bbfc628a3681ddf812f59841d43c57f70a583f5b
[deliverable/binutils-gdb.git] / gdbserver / ChangeLog
1 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2
3 Turn the 'regs_info' linux target op into a method of
4 linux_process_target.
5
6 * linux-low.h (struct linux_target_ops) <regs_info>: Remove.
7 (class linux_process_target) <get_regs_info>: Define.
8
9 Update the callers below.
10
11 * linux-low.cc (linux_process_target::fetch_registers)
12 (linux_process_target::store_registers)
13 * proc-service.cc (gregset_info)
14
15 * linux-x86-low.cc (class x86_target) <get_regs_info>: Declare.
16 (x86_linux_regs_info): Turn into ...
17 (x86_target::get_regs_info): ...this.
18 (the_low_target): Remove the op field.
19 * linux-aarch64-low.cc (class aarch64_target) <get_regs_info>:
20 Declare.
21 (aarch64_regs_info): Turn into ...
22 (aarch64_target::get_regs_info): ...this.
23 (the_low_target): Remove the op field.
24 * linux-arm-low.cc (class arm_target) <get_regs_info>: Declare.
25 (arm_regs_info): Turn into ...
26 (arm_target::get_regs_info): ...this.
27 (the_low_target): Remove the op field.
28 * linux-bfin-low.cc (class bfin_target) <get_regs_info>: Declare.
29 (bfin_regs_info): Turn into ...
30 (bfin_target::get_regs_info): ...this.
31 (the_low_target): Remove the op field.
32 * linux-cris-low.cc (class cris_target) <get_regs_info>: Declare.
33 (cris_regs_info): Turn into ...
34 (cris_target::get_regs_info): ...this.
35 (the_low_target): Remove the op field.
36 * linux-crisv32-low.cc (class crisv32_target) <get_regs_info>:
37 Declare.
38 (crisv32_regs_info): Turn into ...
39 (crisv32_target::get_regs_info): ...this.
40 (the_low_target): Remove the op field.
41 * linux-ia64-low.cc (class ia64_target) <get_regs_info>: Declare.
42 (ia64_regs_info): Turn into ...
43 (ia64_target::get_regs_info): ...this.
44 (the_low_target): Remove the op field.
45 * linux-m32r-low.cc (class m32r_target) <get_regs_info>: Declare.
46 (m32r_regs_info): Turn into ...
47 (m32r_target::get_regs_info): ...this.
48 (the_low_target): Remove the op field.
49 * linux-m68k-low.cc (class m68k_target) <get_regs_info>: Declare.
50 (m68k_regs_info): Turn into ...
51 (m68k_target::get_regs_info): ...this.
52 (the_low_target): Remove the op field.
53 * linux-mips-low.cc (class mips_target) <get_regs_info>: Declare.
54 (mips_regs_info): Turn into ...
55 (mips_target::get_regs_info): ...this.
56 (the_low_target): Remove the op field.
57 (get_usrregs_info): Update the call to the op.
58 * linux-nios2-low.cc (class nios2_target) <get_regs_info>: Declare.
59 (nios2_regs_info): Turn into ...
60 (nios2_target::get_regs_info): ...this.
61 (the_low_target): Remove the op field.
62 * linux-ppc-low.cc (class ppc_target) <get_regs_info>: Declare.
63 (ppc_regs_info): Turn into ...
64 (ppc_target::get_regs_info): ...this.
65 (the_low_target): Remove the op field.
66 * linux-riscv-low.cc (class riscv_target) <get_regs_info>: Declare.
67 (riscv_regs_info): Turn into ...
68 (riscv_target::get_regs_info): ...this.
69 (the_low_target): Remove the op field.
70 * linux-s390-low.cc (class s390_target) <get_regs_info>: Declare.
71 (s390_regs_info): Turn into ...
72 (s390_target::get_regs_info): ...this.
73 (the_low_target): Remove the op field.
74 (s390_collect_ptrace_register)
75 (s390_supply_ptrace_register)
76 (s390_fill_gregset): Update the call to the op.
77 * linux-sh-low.cc (class sh_target) <get_regs_info>: Declare.
78 (sh_regs_info): Turn into ...
79 (sh_target::get_regs_info): ...this.
80 (the_low_target): Remove the op field.
81 * linux-sparc-low.cc (class sparc_target) <get_regs_info>: Declare.
82 (sparc_regs_info): Turn into ...
83 (sparc_target::get_regs_info): ...this.
84 (the_low_target): Remove the op field.
85 * linux-tic6x-low.cc (class tic6x_target) <get_regs_info>: Declare.
86 (tic6x_regs_info): Turn into ...
87 (tic6x_target::get_regs_info): ...this.
88 (the_low_target): Remove the op field.
89 * linux-tile-low.cc (class tile_target) <get_regs_info>: Declare.
90 (tile_regs_info): Turn into ...
91 (tile_target::get_regs_info): ...this.
92 (the_low_target): Remove the op field.
93 * linux-xtensa-low.cc (class xtensa_target) <get_regs_info>:
94 Declare.
95 (xtensa_regs_info): Turn into ...
96 (xtensa_target::get_regs_info): ...this.
97 (the_low_target): Remove the op field.
98
99 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
100
101 Turn the 'arch_setup' linux target op into a method of
102 linux_process_target.
103
104 * linux-low.h (struct linux_target_ops) <arch_setup>: Delete.
105 (class linux_process_target) <arch_setup_thread>
106 <low_arch_setup>: New declarations.
107 * linux-low.cc (linux_arch_setup): Delete.
108 (linux_arch_setup_thread): Turn into...
109 (linux_process_target::arch_setup_thread): ... this.
110
111 Update the callers below.
112
113 (linux_process_target::handle_extended_wait)
114 (linux_process_target::post_create_inferior)
115 (linux_process_target::filter_event)
116
117 * linux-x86-low.cc (class x86_target) <low_arch_setup>: New
118 declaration.
119 (x86_linux_update_xmltarget): Turn into...
120 (x86_target::update_xmltarget): ...this.
121 (x86_linux_process_qsupported): Update the call to
122 x86_linux_update_xmltarget.
123 (x86_arch_setup): Turn into ...
124 (x86_target::low_arch_setup): ...this.
125 (the_low_target): Remove the op field.
126 * linux-aarch64-low.cc (class aarch64_target) <low_arch_setup>: New
127 declaration.
128 (aarch64_arch_setup): Turn into ...
129 (aarch64_target::low_arch_setup): ...this.
130 (the_low_target): Remove the op field.
131 * linux-arm-low.cc (class arm_target) <low_arch_setup>: New
132 declaration.
133 (arm_arch_setup): Turn into ...
134 (arm_target::low_arch_setup): ...this.
135 (the_low_target): Remove the op field.
136 * linux-bfin-low.cc (class bfin_target) <low_arch_setup>: New
137 declaration.
138 (bfin_arch_setup): Turn into ...
139 (bfin_target::low_arch_setup): ...this.
140 (the_low_target): Remove the op field.
141 * linux-cris-low.cc (class cris_target) <low_arch_setup>: New
142 declaration.
143 (cris_arch_setup): Turn into ...
144 (cris_target::low_arch_setup): ...this.
145 (the_low_target): Remove the op field.
146 * linux-crisv32-low.cc (class crisv32_target) <low_arch_setup>: New
147 declaration.
148 (crisv32_arch_setup): Turn into ...
149 (crisv32_target::low_arch_setup): ...this.
150 (the_low_target): Remove the op field.
151 * linux-ia64-low.cc (class ia64_target) <low_arch_setup>: New
152 declaration.
153 (ia64_arch_setup): Turn into ...
154 (ia64_target::low_arch_setup): ...this.
155 (the_low_target): Remove the op field.
156 * linux-m32r-low.cc (class m32r_target) <low_arch_setup>: New
157 declaration.
158 (m32r_arch_setup): Turn into ...
159 (m32r_target::low_arch_setup): ...this.
160 (the_low_target): Remove the op field.
161 * linux-m68k-low.cc (class m68k_target) <low_arch_setup>: New
162 declaration.
163 (m68k_arch_setup): Turn into ...
164 (m68k_target::low_arch_setup): ...this.
165 (the_low_target): Remove the op field.
166 * linux-mips-low.cc (class mips_target) <low_arch_setup>: New
167 declaration.
168 (mips_arch_setup): Turn into ...
169 (mips_target::low_arch_setup): ...this.
170 (the_low_target): Remove the op field.
171 * linux-nios2-low.cc (class nios2_target) <low_arch_setup>: New
172 declaration.
173 (nios2_arch_setup): Turn into ...
174 (nios2_target::low_arch_setup): ...this.
175 (the_low_target): Remove the op field.
176 * linux-ppc-low.cc (class ppc_target) <low_arch_setup>: New
177 declaration.
178 (ppc_arch_setup): Turn into ...
179 (ppc_target::low_arch_setup): ...this.
180 (the_low_target): Remove the op field.
181 * linux-riscv-low.cc (class riscv_target) <low_arch_setup>: New
182 declaration.
183 (riscv_arch_setup): Turn into ...
184 (riscv_target::low_arch_setup): ...this.
185 (the_low_target): Remove the op field.
186 * linux-s390-low.cc (class s390_target) <low_arch_setup>: New
187 declaration.
188 (s390_arch_setup): Turn into ...
189 (s390_target::low_arch_setup): ...this.
190 (the_low_target): Remove the op field.
191 * linux-sh-low.cc (class sh_target) <low_arch_setup>: New
192 declaration.
193 (sh_arch_setup): Turn into ...
194 (sh_target::low_arch_setup): ...this.
195 (the_low_target): Remove the op field.
196 * linux-sparc-low.cc (class sparc_target) <low_arch_setup>: New
197 declaration.
198 (sparc_arch_setup): Turn into ...
199 (sparc_target::low_arch_setup): ...this.
200 (the_low_target): Remove the op field.
201 * linux-tic6x-low.cc (class tic6x_target) <low_arch_setup>: New
202 declaration.
203 (tic6x_arch_setup): Turn into ...
204 (tic6x_target::low_arch_setup): ...this.
205 (the_low_target): Remove the op field.
206 * linux-tile-low.cc (class tile_target) <low_arch_setup>: New
207 declaration.
208 (tile_arch_setup): Turn into ...
209 (tile_target::low_arch_setup): ...this.
210 (the_low_target): Remove the op field.
211 * linux-xtensa-low.cc (class xtensa_target) <low_arch_setup>: New
212 declaration.
213 (xtensa_arch_setup): Turn into ...
214 (xtensa_target::low_arch_setup): ...this.
215 (the_low_target): Remove the op field.
216
217 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
218
219 * linux-low.h (the_linux_target): New extern declaration.
220 * linux-low.cc (initialize_low): Use 'the_linux_target' to set
221 'the_target'.
222 (the_linux_target): Remove.
223 * linux-x86-low.cc (class x86_target): New class.
224 (the_x86_target): New static object.
225 (the_linux_target): Define as pointer to the_x86_target.
226 * linux-aarch64-low.cc (class aarch64_target): New class.
227 (the_aarch64_target): New static object.
228 (the_linux_target): Define as pointer to the_aarch64_target.
229 * linux-arm-low.cc (class arm_target): New class.
230 (the_arm_target): New static object.
231 (the_linux_target): Define as pointer to the_arm_target.
232 * linux-bfin-low.cc (class bfin_target): New class.
233 (the_bfin_target): New static object.
234 (the_linux_target): Define as pointer to the_bfin_target.
235 * linux-cris-low.cc (class cris_target): New class.
236 (the_cris_target): New static object.
237 (the_linux_target): Define as pointer to the_cris_target.
238 * linux-crisv32-low.cc (class crisv32_target): New class.
239 (the_crisv32_target): New static object.
240 (the_linux_target): Define as pointer to the_crisv32_target.
241 * linux-ia64-low.cc (class ia64_target): New class.
242 (the_ia64_target): New static object.
243 (the_linux_target): Define as pointer to the_ia64_target.
244 * linux-m32r-low.cc (class m32r_target): New class.
245 (the_m32r_target): New static object.
246 (the_linux_target): Define as pointer to the_m32r_target.
247 * linux-m68k-low.cc (class m68k_target): New class.
248 (the_m68k_target): New static object.
249 (the_linux_target): Define as pointer to the_m68k_target.
250 * linux-mips-low.cc (class mips_target): New class.
251 (the_mips_target): New static object.
252 (the_linux_target): Define as pointer to the_mips_target.
253 * linux-nios2-low.cc (class nios2_target): New class.
254 (the_nios2_target): New static object.
255 (the_linux_target): Define as pointer to the_nios2_target.
256 * linux-ppc-low.cc (class ppc_target): New class.
257 (the_ppc_target): New static object.
258 (the_linux_target): Define as pointer to the_ppc_target.
259 * linux-riscv-low.cc (class riscv_target): New class.
260 (the_riscv_target): New static object.
261 (the_linux_target): Define as pointer to the_riscv_target.
262 * linux-s390-low.cc (class s390_target): New class.
263 (the_s390_target): New static object.
264 (the_linux_target): Define as pointer to the_s390_target.
265 * linux-sh-low.cc (class sh_target): New class.
266 (the_sh_target): New static object.
267 (the_linux_target): Define as pointer to the_sh_target.
268 * linux-sparc-low.cc (class sparc_target): New class.
269 (the_sparc_target): New static object.
270 (the_linux_target): Define as pointer to the_sparc_target.
271 * linux-tic6x-low.cc (class tic6x_target): New class.
272 (the_tic6x_target): New static object.
273 (the_linux_target): Define as pointer to the_tic6x_target.
274 * linux-tile-low.cc (class tile_target): New class.
275 (the_tile_target): New static object.
276 (the_linux_target): Define as pointer to the_tile_target.
277 * linux-xtensa-low.cc (class xtensa_target): New class.
278 (the_xtensa_target): New static object.
279 (the_linux_target): Define as pointer to the_xtensa_target.
280
281 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
282
283 Turn some static functions in linux-low.cc into private methods of
284 linux_process_target.
285
286 * linux-low.cc (handle_extended_wait): Turn into ...
287 (linux_process_target::handle_extended_wait): ...this. Call
288 'mourn' on 'this' object instead of 'the_target'.
289 (maybe_move_out_of_jump_pad): Turn into...
290 (linux_process_target::maybe_move_out_of_jump_pad): ...this.
291 (linux_low_filter_event): Turn into...
292 (linux_process_target::filter_event): ...this.
293 (linux_wait_for_event_filtered): Turn into...
294 (linux_process_target::wait_for_event_filtered): ...this.
295 (linux_wait_for_event): Turn into...
296 (linux_process_target::wait_for_event): ...this.
297 (linux_wait_1): Turn into...
298 (linux_process_target::wait_1): ...this.
299 (wait_for_sigstop): Turn into...
300 (linux_process_target::wait_for_sigstop): ...this.
301 (move_out_of_jump_pad_callback): Turn into...
302 (linux_process_target::move_out_of_jump_pad): ...this.
303 (stop_all_lwps): Turn into...
304 (linux_process_target::stop_all_lwps): ...this.
305 (start_step_over): Turn into...
306 (linux_process_target::start_step_over): ...this.
307 (complete_ongoing_step_over): Turn into...
308 (linux_process_target::complete_ongoing_step_over): ...this.
309 (proceed_all_lwps): Turn into...
310 (linux_process_target::proceed_all_lwps): ...this.
311 (unstop_all_lwps): Turn into...
312 (linux_process_target::unstop_all_lwps): ...this.
313
314 * linux-low.h (class linux_process_target)
315 <handle_extended_wait>
316 <maybe_move_out_of_jump_pad>
317 filter_event>
318 <wait_for_event_filtered>
319 <wait_for_event>
320 <wait_1>
321 <wait_for_sigstop>
322 <move_out_of_jump_pad>
323 <stop_all_lwps>
324 <start_step_over>
325 <complete_ongoing_step_over>
326 <proceed_all_lwps>
327 <unstop_all_lwps>: Declare.
328
329 Update the callers below.
330
331 * linux-low.cc (linux_process_target::attach): Update.
332 (linux_process_target::stabilize_threads): Ditto.
333 (linux_process_target::wait): Ditto.
334
335 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
336
337 * linux-low.h (struct linux_target_ops): Update the comment for
338 'cannot_store_register' to return 0 or 1.
339 * linux-ppc-low.cc (ppc_cannot_store_register): Return 1 instead
340 of 2.
341
342 2020-03-20 Simon Marchi <simon.marchi@efficios.com>
343
344 * config.in: Re-generate.
345 * configure: Re-generate.
346
347 2020-03-17 Kamil Rytarowski <n54@gmx.com>
348
349 * regcache.cc (find_register_by_number): Update.
350 * tdesc.cc (init_target_desc): Likewise.
351 * tdesc.h (target_desc::reg_defs): Likewise.
352
353 2020-03-12 Tom Tromey <tom@tromey.com>
354
355 * configure: Rebuild.
356 * configure.ac (GDBSERVER_DEPFILES): Remove srv_selftest_objs.
357 (WIN32APILIBS): New subst.
358 * Makefile.in (SFILES, OBS, TAGS, GDBREPLAY_OBS): Remove
359 gdbsupport files.
360 (gdbsupport/%.o): Remove target.
361 (GDBSUPPORT_BUILDDIR, GDBSUPPORT): New variables.
362 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Add GDBSUPPORT.
363 (WIN32APILIBS): New variable.
364 (gdbserver$(EXEEXT)): Add WIN32APILIBS.
365 (gdbreplay$(EXEEXT)): Likewise.
366
367 2020-03-12 Tom Tromey <tom@tromey.com>
368
369 * config.in, configure: Rebuild.
370 * configure.ac: Call ZW_GNU_GETTEXT_SISTER_DIR.
371 * acinclude.m4: Include gettext-sister.m4.
372 * Makefile.in (top_builddir, INTL, INTL_DEPS, INTL_CFLAGS): New
373 variables.
374 (INCLUDE_CFLAGS): Add INTL_CFLAGS.
375 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Use INTL_DEPS, INTL.
376
377 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
378
379 * acinclude.m4: Update path to selftest.m4.
380
381 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
382
383 * configure.ac: Don't source bfd/development.sh, move
384 GDB_AC_COMMON higher.
385 * configure: Re-generate.
386
387 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
388
389 * configure: Re-generate.
390
391 2020-03-11 Simon Marchi <simon.marchi@efficios.com>
392
393 * configure: Re-generate.
394
395 2020-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
396
397 * .dir-locals.el: New file.
398
399 2020-03-05 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
400
401 * .gitattributes: New file.
402
403 2020-03-02 Andrew Burgess <andrew.burgess@embecosm.com>
404
405 * remote-utils.cc (prepare_resume_reply): Add ability to convert T
406 reply into an S reply.
407 * server.cc (disable_packet_T): New global.
408 (captured_main): Set new global when appropriate.
409 * server.h (disable_packet_T): Declare.
410
411 2020-02-21 Tom Tromey <tom@tromey.com>
412
413 * Makefile.in (mostlyclean): New target.
414
415 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
416
417 * target.h (struct process_stratum_target): Remove.
418 (class process_target): Rename to ...
419 (class process_stratum_target): ... this.
420 * linux-low.h (class linux_process_target): Derive from
421 'process_stratum_target'.
422 * linux-low.cc (linux_target_ops): Remove.
423 (initialize_low): Set the_target to the singleton instance of
424 linux_process_target.
425 * lynx-low.h (class lynx_process_target): Derive from
426 'process_stratum_target'.
427 * lynx-low.cc (lynx_target_ops): Remove.
428 (initialize_low): Set the_target to the singleton instance of
429 lynx_process_target.
430 * nto-low.h (class nto_process_target): Derive from
431 'process_stratum_target'.
432 * nto-low.cc (nto_target_ops): Remove.
433 (initialize_low): Set the_target to the singleton instance of
434 nto_process_target.
435 * win32-low.h (class win32_process_target): Derive from
436 'process_stratum_target'.
437 * win32-low.cc (win32_target_ops): Remove.
438 (initialize_low): Set the_target to the singleton instance of
439 win32_process_target.
440
441 Replace 'the_target->pt' with 'the_target' in the uses below.
442
443 * hostio.cc (hostio_error)
444 (handle_setfs)
445 (handle_open)
446 (handle_unlink)
447 (handle_readlink)
448 * linux-aarch32-low.cc (arm_breakpoint_at)
449 * linux-aarch64-low.cc (aarch64_breakpoint_at)
450 * linux-arm-low.cc (arm_sigreturn_next_pc)
451 (arm_get_hwcap)
452 (arm_get_syscall_trapinfo)
453 * linux-cris-low.cc (cris_breakpoint_at)
454 * linux-crisv32-low.cc (cris_breakpoint_at)
455 * linux-low.cc (handle_extended_wait)
456 (linux_wait_1)
457 (linux_read_memory)
458 (linux_process_target::breakpoint_kind_from_pc)
459 (linux_get_auxv)
460 * linux-m32r-low.cc (m32r_breakpoint_at)
461 * linux-mips-low.cc (mips_breakpoint_at)
462 * linux-nios2-low.cc (nios2_breakpoint_at)
463 * linux-ppc-low.cc (ppc_breakpoint_at)
464 * linux-s390-low.cc (s390_get_hwcap)
465 * linux-sh-low.cc (sh_breakpoint_at)
466 * linux-sparc-low.cc (sparc_fill_gregset_to_stack)
467 (sparc_store_gregset_from_stack)
468 (sparc_breakpoint_at)
469 * linux-tic6x-low.cc (tic6x_breakpoint_at)
470 * linux-tile-low.cc (tile_breakpoint_at)
471 * linux-x86-low.cc (x86_breakpoint_at)
472 * linux-xtensa-low.cc (xtensa_breakpoint_at)
473 * mem-break.cc (bp_size)
474 (bp_opcode)
475 (insert_memory_breakpoint)
476 (set_raw_breakpoint_at)
477 (delete_raw_breakpoint)
478 (z_type_supported)
479 (uninsert_raw_breakpoint)
480 (reinsert_raw_breakpoint)
481 (validate_inserted_breakpoint)
482 * regcache.cc (regcache_read_pc)
483 (regcache_write_pc)
484 * remote-utils.cc (putpkt_binary_1)
485 (input_interrupt)
486 (getpkt)
487 (prepare_resume_reply)
488 * server.cc (handle_general_set)
489 (handle_detach)
490 (handle_qxfer_auxv)
491 (handle_qxfer_exec_file)
492 (handle_qxfer_libraries_svr4)
493 (handle_qxfer_osdata)
494 (handle_qxfer_siginfo)
495 (handle_qxfer_fdpic)
496 (handle_query)
497 (resume)
498 (handle_v_requests)
499 (queue_stop_reply_callback)
500 (captured_main)
501 * target.cc (prepare_to_access_memory)
502 (done_accessing_memory)
503 (read_inferior_memory)
504 (target_write_memory)
505 (target_stop_and_wait)
506 (target_wait)
507 (target_mourn_inferior)
508 (target_continue_no_signal)
509 (target_continue)
510 (target_supports_multi_process)
511 (kill_inferior)
512 * target.h
513 (target_create_inferior)
514 (target_post_create_inferior)
515 (myattach)
516 (target_supports_fork_events)
517 (target_supports_vfork_events)
518 (target_supports_exec_events)
519 (target_handle_new_gdb_connection)
520 (detach_inferior)
521 (mythread_alive)
522 (fetch_inferior_registers)
523 (store_inferior_registers)
524 (join_inferior)
525 (target_supports_non_stop)
526 (target_async)
527 (target_process_qsupported)
528 (target_supports_catch_syscall)
529 (target_get_ipa_tdesc_idx)
530 (target_supports_tracepoints)
531 (target_supports_fast_tracepoints)
532 (target_get_min_fast_tracepoint_insn_len)
533 (target_thread_stopped)
534 (target_pause_all)
535 (target_unpause_all)
536 (target_stabilize_threads)
537 (target_install_fast_tracepoint_jump_pad)
538 (target_emit_ops)
539 (target_supports_disable_randomization)
540 (target_supports_agent)
541 (target_enable_btrace)
542 (target_disable_btrace)
543 (target_read_btrace)
544 (target_read_btrace_conf)
545 (target_supports_range_stepping)
546 (target_supports_stopped_by_sw_breakpoint)
547 (target_stopped_by_sw_breakpoint)
548 (target_supports_stopped_by_hw_breakpoint)
549 (target_supports_hardware_single_step)
550 (target_stopped_by_hw_breakpoint)
551 (target_breakpoint_kind_from_pc)
552 (target_breakpoint_kind_from_current_state)
553 (target_supports_software_single_step)
554 (target_core_of_thread)
555 (target_thread_name)
556 (target_thread_handle)
557 * win32-low.cc (do_initial_child_stuff)
558
559 Rename target op default definitions listed below.
560
561 * target.cc (process_target::post_create_inferior): Rename as ...
562 (process_stratum_target::post_create_inferior): ... this.
563 (process_target::prepare_to_access_memory): Rename as ...
564 (process_stratum_target::prepare_to_access_memory): ... this.
565 (process_target::done_accessing_memory): Rename as ...
566 (process_stratum_target::done_accessing_memory): ... this.
567 (process_target::look_up_symbols): Rename as ...
568 (process_stratum_target::look_up_symbols): ... this.
569 (process_target::supports_read_auxv): Rename as ...
570 (process_stratum_target::supports_read_auxv): ... this.
571 (process_target::read_auxv): Rename as ...
572 (process_stratum_target::read_auxv): ... this.
573 (process_target::supports_z_point_type): Rename as ...
574 (process_stratum_target::supports_z_point_type): ... this.
575 (process_target::insert_point): Rename as ...
576 (process_stratum_target::insert_point): ... this.
577 (process_target::remove_point): Rename as ...
578 (process_stratum_target::remove_point): ... this.
579 (process_target::stopped_by_sw_breakpoint): Rename as ...
580 (process_stratum_target::stopped_by_sw_breakpoint): ... this.
581 (process_target::supports_stopped_by_sw_breakpoint): Rename as ...
582 (process_stratum_target::supports_stopped_by_sw_breakpoint): ... this.
583 (process_target::stopped_by_hw_breakpoint): Rename as ...
584 (process_stratum_target::stopped_by_hw_breakpoint): ... this.
585 (process_target::supports_stopped_by_hw_breakpoint): Rename as ...
586 (process_stratum_target::supports_stopped_by_hw_breakpoint): ... this.
587 (process_target::supports_hardware_single_step): Rename as ...
588 (process_stratum_target::supports_hardware_single_step): ... this.
589 (process_target::stopped_by_watchpoint): Rename as ...
590 (process_stratum_target::stopped_by_watchpoint): ... this.
591 (process_target::stopped_data_address): Rename as ...
592 (process_stratum_target::stopped_data_address): ... this.
593 (process_target::supports_read_offsets): Rename as ...
594 (process_stratum_target::supports_read_offsets): ... this.
595 (process_target::read_offsets): Rename as ...
596 (process_stratum_target::read_offsets): ... this.
597 (process_target::supports_get_tls_address): Rename as ...
598 (process_stratum_target::supports_get_tls_address): ... this.
599 (process_target::get_tls_address): Rename as ...
600 (process_stratum_target::get_tls_address): ... this.
601 (process_target::hostio_last_error): Rename as ...
602 (process_stratum_target::hostio_last_error): ... this.
603 (process_target::supports_qxfer_osdata): Rename as ...
604 (process_stratum_target::supports_qxfer_osdata): ... this.
605 (process_target::qxfer_osdata): Rename as ...
606 (process_stratum_target::qxfer_osdata): ... this.
607 (process_target::supports_qxfer_siginfo): Rename as ...
608 (process_stratum_target::supports_qxfer_siginfo): ... this.
609 (process_target::qxfer_siginfo): Rename as ...
610 (process_stratum_target::qxfer_siginfo): ... this.
611 (process_target::supports_non_stop): Rename as ...
612 (process_stratum_target::supports_non_stop): ... this.
613 (process_target::async): Rename as ...
614 (process_stratum_target::async): ... this.
615 (process_target::start_non_stop): Rename as ...
616 (process_stratum_target::start_non_stop): ... this.
617 (process_target::supports_multi_process): Rename as ...
618 (process_stratum_target::supports_multi_process): ... this.
619 (process_target::supports_fork_events): Rename as ...
620 (process_stratum_target::supports_fork_events): ... this.
621 (process_target::supports_vfork_events): Rename as ...
622 (process_stratum_target::supports_vfork_events): ... this.
623 (process_target::supports_exec_events): Rename as ...
624 (process_stratum_target::supports_exec_events): ... this.
625 (process_target::handle_new_gdb_connection): Rename as ...
626 (process_stratum_target::handle_new_gdb_connection): ... this.
627 (process_target::handle_monitor_command): Rename as ...
628 (process_stratum_target::handle_monitor_command): ... this.
629 (process_target::core_of_thread): Rename as ...
630 (process_stratum_target::core_of_thread): ... this.
631 (process_target::supports_read_loadmap): Rename as ...
632 (process_stratum_target::supports_read_loadmap): ... this.
633 (process_target::read_loadmap): Rename as ...
634 (process_stratum_target::read_loadmap): ... this.
635 (process_target::process_qsupported): Rename as ...
636 (process_stratum_target::process_qsupported): ... this.
637 (process_target::supports_tracepoints): Rename as ...
638 (process_stratum_target::supports_tracepoints): ... this.
639 (process_target::read_pc): Rename as ...
640 (process_stratum_target::read_pc): ... this.
641 (process_target::write_pc): Rename as ...
642 (process_stratum_target::write_pc): ... this.
643 (process_target::supports_thread_stopped): Rename as ...
644 (process_stratum_target::supports_thread_stopped): ... this.
645 (process_target::thread_stopped): Rename as ...
646 (process_stratum_target::thread_stopped): ... this.
647 (process_target::supports_get_tib_address): Rename as ...
648 (process_stratum_target::supports_get_tib_address): ... this.
649 (process_target::get_tib_address): Rename as ...
650 (process_stratum_target::get_tib_address): ... this.
651 (process_target::pause_all): Rename as ...
652 (process_stratum_target::pause_all): ... this.
653 (process_target::unpause_all): Rename as ...
654 (process_stratum_target::unpause_all): ... this.
655 (process_target::stabilize_threads): Rename as ...
656 (process_stratum_target::stabilize_threads): ... this.
657 (process_target::supports_fast_tracepoints): Rename as ...
658 (process_stratum_target::supports_fast_tracepoints): ... this.
659 (process_target::get_min_fast_tracepoint_insn_len): Rename as ...
660 (process_stratum_target::get_min_fast_tracepoint_insn_len): ... this.
661 (process_target::emit_ops): Rename as ...
662 (process_stratum_target::emit_ops): ... this.
663 (process_target::supports_disable_randomization): Rename as ...
664 (process_stratum_target::supports_disable_randomization): ... this.
665 (process_target::supports_qxfer_libraries_svr4): Rename as ...
666 (process_stratum_target::supports_qxfer_libraries_svr4): ... this.
667 (process_target::qxfer_libraries_svr4): Rename as ...
668 (process_stratum_target::qxfer_libraries_svr4): ... this.
669 (process_target::supports_agent): Rename as ...
670 (process_stratum_target::supports_agent): ... this.
671 (process_target::enable_btrace): Rename as ...
672 (process_stratum_target::enable_btrace): ... this.
673 (process_target::disable_btrace): Rename as ...
674 (process_stratum_target::disable_btrace): ... this.
675 (process_target::read_btrace): Rename as ...
676 (process_stratum_target::read_btrace): ... this.
677 (process_target::read_btrace_conf): Rename as ...
678 (process_stratum_target::read_btrace_conf): ... this.
679 (process_target::supports_range_stepping): Rename as ...
680 (process_stratum_target::supports_range_stepping): ... this.
681 (process_target::supports_pid_to_exec_file): Rename as ...
682 (process_stratum_target::supports_pid_to_exec_file): ... this.
683 (process_target::pid_to_exec_file): Rename as ...
684 (process_stratum_target::pid_to_exec_file): ... this.
685 (process_target::supports_multifs): Rename as ...
686 (process_stratum_target::supports_multifs): ... this.
687 (process_target::multifs_open): Rename as ...
688 (process_stratum_target::multifs_open): ... this.
689 (process_target::multifs_unlink): Rename as ...
690 (process_stratum_target::multifs_unlink): ... this.
691 (process_target::multifs_readlink): Rename as ...
692 (process_stratum_target::multifs_readlink): ... this.
693 (process_target::breakpoint_kind_from_pc): Rename as ...
694 (process_stratum_target::breakpoint_kind_from_pc): ... this.
695 (process_target::breakpoint_kind_from_current_state): Rename as ...
696 (process_stratum_target::breakpoint_kind_from_current_state): ... this.
697 (process_target::thread_name): Rename as ...
698 (process_stratum_target::thread_name): ... this.
699 (process_target::thread_handle): Rename as ...
700 (process_stratum_target::thread_handle): ... this.
701 (process_target::supports_software_single_step): Rename as ...
702 (process_stratum_target::supports_software_single_step): ... this.
703 (process_target::supports_catch_syscall): Rename as ...
704 (process_stratum_target::supports_catch_syscall): ... this.
705 (process_target::get_ipa_tdesc_idx): Rename as ...
706 (process_stratum_target::get_ipa_tdesc_idx): ... this.
707
708 2020-02-20 Pedro Alves <palves@redhat.com>
709
710 * target.cc (set_target_ops): Simply copy the given target pointer
711 instead of creating a copy of the pointed object.
712
713 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
714
715 Turn process_stratum_target's get_ipa_tdesc_idx op into a method
716 of process_target.
717
718 * target.h (struct process_stratum_target): Remove the target op.
719 (class process_target): Add the target op.
720 (target_get_ipa_tdesc_idx): Update the macro.
721 * target.cc (process_target::get_ipa_tdesc_idx): Define.
722
723 Update the derived classes and callers below.
724
725 * linux-low.cc (linux_target_ops): Update.
726 (linux_get_ipa_tdesc_idx): Turn into ...
727 (linux_process_target::get_ipa_tdesc_idx): ... this.
728 * linux-low.h (class linux_process_target): Update.
729 * lynx-low.cc (lynx_target_ops): Update.
730 * nto-low.cc (nto_target_ops): Update.
731 * win32-low.cc (win32_target_ops): Update.
732
733 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
734
735 Turn process_stratum_target's supports_catch_syscall op into a
736 method of process_target.
737
738 * target.h (struct process_stratum_target): Remove the target op.
739 (class process_target): Add the target op.
740 (target_supports_catch_syscall): Update the macro.
741 * target.cc (process_target::supports_catch_syscall): Define.
742
743 Update the derived classes and callers below.
744
745 * linux-low.cc (linux_target_ops): Update.
746 (linux_supports_catch_syscall): Turn into ...
747 (linux_process_target::supports_catch_syscall): ... this.
748 * linux-low.h (class linux_process_target): Update.
749 * lynx-low.cc (lynx_target_ops): Update.
750 * nto-low.cc (nto_target_ops): Update.
751 * win32-low.cc (win32_target_ops): Update.
752
753 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
754
755 Turn process_stratum_target's supports_software_single_step op
756 into a method of process_target.
757
758 * target.h (struct process_stratum_target): Remove the target op.
759 (class process_target): Add the target op.
760 (target_supports_software_single_step): Update the macro.
761 * target.cc (process_target::supports_software_single_step): Define.
762
763 Update the derived classes and callers below.
764
765 * linux-low.cc (linux_target_ops): Update.
766 (linux_supports_software_single_step): Turn into ...
767 (linux_process_target::supports_software_single_step): ... this.
768 * linux-low.h (class linux_process_target): Update.
769 * lynx-low.cc (lynx_target_ops): Update.
770 * nto-low.cc (nto_target_ops): Update.
771 * win32-low.cc (win32_target_ops): Update.
772
773 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
774
775 Turn process_stratum_target's thread_name and thread_handle ops
776 into methods of process_target.
777
778 * target.h (struct process_stratum_target): Remove the target ops.
779 (class process_target): Add the target ops.
780 (target_thread_name): Update the macro.
781 (target_thread_handle): Update the macro.
782 * target.cc (process_target::thread_name): Define.
783 (process_target::thread_handle): Define.
784
785 Update the derived classes and callers below.
786
787 * linux-low.cc (linux_target_ops): Update.
788 (linux_process_target::thread_name): Define.
789 (linux_process_target::thread_handle): Define.
790 * linux-low.h (class linux_process_target): Update.
791 * lynx-low.cc (lynx_target_ops): Update.
792 * nto-low.cc (nto_target_ops): Update.
793 * win32-low.cc (win32_target_ops): Update.
794
795 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
796
797 Turn process_stratum_target's breakpoint_kind_from_pc,
798 sw_breakpoint_from_kind, and breakpoint_kind_from_current_state
799 ops into methods of process_target.
800
801 * target.h (struct process_stratum_target): Remove the target op.
802 (class process_target): Add the target op.
803 (target_breakpoint_kind_from_pc): Update the macro.
804 (target_breakpoint_kind_from_current_state): Update the macro.
805 (default_breakpoint_kind_from_pc): Remove declaration.
806 * target.cc (default_breakpoint_kind_from_pc): Turn into ...
807 (process_target::breakpoint_kind_from_pc): ... this.
808 (process_target::breakpoint_kind_from_current_state): Define.
809
810 Update the derived classes and callers below.
811
812 * mem-break.cc (bp_size): Update.
813 (bp_opcode): Update.
814 * linux-low.cc (linux_target_ops): Update.
815 (linux_wait_1): Update.
816 (linux_breakpoint_kind_from_pc): Turn into ...
817 (linux_process_target::breakpoint_kind_from_pc): ... this.
818 (linux_sw_breakpoint_from_kind): Turn into ...
819 (linux_process_target::sw_breakpoint_from_kind): ... this.
820 (linux_breakpoint_kind_from_current_state): Turn into ...
821 (linux_process_target::breakpoint_kind_from_current_state): ... this.
822 * linux-low.h (class linux_process_target): Update.
823 * lynx-low.cc (lynx_target_ops): Update.
824 (lynx_process_target::sw_breakpoint_from_kind): Define.
825 * lynx-low.h (class lynx_process_target): Update.
826 * nto-low.cc (nto_target_ops): Update.
827 (nto_sw_breakpoint_from_kind): Turn into ...
828 (nto_process_target::sw_breakpoint_from_kind): ... this.
829 * nto-low.h (class nto_process_target): Update.
830 * win32-low.cc (win32_target_ops): Update.
831 (win32_sw_breakpoint_from_kind): Turn into ...
832 (win32_process_target::sw_breakpoint_from_kind): ... this.
833 * win32-low.h (class win32_process_target): Update.
834
835 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
836
837 Turn process_stratum_target's multifs_open, multifs_readlink,
838 multifs_unlink ops into methods of process_target.
839
840 * target.h (struct process_stratum_target): Remove the target ops.
841 (class process_target): Add the target ops. Also add
842 'supports_multifs'.
843 * target.cc: Include "fcntl.h", "unistd.h", "sys/types.h", and
844 "sys/stat.h".
845 (process_target::supports_multifs): Define.
846 (process_target::multifs_open): Define.
847 (process_target::multifs_readlink): Define.
848 (process_target::multifs_unlink): Define.
849
850 Update the derived classes and callers below.
851
852 * hostio.cc (handle_setfs): Update.
853 (handle_open): Update.
854 (handle_unlink): Update.
855 (handle_readlink): Update.
856 * linux-low.cc (linux_target_ops): Update.
857 (linux_process_target::supports_multifs): Define.
858 (linux_process_target::multifs_open): Define.
859 (linux_process_target::multifs_readlink): Define.
860 (linux_process_target::multifs_unlink): Define.
861 * linux-low.h (class linux_process_target): Update.
862 * lynx-low.cc (lynx_target_ops): Update.
863 * nto-low.cc (nto_target_ops): Update.
864 * win32-low.cc (win32_target_ops): Update.
865
866 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
867
868 Turn process_stratum_target's pid_to_exec_file op into a method
869 of process_target.
870
871 * target.h (struct process_stratum_target): Remove the target op.
872 (class process_target): Add the target op. Also add
873 'supports_pid_to_exec_file'.
874 * target.cc (process_target::pid_to_exec_file): Define.
875 (process_target::supports_pid_to_exec_file): Define.
876
877 Update the derived classes and callers below.
878
879 * server.cc (handle_qxfer_exec_file): Update.
880 (handle_query): Update.
881 * linux-low.cc (linux_target_ops): Update.
882 (linux_process_target::supports_pid_to_exec_file): Define.
883 (linux_process_target::pid_to_exec_file): Define.
884 * linux-low.h (class linux_process_target): Update.
885 * lynx-low.cc (lynx_target_ops): Update.
886 * nto-low.cc (nto_target_ops): Update.
887 * win32-low.cc (win32_target_ops): Update.
888
889 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
890
891 Turn process_stratum_target's supports_range_stepping op into a
892 method of process_target.
893
894 * target.h (struct process_stratum_target): Remove the target op.
895 (class process_target): Add the target op.
896 (target_supports_range_stepping): Update the macro.
897 * target.cc (process_target::supports_range_stepping): Define.
898
899 Update the derived classes and callers below.
900
901 * linux-low.cc (linux_target_ops): Update.
902 (linux_supports_range_stepping): Turn into ...
903 (linux_process_target::supports_range_stepping): ... this.
904 * linux-low.h (class linux_process_target): Update.
905 * lynx-low.cc (lynx_target_ops): Update.
906 * nto-low.cc (nto_target_ops): Update.
907 * win32-low.cc (win32_target_ops): Update.
908
909 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
910
911 Turn process_stratum_target's btrace-related ops (enable_btrace,
912 disable_btrace, read_btrace, read_btrace_conf) into methods of
913 process_target.
914
915 * target.h (struct process_stratum_target): Remove the target ops.
916 (class process_target): Add the target ops.
917 (target_enable_btrace): Update.
918 (target_disable_btrace): Update.
919 (target_read_btrace): Update.
920 (target_read_btrace_conf): Update.
921 * target.cc (process_target::enable_btrace): Define.
922 (process_target::disable_btrace): Define.
923 (process_target::read_btrace): Define.
924 (process_target::read_btrace_conf): Define.
925
926 Update the derived classes and callers below.
927
928 * linux-low.cc (linux_target_ops): Update.
929 (linux_process_target:enable_btrace): Define as a wrapper around
930 linux_enable_btrace.
931 (linux_low_disable_btrace): Turn into ...
932 (linux_process_target::disable_btrace): ... this.
933 (linux_low_read_btrace): Turn into ...
934 (linux_process_target::read_btrace): ... this.
935 (linux_low_btrace_conf): Turn into ...
936 (linux_process_target::read_btrace_conf): ... this.
937 * linux-low.h (class linux_process_target): Update.
938 * lynx-low.cc (lynx_target_ops): Update.
939 * nto-low.cc (nto_target_ops): Update.
940 * win32-low.cc (win32_target_ops): Update.
941
942 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
943
944 Turn process_stratum_target's supports_agent op into a method of
945 process_target.
946
947 * target.h (struct process_stratum_target): Remove the target op.
948 (class process_target): Add the target op.
949 (target_supports_agent): Update the macro.
950 * target.cc (process_target::supports_agent): Define.
951
952 Update the derived classes and callers below.
953
954 * linux-low.cc (linux_target_ops): Update.
955 (linux_supports_agent): Turn into ...
956 (linux_process_target::supports_agent): ... this.
957 * linux-low.h (class linux_process_target): Update.
958 * lynx-low.cc (lynx_target_ops): Update.
959 * nto-low.cc (nto_target_ops): Update.
960 * win32-low.cc (win32_target_ops): Update.
961
962 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
963
964 Turn process_stratum_target's qxfer_libraries_svr4 op into a
965 method of process_target.
966
967 * target.h (struct process_stratum_target): Remove the target op.
968 (class process_target): Add the target op. Also add
969 'supports_qxfer_libraries_svr4'.
970 * target.cc (process_target::qxfer_libraries_svr4): Define.
971 (process_target::supports_qxfer_libraries_svr4): Define.
972
973 Update the derived classes and callers below.
974
975 * server.cc (handle_qxfer_libraries_svr4): Update.
976 (handle_query): Update.
977 * linux-low.cc (linux_target_ops): Update.
978 (linux_process_target::supports_qxfer_libraries_svr4): Define.
979 (linux_qxfer_libraries_svr4): Turn into ...
980 (linux_process_target::qxfer_libraries_svr4): ... this.
981 * linux-low.h (class linux_process_target): Update.
982 * lynx-low.cc (lynx_target_ops): Update.
983 * nto-low.cc (nto_target_ops): Update.
984 * win32-low.cc (win32_target_ops): Update.
985
986 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
987
988 Turn process_stratum_target's supports_disable_randomization op
989 into a method of process_target.
990
991 * target.h (struct process_stratum_target): Remove the target op.
992 (class process_target): Add the target op.
993 (target_supports_disable_randomization): Update the macro.
994 * target.cc (process_target::supports_disable_randomization): Define.
995
996 Update the derived classes and callers below.
997
998 * linux-low.cc (linux_target_ops): Update.
999 (linux_supports_disable_randomization): Turn into ...
1000 (linux_process_target::supports_disable_randomization): ... this.
1001 * linux-low.h (class linux_process_target): Update.
1002 * lynx-low.cc (lynx_target_ops): Update.
1003 * nto-low.cc (nto_target_ops): Update.
1004 * win32-low.cc (win32_target_ops): Update.
1005
1006 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1007
1008 Turn process_stratum_target's emit_ops op into a method of
1009 process_target.
1010
1011 * target.h (struct process_stratum_target): Remove the target op.
1012 (class process_target): Add the target op.
1013 (target_emit_ops): Update the macro.
1014 * target.cc (process_target::emit_ops): Define.
1015
1016 Update the derived classes and callers below.
1017
1018 * linux-low.cc (linux_target_ops): Update.
1019 (linux_emit_ops): Turn into ...
1020 (linux_process_target::emit_ops): ... this.
1021 * linux-low.h (class linux_process_target): Update.
1022 * lynx-low.cc (lynx_target_ops): Update.
1023 * nto-low.cc (nto_target_ops): Update.
1024 * win32-low.cc (win32_target_ops): Update.
1025
1026 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1027
1028 Turn process_stratum_target's install_fast_tracepoint_jump_pad
1029 and get_min_fast_tracepoint_insn_len ops into methods of
1030 process_target.
1031
1032 * target.h (struct process_stratum_target): Remove the target ops.
1033 (class process_target): Add the target ops. Also add
1034 'supports_fast_tracepoints'.
1035 (target_supports_fast_tracepoints): Update the macro.
1036 (target_get_min_fast_tracepoint_insn_len): Update the macro.
1037 (install_fast_tracepoint_jump_pad): Update and rename the macro
1038 to ...
1039 (target_install_fast_tracepoint_jump_pad): ... this.
1040 * target.cc (process_target::supports_fast_tracepoints): Define.
1041 (process_target::install_fast_tracepoint_jump_pad): Define.
1042 (process_target::get_min_fast_tracepoint_insn_len): Define.
1043
1044 Update the derived classes and callers below.
1045
1046 * tracepoint.cc (install_fast_tracepoint): Update.
1047 * linux-low.cc (linux_target_ops): Update.
1048 (linux_process_target::supports_fast_tracepoints): Define.
1049 (linux_install_fast_tracepoint_jump_pad): Turn into ...
1050 (linux_process_target::install_fast_tracepoint_jump_pad): ... this.
1051 (linux_get_min_fast_tracepoint_insn_len): Turn into ...
1052 (linux_process_target::get_min_fast_tracepoint_insn_len): ... this.
1053 * linux-low.h (class linux_process_target): Update.
1054 * lynx-low.cc (lynx_target_ops): Update.
1055 * nto-low.cc (nto_target_ops): Update.
1056 * win32-low.cc (win32_target_ops): Update.
1057
1058 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1059
1060 Turn process_stratum_target's stabilize_threads op into a
1061 method of process_target.
1062
1063 * target.h (struct process_stratum_target): Remove the target op.
1064 (class process_target): Add the target op.
1065 (target_stabilize_threads): Update the macro.
1066 * target.cc (process_target::stabilize_threads): Define.
1067
1068 Update the derived classes and callers below.
1069
1070 * server.cc (handle_status): Update.
1071 * tracepoint.cc (cmd_qtdp): Update.
1072 (cmd_qtstart): Update.
1073 * linux-low.cc (linux_target_ops): Update.
1074 (linux_stabilize_threads): Turn into ...
1075 (linux_process_target::stabilize_threads): ... this.
1076 (linux_wait_1): Update.
1077 * linux-low.h (class linux_process_target): Update.
1078 * lynx-low.cc (lynx_target_ops): Update.
1079 * nto-low.cc (nto_target_ops): Update.
1080 * win32-low.cc (win32_target_ops): Update.
1081
1082 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1083
1084 Turn process_stratum_target's pause_all and unpause_all ops
1085 into methods of process_target.
1086
1087 * target.h (struct process_stratum_target): Remove the target ops.
1088 (class process_target): Add the target ops.
1089 (pause_all): Update the macro and rename to...
1090 (target_pause_all): ... this.
1091 (unpause_all): Update the macro and rename to...
1092 (target_unpause_all): ... this.
1093 * target.cc (process_target::pause_all): Define.
1094 (process_target::unpause_all): Define.
1095
1096 Update the derived classes and callers below.
1097
1098 * server.cc (handle_status): Update.
1099 * tracepoint.cc (clear_installed_tracepoints): Update.
1100 (cmd_qtdp): Update.
1101 (cmd_qtstart): Update.
1102 (stop_tracing): Update.
1103 (cmd_qtstatus): Update.
1104 (upload_fast_traceframes): Update.
1105 (run_inferior_command): Update.
1106 * linux-low.cc (linux_target_ops): Update.
1107 (linux_pause_all): Turn into ...
1108 (linux_process_target::pause_all): ... this.
1109 (linux_unpause_all): Turn into ...
1110 (linux_process_target::unpause_all): ... this.
1111 (linux_process_target::prepare_to_access_memory): Update.
1112 (linux_process_target::done_accessing_memory): Update.
1113 * linux-low.h (class linux_process_target): Update.
1114 * lynx-low.cc (lynx_target_ops): Update.
1115 * nto-low.cc (nto_target_ops): Update.
1116 * win32-low.cc (win32_target_ops): Update.
1117
1118 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1119
1120 Turn process_stratum_target's get_tib_address op into a method of
1121 process_target.
1122
1123 * target.h (struct process_stratum_target): Remove the target op.
1124 (class process_target): Add the target op. Also add
1125 'supports_get_tib_address'.
1126 * target.cc (process_target::get_tib_address): Define.
1127 (process_target::supports_get_tib_address): Define.
1128
1129 Update the derived classes and callers below.
1130
1131 * server.cc (handle_query): Update.
1132 * linux-low.cc (win32_target_ops): Update.
1133 * lynx-low.cc (lynx_target_ops): Update.
1134 * nto-low.cc (nto_target_ops): Update.
1135 * win32-low.cc (win32_target_ops): Update.
1136 (win32_process_target::supports_get_tib_address): Define.
1137 (win32_get_tib_address): Turn into ...
1138 (win32_process_target::get_tib_address): ... this.
1139 * win32-low.h (class win32_process_target): Update.
1140
1141 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1142
1143 Turn process_stratum_target's thread_stopped op into a method of
1144 process_target.
1145
1146 * target.h (struct process_stratum_target): Remove the target op.
1147 (class process_target): Add the target op. Also add
1148 'supports_thread_stopped'.
1149 (target_thread_stopped): Update the macro.
1150 * target.cc (process_target::thread_stopped): Define.
1151 (process_target::supports_thread_stopped): Define.
1152 (prepare_to_access_memory): Update.
1153
1154 Update the derived classes and callers below.
1155
1156 * server.cc (queue_stop_reply_callback): Update.
1157 * linux-low.cc (linux_target_ops): Update.
1158 (linux_process_target::supports_thread_stopped): Define.
1159 (linux_thread_stopped): Turn into ...
1160 (linux_process_target::thread_stopped): ... this.
1161 * linux-low.h (class linux_process_target): Update.
1162 * lynx-low.cc (lynx_target_ops): Update.
1163 * nto-low.cc (nto_target_ops): Update.
1164 * win32-low.cc (win32_target_ops): Update.
1165
1166 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1167
1168 Turn process_stratum_target's read_pc and write_pc ops into
1169 methods of process_target.
1170
1171 * target.h (struct process_stratum_target): Remove the target ops.
1172 (class process_target): Add the target ops.
1173 * target.cc (process_target::read_pc): Define.
1174 (process_target::write_pc): Define.
1175
1176 Update the derived classes and callers below.
1177
1178 * regcache.cc (regcache_read_pc): Update.
1179 (regcache_write_pc): Update.
1180 * linux-low.cc (linux_target_ops): Update.
1181 (linux_read_pc): Turn into ...
1182 (linux_process_target::read_pc): ... this.
1183 (linux_write_pc): Turn into ...
1184 (linux_process_target::write_pc): ... this.
1185 * linux-low.h (class linux_process_target): Update.
1186 * lynx-low.cc (lynx_target_ops): Update.
1187 * nto-low.cc (nto_target_ops): Update.
1188 * win32-low.cc (win32_target_ops): Update.
1189
1190 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1191
1192 Turn process_stratum_target's supports_tracepoints op into a
1193 method of process_target.
1194
1195 * target.h (struct process_stratum_target): Remove the target op.
1196 (class process_target): Add the target op.
1197 (target_supports_tracepoints): Update the macro.
1198 * target.cc (process_target::supports_tracepoints): Define.
1199
1200 Update the derived classes and callers below.
1201
1202 * linux-low.cc (linux_target_ops): Update.
1203 (linux_supports_tracepoints): Turn into ...
1204 (linux_process_target::supports_tracepoints): ... this.
1205 * linux-low.h (class linux_process_target): Update.
1206 * lynx-low.cc (lynx_target_ops): Update.
1207 * nto-low.cc (nto_target_ops): Update.
1208 * win32-low.cc (win32_target_ops): Update.
1209
1210 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1211
1212 Turn process_stratum_target's process_qsupported op into a method
1213 of process_target.
1214
1215 * target.h (struct process_stratum_target): Remove the target op.
1216 (class process_target): Add the target op.
1217 (target_process_qsupported): Update the macro.
1218 * target.cc (process_target::process_qsupported): Define.
1219
1220 Update the derived classes and callers below.
1221
1222 * linux-low.cc (linux_target_ops): Update.
1223 (linux_process_qsupported): Turn into ...
1224 (linux_process_target::process_qsupported): ... this.
1225 * linux-low.h (class linux_process_target): Update.
1226 * lynx-low.cc (lynx_target_ops): Update.
1227 * nto-low.cc (nto_target_ops): Update.
1228 * win32-low.cc (win32_target_ops): Update.
1229
1230 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1231
1232 Turn process_stratum_target's read_loadmap op into a method of
1233 process_target.
1234
1235 * target.h (struct process_stratum_target): Remove the target op.
1236 (class process_target): Add the target op. Also add
1237 'supports_read_loadmap'.
1238 * target.cc (process_target::read_loadmap): Define.
1239 (process_target::supports_read_loadmap): Define.
1240
1241 Update the derived classes and callers below.
1242
1243 * server.cc (handle_qxfer_fdpic): Update.
1244 (handle_query): Update.
1245 * linux-low.cc (linux_target_ops): Update.
1246 (linux_process_target::supports_read_loadmap): Define.
1247 (linux_read_loadmap): Turn into ...
1248 (linux_process_target::read_loadmap): ... this.
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.
1253
1254 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1255
1256 Turn process_stratum_target's core_of_thread op into a method of
1257 process_target.
1258
1259 * target.h (struct process_stratum_target): Remove the target op.
1260 (class process_target): Add the target op.
1261 (target_core_of_thread): Update the macro.
1262 * target.cc (process_target::core_of_thread): Define.
1263
1264 Update the derived classes and callers below.
1265
1266 * linux-low.cc (linux_target_ops): Update.
1267 (linux_process_target::core_of_thread): Define.
1268 * linux-low.h (class linux_process_target): Update.
1269 * lynx-low.cc (lynx_target_ops): Update.
1270 * nto-low.cc (nto_target_ops): Update.
1271 * win32-low.cc (win32_target_ops): Update.
1272
1273 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1274
1275 Turn process_stratum_target's handle_monitor_command op into a
1276 method of process_target.
1277
1278 * target.h (struct process_stratum_target): Remove the target op.
1279 (class process_target): Add the target op.
1280 (target_handle_monitor_command): Update the macro.
1281 * target.cc (process_target::handle_monitor_command): Define.
1282
1283 Update the derived classes and callers below.
1284
1285 * server.cc (handle_query): Update.
1286 * linux-low.cc (linux_target_ops): Update.
1287 (linux_process_target::handle_monitor_command): Define.
1288 * linux-low.h (class linux_process_target): Update.
1289 * lynx-low.cc (lynx_target_ops): Update.
1290 * nto-low.cc (nto_target_ops): Update.
1291 * win32-low.cc (win32_target_ops): Update.
1292
1293 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1294
1295 Turn process_stratum_target's handle_new_gdb_connection op into a
1296 method of process_target.
1297
1298 * target.h (struct process_stratum_target): Remove the target op.
1299 (class process_target): Add the target op.
1300 (target_handle_new_gdb_connection): Update the macro.
1301 * target.cc (process_target::handle_new_gdb_connection): Define.
1302
1303 Update the derived classes and callers below.
1304
1305 * linux-low.cc (linux_target_ops): Update.
1306 (linux_handle_new_gdb_connection): Turn into ...
1307 (linux_process_target::handle_new_gdb_connection): ... this.
1308 * linux-low.h (class linux_process_target): Update.
1309 * lynx-low.cc (lynx_target_ops): Update.
1310 * nto-low.cc (nto_target_ops): Update.
1311 * win32-low.cc (win32_target_ops): Update.
1312
1313 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1314
1315 Turn process_stratum_target's supports_fork_events,
1316 supports_vfork_events, and supports_exec_events ops into methods
1317 of process_target.
1318
1319 * target.h (struct process_stratum_target): Remove the target ops.
1320 (class process_target): Add the target ops.
1321 (target_supports_fork_events): Update the macro.
1322 (target_supports_vfork_events): Update the macro.
1323 (target_supports_exec_events): Update the macro.
1324 * target.cc (process_target::supports_fork_events): Define.
1325 (process_target::supports_vfork_events): Define.
1326 (process_target::supports_exec_events): Define.
1327
1328 Update the derived classes and callers below.
1329
1330 * linux-low.cc (linux_target_ops): Update.
1331 (linux_supports_fork_events): Turn into ...
1332 (linux_process_target::supports_fork_events): ... this.
1333 (linux_supports_vfork_events): Turn into ...
1334 (linux_process_target::supports_vfork_events): ... this.
1335 (linux_supports_exec_events): Turn into ...
1336 (linux_process_target::supports_exec_events): ... this.
1337 * linux-low.h (class linux_process_target): Update.
1338 * lynx-low.cc (lynx_target_ops): Update.
1339 * nto-low.cc (nto_target_ops): Update.
1340 * win32-low.cc (win32_target_ops): Update.
1341
1342 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1343
1344 Turn process_stratum_target's supports_multi_process op into a
1345 method of process_target.
1346
1347 * target.h (struct process_stratum_target): Remove the target op.
1348 (class process_target): Add the target op.
1349 * target.cc (process_target::supports_multi_process): Define.
1350 (target_supports_multi_process): Update.
1351
1352 Update the derived classes and callers below.
1353
1354 * linux-low.cc (linux_target_ops): Update.
1355 (linux_supports_multi_process): Turn into ...
1356 (linux_process_target::supports_multi_process): ... this.
1357 * linux-low.h (class linux_process_target): Update.
1358 * lynx-low.cc (lynx_target_ops): Update.
1359 * nto-low.cc (nto_target_ops): Update.
1360 * win32-low.cc (win32_target_ops): Update.
1361
1362 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1363
1364 Turn process_stratum_target's supports_non_stop, async, and
1365 start_non_stop ops into methods of process_target.
1366
1367 * target.h (struct process_stratum_target): Remove the target ops.
1368 (class process_target): Add the target ops.
1369 (target_supports_non_stop): Update the macro.
1370 (target_async): Update the macro.
1371 (start_non_stop): Remove declaration.
1372 * target.cc (process_target::supports_non_stop): Define.
1373 (process_target::async): Define.
1374 (process_target::start_non_stop): Define.
1375 (start_non_stop): Remove.
1376
1377 Update the derived classes and callers below.
1378
1379 * server.cc (handle_qxfer_siginfo): Update.
1380 (handle_query): Update.
1381 * linux-low.cc (linux_target_ops): Update.
1382 (linux_supports_non_stop): Turn into ...
1383 (linux_process_target::supports_non_stop): ... this.
1384 (linux_async): Turn into ...
1385 (linux_process_target::async): ... this.
1386 (linux_start_non_stop): Turn into ...
1387 (linux_process_target::start_non_stop): ... this.
1388 * linux-low.h (class linux_process_target): Update.
1389 * lynx-low.cc (lynx_target_ops): Update.
1390 * nto-low.cc (nto_target_ops): Update.
1391 (nto_supports_non_stop): Remove; rely on the default behavior
1392 instead.
1393 * win32-low.cc (win32_target_ops): Update.
1394
1395 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1396
1397 Turn process_stratum_target's qxfer_siginfo op into a method of
1398 process_target.
1399
1400 * target.h (struct process_stratum_target): Remove the target op.
1401 (class process_target): Add the target op. Also add
1402 'supports_qxfer_siginfo'.
1403 * target.cc (process_target::qxfer_siginfo): Define.
1404 (process_target::supports_qxfer_siginfo): Define.
1405
1406 Update the derived classes and callers below.
1407
1408 * server.cc (handle_qxfer_siginfo): Update.
1409 (handle_query): Update.
1410 * linux-low.cc (linux_target_ops): Update.
1411 (linux_process_target::supports_qxfer_siginfo): Define.
1412 (linux_xfer_siginfo): Turn into ...
1413 (linux_process_target::qxfer_siginfo): ... this.
1414 * linux-low.h (class linux_process_target): Update.
1415 * lynx-low.cc (lynx_target_ops): Update.
1416 * nto-low.cc (nto_target_ops): Update.
1417 * win32-low.cc (win32_target_ops): Update.
1418
1419 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1420
1421 Turn process_stratum_target's qxfer_osdata op into a method of
1422 process_target.
1423
1424 * target.h (struct process_stratum_target): Remove the target op.
1425 (class process_target): Add the target op. Also add
1426 'supports_qxfer_osdata'.
1427 * target.cc (process_target::qxfer_osdata): Define.
1428 (process_target::supports_qxfer_osdata): Define.
1429
1430 Update the derived classes and callers below.
1431
1432 * server.cc (handle_qxfer_osdata): Update.
1433 (handle_query): Update.
1434 * linux-low.cc (linux_target_ops): Update.
1435 (linux_process_target::supports_qxfer_osdata): Define.
1436 (linux_qxfer_osdata): Turn into ...
1437 (linux_process_target::qxfer_osdata): ... this.
1438 * linux-low.h (class linux_process_target): Update.
1439 * lynx-low.cc (lynx_target_ops): Update.
1440 * nto-low.cc (nto_target_ops): Update.
1441 * win32-low.cc (win32_target_ops): Update.
1442
1443 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1444
1445 Turn process_stratum_target's hostio_last_error op into a
1446 method of process_target.
1447
1448 * target.h (struct process_stratum_target): Remove the target op.
1449 (class process_target): Add the target op.
1450 * target.cc: Add "hostio.h" to includes.
1451 (process_target::hostio_last_error): Define.
1452
1453 Update the derived classes and callers below.
1454
1455 * hostio.cc (hostio_error): Update.
1456 * linux-low.cc: Remove "hostio.h" from includes.
1457 (linux_target_ops): Update.
1458 * lynx-low.cc (lynx_target_ops): Update.
1459 * nto-low.cc (nto_target_ops): Update.
1460 * win32-low.h (class win32_process_target): Update.
1461 * win32-low.cc (win32_target_ops): Update.
1462 (wince_hostio_last_error): Turn into ...
1463 (win32_process_target::hostio_last_error): ... this.
1464
1465 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1466
1467 Turn process_stratum_target's get_tls_address op into a method of
1468 process_target.
1469
1470 * target.h (struct process_stratum_target): Remove the target op.
1471 (class process_target): Add the target op. Also add
1472 'supports_get_tls_address'.
1473 * target.cc (process_target::get_tls_address): Define.
1474 (process_target::supports_get_tls_address): Define.
1475
1476 Update the derived classes and callers below.
1477
1478 * server.cc (handle_query): Update.
1479 * linux-low.cc (linux_target_ops): Update.
1480 (linux_process_target::supports_get_tls_address): Define.
1481 (linux_process_target::get_tls_address): Define.
1482 * linux-low.h (class linux_process_target): Update.
1483 * lynx-low.cc (lynx_target_ops): Update.
1484 * nto-low.cc (nto_target_ops): Update.
1485 * win32-low.cc (win32_target_ops): Update.
1486
1487 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1488
1489 Turn process_stratum_target's read_offsets op into a method of
1490 process_target.
1491
1492 * target.h (struct process_stratum_target): Remove the target op.
1493 (class process_target): Add the target op. Also add
1494 'supports_read_offsets'.
1495 * target.cc (process_target::read_offsets): Define.
1496 (process_target::supports_read_offsets): Define.
1497
1498 Update the derived classes and callers below.
1499
1500 * server.cc (handle_query): Update.
1501 * linux-low.cc (SUPPORTS_READ_OFFSETS): New #define directive.
1502 (linux_target_ops): Update.
1503 (linux_process_target::supports_read_offsets): Define.
1504 (linux_read_offsets): Turn into ...
1505 (linux_process_target::read_offsets): ... this.
1506 * linux-low.h (class linux_process_target): Update.
1507 * lynx-low.cc (lynx_target_ops): Update.
1508 * nto-low.cc (nto_target_ops): Update.
1509 * win32-low.cc (win32_target_ops): Update.
1510
1511 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1512
1513 Turn process_stratum_target's stopped_by_watchpoint and
1514 stopped_data_address ops into methods of process_target.
1515
1516 * target.h (struct process_stratum_target): Remove the target ops.
1517 (class process_target): Add the target ops.
1518 * target.cc (process_target::stopped_by_watchpoint): Define.
1519 (process_target::stopped_data_address): Define.
1520
1521 Update the derived classes and callers below.
1522
1523 * remote-utils.cc (prepare_resume_reply): Update.
1524 * linux-low.cc (linux_target_ops): Update.
1525 (linux_stopped_by_watchpoint): Turn into ...
1526 (linux_process_target::stopped_by_watchpoint): ... this.
1527 (linux_stopped_data_address): Turn into ...
1528 (linux_process_target::stopped_data_address): ... this.
1529 * linux-low.h (class linux_process_target): Update.
1530 * lynx-low.cc (lynx_target_ops): Update.
1531 * nto-low.cc (nto_target_ops): Update.
1532 (nto_stopped_by_watchpoint): Turn into ...
1533 (nto_process_target::stopped_by_watchpoint): ... this.
1534 (nto_stopped_data_address): Turn into ...
1535 (nto_process_target::stopped_data_address): ... this.
1536 * nto-low.h (class nto_process_target): Update.
1537 * win32-low.cc (win32_target_ops): Update.
1538 (win32_stopped_by_watchpoint): Turn into ...
1539 (win32_process_target::stopped_by_watchpoint): ... this.
1540 (win32_stopped_data_address): Turn into ...
1541 (win32_process_target::stopped_data_address): ... this.
1542 * win32-low.h (class win32_process_target): Update.
1543
1544 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1545
1546 Turn process_stratum_target's supports_hardware_single_step op into
1547 a method of process_target.
1548
1549 * target.h (struct process_stratum_target): Remove the target op.
1550 (class process_target): Add the target op.
1551 (target_supports_hardware_single_step): Update the macro.
1552 (target_can_do_hardware_single_step): Remove declaration.
1553 * target.cc (process_target::supports_hardware_single_step): Define.
1554 (target_can_do_hardware_single_step): Remove.
1555
1556 Update the derived classes and callers below.
1557
1558 * linux-low.h (class linux_process_target): Update.
1559 * linux-low.cc (linux_target_ops): Update.
1560 (linux_supports_hardware_single_step): Turn into ...
1561 (linux_process_target::supports_hardware_single_step): ... this.
1562 * lynx-low.h (class lynx_process_target): Update.
1563 * lynx-low.cc (lynx_target_ops): Update.
1564 (lynx_process_target::supports_hardware_single_step): Define.
1565 * nto-low.h (class nto_process_target): Update.
1566 * nto-low.cc (nto_target_ops): Update.
1567 (nto_process_target::supports_hardware_single_step): Define.
1568 * win32-low.h (class win32_process_target): Update.
1569 * win32-low.cc (win32_target_ops): Update.
1570 (win32_process_target::supports_hardware_single_step): Define.
1571
1572 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1573
1574 Turn process_stratum_target's {supports_}stopped_by_hw_breakpoint
1575 ops into methods of process_target.
1576
1577 * target.h (struct process_stratum_target): Remove the target ops.
1578 (class process_target): Add the target ops.
1579 (target_stopped_by_hw_breakpoint): Update the macro.
1580 (target_supports_stopped_by_hw_breakpoint): Update the macro.
1581 * target.cc (process_target::stopped_by_hw_breakpoint): Define.
1582 (process_target::supports_stopped_by_hw_breakpoint): Define.
1583
1584 Update the derived classes and callers below.
1585
1586 * linux-low.cc (linux_target_ops): Update.
1587 (linux_stopped_by_hw_breakpoint): Turn into ...
1588 (linux_process_target::stopped_by_hw_breakpoint): ... this.
1589 (linux_supports_stopped_by_hw_breakpoint): Turn into ...
1590 (linux_process_target::supports_stopped_by_hw_breakpoint): ... this.
1591 * linux-low.h (class linux_process_target): 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
1596 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1597
1598 Turn process_stratum_target's {supports_}stopped_by_sw_breakpoint
1599 ops into methods of process_target.
1600
1601 * target.h (struct process_stratum_target): Remove the target ops.
1602 (class process_target): Add the target ops.
1603 (target_stopped_by_sw_breakpoint): Update the macro.
1604 (target_supports_stopped_by_sw_breakpoint): Update the macro.
1605 * target.cc (process_target::stopped_by_sw_breakpoint): Define.
1606 (process_target::supports_stopped_by_sw_breakpoint): Define.
1607
1608 Update the derived classes and callers below.
1609
1610 * linux-low.cc (linux_target_ops): Update.
1611 (linux_stopped_by_sw_breakpoint): Turn into ...
1612 (linux_process_target::stopped_by_sw_breakpoint): ... this.
1613 (linux_supports_stopped_by_sw_breakpoint): Turn into ...
1614 (linux_process_target::supports_stopped_by_sw_breakpoint): ... this.
1615 * linux-low.h (class linux_process_target): Update.
1616 * lynx-low.cc (lynx_target_ops): Update.
1617 * nto-low.cc (nto_target_ops): Update.
1618 * win32-low.cc (win32_target_ops): Update.
1619
1620 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1621
1622 Turn process_stratum_target's insert_point and remove_point ops
1623 into methods of process_target.
1624
1625 * target.h (struct process_stratum_target): Remove the target ops.
1626 (class process_target): Add the target ops.
1627 * target.cc (process_target::insert_point): Define.
1628 (process_target::remove_point): Define.
1629
1630 Update the derived classes and callers below.
1631
1632 * mem-break.cc (set_raw_breakpoint_at): Update.
1633 (delete_raw_breakpoint): Update.
1634 (uninsert_raw_breakpoint): Update.
1635 (reinsert_raw_breakpoint): Update.
1636 * linux-low.cc (linux_target_ops): Update.
1637 (linux_insert_point): Turn into ...
1638 (linux_process_target::insert_point): ... this.
1639 (linux_remove_point): Turn into ...
1640 (linux_process_target::remove_point): ... this.
1641 * linux-low.h (class linux_process_target): Update.
1642 * lynx-low.cc (lynx_target_ops): Update.
1643 * nto-low.cc (nto_target_ops): Update.
1644 (nto_insert_point): Turn into ...
1645 (nto_process_target::insert_point): ... this.
1646 (nto_remove_point): Turn into ...
1647 (nto_process_target::remove_point): ... this.
1648 * nto-low.h (class nto_process_target): Update.
1649 * win32-low.cc (win32_target_ops): Update.
1650 (win32_insert_point): Turn into ...
1651 (win32_process_target::insert_point): ... this.
1652 (win32_remove_point): Turn into ...
1653 (win32_process_target::remove_point): ... this.
1654 * win32-low.h (class win32_process_target): Update.
1655
1656 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1657
1658 Turn process_stratum_target's supports_z_point_type op into a
1659 method of process_target.
1660
1661 * target.h (struct process_stratum_target): Remove the target op.
1662 (class process_target): Add the target op.
1663 * target.cc (process_target::supports_z_point_type): Define.
1664
1665 Update the derived classes and callers below.
1666
1667 * mem-break.cc (z_type_supported): Update.
1668 * linux-low.cc (linux_target_ops): Update.
1669 (linux_supports_z_point_type): Turn into ...
1670 (linux_process_target::supports_z_point_type): ... this.
1671 * linux-low.h (class linux_process_target): Update.
1672 * lynx-low.cc (lynx_target_ops): Update.
1673 * nto-low.cc (nto_target_ops): Update.
1674 (nto_supports_z_point_type): Turn into ...
1675 (nto_process_target::supports_z_point_type): ... this.
1676 * nto-low.h (class nto_process_target): Update.
1677 * win32-low.cc (win32_target_ops): Update.
1678 (win32_supports_z_point_type): Turn into ...
1679 (win32_process_target::supports_z_point_type): ... this.
1680 * win32-low.h (class win32_process_target): Update.
1681
1682 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1683
1684 Turn process_stratum_target's read_auxv op into a method of
1685 process_target.
1686
1687 * target.h (class process_stratum_target): Remove the target op.
1688 (struct process_target): Add the target op. Also add
1689 'supports_read_auxv'.
1690 * target.cc (process_target::read_auxv): Define.
1691 (process_target::supports_read_auxv): Define.
1692
1693 Update the derived classes and callers below.
1694
1695 * server.cc (handle_qxfer_auxv): Update.
1696 (handle_query): Update.
1697 * linux-low.cc (linux_target_ops): Update.
1698 (linux_process_target::supports_read_auxv): Define.
1699 (linux_read_auxv): Turn into ...
1700 (linux_process_target::read_auxv): ... this.
1701 * linux-low.h (class linux_process_target): Update.
1702 * lynx-low.cc (lynx_target_ops): Update.
1703 * nto-low.cc (nto_target_ops): Update.
1704 (nto_process_target::supports_read_auxv): Define.
1705 (nto_read_auxv): Turn into ...
1706 (nto_process_target::read_auxv): ... this.
1707 * nto-low.h (class nto_process_target): Update.
1708 * win32-low.cc (win32_target_ops): Update.
1709
1710 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1711
1712 Turn process_stratum_target's request_interrupt op into a method of
1713 process_target.
1714
1715 * target.h (struct process_stratum_target): Remove the target op.
1716 (class process_target): Add the target op.
1717
1718 Update the derived classes and callers below.
1719
1720 * remote-utils.cc (putpkt_binary_1): Update.
1721 (input_interrupt): Update.
1722 (getpkt): Update.
1723 * server.cc (handle_v_requests): Update.
1724 * linux-low.cc (linux_target_ops): Update.
1725 (linux_request_interrupt): Turn into ...
1726 (linux_process_target::request_interrupt): ... this.
1727 * linux-low.h (class linux_process_target): Update.
1728 * lynx-low.cc (lynx_target_ops): Update.
1729 (lynx_request_interrupt): Turn into ...
1730 (lynx_process_target::request_interrupt): ... this.
1731 * lynx-low.h (class lynx_process_target): Update.
1732 * nto-low.cc (nto_target_ops): Update.
1733 (nto_request_interrupt): Turn into ...
1734 (nto_process_target::request_interrupt): ... this.
1735 * nto-low.h (class nto_process_target): Update.
1736 * win32-low.cc (win32_target_ops): Update.
1737 (win32_request_interrupt): Turn into ...
1738 (win32_process_target::request_interrupt): ... this.
1739 * win32-low.h (class win32_process_target): Update.
1740
1741 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1742
1743 Turn process_stratum_target's look_up_symbols op into a method of
1744 process_target.
1745
1746 * target.h (struct process_stratum_target): Remove the target op.
1747 (class process_target): Add the target op.
1748 * target.cc (process_target::look_up_symbols): Define.
1749
1750 Update the derived classes and callers below.
1751
1752 * server.cc (handle_query): Update.
1753 * linux-low.cc (linux_target_ops): Update.
1754 (linux_look_up_symbols): Turn into ...
1755 (linux_process_target::look_up_symbols): ... this.
1756 * linux-low.h (class linux_process_target): Update.
1757 * lynx-low.cc (lynx_target_ops): Update.
1758 * nto-low.cc (nto_target_ops): Update.
1759 * win32-low.cc (win32_target_ops): Update.
1760
1761 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1762
1763 Turn process_stratum_target's read_memory and write_memory
1764 ops into methods of process_target.
1765
1766 * target.h (struct process_stratum_target): Remove the target ops.
1767 (class process_target): Add the target ops.
1768
1769 Update the derived classes and callers below.
1770
1771 * linux-aarch32-low.cc (arm_breakpoint_at): Update.
1772 * linux-aarch64-low.cc (aarch64_breakpoint_at): Update.
1773 * linux-arm-low.cc (arm_sigreturn_next_pc): Update.
1774 (arm_get_syscall_trapinfo): Update.
1775 * linux-cris-low.cc (cris_breakpoint_at): Update.
1776 * linux-crisv32-low.cc (cris_breakpoint_at): Update.
1777 * linux-m32r-low.cc (m32r_breakpoint_at): Update.
1778 * linux-mips-low.cc (mips_breakpoint_at): Update.
1779 * linux-nios2-low.cc (nios2_breakpoint_at): Update.
1780 * linux-ppc-low.cc (ppc_breakpoint_at): Update.
1781 * linux-sh-low.cc (sh_breakpoint_at): Update.
1782 * linux-sparc-low.cc (sparc_fill_gregset_to_stack): Update.
1783 (sparc_store_gregset_from_stack): Update.
1784 (sparc_breakpoint_at): Update.
1785 * linux-tic6x-low.cc (tic6x_breakpoint_at): Update.
1786 * linux-tile-low.cc (tile_breakpoint_at): Update.
1787 * linux-x86-low.cc (x86_breakpoint_at): Update.
1788 * linux-xtensa-low.cc (xtensa_breakpoint_at): Update.
1789 * mem-brea.cc (insert_memory_breakpoint): Update.
1790 (validate_inserted_breakpoint): Update.
1791 * target.cc (read_inferior_memory): Update.
1792 (target_write_memory): Update.
1793 * linux-low.cc (linux_target_ops): Update.
1794 (linux_read_memory): Make a wrapper around the read_memory target
1795 op call.
1796 (linux_process_target::read_memory): Rename from linux_read_memory.
1797 (linux_write_memory): Turn into ...
1798 (linux_process_target::write_memory): ... this.
1799 * linux-low.h (class linux_process_target): Update.
1800 * lynx-low.cc (lynx_target_ops): Update.
1801 (lynx_read_memory): Turn into ...
1802 (lynx_process_target::read_memory): ... this.
1803 (lynx_write_memory): Turn into ...
1804 (lynx_process_target::write_memory): ... this.
1805 * lynx-low.h (class lynx_process_target): Update.
1806 * nto-low.cc (nto_target_ops): Update.
1807 (nto_read_memory): Turn into ...
1808 (nto_process_target::read_memory): ... this.
1809 (nto_write_memory): Turn into ...
1810 (nto_process_target::write_memory): ... this.
1811 * nto-low.h (class nto_process_target): Update.
1812 * win32-low.cc (win32_target_ops): Update.
1813 (win32_read_inferior_memory): Turn into ...
1814 (win32_process_target::read_memory): ... this.
1815 (win32_write_inferior_memory): Turn into ...
1816 (win32_process_target::write_memory): ... this.
1817 * win32-low.h (class win32_process_target): Update.
1818
1819 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1820
1821 Turn process_stratum_target's prepare_to_access_memory and
1822 done_accessing_memory ops into methods of process_target.
1823
1824 * target.h (struct process_stratum_target): Remove the target ops.
1825 (class process_target): Add the target ops.
1826 * target.cc (process_target::prepare_to_access_memory): Define.
1827 (process_target::done_accessing_memory): Define.
1828 (prepare_to_access_memory): Update.
1829 (done_accessing_memory): Update.
1830
1831 Update the derived classes and callers below.
1832
1833 * linux-low.cc (linux_target_ops): Update.
1834 (linux_prepare_to_access_memory): Turn into ...
1835 (linux_process_target::prepare_to_access_memory): ... this.
1836 (linux_done_accessing_memory): Turn into ...
1837 (linux_process_target::done_accessing_memory): ... this.
1838 * linux-low.h (class linux_process_target): Update.
1839 * lynx-low.cc (lynx_target_ops): Update.
1840 * nto-low.cc (nto_target_ops): Update.
1841 * win32-low.cc (win32_target_ops): Update.
1842
1843 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1844
1845 Turn process_stratum_target's fetch_registers and store_registers
1846 ops into methods of process_target.
1847
1848 * target.h (struct process_stratum_target): Remove the target ops.
1849 (class process_target): Add the target ops.
1850 (fetch_inferior_registers): Update the macro.
1851 (store_inferior_registers): Update the macro.
1852
1853 Update the derived classes and callers below.
1854
1855 * linux-low.cc (linux_target_ops): Update.
1856 (linux_fetch_registers): Turn into ...
1857 (linux_process_target::fetch_registers): ... this.
1858 (linux_store_registers): Turn into ...
1859 (linux_process_target::store_registers): ... this.
1860 * linux-low.h (class linux_process_target): Update.
1861 * lynx-low.cc (lynx_target_ops): Update.
1862 (lynx_fetch_registers): Turn into ...
1863 (lynx_process_target::fetch_registers): ... this.
1864 (lynx_store_registers): Turn into ...
1865 (lynx_process_target::store_registers): ... this.
1866 * lynx-low.h (class lynx_process_target): Update.
1867 * nto-low.cc (nto_target_ops): Update.
1868 (nto_fetch_registers): Turn into ...
1869 (nto_process_target::fetch_registers): ... this.
1870 (nto_store_registers): Turn into ...
1871 (nto_process_target::store_registers): ... this.
1872 * nto-low.h (class nto_process_target): Update.
1873 * win32-low.cc (win32_target_ops): Update.
1874 (win32_fetch_inferior_registers): Turn into ...
1875 (win32_process_target::fetch_registers): ... this.
1876 (win32_store_inferior_registers): Turn into ...
1877 (win32_process_target::store_registers): ... this.
1878 * win32-low.h (class win32_process_target): Update.
1879
1880 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1881
1882 Turn process_stratum_target's wait op into a method of
1883 process_target.
1884
1885 * target.h (struct process_stratum_target): Remove the target op.
1886 (class process_target): Add the target op.
1887
1888 Update the derived classes and callers below.
1889
1890 * target.cc (target_wait): Update.
1891 * linux-low.cc (linux_target_ops): Update.
1892 (linux_wait): Turn into ...
1893 (linux_process_target::wait): ... this.
1894 * linux-low.h (class linux_process_target): Update.
1895 * lynx-low.cc (lynx_target_ops): Update.
1896 (lynx_wait): Turn into ...
1897 (lynx_process_target::wait): ... this.
1898 * lynx-low.h (class lynx_process_target): Update.
1899 * nto-low.cc (nto_target_ops): Update.
1900 (nto_wait): Turn into ...
1901 (nto_process_target::wait): ... this.
1902 * nto-low.h (class nto_process_target): Update.
1903 * win32-low.cc (win32_target_ops): Update.
1904 (win32_wait): Turn into ...
1905 (win32_process_target::wait): ... this.
1906 (do_initial_child_stuff): Update.
1907 * win32-low.h (class win32_process_target): Update.
1908
1909 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1910
1911 Turn process_stratum_target's resume op into a method of
1912 process_target.
1913
1914 * target.h (struct process_stratum_target): Remove the target op.
1915 (class process_target): Add the target op.
1916
1917 Update the derived classes and callers below.
1918
1919 * server.cc (resume): Update.
1920 * target.cc (target_stop_and_wait): Update.
1921 (target_continue_no_signal): Update.
1922 (target_continue): Update.
1923 * linux-low.cc (linux_target_ops): Update.
1924 (linux_resume): Turn into ...
1925 (linux_process_target::resume): ... this.
1926 * linux-low.h (class linux_process_target): Update.
1927 * lynx-low.cc (lynx_target_ops): Update.
1928 (lynx_resume): Turn into ...
1929 (lynx_process_target::resume): ... this.
1930 * lynx-low.h (class lynx_process_target): Update.
1931 * nto-low.cc (nto_target_ops): Update.
1932 (nto_resume): Turn into ...
1933 (nto_process_target::resume): ... this.
1934 * nto-low.h (class nto_process_target): Update.
1935 * win32-low.cc (win32_target_ops): Update.
1936 (win32_resume): Turn into ...
1937 (win32_process_target::resume): ... this.
1938 (win32_process_target::detach): Update.
1939 (do_initial_child_stuff): Update.
1940 * win32-low.h (class win32_process_target): Update.
1941
1942 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1943
1944 Turn process_stratum_target's thread_alive op into a method of
1945 process_target.
1946
1947 * target.h (struct process_stratum_target): Remove the target op.
1948 (class process_target): Add the target op.
1949 (mythread_alive): Update the macro.
1950
1951 Update the derived classes and callers below.
1952
1953 * linux-low.cc (linux_target_ops): Update.
1954 (linux_thread_alive): Turn into ...
1955 (linux_process_target::thread_alive): ... this.
1956 (wait_for_sigstop): Update.
1957 * linux-low.h (class linux_process_target): Update.
1958 * lynx-low.cc (lynx_target_ops): Update.
1959 (lynx_thread_alive): Turn into ...
1960 (lynx_process_target::thread_alive): ... this.
1961 * lynx-low.h (class lynx_process_target): Update.
1962 * nto-low.cc (nto_target_ops): Update.
1963 (nto_thread_alive): Turn into ...
1964 (nto_process_target::thread_alive): ... this.
1965 * nto-low.h (class nto_process_target): Update.
1966 * win32-low.cc (win32_target_ops): Update.
1967 (win32_thread_alive): Turn into ...
1968 (win32_process_target::thread_alive): ... this.
1969 * win32-low.h (class win32_process_target): Update.
1970
1971 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1972
1973 Turn process_stratum_target's join op into a method of
1974 process_target.
1975
1976 * target.h (struct process_stratum_target): Remove the target op.
1977 (class process_target): Add the target op.
1978 (join_inferior): Update the macro.
1979
1980 Update the derived classes and callers below.
1981
1982 * linux-low.cc (linux_target_ops): Update.
1983 (linux_join): Turn into ...
1984 (linux_process_target::join): ... this.
1985 * linux-low.h (class linux_process_target): Update.
1986 * lynx-low.cc (lynx_target_ops): Update.
1987 (lynx_join): Turn into ...
1988 (lynx_process_target::join): ... this.
1989 * lynx-low.h (class lynx_process_target): Update.
1990 * nto-low.cc (nto_target_ops): Update.
1991 (nto_process_target::join): Define.
1992 * nto-low.h (class nto_process_target): Update.
1993 * win32-low.cc (win32_target_ops): Update.
1994 (win32_join): Turn into ...
1995 (win32_process_target::join): ... this.
1996 * win32-low.h (class win32_process_target): Update.
1997
1998 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1999
2000 Turn process_stratum_target's mourn op into a method of
2001 process_target.
2002
2003 * target.h (struct process_stratum_target): Remove the target op.
2004 (class process_target): Add the target op.
2005
2006 Update the derived classes and callers below.
2007
2008 * target.cc (target_mourn_inferior): Update.
2009 * linux-low.cc (linux_target_ops): Update.
2010 (linux_mourn): Turn into ...
2011 (linux_process_target::mourn): ... this.
2012 (handle_extended_wait): Update.
2013 (linux_process_target::kill): Update.
2014 (linux_process_target::detach): Update.
2015 * linux-low.h (class linux_process_target): Update.
2016 * lynx-low.cc (lynx_target_ops): Update.
2017 (lynx_mourn): Turn into ...
2018 (lynx_process_target::mourn): ... this.
2019 * lynx-low.h (class lynx_process_target): Update.
2020 * nto-low.cc (nto_target_ops): Update.
2021 (nto_mourn): Turn into ...
2022 (nto_process_target::mourn): ... this.
2023 * nto-low.h (class nto_process_target): Update.
2024 * win32-low.cc (win32_target_ops): Update.
2025 (win32_mourn): Turn into ...
2026 (win32_process_target::mourn): ... this.
2027 * win32-low.h (class win32_process_target): Update.
2028
2029 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2030
2031 Turn process_stratum_target's detach op into a method of
2032 process_target.
2033
2034 * target.h (struct process_stratum_target): Remove the target op.
2035 (class process_target): Add the target op.
2036 (detach_inferior): Update the macro.
2037
2038 Update the derived classes and callers below.
2039
2040 * linux-low.cc (linux_target_ops): Update.
2041 (linux_detach): Turn into ...
2042 (linux_process_target::detach): ... this.
2043 * linux-low.h (class linux_process_target): Update.
2044 * lynx-low.cc (lynx_target_ops): Update.
2045 (lynx_detach): Turn into ...
2046 (lynx_process_target::detach): ... this.
2047 * lynx-low.h (class lynx_process_target): Update.
2048 * nto-low.cc (nto_target_ops): Update.
2049 (nto_detach): Turn into ...
2050 (nto_process_target::detach): ... this.
2051 * nto-low.h (class nto_process_target): Update.
2052 * win32-low.cc (win32_target_ops): Update.
2053 (win32_detach): Turn into ...
2054 (win32_process_target::detach): ... this.
2055 * win32-low.h (class win32_process_target): Update.
2056
2057 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2058
2059 Turn process_stratum_target's kill op into a method of
2060 process_target.
2061
2062 * target.h (struct process_stratum_target): Remove the target op.
2063 (class process_target): Add the target op.
2064
2065 Update the derived classes and callers below.
2066
2067 * target.cc (kill_inferior): Update.
2068 * linux-low.cc (linux_target_ops): Update.
2069 (linux_kill): Turn into ...
2070 (linux_process_target::kill): ... this.
2071 * linux-low.h (class linux_process_target): Update.
2072 * lynx-low.cc (lynx_target_ops): Update.
2073 (lynx_kill): Turn into ...
2074 (lynx_process_target::kill): ... this.
2075 * lynx-low.h (class lynx_process_target): Update.
2076 * nto-low.cc (nto_target_ops): Update.
2077 (nto_kill): Turn into ...
2078 (nto_process_target::kill): ... this.
2079 * nto-low.h (class nto_process_target): Update.
2080 * win32-low.cc (win32_target_ops): Update.
2081 (win32_kill): Turn into ...
2082 (win32_process_target::kill): ... this.
2083 * win32-low.h (class win32_process_target): Update.
2084
2085 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2086
2087 Turn process_stratum_target's attach op into a method of
2088 process_target.
2089
2090 * target.h (struct process_stratum_target): Remove the target op.
2091 (class process_target): Add the target op.
2092 (myattach): Update the macro.
2093
2094 Update the derived classes and callers below.
2095
2096 * linux-low.cc (linux_target_ops): Update.
2097 (linux_attach): Turn into ...
2098 (linux_process_target::attach): ... this.
2099 * linux-low.h (class linux_process_target): Update.
2100 * lynx-low.cc (lynx_target_ops): Update.
2101 (lynx_attach): Turn into ...
2102 (lynx_process_target::attach): ... this.
2103 * lynx-low.h (class lynx_process_target): Update.
2104 * nto-low.cc (nto_target_ops): Update.
2105 (nto_attach): Turn into ...
2106 (nto_process_target::attach): ... this.
2107 * nto-low.h (class nto_process_target): Update.
2108 * win32-low.cc (win32_target_ops): Update.
2109 (win32_attach): Turn into ...
2110 (win32_process_target::attach): ... this.
2111 * win32-low.h (class win32_process_target): Update.
2112
2113 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2114
2115 Turn process_stratum_target's post_create_inferior op into a method
2116 of process_target.
2117
2118 * target.h (struct process_stratum_target): Remove the target op.
2119 (class process_target): Add the target op.
2120 (target_post_create_inferior): Update the macro.
2121 * target.cc (process_target::post_create_inferior): Define.
2122
2123 Update the derived classes and callers below.
2124
2125 * linux-low.cc (linux_target_ops): Update.
2126 (linux_post_create_inferior): Turn into ...
2127 (linux_process_target::post_create_inferior): ... this.
2128 * linux-low.h (class linux_process_target): Update.
2129 * lynx-low.cc (lynx_target_ops): Update.
2130 * nto-low.cc (nto_target_ops): Update.
2131 * win32-low.cc (win32_target_ops): Update.
2132
2133 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2134
2135 Turn process_stratum_target's create_inferior op into a method of
2136 process_target.
2137
2138 * target.h (struct process_stratum_target): Remove the target op.
2139 (class process_target): Add the target op.
2140 (create_inferior): Rename the macro to ...
2141 (target_create_inferior): ... this.
2142
2143 Update the derived classes and callers below.
2144
2145 * server.cc (handle_v_run): Update.
2146 (captured_main): Update.
2147 (process_serial_event): Update.
2148 * linux-low.cc (linux_target_ops): Update.
2149 (linux_create_inferior): Turn into ...
2150 (linux_process_target::create_inferior): ... this.
2151 * linux-low.h (class linux_process_target): Update.
2152 * lynx-low.cc (lynx_target_ops): Update.
2153 (lynx_create_inferior): Turn into ...
2154 (lynx_process_target::create_inferior): ... this.
2155 * lynx-low.h (class lynx_process_target): Update.
2156 * nto-low.cc (nto_target_ops): Update.
2157 (nto_create_inferior): Turn into ...
2158 (nto_process_target::create_inferior): ... this.
2159 * nto-low.h (class nto_process_target): Update.
2160 * win32-low.cc (win32_target_ops): Update.
2161 (win32_create_inferior): Turn into ...
2162 (win32_process_target::create_inferior): ... this.
2163 * win32-low.h (class win32_process_target): Update.
2164
2165 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2166
2167 * target.h (class process_target): New class definition.
2168 (struct process_stratum_target) <pt>: New field with type
2169 'process_target*'.
2170 * linux-low.h (class linux_process_target): Define as a derived
2171 class of 'process_target'.
2172 * linux-low.cc (linux_target_ops): Add a linux_process_target*
2173 as the 'pt' field.
2174 * lynx-low.h (class lynx_process_target): Define as a derived
2175 class of 'process_target'.
2176 * lynx-low.cc (lynx_target_ops): Add a lynx_process_target*
2177 as the 'pt' field.
2178 * nto-low.h (class nto_process_target): Define as a derived
2179 class of 'process_target'.
2180 * nto-low.cc (nto_target_ops): Add an nto_process_target*
2181 as the 'pt' field.
2182 * win32-low.h (class win32_process_target): Define as a derived
2183 class of 'process_target'.
2184 * win32-low.cc (win32_target_ops): Add a win32_process_target*
2185 as the 'pt' field.
2186
2187 2020-02-19 Andrew Burgess <andrew.burgess@embecosm.com>
2188
2189 * configure: Regenerate.
2190
2191 2020-02-19 Maciej W. Rozycki <macro@wdc.com>
2192 Andrew Burgess <andrew.burgess@embecosm.com>
2193
2194 * linux-riscv-low.cc: New file.
2195 * Makefile.in (SFILES): Add linux-riscv-low.cc, arch/riscv.c,
2196 and nat/riscv-linux-tdesc.c.
2197 * configure.srv <riscv*-*-linux*> (srv_tgtobj)
2198 (srv_linux_regsets, srv_linux_usrregs, srv_linux_thread_db):
2199 Define.
2200
2201 2020-02-14 Tom Tromey <tom@tromey.com>
2202
2203 * acinclude.m4: Don't include acx_configure_dir.m4.
2204 * Makefile.in (LIBIBERTY_BUILDDIR, GNULIB_BUILDDIR): Update.
2205 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): Remove.
2206 (all, install-only, uninstall, clean-info, clean)
2207 (maintainer-clean): Don't recurse.
2208 (subdir_do, all-lib): Remove.
2209 ($(LIBGNU) $(LIBIBERTY) $(GNULIB_H)): Remove rule.
2210 (GNULIB_H): Remove.
2211 (generated_files): Update.
2212 ($(GNULIB_BUILDDIR)/Makefile): Remove rule.
2213 * configure: Rebuild.
2214 * configure.ac: Don't configure gnulib or libiberty.
2215 (GNULIB): Update.
2216
2217 2020-02-14 Eli Zaretskii <eliz@gnu.org>
2218
2219 * win32-low.c (create_process): Prepend PROGRAM to ARGS when
2220 preparing the command line for CreateProcess.
2221 (win32_create_inferior): Reflect the program name in debugging
2222 output that shows the process and its command line.
2223
2224 2020-02-13 Simon Marchi <simon.marchi@efficios.com>
2225
2226 * Makefile.in: Rename source files from .c to .cc.
2227 * %.c: Rename to %.cc.
2228 * configure.ac: Rename server.c to server.cc.
2229 * configure: Re-generate.
2230
2231 2020-02-13 Simon Marchi <simon.marchi@efficios.com>
2232
2233 * Makefile.in: Rename gdbsupport source files from .c to .cc.
2234
2235 2020-02-12 Hannes Domani <ssbssa@yahoo.de>
2236
2237 * win32-low.c (win32_create_inferior): Set signal_pid.
2238
2239 2020-02-12 Maciej W. Rozycki <macro@wdc.com>
2240 Pedro Alves <palves@redhat.com>
2241
2242 Skip building gdbserver in a cross-configuration.
2243 * configure.srv: Set $gdbserver_host depending on whether $target
2244 is $host. Use $gdbserver_host instead of $host.
2245
2246 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
2247
2248 * configure: Re-generate.
2249
2250 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
2251
2252 * configure: Re-generate.
2253
2254 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
2255
2256 * acinclude.m4: Update warning.m4 path.
2257
2258 2020-02-09 Hannes Domani <ssbssa@yahoo.de>
2259
2260 * win32-low.c (win32_clear_inferiors): Reset siginfo_er.
2261 (handle_exception): Set siginfo_er.
2262 (win32_xfer_siginfo): New function.
2263
2264 2020-02-07 Tom Tromey <tom@tromey.com>
2265 Pedro Alves <palves@redhat.com>
2266
2267 * README: Update build documentation.
2268 * configure.srv: Set UNSUPPORTED if host is unsupported. Check
2269 host, not target.
2270 * configure.ac: Update paths.
2271 * configure: Rebuild.
2272 * acinclude.m4: Update paths.
2273 * Makefile.in: Update include paths.
2274 (depcomp, INCLUDE_DIR, INCGNU, INCSUPPORT, INCLUDE_CFLAGS)
2275 (SFILES, XML_DIR, n, $(GNULIB_BUILDDIR)/Makefile, config.status)
2276 (version-generated.c, stamp-xml, regdat_sh, arch/%-ipa.o)
2277 (gdbsupport/%-ipa.o, %-ipa.o, arch/%.o, gdbsupport/%.o, %.o)
2278 (%-generated.c): Update paths.
2279 * Move entire directory from ../gdb/gdbserver.
2280
2281 2020-01-29 Maciej W. Rozycki <macro@wdc.com>
2282
2283 * configure.srv <i[34567]86-*-mingw*>: Fix whitespace damage.
2284
2285 2020-01-29 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2286
2287 * configure.srv (powerpc*-*-linux*): Use srv_tgtobj in second
2288 assignment instead of srv_linux_obj.
2289
2290 2020-01-28 Hannes Domani <ssbssa@yahoo.de>
2291
2292 * server.c (handle_qxfer_libraries): Write segment-address with
2293 paddress.
2294
2295 2020-01-24 Hannes Domani <ssbssa@yahoo.de>
2296
2297 * Makefile.in (install-strip): New target.
2298 (install_sh, INSTALL_STRIP_PROGRAM, STRIP): New variables.
2299 * aclocal.m4: Regenerate.
2300 * configure: Regenerate.
2301 * configure.ac: Add AM_PROG_INSTALL_STRIP.
2302
2303 2020-01-24 Maciej W. Rozycki <macro@wdc.com>
2304
2305 * Makefile.in (SFILES): Adjust paths to point to real files.
2306 (OBS): Move waitstatus.o to target/waitstatus.o.
2307 (TAGS): Transform paths appropriately.
2308 (%.o): Rename to...
2309 (nat/%.o): ... this pattern rule.
2310 (%.o): Rename to...
2311 (target/%.o): ... this pattern rule.
2312 * configure.srv: Adjust paths throughout to include nat/ prefix
2313 with the revant files.
2314 * configure.ac: Add `nat' and `target' to CONFIG_SRC_SUBDIR.
2315 * configure: Regenerate.
2316
2317 2020-01-24 Maciej W. Rozycki <macro@wdc.com>
2318
2319 * Makefile.in (TAGS): Remove config files from the recipe.
2320
2321 2020-01-14 Tom Tromey <tom@tromey.com>
2322
2323 * configure: Rebuild.
2324 * configure.ac: Remove any checks that were added to common.m4.
2325 * acinclude.m4: Include lib-ld.m4, lib-prefix.m4, and
2326 lib-link.m4.
2327
2328 2020-01-14 Tom Tromey <tom@tromey.com>
2329
2330 * server.h: Include config.h.
2331 * gdbreplay.c: Include config.h.
2332 * configure: Rebuild.
2333 * configure.ac: Don't source common.host.
2334 * acinclude.m4: Update path.
2335 * Makefile.in (INCSUPPORT): New variable.
2336 (INCLUDE_CFLAGS): Add INCSUPPORT.
2337 (SFILES): Update paths.
2338 (version-generated.c): Update path to create-version.sh.
2339 (gdbsupport/%-ipa.o, gdbsupport/%.o): Update paths.
2340
2341 2020-01-14 Tom Tromey <tom@tromey.com>
2342
2343 * configure.ac (LIBS): Use WIN32APILIBS.
2344 (USE_WIN32API): Don't define.
2345 * configure: Rebuild.
2346
2347 2020-01-14 Tom Tromey <tom@tromey.com>
2348
2349 * configure: Rebuild.
2350
2351 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
2352
2353 * Makefile.in (%-generated.c): Remove rule for files from
2354 regformats/i386.
2355
2356 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
2357
2358 * configure: Re-generate.
2359
2360 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
2361
2362 * tracepoint.h (IP_AGENT_EXPORT_FUNC) [!IN_PROCESS_AGENT]:
2363 Define to static.
2364 * tracepoint.c (stop_tracing, flush_trace_buffer,
2365 about_to_request_buffer_space, get_trace_state_variable_value,
2366 set_trace_state_variable_value, gdb_collect): Add declaration.
2367
2368 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
2369
2370 * linux-x86-low.c (x86_linux_regs_info, amd64_emit_eq_goto,
2371 amd64_emit_ne_goto, amd64_emit_lt_goto, amd64_emit_le_goto,
2372 amd64_emit_gt_goto, amd64_emit_ge_goto, amd64_emit_ge_goto,
2373 i386_emit_eq_goto, i386_emit_ne_goto, i386_emit_lt_goto,
2374 i386_emit_le_goto, i386_emit_gt_goto, i386_emit_ge_goto): Make
2375 static.
2376
2377 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
2378
2379 * inferiors.c: Include gdbsupport/common-inferior.h.
2380
2381 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
2382
2383 * hostio-errno.c: Include hostio.h.
2384
2385 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
2386
2387 * Makefile.in (%-generated.c): Make $(regdat_sh) a regular
2388 prerequisite.
2389
2390 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
2391
2392 * linux-arm-tdesc.c: Include linux-arm-tdesc.h.
2393 * linux-arm-tdesc.h: Include arch/arm.h.
2394
2395 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
2396
2397 * linux-aarch64-low.c (aarch64_write_goto_address): Make static.
2398
2399 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
2400
2401 * linux-aarch32-tdesc.c: Include linux-aarch32-tdesc.h.
2402 * linux-aarch64-tdesc.c: Include linux-aarch64-tdesc.h.
2403
2404 2020-01-10 Pedro Alves <palves@redhat.com>
2405
2406 * fork-child.c (post_fork_inferior): Pass target down to
2407 startup_inferior.
2408 * inferiors.c (switch_to_thread): Add process_stratum_target
2409 parameter.
2410 * lynx-low.c (lynx_target_ops): Now a process_stratum_target.
2411 * nto-low.c (nto_target_ops): Now a process_stratum_target.
2412 * linux-low.c (linux_target_ops): Now a process_stratum_target.
2413 * remote-utils.c (prepare_resume_reply): Pass the target to
2414 switch_to_thread.
2415 * target.c (the_target): Now a process_stratum_target.
2416 (done_accessing_memory): Pass the target to switch_to_thread.
2417 (set_target_ops): Ajust to use process_stratum_target.
2418 * target.h (struct target_ops): Rename to ...
2419 (struct process_stratum_target): ... this.
2420 (the_target, set_target_ops): Adjust.
2421 (prepare_to_access_memory): Adjust comment.
2422 * win32-low.c (child_xfer_memory): Adjust to use
2423 process_stratum_target.
2424 (win32_target_ops): Now a process_stratum_target.
2425
2426 2020-01-06 Eli Zaretskii <eliz@gnu.org>
2427 Pedro Alves <palves@redhat.com>
2428
2429 * win32-low.c (get_child_debug_event): Extract the fatal exception
2430 from the exit status and convert to the equivalent Posix signal
2431 number.
2432 (win32_wait): Allow TARGET_WAITKIND_SIGNALLED status as well.
2433 * Makefile.in (OBS, SFILES): Add gdb_wait.[co].
2434
2435 2020-01-01 Hannes Domani <ssbssa@yahoo.de>
2436
2437 * Makefile.in: Use INSTALL_PROGRAM_ENV.
2438
2439 2020-01-01 Joel Brobecker <brobecker@adacore.com>
2440
2441 * server.c (gdbserver_version): Change copyright year to 2020.
2442 * gdbreplay.c (gdbreplay_version): Likewise.
2443
2444 2019-12-19 Christian Biesinger <cbiesinger@google.com>
2445
2446 * configure: Regenerate.
2447 * configure.ac: Quote variable arguments of test.
2448
2449 2019-12-16 Bernd Edlinger <bernd.edlinger@hotmail.de>
2450
2451 * Makefile.in: Fix build with GNU Make 3.81
2452
2453 2019-12-16 Tom Tromey <tromey@adacore.com>
2454
2455 * server.c (get_exec_file): Constify result.
2456
2457 2019-12-10 Christian Biesinger <cbiesinger@google.com>
2458
2459 * Makefile.in: Add safe-strerror.c to gdbreplay and IPA, and change
2460 UNDO_GNULIB_CFLAGS to undo strerror_r instead of strerror.
2461 * config.in: Regenerate.
2462 * configure: Regenerate.
2463 * configure.ac: Don't check for strerror.
2464 * linux-i386-ipa.c (initialize_fast_tracepoint_trampoline_buffer):
2465 Call safe_strerror instead of strerror.
2466 * server.h (strerror): Remove this now-unnecessary declaration.
2467 * tracepoint.c (init_named_socket): Call safe_strerror instead of
2468 strerror.
2469 (gdb_agent_helper_thread): Likewise.
2470 * utils.c (perror_with_name): Likewise.
2471
2472 2019-11-26 Tom Tromey <tom@tromey.com>
2473
2474 * configure, config.in: Rebuild.
2475
2476 2019-11-26 Tom Tromey <tom@tromey.com>
2477
2478 * remote-utils.c (block_unblock_async_io): Use gdb_sigmask.
2479 * linux-low.c (linux_wait_for_event_filtered, linux_async): Use
2480 gdb_sigmask.
2481 * configure, config.in: Rebuild.
2482
2483 2019-11-26 Tom Tromey <tom@tromey.com>
2484
2485 * Makefile.in (PTHREAD_CFLAGS, PTHREAD_LIBS): New variables.
2486 (INTERNAL_CFLAGS_BASE): Use PTHREAD_CFLAGS.
2487 (GDBSERVER_LIBS): Use PTHREAD_LIBS.
2488 * acinclude.m4: Include ax_pthread.m4.
2489 * config.in, configure: Rebuild.
2490
2491 2019-11-26 Christian Biesinger <cbiesinger@google.com>
2492
2493 * debug.c (debug_set_output): Call safe_strerror instead of
2494 strerror.
2495 * linux-low.c (attach_proc_task_lwp_callback): Likewise.
2496 (linux_kill_one_lwp): Likewise.
2497 (linux_detach_one_lwp): Likewise.
2498 (linux_wait_for_event_filtered): Likewise.
2499 (store_register): Likewise.
2500 * lynx-low.c (lynx_attach): Likewise.
2501 * mem-break.c (insert_memory_breakpoint): Likewise.
2502 (remove_memory_breakpoint): Likewise.
2503 (delete_fast_tracepoint_jump): Likewise.
2504 (set_fast_tracepoint_jump): Likewise.
2505 (uninsert_fast_tracepoint_jumps_at): Likewise.
2506 (reinsert_fast_tracepoint_jumps_at): Likewise.
2507 * nto-low.c (nto_xfer_memory): Likewise.
2508 (nto_resume): Likewise.
2509
2510 2019-11-20 Luis Machado <luis.machado@linaro.org>
2511
2512 * linux-aarch64-low.c (is_sve_tdesc): Check against target feature
2513 instead of register count.
2514 * tdesc.c (tdesc_contains_feature): New function.
2515 * tdesc.h (tdesc_contains_feature): New prototype.
2516
2517 2019-11-15 Christian Biesinger <cbiesinger@google.com>
2518
2519 * Makefile.in: Add safe-strerror.c.
2520 * configure: Regenerate.
2521 * configure.ac: Don't source common.host.
2522
2523 2019-11-15 Christian Biesinger <cbiesinger@google.com>
2524
2525 * config.in: Regenerate.
2526 * configure: Regenerate.
2527
2528 2019-11-12 Andrew Burgess <andrew.burgess@embecosm.com>
2529
2530 * ax.c (ax_printf): Handle size_t_arg.
2531
2532 2019-11-06 Christian Biesinger <cbiesinger@google.com>
2533
2534 * linux-tdep.c (linux_info_proc): Use strtok_r instead of strtok.
2535 * mi/mi-main.c (output_cores): Likewise.
2536 * nat/linux-osdata.c (linux_xfer_osdata_cpus): Likewise.
2537 (linux_xfer_osdata_modules): Likewise.
2538 * remote.c (register_remote_support_xml): Likewise.
2539 * sparc64-tdep.c (adi_is_addr_mapped): Likewise.
2540 * xml-syscall.c (syscall_create_syscall_desc): Likewise.
2541
2542 2019-11-01 Christian Biesinger <cbiesinger@google.com>
2543
2544 * configure: Regenerate.
2545 * configure.ac: Remove check for strerror_r.
2546
2547 2019-10-31 Christian Biesinger <cbiesinger@google.com>
2548
2549 * config.in: Regenerate.
2550 * configure: Regenerate.
2551 * configure.ac: Also check for strerror_r.
2552
2553 2019-10-31 Christian Biesinger <cbiesinger@google.com>
2554
2555 * ax.h (debug_agent): Remove duplicate declaration.
2556
2557 2019-10-26 Tom de Vries <tdevries@suse.de>
2558
2559 * linux-aarch64-low.c: Fix typos in comments.
2560 * linux-arm-low.c: Same.
2561 * linux-low.c: Same.
2562 * linux-ppc-low.c: Same.
2563 * proc-service.c: Same.
2564 * regcache.h: Same.
2565 * server.c: Same.
2566 * tracepoint.c: Same.
2567 * win32-low.c: Same.
2568
2569 2019-10-25 Tom Tromey <tromey@adacore.com>
2570
2571 * utils.c (xstrdup): Remove.
2572
2573 2019-10-23 Tom Tromey <tom@tromey.com>
2574
2575 * configure, config.in: Rebuild.
2576
2577 2019-10-23 Tom Tromey <tom@tromey.com>
2578
2579 * configure: Rebuild.
2580 * acinclude.m4: Use m4_include, not sinclude.
2581
2582 2019-10-17 Tom Tromey <tromey@adacore.com>
2583
2584 * configure: Rebuild.
2585 * configure.ac: Use AC_CONFIG_HEADERS. Create stamp-h there, not
2586 in AC_CONFIG_FILES invocation.
2587 * Makefile.in (stamp-h, Makefile): Use new-style config.status
2588 invocation.
2589
2590 2019-10-16 Christian Biesinger <cbiesinger@google.com>
2591
2592 * server.c: Include xml-builtin.h.
2593 (get_xml_features): Don't declare xml_builtins here.
2594
2595 2019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
2596
2597 * Makefile.in: Remove references to vec-ipa.o.
2598
2599 2019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
2600
2601 * Makefile.in: Remove references to vec.c.
2602
2603 2019-10-02 Christian Biesinger <cbiesinger@google.com>
2604
2605 * server.c (server_waiting): Change to bool.
2606 (extended_protocol): Likewise.
2607 (response_needed): Likewise.
2608 (exit_requested): Likewise.
2609 (run_once): Likewise.
2610 (report_no_resumed): Likewise.
2611 (non_stop): Likewise.
2612 (disable_packet_vCont): Likewise.
2613 (disable_packet_Tthread): Likewise.
2614 (disable_packet_qC): Likewise.
2615 (disable_packet_qfThreadInfo): Likewise.
2616 (handle_general_set): Update.
2617 (handle_detach): Update.
2618 (handle_monitor_command): Update.
2619 (handle_query): Update.
2620 (captured_main): Update.
2621 (process_serial_event): Update.
2622 * server.h (server_waiting): Change to bool.
2623 (disable_packet_vCont): Likewise.
2624 (disable_packet_Tthread): Likewise.
2625 (disable_packet_qC): Likewise.
2626 (disable_packet_qfThreadInfo): Likewise.
2627 (run_once): Likewise.
2628 (non_stop): Likewise.
2629 * target.c (target_stop_and_wait): Update.
2630
2631 2019-10-02 Tom Tromey <tromey@adacore.com>
2632
2633 * Makefile.in (SFILES): Add common-inferior.c.
2634 (OBS): Add common-inferior.o.
2635 * server.c (startup_with_shell): Don't define.
2636
2637 2019-10-02 Andrew Burgess <andrew.burgess@embecosm.com>
2638
2639 * linux-low.c (linux_low_read_btrace): Update for change to
2640 std::vector.
2641
2642 2019-09-20 Christian Biesinger <cbiesinger@google.com>
2643
2644 * debug.c (debug_threads): Remove comment in favor of the header.
2645 * debug.h (using_threads): Add declaration.
2646 (debug_threads): Add comment.
2647 * linux-aarch64-low.c: Include debug.h and remove declaration of
2648 debug_threads.
2649 * nto-low.c: Likewise.
2650 * remote-utils.c: Likewise.
2651 * thread-db.c: Likewise.
2652
2653 2019-09-20 Ulrich Weigand <uweigand@de.ibm.com>
2654
2655 * configure.srv (ipa_ppc_linux_regobj): Remove powerpc-cell32l-ipa.o
2656 and powerpc-cell64l-ipa.o.
2657 (powerpc*-*-linux*): Remove powerpc-cell32l.o and powerpc-cell64l.o
2658 from srv_regobj. Remove rs6000/powerpc-cell32l.xml and
2659 rs6000/powerpc-cell64l.xml from srv_xmlfiles.
2660 (spu*-*-*): Remove.
2661
2662 * spu-low.c: Remove file.
2663
2664 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Remove.
2665 (parse_spufs_run): Remove.
2666 (ppc_get_pc): Remove Cell/B.E. support.
2667 (ppc_set_pc): Likewise.
2668 (ppc_breakpoint_at): Likewise.
2669 (ppc_arch_setup): Likewise.
2670 (ppc_get_ipa_tdesc_idx): Do not handle tdesc_powerpc_cell64l or
2671 tdesc_powerpc_cell32l.
2672 (initialize_low_arch): Do not call init_registers_powerpc_cell64l
2673 or init_registers_powerpc_cell32l.
2674 * linux-ppc-ipa.c (get_ipa_tdesc): Do not handle PPC_TDESC_CELL.
2675 (initialize_low_tracepoint): Do not call init_registers_powerpc_cell64l
2676 or init_registers_powerpc_cell32l.
2677 * linux-ppc-tdesc-init.h (PPC_TDESC_CELL): Mark as unused.
2678 (init_registers_powerpc_cell32l): Remove prototype.
2679 (init_registers_powerpc_cell64l): Likewise.
2680
2681 * target.h (struct target_ops): Remove qxfer_spu member.
2682 * server.c (handle_qxfer_spu): Remove.
2683 (qxfer_packets): Remove entry for "spu".
2684 (handle_query): No longer support qXfer:spu:read or qXfer:spu:write.
2685 * linux-low.c (SPUFS_MAGIC): Remove.
2686 (spu_enumerate_spu_ids): Remove.
2687 (linux_qxfer_spu): Remove.
2688 (linux_target_ops): Remove qxfer_spu member.
2689 * lynx-low.c (lynx_target_ops): Remove qxfer_spu member.
2690 * nto-low.c (nto_target_ops): Remove qxfer_spu member.
2691 * win32-low.c (win32_target_ops): Remove qxfer_spu member.
2692
2693 2019-08-23 Sergio Durigan Junior <sergiodj@redhat.com>
2694
2695 * Makefile.in (SFILES): Add 'gdbsupport/gdb-dlfcn.c'.
2696 (OBS): Add 'gdbsupport/gdb-dlfcn.o'.
2697 * config.in: Regenerate.
2698 * configure: Regenerate.
2699
2700 2019-08-15 Tom Tromey <tromey@adacore.com>
2701
2702 * target.c (target_write_memory): Use gdb::byte_vector.
2703
2704 2019-08-15 Tom Tromey <tromey@adacore.com>
2705
2706 * tracepoint.c (write_inferior_data_pointer)
2707 (write_inferior_integer, write_inferior_int8)
2708 (write_inferior_uinteger, m_tracepoint_action_download)
2709 (r_tracepoint_action_download, x_tracepoint_action_download)
2710 (l_tracepoint_action_download, clear_inferior_trace_buffer)
2711 (download_agent_expr, download_tracepoint_1)
2712 (download_trace_state_variables, upload_fast_traceframes): Update.
2713 * server.c (gdb_write_memory): Update.
2714 * remote-utils.c (relocate_instruction): Update.
2715 * proc-service.c (ps_pdwrite): Update.
2716 * mem-break.c (remove_memory_breakpoint)
2717 (delete_fast_tracepoint_jump, set_fast_tracepoint_jump)
2718 (uninsert_fast_tracepoint_jumps_at)
2719 (reinsert_fast_tracepoint_jumps_at): Update.
2720 * linux-x86-low.c (append_insns)
2721 (i386_install_fast_tracepoint_jump_pad)
2722 (amd64_write_goto_address, i386_write_goto_address): Update.
2723 * linux-s390-low.c (append_insns, s390_write_goto_address):
2724 Update.
2725 * linux-ppc-low.c (ppc_relocate_instruction)
2726 (ppc_install_fast_tracepoint_jump_pad, emit_insns)
2727 (ppc_write_goto_address): Update.
2728 * linux-aarch64-low.c (append_insns): Update.
2729 * target.h (struct target_ops): Update.
2730 (write_inferior_memory): Don't declare.
2731 * target.c (target_write_memory): Rename from
2732 write_inferior_memory. Remove old target_write_memory.
2733
2734 2019-08-15 Tom Tromey <tromey@adacore.com>
2735
2736 * target.c (write_inferior_memory): Use std::vector.
2737
2738 2019-08-06 Frank Ch. Eigler <fche@redhat.com>
2739
2740 PR build/24886
2741 * configure.ac: Drop enable-libmcheck support.
2742 * configure, config.in: Rebuild.
2743 * acinclude.m4: Don't include it.
2744
2745 2019-07-19 Alan Hayward <alan.hayward@arm.com>
2746
2747 * configure.srv: Remove Arm xml files.
2748
2749 2019-07-19 Alan Hayward <alan.hayward@arm.com>
2750
2751 * configure.srv: Add new files. Remove xml generated files.
2752 * linux-aarch32-low.c (initialize_low_arch_aarch32): Don't init
2753 registers.
2754 * linux-aarch32-low.h (tdesc_arm_with_neon): Remove.
2755 * linux-aarch32-tdesc.c: New file.
2756 * linux-aarch32-tdesc.h: New file.
2757 * linux-aarch64-low.c (aarch64_arch_setup): Call aarch32_linux_read_description.
2758 * linux-arm-low.c (init_registers_arm, tdesc_arm)
2759 (init_registers_arm_with_iwmmxt, tdesc_arm_with_iwmmxt)
2760 (init_registers_arm_with_vfpv2, tdesc_arm_with_vfpv2)
2761 (init_registers_arm_with_vfpv3, tdesc_arm_with_vfpv3): Remove.
2762 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
2763 (arm_store_vfpregset): Call arm_linux_get_tdesc_fp_type.
2764 (arm_read_description): Call arm_linux_read_description.
2765 (initialize_low_arch): Don't init registers.
2766 * linux-arm-tdesc.c: New file.
2767 * linux-arm-tdesc.h: New file.
2768
2769 2019-07-10 Alan Hayward <alan.hayward@arm.com>
2770
2771 * linux-arm-low.c (arm_fill_wmmxregset, arm_store_wmmxregset):
2772 Move counter inside for.
2773 (arm_read_description): Check ptrace earlier.
2774 (arm_arch_setup): Call arm_linux_init_hwbp_cap here.
2775
2776 2019-07-09 Tom Tromey <tom@tromey.com>
2777
2778 * configure: Rebuild.
2779 * configure.ac: Change common to gdbsupport.
2780 * acinclude.m4: Change common to gdbsupport.
2781 * Makefile.in (SFILES, OBS, GDBREPLAY_OBS, IPA_OBJS)
2782 (version-generated.c, gdbsupport/%-ipa.o, gdbsupport/%.o): Change
2783 common to gdbsupport.
2784 * ax.c, event-loop.c, fork-child.c, gdb_proc_service.h,
2785 gdbreplay.c, gdbthread.h, hostio-errno.c, hostio.c, i387-fp.c,
2786 inferiors.c, inferiors.h, linux-aarch64-tdesc-selftest.c,
2787 linux-amd64-ipa.c, linux-i386-ipa.c, linux-low.c,
2788 linux-tic6x-low.c, linux-x86-low.c, linux-x86-tdesc-selftest.c,
2789 linux-x86-tdesc.c, lynx-i386-low.c, lynx-low.c, mem-break.h,
2790 nto-x86-low.c, regcache.c, regcache.h, remote-utils.c, server.c,
2791 server.h, spu-low.c, symbol.c, target.h, tdesc.c, tdesc.h,
2792 thread-db.c, tracepoint.c, win32-i386-low.c, win32-low.c: Change
2793 common to gdbsupport.
2794
2795 2019-07-04 Alan Hayward <alan.hayward@arm.com>
2796
2797 * linux-aarch32-low.c (arm_read_description, arm_regsets): Use new
2798 defines.
2799 * linux-arm-low.c (arm_read_description, arm_regsets): Likewise.
2800
2801 2019-07-04 Alan Hayward <alan.hayward@arm.com>
2802
2803 * configure.srv: Remove legacy xml.
2804 * linux-aarch64-low.c (initialize_low_arch): Remove
2805 initialize_low_tdesc call.
2806 * linux-aarch64-tdesc-selftest.c: Remove file.
2807 * linux-aarch64-tdesc.h (initialize_low_tdesc): Remove.
2808 * linux-x86-low.c (initialize_low_arch): Remove
2809 initialize_low_tdesc call.
2810 * linux-x86-tdesc-selftest.c: Remove file.
2811 * linux-x86-tdesc.h (initialize_low_tdesc): Remove.
2812
2813 2019-06-20 Tom de Vries <tdevries@suse.de>
2814
2815 * linux-s390-ipa.c (get_ipa_tdesc)[!__s390x__]: Use
2816 s390_te_linux64_ft_collect_regmap for S390_TDESC_GS.
2817
2818 2019-06-19 Tom de Vries <tdevries@suse.de>
2819
2820 * debug.h (debug_write): Change return type to ssize_t.
2821 * debug.c (debug_write): Same.
2822
2823 2019-06-14 Tom Tromey <tom@tromey.com>
2824
2825 * configure.ac: Use new path to gnulib.
2826 * configure: Rebuild.
2827 * Makefile.in (INCGNU, $(GNULIB_BUILDDIR)/Makefile): Use new path
2828 to gnulib.
2829
2830 2019-06-11 Tom Tromey <tom@tromey.com>
2831
2832 * Makefile.in (SFILES): Add alloc.c.
2833 (OBS): Add alloc.o.
2834 (IPA_OBJS): Add alloc-ipa.o.
2835 (alloc-ipa.o): New target.
2836 (%.o: ../%.c): New pattern rule.
2837
2838 2019-06-10 Tom Tromey <tromey@adacore.com>
2839
2840 * remote-utils.c (look_up_one_symbol, relocate_instruction): Don't
2841 end warning with a newline.
2842 * linux-s390-low.c (s390_get_wordsize): Don't end warning with a
2843 newline.
2844 * thread-db.c (attach_thread): Don't end warning with a newline.
2845 (thread_db_notice_clone): Likewise.
2846 * tracepoint.c (gdb_agent_helper_thread): Don't end warning with a
2847 newline.
2848 * linux-x86-low.c (x86_get_min_fast_tracepoint_insn_len): Don't
2849 end warning with a newline.
2850
2851 2019-06-04 Pedro Alves <palves@redhat.com>
2852
2853 * server.c (captured_main): Use make_unique_xstrdup.
2854
2855 2019-06-02 Tom Tromey <tom@tromey.com>
2856
2857 * gdbreplay.c (fromhex): Remove.
2858 * Makefile.in (GDBREPLAY_OBS): Add rsp-low.o.
2859
2860 2019-05-29 Tom Tromey <tromey@adacore.com>
2861
2862 * configure: Rebuild.
2863
2864 2019-05-06 Kevin Buettner <kevinb@redhat.com>
2865
2866 * linux-x86-low.c (x86_fill_gregset): Don't compile 64-bit
2867 sign extension code on 32-bit builds.
2868
2869 2019-05-03 Eli Zaretskii <eliz@gnu.org>
2870
2871 * remote-utils.c:
2872 * gdbreplay.c [USE_WIN32API]: Remove the _WIN32_WINNT override.
2873
2874 2019-04-19 Tom Tromey <tom@tromey.com>
2875
2876 * server.c (struct vstop_notif): Derive from notif_event.
2877 <base>: Remove.
2878 (queue_stop_reply): Update.
2879 (remove_all_on_match_ptid): Change type. Rewrite.
2880 (discard_queued_stop_replies): Rewrite.
2881 (in_queued_stop_replies_ptid): Change type.
2882 (in_queued_stop_replies): Rewrite.
2883 (notif_stop): Update.
2884 (queue_stop_reply_callback): Update.
2885 (captured_main): Don't call initialize_notif.
2886 (push_stop_notification): Update.
2887 * notif.c (notif_write_event, handle_notif_ack)
2888 (notif_event_enque, notif_push): Update.
2889 (notif_event_xfree, initialize_notif): Remove.
2890 * notif.h (struct notif_event): Include <list>, not
2891 "common/queue.h".
2892 (struct notif_server) <queue>: Now a std::list.
2893 (notif_event_p): Remove typedef.
2894 (initialize_notif): Don't declare.
2895 (struct notif_event): Add virtual destructor.
2896
2897 2019-04-17 Alan Hayward <alan.hayward@arm.com>
2898
2899 * ax.c (ax_vdebug): Call debug_printf.
2900 * debug.c (debug_write): New function.
2901 * debug.h (debug_write): New declaration.
2902 * linux-low.c (sigchld_handler): Call debug_write.
2903
2904 2019-04-17 Alan Hayward <alan.hayward@arm.com>
2905
2906 * debug.c (debug_set_output): New function.
2907 (debug_vprintf): Send output to debug_file.
2908 (debug_flush): Likewise.
2909 * debug.h (debug_set_output): New declaration.
2910 * server.c (handle_monitor_command): Add debug-file option.
2911 (captured_main): Likewise.
2912
2913 2019-04-17 Alan Hayward <alan.hayward@arm.com>
2914
2915 * debug.c (remote_debug): Add definition.
2916 * debug.h (remote_debug): Add declaration.
2917 * hostio.c (remote_debug): Remove declaration.
2918 * remote-utils.c (struct ui_file): Likewise.
2919 (remote_debug): Likewise.
2920 * remote-utils.h (remote_debug): Likewise,
2921 * server.c (remote_debug): Remove definition.
2922
2923 2019-04-10 Kevin Buettner <kevinb@redhat.com>
2924
2925 * linux-x86-low.c (x86_fill_gregset): Sign extend EAX value
2926 when using a 64-bit gdbserver.
2927
2928 2019-04-09 Tom Tromey <tromey@adacore.com>
2929
2930 * linux-low.c (select_event_lwp): Use find_thread_in_random.
2931
2932 2019-04-08 Tom Tromey <tom@tromey.com>
2933
2934 * linux-low.c (linux_detach_one_lwp): Replace throw_exception with
2935 throw.
2936 (linux_resume_one_lwp): Likewise.
2937
2938 2019-04-08 Tom Tromey <tom@tromey.com>
2939
2940 * gdbreplay.c: Update.
2941 * linux-low.c: Update.
2942 * server.c: Update.
2943
2944 2019-04-08 Tom Tromey <tom@tromey.com>
2945
2946 * server.c: Use C++ exception handling.
2947 * linux-low.c: Use C++ exception handling.
2948 * gdbreplay.c: Use C++ exception handling.
2949
2950 2019-04-08 Tom Tromey <tom@tromey.com>
2951
2952 * server.c (handle_btrace_general_set, handle_qxfer_btrace)
2953 (handle_qxfer_btrace_conf, detach_or_kill_for_exit_cleanup)
2954 (captured_main, main): Update.
2955 * gdbreplay.c (main): Update.
2956
2957 2019-04-05 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2958
2959 * linux-low.c (linux_get_auxv): Remove static. Return auxv entry
2960 value in argument pointer, return 1 if the entry is found and 0
2961 otherwise. Move comment.
2962 (linux_get_hwcap, linux_get_hwcap2): Use modified linux_get_auxv.
2963 * linux-low.h (linux_get_auxv): Declare.
2964 * linux-ppc-low.c (is_elfv2_inferior): Use linux_get_auxv.
2965
2966 2019-04-05 Tom Tromey <tromey@adacore.com>
2967
2968 * server.c (gdbserver_usage): Use upper-case for metasyntactic
2969 variables.
2970
2971 2019-03-28 Alan Hayward <alan.hayward@arm.com>
2972
2973 * linux-low.c (AT_HWCAP2): Add define if not already included.
2974
2975 2019-03-26 Alan Hayward <alan.hayward@arm.com>
2976
2977 * linux-aarch64-low.c (aarch64_get_hwcap): Remove function.
2978 (aarch64_arch_setup): Call linux_get_hwcap.
2979 * linux-arm-low.c (arm_get_hwcap): Remove function.
2980 (arm_read_description): Call linux_get_hwcap.
2981 * linux-low.c (linux_get_auxv): New function.
2982 (linux_get_hwcap): Likewise.
2983 (linux_get_hwcap2): Likewise.
2984 * linux-low.h (linux_get_hwcap): New declaration.
2985 (linux_get_hwcap2): Likewise.
2986 * linux-ppc-low.c (ppc_get_auxv): Remove function.
2987 (ppc_arch_setup): Call linux_get_hwcap.
2988 * linux-s390-low.c (s390_get_hwcap): Remove function.
2989 (s390_arch_setup): Call linux_get_hwcap.
2990
2991 2019-03-22 Alan Hayward <alan.hayward@arm.com>
2992 Jiong Wang <jiong.wang@arm.com>
2993
2994 * linux-aarch64-low.c (aarch64_store_pauthregset): New function.
2995 * linux-low.c (regsets_store_inferior_registers): Allow optional reads
2996 to fail.
2997 * linux-low.h (enum regset_type): Add OPTIONAL_REGS.
2998
2999 2019-03-22 Alan Hayward <alan.hayward@arm.com>
3000 Jiong Wang <jiong.wang@arm.com>
3001
3002 * linux-aarch64-low.c (AARCH64_HWCAP_PACA): New define.
3003 (aarch64_get_hwcap): New function.
3004 (aarch64_arch_setup): Read APIA hwcap.
3005
3006 2019-03-22 Alan Hayward <alan.hayward@arm.com>
3007 Jiong Wang <jiong.wang@arm.com>
3008
3009 * linux-aarch64-ipa.c (get_ipa_tdesc): Add pauth param.
3010 (initialize_low_tracepoint): Likewise.
3011 * linux-aarch64-low.c (aarch64_arch_setup): Likewise.
3012 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Likewise.
3013 * linux-aarch64-tdesc.c (struct target_desc): Likewise.
3014 (aarch64_linux_read_description): Likewise.
3015 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Likewise.
3016
3017 2019-03-12 John Baldwin <jhb@FreeBSD.org>
3018
3019 * linux-x86-tdesc.c (i386_linux_read_description): Update call to
3020 i386_create_target_description for 'segments' parameter.
3021 * lynx-i386-low.c (lynx_i386_arch_setup): Likewise.
3022 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
3023 * win32-i386-low.c (i386_arch_setup): Likewise.
3024
3025 2019-03-12 Tom Tromey <tromey@adacore.com>
3026
3027 * linux-low.c (iterate_over_lwps): Update.
3028
3029 2019-03-06 Tom Tromey <tom@tromey.com>
3030
3031 * server.c (detach_or_kill_for_exit_cleanup): Remove parameter.
3032 (captured_main): Use SCOPE_EXIT.
3033
3034 2019-03-04 Sergio Durigan Junior <sergiodj@redhat.com>
3035
3036 * configure.srv: Use '$enable_unittest' instead of '$development'
3037 when checking whether to fill 'srv_regobj' on 'aarch64*-*-linux*'
3038 case.
3039
3040 2019-02-27 Tom Tromey <tromey@adacore.com>
3041
3042 * gdbreplay.c (logchar): Handle \r\n.
3043
3044 2019-02-07 Alan Hayward <alan.hayward@arm.com>
3045
3046 * linux-low.c (linux_attach): Add process before lwp.
3047 * server.c (attach_inferior): Check if already attached.
3048
3049 2019-02-07 Tom Tromey <tom@tromey.com>
3050
3051 * x86-tdesc.h: Rename include guard.
3052 * x86-low.h: Add include guard.
3053 * wincecompat.h: Rename include guard.
3054 * win32-low.h: Add include guard.
3055 * utils.h: Rename include guard.
3056 * tracepoint.h: Rename include guard.
3057 * tdesc.h: Rename include guard.
3058 * target.h: Rename include guard.
3059 * server.h: Rename include guard.
3060 * remote-utils.h: Rename include guard.
3061 * regcache.h: Rename include guard.
3062 * nto-low.h: Rename include guard.
3063 * notif.h: Add include guard.
3064 * mem-break.h: Rename include guard.
3065 * lynx-low.h: Add include guard.
3066 * linux-x86-tdesc.h: Add include guard.
3067 * linux-s390-tdesc.h: Add include guard.
3068 * linux-ppc-tdesc-init.h: Add include guard.
3069 * linux-low.h: Add include guard.
3070 * linux-aarch64-tdesc.h: Add include guard.
3071 * linux-aarch32-low.h: Add include guard.
3072 * inferiors.h: Rename include guard.
3073 * i387-fp.h: Rename include guard.
3074 * hostio.h: Rename include guard.
3075 * gdbthread.h: Rename include guard.
3076 * gdb_proc_service.h: Rename include guard.
3077 * event-loop.h: Rename include guard.
3078 * dll.h: Rename include guard.
3079 * debug.h: Rename include guard.
3080 * ax.h: Rename include guard.
3081
3082 2018-01-30 Szabolcs Nagy <szabolcs.nagy@arm.com>
3083
3084 PR gdb/23985
3085 * Makefile.in (IPAGENT_CFLAGS): Add UNDO_GNULIB_CFLAGS.
3086 (UNDO_GNULIB_CFLAGS): Undo gnulib replacements.
3087
3088 2019-01-25 Tom Tromey <tom@tromey.com>
3089
3090 * Makefile.in (INCLUDE_CFLAGS): Don't add -I for common.
3091
3092 2019-01-25 Tom Tromey <tom@tromey.com>
3093
3094 * win32-low.c: Fix common/ includes.
3095 * win32-i386-low.c: Fix common/ includes.
3096 * tracepoint.c: Fix common/ includes.
3097 * thread-db.c: Fix common/ includes.
3098 * target.h: Fix common/ includes.
3099 * symbol.c: Fix common/ includes.
3100 * spu-low.c: Fix common/ includes.
3101 * server.h: Fix common/ includes.
3102 * server.c: Fix common/ includes.
3103 * remote-utils.c: Fix common/ includes.
3104 * regcache.h: Fix common/ includes.
3105 * regcache.c: Fix common/ includes.
3106 * nto-x86-low.c: Fix common/ includes.
3107 * notif.h: Fix common/ includes.
3108 * mem-break.h: Fix common/ includes.
3109 * lynx-low.c: Fix common/ includes.
3110 * lynx-i386-low.c: Fix common/ includes.
3111 * linux-x86-tdesc-selftest.c: Fix common/ includes.
3112 * linux-x86-low.c: Fix common/ includes.
3113 * linux-low.c: Fix common/ includes.
3114 * inferiors.h: Fix common/ includes.
3115 * i387-fp.c: Fix common/ includes.
3116 * hostio.c: Fix common/ includes.
3117 * hostio-errno.c: Fix common/ includes.
3118 * gdbthread.h: Fix common/ includes.
3119 * gdbreplay.c: Fix common/ includes.
3120 * fork-child.c: Fix common/ includes.
3121 * event-loop.c: Fix common/ includes.
3122 * ax.c:
3123 (enum gdb_agent_op): Fix common/ includes.
3124
3125 2019-01-21 Tom Tromey <tom@tromey.com>
3126
3127 * tracepoint.c: Fix includes.
3128 * remote-utils.c: Fix includes.
3129 * linux-x86-low.c: Fix includes.
3130
3131 2019-01-01 Joel Brobecker <brobecker@adacore.com>
3132
3133 * gdbreplay.c (gdbreplay_version): Update copyright year in
3134 version message.
3135 * server.c (gdbserver_version): Likewise.
3136
3137 2018-12-05 Alan Hayward <alan.hayward@arm.com>
3138
3139 * linux-low.c (add_lwp): Switch ordering.
3140
3141 2018-11-29 Tom Tromey <tom@tromey.com>
3142
3143 * win32-low.c (win32_join): Take pid, not process.
3144 * target.h (struct target_ops) <join>: Change argument type.
3145 (join_inferior): Change argument name.
3146 * spu-low.c (spu_join): Take pid, not process.
3147 * server.c (handle_detach): Preserve pid before destroying
3148 process.
3149 * lynx-low.c (lynx_join): Take pid, not process.
3150 * linux-low.c (linux_join): Take pid, not process.
3151
3152 2018-11-23 Alan Hayward <alan.hayward@arm.com>
3153
3154 * linux-aarch64-low.c (aarch64_cannot_store_register): Remove.
3155 (aarch64_cannot_fetch_register): Likewise.
3156 (struct linux_target_ops): Update references.
3157
3158 2018-10-31 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3159
3160 * linux-ppc-low.c: Include nat/linux-ptrace.h.
3161
3162 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3163
3164 * configure.srv (ipa_ppc_linux_regobj): Add
3165 powerpc-isa207-htm-vsx32l-ipa.o and
3166 powerpc-isa207-htm-vsx64l-ipa.o.
3167 (powerpc*-*-linux*): Add powerpc-isa207-htm-vsx32l.o and
3168 powerpc-isa207-htm-vsx64l.o to srv_regobj. Add
3169 rs6000/power-htm-spr.xml, rs6000/power-htm-core.xml,
3170 rs6000/power64-htm-core.xml, rs6000/power-htm-fpu.xml,
3171 rs6000/power-htm-altivec.xml, rs6000/power-htm-vsx.xml,
3172 rs6000/power-htm-ppr.xml, rs6000/power-htm-dscr.xml,
3173 rs6000/power-htm-tar.xml, rs6000/powerpc-isa207-htm-vsx32l.xml,
3174 and rs6000/powerpc-isa207-htm-vsx64l.xml to srv_xmlfiles.
3175 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
3176 <PPC_TDESC_ISA207_HTM_VSX>: New enum value.
3177 (init_registers_powerpc_isa207_htm_vsx32l)
3178 (init_registers_powerpc_isa207_htm_vsx64l): Declare.
3179 * linux-ppc-low.c (ppc_fill_tm_sprregset, ppc_store_tm_sprregset)
3180 (ppc_store_tm_cgprregset, ppc_store_tm_cfprregset)
3181 (ppc_store_tm_cvrregset, ppc_store_tm_cvsxregset)
3182 (ppc_store_tm_cpprregset, ppc_store_tm_cdscrregset)
3183 (ppc_store_tm_ctarregset): New functions.
3184 (ppc_regsets): Add entries for HTM regsets.
3185 (ppc_arch_setup): Set htm in features struct when needed. Set
3186 sizes for the HTM regsets.
3187 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_HTM_VSX.
3188 (initialize_low_arch): Call
3189 init_registers_powerpc_isa207_htm_vsx32l and
3190 init_registers_powerpc_isa207_htm_vsx64l.
3191 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
3192 PPC_TDESC_ISA207_HTM_VSX.
3193 (initialize_low_tracepoint): Call
3194 init_registers_powerpc_isa207_htm_vsx32l and
3195 init_registers_powerpc_isa207_htm_vsx64l.
3196
3197 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3198
3199 * configure.srv (powerpc*-*-linux*): Add rs6000/power-ebb.xml and
3200 rs6000/power-linux-pmu.xml to srv_xmlfiles.
3201 * linux-ppc-low.c (ppc_store_ebbregset, ppc_fill_pmuregset)
3202 (ppc_store_pmuregset): New functions.
3203 (ppc_regsets): Add entries for ebb and pmu regsets.
3204 (ppc_arch_setup): Set isa207 in features struct if the ebb and
3205 pmu regsets are available. Set sizes for these regsets.
3206
3207 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3208
3209 * configure.srv (ipa_ppc_linux_regobj): Add
3210 powerpc-isa207-vsx64l-ipa.o and powerpc-isa207-vsx32l-ipa.o.
3211 (powerpc*-*-linux*): Add powerpc-isa207-vsx32l.o and
3212 powerpc-isa207-vsx64l.o to srv_regobj, add rs6000/power-tar.xml,
3213 rs6000/powerpc-isa207-vsx32l.xml, and
3214 rs6000/powerpc-isa207-vsx64l.xml to srv_xmlfiles.
3215 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
3216 <PPC_TDESC_ISA207_VSX>: New enum value.
3217 (init_registers_powerpc_isa207_vsx32l): Declare.
3218 (init_registers_powerpc_isa207_vsx64l): Declare.
3219 * linux-ppc-low.c (ppc_fill_tarregset): New function.
3220 (ppc_store_tarregset): New function.
3221 (ppc_regsets): Add entry for the TAR regset.
3222 (ppc_arch_setup): Set isa207 in features struct when needed. Set
3223 size for the TAR regsets.
3224 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_VSX.
3225 (initialize_low_arch): Call init_registers_powerpc_isa207_vsx32l
3226 and init_registers_powerpc_isa207_vsx64l.
3227 * linux-ppc-ipa.c (get_ipa_tdesc): Handle PPC_TDESC_ISA207_VSX.
3228 (initialize_low_tracepoint): Call
3229 init_registers_powerpc_isa207_vsx32l and
3230 init_registers_powerpc_isa207_vsx64l.
3231
3232 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
3233 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3234
3235 * configure.srv (ipa_ppc_linux_regobj): Add
3236 powerpc-isa205-ppr-dscr-vsx32l-ipa.o and
3237 powerpc-isa205-ppr-dscr-vsx64l-ipa.o.
3238 (powerpc*-*-linux*): Add powerpc-isa205-ppr-dscr-vsx32l.o and
3239 powerpc-isa205-ppr-dscr-vsx64l.o to srv_regobj, add
3240 rs6000/power-dscr.xml, rs6000/power-ppr.xml,
3241 rs6000/powerpc-isa205-ppr-dscr-vsx32l.xml and
3242 rs6000/powerpc-isa205-ppr-dscr-vsx64l.xml to srv_xmlfiles.
3243 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
3244 <PPC_TDESC_ISA205_PPR_DSCR_VSX>: New enum value.
3245 (init_registers_powerpc_isa205_ppr_dscr_vsx32l)
3246 (init_registers_powerpc_isa205_ppr_dscr_vsx64l): Declare.
3247 * linux-ppc-low.c: Include "elf/common.h" and <sys/uio.h>.
3248 (ppc_hwcap): Add comment.
3249 (ppc_hwcap2): New global.
3250 (ppc_check_regset, ppc_fill_pprregset, ppc_store_pprregset)
3251 (ppc_fill_dscrregset, ppc_store_dscrregset): New functions.
3252 (ppc_regsets): Add entries for the DSCR and PPR regsets.
3253 (ppc_arch_setup): Get AT_HWCAP2. Set ppr_dscr in features struct
3254 when needed. Set sizes for the the DSCR and PPR regsets.
3255 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA205_PPR_DSCR_VSX.
3256 (initialize_low_arch): Call
3257 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
3258 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
3259 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
3260 PPC_TDESC_ISA205_PPR_DSCR_VSX.
3261 (initialize_low_tracepoint): Call
3262 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
3263 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
3264
3265 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3266
3267 * linux-ppc-low.c (ppc_fill_vrregset): Remove memset calls.
3268
3269 2018-10-10 Sergio Durigan Junior <sergiodj@redhat.com>
3270 Simon Marchi <simark@simark.ca>
3271
3272 * acinclude.m4: Include "../selftest.m4".
3273 * configure: Regenerate.
3274 * configure.ac: Use "GDB_AC_SELFTEST".
3275 * configure.srv: Use "$enable_unittests" instead of
3276 "$development" when checking whether unit tests have been
3277 enabled.
3278 * server.c (captured_main): Update message informing that
3279 selftests have been disabled.
3280
3281 2018-10-04 Tom Tromey <tom@tromey.com>
3282
3283 * configure: Rebuild.
3284
3285 2018-10-04 Tom Tromey <tom@tromey.com>
3286
3287 * server.c (handle_status): Rename inner "thread".
3288 (process_serial_event): Declare "res" in 'm' case.
3289 * linux-low.c (last_thread_of_process_p, find_lwp_pid)
3290 (iterate_over_lwps): Rename inner "thread".
3291 (linux_qxfer_libraries_svr4): Rename inner "len".
3292 * gdbthread.h (find_thread_in_random): Rename inner "thread".
3293
3294 2018-10-01 Gary Benson <gbenson@redhat.com>
3295
3296 * gdb_proc_service.h: Moved common code to
3297 common/gdb_proc_service.h.
3298
3299 2018-10-01 Gary Benson <gbenson@redhat.com>
3300
3301 * gdb_proc_service.h: Synchronize comments and whitespace with
3302 GDB's version of this file.
3303
3304 2018-09-25 Tom Tromey <tom@tromey.com>
3305
3306 * configure: Rebuild.
3307 * configure.ac (WARN_CFLAGS): Don't remove -Wmissing-prototypes.
3308
3309 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
3310
3311 * Makefile.in (gdbserver$(EXEEXT)): Sort OBS.
3312 (gdbreplay$(EXEEXT)): Sort GDBREPLAY_OBS.
3313 ($(IPA_LIB)): Sort IPA_OBJS.
3314
3315 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
3316
3317 * Makefile.in: Remove references to $(ADD_DEPS).
3318
3319 2018-09-16 Tom Tromey <tom@tromey.com>
3320
3321 * remote-utils.c (remote_open): Use GNU style for metasyntactic
3322 variables.
3323 * gdbreplay.c (gdbreplay_usage): Use GNU style for metasyntactic
3324 variables.
3325
3326 2018-09-05 Tom Tromey <tom@tromey.com>
3327
3328 * configure: Rebuild.
3329
3330 2018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
3331
3332 PR build/23399
3333 * tracepoint.c (IPA_SYM_STRUCT_NAME): Define.
3334
3335 2018-08-27 Tom Tromey <tom@tromey.com>
3336
3337 PR build/23087:
3338 * configure: Rebuild.
3339
3340 2018-08-27 Tom Tromey <tom@tromey.com>
3341
3342 * linux-s390-low.c (s390_emit_ext, s390_emit_litpool)
3343 (s390_emit_const, s390_emit_reg, s390_emit_zero_ext)
3344 (s390_emit_stack_adjust, s390_emit_set_r2, s390x_emit_ext)
3345 (s390x_emit_const, s390x_emit_reg, s390x_emit_zero_ext)
3346 (s390x_emit_stack_adjust): Add casts to unsigned char.
3347
3348 2018-08-22 Simon Marchi <simon.marchi@ericsson.com>
3349
3350 PR gdb/23374
3351 PR gdb/23375
3352 * server.h (struct client_state) <disable_randomization>:
3353 Initialize to 1.
3354
3355 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
3356
3357 * linux-mips-low.c (mips_collect_ptrace_register): Remove unused
3358 variable.
3359 (mips_supply_ptrace_register): Likewise.
3360
3361 2018-07-22 Tom Tromey <tom@tromey.com>
3362
3363 * configure: Rebuild.
3364
3365 2018-07-22 Tom Tromey <tom@tromey.com>
3366
3367 * win32-low.c (win32_create_inferior): Remove unused variables.
3368 * gdbreplay.c (remote_open): Remove unused variable.
3369 * remote-utils.c (remote_prepare): Remove unused variable.
3370 * x86-tdesc.h (X86_TDESC_H): Define.
3371 (amd64_expedite_regs): Define conditionally.
3372 (i386_expedite_regs): Mark ATTRIBUTE_UNUSED.
3373 * linux-x86-tdesc.c (i386_tdescs): Move inside #if.
3374 * remote-utils.c (readchar): Remove unused variable.
3375
3376 2018-07-13 Pedro Alves <palves@redhat.com>
3377
3378 * linux-low.c (linux_kill): Change parameter to process_info
3379 pointer instead of pid. Adjust.
3380 * lynx-low.c (lynx_kill): Likewise.
3381 * nto-low.c (nto_kill): Likewise.
3382 * spu-low.c (spu_kill): Likewise.
3383 * win32-low.c (win32_kill): Likewise.
3384 * server.c (handle_v_kill, kill_inferior_callback)
3385 (detach_or_kill_for_exit): Adjust.
3386 * target.c (kill_inferior): Change parameter to process_info
3387 pointer instead of pid. Adjust.
3388 * target.h (struct target_ops) <kill>: Change parameter to
3389 process_info pointer instead of pid. Adjust all implementations
3390 and callers.
3391 (kill_inferior): Likewise.
3392
3393 2018-07-13 Pedro Alves <palves@redhat.com>
3394
3395 * linux-low.c (linux_detach, linux_join): Change parameter to
3396 process_info pointer instead of pid. Adjust.
3397 * lynx-low.c (lynx_detach, lynx_join): Likewise.
3398 * nto-low.c (nto_detach): Likewise.
3399 * spu-low.c (spu_detach, spu_join): Likewise.
3400 * win32-low.c (win32_detach, win32_join): Likewise.
3401 * server.c (handle_detach, detach_or_kill_for_exit): Adjust.
3402 * target.h (struct target_ops) <detach, join>: Change parameter to
3403 process_info pointer instead of pid. Adjust all implementations
3404 and callers.
3405 (detach_inferior, join_inferior): Rename 'pid' parameter to
3406 'proc'.
3407
3408 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
3409 Jan Kratochvil <jan.kratochvil@redhat.com>
3410 Paul Fertser <fercerpav@gmail.com>
3411 Tsutomu Seki <sekiriki@gmail.com>
3412
3413 * Makefile.in (SFILES): Add '$(srcdir)/common/netstuff.c'.
3414 (OBS): Add 'common/netstuff.o'.
3415 (GDBREPLAY_OBS): Likewise.
3416 * gdbreplay.c: Include 'wspiapi.h' and 'netstuff.h'.
3417 (remote_open): Implement support for IPv6
3418 connections.
3419 * remote-utils.c: Include 'netstuff.h', 'filestuff.h'
3420 and 'wspiapi.h'.
3421 (handle_accept_event): Accept connections from IPv6 sources.
3422 (remote_prepare): Handle IPv6-style hostnames; implement
3423 support for IPv6 connections.
3424 (remote_open): Implement support for printing connections from
3425 IPv6 sources.
3426
3427 2018-07-11 Pedro Alves <palves@redhat.com>
3428
3429 PR gdb/23377
3430 * mem-break.c (any_persistent_commands): Add process_info
3431 parameter and use it instead of relying on the current process.
3432 Change return type to bool.
3433 * mem-break.h (any_persistent_commands): Add process_info
3434 parameter and change return type to bool.
3435 * server.c (handle_detach): Remove require_running_or_return call.
3436 Look up the process_info for the process we're about to detach.
3437 If not found, return back error to GDB. Adjust
3438 any_persistent_commands call to pass down a process pointer.
3439
3440 2018-07-11 Pedro Alves <palves@redhat.com>
3441
3442 * i387-fp.c (i387_cache_to_fsave, cache_to_fxsave)
3443 (i387_cache_to_xsave): Use regcache_raw_get_unsigned_by_name
3444 instead of collect_register_by_name.
3445 * regcache.c (regcache_raw_get_unsigned_by_name): New.
3446 * regcache.h (regcache_raw_get_unsigned_by_name): New.
3447
3448 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
3449 Pedro Alves <palves@redhat.com>
3450
3451 * linux-low.c (initialize_low): Call linux_proc_init_warnings.
3452
3453 2018-07-03 Tom Tromey <tom@tromey.com>
3454
3455 * linux-low.c: Update.
3456 * lynx-low.c: Update.
3457 * mem-break.c: Update.
3458 * nto-low.c: Update.
3459 * remote-utils.c: Update.
3460 * server.c: Update.
3461 * spu-low.c: Update.
3462 * target.c: Update.
3463 * win32-low.c: Update.
3464
3465 2018-07-03 Tom Tromey <tom@tromey.com>
3466
3467 * server.c: Update.
3468
3469 2018-07-03 Tom Tromey <tom@tromey.com>
3470
3471 * linux-low.c: Update.
3472
3473 2018-07-03 Tom Tromey <tom@tromey.com>
3474
3475 * target.c: Update.
3476
3477 2018-07-03 Tom Tromey <tom@tromey.com>
3478
3479 * linux-low.c: Update.
3480 * linux-mips-low.c: Update.
3481 * lynx-low.c: Update.
3482 * nto-low.c: Update.
3483 * remote-utils.c: Update.
3484 * server.c: Update.
3485 * spu-low.c: Update.
3486 * target.c: Update.
3487 * thread-db.c: Update.
3488
3489 2018-07-03 Tom Tromey <tom@tromey.com>
3490
3491 * linux-low.c: Update.
3492 * linux-mips-low.c: Update.
3493 * lynx-low.c: Update.
3494 * mem-break.c: Update.
3495 * nto-low.c: Update.
3496 * remote-utils.c: Update.
3497 * server.c: Update.
3498 * spu-low.c: Update.
3499 * target.c: Update.
3500 * tracepoint.c: Update.
3501
3502 2018-07-03 Tom Tromey <tom@tromey.com>
3503
3504 * linux-low.c: Update.
3505 * linux-ppc-low.c: Update.
3506 * linux-x86-low.c: Update.
3507 * proc-service.c: Update.
3508 * server.c: Update.
3509 * spu-low.c: Update.
3510 * thread-db.c: Update.
3511 * win32-low.c: Update.
3512
3513 2018-07-03 Tom Tromey <tom@tromey.com>
3514
3515 * linux-low.c: Update.
3516 * lynx-low.c: Update.
3517 * nto-low.c: Update.
3518 * remote-utils.c: Update.
3519 * spu-low.c: Update.
3520 * thread-db.c: Update.
3521 * win32-low.c: Update.
3522
3523 2018-06-29 Joel Brobecker <brobecker@adacore.com>
3524
3525 * linux-x86-tdesc.c (amd64_linux_read_description): Add missing
3526 parameter in call to 'amd64_create_target_description'.
3527
3528 2018-06-28 Jan Kratochvil <jan.kratochvil@redhat.com>
3529
3530 * x86-tdesc.h: Remove executable permission flag.
3531
3532 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
3533
3534 * configure.ac: Remove AC_PREREQ, add missing quoting.
3535 * configure: Re-generate.
3536 * config.in: Re-generate.
3537 * aclocal.m4: Re-generate.
3538
3539 2018-06-18 Simon Marchi <simon.marchi@ericsson.com>
3540
3541 * tracepoint.h (current_traceframe): Remove declaration.
3542
3543 2018-06-18 Alan Hayward <alan.hayward@arm.com>
3544
3545 * linux-aarch64-low.c (is_sve_tdesc): New function.
3546 (aarch64_sve_regs_copy_to_regcache): Likewise.
3547 (aarch64_sve_regs_copy_from_regcache): Likewise.
3548 (aarch64_regs_info): Add SVE checks.
3549 (initialize_low_arch): Initialize SVE.
3550
3551 2018-06-18 Alan Hayward <alan.hayward@arm.com>
3552
3553 * Makefile.in: Add aarch64-sve-linux-ptrace.c.
3554
3555 2018-06-11 Alan Hayward <alan.hayward@arm.com>
3556
3557 * linux-aarch64-ipa.c (get_ipa_tdesc): Add null VQ param.
3558 (initialize_low_tracepoint): Likewise
3559 * linux-aarch64-low.c (aarch64_arch_setup): Get VQ.
3560 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Add null VQ
3561 param.
3562 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add VQ
3563 checks.
3564 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Add VQ.
3565
3566 2018-06-11 Alan Hayward <alan.hayward@arm.com>
3567
3568 * server.h (PBUFSIZ): Increase size
3569
3570 2018-06-11 Alan Hayward <alan.hayward@arm.com>
3571
3572 * regcache.c (regcache::raw_compare): New function.
3573 * regcache.h (regcache::raw_compare): New declaration.
3574
3575 2018-06-11 Alan Hayward <alan.hayward@arm.com>
3576
3577 * regcache.c (new_register_cache): Use new.
3578 (free_register_cache): Use delete.
3579 (register_data): Use const.
3580 (supply_register): Move body inside regcache.
3581 (regcache::raw_supply): New override function.
3582 (collect_register): Move body inside regcache.
3583 (regcache::raw_collect): New override function.
3584 (regcache::get_register_status): New override function.
3585 * regcache.h (struct regcache): Inherit from reg_buffer_common.
3586
3587 2018-06-09 Tom Tromey <tom@tromey.com>
3588
3589 * event-loop.c (gdb_event, gdb_event_p): Remove typedefs. Don't
3590 declare queue.
3591 (event_queue): Use std::queue.
3592 (gdb_event_xfree): Remove.
3593 (initialize_event_loop, process_event, wait_for_event): Update.
3594
3595 2018-06-08 Stan Cox <scox@redhat.com>
3596
3597 * win32-low.c (win32_create_inferior): last_ptid and last_status
3598 moved to client_state.
3599
3600 2018-06-08 Pedro Alves <palves@redhat.com>
3601
3602 * Makefile.in (GDBREPLAY_OBS): Add common/cleanups.o,
3603 common/common-exceptions.o, common/common-utils.o,
3604 common/errors.o, common/print-utils.o and utils.o.
3605 * gdbreplay.c: Include "common-defs.h" instead of the two
3606 'config.h's here. Don't include stdio.h, errno.h, stdlib.h,
3607 string.h or alloca.h.
3608 (perror_with_name): Delete.
3609 (remote_open): Use xstrdup instead of strdup.
3610 (main): Rename to ...
3611 (captured_main): ... this.
3612 (main): New.
3613
3614 2018-06-08 Tom Tromey <tom@tromey.com>
3615
3616 * linux-low.c (linux_low_read_btrace): Update.
3617
3618 2018-06-04 Stan Cox <scox@redhat.com>
3619
3620 * server.h (struct client_state): New.
3621 * server.c (cont_thread, general_thread, multi_process)
3622 (report_fork_events, report_vfork_events, report_exec_events)
3623 (report_thread_events, swbreak_feature, hwbreak_feature)
3624 (vCont_supported, disable_randomization, pass_signals)
3625 (program_signals, program_signals_p, last_status, last_ptid, own_buf):
3626 Moved to client_state.
3627 * remote-utils.c (remote_debug, noack_mode)
3628 (transport_is_reliable): Moved to client_state.
3629 * tracepoint.c (current_traceframe): Moved to client_state.
3630
3631 Update all callers.
3632 * server.c, remote-utils.c, tracepoint.c, fork-child.c,
3633 linux-low.c, remote-utils.h, target.c: Use client_state.
3634
3635 2018-05-31 Alan Hayward <alan.hayward@arm.com>
3636
3637 * configure.srv: Add new c/h file.
3638
3639 2018-05-31 Alan Hayward <alan.hayward@arm.com>
3640
3641 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add
3642 null VQ.
3643
3644 2018-05-25 Maciej W. Rozycki <macro@mips.com>
3645
3646 * gdb.arch/mips-fpregset-core.exp: New test.
3647 * gdb.arch/mips-fpregset-core.c: New test source.
3648
3649 2018-05-23 Erik Kurzinger <ekurzinger@nvidia.com>
3650
3651 PR server/23198
3652 * hostio.c (require_int): Do not report overflow for integers
3653 between 0xfffffff and 0x7fffffff.
3654
3655 2018-05-22 Maciej W. Rozycki <macro@mips.com>
3656
3657 * linux-mips-low.c [HAVE_PTRACE_GETREGS] (mips_collect_register)
3658 (mips_supply_register): Move outside HAVE_PTRACE_GETREGS.
3659 (mips_collect_ptrace_register, mips_supply_ptrace_register): New
3660 functions.
3661 (the_low_target): Wire them.
3662
3663 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3664
3665 * linux-ppc-low.c (ppc_fill_vrregset): Add vscr_offset variable.
3666 Set vscr_offset to 0 in little-endian mode and 12 in big-endian
3667 mode. Call collect_register_by_name with vscr using
3668 vscr_offset. Zero-pad vscr and vrsave fields in collector buffer.
3669 (ppc_store_vrregset): Add and set vscr_offset variable as in
3670 ppc_fill_vrregset. Call supply_register_by_name with vscr using
3671 vscr_offset.
3672
3673 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3674
3675 * linux-ppc-low.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
3676 (ppc_arch_setup): Change SIZEOF_VRREGS and SIZEOF_VSXREGS to
3677 PPC_LINUX_SIZEOF_VRREGSET and PPC_LINUX_SIZEOF_VSXREGSET.
3678
3679 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3680
3681 * linux-ppc-low.c (ppc_fill_vsxregset): Remove ppc_hwcap check.
3682 (ppc_store_vsxregset): Likewise.
3683 (ppc_fill_vrregset): Likewise.
3684 (ppc_store_vrregset): Likewise.
3685 (ppc_fill_evrregset): Likewise.
3686 (ppc_store_evrregset): Likewise.
3687 (ppc_regsets): Set VSX/VR/EVR regset sizes to 0.
3688 (ppc_arch_setup): Iterate through ppc_regsets and set sizes when
3689 needed.
3690
3691 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3692
3693 * linux-ppc-low.c (ppc_arch_setup): Remove code for getting the
3694 wordsize of the inferior. Call ppc_linux_target_wordsize.
3695
3696 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3697
3698 * configure.srv (srv_tgtobj): Add arch/ppc-linux-common.o.
3699 * Makefile.in (SFILES): Add arch/ppc-linux-common.c.
3700 * linux-ppc-tdesc.h: Rename to linux-ppc-tdesc-init.h.
3701 * linux-ppc-tdesc-init.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
3702 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
3703 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
3704 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
3705 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
3706 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
3707 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
3708 (tdesc_powerpc_e500l): Remove.
3709 * linux-ppc-ipa.c: Include arch/ppc-linux-tdesc.h and
3710 linux-ppc-tdesc-init.h. Don't include linux-ppc-tdesc.h.
3711 * linux-ppc-low.c: Include arch/ppc-linux-common.h,
3712 arch/ppc-linux-tdesc.h, and linux-ppc-tdesc-init.h. Don't include
3713 linux-ppc-tdesc.h.
3714 (ppc_arch_setup): Remove target description matching code. Fill a
3715 ppc_linux_features struct and call ppc_linux_match_description
3716 with it.
3717
3718 2018-05-22 Maciej W. Rozycki <macro@mips.com>
3719
3720 * linux-mips-low.c (mips_cannot_fetch_register): Return 1 if the
3721 width of the requested register exceeds the width of the
3722 `ptrace' data type.
3723 (mips_cannot_store_register): Likewise.
3724
3725 2018-05-21 Maciej W. Rozycki <macro@mips.com>
3726
3727 * linux-mips-low.c (mips_fetch_register): New function. Update
3728 preceding comment.
3729 (mips_store_gregset): Supply 0 rather than $restart for $zero.
3730 (the_low_target): Wire `mips_fetch_register'.
3731
3732 2018-05-10 Joel Brobecker <brobecker@adacore.com>
3733
3734 * lynx-i386-low.c (LYNXOS_178): New macro.
3735 [LYNXOS_178] (usr_fcontext_t): Provide a definition that matches
3736 the layout on LynxOS-178.
3737 (lynx_i386_fill_fpregset, lynx_i386_store_fpregset): Do not
3738 handle floating point registers that are not supported by
3739 LynxOS-178.
3740
3741 2018-05-10 Tom Tromey <tom@tromey.com>
3742
3743 * configure: Rebuild.
3744
3745 2018-05-10 Joel Brobecker <brobecker@adacore.com>
3746
3747 PR server/23158:
3748 * tdesc.h (init_target_desc) <expedite_regs>: New parameter.
3749 * tdesc.c (init_target_desc) <expedite_regs>: New parameter.
3750 Use it to set the expedite_regs field in the given tdesc.
3751 * x86-tdesc.h: New file.
3752 * linux-aarch64-tdesc.c (aarch64_linux_read_description):
3753 Adjust following the addition of the new expedite_regs parameter
3754 to init_target_desc.
3755 * linux-tic6x-low.c (tic6x_read_description): Likewise.
3756 * linux-x86-tdesc.c: #include "x86-tdesc.h".
3757 (i386_linux_read_description, amd64_linux_read_description):
3758 Adjust following the addition of the new expedite_regs parameter
3759 to init_target_desc.
3760 * lynx-i386-low.c: #include "x86-tdesc.h".
3761 (lynx_i386_arch_setup): Adjust following the addition of the new
3762 expedite_regs parameter to init_target_desc.
3763 * nto-x86-low.c: #include "x86-tdesc.h".
3764 (nto_x86_arch_setup): Adjust following the addition of the new
3765 expedite_regs parameter to init_target_desc.
3766 * win32-i386-low.c: #include "x86-tdesc.h".
3767 (i386_arch_setup): Adjust following the addition of the new
3768 expedite_regs parameter to init_target_desc.
3769
3770 2018-05-10 Joel Brobecker <brobecker@adacore.com>
3771
3772 PR server/23158:
3773 * win32-low.c (win32_create_inferior): Add call to my_wait
3774 setting last_status global.
3775
3776 2018-05-10 Joel Brobecker <brobecker@adacore.com>
3777
3778 PR server/23158:
3779 * win32-low.c (create_process): Only call gdb_tilde_expand if
3780 inferior_cwd is not NULL.
3781
3782 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
3783
3784 * i387-fp.c (i387_cache_to_xsave): Only write x87 control
3785 registers to the cache if their values have changed.
3786 (i387_xsave_to_cache): Provide default values for x87 control
3787 registers when these features are available, but disabled.
3788 * regcache.c (supply_register_by_name_zeroed): New function.
3789 * regcache.h (supply_register_by_name_zeroed): Declare new
3790 function.
3791
3792 2018-05-07 Tom Tromey <tom@tromey.com>
3793
3794 * configure: Rebuild.
3795
3796 2018-05-04 Tom Tromey <tom@tromey.com>
3797
3798 * configure: Rebuild.
3799
3800 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
3801 Pedro Alves <palves@redhat.com>
3802
3803 * linux-aarch64-low.c (aarch64_stopped_data_address):
3804 Likewise.
3805
3806 2018-04-27 Tom Tromey <tom@tromey.com>
3807
3808 * configure: Rebuild.
3809
3810 2018-04-23 Tom Tromey <tom@tromey.com>
3811
3812 * configure: Rebuild.
3813
3814 2018-04-19 Simon Marchi <simon.marchi@ericsson.com>
3815
3816 * Makefile.in (depcomp): Add "..".
3817 (all_deps_files): New and use it.
3818
3819 2018-04-18 Alan Hayward <alan.hayward@arm.com>
3820
3821 * configure.srv (aarch64*-*-linux*): Don't include xml.
3822 (i[34567]86-*-cygwin*): Likewise.
3823 (i[34567]86-*-linux*): Likewise.
3824 (i[34567]86-*-lynxos*): Likewise.
3825 (i[34567]86-*-mingw32ce*): Likewise.
3826 (i[34567]86-*-mingw*): Likewise.
3827 (i[34567]86-*-nto*): Likewise.
3828 (tic6x-*-uclinux): Likewise.
3829 (x86_64-*-linux*): Likewise.
3830 (x86_64-*-mingw*): Likewise.
3831 (x86_64-*-cygwin*): Likewise.
3832
3833 2018-04-18 Alan Hayward <alan.hayward@arm.com>
3834
3835 * tdesc.c: Remove xml parameter.
3836
3837 2018-04-18 Alan Hayward <alan.hayward@arm.com>
3838
3839 * server.c (get_features_xml): Remove cast.
3840 * tdesc.c (void target_desc::accept): Fill in function.
3841 (tdesc_get_features_xml): Remove old xml creation.
3842 (print_xml_feature::visit_pre): Add xml vistor.
3843 * tdesc.h (struct target_desc): Make xmltarget mutable.
3844 (tdesc_get_features_xml): Remove declaration.
3845
3846 2018-04-18 Alan Hayward <alan.hayward@arm.com>
3847
3848 * tdesc.c (tdesc_architecture_name): Add new function.
3849 (tdesc_osabi_name): Likewise.
3850 (tdesc_get_features_xml): Use new functions.
3851
3852 2018-04-18 Alan Hayward <alan.hayward@arm.com>
3853
3854 * tdesc.c (tdesc_create_flags): Remove.
3855 (tdesc_add_flag): Likewise.
3856 (tdesc_named_type): Likewise.
3857 (tdesc_create_union): Likewise.
3858 (tdesc_create_struct): Likewise.
3859 (tdesc_create_vector): Likewise.
3860 (tdesc_add_bitfield): Likewise.
3861 (tdesc_add_field): Likewise.
3862 (tdesc_set_struct_size): Likewise.
3863
3864 2018-04-18 Alan Hayward <alan.hayward@arm.com>
3865
3866 * tdesc.c (~target_desc): Remove implictly deleted items.
3867 (init_target_desc): Iterate all features.
3868 (tdesc_get_features_xml): Use vector.
3869 (tdesc_create_feature): Create feature.
3870 * tdesc.h (tdesc_feature) Remove
3871 (target_desc): Add features.
3872
3873 2018-04-18 Alan Hayward <alan.hayward@arm.com>
3874
3875 * Makefile.in: Add common/tdesc.c
3876 * tdesc.c (init_target_desc): init all reg_defs from register
3877 vector.
3878 (tdesc_create_reg): Create tdesc_reg.
3879 * tdesc.h (tdesc_feature): Add register vector.
3880
3881 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
3882
3883 * tdesc.h (struct target_desc) <features>: Change type to
3884 std::vector<std::string>.
3885 * tdesc.c (target_desc::~target_desc): Adjust to std::vector
3886 changes.
3887 (tdesc_get_features_xml): Likewise.
3888 (tdesc_create_feature): Likewise.
3889
3890 2018-03-26 Alan Hayward <alan.hayward@arm.com>
3891
3892 * regcache.c (find_register_by_number): Return a ref.
3893 (find_regno): Use references.
3894 (register_size): Likewise.
3895 (register_data): Likewise.
3896 * tdesc.c (target_desc::~target_desc): Remove free calls.
3897 (target_desc::operator==): Use std::vector compare.
3898 (init_target_desc): Use reference.
3899 (tdesc_create_reg): Use reg constructors.
3900 * tdesc.h (struct target_desc): Replace pointer with object.
3901
3902 2018-03-23 Alan Hayward <alan.hayward@arm.com>
3903
3904 * regcache.c (find_register_by_number): Make static.
3905 (find_regno): Use find_register_by_number
3906 * regcache.h (struct reg): Remove declaration.
3907
3908 2018-03-23 Alan Hayward <alan.hayward@arm.com>
3909
3910 * tdesc.c (target_desc::~target_desc): Move to here.
3911 (target_desc::operator==): Likewise.
3912 * tdesc.h (target_desc::~target_desc): Move from here.
3913 (target_desc::operator==): Likewise.
3914
3915 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
3916
3917 * linux-s390-low.c (s390_get_wordsize): Correct brace style.
3918
3919 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
3920
3921 * linux-s390-ipa.c (get_ipa_tdesc): Add handling for
3922 S390_TDESC_GS.
3923 * linux-s390-low.c (s390_get_ipa_tdesc_idx): Likewise.
3924 (initialize_low_tracepoint): Call init_registers_s390x_gs_linux64
3925 and init_registers_s390_gs_linux64.
3926
3927 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
3928
3929 * linux-s390-low.c (s390_fill_gs): Remove function.
3930 (s390_fill_gsbc): Remove function.
3931 (s390_regsets): Set fill functions for the guarded storage regsets
3932 to NULL.
3933
3934 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
3935
3936 * linux-s390-low.c (s390_get_hwcap): Replace tdesc parameter by
3937 the word size. Add comment.
3938 (s390_get_wordsize): New function.
3939 (s390_arch_setup): No longer select a temporary tdesc to fetch the
3940 pswm with it. Instead, use s390_get_wordsize to determine the
3941 word size first and derive the correct tdesc from that directly.
3942
3943 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
3944
3945 * Makefile.in: Include silent-rules.mk.
3946 (srcdir, abs_top_srcdir, abs_srcdir, VPATH): Move up.
3947 (COMPILE): Add ECHO_CXX.
3948 (gdbserver$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
3949 (gdbreplay$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
3950 ($(IPA_LIB)): Add SILENCE and ECHO_CXXLD.
3951 (version-generated.c): Add ECHO_GEN.
3952 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN_GENERATED.
3953 (IPAGENT_COMPILE): Add ECHO_CXX.
3954 (%-generated.c): Add ECHO_REGDAT.
3955
3956 2018-03-14 Tom Tromey <tom@tromey.com>
3957
3958 PR cli/14977:
3959 * ax.c (ax_printf): Special case for NULL.
3960
3961 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
3962
3963 * linux-low.c (linux_qxfer_libraries_svr4): Use
3964 xml_escape_text_append.
3965
3966 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
3967
3968 * linux-low.c (linux_qxfer_libraries_svr4): Use std::string.
3969
3970 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
3971
3972 * server.c (handle_general_set): Remove unnecessary xstrdup.
3973
3974 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
3975
3976 * server.c (parse_debug_format_options): Adjust to
3977 delim_string_to_char_ptr_vec changes.
3978 * thread-db.c (thread_db_load_search): Adjust to
3979 dirnames_to_char_ptr_vec changes.
3980
3981 2018-03-01 Markus Metzger <markus.t.metzger@intel.com>
3982
3983 * target.h (target_enable_btrace, target_disable_btrace)
3984 (target_read_btrace, target_read_btrace_conf): Turn macro into
3985 inline function. Throw error if target method is not defined.
3986 * server.c (handle_qxfer_btrace handle_qxfer_btrace_conf): Remove
3987 check for btrace target method. Be prepared to handle exceptions
3988 from btrace target methods.
3989
3990 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
3991
3992 * server.c (captured_main): Change order of error message printed
3993 when the current working directory cannot be found.
3994
3995 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
3996
3997 * server.c: Include "filenames.h" and "pathstuff.h".
3998 (program_name): Delete variable.
3999 (program_path): New anonymous class.
4000 (get_exec_wrapper): Use "program_path" instead of
4001 "program_name".
4002 (handle_v_run): Likewise.
4003 (captured_main): Likewise.
4004 (process_serial_event): Likewise.
4005
4006 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
4007
4008 * Makefile.in (SFILES): Add "$(srcdir)/common/pathstuff.c".
4009 (OBJS): Add "pathstuff.o".
4010 * server.c (current_directory): New global variable.
4011 (captured_main): Initialize "current_directory".
4012
4013 2018-02-26 Alan Hayward <alan.hayward@arm.com>
4014
4015 * tdesc.c: Use common/tdesc.h.
4016 * tdesc.h: Likewise.
4017
4018 2018-02-20 Alan Hayward <alan.hayward@arm.com>
4019 Simon Marchi <simon.marchi@ericsson.com>
4020
4021 * Makefile.in: Switch order of make rules.
4022
4023 2018-02-19 Alan Hayward <alan.hayward@arm.com>
4024
4025 * Makefile.in: Add common directory in build.
4026 * configure.ac: Add common reference.
4027 * configure: Regenerate.
4028
4029 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
4030
4031 * linux-low.c (linux_target_ops): Remove linux_supports_btrace.
4032 * nto-low.c (nto_target_ops): Remove NULL for supports_btrace.
4033 * spu-low.c (spu_target_ops): Likewise.
4034 * win32-low.c (win32_target_ops): Likewise.
4035 * server.c (supported_btrace_packets): Report packets unconditionally.
4036 * target.h (target_ops) <supports_btrace>: Remove.
4037 (target_supports_btrace): Remove.
4038
4039 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
4040
4041 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt)
4042 (handle_btrace_disable): Change return type to void. Use exceptions
4043 to report errors.
4044 (handle_btrace_general_set): Catch exception and copy message to
4045 return message.
4046
4047 2018-02-08 Tom Tromey <tom@tromey.com>
4048
4049 * linux-low.c (install_software_single_step_breakpoints): Use
4050 make_scoped_restore.
4051 * inferiors.c (make_cleanup_restore_current_thread): Remove.
4052 (do_restore_current_thread_cleanup): Remove.
4053 * gdbthread.h (make_cleanup_restore_current_thread): Don't
4054 declare.
4055
4056 2018-02-08 Tom Tromey <tom@tromey.com>
4057
4058 * mem-break.c (set_raw_breakpoint_at): Use
4059 gdb::unique_xmalloc_ptr.
4060
4061 2018-01-30 Pedro Alves <palves@redhat.com>
4062
4063 PR gdb/13211
4064 * target.c (target_terminal::terminal_state): Rename to ...
4065 (target_terminal::m_terminal_state): ... this.
4066
4067 2018-01-19 James Clarke <jrtc27@jrtc27.com>
4068
4069 * linux-low.c (handle_extended_wait): Surround call to
4070 thread_db_notice_clone with #ifdef USE_THREAD_DB.
4071
4072 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
4073
4074 * linux-low.c (attach_proc_task_lwp_callback): Adjust to
4075 linux_ptrace_attach_fail_reason_string now returning an
4076 std::string.
4077 (linux_attach): Likewise.
4078 * thread-db.c (attach_thread): Likewise.
4079
4080 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
4081
4082 PR gdb/21559
4083 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
4084 checking for fs_base/gs_base fields in struct user_regs_struct.
4085 * configure: Regenerate.
4086
4087 2018-01-16 Yao Qi <yao.qi@linaro.org>
4088
4089 PR gdb/18749
4090 * linux-low.c (fetch_register): Call supply_register instead of
4091 error.
4092
4093 2018-01-08 Yao Qi <yao.qi@linaro.org>
4094 Simon Marchi <simon.marchi@ericsson.com>
4095
4096 * Makefile.in (OBS): Remove selftest.o.
4097 * configure.ac: Set srv_selftest_objs if $development is true.
4098 (GDBSERVER_DEPFILES): Append $srv_selftest_objs.
4099 * configure: Re-generated.
4100 * server.c (captured_main): Wrap variable selftest_filter with
4101 GDB_SELF_TEST.
4102
4103 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
4104
4105 * server.c (parse_debug_format_options): Return std::string.
4106 (handle_monitor_command, captured_main): Adjust.
4107
4108 2018-01-05 Pedro Alves <palves@redhat.com>
4109
4110 PR gdb/18653
4111 * server.c (captured_main): Pass quiet=false to
4112 save_original_signals_state.
4113
4114 2018-01-01 Joel Brobecker <brobecker@adacore.com>
4115
4116 * gdbreplay.c (gdbreplay_version): Update copyright year in
4117 version message.
4118 * server.c (gdbserver_version): Likewise.
4119
4120 2017-12-08 Tom Tromey <tom@tromey.com>
4121
4122 * ax.c (ax_printf): Update.
4123
4124 2017-12-07 Yao Qi <yao.qi@linaro.org>
4125
4126 * linux-aarch64-ipa.c (initialize_low_tracepoint): Call
4127 aarch64_linux_read_description.
4128 * linux-amd64-ipa.c (idx2mask): New array.
4129 (get_ipa_tdesc): Move idx2mask out.
4130 (initialize_low_tracepoint): Initialize target descriptions.
4131 * linux-i386-ipa.c (idx2mask): New array.
4132 (get_ipa_tdesc): Move idx2mask out.
4133 (initialize_low_tracepoint): Initialize target descriptions.
4134
4135 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
4136
4137 * tdesc.c (struct tdesc_type): Change return type.
4138 (tdesc_add_flag): Change parameter type.
4139 (tdesc_add_bitfield): Likewise.
4140 (tdesc_add_field): Likewise.
4141 (tdesc_set_struct_size): Likewise.
4142
4143 2017-12-05 Simon Marchi <simon.marchi@ericsson.com>
4144
4145 * regcache.c (registers_to_string): Remove unused variable.
4146
4147 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4148
4149 * inferiors.c (for_each_inferior_with_data): Remove.
4150 * inferiors.h (for_each_inferior_with_data): Remove.
4151 * server.c (handle_qxfer_threads_worker): Change parameter type.
4152 (handle_qxfer_threads_proper): Use for_each_thread.
4153
4154 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4155
4156 * inferiors.c (for_each_inferior): Remove.
4157 (clear_inferiors): Use for_each_thread.
4158 * inferiors.h (for_each_inferior): Remove.
4159 * linux-low.c (linux_wait_for_event_filtered): Use
4160 for_each_thread.
4161 (linux_stabilize_threads): Likewise.
4162 * regcache.c (regcache_release): Likewise.
4163 * server.c (gdb_wants_all_threads_stopped): Likewise.
4164 (clear_pending_status_callback): Remove.
4165 (handle_status): Use for_each_thread.
4166 (captured_main): Likewise.
4167 * win32-low.c (child_init_thread_list): Likewise.
4168 (win32_clear_inferiors): Likewise.
4169 (fake_breakpoint_event): Likewise.
4170
4171 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4172
4173 * inferiors.h (find_inferior): Remove.
4174 * inferiors.c (find_inferior): Remove.
4175
4176 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4177
4178 * linux-low.c (resume_status_pending_p): Update comment.
4179 (need_step_over_p): Update comment.
4180
4181 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4182
4183 * linux-low.c (proceed_one_lwp): Return void, change parameter
4184 type.
4185 (unsuspend_and_proceed_one_lwp): Likewise.
4186 (proceed_all_lwps): Use for_each_thread.
4187 (unstop_all_lwps): Likewise.
4188
4189 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4190
4191 * linux-low.c (linux_resume_one_thread): Return void, take
4192 parameter directly.
4193 (linux_resume): Use for_each_thread.
4194
4195 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4196
4197 * linux-low.c (send_sigstop_callback): Return void, change
4198 parameter type. Rename to...
4199 (send_sigstop): ... this.
4200 (suspend_and_send_sigstop_callback): Return void, change parameter
4201 type. Rename to...
4202 (suspend_and_send_sigstop): ... this.
4203 (stop_all_lwps): Use for_each_thread.
4204
4205 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4206
4207 * linux-low.c (lwp_running): Return bool, remove unused
4208 argument.
4209 (linux_stabilize_threads): Use find_thread.
4210
4211 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4212
4213 * linux-low.c (select_singlestep_lwp_callback): Remove.
4214 (count_events_callback): Remove.
4215 (select_event_lwp_callback): Remove.
4216 (select_event_lwp): Use find_thread/for_each_thread.
4217
4218 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4219
4220 * linux-low.c (not_stopped_callback): Return bool, take filter
4221 argument directly.
4222 (linux_wait_for_event_filtered): Use find_thread.
4223 (linux_wait_1): Likewise.
4224
4225 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4226
4227 * linux-low.c (same_lwp): Remove.
4228 (find_lwp_pid): Use find_thread.
4229
4230 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4231
4232 * linux-low.c (delete_lwp_callback): Remove.
4233 (linux_mourn): Use for_each_thread.
4234
4235 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4236
4237 * linux-low.c (linux_detach_lwp_callback): Return void, remove
4238 args parameter, don't check for pid.
4239 (linux_detach): Use for_each_thread.
4240
4241 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4242
4243 * linux-low.c (struct counter): Remove.
4244 (second_thread_of_pid_p): Remove.
4245 (last_thread_of_process_p): Use find_thread.
4246
4247 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4248
4249 * inferiors.c (find_inferior_in_random): Remove.
4250 * inferiors.h (find_inferior_in_random): Remove.
4251 * linux-low.c (status_pending_p_callback): Return bool, accept
4252 parameter ptid directly.
4253 (linux_wait_for_event_filtered): Use find_thread_in_random.
4254 (linux_wait_1): Likewise.
4255
4256 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4257
4258 * inferiors.c (find_inferior_id): Remove.
4259 (find_thread_ptid): Move implemention from find_inferior_id to
4260 here.
4261 * inferiors.h (find_inferior_id): Remove.
4262 * server.c (handle_status): Use find_thread_ptid.
4263 (process_serial_event): Likewise.
4264 * thread-db.c (find_one_thread): Likewise.
4265 (thread_db_thread_handle): Likewise.
4266 * win32-low.c (thread_rec): Likewise.
4267 (child_delete_thread): Likewise.
4268 (win32_thread_alive): Likewise.
4269 (get_child_debug_event): Likewise.
4270
4271 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4272
4273 * linux-mips-low.c (update_watch_registers_callback): Return
4274 void, remove pid_p parameter, don't check for pid.
4275 (mips_insert_point, mips_remove_point): Use for_each_thread.
4276
4277 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4278
4279 * lynx.low (lynx_delete_thread_callback): Remove.
4280 (lynx_mourn): Use for_each_thread.
4281
4282 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
4283
4284 * regcache.c (regcache_invalidate_one): Remove.
4285 (regcache_invalidate_pid): use for_each_thread.
4286
4287 2017-11-26 Tom Tromey <tom@tromey.com>
4288
4289 * linux-low.c (linux_create_inferior): Update.
4290
4291 2017-11-24 Ulrich Weigand <uweigand@de.ibm.com>
4292
4293 * spu-low.c (spu_create_inferior): Fix typo in argument name.
4294
4295 2017-11-24 Alan Hayward <alan.hayward@arm.com>
4296
4297 * configure.srv: Add linux-aarch64-tdesc-selftest.o.
4298 * linux-aarch64-low.c (initialize_low_arch): Call init func.
4299 * linux-aarch64-tdesc-selftest.c: New file.
4300 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
4301
4302 2017-11-24 Alan Hayward <alan.hayward@arm.com>
4303
4304 * configure.srv: Add new file.
4305 * linux-aarch64-low.c (initialize_low_arch): Call init func.
4306 * linux-aarch64-tdesc-selftest.c: New file.
4307 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
4308
4309 2017-11-24 Alan Hayward <alan.hayward@arm.com>
4310
4311 * linux-aarch64-ipa.c (initialize_low_tracepoint): Remove init.
4312 * linux-aarch64-low.c (initialize_low_arch): Remove init.
4313 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add init.
4314
4315 2017-11-24 Alan Hayward <alan.hayward@arm.com>
4316
4317 * configure.srv: Add new files.
4318 * linux-aarch64-ipa.c (get_ipa_tdesc): Call
4319 aarch64_linux_read_description.
4320 * linux-aarch64-low.c (aarch64_linux_read_description):
4321 Merge with aarch64_arch_setup.
4322 (aarch64_arch_setup): Call aarch64_linux_read_description.
4323 * linux-aarch64-tdesc.c: New file.
4324 * linux-aarch64-tdesc.h: New file.
4325
4326 2017-11-24 Yao Qi <yao.qi@linaro.org>
4327
4328 * configure.srv: Set $srv_regobj for tic6x-linux.
4329 * linux-tic6x-low.c: Include "arch/tic6x.h" and "tdesc.h".
4330 (tic6x_read_description): Move some code to tic6x_arch_setup.
4331 (tic6x_tdesc_test): New function.
4332 (initialize_low_arch): Call selftests::register_test.
4333
4334 2017-11-22 Yao Qi <yao.qi@linaro.org>
4335
4336 * remote-utils.c (prepare_resume_reply): Use memcpy.
4337
4338 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
4339
4340 * linux-low.c (kill_one_lwp_callback): Return void, take
4341 argument directly, don't filter on pid.
4342 (linux_kill): Use for_each_thread.
4343
4344 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
4345
4346 * linux-low.c (need_step_over_p): Return bool, remove dummy
4347 argument.
4348 (linux_resume, proceed_all_lwps): Use find_thread.
4349
4350 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
4351
4352 * linux-low.c (resume_status_pending_p): Return bool, remove
4353 flag_p argument.
4354 (linux_resume): Use find_thread.
4355
4356 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
4357
4358 * linux-low.c (struct thread_resume_array): Remove.
4359 (linux_set_resume_request): Return void, take arguments
4360 directly.
4361 (linux_resume): Use for_each_thread.
4362
4363 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
4364
4365 * linux-low.c (stuck_in_jump_pad_callback): Change prototype,
4366 return bool, remove data argument.
4367 (linux_stabilize_threads): Use find_thread.
4368
4369 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
4370
4371 * linux-low.c (unsuspend_one_lwp): Remove.
4372 (unsuspend_all_lwps): Use for_each_thread, inline code from
4373 unsuspend_one_lwp.
4374
4375 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
4376
4377 * gdbthread.h (find_thread): Add overload with ptid_t filter.
4378 * linux-low.c (struct iterate_over_lwps_args): Remove.
4379 (iterate_over_lwps_filter): Remove.
4380 (iterate_over_lwps): Use find_thread.
4381
4382 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
4383
4384 * linux-low.c (reset_lwp_ptrace_options_callback): Remove.
4385 (linux_handle_new_gdb_connection): Use for_each_thread, inline
4386 code from reset_lwp_ptrace_options_callback.
4387
4388 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
4389
4390 * linux-arm-low.c (struct update_registers_data): Remove.
4391 (update_registers_callback): Return void, take arguments
4392 directly, don't check thread's pid.
4393 (arm_insert_point, arm_remove_point): Use for_each_thread.
4394
4395 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
4396
4397 * win32-low.c (continue_one_thread): Return void, take argument
4398 directly.
4399 (child_continue): Use for_each_thread.
4400
4401 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
4402
4403 * win32-i386-low.c (update_debug_registers_callback): Rename
4404 to ...
4405 (update_debug_registers): ... this, return void, remove pid_p arg.
4406 (x86_dr_low_set_addr, x86_dr_low_set_control): Use for_each_thread.
4407
4408 2017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
4409
4410 * inferiors.h (struct process_info): Add constructor, initialize
4411 fields..
4412 <syscalls_to_catch>: Change type to std::vector<int>.
4413 * inferiors.c (add_process): Allocate process_info with new.
4414 (remove_process): Free process_info with delete.
4415 * linux-low.c (handle_extended_wait): Adjust.
4416 (gdb_catching_syscalls_p, gdb_catch_this_syscall_p): Adjust.
4417 * server.c (handle_general_set): Adjust.
4418
4419 2017-11-16 Pedro Alves <palves@redhat.com>
4420
4421 * remote-utils.c (remote_close): Block SIGIO signals instead of
4422 uninstalling the SIGIO handler.
4423
4424 2017-11-16 Alan Hayward <alan.hayward@arm.com>
4425
4426 * tdesc.c (tdesc_get_features_xml): Allow null osabi.
4427
4428 2017-11-16 Yao Qi <yao.qi@linaro.org>
4429
4430 * linux-tic6x-low.c (tic6x_fill_gregset): Cast buf.
4431 (tic6x_store_gregset): Likewise.
4432 (tic6x_usrregs_info): Move it up.
4433
4434 2017-11-15 Alan Hayward <alan.hayward@arm.com>
4435
4436 * Makefile.in: Update arch rules.
4437 * configure.srv: Explicitly mark arch/ files.
4438
4439 2017-11-13 Andreas Schwab <schwab@suse.de>
4440
4441 * linux-m68k-low.c (m68k_supports_hardware_single_step): New
4442 function.
4443 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4444
4445 2017-11-06 Pedro Alves <palves@redhat.com>
4446
4447 * config.in, configure: Regenerate.
4448
4449 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
4450
4451 * target.c (struct thread_search): Remove.
4452 (thread_search_callback): Remove.
4453 (prepare_to_access_memory): Use for_each_thread instead of
4454 find_inferior. Inline code from thread_search_callback.
4455
4456 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
4457
4458 * server.c (struct visit_actioned_threads_data): Remove.
4459 (visit_actioned_threads): Change prototype to take arguments
4460 directly.
4461 (resume): Use find_thread instead of find_inferior.
4462
4463 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
4464
4465 * server.c (queue_stop_reply_callback): Change prototype, return
4466 void.
4467 (find_status_pending_thread_callback): Remove.
4468 (handle_status): Replace find_inferior with find_thread and
4469 for_each_thread.
4470
4471 2017-10-25 Alan Hayward <alan.hayward@arm.com>
4472
4473 * linux-aarch64-low.c (aarch64_fill_gregset): Replace defines
4474 with REGNO.
4475 (aarch64_store_gregset): Likewise.
4476 (aarch64_fill_fpregset): Likewise.
4477 (aarch64_store_fpregset): Likewise.
4478
4479 2017-10-21 Simon Marchi <simon.marchi@ericsson.com>
4480
4481 * gdbthread.h (find_thread, for_each_thread): New functions.
4482 * inferiors.c (thread_of_pid): Remove.
4483 (find_any_thread_of_pid): Use find_thread.
4484 * linux-low.c (num_lwps): Use for_each_thread.
4485
4486 2017-10-17 Yao Qi <yao.qi@linaro.org>
4487
4488 * Makefile.in: Remove one rule.
4489 * configure.srv: Rename aarch64-insn.o with arch/aarch64-insn.o.
4490
4491 2017-10-17 Yao Qi <yao.qi@linaro.org>
4492
4493 * configure.srv: Rename arm-linux.o with arch/arm-linux.o.
4494 Rename arm-get-next-pcs.o with arch/arm-get-next-pcs.o.
4495
4496 2017-10-17 Yao Qi <yao.qi@linaro.org>
4497
4498 * configure.srv: Rename arm.o with arch/arm.o.
4499
4500 2017-10-17 Yao Qi <yao.qi@linaro.org>
4501
4502 * Makefile.in (CONFIG_SRC_SUBDIR): New variable.
4503 (clean): Remove .o files in CONFIG_SRC_SUBDIR.
4504 (distclean): Remove DEPDIR in CONFIG_SRC_SUBDIR.
4505 (arch-i386.o, arch-amd64.o): Remove rules.
4506 (arch/%.o): New rule.
4507 Update POSTCOMPILE and COMPILE.pre.
4508 * configure.ac: Invoke AC_CONFIG_COMMANDS.
4509 * configure: Re-generated.
4510 * configure.srv: Replace arch-i386.o with arch/i386.o.
4511 Replace arch-amd64.o with arch/amd64.o.
4512
4513 2017-10-16 Yao Qi <yao.qi@linaro.org>
4514
4515 * configure: Regenerated.
4516
4517 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
4518
4519 * inferiors.h: (struct inferior_list): Remove.
4520 (struct inferior_list_entry); Remove.
4521 (add_inferior_to_list, clear_inferior_list, one_inferior_p,
4522 A_I_NEXT, ALL_INFERIORS_TYPE, ALL_INFERIORS, remove_inferior,
4523 get_first_inferior): Remove.
4524 (for_each_inferior, for_each_inferior_with_data, find_inferior,
4525 find_inferior_id, find_inferior_in_random): Change signature.
4526 * inferiors.c (all_threads): Change type to
4527 std::list<thread_info *>.
4528 (get_thread): Remove macro.
4529 (find_inferior, find_inferior_id): Change signature, implement
4530 using find_thread.
4531 (find_inferior_in_random): Change signature, implement using
4532 find_thread_in_random.
4533 (for_each_inferior, for_each_inferior_with_data): Change
4534 signature, implement using for_each_thread.
4535 (add_inferior_to_list, remove_inferior): Remove.
4536 (add_thread, get_first_thread, thread_of_pid,
4537 find_any_thread_of_pid, free_one_thread, remove_thread): Update.
4538 (get_first_inferior, one_inferior_p, clear_inferior_list):
4539 Remove.
4540 (clear_inferiors, get_thread_process): Update.
4541 * gdbthread.h: Include <list>.
4542 (struct thread_info) <entry>: Remove field.
4543 <id>: New field.
4544 (all_threads): Change type to std::list<thread_info *>.
4545 (get_first_inferior): Add doc.
4546 (find_thread, for_each_thread, find_thread_in_random): New
4547 functions.
4548 (current_ptid, pid_of, ptid_of, lwpid_of): Update.
4549 * linux-arm-low.c (update_registers_callback): Update.
4550 * linux-low.c (second_thread_of_pid_p): Update.
4551 (kill_one_lwp_callback, linux_detach_lwp_callback,
4552 delete_lwp_callback, status_pending_p_callback, same_lwp,
4553 find_lwp_pid, num_lwps, iterate_over_lwps_filter,
4554 iterate_over_lwps, not_stopped_callback,
4555 resume_stopped_resumed_lwps, count_events_callback,
4556 select_singlestep_lwp_callback, select_event_lwp_callback,
4557 unsuspend_one_lwp, linux_wait_1, send_sigstop_callback,
4558 suspend_and_send_sigstop_callback, wait_for_sigstop,
4559 stuck_in_jump_pad_callback, move_out_of_jump_pad_callback,
4560 lwp_running, linux_set_resume_request, resume_status_pending_p,
4561 need_step_over_p, start_step_over, linux_resume_one_thread,
4562 proceed_one_lwp, unsuspend_and_proceed_one_lwp,
4563 reset_lwp_ptrace_options_callback): Update.
4564 * linux-mips-low.c (update_watch_registers_callback): Update.
4565 * regcache.c (regcache_invalidate_one, regcache_invalidate):
4566 Update.
4567 (free_register_cache_thread_one): Remove.
4568 (regcache_release): Update.
4569 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt,
4570 handle_qxfer_threads_worker): Update.
4571 (handle_query): Update, use list iterator.
4572 (visit_actioned_threads, handle_pending_status,
4573 queue_stop_reply_callback, gdb_wants_all_threads_stopped,
4574 clear_pending_status_callback, set_pending_status_callback,
4575 find_status_pending_thread_callback, handle_status,
4576 process_serial_event): Update.
4577 * target.c (thread_search_callback): Update.
4578 * thread-db.c (thread_db_get_tls_address): Update.
4579 * tracepoint.c (tracepoint_finished_step, tracepoint_was_hit):
4580 Update.
4581 * win32-i386-low.c (update_debug_registers_callback): Update.
4582 * win32-low.c (delete_thread_info, child_delete_thread,
4583 continue_one_thread, suspend_one_thread,
4584 get_child_debug_event): Adjust.
4585
4586 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
4587
4588 * gdbthread.h (ptid_of, pid_of, lwpid_of): New functions.
4589 * inferiors.h: Include <list>.
4590 (struct process_info) <entry>: Remove field.
4591 <pid>: New field.
4592 (pid_of): Change macro to function.
4593 (ptid_of, lwpid_of): Remove macro.
4594 (all_processes): Change type to std::list<process_info *>.
4595 (ALL_PROCESSES): Remove macro.
4596 (for_each_process, find_process): New function.
4597 * inferiors.c (all_processes): Change type to
4598 std::list<process_info *>.
4599 (find_thread_process): Adjust.
4600 (add_process): Likewise.
4601 (remove_process): Likewise.
4602 (find_process_pid): Likewise.
4603 (get_first_process): Likewise.
4604 (started_inferior_callback): Remove.
4605 (have_started_inferiors_p): Adjust.
4606 (attached_inferior_callback): Remove.
4607 (have_attached_inferiors_p): Adjust.
4608 * linux-low.c (check_zombie_leaders): Likewise.
4609 * linux-x86-low.c (x86_arch_setup_process_callback): Remove.
4610 (x86_linux_update_xmltarget): Adjust.
4611 * server.c (handle_query): Likewise.
4612 (gdb_reattached_process): Remove.
4613 (handle_status): Adjust.
4614 (kill_inferior_callback): Likewise.
4615 (detach_or_kill_inferior): Remove.
4616 (print_started_pid): Likewise.
4617 (print_attached_pid): Likewise.
4618 (detach_or_kill_for_exit): Update.
4619 (process_serial_event): Likewise.
4620 * linux-arm-low.c (arm_new_fork): Likewise.
4621
4622 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
4623
4624 * dll.h: Include <list>.
4625 (struct dll_info): Add constructor.
4626 <entry>: Remove field.
4627 (all_dlls): Change type to std::list<dll_info>.
4628 * dll.c: Include <algorithm>.
4629 (get_dll): Remove macro.
4630 (all_dlls): Change type to std::list<dll_info *>.
4631 (free_one_dll): Remove.
4632 (match_dll): Likewise.
4633 (loaded_dll): Adjust.
4634 (unloaded_dll): Adjust to all_dlls type change, use
4635 std::find_if. Inline code from match_dll.
4636 (clear_dlls): Adjust to all_dlls type change.
4637 * server.c (emit_dll_description): Remove.
4638 (handle_qxfer_libraries): Adjust to all_dlls type change,
4639 integrate emit_dll_description's functionality.
4640
4641 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
4642
4643 * linux-low.h (struct linux_target_ops) <delete_process>: New
4644 field.
4645 * linux-low.c (linux_mourn): Call the_low_target.delete_process.
4646 * linux-aarch64-low.c (aarch64_linux_delete_process): New.
4647 (struct linux_target_ops): Add delete_process callback.
4648 * linux-arm-low.c (arm_delete_process): New.
4649 (struct linux_target_ops): Add delete_process callback.
4650 * linux-bfin-low.c (struct linux_target_ops): Likewise.
4651 * linux-crisv32-low.c (struct linux_target_ops): Likewise.
4652 * linux-m32r-low.c (struct linux_target_ops): Likewise.
4653 * linux-mips-low.c (mips_linux_delete_process): New.
4654 (struct linux_target_ops): Add delete_process callback.
4655 * linux-ppc-low.c (struct linux_target_ops): Likewise.
4656 * linux-s390-low.c (struct linux_target_ops): Likewise.
4657 * linux-sh-low.c (struct linux_target_ops): Likewise.
4658 * linux-tic6x-low.c (struct linux_target_ops): Likewise.
4659 * linux-tile-low.c (struct linux_target_ops): Likewise.
4660 * linux-x86-low.c (x86_linux_delete_process): New.
4661 (struct linux_target_ops): Add delete_process callback.
4662 * linux-xtensa-low.c (struct linux_target_ops): Likewise.
4663
4664 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
4665
4666 * linux-aarch64-low.c (the_low_target): Add thread delete
4667 callback.
4668 * linux-arm-low.c (arm_delete_thread): New function.
4669 (the_low_target): Add thread delete callback.
4670 * linux-bfin-low.c (the_low_target): Likewise.
4671 * linux-crisv32-low.c (the_low_target): Likewise.
4672 * linux-low.c (delete_lwp): Invoke delete_thread callback if
4673 set.
4674 * linux-low.h (struct linux_target_ops) <delete_thread>: New
4675 field.
4676 * linux-m32r-low.c (the_low_target): Add thread delete callback.
4677 * linux-mips-low.c (mips_linux_delete_thread): New function.
4678 (the_low_target): Add thread delete callback.
4679 * linux-ppc-low.c (the_low_target): Likewise.
4680 * linux-s390-low.c (the_low_target): Likewise.
4681 * linux-sh-low.c (the_low_target): Likewise.
4682 * linux-tic6x-low.c (the_low_target): Likewise.
4683 * linux-tile-low.c (the_low_target): Likewise.
4684 * linux-x86-low.c (the_low_target): Likewise.
4685 * linux-xtensa-low.c (the_low_target): Likewise.
4686
4687 2017-10-06 Yuanhui Zhang <asmwarrior@gmail.com>
4688
4689 * win32-low.c: Include "common-inferior.h".
4690
4691 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
4692
4693 * inferiors.c (set_inferior_cwd): New function.
4694 * server.c (handle_general_set): Handle QSetWorkingDir packet.
4695 (handle_query): Inform that QSetWorkingDir is supported.
4696 * win32-low.c (create_process): Pass the inferior's cwd to
4697 CreateProcess.
4698
4699 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
4700
4701 * inferiors.c (current_inferior_cwd): New global variable.
4702 (get_inferior_cwd): New function.
4703 * inferiors.h (struct process_info) <cwd>: New field.
4704
4705 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
4706
4707 * Makefile.in (SFILES): Add $(srcdir)/common/gdb_tilde_expand.c.
4708 (OBS): Add gdb_tilde_expand.o.
4709
4710 2017-10-02 Simon Marchi <simon.marchi@ericsson.com>
4711
4712 * lynx-i386-low.c (lynx_i386_arch_setup): Call init_target_desc.
4713 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
4714
4715 2017-09-29 Pedro Alves <palves@redhat.com>
4716
4717 * ax.c (gdb_parse_agent_expr): Constify.
4718 * ax.h (gdb_parse_agent_expr): Constify.
4719 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
4720 Constify.
4721 * mem-break.h (add_breakpoint_condition, add_breakpoint_commands): Constify.
4722 * remote-utils.c (hex_or_minus_one, read_ptid): Constify.
4723 * remote-utils.h (read_ptid): Constify.
4724 * server.c (handle_qxfer_exec_file, handle_query, handle_v_cont)
4725 (process_point_options, process_serial_event): Constify.
4726 * tracepoint.c (add_tracepoint_action, cmd_qtdp, cmd_qtdpsrc)
4727 (cmd_qtdv, cmd_qtenable_disable, cmd_qtro, cmd_qtframe, cmd_qtp)
4728 (cmd_qtbuffer): Constify.
4729
4730 2017-09-29 Pedro Alves <palves@redhat.com>
4731
4732 * proc-service.c (ps_pdread): Return PS_ERR if reading memory
4733 fails.
4734
4735 2017-09-29 Pedro Alves <palves@redhat.com>
4736
4737 * linux-low.c (handle_extended_wait): Pass parent thread instead
4738 of process to thread_db_notice_clone.
4739 * linux-low.h (thread_db_notice_clone): Replace parent process
4740 parameter with parent thread parameter.
4741 * thread-db.c (find_one_thread): Add comment.
4742 (thread_db_notice_clone): Replace parent process parameter with
4743 parent thread parameter. Temporarily switch to the parent thread.
4744
4745 2017-09-26 Sergio Durigan Junior <sergiodj@redhat.com>
4746
4747 * gdbthread.h: Include "common-gdbthread.h".
4748 * inferiors.c (switch_to_thread): Use "gdb_assert" instead of
4749 "if" when validating the ptid.
4750 * remote-utils.c: Include "gdbthread.h".
4751 (prepare_resume_reply): Use "switch_to_thread".
4752 * target.c (done_accessing_memory): Likewise.
4753
4754 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
4755
4756 * configure.srv (s390*-*-linux*): Add s390-gs-linux64.o and
4757 s390x-gs-linux64.o to srv_regobj. Add s390-gs-linux64.xml,
4758 s390x-gs-linux64.xml, s390-gs.xml, and s390-gsbc.xml to
4759 srv_xmlfiles. Add s390-gs-linux64-ipa.o and
4760 s390x-gs-linux64-ipa.o to ipa_obj.
4761 * linux-s390-low.c (HWCAP_S390_GS): New define.
4762 (s390_fill_gs, s390_store_gs, s390_fill_gsbc, s390_store_gsbc):
4763 New functions.
4764 (s390_regsets): Add regsets for NT_S390_GS_CB and NT_S390_GS_BC.
4765 (s390_arch_setup): Check for guarded-storage support and choose
4766 appropriate tdesc.
4767 (initialize_low_arch): Invoke init_registers_s390_gs_linux64 and
4768 init_registers_s390x_gs_linux64.
4769 * linux-s390-tdesc.h (enum s390_linux_tdesc) <S390_TDESC_GS>: New
4770 enum value.
4771 (init_registers_s390x_gs_linux64, tdesc_s390x_gs_linux64)
4772 (init_registers_s390_gs_linux64, tdesc_s390_gs_linux64): Declare.
4773
4774 2017-09-22 Simon Marchi <simon.marchi@ericsson.com>
4775
4776 * win32-i386-low.c (i386_arch_setup): Call init_target_desc.
4777
4778 2017-09-21 Kevin Buettner <kevinb@redhat.com>
4779
4780 * linux-low.h (struct lwp_info): Add new field, thread_handle.
4781 (thread_db_thread_handle): Declare.
4782 * linux-low.c (linux_target_ops): Initialize thread_handle.
4783 * server.c (handle_qxfer_threads_worker): Add support for
4784 "handle" attribute.
4785 * target.h (struct target_ops): Add new function pointer,
4786 thread_handle.
4787 (target_thread_handle): Define.
4788 * thread-db.c (find_one_thread, attach_thread): Set thread_handle
4789 field in lwp.
4790 (thread_db_thread_handle): New function.
4791
4792 2017-09-21 Kevin Buettner <kevinb@redhat.com>
4793
4794 * linux-low.c (handle_extended_wait): Call thread_db_notice_clone().
4795 * linux-low.h (thread_db_notice_clone): Declare.
4796 * thread-db.c (thread_db_notice_clone): New function.
4797
4798 2017-09-21 Pedro Alves <palves@redhat.com>
4799
4800 * server.c (gdb_read_memory, handle_status, process_serial_event)
4801 (handle_serial_event, handle_target_event): Adjust to
4802 set_desired_thread prototype change.
4803 * target.c (set_desired_thread): Remove 'use_general' parameter
4804 and adjust.
4805 * target.h (set_desired_thread): Remove 'use_general' parameter.
4806
4807 2017-09-20 Tom Tromey <tom@tromey.com>
4808
4809 * target.c (target_terminal::terminal_state): Define.
4810 (target_terminal::init): Rename from target_terminal_init.
4811 (target_terminal::inferior): Rename from
4812 target_terminal_inferior.
4813 (target_terminal::ours): Rename from target_terminal_ours.
4814 (target_terminal::ours_for_output, target_terminal::info): New.
4815
4816 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
4817
4818 * server.c (accumulate_file_name_length): Remove.
4819 (emit_dll_description): Adjust to std::string change.
4820 (handle_qxfer_libraries): Use std::string to hold document.
4821
4822 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
4823
4824 * linux-low.c (linux_qxfer_libraries_svr4): Adjust to change of
4825 return type of xml_escape_text.
4826 * server.c (emit_dll_description): Likewise.
4827
4828 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
4829
4830 * server.c (captured_main): Accept argument for --selftest.
4831 Update run_tests call.
4832 * linux-x86-tdesc-selftest.c (initialize_low_tdesc): Add names
4833 when registering selftests.
4834
4835 2017-09-16 Sergio Durigan Junior <sergiodj@redhat.com>
4836
4837 * regcache.c (get_thread_regcache): Update code to use "std::vector"
4838 instead of "VEC" for "target_desc.reg_defs".
4839 (regcache_cpy): Likewise.
4840 (registers_to_string): Likewise.
4841 (registers_from_string): Likewise.
4842 (find_regno): Likewise.
4843 (supply_regblock): Likewise.
4844 (regcache_raw_read_unsigned): Likewise.
4845 * tdesc.c (init_target_desc): Likewise.
4846 (tdesc_create_reg): Likewise.
4847 * tdesc.h: Remove declaration of "tdesc_reg_p". Include <vector>.
4848 (struct target_desc) <reg_defs>: Convert to "std::vector".
4849 (target_desc): Do not initialize "reg_defs".
4850 (~target_desc): Update code to use "std::vector" instead of "VEC"
4851 for "target_desc.reg_defs".
4852 (operator==): Likewise.
4853
4854 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
4855
4856 * inferiors.h (thread_to_gdb_id): Remove.
4857 * inferiors.c (thread_to_gdb_id): Remove.
4858 * server.c (handle_qxfer_threads_worker, handle_query): Adjust.
4859 * lynx-low.c (lynx_resume, lynx_wait_1, lynx_fetch_registers,
4860 lynx_store_registers, lynx_read_memory, lynx_write_memory):
4861 Likewise.
4862 * nto-low.c (nto_fetch_registers, nto_store_registers,
4863 nto_stopped_by_watchpoint, nto_stopped_data_address): Likewise.
4864
4865 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
4866
4867 * inferiors.h (gdb_id_to_thread_id): Remove.
4868 * inferiors.c (gdb_id_to_thread_id): Remove.
4869 * server.c (process_serial_event): Adjust to gdb_id_to_thread_id
4870 removal. Move pid declaration closer to where it's used.
4871
4872 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
4873
4874 * server.c (handle_detach): New function.
4875 (process_serial_event): Move code out, call handle_detach.
4876
4877 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
4878
4879 * server.c (require_running): Rename to ...
4880 (require_running_or_return): ... this ...
4881 (require_running_or_break): ... and this.
4882 (handle_query, process_serial_event): Adjust.
4883
4884 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
4885
4886 * linux-low.c (linux_set_resume_request): Remove unused
4887 variables.
4888
4889 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
4890
4891 * server.c (first_thread_of): Remove.
4892 (process_serial_event): Replace usage of first_thread_of with
4893 find_any_thread_of_pid.
4894 * tracepoint.c (same_process_p): Remove.
4895 (gdb_agent_about_to_close): Replace usage of same_process_p with
4896 find_any_thread_of_pid.
4897 * linux-x86-low.c (same_process_callback): Remove.
4898 (x86_arch_setup_process_callback): Replace usage of
4899 same_process_callback with find_any_thread_of_pid.
4900 * thread-db.c (any_thread_of): Remove.
4901 (switch_to_process): Replace usage of any_thread_of with
4902 find_any_thread_of_pid.
4903 * inferiors.c (thread_pid_matches_callback): Remove.
4904 (find_thread_process): Adjust to use find_any_thread_of_pid.
4905
4906 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
4907
4908 * regcache.c (get_thread_regcache): Guard calls to "memset"
4909 with "!VEC_empty".
4910
4911 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
4912
4913 * linux-low.c (handle_extended_wait): Use
4914 "allocate_target_description" instead of "XNEW".
4915 * linux-x86-low.c (initialize_low_arch): Likewise.
4916
4917 2017-09-05 Yao Qi <yao.qi@linaro.org>
4918
4919 * configure.srv (srv_i386_regobj): Remove.
4920 (srv_amd64_regobj): Remove.
4921 (srv_regobj): Set it to "" for x86 non-linux targets.
4922 * linux-x86-tdesc.c (i386_linux_read_description):
4923 * lynx-i386-low.c: Include x86-xstate.h and arch/i386.h.
4924 (init_registers_i386): Remove the declaration.
4925 (tdesc_i386): Remove the declaration.
4926 (lynx_i386_arch_setup): Call i386_create_target_description.
4927 * nto-x86-low.c: Likewise.
4928 * win32-i386-low.c [__x86_64__]: include arch/amd64.h.
4929 [!__x86_64__]: include arch/i386.h.
4930 (i386_arch_setup) [__x86_64__]: Call amd64_create_target_description.
4931
4932 2017-09-05 Yao Qi <yao.qi@linaro.org>
4933
4934 * configure.srv (srv_amd64_linux_xmlfiles): Remove
4935 i386/amd64-XXX-linux from it.
4936
4937 2017-09-05 Yao Qi <yao.qi@linaro.org>
4938
4939 * configure.srv: Empty srv_amd64_linux_regobj if $development is
4940 false.
4941 (ipa_amd64_linux_regobj): Remove.
4942 (ipa_x32_linux_regobj): Remove.
4943
4944 2017-09-05 Yao Qi <yao.qi@linaro.org>
4945
4946 * Makefile.in (arch-amd64.o): New rule.
4947 * configure.srv: Append arch-amd64.o.
4948 * linux-amd64-ipa.c: Include common/x86-xstate.h.
4949 (get_ipa_tdesc): Call amd64_linux_read_description.
4950 (initialize_low_tracepoint): Don't call init_registers_x32_XXX
4951 and init_registers_amd64_XXX.
4952 * linux-x86-low.c (x86_linux_read_description): Call
4953 amd64_linux_read_description.
4954 (x86_get_ipa_tdesc_idx): Call amd64_get_ipa_tdesc_idx.
4955 (initialize_low_arch): Don't call init_registers_x32_XXX and
4956 init_registers_amd64_XXX.
4957 * linux-x86-tdesc-selftest.c: Declare init_registers_amd64_XXX
4958 and tdesc_amd64_XXX.
4959 [__x86_64__] (amd64_tdesc_test): New function.
4960 (initialize_low_tdesc) [__x86_64__]: Call init_registers_x32_XXX
4961 and init_registers_amd64_XXX.
4962 * linux-x86-tdesc.c: Include arch/amd64.h.
4963 (xcr0_to_tdesc_idx): New function.
4964 (i386_linux_read_description): New function.
4965 (amd64_get_ipa_tdesc_idx): New function.
4966 * linux-x86-tdesc.h (amd64_get_ipa_tdesc_idx): Declare.
4967 (amd64_get_ipa_tdesc): Declare.
4968
4969 2017-09-05 Yao Qi <yao.qi@linaro.org>
4970
4971 * configure.srv (srv_i386_linux_xmlfiles): Remove
4972 i386/i386-XXX-linux.xml from it.
4973
4974 2017-09-05 Yao Qi <yao.qi@linaro.org>
4975
4976 * configure.srv: Set srv_i386_linux_regobj empty if $development
4977 is false.
4978 * linux-i386-ipa.c (initialize_low_tracepoint): Don't call
4979 initialize_low_tdesc.
4980 * linux-x86-low.c (initialize_low_arch): Wrap initialize_low_tdesc
4981 with #if initialize_low_tdesc.
4982 * linux-x86-tdesc-selftest.c: New file.
4983 * linux-x86-tdesc.c: Move code to linux-x86-tdesc-selftest.c.
4984
4985 2017-09-05 Yao Qi <yao.qi@linaro.org>
4986
4987 * Makefile.in (arch-i386.o): New rule.
4988 * configure.srv (i[34567]86-*-linux*): Add arch-i386.o.
4989 (x86_64-*-linux*): Likewise.
4990 * linux-x86-tdesc.c: Don't include ../features/i386/32bit-XXX.c,
4991 include arch/i386.h.
4992 (i386_linux_read_description): Remove code and call
4993 i386_create_target_description.
4994 * tdesc.c (allocate_target_description): New function.
4995 * tdesc.h (set_tdesc_architecture): Remove declaration.
4996 (set_tdesc_osabi): Likewise.
4997
4998 2017-09-05 Yao Qi <yao.qi@linaro.org>
4999
5000 * linux-x86-tdesc.c: Don't include <inttypes.h>.
5001 (i386_linux_read_description) [!IN_PROCESS_AGENT]: Call
5002 set_tdesc_architecture and set_tdesc_osabi. Remove code setting
5003 .xmltarget.
5004 * server.c (get_features_xml): Call tdesc_get_features_xml.
5005 * tdesc.c (set_tdesc_architecture): New function.
5006 (set_tdesc_osabi): New function.
5007 (tdesc_get_features_xml): New function.
5008 (tdesc_create_feature): Add an argument.
5009 * tdesc.h (struct target_desc) <features>: New field.
5010 <arch, osabi>: New field.
5011 (~target_desc): xfree features, arch, and osabi.
5012 (target_desc::oerator==): Don't compare .xmltarget.
5013 [!IN_PROCESS_AGENT] (set_tdesc_architecture): Declare.
5014 (set_tdesc_osabi): Likewise.
5015 (tdesc_get_features_xml): Likewise.
5016
5017 2017-09-05 Yao Qi <yao.qi@linaro.org>
5018
5019 * linux-x86-tdesc.c: Include selftest.h.
5020 (i386_tdesc_test): New function.
5021 (initialize_low_tdesc): Call selftests::register_test.
5022 * tdesc.h: Include regdef.h.
5023 (target_desc): Override operator == and !=.
5024
5025 2017-09-05 Yao Qi <yao.qi@linaro.org>
5026
5027 * configure.srv (srv_tgtobj): Append linux-x86-tdesc.o.
5028 (ipa_obj): Likewise.
5029 * linux-i386-ipa.c: Include common/x86-xstate.h
5030 (get_ipa_tdesc): Call i386_linux_read_description.
5031 (initialize_low_tracepoint): Don't call init_registers_XXX
5032 functions, call initialize_low_tdesc instead.
5033 * linux-x86-low.c (x86_linux_read_description): Call
5034 i386_linux_read_description.
5035 (initialize_low_arch): Don't call init_registers_i386_XXX
5036 functions, call initialize_low_tdesc.
5037 * linux-x86-tdesc.c: New file.
5038 * linux-x86-tdesc.h (x86_linux_tdesc): New X86_TDESC_LAST.
5039 (i386_get_ipa_tdesc_idx): Declare.
5040 (i386_get_ipa_tdesc): Declare.
5041 (initialize_low_tdesc): Declare.
5042
5043 2017-09-05 Yao Qi <yao.qi@linaro.org>
5044
5045 * linux-x86-low.c (x86_get_ipa_tdesc_idx): Use X86_TDESC_MMX
5046 instead of 0.
5047
5048 2017-09-05 Yao Qi <yao.qi@linaro.org>
5049
5050 * Makefile.in (IPA_OBJS): Add vec-ipa.o
5051 * regcache.c (get_thread_regcache): Use VEC_length.
5052 (init_register_cache): Likewise.
5053 (regcache_cpy): Likewise.
5054 (registers_to_string): Iterate reg_defs via VEC_iterate.
5055 (find_regno): Likewise.
5056 (find_register_by_number): Use VEC_index.
5057 (register_size): Call find_register_by_number.
5058 (register_data): Call find_register_by_number.
5059 (supply_regblock): Use VEC_length.
5060 (regcache_raw_read_unsigned): Likewise.
5061 * tdesc.c (init_target_desc): Iterate reg_defs via
5062 VEC_iterate.
5063 (default_description): Update initializer.
5064 (copy_target_description): Don't update field num_registers.
5065 * tdesc.h (struct target_desc) <reg_defs>: Change it to VEC.
5066 <num_registers>: Remove.
5067
5068 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
5069
5070 * Makefile.in (.SECONDARY): Define target.
5071
5072 2017-09-03 Simon Marchi <simon.marchi@ericsson.com>
5073
5074 * linux-low.c (linux_wait_1): Adjust.
5075 * server.c (queue_stop_reply_callback): Adjust.
5076
5077 2017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
5078
5079 * server.c (handle_general_set): Handle QEnvironmentHexEncoded,
5080 QEnvironmentUnset and QEnvironmentReset packets.
5081 (handle_query): Inform remote that QEnvironmentHexEncoded,
5082 QEnvironmentUnset and QEnvironmentReset are supported.
5083
5084 2017-08-25 Simon Marchi <simon.marchi@ericsson.com>
5085
5086 * inferiors.h (inferior_target_data): Rename to ...
5087 (thread_target_data): ... this.
5088 (inferior_regcache_data): Rename to ...
5089 (thread_regcache_data): ... this.
5090 (set_inferior_regcache_data): Rename to ...
5091 (set_thread_regcache_data): ... this.
5092 * inferiors.c (inferior_target_data): Rename to ...
5093 (thread_target_data): ... this.
5094 (inferior_regcache_data): Rename to ...
5095 (thread_regcache_data): ... this.
5096 (set_inferior_regcache_data): Rename to ...
5097 (set_thread_regcache_data): ... this.
5098 (free_one_thread): Update.
5099 * linux-low.h (get_thread_lwp): Update.
5100 * regcache.c (get_thread_regcache): Update.
5101 (regcache_invalidate_thread): Update.
5102 (free_register_cache_thread): Update.
5103 * win32-i386-low.c (update_debug_registers_callback): Update.
5104 (win32_get_current_dr): Update.
5105 * win32-low.c (thread_rec): Update.
5106 (delete_thread_info): Update.
5107 (continue_one_thread): Update.
5108 (suspend_one_thread): Update.
5109
5110 2017-08-24 Simon Marchi <simon.marchi@ericsson.com>
5111
5112 * inferiors.c (set_inferior_target_data): Remove.
5113 * inferiors.h (set_inferior_target_data): Remove.
5114
5115 2017-08-18 Yao Qi <yao.qi@linaro.org>
5116
5117 * Makefile.in (OBS): Add selftest.o.
5118 * configure.ac: AC_DEFINE GDB_SELF_TEST if $development.
5119 * configure, config.in: Re-generated.
5120 * server.c: Include common/sefltest.h.
5121 (captured_main): Handle option --selftest.
5122
5123 2017-08-09 Yao Qi <yao.qi@linaro.org>
5124
5125 * configure.srv (srv_i386_regobj): Remove i386-avx.o,
5126 i386-avx-avx512.o, i386-avx-mpx-avx512-pku.o, i386-mpx.o,
5127 i386-avx-mpx.o and i386-mmx.o.
5128 (srv_amd64_regobj): Remove amd64-avx.o, amd64-avx-avx512.o,
5129 amd64-avx-mpx-avx512-pku.o, amd64-mpx.o and amd64-avx-mpx.o.
5130 (srv_i386_xmlfiles): Remove i386/i386-avx.xml,
5131 i386/i386-avx-avx512.xml, i386/i386-avx-mpx-avx512-pku.xml,
5132 i386/i386-mpx.xml, i386/i386-avx-mpx.xml and i386/i386-mmx.xml.
5133 (srv_amd64_xmlfile):i386/amd64-avx.xml, i386/amd64-avx-avx512.xml,
5134 i386/amd64-avx-mpx-avx512-pku.xml, i386/amd64-mpx.xml,
5135 i386/amd64-avx-mpx.xml.
5136
5137 2017-08-09 Yao Qi <yao.qi@linaro.org>
5138
5139 * configure.srv (srv_amd64_regobj): Remove x32.o, x32-avx.o
5140 and x32-avx-avx512.o.
5141 (srv_amd64_xmlfiles): Remove i386/x32.xml, i386/x32-avx.xml
5142 i386/x32-avx-avx512.xml.
5143
5144 2017-07-26 Simon Marchi <simon.marchi@ericsson.com>
5145
5146 * tracepoint.h (enum class fast_tpoint_collect_result): New
5147 enumeration.
5148 (fast_tracepoint_collecting): Change return type to
5149 fast_tpoint_collect_result.
5150 * tracepoint.c (fast_tracepoint_collecting): Likewise.
5151 * linux-low.h: Include tracepoint.h.
5152 (struct lwp_info) <collecting_fast_tracepoint>: Change type to
5153 fast_tpoint_collect_result.
5154 * linux-low.c (handle_tracepoints): Adjust.
5155 (linux_fast_tracepoint_collecting): Change return type to
5156 fast_tpoint_collect_result.
5157 (maybe_move_out_of_jump_pad, linux_wait_for_event_filtered,
5158 linux_wait_1, stuck_in_jump_pad_callback,
5159 lwp_signal_can_be_delivered, linux_resume_one_lwp_throw,
5160 proceed_one_lwp): Adjust to type change.
5161
5162 2017-07-10 Yao Qi <yao.qi@linaro.org>
5163
5164 * linux-x86-low.c (x86_linux_read_description): Re-indent the code.
5165
5166 2017-06-29 Yao Qi <yao.qi@linaro.org>
5167
5168 * tdesc.h (struct target_desc) [IN_PROCESS_AGENT] <expedite_regs>:
5169 Remove.
5170 [IN_PROCESS_AGENT] <xmltarget>: Likewise.
5171
5172 2017-06-20 Simon Marchi <simon.marchi@ericsson.com>
5173
5174 * Makefile.in (IPA_OBJS): Sort and format one item per line.
5175
5176 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
5177
5178 * linux-low.c (linux_create_inferior): Adjust code to access the
5179 environment information via 'gdb_environ' class.
5180 * lynx-low.c (lynx_create_inferior): Likewise.
5181 * server.c (our_environ): Make it an instance of 'gdb_environ'.
5182 (get_environ): Return a pointer to 'our_environ'.
5183 (captured_main): Initialize 'our_environ'.
5184 * server.h (get_environ): Adjust prototype.
5185 * spu-low.c (spu_create_inferior): Adjust code to access the
5186 environment information via 'gdb_environ' class.
5187
5188 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
5189
5190 * linux-low.c (linux_read_memory, linux_write_memory): Remove
5191 usage of "register" keyword.
5192
5193 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
5194
5195 * configure: Re-generate.
5196
5197 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
5198
5199 * configure: Re-generate.
5200
5201 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
5202
5203 * Makefile.in (COMPILE.pre): Add "-x c++".
5204
5205 2017-06-09 Sergio Durigan Junior <sergiodj@redhat.com>
5206
5207 * fork-child.c: Conditionally include <signal.h>.
5208
5209 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
5210
5211 * server.c (handle_general_set): Handle new packet
5212 "QStartupWithShell".
5213 (handle_query): Add "QStartupWithShell" to the list of supported
5214 packets.
5215 (gdbserver_usage): Add help text explaining the
5216 new "--startup-with-shell" and "--no-startup-with-shell" CLI
5217 options.
5218 (captured_main): Recognize and act upon the presence of the new
5219 CLI options.
5220
5221 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
5222 Pedro Alves <palves@redhat.com>
5223
5224 * Makefile.in (SFILES): Add "nat/fork-inferior.o".
5225 * configure: Regenerate.
5226 * configure.srv (srv_linux_obj): Add "fork-child.o" and
5227 "fork-inferior.o".
5228 (i[34567]86-*-lynxos*): Likewise.
5229 (spu*-*-*): Likewise.
5230 * fork-child.c: New file.
5231 * linux-low.c: Include "common-inferior.h", "nat/fork-inferior.h"
5232 and "environ.h".
5233 (linux_ptrace_fun): New function.
5234 (linux_create_inferior): Adjust function prototype to reflect
5235 change on "target.h". Adjust function code to use
5236 "fork_inferior".
5237 (linux_request_interrupt): Delete "signal_pid".
5238 * lynx-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
5239 (lynx_ptrace_fun): New function.
5240 (lynx_create_inferior): Adjust function prototype to reflect
5241 change on "target.h". Adjust function code to use
5242 "fork_inferior".
5243 * nto-low.c (nto_create_inferior): Adjust function prototype and
5244 code to reflect change on "target.h". Update comments.
5245 * server.c: Include "common-inferior.h", "nat/fork-inferior.h",
5246 "common-terminal.h" and "environ.h".
5247 (terminal_fd): Moved to fork-child.c.
5248 (old_foreground_pgrp): Likewise.
5249 (restore_old_foreground_pgrp): Likewise.
5250 (last_status): Make it global.
5251 (last_ptid): Likewise.
5252 (our_environ): New variable.
5253 (startup_with_shell): Likewise.
5254 (program_name): Likewise.
5255 (program_argv): Rename to...
5256 (program_args): ...this.
5257 (wrapper_argv): New variable.
5258 (start_inferior): Delete function.
5259 (get_exec_wrapper): New function.
5260 (get_exec_file): Likewise.
5261 (get_environ): Likewise.
5262 (prefork_hook): Likewise.
5263 (post_fork_inferior): Likewise.
5264 (postfork_hook): Likewise.
5265 (postfork_child_hook): Likewise.
5266 (handle_v_run): Update code to deal with arguments coming from the
5267 remote host. Update calls from "start_inferior" to
5268 "create_inferior".
5269 (captured_main): Likewise. Initialize environment variable. Call
5270 "have_job_control".
5271 * server.h (post_fork_inferior): New prototype.
5272 (get_environ): Likewise.
5273 (last_status): Declare.
5274 (last_ptid): Likewise.
5275 (signal_pid): Likewise.
5276 * spu-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
5277 (spu_ptrace_fun): New function.
5278 (spu_create_inferior): Adjust function prototype to reflect change
5279 on "target.h". Adjust function code to use "fork_inferior".
5280 * target.c (target_terminal_init): New function.
5281 (target_terminal_inferior): Likewise.
5282 (target_terminal_ours): Likewise.
5283 * target.h: Include <vector>.
5284 (struct target_ops) <create_inferior>: Update prototype.
5285 (create_inferior): Update macro.
5286 * utils.c (gdb_flush_out_err): New function.
5287 * win32-low.c (win32_create_inferior): Adjust function prototype
5288 and code to reflect change on "target.h".
5289
5290 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
5291
5292 * inferiors.c (switch_to_thread): New function.
5293
5294 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
5295
5296 * Makefile.in (SFILE): Add "common/job-control.c".
5297 (OBS): Add "job-control.o".
5298
5299 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
5300
5301 * Makefile: Remove "@host_makefile_frag@".
5302
5303 2017-05-05 Pedro Alves <palves@redhat.com>
5304
5305 * configure: Regenerate.
5306
5307 2017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
5308
5309 * configure: Regenerate.
5310
5311 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
5312
5313 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Adjust to
5314 software_single_step change of return type to
5315 std::vector<CORE_ADDR>.
5316 * linux-low.c (install_software_single_step_breakpoints):
5317 Likewise.
5318 * linux-low.h (install_software_single_step_breakpoints):
5319 Likewise.
5320
5321 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
5322
5323 * remote-utils.c: Include "gdb_termios.h" instead of
5324 "terminal.h".
5325 * terminal.h: Delete file.
5326
5327 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
5328
5329 * server.c: Include <vector>.
5330 <program_argv, wrapper_argv>: Convert to std::vector.
5331 (start_inferior): Rewrite function to use C++.
5332 (handle_v_run): Likewise. Update code that calculates the argv
5333 based on the vRun packet; use C++.
5334 (captured_main): Likewise.
5335
5336 2017-04-06 Simon Marchi <simon.marchi@ericsson.com>
5337
5338 * server.c (handle_v_cont): Initialize thread_resume::thread
5339 with null_ptid.
5340
5341 2017-04-05 Pedro Alves <palves@redhat.com>
5342
5343 * configure: Regenerate.
5344
5345 2017-04-05 Pedro Alves <palves@redhat.com>
5346
5347 * gdbreplay.c (sync_error): Constify.
5348 * linux-x86-low.c (push_opcode): Constify.
5349
5350 2017-04-05 Pedro Alves <palves@redhat.com>
5351
5352 * win32-low.c (get_child_debug_event)
5353 <CREATE_PROCESS_DEBUG_EVENT>: Don't report TARGET_WAITKIND_EXECD.
5354 Report TARGET_WAITKIND_SPURIOUS instead.
5355
5356 2017-04-05 Pedro Alves <palves@redhat.com>
5357
5358 * remote-utils.c (remote_prepare, remote_open): Constify.
5359 * remote-utils.h (remote_prepare, remote_open): Constify.
5360 * server.c (captured_main): Constify 'port' handling.
5361
5362 2017-04-04 Simon Marchi <simon.marchi@ericsson.com>
5363
5364 * Makefile.in (clean): Clear .deps.
5365
5366 2017-03-31 Simon Marchi <simon.marchi@polymtl.ca>
5367
5368 * .gitignore: Remove generated files, replace with wildcard.
5369 * (clean): Replace removal of generated files with wildcard.
5370 (version.c): Replace with...
5371 (version-generated.c): ...this.
5372 (xml-builtin.c): Replace with...
5373 (xml-builtin-generated.c): ...this.
5374 (%-ipa.o: %-generated.c, %.o: %-generated.c): New rules.
5375 (%.c: *regformats*): Replace with...
5376 (%-generated.c: *regformats*): ...this.
5377
5378 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
5379
5380 * linux-xtensa-low.c (regnum::R_THREADPTR): New enum member.
5381 (xtensa_fill_gregset): Call collect_register_by_name for
5382 threadptr register.
5383 (xtensa_store_gregset): Call supply_register_by_name for
5384 threadptr register.
5385
5386 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
5387
5388 * linux-xtensa-low.c (xtensa_fill_gregset): Call collect_register
5389 for all registers in a0_regnum..a0_regnum + C0_NREGS range.
5390 (xtensa_store_gregset): Call supply_register for all registers in
5391 a0_regnum..a0_regnum + C0_NREGS range.
5392
5393 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
5394
5395 * Makefile.in (%-ipa.o: %-ipa.c): New rule.
5396 (ax-ipa.o: ax.c): Remove.
5397 (linux-i386-ipa.o: linux-i386-ipa.c): Remove.
5398 (linux-amd64-ipa.o: linux-amd64-ipa.c): Remove.
5399 (linux-aarch64-ipa.o: linux-aarch64-ipa.c): Remove.
5400 (linux-s390-ipa.o: linux-s390-ipa.c): Remove.
5401 (linux-ppc-ipa.o: linux-ppc-ipa.c): Remove.
5402
5403 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
5404
5405 * Makefile.in (%-ipa.o: ../common/%.c): New rule.
5406 (print-utils-ipa.o: ../common/print-utils.c): Remove.
5407 (rsp-low-ipa.o: ../common/rsp-low.c): Remove.
5408 (errors-ipa.o: ../common/errors.c): Remove.
5409 (format-ipa.o: ../common/format.c): Remove.
5410 (common-utils-ipa.o: ../common/common-utils.c): Remove.
5411
5412 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
5413
5414 * Makefile.in (%-ipa.o: %.c): New rule.
5415 (tracepoint-ipa.o: tracepoint.c): Remove.
5416 (utils-ipa.o: utils.c): Remove.
5417 (remote-utils-ipa.o: remote-utils.c): Remove.
5418 (regcache-ipa.o: regcache.c): Remove.
5419 (i386-linux-ipa.o: i386-linux.c): Remove.
5420 (i386-mmx-linux-ipa.o: i386-mmx-linux.c): Remove.
5421 (i386-avx-linux-ipa.o: i386-avx-linux.c): Remove.
5422 (i386-mpx-linux-ipa.o: i386-mpx-linux.c): Remove.
5423 (i386-avx-mpx-linux-ipa.o: i386-avx-mpx-linux.c): Remove.
5424 (i386-avx-avx512-linux-ipa.o: i386-avx-avx512-linux.c): Remove.
5425 (i386-avx-mpx-avx512-pku-linux-ipa.o: i386-avx-mpx-avx512-pku-linux.c): Remove.
5426 (amd64-linux-ipa.o: amd64-linux.c): Remove.
5427 (amd64-avx-linux-ipa.o: amd64-avx-linux.c): Remove.
5428 (amd64-mpx-linux-ipa.o: amd64-mpx-linux.c): Remove.
5429 (amd64-avx-mpx-linux-ipa.o: amd64-avx-mpx-linux.c): Remove.
5430 (amd64-avx-avx512-linux-ipa.o: amd64-avx-avx512-linux.c): Remove.
5431 (amd64-avx-mpx-avx512-pku-linux-ipa.o: amd64-avx-mpx-avx512-pku-linux.c): Remove.
5432 (aarch64-ipa.o: aarch64.c): Remove.
5433 (s390-linux32-ipa.o: s390-linux32.c): Remove.
5434 (s390-linux32v1-ipa.o: s390-linux32v1.c): Remove.
5435 (s390-linux32v2-ipa.o: s390-linux32v2.c): Remove.
5436 (s390-linux64-ipa.o: s390-linux64.c): Remove.
5437 (s390-linux64v1-ipa.o: s390-linux64v1.c): Remove.
5438 (s390-linux64v2-ipa.o: s390-linux64v2.c): Remove.
5439 (s390-te-linux64-ipa.o: s390-te-linux64.c): Remove.
5440 (s390-vx-linux64-ipa.o: s390-vx-linux64.c): Remove.
5441 (s390-tevx-linux64-ipa.o: s390-tevx-linux64.c): Remove.
5442 (s390x-linux64-ipa.o: s390x-linux64.c): Remove.
5443 (s390x-linux64v1-ipa.o: s390x-linux64v1.c): Remove.
5444 (s390x-linux64v2-ipa.o: s390x-linux64v2.c): Remove.
5445 (s390x-te-linux64-ipa.o: s390x-te-linux64.c): Remove.
5446 (s390x-vx-linux64-ipa.o: s390x-vx-linux64.c): Remove.
5447 (s390x-tevx-linux64-ipa.o: s390x-tevx-linux64.c): Remove.
5448 (powerpc-32l-ipa.o: powerpc-32l.c): Remove.
5449 (powerpc-altivec32l-ipa.o: powerpc-altivec32l.c): Remove.
5450 (powerpc-cell32l-ipa.o: powerpc-cell32l.c): Remove.
5451 (powerpc-vsx32l-ipa.o: powerpc-vsx32l.c): Remove.
5452 (powerpc-isa205-32l-ipa.o: powerpc-isa205-32l.c): Remove.
5453 (powerpc-isa205-altivec32l-ipa.o: powerpc-isa205-altivec32l.c): Remove.
5454 (powerpc-isa205-vsx32l-ipa.o: powerpc-isa205-vsx32l.c): Remove.
5455 (powerpc-e500l-ipa.o: powerpc-e500l.c): Remove.
5456 (powerpc-64l-ipa.o: powerpc-64l.c): Remove.
5457 (powerpc-altivec64l-ipa.o: powerpc-altivec64l.c): Remove.
5458 (powerpc-cell64l-ipa.o: powerpc-cell64l.c): Remove.
5459 (powerpc-vsx64l-ipa.o: powerpc-vsx64l.c): Remove.
5460 (powerpc-isa205-64l-ipa.o: powerpc-isa205-64l.c): Remove.
5461 (powerpc-isa205-altivec64l-ipa.o: powerpc-isa205-altivec64l.c): Remove.
5462 (powerpc-isa205-vsx64l-ipa.o: powerpc-isa205-vsx64l.c): Remove.
5463 (tdesc-ipa.o: tdesc.c): Remove.
5464 (x32-linux-ipa.o: x32-linux.c): Remove.
5465 (x32-avx-linux-ipa.o: x32-avx-linux.c): Remove.
5466 (x32-avx512-linux-ipa.o: x32-avx512-linux.c): Remove.
5467
5468 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
5469
5470 * Makefile.in (%.o: ../arch/%.c): New rule.
5471 (arm.o: ../arch/arm.c): Remove.
5472 (arm-linux.o: ../arch/arm-linux.c): Remove.
5473 (arm-get-next-pcs.o: ../arch/arm-get-next-pcs.c): Remove.
5474 (aarch64-insn.o: ../arch/aarch64-insn.c): Remove.
5475
5476 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
5477
5478 * Makefile.in (%.o: ../nat/%.c): New rule.
5479 (x86-dregs.o: ../nat/x86-dregs.c): Remove.
5480 (amd64-linux-siginfo.o: ../nat/amd64-linux-siginfo.c): Remove.
5481 (linux-btrace.o: ../nat/linux-btrace.c): Remove.
5482 (linux-osdata.o: ../nat/linux-osdata.c): Remove.
5483 (linux-procfs.o: ../nat/linux-procfs.c): Remove.
5484 (linux-ptrace.o: ../nat/linux-ptrace.c): Remove.
5485 (linux-waitpid.o: ../nat/linux-waitpid.c): Remove.
5486 (mips-linux-watch.o: ../nat/mips-linux-watch.c): Remove.
5487 (ppc-linux.o: ../nat/ppc-linux.c): Remove.
5488 (linux-personality.o: ../nat/linux-personality.c): Remove.
5489 (aarch64-linux-hw-point.o: ../nat/aarch64-linux-hw-point.c): Remove.
5490 (aarch64-linux.o: ../nat/aarch64-linux.c): Remove.
5491 (x86-linux.o: ../nat/x86-linux.c): Remove.
5492 (x86-linux-dregs.o: ../nat/x86-linux-dregs.c): Remove.
5493 (linux-namespaces.o: ../nat/linux-namespaces.c): Remove.
5494
5495 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
5496
5497 * Makefile.in (%.o: ../common/%.c): New rule.
5498 (signals.o: ../common/signals.c): Remove.
5499 (print-utils.o: ../common/print-utils.c): Remove.
5500 (rsp-low.o: ../common/rsp-low.c): Remove.
5501 (common-utils.o: ../common/common-utils.c): Remove.
5502 (posix-strerror.o: ../common/posix-strerror.c): Remove.
5503 (mingw-strerror.o: ../common/mingw-strerror.c): Remove.
5504 (vec.o: ../common/vec.c): Remove.
5505 (gdb_vecs.o: ../common/gdb_vecs.c): Remove.
5506 (xml-utils.o: ../common/xml-utils.c): Remove.
5507 (ptid.o: ../common/ptid.c): Remove.
5508 (buffer.o: ../common/buffer.c): Remove.
5509 (format.o: ../common/format.c): Remove.
5510 (filestuff.o: ../common/filestuff.c): Remove.
5511 (agent.o: ../common/agent.c): Remove.
5512 (errors.o: ../common/errors.c): Remove.
5513 (environ.o: ../common/environ.c): Remove.
5514 (common-debug.o: ../common/common-debug.c): Remove.
5515 (cleanups.o: ../common/cleanups.c): Remove.
5516 (common-exceptions.o: ../common/common-exceptions.c): Remove.
5517 (fileio.o: ../common/fileio.c): Remove.
5518 (common-regcache.o: ../common/common-regcache.c): Remove.
5519 (signals-state-save-restore.o: ../common/signals-state-save-restore.c): Remove.
5520 (new-op.o: ../common/new-op.c): Remove.
5521 (btrace-common.o: ../common/btrace-common.c): Remove.
5522
5523 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
5524
5525 * Makefile.in (%.o: ../target/%.c): New rule.
5526 (waitstatus.o: ../target/waitstatus.c): Remove.
5527
5528 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
5529
5530 * Makefile.in
5531 (%.c: ../regformats/%.dat,
5532 (%.c: ../regformats/arm/%.dat,
5533 (%.c: ../regformats/i386/%.dat,
5534 (%.c: ../regformats/rs6000/%.dat): New rules.
5535 (aarch64.c): Remove.
5536 (reg-arm.c): Remove.
5537 (arm-with-iwmmxt.c): Remove.
5538 (arm-with-vfpv2.c): Remove.
5539 (arm-with-vfpv3.c): Remove.
5540 (arm-with-neon.c): Remove.
5541 (reg-bfin.c): Remove.
5542 (reg-cris.c): Remove.
5543 (reg-crisv32.c): Remove.
5544 (i386.c): Remove.
5545 (i386-linux.c): Remove.
5546 (i386-avx.c): Remove.
5547 (i386-avx-linux.c): Remove.
5548 (i386-avx-avx512.c): Remove.
5549 (i386-avx-avx512-linux.c): Remove.
5550 (i386-mpx.c): Remove.
5551 (i386-mpx-linux.c): Remove.
5552 (i386-avx-mpx-avx512-pku.c): Remove.
5553 (i386-avx-mpx-avx512-pku-linux.c): Remove.
5554 (i386-avx-mpx.c): Remove.
5555 (i386-avx-mpx-linux.c): Remove.
5556 (i386-mmx.c): Remove.
5557 (i386-mmx-linux.c): Remove.
5558 (reg-ia64.c): Remove.
5559 (reg-m32r.c): Remove.
5560 (reg-m68k.c): Remove.
5561 (reg-cf.c): Remove.
5562 (mips-linux.c): Remove.
5563 (mips-dsp-linux.c): Remove.
5564 (mips64-linux.c): Remove.
5565 (mips64-dsp-linux.c): Remove.
5566 (nios2-linux.c): Remove.
5567 (powerpc-32.c): Remove.
5568 (powerpc-32l.c): Remove.
5569 (powerpc-altivec32l.c): Remove.
5570 (powerpc-cell32l.c): Remove.
5571 (powerpc-vsx32l.c): Remove.
5572 (powerpc-isa205-32l.c): Remove.
5573 (powerpc-isa205-altivec32l.c): Remove.
5574 (powerpc-isa205-vsx32l.c): Remove.
5575 (powerpc-e500l.c): Remove.
5576 (powerpc-64l.c): Remove.
5577 (powerpc-altivec64l.c): Remove.
5578 (powerpc-cell64l.c): Remove.
5579 (powerpc-vsx64l.c): Remove.
5580 (powerpc-isa205-64l.c): Remove.
5581 (powerpc-isa205-altivec64l.c): Remove.
5582 (powerpc-isa205-vsx64l.c): Remove.
5583 (s390-linux32.c): Remove.
5584 (s390-linux32v1.c): Remove.
5585 (s390-linux32v2.c): Remove.
5586 (s390-linux64.c): Remove.
5587 (s390-linux64v1.c): Remove.
5588 (s390-linux64v2.c): Remove.
5589 (s390-te-linux64.c): Remove.
5590 (s390-vx-linux64.c): Remove.
5591 (s390-tevx-linux64.c): Remove.
5592 (s390x-linux64.c): Remove.
5593 (s390x-linux64v1.c): Remove.
5594 (s390x-linux64v2.c): Remove.
5595 (s390x-te-linux64.c): Remove.
5596 (s390x-vx-linux64.c): Remove.
5597 (s390x-tevx-linux64.c): Remove.
5598 (tic6x-c64xp-linux.c): Remove.
5599 (tic6x-c64x-linux.c): Remove.
5600 (tic6x-c62x-linux.c): Remove.
5601 (reg-sh.c): Remove.
5602 (reg-sparc64.c): Remove.
5603 (reg-spu.c): Remove.
5604 (amd64.c): Remove.
5605 (amd64-linux.c): Remove.
5606 (amd64-avx.c): Remove.
5607 (amd64-avx-linux.c): Remove.
5608 (amd64-avx-avx512.c): Remove.
5609 (amd64-avx-avx512-linux.c): Remove.
5610 (amd64-mpx.c): Remove.
5611 (amd64-mpx-linux.c): Remove.
5612 (amd64-avx-mpx-avx512-pku.c): Remove.
5613 (amd64-avx-mpx-avx512-pku-linux.c): Remove.
5614 (amd64-avx-mpx.c): Remove.
5615 (amd64-avx-mpx-linux.c): Remove.
5616 (x32.c): Remove.
5617 (x32-linux.c): Remove.
5618 (x32-avx.c): Remove.
5619 (x32-avx-linux.c): Remove.
5620 (x32-avx-avx512.c): Remove.
5621 (x32-avx-avx512-linux.c): Remove.
5622 (reg-xtensa.c): Remove.
5623 (reg-tilegx.c): Remove.
5624 (reg-tilegx32.c): Remove.
5625
5626 2017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
5627
5628 * Makefile.in (SFILES): Add "common/environ.c".
5629 (OBJS): Add "common/environ.h".
5630
5631 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
5632
5633 * configure.ac: Check if the fs_base and gs_base members of
5634 `struct user_regs_struct' exist.
5635 * config.in: Regenerated.
5636 * configure: Likewise.
5637
5638 2017-01-09 Antoine Tremblay <antoine.tremblay@ericsson.com>
5639
5640 * linux-aarch32-low.c (arm_breakpoint_kind_from_pc): Use
5641 target_read_memory.
5642 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer): Likewise.
5643 (get_next_pcs_syscall_next_pc): Likewise.
5644
5645 2016-12-23 Luis Machado <lgustavo@codesourcery.com>
5646
5647 * win32-i386-low.c: Fix incorrect reference to a couple source files.
5648 * nto-x86-low.c: Likewise.
5649
5650 2016-11-30 Simon Marchi <simon.marchi@polymtl.ca>
5651
5652 * Makefile.in: Include disable-implicit-rules.mk.
5653
5654 2016-11-23 Pedro Alves <palves@redhat.com>
5655
5656 * debug.c: Include <chrono> instead of "gdb_sys_time.h".
5657 (debug_vprintf): Use std::chrono::steady_clock instead of
5658 gettimeofday. Use '.' instead of ':'.
5659 * tracepoint.c: Include <chrono> instead of "gdb_sys_time.h".
5660 (get_timestamp): Use std::chrono::steady_clock instead of
5661 gettimeofday.
5662
5663 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
5664
5665 * Makefile.in: Fix whitespace formatting.
5666
5667 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
5668
5669 * Makefile.in (SFILES, OBS): Flatten list and order
5670 alphabetically.
5671
5672 2016-11-23 Pedro Alves <palves@redhat.com>
5673
5674 * event-loop.c (handle_file_event): Use warning.
5675 * linux-low.c (linux_resume_one_lwp_throw): Use warning.
5676 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
5677 Use warning.
5678
5679 2016-11-23 Pedro Alves <palves@redhat.com>
5680
5681 * linux-low.c (check_zombie_leaders): Use debug_printf for debug
5682 output.
5683 * notif.c (handle_notif_ack, notif_event_enque): Likewise.
5684 * remote-utils.c (putpkt_binary_1, readchar, getpkt): Use
5685 debug_printf and debug_flush for debug output.
5686 * server.c (handle_general_set): Likewise.
5687 * thread-db.c (try_thread_db_load): Use debug_printf for debug
5688 output.
5689
5690 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
5691
5692 * Makefile.in (.c.o): Replace rule with ...
5693 (%.o: %.c): ... this one.
5694
5695 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
5696
5697 * Makefile.in: Remove @GMAKE_TRUE@ prefixes and removes lines
5698 prefixed with @GMAKE_FALSE@. Update comment related to non-GNU
5699 make.
5700 * configure.ac: Remove checks for the make program.
5701 * configure: Re-generate.
5702
5703 2016-10-28 Pedro Alves <palves@redhat.com>
5704
5705 * Makefile.in (CXX_DIALECT): Get from configure.
5706 (COMPILE.pre, CC_LD): Append $(CXX_DIALECT).
5707 * acinclude.m4: Include ../ax_cxx_compile_stdcxx.m4.
5708 * configure.ac: Call AX_CXX_COMPILE_STDCXX.
5709 * config.in: Regenerate.
5710 * configure: Regenerate.
5711
5712 2016-10-27 Yao Qi <yao.qi@linaro.org>
5713
5714 * linux-low.c (linux_supports_range_stepping): Return true if
5715 can_software_single_step return true.
5716
5717 2016-10-27 Yao Qi <yao.qi@linaro.org>
5718
5719 * inferiors.c (find_inferior_in_random): New function.
5720 * inferiors.h (find_inferior_in_random): Declare.
5721 * linux-low.c (linux_wait_for_event_filtered): Call
5722 find_inferior_in_random instead of find_inferior.
5723
5724 2016-10-27 Yao Qi <yao.qi@linaro.org>
5725
5726 * linux-low.c (linux_wait_1): If single-step breakpoints are
5727 inserted, remove them.
5728
5729 2016-10-26 Pedro Alves <palves@redhat.com>
5730
5731 * linux-low.c (handle_extended_wait): Link parent/child fork
5732 threads.
5733 (linux_wait_1): Unlink them.
5734 (linux_set_resume_request): Ignore resume requests for
5735 already-resumed and unhandled fork child threads.
5736 * linux-low.h (struct lwp_info) <fork_relative>: New field.
5737 * server.c (in_queued_stop_replies_ptid, in_queued_stop_replies):
5738 New functions.
5739 (handle_v_requests) <vCont>: Don't call require_running.
5740 * server.h (in_queued_stop_replies): New declaration.
5741
5742 2016-10-24 Yao Qi <yao.qi@linaro.org>
5743
5744 PR server/20733
5745 * linux-aarch64-low.c (append_insns): Cast the return value to
5746 'uint32_t *'.
5747
5748 2016-10-10 Yao Qi <yao.qi@linaro.org>
5749
5750 * linux-aarch32-low.c (enum arm_breakpoint_kinds): Remove.
5751
5752 2016-10-06 Sergio Durigan Junior <sergiodj@redhat.com>
5753
5754 * target.c (target_supports_multi_process): New function, moved
5755 from...
5756 * target.h (target_supports_multi_process): ... here. Remove
5757 macro.
5758
5759 2016-10-05 Tom Tromey <tom@tromey.com>
5760
5761 PR remote/20655:
5762 * tracepoint.c (handle_tracepoint_bkpts): Check
5763 ipa_error_tracepoint, not ipa_stopping_tracepoint.
5764
5765 2016-10-05 Yao Qi <yao.qi@linaro.org>
5766
5767 * configure.srv: Update the path of arm-*.xml files.
5768
5769 2016-10-05 Terry Guo <terry.guo@arm.com>
5770 Yao Qi <yao.qi@linaro.org>
5771
5772 * Makefile.in: Adjust the path of rules.
5773 * configure.srv: Update the path of xml files.
5774 * regformats/arm-with-iwmmxt.dat: Regenerated.
5775 * regformats/arm-with-neon.dat: Likewise.
5776 * regformats/arm-with-vfpv2.dat: Likewise.
5777 * regformats/arm-with-vfpv3.dat Likewise.
5778
5779 2016-09-30 Yao Qi <yao.qi@linaro.org>
5780
5781 PR gdbserver/20627
5782 * target.c (target_stop_and_wait): Don't call
5783 target_continue_no_signal, use resume_stop instead.
5784
5785 2016-09-26 Yao Qi <yao.qi@linaro.org>
5786
5787 * linux-low.c (linux_wait_1): Call debug_exit.
5788
5789 2016-09-23 Pedro Alves <palves@redhat.com>
5790
5791 * Makefile.in (SFILES): Add common/new-op.c.
5792 (OBS): Add common/new-op.o.
5793 (new-op.o): New rule.
5794
5795 2016-09-21 Simon Marchi <simon.marchi@ericsson.com>
5796
5797 * .gitinore: Ignore more files.
5798
5799 2016-09-21 Yao Qi <yao.qi@linaro.org>
5800
5801 * linux-aarch32-low.c (arm_fill_gregset): Keep bits 20 to
5802 23.
5803
5804 2016-09-19 Sergio Durigan Junior <sergiodj@redhat.com>
5805
5806 * server.c (start_inferior): Call target_mourn_inferior instead of
5807 mourn_inferior; pass ptid_t argument to it.
5808 (resume): Likewise.
5809 (handle_target_event): Likewise.
5810 * target.c (target_mourn_inferior): New function.
5811 * target.h (mourn_inferior): Delete macro.
5812
5813 2016-09-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
5814
5815 * linux-low.c (lwp_is_stepping): New function.
5816
5817 2016-09-06 Carl Love <cel@us.ibm.com>
5818
5819 * server.c (start_inferior): Fixed comment, requested comment change
5820 didn't get updated correctly. Removed reference to ptrace () call as
5821 it is only true on Linux systems.
5822
5823 2016-09-06 Carl Love <cel@us.ibm.com>
5824
5825 * server.c (start_inferior): Do not call
5826 function target_post_create_inferior () if the
5827 inferior process has already exited.
5828
5829 2016-09-05 Pedro Alves <palves@redhat.com>
5830
5831 * Makefile.in (COMPILER, COMPILER_CFLAGS): Remove.
5832 (COMPILE.pre, CC_LD): Use CXX directly.
5833 (INTERNAL_CFLAGS_BASE): Use CXXFLAGS directly.
5834 * acinclude.m4: Don't include build-with-cxx.m4.
5835 * configure.ac: Remove GDB_AC_BUILD_WITH_CXX call.
5836 * configure: Regenerate.
5837
5838 2016-09-02 Akash Trehan <akash.trehan123@gmail.com>
5839
5840 PR gdb/19495
5841 * remote-utils.c (relocate_instruction): Remove redundant strcpy()
5842 call writing data to own_buf.
5843
5844 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
5845
5846 * target.c (mywait): Call target_wait instead of
5847 the_target->wait.
5848 (target_wait): New function.
5849
5850 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
5851
5852 * server.c (start_inferior): New variable 'ptid'. Replace calls
5853 to the_target->resume by target_continue{,_no_signal}, depending
5854 on the case.
5855 * target.c (target_stop_and_wait): Call target_continue_no_signal
5856 instead of the_target->resume.
5857 (target_continue): New function.
5858
5859 2016-08-31 Antoine Tremblay <antoine.tremblay@ericsson.com>
5860
5861 * linux-low.c (linux_wait_1): Move event switch after unsuspend_lwps.
5862
5863 2016-08-25 Adhemerval Zanella <adhemerval.zanella@linaro.org>
5864
5865 PR server/20491
5866 * gdb_proc_service.h (ps_get_thread_area): Remove const from struct
5867 ps_prochandle.
5868 * linux-aarch64-low.c (ps_get_thread_area): Likewise.
5869 * linux-arm-low.c (ps_get_thread_area): Likewise.
5870 * linux-crisv32-low.c (ps_get_thread_area): Likewise.
5871 * linux-m68k-low.c (ps_get_thread_area): Likewise.
5872 * linux-mips-low.c (ps_get_thread_area): Likewise.
5873 * linux-nios2-low.c (ps_get_thread_area): Likewise.
5874 * linux-tic6x-low.c (ps_get_thread_area): Likewise.
5875 * linux-x86-low.c (ps_get_thread_area): Likewise.
5876 * linux-xtensa-low.c (ps_get_thread_area): Likewise.
5877
5878 2016-08-19 Pedro Alves <palves@redhat.com>
5879
5880 * linux-x86-low.c (amd64_emit_call): Emit missing call opcode.
5881
5882 2016-08-19 Pedro Alves <palves@redhat.com>
5883
5884 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Fix
5885 comment. Use memcpy instead of casting through unsigned long.
5886
5887 2016-08-19 Pedro Alves <palves@redhat.com>
5888
5889 * linux-amd64-ipa.c (alloc_jump_pad_buffer) [__ILP32__]: Try
5890 allocating around 0x80000000.
5891
5892 2016-08-19 Pedro Alves <palves@redhat.com>
5893
5894 PR gdb/20415
5895 * Makefile.in (x32-linux-ipa.o, x32-avx-linux-ipa.o)
5896 (x32-avx512-linux-ipa.o): New rules.
5897 * configure.ac (x86_64-*-linux*): New x32 check.
5898 * configure.srv (ipa_x32_linux_regobj): New.
5899 (x86_64-*-linux*): Use $ipa_x32_linux_regobj if building for x32.
5900 * linux-amd64-ipa.c (get_ipa_tdesc) [__ILP32__]: Return x32
5901 descriptions.
5902 (initialize_low_tracepoint) [__ILP32__]: Initialize x32
5903 descriptions.
5904 * configure: Regenerate.
5905
5906 2016-08-09 Pedro Alves <palves@redhat.com>
5907
5908 PR gdb/18653
5909 * Makefile.in (OBS): Add signals-state-save-restore.o.
5910 (signals-state-save-restore.o): New rule.
5911 * config.in: Regenerate.
5912 * configure: Regenerate.
5913 * linux-low.c: Include "signals-state-save-restore.h".
5914 (linux_create_inferior): Call
5915 restore_original_signals_state.
5916 * server.c: Include "dispositions-save-restore.h".
5917 (captured_main): Call save_original_signals_state.
5918
5919 2016-08-05 Pedro Alves <palves@redhat.com>
5920
5921 * configure: Regenerate.
5922
5923 2016-08-04 Yao Qi <yao.qi@linaro.org>
5924
5925 * linux-low.c (regsets_fetch_inferior_registers): Check
5926 errno is ESRCH or not.
5927
5928 2016-08-02 Yao Qi <yao.qi@linaro.org>
5929
5930 * thread-db.c (struct thread_db) <td_ta_event_getmsg_p>: Remove.
5931 <td_ta_set_event_p, td_ta_event_addr_p>: Remove.
5932 (thread_db_load_search): Update.
5933 (try_thread_db_load_1): Don't look for td_ta_event_addr,
5934 td_ta_set_event and td_ta_event_getmsg.
5935
5936 2016-07-26 Pedro Alves <palves@redhat.com>
5937
5938 PR server/20414
5939 * linux-x86-low.c (x86_get_pc, x86_set_pc): Use uint64_t instead
5940 of unsigned long for 64-bit registers and use uint32_t instead of
5941 unsigned int for 32-bit registers.
5942
5943 2016-07-26 Pedro Alves <palves@redhat.com>
5944
5945 * linux-x86-low.c (x86_siginfo_fixup): Rename 'native' parameter
5946 to 'ptrace'.
5947
5948 2016-07-21 Tom Tromey <tom@tromey.com>
5949
5950 * configure: Rebuild.
5951
5952 2016-07-21 Yao Qi <yao.qi@linaro.org>
5953
5954 * mem-break.c (find_gdb_breakpoint): Cast bp to
5955 'struct gdb_breakpoint *' rather than 'gdb_breakpoint *'.
5956
5957 2016-07-21 Yao Qi <yao.qi@linaro.org>
5958
5959 * server.c (handle_v_requests): Support s and S actions
5960 if target_supports_software_single_step return true.
5961
5962 2016-07-21 Yao Qi <yao.qi@linaro.org>
5963
5964 * linux-low.c (resume_stopped_resumed_lwps): If resume request
5965 is resume_step, call maybe_hw_step.
5966 (linux_wait_1): Stop all threads, remove reinsert breakpoints,
5967 and unstop them.
5968 (linux_resume_one_lwp_throw): Don't assert the thread has reinsert
5969 breakpoints or not.
5970 (proceed_one_lwp): If resume request is resume_step, install
5971 reinsert breakpoints and call maybe_hw_step.
5972
5973 2016-07-21 Yao Qi <yao.qi@linaro.org>
5974
5975 * linux-low.c (proceed_one_lwp): Declare.
5976 (linux_resume_one_thread): Remove local variable 'step'.
5977 Lift code enqueue signal. Call proceed_one_lwp instead of
5978 linux_resume_one_lwp.
5979
5980 2016-07-21 Yao Qi <yao.qi@linaro.org>
5981
5982 * linux-low.c (linux_resume_one_thread): Call
5983 enqueue_pending_signal.
5984
5985 2016-07-21 Yao Qi <yao.qi@linaro.org>
5986
5987 * gdbthread.h (make_cleanup_restore_current_thread): Declare.
5988 * inferiors.c (do_restore_current_thread_cleanup): New function.
5989 (make_cleanup_restore_current_thread): Likewise.
5990 * linux-low.c (install_software_single_step_breakpoints): Call
5991 make_cleanup_restore_current_thread. Switch current_thread to
5992 thread.
5993
5994 2016-07-21 Yao Qi <yao.qi@linaro.org>
5995
5996 * mem-break.c (struct reinsert_breakpoint) <ptid>: New field.
5997 (set_reinsert_breakpoint): New parameter ptid. Callers updated.
5998 (clone_one_breakpoint): Likewise.
5999 (delete_reinsert_breakpoints): Change parameter to thread.
6000 Callers updated.
6001 (has_reinsert_breakpoints): Likewise.
6002 (uninsert_reinsert_breakpoints): Likewise.
6003 (reinsert_reinsert_breakpoints): Likewise.
6004 * mem-break.h (set_reinsert_breakpoint): Update declaration.
6005 (delete_reinsert_breakpoints): Likewise.
6006 (reinsert_reinsert_breakpoints): Likewise.
6007 (uninsert_reinsert_breakpoints): Likewise.
6008 (has_reinsert_breakpoints): Likewise.
6009
6010 2016-07-21 Yao Qi <yao.qi@linaro.org>
6011
6012 * inferiors.c (get_thread_process): Make parameter const.
6013 * inferiors.h (get_thread_process): Update declaration.
6014 * mem-break.c (clone_all_breakpoints): Remove all parameters.
6015 Add new parameters child_thread and parent_thread. Callers
6016 updated.
6017 * mem-break.h (clone_all_breakpoints): Update declaration.
6018
6019 2016-07-21 Yao Qi <yao.qi@linaro.org>
6020
6021 * mem-break.c (struct breakpoint) <cond_list>: Remove.
6022 <command_list, handler>: Remove.
6023 (struct gdb_breakpoint): New.
6024 (struct other_breakpoint): New.
6025 (struct reinsert_breakpoint): New.
6026 (is_gdb_breakpoint): New function.
6027 (any_persistent_commands): Update command_list if
6028 is_gdb_breakpoint returns true.
6029 (set_breakpoint): Create breakpoints according to their types.
6030 (find_gdb_breakpoint): Return 'struct gdb_breakpoint *'.
6031 (set_gdb_breakpoint_1): Likewise.
6032 (set_gdb_breakpoint): Likewise.
6033 (clear_breakpoint_conditions): Change parameter type to
6034 'struct gdb_breakpoint *'.
6035 (clear_breakpoint_commands): Likewise.
6036 (clear_breakpoint_conditions_and_commands): Likewise.
6037 (add_condition_to_breakpoint): Likewise.
6038 (add_breakpoint_condition): Likewise.
6039 (add_commands_to_breakpoint): Likewise.
6040 (check_breakpoints): Check other_breakpoint.
6041 (clone_one_breakpoint): Clone breakpopint according to its type.
6042 * mem-break.h (struct gdb_breakpoint): Declare.
6043 (set_gdb_breakpoint): Update declaration.
6044 (clear_breakpoint_conditions_and_commands): Likewise.
6045 (add_breakpoint_condition): Likewise.
6046 (add_breakpoint_commands): Likewise.
6047 * server.c (process_point_options): Change parameter type to
6048 'struct gdb_breakpoint *'.
6049
6050 2016-07-21 Yao Qi <yao.qi@linaro.org>
6051
6052 * mem-break.c (set_breakpoint_at): Rename it to ...
6053 (set_breakpoint_type_at): ... it.
6054 (set_breakpoint_at): Call set_breakpoint_type_at.
6055 (set_reinsert_breakpoint): Call set_breakpoint_type_at.
6056 * mem-break.h (set_breakpoint_at): Update comments.
6057
6058 2016-07-12 Chung-Lin Tang <cltang@codesourcery.com>
6059
6060 * linux-nios2-low.c (nios2_fill_gregset): Add type cast
6061 to buf parameter.
6062 (nios2_store_gregset): Likewise.
6063
6064 2016-07-01 Pedro Alves <palves@redhat.com>
6065 Antoine Tremblay <antoine.tremblay@ericsson.com>
6066
6067 * linux-low.c: Change interface to take the target lwp_info
6068 pointer directly and return void. Handle detaching from a zombie
6069 thread.
6070 (linux_detach_lwp_callback): New function.
6071 (linux_detach): Detach from the leader thread after detaching from
6072 the clone threads.
6073
6074 2016-06-28 Yao Qi <yao.qi@linaro.org>
6075
6076 * linux-aarch64-low.c (aarch64_ftrace_insn_reloc_b): Use int64_t
6077 for variable new_offset.
6078 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
6079 (aarch64_ftrace_insn_reloc_cb): Likewise.
6080 (aarch64_ftrace_insn_reloc_tb): Likewise.
6081 (aarch64_install_fast_tracepoint_jump_pad): Likewise. Use
6082 PRIx64 instead of PRIx32.
6083
6084 2016-06-28 Yao Qi <yao.qi@linaro.org>
6085
6086 * linux-arm-low.c (arm_get_syscall_trapinfo): New function.
6087 (the_low_target): Install arm_get_syscall_trapinfo.
6088
6089 2016-06-28 Yao Qi <yao.qi@linaro.org>
6090
6091 * linux-aarch64-low.c (aarch64_get_syscall_trapinfo): New
6092 function.
6093 (the_low_target): Install aarch64_get_syscall_trapinfo.
6094
6095 2016-06-28 Yao Qi <yao.qi@linaro.org>
6096
6097 * linux-low.c (get_syscall_trapinfo): Remove parameter sysret.
6098 Callers updated.
6099 * linux-low.h (struct linux_target_ops) <get_syscall_trapinfo>:
6100 Remove parameter sysno.
6101 * linux-x86-low.c (x86_get_syscall_trapinfo): Remove parameter
6102 sysret.
6103
6104 2016-06-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
6105
6106 * linux-s390-low.c (s390_emit_eq_goto): Mark function static.
6107 (s390_emit_ne_goto): Likewise.
6108 (s390_emit_lt_goto): Likewise.
6109 (s390_emit_le_goto): Likewise.
6110 (s390_emit_gt_goto): Likewise.
6111 (s390_emit_ge_goto): Likewise.
6112 (s390x_emit_eq_goto): Likewise.
6113 (s390x_emit_ne_goto): Likewise.
6114 (s390x_emit_lt_goto): Likewise.
6115 (s390x_emit_le_goto): Likewise.
6116 (s390x_emit_gt_goto): Likewise.
6117 (s390x_emit_ge_goto): Likewise.
6118 (s390_emit_ops_impl): Mark variable static.
6119 (s390x_emit_ops): Likewise.
6120
6121 2016-06-17 Yao Qi <yao.qi@linaro.org>
6122
6123 * linux-low.c (handle_extended_wait): Call
6124 uninsert_reinsert_breakpoints for the parent process. Remove
6125 reinsert breakpoints from the child process. Reinsert them to
6126 the parent process when vfork is done.
6127 * mem-break.c (uninsert_reinsert_breakpoints): New function.
6128 (reinsert_reinsert_breakpoints): New function.
6129 * mem-break.h (uninsert_reinsert_breakpoints): Declare
6130 (reinsert_reinsert_breakpoints): Declare.
6131
6132 2016-06-17 Yao Qi <yao.qi@linaro.org>
6133
6134 * linux-low.c (handle_extended_wait): If the parent is doing
6135 step-over, remove the reinsert breakpoints from the forked child.
6136
6137 2016-06-17 Yao Qi <yao.qi@linaro.org>
6138
6139 * linux-low.c (unsuspend_all_lwps): Declare.
6140 (linux_low_filter_event): If thread exited, call finish_step_over.
6141 If step-over is finished, unsuspend other threads.
6142
6143 2016-06-17 Yao Qi <yao.qi@linaro.org>
6144
6145 * linux-low.c (linux_resume_one_lwp_throw): Assert
6146 has_reinsert_breakpoints returns false.
6147 * mem-break.c (delete_disabled_breakpoints): Assert
6148 bp type isn't reinsert_breakpoint.
6149
6150 2016-06-17 Yao Qi <yao.qi@linaro.org>
6151
6152 * linux-low.c (maybe_hw_step): New function.
6153 (linux_resume_one_lwp_throw): Call maybe_hw_step.
6154 (finish_step_over): Switch current_thread to lwp temporarily,
6155 and assert has_reinsert_breakpoints returns true.
6156 (proceed_one_lwp): Call maybe_hw_step.
6157 * mem-break.c (has_reinsert_breakpoints): New function.
6158 * mem-break.h (has_reinsert_breakpoints): Declare.
6159
6160 2016-06-02 Jon Turney <jon.turney@dronecode.org.uk>
6161
6162 * win32-low.c (win32_create_inferior): Add pointer casts for C++.
6163
6164 2016-05-17 Yao Qi <yao.qi@linaro.org>
6165
6166 * linux-low.c (linux_stabilize_threads): Call unsuspend_all_lwps
6167 instead of find_inferior.
6168
6169 2016-05-05 Yao Qi <yao.qi@linaro.org>
6170
6171 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer):
6172 Initialize res to zero.
6173
6174 2016-05-05 Yao Qi <yao.qi@linaro.org>
6175
6176 * linux-arm-low.c (arm_sigreturn_next_pc): Change type of cpsr
6177 to uint32_t.
6178
6179 2016-05-04 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
6180
6181 * spu-low.c (fetch_ppc_register): Cast PowerPC-Linux-specific value
6182 used as first ptrace argument to PTRACE_TYPE_ARG1 for C++.
6183 (fetch_ppc_memory_1, store_ppc_memory_1): Likewise.
6184
6185 2016-04-28 Par Olsson <par.olsson@windriver.com>
6186 Simon Marchi <simon.marchi@ericsson.com>
6187
6188 * tracepoint.c (write_inferior_int8): New function.
6189 (cmd_qtenable_disable): Write enable flag using
6190 write_inferior_int8.
6191
6192 2016-04-25 Yao Qi <yao.qi@linaro.org>
6193
6194 * linux-low.c (lwp_signal_can_be_delivered): Adjust.
6195 (need_step_over_p): Return zero if the LWP has pending signals
6196 can be delivered on software single step target.
6197
6198 2016-04-25 Yao Qi <yao.qi@linaro.org>
6199
6200 * linux-low.c (reinsert_raw_breakpoint): If bp->inserted is true
6201 return instead of error.
6202
6203 2016-04-22 Yao Qi <yao.qi@linaro.org>
6204
6205 * linux-aarch32-low.c (arm_store_gregset): Clear CPSR bits 20
6206 to 23.
6207
6208 2016-04-22 Yao Qi <yao.qi@linaro.org>
6209
6210 * linux-low.c (lwp_signal_can_be_delivered): Don't deliver
6211 signal when stepping over breakpoint with software single
6212 step.
6213
6214 2016-04-21 Pedro Alves <palves@redhat.com>
6215
6216 * linux-s390-low.c (s390_collect_ptrace_register)
6217 (s390_supply_ptrace_register, s390_get_hwcap): Use gdb_byte * and
6218 add casts.
6219 (s390_check_regset): Use void * instead of gdb_byte *.
6220
6221 2016-04-20 Pedro Alves <palves@redhat.com>
6222
6223 * configure: Renegerate.
6224
6225 2016-04-20 Yao Qi <yao.qi@linaro.org>
6226
6227 * linux-aarch32-low.c: Include "arch/arm-linux.h".
6228 (arm_fill_gregset): Use ARM_CPSR_GREGNUM rather than magic
6229 number 16.
6230 (arm_store_gregset): Likewise.
6231
6232 2016-04-16 Walfred Tedeschi <walfred.tedeschi@intel.com>
6233
6234 * Makefile.in (clean): Add removal for i386-avx-mpx.c,
6235 i386-avx-mpx-linux.c, amd64-avx-mpx.c and amd64-avx-mpx-linux.c.
6236 (i386-avx-mpx.c, i386-avx-mpx-linux.c, amd64-avx-mpx.c)
6237 (amd64-avx-mpx-linux.c): New rules.
6238 (amd64-avx-mpx-linux-ipa.o, i386-avx-mpx-linux-ipa.o): New rule.
6239 * configure.srv (srv_i386_regobj): Add i386-avx-mpx.o.
6240 (srv_i386_linux_regobj): Add i386-avx-mpx-linux.o.
6241 (srv_amd64_regobj): Add amd64-avx-mpx.o.
6242 (srv_amd64_linux_regobj): Add amd64-avx-mpx-linux.o.
6243 (srv_i386_xmlfiles): Add i386/i386-avx-mpx.xml.
6244 (srv_amd64_xmlfiles): Add i386/amd64-avx-mpx.xml.
6245 (srv_i386_linux_xmlfiles): Add i386/i386-avx-mpx-linux.xml.
6246 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-mpx-linux.xml.
6247 (ipa_i386_linux_regobj): Add i386-avx-mpx-linux-ipa.o.
6248 (ipa_amd64_linux_regobj): Add amd64-avx-mpx-linux-ipa.o.
6249 * linux-x86-low.c (x86_linux_read_description): Add case for
6250 X86_XSTATE_AVX_MPX_MASK.
6251 (x86_get_ipa_tdesc_idx): Add cases for avx_mpx.
6252 (initialize_low_arch): Call init_registers_amd64_avx_mpx_linux and
6253 init_registers_i386_avx_mpx_linux.
6254 * linux-i386-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
6255 (initialize_low_tracepoint): Call
6256 init_registers_i386_avx_mpx_linux.
6257 * linux-amd64-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
6258 (initialize_low_tracepoint): Call
6259 init_registers_amd64_avx_mpx_linux.
6260 * linux-x86-tdesc.h (X86_TDESC_AVX_MPX): New enum value.
6261 (init_registers_amd64_avx_mpx_linux, tdesc_amd64_avx_mpx_linux)
6262 (init_registers_i386_avx_mpx_linux, tdesc_i386_avx_mpx_linux): New
6263 declarations.
6264
6265 2016-04-18 Pedro Alves <palves@redhat.com>
6266
6267 * configure: Regenerate.
6268
6269 2016-04-13 Antoine Tremblay <antoine.tremblay@ericsson.com>
6270
6271 * linux-aarch64-low.c (aarch64_emit_add): Switch x1 and x0.
6272 (aarch64_emit_sub): Likewise.
6273
6274 2016-04-12 Pedro Alves <palves@redhat.com>
6275
6276 * utils.c (prepare_to_throw_exception): Delete.
6277
6278 2016-04-05 Simon Marchi <simon.marchi@ericsson.com>
6279
6280 * Makefile.in ($(IPA_LIB)): Set SONAME of the IPA lib.
6281
6282 2016-04-05 Marcin Kościelnicki <koriakin@0x04.net>
6283
6284 * tracepoint.c (getauxval): Move to #ifdef IN_PROCESS_AGENT.
6285
6286 2016-04-03 Marcin Kościelnicki <koriakin@0x04.net>
6287
6288 * linux-aarch64-ipa.c: Add <elf.h> include.
6289 * linux-ppc-ipa.c: Add <elf.h> include.
6290 * linux-s390-ipa.c: Add <elf.h> include.
6291
6292 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
6293
6294 * tracepoint.c (gdb_collect_ptr): Remove const qualifier.
6295 (get_raw_reg_ptr): Likewise.
6296 (get_trace_state_variable_value_ptr): Likewise.
6297 (set_trace_state_variable_value_ptr): Likewise.
6298 (initialize_tracepoint): Cast alloc_jump_pad_buffer result to
6299 char *.
6300
6301 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
6302 Marcin Kościelnicki <koriakin@0x04.net>
6303
6304 PR/17221
6305 * linux-ppc-low.c (emit_insns): New function.
6306 (__EMIT_ASM, _EMIT_ASM, EMIT_ASM): New macros.
6307 (ppc_emit_prologue): New function.
6308 (ppc_emit_epilogue): New function.
6309 (ppc_emit_add): New function.
6310 (ppc_emit_sub): New function.
6311 (ppc_emit_mul): New function.
6312 (ppc_emit_lsh): New function.
6313 (ppc_emit_rsh_signed): New function.
6314 (ppc_emit_rsh_unsigned): New function.
6315 (ppc_emit_ext): New function.
6316 (ppc_emit_zero_ext): New function.
6317 (ppc_emit_log_not): New function.
6318 (ppc_emit_bit_and): New function.
6319 (ppc_emit_bit_or): New function.
6320 (ppc_emit_bit_xor): New function.
6321 (ppc_emit_bit_not): New function.
6322 (ppc_emit_equal): New function.
6323 (ppc_emit_less_signed): New function.
6324 (ppc_emit_less_unsigned): New function.
6325 (ppc_emit_ref): New function.
6326 (ppc_emit_const): New function.
6327 (ppc_emit_reg): New function.
6328 (ppc_emit_pop): New function.
6329 (ppc_emit_stack_flush): New function.
6330 (ppc_emit_swap): New function.
6331 (ppc_emit_stack_adjust): New function.
6332 (ppc_emit_call): New function.
6333 (ppc_emit_int_call_1): New function.
6334 (ppc_emit_void_call_2): New function.
6335 (ppc_emit_if_goto): New function.
6336 (ppc_emit_goto): New function.
6337 (ppc_emit_eq_goto): New function.
6338 (ppc_emit_ne_goto): New function.
6339 (ppc_emit_lt_goto): New function.
6340 (ppc_emit_le_goto): New function.
6341 (ppc_emit_gt_goto): New function.
6342 (ppc_emit_ge_goto): New function.
6343 (ppc_write_goto_address): New function.
6344 (ppc_emit_ops_impl): New static variable.
6345 (ppc64v1_emit_prologue): New function.
6346 (ppc64v2_emit_prologue): New function.
6347 (ppc64_emit_epilogue): New function.
6348 (ppc64_emit_add): New function.
6349 (ppc64_emit_sub): New function.
6350 (ppc64_emit_mul): New function.
6351 (ppc64_emit_lsh): New function.
6352 (ppc64_emit_rsh_signed): New function.
6353 (ppc64_emit_rsh_unsigned): New function.
6354 (ppc64_emit_ext): New function.
6355 (ppc64_emit_zero_ext): New function.
6356 (ppc64_emit_log_not): New function.
6357 (ppc64_emit_bit_and): New function.
6358 (ppc64_emit_bit_or): New function.
6359 (ppc64_emit_bit_xor): New function.
6360 (ppc64_emit_bit_not): New function.
6361 (ppc64_emit_equal): New function.
6362 (ppc64_emit_less_signed): New function.
6363 (ppc64_emit_less_unsigned): New function.
6364 (ppc64_emit_ref): New function.
6365 (ppc64_emit_const): New function.
6366 (ppc64v1_emit_reg): New function.
6367 (ppc64v2_emit_reg): New function.
6368 (ppc64_emit_pop): New function.
6369 (ppc64_emit_stack_flush): New function.
6370 (ppc64_emit_swap): New function.
6371 (ppc64v1_emit_call): New function.
6372 (ppc64v2_emit_call): New function.
6373 (ppc64v1_emit_int_call_1): New function.
6374 (ppc64v2_emit_int_call_1): New function.
6375 (ppc64v1_emit_void_call_2): New function.
6376 (ppc64v2_emit_void_call_2): New function.
6377 (ppc64_emit_if_goto): New function.
6378 (ppc64_emit_eq_goto): New function.
6379 (ppc64_emit_ne_goto): New function.
6380 (ppc64_emit_lt_goto): New function.
6381 (ppc64_emit_le_goto): New function.
6382 (ppc64_emit_gt_goto): New function.
6383 (ppc64_emit_ge_goto): New function.
6384 (ppc64v1_emit_ops_impl): New static variable.
6385 (ppc64v2_emit_ops_impl): New static variable.
6386 (ppc_emit_ops): New function.
6387 (linux_low_target): Wire in ppc_emit_ops.
6388
6389 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
6390 Marcin Kościelnicki <koriakin@0x04.net>
6391
6392 PR/17221
6393 * Makefile.in: Add powerpc-*-ipa.o
6394 * configure.srv: Add ipa_obj for powerpc*-linux.
6395 * linux-ppc-ipa.c: New file.
6396 * linux-ppc-low.c: Added linux-ppc-tdesc.h, ax.h, tracepoint.h
6397 includes.
6398 (PPC_FIELD): New macro.
6399 (PPC_SEXT): New macro.
6400 (PPC_OP6): New macro.
6401 (PPC_BO): New macro.
6402 (PPC_LI): New macro.
6403 (PPC_BD): New macro.
6404 (init_registers_*): Move prototype to linux-ppc-tdesc.h.
6405 (tdesc_*): Move declaration to linux-ppc-tdesc.h.
6406 (ppc_get_hwcap): Rename to ppc_get_auxv and add type parameter.
6407 (ppc_get_thread_area): New function.
6408 (is_elfv2_inferior): New function.
6409 (gen_ds_form): New function.
6410 (GEN_STD): New macro.
6411 (GEN_STDU): New macro.
6412 (GEN_LD): New macro.
6413 (GEN_LDU): New macro.
6414 (gen_d_form): New function.
6415 (GEN_ADDI): New macro.
6416 (GEN_ADDIS): New macro.
6417 (GEN_LI): New macro.
6418 (GEN_LIS): New macro.
6419 (GEN_ORI): New macro.
6420 (GEN_ORIS): New macro.
6421 (GEN_LWZ): New macro.
6422 (GEN_STW): New macro.
6423 (GEN_STWU): New macro.
6424 (gen_xfx_form): New function.
6425 (GEN_MFSPR): New macro.
6426 (GEN_MTSPR): New macro.
6427 (GEN_MFCR): New macro.
6428 (GEN_MTCR): New macro.
6429 (GEN_SYNC): New macro.
6430 (GEN_LWSYNC): New macro.
6431 (gen_x_form): New function.
6432 (GEN_OR): New macro.
6433 (GEN_MR): New macro.
6434 (GEN_LWARX): New macro.
6435 (GEN_STWCX): New macro.
6436 (GEN_CMPW): New macro.
6437 (gen_md_form): New function.
6438 (GEN_RLDICL): New macro.
6439 (GEN_RLDICR): New macro.
6440 (gen_i_form): New function.
6441 (GEN_B): New macro.
6442 (GEN_BL): New macro.
6443 (gen_b_form): New function.
6444 (GEN_BNE): New macro.
6445 (GEN_LOAD): New macro.
6446 (GEN_STORE): New macro.
6447 (gen_limm): New function.
6448 (gen_atomic_xchg): New function.
6449 (gen_call): New function.
6450 (ppc_relocate_instruction): New function.
6451 (ppc_install_fast_tracepoint_jump_pad): New function.
6452 (ppc_get_min_fast_tracepoint_insn_len): New function.
6453 (ppc_get_ipa_tdesc_idx): New function.
6454 (the_low_target): Wire in the new functions.
6455 (initialize_low_arch) [!__powerpc64__]: Don'it initialize 64-bit
6456 tdescs.
6457 * linux-ppc-tdesc.h: New file.
6458
6459 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
6460
6461 * linux-aarch64-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
6462 (alloc_jump_pad_buffer): New function.
6463 * linux-amd64-ipa.c: Add <sys/mman.h> include.
6464 (alloc_jump_pad_buffer): New function.
6465 * linux-i386-ipa.c (alloc_jump_pad_buffer): New function.
6466 * linux-s390-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
6467 (alloc_jump_pad_buffer): New function.
6468 * tracepoint.c (getauxval) [!HAVE_GETAUXVAL]: New function.
6469 (initialize_tracepoint): Delegate to alloc_jump_pad_buffer.
6470 * tracepoint.h (alloc_jump_pad_buffer): New prototype.
6471 (getauxval) [!HAVE_GETAUXVAL]: New prototype.
6472
6473 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
6474
6475 * linux-aarch64-ipa.c: Rename gdb_agent_get_raw_reg to get_raw_reg.
6476 * linux-amd64-ipa.c: Likewise.
6477 * linux-i386-ipa.c: Likewise.
6478 * linux-s390-ipa.c: Likewise.
6479 * tracepoint.c: IPA-export gdb_collect_ptr instead of gdb_collect,
6480 ditto for get_raw_reg_ptr, get_trace_state_variable_value_ptr,
6481 set_trace_state_variable_value_ptr.
6482 (struct ipa_sym_addresses): Likewise.
6483 (symbol_list): Likewise.
6484 (install_fast_tracepoint): Dereference gdb_collect_ptr instead of
6485 accessing gdb_collect directly.
6486 (gdb_collect_ptr_type): New typedef.
6487 (get_raw_reg_ptr_type): New typedef.
6488 (get_trace_state_variable_value_ptr_type): New typedef.
6489 (set_trace_state_variable_value_ptr_type): New typedef.
6490 (gdb_collect_ptr): New global.
6491 (get_raw_reg_ptr): New global.
6492 (get_trace_state_variable_value_ptr): New global.
6493 (set_trace_state_variable_value_ptr): New global.
6494 (get_raw_reg_func_addr): Dereference get_raw_reg_ptr instead of
6495 accessing get_raw_reg directly.
6496 (get_get_tsv_func_addr): Likewise for
6497 get_trace_state_variable_value_ptr.
6498 (get_set_tsv_func_addr): Likewise for
6499 set_trace_state_variable_value_ptr.
6500 * tracepoint.h: Rename gdb_agent_get_raw_reg to get_raw_reg.
6501
6502 2016-03-30 Simon Marchi <simon.marchi@ericsson.com>
6503
6504 * tracepoint.c (cmd_qtenable_disable): Remove whitespace.
6505
6506 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
6507
6508 * remote-utils.c (look_up_one_symbol): Remove own_buf, handle 'v'
6509 packets.
6510 (relocate_instruction): Remove own_buf.
6511 * server.c (own_buf): Make global.
6512 (handle_v_requests): Make global.
6513 * server.h (own_buf): New declaration.
6514 (handle_v_requests): New prototype.
6515
6516 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
6517
6518 PR 18377
6519 * linux-s390-low.c (add_insns): New function.
6520 (s390_emit_prologue): New function.
6521 (s390_emit_epilogue): New function.
6522 (s390_emit_add): New function.
6523 (s390_emit_sub): New function.
6524 (s390_emit_mul): New function.
6525 (s390_emit_lsh): New function.
6526 (s390_emit_rsh_signed): New function.
6527 (s390_emit_rsh_unsigned): New function.
6528 (s390_emit_ext): New function.
6529 (s390_emit_log_not): New function.
6530 (s390_emit_bit_and): New function.
6531 (s390_emit_bit_or): New function.
6532 (s390_emit_bit_xor): New function.
6533 (s390_emit_bit_not): New function.
6534 (s390_emit_equal): New function.
6535 (s390_emit_less_signed): New function.
6536 (s390_emit_less_unsigned): New function.
6537 (s390_emit_ref): New function.
6538 (s390_emit_if_goto): New function.
6539 (s390_emit_goto): New function.
6540 (s390_write_goto_address): New function.
6541 (s390_emit_litpool): New function.
6542 (s390_emit_const): New function.
6543 (s390_emit_call): New function.
6544 (s390_emit_reg): New function.
6545 (s390_emit_pop): New function.
6546 (s390_emit_stack_flush): New function.
6547 (s390_emit_zero_ext): New function.
6548 (s390_emit_swap): New function.
6549 (s390_emit_stack_adjust): New function.
6550 (s390_emit_set_r2): New function.
6551 (s390_emit_int_call_1): New function.
6552 (s390_emit_void_call_2): New function.
6553 (s390_emit_eq_goto): New function.
6554 (s390_emit_ne_goto): New function.
6555 (s390_emit_lt_goto): New function.
6556 (s390_emit_le_goto): New function.
6557 (s390_emit_gt_goto): New function.
6558 (s390_emit_ge_goto): New function.
6559 (s390x_emit_prologue): New function.
6560 (s390x_emit_epilogue): New function.
6561 (s390x_emit_add): New function.
6562 (s390x_emit_sub): New function.
6563 (s390x_emit_mul): New function.
6564 (s390x_emit_lsh): New function.
6565 (s390x_emit_rsh_signed): New function.
6566 (s390x_emit_rsh_unsigned): New function.
6567 (s390x_emit_ext): New function.
6568 (s390x_emit_log_not): New function.
6569 (s390x_emit_bit_and): New function.
6570 (s390x_emit_bit_or): New function.
6571 (s390x_emit_bit_xor): New function.
6572 (s390x_emit_bit_not): New function.
6573 (s390x_emit_equal): New function.
6574 (s390x_emit_less_signed): New function.
6575 (s390x_emit_less_unsigned): New function.
6576 (s390x_emit_ref): New function.
6577 (s390x_emit_if_goto): New function.
6578 (s390x_emit_const): New function.
6579 (s390x_emit_call): New function.
6580 (s390x_emit_reg): New function.
6581 (s390x_emit_pop): New function.
6582 (s390x_emit_stack_flush): New function.
6583 (s390x_emit_zero_ext): New function.
6584 (s390x_emit_swap): New function.
6585 (s390x_emit_stack_adjust): New function.
6586 (s390x_emit_int_call_1): New function.
6587 (s390x_emit_void_call_2): New function.
6588 (s390x_emit_eq_goto): New function.
6589 (s390x_emit_ne_goto): New function.
6590 (s390x_emit_lt_goto): New function.
6591 (s390x_emit_le_goto): New function.
6592 (s390x_emit_gt_goto): New function.
6593 (s390x_emit_ge_goto): New function.
6594 (s390_emit_ops): New function.
6595 (struct linux_target_ops): Fill in emit_ops hook.
6596
6597 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
6598
6599 PR 18377
6600 * Makefile.in: Add s390 IPA files.
6601 * configure.srv: Build IPA for s390.
6602 * linux-s390-ipa.c: New file.
6603 * linux-s390-low.c: New includes - inttypes.h and linux-s390-tdesc.h.
6604 (init_registers_s390_linux32): Move declaration to linux-s390-tdesc.h.
6605 (tdesc_s390_linux32): Likewise.
6606 (init_registers_s390_linux32v1): Likewise.
6607 (tdesc_s390_linux32v1): Likewise.
6608 (init_registers_s390_linux32v2): Likewise.
6609 (tdesc_s390_linux32v2): Likewise.
6610 (init_registers_s390_linux64): Likewise.
6611 (tdesc_s390_linux64): Likewise.
6612 (init_registers_s390_linux64v1): Likewise.
6613 (tdesc_s390_linux64v1): Likewise.
6614 (init_registers_s390_linux64v2): Likewise.
6615 (tdesc_s390_linux64v2): Likewise.
6616 (init_registers_s390_te_linux64): Likewise.
6617 (tdesc_s390_te_linux64): Likewise.
6618 (init_registers_s390_vx_linux64): Likewise.
6619 (tdesc_s390_vx_linux64): Likewise.
6620 (init_registers_s390_tevx_linux64): Likewise.
6621 (tdesc_s390_tevx_linux64): Likewise.
6622 (init_registers_s390x_linux64): Likewise.
6623 (tdesc_s390x_linux64): Likewise.
6624 (init_registers_s390x_linux64v1): Likewise.
6625 (tdesc_s390x_linux64v1): Likewise.
6626 (init_registers_s390x_linux64v2): Likewise.
6627 (tdesc_s390x_linux64v2): Likewise.
6628 (init_registers_s390x_te_linux64): Likewise.
6629 (tdesc_s390x_te_linux64): Likewise.
6630 (init_registers_s390x_vx_linux64): Likewise.
6631 (tdesc_s390x_vx_linux64): Likewise.
6632 (init_registers_s390x_tevx_linux64): Likewise.
6633 (tdesc_s390x_tevx_linux64): Likewise.
6634 (have_hwcap_s390_vx): New static variable.
6635 (s390_arch_setup): Fill have_hwcap_s390_vx.
6636 (s390_get_thread_area): New function.
6637 (s390_ft_entry_gpr_esa): New const.
6638 (s390_ft_entry_gpr_zarch): New const.
6639 (s390_ft_entry_misc): New const.
6640 (s390_ft_entry_fr): New const.
6641 (s390_ft_entry_vr): New const.
6642 (s390_ft_main_31): New const.
6643 (s390_ft_main_64): New const.
6644 (s390_ft_exit_fr): New const.
6645 (s390_ft_exit_vr): New const.
6646 (s390_ft_exit_misc): New const.
6647 (s390_ft_exit_gpr_esa): New const.
6648 (s390_ft_exit_gpr_zarch): New const.
6649 (append_insns): New function.
6650 (s390_relocate_instruction): New function.
6651 (s390_install_fast_tracepoint_jump_pad): New function.
6652 (s390_get_min_fast_tracepoint_insn_len): New function.
6653 (s390_get_ipa_tdesc_idx): New function.
6654 (struct linux_target_ops): Wire in the above functions.
6655 (initialize_low_arch) [!__s390x__]: Don't initialize s390x tdescs.
6656 * linux-s390-tdesc.h: New file.
6657
6658 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
6659
6660 * linux-s390-low.c (s390_supports_tracepoints): New function.
6661 (struct linux_target_ops): Fill supports_tracepoints hook.
6662
6663 2016-03-18 Yao Qi <yao.qi@linaro.org>
6664
6665 * linux-low.c (lwp_signal_can_be_delivered): New function.
6666 (linux_resume_one_lwp_throw): Use lwp_signal_can_be_delivered.
6667
6668 2016-03-18 Yao Qi <yao.qi@linaro.org>
6669
6670 * linux-low.c (linux_resume_one_lwp_throw): Set 'signal' to
6671 0 if signal is enqueued. Remove 'signal' from one debugging
6672 message. Move one debugging message to some lines below.
6673 Remove code setting 'signal' to 0.
6674
6675 2016-03-18 Yao Qi <yao.qi@linaro.org>
6676
6677 * linux-low.c (linux_low_filter_event): Remove redundant
6678 WIFSTOPPED check together with linux_wstatus_maybe_breakpoint.
6679
6680 2016-03-09 Marcin Kościelnicki <koriakin@0x04.net>
6681
6682 * linux-ppc-low.c (ppc_supports_tracepoints): New function.
6683 (struct linux_target_ops): Wire in the above.
6684
6685 2016-03-03 Yao Qi <yao.qi@linaro.org>
6686
6687 * linux-low.c: Update comments to start_step_over.
6688
6689 2016-03-03 Yao Qi <yao.qi@linaro.org>
6690
6691 PR server/19736
6692 * linux-low.c (handle_extended_wait): Set child suspended
6693 if event_lwp->bp_reinsert isn't zero.
6694
6695 2016-03-02 Yao Qi <yao.qi@linaro.org>
6696
6697 * linux-low.c (linux_resume_one_lwp_throw): Replace code with
6698 enqueue_pending_signal.
6699
6700 2016-03-02 Marcin Kościelnicki <koriakin@0x04.net>
6701
6702 * tracepoint.c (cmd_qtstart): Only set ipa_tdesc_idx if agent
6703 is actually loaded.
6704
6705 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
6706
6707 * linux-s390-low.c (s390_num_regs_3264): Define on 31-bit too.
6708 (s390_regmap_3264) [!__s390x__]: New global.
6709 (s390_collect_ptrace_register): Skip map entries containing -1.
6710 (s390_supply_ptrace_register): Ditto.
6711 (s390_fill_gprs_high): New function.
6712 (s390_store_gprs_high): New function.
6713 (s390_regsets): Add NT_S390_HIGH_GPRS.
6714 (s390_get_hwcap): Enable on 31-bit.
6715 (have_hwcap_s390_high_gprs): Enable on 31-bit.
6716 (s390_arch_setup): Enable detection of high GPRs, TDB, VX on 31-bit.
6717 Detect NT_S390_HIGH_GPRS.
6718 (s390_usrregs_info_3264): Enable on 31-bit.
6719 (s390_regs_info): Enable regs_info_3264 on 31-bit.
6720 (initialize_low_arch): Initialize s390_regsets_info_3264 on 31-bit.
6721
6722 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
6723
6724 PR gdb/13808
6725 * Makefile.in: Add i386-*-linux-ipa.o and amd64-*-linux-ipa.o.
6726 * configure.srv: Ditto.
6727 * linux-aarch64-ipa.c (get_ipa_tdesc): New function.
6728 (initialize_low_tracepoint): Remove ipa_tdesc assignment.
6729 * linux-amd64-ipa.c: Add "linux-x86-tdesc.h" include.
6730 (init_registers_amd64_linux): Remove prototype.
6731 (tdesc_amd64_linux): Remove declaration.
6732 (get_ipa_tdesc): New function.
6733 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
6734 initialize remaining tdescs.
6735 * linux-i386-ipa.c: Add "linux-x86-tdesc.h" include.
6736 (init_registers_i386_linux): Remove prototype.
6737 (tdesc_i386_linux): Remove declaration.
6738 (get_ipa_tdesc): New function.
6739 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
6740 initialize remaining tdescs.
6741 * linux-low.c (linux_get_ipa_tdesc_idx): New function.
6742 (linux_target_ops): wire in linux_get_ipa_tdesc_idx.
6743 * linux-low.h (struct linux_target_ops): Add get_ipa_tdesc_idx.
6744 * linux-x86-low.c: Move tdesc declarations to linux-x86-tdesc.h.
6745 (x86_get_ipa_tdesc_idx): New function.
6746 (the_low_target): Wire in x86_get_ipa_tdesc_idx.
6747 * linux-x86-tdesc.h: New file.
6748 * target.h (struct target_ops): Add get_ipa_tdesc_idx.
6749 (target_get_ipa_tdesc_idx): New macro.
6750 * tracepoint.c (ipa_tdesc_idx): New macro.
6751 (struct ipa_sym_addresses): Add addr_ipa_tdesc_idx.
6752 (symbol_list): Add ipa_tdesc_idx.
6753 (cmd_qtstart): Write ipa_tdesc_idx in the target.
6754 (ipa_tdesc): Remove.
6755 (ipa_tdesc_idx): New variable.
6756 (get_context_regcache): Use get_ipa_tdesc.
6757 (gdb_collect): Ditto.
6758 (gdb_probe): Ditto.
6759 * tracepoint.h (get_ipa_tdesc): New prototype.
6760 (ipa_tdesc): Remove.
6761
6762 2016-02-24 Pedro Alves <palves@redhat.com>
6763
6764 * linux-low.c (check_stopped_by_breakpoint): Rename to ...
6765 (save_stop_reason): ... this. Use GDB_ARCH_IS_TRAP_HWBKPT and
6766 handle ambiguous GDB_ARCH_IS_TRAP_BRKPT / GDB_ARCH_IS_TRAP_HWBKPT.
6767 Factor out common code between the USE_SIGTRAP_SIGINFO and
6768 !USE_SIGTRAP_SIGINFO blocks.
6769 (linux_low_filter_event): Call save_stop_reason instead of
6770 check_stopped_by_breakpoint and check_stopped_by_watchpoint.
6771 Update comments.
6772 (linux_wait_1): Update comments.
6773
6774 2016-02-24 Wei-cheng Wang <cole945@gmail.com>
6775
6776 * linux-ppc-low.c (ppc_supports_z_point_type): New function:
6777 (ppc_insert_point, ppc_remove_point): Insert/remove z-packet breakpoints.
6778 (ppc64_emit_ops_vector): Add target ops - ppc_supports_z_point_type,
6779 ppc_insert_point, ppc_remove_point.
6780
6781 2016-02-17 Marcin Kościelnicki <koriakin@0x04.net>
6782
6783 * linux-s390-low.c (s390_supports_z_point_type): New function.
6784 (struct linux_target_ops): Wire s390_supports_z_point_type in.
6785
6786 2016-02-16 Yao Qi <yao.qi@linaro.org>
6787
6788 * linux-arm-low.c (get_next_pcs_syscall_next_pc): Remove argument
6789 PC. Get pc from regcache_read_pc.
6790
6791 2016-02-12 Yao Qi <yao.qi@linaro.org>
6792
6793 * linux-aarch64-low.c (aarch64_get_pc): Call linux_get_pc_64bit
6794 or linux_get_pc_32bit.
6795 (aarch64_set_pc): Call linux_set_pc_64bit or linux_set_pc_32bit.
6796
6797 2016-02-12 Yao Qi <yao.qi@linaro.org>
6798
6799 * linux-arm-low.c (get_next_pcs_ops): Initialize it with
6800 arm_linux_get_next_pcs_fixup.
6801
6802 2016-02-12 Marcin Kościelnicki <koriakin@0x04.net>
6803
6804 * tracepoint.c (x_tracepoint_action_download): Change
6805 write_inferior_data_ptr to write_inferior_data_pointer.
6806 (cmd_qtstart): Likewise.
6807 (write_inferior_data_ptr): Remove.
6808 (download_agent_expr): Change write_inferior_data_ptr to
6809 write_inferior_data_pointer.
6810 (download_tracepoint_1): Likewise.
6811 (download_tracepoint): Likewise.
6812 (download_trace_state_variables): Likewise.
6813
6814 2016-02-11 Wei-cheng Wang <cole945@gmail.com>
6815 Marcin Kościelnicki <koriakin@0x04.net>
6816
6817 * tracepoint.c (struct tracepoint_action_ops): Remove.
6818 (struct tracepoint_action): Remove ops.
6819 (m_tracepoint_action_download, r_tracepoint_action_download)
6820 (x_tracepoint_action_download, l_tracepoint_action_download): Adjust
6821 size and offset accordingly.
6822 (m_tracepoint_action_ops, r_tracepoint_action_ops)
6823 (x_tracepoint_action_ops, l_tracepoint_action_ops): Remove.
6824 (tracepoint_action_send, tracepoint_action_download): New functions.
6825 Helpers for trace action handlers.
6826 (add_tracepoint_action): Remove setup actions ops.
6827 (download_tracepoint_1, tracepoint_send_agent): Call helper functions.
6828
6829 2016-02-10 Yao Qi <yao.qi@linaro.org>
6830
6831 * regcache.c (regcache_raw_read_unsigned): Clear *VAL.
6832
6833 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
6834
6835 * configure.ac: Use AC_CONFIG_FILES instead of passing arguments
6836 to AC_OUTPUT.
6837 * configure: Regenerate.
6838
6839 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
6840
6841 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): Change
6842 void * to gdb_byte *.
6843 * linux-low.c (siginfo_fixup): Likewise.
6844 (linux_xfer_siginfo): Likewise.
6845 * linux-low.h (struct linux_target_ops) <siginfo_fixup>:
6846 Likewise.
6847 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
6848
6849 2016-02-02 Walfred Tedeschi <walfred.tedeschi@intel.com>
6850
6851 * configure.srv (x86_64-*-linux*): Add amd64-linux-siginfo.o
6852 to srv_tgtobj.
6853 (i[34567]86-*-linux*): Add amd64-linux-siginfo.o
6854 to srv_tgtobj.
6855 * linux-x86-low.c [__x86_64__]: Include
6856 "nat/amd64-linux-siginfo.h".
6857 (compat_siginfo_from_siginfo, siginfo_from_compat_siginfo)
6858 (compat_x32_siginfo_from_siginfo, siginfo_from_compat_x32_siginfo)
6859 (compat_timeval, compat_sigval, compat_x32_clock, cpt_si_pid)
6860 (cpt_si_uid, cpt_si_timerid, cpt_si_overrun, cpt_si_status)
6861 (cpt_si_utime, cpt_si_stime, cpt_si_ptr, cpt_si_addr, cpt_si_band)
6862 (cpt_si_fd, si_timerid, si_overrun): Move from
6863 nat/amd64-linux-siginfo.c.
6864 * Makefile.in (amd64-linux-siginfo.o:): New rule.
6865
6866 2016-01-28 Simon Marchi <simon.marchi@ericsson.com>
6867
6868 * server.c (skip_to_semicolon): Remove.
6869 (process_point_options): Use strchrnul instead of
6870 skip_to_semicolon.
6871
6872 2016-01-26 Yao Qi <yao.qi@linaro.org>
6873
6874 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Remove argument pc.
6875 * linux-low.c (install_software_single_step_breakpoints): Don't
6876 call regcache_read_pc.
6877 * linux-low.h (struct linux_target_ops) <get_next_pcs>: Remove
6878 argument pc.
6879
6880 2016-01-26 Yao Qi <yao.qi@linaro.org>
6881
6882 * linux-low.c (install_software_single_step_breakpoints): Call
6883 regcache_read_pc instead of get_pc.
6884
6885 2016-01-26 Yao Qi <yao.qi@linaro.org>
6886
6887 * remote-utils.c (remote_close) [!USE_WIN32API]: Ignore SIGIO.
6888 (unblock_async_io): Rename to ...
6889 (block_unblock_async_io): ... it. New function.
6890 (enable_async_io): Don't install SIGIO handler. Unblock it
6891 instead.
6892 (disable_async_io): Don't ignore SIGIO. Block it instead.
6893 (initialize_async_io): Install SIGIO handler. Don't call
6894 unblock_async_io.
6895
6896 2016-01-26 Yao Qi <yao.qi@linaro.org>
6897
6898 * remote-utils.c (getpkt): If the buffer isn't empty, and the
6899 first character is '\003', call *the_target->request_interrupt.
6900
6901 2016-01-25 Yao Qi <yao.qi@linaro.org>
6902
6903 * remote-utils.c (new_thread_notify): Remove.
6904 (dead_thread_notify): Likewise.
6905 * remote-utils.h (new_thread_notify): Remove declaration.
6906 (dead_thread_notify): Likewise.
6907
6908 2016-01-23 Marcin Kościelnicki <koriakin@0x04.net>
6909
6910 * gdb.trace/pending.exp: Fix expected message on continue.
6911
6912 2016-01-22 Marcin Kościelnicki <koriakin@0x04.net>
6913
6914 * tracepoint.c (write_inferior_data_ptr): Cast to uintptr_t, so that
6915 it works properly on big-endian machines where sizeof (CORE_ADDR)
6916 != sizeof (void *).
6917
6918 2016-01-21 Pedro Alves <palves@redhat.com>
6919
6920 * Makefile.in (COMPILER_CFLAGS, CXXFLAGS): New.
6921 (INTERNAL_CFLAGS_BASE): Use COMPILER_CFLAGS instead of CFLAGS.
6922 * configure: Regenerate.
6923
6924 2016-01-21 Yao Qi <yao.qi@linaro.org>
6925
6926 * linux-arm-low.c (arm_sigreturn_next_pc): Add parameter
6927 is_thumb and set it according to CPSR saved on the stack.
6928 (get_next_pcs_syscall_next_pc): Pass is_thumb to
6929 arm_sigreturn_next_pc.
6930
6931 2016-01-18 Yao Qi <yao.qi@linaro.org>
6932
6933 * linux-low.c (linux_set_pc_64bit): New function.
6934 (linux_get_pc_64bit): New function.
6935 * linux-low.h (linux_set_pc_64bit, linux_get_pc_64bit):
6936 Declare.
6937 * linux-sparc-low.c (debug_threads): Remove declaration.
6938 (sparc_get_pc): Remove.
6939 (the_low_target): Use linux_get_pc_64bit instead of
6940 sparc_get_pc.
6941 * linux-tile-low.c (tile_get_pc, tile_set_pc): Remove.
6942 (the_low_target): Use linux_get_pc_64bit and
6943 linux_set_pc_64bit.
6944
6945 2016-01-18 Yao Qi <yao.qi@linaro.org>
6946
6947 * linux-arm-low.c (debug_threads): Remove declaration.
6948 (arm_get_pc, arm_set_pc): Remove.
6949 (the_low_target): Use linux_get_pc_32bit and
6950 linux_set_pc_32bit.
6951 * linux-bfin-low.c (bfin_get_pc, bfin_set_pc): Remove.
6952 (the_low_target): Use linux_get_pc_32bit and
6953 linux_set_pc_32bit.
6954 * linux-cris-low.c (debug_threads): Remove declaration.
6955 (cris_get_pc, cris_set_pc,): Remove.
6956 (the_low_target): Use linux_get_pc_32bit and
6957 linux_set_pc_32bit.
6958 * linux-crisv32-low.c (debug_threads): Remove declaration.
6959 (cris_get_pc, cris_set_pc): Remove.
6960 (the_low_target): Use linux_get_pc_32bit and
6961 linux_set_pc_32bit.
6962 * linux-low.c: Include inttypes.h.
6963 (linux_get_pc_32bit, linux_set_pc_32bit): New functions.
6964 * linux-low.h (linux_get_pc_32bit, linux_set_pc_32bit): Declare.
6965 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Remove.
6966 (the_low_target): Use linux_get_pc_32bit and
6967 linux_set_pc_32bit.
6968 * linux-m68k-low.c (m68k_get_pc, m68k_set_pc): Remove.
6969 (the_low_target): Use linux_get_pc_32bit and
6970 linux_set_pc_32bit.
6971 * linux-nios2-low.c (nios2_get_pc, nios2_set_pc): Remove.
6972 (the_low_target): Use linux_get_pc_32bit and
6973 linux_set_pc_32bit.
6974 * linux-sh-low.c (sh_get_pc, sh_set_pc): Remove.
6975 (the_low_target): Use linux_get_pc_32bit and
6976 linux_set_pc_32bit.
6977 * linux-xtensa-low.c (xtensa_get_pc, xtensa_set_pc): Remove.
6978 (the_low_target): Use linux_get_pc_32bit and
6979 linux_set_pc_32bit.
6980
6981 2016-01-18 Gary Benson <gbenson@redhat.com>
6982
6983 * configure.ac (AC_FUNC_FORK): New check.
6984 * config.in: Regenerate.
6985 * configure: Likewise.
6986
6987 2016-01-14 Yao Qi <yao.qi@linaro.org>
6988
6989 * linux-aarch32-low.c (thumb2_breakpoint): Make it static.
6990 * linux-aarch32-low.h (thumb2_breakpoint): Remove declaration.
6991 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Pass 1 to
6992 arm_get_next_pcs_ctor.
6993
6994 2016-01-12 Josh Stone <jistone@redhat.com>
6995 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6996
6997 * inferiors.h: Include "gdb_vecs.h".
6998 (struct process_info): Add syscalls_to_catch.
6999 * inferiors.c (remove_process): Free syscalls_to_catch.
7000 * remote-utils.c (prepare_resume_reply): Report syscall_entry and
7001 syscall_return stops.
7002 * server.h (UNKNOWN_SYSCALL, ANY_SYSCALL): Define.
7003 * server.c (handle_general_set): Handle QCatchSyscalls.
7004 (handle_query): Report support for QCatchSyscalls.
7005 * target.h (struct target_ops): Add supports_catch_syscall.
7006 (target_supports_catch_syscall): New macro.
7007 * linux-low.h (struct linux_target_ops): Add get_syscall_trapinfo.
7008 (struct lwp_info): Add syscall_state.
7009 * linux-low.c (handle_extended_wait): Mark syscall_state as an entry.
7010 Maintain syscall_state and syscalls_to_catch across exec.
7011 (get_syscall_trapinfo): New function, proxy to the_low_target.
7012 (linux_low_ptrace_options): Enable PTRACE_O_TRACESYSGOOD.
7013 (linux_low_filter_event): Toggle syscall_state entry/return for
7014 syscall traps, and set it ignored for all others.
7015 (gdb_catching_syscalls_p): New function.
7016 (gdb_catch_this_syscall_p): New function.
7017 (linux_wait_1): Handle SYSCALL_SIGTRAP.
7018 (linux_resume_one_lwp_throw): Add PTRACE_SYSCALL possibility.
7019 (linux_supports_catch_syscall): New function.
7020 (linux_target_ops): Install it.
7021 * linux-x86-low.c (x86_get_syscall_trapinfo): New function.
7022 (the_low_target): Install it.
7023
7024 2016-01-12 Mike Frysinger <vapier@gentoo.org>
7025
7026 * acinclude.m4: Include new ../warning.m4 file.
7027 * configure: Regenerated.
7028 * configure.ac: Replace all warning logic with AM_GDB_WARNINGS.
7029
7030 2016-01-12 Mike Frysinger <vapier@gentoo.org>
7031
7032 * ax.c (is_goto_target): Mark static.
7033 * linux-low.c (register_addr): Likewise.
7034 (linux_fetch_registers, linux_store_registers): Likewise.
7035 * mem-break.c (any_persistent_commands): Fix old prototype.
7036 (add_commands_to_breakpoint): Mark static.
7037 * regcache.c (find_register_by_name): Delete unused func.
7038 * remote-utils.c (hex_or_minus_one): Mark static.
7039 * server.c (monitor_show_help): Mark static.
7040 (handle_query, handle_v_cont, handle_v_attach, handle_v_kill,
7041 handle_v_requests): Likewise.
7042
7043 2016-01-12 Pedro Alves <palves@redhat.com>
7044
7045 Remove use of the registered trademark symbol throughout.
7046
7047 2016-01-08 Yao Qi <yao.qi@linaro.org>
7048
7049 * remote-utils.c (getpkt): If c is '\003', call target hook
7050 request_interrupt.
7051
7052 2016-01-06 Yao Qi <yao.qi@linaro.org>
7053
7054 * linux-aarch32-low.h (arm_abi_breakpoint): Move to
7055 linux-aarch32-low.c.
7056 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
7057 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
7058 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
7059 (thumb2_breakpoint): Declare.
7060 * linux-aarch32-low.c (arm_abi_breakpoint): Moved from
7061 linux-aarch32-low.h.
7062 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
7063 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
7064 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
7065
7066 2016-01-01 Joel Brobecker <brobecker@adacore.com>
7067
7068 * gdbreplay.c (gdbreplay_version): Change copyright year in
7069 version message.
7070 * server.c (gdbserver_version): Likewise.
7071
7072 2015-12-28 Patrick Palka <patrick@parcs.ath.cx>
7073
7074 * server.c (crc32_table): Delete.
7075 (crc32): Use libiberty's xcrc32 function.
7076
7077 2015-12-22 Joel Brobecker <brobecker@adacore.com>
7078
7079 * lynx-low.c (lynx_delete_thread_callback): New function.
7080 (lynx_mourn): Properly delete our process and all of its
7081 threads. Remove call to clear_inferiors.
7082
7083 2015-12-22 Joel Brobecker <brobecker@adacore.com>
7084
7085 * target.c (thread_search_callback): Add check that
7086 the thread_stopped target callback is not NULL before
7087 calling it.
7088
7089 2015-12-21 Yao Qi <yao.qi@linaro.org>
7090
7091 * linux-aarch32-low.h [__aarch64__]: Use arm_abi_breakpoint
7092 arm breakpoint.
7093
7094 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
7095
7096 * server.c (handle_query): Call target_supports_software_single_step.
7097
7098 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
7099
7100 * linux-low.c (single_step): New function.
7101 (linux_resume_one_lwp_throw): Call single_step.
7102 (start_step_over): Likewise.
7103
7104 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
7105
7106 * Makefile.in (SFILES): Append arch/arm-linux.c,
7107 arch/arm-get-next-pcs.c.
7108 (arm-linux.o): New rule.
7109 (arm-get-next-pcs.o): New rule.
7110 * configure.srv (arm*-*-linux*): Add arm-get-next-pcs.o,
7111 arm-linux.o.
7112 * linux-aarch32-low.c (arm_abi_breakpoint): Remove macro. Moved
7113 to linux-aarch32-low.c.
7114 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
7115 (arm_breakpoint_len, thumb_breakpoint): Likewise.
7116 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
7117 (thumb2_breakpoint_len): Likewise.
7118 (arm_is_thumb_mode): Make non-static.
7119 * linux-aarch32-low.h (arm_abi_breakpoint): New macro. Moved
7120 from linux-aarch32-low.c.
7121 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
7122 (arm_breakpoint_len, thumb_breakpoint): Likewise.
7123 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
7124 (thumb2_breakpoint_len): Likewise.
7125 (arm_is_thumb_mode): New declaration.
7126 * linux-arm-low.c: Include arch/arm-linux.h
7127 aarch/arm-get-next-pcs.h, sys/syscall.h.
7128 (get_next_pcs_ops): New struct.
7129 (get_next_pcs_addr_bits_remove): New function.
7130 (get_next_pcs_is_thumb): New function.
7131 (get_next_pcs_read_memory_unsigned_integer): Likewise.
7132 (arm_sigreturn_next_pc): Likewise.
7133 (get_next_pcs_syscall_next_pc): Likewise.
7134 (arm_gdbserver_get_next_pcs): Likewise.
7135 (struct linux_target_ops) <arm_gdbserver_get_next_pcs>:
7136 Initialize.
7137 * linux-low.h: Move CORE_ADDR vector definition to gdb_vecs.h.
7138 * server.h: Include gdb_vecs.h.
7139
7140 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
7141
7142 * Makefile.in (SFILES): Append common/common-regcache.c.
7143 (OBS): Append common-regcache.o.
7144 (common-regcache.o): New rule.
7145 * regcache.c (init_register_cache): Initialize cache to
7146 REG_UNAVAILABLE.
7147 (regcache_raw_read_unsigned): New function.
7148 * regcache.h (REG_UNAVAILABLE, REG_VALID): Replaced by shared
7149 register_status enum.
7150
7151 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
7152
7153 * linux-aarch64-low.c (the_low_targets): Rename
7154 breakpoint_reinsert_addr to get_next_pcs.
7155 * linux-arm-low.c (the_low_targets): Likewise.
7156 * linux-bfin-low.c (the_low_targets): Likewise.
7157 * linux-cris-low.c (the_low_targets): Likewise.
7158 * linux-crisv32-low.c (the_low_targets): Likewise.
7159 * linux-low.c (can_software_single_step): Likewise.
7160 (install_software_single_step_breakpoints): New function.
7161 (start_step_over): Use install_software_single_step_breakpoints.
7162 * linux-low.h: New CORE_ADDR vector.
7163 (struct linux_target_ops) Rename breakpoint_reinsert_addr to
7164 get_next_pcs.
7165 * linux-mips-low.c (the_low_targets): Likewise.
7166 * linux-nios2-low.c (the_low_targets): Likewise.
7167 * linux-sparc-low.c (the_low_targets): Likewise.
7168
7169 2015-12-17 Pedro Alves <palves@redhat.com>
7170
7171 * linux-low.c (linux_kill_one_lwp): Remove references to
7172 LinuxThreads.
7173 (kill_lwp): Remove HAVE_TKILL_SYSCALL check. No longer fall back
7174 to 'kill'.
7175 (linux_init_signals): Delete.
7176 (initialize_low): Adjust.
7177 * thread-db.c (thread_db_init): Remove LinuxThreads reference.
7178
7179 2015-12-16 Pedro Alves <palves@redhat.com>
7180
7181 * configure.ac (compiler warning flags): When testing a
7182 -Wno-foo option, check whether -Wfoo works instead.
7183 * configure: Regenerate.
7184
7185 2015-12-11 Don Breazeal <donb@codesourcery.com>
7186
7187 * server.c (process_serial_event): Don't exit from gdbserver
7188 in remote mode if there are still active inferiors.
7189
7190 2015-12-11 Yao Qi <yao.qi@linaro.org>
7191
7192 * linux-aarch64-low.c (aarch64_breakpoint_at): Call
7193 arm_breakpoint_at if the process is 32-bit.
7194
7195 2015-12-11 Yao Qi <yao.qi@linaro.org>
7196
7197 * linux-aarch32-low.c [__aarch64__]: Use arm_abi_breakpoint
7198 arm breakpoint.
7199
7200 2015-12-07 Yao Qi <yao.qi@linaro.org>
7201
7202 * configure.srv: Append arm.o to srv_tgtobj for
7203 aarch64*-*-linux* target.
7204 * linux-aarch32-low.c (arm_abi_breakpoint): New macro. Moved
7205 from linux-arm-low.c.
7206 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
7207 (arm_breakpoint_len, thumb_breakpoint): Likewise.
7208 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
7209 (thumb2_breakpoint_len): Likewise.
7210 (arm_is_thumb_mode, arm_breakpoint_at): Likewise.
7211 (arm_breakpoint_kinds): Likewise.
7212 (arm_breakpoint_kind_from_pc): Likewise.
7213 (arm_sw_breakpoint_from_kind): Likewise.
7214 (arm_breakpoint_kind_from_current_state): Likewise.
7215 * linux-aarch32-low.h (arm_breakpoint_kind_from_pc): Declare.
7216 (arm_sw_breakpoint_from_kind): Declare.
7217 (arm_breakpoint_kind_from_current_state): Declare.
7218 (arm_breakpoint_at): Declare.
7219 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): Call
7220 arm_sw_breakpoint_from_kind if process is 32-bit.
7221 (aarch64_breakpoint_kind_from_pc): New function.
7222 (aarch64_breakpoint_kind_from_current_state): New function.
7223 (the_low_target): Initialize fields breakpoint_kind_from_pc
7224 and breakpoint_kind_from_current_state.
7225 * linux-arm-low.c (arm_breakpoint_kinds): Move to
7226 linux-aarch32-low.c.
7227 (arm_abi_breakpoint, arm_eabi_breakpoint): Likewise.
7228 (arm_breakpoint, arm_breakpoint_len): Likewise.
7229 (thumb_breakpoint, thumb_breakpoint_len): Likewise.
7230 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
7231 (arm_is_thumb_mode): Likewise.
7232 (arm_breakpoint_at): Likewise.
7233 (arm_breakpoint_kind_from_pc): Likewise.
7234 (arm_sw_breakpoint_from_kind): Likewise.
7235 (arm_breakpoint_kind_from_current_state): Likewise.
7236
7237 Revert:
7238 2015-08-04 Yao Qi <yao.qi@linaro.org>
7239
7240 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
7241 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
7242 * server.c (extended_protocol): Remove "static".
7243 * server.h (extended_protocol): Declare it.
7244
7245 2015-12-04 Josh Stone <jistone@redhat.com>
7246
7247 * target.h (struct target_ops) <arch_setup>: Rename to ...
7248 (struct target_ops) <post_create_inferior>: ... this.
7249 (target_arch_setup): Rename to ...
7250 (target_post_create_inferior): ... this, calling post_create_inferior.
7251 * server.c (start_inferior): Update target_arch_setup calls to
7252 target_post_create_inferior.
7253 * linux-low.c (linux_low_ptrace_options): Forward declare.
7254 (linux_arch_setup): Update its comment for general use.
7255 (linux_post_create_inferior): New, run arch_setup and setup ptrace.
7256 (struct linux_target_ops): Use linux_post_create_inferior.
7257 * lynx-low.c (struct lynx_target_ops): Update arch_setup stub comment
7258 to post_create_inferior.
7259 * nto-low.c (struct nto_target_ops): Likewise.
7260 * spu-low.c (struct spu_target_ops): Likewise.
7261 * win32-low.c (struct win32_target_ops): Likewise.
7262
7263 2015-12-03 Antoine Tremblay <antoine.tremblay@ericsson.com>
7264
7265 * linux-arm-low.c: Remove duplicate arch/arm.h include.
7266
7267 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
7268
7269 * linux-arm-low.c (arm_reinsert_addr): Remove function.
7270 (struct linux_target_ops <breakpoint_reinsert_addr>: Set to NULL.
7271 * linux-cris-low.c (cris_reinsert_addr> Remove function.
7272 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
7273 * linux-crisv32-low.c (cris_reinsert_addr): Remove function.
7274 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
7275 * linux-mips-low.c (mips_reinsert_addr): Remove function.
7276 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
7277 * linux-nios2-low.c (nios2_reinsert_addr): Remove function.
7278 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
7279 * linux-sparc-low.c (sparc_reinsert_addr): Remove function.
7280 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
7281
7282 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
7283
7284 * linux-low.c (linux_look_up_symbols): Don't call
7285 linux_supports_traceclone.
7286 * linux-low.h (thread_db_init): Remove use_events argument.
7287 * thread-db.c (thread_db_use_event): Remove global variable.
7288 (struct thread_db) <td_thr_event_enable_p>: Remove field.
7289 (struct thread_db) <td_create_bp>: Remove field.
7290 (thread_db_create_event): Remove function.
7291 (thread_db_enable_reporting): Likewise.
7292 (find_one_thread): Don't check for thread_db_use_events.
7293 (attach_thread): Likewise.
7294 (thread_db_load_search): Remove td_thr_event_enable_p initialization.
7295 (try_thread_db_load_1): Don't check for thread_db_use_events.
7296 (thread_db_init): Remove use_events argument and thread events
7297 handling.
7298 (remove_thread_event_breakpoints): Remove function.
7299 (thread_db_detach): Remove call to remove_thred_event_breakpoints.
7300
7301 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
7302
7303 * linux-aarch64-low.c (aarch64_supports_hardware_single_step):
7304 New function.
7305 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
7306 * linux-arm-low.c (arm_supports_hardware_single_step): New function.
7307 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
7308 * linux-bfin-low.c (bfin_supports_hardware_single_step): New function.
7309 (struct linux_target_ops) <bfin_supports_hardware_single_step>:
7310 Initialize.
7311 * linux-crisv32-low.c (cris_supports_hardware_single_step):
7312 New function.
7313 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
7314 * linux-low.c (can_hardware_single_step): Use
7315 supports_hardware_single_step.
7316 (can_software_single_step): New function.
7317 (start_step_over): Call can_software_single_step.
7318 (linux_supports_hardware_single_step): New function.
7319 (struct target_ops) <supports_software_single_step>: Initialize.
7320 * linux-low.h (struct linux_target_ops)
7321 <supports_hardware_single_step>: Initialize.
7322 * linux-m32r-low.c (m32r_supports_hardware_single_step): New function.
7323 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
7324 * linux-ppc-low.c (ppc_supports_hardware_single_step): New function.
7325 (struct linux_target_ops) <supports_hardware_single_step> Initialize.
7326 * linux-s390-low.c (s390_supports_hardware_single_step): New function.
7327 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
7328 * linux-sh-low.c (sh_supports_hardware_single_step): New function.
7329 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
7330 * linux-tic6x-low.c (tic6x_supports_hardware_single_step): New function.
7331 (struct linux_target_ops) <tic6x_supports_hardware_single_step>:
7332 Initialize.
7333 * linux-tile-low.c (tile_supports_hardware_single_step): New function.
7334 (struct linux_target_ops) <tile_supports_hardware_single_step>:
7335 Initialize.
7336 * linux-x86-low.c (x86_supports_hardware_single_step) New function.
7337 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
7338 * linux-xtensa-low.c (xtensa_supports_hardware_single_step):
7339 New function.
7340 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
7341 * target.h (struct target_ops): <supports_software_single_step>:
7342 New field.
7343 (target_supports_software_single_step): New macro.
7344
7345 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
7346
7347 * linux-low.c (linux_wait_1): Fix pc advance condition.
7348 * mem-break.c (reinsert_breakpoint_inserted_here): New function.
7349 * mem-break.h (reinsert_breakpoint_inserted_here): New declaration.
7350
7351 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
7352
7353 * linux-arm-low.c (arm_is_thumb_mode): New function.
7354 (arm_breakpoint_at): Use arm_is_thumb_mode.
7355 (arm_breakpoint_kind_from_current_state): New function.
7356 (struct linux_target_ops) <breakpoint_kind_from_current_state>:
7357 Initialize.
7358 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_current_state.
7359 (linux_breakpoint_kind_from_current_state): New function.
7360 (struct target_ops <breakpoint_kind_from_current_state>: Initialize.
7361 * linux-low.h (struct linux_target_ops)
7362 <breakpoint_kind_from_current_state>: New field.
7363 * target.h (struct target_ops): Likewise.
7364 (target_breakpoint_kind_from_current_state): New macro.
7365
7366 2015-11-30 Pedro Alves <palves@redhat.com>
7367
7368 * linux-low.c (linux_resume): Wake up the event loop before
7369 returning.
7370
7371 2015-11-30 Pedro Alves <palves@redhat.com>
7372
7373 * mem-break.c (check_gdb_bp_preconditions): Remove current_thread
7374 check.
7375 (set_gdb_breakpoint): If prepare_to_access_memory fails, set *ERR
7376 to -1.
7377 * target.c (struct thread_search): New structure.
7378 (thread_search_callback): New function.
7379 (prev_general_thread): New global.
7380 (prepare_to_access_memory, done_accessing_memory): New functions.
7381 * target.h (prepare_to_access_memory, done_accessing_memory):
7382 Replace macros with function declarations.
7383
7384 2015-11-30 Pedro Alves <palves@redhat.com>
7385
7386 PR 14618
7387 * linux-low.c (linux_wait_1): If the last resumed thread is gone,
7388 report TARGET_WAITKIND_NO_RESUMED.
7389 * remote-utils.c (prepare_resume_reply): Handle
7390 TARGET_WAITKIND_NO_RESUMED.
7391 * server.c (report_no_resumed): New global.
7392 (handle_query) <qSupported>: Handle "no-resumed+". Report
7393 "no-resumed+" support.
7394 (resume): When the target reports TARGET_WAITKIND_NO_RESUMED, only
7395 return error if the client doesn't support no-resumed events.
7396 (push_stop_notification): New function.
7397 (handle_target_event): Use it. Report TARGET_WAITKIND_NO_RESUMED
7398 events if the client supports them.
7399
7400 2015-11-30 Pedro Alves <palves@redhat.com>
7401
7402 * linux-low.c (thread_still_has_status_pending_p): Don't check
7403 vCont;t here.
7404 (lwp_resumed): New function.
7405 (status_pending_p_callback): Return early if the LWP is not
7406 supposed to be resumed.
7407
7408 2015-11-30 Pedro Alves <palves@redhat.com>
7409
7410 * linux-low.c (handle_extended_wait): Assert that the LWP's
7411 waitstatus is TARGET_WAITKIND_IGNORE. If GDB wants to hear about
7412 thread create events, leave the new child's status pending.
7413 (linux_low_filter_event): If GDB wants to hear about thread exit
7414 events, leave the LWP marked dead and don't delete it.
7415 (linux_wait_for_event_filtered): Don't check for thread exit.
7416 (filter_exit_event): New function.
7417 (linux_wait_1): Use it, when returning an exit event.
7418 (linux_resume_one_lwp_throw): Assert that the LWP's
7419 waitstatus is TARGET_WAITKIND_IGNORE.
7420 * remote-utils.c (prepare_resume_reply): Handle
7421 TARGET_WAITKIND_THREAD_CREATED and TARGET_WAITKIND_THREAD_EXITED.
7422 * server.c (report_thread_events): New global.
7423 (handle_general_set): Handle QThreadEvents.
7424 (handle_query) <qSupported>: Handle and report QThreadEvents+;
7425 (handle_target_event): Handle TARGET_WAITKIND_THREAD_CREATED and
7426 TARGET_WAITKIND_THREAD_EXITED.
7427 * server.h (report_thread_events): Declare.
7428
7429 2015-11-30 Pedro Alves <palves@redhat.com>
7430
7431 * linux-low.c (resume_stopped_resumed_lwps): Don't check whether
7432 the thread's last_resume_kind was resume_stop.
7433
7434 2015-11-30 Pedro Alves <palves@redhat.com>
7435
7436 * linux-low.c (linux_attach): In non-stop mode, wait for one stop
7437 before returning.
7438
7439 2015-11-30 Pedro Alves <palves@redhat.com>
7440
7441 * server.c (handle_v_requests): Handle vCtrlC.
7442
7443 2015-11-30 Pedro Alves <palves@redhat.com>
7444
7445 * gdbthread.h (find_any_thread_of_pid): Declare.
7446 * inferiors.c (thread_of_pid, find_any_thread_of_pid): New
7447 functions.
7448 * server.c (handle_query): If current_thread is NULL, look for
7449 another thread of the selected process.
7450
7451 2015-11-26 Daniel Colascione <dancol@dancol.org>
7452 Simon Marchi <simon.marchi@ericsson.com>
7453
7454 * linux-low.c (linux_target_ops): Use linux_proc_tid_get_name.
7455 * server.c (handle_qxfer_threads_worker): Refactor to include thread
7456 name in reply.
7457 * target.h (struct target_ops) <thread_name>: New field.
7458 (target_thread_name): New macro.
7459
7460 2015-11-23 Joel Brobecker <brobecker@adacore.com>
7461
7462 * regcache.h (regcache_invalidate_pid): Add declaration.
7463 * regcache.c (regcache_invalidate_pid): New function, extracted
7464 from regcache_invalidate.
7465 (regcache_invalidate): Reimplement using regcache_invalidate_pid.
7466 Add trivial documentation comment.
7467 * lynx-low.c: Use regcache_invalidate_pid instead of
7468 regcache_invalidate.
7469
7470 2015-11-23 Joel Brobecker <brobecker@adacore.com>
7471
7472 * configure.ac: Do not call AC_CHECK_TYPES for Elf32_auxv_t
7473 and Elf64_auxv_t if the target is Android.
7474
7475 2015-11-22 Doug Evans <xdje42@gmail.com>
7476
7477 * target.h: #include <sys/types.h>.
7478
7479 2015-11-19 Pedro Alves <palves@redhat.com>
7480
7481 * linux-low.c (linux_process_qsupported): Change prototype.
7482 Adjust.
7483 * linux-low.h (struct linux_target_ops) <process_qsupported>:
7484 Change prototype.
7485 * linux-x86-low.c (x86_linux_process_qsupported): Change prototype
7486 and adjust to loop over all features.
7487 * server.c (handle_query) <qSupported>: Adjust to call
7488 target_process_qsupported once, passing it a vector of unprocessed
7489 features.
7490 * target.h (struct target_ops) <process_qsupported>: Change
7491 prototype.
7492 (target_process_qsupported): Adjust.
7493
7494 2015-11-19 Pedro Alves <palves@redhat.com>
7495
7496 * configure.ac (ERROR_ON_WARNING): Don't check whether in C++
7497 mode.
7498 * configure: Regenerate.
7499
7500 2015-11-19 Pedro Alves <palves@redhat.com>
7501
7502 * configure: Regenerate.
7503
7504 2015-11-19 Yao Qi <yao.qi@linaro.org>
7505
7506 * linux-aarch64-low.c (emit_data_processing_reg): Change opcode
7507 type to uint32_t.
7508
7509 2015-11-19 Yao Qi <yao.qi@linaro.org>
7510
7511 * linux-aarch64-low.c (enum aarch64_operand_type): New.
7512 (struct aarch64_operand): Move enum out.
7513
7514 2015-11-19 Yao Qi <yao.qi@linaro.org>
7515
7516 * linux-aarch64-low.c (aarch64_fill_fpregset): Cast buf to
7517 struct user_fpsimd_state *.
7518 (aarch64_store_fpregset): Likewise.
7519
7520 2015-11-19 Yao Qi <yao.qi@linaro.org>
7521
7522 * linux-aarch64-low.c (aarch64_fill_gregset): Cast buf to
7523 struct user_pt_regs *.
7524 (aarch64_store_gregset): Likewise.
7525
7526 2015-11-18 Pedro Alves <palves@redhat.com>
7527
7528 * Makefile.in (all_object_files): Add $IPA_OBJS.
7529
7530 2015-11-17 Pedro Alves <palves@redhat.com>
7531
7532 * win32-low.c (win32_resume): Use gdb_signal_from_host,
7533 GDB_SIGNAL_0 and gdb_signal_to_string.
7534
7535 2015-11-17 Pedro Alves <palves@redhat.com>
7536
7537 * win32-low.c (handle_output_debug_string): Remove parameter.
7538 (win32_kill): Remove our_status local and adjust call to
7539 handle_output_debug_string.
7540 (get_child_debug_event): Adjust call to
7541 handle_output_debug_string.
7542
7543 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
7544
7545 * linux-mips-low.c (mips_fill_gregset): Add cast.
7546 (mips_store_gregset): Likewise.
7547 (mips_fill_fpregset): Likewise.
7548 (mips_store_fpregset): Likewise.
7549
7550 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
7551
7552 * linux-mips-low.c (mips_add_watchpoint): Rename private to
7553 priv.
7554
7555 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
7556
7557 * linux-mips-low.c (mips_linux_new_thread): Change type of
7558 watch_type to enum target_hw_bp_type.
7559
7560 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
7561
7562 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type):
7563 Change return type to arm_hwbp_type.
7564
7565 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
7566
7567 * linux-aarch32-low.c (arm_fill_gregset): Add cast.
7568 (arm_store_gregset): Likewise.
7569 * linux-arm-low.c (arm_get_hwcap): Likewise.
7570 (arm_read_description): Likewise.
7571
7572 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
7573
7574 * linux-aarch32-low.c (aarch32_regsets): Use NULL_REGSET.
7575
7576 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
7577
7578 * linux-ppc-low.c (ppc_get_hwcap): Add cast.
7579 (ppc_fill_vsxregset): Likewise.
7580 (ppc_store_vsxregset): Likewise.
7581 (ppc_fill_vrregset): Likewise.
7582 (ppc_store_vrregset): Likewise.
7583 (ppc_fill_evrregset): Likewise.
7584 (ppc_store_evrregset): Likewise.
7585
7586 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
7587
7588 * linux-ppc-low.c (ppc_usrregs_info): Remove
7589 forward-declaration.
7590 (ppc_arch_setup): Move lower in file.
7591
7592 2015-10-30 Simon Marchi <simon.marchi@ericsson.com>
7593
7594 * proc-service.c (ps_pdread): Change CORE_ADDR cast to uintptr_t.
7595 (ps_pdwrite): Likewise.
7596
7597 2015-10-29 Henrik Wallin <henrik.wallin@windriver.com>
7598
7599 * linux-arm-low.c (arm_new_thread): Move pointer dereference
7600 to after assert checks.
7601
7602 2015-10-29 Simon Marchi <simon.marchi@ericsson.com>
7603
7604 * proc-service.c (ps_pdread): Add/adjust casts.
7605 (ps_pdwrite): Add/adjust casts.
7606
7607 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
7608
7609 * server.c (handle_search_memory_1): Cast return value of
7610 memmem.
7611
7612 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
7613
7614 * server.c (write_qxfer_response): Change type of data to
7615 gdb_byte *.
7616
7617 2015-10-29 Pedro Alves <palves@redhat.com>
7618
7619 * mem-break.c (Z_packet_to_bkpt_type): Add cast.
7620
7621 2015-10-29 Pedro Alves <palves@redhat.com>
7622
7623 * tracepoint.c (clear_installed_tracepoints): Add casts.
7624
7625 2015-10-29 Pedro Alves <palves@redhat.com>
7626
7627 * server.c (handle_v_cont, process_serial_event): Add enum
7628 gdb_signal casts to signal parsing code.
7629
7630 2015-10-29 Pedro Alves <palves@redhat.com>
7631
7632 * linux-low.h (NULL_REGSET): Define.
7633 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
7634 * linux-arm-low.c (arm_regsets): Likewise.
7635 * linux-crisv32-low.c (cris_regsets): Likewise.
7636 * linux-m68k-low.c (m68k_regsets): Likewise.
7637 * linux-mips-low.c (mips_regsets): Likewise.
7638 * linux-nios2-low.c (nios2_regsets): Likewise.
7639 * linux-ppc-low.c (ppc_regsets): Likewise.
7640 * linux-s390-low.c (s390_regsets): Likewise.
7641 * linux-sh-low.c (sh_regsets): Likewise.
7642 * linux-sparc-low.c (sparc_regsets): Likewise.
7643 * linux-tic6x-low.c (tic6x_regsets): Likewise.
7644 * linux-tile-low.c (tile_regsets): Likewise.
7645 * linux-x86-low.c (x86_regsets): Likewise.
7646 * linux-xtensa-low.c (xtensa_regsets): Likewise.
7647
7648 2015-10-29 Pedro Alves <palves@redhat.com>
7649
7650 * linux-low.h (NULL_REGSET): Define.
7651 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
7652 * linux-arm-low.c (arm_regsets): Likewise.
7653 * linux-crisv32-low.c (cris_regsets): Likewise.
7654 * linux-m68k-low.c (m68k_regsets): Likewise.
7655 * linux-mips-low.c (mips_regsets): Likewise.
7656 * linux-nios2-low.c (nios2_regsets): Likewise.
7657 * linux-ppc-low.c (ppc_regsets): Likewise.
7658 * linux-s390-low.c (s390_regsets): Likewise.
7659 * linux-sh-low.c (sh_regsets): Likewise.
7660 * linux-sparc-low.c (sparc_regsets): Likewise.
7661 * linux-tic6x-low.c (tic6x_regsets): Likewise.
7662 * linux-tile-low.c (tile_regsets): Likewise.
7663 * linux-x86-low.c (x86_regsets): Likewise.
7664 * linux-xtensa-low.c (xtensa_regsets): Likewise.
7665
7666 2015-10-26 Doug Evans <dje@google.com>
7667
7668 * linux-low.c (__SIGRTMIN): Move to nat/linux-nat.h.
7669
7670 2015-10-26 Doug Evans <dje@google.com>
7671
7672 * linux-low.c (W_STOPCODE): Moved to common/gdb_wait.h.
7673
7674 2015-10-26 Doug Evans <dje@google.com>
7675
7676 * thread-db.c (find_one_thread): Cast ti.ti_tid to unsigned long
7677 for debug_printf.
7678 (attach_thread, find_new_threads_callback): Ditto.
7679
7680 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
7681
7682 * mem-break.h (set_breakpoint_data): Remove.
7683
7684 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
7685
7686 * nto-low.c (nto_sw_breakpoint_from_kind): New function.
7687 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
7688 (initialize_low): Remove set_breakpoint_data call.
7689 * spu-low.c (spu_sw_breakpoint_from_kind): New function.
7690 (struct target_ops) <sw_breakpoint_from_kind>: Iniitalize.
7691 (initialize_low): Remove set_breakpoint_data call.
7692 * win32-low.c (win32_sw_breakpoint_from_kind): New function.
7693 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
7694 (initialize_low): Remove set_breakpoint_data call.
7695
7696 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
7697
7698 * linux-low.c (default_breakpoint_kind_from_pc): Move to target.c.
7699 * mem-break.c (set_breakpoint_at): Use target_breakpoint_kind_from_pc.
7700 * target.c (default_breakpoint_kind_from_pc): Moved from linux-low.c
7701 * target.h (target_breakpoint_kind_from_pc): New macro.
7702
7703 2015-10-22 Antoine Tremblay <antoine.tremblay@ericsson.com>
7704
7705 * linux-low.c (default_breakpoint_kind_from_pc): New function.
7706 (linux_breakpoint_kind_from_pc): Use default_breakpoint_kind_from_pc for
7707 the default breakpoint kind.
7708
7709 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
7710
7711 * linux-arm-low.c (arm_supports_z_point_type): Add software
7712 breakpoint support.
7713
7714 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
7715
7716 * linux-arm-low.c: Refactor breakpoint definitions.
7717 (arm_breakpoint_at): Adjust for arm_abi_breakpoint.
7718 (arm_sw_breakpoint_from_kind): Adjust for arm_breakpoint.
7719
7720 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
7721
7722 * Makefile.in: Add arm.c/o.
7723 * configure.srv: Likewise.
7724 * linux-arm-low.c (arm_breakpoint_kinds): New enum.
7725 (arm_breakpoint_kind_from_pc): New function.
7726 (arm_sw_breakpoint_from_kind): Return proper kind.
7727 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize.
7728
7729 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
7730
7731 * linux-low.c (initialize_low): Ajdust for breakpoint global variables
7732 removal.
7733 * mem-break.c : Remove breakpoint_data/breakpoint_len global variables.
7734 (struct raw_breakpoint) <size>: Remove.
7735 (struct raw_breakpoint) <kind>: Add.
7736 (bp_size): New function.
7737 (bp_opcode): Likewise.
7738 (find_raw_breakpoint_at): Adjust for kind.
7739 (insert_memory_breakpoint): Adjust for kind call bp_size,bp_opcode.
7740 (remove_memory_breakpoint): Adjust for kind call bp_size.
7741 (set_raw_breakpoint_at): Adjust for kind.
7742 (set_breakpoint): Likewise.
7743 (set_breakpoint_at): Call breakpoint_kind_from_pc.
7744 (delete_raw_breakpoint): Adjust for kind.
7745 (delete_breakpoint): Likewise.
7746 (find_gdb_breakpoint): Likewise.
7747 (set_gdb_breakpoint_1): Likewise.
7748 (set_gdb_breakpoint): Likewise.
7749 (delete_gdb_breakpoint_1): Likewise.
7750 (delete_gdb_breakpoint): Likewise.
7751 (uninsert_raw_breakpoint): Likewise.
7752 (reinsert_raw_breakpoint): Likewise.
7753 (set_breakpoint_data): Remove.
7754 (validate_inserted_breakpoint): Adjust for kind call bp_size,bp_opcode.
7755 (check_mem_read): Adjust for kind call bp_size.
7756 (check_mem_write): Adjust for kind call bp_size,bp_opcode.
7757 (clone_one_breakpoint): Adjust for kind.
7758 * mem-break.h (set_gdb_breakpoint): Likewise.
7759 (delete_gdb_breakpoint): Likewise.
7760 * server.c (process_serial_event): Likewise.
7761
7762 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
7763
7764 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): New function.
7765 (struct linux_target_ops) <breakpoint>: Remove.
7766 (struct linux_target_ops) <breakpoint_len>: Remove.
7767 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7768 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7769 * linux-arm-low.c (arm_breakpoint_kind_from_pc): New function.
7770 (arm_sw_breakpoint_from_kind): New function.
7771 * linux-bfin-low.c (bfin_sw_breakpoint_from_kind): New function.
7772 (struct linux_target_ops) <breakpoint>: Remove.
7773 (struct linux_target_ops) <breakpoint_len>: Remove.
7774 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7775 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7776 * linux-cris-low.c (cris_sw_breakpoint_from_kind): New function.
7777 (struct linux_target_ops) <breakpoint>: Remove.
7778 (struct linux_target_ops) <breakpoint_len>: Remove.
7779 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7780 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7781 * linux-crisv32-low.c (cris_sw_breakpoint_from_kind): New function.
7782 (struct linux_target_ops) <breakpoint>: Remove.
7783 (struct linux_target_ops) <breakpoint_len>: Remove.
7784 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7785 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7786 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_pc
7787 and sw_breakpoint_from_kind to increment the pc.
7788 (linux_breakpoint_kind_from_pc): New function.
7789 (linux_sw_breakpoint_from_kind): New function.
7790 (struct target_ops) <sw_breakpoint_from_kind>: Initialize field.
7791 (initialize_low): Call breakpoint_kind_from_pc and
7792 sw_breakpoint_from_kind to replace breakpoint_data/len.
7793 * linux-low.h (struct linux_target_ops) <breakpoint_kind_from_pc>:
7794 New field.
7795 (struct linux_target_ops) <sw_breakpoint_from_kind>: Likewise.
7796 * linux-m32r-low.c (m32r_sw_breakpoint_from_kind): New function.
7797 (struct linux_target_ops) <breakpoint>: Remove.
7798 (struct linux_target_ops) <breakpoint_len>: Remove.
7799 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7800 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7801 * linux-m68k-low.c (m68k_sw_breakpoint_from_kind): New function.
7802 (struct linux_target_ops) <breakpoint>: Remove.
7803 (struct linux_target_ops) <breakpoint_len>: Remove.
7804 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7805 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7806 * linux-mips-low.c (mips_sw_breakpoint_from_kind): New function.
7807 (struct linux_target_ops) <breakpoint>: Remove.
7808 (struct linux_target_ops) <breakpoint_len>: Remove.
7809 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7810 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7811 * linux-nios2-low.c (nios2_sw_breakpoint_from_kind): New function.
7812 (struct linux_target_ops) <breakpoint>: Remove.
7813 (struct linux_target_ops) <breakpoint_len>: Remove.
7814 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7815 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7816 * linux-ppc-low.c (ppc_sw_breakpoint_from_kind): New function.
7817 (struct linux_target_ops) <breakpoint>: Remove.
7818 (struct linux_target_ops) <breakpoint_len>: Remove.
7819 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7820 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7821 * linux-s390-low.c (s390_sw_breakpoint_from_kind): New function.
7822 (struct linux_target_ops) <breakpoint>: Remove.
7823 (struct linux_target_ops) <breakpoint_len>: Remove.
7824 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7825 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7826 * linux-sh-low.c (sh_sw_breakpoint_from_kind): New function.
7827 (struct linux_target_ops) <breakpoint>: Remove.
7828 (struct linux_target_ops) <breakpoint_len>: Remove.
7829 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7830 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7831 * linux-sparc-low.c (sparc_sw_breakpoint_from_kind): New function.
7832 (struct linux_target_ops) <breakpoint>: Remove.
7833 (struct linux_target_ops) <breakpoint_len>: Remove.
7834 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7835 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7836 * linux-tic6x-low.c (tic6x_sw_breakpoint_from_kind): New function.
7837 (struct linux_target_ops) <breakpoint>: Remove.
7838 (struct linux_target_ops) <breakpoint_len>: Remove.
7839 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7840 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7841 * linux-tile-low.c (tile_sw_breakpoint_from_kind): New function.
7842 * linux-x86-low.c (x86_sw_breakpoint_from_kind): New function.
7843 (struct linux_target_ops) <breakpoint>: Remove.
7844 (struct linux_target_ops) <breakpoint_len>: Remove.
7845 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7846 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7847 * linux-xtensa-low.c (xtensa_sw_breakpoint_from_kind) New function.
7848 (struct linux_target_ops) <breakpoint>: Remove.
7849 (struct linux_target_ops) <breakpoint_len>: Remove.
7850 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7851 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7852
7853 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
7854
7855 * linux-cris-low.c (cris_get_pc): Remove void arg.
7856
7857 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
7858
7859 * gdbserver/nto-low.c (nto_insert_point, nto_remove_point): Fix
7860 variable name.
7861
7862 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
7863
7864 * inferiors.c (thread_pid_matches_callback): New function.
7865 (find_thread_process): New function.
7866 (remove_thread): Reset current_thread.
7867 (remove_process): Assert threads have been removed first.
7868
7869 2015-10-15 Yao Qi <yao.qi@linaro.org>
7870
7871 * linux-aarch64-low.c (aarch64_insert_point): Set len to 2
7872 if it is 3.
7873 (aarch64_remove_point): Likewise.
7874 * regcache.c (regcache_register_size): New function.
7875
7876 2015-10-12 Yao Qi <yao.qi@linaro.org>
7877
7878 * linux-aarch64-low.c: Update all callers as emit_load_store
7879 is renamed to aarch64_emit_load_store.
7880
7881 2015-10-12 Yao Qi <yao.qi@linaro.org>
7882
7883 * linux-aarch64-low.c: Update all callers of function renaming
7884 from emit_insn to aarch64_emit_insn.
7885
7886 2015-10-12 Yao Qi <yao.qi@linaro.org>
7887
7888 * linux-aarch64-low.c (enum aarch64_opcodes): Move to
7889 arch/aarch64-insn.h.
7890 (struct aarch64_memory_operand): Likewise.
7891 (ENCODE): Likewise.
7892 (emit_insn): Move to arch/aarch64-insn.c.
7893 (emit_b, emit_bcond, emit_cb, emit_tb): Remove.
7894 (emit_load_store): Move to arch/aarch64-insn.c.
7895 (emit_ldr, emit_ldrb, emit_ldrsw, emit_nop): Remove.
7896 (can_encode_int32): Remove.
7897
7898 2015-10-12 Yao Qi <yao.qi@linaro.org>
7899
7900 * linux-aarch64-low.c (extract_signed_bitfield): Remove.
7901 (aarch64_decode_ldr_literal): Move to gdb/arch/aarch64-insn.c.
7902 (aarch64_relocate_instruction): Likewise.
7903 (struct aarch64_insn_data): Move to gdb/arch/aarch64-insn.h.
7904 (struct aarch64_insn_visitor): Likewise.
7905
7906 2015-10-12 Yao Qi <yao.qi@linaro.org>
7907
7908 * linux-aarch64-low.c (struct aarch64_insn_data): New.
7909 (struct aarch64_insn_visitor): New.
7910 (struct aarch64_insn_relocation_data): New.
7911 (aarch64_ftrace_insn_reloc_b): New function.
7912 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
7913 (aarch64_ftrace_insn_reloc_cb): Likewise.
7914 (aarch64_ftrace_insn_reloc_tb): Likewise.
7915 (aarch64_ftrace_insn_reloc_adr): Likewise.
7916 (aarch64_ftrace_insn_reloc_ldr_literal): Likewise.
7917 (aarch64_ftrace_insn_reloc_others): Likewise.
7918 (visitor): New.
7919 (aarch64_relocate_instruction): Use visitor.
7920
7921 2015-10-12 Yao Qi <yao.qi@linaro.org>
7922
7923 * linux-aarch64-low.c (aarch64_relocate_instruction): Return
7924 int. Add argument buf.
7925 (aarch64_install_fast_tracepoint_jump_pad): Pass buf to
7926 aarch64_relocate_instruction.
7927
7928 2015-10-12 Yao Qi <yao.qi@linaro.org>
7929
7930 * linux-aarch64-low.c (aarch64_relocate_instruction): Add
7931 argument insn. Remove local variable insn. Don't call
7932 target_read_uint32.
7933 (aarch64_install_fast_tracepoint_jump_pad): Call
7934 target_read_uint32.
7935
7936 2015-09-30 Yao Qi <yao.qi@linaro.org>
7937
7938 * linux-aarch64-low.c (emit_movk): Shorten a long line.
7939 (emit_load_store_pair): Likewise.
7940
7941 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
7942
7943 * dll.c (match_dll): Add cast(s).
7944 (unloaded_dll): Likewise.
7945 * linux-low.c (second_thread_of_pid_p): Likewise.
7946 (delete_lwp_callback): Likewise.
7947 (count_events_callback): Likewise.
7948 (select_event_lwp_callback): Likewise.
7949 (linux_set_resume_request): Likewise.
7950 * server.c (accumulate_file_name_length): Likewise.
7951 (emit_dll_description): Likewise.
7952 (handle_qxfer_threads_worker): Likewise.
7953 (visit_actioned_threads): Likewise.
7954 * thread-db.c (any_thread_of): Likewise.
7955 * tracepoint.c (same_process_p): Likewise.
7956 (match_blocktype): Likewise.
7957 (build_traceframe_info_xml): Likewise.
7958
7959 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
7960
7961 * ax.c (gdb_parse_agent_expr): Add cast to allocation result
7962 assignment.
7963 (gdb_unparse_agent_expr): Likewise.
7964 * hostio.c (require_data): Likewise.
7965 (handle_pread): Likewise.
7966 * linux-low.c (disable_regset): Likewise.
7967 (fetch_register): Likewise.
7968 (store_register): Likewise.
7969 (get_dynamic): Likewise.
7970 (linux_qxfer_libraries_svr4): Likewise.
7971 * mem-break.c (delete_fast_tracepoint_jump): Likewise.
7972 (set_fast_tracepoint_jump): Likewise.
7973 (uninsert_fast_tracepoint_jumps_at): Likewise.
7974 (reinsert_fast_tracepoint_jumps_at): Likewise.
7975 (validate_inserted_breakpoint): Likewise.
7976 (clone_agent_expr): Likewise.
7977 * regcache.c (init_register_cache): Likewise.
7978 * remote-utils.c (putpkt_binary_1): Likewise.
7979 (decode_M_packet): Likewise.
7980 (decode_X_packet): Likewise.
7981 (look_up_one_symbol): Likewise.
7982 (relocate_instruction): Likewise.
7983 (monitor_output): Likewise.
7984 * server.c (handle_search_memory): Likewise.
7985 (handle_qxfer_exec_file): Likewise.
7986 (handle_qxfer_libraries): Likewise.
7987 (handle_qxfer): Likewise.
7988 (handle_query): Likewise.
7989 (handle_v_cont): Likewise.
7990 (handle_v_run): Likewise.
7991 (captured_main): Likewise.
7992 * target.c (write_inferior_memory): Likewise.
7993 * thread-db.c (try_thread_db_load_from_dir): Likewise.
7994 * tracepoint.c (init_trace_buffer): Likewise.
7995 (add_tracepoint_action): Likewise.
7996 (add_traceframe): Likewise.
7997 (add_traceframe_block): Likewise.
7998 (cmd_qtdpsrc): Likewise.
7999 (cmd_qtdv): Likewise.
8000 (cmd_qtstatus): Likewise.
8001 (response_source): Likewise.
8002 (response_tsv): Likewise.
8003 (cmd_qtnotes): Likewise.
8004 (gdb_collect): Likewise.
8005 (initialize_tracepoint): Likewise.
8006
8007 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
8008
8009 * linux-aarch64-low-.c: Include ax.h and tracepoint.h.
8010 (enum aarch64_opcodes) <RET>, <SUBS>, <AND>, <ORR>, <ORN>,
8011 <EOR>, <LSLV>, <LSRV>, <ASRV>, <SBFM>, <UBFM>, <CSINC>, <MUL>,
8012 <NOP>: New.
8013 (enum aarch64_condition_codes): New enum.
8014 (w0): New static global.
8015 (fp): Likewise.
8016 (lr): Likewise.
8017 (struct aarch64_memory_operand) <type>: New
8018 MEMORY_OPERAND_POSTINDEX type.
8019 (postindex_memory_operand): New helper function.
8020 (emit_ret): New function.
8021 (emit_load_store_pair): New function, factored out of emit_stp
8022 with support for MEMORY_OPERAND_POSTINDEX.
8023 (emit_stp): Rewrite using emit_load_store_pair.
8024 (emit_ldp): New function.
8025 (emit_load_store): Likewise.
8026 (emit_ldr): Mention post-index instruction in comment.
8027 (emit_ldrh): New function.
8028 (emit_ldrb): New function.
8029 (emit_ldrsw): Mention post-index instruction in comment.
8030 (emit_str): Likewise.
8031 (emit_subs): New function.
8032 (emit_cmp): Likewise.
8033 (emit_and): Likewise.
8034 (emit_orr): Likewise.
8035 (emit_orn): Likewise.
8036 (emit_eor): Likewise.
8037 (emit_mvn): Likewise.
8038 (emit_lslv): Likewise.
8039 (emit_lsrv): Likewise.
8040 (emit_asrv): Likewise.
8041 (emit_mul): Likewise.
8042 (emit_sbfm): Likewise.
8043 (emit_sbfx): Likewise.
8044 (emit_ubfm): Likewise.
8045 (emit_ubfx): Likewise.
8046 (emit_csinc): Likewise.
8047 (emit_cset): Likewise.
8048 (emit_nop): Likewise.
8049 (emit_ops_insns): New helper function.
8050 (emit_pop): Likewise.
8051 (emit_push): Likewise.
8052 (aarch64_emit_prologue): New function.
8053 (aarch64_emit_epilogue): Likewise.
8054 (aarch64_emit_add): Likewise.
8055 (aarch64_emit_sub): Likewise.
8056 (aarch64_emit_mul): Likewise.
8057 (aarch64_emit_lsh): Likewise.
8058 (aarch64_emit_rsh_signed): Likewise.
8059 (aarch64_emit_rsh_unsigned): Likewise.
8060 (aarch64_emit_ext): Likewise.
8061 (aarch64_emit_log_not): Likewise.
8062 (aarch64_emit_bit_and): Likewise.
8063 (aarch64_emit_bit_or): Likewise.
8064 (aarch64_emit_bit_xor): Likewise.
8065 (aarch64_emit_bit_not): Likewise.
8066 (aarch64_emit_equal): Likewise.
8067 (aarch64_emit_less_signed): Likewise.
8068 (aarch64_emit_less_unsigned): Likewise.
8069 (aarch64_emit_ref): Likewise.
8070 (aarch64_emit_if_goto): Likewise.
8071 (aarch64_emit_goto): Likewise.
8072 (aarch64_write_goto_address): Likewise.
8073 (aarch64_emit_const): Likewise.
8074 (aarch64_emit_call): Likewise.
8075 (aarch64_emit_reg): Likewise.
8076 (aarch64_emit_pop): Likewise.
8077 (aarch64_emit_stack_flush): Likewise.
8078 (aarch64_emit_zero_ext): Likewise.
8079 (aarch64_emit_swap): Likewise.
8080 (aarch64_emit_stack_adjust): Likewise.
8081 (aarch64_emit_int_call_1): Likewise.
8082 (aarch64_emit_void_call_2): Likewise.
8083 (aarch64_emit_eq_goto): Likewise.
8084 (aarch64_emit_ne_goto): Likewise.
8085 (aarch64_emit_lt_goto): Likewise.
8086 (aarch64_emit_le_goto): Likewise.
8087 (aarch64_emit_gt_goto): Likewise.
8088 (aarch64_emit_ge_got): Likewise.
8089 (aarch64_emit_ops_impl): New static global variable.
8090 (aarch64_emit_ops): New target function, return
8091 &aarch64_emit_ops_impl.
8092 (struct linux_target_ops): Install it.
8093
8094 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
8095
8096 * Makefile.in (linux-aarch64-ipa.o, aarch64-ipa.o): New rules.
8097 * configure.srv (aarch64*-*-linux*): Add linux-aarch64-ipa.o and
8098 aarch64-ipa.o.
8099 * linux-aarch64-ipa.c: New file.
8100 * linux-aarch64-low.c: Include arch/aarch64-insn.h, inttypes.h
8101 and endian.h.
8102 (aarch64_get_thread_area): New target method.
8103 (extract_signed_bitfield): New helper function.
8104 (aarch64_decode_ldr_literal): New function.
8105 (enum aarch64_opcodes): New enum.
8106 (struct aarch64_register): New struct.
8107 (struct aarch64_operand): New struct.
8108 (x0): New static global.
8109 (x1): Likewise.
8110 (x2): Likewise.
8111 (x3): Likewise.
8112 (x4): Likewise.
8113 (w2): Likewise.
8114 (ip0): Likewise.
8115 (sp): Likewise.
8116 (xzr): Likewise.
8117 (aarch64_register): New helper function.
8118 (register_operand): Likewise.
8119 (immediate_operand): Likewise.
8120 (struct aarch64_memory_operand): New struct.
8121 (offset_memory_operand): New helper function.
8122 (preindex_memory_operand): Likewise.
8123 (enum aarch64_system_control_registers): New enum.
8124 (ENCODE): New macro.
8125 (emit_insn): New helper function.
8126 (emit_b): New function.
8127 (emit_bcond): Likewise.
8128 (emit_cb): Likewise.
8129 (emit_tb): Likewise.
8130 (emit_blr): Likewise.
8131 (emit_stp): Likewise.
8132 (emit_ldp_q_offset): Likewise.
8133 (emit_stp_q_offset): Likewise.
8134 (emit_load_store): Likewise.
8135 (emit_ldr): Likewise.
8136 (emit_ldrsw): Likewise.
8137 (emit_str): Likewise.
8138 (emit_ldaxr): Likewise.
8139 (emit_stxr): Likewise.
8140 (emit_stlr): Likewise.
8141 (emit_data_processing_reg): Likewise.
8142 (emit_data_processing): Likewise.
8143 (emit_add): Likewise.
8144 (emit_sub): Likewise.
8145 (emit_mov): Likewise.
8146 (emit_movk): Likewise.
8147 (emit_mov_addr): Likewise.
8148 (emit_mrs): Likewise.
8149 (emit_msr): Likewise.
8150 (emit_sevl): Likewise.
8151 (emit_wfe): Likewise.
8152 (append_insns): Likewise.
8153 (can_encode_int32_in): New helper function.
8154 (aarch64_relocate_instruction): New function.
8155 (aarch64_install_fast_tracepoint_jump_pad): Likewise.
8156 (aarch64_get_min_fast_tracepoint_insn_len): Likewise.
8157 (struct linux_target_ops): Install aarch64_get_thread_area,
8158 aarch64_install_fast_tracepoint_jump_pad and
8159 aarch64_get_min_fast_tracepoint_insn_len.
8160
8161 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
8162
8163 * Makefile.in (aarch64-insn.o): New rule.
8164 * configure.srv (aarch64*-*-linux*): Add aarch64-insn.o.
8165
8166 2015-09-21 Yao Qi <yao.qi@linaro.org>
8167
8168 * ax.c [!IN_PROCESS_AGENT] (gdb_agent_op_sizes): Define it.
8169
8170 2015-09-21 Yao Qi <yao.qi@linaro.org>
8171
8172 * tracepoint.c (max_jump_pad_size): Remove.
8173
8174 2015-09-18 Yao Qi <yao.qi@linaro.org>
8175
8176 * linux-aarch64-low.c: Don't include sys/uio.h.
8177 (ps_get_thread_area): Call aarch64_ps_get_thread_area.
8178
8179 2015-09-16 Wei-cheng Wang <cole945@gmail.com>
8180
8181 * tracepoint.c (eval_result_type): Change prototype.
8182 (condition_true_at_tracepoint): Fix argument to compiled_cond.
8183
8184 2015-09-15 Pedro Alves <palves@redhat.com>
8185
8186 * remote-utils.c (prepare_resume_reply) <TARGET_WAITKIND_EXECD>:
8187 Check whether to report exec events instead of checking whether
8188 multiprocess is enabled.
8189
8190 2015-09-15 Pedro Alves <palves@redhat.com>
8191
8192 PR remote/18965
8193 * remote-utils.c (prepare_resume_reply): Merge
8194 TARGET_WAITKIND_VFORK_DONE switch case with the
8195 TARGET_WAITKIND_FORKED case.
8196
8197 2015-09-15 Yao Qi <yao.qi@linaro.org>
8198
8199 * server.c (handle_query): Check string comparison using
8200 "else if" instead of "if".
8201
8202 2015-09-15 Yao Qi <yao.qi@linaro.org>
8203
8204 * server.c (vCont_supported): New global variable.
8205 (handle_query): Set vCont_supported to 1 if "vContSupported+"
8206 matches. Append ";vContSupported+" to own_buf.
8207 (handle_v_requests): Append ";s;S" to own_buf if target supports
8208 hardware single step or vCont_supported is false.
8209 (capture_main): Set vCont_supported to zero.
8210
8211 2015-09-15 Yao Qi <yao.qi@linaro.org>
8212
8213 * linux-low.c (linux_supports_conditional_breakpoints): Rename
8214 it to ...
8215 (linux_supports_hardware_single_step): ... New function.
8216 (linux_target_ops): Update.
8217 * lynx-low.c (lynx_target_ops): Set field
8218 supports_hardware_single_step to target_can_do_hardware_single_step.
8219 * nto-low.c (nto_target_ops): Likewise.
8220 * spu-low.c (spu_target_ops): Likewise.
8221 * win32-low.c (win32_target_ops): Likewise.
8222 * target.c (target_can_do_hardware_single_step): New function.
8223 * target.h (struct target_ops) <supports_conditional_breakpoints>:
8224 Remove. <supports_hardware_single_step>: New field.
8225 (target_supports_conditional_breakpoints): Remove.
8226 (target_supports_hardware_single_step): New macro.
8227 (target_can_do_hardware_single_step): Declare.
8228 * server.c (handle_query): Use target_supports_hardware_single_step
8229 instead of target_supports_conditional_breakpoints.
8230
8231 2015-09-15 Yao Qi <yao.qi@linaro.org>
8232
8233 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): New
8234 function.
8235 (struct linux_target_ops the_low_target): Install
8236 aarch64_linux_siginfo_fixup.
8237
8238 2015-09-11 Don Breazeal <donb@codesourcery.com>
8239 Luis Machado <lgustavo@codesourcery.com>
8240
8241 * linux-low.c (linux_mourn): Static declaration.
8242 (linux_arch_setup): Move in front of
8243 handle_extended_wait.
8244 (linux_arch_setup_thread): New function.
8245 (handle_extended_wait): Handle exec events. Call
8246 linux_arch_setup_thread. Make event_lwp argument a
8247 pointer-to-a-pointer.
8248 (check_zombie_leaders): Do not check stopped threads.
8249 (linux_low_ptrace_options): Add PTRACE_O_TRACEEXEC.
8250 (linux_low_filter_event): Add lwp and thread for exec'ing
8251 non-leader thread if leader thread has been deleted.
8252 Refactor code into linux_arch_setup_thread and call it.
8253 Pass child lwp pointer by reference to handle_extended_wait.
8254 (linux_wait_for_event_filtered): Update comment.
8255 (linux_wait_1): Prevent clobbering exec event status.
8256 (linux_supports_exec_events): New function.
8257 (linux_target_ops) <supports_exec_events>: Initialize new member.
8258 * lynx-low.c (lynx_target_ops) <supports_exec_events>: Initialize
8259 new member.
8260 * remote-utils.c (prepare_resume_reply): New stop reason 'exec'.
8261 * server.c (report_exec_events): New global variable.
8262 (handle_query): Handle qSupported query for exec-events feature.
8263 (captured_main): Initialize report_exec_events.
8264 * server.h (report_exec_events): Declare new global variable.
8265 * target.h (struct target_ops) <supports_exec_events>: New
8266 member.
8267 (target_supports_exec_events): New macro.
8268 * win32-low.c (win32_target_ops) <supports_exec_events>:
8269 Initialize new member.
8270
8271 2015-09-09 Markus Metzger <markus.t.metzger@intel.com>
8272
8273 * linux-low.c (linux_low_enable_btrace): Remove.
8274 (linux_target_ops): Replace linux_low_enable_btrace with
8275 linux_enable_btrace.
8276
8277 2015-09-03 Yao Qi <yao.qi@linaro.org>
8278
8279 * linux-aarch64-low.c (aarch64_insert_point): Call
8280 aarch64_handle_watchpoint if aarch64_linux_region_ok_for_watchpoint
8281 returns true.
8282
8283 2015-08-27 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
8284
8285 * linux-low.c (check_stopped_by_breakpoint): Use
8286 GDB_ARCH_IS_TRAP_BRKPT instead of GDB_ARCH_TRAP_BRKPT.
8287
8288 2015-08-27 Pedro Alves <palves@redhat.com>
8289
8290 * proc-service.c (ps_pdwrite): Return PS_ERR/PS_OK explicily.
8291
8292 2015-08-26 Simon Marchi <simon.marchi@ericsson.com>
8293
8294 * ax.c (gdb_parse_agent_expr): Replace xmalloc-family function with
8295 the XNEW-family equivalent.
8296 (compile_bytecodes): Likewise.
8297 * dll.c (loaded_dll): Likewise.
8298 * event-loop.c (append_callback_event): Likewise.
8299 (create_file_handler): Likewise.
8300 (create_file_event): Likewise.
8301 * hostio.c (handle_open): Likewise.
8302 * inferiors.c (add_thread): Likewise.
8303 (add_process): Likewise.
8304 * linux-aarch64-low.c (aarch64_linux_new_process): Likewise.
8305 * linux-arm-low.c (arm_new_process): Likewise.
8306 (arm_new_thread): Likewise.
8307 * linux-low.c (add_to_pid_list): Likewise.
8308 (linux_add_process): Likewise.
8309 (handle_extended_wait): Likewise.
8310 (add_lwp): Likewise.
8311 (enqueue_one_deferred_signal): Likewise.
8312 (enqueue_pending_signal): Likewise.
8313 (linux_resume_one_lwp_throw): Likewise.
8314 (linux_resume_one_thread): Likewise.
8315 (linux_read_memory): Likewise.
8316 (linux_write_memory): Likewise.
8317 * linux-mips-low.c (mips_linux_new_process): Likewise.
8318 (mips_linux_new_thread): Likewise.
8319 (mips_add_watchpoint): Likewise.
8320 * linux-x86-low.c (initialize_low_arch): Likewise.
8321 * lynx-low.c (lynx_add_process): Likewise.
8322 * mem-break.c (set_raw_breakpoint_at): Likewise.
8323 (set_breakpoint): Likewise.
8324 (add_condition_to_breakpoint): Likewise.
8325 (add_commands_to_breakpoint): Likewise.
8326 (clone_agent_expr): Likewise.
8327 (clone_one_breakpoint): Likewise.
8328 * regcache.c (new_register_cache): Likewise.
8329 * remote-utils.c (look_up_one_symbol): Likewise.
8330 * server.c (queue_stop_reply): Likewise.
8331 (start_inferior): Likewise.
8332 (queue_stop_reply_callback): Likewise.
8333 (handle_target_event): Likewise.
8334 * spu-low.c (fetch_ppc_memory): Likewise.
8335 (store_ppc_memory): Likewise.
8336 * target.c (set_target_ops): Likewise.
8337 * thread-db.c (thread_db_load_search): Likewise.
8338 (try_thread_db_load_1): Likewise.
8339 * tracepoint.c (add_tracepoint): Likewise.
8340 (add_tracepoint_action): Likewise.
8341 (create_trace_state_variable): Likewise.
8342 (cmd_qtdpsrc): Likewise.
8343 (cmd_qtro): Likewise.
8344 (add_while_stepping_state): Likewise.
8345 * win32-low.c (child_add_thread): Likewise.
8346 (get_image_name): Likewise.
8347
8348 2015-08-25 Yao Qi <yao.qi@linaro.org>
8349
8350 * linux-aarch64-low.c (aarch64_linux_new_thread): Remove.
8351
8352 2015-08-25 Yao Qi <yao.qi@linaro.org>
8353
8354 * Makefile.in (aarch64-linux.o): New rule.
8355 * configure.srv (aarch64*-*-linux*): Append aarch64-linux.o to
8356 srv_tgtobj.
8357 * linux-aarch64-low.c: Include nat/aarch64-linux.h.
8358 (aarch64_init_debug_reg_state): Make it extern.
8359 (aarch64_linux_prepare_to_resume): Remove.
8360
8361 2015-08-25 Yao Qi <yao.qi@linaro.org>
8362
8363 * linux-aarch64-low.c (aarch64_linux_prepare_to_resume): Use
8364 lwp_arch_private_info and ptid_of_lwp.
8365
8366 2015-08-25 Yao Qi <yao.qi@linaro.org>
8367
8368 * linux-aarch64-low.c (aarch64_get_debug_reg_state): Add argument pid.
8369 Find proc_info by find_process_pid. All callers updated.
8370
8371 2015-08-25 Yao Qi <yao.qi@linaro.org>
8372
8373 * linux-aarch64-low.c (struct arch64_dr_update_callback_param):
8374 Remove.
8375 (debug_reg_change_callback): Remove.
8376 (aarch64_notify_debug_reg_change): Remove.
8377
8378 2015-08-25 Yao Qi <yao.qi@linaro.org>
8379
8380 * linux-aarch64-low.c (aarch64_notify_debug_reg_change):
8381 Call current_lwp_ptid.
8382
8383 2015-08-25 Yao Qi <yao.qi@linaro.org>
8384
8385 * linux-aarch64-low.c (debug_reg_change_callback): Use
8386 debug_printf.
8387
8388 2015-08-25 Yao Qi <yao.qi@linaro.org>
8389
8390 * linux-aarch64-low.c (debug_reg_change_callback): Use phex.
8391
8392 2015-08-25 Yao Qi <yao.qi@linaro.org>
8393
8394 * linux-aarch64-low.c (debug_reg_change_callback): Remove comments.
8395
8396 2015-08-25 Yao Qi <yao.qi@linaro.org>
8397
8398 * linux-aarch64-low.c (debug_reg_change_callback): Re-indent
8399 the code.
8400
8401 2015-08-25 Yao Qi <yao.qi@linaro.org>
8402
8403 * linux-aarch64-low.c (aarch64_dr_update_callback_param) <pid>:
8404 Remove.
8405 (debug_reg_change_callback): Remove argument entry and add argument
8406 lwp. Remove local variable thread. Don't print thread id in the
8407 debugging output. Don't check whether pid of thread equals to pid.
8408 (aarch64_notify_debug_reg_change): Don't set param.pid. Call
8409 iterate_over_lwps instead find_inferior.
8410
8411 2015-08-24 Pedro Alves <palves@redhat.com>
8412
8413 * inferiors.c (get_first_process): New function.
8414 * inferiors.h (get_first_process): New declaration.
8415 * remote-utils.c (read_ptid): Default to the first process in the
8416 list, instead of to the current thread's process.
8417
8418 2015-08-24 Pedro Alves <palves@redhat.com>
8419
8420 * debug.c: Include gdb_sys_time.h instead of sys/time.h.
8421 * event-loop.c: Likewise.
8422 * remote-utils.c: Likewise.
8423 * tracepoint.c: Likewise.
8424
8425 2015-08-24 Pedro Alves <palves@redhat.com>
8426
8427 * spu-low.c (spu_request_interrupt): Use lwpid_of instead of
8428 ptid_get_lwp.
8429
8430 2015-08-21 Pedro Alves <palves@redhat.com>
8431
8432 * ax.c (gdb_eval_agent_expr): Return expr_eval_unhandled_opcode
8433 instead of literal 1.
8434
8435 2015-08-21 Pedro Alves <palves@redhat.com>
8436
8437 * tdesc.c (default_description): Explicitly zero-initialize.
8438
8439 2015-08-21 Pedro Alves <palves@redhat.com>
8440
8441 PR gdb/18749
8442 * inferiors.c (remove_thread): Discard any pending stop reply for
8443 this thread.
8444 * server.c (remove_all_on_match_pid): Rename to ...
8445 (remove_all_on_match_ptid): ... this. Work with a filter ptid
8446 instead of a pid.
8447 (discard_queued_stop_replies): Change parameter to a ptid. Now
8448 extern.
8449 (handle_v_kill, kill_inferior_callback, captured_main)
8450 (process_serial_event): Adjust.
8451 * server.h (discard_queued_stop_replies): Declare.
8452
8453 2015-08-21 Pedro Alves <palves@redhat.com>
8454
8455 * linux-low.c (wait_for_sigstop): Always switch to no thread
8456 selected if the previously current thread dies.
8457 * lynx-low.c (lynx_request_interrupt): Use the first thread's
8458 process instead of the current thread's.
8459 * remote-utils.c (input_interrupt): Don't check if there's no
8460 current thread.
8461 * server.c (gdb_read_memory, gdb_write_memory): If setting the
8462 current thread to the general thread fails, error out.
8463 (handle_qxfer_auxv, handle_qxfer_libraries)
8464 (handle_qxfer_libraries_svr4, handle_qxfer_siginfo)
8465 (handle_qxfer_spu, handle_qxfer_statictrace, handle_qxfer_fdpic)
8466 (handle_query): Check if there's a thread selected instead of
8467 checking whether there's any thread in the thread list.
8468 (handle_qxfer_threads, handle_qxfer_btrace)
8469 (handle_qxfer_btrace_conf): Don't error out early if there's no
8470 thread in the thread list.
8471 (handle_v_cont, myresume): Don't set the current thread to the
8472 continue thread.
8473 (process_serial_event) <Hg handling>: Also set thread_id if the
8474 previous general thread is still alive.
8475 (process_serial_event) <g/G handling>: If setting the current
8476 thread to the general thread fails, error out.
8477 * spu-low.c (spu_resume, spu_request_interrupt): Use the first
8478 thread's lwp instead of the current thread's.
8479 * target.c (set_desired_thread): If the desired thread was not
8480 found, leave the current thread pointing to NULL. Return an int
8481 (boolean) indicating success.
8482 * target.h (set_desired_thread): Change return type to int.
8483
8484 2015-08-20 Max Filippov <jcmvbkbc@gmail.com>
8485
8486 * configure.srv (xtensa*-*-linux*): Add srv_linux_thread_db=yes.
8487 * linux-xtensa-low.c (arch/xtensa.h gdb_proc_service.h): New
8488 #includes.
8489 (ps_get_thread_area): New function.
8490
8491 2015-08-19 Gary Benson <gbenson@redhat.com>
8492
8493 * hostio.c (handle_pread): Do not attempt to read more data
8494 than hostio_reply_with_data can fit in a packet.
8495
8496 2015-08-18 Joel Brobecker <brobecker@adacore.com>
8497
8498 * linux-aarch32-low.c (NT_ARM_VFP): Define if not already defined.
8499
8500 2015-08-14 Matthew Fortune <matthew.fortune@imgtec.com>
8501
8502 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP_REL.
8503
8504 2015-08-06 Pedro Alves <palves@redhat.com>
8505
8506 * tracepoint.c (expr_eval_result): Now an int.
8507
8508 2015-08-06 Pedro Alves <palves@redhat.com>
8509
8510 * gdbthread.h (struct regcache): Forward declare.
8511 (struct thread_info) <regcache_data>: Now a struct regcache
8512 pointer.
8513 * inferiors.c (inferior_regcache_data)
8514 (set_inferior_regcache_data): Now work with struct regcache
8515 pointers.
8516 * inferiors.h (struct regcache): Forward declare.
8517 (inferior_regcache_data, set_inferior_regcache_data): Now work
8518 with struct regcache pointers.
8519 * regcache.c (get_thread_regcache, regcache_invalidate_thread)
8520 (free_register_cache_thread): Remove struct regcache pointer
8521 casts.
8522
8523 2015-08-06 Pedro Alves <palves@redhat.com>
8524
8525 * server.c (captured_main): On error, print the exception message
8526 to stderr, and if run_once is set, throw a quit.
8527
8528 2015-08-06 Pedro Alves <palves@redhat.com>
8529
8530 * linux-low.c (move_out_of_jump_pad_callback): Temporarily switch
8531 the current thread.
8532
8533 2015-08-06 Pedro Alves <palves@redhat.com>
8534
8535 * linux-low.c (linux_write_memory): Rewrite debug output to avoid
8536 reading beyond the passed in buffer length.
8537
8538 2015-08-06 Pierre Langlois <pierre.langlois@arm.com>
8539
8540 * tracepoint.c (symbol_list) <required>: Remove.
8541
8542 2015-08-06 Pedro Alves <palves@redhat.com>
8543
8544 * linux-low.c (handle_extended_wait): Set the fork child's suspend
8545 count if stopping and suspending threads.
8546 (check_stopped_by_breakpoint): If stopped by trace, set the LWP's
8547 stop reason to TARGET_STOPPED_BY_SINGLE_STEP.
8548 (linux_detach): Complete an ongoing step-over.
8549 (lwp_suspended_inc, lwp_suspended_decr): New functions. Use
8550 throughout.
8551 (resume_stopped_resumed_lwps): Don't resume a suspended thread.
8552 (linux_wait_1): If passing a signal to the inferior after
8553 finishing a step-over, unsuspend and re-resume all lwps. If we
8554 see a single-step event but the thread should be continuing, don't
8555 pass the trap to gdb.
8556 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback): Use
8557 internal_error instead of gdb_assert.
8558 (enqueue_pending_signal): New function.
8559 (check_ptrace_stopped_lwp_gone): Add debug output.
8560 (start_step_over): Use internal_error instead of gdb_assert.
8561 (complete_ongoing_step_over): New function.
8562 (linux_resume_one_thread): Don't resume a suspended thread.
8563 (proceed_one_lwp): If the LWP is stepping over a breakpoint, reset
8564 it stepping.
8565
8566 2015-08-06 Pedro Alves <palves@redhat.com>
8567
8568 * linux-low.c (add_lwp): Set waitstatus to TARGET_WAITKIND_IGNORE.
8569 (linux_thread_alive): Use lwp_is_marked_dead.
8570 (extended_event_reported): Delete.
8571 (linux_wait_1): Check if waitstatus is TARGET_WAITKIND_IGNORE
8572 instead of extended_event_reported.
8573 (mark_lwp_dead): Don't set the 'dead' flag. Store the waitstatus
8574 as well.
8575 (lwp_is_marked_dead): New function.
8576 (lwp_running): Use lwp_is_marked_dead.
8577 * linux-low.h: Delete 'dead' field, and update 'waitstatus's
8578 comment.
8579
8580 2015-08-06 Pedro Alves <palves@redhat.com>
8581
8582 * linux-low.c (linux_wait_1): Move fork event output out of the
8583 !report_to_gdb check. Pass event_child->waitstatus to
8584 target_waitstatus_to_string instead of ourstatus.
8585
8586 2015-08-04 Yao Qi <yao.qi@linaro.org>
8587
8588 * linux-aarch64-low.c (aarch64_supports_tracepoints): Return 0
8589 if current_thread is 32 bit.
8590
8591 2015-08-04 Yao Qi <yao.qi@linaro.org>
8592
8593 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
8594 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
8595 * server.c (extended_protocol): Remove "static".
8596 * server.h (extended_protocol): Declare it.
8597
8598 2015-08-04 Yao Qi <yao.qi@linaro.org>
8599
8600 * linux-aarch64-low.c (aarch64_get_pc): Get PC register on
8601 both aarch64 and aarch32.
8602 (aarch64_set_pc): Likewise.
8603
8604 2015-08-04 Yao Qi <yao.qi@linaro.org>
8605
8606 * configure.srv (case aarch64*-*-linux*): Append arm-with-neon.o
8607 to srv_regobj and append arm-core.xml arm-vfpv3.xml and
8608 arm-with-neon.xml to srv_xmlfiles.
8609 * linux-aarch64-low.c: Include linux-aarch32-low.h.
8610 (is_64bit_tdesc): New function.
8611 (aarch64_linux_read_description): New function.
8612 (aarch64_arch_setup): Call aarch64_linux_read_description.
8613 (regs_info): Rename to regs_info_aarch64.
8614 (aarch64_regs_info): Return right regs_info.
8615 (initialize_low_arch): Call initialize_low_arch_aarch32.
8616
8617 2015-08-04 Yao Qi <yao.qi@linaro.org>
8618
8619 * configure.srv (srv_tgtobj): Add linux-aarch32-low.o.
8620 * linux-aarch32-low.c: New file.
8621 * linux-aarch32-low.h: New file.
8622 * linux-arm-low.c (arm_fill_gregset): Move it to
8623 linux-aarch32-low.c.
8624 (arm_store_gregset): Likewise.
8625 (arm_fill_vfpregset): Call arm_fill_vfpregset_num
8626 (arm_store_vfpregset): Call arm_store_vfpregset_num.
8627 (arm_arch_setup): Check if PTRACE_GETREGSET works.
8628 (regs_info): Rename to regs_info_arm.
8629 (arm_regs_info): Return regs_info_aarch32 if
8630 have_ptrace_getregset is 1 and target description is
8631 arm_with_neon or arm_with_vfpv3.
8632 (initialize_low_arch): Don't call init_registers_arm_with_neon.
8633 Call initialize_low_arch_aarch32 instead.
8634
8635 2015-08-04 Yao Qi <yao.qi@linaro.org>
8636
8637 * linux-x86-low.c (have_ptrace_getregset): Move it to ...
8638 * linux-low.c: ... here.
8639 * linux-low.h (have_ptrace_getregset): Declare it.
8640
8641 2015-08-04 Pedro Alves <palves@redhat.com>
8642
8643 * thread-db.c (struct thread_db): Use new typedefs.
8644 (try_thread_db_load_1): Define local TDB_DLSYM macro and use it in
8645 CHK calls.
8646 (disable_thread_event_reporting): Cast result of dlsym to
8647 destination function pointer type.
8648 (thread_db_mourn): Use td_ta_delete_ftype.
8649
8650 2015-08-03 Sandra Loosemore <sandra@codesourcery.com>
8651
8652 * linux-nios2-low.c (NIOS2_BREAKPOINT): Conditionalize for
8653 arch variant.
8654 (CDX_BREAKPOINT): Define for R2.
8655 (nios2_breakpoint_at): Check for CDX_BREAKPOINT when R2.
8656 (the_low_target): Add comments.
8657
8658 2015-07-30 Yao Qi <yao.qi@linaro.org>
8659
8660 * linux-arm-low.c (arm_hwcap): Remove it.
8661 (arm_read_description): New local variable arm_hwcap. Don't
8662 set arm_hwcap to zero.
8663
8664 2015-07-30 Yao Qi <yao.qi@linaro.org>
8665
8666 * linux-arm-low.c (arm_fill_wmmxregset): Don't use arm_hwcap.
8667 Use regcache->tdesc instead.
8668 (arm_store_wmmxregset): Likewise.
8669 (arm_fill_vfpregset): Likewise.
8670 (arm_store_vfpregset): Likewise.
8671
8672 2015-07-30 Yao Qi <yao.qi@linaro.org>
8673
8674 * linux-arm-low.c: Include arch/arm.h.
8675 (arm_fill_gregset): Don't use arm_num_regs and arm_regmap.
8676 (arm_store_gregset): Likewise.
8677
8678 2015-07-29 Simon Marchi <simon.marchi@ericsson.com>
8679
8680 * linux-mips-low.c (mips_linux_prepare_to_resume): Add NULL as
8681 ptrace's 4th parameter.
8682
8683 2015-07-27 Yao Qi <yao.qi@linaro.org>
8684
8685 * configure.srv (case aarch64*-*-linux*): Don't set
8686 srv_linux_usrregs.
8687
8688 2015-07-24 Pedro Alves <palves@redhat.c: Likewise.om>
8689
8690 * linux-aarch64-low.c: Include nat/gdb_ptrace.h instead of
8691 sys/ptrace.h.
8692 * linux-arm-low.c: Likewise.
8693 * linux-cris-low.c: Likewise.
8694 * linux-crisv32-low.c: Likewise.
8695 * linux-low.c: Likewise.
8696 * linux-m68k-low.c: Likewise.
8697 * linux-mips-low.c: Likewise.
8698 * linux-nios2-low.c: Likewise.
8699 * linux-s390-low.c: Likewise.
8700 * linux-sparc-low.c: Likewise.
8701 * linux-tic6x-low.c: Likewise.
8702 * linux-tile-low.c: Likewise.
8703 * linux-x86-low.c: Likewise.
8704
8705 2015-07-24 Pedro Alves <palves@redhat.com>
8706
8707 * config.in: Regenerate.
8708 * configure: Regenerate.
8709
8710 2015-07-24 Pedro Alves <palves@redhat.com>
8711
8712 * acinclude.m4: Include ../ptrace.m4.
8713 * configure.ac: Call GDB_AC_PTRACE.
8714 * config.in, configure: Regenerate.
8715
8716 2015-07-24 Yao Qi <yao.qi@linaro.org>
8717
8718 * linux-low.c (linux_create_inferior): Remove setting to
8719 proc->priv->new_inferior.
8720 (linux_attach): Likewise.
8721 (linux_low_filter_event): Likewise.
8722 * linux-low.h (struct process_info_private) <new_inferior>: Remove.
8723
8724 2015-07-24 Yao Qi <yao.qi@linaro.org>
8725
8726 * linux-low.c (linux_arch_setup): New function.
8727 (linux_low_filter_event): If proc->tdesc is NULL and
8728 proc->attached is true, call the_low_target.arch_setup.
8729 Otherwise, keep status pending, and return.
8730 (linux_resume_one_lwp_throw): Don't call get_pc if
8731 thread->while_stepping isn't NULL. Don't call
8732 get_thread_regcache if proc->tdesc is NULL.
8733 (need_step_over_p): Return 0 if proc->tdesc is NULL.
8734 (linux_target_ops): Install arch_setup.
8735 * server.c (start_inferior): Call the_target->arch_setup.
8736 * target.h (struct target_ops) <arch_setup>: New field.
8737 (target_arch_setup): New marco.
8738 * lynx-low.c (lynx_target_ops): Update.
8739 * nto-low.c (nto_target_ops): Update.
8740 * spu-low.c (spu_target_ops): Update.
8741 * win32-low.c (win32_target_ops): Update.
8742
8743 2015-07-24 Yao Qi <yao.qi@linaro.org>
8744
8745 * linux-low.c (linux_add_process): Don't set
8746 proc->priv->new_inferior.
8747 (linux_create_inferior): Set proc->priv->new_inferior to 1.
8748 (linux_attach): Likewise.
8749
8750 2015-07-24 Yao Qi <yao.qi@linaro.org>
8751
8752 * server.c (start_inferior): Code refactor.
8753
8754 2015-07-24 Yao Qi <yao.qi@linaro.org>
8755
8756 * server.c (process_serial_event): Set general_thread.
8757
8758 2015-07-21 Yao Qi <yao.qi@linaro.org>
8759
8760 * linux-aarch64-low.c (aarch64_arch_setup): Remove code and call
8761 aarch64_linux_get_debug_reg_capacity.
8762
8763 2015-07-17 Yao Qi <yao.qi@linaro.org>
8764
8765 * Makefile.in (aarch64-linux-hw-point.o): New rule.
8766 * configure.srv (srv_tgtobj): Append aarch64-linux-hw-point.o.
8767 * linux-aarch64-low.c: Include nat/aarch64-linux-hw-point.h.
8768 (AARCH64_HBP_MAX_NUM): Move to nat/aarch64-linux-hw-point.h.
8769 (AARCH64_HWP_MAX_NUM, AARCH64_HBP_ALIGNMENT): Likewise.
8770 (AARCH64_HWP_ALIGNMENT): Likewise.
8771 (AARCH64_HWP_MAX_LEN_PER_REG): Likewise.
8772 (AARCH64_DEBUG_NUM_SLOTS, AARCH64_DEBUG_ARCH): Likewise.
8773 (aarch64_num_bp_regs, aarch64_num_wp_regs): Likewise.
8774 (AARCH64_DEBUG_ARCH_V8, DR_MARK_ALL_CHANGED): Likewise.
8775 (DR_MARK_N_CHANGED, DR_CLEAR_CHANGED): Likewise.
8776 (DR_HAS_CHANGED, DR_N_HAS_CHANGE): Likewise.
8777 (struct aarch64_debug_reg_state): Likewise.
8778 (struct arch_lwp_info): Likewise.
8779 (aarch64_align_watchpoint): Likewise.
8780 (DR_CONTROL_ENABLED, DR_CONTROL_LENGTH): Likewise.
8781 (aarch64_watchpoint_length): Likewise.
8782 (aarch64_point_encode_ctrl_reg): Likewise
8783 (aarch64_point_is_aligned): Likewise.
8784 (aarch64_align_watchpoint): Likewise.
8785 (aarch64_linux_set_debug_regs):
8786 (aarch64_dr_state_insert_one_point): Likewise.
8787 (aarch64_dr_state_remove_one_point): Likewise.
8788 (aarch64_handle_breakpoint): Likewise.
8789 (aarch64_handle_aligned_watchpoint): Likewise.
8790 (aarch64_handle_unaligned_watchpoint): Likewise.
8791 (aarch64_handle_watchpoint): Likewise.
8792
8793 2015-07-17 Yao Qi <yao.qi@linaro.org>
8794
8795 * linux-aarch64-low.c (aarch64_handle_breakpoint): Add argument state
8796 and don't aarch64_get_debug_reg_state. All callers update.
8797 (aarch64_handle_aligned_watchpoint): Likewise.
8798 (aarch64_handle_unaligned_watchpoint): Likewise.
8799 (aarch64_handle_watchpoint): Likewise.
8800 (aarch64_insert_point): Call aarch64_get_debug_reg_state earlier.
8801 (aarch64_remove_point): Likewise.
8802
8803 2015-07-17 Yao Qi <yao.qi@linaro.org>
8804
8805 * linux-aarch64-low.c (aarch64_show_debug_reg_state): Use
8806 debug_printf.
8807 (aarch64_handle_unaligned_watchpoint): Likewise.
8808
8809 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
8810
8811 Revert the previous 3 commits:
8812 Move gdb_regex* to common/
8813 Move linux_find_memory_regions_full & co.
8814 gdbserver build-id attribute generator
8815
8816 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
8817 Jan Kratochvil <jan.kratochvil@redhat.com>
8818
8819 gdbserver build-id attribute generator.
8820 * linux-low.c (nat/linux-maps.h, search.h, rsp-low.h): Include.
8821 (ElfXX_Ehdr, ElfXX_Phdr, ElfXX_Nhdr): New.
8822 (ELFXX_FLD, ELFXX_SIZEOF, ELFXX_ROUNDUP, BUILD_ID_INVALID): New.
8823 (find_phdr): New.
8824 (get_dynamic): Use find_pdhr to traverse program headers.
8825 (struct mapping_entry, mapping_entry_s, free_mapping_entry_vec)
8826 (compare_mapping_entry_range, struct find_memory_region_callback_data)
8827 (read_build_id, find_memory_region_callback, lrfind_mapping_entry)
8828 (get_hex_build_id): New.
8829 (linux_qxfer_libraries_svr4): Add optional build-id attribute
8830 to reply XML document.
8831
8832 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
8833 Jan Kratochvil <jan.kratochvil@redhat.com>
8834
8835 * target.c: Include target/target-utils.h and fcntl.h.
8836 (target_fileio_read_stralloc_1_pread, target_fileio_read_stralloc_1)
8837 (target_fileio_read_stralloc): New functions.
8838
8839 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
8840
8841 * Makefile.in (OBS): Add gdb_regex.o.
8842 (gdb_regex.o): New.
8843 * config.in: Rebuilt.
8844 * configure: Rebuilt.
8845
8846 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
8847 Jan Kratochvil <jan.kratochvil@redhat.com>
8848
8849 Create empty nat/linux-maps.[ch] and common/target-utils.[ch].
8850 * Makefile.in (OBS): Add target-utils.o.
8851 (linux-maps.o, target-utils.o): New.
8852 * configure.srv (srv_linux_obj): Add linux-maps.o.
8853
8854 2015-07-15 Pierre Langlois <pierre.langlois@arm.com>
8855
8856 * linux-aarch64-low.c (aarch64_supports_range_stepping): New
8857 function, return 1.
8858 (the_low_target): Install it.
8859
8860 2015-07-14 Pedro Alves <palves@redhat.com>
8861
8862 * linux-low.c (kill_wait_lwp): Don't assert if waitpid fails.
8863 Instead, ignore ECHILD, and throw an error for other errnos.
8864
8865 2015-07-10 Pedro Alves <palves@redhat.com>
8866
8867 * event-loop.c (struct callback_event) <data>: Change type to
8868 gdb_client_data instance instead of gdb_client_data pointer.
8869 (append_callback_event): Adjust.
8870
8871 2015-07-10 Pierre Langlois <pierre.langlois@arm.com>
8872
8873 * linux-aarch64-low.c: Add comments for each linux_target_ops
8874 method. Remove comments already covered in target_ops and
8875 linux_target_ops definitions.
8876 (the_low_target): Add comments for each unimplemented method.
8877
8878 2015-07-09 Yao Qi <yao.qi@linaro.org>
8879
8880 * linux-aarch64-low.c (aarch64_regmap): Remove.
8881 (aarch64_usrregs_info): Remove.
8882 (regs_info): Set field usrregs to NULL.
8883
8884 2015-07-02 Markus Metzger <markus.t.metzger@intel.com>
8885
8886 * linux-low.c: Include "rsp-low.h"
8887 (linux_low_encode_pt_config, linux_low_encode_raw): New.
8888 (linux_low_read_btrace): Support BTRACE_FORMAT_PT.
8889 (linux_low_btrace_conf): Support BTRACE_FORMAT_PT.
8890 (handle_btrace_enable_pt): New.
8891 (handle_btrace_general_set): Support "pt".
8892 (handle_btrace_conf_general_set): Support "pt:size".
8893
8894 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
8895
8896 * linux-aarch64-low.c (aarch64_supports_z_point_type): Enable for
8897 Z_PACKET_SW_BP.
8898
8899 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
8900
8901 * linux-aarch64-low.c: Remove comment about endianness.
8902 (aarch64_breakpoint): Change type to gdb_byte[]. Set to "brk #0".
8903 (aarch64_breakpoint_at): Change type of insn to gdb_byte[]. Use
8904 memcmp.
8905
8906 2015-06-24 Gary Benson <gbenson@redhat.com>
8907
8908 * linux-i386-ipa.c (stdint.h): Do not include.
8909 * lynx-i386-low.c (stdint.h): Likewise.
8910 * lynx-ppc-low.c (stdint.h): Likewise.
8911 * mem-break.c (stdint.h): Likewise.
8912 * thread-db.c (stdint.h): Likewise.
8913 * tracepoint.c (stdint.h): Likewise.
8914 * win32-low.c (stdint.h): Likewise.
8915
8916 2015-06-18 Simon Marchi <simon.marchi@ericsson.com>
8917
8918 * server.c (write_qxfer_response): Update call to
8919 remote_escape_output.
8920
8921 2015-06-15 Aleksandar Ristovski <aristovski@qnx.com
8922 Jan Kratochvil <jan.kratochvil@redhat.com>
8923
8924 Merge multiple hex conversions.
8925 * gdbreplay.c (tohex): Rename to 'fromhex'.
8926 (logchar): Use fromhex.
8927
8928 2015-06-10 Jan Kratochvil <jan.kratochvil@redhat.com>
8929
8930 * server.c (handle_qxfer_libraries): Set `version' attribute for
8931 <library-list>.
8932
8933 2015-06-10 Gary Benson <gbenson@redhat.com>
8934
8935 * target.h (struct target_ops) <multifs_open>: New field.
8936 <multifs_unlink>: Likewise.
8937 <multifs_readlink>: Likewise.
8938 * linux-low.c (nat/linux-namespaces.h): New include.
8939 (linux_target_ops): Initialize the_target->multifs_open,
8940 the_target->multifs_unlink and the_target->multifs_readlink.
8941 * hostio.h (hostio_handle_new_gdb_connection): New declaration.
8942 * hostio.c (hostio_fs_pid): New static variable.
8943 (hostio_handle_new_gdb_connection): New function.
8944 (handle_setfs): Likewise.
8945 (handle_open): Use the_target->multifs_open as appropriate.
8946 (handle_unlink): Use the_target->multifs_unlink as appropriate.
8947 (handle_readlink): Use the_target->multifs_readlink as
8948 appropriate.
8949 (handle_vFile): Handle vFile:setfs packets.
8950 * server.c (handle_query): Call hostio_handle_new_gdb_connection
8951 after target_handle_new_gdb_connection.
8952
8953 2015-06-10 Gary Benson <gbenson@redhat.com>
8954
8955 * configure.ac (AC_CHECK_FUNCS): Add setns.
8956 * config.in: Regenerate.
8957 * configure: Likewise.
8958 * Makefile.in (SFILES): Add nat/linux-namespaces.c.
8959 (linux-namespaces.o): New rule.
8960 * configure.srv (srv_linux_obj): Add linux-namespaces.o.
8961
8962 2015-06-09 Gary Benson <gbenson@redhat.com>
8963
8964 * hostio.c (handle_open): Process mode argument with
8965 fileio_to_host_mode.
8966
8967 2015-06-01 Yao Qi <yao.qi@linaro.org>
8968
8969 * linux-s390-low.c (PTRACE_GETREGSET, PTRACE_SETREGSET): Remove.
8970 * linux-x86-low.c: Likewise.
8971
8972 2015-05-28 Don Breazeal <donb@codesourcery.com>
8973
8974 * linux-low.c (handle_extended_wait): Initialize
8975 thread_info.last_resume_kind for new fork children.
8976
8977 2015-05-15 Pedro Alves <palves@redhat.com>
8978
8979 * target.h (target_handle_new_gdb_connection): Rewrite using if
8980 wrapped in do/while.
8981
8982 2015-05-14 Joel Brobecker <brobecker@adacore.com>
8983
8984 * configure.ac: Add prfpregset_t BFD_HAVE_SYS_PROCFS_TYPE check.
8985 * configure, config.in: Regenerate.
8986 * gdb_proc_service.h [HAVE_PRFPREGSET_T] (prfpregset_t):
8987 Declare typedef.
8988
8989 2015-05-12 Don Breazeal <donb@codesourcery.com>
8990
8991 * linux-low.c (handle_extended_wait): Handle PTRACE_EVENT_FORK and
8992 PTRACE_EVENT_VFORK_DONE.
8993 (linux_low_ptrace_options, extended_event_reported): Add vfork
8994 events.
8995 * remote-utils.c (prepare_resume_reply): New stop reasons "vfork"
8996 and "vforkdone" for RSP 'T' Stop Reply Packet.
8997 * server.h (report_vfork_events): Declare
8998 global variable.
8999
9000 2015-05-12 Don Breazeal <donb@codesourcery.com>
9001
9002 * linux-aarch64-low.c (aarch64_linux_new_fork): New function.
9003 (the_low_target) <new_fork>: Initialize new member.
9004 * linux-arm-low.c (arm_new_fork): New function.
9005 (the_low_target) <new_fork>: Initialize new member.
9006 * linux-low.c (handle_extended_wait): Call new target function
9007 new_fork.
9008 * linux-low.h (struct linux_target_ops) <new_fork>: New member.
9009 * linux-mips-low.c (mips_add_watchpoint): New function
9010 extracted from mips_insert_point.
9011 (the_low_target) <new_fork>: Initialize new member.
9012 (mips_linux_new_fork): New function.
9013 (mips_insert_point): Call mips_add_watchpoint.
9014 * linux-x86-low.c (x86_linux_new_fork): New function.
9015 (the_low_target) <new_fork>: Initialize new member.
9016
9017 2015-05-12 Don Breazeal <donb@codesourcery.com>
9018
9019 * linux-low.c (handle_extended_wait): Implement return value,
9020 rename argument 'event_child' to 'event_lwp', handle
9021 PTRACE_EVENT_FORK, call internal_error for unrecognized event.
9022 (linux_low_ptrace_options): New function.
9023 (linux_low_filter_event): Call linux_low_ptrace_options,
9024 use different argument fo linux_enable_event_reporting,
9025 use return value from handle_extended_wait.
9026 (extended_event_reported): New function.
9027 (linux_wait_1): Call extended_event_reported and set
9028 status to report fork events.
9029 (linux_write_memory): Add pid to debug message.
9030 (reset_lwp_ptrace_options_callback): New function.
9031 (linux_handle_new_gdb_connection): New function.
9032 (linux_target_ops): Initialize new structure member.
9033 * linux-low.h (struct lwp_info) <waitstatus>: New member.
9034 * lynx-low.c: Initialize new structure member.
9035 * remote-utils.c (prepare_resume_reply): Implement stop reason
9036 "fork" for "T" stop message.
9037 * server.c (handle_query): Call handle_new_gdb_connection.
9038 * server.h (report_fork_events): Declare global flag.
9039 * target.h (struct target_ops) <handle_new_gdb_connection>:
9040 New member.
9041 (target_handle_new_gdb_connection): New macro.
9042 * win32-low.c: Initialize new structure member.
9043
9044 2015-05-12 Don Breazeal <donb@codesourcery.com>
9045
9046 * mem-break.c (APPEND_TO_LIST): Define macro.
9047 (clone_agent_expr): New function.
9048 (clone_one_breakpoint): New function.
9049 (clone_all_breakpoints): New function.
9050 * mem-break.h: Declare new functions.
9051
9052 2015-05-12 Don Breazeal <donb@codesourcery.com>
9053
9054 * linux-low.c (linux_supports_fork_events): New function.
9055 (linux_supports_vfork_events): New function.
9056 (linux_target_ops): Initialize new structure members.
9057 (initialize_low): Call linux_check_ptrace_features.
9058 * lynx-low.c (lynx_target_ops): Initialize new structure
9059 members.
9060 * server.c (report_fork_events, report_vfork_events):
9061 New global flags.
9062 (handle_query): Add new features to qSupported packet and
9063 response.
9064 (captured_main): Initialize new global variables.
9065 * target.h (struct target_ops) <supports_fork_events>:
9066 New member.
9067 <supports_vfork_events>: New member.
9068 (target_supports_fork_events): New macro.
9069 (target_supports_vfork_events): New macro.
9070 * win32-low.c (win32_target_ops): Initialize new structure
9071 members.
9072
9073 2015-05-12 Gary Benson <gbenson@redhat.com>
9074
9075 * server.c (handle_qxfer_exec_file): Use current process
9076 if annex is empty.
9077
9078 2015-05-08 Sandra Loosemore <sandra@codesourcery.com>
9079
9080 * linux-nios2-low.c: Include elf/common.h. Adjust comments.
9081 Remove HAVE_PTRACE_GETREGS conditionals.
9082 (nios2_regsets): Use PTRACE_GETREGSET and PTRACE_SETREGSET
9083 instead of PTRACE_GETREGS and PTRACE_SETREGS.
9084
9085 2015-05-08 Yao Qi <yao.qi@linaro.org>
9086
9087 * linux-low.c (linux_supports_conditional_breakpoints): New
9088 function.
9089 (linux_target_ops): Install new target method.
9090 * lynx-low.c (lynx_target_ops): Install NULL hook for
9091 supports_conditional_breakpoints.
9092 * nto-low.c (nto_target_ops): Likewise.
9093 * spu-low.c (spu_target_ops): Likewise.
9094 * win32-low.c (win32_target_ops): Likewise.
9095 * server.c (handle_query): Check
9096 target_supports_conditional_breakpoints.
9097 * target.h (struct target_ops) <supports_conditional_breakpoints>:
9098 New field.
9099 (target_supports_conditional_breakpoints): New macro.
9100
9101 2015-05-06 Pedro Alves <palves@redhat.com>
9102
9103 PR server/18081
9104 * server.c (start_inferior): If the process exits, mourn it.
9105
9106 2015-04-21 Gary Benson <gbenson@redhat.com>
9107
9108 * hostio.c (fileio_open_flags_to_host): Factored out to
9109 fileio_to_host_openflags in common/fileio.c. Single use
9110 updated.
9111
9112 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
9113
9114 * linux-xtensa-low.c (xtensa_fill_gregset)
9115 (xtensa_store_gregset): Check XCHAL_HAVE_LOOPS instead of
9116 XCHAL_HAVE_LOOP.
9117
9118 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
9119
9120 * linux-xtensa-low.c (xtensa_usrregs_info): Remove.
9121 (regs_info): Replace usrregs pointer with NULL.
9122
9123 2015-04-17 Gary Benson <gbenson@redhat.com>
9124
9125 * target.h (struct target_ops) <pid_to_exec_file>: New field.
9126 * linux-low.c (linux_target_ops): Initialize pid_to_exec_file.
9127 * server.c (handle_qxfer_exec_file): New function.
9128 (qxfer_packets): Add exec-file entry.
9129 (handle_query): Report qXfer:exec-file:read as supported packet.
9130
9131 2015-04-14 Romain Naour <romain.naour@openwide.fr> (tiny change)
9132
9133 * linux-low.c (linux_read_offsets): Remove get_thread_lwp.
9134
9135 2015-04-09 Gary Benson <gbenson@redhat.com>
9136
9137 * hostio-errno.c (errno_to_fileio_error): Remove function.
9138 Update caller to use remote_fileio_to_fio_error.
9139
9140 2015-04-09 Yao Qi <yao.qi@linaro.org>
9141
9142 * linux-low.c (linux_insert_point): Call
9143 insert_memory_breakpoint if TYPE is raw_bkpt_type_sw.
9144 (linux_remove_point): Call remove_memory_breakpoint if type is
9145 raw_bkpt_type_sw.
9146 * linux-x86-low.c (x86_insert_point): Don't call
9147 insert_memory_breakpoint.
9148 (x86_remove_point): Don't call remove_memory_breakpoint.
9149
9150 2015-04-01 Pedro Alves <palves@redhat.com>
9151 Cleber Rosa <crosa@redhat.com>
9152
9153 * server.c (gdbserver_usage): Reorganize and extend the usage
9154 message.
9155
9156 2015-03-24 Pedro Alves <palves@redhat.com>
9157
9158 * linux-low.c (check_stopped_by_breakpoint): Tweak debug log
9159 output. Also dump TRAP_TRACE.
9160 (linux_low_filter_event): In debug output, distinguish a
9161 resume_stop SIGSTOP from a delayed SIGSTOP.
9162
9163 2015-03-24 Gary Benson <gbenson@redhat.com>
9164
9165 * linux-x86-low.c (x86_linux_new_thread): Moved to
9166 nat/x86-linux.c.
9167 (x86_linux_prepare_to_resume): Likewise.
9168
9169 2015-03-24 Gary Benson <gbenson@redhat.com>
9170
9171 * Makefile.in (x86-linux-dregs.o): New rule.
9172 * configure.srv: Add x86-linux-dregs.o to relevant targets.
9173 * linux-x86-low.c: Include nat/x86-linux-dregs.h.
9174 (u_debugreg_offset): Moved to nat/x86-linux-dregs.c.
9175 (x86_linux_dr_get): Likewise.
9176 (x86_linux_dr_set): Likewise.
9177 (update_debug_registers_callback): Likewise.
9178 (x86_linux_dr_set_addr): Likewise.
9179 (x86_linux_dr_get_addr): Likewise.
9180 (x86_linux_dr_set_control): Likewise.
9181 (x86_linux_dr_get_control): Likewise.
9182 (x86_linux_dr_get_status): Likewise.
9183 (x86_linux_update_debug_registers): Likewise.
9184
9185 2015-03-24 Gary Benson <gbenson@redhat.com>
9186
9187 * linux-x86-low.c (x86_linux_update_debug_registers):
9188 New function, factored out from...
9189 (x86_linux_prepare_to_resume): ...this.
9190
9191 2015-03-24 Gary Benson <gbenson@redhat.com>
9192
9193 * linux-x86-low.c (x86_linux_dr_get): Update comments.
9194 (x86_linux_dr_set): Likewise.
9195 (update_debug_registers_callback): Likewise.
9196 (x86_linux_dr_set_addr): Likewise.
9197 (x86_linux_dr_get_addr): Likewise.
9198 (x86_linux_dr_set_control): Likewise.
9199 (x86_linux_dr_get_control): Likewise.
9200 (x86_linux_dr_get_status): Likewise.
9201 (x86_linux_prepare_to_resume): Likewise.
9202
9203 2015-03-24 Gary Benson <gbenson@redhat.com>
9204
9205 * linux-x86-low.c (x86_linux_dr_get): Add assertion.
9206 Use perror_with_name. Pass string through gettext.
9207 (x86_linux_dr_set): Likewise.
9208
9209 2015-03-24 Gary Benson <gbenson@redhat.com>
9210
9211 * linux-x86-low.c (x86_dr_low_set_addr): Rename to...
9212 (x86_linux_dr_set_addr): ...this.
9213 (x86_dr_low_get_addr): Rename to...
9214 (x86_linux_dr_get_addr): ...this.
9215 (x86_dr_low_set_control): Rename to...
9216 (x86_linux_dr_set_control): ...this.
9217 (x86_dr_low_get_control): Rename to...
9218 (x86_linux_dr_get_control): ...this.
9219 (x86_dr_low_get_status): Rename to...
9220 (x86_linux_dr_get_status): ...this.
9221 (x86_dr_low): Update with new function names.
9222
9223 2015-03-24 Gary Benson <gbenson@redhat.com>
9224
9225 * Makefile.in (x86-linux.o): New rule.
9226 * configure.srv: Add x86-linux.o to relevant targets.
9227 * linux-low.c (lwp_set_arch_private_info): New function.
9228 (lwp_arch_private_info): Likewise.
9229 * linux-x86-low.c: Include nat/x86-linux.h.
9230 (arch_lwp_info): Removed structure.
9231 (update_debug_registers_callback):
9232 Use lwp_set_debug_registers_changed.
9233 (x86_linux_prepare_to_resume): Use lwp_debug_registers_changed
9234 and lwp_set_debug_registers_changed.
9235 (x86_linux_new_thread): Use lwp_set_debug_registers_changed.
9236
9237 2015-03-24 Gary Benson <gbenson@redhat.com>
9238
9239 * linux-low.h (linux_target_ops) <new_thread>: Changed signature.
9240 * linux-arm-low.c (arm_new_thread): Likewise.
9241 * linux-aarch64-low.c (aarch64_linux_new_thread): Likewise.
9242 * linux-mips-low.c (mips_linux_new_thread): Likewise.
9243 * linux-x86-low.c (x86_linux_new_thread): Likewise.
9244 * linux-low.c (add_lwp): Update the_low_target.new_thread call.
9245
9246 2015-03-24 Gary Benson <gbenson@redhat.com>
9247
9248 * linux-low.c (ptid_of_lwp): New function.
9249 (lwp_is_stopped): Likewise.
9250 (lwp_stop_reason): Likewise.
9251 * linux-x86-low.c (update_debug_registers_callback):
9252 Use lwp_is_stopped.
9253 (x86_linux_prepare_to_resume): Use ptid_of_lwp and
9254 lwp_stop_reason.
9255
9256 2015-03-24 Gary Benson <gbenson@redhat.com>
9257
9258 * linux-low.h (linux_stop_lwp): Remove declaration.
9259
9260 2015-03-24 Gary Benson <gbenson@redhat.com>
9261
9262 * linux-low.h: Include nat/linux-nat.h.
9263 * linux-low.c (iterate_over_lwps_args): New structure.
9264 (iterate_over_lwps_filter): New function.
9265 (iterate_over_lwps): Likewise.
9266 * linux-x86-low.c (update_debug_registers_callback):
9267 Update signature to what iterate_over_lwps expects.
9268 Remove PID check that iterate_over_lwps now performs.
9269 (x86_dr_low_set_addr): Use iterate_over_lwps.
9270 (x86_dr_low_set_control): Likewise.
9271
9272 2015-03-24 Gary Benson <gbenson@redhat.com>
9273
9274 * linux-x86-low.c (x86_debug_reg_state): New function.
9275 (x86_linux_prepare_to_resume): Use the above.
9276
9277 2015-03-24 Gary Benson <gbenson@redhat.com>
9278
9279 * linux-low.c (current_lwp_ptid): New function.
9280 * linux-x86-low.c: Include nat/linux-nat.h.
9281 (x86_dr_low_get_addr): Use current_lwp_ptid.
9282 (x86_dr_low_get_control): Likewise.
9283 (x86_dr_low_get_status): Likewise.
9284
9285 2015-03-20 Pedro Alves <palves@redhat.com>
9286
9287 * tracepoint.c (cmd_qtstatus): Make "str" const.
9288
9289 2015-03-20 Pedro Alves <palves@redhat.com>
9290
9291 * server.c (handle_general_set): Make "req_str" const.
9292
9293 2015-03-19 Pedro Alves <palves@redhat.com>
9294
9295 * linux-low.c (linux_resume_one_lwp): Rename to ...
9296 (linux_resume_one_lwp_throw): ... this. Don't handle ESRCH here,
9297 instead call perror_with_name.
9298 (check_ptrace_stopped_lwp_gone): New function.
9299 (linux_resume_one_lwp): Reimplement as wrapper around
9300 linux_resume_one_lwp_throw that swallows errors if the LWP is
9301 gone.
9302
9303 2015-03-19 Pedro Alves <palves@redhat.com>
9304
9305 * linux-low.c (count_events_callback, select_event_lwp_callback):
9306 No longer check whether the thread has resume_stop as last resume
9307 kind.
9308
9309 2015-03-19 Pedro Alves <palves@redhat.com>
9310
9311 * linux-low.c (count_events_callback, select_event_lwp_callback):
9312 Use the lwp's status_pending_p field, not the thread's.
9313
9314 2015-03-19 Pedro Alves <palves@redhat.com>
9315
9316 * linux-low.c (select_event_lwp_callback): Update comments to
9317 no longer mention SIGTRAP.
9318
9319 2015-03-18 Gary Benson <gbenson@redhat.com>
9320
9321 * server.c (handle_query): Do not report vFile:fstat as supported.
9322
9323 2015-03-11 Gary Benson <gbenson@redhat.com>
9324
9325 * hostio.c (sys/types.h): New include.
9326 (sys/stat.h): Likewise.
9327 (common-remote-fileio.h): Likewise.
9328 (handle_fstat): New function.
9329 (handle_vFile): Handle vFile:fstat packets.
9330
9331 2015-03-11 Gary Benson <gbenson@redhat.com>
9332
9333 * configure.ac (AC_CHECK_MEMBERS): Add checks for
9334 struct stat.st_blocks and struct stat.st_blksize.
9335 * configure: Regenerate.
9336 * config.in: Likewise.
9337 * Makefile.in (SFILES): Add common/common-remote-fileio.c.
9338 (OBS): Add common-remote-fileio.o.
9339 (common-remote-fileio.o): New rule.
9340
9341 2015-03-09 Pedro Alves <palves@redhat.com>
9342
9343 * tracepoint.c (gdb_agent_helper_thread): Cast '&sockaddr' to
9344 'struct sockaddr' pointer in 'accept' call.
9345
9346 2015-03-09 Pedro Alves <palves@redhat.com>
9347
9348 Revert:
9349 2015-03-07 Pedro Alves <palves@redhat.com>
9350 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
9351 or <winsock2.h> here. Instead include "gdb_socket.h".
9352 (remote_open): Use union gdb_sockaddr_u.
9353 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
9354 or <winsock2.h> here. Instead include "gdb_socket.h".
9355 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
9356 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
9357 or <sys/un.h>.
9358 (init_named_socket, gdb_agent_helper_thread): Use union
9359 gdb_sockaddr_u.
9360
9361 2015-03-07 Pedro Alves <palves@redhat.com>
9362
9363 * configure.ac (build_warnings): Move
9364 -Wdeclaration-after-statement to the C-specific set.
9365 * configure: Regenerate.
9366
9367 2015-03-07 Pedro Alves <palves@redhat.com>
9368
9369 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
9370 or <winsock2.h> here. Instead include "gdb_socket.h".
9371 (remote_open): Use union gdb_sockaddr_u.
9372 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
9373 or <winsock2.h> here. Instead include "gdb_socket.h".
9374 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
9375 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
9376 or <sys/un.h>.
9377 (init_named_socket, gdb_agent_helper_thread): Use union
9378 gdb_sockaddr_u.
9379
9380 2015-03-07 Pedro Alves <palves@redhat.com>
9381
9382 Adjust all callers of TRY_CATCH to use TRY/CATCH/END_CATCH
9383 instead.
9384
9385 2015-03-06 Yao Qi <yao.qi@linaro.org>
9386
9387 * linux-aarch64-low.c (aarch64_insert_point): Use
9388 show_debug_regs as a boolean.
9389 (aarch64_remove_point): Likewise.
9390
9391 2015-03-05 Pedro Alves <palves@redhat.com>
9392
9393 * lynx-low.c (lynx_target_ops): Install NULL hooks for
9394 stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
9395 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint.
9396 * nto-low.c (nto_target_ops): Likewise.
9397 * spu-low.c (spu_target_ops): Likewise.
9398 * win32-low.c (win32_target_ops): Likewise.
9399
9400 2015-03-04 Pedro Alves <palves@redhat.com>
9401
9402 * linux-low.c (check_stopped_by_breakpoint) [USE_SIGTRAP_SIGINFO]:
9403 Decide whether a breakpoint triggered based on the SIGTRAP's
9404 siginfo.si_code.
9405 (thread_still_has_status_pending_p) [USE_SIGTRAP_SIGINFO]: Don't check whether a
9406 breakpoint is inserted if relying on SIGTRAP's siginfo.si_code.
9407 (linux_low_filter_event): Check for breakpoints before checking
9408 watchpoints.
9409 (linux_wait_1): Don't re-increment the PC if relying on SIGTRAP's
9410 siginfo.si_code.
9411 (linux_stopped_by_sw_breakpoint)
9412 (linux_supports_stopped_by_sw_breakpoint)
9413 (linux_stopped_by_hw_breakpoint)
9414 (linux_supports_stopped_by_hw_breakpoint): New functions.
9415 (linux_target_ops): Install new target methods.
9416
9417 2015-03-04 Pedro Alves <palves@redhat.com>
9418
9419 * remote-utils.c (prepare_resume_reply): Report swbreak/hbreak.
9420 * server.c (swbreak_feature, hwbreak_feature): New globals.
9421 (handle_query) <qSupported>: Handle "swbreak+" and "hwbreak+".
9422 (captured_main): Clear swbreak_feature and hwbreak_feature.
9423 * server.h (swbreak_feature, hwbreak_feature): Declare.
9424 * target.h (struct target_ops) <stopped_by_sw_breakpoint,
9425 supports_stopped_by_sw_breakpoint, stopped_by_hw_breakpoint,
9426 supports_stopped_by_hw_breakpoint>: New fields.
9427 (target_supports_stopped_by_sw_breakpoint)
9428 (target_stopped_by_sw_breakpoint)
9429 (target_supports_stopped_by_hw_breakpoint)
9430 (target_stopped_by_hw_breakpoint): Declare.
9431
9432 2015-03-04 Pedro Alves <palves@redhat.com>
9433
9434 enum lwp_stop_reason -> enum target_stop_reason
9435 * linux-low.c (check_stopped_by_breakpoint): Adjust.
9436 (thread_still_has_status_pending_p, check_stopped_by_watchpoint)
9437 (linux_wait_1, stuck_in_jump_pad_callback)
9438 (move_out_of_jump_pad_callback, linux_resume_one_lwp)
9439 (linux_stopped_by_watchpoint):
9440 * linux-low.h (enum lwp_stop_reason): Delete.
9441 (struct lwp_info) <stop_reason>: Now an enum target_stop_reason.
9442 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
9443
9444 2015-03-04 Yao Qi <yao.qi@linaro.org>
9445
9446 * Makefile.in (SFILES): Add linux-aarch64-low.c.
9447
9448 2015-03-03 Gary Benson <gbenson@redhat.com>
9449
9450 * hostio.c (handle_vFile): Fix prefix lengths.
9451
9452 2015-03-03 Markus Metzger <markus.t.metzger@intel.com>
9453
9454 * linux-low.c (linux_low_enable_btrace): Do not overwrite non-zero
9455 ptr_bits.
9456
9457 2015-03-02 Andreas Arnez <arnez@linux.vnet.ibm.com>
9458
9459 * Makefile.in (s390-vx-linux64.c, s390-tevx-linux64.c)
9460 (s390x-vx-linux64.c, s390x-tevx-linux64.c): New rules.
9461 (clean): Add "rm -f" for above C files.
9462 * configure.srv (srv_regobj): Add s390-vx-linux64.o,
9463 s390-tevx-linux64.o, s390x-vx-linux64.o, and s390x-tevx-linux64.o.
9464 (srv_xmlfiles): Add s390-vx-linux64.xml, s390-tevx-linux64.xml,
9465 s390x-vx-linux64.xml, s390x-tevx-linux64.xml, and s390-vx.xml.
9466 * linux-s390-low.c (HWCAP_S390_VX): New macro.
9467 (init_registers_s390_vx_linux64, init_registers_s390_tevx_linux64)
9468 (init_registers_s390x_vx_linux64)
9469 (init_registers_s390x_tevx_linux64)
9470 (tdesc_s390_vx_linux64, tdesc_s390_tevx_linux64)
9471 (tdesc_s390x_vx_linux64, tdesc_s390x_tevx_linux64): New extern
9472 declarations.
9473 (s390_fill_vxrs_low, s390_store_vxrs_low, s390_fill_vxrs_high)
9474 (s390_store_vxrs_high): New functions.
9475 (s390_regsets): Add entries for NT_S390_VXRS_LOW and
9476 NT_S390_VXRS_HIGH.
9477 (s390_arch_setup): Add logic for selecting one of the new target
9478 descriptions. Activate the new vector regsets if applicable.
9479 (initialize_low_arch): Also invoke init_registers_s390_vx_linux64,
9480 init_registers_s390_tevx_linux64, init_registers_s390x_vx_linux64,
9481 and init_registers_s390x_tevx_linux64.
9482
9483 2015-03-01 Pedro Alves <palves@redhat.com>
9484
9485 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Constify 'raw_regs'
9486 parameter.
9487
9488 2015-02-27 Pedro Alves <palves@redhat.com>
9489
9490 * linux-x86-low.c (u_debugreg_offset): New function.
9491 (x86_linux_dr_get, x86_linux_dr_set): Use it.
9492
9493 2015-02-27 Pedro Alves <palves@redhat.com>
9494
9495 * gdb_proc_service.h: Wrap with EXTERN_C_PUSH/EXTERN_C_POP.
9496 [!HAVE_PROC_SERVICE_H] (struct ps_prochandle): Forward declare.
9497 [!HAVE_PROC_SERVICE_H] (ps_pdread, ps_pdwrite, ps_ptread)
9498 ps_ptwrite, ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
9499 (ps_lsetfpregs, ps_getpid)
9500 (ps_get_thread_area, ps_pglobal_lookup, ps_pstop, ps_pcontinue)
9501 (ps_lstop, ps_lcontinue, ps_lgetxregsize, ps_lgetxregs)
9502 (ps_lsetxregs, ps_plog): Declare.
9503
9504 2015-02-27 Pedro Alves <palves@redhat.com>
9505
9506 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Use
9507 IP_AGENT_EXPORT_FUNC.
9508 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Use
9509 IP_AGENT_EXPORT_FUNC.
9510 * tracepoint.c (ATTR_USED, ATTR_NOINLINE, ATTR_CONSTRUCTOR)
9511 (IP_AGENT_EXPORT): Delete.
9512 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
9513 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
9514 (gdb_trampoline_buffer_error, collecting, gdb_collect)
9515 (stop_tracing, flush_trace_buffer, about_to_request_buffer_space)
9516 (trace_buffer_is_full, stopping_tracepoint, expr_eval_result)
9517 (error_tracepoint, tracepoints, tracing, trace_buffer_ctrl)
9518 (trace_buffer_ctrl_curr, trace_buffer_lo, trace_buffer_hi)
9519 (traceframe_read_count, traceframe_write_count)
9520 (traceframes_created, trace_state_variables, get_raw_reg)
9521 (get_trace_state_variable_value, set_trace_state_variable_value)
9522 (ust_loaded, helper_thread_id, cmd_buf): Use
9523 IPA_SYM_EXPORTED_NAME.
9524 (stop_tracing, flush_trace_buffer): Use IP_AGENT_EXPORT_FUNC.
9525 (tracepoints) Use IP_AGENT_EXPORT_VAR.
9526 (stopping_tracepoint, trace_buffer_is_full, expr_eval_result): Use
9527 IP_AGENT_EXPORT_VAR and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
9528 (last_tracepoint): Move into !IN_PROCESS_AGENT block.
9529 (error_tracepoint): Use IP_AGENT_EXPORT_VAR and wrap in
9530 EXTERN_C_PUSH/EXTERN_C_POP.
9531 (trace_state_variables): Use IP_AGENT_EXPORT_VAR.
9532 (trace_buffer_lo, trace_buffer_hi): Use IP_AGENT_EXPORT_VAR and
9533 wrap in EXTERN_C_PUSH/EXTERN_C_POP.
9534 (trace_buffer_ctrl, trace_buffer_ctrl_curr)
9535 (traceframe_write_count, traceframe_read_count)
9536 (traceframes_created, tracing): Use IP_AGENT_EXPORT_VAR.
9537 (about_to_request_buffer_space, get_trace_state_variable_value)
9538 (set_trace_state_variable_value): Use IP_AGENT_EXPORT_FUNC.
9539 (collecting): Use IP_AGENT_EXPORT_VAR and wrap in
9540 EXTERN_C_PUSH/EXTERN_C_POP.
9541 (gdb_collect): Use IP_AGENT_EXPORT_FUNC.
9542 (ust_loaded, cmd_buf): Use IP_AGENT_EXPORT_VAR.
9543 (helper_thread_id, gdb_agent_capability): Use IP_AGENT_EXPORT_VAR
9544 and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
9545 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
9546 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
9547 (gdb_trampoline_buffer_error): Use IP_AGENT_EXPORT_VAR.
9548 * tracepoint.h (ATTR_USED, ATTR_NOINLINE, EXPORTED_SYMBOL):
9549 Define.
9550 (IP_AGENT_EXPORT_FUNC, IP_AGENT_EXPORT_VAR)
9551 (IP_AGENT_EXPORT_VAR_DECL): Define.
9552 (tracing): Declare.
9553 (gdb_agent_get_raw_reg): Declare.
9554
9555 2015-02-27 Tom Tromey <tromey@redhat.com>
9556 Pedro Alves <palves@redhat.com>
9557
9558 Rename symbols whose names are reserved C++ keywords throughout.
9559
9560 2015-02-27 Pedro Alves <palves@redhat.com>
9561
9562 * Makefile.in (COMPILER): New, get it from autoconf.
9563 (CXX): Get from autoconf instead.
9564 (COMPILE.pre): Use COMPILER.
9565 (CC-LD): Rename to ...
9566 (CC_LD): ... this. Use COMPILER.
9567 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT), $(IPA_LIB)): Adjust.
9568 (CXX_FOR_TARGET): Default to g++ instead of gcc.
9569 * acinclude.m4: Include build-with-cxx.m4.
9570 * configure.ac: Call AC_PROG_CXX and GDB_AC_BUILD_WITH_CXX.
9571 Disable -Werror by default if building in C++ mode.
9572 (build_warnings): Add -Wno-sign-compare, -Wno-write-strings and
9573 -Wno-narrowing in C++ mode. Run supported-warning-flags tests with
9574 the C++ compiler. Save/restore CXXFLAGS too.
9575 * configure: Regenerate.
9576
9577 2015-02-27 Pedro Alves <palves@redhat.com>
9578
9579 * acinclude.m4: Include libiberty.m4.
9580 * configure.ac: Call libiberty_INIT.
9581 * config.in, configure: Regenerate.
9582
9583 2015-02-26 Pedro Alves <palves@redhat.com>
9584
9585 * linux-low.c (linux_wait_1): When incrementing the PC past a
9586 program breakpoint always use the_low_target.breakpoint_len as
9587 increment, rather than the maximum between that and
9588 the_low_target.decr_pc_after_break.
9589
9590 2015-02-23 Pedro Alves <palves@redhat.com>
9591
9592 * linux-low.c (check_stopped_by_breakpoint): Don't check if the
9593 thread was doing a step-over; always adjust the PC if
9594 we stepped over a permanent breakpoint.
9595 (linux_wait_1): If we stepped over breakpoint that was on top of a
9596 permanent breakpoint, manually advance the PC past it.
9597
9598 2015-02-23 Pedro Alves <palves@redhat.com>
9599
9600 * linux-x86-low.c (REGSIZE): Define in both 32-bit and 64-bit
9601 modes.
9602 (x86_fill_gregset, x86_store_gregset): Use it when handling
9603 $orig_eax.
9604
9605 2015-02-20 Pedro Alves <palves@redhat.com>
9606
9607 * thread-db.c: Include "nat/linux-procfs.h".
9608 (thread_db_init): Skip listing new threads if the kernel supports
9609 PTRACE_EVENT_CLONE and /proc/PID/task/ is accessible.
9610
9611 2015-02-20 Pedro Alves <palves@redhat.com>
9612
9613 * linux-low.c (status_pending_p_callback): Use ptid_match.
9614
9615 2015-02-19 Antoine Tremblay <antoine.tremblay@ericsson.com>
9616
9617 PR breakpoints/16812
9618 * linux-low.c (wstatus_maybe_breakpoint): Remove.
9619 (linux_low_filter_event): Update wstatus_maybe_breakpoint name.
9620 (linux_wait_1): Report SIGTRAP,SIGILL,SIGSEGV.
9621
9622 2015-02-10 Antoine Tremblay <antoine.tremblay@ericsson.com>
9623
9624 PR breakpoints/15956
9625 * tracepoint.c (cmd_qtinit): Add check for current_thread.
9626
9627 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
9628
9629 * linux-low.c (linux_low_btrace_conf): Print size.
9630 * server.c (handle_btrace_conf_general_set): New.
9631 (hanle_general_set): Call handle_btrace_conf_general_set.
9632 (handle_query): Report Qbtrace-conf:bts:size as supported.
9633
9634 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
9635
9636 * linux-low.c (linux_low_enable_btrace): Update parameters.
9637 (linux_low_btrace_conf): New.
9638 (linux_target_ops)<to_btrace_conf>: Initialize.
9639 * server.c (current_btrace_conf): New.
9640 (handle_btrace_enable): Rename to ...
9641 (handle_btrace_enable_bts): ... this. Pass &current_btrace_conf
9642 to target_enable_btrace. Update comment. Update users.
9643 (handle_qxfer_btrace_conf): New.
9644 (qxfer_packets): Add btrace-conf entry.
9645 (handle_query): Report qXfer:btrace-conf:read as supported packet.
9646 * target.h (target_ops)<enable_btrace>: Update parameters and comment.
9647 (target_ops)<read_btrace_conf>: New.
9648 (target_enable_btrace): Update parameters.
9649 (target_read_btrace_conf): New.
9650
9651 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
9652
9653 * server.c (handle_btrace_general_set): Remove call to
9654 target_supports_btrace.
9655 (supported_btrace_packets): New.
9656 (handle_query): Call supported_btrace_packets.
9657 * target.h: include btrace-common.h.
9658 (btrace_target_info): Removed.
9659 (supports_btrace, target_supports_btrace): Update parameters.
9660
9661 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
9662
9663 * Makefile.in (SFILES): Add common/btrace-common.c.
9664 (OBS): Add common/btrace-common.o.
9665 (btrace-common.o): Add build rules.
9666 * linux-low: Include btrace-common.h.
9667 (linux_low_read_btrace): Use struct btrace_data. Call
9668 btrace_data_init and btrace_data_fini.
9669
9670 2015-02-06 Pedro Alves <palves@redhat.com>
9671
9672 * thread-db.c (find_new_threads_callback): Add debug output.
9673
9674 2015-02-04 Pedro Alves <palves@redhat.com>
9675
9676 * linux-low.c (handle_extended_wait): Don't resume LWPs here.
9677 (resume_stopped_resumed_lwps): New function.
9678 (linux_wait_for_event_filtered): Use it.
9679
9680 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
9681
9682 * Makefile.in (SFILES): Add linux-personality.c.
9683 (linux-personality.o): New rule.
9684 * configure.srv (srv_linux_obj): Add linux-personality.o to the
9685 list of objects to be built.
9686 * linux-low.c: Include nat/linux-personality.h.
9687 (linux_create_inferior): Remove code to disable address space
9688 randomization (moved to ../nat/linux-personality.c). Create
9689 cleanup to disable address space randomization.
9690
9691 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
9692
9693 * Makefile.in (posix-strerror.o): New rule.
9694 (mingw-strerror.o): Likewise.
9695 * configure: Regenerated.
9696 * configure.ac: Source file ../common/common.host. Initialize new
9697 variable srv_host_obs. Add srv_host_obs to GDBSERVER_DEPFILES.
9698
9699 2015-01-14 Yao Qi <yao@codesourcery.com>
9700
9701 * Makefile.in (SFILES): Add nat/ppc-linux.c.
9702 (ppc-linux.o): New rule.
9703 * configure.srv (powerpc*-*-linux*): Add ppc-linux.o.
9704 * configure.ac: AC_CHECK_FUNCS(getauxval).
9705 * config.in: Re-generated.
9706 * configure: Re-generated.
9707 * linux-ppc-low.c (ppc_arch_setup) [__powerpc64__]: Call
9708 ppc64_64bit_inferior_p
9709
9710 2015-01-14 Yao Qi <yao@codesourcery.com>
9711
9712 * linux-ppc-low.c: Include "nat/ppc-linux.h".
9713 (PPC_FEATURE_HAS_VSX): Move to nat/ppc-linux.h.
9714 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Likewise.
9715 (PT_ORIG_R3, PT_TRAP): Likewise.
9716 (PTRACE_GETVSXREGS, PTRACE_SETVSXREGS): Likewise.
9717 (PTRACE_GETVRREGS, PTRACE_SETVRREGS): Likewise.
9718 (PTRACE_GETEVRREGS, PTRACE_SETEVRREGS): Likewise.
9719
9720 2015-01-10 Joel Brobecker <brobecker@adacore.com>
9721
9722 * i387-fp.c (i387_cache_to_xsave): In look over
9723 num_avx512_zmmh_high_registers, replace use of struct i387_xsave
9724 zmmh_low_space field by use of zmmh_high_space.
9725
9726 2015-01-09 Pedro Alves <palves@redhat.com>
9727
9728 * linux-low.c (step_over_bkpt): Move higher up in the file.
9729 (handle_extended_wait): Don't store the stop_pc here.
9730 (get_stop_pc): Adjust comments and rename to ...
9731 (check_stopped_by_breakpoint): ... this. Record whether the LWP
9732 stopped for a software breakpoint or hardware breakpoint.
9733 (thread_still_has_status_pending_p): New function.
9734 (status_pending_p_callback): Use
9735 thread_still_has_status_pending_p. If the event is no longer
9736 interesting, resume the LWP.
9737 (handle_tracepoints): Add assert.
9738 (maybe_move_out_of_jump_pad): Remove cancel_breakpoints call.
9739 (wstatus_maybe_breakpoint): New function.
9740 (cancel_breakpoint): Delete function.
9741 (check_stopped_by_watchpoint): New function, factored out from
9742 linux_low_filter_event.
9743 (lp_status_maybe_breakpoint): Delete function.
9744 (linux_low_filter_event): Remove filter_ptid argument.
9745 Leave thread group exits pending here. Store the LWP's stop PC.
9746 Always leave events pending.
9747 (linux_wait_for_event_filtered): Pull all events out of the
9748 kernel, and leave them all pending.
9749 (count_events_callback, select_event_lwp_callback): Consider all
9750 events.
9751 (cancel_breakpoints_callback, linux_cancel_breakpoints): Delete.
9752 (select_event_lwp): Only give preference to the stepping LWP in
9753 all-stop mode. Adjust comments.
9754 (ignore_event): New function.
9755 (linux_wait_1): Delete 'retry' label. Use ignore_event. Remove
9756 references to cancel_breakpoints. Adjust to renames. Also give
9757 equal priority to all LWPs that have had events in non-stop mode.
9758 If reporting a software breakpoint event, unadjust the LWP's PC.
9759 (linux_wait): If linux_wait_1 returned an ignored event, retry.
9760 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback):
9761 Adjust.
9762 (linux_resume_one_lwp): Store the LWP's PC. Adjust.
9763 (resume_status_pending_p): Use thread_still_has_status_pending_p.
9764 (linux_stopped_by_watchpoint): Adjust.
9765 (linux_target_ops): Remove reference to linux_cancel_breakpoints.
9766 * linux-low.h (enum lwp_stop_reason): New.
9767 (struct lwp_info) <stop_pc>: Adjust comment.
9768 <stopped_by_watchpoint>: Delete field.
9769 <stop_reason>: New field.
9770 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
9771 * mem-break.c (software_breakpoint_inserted_here)
9772 (hardware_breakpoint_inserted_here): New function.
9773 * mem-break.h (software_breakpoint_inserted_here)
9774 (hardware_breakpoint_inserted_here): Declare.
9775 * target.h (struct target_ops) <cancel_breakpoints>: Remove field.
9776 (cancel_breakpoints): Delete.
9777 * tracepoint.c (clear_installed_tracepoints, stop_tracing)
9778 (upload_fast_traceframes): Remove references to
9779 cancel_breakpoints.
9780
9781 2015-01-09 Pedro Alves <palves@redhat.com>
9782
9783 * thread-db.c (find_new_threads_callback): Ignore thread if the
9784 kernel thread ID is -1.
9785
9786 2015-01-09 Pedro Alves <palves@redhat.com>
9787
9788 * linux-low.c (linux_attach_fail_reason_string): Move to
9789 nat/linux-ptrace.c, and rename.
9790 (linux_attach_lwp): Update comment.
9791 (attach_proc_task_lwp_callback): New function.
9792 (linux_attach): Adjust to rename and use
9793 linux_proc_attach_tgid_threads.
9794 (linux_attach_fail_reason_string): Delete declaration.
9795
9796 2015-01-01 Joel Brobecker <brobecker@adacore.com>
9797
9798 * gdbreplay.c (gdbreplay_version): Update copyright year to 2015.
9799 * server.c (gdbserver_version): Likewise.
9800
9801 2014-12-29 Sergio Durigan Junior <sergiodj@redhat.com>
9802
9803 * remote-utils.c: Include ctype.h.
9804 (input_interrupt): Explicitly handle the case when the char
9805 received is the NUL byte. Improve the printing of non-ASCII
9806 characters.
9807
9808 2014-12-16 Joel Brobecker <brobecker@adacore.com>
9809
9810 * linux-low.c (linux_low_filter_event): Update call to
9811 linux_enable_event_reporting following the addition of
9812 a new parameter to that function.
9813
9814 2014-12-16 Catalin Udma <catalin.udma@freescale.com>
9815
9816 PR server/17457
9817 * linux-aarch64-low.c (AARCH64_FPSR_REGNO): New define.
9818 (AARCH64_FPCR_REGNO): Likewise.
9819 (AARCH64_NUM_REGS): Update to include fpsr/fpcr registers.
9820 (aarch64_fill_fpregset): Add missing fpsr/fpcr registers.
9821 (aarch64_store_fpregset): Likewise.
9822
9823 2014-12-15 Joel Brobecker <brobecker@adacore.com>
9824
9825 * lynx-low.c (lynx_resume): Use PTRACE_SINGLESTEP_ONE if N == 1.
9826 Remove FIXME comment about assumption about N.
9827
9828 2014-12-13 Joel Brobecker <brobecker@adacore.com>
9829
9830 * configure.ac: If large-file support is disabled in GDBserver,
9831 pass --disable-largefile to ACX_CONFIGURE_DIR call for "gnulib".
9832 * configure: Regenerate.
9833
9834 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
9835
9836 * linux-low.c (regsets_fetch_inferior_registers): Suppress the
9837 warning upon ENODATA from ptrace.
9838 * linux-s390-low.c (s390_store_tdb): New.
9839 (s390_regsets): Add regset for NT_S390_TDB.
9840
9841 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
9842
9843 * linux-low.c (regsets_store_inferior_registers): Skip regsets
9844 without a fill_function.
9845 * linux-s390-low.c (s390_fill_last_break): Remove.
9846 (s390_regsets): Set fill_function to NULL for NT_S390_LAST_BREAK.
9847 (s390_arch_setup): Use regset's size instead of fill_function for
9848 loop end condition.
9849
9850 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
9851
9852 * linux-low.c (regsets_fetch_inferior_registers): Do not invoke
9853 the regset's store function when ptrace returned an error.
9854 * regcache.c (get_thread_regcache): Invalidate register cache
9855 before fetching inferior's registers.
9856
9857 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
9858
9859 * linux-low.c (regsets_fetch_inferior_registers): Rephrase
9860 while-loop as for-loop.
9861 (regsets_store_inferior_registers): Likewise.
9862
9863 2014-11-28 Yao Qi <yao@codesourcery.com>
9864
9865 * configure.ac(AC_CHECK_FUNCS): Remove readlink.
9866 * config.in, configure: Re-generate.
9867 * hostio.c (handle_unlink): Remove code checking HAVE_READLINK
9868 is defined.
9869
9870 2014-11-21 Yao Qi <yao@codesourcery.com>
9871
9872 * configure.ac: Don't invoke AC_FUNC_ALLOCA.
9873 (AC_CHECK_HEADERS): Remove malloc.h.
9874 * configure: Re-generated.
9875 * config.in: Re-generated.
9876 * server.h: Don't include alloca.h and malloc.h.
9877 * gdbreplay.c: Don't check HAVE_ALLOCA_H is defined.
9878 Don't include malloc.h.
9879
9880 2014-11-17 Joel Brobecker <brobecker@adacore.com>
9881
9882 * lynx-low.c (lynx_write_memory): Put lynx_read_memory and
9883 corresponding ERRNO check in same block.
9884
9885 2014-11-12 Pedro Alves <palves@redhat.com>
9886
9887 * server.c (cont_thread): Update comment.
9888 (start_inferior, attach_inferior): No longer clear cont_thread.
9889 (handle_v_cont): No longer set cont_thread.
9890 (captured_main): Clear cont_thread each time a GDB connects.
9891
9892 2014-11-12 Pedro Alves <palves@redhat.com>
9893
9894 * linux-low.c (linux_wait_1): Don't force a wait for the Hc
9895 thread, and don't resume all threads if the Hc thread has exited.
9896
9897 2014-11-12 Pedro Alves <palves@redhat.com>
9898
9899 * linux-low.c (linux_request_interrupt): Always send a SIGINT to
9900 the process group instead of to a specific LWP.
9901
9902 2014-10-15 Pedro Alves <palves@redhat.com>
9903
9904 PR server/17487
9905 * win32-arm-low.c (arm_set_thread_context): Remove current_event
9906 parameter.
9907 (arm_set_thread_context): Delete.
9908 (the_low_target): Adjust.
9909 * win32-i386-low.c (debug_registers_changed)
9910 (debug_registers_used): Delete.
9911 (update_debug_registers_callback): New function.
9912 (x86_dr_low_set_addr, x86_dr_low_set_control): Mark all threads as
9913 needing to update their debug registers.
9914 (win32_get_current_dr): New function.
9915 (x86_dr_low_get_addr, x86_dr_low_get_control)
9916 (x86_dr_low_get_status): Fetch the debug register from the thread
9917 record's context.
9918 (i386_initial_stuff): Adjust.
9919 (i386_get_thread_context): Remove current_event parameter. Don't
9920 clear debug_registers_changed nor copy DR values to
9921 debug_reg_state.
9922 (i386_set_thread_context): Delete.
9923 (i386_prepare_to_resume): New function.
9924 (i386_thread_added): Mark the thread as needing to update irs
9925 debug registers.
9926 (the_low_target): Remove i386_set_thread_context and install
9927 i386_prepare_to_resume.
9928 * win32-low.c (win32_get_thread_context): Adjust.
9929 (win32_set_thread_context): Use SetThreadContext
9930 directly.
9931 (win32_prepare_to_resume): New function.
9932 (win32_require_context): New function, factored out from ...
9933 (thread_rec): ... this.
9934 (continue_one_thread): Call win32_prepare_to_resume on each thread
9935 we're about to continue.
9936 (win32_resume): Call win32_prepare_to_resume on the event thread.
9937 * win32-low.h (struct win32_thread_info)
9938 <debug_registers_changed>: New field.
9939 (struct win32_target_ops): Change prototype of set_thread_context,
9940 delete set_thread_context and add prepare_to_resume.
9941 (win32_require_context): New declaration.
9942
9943 2014-10-08 Gary Benson <gbenson@redhat.com>
9944
9945 * server.h: Do not include common-exceptions.h.
9946
9947 2014-10-08 Gary Benson <gbenson@redhat.com>
9948
9949 * server.h: Do not include cleanups.h.
9950
9951 2014-09-30 James Hogan <james.hogan@imgtec.com>
9952
9953 * Makefile.in (clean): Add rm -f commands for mips-dsp-linux.c and
9954 mips64-dsp-linux.c.
9955
9956 2014-09-23 Yao Qi <yao@codesourcery.com>
9957
9958 * linux-low.c (lp_status_maybe_breakpoint): New function.
9959 (linux_low_filter_event): Call lp_status_maybe_breakpoint.
9960 (count_events_callback): Likewise.
9961 (select_event_lwp_callback): Likewise.
9962 (cancel_breakpoints_callback): Likewise.
9963
9964 2014-09-19 Don Breazeal <donb@codesourcery.com>
9965
9966 * linux-low.c (handle_extended_wait): Call
9967 linux_ptrace_get_extended_event.
9968 (get_stop_pc, get_detach_signal, linux_low_filter_event): Call
9969 linux_is_extended_waitstatus.
9970
9971 2014-09-16 Joel Brobecker <brobecker@adacore.com>
9972
9973 * Makefile.in (CPPFLAGS): Define.
9974 (INTERNAL_CFLAGS_BASE): Add ${CPPFLAGS}.
9975 (IPAGENT_CFLAGS): Remove ${CPPFLAGS}.
9976
9977 2014-09-16 Gary Benson <gbenson@redhat.com>
9978
9979 * inferiors.h (current_inferior): Renamed as...
9980 (current_thread): New variable. All uses updated.
9981 * linux-low.c (get_pc): Renamed saved_inferior as saved_thread.
9982 (maybe_move_out_of_jump_pad): Likewise.
9983 (cancel_breakpoint): Likewise.
9984 (linux_low_filter_event): Likewise.
9985 (wait_for_sigstop): Likewise.
9986 (linux_resume_one_lwp): Likewise.
9987 (need_step_over_p): Likewise.
9988 (start_step_over): Likewise.
9989 (linux_stabilize_threads): Renamed save_inferior as saved_thread.
9990 * linux-x86-low.c (x86_linux_update_xmltarget): Likewise.
9991 * proc-service.c (ps_lgetregs): Renamed reg_inferior as reg_thread
9992 and save_inferior as saved_thread.
9993 * regcache.c (get_thread_regcache): Renamed saved_inferior as
9994 saved_thread.
9995 (regcache_invalidate_thread): Likewise.
9996 * remote-utils.c (prepare_resume_reply): Likewise.
9997 * thread-db.c (thread_db_get_tls_address): Likewise.
9998 (disable_thread_event_reporting): Likewise.
9999 (remove_thread_event_breakpoints): Likewise.
10000 * tracepoint.c (gdb_agent_about_to_close): Renamed save_inferior
10001 as saved_thread.
10002 * target.h (set_desired_inferior): Renamed as...
10003 (set_desired_thread): New declaration. All uses updated.
10004 * server.c (myresume): Updated comment to reference thread instead
10005 of inferior.
10006 (handle_serial_event): Likewise.
10007 (handle_target_event): Likewise.
10008
10009 2014-09-12 Tom Tromey <tromey@redhat.com>
10010 Gary Benson <gbenson@redhat.com>
10011
10012 * regcache.h: Include common-regcache.h.
10013 (regcache_read_pc): Don't declare.
10014 * regcache.c (get_thread_regcache_for_ptid): New function.
10015
10016 2014-09-11 Tom Tromey <tromey@redhat.com>
10017 Gary Benson <gbenson@redhat.com>
10018
10019 * symbol.c: New file.
10020 * Makefile.in (SFILES): Add symbol.c.
10021 (OBS): Add symbol.o.
10022
10023 2014-09-11 Gary Benson <gbenson@redhat.com>
10024
10025 * target.c (target_stop_ptid, target_continue_ptid): New
10026 functions.
10027
10028 2014-09-11 Tom Tromey <tromey@redhat.com>
10029 Gary Benson <gbenson@redhat.com>
10030
10031 * target.h: Include target/target.h.
10032 * target.c (target_read_memory, target_read_uint32)
10033 (target_write_memory): New functions.
10034
10035 2014-09-11 Gary Benson <gbenson@redhat.com>
10036
10037 * server.h (debug_hw_points): Don't declare.
10038 * server.c (debug_hw_points): Don't define. Replace all uses
10039 with show_debug_regs.
10040 * linux-aarch64-low.c (debug_hw_points): Don't define. Replace
10041 all uses with show_debug_regs.
10042
10043 2014-09-08 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
10044
10045 * linux-ppc-low.c (ppc_collect_ptrace_register): Adjust routine to take
10046 endianness into account.
10047 (ppc_supply_ptrace_register): Likewise.
10048
10049 2014-09-03 James Hogan <james.hogan@imgtec.com>
10050
10051 * linux-mips-low.c (mips_read_description): Reset errno to 0 prior
10052 to reading DSP_CONTROL with PTRACE_PEEKUSER ptrace call.
10053
10054 2014-09-03 Gary Benson <gbenson@redhat.com>
10055
10056 * linux-x86-low.c (x86_linux_prepare_to_resume): Use
10057 ALL_DEBUG_ADDRESS_REGISTERS.
10058
10059 2014-09-02 Gary Benson <gbenson@redhat.com>
10060
10061 * i386-low.h: Renamed as...
10062 * x86-low.h: New file. All type, function and variable name
10063 prefixes changed from "i386_" to "x86_". All references updated.
10064 * i386-low.c: Renamed as...
10065 * x86-low.c: New file. All type, function and variable name
10066 prefixes changed from "i386_" to "x86_". All references updated.
10067
10068 2014-09-02 Gary Benson <gbenson@redhat.com>
10069
10070 * linux-x86-low.c (x86_linux_new_process): Use XCNEW.
10071 (x86_linux_new_thread): Likewise.
10072
10073 2014-08-29 Gary Benson <gbenson@redhat.com>
10074
10075 * server.h (setjmp.h): Do not include.
10076 (toplevel): Do not declare.
10077 (common-exceptions.h): Include.
10078 (cleanups.h): Likewise.
10079 * server.c (toplevel): Do not define.
10080 (exit_code): New static global.
10081 (detach_or_kill_for_exit_cleanup): New function.
10082 (main): New function. Original main renamed to...
10083 (captured_main): New function.
10084 * utils.c (verror) [!IN_PROCESS_AGENT]: Use throw_verror.
10085
10086 2014-08-29 Gary Benson <gbenson@redhat.com>
10087
10088 * Makefile.in (SFILES): Add common/common-exceptions.c.
10089 (OBS): Add common-exceptions.o.
10090 (common-exceptions.o): New rule.
10091 * utils.c (prepare_to_throw_exception): New function.
10092
10093 2014-08-29 Gary Benson <gbenson@redhat.com>
10094
10095 * config.in: Regenerate.
10096 * configure: Likewise.
10097
10098 2014-08-29 Gary Benson <gbenson@redhat.com>
10099
10100 * Makefile.in (SFILES): Add common/cleanups.c.
10101 (OBS): cleanups.o.
10102 (cleanups.o): New rule.
10103
10104 2014-08-29 Gary Benson <gbenson@redhat.com>
10105
10106 * utils.c (internal_vwarning): New function.
10107
10108 2014-08-28 Gary Benson <gbenson@redhat.com>
10109
10110 * utils.h (fatal): Remove declaration.
10111 * utils.c (fatal): Remove function.
10112
10113 2014-08-28 Gary Benson <gbenson@redhat.com>
10114
10115 * tracepoint.c (gdb_agent_init): Replace fatal with
10116 perror_with_name.
10117 (initialize_tracepoint): Likewise.
10118
10119 2014-08-28 Gary Benson <gbenson@redhat.com>
10120
10121 * remote-utils.c (remote_prepare): Replace fatal with error.
10122
10123 2014-08-28 Gary Benson <gbenson@redhat.com>
10124
10125 * linux-low.c (linux_async): Replace fatal with warning.
10126 Tidy up and return.
10127 (linux_start_non_stop): Return -1 if linux_async failed.
10128
10129 2014-08-28 Gary Benson <gbenson@redhat.com>
10130
10131 * linux-x86-low.c (i386_dr_low_set_addr): Replace check with
10132 gdb_assert.
10133 (i386_dr_low_get_addr): Remove vague comment.
10134 * win32-i386-low.c (i386_dr_low_set_addr): Replace check with
10135 gdb_assert.
10136
10137 2014-08-28 Gary Benson <gbenson@redhat.com>
10138
10139 * inferiors.c (get_thread_process): Replace check with gdb_assert.
10140 * linux-low.c (linux_wait_for_event_filtered): Replace fatal with
10141 internal_error.
10142 (linux_resume_one_lwp): Likewise.
10143 * linux-x86-low.c (x86_siginfo_fixup): Replace checks with
10144 gdb_assert.
10145 * mem-break.c (raw_bkpt_type_to_target_hw_bp_type): Replace fatal
10146 with internal_error.
10147 * regcache.c (get_thread_regcache): Replace check with gdb_assert.
10148 (init_register_cache): Replace fatal with gdb_assert_not_reached.
10149 (find_register_by_name): Replace fatal with internal_error.
10150 (find_regno): Likewise.
10151 * tdesc.c (init_target_desc): Replace check with gdb_assert.
10152 * thread-db.c (thread_db_create_event): Likewise.
10153 (thread_db_load_search): Likewise.
10154 (try_thread_db_load_1): Likewise.
10155 * tracepoint.c (get_jump_space_head): Replace fatal with
10156 internal_error.
10157 (claim_trampoline_space): Likewise.
10158 (have_fast_tracepoint_trampoline_buffer): Likewise.
10159 (cmd_qtstart): Likewise.
10160 (stop_tracing): Likewise.
10161 (fast_tracepoint_collecting): Likewise.
10162 (target_malloc): Likewise.
10163 (download_tracepoint): Likewise.
10164 (download_trace_state_variables): Replace check with gdb_assert.
10165 (upload_fast_traceframes): Replace fatal with internal_error.
10166
10167 2014-08-19 Tom Tromey <tromey@redhat.com>
10168 Gary Benson <gbenson@redhat.com>
10169
10170 * Makefile.in (SFILES): Add common/common-debug.c.
10171 (OBS): Add common-debug.o.
10172 (common-debug.o): New rule.
10173 * debug.h (debug_printf): Don't declare.
10174 * debug.c (debug_printf): Renamed and rewritten as...
10175 (debug_vprintf): New function.
10176
10177 2014-08-19 Gary Benson <gbenson@redhat.com>
10178
10179 * utils.h: Do not include print-utils.h.
10180
10181 2014-08-19 Tom Tromey <tromey@redhat.com>
10182 Gary Benson <gbenson@redhat.com>
10183
10184 * server.h: Add static assertion.
10185 (gdb_byte, CORE_ADDR, LONGEST, ULONGEST): Remove.
10186
10187 2014-08-19 Tom Tromey <tromey@redhat.com>
10188 Gary Benson <gbenson@redhat.com>
10189
10190 * Makefile.in (SFILES): Add common/errors.c.
10191 (OBS): Add errors.o.
10192 (IPA_OBS): Add errors-ipa.o.
10193 (errors.o): New rule.
10194 (errors-ipa.o): Likewise.
10195 * utils.h (perror_with_name, error, warning): Don't declare.
10196 * utils.c (warning): Renamed and rewritten as...
10197 (vwarning): New function.
10198 (error): Renamed and rewritten as...
10199 (verror): New function.
10200 (internal_error): Renamed and rewritten as...
10201 (internal_verror): New function.
10202
10203 2014-08-07 Gary Benson <gbenson@redhat.com>
10204
10205 * configure.ac (AC_CHECK_HEADERS): Remove errno.h.
10206 * configure: Regenerate.
10207 * config.in: Likewise.
10208 * server.h: Do not include errno.h.
10209 * event-loop.c: Likewise.
10210 * hostio-errno.c: Likewise.
10211 * linux-low.c: Likewise.
10212 * remote-utils.c: Likewise.
10213 * spu-low.c: Likewise.
10214 * utils.c: Likewise.
10215 * gdbreplay.c: Unconditionally include errno.h.
10216
10217 2014-08-07 Gary Benson <gbenson@redhat.com>
10218
10219 * server.h: Do not include string.h.
10220 * event-loop.c: Likewise.
10221 * linux-low.c: Likewise.
10222 * regcache.c: Likewise.
10223 * remote-utils.c: Likewise.
10224 * spu-low.c: Likewise.
10225 * utils.c: Likewise.
10226
10227 2014-08-07 Gary Benson <gbenson@redhat.com>
10228
10229 * server.h: Do not include gdb_assert.h.
10230
10231 2014-08-07 Gary Benson <gbenson@redhat.com>
10232
10233 * server.h: Do not include common-utils.h.
10234
10235 2014-08-07 Gary Benson <gbenson@redhat.com>
10236
10237 * server.h: Do not include ptid.h.
10238 * notif.h: Likewise.
10239
10240 2014-08-07 Gary Benson <gbenson@redhat.com>
10241
10242 * server.h: Do not include gdb_locale.h.
10243
10244 2014-08-07 Gary Benson <gbenson@redhat.com>
10245
10246 * server.h: Do not include gdb/signals.h.
10247 * win32-low.c: Likewise.
10248
10249 2014-08-07 Gary Benson <gbenson@redhat.com>
10250
10251 * server.h: Do not include pathmax.h.
10252
10253 2014-08-07 Gary Benson <gbenson@redhat.com>
10254
10255 * server.h: Do not include libiberty.h.
10256 * linux-bfin-low.c: Likewise.
10257
10258 2014-08-07 Gary Benson <gbenson@redhat.com>
10259
10260 * server.h: Do not include ansidecl.h.
10261
10262 2014-08-07 Gary Benson <gbenson@redhat.com>
10263
10264 * linux-x86-low.c: Do not include stddef.h.
10265 * lynx-ppc-low.c: Likewise.
10266 * tracepoint.c: Likewise.
10267
10268 2014-08-07 Gary Benson <gbenson@redhat.com>
10269
10270 * server.h: Do not include stdarg.h.
10271 * nto-low.c: Likewise.
10272
10273 2014-08-07 Gary Benson <gbenson@redhat.com>
10274
10275 * server.h: Do not include stdlib.h.
10276 * inferiors.c: Likewise.
10277 * linux-low.c: Likewise.
10278 * regcache.c: Likewise.
10279 * spu-low.c: Likewise.
10280 * tracepoint.c: Likewise.
10281 * utils.c: Likewise.
10282
10283 2014-08-07 Gary Benson <gbenson@redhat.com>
10284
10285 * server.h: Do not include stdio.h.
10286 * linux-low.c: Likewise.
10287 * remote-utils.c: Likewise.
10288 * spu-low.c: Likewise.
10289 * utils.c: Likewise.
10290 * wincecompat.c: Likewise.
10291
10292 2014-08-06 Gary Benson <gbenson@redhat.com>
10293
10294 * regcache.c (init_register_cache): Move conditionals inside if.
10295
10296 2014-08-06 Gary Benson <gbenson@redhat.com>
10297
10298 * linux-low.c (linux_supports_non_stop): Use target_is_async_p.
10299
10300 2014-07-31 Gary Benson <gbenson@redhat.com>
10301
10302 * ax.h: Do not include server.h.
10303 * gdbthread.h: Likewise.
10304 * lynx-low.h: Likewise.
10305 * notif.h: Likewise.
10306
10307 2014-07-30 Gary Benson <gbenson@redhat.com>
10308
10309 * server.h: Include common-defs.h.
10310 Do not include config.h or build-gnulib-gdbserver/config.h.
10311
10312 2014-07-30 Gary Benson <gbenson@redhat.com>
10313
10314 * hostio-errno.c: Move server.h to top of includes list.
10315 * inferiors.c: Likewise.
10316 * linux-x86-low.c: Likewise.
10317 * notif.c: Include server.h.
10318
10319 2014-07-24 Tom Tromey <tromey@redhat.com>
10320 Gary Benson <gbenson@redhat.com>
10321
10322 * server.h (CORE_ADDR): Now unsigned.
10323
10324 2014-07-16 Pedro Alves <palves@redhat.com>
10325
10326 * linux-low.c (linux_kill_one_lwp): Use kill_lwp, not kill.
10327
10328 2014-07-15 Pedro Alves <palves@redhat.com>
10329
10330 * linux-low.c (linux_kill_one_lwp): Save errno and work with saved
10331 copy.
10332
10333 2014-07-11 Pedro Alves <palves@redhat.com>
10334
10335 * linux-low.c (kill_wait_lwp): New function, based on
10336 kill_one_lwp_callback, but use my_waitpid directly.
10337 (kill_one_lwp_callback, linux_kill): Use it.
10338
10339 2014-06-23 Pedro Alves <palves@redhat.com>
10340
10341 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR_CONTROL
10342 before setting DR0..DR3.
10343
10344 2014-06-20 Gary Benson <gbenson@redhat.com>
10345
10346 * configure.ac (AC_REPLACE_FUNCS) <vasprintf, vsnprintf>: Removed.
10347 * configure: Regenerated.
10348 * config.in: Likewise.
10349
10350 2014-06-20 Gary Benson <gbenson@redhat.com>
10351
10352 * Makefile.in (SFILES): Update locations for files moved
10353 from common to nat.
10354 (object file files): Reordered.
10355
10356 2014-06-20 Gary Benson <gbenson@redhat.com>
10357
10358 * i386-low.h (i386_dr_low_can_set_addr): Removed.
10359 (i386_dr_low_set_addr): Likewise.
10360 (i386_dr_low_get_addr): Likewise.
10361 (i386_dr_low_can_set_control): Likewise.
10362 (i386_dr_low_set_control): Likewise.
10363 (i386_dr_low_get_control): Likewise.
10364 (i386_dr_low_get_status): Likewise.
10365 (i386_get_debug_register_length): Likewise.
10366 * linux-x86-low.c (i386_dr_low_set_addr):
10367 Changed signature. Made static.
10368 (i386_dr_low_get_addr): Likewise.
10369 (i386_dr_low_set_control): Likewise.
10370 (i386_dr_low_get_control): Likewise.
10371 (i386_dr_low_get_status): Likewise.
10372 (i386_dr_low): New global variable.
10373 * win32-i386-low.c (i386_dr_low_set_addr):
10374 Changed signature. Made static.
10375 (i386_dr_low_get_addr): Likewise.
10376 (i386_dr_low_set_control): Likewise.
10377 (i386_dr_low_get_control): Likewise.
10378 (i386_dr_low_get_status): Likewise.
10379 (i386_dr_low): New global variable.
10380
10381 2014-06-20 Marcus Shawcroft <marcus.shawcroft@arm.com>
10382
10383 * configure.ac: Invoke. AC_CHECK_TOOL(AR, ar).
10384 * Makefile.in (AR, AR_FLAGS): Define.
10385 * configure: Regenerate.
10386
10387 2014-06-19 Gary Benson <gbenson@redhat.com>
10388
10389 * Makefile.in (i386-dregs.o): New rule.
10390 * configure.srv: Add i386-dregs.o to all targets using i386-low.o.
10391 * i386-low.c (target.h): Remove include.
10392 (TARGET_HAS_DR_LEN_8): Now in i386-dregs.c.
10393 (DR_CONTROL_SHIFT): Likewise.
10394 (DR_CONTROL_SIZE): Likewise.
10395 (DR_RW_EXECUTE): Likewise.
10396 (DR_RW_WRITE): Likewise.
10397 (DR_RW_READ): Likewise.
10398 (DR_RW_IORW): Likewise.
10399 (DR_LEN_1): Likewise.
10400 (DR_LEN_2): Likewise.
10401 (DR_LEN_4): Likewise.
10402 (DR_LEN_8): Likewise.
10403 (DR_LOCAL_ENABLE_SHIFT): Likewise.
10404 (DR_GLOBAL_ENABLE_SHIFT): Likewise.
10405 (DR_ENABLE_SIZE): Likewise.
10406 (DR_LOCAL_SLOWDOWN): Likewise.
10407 (DR_GLOBAL_SLOWDOWN): Likewise.
10408 (DR_CONTROL_RESERVED): Likewise.
10409 (I386_DR_CONTROL_MASK): Likewise.
10410 (I386_DR_VACANT): Likewise.
10411 (I386_DR_LOCAL_ENABLE): Likewise.
10412 (I386_DR_GLOBAL_ENABLE): Likewise.
10413 (I386_DR_DISABLE): Likewise.
10414 (I386_DR_SET_RW_LEN): Likewise.
10415 (I386_DR_GET_RW_LEN): Likewise.
10416 (I386_DR_WATCH_HIT): Likewise.
10417 (i386_wp_op_t): Likewise.
10418 (i386_show_dr): Likewise.
10419 (i386_length_and_rw_bits): Likewise.
10420 (i386_insert_aligned_watchpoint): Likewise.
10421 (i386_remove_aligned_watchpoint): Likewise.
10422 (i386_handle_nonaligned_watchpoint): Likewise.
10423 i386_update_inferior_debug_regs(): Likewise.
10424 (i386_dr_insert_watchpoint): Likewise.
10425 (i386_dr_remove_watchpoint): Likewise.
10426 (i386_dr_region_ok_for_watchpoint): Likewise.
10427 (i386_dr_stopped_data_address): Likewise.
10428 (i386_dr_stopped_by_watchpoint): Likewise.
10429
10430 2014-06-19 Gary Benson <gbenson@redhat.com>
10431
10432 * i386-low.c (i386_dr_show): Renamed to
10433 i386_show_dr and made static. All uses updated.
10434 (i386_dr_length_and_rw_bits): Renamed to
10435 i386_length_and_rw_bits and made static.
10436 All uses updated.
10437 (i386_dr_insert_aligned_watchpoint): Renamed to
10438 i386_insert_aligned_watchpoint and made static.
10439 All uses updated.
10440 (i386_dr_remove_aligned_watchpoint): Renamed to
10441 i386_remove_aligned_watchpoint and made static.
10442 All uses updated.
10443 (i386_dr_update_inferior_debug_regs): Renamed to
10444 i386_update_inferior_debug_regs and made static.
10445 All uses updated.
10446
10447 2014-06-18 Gary Benson <gbenson@redhat.com>
10448
10449 * i386-low.h (i386_dr_low_can_set_addr): New macro.
10450 (i386_dr_low_can_set_control): Likewise.
10451 (i386_get_debug_register_length): Likewise.
10452 * i386-low.c (i386_dr_low_can_set_addr): Now in i386-low.h.
10453 (i386_dr_low_can_set_control): Likewise.
10454 (i386_get_debug_register_length): Likewise.
10455
10456 2014-06-17 Gary Benson <gbenson@redhat.com>
10457
10458 * i386-low.h (i386-dregs.h): New include.
10459 (DR_FIRSTADDR): Now in i386-dregs.h.
10460 (DR_LASTADDR): Likewise.
10461 (DR_NADDR): Likewise.
10462 (DR_STATUS): Likewise.
10463 (DR_CONTROL): Likewise.
10464 (i386_debug_reg_state): Likewise.
10465 (i386_dr_insert_watchpoint): Likewise.
10466 (i386_dr_remove_watchpoint): Likewise.
10467 (i386_dr_region_ok_for_watchpoint): Likewise.
10468 (i386_dr_stopped_data_address): Likewise.
10469 (i386_dr_stopped_by_watchpoint): Likewise.
10470 * i386-low.c (ALL_DEBUG_REGISTERS): Likewise.
10471
10472 2014-06-18 Gary Benson <gbenson@redhat.com>
10473
10474 * i386-low.h (i386_low_insert_watchpoint): Renamed to
10475 i386_dr_insert_watchpoint.
10476 (i386_low_remove_watchpoint): Renamed to
10477 i386_dr_remove_watchpoint.
10478 (i386_low_region_ok_for_watchpoint): Renamed to
10479 i386_dr_region_ok_for_watchpoint.
10480 (i386_low_stopped_data_address): Renamed to
10481 i386_dr_stopped_data_address.
10482 (i386_low_stopped_by_watchpoint): Renamed to
10483 i386_dr_stopped_by_watchpoint.
10484 * i386-low.c (i386_show_dr): Renamed to
10485 i386_dr_show and made nonstatic. All uses updated.
10486 (i386_length_and_rw_bits): Renamed to
10487 i386_dr_length_and_rw_bits and made nonstatic.
10488 All uses updated.
10489 (i386_insert_aligned_watchpoint): Renamed to
10490 i386_dr_insert_aligned_watchpoint and made nonstatic.
10491 All uses updated.
10492 (i386_remove_aligned_watchpoint): Renamed to
10493 i386_dr_remove_aligned_watchpoint and made nonstatic.
10494 All uses updated.
10495 (i386_update_inferior_debug_regs): Renamed to
10496 i386_dr_update_inferior_debug_regs and made nonstatic.
10497 All uses updated.
10498 (i386_low_insert_watchpoint): Renamed to
10499 i386_dr_insert_watchpoint. All uses updated.
10500 (i386_low_remove_watchpoint): Renamed to
10501 i386_dr_remove_watchpoint. All uses updated.
10502 (i386_low_region_ok_for_watchpoint): Renamed to
10503 i386_dr_region_ok_for_watchpoint. All uses updated.
10504 (i386_low_stopped_data_address): Renamed to
10505 i386_dr_stopped_data_address. All uses updated.
10506 (i386_low_stopped_by_watchpoint): Renamed to
10507 i386_dr_stopped_by_watchpoint. All uses updated.
10508
10509 2014-06-18 Gary Benson <gbenson@redhat.com>
10510
10511 * i386-low.c (i386_dr_low_can_set_addr): New macro.
10512 (i386_dr_low_can_set_control): Likewise.
10513 (i386_insert_aligned_watchpoint): New check.
10514
10515 2014-06-18 Gary Benson <gbenson@redhat.com>
10516
10517 * i386-low.c (i386_update_inferior_debug_regs) <inf_state>:
10518 Renamed to state.
10519
10520 2014-06-18 Gary Benson <gbenson@redhat.com>
10521
10522 * i386-low.c (i386_length_and_rw_bits): Use internal_error
10523 instead of fatal and error.
10524 (i386_handle_nonaligned_watchpoint): Likewise.
10525
10526 2014-06-18 Gary Benson <gbenson@redhat.com>
10527
10528 * i386-low.c (i386_get_debug_register_length): New macro.
10529 (TARGET_HAS_DR_LEN_8): Remove conditional. Use above macro.
10530 (i386_show_dr): Use debug_printf instead of fprintf. Use
10531 phex to format values.
10532
10533 2014-06-18 Gary Benson <gbenson@redhat.com>
10534
10535 * i386-low.h: Comment changes.
10536 * i386-low.c: Likewise.
10537
10538 2014-06-18 Gary Benson <gbenson@redhat.com>
10539
10540 * i386-low.c: Whitespace changes.
10541
10542 2014-06-12 Tom Tromey <tromey@redhat.com>
10543
10544 * utils.c (freeargv): Remove.
10545
10546 2014-06-12 Tom Tromey <tromey@redhat.com>
10547
10548 * debug.c (debug_printf): Remove HAVE_GETTIMEOFDAY checks.
10549 * server.c (monitor_show_help): Remove HAVE_GETTIMEOFDAY check.
10550 (parse_debug_format_options): Likewise.
10551 (gdbserver_usage): Likewise.
10552 * Makefile.in (LIBIBERTY_BUILDDIR, LIBIBERTY): New variables.
10553 (SUBDIRS, REQUIRED_SUBDIRS): Add libiberty.
10554 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Depend on and link
10555 against libiberty.
10556 ($(LIBGNU)): Depend on libiberty.
10557 (all-lib): Recurse into all subdirs.
10558 (install-only): Invoke "install" target in subdirs.
10559 (vasprintf.o, vsnprintf.o, safe-ctype.o, lbasename.o): Remove
10560 targets.
10561 * configure: Rebuild.
10562 * configure.ac: Add ACX_CONFIGURE_DIR for libiberty. Don't check
10563 for vasprintf, vsnprintf, or gettimeofday.
10564 * configure.srv: Don't add safe-ctype.o or lbasename.o to
10565 srv_tgtobj.
10566
10567 2014-06-05 Joel Brobecker <brobecker@adacore.com>
10568
10569 * development.sh: Delete.
10570 * Makefile.in (config.status): Adjust dependency on development.sh.
10571 * configure.ac: Adjust development.sh source call.
10572 * configure: Regenerate.
10573
10574 2014-06-02 Pedro Alves <palves@redhat.com>
10575
10576 * ax.c (gdb_free_agent_expr): New function.
10577 * ax.h (gdb_free_agent_expr): New declaration.
10578 * mem-break.c (delete_gdb_breakpoint_1): Also clear the commands
10579 list.
10580 (clear_breakpoint_conditions, clear_breakpoint_commands): Make
10581 static.
10582 (clear_breakpoint_conditions_and_commands): New function.
10583 * mem-break.h (clear_breakpoint_conditions): Delete declaration.
10584 (clear_breakpoint_conditions_and_commands): New declaration.
10585
10586 2014-05-23 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
10587
10588 * linux-aarch64-low.c (asm/ptrace.h): Include.
10589
10590 2014-05-21 Jan Kratochvil <jan.kratochvil@redhat.com>
10591
10592 Fix TLS access for -static -pthread.
10593 * gdbserver/thread-db.c (struct thread_db): Add td_thr_tlsbase_p.
10594 (thread_db_get_tls_address): Call it if LOAD_MODULE is zero.
10595 (thread_db_load_search, try_thread_db_load_1): Initialize it.
10596
10597 2014-05-20 Pedro Alves <palves@redhat.com>
10598
10599 * linux-aarch64-low.c (aarch64_insert_point)
10600 (aarch64_remove_point): No longer check whether the type is
10601 supported here. Adjust to new interface.
10602 (the_low_target): Install aarch64_supports_z_point_type as
10603 supports_z_point_type method.
10604 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type): New function.
10605 (arm_linux_hw_point_initialize): Take an enum raw_bkpt_type
10606 instead of a Z packet char. Adjust.
10607 (arm_supports_z_point_type): New function.
10608 (arm_insert_point, arm_remove_point): Adjust to new interface.
10609 (the_low_target): Install arm_supports_z_point_type.
10610 * linux-crisv32-low.c (cris_supports_z_point_type): New function.
10611 (cris_insert_point, cris_remove_point): Adjust to new interface.
10612 Don't check whether the type is supported here.
10613 (the_low_target): Install cris_supports_z_point_type.
10614 * linux-low.c (linux_supports_z_point_type): New function.
10615 (linux_insert_point, linux_remove_point): Adjust to new interface.
10616 * linux-low.h (struct linux_target_ops) <insert_point,
10617 remove_point>: Take an enum raw_bkpt_type instead of a char. Add
10618 raw_breakpoint pointer parameter.
10619 <supports_z_point_type>: New method.
10620 * linux-mips-low.c (mips_supports_z_point_type): New function.
10621 (mips_insert_point, mips_remove_point): Adjust to new interface.
10622 Use mips_supports_z_point_type.
10623 (the_low_target): Install mips_supports_z_point_type.
10624 * linux-ppc-low.c (the_low_target): Install NULL as
10625 supports_z_point_type method.
10626 * linux-s390-low.c (the_low_target): Install NULL as
10627 supports_z_point_type method.
10628 * linux-sparc-low.c (the_low_target): Install NULL as
10629 supports_z_point_type method.
10630 * linux-x86-low.c (x86_supports_z_point_type): New function.
10631 (x86_insert_point): Adjust to new insert_point interface. Use
10632 insert_memory_breakpoint. Adjust to new
10633 i386_low_insert_watchpoint interface.
10634 (x86_remove_point): Adjust to remove_point interface. Use
10635 remove_memory_breakpoint. Adjust to new
10636 i386_low_remove_watchpoint interface.
10637 (the_low_target): Install x86_supports_z_point_type.
10638 * lynx-low.c (lynx_target_ops): Install NULL as
10639 supports_z_point_type callback.
10640 * nto-low.c (nto_supports_z_point_type): New.
10641 (nto_insert_point, nto_remove_point): Adjust to new interface.
10642 (nto_target_ops): Install nto_supports_z_point_type.
10643 * mem-break.c: Adjust intro comment.
10644 (struct raw_breakpoint) <raw_type, size>: New fields.
10645 <inserted>: Update comment.
10646 <shlib_disabled>: Delete field.
10647 (enum bkpt_type) <gdb_breakpoint>: Delete value.
10648 <gdb_breakpoint_Z0, gdb_breakpoint_Z1, gdb_breakpoint_Z2,
10649 gdb_breakpoint_Z3, gdb_breakpoint_Z4>: New values.
10650 (raw_bkpt_type_to_target_hw_bp_type): New function.
10651 (find_enabled_raw_code_breakpoint_at): New function.
10652 (find_raw_breakpoint_at): New type and size parameters. Use them.
10653 (insert_memory_breakpoint): New function, based off
10654 set_raw_breakpoint_at.
10655 (remove_memory_breakpoint): New function.
10656 (set_raw_breakpoint_at): Reimplement.
10657 (set_breakpoint): New, based on set_breakpoint_at.
10658 (set_breakpoint_at): Reimplement.
10659 (delete_raw_breakpoint): Go through the_target->remove_point
10660 instead of assuming memory breakpoints.
10661 (find_gdb_breakpoint_at): Delete.
10662 (Z_packet_to_bkpt_type, Z_packet_to_raw_bkpt_type): New functions.
10663 (find_gdb_breakpoint): New function.
10664 (set_gdb_breakpoint_at): Delete.
10665 (z_type_supported): New function.
10666 (set_gdb_breakpoint_1): New function, loosely based off
10667 set_gdb_breakpoint_at.
10668 (check_gdb_bp_preconditions, set_gdb_breakpoint): New functions.
10669 (delete_gdb_breakpoint_at): Delete.
10670 (delete_gdb_breakpoint_1): New function, loosely based off
10671 delete_gdb_breakpoint_at.
10672 (delete_gdb_breakpoint): New function.
10673 (clear_gdb_breakpoint_conditions): Rename to ...
10674 (clear_breakpoint_conditions): ... this. Don't handle a NULL
10675 breakpoint.
10676 (add_condition_to_breakpoint): Make static.
10677 (add_breakpoint_condition): Take a struct breakpoint pointer
10678 instead of an address. Adjust.
10679 (gdb_condition_true_at_breakpoint): Rename to ...
10680 (gdb_condition_true_at_breakpoint_z_type): ... this, and add
10681 z_type parameter.
10682 (gdb_condition_true_at_breakpoint): Reimplement.
10683 (add_breakpoint_commands): Take a struct breakpoint pointer
10684 instead of an address. Adjust.
10685 (gdb_no_commands_at_breakpoint): Rename to ...
10686 (gdb_no_commands_at_breakpoint_z_type): ... this. Add z_type
10687 parameter. Return true if no breakpoint was found. Change debug
10688 output.
10689 (gdb_no_commands_at_breakpoint): Reimplement.
10690 (run_breakpoint_commands): Rename to ...
10691 (run_breakpoint_commands_z_type): ... this. Add z_type parameter,
10692 and change return type to boolean.
10693 (run_breakpoint_commands): New function.
10694 (gdb_breakpoint_here): Also check for Z1 breakpoints.
10695 (uninsert_raw_breakpoint): Don't try to reinsert a disabled
10696 breakpoint. Go through the_target->remove_point instead of
10697 assuming memory breakpoint.
10698 (uninsert_breakpoints_at, uninsert_all_breakpoints): Uninsert
10699 software and hardware breakpoints.
10700 (reinsert_raw_breakpoint): Go through the_target->insert_point
10701 instead of assuming memory breakpoint.
10702 (reinsert_breakpoints_at, reinsert_all_breakpoints): Reinsert
10703 software and hardware breakpoints.
10704 (check_breakpoints, breakpoint_here, breakpoint_inserted_here):
10705 Check both software and hardware breakpoints.
10706 (validate_inserted_breakpoint): Assert the breakpoint is a
10707 software breakpoint. Set the inserted flag to -1 instead of
10708 setting shlib_disabled.
10709 (delete_disabled_breakpoints): Adjust.
10710 (validate_breakpoints): Only validate software breakpoints.
10711 Adjust to inserted flag change.
10712 (check_mem_read, check_mem_write): Skip breakpoint types other
10713 than software breakpoints. Adjust to inserted flag change.
10714 * mem-break.h (enum raw_bkpt_type): New enum.
10715 (raw_breakpoint, struct process_info): Forward declare.
10716 (Z_packet_to_target_hw_bp_type): Delete declaration.
10717 (raw_bkpt_type_to_target_hw_bp_type, Z_packet_to_raw_bkpt_type)
10718 (set_gdb_breakpoint, delete_gdb_breakpoint)
10719 (clear_breakpoint_conditions): New declarations.
10720 (set_gdb_breakpoint_at, clear_gdb_breakpoint_conditions): Delete.
10721 (breakpoint_inserted_here): Update comment.
10722 (add_breakpoint_condition, add_breakpoint_commands): Replace
10723 address parameter with a breakpoint pointer parameter.
10724 (gdb_breakpoint_here): Update comment.
10725 (delete_gdb_breakpoint_at): Delete.
10726 (insert_memory_breakpoint, remove_memory_breakpoint): Declare.
10727 * server.c (process_point_options): Take a struct breakpoint
10728 pointer instead of an address. Adjust.
10729 (process_serial_event) <Z/z packets>: Use set_gdb_breakpoint and
10730 delete_gdb_breakpoint.
10731 * spu-low.c (spu_target_ops): Install NULL as
10732 supports_z_point_type method.
10733 * target.h: Include mem-break.h.
10734 (struct target_ops) <prepare_to_access_memory>: Update comment.
10735 <supports_z_point_type>: New field.
10736 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
10737 instead of a char. Also take a raw breakpoint pointer.
10738 * win32-arm-low.c (the_low_target): Install NULL as
10739 supports_z_point_type.
10740 * win32-i386-low.c (i386_supports_z_point_type): New function.
10741 (i386_insert_point, i386_remove_point): Adjust to new interface.
10742 (the_low_target): Install i386_supports_z_point_type.
10743 * win32-low.c (win32_supports_z_point_type): New function.
10744 (win32_insert_point, win32_remove_point): Adjust to new interface.
10745 (win32_target_ops): Install win32_supports_z_point_type.
10746 * win32-low.h (struct win32_target_ops):
10747 <supports_z_point_type>: New method.
10748 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
10749 instead of a char. Also take a raw breakpoint pointer.
10750
10751 2014-05-20 Pedro Alves <palves@redhat.com>
10752
10753 * mem-break.h: Include break-common.h.
10754 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
10755 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): New defines.
10756 (Z_packet_to_target_hw_bp_type): New declaration.
10757 * mem-break.c (Z_packet_to_target_hw_bp_type): New function.
10758 * i386-low.c (Z_PACKET_HW_BP, Z_PACKET_WRITE_WP, Z_PACKET_READ_WP)
10759 (Z_PACKET_ACCESS_WP): Delete macros.
10760 (Z_packet_to_hw_type): Delete function.
10761 * i386-low.h: Don't include break-common.h here.
10762 (Z_packet_to_hw_type): Delete declaration.
10763 * linux-x86-low.c (x86_insert_point, x86_insert_point): Call
10764 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
10765 * win32-i386-low.c (i386_insert_point, i386_remove_point): Call
10766 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
10767 * linux-aarch64-low.c: Don't include break-common.h here.
10768 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
10769 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): Delete macros.
10770 (Z_packet_to_target_hw_bp_type): Delete function.
10771 * linux-mips-low.c (rsp_bp_type_to_target_hw_bp_type): Delete
10772 function.
10773 (mips_insert_point, mips_remove_point): Use
10774 Z_packet_to_target_hw_bp_type.
10775
10776 2014-05-20 Pedro Alves <palves@redhat.com>
10777
10778 * linux-aarch64-low.c: Include break-common.h.
10779 (enum target_point_type): Delete.
10780 (Z_packet_to_point_type): Rename to ...
10781 (Z_packet_to_target_hw_bp_type): ... this, and return a
10782 target_hw_bp_type instead.
10783 (aarch64_show_debug_reg_state): Take an enum target_hw_bp_type
10784 instead of an enum target_point_type.
10785 (aarch64_point_encode_ctrl_reg): Likewise. Compute type mask from
10786 breakpoint type.
10787 (aarch64_dr_state_insert_one_point)
10788 (aarch64_dr_state_remove_one_point, aarch64_handle_breakpoint)
10789 (aarch64_handle_aligned_watchpoint)
10790 (aarch64_handle_unaligned_watchpoint, aarch64_handle_watchpoint):
10791 Take an enum target_hw_bp_type instead of an enum
10792 target_point_type.
10793 (aarch64_supports_z_point_type): New function.
10794 (aarch64_insert_point, aarch64_remove_point): Use it. Adjust to
10795 use Z_packet_to_target_hw_bp_type.
10796
10797 2014-05-20 Joel Brobecker <brobecker@adacore.com>
10798
10799 * configure.ac: Only use -Werror by default when DEVELOPMENT
10800 is true.
10801 * configure: Regenerate.
10802
10803 2014-05-19 Jan Kratochvil <jan.kratochvil@redhat.com>
10804
10805 Fix gdbserver qGetTLSAddr for x86_64 -m32.
10806 * linux-x86-low.c (X86_64_USER_REGS): New.
10807 (x86_fill_gregset): Call memset for BUF first in x86_64 -m32 case.
10808
10809 2014-04-28 Yao Qi <yao@codesourcery.com>
10810
10811 * Makefile.in (i386-avx512.c): Fix the typo of generated file
10812 name.
10813
10814 2014-04-25 Pedro Alves <palves@redhat.com>
10815
10816 PR server/16255
10817 * linux-low.c (linux_attach_fail_reason_string): New function.
10818 (linux_attach_lwp): Delete.
10819 (linux_attach_lwp_1): Rename to ...
10820 (linux_attach_lwp): ... this. Take a ptid instead of a pid as
10821 argument. Remove "initial" parameter. Return int instead of
10822 void. Don't error or warn here.
10823 (linux_attach): Adjust to call linux_attach_lwp. Call error on
10824 failure to attach to the tgid. Call warning when failing to
10825 attach to an lwp.
10826 * linux-low.h (linux_attach_lwp): Take a ptid instead of a pid as
10827 argument. Remove "initial" parameter. Return int instead of
10828 void. Don't error or warn here.
10829 (linux_attach_fail_reason_string): New declaration.
10830 * thread-db.c (attach_thread): Adjust to linux_attach_lwp's
10831 interface change. Use linux_attach_fail_reason_string.
10832
10833 2014-04-24 Michael Sturm <michael.sturm@mintel.com>
10834 Walfred Tedeschi <walfred.tedeschi@intel.com>
10835
10836 * Makefile.in: Added rules to handle new files
10837 i386-avx512.c i386-avx512-linux.c amd64-avx512.c
10838 amd64-avx512-linux.c x32-avx512.c x32-avx512-linux.c.
10839 * configure.srv (srv_i386_regobj): Add i386-avx512.o.
10840 (srv_i386_linux_regobj): Add i386-avx512-linux.o.
10841 (srv_amd64_regobj): Add amd64-avx512.o and x32-avx512.o.
10842 (srv_amd64_linux_regobj): Add amd64-avx512-linux.o and
10843 x32-avx512-linux.o.
10844 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx512.xml.
10845 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx512.xml.
10846 (srv_amd64_xmlfiles): Add i386/amd64-avx512.xml and
10847 i386/x32-avx512.xml.
10848 (srv_i386_linux_xmlfiles): Add i386/i386-avx512-linux.xml.
10849 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx512-linux.xml and
10850 i386/x32-avx512-linux.xml.
10851 * i387-fp.c (num_avx512_k_registers): New constant for number
10852 of K registers.
10853 (num_avx512_zmmh_low_registers): New constant for number of
10854 lower ZMM registers (0-15).
10855 (num_avx512_zmmh_high_registers): New constant for number of
10856 higher ZMM registers (16-31).
10857 (num_avx512_ymmh_registers): New contant for number of higher
10858 YMM registers (ymm16-31 added by avx521 on x86_64).
10859 (num_avx512_xmm_registers): New constant for number of higher
10860 XMM registers (xmm16-31 added by AVX512 on x86_64).
10861 (struct i387_xsave): Add space for AVX512 registers.
10862 (i387_cache_to_xsave): Change raw buffer size to 64 characters.
10863 Add code to handle AVX512 registers.
10864 (i387_xsave_to_cache): Add code to handle AVX512 registers.
10865 * linux-x86-low.c (init_registers_amd64_avx512_linux): New
10866 prototypei from generated file.
10867 (tdesc_amd64_avx512_linux): Likewise.
10868 (init_registers_x32_avx512_linux): Likewise.
10869 (tdesc_x32_avx512_linux): Likewise.
10870 (init_registers_i386_avx512_linux): Likewise.
10871 (tdesc_i386_avx512_linux): Likewise.
10872 (x86_64_regmap): Add AVX512 registers.
10873 (x86_linux_read_description): Add code to handle AVX512 XSTATE
10874 mask.
10875 (initialize_low_arch): Add code to initialize AVX512 registers.
10876
10877 2014-04-23 Pedro Alves <palves@redhat.com>
10878
10879 * mem-break.c (find_gdb_breakpoint_at): Make static.
10880 * mem-break.h (find_gdb_breakpoint_at): Delete declaration.
10881
10882 2014-04-23 Pedro Alves <palves@redhat.com>
10883
10884 * i386-low.c: Don't include break-common.h here.
10885 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
10886 prototype to take target_hw_bp_type as argument instead of a Z
10887 packet char.
10888 * i386-low.h: Include break-common.h here.
10889 (Z_packet_to_hw_type): Declare.
10890 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
10891 prototypes.
10892 * linux-x86-low.c (x86_insert_point): Convert the packet number to
10893 a target_hw_bp_type before calling i386_low_insert_watchpoint.
10894 (x86_remove_point): Convert the packet number to a
10895 target_hw_bp_type before calling i386_low_remove_watchpoint.
10896 * win32-i386-low.c (i386_insert_point): Convert the packet number
10897 to a target_hw_bp_type before calling i386_low_insert_watchpoint.
10898 (i386_remove_point): Convert the packet number to a
10899 target_hw_bp_type before calling i386_low_remove_watchpoint.
10900
10901 2014-04-23 Pedro Alves <palves@redhat.com>
10902
10903 * utils.h (perror_with_name): Add ATTRIBUTE_NORETURN.
10904
10905 2014-04-10 Pedro Alves <palves@redhat.com>
10906
10907 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
10908 Check if the condition or command is NULL before checking if the
10909 breakpoint is known. On success, return true.
10910 * mem-break.h (add_breakpoint_condition): Document return.
10911 (add_breakpoint_commands): Add describing comment.
10912 * server.c (skip_to_semicolon): New function.
10913 (process_point_options): Use it.
10914
10915 2014-04-09 Pedro Alves <palves@redhat.com>
10916
10917 * linux-low.c (linux_read_loadmap): Pass current_inferior directly
10918 to lwpid_of.
10919
10920 2014-02-27 Pedro Alves <palves@redhat.com>
10921
10922 PR 12702
10923 * inferiors.h (A_I_NEXT, ALL_INFERIORS_TYPE, ALL_PROCESSES): New
10924 macros.
10925 * linux-low.c (delete_lwp, handle_extended_wait): Add debug
10926 output.
10927 (last_thread_of_process_p): Take a PID argument instead of a
10928 thread pointer.
10929 (linux_wait_for_lwp): Delete.
10930 (num_lwps, check_zombie_leaders, not_stopped_callback): New
10931 functions.
10932 (linux_low_filter_event): New function, party factored out from
10933 linux_wait_for_event.
10934 (linux_wait_for_event): Rename to ...
10935 (linux_wait_for_event_filtered): ... this. Add new filter ptid
10936 argument. Partly rewrite. Always use waitpid(-1, WNOHANG) and
10937 sigsuspend. Check for zombie leaders.
10938 (linux_wait_for_event): Reimplement as wrapper around
10939 linux_wait_for_event_filtered.
10940 (linux_wait_1): Handle TARGET_WAITKIND_NO_RESUMED. Assume that if
10941 a normal or signal exit is seen, it's the whole process exiting.
10942 (wait_for_sigstop): No longer a for_each_inferior callback.
10943 Rewrite on top of linux_wait_for_event_filtered.
10944 (stop_all_lwps): Call wait_for_sigstop directly.
10945 * server.c (resume, handle_target_event): Handle
10946 TARGET_WAITKIND_NO_RESUMED.
10947
10948 2014-02-26 Joel Brobecker <brobecker@adacore.com>
10949
10950 * win32-low.c (psapi_get_dll_name,
10951 * win32_CreateToolhelp32Snapshot): Delete.
10952 (win32_CreateToolhelp32Snapshot, win32_Module32First)
10953 (win32_Module32Next, load_toolhelp, toolhelp_get_dll_name):
10954 Delete.
10955 (handle_load_dll): Add function description.
10956 Remove code using psapi_get_dll_name and toolhelp_get_dll_name.
10957
10958 2014-02-26 Joel Brobecker <brobecker@adacore.com>
10959
10960 * win32-low.c (win32_add_one_solib): Add 0x1000 to load_addr.
10961 Add comment.
10962 (win32_add_all_dlls): Remove 0x1000 offset applied to DLL
10963 base address when calling win32_add_one_solib.
10964 (handle_load_dll): Delete local variable load_addr.
10965 Remove 0x1000 offset applied to DLL base address when calling
10966 win32_add_one_solib.
10967 (handle_unload_dll): Add comment.
10968
10969 2014-02-26 Joel Brobecker <brobecker@adacore.com>
10970
10971 * win32-low.c (win32_add_all_dlls): Renames
10972 win32_ensure_ntdll_loaded. Rewrite function documentation.
10973 Adjust implementation to always load all DLLs.
10974 Add 0x1000 offset to DLL base address when calling
10975 win32_add_one_solib.
10976 (child_initialization_done): New static global.
10977 (do_initial_child_stuff): Set child_initialization_done to
10978 zero during child initialization, and 1 after. Replace call
10979 to win32_ensure_ntdll_loaded by call to win32_add_all_dlls.
10980 Add comment.
10981 (match_dll_by_basename, dll_is_loaded_by_basename): Delete.
10982 (handle_unload_dll): Add function documentation.
10983 (get_child_debug_event): Ignore load and unload DLL events
10984 during child initialization.
10985
10986 2014-02-20 Doug Evans <dje@google.com>
10987
10988 Remove global all_lwps.
10989 * inferiors.h (ptid_of): Move here from linux-low.h.
10990 (pid_of, lwpid_of): Ditto.
10991 * linux-aarch64-low.c (debug_reg_change_callback): Update, "entry"
10992 parameter is a struct thread_info * now.
10993 (aarch64_notify_debug_reg_change): Fetch pid from current_inferior
10994 directly. Pass &all_threads to find_inferior instead of &all_lwps.
10995 (aarch64_stopped_data_address): Fetch lwpid from current_inferior
10996 directly.
10997 (aarch64_linux_prepare_to_resume): Fetch ptid from thread.
10998 (aarch64_arch_setup): Fetch lwpid from current_inferior directly.
10999 * linux-arm-low.c (update_registers_callback): Update, "entry"
11000 parameter is a struct thread_info * now.
11001 Fetch lwpid from current_inferior directly.
11002 (arm_insert_point): Pass &all_threads to find_inferior instead of
11003 &all_lwps.
11004 (arm_remove_point): Ditto.
11005 (arm_stopped_by_watchpoint): Fetch lwp from current_inferior.
11006 (arm_prepare_to_resume): Fetch pid from thread.
11007 (arm_read_description): Fetch lwpid from current_inferior directly.
11008 * linux-low.c (all_lwps): Delete.
11009 (delete_lwp): Delete call to remove_inferior.
11010 (handle_extended_wait): Fetch lwpid from thread.
11011 (add_lwp): Don't set lwp->entry.id. Remove call to
11012 add_inferior_to_list.
11013 (linux_attach_lwp_1): Fetch pid from current_inferior directly.
11014 (linux_kill_one_lwp): Fetch ptid,lwpid from thread.
11015 (kill_one_lwp_callback): Ditto.
11016 (linux_kill): Don't dereference NULL pointer.
11017 Fetch ptid,lwpid from thread.
11018 (get_detach_signal): Fetch ptid from thread.
11019 (linux_detach_one_lwp): Fetch ptid,lwpid from thread.
11020 Simplify call to regcache_invalidate_thread.
11021 (delete_lwp_callback): Update, "entry" parameter is a
11022 struct thread_info * now. Fetch pid from thread.
11023 (linux_mourn): Pass &all_threads to find_inferior instead of &all_lwps.
11024 (status_pending_p_callback): Update, "entry" parameter is a
11025 struct thread_info * now. Fetch ptid from thread.
11026 (find_lwp_pid): Update, "entry" parameter is a
11027 struct thread_info * now.
11028 (linux_wait_for_lwp): Fetch pid from thread.
11029 (linux_fast_tracepoint_collecting): Fetch lwpid from thread.
11030 (maybe_move_out_of_jump_pad): Fetch lwpid from current_inferior.
11031 (enqueue_one_deferred_signal): Fetch lwpid from thread.
11032 (dequeue_one_deferred_signal): Ditto.
11033 (cancel_breakpoint): Fetch ptid from current_inferior.
11034 (linux_wait_for_event): Pass &all_threads to find_inferior,
11035 not &all_lwps. Fetch ptid, lwpid from thread.
11036 (count_events_callback): Update, "entry" parameter is a
11037 struct thread_info * now.
11038 (select_singlestep_lwp_callback): Ditto.
11039 (select_event_lwp_callback): Ditto.
11040 (cancel_breakpoints_callback): Ditto.
11041 (linux_cancel_breakpoints): Pass &all_threads to find_inferior,
11042 not &all_lwps.
11043 (select_event_lwp): Ditto. Fetch ptid from event_thread.
11044 (unsuspend_one_lwp): Update, "entry" parameter is a
11045 struct thread_info * now.
11046 (unsuspend_all_lwps): Pass &all_threads to find_inferior,
11047 not &all_lwps.
11048 (linux_stabilize_threads): Ditto. And for for_each_inferior.
11049 Fetch lwpid from thread, not lwp.
11050 (linux_wait_1): Fetch ptid, lwpid from current_inferior.
11051 Pass &all_threads to find_inferior, not &all_lwps.
11052 (send_sigstop): Fetch lwpid from thread, not lwp.
11053 (send_sigstop_callback): Update, "entry" parameter is a
11054 struct thread_info * now.
11055 (suspend_and_send_sigstop_callback): Ditto.
11056 (wait_for_sigstop): Ditto. Fetch ptid, lwpid from thread, lwp.
11057 (stuck_in_jump_pad_callback): Update, "entry" parameter is a
11058 struct thread_info * now.
11059 (move_out_of_jump_pad_callback): Ditto. Fetch ptid, lwpid
11060 from thread, lwp.
11061 (lwp_running): Update, "entry" parameter is a
11062 struct thread_info * now.
11063 (stop_all_lwps): Fetch ptid from thread.
11064 Pass &all_threads to find_inferior, for_each_inferior, not &all_lwps.
11065 (linux_resume_one_lwp): Fetch lwpid from thread.
11066 (linux_set_resume_request): Update, "entry" parameter is a
11067 struct thread_info * now. Fetch pid, lwpid from thread.
11068 (resume_status_pending_p): Update, "entry" parameter is a
11069 struct thread_info * now.
11070 (need_step_over_p): Ditto. Fetch lwpid from thread.
11071 (start_step_over): Fetch lwpid from thread.
11072 (linux_resume_one_thread): Update, "entry" parameter is a
11073 struct thread_info * now. Fetch lwpid from thread.
11074 (linux_resume): Pass &all_threads to find_inferior, not &all_lwps.
11075 (proceed_one_lwp): Update, "entry" parameter is a
11076 struct thread_info * now. Fetch lwpid from thread.
11077 (unsuspend_and_proceed_one_lwp): Update, "entry" parameter is a
11078 struct thread_info * now.
11079 (proceed_all_lwps): Pass &all_threads to find_inferior, not &all_lwps.
11080 (unstop_all_lwps): Ditto. Fetch lwpid from thread.
11081 (regsets_fetch_inferior_registers): Fetch lwpid from current_inferior
11082 directly.
11083 (regsets_store_inferior_registers): Ditto.
11084 (fetch_register, store_register): Ditto.
11085 (linux_read_memory, linux_write_memory): Ditto.
11086 (linux_request_interrupt): Ditto.
11087 (linux_read_auxv): Ditto.
11088 (linux_xfer_siginfo): Ditto.
11089 (linux_qxfer_spu): Ditto.
11090 (linux_qxfer_libraries_svr4): Ditto.
11091 * linux-low.h (ptid_of, pid_of, lwpid_of): Delete,
11092 moved to inferiors.h.
11093 (get_lwp): Delete.
11094 (get_thread_lwp): Update.
11095 (struct lwp_info): Delete member "entry". Simplify comment for
11096 member "thread".
11097 (all_lwps): Delete.
11098 * linux-mips-low.c (mips_read_description): Fetch lwpid from
11099 current_inferior directly.
11100 (update_watch_registers_callback): Update, "entry" parameter is a
11101 struct thread_info * now. Fetch pid from thread.
11102 (mips_linux_prepare_to_resume): Fetch ptid from thread.
11103 (mips_insert_point): Fetch lwpid from current_inferior.
11104 Pass &all_threads to find_inferior, not &all_lwps.
11105 (mips_remove_point): Pass &all_threads to find_inferior, not &all_lwps.
11106 (mips_stopped_by_watchpoint): Fetch lwpid from current_inferior
11107 directly.
11108 (mips_stopped_data_address): Ditto.
11109 * linux-s390-low.c (s390_arch_setup): Fetch pid from current_inferior
11110 directly.
11111 * linux-tile-low.c (tile_arch_setup): Ditto.
11112 * linux-x86-low.c (x86_get_thread_area): Fetch lwpid from thread.
11113 (update_debug_registers_callback): Update, "entry" parameter is a
11114 struct thread_info * now. Fetch pid from thread.
11115 (i386_dr_low_set_addr): Fetch pid from current_inferior directly.
11116 Pass &all_threads to find_inferior, not &all_lwps.
11117 (i386_dr_low_get_addr): Fetch ptid from current_inferior directly.
11118 (i386_dr_low_set_control): Fetch pid from current_inferior directly.
11119 Pass &all_threads to find_inferior, not &all_lwps.
11120 (i386_dr_low_get_control): Fetch ptid from current_inferior directly.
11121 (i386_dr_low_get_status): Ditto.
11122 (x86_linux_prepare_to_resume): Fetch ptid from thread.
11123 (x86_siginfo_fixup): Fetch lwpid from current_inferior directly.
11124 (x86_linux_read_description): Ditto.
11125 * proc-service.c (ps_getpid): Fetch pid from current_inferior directly.
11126
11127 2014-02-20 Doug Evans <dje@google.com>
11128
11129 * inferiors.c (get_first_inferior): Fix buglet.
11130
11131 2014-02-19 Doug Evans <dje@google.com>
11132
11133 * gdbthread.h (add_thread): Change result type to struct thread_info *.
11134 * inferiors.c (add_thread): Change result type to struct thread_info *.
11135 All callers updated.
11136 (add_lwp): Call add_thread here instead of in callers.
11137 All callers updated.
11138 * linux-low.h (get_lwp_thread): Rewrite.
11139 (struct lwp_info): New member "thread".
11140
11141 2014-02-19 Doug Evans <dje@google.com>
11142
11143 * linux-low.c (add_lwp): Change result to struct lwp_info *.
11144 All callers updated.
11145
11146 2014-02-19 Doug Evans <dje@google.com>
11147
11148 * inferiors.c (add_thread): Fix whitespace.
11149
11150 2014-02-19 Doug Evans <dje@google.com>
11151
11152 * dll.c (clear_dlls): Replace accessing list implemention details
11153 with API function.
11154 * gdbthread.h (get_first_thread): Declare.
11155 * inferiors.c (for_each_inferior_with_data): New function.
11156 (get_first_thread): New function.
11157 (find_thread_ptid): Simplify.
11158 (get_first_inferior): New function.
11159 (clear_list): Delete.
11160 (one_inferior_p): New function.
11161 (clear_inferior_list): New function.
11162 (clear_inferiors): Update.
11163 * inferiors.h (for_each_inferior_with_data): Declare.
11164 (clear_inferior_list): Declare.
11165 (one_inferior_p): Declare.
11166 (get_first_inferior): Declare.
11167 * linux-low.c (linux_wait_for_event): Replace accessing list
11168 implemention details with API function.
11169 * server.c (target_running): Ditto.
11170 (accumulate_file_name_length): New function.
11171 (emit_dll_description): New function.
11172 (handle_qxfer_libraries): Replace accessing list implemention
11173 details with API function.
11174 (handle_qxfer_threads_worker): New function.
11175 (handle_qxfer_threads_proper): Replace accessing list implemention
11176 details with API function.
11177 (handle_query): Ditto.
11178 (visit_actioned_threads_callback_ftype): New typedef.
11179 (visit_actioned_threads_data): New struct.
11180 (visit_actioned_threads): Rewrite to be find_inferior callback.
11181 (resume): Call find_inferior.
11182 (handle_status): Replace accessing list implemention
11183 details with API function.
11184 (process_serial_event): Replace accessing list implemention details
11185 with API function.
11186 * target.c (set_desired_inferior): Replace accessing list implemention
11187 details with API function.
11188 * tracepoint.c (same_process_p): New function.
11189 (gdb_agent_about_to_close): Replace accessing list implemention
11190 details with API function.
11191 * win32-low.c (child_delete_thread): Replace accessing list
11192 implemention details with API function.
11193 (match_dll_by_basename): New function.
11194 (dll_is_loaded_by_basename): New function.
11195 (win32_ensure_ntdll_loaded): Replace accessing list implemention
11196 details call to dll_is_loaded_by_basename.
11197
11198 2014-02-19 Doug Evans <dje@google.com>
11199
11200 * dll.h (struct dll_info): Add comment.
11201 * gdbthread.h (struct thread_info): Add comment.
11202 (current_ptid): Simplify.
11203 * inferiors.c (add_process): Update.
11204 (remove_process): Update.
11205 * inferiors.h (struct process_info): Rename member "head" to "entry".
11206 * linux-low.c (delete_lwp): Update.
11207 (add_lwp): Update.
11208 (last_thread_of_process_p): Update.
11209 (kill_one_lwp_callback, linux_kill): Update.
11210 (status_pending_p_callback): Update.
11211 (wait_for_sigstop): Update. Simplify read of ptid.
11212 (start_step_over): Update.
11213 * linux-low.h (ptid_of, pid_of, lwpid_of): Update.
11214 (get_lwp_thread): Update.
11215 (struct lwp_info): Rename member "head" to "entry".
11216 * regcache.h (inferior_list_entry): Delete.
11217 * server.c (kill_inferior_callback): Update.
11218 (detach_or_kill_inferior_callback): Update.
11219 (print_started_pid): Update.
11220 (print_attached_pid): Update.
11221 (process_serial_event): Simplify read of ptid.
11222 * thread-db.c (thread_db_create_event): Update.
11223 (thread_db_get_tls_address): Update.
11224 * win32-low.c (current_inferior_ptid): Simplify.
11225
11226 2014-02-19 Tom Tromey <tromey@redhat.com>
11227
11228 * target.h (struct target_ops) <supports_btrace>: Add target_ops
11229 argument.
11230 (target_supports_btrace): Update.
11231
11232 2014-02-14 Yao Qi <yao@codesourcery.com>
11233
11234 * Makefile.in (IPA_OBJS): Append rsp-low-ipa.o.
11235 (rsp-low-ipa.o): New target.
11236
11237 2014-02-12 Tom Tromey <tromey@redhat.com>
11238
11239 * ax.c (gdb_parse_agent_expr): Use hex2bin, not
11240 convert_ascii_to_int.
11241 * regcache.c (registers_to_string): Likewise.
11242 * remote-utils.c (decode_M_packet): Likewise.
11243 * server.c (process_serial_event): Likewise.
11244
11245 2014-02-12 Tom Tromey <tromey@redhat.com>
11246
11247 * server.c (handle_query, handle_v_run): Use hex2bin, not
11248 unhexify.
11249 * tracepoint.c (cmd_qtdpsrc, cmd_qtdv, cmd_qtnotes): Likewise.
11250
11251 2014-02-12 Tom Tromey <tromey@redhat.com>
11252
11253 * ax.c (gdb_unparse_agent_expr): Use bin2hex, not
11254 convert_int_to_ascii.
11255 * regcache.c (registers_to_string, collect_register_as_string):
11256 Likewise.
11257 * remote-utils.c (look_up_one_symbol, relocate_instruction):
11258 Likewise.
11259 * server.c (process_serial_event): Likewise.
11260 * tracepoint.c (cmd_qtstatus, response_source, response_tsv)
11261 (cmd_qtbuffer, cstr_to_hexstr): Likewise.
11262
11263 2014-02-12 Tom Tromey <tromey@redhat.com>
11264
11265 * remote-utils.c (look_up_one_symbol, monitor_output): Use
11266 bin2hex, not hexify.
11267 * tracepoint.c (cmd_qtstatus): Likewise.
11268
11269 2014-02-12 Tom Tromey <tromey@redhat.com>
11270
11271 * remote-utils.c (monitor_output): Pass explicit length to
11272 hexify.
11273
11274 2014-02-12 Tom Tromey <tromey@redhat.com>
11275
11276 * tracepoint.c: Include rsp-low.h.
11277 * server.c: Include rsp-low.h.
11278 * remote-utils.h (convert_ascii_to_int, convert_int_to_ascii)
11279 (unhexify, hexify, remote_escape_output, unpack_varlen_hex): Don't
11280 declare.
11281 * remote-utils.c: Include rsp-low.h.
11282 (fromhex, hexchars, ishex, unhexify, tohex, hexify)
11283 (remote_escape_output, remote_unescape_input, unpack_varlen_hex)
11284 (convert_int_to_ascii, convert_ascii_to_int): Move to
11285 common/rsp-low.c.
11286 * regcache.c: Include rsp-low.h.
11287 * ax.c: Include rsp-low.h.
11288 * Makefile.in (SFILES): Add common/rsp-low.c.
11289 (OBS): Add rsp-low.o.
11290 (rsp-low.o): New target.
11291
11292 2014-02-12 Tom Tromey <tromey@redhat.com>
11293
11294 * utils.h (pulongest, plongest, phex_nz): Don't declare.
11295 Include print-utils.h.
11296 * utils.c (NUMCELLS, CELLSIZE, get_cell, decimal2str, pulongest)
11297 (plongest, thirty_two, phex_nz): Remove.
11298 * Makefile.in (SFILES): Add common/print-utils.c.
11299 (OBS): Add print-utils.o.
11300 (print-utils-ipa.o): New target.
11301 (print-utils.o): New target.
11302 (IPA_OBJS): Add print-utils-ipa.o.
11303
11304 2014-02-06 Tom Tromey <tromey@redhat.com>
11305
11306 * Makefile.in (SFILES): Fix indentation.
11307
11308 2014-02-05 Doug Evans <dje@google.com>
11309
11310 * linux-low.c (linux_wait_for_event): Improve comment.
11311 (linux_wait_1): Keep current_inferior in sync with event_child.
11312
11313 2014-01-22 Doug Evans <dje@google.com>
11314
11315 * gdbthread.h (gdb_id_to_thread): Delete, unused.
11316
11317 2014-01-22 Doug Evans <dje@google.com>
11318
11319 * configure.ac (AC_CHECK_FUNCS): Add test for gettimeofday.
11320 * configure: Regenerate.
11321 * config.in: Regenerate.
11322 * Makefile.in (SFILES): Add debug.c.
11323 (OBS): Add debug.o.
11324 * debug.c: New file.
11325 * debug.h: New file.
11326 * linux-aarch64-low.c (*): Update all debugging printfs to use
11327 debug_printf instead of fprintf.
11328 * linux-arm-low.c (*): Ditto.
11329 * linux-cris-low.c (*): Ditto.
11330 * linux-crisv32-low.c (*): Ditto.
11331 * linux-m32r-low.c (*): Ditto.
11332 * linux-sparc-low.c (*): Ditto.
11333 * linux-x86.c (*): Ditto.
11334 * linux-low.c (*): Ditto.
11335 (linux_wait_1): Add calls to debug_enter, debug_exit.
11336 (linux_wait): Remove redundant debugging printf.
11337 (stop_all_lwps): Add calls to debug_enter, debug_exit.
11338 (linux_resume, unstop_all_lwps): Ditto.
11339 * mem-break.c (*): Update all debugging printfs to use
11340 debug_printf instead of fprintf.
11341 * remote-utils.c (*): Ditto.
11342 * thread-db.c (*): Ditto.
11343 * server.c #include <ctype.h>, "gdb_vecs.h".
11344 (debug_threads): Moved to debug.c.
11345 (*): Update all debugging printfs to use debug_printf instead of
11346 fprintf.
11347 (start_inferior): Replace call to fflush with call to debug_flush.
11348 (monitor_show_help): Mention set debug-format.
11349 (parse_debug_format_options): New function.
11350 (handle_monitor_command): Handle "monitor set debug-format".
11351 (gdbserver_usage): Mention --debug-format.
11352 (main): Parse --debug-format.
11353 * server.h (debug_threads): Declaration moved to debug.h.
11354 #include "debug.h".
11355 * tracepoint.c (trace_debug_1) [!IN_PROCESS_AGENT]: Add version of
11356 trace_debug_1 that uses debug_printf.
11357 (tracepoint_look_up_symbols): Update all debugging printfs to use
11358 debug_printf instead of fprintf.
11359
11360 2014-01-20 Baruch Siach <baruch@tkos.co.il>
11361
11362 * linux-xtensa-low.c: Include asm/ptrace.h instead of
11363 sys/ptrace.h.
11364
11365 2014-01-17 Pedro Alves <palves@redhat.com>
11366
11367 PR build/16445
11368 * linux-x86-low.c: Don't include elf/common.h if ELFMAG0 is
11369 defined after including gdb_proc_service.h.
11370
11371 2014-01-16 Doug Evans <dje@google.com>
11372
11373 * dll.c (UNSPECIFIED_CORE_ADDR): New macro.
11374 (match_dll): Use it.
11375
11376 2014-01-16 Markus Metzger <markus.t.metzger@intel.com>
11377
11378 * target.h (target_ops) <read_btrace>: Change parameters and
11379 return type to allow error reporting.
11380 * server.c (handle_qxfer_btrace): Support delta reads. Pass
11381 trace reading errors on.
11382 * linux-low.c (linux_low_read_btrace): Pass trace reading
11383 errors on.
11384 (linux_low_disable_btrace): New.
11385
11386 2014-01-15 Doug Evans <dje@google.com>
11387
11388 * inferiors.c (thread_id_to_gdb_id): Delete.
11389 * inferiors.h (thread_id_to_gdb_id): Delete.
11390
11391 2014-01-13 Eli Zaretskii <eliz@gnu.org>
11392
11393 * Makefile.in (INCLUDE_CFLAGS): Remove trailing slash from
11394 "-I$(srcdir)/../". Fixes MinGW compilation errors with old GCC
11395 versions.
11396
11397 2014-01-08 Pedro Alves <palves@redhat.com>
11398
11399 * server.c (handle_status): Don't discard previous queued stop
11400 replies or thread's pending status here.
11401 (main) <disconnection>: Do it here instead.
11402
11403 2014-01-08 Pedro Alves <palves@redhat.com>
11404
11405 * gdbthread.h (struct thread_info) <status_pending_p>: New field.
11406 * server.c (visit_actioned_threads, handle_pending_status): New
11407 function.
11408 (handle_v_cont): Factor out parts to ...
11409 (resume): ... this new function. If in all-stop, and a thread
11410 being resumed has a pending status, report it without actually
11411 resuming.
11412 (myresume): Adjust to use the new 'resume' function.
11413 (clear_pending_status_callback, set_pending_status_callback)
11414 (find_status_pending_thread_callback): New functions.
11415 (handle_status): Handle the case of multiple threads having
11416 interesting statuses to report. Report threads' real last signal
11417 instead of always reporting GDB_SIGNAL_TRAP. Look for a thread
11418 with an interesting thread to report the status for, instead of
11419 always reporting the status of the first thread.
11420
11421 2014-01-01 Joel Brobecker <brobecker@adacore.com>
11422
11423 * gdbserver.c (gdbserver_version): Set copyright year to 2014.
11424 * gdbreplay.c (gdbreplay_version): Likewise.
11425
11426 2013-12-18 Yufeng Zhang <yufeng.zhang@arm.com>
11427
11428 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Set
11429 iov.iov_len with the real length in use.
11430
11431 2013-12-13 Joel Brobecker <brobecker@adacore.com>
11432
11433 * Makefile.in (safe-ctype.o, lbasename.o): New rules.
11434 * configure.srv: Add safe-ctype.o and lbasename.o to srv_tgtobj
11435 for all targets that use win32-low.c.
11436 * win32-low.c (win32_ensure_ntdll_loaded): New function.
11437 (do_initial_child_stuff): Add call to win32_ensure_ntdll_loaded.
11438
11439 2013-12-13 Pedro Alves <palves@redhat.com>
11440
11441 * target.c (mywait): Set OURSTATUS->KIND to TARGET_WAITKIND_STOPPED
11442 if equal to TARGET_WAITKIND_LOADED.
11443 * win32-low.c (cached_status): New static global.
11444 (win32_wait): Add declaration.
11445 (do_initial_child_stuff): Flush all initial pending debug events
11446 up to the initial breakpoint.
11447 (win32_wait): If CACHED_STATUS was set, return that instead
11448 of doing a real wait. Remove the code resuming the execution
11449 of the inferior after receiving a TARGET_WAITKIND_LOADED event
11450 during the initial phase. Also remove the code changing
11451 OURSTATUS->KIND from TARGET_WAITKIND_LOADED to
11452 TARGET_WAITKIND_STOPPED.
11453
11454 2013-12-11 Yao Qi <yao@codesourcery.com>
11455
11456 * notif.c (handle_notif_ack): Return 0 if no notification
11457 matches.
11458
11459 2013-11-20 Doug Evans <dje@google.com>
11460
11461 * linux-low.c (linux_set_resume_request): Fix comment.
11462
11463 2013-11-20 Doug Evans <dje@google.com>
11464
11465 * linux-low.c (resume_status_pending_p): Tweak comment.
11466
11467 2013-11-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
11468
11469 * Makefile.in: Add i386-mpx.c, i386-mpx-linux.c, amd64-mpx.c,
11470 amd64-mpx-linux.c, x32-mpx.c and x32-mpx-linux.c generation.
11471 * configure.srv (srv_i386_regobj): Add i386-mpx.o.
11472 (srv_i386_linux_regobj): Add i386-mpx-linux.o.
11473 (srv_amd64_regobj): Add amd64-mpx.o.
11474 (srv_amd64_linux_regobj): Add amd64-mpx-linux.o.
11475 (srv_i386_32bit_xmlfiles): Add i386/32bit-mpx.xml.
11476 (srv_i386_64bit_xmlfiles): Add i386/64bit-mpx.xml.
11477 * i387-fp.c (num_pl_bnd_register) Added constant.
11478 (num_pl_bnd_cfg_registers) Added constant.
11479 (struct i387_xsave) Added reserved area and MPX fields.
11480 (i387_cache_to_xsave, i387_xsave_to_cache) Add MPX.
11481 * linux-x86-low.c (init_registers_i386_mpx_linux): Declare new
11482 function.
11483 (tdesc_i386_mpx_linux): Add MPX amd64 target.
11484 (init_registers_amd64_mpx_linux): Declare new function.
11485 (tdesc_amd64_mpx_linux): Add MPX amd64 target.
11486 (x86_64_regmap): Add MPX registers.
11487 (x86_linux_read_description): Add MPX case.
11488 (initialize_low_arch): Initialize MPX targets.
11489
11490 2013-11-18 Tom Tromey <tromey@redhat.com>
11491
11492 * configure: Rebuild.
11493 * configure.ac: Don't check for stdlib.h.
11494 * gdbreplay.c: Unconditionally include stdlib.h.
11495
11496 2013-11-18 Tom Tromey <tromey@redhat.com>
11497
11498 * config.in: Rebuild.
11499 * configure: Rebuild.
11500 * configure.ac: Don't use AC_HEADER_DIRENT.
11501
11502 2013-11-18 Tom Tromey <tromey@redhat.com>
11503
11504 * server.h: Don't check HAVE_STRING_H.
11505 * gdbreplay.c: Don't check HAVE_STRING_H.
11506 * configure: Rebuild.
11507
11508 2013-11-18 Tom Tromey <tromey@redhat.com>
11509
11510 * Makefile.in (gdbreplay$(EXEEXT)): Depend on and link against
11511 LIBGNU.
11512
11513 2013-11-08 Tom Tromey <tromey@redhat.com>
11514
11515 * configure, config.in: Rebuild.
11516 * configure.ac: Remove unused configury.
11517
11518 2013-11-08 Tom Tromey <tromey@redhat.com>
11519
11520 * acinclude.m4: Include common.m4, codeset.m4.
11521 * configure, config.in: Rebuild.
11522 * configure.ac: Use GDB_AC_COMMON.
11523
11524 2013-11-06 Andreas Arnez <arnez@linux.vnet.ibm.com>
11525
11526 * linux-s390-low.c (HWCAP_S390_TE): New define.
11527 (s390_arch_setup): Consider the TE field in the HWCAP for
11528 determining 'have_regset_tdb'.
11529
11530 2013-10-16 Sergio Durigan Junior <sergiodj@redhat.com>
11531
11532 PR gdb/16014
11533 * tracepoint.c (download_tracepoint_1): Remove unnecessary double
11534 call to sizeof.
11535
11536 2013-10-02 Pedro Alves <palves@redhat.com>
11537
11538 * server.c (process_serial_event): Don't output "GDBserver
11539 exiting" if GDB is connected through stdio.
11540 * target.c (mywait): Likewise, be silent if GDB is connected
11541 through stdio.
11542
11543 2013-10-01 Joel Brobecker <brobecker@adacore.com>
11544
11545 * lynx-low.c (lynx_add_threads_after_attach): New function.
11546 (lynx_attach): Remove call to add_thread. Add call to
11547 lynx_add_threads_after_attach instead.
11548
11549 2013-09-28 Mike Frysinger <vapier@gentoo.org>
11550
11551 * configure.ac (AC_CHECK_HEADERS): Add sys/syscall.h
11552 * config.in, configure: Regenerated.
11553
11554 2013-09-18 Yao Qi <yao@codesourcery.com>
11555
11556 PR server/15959
11557 * server.c (start_inferior): Clear 'resume_info'.
11558
11559 2013-09-16 Jiong Wang <jiwang@tilera.com>
11560
11561 * linux-tile-low.c (tile_regsets): Modify the size field to 64-bit
11562 for each register.
11563
11564 2013-09-16 Jiong Wang <jiwang@tilera.com>
11565
11566 * configure.srv <tilegx*-*-linux*>: Remove linux-osdata.o from and add
11567 linux-tile-low.o to srv_tgtobj.
11568
11569 2013-09-16 Will Newton <will.newton@linaro.org>
11570
11571 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Zero
11572 out regs.
11573
11574 2013-09-06 Pedro Alves <palves@redhat.com>
11575
11576 * Makefile.in (gdb_proc_service_h, regdef_h, regcache_h)
11577 (signals_def, signals_h, ptid_h, ax_h, agent_h, linux_btrace_h)
11578 (linux_osdata_h, vec_h, gdb_vecs_h, host_defs_h, libiberty_h)
11579 (server_h, gdbthread_h, linux_low_h, linux_ptrace_h)
11580 (gdb_thread_db_h, linux_procfs_h, lynx_low_h, nto_low_h)
11581 (mips_linux_watch_h, i386_low_h, win32_low_h): Delete.
11582
11583 2013-09-06 Pedro Alves <palves@redhat.com>
11584
11585 * Makefile.in (linux-btrace.o, mips-linux-watch.o): Remove
11586 explicit header dependencies and use $COMPILE/$POSTCOMPILE.
11587
11588 2013-09-06 Pedro Alves <palves@redhat.com>
11589
11590 * linux-amd64-ipa.c: Include tracepoint.h.
11591 * linux-i386-ipa.c: Include tracepoint.h.
11592
11593 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
11594
11595 * linux-crisv32-low.c (PTRACE_GET_THREAD_AREA): New macro.
11596 (ps_get_thread_area): New function.
11597
11598 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
11599
11600 * linux-crisv32-low.c (elf_gregset_t): Delete typedef.
11601 (initialize_low_arch): Call init_registers_crisv32 rather than
11602 init_register_crisv32.
11603
11604 2013-09-05 Pedro Alves <palves@redhat.com>
11605
11606 * server.h (handle_vFile, hostio_last_error_from_errno): Move
11607 to ...
11608 * hostio.h: ... this new file.
11609 * hostio.c, server.c, linux-low.c, nto-low.c, spu-low,
11610 win32-low.c: Include hostio.h.
11611
11612 2013-09-05 Pedro Alves <palves@redhat.com>
11613
11614 * server.h (gdb_client_data, handler_func, callback_handler_func)
11615 (delete_file_handler, add_file_handler, append_callback_event)
11616 (delete_callback_event, start_event_loop, initialize_event_loop):
11617 Move to event-loop.h and include it.
11618 * event-loop.h: New file.
11619
11620 2013-09-05 Pedro Alves <palves@redhat.com>
11621
11622 * dll.c, inferiors.c, remote-utils.c, server.c: Include "dll.h".
11623 * server.h (struct dll_info, all_dlls, dlls_changed, clear_dlls)
11624 (loaded_dll, unloaded_dll): Move to ...
11625 * dll.h: ... this new file.
11626 * inferiors.c, remote-utils.c, win32-low.c: Include "dll.h".
11627
11628 2013-09-05 Pedro Alves <palves@redhat.com>
11629
11630 * server.h (current_process, get_thread_process, all_processes)
11631 (add_inferior_to_list, for_each_inferior, current_inferior)
11632 (remove_inferior, add_process, remove_process, find_process_pid)
11633 (have_started_inferiors_p, have_attached_inferiors_p)
11634 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id)
11635 (clear_inferiors, find_inferior, find_inferior_id)
11636 (inferior_target_data, set_inferior_target_data)
11637 (inferior_regcache_data, set_inferior_regcache_data): Move to
11638 inferiors.h, and include it.
11639 * inferiors.h: New file.
11640
11641 2013-09-05 Pedro Alves <palves@redhat.com>
11642
11643 * server.h (struct emit_ops, current_insn_ptr, emit_error):
11644 Move ...
11645 * ax.h: ... here.
11646
11647 2013-09-05 Pedro Alves <palves@redhat.com>
11648
11649 * ax.c, linux-low.c, linux-x86-low.c, server.c: Include
11650 tracepoint.h.
11651 * server.h (IPA_BUFSIZ, initialize_tracepoint, tracing)
11652 (disconnected_tracing, tracepoint_look_up_symbols, stop_tracing
11653 (handle_tracepoint_general_set, handle_tracepoint_query)
11654 (tracepoint_finished_step, tracepoint_was_hit)
11655 (release_while_stepping_state_list, current_traceframe)
11656 (in_readonly_region, traceframe_read_mem)
11657 (fetch_traceframe_registers, traceframe_read_sdata)
11658 (traceframe_read_info, struct fast_tpoint_collect_status)
11659 (fast_tracepoint_collecting, force_unlock_trace_buffer)
11660 (handle_tracepoit_bkpts, initialize_low_tracepoint)
11661 (supply_fast_tracepoint_registers)
11662 (supply_static_tracepoint_registers, set_trampoline_buffer_space)
11663 (ipa_tdesc, claim_trampoline_space)
11664 (have_fast_tracepoint_trampoline_buffer, gdb_agent_about_to_close)
11665 (agent_mem_read, agent_get_trace_state_variable_value)
11666 (agent_set_trace_state_variable_value, agent_tsv_read)
11667 (agent_mem_read_string, get_raw_reg_func_addr)
11668 (get_get_tsv_func_addr, get_set_tsv_func_addr): Move to ...
11669 * tracepoint.h: ... this new file.
11670
11671 2013-09-05 Pedro Alves <palves@redhat.com>
11672
11673 * server.h (perror_with_name, error, fatal, warning, paddress)
11674 (pulongest, plongest, phex_nz, pfildes): Move to utils.h, and
11675 include it.
11676 * utils.h: New file.
11677
11678 2013-09-05 Pedro Alves <palves@redhat.com>
11679
11680 * server.h (remote_debug, noack_mode, transport_is_reliable)
11681 (gdb_connected, STDIO_CONNECTION_NAME, remote_connection_is_stdio)
11682 (read_ptid, write_ptid, putpkt, putpkt_binary, putpkt_notif)
11683 (getpkt, remote_prepare, remote_open, remote_close, write_ok)
11684 (write_enn, initialize_async_io, enable_async_io)
11685 (disable_async_io, check_remote_input_interrupt_request)
11686 (convert_ascii_to_int, convert_int_to_ascii, new_thread_notify)
11687 (dead_thread_notify, prepare_resume_reply)
11688 (decode_address_to_semicolon, decode_address, decode_m_packet)
11689 (decode_M_packet, decode_X_packet, decode_xfer_write)
11690 (decode_search_memory_packet, unhexify, hexify)
11691 (remote_escape_output, unpack_varlen_hex, clear_symbol_cache)
11692 (look_up_one_symbol, relocate_instruction)
11693 (monitor_output): Move to remote-utils.h, and include it.
11694 * remote-utils.h: New file.
11695
11696 2013-09-05 Pedro Alves <palves@redhat.com>
11697
11698 * server.h (_): Delete.
11699
11700 2013-09-02 Pedro Alves <palves@redhat.com>
11701
11702 * tracepoint.c (TRACEFRAME_EOB_MARKER_SIZE): New macro.
11703 (init_trace_buffer): Ensure at least TRACEFRAME_EOB_MARKER_SIZE is
11704 allocated.
11705 (trace_buffer_alloc): Use TRACEFRAME_EOB_MARKER_SIZE.
11706
11707 2013-09-02 Pierre Muller <muller@sourceware.org>
11708
11709 * win32-low.c (child_xfer_memory): Check if ReadProcessMemory
11710 or WriteProcessMemory complete successfully and handle
11711 ERROR_PARTIAL_COPY error.
11712
11713 2013-09-02 Pedro Alves <palves@redhat.com>
11714
11715 * server.c (gdb_read_memory): Return -1 on traceframe memory read
11716 error instead of EIO.
11717
11718 2013-08-28 Jan Kratochvil <jan.kratochvil@redhat.com>
11719
11720 PR server/15604
11721 * linux-low.c: Include filestuff.h.
11722 (linux_create_inferior) <pid == 0>: Call close_most_fds.
11723 * lynx-low.c: Include filestuff.h.
11724 (lynx_create_inferior) <pid == 0>: Call close_most_fds.
11725 * server.c: Include filestuff.h.
11726 (main): Call notice_open_fds.
11727 * spu-low.c: Include filestuff.h.
11728 (spu_create_inferior) <pid == 0>: Call close_most_fds.
11729
11730 2013-08-22 Luis Machado <lgustavo@codesourcery.com>
11731
11732 * Makefile.in: Explain why ../target and ../nat are not
11733 listed as include file search paths.
11734 (linux-waitpid.o): New object file rule.
11735 * configure.srv (srv_native_linux_obj): New variable.
11736 Replace all occurrences of linux native object files with
11737 $srv_native_linux_obj.
11738 * linux-low.c: Include nat/linux-nat.h and nat/linux-waitpid.h.
11739 (HAS_NOMMU): Move defining logic to common/linux-ptrace.c.
11740 (linux_enable_event_reporting): Remove declaration.
11741 (my_waitpid): Moved to common/linux-waitpid.c.
11742 (linux_wait_for_event): Pass ptid when calling
11743 linux_enable_event_reporting.
11744 (linux_supports_tracefork_flag): Remove.
11745 (linux_enable_event_reporting): Likewise.
11746 (linux_tracefork_grandchild): Remove.
11747 (STACK_SIZE): Moved to common/linux-ptrace.c.
11748 (linux_tracefork_child): Remove.
11749 (linux_test_for_tracefork): Remove.
11750 (linux_look_up_symbols): Call linux_supports_traceclone.
11751 (initialize_low): Remove call to linux_test_for_tracefork.
11752 * linux-low.h (PTRACE_TYPE_ARG3): Move to
11753 common/linux-ptrace.h.
11754 (PTRACE_TYPE_ARG4): Likewise.
11755 Include linux-ptrace.h.
11756
11757 2013-08-21 Pedro Alves <palves@redhat.com>
11758
11759 * config.in: Renegerate.
11760
11761 2013-08-19 Luis Machado <lgustavo@codesourcery.com>
11762
11763 * Makefile.in (INCLUDE_CFLAGS): Include -I$(srcdir)/../.
11764 (SFILES): Remove $(srcdir)/common/target-common.c and
11765 add $(srcdir)/target/waitstatus.c.
11766 (OBS): Remove target-common.o and add waitstatus.o.
11767 (server_h): Remove $(srcdir)/../common/target-common.h and
11768 add $(srcdir)/../target/resume.h, $(srcdir)/../target/wait.h
11769 and $(srcdir)/../target/waitstatus.h.
11770 (target-common.o): Remove.
11771 (waitstatus.o): New target object file.
11772 * target.h: Do not include target-common.h and
11773 include target/resume.h, target/wait.h and
11774 target/waitstatus.h.
11775
11776 2013-08-13 Luis Machado <lgustavo@codesourcery.com>
11777
11778 * linux-arm-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
11779 to PTRACE_TYPE_ARG3.
11780 * linux-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
11781 to PTRACE_TYPE_ARG3 and PTRACE_ARG4_TYPE to
11782 PTRACE_TYPE_ARG4.
11783 * linux-low.h (PTRACE_ARG3_TYPE): Rename to PTRACE_TYPE_ARG3.
11784 (PTRACE_ARG4_TYPE): Rename to PTRACE_TYPE_ARG4.
11785
11786 2013-07-27 Jie Zhang <jie@codesourcery.com>
11787 Daniel Jacobowitz <dan@codesourcery.com>
11788 Yao Qi <yao@codesourcery.com>
11789
11790 * Makefile.in (SFILES): Add common/mips-linux-watch.c.
11791 (mips-linux-watch.o): New rule.
11792 (mips_linux_watch_h): New variable.
11793 * configure.srv <mips*-*-linux*>: Add mips-linux-watch.o to
11794 srv_tgtobj.
11795 * linux-mips-low.c: Include mips-linux-watch.h.
11796 (struct arch_process_info, struct arch_lwp_info): New.
11797 (update_watch_registers_callback): New function.
11798 (mips_linux_new_process, mips_linux_new_thread) New functions.
11799 (mips_linux_prepare_to_resume, mips_insert_point): New
11800 functions.
11801 (mips_remove_point, mips_stopped_by_watchpoint): New
11802 functions.
11803 (rsp_bp_type_to_target_hw_bp_type): New function.
11804 (mips_stopped_data_address): New function.
11805 (the_low_target): Add watchpoint support functions.
11806
11807 2013-07-27 Yao Qi <yao@codesourcery.com>
11808
11809 * i386-low.c: Include break-common.h.
11810 (enum target_hw_bp_type): Remove.
11811
11812 2013-07-24 Luis Machado <lgustavo@codesourcery.com>
11813
11814 * Makefile.in (SFILES): /common/target-common.c.
11815 (OBS): Add target-common.o.
11816 (server_h): Add $(srcdir)/../common/target-common.h.
11817 (target-common.o): New target.
11818 * server.c (queue_stop_reply_callback): Free
11819 status string after use.
11820 * target.c (target_waitstatus_to_string): Remove.
11821 * target.h: Include target-common.h.
11822 (resume_kind): Likewise.
11823 (target_waitkind): Likewise.
11824 (target_waitstatus): Likewise.
11825 (TARGET_WNOHANG): Likewise.
11826
11827 2013-07-04 Yao Qi <yao@codesourcery.com>
11828
11829 * Makefile.in (host_alias): Use @host_noncanonical@.
11830 (target_alias): Use @target_noncanonical@.
11831 * configure.ac: Use ACX_NONCANONICAL_TARGET and
11832 ACX_NONCANONICAL_HOST.
11833 * configure: Regenerated.
11834
11835 Revert:
11836 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
11837
11838 * configure.ac (version_host, version_target): Set and AC_SUBST them.
11839 * configure: Rebuild.
11840 * Makefile.in (version_host, version_target): Get from configure.
11841 (version.c): Use $(version_host) and $(version_target).
11842
11843 2013-07-03 Pedro Alves <palves@redhat.com>
11844
11845 * Makefile.in (config.status): Depend on development.sh.
11846 * acinclude.m4: Include libmcheck.m4.
11847 * configure: Regenerate.
11848
11849 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
11850
11851 * win32-low.c (winapi_DebugActiveProcessStop): Move the WINAPI
11852 attribute inside the parentheses.
11853 (winapi_DebugSetProcessKillOnExit): Ditto.
11854 (winapi_DebugBreakProcess): Ditto.
11855 (winapi_GenerateConsoleCtrlEvent): Ditto.
11856
11857 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
11858
11859 * notif.h (notif_event): Add a dummy member to avoid compiler
11860 errors.
11861
11862 2013-07-01 Pedro Alves <palves@redhat.com>
11863
11864 * hostio.c (HOSTIO_PATH_MAX): Define.
11865 (require_filename, handle_open, handle_unlink, handle_readlink):
11866 Use it.
11867
11868 2013-07-01 Pedro Alves <palves@redhat.com>
11869
11870 * server.h: Include "pathmax.h".
11871 * linux-low.c: Don't include sys/param.h.
11872 (linux_pid_exe_is_elf_64_file): Use PATH_MAX instead of
11873 MAXPATHLEN.
11874 * win32-low.c: Don't include sys/param.h.
11875 (win32_create_inferior): Use PATH_MAX instead of MAXPATHLEN.
11876
11877 2013-07-01 Pedro Alves <palves@redhat.com>
11878
11879 * event-loop.c: Don't check HAVE_UNISTD_H before including
11880 <unistd.h>.
11881 * gdbreplay.c: Likewise.
11882 * remote-utils.c: Likewise.
11883 * server.c: Likewise.
11884 * configure.ac: Don't check for unistd.h.
11885 * configure: Regenerate.
11886
11887 2013-06-28 Tom Tromey <tromey@redhat.com>
11888
11889 * Makefile.in (version.c): Use version.in, not
11890 common/version.in.
11891
11892 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
11893
11894 * configure.ac (version_host, version_target): Set and AC_SUBST them.
11895 * configure: Rebuild.
11896 * Makefile.in (version_host, version_target): Get from configure.
11897 (version.c): Use $(version_host) and $(version_target).
11898
11899 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
11900
11901 Fix trace-status to output user name without trailing colon.
11902 * tracepoint.c (cmd_qtstatus): Remove unnecessary colon from user name.
11903
11904 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
11905
11906 Fix trace-status to output proper start-time and stop-time.
11907 * tracepoint.c (cmd_qtstatus): Modify trace-status output to
11908 output start time and stop time in hex as gdb expects.
11909
11910 2013-06-26 Pedro Alves <pedro@codesourcery.com>
11911
11912 * tracepoint.c (build_traceframe_info_xml): Output trace state
11913 variables present in the trace buffer.
11914
11915 2013-06-24 Tom Tromey <tromey@redhat.com>
11916
11917 * Makefile.in (version.c): Use bfd/version.h, common/version.in,
11918 create-version.sh.
11919 (version.o): Remove.
11920 * gdbreplay.c: Include version.h.
11921 (version, host_name): Don't declare.
11922 * server.h: Include version.h.
11923 (version, host_name): Don't declare.
11924
11925 2013-06-12 Pedro Alves <palves@redhat.com>
11926
11927 * linux-x86-low.c (linux_is_elf64): Delete global.
11928 (x86_siginfo_fixup): Replace reference to `linux_is_elf64' global
11929 with local linux_pid_exe_is_elf_64_file use.
11930
11931 2013-06-11 Pedro Alves <palves@redhat.com>
11932
11933 * linux-low.c (regset_disabled, disable_regset): New functions.
11934 (regsets_fetch_inferior_registers)
11935 (regsets_store_inferior_registers): Use them.
11936 (initialize_regsets_info); Don't allocate the disabled_regsets
11937 array here.
11938 * linux-low.h (struct regsets_info) <disabled_regsets>: Extend
11939 comment.
11940
11941 2013-06-11 Pedro Alves <palves@redhat.com>
11942
11943 * linux-low.c (initialize_regsets_info): Use xcalloc instead of
11944 xmalloc.
11945
11946 2013-06-11 Pedro Alves <palves@redhat.com>
11947
11948 * linux-x86-low.c (initialize_low_arch): Call
11949 init_registers_x32_avx_linux.
11950
11951 2013-06-09 Jan Kratochvil <jan.kratochvil@redhat.com>
11952
11953 Fix compatibility with Android Bionic.
11954 * linux-low.c (linux_qxfer_libraries_svr4): Ignore first entry even if
11955 it is not empty.
11956
11957 2013-06-07 Pedro Alves <palves@redhat.com>
11958
11959 PR server/14823
11960 * Makefile.in (OBS): Add tdesc.o.
11961 (IPA_OBJS): Add tdesc-ipa.o.
11962 (tdesc-ipa.o): New rule.
11963 * ax.c (gdb_eval_agent_expr): Adjust register_size call to new
11964 interface.
11965 * linux-low.c (new_inferior): Delete.
11966 (disabled_regsets, num_regsets): Delete.
11967 (linux_add_process): Adjust to set the new per-process
11968 new_inferior flag.
11969 (linux_detach_one_lwp): Adjust to call regcache_invalidate_thread.
11970 (linux_wait_for_lwp): Adjust. Only call arch_setup if the event
11971 was a stop. When calling arch_setup, switch the current inferior
11972 to the thread that got an event.
11973 (linux_resume_one_lwp): Adjust to call regcache_invalidate_thread.
11974 (regsets_fetch_inferior_registers)
11975 (regsets_store_inferior_registers): New regsets_info parameter.
11976 Adjust to use it.
11977 (linux_register_in_regsets): New regs_info parameter. Adjust to
11978 use it.
11979 (register_addr, fetch_register, store_register): New usrregs_info
11980 parameter. Adjust to use it.
11981 (usr_fetch_inferior_registers, usr_store_inferior_registers): New
11982 parameter regs_info. Adjust to use it.
11983 (linux_fetch_registers): Get the current inferior's regs_info, and
11984 adjust to use it.
11985 (linux_store_registers): Ditto.
11986 [HAVE_LINUX_REGSETS] (initialize_regsets_info): New.
11987 (initialize_low): Don't initialize the target_regsets here. Call
11988 initialize_low_arch.
11989 * linux-low.h (target_regsets): Delete declaration.
11990 (struct regsets_info): New.
11991 (struct usrregs_info): New.
11992 (struct regs_info): New.
11993 (struct process_info_private) <new_inferior>: New field.
11994 (struct linux_target_ops): Delete the num_regs, regmap, and
11995 regset_bitmap fields. New field regs_info.
11996 [HAVE_LINUX_REGSETS] (initialize_regsets_info): Declare.
11997 * i387-fp.c (num_xmm_registers): Delete.
11998 (i387_cache_to_fsave, i387_fsave_to_cache): Adjust find_regno
11999 calls to new interface.
12000 (i387_cache_to_fxsave, i387_cache_to_xsave, i387_fxsave_to_cache)
12001 (i387_xsave_to_cache): Adjust find_regno calls to new interface.
12002 Infer the number of xmm registers from the regcache's target
12003 description.
12004 * i387-fp.h (num_xmm_registers): Delete.
12005 * inferiors.c (add_thread): Don't install the thread's regcache
12006 here.
12007 * proc-service.c (gregset_info): Fetch the current inferior's
12008 regs_info. Adjust to use it.
12009 * regcache.c: Include tdesc.h.
12010 (register_bytes, reg_defs, num_registers)
12011 (gdbserver_expedite_regs): Delete.
12012 (get_thread_regcache): If the thread doesn't have a regcache yet,
12013 create one, instead of aborting gdbserver.
12014 (regcache_invalidate_one): Rename to ...
12015 (regcache_invalidate_thread): ... this.
12016 (regcache_invalidate_one): New.
12017 (regcache_invalidate): Only invalidate registers of the current
12018 process.
12019 (init_register_cache): Add target_desc parameter, and use it.
12020 (new_register_cache): Ditto. Assert the target description has a
12021 non zero registers_size.
12022 (regcache_cpy): Add assertions. Adjust.
12023 (realloc_register_cache, set_register_cache): Delete.
12024 (registers_to_string, registers_from_string): Adjust.
12025 (find_register_by_name, find_regno, find_register_by_number)
12026 (register_cache_size): Add target_desc parameter, and use it.
12027 (free_register_cache_thread, free_register_cache_thread_one)
12028 (regcache_release, register_cache_size): New.
12029 (register_size): Add target_desc parameter, and use it.
12030 (register_data, supply_register, supply_register_zeroed)
12031 (supply_regblock, supply_register_by_name, collect_register)
12032 (collect_register_as_string, collect_register_by_name): Adjust.
12033 * regcache.h (struct target_desc): Forward declare.
12034 (struct regcache) <tdesc>: New field.
12035 (init_register_cache, new_register_cache): Add target_desc
12036 parameter.
12037 (regcache_invalidate_thread): Declare.
12038 (regcache_invalidate_one): Delete declaration.
12039 (regcache_release): Declare.
12040 (find_register_by_number, register_cache_size, register_size)
12041 (find_regno): Add target_desc parameter.
12042 (gdbserver_expedite_regs, gdbserver_xmltarget): Delete
12043 declarations.
12044 * remote-utils.c: Include tdesc.h.
12045 (outreg, prepare_resume_reply): Adjust.
12046 * server.c: Include tdesc.h.
12047 (gdbserver_xmltarget): Delete declaration.
12048 (get_features_xml, process_serial_event): Adjust.
12049 * server.h [IN_PROCESS_AGENT] (struct target_desc): Forward
12050 declare.
12051 (struct process_info) <tdesc>: New field.
12052 (ipa_tdesc): Declare.
12053 * tdesc.c: New file.
12054 * tdesc.h: New file.
12055 * tracepoint.c: Include tdesc.h.
12056 [IN_PROCESS_AGENT] (ipa_tdesc): Define.
12057 (get_context_regcache): Adjust to pass ipa_tdesc down.
12058 (do_action_at_tracepoint): Adjust to get the register cache size
12059 from the context regcache's description.
12060 (traceframe_walk_blocks): Adjust to get the register cache size
12061 from the current trace frame's description.
12062 (traceframe_get_pc): Adjust to get current trace frame's
12063 description and pass it down.
12064 (gdb_collect): Adjust to get the register cache size from the
12065 IPA's description.
12066 * linux-amd64-ipa.c (tdesc_amd64_linux): Declare.
12067 (gdbserver_xmltarget): Delete.
12068 (initialize_low_tracepoint): Set the ipa's target description.
12069 * linux-i386-ipa.c (tdesc_i386_linux): Declare.
12070 (initialize_low_tracepoint): Set the ipa's target description.
12071 * linux-x86-low.c: Include tdesc.h.
12072 [__x86_64__] (is_64bit_tdesc): New.
12073 (ps_get_thread_area, x86_get_thread_area): Use it.
12074 (i386_cannot_store_register): Rename to ...
12075 (x86_cannot_store_register): ... this. Use is_64bit_tdesc.
12076 (i386_cannot_fetch_register): Rename to ...
12077 (x86_cannot_fetch_register): ... this. Use is_64bit_tdesc.
12078 (x86_fill_gregset, x86_store_gregset): Adjust register_size calls
12079 to new interface.
12080 (target_regsets): Rename to ...
12081 (x86_regsets): ... this.
12082 (x86_get_pc, x86_set_pc): Adjust register_size calls to new
12083 interface.
12084 (x86_siginfo_fixup): Use is_64bit_tdesc.
12085 [__x86_64__] (tdesc_amd64_linux, tdesc_amd64_avx_linux)
12086 (tdesc_x32_avx_linux, tdesc_x32_linux)
12087 (tdesc_i386_linux, tdesc_i386_mmx_linux, tdesc_i386_avx_linux):
12088 Declare.
12089 (x86_linux_update_xmltarget): Delete.
12090 (I386_LINUX_XSAVE_XCR0_OFFSET): Define.
12091 (have_ptrace_getfpxregs, have_ptrace_getregset): New.
12092 (AMD64_LINUX_USER64_CS): New.
12093 (x86_linux_read_description): New, based on
12094 x86_linux_update_xmltarget.
12095 (same_process_callback): New.
12096 (x86_arch_setup_process_callback): New.
12097 (x86_linux_update_xmltarget): New.
12098 (x86_regsets_info): New.
12099 (amd64_linux_regs_info): New.
12100 (i386_linux_usrregs_info): New.
12101 (i386_linux_regs_info): New.
12102 (x86_linux_regs_info): New.
12103 (x86_arch_setup): Reimplement.
12104 (x86_install_fast_tracepoint_jump_pad): Use is_64bit_tdesc.
12105 (x86_emit_ops): Ditto.
12106 (the_low_target): Adjust. Install x86_linux_regs_info,
12107 x86_cannot_fetch_register, and x86_cannot_store_register.
12108 (initialize_low_arch): New.
12109 * linux-ia64-low.c (tdesc_ia64): Declare.
12110 (ia64_fetch_register): Adjust.
12111 (ia64_usrregs_info, regs_info): New globals.
12112 (ia64_regs_info): New function.
12113 (the_low_target): Adjust.
12114 (initialize_low_arch): New function.
12115 * linux-sparc-low.c (tdesc_sparc64): Declare.
12116 (sparc_fill_gregset_to_stack, sparc_store_gregset_from_stack):
12117 Adjust.
12118 (sparc_arch_setup): New function.
12119 (sparc_regsets_info, sparc_usrregs_info, regs_info): New globals.
12120 (the_low_target): Adjust.
12121 (initialize_low_arch): New function.
12122 * linux-ppc-low.c (tdesc_powerpc_32l, tdesc_powerpc_altivec32l)
12123 (tdesc_powerpc_cell32l, tdesc_powerpc_vsx32l)
12124 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_altivec32l)
12125 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_e500l)
12126 (tdesc_powerpc_64l, tdesc_powerpc_altivec64l)
12127 (tdesc_powerpc_cell64l, tdesc_powerpc_vsx64l)
12128 (tdesc_powerpc_isa205_64l, tdesc_powerpc_isa205_altivec64l)
12129 (tdesc_powerpc_isa205_vsx64l): Declare.
12130 (ppc_cannot_store_register, ppc_collect_ptrace_register)
12131 (ppc_supply_ptrace_register, parse_spufs_run, ppc_get_pc)
12132 (ppc_set_pc, ppc_get_hwcap): Adjust.
12133 (ppc_usrregs_info): Forward declare.
12134 (!__powerpc64__) ppc_regmap_adjusted: New global.
12135 (ppc_arch_setup): Adjust to the current process'es target
12136 description.
12137 (ppc_fill_vsxregset, ppc_store_vsxregset, ppc_fill_vrregset)
12138 (ppc_store_vrregset, ppc_fill_evrregset, ppc_store_evrregse)
12139 (ppc_store_evrregset): Adjust.
12140 (target_regsets): Rename to ...
12141 (ppc_regsets): ... this, and make static.
12142 (ppc_usrregs_info, ppc_regsets_info, regs_info): New globals.
12143 (ppc_regs_info): New function.
12144 (the_low_target): Adjust.
12145 (initialize_low_arch): New function.
12146 * linux-s390-low.c (tdesc_s390_linux32, tdesc_s390_linux32v1)
12147 (tdesc_s390_linux32v2, tdesc_s390_linux64, tdesc_s390_linux64v1)
12148 (tdesc_s390_linux64v2, tdesc_s390x_linux64, tdesc_s390x_linux64v1)
12149 (tdesc_s390x_linux64v2): Declare.
12150 (s390_collect_ptrace_register, s390_supply_ptrace_register)
12151 (s390_fill_gregset, s390_store_last_break): Adjust.
12152 (target_regsets): Rename to ...
12153 (s390_regsets): ... this, and make static.
12154 (s390_get_pc, s390_set_pc): Adjust.
12155 (s390_get_hwcap): New target_desc parameter, and use it.
12156 [__s390x__] (have_hwcap_s390_high_gprs): New global.
12157 (s390_arch_setup): Adjust to set the current process'es target
12158 description. Don't adjust the regmap.
12159 (s390_usrregs_info, s390_regsets_info, regs_info): New globals.
12160 [__s390x__] (s390_usrregs_info_3264, s390_regsets_info_3264)
12161 (regs_info_3264): New globals.
12162 (s390_regs_info): New function.
12163 (the_low_target): Adjust.
12164 (initialize_low_arch): New function.
12165 * linux-mips-low.c (tdesc_mips_linux, tdesc_mips_dsp_linux)
12166 (tdesc_mips64_linux, tdesc_mips64_dsp_linux): Declare.
12167 [__mips64] (init_registers_mips_linux)
12168 (init_registers_mips_dsp_linux): Delete defines.
12169 [__mips64] (tdesc_mips_linux, tdesc_mips_dsp_linux): New defines.
12170 (have_dsp): New global.
12171 (mips_read_description): New, based on mips_arch_setup.
12172 (mips_arch_setup): Reimplement.
12173 (get_usrregs_info): New function.
12174 (mips_cannot_fetch_register, mips_cannot_store_register)
12175 (mips_get_pc, mips_set_pc, mips_fill_gregset, mips_store_gregset)
12176 (mips_fill_fpregset, mips_store_fpregset): Adjust.
12177 (target_regsets): Rename to ...
12178 (mips_regsets): ... this, and make static.
12179 (mips_regsets_info, mips_dsp_usrregs_info, mips_usrregs_info)
12180 (dsp_regs_info, regs_info): New globals.
12181 (mips_regs_info): New function.
12182 (the_low_target): Adjust.
12183 (initialize_low_arch): New function.
12184 * linux-arm-low.c (tdesc_arm, tdesc_arm_with_iwmmxt)
12185 (tdesc_arm_with_vfpv2, tdesc_arm_with_vfpv3, tdesc_arm_with_neon):
12186 Declare.
12187 (arm_fill_vfpregset, arm_store_vfpregset): Adjust.
12188 (arm_read_description): New, with bits factored from
12189 arm_arch_setup.
12190 (arm_arch_setup): Reimplement.
12191 (target_regsets): Rename to ...
12192 (arm_regsets): ... this, and make static.
12193 (arm_regsets_info, arm_usrregs_info, regs_info): New globals.
12194 (arm_regs_info): New function.
12195 (the_low_target): Adjust.
12196 (initialize_low_arch): New function.
12197 * linux-m68k-low.c (tdesc_m68k): Declare.
12198 (target_regsets): Rename to ...
12199 (m68k_regsets): ... this, and make static.
12200 (m68k_regsets_info, m68k_usrregs_info, regs_info): New globals.
12201 (m68k_regs_info): New function.
12202 (m68k_arch_setup): New function.
12203 (the_low_target): Adjust.
12204 (initialize_low_arch): New function.
12205 * linux-sh-low.c (tdesc_sharch): Declare.
12206 (target_regsets): Rename to ...
12207 (sh_regsets): ... this, and make static.
12208 (sh_regsets_info, sh_usrregs_info, regs_info): New globals.
12209 (sh_regs_info, sh_arch_setup): New functions.
12210 (the_low_target): Adjust.
12211 (initialize_low_arch): New function.
12212 * linux-bfin-low.c (tdesc_bfin): Declare.
12213 (bfin_arch_setup): New function.
12214 (bfin_usrregs_info, regs_info): New globals.
12215 (bfin_regs_info): New function.
12216 (the_low_target): Adjust.
12217 (initialize_low_arch): New function.
12218 * linux-cris-low.c (tdesc_cris): Declare.
12219 (cris_arch_setup): New function.
12220 (cris_usrregs_info, regs_info): New globals.
12221 (cris_regs_info): New function.
12222 (the_low_target): Adjust.
12223 (initialize_low_arch): New function.
12224 * linux-cris-low.c (tdesc_crisv32): Declare.
12225 (cris_arch_setup): New function.
12226 (cris_regsets_info, cris_usrregs_info, regs_info): New globals.
12227 (cris_regs_info): New function.
12228 (the_low_target): Adjust.
12229 (initialize_low_arch): New function.
12230 * linux-m32r-low.c (tdesc_m32r): Declare.
12231 (m32r_arch_setup): New function.
12232 (m32r_usrregs_info, regs_info): New globals.
12233 (m32r_regs_info): Adjust.
12234 (initialize_low_arch): New function.
12235 * linux-tic6x-low.c (tdesc_tic6x_c64xp_linux)
12236 (tdesc_tic6x_c64x_linux, tdesc_tic6x_c62x_linux): Declare.
12237 (tic6x_usrregs_info): Forward declare.
12238 (tic6x_read_description): New function, based on ...
12239 (tic6x_arch_setup): ... this. Reimplement.
12240 (target_regsets): Rename to ...
12241 (tic6x_regsets): ... this, and make static.
12242 (tic6x_regsets_info, tic6x_usrregs_info, regs_info): New globals.
12243 (tic6x_regs_info): New function.
12244 (the_low_target): Adjust.
12245 (initialize_low_arch): New function.
12246 * linux-xtensa-low.c (tdesc_xtensa): Declare.
12247 (xtensa_fill_gregset, xtensa_store_gregset): Adjust.
12248 (target_regsets): Rename to ...
12249 (xtensa_regsets): ... this, and make static.
12250 (xtensa_regsets_info, xtensa_usrregs_info, regs_info): New
12251 globals.
12252 (xtensa_arch_setup, xtensa_regs_info): New functions.
12253 (the_low_target): Adjust.
12254 (initialize_low_arch): New function.
12255 * linux-nios2-low.c (tdesc_nios2_linux): Declare.
12256 (nios2_arch_setup): Set the current process'es tdesc.
12257 (target_regsets): Rename to ...
12258 (nios2_regsets): ... this.
12259 (nios2_regsets_info, nios2_usrregs_info, regs_info): New globals.
12260 (nios2_regs_info): New function.
12261 (the_low_target): Adjust.
12262 (initialize_low_arch): New function.
12263 * linux-aarch64-low.c (tdesc_aarch64): Declare.
12264 (aarch64_arch_setup): Set the current process'es tdesc.
12265 (target_regsets): Rename to ...
12266 (aarch64_regsets): ... this.
12267 (aarch64_regsets_info, aarch64_usrregs_info, regs_info): New globals.
12268 (aarch64_regs_info): New function.
12269 (the_low_target): Adjust.
12270 (initialize_low_arch): New function.
12271 * linux-tile-low.c (tdesc_tilegx, tdesc_tilegx32): Declare
12272 globals.
12273 (target_regsets): Rename to ...
12274 (tile_regsets): ... this.
12275 (tile_regsets_info, tile_usrregs_info, regs_info): New globals.
12276 (tile_regs_info): New function.
12277 (tile_arch_setup): Set the current process'es tdesc.
12278 (the_low_target): Adjust.
12279 (initialize_low_arch): New function.
12280 * spu-low.c (tdesc_spu): Declare.
12281 (spu_create_inferior, spu_attach): Set the new process'es tdesc.
12282 * win32-arm-low.c (tdesc_arm): Declare.
12283 (arm_arch_setup): New function.
12284 (the_low_target): Install arm_arch_setup instead of
12285 init_registers_arm.
12286 * win32-i386-low.c (tdesc_i386, tdesc_amd64): Declare.
12287 (init_windows_x86): Rename to ...
12288 (i386_arch_setup): ... this. Set `win32_tdesc'.
12289 (the_low_target): Adjust.
12290 * win32-low.c (win32_tdesc): New global.
12291 (child_add_thread): Don't create the thread cache here.
12292 (do_initial_child_stuff): Set the new process'es tdesc.
12293 * win32-low.h (struct target_desc): Forward declare.
12294 (win32_tdesc): Declare.
12295 * lynx-i386-low.c (tdesc_i386): Declare global.
12296 (lynx_i386_arch_setup): Set `lynx_tdesc'.
12297 * lynx-low.c (lynx_tdesc): New global.
12298 (lynx_add_process): Set the new process'es tdesc.
12299 * lynx-low.h (struct target_desc): Forward declare.
12300 (lynx_tdesc): Declare global.
12301 * lynx-ppc-low.c (tdesc_powerpc_32): Declare global.
12302 (lynx_ppc_arch_setup): Set `lynx_tdesc'.
12303 * nto-low.c (nto_tdesc): New global.
12304 (do_attach): Set the new process'es tdesc.
12305 * nto-low.h (struct target_desc): Forward declare.
12306 (nto_tdesc): Declare.
12307 * nto-x86-low.c (tdesc_i386): Declare.
12308 (nto_x86_arch_setup): Set `nto_tdesc'.
12309
12310 2013-06-04 Gary Benson <gbenson@redhat.com>
12311
12312 * server.c (handle_query): Add "augmented-libraries-svr4-read+"
12313 to qSupported response when appropriate.
12314 (handle_qxfer_libraries_svr4): Allow qXfer:libraries-svr4:read
12315 with nonzero-length annex.
12316 * linux-low.c (linux_qxfer_libraries_svr4): Parse and handle
12317 arguments supplied in annex.
12318
12319 2013-05-31 Doug Evans <dje@google.com>
12320
12321 PR server/15594
12322 * linux-x86-low.c (ps_get_thread_area): Properly extend address to
12323 64 bits in 64-cross-32 environment.
12324
12325 2013-05-28 Pedro Alves <palves@redhat.com>
12326
12327 * Makefile.in (clean): Remove reference to aarch64-without-fpu.c.
12328 (aarch64-without-fpu.c): Delete rule.
12329 * configure.srv (aarch64*-*-linux*): Remove references to
12330 aarch64-without-fpu.o and aarch64-without-fpu.xml.
12331 * linux-aarch64-low.c (init_registers_aarch64_without_fpu): Remove
12332 declaration.
12333
12334 2013-05-24 Pedro Alves <palves@redhat.com>
12335
12336 * server.c (handle_v_cont) <vCont;r>: Use unpack_varlen_hex
12337 instead of strchr/decode_address. Error if the range isn't split
12338 with a ','. Don't assume there's be a ':' in the action.
12339
12340 2013-05-23 Yao Qi <yao@codesourcery.com>
12341 Pedro Alves <palves@redhat.com>
12342
12343 * linux-low.c (lwp_in_step_range): New function.
12344 (linux_wait_1): If the thread was range stepping and stopped
12345 outside the stepping range, report the stop to GDB. Otherwise,
12346 continue stepping. Add range stepping debug output.
12347 (linux_set_resume_request): Copy the step range from the resume
12348 request to the lwp.
12349 (linux_supports_range_stepping): New.
12350 (linux_target_ops) <supports_range_stepping>: Set to
12351 linux_supports_range_stepping.
12352 * linux-low.h (struct linux_target_ops)
12353 <supports_range_stepping>: New field.
12354 (struct lwp_info) <step_range_start, step_range_end>: New fields.
12355 * linux-x86-low.c (x86_supports_range_stepping): New.
12356 (the_low_target) <supports_range_stepping>: Set to
12357 x86_supports_range_stepping.
12358 * server.c (handle_v_cont): Handle 'r' action.
12359 (handle_v_requests): Append ";r" if the target supports range
12360 stepping.
12361 * target.h (struct thread_resume) <step_range_start,
12362 step_range_end>: New fields.
12363 (struct target_ops) <supports_range_stepping>:
12364 New field.
12365 (target_supports_range_stepping): New macro.
12366
12367 2013-05-17 Joel Brobecker <brobecker@adacore.com>
12368
12369 * lynx-low.c (lynx_resume): Fix null_ptid/minus_one_ptid
12370 confusion in comment.
12371
12372 2013-05-17 Joel Brobecker <brobecker@adacore.com>
12373
12374 * lynx-low.c (struct process_info_private): New type.
12375 (lynx_add_process): New function.
12376 (lynx_create_inferior, lynx_attach): Replace calls to
12377 add_process by calls to lynx_add_process.
12378 (lynx_resume): If PTID is null, then try using
12379 current_process()->private->last_wait_event_ptid.
12380 Add comments.
12381 (lynx_clear_inferiors): Delete. The contents of that function
12382 has been inlined in lynx_mourn;
12383 (lynx_wait_1): Save the ptid in the process's private data.
12384 (lynx_mourn): Free the process' private data. Replace call
12385 to lynx_clear_inferiors by call to clear_inferiors.
12386
12387 2013-05-17 Yao Qi <yao@codesourcery.com>
12388
12389 * i386-low.c (i386_length_and_rw_bits): Move the comment to
12390 the right place.
12391
12392 2013-05-16 Luis Machado <lgustavo@codesourcery.com>
12393
12394 * linux-low.c: Move definition checks upwards for PT_TEXT_ADDR,
12395 PT_DATA_ADDR and PT_TEXT_END_ADDR. Update comments.
12396 (linux_read_offsets): Remove PT_TEXT_ADDR, PT_DATA_ADDR and
12397 PT_TEXT_END_ADDR guards. Update comments.
12398 (linux_target_op) <read_offsets>: Conditionally define to
12399 linux_read_offsets if the target is UCLIBC and if it defines
12400 PT_TEXT_ADDR, PT_DATA_ADDR and PT_TEXT_END_ADDR.
12401
12402 2013-05-06 Sandra Loosemore <sandra@codesourcery.com>
12403 Andrew Jenner <andrew@codesourcery.com>
12404
12405 * Makefile.in (SFILES): Add linux-nios2-low.c.
12406 (clean): Add action to delete nios2-linux.c.
12407 (nios2-linux.c): New rule.
12408 * configure.srv: Add nios2*-*-linux*.
12409 * linux-nios2-low.c: New.
12410
12411 2013-05-03 Hafiz Abid Qadeer <abidh@codesourcery.com>
12412
12413 * tracepoint.c (cmd_qtinit): Call 'stop_tracing'.
12414
12415 2013-04-25 Hui Zhu <hui@codesourcery.com>
12416
12417 PR gdb/15186
12418 * ax.c (ax_printf): Add fflush.
12419
12420 2013-04-22 Tom Tromey <tromey@redhat.com>
12421
12422 * Makefile.in (SFILES): Add filestuff.c.
12423 (OBS): Add filestuff.o.
12424 (filestuff.o): New target.
12425 * config.in, configure: Rebuild.
12426 * configure.ac: Check for fdwalk, pipe2.
12427
12428 2013-04-17 Pedro Alves <palves@redhat.com>
12429
12430 * configure.ac (USE_THREAD_DB): Delete variable.
12431 (if test "$srv_linux_thread_db" = "yes"): AC_DEFINE USE_THREAD_DB.
12432 Don't AC_SUBST USE_THREAD_DB.
12433 * Makefile.in (INTERNAL_CFLAGS): Remove @USE_THREAD_DB@.
12434 * config.in, configure: Regenerate.
12435
12436 2013-04-16 Pedro Alves <palves@redhat.com>
12437
12438 * linux-low.h (struct lwp_info) <thread_known>: Move under
12439 the USE_THREAD_DB #ifdef.
12440
12441 2013-04-16 Pedro Alves <palves@redhat.com>
12442
12443 * Makefile.in (INTERNAL_CFLAGS): Add @USE_THREAD_DB@.
12444 (linux-low.o): Delete rule.
12445 * linux-low.h: Always include "gdb_thread_db.h" instead of
12446 conditionally including thread_db.h.
12447 (struct lwp_info) <th>: Guard with #ifdef USE_THREAD_DB instead of
12448 HAVE_THREAD_DB_H.
12449
12450 2013-04-07 Jan Kratochvil <jan.kratochvil@redhat.com>
12451
12452 * Makefile.in (install-only): Fix make install regression.
12453
12454 2013-04-05 Jan Kratochvil <jan.kratochvil@redhat.com>
12455
12456 Convert man pages to texinfo, new gdbinit.5 texinfo page.
12457 * Makefile.in (install-only): Remove $(man1dir) and gdbserver.1
12458 installation.
12459 * gdbserver.1: Remove.
12460
12461 2013-03-22 Pedro Alves <palves@redhat.com>
12462
12463 * linux-low.c (handle_extended_wait): Don't call
12464 linux_enable_event_reporting.
12465
12466 2013-03-15 Tony Theodore <tonyt@logyst.com>
12467
12468 PR build/9098:
12469 * Makefile.in (SHELL): Use @SHELL@.
12470
12471 2013-03-14 Sergio Durigan Junior <sergiodj@redhat.com>
12472
12473 * tracepoint.c (cmd_qtv): Initialize `val' with zero, silencing
12474 compiler warning.
12475
12476 2013-03-13 Joel Brobecker <brobecker@adacore.com>
12477
12478 * linux-low.c (linux_target_ops) [!HAVE_LINUX_BTRACE]:
12479 Remove extraneous NULL element.
12480
12481 2013-03-13 Yao Qi <yao@codesourcery.com>
12482
12483 * tracepoint.c (traceframe_read_tsv): Look for the last matched
12484 'V' block in trace frame.
12485
12486 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
12487
12488 * target.h (struct target_ops): Add btrace ops.
12489 (target_supports_btrace): New macro.
12490 (target_enable_btrace): New macro.
12491 (target_disable_btrace): New macro.
12492 (target_read_btrace): New macro.
12493 * gdbthread.h (struct thread_info): Add btrace field.
12494 * server.c: Include btrace-common.h.
12495 (handle_btrace_general_set): New function.
12496 (handle_btrace_enable): New function.
12497 (handle_btrace_disable): New function.
12498 (handle_general_set): Call handle_btrace_general_set.
12499 (handle_qxfer_btrace): New function.
12500 (struct qxfer qxfer_packets[]): Add btrace entry.
12501 * inferiors.c (remove_thread): Disable btrace.
12502 * linux-low: Include linux-btrace.h.
12503 (linux_low_enable_btrace): New function.
12504 (linux_low_read_btrace): New function.
12505 (linux_target_ops): Add btrace ops.
12506 * configure.srv (i[34567]86-*-linux*): Add linux-btrace.o.
12507 Add srv_linux_btrace=yes.
12508 (x86_64-*-linux*): Add linux-btrace.o.
12509 Add srv_linux_btrace=yes.
12510 * configure.ac: Define HAVE_LINUX_BTRACE.
12511 * config.in: Regenerated.
12512 * configure: Regenerated.
12513
12514 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
12515
12516 * server.c (handle_qxfer): Preserve error message if -3 is
12517 returned.
12518 (qxfer): Document the -3 return value.
12519
12520 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
12521
12522 * Makefile.in (SFILES): Add $(srcdir)/common/linux-btrace.c.
12523 (linux_btrace_h): New variable.
12524 (linux-btrace.o): New rule.
12525
12526 2013-03-08 Stan Shebs <stan@codesourcery.com>
12527 Hafiz Abid Qadeer <abidh@codesourcery.com>
12528
12529 * tracepoint.c (trace_buffer_size): New global.
12530 (DEFAULT_TRACE_BUFFER_SIZE): New define.
12531 (init_trace_buffer): Change to one-argument function. Allocate
12532 trace buffer memory.
12533 (handle_tracepoint_general_set): Call cmd_bigqtbuffer_size to
12534 handle QTBuffer:size packet.
12535 (cmd_bigqtbuffer_size): New function.
12536 (initialize_tracepoint): Call init_trace_buffer with
12537 DEFAULT_TRACE_BUFFER_SIZE.
12538 * server.c (handle_query): Add QTBuffer:size in the
12539 supported packets.
12540
12541 2013-03-07 Yao Qi <yao@codesourcery.com>
12542
12543 * tracepoint.c (cur_action, cur_step_action): Make them unsigned.
12544 (cmd_qtfp): Initialize cur_action and cur_step_action 0 instead
12545 of -1.
12546 (cmd_qtsp): Adjust condition. Do post increment.
12547 Set cur_action and cur_step_action back to 0.
12548
12549 2013-03-07 Jeremy Bennett <jeremy.bennett@embecosm.com>
12550
12551 PR server/15236
12552 * linux-low.c (linux_write_memory): Return early success if LEN is
12553 zero.
12554
12555 2013-03-05 Corinna Vinschen <vinschen@redhat.de>
12556
12557 * configure.srv: Add x86_64-*-cygwin* as target.
12558
12559 2013-02-28 Tom Tromey <tromey@redhat.com>
12560
12561 * configure.ac: Invoke AC_SYS_LARGEFILE.
12562 * configure, config.in: Rebuild.
12563
12564 2013-02-28 Corinna Vinschen <vinschen@redhat.com>
12565
12566 * win32-low.c: Throughout, fix format strings and casts of
12567 printf-like functions to avoid type related warnings on all
12568 platforms.
12569 (get_child_debug_event): Print dwDebugEventCode as hex since
12570 that's how it's usually documented.
12571
12572 2013-02-28 Yao Qi <yao@codesourcery.com>
12573
12574 * tracepoint.c (cmd_qtbuffer): Call phex_nz instead of
12575 pulongest.
12576
12577 2013-02-27 Jiong Wang <jiwang@tilera.com>
12578
12579 * Makefile.in (clean): Remove reg-tilegx.c, reg-tilegx32.c.
12580 (reg-tilegx32.c): New rule.
12581 * configure.srv (tilegx-*-linux*): Add reg-tilegx32.o to srv_regobj.
12582 * linux-tile-low.c (tile_arch_setup): New function. Invoke
12583 different register info initializer according to elf class.
12584 (init_registers_tilgx32): New function. The tilegx32 register info
12585 initializer.
12586 (tile_fill_gregset): Use "uint_reg_t" to represent register size.
12587 (tile_store_gregset): Likewise.
12588
12589 2013-02-27 Yao Qi <yao@codesourcery.com>
12590
12591 * server.c (process_point_options): Print debug message when
12592 debug_threads is true.
12593
12594 2013-02-26 Yao Qi <yao@codesourcery.com>
12595
12596 * tracepoint.c (cmd_qtbuffer): Don't set '\0' in OWN_BUF.
12597
12598 2013-02-19 Pedro Alves <palves@redhat.com>
12599 Kai Tietz <ktietz@redhat.com>
12600
12601 PR gdb/15161
12602
12603 * server.c (handle_query) <CRC check>: Use unpack_varlen_hex
12604 instead of strtoul to extract address from packet.
12605 (process_serial_event) <'z'>: Likewise.
12606
12607 2013-02-18 Yao Qi <yao@codesourcery.com>
12608
12609 * linux-bfin-low.c (the_low_target): Use NULL instead of 0.
12610
12611 2013-02-14 Pedro Alves <palves@redhat.com>
12612
12613 Plug memory leak.
12614
12615 * tracepoint.c (cmd_qtnotes): Free TRACING_USER_NAME,
12616 TRACING_NOTES and TRACING_STOP_NOTE before clobbering.
12617
12618 2013-02-14 Pedro Alves <palves@redhat.com>
12619
12620 * tracepoint.c (cmd_qtdpsrc): Use savestring.
12621
12622 2013-02-14 Pedro Alves <palves@redhat.com>
12623
12624 * tracepoint.c (save_string): Delete.
12625 (add_tracepoint_action): Use savestring instead of save_string.
12626
12627 2013-02-12 Pedro Alves <palves@redhat.com>
12628
12629 * linux-xtensa-low.c: Ditto.
12630 * xtensa-xtregs.c: Ditto.
12631
12632 2013-02-12 Sanimir Agovic <sanimir.agovic@intel.com>
12633
12634 * thread-db.c (thread_db_get_tls_address): NULL pointer check
12635 thread_db.
12636
12637 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
12638
12639 * linux-aarch64-low.c (aarch64_arch_setup): Clamp
12640 aarch64_num_wp_regs and aarch64_num_bp_regs to
12641 AARCH64_HWP_MAX_NUM and AARCH64_HBP_MAX_NUM respectively.
12642
12643 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
12644
12645 * linux-aarch64-low.c (ps_get_thread_area): Replace
12646 PTRACE_GET_THREAD_AREA with PTRACE_GETREGSET.
12647
12648 2013-02-04 Jim MacArthur <jim.macarthur@arm.com>
12649 Marcus Shawcroft <marcus.shawcroft@arm.com>
12650 Nigel Stephens <nigel.stephens@arm.com>
12651 Yufeng Zhang <yufeng.zhang@arm.com>
12652
12653 * Makefile.in (clean): Remove aarch64.c and aarch64-without-fpu.c.
12654 (aarch64.c, aarch64-without-fpu.c): New targets.
12655 * configure.srv (aarch64*-*-linux*): New.
12656 * linux-aarch64-low.c: New file.
12657
12658 2013-02-04 Marcus Shawcroft <marcus.shawcroft@arm.com>
12659
12660 * linux-low.c (handle_extended_wait, linux_create_inferior)
12661 (linux_attach_lwp_1, linux_kill_one_lwp, linux_attach_one_lwp)
12662 (dequeue_one_deferred_signal, linux_resume_one_thread)
12663 (fetch_register, linux_write_memory, linux_enable_event_reporting)
12664 (linux_tracefork_grandchild, linux_test_for_tracefork)
12665 (linux_read_offsets, linux_xfer_siginfo, linux_xfer_siginfo): Add
12666 PTRACE_ARG3_TYPE and PTRACE_ARG4_TYPE cast to ptrace arguments
12667 where the argument is 0.
12668
12669 2013-01-25 Yao Qi <yao@codesourcery.com>
12670
12671 * event-loop.c: Include "queue.h".
12672 (gdb_event_p): New typedef.
12673 (struct gdb_event) <next_event>: Remove.
12674 (event_queue): Change to QUEUE(gdb_event_p).
12675 (async_queue_event): Remove.
12676 (gdb_event_xfree): New.
12677 (initialize_event_loop): New.
12678 (process_event): Use API from QUEUE.
12679 (wait_for_event): Likewise.
12680 * server.c (main): Call initialize_event_loop.
12681 * server.h (initialize_event_loop): Declare.
12682
12683 2013-01-18 Yao Qi <yao@codesourcery.com>
12684
12685 * ax.h (struct eval_agent_expr_context): New.
12686 (gdb_eval_agent_expr): Update declaration.
12687 * ax.c (gdb_eval_agent_expr): Remove argument REGCACHE and
12688 TFRAME. Add new argument CTX.
12689 * server.h (struct eval_agent_expr_context): Declare.
12690 (agent_mem_read, agent_tsv_read): Update declaration.
12691 (agent_mem_read_string): Likewise.
12692 * tracepoint.c (eval_tracepoint_agent_expr): Remove.
12693 (add_traceframe_block): Add new argument TPOINT.
12694 Increase TPOINT->traceframe_usage.
12695 (do_action_at_tracepoint): Call gdb_eval_agent_expr instead of
12696 eval_tracepoint_agent_expr.
12697 (condition_true_at_tracepoint): Likewise.
12698 (agent_mem_read): Remove argument TFRAME. Add argument CTX.
12699 (agent_mem_read_string, agent_tsv_read): Likewise.
12700
12701 2013-01-16 Yao Qi <yao@codesourcery.com>
12702
12703 * linux-low.c (linux_resume_one_lwp): Don't check
12704 'lwp->bp_reinsert != 0'.
12705
12706 2013-01-07 Joel Brobecker <brobecker@adacore.com>
12707 Pedro Alves <palves@redhat.com>
12708
12709 * lynx-low.c (ptrace_request_to_str): Define a temporary
12710 macro and use it to simplify this function's implementation.
12711
12712 2013-01-07 Joel Brobecker <brobecker@adacore.com>
12713
12714 * lynx-low.c (lynx_resume): Call perror_with_name if lynx_ptrace
12715 sets errno.
12716
12717 2013-01-07 Joel Brobecker <brobecker@adacore.com>
12718
12719 * configure.srv (i[34567]86-*-lynxos*): Set srv_xmlfiles.
12720
12721 2013-01-07 Joel Brobecker <brobecker@adacore.com>
12722
12723 * configure.srv (powerpc-*-lynxos*): Set srv_xmlfiles.
12724
12725 2013-01-07 Joel Brobecker <brobecker@adacore.com>
12726
12727 * lynx-low.c (lynx_resume): Use the resume_info parameter
12728 to determine the ptid for the lynx_ptrace call, unless
12729 it is equal to minus_one_ptid, in which case we use the
12730 ptid of the current_inferior.
12731 (lynx_wait_1): After having received a thread create/exit
12732 event, resume the inferior's execution using the signaling
12733 thread's ptid, rather than the old ptid.
12734
12735 2013-01-07 Joel Brobecker <brobecker@adacore.com>
12736
12737 * lynx-low.c (lynx_resume): Delete variable ret.
12738
12739 2013-01-01 Joel Brobecker <brobecker@adacore.com>
12740
12741 * gdbreplay.c (gdbreplay_version): Update copyright year.
12742 * server.c (gdbserver_version): Likewise.
12743
12744 2012-12-17 Joel Brobecker <brobecker@adacore.com>
12745
12746 * lynx-low.c (lynx_wait_1): Add debug trace before adding
12747 new thread.
12748
12749 2012-12-17 Joel Brobecker <brobecker@adacore.com>
12750
12751 * lynx-low.c (ptrace_request_to_str): Add handling for
12752 PTRACE_GETTRACESIG.
12753
12754 2012-12-17 Joel Brobecker <brobecker@adacore.com>
12755
12756 * lynx-low.c (lynx_attach): Delete variable new_process.
12757
12758 2012-12-17 Joel Brobecker <brobecker@adacore.com>
12759
12760 * lynx-low.c (lynx_create_inferior): Delete variable
12761 new_process.
12762
12763 2012-12-17 Joel Brobecker <brobecker@adacore.com>
12764
12765 * lynx-low.c (ptrace_request_to_str): Do not handle
12766 PTRACE_GETTHREADLIST if this macro does not exist.
12767
12768 2012-12-15 Yao Qi <yao@codesourcery.com>
12769
12770 * Makefile.in (OBS): Add notif.o.
12771 * notif.c, notif.h: New.
12772 * server.c: Include "notif.h".
12773 (struct vstop_notif) <next>: Remove.
12774 <base>: New field.
12775 (queue_stop_reply): Update.
12776 (push_event, send_next_stop_reply): Remove.
12777 (discard_queued_stop_replies): Update.
12778 (notif_stop): New variable.
12779 (handle_v_stopped): Remove.
12780 (handle_v_requests): Don't call handle_v_stopped. Call
12781 handle_ack_notif instead.
12782 (queue_stop_reply_callback): Call notif_event_enque instead
12783 of queue_stop_reply.
12784 (handle_status): Don't call send_next_stop_reply, call
12785 notif_write_event instead.
12786 (kill_inferior_callback): Likewise.
12787 (detach_or_kill_inferior_callback): Likewise.
12788 (main): Call initialize_notif.
12789 (process_serial_event): Call QUEUE_is_empty.
12790 (handle_target_event): Call notif_push instead of push event.
12791 * server.h (push_event): Remove declaration.
12792
12793 2012-12-10 Tom Tromey <tromey@redhat.com>
12794
12795 * Makefile.in (DEPMODE, DEPDIR, depcomp, COMPILE.pre)
12796 (COMPILE.post, COMPILE, POSTCOMPILE, IPAGENT_COMPILE): New
12797 macros.
12798 (.c.o): Rewrite.
12799 (ax-ipa.o, tracepoint-ipa.o, utils-ipa.o, format-ipa.o)
12800 (common-utils-ipa.o, remote-utils-ipa.o, regcache-ipa.o)
12801 (i386-linux-ipa.o, linux-i386-ipa.o, linux-amd64-ipa.o)
12802 (amd64-linux-ipa.o, ax.o): Rewrite.
12803 (event-loop.o, hostio.o, hostio-errno.o, inferiors.o, mem-break.o)
12804 (proc-service.o, regcache.o, remote-utils.o, server.o, target.o)
12805 (thread-db.o, tracepoint.o, utils.o, gdbreplay.o, dll.o): Remove.
12806 (signals.o, linux-procfs.o, linux-ptrace.o, common-utils.o, vec.o)
12807 (gdb_vecs.o, xml-utils.o, linux-osdata.o, ptid.o, buffer.o)
12808 (format.o, agent.o, vasprintf.o, vsnprintf.o): Rewrite.
12809 (i386-low.o, i387-fp.o, linux-low.o, linux-arm-low.o)
12810 (linux-bfin-low.o, linux-cris-low.o, linux-crisv32-low.o)
12811 (linux-ia64-low.o, linux-m32r-low.o, linux-mips-low.o)
12812 (linux-ppc-low.o, linux-s390-low.o, linux-sh-low.o)
12813 (linux-tic6x-low.o, linux-x86-low.o, linux-xtensa-low.o)
12814 (linux-tile-low.o, lynx-low.o, lynx-ppc-low.o, nto-low.o)
12815 (nto-x86-low.o, linux-low.o, win32-low.o, win32-arm-low.o)
12816 (win32-i386-low.o, spu-low.o, reg-arm.o, arm-with-iwmmxt.o)
12817 (arm-with-vfpv2.o, arm-with-vfpv3.o, arm-with-neon.o, reg-bfin.o)
12818 (reg-cris.o, reg-crisv32.o, i386.o, i386-linux.o, i386-avx.o)
12819 (i386-avx-linux.o, i386-mmx.o, i386-mmx-linux.o, reg-ia64.o)
12820 (reg-m32r.o, reg-m68k.o, reg-cf.o, mips-linux.o, mips-dsp-linux.o)
12821 (mips64-linux.o, mips64-dsp-linux.o, powerpc-32.o, powerpc-32l.o)
12822 (powerpc-altivec32l.o, powerpc-cell32l.o, powerpc-vsx32l.o)
12823 (powerpc-isa205-32l.o, powerpc-isa205-altivec32l.o)
12824 (powerpc-isa205-vsx32l.o, powerpc-e500l.o, powerpc-64l.o)
12825 (powerpc-altivec64l.o, powerpc-cell64l.o, powerpc-vsx64l.o)
12826 (powerpc-isa205-64l.o, powerpc-isa205-altivec64l.o)
12827 (powerpc-isa205-vsx64l.o, s390-linux32.o, s390-linux32v1.o)
12828 (s390-linux32v2.o, s390-linux64.o, s390-linux64v1.o)
12829 (s390-linux64v2.o, s390x-linux64.o, s390x-linux64v1.o)
12830 (s390x-linux64v2.o, tic6x-c64xp-linux.o, tic6x-c64x-linux.o)
12831 (tic6x-c62x-linux.o, reg-sh.o, reg-sparc64.o, reg-spu.o, amd64.o)
12832 (amd64-linux.o, amd64-avx.o, amd64-avx-linux.o, x32.o)
12833 (x32-linux.o, x32-avx.o, x32-avx-linux.o, reg-xtensa.o)
12834 (reg-tilegx.o): Remove.
12835 (all_object_files): New macro.
12836 Include .deps files.
12837 * aclocal.m4, configure: Rebuild.
12838 * acinclude.m4: Include depstand.m4, lead-dot.m4.
12839 * configure.ac: Invoke ZW_CREATE_DEPDIR,
12840 ZW_PROG_COMPILER_DEPENDENCIES. Compute GMAKE condition.
12841
12842 2012-12-05 Tom Tromey <tromey@redhat.com>
12843
12844 PR gdb/14917:
12845 * server.h (current_insn_ptr, emit_error): Declare 'extern'.
12846
12847 2012-11-28 Markus Metzger <markus.t.metzger@intel.com>
12848
12849 * configure.ac: Check for linux/perf_event.h.
12850 * config.in: Regenerated.
12851 * configure: Regenerated.
12852
12853 2012-11-26 Maxime Villard <rustyBSD@gmx.fr>
12854
12855 * hostio.c (handle_readlink): Decrease buffer size
12856 parameter passed to readlink by one byte.
12857
12858 2012-11-26 Yao Qi <yao@codesourcery.com>
12859
12860 * configure.ac (build_warnings): Append '-Wempty-body'.
12861 * configure: Regenerated.
12862 * linux-low.c (linux_create_inferior): Use braces for empty 'if'
12863 body.
12864
12865 2012-11-15 Pierre Muller <muller@sourceware.org>
12866
12867 * configure.ac (AC_CHECK_HEADERS): Add wait.h header.
12868 * config.in: Regenerate.
12869 * configure: Regenerate.
12870 * linux-low.c: Use "gdb_stat.h" header instead of <sys/stat.h> header.
12871 Use "gdb_wait.h" header instead of <sys/wait.h> header.
12872 * lynx-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
12873 * remote-utils.c: Use "gdb_stat.h" header instead of <sys/stat.h>
12874 header.
12875 * server.c: Remove HAVE_WAIT_H conditional. Use "gdb_wait.h" header
12876 instead of <sys/wait.h> header.
12877 * spu-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
12878
12879 2012-11-13 Markus Metzger <markus.t.metzger@intel.com>
12880
12881 * Makefile.in: (INTERNAL_CFLAGS): Add -DGDBSERVER
12882 (various make rules): Remove -DGDBSERVER
12883
12884 2012-11-09 Yao Qi <yao@codesourcery.com>
12885
12886 * spu-low.c (current_ptid): Move it to ..
12887 * gdbthread.h: ... here. New.
12888 * remote-utils.c (read_ptid): Use macro 'current_ptid'.
12889 * server.c (myresume, process_serial_event): Likewise.
12890 * thread-db.c (thread_db_find_new_threads): Likewise.
12891 * tracepoint.c (run_inferior_command): Likewise.
12892
12893 2012-10-01 Andrew Burgess <aburgess@broadcom.com>
12894
12895 * server.c (handle_search_memory_1): Include access length in
12896 warning message.
12897
12898 2012-09-05 Michael Brandt <michael.brandt@axis.com>
12899
12900 * linux-crisv32-low.c: Fix compile errors.
12901
12902 2012-09-04 Yao Qi <yao@codesourcery.com>
12903
12904 * tracepoint.c (cmd_qtsv): Adjust debug message.
12905 Don't check CUR_TPOINT.
12906
12907 2012-08-28 Yao Qi <yao@codesourcery.com>
12908
12909 * ax.c, tracepoint.c: Replace ATTR_FORMAT with ATTRIBUTE_PRINTF.
12910 * server.h: Include 'libiberty.h' and 'ansidecl.h'.
12911 (ATTR_NORETURN, ATTR_FORMAT, ATTR_MALLOC): Remove.
12912 Remove declarations of xmalloc, xreallloc, xstrdup and
12913 freeargv.
12914 * Makefile.in (libiberty_h): New.
12915 (server_h): Append dependencies 'libiberty.h' and 'ansidecl.h'.
12916 (linux-bfin-low.o): Append dependency 'libiberty.h'.
12917
12918 2012-08-23 Yao Qi <yao@codesourcery.com>
12919
12920 * server.h: Remove declaration of 'xsnprintf'.
12921
12922 2012-08-22 Keith Seitz <keiths@redhat.com>
12923
12924 * server.h: Include build-gnulib-gbserver/config.h.
12925 * gdbreplay.c: Likewise.
12926
12927 2012-08-08 Doug Evans <dje@google.com>
12928
12929 * Makefile.in (SFILES): Add gdb_vecs.c.
12930 (OBS): Add gdb_vecs.o.
12931 (gdb_vecs_h, host_defs_h): New variables.
12932 (thread-db.o): Add $(gdb_vecs_h) dependency.
12933 (gdb_vecs.o): New rule.
12934 * thread-db.c: #include "gdb_vecs.h".
12935 (thread_db_load_search): Use a vector to iterate over path elements.
12936 Handle text appearing after "$pdir".
12937
12938 * configure.ac: Add check for strstr.
12939 * config.in: Regenerate.
12940 * configure: Regenerate.
12941
12942 2012-08-02 Ulrich Weigand <ulrich.weigand@linaro.org>
12943
12944 * hostio.c (handle_pread): If pread fails, fall back to attempting
12945 lseek/read.
12946 (handle_pwrite): Likewise for pwrite.
12947
12948 2012-08-01 Ulrich Weigand <ulrich.weigand@linaro.org>
12949
12950 * linux-arm-low.c (arm_linux_hw_point_initialize): Distinguish
12951 between unsupported TYPE and unimplementable ADDR/LEN combination.
12952 (arm_insert_point): Act on new return value.
12953
12954 2012-07-31 Pedro Alves <palves@redhat.com>
12955
12956 * server.c (process_point_options): Only skip tokens if we find
12957 one that is unrecognized. Don't treat 'X' specially while
12958 skipping unrecognized tokens.
12959
12960 2012-07-30 Ulrich Weigand <ulrich.weigand@linaro.org>
12961
12962 * linux-arm-low.c (arm_linux_hw_point_initialize): Do not attempt
12963 to 4-byte-align HW breakpoint addresses for Thumb.
12964
12965 2012-07-27 Yao Qi <yao@codesourcery.com>
12966
12967 PR remote/14161.
12968
12969 * server.h: Declare gdb_agent_about_to_close.
12970 * target.c (kill_inferior): Include "agent.h".
12971 New. Send command 'kill'.
12972 * target.h (kill_inferior): Removed macro.
12973 * tracepoint.c (gdb_agent_about_to_close): New.
12974 (gdb_agent_helper_thread): Handle command 'close'.
12975 Wait endlessly until the inferior stops.
12976 Install gdb_agent_remove_socket to atexit hook.
12977 (agent_socket_name): New static variable.
12978 (gdb_agent_socket_init): Replace local variable 'name' with
12979 'agent_socket_name'.
12980 (gdb_agent_remove_socket): New.
12981
12982 2012-07-27 Yao Qi <yao@codesourcery.com>
12983
12984 * server.c (process_point_options): Stop at 'X' when parsing.
12985
12986 2012-07-19 Michael Eager <eager@eagercon.com>
12987
12988 * i386-low.c (Z_packet_to_hw_type): Add Z_PACKET_HW_BP, translate
12989 to hw_execute.
12990 * linux-x86-low.c (x86_insert_point, x86_remove_point):
12991 Call i386_low_insert_watchpoint, i386_low_remove_watchpoint to add/del
12992 hardware breakpoint.
12993
12994 2012-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
12995
12996 * gdbserver/linux-low.c (initialize_low): Call
12997 linux_ptrace_init_warnings.
12998
12999 2012-07-02 Doug Evans <dje@google.com>
13000
13001 * mem-break.c (gdb_no_commands_at_breakpoint): Fix cast from
13002 pointer to int.
13003
13004 2012-07-02 Stan Shebs <stan@codesourcery.com>
13005
13006 * Makefile.in (WARN_CFLAGS_NO_FORMAT): Define.
13007 (ax.o): Add it to build rule.
13008 (ax-ipa.o): Ditto.
13009 (OBS): Add format.o.
13010 (IPA_OBS): Add format.o.
13011 * server.c (handle_query): Claim support for breakpoint commands.
13012 (process_point_options): Add command case.
13013 (process_serial_event): Leave running if there are printfs in
13014 effect.
13015 * mem-break.h (any_persistent_commands): Declare.
13016 (add_breakpoint_commands): Declare.
13017 (gdb_no_commands_at_breakpoint): Declare.
13018 (run_breakpoint_commands): Declare.
13019 * mem-break.c (struct point_command_list): New struct.
13020 (struct breakpoint): New field command_list.
13021 (any_persistent_commands): New function.
13022 (add_commands_to_breakpoint): New function.
13023 (add_breakpoint_commands): New function.
13024 (gdb_no_commands_at_breakpoint): New function.
13025 (run_breakpoint_commands): New function.
13026 * linux-low.c (linux_wait_1): Test for and run breakpoint commands
13027 locally.
13028 * ax.c: Include format.h.
13029 (ax_printf): New function.
13030 (gdb_eval_agent_expr): Add printf opcode.
13031
13032 2012-06-13 Yao Qi <yao@codesourcery.com>
13033
13034 * server.c (start_inferior): Remove duplicated writes to fields
13035 'last_resume_kind' and 'last_status' of 'current_inferior'.
13036
13037 2012-06-12 Yao Qi <yao@codesourcery.com>
13038 Pedro Alves <palves@redhat.com>
13039
13040 * linux-low.c (linux_set_resume_request): Simplify predicate. Add
13041 comment.
13042 * server.c (handle_v_cont): Extend comment.
13043
13044 2012-06-11 Yao Qi <yao@codesourcery.com>
13045
13046 * linux-low.c (linux_attach): Add 'static'.
13047
13048 2012-06-06 Yao Qi <yao@codesourcery.com>
13049
13050 * ax.c (gdb_eval_agent_expr): Print `top' in hex.
13051
13052 2012-06-01 Jan Kratochvil <jan.kratochvil@redhat.com>
13053
13054 Fix gcc -flto compilation warning.
13055 * server.c (main): Make variable multi_mode and attach volatile.
13056
13057 2012-05-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
13058
13059 * linux-low.c (get_r_debug): Disable code using DT_MIPS_RLD_MAP
13060 if the platform doesn't know about it.
13061
13062 2012-05-30 Jeff Kenton <jkenton@tilera.com>
13063
13064 * Makefile.in (SFILES): Add linux-tile-low.c.
13065 (linux-tile-low.o, reg-tilegx.o, reg-tilegx.c): New rules.
13066 * configure.srv: Handle tilegx-*-linux*.
13067 * linux-tile-low.c: New file.
13068
13069 2012-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
13070
13071 * linux-low.c (linux_qxfer_libraries_svr4): Return -1 if R_DEBUG is -1.
13072
13073 2012-05-24 Pedro Alves <palves@redhat.com>
13074
13075 PR gdb/7205
13076
13077 Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.
13078
13079 2012-05-24 Pedro Alves <palves@redhat.com>
13080
13081 PR gdb/7205
13082
13083 Replace target_signal with gdb_signal throughout.
13084
13085 2012-05-22 Maciej W. Rozycki <macro@codesourcery.com>
13086
13087 * linux-low.c (linux_store_registers): Avoid the copying sequence
13088 when no data has been retrieved by ptrace.
13089
13090 2012-05-22 Will Deacon <will.deacon@arm.com>
13091
13092 * linux-low (__UCLIBC__ && !(__UCLIBC_HAS_MMU__ || __ARCH_HAS_MMU__)):
13093 Include asm/ptrace.h.
13094 (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define only if not
13095 already defined.
13096
13097 2012-05-21 Maciej W. Rozycki <macro@codesourcery.com>
13098
13099 * linux-low.c (linux_store_registers): Don't re-retrieve data
13100 with ptrace that has already been obtained from /proc. Always
13101 copy any data retrieved with ptrace to the buffer supplied.
13102
13103 2012-05-11 Yao Qi <yao@codesourcery.com>
13104 Pedro Alves <palves@redhat.com>
13105
13106 * linux-low.c (enum stopping_threads_kind): New.
13107 (stopping_threads): Change type to `enum stopping_threads_kind'.
13108 (handle_extended_wait): If stopping and suspending threads, leave
13109 the new_lwp suspended too.
13110 (linux_wait_for_event): Adjust.
13111 (stop_all_lwps): Set `stopping_threads' to
13112 STOPPING_AND_SUSPENDING_THREADS or STOPPING_THREADS depending on
13113 whether we're suspending threads or just stopping them. Assert no
13114 recursion happens.
13115
13116 2012-04-29 Yao Qi <yao@codesourcery.com>
13117
13118 * server.h: Move some code to ...
13119 * gdbthread.h: ... here. New.
13120 * Makefile.in (inferiors.o, regcache.o): Depends on gdbthread.h
13121 (remote-utils.o, server.o, target.o tracepoint.o): Likewise.
13122 (nto-low.o, win32-low.o): Likewise.
13123 * inferiors.c, linux-low.h, nto-low.c: Include gdbthread.h.
13124 * regcache.c, remote-utils.c, server.c: Likewise.
13125 * target.c, tracepoint.c, win32-low.c: Likewise.
13126
13127 2012-04-24 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
13128
13129 * linux-low.h (PTRACE_ARG3_TYPE): Move macro from linux-low.c.
13130 (PTRACE_ARG4_TYPE): Likewise.
13131 (PTRACE_XFER_TYPE): Likewise.
13132 * linux-arm-low.c (arm_prepare_to_resume): Cast third argument of
13133 ptrace to PTRACE_ARG3_TYPE.
13134 * linux-low.c (PTRACE_ARG3_TYPE): Move macro to linux-low.h.
13135 (PTRACE_ARG4_TYPE): Likewise.
13136 (PTRACE_XFER_TYPE): Likewise.
13137 (linux_detach_one_lwp): Cast fourth argument of
13138 ptrace to long then PTRACE_ARG4_TYPE.
13139 (regsets_fetch_inferior_registers): Cast third argument of
13140 ptrace to long then PTRACE_ARG3_TYPE.
13141 (regsets_store_inferior_registers): Likewise.
13142
13143 2012-04-20 Pedro Alves <palves@redhat.com>
13144
13145 * configure: Regenerate.
13146
13147 2012-04-19 Pedro Alves <palves@redhat.com>
13148
13149 * Makefile.in (GNULIB_BUILDDIR): New.
13150 (LIBGNU, INCGNU, GNULIB_H): Adjust.
13151 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): New.
13152 (all, install-only, uninstall, clean-info, all-lib, clean): No
13153 longer pass GNULIB_FLAGS_TO_PASS. Use subdir_do.
13154 (maintainer-clean realclean distclean): Use subdir_do.
13155 (subdir_do): New.
13156 (gnulib/import/Makefile): Adjust. Replace gnulib/import with
13157 $(GNULIB_BUILDDIR). Don't pass argument to config.status.
13158 * acinclude.m4: Include acx_configure_dir.m4.
13159 * configure.ac: Remove gl_EARLY, gl_INIT, and AM_INIT_AUTOMAKE
13160 calls. Call AC_PROG_RANLIB. Configure gnulib using
13161 ACX_CONFIGURE_DIR.
13162 (GNULIB): New.
13163 (GNULIB_STDINT_H): Adjust.
13164 (AC_OUTPUT): Don't output gnulib/Makefile anymore.
13165 * gdbreplay.c: Include build-gnulib/config.h.
13166 * server.h: Likewise.
13167 * aclocal.m4: Regenerate.
13168 * config.in: Regenerate.
13169 * configure: Regenerate.
13170
13171 2012-04-19 Pedro Alves <palves@redhat.com>
13172
13173 * Makefile.in (LIBGNU, INCGNU): Adjust.
13174 (GNULIB_FLAGS_TO_PASS, GNULIB_H): Adjust.
13175 (all, install-only, uninstall, clean-info, all-lib, clean)
13176 (maintainer-clean, Makefile, gnulib/Makefile): Adjust.
13177 * configure.ac: Adjust AC_OUTPUT output.
13178 * aclocal.m4: Regenerate.
13179 * configure: Regenerate.
13180
13181 2012-04-19 Pedro Alves <palves@redhat.com>
13182
13183 * Makefile.in (generated_files): New.
13184 (server_h): Remove the explicit dependency on config.h, and depend
13185 on $generated_files.
13186
13187 2012-04-19 Pedro Alves <palves@redhat.com>
13188
13189 * Makefile.in (INCGNU): Add -Ignulib.
13190
13191 2012-04-19 Pedro Alves <palves@redhat.com>
13192
13193 * Makefile.in (GNULIB_INCLUDE_DIR): Rename to ...
13194 (INCGNU): ... this, and spell out -I here.
13195 (GNULIB_LIB): Rename to ...
13196 (LIBGNU): ... this.
13197 (INCLUDE_CFLAGS, gdbserver$(EXEEXT), $(GNULIB_LIB) rule): Adjust.
13198
13199 2012-04-19 Pedro Alves <palves@redhat.com>
13200
13201 * config.in: Regenerate.
13202
13203 2012-04-19 Pedro Alves <palves@redhat.com>
13204
13205 * configure.ac: Remove AC_CHECK_DECLS check for memmem.
13206 * server.h (memmem): Remove declaration.
13207 * config.in: Regenerate.
13208 * configure: Regenerate.
13209
13210 2012-04-19 Yao Qi <yao@codesourcery.com>
13211
13212 * Makefile.in (SFILES): Add common/vec.c.
13213 (OBS): Add vec.o.
13214 (vec.o): New rule.
13215
13216 2012-04-19 Yao Qi <yao@codesourcery.com>
13217
13218 * remote-utils.c (prepare_resume_reply): Replace with macro
13219 target_core_of_thread.
13220 * server.c (handle_qxfer_threads_proper): Likewise.
13221 * target.h (traget_core_of_thread): New macro.
13222
13223 2012-04-18 Pedro Alves <palves@redhat.com>
13224
13225 * aclocal.m4: Regenerate.
13226 * configure: Regenerate.
13227
13228 2012-04-16 Yao Qi <yao@codesourcery.com>
13229
13230 * tracepoint.c (cmd_qtstart): Download tracepoints even when they are
13231 duplicated on address.
13232
13233 2012-04-16 Yao Qi <yao@codesourcery.com>
13234
13235 * tracepoint.c (COPY_FIELD_TO_BUF): New macro.
13236 (struct tracepoint_action_ops) <send>: New field.
13237 (m_tracepoint_action_send, r_tracepoint_action_send): New.
13238 (agent_expr_send, x_tracepoint_action_send): New.
13239 (l_tracepoint_action_send): New.
13240 (cmd_qtdp): Download and install tracepoint
13241 according to `use_agent'.
13242 (run_inferior_command): Add one more parameter `len'.
13243 Update callers.
13244 (tracepoint_send_agent): New.
13245 (cmd_qtdp, cmd_qtstart): Call tracepoint_send_agent.
13246
13247 2012-04-16 Yao Qi <yao@codesourcery.com>
13248
13249 * tracepoint.c (download_tracepoints): Moved to ...
13250 (cmd_qtstart): ... here.
13251
13252 2012-04-14 Yao Qi <yao@codesourcery.com>
13253
13254 * tracepoint.c: Include inttypes.h.
13255 (struct collect_memory_action): Use sized types.
13256 (struct tracepoint): Likewise.
13257 (cmd_qtdp, stop_tracing): Update print specifiers.
13258 (cmd_qtp, response_tracepoint): Likewise.
13259 (collect_data_at_tracepoint): Likewise.
13260 (collect_data_at_step): Likewise.
13261
13262 2012-04-14 Yao Qi <yao@codesourcery.com>
13263
13264 Import gnulib module inttypes.
13265 * aclocal.m4, config.in, configure: Regenerated.
13266
13267 2012-04-14 Yao Qi <yao@codesourcery.com>
13268
13269 * Makefile.in (maintainer-clean, realclean, distclean): Remove
13270 Makefile and config.status at last.
13271
13272 2012-04-13 Yao Qi <yao@codesourcery.com>
13273
13274 * tracepoint.c: Include stdint.h unconditionally.
13275
13276 2012-04-13 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
13277
13278 * acinclude.m4 (GDBSERVER_HAVE_THREAD_DB_TYPE): New macro based
13279 on BFD_HAVE_SYS_PROCFS_TYPE.
13280 * configure.ac: Look for lwpid_t and psaddr_t in libthread_db.h.
13281 * configure: Regenerate.
13282 * config.in: Likewise.
13283
13284 2012-04-13 H.J. Lu <hongjiu.lu@intel.com>
13285
13286 * Makefile.in (clean): Also remove x32.c x32-linux.c
13287 x32-avx.c x32-avx-linux.c.
13288 (x32.o): New target.
13289 (x32.c): Likewise.
13290 (x32-linux.o): Likewise.
13291 (x32-linux.c): Likewise.
13292 (x32-avx.o): Likewise.
13293 (x32-avx.c): Likewise.
13294 (x32-avx-linux.o): Likewise.
13295 (x32-avx-linux.c): Likewise.
13296
13297 * configure.srv (srv_amd64_regobj): Add x32.o x32-avx.o.
13298 (srv_amd64_linux_regobj): Add x32-linux.o x32-avx-linux.o.
13299 (srv_i386_64bit_xmlfiles): Add i386/x32-core.xml.
13300 (srv_amd64_xmlfiles): Add i386/x32.xml i386/x32-avx.xml.
13301 (srv_amd64_linux_xmlfiles): Add i386/x32-linux.xml
13302 i386/x32-avx-linux.xml.
13303
13304 * linux-x86-low.c (init_registers_x32_linux): New prototype.
13305 (init_registers_x32_avx_linux): Likwise.
13306 (x86_linux_update_xmltarget): Call init_registers_x32_linux
13307 or init_registers_x32_avx_linux if linux_is_elf64 is false.
13308
13309 2012-04-13 Pedro Alves <palves@redhat.com>
13310
13311 * Makefile.in (GNULIB_FLAGS_TO_PASS): New.
13312 (FLAGS_TO_PASS): Don't change or set $top_srcdir, $srcdir and VPATH.
13313 (all, uninstall, clean-info, all-lib, clean, maintainer-clean)
13314 (realclean, distclean): Explicitly pass $GNULIB_FLAGS_TO_PASS to
13315 the sub-make.
13316
13317 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
13318
13319 * linux-x86-low.c (compat_x32_clock_t): New.
13320 (compat_x32_siginfo_t): Likewise.
13321 (compat_x32_siginfo_from_siginfo): Likewise.
13322 (siginfo_from_compat_x32_siginfo): Likewise.
13323 (linux_is_elf64): Likewise.
13324 (x86_siginfo_fixup): Call compat_x32_siginfo_from_siginfo
13325 and siginfo_from_compat_x32_siginfo for x32.
13326 (x86_arch_setup): Set linux_is_elf64.
13327
13328 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
13329
13330 PR gdb/13969
13331 * linux-low.c (linux_pid_exe_is_elf_64_file): Also return the
13332 e_machine field.
13333 (linux_qxfer_libraries_svr4): Update call to elf_64_file_p.
13334 * linux-low.h (linux_pid_exe_is_elf_64_file): Updated.
13335 * linux-x86-low.c (x86_arch_setup): Check if GDBserver is
13336 compatible with process.
13337
13338 2012-04-12 Yao Qi <yao@codesourcery.com>
13339
13340 * Makefile.in: Define abs_top_srcdir and abs_srcdir.
13341 (INCLUDE_CFLAGS): Append GNULIB_INCLUDE_DIR.
13342 (install-only, install-info, clean): Handle sub dir gnulib.
13343 (all-lib, am--refresh): New targets.
13344 (memmem.o): Remove target.
13345 * configure.ac: Remove AC_CONFIG_LIBOBJ_DIR.
13346 Invoke gl_EARLY. Invoke AC_CHECK_PROGS for make.
13347 (AC_REPLACE_FUNCS): Remove memmem.
13348 Invoke gl_INIT and AM_INIT_AUTOMAKE.
13349 (AC_OUTPUT): Generate Makefile in gnulib/.
13350 * aclocal.m4, config.in, configure: Regenerated.
13351
13352 2012-04-10 Maciej W. Rozycki <macro@codesourcery.com>
13353
13354 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP.
13355
13356 2012-04-05 Pedro Alves <palves@redhat.com>
13357
13358 -Werror=strict-aliasing
13359
13360 * spu-low.c (parse_spufs_run): Avoid dereferencing type-punned
13361 pointer.
13362
13363 2012-04-04 Pedro Alves <palves@redhat.com>
13364
13365 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
13366 (sparc_store_gregset_from_stack, sparc_store_gregset)
13367 (sparc_breakpoint_at): Fix formatting.
13368
13369 2012-03-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
13370
13371 * configure.ac: Check whether Elf32_auxv_t and Elf64_auxv_t
13372 are available.
13373 * linux-low.c [HAVE_ELF32_AUXV_T] (Elf32_auxv_t): Add typedef.
13374 [HAVE_ELF64_AUXV_T] (Elf64_auxv_t): Likewise.
13375 * config.in: Regenerate.
13376 * configure: Likewise.
13377
13378 2012-03-29 Pedro Alves <palves@redhat.com>
13379
13380 * linux-low.c (regsets_store_inferior_registers) [__sparc__]:
13381 Correct ptrace arguments.
13382
13383 2012-03-28 Pedro Alves <palves@redhat.com>
13384
13385 * linux-ia64-low.c (ia64_regmap): Map IA64_EC_REGNUM to PT_AR_EC.
13386 (IA64_GR0_REGNUM, IA64_FR0_REGNUM)
13387 (IA64_FR1_REGNUM): New defines.
13388 (ia64_fetch_register): New.
13389 (the_low_target): Install it.
13390 * linux-low.h (struct linux_target_ops) <fetch_register>: New
13391 field.
13392 * linux-low.c (linux_fetch_registers): Try the
13393 the_low_target.fetch_register hook first.
13394
13395 * linux-arm-low.c (the_low_target): Adjust.
13396 * linux-bfin-low.c (the_low_target): Adjust.
13397 * linux-cris-low.c (the_low_target): Adjust.
13398 * linux-crisv32-low.c (the_low_target): Adjust.
13399 * linux-m32r-low.c (the_low_target): Adjust.
13400 * linux-m68k-low.c (the_low_target): Adjust.
13401 * linux-mips-low.c (the_low_target): Adjust.
13402 * linux-ppc-low.c (the_low_target): Adjust.
13403 * linux-s390-low.c (the_low_target): Adjust.
13404 * linux-sh-low.c (the_low_target): Adjust.
13405 * linux-sparc-low.c (the_low_target): Adjust.
13406 * linux-tic6x-low.c (the_low_target): Adjust.
13407 * linux-x86-low.c (the_low_target): Adjust.
13408 * linux-xtensa-low.c (the_low_target): Adjust.
13409
13410 2012-03-26 Pedro Alves <palves@redhat.com>
13411
13412 * server.c (handle_qxfer_libraries): Don't bail early if
13413 the_target->qxfer_libraries_svr4 is not NULL.
13414
13415 2012-03-26 Pedro Alves <palves@redhat.com>
13416
13417 * linux-low.c (linux_qxfer_libraries_svr4): Fix pasto in comment.
13418
13419 2012-03-23 Pedro Alves <palves@redhat.com>
13420
13421 * linux-low.c (linux_qxfer_libraries_svr4): Terminate the
13422 "library-list-svr4" element's start tag when the the DSO list is
13423 empty.
13424
13425 2012-03-23 Pedro Alves <palves@redhat.com>
13426
13427 * linux-low.c (read_one_ptr): Read the inferior's pointer through
13428 a variable whose type size is the same as the inferior's pointer
13429 size.
13430
13431 2012-03-21 Thomas Schwinge <thomas@codesourcery.com>
13432
13433 * linux-arm-low.c (arm_stopped_by_watchpoint): Use siginfo_t instead of
13434 struct siginfo.
13435 * linux-low.c (siginfo_fixup, linux_xfer_siginfo): Likewise.
13436 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
13437 * linux-low.h: Include <signal.h>.
13438 (struct siginfo): Remove forward declaration.
13439 (struct linux_target_ops) <siginfo_fixup>: Use siginfo_t instead of
13440 struct siginfo.
13441
13442 2012-03-21 Mike Frysinger <vapier@gentoo.org>
13443
13444 * .gitignore: Ignore more files.
13445
13446 2012-03-19 Pedro Alves <palves@redhat.com>
13447 Jan Kratochvil <jan.kratochvil@redhat.com>
13448
13449 * server.c (cont_thread, general_thread): Add describing comments.
13450 (start_inferior): Clear `cont_thread'.
13451 (handle_v_cont): Don't set `cont_thread' if resuming all threads
13452 of a process.
13453
13454 2012-03-15 Yao Qi <yao@codesourcery.com>
13455
13456 * tracepoint.c (install_tracepoint): Move duplicated tracepoint
13457 handling to ...
13458 (cmd_qtdp): ... here.
13459
13460 2012-03-15 Yao Qi <yao@codesourcery.com>
13461
13462 * tracepoint.c (struct tracepoint_action_ops): New.
13463 (struct tracepoint_action) [!IN_PROCESS_AGENT] <ops>: New field.
13464 (m_tracepoint_action_download): New.
13465 (r_tracepoint_action_download): New.
13466 (x_tracepoint_action_download): New.
13467 (l_tracepoint_action_download): New.
13468 (add_tracepoint_action): Install `action->ops' according type.
13469 (download_tracepoint_1): Move code `download' function pointer
13470 of various tracepoint_action_ops.
13471
13472 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
13473
13474 * linux-low.c (linux_attach_lwp_1): New variable buffer. Call
13475 linux_ptrace_attach_warnings.
13476
13477 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
13478
13479 * Makefile.in (linux-ptrace.o): New.
13480 * configure.srv (arm*-*-linux*, bfin-*-*linux*, crisv32-*-linux*)
13481 (cris-*-linux*, i[34567]86-*-linux*, ia64-*-linux*, m32r*-*-linux*)
13482 (m68*-*-linux*, m68*-*-uclinux*, mips*-*-linux*, powerpc*-*-linux*)
13483 (s390*-*-linux*, sh*-*-linux*, sparc*-*-linux*, tic6x-*-uclinux)
13484 (x86_64-*-linux*, xtensa*-*-linux*): Add linux-ptrace.o to SRV_TGTOBJ
13485 of these targets.
13486 * linux-low.c (linux_attach_lwp_1): Remove redundent else clause.
13487
13488 2012-03-08 Yao Qi <yao@codesourcery.com>
13489 Pedro Alves <palves@redhat.com>
13490
13491 Fix PR server/13392.
13492 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Check
13493 offset of JMP insn.
13494 * tracepoint.c (remove_tracepoint): New.
13495 (cmd_qtdp): Call remove_tracepoint when failed to install.
13496
13497 2012-03-07 Pedro Alves <palves@redhat.com>
13498
13499 * linux-low.c (get_detach_signal): New.
13500 (linux_detach_one_lwp): Get rid of a pending SIGSTOP with SIGCONT.
13501 Pass on pending signals to PTRACE_DETACH. Check the result of the
13502 ptrace call.
13503 * server.c (program_signals, program_signals_p): New.
13504 (handle_general_set): Handle QProgramSignals.
13505 * server.h (program_signals, program_signals_p): Declare.
13506
13507 2012-03-05 Pedro Alves <palves@redhat.com>
13508 Jan Kratochvil <jan.kratochvil@redhat.com>
13509
13510 * linux-low.c (get_dynamic): Don't warn when PT_PHDR isn't found.
13511 New comment why.
13512
13513 2012-03-03 Yao Qi <yao@codesourcery.com>
13514
13515 * tracepoint.c (tracepoint_look_up_symbols): Update call to
13516 agent_look_up_symbols.
13517
13518 2012-03-03 Yao Qi <yao@codesourcery.com>
13519
13520 * Makefile.in (linux-low.o): Keep dependence on agent.h.
13521 (linux-x86-low.o): Likewise.
13522 * server.h: Remove in_process_agent_loaded.
13523 * tracepoint.c (in_process_agent_loaded): Removed. Moved it
13524 common/agent.c.
13525 Update callers.
13526
13527 2012-03-03 Yao Qi <yao@codesourcery.com>
13528
13529 * tracepoint.c (gdb_agent_capability): New global.
13530 (in_process_agent_loaded_ust): Renamed to
13531 `in_process_agent_supports_ust'.
13532 Update callers.
13533 (in_process_agent_supports_ust): Call agent_capability_check.
13534 (clear_installed_tracepoints): Assert that agent supports
13535 agent.
13536
13537 2012-03-03 Yao Qi <yao@codesourcery.com>
13538
13539 * linux-low.c (linux_supports_agent): New.
13540 (linux_target_ops): Initialize field `supports_agent' with
13541 linux_supports_agent.
13542 * target.h (struct target_ops) <supports_agent>: New.
13543 (target_supports_agent): New macro.
13544 * server.c (handle_general_set): Handle packet 'QAgent'.
13545 (handle_query): Send `QAgent+'.
13546 * Makefile.in (server.o): Depends on agent.h.
13547
13548 2012-03-03 Yao Qi <yao@codesourcery.com>
13549
13550 * Makefile.in (OBS): Add agent.o.
13551 Add new rule for agent.o.
13552 Track dependence of tracepoint.c on agent.h.
13553 * tracepoint.c (run_inferior_command_1):
13554 (run_inferior_command): Call agent_run_command.
13555 (gdb_ust_connect_sync_socket): Deleted. Move it to
13556 common/agent.c.
13557 (resume_thread, stop_thread): Likewise.
13558 (gdb_ust_socket_init): Renamed to ...
13559 (gdb_agent_socket_init): ... New.
13560 (gdb_ust_thread): Renamed to ...
13561 (gdb_agent_helper_thread): ... New.
13562 (gdb_ust_init): Move some code to ...
13563 (gdb_agent_init): ... here. New.
13564 [HAVE_UST]: Call gdb_ust_init.
13565 (initialize_tracepoint_ftlib): Call gdb_agent_init.
13566 * configure.ac: Add `sys/un.h' to AC_CHECK_HEADERS.
13567 * config.in, configure: Regenerated.
13568
13569 2012-03-02 Pedro Alves <palves@redhat.com>
13570
13571 * inferiors.c (add_pid_to_list, pull_pid_from_list): Delete.
13572 * linux-low.c (struct simple_pid_list): New.
13573 (stopped_pids): New a struct simple_pid_list pointer.
13574 (add_to_pid_list, pull_pid_from_list): New.
13575 (handle_extended_wait): Don't assume the first signal new children
13576 report is SIGSTOP. Adjust call to pull_pid_from_list.
13577 (linux_wait_for_lwp): Adjust.
13578
13579 2012-03-02 Yao Qi <yao@codesourcery.com>
13580
13581 * tracepoint.c (do_action_at_tracepoint): Write `stop_pc' in
13582 debug log.
13583
13584 2012-03-02 Yao Qi <yao@codesourcery.com>
13585
13586 * tracepoint.c (collect_ust_data_at_tracepoint): Remove parameters
13587 `stop_pc' and `tpoint'. Update caller.
13588
13589 2012-03-01 Maciej W. Rozycki <macro@codesourcery.com>
13590
13591 * linux-low.h (linux_target_ops): Add regset_bitmap member.
13592 * linux-low.c (use_linux_regsets): New macro.
13593 [!HAVE_LINUX_REGSETS] (regsets_fetch_inferior_registers): Likewise.
13594 [!HAVE_LINUX_REGSETS] (regsets_store_inferior_registers): Likewise.
13595 (linux_register_in_regsets): New function.
13596 (usr_fetch_inferior_registers): Skip registers covered by
13597 regsets.
13598 (usr_store_inferior_registers): Likewise.
13599 (usr_fetch_inferior_registers): New macro.
13600 (usr_store_inferior_registers): Likewise.
13601 (linux_fetch_registers): Handle mixed regset/non-regset targets.
13602 (linux_store_registers): Likewise.
13603 * linux-mips-low.c (init_registers_mips_dsp_linux): New
13604 prototype.
13605 (init_registers_mips64_dsp_linux): Likewise.
13606 (init_registers_mips_linux): New macro.
13607 (init_registers_mips_dsp_linux): Likewise.
13608 (mips_dsp_num_regs): Likewise.
13609 (DSP_BASE, DSP_CONTROL): New fallback macros.
13610 (mips_base_regs): New macro.
13611 (mips_regmap): Use it. Fix the size.
13612 (mips_dsp_regmap): New variable.
13613 (mips_dsp_regset_bitmap): Likewise.
13614 (mips_arch_setup): New function.
13615 (mips_cannot_fetch_register): Use the_low_target.regmap rather
13616 than mips_regmap.
13617 (mips_cannot_store_register): Likewise.
13618 (the_low_target): Update .arch_setup, .num_regs and .regmap
13619 initializers. Add .regset_bitmap initializer.
13620 * linux-arm-low.c (the_low_target): Add .regset_bitmap
13621 initializer.
13622 * linux-bfin-low.c (the_low_target): Likewise.
13623 * linux-cris-low.c (the_low_target): Likewise.
13624 * linux-crisv32-low.c (the_low_target): Likewise.
13625 * linux-ia64-low.c (the_low_target): Likewise.
13626 * linux-m32r-low.c (the_low_target): Likewise.
13627 * linux-m68k-low.c (the_low_target): Likewise.
13628 * linux-ppc-low.c (the_low_target): Likewise.
13629 * linux-s390-low.c (the_low_target): Likewise.
13630 * linux-sh-low.c (the_low_target): Likewise.
13631 * linux-sparc-low.c (the_low_target): Likewise.
13632 * linux-tic6x-low.c (the_low_target): Likewise.
13633 * linux-x86-low.c (the_low_target): Likewise.
13634 * linux-xtensa-low.c (the_low_target): Likewise.
13635 * configure.srv <mips*-*-linux*>: Add mips-dsp-linux.o and
13636 mips64-dsp-linux.o to srv_regobj. Add mips-dsp-linux.xml,
13637 mips64-dsp-linux.xml, mips-dsp.xml and mips64-dsp.xml to
13638 srv_xmlfiles.
13639 * Makefile.in (mips-dsp-linux.o, mips-dsp-linux.c): New targets.
13640 (mips64-dsp-linux.o, mips64-dsp-linux.c): Likewise.
13641
13642 2012-02-29 Yao Qi <yao@codesourcery.com>
13643 Pedro Alves <palves@redhat.com>
13644
13645 * linux-low.c: (linux_wait_1): Call unsuspend_all_lwps when
13646 `step_over_finished' is true.
13647
13648 2012-02-27 Pedro Alves <palves@redhat.com>
13649
13650 * linux-low.c (pid_is_stopped): Delete, moved to common/.
13651 (linux_attach_lwp_1): Adjust to use linux_proc_pid_is_stopped.
13652
13653 2012-02-27 Pedro Alves <palves@redhat.com>
13654
13655 PR server/9684
13656 * linux-low.c (pid_is_stopped): New.
13657 (linux_attach_lwp_1): Handle attaching to 'T (stopped)' processes.
13658
13659 2012-02-25 Luis Machado <lgustavo@codesourcery.com>
13660
13661 * mem-break.c (clear_gdb_breakpoint_conditions): Fix de-allocation
13662 of conditions.
13663
13664 2012-02-24 Maciej W. Rozycki <macro@codesourcery.com>
13665
13666 * linux-mips-low.c (mips_regmap): Correct the index of $f9.
13667
13668 2012-02-24 Luis Machado <lgustavo@codesourcery>
13669
13670 * server.c (handle_query): Advertise support for target-side
13671 breakpoint condition evaluation.
13672 (process_point_options): New function.
13673 (process_serial_event): When inserting a breakpoint, check for
13674 a target-side condition that should be evaluated.
13675
13676 * mem-break.c: Include regcache.h and ax.h.
13677 (point_cond_list_t): New data structure.
13678 (breakpoint) <cond_list>: New field.
13679 (find_gdb_breakpoint_at): Make non-static.
13680 (delete_gdb_breakpoint_at): Clear any target-side
13681 conditions.
13682 (clear_gdb_breakpoint_conditions): New function.
13683 (add_condition_to_breakpoint): Likewise.
13684 (add_breakpoint_condition): Likewise.
13685 (gdb_condition_true_at_breakpoint): Likewise.
13686 (gdb_breakpoint_here): Return result directly instead
13687 of going through a local variable.
13688
13689 * mem-break.h (find_gdb_breakpoint_at): New prototype.
13690 (clear_gdb_breakpoint_conditions): Likewise.
13691 (add_breakpoint_condition): Likewise.
13692 (gdb_condition_true_at_breakpoint): Likewise.
13693
13694 * linux-low.c (linux_wait_1): Evaluate target-side breakpoint condition.
13695 (need_step_over_p): Take target-side breakpoint condition into
13696 consideration.
13697
13698 2012-02-24 Luis Machado <lgustavo@codesourcery>
13699
13700 * server.h: Include tracepoint.h.
13701 (agent_mem_read, agent_get_trace_state_variable_value,
13702 agent_set_trace_state_variable_value,
13703 agent_tsv_read, agent_mem_read_string, get_get_tsv_func_addr,
13704 get_set_tsv_func_addr): New prototypes.
13705
13706 * ax.h: New include file.
13707 * ax.c: New source file.
13708
13709 * tracepoint.c: Include ax.h.
13710 (gdb_agent_op, gdb_agent_op_names, gdb_agent_op_sizes,
13711 agent_expr, eval_result_type): Move to ax.h.
13712 (parse_agent_expr): Rename to ...
13713 (gdb_parse_agent_expr): ... this, make it non-static and move
13714 to ax.h.
13715 (unparse_agent_expr) Rename to ...
13716 (gdb_unparse_agent_expr): ... this, make it non-static and move
13717 to ax.h.
13718 (eval_agent_expr): Rename to ...
13719 (eval_tracepoint_agent_expr): ... this.
13720 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Remove
13721 forward declarations.
13722 (add_tracepoint_action): Call gdb_parse_agent_expr (...).
13723 (agent_get_trace_state_variable_value): New function.
13724 (agent_set_trace_state_variable_value): New function.
13725 (cmd_qtdp): Call gdb_parse_agent_expr (...).
13726 (response_tracepoint): Call gdb_unparse_agent_expr (...).
13727 (do_action_at_tracepoint): Call eval_tracepoint_agent_expr (...).
13728 (condition_true_at_tracepoint): Likewise.
13729 (parse_agent_expr): Rename to ...
13730 (gdb_parse_agent_expr): ... this and move to ax.c.
13731 (unparse_agent_expr): Rename to ...
13732 (gdb_unparse_agent_expr): ... this and move to ax.c.
13733 (gdb_agent_op_name): Move to ax.c.
13734 (eval_agent_expr): Rename to ...
13735 (gdb_eval_agent_expr): ... this, use regcache passed as parameter
13736 and move to ax.c.
13737 (eval_tracepoint_agent_expr): New function.
13738 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Make
13739 non-static.
13740 (current_insn_ptr, emit_error, struct bytecode_address): Move to
13741 ax.c.
13742 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul, emit_lsh,
13743 emit_rsh_signed, emit_rsh_unsigned, emit_ext, emit_log_not,
13744 emit_bit_and, emit_bit_or, emit_bit_xor, emit_bit_not, emit_equal,
13745 emit_less_signed, emit_less_unsigned, emit_ref, emit_if_goto,
13746 emit_goto, write_goto_address, emit_const, emit_reg, emit_pop,
13747 emit_stack, emit_zero_ext, emit_swap, emit_stack_adjust,
13748 emit_int_call_1, emit_void_call_2, emit_eq_goto, emit_ne_goto,
13749 emit_lt_goto, emit_ge_goto, emit_gt_goto, emit_le_goto): Move to ax.c.
13750 (get_get_tsv_func_addr, get_set_tsv_func_addr): New functions.
13751 (compile_bytecodes): Remove forward declaration.
13752 (is_goto_target): Move to ax.c.
13753 (compile_bytecodes): Move to ax.c and call
13754 agent_get_trace_state_variable_value (...) and
13755 agent_set_trace_state_variable_value (...).
13756
13757 * Makefile.in: Update ax.c and IPA dependencies.
13758
13759 2012-02-24 Pedro Alves <palves@redhat.com>
13760
13761 * tracepoint.c (cmd_bigqtbuffer): Rename as ...
13762 (cmd_bigqtbuffer_circular): ... this. Only handle
13763 'QTBuffer:circular:'.
13764 (handle_tracepoint_general_set): Adjust.
13765
13766 2012-02-16 Yao Qi <yao@codesourcery.com>
13767
13768 * inferiors.c: Move code to ...
13769 * dll.c: .... here. New.
13770 * server.h: Declare clear_dlls.
13771 * Makefile.in (SFILES): Add dll.c.
13772 (OBS): Add dll.o
13773 (dll.o): New rule.
13774
13775 2012-02-11 Yao Qi <yao@codesourcery.com>
13776
13777 * server.c: (handle_monitor_command): Add a new parameter
13778 `own_buf'.
13779 (handle_query): Update caller.
13780
13781 2012-02-09 Joel Brobecker <brobecker@adacore.com>
13782
13783 * configure.ac: Add readlink to AC_CHECK_FUNCS list.
13784 * configure, config.in: Regenerate.
13785 * hostio.c: Provide an alternate implementation if HAVE_READLINK
13786 is not defined.
13787
13788 2012-02-02 Pedro Alves <palves@redhat.com>
13789
13790 Try SIGKILL first, then PTRACE_KILL.
13791 * linux-low.c (linux_kill_one_lwp): New.
13792 (linux_kill_one_lwp): Rename to ...
13793 (kill_one_lwp_callback): ... this. Use the new
13794 linux_kill_one_lwp.
13795
13796 2012-02-02 Pedro Alves <palves@redhat.com>
13797
13798 * tracepoint.c (cmd_qtminftpilen): Return 0 if there's no current
13799 inferior.
13800
13801 2012-01-27 Pedro Alves <palves@redhat.com>
13802
13803 * linux-low.c (linux_child_pid_to_exec_file): Delete.
13804 (elf_64_file_p): Make static.
13805 (linux_pid_exe_is_elf_64_file): New.
13806 * linux-low.h (linux_child_pid_to_exec_file, elf_64_file_p):
13807 Delete declarations.
13808 (linux_pid_exe_is_elf_64_file): Declare.
13809 * linux-x86-low.c (x86_arch_setup): Use
13810 linux_pid_exe_is_elf_64_file.
13811
13812 2012-01-25 Jan Kratochvil <jan.kratochvil@redhat.com>
13813
13814 * linux-low.c (linux_wait_for_event_1): Rename to ...
13815 (linux_wait_for_event): ... here and merge it with former
13816 linux_wait_for_event - new variable wait_ptid, use it.
13817 (linux_wait_for_event): Remove - merge it to linux_wait_for_event_1.
13818
13819 2012-01-23 Pedro Alves <palves@redhat.com>
13820
13821 * server.c (main): Avoid yet another case of infinite loop while
13822 detaching/killing after a longjmp.
13823
13824 2012-01-20 Jan Kratochvil <jan.kratochvil@redhat.com>
13825
13826 Code cleanup.
13827 * linux-low.c (linux_wait_for_event_1): Use ptid_is_pid.
13828
13829 2012-01-20 Ulrich Weigand <ulrich.weigand@linaro.org>
13830
13831 * hostio.c (handle_readlink): New function.
13832 (handle_vFile): Call it to handle "vFile:readlink" packets.
13833
13834 2012-01-20 Pedro Alves <palves@redhat.com>
13835 Ulrich Weigand <ulrich.weigand@linaro.org>
13836
13837 * server.c (handle_v_requests): Only support vAttach and vRun to
13838 start multiple processes when in extended protocol mode.
13839
13840 2012-01-17 Pedro Alves <palves@redhat.com>
13841
13842 * tracepoint.c (initialize_tracepoint): Use mmap instead of
13843 memalign plus mprotect to allocate the scratch buffer.
13844
13845 2012-01-13 Pedro Alves <palves@redhat.com>
13846
13847 * server.c (attach_inferior): Clear `cont_thread'.
13848
13849 2012-01-13 Pedro Alves <palves@redhat.com>
13850
13851 * server.c (main): Avoid infinite loop while detaching/killing
13852 after a longjmp.
13853
13854 2012-01-09 Doug Evans <dje@google.com>
13855
13856 * server.c (start_inferior): Set last_ptid in --wrapper case.
13857
13858 2012-01-06 Yao Qi <yao@codesourcery.com>
13859
13860 * tracepoint.c [IN_PROCESS_AGENT] (debug_threads): Macro
13861 defined.
13862 [IN_PROCESS_AGENT] (debug_agent): New global variable.
13863
13864 2012-01-04 Yao Qi <yao@codesourcery.com>
13865
13866 * tracepoint.c (cmd_qtdp): Print debug message
13867 for static tracepoint.
13868
13869 2012-01-04 Yao Qi <yao@codesourcery.com>
13870
13871 * tracepoint.c (trace_vdebug): Differentiate debug message
13872 between gdbserver and IPA.
13873
13874 2012-01-03 Yao Qi <yao@codesourcery.com>
13875
13876 * tracepoint.c (tracepoint_was_hit): Don't collect for
13877 static tracepoint.
13878
13879 2012-01-02 Joel Brobecker <brobecker@adacore.com>
13880
13881 * terminal.h: Reformat copyright header.
13882
13883 2012-01-02 Joel Brobecker <brobecker@adacore.com>
13884
13885 * server.c (gdbserver_version): Update copyright year.
13886 * gdbreplay.c (gdbreplay_version): Likewise.
13887
13888 2011-12-18 Jan Kratochvil <jan.kratochvil@redhat.com>
13889
13890 * linux-low.c (linux_create_inferior): Put empty if clause for write.
13891
13892 Revert:
13893 2011-12-18 Hui Zhu <teawater@gmail.com>
13894 * linux-low.c (linux_create_inferior): Save return value to ret.
13895
13896 2011-12-18 Hui Zhu <teawater@gmail.com>
13897
13898 * linux-low.c (linux_create_inferior): Save return value to ret.
13899
13900 2011-12-16 Doug Evans <dje@google.com>
13901
13902 * linux-low.c (linux_create_inferior): If stdio connection,
13903 redirect stdin from /dev/null, stdout to stderr.
13904 * remote-utils.c (remote_is_stdio): New static global.
13905 (remote_connection_is_stdio): New function.
13906 (remote_prepare): Handle stdio connection.
13907 (remote_open): Ditto.
13908 (remote_close): Don't close stdin for stdio connections.
13909 (read_prim,write_prim): New functions. Replace all calls to
13910 read/write to these.
13911 * server.c (main): Watch for "-" argument. Move call to
13912 remote_prepare before start_inferior.
13913 * server.h (STDIO_CONNECTION_NAME): New macro.
13914 (remote_connection_is_stdio): Declare.
13915
13916 * remote-utils.c (prepare_resume_reply): Remove extraneous \n
13917 in debugging output.
13918
13919 2011-12-15 Yao Qi <yao@codesourcery.com>
13920
13921 * tracepoint.c: Include sys/syscall.h.
13922 (gdb_ust_thread): Remove preprocessor conditional.
13923
13924 2011-12-14 Pedro Alves <pedro@codesourcery.com>
13925
13926 * linux-low.c (linux_detach_one_lwp): Call
13927 the_low_target.prepare_to_resume before detaching.
13928
13929 2011-12-14 Yao Qi <yao@codesourcery.com>
13930
13931 * tracepoint.c (gdb_ust_thread): Don't ignore return value
13932 of write.
13933
13934 2011-12-14 Yao Qi <yao@codesourcery.com>
13935
13936 * i386-low.c (i386_low_stopped_data_address): Initialize local
13937 variable `control'.
13938
13939 2011-12-13 Pedro Alves <pedro@codesourcery.com>
13940
13941 PR remote/13492
13942
13943 * i386-low.c (i386_low_stopped_data_address): Avoid fetching
13944 DR_CONTROL unless necessary. Extend comments.
13945 * linux-x86-low.c (x86_linux_prepare_to_resume): Don't write to
13946 DR0-3 if not used. If any watchpoint was set, clear DR_STATUS.
13947
13948 2011-12-13 Yao Qi <yao@codesourcery.com>
13949
13950 * tracepoint.c (trace_buffer_alloc): Replace magic numbers with
13951 macros.
13952 (upload_fast_traceframes, upload_fast_traceframes): Likewise.
13953
13954 2011-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
13955
13956 * linux-low.c (linux_kill): Skip PTRACE_KILL if LWP does not exist.
13957 Print new debug message for such case.
13958
13959 2011-12-06 Jan Kratochvil <jan.kratochvil@redhat.com>
13960
13961 Fix overlapping memcpy.
13962 * mem-break.c (set_raw_breakpoint_at): New variable buf. Use it for
13963 the read_inferior_memory transfer.
13964 (delete_fast_tracepoint_jump): New variable buf. Use it for the
13965 write_inferior_memory transfer.
13966 (set_fast_tracepoint_jump): New variable buf. Use it for the
13967 read_inferior_memory and write_inferior_memory transfers.
13968 (uninsert_fast_tracepoint_jumps_at, reinsert_fast_tracepoint_jumps_at)
13969 (delete_raw_breakpoint, uninsert_raw_breakpoint): New variable buf.
13970 Use it for the write_inferior_memory transfer.
13971 (check_mem_read, check_mem_write): New gdb_asserts for overlapping
13972 buffers.
13973
13974 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
13975
13976 * linux-low.c (fetch_register, store_register): Make code
13977 consistent, fix formatting.
13978
13979 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
13980
13981 * linux-low.c (usr_store_inferior_registers): Factor out code
13982 to handle individual registers into...
13983 (store_register): ... this new function.
13984
13985 2011-12-06 Ulrich Weigand <uweigand@de.ibm.com>
13986
13987 * Makefile.in (s390-linux32v1.o, s390-linux32v1.c): New rules.
13988 (s390-linux32v2.o, s390-linux32v2.c): Likewise.
13989 (s390-linux64v1.o, s390-linux64v1.c): Likewise.
13990 (s390-linux64v2.o, s390-linux64v2.c): Likewise.
13991 (s390x-linux64v1.o, s390x-linux64v1.c): Likewise.
13992 (s390x-linux64v2.o, s390x-linux64v2.c): Likewise.
13993 * configure.srv [s390*-*-linux*] (srv_regobj): Add new objects.
13994 (srv_xmlfiles): Add new XML files.
13995
13996 * linux-s390-low.c: Include "elf/common.h", <sys/ptrace.h>,
13997 and <sys/uio.h>.
13998 (PTRACE_GETREGSET, PTRACE_SETREGSET): Define if undefined.
13999 (init_registers_s390_linux32v1): Add prototype.
14000 (init_registers_s390_linux32v2): Likewise.
14001 (init_registers_s390_linux64v1): Likewise.
14002 (init_registers_s390_linux64v2): Likewise.
14003 (init_registers_s390x_linux64v1): Likewise.
14004 (init_registers_s390x_linux64v2): Likewise.
14005 (s390_num_regs): Increment to 52.
14006 (s390_regmap): Add orig_r2 register.
14007 (s390_num_regs_3264): Increment to 68.
14008 (s390_regmap_3264): Add orig_r2 register.
14009 (s390_collect_ptrace_register): Handle orig_r2 register.
14010 (s390_supply_ptrace_register): Likewise.
14011 (s390_fill_last_break): New function.
14012 (s390_store_last_break): Likewise.
14013 (s390_fill_system_call): New function.
14014 (s390_store_system_call): Likewise.
14015 (target_regsets): Handle NT_S390_LAST_BREAK and NT_S390_SYSTEM_CALL
14016 register sets.
14017 (s390_check_regset): New function.
14018 (s390_arch_setup): Check for presence of NT_S390_LAST_BREAK and
14019 NT_S390_SYSTEM_CALL regsets and use appropriate description.
14020 Update target_regsets for available register sets.
14021
14022 2011-12-02 Paul Pluzhnikov <ppluzhnikov@google.com>
14023 Jan Kratochvil <jan.kratochvil@redhat.com>
14024
14025 * linux-low.c (get_phdr_phnum_from_proc_auxv, get_dynamic, get_r_debug)
14026 (read_one_ptr, struct link_map_offsets, linux_qxfer_libraries_svr4):
14027 New.
14028 (struct linux_target_ops): Install linux_qxfer_libraries_svr4.
14029 * linux-low.h (struct process_info_private): New member r_debug.
14030 * server.c (handle_qxfer_libraries): Call
14031 the_target->qxfer_libraries_svr4.
14032 (handle_qxfer_libraries_svr4): New function.
14033 (qxfer_packets): New entry "libraries-svr4".
14034 (handle_query): Check QXFER_LIBRARIES_SVR4 and report libraries-svr4.
14035 * target.h (struct target_ops): New member qxfer_libraries_svr4.
14036 * remote.c (remote_xfer_partial): Call add_packet_config_cmd for
14037 PACKET_qXfer_libraries_svr4.
14038
14039 2011-11-30 Ulrich Weigand <uweigand@de.ibm.com>
14040
14041 * linux-s390-low.c (s390_collect_ptrace_register): Fully convert
14042 PSW address/mask between 8-byte and 16-byte formats.
14043 (s390_supply_ptrace_register): Likewise.
14044 (s390_get_pc, s390_set_pc): 4-byte PSW address always includes
14045 basic addressing mode bit.
14046
14047 2011-11-24 Stan Shebs <stan@codesourcery.com>
14048
14049 * tracepoint.c (cmd_qtstatus): Use plongest instead of %llx.
14050
14051 2011-11-17 Stan Shebs <stan@codesourcery.com>
14052
14053 * tracepoint.c (struct tracepoint): New field traceframe_usage.
14054 (tracing_start_time): New global.
14055 (tracing_stop_time): New global.
14056 (tracing_user_name): New global.
14057 (tracing_notes): New global.
14058 (tracing_stop_note): New global.
14059 (cmd_qtstart): Set traceframe_usage, start_time.
14060 (stop_tracing): Set stop_time.
14061 (cmd_qtstatus): Report additional status.
14062 (cmd_qtp): New function.
14063 (handle_tracepoint_query): Call it.
14064 (cmd_qtnotes): New function.
14065 (handle_tracepoint_general_set): Call it.
14066 (get_timestamp): Rename from tsv_get_timestamp.
14067
14068 2011-11-14 Stan Shebs <stan@codesourcery.com>
14069 Kwok Cheung Yeung <kcy@codesourcery.com>
14070
14071 * linux-x86-low.c (small_jump_insn): New.
14072 (i386_install_fast_tracepoint_jump_pad): Add arguments for
14073 trampoline and error message, build a trampoline and issue a small
14074 jump instruction to it.
14075 (x86_install_fast_tracepoint_jump_pad): Add arguments for
14076 trampoline and error message.
14077 (x86_get_min_fast_tracepoint_insn_len): New.
14078 (the_low_target): Add call to x86_get_min_fast_tracepoint_insn_len.
14079 * linux-low.h (struct linux_target_ops): Add arguments to
14080 install_fast_tracepoint_jump_pad operation, add new operation.
14081 * linux-low.c (linux_install_fast_tracepoint_jump_pad): Add
14082 arguments.
14083 (linux_get_min_fast_tracepoint_insn_len): New function.
14084 (linux_target_op): Add new operation.
14085 * tracepoint.c (gdb_trampoline_buffer): New IPA variable.
14086 (gdb_trampoline_buffer_end): Ditto.
14087 (gdb_trampoline_buffer_error): Ditto.
14088 (struct ipa_sym_addresses): Add fields for new IPA variables.
14089 (symbol_list): Add entries for new IPA variables.
14090 (struct tracepoint): Add fields to hold the address range of the
14091 trampoline used by the tracepoint.
14092 (trampoline_buffer_head): New static variable.
14093 (trampoline_buffer_tail): Ditto.
14094 (claim_trampoline_space): New function.
14095 (have_fast_tracepoint_trampoline_buffer): New function.
14096 (clone_fast_tracepoint): Fill in trampoline fields of tracepoint
14097 structure.
14098 (install_fast_tracepoint): Ditto, also add error buffer argument.
14099 (cmd_qtminftpilen): New function.
14100 (handle_tracepoint_query): Add response to qTMinFTPILen packet.
14101 (fast_tracepoint_from_trampoline_address): New function.
14102 (fast_tracepoint_collecting): Handle trampoline as part of jump
14103 pad space.
14104 (set_trampoline_buffer_space): New function.
14105 (initialize_tracepoint): Initialize new IPA variables.
14106 * target.h (struct target_ops): Add arguments to
14107 install_fast_tracepoint_jump_pad operation, add new
14108 get_min_fast_tracepoint_insn_len operation.
14109 (target_get_min_fast_tracepoint_insn_len): New.
14110 (install_fast_tracepoint_jump_pad): Add arguments.
14111 * server.h (IPA_BUFSIZ): Define.
14112 * linux-i386-ipa.c: Include extra header files.
14113 (initialize_fast_tracepoint_trampoline_buffer): New function.
14114 (initialize_low_tracepoint): Call it.
14115 * server.h (set_trampoline_buffer_space): Declare.
14116 (claim_trampoline_space): Ditto.
14117 (have_fast_tracepoint_trampoline_buffer): Ditto.
14118
14119 2011-11-14 Yao Qi <yao@codesourcery.com>
14120
14121 * server.c (handle_query): Handle InstallInTrace for qSupported.
14122 * tracepoint.c (add_tracepoint): Sort list.
14123 (install_tracepoint, download_tracepoint): New.
14124 (cmd_qtdp): Call them to install and download tracepoints.
14125 (sort_tracepoints): Removed.
14126 (cmd_qtstart): Update.
14127
14128 2011-11-14 Yao Qi <yao@codesourcery.com>
14129
14130 * mem-break.c (inc_ref_fast_tracepoint_jump): New.
14131 * mem-break.h: Declare.
14132 * tracepoint.c (cmd_qtstart): Move some code to ...
14133 (clone_fast_tracepoint, install_fast_tracepoint): ... here.
14134 New.
14135 (download_tracepoints): Move some code to ...
14136 (download_tracepoint_1): ... here. New.
14137
14138 2011-11-08 Yao Qi <yao@codesourcery.com>
14139
14140 * remote-utils.c (relocate_instruction): A comment fix.
14141
14142 2011-11-07 Joel Brobecker <brobecker@adacore.com>
14143
14144 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): Delete.
14145 (i386_dr_low_get_control, i386_dr_low_get_status): Use
14146 dr_status_mirror and dr_control_mirror from debug_reg_state.
14147 (i386_dr_low_get_status): Use debug_reg_state.dr_status_mirror
14148 (i386_initial_stuff): Remove use of deleted globals.
14149 (i386_get_thread_context, i386_set_thread_context,
14150 i386_thread_added): Use dr_status_mirror and dr_control_mirror
14151 from debug_reg_state.
14152
14153 2011-11-05 Yao Qi <yao@codesourcery.com>
14154
14155 * tracepoint.c (gdb_collect): Loop over tracepoints of same
14156 address as TPOINT's.
14157
14158 2011-11-02 Stan Shebs <stan@codesourcery.com>
14159
14160 * tracepoint.c (agent_mem_read_string): New function.
14161 (eval_agent_expr): Call it for tracenz.
14162 * server.c (handle_query): Report support for tracenz.
14163
14164 2011-11-02 Yao Qi <yao@codesourcery.com>
14165
14166 * tracepoint.c (cmd_qtstart): Remove unused local variables.
14167
14168 2011-11-02 Yao Qi <yao@codesourcery.com>
14169
14170 * target.h: Fix a typo in comment.
14171
14172 2011-10-31 Pedro Alves <pedro@codesourcery.com>
14173
14174 * mem-break.c (check_mem_write): Add `myaddr' parameter. Don't
14175 clobber the breakpoints' shadows with fast tracepoint jumps.
14176 * mem-break.h (check_mem_write): Add `myaddr' parameter.
14177 * target.c (write_inferior_memory): Also pass MYADDR down to
14178 check_mem_write.
14179
14180 2011-10-07 Ulrich Weigand <ulrich.weigand@linaro.org>
14181
14182 * configure.ac: Check support for personality routine.
14183 * configure: Regenerate.
14184 * config.in: Likewise.
14185 * linux-low.c: Include <sys/personality.h>.
14186 Define ADDR_NO_RANDOMIZE if necessary.
14187 (linux_create_inferior): Disable address space randomization when
14188 forking inferior, if requested.
14189 (linux_supports_disable_randomization): New function.
14190 (linux_target_ops): Install it.
14191 * server.h (disable_randomization): Declare.
14192 * server.c (disable_randomization): New global variable.
14193 (handle_general_set): Handle QDisableRandomization.
14194 (handle_query): Likewise for qSupported.
14195 (main): Support --disable-randomization and --no-disable-randomization
14196 command line arguments.
14197 * target.h (struct target_ops): Add supports_disable_randomization.
14198 (target_supports_disable_randomization): New macro.
14199
14200 2011-09-29 Mike Frysinger <vapier@gentoo.org>
14201
14202 * linux-low.c (target_loadseg): Add defined PTRACE_GETFDPIC to the
14203 ifdef check.
14204 [PT_GETDSBT] (target_loadmap): Wrap in a defined PT_GETDSBT check.
14205 [!PT_GETDSBT] (target_loadmap): New definition.
14206 (LINUX_LOADMAP, LINUX_LOADMAP_EXEC, LINUX_LOADMAP_INTERP): Define.
14207 (linux_read_loadmap): Change PTRACE_GETDSBT_EXEC to
14208 LINUX_LOADMAP_EXEC, PTRACE_GETDSBT_INTERP to LINUX_LOADMAP_INTERP,
14209 and PT_GETDSBT to LINUX_LOADMAP.
14210 [!PT_GETDSBT] (linux_read_loadmap): Define to NULL.
14211 (linux_target_ops): Delete unnecessary ifdef PT_GETDSBT check.
14212
14213 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
14214
14215 * linux-arm-low.c (struct arm_linux_hwbp_cap): Remove.
14216 (arm_linux_hwbp_cap): New static variable.
14217 (arm_linux_get_hwbp_cap): Replace by ...
14218 (arm_linux_init_hwbp_cap): ... this new function.
14219 (arm_linux_get_hw_breakpoint_count): Use arm_linux_hwbp_cap.
14220 (arm_linux_get_hw_watchpoint_count): Likewise.
14221 (arm_linux_get_hw_watchpoint_max_length): Likewise.
14222 (arm_arch_setup): Call arm_linux_init_hwbp_cap.
14223 (arm_prepare_to_resume): Use perror_with_name instead of error.
14224
14225 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
14226
14227 * linux-arm-low.c: Include <signal.h>.
14228 (PTRACE_GETHBPREGS, PTRACE_SETHBPREGS): Define if necessary.
14229 (struct arm_linux_hwbp_cap): New data type.
14230 (arm_hwbp_type, arm_hwbp_control_t): New typedefs.
14231 (struct arm_linux_hw_breakpoint): New data type.
14232 (MAX_BPTS, MAX_WPTS): Define.
14233 (struct arch_process_info, struct arch_lwp_info): New data types.
14234 (arm_linux_get_hwbp_cap): New function.
14235 (arm_linux_get_hw_breakpoint_count): Likewise.
14236 (arm_linux_get_hw_watchpoint_count): Likewise.
14237 (arm_linux_get_hw_watchpoint_max_length): Likewise.
14238 (arm_hwbp_control_initialize): Likewise.
14239 (arm_hwbp_control_is_enabled): Likewise.
14240 (arm_hwbp_control_is_initialized): Likewise.
14241 (arm_hwbp_control_disable): Likewise.
14242 (arm_linux_hw_breakpoint_equal): Likewise.
14243 (arm_linux_hw_point_initialize): Likewise.
14244 (struct update_registers_data): New data structure.
14245 (update_registers_callback: New function.
14246 (arm_insert_point): Likewise.
14247 (arm_remove_point): Likewise.
14248 (arm_stopped_by_watchpoint): Likewise.
14249 (arm_stopped_data_address): Likewise.
14250 (arm_new_process): Likewise.
14251 (arm_new_thread): Likewise.
14252 (arm_prepare_to_resume): Likewise.
14253 (the_low_target): Register arm_insert_point, arm_remove_point,
14254 arm_stopped_by_watchpoint, arm_stopped_data_address, arm_new_process,
14255 arm_new_thread, and arm_prepare_to_resume.
14256
14257 2011-09-15 Stan Shebs <stan@codesourcery.com>
14258
14259 * server.h (struct emit_ops): Add compare-goto fields.
14260 * tracepoint.c (gdb_agent_op_sizes): New table.
14261 (emit_eq_goto): New function.
14262 (emit_ne_goto): New function.
14263 (emit_lt_goto): New function.
14264 (emit_le_goto): New function.
14265 (emit_gt_goto): New function.
14266 (emit_ge_goto): New function.
14267 (is_goto_target): New function.
14268 (compile_bytecodes): Recognize special cases of compare-goto
14269 combinations and call specialized emitters for them.
14270 * linux-x86-low.c (amd64_emit_eq_goto): New function.
14271 (amd64_emit_ne_goto): New function.
14272 (amd64_emit_lt_goto): New function.
14273 (amd64_emit_le_goto): New function.
14274 (amd64_emit_gt_goto): New function.
14275 (amd64_emit_ge_goto): New function.
14276 (amd64_emit_ops): Add the new functions.
14277 (i386_emit_eq_goto): New function.
14278 (i386_emit_ne_goto): New function.
14279 (i386_emit_lt_goto): New function.
14280 (i386_emit_le_goto): New function.
14281 (i386_emit_gt_goto): New function.
14282 (i386_emit_ge_goto): New function.
14283 (i386_emit_ops): Add the new functions.
14284
14285 2011-09-08 Stan Shebs <stan@codesourcery.com>
14286
14287 * linux-x86-low.c (i386_emit_prologue): Save %ebx.
14288 (i386_emit_epilogue): Restore %ebx.
14289
14290 2011-08-31 Jie Zhang <jzhang918@gmail.com>
14291
14292 * server.c (step_thread): Remove definition.
14293 (process_serial_event): Don't handle Hs.
14294 * server.h (step_thread): Remove declaration.
14295 * target.c (set_desired_inferior): Remove use of step_thread.
14296
14297 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
14298
14299 * linux-low.c: Include linux-procfs.h.
14300 (linux_attach_lwp_1): Update comments.
14301 (linux_attach): Scan for existing threads when attaching to a
14302 process that is the tgid.
14303 * Makefile.in: Update dependencies.
14304
14305 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
14306
14307 * configure.srv: Add linux-procfs.o dependencies.
14308
14309 2011-08-14 Yao Qi <yao@codesourcery.com>
14310
14311 * target.h (struct target_ops): Fix indent.
14312 * win32-low.c (win32_target_ops): Fix comment.
14313
14314 2011-08-14 Andrew Jenner <andrew@codesourcery.com>
14315 Yao Qi <yao@codesourcery.com>
14316
14317 * Makefile.in (clean): Remove tic6x-*.c files.
14318 (linux-tic6x-low.o, tic6x-c62x-linux.o, tic6x-c64x-linux.o): New rules.
14319 (tic6x-c64xp-linux.o, tic6x-c62x-linux.c, tic6x-c64x-linux.c): Likewise.
14320 (tic6x-c64xp-linux.c): Likewise.
14321 * configure.srv: Add support for tic6x-*-uclinux.
14322 * linux-tic6x-low.c: New.
14323 * linux-low.c (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define.
14324
14325 2011-08-14 Andrew Stubbs <ams@codesourcery.com>
14326 Yao Qi <yao@codesourcery.com>
14327
14328 * target.h (struct target_ops): Add read_loadmap.
14329 * linux-low.c (struct target_loadseg): New type.
14330 (struct target_loadmap): New type.
14331 (linux_read_loadmap): New function.
14332 (linux_target_ops): Add linux_read_loadmap.
14333 * server.c (handle_query): Support qXfer:fdpic:read packet.
14334 * win32-low.c (win32_target_ops): Initialize field `read_loadmap'
14335 to NULL.
14336
14337 2011-08-05 Eli Zaretskii <eliz@gnu.org>
14338
14339 * win32-low.c: Include <stdint.h>.
14340
14341 2011-07-22 Pedro Alves <pedro@codesourcery.com>
14342
14343 * i386-low.c (i386_insert_aligned_watchpoint): Don't pass the info
14344 to the inferior here.
14345 (i386_remove_aligned_watchpoint): Ditto.
14346 (i386_handle_nonaligned_watchpoint): Return immediate on fail to
14347 fit part of the watchpoint in the debug registers.
14348 (i386_update_inferior_debug_regs): New.
14349 (i386_low_insert_watchpoint): Work on a local mirror of the debug
14350 registers, and only update the inferior on success.
14351 (i386_low_remove_watchpoint): Ditto.
14352
14353 2011-07-22 Kwok Cheung Yeung <kcy@codesourcery.com>
14354
14355 * linux-low.c (compare_ints, unique, list_threads, show_process,
14356 linux_core_of_thread): Delete.
14357 (linux_target_ops): Change linux_core_of_thread to
14358 linux_common_core_of_thread.
14359 (linux_qxfer_osdata): Defer to linux_common_xfer_osdata.
14360 * utils.c (malloc_failure): Change type of argument.
14361 (xmalloc, xrealloc, xcalloc, xsnprintf): Delete.
14362 * Makefile.in (SFILES): Add common/common-utils.c, common/xml-utils.c,
14363 common/linux-osdata.c, common/ptid.c and common/buffer.c.
14364 (OBS): Add xml-utils.o, common-utils.o, ptid.o and buffer.o.
14365 (IPA_OBJS): Add common-utils-ipa.o.
14366 (ptid_h, linux_osdata_h): New macros.
14367 (server_h): Add common/common-utils.h, common/xml-utils.h,
14368 common/buffer.h, common/gdb_assert.h, common/gdb_locale.h and
14369 common/ptid.h.
14370 (common-utils-ipa.o, common-utils.o, xml-utils.o, linux-osdata.o,
14371 ptid.o, buffer.o): New rules.
14372 (linux-low.o): Add common/linux-osdata.h as a dependency.
14373 * configure.srv (srv_tgtobj): Add linux-osdata.o to Linux targets.
14374 * configure.ac: Add AC_HEADER_DIRENT check.
14375 * config.in: Regenerate.
14376 * configure: Regenerate.
14377 * remote-utils.c (xml_escape_text): Delete.
14378 (buffer_grow, buffer_free, buffer_init, buffer_finish,
14379 buffer_xml_printf): Move to common/buffer.c.
14380 * server.c (main): Remove call to initialize_inferiors.
14381 * server.h (struct ptid, ptid_t, minus_one_ptid, null_ptid,
14382 ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp, ptid_get_tid,
14383 ptid_equal, ptid_is_pid, initialize_inferiors, xml_escape_text,
14384 internal_error, gdb_assert, gdb_assert_fail): Delete.
14385 (struct buffer, buffer_grow, buffer_free, buffer_init, buffer_finish,
14386 buffer_xml_printf, buffer_grow_str, buffer_grow_str0): Move to
14387 common/buffer.h.
14388 * inferiors.c (null_ptid, minus_one_ptid, ptid_build, pid_to_ptid,
14389 ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal, ptid_is_pid,
14390 initialize_inferiors): Delete.
14391
14392 2011-07-20 Pedro Alves <pedro@codesourcery.com>
14393
14394 * tracepoint.c (tracepoint_look_up_symbols): Return upon the first
14395 symbol error.
14396
14397 2011-05-31 Pedro Alves <pedro@codesourcery.com>
14398
14399 * linux-x86-low.c (i386_dr_low_get_addr): Fix off by one in
14400 assertion.
14401 * win32-i386-low.c (i386_dr_low_get_addr): Ditto.
14402
14403 2011-05-26 Yao Qi <yao@codesourcery.com>
14404
14405 * Makefile.in (thread-db.o): Track dependence to
14406 common/gdb_thread_db.h.
14407 * thread-db.c: include gdb_thread_db.h from right place.
14408
14409 2011-05-16 Adrian Cornish <gnu@bluedreamer.com>
14410
14411 * linux-i386-ipa.c (supply_static_tracepoint_registers): Pass
14412 __FILE__ and __LINE__ to internal_error.
14413
14414 2011-05-13 Doug Evans <dje@google.com>
14415
14416 * thread-db.c (try_thread_db_load_from_sdir): New function.
14417 (try_thread_db_load_from_dir): New function.
14418 (thread_db_load_search): Handle $sdir, ignore $pdir.
14419 Remove trying of system directories if search of
14420 libthread-db-search-path fails, that is now done via $sdir.
14421
14422 2011-05-12 Kwok Cheung Yeung <kcy@codesourcery.com>
14423
14424 * server.c (handle_query): Add EnableDisableTracepoints to the list
14425 of supported features.
14426 * tracepoint.c (clear_installed_tracepoints): Uninstall disabled
14427 tracepoints.
14428 (cmd_qtenable_disable): New.
14429 (cmd_qtstart): Install tracepoints even if disabled.
14430 (handle_tracepoint_general_set): Add call to cmd_qtenable_disable on
14431 receiving a QTEnable or QTDisable packet.
14432 (gdb_collect): Skip data collection if fast tracepoint is disabled.
14433 (ust_marker_to_static_tracepoint): Do not ignore disabled static
14434 tracepoints.
14435 (gdb_probe): Skip data collection if static tracepoint is disabled.
14436
14437 2011-05-10 Doug Evans <dje@google.com>
14438
14439 * thread-db.c (thread_db_handle_monitor_command): Handle elided path.
14440
14441 2011-05-04 Doug Evans <dje@google.com>
14442
14443 * linux-low.c (linux_join): Skip process lookup.
14444 * spu-low.c (spu_join): Ditto.
14445 * server.c (join_inferiors_callback): Delete.
14446 (process_serial_event): For 'D' packet (detach) call join_inferior
14447 directly.
14448
14449 2011-05-04 Joseph Myers <joseph@codesourcery.com>
14450
14451 * README: Don't mention xscale*-*-linux*.
14452 * configure.srv (xscale*-*-linux*): Don't handle target.
14453
14454 2011-04-27 Nathan Froyd <froydnj@codesourcery.com>
14455
14456 * linux-x86-low.c (amd64_emit_const): Call memcpy instead of
14457 casting pointers.
14458 (amd64_emit_reg, amd64_emit_int_call_1, amd64_emit_void_call_2):
14459 (i386_emit_const, i386_emit_reg, i386_emit_int_call_1):
14460 (i386_emit_void_call_2): Likewise.
14461
14462 2011-04-26 Yao Qi <yao@codesourcery.com>
14463
14464 * linux-low.c: Move common macros to linux-ptrace.h.
14465 Include linux-ptrace.h.
14466 * Makefile.in (linux_ptrace_h): New.
14467 (linux-low.o): Depends on linux-ptrace.h.
14468
14469 2011-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
14470
14471 * remote-utils.c (handle_accept_event): Close LISTEN_DESC only if
14472 RUN_ONCE. Comment for the LISTEN_DESC delete_file_handler call.
14473 (remote_prepare): New function with most of the TCP code from ...
14474 (remote_open): ... here. Detect PORT here unconditionally. Move also
14475 setting transport_is_reliable.
14476 * server.c (run_once): New variable.
14477 (gdbserver_usage): Document it.
14478 (main): Set run_once for `--once'. Call remote_prepare. Exit after
14479 the first run if RUN_ONCE.
14480 * server.h (run_once, remote_prepare): New declarations.
14481
14482 2011-04-19 Tom Tromey <tromey@redhat.com>
14483
14484 * win32-low.c (handle_load_dll): Remove duplicate "the".
14485
14486 2011-04-07 Pierre Muller <muller@ics.u-strasbg.fr>
14487
14488 Remove support for old Cygwin 1.5 versions.
14489 * win32-low.c (win32_create_inferior): Use new cygwin_path_list
14490 function to avoid warning.
14491 (win32_add_one_solib): Use cygwin_conv_path function to avoid
14492 warning.
14493
14494 2011-03-18 Pierre Muller <muller@ics.u-strasbg.fr>
14495
14496 * gdbserver/server.h (Macro _): Define it if not available.
14497
14498 2011-03-14 Michael Snyder <msnyder@vmware.com>
14499
14500 * hostio.c (handle_close): Remove unnecessary null test.
14501
14502 2011-03-10 Joel Brobecker <brobecker@adacore.com>
14503
14504 * Makefile.in (maintainer-clean realclean distclean): Remove
14505 "make ... subdir_do" command.
14506
14507 2011-03-10 Michael Snyder <msnyder@vmware.com>
14508
14509 * tracepoint.c (tracepoint_finish_step): Fix loop variable.
14510
14511 * server.c (handle_v_run): Free alloced buffer on early return.
14512
14513 2011-03-09 Yao Qi <yao@codesourcery.com>
14514
14515 Revert:
14516 2011-03-04 Yao Qi <yao@codesourcery.com>
14517
14518 * Makefile.in: Remove GNU make feature --directory.
14519
14520 2011-03-05 Yao Qi <yao@codesourcery.com>
14521
14522 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
14523 (subdir_do): New make target. Copied from gdb/Makefile.
14524 (maintainer-clean, realclean, distclean, clean): Call corresponding
14525 make targets in common/Makefile.
14526
14527 2011-02-11 Yao Qi <yao@codesourcery.com>
14528
14529 * configure.ac: Call AC_PROG_RANLIB.
14530 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
14531 * configure: Regenerate.
14532
14533 2011-03-07 Jan Kratochvil <jan.kratochvil@redhat.com>
14534
14535 * remote-utils.c (putpkt_binary_1): Calculate BUF2 size dynamically.
14536
14537 2011-03-06 Yao Qi <yao@codesourcery.com>
14538
14539 * Makefile.in (REQUIRED_SUBDIRS): Remove $(LIBCOMMON_DIR).
14540
14541 2011-03-05 Yao Qi <yao@codesourcery.com>
14542
14543 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
14544 (subdir_do): New make target. Copied from gdb/Makefile.
14545 (maintainer-clean, realclean, distclean, clean): Call corresponding
14546 make targets in common/Makefile.
14547
14548 2011-03-04 Yao Qi <yao@codesourcery.com>
14549
14550 * Makefile.in: Remove GNU make feature --directory.
14551
14552 2011-03-04 Michael Snyder <msnyder@vmware.com>
14553
14554 * server.c (queue_stop_reply): Call xmalloc not malloc.
14555
14556 2011-03-02 Michael Snyder <msnyder@vmware.com>
14557
14558 * linux-arm-low.c (arm_arch_setup): Replace malloc with xmalloc.
14559
14560 2011-02-28 Michael Snyder <msnyder@vmware.com>
14561
14562 * tracepoint.c (cmd_qtv): Discard unused value 'packet'.
14563 (cmd_qtframe): Ditto.
14564 (cmd_qtbuffer): Ditto.
14565 (cmd_bigqtbuffer): Ditto.
14566
14567 * utils.c (decimal2str): Initialize 'width' to nine, then
14568 don't mess with it.
14569
14570 2011-02-28 Ulrich Weigand <uweigand@de.ibm.com>
14571
14572 * hostio.c (require_data): Free *data, not data.
14573
14574 2011-02-28 Jan Kratochvil <jan.kratochvil@redhat.com>
14575
14576 * hostio.c (require_data): Use free, not xfree.
14577
14578 2011-02-27 Michael Snyder <msnyder@vmware.com>
14579
14580 * server.c (handle_query): Discard unused value.
14581
14582 * hostio.c (require_data): Free malloc memory before returning
14583 error.
14584
14585 2011-02-26 Michael Snyder <msnyder@vmware.com>
14586
14587 * linux-low.c (list_threads): Call closedir for dirent.
14588
14589 2011-02-27 Michael Snyder <msnyder@vmware.com>
14590
14591 * i386-low.c (i386-length_and_rw_bits): Comment the fact that
14592 a case statement falls through.
14593
14594 * linux-low.c (linux_xfer_siginfo): Fix fencepost error.
14595
14596 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Fix fencepost error
14597 in comparison.
14598
14599 2011-02-26 Michael Snyder <msnyder@vmware.com>
14600
14601 * utils.c (decimal2str): Eliminate dead code and dead param.
14602 (pulongest): Drop dead param from call to decimal2str.
14603 (plongest): Ditto.
14604
14605 2011-02-24 Joel Brobecker <brobecker@adacore.com>
14606
14607 Revert the following patch (not approved yet):
14608 2011-02-21 Hui Zhu <teawater@gmail.com>
14609 * tracepoint.c (tp_printf): New function.
14610 (eval_agent_expr): Handle gdb_agent_op_printf.
14611
14612 2011-02-21 Hui Zhu <teawater@gmail.com>
14613
14614 * tracepoint.c (tp_printf): New function.
14615 (eval_agent_expr): Handle gdb_agent_op_printf.
14616
14617 2011-02-18 Tom Tromey <tromey@redhat.com>
14618
14619 * Makefile.in (tracepoint-ipa.o): Depend on ax.def.
14620 (tracepoint.o): Likewise.
14621 * tracepoint.c (enum gdb_agent_op): Use ax.def.
14622 (gdb_agent_op_names): Likewise.
14623
14624 2011-02-18 Tom Tromey <tromey@redhat.com>
14625
14626 * tracepoint.c (enum gdb_agent_op) <gdb_agent_op_pick,
14627 gdb_agent_op_rot>: New constants.
14628 (gdb_agent_op_names): Add pick and roll.
14629 (eval_agent_expr) <gdb_agent_op_pick, gdb_agent_op_rot>: New
14630 cases.
14631
14632 2011-02-15 Jan Kratochvil <jan.kratochvil@redhat.com>
14633
14634 * aclocal.m4: Regenerated with aclocal-1.11.1.
14635
14636 2011-02-14 Pedro Alves <pedro@codesourcery.com>
14637
14638 * server.c (handle_qxfer_traceframe_info): New.
14639 (qxfer_packets): Register "traceframe-info".
14640 (handle_query): Report support for qXfer:traceframe-info:read+.
14641 * tracepoint.c (match_blocktype): New.
14642 (traceframe_find_block_type): Rename to ...
14643 (traceframe_walk_blocks): ... this. Add callback filter argument,
14644 and use it.
14645 (traceframe_find_block_type): New, reimplemented on top of
14646 traceframe_walk_blocks.
14647 (build_traceframe_info_xml): New.
14648 (traceframe_read_info): New.
14649 * server.h (traceframe_read_info): Declare.
14650
14651 2011-02-11 Yao Qi <yao@codesourcery.com>
14652
14653 * configure.ac: Call AC_PROG_RANLIB.
14654 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
14655 * configure: Regenerate.
14656
14657 2011-02-07 Pedro Alves <pedro@codesourcery.com>
14658
14659 * server.c (gdb_read_memory): Change return semantics to allow
14660 partial transfers.
14661 (handle_search_memory_1): Adjust.
14662 (process_serial_event) <'m' packet>: Handle partial transfers.
14663 * tracepoint.c (traceframe_read_mem): Handle partial transfers.
14664
14665 2011-01-28 Pedro Alves <pedro@codesourcery.com>
14666
14667 * regcache.c (init_register_cache): Initialize
14668 regcache->register_status.
14669 (free_register_cache): Release regcache->register_status.
14670 (regcache_cpy): Copy register_status.
14671 (registers_to_string): Print 'x's for unavailable registers.
14672 (supply_register): Mark the register's status valid or
14673 unavailable, depending on whether a buffer was passed in or not.
14674 (supply_register_zeroed): New.
14675 (supply_regblock): Mark the registers' status valid or
14676 unavailable, depending on whether a buffer was passed in or not.
14677 * regcache.h (REG_UNAVAILABLE, REG_VALID): New defines.
14678 (struct regcache): New `register_status' field.
14679 (supply_register_zeroed): Declare.
14680 * i387-fp.c (i387_xsave_to_cache): Zero out registers using
14681 supply_register_zeroed, rather than passing a NULL buffer to
14682 supply_register.
14683 * tracepoint.c (fetch_traceframe_registers): Update comment.
14684
14685 2011-01-28 Pedro Alves <pedro@codesourcery.com>
14686
14687 * i387-fp.c (i387_xsave_to_cache): Make passing NULL as register
14688 buffer explicit.
14689
14690 2011-01-25 Pedro Alves <pedro@codesourcery.com>
14691
14692 * server.h (decode_xfer_write): Change prototype.
14693 * remote-utils.c (decode_xfer_write): Remove `annex' parameter,
14694 and don't extract the annex here.
14695 * server.c (decode_xfer_read): Remove `annex' parameter,
14696 and don't extract the annex here.
14697 (decode_xfer): New.
14698 (struct qxfer): New.
14699 (handle_qxfer_auxv, handle_qxfer_features, handle_qxfer_libraries)
14700 (handle_qxfer_osdata, handle_qxfer_siginfo, handle_qxfer_spu)
14701 (handle_qxfer_statictrace): New functions, abstracted out from
14702 handle_query, and made to use the struct qxfer interface.
14703 (handle_threads_qxfer_proper): Rename to ...
14704 (handle_qxfer_threads_proper): ... this.
14705 (handle_threads_qxfer): Rename to ...
14706 (handle_qxfer_threads): ... this. Adjust.
14707 (qxfer_packets): New array.
14708 (handle_qxfer): New function.
14709 (handle_query): Use handle_qxfer.
14710
14711 2011-01-05 Michael Snyder <msnyder@msnyder-server.eng.vmware.com>
14712
14713 * gdbreplay.c: Shorten lines of >= 80 columns.
14714 * linux-low.c: Ditto.
14715 * linux-ppc-low.c: Ditto.
14716 * linux-s390-low.c: Ditto.
14717 * linux-sparc-low.c: Ditto.
14718 * linux-x86-low.c: Ditto.
14719 * linux-xtensa-low.c: Ditto.
14720 * mem-break.c: Ditto.
14721 * nto-low.c: Ditto.
14722 * regcache.h: Ditto.
14723 * remote-utils.c: Ditto.
14724 * server.c: Ditto.
14725 * server.h: Ditto.
14726 * thread-db.c: Ditto.
14727 * tracepoint.c: Ditto.
14728 * utils.c: Ditto.
14729 * win32-low.h: Ditto.
14730
14731 2011-01-05 Joel Brobecker <brobecker@adacore.com>
14732
14733 * gdbserver/configure.ac, gdbserver/gdbserver.1: Copyright year
14734 update.
14735
14736 2011-01-01 Joel Brobecker <brobecker@adacore.com>
14737
14738 * server.c (gdbserver_version): Update copyright year in version
14739 output.
14740 * gdbreplay.c (gdbreplay_version): Ditto.
14741
14742 2010-12-29 Jie Zhang <jie.zhang@analog.com>
14743
14744 * configure.srv (bfin-*-*linux*): Handle Blackfin/Linux targets.
14745 * linux-bfin-low.c: New file.
14746 * linux-low.c: Define PT_TEXT_ADDR, PT_TEXT_END_ADDR, and
14747 PT_DATA_ADDR for BFIN targets.
14748 * Makefile.in (SFILES): Add linux-bfin-low.c.
14749 (clean): Remove reg-bfin.c.
14750 (linux-bfin-low.o, reg-bfin.o, reg-bfin.c): New targets.
14751 * README: Mention supported Blackfin targets.
14752
14753 2010-12-23 Mike Frysinger <vapier@gentoo.org>
14754
14755 * .gitignore: New file.
14756
14757 2010-11-16 Mike Frysinger <vapier@gentoo.org>
14758
14759 * linux-low.c (linux_tracefork_child): Add char* cast to arg.
14760
14761 2010-10-22 Jie Zhang <jie@codesourcery.com>
14762
14763 * Makefile.in: Add FLAGS_TO_PASS variable.
14764 (install): Remove dependency of install-only and recursively
14765 invoke make for install-only.
14766
14767 2010-10-04 Doug Evans <dje@google.com>
14768
14769 * Makefile.in (uninstall): Use $(DESTDIR).
14770
14771 2010-09-24 Pedro Alves <pedro@codesourcery.com>
14772
14773 PR gdb/11842
14774
14775 * linux-x86-low.c (compat_siginfo_from_siginfo)
14776 (siginfo_from_compat_siginfo): Also copy si_pid and si_uid when
14777 si_code is < 0. Check for si_code == SI_TIMER before checking for
14778 si_code < 0.
14779
14780 2010-09-13 Joel Brobecker <brobecker@adacore.com>
14781
14782 * lynx-i386-low.c: New file.
14783 * configure.srv: Add handling of i[34567]86-*-lynxos* targets.
14784
14785 2010-09-13 Joel Brobecker <brobecker@adacore.com>
14786
14787 * lynx-low.c (ptrace_request_to_str): Remove handling for
14788 request values that have been removed in LynxOS 5.x.
14789
14790 2010-09-13 Joel Brobecker <brobecker@adacore.com>
14791
14792 * lynx-low.c, lynx-ppc-loc.c: Include <sys/ptrace.h> instead of
14793 <ptrace.h>
14794
14795 2010-09-09 Nathan Sidwell <nathan@codesourcery.com>
14796
14797 * configure.ac: Add --enable-inprocess-agent option.
14798 * configure: Rebuilt.
14799
14800 2010-09-06 Yao Qi <yao@codesourcery.com>
14801
14802 * linux-low.c (linux_kill): Remove unused variable.
14803 (linux_stabilize_threads): Likewise.
14804 * server.c (start_inferior): Likewise.
14805 (queue_stop_reply_callback): Likewise.
14806 * tracepoint.c (do_action_at_tracepoint): Likewise.
14807
14808 2010-09-06 Yao Qi <yao@codesourcery.com>
14809
14810 * linux-low.c (maybe_move_out_of_jump_pad): Restore current_inferior
14811 on return.
14812
14813 2010-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
14814
14815 * target.c (mywait) <TARGET_WAITKIND_EXITED>: Fix to use INTEGER.
14816
14817 2010-09-06 Pedro Alves <pedro@codesourcery.com>
14818
14819 * Makefile.in (install-only): Replace $IPA_DEPFILES with
14820 "$(IPA_DEPFILES)".
14821
14822 2010-09-01 Joel Brobecker <brobecker@adacore.com>
14823
14824 * gdbserver/lynx-low.c, gdbserver/lynx-low.h,
14825 gdbserver/lynx-ppc-low.c: New files.
14826 * Makefile.in (lynx_low_h): New variable.
14827 (lynx-low.o, lynx-ppc-low.o): New rules.
14828 * configure.ac: On LynxOS, link with -lnetinet.
14829 * configure.srv: Add handling of powerpc-*-lynxos* targets.
14830 * configure: regenerate.
14831
14832 2010-09-01 Joel Brobecker <brobecker@adacore.com>
14833
14834 * Makefile.in (vasprintf.o, vsnprintf.o): New rules.
14835 * configure.ac: Add check for vasprintf and vsnprintf.
14836 * configure, config.in: Regenerate.
14837 * server.h (vasprintf, vsnprintf): Add conditional declarations.
14838
14839 2010-09-01 Joel Brobecker <brobecker@adacore.com>
14840
14841 * gdbreplay.c: Move include of alloca.h up, next to include of
14842 malloc.h.
14843 * server.h: Add include of malloc.h.
14844 * mem-break.c: Remove include of malloc.h.
14845 * server.c, tracepoint.c, utils.c, win32-low.c: Likewise.
14846
14847 2010-09-01 Joel Brobecker <brobecker@adacore.com>
14848
14849 * Makefile.in (memmem.o): Build with -Wno-error.
14850
14851 2010-09-01 Joel Brobecker <brobecker@adacore.com>
14852
14853 * utils.c (xsnprintf): Make non-static.
14854 * server.h: Add xsnprintf declaration.
14855 * linux-low.c, nto-low.c, target.c, thread-db.c, tracepoint.c:
14856 replace calls to snprintf by calls to xsnprintf throughout.
14857
14858 2010-09-01 Joel Brobecker <brobecker@adacore.com>
14859
14860 * configure.ac: Add configure check for alloca.
14861 * configure, config.in: Regenerate.
14862 * server.h: Include alloca.h if it exists.
14863 * gdbreplay.c: Include alloca.h if it exists.
14864
14865 2010-08-28 Pedro Alves <pedro@codesourcery.com>
14866
14867 * linux-low.c (__SIGRTMIN): Define if not already defined.
14868 (linux_create_inferior): Check for __ANDROID__ rather than
14869 __SIGRTMIN.
14870 (enqueue_one_deferred_signal): Don't requeue non-RT signals that
14871 are already deferred.
14872 (linux_wait_1): Check for __ANDROID__ rather than __SIGRTMIN.
14873 (linux_resume_one_thread): Don't queue a SIGSTOP if the lwp is
14874 stopped and already has a pending signal to report.
14875 (proceed_one_lwp): : Don't queue a SIGSTOP if the lwp already has
14876 a pending signal to report or is moving out of a jump pad.
14877 (linux_init_signals): Check for __ANDROID__ rather than
14878 __SIGRTMIN.
14879
14880 2010-08-28 Pedro Alves <pedro@codesourcery.com>
14881
14882 * linux-low.c (linux_stabilize_threads): Wrap debug output in a
14883 debug_threads check. Avoid a linear search when not doing debug
14884 output.
14885
14886 2010-08-27 Pedro Alves <pedro@codesourcery.com>
14887
14888 * event-loop.c (event_handle_func): Adjust to use gdb_fildes_t.
14889 (struct gdb_event) <fd>: Change type to gdb_fildes_t.
14890 (struct file_handler) <fd>: Change type to gdb_fildes_t.
14891 (process_event): Change local fd's type to gdb_fildes_t.
14892 (create_file_handler): Adjust prototype.
14893 (delete_file_handler): Adjust prototype.
14894 (handle_file_event): Adjust prototype. Use pfildes.
14895 (create_file_event): Adjsut prototype.
14896 * remote-utils.c (remote_desc, listen_desc): Change type to
14897 gdb_fildes_t.
14898 * server.h: New gdb_fildes_t typedef.
14899 [USE_WIN32API]: Include winsock2.h.
14900 (delete_file_handler, add_file_handler): Adjust prototypes.
14901 (pfildes): Declare.
14902 * utils.c (pfildes): New.
14903
14904 2010-08-27 Pedro Alves <pedro@codesourcery.com>
14905
14906 * configure.ac (build_warnings): Add -Wno-char-subscripts.
14907 * configure: Regenerate.
14908
14909 2010-08-27 Pedro Alves <pedro@codesourcery.com>
14910
14911 * linux-low.c (linux_unprepare_to_access_memory): Rename to ...
14912 (linux_done_accessing_memory): ... this.
14913 (linux_target_ops): Adjust.
14914 * linux-x86-low.c (x86_insert_point, x86_remove_point): Adjust.
14915 * nto-low.c (nto_target_ops): Adjust comment.
14916 * server.c (gdb_read_memory, gdb_write_memory): Adjust.
14917 * spu-low.c (spu_target_ops): Adjust comment.
14918 * target.h (target_ops): Rename unprepare_to_access_memory field
14919 to done_accessing_memory.
14920 (unprepare_to_access_memory): Rename to ...
14921 (done_accessing_memory): ... this.
14922
14923 2010-08-26 Pedro Alves <pedro@codesourcery.com>
14924
14925 * linux-low.c (linux_prepare_to_access_memory): New.
14926 (linux_unprepare_to_access_memory): New.
14927 (linux_target_ops): Install them.
14928 * server.c (read_memory): Rename to ...
14929 (gdb_read_memory): ... this. Use
14930 prepare_to_access_memory/prepare_to_access_memory.
14931 (write_memory): Rename to ...
14932 (gdb_write_memory): ... this. Use
14933 prepare_to_access_memory/prepare_to_access_memory.
14934 (handle_search_memory_1): Adjust.
14935 (process_serial_event): Adjust.
14936 * target.h (struct target_ops): New fields
14937 prepare_to_access_memory and unprepare_to_access_memory.
14938 (prepare_to_access_memory, unprepare_to_access_memory): New.
14939 * linux-x86-low.c (x86_insert_point, x86_remove_point): Use
14940 prepare_to_access_memory/prepare_to_access_memory.
14941 * nto-low.c (nto_target_ops): Adjust.
14942 * spu-low.c (spu_target_ops): Adjust.
14943 * win32-low.c (win32_target_ops): Adjust.
14944
14945 2010-08-26 Pedro Alves <pedro@codesourcery.com>
14946
14947 * Makefile.in (WARN_CFLAGS): Get it from configure.
14948 (WERROR_CFLAGS): New.
14949 (INTERNAL_CFLAGS): Add WERROR_CFLAGS.
14950 * configure.ac: Introduce --enable-werror, which adds -Werror to
14951 the compiler command line. Enabled by default. Disable with
14952 --disable-werror. Add -Wdeclaration-after-statement
14953 Wpointer-arith and -Wformat-nonliteral to warning flags.
14954 * configure: Regenerate.
14955
14956 2010-08-26 Pedro Alves <pedro@codesourcery.com>
14957
14958 * mem-break.c [HAVE_MALLOC_H]: Include malloc.h.
14959
14960 2010-08-26 Pedro Alves <pedro@codesourcery.com>
14961
14962 * gdbreplay.c (remote_error): New.
14963 (gdbchar): New.
14964 (expect): Use gdbchar. Check for error reading from GDB.
14965 Clarify sync error output.
14966 (play): Check for errors writing to GDB.
14967 * linux-low.c (sigchld_handler): Really ignore `write' errors.
14968 * remote-utils.c (getpkt): Check for errors writing to the remote
14969 descriptor.
14970
14971 2010-08-25 Pedro Alves <pedro@codesourcery.com>
14972
14973 * linux-low.c (linux_wait_1): Move non-debugging code out of
14974 `debug_threads' control.
14975
14976 2010-08-25 Pedro Alves <pedro@codesourcery.com>
14977
14978 * linux-low.c (linux_wait_1): Don't set last_status here.
14979 * server.c (push_event, queue_stop_reply_callback): Assert we're
14980 not pushing a TARGET_WAITKIND_IGNORE event.
14981 (start_inferior, start_inferior, attach_inferior, handle_v_cont)
14982 (myresume, handle_target_event): Set the thread's last_resume_kind
14983 and last_status from the target returned status.
14984
14985 2010-08-25 Pedro Alves <pedro@codesourcery.com>
14986
14987 PR threads/10729
14988
14989 * linux-x86-low.c (update_debug_registers_callback): New.
14990 (i386_dr_low_set_addr): Use it.
14991 (i386_dr_low_get_addr): New.
14992 (i386_dr_low_set_control): Use update_debug_registers_callback.
14993 (i386_dr_low_get_control): New.
14994 (i386_dr_low_get_status): Adjust.
14995 * linux-low.c (linux_stop_lwp): New.
14996 * linux-low.h (linux_stop_lwp): Declare.
14997
14998 * i386-low.c (I386_DR_GET_RW_LEN): Take the dr7 contents as
14999 argument instead of a i386_debug_reg_state.
15000 (I386_DR_WATCH_HIT): Take the dr6 contents as argument instead of
15001 a i386_debug_reg_state.
15002 (i386_insert_aligned_watchpoint): Adjust.
15003 (i386_remove_aligned_watchpoint): Adjust.
15004 (i386_low_stopped_data_address): Read the debug registers from the
15005 inferior instead of from the mirrors.
15006 * i386-low.h (struct i386_debug_reg_state): Extend comment.
15007 (i386_dr_low_get_addr): Declare.
15008 (i386_dr_low_get_control): Declare.
15009 (i386_dr_low_get_status): Change prototype.
15010
15011 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): New globals.
15012 (i386_dr_low_get_addr): New.
15013 (i386_dr_low_get_control): New.
15014 (i386_dr_low_get_status): Adjust prototype. Return
15015 dr_status_mirror.
15016 (i386_initial_stuff): Clear dr_status_mirror and
15017 dr_control_mirror.
15018 (i386_get_thread_context): Adjust.
15019 (i386_set_thread_context): Adjust.
15020 (i386_thread_added): Adjust.
15021
15022 2010-08-24 Pedro Alves <pedro@codesourcery.com>
15023
15024 * linux-low.h (linux_thread_area): Delete declaration.
15025
15026 2010-08-11 Thomas Schwinge <thomas@codesourcery.com>
15027
15028 * linux-low.c (linux_wait_1): Correctly return the ptid of the child
15029 after its termination.
15030
15031 2010-08-09 Pedro Alves <pedro@codesourcery.com>
15032
15033 * linux-low.c (gdb_wants_lwp_stopped): Delete.
15034 (gdb_wants_all_stopped): Delete.
15035 (linux_wait_1): Don't call them.
15036 * server.c (handle_v_cont): Tag all threads as want-stopped.
15037 (gdb_wants_thread_stopped): Fix comments. Tag the thread that
15038 stopped as "client-wants-stopped".
15039
15040 2010-07-31 Pedro Alves <pedro@codesourcery.com>
15041
15042 * Makefile.in (signals_h): New.
15043 (server_h): Depend on it.
15044 (server.o): Don't depend on $(signals_def).
15045 (signals.o): Depend on $(signals_def).
15046
15047 2010-07-31 Jan Kratochvil <jan.kratochvil@redhat.com>
15048
15049 * Makefile.in (signals_def): New.
15050 (server_h): Append include/gdb/signals.h and signals_def.
15051 (server.o): Append signals_def.
15052
15053 2010-07-25 Jan Kratochvil <jan.kratochvil@redhat.com>
15054
15055 * server.c (handle_target_event): Use target_signal_to_host for
15056 resume_info.sig initialization.
15057 * target.h (struct thread_resume) <sig>: New comment.
15058
15059 2010-07-20 Ozkan Sezer <sezeroz@gmail.com>
15060
15061 * server.c (handle_query): strcpy() the returned string from paddress()
15062 instead of sprintf().
15063 * utils.c (paddress): Return phex_nz().
15064
15065 2010-07-07 Joel Brobecker <brobecker@adacore.com>
15066
15067 * server.c (handle_v_cont): Call mourn_inferior if process
15068 just exited.
15069 (myresume): Likewise.
15070
15071 2010-07-01 Pedro Alves <pedro@codesourcery.com>
15072
15073 Static tracepoints, and integration with UST.
15074
15075 * configure.ac: Handle --with-ust. substitute ustlibs and ustinc.
15076 * mem-break.c (uninsert_all_breakpoints)
15077 (reinsert_all_breakpoints): New.
15078 * mem-break.h (reinsert_all_breakpoints, uninsert_all_breakpoints):
15079 * tracepoint.c (ust_loaded, helper_thread_id, cmd_buf): New.
15080 (gdb_agent_ust_loaded, helper_thread_id)
15081 (gdb_agent_helper_thread_id): New macros.
15082 (struct ipa_sym_addresses): Add addr_ust_loaded,
15083 addr_helper_thread_id, addr_cmd_buf.
15084 (symbol_list): Add ust_loaded, helper_thread_id, cmd_buf.
15085 (in_process_agent_loaded_ust): New.
15086 (write_e_ust_not_loaded): New.
15087 (maybe_write_ipa_ust_not_loaded): New.
15088 (struct collect_static_trace_data_action): New.
15089 (enum tracepoint_type) <static_tracepoint>: New.
15090 (struct tracepoint) <handle>: Mention static tracepoints.
15091 (struct static_tracepoint_ctx): New.
15092 (CMD_BUF_SIZE): New.
15093 (add_tracepoint_action): Handle static tracepoint actions.
15094 (unprobe_marker_at): New.
15095 (clear_installed_tracepoints): Handle static tracepoints.
15096 (cmd_qtdp): Handle static tracepoints.
15097 (probe_marker_at): New.
15098 (cmd_qtstart): Handle static tracepoints.
15099 (response_tracepoint): Handle static tracepoints.
15100 (cmd_qtfstm, cmd_qtsstm, cmd_qtstmat): New.
15101 (handle_tracepoint_query): Handle qTfSTM, qTsSTM and qTSTMat.
15102 (get_context_regcache): Handle static tracepoints.
15103 (do_action_at_tracepoint): Handle static tracepoint actions.
15104 (traceframe_find_block_type): Handle static trace data blocks.
15105 (traceframe_read_sdata): New.
15106 (download_tracepoints): Download static tracepoint actions.
15107 [HAVE_UST] Include ust/ust.h, dlfcn.h, sys/socket.h, and sys/un.h.
15108 (GDB_PROBE_NAME): New.
15109 (ust_ops): New.
15110 (GET_UST_SYM): New.
15111 (USTF): New.
15112 (dlsym_ust): New.
15113 (ust_marker_to_static_tracepoint): New.
15114 (gdb_probe): New.
15115 (collect_ust_data_at_tracepoint): New.
15116 (gdb_ust_probe): New.
15117 (UNIX_PATH_MAX, SOCK_DIR): New.
15118 (gdb_ust_connect_sync_socket): New.
15119 (resume_thread, stop_thread): New.
15120 (run_inferior_command): New.
15121 (init_named_socket): New.
15122 (gdb_ust_socket_init): New.
15123 (cstr_to_hexstr): New.
15124 (next_st): New.
15125 (first_marker, next_marker): New.
15126 (response_ust_marker): New.
15127 (cmd_qtfstm, cmd_qtsstm): New.
15128 (unprobe_marker_at, probe_marker_at): New.
15129 (cmd_qtstmat, gdb_ust_thread): New.
15130 (gdb_ust_init): New.
15131 (initialize_tracepoint_ftlib): Call gdb_ust_init.
15132 * linux-amd64-ipa.c [HAVE_UST]: Include ust/processor.h
15133 (ST_REGENTRY): New.
15134 (x86_64_st_collect_regmap): New.
15135 (X86_64_NUM_ST_COLLECT_GREGS): New.
15136 (AMD64_RIP_REGNUM): New.
15137 (supply_static_tracepoint_registers): New.
15138 * linux-i386-ipa.c [HAVE_UST]: Include ust/processor.h
15139 (ST_REGENTRY): New.
15140 (i386_st_collect_regmap): New.
15141 (i386_NUM_ST_COLLECT_GREGS): New.
15142 (supply_static_tracepoint_registers): New.
15143 * server.c (handle_query): Handle qXfer:statictrace:read.
15144 <qSupported>: Report support for StaticTracepoints, and
15145 qXfer:statictrace:read features.
15146 * server.h (traceframe_read_sdata)
15147 (supply_static_tracepoint_registers): Declare.
15148 * remote-utils.c (convert_int_to_ascii, hexchars, ishex, tohex)
15149 (unpack_varlen_hex): Include in IPA build.
15150 * Makefile.in (ustlibs, ustinc): New.
15151 (IPA_OBJS): Add remote-utils-ipa.o.
15152 ($(IPA_LIB)): Link -ldl and -lpthread.
15153 (UST_CFLAGS): New.
15154 (IPAGENT_CFLAGS): Add UST_CFLAGS.
15155 * config.in, configure: Regenerate.
15156
15157 2010-06-20 Ian Lance Taylor <iant@google.com>
15158 Pedro Alves <pedro@codesourcery.com>
15159
15160 * linux-x86-low.c (always_true): Delete.
15161 (EMIT_ASM, EMIT_ASM32): Use an uncondition asm jmp instead of
15162 trying to fool the compiler with always_true.
15163
15164 2010-06-20 Pedro Alves <pedro@codesourcery.com>
15165
15166 * tracepoint.c (condition_true_at_tracepoint): Don't run compiled
15167 conditions in gdbserver.
15168
15169 2010-06-19 Ulrich Weigand <uweigand@de.ibm.com>
15170
15171 * spu-low.c (spu_read_memory): Wrap around local store limit.
15172 (spu_write_memory): Likewise.
15173
15174 2010-06-15 Pedro Alves <pedro@codesourcery.com>
15175
15176 * linux-x86-low.c (amd64_emit_const, amd64_emit_void_call_2)
15177 (i386_emit_const, i386_emit_void_call_2): Replace int64_t uses with
15178 LONGEST uses.
15179 * server.h (struct emit_ops): Replace int64_t uses with LONGEST
15180 uses.
15181 * tracepoint.c (emit_const, emit_void_call_2): Replace int64_t
15182 uses with LONGEST uses.
15183
15184 2010-06-14 Stan Shebs <stan@codesourcery.com>
15185 Pedro Alves <pedro@codesourcery.com>
15186
15187 Bytecode compiler.
15188
15189 * linux-x86-low.c: Include limits.h.
15190 (add_insns): New.
15191 (always_true): New.
15192 (EMIT_ASM): New.
15193 (EMIT_ASM32): New.
15194 (amd64_emit_prologue, amd64_emit_epilogue, amd64_emit_add)
15195 (amd64_emit_sub, amd64_emit_mul, amd64_emit_lsh)
15196 (amd64_emit_rsh_signed, amd64_emit_rsh_unsigned, amd64_emit_ext,
15197 (amd64_emit_log_not, amd64_emit_bit_and, amd64_emit_bit_or)
15198 (amd64_emit_bit_xor, amd64_emit_bit_not, amd64_emit_equal,
15199 (amd64_emit_less_signed, amd64_emit_less_unsigned, amd64_emit_ref,
15200 (amd64_emit_if_goto, amd64_emit_goto, amd64_write_goto_address)
15201 (amd64_emit_const, amd64_emit_call, amd64_emit_reg)
15202 (amd64_emit_pop, amd64_emit_stack_flush, amd64_emit_zero_ext)
15203 (amd64_emit_swap, amd64_emit_stack_adjust, amd64_emit_int_call_1)
15204 (amd64_emit_void_call_2): New.
15205 (amd64_emit_ops): New.
15206 (i386_emit_prologue, i386_emit_epilogue, i386_emit_add)
15207 (i386_emit_sub,i386_emit_mul, i386_emit_lsh, i386_emit_rsh_signed)
15208 (i386_emit_rsh_unsigned, i386_emit_ext, i386_emit_log_not)
15209 (i386_emit_bit_and, i386_emit_bit_or, i386_emit_bit_xor)
15210 (i386_emit_bit_not, i386_emit_equal, i386_emit_less_signed)
15211 (i386_emit_less_unsigned, i386_emit_ref, i386_emit_if_goto)
15212 (i386_emit_goto, i386_write_goto_address, i386_emit_const)
15213 (i386_emit_call, i386_emit_reg, i386_emit_pop)
15214 (i386_emit_stack_flush, i386_emit_zero_ext, i386_emit_swap)
15215 (i386_emit_stack_adjust, i386_emit_int_call_1)
15216 (i386_emit_void_call_2): New.
15217 (i386_emit_ops): New.
15218 (x86_emit_ops): New.
15219 (the_low_target): Install x86_emit_ops.
15220 * server.h (struct emit_ops): New.
15221 (get_raw_reg_func_addr): Declare.
15222 (current_insn_ptr, emit_error): Declare.
15223 * tracepoint.c (get_raw_reg, get_trace_state_variable_value)
15224 (set_trace_state_variable_value): New defines.
15225 (struct ipa_sym_addresses): New fields addr_get_raw_reg,
15226 addr_get_trace_state_variable_value and
15227 addr_set_trace_state_variable_value.
15228 (symbol_list): New fields for get_raw_reg,
15229 get_trace_state_variable_value and set_trace_state_variable_value.
15230 (condfn): New typedef.
15231 (struct tracepoint): New field `compiled_cond'.
15232 (do_action_at_tracepoint): Clear compiled_cond.
15233 (get_trace_state_variable_value, set_trace_state_variable_value):
15234 Export in the IPA.
15235 (condition_true_at_tracepoint): If there's a compiled condition,
15236 run that.
15237 (current_insn_ptr, emit_error): New globals.
15238 (struct bytecode_address): New.
15239 (get_raw_reg_func_addr): New.
15240 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul)
15241 (emit_lsh, emit_rsh_signed, emit_rsh_unsigned, emit_ext)
15242 (emit_log_not, emit_bit_and, emit_bit_or, emit_bit_xor)
15243 (emit_bit_not, emit_equal, emit_less_signed, emit_less_unsigned)
15244 (emit_ref, emit_if_goto, emit_goto, write_goto_address, emit_const)
15245 (emit_reg, emit_pop, emit_stack_flush, emit_zero_ext, emit_swap)
15246 (emit_stack_adjust, emit_int_call_1, emit_void_call_2): New.
15247 (compile_tracepoint_condition, compile_bytecodes): New.
15248 * target.h (emit_ops): Forward declare.
15249 (struct target_ops): New field emit_ops.
15250 (target_emit_ops): New.
15251 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): New.
15252 * linux-i386-ipa.c (gdb_agent_get_raw_reg): New.
15253 * linux-low.c (linux_emit_ops): New.
15254 (linux_target_ops): Install it.
15255 * linux-low.h (struct linux_target_ops): New field emit_ops.
15256
15257 2010-06-14 Ulrich Weigand <uweigand@de.ibm.com>
15258
15259 * linux-ppc-low.c (ppc_arch_setup): Use private regcache to test MSR.
15260 * linux-s390-low.c (ppc_arch_setup): Use private regcache to test PSW.
15261
15262 2010-06-01 Pedro Alves <pedro@codesourcery.com>
15263 Stan Shebs <stan@codesourcery.com>
15264
15265 * Makefile.in (IPA_DEPFILES, extra_libraries): New.
15266 (all): Depend on $(extra_libraries).
15267 (install-only): Install the IPA.
15268 (IPA_OBJS, IPA_LIB): New.
15269 (clean): Remove the IPA lib.
15270 (IPAGENT_CFLAGS): New.
15271 (tracepoint-ipa.o, utils-ipa.o, remote-utils-ipa.o)
15272 (regcache-ipa.o, i386-linux-ipa.o, linux-i386-ipa.o)
15273 (linux-amd64-ipa.o, amd64-linux-ipa.o): New rules.
15274 * linux-amd64-ipa.c, linux-i386-ipa.c: New files.
15275 * configure.ac: Check for atomic builtins support in the compiler.
15276 (IPA_DEPFILES, extra_libraries): Define.
15277 * configure.srv (ipa_obj): Add description.
15278 (ipa_i386_linux_regobj, ipa_amd64_linux_regobj): Define.
15279 (i[34567]86-*-linux*): Set ipa_obj.
15280 (x86_64-*-linux*): Set ipa_obj.
15281 * linux-low.c (stabilizing_threads): New.
15282 (supports_fast_tracepoints): New.
15283 (linux_detach): Stabilize threads before detaching.
15284 (handle_tracepoints): Handle internal tracing breakpoints. Assert
15285 the lwp is either not stabilizing, or is moving out of a jump pad.
15286 (linux_fast_tracepoint_collecting): New.
15287 (maybe_move_out_of_jump_pad): New.
15288 (enqueue_one_deferred_signal): New.
15289 (dequeue_one_deferred_signal): New.
15290 (linux_wait_for_event_1): If moving out of a jump pad, defer
15291 pending signals to later.
15292 (linux_stabilize_threads): New.
15293 (linux_wait_1): Check if threads need moving out of jump pads, and
15294 do it if so.
15295 (stuck_in_jump_pad_callback): New.
15296 (move_out_of_jump_pad_callback): New.
15297 (lwp_running): New.
15298 (linux_resume_one_lwp): Handle moving out of jump pads.
15299 (linux_set_resume_request): Dequeue deferred signals.
15300 (need_step_over_p): Also step over fast tracepoint jumps.
15301 (start_step_over): Also uninsert fast tracepoint jumps.
15302 (finish_step_over): Also reinsert fast tracepoint jumps.
15303 (linux_install_fast_tracepoint_jump): New.
15304 (linux_target_ops): Install linux_stabilize_threads and
15305 linux_install_fast_tracepoint_jump_pad.
15306 * linux-low.h (linux_target_ops) <get_thread_area,
15307 install_fast_tracepoint_jump_pad>: New fields.
15308 (struct lwp_info) <collecting_fast_tracepoint,
15309 pending_signals_to_report, exit_jump_pad_bkpt>: New fields.
15310 (linux_get_thread_area): Declare.
15311 * linux-x86-low.c (jump_insn): New.
15312 (x86_get_thread_area): New.
15313 (append_insns): New.
15314 (push_opcode): New.
15315 (amd64_install_fast_tracepoint_jump_pad): New.
15316 (i386_install_fast_tracepoint_jump_pad): New.
15317 (x86_install_fast_tracepoint_jump_pad): New.
15318 (the_low_target): Install x86_get_thread_area and
15319 x86_install_fast_tracepoint_jump_pad.
15320 * mem-break.c (set_raw_breakpoint_at): Use read_inferior_memory.
15321 (struct fast_tracepoint_jump): New.
15322 (fast_tracepoint_jump_insn): New.
15323 (fast_tracepoint_jump_shadow): New.
15324 (find_fast_tracepoint_jump_at): New.
15325 (fast_tracepoint_jump_here): New.
15326 (delete_fast_tracepoint_jump): New.
15327 (set_fast_tracepoint_jump): New.
15328 (uninsert_fast_tracepoint_jumps_at): New.
15329 (reinsert_fast_tracepoint_jumps_at): New.
15330 (set_breakpoint_at): Use write_inferior_memory.
15331 (uninsert_raw_breakpoint): Use write_inferior_memory.
15332 (check_mem_read): Mask out fast tracepoint jumps.
15333 (check_mem_write): Mask out fast tracepoint jumps.
15334 * mem-break.h (struct fast_tracepoint_jump): Forward declare.
15335 (set_fast_tracepoint_jump): Declare.
15336 (delete_fast_tracepoint_jump)
15337 (fast_tracepoint_jump_here, uninsert_fast_tracepoint_jumps_at)
15338 (reinsert_fast_tracepoint_jumps_at): Declare.
15339 * regcache.c: Don't compile many functions when building the
15340 in-process agent library.
15341 (init_register_cache) [IN_PROCESS_AGENT]: Don't allow allocating
15342 the register buffer in the heap.
15343 (free_register_cache): If the register buffer isn't owned by the
15344 regcache, don't free it.
15345 (set_register_cache) [IN_PROCESS_AGENT]: Don't re-alocate
15346 pre-existing register caches.
15347 * remote-utils.c (convert_int_to_ascii): Constify `from' parameter
15348 type.
15349 (convert_ascii_to_int): : Constify `from' parameter type.
15350 (decode_M_packet, decode_X_packet): Replace the `to' parameter by
15351 a `to_p' pointer to pointer parameter. If TO_P is NULL, malloc
15352 the needed buffer in-place.
15353 (relocate_instruction): New.
15354 * server.c (handle_query) <qSymbols>: If the target supports
15355 tracepoints, give it a chance of looking up symbols. Report
15356 support for fast tracepoints.
15357 (handle_status): Stabilize threads.
15358 (process_serial_event): Adjust.
15359 * server.h (struct fast_tracepoint_jump): Forward declare.
15360 (struct process_info) <fast_tracepoint_jumps>: New field.
15361 (convert_ascii_to_int, convert_int_to_ascii): Adjust.
15362 (decode_X_packet, decode_M_packet): Adjust.
15363 (relocate_instruction): Declare.
15364 (in_process_agent_loaded): Declare.
15365 (tracepoint_look_up_symbols): Declare.
15366 (struct fast_tpoint_collect_status): Declare.
15367 (fast_tracepoint_collecting): Declare.
15368 (force_unlock_trace_buffer): Declare.
15369 (handle_tracepoint_bkpts): Declare.
15370 (initialize_low_tracepoint)
15371 (supply_fast_tracepoint_registers) [IN_PROCESS_AGENT]: Declare.
15372 * target.h (struct target_ops) <stabilize_threads,
15373 install_fast_tracepoint_jump_pad>: New fields.
15374 (stabilize_threads, install_fast_tracepoint_jump_pad): New.
15375 * tracepoint.c [HAVE_MALLOC_H]: Include malloc.h.
15376 [HAVE_STDINT_H]: Include stdint.h.
15377 (trace_debug_1): Rename to ...
15378 (trace_vdebug): ... this.
15379 (trace_debug): Rename to ...
15380 (trace_debug_1): ... this. Add `level' parameter.
15381 (trace_debug): New.
15382 (ATTR_USED, ATTR_NOINLINE): New.
15383 (IP_AGENT_EXPORT): New.
15384 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
15385 (collecting, gdb_collect, stop_tracing, flush_trace_buffer)
15386 (about_to_request_buffer_space, trace_buffer_is_full)
15387 (stopping_tracepoint, expr_eval_result, error_tracepoint)
15388 (tracepoints, tracing, trace_buffer_ctrl, trace_buffer_ctrl_curr)
15389 (trace_buffer_lo, trace_buffer_hi, traceframe_read_count)
15390 (traceframe_write_count, traceframes_created)
15391 (trace_state_variables)
15392 New renaming defines.
15393 (struct ipa_sym_addresses): New.
15394 (STRINGIZE_1, STRINGIZE, IPA_SYM): New.
15395 (symbol_list): New.
15396 (ipa_sym_addrs): New.
15397 (all_tracepoint_symbols_looked_up): New.
15398 (in_process_agent_loaded): New.
15399 (write_e_ipa_not_loaded): New.
15400 (maybe_write_ipa_not_loaded): New.
15401 (tracepoint_look_up_symbols): New.
15402 (debug_threads) [IN_PROCESS_AGENT]: New.
15403 (read_inferior_memory) [IN_PROCESS_AGENT]: New.
15404 (UNKNOWN_SIDE_EFFECTS): New.
15405 (stop_tracing): New.
15406 (flush_trace_buffer): New.
15407 (stop_tracing_bkpt): New.
15408 (flush_trace_buffer_bkpt): New.
15409 (read_inferior_integer): New.
15410 (read_inferior_uinteger): New.
15411 (read_inferior_data_pointer): New.
15412 (write_inferior_data_pointer): New.
15413 (write_inferior_integer): New.
15414 (write_inferior_uinteger): New.
15415 (struct collect_static_trace_data_action): Delete.
15416 (enum tracepoint_type): New.
15417 (struct tracepoint) <type>: New field `type'.
15418 <actions_str, step_actions, step_actions_str>: Only include in
15419 GDBserver.
15420 <orig_size, obj_addr_on_target, adjusted_insn_addr>
15421 <adjusted_insn_addr_end, jump_pad, jump_pad_end>: New fields.
15422 (tracepoints): Use IP_AGENT_EXPORT.
15423 (last_tracepoint): Don't include in the IPA.
15424 (stopping_tracepoint): Use IP_AGENT_EXPORT.
15425 (trace_buffer_is_full): Use IP_AGENT_EXPORT.
15426 (alloced_trace_state_variables): New.
15427 (trace_state_variables): Use IP_AGENT_EXPORT.
15428 (traceframe_t): Delete unused variable.
15429 (circular_trace_buffer): Don't include in the IPA.
15430 (trace_buffer_start): Delete.
15431 (struct trace_buffer_control): New.
15432 (trace_buffer_free): Delete.
15433 (struct ipa_trace_buffer_control): New.
15434 (GDBSERVER_FLUSH_COUNT_MASK, GDBSERVER_FLUSH_COUNT_MASK_PREV)
15435 (GDBSERVER_FLUSH_COUNT_MASK_CURR, GDBSERVER_UPDATED_FLUSH_COUNT_BIT):
15436 New.
15437 (trace_buffer_ctrl): New.
15438 (TRACE_BUFFER_CTRL_CURR): New.
15439 (trace_buffer_start, trace_buffer_free, trace_buffer_end_free):
15440 Reimplement as macros.
15441 (trace_buffer_wrap): Delete.
15442 (traceframe_write_count, traceframe_read_count)
15443 (traceframes_created, tracing): Use IP_AGENT_EXPORT.
15444 (struct tracepoint_hit_ctx) <type>: New field.
15445 (struct fast_tracepoint_ctx): New.
15446 (memory_barrier): New.
15447 (cmpxchg): New.
15448 (record_tracepoint_error): Update atomically in the IPA.
15449 (clear_inferior_trace_buffer): New.
15450 (about_to_request_buffer_space): New.
15451 (trace_buffer_alloc): Handle GDBserver and inferior simulatenous
15452 updating the same buffer.
15453 (add_tracepoint): Default the tracepoint's type to trap
15454 tracepoint, and orig_size to -1.
15455 (get_trace_state_variable) [IN_PROCESS_AGENT]: Handle allocated
15456 internal variables.
15457 (create_trace_state_variable): New parameter `gdb'. Handle it.
15458 (clear_installed_tracepoints): Clear fast tracepoint jumps.
15459 (cmd_qtdp): Handle fast tracepoints.
15460 (cmd_qtdv): Adjust.
15461 (max_jump_pad_size): New.
15462 (gdb_jump_pad_head): New.
15463 (get_jump_space_head): New.
15464 (claim_jump_space): New.
15465 (sort_tracepoints): New.
15466 (MAX_JUMP_SIZE): New.
15467 (cmd_qtstart): Handle fast tracepoints. Sync tracepoints with the
15468 IPA.
15469 (stop_tracing) [IN_PROCESS_AGENT]: Don't include the tdisconnected
15470 support. Upload fast traceframes, and delete internal IPA
15471 breakpoints.
15472 (stop_tracing_handler): New.
15473 (flush_trace_buffer_handler): New.
15474 (cmd_qtstop): Upload fast tracepoints.
15475 (response_tracepoint): Handle fast tracepoints.
15476 (tracepoint_finished_step): Upload fast traceframes. Set the
15477 tracepoint hit context's tracepoint type.
15478 (handle_tracepoint_bkpts): New.
15479 (tracepoint_was_hit): Set the tracepoint hit context's tracepoint
15480 type. Add comment about fast tracepoints.
15481 (collect_data_at_tracepoint) [IN_PROCESS_AGENT]: Don't access the
15482 non-existing action_str field.
15483 (get_context_regcache): Handle fast tracepoints.
15484 (do_action_at_tracepoint) [!IN_PROCESS_AGENT]: Don't write the PC
15485 to the regcache.
15486 (fast_tracepoint_from_jump_pad_address): New.
15487 (fast_tracepoint_from_ipa_tpoint_address): New.
15488 (collecting_t): New.
15489 (force_unlock_trace_buffer): New.
15490 (fast_tracepoint_collecting): New.
15491 (collecting): New.
15492 (gdb_collect): New.
15493 (write_inferior_data_ptr): New.
15494 (target_tp_heap): New.
15495 (target_malloc): New.
15496 (download_agent_expr): New.
15497 (UALIGN): New.
15498 (download_tracepoints): New.
15499 (download_trace_state_variables): New.
15500 (upload_fast_traceframes): New.
15501 (IPA_FIRST_TRACEFRAME): New.
15502 (IPA_NEXT_TRACEFRAME_1): New.
15503 (IPA_NEXT_TRACEFRAME): New.
15504 [IN_PROCESS_AGENT]: Include sys/mman.h and fcntl.h.
15505 [IN_PROCESS_AGENT] (gdb_tp_heap_buffer, gdb_jump_pad_buffer)
15506 (gdb_jump_pad_buffer_end): New.
15507 [IN_PROCESS_AGENT] (initialize_tracepoint_ftlib): New.
15508 (initialize_tracepoint): Adjust.
15509 [IN_PROCESS_AGENT]: Allocate the IPA heap, and jump pad scratch
15510 buffer. Initialize the low module.
15511 * utils.c (PREFIX, TOOLNAME): New.
15512 (malloc_failure): Use PREFIX.
15513 (error): In the IPA, an error causes an exit.
15514 (fatal, warning): Use PREFIX.
15515 (internal_error): Use TOOLNAME.
15516 (NUMCELLS): Increase to 10.
15517 * configure, config.in: Regenerate.
15518
15519 2010-06-01 Pedro Alves <pedro@codesourcery.com>
15520
15521 * server.c (handle_query) <qSupported>: Do two passes over the
15522 qSupported string to avoid nesting strtok.
15523
15524 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
15525
15526 * Makefile.in (SFILES): Add $(srcdir)/proc-service.list.
15527 (CDEPS): New.
15528 * configure.ac (RDYNAMIC): New AC_MSG_CHECKING wrapping. Test also
15529 -Wl,--dynamic-list.
15530 * configure: Regenerate.
15531 * proc-service.list: New.
15532
15533 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
15534
15535 * linux-low.c (linux_core_of_thread): Fix crash on invalid CONTENT.
15536 New comment.
15537
15538 2010-05-26 Ozkan Sezer <sezeroz@gmail.com>
15539
15540 * gdbreplay.c (remote_open): Check error return from socket() call by
15541 its equality to -1 not by it being negative.
15542 * remote-utils.c (remote_open): Likewise.
15543
15544 2010-05-23 Pedro Alves <pedro@codesourcery.com>
15545
15546 * config.h: Regenerate.
15547
15548 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
15549
15550 * linux-m68k-low.c (ps_get_thread_area): Don't define if kernel
15551 doesn't provide PTRACE_GET_THREAD_AREA.
15552
15553 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
15554
15555 * linux-m68k-low.c: Include <asm/ptrace.h>
15556 (ps_get_thread_area): Implement.
15557
15558 2010-05-03 Doug Evans <dje@google.com>
15559
15560 * event-loop.c (struct callback_event): New struct.
15561 (callback_list): New global.
15562 (append_callback_event, delete_callback_event): New functions.
15563 (process_callback): New function.
15564 (start_event_loop): Call it.
15565 * remote-utils.c (NOT_SCHEDULED): Define.
15566 (readchar_buf, readchar_bufcnt, readchar_bufp): New static globals,
15567 moved out of readchar.
15568 (readchar): Rewrite. Call reschedule before returning.
15569 (reset_readchar): New function.
15570 (remote_close): Call it.
15571 (process_remaining, reschedule): New functions.
15572 * server.h (callback_handler_func): New typedef.
15573 (append_callback_event, delete_callback_event): Declare.
15574
15575 2010-05-03 Pedro Alves <pedro@codesourcery.com>
15576
15577 * proc-service.c (ps_pglobal_lookup): Use
15578 thread_db_look_up_one_symbol.
15579 * remote-utils.c (look_up_one_symbol): Add new `may_ask_gdb'
15580 parameter. Use it instead of all_symbols_looked_up.
15581 * server.h (struct process_info) <all_symbols_looked_up>: Delete
15582 field.
15583 (all_symbols_looked_up): Don't declare.
15584 (look_up_one_symbol): Add new `may_ask_gdb' parameter.
15585 * thread-db.c (struct thread_db) <all_symbols_looked_up>: New
15586 field.
15587 (thread_db_look_up_symbols): Adjust call to look_up_one_symbol.
15588 Set all_symbols_looked_up here.
15589 (thread_db_look_up_one_symbol): New.
15590 (thread_db_get_tls_address): Adjust.
15591 (thread_db_load_search, try_thread_db_load_1): Always allocate the
15592 thread_db object on the heap, and tentatively set it in the
15593 process structure.
15594 (thread_db_init): Don't set all_symbols_looked_up here.
15595 * linux-low.h (thread_db_look_up_one_symbol): Declare.
15596
15597 2010-05-03 Pedro Alves <pedro@codesourcery.com>
15598
15599 * linux-low.c (linux_kill, linux_detach): Adjust.
15600 (status_pending_p_callback): Remove redundant statement. Check
15601 for !TARGET_WAITIKIND_IGNORE, instead of
15602 TARGET_WAITKIND_STOPPED.
15603 (handle_tracepoints): Make sure LWP is locked. Adjust.
15604 (linux_wait_for_event_1): Adjust.
15605 (linux_cancel_breakpoints): New.
15606 (unsuspend_one_lwp): New.
15607 (unsuspend_all_lwps): New.
15608 (linux_wait_1): If finishing a step-over, unsuspend all lwps.
15609 (send_sigstop_callback): Change return type to int, add new
15610 `except' parameter and handle it.
15611 (suspend_and_send_sigstop_callback): New.
15612 (stop_all_lwps): Add new `suspend' and `expect' parameters, and
15613 pass them down. If SUSPEND, also increment the lwp's suspend
15614 count.
15615 (linux_resume_one_lwp): Add notice about resuming a suspended LWP.
15616 (need_step_over_p): Don't consider suspended LWPs.
15617 (start_step_over): Adjust.
15618 (proceed_one_lwp): Change return type to int, add new `except'
15619 parameter and handle it.
15620 (unsuspend_and_proceed_one_lwp): New.
15621 (proceed_all_lwps): Use find_inferior instead of
15622 for_each_inferior.
15623 (unstop_all_lwps): Add `unsuspend' parameter. If UNSUSPEND, them
15624 also decrement the suspend count of LWPs. Pass `except' down,
15625 instead of hacking its suspend count.
15626 (linux_pause_all): Add `freeze' parameter. Adjust.
15627 (linux_unpause_all): New.
15628 (linux_target_ops): Install linux_unpause_all.
15629 * server.c (handle_status): Adjust.
15630 * target.h (struct target_ops): New fields `unpause_all' and
15631 `cancel_breakpoints'. Add new parameter to `pause_all'.
15632 (pause_all): Add new `freeze' parameter.
15633 (unpause_all): New.
15634 (cancel_breakpoints): New.
15635 * tracepoint.c (clear_installed_tracepoints): Pause threads, and
15636 cancel breakpoints.
15637 (cmd_qtstart): Pause threads.
15638 (stop_tracing): Pause threads, and cancel breakpoints.
15639 * win32-low.c (win32_target_ops): Adjust.
15640
15641 2010-05-03 Pedro Alves <pedro@codesourcery.com>
15642
15643 * linux-low.c (linux_wait_for_event_1): Move passing the signal to
15644 the inferior right away from here...
15645 (linux_wait_1): ... to here, and adjust to check the thread's
15646 last_resume_kind instead of the lwp's step or stop_expected flags.
15647
15648 2010-05-02 Pedro Alves <pedro@codesourcery.com>
15649
15650 * README: Use consistent `GDB' and `GDBserver' spellings.
15651
15652 2010-05-02 Pedro Alves <pedro@codesourcery.com>
15653
15654 * linux-low.c (linux_kill_one_lwp): Assume the lwp is stopped.
15655 (linux_kill): Stop all lwps here. Don't delete the main lwp here.
15656 (linux_detach_one_lwp): Assume the lwp is stopped.
15657 (any_thread_of): Delete.
15658 (linux_detach): Stop all lwps here. Don't blindly delete all
15659 breakpoints.
15660 (delete_lwp_callback): New.
15661 (linux_mourn): Delete all lwps of the process that is gone.
15662 (linux_wait_1): Don't delete the last lwp of the process here.
15663 * mem-break.h (mark_breakpoints_out): Declare.
15664 * mem-break.c (mark_breakpoints_out): New.
15665 (free_all_breakpoints): Use it.
15666 * server.c (handle_target_event): If the process is gone, mark
15667 breakpoints out.
15668 * thread-db.c (struct thread_db) <create_bp>: New field.
15669 (thread_db_enable_reporting): Fix prototype. Store a thread event
15670 breakpoint reference in the thread_db struct.
15671 (thread_db_load_search): Clear the thread_db object.
15672 (try_thread_db_load_1): Ditto.
15673 (switch_to_process): New.
15674 (disable_thread_event_reporting): Use it.
15675 (remove_thread_event_breakpoints): New.
15676 (thread_db_detach, thread_db_mourn): Use it.
15677
15678 2010-05-01 Pedro Alves <pedro@codesourcery.com>
15679
15680 * linux-low.c (linux_enable_event_reporting): New.
15681 (linux_wait_for_event_1, handle_extended_wait): Use it.
15682
15683 2010-04-30 Pedro Alves <pedro@codesourcery.com>
15684
15685 * linux-low.c (linux_kill_one_lwp, linux_kill)
15686 (linux_detach_one_lwp): Adjust to send_sigstop interface change.
15687 (send_sigstop): Take an lwp_info as parameter instead. Queue a
15688 SIGSTOP even if the LWP is stopped.
15689 (send_sigstop_callback): New.
15690 (stop_all_lwps): Use send_sigstop_callback instead.
15691 (linux_resume_one_thread): Adjust.
15692 (proceed_one_lwp): Still proceed an LWP that the client has
15693 requested to stop, if we haven't reported it as stopped yet. Make
15694 sure that LWPs the client want stopped, have a pending SIGSTOP.
15695
15696 2010-04-26 Doug Evans <dje@google.com>
15697
15698 * server.c (handle_general_set): Make static.
15699
15700 * remote-utils.c (putpkt_binary_1): Call readchar instead of read.
15701 Print received char after testing for error/eof instead of before.
15702 (input_interrupt): Tweak comment.
15703
15704 2010-04-23 Doug Evans <dje@google.com>
15705
15706 * server.c (start_inferior): Print inferior argv if --debug.
15707
15708 2010-04-21 Aleksandar Ristovski <aristovski@qnx.com>
15709
15710 * Makefile.in (nto_low_h nto-low.o nto-x86-low.o): New dependency lists.
15711 * nto-x86-low.c: Include server.h
15712
15713 2010-04-20 Pierre Muller <muller@ics.u-strasbg.fr>
15714
15715 * win32-i386-low.c: Use __x86_64__ macro instead of __x86_64 to
15716 be consistent with other sources of this directory.
15717 (init_registers_amd64): Correct name of source file of this function
15718 in the comment.
15719
15720 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
15721
15722 * configure.srv (x86_64-*-mingw*): New configuration for Windows
15723 64-bit executables.
15724
15725 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
15726
15727 * win32-i386-low.c: Add 64-bit support.
15728 (CONTEXT_EXTENDED_REGISTERS): Set macro to zero if not exisiting.
15729 (init_registers_amd64): Declare.
15730 (mappings): Add 64-bit version of array.
15731 (init_windows_x86): New function.
15732 (the_low_target): Change init_arch field to init_windows_x86.
15733
15734 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
15735
15736 * win32-low.c: Adapt to support also 64-bit architecture.
15737 (child_xfer_memory): Use uintptr_t type for local variable `addr'.
15738 (get_image_name): Use SIZE_T type for local variable `done'.
15739 (psapi_get_dll_name): Use LPVOID type for parameter `BaseAddress'.
15740 (toolhelp_get_dll_name): Idem.
15741 (handle_load_dll): Use CORE_ADDR type for local variable `load_addr'.
15742 Use uintptr_t typecast to avoid warning.
15743 (handle_unload_dll): Use uintptr_t typecast to avoid warning.
15744 (handle_exception): Use phex_nz to avoid warning.
15745 (win32_wait): Remove unused local variable `process'.
15746
15747 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
15748
15749 * configure.srv (srv_amd64_regobj): Replace `x86-64-avx.o' by
15750 `amd64-avx.o'.
15751
15752 2010-04-17 Pierre Muller <muller@ics.u-strasbg.fr>
15753
15754 * configure.ac: Use `ws2_32' library for srv_mingw.
15755 * configure: Regenerate.
15756 * gdbreplay.c: Include winsock2.h instead of winsock.h.
15757 * remote-utils.c: Likewise.
15758
15759 2010-04-17 H.J. Lu <hongjiu.lu@intel.com>
15760
15761 * linux-x86-low.c (xmltarget_amd64_linux_no_xml): Define only
15762 if __x86_64__ is defined.
15763
15764 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
15765
15766 * configure: Regenerate.
15767
15768 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
15769
15770 * server.c (handle_query): Handle 'qGetTIBAddr' query.
15771 * target.h (target_ops): New get_tib_address field.
15772 * win32-low.h (win32_thread_info): Add thread_local_base field.
15773 * win32-low.c (child_add_thread): Add tlb argument.
15774 Set thread_local_base field to TLB.
15775 (get_child_debug_event): Adapt to child_add_thread change.
15776 (win32_get_tib_address): New function.
15777 (win32_target_ops): Set get_tib_address field to
15778 win32_get_tib_address.
15779 * linux-low.c (linux_target_ops): Set get_tib_address field to NULL.
15780
15781 2010-04-12 Pedro Alves <pedro@codesourcery.com>
15782
15783 * linux-low.c (linux_mourn): Also remove the process.
15784 * server.c (handle_target_event): Don't remove the process here.
15785 * nto-low.c (nto_mourn): New.
15786 (nto_target_ops): Install it.
15787 * spu-low.c (spu_mourn): New.
15788 (spu_target_ops): Install it.
15789 * win32-low.c (win32_mourn): New.
15790 (win32_target_ops): Install it.
15791
15792 2010-04-12 Pedro Alves <pedro@codesourcery.com>
15793
15794 * server.h (buffer_xml_printf): Remove redundant `;'.
15795
15796 2010-04-12 Pedro Alves <pedro@codesourcery.com>
15797
15798 * regcache.c (set_register_cache): Invalidate regcaches before
15799 changing the register cache layout.
15800 (regcache_invalidate_one): Allow a NULL regcache.
15801 * linux-x86-low.c (x86_linux_update_xmltarget): Invalidate
15802 regcaches before changing the register cache layout or the target
15803 regsets.
15804
15805 2010-04-12 H.J. Lu <hongjiu.lu@intel.com>
15806
15807 * linux-x86-low.c (x86_linux_update_xmltarget): Avoid unused
15808 variable warning on Linux/x86-64.
15809
15810 2010-04-11 Pedro Alves <pedro@codesourcery.com>
15811
15812 GDBserver disconnected tracing support.
15813
15814 * linux-low.c (linux_remove_process): Delete.
15815 (add_lwp): Don't set last_resume_kind here.
15816 (linux_kill): Use `mourn'.
15817 (linux_detach): Use `thread_db_detach', and `mourn'.
15818 (linux_mourn): New.
15819 (linux_attach_lwp_1): Adjust comment.
15820 (linux_attach): last_resume_kind moved the thread_info; adjust.
15821 (status_pending_p_callback): Adjust.
15822 (linux_wait_for_event_1): Adjust.
15823 (count_events_callback, select_singlestep_lwp_callback)
15824 (select_event_lwp_callback, cancel_breakpoints_callback)
15825 (db_wants_lwp_stopped, linux_wait_1, need_step_over_p)
15826 (proceed_one_lwp): Adjust.
15827 (linux_async): Add debug output.
15828 (linux_thread_stopped): New.
15829 (linux_pause_all): New.
15830 (linux_target_ops): Install linux_mourn, linux_thread_stopped and
15831 linux_pause_all.
15832 * linux-low.h (struct lwp_info): Delete last_resume_kind field.
15833 (thread_db_free): Delete declaration.
15834 (thread_db_detach, thread_db_mourn): Declare.
15835 * thread-db.c (thread_db_init): Use thread_db_mourn.
15836 (thread_db_free): Delete, split in two.
15837 (disable_thread_event_reporting): New.
15838 (thread_db_detach): New.
15839 (thread_db_mourn): New.
15840
15841 * server.h (struct thread_info) <last_resume_kind>: New field.
15842 <attached>: Add comment.
15843 <gdb_detached>: New field.
15844 (handler_func): Change return type to int.
15845 (handle_serial_event, handle_target_event): Ditto.
15846 (gdb_connected): Declare.
15847 (tracing): Delete.
15848 (disconnected_tracing): Declare.
15849 (stop_tracing): Declare.
15850
15851 * server.c (handle_query) <qSupported>: Report support for
15852 disconnected tracing.
15853 (queue_stop_reply_callback): Account for running threads.
15854 (gdb_wants_thread_stopped): New.
15855 (gdb_wants_all_threads_stopped): New.
15856 (gdb_reattached_process): New.
15857 (handle_status): Clear the `gdb_detached' flag of all processes.
15858 In all-stop, stop all threads.
15859 (main): Be sure to leave tfind mode. Handle disconnected tracing.
15860 (process_serial_event): If the remote connection breaks, or if an
15861 exit was forced with "monitor exit", force an event loop exit.
15862 Handle disconnected tracing on detach.
15863 (handle_serial_event): Adjust.
15864 (handle_target_event): If GDB isn't connected, forward events back
15865 to the inferior, unless the last process exited, in which case,
15866 exit gdbserver. Adjust interface.
15867
15868 * remote-utils.c (remote_open): Don't block in accept. Instead
15869 register an event loop source on the listen socket file
15870 descriptor. Refactor bits into ...
15871 (listen_desc): ... this new global.
15872 (gdb_connected): ... this new function.
15873 (enable_async_notification): ... this new function.
15874 (handle_accept_event): ... this new function.
15875 (remote_close): Clear remote_desc.
15876
15877 * inferiors.c (add_thread): Set the new thread's last_resume_kind.
15878
15879 * target.h (struct target_ops) <mourn, thread_stopped, pause_all>:
15880 New fields.
15881 (mourn_inferior): Define.
15882 (target_process_qsupported): Avoid the dangling else problem.
15883 (thread_stopped): Define.
15884 (pause_all): Define.
15885 (target_waitstatus_to_string): Declare.
15886 * target.c (target_waitstatus_to_string): New.
15887
15888 * tracepoint.c (tracing): Make extern.
15889 (disconnected_tracing): New.
15890 (stop_tracing): Make extern. Handle tracing stops due to GDB
15891 disconnecting.
15892 (cmd_qtdisconnected): New.
15893 (cmd_qtstatus): Report disconnected tracing status in trace reply.
15894 (handle_tracepoint_general_set): Handle QTDisconnected.
15895
15896 * event-loop.c (event_handler_func): Change return type to int.
15897 (process_event): Bail out if the event handler wants the event
15898 loop to stop.
15899 (handle_file_event): Ditto.
15900 (start_event_loop): Bail out if the event handler wants the event
15901 loop to stop.
15902
15903 * nto-low.c (nto_target_ops): Adjust.
15904 * spu-low.c (spu_wait): Don't remove the process here.
15905 (spu_target_ops): Adjust.
15906 * win32-low.c (win32_wait): Don't remove the process here.
15907 (win32_target_ops): Adjust.
15908
15909 2010-04-11 Pedro Alves <pedro@codesourcery.com>
15910
15911 * regcache.c (realloc_register_cache): Invalidate inferior's
15912 regcache before recreating it.
15913
15914 2010-04-09 Pedro Alves <pedro@codesourcery.com>
15915
15916 * tracepoint.c (cmd_qtstatus): Report trace buffer circularity.
15917
15918 2010-04-09 Stan Shebs <stan@codesourcery.com>
15919 Pedro Alves <pedro@codesourcery.com>
15920
15921 * server.h (LONGEST): New.
15922 (struct thread_info) <while_stepping>: New field.
15923 (unpack_varlen_hex, xrealloc, pulongest, plongest, phex_nz):
15924 Declare.
15925 (initialize_tracepoint, handle_tracepoint_general_set)
15926 (handle_tracepoint_query, tracepoint_finished_step)
15927 (tracepoint_was_hit, release_while_stepping_state_list):
15928 (current_traceframe): Declare.
15929 * server.c (handle_general_set): Handle tracepoint packets.
15930 (read_memory): New.
15931 (write_memory): New.
15932 (handle_search_memory_1): Use read_memory.
15933 (handle_query): Report support for conditional tracepoints, trace
15934 state variables, and tracepoint sources. Handle tracepoint
15935 queries.
15936 (main): Initialize the tracepoints module.
15937 (process_serial_event): Handle traceframe reads/writes.
15938
15939 * linux-low.c (handle_tracepoints): New.
15940 (linux_wait_1): Call it.
15941 (linux_resume_one_lwp): Handle while-stepping.
15942 (linux_supports_tracepoints, linux_read_pc, linux_write_pc): New.
15943 (linux_target_ops): Install them.
15944 * linux-low.h (struct linux_target_ops) <supports_tracepoints>:
15945 New field.
15946 * linux-x86-low.c (x86_supports_tracepoints): New.
15947 (the_low_target). Install it.
15948
15949 * mem-break.h (delete_breakpoint): Declare.
15950 * mem-break.c (delete_breakpoint): Make external.
15951
15952 * target.h (struct target_ops): Add `supports_tracepoints',
15953 `read_pc', and `write_pc' fields.
15954 (target_supports_tracepoints): Define.
15955 * utils.c (xrealloc, decimal2str, pulongest, plongest, thirty_two)
15956 (phex_nz): New.
15957
15958 * regcache.h (struct regcache) <registers_owned>: New field.
15959 (init_register_cache, regcache_cpy): Declare.
15960 (regcache_read_pc, regcache_write_pc): Declare.
15961 (register_cache_size): Declare.
15962 (supply_regblock): Declare.
15963 * regcache.c (init_register_cache): New.
15964 (new_register_cache): Use it.
15965 (regcache_cpy): New.
15966 (register_cache_size): New.
15967 (supply_regblock): New.
15968 (regcache_read_pc, regcache_write_pc): New.
15969
15970 * tracepoint.c: New.
15971
15972 * Makefile.in (OBS): Add tracepoint.o.
15973 (tracepoint.o): New rule.
15974
15975 2010-04-08 H.J. Lu <hongjiu.lu@intel.com>
15976
15977 * Makefile.in (clean): Also remove i386-mmx.c i386-mmx-linux.c.
15978 (i386-mmx.o): New.
15979 (i386-mmx.c): Likewise.
15980 (i386-mmx-linux.o): Likewise.
15981 (i386-mmx-linux.c): Likewise.
15982
15983 * configure.srv (srv_i386_regobj): Add i386-mmx.o.
15984 (srv_i386_linux_regobj): Add i386-mmx-linux.o.
15985 (srv_i386_xmlfiles): Add i386/i386-mmx.xml.
15986 (srv_i386_linux_xmlfiles): Add i386/i386-mmx-linux.xml.
15987
15988 * linux-x86-low.c (init_registers_i386_mmx_linux): New.
15989 (x86_linux_update_xmltarget): Call init_registers_i386_mmx_linux
15990 and return if ptrace PTRACE_GETFPXREGS failed in 32bit.
15991
15992 2010-04-07 H.J. Lu <hongjiu.lu@intel.com>
15993
15994 * Makefile.in (clean): Updated.
15995 (i386-avx.o): New.
15996 (i386-avx.c): Likewise.
15997 (i386-avx-linux.o): Likewise.
15998 (i386-avx-linux.c): Likewise.
15999 (amd64-avx.o): Likewise.
16000 (amd64-avx.c): Likewise.
16001 (amd64-avx-linux.o): Likewise.
16002 (amd64-avx-linux.c): Likewise.
16003
16004 * configure.srv (srv_i386_regobj): Add i386-avx.o.
16005 (srv_i386_linux_regobj): Add i386-avx-linux.o.
16006 (srv_amd64_regobj): Add amd64-avx.o.
16007 (srv_amd64_linux_regobj): Add amd64-avx-linux.o.
16008 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx.xml.
16009 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx.xml.
16010 (srv_i386_xmlfiles): Add i386/i386-avx.xml.
16011 (srv_amd64_xmlfiles): Add i386/amd64-avx.xml.
16012 (srv_i386_linux_xmlfiles): Add i386/i386-avx-linux.xml.
16013 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-linux.xml.
16014
16015 * i387-fp.c: Include "i386-xstate.h".
16016 (i387_xsave): New.
16017 (i387_cache_to_xsave): Likewise.
16018 (i387_xsave_to_cache): Likewise.
16019 (x86_xcr0): Likewise.
16020
16021 * i387-fp.h (i387_cache_to_xsave): Likewise.
16022 (i387_xsave_to_cache): Likewise.
16023 (x86_xcr0): Likewise.
16024
16025 * linux-arm-low.c (target_regsets): Initialize nt_type to 0.
16026 * linux-crisv32-low.c (target_regsets): Likewise.
16027 * linux-m68k-low.c (target_regsets): Likewise.
16028 * linux-mips-low.c (target_regsets): Likewise.
16029 * linux-ppc-low.c (target_regsets): Likewise.
16030 * linux-s390-low.c (target_regsets): Likewise.
16031 * linux-sh-low.c (target_regsets): Likewise.
16032 * linux-sparc-low.c (target_regsets): Likewise.
16033 * linux-xtensa-low.c (target_regsets): Likewise.
16034
16035 * linux-low.c: Include <sys/uio.h>.
16036 (regsets_fetch_inferior_registers): Support nt_type.
16037 (regsets_store_inferior_registers): Likewise.
16038 (linux_process_qsupported): New.
16039 (linux_target_ops): Add linux_process_qsupported.
16040
16041 * linux-low.h (regset_info): Add nt_type.
16042 (linux_target_ops): Add process_qsupported.
16043
16044 * linux-x86-low.c: Include "i386-xstate.h", "elf/common.h"
16045 and <sys/uio.h>.
16046 (init_registers_i386_avx_linux): New.
16047 (init_registers_amd64_avx_linux): Likewise.
16048 (xmltarget_i386_linux_no_xml): Likewise.
16049 (xmltarget_amd64_linux_no_xml): Likewise.
16050 (PTRACE_GETREGSET): Likewise.
16051 (PTRACE_SETREGSET): Likewise.
16052 (x86_fill_xstateregset): Likewise.
16053 (x86_store_xstateregset): Likewise.
16054 (use_xml): Likewise.
16055 (x86_linux_update_xmltarget): Likewise.
16056 (x86_linux_process_qsupported): Likewise.
16057 (target_regsets): Add NT_X86_XSTATE entry and Initialize nt_type.
16058 (x86_arch_setup): Don't call init_registers_amd64_linux nor
16059 init_registers_i386_linux here. Call
16060 x86_linux_update_xmltarget.
16061 (the_low_target): Add x86_linux_process_qsupported.
16062
16063 * server.c (handle_query): Call target_process_qsupported.
16064
16065 * target.h (target_ops): Add process_qsupported.
16066 (target_process_qsupported): New.
16067
16068 2010-04-03 Pedro Alves <pedro@codesourcery.com>
16069
16070 * inferiors.c (add_thread): Set last_status kind to
16071 TARGET_WAITKIND_IGNORE.
16072 * linux-low.c (cancel_breakpoint): Remove unnecessary regcache
16073 fetch. Use ptid_of. Avoid unnecessary get_lwp_thread calls.
16074 (linux_wait_1): Move `thread' local definition to block that uses
16075 it. Don't NULL initialize `event_child'.
16076 (linux_resume_one_thread): Avoid unnecessary get_lwp_thread calls.
16077 Alway set the thread's last_status to TARGET_WAITKIND_IGNORE.
16078 * linux-x86-low.c (x86_breakpoint_at): Read raw memory.
16079
16080 2010-04-01 Pedro Alves <pedro@codesourcery.com>
16081
16082 * linux-low.c (get_stop_pc): Don't adjust the PC if stopped with
16083 an extended waitstatus, or by a watchpoint.
16084 (cancel_breakpoints_callback): Don't cancel a breakpoint if the
16085 thread was stepping or has been stopped by a watchpoint.
16086
16087 2010-04-01 Pedro Alves <pedro@codesourcery.com>
16088
16089 * mem-break.c (struct raw_breakpoint): New field shlib_disabled.
16090 (set_gdb_breakpoint_at): If GDB is inserting a breakpoint on top
16091 of another, then delete the previous, and validate all
16092 breakpoints.
16093 (validate_inserted_breakpoint): New.
16094 (delete_disabled_breakpoints): New.
16095 (validate_breakpoints): New.
16096 (check_mem_read): Validate breakpoints before trusting their
16097 shadow. Delete disabled breakpoints.
16098 (check_mem_write): Validate breakpoints before trusting they
16099 should be inserted. Delete disabled breakpoints.
16100 * mem-break.h (validate_breakpoints):
16101 * server.c (handle_query): Validate breakpoints when we see a
16102 qSymbol query.
16103
16104 2010-04-01 Pedro Alves <pedro@codesourcery.com>
16105
16106 * linux-low.c (linux_wait_1): Avoid setting need_step_over is
16107 there's a GDB breakpoint at stop_pc. Always report a trap to GDB
16108 if we could tell there's a GDB breakpoint at stop_pc.
16109 (need_step_over_p): Don't do a step over if we find a GDB
16110 breakpoint at the resume PC.
16111
16112 * mem-break.c (struct raw_breakpoint): New.
16113 (enum bkpt_type): New type `gdb_breakpoint'.
16114 (struct breakpoint): Delete the `PC', `old_data' and `inserted'
16115 fields. New field `raw'.
16116 (find_raw_breakpoint_at): New.
16117 (set_raw_breakpoint_at): Handle refcounting. Create a raw
16118 breakpoint instead.
16119 (set_breakpoint_at): Adjust.
16120 (delete_raw_breakpoint): New.
16121 (release_breakpoint): New.
16122 (delete_breakpoint): Rename to...
16123 (delete_breakpoint_1): ... this. Add proc parameter. Use
16124 release_breakpoint. Return ENOENT.
16125 (delete_breakpoint): Reimplement.
16126 (find_breakpoint_at): Delete.
16127 (find_gdb_breakpoint_at): New.
16128 (delete_breakpoint_at): Delete.
16129 (set_gdb_breakpoint_at): New.
16130 (delete_gdb_breakpoint_at): New.
16131 (gdb_breakpoint_here): New.
16132 (set_reinsert_breakpoint): Use release_breakpoint.
16133 (uninsert_breakpoint): Rename to ...
16134 (uninsert_raw_breakpoint): ... this.
16135 (uninsert_breakpoints_at): Adjust to handle raw breakpoints.
16136 (reinsert_raw_breakpoint): Change parameter type to
16137 raw_breakpoint.
16138 (reinsert_breakpoints_at): Adjust to handle raw breakpoints
16139 instead.
16140 (check_breakpoints): Adjust. Use release_breakpoint.
16141 (breakpoint_here): Rewrite using find_raw_breakpoint_at.
16142 (breakpoint_inserted_here): Ditto.
16143 (check_mem_read): Adjust to iterate over raw breakpoints instead.
16144 Don't trust the breakpoint's shadow if it is not inserted.
16145 (check_mem_write): Adjust to iterate over raw breakpoints instead.
16146 (delete_all_breakpoints): Adjust.
16147 (free_all_breakpoints): Mark all breakpoints as uninserted, and
16148 use delete_breakpoint_1.
16149
16150 * mem-break.h (breakpoints_supported): Delete declaration.
16151 (set_gdb_breakpoint_at): Declare.
16152 (gdb_breakpoint_here): Declare.
16153 (delete_breakpoint_at): Delete.
16154 (delete_gdb_breakpoint_at): Declare.
16155
16156 * server.h (struct raw_breakpoint): Forward declare.
16157 (struct process_info): New field `raw_breakpoints'.
16158
16159 * linux-x86-low.c (x86_insert_point, x86_remote_point): Handle Z0
16160 breakpoints.
16161
16162 2010-03-24 Pedro Alves <pedro@codesourcery.com>
16163
16164 * linux-low.c (status_pending_p_callback): Fix comment.
16165 (linux_wait_for_event_1): Move most of the internal breakpoint
16166 handling from here...
16167 (linux_wait_1): ... to here.
16168 (count_events_callback): New.
16169 (select_singlestep_lwp_callback): New.
16170 (select_event_lwp_callback): New.
16171 (cancel_breakpoints_callback): New.
16172 (select_event_lwp): New.
16173 (linux_wait_1): Simplify internal breakpoint handling. Give equal
16174 priority to all LWPs that have had events that should be reported
16175 to the client. Cancel breakpoints when about to reporting the
16176 event to the client, not while stopping lwps. No longer cancel
16177 finished single-steps here.
16178 (cancel_finished_single_step): Delete.
16179 (cancel_finished_single_steps): Delete.
16180
16181 2010-03-24 Pedro Alves <pedro@codesourcery.com>
16182
16183 * mem-break.c (enum bkpt_type): New.
16184 (struct breakpoint): New field `type'.
16185 (set_breakpoint_at): Change return type to struct breakpoint
16186 pointer. Set type to `other_breakpoint' by default.
16187 (delete_breakpoint): Rewrite, supporting more than one breakpoint
16188 in the breakpoint list.
16189 (delete_reinsert_breakpoints): Only delete reinsert breakpoints.
16190 (reinsert_breakpoint): Rename to ...
16191 (reinsert_raw_breakpoint): ... this.
16192 (reinsert_breakpoints_at): Adjust.
16193 * mem-break.h (struct breakpoint): Declare.
16194 (set_breakpoint_at): Change return type to struct breakpoint
16195 pointer.
16196
16197 2010-03-24 Pedro Alves <pedro@codesourcery.com>
16198
16199 * server.c (handle_query): Assign, not compare.
16200
16201 2010-03-24 Pedro Alves <pedro@codesourcery.com>
16202
16203 Teach linux gdbserver to step-over-breakpoints.
16204
16205 * linux-low.c (can_hardware_single_step): New.
16206 (supports_breakpoints): New.
16207 (handle_extended_wait): If stopping threads, read the stop pc of
16208 the new cloned LWP.
16209 (get_pc): New.
16210 (get_stop_pc): Add `lwp' parameter. Handle it. Bail out if the
16211 low target doesn't support retrieving the PC.
16212 (add_lwp): Set last_resume_kind to resume_continue.
16213 (linux_attach_lwp_1): Adjust comments. Always set stop_expected.
16214 (linux_attach): Don't clear stop_expected. Set the lwp's
16215 last_resume_kind to resume_stop.
16216 (linux_detach_one_lwp): Don't check for removed breakpoints.
16217 (check_removed_breakpoint): Delete.
16218 (status_pending_p): Rename to ...
16219 (status_pending_p_callback): ... this. Don't check for removed
16220 breakpoints. Don't consider threads that are stopped from GDB's
16221 perspective.
16222 (linux_wait_for_lwp): Always read the stop_pc here.
16223 (cancel_breakpoint): New.
16224 (step_over_bkpt): New global.
16225 (linux_wait_for_event_1): Implement stepping over breakpoints.
16226 (gdb_wants_lwp_stopped): New.
16227 (gdb_wants_all_stopped): New.
16228 (linux_wait_1): Tag threads as gdb-wants-stopped. Cancel finished
16229 single-step traps here. Store the thread's last reported target
16230 wait status.
16231 (send_sigstop): Don't clear stop_expected. Always set it,
16232 instead.
16233 (mark_lwp_dead): Remove reference to pending_is_breakpoint.
16234 (cancel_finished_single_step): New.
16235 (cancel_finished_single_steps): New.
16236 (wait_for_sigstop): Don't cancel finished single-step traps here.
16237 (linux_resume_one_lwp): Don't check for removed breakpoints.
16238 Don't set `step' on non-hardware step archs.
16239 (linux_set_resume_request): Ignore resume_stop requests if already
16240 stopping or stopped. Set the lwp's last_resume_kind.
16241 (resume_status_pending_p): Don't check for removed breakpoints.
16242 (need_step_over_p): New.
16243 (start_step_over): New.
16244 (finish_step_over): New.
16245 (linux_resume_one_thread): Always queue a sigstop for resume_stop
16246 requests. Clear the thread's last reported target waitstatus.
16247 Don't use the `suspended' flag. Don't consider pending breakpoints.
16248 (linux_resume): Start a step-over if necessary.
16249 (proceed_one_lwp): New.
16250 (proceed_all_lwps): New.
16251 (unstop_all_lwps): New.
16252 * linux-low.h (struct lwp_info): Rewrite comment for the
16253 `suspended' flag. Add the `stop_pc' field. Delete the
16254 `pending_stop_pc' field. Tweak the `stepping' flag's comment.
16255 Add `'last_resume_kind' and `need_step_over' fields.
16256 * inferiors.c (struct thread_info): Delete, moved elsewhere.
16257 * mem-break.c (struct breakpoint): Delete `reinserting' flag.
16258 Delete `breakpoint_to_reinsert' field. New flag `inserted'.
16259 (set_raw_breakpoint_at): New.
16260 (set_breakpoint_at): Rewrite to use it.
16261 (reinsert_breakpoint_handler): Delete.
16262 (set_reinsert_breakpoint): New.
16263 (reinsert_breakpoint_by_bp): Delete.
16264 (delete_reinsert_breakpoints): New.
16265 (uninsert_breakpoint): Rewrite.
16266 (uninsert_breakpoints_at): New.
16267 (reinsert_breakpoint): Rewrite.
16268 (reinsert_breakpoints_at): New.
16269 (check_breakpoints): Rewrite.
16270 (breakpoint_here): New.
16271 (breakpoint_inserted_here): New.
16272 (check_mem_read): Adjust.
16273 * mem-break.h (breakpoints_supported, breakpoint_here)
16274 (breakpoint_inserted_here, set_reinsert_breakpoint): Declare.
16275 (reinsert_breakpoint_by_bp): Delete declaration.
16276 (delete_reinsert_breakpoints): Declare.
16277 (reinsert_breakpoint): Delete declaration.
16278 (reinsert_breakpoints_at): Declare.
16279 (uninsert_breakpoint): Delete declaration.
16280 (uninsert_breakpoints_at): Declare.
16281 (check_breakpoints): Adjust prototype.
16282 * server.h: Adjust include order.
16283 (struct thread_info): Declare here. Add a `last_status' field.
16284
16285 2010-03-23 Michael Snyder <msnyder@vmware.com>
16286
16287 * server.c (crc32): New function.
16288 (handle_query): Add handling for 'qCRC:' request.
16289
16290 2010-03-23 Pedro Alves <pedro@codesourcery.com>
16291
16292 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR6 if the
16293 lwp had been stopped by a watchpoint.
16294
16295 2010-03-16 Pedro Alves <pedro@codesourcery.com>
16296
16297 * server.h (internal_error): Declare.
16298 (gdb_assert, ASSERT_FUNCTION, gdb_assert_fail): Define.
16299 * utils.c (internal_error): New function.
16300
16301 2010-03-15 Andreas Schwab <schwab@redhat.com>
16302
16303 * configure.srv: Fix typo setting srv_regobj.
16304
16305 2010-03-15 Pedro Alves <pedro@codesourcery.com>
16306
16307 * linux-low.c (fetch_register): Avoid passing a non string literal
16308 format to `error'.
16309 (usr_store_inferior_registers): Ditto.
16310
16311 2010-03-14 Pedro Alves <pedro@codesourcery.com>
16312
16313 * linux-low.c (linux_write_memory): Bail out early if peeking
16314 memory failed.
16315
16316 2010-03-14 Pedro Alves <pedro@codesourcery.com>
16317
16318 * linux-low.h (struct lwp_info): New fields
16319 `stopped_by_watchpoint' and `stopped_data_address'.
16320 * linux-low.c (linux_wait_for_lwp): Check for watchpoint triggers
16321 here, and cache them in the lwp object.
16322 (wait_for_sigstop): Check stopped_by_watchpoint lwp field
16323 directly.
16324 (linux_resume_one_lwp): Clear the lwp's stopped_by_watchpoint
16325 field.
16326 (linux_stopped_by_watchpoint): Rewrite.
16327 (linux_stopped_data_address): Rewrite.
16328
16329 2010-03-06 Simo Melenius <simo.melenius@iki.fi>
16330
16331 * linux-low.c (linux_wait_for_lwp): Fetch the regcache after
16332 switching the current inferior, not before.
16333
16334 2010-03-01 H.J. Lu <hongjiu.lu@intel.com>
16335
16336 * Makefile.in (clean): Replace reg-i386.c, reg-x86-64.c,
16337 reg-i386-linux.c and reg-x86-64-linux.c with i386.c, amd64.c,
16338 i386-linux.c and amd64-linux.c.
16339 (reg-i386.o): Removed.
16340 (reg-i386.c): Likewise.
16341 (reg-i386-linux.o): Likewise.
16342 (reg-i386-linux.c): Likewise.
16343 (reg-x86-64.o): Likewise.
16344 (reg-x86-64.c): Likewise.
16345 (reg-x86-64-linux.o): Likewise.
16346 (reg-x86-64-linux.c): Likewise.
16347 (i386.o): New.
16348 (i386.c): Likewise.
16349 (i386-linux.o): Likewise.
16350 (i386-linux.c): Likewise.
16351 (amd64.o): Likewise.
16352 (amd64.c): Likewise.
16353 (amd64-linux.o): Likewise.
16354 (amd64-linux.c): Likewise.
16355
16356 * configure.srv (srv_i386_regobj): New.
16357 (srv_i386_linux_regobj): Likewise.
16358 (srv_amd64_regobj): Likewise.
16359 (srv_amd64_linux_regobj): Likewise.
16360 (srv_i386_32bit_xmlfiles): Likewise.
16361 (srv_i386_64bit_xmlfiles): Likewise.
16362 (srv_i386_xmlfiles): Likewise.
16363 (srv_amd64_xmlfiles): Likewise.
16364 (srv_i386_linux_xmlfiles): Likewise.
16365 (srv_amd64_linux_xmlfiles): Likewise.
16366 (i[34567]86-*-cygwin*): Set srv_regobj to $srv_i386_regobj. Set
16367 srv_xmlfiles to $srv_i386_xmlfiles.
16368 (i[34567]86-*-mingw32ce*): Likewise.
16369 (i[34567]86-*-mingw*): Likewise.
16370 (i[34567]86-*-nto*): Likewise.
16371 (i[34567]86-*-linux*): Set srv_regobj to $srv_i386_linux_regobj
16372 and $srv_amd64_linux_regobj. Set srv_xmlfiles to
16373 $srv_i386_linux_xmlfiles and $srv_amd64_linux_xmlfiles.
16374 (x86_64-*-linux*): Likewise.
16375
16376 * linux-x86-low.c (init_registers_x86_64_linux): Removed.
16377 (init_registers_amd64_linux): New.
16378 (x86_arch_setup): Replace init_registers_x86_64_linux with
16379 init_registers_amd64_linux.
16380
16381 2010-02-23 Maxim Kuvyrkov <maxim@codesourcery.com>
16382
16383 * configure.ac: Check for libdl. If it is not available link against
16384 static libthread_db.
16385 * configure: Regenerate.
16386
16387 2010-02-22 Pedro Alves <pedro@codesourcery.com>
16388
16389 PR9605
16390
16391 * i386-low.c (i386_length_and_rw_bits): Throw a fatal error if
16392 handing a read watchpoint.
16393 (i386_low_insert_watchpoint): Read watchpoints aren't supported.
16394
16395 2010-02-12 Doug Evans <dje@google.com>
16396
16397 * linux-low.c (linux_supports_tracefork_flag): Document.
16398 (linux_look_up_symbols): Add comment.
16399
16400 2010-02-03 H.J. Lu <hongjiu.lu@intel.com>
16401
16402 * regcache.c (supply_register): Clear regcache if buf is NULL.
16403
16404 2010-02-02 Nicolas Roche <roche@sourceware.org>
16405 Joel Brobecker <brobecker@adacore.com>
16406
16407 * inferiors.c (find_inferior): Add function documentation.
16408 (unloaded_dll): Handle the case where the unloaded dll has not
16409 been previously registered in the dll list.
16410
16411 2010-02-01 Daniel Jacobowitz <dan@codesourcery.com>
16412
16413 * linux-arm-low.c (thumb_breakpoint_len): Delete.
16414 (thumb2_breakpoint): New.
16415 (arm_breakpoint_at): Check for Thumb-2 breakpoints.
16416
16417 2010-01-29 Daniel Jacobowitz <dan@codesourcery.com>
16418
16419 * linux-low.c (get_stop_pc): Check for SIGTRAP.
16420 (linux_wait_for_event_1): Handle SIGILL and SIGSEGV as possible
16421 breakpoints.
16422
16423 2010-01-21 Pedro Alves <pedro@codesourcery.com>
16424
16425 * linux-ppc-low.c (ppc_arch_setup): Adjust to regcache changes.
16426
16427 2010-01-21 Jan Kratochvil <jan.kratochvil@redhat.com>
16428
16429 * linux-s390-low.c (s390_collect_ptrace_register)
16430 (s390_supply_ptrace_register): Adjust it for the new regcache parameter.
16431
16432 2010-01-21 Doug Evans <dje@google.com>
16433
16434 * linux-low.c (PTRACE_ARG3_TYPE): Change from long to void*.
16435 (PTRACE_ARG4_TYPE): New macro.
16436 (handle_extended_wait): Cast ptrace arg4 to PTRACE_ARG4_TYPE.
16437 (linux_wait_for_event_1, linux_resume_one_lwp): Ditto.
16438 (fetch_register): Cast to uintptr_t before casting to PTRACE_ARG3_TYPE.
16439 (usr_store_inferior_registers): Ditto.
16440 (linux_read_memory, linux_write_memory): Ditto.
16441 (linux_test_for_tracefork): Ditto.
16442
16443 * linux-arm-low.c: Remove redundant include of gdb_proc_service.h.
16444 Only include elf.h if gdb_proc_service.h didn't include linux/elf.h.
16445
16446 2010-01-21 Pedro Alves <pedro@codesourcery.com>
16447
16448 * proc-service.c (ps_lgetregs): Don't refetch registers from the
16449 target.
16450
16451 2010-01-21 Pedro Alves <pedro@codesourcery.com>
16452
16453 * spu-low.c (spu_fetch_registers, spu_store_registers): Change
16454 prototype to take a regcache. Adjust.
16455
16456 2010-01-20 Pedro Alves <pedro@codesourcery.com>
16457
16458 * regcache.h (struct thread_info): Forward declare.
16459 (struct regcache): New.
16460 (new_register_cache): Adjust prototype.
16461 (get_thread_regcache): Declare.
16462 (free_register_cache): Adjust prototype.
16463 (registers_to_string, registers_from_string): Ditto.
16464 (supply_register, supply_register_by_name, collect_register)
16465 (collect_register_as_string, collect_register_by_name): Ditto.
16466 * regcache.c (struct inferior_regcache_data): Delete.
16467 (get_regcache): Rename to ...
16468 (get_thread_regcache): ... this. Adjust. Switch inferior before
16469 fetching registers.
16470 (regcache_invalidate_one): Adjust.
16471 (regcache_invalidate): Fix prototype.
16472 (new_register_cache): Return the new register cache.
16473 (free_register_cache): Change prototype.
16474 (realloc_register_cache): Adjust.
16475 (registers_to_string): Change prototype to take a regcache. Adjust.
16476 (registers_from_string): Ditto.
16477 (register_data): Ditto.
16478 (supply_register): Ditto.
16479 (supply_register_by_name): Ditto.
16480 (collect_register): Ditto.
16481 (collect_register_as_string): Ditto.
16482 (collect_register_by_name): Ditto.
16483 * server.c (process_serial_event): Adjust.
16484 * linux-low.h (regset_fill_func, regset_store_func): Change
16485 prototype.
16486 (get_pc, set_pc, collect_ptrace_register, supply_ptrace_register):
16487 Change prototype.
16488 * linux-low.c (get_stop_pc): Adjust.
16489 (check_removed_breakpoint): Adjust.
16490 (linux_wait_for_event): Adjust.
16491 (linux_resume_one_lwp): Adjust.
16492 (fetch_register): Add regcache parameter. Adjust.
16493 (usr_store_inferior_registers): Ditto.
16494 (regsets_fetch_inferior_registers): Ditto.
16495 (regsets_store_inferior_registers): Ditto.
16496 (linux_fetch_registers, linux_store_registers): Ditto.
16497 * i387-fp.c (i387_cache_to_fsave): Change prototype to take a
16498 regcache. Adjust.
16499 (i387_fsave_to_cache, i387_cache_to_fxsave, i387_fxsave_to_cache):
16500 Ditto.
16501 * i387-fp.h (i387_cache_to_fsave, i387_fsave_to_cache): Change
16502 prototype to take a regcache.
16503 (i387_cache_to_fxsave, i387_fxsave_to_cache): Ditto.
16504 * remote-utils.c (convert_ascii_to_int, outreg)
16505 (prepare_resume_reply): Change prototype to take a regcache.
16506 Adjust.
16507 * target.h (struct target_ops) <fetch_registers, store_registers>:
16508 Change prototype to take a regcache.
16509 (fetch_inferior_registers, store_inferior_registers): Change
16510 prototype to take a regcache. Adjust.
16511 * proc-service.c (ps_lgetregs): Adjust.
16512 * linux-x86-low.c (x86_fill_gregset, x86_store_gregset)
16513 (x86_fill_fpregset, x86_store_fpregset, x86_fill_fpxregset)
16514 (x86_store_fpxregset, x86_get_pc, x86_set_pc): Change prototype to
16515 take a regcache. Adjust.
16516 * linux-arm-low.c (arm_fill_gregset, arm_store_gregset)
16517 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
16518 (arm_store_vfpregset, arm_get_pc, arm_set_pc):
16519 (arm_breakpoint_at): Change prototype to take a regcache. Adjust.
16520 * linux-cris-low.c (cris_get_pc, cris_set_pc)
16521 (cris_cannot_fetch_register):
16522 (cris_breakpoint_at): Change prototype to take a regcache.
16523 Adjust.
16524 * linux-crisv32-low.c (cris_get_pc, cris_set_pc,
16525 cris_reinsert_addr, cris_write_data_breakpoint): Change prototype
16526 to take a regcache. Adjust.
16527 (cris_breakpoint_at, cris_insert_point, cris_remove_point):
16528 Adjust.
16529 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Change prototype to
16530 take a regcache. Adjust.
16531 * linux-m68k-low.c (m68k_fill_gregset, m68k_store_gregset)
16532 (m68k_fill_fpregset, m68k_store_fpregset, m68k_get_pc,
16533 (m68k_set_pc): Change prototype to take a regcache. Adjust.
16534 * linux-mips-low.c (mips_get_pc):
16535 (mips_set_pc): Change prototype to take a regcache. Adjust.
16536 (mips_reinsert_addr): Adjust.
16537 (mips_collect_register): Change prototype to take a regcache.
16538 Adjust.
16539 (mips_supply_register):
16540 (mips_collect_register_32bit, mips_supply_register_32bit)
16541 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
16542 (mips_store_fpregset): Ditto.
16543 * linux-ppc-low.c (ppc_supply_ptrace_register)
16544 (ppc_supply_ptrace_register): Ditto.
16545 (parse_spufs_run): Adjust.
16546 (ppc_get_pc, ppc_set_pc, ppc_fill_gregset, ppc_fill_vsxregset)
16547 (ppc_store_vsxregset, ppc_fill_vrregset, ppc_store_vrregset)
16548 (ppc_fill_evrregset, ppc_store_evrregset): Change prototype to
16549 take a regcache. Adjust.
16550 * linux-s390-low.c (s390_collect_ptrace_register)
16551 (s390_supply_ptrace_register, s390_fill_gregset, s390_get_pc)
16552 (s390_set_pc): Change prototype to take a regcache. Adjust.
16553 (s390_arch_setup): Adjust.
16554 * linux-sh-low.c (sh_get_pc, sh_breakpoint_at)
16555 (sh_fill_gregset): Change prototype to take a regcache. Adjust.
16556 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
16557 (sparc_fill_gregset, sparc_store_gregset_from_stack)
16558 (sparc_store_gregset, sparc_get_pc): Change prototype to take a
16559 regcache. Adjust.
16560 (sparc_breakpoint_at): Adjust.
16561 * linux-xtensa-low.c (xtensa_fill_gregset):
16562 (xtensa_store_gregset):
16563 (xtensa_fill_xtregset, xtensa_store_xtregset, xtensa_get_pc)
16564 (xtensa_set_pc): Change prototype to take a regcache. Adjust.
16565 * nto-low.c (nto_fetch_registers, nto_store_registers): Change
16566 prototype to take a regcache. Adjust.
16567 * win32-arm-low.c (arm_fetch_inferior_register)
16568 (arm_store_inferior_register): Change prototype to take a
16569 regcache. Adjust.
16570 * win32-i386-low.c (i386_fetch_inferior_register)
16571 (i386_store_inferior_register): Change prototype to take a
16572 regcache. Adjust.
16573 * win32-low.c (child_fetch_inferior_registers)
16574 (child_store_inferior_registers): Change prototype to take a
16575 regcache. Adjust.
16576 (win32_wait): Adjust.
16577 (win32_fetch_inferior_registers): Change prototype to take a
16578 regcache. Adjust.
16579 (win32_store_inferior_registers): Adjust.
16580 * win32-low.h (struct win32_target_ops) <fetch_inferior_register,
16581 store_inferior_register>: Change prototype to take a regcache.
16582
16583 2010-01-20 Doug Evans <dje@google.com>
16584
16585 * linux-low.c (linux_create_inferior): Wrap use of __SIGRTMIN in
16586 #ifdef.
16587 (linux_wait_for_event1, linux_init_signals): Ditto.
16588 (W_STOPCODE): Provide definition if missing.
16589
16590 2010-01-13 Vladimir Prus <vladimir@codesourcery.com>
16591
16592 * linux-low.c (linux_core_of_thread): New.
16593 (compare_ints, show_process, list_threads): New.
16594 (linux_qxfer_osdata): Report threads and cores.
16595 (linux_target_op): Register linux_core_of_thread.
16596 * remote-utils.c (prepare_resume_reply): Report the core.
16597 (buffer_xml_printf): Support %d specifier.
16598 * server.c (handle_threads_qxfer_proper, handle_threads_qxfer):
16599 New.
16600 (handle_query): Handle qXfer:threads. Announce availability
16601 thereof.
16602 * target.h (struct target_ops): New field core_of_thread.
16603
16604 2010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
16605
16606 * Makefile.in (clean): Remove new generated files.
16607 (reg-s390.o, reg-s390.c): Remove rules.
16608 (reg-s390x.o, reg-s390x.c): Likewise.
16609 (s390-linux32.o, s390-linux32.c): Add rules.
16610 (s390-linux64.o, s390-linux64.c): Likewise.
16611 (s390x-linux64.o, s390x-linux64.c): Likewise.
16612 * configure.srv (s390*-*-linux*): Update srv_regobj and srv_xmlfiles.
16613 * linux-s390-low.c: Include <elf.h>.
16614 (HWCAP_S390_HIGH_GPRS): Define if undefined.
16615 (init_registers_s390): Remove prototype.
16616 (init_registers_s390x): Likewise.
16617 (init_registers_s390_linux32): Add prototype.
16618 (init_registers_s390_linux64): Likewise.
16619 (init_registers_s390x_linux64): Likewise.
16620 (s390_num_regs_3264): New define.
16621 (s390_regmap_3264): New global variable.
16622 (s390_cannot_fetch_register): Remove obsolete check.
16623 (s390_cannot_store_register): Likewise.
16624 (s390_collect_ptrace_register): Handle upper/lower register halves.
16625 (s390_supply_ptrace_register): Likewise.
16626 (s390_fill_gregset): Update to register number changes.
16627 (s390_get_hwcap): New routine.
16628 (s390_arch_setup): Detect 32-bit process running on 64-bit system.
16629 Install appropriate regmap and register set.
16630
16631 2010-01-01 Joel Brobecker <brobecker@adacore.com>
16632
16633 * server.c (gdbserver_version): Update copyright year to 2010.
16634 * gdbreplay.c (gdbreplay_version): Likewise.
16635
16636 2009-12-28 Doug Evans <dje@google.com>
16637
16638 * linux-low.c: Delete inclusion of ansidecl.h, elf/common.h,
16639 elf/external.h. Include <elf.h> instead but only if necessary.
16640
16641 2009-12-28 Pedro Alves <pedro@codesourcery.com>
16642
16643 * linux-low.c (linux_remove_process): Remove `detaching'
16644 parameter. Don't release/detach from thread_db here.
16645 (linux_kill): Release/detach from thread_db here, ...
16646 (linux_detach): ... and here, before actually detaching.
16647 (linux_wait_1): ... and here, when a process exits.
16648 * thread-db.c (any_thread_of): New.
16649 (thread_db_free): Switch the current inferior to a thread of the
16650 passed in process.
16651
16652 2009-12-21 Doug Evans <dje@google.com>
16653
16654 * linux-x86-low.c: Delete outdated comment about Elf32_Phdr.
16655
16656 * linux-low.c (kill_lwp): Use __NR_tkill instead of SYS_tkill.
16657 Move definition of tkill_failed to ifdef __NR_tkill to avoid gcc
16658 warning ifndef __NR_tkill. Move setting of errno there too.
16659 Delete unnecessary resetting of errno after syscall.
16660 Minor comment changes to match gdb/linux-nat.c:kill_lwp.
16661
16662 * configure.ac: Check for dladdr.
16663 * config.in: Regenerate.
16664 * configure: Regenerate.
16665 * thread-db.c (dladdr_to_soname): Only define ifdef HAVE_DLADDR.
16666 (try_thread_db_load): Update.
16667
16668 * linux-low.c (my_waitpid): Delete unnecessary prototype.
16669
16670 2009-12-18 Doug Evans <dje@google.com>
16671
16672 * event-loop.c: Include unistd.h if it exists.
16673
16674 * linux-low.c (my_waitpid): Move definition away from being in
16675 between linux_tracefork_child/linux_test_for_tracefork.
16676
16677 * gdb_proc_service.h (psaddr_t): Fix type.
16678 * thread-db.c (thread_db_info.td_thr_tls_get_addr_p): Fix
16679 signature to match glibc.
16680
16681 2009-12-16 Doug Evans <dje@google.com>
16682
16683 * linux-low.c (linux_read_memory): Fix argument to read.
16684
16685 2009-11-26 Pedro Alves <pedro@codesourcery.com>
16686
16687 * win32-low.c (get_child_debug_event): On EXIT_THREAD_DEBUG_EVENT
16688 events, don't leave current_inferior pointing at null.
16689
16690 2009-11-26 Pedro Alves <pedro@codesourcery.com>
16691
16692 * win32-low.c (LOG): Delete.
16693 (OUTMSG): Output to stderr.
16694 (OUTMSG2): Conditionalize on `debug_threads' variable, instead of
16695 on compile time LOG macro.
16696 (win32_wait): Fix debug output.
16697
16698 2009-11-26 Pedro Alves <pedro@codesourcery.com>
16699
16700 * win32-low.c (win32_add_one_solib): If the dll name is
16701 "ntdll.dll", prepend the system directory to the dll path.
16702
16703 2009-11-17 Daniel Jacobowitz <dan@codesourcery.com>
16704
16705 * m68k-tdep.c (m68k_gdbarch_init): Reuse previous initialization.
16706
16707 2009-11-17 Nathan Sidwell <nathan@codesourcery.com>
16708 Vladimir Prus <vladimir@codesourcery.com>
16709
16710 * Makefile.in (reg-cf.o, reg-cf.c): New targets.
16711 * configure.ac: Check for __mcoldfire__ and set
16712 gdb_cv_m68k_is_coldfire.
16713 * configure.srv: Use gdb_cv_m68k_is_coldfire to select between
16714 reg-cf.o and reg-m68k.o.
16715 * configure: Regenerated.
16716
16717 2009-11-16 Pedro Alves <pedro@codesourcery.com>
16718
16719 * linux-low.c (linux_remove_process): Add `detaching' parameter.
16720 Pass it to thread_db_free.
16721 (linux_kill, linux_detach, linux_wait_1): Adjust to pass the
16722 proper `detaching' argument to linux_remove_process.
16723 * linux-low.h (thread_db_free): Add `detaching' parameter.
16724 * thread-db.c (thread_db_init): Pass false as `detaching' argument
16725 to thread_db_free.
16726 (thread_db_free): Add `detaching' parameter. Only
16727 call td_ta_clear_event if detaching from process.
16728
16729 2009-11-12 Maxim Kuvyrkov <maxim@codesourcery.com>
16730
16731 * thread-db.c (thread_db_free): Fix typo.
16732
16733 2009-11-11 Paul Pluzhnikov <ppluzhnikov@google.com>
16734
16735 PR gdb/10838
16736 * thread-db.c (thread_db_free): Call td_ta_clear_event.
16737
16738 2009-11-03 Nathan Sidwell <nathan@codesourcery.com>
16739
16740 * configure.ac (i[34567]86-*): Check if we're targetting x86-64
16741 with an i686 compiler.
16742 * configure.srv (i[34567]86-*-linux*): Pull in x86-64 handling if
16743 needed.
16744 * configure: Rebuilt.
16745
16746 2009-10-29 Sandra Loosemore <sandra@codesourcery.com>
16747
16748 PR gdb/10783
16749
16750 * server.c (handle_search_memory_1): Correct read_addr initialization
16751 in loop for searching subsequent chunks.
16752
16753 2009-10-29 Paul Pluzhnikov <ppluzhnikov@google.com>
16754
16755 * configure.ac: New --with-libthread-db option.
16756 * thread-db.c: Allow direct dependence on libthread_db.
16757 (thread_db_free): Adjust.
16758 * config.in: Regenerate.
16759 * configure: Likewise.
16760
16761 2009-10-28 Paul Pluzhnikov <ppluzhnikov@google.com>
16762
16763 PR gdb/10757
16764 * thread-db.c (attach_thread): New function.
16765 (maybe_attach_thread): Return success/failure.
16766 (find_new_threads_callback): Adjust.
16767 (thread_db_find_new_threads): Loop until no new threads.
16768
16769 2009-10-13 Pedro Alves <pedro@codesourcery.com>
16770
16771 * proc-service.c (ps_lgetregs): Formatting.
16772
16773 2009-10-08 Paul Pluzhnikov <ppluzhnikov@google.com>
16774
16775 * acinclude.m4: (SRV_CHECK_THREAD_DB, SRV_CHECK_TLS_GET_ADDR): Remove.
16776 * configure.ac: Adjust.
16777 * linux-low.h (struct process_info_private): Move members to struct
16778 thread_db.
16779 (thread_db_free, thread_db_handle_monitor_command): New prototype.
16780 * linux-low.c (linux_remove_process): Adjust.
16781 (linux_wait_for_event_1, linux_look_up_symbols): Likewise.
16782 * server.c (handle_query): Move code ...
16783 (handle_monitor_command): ... here. New function.
16784 * target.h (struct target_ops): New member.
16785 * thread-db.c (struct thread_db): New.
16786 (libthread_db_search_path): New variable.
16787 (thread_db_create_event, thread_db_enable_reporting)
16788 (find_one_thread, maybe_attach_thread, find_new_threads_callback)
16789 (thread_db_find_new_threads, (thread_db_get_tls_address): Adjust.
16790 (try_thread_db_load_1, dladdr_to_soname): New functions.
16791 (try_thread_db_load, thread_db_load_search): New functions.
16792 (thread_db_init): Search for libthread_db.
16793 (thread_db_free): New function.
16794 (thread_db_handle_monitor_command): Likewise.
16795 * config.in: Regenerate.
16796 * configure: Regenerate.
16797
16798 2009-09-27 Ulrich Weigand <uweigand@de.ibm.com>
16799
16800 * spu-low.c (spu_kill): Wait for inferior to terminate.
16801 Call clear_inferiors.
16802 (spu_detach): Call clear_inferiors.
16803
16804 2009-08-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
16805
16806 * aclocal.m4: Regenerate.
16807 * config.in: Likewise.
16808 * configure: Likewise.
16809
16810 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
16811
16812 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Define.
16813 (parse_spufs_run): New function.
16814 (ppc_get_pc, ppc_set_pc): Detect and handle SPU PC.
16815 (ppc_breakpoint_at): Handle SPU breakpoints.
16816
16817 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
16818
16819 * linux-low.c: Include <sys/stat.h> and <sys/vfs.h>.
16820 (SPUFS_MAGIC): Define.
16821 (spu_enumerate_spu_ids): New function.
16822 (linux_qxfer_spu): New function.
16823 (linux_target_ops): Install linux_qxfer_spu.
16824
16825 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
16826
16827 * configure.srv (powerpc*-*-linux*): Add powerpc-cell32l.o
16828 and powerpc-cell64l.o to srv_regobj. Add rs6000/powerpc-cell32l.xml
16829 and rs6000/powerpc-cell64l.xml to srv_xmlfiles.
16830 * Makefile.in (powerpc-cell32l.o, powerpc-cell32l.c): New rules.
16831 (powerpc-cell64l.o, powerpc-cell64l.c): Likewise.
16832 (clean): Handle powerpc-cell32l.c and powerpc-cell64l.c.
16833 * linux-ppc-low.c (PPC_FEATURE_CELL): Define.
16834 (init_registers_powerpc_cell32l): Add prototype.
16835 (init_registers_powerpc_cell64l): Likewise.
16836 (ppc_arch_setup): Detect Cell/B.E. architecture.
16837
16838 2009-07-30 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
16839
16840 * Makefile.in (datarootdir): New variable.
16841
16842 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
16843
16844 * linux-low.c (linux_write_memory): Update debugging output.
16845 * Makefile.in (clean): Add new descriptions.
16846 (arm-with-vfpv2.o, arm-with-vfpv2.c, arm-with-vfpv3.o)
16847 (arm-with-vfpv3.c, arm-with-neon.o, arm-with-neon.c): New rules.
16848 * configure.srv: Add new files for arm*-*-linux*.
16849 * linux-arm-low.c: Add new declarations.
16850 (PTRACE_GETVFPREGS, PTRACE_SETVFPREGS): Define if undefined.
16851 (arm_hwcap, HWCAP_VFP, HWCAP_IWMMXT, HWCAP_NEON, HWCAP_VFPv3)
16852 (HWCAP_VFPv3D16): New.
16853 (arm_fill_wmmxregset, arm_store_wmmxregset): Check HWCAP_IWMMXT
16854 instead of __IWMMXT__.
16855 (arm_fill_vfpregset, arm_store_vfpregset, arm_get_hwcap)
16856 (arm_arch_setup): New.
16857 (target_regsets): Remove #ifdef. Add VFP regset.
16858 (the_low_target): Use arm_arch_setup.
16859
16860 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
16861
16862 * linux-low.c (linux_kill_one_lwp): Adjust kernel workaround to skip
16863 the main thread again.
16864
16865 2009-07-06 Aleksandar Ristovski <aristovski@qnx.com>
16866
16867 Adding Neutrino gdbserver.
16868 * configure: Regenerated.
16869 * configure.ac: Add case for srv_qnx and set LIBS accordingly.
16870 * configure.srv (i[34567]86-*-nto*): New target.
16871 * nto-low.c, nto-low.h, nto-x86-low.c: New files.
16872 * remote-utils.c [__QNX__]: Include sys/iomgr.h
16873 (nto_comctrl) [__QNX__]: New function.
16874 (enable_async_io, disable_async_io) [__QNX__]: Call nto_comctrl.
16875
16876 2009-07-05 Danny Backx <dannybackx@users.sourceforge.net>
16877
16878 * configure.srv (i[34567]86-*-mingw32ce*): Add i386-low.o to
16879 srv_tgtobj.
16880
16881 2009-07-04 Danny Backx <dannybackx@users.sourceforge.net>
16882 Pedro Alves <pedro@codesourcery.com>
16883
16884 * win32-i386-low.c (i386_get_thread_context): Handle systems that
16885 don't support CONTEXT_EXTENDED_REGISTERS.
16886 (i386_win32_breakpoint, i386_win32_breakpoint_len): New.
16887 (the_low_target): Install them.
16888 * win32-low.c (get_child_debug_event): Handle WaitForDebugEvent
16889 failing with ERROR_PIPE_NOT_CONNECTED.
16890
16891 2009-06-30 Doug Evans <dje@google.com>
16892 Pierre Muller <muller@ics.u-strasbg.fr>
16893
16894 Add h/w watchpoint support to x86-linux, win32-i386.
16895 * Makefile.in (SFILES): Add i386-low.c
16896 (i386_low_h): Define.
16897 (i386-low.o): Add dependencies.
16898 (linux-x86-low.o): Add i386-low.h dependency.
16899 (win32-i386-low.o): Ditto.
16900 * i386-low.c: New file.
16901 * i386-low.h: New file.
16902 * configure.srv (i[34567]86-*-cygwin*): Add i386-low.o to srv_tgtobj.
16903 (i[34567]86-*-linux*, i[34567]86-*-mingw*, x86_64-*-linux*): Ditto.
16904 * linux-low.c (linux_add_process): Initialize arch_private.
16905 (linux_remove_process): Free arch_private.
16906 (add_lwp): Initialize arch_private.
16907 (delete_lwp): Free arch_private.
16908 (linux_resume_one_lwp): Call the_low_target.prepare_to_resume if
16909 provided.
16910 * linux-low.h (process_info_private): New member arch_private.
16911 (lwp_info): New member arch_private.
16912 (linux_target_ops): New members new_process, new_thread,
16913 prepare_to_resume.
16914 (ptid_of): New macro.
16915 * linux-x86-low.c: Include stddef.h, i386-low.h.
16916 (arch_process_info): New struct.
16917 (arch_lwp_info): New struct.
16918 (x86_linux_dr_get, x86_linux_dr_set): New functions.
16919 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
16920 (i386_dr_low_get_status): New function.
16921 (x86_insert_point, x86_remove_point): New functions.
16922 (x86_stopped_by_watchpoint): New function.
16923 (x86_stopped_data_address): New function.
16924 (x86_linux_new_process, x86_linux_new_thread): New functions.
16925 (x86_linux_prepare_to_resume): New function.
16926 (the_low_target): Add entries for insert_point, remove_point,
16927 stopped_by_watchpoint, stopped_data_address, new_process, new_thread,
16928 prepare_to_resume.
16929 * server.c (debug_hw_points): New global.
16930 (monitor_show_help): Document set debug-hw-points.
16931 (handle_query): Process "set debug-hw-points".
16932 * server.h (debug_hw_points): Declare.
16933 (paddress): Declare.
16934 * utils.c (NUMCELLS, CELLSIZE): New macros.
16935 (get_sell, xsnprintf, paddress): New functions.
16936 * win32-arm-low.c (the_low_target): Add entries for insert_point,
16937 remove_point, stopped_by_watchpoint, stopped_data_address.
16938 * win32-i386-low.c: Include i386-low.h.
16939 (debug_reg_state): Replaces dr.
16940 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
16941 (i386_dr_low_get_status): New function.
16942 (i386_insert_point, i386_remove_point): New functions.
16943 (i386_stopped_by_watchpoint): New function.
16944 (i386_stopped_data_address): New function.
16945 (i386_initial_stuff): Update.
16946 (get_thread_context,set_thread_context,i386_thread_added): Update.
16947 (the_low_target): Add entries for insert_point,
16948 remove_point, stopped_by_watchpoint, stopped_data_address.
16949 * win32-low.c (win32_insert_watchpoint): New function.
16950 (win32_remove_watchpoint): New function.
16951 (win32_stopped_by_watchpoint): New function.
16952 (win32_stopped_data_address): New function.
16953 (win32_target_ops): Add entries for insert_watchpoint,
16954 remove_watchpoint, stopped_by_watchpoint, stopped_data_address.
16955 * win32-low.h (win32_target_ops): New members insert_point,
16956 remove_point, stopped_by_watchpoint, stopped_data_address.
16957
16958 2009-06-25 Pedro Alves <pedro@codesourcery.com>
16959
16960 * server.c (process_serial_event): Re-return unsupported, not
16961 error, if the type isn't recognized. Re-allow supporting only
16962 insert or remove packets. Also call require_running for
16963 breakpoints. Add missing break statement to default case. Tidy.
16964 * target.h (struct target_ops): Rename insert_watchpoint to
16965 insert_point, and remove_watchpoint to remove_point.
16966
16967 * linux-low.h (struct linux_target_ops): Likewise.
16968 * linux-low.c (linux_insert_watchpoint): Rename to ...
16969 (linux_insert_point): ... this. Adjust.
16970 (linux_remove_watchpoint): Rename to ...
16971 (linux_remove_point): ... this. Adjust.
16972 (linux_target_ops): Adjust.
16973 * linux-crisv32-low.c (cris_insert_watchpoint): Rename to ...
16974 (cris_insert_point): ... this.
16975 (cris_remove_watchpoint): Rename to ...
16976 (cris_remove_point): ... this.
16977 (the_low_target): Adjust.
16978
16979 2009-06-24 Pierre Muller <muller@ics.u-strasbg.fr>
16980
16981 * server.c (handle_v_kill): Pass signal_pid to
16982 kill_inferior if multi_process is zero.
16983
16984 2009-06-23 Aleksandar Ristovski <aristovski@qnx.com>
16985
16986 * server.c (process_serial_event): Add support for Z0 and Z1 packet.
16987 * target.h (target_ops): Comment for *_watchpoint to make it clear
16988 the functions can get types '0' and '1'.
16989
16990 2009-06-22 Aleksandar Ristovski <aristovski@qnx.com>
16991
16992 * linux-low.c (usr_fetch_inferior_registers): Remove check for regno 0.
16993 * proc-service.c (ps_lgetregs): Pass -1 to fetch all registers.
16994 * regcache.c (get_regcache): Likewise.
16995 * spu-low.c (spu_fetch_registers): Remove 0 to -1 conversion.
16996 * win32-low.c (child_fetch_inferior_registers): Remove check for
16997 regno 0.
16998
16999 2009-06-19 Aleksandar Ristovski <aristovski@qnx.com>
17000 Pedro Alves <pedro@codesourcery.com>
17001
17002 * target.h (struct target_ops) <supports_multi_process>: New
17003 callback.
17004 (target_supports_multi_process): New.
17005 * server.c (handle_query): Even if GDB reports support, only
17006 enable multi-process if the target also supports it. Report
17007 multi-process support only if the target backend supports it.
17008 * linux-low.c (linux_supports_multi_process): New function.
17009 (linux_target_ops): Install it as target_supports_multi_process
17010 callback.
17011
17012 2009-05-24 Doug Evans <dje@google.com>
17013
17014 Global renaming of find_thread_pid to find_thread_ptid.
17015 * server.h (find_thread_ptid): Renamed from find_thread_pid.
17016 * inferiors.c (find_thread_ptid): Renamed from find_thread_pid.
17017 All callers updated.
17018
17019 * linux-low.c (handle_extended_wait): Use linux_resume_one_lwp
17020 to resume the newly created thread, don't call ptrace (PTRACE_CONT)
17021 directly.
17022
17023 * linux-low.c (get_stop_pc): Print pc if debug_threads.
17024 (check_removed_breakpoint, linux_wait_for_lwp): Ditto.
17025 (linux_resume_one_lwp): Ditto.
17026
17027 2009-05-23 Doug Evans <dje@google.com>
17028
17029 * linux-low.c (linux_resume_one_lwp): Change type of first arg
17030 from struct inferior_list_entry * to struct lwp_info *.
17031 All callers updated.
17032
17033 2009-05-13 Doug Evans <dje@google.com>
17034
17035 * linux-x86-low.c: Don't include assert.h.
17036 (x86_siginfo_fixup): Use fatal, not assert.
17037 (x86_arch_setup): Fix comment.
17038
17039 2009-05-12 Doug Evans <dje@google.com>
17040
17041 Biarch support for i386/amd64 gdbserver.
17042 * Makefile.in (SFILES): Remove linux-i386-low.c, linux-x86-64-low.c.
17043 Add linux-x86-low.c.
17044 (linux-i386-low.o, linux-x86-64-low.o): Delete.
17045 (linux-x86-low.o): Add.
17046 * linux-x86-64-low.c: Delete.
17047 * linux-i386-low.c: Delete.
17048 * linux-x86-low.c: New file.
17049 * configure.srv (i?86-linux srv_tgtobj): Replace linux-i386-low.o with
17050 linux-x86-low.o.
17051 (x86_64-linux srv_tgtobj): Replace linux-x86-64-low.o with
17052 linux-x86-low.o.
17053 (x86_64-linux srv_regobj): Add reg-i386-linux.o.
17054 * linux-low.c: Include ansidecl.h, elf/common.h, elf/external.h.
17055 (linux_child_pid_to_exec_file): New function.
17056 (elf_64_header_p, elf_64_file_p): New functions.
17057 (siginfo_fixup): New function.
17058 (linux_xfer_siginfo): New local inf_siginfo. Call siginfo_fixup to
17059 give target a chance to convert layout.
17060 * linux-low.h (linux_target_ops): New member siginfo_fixup.
17061 (linux_child_pid_to_exec_file, elf_64_file_p): Declare.
17062
17063 2009-05-07 Doug Evans <dje@google.com>
17064
17065 * linux-low.c (regsets_fetch_inferior_registers): Fix memory leak.
17066 (regsets_store_inferior_registers): Ditto.
17067
17068 2009-05-06 Pedro Alves <pedro@codesourcery.com>
17069
17070 PR server/10048
17071
17072 * linux-low.c (must_set_ptrace_flags): Delete.
17073 (linux_create_inferior): Set `lwp->must_set_ptrace_flags' instead
17074 of the global.
17075 (linux_attach_lwp_1): Don't set PTRACE_SETOPTIONS here. Set
17076 `lwp->must_set_ptrace_flags' instead.
17077 (linux_wait_for_event_1): Set ptrace options here.
17078 (linux_wait_1): ... not here.
17079
17080 2009-04-30 Doug Evans <dje@google.com>
17081
17082 * inferiors.c (started_inferior_callback): New function.
17083 (attached_inferior_callback): New function.
17084 (have_started_inferiors_p, have_attached_inferiors_p): New functions.
17085 * server.c (print_started_pid, print_attached_pid): New functions.
17086 (detach_or_kill_for_exit): New function.
17087 (main): Call it instead of for_each_inferior (kill_inferior_callback).
17088 * server.h (have_started_inferiors_p): Declare.
17089 (have_attached_inferiors_p): Declare.
17090
17091 * inferiors.c (remove_process): Fix memory leak, free process.
17092 * linux-low.c (linux_remove_process): New function.
17093 (linux_kill): Call it instead of remove_process.
17094 (linux_detach, linux_wait_1): Ditto.
17095
17096 2009-04-19 Danny Backx <dannybackx@users.sourceforge.net>
17097
17098 * configure.srv: Add x86 Windows CE target.
17099
17100 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
17101
17102 * inferiors.c (get_thread_process): Make global.
17103 * server.h (get_thread_process): Add prototype.
17104 * thread-db.c (find_one_thread): Use get_thread_process
17105 instead of current_process.
17106 (thread_db_get_tls_address): Do not crash if called when
17107 thread layer is not yet initialized.
17108
17109 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
17110
17111 * remote-utils.c (prepare_resume_reply): Null-terminate packet.
17112 * spu-low.c (current_tid): Rename to ...
17113 (current_ptid): ... this.
17114 (fetch_ppc_register, fetch_ppc_memory, store_ppc_memory,
17115 spu_proc_xfer_spu, spu_resume, spu_request_interrupt): Use
17116 ptid_get_lwp (current_ptid) instead of current_tid.
17117 (spu_kill, spu_detach, spu_join, spu_wait): Use pid argument
17118 instead of current_tid. Use find_process_pid to verify pid
17119 argument is valid. Pass proper argument to remove_process.
17120 (spu_thread_alive): Compare current_ptid instead of current_tid.
17121 (spu_resume): Likewise.
17122
17123 2009-04-02 Pedro Alves <pedro@codesourcery.com>
17124
17125 * linux-low.c (usr_store_inferior_registers): Declare local `pid'
17126 variable.
17127
17128 2009-04-01 Pedro Alves <pedro@codesourcery.com>
17129
17130 Implement the multiprocess extensions, and add linux multiprocess
17131 support.
17132
17133 * server.h (ULONGEST): Declare.
17134 (struct ptid, ptid_t): New.
17135 (minus_one_ptid, null_ptid): Declare.
17136 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
17137 (ptid_get_tid, ptid_equal, ptid_is_pid): Declare.
17138 (struct inferior_list_entry): Change `id' type from unsigned from
17139 to ptid_t.
17140 (struct sym_cache, struct breakpoint, struct
17141 process_info_private): Forward declare.
17142 (struct process_info): Declare.
17143 (current_process): Declare.
17144 (all_processes): Declare.
17145 (initialize_inferiors): Declare.
17146 (add_thread): Adjust to use ptid_t.
17147 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): Ditto.
17148 (add_process, remove_process, find_thread_pid): Declare.
17149 (find_inferior_id): Adjust to use ptid_t.
17150 (cont_thread, general_thread, step_thread): Change type to ptid_t.
17151 (multi_process): Declare.
17152 (push_event): Adjust to use ptid_t.
17153 (read_ptid, write_ptid): Declare.
17154 (prepare_resume_reply): Adjust to use ptid_t.
17155 (clear_symbol_cache): Declare.
17156 * inferiors.c (all_processes): New.
17157 (null_ptid, minus_one_ptid): New.
17158 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
17159 (ptid_get_tid, ptid_equal, ptid_is_pid): New.
17160 (add_thread): Change unsigned long to ptid. Remove gdb_id
17161 parameter. Adjust.
17162 (thread_id_to_gdb_id, thread_to_gdb_id): Change unsigned long to ptid.
17163 (gdb_id_to_thread): Rename to ...
17164 (find_thread_pid): ... this. Change unsigned long to ptid.
17165 (gdb_id_to_thread_id, find_inferior_id): Change unsigned long to ptid.
17166 (loaded_dll, pull_pid_from_list): Adjust.
17167 (add_process, remove_process, find_process_pid)
17168 (get_thread_process, current_process, initialize_inferiors): New.
17169 * target.h (struct thread_resume) <thread>: Change type to ptid_t.
17170 (struct target_waitstatus) <related_pid>: Ditto.
17171 (struct target_ops) <kill, detach>: Add `pid' argument. Change
17172 return type to int.
17173 (struct target_ops) <join>: Add `pid' argument.
17174 (struct target_ops) <thread_alive>: Change pid's type to ptid_t.
17175 (struct target_ops) <wait>: Add `ptid' field. Change return type
17176 to ptid.
17177 (kill_inferior, detach_inferior, join_inferior): Add `pid' argument.
17178 (mywait): Add `ptid' argument. Change return type to ptid_t.
17179 (target_pid_to_str): Declare.
17180 * target.c (set_desired_inferior): Adjust to use ptids.
17181 (mywait): Add new `ptid' argument. Adjust.
17182 (target_pid_to_str): New.
17183 * mem-break.h (free_all_breakpoints): Declare.
17184 * mem-break.c (breakpoints): Delelete.
17185 (set_breakpoint_at, delete_breakpoint, find_breakpoint_at)
17186 (check_mem_read, check_mem_write, delete_all_breakpoints): Adjust
17187 to use per-process breakpoint list.
17188 (free_all_breakpoints): New.
17189 * remote-utils.c (struct sym_cache) <name>: Drop `const'.
17190 (symbol_cache, all_symbols_looked_up): Delete.
17191 (hexchars): New.
17192 (ishex, unpack_varlen_hex, write_ptid, hex_or_minus_one,
17193 read_ptid): New.
17194 (prepare_resume_reply): Change ptid argument's type from unsigned
17195 long to ptid_t. Adjust. Implement W;process and X;process.
17196 (free_sym_cache, clear_symbol_cache): New.
17197 (look_up_one_symbol): Adjust to per-process symbol cache. *
17198 * server.c (cont_thread, general_thread, step_thread): Change type
17199 to ptid_t.
17200 (attached): Delete.
17201 (multi_process): New.
17202 (last_ptid): Change type to ptid_t.
17203 (struct vstop_notif) <ptid>: Change type to ptid_t.
17204 (queue_stop_reply, push_event): Change `ptid' argument's type to
17205 ptid_t.
17206 (discard_queued_stop_replies): Add `pid' argument.
17207 (start_inferior): Adjust to use ptids. Adjust to mywait interface
17208 changes. Don't reference the `attached' global.
17209 (attach_inferior): Adjust to mywait interface changes.
17210 (handle_query): Adjust to use ptids. Parse GDB's qSupported
17211 features. Handle and report "multiprocess+". Handle
17212 "qAttached:PID".
17213 (handle_v_cont): Adjust to use ptids. Adjust to mywait interface
17214 changes.
17215 (handle_v_kill): New.
17216 (handle_v_stopped): Adjust to use target_pid_to_str.
17217 (handle_v_requests): Allow multiple attaches and runs when
17218 multiprocess extensions are in effect. Handle "vKill".
17219 (myresume): Adjust to use ptids.
17220 (queue_stop_reply_callback): Add `arg' parameter. Handle it.
17221 (handle_status): Adjust to discard_queued_stop_replies interface
17222 change.
17223 (first_thread_of, kill_inferior_callback)
17224 (detach_or_kill_inferior_callback, join_inferiors_callback): New.
17225 (main): Call initialize_inferiors. Adjust to use ptids, killing
17226 and detaching from all inferiors. Handle multiprocess packet
17227 variants.
17228 * linux-low.h: Include gdb_proc_service.h.
17229 (struct process_info_private): New.
17230 (struct linux_target_ops) <pid_of>: Use ptid_get_pid.
17231 <lwpid_of>: Use ptid_get_lwp.
17232 (get_lwp_thread): Adjust.
17233 (struct lwp_info): Add `dead' member.
17234 (find_lwp_pid): Declare.
17235 * linux-low.c (thread_db_active): Delete.
17236 (new_inferior): Adjust comment.
17237 (inferior_pid): Delete.
17238 (linux_add_process): New.
17239 (handle_extended_wait): Adjust.
17240 (add_lwp): Change unsigned long to ptid.
17241 (linux_create_inferior): Add process to processes table. Adjust
17242 to use ptids. Don't set new_inferior here.
17243 (linux_attach_lwp): Rename to ...
17244 (linux_attach_lwp_1): ... this. Add `initial' argument. Handle
17245 it. Adjust to use ptids.
17246 (linux_attach_lwp): New.
17247 (linux_attach): Add process to processes table. Don't set
17248 new_inferior here.
17249 (struct counter): New.
17250 (second_thread_of_pid_p, last_thread_of_process_p): New.
17251 (linux_kill_one_lwp): Add `args' parameter. Handle it. Adjust to
17252 multiple processes.
17253 (linux_kill): Add `pid' argument. Handle it. Adjust to multiple
17254 processes. Remove process from process table.
17255 (linux_detach_one_lwp): Add `args' parameter. Handle it. Adjust
17256 to multiple processes.
17257 (any_thread_of): New.
17258 (linux_detach): Add `pid' argument, and handle it. Remove process
17259 from processes table.
17260 (linux_join): Add `pid' argument. Handle it.
17261 (linux_thread_alive): Change unsighed long argument to ptid_t.
17262 Consider dead lwps as not being alive.
17263 (status_pending_p): Rename `dummy' argument to `arg'. Filter out
17264 threads we're not interested in.
17265 (same_lwp, find_lwp_pid): New.
17266 (linux_wait_for_lwp): Change `pid' argument's type from int to
17267 ptid_t. Adjust.
17268 (linux_wait_for_event): Rename to ...
17269 (linux_wait_for_event_1): ... this. Change `pid' argument's type
17270 from int to ptid_t. Adjust.
17271 (linux_wait_for_event): New.
17272 (linux_wait_1): Add `ptid' argument. Change return type to
17273 ptid_t. Adjust. Use last_thread_of_process_p. Remove processes
17274 that exit from the process table.
17275 (linux_wait): Add `ptid' argument. Change return type to ptid_t.
17276 Adjust.
17277 (mark_lwp_dead): New.
17278 (wait_for_sigstop): Adjust to use ptids. If a process exits while
17279 stopping all threads, mark its main lwp as dead.
17280 (linux_set_resume_request, linux_resume_one_thread): Adjust to use
17281 ptids.
17282 (fetch_register, usr_store_inferior_registers)
17283 (regsets_fetch_inferior_registers)
17284 (regsets_store_inferior_registers, linux_read_memory)
17285 (linux_write_memory): Inline `inferior_pid'.
17286 (linux_look_up_symbols): Adjust to use per-process
17287 `thread_db_active'.
17288 (linux_request_interrupt): Adjust to use ptids.
17289 (linux_read_auxv): Inline `inferior_pid'.
17290 (initialize_low): Don't reference thread_db_active.
17291 * gdb_proc_service.h (struct ps_prochandle) <pid>: Remove.
17292 * proc-service.c (ps_lgetregs): Use find_lwp_pid.
17293 (ps_getpid): Return the pid of the current inferior.
17294 * thread-db.c (proc_handle, thread_agent): Delete.
17295 (thread_db_create_event, thread_db_enable_reporting): Adjust to
17296 per-process data.
17297 (find_one_thread): Change argument type to ptid_t. Adjust to
17298 per-process data.
17299 (maybe_attach_thread): Adjust to per-process data and ptids.
17300 (thread_db_find_new_threads): Ditto.
17301 (thread_db_init): Ditto.
17302 * spu-low.c (spu_create_inferior, spu_attach): Add process to
17303 processes table. Adjust to use ptids.
17304 (spu_kill, spu_detach): Adjust interface. Remove process from
17305 processes table.
17306 (spu_join, spu_thread_alive): Adjust interface.
17307 (spu_wait): Adjust interface. Remove process from processes
17308 table. Adjust to use ptids.
17309 * win32-low.c (current_inferior_tid): Delete.
17310 (current_inferior_ptid): New.
17311 (debug_event_ptid): New.
17312 (thread_rec): Take a ptid. Adjust.
17313 (child_add_thread): Add `pid' argument. Adjust to use ptids.
17314 (child_delete_thread): Ditto.
17315 (do_initial_child_stuff): Add `attached' argument. Add process to
17316 processes table.
17317 (child_fetch_inferior_registers, child_store_inferior_registers):
17318 Adjust.
17319 (win32_create_inferior): Pass 0 to do_initial_child_stuff.
17320 (win32_attach): Pass 1 to do_initial_child_stuff.
17321 (win32_kill): Adjust interface. Remove process from processes
17322 table.
17323 (win32_detach): Ditto.
17324 (win32_join): Adjust interface.
17325 (win32_thread_alive): Take a ptid.
17326 (win32_resume): Adjust to use ptids.
17327 (get_child_debug_event): Ditto.
17328 (win32_wait): Adjust interface. Remove exiting process from
17329 processes table.
17330
17331 2009-04-01 Pedro Alves <pedro@codesourcery.com>
17332
17333 Non-stop mode support.
17334
17335 * server.h (non_stop): Declare.
17336 (gdb_client_data, handler_func): Declare.
17337 (delete_file_handler, add_file_handler, start_event_loop):
17338 Declare.
17339 (handle_serial_event, handle_target_event, push_event)
17340 (putpkt_notif): Declare.
17341 * target.h (enum resume_kind): New.
17342 (struct thread_resume): Replace `step' field by `kind' field.
17343 (TARGET_WNOHANG): Define.
17344 (struct target_ops) <wait>: Add `options' argument.
17345 <supports_non_stop, async, start_non_stop>: New fields.
17346 (target_supports_non_stop, target_async): New.
17347 (start_non_stop): Declare.
17348 (mywait): Add `options' argument.
17349 * target.c (mywait): Add `options' argument. Print child exit
17350 notifications here.
17351 (start_non_stop): New.
17352 * server.c (non_stop, own_buf, mem_buf): New globals.
17353 (struct vstop_notif): New.
17354 (notif_queue): New global.
17355 (queue_stop_reply, push_event, discard_queued_stop_replies)
17356 (send_next_stop_reply): New.
17357 (start_inferior): Adjust to use resume_kind. Adjust to mywait
17358 interface changes.
17359 (attach_inferior): In non-stop mode, don't wait for the target
17360 here.
17361 (handle_general_set): Handle QNonStop.
17362 (handle_query): When handling qC, return the current general
17363 thread, instead of the first thread of the list.
17364 (handle_query): If the backend supports non-stop mode, include
17365 QNonStop+ in the qSupported query response.
17366 (handle_v_cont): Adjust to use resume_kind. Handle resume_stop
17367 and non-stop mode.
17368 (handle_v_attach, handle_v_run): Handle non-stop mode.
17369 (handle_v_stopped): New.
17370 (handle_v_requests): Report support for vCont;t. Handle vStopped.
17371 (myresume): Adjust to use resume_kind. Handle non-stop.
17372 (queue_stop_reply_callback): New.
17373 (handle_status): Handle non-stop mode.
17374 (main): Clear non_stop flag on reconnection. Use the event-loop.
17375 Refactor serial protocol handling from here ...
17376 (process_serial_event): ... to this new function. When GDB
17377 selects any thread, select one here. In non-stop mode, wait until
17378 GDB acks all pending events before exiting.
17379 (handle_serial_event, handle_target_event): New.
17380 * remote-utils.c (remote_open): Install remote_desc in the event
17381 loop.
17382 (remote_close): Remove remote_desc from the event loop.
17383 (putpkt_binary): Rename to...
17384 (putpkt_binary_1): ... this. Add `is_notic' argument. Handle it.
17385 (putpkt_binary): New as wrapper around putpkt_binary_1.
17386 (putpkt_notif): New.
17387 (prepare_resume_reply): In non-stop mode, don't change the
17388 general_thread.
17389 * event-loop.c: New.
17390 * Makefile.in (OBJ): Add event-loop.o.
17391 (event-loop.o): New rule.
17392
17393 * linux-low.h (pid_of): Moved here.
17394 (lwpid_of): New.
17395 (get_lwp_thread): Use lwpid_of.
17396 (struct lwp_info): Delete `lwpid' field. Add `suspended' field.
17397 * linux-low.c (pid_of): Delete.
17398 (inferior_pid): Use lwpid_of.
17399 (linux_event_pipe): New.
17400 (target_is_async_p): New.
17401 (delete_lwp): New.
17402 (handle_extended_wait): Use lwpid_of.
17403 (add_lwp): Don't set lwpid field.
17404 (linux_attach_lwp): Adjust debug output. Use lwpid_of.
17405 (linux_kill_one_lwp): If killing a running lwp, stop it first.
17406 Use lwpid_of. Adjust to linux_wait_for_event interface changes.
17407 (linux_detach_one_lwp): If detaching from a running lwp, stop it
17408 first. Adjust to linux_wait_for_event interface changes. Use
17409 lwpid_of.
17410 (linux_detach): Don't delete the main lwp here.
17411 (linux_join): Use my_waitpid. Avoid signal_pid. Use lwpid_of.
17412 (status_pending_p): Don't consider explicitly suspended lwps.
17413 (linux_wait_for_lwp): Take an integer pid instead of a lwp_info
17414 pointer. Add OPTIONS argument. Change return type to int. Use
17415 my_waitpid instead of sleeping. Handle WNOHANG. Use lwpid_of.
17416 (linux_wait_for_event): Take an integer pid instead of a lwp_info
17417 pointer. Add status pointer argument. Return a pid instead of a
17418 status. Use lwpid_of. Adjust to linux_wait_for_lwp interface
17419 changes. In non-stop mode, don't switch to a random thread.
17420 (linux_wait): Rename to...
17421 (linux_wait_1): ... this. Add target_options argument, and handle
17422 it. Adjust to use resume_kind. Use lwpid_of. In non-stop mode,
17423 don't handle the continue thread. Handle TARGET_WNOHANG. Merge
17424 clean exit and signal exit code. Don't stop all threads in
17425 non-stop mode. In all-stop mode, only stop all threads when
17426 reporting a stop to GDB. Handle explicit thread stop requests.
17427 (async_file_flush, async_file_mark): New.
17428 (linux_wait): New.
17429 (send_sigstop): Use lwpid_of.
17430 (wait_for_sigstop): Use lwpid_of. Adjust to linux_wait_for_event
17431 interface changes. In non-stop mode, don't switch to a random
17432 thread.
17433 (linux_resume_one_lwp): Use lwpid_of.
17434 (linux_continue_one_thread, linux_queue_one_thread): Merge into ...
17435 (linux_resume_one_thread): ... this. Handle resume_stop. In
17436 non-stop mode, don't look for pending flag in all threads.
17437 (resume_status_pending_p): Don't consider explicitly suspended
17438 threads.
17439 (my_waitpid): Reimplement. Emulate __WALL.
17440 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
17441 Use lwpid_of.
17442 (sigchld_handler, linux_supports_non_stop, linux_async)
17443 (linux_start_non_stop): New.
17444 (linux_target_ops): Register linux_supports_non_stop, linux_async
17445 and linux_start_non_stop.
17446 (initialize_low): Install SIGCHLD handler.
17447 * thread-db.c (thread_db_create_event, find_one_thread)
17448 (thread_db_get_tls_address): Use lwpid_of.
17449 * win32-low.c (win32_detach): Adjust to use resume_kind.
17450 (win32_wait): Add `options' argument.
17451 * spu-low.c (spu_resume): Adjust to use resume_kind.
17452 (spu_wait): Add `options' argument.
17453
17454 2009-04-01 Pedro Alves <pedro@codesourcery.com>
17455
17456 Decouple target code from remote protocol.
17457
17458 * target.h (enum target_waitkind): New.
17459 (struct target_waitstatus): New.
17460 (struct target_ops) <wait>: Return an unsigned long. Take a
17461 target_waitstatus pointer instead of a char pointer.
17462 (mywait): Likewise.
17463 * target.c (mywait): Change prototype to return an unsigned long.
17464 Take a target_waitstatus pointer instead of a char pointer. Adjust.
17465 * server.h (thread_from_wait, old_thread_from_wait): Delete
17466 declarations.
17467 (prepare_resume_reply): Change prototype to take a
17468 target_waitstatus.
17469 * server.c (thread_from_wait, old_thread_from_wait): Delete.
17470 (last_status, last_ptid): New.
17471 (start_inferior): Remove "statusptr" argument. Adjust. Return a
17472 pid instead of a signal.
17473 (attach_inferior): Remove "status" and "signal" parameters.
17474 Adjust.
17475 (handle_query): For qGetTLSAddr, parse the thread id with strtol,
17476 not as an address.
17477 (handle_v_cont, handle_v_attach, handle_v_run, handle_v_kill)
17478 (handle_v_requests, myresume): Remove "status" and "signal"
17479 parameters. Adjust.
17480 (handle_status): New.
17481 (main): Delete local `status'. Adjust.
17482 * remote-utils.c: Include target.h.
17483 (prepare_resume_reply): Change prototype to take a
17484 target_waitstatus. Adjust.
17485
17486 * linux-low.c (linux_wait): Adjust to new target_ops->wait
17487 interface.
17488 * spu-low.c (spu_wait): Adjust.
17489 * win32-low.c (enum target_waitkind, struct target_waitstatus):
17490 Delete.
17491 (win32_wait): Adjust.
17492
17493 2009-04-01 Pedro Alves <pedro@codesourcery.com>
17494
17495 * target.h (struct thread_resume): Delete leave_stopped member.
17496 (struct target_ops): Add a `n' argument to the `resume' callback.
17497 * server.c (start_inferior): Adjust.
17498 (handle_v_cont, myresume): Adjust.
17499 * linux-low.c (check_removed_breakpoint): Adjust to resume
17500 interface change, and to removed leave_stopped field.
17501 (resume_ptr): Delete.
17502 (struct thread_resume_array): New.
17503 (linux_set_resume_request): Add new `arg' parameter. Adjust to
17504 resume interface change.
17505 (linux_continue_one_thread, linux_queue_one_thread)
17506 (resume_status_pending_p): Check if the resume field is NULL
17507 instead of checking the leave_stopped member.
17508 (linux_resume): Adjust to the target resume interface change.
17509 * spu-low.c (spu_resume): Adjust to the target resume interface
17510 change.
17511 * win32-low.c (win32_detach, win32_resume): Ditto.
17512
17513 2009-04-01 Pedro Alves <pedro@codesourcery.com>
17514
17515 * linux-low.c (linux_wait_for_event): Don't clear the `stepping'
17516 flag.
17517 (wait_for_sigstop): Don't leave a finished single-step SIGTRAP
17518 pending.
17519 (linux_continue_one_thread): Only preserve the stepping flag if
17520 there's a pending breakpoint.
17521
17522 2009-03-31 Pedro Alves <pedro@codesourcery.com>
17523
17524 * server.c (main): After the inferior having exited, call
17525 remote_close before exiting gdbserver.
17526
17527 2009-03-25 Thiago Jung Bauermann <bauerman@br.ibm.com>
17528
17529 Fix size of FPSCR in Power 7 processors.
17530 * linux-ppc-low.c (PPC_FEATURE_ARCH_2_05): Remove #define.
17531 (PPC_FEATURE_HAS_DFP): New #define.
17532 (ppc_arch_setup): Check for DFP feature instead of ISA 2.05 to decide on
17533 size of the FPSCR.
17534
17535 2009-03-23 Pedro Alves <pedro@codesourcery.com>
17536
17537 * server.c (handle_query) Whitespace and formatting.
17538
17539 2009-03-22 Pedro Alves <pedro@codesourcery.com>
17540
17541 * i387-fp.c, linux-arm-low.c, linux-cris-low.c,
17542 linux-crisv32-low.c, linux-i386-low.c, linux-low.c,
17543 linux-mips-low.c, linux-s390-low.c, linux-sparc-low.c,
17544 linux-x86-64-low.c, linux-xtensa-low.c, proc-service.c,
17545 regcache.c, remote-utils.c, server.c, spu-low.c, target.h,
17546 thread-db.c, win32-low.c, xtensa-xtregs.c, gdbreplay.c,
17547 Makefile.in, configure.ac: Fix whitespace throughout.
17548 * configure: Regenerate.
17549
17550 2009-03-22 Pedro Alves <pedro@codesourcery.com>
17551
17552 * inferiors.c (find_inferior): Make it safe for the callback
17553 function to delete the currently iterated inferior.
17554
17555 2009-03-22 Pedro Alves <pedro@codesourcery.com>
17556
17557 * Makefile.in (linuw_low_h): Move higher.
17558 (thread-db.o): Depend on $(linux_low_h).
17559
17560 2009-03-17 Pedro Alves <pedro@codesourcery.com>
17561
17562 Rename "process" to "lwp" throughout.
17563
17564 * linux-low.c (all_processes): Rename to...
17565 (all_lwps): ... this.
17566 (inferior_pid, handle_extended_wait, get_stop_pc): Adjust.
17567 (add_process): Rename to ...
17568 (add_lwp): ... this. Adjust.
17569 (linux_create_inferior): Adjust.
17570 (linux_attach_lwp): Adjust.
17571 (linux_attach): Adjust.
17572 (linux_kill_one_process): Rename to ...
17573 (linux_kill_one_lwp): ... this. Adjust.
17574 (linux_kill): Adjust.
17575 (linux_detach_one_process): Rename to ...
17576 (linux_detach_one_lwp): ... this. Adjust.
17577 (linux_detach): Adjust.
17578 (check_removed_breakpoint): Adjust.
17579 (status_pending_p): Adjust.
17580 (linux_wait_for_process): Rename to ...
17581 (linux_wait_for_lwp): ... this. Adjust.
17582 (linux_wait_for_event): Adjust.
17583 (send_sigstop): Adjust.
17584 (wait_for_sigstop): Adjust.
17585 (stop_all_processes): Rename to ...
17586 (stop_all_lwps): ... this.
17587 (linux_resume_one_process): Rename to ...
17588 (linux_resume_one_lwp): ... this. Adjust.
17589 (linux_set_resume_request, linux_continue_one_thread)
17590 (linux_queue_one_thread, resume_status_pending_p)
17591 (usr_store_inferior_registers, regsets_store_inferior_registers)
17592 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
17593 Adjust.
17594 * linux-low.h (get_process): Rename to ...
17595 (get_lwp): ... this. Adjust.
17596 (get_thread_process): Rename to ...
17597 (get_thread_lwp): ... this. Adjust.
17598 (get_process_thread): Rename to ...
17599 (get_lwp_thread): ... this. Adjust.
17600 (struct process_info): Rename to ...
17601 (struct lwp_info): ... this.
17602 (all_processes): Rename to ...
17603 (all_lwps): ... this.
17604 * proc-service.c (ps_lgetregs): Adjust.
17605 * thread-db.c (thread_db_create_event, find_one_thread)
17606 (maybe_attach_thread, thread_db_get_tls_address): Adjust.
17607
17608 2009-03-14 Pedro Alves <pedro@codesourcery.com>
17609
17610 * server.c (handle_query): Handle "qAttached".
17611
17612 2009-03-13 Nathan Sidwell <nathan@codesourcery.com>
17613
17614 * Makefile.in, hostio-errno.c, errno.c, xtensa-xtregs.c: Change to
17615 GPLv3, update license URL.
17616
17617 2009-03-01 Doug Evans <dje@google.com>
17618
17619 * Makefile.in (INCLUDE_CFLAGS): Add -I$(srcdir)/../common.
17620 (server_h): Add gdb_signals.h.
17621 (signals.o): Update.
17622 * server.h (target_signal_from_host,target_signal_to_host_p)
17623 (target_signal_to_host,target_signal_to_name): Moved to gdb_signals.h.
17624
17625 2009-02-14 Pierre Muller <muller@ics.u-strasbg.fr>
17626
17627 * remote-utils.c (getpkt): Also generate remote-debug
17628 information if noack_mode is set.
17629
17630 2009-02-06 Pedro Alves <pedro@codesourcery.com>
17631
17632 * server.c (handle_query): Report qXfer:siginfo:read and
17633 qXfer:siginfo:write as supported and handle them.
17634 * target.h (struct target_ops) <qxfer_siginfo>: New field.
17635 * linux-low.c (linux_xfer_siginfo): New.
17636 (linux_target_ops): Set it.
17637
17638 2009-01-26 Pedro Alves <pedro@codesourcery.com>
17639
17640 * server.c (gdbserver_usage): Mention --remote-debug.
17641 (main): Accept '--remote-debug' switch.
17642
17643 2009-01-18 Doug Evans <dje@google.com>
17644
17645 * regcache.c (new_register_cache): No need to check result of xcalloc.
17646 * server.c (handle_search_memory): Back out calls to xmalloc,
17647 result is checked and error is returned to user upon failure.
17648 (handle_query): Ditto. Add more checks for result of malloc.
17649 (handle_v_cont): Check result of malloc, report error back to
17650 user upon failure.
17651 (handle_v_run): Ditto. Call freeargv.
17652 * server.h (freeargv): Declare.
17653 * utils.c (freeargv): New fn.
17654
17655 2009-01-15 Doug Evans <dje@google.com>
17656
17657 * gdbreplay.c (perror_with_name): Make arg const char *.
17658 * server.h (target_signal_to_name): Make return type const char *.
17659 * thread-db.c (thread_db_err_str): Make return type const char *.
17660 * utils.c (perror_with_name): Make arg const char *.
17661
17662 2009-01-14 Pedro Alves <pedro@codesourcery.com>
17663
17664 * win32-low.c (get_child_debug_event): Issue a final DBG_CONTINUE
17665 when handling a EXIT_PROCESS_DEBUG_EVENT.
17666
17667 2009-01-06 Joel Brobecker <brobecker@adacore.com>
17668
17669 * gdbreplay.c (gdbreplay_version): Update copyright year.
17670 * server.c (gdbserver_version): Likewise.
17671
17672 2009-01-05 Doug Evans <dje@google.com>
17673
17674 * linux-low.c (linux_attach_lwp): Add some comments/fixmes.
17675 (handle_extended_wait): Improve comment.
17676
17677 2008-12-13 Doug Evans <dje@google.com>
17678
17679 * utils.c (xmalloc,xcalloc,xstrdup): New fns.
17680 * server.h (ATTR_MALLOC): New macro.
17681 (xmalloc,xcalloc,xstrdup): Declare.
17682 * hostio.c: Replace malloc,calloc,strdup with xmalloc,xcalloc,xstrdup.
17683 * inferiors.c: Ditto.
17684 * linux-low.c: Ditto.
17685 * mem-break.c: Ditto.
17686 * regcache.c: Ditto.
17687 * remote-utils.c: Ditto.
17688 * server.c: Ditto.
17689 * target.c: Ditto.
17690 * win32-low.c: Ditto.
17691
17692 2008-12-12 Doug Evans <dje@google.com>
17693
17694 * linux-low.c (linux_wait_for_process): Don't clobber current_inferior
17695 in debugging printf.
17696
17697 * linux-low.c (handle_extended_wait): Simplify, use my_waitpid.
17698
17699 2008-12-09 Doug Evans <dje@google.com>
17700
17701 * linux-low.h (struct process_info): Delete member tid, unused.
17702 * thread-db.c (find_one_thread): Update.
17703 (maybe_attach_thread): Update.
17704
17705 2008-12-02 Pedro Alves <pedro@codesourcery.com>
17706
17707 * target.h (struct target_ops): Add qxfer_osdata member.
17708 * linux-low.c: Include ctype.h and pwd.h and sys/types.h
17709 and dirent.h.
17710 (linux_qxfer_osdata): New functions.
17711 (linux_target_ops): Register linux_qxfer_osdata as qxfer_osdata
17712 callback.
17713 * server.c (handle_query): Handle "qXfer:osdata:read:".
17714 * remote-utils.c (buffer_grow, buffer_free, buffer_init, buffer_finish)
17715 (buffer_xml_printf): New functions.
17716 * server.h (struct buffer): New.
17717 (buffer_grow_str, buffer_grow_str0): New macros.
17718 (buffer_grow, buffer_free, buffer_init, buffer_finish)
17719 (buffer_xml_printf): Declare.
17720
17721 2008-11-24 Doug Evans <dje@google.com>
17722
17723 * Makefile.in (VERSION,DIST,LINT,LINTFLAGS): Delete, unused.
17724
17725 2008-11-24 Daniel Jacobowitz <dan@codesourcery.com>
17726
17727 * server.c (handle_v_run): Always use the supplied argument list.
17728
17729 2008-11-19 Bob Wilson <bob.wilson@acm.org>
17730
17731 * xtensa-xtregs.c (XTENSA_ELF_XTREG_SIZE): Change to 4.
17732 (xtensa_regmap_table): Add entry for scompare1.
17733
17734 2008-11-18 Thiago Jung Bauermann <bauerman@br.ibm.com>
17735
17736 * Makefile.in (powerpc-isa205-32l.o, powerpc-isa205-32l.c,
17737 powerpc-isa205-altivec32l.o, powerpc-isa205-altivec32l.c,
17738 powerpc-isa205-vsx32l.o, powerpc-isa205-vsx32l.c,
17739 powerpc-isa205-64l.o, powerpc-isa205-64l.c,
17740 powerpc-isa205-altivec64l.o, powerpc-isa205-altivec64l.c,
17741 powerpc-isa205-vsx64l.o, powerpc-isa205-vsx64l.c): New targets.
17742 * configure.srv (powerpc*-*-linux*): Add ISA 2.05 object files and
17743 XML target descriptions.
17744 * linux-ppc-low.c (ppc_arch_setup): Init registers with 64-bit FPSCR
17745 when inferior is running on an ISA 2.05 or later processor. Add
17746 special case to return offset for full 64-bit slot of FPSCR when
17747 in 32-bits.
17748
17749 2008-11-14 Daniel Gutson <dgutson@codesourcery.com>
17750
17751 * Makefile.in (SFILES, clean): Added sparc64 files.
17752 (reg-sparc64.o, reg-sparc64.c): New.
17753 * configure.srv (sparc*-*-linux*): New configuration.
17754 * linux-low.c (regsets_fetch_inferior_registers): Swap ptrace
17755 syscall arguments for SPARC.
17756 (regsets_store_inferior_registers): Likewise.
17757 * linux-sparc-low.c: New file.
17758
17759 2008-10-21 Doug Evans <dje@google.com>
17760
17761 * Makefile.in (BFD_DIR,BFD,BFD_SRC,BFD_CFLAGS): Delete.
17762 (READLINE_DIR,READLINE_DEP): Delete.
17763 (INTERNAL_CFLAGS): Update.
17764 (LINTFLAGS): Update.
17765
17766 2008-10-10 Pedro Alves <pedro@codesourcery.com>
17767
17768 * server.c (handle_v_run): If GDB didn't specify an argv, use the
17769 whole argv from the last run, not just argv[0].
17770
17771 2008-09-08 Pedro Alves <pedro@codesourcery.com>
17772
17773 * regcache.c (new_register_cache): Return NULL if the register
17774 cache size isn't known yet.
17775 (free_register_cache): Avoid dereferencing a NULL regcache.
17776
17777 2008-09-04 Daniel Jacobowitz <dan@codesourcery.com>
17778
17779 * configure.srv: Merge MIPS and MIPS64.
17780
17781 2008-08-24 Maciej W. Rozycki <macro@linux-mips.org>
17782
17783 * Makefile.in (uninstall): Apply $(EXEEXT) too.
17784
17785 2008-08-18 Luis Machado <luisgpm@br.ibm.com>
17786
17787 * Makefile.in: Add required vsx dependencies.
17788
17789 * linux-ppc-low: Define PPC_FEATURE_HAS_VSX.
17790 Declare init_registers_powerpc_vsx32l.
17791 Declare init_registers_powerpc_vsx64l.
17792 Define PTRACE_GETVSXREGS and PTRACE_SETVSXREGS.
17793 (ppc_arch_setup): Check for VSX in hwcap.
17794 (ppc_fill_vsxregset): New function.
17795 (ppc_store_vsxregset): New function.
17796 Add new VSX entry in regset_info target_regsets.
17797
17798 * configure.srv: Add new VSX dependencies.
17799
17800 2008-08-12 Pedro Alves <pedro@codesourcery.com>
17801
17802 * remote-utils.c (noack_mode, transport_is_reliable): New globals.
17803 (remote_open): Set or clear transport_is_reliable.
17804 (putpkt_binary): Don't expect acks in noack mode.
17805 (getpkt): Don't send ack/nac in noack mode.
17806 * server.c (handle_general_set): Handle QStartNoAckMode.
17807 (handle_query): If connected by tcp pass QStartNoAckMode+ in
17808 qSupported.
17809 (main): Reset noack_mode on every connection.
17810 * server.h (noack_mode): Declare.
17811
17812 2008-08-07 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
17813
17814 * Makefile.in (GDBREPLAY_OBS): New variable.
17815 (gdbreplay$(EXEEXT)): Use it to avoid unportable $^.
17816
17817 2008-08-05 Ulrich Weigand <uweigand@de.ibm.com>
17818 Daniel Jacobowitz <dan@codesourcery.com>
17819
17820 * linux-low.c (linux_resume_one_process): Ignore ESRCH.
17821 (usr_store_inferior_registers): Likewise.
17822 (regsets_store_inferior_registers): Likewise.
17823
17824 2008-07-31 Rolf Jansen <rj@surtec.com>
17825 Pedro Alves <pedro@codesourcery.com>
17826
17827 * configure.ac: Check for memmem declaration.
17828 * server.c [HAVE_MALLOC_H]: Include malloc.h.
17829 (disable_packet_vCont, disable_packet_Tthread, disable_packet_qC)
17830 (disable_packet_qfThreadInfo): Unconditionally compile.
17831 * server.h [!HAVE_DECL_MEMMEM]: Declare memmem.
17832 * configure, config.in: Regenerate.
17833
17834 2008-07-28 Doug Kwan <dougkwan@google.com>
17835
17836 * linux-low.c (sys/dir.h, sys/user.h): Remove includes.
17837 (linux_write_memory): Remove declaration of errno.
17838
17839 2008-07-12 Ulrich Weigand <uweigand@de.ibm.com>
17840
17841 * linux-low.c (handle_extended_wait): Do not use "status"
17842 variable uninitialized.
17843
17844 2008-07-07 Pedro Alves <pedro@codesourcery.com>
17845
17846 * server.c (handle_v_attach): Inhibit reporting dll changes.
17847
17848 2008-06-27 Pedro Alves <pedro@codesourcery.com>
17849
17850 * remote-utils.c (prepare_resume_reply): If requested, don't
17851 output "thread:TID" in the T stop reply.
17852
17853 * server.c (disable_packet_vCont, disable_packet_Tthread)
17854 (disable_packet_qC, disable_packet_qfThreadInfo): New globals.
17855 (handle_query): If requested, disable support for qC, qfThreadInfo
17856 and qsThreadInfo.
17857 (handle_v_requests): If requested, disable support for vCont.
17858 (gdbserver_show_disableable): New.
17859 (main): Handle --disable-packet and --disable-packet=LIST.
17860
17861 * server.h (disable_packet_vCont, disable_packet_Tthread)
17862 (disable_packet_qC, disable_packet_qfThreadInfo): Declare.
17863
17864 2008-06-20 Carlos O'Donell <carlos@codesourcery.com>
17865
17866 * server.c (gdbserver_usage): Mention --version.
17867
17868 2008-06-06 Daniel Jacobowitz <dan@codesourcery.com>
17869
17870 * Makefile.in (gdbreplay.o): New rule.
17871
17872 2008-06-06 Joseph Myers <joseph@codesourcery.com>
17873
17874 * gdbreplay.c (gdbreplay_version): Say gdbreplay in version
17875 message, not gdbserver.
17876
17877 2008-06-05 Vladimir Prus <vladimir@codesourcery.com>
17878 Nathan Sidwell <nathan@codesourcery.com>
17879 Joseph Myers <joseph@codesourcery.com>
17880
17881 * acinclude.m4: Include ../../config/acx.m4.
17882 * configure.ac: Use ACX_PKGVERSION and ACX_BUGURL.
17883 * configure, config.in: Regenerate.
17884 * Makefile.in (gdbreplay$(EXEEXT)): Add version.o.
17885 * server.c (gdbserver_version): Print PKGVERSION.
17886 (gdbsrever_usage): Add stream parameter. Print REPORT_BUGS_TO.
17887 (main): Adjust gdbserver_usage calls.
17888 * gdbreplay.c (version, host_name): Add declarations.
17889 (gdbreplay_version, gdbreplay_usage): New.
17890 (main): Accept --version and --help options.
17891
17892 2008-06-04 Daniel Jacobowitz <dan@codesourcery.com>
17893
17894 * linux-arm-low.c (thumb_breakpoint, thumb_breakpoint_len): New.
17895 (arm_breakpoint_at): Handle Thumb.
17896 (the_low_target): Add comment.
17897
17898 2008-05-29 Ulrich Weigand <uweigand@de.ibm.com>
17899
17900 * linux-ppc-low.c (ppc_collect_ptrace_register): Clear buffer.
17901
17902 2008-05-09 Doug Evans <dje@google.com>
17903
17904 * server.h (decode_search_memory_packet): Declare.
17905 * remote-utils.c (decode_search_memory_packet): New fn.
17906 * server.c (handle_search_memory_1): New fn.
17907 (handle_search_memory): New fn.
17908 (handle_query): Process qSearch:memory packets.
17909
17910 2008-05-08 Ulrich Weigand <uweigand@de.ibm.com>
17911
17912 * regcache.c (registers_length): Remove.
17913 (set_register_cache): Verify that PBUFSIZ is large enough to hold a
17914 full register packet.
17915 * regcache.h (registers_length): Remove prototype.
17916 * server.h (PBUFSIZ): Define to 16384.
17917
17918 2008-05-03 Ulrich Weigand <uweigand@de.ibm.com>
17919
17920 * configure.srv (powerpc*-*-linux*): Set srv_regobj to
17921 powerpc-32l.o, powerpc-altivec32l.o, powerpc-e500l.o,
17922 powerpc-64l.o, and powerpc-altivec64l.o.
17923 Remove rs6000/powerpc-32.xml, rs6000/powerpc-64.xml, and
17924 rs6000/powerpc-e500.xml; add rs6000/powerpc-32l.xml,
17925 rs6000/powerpc-altivec32l.xml, rs6000/powerpc-e500l.xml,
17926 rs6000/powerpc-64l.xml, rs6000/powerpc-altivec64l.xml,
17927 rs6000/power-linux.xml, and rs6000/power64-linux.xml
17928 to srv_xmlfiles.
17929
17930 * Makefile.in (reg-ppc.o, reg-ppc.c): Remove, replace by ...
17931 (powerpc-32l.o, powerpc-32l.c): ... these new rules.
17932 (powerpc-32.o, powerpc-32.c): Remove, replace by ...
17933 (powerpc-altivec32l.o, powerpc-altivec32l.c): ... these new rules.
17934 (powerpc-e500.o, powerpc-e500.c): Remove, replace by ...
17935 (powerpc-e500l.o, powerpc-e500l.c): ... these new rules.
17936 (reg-ppc64.o, reg-ppc64.c): Remove, replace by ...
17937 (powerpc-64l.o, powerpc-64l.c): ... these new rules.
17938 (powerpc-64.o, powerpc-64.c): Remove, replace by ...
17939 (powerpc-altivec64l.o, powerpc-altivec64l.c): ... these new rules.
17940 (clean): Update.
17941
17942 * linux-ppc-low.c (init_registers_ppc): Remove, replace by ...
17943 (init_registers_powerpc_32l): ... this new prototype.
17944 (init_registers_powerpc_32): Remove, replace by ...
17945 (init_registers_powerpc_altivec32l): ... this new prototype.
17946 (init_registers_powerpc_e500): Remove, replace by ...
17947 (init_registers_powerpc_e500l): ... this new prototype.
17948 (init_registers_ppc64): Remove, replace by ...
17949 (init_registers_powerpc_64l): ... this new prototype.
17950 (init_registers_powerpc_64): Remove, replace by ...
17951 (init_registers_powerpc_altivec64l): ... this new prototype.
17952 (ppc_num_regs): Set to 73.
17953 (PT_ORIG_R3, PT_TRAP): Define if necessary.
17954 (ppc_regmap, ppc_regmap_e500): Add values for orig_r3 and trap.
17955 (ppc_cannot_store_register): Handle orig_r3 and trap.
17956 (ppc_arch_setup): Update init_registers_... calls.
17957 (ppc_fill_gregset): Handle orig_r3 and trap.
17958
17959 * inferiors.c (clear_inferiors): Reset current_inferior.
17960
17961 2008-04-23 Paolo Bonzini <bonzini@gnu.org>
17962
17963 * acinclude.m4: Add override.m4.
17964 * configure: Regenerate.
17965
17966 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
17967
17968 * linux-ppc-low.c (ppc_arch_setup): Reset ppc_hwcap after the
17969 initial call to init_register_ppc64.
17970
17971 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
17972
17973 * configure.srv (powerpc64-*-linux*, powerpc-*-linux*): Merge into
17974 single powerpc*-*-linux* case.
17975 (s390-*-linux*, s390x-*-linux*): Merge into single s390*-*-linux* case.
17976
17977 2008-04-17 Ulrich Weigand <uweigand@de.ibm.com>
17978
17979 * configure.srv [powerpc64-*-linux*]: Remove powerpc-e500.o from
17980 srv_regobj. Remove rs6000/powerpc-e500.xml and rs6000/power-spe.xml
17981 from reg_xmlfiles.
17982 * linux-ppc-low.c: Include <elf.h>.
17983 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Define.
17984 (ppc_hwcap): New global variable.
17985 (ppc_regmap): Remove __SPE__ #ifdef sections.
17986 (ppc_regmap_e500): New global variable.
17987 (ppc_cannot_store_register): Update __SPE__ special case.
17988 (ppc_get_hwcap): New function.
17989 (ppc_arch_setup): Use it to determine whether inferior supports
17990 AltiVec or SPE registers. Set the_low_target.regmap if appropriate.
17991 (ppc_fill_vrregset, ppc_store_vrregset): Define unconditionally.
17992 Do not access registers if target does not support AltiVec.
17993 (ppc_fill_evrregset, ppc_store_evrregset): Define unconditionally.
17994 Do not access registers if target does not support SPE.
17995 (target_regsets): Unconditionally include AltiVec and SPE regsets.
17996
17997 2008-04-17 Daniel Jacobowitz <dan@codesourcery.com>
17998
17999 * linux-low.c (disabled_regsets, num_regsets): New.
18000 (use_regsets_p): Delete.
18001 (linux_wait_for_process): Clear disabled_regsets.
18002 (regsets_fetch_inferior_registers): Check and set it.
18003 (regsets_store_inferior_registers): Likewise.
18004 (linux_fetch_registers, linux_store_registers): Do not use
18005 use_regsets_p.
18006 (initialize_low): Allocate disabled_regsets.
18007
18008 2008-04-14 Daniel Jacobowitz <dan@codesourcery.com>
18009
18010 * Makefile.in (LIBOBJS): New.
18011 (OBS): Use LIBOBJS.
18012 (memmem.o): New rule.
18013 * configure.ac: Use AC_CONFIG_LIBOBJ_DIR and check for memmem.
18014 * configure: Regenerated.
18015
18016 2008-04-04 Ulrich Weigand <uweigand@de.ibm.com>
18017
18018 * server.c (handle_query): Never return "unsupported" for
18019 qXfer:features:read queries.
18020
18021 2008-03-27 Ulrich Weigand <uweigand@de.ibm.com>
18022
18023 * server.c (get_features_xml): Fix inverted condition.
18024 (handle_query): Always support qXfer:feature:read.
18025
18026 2008-03-10 Daniel Jacobowitz <dan@codesourcery.com>
18027
18028 * server.c (wrapper_argv): New.
18029 (start_inferior): Handle wrapper_argv. If set, expect an extra
18030 trap.
18031 (gdbserver_usage): Document --wrapper.
18032 (main): Parse --wrapper.
18033
18034 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
18035
18036 * configure.srv [powerpc64-*-linux*]: Add all files mentioned for
18037 powerpc-*-linux* to srv_regobj and reg_xmlfiles.
18038 * linux-ppc-low.c (ppc_get_pc): Support bi-arch operation.
18039 (ppc_set_pc): Likewise.
18040 (ppc_arch_setup): New function.
18041 (ppc_fill_gregset): Call ppc_collect_ptrace_register instead
18042 of collect_register.
18043 (the_low_target): Use ppc_arch_setup as arch_setup initializer.
18044
18045 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
18046
18047 * configure.srv [powerpc64-*-linux*]: Use linux-ppc-low.o
18048 instead of linux-ppc64-low.o.
18049 * linux-ppc64-low.c: Remove file.
18050 * Makefile.in (SFILES): Remove linux-ppc64-low.c.
18051 (linux-ppc64-low.o): Remove rule.
18052
18053 * linux-ppc-low.c (init_registers_ppc64): Add prototype.
18054 (init_registers_powerpc_64): Likewise.
18055 (ppc_regmap): Conditionally define depending on __powerpc64__.
18056 (ppc_cannot_store_register): Do not special-case "fpscr" when
18057 compiled on __powerpc64__.
18058 (ppc_collect_ptrace_register): New function.
18059 (ppc_supply_ptrace_register): New function.
18060 (ppc_breakpoint): Change type to "unsigned int".
18061 (ppc_breakpoint_at): Change type of "insn" to "unsigned int".
18062 (the_low_target): Conditionally provide initializers for the
18063 arch_setup member depending on __powerpc64__. Install
18064 collect_ptrace_register and supply_ptrace_register members.
18065
18066 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
18067
18068 * regcache.h (gdbserver_xmltarget): Add extern declaration.
18069 * server.c (gdbserver_xmltarget): Define.
18070 (get_features_xml): Use it to replace "target.xml" and arch_string.
18071
18072 * configure.srv: Remove srv_xmltarget. Add XML files that were
18073 mentioned there to srv_xmlfiles instead. Remove conditional tests
18074 on gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe; set
18075 srv_xmlfiles and srv_regobj to include all possible choices.
18076 * configure.ac (srv_xmltarget): Remove.
18077 (srv_xmlfiles): Do not add "target.xml".
18078 (gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe): Remove
18079 checks for supplementary target information.
18080 * configure: Regenerate.
18081 * Makefile.in (XML_TARGET): Remove.
18082 (target.xml): Remove rule.
18083 (clean): Do not clean up target.xml.
18084 (.PRECIOUS): Do not mention target.xml.
18085
18086 * target.h (struct target_ops): Remove arch_string member.
18087 * linux-low.c (linux_arch_string): Remove.
18088 (linux_target_ops): Remove arch_string initializer.
18089 * linux-low.h (struct linux_target_ops): Remove arch_string member.
18090 * linux-i386-low.c (the_low_target): Remove arch_string initializer.
18091 * linux-x86-64-low.c (the_low_target): Remove arch_string initializer.
18092 * spu-low.c (spu_arch_string): Remove.
18093 (spu_target_ops): Remove arch_string initializer.
18094 * win32-low.c (win32_arch_string): Remove.
18095 (win32_target_ops): Remove arch_string initializer.
18096 * win32-low.h (struct win32_target_ops): Remove arch_string member.
18097 * win32-arm-low.c (the_low_target): Remove arch_string initializer.
18098 * win32-i368-low.c (the_low_target): Remove arch_string initializer.
18099
18100 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
18101
18102 * linux-low.h (struct linux_target_ops): Replace left_pad_xfer field
18103 by collect_ptrace_register and supply_ptrace_register hooks.
18104 * linux-low.c (fetch_register): Use supply_ptrace_register callback
18105 instead of checking for the_low_target.left_pad_xfer.
18106 (usr_store_inferior_registers): Use collect_ptrace_register callback
18107 instead of checking for the_low_target.left_pad_xfer.
18108
18109 * linux-s390-low.c (s390_collect_ptrace_register): New function.
18110 (s390_supply_ptrace_register): Likewise.
18111 (s390_fill_gregset): Call s390_collect_ptrace_register.
18112 (the_low_target): Update.
18113
18114 * linux-ppc64-low.c (ppc_collect_ptrace_register): New function.
18115 (ppc_supply_ptrace_register): Likewise.
18116 (the_low_target): Update.
18117
18118 * linux-i386-low.c (the_low_target): Update.
18119 * linux-x86-64-low.c (the_low_target): Update.
18120
18121 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
18122
18123 * configure.srv [s390x-*-linux*]: Set srv_regobj to include both
18124 reg-s390.o and reg-s390x.o.
18125
18126 * linux-low.c (new_inferior): New global variable.
18127 (linux_create_inferior, linux_attach): Set it.
18128 (linux_wait_for_process): Call the_low_target.arch_setup after the
18129 target has stopped for the first time.
18130 (initialize_low): Do not call the_low_target.arch_setup.
18131
18132 * linux-s390-low.c (s390_get_pc): Support bi-arch operation.
18133 (s390_set_pc): Likewise.
18134 (s390_arch_setup): New function.
18135 (the_low_target): Use s390_arch_setup as arch_setup routine.
18136
18137 * regcache.c (realloc_register_cache): New function.
18138 (set_register_cache): Call it for each existing regcache.
18139
18140 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
18141
18142 * server.h (init_registers): Remove prototype.
18143
18144 * linux-low.h (struct linux_target_ops): Add arch_setup field.
18145 * linux-low.c (initialize_low): Call the_low_target.arch_setup ()
18146 instead of init_registers ().
18147 * linux-arm-low.c (init_registers_arm): Add prototype.
18148 (init_registers_arm_with_iwmmxt): Likewise.
18149 (the_low_target): Add initializer for arch_setup field.
18150 * linux-cris-low.c (init_registers_cris): Add prototype.
18151 (the_low_target): Add initializer for arch_setup field.
18152 * linux-crisv32-low.c (init_registers_crisv32): Add prototype.
18153 (the_low_target): Add initializer for arch_setup field.
18154 * linux-i386-low.c (init_registers_i386_linux): Add prototype.
18155 (the_low_target): Add initializer for arch_setup field.
18156 * linux-ia64-low.c (init_registers_ia64): Add prototype.
18157 (the_low_target): Add initializer for arch_setup field.
18158 * linux-m32r-low.c (init_registers_m32r): Add prototype.
18159 (the_low_target): Add initializer for arch_setup field.
18160 * linux-m68k-low.c (init_registers_m68k): Add prototype.
18161 (the_low_target): Add initializer for arch_setup field.
18162 * linux-mips-low.c (init_registers_mips_linux): Add prototype.
18163 (init_registers_mips64_linux): Likewise.
18164 (the_low_target): Add initializer for arch_setup field.
18165 * linux-ppc-low.c (init_registers_ppc): Add prototype.
18166 (init_registers_powerpc_32, init_registers_powerpc_e500): Likewise.
18167 (the_low_target): Add initializer for arch_setup field.
18168 * linux-ppc64-low.c (init_registers_ppc64): Add prototype.
18169 (init_registers_powerpc_64): Likewise.
18170 (the_low_target): Add initializer for arch_setup field.
18171 * linux-s390-low.c (init_registers_s390): Add prototype.
18172 (init_registers_s390x): Likewise.
18173 (the_low_target): Add initializer for arch_setup field.
18174 * linux-sh-low.c (init_registers_sh): Add prototype.
18175 (the_low_target): Add initializer for arch_setup field.
18176 * linux-x86-64-low.c (init_registers_x86_64_linux): Add prototype.
18177 (the_low_target): Add initializer for arch_setup field.
18178 * linux-xtensa-low.c (init_registers_xtensa): Add prototype.
18179 (the_low_target): Add initializer for arch_setup field.
18180
18181 * win32-low.h (struct win32_target_ops): Add arch_setup field.
18182 * win32-low.c (initialize_low): Call the_low_target.arch_setup ()
18183 instead of init_registers ().
18184 * win32-arm-low.c (init_registers_arm): Add prototype.
18185 (the_low_target): Add initializer for arch_setup field.
18186 * win32-i386-low.c (init_registers_i386): Add prototype.
18187 (the_low_target): Add initializer for arch_setup field.
18188
18189 * spu-low.c (init_registers_spu): Add prototype.
18190 (initialize_low): Call initialie_registers_spu () instead of
18191 initialize_registers ().
18192
18193 2008-02-19 Pedro Alves <pedro@codesourcery.com>
18194
18195 * server.c (handle_v_requests): When handling the vRun and vAttach
18196 packets, if already debugging a process, don't kill it. Return an
18197 error instead.
18198
18199 2008-02-17 Daniel Jacobowitz <dan@codesourcery.com>
18200
18201 * server.c (handle_query): Correct length check.
18202
18203 2008-02-14 Pedro Alves <pedro_alves@portugalmail.pt>
18204
18205 * win32-low.c (do_initial_child_stuff): Add process handle
18206 parameter. Set current_process_handle and current_process_id from the
18207 parameters. Clear globals.
18208 (win32_create_inferior): Don't set current_process_handle and
18209 current_process_id here. Instead pass them on the call to
18210 do_initial_child_stuff.
18211 (win32_attach): Likewise.
18212 (win32_clear_inferiors): New.
18213 (win32_kill): Don't close the current process handle or the
18214 current thread handle here. Instead call win32_clear_inferiors.
18215 (win32_detach): Don't open a new handle to the process. Call
18216 win32_clear_inferiors.
18217 (win32_join): Don't rely on current_process_handle; open a new
18218 handle using the process id.
18219 (win32_wait): Call win32_clear_inferiors when the inferior process
18220 has exited.
18221
18222 2008-02-14 Daniel Jacobowitz <dan@codesourcery.com>
18223
18224 * server.c (monitor_show_help): Add "exit".
18225
18226 2008-02-11 Maxim Grigoriev <maxim2405@gmail.com>
18227
18228 * Makefile.in (SFILES): Add linux-xtensa-low.c.
18229 (clean): Add reg-xtensa.c.
18230 (linux-xtensa-low.o, reg-xtensa.o, reg-xtensa.c): New dependencies.
18231 * configure.srv (xtensa*-*-linux*) New target.
18232 * linux-xtensa-low.c: New.
18233 * xtensa-xtregs.c: New.
18234
18235 2008-02-01 Pedro Alves <pedro_alves@portugalmail.pt>
18236
18237 * hostio.c: Don't include errno.h.
18238 (errno_to_fileio_errno): Move to hostio-errno.
18239 * hostio.c: (hostio_error): Remove the error parameter. Defer the
18240 error number outputting to the target->hostio_last_error callback.
18241 (hostio_packet_error): Use FILEIO_EINVAL directly.
18242 (handle_open, handle_pread, hostio_error, handle_unlink): Update
18243 calls to hostio_error.
18244 * hostio-errno.c: New.
18245 * server.h (hostio_last_error_from_errno): Declare.
18246 * target.h (target_ops): Add hostio_last_error member.
18247 * linux-low.c (linux_target_op): Register hostio_last_error_from_errno
18248 as hostio_last_error handler.
18249 * spu-low.c (spu_target_ops): Likewise.
18250 * win32-low.c [_WIN32_WCE] (win32_error_to_fileio_error)
18251 (wince_hostio_last_error): New functions.
18252 (win32_target_ops) [_WIN32_WCE]: Register wince_hostio_last_error
18253 as hostio_last_error handler.
18254 (win32_target_ops) [!_WIN32_WCE]: Register
18255 hostio_last_error_from_errno as hostio_last_error handler.
18256 * Makefile.in (SFILES): Add hostio.c and hostio-errno.c.
18257 (hostio-errno.o): New rule.
18258 * configure.ac (GDBSERVER_DEPFILES): Add $srv_hostio_err_objs.
18259 * configure.srv (srv_hostio_err_objs): New variable. Default to
18260 hostio-errno.o.
18261 (arm*-*-mingw32ce*): Set srv_hostio_err_objs to "".
18262 * configure: Regenerate.
18263
18264 2008-01-29 Daniel Jacobowitz <dan@codesourcery.com>
18265
18266 * linux-low.c (linux_attach_lwp): Do not _exit after errors.
18267 (linux_kill, linux_detach): Clean up the process list.
18268 * remote-utils.c (remote_open): Improve port number parsing.
18269 (putpkt_binary, input_interrupt): Only send interrupts if the target
18270 is running.
18271 * server.c (extended_protocol): Make static.
18272 (attached): Define earlier.
18273 (exit_requested, response_needed, program_argv): New variables.
18274 (target_running): New.
18275 (start_inferior): Clear attached here.
18276 (attach_inferior): Set attached here.
18277 (require_running): Define.
18278 (handle_query): Use require_running and target_running. Implement
18279 "monitor exit".
18280 (handle_v_attach, handle_v_run): New.
18281 (handle_v_requests): Use require_running. Handle vAttach and vRun.
18282 (gdbserver_usage): Update.
18283 (main): Redo argument parsing. Handle --debug and --multi. Handle
18284 --attach along with other options or after the port. Save
18285 program_argv. Support no initial program. Resynchronize
18286 communication with GDB after an error. Handle "monitor exit".
18287 Use require_running and target_running. Always allow the extended
18288 protocol. Do not error out for Hc0 or Hc-1. Do not automatically
18289 restart in extended mode.
18290 * README: Refer to the GDB manual. Update --attach usage.
18291
18292 2007-12-20 Andreas Schwab <schwab@suse.de>
18293
18294 * linux-low.c (STACK_SIZE): Define.
18295 (linux_tracefork_child): Use it. Use __clone2 on ia64.
18296 (linux_test_for_tracefork): Likewise.
18297
18298 2007-12-18 Daniel Jacobowitz <dan@codesourcery.com>
18299
18300 * linux-low.c (linux_wait_for_event): Update messages. Do not
18301 reinsert auto-delete breakpoints.
18302 * mem-break.c (struct breakpoint): Change return type of handler to
18303 int.
18304 (set_breakpoint_at): Update handler type.
18305 (reinsert_breakpoint_handler): Return 1 instead of calling
18306 delete_breakpoint.
18307 (reinsert_breakpoint_by_bp): Check for the original breakpoint before
18308 setting a new one.
18309 (check_breakpoints): Delete auto-delete breakpoints and return 2.
18310 * mem-break.h (set_breakpoint_at): Update handler type.
18311 * thread-db.c (thread_db_create_event, thread_db_create_event): Update.
18312 * win32-low.c (auto_delete_breakpoint): New.
18313 (get_child_debug_event): Use it.
18314
18315 2007-12-16 Daniel Jacobowitz <dan@codesourcery.com>
18316
18317 * configure.ac: Check for pread and pwrite.
18318 * hostio.c (handle_pread): Fall back to lseek and read.
18319 (handle_pwrite): Fall back to lseek and write.
18320 * config.in, configure: Regenerated.
18321
18322 2007-12-07 Daniel Jacobowitz <dan@codesourcery.com>
18323
18324 * server.c (myresume): Add own_buf argument.
18325 (main): Update calls.
18326
18327 2007-12-06 Daniel Jacobowitz <dan@codesourcery.com>
18328
18329 * linux-low.c (linux_wait, linux_resume): Do not handle async I/O.
18330 * remote-utils.c (remote_open): Do not call disable_async_io.
18331 (block_async_io): Delete.
18332 (unblock_async_io): Make static.
18333 (initialize_async_io): New.
18334 * server.c (handle_v_cont): Handle async I/O here.
18335 (myresume): Likewise. Move other common resume tasks here...
18336 (main): ... from here. Call initialize_async_io. Disable async
18337 I/O before the main loop.
18338 * server.h (initialize_async_io): Declare.
18339 (block_async_io, unblock_async_io): Delete prototypes.
18340 * spu-low.c (spu_resume, spu_wait): Do not handle async I/O here.
18341
18342 2007-12-06 Mick Davis <mickd@goanna.iinet.net.au>
18343
18344 * remote-utils.c (readchar): Allow binary data in received messages.
18345
18346 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
18347
18348 * win32-low.c (attaching): New global.
18349 (win32_create_inferior): Clear the `attaching' global.
18350 (win32_attach): Set the `attaching' global.
18351 (get_child_debug_event) [_WIN32_WCE]: Stop the inferior when
18352 attaching. Only set a breakpoint at the entry point if not
18353 attaching.
18354
18355 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
18356
18357 * server.c (main): Don't report dll events on the initial
18358 connection on attaches.
18359
18360 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
18361
18362 * server.c (main): Relax numerical bases supported for the pid of
18363 the --attach command line argument.
18364
18365 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
18366
18367 * win32-low.c (win32_attach): Call OpenProcess before
18368 DebugActiveProcess, not after. Add last error output to error
18369 call.
18370
18371 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
18372
18373 * win32-low.c (win32_get_thread_context)
18374 (win32_set_thread_context): New functions.
18375 (thread_rec): Use win32_get_thread_context.
18376 (continue_one_thread, win32_resume): Use win32_set_thread_context.
18377 * win32-low.h (win32_thread_info) [_WIN32_WCE]: Add `base_context'
18378 field.
18379
18380 2007-12-03 Leo Zayas
18381 Pedro Alves <pedro_alves@portugalmail.pt>
18382
18383 * win32-low.c (soft_interrupt_requested, faked_breakpoint): New
18384 global variables.
18385 (child_add_thread): Minor cleanup.
18386 (child_continue): Resume artificially suspended threads before
18387 calling ContinueDebugEvent.
18388 (suspend_one_thread): New.
18389 (fake_breakpoint_event): New.
18390 (get_child_debug_event): Change return type to int. Check here if
18391 gdb sent an interrupt request. If a soft interrupt was requested,
18392 fake a breakpoint event. Return 0 if there is no event to handle,
18393 and 1 otherwise.
18394 (win32_wait): Don't check here if gdb sent an interrupt request.
18395 Ensure there is a valid event to handle.
18396 (win32_request_interrupt): Add soft interruption method as last
18397 resort.
18398
18399 2007-12-03 Leo Zayas
18400 Pedro Alves <pedro_alves@portugalmail.pt>
18401
18402 * win32-low.h (win32_thread_info): Add descriptions to the
18403 structure members. Replace `suspend_count' counter by a
18404 `suspended' flag.
18405 * win32-low.c (thread_rec): Update condition of when to get the
18406 context from the inferior. Rely on ContextFlags being set if it
18407 has already been retrieved. Only suspend the inferior thread if
18408 we haven't already. Warn if that fails.
18409 (continue_one_thread): s/suspend_count/suspended/. Only call
18410 ResumeThread once. Warn if that fails.
18411
18412 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
18413
18414 * win32-low.c (win32_wait): Don't read from the inferior when it
18415 has already exited.
18416
18417 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
18418
18419 * Makefile.in (win32_low_h): New variable.
18420 (win32-low.o): Add dependency on $(win32_low_h).
18421 (win32-arm-low.o, win32-i386-low.o): New rules.
18422
18423 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
18424
18425 * hostio.c: Correct copyright year.
18426
18427 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
18428
18429 * Makefile.in (OBS): Add hostio.o.
18430 (hostio.o): New rule.
18431 * server.h (handle_vFile): Declare.
18432 * hostio.c: New file.
18433 * server.c (handle_v_requests): Take packet_len and new_packet_len
18434 for binary packets. Call handle_vFile.
18435 (main): Update call to handle_v_requests.
18436
18437 2007-11-05 Daniel Jacobowitz <dan@codesourcery.com>
18438
18439 * linux-low.c: Include <sched.h>.
18440
18441 2007-11-01 Daniel Jacobowitz <dan@codesourcery.com>
18442
18443 * linux-low.c (linux_tracefork_grandchild): New.
18444 (linux_tracefork_child): Use clone.
18445 (linux_test_for_tracefork): Use clone; allocate and free a stack.
18446
18447 2007-10-31 Joel Brobecker <brobecker@adacore.com>
18448
18449 * Makefile.in: Use $(SHELL) instead of "sh" to call regdat.sh.
18450
18451 2007-10-24 Daniel Jacobowitz <dan@codesourcery.com>
18452
18453 * linux-low.c (handle_extended_wait): Handle unexpected signals.
18454
18455 2007-10-23 Daniel Jacobowitz <dan@codesourcery.com>
18456
18457 * inferiors.c (change_inferior_id): Delete.
18458 (add_pid_to_list, pull_pid_from_list): New.
18459 * linux-low.c (PTRACE_SETOPTIONS, PTRACE_GETEVENTMSG)
18460 (PTRACE_O_TRACESYSGOOD, PTRACE_O_TRACEFORK, PTRACE_O_TRACEVFORK)
18461 (PTRACE_O_TRACECLONE, PTRACE_O_TRACEEXEC, PTRACE_O_TRACEVFORKDONE)
18462 (PTRACE_O_TRACEEXIT, PTRACE_EVENT_FORK, PTRACE_EVENT_VFORK)
18463 (PTRACE_EVENT_CLONE, PTRACE_EVENT_EXEC, PTRACE_EVENT_VFORK_DONE)
18464 (PTRACE_EVENT_EXIT, __WALL): Provide default definitions.
18465 (stopped_pids, thread_db_active, must_set_ptrace_flags): New variables.
18466 (using_threads): Always set to 1.
18467 (handle_extended_wait): New.
18468 (add_process): Do not set TID.
18469 (linux_create_inferior): Set must_set_ptrace_flags.
18470 (linux_attach_lwp): Remove TID argument. Do not check using_threads.
18471 Use PTRACE_SETOPTIONS. Call new_thread_notify. Update all callers.
18472 (linux_thread_alive): Rename TID argument to LWPID.
18473 (linux_wait_for_process): Handle unknown processes. Do not use TID.
18474 (linux_wait_for_event): Do not use TID or check using_threads. Update
18475 call to dead_thread_notify. Call handle_extended_wait.
18476 (linux_create_inferior): Use PTRACE_SETOPTIONS.
18477 (send_sigstop): Delete sigstop_sent.
18478 (wait_for_sigstop): Avoid TID.
18479 (linux_supports_tracefork_flag, linux_tracefork_child, my_waitpid)
18480 (linux_test_for_tracefork): New.
18481 (linux_lookup_signals): Use thread_db_active and
18482 linux_supports_tracefork_flag.
18483 (initialize_low): Use thread_db_active and linux_test_for_tracefork.
18484 * linux-low.h (get_process_thread): Avoid TID.
18485 (struct process_ifo): Move thread_known and tid to the end. Remove
18486 sigstop_sent.
18487 (linux_attach_lwp, thread_db_init): Update prototypes.
18488 * server.h (change_inferior_id): Delete prototype.
18489 (add_pid_to_list, pull_pid_from_list): New prototypes.
18490 * thread-db.c (thread_db_use_events): New.
18491 (find_first_thread): Rename to...
18492 (find_one_thread): ...this. Update callers and messages. Do not
18493 call fatal. Check thread_db_use_events. Do not call
18494 change_inferior_id or new_thread_notify.
18495 (maybe_attach_thread): Update. Do not call new_thread_notify.
18496 (thread_db_init): Set thread_db_use_events. Check use_events.
18497 * utils.c (fatal, warning): Correct message prefix.
18498
18499 2007-10-15 Daniel Jacobowitz <dan@codesourcery.com>
18500
18501 * Makefile.in (clean): Remove new files.
18502 (powerpc-32.o, powerpc-32.c, powerpc-e500.o, powerpc-e500.c)
18503 (powerpc-64.o, powerpc-64.c): New rules.
18504 * configure.srv: Use alternate register sets for powerpc64-*-linux*
18505 with AltiVec, powerpc-*-linux* with AltiVec, and powerpc-*-linux*
18506 with SPE.
18507 * linux-ppc-low.c (ppc_regmap): Do not fetch the FP registers for
18508 SPE targets.
18509 (ppc_cannot_store_register): Do not check for FPSCR for SPE targets.
18510 (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS, ppc_fill_vrregset)
18511 (ppc_store_vrregset, PTRACE_GETEVRREGS, PTRACE_SETEVRREGS)
18512 (struct gdb_evrregset_t, ppc_fill_evrregset, ppc_store_evrregset): New.
18513 (target_regsets): Add AltiVec and SPE register sets.
18514 * configure.ac: Check for AltiVec and SPE.
18515 * linux-ppc64-low.c (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS)
18516 (ppc_fill_vrregset, ppc_store_vrregset): New.
18517 (target_regsets): Add AltiVec register set.
18518 * configure: Regenerated.
18519
18520 2007-09-19 Daniel Jacobowitz <dan@codesourcery.com>
18521
18522 * linux-low.c (O_LARGEFILE): Define.
18523 (linux_read_memory): Use /proc/PID/mem.
18524 * configure.ac: Use AC_GNU_SOURCE. Check for pread64.
18525 * configure, config.in: Regenerated.
18526
18527 2007-09-04 Daniel Jacobowitz <dan@codesourcery.com>
18528
18529 * linux-low.c (linux_wait_for_event): Do not pass signals while
18530 single-stepping.
18531
18532 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
18533
18534 * win32-low.c (create_process): New.
18535 (win32_create_inferior): Use create_process instead of
18536 CreateProcess. If create_process failed retry appending an ".exe"
18537 suffix. Store the GetLastError result immediatelly after
18538 create_process calls and use it on the call to error.
18539
18540 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
18541
18542 * win32-low.c (handle_load_dll): Don't use toolhelp when waiting.
18543
18544 2007-08-23 Joel Brobecker <brobecker@adacore.com>
18545
18546 * configure.ac: Switch license to GPLv3.
18547
18548 2007-08-01 Michael Snyder <msnyder@access-company.com>
18549
18550 * remote-utils.c (putpkt_binary): Memory leak, free buf2.
18551
18552 2007-07-31 Pedro Alves <pedro_alves@portugalmail.pt>
18553
18554 * win32-low.c (winapi_CloseToolhelp32Snapshot) [_WIN32_WCE]: New
18555 typedef.
18556 (win32_CloseToolhelp32Snapshot) [_WIN32_WCE]: New global var.
18557 (load_toolhelp) [_WIN32_WCE]: Load TOOLHELP.DLL. Get
18558 CloseToolhelp32Snapshot.
18559 (toolhelp_get_dll_name) [_WIN32_WCE]: Close the snapshot with
18560 CloseToolhelp32Snapshot.
18561
18562 2007-07-27 Michael Snyder <michael.snyder@access-company.com>
18563
18564 * server.c (main): Check for inferior exit before main loop.
18565
18566 2007-07-18 Pedro Alves <pedro_alves@portugalmail.pt>
18567
18568 * remote-utils.c (remote_open): Set SO_KEEPALIVE on remote_desc
18569 instead of on tmp_desc.
18570
18571 2007-07-17 Pedro Alves <pedro_alves@portugalmail.pt>
18572 Daniel Jacobowitz <dan@codesourcery.com>
18573
18574 * inferiors.c (all_dlls, dlls_changed, get_dll): New.
18575 (add_thread): Minor cleanups.
18576 (clear_inferiors): Move lower in the file. Clear the DLL
18577 list.
18578 (free_one_dll, match_dll, loaded_dll, unloaded_dll, clear_list): New.
18579 * remote-utils.c (prepare_resume_reply): Check dlls_changed.
18580 (xml_escape_text): New.
18581 * server.c (handle_query): Handle qXfer:libraries:read. Report it
18582 for qSupported.
18583 (handle_v_cont): Report errors.
18584 (gdbserver_version): Update.
18585 (main): Correct size of own_buf. Do not report initial DLL events.
18586 * server.h (struct dll_info, all_dlls, dlls_changed, loaded_dll)
18587 (unloaded_dll, xml_escape_text): New.
18588 * win32-low.c (enum target_waitkind): Update comments.
18589 (win32_add_one_solib, get_image_name, winapi_EnumProcessModules)
18590 (winapi_GetModuleInformation, winapi_GetModuleFileNameExA)
18591 (win32_EnumProcessModules, win32_GetModuleInformation)
18592 (win32_GetModuleFileNameExA, load_psapi, psapi_get_dll_name)
18593 (winapi_CreateToolhelp32Snapshot, winapi_Module32First)
18594 (winapi_Module32Next, win32_CreateToolhelp32Snapshot)
18595 (win32_Module32First, win32_Module32Next, load_toolhelp)
18596 (toolhelp_get_dll_name, handle_load_dll, handle_unload_dll): New.
18597 (get_child_debug_event): Handle DLL events.
18598 (win32_wait): Likewise.
18599
18600 2007-07-12 Daniel Jacobowitz <dan@codesourcery.com>
18601
18602 * configure.srv: Set srv_linux_regsets for sh*-*-linux*.
18603 * linux-sh-low.c (sh_fill_gregset, target_regsets): New.
18604
18605 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
18606
18607 * win32-low.c (handle_output_debug_string): Ignore event if not
18608 waiting.
18609
18610 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
18611
18612 * win32-arm-low.c (arm_wince_breakpoint): Fix typo.
18613
18614 2007-07-03 Daniel Jacobowitz <dan@codesourcery.com>
18615
18616 * remote-utils.c (look_up_one_symbol): Handle 'm' packets.
18617
18618 2007-07-02 Daniel Jacobowitz <dan@codesourcery.com>
18619
18620 * inferiors.c (change_inferior_id): Add comment.
18621 * linux-low.c (check_removed_breakpoint): Add an early
18622 prototype. Improve debug output.
18623 (linux_attach): Doc update.
18624 (linux_detach_one_process, linux_detach): Clean up before releasing
18625 each process.
18626 (send_sigstop, wait_for_sigstop): Improve comments and debug output.
18627 * linux-low.h (struct process_info): Doc improvement.
18628 * mem-break.c (delete_all_breakpoints): New.
18629 * mem-break.h (delete_all_breakpoints): New prototype.
18630 * thread-db.c (find_first_thread): New.
18631 (thread_db_create_event): Call it instead of
18632 thread_db_find_new_threads. Clean up unused variables.
18633 (maybe_attach_thread): Remove first thread handling.
18634 (thread_db_find_new_threads): Use find_first_thread.
18635 (thread_db_get_tls_address): Likewise.
18636
18637 2007-06-27 Daniel Jacobowitz <dan@codesourcery.com>
18638
18639 * thread-db.c (thread_db_find_new_threads): Add prototype.
18640 (thread_db_create_event): Check for the main thread before adding
18641 a new thread.
18642 (maybe_attach_thread): Only enable event reporting if TID == 0.
18643 (thread_db_get_tls_address): Check for new threads.
18644
18645 2007-06-20 Daniel Jacobowitz <dan@codesourcery.com>
18646
18647 * linux-low.c (linux_create_inferior): Try execv before execvp.
18648 * spu-low.c (spu_create_inferior): Likewise.
18649
18650 2007-06-13 Mike Frysinger <vapier@gentoo.org>
18651
18652 * linux-low.c (linux_create_inferior): Change execv to execvp.
18653 * spu-low.c (spu_create_inferior): Likewies.
18654
18655 2007-06-13 Daniel Jacobowitz <dan@codesourcery.com>
18656
18657 * Makefile.in (clean): Clean new files instead of deleted ones.
18658 (reg-mips.o, reg-mips.c, reg-mips64.o, reg-mips64.c): Delete.
18659 (mips-linux.o, mips-linux.c, mips64-linux.o, mips64-linux.c): New
18660 rules.
18661 * configure.srv: Specify XML files and new regformats for MIPS and
18662 MIPS64 GNU/Linux.
18663 * linux-mips-low.c (mips_num_regs): Set to only used registers.
18664 (mips_regmap): Do not fetch $0. Remove unused registers. Add
18665 an entry for the restart register.
18666 (mips_cannot_fetch_register, mips_cannot_store_register)
18667 (mips_reinsert_addr, mips_fill_fpregset, mips_store_fpregset): Update
18668 register names to match the XML descriptions.
18669 (mips_fill_gregset, mips_store_gregset): Likewise. Handle the
18670 restart register instead of $0.
18671
18672 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
18673 Markus Deuling <deuling@de.ibm.com>
18674
18675 * remote-utils.c (decode_xfer_write): New function.
18676 * server.h (decode_xfer_write): Add prototype.
18677 * server.c (handle_query): Add PACKET_LEN argument. Support
18678 qXfer:spu:read and qXfer:spu:write packets.
18679 (main): Pass packet_len to handle_query.
18680 * spu-low.c (spu_target_ops): Add spu_proc_xfer_spu.
18681 * target.h (target_ops): Add qxfer_spu.
18682
18683 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
18684
18685 * spu-low.c (spu_proc_xfer_spu): Do not return failure when
18686 accessing non-seekable spufs files.
18687
18688 2007-05-16 Markus Deuling <deuling@de.ibm.com>
18689
18690 * server.c (handle_query): Add reply for qC packet.
18691
18692 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
18693 Leo Zayas <lerele@champenstudios@com>
18694
18695 * server.h (check_remote_input_interrupt_request): New function.
18696 * remote_utils.c (INVALID_DESCRIPTOR): New define.
18697 (remote_desc): Initialize with INVALID_DESCRIPTOR.
18698 (input_interrupt): Expose on USE_WIN32API too. Fix whitespace.
18699 (check_remote_input_interrupt_request): New function.
18700 * server.h (check_remote_input_interrupt_request): Declare.
18701 * win32-low.c (winapi_DebugBreakProcess,
18702 winapi_GenerateConsoleCtrlEvent): New typedefs.
18703 (get_child_debug_event): Lower Win32 debug event polling from 1 sec
18704 to 250 ms.
18705 (win32_wait): Check for remote interrupt request
18706 with check_remote_input_interrupt_request.
18707 (win32_request_interrupt): New function.
18708 (win32_target_op): Set request_interrupt to win32_request_interrupt.
18709
18710 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
18711
18712 * win32-low.c (debug_registers_changed,
18713 debug_registers_used, CONTEXT_EXTENDED_REGISTERS,
18714 CONTEXT_FLOATING_POINT, CONTEXT_DEBUG_REGISTERS,
18715 CONTEXT_DEBUGGER, CONTEXT_DEBUGGER_DR): Delete.
18716 (thread_rec): Get context using the low target.
18717 (child_add_thread): Call thread_added on the low target,
18718 which does the same thing.
18719 (regptr): Delete.
18720 (do_initial_child_stuff): Remove debug registers references.
18721 Set context using the low target. Resume threads after
18722 setting the contexts.
18723 (child_continue): Remove dead variable. Remove debug
18724 registers references.
18725 (child_fetch_inferior_registers): Go through the low target.
18726 (do_child_store_inferior_registers): Remove.
18727 (child_store_inferior_registers): Go through the low target.
18728 (win32_resume): Remove debug registers references.
18729 Set context using the low target.
18730 (handle_exception): Change return type to void. Don't record
18731 context here. Set status to TARGET_WAITKIND_SPURIOUS on a
18732 first chance exception.
18733 (get_child_debug_event): Change return type to void. Remove
18734 goto loop. Always return after waiting for debug event.
18735 (win32_wait): Convert to switch statement. Handle spurious
18736 events.
18737
18738 * win32-i386-low.c (debug_registers_changed,
18739 debug_registers_used): New.
18740 (initial_stuff): Rename to ...
18741 (i386_initial_stuff): ... this. Clear debug registers
18742 state variables.
18743 (store_debug_registers): Delete.
18744 (i386_get_thread_context): New.
18745 (load_debug_registers): Delete.
18746 (i386_set_thread_context): New.
18747 (i386_thread_added): New.
18748 (single_step): Rename to ...
18749 (i386_single_step): ... this.
18750 (do_fetch_inferior_registers): Rename to ...
18751 (i386_fetch_inferior_register): ... this.
18752 (i386_store_inferior_register): New.
18753 (the_low_target): Adapt to new interface.
18754
18755 * win32-arm-low.c (CONTEXT_FLOATING_POINT): Define.
18756 (arm_get_thread_context): New.
18757 (arm_set_thread_context): New.
18758 (regptr): New.
18759 (do_fetch_inferior_registers): Rename to ...
18760 (arm_fetch_inferior_register): ... this.
18761 (arm_store_inferior_register): New.
18762 (arm_wince_breakpoint): Reimplement as unsigned long.
18763 (arm_wince_breakpoint_len): Define.
18764 (the_low_target): Adapt to new interface.
18765
18766 * win32-low.h (target_ops): Remove regmap, store_debug_registers and
18767 load_debug_registers. Add get_thread_context, set_thread_context,
18768 thread_added and store_inferior_register. Rename
18769 fetch_inferior_registers to fetch_inferior_register.
18770 (regptr): Remove declaration.
18771
18772 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
18773
18774 * linux-low.c (linux_detach): Change return type to int. Return 0.
18775 * spu-low.c (spu_detach): Likewise.
18776
18777 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
18778
18779 * target.h (target_ops): Change return type of detach to int.
18780 Add join.
18781 (join_inferior): New.
18782 * server.c (main): Don't skip detach support on mingw32.
18783 If the inferior doesn't support detaching return error.
18784 Call join_inferior instead of using waitpid.
18785 * linux-low.c (linux_join): New.
18786 (linux_target_op): Add linux_join.
18787 * spu-low.c (spu_join): New.
18788 (spu_target_ops): Add spu_join.
18789 * win32-low.c (win32_detach): Adapt to new interface.
18790 Reopen current_process_handle before detaching. Issue a child
18791 resume before detaching.
18792 (win32_join): New.
18793 (win32_target_op): Add win32_join.
18794
18795 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
18796
18797 * win32-low.c (win32-attach): Fix return value.
18798 * target.h (target_ops): Describe ATTACH return values.
18799
18800 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
18801
18802 * win32-low.c (GETPROCADDRESS): Define.
18803 (winapi_DebugActiveProcessStop): Add WINAPI. typedef as pointer.
18804 (winapi_DebugSetProcessKillOnExit): Likewise.
18805 (win32_create_inferior): Force usage of ansi CreateProcessA.
18806 (win32_attach): Use GETPROCADDRESS.
18807 (win32_detach): Likewise.
18808
18809 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
18810
18811 * win32-low.c (win32_wait): Don't use WSTOPSIG.
18812
18813 2007-03-30 Pedro Alves <pedro_alves@portugalmail.pt>
18814
18815 * win32-low.c: Commit leftover changes from 2007-03-29.
18816
18817 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
18818
18819 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Make 16-bit
18820 fields short instead of int. Add explicit padding.
18821 (i387_cache_to_fsave): Remove unnecessary casts.
18822 (i387_fsave_to_cache): Doc fix.
18823 (i387_cache_to_fxsave): Remove unnecessary casts and masking.
18824
18825 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
18826
18827 * i387-fp.c (i387_cache_to_fxsave): Reinitialize val2 before use.
18828 (i387_fxsave_to_cache): Check fp->ftag while building ftag value.
18829
18830 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
18831
18832 * configure.srv (arm*-*-mingw32ce*): Move near the other
18833 arm targets.
18834
18835 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
18836
18837 * configure.ac: Add errno checking.
18838 (AC_CHECK_HEADERS): Add errno.h, fcntl.h, signal.h,
18839 sys/file.h and malloc.h.
18840 (AC_CHECK_DECLS): Add perror.
18841 (srv_mingwce): Handle.
18842 * configure.srv (i[34567]86-*-cygwin*): Add
18843 win32-i386-low.o to srv_tgtobj.
18844 (i[34567]86-*-mingw*): Likewise.
18845 (arm*-*-mingw32ce*): Add case.
18846 * gdbreplay.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
18847 HAVE_FCNTL_H, HAVE_ERRNO_H, HAVE_MALLOC_H]: Check.
18848 [__MINGW32CE__] (strerror): New function.
18849 [__MINGW32CE__] (errno): Define to GetLastError.
18850 [__MINGW32CE__] (COUNTOF): New macro.
18851 (remote_open): Remove extra close call.
18852 * mem-break.c (delete_breakpoint_at): New function.
18853 * mem-break.h (delete_breakpoint_at): Declare.
18854 * remote-utils.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
18855 HAVE_FCNTL_H, HAVE_UNISTD_H, HAVE_ERRNO_H]: Check.
18856 [USE_WIN32API] (read, write): Add char* casts.
18857 * server.c [HAVE_UNISTD_H, HAVE_SIGNAL_H]: Check.
18858 * server.h: Include wincecompat.h on Windows CE.
18859 [HAVE_ERRNO_H]: Check.
18860 (perror): Declare if not declared.
18861 * utils.c: Add stdlib.h, errno.h and malloc.h includes.
18862 (perror_with_name): Remove errno declaration.
18863 * wincecompat.h: New.
18864 * wincecompat.c: New.
18865 * win32-low.h: New.
18866 * win32-arm-low.c: New.
18867 * win32-i386-low.c: New.
18868 (win32-low.c): Include mem-break.h and win32-low.h, and winnt.h.
18869 (OUTMSG2): Make it safe.
18870 (_T): New macro.
18871 (COUNTOF): New macro.
18872 (NUM_REGS): Get it from the low target.
18873 (CONTEXT_EXTENDED_REGISTERS, CONTEXT_FLOATING_POINT,
18874 CONTEXT_DEBUG_REGISTERS): Add fallbacks to 0.
18875 (thread_rec): Let low target handle debug registers.
18876 (child_add_thread): Likewise.
18877 (child_init_thread_list): Likewise.
18878 (continue_one_thread): Likewise.
18879 (regptr): New.
18880 (do_child_fetch_inferior_registers): Move to ...
18881 * win32-i386-low.c: ... here, and rename to ...
18882 (do_fetch_inferior_registers): ... this.
18883 * win32-low.c (child_fetch_inferior_registers):
18884 Go through the low target.
18885 (do_child_store_inferior_registers): Use regptr.
18886 (strwinerror): New function.
18887 (win32_create_inferior): Handle Windows CE.
18888 Use strwinerror instead of strerror on Windows error
18889 codes. Add program to the error output.
18890 Don't close the main thread handle on Windows CE.
18891 (win32_attach): Use coredll.dll on Windows CE.
18892 (win32_kill): Close current process and current
18893 thread handles.
18894 (win32_detach): Use coredll.dll on Windows CE.
18895 (win32_resume): Let low target handle debug registers, and
18896 step request.
18897 (handle_exception): Add/Remove initial breakpoint. Avoid
18898 non-existant WSTOPSIG on Windows CE.
18899 (win32_read_inferior_memory): Cast to remove warning.
18900 (win32_arch_string): Go through the low target.
18901 (initialize_low): Call set_breakpoint_data with the low
18902 target's breakpoint.
18903 * win32-low.c (dr, FLAG_TRACE_BIT, FCS_REGNUM,
18904 FOP_REGNUM, mappings): Move to ...
18905 * win32-i386-low.c: ... here.
18906 * win32-low.c (win32_thread_info): Move to ...
18907 * win32-low.h: ... here.
18908 * Makefile.in (SFILES): Add win32-low.c, win32-i386-low.c,
18909 win32-arm-low.c and wincecompat.c.
18910 (all:): Add $EXEEXT.
18911 (install-only:): Likewise.
18912 (gdbserver:): Likewise.
18913 (gdbreplay:): Likewise.
18914 * config.in: Regenerate.
18915 * configure: Regenerate.
18916
18917 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
18918
18919 * win32-low.c: Rename typedef thread_info to
18920 win32_thread_info throughout.
18921
18922 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
18923
18924 * win32-i386-low.c: Rename to ...
18925 * win32-low.c: ... this.
18926 * configure.srv: Replace win32-i386-low.o with win32-low.o.
18927 * Makefile.in: Likewise.
18928
18929 2007-03-27 Pedro Alves <pedro_alves@portugalmail.pt>
18930
18931 * remote-utils.c (monitor_output): Constify msg parameter.
18932 * server.h (monitor_output): Likewise.
18933 * win32-i386-low.c (handle_output_debug_string): New.
18934 (win32_kill): Handle OUTPUT_DEBUG_STRING_EVENT events using
18935 handle_output_debug_string.
18936 (get_child_debug_event): Likewise.
18937
18938 2007-03-27 Mat Hostetter <mat@lcs.mit.edu>
18939
18940 * server.c (main): Correct strtoul check.
18941
18942 2007-03-27 Jon Ringle <jon@ringle.org>
18943
18944 * linux-low.c: Check __ARCH_HAS_MMU__ also.
18945
18946 2007-03-27 Brooks Moses <brooks.moses@codesourcery.com>
18947
18948 * Makefile.in: Add dummy "pdf" and "install-pdf" targets.
18949
18950 2007-02-27 Daniel Jacobowitz <dan@codesourcery.com>
18951
18952 * terminal.h: Check HAVE_SGTTY_H.
18953
18954 2007-02-27 Mat Hostetter <mat@lcs.mit.edu>
18955
18956 * remote-utils.c (remote_open): Print out the assigned port number.
18957
18958 2007-02-26 Daniel Jacobowitz <dan@codesourcery.com>
18959
18960 * remote-utils.c (monitor_output): New function.
18961 * server.c (debug_threads): Define here.
18962 (monitor_show_help): New function.
18963 (handle_query): Handle qRcmd.
18964 (main): Do not handle 'd' packet.
18965 * server.h (debug_threads, remote_debug, monitor_output): Declare.
18966 * linux-low.c, spu-low.c, win32-i386-low.c: Remove definitions
18967 of debug_threads.
18968
18969 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
18970
18971 * Makefile.in (EXEEXT): New.
18972 (clean): Use $(EXEEXT).
18973
18974 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
18975
18976 * target.h (target_ops): Rename send_signal to request_interrupt,
18977 and remove enum target_signal parameter.
18978 * linux-low.c (linux_request_interrupt): Rename from
18979 linux_send_signal, and always send SIGINT.
18980 * spu-low.c (spu_request_interrupt): Rename from spu_send_signal,
18981 and always send SIGINT.
18982 * remote-utils.c (putpkt_binary): Call request_interrupt, instead
18983 of send_signal.
18984 (input_interrupt): Likewise.
18985
18986 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
18987
18988 * server.c (get_features_xml): Check if target implemented
18989 arch_string.
18990 * win32-i386-low.c (win32_arch_string): New.
18991 (win32_target_ops): Add win32_arch_string as arch_string member.
18992
18993 2007-02-22 Markus Deuling <deuling@de.ibm.com>
18994
18995 * spu-low.c (spu_arch_string): New.
18996 (spu_target_ops): Add spu_arch_string.
18997
18998 2007-02-16 Daniel Jacobowitz <dan@codesourcery.com>
18999
19000 * remote-utils.c: Remove HAVE_TERMINAL_H check.
19001 * configure.ac: Do not check for terminal.h.
19002 * configure, config.in: Regenerated.
19003
19004 2007-02-08 Daniel Jacobowitz <dan@codesourcery.com>
19005
19006 * Makefile.in (OBS): Add $(XML_BUILTIN).
19007 (XML_DIR, XML_TARGET, XML_FILES, XML_BUILTIN): New.
19008 (clean): Update.
19009 (target.xml, xml-builtin.c, stamp-xml, arm-with-iwmmxt.o)
19010 (arm-with-iwmmxt.c): New.
19011 * config.in, configure: Regenerate.
19012 * configure.ac: Check for iWMMXt. Handle srv_xmltarget,
19013 srv_xmlbuiltin, and srv_xmlfiles. Define USE_XML.
19014 * configure.srv: Mention srv_xmltarget and srv_xmlfiles.
19015 (arm*-*-linux*): Add iWMMXt and regset support.
19016 * linux-arm-low.c (PTRACE_GETWMMXREGS, PTRACE_SETWMMXREGS): Define.
19017 (arm_fill_gregset, arm_store_gregset, arm_fill_wmmxregset)
19018 (arm_store_wmmxregset, target_regsets): New.
19019 * server.c (get_features_xml): Take annex argument. Check builtin
19020 XML documents.
19021 (handle_query): Handle multiple annexes.
19022
19023 2007-01-29 Daniel Jacobowitz <dan@codesourcery.com>
19024
19025 * remote-utils.c [USE_WIN32API] (read, write): Define.
19026 (putpkt_binary, input_interrupt, readchar, getpkt): Use read and
19027 write.
19028
19029 2007-01-09 Daniel Jacobowitz <dan@codesourcery.com>
19030
19031 * linux-i386-low.c (the_low_target): Set arch_string.
19032 * linux-x86-64-low.c (the_low_target): Likewise.
19033 * linux-low.c (linux_arch_string): New.
19034 (linux_target_ops): Add it.
19035 * linux-low.h (struct linux_target_ops): Add arch_string.
19036 * server.c (write_qxfer_response): Use const void * for DATA.
19037 (get_features_xml): New.
19038 (handle_query): Handle qXfer:features:read. Report it for qSupported.
19039 * target.h (struct target_ops): Add arch_string method.
19040
19041 2007-01-03 Denis Pilat <denis.pilat@st.com>
19042 Daniel Jacobowitz <dan@codesourcery.com>
19043
19044 * linux-low.c (linux_kill): Handle being called with no threads.
19045 * win32-i386-low.c (win32_kill): Likewise.
19046 (get_child_debug_event): Clear current_process_handle.
19047
19048 2006-12-30 Denis PILAT <denis.pilat@st.com>
19049 Daniel Jacobowitz <dan@codesourcery.com>
19050
19051 * remote-utils.c (remote_open): Check the type of specified
19052 serial port devices before opening them.
19053 * server.c (main): Kill the inferior if an error occurs during
19054 the first remote_open.
19055
19056 2006-12-05 Markus Deuling <deuling@de.ibm.com>
19057
19058 * README: Update supported targets.
19059
19060 2006-11-28 Daniel Jacobowitz <dan@codesourcery.com>
19061
19062 * Makefile.in (clean): Remove reg-mips64.c.
19063 (reg-mips64.c, reg-mips64.o): New rules.
19064 * configure.srv: Handle mips64. Include regset support for mips.
19065 * linux-mips-low.c (union mips_register): New.
19066 (mips_get_pc, mips_set_pc, mips_reinsert_addr): Use it.
19067 (mips_breakpoint, mips_breakpoint_at): Use int.
19068 (mips_collect_register, mips_supply_register)
19069 (mips_collect_register_32bit, mips_supply_register_32bit)
19070 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
19071 (mips_store_fpregset, target_regsets): New.
19072 * thread-db.c (thread_db_get_tls_address): Use uintptr_t.
19073
19074 2006-11-22 Ulrich Weigand <uweigand@de.ibm.com>
19075
19076 * configure.srv: Add target "spu*-*-*".
19077 * Makefile.in (clean): Remove reg-spu.c.
19078 (reg-spu.c, reg-spu.o, spu-low.o): Add dependencies.
19079 * spu-low.c: New file.
19080
19081 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
19082
19083 * configure.ac: Correct td_thr_tls_get_addr test.
19084 * configure: Regenerated.
19085
19086 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
19087
19088 * linux-low.c (linux_wait_for_event): Reformat. Use the
19089 pass_signals array.
19090 * remote-utils.c (decode_address_to_semicolon): New.
19091 * server.c (pass_signals, handle_general_set): New.
19092 (handle_query): Mention QPassSignals for qSupported.
19093 (main): Call handle_general_set.
19094 * server.h (pass_signals, decode_address_to_semicolon): New.
19095
19096 2006-11-06 Daniel Jacobowitz <dan@codesourcery.com>
19097
19098 * server.c (handle_query): Correct error handling for read_auxv.
19099
19100 2005-10-19 Ulrich Weigand <uweigand@de.ibm.com>
19101
19102 * configure.srv [s390-*-linux*, s390x-*-linux*]: Set srv_linux_regsets
19103 and srv_linux_thread_db to yes.
19104 * linux-s390-low.c (s390_fill_gregset): New function.
19105 (target_regsets): Define data structure.
19106
19107 2006-10-17 Daniel Jacobowitz <dan@codesourcery.com>
19108
19109 * acinclude.m4 (SRV_CHECK_TLS_GET_ADDR): New.
19110 * configure.ac: Use it. Define HAVE_TD_THR_TLS_GET_ADDR.
19111 * config.in, configure: Regenerated.
19112 * inferiors.c (gdb_id_to_thread): New function.
19113 (gdb_id_to_thread_id): Use it.
19114 * linux-low.c (linux_target_ops): Use thread_db_get_tls_address.
19115 * linux-low.h (struct process_info): Add th member.
19116 (thread_db_get_tls_address): New prototype.
19117 * remote-utils.c (decode_address): Make non-static.
19118 * server.c (handle_query): Handle qGetTLSAddr.
19119 * server.h (gdb_id_to_thread, decode_address): New prototypes.
19120 * target.h (struct target_ops): Add get_tls_address.
19121 * thread-db.c (maybe_attach_thread): Save the thread handle.
19122 (thread_db_get_tls_address): New.
19123
19124 2006-09-28 Daniel Jacobowitz <dan@codesourcery.com>
19125
19126 * linux-low.c (PTRACE_GETSIGINFO, PTRACE_SETSIGINFO): Define.
19127 (linux_resume_one_process): Take a siginfo_t *. Update all
19128 callers. Queue it if necessary. Use PTRACE_SETSIGINFO.
19129 (struct pending_signals): Add a siginfo_t.
19130 (linux_wait_for_process): Always set last_status.
19131 (linux_wait_for_event): Use PTRACE_GETSIGINFO.
19132 (linux_queue_one_thread): Use PTRACE_GETSIGINFO.
19133 * linux-low.h (struct process_info): Add last_status.
19134
19135 2006-09-21 Daniel Jacobowitz <dan@codesourcery.com>
19136
19137 * remote-utils.c (try_rle): New function.
19138 (putpkt_binary): Use it.
19139
19140 2006-08-19 Daniel Jacobowitz <dan@codesourcery.com>
19141
19142 * Makefile.in (clean): Clean reg-x86-64-linux.c.
19143 (reg-x86-64-linux.o, reg-x86-64-linux.c): New.
19144 * configure.srv (x86_64-*-linux*): Use reg-x86-64-linux.o.
19145 * linux-x86-64-low.c (x86_64_regmap): Include ORIG_RAX.
19146 (x86_64_fill_gregset, x86_64_store_gregset): Skip floating
19147 point registers.
19148
19149 2006-08-08 Richard Sandiford <richard@codesourcery.com>
19150
19151 * server.c (terminal_fd): New variable.
19152 (old_foreground_pgrp): Likewise.
19153 (restore_old_foreground_pgrp): New function.
19154 (start_inferior): Record the terminal file descriptor in terminal_fd
19155 and its original foreground group in old_foreground_pgrp. Register
19156 restore_old_foreground_pgrp with atexit().
19157
19158 2006-07-26 Daniel Jacobowitz <dan@codesourcery.com>
19159
19160 * server.c (handle_query): Correct qPart to qXfer.
19161
19162 2006-07-22 Daniel Jacobowitz <dan@codesourcery.com>
19163
19164 * configure.ac: Check for more headers which are missing on
19165 Windows. Automatically supply -lwsock32 and USE_WIN32API.
19166 * configure.srv: Add Cygwin and mingw32.
19167 * remote-utils.c: Don't include headers unconditionally which
19168 are missing on mingw32. Include <winsock.h> for mingw32.
19169 (remote_open): Adjust for mingw32 support. Flush
19170 standard error after writing to it.
19171 (remote_close, putpkt_binary, input_interrupt, block_async_io)
19172 (unblock_async_io, enable_async_io, disable_async_io)
19173 (readchar, getpkt): Update for Winsock support.
19174 (prepare_resume_reply): Expect a protocol signal number.
19175 * server.c: Disable <sys/wait.h> on mingw32.
19176 (start_inferior): Adjust for mingw32 support. Flush
19177 standard error after writing to it.
19178 (attach_inferior): Likewise. Use protocol signal
19179 numbers.
19180 (main): Skip 'D' packet on mingw32. Use protocol signal numbers
19181 and names.
19182 * win32-i386-low.c: New file.
19183 * Makefile.in (XM_CLIBS): Set.
19184 (gdbserver, gdbreplay): Use $(INTERNAL_CFLAGS).
19185 (win32-i386-low.o): New dependency rule.
19186 * linux-low.c (linux_wait): Use target signal numbers.
19187 * target.h (struct target_ops): Doc fix.
19188 * server.h (target_signal_to_name): New prototype.
19189 * gdbreplay.c: Don't include headers unconditionally which
19190 are missing on mingw32. Include <winsock.h> for mingw32.
19191 (remote_close, remote_open): Adjust for Winsock support.
19192 * configure, config.in: Regenerated.
19193
19194 2006-07-12 Daniel Jacobowitz <dan@codesourcery.com>
19195
19196 * server.c (decode_xfer_read, write_qxfer_response): New.
19197 (handle_query): Take a packet length argument. Handle
19198 qXfer:auxv:read instead of qPart:auxv:read. Mention it in
19199 the qSupported response.
19200 (main): Update call to handle_query.
19201
19202 2006-06-22 Daniel Jacobowitz <dan@codesourcery.com>
19203
19204 * remote-utils.c (remote_escape_output, remote_unescape_input): New.
19205 (putpkt_binary): Renamed from putpkt and adjusted for binary
19206 data.
19207 (putpkt): New wrapper for putpkt_binary.
19208 (readchar): Don't mask off the high bit.
19209 (decode_X_packet): New function.
19210 * server.c (main): Call putpkt_binary if a handler sets the packet
19211 length. Save the length of the incoming packet. Handle 'X'.
19212 * server.h (gdb_byte, remote_escape_output, decode_X_packet): New.
19213
19214 2006-06-21 Daniel Jacobowitz <dan@codesourcery.com>
19215
19216 * server.c (handle_query): Handle qSupported.
19217
19218 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
19219
19220 * remote-utils.c (all_symbols_looked_up): New variable.
19221 (look_up_one_symbol): Check it.
19222 * server.h (look_up_one_symbol): New declaration.
19223 * thread-db.c (thread_db_init): Set all_symbols_looked_up.
19224
19225 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
19226
19227 * Makefile.in (linux-arm-low.o): Update dependencies.
19228 * linux-arm-low.c: Include "gdb_proc_service.h".
19229 (PTRACE_GET_THREAD_AREA): Define.
19230 (ps_get_thread_area): New function.
19231
19232 2006-05-09 Nathan Sidwell <nathan@codesourcery.com>
19233
19234 * configure.srv (m68k*-*-uclinux*): New target.
19235 * linux-low.c (linux_create_inferior): Use vfork on mmuless systems.
19236 (linux_resume_one_process): Remove extraneous cast.
19237 (linux_read_offsets): New.
19238 (linux_target_op): Add linux_read_offsets on mmuless systems.
19239 * server.c (handle_query): Add qOffsets logic.
19240 * target.h (struct target_ops): Add read_offsets.
19241
19242 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
19243
19244 * linux-mips-low.c: Include <sys/ptrace.h> and "gdb_proc_service.h".
19245 (PTRACE_GET_THREAD_AREA): Define.
19246 (ps_get_thread_area): New function.
19247 * Makefile.in (linux-i386-low.o, linux-mips-low.o)
19248 (linux-x86-64-low.o): Update.
19249
19250 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
19251
19252 * configure.ac: Remove checks for prfpregset_t.
19253 * gdb_proc_service.h: New file.
19254 * linux-i386-low.c, linux-x86-64-low.c, thread-db.c: Use the
19255 new "gdb_proc_service.h".
19256 * proc-service.c: Likewise.
19257 (ps_pglobal_lookup, ps_pdread, ps_pdwrite): Use psaddr_t.
19258 (ps_lgetfpregs, ps_lsetfpregs): Use a void* argument.
19259 * Makefile.in (gdb_proc_service_h): Updated.
19260 * configure, config.in: Regenerated.
19261
19262 2006-03-03 Daniel Jacobowitz <dan@codesourcery.com>
19263
19264 * remote-utils.c (prepare_resume_reply): Move declaration
19265 of gdb_id_from_wait to the top of the block.
19266
19267 2006-02-15 Daniel Jacobowitz <dan@codesourcery.com>
19268
19269 * linux-low.c (regsets_store_inferior_registers): Read the regset
19270 from the target before filling it.
19271
19272 2006-02-08 Daniel Jacobowitz <dan@codesourcery.com>
19273
19274 * server.c (attach_inferior): Return SIGTRAP for a successful
19275 attach.
19276
19277 2006-02-01 Daniel Jacobowitz <dan@codesourcery.com>
19278
19279 * Makefile.in (OBS): Add version.o.
19280 (STAGESTUFF): Delete.
19281 (version.o): Add dependencies.
19282 (version.c): Replace rule.
19283 (clean): Remove version.c.
19284 * server.c (gdbserver_version): New.
19285 (gdbserver_usage): Use printf.
19286 (main): Handle --version and --help.
19287 * server.h (version, host_name): Add declarations.
19288
19289 2005-12-23 Eli Zaretskii <eliz@gnu.org>
19290
19291 * linux-arm-low.c:
19292 * linux-arm-low.c:
19293 * inferiors.c:
19294 * i387-fp.h:
19295 * i387-fp.c:
19296 * gdbreplay.c:
19297 * regcache.c:
19298 * proc-service.c:
19299 * mem-break.h:
19300 * mem-break.c:
19301 * linux-x86-64-low.c:
19302 * linux-sh-low.c:
19303 * linux-s390-low.c:
19304 * linux-ppc64-low.c:
19305 * linux-ppc-low.c:
19306 * linux-mips-low.c:
19307 * linux-m68k-low.c:
19308 * linux-m32r-low.c:
19309 * linux-low.h:
19310 * linux-low.c:
19311 * linux-ia64-low.c:
19312 * linux-i386-low.c:
19313 * linux-crisv32-low.c:
19314 * thread-db.c:
19315 * terminal.h:
19316 * target.h:
19317 * target.c:
19318 * server.h:
19319 * server.c:
19320 * remote-utils.c:
19321 * regcache.h:
19322 * utils.c:
19323 * Makefile.in:
19324 * configure.ac:
19325 * gdbserver.1: Add (C) after Copyright. Update the FSF
19326 address.
19327
19328 2005-11-13 Daniel Jacobowitz <dan@codesourcery.com>
19329
19330 * linux-arm-low.c (arm_eabi_breakpoint): New variable.
19331 (arm_breakpoint_at): Recognize both breakpoints.
19332 (the_low_target): Use the correct breakpoint instruction.
19333
19334 2005-11-02 Daniel Jacobowitz <dan@codesourcery.com>
19335
19336 * configure.srv (x86_64-*-linux*): Turn on thread_db support.
19337 * linux-x86-64-low.c (x86_64_breakpoint, x86_64_breakpoint_len)
19338 (x86_64_get_pc, x86_64_set_pc, x86_64_breakpoint_at): New.
19339 (the_low_target): Update.
19340
19341 2005-10-25 Andreas Schwab <schwab@suse.de>
19342
19343 * server.c (main): Allocate mem_buf with PBUFSIZ bytes.
19344
19345 * linux-ia64-low.c (ia64_regmap): Remove NAT registers.
19346 (ia64_num_regs): Reduce to 462.
19347
19348 2005-09-17 Daniel Jacobowitz <dan@codesourcery.com>
19349
19350 * acinclude.m4: Correct quoting.
19351 * aclocal.m4: Regenerated.
19352
19353 Suggested by SZOKOVACS Robert <szo@ies.hu>:
19354 * thread-db.c (thread_db_err_str): Handle TD_VERSION.
19355 (thread_db_init): Call thread_db_err_str.
19356 * configure.ac: Check for TD_VERSION.
19357 * config.in, configure: Regenerated.
19358
19359 2005-07-31 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
19360
19361 * server.h (error, fatal, warning): Add ATTR_FORMAT.
19362
19363 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
19364
19365 * configure.ac: Define HAVE_LINUX_REGSETS even if PTRACE_GETREGS
19366 is not available. Define HAVE_PTRACE_GETREGS if it is.
19367 * config.in, configure: Regenerated.
19368 * configure.srv: Set srv_linux_regsets for PowerPC and PowerPC64.
19369 * linux-i386-low.c, linux-m68k-low.c: Update to use
19370 HAVE_PTRACE_GETREGS.
19371 * linux-low.c (regsets_fetch_inferior_registers)
19372 (regsets_store_inferior_registers): Only return 0 if we processed
19373 GENERAL_REGS.
19374 * linux-ppc-low.c (ppc_fill_gregset, target_regsets): New.
19375 * linux-ppc64-low.c (ppc_fill_gregset, target_regsets): New.
19376
19377 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
19378
19379 * inferiors.c (struct thread_info): Add gdb_id.
19380 (add_thread): Add gdb_id argument.
19381 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New.
19382 * linux-low.c (linux_create_inferior, linux_attach_lwp): Update
19383 calls to add_thread.
19384 * remote-utils.c (prepare_resume_reply: Use thread_to_gdb_id.
19385 * server.c (handle_query): Use thread_to_gdb_id.
19386 (handle_v_cont, main): Use gdb_id_to_thread_id.
19387 * server.h (add_thread): Update prototype.
19388 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New
19389 prototypes.
19390
19391 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
19392
19393 * linux-low.c (fetch_register, usr_store_inferior_registers): Handle
19394 left-padded registers.
19395 * linux-low.h (struct linux_target_ops): Add left_pad_xfer.
19396 * linux-ppc64-low.c (the_low_target): Set left_pad_xfer.
19397
19398 2005-07-01 Steve Ellcey <sje@cup.hp.com>
19399
19400 * configure.ac (BFD_NEED_DECLARATION): Replace with AC_CHECK_DECLS.
19401 * configure: Regenerate.
19402 * config.in: Regenerate.
19403 * server.h (NEED_DECLARATION_STRERROR):
19404 Replace with !HAVE_DECL_STRERROR.
19405
19406 2005-06-16 Daniel Jacobowitz <dan@codesourcery.com>
19407
19408 * linux-low.c (linux_wait, linux_send_signal): Don't test
19409 an unsigned long variable for > 0 if it could be MAX_ULONG.
19410 * server.c (myresume): Likewise.
19411 * target.c (set_desired_inferior): Likewise.
19412
19413 2005-06-13 Mark Kettenis <kettenis@gnu.org>
19414
19415 * configure.ac: Simplify and improve check for socklen_t.
19416 * configure, config.in: Regenerate.
19417
19418 2005-06-12 Daniel Jacobowitz <dan@codesourcery.com>
19419
19420 * acconfig.h: Remove.
19421 * configure.ac: Add a test for socklen_t. Use three-argument
19422 AC_DEFINE throughout.
19423 * config.in: Regenerated using autoheader 2.59.
19424 * configure: Regenerated.
19425
19426 * gdbreplay.c (socklen_t): Provide a default.
19427 (remote_open): Use socklen_t.
19428 * remote-utils.c (socklen_t): Provide a default.
19429 (remote_open): Use socklen_t.
19430 (convert_int_to_ascii, convert_ascii_to_int, decode_M_packet): Use
19431 unsigned char.
19432
19433 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Use unsigned
19434 char for buffers.
19435 * linux-low.c (linux_read_memory, linux_write_memory)
19436 (linux_read_auxv): Likewise.
19437 * mem-break.c (breakpoint_data, set_breakpoint_data, check_mem_read)
19438 (check_mem_write): Likewise.
19439 * mem-break.h (set_breakpoint_data, check_mem_read, check_mem_write):
19440 Likewise.
19441 * regcache.c (struct inferior_rgcache_data, registers_to_string)
19442 (registers_from_string, register_data): Likewise.
19443 * server.c (handle_query, main): Likewise.
19444 * server.h (convert_ascii_to_int, convert_int_to_ascii)
19445 (decode_M_packet): Likewise.
19446 * target.c (read_inferior_memory, write_inferior_memory): Likewise.
19447 * target.h (struct target_ops): Update read_memory, write_memory,
19448 and read_auxv.
19449 (read_inferior_memory, write_inferior_memory): Update.
19450 * linux-low.h (struct linux_target_ops): Change type of breakpoint
19451 to unsigned char *.
19452 * linux-arm-low.c, linux-cris-low.c, linux-crisv32-low.c,
19453 linux-i386-low.c, linux-m32r-low.c, linux-m68k-low.c,
19454 linux-mips-low.c, linux-ppc-low.c, linux-ppc64-low.c,
19455 linux-s390-low.c, linux-sh-low.c: Update for changes in
19456 read_inferior_memory and the_low_target->breakpoint.
19457
19458 2005-05-28 Daniel Jacobowitz <dan@codesourcery.com>
19459
19460 * Makefile.in (SFILES): Add linux-ppc64-low.c.
19461 (linux-ppc64-low.o, reg-ppc64.c, reg-ppc64.o): New targets.
19462 * configure.srv: Add powerpc64-*-linux*.
19463 * linux-ppc64-low.c: New file.
19464
19465 2005-05-23 Orjan Friberg <orjanf@axis.com>
19466
19467 * linux-cris-low.c: New file with support for CRIS.
19468 * linux-crisv32-low.c: Ditto for CRISv32.
19469 * Makefile.in (SFILES): Add linux-cris-low.c, linux-crisv32-low.c.
19470 (clean): Add reg-cris.c and reg-crisv32.c.
19471 Add linux-cris-low.o, linux-crisv32-low.o, reg-cris.o, reg-cris.c,
19472 reg-crisv32.o, and reg-crisv32.c to make rules.
19473 * configure.srv: Add cris-*-linux* and crisv32-*-linux* to list of
19474 recognized targets.
19475
19476 2005-05-16 Ulrich Weigand <uweigand@de.ibm.com>
19477
19478 * linux-low.c (fetch_register): Ensure buffer size is a multiple
19479 of sizeof (PTRACE_XFER_TYPE).
19480 (usr_store_inferior_registers): Likewise. Zero out excess bytes.
19481
19482 2005-05-12 Orjan Friberg <orjanf@axis.com>
19483
19484 * target.h (struct target_ops): Add insert_watchpoint,
19485 remove_watchpoint, stopped_by_watchpoint, stopped_data_address function
19486 pointers for hardware watchpoint support.
19487 * linux-low.h (struct linux_target_ops): Ditto.
19488 * linux-low.c (linux_insert_watchpoint, linux_remove_watchpoint)
19489 (linux_stopped_by_watchpoint, linux_stopped_data_address): New. Add
19490 to linux_target_ops.
19491 * remote-utils.c (prepare_resume_reply): Add watchpoint information to
19492 reply packet.
19493 * server.c (main): Recognize 'Z' and 'z' packets.
19494
19495 2005-05-10 Ulrich Weigand <uweigand@de.ibm.com>
19496
19497 * linux-s390-low.c (s390_breakpoint, s390_breakpoint_len): Define.
19498 (s390_get_pc, s390_set_pc, s390_breakpoint_at): New functions.
19499 (the_low_target): Add new members.
19500
19501 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
19502
19503 * proc-service.c (ps_lgetregs): Search all_processes instead of
19504 all_threads.
19505
19506 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
19507
19508 * server.c (start_inferior): Change return type to int.
19509 (attach_inferior): Change sigptr to int *.
19510 (handle_v_cont, handle_v_requests): Change signal to int *.
19511 (main): Change signal to int.
19512
19513 2005-04-15 Kei Sakamoto <sakamoto.kei@renesas.com>
19514
19515 * Makefile.in: Add linux-m32r-low.o, reg-m32r.c and reg-m32r.o.
19516 * configure.srv: Add m32r*-*-linux*.
19517 * linux-m32r-low.c: New file.
19518
19519 2005-03-04 Daniel Jacobowitz <dan@codesourcery.com>
19520
19521 * Makefile.in (stamp-h): Set CONFIG_HEADERS explicitly.
19522
19523 2005-03-03 Daniel Jacobowitz <dan@codesourcery.com>
19524
19525 * inferiors.c (change_inferior_id, add_thread, find_inferior_id):
19526 Take unsigned long arguments for PIDs.
19527 * linux-low.c (add_process, linux_attach_lwp, linux_attach)
19528 (linux_thread_alive, linux_wait_for_event, kill_lwp, send_sigstop)
19529 (wait_for_sigstop, linux_resume_one_process)
19530 (regsets_fetch_inferior_registers, linux_send_signal)
19531 (linux_read_auxv): Likewise. Update the types of variables holding
19532 PIDs. Update format string specifiers.
19533 * linux-low.h (struct process_info, linux_attach_lwp): Likewise.
19534 * remote-utils.c (prepare_resume_reply): Likewise.
19535 * server.c (cont_thread, general_thread, step_thread)
19536 (thread_from_wait, old_thread_from_wait, signal_pid): Change type to
19537 unsigned long.
19538 (handle_query): Update format specifiers.
19539 (handle_v_cont, main): Use strtoul for thread IDs.
19540 * server.h (struct inferior_list_entry): Use unsigned long for ID.
19541 (add_thread, find_inferior_id, change_inferior_id, cont_thread)
19542 (general_thread, step_thread, thread_from_wait)
19543 (old_thread_from_wait): Update.
19544 * target.h (struct thread_resume): Use unsigned long for THREAD.
19545 (struct target_ops): Use unsigned long for arguments to attach and
19546 thread_alive.
19547
19548 2005-02-24 Daniel Jacobowitz <dan@codesourcery.com>
19549
19550 * acinclude.m4: Include bfd/bfd.m4 directly.
19551 * configure.ac: Use AC_ARG_PROGRAM. Suggested by Aron Griffis
19552 <agriffis@toolchain.org>.
19553 * aclocal.m4, configure: Regenerated.
19554
19555 2005-01-07 Andrew Cagney <cagney@gnu.org>
19556
19557 * configure.ac: Rename configure.in, require autoconf 2.59.
19558 * configure: Re-generate.
19559
19560 2004-12-08 Daniel Jacobowitz <dan@debian.org>
19561
19562 * acinclude.m4 (SRV_CHECK_THREAD_DB): Add ps_get_thread_area. Reset
19563 LIBS when finished.
19564 * aclocal.m4: Regenerated.
19565 * configure: Regenerated.
19566
19567 2004-11-21 Andreas Schwab <schwab@suse.de>
19568
19569 * linux-m68k-low.c (m68k_num_gregs): Define.
19570 (m68k_fill_gregset, m68k_store_gregset, m68k_fill_fpregset)
19571 (m68k_store_fpregset, target_regsets) [HAVE_LINUX_REGSETS]: New.
19572 (m68k_breakpoint, m68k_breakpoint_len, m68k_get_pc, m68k_set_pc)
19573 (m68k_breakpoint_at): New. Add to the_low_target.
19574
19575 * configure.srv (m68*-*-linux*): Set srv_linux_regsets and
19576 srv_linux_thread_db to yes.
19577
19578 2004-10-20 Joel Brobecker <brobecker@gnat.com>
19579
19580 * linux-x86-64-low.c (ARCH_SET_GS): Add definition if missing.
19581 (ARCH_SET_FS): Likewise.
19582 (ARCH_GET_FS): Likewise.
19583 (ARCH_GET_GS): Likewise.
19584
19585 2004-10-16 Daniel Jacobowitz <dan@debian.org>
19586
19587 * linux-i386-low.c (ps_get_thread_area): New.
19588 * linux-x86-64-low.c (ps_get_thread_area): New.
19589 * linux-low.c: Include <sys/syscall.h>.
19590 (linux_kill_one_process): Don't kill the first thread here.
19591 (linux_kill): Kill the first thread here.
19592 (kill_lwp): New function.
19593 (send_sigstop, linux_send_signal): Use it.
19594 * proc-service.c: Clean up #ifdefs.
19595 (fpregset_info): Delete.
19596 (ps_lgetregs): Update and enable implementation.
19597 (ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs): Remove disabled
19598 implementations.
19599 * remote-utils.c (struct sym_cache, symbol_cache): New.
19600 (input_interrupt): Print a clearer message.
19601 (async_io_enabled): New variable.
19602 (enable_async_io, disable_async_io): Use it. Update comments.
19603 (look_up_one_symbol): Use the symbol cache.
19604 * thread-db.c (thread_db_look_up_symbols): New function.
19605 (thread_db_init): Update comments. Call thread_db_look_up_symbols.
19606
19607 2004-10-16 Daniel Jacobowitz <dan@debian.org>
19608
19609 * configure.in: Test for -rdynamic.
19610 * configure: Regenerated.
19611 * Makefile (INTERNAL_LDFLAGS): New.
19612 (gdbserver, gdbreplay): Use it.
19613
19614 2004-09-02 Andrew Cagney <cagney@gnu.org>
19615
19616 * Makefile.in (TAGS): Replace TM_FILE with DEPRECATED_TM_FILE.
19617
19618 2004-03-23 Daniel Jacobowitz <drow@mvista.com>
19619
19620 * linux-low.c (linux_wait): Clear all_processes list also.
19621
19622 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
19623
19624 * linux-low.c: Include <errno.h>. Remove extern declaration of
19625 errno.
19626
19627 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
19628
19629 * gdbreplay.c, server.h, utils.c: Update copyright years.
19630
19631 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
19632
19633 * server.c (main): Print child status or termination signal from
19634 variable 'signal', not 'sig'.
19635
19636 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
19637
19638 * linux-low.c (linux_read_memory): Change return type to
19639 int. Check for and return error from ptrace().
19640 * target.c (read_inferior_memory): Change return type to int. Pass
19641 back return status from the_target->read_memory().
19642 * target.h (struct target_ops): Adapt *read_memory() prototype.
19643 Update comment.
19644 (read_inferior_memory): Adapt prototype.
19645 * server.c (main): Return an error packet if
19646 read_inferior_memory() returns an error.
19647
19648 2004-03-04 Daniel Jacobowitz <drow@mvista.com>
19649
19650 * Makefile.in (distclean): Remove config.h, stamp-h, and config.log.
19651 Unify with other clean targets.
19652
19653 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
19654
19655 * server.c (handle_v_cont): Call set_desired_inferior.
19656
19657 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
19658
19659 * remote-utils.c (prepare_resume_reply): Always supply "thread:".
19660
19661 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
19662
19663 * linux-low.c (linux_wait): Unblock async I/O.
19664 (linux_resume): Block and enable async I/O.
19665 * remote-utils.c (block_async_io, unblock_async_io): New functions.
19666 * server.h (block_async_io, unblock_async_io): Add prototypes.
19667
19668 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
19669
19670 * remote-utils.c (remote_open): Print a status notice after
19671 opening a TCP port.
19672 * server.c (attach_inferior): Print a status notice after
19673 attaching.
19674
19675 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
19676
19677 * linux-arm-low.c (arm_get_pc): Print out stop PC in debug mode.
19678
19679 2004-02-26 Daniel Jacobowitz <drow@mvista.com>
19680
19681 * remote-utils.c (write_enn): Use "E01" instead of "ENN" for the
19682 error packet.
19683 * server.c, target.h: Update copyright years.
19684
19685 2004-02-25 Roland McGrath <roland@redhat.com>
19686
19687 * target.h (struct target_ops): New member `read_auxv'.
19688 * server.c (handle_query): Handle qPart:auxv:read: query using that.
19689 * linux-low.c (linux_read_auxv): New function.
19690 (linux_target_ops): Initialize `read_auxv' member to that.
19691
19692 2004-02-17 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
19693
19694 Committed by Jim Blandy <jimb@redhat.com>.
19695
19696 * linux-s390-low.c (s390_num_regs): Update.
19697 (s390_regmap): Remove control registers. Use __s390x__ predefine
19698 instead of GPR_SIZE to distiguish s390 and s390x targets.
19699
19700 2004-01-31 Daniel Jacobowitz <drow@mvista.com>
19701
19702 * linux-low.c: Update copyright year.
19703 (check_removed_breakpoint): Clear pending_is_breakpoint.
19704 (linux_set_resume_request, linux_queue_one_thread)
19705 (resume_status_pending_p): New functions.
19706 (linux_continue_one_thread): Use process->resume.
19707 (linux_resume): Only resume threads if there are no pending events.
19708 * linux-low.h (struct process_info): Add resume request
19709 pointer.
19710
19711 2004-01-30 Daniel Jacobowitz <drow@mvista.com>
19712
19713 * regcache.c (new_register_cache): Clear the allocated register
19714 buffer. Suggested by Atsushi Nemoto <anemo@mba.ocn.ne.jp>.
19715
19716 2003-10-13 Daniel Jacobowitz <drow@mvista.com>
19717
19718 * linux-low.c (linux_resume): Take a struct thread_resume *
19719 argument.
19720 (linux_wait): Update call.
19721 (resume_ptr): New static variable.
19722 (linux_continue_one_thread): Renamed from
19723 linux_continue_one_process. Use resume_ptr.
19724 (linux_resume): Use linux_continue_one_thread.
19725 * server.c (handle_v_cont, handle_v_requests): New functions.
19726 (myresume): New function.
19727 (main): Handle 'v' case.
19728 * target.h (struct thread_resume): New type.
19729 (struct target_ops): Change argument of "resume" to struct
19730 thread_resume *.
19731 (myresume): Delete macro.
19732
19733 2003-08-08 H.J. Lu <hongjiu.lu@intel.com>
19734
19735 * Makefile.in (install-only): Create dest dir. Support DESTDIR.
19736 (uninstall): Support DESTDIR.
19737
19738 Mon Jul 21 20:09:34 UTC 2003 Brendan Conoboy <blc@redhat.com>
19739
19740 * configure.srv: Add xscale*linux copy of arm*linux entry.
19741
19742 2003-07-24 Daniel Jacobowitz <drow@mvista.com>
19743
19744 * linux-arm-low.c (arm_reinsert_addr): New function.
19745 (the_low_target): Add arm_reinsert_addr.
19746
19747 2003-07-08 Mark Kettenis <kettenis@gnu.org>
19748
19749 * mem-break.c: Remove whitespace at end of file.
19750
19751 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
19752
19753 * configure.in: Check whether we need to prototype strerror.
19754 * server.h: Optionally prototype strerror.
19755 * gdbreplay.c (perror_with_name): Use strerror.
19756 * linux-low.c (linux_attach_lwp): Use strerror.
19757 * utils.c (perror_with_name): Use strerror.
19758 * config.in, configure: Regenerated.
19759
19760 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
19761
19762 * linux-sh-low.c (sh_regmap): Fix FP register offsets, reported by
19763 SUGIOKA Toshinobu <sugioka@itonet.co.jp>.
19764
19765 2003-06-20 Daniel Jacobowitz <drow@mvista.com>
19766
19767 * Makefile.in (SFILES): Update.
19768 * low-hppabsd.c, low-lynx.c, low-nbsd.c, low-sim.c, low-sparc.c,
19769 low-sun3.c: Remove files.
19770
19771 2003-06-17 Daniel Jacobowitz <drow@mvista.com>
19772
19773 * linux-low.c: Move comment to linux_thread_alive where it belonged.
19774 (linux_detach_one_process, linux_detach): New functions.
19775 (linux_target_ops): Add linux_detach.
19776 * server.c (main): Handle 'D' packet.
19777 * target.h (struct target_ops): Add "detach" member.
19778 (detach_inferior): Define.
19779
19780 2003-06-13 Mark Kettenis <kettenis@gnu.org>
19781
19782 From Kelley Cook <kelleycook@wideopenwest.com>:
19783 * configure.srv: Accept i[34567]86 variants.
19784
19785 2003-06-05 Daniel Jacobowitz <drow@mvista.com>
19786
19787 * linux-low.c (linux_wait_for_event): Correct comment typos.
19788 (linux_resume_one_process): Call check_removed_breakpoint.
19789 (linux_send_signal): New function.
19790 (linux_target_ops): Add linux_send_signal.
19791 * remote-utils.c (putpkt, input_interrupt): Use send_signal instead
19792 of kill.
19793 * target.h (struct target_ops): Add send_signal.
19794
19795 2003-05-29 Jim Blandy <jimb@redhat.com>
19796
19797 * linux-low.c (usr_store_inferior_registers): Transfer buf in
19798 PTRACE_XFER_TYPE-sized chunks, not int-sized chunks. Otherwise,
19799 if 'int' is smaller than PTRACE_XFER_TYPE, you end up throwing
19800 away part of the register's value.
19801
19802 2003-03-26 Daniel Jacobowitz <drow@mvista.com>
19803
19804 * linux-low.c (linux_create_inferior): Use __SIGRTMIN.
19805 (linux_wait_for_event, linux_init_signals): Likewise.
19806
19807 2003-03-17 Daniel Jacobowitz <drow@mvista.com>
19808
19809 * configure.in: Check for stdlib.h.
19810 * configure: Regenerated.
19811 * config.in: Regenerated.
19812
19813 2003-01-04 Andreas Schwab <schwab@suse.de>
19814
19815 * linux-m68k-low.c (m68k_num_regs): Define to 29 instead of 31.
19816
19817 2003-01-02 Andrew Cagney <ac131313@redhat.com>
19818
19819 * Makefile.in: Remove obsolete code.
19820
19821 2002-11-20 Daniel Jacobowitz <drow@mvista.com>
19822
19823 * linux-s390-low.c (s390_regmap): Check GPR_SIZE instead of
19824 defined(PT_FPR0_HI).
19825
19826 2002-11-17 Stuart Hughes <seh@zee2.com>
19827
19828 * linux-arm-low.c (arm_num_regs): Increase.
19829 (arm_regmap): Include status register.
19830
19831 2002-11-17 Daniel Jacobowitz <drow@mvista.com>
19832
19833 * linux-low.c (register_addr): Remove incorrect -1 check.
19834
19835 2002-08-29 Daniel Jacobowitz <drow@mvista.com>
19836
19837 * linux-low.c (linux_create_inferior): Call setpgid. Return
19838 the new PID.
19839 (unstopped_p, linux_signal_pid): Remove.
19840 (linux_target_ops): Remove linux_signal_pid.
19841 * remote-utils.c (putpkt, input_interrupt): Use signal_pid
19842 global instead of target method.
19843 * target.h (struct target_ops): Remove signal_pid. Update comment
19844 for create_inferior.
19845 * server.c (signal_pid): New variable.
19846 (create_inferior): Set signal_pid. Block SIGTTOU and SIGTTIN in
19847 gdbserver. Set the child to be the foreground process group.
19848 (attach_inferior): Set signal_pid.
19849
19850 2002-08-23 Daniel Jacobowitz <drow@mvista.com>
19851
19852 * ChangeLog: New file, with entries from gdb/ChangeLog after GDB 5.2.
19853
19854 2002-08-20 Jim Blandy <jimb@redhat.com>
19855
19856 * Makefile.in (LDFLAGS): Allow the configure script to establish a
19857 default for this.
19858
19859 2002-08-01 Andrew Cagney <cagney@redhat.com>
19860
19861 * Makefile.in: Make chill references obsolete.
19862
19863 2002-07-24 Kevin Buettner <kevinb@redhat.com>
19864
19865 * configure.in (unistd.h): Add to AC_CHECK_HEADERS list.
19866 * configure: Regenerate.
19867 * config.in: Regenerate.
19868
19869 2002-07-09 David O'Brien <obrien@FreeBSD.org>
19870
19871 * gdbreplay.c (stdlib.h, unistd.h): Conditionaly include.
19872 (perror_with_name, remote_close, remote_open, expect, play): Static.
19873
19874 2002-07-04 Michal Ludvig <mludvig@suse.cz>
19875
19876 * linux-x86-64-low.c (x86_64_regmap): Make it an array of
19877 byte offsets instead of an array of indexes.
19878 (x86_64_store_gregset, x86_64_store_fpregset): Parameter made const.
19879
19880 2002-06-13 Daniel Jacobowitz <drow@mvista.com>
19881
19882 * regcache.c: Add comment.
19883
19884 2002-06-11 Daniel Jacobowitz <drow@mvista.com>
19885
19886 * thread-db.c: New file.
19887 * proc-service.c: New file.
19888 * acinclude.m4: New file.
19889 * Makefile.in: Add GDBSERVER_LIBS, gdb_proc_service_h,
19890 proc-service.o, and thread-db.o.
19891 (linux-low.o): Add USE_THREAD_DB.
19892 * acconfig.h: Add HAVE_PRGREGSET_T, HAVE_PRFPREGSET_T,
19893 HAVE_LWPID_T, HAVE_PSADDR_T, and PRFPREGSET_T_BROKEN.
19894 * aclocal.m4: Regenerated.
19895 * config.in: Regenerated.
19896 * configure: Regenerated.
19897 * configure.in: Check for proc_service.h, sys/procfs.h,
19898 thread_db.h, and linux/elf.h headrs.
19899 Check for lwpid_t, psaddr_t, prgregset_t, prfpregset_t, and
19900 PRFPREGSET_T_BROKEN. Introduce srv_thread_depfiles and USE_THREAD_DB.
19901 Check for -lthread_db and thread support.
19902 * configure.srv: Enable thread_db support for ARM, i386, MIPS,
19903 PowerPC, and SuperH.
19904 * i387-fp.c: Constify arguments.
19905 * i387-fp.h: Likewise.
19906 * inferiors.c: (struct thread_info): Renamed from
19907 `struct inferior_info'. Remove PID member. Use generic inferior
19908 list header. All uses updated.
19909 (inferiors, signal_pid): Removed.
19910 (all_threads): New variable.
19911 (get_thread): Define.
19912 (add_inferior_to_list): New function.
19913 (for_each_inferior): New function.
19914 (change_inferior_id): New function.
19915 (add_inferior): Removed.
19916 (remove_inferior): New function.
19917 (add_thread): New function.
19918 (free_one_thread): New function.
19919 (remove_thread): New function.
19920 (clear_inferiors): Use for_each_inferior and free_one_thread.
19921 (find_inferior): New function.
19922 (find_inferior_id): New function.
19923 (inferior_target_data): Update argument type.
19924 (set_inferior_target_data): Likewise.
19925 (inferior_regcache_data): Likewise.
19926 (set_inferior_regcache_data): Likewise.
19927 * linux-low.c (linux_bp_reinsert): Remove.
19928 (all_processes, stopping_threads, using_thrads)
19929 (struct pending_signals, debug_threads, pid_of): New.
19930 (inferior_pid): Replace with macro.
19931 (struct inferior_linux_data): Remove.
19932 (get_stop_pc, add_process): New functions.
19933 (linux_create_inferior): Restore SIGRTMIN+1 before calling exec.
19934 Use add_process and add_thread.
19935 (linux_attach_lwp): New function, based on old linux_attach. Use
19936 add_process and add_thread. Set stop_expected for new threads.
19937 (linux_attach): New function.
19938 (linux_kill_one_process): New function.
19939 (linux_kill): Kill all LWPs.
19940 (linux_thread_alive): Use find_inferior_id.
19941 (check_removed_breakpoints, status_pending_p): New functions.
19942 (linux_wait_for_process): Renamed from linux_wait_for_one_inferior.
19943 Update. Use WNOHANG. Wait for cloned processes also. Update process
19944 struct for the found process.
19945 (linux_wait_for_event): New function.
19946 (linux_wait): Use it. Support LWPs.
19947 (send_sigstop, wait_for_sigstop, stop_all_processes)
19948 (linux_resume_one_process, linux_continue_one_process): New functions.
19949 (linux_resume): Support LWPs.
19950 (REGISTER_RAW_SIZE): Remove.
19951 (fetch_register): Use register_size instead. Call supply_register.
19952 (usr_store_inferior_registers): Likewise. Call collect_register.
19953 Fix recursive case.
19954 (regsets_fetch_inferior_registers): Improve error message.
19955 (regsets_store_inferior_registers): Add debugging.
19956 (linux_look_up_symbols): Call thread_db_init if USE_THREAD_DB.
19957 (unstopped_p, linux_signal_pid): New functions.
19958 (linux_target_ops): Add linux_signal_pid.
19959 (linux_init_signals): New function.
19960 (initialize_low): Call it. Initialize using_threads.
19961 * regcache.c (inferior_regcache_data): Add valid
19962 flag.
19963 (get_regcache): Fetch registers lazily. Add fetch argument
19964 and update all callers.
19965 (regcache_invalidate_one, regcache_invalidate): New
19966 functions.
19967 (new_register_cache): Renamed from create_register_cache.
19968 Return the new regcache.
19969 (free_register_cache): Change argument to a void *.
19970 (registers_to_string, registers_from_string): Call get_regcache
19971 with fetch flag set.
19972 (register_data): Make static. Pass fetch flag to get_regcache.
19973 (supply_register): Call get_regcache with fetch flag clear.
19974 (collect_register): Call get_regcache with fetch flag set.
19975 (collect_register_as_string): New function.
19976 * regcache.h: Update.
19977 * remote-utils.c (putpkt): Flush after debug output and use
19978 stderr.
19979 Handle input interrupts while waiting for an ACK.
19980 (input_interrupt): Use signal_pid method.
19981 (getpkt): Flush after debug output and use stderr.
19982 (outreg): Use collect_register_as_string.
19983 (new_thread_notify, dead_thread_notify): New functions.
19984 (prepare_resume_reply): Check using_threads. Set thread_from_wait
19985 and general_thread.
19986 (look_up_one_symbol): Flush after debug output.
19987 * server.c (step_thread, server_waiting): New variables.
19988 (start_inferior): Don't use signal_pid. Update call to mywait.
19989 (attach_inferior): Update call to mywait.
19990 (handle_query): Handle qfThreadInfo and qsThreadInfo.
19991 (main): Don't fetch/store registers explicitly. Use
19992 set_desired_inferior. Support proposed ``Hs'' packet. Update
19993 calls to mywait.
19994 * server.h: Update.
19995 (struct inferior_list, struct_inferior_list_entry): New.
19996 * target.c (set_desired_inferior): New.
19997 (write_inferior_memory): Constify.
19998 (mywait): New function.
19999 * target.h: Update.
20000 (struct target_ops): New signal_pid method.
20001 (mywait): Removed macro, added prototype.
20002
20003 * linux-low.h (regset_func): Removed.
20004 (regset_fill_func, regset_store_func): New.
20005 (enum regset_type): New.
20006 (struct regset_info): Add type field. Use new operation types.
20007 (struct linux_target_ops): stop_pc renamed to get_pc.
20008 Add decr_pc_after_break and breakpoint_at.
20009 (get_process, get_thread_proess, get_process_thread)
20010 (strut process_info, all_processes, linux_attach_lwp)
20011 (thread_db_init): New.
20012
20013 * linux-arm-low.c (arm_get_pc, arm_set_pc,
20014 arm_breakpoint, arm_breakpoint_len, arm_breakpoint_at): New.
20015 (the_low_target): Add new members.
20016 * linux-i386-low.c (i386_store_gregset, i386_store_fpregset)
20017 (i386_store_fpxregset): Constify.
20018 (target_regsets): Add new kind identifier.
20019 (i386_get_pc): Renamed from i386_stop_pc. Simplify.
20020 (i386_set_pc): Add debugging.
20021 (i386_breakpoint_at): New function.
20022 (the_low_target): Add new members.
20023 * linux-mips-low.c (mips_get_pc, mips_set_pc)
20024 (mips_breakpoint, mips_breakpoint_len, mips_reinsert_addr)
20025 (mips_breakpoint_at): New.
20026 (the_low_target): Add new members.
20027 * linux-ppc-low.c (ppc_get_pc, ppc_set_pc)
20028 (ppc_breakpoint, ppc_breakpoint_len, ppc_breakpoint_at): New.
20029 (the_low_target): Add new members.
20030 * linux-sh-low.c (sh_get_pc, sh_set_pc)
20031 (sh_breakpoint, sh_breakpoint_len, sh_breakpoint_at): New.
20032 (the_low_target): Add new members.
20033 * linux-x86-64-low.c (target_regsets): Add new kind
20034 identifier.
20035
20036 2002-05-15 Daniel Jacobowitz <drow@mvista.com>
20037
20038 From Martin Pool <mbp@samba.org>:
20039 * server.c (gdbserver_usage): New function.
20040 (main): Call it.
20041
20042 2002-05-14 Daniel Jacobowitz <drow@mvista.com>
20043
20044 * mem-break.c (reinsert_breakpoint_by_bp): Correct typo
20045 stop_at -> stop_pc.
20046
20047 2002-05-04 Andrew Cagney <ac131313@redhat.com>
20048
20049 * Makefile.in: Remove obsolete code.
20050
20051 2002-04-24 Michal Ludvig <mludvig@suse.cz>
20052
20053 * linux-low.c (regsets_fetch_inferior_registers),
20054 (regsets_store_inferior_registers): Removed cast to int from
20055 ptrace() calls.
20056 * regcache.h: Added declaration of struct inferior_info.
20057
20058 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
20059
20060 * inferiors.c (struct inferior_info): Add regcache_data.
20061 (add_inferior): Call create_register_cache.
20062 (clear_inferiors): Call free_register_cache.
20063 (inferior_regcache_data, set_inferior_regcache_data): New functions.
20064 * regcache.c (struct inferior_regcache_data): New.
20065 (registers): Remove.
20066 (get_regcache): New function.
20067 (create_register_cache, free_register_cache): New functions.
20068 (set_register_cache): Don't initialize the register cache here.
20069 (registers_to_string, registers_from_string, register_data): Call
20070 get_regcache.
20071 * regcache.h: Add prototypes.
20072 * server.h: Likewise.
20073
20074 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
20075
20076 * mem-break.c: New file.
20077 * mem-break.h: New file.
20078 * Makefile.in: Add mem-break.o rule; update server.h
20079 dependencies.
20080 * inferiors.c (struct inferior_info): Add target_data
20081 member.
20082 (clear_inferiors): Free target_data member if set.
20083 (inferior_target_data, set_inferior_target_data): New functions.
20084 * linux-i386-low.c (i386_breakpoint, i386_breakpoint_len)
20085 (i386_stop_pc, i386_set_pc): New. Add to the_low_target.
20086 * linux-low.c (linux_bp_reinsert): New variable.
20087 (struct inferior_linux_data): New.
20088 (linux_create_inferior): Use set_inferior_target_data.
20089 (linux_attach): Likewise. Call add_inferior.
20090 (linux_wait_for_one_inferior): New function.
20091 (linux_wait): Call it.
20092 (linux_write_memory): Add const.
20093 (initialize_low): Call set_breakpoint_data.
20094 * linux-low.h (struct linux_target_ops): Add breakpoint
20095 handling members.
20096 * server.c (attach_inferior): Remove extra add_inferior
20097 call.
20098 * server.h: Include mem-break.h. Update inferior.c
20099 prototypes.
20100 * target.c (read_inferior_memory)
20101 (write_inferior_memory): New functions.
20102 * target.h (read_inferior_memory)
20103 (write_inferior_memory): Change macros to prototypes.
20104 (struct target_ops): Update comments. Add const to write_memory
20105 definition.
20106
20107 2002-04-11 Daniel Jacobowitz <drow@mvista.com>
20108
20109 * linux-low.c (usr_store_inferior_registers): Support
20110 registers which are allowed to fail to store.
20111 * linux-low.h (linux_target_ops): Likewise.
20112 * linux-ppc-low.c (ppc_regmap): Support FPSCR.
20113 (ppc_cannot_store_register): FPSCR may not be storable.
20114
20115 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
20116
20117 * server.h: Include <string.h> if HAVE_STRING_H.
20118 * ChangeLog: Correct paths in last ChangeLog entry.
20119
20120 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
20121
20122 * linux-low.h: Remove obsolete prototypes.
20123 (struct linux_target_ops): New.
20124 (extern the_low_target): New.
20125 * linux-low.c (num_regs, regmap): Remove declarations.
20126 (register_addr): Use the_low_target explicitly.
20127 (fetch_register): Likewise.
20128 (usr_fetch_inferior_registers): Likewise.
20129 (usr_store_inferior_registers): Likewise.
20130 * linux-arm-low.c (num_regs): Remove.
20131 (arm_num_regs): Define.
20132 (arm_regmap): Renamed from regmap, made static.
20133 (arm_cannot_fetch_register): Renamed from cannot_fetch_register,
20134 made static.
20135 (arm_cannot_store_register): Renamed from cannot_store_register,
20136 made static.
20137 (the_low_target): New.
20138 * linux-i386-low.c (num_regs): Remove.
20139 (i386_num_regs): Define.
20140 (i386_regmap): Renamed from regmap, made static.
20141 (i386_cannot_fetch_register): Renamed from cannot_fetch_register,
20142 made static.
20143 (i386_cannot_store_register): Renamed from cannot_store_register,
20144 made static.
20145 (the_low_target): New.
20146 * linux-ia64-low.c (num_regs): Remove.
20147 (ia64_num_regs): Define.
20148 (ia64_regmap): Renamed from regmap, made static.
20149 (ia64_cannot_fetch_register): Renamed from cannot_fetch_register,
20150 made static.
20151 (ia64_cannot_store_register): Renamed from cannot_store_register,
20152 made static.
20153 (the_low_target): New.
20154 * linux-m68k-low.c (num_regs): Remove.
20155 (m68k_num_regs): Define.
20156 (m68k_regmap): Renamed from regmap, made static.
20157 (m68k_cannot_fetch_register): Renamed from cannot_fetch_register,
20158 made static.
20159 (m68k_cannot_store_register): Renamed from cannot_store_register,
20160 made static.
20161 (the_low_target): New.
20162 * linux-mips-low.c (num_regs): Remove.
20163 (mips_num_regs): Define.
20164 (mips_regmap): Renamed from regmap, made static.
20165 (mips_cannot_fetch_register): Renamed from cannot_fetch_register,
20166 made static.
20167 (mips_cannot_store_register): Renamed from cannot_store_register,
20168 made static.
20169 (the_low_target): New.
20170 * linux-ppc-low.c (num_regs): Remove.
20171 (ppc_num_regs): Define.
20172 (ppc_regmap): Renamed from regmap, made static.
20173 (ppc_cannot_fetch_register): Renamed from cannot_fetch_register,
20174 made static.
20175 (ppc_cannot_store_register): Renamed from cannot_store_register,
20176 made static.
20177 (the_low_target): New.
20178 * linux-s390-low.c (num_regs): Remove.
20179 (s390_num_regs): Define.
20180 (s390_regmap): Renamed from regmap, made static.
20181 (s390_cannot_fetch_register): Renamed from cannot_fetch_register,
20182 made static.
20183 (s390_cannot_store_register): Renamed from cannot_store_register,
20184 made static.
20185 (the_low_target): New.
20186 * linux-sh-low.c (num_regs): Remove.
20187 (sh_num_regs): Define.
20188 (sh_regmap): Renamed from regmap, made static.
20189 (sh_cannot_fetch_register): Renamed from cannot_fetch_register,
20190 made static.
20191 (sh_cannot_store_register): Renamed from cannot_store_register,
20192 made static.
20193 (the_low_target): New.
20194 * linux-x86-64-low.c (x86_64_regmap): Renamed from regmap.
20195 (the_low_target): New.
20196
20197 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
20198
20199 * Makefile.in: Add stamp-h target.
20200 * configure.in: Create stamp-h.
20201 * configure: Regenerated.
20202
20203 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
20204
20205 * inferiors.c: New file.
20206 * target.c: New file.
20207 * target.h: New file.
20208 * Makefile.in: Add target.o and inferiors.o. Update
20209 dependencies.
20210 * linux-low.c (inferior_pid): New static variable,
20211 moved from server.c.
20212 (linux_create_inferior): Renamed from create_inferior.
20213 Call add_inferior. Return 0 on success instead of a PID.
20214 (linux_attach): Renamed from myattach.
20215 (linux_kill): Renamed from kill_inferior. Call clear_inferiors ().
20216 (linux_thread_alive): Renamed from mythread_alive.
20217 (linux_wait): Renamed from mywait. Call clear_inferiors () if the
20218 child dies.
20219 (linux_resume): Renamed from myresume. Add missing ``return 0''.
20220 (regsets_store_inferior_registers): Correct error message.
20221 Add missing ``return 0''.
20222 (linux_fetch_registers): Renamed from fetch_inferior_registers.
20223 (linux_store_registers): Renamed from store_inferior_registers.
20224 (linux_read_memory): Renamed from read_inferior_memory.
20225 (linux_write_memory): Renamed from write_inferior_memory.
20226 (linux_target_ops): New structure.
20227 (initialize_low): Call set_target_ops ().
20228 * remote-utils.c (unhexify): New function.
20229 (hexify): New function.
20230 (input_interrupt): Send signals to ``signal_pid''.
20231 * server.c (inferior_pid): Remove.
20232 (start_inferior): Update create_inferior call.
20233 (attach_inferior): Call add_inferior.
20234 (handle_query): New function.
20235 (main): Call handle_query for `q' packets.
20236 * server.h: Include "target.h". Remove obsolete prototypes.
20237 Add prototypes for "inferiors.c", "target.c", hexify, and unhexify.
20238
20239 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
20240
20241 * Makefile.in: Add WARN_CFLAGS. Update configury
20242 dependencies.
20243 * configure.in: Check for <string.h>
20244 * configure: Regenerate.
20245 * config.in: Regenerate.
20246 * gdbreplay.c: Include needed system headers.
20247 (remote_open): Remove strchr prototype.
20248 * linux-low.h: Correct #ifdef to HAVE_LINUX_USRREGS.
20249 * regcache.c (supply_register): Change buf argument to const void *.
20250 (supply_register_by_name): Likewise.
20251 (collect_register): Change buf argument to void *.
20252 (collect_register_by_name): Likewise.
20253 * regcache.h: Add missing prototypes.
20254 * remote-utils.c: Include <arpa/inet.h> for inet_ntoa.
20255 * server.c (handle_query): New function.
20256 (attached): New static variable, moved out of main.
20257 (main): Quiet longjmp clobber warnings.
20258 * server.h: Add ATTR_NORETURN and ATTR_FORMAT. Update prototypes.
20259 * utils.c (error): Remove NORETURN.
20260 (fatal): Likewise.
This page took 0.445647 seconds and 3 git commands to generate.