1 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
3 * Makefile.in (.SECONDARY): Define target.
5 2017-09-03 Simon Marchi <simon.marchi@ericsson.com>
7 * linux-low.c (linux_wait_1): Adjust.
8 * server.c (queue_stop_reply_callback): Adjust.
10 2017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
12 * server.c (handle_general_set): Handle QEnvironmentHexEncoded,
13 QEnvironmentUnset and QEnvironmentReset packets.
14 (handle_query): Inform remote that QEnvironmentHexEncoded,
15 QEnvironmentUnset and QEnvironmentReset are supported.
17 2017-08-25 Simon Marchi <simon.marchi@ericsson.com>
19 * inferiors.h (inferior_target_data): Rename to ...
20 (thread_target_data): ... this.
21 (inferior_regcache_data): Rename to ...
22 (thread_regcache_data): ... this.
23 (set_inferior_regcache_data): Rename to ...
24 (set_thread_regcache_data): ... this.
25 * inferiors.c (inferior_target_data): Rename to ...
26 (thread_target_data): ... this.
27 (inferior_regcache_data): Rename to ...
28 (thread_regcache_data): ... this.
29 (set_inferior_regcache_data): Rename to ...
30 (set_thread_regcache_data): ... this.
31 (free_one_thread): Update.
32 * linux-low.h (get_thread_lwp): Update.
33 * regcache.c (get_thread_regcache): Update.
34 (regcache_invalidate_thread): Update.
35 (free_register_cache_thread): Update.
36 * win32-i386-low.c (update_debug_registers_callback): Update.
37 (win32_get_current_dr): Update.
38 * win32-low.c (thread_rec): Update.
39 (delete_thread_info): Update.
40 (continue_one_thread): Update.
41 (suspend_one_thread): Update.
43 2017-08-24 Simon Marchi <simon.marchi@ericsson.com>
45 * inferiors.c (set_inferior_target_data): Remove.
46 * inferiors.h (set_inferior_target_data): Remove.
48 2017-08-18 Yao Qi <yao.qi@linaro.org>
50 * Makefile.in (OBS): Add selftest.o.
51 * configure.ac: AC_DEFINE GDB_SELF_TEST if $development.
52 * configure, config.in: Re-generated.
53 * server.c: Include common/sefltest.h.
54 (captured_main): Handle option --selftest.
56 2017-08-09 Yao Qi <yao.qi@linaro.org>
58 * configure.srv (srv_i386_regobj): Remove i386-avx.o,
59 i386-avx-avx512.o, i386-avx-mpx-avx512-pku.o, i386-mpx.o,
60 i386-avx-mpx.o and i386-mmx.o.
61 (srv_amd64_regobj): Remove amd64-avx.o, amd64-avx-avx512.o,
62 amd64-avx-mpx-avx512-pku.o, amd64-mpx.o and amd64-avx-mpx.o.
63 (srv_i386_xmlfiles): Remove i386/i386-avx.xml,
64 i386/i386-avx-avx512.xml, i386/i386-avx-mpx-avx512-pku.xml,
65 i386/i386-mpx.xml, i386/i386-avx-mpx.xml and i386/i386-mmx.xml.
66 (srv_amd64_xmlfile):i386/amd64-avx.xml, i386/amd64-avx-avx512.xml,
67 i386/amd64-avx-mpx-avx512-pku.xml, i386/amd64-mpx.xml,
68 i386/amd64-avx-mpx.xml.
70 2017-08-09 Yao Qi <yao.qi@linaro.org>
72 * configure.srv (srv_amd64_regobj): Remove x32.o, x32-avx.o
74 (srv_amd64_xmlfiles): Remove i386/x32.xml, i386/x32-avx.xml
75 i386/x32-avx-avx512.xml.
77 2017-07-26 Simon Marchi <simon.marchi@ericsson.com>
79 * tracepoint.h (enum class fast_tpoint_collect_result): New
81 (fast_tracepoint_collecting): Change return type to
82 fast_tpoint_collect_result.
83 * tracepoint.c (fast_tracepoint_collecting): Likewise.
84 * linux-low.h: Include tracepoint.h.
85 (struct lwp_info) <collecting_fast_tracepoint>: Change type to
86 fast_tpoint_collect_result.
87 * linux-low.c (handle_tracepoints): Adjust.
88 (linux_fast_tracepoint_collecting): Change return type to
89 fast_tpoint_collect_result.
90 (maybe_move_out_of_jump_pad, linux_wait_for_event_filtered,
91 linux_wait_1, stuck_in_jump_pad_callback,
92 lwp_signal_can_be_delivered, linux_resume_one_lwp_throw,
93 proceed_one_lwp): Adjust to type change.
95 2017-07-10 Yao Qi <yao.qi@linaro.org>
97 * linux-x86-low.c (x86_linux_read_description): Re-indent the code.
99 2017-06-29 Yao Qi <yao.qi@linaro.org>
101 * tdesc.h (struct target_desc) [IN_PROCESS_AGENT] <expedite_regs>:
103 [IN_PROCESS_AGENT] <xmltarget>: Likewise.
105 2017-06-20 Simon Marchi <simon.marchi@ericsson.com>
107 * Makefile.in (IPA_OBJS): Sort and format one item per line.
109 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
111 * linux-low.c (linux_create_inferior): Adjust code to access the
112 environment information via 'gdb_environ' class.
113 * lynx-low.c (lynx_create_inferior): Likewise.
114 * server.c (our_environ): Make it an instance of 'gdb_environ'.
115 (get_environ): Return a pointer to 'our_environ'.
116 (captured_main): Initialize 'our_environ'.
117 * server.h (get_environ): Adjust prototype.
118 * spu-low.c (spu_create_inferior): Adjust code to access the
119 environment information via 'gdb_environ' class.
121 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
123 * linux-low.c (linux_read_memory, linux_write_memory): Remove
124 usage of "register" keyword.
126 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
128 * configure: Re-generate.
130 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
132 * configure: Re-generate.
134 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
136 * Makefile.in (COMPILE.pre): Add "-x c++".
138 2017-06-09 Sergio Durigan Junior <sergiodj@redhat.com>
140 * fork-child.c: Conditionally include <signal.h>.
142 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
144 * server.c (handle_general_set): Handle new packet
146 (handle_query): Add "QStartupWithShell" to the list of supported
148 (gdbserver_usage): Add help text explaining the
149 new "--startup-with-shell" and "--no-startup-with-shell" CLI
151 (captured_main): Recognize and act upon the presence of the new
154 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
155 Pedro Alves <palves@redhat.com>
157 * Makefile.in (SFILES): Add "nat/fork-inferior.o".
158 * configure: Regenerate.
159 * configure.srv (srv_linux_obj): Add "fork-child.o" and
161 (i[34567]86-*-lynxos*): Likewise.
162 (spu*-*-*): Likewise.
163 * fork-child.c: New file.
164 * linux-low.c: Include "common-inferior.h", "nat/fork-inferior.h"
166 (linux_ptrace_fun): New function.
167 (linux_create_inferior): Adjust function prototype to reflect
168 change on "target.h". Adjust function code to use
170 (linux_request_interrupt): Delete "signal_pid".
171 * lynx-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
172 (lynx_ptrace_fun): New function.
173 (lynx_create_inferior): Adjust function prototype to reflect
174 change on "target.h". Adjust function code to use
176 * nto-low.c (nto_create_inferior): Adjust function prototype and
177 code to reflect change on "target.h". Update comments.
178 * server.c: Include "common-inferior.h", "nat/fork-inferior.h",
179 "common-terminal.h" and "environ.h".
180 (terminal_fd): Moved to fork-child.c.
181 (old_foreground_pgrp): Likewise.
182 (restore_old_foreground_pgrp): Likewise.
183 (last_status): Make it global.
184 (last_ptid): Likewise.
185 (our_environ): New variable.
186 (startup_with_shell): Likewise.
187 (program_name): Likewise.
188 (program_argv): Rename to...
189 (program_args): ...this.
190 (wrapper_argv): New variable.
191 (start_inferior): Delete function.
192 (get_exec_wrapper): New function.
193 (get_exec_file): Likewise.
194 (get_environ): Likewise.
195 (prefork_hook): Likewise.
196 (post_fork_inferior): Likewise.
197 (postfork_hook): Likewise.
198 (postfork_child_hook): Likewise.
199 (handle_v_run): Update code to deal with arguments coming from the
200 remote host. Update calls from "start_inferior" to
202 (captured_main): Likewise. Initialize environment variable. Call
204 * server.h (post_fork_inferior): New prototype.
205 (get_environ): Likewise.
206 (last_status): Declare.
207 (last_ptid): Likewise.
208 (signal_pid): Likewise.
209 * spu-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
210 (spu_ptrace_fun): New function.
211 (spu_create_inferior): Adjust function prototype to reflect change
212 on "target.h". Adjust function code to use "fork_inferior".
213 * target.c (target_terminal_init): New function.
214 (target_terminal_inferior): Likewise.
215 (target_terminal_ours): Likewise.
216 * target.h: Include <vector>.
217 (struct target_ops) <create_inferior>: Update prototype.
218 (create_inferior): Update macro.
219 * utils.c (gdb_flush_out_err): New function.
220 * win32-low.c (win32_create_inferior): Adjust function prototype
221 and code to reflect change on "target.h".
223 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
225 * inferiors.c (switch_to_thread): New function.
227 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
229 * Makefile.in (SFILE): Add "common/job-control.c".
230 (OBS): Add "job-control.o".
232 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
234 * Makefile: Remove "@host_makefile_frag@".
236 2017-05-05 Pedro Alves <palves@redhat.com>
238 * configure: Regenerate.
240 2017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
242 * configure: Regenerate.
244 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
246 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Adjust to
247 software_single_step change of return type to
248 std::vector<CORE_ADDR>.
249 * linux-low.c (install_software_single_step_breakpoints):
251 * linux-low.h (install_software_single_step_breakpoints):
254 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
256 * remote-utils.c: Include "gdb_termios.h" instead of
258 * terminal.h: Delete file.
260 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
262 * server.c: Include <vector>.
263 <program_argv, wrapper_argv>: Convert to std::vector.
264 (start_inferior): Rewrite function to use C++.
265 (handle_v_run): Likewise. Update code that calculates the argv
266 based on the vRun packet; use C++.
267 (captured_main): Likewise.
269 2017-04-06 Simon Marchi <simon.marchi@ericsson.com>
271 * server.c (handle_v_cont): Initialize thread_resume::thread
274 2017-04-05 Pedro Alves <palves@redhat.com>
276 * configure: Regenerate.
278 2017-04-05 Pedro Alves <palves@redhat.com>
280 * gdbreplay.c (sync_error): Constify.
281 * linux-x86-low.c (push_opcode): Constify.
283 2017-04-05 Pedro Alves <palves@redhat.com>
285 * win32-low.c (get_child_debug_event)
286 <CREATE_PROCESS_DEBUG_EVENT>: Don't report TARGET_WAITKIND_EXECD.
287 Report TARGET_WAITKIND_SPURIOUS instead.
289 2017-04-05 Pedro Alves <palves@redhat.com>
291 * remote-utils.c (remote_prepare, remote_open): Constify.
292 * remote-utils.h (remote_prepare, remote_open): Constify.
293 * server.c (captured_main): Constify 'port' handling.
295 2017-04-04 Simon Marchi <simon.marchi@ericsson.com>
297 * Makefile.in (clean): Clear .deps.
299 2017-03-31 Simon Marchi <simon.marchi@polymtl.ca>
301 * .gitignore: Remove generated files, replace with wildcard.
302 * (clean): Replace removal of generated files with wildcard.
303 (version.c): Replace with...
304 (version-generated.c): ...this.
305 (xml-builtin.c): Replace with...
306 (xml-builtin-generated.c): ...this.
307 (%-ipa.o: %-generated.c, %.o: %-generated.c): New rules.
308 (%.c: *regformats*): Replace with...
309 (%-generated.c: *regformats*): ...this.
311 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
313 * linux-xtensa-low.c (regnum::R_THREADPTR): New enum member.
314 (xtensa_fill_gregset): Call collect_register_by_name for
316 (xtensa_store_gregset): Call supply_register_by_name for
319 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
321 * linux-xtensa-low.c (xtensa_fill_gregset): Call collect_register
322 for all registers in a0_regnum..a0_regnum + C0_NREGS range.
323 (xtensa_store_gregset): Call supply_register for all registers in
324 a0_regnum..a0_regnum + C0_NREGS range.
326 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
328 * Makefile.in (%-ipa.o: %-ipa.c): New rule.
329 (ax-ipa.o: ax.c): Remove.
330 (linux-i386-ipa.o: linux-i386-ipa.c): Remove.
331 (linux-amd64-ipa.o: linux-amd64-ipa.c): Remove.
332 (linux-aarch64-ipa.o: linux-aarch64-ipa.c): Remove.
333 (linux-s390-ipa.o: linux-s390-ipa.c): Remove.
334 (linux-ppc-ipa.o: linux-ppc-ipa.c): Remove.
336 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
338 * Makefile.in (%-ipa.o: ../common/%.c): New rule.
339 (print-utils-ipa.o: ../common/print-utils.c): Remove.
340 (rsp-low-ipa.o: ../common/rsp-low.c): Remove.
341 (errors-ipa.o: ../common/errors.c): Remove.
342 (format-ipa.o: ../common/format.c): Remove.
343 (common-utils-ipa.o: ../common/common-utils.c): Remove.
345 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
347 * Makefile.in (%-ipa.o: %.c): New rule.
348 (tracepoint-ipa.o: tracepoint.c): Remove.
349 (utils-ipa.o: utils.c): Remove.
350 (remote-utils-ipa.o: remote-utils.c): Remove.
351 (regcache-ipa.o: regcache.c): Remove.
352 (i386-linux-ipa.o: i386-linux.c): Remove.
353 (i386-mmx-linux-ipa.o: i386-mmx-linux.c): Remove.
354 (i386-avx-linux-ipa.o: i386-avx-linux.c): Remove.
355 (i386-mpx-linux-ipa.o: i386-mpx-linux.c): Remove.
356 (i386-avx-mpx-linux-ipa.o: i386-avx-mpx-linux.c): Remove.
357 (i386-avx-avx512-linux-ipa.o: i386-avx-avx512-linux.c): Remove.
358 (i386-avx-mpx-avx512-pku-linux-ipa.o: i386-avx-mpx-avx512-pku-linux.c): Remove.
359 (amd64-linux-ipa.o: amd64-linux.c): Remove.
360 (amd64-avx-linux-ipa.o: amd64-avx-linux.c): Remove.
361 (amd64-mpx-linux-ipa.o: amd64-mpx-linux.c): Remove.
362 (amd64-avx-mpx-linux-ipa.o: amd64-avx-mpx-linux.c): Remove.
363 (amd64-avx-avx512-linux-ipa.o: amd64-avx-avx512-linux.c): Remove.
364 (amd64-avx-mpx-avx512-pku-linux-ipa.o: amd64-avx-mpx-avx512-pku-linux.c): Remove.
365 (aarch64-ipa.o: aarch64.c): Remove.
366 (s390-linux32-ipa.o: s390-linux32.c): Remove.
367 (s390-linux32v1-ipa.o: s390-linux32v1.c): Remove.
368 (s390-linux32v2-ipa.o: s390-linux32v2.c): Remove.
369 (s390-linux64-ipa.o: s390-linux64.c): Remove.
370 (s390-linux64v1-ipa.o: s390-linux64v1.c): Remove.
371 (s390-linux64v2-ipa.o: s390-linux64v2.c): Remove.
372 (s390-te-linux64-ipa.o: s390-te-linux64.c): Remove.
373 (s390-vx-linux64-ipa.o: s390-vx-linux64.c): Remove.
374 (s390-tevx-linux64-ipa.o: s390-tevx-linux64.c): Remove.
375 (s390x-linux64-ipa.o: s390x-linux64.c): Remove.
376 (s390x-linux64v1-ipa.o: s390x-linux64v1.c): Remove.
377 (s390x-linux64v2-ipa.o: s390x-linux64v2.c): Remove.
378 (s390x-te-linux64-ipa.o: s390x-te-linux64.c): Remove.
379 (s390x-vx-linux64-ipa.o: s390x-vx-linux64.c): Remove.
380 (s390x-tevx-linux64-ipa.o: s390x-tevx-linux64.c): Remove.
381 (powerpc-32l-ipa.o: powerpc-32l.c): Remove.
382 (powerpc-altivec32l-ipa.o: powerpc-altivec32l.c): Remove.
383 (powerpc-cell32l-ipa.o: powerpc-cell32l.c): Remove.
384 (powerpc-vsx32l-ipa.o: powerpc-vsx32l.c): Remove.
385 (powerpc-isa205-32l-ipa.o: powerpc-isa205-32l.c): Remove.
386 (powerpc-isa205-altivec32l-ipa.o: powerpc-isa205-altivec32l.c): Remove.
387 (powerpc-isa205-vsx32l-ipa.o: powerpc-isa205-vsx32l.c): Remove.
388 (powerpc-e500l-ipa.o: powerpc-e500l.c): Remove.
389 (powerpc-64l-ipa.o: powerpc-64l.c): Remove.
390 (powerpc-altivec64l-ipa.o: powerpc-altivec64l.c): Remove.
391 (powerpc-cell64l-ipa.o: powerpc-cell64l.c): Remove.
392 (powerpc-vsx64l-ipa.o: powerpc-vsx64l.c): Remove.
393 (powerpc-isa205-64l-ipa.o: powerpc-isa205-64l.c): Remove.
394 (powerpc-isa205-altivec64l-ipa.o: powerpc-isa205-altivec64l.c): Remove.
395 (powerpc-isa205-vsx64l-ipa.o: powerpc-isa205-vsx64l.c): Remove.
396 (tdesc-ipa.o: tdesc.c): Remove.
397 (x32-linux-ipa.o: x32-linux.c): Remove.
398 (x32-avx-linux-ipa.o: x32-avx-linux.c): Remove.
399 (x32-avx512-linux-ipa.o: x32-avx512-linux.c): Remove.
401 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
403 * Makefile.in (%.o: ../arch/%.c): New rule.
404 (arm.o: ../arch/arm.c): Remove.
405 (arm-linux.o: ../arch/arm-linux.c): Remove.
406 (arm-get-next-pcs.o: ../arch/arm-get-next-pcs.c): Remove.
407 (aarch64-insn.o: ../arch/aarch64-insn.c): Remove.
409 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
411 * Makefile.in (%.o: ../nat/%.c): New rule.
412 (x86-dregs.o: ../nat/x86-dregs.c): Remove.
413 (amd64-linux-siginfo.o: ../nat/amd64-linux-siginfo.c): Remove.
414 (linux-btrace.o: ../nat/linux-btrace.c): Remove.
415 (linux-osdata.o: ../nat/linux-osdata.c): Remove.
416 (linux-procfs.o: ../nat/linux-procfs.c): Remove.
417 (linux-ptrace.o: ../nat/linux-ptrace.c): Remove.
418 (linux-waitpid.o: ../nat/linux-waitpid.c): Remove.
419 (mips-linux-watch.o: ../nat/mips-linux-watch.c): Remove.
420 (ppc-linux.o: ../nat/ppc-linux.c): Remove.
421 (linux-personality.o: ../nat/linux-personality.c): Remove.
422 (aarch64-linux-hw-point.o: ../nat/aarch64-linux-hw-point.c): Remove.
423 (aarch64-linux.o: ../nat/aarch64-linux.c): Remove.
424 (x86-linux.o: ../nat/x86-linux.c): Remove.
425 (x86-linux-dregs.o: ../nat/x86-linux-dregs.c): Remove.
426 (linux-namespaces.o: ../nat/linux-namespaces.c): Remove.
428 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
430 * Makefile.in (%.o: ../common/%.c): New rule.
431 (signals.o: ../common/signals.c): Remove.
432 (print-utils.o: ../common/print-utils.c): Remove.
433 (rsp-low.o: ../common/rsp-low.c): Remove.
434 (common-utils.o: ../common/common-utils.c): Remove.
435 (posix-strerror.o: ../common/posix-strerror.c): Remove.
436 (mingw-strerror.o: ../common/mingw-strerror.c): Remove.
437 (vec.o: ../common/vec.c): Remove.
438 (gdb_vecs.o: ../common/gdb_vecs.c): Remove.
439 (xml-utils.o: ../common/xml-utils.c): Remove.
440 (ptid.o: ../common/ptid.c): Remove.
441 (buffer.o: ../common/buffer.c): Remove.
442 (format.o: ../common/format.c): Remove.
443 (filestuff.o: ../common/filestuff.c): Remove.
444 (agent.o: ../common/agent.c): Remove.
445 (errors.o: ../common/errors.c): Remove.
446 (environ.o: ../common/environ.c): Remove.
447 (common-debug.o: ../common/common-debug.c): Remove.
448 (cleanups.o: ../common/cleanups.c): Remove.
449 (common-exceptions.o: ../common/common-exceptions.c): Remove.
450 (fileio.o: ../common/fileio.c): Remove.
451 (common-regcache.o: ../common/common-regcache.c): Remove.
452 (signals-state-save-restore.o: ../common/signals-state-save-restore.c): Remove.
453 (new-op.o: ../common/new-op.c): Remove.
454 (btrace-common.o: ../common/btrace-common.c): Remove.
456 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
458 * Makefile.in (%.o: ../target/%.c): New rule.
459 (waitstatus.o: ../target/waitstatus.c): Remove.
461 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
464 (%.c: ../regformats/%.dat,
465 (%.c: ../regformats/arm/%.dat,
466 (%.c: ../regformats/i386/%.dat,
467 (%.c: ../regformats/rs6000/%.dat): New rules.
470 (arm-with-iwmmxt.c): Remove.
471 (arm-with-vfpv2.c): Remove.
472 (arm-with-vfpv3.c): Remove.
473 (arm-with-neon.c): Remove.
474 (reg-bfin.c): Remove.
475 (reg-cris.c): Remove.
476 (reg-crisv32.c): Remove.
478 (i386-linux.c): Remove.
479 (i386-avx.c): Remove.
480 (i386-avx-linux.c): Remove.
481 (i386-avx-avx512.c): Remove.
482 (i386-avx-avx512-linux.c): Remove.
483 (i386-mpx.c): Remove.
484 (i386-mpx-linux.c): Remove.
485 (i386-avx-mpx-avx512-pku.c): Remove.
486 (i386-avx-mpx-avx512-pku-linux.c): Remove.
487 (i386-avx-mpx.c): Remove.
488 (i386-avx-mpx-linux.c): Remove.
489 (i386-mmx.c): Remove.
490 (i386-mmx-linux.c): Remove.
491 (reg-ia64.c): Remove.
492 (reg-m32r.c): Remove.
493 (reg-m68k.c): Remove.
495 (mips-linux.c): Remove.
496 (mips-dsp-linux.c): Remove.
497 (mips64-linux.c): Remove.
498 (mips64-dsp-linux.c): Remove.
499 (nios2-linux.c): Remove.
500 (powerpc-32.c): Remove.
501 (powerpc-32l.c): Remove.
502 (powerpc-altivec32l.c): Remove.
503 (powerpc-cell32l.c): Remove.
504 (powerpc-vsx32l.c): Remove.
505 (powerpc-isa205-32l.c): Remove.
506 (powerpc-isa205-altivec32l.c): Remove.
507 (powerpc-isa205-vsx32l.c): Remove.
508 (powerpc-e500l.c): Remove.
509 (powerpc-64l.c): Remove.
510 (powerpc-altivec64l.c): Remove.
511 (powerpc-cell64l.c): Remove.
512 (powerpc-vsx64l.c): Remove.
513 (powerpc-isa205-64l.c): Remove.
514 (powerpc-isa205-altivec64l.c): Remove.
515 (powerpc-isa205-vsx64l.c): Remove.
516 (s390-linux32.c): Remove.
517 (s390-linux32v1.c): Remove.
518 (s390-linux32v2.c): Remove.
519 (s390-linux64.c): Remove.
520 (s390-linux64v1.c): Remove.
521 (s390-linux64v2.c): Remove.
522 (s390-te-linux64.c): Remove.
523 (s390-vx-linux64.c): Remove.
524 (s390-tevx-linux64.c): Remove.
525 (s390x-linux64.c): Remove.
526 (s390x-linux64v1.c): Remove.
527 (s390x-linux64v2.c): Remove.
528 (s390x-te-linux64.c): Remove.
529 (s390x-vx-linux64.c): Remove.
530 (s390x-tevx-linux64.c): Remove.
531 (tic6x-c64xp-linux.c): Remove.
532 (tic6x-c64x-linux.c): Remove.
533 (tic6x-c62x-linux.c): Remove.
535 (reg-sparc64.c): Remove.
538 (amd64-linux.c): Remove.
539 (amd64-avx.c): Remove.
540 (amd64-avx-linux.c): Remove.
541 (amd64-avx-avx512.c): Remove.
542 (amd64-avx-avx512-linux.c): Remove.
543 (amd64-mpx.c): Remove.
544 (amd64-mpx-linux.c): Remove.
545 (amd64-avx-mpx-avx512-pku.c): Remove.
546 (amd64-avx-mpx-avx512-pku-linux.c): Remove.
547 (amd64-avx-mpx.c): Remove.
548 (amd64-avx-mpx-linux.c): Remove.
550 (x32-linux.c): Remove.
552 (x32-avx-linux.c): Remove.
553 (x32-avx-avx512.c): Remove.
554 (x32-avx-avx512-linux.c): Remove.
555 (reg-xtensa.c): Remove.
556 (reg-tilegx.c): Remove.
557 (reg-tilegx32.c): Remove.
559 2017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
561 * Makefile.in (SFILES): Add "common/environ.c".
562 (OBJS): Add "common/environ.h".
564 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
566 * configure.ac: Check if the fs_base and gs_base members of
567 `struct user_regs_struct' exist.
568 * config.in: Regenerated.
569 * configure: Likewise.
571 2017-01-09 Antoine Tremblay <antoine.tremblay@ericsson.com>
573 * linux-aarch32-low.c (arm_breakpoint_kind_from_pc): Use
575 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer): Likewise.
576 (get_next_pcs_syscall_next_pc): Likewise.
578 2016-12-23 Luis Machado <lgustavo@codesourcery.com>
580 * win32-i386-low.c: Fix incorrect reference to a couple source files.
581 * nto-x86-low.c: Likewise.
583 2016-11-30 Simon Marchi <simon.marchi@polymtl.ca>
585 * Makefile.in: Include disable-implicit-rules.mk.
587 2016-11-23 Pedro Alves <palves@redhat.com>
589 * debug.c: Include <chrono> instead of "gdb_sys_time.h".
590 (debug_vprintf): Use std::chrono::steady_clock instead of
591 gettimeofday. Use '.' instead of ':'.
592 * tracepoint.c: Include <chrono> instead of "gdb_sys_time.h".
593 (get_timestamp): Use std::chrono::steady_clock instead of
596 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
598 * Makefile.in: Fix whitespace formatting.
600 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
602 * Makefile.in (SFILES, OBS): Flatten list and order
605 2016-11-23 Pedro Alves <palves@redhat.com>
607 * event-loop.c (handle_file_event): Use warning.
608 * linux-low.c (linux_resume_one_lwp_throw): Use warning.
609 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
612 2016-11-23 Pedro Alves <palves@redhat.com>
614 * linux-low.c (check_zombie_leaders): Use debug_printf for debug
616 * notif.c (handle_notif_ack, notif_event_enque): Likewise.
617 * remote-utils.c (putpkt_binary_1, readchar, getpkt): Use
618 debug_printf and debug_flush for debug output.
619 * server.c (handle_general_set): Likewise.
620 * thread-db.c (try_thread_db_load): Use debug_printf for debug
623 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
625 * Makefile.in (.c.o): Replace rule with ...
626 (%.o: %.c): ... this one.
628 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
630 * Makefile.in: Remove @GMAKE_TRUE@ prefixes and removes lines
631 prefixed with @GMAKE_FALSE@. Update comment related to non-GNU
633 * configure.ac: Remove checks for the make program.
634 * configure: Re-generate.
636 2016-10-28 Pedro Alves <palves@redhat.com>
638 * Makefile.in (CXX_DIALECT): Get from configure.
639 (COMPILE.pre, CC_LD): Append $(CXX_DIALECT).
640 * acinclude.m4: Include ../ax_cxx_compile_stdcxx.m4.
641 * configure.ac: Call AX_CXX_COMPILE_STDCXX.
642 * config.in: Regenerate.
643 * configure: Regenerate.
645 2016-10-27 Yao Qi <yao.qi@linaro.org>
647 * linux-low.c (linux_supports_range_stepping): Return true if
648 can_software_single_step return true.
650 2016-10-27 Yao Qi <yao.qi@linaro.org>
652 * inferiors.c (find_inferior_in_random): New function.
653 * inferiors.h (find_inferior_in_random): Declare.
654 * linux-low.c (linux_wait_for_event_filtered): Call
655 find_inferior_in_random instead of find_inferior.
657 2016-10-27 Yao Qi <yao.qi@linaro.org>
659 * linux-low.c (linux_wait_1): If single-step breakpoints are
660 inserted, remove them.
662 2016-10-26 Pedro Alves <palves@redhat.com>
664 * linux-low.c (handle_extended_wait): Link parent/child fork
666 (linux_wait_1): Unlink them.
667 (linux_set_resume_request): Ignore resume requests for
668 already-resumed and unhandled fork child threads.
669 * linux-low.h (struct lwp_info) <fork_relative>: New field.
670 * server.c (in_queued_stop_replies_ptid, in_queued_stop_replies):
672 (handle_v_requests) <vCont>: Don't call require_running.
673 * server.h (in_queued_stop_replies): New declaration.
675 2016-10-24 Yao Qi <yao.qi@linaro.org>
678 * linux-aarch64-low.c (append_insns): Cast the return value to
681 2016-10-10 Yao Qi <yao.qi@linaro.org>
683 * linux-aarch32-low.c (enum arm_breakpoint_kinds): Remove.
685 2016-10-06 Sergio Durigan Junior <sergiodj@redhat.com>
687 * target.c (target_supports_multi_process): New function, moved
689 * target.h (target_supports_multi_process): ... here. Remove
692 2016-10-05 Tom Tromey <tom@tromey.com>
695 * tracepoint.c (handle_tracepoint_bkpts): Check
696 ipa_error_tracepoint, not ipa_stopping_tracepoint.
698 2016-10-05 Yao Qi <yao.qi@linaro.org>
700 * configure.srv: Update the path of arm-*.xml files.
702 2016-10-05 Terry Guo <terry.guo@arm.com>
703 Yao Qi <yao.qi@linaro.org>
705 * Makefile.in: Adjust the path of rules.
706 * configure.srv: Update the path of xml files.
707 * regformats/arm-with-iwmmxt.dat: Regenerated.
708 * regformats/arm-with-neon.dat: Likewise.
709 * regformats/arm-with-vfpv2.dat: Likewise.
710 * regformats/arm-with-vfpv3.dat Likewise.
712 2016-09-30 Yao Qi <yao.qi@linaro.org>
715 * target.c (target_stop_and_wait): Don't call
716 target_continue_no_signal, use resume_stop instead.
718 2016-09-26 Yao Qi <yao.qi@linaro.org>
720 * linux-low.c (linux_wait_1): Call debug_exit.
722 2016-09-23 Pedro Alves <palves@redhat.com>
724 * Makefile.in (SFILES): Add common/new-op.c.
725 (OBS): Add common/new-op.o.
726 (new-op.o): New rule.
728 2016-09-21 Simon Marchi <simon.marchi@ericsson.com>
730 * .gitinore: Ignore more files.
732 2016-09-21 Yao Qi <yao.qi@linaro.org>
734 * linux-aarch32-low.c (arm_fill_gregset): Keep bits 20 to
737 2016-09-19 Sergio Durigan Junior <sergiodj@redhat.com>
739 * server.c (start_inferior): Call target_mourn_inferior instead of
740 mourn_inferior; pass ptid_t argument to it.
742 (handle_target_event): Likewise.
743 * target.c (target_mourn_inferior): New function.
744 * target.h (mourn_inferior): Delete macro.
746 2016-09-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
748 * linux-low.c (lwp_is_stepping): New function.
750 2016-09-06 Carl Love <cel@us.ibm.com>
752 * server.c (start_inferior): Fixed comment, requested comment change
753 didn't get updated correctly. Removed reference to ptrace () call as
754 it is only true on Linux systems.
756 2016-09-06 Carl Love <cel@us.ibm.com>
758 * server.c (start_inferior): Do not call
759 function target_post_create_inferior () if the
760 inferior process has already exited.
762 2016-09-05 Pedro Alves <palves@redhat.com>
764 * Makefile.in (COMPILER, COMPILER_CFLAGS): Remove.
765 (COMPILE.pre, CC_LD): Use CXX directly.
766 (INTERNAL_CFLAGS_BASE): Use CXXFLAGS directly.
767 * acinclude.m4: Don't include build-with-cxx.m4.
768 * configure.ac: Remove GDB_AC_BUILD_WITH_CXX call.
769 * configure: Regenerate.
771 2016-09-02 Akash Trehan <akash.trehan123@gmail.com>
774 * remote-utils.c (relocate_instruction): Remove redundant strcpy()
775 call writing data to own_buf.
777 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
779 * target.c (mywait): Call target_wait instead of
781 (target_wait): New function.
783 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
785 * server.c (start_inferior): New variable 'ptid'. Replace calls
786 to the_target->resume by target_continue{,_no_signal}, depending
788 * target.c (target_stop_and_wait): Call target_continue_no_signal
789 instead of the_target->resume.
790 (target_continue): New function.
792 2016-08-31 Antoine Tremblay <antoine.tremblay@ericsson.com>
794 * linux-low.c (linux_wait_1): Move event switch after unsuspend_lwps.
796 2016-08-25 Adhemerval Zanella <adhemerval.zanella@linaro.org>
799 * gdb_proc_service.h (ps_get_thread_area): Remove const from struct
801 * linux-aarch64-low.c (ps_get_thread_area): Likewise.
802 * linux-arm-low.c (ps_get_thread_area): Likewise.
803 * linux-crisv32-low.c (ps_get_thread_area): Likewise.
804 * linux-m68k-low.c (ps_get_thread_area): Likewise.
805 * linux-mips-low.c (ps_get_thread_area): Likewise.
806 * linux-nios2-low.c (ps_get_thread_area): Likewise.
807 * linux-tic6x-low.c (ps_get_thread_area): Likewise.
808 * linux-x86-low.c (ps_get_thread_area): Likewise.
809 * linux-xtensa-low.c (ps_get_thread_area): Likewise.
811 2016-08-19 Pedro Alves <palves@redhat.com>
813 * linux-x86-low.c (amd64_emit_call): Emit missing call opcode.
815 2016-08-19 Pedro Alves <palves@redhat.com>
817 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Fix
818 comment. Use memcpy instead of casting through unsigned long.
820 2016-08-19 Pedro Alves <palves@redhat.com>
822 * linux-amd64-ipa.c (alloc_jump_pad_buffer) [__ILP32__]: Try
823 allocating around 0x80000000.
825 2016-08-19 Pedro Alves <palves@redhat.com>
828 * Makefile.in (x32-linux-ipa.o, x32-avx-linux-ipa.o)
829 (x32-avx512-linux-ipa.o): New rules.
830 * configure.ac (x86_64-*-linux*): New x32 check.
831 * configure.srv (ipa_x32_linux_regobj): New.
832 (x86_64-*-linux*): Use $ipa_x32_linux_regobj if building for x32.
833 * linux-amd64-ipa.c (get_ipa_tdesc) [__ILP32__]: Return x32
835 (initialize_low_tracepoint) [__ILP32__]: Initialize x32
837 * configure: Regenerate.
839 2016-08-09 Pedro Alves <palves@redhat.com>
842 * Makefile.in (OBS): Add signals-state-save-restore.o.
843 (signals-state-save-restore.o): New rule.
844 * config.in: Regenerate.
845 * configure: Regenerate.
846 * linux-low.c: Include "signals-state-save-restore.h".
847 (linux_create_inferior): Call
848 restore_original_signals_state.
849 * server.c: Include "dispositions-save-restore.h".
850 (captured_main): Call save_original_signals_state.
852 2016-08-05 Pedro Alves <palves@redhat.com>
854 * configure: Regenerate.
856 2016-08-04 Yao Qi <yao.qi@linaro.org>
858 * linux-low.c (regsets_fetch_inferior_registers): Check
859 errno is ESRCH or not.
861 2016-08-02 Yao Qi <yao.qi@linaro.org>
863 * thread-db.c (struct thread_db) <td_ta_event_getmsg_p>: Remove.
864 <td_ta_set_event_p, td_ta_event_addr_p>: Remove.
865 (thread_db_load_search): Update.
866 (try_thread_db_load_1): Don't look for td_ta_event_addr,
867 td_ta_set_event and td_ta_event_getmsg.
869 2016-07-26 Pedro Alves <palves@redhat.com>
872 * linux-x86-low.c (x86_get_pc, x86_set_pc): Use uint64_t instead
873 of unsigned long for 64-bit registers and use uint32_t instead of
874 unsigned int for 32-bit registers.
876 2016-07-26 Pedro Alves <palves@redhat.com>
878 * linux-x86-low.c (x86_siginfo_fixup): Rename 'native' parameter
881 2016-07-21 Tom Tromey <tom@tromey.com>
883 * configure: Rebuild.
885 2016-07-21 Yao Qi <yao.qi@linaro.org>
887 * mem-break.c (find_gdb_breakpoint): Cast bp to
888 'struct gdb_breakpoint *' rather than 'gdb_breakpoint *'.
890 2016-07-21 Yao Qi <yao.qi@linaro.org>
892 * server.c (handle_v_requests): Support s and S actions
893 if target_supports_software_single_step return true.
895 2016-07-21 Yao Qi <yao.qi@linaro.org>
897 * linux-low.c (resume_stopped_resumed_lwps): If resume request
898 is resume_step, call maybe_hw_step.
899 (linux_wait_1): Stop all threads, remove reinsert breakpoints,
901 (linux_resume_one_lwp_throw): Don't assert the thread has reinsert
903 (proceed_one_lwp): If resume request is resume_step, install
904 reinsert breakpoints and call maybe_hw_step.
906 2016-07-21 Yao Qi <yao.qi@linaro.org>
908 * linux-low.c (proceed_one_lwp): Declare.
909 (linux_resume_one_thread): Remove local variable 'step'.
910 Lift code enqueue signal. Call proceed_one_lwp instead of
911 linux_resume_one_lwp.
913 2016-07-21 Yao Qi <yao.qi@linaro.org>
915 * linux-low.c (linux_resume_one_thread): Call
916 enqueue_pending_signal.
918 2016-07-21 Yao Qi <yao.qi@linaro.org>
920 * gdbthread.h (make_cleanup_restore_current_thread): Declare.
921 * inferiors.c (do_restore_current_thread_cleanup): New function.
922 (make_cleanup_restore_current_thread): Likewise.
923 * linux-low.c (install_software_single_step_breakpoints): Call
924 make_cleanup_restore_current_thread. Switch current_thread to
927 2016-07-21 Yao Qi <yao.qi@linaro.org>
929 * mem-break.c (struct reinsert_breakpoint) <ptid>: New field.
930 (set_reinsert_breakpoint): New parameter ptid. Callers updated.
931 (clone_one_breakpoint): Likewise.
932 (delete_reinsert_breakpoints): Change parameter to thread.
934 (has_reinsert_breakpoints): Likewise.
935 (uninsert_reinsert_breakpoints): Likewise.
936 (reinsert_reinsert_breakpoints): Likewise.
937 * mem-break.h (set_reinsert_breakpoint): Update declaration.
938 (delete_reinsert_breakpoints): Likewise.
939 (reinsert_reinsert_breakpoints): Likewise.
940 (uninsert_reinsert_breakpoints): Likewise.
941 (has_reinsert_breakpoints): Likewise.
943 2016-07-21 Yao Qi <yao.qi@linaro.org>
945 * inferiors.c (get_thread_process): Make parameter const.
946 * inferiors.h (get_thread_process): Update declaration.
947 * mem-break.c (clone_all_breakpoints): Remove all parameters.
948 Add new parameters child_thread and parent_thread. Callers
950 * mem-break.h (clone_all_breakpoints): Update declaration.
952 2016-07-21 Yao Qi <yao.qi@linaro.org>
954 * mem-break.c (struct breakpoint) <cond_list>: Remove.
955 <command_list, handler>: Remove.
956 (struct gdb_breakpoint): New.
957 (struct other_breakpoint): New.
958 (struct reinsert_breakpoint): New.
959 (is_gdb_breakpoint): New function.
960 (any_persistent_commands): Update command_list if
961 is_gdb_breakpoint returns true.
962 (set_breakpoint): Create breakpoints according to their types.
963 (find_gdb_breakpoint): Return 'struct gdb_breakpoint *'.
964 (set_gdb_breakpoint_1): Likewise.
965 (set_gdb_breakpoint): Likewise.
966 (clear_breakpoint_conditions): Change parameter type to
967 'struct gdb_breakpoint *'.
968 (clear_breakpoint_commands): Likewise.
969 (clear_breakpoint_conditions_and_commands): Likewise.
970 (add_condition_to_breakpoint): Likewise.
971 (add_breakpoint_condition): Likewise.
972 (add_commands_to_breakpoint): Likewise.
973 (check_breakpoints): Check other_breakpoint.
974 (clone_one_breakpoint): Clone breakpopint according to its type.
975 * mem-break.h (struct gdb_breakpoint): Declare.
976 (set_gdb_breakpoint): Update declaration.
977 (clear_breakpoint_conditions_and_commands): Likewise.
978 (add_breakpoint_condition): Likewise.
979 (add_breakpoint_commands): Likewise.
980 * server.c (process_point_options): Change parameter type to
981 'struct gdb_breakpoint *'.
983 2016-07-21 Yao Qi <yao.qi@linaro.org>
985 * mem-break.c (set_breakpoint_at): Rename it to ...
986 (set_breakpoint_type_at): ... it.
987 (set_breakpoint_at): Call set_breakpoint_type_at.
988 (set_reinsert_breakpoint): Call set_breakpoint_type_at.
989 * mem-break.h (set_breakpoint_at): Update comments.
991 2016-07-12 Chung-Lin Tang <cltang@codesourcery.com>
993 * linux-nios2-low.c (nios2_fill_gregset): Add type cast
995 (nios2_store_gregset): Likewise.
997 2016-07-01 Pedro Alves <palves@redhat.com>
998 Antoine Tremblay <antoine.tremblay@ericsson.com>
1000 * linux-low.c: Change interface to take the target lwp_info
1001 pointer directly and return void. Handle detaching from a zombie
1003 (linux_detach_lwp_callback): New function.
1004 (linux_detach): Detach from the leader thread after detaching from
1007 2016-06-28 Yao Qi <yao.qi@linaro.org>
1009 * linux-aarch64-low.c (aarch64_ftrace_insn_reloc_b): Use int64_t
1010 for variable new_offset.
1011 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
1012 (aarch64_ftrace_insn_reloc_cb): Likewise.
1013 (aarch64_ftrace_insn_reloc_tb): Likewise.
1014 (aarch64_install_fast_tracepoint_jump_pad): Likewise. Use
1015 PRIx64 instead of PRIx32.
1017 2016-06-28 Yao Qi <yao.qi@linaro.org>
1019 * linux-arm-low.c (arm_get_syscall_trapinfo): New function.
1020 (the_low_target): Install arm_get_syscall_trapinfo.
1022 2016-06-28 Yao Qi <yao.qi@linaro.org>
1024 * linux-aarch64-low.c (aarch64_get_syscall_trapinfo): New
1026 (the_low_target): Install aarch64_get_syscall_trapinfo.
1028 2016-06-28 Yao Qi <yao.qi@linaro.org>
1030 * linux-low.c (get_syscall_trapinfo): Remove parameter sysret.
1032 * linux-low.h (struct linux_target_ops) <get_syscall_trapinfo>:
1033 Remove parameter sysno.
1034 * linux-x86-low.c (x86_get_syscall_trapinfo): Remove parameter
1037 2016-06-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
1039 * linux-s390-low.c (s390_emit_eq_goto): Mark function static.
1040 (s390_emit_ne_goto): Likewise.
1041 (s390_emit_lt_goto): Likewise.
1042 (s390_emit_le_goto): Likewise.
1043 (s390_emit_gt_goto): Likewise.
1044 (s390_emit_ge_goto): Likewise.
1045 (s390x_emit_eq_goto): Likewise.
1046 (s390x_emit_ne_goto): Likewise.
1047 (s390x_emit_lt_goto): Likewise.
1048 (s390x_emit_le_goto): Likewise.
1049 (s390x_emit_gt_goto): Likewise.
1050 (s390x_emit_ge_goto): Likewise.
1051 (s390_emit_ops_impl): Mark variable static.
1052 (s390x_emit_ops): Likewise.
1054 2016-06-17 Yao Qi <yao.qi@linaro.org>
1056 * linux-low.c (handle_extended_wait): Call
1057 uninsert_reinsert_breakpoints for the parent process. Remove
1058 reinsert breakpoints from the child process. Reinsert them to
1059 the parent process when vfork is done.
1060 * mem-break.c (uninsert_reinsert_breakpoints): New function.
1061 (reinsert_reinsert_breakpoints): New function.
1062 * mem-break.h (uninsert_reinsert_breakpoints): Declare
1063 (reinsert_reinsert_breakpoints): Declare.
1065 2016-06-17 Yao Qi <yao.qi@linaro.org>
1067 * linux-low.c (handle_extended_wait): If the parent is doing
1068 step-over, remove the reinsert breakpoints from the forked child.
1070 2016-06-17 Yao Qi <yao.qi@linaro.org>
1072 * linux-low.c (unsuspend_all_lwps): Declare.
1073 (linux_low_filter_event): If thread exited, call finish_step_over.
1074 If step-over is finished, unsuspend other threads.
1076 2016-06-17 Yao Qi <yao.qi@linaro.org>
1078 * linux-low.c (linux_resume_one_lwp_throw): Assert
1079 has_reinsert_breakpoints returns false.
1080 * mem-break.c (delete_disabled_breakpoints): Assert
1081 bp type isn't reinsert_breakpoint.
1083 2016-06-17 Yao Qi <yao.qi@linaro.org>
1085 * linux-low.c (maybe_hw_step): New function.
1086 (linux_resume_one_lwp_throw): Call maybe_hw_step.
1087 (finish_step_over): Switch current_thread to lwp temporarily,
1088 and assert has_reinsert_breakpoints returns true.
1089 (proceed_one_lwp): Call maybe_hw_step.
1090 * mem-break.c (has_reinsert_breakpoints): New function.
1091 * mem-break.h (has_reinsert_breakpoints): Declare.
1093 2016-06-02 Jon Turney <jon.turney@dronecode.org.uk>
1095 * win32-low.c (win32_create_inferior): Add pointer casts for C++.
1097 2016-05-17 Yao Qi <yao.qi@linaro.org>
1099 * linux-low.c (linux_stabilize_threads): Call unsuspend_all_lwps
1100 instead of find_inferior.
1102 2016-05-05 Yao Qi <yao.qi@linaro.org>
1104 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer):
1105 Initialize res to zero.
1107 2016-05-05 Yao Qi <yao.qi@linaro.org>
1109 * linux-arm-low.c (arm_sigreturn_next_pc): Change type of cpsr
1112 2016-05-04 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
1114 * spu-low.c (fetch_ppc_register): Cast PowerPC-Linux-specific value
1115 used as first ptrace argument to PTRACE_TYPE_ARG1 for C++.
1116 (fetch_ppc_memory_1, store_ppc_memory_1): Likewise.
1118 2016-04-28 Par Olsson <par.olsson@windriver.com>
1119 Simon Marchi <simon.marchi@ericsson.com>
1121 * tracepoint.c (write_inferior_int8): New function.
1122 (cmd_qtenable_disable): Write enable flag using
1123 write_inferior_int8.
1125 2016-04-25 Yao Qi <yao.qi@linaro.org>
1127 * linux-low.c (lwp_signal_can_be_delivered): Adjust.
1128 (need_step_over_p): Return zero if the LWP has pending signals
1129 can be delivered on software single step target.
1131 2016-04-25 Yao Qi <yao.qi@linaro.org>
1133 * linux-low.c (reinsert_raw_breakpoint): If bp->inserted is true
1134 return instead of error.
1136 2016-04-22 Yao Qi <yao.qi@linaro.org>
1138 * linux-aarch32-low.c (arm_store_gregset): Clear CPSR bits 20
1141 2016-04-22 Yao Qi <yao.qi@linaro.org>
1143 * linux-low.c (lwp_signal_can_be_delivered): Don't deliver
1144 signal when stepping over breakpoint with software single
1147 2016-04-21 Pedro Alves <palves@redhat.com>
1149 * linux-s390-low.c (s390_collect_ptrace_register)
1150 (s390_supply_ptrace_register, s390_get_hwcap): Use gdb_byte * and
1152 (s390_check_regset): Use void * instead of gdb_byte *.
1154 2016-04-20 Pedro Alves <palves@redhat.com>
1156 * configure: Renegerate.
1158 2016-04-20 Yao Qi <yao.qi@linaro.org>
1160 * linux-aarch32-low.c: Include "arch/arm-linux.h".
1161 (arm_fill_gregset): Use ARM_CPSR_GREGNUM rather than magic
1163 (arm_store_gregset): Likewise.
1165 2016-04-16 Walfred Tedeschi <walfred.tedeschi@intel.com>
1167 * Makefile.in (clean): Add removal for i386-avx-mpx.c,
1168 i386-avx-mpx-linux.c, amd64-avx-mpx.c and amd64-avx-mpx-linux.c.
1169 (i386-avx-mpx.c, i386-avx-mpx-linux.c, amd64-avx-mpx.c)
1170 (amd64-avx-mpx-linux.c): New rules.
1171 (amd64-avx-mpx-linux-ipa.o, i386-avx-mpx-linux-ipa.o): New rule.
1172 * configure.srv (srv_i386_regobj): Add i386-avx-mpx.o.
1173 (srv_i386_linux_regobj): Add i386-avx-mpx-linux.o.
1174 (srv_amd64_regobj): Add amd64-avx-mpx.o.
1175 (srv_amd64_linux_regobj): Add amd64-avx-mpx-linux.o.
1176 (srv_i386_xmlfiles): Add i386/i386-avx-mpx.xml.
1177 (srv_amd64_xmlfiles): Add i386/amd64-avx-mpx.xml.
1178 (srv_i386_linux_xmlfiles): Add i386/i386-avx-mpx-linux.xml.
1179 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-mpx-linux.xml.
1180 (ipa_i386_linux_regobj): Add i386-avx-mpx-linux-ipa.o.
1181 (ipa_amd64_linux_regobj): Add amd64-avx-mpx-linux-ipa.o.
1182 * linux-x86-low.c (x86_linux_read_description): Add case for
1183 X86_XSTATE_AVX_MPX_MASK.
1184 (x86_get_ipa_tdesc_idx): Add cases for avx_mpx.
1185 (initialize_low_arch): Call init_registers_amd64_avx_mpx_linux and
1186 init_registers_i386_avx_mpx_linux.
1187 * linux-i386-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
1188 (initialize_low_tracepoint): Call
1189 init_registers_i386_avx_mpx_linux.
1190 * linux-amd64-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
1191 (initialize_low_tracepoint): Call
1192 init_registers_amd64_avx_mpx_linux.
1193 * linux-x86-tdesc.h (X86_TDESC_AVX_MPX): New enum value.
1194 (init_registers_amd64_avx_mpx_linux, tdesc_amd64_avx_mpx_linux)
1195 (init_registers_i386_avx_mpx_linux, tdesc_i386_avx_mpx_linux): New
1198 2016-04-18 Pedro Alves <palves@redhat.com>
1200 * configure: Regenerate.
1202 2016-04-13 Antoine Tremblay <antoine.tremblay@ericsson.com>
1204 * linux-aarch64-low.c (aarch64_emit_add): Switch x1 and x0.
1205 (aarch64_emit_sub): Likewise.
1207 2016-04-12 Pedro Alves <palves@redhat.com>
1209 * utils.c (prepare_to_throw_exception): Delete.
1211 2016-04-05 Simon Marchi <simon.marchi@ericsson.com>
1213 * Makefile.in ($(IPA_LIB)): Set SONAME of the IPA lib.
1215 2016-04-05 Marcin Kościelnicki <koriakin@0x04.net>
1217 * tracepoint.c (getauxval): Move to #ifdef IN_PROCESS_AGENT.
1219 2016-04-03 Marcin Kościelnicki <koriakin@0x04.net>
1221 * linux-aarch64-ipa.c: Add <elf.h> include.
1222 * linux-ppc-ipa.c: Add <elf.h> include.
1223 * linux-s390-ipa.c: Add <elf.h> include.
1225 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
1227 * tracepoint.c (gdb_collect_ptr): Remove const qualifier.
1228 (get_raw_reg_ptr): Likewise.
1229 (get_trace_state_variable_value_ptr): Likewise.
1230 (set_trace_state_variable_value_ptr): Likewise.
1231 (initialize_tracepoint): Cast alloc_jump_pad_buffer result to
1234 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
1235 Marcin Kościelnicki <koriakin@0x04.net>
1238 * linux-ppc-low.c (emit_insns): New function.
1239 (__EMIT_ASM, _EMIT_ASM, EMIT_ASM): New macros.
1240 (ppc_emit_prologue): New function.
1241 (ppc_emit_epilogue): New function.
1242 (ppc_emit_add): New function.
1243 (ppc_emit_sub): New function.
1244 (ppc_emit_mul): New function.
1245 (ppc_emit_lsh): New function.
1246 (ppc_emit_rsh_signed): New function.
1247 (ppc_emit_rsh_unsigned): New function.
1248 (ppc_emit_ext): New function.
1249 (ppc_emit_zero_ext): New function.
1250 (ppc_emit_log_not): New function.
1251 (ppc_emit_bit_and): New function.
1252 (ppc_emit_bit_or): New function.
1253 (ppc_emit_bit_xor): New function.
1254 (ppc_emit_bit_not): New function.
1255 (ppc_emit_equal): New function.
1256 (ppc_emit_less_signed): New function.
1257 (ppc_emit_less_unsigned): New function.
1258 (ppc_emit_ref): New function.
1259 (ppc_emit_const): New function.
1260 (ppc_emit_reg): New function.
1261 (ppc_emit_pop): New function.
1262 (ppc_emit_stack_flush): New function.
1263 (ppc_emit_swap): New function.
1264 (ppc_emit_stack_adjust): New function.
1265 (ppc_emit_call): New function.
1266 (ppc_emit_int_call_1): New function.
1267 (ppc_emit_void_call_2): New function.
1268 (ppc_emit_if_goto): New function.
1269 (ppc_emit_goto): New function.
1270 (ppc_emit_eq_goto): New function.
1271 (ppc_emit_ne_goto): New function.
1272 (ppc_emit_lt_goto): New function.
1273 (ppc_emit_le_goto): New function.
1274 (ppc_emit_gt_goto): New function.
1275 (ppc_emit_ge_goto): New function.
1276 (ppc_write_goto_address): New function.
1277 (ppc_emit_ops_impl): New static variable.
1278 (ppc64v1_emit_prologue): New function.
1279 (ppc64v2_emit_prologue): New function.
1280 (ppc64_emit_epilogue): New function.
1281 (ppc64_emit_add): New function.
1282 (ppc64_emit_sub): New function.
1283 (ppc64_emit_mul): New function.
1284 (ppc64_emit_lsh): New function.
1285 (ppc64_emit_rsh_signed): New function.
1286 (ppc64_emit_rsh_unsigned): New function.
1287 (ppc64_emit_ext): New function.
1288 (ppc64_emit_zero_ext): New function.
1289 (ppc64_emit_log_not): New function.
1290 (ppc64_emit_bit_and): New function.
1291 (ppc64_emit_bit_or): New function.
1292 (ppc64_emit_bit_xor): New function.
1293 (ppc64_emit_bit_not): New function.
1294 (ppc64_emit_equal): New function.
1295 (ppc64_emit_less_signed): New function.
1296 (ppc64_emit_less_unsigned): New function.
1297 (ppc64_emit_ref): New function.
1298 (ppc64_emit_const): New function.
1299 (ppc64v1_emit_reg): New function.
1300 (ppc64v2_emit_reg): New function.
1301 (ppc64_emit_pop): New function.
1302 (ppc64_emit_stack_flush): New function.
1303 (ppc64_emit_swap): New function.
1304 (ppc64v1_emit_call): New function.
1305 (ppc64v2_emit_call): New function.
1306 (ppc64v1_emit_int_call_1): New function.
1307 (ppc64v2_emit_int_call_1): New function.
1308 (ppc64v1_emit_void_call_2): New function.
1309 (ppc64v2_emit_void_call_2): New function.
1310 (ppc64_emit_if_goto): New function.
1311 (ppc64_emit_eq_goto): New function.
1312 (ppc64_emit_ne_goto): New function.
1313 (ppc64_emit_lt_goto): New function.
1314 (ppc64_emit_le_goto): New function.
1315 (ppc64_emit_gt_goto): New function.
1316 (ppc64_emit_ge_goto): New function.
1317 (ppc64v1_emit_ops_impl): New static variable.
1318 (ppc64v2_emit_ops_impl): New static variable.
1319 (ppc_emit_ops): New function.
1320 (linux_low_target): Wire in ppc_emit_ops.
1322 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
1323 Marcin Kościelnicki <koriakin@0x04.net>
1326 * Makefile.in: Add powerpc-*-ipa.o
1327 * configure.srv: Add ipa_obj for powerpc*-linux.
1328 * linux-ppc-ipa.c: New file.
1329 * linux-ppc-low.c: Added linux-ppc-tdesc.h, ax.h, tracepoint.h
1331 (PPC_FIELD): New macro.
1332 (PPC_SEXT): New macro.
1333 (PPC_OP6): New macro.
1334 (PPC_BO): New macro.
1335 (PPC_LI): New macro.
1336 (PPC_BD): New macro.
1337 (init_registers_*): Move prototype to linux-ppc-tdesc.h.
1338 (tdesc_*): Move declaration to linux-ppc-tdesc.h.
1339 (ppc_get_hwcap): Rename to ppc_get_auxv and add type parameter.
1340 (ppc_get_thread_area): New function.
1341 (is_elfv2_inferior): New function.
1342 (gen_ds_form): New function.
1343 (GEN_STD): New macro.
1344 (GEN_STDU): New macro.
1345 (GEN_LD): New macro.
1346 (GEN_LDU): New macro.
1347 (gen_d_form): New function.
1348 (GEN_ADDI): New macro.
1349 (GEN_ADDIS): New macro.
1350 (GEN_LI): New macro.
1351 (GEN_LIS): New macro.
1352 (GEN_ORI): New macro.
1353 (GEN_ORIS): New macro.
1354 (GEN_LWZ): New macro.
1355 (GEN_STW): New macro.
1356 (GEN_STWU): New macro.
1357 (gen_xfx_form): New function.
1358 (GEN_MFSPR): New macro.
1359 (GEN_MTSPR): New macro.
1360 (GEN_MFCR): New macro.
1361 (GEN_MTCR): New macro.
1362 (GEN_SYNC): New macro.
1363 (GEN_LWSYNC): New macro.
1364 (gen_x_form): New function.
1365 (GEN_OR): New macro.
1366 (GEN_MR): New macro.
1367 (GEN_LWARX): New macro.
1368 (GEN_STWCX): New macro.
1369 (GEN_CMPW): New macro.
1370 (gen_md_form): New function.
1371 (GEN_RLDICL): New macro.
1372 (GEN_RLDICR): New macro.
1373 (gen_i_form): New function.
1375 (GEN_BL): New macro.
1376 (gen_b_form): New function.
1377 (GEN_BNE): New macro.
1378 (GEN_LOAD): New macro.
1379 (GEN_STORE): New macro.
1380 (gen_limm): New function.
1381 (gen_atomic_xchg): New function.
1382 (gen_call): New function.
1383 (ppc_relocate_instruction): New function.
1384 (ppc_install_fast_tracepoint_jump_pad): New function.
1385 (ppc_get_min_fast_tracepoint_insn_len): New function.
1386 (ppc_get_ipa_tdesc_idx): New function.
1387 (the_low_target): Wire in the new functions.
1388 (initialize_low_arch) [!__powerpc64__]: Don'it initialize 64-bit
1390 * linux-ppc-tdesc.h: New file.
1392 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
1394 * linux-aarch64-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
1395 (alloc_jump_pad_buffer): New function.
1396 * linux-amd64-ipa.c: Add <sys/mman.h> include.
1397 (alloc_jump_pad_buffer): New function.
1398 * linux-i386-ipa.c (alloc_jump_pad_buffer): New function.
1399 * linux-s390-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
1400 (alloc_jump_pad_buffer): New function.
1401 * tracepoint.c (getauxval) [!HAVE_GETAUXVAL]: New function.
1402 (initialize_tracepoint): Delegate to alloc_jump_pad_buffer.
1403 * tracepoint.h (alloc_jump_pad_buffer): New prototype.
1404 (getauxval) [!HAVE_GETAUXVAL]: New prototype.
1406 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
1408 * linux-aarch64-ipa.c: Rename gdb_agent_get_raw_reg to get_raw_reg.
1409 * linux-amd64-ipa.c: Likewise.
1410 * linux-i386-ipa.c: Likewise.
1411 * linux-s390-ipa.c: Likewise.
1412 * tracepoint.c: IPA-export gdb_collect_ptr instead of gdb_collect,
1413 ditto for get_raw_reg_ptr, get_trace_state_variable_value_ptr,
1414 set_trace_state_variable_value_ptr.
1415 (struct ipa_sym_addresses): Likewise.
1416 (symbol_list): Likewise.
1417 (install_fast_tracepoint): Dereference gdb_collect_ptr instead of
1418 accessing gdb_collect directly.
1419 (gdb_collect_ptr_type): New typedef.
1420 (get_raw_reg_ptr_type): New typedef.
1421 (get_trace_state_variable_value_ptr_type): New typedef.
1422 (set_trace_state_variable_value_ptr_type): New typedef.
1423 (gdb_collect_ptr): New global.
1424 (get_raw_reg_ptr): New global.
1425 (get_trace_state_variable_value_ptr): New global.
1426 (set_trace_state_variable_value_ptr): New global.
1427 (get_raw_reg_func_addr): Dereference get_raw_reg_ptr instead of
1428 accessing get_raw_reg directly.
1429 (get_get_tsv_func_addr): Likewise for
1430 get_trace_state_variable_value_ptr.
1431 (get_set_tsv_func_addr): Likewise for
1432 set_trace_state_variable_value_ptr.
1433 * tracepoint.h: Rename gdb_agent_get_raw_reg to get_raw_reg.
1435 2016-03-30 Simon Marchi <simon.marchi@ericsson.com>
1437 * tracepoint.c (cmd_qtenable_disable): Remove whitespace.
1439 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
1441 * remote-utils.c (look_up_one_symbol): Remove own_buf, handle 'v'
1443 (relocate_instruction): Remove own_buf.
1444 * server.c (own_buf): Make global.
1445 (handle_v_requests): Make global.
1446 * server.h (own_buf): New declaration.
1447 (handle_v_requests): New prototype.
1449 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
1452 * linux-s390-low.c (add_insns): New function.
1453 (s390_emit_prologue): New function.
1454 (s390_emit_epilogue): New function.
1455 (s390_emit_add): New function.
1456 (s390_emit_sub): New function.
1457 (s390_emit_mul): New function.
1458 (s390_emit_lsh): New function.
1459 (s390_emit_rsh_signed): New function.
1460 (s390_emit_rsh_unsigned): New function.
1461 (s390_emit_ext): New function.
1462 (s390_emit_log_not): New function.
1463 (s390_emit_bit_and): New function.
1464 (s390_emit_bit_or): New function.
1465 (s390_emit_bit_xor): New function.
1466 (s390_emit_bit_not): New function.
1467 (s390_emit_equal): New function.
1468 (s390_emit_less_signed): New function.
1469 (s390_emit_less_unsigned): New function.
1470 (s390_emit_ref): New function.
1471 (s390_emit_if_goto): New function.
1472 (s390_emit_goto): New function.
1473 (s390_write_goto_address): New function.
1474 (s390_emit_litpool): New function.
1475 (s390_emit_const): New function.
1476 (s390_emit_call): New function.
1477 (s390_emit_reg): New function.
1478 (s390_emit_pop): New function.
1479 (s390_emit_stack_flush): New function.
1480 (s390_emit_zero_ext): New function.
1481 (s390_emit_swap): New function.
1482 (s390_emit_stack_adjust): New function.
1483 (s390_emit_set_r2): New function.
1484 (s390_emit_int_call_1): New function.
1485 (s390_emit_void_call_2): New function.
1486 (s390_emit_eq_goto): New function.
1487 (s390_emit_ne_goto): New function.
1488 (s390_emit_lt_goto): New function.
1489 (s390_emit_le_goto): New function.
1490 (s390_emit_gt_goto): New function.
1491 (s390_emit_ge_goto): New function.
1492 (s390x_emit_prologue): New function.
1493 (s390x_emit_epilogue): New function.
1494 (s390x_emit_add): New function.
1495 (s390x_emit_sub): New function.
1496 (s390x_emit_mul): New function.
1497 (s390x_emit_lsh): New function.
1498 (s390x_emit_rsh_signed): New function.
1499 (s390x_emit_rsh_unsigned): New function.
1500 (s390x_emit_ext): New function.
1501 (s390x_emit_log_not): New function.
1502 (s390x_emit_bit_and): New function.
1503 (s390x_emit_bit_or): New function.
1504 (s390x_emit_bit_xor): New function.
1505 (s390x_emit_bit_not): New function.
1506 (s390x_emit_equal): New function.
1507 (s390x_emit_less_signed): New function.
1508 (s390x_emit_less_unsigned): New function.
1509 (s390x_emit_ref): New function.
1510 (s390x_emit_if_goto): New function.
1511 (s390x_emit_const): New function.
1512 (s390x_emit_call): New function.
1513 (s390x_emit_reg): New function.
1514 (s390x_emit_pop): New function.
1515 (s390x_emit_stack_flush): New function.
1516 (s390x_emit_zero_ext): New function.
1517 (s390x_emit_swap): New function.
1518 (s390x_emit_stack_adjust): New function.
1519 (s390x_emit_int_call_1): New function.
1520 (s390x_emit_void_call_2): New function.
1521 (s390x_emit_eq_goto): New function.
1522 (s390x_emit_ne_goto): New function.
1523 (s390x_emit_lt_goto): New function.
1524 (s390x_emit_le_goto): New function.
1525 (s390x_emit_gt_goto): New function.
1526 (s390x_emit_ge_goto): New function.
1527 (s390_emit_ops): New function.
1528 (struct linux_target_ops): Fill in emit_ops hook.
1530 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
1533 * Makefile.in: Add s390 IPA files.
1534 * configure.srv: Build IPA for s390.
1535 * linux-s390-ipa.c: New file.
1536 * linux-s390-low.c: New includes - inttypes.h and linux-s390-tdesc.h.
1537 (init_registers_s390_linux32): Move declaration to linux-s390-tdesc.h.
1538 (tdesc_s390_linux32): Likewise.
1539 (init_registers_s390_linux32v1): Likewise.
1540 (tdesc_s390_linux32v1): Likewise.
1541 (init_registers_s390_linux32v2): Likewise.
1542 (tdesc_s390_linux32v2): Likewise.
1543 (init_registers_s390_linux64): Likewise.
1544 (tdesc_s390_linux64): Likewise.
1545 (init_registers_s390_linux64v1): Likewise.
1546 (tdesc_s390_linux64v1): Likewise.
1547 (init_registers_s390_linux64v2): Likewise.
1548 (tdesc_s390_linux64v2): Likewise.
1549 (init_registers_s390_te_linux64): Likewise.
1550 (tdesc_s390_te_linux64): Likewise.
1551 (init_registers_s390_vx_linux64): Likewise.
1552 (tdesc_s390_vx_linux64): Likewise.
1553 (init_registers_s390_tevx_linux64): Likewise.
1554 (tdesc_s390_tevx_linux64): Likewise.
1555 (init_registers_s390x_linux64): Likewise.
1556 (tdesc_s390x_linux64): Likewise.
1557 (init_registers_s390x_linux64v1): Likewise.
1558 (tdesc_s390x_linux64v1): Likewise.
1559 (init_registers_s390x_linux64v2): Likewise.
1560 (tdesc_s390x_linux64v2): Likewise.
1561 (init_registers_s390x_te_linux64): Likewise.
1562 (tdesc_s390x_te_linux64): Likewise.
1563 (init_registers_s390x_vx_linux64): Likewise.
1564 (tdesc_s390x_vx_linux64): Likewise.
1565 (init_registers_s390x_tevx_linux64): Likewise.
1566 (tdesc_s390x_tevx_linux64): Likewise.
1567 (have_hwcap_s390_vx): New static variable.
1568 (s390_arch_setup): Fill have_hwcap_s390_vx.
1569 (s390_get_thread_area): New function.
1570 (s390_ft_entry_gpr_esa): New const.
1571 (s390_ft_entry_gpr_zarch): New const.
1572 (s390_ft_entry_misc): New const.
1573 (s390_ft_entry_fr): New const.
1574 (s390_ft_entry_vr): New const.
1575 (s390_ft_main_31): New const.
1576 (s390_ft_main_64): New const.
1577 (s390_ft_exit_fr): New const.
1578 (s390_ft_exit_vr): New const.
1579 (s390_ft_exit_misc): New const.
1580 (s390_ft_exit_gpr_esa): New const.
1581 (s390_ft_exit_gpr_zarch): New const.
1582 (append_insns): New function.
1583 (s390_relocate_instruction): New function.
1584 (s390_install_fast_tracepoint_jump_pad): New function.
1585 (s390_get_min_fast_tracepoint_insn_len): New function.
1586 (s390_get_ipa_tdesc_idx): New function.
1587 (struct linux_target_ops): Wire in the above functions.
1588 (initialize_low_arch) [!__s390x__]: Don't initialize s390x tdescs.
1589 * linux-s390-tdesc.h: New file.
1591 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
1593 * linux-s390-low.c (s390_supports_tracepoints): New function.
1594 (struct linux_target_ops): Fill supports_tracepoints hook.
1596 2016-03-18 Yao Qi <yao.qi@linaro.org>
1598 * linux-low.c (lwp_signal_can_be_delivered): New function.
1599 (linux_resume_one_lwp_throw): Use lwp_signal_can_be_delivered.
1601 2016-03-18 Yao Qi <yao.qi@linaro.org>
1603 * linux-low.c (linux_resume_one_lwp_throw): Set 'signal' to
1604 0 if signal is enqueued. Remove 'signal' from one debugging
1605 message. Move one debugging message to some lines below.
1606 Remove code setting 'signal' to 0.
1608 2016-03-18 Yao Qi <yao.qi@linaro.org>
1610 * linux-low.c (linux_low_filter_event): Remove redundant
1611 WIFSTOPPED check together with linux_wstatus_maybe_breakpoint.
1613 2016-03-09 Marcin Kościelnicki <koriakin@0x04.net>
1615 * linux-ppc-low.c (ppc_supports_tracepoints): New function.
1616 (struct linux_target_ops): Wire in the above.
1618 2016-03-03 Yao Qi <yao.qi@linaro.org>
1620 * linux-low.c: Update comments to start_step_over.
1622 2016-03-03 Yao Qi <yao.qi@linaro.org>
1625 * linux-low.c (handle_extended_wait): Set child suspended
1626 if event_lwp->bp_reinsert isn't zero.
1628 2016-03-02 Yao Qi <yao.qi@linaro.org>
1630 * linux-low.c (linux_resume_one_lwp_throw): Replace code with
1631 enqueue_pending_signal.
1633 2016-03-02 Marcin Kościelnicki <koriakin@0x04.net>
1635 * tracepoint.c (cmd_qtstart): Only set ipa_tdesc_idx if agent
1638 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
1640 * linux-s390-low.c (s390_num_regs_3264): Define on 31-bit too.
1641 (s390_regmap_3264) [!__s390x__]: New global.
1642 (s390_collect_ptrace_register): Skip map entries containing -1.
1643 (s390_supply_ptrace_register): Ditto.
1644 (s390_fill_gprs_high): New function.
1645 (s390_store_gprs_high): New function.
1646 (s390_regsets): Add NT_S390_HIGH_GPRS.
1647 (s390_get_hwcap): Enable on 31-bit.
1648 (have_hwcap_s390_high_gprs): Enable on 31-bit.
1649 (s390_arch_setup): Enable detection of high GPRs, TDB, VX on 31-bit.
1650 Detect NT_S390_HIGH_GPRS.
1651 (s390_usrregs_info_3264): Enable on 31-bit.
1652 (s390_regs_info): Enable regs_info_3264 on 31-bit.
1653 (initialize_low_arch): Initialize s390_regsets_info_3264 on 31-bit.
1655 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
1658 * Makefile.in: Add i386-*-linux-ipa.o and amd64-*-linux-ipa.o.
1659 * configure.srv: Ditto.
1660 * linux-aarch64-ipa.c (get_ipa_tdesc): New function.
1661 (initialize_low_tracepoint): Remove ipa_tdesc assignment.
1662 * linux-amd64-ipa.c: Add "linux-x86-tdesc.h" include.
1663 (init_registers_amd64_linux): Remove prototype.
1664 (tdesc_amd64_linux): Remove declaration.
1665 (get_ipa_tdesc): New function.
1666 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
1667 initialize remaining tdescs.
1668 * linux-i386-ipa.c: Add "linux-x86-tdesc.h" include.
1669 (init_registers_i386_linux): Remove prototype.
1670 (tdesc_i386_linux): Remove declaration.
1671 (get_ipa_tdesc): New function.
1672 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
1673 initialize remaining tdescs.
1674 * linux-low.c (linux_get_ipa_tdesc_idx): New function.
1675 (linux_target_ops): wire in linux_get_ipa_tdesc_idx.
1676 * linux-low.h (struct linux_target_ops): Add get_ipa_tdesc_idx.
1677 * linux-x86-low.c: Move tdesc declarations to linux-x86-tdesc.h.
1678 (x86_get_ipa_tdesc_idx): New function.
1679 (the_low_target): Wire in x86_get_ipa_tdesc_idx.
1680 * linux-x86-tdesc.h: New file.
1681 * target.h (struct target_ops): Add get_ipa_tdesc_idx.
1682 (target_get_ipa_tdesc_idx): New macro.
1683 * tracepoint.c (ipa_tdesc_idx): New macro.
1684 (struct ipa_sym_addresses): Add addr_ipa_tdesc_idx.
1685 (symbol_list): Add ipa_tdesc_idx.
1686 (cmd_qtstart): Write ipa_tdesc_idx in the target.
1687 (ipa_tdesc): Remove.
1688 (ipa_tdesc_idx): New variable.
1689 (get_context_regcache): Use get_ipa_tdesc.
1690 (gdb_collect): Ditto.
1692 * tracepoint.h (get_ipa_tdesc): New prototype.
1693 (ipa_tdesc): Remove.
1695 2016-02-24 Pedro Alves <palves@redhat.com>
1697 * linux-low.c (check_stopped_by_breakpoint): Rename to ...
1698 (save_stop_reason): ... this. Use GDB_ARCH_IS_TRAP_HWBKPT and
1699 handle ambiguous GDB_ARCH_IS_TRAP_BRKPT / GDB_ARCH_IS_TRAP_HWBKPT.
1700 Factor out common code between the USE_SIGTRAP_SIGINFO and
1701 !USE_SIGTRAP_SIGINFO blocks.
1702 (linux_low_filter_event): Call save_stop_reason instead of
1703 check_stopped_by_breakpoint and check_stopped_by_watchpoint.
1705 (linux_wait_1): Update comments.
1707 2016-02-24 Wei-cheng Wang <cole945@gmail.com>
1709 * linux-ppc-low.c (ppc_supports_z_point_type): New function:
1710 (ppc_insert_point, ppc_remove_point): Insert/remove z-packet breakpoints.
1711 (ppc64_emit_ops_vector): Add target ops - ppc_supports_z_point_type,
1712 ppc_insert_point, ppc_remove_point.
1714 2016-02-17 Marcin Kościelnicki <koriakin@0x04.net>
1716 * linux-s390-low.c (s390_supports_z_point_type): New function.
1717 (struct linux_target_ops): Wire s390_supports_z_point_type in.
1719 2016-02-16 Yao Qi <yao.qi@linaro.org>
1721 * linux-arm-low.c (get_next_pcs_syscall_next_pc): Remove argument
1722 PC. Get pc from regcache_read_pc.
1724 2016-02-12 Yao Qi <yao.qi@linaro.org>
1726 * linux-aarch64-low.c (aarch64_get_pc): Call linux_get_pc_64bit
1727 or linux_get_pc_32bit.
1728 (aarch64_set_pc): Call linux_set_pc_64bit or linux_set_pc_32bit.
1730 2016-02-12 Yao Qi <yao.qi@linaro.org>
1732 * linux-arm-low.c (get_next_pcs_ops): Initialize it with
1733 arm_linux_get_next_pcs_fixup.
1735 2016-02-12 Marcin Kościelnicki <koriakin@0x04.net>
1737 * tracepoint.c (x_tracepoint_action_download): Change
1738 write_inferior_data_ptr to write_inferior_data_pointer.
1739 (cmd_qtstart): Likewise.
1740 (write_inferior_data_ptr): Remove.
1741 (download_agent_expr): Change write_inferior_data_ptr to
1742 write_inferior_data_pointer.
1743 (download_tracepoint_1): Likewise.
1744 (download_tracepoint): Likewise.
1745 (download_trace_state_variables): Likewise.
1747 2016-02-11 Wei-cheng Wang <cole945@gmail.com>
1748 Marcin Kościelnicki <koriakin@0x04.net>
1750 * tracepoint.c (struct tracepoint_action_ops): Remove.
1751 (struct tracepoint_action): Remove ops.
1752 (m_tracepoint_action_download, r_tracepoint_action_download)
1753 (x_tracepoint_action_download, l_tracepoint_action_download): Adjust
1754 size and offset accordingly.
1755 (m_tracepoint_action_ops, r_tracepoint_action_ops)
1756 (x_tracepoint_action_ops, l_tracepoint_action_ops): Remove.
1757 (tracepoint_action_send, tracepoint_action_download): New functions.
1758 Helpers for trace action handlers.
1759 (add_tracepoint_action): Remove setup actions ops.
1760 (download_tracepoint_1, tracepoint_send_agent): Call helper functions.
1762 2016-02-10 Yao Qi <yao.qi@linaro.org>
1764 * regcache.c (regcache_raw_read_unsigned): Clear *VAL.
1766 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
1768 * configure.ac: Use AC_CONFIG_FILES instead of passing arguments
1770 * configure: Regenerate.
1772 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
1774 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): Change
1775 void * to gdb_byte *.
1776 * linux-low.c (siginfo_fixup): Likewise.
1777 (linux_xfer_siginfo): Likewise.
1778 * linux-low.h (struct linux_target_ops) <siginfo_fixup>:
1780 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
1782 2016-02-02 Walfred Tedeschi <walfred.tedeschi@intel.com>
1784 * configure.srv (x86_64-*-linux*): Add amd64-linux-siginfo.o
1786 (i[34567]86-*-linux*): Add amd64-linux-siginfo.o
1788 * linux-x86-low.c [__x86_64__]: Include
1789 "nat/amd64-linux-siginfo.h".
1790 (compat_siginfo_from_siginfo, siginfo_from_compat_siginfo)
1791 (compat_x32_siginfo_from_siginfo, siginfo_from_compat_x32_siginfo)
1792 (compat_timeval, compat_sigval, compat_x32_clock, cpt_si_pid)
1793 (cpt_si_uid, cpt_si_timerid, cpt_si_overrun, cpt_si_status)
1794 (cpt_si_utime, cpt_si_stime, cpt_si_ptr, cpt_si_addr, cpt_si_band)
1795 (cpt_si_fd, si_timerid, si_overrun): Move from
1796 nat/amd64-linux-siginfo.c.
1797 * Makefile.in (amd64-linux-siginfo.o:): New rule.
1799 2016-01-28 Simon Marchi <simon.marchi@ericsson.com>
1801 * server.c (skip_to_semicolon): Remove.
1802 (process_point_options): Use strchrnul instead of
1805 2016-01-26 Yao Qi <yao.qi@linaro.org>
1807 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Remove argument pc.
1808 * linux-low.c (install_software_single_step_breakpoints): Don't
1809 call regcache_read_pc.
1810 * linux-low.h (struct linux_target_ops) <get_next_pcs>: Remove
1813 2016-01-26 Yao Qi <yao.qi@linaro.org>
1815 * linux-low.c (install_software_single_step_breakpoints): Call
1816 regcache_read_pc instead of get_pc.
1818 2016-01-26 Yao Qi <yao.qi@linaro.org>
1820 * remote-utils.c (remote_close) [!USE_WIN32API]: Ignore SIGIO.
1821 (unblock_async_io): Rename to ...
1822 (block_unblock_async_io): ... it. New function.
1823 (enable_async_io): Don't install SIGIO handler. Unblock it
1825 (disable_async_io): Don't ignore SIGIO. Block it instead.
1826 (initialize_async_io): Install SIGIO handler. Don't call
1829 2016-01-26 Yao Qi <yao.qi@linaro.org>
1831 * remote-utils.c (getpkt): If the buffer isn't empty, and the
1832 first character is '\003', call *the_target->request_interrupt.
1834 2016-01-25 Yao Qi <yao.qi@linaro.org>
1836 * remote-utils.c (new_thread_notify): Remove.
1837 (dead_thread_notify): Likewise.
1838 * remote-utils.h (new_thread_notify): Remove declaration.
1839 (dead_thread_notify): Likewise.
1841 2016-01-23 Marcin Kościelnicki <koriakin@0x04.net>
1843 * gdb.trace/pending.exp: Fix expected message on continue.
1845 2016-01-22 Marcin Kościelnicki <koriakin@0x04.net>
1847 * tracepoint.c (write_inferior_data_ptr): Cast to uintptr_t, so that
1848 it works properly on big-endian machines where sizeof (CORE_ADDR)
1851 2016-01-21 Pedro Alves <palves@redhat.com>
1853 * Makefile.in (COMPILER_CFLAGS, CXXFLAGS): New.
1854 (INTERNAL_CFLAGS_BASE): Use COMPILER_CFLAGS instead of CFLAGS.
1855 * configure: Regenerate.
1857 2016-01-21 Yao Qi <yao.qi@linaro.org>
1859 * linux-arm-low.c (arm_sigreturn_next_pc): Add parameter
1860 is_thumb and set it according to CPSR saved on the stack.
1861 (get_next_pcs_syscall_next_pc): Pass is_thumb to
1862 arm_sigreturn_next_pc.
1864 2016-01-18 Yao Qi <yao.qi@linaro.org>
1866 * linux-low.c (linux_set_pc_64bit): New function.
1867 (linux_get_pc_64bit): New function.
1868 * linux-low.h (linux_set_pc_64bit, linux_get_pc_64bit):
1870 * linux-sparc-low.c (debug_threads): Remove declaration.
1871 (sparc_get_pc): Remove.
1872 (the_low_target): Use linux_get_pc_64bit instead of
1874 * linux-tile-low.c (tile_get_pc, tile_set_pc): Remove.
1875 (the_low_target): Use linux_get_pc_64bit and
1878 2016-01-18 Yao Qi <yao.qi@linaro.org>
1880 * linux-arm-low.c (debug_threads): Remove declaration.
1881 (arm_get_pc, arm_set_pc): Remove.
1882 (the_low_target): Use linux_get_pc_32bit and
1884 * linux-bfin-low.c (bfin_get_pc, bfin_set_pc): Remove.
1885 (the_low_target): Use linux_get_pc_32bit and
1887 * linux-cris-low.c (debug_threads): Remove declaration.
1888 (cris_get_pc, cris_set_pc,): Remove.
1889 (the_low_target): Use linux_get_pc_32bit and
1891 * linux-crisv32-low.c (debug_threads): Remove declaration.
1892 (cris_get_pc, cris_set_pc): Remove.
1893 (the_low_target): Use linux_get_pc_32bit and
1895 * linux-low.c: Include inttypes.h.
1896 (linux_get_pc_32bit, linux_set_pc_32bit): New functions.
1897 * linux-low.h (linux_get_pc_32bit, linux_set_pc_32bit): Declare.
1898 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Remove.
1899 (the_low_target): Use linux_get_pc_32bit and
1901 * linux-m68k-low.c (m68k_get_pc, m68k_set_pc): Remove.
1902 (the_low_target): Use linux_get_pc_32bit and
1904 * linux-nios2-low.c (nios2_get_pc, nios2_set_pc): Remove.
1905 (the_low_target): Use linux_get_pc_32bit and
1907 * linux-sh-low.c (sh_get_pc, sh_set_pc): Remove.
1908 (the_low_target): Use linux_get_pc_32bit and
1910 * linux-xtensa-low.c (xtensa_get_pc, xtensa_set_pc): Remove.
1911 (the_low_target): Use linux_get_pc_32bit and
1914 2016-01-18 Gary Benson <gbenson@redhat.com>
1916 * configure.ac (AC_FUNC_FORK): New check.
1917 * config.in: Regenerate.
1918 * configure: Likewise.
1920 2016-01-14 Yao Qi <yao.qi@linaro.org>
1922 * linux-aarch32-low.c (thumb2_breakpoint): Make it static.
1923 * linux-aarch32-low.h (thumb2_breakpoint): Remove declaration.
1924 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Pass 1 to
1925 arm_get_next_pcs_ctor.
1927 2016-01-12 Josh Stone <jistone@redhat.com>
1928 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1930 * inferiors.h: Include "gdb_vecs.h".
1931 (struct process_info): Add syscalls_to_catch.
1932 * inferiors.c (remove_process): Free syscalls_to_catch.
1933 * remote-utils.c (prepare_resume_reply): Report syscall_entry and
1934 syscall_return stops.
1935 * server.h (UNKNOWN_SYSCALL, ANY_SYSCALL): Define.
1936 * server.c (handle_general_set): Handle QCatchSyscalls.
1937 (handle_query): Report support for QCatchSyscalls.
1938 * target.h (struct target_ops): Add supports_catch_syscall.
1939 (target_supports_catch_syscall): New macro.
1940 * linux-low.h (struct linux_target_ops): Add get_syscall_trapinfo.
1941 (struct lwp_info): Add syscall_state.
1942 * linux-low.c (handle_extended_wait): Mark syscall_state as an entry.
1943 Maintain syscall_state and syscalls_to_catch across exec.
1944 (get_syscall_trapinfo): New function, proxy to the_low_target.
1945 (linux_low_ptrace_options): Enable PTRACE_O_TRACESYSGOOD.
1946 (linux_low_filter_event): Toggle syscall_state entry/return for
1947 syscall traps, and set it ignored for all others.
1948 (gdb_catching_syscalls_p): New function.
1949 (gdb_catch_this_syscall_p): New function.
1950 (linux_wait_1): Handle SYSCALL_SIGTRAP.
1951 (linux_resume_one_lwp_throw): Add PTRACE_SYSCALL possibility.
1952 (linux_supports_catch_syscall): New function.
1953 (linux_target_ops): Install it.
1954 * linux-x86-low.c (x86_get_syscall_trapinfo): New function.
1955 (the_low_target): Install it.
1957 2016-01-12 Mike Frysinger <vapier@gentoo.org>
1959 * acinclude.m4: Include new ../warning.m4 file.
1960 * configure: Regenerated.
1961 * configure.ac: Replace all warning logic with AM_GDB_WARNINGS.
1963 2016-01-12 Mike Frysinger <vapier@gentoo.org>
1965 * ax.c (is_goto_target): Mark static.
1966 * linux-low.c (register_addr): Likewise.
1967 (linux_fetch_registers, linux_store_registers): Likewise.
1968 * mem-break.c (any_persistent_commands): Fix old prototype.
1969 (add_commands_to_breakpoint): Mark static.
1970 * regcache.c (find_register_by_name): Delete unused func.
1971 * remote-utils.c (hex_or_minus_one): Mark static.
1972 * server.c (monitor_show_help): Mark static.
1973 (handle_query, handle_v_cont, handle_v_attach, handle_v_kill,
1974 handle_v_requests): Likewise.
1976 2016-01-12 Pedro Alves <palves@redhat.com>
1978 Remove use of the registered trademark symbol throughout.
1980 2016-01-08 Yao Qi <yao.qi@linaro.org>
1982 * remote-utils.c (getpkt): If c is '\003', call target hook
1985 2016-01-06 Yao Qi <yao.qi@linaro.org>
1987 * linux-aarch32-low.h (arm_abi_breakpoint): Move to
1988 linux-aarch32-low.c.
1989 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
1990 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
1991 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
1992 (thumb2_breakpoint): Declare.
1993 * linux-aarch32-low.c (arm_abi_breakpoint): Moved from
1994 linux-aarch32-low.h.
1995 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
1996 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
1997 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
1999 2016-01-01 Joel Brobecker <brobecker@adacore.com>
2001 * gdbreplay.c (gdbreplay_version): Change copyright year in
2003 * server.c (gdbserver_version): Likewise.
2005 2015-12-28 Patrick Palka <patrick@parcs.ath.cx>
2007 * server.c (crc32_table): Delete.
2008 (crc32): Use libiberty's xcrc32 function.
2010 2015-12-22 Joel Brobecker <brobecker@adacore.com>
2012 * lynx-low.c (lynx_delete_thread_callback): New function.
2013 (lynx_mourn): Properly delete our process and all of its
2014 threads. Remove call to clear_inferiors.
2016 2015-12-22 Joel Brobecker <brobecker@adacore.com>
2018 * target.c (thread_search_callback): Add check that
2019 the thread_stopped target callback is not NULL before
2022 2015-12-21 Yao Qi <yao.qi@linaro.org>
2024 * linux-aarch32-low.h [__aarch64__]: Use arm_abi_breakpoint
2027 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
2029 * server.c (handle_query): Call target_supports_software_single_step.
2031 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
2033 * linux-low.c (single_step): New function.
2034 (linux_resume_one_lwp_throw): Call single_step.
2035 (start_step_over): Likewise.
2037 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
2039 * Makefile.in (SFILES): Append arch/arm-linux.c,
2040 arch/arm-get-next-pcs.c.
2041 (arm-linux.o): New rule.
2042 (arm-get-next-pcs.o): New rule.
2043 * configure.srv (arm*-*-linux*): Add arm-get-next-pcs.o,
2045 * linux-aarch32-low.c (arm_abi_breakpoint): Remove macro. Moved
2046 to linux-aarch32-low.c.
2047 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
2048 (arm_breakpoint_len, thumb_breakpoint): Likewise.
2049 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
2050 (thumb2_breakpoint_len): Likewise.
2051 (arm_is_thumb_mode): Make non-static.
2052 * linux-aarch32-low.h (arm_abi_breakpoint): New macro. Moved
2053 from linux-aarch32-low.c.
2054 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
2055 (arm_breakpoint_len, thumb_breakpoint): Likewise.
2056 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
2057 (thumb2_breakpoint_len): Likewise.
2058 (arm_is_thumb_mode): New declaration.
2059 * linux-arm-low.c: Include arch/arm-linux.h
2060 aarch/arm-get-next-pcs.h, sys/syscall.h.
2061 (get_next_pcs_ops): New struct.
2062 (get_next_pcs_addr_bits_remove): New function.
2063 (get_next_pcs_is_thumb): New function.
2064 (get_next_pcs_read_memory_unsigned_integer): Likewise.
2065 (arm_sigreturn_next_pc): Likewise.
2066 (get_next_pcs_syscall_next_pc): Likewise.
2067 (arm_gdbserver_get_next_pcs): Likewise.
2068 (struct linux_target_ops) <arm_gdbserver_get_next_pcs>:
2070 * linux-low.h: Move CORE_ADDR vector definition to gdb_vecs.h.
2071 * server.h: Include gdb_vecs.h.
2073 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
2075 * Makefile.in (SFILES): Append common/common-regcache.c.
2076 (OBS): Append common-regcache.o.
2077 (common-regcache.o): New rule.
2078 * regcache.c (init_register_cache): Initialize cache to
2080 (regcache_raw_read_unsigned): New function.
2081 * regcache.h (REG_UNAVAILABLE, REG_VALID): Replaced by shared
2082 register_status enum.
2084 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
2086 * linux-aarch64-low.c (the_low_targets): Rename
2087 breakpoint_reinsert_addr to get_next_pcs.
2088 * linux-arm-low.c (the_low_targets): Likewise.
2089 * linux-bfin-low.c (the_low_targets): Likewise.
2090 * linux-cris-low.c (the_low_targets): Likewise.
2091 * linux-crisv32-low.c (the_low_targets): Likewise.
2092 * linux-low.c (can_software_single_step): Likewise.
2093 (install_software_single_step_breakpoints): New function.
2094 (start_step_over): Use install_software_single_step_breakpoints.
2095 * linux-low.h: New CORE_ADDR vector.
2096 (struct linux_target_ops) Rename breakpoint_reinsert_addr to
2098 * linux-mips-low.c (the_low_targets): Likewise.
2099 * linux-nios2-low.c (the_low_targets): Likewise.
2100 * linux-sparc-low.c (the_low_targets): Likewise.
2102 2015-12-17 Pedro Alves <palves@redhat.com>
2104 * linux-low.c (linux_kill_one_lwp): Remove references to
2106 (kill_lwp): Remove HAVE_TKILL_SYSCALL check. No longer fall back
2108 (linux_init_signals): Delete.
2109 (initialize_low): Adjust.
2110 * thread-db.c (thread_db_init): Remove LinuxThreads reference.
2112 2015-12-16 Pedro Alves <palves@redhat.com>
2114 * configure.ac (compiler warning flags): When testing a
2115 -Wno-foo option, check whether -Wfoo works instead.
2116 * configure: Regenerate.
2118 2015-12-11 Don Breazeal <donb@codesourcery.com>
2120 * server.c (process_serial_event): Don't exit from gdbserver
2121 in remote mode if there are still active inferiors.
2123 2015-12-11 Yao Qi <yao.qi@linaro.org>
2125 * linux-aarch64-low.c (aarch64_breakpoint_at): Call
2126 arm_breakpoint_at if the process is 32-bit.
2128 2015-12-11 Yao Qi <yao.qi@linaro.org>
2130 * linux-aarch32-low.c [__aarch64__]: Use arm_abi_breakpoint
2133 2015-12-07 Yao Qi <yao.qi@linaro.org>
2135 * configure.srv: Append arm.o to srv_tgtobj for
2136 aarch64*-*-linux* target.
2137 * linux-aarch32-low.c (arm_abi_breakpoint): New macro. Moved
2138 from linux-arm-low.c.
2139 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
2140 (arm_breakpoint_len, thumb_breakpoint): Likewise.
2141 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
2142 (thumb2_breakpoint_len): Likewise.
2143 (arm_is_thumb_mode, arm_breakpoint_at): Likewise.
2144 (arm_breakpoint_kinds): Likewise.
2145 (arm_breakpoint_kind_from_pc): Likewise.
2146 (arm_sw_breakpoint_from_kind): Likewise.
2147 (arm_breakpoint_kind_from_current_state): Likewise.
2148 * linux-aarch32-low.h (arm_breakpoint_kind_from_pc): Declare.
2149 (arm_sw_breakpoint_from_kind): Declare.
2150 (arm_breakpoint_kind_from_current_state): Declare.
2151 (arm_breakpoint_at): Declare.
2152 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): Call
2153 arm_sw_breakpoint_from_kind if process is 32-bit.
2154 (aarch64_breakpoint_kind_from_pc): New function.
2155 (aarch64_breakpoint_kind_from_current_state): New function.
2156 (the_low_target): Initialize fields breakpoint_kind_from_pc
2157 and breakpoint_kind_from_current_state.
2158 * linux-arm-low.c (arm_breakpoint_kinds): Move to
2159 linux-aarch32-low.c.
2160 (arm_abi_breakpoint, arm_eabi_breakpoint): Likewise.
2161 (arm_breakpoint, arm_breakpoint_len): Likewise.
2162 (thumb_breakpoint, thumb_breakpoint_len): Likewise.
2163 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
2164 (arm_is_thumb_mode): Likewise.
2165 (arm_breakpoint_at): Likewise.
2166 (arm_breakpoint_kind_from_pc): Likewise.
2167 (arm_sw_breakpoint_from_kind): Likewise.
2168 (arm_breakpoint_kind_from_current_state): Likewise.
2171 2015-08-04 Yao Qi <yao.qi@linaro.org>
2173 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
2174 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
2175 * server.c (extended_protocol): Remove "static".
2176 * server.h (extended_protocol): Declare it.
2178 2015-12-04 Josh Stone <jistone@redhat.com>
2180 * target.h (struct target_ops) <arch_setup>: Rename to ...
2181 (struct target_ops) <post_create_inferior>: ... this.
2182 (target_arch_setup): Rename to ...
2183 (target_post_create_inferior): ... this, calling post_create_inferior.
2184 * server.c (start_inferior): Update target_arch_setup calls to
2185 target_post_create_inferior.
2186 * linux-low.c (linux_low_ptrace_options): Forward declare.
2187 (linux_arch_setup): Update its comment for general use.
2188 (linux_post_create_inferior): New, run arch_setup and setup ptrace.
2189 (struct linux_target_ops): Use linux_post_create_inferior.
2190 * lynx-low.c (struct lynx_target_ops): Update arch_setup stub comment
2191 to post_create_inferior.
2192 * nto-low.c (struct nto_target_ops): Likewise.
2193 * spu-low.c (struct spu_target_ops): Likewise.
2194 * win32-low.c (struct win32_target_ops): Likewise.
2196 2015-12-03 Antoine Tremblay <antoine.tremblay@ericsson.com>
2198 * linux-arm-low.c: Remove duplicate arch/arm.h include.
2200 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
2202 * linux-arm-low.c (arm_reinsert_addr): Remove function.
2203 (struct linux_target_ops <breakpoint_reinsert_addr>: Set to NULL.
2204 * linux-cris-low.c (cris_reinsert_addr> Remove function.
2205 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
2206 * linux-crisv32-low.c (cris_reinsert_addr): Remove function.
2207 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
2208 * linux-mips-low.c (mips_reinsert_addr): Remove function.
2209 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
2210 * linux-nios2-low.c (nios2_reinsert_addr): Remove function.
2211 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
2212 * linux-sparc-low.c (sparc_reinsert_addr): Remove function.
2213 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
2215 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
2217 * linux-low.c (linux_look_up_symbols): Don't call
2218 linux_supports_traceclone.
2219 * linux-low.h (thread_db_init): Remove use_events argument.
2220 * thread-db.c (thread_db_use_event): Remove global variable.
2221 (struct thread_db) <td_thr_event_enable_p>: Remove field.
2222 (struct thread_db) <td_create_bp>: Remove field.
2223 (thread_db_create_event): Remove function.
2224 (thread_db_enable_reporting): Likewise.
2225 (find_one_thread): Don't check for thread_db_use_events.
2226 (attach_thread): Likewise.
2227 (thread_db_load_search): Remove td_thr_event_enable_p initialization.
2228 (try_thread_db_load_1): Don't check for thread_db_use_events.
2229 (thread_db_init): Remove use_events argument and thread events
2231 (remove_thread_event_breakpoints): Remove function.
2232 (thread_db_detach): Remove call to remove_thred_event_breakpoints.
2234 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
2236 * linux-aarch64-low.c (aarch64_supports_hardware_single_step):
2238 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
2239 * linux-arm-low.c (arm_supports_hardware_single_step): New function.
2240 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
2241 * linux-bfin-low.c (bfin_supports_hardware_single_step): New function.
2242 (struct linux_target_ops) <bfin_supports_hardware_single_step>:
2244 * linux-crisv32-low.c (cris_supports_hardware_single_step):
2246 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
2247 * linux-low.c (can_hardware_single_step): Use
2248 supports_hardware_single_step.
2249 (can_software_single_step): New function.
2250 (start_step_over): Call can_software_single_step.
2251 (linux_supports_hardware_single_step): New function.
2252 (struct target_ops) <supports_software_single_step>: Initialize.
2253 * linux-low.h (struct linux_target_ops)
2254 <supports_hardware_single_step>: Initialize.
2255 * linux-m32r-low.c (m32r_supports_hardware_single_step): New function.
2256 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
2257 * linux-ppc-low.c (ppc_supports_hardware_single_step): New function.
2258 (struct linux_target_ops) <supports_hardware_single_step> Initialize.
2259 * linux-s390-low.c (s390_supports_hardware_single_step): New function.
2260 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
2261 * linux-sh-low.c (sh_supports_hardware_single_step): New function.
2262 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
2263 * linux-tic6x-low.c (tic6x_supports_hardware_single_step): New function.
2264 (struct linux_target_ops) <tic6x_supports_hardware_single_step>:
2266 * linux-tile-low.c (tile_supports_hardware_single_step): New function.
2267 (struct linux_target_ops) <tile_supports_hardware_single_step>:
2269 * linux-x86-low.c (x86_supports_hardware_single_step) New function.
2270 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
2271 * linux-xtensa-low.c (xtensa_supports_hardware_single_step):
2273 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
2274 * target.h (struct target_ops): <supports_software_single_step>:
2276 (target_supports_software_single_step): New macro.
2278 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
2280 * linux-low.c (linux_wait_1): Fix pc advance condition.
2281 * mem-break.c (reinsert_breakpoint_inserted_here): New function.
2282 * mem-break.h (reinsert_breakpoint_inserted_here): New declaration.
2284 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
2286 * linux-arm-low.c (arm_is_thumb_mode): New function.
2287 (arm_breakpoint_at): Use arm_is_thumb_mode.
2288 (arm_breakpoint_kind_from_current_state): New function.
2289 (struct linux_target_ops) <breakpoint_kind_from_current_state>:
2291 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_current_state.
2292 (linux_breakpoint_kind_from_current_state): New function.
2293 (struct target_ops <breakpoint_kind_from_current_state>: Initialize.
2294 * linux-low.h (struct linux_target_ops)
2295 <breakpoint_kind_from_current_state>: New field.
2296 * target.h (struct target_ops): Likewise.
2297 (target_breakpoint_kind_from_current_state): New macro.
2299 2015-11-30 Pedro Alves <palves@redhat.com>
2301 * linux-low.c (linux_resume): Wake up the event loop before
2304 2015-11-30 Pedro Alves <palves@redhat.com>
2306 * mem-break.c (check_gdb_bp_preconditions): Remove current_thread
2308 (set_gdb_breakpoint): If prepare_to_access_memory fails, set *ERR
2310 * target.c (struct thread_search): New structure.
2311 (thread_search_callback): New function.
2312 (prev_general_thread): New global.
2313 (prepare_to_access_memory, done_accessing_memory): New functions.
2314 * target.h (prepare_to_access_memory, done_accessing_memory):
2315 Replace macros with function declarations.
2317 2015-11-30 Pedro Alves <palves@redhat.com>
2320 * linux-low.c (linux_wait_1): If the last resumed thread is gone,
2321 report TARGET_WAITKIND_NO_RESUMED.
2322 * remote-utils.c (prepare_resume_reply): Handle
2323 TARGET_WAITKIND_NO_RESUMED.
2324 * server.c (report_no_resumed): New global.
2325 (handle_query) <qSupported>: Handle "no-resumed+". Report
2326 "no-resumed+" support.
2327 (resume): When the target reports TARGET_WAITKIND_NO_RESUMED, only
2328 return error if the client doesn't support no-resumed events.
2329 (push_stop_notification): New function.
2330 (handle_target_event): Use it. Report TARGET_WAITKIND_NO_RESUMED
2331 events if the client supports them.
2333 2015-11-30 Pedro Alves <palves@redhat.com>
2335 * linux-low.c (thread_still_has_status_pending_p): Don't check
2337 (lwp_resumed): New function.
2338 (status_pending_p_callback): Return early if the LWP is not
2339 supposed to be resumed.
2341 2015-11-30 Pedro Alves <palves@redhat.com>
2343 * linux-low.c (handle_extended_wait): Assert that the LWP's
2344 waitstatus is TARGET_WAITKIND_IGNORE. If GDB wants to hear about
2345 thread create events, leave the new child's status pending.
2346 (linux_low_filter_event): If GDB wants to hear about thread exit
2347 events, leave the LWP marked dead and don't delete it.
2348 (linux_wait_for_event_filtered): Don't check for thread exit.
2349 (filter_exit_event): New function.
2350 (linux_wait_1): Use it, when returning an exit event.
2351 (linux_resume_one_lwp_throw): Assert that the LWP's
2352 waitstatus is TARGET_WAITKIND_IGNORE.
2353 * remote-utils.c (prepare_resume_reply): Handle
2354 TARGET_WAITKIND_THREAD_CREATED and TARGET_WAITKIND_THREAD_EXITED.
2355 * server.c (report_thread_events): New global.
2356 (handle_general_set): Handle QThreadEvents.
2357 (handle_query) <qSupported>: Handle and report QThreadEvents+;
2358 (handle_target_event): Handle TARGET_WAITKIND_THREAD_CREATED and
2359 TARGET_WAITKIND_THREAD_EXITED.
2360 * server.h (report_thread_events): Declare.
2362 2015-11-30 Pedro Alves <palves@redhat.com>
2364 * linux-low.c (resume_stopped_resumed_lwps): Don't check whether
2365 the thread's last_resume_kind was resume_stop.
2367 2015-11-30 Pedro Alves <palves@redhat.com>
2369 * linux-low.c (linux_attach): In non-stop mode, wait for one stop
2372 2015-11-30 Pedro Alves <palves@redhat.com>
2374 * server.c (handle_v_requests): Handle vCtrlC.
2376 2015-11-30 Pedro Alves <palves@redhat.com>
2378 * gdbthread.h (find_any_thread_of_pid): Declare.
2379 * inferiors.c (thread_of_pid, find_any_thread_of_pid): New
2381 * server.c (handle_query): If current_thread is NULL, look for
2382 another thread of the selected process.
2384 2015-11-26 Daniel Colascione <dancol@dancol.org>
2385 Simon Marchi <simon.marchi@ericsson.com>
2387 * linux-low.c (linux_target_ops): Use linux_proc_tid_get_name.
2388 * server.c (handle_qxfer_threads_worker): Refactor to include thread
2390 * target.h (struct target_ops) <thread_name>: New field.
2391 (target_thread_name): New macro.
2393 2015-11-23 Joel Brobecker <brobecker@adacore.com>
2395 * regcache.h (regcache_invalidate_pid): Add declaration.
2396 * regcache.c (regcache_invalidate_pid): New function, extracted
2397 from regcache_invalidate.
2398 (regcache_invalidate): Reimplement using regcache_invalidate_pid.
2399 Add trivial documentation comment.
2400 * lynx-low.c: Use regcache_invalidate_pid instead of
2401 regcache_invalidate.
2403 2015-11-23 Joel Brobecker <brobecker@adacore.com>
2405 * configure.ac: Do not call AC_CHECK_TYPES for Elf32_auxv_t
2406 and Elf64_auxv_t if the target is Android.
2408 2015-11-22 Doug Evans <xdje42@gmail.com>
2410 * target.h: #include <sys/types.h>.
2412 2015-11-19 Pedro Alves <palves@redhat.com>
2414 * linux-low.c (linux_process_qsupported): Change prototype.
2416 * linux-low.h (struct linux_target_ops) <process_qsupported>:
2418 * linux-x86-low.c (x86_linux_process_qsupported): Change prototype
2419 and adjust to loop over all features.
2420 * server.c (handle_query) <qSupported>: Adjust to call
2421 target_process_qsupported once, passing it a vector of unprocessed
2423 * target.h (struct target_ops) <process_qsupported>: Change
2425 (target_process_qsupported): Adjust.
2427 2015-11-19 Pedro Alves <palves@redhat.com>
2429 * configure.ac (ERROR_ON_WARNING): Don't check whether in C++
2431 * configure: Regenerate.
2433 2015-11-19 Pedro Alves <palves@redhat.com>
2435 * configure: Regenerate.
2437 2015-11-19 Yao Qi <yao.qi@linaro.org>
2439 * linux-aarch64-low.c (emit_data_processing_reg): Change opcode
2442 2015-11-19 Yao Qi <yao.qi@linaro.org>
2444 * linux-aarch64-low.c (enum aarch64_operand_type): New.
2445 (struct aarch64_operand): Move enum out.
2447 2015-11-19 Yao Qi <yao.qi@linaro.org>
2449 * linux-aarch64-low.c (aarch64_fill_fpregset): Cast buf to
2450 struct user_fpsimd_state *.
2451 (aarch64_store_fpregset): Likewise.
2453 2015-11-19 Yao Qi <yao.qi@linaro.org>
2455 * linux-aarch64-low.c (aarch64_fill_gregset): Cast buf to
2456 struct user_pt_regs *.
2457 (aarch64_store_gregset): Likewise.
2459 2015-11-18 Pedro Alves <palves@redhat.com>
2461 * Makefile.in (all_object_files): Add $IPA_OBJS.
2463 2015-11-17 Pedro Alves <palves@redhat.com>
2465 * win32-low.c (win32_resume): Use gdb_signal_from_host,
2466 GDB_SIGNAL_0 and gdb_signal_to_string.
2468 2015-11-17 Pedro Alves <palves@redhat.com>
2470 * win32-low.c (handle_output_debug_string): Remove parameter.
2471 (win32_kill): Remove our_status local and adjust call to
2472 handle_output_debug_string.
2473 (get_child_debug_event): Adjust call to
2474 handle_output_debug_string.
2476 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
2478 * linux-mips-low.c (mips_fill_gregset): Add cast.
2479 (mips_store_gregset): Likewise.
2480 (mips_fill_fpregset): Likewise.
2481 (mips_store_fpregset): Likewise.
2483 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
2485 * linux-mips-low.c (mips_add_watchpoint): Rename private to
2488 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
2490 * linux-mips-low.c (mips_linux_new_thread): Change type of
2491 watch_type to enum target_hw_bp_type.
2493 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
2495 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type):
2496 Change return type to arm_hwbp_type.
2498 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
2500 * linux-aarch32-low.c (arm_fill_gregset): Add cast.
2501 (arm_store_gregset): Likewise.
2502 * linux-arm-low.c (arm_get_hwcap): Likewise.
2503 (arm_read_description): Likewise.
2505 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
2507 * linux-aarch32-low.c (aarch32_regsets): Use NULL_REGSET.
2509 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
2511 * linux-ppc-low.c (ppc_get_hwcap): Add cast.
2512 (ppc_fill_vsxregset): Likewise.
2513 (ppc_store_vsxregset): Likewise.
2514 (ppc_fill_vrregset): Likewise.
2515 (ppc_store_vrregset): Likewise.
2516 (ppc_fill_evrregset): Likewise.
2517 (ppc_store_evrregset): Likewise.
2519 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
2521 * linux-ppc-low.c (ppc_usrregs_info): Remove
2522 forward-declaration.
2523 (ppc_arch_setup): Move lower in file.
2525 2015-10-30 Simon Marchi <simon.marchi@ericsson.com>
2527 * proc-service.c (ps_pdread): Change CORE_ADDR cast to uintptr_t.
2528 (ps_pdwrite): Likewise.
2530 2015-10-29 Henrik Wallin <henrik.wallin@windriver.com>
2532 * linux-arm-low.c (arm_new_thread): Move pointer dereference
2533 to after assert checks.
2535 2015-10-29 Simon Marchi <simon.marchi@ericsson.com>
2537 * proc-service.c (ps_pdread): Add/adjust casts.
2538 (ps_pdwrite): Add/adjust casts.
2540 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
2542 * server.c (handle_search_memory_1): Cast return value of
2545 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
2547 * server.c (write_qxfer_response): Change type of data to
2550 2015-10-29 Pedro Alves <palves@redhat.com>
2552 * mem-break.c (Z_packet_to_bkpt_type): Add cast.
2554 2015-10-29 Pedro Alves <palves@redhat.com>
2556 * tracepoint.c (clear_installed_tracepoints): Add casts.
2558 2015-10-29 Pedro Alves <palves@redhat.com>
2560 * server.c (handle_v_cont, process_serial_event): Add enum
2561 gdb_signal casts to signal parsing code.
2563 2015-10-29 Pedro Alves <palves@redhat.com>
2565 * linux-low.h (NULL_REGSET): Define.
2566 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
2567 * linux-arm-low.c (arm_regsets): Likewise.
2568 * linux-crisv32-low.c (cris_regsets): Likewise.
2569 * linux-m68k-low.c (m68k_regsets): Likewise.
2570 * linux-mips-low.c (mips_regsets): Likewise.
2571 * linux-nios2-low.c (nios2_regsets): Likewise.
2572 * linux-ppc-low.c (ppc_regsets): Likewise.
2573 * linux-s390-low.c (s390_regsets): Likewise.
2574 * linux-sh-low.c (sh_regsets): Likewise.
2575 * linux-sparc-low.c (sparc_regsets): Likewise.
2576 * linux-tic6x-low.c (tic6x_regsets): Likewise.
2577 * linux-tile-low.c (tile_regsets): Likewise.
2578 * linux-x86-low.c (x86_regsets): Likewise.
2579 * linux-xtensa-low.c (xtensa_regsets): Likewise.
2581 2015-10-29 Pedro Alves <palves@redhat.com>
2583 * linux-low.h (NULL_REGSET): Define.
2584 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
2585 * linux-arm-low.c (arm_regsets): Likewise.
2586 * linux-crisv32-low.c (cris_regsets): Likewise.
2587 * linux-m68k-low.c (m68k_regsets): Likewise.
2588 * linux-mips-low.c (mips_regsets): Likewise.
2589 * linux-nios2-low.c (nios2_regsets): Likewise.
2590 * linux-ppc-low.c (ppc_regsets): Likewise.
2591 * linux-s390-low.c (s390_regsets): Likewise.
2592 * linux-sh-low.c (sh_regsets): Likewise.
2593 * linux-sparc-low.c (sparc_regsets): Likewise.
2594 * linux-tic6x-low.c (tic6x_regsets): Likewise.
2595 * linux-tile-low.c (tile_regsets): Likewise.
2596 * linux-x86-low.c (x86_regsets): Likewise.
2597 * linux-xtensa-low.c (xtensa_regsets): Likewise.
2599 2015-10-26 Doug Evans <dje@google.com>
2601 * linux-low.c (__SIGRTMIN): Move to nat/linux-nat.h.
2603 2015-10-26 Doug Evans <dje@google.com>
2605 * linux-low.c (W_STOPCODE): Moved to common/gdb_wait.h.
2607 2015-10-26 Doug Evans <dje@google.com>
2609 * thread-db.c (find_one_thread): Cast ti.ti_tid to unsigned long
2611 (attach_thread, find_new_threads_callback): Ditto.
2613 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
2615 * mem-break.h (set_breakpoint_data): Remove.
2617 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
2619 * nto-low.c (nto_sw_breakpoint_from_kind): New function.
2620 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
2621 (initialize_low): Remove set_breakpoint_data call.
2622 * spu-low.c (spu_sw_breakpoint_from_kind): New function.
2623 (struct target_ops) <sw_breakpoint_from_kind>: Iniitalize.
2624 (initialize_low): Remove set_breakpoint_data call.
2625 * win32-low.c (win32_sw_breakpoint_from_kind): New function.
2626 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
2627 (initialize_low): Remove set_breakpoint_data call.
2629 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
2631 * linux-low.c (default_breakpoint_kind_from_pc): Move to target.c.
2632 * mem-break.c (set_breakpoint_at): Use target_breakpoint_kind_from_pc.
2633 * target.c (default_breakpoint_kind_from_pc): Moved from linux-low.c
2634 * target.h (target_breakpoint_kind_from_pc): New macro.
2636 2015-10-22 Antoine Tremblay <antoine.tremblay@ericsson.com>
2638 * linux-low.c (default_breakpoint_kind_from_pc): New function.
2639 (linux_breakpoint_kind_from_pc): Use default_breakpoint_kind_from_pc for
2640 the default breakpoint kind.
2642 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
2644 * linux-arm-low.c (arm_supports_z_point_type): Add software
2647 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
2649 * linux-arm-low.c: Refactor breakpoint definitions.
2650 (arm_breakpoint_at): Adjust for arm_abi_breakpoint.
2651 (arm_sw_breakpoint_from_kind): Adjust for arm_breakpoint.
2653 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
2655 * Makefile.in: Add arm.c/o.
2656 * configure.srv: Likewise.
2657 * linux-arm-low.c (arm_breakpoint_kinds): New enum.
2658 (arm_breakpoint_kind_from_pc): New function.
2659 (arm_sw_breakpoint_from_kind): Return proper kind.
2660 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize.
2662 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
2664 * linux-low.c (initialize_low): Ajdust for breakpoint global variables
2666 * mem-break.c : Remove breakpoint_data/breakpoint_len global variables.
2667 (struct raw_breakpoint) <size>: Remove.
2668 (struct raw_breakpoint) <kind>: Add.
2669 (bp_size): New function.
2670 (bp_opcode): Likewise.
2671 (find_raw_breakpoint_at): Adjust for kind.
2672 (insert_memory_breakpoint): Adjust for kind call bp_size,bp_opcode.
2673 (remove_memory_breakpoint): Adjust for kind call bp_size.
2674 (set_raw_breakpoint_at): Adjust for kind.
2675 (set_breakpoint): Likewise.
2676 (set_breakpoint_at): Call breakpoint_kind_from_pc.
2677 (delete_raw_breakpoint): Adjust for kind.
2678 (delete_breakpoint): Likewise.
2679 (find_gdb_breakpoint): Likewise.
2680 (set_gdb_breakpoint_1): Likewise.
2681 (set_gdb_breakpoint): Likewise.
2682 (delete_gdb_breakpoint_1): Likewise.
2683 (delete_gdb_breakpoint): Likewise.
2684 (uninsert_raw_breakpoint): Likewise.
2685 (reinsert_raw_breakpoint): Likewise.
2686 (set_breakpoint_data): Remove.
2687 (validate_inserted_breakpoint): Adjust for kind call bp_size,bp_opcode.
2688 (check_mem_read): Adjust for kind call bp_size.
2689 (check_mem_write): Adjust for kind call bp_size,bp_opcode.
2690 (clone_one_breakpoint): Adjust for kind.
2691 * mem-break.h (set_gdb_breakpoint): Likewise.
2692 (delete_gdb_breakpoint): Likewise.
2693 * server.c (process_serial_event): Likewise.
2695 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
2697 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): New function.
2698 (struct linux_target_ops) <breakpoint>: Remove.
2699 (struct linux_target_ops) <breakpoint_len>: Remove.
2700 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
2701 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
2702 * linux-arm-low.c (arm_breakpoint_kind_from_pc): New function.
2703 (arm_sw_breakpoint_from_kind): New function.
2704 * linux-bfin-low.c (bfin_sw_breakpoint_from_kind): New function.
2705 (struct linux_target_ops) <breakpoint>: Remove.
2706 (struct linux_target_ops) <breakpoint_len>: Remove.
2707 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
2708 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
2709 * linux-cris-low.c (cris_sw_breakpoint_from_kind): New function.
2710 (struct linux_target_ops) <breakpoint>: Remove.
2711 (struct linux_target_ops) <breakpoint_len>: Remove.
2712 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
2713 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
2714 * linux-crisv32-low.c (cris_sw_breakpoint_from_kind): New function.
2715 (struct linux_target_ops) <breakpoint>: Remove.
2716 (struct linux_target_ops) <breakpoint_len>: Remove.
2717 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
2718 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
2719 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_pc
2720 and sw_breakpoint_from_kind to increment the pc.
2721 (linux_breakpoint_kind_from_pc): New function.
2722 (linux_sw_breakpoint_from_kind): New function.
2723 (struct target_ops) <sw_breakpoint_from_kind>: Initialize field.
2724 (initialize_low): Call breakpoint_kind_from_pc and
2725 sw_breakpoint_from_kind to replace breakpoint_data/len.
2726 * linux-low.h (struct linux_target_ops) <breakpoint_kind_from_pc>:
2728 (struct linux_target_ops) <sw_breakpoint_from_kind>: Likewise.
2729 * linux-m32r-low.c (m32r_sw_breakpoint_from_kind): New function.
2730 (struct linux_target_ops) <breakpoint>: Remove.
2731 (struct linux_target_ops) <breakpoint_len>: Remove.
2732 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
2733 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
2734 * linux-m68k-low.c (m68k_sw_breakpoint_from_kind): New function.
2735 (struct linux_target_ops) <breakpoint>: Remove.
2736 (struct linux_target_ops) <breakpoint_len>: Remove.
2737 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
2738 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
2739 * linux-mips-low.c (mips_sw_breakpoint_from_kind): New function.
2740 (struct linux_target_ops) <breakpoint>: Remove.
2741 (struct linux_target_ops) <breakpoint_len>: Remove.
2742 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
2743 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
2744 * linux-nios2-low.c (nios2_sw_breakpoint_from_kind): New function.
2745 (struct linux_target_ops) <breakpoint>: Remove.
2746 (struct linux_target_ops) <breakpoint_len>: Remove.
2747 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
2748 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
2749 * linux-ppc-low.c (ppc_sw_breakpoint_from_kind): New function.
2750 (struct linux_target_ops) <breakpoint>: Remove.
2751 (struct linux_target_ops) <breakpoint_len>: Remove.
2752 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
2753 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
2754 * linux-s390-low.c (s390_sw_breakpoint_from_kind): New function.
2755 (struct linux_target_ops) <breakpoint>: Remove.
2756 (struct linux_target_ops) <breakpoint_len>: Remove.
2757 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
2758 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
2759 * linux-sh-low.c (sh_sw_breakpoint_from_kind): New function.
2760 (struct linux_target_ops) <breakpoint>: Remove.
2761 (struct linux_target_ops) <breakpoint_len>: Remove.
2762 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
2763 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
2764 * linux-sparc-low.c (sparc_sw_breakpoint_from_kind): New function.
2765 (struct linux_target_ops) <breakpoint>: Remove.
2766 (struct linux_target_ops) <breakpoint_len>: Remove.
2767 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
2768 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
2769 * linux-tic6x-low.c (tic6x_sw_breakpoint_from_kind): New function.
2770 (struct linux_target_ops) <breakpoint>: Remove.
2771 (struct linux_target_ops) <breakpoint_len>: Remove.
2772 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
2773 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
2774 * linux-tile-low.c (tile_sw_breakpoint_from_kind): New function.
2775 * linux-x86-low.c (x86_sw_breakpoint_from_kind): New function.
2776 (struct linux_target_ops) <breakpoint>: Remove.
2777 (struct linux_target_ops) <breakpoint_len>: Remove.
2778 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
2779 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
2780 * linux-xtensa-low.c (xtensa_sw_breakpoint_from_kind) New function.
2781 (struct linux_target_ops) <breakpoint>: Remove.
2782 (struct linux_target_ops) <breakpoint_len>: Remove.
2783 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
2784 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
2786 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
2788 * linux-cris-low.c (cris_get_pc): Remove void arg.
2790 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
2792 * gdbserver/nto-low.c (nto_insert_point, nto_remove_point): Fix
2795 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
2797 * inferiors.c (thread_pid_matches_callback): New function.
2798 (find_thread_process): New function.
2799 (remove_thread): Reset current_thread.
2800 (remove_process): Assert threads have been removed first.
2802 2015-10-15 Yao Qi <yao.qi@linaro.org>
2804 * linux-aarch64-low.c (aarch64_insert_point): Set len to 2
2806 (aarch64_remove_point): Likewise.
2807 * regcache.c (regcache_register_size): New function.
2809 2015-10-12 Yao Qi <yao.qi@linaro.org>
2811 * linux-aarch64-low.c: Update all callers as emit_load_store
2812 is renamed to aarch64_emit_load_store.
2814 2015-10-12 Yao Qi <yao.qi@linaro.org>
2816 * linux-aarch64-low.c: Update all callers of function renaming
2817 from emit_insn to aarch64_emit_insn.
2819 2015-10-12 Yao Qi <yao.qi@linaro.org>
2821 * linux-aarch64-low.c (enum aarch64_opcodes): Move to
2822 arch/aarch64-insn.h.
2823 (struct aarch64_memory_operand): Likewise.
2825 (emit_insn): Move to arch/aarch64-insn.c.
2826 (emit_b, emit_bcond, emit_cb, emit_tb): Remove.
2827 (emit_load_store): Move to arch/aarch64-insn.c.
2828 (emit_ldr, emit_ldrb, emit_ldrsw, emit_nop): Remove.
2829 (can_encode_int32): Remove.
2831 2015-10-12 Yao Qi <yao.qi@linaro.org>
2833 * linux-aarch64-low.c (extract_signed_bitfield): Remove.
2834 (aarch64_decode_ldr_literal): Move to gdb/arch/aarch64-insn.c.
2835 (aarch64_relocate_instruction): Likewise.
2836 (struct aarch64_insn_data): Move to gdb/arch/aarch64-insn.h.
2837 (struct aarch64_insn_visitor): Likewise.
2839 2015-10-12 Yao Qi <yao.qi@linaro.org>
2841 * linux-aarch64-low.c (struct aarch64_insn_data): New.
2842 (struct aarch64_insn_visitor): New.
2843 (struct aarch64_insn_relocation_data): New.
2844 (aarch64_ftrace_insn_reloc_b): New function.
2845 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
2846 (aarch64_ftrace_insn_reloc_cb): Likewise.
2847 (aarch64_ftrace_insn_reloc_tb): Likewise.
2848 (aarch64_ftrace_insn_reloc_adr): Likewise.
2849 (aarch64_ftrace_insn_reloc_ldr_literal): Likewise.
2850 (aarch64_ftrace_insn_reloc_others): Likewise.
2852 (aarch64_relocate_instruction): Use visitor.
2854 2015-10-12 Yao Qi <yao.qi@linaro.org>
2856 * linux-aarch64-low.c (aarch64_relocate_instruction): Return
2857 int. Add argument buf.
2858 (aarch64_install_fast_tracepoint_jump_pad): Pass buf to
2859 aarch64_relocate_instruction.
2861 2015-10-12 Yao Qi <yao.qi@linaro.org>
2863 * linux-aarch64-low.c (aarch64_relocate_instruction): Add
2864 argument insn. Remove local variable insn. Don't call
2866 (aarch64_install_fast_tracepoint_jump_pad): Call
2869 2015-09-30 Yao Qi <yao.qi@linaro.org>
2871 * linux-aarch64-low.c (emit_movk): Shorten a long line.
2872 (emit_load_store_pair): Likewise.
2874 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
2876 * dll.c (match_dll): Add cast(s).
2877 (unloaded_dll): Likewise.
2878 * linux-low.c (second_thread_of_pid_p): Likewise.
2879 (delete_lwp_callback): Likewise.
2880 (count_events_callback): Likewise.
2881 (select_event_lwp_callback): Likewise.
2882 (linux_set_resume_request): Likewise.
2883 * server.c (accumulate_file_name_length): Likewise.
2884 (emit_dll_description): Likewise.
2885 (handle_qxfer_threads_worker): Likewise.
2886 (visit_actioned_threads): Likewise.
2887 * thread-db.c (any_thread_of): Likewise.
2888 * tracepoint.c (same_process_p): Likewise.
2889 (match_blocktype): Likewise.
2890 (build_traceframe_info_xml): Likewise.
2892 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
2894 * ax.c (gdb_parse_agent_expr): Add cast to allocation result
2896 (gdb_unparse_agent_expr): Likewise.
2897 * hostio.c (require_data): Likewise.
2898 (handle_pread): Likewise.
2899 * linux-low.c (disable_regset): Likewise.
2900 (fetch_register): Likewise.
2901 (store_register): Likewise.
2902 (get_dynamic): Likewise.
2903 (linux_qxfer_libraries_svr4): Likewise.
2904 * mem-break.c (delete_fast_tracepoint_jump): Likewise.
2905 (set_fast_tracepoint_jump): Likewise.
2906 (uninsert_fast_tracepoint_jumps_at): Likewise.
2907 (reinsert_fast_tracepoint_jumps_at): Likewise.
2908 (validate_inserted_breakpoint): Likewise.
2909 (clone_agent_expr): Likewise.
2910 * regcache.c (init_register_cache): Likewise.
2911 * remote-utils.c (putpkt_binary_1): Likewise.
2912 (decode_M_packet): Likewise.
2913 (decode_X_packet): Likewise.
2914 (look_up_one_symbol): Likewise.
2915 (relocate_instruction): Likewise.
2916 (monitor_output): Likewise.
2917 * server.c (handle_search_memory): Likewise.
2918 (handle_qxfer_exec_file): Likewise.
2919 (handle_qxfer_libraries): Likewise.
2920 (handle_qxfer): Likewise.
2921 (handle_query): Likewise.
2922 (handle_v_cont): Likewise.
2923 (handle_v_run): Likewise.
2924 (captured_main): Likewise.
2925 * target.c (write_inferior_memory): Likewise.
2926 * thread-db.c (try_thread_db_load_from_dir): Likewise.
2927 * tracepoint.c (init_trace_buffer): Likewise.
2928 (add_tracepoint_action): Likewise.
2929 (add_traceframe): Likewise.
2930 (add_traceframe_block): Likewise.
2931 (cmd_qtdpsrc): Likewise.
2932 (cmd_qtdv): Likewise.
2933 (cmd_qtstatus): Likewise.
2934 (response_source): Likewise.
2935 (response_tsv): Likewise.
2936 (cmd_qtnotes): Likewise.
2937 (gdb_collect): Likewise.
2938 (initialize_tracepoint): Likewise.
2940 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
2942 * linux-aarch64-low-.c: Include ax.h and tracepoint.h.
2943 (enum aarch64_opcodes) <RET>, <SUBS>, <AND>, <ORR>, <ORN>,
2944 <EOR>, <LSLV>, <LSRV>, <ASRV>, <SBFM>, <UBFM>, <CSINC>, <MUL>,
2946 (enum aarch64_condition_codes): New enum.
2947 (w0): New static global.
2950 (struct aarch64_memory_operand) <type>: New
2951 MEMORY_OPERAND_POSTINDEX type.
2952 (postindex_memory_operand): New helper function.
2953 (emit_ret): New function.
2954 (emit_load_store_pair): New function, factored out of emit_stp
2955 with support for MEMORY_OPERAND_POSTINDEX.
2956 (emit_stp): Rewrite using emit_load_store_pair.
2957 (emit_ldp): New function.
2958 (emit_load_store): Likewise.
2959 (emit_ldr): Mention post-index instruction in comment.
2960 (emit_ldrh): New function.
2961 (emit_ldrb): New function.
2962 (emit_ldrsw): Mention post-index instruction in comment.
2963 (emit_str): Likewise.
2964 (emit_subs): New function.
2965 (emit_cmp): Likewise.
2966 (emit_and): Likewise.
2967 (emit_orr): Likewise.
2968 (emit_orn): Likewise.
2969 (emit_eor): Likewise.
2970 (emit_mvn): Likewise.
2971 (emit_lslv): Likewise.
2972 (emit_lsrv): Likewise.
2973 (emit_asrv): Likewise.
2974 (emit_mul): Likewise.
2975 (emit_sbfm): Likewise.
2976 (emit_sbfx): Likewise.
2977 (emit_ubfm): Likewise.
2978 (emit_ubfx): Likewise.
2979 (emit_csinc): Likewise.
2980 (emit_cset): Likewise.
2981 (emit_nop): Likewise.
2982 (emit_ops_insns): New helper function.
2983 (emit_pop): Likewise.
2984 (emit_push): Likewise.
2985 (aarch64_emit_prologue): New function.
2986 (aarch64_emit_epilogue): Likewise.
2987 (aarch64_emit_add): Likewise.
2988 (aarch64_emit_sub): Likewise.
2989 (aarch64_emit_mul): Likewise.
2990 (aarch64_emit_lsh): Likewise.
2991 (aarch64_emit_rsh_signed): Likewise.
2992 (aarch64_emit_rsh_unsigned): Likewise.
2993 (aarch64_emit_ext): Likewise.
2994 (aarch64_emit_log_not): Likewise.
2995 (aarch64_emit_bit_and): Likewise.
2996 (aarch64_emit_bit_or): Likewise.
2997 (aarch64_emit_bit_xor): Likewise.
2998 (aarch64_emit_bit_not): Likewise.
2999 (aarch64_emit_equal): Likewise.
3000 (aarch64_emit_less_signed): Likewise.
3001 (aarch64_emit_less_unsigned): Likewise.
3002 (aarch64_emit_ref): Likewise.
3003 (aarch64_emit_if_goto): Likewise.
3004 (aarch64_emit_goto): Likewise.
3005 (aarch64_write_goto_address): Likewise.
3006 (aarch64_emit_const): Likewise.
3007 (aarch64_emit_call): Likewise.
3008 (aarch64_emit_reg): Likewise.
3009 (aarch64_emit_pop): Likewise.
3010 (aarch64_emit_stack_flush): Likewise.
3011 (aarch64_emit_zero_ext): Likewise.
3012 (aarch64_emit_swap): Likewise.
3013 (aarch64_emit_stack_adjust): Likewise.
3014 (aarch64_emit_int_call_1): Likewise.
3015 (aarch64_emit_void_call_2): Likewise.
3016 (aarch64_emit_eq_goto): Likewise.
3017 (aarch64_emit_ne_goto): Likewise.
3018 (aarch64_emit_lt_goto): Likewise.
3019 (aarch64_emit_le_goto): Likewise.
3020 (aarch64_emit_gt_goto): Likewise.
3021 (aarch64_emit_ge_got): Likewise.
3022 (aarch64_emit_ops_impl): New static global variable.
3023 (aarch64_emit_ops): New target function, return
3024 &aarch64_emit_ops_impl.
3025 (struct linux_target_ops): Install it.
3027 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
3029 * Makefile.in (linux-aarch64-ipa.o, aarch64-ipa.o): New rules.
3030 * configure.srv (aarch64*-*-linux*): Add linux-aarch64-ipa.o and
3032 * linux-aarch64-ipa.c: New file.
3033 * linux-aarch64-low.c: Include arch/aarch64-insn.h, inttypes.h
3035 (aarch64_get_thread_area): New target method.
3036 (extract_signed_bitfield): New helper function.
3037 (aarch64_decode_ldr_literal): New function.
3038 (enum aarch64_opcodes): New enum.
3039 (struct aarch64_register): New struct.
3040 (struct aarch64_operand): New struct.
3041 (x0): New static global.
3050 (aarch64_register): New helper function.
3051 (register_operand): Likewise.
3052 (immediate_operand): Likewise.
3053 (struct aarch64_memory_operand): New struct.
3054 (offset_memory_operand): New helper function.
3055 (preindex_memory_operand): Likewise.
3056 (enum aarch64_system_control_registers): New enum.
3057 (ENCODE): New macro.
3058 (emit_insn): New helper function.
3059 (emit_b): New function.
3060 (emit_bcond): Likewise.
3061 (emit_cb): Likewise.
3062 (emit_tb): Likewise.
3063 (emit_blr): Likewise.
3064 (emit_stp): Likewise.
3065 (emit_ldp_q_offset): Likewise.
3066 (emit_stp_q_offset): Likewise.
3067 (emit_load_store): Likewise.
3068 (emit_ldr): Likewise.
3069 (emit_ldrsw): Likewise.
3070 (emit_str): Likewise.
3071 (emit_ldaxr): Likewise.
3072 (emit_stxr): Likewise.
3073 (emit_stlr): Likewise.
3074 (emit_data_processing_reg): Likewise.
3075 (emit_data_processing): Likewise.
3076 (emit_add): Likewise.
3077 (emit_sub): Likewise.
3078 (emit_mov): Likewise.
3079 (emit_movk): Likewise.
3080 (emit_mov_addr): Likewise.
3081 (emit_mrs): Likewise.
3082 (emit_msr): Likewise.
3083 (emit_sevl): Likewise.
3084 (emit_wfe): Likewise.
3085 (append_insns): Likewise.
3086 (can_encode_int32_in): New helper function.
3087 (aarch64_relocate_instruction): New function.
3088 (aarch64_install_fast_tracepoint_jump_pad): Likewise.
3089 (aarch64_get_min_fast_tracepoint_insn_len): Likewise.
3090 (struct linux_target_ops): Install aarch64_get_thread_area,
3091 aarch64_install_fast_tracepoint_jump_pad and
3092 aarch64_get_min_fast_tracepoint_insn_len.
3094 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
3096 * Makefile.in (aarch64-insn.o): New rule.
3097 * configure.srv (aarch64*-*-linux*): Add aarch64-insn.o.
3099 2015-09-21 Yao Qi <yao.qi@linaro.org>
3101 * ax.c [!IN_PROCESS_AGENT] (gdb_agent_op_sizes): Define it.
3103 2015-09-21 Yao Qi <yao.qi@linaro.org>
3105 * tracepoint.c (max_jump_pad_size): Remove.
3107 2015-09-18 Yao Qi <yao.qi@linaro.org>
3109 * linux-aarch64-low.c: Don't include sys/uio.h.
3110 (ps_get_thread_area): Call aarch64_ps_get_thread_area.
3112 2015-09-16 Wei-cheng Wang <cole945@gmail.com>
3114 * tracepoint.c (eval_result_type): Change prototype.
3115 (condition_true_at_tracepoint): Fix argument to compiled_cond.
3117 2015-09-15 Pedro Alves <palves@redhat.com>
3119 * remote-utils.c (prepare_resume_reply) <TARGET_WAITKIND_EXECD>:
3120 Check whether to report exec events instead of checking whether
3121 multiprocess is enabled.
3123 2015-09-15 Pedro Alves <palves@redhat.com>
3126 * remote-utils.c (prepare_resume_reply): Merge
3127 TARGET_WAITKIND_VFORK_DONE switch case with the
3128 TARGET_WAITKIND_FORKED case.
3130 2015-09-15 Yao Qi <yao.qi@linaro.org>
3132 * server.c (handle_query): Check string comparison using
3133 "else if" instead of "if".
3135 2015-09-15 Yao Qi <yao.qi@linaro.org>
3137 * server.c (vCont_supported): New global variable.
3138 (handle_query): Set vCont_supported to 1 if "vContSupported+"
3139 matches. Append ";vContSupported+" to own_buf.
3140 (handle_v_requests): Append ";s;S" to own_buf if target supports
3141 hardware single step or vCont_supported is false.
3142 (capture_main): Set vCont_supported to zero.
3144 2015-09-15 Yao Qi <yao.qi@linaro.org>
3146 * linux-low.c (linux_supports_conditional_breakpoints): Rename
3148 (linux_supports_hardware_single_step): ... New function.
3149 (linux_target_ops): Update.
3150 * lynx-low.c (lynx_target_ops): Set field
3151 supports_hardware_single_step to target_can_do_hardware_single_step.
3152 * nto-low.c (nto_target_ops): Likewise.
3153 * spu-low.c (spu_target_ops): Likewise.
3154 * win32-low.c (win32_target_ops): Likewise.
3155 * target.c (target_can_do_hardware_single_step): New function.
3156 * target.h (struct target_ops) <supports_conditional_breakpoints>:
3157 Remove. <supports_hardware_single_step>: New field.
3158 (target_supports_conditional_breakpoints): Remove.
3159 (target_supports_hardware_single_step): New macro.
3160 (target_can_do_hardware_single_step): Declare.
3161 * server.c (handle_query): Use target_supports_hardware_single_step
3162 instead of target_supports_conditional_breakpoints.
3164 2015-09-15 Yao Qi <yao.qi@linaro.org>
3166 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): New
3168 (struct linux_target_ops the_low_target): Install
3169 aarch64_linux_siginfo_fixup.
3171 2015-09-11 Don Breazeal <donb@codesourcery.com>
3172 Luis Machado <lgustavo@codesourcery.com>
3174 * linux-low.c (linux_mourn): Static declaration.
3175 (linux_arch_setup): Move in front of
3176 handle_extended_wait.
3177 (linux_arch_setup_thread): New function.
3178 (handle_extended_wait): Handle exec events. Call
3179 linux_arch_setup_thread. Make event_lwp argument a
3180 pointer-to-a-pointer.
3181 (check_zombie_leaders): Do not check stopped threads.
3182 (linux_low_ptrace_options): Add PTRACE_O_TRACEEXEC.
3183 (linux_low_filter_event): Add lwp and thread for exec'ing
3184 non-leader thread if leader thread has been deleted.
3185 Refactor code into linux_arch_setup_thread and call it.
3186 Pass child lwp pointer by reference to handle_extended_wait.
3187 (linux_wait_for_event_filtered): Update comment.
3188 (linux_wait_1): Prevent clobbering exec event status.
3189 (linux_supports_exec_events): New function.
3190 (linux_target_ops) <supports_exec_events>: Initialize new member.
3191 * lynx-low.c (lynx_target_ops) <supports_exec_events>: Initialize
3193 * remote-utils.c (prepare_resume_reply): New stop reason 'exec'.
3194 * server.c (report_exec_events): New global variable.
3195 (handle_query): Handle qSupported query for exec-events feature.
3196 (captured_main): Initialize report_exec_events.
3197 * server.h (report_exec_events): Declare new global variable.
3198 * target.h (struct target_ops) <supports_exec_events>: New
3200 (target_supports_exec_events): New macro.
3201 * win32-low.c (win32_target_ops) <supports_exec_events>:
3202 Initialize new member.
3204 2015-09-09 Markus Metzger <markus.t.metzger@intel.com>
3206 * linux-low.c (linux_low_enable_btrace): Remove.
3207 (linux_target_ops): Replace linux_low_enable_btrace with
3208 linux_enable_btrace.
3210 2015-09-03 Yao Qi <yao.qi@linaro.org>
3212 * linux-aarch64-low.c (aarch64_insert_point): Call
3213 aarch64_handle_watchpoint if aarch64_linux_region_ok_for_watchpoint
3216 2015-08-27 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
3218 * linux-low.c (check_stopped_by_breakpoint): Use
3219 GDB_ARCH_IS_TRAP_BRKPT instead of GDB_ARCH_TRAP_BRKPT.
3221 2015-08-27 Pedro Alves <palves@redhat.com>
3223 * proc-service.c (ps_pdwrite): Return PS_ERR/PS_OK explicily.
3225 2015-08-26 Simon Marchi <simon.marchi@ericsson.com>
3227 * ax.c (gdb_parse_agent_expr): Replace xmalloc-family function with
3228 the XNEW-family equivalent.
3229 (compile_bytecodes): Likewise.
3230 * dll.c (loaded_dll): Likewise.
3231 * event-loop.c (append_callback_event): Likewise.
3232 (create_file_handler): Likewise.
3233 (create_file_event): Likewise.
3234 * hostio.c (handle_open): Likewise.
3235 * inferiors.c (add_thread): Likewise.
3236 (add_process): Likewise.
3237 * linux-aarch64-low.c (aarch64_linux_new_process): Likewise.
3238 * linux-arm-low.c (arm_new_process): Likewise.
3239 (arm_new_thread): Likewise.
3240 * linux-low.c (add_to_pid_list): Likewise.
3241 (linux_add_process): Likewise.
3242 (handle_extended_wait): Likewise.
3243 (add_lwp): Likewise.
3244 (enqueue_one_deferred_signal): Likewise.
3245 (enqueue_pending_signal): Likewise.
3246 (linux_resume_one_lwp_throw): Likewise.
3247 (linux_resume_one_thread): Likewise.
3248 (linux_read_memory): Likewise.
3249 (linux_write_memory): Likewise.
3250 * linux-mips-low.c (mips_linux_new_process): Likewise.
3251 (mips_linux_new_thread): Likewise.
3252 (mips_add_watchpoint): Likewise.
3253 * linux-x86-low.c (initialize_low_arch): Likewise.
3254 * lynx-low.c (lynx_add_process): Likewise.
3255 * mem-break.c (set_raw_breakpoint_at): Likewise.
3256 (set_breakpoint): Likewise.
3257 (add_condition_to_breakpoint): Likewise.
3258 (add_commands_to_breakpoint): Likewise.
3259 (clone_agent_expr): Likewise.
3260 (clone_one_breakpoint): Likewise.
3261 * regcache.c (new_register_cache): Likewise.
3262 * remote-utils.c (look_up_one_symbol): Likewise.
3263 * server.c (queue_stop_reply): Likewise.
3264 (start_inferior): Likewise.
3265 (queue_stop_reply_callback): Likewise.
3266 (handle_target_event): Likewise.
3267 * spu-low.c (fetch_ppc_memory): Likewise.
3268 (store_ppc_memory): Likewise.
3269 * target.c (set_target_ops): Likewise.
3270 * thread-db.c (thread_db_load_search): Likewise.
3271 (try_thread_db_load_1): Likewise.
3272 * tracepoint.c (add_tracepoint): Likewise.
3273 (add_tracepoint_action): Likewise.
3274 (create_trace_state_variable): Likewise.
3275 (cmd_qtdpsrc): Likewise.
3276 (cmd_qtro): Likewise.
3277 (add_while_stepping_state): Likewise.
3278 * win32-low.c (child_add_thread): Likewise.
3279 (get_image_name): Likewise.
3281 2015-08-25 Yao Qi <yao.qi@linaro.org>
3283 * linux-aarch64-low.c (aarch64_linux_new_thread): Remove.
3285 2015-08-25 Yao Qi <yao.qi@linaro.org>
3287 * Makefile.in (aarch64-linux.o): New rule.
3288 * configure.srv (aarch64*-*-linux*): Append aarch64-linux.o to
3290 * linux-aarch64-low.c: Include nat/aarch64-linux.h.
3291 (aarch64_init_debug_reg_state): Make it extern.
3292 (aarch64_linux_prepare_to_resume): Remove.
3294 2015-08-25 Yao Qi <yao.qi@linaro.org>
3296 * linux-aarch64-low.c (aarch64_linux_prepare_to_resume): Use
3297 lwp_arch_private_info and ptid_of_lwp.
3299 2015-08-25 Yao Qi <yao.qi@linaro.org>
3301 * linux-aarch64-low.c (aarch64_get_debug_reg_state): Add argument pid.
3302 Find proc_info by find_process_pid. All callers updated.
3304 2015-08-25 Yao Qi <yao.qi@linaro.org>
3306 * linux-aarch64-low.c (struct arch64_dr_update_callback_param):
3308 (debug_reg_change_callback): Remove.
3309 (aarch64_notify_debug_reg_change): Remove.
3311 2015-08-25 Yao Qi <yao.qi@linaro.org>
3313 * linux-aarch64-low.c (aarch64_notify_debug_reg_change):
3314 Call current_lwp_ptid.
3316 2015-08-25 Yao Qi <yao.qi@linaro.org>
3318 * linux-aarch64-low.c (debug_reg_change_callback): Use
3321 2015-08-25 Yao Qi <yao.qi@linaro.org>
3323 * linux-aarch64-low.c (debug_reg_change_callback): Use phex.
3325 2015-08-25 Yao Qi <yao.qi@linaro.org>
3327 * linux-aarch64-low.c (debug_reg_change_callback): Remove comments.
3329 2015-08-25 Yao Qi <yao.qi@linaro.org>
3331 * linux-aarch64-low.c (debug_reg_change_callback): Re-indent
3334 2015-08-25 Yao Qi <yao.qi@linaro.org>
3336 * linux-aarch64-low.c (aarch64_dr_update_callback_param) <pid>:
3338 (debug_reg_change_callback): Remove argument entry and add argument
3339 lwp. Remove local variable thread. Don't print thread id in the
3340 debugging output. Don't check whether pid of thread equals to pid.
3341 (aarch64_notify_debug_reg_change): Don't set param.pid. Call
3342 iterate_over_lwps instead find_inferior.
3344 2015-08-24 Pedro Alves <palves@redhat.com>
3346 * inferiors.c (get_first_process): New function.
3347 * inferiors.h (get_first_process): New declaration.
3348 * remote-utils.c (read_ptid): Default to the first process in the
3349 list, instead of to the current thread's process.
3351 2015-08-24 Pedro Alves <palves@redhat.com>
3353 * debug.c: Include gdb_sys_time.h instead of sys/time.h.
3354 * event-loop.c: Likewise.
3355 * remote-utils.c: Likewise.
3356 * tracepoint.c: Likewise.
3358 2015-08-24 Pedro Alves <palves@redhat.com>
3360 * spu-low.c (spu_request_interrupt): Use lwpid_of instead of
3363 2015-08-21 Pedro Alves <palves@redhat.com>
3365 * ax.c (gdb_eval_agent_expr): Return expr_eval_unhandled_opcode
3366 instead of literal 1.
3368 2015-08-21 Pedro Alves <palves@redhat.com>
3370 * tdesc.c (default_description): Explicitly zero-initialize.
3372 2015-08-21 Pedro Alves <palves@redhat.com>
3375 * inferiors.c (remove_thread): Discard any pending stop reply for
3377 * server.c (remove_all_on_match_pid): Rename to ...
3378 (remove_all_on_match_ptid): ... this. Work with a filter ptid
3380 (discard_queued_stop_replies): Change parameter to a ptid. Now
3382 (handle_v_kill, kill_inferior_callback, captured_main)
3383 (process_serial_event): Adjust.
3384 * server.h (discard_queued_stop_replies): Declare.
3386 2015-08-21 Pedro Alves <palves@redhat.com>
3388 * linux-low.c (wait_for_sigstop): Always switch to no thread
3389 selected if the previously current thread dies.
3390 * lynx-low.c (lynx_request_interrupt): Use the first thread's
3391 process instead of the current thread's.
3392 * remote-utils.c (input_interrupt): Don't check if there's no
3394 * server.c (gdb_read_memory, gdb_write_memory): If setting the
3395 current thread to the general thread fails, error out.
3396 (handle_qxfer_auxv, handle_qxfer_libraries)
3397 (handle_qxfer_libraries_svr4, handle_qxfer_siginfo)
3398 (handle_qxfer_spu, handle_qxfer_statictrace, handle_qxfer_fdpic)
3399 (handle_query): Check if there's a thread selected instead of
3400 checking whether there's any thread in the thread list.
3401 (handle_qxfer_threads, handle_qxfer_btrace)
3402 (handle_qxfer_btrace_conf): Don't error out early if there's no
3403 thread in the thread list.
3404 (handle_v_cont, myresume): Don't set the current thread to the
3406 (process_serial_event) <Hg handling>: Also set thread_id if the
3407 previous general thread is still alive.
3408 (process_serial_event) <g/G handling>: If setting the current
3409 thread to the general thread fails, error out.
3410 * spu-low.c (spu_resume, spu_request_interrupt): Use the first
3411 thread's lwp instead of the current thread's.
3412 * target.c (set_desired_thread): If the desired thread was not
3413 found, leave the current thread pointing to NULL. Return an int
3414 (boolean) indicating success.
3415 * target.h (set_desired_thread): Change return type to int.
3417 2015-08-20 Max Filippov <jcmvbkbc@gmail.com>
3419 * configure.srv (xtensa*-*-linux*): Add srv_linux_thread_db=yes.
3420 * linux-xtensa-low.c (arch/xtensa.h gdb_proc_service.h): New
3422 (ps_get_thread_area): New function.
3424 2015-08-19 Gary Benson <gbenson@redhat.com>
3426 * hostio.c (handle_pread): Do not attempt to read more data
3427 than hostio_reply_with_data can fit in a packet.
3429 2015-08-18 Joel Brobecker <brobecker@adacore.com>
3431 * linux-aarch32-low.c (NT_ARM_VFP): Define if not already defined.
3433 2015-08-14 Matthew Fortune <matthew.fortune@imgtec.com>
3435 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP_REL.
3437 2015-08-06 Pedro Alves <palves@redhat.com>
3439 * tracepoint.c (expr_eval_result): Now an int.
3441 2015-08-06 Pedro Alves <palves@redhat.com>
3443 * gdbthread.h (struct regcache): Forward declare.
3444 (struct thread_info) <regcache_data>: Now a struct regcache
3446 * inferiors.c (inferior_regcache_data)
3447 (set_inferior_regcache_data): Now work with struct regcache
3449 * inferiors.h (struct regcache): Forward declare.
3450 (inferior_regcache_data, set_inferior_regcache_data): Now work
3451 with struct regcache pointers.
3452 * regcache.c (get_thread_regcache, regcache_invalidate_thread)
3453 (free_register_cache_thread): Remove struct regcache pointer
3456 2015-08-06 Pedro Alves <palves@redhat.com>
3458 * server.c (captured_main): On error, print the exception message
3459 to stderr, and if run_once is set, throw a quit.
3461 2015-08-06 Pedro Alves <palves@redhat.com>
3463 * linux-low.c (move_out_of_jump_pad_callback): Temporarily switch
3466 2015-08-06 Pedro Alves <palves@redhat.com>
3468 * linux-low.c (linux_write_memory): Rewrite debug output to avoid
3469 reading beyond the passed in buffer length.
3471 2015-08-06 Pierre Langlois <pierre.langlois@arm.com>
3473 * tracepoint.c (symbol_list) <required>: Remove.
3475 2015-08-06 Pedro Alves <palves@redhat.com>
3477 * linux-low.c (handle_extended_wait): Set the fork child's suspend
3478 count if stopping and suspending threads.
3479 (check_stopped_by_breakpoint): If stopped by trace, set the LWP's
3480 stop reason to TARGET_STOPPED_BY_SINGLE_STEP.
3481 (linux_detach): Complete an ongoing step-over.
3482 (lwp_suspended_inc, lwp_suspended_decr): New functions. Use
3484 (resume_stopped_resumed_lwps): Don't resume a suspended thread.
3485 (linux_wait_1): If passing a signal to the inferior after
3486 finishing a step-over, unsuspend and re-resume all lwps. If we
3487 see a single-step event but the thread should be continuing, don't
3488 pass the trap to gdb.
3489 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback): Use
3490 internal_error instead of gdb_assert.
3491 (enqueue_pending_signal): New function.
3492 (check_ptrace_stopped_lwp_gone): Add debug output.
3493 (start_step_over): Use internal_error instead of gdb_assert.
3494 (complete_ongoing_step_over): New function.
3495 (linux_resume_one_thread): Don't resume a suspended thread.
3496 (proceed_one_lwp): If the LWP is stepping over a breakpoint, reset
3499 2015-08-06 Pedro Alves <palves@redhat.com>
3501 * linux-low.c (add_lwp): Set waitstatus to TARGET_WAITKIND_IGNORE.
3502 (linux_thread_alive): Use lwp_is_marked_dead.
3503 (extended_event_reported): Delete.
3504 (linux_wait_1): Check if waitstatus is TARGET_WAITKIND_IGNORE
3505 instead of extended_event_reported.
3506 (mark_lwp_dead): Don't set the 'dead' flag. Store the waitstatus
3508 (lwp_is_marked_dead): New function.
3509 (lwp_running): Use lwp_is_marked_dead.
3510 * linux-low.h: Delete 'dead' field, and update 'waitstatus's
3513 2015-08-06 Pedro Alves <palves@redhat.com>
3515 * linux-low.c (linux_wait_1): Move fork event output out of the
3516 !report_to_gdb check. Pass event_child->waitstatus to
3517 target_waitstatus_to_string instead of ourstatus.
3519 2015-08-04 Yao Qi <yao.qi@linaro.org>
3521 * linux-aarch64-low.c (aarch64_supports_tracepoints): Return 0
3522 if current_thread is 32 bit.
3524 2015-08-04 Yao Qi <yao.qi@linaro.org>
3526 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
3527 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
3528 * server.c (extended_protocol): Remove "static".
3529 * server.h (extended_protocol): Declare it.
3531 2015-08-04 Yao Qi <yao.qi@linaro.org>
3533 * linux-aarch64-low.c (aarch64_get_pc): Get PC register on
3534 both aarch64 and aarch32.
3535 (aarch64_set_pc): Likewise.
3537 2015-08-04 Yao Qi <yao.qi@linaro.org>
3539 * configure.srv (case aarch64*-*-linux*): Append arm-with-neon.o
3540 to srv_regobj and append arm-core.xml arm-vfpv3.xml and
3541 arm-with-neon.xml to srv_xmlfiles.
3542 * linux-aarch64-low.c: Include linux-aarch32-low.h.
3543 (is_64bit_tdesc): New function.
3544 (aarch64_linux_read_description): New function.
3545 (aarch64_arch_setup): Call aarch64_linux_read_description.
3546 (regs_info): Rename to regs_info_aarch64.
3547 (aarch64_regs_info): Return right regs_info.
3548 (initialize_low_arch): Call initialize_low_arch_aarch32.
3550 2015-08-04 Yao Qi <yao.qi@linaro.org>
3552 * configure.srv (srv_tgtobj): Add linux-aarch32-low.o.
3553 * linux-aarch32-low.c: New file.
3554 * linux-aarch32-low.h: New file.
3555 * linux-arm-low.c (arm_fill_gregset): Move it to
3556 linux-aarch32-low.c.
3557 (arm_store_gregset): Likewise.
3558 (arm_fill_vfpregset): Call arm_fill_vfpregset_num
3559 (arm_store_vfpregset): Call arm_store_vfpregset_num.
3560 (arm_arch_setup): Check if PTRACE_GETREGSET works.
3561 (regs_info): Rename to regs_info_arm.
3562 (arm_regs_info): Return regs_info_aarch32 if
3563 have_ptrace_getregset is 1 and target description is
3564 arm_with_neon or arm_with_vfpv3.
3565 (initialize_low_arch): Don't call init_registers_arm_with_neon.
3566 Call initialize_low_arch_aarch32 instead.
3568 2015-08-04 Yao Qi <yao.qi@linaro.org>
3570 * linux-x86-low.c (have_ptrace_getregset): Move it to ...
3571 * linux-low.c: ... here.
3572 * linux-low.h (have_ptrace_getregset): Declare it.
3574 2015-08-04 Pedro Alves <palves@redhat.com>
3576 * thread-db.c (struct thread_db): Use new typedefs.
3577 (try_thread_db_load_1): Define local TDB_DLSYM macro and use it in
3579 (disable_thread_event_reporting): Cast result of dlsym to
3580 destination function pointer type.
3581 (thread_db_mourn): Use td_ta_delete_ftype.
3583 2015-08-03 Sandra Loosemore <sandra@codesourcery.com>
3585 * linux-nios2-low.c (NIOS2_BREAKPOINT): Conditionalize for
3587 (CDX_BREAKPOINT): Define for R2.
3588 (nios2_breakpoint_at): Check for CDX_BREAKPOINT when R2.
3589 (the_low_target): Add comments.
3591 2015-07-30 Yao Qi <yao.qi@linaro.org>
3593 * linux-arm-low.c (arm_hwcap): Remove it.
3594 (arm_read_description): New local variable arm_hwcap. Don't
3595 set arm_hwcap to zero.
3597 2015-07-30 Yao Qi <yao.qi@linaro.org>
3599 * linux-arm-low.c (arm_fill_wmmxregset): Don't use arm_hwcap.
3600 Use regcache->tdesc instead.
3601 (arm_store_wmmxregset): Likewise.
3602 (arm_fill_vfpregset): Likewise.
3603 (arm_store_vfpregset): Likewise.
3605 2015-07-30 Yao Qi <yao.qi@linaro.org>
3607 * linux-arm-low.c: Include arch/arm.h.
3608 (arm_fill_gregset): Don't use arm_num_regs and arm_regmap.
3609 (arm_store_gregset): Likewise.
3611 2015-07-29 Simon Marchi <simon.marchi@ericsson.com>
3613 * linux-mips-low.c (mips_linux_prepare_to_resume): Add NULL as
3614 ptrace's 4th parameter.
3616 2015-07-27 Yao Qi <yao.qi@linaro.org>
3618 * configure.srv (case aarch64*-*-linux*): Don't set
3621 2015-07-24 Pedro Alves <palves@redhat.c: Likewise.om>
3623 * linux-aarch64-low.c: Include nat/gdb_ptrace.h instead of
3625 * linux-arm-low.c: Likewise.
3626 * linux-cris-low.c: Likewise.
3627 * linux-crisv32-low.c: Likewise.
3628 * linux-low.c: Likewise.
3629 * linux-m68k-low.c: Likewise.
3630 * linux-mips-low.c: Likewise.
3631 * linux-nios2-low.c: Likewise.
3632 * linux-s390-low.c: Likewise.
3633 * linux-sparc-low.c: Likewise.
3634 * linux-tic6x-low.c: Likewise.
3635 * linux-tile-low.c: Likewise.
3636 * linux-x86-low.c: Likewise.
3638 2015-07-24 Pedro Alves <palves@redhat.com>
3640 * config.in: Regenerate.
3641 * configure: Regenerate.
3643 2015-07-24 Pedro Alves <palves@redhat.com>
3645 * acinclude.m4: Include ../ptrace.m4.
3646 * configure.ac: Call GDB_AC_PTRACE.
3647 * config.in, configure: Regenerate.
3649 2015-07-24 Yao Qi <yao.qi@linaro.org>
3651 * linux-low.c (linux_create_inferior): Remove setting to
3652 proc->priv->new_inferior.
3653 (linux_attach): Likewise.
3654 (linux_low_filter_event): Likewise.
3655 * linux-low.h (struct process_info_private) <new_inferior>: Remove.
3657 2015-07-24 Yao Qi <yao.qi@linaro.org>
3659 * linux-low.c (linux_arch_setup): New function.
3660 (linux_low_filter_event): If proc->tdesc is NULL and
3661 proc->attached is true, call the_low_target.arch_setup.
3662 Otherwise, keep status pending, and return.
3663 (linux_resume_one_lwp_throw): Don't call get_pc if
3664 thread->while_stepping isn't NULL. Don't call
3665 get_thread_regcache if proc->tdesc is NULL.
3666 (need_step_over_p): Return 0 if proc->tdesc is NULL.
3667 (linux_target_ops): Install arch_setup.
3668 * server.c (start_inferior): Call the_target->arch_setup.
3669 * target.h (struct target_ops) <arch_setup>: New field.
3670 (target_arch_setup): New marco.
3671 * lynx-low.c (lynx_target_ops): Update.
3672 * nto-low.c (nto_target_ops): Update.
3673 * spu-low.c (spu_target_ops): Update.
3674 * win32-low.c (win32_target_ops): Update.
3676 2015-07-24 Yao Qi <yao.qi@linaro.org>
3678 * linux-low.c (linux_add_process): Don't set
3679 proc->priv->new_inferior.
3680 (linux_create_inferior): Set proc->priv->new_inferior to 1.
3681 (linux_attach): Likewise.
3683 2015-07-24 Yao Qi <yao.qi@linaro.org>
3685 * server.c (start_inferior): Code refactor.
3687 2015-07-24 Yao Qi <yao.qi@linaro.org>
3689 * server.c (process_serial_event): Set general_thread.
3691 2015-07-21 Yao Qi <yao.qi@linaro.org>
3693 * linux-aarch64-low.c (aarch64_arch_setup): Remove code and call
3694 aarch64_linux_get_debug_reg_capacity.
3696 2015-07-17 Yao Qi <yao.qi@linaro.org>
3698 * Makefile.in (aarch64-linux-hw-point.o): New rule.
3699 * configure.srv (srv_tgtobj): Append aarch64-linux-hw-point.o.
3700 * linux-aarch64-low.c: Include nat/aarch64-linux-hw-point.h.
3701 (AARCH64_HBP_MAX_NUM): Move to nat/aarch64-linux-hw-point.h.
3702 (AARCH64_HWP_MAX_NUM, AARCH64_HBP_ALIGNMENT): Likewise.
3703 (AARCH64_HWP_ALIGNMENT): Likewise.
3704 (AARCH64_HWP_MAX_LEN_PER_REG): Likewise.
3705 (AARCH64_DEBUG_NUM_SLOTS, AARCH64_DEBUG_ARCH): Likewise.
3706 (aarch64_num_bp_regs, aarch64_num_wp_regs): Likewise.
3707 (AARCH64_DEBUG_ARCH_V8, DR_MARK_ALL_CHANGED): Likewise.
3708 (DR_MARK_N_CHANGED, DR_CLEAR_CHANGED): Likewise.
3709 (DR_HAS_CHANGED, DR_N_HAS_CHANGE): Likewise.
3710 (struct aarch64_debug_reg_state): Likewise.
3711 (struct arch_lwp_info): Likewise.
3712 (aarch64_align_watchpoint): Likewise.
3713 (DR_CONTROL_ENABLED, DR_CONTROL_LENGTH): Likewise.
3714 (aarch64_watchpoint_length): Likewise.
3715 (aarch64_point_encode_ctrl_reg): Likewise
3716 (aarch64_point_is_aligned): Likewise.
3717 (aarch64_align_watchpoint): Likewise.
3718 (aarch64_linux_set_debug_regs):
3719 (aarch64_dr_state_insert_one_point): Likewise.
3720 (aarch64_dr_state_remove_one_point): Likewise.
3721 (aarch64_handle_breakpoint): Likewise.
3722 (aarch64_handle_aligned_watchpoint): Likewise.
3723 (aarch64_handle_unaligned_watchpoint): Likewise.
3724 (aarch64_handle_watchpoint): Likewise.
3726 2015-07-17 Yao Qi <yao.qi@linaro.org>
3728 * linux-aarch64-low.c (aarch64_handle_breakpoint): Add argument state
3729 and don't aarch64_get_debug_reg_state. All callers update.
3730 (aarch64_handle_aligned_watchpoint): Likewise.
3731 (aarch64_handle_unaligned_watchpoint): Likewise.
3732 (aarch64_handle_watchpoint): Likewise.
3733 (aarch64_insert_point): Call aarch64_get_debug_reg_state earlier.
3734 (aarch64_remove_point): Likewise.
3736 2015-07-17 Yao Qi <yao.qi@linaro.org>
3738 * linux-aarch64-low.c (aarch64_show_debug_reg_state): Use
3740 (aarch64_handle_unaligned_watchpoint): Likewise.
3742 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
3744 Revert the previous 3 commits:
3745 Move gdb_regex* to common/
3746 Move linux_find_memory_regions_full & co.
3747 gdbserver build-id attribute generator
3749 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
3750 Jan Kratochvil <jan.kratochvil@redhat.com>
3752 gdbserver build-id attribute generator.
3753 * linux-low.c (nat/linux-maps.h, search.h, rsp-low.h): Include.
3754 (ElfXX_Ehdr, ElfXX_Phdr, ElfXX_Nhdr): New.
3755 (ELFXX_FLD, ELFXX_SIZEOF, ELFXX_ROUNDUP, BUILD_ID_INVALID): New.
3757 (get_dynamic): Use find_pdhr to traverse program headers.
3758 (struct mapping_entry, mapping_entry_s, free_mapping_entry_vec)
3759 (compare_mapping_entry_range, struct find_memory_region_callback_data)
3760 (read_build_id, find_memory_region_callback, lrfind_mapping_entry)
3761 (get_hex_build_id): New.
3762 (linux_qxfer_libraries_svr4): Add optional build-id attribute
3763 to reply XML document.
3765 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
3766 Jan Kratochvil <jan.kratochvil@redhat.com>
3768 * target.c: Include target/target-utils.h and fcntl.h.
3769 (target_fileio_read_stralloc_1_pread, target_fileio_read_stralloc_1)
3770 (target_fileio_read_stralloc): New functions.
3772 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
3774 * Makefile.in (OBS): Add gdb_regex.o.
3776 * config.in: Rebuilt.
3777 * configure: Rebuilt.
3779 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
3780 Jan Kratochvil <jan.kratochvil@redhat.com>
3782 Create empty nat/linux-maps.[ch] and common/target-utils.[ch].
3783 * Makefile.in (OBS): Add target-utils.o.
3784 (linux-maps.o, target-utils.o): New.
3785 * configure.srv (srv_linux_obj): Add linux-maps.o.
3787 2015-07-15 Pierre Langlois <pierre.langlois@arm.com>
3789 * linux-aarch64-low.c (aarch64_supports_range_stepping): New
3791 (the_low_target): Install it.
3793 2015-07-14 Pedro Alves <palves@redhat.com>
3795 * linux-low.c (kill_wait_lwp): Don't assert if waitpid fails.
3796 Instead, ignore ECHILD, and throw an error for other errnos.
3798 2015-07-10 Pedro Alves <palves@redhat.com>
3800 * event-loop.c (struct callback_event) <data>: Change type to
3801 gdb_client_data instance instead of gdb_client_data pointer.
3802 (append_callback_event): Adjust.
3804 2015-07-10 Pierre Langlois <pierre.langlois@arm.com>
3806 * linux-aarch64-low.c: Add comments for each linux_target_ops
3807 method. Remove comments already covered in target_ops and
3808 linux_target_ops definitions.
3809 (the_low_target): Add comments for each unimplemented method.
3811 2015-07-09 Yao Qi <yao.qi@linaro.org>
3813 * linux-aarch64-low.c (aarch64_regmap): Remove.
3814 (aarch64_usrregs_info): Remove.
3815 (regs_info): Set field usrregs to NULL.
3817 2015-07-02 Markus Metzger <markus.t.metzger@intel.com>
3819 * linux-low.c: Include "rsp-low.h"
3820 (linux_low_encode_pt_config, linux_low_encode_raw): New.
3821 (linux_low_read_btrace): Support BTRACE_FORMAT_PT.
3822 (linux_low_btrace_conf): Support BTRACE_FORMAT_PT.
3823 (handle_btrace_enable_pt): New.
3824 (handle_btrace_general_set): Support "pt".
3825 (handle_btrace_conf_general_set): Support "pt:size".
3827 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
3829 * linux-aarch64-low.c (aarch64_supports_z_point_type): Enable for
3832 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
3834 * linux-aarch64-low.c: Remove comment about endianness.
3835 (aarch64_breakpoint): Change type to gdb_byte[]. Set to "brk #0".
3836 (aarch64_breakpoint_at): Change type of insn to gdb_byte[]. Use
3839 2015-06-24 Gary Benson <gbenson@redhat.com>
3841 * linux-i386-ipa.c (stdint.h): Do not include.
3842 * lynx-i386-low.c (stdint.h): Likewise.
3843 * lynx-ppc-low.c (stdint.h): Likewise.
3844 * mem-break.c (stdint.h): Likewise.
3845 * thread-db.c (stdint.h): Likewise.
3846 * tracepoint.c (stdint.h): Likewise.
3847 * win32-low.c (stdint.h): Likewise.
3849 2015-06-18 Simon Marchi <simon.marchi@ericsson.com>
3851 * server.c (write_qxfer_response): Update call to
3852 remote_escape_output.
3854 2015-06-15 Aleksandar Ristovski <aristovski@qnx.com
3855 Jan Kratochvil <jan.kratochvil@redhat.com>
3857 Merge multiple hex conversions.
3858 * gdbreplay.c (tohex): Rename to 'fromhex'.
3859 (logchar): Use fromhex.
3861 2015-06-10 Jan Kratochvil <jan.kratochvil@redhat.com>
3863 * server.c (handle_qxfer_libraries): Set `version' attribute for
3866 2015-06-10 Gary Benson <gbenson@redhat.com>
3868 * target.h (struct target_ops) <multifs_open>: New field.
3869 <multifs_unlink>: Likewise.
3870 <multifs_readlink>: Likewise.
3871 * linux-low.c (nat/linux-namespaces.h): New include.
3872 (linux_target_ops): Initialize the_target->multifs_open,
3873 the_target->multifs_unlink and the_target->multifs_readlink.
3874 * hostio.h (hostio_handle_new_gdb_connection): New declaration.
3875 * hostio.c (hostio_fs_pid): New static variable.
3876 (hostio_handle_new_gdb_connection): New function.
3877 (handle_setfs): Likewise.
3878 (handle_open): Use the_target->multifs_open as appropriate.
3879 (handle_unlink): Use the_target->multifs_unlink as appropriate.
3880 (handle_readlink): Use the_target->multifs_readlink as
3882 (handle_vFile): Handle vFile:setfs packets.
3883 * server.c (handle_query): Call hostio_handle_new_gdb_connection
3884 after target_handle_new_gdb_connection.
3886 2015-06-10 Gary Benson <gbenson@redhat.com>
3888 * configure.ac (AC_CHECK_FUNCS): Add setns.
3889 * config.in: Regenerate.
3890 * configure: Likewise.
3891 * Makefile.in (SFILES): Add nat/linux-namespaces.c.
3892 (linux-namespaces.o): New rule.
3893 * configure.srv (srv_linux_obj): Add linux-namespaces.o.
3895 2015-06-09 Gary Benson <gbenson@redhat.com>
3897 * hostio.c (handle_open): Process mode argument with
3898 fileio_to_host_mode.
3900 2015-06-01 Yao Qi <yao.qi@linaro.org>
3902 * linux-s390-low.c (PTRACE_GETREGSET, PTRACE_SETREGSET): Remove.
3903 * linux-x86-low.c: Likewise.
3905 2015-05-28 Don Breazeal <donb@codesourcery.com>
3907 * linux-low.c (handle_extended_wait): Initialize
3908 thread_info.last_resume_kind for new fork children.
3910 2015-05-15 Pedro Alves <palves@redhat.com>
3912 * target.h (target_handle_new_gdb_connection): Rewrite using if
3913 wrapped in do/while.
3915 2015-05-14 Joel Brobecker <brobecker@adacore.com>
3917 * configure.ac: Add prfpregset_t BFD_HAVE_SYS_PROCFS_TYPE check.
3918 * configure, config.in: Regenerate.
3919 * gdb_proc_service.h [HAVE_PRFPREGSET_T] (prfpregset_t):
3922 2015-05-12 Don Breazeal <donb@codesourcery.com>
3924 * linux-low.c (handle_extended_wait): Handle PTRACE_EVENT_FORK and
3925 PTRACE_EVENT_VFORK_DONE.
3926 (linux_low_ptrace_options, extended_event_reported): Add vfork
3928 * remote-utils.c (prepare_resume_reply): New stop reasons "vfork"
3929 and "vforkdone" for RSP 'T' Stop Reply Packet.
3930 * server.h (report_vfork_events): Declare
3933 2015-05-12 Don Breazeal <donb@codesourcery.com>
3935 * linux-aarch64-low.c (aarch64_linux_new_fork): New function.
3936 (the_low_target) <new_fork>: Initialize new member.
3937 * linux-arm-low.c (arm_new_fork): New function.
3938 (the_low_target) <new_fork>: Initialize new member.
3939 * linux-low.c (handle_extended_wait): Call new target function
3941 * linux-low.h (struct linux_target_ops) <new_fork>: New member.
3942 * linux-mips-low.c (mips_add_watchpoint): New function
3943 extracted from mips_insert_point.
3944 (the_low_target) <new_fork>: Initialize new member.
3945 (mips_linux_new_fork): New function.
3946 (mips_insert_point): Call mips_add_watchpoint.
3947 * linux-x86-low.c (x86_linux_new_fork): New function.
3948 (the_low_target) <new_fork>: Initialize new member.
3950 2015-05-12 Don Breazeal <donb@codesourcery.com>
3952 * linux-low.c (handle_extended_wait): Implement return value,
3953 rename argument 'event_child' to 'event_lwp', handle
3954 PTRACE_EVENT_FORK, call internal_error for unrecognized event.
3955 (linux_low_ptrace_options): New function.
3956 (linux_low_filter_event): Call linux_low_ptrace_options,
3957 use different argument fo linux_enable_event_reporting,
3958 use return value from handle_extended_wait.
3959 (extended_event_reported): New function.
3960 (linux_wait_1): Call extended_event_reported and set
3961 status to report fork events.
3962 (linux_write_memory): Add pid to debug message.
3963 (reset_lwp_ptrace_options_callback): New function.
3964 (linux_handle_new_gdb_connection): New function.
3965 (linux_target_ops): Initialize new structure member.
3966 * linux-low.h (struct lwp_info) <waitstatus>: New member.
3967 * lynx-low.c: Initialize new structure member.
3968 * remote-utils.c (prepare_resume_reply): Implement stop reason
3969 "fork" for "T" stop message.
3970 * server.c (handle_query): Call handle_new_gdb_connection.
3971 * server.h (report_fork_events): Declare global flag.
3972 * target.h (struct target_ops) <handle_new_gdb_connection>:
3974 (target_handle_new_gdb_connection): New macro.
3975 * win32-low.c: Initialize new structure member.
3977 2015-05-12 Don Breazeal <donb@codesourcery.com>
3979 * mem-break.c (APPEND_TO_LIST): Define macro.
3980 (clone_agent_expr): New function.
3981 (clone_one_breakpoint): New function.
3982 (clone_all_breakpoints): New function.
3983 * mem-break.h: Declare new functions.
3985 2015-05-12 Don Breazeal <donb@codesourcery.com>
3987 * linux-low.c (linux_supports_fork_events): New function.
3988 (linux_supports_vfork_events): New function.
3989 (linux_target_ops): Initialize new structure members.
3990 (initialize_low): Call linux_check_ptrace_features.
3991 * lynx-low.c (lynx_target_ops): Initialize new structure
3993 * server.c (report_fork_events, report_vfork_events):
3995 (handle_query): Add new features to qSupported packet and
3997 (captured_main): Initialize new global variables.
3998 * target.h (struct target_ops) <supports_fork_events>:
4000 <supports_vfork_events>: New member.
4001 (target_supports_fork_events): New macro.
4002 (target_supports_vfork_events): New macro.
4003 * win32-low.c (win32_target_ops): Initialize new structure
4006 2015-05-12 Gary Benson <gbenson@redhat.com>
4008 * server.c (handle_qxfer_exec_file): Use current process
4011 2015-05-08 Sandra Loosemore <sandra@codesourcery.com>
4013 * linux-nios2-low.c: Include elf/common.h. Adjust comments.
4014 Remove HAVE_PTRACE_GETREGS conditionals.
4015 (nios2_regsets): Use PTRACE_GETREGSET and PTRACE_SETREGSET
4016 instead of PTRACE_GETREGS and PTRACE_SETREGS.
4018 2015-05-08 Yao Qi <yao.qi@linaro.org>
4020 * linux-low.c (linux_supports_conditional_breakpoints): New
4022 (linux_target_ops): Install new target method.
4023 * lynx-low.c (lynx_target_ops): Install NULL hook for
4024 supports_conditional_breakpoints.
4025 * nto-low.c (nto_target_ops): Likewise.
4026 * spu-low.c (spu_target_ops): Likewise.
4027 * win32-low.c (win32_target_ops): Likewise.
4028 * server.c (handle_query): Check
4029 target_supports_conditional_breakpoints.
4030 * target.h (struct target_ops) <supports_conditional_breakpoints>:
4032 (target_supports_conditional_breakpoints): New macro.
4034 2015-05-06 Pedro Alves <palves@redhat.com>
4037 * server.c (start_inferior): If the process exits, mourn it.
4039 2015-04-21 Gary Benson <gbenson@redhat.com>
4041 * hostio.c (fileio_open_flags_to_host): Factored out to
4042 fileio_to_host_openflags in common/fileio.c. Single use
4045 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
4047 * linux-xtensa-low.c (xtensa_fill_gregset)
4048 (xtensa_store_gregset): Check XCHAL_HAVE_LOOPS instead of
4051 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
4053 * linux-xtensa-low.c (xtensa_usrregs_info): Remove.
4054 (regs_info): Replace usrregs pointer with NULL.
4056 2015-04-17 Gary Benson <gbenson@redhat.com>
4058 * target.h (struct target_ops) <pid_to_exec_file>: New field.
4059 * linux-low.c (linux_target_ops): Initialize pid_to_exec_file.
4060 * server.c (handle_qxfer_exec_file): New function.
4061 (qxfer_packets): Add exec-file entry.
4062 (handle_query): Report qXfer:exec-file:read as supported packet.
4064 2015-04-14 Romain Naour <romain.naour@openwide.fr> (tiny change)
4066 * linux-low.c (linux_read_offsets): Remove get_thread_lwp.
4068 2015-04-09 Gary Benson <gbenson@redhat.com>
4070 * hostio-errno.c (errno_to_fileio_error): Remove function.
4071 Update caller to use remote_fileio_to_fio_error.
4073 2015-04-09 Yao Qi <yao.qi@linaro.org>
4075 * linux-low.c (linux_insert_point): Call
4076 insert_memory_breakpoint if TYPE is raw_bkpt_type_sw.
4077 (linux_remove_point): Call remove_memory_breakpoint if type is
4079 * linux-x86-low.c (x86_insert_point): Don't call
4080 insert_memory_breakpoint.
4081 (x86_remove_point): Don't call remove_memory_breakpoint.
4083 2015-04-01 Pedro Alves <palves@redhat.com>
4084 Cleber Rosa <crosa@redhat.com>
4086 * server.c (gdbserver_usage): Reorganize and extend the usage
4089 2015-03-24 Pedro Alves <palves@redhat.com>
4091 * linux-low.c (check_stopped_by_breakpoint): Tweak debug log
4092 output. Also dump TRAP_TRACE.
4093 (linux_low_filter_event): In debug output, distinguish a
4094 resume_stop SIGSTOP from a delayed SIGSTOP.
4096 2015-03-24 Gary Benson <gbenson@redhat.com>
4098 * linux-x86-low.c (x86_linux_new_thread): Moved to
4100 (x86_linux_prepare_to_resume): Likewise.
4102 2015-03-24 Gary Benson <gbenson@redhat.com>
4104 * Makefile.in (x86-linux-dregs.o): New rule.
4105 * configure.srv: Add x86-linux-dregs.o to relevant targets.
4106 * linux-x86-low.c: Include nat/x86-linux-dregs.h.
4107 (u_debugreg_offset): Moved to nat/x86-linux-dregs.c.
4108 (x86_linux_dr_get): Likewise.
4109 (x86_linux_dr_set): Likewise.
4110 (update_debug_registers_callback): Likewise.
4111 (x86_linux_dr_set_addr): Likewise.
4112 (x86_linux_dr_get_addr): Likewise.
4113 (x86_linux_dr_set_control): Likewise.
4114 (x86_linux_dr_get_control): Likewise.
4115 (x86_linux_dr_get_status): Likewise.
4116 (x86_linux_update_debug_registers): Likewise.
4118 2015-03-24 Gary Benson <gbenson@redhat.com>
4120 * linux-x86-low.c (x86_linux_update_debug_registers):
4121 New function, factored out from...
4122 (x86_linux_prepare_to_resume): ...this.
4124 2015-03-24 Gary Benson <gbenson@redhat.com>
4126 * linux-x86-low.c (x86_linux_dr_get): Update comments.
4127 (x86_linux_dr_set): Likewise.
4128 (update_debug_registers_callback): Likewise.
4129 (x86_linux_dr_set_addr): Likewise.
4130 (x86_linux_dr_get_addr): Likewise.
4131 (x86_linux_dr_set_control): Likewise.
4132 (x86_linux_dr_get_control): Likewise.
4133 (x86_linux_dr_get_status): Likewise.
4134 (x86_linux_prepare_to_resume): Likewise.
4136 2015-03-24 Gary Benson <gbenson@redhat.com>
4138 * linux-x86-low.c (x86_linux_dr_get): Add assertion.
4139 Use perror_with_name. Pass string through gettext.
4140 (x86_linux_dr_set): Likewise.
4142 2015-03-24 Gary Benson <gbenson@redhat.com>
4144 * linux-x86-low.c (x86_dr_low_set_addr): Rename to...
4145 (x86_linux_dr_set_addr): ...this.
4146 (x86_dr_low_get_addr): Rename to...
4147 (x86_linux_dr_get_addr): ...this.
4148 (x86_dr_low_set_control): Rename to...
4149 (x86_linux_dr_set_control): ...this.
4150 (x86_dr_low_get_control): Rename to...
4151 (x86_linux_dr_get_control): ...this.
4152 (x86_dr_low_get_status): Rename to...
4153 (x86_linux_dr_get_status): ...this.
4154 (x86_dr_low): Update with new function names.
4156 2015-03-24 Gary Benson <gbenson@redhat.com>
4158 * Makefile.in (x86-linux.o): New rule.
4159 * configure.srv: Add x86-linux.o to relevant targets.
4160 * linux-low.c (lwp_set_arch_private_info): New function.
4161 (lwp_arch_private_info): Likewise.
4162 * linux-x86-low.c: Include nat/x86-linux.h.
4163 (arch_lwp_info): Removed structure.
4164 (update_debug_registers_callback):
4165 Use lwp_set_debug_registers_changed.
4166 (x86_linux_prepare_to_resume): Use lwp_debug_registers_changed
4167 and lwp_set_debug_registers_changed.
4168 (x86_linux_new_thread): Use lwp_set_debug_registers_changed.
4170 2015-03-24 Gary Benson <gbenson@redhat.com>
4172 * linux-low.h (linux_target_ops) <new_thread>: Changed signature.
4173 * linux-arm-low.c (arm_new_thread): Likewise.
4174 * linux-aarch64-low.c (aarch64_linux_new_thread): Likewise.
4175 * linux-mips-low.c (mips_linux_new_thread): Likewise.
4176 * linux-x86-low.c (x86_linux_new_thread): Likewise.
4177 * linux-low.c (add_lwp): Update the_low_target.new_thread call.
4179 2015-03-24 Gary Benson <gbenson@redhat.com>
4181 * linux-low.c (ptid_of_lwp): New function.
4182 (lwp_is_stopped): Likewise.
4183 (lwp_stop_reason): Likewise.
4184 * linux-x86-low.c (update_debug_registers_callback):
4186 (x86_linux_prepare_to_resume): Use ptid_of_lwp and
4189 2015-03-24 Gary Benson <gbenson@redhat.com>
4191 * linux-low.h (linux_stop_lwp): Remove declaration.
4193 2015-03-24 Gary Benson <gbenson@redhat.com>
4195 * linux-low.h: Include nat/linux-nat.h.
4196 * linux-low.c (iterate_over_lwps_args): New structure.
4197 (iterate_over_lwps_filter): New function.
4198 (iterate_over_lwps): Likewise.
4199 * linux-x86-low.c (update_debug_registers_callback):
4200 Update signature to what iterate_over_lwps expects.
4201 Remove PID check that iterate_over_lwps now performs.
4202 (x86_dr_low_set_addr): Use iterate_over_lwps.
4203 (x86_dr_low_set_control): Likewise.
4205 2015-03-24 Gary Benson <gbenson@redhat.com>
4207 * linux-x86-low.c (x86_debug_reg_state): New function.
4208 (x86_linux_prepare_to_resume): Use the above.
4210 2015-03-24 Gary Benson <gbenson@redhat.com>
4212 * linux-low.c (current_lwp_ptid): New function.
4213 * linux-x86-low.c: Include nat/linux-nat.h.
4214 (x86_dr_low_get_addr): Use current_lwp_ptid.
4215 (x86_dr_low_get_control): Likewise.
4216 (x86_dr_low_get_status): Likewise.
4218 2015-03-20 Pedro Alves <palves@redhat.com>
4220 * tracepoint.c (cmd_qtstatus): Make "str" const.
4222 2015-03-20 Pedro Alves <palves@redhat.com>
4224 * server.c (handle_general_set): Make "req_str" const.
4226 2015-03-19 Pedro Alves <palves@redhat.com>
4228 * linux-low.c (linux_resume_one_lwp): Rename to ...
4229 (linux_resume_one_lwp_throw): ... this. Don't handle ESRCH here,
4230 instead call perror_with_name.
4231 (check_ptrace_stopped_lwp_gone): New function.
4232 (linux_resume_one_lwp): Reimplement as wrapper around
4233 linux_resume_one_lwp_throw that swallows errors if the LWP is
4236 2015-03-19 Pedro Alves <palves@redhat.com>
4238 * linux-low.c (count_events_callback, select_event_lwp_callback):
4239 No longer check whether the thread has resume_stop as last resume
4242 2015-03-19 Pedro Alves <palves@redhat.com>
4244 * linux-low.c (count_events_callback, select_event_lwp_callback):
4245 Use the lwp's status_pending_p field, not the thread's.
4247 2015-03-19 Pedro Alves <palves@redhat.com>
4249 * linux-low.c (select_event_lwp_callback): Update comments to
4250 no longer mention SIGTRAP.
4252 2015-03-18 Gary Benson <gbenson@redhat.com>
4254 * server.c (handle_query): Do not report vFile:fstat as supported.
4256 2015-03-11 Gary Benson <gbenson@redhat.com>
4258 * hostio.c (sys/types.h): New include.
4259 (sys/stat.h): Likewise.
4260 (common-remote-fileio.h): Likewise.
4261 (handle_fstat): New function.
4262 (handle_vFile): Handle vFile:fstat packets.
4264 2015-03-11 Gary Benson <gbenson@redhat.com>
4266 * configure.ac (AC_CHECK_MEMBERS): Add checks for
4267 struct stat.st_blocks and struct stat.st_blksize.
4268 * configure: Regenerate.
4269 * config.in: Likewise.
4270 * Makefile.in (SFILES): Add common/common-remote-fileio.c.
4271 (OBS): Add common-remote-fileio.o.
4272 (common-remote-fileio.o): New rule.
4274 2015-03-09 Pedro Alves <palves@redhat.com>
4276 * tracepoint.c (gdb_agent_helper_thread): Cast '&sockaddr' to
4277 'struct sockaddr' pointer in 'accept' call.
4279 2015-03-09 Pedro Alves <palves@redhat.com>
4282 2015-03-07 Pedro Alves <palves@redhat.com>
4283 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
4284 or <winsock2.h> here. Instead include "gdb_socket.h".
4285 (remote_open): Use union gdb_sockaddr_u.
4286 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
4287 or <winsock2.h> here. Instead include "gdb_socket.h".
4288 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
4289 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
4291 (init_named_socket, gdb_agent_helper_thread): Use union
4294 2015-03-07 Pedro Alves <palves@redhat.com>
4296 * configure.ac (build_warnings): Move
4297 -Wdeclaration-after-statement to the C-specific set.
4298 * configure: Regenerate.
4300 2015-03-07 Pedro Alves <palves@redhat.com>
4302 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
4303 or <winsock2.h> here. Instead include "gdb_socket.h".
4304 (remote_open): Use union gdb_sockaddr_u.
4305 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
4306 or <winsock2.h> here. Instead include "gdb_socket.h".
4307 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
4308 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
4310 (init_named_socket, gdb_agent_helper_thread): Use union
4313 2015-03-07 Pedro Alves <palves@redhat.com>
4315 Adjust all callers of TRY_CATCH to use TRY/CATCH/END_CATCH
4318 2015-03-06 Yao Qi <yao.qi@linaro.org>
4320 * linux-aarch64-low.c (aarch64_insert_point): Use
4321 show_debug_regs as a boolean.
4322 (aarch64_remove_point): Likewise.
4324 2015-03-05 Pedro Alves <palves@redhat.com>
4326 * lynx-low.c (lynx_target_ops): Install NULL hooks for
4327 stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
4328 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint.
4329 * nto-low.c (nto_target_ops): Likewise.
4330 * spu-low.c (spu_target_ops): Likewise.
4331 * win32-low.c (win32_target_ops): Likewise.
4333 2015-03-04 Pedro Alves <palves@redhat.com>
4335 * linux-low.c (check_stopped_by_breakpoint) [USE_SIGTRAP_SIGINFO]:
4336 Decide whether a breakpoint triggered based on the SIGTRAP's
4338 (thread_still_has_status_pending_p) [USE_SIGTRAP_SIGINFO]: Don't check whether a
4339 breakpoint is inserted if relying on SIGTRAP's siginfo.si_code.
4340 (linux_low_filter_event): Check for breakpoints before checking
4342 (linux_wait_1): Don't re-increment the PC if relying on SIGTRAP's
4344 (linux_stopped_by_sw_breakpoint)
4345 (linux_supports_stopped_by_sw_breakpoint)
4346 (linux_stopped_by_hw_breakpoint)
4347 (linux_supports_stopped_by_hw_breakpoint): New functions.
4348 (linux_target_ops): Install new target methods.
4350 2015-03-04 Pedro Alves <palves@redhat.com>
4352 * remote-utils.c (prepare_resume_reply): Report swbreak/hbreak.
4353 * server.c (swbreak_feature, hwbreak_feature): New globals.
4354 (handle_query) <qSupported>: Handle "swbreak+" and "hwbreak+".
4355 (captured_main): Clear swbreak_feature and hwbreak_feature.
4356 * server.h (swbreak_feature, hwbreak_feature): Declare.
4357 * target.h (struct target_ops) <stopped_by_sw_breakpoint,
4358 supports_stopped_by_sw_breakpoint, stopped_by_hw_breakpoint,
4359 supports_stopped_by_hw_breakpoint>: New fields.
4360 (target_supports_stopped_by_sw_breakpoint)
4361 (target_stopped_by_sw_breakpoint)
4362 (target_supports_stopped_by_hw_breakpoint)
4363 (target_stopped_by_hw_breakpoint): Declare.
4365 2015-03-04 Pedro Alves <palves@redhat.com>
4367 enum lwp_stop_reason -> enum target_stop_reason
4368 * linux-low.c (check_stopped_by_breakpoint): Adjust.
4369 (thread_still_has_status_pending_p, check_stopped_by_watchpoint)
4370 (linux_wait_1, stuck_in_jump_pad_callback)
4371 (move_out_of_jump_pad_callback, linux_resume_one_lwp)
4372 (linux_stopped_by_watchpoint):
4373 * linux-low.h (enum lwp_stop_reason): Delete.
4374 (struct lwp_info) <stop_reason>: Now an enum target_stop_reason.
4375 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
4377 2015-03-04 Yao Qi <yao.qi@linaro.org>
4379 * Makefile.in (SFILES): Add linux-aarch64-low.c.
4381 2015-03-03 Gary Benson <gbenson@redhat.com>
4383 * hostio.c (handle_vFile): Fix prefix lengths.
4385 2015-03-03 Markus Metzger <markus.t.metzger@intel.com>
4387 * linux-low.c (linux_low_enable_btrace): Do not overwrite non-zero
4390 2015-03-02 Andreas Arnez <arnez@linux.vnet.ibm.com>
4392 * Makefile.in (s390-vx-linux64.c, s390-tevx-linux64.c)
4393 (s390x-vx-linux64.c, s390x-tevx-linux64.c): New rules.
4394 (clean): Add "rm -f" for above C files.
4395 * configure.srv (srv_regobj): Add s390-vx-linux64.o,
4396 s390-tevx-linux64.o, s390x-vx-linux64.o, and s390x-tevx-linux64.o.
4397 (srv_xmlfiles): Add s390-vx-linux64.xml, s390-tevx-linux64.xml,
4398 s390x-vx-linux64.xml, s390x-tevx-linux64.xml, and s390-vx.xml.
4399 * linux-s390-low.c (HWCAP_S390_VX): New macro.
4400 (init_registers_s390_vx_linux64, init_registers_s390_tevx_linux64)
4401 (init_registers_s390x_vx_linux64)
4402 (init_registers_s390x_tevx_linux64)
4403 (tdesc_s390_vx_linux64, tdesc_s390_tevx_linux64)
4404 (tdesc_s390x_vx_linux64, tdesc_s390x_tevx_linux64): New extern
4406 (s390_fill_vxrs_low, s390_store_vxrs_low, s390_fill_vxrs_high)
4407 (s390_store_vxrs_high): New functions.
4408 (s390_regsets): Add entries for NT_S390_VXRS_LOW and
4410 (s390_arch_setup): Add logic for selecting one of the new target
4411 descriptions. Activate the new vector regsets if applicable.
4412 (initialize_low_arch): Also invoke init_registers_s390_vx_linux64,
4413 init_registers_s390_tevx_linux64, init_registers_s390x_vx_linux64,
4414 and init_registers_s390x_tevx_linux64.
4416 2015-03-01 Pedro Alves <palves@redhat.com>
4418 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Constify 'raw_regs'
4421 2015-02-27 Pedro Alves <palves@redhat.com>
4423 * linux-x86-low.c (u_debugreg_offset): New function.
4424 (x86_linux_dr_get, x86_linux_dr_set): Use it.
4426 2015-02-27 Pedro Alves <palves@redhat.com>
4428 * gdb_proc_service.h: Wrap with EXTERN_C_PUSH/EXTERN_C_POP.
4429 [!HAVE_PROC_SERVICE_H] (struct ps_prochandle): Forward declare.
4430 [!HAVE_PROC_SERVICE_H] (ps_pdread, ps_pdwrite, ps_ptread)
4431 ps_ptwrite, ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
4432 (ps_lsetfpregs, ps_getpid)
4433 (ps_get_thread_area, ps_pglobal_lookup, ps_pstop, ps_pcontinue)
4434 (ps_lstop, ps_lcontinue, ps_lgetxregsize, ps_lgetxregs)
4435 (ps_lsetxregs, ps_plog): Declare.
4437 2015-02-27 Pedro Alves <palves@redhat.com>
4439 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Use
4440 IP_AGENT_EXPORT_FUNC.
4441 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Use
4442 IP_AGENT_EXPORT_FUNC.
4443 * tracepoint.c (ATTR_USED, ATTR_NOINLINE, ATTR_CONSTRUCTOR)
4444 (IP_AGENT_EXPORT): Delete.
4445 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
4446 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
4447 (gdb_trampoline_buffer_error, collecting, gdb_collect)
4448 (stop_tracing, flush_trace_buffer, about_to_request_buffer_space)
4449 (trace_buffer_is_full, stopping_tracepoint, expr_eval_result)
4450 (error_tracepoint, tracepoints, tracing, trace_buffer_ctrl)
4451 (trace_buffer_ctrl_curr, trace_buffer_lo, trace_buffer_hi)
4452 (traceframe_read_count, traceframe_write_count)
4453 (traceframes_created, trace_state_variables, get_raw_reg)
4454 (get_trace_state_variable_value, set_trace_state_variable_value)
4455 (ust_loaded, helper_thread_id, cmd_buf): Use
4456 IPA_SYM_EXPORTED_NAME.
4457 (stop_tracing, flush_trace_buffer): Use IP_AGENT_EXPORT_FUNC.
4458 (tracepoints) Use IP_AGENT_EXPORT_VAR.
4459 (stopping_tracepoint, trace_buffer_is_full, expr_eval_result): Use
4460 IP_AGENT_EXPORT_VAR and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
4461 (last_tracepoint): Move into !IN_PROCESS_AGENT block.
4462 (error_tracepoint): Use IP_AGENT_EXPORT_VAR and wrap in
4463 EXTERN_C_PUSH/EXTERN_C_POP.
4464 (trace_state_variables): Use IP_AGENT_EXPORT_VAR.
4465 (trace_buffer_lo, trace_buffer_hi): Use IP_AGENT_EXPORT_VAR and
4466 wrap in EXTERN_C_PUSH/EXTERN_C_POP.
4467 (trace_buffer_ctrl, trace_buffer_ctrl_curr)
4468 (traceframe_write_count, traceframe_read_count)
4469 (traceframes_created, tracing): Use IP_AGENT_EXPORT_VAR.
4470 (about_to_request_buffer_space, get_trace_state_variable_value)
4471 (set_trace_state_variable_value): Use IP_AGENT_EXPORT_FUNC.
4472 (collecting): Use IP_AGENT_EXPORT_VAR and wrap in
4473 EXTERN_C_PUSH/EXTERN_C_POP.
4474 (gdb_collect): Use IP_AGENT_EXPORT_FUNC.
4475 (ust_loaded, cmd_buf): Use IP_AGENT_EXPORT_VAR.
4476 (helper_thread_id, gdb_agent_capability): Use IP_AGENT_EXPORT_VAR
4477 and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
4478 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
4479 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
4480 (gdb_trampoline_buffer_error): Use IP_AGENT_EXPORT_VAR.
4481 * tracepoint.h (ATTR_USED, ATTR_NOINLINE, EXPORTED_SYMBOL):
4483 (IP_AGENT_EXPORT_FUNC, IP_AGENT_EXPORT_VAR)
4484 (IP_AGENT_EXPORT_VAR_DECL): Define.
4486 (gdb_agent_get_raw_reg): Declare.
4488 2015-02-27 Tom Tromey <tromey@redhat.com>
4489 Pedro Alves <palves@redhat.com>
4491 Rename symbols whose names are reserved C++ keywords throughout.
4493 2015-02-27 Pedro Alves <palves@redhat.com>
4495 * Makefile.in (COMPILER): New, get it from autoconf.
4496 (CXX): Get from autoconf instead.
4497 (COMPILE.pre): Use COMPILER.
4498 (CC-LD): Rename to ...
4499 (CC_LD): ... this. Use COMPILER.
4500 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT), $(IPA_LIB)): Adjust.
4501 (CXX_FOR_TARGET): Default to g++ instead of gcc.
4502 * acinclude.m4: Include build-with-cxx.m4.
4503 * configure.ac: Call AC_PROG_CXX and GDB_AC_BUILD_WITH_CXX.
4504 Disable -Werror by default if building in C++ mode.
4505 (build_warnings): Add -Wno-sign-compare, -Wno-write-strings and
4506 -Wno-narrowing in C++ mode. Run supported-warning-flags tests with
4507 the C++ compiler. Save/restore CXXFLAGS too.
4508 * configure: Regenerate.
4510 2015-02-27 Pedro Alves <palves@redhat.com>
4512 * acinclude.m4: Include libiberty.m4.
4513 * configure.ac: Call libiberty_INIT.
4514 * config.in, configure: Regenerate.
4516 2015-02-26 Pedro Alves <palves@redhat.com>
4518 * linux-low.c (linux_wait_1): When incrementing the PC past a
4519 program breakpoint always use the_low_target.breakpoint_len as
4520 increment, rather than the maximum between that and
4521 the_low_target.decr_pc_after_break.
4523 2015-02-23 Pedro Alves <palves@redhat.com>
4525 * linux-low.c (check_stopped_by_breakpoint): Don't check if the
4526 thread was doing a step-over; always adjust the PC if
4527 we stepped over a permanent breakpoint.
4528 (linux_wait_1): If we stepped over breakpoint that was on top of a
4529 permanent breakpoint, manually advance the PC past it.
4531 2015-02-23 Pedro Alves <palves@redhat.com>
4533 * linux-x86-low.c (REGSIZE): Define in both 32-bit and 64-bit
4535 (x86_fill_gregset, x86_store_gregset): Use it when handling
4538 2015-02-20 Pedro Alves <palves@redhat.com>
4540 * thread-db.c: Include "nat/linux-procfs.h".
4541 (thread_db_init): Skip listing new threads if the kernel supports
4542 PTRACE_EVENT_CLONE and /proc/PID/task/ is accessible.
4544 2015-02-20 Pedro Alves <palves@redhat.com>
4546 * linux-low.c (status_pending_p_callback): Use ptid_match.
4548 2015-02-19 Antoine Tremblay <antoine.tremblay@ericsson.com>
4550 PR breakpoints/16812
4551 * linux-low.c (wstatus_maybe_breakpoint): Remove.
4552 (linux_low_filter_event): Update wstatus_maybe_breakpoint name.
4553 (linux_wait_1): Report SIGTRAP,SIGILL,SIGSEGV.
4555 2015-02-10 Antoine Tremblay <antoine.tremblay@ericsson.com>
4557 PR breakpoints/15956
4558 * tracepoint.c (cmd_qtinit): Add check for current_thread.
4560 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
4562 * linux-low.c (linux_low_btrace_conf): Print size.
4563 * server.c (handle_btrace_conf_general_set): New.
4564 (hanle_general_set): Call handle_btrace_conf_general_set.
4565 (handle_query): Report Qbtrace-conf:bts:size as supported.
4567 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
4569 * linux-low.c (linux_low_enable_btrace): Update parameters.
4570 (linux_low_btrace_conf): New.
4571 (linux_target_ops)<to_btrace_conf>: Initialize.
4572 * server.c (current_btrace_conf): New.
4573 (handle_btrace_enable): Rename to ...
4574 (handle_btrace_enable_bts): ... this. Pass ¤t_btrace_conf
4575 to target_enable_btrace. Update comment. Update users.
4576 (handle_qxfer_btrace_conf): New.
4577 (qxfer_packets): Add btrace-conf entry.
4578 (handle_query): Report qXfer:btrace-conf:read as supported packet.
4579 * target.h (target_ops)<enable_btrace>: Update parameters and comment.
4580 (target_ops)<read_btrace_conf>: New.
4581 (target_enable_btrace): Update parameters.
4582 (target_read_btrace_conf): New.
4584 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
4586 * server.c (handle_btrace_general_set): Remove call to
4587 target_supports_btrace.
4588 (supported_btrace_packets): New.
4589 (handle_query): Call supported_btrace_packets.
4590 * target.h: include btrace-common.h.
4591 (btrace_target_info): Removed.
4592 (supports_btrace, target_supports_btrace): Update parameters.
4594 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
4596 * Makefile.in (SFILES): Add common/btrace-common.c.
4597 (OBS): Add common/btrace-common.o.
4598 (btrace-common.o): Add build rules.
4599 * linux-low: Include btrace-common.h.
4600 (linux_low_read_btrace): Use struct btrace_data. Call
4601 btrace_data_init and btrace_data_fini.
4603 2015-02-06 Pedro Alves <palves@redhat.com>
4605 * thread-db.c (find_new_threads_callback): Add debug output.
4607 2015-02-04 Pedro Alves <palves@redhat.com>
4609 * linux-low.c (handle_extended_wait): Don't resume LWPs here.
4610 (resume_stopped_resumed_lwps): New function.
4611 (linux_wait_for_event_filtered): Use it.
4613 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
4615 * Makefile.in (SFILES): Add linux-personality.c.
4616 (linux-personality.o): New rule.
4617 * configure.srv (srv_linux_obj): Add linux-personality.o to the
4618 list of objects to be built.
4619 * linux-low.c: Include nat/linux-personality.h.
4620 (linux_create_inferior): Remove code to disable address space
4621 randomization (moved to ../nat/linux-personality.c). Create
4622 cleanup to disable address space randomization.
4624 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
4626 * Makefile.in (posix-strerror.o): New rule.
4627 (mingw-strerror.o): Likewise.
4628 * configure: Regenerated.
4629 * configure.ac: Source file ../common/common.host. Initialize new
4630 variable srv_host_obs. Add srv_host_obs to GDBSERVER_DEPFILES.
4632 2015-01-14 Yao Qi <yao@codesourcery.com>
4634 * Makefile.in (SFILES): Add nat/ppc-linux.c.
4635 (ppc-linux.o): New rule.
4636 * configure.srv (powerpc*-*-linux*): Add ppc-linux.o.
4637 * configure.ac: AC_CHECK_FUNCS(getauxval).
4638 * config.in: Re-generated.
4639 * configure: Re-generated.
4640 * linux-ppc-low.c (ppc_arch_setup) [__powerpc64__]: Call
4641 ppc64_64bit_inferior_p
4643 2015-01-14 Yao Qi <yao@codesourcery.com>
4645 * linux-ppc-low.c: Include "nat/ppc-linux.h".
4646 (PPC_FEATURE_HAS_VSX): Move to nat/ppc-linux.h.
4647 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Likewise.
4648 (PT_ORIG_R3, PT_TRAP): Likewise.
4649 (PTRACE_GETVSXREGS, PTRACE_SETVSXREGS): Likewise.
4650 (PTRACE_GETVRREGS, PTRACE_SETVRREGS): Likewise.
4651 (PTRACE_GETEVRREGS, PTRACE_SETEVRREGS): Likewise.
4653 2015-01-10 Joel Brobecker <brobecker@adacore.com>
4655 * i387-fp.c (i387_cache_to_xsave): In look over
4656 num_avx512_zmmh_high_registers, replace use of struct i387_xsave
4657 zmmh_low_space field by use of zmmh_high_space.
4659 2015-01-09 Pedro Alves <palves@redhat.com>
4661 * linux-low.c (step_over_bkpt): Move higher up in the file.
4662 (handle_extended_wait): Don't store the stop_pc here.
4663 (get_stop_pc): Adjust comments and rename to ...
4664 (check_stopped_by_breakpoint): ... this. Record whether the LWP
4665 stopped for a software breakpoint or hardware breakpoint.
4666 (thread_still_has_status_pending_p): New function.
4667 (status_pending_p_callback): Use
4668 thread_still_has_status_pending_p. If the event is no longer
4669 interesting, resume the LWP.
4670 (handle_tracepoints): Add assert.
4671 (maybe_move_out_of_jump_pad): Remove cancel_breakpoints call.
4672 (wstatus_maybe_breakpoint): New function.
4673 (cancel_breakpoint): Delete function.
4674 (check_stopped_by_watchpoint): New function, factored out from
4675 linux_low_filter_event.
4676 (lp_status_maybe_breakpoint): Delete function.
4677 (linux_low_filter_event): Remove filter_ptid argument.
4678 Leave thread group exits pending here. Store the LWP's stop PC.
4679 Always leave events pending.
4680 (linux_wait_for_event_filtered): Pull all events out of the
4681 kernel, and leave them all pending.
4682 (count_events_callback, select_event_lwp_callback): Consider all
4684 (cancel_breakpoints_callback, linux_cancel_breakpoints): Delete.
4685 (select_event_lwp): Only give preference to the stepping LWP in
4686 all-stop mode. Adjust comments.
4687 (ignore_event): New function.
4688 (linux_wait_1): Delete 'retry' label. Use ignore_event. Remove
4689 references to cancel_breakpoints. Adjust to renames. Also give
4690 equal priority to all LWPs that have had events in non-stop mode.
4691 If reporting a software breakpoint event, unadjust the LWP's PC.
4692 (linux_wait): If linux_wait_1 returned an ignored event, retry.
4693 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback):
4695 (linux_resume_one_lwp): Store the LWP's PC. Adjust.
4696 (resume_status_pending_p): Use thread_still_has_status_pending_p.
4697 (linux_stopped_by_watchpoint): Adjust.
4698 (linux_target_ops): Remove reference to linux_cancel_breakpoints.
4699 * linux-low.h (enum lwp_stop_reason): New.
4700 (struct lwp_info) <stop_pc>: Adjust comment.
4701 <stopped_by_watchpoint>: Delete field.
4702 <stop_reason>: New field.
4703 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
4704 * mem-break.c (software_breakpoint_inserted_here)
4705 (hardware_breakpoint_inserted_here): New function.
4706 * mem-break.h (software_breakpoint_inserted_here)
4707 (hardware_breakpoint_inserted_here): Declare.
4708 * target.h (struct target_ops) <cancel_breakpoints>: Remove field.
4709 (cancel_breakpoints): Delete.
4710 * tracepoint.c (clear_installed_tracepoints, stop_tracing)
4711 (upload_fast_traceframes): Remove references to
4714 2015-01-09 Pedro Alves <palves@redhat.com>
4716 * thread-db.c (find_new_threads_callback): Ignore thread if the
4717 kernel thread ID is -1.
4719 2015-01-09 Pedro Alves <palves@redhat.com>
4721 * linux-low.c (linux_attach_fail_reason_string): Move to
4722 nat/linux-ptrace.c, and rename.
4723 (linux_attach_lwp): Update comment.
4724 (attach_proc_task_lwp_callback): New function.
4725 (linux_attach): Adjust to rename and use
4726 linux_proc_attach_tgid_threads.
4727 (linux_attach_fail_reason_string): Delete declaration.
4729 2015-01-01 Joel Brobecker <brobecker@adacore.com>
4731 * gdbreplay.c (gdbreplay_version): Update copyright year to 2015.
4732 * server.c (gdbserver_version): Likewise.
4734 2014-12-29 Sergio Durigan Junior <sergiodj@redhat.com>
4736 * remote-utils.c: Include ctype.h.
4737 (input_interrupt): Explicitly handle the case when the char
4738 received is the NUL byte. Improve the printing of non-ASCII
4741 2014-12-16 Joel Brobecker <brobecker@adacore.com>
4743 * linux-low.c (linux_low_filter_event): Update call to
4744 linux_enable_event_reporting following the addition of
4745 a new parameter to that function.
4747 2014-12-16 Catalin Udma <catalin.udma@freescale.com>
4750 * linux-aarch64-low.c (AARCH64_FPSR_REGNO): New define.
4751 (AARCH64_FPCR_REGNO): Likewise.
4752 (AARCH64_NUM_REGS): Update to include fpsr/fpcr registers.
4753 (aarch64_fill_fpregset): Add missing fpsr/fpcr registers.
4754 (aarch64_store_fpregset): Likewise.
4756 2014-12-15 Joel Brobecker <brobecker@adacore.com>
4758 * lynx-low.c (lynx_resume): Use PTRACE_SINGLESTEP_ONE if N == 1.
4759 Remove FIXME comment about assumption about N.
4761 2014-12-13 Joel Brobecker <brobecker@adacore.com>
4763 * configure.ac: If large-file support is disabled in GDBserver,
4764 pass --disable-largefile to ACX_CONFIGURE_DIR call for "gnulib".
4765 * configure: Regenerate.
4767 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
4769 * linux-low.c (regsets_fetch_inferior_registers): Suppress the
4770 warning upon ENODATA from ptrace.
4771 * linux-s390-low.c (s390_store_tdb): New.
4772 (s390_regsets): Add regset for NT_S390_TDB.
4774 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
4776 * linux-low.c (regsets_store_inferior_registers): Skip regsets
4777 without a fill_function.
4778 * linux-s390-low.c (s390_fill_last_break): Remove.
4779 (s390_regsets): Set fill_function to NULL for NT_S390_LAST_BREAK.
4780 (s390_arch_setup): Use regset's size instead of fill_function for
4783 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
4785 * linux-low.c (regsets_fetch_inferior_registers): Do not invoke
4786 the regset's store function when ptrace returned an error.
4787 * regcache.c (get_thread_regcache): Invalidate register cache
4788 before fetching inferior's registers.
4790 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
4792 * linux-low.c (regsets_fetch_inferior_registers): Rephrase
4793 while-loop as for-loop.
4794 (regsets_store_inferior_registers): Likewise.
4796 2014-11-28 Yao Qi <yao@codesourcery.com>
4798 * configure.ac(AC_CHECK_FUNCS): Remove readlink.
4799 * config.in, configure: Re-generate.
4800 * hostio.c (handle_unlink): Remove code checking HAVE_READLINK
4803 2014-11-21 Yao Qi <yao@codesourcery.com>
4805 * configure.ac: Don't invoke AC_FUNC_ALLOCA.
4806 (AC_CHECK_HEADERS): Remove malloc.h.
4807 * configure: Re-generated.
4808 * config.in: Re-generated.
4809 * server.h: Don't include alloca.h and malloc.h.
4810 * gdbreplay.c: Don't check HAVE_ALLOCA_H is defined.
4811 Don't include malloc.h.
4813 2014-11-17 Joel Brobecker <brobecker@adacore.com>
4815 * lynx-low.c (lynx_write_memory): Put lynx_read_memory and
4816 corresponding ERRNO check in same block.
4818 2014-11-12 Pedro Alves <palves@redhat.com>
4820 * server.c (cont_thread): Update comment.
4821 (start_inferior, attach_inferior): No longer clear cont_thread.
4822 (handle_v_cont): No longer set cont_thread.
4823 (captured_main): Clear cont_thread each time a GDB connects.
4825 2014-11-12 Pedro Alves <palves@redhat.com>
4827 * linux-low.c (linux_wait_1): Don't force a wait for the Hc
4828 thread, and don't resume all threads if the Hc thread has exited.
4830 2014-11-12 Pedro Alves <palves@redhat.com>
4832 * linux-low.c (linux_request_interrupt): Always send a SIGINT to
4833 the process group instead of to a specific LWP.
4835 2014-10-15 Pedro Alves <palves@redhat.com>
4838 * win32-arm-low.c (arm_set_thread_context): Remove current_event
4840 (arm_set_thread_context): Delete.
4841 (the_low_target): Adjust.
4842 * win32-i386-low.c (debug_registers_changed)
4843 (debug_registers_used): Delete.
4844 (update_debug_registers_callback): New function.
4845 (x86_dr_low_set_addr, x86_dr_low_set_control): Mark all threads as
4846 needing to update their debug registers.
4847 (win32_get_current_dr): New function.
4848 (x86_dr_low_get_addr, x86_dr_low_get_control)
4849 (x86_dr_low_get_status): Fetch the debug register from the thread
4851 (i386_initial_stuff): Adjust.
4852 (i386_get_thread_context): Remove current_event parameter. Don't
4853 clear debug_registers_changed nor copy DR values to
4855 (i386_set_thread_context): Delete.
4856 (i386_prepare_to_resume): New function.
4857 (i386_thread_added): Mark the thread as needing to update irs
4859 (the_low_target): Remove i386_set_thread_context and install
4860 i386_prepare_to_resume.
4861 * win32-low.c (win32_get_thread_context): Adjust.
4862 (win32_set_thread_context): Use SetThreadContext
4864 (win32_prepare_to_resume): New function.
4865 (win32_require_context): New function, factored out from ...
4866 (thread_rec): ... this.
4867 (continue_one_thread): Call win32_prepare_to_resume on each thread
4868 we're about to continue.
4869 (win32_resume): Call win32_prepare_to_resume on the event thread.
4870 * win32-low.h (struct win32_thread_info)
4871 <debug_registers_changed>: New field.
4872 (struct win32_target_ops): Change prototype of set_thread_context,
4873 delete set_thread_context and add prepare_to_resume.
4874 (win32_require_context): New declaration.
4876 2014-10-08 Gary Benson <gbenson@redhat.com>
4878 * server.h: Do not include common-exceptions.h.
4880 2014-10-08 Gary Benson <gbenson@redhat.com>
4882 * server.h: Do not include cleanups.h.
4884 2014-09-30 James Hogan <james.hogan@imgtec.com>
4886 * Makefile.in (clean): Add rm -f commands for mips-dsp-linux.c and
4889 2014-09-23 Yao Qi <yao@codesourcery.com>
4891 * linux-low.c (lp_status_maybe_breakpoint): New function.
4892 (linux_low_filter_event): Call lp_status_maybe_breakpoint.
4893 (count_events_callback): Likewise.
4894 (select_event_lwp_callback): Likewise.
4895 (cancel_breakpoints_callback): Likewise.
4897 2014-09-19 Don Breazeal <donb@codesourcery.com>
4899 * linux-low.c (handle_extended_wait): Call
4900 linux_ptrace_get_extended_event.
4901 (get_stop_pc, get_detach_signal, linux_low_filter_event): Call
4902 linux_is_extended_waitstatus.
4904 2014-09-16 Joel Brobecker <brobecker@adacore.com>
4906 * Makefile.in (CPPFLAGS): Define.
4907 (INTERNAL_CFLAGS_BASE): Add ${CPPFLAGS}.
4908 (IPAGENT_CFLAGS): Remove ${CPPFLAGS}.
4910 2014-09-16 Gary Benson <gbenson@redhat.com>
4912 * inferiors.h (current_inferior): Renamed as...
4913 (current_thread): New variable. All uses updated.
4914 * linux-low.c (get_pc): Renamed saved_inferior as saved_thread.
4915 (maybe_move_out_of_jump_pad): Likewise.
4916 (cancel_breakpoint): Likewise.
4917 (linux_low_filter_event): Likewise.
4918 (wait_for_sigstop): Likewise.
4919 (linux_resume_one_lwp): Likewise.
4920 (need_step_over_p): Likewise.
4921 (start_step_over): Likewise.
4922 (linux_stabilize_threads): Renamed save_inferior as saved_thread.
4923 * linux-x86-low.c (x86_linux_update_xmltarget): Likewise.
4924 * proc-service.c (ps_lgetregs): Renamed reg_inferior as reg_thread
4925 and save_inferior as saved_thread.
4926 * regcache.c (get_thread_regcache): Renamed saved_inferior as
4928 (regcache_invalidate_thread): Likewise.
4929 * remote-utils.c (prepare_resume_reply): Likewise.
4930 * thread-db.c (thread_db_get_tls_address): Likewise.
4931 (disable_thread_event_reporting): Likewise.
4932 (remove_thread_event_breakpoints): Likewise.
4933 * tracepoint.c (gdb_agent_about_to_close): Renamed save_inferior
4935 * target.h (set_desired_inferior): Renamed as...
4936 (set_desired_thread): New declaration. All uses updated.
4937 * server.c (myresume): Updated comment to reference thread instead
4939 (handle_serial_event): Likewise.
4940 (handle_target_event): Likewise.
4942 2014-09-12 Tom Tromey <tromey@redhat.com>
4943 Gary Benson <gbenson@redhat.com>
4945 * regcache.h: Include common-regcache.h.
4946 (regcache_read_pc): Don't declare.
4947 * regcache.c (get_thread_regcache_for_ptid): New function.
4949 2014-09-11 Tom Tromey <tromey@redhat.com>
4950 Gary Benson <gbenson@redhat.com>
4952 * symbol.c: New file.
4953 * Makefile.in (SFILES): Add symbol.c.
4954 (OBS): Add symbol.o.
4956 2014-09-11 Gary Benson <gbenson@redhat.com>
4958 * target.c (target_stop_ptid, target_continue_ptid): New
4961 2014-09-11 Tom Tromey <tromey@redhat.com>
4962 Gary Benson <gbenson@redhat.com>
4964 * target.h: Include target/target.h.
4965 * target.c (target_read_memory, target_read_uint32)
4966 (target_write_memory): New functions.
4968 2014-09-11 Gary Benson <gbenson@redhat.com>
4970 * server.h (debug_hw_points): Don't declare.
4971 * server.c (debug_hw_points): Don't define. Replace all uses
4972 with show_debug_regs.
4973 * linux-aarch64-low.c (debug_hw_points): Don't define. Replace
4974 all uses with show_debug_regs.
4976 2014-09-08 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
4978 * linux-ppc-low.c (ppc_collect_ptrace_register): Adjust routine to take
4979 endianness into account.
4980 (ppc_supply_ptrace_register): Likewise.
4982 2014-09-03 James Hogan <james.hogan@imgtec.com>
4984 * linux-mips-low.c (mips_read_description): Reset errno to 0 prior
4985 to reading DSP_CONTROL with PTRACE_PEEKUSER ptrace call.
4987 2014-09-03 Gary Benson <gbenson@redhat.com>
4989 * linux-x86-low.c (x86_linux_prepare_to_resume): Use
4990 ALL_DEBUG_ADDRESS_REGISTERS.
4992 2014-09-02 Gary Benson <gbenson@redhat.com>
4994 * i386-low.h: Renamed as...
4995 * x86-low.h: New file. All type, function and variable name
4996 prefixes changed from "i386_" to "x86_". All references updated.
4997 * i386-low.c: Renamed as...
4998 * x86-low.c: New file. All type, function and variable name
4999 prefixes changed from "i386_" to "x86_". All references updated.
5001 2014-09-02 Gary Benson <gbenson@redhat.com>
5003 * linux-x86-low.c (x86_linux_new_process): Use XCNEW.
5004 (x86_linux_new_thread): Likewise.
5006 2014-08-29 Gary Benson <gbenson@redhat.com>
5008 * server.h (setjmp.h): Do not include.
5009 (toplevel): Do not declare.
5010 (common-exceptions.h): Include.
5011 (cleanups.h): Likewise.
5012 * server.c (toplevel): Do not define.
5013 (exit_code): New static global.
5014 (detach_or_kill_for_exit_cleanup): New function.
5015 (main): New function. Original main renamed to...
5016 (captured_main): New function.
5017 * utils.c (verror) [!IN_PROCESS_AGENT]: Use throw_verror.
5019 2014-08-29 Gary Benson <gbenson@redhat.com>
5021 * Makefile.in (SFILES): Add common/common-exceptions.c.
5022 (OBS): Add common-exceptions.o.
5023 (common-exceptions.o): New rule.
5024 * utils.c (prepare_to_throw_exception): New function.
5026 2014-08-29 Gary Benson <gbenson@redhat.com>
5028 * config.in: Regenerate.
5029 * configure: Likewise.
5031 2014-08-29 Gary Benson <gbenson@redhat.com>
5033 * Makefile.in (SFILES): Add common/cleanups.c.
5035 (cleanups.o): New rule.
5037 2014-08-29 Gary Benson <gbenson@redhat.com>
5039 * utils.c (internal_vwarning): New function.
5041 2014-08-28 Gary Benson <gbenson@redhat.com>
5043 * utils.h (fatal): Remove declaration.
5044 * utils.c (fatal): Remove function.
5046 2014-08-28 Gary Benson <gbenson@redhat.com>
5048 * tracepoint.c (gdb_agent_init): Replace fatal with
5050 (initialize_tracepoint): Likewise.
5052 2014-08-28 Gary Benson <gbenson@redhat.com>
5054 * remote-utils.c (remote_prepare): Replace fatal with error.
5056 2014-08-28 Gary Benson <gbenson@redhat.com>
5058 * linux-low.c (linux_async): Replace fatal with warning.
5060 (linux_start_non_stop): Return -1 if linux_async failed.
5062 2014-08-28 Gary Benson <gbenson@redhat.com>
5064 * linux-x86-low.c (i386_dr_low_set_addr): Replace check with
5066 (i386_dr_low_get_addr): Remove vague comment.
5067 * win32-i386-low.c (i386_dr_low_set_addr): Replace check with
5070 2014-08-28 Gary Benson <gbenson@redhat.com>
5072 * inferiors.c (get_thread_process): Replace check with gdb_assert.
5073 * linux-low.c (linux_wait_for_event_filtered): Replace fatal with
5075 (linux_resume_one_lwp): Likewise.
5076 * linux-x86-low.c (x86_siginfo_fixup): Replace checks with
5078 * mem-break.c (raw_bkpt_type_to_target_hw_bp_type): Replace fatal
5079 with internal_error.
5080 * regcache.c (get_thread_regcache): Replace check with gdb_assert.
5081 (init_register_cache): Replace fatal with gdb_assert_not_reached.
5082 (find_register_by_name): Replace fatal with internal_error.
5083 (find_regno): Likewise.
5084 * tdesc.c (init_target_desc): Replace check with gdb_assert.
5085 * thread-db.c (thread_db_create_event): Likewise.
5086 (thread_db_load_search): Likewise.
5087 (try_thread_db_load_1): Likewise.
5088 * tracepoint.c (get_jump_space_head): Replace fatal with
5090 (claim_trampoline_space): Likewise.
5091 (have_fast_tracepoint_trampoline_buffer): Likewise.
5092 (cmd_qtstart): Likewise.
5093 (stop_tracing): Likewise.
5094 (fast_tracepoint_collecting): Likewise.
5095 (target_malloc): Likewise.
5096 (download_tracepoint): Likewise.
5097 (download_trace_state_variables): Replace check with gdb_assert.
5098 (upload_fast_traceframes): Replace fatal with internal_error.
5100 2014-08-19 Tom Tromey <tromey@redhat.com>
5101 Gary Benson <gbenson@redhat.com>
5103 * Makefile.in (SFILES): Add common/common-debug.c.
5104 (OBS): Add common-debug.o.
5105 (common-debug.o): New rule.
5106 * debug.h (debug_printf): Don't declare.
5107 * debug.c (debug_printf): Renamed and rewritten as...
5108 (debug_vprintf): New function.
5110 2014-08-19 Gary Benson <gbenson@redhat.com>
5112 * utils.h: Do not include print-utils.h.
5114 2014-08-19 Tom Tromey <tromey@redhat.com>
5115 Gary Benson <gbenson@redhat.com>
5117 * server.h: Add static assertion.
5118 (gdb_byte, CORE_ADDR, LONGEST, ULONGEST): Remove.
5120 2014-08-19 Tom Tromey <tromey@redhat.com>
5121 Gary Benson <gbenson@redhat.com>
5123 * Makefile.in (SFILES): Add common/errors.c.
5124 (OBS): Add errors.o.
5125 (IPA_OBS): Add errors-ipa.o.
5126 (errors.o): New rule.
5127 (errors-ipa.o): Likewise.
5128 * utils.h (perror_with_name, error, warning): Don't declare.
5129 * utils.c (warning): Renamed and rewritten as...
5130 (vwarning): New function.
5131 (error): Renamed and rewritten as...
5132 (verror): New function.
5133 (internal_error): Renamed and rewritten as...
5134 (internal_verror): New function.
5136 2014-08-07 Gary Benson <gbenson@redhat.com>
5138 * configure.ac (AC_CHECK_HEADERS): Remove errno.h.
5139 * configure: Regenerate.
5140 * config.in: Likewise.
5141 * server.h: Do not include errno.h.
5142 * event-loop.c: Likewise.
5143 * hostio-errno.c: Likewise.
5144 * linux-low.c: Likewise.
5145 * remote-utils.c: Likewise.
5146 * spu-low.c: Likewise.
5147 * utils.c: Likewise.
5148 * gdbreplay.c: Unconditionally include errno.h.
5150 2014-08-07 Gary Benson <gbenson@redhat.com>
5152 * server.h: Do not include string.h.
5153 * event-loop.c: Likewise.
5154 * linux-low.c: Likewise.
5155 * regcache.c: Likewise.
5156 * remote-utils.c: Likewise.
5157 * spu-low.c: Likewise.
5158 * utils.c: Likewise.
5160 2014-08-07 Gary Benson <gbenson@redhat.com>
5162 * server.h: Do not include gdb_assert.h.
5164 2014-08-07 Gary Benson <gbenson@redhat.com>
5166 * server.h: Do not include common-utils.h.
5168 2014-08-07 Gary Benson <gbenson@redhat.com>
5170 * server.h: Do not include ptid.h.
5171 * notif.h: Likewise.
5173 2014-08-07 Gary Benson <gbenson@redhat.com>
5175 * server.h: Do not include gdb_locale.h.
5177 2014-08-07 Gary Benson <gbenson@redhat.com>
5179 * server.h: Do not include gdb/signals.h.
5180 * win32-low.c: Likewise.
5182 2014-08-07 Gary Benson <gbenson@redhat.com>
5184 * server.h: Do not include pathmax.h.
5186 2014-08-07 Gary Benson <gbenson@redhat.com>
5188 * server.h: Do not include libiberty.h.
5189 * linux-bfin-low.c: Likewise.
5191 2014-08-07 Gary Benson <gbenson@redhat.com>
5193 * server.h: Do not include ansidecl.h.
5195 2014-08-07 Gary Benson <gbenson@redhat.com>
5197 * linux-x86-low.c: Do not include stddef.h.
5198 * lynx-ppc-low.c: Likewise.
5199 * tracepoint.c: Likewise.
5201 2014-08-07 Gary Benson <gbenson@redhat.com>
5203 * server.h: Do not include stdarg.h.
5204 * nto-low.c: Likewise.
5206 2014-08-07 Gary Benson <gbenson@redhat.com>
5208 * server.h: Do not include stdlib.h.
5209 * inferiors.c: Likewise.
5210 * linux-low.c: Likewise.
5211 * regcache.c: Likewise.
5212 * spu-low.c: Likewise.
5213 * tracepoint.c: Likewise.
5214 * utils.c: Likewise.
5216 2014-08-07 Gary Benson <gbenson@redhat.com>
5218 * server.h: Do not include stdio.h.
5219 * linux-low.c: Likewise.
5220 * remote-utils.c: Likewise.
5221 * spu-low.c: Likewise.
5222 * utils.c: Likewise.
5223 * wincecompat.c: Likewise.
5225 2014-08-06 Gary Benson <gbenson@redhat.com>
5227 * regcache.c (init_register_cache): Move conditionals inside if.
5229 2014-08-06 Gary Benson <gbenson@redhat.com>
5231 * linux-low.c (linux_supports_non_stop): Use target_is_async_p.
5233 2014-07-31 Gary Benson <gbenson@redhat.com>
5235 * ax.h: Do not include server.h.
5236 * gdbthread.h: Likewise.
5237 * lynx-low.h: Likewise.
5238 * notif.h: Likewise.
5240 2014-07-30 Gary Benson <gbenson@redhat.com>
5242 * server.h: Include common-defs.h.
5243 Do not include config.h or build-gnulib-gdbserver/config.h.
5245 2014-07-30 Gary Benson <gbenson@redhat.com>
5247 * hostio-errno.c: Move server.h to top of includes list.
5248 * inferiors.c: Likewise.
5249 * linux-x86-low.c: Likewise.
5250 * notif.c: Include server.h.
5252 2014-07-24 Tom Tromey <tromey@redhat.com>
5253 Gary Benson <gbenson@redhat.com>
5255 * server.h (CORE_ADDR): Now unsigned.
5257 2014-07-16 Pedro Alves <palves@redhat.com>
5259 * linux-low.c (linux_kill_one_lwp): Use kill_lwp, not kill.
5261 2014-07-15 Pedro Alves <palves@redhat.com>
5263 * linux-low.c (linux_kill_one_lwp): Save errno and work with saved
5266 2014-07-11 Pedro Alves <palves@redhat.com>
5268 * linux-low.c (kill_wait_lwp): New function, based on
5269 kill_one_lwp_callback, but use my_waitpid directly.
5270 (kill_one_lwp_callback, linux_kill): Use it.
5272 2014-06-23 Pedro Alves <palves@redhat.com>
5274 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR_CONTROL
5275 before setting DR0..DR3.
5277 2014-06-20 Gary Benson <gbenson@redhat.com>
5279 * configure.ac (AC_REPLACE_FUNCS) <vasprintf, vsnprintf>: Removed.
5280 * configure: Regenerated.
5281 * config.in: Likewise.
5283 2014-06-20 Gary Benson <gbenson@redhat.com>
5285 * Makefile.in (SFILES): Update locations for files moved
5287 (object file files): Reordered.
5289 2014-06-20 Gary Benson <gbenson@redhat.com>
5291 * i386-low.h (i386_dr_low_can_set_addr): Removed.
5292 (i386_dr_low_set_addr): Likewise.
5293 (i386_dr_low_get_addr): Likewise.
5294 (i386_dr_low_can_set_control): Likewise.
5295 (i386_dr_low_set_control): Likewise.
5296 (i386_dr_low_get_control): Likewise.
5297 (i386_dr_low_get_status): Likewise.
5298 (i386_get_debug_register_length): Likewise.
5299 * linux-x86-low.c (i386_dr_low_set_addr):
5300 Changed signature. Made static.
5301 (i386_dr_low_get_addr): Likewise.
5302 (i386_dr_low_set_control): Likewise.
5303 (i386_dr_low_get_control): Likewise.
5304 (i386_dr_low_get_status): Likewise.
5305 (i386_dr_low): New global variable.
5306 * win32-i386-low.c (i386_dr_low_set_addr):
5307 Changed signature. Made static.
5308 (i386_dr_low_get_addr): Likewise.
5309 (i386_dr_low_set_control): Likewise.
5310 (i386_dr_low_get_control): Likewise.
5311 (i386_dr_low_get_status): Likewise.
5312 (i386_dr_low): New global variable.
5314 2014-06-20 Marcus Shawcroft <marcus.shawcroft@arm.com>
5316 * configure.ac: Invoke. AC_CHECK_TOOL(AR, ar).
5317 * Makefile.in (AR, AR_FLAGS): Define.
5318 * configure: Regenerate.
5320 2014-06-19 Gary Benson <gbenson@redhat.com>
5322 * Makefile.in (i386-dregs.o): New rule.
5323 * configure.srv: Add i386-dregs.o to all targets using i386-low.o.
5324 * i386-low.c (target.h): Remove include.
5325 (TARGET_HAS_DR_LEN_8): Now in i386-dregs.c.
5326 (DR_CONTROL_SHIFT): Likewise.
5327 (DR_CONTROL_SIZE): Likewise.
5328 (DR_RW_EXECUTE): Likewise.
5329 (DR_RW_WRITE): Likewise.
5330 (DR_RW_READ): Likewise.
5331 (DR_RW_IORW): Likewise.
5332 (DR_LEN_1): Likewise.
5333 (DR_LEN_2): Likewise.
5334 (DR_LEN_4): Likewise.
5335 (DR_LEN_8): Likewise.
5336 (DR_LOCAL_ENABLE_SHIFT): Likewise.
5337 (DR_GLOBAL_ENABLE_SHIFT): Likewise.
5338 (DR_ENABLE_SIZE): Likewise.
5339 (DR_LOCAL_SLOWDOWN): Likewise.
5340 (DR_GLOBAL_SLOWDOWN): Likewise.
5341 (DR_CONTROL_RESERVED): Likewise.
5342 (I386_DR_CONTROL_MASK): Likewise.
5343 (I386_DR_VACANT): Likewise.
5344 (I386_DR_LOCAL_ENABLE): Likewise.
5345 (I386_DR_GLOBAL_ENABLE): Likewise.
5346 (I386_DR_DISABLE): Likewise.
5347 (I386_DR_SET_RW_LEN): Likewise.
5348 (I386_DR_GET_RW_LEN): Likewise.
5349 (I386_DR_WATCH_HIT): Likewise.
5350 (i386_wp_op_t): Likewise.
5351 (i386_show_dr): Likewise.
5352 (i386_length_and_rw_bits): Likewise.
5353 (i386_insert_aligned_watchpoint): Likewise.
5354 (i386_remove_aligned_watchpoint): Likewise.
5355 (i386_handle_nonaligned_watchpoint): Likewise.
5356 i386_update_inferior_debug_regs(): Likewise.
5357 (i386_dr_insert_watchpoint): Likewise.
5358 (i386_dr_remove_watchpoint): Likewise.
5359 (i386_dr_region_ok_for_watchpoint): Likewise.
5360 (i386_dr_stopped_data_address): Likewise.
5361 (i386_dr_stopped_by_watchpoint): Likewise.
5363 2014-06-19 Gary Benson <gbenson@redhat.com>
5365 * i386-low.c (i386_dr_show): Renamed to
5366 i386_show_dr and made static. All uses updated.
5367 (i386_dr_length_and_rw_bits): Renamed to
5368 i386_length_and_rw_bits and made static.
5370 (i386_dr_insert_aligned_watchpoint): Renamed to
5371 i386_insert_aligned_watchpoint and made static.
5373 (i386_dr_remove_aligned_watchpoint): Renamed to
5374 i386_remove_aligned_watchpoint and made static.
5376 (i386_dr_update_inferior_debug_regs): Renamed to
5377 i386_update_inferior_debug_regs and made static.
5380 2014-06-18 Gary Benson <gbenson@redhat.com>
5382 * i386-low.h (i386_dr_low_can_set_addr): New macro.
5383 (i386_dr_low_can_set_control): Likewise.
5384 (i386_get_debug_register_length): Likewise.
5385 * i386-low.c (i386_dr_low_can_set_addr): Now in i386-low.h.
5386 (i386_dr_low_can_set_control): Likewise.
5387 (i386_get_debug_register_length): Likewise.
5389 2014-06-17 Gary Benson <gbenson@redhat.com>
5391 * i386-low.h (i386-dregs.h): New include.
5392 (DR_FIRSTADDR): Now in i386-dregs.h.
5393 (DR_LASTADDR): Likewise.
5394 (DR_NADDR): Likewise.
5395 (DR_STATUS): Likewise.
5396 (DR_CONTROL): Likewise.
5397 (i386_debug_reg_state): Likewise.
5398 (i386_dr_insert_watchpoint): Likewise.
5399 (i386_dr_remove_watchpoint): Likewise.
5400 (i386_dr_region_ok_for_watchpoint): Likewise.
5401 (i386_dr_stopped_data_address): Likewise.
5402 (i386_dr_stopped_by_watchpoint): Likewise.
5403 * i386-low.c (ALL_DEBUG_REGISTERS): Likewise.
5405 2014-06-18 Gary Benson <gbenson@redhat.com>
5407 * i386-low.h (i386_low_insert_watchpoint): Renamed to
5408 i386_dr_insert_watchpoint.
5409 (i386_low_remove_watchpoint): Renamed to
5410 i386_dr_remove_watchpoint.
5411 (i386_low_region_ok_for_watchpoint): Renamed to
5412 i386_dr_region_ok_for_watchpoint.
5413 (i386_low_stopped_data_address): Renamed to
5414 i386_dr_stopped_data_address.
5415 (i386_low_stopped_by_watchpoint): Renamed to
5416 i386_dr_stopped_by_watchpoint.
5417 * i386-low.c (i386_show_dr): Renamed to
5418 i386_dr_show and made nonstatic. All uses updated.
5419 (i386_length_and_rw_bits): Renamed to
5420 i386_dr_length_and_rw_bits and made nonstatic.
5422 (i386_insert_aligned_watchpoint): Renamed to
5423 i386_dr_insert_aligned_watchpoint and made nonstatic.
5425 (i386_remove_aligned_watchpoint): Renamed to
5426 i386_dr_remove_aligned_watchpoint and made nonstatic.
5428 (i386_update_inferior_debug_regs): Renamed to
5429 i386_dr_update_inferior_debug_regs and made nonstatic.
5431 (i386_low_insert_watchpoint): Renamed to
5432 i386_dr_insert_watchpoint. All uses updated.
5433 (i386_low_remove_watchpoint): Renamed to
5434 i386_dr_remove_watchpoint. All uses updated.
5435 (i386_low_region_ok_for_watchpoint): Renamed to
5436 i386_dr_region_ok_for_watchpoint. All uses updated.
5437 (i386_low_stopped_data_address): Renamed to
5438 i386_dr_stopped_data_address. All uses updated.
5439 (i386_low_stopped_by_watchpoint): Renamed to
5440 i386_dr_stopped_by_watchpoint. All uses updated.
5442 2014-06-18 Gary Benson <gbenson@redhat.com>
5444 * i386-low.c (i386_dr_low_can_set_addr): New macro.
5445 (i386_dr_low_can_set_control): Likewise.
5446 (i386_insert_aligned_watchpoint): New check.
5448 2014-06-18 Gary Benson <gbenson@redhat.com>
5450 * i386-low.c (i386_update_inferior_debug_regs) <inf_state>:
5453 2014-06-18 Gary Benson <gbenson@redhat.com>
5455 * i386-low.c (i386_length_and_rw_bits): Use internal_error
5456 instead of fatal and error.
5457 (i386_handle_nonaligned_watchpoint): Likewise.
5459 2014-06-18 Gary Benson <gbenson@redhat.com>
5461 * i386-low.c (i386_get_debug_register_length): New macro.
5462 (TARGET_HAS_DR_LEN_8): Remove conditional. Use above macro.
5463 (i386_show_dr): Use debug_printf instead of fprintf. Use
5464 phex to format values.
5466 2014-06-18 Gary Benson <gbenson@redhat.com>
5468 * i386-low.h: Comment changes.
5469 * i386-low.c: Likewise.
5471 2014-06-18 Gary Benson <gbenson@redhat.com>
5473 * i386-low.c: Whitespace changes.
5475 2014-06-12 Tom Tromey <tromey@redhat.com>
5477 * utils.c (freeargv): Remove.
5479 2014-06-12 Tom Tromey <tromey@redhat.com>
5481 * debug.c (debug_printf): Remove HAVE_GETTIMEOFDAY checks.
5482 * server.c (monitor_show_help): Remove HAVE_GETTIMEOFDAY check.
5483 (parse_debug_format_options): Likewise.
5484 (gdbserver_usage): Likewise.
5485 * Makefile.in (LIBIBERTY_BUILDDIR, LIBIBERTY): New variables.
5486 (SUBDIRS, REQUIRED_SUBDIRS): Add libiberty.
5487 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Depend on and link
5489 ($(LIBGNU)): Depend on libiberty.
5490 (all-lib): Recurse into all subdirs.
5491 (install-only): Invoke "install" target in subdirs.
5492 (vasprintf.o, vsnprintf.o, safe-ctype.o, lbasename.o): Remove
5494 * configure: Rebuild.
5495 * configure.ac: Add ACX_CONFIGURE_DIR for libiberty. Don't check
5496 for vasprintf, vsnprintf, or gettimeofday.
5497 * configure.srv: Don't add safe-ctype.o or lbasename.o to
5500 2014-06-05 Joel Brobecker <brobecker@adacore.com>
5502 * development.sh: Delete.
5503 * Makefile.in (config.status): Adjust dependency on development.sh.
5504 * configure.ac: Adjust development.sh source call.
5505 * configure: Regenerate.
5507 2014-06-02 Pedro Alves <palves@redhat.com>
5509 * ax.c (gdb_free_agent_expr): New function.
5510 * ax.h (gdb_free_agent_expr): New declaration.
5511 * mem-break.c (delete_gdb_breakpoint_1): Also clear the commands
5513 (clear_breakpoint_conditions, clear_breakpoint_commands): Make
5515 (clear_breakpoint_conditions_and_commands): New function.
5516 * mem-break.h (clear_breakpoint_conditions): Delete declaration.
5517 (clear_breakpoint_conditions_and_commands): New declaration.
5519 2014-05-23 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
5521 * linux-aarch64-low.c (asm/ptrace.h): Include.
5523 2014-05-21 Jan Kratochvil <jan.kratochvil@redhat.com>
5525 Fix TLS access for -static -pthread.
5526 * gdbserver/thread-db.c (struct thread_db): Add td_thr_tlsbase_p.
5527 (thread_db_get_tls_address): Call it if LOAD_MODULE is zero.
5528 (thread_db_load_search, try_thread_db_load_1): Initialize it.
5530 2014-05-20 Pedro Alves <palves@redhat.com>
5532 * linux-aarch64-low.c (aarch64_insert_point)
5533 (aarch64_remove_point): No longer check whether the type is
5534 supported here. Adjust to new interface.
5535 (the_low_target): Install aarch64_supports_z_point_type as
5536 supports_z_point_type method.
5537 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type): New function.
5538 (arm_linux_hw_point_initialize): Take an enum raw_bkpt_type
5539 instead of a Z packet char. Adjust.
5540 (arm_supports_z_point_type): New function.
5541 (arm_insert_point, arm_remove_point): Adjust to new interface.
5542 (the_low_target): Install arm_supports_z_point_type.
5543 * linux-crisv32-low.c (cris_supports_z_point_type): New function.
5544 (cris_insert_point, cris_remove_point): Adjust to new interface.
5545 Don't check whether the type is supported here.
5546 (the_low_target): Install cris_supports_z_point_type.
5547 * linux-low.c (linux_supports_z_point_type): New function.
5548 (linux_insert_point, linux_remove_point): Adjust to new interface.
5549 * linux-low.h (struct linux_target_ops) <insert_point,
5550 remove_point>: Take an enum raw_bkpt_type instead of a char. Add
5551 raw_breakpoint pointer parameter.
5552 <supports_z_point_type>: New method.
5553 * linux-mips-low.c (mips_supports_z_point_type): New function.
5554 (mips_insert_point, mips_remove_point): Adjust to new interface.
5555 Use mips_supports_z_point_type.
5556 (the_low_target): Install mips_supports_z_point_type.
5557 * linux-ppc-low.c (the_low_target): Install NULL as
5558 supports_z_point_type method.
5559 * linux-s390-low.c (the_low_target): Install NULL as
5560 supports_z_point_type method.
5561 * linux-sparc-low.c (the_low_target): Install NULL as
5562 supports_z_point_type method.
5563 * linux-x86-low.c (x86_supports_z_point_type): New function.
5564 (x86_insert_point): Adjust to new insert_point interface. Use
5565 insert_memory_breakpoint. Adjust to new
5566 i386_low_insert_watchpoint interface.
5567 (x86_remove_point): Adjust to remove_point interface. Use
5568 remove_memory_breakpoint. Adjust to new
5569 i386_low_remove_watchpoint interface.
5570 (the_low_target): Install x86_supports_z_point_type.
5571 * lynx-low.c (lynx_target_ops): Install NULL as
5572 supports_z_point_type callback.
5573 * nto-low.c (nto_supports_z_point_type): New.
5574 (nto_insert_point, nto_remove_point): Adjust to new interface.
5575 (nto_target_ops): Install nto_supports_z_point_type.
5576 * mem-break.c: Adjust intro comment.
5577 (struct raw_breakpoint) <raw_type, size>: New fields.
5578 <inserted>: Update comment.
5579 <shlib_disabled>: Delete field.
5580 (enum bkpt_type) <gdb_breakpoint>: Delete value.
5581 <gdb_breakpoint_Z0, gdb_breakpoint_Z1, gdb_breakpoint_Z2,
5582 gdb_breakpoint_Z3, gdb_breakpoint_Z4>: New values.
5583 (raw_bkpt_type_to_target_hw_bp_type): New function.
5584 (find_enabled_raw_code_breakpoint_at): New function.
5585 (find_raw_breakpoint_at): New type and size parameters. Use them.
5586 (insert_memory_breakpoint): New function, based off
5587 set_raw_breakpoint_at.
5588 (remove_memory_breakpoint): New function.
5589 (set_raw_breakpoint_at): Reimplement.
5590 (set_breakpoint): New, based on set_breakpoint_at.
5591 (set_breakpoint_at): Reimplement.
5592 (delete_raw_breakpoint): Go through the_target->remove_point
5593 instead of assuming memory breakpoints.
5594 (find_gdb_breakpoint_at): Delete.
5595 (Z_packet_to_bkpt_type, Z_packet_to_raw_bkpt_type): New functions.
5596 (find_gdb_breakpoint): New function.
5597 (set_gdb_breakpoint_at): Delete.
5598 (z_type_supported): New function.
5599 (set_gdb_breakpoint_1): New function, loosely based off
5600 set_gdb_breakpoint_at.
5601 (check_gdb_bp_preconditions, set_gdb_breakpoint): New functions.
5602 (delete_gdb_breakpoint_at): Delete.
5603 (delete_gdb_breakpoint_1): New function, loosely based off
5604 delete_gdb_breakpoint_at.
5605 (delete_gdb_breakpoint): New function.
5606 (clear_gdb_breakpoint_conditions): Rename to ...
5607 (clear_breakpoint_conditions): ... this. Don't handle a NULL
5609 (add_condition_to_breakpoint): Make static.
5610 (add_breakpoint_condition): Take a struct breakpoint pointer
5611 instead of an address. Adjust.
5612 (gdb_condition_true_at_breakpoint): Rename to ...
5613 (gdb_condition_true_at_breakpoint_z_type): ... this, and add
5615 (gdb_condition_true_at_breakpoint): Reimplement.
5616 (add_breakpoint_commands): Take a struct breakpoint pointer
5617 instead of an address. Adjust.
5618 (gdb_no_commands_at_breakpoint): Rename to ...
5619 (gdb_no_commands_at_breakpoint_z_type): ... this. Add z_type
5620 parameter. Return true if no breakpoint was found. Change debug
5622 (gdb_no_commands_at_breakpoint): Reimplement.
5623 (run_breakpoint_commands): Rename to ...
5624 (run_breakpoint_commands_z_type): ... this. Add z_type parameter,
5625 and change return type to boolean.
5626 (run_breakpoint_commands): New function.
5627 (gdb_breakpoint_here): Also check for Z1 breakpoints.
5628 (uninsert_raw_breakpoint): Don't try to reinsert a disabled
5629 breakpoint. Go through the_target->remove_point instead of
5630 assuming memory breakpoint.
5631 (uninsert_breakpoints_at, uninsert_all_breakpoints): Uninsert
5632 software and hardware breakpoints.
5633 (reinsert_raw_breakpoint): Go through the_target->insert_point
5634 instead of assuming memory breakpoint.
5635 (reinsert_breakpoints_at, reinsert_all_breakpoints): Reinsert
5636 software and hardware breakpoints.
5637 (check_breakpoints, breakpoint_here, breakpoint_inserted_here):
5638 Check both software and hardware breakpoints.
5639 (validate_inserted_breakpoint): Assert the breakpoint is a
5640 software breakpoint. Set the inserted flag to -1 instead of
5641 setting shlib_disabled.
5642 (delete_disabled_breakpoints): Adjust.
5643 (validate_breakpoints): Only validate software breakpoints.
5644 Adjust to inserted flag change.
5645 (check_mem_read, check_mem_write): Skip breakpoint types other
5646 than software breakpoints. Adjust to inserted flag change.
5647 * mem-break.h (enum raw_bkpt_type): New enum.
5648 (raw_breakpoint, struct process_info): Forward declare.
5649 (Z_packet_to_target_hw_bp_type): Delete declaration.
5650 (raw_bkpt_type_to_target_hw_bp_type, Z_packet_to_raw_bkpt_type)
5651 (set_gdb_breakpoint, delete_gdb_breakpoint)
5652 (clear_breakpoint_conditions): New declarations.
5653 (set_gdb_breakpoint_at, clear_gdb_breakpoint_conditions): Delete.
5654 (breakpoint_inserted_here): Update comment.
5655 (add_breakpoint_condition, add_breakpoint_commands): Replace
5656 address parameter with a breakpoint pointer parameter.
5657 (gdb_breakpoint_here): Update comment.
5658 (delete_gdb_breakpoint_at): Delete.
5659 (insert_memory_breakpoint, remove_memory_breakpoint): Declare.
5660 * server.c (process_point_options): Take a struct breakpoint
5661 pointer instead of an address. Adjust.
5662 (process_serial_event) <Z/z packets>: Use set_gdb_breakpoint and
5663 delete_gdb_breakpoint.
5664 * spu-low.c (spu_target_ops): Install NULL as
5665 supports_z_point_type method.
5666 * target.h: Include mem-break.h.
5667 (struct target_ops) <prepare_to_access_memory>: Update comment.
5668 <supports_z_point_type>: New field.
5669 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
5670 instead of a char. Also take a raw breakpoint pointer.
5671 * win32-arm-low.c (the_low_target): Install NULL as
5672 supports_z_point_type.
5673 * win32-i386-low.c (i386_supports_z_point_type): New function.
5674 (i386_insert_point, i386_remove_point): Adjust to new interface.
5675 (the_low_target): Install i386_supports_z_point_type.
5676 * win32-low.c (win32_supports_z_point_type): New function.
5677 (win32_insert_point, win32_remove_point): Adjust to new interface.
5678 (win32_target_ops): Install win32_supports_z_point_type.
5679 * win32-low.h (struct win32_target_ops):
5680 <supports_z_point_type>: New method.
5681 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
5682 instead of a char. Also take a raw breakpoint pointer.
5684 2014-05-20 Pedro Alves <palves@redhat.com>
5686 * mem-break.h: Include break-common.h.
5687 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
5688 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): New defines.
5689 (Z_packet_to_target_hw_bp_type): New declaration.
5690 * mem-break.c (Z_packet_to_target_hw_bp_type): New function.
5691 * i386-low.c (Z_PACKET_HW_BP, Z_PACKET_WRITE_WP, Z_PACKET_READ_WP)
5692 (Z_PACKET_ACCESS_WP): Delete macros.
5693 (Z_packet_to_hw_type): Delete function.
5694 * i386-low.h: Don't include break-common.h here.
5695 (Z_packet_to_hw_type): Delete declaration.
5696 * linux-x86-low.c (x86_insert_point, x86_insert_point): Call
5697 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
5698 * win32-i386-low.c (i386_insert_point, i386_remove_point): Call
5699 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
5700 * linux-aarch64-low.c: Don't include break-common.h here.
5701 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
5702 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): Delete macros.
5703 (Z_packet_to_target_hw_bp_type): Delete function.
5704 * linux-mips-low.c (rsp_bp_type_to_target_hw_bp_type): Delete
5706 (mips_insert_point, mips_remove_point): Use
5707 Z_packet_to_target_hw_bp_type.
5709 2014-05-20 Pedro Alves <palves@redhat.com>
5711 * linux-aarch64-low.c: Include break-common.h.
5712 (enum target_point_type): Delete.
5713 (Z_packet_to_point_type): Rename to ...
5714 (Z_packet_to_target_hw_bp_type): ... this, and return a
5715 target_hw_bp_type instead.
5716 (aarch64_show_debug_reg_state): Take an enum target_hw_bp_type
5717 instead of an enum target_point_type.
5718 (aarch64_point_encode_ctrl_reg): Likewise. Compute type mask from
5720 (aarch64_dr_state_insert_one_point)
5721 (aarch64_dr_state_remove_one_point, aarch64_handle_breakpoint)
5722 (aarch64_handle_aligned_watchpoint)
5723 (aarch64_handle_unaligned_watchpoint, aarch64_handle_watchpoint):
5724 Take an enum target_hw_bp_type instead of an enum
5726 (aarch64_supports_z_point_type): New function.
5727 (aarch64_insert_point, aarch64_remove_point): Use it. Adjust to
5728 use Z_packet_to_target_hw_bp_type.
5730 2014-05-20 Joel Brobecker <brobecker@adacore.com>
5732 * configure.ac: Only use -Werror by default when DEVELOPMENT
5734 * configure: Regenerate.
5736 2014-05-19 Jan Kratochvil <jan.kratochvil@redhat.com>
5738 Fix gdbserver qGetTLSAddr for x86_64 -m32.
5739 * linux-x86-low.c (X86_64_USER_REGS): New.
5740 (x86_fill_gregset): Call memset for BUF first in x86_64 -m32 case.
5742 2014-04-28 Yao Qi <yao@codesourcery.com>
5744 * Makefile.in (i386-avx512.c): Fix the typo of generated file
5747 2014-04-25 Pedro Alves <palves@redhat.com>
5750 * linux-low.c (linux_attach_fail_reason_string): New function.
5751 (linux_attach_lwp): Delete.
5752 (linux_attach_lwp_1): Rename to ...
5753 (linux_attach_lwp): ... this. Take a ptid instead of a pid as
5754 argument. Remove "initial" parameter. Return int instead of
5755 void. Don't error or warn here.
5756 (linux_attach): Adjust to call linux_attach_lwp. Call error on
5757 failure to attach to the tgid. Call warning when failing to
5759 * linux-low.h (linux_attach_lwp): Take a ptid instead of a pid as
5760 argument. Remove "initial" parameter. Return int instead of
5761 void. Don't error or warn here.
5762 (linux_attach_fail_reason_string): New declaration.
5763 * thread-db.c (attach_thread): Adjust to linux_attach_lwp's
5764 interface change. Use linux_attach_fail_reason_string.
5766 2014-04-24 Michael Sturm <michael.sturm@mintel.com>
5767 Walfred Tedeschi <walfred.tedeschi@intel.com>
5769 * Makefile.in: Added rules to handle new files
5770 i386-avx512.c i386-avx512-linux.c amd64-avx512.c
5771 amd64-avx512-linux.c x32-avx512.c x32-avx512-linux.c.
5772 * configure.srv (srv_i386_regobj): Add i386-avx512.o.
5773 (srv_i386_linux_regobj): Add i386-avx512-linux.o.
5774 (srv_amd64_regobj): Add amd64-avx512.o and x32-avx512.o.
5775 (srv_amd64_linux_regobj): Add amd64-avx512-linux.o and
5777 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx512.xml.
5778 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx512.xml.
5779 (srv_amd64_xmlfiles): Add i386/amd64-avx512.xml and
5780 i386/x32-avx512.xml.
5781 (srv_i386_linux_xmlfiles): Add i386/i386-avx512-linux.xml.
5782 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx512-linux.xml and
5783 i386/x32-avx512-linux.xml.
5784 * i387-fp.c (num_avx512_k_registers): New constant for number
5786 (num_avx512_zmmh_low_registers): New constant for number of
5787 lower ZMM registers (0-15).
5788 (num_avx512_zmmh_high_registers): New constant for number of
5789 higher ZMM registers (16-31).
5790 (num_avx512_ymmh_registers): New contant for number of higher
5791 YMM registers (ymm16-31 added by avx521 on x86_64).
5792 (num_avx512_xmm_registers): New constant for number of higher
5793 XMM registers (xmm16-31 added by AVX512 on x86_64).
5794 (struct i387_xsave): Add space for AVX512 registers.
5795 (i387_cache_to_xsave): Change raw buffer size to 64 characters.
5796 Add code to handle AVX512 registers.
5797 (i387_xsave_to_cache): Add code to handle AVX512 registers.
5798 * linux-x86-low.c (init_registers_amd64_avx512_linux): New
5799 prototypei from generated file.
5800 (tdesc_amd64_avx512_linux): Likewise.
5801 (init_registers_x32_avx512_linux): Likewise.
5802 (tdesc_x32_avx512_linux): Likewise.
5803 (init_registers_i386_avx512_linux): Likewise.
5804 (tdesc_i386_avx512_linux): Likewise.
5805 (x86_64_regmap): Add AVX512 registers.
5806 (x86_linux_read_description): Add code to handle AVX512 XSTATE
5808 (initialize_low_arch): Add code to initialize AVX512 registers.
5810 2014-04-23 Pedro Alves <palves@redhat.com>
5812 * mem-break.c (find_gdb_breakpoint_at): Make static.
5813 * mem-break.h (find_gdb_breakpoint_at): Delete declaration.
5815 2014-04-23 Pedro Alves <palves@redhat.com>
5817 * i386-low.c: Don't include break-common.h here.
5818 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
5819 prototype to take target_hw_bp_type as argument instead of a Z
5821 * i386-low.h: Include break-common.h here.
5822 (Z_packet_to_hw_type): Declare.
5823 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
5825 * linux-x86-low.c (x86_insert_point): Convert the packet number to
5826 a target_hw_bp_type before calling i386_low_insert_watchpoint.
5827 (x86_remove_point): Convert the packet number to a
5828 target_hw_bp_type before calling i386_low_remove_watchpoint.
5829 * win32-i386-low.c (i386_insert_point): Convert the packet number
5830 to a target_hw_bp_type before calling i386_low_insert_watchpoint.
5831 (i386_remove_point): Convert the packet number to a
5832 target_hw_bp_type before calling i386_low_remove_watchpoint.
5834 2014-04-23 Pedro Alves <palves@redhat.com>
5836 * utils.h (perror_with_name): Add ATTRIBUTE_NORETURN.
5838 2014-04-10 Pedro Alves <palves@redhat.com>
5840 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
5841 Check if the condition or command is NULL before checking if the
5842 breakpoint is known. On success, return true.
5843 * mem-break.h (add_breakpoint_condition): Document return.
5844 (add_breakpoint_commands): Add describing comment.
5845 * server.c (skip_to_semicolon): New function.
5846 (process_point_options): Use it.
5848 2014-04-09 Pedro Alves <palves@redhat.com>
5850 * linux-low.c (linux_read_loadmap): Pass current_inferior directly
5853 2014-02-27 Pedro Alves <palves@redhat.com>
5856 * inferiors.h (A_I_NEXT, ALL_INFERIORS_TYPE, ALL_PROCESSES): New
5858 * linux-low.c (delete_lwp, handle_extended_wait): Add debug
5860 (last_thread_of_process_p): Take a PID argument instead of a
5862 (linux_wait_for_lwp): Delete.
5863 (num_lwps, check_zombie_leaders, not_stopped_callback): New
5865 (linux_low_filter_event): New function, party factored out from
5866 linux_wait_for_event.
5867 (linux_wait_for_event): Rename to ...
5868 (linux_wait_for_event_filtered): ... this. Add new filter ptid
5869 argument. Partly rewrite. Always use waitpid(-1, WNOHANG) and
5870 sigsuspend. Check for zombie leaders.
5871 (linux_wait_for_event): Reimplement as wrapper around
5872 linux_wait_for_event_filtered.
5873 (linux_wait_1): Handle TARGET_WAITKIND_NO_RESUMED. Assume that if
5874 a normal or signal exit is seen, it's the whole process exiting.
5875 (wait_for_sigstop): No longer a for_each_inferior callback.
5876 Rewrite on top of linux_wait_for_event_filtered.
5877 (stop_all_lwps): Call wait_for_sigstop directly.
5878 * server.c (resume, handle_target_event): Handle
5879 TARGET_WAITKIND_NO_RESUMED.
5881 2014-02-26 Joel Brobecker <brobecker@adacore.com>
5883 * win32-low.c (psapi_get_dll_name,
5884 * win32_CreateToolhelp32Snapshot): Delete.
5885 (win32_CreateToolhelp32Snapshot, win32_Module32First)
5886 (win32_Module32Next, load_toolhelp, toolhelp_get_dll_name):
5888 (handle_load_dll): Add function description.
5889 Remove code using psapi_get_dll_name and toolhelp_get_dll_name.
5891 2014-02-26 Joel Brobecker <brobecker@adacore.com>
5893 * win32-low.c (win32_add_one_solib): Add 0x1000 to load_addr.
5895 (win32_add_all_dlls): Remove 0x1000 offset applied to DLL
5896 base address when calling win32_add_one_solib.
5897 (handle_load_dll): Delete local variable load_addr.
5898 Remove 0x1000 offset applied to DLL base address when calling
5899 win32_add_one_solib.
5900 (handle_unload_dll): Add comment.
5902 2014-02-26 Joel Brobecker <brobecker@adacore.com>
5904 * win32-low.c (win32_add_all_dlls): Renames
5905 win32_ensure_ntdll_loaded. Rewrite function documentation.
5906 Adjust implementation to always load all DLLs.
5907 Add 0x1000 offset to DLL base address when calling
5908 win32_add_one_solib.
5909 (child_initialization_done): New static global.
5910 (do_initial_child_stuff): Set child_initialization_done to
5911 zero during child initialization, and 1 after. Replace call
5912 to win32_ensure_ntdll_loaded by call to win32_add_all_dlls.
5914 (match_dll_by_basename, dll_is_loaded_by_basename): Delete.
5915 (handle_unload_dll): Add function documentation.
5916 (get_child_debug_event): Ignore load and unload DLL events
5917 during child initialization.
5919 2014-02-20 Doug Evans <dje@google.com>
5921 Remove global all_lwps.
5922 * inferiors.h (ptid_of): Move here from linux-low.h.
5923 (pid_of, lwpid_of): Ditto.
5924 * linux-aarch64-low.c (debug_reg_change_callback): Update, "entry"
5925 parameter is a struct thread_info * now.
5926 (aarch64_notify_debug_reg_change): Fetch pid from current_inferior
5927 directly. Pass &all_threads to find_inferior instead of &all_lwps.
5928 (aarch64_stopped_data_address): Fetch lwpid from current_inferior
5930 (aarch64_linux_prepare_to_resume): Fetch ptid from thread.
5931 (aarch64_arch_setup): Fetch lwpid from current_inferior directly.
5932 * linux-arm-low.c (update_registers_callback): Update, "entry"
5933 parameter is a struct thread_info * now.
5934 Fetch lwpid from current_inferior directly.
5935 (arm_insert_point): Pass &all_threads to find_inferior instead of
5937 (arm_remove_point): Ditto.
5938 (arm_stopped_by_watchpoint): Fetch lwp from current_inferior.
5939 (arm_prepare_to_resume): Fetch pid from thread.
5940 (arm_read_description): Fetch lwpid from current_inferior directly.
5941 * linux-low.c (all_lwps): Delete.
5942 (delete_lwp): Delete call to remove_inferior.
5943 (handle_extended_wait): Fetch lwpid from thread.
5944 (add_lwp): Don't set lwp->entry.id. Remove call to
5945 add_inferior_to_list.
5946 (linux_attach_lwp_1): Fetch pid from current_inferior directly.
5947 (linux_kill_one_lwp): Fetch ptid,lwpid from thread.
5948 (kill_one_lwp_callback): Ditto.
5949 (linux_kill): Don't dereference NULL pointer.
5950 Fetch ptid,lwpid from thread.
5951 (get_detach_signal): Fetch ptid from thread.
5952 (linux_detach_one_lwp): Fetch ptid,lwpid from thread.
5953 Simplify call to regcache_invalidate_thread.
5954 (delete_lwp_callback): Update, "entry" parameter is a
5955 struct thread_info * now. Fetch pid from thread.
5956 (linux_mourn): Pass &all_threads to find_inferior instead of &all_lwps.
5957 (status_pending_p_callback): Update, "entry" parameter is a
5958 struct thread_info * now. Fetch ptid from thread.
5959 (find_lwp_pid): Update, "entry" parameter is a
5960 struct thread_info * now.
5961 (linux_wait_for_lwp): Fetch pid from thread.
5962 (linux_fast_tracepoint_collecting): Fetch lwpid from thread.
5963 (maybe_move_out_of_jump_pad): Fetch lwpid from current_inferior.
5964 (enqueue_one_deferred_signal): Fetch lwpid from thread.
5965 (dequeue_one_deferred_signal): Ditto.
5966 (cancel_breakpoint): Fetch ptid from current_inferior.
5967 (linux_wait_for_event): Pass &all_threads to find_inferior,
5968 not &all_lwps. Fetch ptid, lwpid from thread.
5969 (count_events_callback): Update, "entry" parameter is a
5970 struct thread_info * now.
5971 (select_singlestep_lwp_callback): Ditto.
5972 (select_event_lwp_callback): Ditto.
5973 (cancel_breakpoints_callback): Ditto.
5974 (linux_cancel_breakpoints): Pass &all_threads to find_inferior,
5976 (select_event_lwp): Ditto. Fetch ptid from event_thread.
5977 (unsuspend_one_lwp): Update, "entry" parameter is a
5978 struct thread_info * now.
5979 (unsuspend_all_lwps): Pass &all_threads to find_inferior,
5981 (linux_stabilize_threads): Ditto. And for for_each_inferior.
5982 Fetch lwpid from thread, not lwp.
5983 (linux_wait_1): Fetch ptid, lwpid from current_inferior.
5984 Pass &all_threads to find_inferior, not &all_lwps.
5985 (send_sigstop): Fetch lwpid from thread, not lwp.
5986 (send_sigstop_callback): Update, "entry" parameter is a
5987 struct thread_info * now.
5988 (suspend_and_send_sigstop_callback): Ditto.
5989 (wait_for_sigstop): Ditto. Fetch ptid, lwpid from thread, lwp.
5990 (stuck_in_jump_pad_callback): Update, "entry" parameter is a
5991 struct thread_info * now.
5992 (move_out_of_jump_pad_callback): Ditto. Fetch ptid, lwpid
5994 (lwp_running): Update, "entry" parameter is a
5995 struct thread_info * now.
5996 (stop_all_lwps): Fetch ptid from thread.
5997 Pass &all_threads to find_inferior, for_each_inferior, not &all_lwps.
5998 (linux_resume_one_lwp): Fetch lwpid from thread.
5999 (linux_set_resume_request): Update, "entry" parameter is a
6000 struct thread_info * now. Fetch pid, lwpid from thread.
6001 (resume_status_pending_p): Update, "entry" parameter is a
6002 struct thread_info * now.
6003 (need_step_over_p): Ditto. Fetch lwpid from thread.
6004 (start_step_over): Fetch lwpid from thread.
6005 (linux_resume_one_thread): Update, "entry" parameter is a
6006 struct thread_info * now. Fetch lwpid from thread.
6007 (linux_resume): Pass &all_threads to find_inferior, not &all_lwps.
6008 (proceed_one_lwp): Update, "entry" parameter is a
6009 struct thread_info * now. Fetch lwpid from thread.
6010 (unsuspend_and_proceed_one_lwp): Update, "entry" parameter is a
6011 struct thread_info * now.
6012 (proceed_all_lwps): Pass &all_threads to find_inferior, not &all_lwps.
6013 (unstop_all_lwps): Ditto. Fetch lwpid from thread.
6014 (regsets_fetch_inferior_registers): Fetch lwpid from current_inferior
6016 (regsets_store_inferior_registers): Ditto.
6017 (fetch_register, store_register): Ditto.
6018 (linux_read_memory, linux_write_memory): Ditto.
6019 (linux_request_interrupt): Ditto.
6020 (linux_read_auxv): Ditto.
6021 (linux_xfer_siginfo): Ditto.
6022 (linux_qxfer_spu): Ditto.
6023 (linux_qxfer_libraries_svr4): Ditto.
6024 * linux-low.h (ptid_of, pid_of, lwpid_of): Delete,
6025 moved to inferiors.h.
6027 (get_thread_lwp): Update.
6028 (struct lwp_info): Delete member "entry". Simplify comment for
6031 * linux-mips-low.c (mips_read_description): Fetch lwpid from
6032 current_inferior directly.
6033 (update_watch_registers_callback): Update, "entry" parameter is a
6034 struct thread_info * now. Fetch pid from thread.
6035 (mips_linux_prepare_to_resume): Fetch ptid from thread.
6036 (mips_insert_point): Fetch lwpid from current_inferior.
6037 Pass &all_threads to find_inferior, not &all_lwps.
6038 (mips_remove_point): Pass &all_threads to find_inferior, not &all_lwps.
6039 (mips_stopped_by_watchpoint): Fetch lwpid from current_inferior
6041 (mips_stopped_data_address): Ditto.
6042 * linux-s390-low.c (s390_arch_setup): Fetch pid from current_inferior
6044 * linux-tile-low.c (tile_arch_setup): Ditto.
6045 * linux-x86-low.c (x86_get_thread_area): Fetch lwpid from thread.
6046 (update_debug_registers_callback): Update, "entry" parameter is a
6047 struct thread_info * now. Fetch pid from thread.
6048 (i386_dr_low_set_addr): Fetch pid from current_inferior directly.
6049 Pass &all_threads to find_inferior, not &all_lwps.
6050 (i386_dr_low_get_addr): Fetch ptid from current_inferior directly.
6051 (i386_dr_low_set_control): Fetch pid from current_inferior directly.
6052 Pass &all_threads to find_inferior, not &all_lwps.
6053 (i386_dr_low_get_control): Fetch ptid from current_inferior directly.
6054 (i386_dr_low_get_status): Ditto.
6055 (x86_linux_prepare_to_resume): Fetch ptid from thread.
6056 (x86_siginfo_fixup): Fetch lwpid from current_inferior directly.
6057 (x86_linux_read_description): Ditto.
6058 * proc-service.c (ps_getpid): Fetch pid from current_inferior directly.
6060 2014-02-20 Doug Evans <dje@google.com>
6062 * inferiors.c (get_first_inferior): Fix buglet.
6064 2014-02-19 Doug Evans <dje@google.com>
6066 * gdbthread.h (add_thread): Change result type to struct thread_info *.
6067 * inferiors.c (add_thread): Change result type to struct thread_info *.
6068 All callers updated.
6069 (add_lwp): Call add_thread here instead of in callers.
6070 All callers updated.
6071 * linux-low.h (get_lwp_thread): Rewrite.
6072 (struct lwp_info): New member "thread".
6074 2014-02-19 Doug Evans <dje@google.com>
6076 * linux-low.c (add_lwp): Change result to struct lwp_info *.
6077 All callers updated.
6079 2014-02-19 Doug Evans <dje@google.com>
6081 * inferiors.c (add_thread): Fix whitespace.
6083 2014-02-19 Doug Evans <dje@google.com>
6085 * dll.c (clear_dlls): Replace accessing list implemention details
6087 * gdbthread.h (get_first_thread): Declare.
6088 * inferiors.c (for_each_inferior_with_data): New function.
6089 (get_first_thread): New function.
6090 (find_thread_ptid): Simplify.
6091 (get_first_inferior): New function.
6092 (clear_list): Delete.
6093 (one_inferior_p): New function.
6094 (clear_inferior_list): New function.
6095 (clear_inferiors): Update.
6096 * inferiors.h (for_each_inferior_with_data): Declare.
6097 (clear_inferior_list): Declare.
6098 (one_inferior_p): Declare.
6099 (get_first_inferior): Declare.
6100 * linux-low.c (linux_wait_for_event): Replace accessing list
6101 implemention details with API function.
6102 * server.c (target_running): Ditto.
6103 (accumulate_file_name_length): New function.
6104 (emit_dll_description): New function.
6105 (handle_qxfer_libraries): Replace accessing list implemention
6106 details with API function.
6107 (handle_qxfer_threads_worker): New function.
6108 (handle_qxfer_threads_proper): Replace accessing list implemention
6109 details with API function.
6110 (handle_query): Ditto.
6111 (visit_actioned_threads_callback_ftype): New typedef.
6112 (visit_actioned_threads_data): New struct.
6113 (visit_actioned_threads): Rewrite to be find_inferior callback.
6114 (resume): Call find_inferior.
6115 (handle_status): Replace accessing list implemention
6116 details with API function.
6117 (process_serial_event): Replace accessing list implemention details
6119 * target.c (set_desired_inferior): Replace accessing list implemention
6120 details with API function.
6121 * tracepoint.c (same_process_p): New function.
6122 (gdb_agent_about_to_close): Replace accessing list implemention
6123 details with API function.
6124 * win32-low.c (child_delete_thread): Replace accessing list
6125 implemention details with API function.
6126 (match_dll_by_basename): New function.
6127 (dll_is_loaded_by_basename): New function.
6128 (win32_ensure_ntdll_loaded): Replace accessing list implemention
6129 details call to dll_is_loaded_by_basename.
6131 2014-02-19 Doug Evans <dje@google.com>
6133 * dll.h (struct dll_info): Add comment.
6134 * gdbthread.h (struct thread_info): Add comment.
6135 (current_ptid): Simplify.
6136 * inferiors.c (add_process): Update.
6137 (remove_process): Update.
6138 * inferiors.h (struct process_info): Rename member "head" to "entry".
6139 * linux-low.c (delete_lwp): Update.
6141 (last_thread_of_process_p): Update.
6142 (kill_one_lwp_callback, linux_kill): Update.
6143 (status_pending_p_callback): Update.
6144 (wait_for_sigstop): Update. Simplify read of ptid.
6145 (start_step_over): Update.
6146 * linux-low.h (ptid_of, pid_of, lwpid_of): Update.
6147 (get_lwp_thread): Update.
6148 (struct lwp_info): Rename member "head" to "entry".
6149 * regcache.h (inferior_list_entry): Delete.
6150 * server.c (kill_inferior_callback): Update.
6151 (detach_or_kill_inferior_callback): Update.
6152 (print_started_pid): Update.
6153 (print_attached_pid): Update.
6154 (process_serial_event): Simplify read of ptid.
6155 * thread-db.c (thread_db_create_event): Update.
6156 (thread_db_get_tls_address): Update.
6157 * win32-low.c (current_inferior_ptid): Simplify.
6159 2014-02-19 Tom Tromey <tromey@redhat.com>
6161 * target.h (struct target_ops) <supports_btrace>: Add target_ops
6163 (target_supports_btrace): Update.
6165 2014-02-14 Yao Qi <yao@codesourcery.com>
6167 * Makefile.in (IPA_OBJS): Append rsp-low-ipa.o.
6168 (rsp-low-ipa.o): New target.
6170 2014-02-12 Tom Tromey <tromey@redhat.com>
6172 * ax.c (gdb_parse_agent_expr): Use hex2bin, not
6173 convert_ascii_to_int.
6174 * regcache.c (registers_to_string): Likewise.
6175 * remote-utils.c (decode_M_packet): Likewise.
6176 * server.c (process_serial_event): Likewise.
6178 2014-02-12 Tom Tromey <tromey@redhat.com>
6180 * server.c (handle_query, handle_v_run): Use hex2bin, not
6182 * tracepoint.c (cmd_qtdpsrc, cmd_qtdv, cmd_qtnotes): Likewise.
6184 2014-02-12 Tom Tromey <tromey@redhat.com>
6186 * ax.c (gdb_unparse_agent_expr): Use bin2hex, not
6187 convert_int_to_ascii.
6188 * regcache.c (registers_to_string, collect_register_as_string):
6190 * remote-utils.c (look_up_one_symbol, relocate_instruction):
6192 * server.c (process_serial_event): Likewise.
6193 * tracepoint.c (cmd_qtstatus, response_source, response_tsv)
6194 (cmd_qtbuffer, cstr_to_hexstr): Likewise.
6196 2014-02-12 Tom Tromey <tromey@redhat.com>
6198 * remote-utils.c (look_up_one_symbol, monitor_output): Use
6199 bin2hex, not hexify.
6200 * tracepoint.c (cmd_qtstatus): Likewise.
6202 2014-02-12 Tom Tromey <tromey@redhat.com>
6204 * remote-utils.c (monitor_output): Pass explicit length to
6207 2014-02-12 Tom Tromey <tromey@redhat.com>
6209 * tracepoint.c: Include rsp-low.h.
6210 * server.c: Include rsp-low.h.
6211 * remote-utils.h (convert_ascii_to_int, convert_int_to_ascii)
6212 (unhexify, hexify, remote_escape_output, unpack_varlen_hex): Don't
6214 * remote-utils.c: Include rsp-low.h.
6215 (fromhex, hexchars, ishex, unhexify, tohex, hexify)
6216 (remote_escape_output, remote_unescape_input, unpack_varlen_hex)
6217 (convert_int_to_ascii, convert_ascii_to_int): Move to
6219 * regcache.c: Include rsp-low.h.
6220 * ax.c: Include rsp-low.h.
6221 * Makefile.in (SFILES): Add common/rsp-low.c.
6222 (OBS): Add rsp-low.o.
6223 (rsp-low.o): New target.
6225 2014-02-12 Tom Tromey <tromey@redhat.com>
6227 * utils.h (pulongest, plongest, phex_nz): Don't declare.
6228 Include print-utils.h.
6229 * utils.c (NUMCELLS, CELLSIZE, get_cell, decimal2str, pulongest)
6230 (plongest, thirty_two, phex_nz): Remove.
6231 * Makefile.in (SFILES): Add common/print-utils.c.
6232 (OBS): Add print-utils.o.
6233 (print-utils-ipa.o): New target.
6234 (print-utils.o): New target.
6235 (IPA_OBJS): Add print-utils-ipa.o.
6237 2014-02-06 Tom Tromey <tromey@redhat.com>
6239 * Makefile.in (SFILES): Fix indentation.
6241 2014-02-05 Doug Evans <dje@google.com>
6243 * linux-low.c (linux_wait_for_event): Improve comment.
6244 (linux_wait_1): Keep current_inferior in sync with event_child.
6246 2014-01-22 Doug Evans <dje@google.com>
6248 * gdbthread.h (gdb_id_to_thread): Delete, unused.
6250 2014-01-22 Doug Evans <dje@google.com>
6252 * configure.ac (AC_CHECK_FUNCS): Add test for gettimeofday.
6253 * configure: Regenerate.
6254 * config.in: Regenerate.
6255 * Makefile.in (SFILES): Add debug.c.
6257 * debug.c: New file.
6258 * debug.h: New file.
6259 * linux-aarch64-low.c (*): Update all debugging printfs to use
6260 debug_printf instead of fprintf.
6261 * linux-arm-low.c (*): Ditto.
6262 * linux-cris-low.c (*): Ditto.
6263 * linux-crisv32-low.c (*): Ditto.
6264 * linux-m32r-low.c (*): Ditto.
6265 * linux-sparc-low.c (*): Ditto.
6266 * linux-x86.c (*): Ditto.
6267 * linux-low.c (*): Ditto.
6268 (linux_wait_1): Add calls to debug_enter, debug_exit.
6269 (linux_wait): Remove redundant debugging printf.
6270 (stop_all_lwps): Add calls to debug_enter, debug_exit.
6271 (linux_resume, unstop_all_lwps): Ditto.
6272 * mem-break.c (*): Update all debugging printfs to use
6273 debug_printf instead of fprintf.
6274 * remote-utils.c (*): Ditto.
6275 * thread-db.c (*): Ditto.
6276 * server.c #include <ctype.h>, "gdb_vecs.h".
6277 (debug_threads): Moved to debug.c.
6278 (*): Update all debugging printfs to use debug_printf instead of
6280 (start_inferior): Replace call to fflush with call to debug_flush.
6281 (monitor_show_help): Mention set debug-format.
6282 (parse_debug_format_options): New function.
6283 (handle_monitor_command): Handle "monitor set debug-format".
6284 (gdbserver_usage): Mention --debug-format.
6285 (main): Parse --debug-format.
6286 * server.h (debug_threads): Declaration moved to debug.h.
6288 * tracepoint.c (trace_debug_1) [!IN_PROCESS_AGENT]: Add version of
6289 trace_debug_1 that uses debug_printf.
6290 (tracepoint_look_up_symbols): Update all debugging printfs to use
6291 debug_printf instead of fprintf.
6293 2014-01-20 Baruch Siach <baruch@tkos.co.il>
6295 * linux-xtensa-low.c: Include asm/ptrace.h instead of
6298 2014-01-17 Pedro Alves <palves@redhat.com>
6301 * linux-x86-low.c: Don't include elf/common.h if ELFMAG0 is
6302 defined after including gdb_proc_service.h.
6304 2014-01-16 Doug Evans <dje@google.com>
6306 * dll.c (UNSPECIFIED_CORE_ADDR): New macro.
6307 (match_dll): Use it.
6309 2014-01-16 Markus Metzger <markus.t.metzger@intel.com>
6311 * target.h (target_ops) <read_btrace>: Change parameters and
6312 return type to allow error reporting.
6313 * server.c (handle_qxfer_btrace): Support delta reads. Pass
6314 trace reading errors on.
6315 * linux-low.c (linux_low_read_btrace): Pass trace reading
6317 (linux_low_disable_btrace): New.
6319 2014-01-15 Doug Evans <dje@google.com>
6321 * inferiors.c (thread_id_to_gdb_id): Delete.
6322 * inferiors.h (thread_id_to_gdb_id): Delete.
6324 2014-01-13 Eli Zaretskii <eliz@gnu.org>
6326 * Makefile.in (INCLUDE_CFLAGS): Remove trailing slash from
6327 "-I$(srcdir)/../". Fixes MinGW compilation errors with old GCC
6330 2014-01-08 Pedro Alves <palves@redhat.com>
6332 * server.c (handle_status): Don't discard previous queued stop
6333 replies or thread's pending status here.
6334 (main) <disconnection>: Do it here instead.
6336 2014-01-08 Pedro Alves <palves@redhat.com>
6338 * gdbthread.h (struct thread_info) <status_pending_p>: New field.
6339 * server.c (visit_actioned_threads, handle_pending_status): New
6341 (handle_v_cont): Factor out parts to ...
6342 (resume): ... this new function. If in all-stop, and a thread
6343 being resumed has a pending status, report it without actually
6345 (myresume): Adjust to use the new 'resume' function.
6346 (clear_pending_status_callback, set_pending_status_callback)
6347 (find_status_pending_thread_callback): New functions.
6348 (handle_status): Handle the case of multiple threads having
6349 interesting statuses to report. Report threads' real last signal
6350 instead of always reporting GDB_SIGNAL_TRAP. Look for a thread
6351 with an interesting thread to report the status for, instead of
6352 always reporting the status of the first thread.
6354 2014-01-01 Joel Brobecker <brobecker@adacore.com>
6356 * gdbserver.c (gdbserver_version): Set copyright year to 2014.
6357 * gdbreplay.c (gdbreplay_version): Likewise.
6359 2013-12-18 Yufeng Zhang <yufeng.zhang@arm.com>
6361 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Set
6362 iov.iov_len with the real length in use.
6364 2013-12-13 Joel Brobecker <brobecker@adacore.com>
6366 * Makefile.in (safe-ctype.o, lbasename.o): New rules.
6367 * configure.srv: Add safe-ctype.o and lbasename.o to srv_tgtobj
6368 for all targets that use win32-low.c.
6369 * win32-low.c (win32_ensure_ntdll_loaded): New function.
6370 (do_initial_child_stuff): Add call to win32_ensure_ntdll_loaded.
6372 2013-12-13 Pedro Alves <palves@redhat.com>
6374 * target.c (mywait): Set OURSTATUS->KIND to TARGET_WAITKIND_STOPPED
6375 if equal to TARGET_WAITKIND_LOADED.
6376 * win32-low.c (cached_status): New static global.
6377 (win32_wait): Add declaration.
6378 (do_initial_child_stuff): Flush all initial pending debug events
6379 up to the initial breakpoint.
6380 (win32_wait): If CACHED_STATUS was set, return that instead
6381 of doing a real wait. Remove the code resuming the execution
6382 of the inferior after receiving a TARGET_WAITKIND_LOADED event
6383 during the initial phase. Also remove the code changing
6384 OURSTATUS->KIND from TARGET_WAITKIND_LOADED to
6385 TARGET_WAITKIND_STOPPED.
6387 2013-12-11 Yao Qi <yao@codesourcery.com>
6389 * notif.c (handle_notif_ack): Return 0 if no notification
6392 2013-11-20 Doug Evans <dje@google.com>
6394 * linux-low.c (linux_set_resume_request): Fix comment.
6396 2013-11-20 Doug Evans <dje@google.com>
6398 * linux-low.c (resume_status_pending_p): Tweak comment.
6400 2013-11-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
6402 * Makefile.in: Add i386-mpx.c, i386-mpx-linux.c, amd64-mpx.c,
6403 amd64-mpx-linux.c, x32-mpx.c and x32-mpx-linux.c generation.
6404 * configure.srv (srv_i386_regobj): Add i386-mpx.o.
6405 (srv_i386_linux_regobj): Add i386-mpx-linux.o.
6406 (srv_amd64_regobj): Add amd64-mpx.o.
6407 (srv_amd64_linux_regobj): Add amd64-mpx-linux.o.
6408 (srv_i386_32bit_xmlfiles): Add i386/32bit-mpx.xml.
6409 (srv_i386_64bit_xmlfiles): Add i386/64bit-mpx.xml.
6410 * i387-fp.c (num_pl_bnd_register) Added constant.
6411 (num_pl_bnd_cfg_registers) Added constant.
6412 (struct i387_xsave) Added reserved area and MPX fields.
6413 (i387_cache_to_xsave, i387_xsave_to_cache) Add MPX.
6414 * linux-x86-low.c (init_registers_i386_mpx_linux): Declare new
6416 (tdesc_i386_mpx_linux): Add MPX amd64 target.
6417 (init_registers_amd64_mpx_linux): Declare new function.
6418 (tdesc_amd64_mpx_linux): Add MPX amd64 target.
6419 (x86_64_regmap): Add MPX registers.
6420 (x86_linux_read_description): Add MPX case.
6421 (initialize_low_arch): Initialize MPX targets.
6423 2013-11-18 Tom Tromey <tromey@redhat.com>
6425 * configure: Rebuild.
6426 * configure.ac: Don't check for stdlib.h.
6427 * gdbreplay.c: Unconditionally include stdlib.h.
6429 2013-11-18 Tom Tromey <tromey@redhat.com>
6431 * config.in: Rebuild.
6432 * configure: Rebuild.
6433 * configure.ac: Don't use AC_HEADER_DIRENT.
6435 2013-11-18 Tom Tromey <tromey@redhat.com>
6437 * server.h: Don't check HAVE_STRING_H.
6438 * gdbreplay.c: Don't check HAVE_STRING_H.
6439 * configure: Rebuild.
6441 2013-11-18 Tom Tromey <tromey@redhat.com>
6443 * Makefile.in (gdbreplay$(EXEEXT)): Depend on and link against
6446 2013-11-08 Tom Tromey <tromey@redhat.com>
6448 * configure, config.in: Rebuild.
6449 * configure.ac: Remove unused configury.
6451 2013-11-08 Tom Tromey <tromey@redhat.com>
6453 * acinclude.m4: Include common.m4, codeset.m4.
6454 * configure, config.in: Rebuild.
6455 * configure.ac: Use GDB_AC_COMMON.
6457 2013-11-06 Andreas Arnez <arnez@linux.vnet.ibm.com>
6459 * linux-s390-low.c (HWCAP_S390_TE): New define.
6460 (s390_arch_setup): Consider the TE field in the HWCAP for
6461 determining 'have_regset_tdb'.
6463 2013-10-16 Sergio Durigan Junior <sergiodj@redhat.com>
6466 * tracepoint.c (download_tracepoint_1): Remove unnecessary double
6469 2013-10-02 Pedro Alves <palves@redhat.com>
6471 * server.c (process_serial_event): Don't output "GDBserver
6472 exiting" if GDB is connected through stdio.
6473 * target.c (mywait): Likewise, be silent if GDB is connected
6476 2013-10-01 Joel Brobecker <brobecker@adacore.com>
6478 * lynx-low.c (lynx_add_threads_after_attach): New function.
6479 (lynx_attach): Remove call to add_thread. Add call to
6480 lynx_add_threads_after_attach instead.
6482 2013-09-28 Mike Frysinger <vapier@gentoo.org>
6484 * configure.ac (AC_CHECK_HEADERS): Add sys/syscall.h
6485 * config.in, configure: Regenerated.
6487 2013-09-18 Yao Qi <yao@codesourcery.com>
6490 * server.c (start_inferior): Clear 'resume_info'.
6492 2013-09-16 Jiong Wang <jiwang@tilera.com>
6494 * linux-tile-low.c (tile_regsets): Modify the size field to 64-bit
6497 2013-09-16 Jiong Wang <jiwang@tilera.com>
6499 * configure.srv <tilegx*-*-linux*>: Remove linux-osdata.o from and add
6500 linux-tile-low.o to srv_tgtobj.
6502 2013-09-16 Will Newton <will.newton@linaro.org>
6504 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Zero
6507 2013-09-06 Pedro Alves <palves@redhat.com>
6509 * Makefile.in (gdb_proc_service_h, regdef_h, regcache_h)
6510 (signals_def, signals_h, ptid_h, ax_h, agent_h, linux_btrace_h)
6511 (linux_osdata_h, vec_h, gdb_vecs_h, host_defs_h, libiberty_h)
6512 (server_h, gdbthread_h, linux_low_h, linux_ptrace_h)
6513 (gdb_thread_db_h, linux_procfs_h, lynx_low_h, nto_low_h)
6514 (mips_linux_watch_h, i386_low_h, win32_low_h): Delete.
6516 2013-09-06 Pedro Alves <palves@redhat.com>
6518 * Makefile.in (linux-btrace.o, mips-linux-watch.o): Remove
6519 explicit header dependencies and use $COMPILE/$POSTCOMPILE.
6521 2013-09-06 Pedro Alves <palves@redhat.com>
6523 * linux-amd64-ipa.c: Include tracepoint.h.
6524 * linux-i386-ipa.c: Include tracepoint.h.
6526 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
6528 * linux-crisv32-low.c (PTRACE_GET_THREAD_AREA): New macro.
6529 (ps_get_thread_area): New function.
6531 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
6533 * linux-crisv32-low.c (elf_gregset_t): Delete typedef.
6534 (initialize_low_arch): Call init_registers_crisv32 rather than
6535 init_register_crisv32.
6537 2013-09-05 Pedro Alves <palves@redhat.com>
6539 * server.h (handle_vFile, hostio_last_error_from_errno): Move
6541 * hostio.h: ... this new file.
6542 * hostio.c, server.c, linux-low.c, nto-low.c, spu-low,
6543 win32-low.c: Include hostio.h.
6545 2013-09-05 Pedro Alves <palves@redhat.com>
6547 * server.h (gdb_client_data, handler_func, callback_handler_func)
6548 (delete_file_handler, add_file_handler, append_callback_event)
6549 (delete_callback_event, start_event_loop, initialize_event_loop):
6550 Move to event-loop.h and include it.
6551 * event-loop.h: New file.
6553 2013-09-05 Pedro Alves <palves@redhat.com>
6555 * dll.c, inferiors.c, remote-utils.c, server.c: Include "dll.h".
6556 * server.h (struct dll_info, all_dlls, dlls_changed, clear_dlls)
6557 (loaded_dll, unloaded_dll): Move to ...
6558 * dll.h: ... this new file.
6559 * inferiors.c, remote-utils.c, win32-low.c: Include "dll.h".
6561 2013-09-05 Pedro Alves <palves@redhat.com>
6563 * server.h (current_process, get_thread_process, all_processes)
6564 (add_inferior_to_list, for_each_inferior, current_inferior)
6565 (remove_inferior, add_process, remove_process, find_process_pid)
6566 (have_started_inferiors_p, have_attached_inferiors_p)
6567 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id)
6568 (clear_inferiors, find_inferior, find_inferior_id)
6569 (inferior_target_data, set_inferior_target_data)
6570 (inferior_regcache_data, set_inferior_regcache_data): Move to
6571 inferiors.h, and include it.
6572 * inferiors.h: New file.
6574 2013-09-05 Pedro Alves <palves@redhat.com>
6576 * server.h (struct emit_ops, current_insn_ptr, emit_error):
6580 2013-09-05 Pedro Alves <palves@redhat.com>
6582 * ax.c, linux-low.c, linux-x86-low.c, server.c: Include
6584 * server.h (IPA_BUFSIZ, initialize_tracepoint, tracing)
6585 (disconnected_tracing, tracepoint_look_up_symbols, stop_tracing
6586 (handle_tracepoint_general_set, handle_tracepoint_query)
6587 (tracepoint_finished_step, tracepoint_was_hit)
6588 (release_while_stepping_state_list, current_traceframe)
6589 (in_readonly_region, traceframe_read_mem)
6590 (fetch_traceframe_registers, traceframe_read_sdata)
6591 (traceframe_read_info, struct fast_tpoint_collect_status)
6592 (fast_tracepoint_collecting, force_unlock_trace_buffer)
6593 (handle_tracepoit_bkpts, initialize_low_tracepoint)
6594 (supply_fast_tracepoint_registers)
6595 (supply_static_tracepoint_registers, set_trampoline_buffer_space)
6596 (ipa_tdesc, claim_trampoline_space)
6597 (have_fast_tracepoint_trampoline_buffer, gdb_agent_about_to_close)
6598 (agent_mem_read, agent_get_trace_state_variable_value)
6599 (agent_set_trace_state_variable_value, agent_tsv_read)
6600 (agent_mem_read_string, get_raw_reg_func_addr)
6601 (get_get_tsv_func_addr, get_set_tsv_func_addr): Move to ...
6602 * tracepoint.h: ... this new file.
6604 2013-09-05 Pedro Alves <palves@redhat.com>
6606 * server.h (perror_with_name, error, fatal, warning, paddress)
6607 (pulongest, plongest, phex_nz, pfildes): Move to utils.h, and
6609 * utils.h: New file.
6611 2013-09-05 Pedro Alves <palves@redhat.com>
6613 * server.h (remote_debug, noack_mode, transport_is_reliable)
6614 (gdb_connected, STDIO_CONNECTION_NAME, remote_connection_is_stdio)
6615 (read_ptid, write_ptid, putpkt, putpkt_binary, putpkt_notif)
6616 (getpkt, remote_prepare, remote_open, remote_close, write_ok)
6617 (write_enn, initialize_async_io, enable_async_io)
6618 (disable_async_io, check_remote_input_interrupt_request)
6619 (convert_ascii_to_int, convert_int_to_ascii, new_thread_notify)
6620 (dead_thread_notify, prepare_resume_reply)
6621 (decode_address_to_semicolon, decode_address, decode_m_packet)
6622 (decode_M_packet, decode_X_packet, decode_xfer_write)
6623 (decode_search_memory_packet, unhexify, hexify)
6624 (remote_escape_output, unpack_varlen_hex, clear_symbol_cache)
6625 (look_up_one_symbol, relocate_instruction)
6626 (monitor_output): Move to remote-utils.h, and include it.
6627 * remote-utils.h: New file.
6629 2013-09-05 Pedro Alves <palves@redhat.com>
6631 * server.h (_): Delete.
6633 2013-09-02 Pedro Alves <palves@redhat.com>
6635 * tracepoint.c (TRACEFRAME_EOB_MARKER_SIZE): New macro.
6636 (init_trace_buffer): Ensure at least TRACEFRAME_EOB_MARKER_SIZE is
6638 (trace_buffer_alloc): Use TRACEFRAME_EOB_MARKER_SIZE.
6640 2013-09-02 Pierre Muller <muller@sourceware.org>
6642 * win32-low.c (child_xfer_memory): Check if ReadProcessMemory
6643 or WriteProcessMemory complete successfully and handle
6644 ERROR_PARTIAL_COPY error.
6646 2013-09-02 Pedro Alves <palves@redhat.com>
6648 * server.c (gdb_read_memory): Return -1 on traceframe memory read
6649 error instead of EIO.
6651 2013-08-28 Jan Kratochvil <jan.kratochvil@redhat.com>
6654 * linux-low.c: Include filestuff.h.
6655 (linux_create_inferior) <pid == 0>: Call close_most_fds.
6656 * lynx-low.c: Include filestuff.h.
6657 (lynx_create_inferior) <pid == 0>: Call close_most_fds.
6658 * server.c: Include filestuff.h.
6659 (main): Call notice_open_fds.
6660 * spu-low.c: Include filestuff.h.
6661 (spu_create_inferior) <pid == 0>: Call close_most_fds.
6663 2013-08-22 Luis Machado <lgustavo@codesourcery.com>
6665 * Makefile.in: Explain why ../target and ../nat are not
6666 listed as include file search paths.
6667 (linux-waitpid.o): New object file rule.
6668 * configure.srv (srv_native_linux_obj): New variable.
6669 Replace all occurrences of linux native object files with
6670 $srv_native_linux_obj.
6671 * linux-low.c: Include nat/linux-nat.h and nat/linux-waitpid.h.
6672 (HAS_NOMMU): Move defining logic to common/linux-ptrace.c.
6673 (linux_enable_event_reporting): Remove declaration.
6674 (my_waitpid): Moved to common/linux-waitpid.c.
6675 (linux_wait_for_event): Pass ptid when calling
6676 linux_enable_event_reporting.
6677 (linux_supports_tracefork_flag): Remove.
6678 (linux_enable_event_reporting): Likewise.
6679 (linux_tracefork_grandchild): Remove.
6680 (STACK_SIZE): Moved to common/linux-ptrace.c.
6681 (linux_tracefork_child): Remove.
6682 (linux_test_for_tracefork): Remove.
6683 (linux_look_up_symbols): Call linux_supports_traceclone.
6684 (initialize_low): Remove call to linux_test_for_tracefork.
6685 * linux-low.h (PTRACE_TYPE_ARG3): Move to
6686 common/linux-ptrace.h.
6687 (PTRACE_TYPE_ARG4): Likewise.
6688 Include linux-ptrace.h.
6690 2013-08-21 Pedro Alves <palves@redhat.com>
6692 * config.in: Renegerate.
6694 2013-08-19 Luis Machado <lgustavo@codesourcery.com>
6696 * Makefile.in (INCLUDE_CFLAGS): Include -I$(srcdir)/../.
6697 (SFILES): Remove $(srcdir)/common/target-common.c and
6698 add $(srcdir)/target/waitstatus.c.
6699 (OBS): Remove target-common.o and add waitstatus.o.
6700 (server_h): Remove $(srcdir)/../common/target-common.h and
6701 add $(srcdir)/../target/resume.h, $(srcdir)/../target/wait.h
6702 and $(srcdir)/../target/waitstatus.h.
6703 (target-common.o): Remove.
6704 (waitstatus.o): New target object file.
6705 * target.h: Do not include target-common.h and
6706 include target/resume.h, target/wait.h and
6707 target/waitstatus.h.
6709 2013-08-13 Luis Machado <lgustavo@codesourcery.com>
6711 * linux-arm-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
6712 to PTRACE_TYPE_ARG3.
6713 * linux-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
6714 to PTRACE_TYPE_ARG3 and PTRACE_ARG4_TYPE to
6716 * linux-low.h (PTRACE_ARG3_TYPE): Rename to PTRACE_TYPE_ARG3.
6717 (PTRACE_ARG4_TYPE): Rename to PTRACE_TYPE_ARG4.
6719 2013-07-27 Jie Zhang <jie@codesourcery.com>
6720 Daniel Jacobowitz <dan@codesourcery.com>
6721 Yao Qi <yao@codesourcery.com>
6723 * Makefile.in (SFILES): Add common/mips-linux-watch.c.
6724 (mips-linux-watch.o): New rule.
6725 (mips_linux_watch_h): New variable.
6726 * configure.srv <mips*-*-linux*>: Add mips-linux-watch.o to
6728 * linux-mips-low.c: Include mips-linux-watch.h.
6729 (struct arch_process_info, struct arch_lwp_info): New.
6730 (update_watch_registers_callback): New function.
6731 (mips_linux_new_process, mips_linux_new_thread) New functions.
6732 (mips_linux_prepare_to_resume, mips_insert_point): New
6734 (mips_remove_point, mips_stopped_by_watchpoint): New
6736 (rsp_bp_type_to_target_hw_bp_type): New function.
6737 (mips_stopped_data_address): New function.
6738 (the_low_target): Add watchpoint support functions.
6740 2013-07-27 Yao Qi <yao@codesourcery.com>
6742 * i386-low.c: Include break-common.h.
6743 (enum target_hw_bp_type): Remove.
6745 2013-07-24 Luis Machado <lgustavo@codesourcery.com>
6747 * Makefile.in (SFILES): /common/target-common.c.
6748 (OBS): Add target-common.o.
6749 (server_h): Add $(srcdir)/../common/target-common.h.
6750 (target-common.o): New target.
6751 * server.c (queue_stop_reply_callback): Free
6752 status string after use.
6753 * target.c (target_waitstatus_to_string): Remove.
6754 * target.h: Include target-common.h.
6755 (resume_kind): Likewise.
6756 (target_waitkind): Likewise.
6757 (target_waitstatus): Likewise.
6758 (TARGET_WNOHANG): Likewise.
6760 2013-07-04 Yao Qi <yao@codesourcery.com>
6762 * Makefile.in (host_alias): Use @host_noncanonical@.
6763 (target_alias): Use @target_noncanonical@.
6764 * configure.ac: Use ACX_NONCANONICAL_TARGET and
6765 ACX_NONCANONICAL_HOST.
6766 * configure: Regenerated.
6769 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
6771 * configure.ac (version_host, version_target): Set and AC_SUBST them.
6772 * configure: Rebuild.
6773 * Makefile.in (version_host, version_target): Get from configure.
6774 (version.c): Use $(version_host) and $(version_target).
6776 2013-07-03 Pedro Alves <palves@redhat.com>
6778 * Makefile.in (config.status): Depend on development.sh.
6779 * acinclude.m4: Include libmcheck.m4.
6780 * configure: Regenerate.
6782 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
6784 * win32-low.c (winapi_DebugActiveProcessStop): Move the WINAPI
6785 attribute inside the parentheses.
6786 (winapi_DebugSetProcessKillOnExit): Ditto.
6787 (winapi_DebugBreakProcess): Ditto.
6788 (winapi_GenerateConsoleCtrlEvent): Ditto.
6790 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
6792 * notif.h (notif_event): Add a dummy member to avoid compiler
6795 2013-07-01 Pedro Alves <palves@redhat.com>
6797 * hostio.c (HOSTIO_PATH_MAX): Define.
6798 (require_filename, handle_open, handle_unlink, handle_readlink):
6801 2013-07-01 Pedro Alves <palves@redhat.com>
6803 * server.h: Include "pathmax.h".
6804 * linux-low.c: Don't include sys/param.h.
6805 (linux_pid_exe_is_elf_64_file): Use PATH_MAX instead of
6807 * win32-low.c: Don't include sys/param.h.
6808 (win32_create_inferior): Use PATH_MAX instead of MAXPATHLEN.
6810 2013-07-01 Pedro Alves <palves@redhat.com>
6812 * event-loop.c: Don't check HAVE_UNISTD_H before including
6814 * gdbreplay.c: Likewise.
6815 * remote-utils.c: Likewise.
6816 * server.c: Likewise.
6817 * configure.ac: Don't check for unistd.h.
6818 * configure: Regenerate.
6820 2013-06-28 Tom Tromey <tromey@redhat.com>
6822 * Makefile.in (version.c): Use version.in, not
6825 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
6827 * configure.ac (version_host, version_target): Set and AC_SUBST them.
6828 * configure: Rebuild.
6829 * Makefile.in (version_host, version_target): Get from configure.
6830 (version.c): Use $(version_host) and $(version_target).
6832 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
6834 Fix trace-status to output user name without trailing colon.
6835 * tracepoint.c (cmd_qtstatus): Remove unnecessary colon from user name.
6837 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
6839 Fix trace-status to output proper start-time and stop-time.
6840 * tracepoint.c (cmd_qtstatus): Modify trace-status output to
6841 output start time and stop time in hex as gdb expects.
6843 2013-06-26 Pedro Alves <pedro@codesourcery.com>
6845 * tracepoint.c (build_traceframe_info_xml): Output trace state
6846 variables present in the trace buffer.
6848 2013-06-24 Tom Tromey <tromey@redhat.com>
6850 * Makefile.in (version.c): Use bfd/version.h, common/version.in,
6852 (version.o): Remove.
6853 * gdbreplay.c: Include version.h.
6854 (version, host_name): Don't declare.
6855 * server.h: Include version.h.
6856 (version, host_name): Don't declare.
6858 2013-06-12 Pedro Alves <palves@redhat.com>
6860 * linux-x86-low.c (linux_is_elf64): Delete global.
6861 (x86_siginfo_fixup): Replace reference to `linux_is_elf64' global
6862 with local linux_pid_exe_is_elf_64_file use.
6864 2013-06-11 Pedro Alves <palves@redhat.com>
6866 * linux-low.c (regset_disabled, disable_regset): New functions.
6867 (regsets_fetch_inferior_registers)
6868 (regsets_store_inferior_registers): Use them.
6869 (initialize_regsets_info); Don't allocate the disabled_regsets
6871 * linux-low.h (struct regsets_info) <disabled_regsets>: Extend
6874 2013-06-11 Pedro Alves <palves@redhat.com>
6876 * linux-low.c (initialize_regsets_info): Use xcalloc instead of
6879 2013-06-11 Pedro Alves <palves@redhat.com>
6881 * linux-x86-low.c (initialize_low_arch): Call
6882 init_registers_x32_avx_linux.
6884 2013-06-09 Jan Kratochvil <jan.kratochvil@redhat.com>
6886 Fix compatibility with Android Bionic.
6887 * linux-low.c (linux_qxfer_libraries_svr4): Ignore first entry even if
6890 2013-06-07 Pedro Alves <palves@redhat.com>
6893 * Makefile.in (OBS): Add tdesc.o.
6894 (IPA_OBJS): Add tdesc-ipa.o.
6895 (tdesc-ipa.o): New rule.
6896 * ax.c (gdb_eval_agent_expr): Adjust register_size call to new
6898 * linux-low.c (new_inferior): Delete.
6899 (disabled_regsets, num_regsets): Delete.
6900 (linux_add_process): Adjust to set the new per-process
6902 (linux_detach_one_lwp): Adjust to call regcache_invalidate_thread.
6903 (linux_wait_for_lwp): Adjust. Only call arch_setup if the event
6904 was a stop. When calling arch_setup, switch the current inferior
6905 to the thread that got an event.
6906 (linux_resume_one_lwp): Adjust to call regcache_invalidate_thread.
6907 (regsets_fetch_inferior_registers)
6908 (regsets_store_inferior_registers): New regsets_info parameter.
6910 (linux_register_in_regsets): New regs_info parameter. Adjust to
6912 (register_addr, fetch_register, store_register): New usrregs_info
6913 parameter. Adjust to use it.
6914 (usr_fetch_inferior_registers, usr_store_inferior_registers): New
6915 parameter regs_info. Adjust to use it.
6916 (linux_fetch_registers): Get the current inferior's regs_info, and
6918 (linux_store_registers): Ditto.
6919 [HAVE_LINUX_REGSETS] (initialize_regsets_info): New.
6920 (initialize_low): Don't initialize the target_regsets here. Call
6921 initialize_low_arch.
6922 * linux-low.h (target_regsets): Delete declaration.
6923 (struct regsets_info): New.
6924 (struct usrregs_info): New.
6925 (struct regs_info): New.
6926 (struct process_info_private) <new_inferior>: New field.
6927 (struct linux_target_ops): Delete the num_regs, regmap, and
6928 regset_bitmap fields. New field regs_info.
6929 [HAVE_LINUX_REGSETS] (initialize_regsets_info): Declare.
6930 * i387-fp.c (num_xmm_registers): Delete.
6931 (i387_cache_to_fsave, i387_fsave_to_cache): Adjust find_regno
6932 calls to new interface.
6933 (i387_cache_to_fxsave, i387_cache_to_xsave, i387_fxsave_to_cache)
6934 (i387_xsave_to_cache): Adjust find_regno calls to new interface.
6935 Infer the number of xmm registers from the regcache's target
6937 * i387-fp.h (num_xmm_registers): Delete.
6938 * inferiors.c (add_thread): Don't install the thread's regcache
6940 * proc-service.c (gregset_info): Fetch the current inferior's
6941 regs_info. Adjust to use it.
6942 * regcache.c: Include tdesc.h.
6943 (register_bytes, reg_defs, num_registers)
6944 (gdbserver_expedite_regs): Delete.
6945 (get_thread_regcache): If the thread doesn't have a regcache yet,
6946 create one, instead of aborting gdbserver.
6947 (regcache_invalidate_one): Rename to ...
6948 (regcache_invalidate_thread): ... this.
6949 (regcache_invalidate_one): New.
6950 (regcache_invalidate): Only invalidate registers of the current
6952 (init_register_cache): Add target_desc parameter, and use it.
6953 (new_register_cache): Ditto. Assert the target description has a
6954 non zero registers_size.
6955 (regcache_cpy): Add assertions. Adjust.
6956 (realloc_register_cache, set_register_cache): Delete.
6957 (registers_to_string, registers_from_string): Adjust.
6958 (find_register_by_name, find_regno, find_register_by_number)
6959 (register_cache_size): Add target_desc parameter, and use it.
6960 (free_register_cache_thread, free_register_cache_thread_one)
6961 (regcache_release, register_cache_size): New.
6962 (register_size): Add target_desc parameter, and use it.
6963 (register_data, supply_register, supply_register_zeroed)
6964 (supply_regblock, supply_register_by_name, collect_register)
6965 (collect_register_as_string, collect_register_by_name): Adjust.
6966 * regcache.h (struct target_desc): Forward declare.
6967 (struct regcache) <tdesc>: New field.
6968 (init_register_cache, new_register_cache): Add target_desc
6970 (regcache_invalidate_thread): Declare.
6971 (regcache_invalidate_one): Delete declaration.
6972 (regcache_release): Declare.
6973 (find_register_by_number, register_cache_size, register_size)
6974 (find_regno): Add target_desc parameter.
6975 (gdbserver_expedite_regs, gdbserver_xmltarget): Delete
6977 * remote-utils.c: Include tdesc.h.
6978 (outreg, prepare_resume_reply): Adjust.
6979 * server.c: Include tdesc.h.
6980 (gdbserver_xmltarget): Delete declaration.
6981 (get_features_xml, process_serial_event): Adjust.
6982 * server.h [IN_PROCESS_AGENT] (struct target_desc): Forward
6984 (struct process_info) <tdesc>: New field.
6985 (ipa_tdesc): Declare.
6986 * tdesc.c: New file.
6987 * tdesc.h: New file.
6988 * tracepoint.c: Include tdesc.h.
6989 [IN_PROCESS_AGENT] (ipa_tdesc): Define.
6990 (get_context_regcache): Adjust to pass ipa_tdesc down.
6991 (do_action_at_tracepoint): Adjust to get the register cache size
6992 from the context regcache's description.
6993 (traceframe_walk_blocks): Adjust to get the register cache size
6994 from the current trace frame's description.
6995 (traceframe_get_pc): Adjust to get current trace frame's
6996 description and pass it down.
6997 (gdb_collect): Adjust to get the register cache size from the
6999 * linux-amd64-ipa.c (tdesc_amd64_linux): Declare.
7000 (gdbserver_xmltarget): Delete.
7001 (initialize_low_tracepoint): Set the ipa's target description.
7002 * linux-i386-ipa.c (tdesc_i386_linux): Declare.
7003 (initialize_low_tracepoint): Set the ipa's target description.
7004 * linux-x86-low.c: Include tdesc.h.
7005 [__x86_64__] (is_64bit_tdesc): New.
7006 (ps_get_thread_area, x86_get_thread_area): Use it.
7007 (i386_cannot_store_register): Rename to ...
7008 (x86_cannot_store_register): ... this. Use is_64bit_tdesc.
7009 (i386_cannot_fetch_register): Rename to ...
7010 (x86_cannot_fetch_register): ... this. Use is_64bit_tdesc.
7011 (x86_fill_gregset, x86_store_gregset): Adjust register_size calls
7013 (target_regsets): Rename to ...
7014 (x86_regsets): ... this.
7015 (x86_get_pc, x86_set_pc): Adjust register_size calls to new
7017 (x86_siginfo_fixup): Use is_64bit_tdesc.
7018 [__x86_64__] (tdesc_amd64_linux, tdesc_amd64_avx_linux)
7019 (tdesc_x32_avx_linux, tdesc_x32_linux)
7020 (tdesc_i386_linux, tdesc_i386_mmx_linux, tdesc_i386_avx_linux):
7022 (x86_linux_update_xmltarget): Delete.
7023 (I386_LINUX_XSAVE_XCR0_OFFSET): Define.
7024 (have_ptrace_getfpxregs, have_ptrace_getregset): New.
7025 (AMD64_LINUX_USER64_CS): New.
7026 (x86_linux_read_description): New, based on
7027 x86_linux_update_xmltarget.
7028 (same_process_callback): New.
7029 (x86_arch_setup_process_callback): New.
7030 (x86_linux_update_xmltarget): New.
7031 (x86_regsets_info): New.
7032 (amd64_linux_regs_info): New.
7033 (i386_linux_usrregs_info): New.
7034 (i386_linux_regs_info): New.
7035 (x86_linux_regs_info): New.
7036 (x86_arch_setup): Reimplement.
7037 (x86_install_fast_tracepoint_jump_pad): Use is_64bit_tdesc.
7038 (x86_emit_ops): Ditto.
7039 (the_low_target): Adjust. Install x86_linux_regs_info,
7040 x86_cannot_fetch_register, and x86_cannot_store_register.
7041 (initialize_low_arch): New.
7042 * linux-ia64-low.c (tdesc_ia64): Declare.
7043 (ia64_fetch_register): Adjust.
7044 (ia64_usrregs_info, regs_info): New globals.
7045 (ia64_regs_info): New function.
7046 (the_low_target): Adjust.
7047 (initialize_low_arch): New function.
7048 * linux-sparc-low.c (tdesc_sparc64): Declare.
7049 (sparc_fill_gregset_to_stack, sparc_store_gregset_from_stack):
7051 (sparc_arch_setup): New function.
7052 (sparc_regsets_info, sparc_usrregs_info, regs_info): New globals.
7053 (the_low_target): Adjust.
7054 (initialize_low_arch): New function.
7055 * linux-ppc-low.c (tdesc_powerpc_32l, tdesc_powerpc_altivec32l)
7056 (tdesc_powerpc_cell32l, tdesc_powerpc_vsx32l)
7057 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_altivec32l)
7058 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_e500l)
7059 (tdesc_powerpc_64l, tdesc_powerpc_altivec64l)
7060 (tdesc_powerpc_cell64l, tdesc_powerpc_vsx64l)
7061 (tdesc_powerpc_isa205_64l, tdesc_powerpc_isa205_altivec64l)
7062 (tdesc_powerpc_isa205_vsx64l): Declare.
7063 (ppc_cannot_store_register, ppc_collect_ptrace_register)
7064 (ppc_supply_ptrace_register, parse_spufs_run, ppc_get_pc)
7065 (ppc_set_pc, ppc_get_hwcap): Adjust.
7066 (ppc_usrregs_info): Forward declare.
7067 (!__powerpc64__) ppc_regmap_adjusted: New global.
7068 (ppc_arch_setup): Adjust to the current process'es target
7070 (ppc_fill_vsxregset, ppc_store_vsxregset, ppc_fill_vrregset)
7071 (ppc_store_vrregset, ppc_fill_evrregset, ppc_store_evrregse)
7072 (ppc_store_evrregset): Adjust.
7073 (target_regsets): Rename to ...
7074 (ppc_regsets): ... this, and make static.
7075 (ppc_usrregs_info, ppc_regsets_info, regs_info): New globals.
7076 (ppc_regs_info): New function.
7077 (the_low_target): Adjust.
7078 (initialize_low_arch): New function.
7079 * linux-s390-low.c (tdesc_s390_linux32, tdesc_s390_linux32v1)
7080 (tdesc_s390_linux32v2, tdesc_s390_linux64, tdesc_s390_linux64v1)
7081 (tdesc_s390_linux64v2, tdesc_s390x_linux64, tdesc_s390x_linux64v1)
7082 (tdesc_s390x_linux64v2): Declare.
7083 (s390_collect_ptrace_register, s390_supply_ptrace_register)
7084 (s390_fill_gregset, s390_store_last_break): Adjust.
7085 (target_regsets): Rename to ...
7086 (s390_regsets): ... this, and make static.
7087 (s390_get_pc, s390_set_pc): Adjust.
7088 (s390_get_hwcap): New target_desc parameter, and use it.
7089 [__s390x__] (have_hwcap_s390_high_gprs): New global.
7090 (s390_arch_setup): Adjust to set the current process'es target
7091 description. Don't adjust the regmap.
7092 (s390_usrregs_info, s390_regsets_info, regs_info): New globals.
7093 [__s390x__] (s390_usrregs_info_3264, s390_regsets_info_3264)
7094 (regs_info_3264): New globals.
7095 (s390_regs_info): New function.
7096 (the_low_target): Adjust.
7097 (initialize_low_arch): New function.
7098 * linux-mips-low.c (tdesc_mips_linux, tdesc_mips_dsp_linux)
7099 (tdesc_mips64_linux, tdesc_mips64_dsp_linux): Declare.
7100 [__mips64] (init_registers_mips_linux)
7101 (init_registers_mips_dsp_linux): Delete defines.
7102 [__mips64] (tdesc_mips_linux, tdesc_mips_dsp_linux): New defines.
7103 (have_dsp): New global.
7104 (mips_read_description): New, based on mips_arch_setup.
7105 (mips_arch_setup): Reimplement.
7106 (get_usrregs_info): New function.
7107 (mips_cannot_fetch_register, mips_cannot_store_register)
7108 (mips_get_pc, mips_set_pc, mips_fill_gregset, mips_store_gregset)
7109 (mips_fill_fpregset, mips_store_fpregset): Adjust.
7110 (target_regsets): Rename to ...
7111 (mips_regsets): ... this, and make static.
7112 (mips_regsets_info, mips_dsp_usrregs_info, mips_usrregs_info)
7113 (dsp_regs_info, regs_info): New globals.
7114 (mips_regs_info): New function.
7115 (the_low_target): Adjust.
7116 (initialize_low_arch): New function.
7117 * linux-arm-low.c (tdesc_arm, tdesc_arm_with_iwmmxt)
7118 (tdesc_arm_with_vfpv2, tdesc_arm_with_vfpv3, tdesc_arm_with_neon):
7120 (arm_fill_vfpregset, arm_store_vfpregset): Adjust.
7121 (arm_read_description): New, with bits factored from
7123 (arm_arch_setup): Reimplement.
7124 (target_regsets): Rename to ...
7125 (arm_regsets): ... this, and make static.
7126 (arm_regsets_info, arm_usrregs_info, regs_info): New globals.
7127 (arm_regs_info): New function.
7128 (the_low_target): Adjust.
7129 (initialize_low_arch): New function.
7130 * linux-m68k-low.c (tdesc_m68k): Declare.
7131 (target_regsets): Rename to ...
7132 (m68k_regsets): ... this, and make static.
7133 (m68k_regsets_info, m68k_usrregs_info, regs_info): New globals.
7134 (m68k_regs_info): New function.
7135 (m68k_arch_setup): New function.
7136 (the_low_target): Adjust.
7137 (initialize_low_arch): New function.
7138 * linux-sh-low.c (tdesc_sharch): Declare.
7139 (target_regsets): Rename to ...
7140 (sh_regsets): ... this, and make static.
7141 (sh_regsets_info, sh_usrregs_info, regs_info): New globals.
7142 (sh_regs_info, sh_arch_setup): New functions.
7143 (the_low_target): Adjust.
7144 (initialize_low_arch): New function.
7145 * linux-bfin-low.c (tdesc_bfin): Declare.
7146 (bfin_arch_setup): New function.
7147 (bfin_usrregs_info, regs_info): New globals.
7148 (bfin_regs_info): New function.
7149 (the_low_target): Adjust.
7150 (initialize_low_arch): New function.
7151 * linux-cris-low.c (tdesc_cris): Declare.
7152 (cris_arch_setup): New function.
7153 (cris_usrregs_info, regs_info): New globals.
7154 (cris_regs_info): New function.
7155 (the_low_target): Adjust.
7156 (initialize_low_arch): New function.
7157 * linux-cris-low.c (tdesc_crisv32): Declare.
7158 (cris_arch_setup): New function.
7159 (cris_regsets_info, cris_usrregs_info, regs_info): New globals.
7160 (cris_regs_info): New function.
7161 (the_low_target): Adjust.
7162 (initialize_low_arch): New function.
7163 * linux-m32r-low.c (tdesc_m32r): Declare.
7164 (m32r_arch_setup): New function.
7165 (m32r_usrregs_info, regs_info): New globals.
7166 (m32r_regs_info): Adjust.
7167 (initialize_low_arch): New function.
7168 * linux-tic6x-low.c (tdesc_tic6x_c64xp_linux)
7169 (tdesc_tic6x_c64x_linux, tdesc_tic6x_c62x_linux): Declare.
7170 (tic6x_usrregs_info): Forward declare.
7171 (tic6x_read_description): New function, based on ...
7172 (tic6x_arch_setup): ... this. Reimplement.
7173 (target_regsets): Rename to ...
7174 (tic6x_regsets): ... this, and make static.
7175 (tic6x_regsets_info, tic6x_usrregs_info, regs_info): New globals.
7176 (tic6x_regs_info): New function.
7177 (the_low_target): Adjust.
7178 (initialize_low_arch): New function.
7179 * linux-xtensa-low.c (tdesc_xtensa): Declare.
7180 (xtensa_fill_gregset, xtensa_store_gregset): Adjust.
7181 (target_regsets): Rename to ...
7182 (xtensa_regsets): ... this, and make static.
7183 (xtensa_regsets_info, xtensa_usrregs_info, regs_info): New
7185 (xtensa_arch_setup, xtensa_regs_info): New functions.
7186 (the_low_target): Adjust.
7187 (initialize_low_arch): New function.
7188 * linux-nios2-low.c (tdesc_nios2_linux): Declare.
7189 (nios2_arch_setup): Set the current process'es tdesc.
7190 (target_regsets): Rename to ...
7191 (nios2_regsets): ... this.
7192 (nios2_regsets_info, nios2_usrregs_info, regs_info): New globals.
7193 (nios2_regs_info): New function.
7194 (the_low_target): Adjust.
7195 (initialize_low_arch): New function.
7196 * linux-aarch64-low.c (tdesc_aarch64): Declare.
7197 (aarch64_arch_setup): Set the current process'es tdesc.
7198 (target_regsets): Rename to ...
7199 (aarch64_regsets): ... this.
7200 (aarch64_regsets_info, aarch64_usrregs_info, regs_info): New globals.
7201 (aarch64_regs_info): New function.
7202 (the_low_target): Adjust.
7203 (initialize_low_arch): New function.
7204 * linux-tile-low.c (tdesc_tilegx, tdesc_tilegx32): Declare
7206 (target_regsets): Rename to ...
7207 (tile_regsets): ... this.
7208 (tile_regsets_info, tile_usrregs_info, regs_info): New globals.
7209 (tile_regs_info): New function.
7210 (tile_arch_setup): Set the current process'es tdesc.
7211 (the_low_target): Adjust.
7212 (initialize_low_arch): New function.
7213 * spu-low.c (tdesc_spu): Declare.
7214 (spu_create_inferior, spu_attach): Set the new process'es tdesc.
7215 * win32-arm-low.c (tdesc_arm): Declare.
7216 (arm_arch_setup): New function.
7217 (the_low_target): Install arm_arch_setup instead of
7219 * win32-i386-low.c (tdesc_i386, tdesc_amd64): Declare.
7220 (init_windows_x86): Rename to ...
7221 (i386_arch_setup): ... this. Set `win32_tdesc'.
7222 (the_low_target): Adjust.
7223 * win32-low.c (win32_tdesc): New global.
7224 (child_add_thread): Don't create the thread cache here.
7225 (do_initial_child_stuff): Set the new process'es tdesc.
7226 * win32-low.h (struct target_desc): Forward declare.
7227 (win32_tdesc): Declare.
7228 * lynx-i386-low.c (tdesc_i386): Declare global.
7229 (lynx_i386_arch_setup): Set `lynx_tdesc'.
7230 * lynx-low.c (lynx_tdesc): New global.
7231 (lynx_add_process): Set the new process'es tdesc.
7232 * lynx-low.h (struct target_desc): Forward declare.
7233 (lynx_tdesc): Declare global.
7234 * lynx-ppc-low.c (tdesc_powerpc_32): Declare global.
7235 (lynx_ppc_arch_setup): Set `lynx_tdesc'.
7236 * nto-low.c (nto_tdesc): New global.
7237 (do_attach): Set the new process'es tdesc.
7238 * nto-low.h (struct target_desc): Forward declare.
7239 (nto_tdesc): Declare.
7240 * nto-x86-low.c (tdesc_i386): Declare.
7241 (nto_x86_arch_setup): Set `nto_tdesc'.
7243 2013-06-04 Gary Benson <gbenson@redhat.com>
7245 * server.c (handle_query): Add "augmented-libraries-svr4-read+"
7246 to qSupported response when appropriate.
7247 (handle_qxfer_libraries_svr4): Allow qXfer:libraries-svr4:read
7248 with nonzero-length annex.
7249 * linux-low.c (linux_qxfer_libraries_svr4): Parse and handle
7250 arguments supplied in annex.
7252 2013-05-31 Doug Evans <dje@google.com>
7255 * linux-x86-low.c (ps_get_thread_area): Properly extend address to
7256 64 bits in 64-cross-32 environment.
7258 2013-05-28 Pedro Alves <palves@redhat.com>
7260 * Makefile.in (clean): Remove reference to aarch64-without-fpu.c.
7261 (aarch64-without-fpu.c): Delete rule.
7262 * configure.srv (aarch64*-*-linux*): Remove references to
7263 aarch64-without-fpu.o and aarch64-without-fpu.xml.
7264 * linux-aarch64-low.c (init_registers_aarch64_without_fpu): Remove
7267 2013-05-24 Pedro Alves <palves@redhat.com>
7269 * server.c (handle_v_cont) <vCont;r>: Use unpack_varlen_hex
7270 instead of strchr/decode_address. Error if the range isn't split
7271 with a ','. Don't assume there's be a ':' in the action.
7273 2013-05-23 Yao Qi <yao@codesourcery.com>
7274 Pedro Alves <palves@redhat.com>
7276 * linux-low.c (lwp_in_step_range): New function.
7277 (linux_wait_1): If the thread was range stepping and stopped
7278 outside the stepping range, report the stop to GDB. Otherwise,
7279 continue stepping. Add range stepping debug output.
7280 (linux_set_resume_request): Copy the step range from the resume
7282 (linux_supports_range_stepping): New.
7283 (linux_target_ops) <supports_range_stepping>: Set to
7284 linux_supports_range_stepping.
7285 * linux-low.h (struct linux_target_ops)
7286 <supports_range_stepping>: New field.
7287 (struct lwp_info) <step_range_start, step_range_end>: New fields.
7288 * linux-x86-low.c (x86_supports_range_stepping): New.
7289 (the_low_target) <supports_range_stepping>: Set to
7290 x86_supports_range_stepping.
7291 * server.c (handle_v_cont): Handle 'r' action.
7292 (handle_v_requests): Append ";r" if the target supports range
7294 * target.h (struct thread_resume) <step_range_start,
7295 step_range_end>: New fields.
7296 (struct target_ops) <supports_range_stepping>:
7298 (target_supports_range_stepping): New macro.
7300 2013-05-17 Joel Brobecker <brobecker@adacore.com>
7302 * lynx-low.c (lynx_resume): Fix null_ptid/minus_one_ptid
7303 confusion in comment.
7305 2013-05-17 Joel Brobecker <brobecker@adacore.com>
7307 * lynx-low.c (struct process_info_private): New type.
7308 (lynx_add_process): New function.
7309 (lynx_create_inferior, lynx_attach): Replace calls to
7310 add_process by calls to lynx_add_process.
7311 (lynx_resume): If PTID is null, then try using
7312 current_process()->private->last_wait_event_ptid.
7314 (lynx_clear_inferiors): Delete. The contents of that function
7315 has been inlined in lynx_mourn;
7316 (lynx_wait_1): Save the ptid in the process's private data.
7317 (lynx_mourn): Free the process' private data. Replace call
7318 to lynx_clear_inferiors by call to clear_inferiors.
7320 2013-05-17 Yao Qi <yao@codesourcery.com>
7322 * i386-low.c (i386_length_and_rw_bits): Move the comment to
7325 2013-05-16 Luis Machado <lgustavo@codesourcery.com>
7327 * linux-low.c: Move definition checks upwards for PT_TEXT_ADDR,
7328 PT_DATA_ADDR and PT_TEXT_END_ADDR. Update comments.
7329 (linux_read_offsets): Remove PT_TEXT_ADDR, PT_DATA_ADDR and
7330 PT_TEXT_END_ADDR guards. Update comments.
7331 (linux_target_op) <read_offsets>: Conditionally define to
7332 linux_read_offsets if the target is UCLIBC and if it defines
7333 PT_TEXT_ADDR, PT_DATA_ADDR and PT_TEXT_END_ADDR.
7335 2013-05-06 Sandra Loosemore <sandra@codesourcery.com>
7336 Andrew Jenner <andrew@codesourcery.com>
7338 * Makefile.in (SFILES): Add linux-nios2-low.c.
7339 (clean): Add action to delete nios2-linux.c.
7340 (nios2-linux.c): New rule.
7341 * configure.srv: Add nios2*-*-linux*.
7342 * linux-nios2-low.c: New.
7344 2013-05-03 Hafiz Abid Qadeer <abidh@codesourcery.com>
7346 * tracepoint.c (cmd_qtinit): Call 'stop_tracing'.
7348 2013-04-25 Hui Zhu <hui@codesourcery.com>
7351 * ax.c (ax_printf): Add fflush.
7353 2013-04-22 Tom Tromey <tromey@redhat.com>
7355 * Makefile.in (SFILES): Add filestuff.c.
7356 (OBS): Add filestuff.o.
7357 (filestuff.o): New target.
7358 * config.in, configure: Rebuild.
7359 * configure.ac: Check for fdwalk, pipe2.
7361 2013-04-17 Pedro Alves <palves@redhat.com>
7363 * configure.ac (USE_THREAD_DB): Delete variable.
7364 (if test "$srv_linux_thread_db" = "yes"): AC_DEFINE USE_THREAD_DB.
7365 Don't AC_SUBST USE_THREAD_DB.
7366 * Makefile.in (INTERNAL_CFLAGS): Remove @USE_THREAD_DB@.
7367 * config.in, configure: Regenerate.
7369 2013-04-16 Pedro Alves <palves@redhat.com>
7371 * linux-low.h (struct lwp_info) <thread_known>: Move under
7372 the USE_THREAD_DB #ifdef.
7374 2013-04-16 Pedro Alves <palves@redhat.com>
7376 * Makefile.in (INTERNAL_CFLAGS): Add @USE_THREAD_DB@.
7377 (linux-low.o): Delete rule.
7378 * linux-low.h: Always include "gdb_thread_db.h" instead of
7379 conditionally including thread_db.h.
7380 (struct lwp_info) <th>: Guard with #ifdef USE_THREAD_DB instead of
7383 2013-04-07 Jan Kratochvil <jan.kratochvil@redhat.com>
7385 * Makefile.in (install-only): Fix make install regression.
7387 2013-04-05 Jan Kratochvil <jan.kratochvil@redhat.com>
7389 Convert man pages to texinfo, new gdbinit.5 texinfo page.
7390 * Makefile.in (install-only): Remove $(man1dir) and gdbserver.1
7392 * gdbserver.1: Remove.
7394 2013-03-22 Pedro Alves <palves@redhat.com>
7396 * linux-low.c (handle_extended_wait): Don't call
7397 linux_enable_event_reporting.
7399 2013-03-15 Tony Theodore <tonyt@logyst.com>
7402 * Makefile.in (SHELL): Use @SHELL@.
7404 2013-03-14 Sergio Durigan Junior <sergiodj@redhat.com>
7406 * tracepoint.c (cmd_qtv): Initialize `val' with zero, silencing
7409 2013-03-13 Joel Brobecker <brobecker@adacore.com>
7411 * linux-low.c (linux_target_ops) [!HAVE_LINUX_BTRACE]:
7412 Remove extraneous NULL element.
7414 2013-03-13 Yao Qi <yao@codesourcery.com>
7416 * tracepoint.c (traceframe_read_tsv): Look for the last matched
7417 'V' block in trace frame.
7419 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
7421 * target.h (struct target_ops): Add btrace ops.
7422 (target_supports_btrace): New macro.
7423 (target_enable_btrace): New macro.
7424 (target_disable_btrace): New macro.
7425 (target_read_btrace): New macro.
7426 * gdbthread.h (struct thread_info): Add btrace field.
7427 * server.c: Include btrace-common.h.
7428 (handle_btrace_general_set): New function.
7429 (handle_btrace_enable): New function.
7430 (handle_btrace_disable): New function.
7431 (handle_general_set): Call handle_btrace_general_set.
7432 (handle_qxfer_btrace): New function.
7433 (struct qxfer qxfer_packets[]): Add btrace entry.
7434 * inferiors.c (remove_thread): Disable btrace.
7435 * linux-low: Include linux-btrace.h.
7436 (linux_low_enable_btrace): New function.
7437 (linux_low_read_btrace): New function.
7438 (linux_target_ops): Add btrace ops.
7439 * configure.srv (i[34567]86-*-linux*): Add linux-btrace.o.
7440 Add srv_linux_btrace=yes.
7441 (x86_64-*-linux*): Add linux-btrace.o.
7442 Add srv_linux_btrace=yes.
7443 * configure.ac: Define HAVE_LINUX_BTRACE.
7444 * config.in: Regenerated.
7445 * configure: Regenerated.
7447 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
7449 * server.c (handle_qxfer): Preserve error message if -3 is
7451 (qxfer): Document the -3 return value.
7453 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
7455 * Makefile.in (SFILES): Add $(srcdir)/common/linux-btrace.c.
7456 (linux_btrace_h): New variable.
7457 (linux-btrace.o): New rule.
7459 2013-03-08 Stan Shebs <stan@codesourcery.com>
7460 Hafiz Abid Qadeer <abidh@codesourcery.com>
7462 * tracepoint.c (trace_buffer_size): New global.
7463 (DEFAULT_TRACE_BUFFER_SIZE): New define.
7464 (init_trace_buffer): Change to one-argument function. Allocate
7465 trace buffer memory.
7466 (handle_tracepoint_general_set): Call cmd_bigqtbuffer_size to
7467 handle QTBuffer:size packet.
7468 (cmd_bigqtbuffer_size): New function.
7469 (initialize_tracepoint): Call init_trace_buffer with
7470 DEFAULT_TRACE_BUFFER_SIZE.
7471 * server.c (handle_query): Add QTBuffer:size in the
7474 2013-03-07 Yao Qi <yao@codesourcery.com>
7476 * tracepoint.c (cur_action, cur_step_action): Make them unsigned.
7477 (cmd_qtfp): Initialize cur_action and cur_step_action 0 instead
7479 (cmd_qtsp): Adjust condition. Do post increment.
7480 Set cur_action and cur_step_action back to 0.
7482 2013-03-07 Jeremy Bennett <jeremy.bennett@embecosm.com>
7485 * linux-low.c (linux_write_memory): Return early success if LEN is
7488 2013-03-05 Corinna Vinschen <vinschen@redhat.de>
7490 * configure.srv: Add x86_64-*-cygwin* as target.
7492 2013-02-28 Tom Tromey <tromey@redhat.com>
7494 * configure.ac: Invoke AC_SYS_LARGEFILE.
7495 * configure, config.in: Rebuild.
7497 2013-02-28 Corinna Vinschen <vinschen@redhat.com>
7499 * win32-low.c: Throughout, fix format strings and casts of
7500 printf-like functions to avoid type related warnings on all
7502 (get_child_debug_event): Print dwDebugEventCode as hex since
7503 that's how it's usually documented.
7505 2013-02-28 Yao Qi <yao@codesourcery.com>
7507 * tracepoint.c (cmd_qtbuffer): Call phex_nz instead of
7510 2013-02-27 Jiong Wang <jiwang@tilera.com>
7512 * Makefile.in (clean): Remove reg-tilegx.c, reg-tilegx32.c.
7513 (reg-tilegx32.c): New rule.
7514 * configure.srv (tilegx-*-linux*): Add reg-tilegx32.o to srv_regobj.
7515 * linux-tile-low.c (tile_arch_setup): New function. Invoke
7516 different register info initializer according to elf class.
7517 (init_registers_tilgx32): New function. The tilegx32 register info
7519 (tile_fill_gregset): Use "uint_reg_t" to represent register size.
7520 (tile_store_gregset): Likewise.
7522 2013-02-27 Yao Qi <yao@codesourcery.com>
7524 * server.c (process_point_options): Print debug message when
7525 debug_threads is true.
7527 2013-02-26 Yao Qi <yao@codesourcery.com>
7529 * tracepoint.c (cmd_qtbuffer): Don't set '\0' in OWN_BUF.
7531 2013-02-19 Pedro Alves <palves@redhat.com>
7532 Kai Tietz <ktietz@redhat.com>
7536 * server.c (handle_query) <CRC check>: Use unpack_varlen_hex
7537 instead of strtoul to extract address from packet.
7538 (process_serial_event) <'z'>: Likewise.
7540 2013-02-18 Yao Qi <yao@codesourcery.com>
7542 * linux-bfin-low.c (the_low_target): Use NULL instead of 0.
7544 2013-02-14 Pedro Alves <palves@redhat.com>
7548 * tracepoint.c (cmd_qtnotes): Free TRACING_USER_NAME,
7549 TRACING_NOTES and TRACING_STOP_NOTE before clobbering.
7551 2013-02-14 Pedro Alves <palves@redhat.com>
7553 * tracepoint.c (cmd_qtdpsrc): Use savestring.
7555 2013-02-14 Pedro Alves <palves@redhat.com>
7557 * tracepoint.c (save_string): Delete.
7558 (add_tracepoint_action): Use savestring instead of save_string.
7560 2013-02-12 Pedro Alves <palves@redhat.com>
7562 * linux-xtensa-low.c: Ditto.
7563 * xtensa-xtregs.c: Ditto.
7565 2013-02-12 Sanimir Agovic <sanimir.agovic@intel.com>
7567 * thread-db.c (thread_db_get_tls_address): NULL pointer check
7570 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
7572 * linux-aarch64-low.c (aarch64_arch_setup): Clamp
7573 aarch64_num_wp_regs and aarch64_num_bp_regs to
7574 AARCH64_HWP_MAX_NUM and AARCH64_HBP_MAX_NUM respectively.
7576 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
7578 * linux-aarch64-low.c (ps_get_thread_area): Replace
7579 PTRACE_GET_THREAD_AREA with PTRACE_GETREGSET.
7581 2013-02-04 Jim MacArthur <jim.macarthur@arm.com>
7582 Marcus Shawcroft <marcus.shawcroft@arm.com>
7583 Nigel Stephens <nigel.stephens@arm.com>
7584 Yufeng Zhang <yufeng.zhang@arm.com>
7586 * Makefile.in (clean): Remove aarch64.c and aarch64-without-fpu.c.
7587 (aarch64.c, aarch64-without-fpu.c): New targets.
7588 * configure.srv (aarch64*-*-linux*): New.
7589 * linux-aarch64-low.c: New file.
7591 2013-02-04 Marcus Shawcroft <marcus.shawcroft@arm.com>
7593 * linux-low.c (handle_extended_wait, linux_create_inferior)
7594 (linux_attach_lwp_1, linux_kill_one_lwp, linux_attach_one_lwp)
7595 (dequeue_one_deferred_signal, linux_resume_one_thread)
7596 (fetch_register, linux_write_memory, linux_enable_event_reporting)
7597 (linux_tracefork_grandchild, linux_test_for_tracefork)
7598 (linux_read_offsets, linux_xfer_siginfo, linux_xfer_siginfo): Add
7599 PTRACE_ARG3_TYPE and PTRACE_ARG4_TYPE cast to ptrace arguments
7600 where the argument is 0.
7602 2013-01-25 Yao Qi <yao@codesourcery.com>
7604 * event-loop.c: Include "queue.h".
7605 (gdb_event_p): New typedef.
7606 (struct gdb_event) <next_event>: Remove.
7607 (event_queue): Change to QUEUE(gdb_event_p).
7608 (async_queue_event): Remove.
7609 (gdb_event_xfree): New.
7610 (initialize_event_loop): New.
7611 (process_event): Use API from QUEUE.
7612 (wait_for_event): Likewise.
7613 * server.c (main): Call initialize_event_loop.
7614 * server.h (initialize_event_loop): Declare.
7616 2013-01-18 Yao Qi <yao@codesourcery.com>
7618 * ax.h (struct eval_agent_expr_context): New.
7619 (gdb_eval_agent_expr): Update declaration.
7620 * ax.c (gdb_eval_agent_expr): Remove argument REGCACHE and
7621 TFRAME. Add new argument CTX.
7622 * server.h (struct eval_agent_expr_context): Declare.
7623 (agent_mem_read, agent_tsv_read): Update declaration.
7624 (agent_mem_read_string): Likewise.
7625 * tracepoint.c (eval_tracepoint_agent_expr): Remove.
7626 (add_traceframe_block): Add new argument TPOINT.
7627 Increase TPOINT->traceframe_usage.
7628 (do_action_at_tracepoint): Call gdb_eval_agent_expr instead of
7629 eval_tracepoint_agent_expr.
7630 (condition_true_at_tracepoint): Likewise.
7631 (agent_mem_read): Remove argument TFRAME. Add argument CTX.
7632 (agent_mem_read_string, agent_tsv_read): Likewise.
7634 2013-01-16 Yao Qi <yao@codesourcery.com>
7636 * linux-low.c (linux_resume_one_lwp): Don't check
7637 'lwp->bp_reinsert != 0'.
7639 2013-01-07 Joel Brobecker <brobecker@adacore.com>
7640 Pedro Alves <palves@redhat.com>
7642 * lynx-low.c (ptrace_request_to_str): Define a temporary
7643 macro and use it to simplify this function's implementation.
7645 2013-01-07 Joel Brobecker <brobecker@adacore.com>
7647 * lynx-low.c (lynx_resume): Call perror_with_name if lynx_ptrace
7650 2013-01-07 Joel Brobecker <brobecker@adacore.com>
7652 * configure.srv (i[34567]86-*-lynxos*): Set srv_xmlfiles.
7654 2013-01-07 Joel Brobecker <brobecker@adacore.com>
7656 * configure.srv (powerpc-*-lynxos*): Set srv_xmlfiles.
7658 2013-01-07 Joel Brobecker <brobecker@adacore.com>
7660 * lynx-low.c (lynx_resume): Use the resume_info parameter
7661 to determine the ptid for the lynx_ptrace call, unless
7662 it is equal to minus_one_ptid, in which case we use the
7663 ptid of the current_inferior.
7664 (lynx_wait_1): After having received a thread create/exit
7665 event, resume the inferior's execution using the signaling
7666 thread's ptid, rather than the old ptid.
7668 2013-01-07 Joel Brobecker <brobecker@adacore.com>
7670 * lynx-low.c (lynx_resume): Delete variable ret.
7672 2013-01-01 Joel Brobecker <brobecker@adacore.com>
7674 * gdbreplay.c (gdbreplay_version): Update copyright year.
7675 * server.c (gdbserver_version): Likewise.
7677 2012-12-17 Joel Brobecker <brobecker@adacore.com>
7679 * lynx-low.c (lynx_wait_1): Add debug trace before adding
7682 2012-12-17 Joel Brobecker <brobecker@adacore.com>
7684 * lynx-low.c (ptrace_request_to_str): Add handling for
7687 2012-12-17 Joel Brobecker <brobecker@adacore.com>
7689 * lynx-low.c (lynx_attach): Delete variable new_process.
7691 2012-12-17 Joel Brobecker <brobecker@adacore.com>
7693 * lynx-low.c (lynx_create_inferior): Delete variable
7696 2012-12-17 Joel Brobecker <brobecker@adacore.com>
7698 * lynx-low.c (ptrace_request_to_str): Do not handle
7699 PTRACE_GETTHREADLIST if this macro does not exist.
7701 2012-12-15 Yao Qi <yao@codesourcery.com>
7703 * Makefile.in (OBS): Add notif.o.
7704 * notif.c, notif.h: New.
7705 * server.c: Include "notif.h".
7706 (struct vstop_notif) <next>: Remove.
7708 (queue_stop_reply): Update.
7709 (push_event, send_next_stop_reply): Remove.
7710 (discard_queued_stop_replies): Update.
7711 (notif_stop): New variable.
7712 (handle_v_stopped): Remove.
7713 (handle_v_requests): Don't call handle_v_stopped. Call
7714 handle_ack_notif instead.
7715 (queue_stop_reply_callback): Call notif_event_enque instead
7716 of queue_stop_reply.
7717 (handle_status): Don't call send_next_stop_reply, call
7718 notif_write_event instead.
7719 (kill_inferior_callback): Likewise.
7720 (detach_or_kill_inferior_callback): Likewise.
7721 (main): Call initialize_notif.
7722 (process_serial_event): Call QUEUE_is_empty.
7723 (handle_target_event): Call notif_push instead of push event.
7724 * server.h (push_event): Remove declaration.
7726 2012-12-10 Tom Tromey <tromey@redhat.com>
7728 * Makefile.in (DEPMODE, DEPDIR, depcomp, COMPILE.pre)
7729 (COMPILE.post, COMPILE, POSTCOMPILE, IPAGENT_COMPILE): New
7732 (ax-ipa.o, tracepoint-ipa.o, utils-ipa.o, format-ipa.o)
7733 (common-utils-ipa.o, remote-utils-ipa.o, regcache-ipa.o)
7734 (i386-linux-ipa.o, linux-i386-ipa.o, linux-amd64-ipa.o)
7735 (amd64-linux-ipa.o, ax.o): Rewrite.
7736 (event-loop.o, hostio.o, hostio-errno.o, inferiors.o, mem-break.o)
7737 (proc-service.o, regcache.o, remote-utils.o, server.o, target.o)
7738 (thread-db.o, tracepoint.o, utils.o, gdbreplay.o, dll.o): Remove.
7739 (signals.o, linux-procfs.o, linux-ptrace.o, common-utils.o, vec.o)
7740 (gdb_vecs.o, xml-utils.o, linux-osdata.o, ptid.o, buffer.o)
7741 (format.o, agent.o, vasprintf.o, vsnprintf.o): Rewrite.
7742 (i386-low.o, i387-fp.o, linux-low.o, linux-arm-low.o)
7743 (linux-bfin-low.o, linux-cris-low.o, linux-crisv32-low.o)
7744 (linux-ia64-low.o, linux-m32r-low.o, linux-mips-low.o)
7745 (linux-ppc-low.o, linux-s390-low.o, linux-sh-low.o)
7746 (linux-tic6x-low.o, linux-x86-low.o, linux-xtensa-low.o)
7747 (linux-tile-low.o, lynx-low.o, lynx-ppc-low.o, nto-low.o)
7748 (nto-x86-low.o, linux-low.o, win32-low.o, win32-arm-low.o)
7749 (win32-i386-low.o, spu-low.o, reg-arm.o, arm-with-iwmmxt.o)
7750 (arm-with-vfpv2.o, arm-with-vfpv3.o, arm-with-neon.o, reg-bfin.o)
7751 (reg-cris.o, reg-crisv32.o, i386.o, i386-linux.o, i386-avx.o)
7752 (i386-avx-linux.o, i386-mmx.o, i386-mmx-linux.o, reg-ia64.o)
7753 (reg-m32r.o, reg-m68k.o, reg-cf.o, mips-linux.o, mips-dsp-linux.o)
7754 (mips64-linux.o, mips64-dsp-linux.o, powerpc-32.o, powerpc-32l.o)
7755 (powerpc-altivec32l.o, powerpc-cell32l.o, powerpc-vsx32l.o)
7756 (powerpc-isa205-32l.o, powerpc-isa205-altivec32l.o)
7757 (powerpc-isa205-vsx32l.o, powerpc-e500l.o, powerpc-64l.o)
7758 (powerpc-altivec64l.o, powerpc-cell64l.o, powerpc-vsx64l.o)
7759 (powerpc-isa205-64l.o, powerpc-isa205-altivec64l.o)
7760 (powerpc-isa205-vsx64l.o, s390-linux32.o, s390-linux32v1.o)
7761 (s390-linux32v2.o, s390-linux64.o, s390-linux64v1.o)
7762 (s390-linux64v2.o, s390x-linux64.o, s390x-linux64v1.o)
7763 (s390x-linux64v2.o, tic6x-c64xp-linux.o, tic6x-c64x-linux.o)
7764 (tic6x-c62x-linux.o, reg-sh.o, reg-sparc64.o, reg-spu.o, amd64.o)
7765 (amd64-linux.o, amd64-avx.o, amd64-avx-linux.o, x32.o)
7766 (x32-linux.o, x32-avx.o, x32-avx-linux.o, reg-xtensa.o)
7767 (reg-tilegx.o): Remove.
7768 (all_object_files): New macro.
7769 Include .deps files.
7770 * aclocal.m4, configure: Rebuild.
7771 * acinclude.m4: Include depstand.m4, lead-dot.m4.
7772 * configure.ac: Invoke ZW_CREATE_DEPDIR,
7773 ZW_PROG_COMPILER_DEPENDENCIES. Compute GMAKE condition.
7775 2012-12-05 Tom Tromey <tromey@redhat.com>
7778 * server.h (current_insn_ptr, emit_error): Declare 'extern'.
7780 2012-11-28 Markus Metzger <markus.t.metzger@intel.com>
7782 * configure.ac: Check for linux/perf_event.h.
7783 * config.in: Regenerated.
7784 * configure: Regenerated.
7786 2012-11-26 Maxime Villard <rustyBSD@gmx.fr>
7788 * hostio.c (handle_readlink): Decrease buffer size
7789 parameter passed to readlink by one byte.
7791 2012-11-26 Yao Qi <yao@codesourcery.com>
7793 * configure.ac (build_warnings): Append '-Wempty-body'.
7794 * configure: Regenerated.
7795 * linux-low.c (linux_create_inferior): Use braces for empty 'if'
7798 2012-11-15 Pierre Muller <muller@sourceware.org>
7800 * configure.ac (AC_CHECK_HEADERS): Add wait.h header.
7801 * config.in: Regenerate.
7802 * configure: Regenerate.
7803 * linux-low.c: Use "gdb_stat.h" header instead of <sys/stat.h> header.
7804 Use "gdb_wait.h" header instead of <sys/wait.h> header.
7805 * lynx-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
7806 * remote-utils.c: Use "gdb_stat.h" header instead of <sys/stat.h>
7808 * server.c: Remove HAVE_WAIT_H conditional. Use "gdb_wait.h" header
7809 instead of <sys/wait.h> header.
7810 * spu-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
7812 2012-11-13 Markus Metzger <markus.t.metzger@intel.com>
7814 * Makefile.in: (INTERNAL_CFLAGS): Add -DGDBSERVER
7815 (various make rules): Remove -DGDBSERVER
7817 2012-11-09 Yao Qi <yao@codesourcery.com>
7819 * spu-low.c (current_ptid): Move it to ..
7820 * gdbthread.h: ... here. New.
7821 * remote-utils.c (read_ptid): Use macro 'current_ptid'.
7822 * server.c (myresume, process_serial_event): Likewise.
7823 * thread-db.c (thread_db_find_new_threads): Likewise.
7824 * tracepoint.c (run_inferior_command): Likewise.
7826 2012-10-01 Andrew Burgess <aburgess@broadcom.com>
7828 * server.c (handle_search_memory_1): Include access length in
7831 2012-09-05 Michael Brandt <michael.brandt@axis.com>
7833 * linux-crisv32-low.c: Fix compile errors.
7835 2012-09-04 Yao Qi <yao@codesourcery.com>
7837 * tracepoint.c (cmd_qtsv): Adjust debug message.
7838 Don't check CUR_TPOINT.
7840 2012-08-28 Yao Qi <yao@codesourcery.com>
7842 * ax.c, tracepoint.c: Replace ATTR_FORMAT with ATTRIBUTE_PRINTF.
7843 * server.h: Include 'libiberty.h' and 'ansidecl.h'.
7844 (ATTR_NORETURN, ATTR_FORMAT, ATTR_MALLOC): Remove.
7845 Remove declarations of xmalloc, xreallloc, xstrdup and
7847 * Makefile.in (libiberty_h): New.
7848 (server_h): Append dependencies 'libiberty.h' and 'ansidecl.h'.
7849 (linux-bfin-low.o): Append dependency 'libiberty.h'.
7851 2012-08-23 Yao Qi <yao@codesourcery.com>
7853 * server.h: Remove declaration of 'xsnprintf'.
7855 2012-08-22 Keith Seitz <keiths@redhat.com>
7857 * server.h: Include build-gnulib-gbserver/config.h.
7858 * gdbreplay.c: Likewise.
7860 2012-08-08 Doug Evans <dje@google.com>
7862 * Makefile.in (SFILES): Add gdb_vecs.c.
7863 (OBS): Add gdb_vecs.o.
7864 (gdb_vecs_h, host_defs_h): New variables.
7865 (thread-db.o): Add $(gdb_vecs_h) dependency.
7866 (gdb_vecs.o): New rule.
7867 * thread-db.c: #include "gdb_vecs.h".
7868 (thread_db_load_search): Use a vector to iterate over path elements.
7869 Handle text appearing after "$pdir".
7871 * configure.ac: Add check for strstr.
7872 * config.in: Regenerate.
7873 * configure: Regenerate.
7875 2012-08-02 Ulrich Weigand <ulrich.weigand@linaro.org>
7877 * hostio.c (handle_pread): If pread fails, fall back to attempting
7879 (handle_pwrite): Likewise for pwrite.
7881 2012-08-01 Ulrich Weigand <ulrich.weigand@linaro.org>
7883 * linux-arm-low.c (arm_linux_hw_point_initialize): Distinguish
7884 between unsupported TYPE and unimplementable ADDR/LEN combination.
7885 (arm_insert_point): Act on new return value.
7887 2012-07-31 Pedro Alves <palves@redhat.com>
7889 * server.c (process_point_options): Only skip tokens if we find
7890 one that is unrecognized. Don't treat 'X' specially while
7891 skipping unrecognized tokens.
7893 2012-07-30 Ulrich Weigand <ulrich.weigand@linaro.org>
7895 * linux-arm-low.c (arm_linux_hw_point_initialize): Do not attempt
7896 to 4-byte-align HW breakpoint addresses for Thumb.
7898 2012-07-27 Yao Qi <yao@codesourcery.com>
7902 * server.h: Declare gdb_agent_about_to_close.
7903 * target.c (kill_inferior): Include "agent.h".
7904 New. Send command 'kill'.
7905 * target.h (kill_inferior): Removed macro.
7906 * tracepoint.c (gdb_agent_about_to_close): New.
7907 (gdb_agent_helper_thread): Handle command 'close'.
7908 Wait endlessly until the inferior stops.
7909 Install gdb_agent_remove_socket to atexit hook.
7910 (agent_socket_name): New static variable.
7911 (gdb_agent_socket_init): Replace local variable 'name' with
7912 'agent_socket_name'.
7913 (gdb_agent_remove_socket): New.
7915 2012-07-27 Yao Qi <yao@codesourcery.com>
7917 * server.c (process_point_options): Stop at 'X' when parsing.
7919 2012-07-19 Michael Eager <eager@eagercon.com>
7921 * i386-low.c (Z_packet_to_hw_type): Add Z_PACKET_HW_BP, translate
7923 * linux-x86-low.c (x86_insert_point, x86_remove_point):
7924 Call i386_low_insert_watchpoint, i386_low_remove_watchpoint to add/del
7925 hardware breakpoint.
7927 2012-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
7929 * gdbserver/linux-low.c (initialize_low): Call
7930 linux_ptrace_init_warnings.
7932 2012-07-02 Doug Evans <dje@google.com>
7934 * mem-break.c (gdb_no_commands_at_breakpoint): Fix cast from
7937 2012-07-02 Stan Shebs <stan@codesourcery.com>
7939 * Makefile.in (WARN_CFLAGS_NO_FORMAT): Define.
7940 (ax.o): Add it to build rule.
7942 (OBS): Add format.o.
7943 (IPA_OBS): Add format.o.
7944 * server.c (handle_query): Claim support for breakpoint commands.
7945 (process_point_options): Add command case.
7946 (process_serial_event): Leave running if there are printfs in
7948 * mem-break.h (any_persistent_commands): Declare.
7949 (add_breakpoint_commands): Declare.
7950 (gdb_no_commands_at_breakpoint): Declare.
7951 (run_breakpoint_commands): Declare.
7952 * mem-break.c (struct point_command_list): New struct.
7953 (struct breakpoint): New field command_list.
7954 (any_persistent_commands): New function.
7955 (add_commands_to_breakpoint): New function.
7956 (add_breakpoint_commands): New function.
7957 (gdb_no_commands_at_breakpoint): New function.
7958 (run_breakpoint_commands): New function.
7959 * linux-low.c (linux_wait_1): Test for and run breakpoint commands
7961 * ax.c: Include format.h.
7962 (ax_printf): New function.
7963 (gdb_eval_agent_expr): Add printf opcode.
7965 2012-06-13 Yao Qi <yao@codesourcery.com>
7967 * server.c (start_inferior): Remove duplicated writes to fields
7968 'last_resume_kind' and 'last_status' of 'current_inferior'.
7970 2012-06-12 Yao Qi <yao@codesourcery.com>
7971 Pedro Alves <palves@redhat.com>
7973 * linux-low.c (linux_set_resume_request): Simplify predicate. Add
7975 * server.c (handle_v_cont): Extend comment.
7977 2012-06-11 Yao Qi <yao@codesourcery.com>
7979 * linux-low.c (linux_attach): Add 'static'.
7981 2012-06-06 Yao Qi <yao@codesourcery.com>
7983 * ax.c (gdb_eval_agent_expr): Print `top' in hex.
7985 2012-06-01 Jan Kratochvil <jan.kratochvil@redhat.com>
7987 Fix gcc -flto compilation warning.
7988 * server.c (main): Make variable multi_mode and attach volatile.
7990 2012-05-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
7992 * linux-low.c (get_r_debug): Disable code using DT_MIPS_RLD_MAP
7993 if the platform doesn't know about it.
7995 2012-05-30 Jeff Kenton <jkenton@tilera.com>
7997 * Makefile.in (SFILES): Add linux-tile-low.c.
7998 (linux-tile-low.o, reg-tilegx.o, reg-tilegx.c): New rules.
7999 * configure.srv: Handle tilegx-*-linux*.
8000 * linux-tile-low.c: New file.
8002 2012-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
8004 * linux-low.c (linux_qxfer_libraries_svr4): Return -1 if R_DEBUG is -1.
8006 2012-05-24 Pedro Alves <palves@redhat.com>
8010 Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.
8012 2012-05-24 Pedro Alves <palves@redhat.com>
8016 Replace target_signal with gdb_signal throughout.
8018 2012-05-22 Maciej W. Rozycki <macro@codesourcery.com>
8020 * linux-low.c (linux_store_registers): Avoid the copying sequence
8021 when no data has been retrieved by ptrace.
8023 2012-05-22 Will Deacon <will.deacon@arm.com>
8025 * linux-low (__UCLIBC__ && !(__UCLIBC_HAS_MMU__ || __ARCH_HAS_MMU__)):
8026 Include asm/ptrace.h.
8027 (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define only if not
8030 2012-05-21 Maciej W. Rozycki <macro@codesourcery.com>
8032 * linux-low.c (linux_store_registers): Don't re-retrieve data
8033 with ptrace that has already been obtained from /proc. Always
8034 copy any data retrieved with ptrace to the buffer supplied.
8036 2012-05-11 Yao Qi <yao@codesourcery.com>
8037 Pedro Alves <palves@redhat.com>
8039 * linux-low.c (enum stopping_threads_kind): New.
8040 (stopping_threads): Change type to `enum stopping_threads_kind'.
8041 (handle_extended_wait): If stopping and suspending threads, leave
8042 the new_lwp suspended too.
8043 (linux_wait_for_event): Adjust.
8044 (stop_all_lwps): Set `stopping_threads' to
8045 STOPPING_AND_SUSPENDING_THREADS or STOPPING_THREADS depending on
8046 whether we're suspending threads or just stopping them. Assert no
8049 2012-04-29 Yao Qi <yao@codesourcery.com>
8051 * server.h: Move some code to ...
8052 * gdbthread.h: ... here. New.
8053 * Makefile.in (inferiors.o, regcache.o): Depends on gdbthread.h
8054 (remote-utils.o, server.o, target.o tracepoint.o): Likewise.
8055 (nto-low.o, win32-low.o): Likewise.
8056 * inferiors.c, linux-low.h, nto-low.c: Include gdbthread.h.
8057 * regcache.c, remote-utils.c, server.c: Likewise.
8058 * target.c, tracepoint.c, win32-low.c: Likewise.
8060 2012-04-24 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
8062 * linux-low.h (PTRACE_ARG3_TYPE): Move macro from linux-low.c.
8063 (PTRACE_ARG4_TYPE): Likewise.
8064 (PTRACE_XFER_TYPE): Likewise.
8065 * linux-arm-low.c (arm_prepare_to_resume): Cast third argument of
8066 ptrace to PTRACE_ARG3_TYPE.
8067 * linux-low.c (PTRACE_ARG3_TYPE): Move macro to linux-low.h.
8068 (PTRACE_ARG4_TYPE): Likewise.
8069 (PTRACE_XFER_TYPE): Likewise.
8070 (linux_detach_one_lwp): Cast fourth argument of
8071 ptrace to long then PTRACE_ARG4_TYPE.
8072 (regsets_fetch_inferior_registers): Cast third argument of
8073 ptrace to long then PTRACE_ARG3_TYPE.
8074 (regsets_store_inferior_registers): Likewise.
8076 2012-04-20 Pedro Alves <palves@redhat.com>
8078 * configure: Regenerate.
8080 2012-04-19 Pedro Alves <palves@redhat.com>
8082 * Makefile.in (GNULIB_BUILDDIR): New.
8083 (LIBGNU, INCGNU, GNULIB_H): Adjust.
8084 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): New.
8085 (all, install-only, uninstall, clean-info, all-lib, clean): No
8086 longer pass GNULIB_FLAGS_TO_PASS. Use subdir_do.
8087 (maintainer-clean realclean distclean): Use subdir_do.
8089 (gnulib/import/Makefile): Adjust. Replace gnulib/import with
8090 $(GNULIB_BUILDDIR). Don't pass argument to config.status.
8091 * acinclude.m4: Include acx_configure_dir.m4.
8092 * configure.ac: Remove gl_EARLY, gl_INIT, and AM_INIT_AUTOMAKE
8093 calls. Call AC_PROG_RANLIB. Configure gnulib using
8096 (GNULIB_STDINT_H): Adjust.
8097 (AC_OUTPUT): Don't output gnulib/Makefile anymore.
8098 * gdbreplay.c: Include build-gnulib/config.h.
8099 * server.h: Likewise.
8100 * aclocal.m4: Regenerate.
8101 * config.in: Regenerate.
8102 * configure: Regenerate.
8104 2012-04-19 Pedro Alves <palves@redhat.com>
8106 * Makefile.in (LIBGNU, INCGNU): Adjust.
8107 (GNULIB_FLAGS_TO_PASS, GNULIB_H): Adjust.
8108 (all, install-only, uninstall, clean-info, all-lib, clean)
8109 (maintainer-clean, Makefile, gnulib/Makefile): Adjust.
8110 * configure.ac: Adjust AC_OUTPUT output.
8111 * aclocal.m4: Regenerate.
8112 * configure: Regenerate.
8114 2012-04-19 Pedro Alves <palves@redhat.com>
8116 * Makefile.in (generated_files): New.
8117 (server_h): Remove the explicit dependency on config.h, and depend
8118 on $generated_files.
8120 2012-04-19 Pedro Alves <palves@redhat.com>
8122 * Makefile.in (INCGNU): Add -Ignulib.
8124 2012-04-19 Pedro Alves <palves@redhat.com>
8126 * Makefile.in (GNULIB_INCLUDE_DIR): Rename to ...
8127 (INCGNU): ... this, and spell out -I here.
8128 (GNULIB_LIB): Rename to ...
8130 (INCLUDE_CFLAGS, gdbserver$(EXEEXT), $(GNULIB_LIB) rule): Adjust.
8132 2012-04-19 Pedro Alves <palves@redhat.com>
8134 * config.in: Regenerate.
8136 2012-04-19 Pedro Alves <palves@redhat.com>
8138 * configure.ac: Remove AC_CHECK_DECLS check for memmem.
8139 * server.h (memmem): Remove declaration.
8140 * config.in: Regenerate.
8141 * configure: Regenerate.
8143 2012-04-19 Yao Qi <yao@codesourcery.com>
8145 * Makefile.in (SFILES): Add common/vec.c.
8149 2012-04-19 Yao Qi <yao@codesourcery.com>
8151 * remote-utils.c (prepare_resume_reply): Replace with macro
8152 target_core_of_thread.
8153 * server.c (handle_qxfer_threads_proper): Likewise.
8154 * target.h (traget_core_of_thread): New macro.
8156 2012-04-18 Pedro Alves <palves@redhat.com>
8158 * aclocal.m4: Regenerate.
8159 * configure: Regenerate.
8161 2012-04-16 Yao Qi <yao@codesourcery.com>
8163 * tracepoint.c (cmd_qtstart): Download tracepoints even when they are
8164 duplicated on address.
8166 2012-04-16 Yao Qi <yao@codesourcery.com>
8168 * tracepoint.c (COPY_FIELD_TO_BUF): New macro.
8169 (struct tracepoint_action_ops) <send>: New field.
8170 (m_tracepoint_action_send, r_tracepoint_action_send): New.
8171 (agent_expr_send, x_tracepoint_action_send): New.
8172 (l_tracepoint_action_send): New.
8173 (cmd_qtdp): Download and install tracepoint
8174 according to `use_agent'.
8175 (run_inferior_command): Add one more parameter `len'.
8177 (tracepoint_send_agent): New.
8178 (cmd_qtdp, cmd_qtstart): Call tracepoint_send_agent.
8180 2012-04-16 Yao Qi <yao@codesourcery.com>
8182 * tracepoint.c (download_tracepoints): Moved to ...
8183 (cmd_qtstart): ... here.
8185 2012-04-14 Yao Qi <yao@codesourcery.com>
8187 * tracepoint.c: Include inttypes.h.
8188 (struct collect_memory_action): Use sized types.
8189 (struct tracepoint): Likewise.
8190 (cmd_qtdp, stop_tracing): Update print specifiers.
8191 (cmd_qtp, response_tracepoint): Likewise.
8192 (collect_data_at_tracepoint): Likewise.
8193 (collect_data_at_step): Likewise.
8195 2012-04-14 Yao Qi <yao@codesourcery.com>
8197 Import gnulib module inttypes.
8198 * aclocal.m4, config.in, configure: Regenerated.
8200 2012-04-14 Yao Qi <yao@codesourcery.com>
8202 * Makefile.in (maintainer-clean, realclean, distclean): Remove
8203 Makefile and config.status at last.
8205 2012-04-13 Yao Qi <yao@codesourcery.com>
8207 * tracepoint.c: Include stdint.h unconditionally.
8209 2012-04-13 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
8211 * acinclude.m4 (GDBSERVER_HAVE_THREAD_DB_TYPE): New macro based
8212 on BFD_HAVE_SYS_PROCFS_TYPE.
8213 * configure.ac: Look for lwpid_t and psaddr_t in libthread_db.h.
8214 * configure: Regenerate.
8215 * config.in: Likewise.
8217 2012-04-13 H.J. Lu <hongjiu.lu@intel.com>
8219 * Makefile.in (clean): Also remove x32.c x32-linux.c
8220 x32-avx.c x32-avx-linux.c.
8221 (x32.o): New target.
8223 (x32-linux.o): Likewise.
8224 (x32-linux.c): Likewise.
8225 (x32-avx.o): Likewise.
8226 (x32-avx.c): Likewise.
8227 (x32-avx-linux.o): Likewise.
8228 (x32-avx-linux.c): Likewise.
8230 * configure.srv (srv_amd64_regobj): Add x32.o x32-avx.o.
8231 (srv_amd64_linux_regobj): Add x32-linux.o x32-avx-linux.o.
8232 (srv_i386_64bit_xmlfiles): Add i386/x32-core.xml.
8233 (srv_amd64_xmlfiles): Add i386/x32.xml i386/x32-avx.xml.
8234 (srv_amd64_linux_xmlfiles): Add i386/x32-linux.xml
8235 i386/x32-avx-linux.xml.
8237 * linux-x86-low.c (init_registers_x32_linux): New prototype.
8238 (init_registers_x32_avx_linux): Likwise.
8239 (x86_linux_update_xmltarget): Call init_registers_x32_linux
8240 or init_registers_x32_avx_linux if linux_is_elf64 is false.
8242 2012-04-13 Pedro Alves <palves@redhat.com>
8244 * Makefile.in (GNULIB_FLAGS_TO_PASS): New.
8245 (FLAGS_TO_PASS): Don't change or set $top_srcdir, $srcdir and VPATH.
8246 (all, uninstall, clean-info, all-lib, clean, maintainer-clean)
8247 (realclean, distclean): Explicitly pass $GNULIB_FLAGS_TO_PASS to
8250 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
8252 * linux-x86-low.c (compat_x32_clock_t): New.
8253 (compat_x32_siginfo_t): Likewise.
8254 (compat_x32_siginfo_from_siginfo): Likewise.
8255 (siginfo_from_compat_x32_siginfo): Likewise.
8256 (linux_is_elf64): Likewise.
8257 (x86_siginfo_fixup): Call compat_x32_siginfo_from_siginfo
8258 and siginfo_from_compat_x32_siginfo for x32.
8259 (x86_arch_setup): Set linux_is_elf64.
8261 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
8264 * linux-low.c (linux_pid_exe_is_elf_64_file): Also return the
8266 (linux_qxfer_libraries_svr4): Update call to elf_64_file_p.
8267 * linux-low.h (linux_pid_exe_is_elf_64_file): Updated.
8268 * linux-x86-low.c (x86_arch_setup): Check if GDBserver is
8269 compatible with process.
8271 2012-04-12 Yao Qi <yao@codesourcery.com>
8273 * Makefile.in: Define abs_top_srcdir and abs_srcdir.
8274 (INCLUDE_CFLAGS): Append GNULIB_INCLUDE_DIR.
8275 (install-only, install-info, clean): Handle sub dir gnulib.
8276 (all-lib, am--refresh): New targets.
8277 (memmem.o): Remove target.
8278 * configure.ac: Remove AC_CONFIG_LIBOBJ_DIR.
8279 Invoke gl_EARLY. Invoke AC_CHECK_PROGS for make.
8280 (AC_REPLACE_FUNCS): Remove memmem.
8281 Invoke gl_INIT and AM_INIT_AUTOMAKE.
8282 (AC_OUTPUT): Generate Makefile in gnulib/.
8283 * aclocal.m4, config.in, configure: Regenerated.
8285 2012-04-10 Maciej W. Rozycki <macro@codesourcery.com>
8287 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP.
8289 2012-04-05 Pedro Alves <palves@redhat.com>
8291 -Werror=strict-aliasing
8293 * spu-low.c (parse_spufs_run): Avoid dereferencing type-punned
8296 2012-04-04 Pedro Alves <palves@redhat.com>
8298 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
8299 (sparc_store_gregset_from_stack, sparc_store_gregset)
8300 (sparc_breakpoint_at): Fix formatting.
8302 2012-03-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
8304 * configure.ac: Check whether Elf32_auxv_t and Elf64_auxv_t
8306 * linux-low.c [HAVE_ELF32_AUXV_T] (Elf32_auxv_t): Add typedef.
8307 [HAVE_ELF64_AUXV_T] (Elf64_auxv_t): Likewise.
8308 * config.in: Regenerate.
8309 * configure: Likewise.
8311 2012-03-29 Pedro Alves <palves@redhat.com>
8313 * linux-low.c (regsets_store_inferior_registers) [__sparc__]:
8314 Correct ptrace arguments.
8316 2012-03-28 Pedro Alves <palves@redhat.com>
8318 * linux-ia64-low.c (ia64_regmap): Map IA64_EC_REGNUM to PT_AR_EC.
8319 (IA64_GR0_REGNUM, IA64_FR0_REGNUM)
8320 (IA64_FR1_REGNUM): New defines.
8321 (ia64_fetch_register): New.
8322 (the_low_target): Install it.
8323 * linux-low.h (struct linux_target_ops) <fetch_register>: New
8325 * linux-low.c (linux_fetch_registers): Try the
8326 the_low_target.fetch_register hook first.
8328 * linux-arm-low.c (the_low_target): Adjust.
8329 * linux-bfin-low.c (the_low_target): Adjust.
8330 * linux-cris-low.c (the_low_target): Adjust.
8331 * linux-crisv32-low.c (the_low_target): Adjust.
8332 * linux-m32r-low.c (the_low_target): Adjust.
8333 * linux-m68k-low.c (the_low_target): Adjust.
8334 * linux-mips-low.c (the_low_target): Adjust.
8335 * linux-ppc-low.c (the_low_target): Adjust.
8336 * linux-s390-low.c (the_low_target): Adjust.
8337 * linux-sh-low.c (the_low_target): Adjust.
8338 * linux-sparc-low.c (the_low_target): Adjust.
8339 * linux-tic6x-low.c (the_low_target): Adjust.
8340 * linux-x86-low.c (the_low_target): Adjust.
8341 * linux-xtensa-low.c (the_low_target): Adjust.
8343 2012-03-26 Pedro Alves <palves@redhat.com>
8345 * server.c (handle_qxfer_libraries): Don't bail early if
8346 the_target->qxfer_libraries_svr4 is not NULL.
8348 2012-03-26 Pedro Alves <palves@redhat.com>
8350 * linux-low.c (linux_qxfer_libraries_svr4): Fix pasto in comment.
8352 2012-03-23 Pedro Alves <palves@redhat.com>
8354 * linux-low.c (linux_qxfer_libraries_svr4): Terminate the
8355 "library-list-svr4" element's start tag when the the DSO list is
8358 2012-03-23 Pedro Alves <palves@redhat.com>
8360 * linux-low.c (read_one_ptr): Read the inferior's pointer through
8361 a variable whose type size is the same as the inferior's pointer
8364 2012-03-21 Thomas Schwinge <thomas@codesourcery.com>
8366 * linux-arm-low.c (arm_stopped_by_watchpoint): Use siginfo_t instead of
8368 * linux-low.c (siginfo_fixup, linux_xfer_siginfo): Likewise.
8369 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
8370 * linux-low.h: Include <signal.h>.
8371 (struct siginfo): Remove forward declaration.
8372 (struct linux_target_ops) <siginfo_fixup>: Use siginfo_t instead of
8375 2012-03-21 Mike Frysinger <vapier@gentoo.org>
8377 * .gitignore: Ignore more files.
8379 2012-03-19 Pedro Alves <palves@redhat.com>
8380 Jan Kratochvil <jan.kratochvil@redhat.com>
8382 * server.c (cont_thread, general_thread): Add describing comments.
8383 (start_inferior): Clear `cont_thread'.
8384 (handle_v_cont): Don't set `cont_thread' if resuming all threads
8387 2012-03-15 Yao Qi <yao@codesourcery.com>
8389 * tracepoint.c (install_tracepoint): Move duplicated tracepoint
8391 (cmd_qtdp): ... here.
8393 2012-03-15 Yao Qi <yao@codesourcery.com>
8395 * tracepoint.c (struct tracepoint_action_ops): New.
8396 (struct tracepoint_action) [!IN_PROCESS_AGENT] <ops>: New field.
8397 (m_tracepoint_action_download): New.
8398 (r_tracepoint_action_download): New.
8399 (x_tracepoint_action_download): New.
8400 (l_tracepoint_action_download): New.
8401 (add_tracepoint_action): Install `action->ops' according type.
8402 (download_tracepoint_1): Move code `download' function pointer
8403 of various tracepoint_action_ops.
8405 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
8407 * linux-low.c (linux_attach_lwp_1): New variable buffer. Call
8408 linux_ptrace_attach_warnings.
8410 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
8412 * Makefile.in (linux-ptrace.o): New.
8413 * configure.srv (arm*-*-linux*, bfin-*-*linux*, crisv32-*-linux*)
8414 (cris-*-linux*, i[34567]86-*-linux*, ia64-*-linux*, m32r*-*-linux*)
8415 (m68*-*-linux*, m68*-*-uclinux*, mips*-*-linux*, powerpc*-*-linux*)
8416 (s390*-*-linux*, sh*-*-linux*, sparc*-*-linux*, tic6x-*-uclinux)
8417 (x86_64-*-linux*, xtensa*-*-linux*): Add linux-ptrace.o to SRV_TGTOBJ
8419 * linux-low.c (linux_attach_lwp_1): Remove redundent else clause.
8421 2012-03-08 Yao Qi <yao@codesourcery.com>
8422 Pedro Alves <palves@redhat.com>
8424 Fix PR server/13392.
8425 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Check
8427 * tracepoint.c (remove_tracepoint): New.
8428 (cmd_qtdp): Call remove_tracepoint when failed to install.
8430 2012-03-07 Pedro Alves <palves@redhat.com>
8432 * linux-low.c (get_detach_signal): New.
8433 (linux_detach_one_lwp): Get rid of a pending SIGSTOP with SIGCONT.
8434 Pass on pending signals to PTRACE_DETACH. Check the result of the
8436 * server.c (program_signals, program_signals_p): New.
8437 (handle_general_set): Handle QProgramSignals.
8438 * server.h (program_signals, program_signals_p): Declare.
8440 2012-03-05 Pedro Alves <palves@redhat.com>
8441 Jan Kratochvil <jan.kratochvil@redhat.com>
8443 * linux-low.c (get_dynamic): Don't warn when PT_PHDR isn't found.
8446 2012-03-03 Yao Qi <yao@codesourcery.com>
8448 * tracepoint.c (tracepoint_look_up_symbols): Update call to
8449 agent_look_up_symbols.
8451 2012-03-03 Yao Qi <yao@codesourcery.com>
8453 * Makefile.in (linux-low.o): Keep dependence on agent.h.
8454 (linux-x86-low.o): Likewise.
8455 * server.h: Remove in_process_agent_loaded.
8456 * tracepoint.c (in_process_agent_loaded): Removed. Moved it
8460 2012-03-03 Yao Qi <yao@codesourcery.com>
8462 * tracepoint.c (gdb_agent_capability): New global.
8463 (in_process_agent_loaded_ust): Renamed to
8464 `in_process_agent_supports_ust'.
8466 (in_process_agent_supports_ust): Call agent_capability_check.
8467 (clear_installed_tracepoints): Assert that agent supports
8470 2012-03-03 Yao Qi <yao@codesourcery.com>
8472 * linux-low.c (linux_supports_agent): New.
8473 (linux_target_ops): Initialize field `supports_agent' with
8474 linux_supports_agent.
8475 * target.h (struct target_ops) <supports_agent>: New.
8476 (target_supports_agent): New macro.
8477 * server.c (handle_general_set): Handle packet 'QAgent'.
8478 (handle_query): Send `QAgent+'.
8479 * Makefile.in (server.o): Depends on agent.h.
8481 2012-03-03 Yao Qi <yao@codesourcery.com>
8483 * Makefile.in (OBS): Add agent.o.
8484 Add new rule for agent.o.
8485 Track dependence of tracepoint.c on agent.h.
8486 * tracepoint.c (run_inferior_command_1):
8487 (run_inferior_command): Call agent_run_command.
8488 (gdb_ust_connect_sync_socket): Deleted. Move it to
8490 (resume_thread, stop_thread): Likewise.
8491 (gdb_ust_socket_init): Renamed to ...
8492 (gdb_agent_socket_init): ... New.
8493 (gdb_ust_thread): Renamed to ...
8494 (gdb_agent_helper_thread): ... New.
8495 (gdb_ust_init): Move some code to ...
8496 (gdb_agent_init): ... here. New.
8497 [HAVE_UST]: Call gdb_ust_init.
8498 (initialize_tracepoint_ftlib): Call gdb_agent_init.
8499 * configure.ac: Add `sys/un.h' to AC_CHECK_HEADERS.
8500 * config.in, configure: Regenerated.
8502 2012-03-02 Pedro Alves <palves@redhat.com>
8504 * inferiors.c (add_pid_to_list, pull_pid_from_list): Delete.
8505 * linux-low.c (struct simple_pid_list): New.
8506 (stopped_pids): New a struct simple_pid_list pointer.
8507 (add_to_pid_list, pull_pid_from_list): New.
8508 (handle_extended_wait): Don't assume the first signal new children
8509 report is SIGSTOP. Adjust call to pull_pid_from_list.
8510 (linux_wait_for_lwp): Adjust.
8512 2012-03-02 Yao Qi <yao@codesourcery.com>
8514 * tracepoint.c (do_action_at_tracepoint): Write `stop_pc' in
8517 2012-03-02 Yao Qi <yao@codesourcery.com>
8519 * tracepoint.c (collect_ust_data_at_tracepoint): Remove parameters
8520 `stop_pc' and `tpoint'. Update caller.
8522 2012-03-01 Maciej W. Rozycki <macro@codesourcery.com>
8524 * linux-low.h (linux_target_ops): Add regset_bitmap member.
8525 * linux-low.c (use_linux_regsets): New macro.
8526 [!HAVE_LINUX_REGSETS] (regsets_fetch_inferior_registers): Likewise.
8527 [!HAVE_LINUX_REGSETS] (regsets_store_inferior_registers): Likewise.
8528 (linux_register_in_regsets): New function.
8529 (usr_fetch_inferior_registers): Skip registers covered by
8531 (usr_store_inferior_registers): Likewise.
8532 (usr_fetch_inferior_registers): New macro.
8533 (usr_store_inferior_registers): Likewise.
8534 (linux_fetch_registers): Handle mixed regset/non-regset targets.
8535 (linux_store_registers): Likewise.
8536 * linux-mips-low.c (init_registers_mips_dsp_linux): New
8538 (init_registers_mips64_dsp_linux): Likewise.
8539 (init_registers_mips_linux): New macro.
8540 (init_registers_mips_dsp_linux): Likewise.
8541 (mips_dsp_num_regs): Likewise.
8542 (DSP_BASE, DSP_CONTROL): New fallback macros.
8543 (mips_base_regs): New macro.
8544 (mips_regmap): Use it. Fix the size.
8545 (mips_dsp_regmap): New variable.
8546 (mips_dsp_regset_bitmap): Likewise.
8547 (mips_arch_setup): New function.
8548 (mips_cannot_fetch_register): Use the_low_target.regmap rather
8550 (mips_cannot_store_register): Likewise.
8551 (the_low_target): Update .arch_setup, .num_regs and .regmap
8552 initializers. Add .regset_bitmap initializer.
8553 * linux-arm-low.c (the_low_target): Add .regset_bitmap
8555 * linux-bfin-low.c (the_low_target): Likewise.
8556 * linux-cris-low.c (the_low_target): Likewise.
8557 * linux-crisv32-low.c (the_low_target): Likewise.
8558 * linux-ia64-low.c (the_low_target): Likewise.
8559 * linux-m32r-low.c (the_low_target): Likewise.
8560 * linux-m68k-low.c (the_low_target): Likewise.
8561 * linux-ppc-low.c (the_low_target): Likewise.
8562 * linux-s390-low.c (the_low_target): Likewise.
8563 * linux-sh-low.c (the_low_target): Likewise.
8564 * linux-sparc-low.c (the_low_target): Likewise.
8565 * linux-tic6x-low.c (the_low_target): Likewise.
8566 * linux-x86-low.c (the_low_target): Likewise.
8567 * linux-xtensa-low.c (the_low_target): Likewise.
8568 * configure.srv <mips*-*-linux*>: Add mips-dsp-linux.o and
8569 mips64-dsp-linux.o to srv_regobj. Add mips-dsp-linux.xml,
8570 mips64-dsp-linux.xml, mips-dsp.xml and mips64-dsp.xml to
8572 * Makefile.in (mips-dsp-linux.o, mips-dsp-linux.c): New targets.
8573 (mips64-dsp-linux.o, mips64-dsp-linux.c): Likewise.
8575 2012-02-29 Yao Qi <yao@codesourcery.com>
8576 Pedro Alves <palves@redhat.com>
8578 * linux-low.c: (linux_wait_1): Call unsuspend_all_lwps when
8579 `step_over_finished' is true.
8581 2012-02-27 Pedro Alves <palves@redhat.com>
8583 * linux-low.c (pid_is_stopped): Delete, moved to common/.
8584 (linux_attach_lwp_1): Adjust to use linux_proc_pid_is_stopped.
8586 2012-02-27 Pedro Alves <palves@redhat.com>
8589 * linux-low.c (pid_is_stopped): New.
8590 (linux_attach_lwp_1): Handle attaching to 'T (stopped)' processes.
8592 2012-02-25 Luis Machado <lgustavo@codesourcery.com>
8594 * mem-break.c (clear_gdb_breakpoint_conditions): Fix de-allocation
8597 2012-02-24 Maciej W. Rozycki <macro@codesourcery.com>
8599 * linux-mips-low.c (mips_regmap): Correct the index of $f9.
8601 2012-02-24 Luis Machado <lgustavo@codesourcery>
8603 * server.c (handle_query): Advertise support for target-side
8604 breakpoint condition evaluation.
8605 (process_point_options): New function.
8606 (process_serial_event): When inserting a breakpoint, check for
8607 a target-side condition that should be evaluated.
8609 * mem-break.c: Include regcache.h and ax.h.
8610 (point_cond_list_t): New data structure.
8611 (breakpoint) <cond_list>: New field.
8612 (find_gdb_breakpoint_at): Make non-static.
8613 (delete_gdb_breakpoint_at): Clear any target-side
8615 (clear_gdb_breakpoint_conditions): New function.
8616 (add_condition_to_breakpoint): Likewise.
8617 (add_breakpoint_condition): Likewise.
8618 (gdb_condition_true_at_breakpoint): Likewise.
8619 (gdb_breakpoint_here): Return result directly instead
8620 of going through a local variable.
8622 * mem-break.h (find_gdb_breakpoint_at): New prototype.
8623 (clear_gdb_breakpoint_conditions): Likewise.
8624 (add_breakpoint_condition): Likewise.
8625 (gdb_condition_true_at_breakpoint): Likewise.
8627 * linux-low.c (linux_wait_1): Evaluate target-side breakpoint condition.
8628 (need_step_over_p): Take target-side breakpoint condition into
8631 2012-02-24 Luis Machado <lgustavo@codesourcery>
8633 * server.h: Include tracepoint.h.
8634 (agent_mem_read, agent_get_trace_state_variable_value,
8635 agent_set_trace_state_variable_value,
8636 agent_tsv_read, agent_mem_read_string, get_get_tsv_func_addr,
8637 get_set_tsv_func_addr): New prototypes.
8639 * ax.h: New include file.
8640 * ax.c: New source file.
8642 * tracepoint.c: Include ax.h.
8643 (gdb_agent_op, gdb_agent_op_names, gdb_agent_op_sizes,
8644 agent_expr, eval_result_type): Move to ax.h.
8645 (parse_agent_expr): Rename to ...
8646 (gdb_parse_agent_expr): ... this, make it non-static and move
8648 (unparse_agent_expr) Rename to ...
8649 (gdb_unparse_agent_expr): ... this, make it non-static and move
8651 (eval_agent_expr): Rename to ...
8652 (eval_tracepoint_agent_expr): ... this.
8653 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Remove
8654 forward declarations.
8655 (add_tracepoint_action): Call gdb_parse_agent_expr (...).
8656 (agent_get_trace_state_variable_value): New function.
8657 (agent_set_trace_state_variable_value): New function.
8658 (cmd_qtdp): Call gdb_parse_agent_expr (...).
8659 (response_tracepoint): Call gdb_unparse_agent_expr (...).
8660 (do_action_at_tracepoint): Call eval_tracepoint_agent_expr (...).
8661 (condition_true_at_tracepoint): Likewise.
8662 (parse_agent_expr): Rename to ...
8663 (gdb_parse_agent_expr): ... this and move to ax.c.
8664 (unparse_agent_expr): Rename to ...
8665 (gdb_unparse_agent_expr): ... this and move to ax.c.
8666 (gdb_agent_op_name): Move to ax.c.
8667 (eval_agent_expr): Rename to ...
8668 (gdb_eval_agent_expr): ... this, use regcache passed as parameter
8670 (eval_tracepoint_agent_expr): New function.
8671 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Make
8673 (current_insn_ptr, emit_error, struct bytecode_address): Move to
8675 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul, emit_lsh,
8676 emit_rsh_signed, emit_rsh_unsigned, emit_ext, emit_log_not,
8677 emit_bit_and, emit_bit_or, emit_bit_xor, emit_bit_not, emit_equal,
8678 emit_less_signed, emit_less_unsigned, emit_ref, emit_if_goto,
8679 emit_goto, write_goto_address, emit_const, emit_reg, emit_pop,
8680 emit_stack, emit_zero_ext, emit_swap, emit_stack_adjust,
8681 emit_int_call_1, emit_void_call_2, emit_eq_goto, emit_ne_goto,
8682 emit_lt_goto, emit_ge_goto, emit_gt_goto, emit_le_goto): Move to ax.c.
8683 (get_get_tsv_func_addr, get_set_tsv_func_addr): New functions.
8684 (compile_bytecodes): Remove forward declaration.
8685 (is_goto_target): Move to ax.c.
8686 (compile_bytecodes): Move to ax.c and call
8687 agent_get_trace_state_variable_value (...) and
8688 agent_set_trace_state_variable_value (...).
8690 * Makefile.in: Update ax.c and IPA dependencies.
8692 2012-02-24 Pedro Alves <palves@redhat.com>
8694 * tracepoint.c (cmd_bigqtbuffer): Rename as ...
8695 (cmd_bigqtbuffer_circular): ... this. Only handle
8696 'QTBuffer:circular:'.
8697 (handle_tracepoint_general_set): Adjust.
8699 2012-02-16 Yao Qi <yao@codesourcery.com>
8701 * inferiors.c: Move code to ...
8702 * dll.c: .... here. New.
8703 * server.h: Declare clear_dlls.
8704 * Makefile.in (SFILES): Add dll.c.
8708 2012-02-11 Yao Qi <yao@codesourcery.com>
8710 * server.c: (handle_monitor_command): Add a new parameter
8712 (handle_query): Update caller.
8714 2012-02-09 Joel Brobecker <brobecker@adacore.com>
8716 * configure.ac: Add readlink to AC_CHECK_FUNCS list.
8717 * configure, config.in: Regenerate.
8718 * hostio.c: Provide an alternate implementation if HAVE_READLINK
8721 2012-02-02 Pedro Alves <palves@redhat.com>
8723 Try SIGKILL first, then PTRACE_KILL.
8724 * linux-low.c (linux_kill_one_lwp): New.
8725 (linux_kill_one_lwp): Rename to ...
8726 (kill_one_lwp_callback): ... this. Use the new
8729 2012-02-02 Pedro Alves <palves@redhat.com>
8731 * tracepoint.c (cmd_qtminftpilen): Return 0 if there's no current
8734 2012-01-27 Pedro Alves <palves@redhat.com>
8736 * linux-low.c (linux_child_pid_to_exec_file): Delete.
8737 (elf_64_file_p): Make static.
8738 (linux_pid_exe_is_elf_64_file): New.
8739 * linux-low.h (linux_child_pid_to_exec_file, elf_64_file_p):
8740 Delete declarations.
8741 (linux_pid_exe_is_elf_64_file): Declare.
8742 * linux-x86-low.c (x86_arch_setup): Use
8743 linux_pid_exe_is_elf_64_file.
8745 2012-01-25 Jan Kratochvil <jan.kratochvil@redhat.com>
8747 * linux-low.c (linux_wait_for_event_1): Rename to ...
8748 (linux_wait_for_event): ... here and merge it with former
8749 linux_wait_for_event - new variable wait_ptid, use it.
8750 (linux_wait_for_event): Remove - merge it to linux_wait_for_event_1.
8752 2012-01-23 Pedro Alves <palves@redhat.com>
8754 * server.c (main): Avoid yet another case of infinite loop while
8755 detaching/killing after a longjmp.
8757 2012-01-20 Jan Kratochvil <jan.kratochvil@redhat.com>
8760 * linux-low.c (linux_wait_for_event_1): Use ptid_is_pid.
8762 2012-01-20 Ulrich Weigand <ulrich.weigand@linaro.org>
8764 * hostio.c (handle_readlink): New function.
8765 (handle_vFile): Call it to handle "vFile:readlink" packets.
8767 2012-01-20 Pedro Alves <palves@redhat.com>
8768 Ulrich Weigand <ulrich.weigand@linaro.org>
8770 * server.c (handle_v_requests): Only support vAttach and vRun to
8771 start multiple processes when in extended protocol mode.
8773 2012-01-17 Pedro Alves <palves@redhat.com>
8775 * tracepoint.c (initialize_tracepoint): Use mmap instead of
8776 memalign plus mprotect to allocate the scratch buffer.
8778 2012-01-13 Pedro Alves <palves@redhat.com>
8780 * server.c (attach_inferior): Clear `cont_thread'.
8782 2012-01-13 Pedro Alves <palves@redhat.com>
8784 * server.c (main): Avoid infinite loop while detaching/killing
8787 2012-01-09 Doug Evans <dje@google.com>
8789 * server.c (start_inferior): Set last_ptid in --wrapper case.
8791 2012-01-06 Yao Qi <yao@codesourcery.com>
8793 * tracepoint.c [IN_PROCESS_AGENT] (debug_threads): Macro
8795 [IN_PROCESS_AGENT] (debug_agent): New global variable.
8797 2012-01-04 Yao Qi <yao@codesourcery.com>
8799 * tracepoint.c (cmd_qtdp): Print debug message
8800 for static tracepoint.
8802 2012-01-04 Yao Qi <yao@codesourcery.com>
8804 * tracepoint.c (trace_vdebug): Differentiate debug message
8805 between gdbserver and IPA.
8807 2012-01-03 Yao Qi <yao@codesourcery.com>
8809 * tracepoint.c (tracepoint_was_hit): Don't collect for
8812 2012-01-02 Joel Brobecker <brobecker@adacore.com>
8814 * terminal.h: Reformat copyright header.
8816 2012-01-02 Joel Brobecker <brobecker@adacore.com>
8818 * server.c (gdbserver_version): Update copyright year.
8819 * gdbreplay.c (gdbreplay_version): Likewise.
8821 2011-12-18 Jan Kratochvil <jan.kratochvil@redhat.com>
8823 * linux-low.c (linux_create_inferior): Put empty if clause for write.
8826 2011-12-18 Hui Zhu <teawater@gmail.com>
8827 * linux-low.c (linux_create_inferior): Save return value to ret.
8829 2011-12-18 Hui Zhu <teawater@gmail.com>
8831 * linux-low.c (linux_create_inferior): Save return value to ret.
8833 2011-12-16 Doug Evans <dje@google.com>
8835 * linux-low.c (linux_create_inferior): If stdio connection,
8836 redirect stdin from /dev/null, stdout to stderr.
8837 * remote-utils.c (remote_is_stdio): New static global.
8838 (remote_connection_is_stdio): New function.
8839 (remote_prepare): Handle stdio connection.
8840 (remote_open): Ditto.
8841 (remote_close): Don't close stdin for stdio connections.
8842 (read_prim,write_prim): New functions. Replace all calls to
8843 read/write to these.
8844 * server.c (main): Watch for "-" argument. Move call to
8845 remote_prepare before start_inferior.
8846 * server.h (STDIO_CONNECTION_NAME): New macro.
8847 (remote_connection_is_stdio): Declare.
8849 * remote-utils.c (prepare_resume_reply): Remove extraneous \n
8850 in debugging output.
8852 2011-12-15 Yao Qi <yao@codesourcery.com>
8854 * tracepoint.c: Include sys/syscall.h.
8855 (gdb_ust_thread): Remove preprocessor conditional.
8857 2011-12-14 Pedro Alves <pedro@codesourcery.com>
8859 * linux-low.c (linux_detach_one_lwp): Call
8860 the_low_target.prepare_to_resume before detaching.
8862 2011-12-14 Yao Qi <yao@codesourcery.com>
8864 * tracepoint.c (gdb_ust_thread): Don't ignore return value
8867 2011-12-14 Yao Qi <yao@codesourcery.com>
8869 * i386-low.c (i386_low_stopped_data_address): Initialize local
8872 2011-12-13 Pedro Alves <pedro@codesourcery.com>
8876 * i386-low.c (i386_low_stopped_data_address): Avoid fetching
8877 DR_CONTROL unless necessary. Extend comments.
8878 * linux-x86-low.c (x86_linux_prepare_to_resume): Don't write to
8879 DR0-3 if not used. If any watchpoint was set, clear DR_STATUS.
8881 2011-12-13 Yao Qi <yao@codesourcery.com>
8883 * tracepoint.c (trace_buffer_alloc): Replace magic numbers with
8885 (upload_fast_traceframes, upload_fast_traceframes): Likewise.
8887 2011-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
8889 * linux-low.c (linux_kill): Skip PTRACE_KILL if LWP does not exist.
8890 Print new debug message for such case.
8892 2011-12-06 Jan Kratochvil <jan.kratochvil@redhat.com>
8894 Fix overlapping memcpy.
8895 * mem-break.c (set_raw_breakpoint_at): New variable buf. Use it for
8896 the read_inferior_memory transfer.
8897 (delete_fast_tracepoint_jump): New variable buf. Use it for the
8898 write_inferior_memory transfer.
8899 (set_fast_tracepoint_jump): New variable buf. Use it for the
8900 read_inferior_memory and write_inferior_memory transfers.
8901 (uninsert_fast_tracepoint_jumps_at, reinsert_fast_tracepoint_jumps_at)
8902 (delete_raw_breakpoint, uninsert_raw_breakpoint): New variable buf.
8903 Use it for the write_inferior_memory transfer.
8904 (check_mem_read, check_mem_write): New gdb_asserts for overlapping
8907 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
8909 * linux-low.c (fetch_register, store_register): Make code
8910 consistent, fix formatting.
8912 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
8914 * linux-low.c (usr_store_inferior_registers): Factor out code
8915 to handle individual registers into...
8916 (store_register): ... this new function.
8918 2011-12-06 Ulrich Weigand <uweigand@de.ibm.com>
8920 * Makefile.in (s390-linux32v1.o, s390-linux32v1.c): New rules.
8921 (s390-linux32v2.o, s390-linux32v2.c): Likewise.
8922 (s390-linux64v1.o, s390-linux64v1.c): Likewise.
8923 (s390-linux64v2.o, s390-linux64v2.c): Likewise.
8924 (s390x-linux64v1.o, s390x-linux64v1.c): Likewise.
8925 (s390x-linux64v2.o, s390x-linux64v2.c): Likewise.
8926 * configure.srv [s390*-*-linux*] (srv_regobj): Add new objects.
8927 (srv_xmlfiles): Add new XML files.
8929 * linux-s390-low.c: Include "elf/common.h", <sys/ptrace.h>,
8931 (PTRACE_GETREGSET, PTRACE_SETREGSET): Define if undefined.
8932 (init_registers_s390_linux32v1): Add prototype.
8933 (init_registers_s390_linux32v2): Likewise.
8934 (init_registers_s390_linux64v1): Likewise.
8935 (init_registers_s390_linux64v2): Likewise.
8936 (init_registers_s390x_linux64v1): Likewise.
8937 (init_registers_s390x_linux64v2): Likewise.
8938 (s390_num_regs): Increment to 52.
8939 (s390_regmap): Add orig_r2 register.
8940 (s390_num_regs_3264): Increment to 68.
8941 (s390_regmap_3264): Add orig_r2 register.
8942 (s390_collect_ptrace_register): Handle orig_r2 register.
8943 (s390_supply_ptrace_register): Likewise.
8944 (s390_fill_last_break): New function.
8945 (s390_store_last_break): Likewise.
8946 (s390_fill_system_call): New function.
8947 (s390_store_system_call): Likewise.
8948 (target_regsets): Handle NT_S390_LAST_BREAK and NT_S390_SYSTEM_CALL
8950 (s390_check_regset): New function.
8951 (s390_arch_setup): Check for presence of NT_S390_LAST_BREAK and
8952 NT_S390_SYSTEM_CALL regsets and use appropriate description.
8953 Update target_regsets for available register sets.
8955 2011-12-02 Paul Pluzhnikov <ppluzhnikov@google.com>
8956 Jan Kratochvil <jan.kratochvil@redhat.com>
8958 * linux-low.c (get_phdr_phnum_from_proc_auxv, get_dynamic, get_r_debug)
8959 (read_one_ptr, struct link_map_offsets, linux_qxfer_libraries_svr4):
8961 (struct linux_target_ops): Install linux_qxfer_libraries_svr4.
8962 * linux-low.h (struct process_info_private): New member r_debug.
8963 * server.c (handle_qxfer_libraries): Call
8964 the_target->qxfer_libraries_svr4.
8965 (handle_qxfer_libraries_svr4): New function.
8966 (qxfer_packets): New entry "libraries-svr4".
8967 (handle_query): Check QXFER_LIBRARIES_SVR4 and report libraries-svr4.
8968 * target.h (struct target_ops): New member qxfer_libraries_svr4.
8969 * remote.c (remote_xfer_partial): Call add_packet_config_cmd for
8970 PACKET_qXfer_libraries_svr4.
8972 2011-11-30 Ulrich Weigand <uweigand@de.ibm.com>
8974 * linux-s390-low.c (s390_collect_ptrace_register): Fully convert
8975 PSW address/mask between 8-byte and 16-byte formats.
8976 (s390_supply_ptrace_register): Likewise.
8977 (s390_get_pc, s390_set_pc): 4-byte PSW address always includes
8978 basic addressing mode bit.
8980 2011-11-24 Stan Shebs <stan@codesourcery.com>
8982 * tracepoint.c (cmd_qtstatus): Use plongest instead of %llx.
8984 2011-11-17 Stan Shebs <stan@codesourcery.com>
8986 * tracepoint.c (struct tracepoint): New field traceframe_usage.
8987 (tracing_start_time): New global.
8988 (tracing_stop_time): New global.
8989 (tracing_user_name): New global.
8990 (tracing_notes): New global.
8991 (tracing_stop_note): New global.
8992 (cmd_qtstart): Set traceframe_usage, start_time.
8993 (stop_tracing): Set stop_time.
8994 (cmd_qtstatus): Report additional status.
8995 (cmd_qtp): New function.
8996 (handle_tracepoint_query): Call it.
8997 (cmd_qtnotes): New function.
8998 (handle_tracepoint_general_set): Call it.
8999 (get_timestamp): Rename from tsv_get_timestamp.
9001 2011-11-14 Stan Shebs <stan@codesourcery.com>
9002 Kwok Cheung Yeung <kcy@codesourcery.com>
9004 * linux-x86-low.c (small_jump_insn): New.
9005 (i386_install_fast_tracepoint_jump_pad): Add arguments for
9006 trampoline and error message, build a trampoline and issue a small
9007 jump instruction to it.
9008 (x86_install_fast_tracepoint_jump_pad): Add arguments for
9009 trampoline and error message.
9010 (x86_get_min_fast_tracepoint_insn_len): New.
9011 (the_low_target): Add call to x86_get_min_fast_tracepoint_insn_len.
9012 * linux-low.h (struct linux_target_ops): Add arguments to
9013 install_fast_tracepoint_jump_pad operation, add new operation.
9014 * linux-low.c (linux_install_fast_tracepoint_jump_pad): Add
9016 (linux_get_min_fast_tracepoint_insn_len): New function.
9017 (linux_target_op): Add new operation.
9018 * tracepoint.c (gdb_trampoline_buffer): New IPA variable.
9019 (gdb_trampoline_buffer_end): Ditto.
9020 (gdb_trampoline_buffer_error): Ditto.
9021 (struct ipa_sym_addresses): Add fields for new IPA variables.
9022 (symbol_list): Add entries for new IPA variables.
9023 (struct tracepoint): Add fields to hold the address range of the
9024 trampoline used by the tracepoint.
9025 (trampoline_buffer_head): New static variable.
9026 (trampoline_buffer_tail): Ditto.
9027 (claim_trampoline_space): New function.
9028 (have_fast_tracepoint_trampoline_buffer): New function.
9029 (clone_fast_tracepoint): Fill in trampoline fields of tracepoint
9031 (install_fast_tracepoint): Ditto, also add error buffer argument.
9032 (cmd_qtminftpilen): New function.
9033 (handle_tracepoint_query): Add response to qTMinFTPILen packet.
9034 (fast_tracepoint_from_trampoline_address): New function.
9035 (fast_tracepoint_collecting): Handle trampoline as part of jump
9037 (set_trampoline_buffer_space): New function.
9038 (initialize_tracepoint): Initialize new IPA variables.
9039 * target.h (struct target_ops): Add arguments to
9040 install_fast_tracepoint_jump_pad operation, add new
9041 get_min_fast_tracepoint_insn_len operation.
9042 (target_get_min_fast_tracepoint_insn_len): New.
9043 (install_fast_tracepoint_jump_pad): Add arguments.
9044 * server.h (IPA_BUFSIZ): Define.
9045 * linux-i386-ipa.c: Include extra header files.
9046 (initialize_fast_tracepoint_trampoline_buffer): New function.
9047 (initialize_low_tracepoint): Call it.
9048 * server.h (set_trampoline_buffer_space): Declare.
9049 (claim_trampoline_space): Ditto.
9050 (have_fast_tracepoint_trampoline_buffer): Ditto.
9052 2011-11-14 Yao Qi <yao@codesourcery.com>
9054 * server.c (handle_query): Handle InstallInTrace for qSupported.
9055 * tracepoint.c (add_tracepoint): Sort list.
9056 (install_tracepoint, download_tracepoint): New.
9057 (cmd_qtdp): Call them to install and download tracepoints.
9058 (sort_tracepoints): Removed.
9059 (cmd_qtstart): Update.
9061 2011-11-14 Yao Qi <yao@codesourcery.com>
9063 * mem-break.c (inc_ref_fast_tracepoint_jump): New.
9064 * mem-break.h: Declare.
9065 * tracepoint.c (cmd_qtstart): Move some code to ...
9066 (clone_fast_tracepoint, install_fast_tracepoint): ... here.
9068 (download_tracepoints): Move some code to ...
9069 (download_tracepoint_1): ... here. New.
9071 2011-11-08 Yao Qi <yao@codesourcery.com>
9073 * remote-utils.c (relocate_instruction): A comment fix.
9075 2011-11-07 Joel Brobecker <brobecker@adacore.com>
9077 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): Delete.
9078 (i386_dr_low_get_control, i386_dr_low_get_status): Use
9079 dr_status_mirror and dr_control_mirror from debug_reg_state.
9080 (i386_dr_low_get_status): Use debug_reg_state.dr_status_mirror
9081 (i386_initial_stuff): Remove use of deleted globals.
9082 (i386_get_thread_context, i386_set_thread_context,
9083 i386_thread_added): Use dr_status_mirror and dr_control_mirror
9084 from debug_reg_state.
9086 2011-11-05 Yao Qi <yao@codesourcery.com>
9088 * tracepoint.c (gdb_collect): Loop over tracepoints of same
9089 address as TPOINT's.
9091 2011-11-02 Stan Shebs <stan@codesourcery.com>
9093 * tracepoint.c (agent_mem_read_string): New function.
9094 (eval_agent_expr): Call it for tracenz.
9095 * server.c (handle_query): Report support for tracenz.
9097 2011-11-02 Yao Qi <yao@codesourcery.com>
9099 * tracepoint.c (cmd_qtstart): Remove unused local variables.
9101 2011-11-02 Yao Qi <yao@codesourcery.com>
9103 * target.h: Fix a typo in comment.
9105 2011-10-31 Pedro Alves <pedro@codesourcery.com>
9107 * mem-break.c (check_mem_write): Add `myaddr' parameter. Don't
9108 clobber the breakpoints' shadows with fast tracepoint jumps.
9109 * mem-break.h (check_mem_write): Add `myaddr' parameter.
9110 * target.c (write_inferior_memory): Also pass MYADDR down to
9113 2011-10-07 Ulrich Weigand <ulrich.weigand@linaro.org>
9115 * configure.ac: Check support for personality routine.
9116 * configure: Regenerate.
9117 * config.in: Likewise.
9118 * linux-low.c: Include <sys/personality.h>.
9119 Define ADDR_NO_RANDOMIZE if necessary.
9120 (linux_create_inferior): Disable address space randomization when
9121 forking inferior, if requested.
9122 (linux_supports_disable_randomization): New function.
9123 (linux_target_ops): Install it.
9124 * server.h (disable_randomization): Declare.
9125 * server.c (disable_randomization): New global variable.
9126 (handle_general_set): Handle QDisableRandomization.
9127 (handle_query): Likewise for qSupported.
9128 (main): Support --disable-randomization and --no-disable-randomization
9129 command line arguments.
9130 * target.h (struct target_ops): Add supports_disable_randomization.
9131 (target_supports_disable_randomization): New macro.
9133 2011-09-29 Mike Frysinger <vapier@gentoo.org>
9135 * linux-low.c (target_loadseg): Add defined PTRACE_GETFDPIC to the
9137 [PT_GETDSBT] (target_loadmap): Wrap in a defined PT_GETDSBT check.
9138 [!PT_GETDSBT] (target_loadmap): New definition.
9139 (LINUX_LOADMAP, LINUX_LOADMAP_EXEC, LINUX_LOADMAP_INTERP): Define.
9140 (linux_read_loadmap): Change PTRACE_GETDSBT_EXEC to
9141 LINUX_LOADMAP_EXEC, PTRACE_GETDSBT_INTERP to LINUX_LOADMAP_INTERP,
9142 and PT_GETDSBT to LINUX_LOADMAP.
9143 [!PT_GETDSBT] (linux_read_loadmap): Define to NULL.
9144 (linux_target_ops): Delete unnecessary ifdef PT_GETDSBT check.
9146 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
9148 * linux-arm-low.c (struct arm_linux_hwbp_cap): Remove.
9149 (arm_linux_hwbp_cap): New static variable.
9150 (arm_linux_get_hwbp_cap): Replace by ...
9151 (arm_linux_init_hwbp_cap): ... this new function.
9152 (arm_linux_get_hw_breakpoint_count): Use arm_linux_hwbp_cap.
9153 (arm_linux_get_hw_watchpoint_count): Likewise.
9154 (arm_linux_get_hw_watchpoint_max_length): Likewise.
9155 (arm_arch_setup): Call arm_linux_init_hwbp_cap.
9156 (arm_prepare_to_resume): Use perror_with_name instead of error.
9158 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
9160 * linux-arm-low.c: Include <signal.h>.
9161 (PTRACE_GETHBPREGS, PTRACE_SETHBPREGS): Define if necessary.
9162 (struct arm_linux_hwbp_cap): New data type.
9163 (arm_hwbp_type, arm_hwbp_control_t): New typedefs.
9164 (struct arm_linux_hw_breakpoint): New data type.
9165 (MAX_BPTS, MAX_WPTS): Define.
9166 (struct arch_process_info, struct arch_lwp_info): New data types.
9167 (arm_linux_get_hwbp_cap): New function.
9168 (arm_linux_get_hw_breakpoint_count): Likewise.
9169 (arm_linux_get_hw_watchpoint_count): Likewise.
9170 (arm_linux_get_hw_watchpoint_max_length): Likewise.
9171 (arm_hwbp_control_initialize): Likewise.
9172 (arm_hwbp_control_is_enabled): Likewise.
9173 (arm_hwbp_control_is_initialized): Likewise.
9174 (arm_hwbp_control_disable): Likewise.
9175 (arm_linux_hw_breakpoint_equal): Likewise.
9176 (arm_linux_hw_point_initialize): Likewise.
9177 (struct update_registers_data): New data structure.
9178 (update_registers_callback: New function.
9179 (arm_insert_point): Likewise.
9180 (arm_remove_point): Likewise.
9181 (arm_stopped_by_watchpoint): Likewise.
9182 (arm_stopped_data_address): Likewise.
9183 (arm_new_process): Likewise.
9184 (arm_new_thread): Likewise.
9185 (arm_prepare_to_resume): Likewise.
9186 (the_low_target): Register arm_insert_point, arm_remove_point,
9187 arm_stopped_by_watchpoint, arm_stopped_data_address, arm_new_process,
9188 arm_new_thread, and arm_prepare_to_resume.
9190 2011-09-15 Stan Shebs <stan@codesourcery.com>
9192 * server.h (struct emit_ops): Add compare-goto fields.
9193 * tracepoint.c (gdb_agent_op_sizes): New table.
9194 (emit_eq_goto): New function.
9195 (emit_ne_goto): New function.
9196 (emit_lt_goto): New function.
9197 (emit_le_goto): New function.
9198 (emit_gt_goto): New function.
9199 (emit_ge_goto): New function.
9200 (is_goto_target): New function.
9201 (compile_bytecodes): Recognize special cases of compare-goto
9202 combinations and call specialized emitters for them.
9203 * linux-x86-low.c (amd64_emit_eq_goto): New function.
9204 (amd64_emit_ne_goto): New function.
9205 (amd64_emit_lt_goto): New function.
9206 (amd64_emit_le_goto): New function.
9207 (amd64_emit_gt_goto): New function.
9208 (amd64_emit_ge_goto): New function.
9209 (amd64_emit_ops): Add the new functions.
9210 (i386_emit_eq_goto): New function.
9211 (i386_emit_ne_goto): New function.
9212 (i386_emit_lt_goto): New function.
9213 (i386_emit_le_goto): New function.
9214 (i386_emit_gt_goto): New function.
9215 (i386_emit_ge_goto): New function.
9216 (i386_emit_ops): Add the new functions.
9218 2011-09-08 Stan Shebs <stan@codesourcery.com>
9220 * linux-x86-low.c (i386_emit_prologue): Save %ebx.
9221 (i386_emit_epilogue): Restore %ebx.
9223 2011-08-31 Jie Zhang <jzhang918@gmail.com>
9225 * server.c (step_thread): Remove definition.
9226 (process_serial_event): Don't handle Hs.
9227 * server.h (step_thread): Remove declaration.
9228 * target.c (set_desired_inferior): Remove use of step_thread.
9230 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
9232 * linux-low.c: Include linux-procfs.h.
9233 (linux_attach_lwp_1): Update comments.
9234 (linux_attach): Scan for existing threads when attaching to a
9235 process that is the tgid.
9236 * Makefile.in: Update dependencies.
9238 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
9240 * configure.srv: Add linux-procfs.o dependencies.
9242 2011-08-14 Yao Qi <yao@codesourcery.com>
9244 * target.h (struct target_ops): Fix indent.
9245 * win32-low.c (win32_target_ops): Fix comment.
9247 2011-08-14 Andrew Jenner <andrew@codesourcery.com>
9248 Yao Qi <yao@codesourcery.com>
9250 * Makefile.in (clean): Remove tic6x-*.c files.
9251 (linux-tic6x-low.o, tic6x-c62x-linux.o, tic6x-c64x-linux.o): New rules.
9252 (tic6x-c64xp-linux.o, tic6x-c62x-linux.c, tic6x-c64x-linux.c): Likewise.
9253 (tic6x-c64xp-linux.c): Likewise.
9254 * configure.srv: Add support for tic6x-*-uclinux.
9255 * linux-tic6x-low.c: New.
9256 * linux-low.c (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define.
9258 2011-08-14 Andrew Stubbs <ams@codesourcery.com>
9259 Yao Qi <yao@codesourcery.com>
9261 * target.h (struct target_ops): Add read_loadmap.
9262 * linux-low.c (struct target_loadseg): New type.
9263 (struct target_loadmap): New type.
9264 (linux_read_loadmap): New function.
9265 (linux_target_ops): Add linux_read_loadmap.
9266 * server.c (handle_query): Support qXfer:fdpic:read packet.
9267 * win32-low.c (win32_target_ops): Initialize field `read_loadmap'
9270 2011-08-05 Eli Zaretskii <eliz@gnu.org>
9272 * win32-low.c: Include <stdint.h>.
9274 2011-07-22 Pedro Alves <pedro@codesourcery.com>
9276 * i386-low.c (i386_insert_aligned_watchpoint): Don't pass the info
9277 to the inferior here.
9278 (i386_remove_aligned_watchpoint): Ditto.
9279 (i386_handle_nonaligned_watchpoint): Return immediate on fail to
9280 fit part of the watchpoint in the debug registers.
9281 (i386_update_inferior_debug_regs): New.
9282 (i386_low_insert_watchpoint): Work on a local mirror of the debug
9283 registers, and only update the inferior on success.
9284 (i386_low_remove_watchpoint): Ditto.
9286 2011-07-22 Kwok Cheung Yeung <kcy@codesourcery.com>
9288 * linux-low.c (compare_ints, unique, list_threads, show_process,
9289 linux_core_of_thread): Delete.
9290 (linux_target_ops): Change linux_core_of_thread to
9291 linux_common_core_of_thread.
9292 (linux_qxfer_osdata): Defer to linux_common_xfer_osdata.
9293 * utils.c (malloc_failure): Change type of argument.
9294 (xmalloc, xrealloc, xcalloc, xsnprintf): Delete.
9295 * Makefile.in (SFILES): Add common/common-utils.c, common/xml-utils.c,
9296 common/linux-osdata.c, common/ptid.c and common/buffer.c.
9297 (OBS): Add xml-utils.o, common-utils.o, ptid.o and buffer.o.
9298 (IPA_OBJS): Add common-utils-ipa.o.
9299 (ptid_h, linux_osdata_h): New macros.
9300 (server_h): Add common/common-utils.h, common/xml-utils.h,
9301 common/buffer.h, common/gdb_assert.h, common/gdb_locale.h and
9303 (common-utils-ipa.o, common-utils.o, xml-utils.o, linux-osdata.o,
9304 ptid.o, buffer.o): New rules.
9305 (linux-low.o): Add common/linux-osdata.h as a dependency.
9306 * configure.srv (srv_tgtobj): Add linux-osdata.o to Linux targets.
9307 * configure.ac: Add AC_HEADER_DIRENT check.
9308 * config.in: Regenerate.
9309 * configure: Regenerate.
9310 * remote-utils.c (xml_escape_text): Delete.
9311 (buffer_grow, buffer_free, buffer_init, buffer_finish,
9312 buffer_xml_printf): Move to common/buffer.c.
9313 * server.c (main): Remove call to initialize_inferiors.
9314 * server.h (struct ptid, ptid_t, minus_one_ptid, null_ptid,
9315 ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp, ptid_get_tid,
9316 ptid_equal, ptid_is_pid, initialize_inferiors, xml_escape_text,
9317 internal_error, gdb_assert, gdb_assert_fail): Delete.
9318 (struct buffer, buffer_grow, buffer_free, buffer_init, buffer_finish,
9319 buffer_xml_printf, buffer_grow_str, buffer_grow_str0): Move to
9321 * inferiors.c (null_ptid, minus_one_ptid, ptid_build, pid_to_ptid,
9322 ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal, ptid_is_pid,
9323 initialize_inferiors): Delete.
9325 2011-07-20 Pedro Alves <pedro@codesourcery.com>
9327 * tracepoint.c (tracepoint_look_up_symbols): Return upon the first
9330 2011-05-31 Pedro Alves <pedro@codesourcery.com>
9332 * linux-x86-low.c (i386_dr_low_get_addr): Fix off by one in
9334 * win32-i386-low.c (i386_dr_low_get_addr): Ditto.
9336 2011-05-26 Yao Qi <yao@codesourcery.com>
9338 * Makefile.in (thread-db.o): Track dependence to
9339 common/gdb_thread_db.h.
9340 * thread-db.c: include gdb_thread_db.h from right place.
9342 2011-05-16 Adrian Cornish <gnu@bluedreamer.com>
9344 * linux-i386-ipa.c (supply_static_tracepoint_registers): Pass
9345 __FILE__ and __LINE__ to internal_error.
9347 2011-05-13 Doug Evans <dje@google.com>
9349 * thread-db.c (try_thread_db_load_from_sdir): New function.
9350 (try_thread_db_load_from_dir): New function.
9351 (thread_db_load_search): Handle $sdir, ignore $pdir.
9352 Remove trying of system directories if search of
9353 libthread-db-search-path fails, that is now done via $sdir.
9355 2011-05-12 Kwok Cheung Yeung <kcy@codesourcery.com>
9357 * server.c (handle_query): Add EnableDisableTracepoints to the list
9358 of supported features.
9359 * tracepoint.c (clear_installed_tracepoints): Uninstall disabled
9361 (cmd_qtenable_disable): New.
9362 (cmd_qtstart): Install tracepoints even if disabled.
9363 (handle_tracepoint_general_set): Add call to cmd_qtenable_disable on
9364 receiving a QTEnable or QTDisable packet.
9365 (gdb_collect): Skip data collection if fast tracepoint is disabled.
9366 (ust_marker_to_static_tracepoint): Do not ignore disabled static
9368 (gdb_probe): Skip data collection if static tracepoint is disabled.
9370 2011-05-10 Doug Evans <dje@google.com>
9372 * thread-db.c (thread_db_handle_monitor_command): Handle elided path.
9374 2011-05-04 Doug Evans <dje@google.com>
9376 * linux-low.c (linux_join): Skip process lookup.
9377 * spu-low.c (spu_join): Ditto.
9378 * server.c (join_inferiors_callback): Delete.
9379 (process_serial_event): For 'D' packet (detach) call join_inferior
9382 2011-05-04 Joseph Myers <joseph@codesourcery.com>
9384 * README: Don't mention xscale*-*-linux*.
9385 * configure.srv (xscale*-*-linux*): Don't handle target.
9387 2011-04-27 Nathan Froyd <froydnj@codesourcery.com>
9389 * linux-x86-low.c (amd64_emit_const): Call memcpy instead of
9391 (amd64_emit_reg, amd64_emit_int_call_1, amd64_emit_void_call_2):
9392 (i386_emit_const, i386_emit_reg, i386_emit_int_call_1):
9393 (i386_emit_void_call_2): Likewise.
9395 2011-04-26 Yao Qi <yao@codesourcery.com>
9397 * linux-low.c: Move common macros to linux-ptrace.h.
9398 Include linux-ptrace.h.
9399 * Makefile.in (linux_ptrace_h): New.
9400 (linux-low.o): Depends on linux-ptrace.h.
9402 2011-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
9404 * remote-utils.c (handle_accept_event): Close LISTEN_DESC only if
9405 RUN_ONCE. Comment for the LISTEN_DESC delete_file_handler call.
9406 (remote_prepare): New function with most of the TCP code from ...
9407 (remote_open): ... here. Detect PORT here unconditionally. Move also
9408 setting transport_is_reliable.
9409 * server.c (run_once): New variable.
9410 (gdbserver_usage): Document it.
9411 (main): Set run_once for `--once'. Call remote_prepare. Exit after
9412 the first run if RUN_ONCE.
9413 * server.h (run_once, remote_prepare): New declarations.
9415 2011-04-19 Tom Tromey <tromey@redhat.com>
9417 * win32-low.c (handle_load_dll): Remove duplicate "the".
9419 2011-04-07 Pierre Muller <muller@ics.u-strasbg.fr>
9421 Remove support for old Cygwin 1.5 versions.
9422 * win32-low.c (win32_create_inferior): Use new cygwin_path_list
9423 function to avoid warning.
9424 (win32_add_one_solib): Use cygwin_conv_path function to avoid
9427 2011-03-18 Pierre Muller <muller@ics.u-strasbg.fr>
9429 * gdbserver/server.h (Macro _): Define it if not available.
9431 2011-03-14 Michael Snyder <msnyder@vmware.com>
9433 * hostio.c (handle_close): Remove unnecessary null test.
9435 2011-03-10 Joel Brobecker <brobecker@adacore.com>
9437 * Makefile.in (maintainer-clean realclean distclean): Remove
9438 "make ... subdir_do" command.
9440 2011-03-10 Michael Snyder <msnyder@vmware.com>
9442 * tracepoint.c (tracepoint_finish_step): Fix loop variable.
9444 * server.c (handle_v_run): Free alloced buffer on early return.
9446 2011-03-09 Yao Qi <yao@codesourcery.com>
9449 2011-03-04 Yao Qi <yao@codesourcery.com>
9451 * Makefile.in: Remove GNU make feature --directory.
9453 2011-03-05 Yao Qi <yao@codesourcery.com>
9455 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
9456 (subdir_do): New make target. Copied from gdb/Makefile.
9457 (maintainer-clean, realclean, distclean, clean): Call corresponding
9458 make targets in common/Makefile.
9460 2011-02-11 Yao Qi <yao@codesourcery.com>
9462 * configure.ac: Call AC_PROG_RANLIB.
9463 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
9464 * configure: Regenerate.
9466 2011-03-07 Jan Kratochvil <jan.kratochvil@redhat.com>
9468 * remote-utils.c (putpkt_binary_1): Calculate BUF2 size dynamically.
9470 2011-03-06 Yao Qi <yao@codesourcery.com>
9472 * Makefile.in (REQUIRED_SUBDIRS): Remove $(LIBCOMMON_DIR).
9474 2011-03-05 Yao Qi <yao@codesourcery.com>
9476 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
9477 (subdir_do): New make target. Copied from gdb/Makefile.
9478 (maintainer-clean, realclean, distclean, clean): Call corresponding
9479 make targets in common/Makefile.
9481 2011-03-04 Yao Qi <yao@codesourcery.com>
9483 * Makefile.in: Remove GNU make feature --directory.
9485 2011-03-04 Michael Snyder <msnyder@vmware.com>
9487 * server.c (queue_stop_reply): Call xmalloc not malloc.
9489 2011-03-02 Michael Snyder <msnyder@vmware.com>
9491 * linux-arm-low.c (arm_arch_setup): Replace malloc with xmalloc.
9493 2011-02-28 Michael Snyder <msnyder@vmware.com>
9495 * tracepoint.c (cmd_qtv): Discard unused value 'packet'.
9496 (cmd_qtframe): Ditto.
9497 (cmd_qtbuffer): Ditto.
9498 (cmd_bigqtbuffer): Ditto.
9500 * utils.c (decimal2str): Initialize 'width' to nine, then
9503 2011-02-28 Ulrich Weigand <uweigand@de.ibm.com>
9505 * hostio.c (require_data): Free *data, not data.
9507 2011-02-28 Jan Kratochvil <jan.kratochvil@redhat.com>
9509 * hostio.c (require_data): Use free, not xfree.
9511 2011-02-27 Michael Snyder <msnyder@vmware.com>
9513 * server.c (handle_query): Discard unused value.
9515 * hostio.c (require_data): Free malloc memory before returning
9518 2011-02-26 Michael Snyder <msnyder@vmware.com>
9520 * linux-low.c (list_threads): Call closedir for dirent.
9522 2011-02-27 Michael Snyder <msnyder@vmware.com>
9524 * i386-low.c (i386-length_and_rw_bits): Comment the fact that
9525 a case statement falls through.
9527 * linux-low.c (linux_xfer_siginfo): Fix fencepost error.
9529 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Fix fencepost error
9532 2011-02-26 Michael Snyder <msnyder@vmware.com>
9534 * utils.c (decimal2str): Eliminate dead code and dead param.
9535 (pulongest): Drop dead param from call to decimal2str.
9538 2011-02-24 Joel Brobecker <brobecker@adacore.com>
9540 Revert the following patch (not approved yet):
9541 2011-02-21 Hui Zhu <teawater@gmail.com>
9542 * tracepoint.c (tp_printf): New function.
9543 (eval_agent_expr): Handle gdb_agent_op_printf.
9545 2011-02-21 Hui Zhu <teawater@gmail.com>
9547 * tracepoint.c (tp_printf): New function.
9548 (eval_agent_expr): Handle gdb_agent_op_printf.
9550 2011-02-18 Tom Tromey <tromey@redhat.com>
9552 * Makefile.in (tracepoint-ipa.o): Depend on ax.def.
9553 (tracepoint.o): Likewise.
9554 * tracepoint.c (enum gdb_agent_op): Use ax.def.
9555 (gdb_agent_op_names): Likewise.
9557 2011-02-18 Tom Tromey <tromey@redhat.com>
9559 * tracepoint.c (enum gdb_agent_op) <gdb_agent_op_pick,
9560 gdb_agent_op_rot>: New constants.
9561 (gdb_agent_op_names): Add pick and roll.
9562 (eval_agent_expr) <gdb_agent_op_pick, gdb_agent_op_rot>: New
9565 2011-02-15 Jan Kratochvil <jan.kratochvil@redhat.com>
9567 * aclocal.m4: Regenerated with aclocal-1.11.1.
9569 2011-02-14 Pedro Alves <pedro@codesourcery.com>
9571 * server.c (handle_qxfer_traceframe_info): New.
9572 (qxfer_packets): Register "traceframe-info".
9573 (handle_query): Report support for qXfer:traceframe-info:read+.
9574 * tracepoint.c (match_blocktype): New.
9575 (traceframe_find_block_type): Rename to ...
9576 (traceframe_walk_blocks): ... this. Add callback filter argument,
9578 (traceframe_find_block_type): New, reimplemented on top of
9579 traceframe_walk_blocks.
9580 (build_traceframe_info_xml): New.
9581 (traceframe_read_info): New.
9582 * server.h (traceframe_read_info): Declare.
9584 2011-02-11 Yao Qi <yao@codesourcery.com>
9586 * configure.ac: Call AC_PROG_RANLIB.
9587 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
9588 * configure: Regenerate.
9590 2011-02-07 Pedro Alves <pedro@codesourcery.com>
9592 * server.c (gdb_read_memory): Change return semantics to allow
9594 (handle_search_memory_1): Adjust.
9595 (process_serial_event) <'m' packet>: Handle partial transfers.
9596 * tracepoint.c (traceframe_read_mem): Handle partial transfers.
9598 2011-01-28 Pedro Alves <pedro@codesourcery.com>
9600 * regcache.c (init_register_cache): Initialize
9601 regcache->register_status.
9602 (free_register_cache): Release regcache->register_status.
9603 (regcache_cpy): Copy register_status.
9604 (registers_to_string): Print 'x's for unavailable registers.
9605 (supply_register): Mark the register's status valid or
9606 unavailable, depending on whether a buffer was passed in or not.
9607 (supply_register_zeroed): New.
9608 (supply_regblock): Mark the registers' status valid or
9609 unavailable, depending on whether a buffer was passed in or not.
9610 * regcache.h (REG_UNAVAILABLE, REG_VALID): New defines.
9611 (struct regcache): New `register_status' field.
9612 (supply_register_zeroed): Declare.
9613 * i387-fp.c (i387_xsave_to_cache): Zero out registers using
9614 supply_register_zeroed, rather than passing a NULL buffer to
9616 * tracepoint.c (fetch_traceframe_registers): Update comment.
9618 2011-01-28 Pedro Alves <pedro@codesourcery.com>
9620 * i387-fp.c (i387_xsave_to_cache): Make passing NULL as register
9623 2011-01-25 Pedro Alves <pedro@codesourcery.com>
9625 * server.h (decode_xfer_write): Change prototype.
9626 * remote-utils.c (decode_xfer_write): Remove `annex' parameter,
9627 and don't extract the annex here.
9628 * server.c (decode_xfer_read): Remove `annex' parameter,
9629 and don't extract the annex here.
9631 (struct qxfer): New.
9632 (handle_qxfer_auxv, handle_qxfer_features, handle_qxfer_libraries)
9633 (handle_qxfer_osdata, handle_qxfer_siginfo, handle_qxfer_spu)
9634 (handle_qxfer_statictrace): New functions, abstracted out from
9635 handle_query, and made to use the struct qxfer interface.
9636 (handle_threads_qxfer_proper): Rename to ...
9637 (handle_qxfer_threads_proper): ... this.
9638 (handle_threads_qxfer): Rename to ...
9639 (handle_qxfer_threads): ... this. Adjust.
9640 (qxfer_packets): New array.
9641 (handle_qxfer): New function.
9642 (handle_query): Use handle_qxfer.
9644 2011-01-05 Michael Snyder <msnyder@msnyder-server.eng.vmware.com>
9646 * gdbreplay.c: Shorten lines of >= 80 columns.
9647 * linux-low.c: Ditto.
9648 * linux-ppc-low.c: Ditto.
9649 * linux-s390-low.c: Ditto.
9650 * linux-sparc-low.c: Ditto.
9651 * linux-x86-low.c: Ditto.
9652 * linux-xtensa-low.c: Ditto.
9653 * mem-break.c: Ditto.
9655 * regcache.h: Ditto.
9656 * remote-utils.c: Ditto.
9659 * thread-db.c: Ditto.
9660 * tracepoint.c: Ditto.
9662 * win32-low.h: Ditto.
9664 2011-01-05 Joel Brobecker <brobecker@adacore.com>
9666 * gdbserver/configure.ac, gdbserver/gdbserver.1: Copyright year
9669 2011-01-01 Joel Brobecker <brobecker@adacore.com>
9671 * server.c (gdbserver_version): Update copyright year in version
9673 * gdbreplay.c (gdbreplay_version): Ditto.
9675 2010-12-29 Jie Zhang <jie.zhang@analog.com>
9677 * configure.srv (bfin-*-*linux*): Handle Blackfin/Linux targets.
9678 * linux-bfin-low.c: New file.
9679 * linux-low.c: Define PT_TEXT_ADDR, PT_TEXT_END_ADDR, and
9680 PT_DATA_ADDR for BFIN targets.
9681 * Makefile.in (SFILES): Add linux-bfin-low.c.
9682 (clean): Remove reg-bfin.c.
9683 (linux-bfin-low.o, reg-bfin.o, reg-bfin.c): New targets.
9684 * README: Mention supported Blackfin targets.
9686 2010-12-23 Mike Frysinger <vapier@gentoo.org>
9688 * .gitignore: New file.
9690 2010-11-16 Mike Frysinger <vapier@gentoo.org>
9692 * linux-low.c (linux_tracefork_child): Add char* cast to arg.
9694 2010-10-22 Jie Zhang <jie@codesourcery.com>
9696 * Makefile.in: Add FLAGS_TO_PASS variable.
9697 (install): Remove dependency of install-only and recursively
9698 invoke make for install-only.
9700 2010-10-04 Doug Evans <dje@google.com>
9702 * Makefile.in (uninstall): Use $(DESTDIR).
9704 2010-09-24 Pedro Alves <pedro@codesourcery.com>
9708 * linux-x86-low.c (compat_siginfo_from_siginfo)
9709 (siginfo_from_compat_siginfo): Also copy si_pid and si_uid when
9710 si_code is < 0. Check for si_code == SI_TIMER before checking for
9713 2010-09-13 Joel Brobecker <brobecker@adacore.com>
9715 * lynx-i386-low.c: New file.
9716 * configure.srv: Add handling of i[34567]86-*-lynxos* targets.
9718 2010-09-13 Joel Brobecker <brobecker@adacore.com>
9720 * lynx-low.c (ptrace_request_to_str): Remove handling for
9721 request values that have been removed in LynxOS 5.x.
9723 2010-09-13 Joel Brobecker <brobecker@adacore.com>
9725 * lynx-low.c, lynx-ppc-loc.c: Include <sys/ptrace.h> instead of
9728 2010-09-09 Nathan Sidwell <nathan@codesourcery.com>
9730 * configure.ac: Add --enable-inprocess-agent option.
9731 * configure: Rebuilt.
9733 2010-09-06 Yao Qi <yao@codesourcery.com>
9735 * linux-low.c (linux_kill): Remove unused variable.
9736 (linux_stabilize_threads): Likewise.
9737 * server.c (start_inferior): Likewise.
9738 (queue_stop_reply_callback): Likewise.
9739 * tracepoint.c (do_action_at_tracepoint): Likewise.
9741 2010-09-06 Yao Qi <yao@codesourcery.com>
9743 * linux-low.c (maybe_move_out_of_jump_pad): Restore current_inferior
9746 2010-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
9748 * target.c (mywait) <TARGET_WAITKIND_EXITED>: Fix to use INTEGER.
9750 2010-09-06 Pedro Alves <pedro@codesourcery.com>
9752 * Makefile.in (install-only): Replace $IPA_DEPFILES with
9755 2010-09-01 Joel Brobecker <brobecker@adacore.com>
9757 * gdbserver/lynx-low.c, gdbserver/lynx-low.h,
9758 gdbserver/lynx-ppc-low.c: New files.
9759 * Makefile.in (lynx_low_h): New variable.
9760 (lynx-low.o, lynx-ppc-low.o): New rules.
9761 * configure.ac: On LynxOS, link with -lnetinet.
9762 * configure.srv: Add handling of powerpc-*-lynxos* targets.
9763 * configure: regenerate.
9765 2010-09-01 Joel Brobecker <brobecker@adacore.com>
9767 * Makefile.in (vasprintf.o, vsnprintf.o): New rules.
9768 * configure.ac: Add check for vasprintf and vsnprintf.
9769 * configure, config.in: Regenerate.
9770 * server.h (vasprintf, vsnprintf): Add conditional declarations.
9772 2010-09-01 Joel Brobecker <brobecker@adacore.com>
9774 * gdbreplay.c: Move include of alloca.h up, next to include of
9776 * server.h: Add include of malloc.h.
9777 * mem-break.c: Remove include of malloc.h.
9778 * server.c, tracepoint.c, utils.c, win32-low.c: Likewise.
9780 2010-09-01 Joel Brobecker <brobecker@adacore.com>
9782 * Makefile.in (memmem.o): Build with -Wno-error.
9784 2010-09-01 Joel Brobecker <brobecker@adacore.com>
9786 * utils.c (xsnprintf): Make non-static.
9787 * server.h: Add xsnprintf declaration.
9788 * linux-low.c, nto-low.c, target.c, thread-db.c, tracepoint.c:
9789 replace calls to snprintf by calls to xsnprintf throughout.
9791 2010-09-01 Joel Brobecker <brobecker@adacore.com>
9793 * configure.ac: Add configure check for alloca.
9794 * configure, config.in: Regenerate.
9795 * server.h: Include alloca.h if it exists.
9796 * gdbreplay.c: Include alloca.h if it exists.
9798 2010-08-28 Pedro Alves <pedro@codesourcery.com>
9800 * linux-low.c (__SIGRTMIN): Define if not already defined.
9801 (linux_create_inferior): Check for __ANDROID__ rather than
9803 (enqueue_one_deferred_signal): Don't requeue non-RT signals that
9804 are already deferred.
9805 (linux_wait_1): Check for __ANDROID__ rather than __SIGRTMIN.
9806 (linux_resume_one_thread): Don't queue a SIGSTOP if the lwp is
9807 stopped and already has a pending signal to report.
9808 (proceed_one_lwp): : Don't queue a SIGSTOP if the lwp already has
9809 a pending signal to report or is moving out of a jump pad.
9810 (linux_init_signals): Check for __ANDROID__ rather than
9813 2010-08-28 Pedro Alves <pedro@codesourcery.com>
9815 * linux-low.c (linux_stabilize_threads): Wrap debug output in a
9816 debug_threads check. Avoid a linear search when not doing debug
9819 2010-08-27 Pedro Alves <pedro@codesourcery.com>
9821 * event-loop.c (event_handle_func): Adjust to use gdb_fildes_t.
9822 (struct gdb_event) <fd>: Change type to gdb_fildes_t.
9823 (struct file_handler) <fd>: Change type to gdb_fildes_t.
9824 (process_event): Change local fd's type to gdb_fildes_t.
9825 (create_file_handler): Adjust prototype.
9826 (delete_file_handler): Adjust prototype.
9827 (handle_file_event): Adjust prototype. Use pfildes.
9828 (create_file_event): Adjsut prototype.
9829 * remote-utils.c (remote_desc, listen_desc): Change type to
9831 * server.h: New gdb_fildes_t typedef.
9832 [USE_WIN32API]: Include winsock2.h.
9833 (delete_file_handler, add_file_handler): Adjust prototypes.
9835 * utils.c (pfildes): New.
9837 2010-08-27 Pedro Alves <pedro@codesourcery.com>
9839 * configure.ac (build_warnings): Add -Wno-char-subscripts.
9840 * configure: Regenerate.
9842 2010-08-27 Pedro Alves <pedro@codesourcery.com>
9844 * linux-low.c (linux_unprepare_to_access_memory): Rename to ...
9845 (linux_done_accessing_memory): ... this.
9846 (linux_target_ops): Adjust.
9847 * linux-x86-low.c (x86_insert_point, x86_remove_point): Adjust.
9848 * nto-low.c (nto_target_ops): Adjust comment.
9849 * server.c (gdb_read_memory, gdb_write_memory): Adjust.
9850 * spu-low.c (spu_target_ops): Adjust comment.
9851 * target.h (target_ops): Rename unprepare_to_access_memory field
9852 to done_accessing_memory.
9853 (unprepare_to_access_memory): Rename to ...
9854 (done_accessing_memory): ... this.
9856 2010-08-26 Pedro Alves <pedro@codesourcery.com>
9858 * linux-low.c (linux_prepare_to_access_memory): New.
9859 (linux_unprepare_to_access_memory): New.
9860 (linux_target_ops): Install them.
9861 * server.c (read_memory): Rename to ...
9862 (gdb_read_memory): ... this. Use
9863 prepare_to_access_memory/prepare_to_access_memory.
9864 (write_memory): Rename to ...
9865 (gdb_write_memory): ... this. Use
9866 prepare_to_access_memory/prepare_to_access_memory.
9867 (handle_search_memory_1): Adjust.
9868 (process_serial_event): Adjust.
9869 * target.h (struct target_ops): New fields
9870 prepare_to_access_memory and unprepare_to_access_memory.
9871 (prepare_to_access_memory, unprepare_to_access_memory): New.
9872 * linux-x86-low.c (x86_insert_point, x86_remove_point): Use
9873 prepare_to_access_memory/prepare_to_access_memory.
9874 * nto-low.c (nto_target_ops): Adjust.
9875 * spu-low.c (spu_target_ops): Adjust.
9876 * win32-low.c (win32_target_ops): Adjust.
9878 2010-08-26 Pedro Alves <pedro@codesourcery.com>
9880 * Makefile.in (WARN_CFLAGS): Get it from configure.
9881 (WERROR_CFLAGS): New.
9882 (INTERNAL_CFLAGS): Add WERROR_CFLAGS.
9883 * configure.ac: Introduce --enable-werror, which adds -Werror to
9884 the compiler command line. Enabled by default. Disable with
9885 --disable-werror. Add -Wdeclaration-after-statement
9886 Wpointer-arith and -Wformat-nonliteral to warning flags.
9887 * configure: Regenerate.
9889 2010-08-26 Pedro Alves <pedro@codesourcery.com>
9891 * mem-break.c [HAVE_MALLOC_H]: Include malloc.h.
9893 2010-08-26 Pedro Alves <pedro@codesourcery.com>
9895 * gdbreplay.c (remote_error): New.
9897 (expect): Use gdbchar. Check for error reading from GDB.
9898 Clarify sync error output.
9899 (play): Check for errors writing to GDB.
9900 * linux-low.c (sigchld_handler): Really ignore `write' errors.
9901 * remote-utils.c (getpkt): Check for errors writing to the remote
9904 2010-08-25 Pedro Alves <pedro@codesourcery.com>
9906 * linux-low.c (linux_wait_1): Move non-debugging code out of
9907 `debug_threads' control.
9909 2010-08-25 Pedro Alves <pedro@codesourcery.com>
9911 * linux-low.c (linux_wait_1): Don't set last_status here.
9912 * server.c (push_event, queue_stop_reply_callback): Assert we're
9913 not pushing a TARGET_WAITKIND_IGNORE event.
9914 (start_inferior, start_inferior, attach_inferior, handle_v_cont)
9915 (myresume, handle_target_event): Set the thread's last_resume_kind
9916 and last_status from the target returned status.
9918 2010-08-25 Pedro Alves <pedro@codesourcery.com>
9922 * linux-x86-low.c (update_debug_registers_callback): New.
9923 (i386_dr_low_set_addr): Use it.
9924 (i386_dr_low_get_addr): New.
9925 (i386_dr_low_set_control): Use update_debug_registers_callback.
9926 (i386_dr_low_get_control): New.
9927 (i386_dr_low_get_status): Adjust.
9928 * linux-low.c (linux_stop_lwp): New.
9929 * linux-low.h (linux_stop_lwp): Declare.
9931 * i386-low.c (I386_DR_GET_RW_LEN): Take the dr7 contents as
9932 argument instead of a i386_debug_reg_state.
9933 (I386_DR_WATCH_HIT): Take the dr6 contents as argument instead of
9934 a i386_debug_reg_state.
9935 (i386_insert_aligned_watchpoint): Adjust.
9936 (i386_remove_aligned_watchpoint): Adjust.
9937 (i386_low_stopped_data_address): Read the debug registers from the
9938 inferior instead of from the mirrors.
9939 * i386-low.h (struct i386_debug_reg_state): Extend comment.
9940 (i386_dr_low_get_addr): Declare.
9941 (i386_dr_low_get_control): Declare.
9942 (i386_dr_low_get_status): Change prototype.
9944 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): New globals.
9945 (i386_dr_low_get_addr): New.
9946 (i386_dr_low_get_control): New.
9947 (i386_dr_low_get_status): Adjust prototype. Return
9949 (i386_initial_stuff): Clear dr_status_mirror and
9951 (i386_get_thread_context): Adjust.
9952 (i386_set_thread_context): Adjust.
9953 (i386_thread_added): Adjust.
9955 2010-08-24 Pedro Alves <pedro@codesourcery.com>
9957 * linux-low.h (linux_thread_area): Delete declaration.
9959 2010-08-11 Thomas Schwinge <thomas@codesourcery.com>
9961 * linux-low.c (linux_wait_1): Correctly return the ptid of the child
9962 after its termination.
9964 2010-08-09 Pedro Alves <pedro@codesourcery.com>
9966 * linux-low.c (gdb_wants_lwp_stopped): Delete.
9967 (gdb_wants_all_stopped): Delete.
9968 (linux_wait_1): Don't call them.
9969 * server.c (handle_v_cont): Tag all threads as want-stopped.
9970 (gdb_wants_thread_stopped): Fix comments. Tag the thread that
9971 stopped as "client-wants-stopped".
9973 2010-07-31 Pedro Alves <pedro@codesourcery.com>
9975 * Makefile.in (signals_h): New.
9976 (server_h): Depend on it.
9977 (server.o): Don't depend on $(signals_def).
9978 (signals.o): Depend on $(signals_def).
9980 2010-07-31 Jan Kratochvil <jan.kratochvil@redhat.com>
9982 * Makefile.in (signals_def): New.
9983 (server_h): Append include/gdb/signals.h and signals_def.
9984 (server.o): Append signals_def.
9986 2010-07-25 Jan Kratochvil <jan.kratochvil@redhat.com>
9988 * server.c (handle_target_event): Use target_signal_to_host for
9989 resume_info.sig initialization.
9990 * target.h (struct thread_resume) <sig>: New comment.
9992 2010-07-20 Ozkan Sezer <sezeroz@gmail.com>
9994 * server.c (handle_query): strcpy() the returned string from paddress()
9995 instead of sprintf().
9996 * utils.c (paddress): Return phex_nz().
9998 2010-07-07 Joel Brobecker <brobecker@adacore.com>
10000 * server.c (handle_v_cont): Call mourn_inferior if process
10002 (myresume): Likewise.
10004 2010-07-01 Pedro Alves <pedro@codesourcery.com>
10006 Static tracepoints, and integration with UST.
10008 * configure.ac: Handle --with-ust. substitute ustlibs and ustinc.
10009 * mem-break.c (uninsert_all_breakpoints)
10010 (reinsert_all_breakpoints): New.
10011 * mem-break.h (reinsert_all_breakpoints, uninsert_all_breakpoints):
10012 * tracepoint.c (ust_loaded, helper_thread_id, cmd_buf): New.
10013 (gdb_agent_ust_loaded, helper_thread_id)
10014 (gdb_agent_helper_thread_id): New macros.
10015 (struct ipa_sym_addresses): Add addr_ust_loaded,
10016 addr_helper_thread_id, addr_cmd_buf.
10017 (symbol_list): Add ust_loaded, helper_thread_id, cmd_buf.
10018 (in_process_agent_loaded_ust): New.
10019 (write_e_ust_not_loaded): New.
10020 (maybe_write_ipa_ust_not_loaded): New.
10021 (struct collect_static_trace_data_action): New.
10022 (enum tracepoint_type) <static_tracepoint>: New.
10023 (struct tracepoint) <handle>: Mention static tracepoints.
10024 (struct static_tracepoint_ctx): New.
10025 (CMD_BUF_SIZE): New.
10026 (add_tracepoint_action): Handle static tracepoint actions.
10027 (unprobe_marker_at): New.
10028 (clear_installed_tracepoints): Handle static tracepoints.
10029 (cmd_qtdp): Handle static tracepoints.
10030 (probe_marker_at): New.
10031 (cmd_qtstart): Handle static tracepoints.
10032 (response_tracepoint): Handle static tracepoints.
10033 (cmd_qtfstm, cmd_qtsstm, cmd_qtstmat): New.
10034 (handle_tracepoint_query): Handle qTfSTM, qTsSTM and qTSTMat.
10035 (get_context_regcache): Handle static tracepoints.
10036 (do_action_at_tracepoint): Handle static tracepoint actions.
10037 (traceframe_find_block_type): Handle static trace data blocks.
10038 (traceframe_read_sdata): New.
10039 (download_tracepoints): Download static tracepoint actions.
10040 [HAVE_UST] Include ust/ust.h, dlfcn.h, sys/socket.h, and sys/un.h.
10041 (GDB_PROBE_NAME): New.
10043 (GET_UST_SYM): New.
10046 (ust_marker_to_static_tracepoint): New.
10048 (collect_ust_data_at_tracepoint): New.
10049 (gdb_ust_probe): New.
10050 (UNIX_PATH_MAX, SOCK_DIR): New.
10051 (gdb_ust_connect_sync_socket): New.
10052 (resume_thread, stop_thread): New.
10053 (run_inferior_command): New.
10054 (init_named_socket): New.
10055 (gdb_ust_socket_init): New.
10056 (cstr_to_hexstr): New.
10058 (first_marker, next_marker): New.
10059 (response_ust_marker): New.
10060 (cmd_qtfstm, cmd_qtsstm): New.
10061 (unprobe_marker_at, probe_marker_at): New.
10062 (cmd_qtstmat, gdb_ust_thread): New.
10063 (gdb_ust_init): New.
10064 (initialize_tracepoint_ftlib): Call gdb_ust_init.
10065 * linux-amd64-ipa.c [HAVE_UST]: Include ust/processor.h
10066 (ST_REGENTRY): New.
10067 (x86_64_st_collect_regmap): New.
10068 (X86_64_NUM_ST_COLLECT_GREGS): New.
10069 (AMD64_RIP_REGNUM): New.
10070 (supply_static_tracepoint_registers): New.
10071 * linux-i386-ipa.c [HAVE_UST]: Include ust/processor.h
10072 (ST_REGENTRY): New.
10073 (i386_st_collect_regmap): New.
10074 (i386_NUM_ST_COLLECT_GREGS): New.
10075 (supply_static_tracepoint_registers): New.
10076 * server.c (handle_query): Handle qXfer:statictrace:read.
10077 <qSupported>: Report support for StaticTracepoints, and
10078 qXfer:statictrace:read features.
10079 * server.h (traceframe_read_sdata)
10080 (supply_static_tracepoint_registers): Declare.
10081 * remote-utils.c (convert_int_to_ascii, hexchars, ishex, tohex)
10082 (unpack_varlen_hex): Include in IPA build.
10083 * Makefile.in (ustlibs, ustinc): New.
10084 (IPA_OBJS): Add remote-utils-ipa.o.
10085 ($(IPA_LIB)): Link -ldl and -lpthread.
10087 (IPAGENT_CFLAGS): Add UST_CFLAGS.
10088 * config.in, configure: Regenerate.
10090 2010-06-20 Ian Lance Taylor <iant@google.com>
10091 Pedro Alves <pedro@codesourcery.com>
10093 * linux-x86-low.c (always_true): Delete.
10094 (EMIT_ASM, EMIT_ASM32): Use an uncondition asm jmp instead of
10095 trying to fool the compiler with always_true.
10097 2010-06-20 Pedro Alves <pedro@codesourcery.com>
10099 * tracepoint.c (condition_true_at_tracepoint): Don't run compiled
10100 conditions in gdbserver.
10102 2010-06-19 Ulrich Weigand <uweigand@de.ibm.com>
10104 * spu-low.c (spu_read_memory): Wrap around local store limit.
10105 (spu_write_memory): Likewise.
10107 2010-06-15 Pedro Alves <pedro@codesourcery.com>
10109 * linux-x86-low.c (amd64_emit_const, amd64_emit_void_call_2)
10110 (i386_emit_const, i386_emit_void_call_2): Replace int64_t uses with
10112 * server.h (struct emit_ops): Replace int64_t uses with LONGEST
10114 * tracepoint.c (emit_const, emit_void_call_2): Replace int64_t
10115 uses with LONGEST uses.
10117 2010-06-14 Stan Shebs <stan@codesourcery.com>
10118 Pedro Alves <pedro@codesourcery.com>
10122 * linux-x86-low.c: Include limits.h.
10124 (always_true): New.
10127 (amd64_emit_prologue, amd64_emit_epilogue, amd64_emit_add)
10128 (amd64_emit_sub, amd64_emit_mul, amd64_emit_lsh)
10129 (amd64_emit_rsh_signed, amd64_emit_rsh_unsigned, amd64_emit_ext,
10130 (amd64_emit_log_not, amd64_emit_bit_and, amd64_emit_bit_or)
10131 (amd64_emit_bit_xor, amd64_emit_bit_not, amd64_emit_equal,
10132 (amd64_emit_less_signed, amd64_emit_less_unsigned, amd64_emit_ref,
10133 (amd64_emit_if_goto, amd64_emit_goto, amd64_write_goto_address)
10134 (amd64_emit_const, amd64_emit_call, amd64_emit_reg)
10135 (amd64_emit_pop, amd64_emit_stack_flush, amd64_emit_zero_ext)
10136 (amd64_emit_swap, amd64_emit_stack_adjust, amd64_emit_int_call_1)
10137 (amd64_emit_void_call_2): New.
10138 (amd64_emit_ops): New.
10139 (i386_emit_prologue, i386_emit_epilogue, i386_emit_add)
10140 (i386_emit_sub,i386_emit_mul, i386_emit_lsh, i386_emit_rsh_signed)
10141 (i386_emit_rsh_unsigned, i386_emit_ext, i386_emit_log_not)
10142 (i386_emit_bit_and, i386_emit_bit_or, i386_emit_bit_xor)
10143 (i386_emit_bit_not, i386_emit_equal, i386_emit_less_signed)
10144 (i386_emit_less_unsigned, i386_emit_ref, i386_emit_if_goto)
10145 (i386_emit_goto, i386_write_goto_address, i386_emit_const)
10146 (i386_emit_call, i386_emit_reg, i386_emit_pop)
10147 (i386_emit_stack_flush, i386_emit_zero_ext, i386_emit_swap)
10148 (i386_emit_stack_adjust, i386_emit_int_call_1)
10149 (i386_emit_void_call_2): New.
10150 (i386_emit_ops): New.
10151 (x86_emit_ops): New.
10152 (the_low_target): Install x86_emit_ops.
10153 * server.h (struct emit_ops): New.
10154 (get_raw_reg_func_addr): Declare.
10155 (current_insn_ptr, emit_error): Declare.
10156 * tracepoint.c (get_raw_reg, get_trace_state_variable_value)
10157 (set_trace_state_variable_value): New defines.
10158 (struct ipa_sym_addresses): New fields addr_get_raw_reg,
10159 addr_get_trace_state_variable_value and
10160 addr_set_trace_state_variable_value.
10161 (symbol_list): New fields for get_raw_reg,
10162 get_trace_state_variable_value and set_trace_state_variable_value.
10163 (condfn): New typedef.
10164 (struct tracepoint): New field `compiled_cond'.
10165 (do_action_at_tracepoint): Clear compiled_cond.
10166 (get_trace_state_variable_value, set_trace_state_variable_value):
10168 (condition_true_at_tracepoint): If there's a compiled condition,
10170 (current_insn_ptr, emit_error): New globals.
10171 (struct bytecode_address): New.
10172 (get_raw_reg_func_addr): New.
10173 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul)
10174 (emit_lsh, emit_rsh_signed, emit_rsh_unsigned, emit_ext)
10175 (emit_log_not, emit_bit_and, emit_bit_or, emit_bit_xor)
10176 (emit_bit_not, emit_equal, emit_less_signed, emit_less_unsigned)
10177 (emit_ref, emit_if_goto, emit_goto, write_goto_address, emit_const)
10178 (emit_reg, emit_pop, emit_stack_flush, emit_zero_ext, emit_swap)
10179 (emit_stack_adjust, emit_int_call_1, emit_void_call_2): New.
10180 (compile_tracepoint_condition, compile_bytecodes): New.
10181 * target.h (emit_ops): Forward declare.
10182 (struct target_ops): New field emit_ops.
10183 (target_emit_ops): New.
10184 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): New.
10185 * linux-i386-ipa.c (gdb_agent_get_raw_reg): New.
10186 * linux-low.c (linux_emit_ops): New.
10187 (linux_target_ops): Install it.
10188 * linux-low.h (struct linux_target_ops): New field emit_ops.
10190 2010-06-14 Ulrich Weigand <uweigand@de.ibm.com>
10192 * linux-ppc-low.c (ppc_arch_setup): Use private regcache to test MSR.
10193 * linux-s390-low.c (ppc_arch_setup): Use private regcache to test PSW.
10195 2010-06-01 Pedro Alves <pedro@codesourcery.com>
10196 Stan Shebs <stan@codesourcery.com>
10198 * Makefile.in (IPA_DEPFILES, extra_libraries): New.
10199 (all): Depend on $(extra_libraries).
10200 (install-only): Install the IPA.
10201 (IPA_OBJS, IPA_LIB): New.
10202 (clean): Remove the IPA lib.
10203 (IPAGENT_CFLAGS): New.
10204 (tracepoint-ipa.o, utils-ipa.o, remote-utils-ipa.o)
10205 (regcache-ipa.o, i386-linux-ipa.o, linux-i386-ipa.o)
10206 (linux-amd64-ipa.o, amd64-linux-ipa.o): New rules.
10207 * linux-amd64-ipa.c, linux-i386-ipa.c: New files.
10208 * configure.ac: Check for atomic builtins support in the compiler.
10209 (IPA_DEPFILES, extra_libraries): Define.
10210 * configure.srv (ipa_obj): Add description.
10211 (ipa_i386_linux_regobj, ipa_amd64_linux_regobj): Define.
10212 (i[34567]86-*-linux*): Set ipa_obj.
10213 (x86_64-*-linux*): Set ipa_obj.
10214 * linux-low.c (stabilizing_threads): New.
10215 (supports_fast_tracepoints): New.
10216 (linux_detach): Stabilize threads before detaching.
10217 (handle_tracepoints): Handle internal tracing breakpoints. Assert
10218 the lwp is either not stabilizing, or is moving out of a jump pad.
10219 (linux_fast_tracepoint_collecting): New.
10220 (maybe_move_out_of_jump_pad): New.
10221 (enqueue_one_deferred_signal): New.
10222 (dequeue_one_deferred_signal): New.
10223 (linux_wait_for_event_1): If moving out of a jump pad, defer
10224 pending signals to later.
10225 (linux_stabilize_threads): New.
10226 (linux_wait_1): Check if threads need moving out of jump pads, and
10228 (stuck_in_jump_pad_callback): New.
10229 (move_out_of_jump_pad_callback): New.
10230 (lwp_running): New.
10231 (linux_resume_one_lwp): Handle moving out of jump pads.
10232 (linux_set_resume_request): Dequeue deferred signals.
10233 (need_step_over_p): Also step over fast tracepoint jumps.
10234 (start_step_over): Also uninsert fast tracepoint jumps.
10235 (finish_step_over): Also reinsert fast tracepoint jumps.
10236 (linux_install_fast_tracepoint_jump): New.
10237 (linux_target_ops): Install linux_stabilize_threads and
10238 linux_install_fast_tracepoint_jump_pad.
10239 * linux-low.h (linux_target_ops) <get_thread_area,
10240 install_fast_tracepoint_jump_pad>: New fields.
10241 (struct lwp_info) <collecting_fast_tracepoint,
10242 pending_signals_to_report, exit_jump_pad_bkpt>: New fields.
10243 (linux_get_thread_area): Declare.
10244 * linux-x86-low.c (jump_insn): New.
10245 (x86_get_thread_area): New.
10246 (append_insns): New.
10247 (push_opcode): New.
10248 (amd64_install_fast_tracepoint_jump_pad): New.
10249 (i386_install_fast_tracepoint_jump_pad): New.
10250 (x86_install_fast_tracepoint_jump_pad): New.
10251 (the_low_target): Install x86_get_thread_area and
10252 x86_install_fast_tracepoint_jump_pad.
10253 * mem-break.c (set_raw_breakpoint_at): Use read_inferior_memory.
10254 (struct fast_tracepoint_jump): New.
10255 (fast_tracepoint_jump_insn): New.
10256 (fast_tracepoint_jump_shadow): New.
10257 (find_fast_tracepoint_jump_at): New.
10258 (fast_tracepoint_jump_here): New.
10259 (delete_fast_tracepoint_jump): New.
10260 (set_fast_tracepoint_jump): New.
10261 (uninsert_fast_tracepoint_jumps_at): New.
10262 (reinsert_fast_tracepoint_jumps_at): New.
10263 (set_breakpoint_at): Use write_inferior_memory.
10264 (uninsert_raw_breakpoint): Use write_inferior_memory.
10265 (check_mem_read): Mask out fast tracepoint jumps.
10266 (check_mem_write): Mask out fast tracepoint jumps.
10267 * mem-break.h (struct fast_tracepoint_jump): Forward declare.
10268 (set_fast_tracepoint_jump): Declare.
10269 (delete_fast_tracepoint_jump)
10270 (fast_tracepoint_jump_here, uninsert_fast_tracepoint_jumps_at)
10271 (reinsert_fast_tracepoint_jumps_at): Declare.
10272 * regcache.c: Don't compile many functions when building the
10273 in-process agent library.
10274 (init_register_cache) [IN_PROCESS_AGENT]: Don't allow allocating
10275 the register buffer in the heap.
10276 (free_register_cache): If the register buffer isn't owned by the
10277 regcache, don't free it.
10278 (set_register_cache) [IN_PROCESS_AGENT]: Don't re-alocate
10279 pre-existing register caches.
10280 * remote-utils.c (convert_int_to_ascii): Constify `from' parameter
10282 (convert_ascii_to_int): : Constify `from' parameter type.
10283 (decode_M_packet, decode_X_packet): Replace the `to' parameter by
10284 a `to_p' pointer to pointer parameter. If TO_P is NULL, malloc
10285 the needed buffer in-place.
10286 (relocate_instruction): New.
10287 * server.c (handle_query) <qSymbols>: If the target supports
10288 tracepoints, give it a chance of looking up symbols. Report
10289 support for fast tracepoints.
10290 (handle_status): Stabilize threads.
10291 (process_serial_event): Adjust.
10292 * server.h (struct fast_tracepoint_jump): Forward declare.
10293 (struct process_info) <fast_tracepoint_jumps>: New field.
10294 (convert_ascii_to_int, convert_int_to_ascii): Adjust.
10295 (decode_X_packet, decode_M_packet): Adjust.
10296 (relocate_instruction): Declare.
10297 (in_process_agent_loaded): Declare.
10298 (tracepoint_look_up_symbols): Declare.
10299 (struct fast_tpoint_collect_status): Declare.
10300 (fast_tracepoint_collecting): Declare.
10301 (force_unlock_trace_buffer): Declare.
10302 (handle_tracepoint_bkpts): Declare.
10303 (initialize_low_tracepoint)
10304 (supply_fast_tracepoint_registers) [IN_PROCESS_AGENT]: Declare.
10305 * target.h (struct target_ops) <stabilize_threads,
10306 install_fast_tracepoint_jump_pad>: New fields.
10307 (stabilize_threads, install_fast_tracepoint_jump_pad): New.
10308 * tracepoint.c [HAVE_MALLOC_H]: Include malloc.h.
10309 [HAVE_STDINT_H]: Include stdint.h.
10310 (trace_debug_1): Rename to ...
10311 (trace_vdebug): ... this.
10312 (trace_debug): Rename to ...
10313 (trace_debug_1): ... this. Add `level' parameter.
10314 (trace_debug): New.
10315 (ATTR_USED, ATTR_NOINLINE): New.
10316 (IP_AGENT_EXPORT): New.
10317 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
10318 (collecting, gdb_collect, stop_tracing, flush_trace_buffer)
10319 (about_to_request_buffer_space, trace_buffer_is_full)
10320 (stopping_tracepoint, expr_eval_result, error_tracepoint)
10321 (tracepoints, tracing, trace_buffer_ctrl, trace_buffer_ctrl_curr)
10322 (trace_buffer_lo, trace_buffer_hi, traceframe_read_count)
10323 (traceframe_write_count, traceframes_created)
10324 (trace_state_variables)
10325 New renaming defines.
10326 (struct ipa_sym_addresses): New.
10327 (STRINGIZE_1, STRINGIZE, IPA_SYM): New.
10328 (symbol_list): New.
10329 (ipa_sym_addrs): New.
10330 (all_tracepoint_symbols_looked_up): New.
10331 (in_process_agent_loaded): New.
10332 (write_e_ipa_not_loaded): New.
10333 (maybe_write_ipa_not_loaded): New.
10334 (tracepoint_look_up_symbols): New.
10335 (debug_threads) [IN_PROCESS_AGENT]: New.
10336 (read_inferior_memory) [IN_PROCESS_AGENT]: New.
10337 (UNKNOWN_SIDE_EFFECTS): New.
10338 (stop_tracing): New.
10339 (flush_trace_buffer): New.
10340 (stop_tracing_bkpt): New.
10341 (flush_trace_buffer_bkpt): New.
10342 (read_inferior_integer): New.
10343 (read_inferior_uinteger): New.
10344 (read_inferior_data_pointer): New.
10345 (write_inferior_data_pointer): New.
10346 (write_inferior_integer): New.
10347 (write_inferior_uinteger): New.
10348 (struct collect_static_trace_data_action): Delete.
10349 (enum tracepoint_type): New.
10350 (struct tracepoint) <type>: New field `type'.
10351 <actions_str, step_actions, step_actions_str>: Only include in
10353 <orig_size, obj_addr_on_target, adjusted_insn_addr>
10354 <adjusted_insn_addr_end, jump_pad, jump_pad_end>: New fields.
10355 (tracepoints): Use IP_AGENT_EXPORT.
10356 (last_tracepoint): Don't include in the IPA.
10357 (stopping_tracepoint): Use IP_AGENT_EXPORT.
10358 (trace_buffer_is_full): Use IP_AGENT_EXPORT.
10359 (alloced_trace_state_variables): New.
10360 (trace_state_variables): Use IP_AGENT_EXPORT.
10361 (traceframe_t): Delete unused variable.
10362 (circular_trace_buffer): Don't include in the IPA.
10363 (trace_buffer_start): Delete.
10364 (struct trace_buffer_control): New.
10365 (trace_buffer_free): Delete.
10366 (struct ipa_trace_buffer_control): New.
10367 (GDBSERVER_FLUSH_COUNT_MASK, GDBSERVER_FLUSH_COUNT_MASK_PREV)
10368 (GDBSERVER_FLUSH_COUNT_MASK_CURR, GDBSERVER_UPDATED_FLUSH_COUNT_BIT):
10370 (trace_buffer_ctrl): New.
10371 (TRACE_BUFFER_CTRL_CURR): New.
10372 (trace_buffer_start, trace_buffer_free, trace_buffer_end_free):
10373 Reimplement as macros.
10374 (trace_buffer_wrap): Delete.
10375 (traceframe_write_count, traceframe_read_count)
10376 (traceframes_created, tracing): Use IP_AGENT_EXPORT.
10377 (struct tracepoint_hit_ctx) <type>: New field.
10378 (struct fast_tracepoint_ctx): New.
10379 (memory_barrier): New.
10381 (record_tracepoint_error): Update atomically in the IPA.
10382 (clear_inferior_trace_buffer): New.
10383 (about_to_request_buffer_space): New.
10384 (trace_buffer_alloc): Handle GDBserver and inferior simulatenous
10385 updating the same buffer.
10386 (add_tracepoint): Default the tracepoint's type to trap
10387 tracepoint, and orig_size to -1.
10388 (get_trace_state_variable) [IN_PROCESS_AGENT]: Handle allocated
10389 internal variables.
10390 (create_trace_state_variable): New parameter `gdb'. Handle it.
10391 (clear_installed_tracepoints): Clear fast tracepoint jumps.
10392 (cmd_qtdp): Handle fast tracepoints.
10393 (cmd_qtdv): Adjust.
10394 (max_jump_pad_size): New.
10395 (gdb_jump_pad_head): New.
10396 (get_jump_space_head): New.
10397 (claim_jump_space): New.
10398 (sort_tracepoints): New.
10399 (MAX_JUMP_SIZE): New.
10400 (cmd_qtstart): Handle fast tracepoints. Sync tracepoints with the
10402 (stop_tracing) [IN_PROCESS_AGENT]: Don't include the tdisconnected
10403 support. Upload fast traceframes, and delete internal IPA
10405 (stop_tracing_handler): New.
10406 (flush_trace_buffer_handler): New.
10407 (cmd_qtstop): Upload fast tracepoints.
10408 (response_tracepoint): Handle fast tracepoints.
10409 (tracepoint_finished_step): Upload fast traceframes. Set the
10410 tracepoint hit context's tracepoint type.
10411 (handle_tracepoint_bkpts): New.
10412 (tracepoint_was_hit): Set the tracepoint hit context's tracepoint
10413 type. Add comment about fast tracepoints.
10414 (collect_data_at_tracepoint) [IN_PROCESS_AGENT]: Don't access the
10415 non-existing action_str field.
10416 (get_context_regcache): Handle fast tracepoints.
10417 (do_action_at_tracepoint) [!IN_PROCESS_AGENT]: Don't write the PC
10419 (fast_tracepoint_from_jump_pad_address): New.
10420 (fast_tracepoint_from_ipa_tpoint_address): New.
10421 (collecting_t): New.
10422 (force_unlock_trace_buffer): New.
10423 (fast_tracepoint_collecting): New.
10425 (gdb_collect): New.
10426 (write_inferior_data_ptr): New.
10427 (target_tp_heap): New.
10428 (target_malloc): New.
10429 (download_agent_expr): New.
10431 (download_tracepoints): New.
10432 (download_trace_state_variables): New.
10433 (upload_fast_traceframes): New.
10434 (IPA_FIRST_TRACEFRAME): New.
10435 (IPA_NEXT_TRACEFRAME_1): New.
10436 (IPA_NEXT_TRACEFRAME): New.
10437 [IN_PROCESS_AGENT]: Include sys/mman.h and fcntl.h.
10438 [IN_PROCESS_AGENT] (gdb_tp_heap_buffer, gdb_jump_pad_buffer)
10439 (gdb_jump_pad_buffer_end): New.
10440 [IN_PROCESS_AGENT] (initialize_tracepoint_ftlib): New.
10441 (initialize_tracepoint): Adjust.
10442 [IN_PROCESS_AGENT]: Allocate the IPA heap, and jump pad scratch
10443 buffer. Initialize the low module.
10444 * utils.c (PREFIX, TOOLNAME): New.
10445 (malloc_failure): Use PREFIX.
10446 (error): In the IPA, an error causes an exit.
10447 (fatal, warning): Use PREFIX.
10448 (internal_error): Use TOOLNAME.
10449 (NUMCELLS): Increase to 10.
10450 * configure, config.in: Regenerate.
10452 2010-06-01 Pedro Alves <pedro@codesourcery.com>
10454 * server.c (handle_query) <qSupported>: Do two passes over the
10455 qSupported string to avoid nesting strtok.
10457 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
10459 * Makefile.in (SFILES): Add $(srcdir)/proc-service.list.
10461 * configure.ac (RDYNAMIC): New AC_MSG_CHECKING wrapping. Test also
10462 -Wl,--dynamic-list.
10463 * configure: Regenerate.
10464 * proc-service.list: New.
10466 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
10468 * linux-low.c (linux_core_of_thread): Fix crash on invalid CONTENT.
10471 2010-05-26 Ozkan Sezer <sezeroz@gmail.com>
10473 * gdbreplay.c (remote_open): Check error return from socket() call by
10474 its equality to -1 not by it being negative.
10475 * remote-utils.c (remote_open): Likewise.
10477 2010-05-23 Pedro Alves <pedro@codesourcery.com>
10479 * config.h: Regenerate.
10481 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
10483 * linux-m68k-low.c (ps_get_thread_area): Don't define if kernel
10484 doesn't provide PTRACE_GET_THREAD_AREA.
10486 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
10488 * linux-m68k-low.c: Include <asm/ptrace.h>
10489 (ps_get_thread_area): Implement.
10491 2010-05-03 Doug Evans <dje@google.com>
10493 * event-loop.c (struct callback_event): New struct.
10494 (callback_list): New global.
10495 (append_callback_event, delete_callback_event): New functions.
10496 (process_callback): New function.
10497 (start_event_loop): Call it.
10498 * remote-utils.c (NOT_SCHEDULED): Define.
10499 (readchar_buf, readchar_bufcnt, readchar_bufp): New static globals,
10500 moved out of readchar.
10501 (readchar): Rewrite. Call reschedule before returning.
10502 (reset_readchar): New function.
10503 (remote_close): Call it.
10504 (process_remaining, reschedule): New functions.
10505 * server.h (callback_handler_func): New typedef.
10506 (append_callback_event, delete_callback_event): Declare.
10508 2010-05-03 Pedro Alves <pedro@codesourcery.com>
10510 * proc-service.c (ps_pglobal_lookup): Use
10511 thread_db_look_up_one_symbol.
10512 * remote-utils.c (look_up_one_symbol): Add new `may_ask_gdb'
10513 parameter. Use it instead of all_symbols_looked_up.
10514 * server.h (struct process_info) <all_symbols_looked_up>: Delete
10516 (all_symbols_looked_up): Don't declare.
10517 (look_up_one_symbol): Add new `may_ask_gdb' parameter.
10518 * thread-db.c (struct thread_db) <all_symbols_looked_up>: New
10520 (thread_db_look_up_symbols): Adjust call to look_up_one_symbol.
10521 Set all_symbols_looked_up here.
10522 (thread_db_look_up_one_symbol): New.
10523 (thread_db_get_tls_address): Adjust.
10524 (thread_db_load_search, try_thread_db_load_1): Always allocate the
10525 thread_db object on the heap, and tentatively set it in the
10527 (thread_db_init): Don't set all_symbols_looked_up here.
10528 * linux-low.h (thread_db_look_up_one_symbol): Declare.
10530 2010-05-03 Pedro Alves <pedro@codesourcery.com>
10532 * linux-low.c (linux_kill, linux_detach): Adjust.
10533 (status_pending_p_callback): Remove redundant statement. Check
10534 for !TARGET_WAITIKIND_IGNORE, instead of
10535 TARGET_WAITKIND_STOPPED.
10536 (handle_tracepoints): Make sure LWP is locked. Adjust.
10537 (linux_wait_for_event_1): Adjust.
10538 (linux_cancel_breakpoints): New.
10539 (unsuspend_one_lwp): New.
10540 (unsuspend_all_lwps): New.
10541 (linux_wait_1): If finishing a step-over, unsuspend all lwps.
10542 (send_sigstop_callback): Change return type to int, add new
10543 `except' parameter and handle it.
10544 (suspend_and_send_sigstop_callback): New.
10545 (stop_all_lwps): Add new `suspend' and `expect' parameters, and
10546 pass them down. If SUSPEND, also increment the lwp's suspend
10548 (linux_resume_one_lwp): Add notice about resuming a suspended LWP.
10549 (need_step_over_p): Don't consider suspended LWPs.
10550 (start_step_over): Adjust.
10551 (proceed_one_lwp): Change return type to int, add new `except'
10552 parameter and handle it.
10553 (unsuspend_and_proceed_one_lwp): New.
10554 (proceed_all_lwps): Use find_inferior instead of
10556 (unstop_all_lwps): Add `unsuspend' parameter. If UNSUSPEND, them
10557 also decrement the suspend count of LWPs. Pass `except' down,
10558 instead of hacking its suspend count.
10559 (linux_pause_all): Add `freeze' parameter. Adjust.
10560 (linux_unpause_all): New.
10561 (linux_target_ops): Install linux_unpause_all.
10562 * server.c (handle_status): Adjust.
10563 * target.h (struct target_ops): New fields `unpause_all' and
10564 `cancel_breakpoints'. Add new parameter to `pause_all'.
10565 (pause_all): Add new `freeze' parameter.
10566 (unpause_all): New.
10567 (cancel_breakpoints): New.
10568 * tracepoint.c (clear_installed_tracepoints): Pause threads, and
10569 cancel breakpoints.
10570 (cmd_qtstart): Pause threads.
10571 (stop_tracing): Pause threads, and cancel breakpoints.
10572 * win32-low.c (win32_target_ops): Adjust.
10574 2010-05-03 Pedro Alves <pedro@codesourcery.com>
10576 * linux-low.c (linux_wait_for_event_1): Move passing the signal to
10577 the inferior right away from here...
10578 (linux_wait_1): ... to here, and adjust to check the thread's
10579 last_resume_kind instead of the lwp's step or stop_expected flags.
10581 2010-05-02 Pedro Alves <pedro@codesourcery.com>
10583 * README: Use consistent `GDB' and `GDBserver' spellings.
10585 2010-05-02 Pedro Alves <pedro@codesourcery.com>
10587 * linux-low.c (linux_kill_one_lwp): Assume the lwp is stopped.
10588 (linux_kill): Stop all lwps here. Don't delete the main lwp here.
10589 (linux_detach_one_lwp): Assume the lwp is stopped.
10590 (any_thread_of): Delete.
10591 (linux_detach): Stop all lwps here. Don't blindly delete all
10593 (delete_lwp_callback): New.
10594 (linux_mourn): Delete all lwps of the process that is gone.
10595 (linux_wait_1): Don't delete the last lwp of the process here.
10596 * mem-break.h (mark_breakpoints_out): Declare.
10597 * mem-break.c (mark_breakpoints_out): New.
10598 (free_all_breakpoints): Use it.
10599 * server.c (handle_target_event): If the process is gone, mark
10601 * thread-db.c (struct thread_db) <create_bp>: New field.
10602 (thread_db_enable_reporting): Fix prototype. Store a thread event
10603 breakpoint reference in the thread_db struct.
10604 (thread_db_load_search): Clear the thread_db object.
10605 (try_thread_db_load_1): Ditto.
10606 (switch_to_process): New.
10607 (disable_thread_event_reporting): Use it.
10608 (remove_thread_event_breakpoints): New.
10609 (thread_db_detach, thread_db_mourn): Use it.
10611 2010-05-01 Pedro Alves <pedro@codesourcery.com>
10613 * linux-low.c (linux_enable_event_reporting): New.
10614 (linux_wait_for_event_1, handle_extended_wait): Use it.
10616 2010-04-30 Pedro Alves <pedro@codesourcery.com>
10618 * linux-low.c (linux_kill_one_lwp, linux_kill)
10619 (linux_detach_one_lwp): Adjust to send_sigstop interface change.
10620 (send_sigstop): Take an lwp_info as parameter instead. Queue a
10621 SIGSTOP even if the LWP is stopped.
10622 (send_sigstop_callback): New.
10623 (stop_all_lwps): Use send_sigstop_callback instead.
10624 (linux_resume_one_thread): Adjust.
10625 (proceed_one_lwp): Still proceed an LWP that the client has
10626 requested to stop, if we haven't reported it as stopped yet. Make
10627 sure that LWPs the client want stopped, have a pending SIGSTOP.
10629 2010-04-26 Doug Evans <dje@google.com>
10631 * server.c (handle_general_set): Make static.
10633 * remote-utils.c (putpkt_binary_1): Call readchar instead of read.
10634 Print received char after testing for error/eof instead of before.
10635 (input_interrupt): Tweak comment.
10637 2010-04-23 Doug Evans <dje@google.com>
10639 * server.c (start_inferior): Print inferior argv if --debug.
10641 2010-04-21 Aleksandar Ristovski <aristovski@qnx.com>
10643 * Makefile.in (nto_low_h nto-low.o nto-x86-low.o): New dependency lists.
10644 * nto-x86-low.c: Include server.h
10646 2010-04-20 Pierre Muller <muller@ics.u-strasbg.fr>
10648 * win32-i386-low.c: Use __x86_64__ macro instead of __x86_64 to
10649 be consistent with other sources of this directory.
10650 (init_registers_amd64): Correct name of source file of this function
10653 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
10655 * configure.srv (x86_64-*-mingw*): New configuration for Windows
10656 64-bit executables.
10658 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
10660 * win32-i386-low.c: Add 64-bit support.
10661 (CONTEXT_EXTENDED_REGISTERS): Set macro to zero if not exisiting.
10662 (init_registers_amd64): Declare.
10663 (mappings): Add 64-bit version of array.
10664 (init_windows_x86): New function.
10665 (the_low_target): Change init_arch field to init_windows_x86.
10667 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
10669 * win32-low.c: Adapt to support also 64-bit architecture.
10670 (child_xfer_memory): Use uintptr_t type for local variable `addr'.
10671 (get_image_name): Use SIZE_T type for local variable `done'.
10672 (psapi_get_dll_name): Use LPVOID type for parameter `BaseAddress'.
10673 (toolhelp_get_dll_name): Idem.
10674 (handle_load_dll): Use CORE_ADDR type for local variable `load_addr'.
10675 Use uintptr_t typecast to avoid warning.
10676 (handle_unload_dll): Use uintptr_t typecast to avoid warning.
10677 (handle_exception): Use phex_nz to avoid warning.
10678 (win32_wait): Remove unused local variable `process'.
10680 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
10682 * configure.srv (srv_amd64_regobj): Replace `x86-64-avx.o' by
10685 2010-04-17 Pierre Muller <muller@ics.u-strasbg.fr>
10687 * configure.ac: Use `ws2_32' library for srv_mingw.
10688 * configure: Regenerate.
10689 * gdbreplay.c: Include winsock2.h instead of winsock.h.
10690 * remote-utils.c: Likewise.
10692 2010-04-17 H.J. Lu <hongjiu.lu@intel.com>
10694 * linux-x86-low.c (xmltarget_amd64_linux_no_xml): Define only
10695 if __x86_64__ is defined.
10697 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
10699 * configure: Regenerate.
10701 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
10703 * server.c (handle_query): Handle 'qGetTIBAddr' query.
10704 * target.h (target_ops): New get_tib_address field.
10705 * win32-low.h (win32_thread_info): Add thread_local_base field.
10706 * win32-low.c (child_add_thread): Add tlb argument.
10707 Set thread_local_base field to TLB.
10708 (get_child_debug_event): Adapt to child_add_thread change.
10709 (win32_get_tib_address): New function.
10710 (win32_target_ops): Set get_tib_address field to
10711 win32_get_tib_address.
10712 * linux-low.c (linux_target_ops): Set get_tib_address field to NULL.
10714 2010-04-12 Pedro Alves <pedro@codesourcery.com>
10716 * linux-low.c (linux_mourn): Also remove the process.
10717 * server.c (handle_target_event): Don't remove the process here.
10718 * nto-low.c (nto_mourn): New.
10719 (nto_target_ops): Install it.
10720 * spu-low.c (spu_mourn): New.
10721 (spu_target_ops): Install it.
10722 * win32-low.c (win32_mourn): New.
10723 (win32_target_ops): Install it.
10725 2010-04-12 Pedro Alves <pedro@codesourcery.com>
10727 * server.h (buffer_xml_printf): Remove redundant `;'.
10729 2010-04-12 Pedro Alves <pedro@codesourcery.com>
10731 * regcache.c (set_register_cache): Invalidate regcaches before
10732 changing the register cache layout.
10733 (regcache_invalidate_one): Allow a NULL regcache.
10734 * linux-x86-low.c (x86_linux_update_xmltarget): Invalidate
10735 regcaches before changing the register cache layout or the target
10738 2010-04-12 H.J. Lu <hongjiu.lu@intel.com>
10740 * linux-x86-low.c (x86_linux_update_xmltarget): Avoid unused
10741 variable warning on Linux/x86-64.
10743 2010-04-11 Pedro Alves <pedro@codesourcery.com>
10745 GDBserver disconnected tracing support.
10747 * linux-low.c (linux_remove_process): Delete.
10748 (add_lwp): Don't set last_resume_kind here.
10749 (linux_kill): Use `mourn'.
10750 (linux_detach): Use `thread_db_detach', and `mourn'.
10751 (linux_mourn): New.
10752 (linux_attach_lwp_1): Adjust comment.
10753 (linux_attach): last_resume_kind moved the thread_info; adjust.
10754 (status_pending_p_callback): Adjust.
10755 (linux_wait_for_event_1): Adjust.
10756 (count_events_callback, select_singlestep_lwp_callback)
10757 (select_event_lwp_callback, cancel_breakpoints_callback)
10758 (db_wants_lwp_stopped, linux_wait_1, need_step_over_p)
10759 (proceed_one_lwp): Adjust.
10760 (linux_async): Add debug output.
10761 (linux_thread_stopped): New.
10762 (linux_pause_all): New.
10763 (linux_target_ops): Install linux_mourn, linux_thread_stopped and
10765 * linux-low.h (struct lwp_info): Delete last_resume_kind field.
10766 (thread_db_free): Delete declaration.
10767 (thread_db_detach, thread_db_mourn): Declare.
10768 * thread-db.c (thread_db_init): Use thread_db_mourn.
10769 (thread_db_free): Delete, split in two.
10770 (disable_thread_event_reporting): New.
10771 (thread_db_detach): New.
10772 (thread_db_mourn): New.
10774 * server.h (struct thread_info) <last_resume_kind>: New field.
10775 <attached>: Add comment.
10776 <gdb_detached>: New field.
10777 (handler_func): Change return type to int.
10778 (handle_serial_event, handle_target_event): Ditto.
10779 (gdb_connected): Declare.
10781 (disconnected_tracing): Declare.
10782 (stop_tracing): Declare.
10784 * server.c (handle_query) <qSupported>: Report support for
10785 disconnected tracing.
10786 (queue_stop_reply_callback): Account for running threads.
10787 (gdb_wants_thread_stopped): New.
10788 (gdb_wants_all_threads_stopped): New.
10789 (gdb_reattached_process): New.
10790 (handle_status): Clear the `gdb_detached' flag of all processes.
10791 In all-stop, stop all threads.
10792 (main): Be sure to leave tfind mode. Handle disconnected tracing.
10793 (process_serial_event): If the remote connection breaks, or if an
10794 exit was forced with "monitor exit", force an event loop exit.
10795 Handle disconnected tracing on detach.
10796 (handle_serial_event): Adjust.
10797 (handle_target_event): If GDB isn't connected, forward events back
10798 to the inferior, unless the last process exited, in which case,
10799 exit gdbserver. Adjust interface.
10801 * remote-utils.c (remote_open): Don't block in accept. Instead
10802 register an event loop source on the listen socket file
10803 descriptor. Refactor bits into ...
10804 (listen_desc): ... this new global.
10805 (gdb_connected): ... this new function.
10806 (enable_async_notification): ... this new function.
10807 (handle_accept_event): ... this new function.
10808 (remote_close): Clear remote_desc.
10810 * inferiors.c (add_thread): Set the new thread's last_resume_kind.
10812 * target.h (struct target_ops) <mourn, thread_stopped, pause_all>:
10814 (mourn_inferior): Define.
10815 (target_process_qsupported): Avoid the dangling else problem.
10816 (thread_stopped): Define.
10817 (pause_all): Define.
10818 (target_waitstatus_to_string): Declare.
10819 * target.c (target_waitstatus_to_string): New.
10821 * tracepoint.c (tracing): Make extern.
10822 (disconnected_tracing): New.
10823 (stop_tracing): Make extern. Handle tracing stops due to GDB
10825 (cmd_qtdisconnected): New.
10826 (cmd_qtstatus): Report disconnected tracing status in trace reply.
10827 (handle_tracepoint_general_set): Handle QTDisconnected.
10829 * event-loop.c (event_handler_func): Change return type to int.
10830 (process_event): Bail out if the event handler wants the event
10832 (handle_file_event): Ditto.
10833 (start_event_loop): Bail out if the event handler wants the event
10836 * nto-low.c (nto_target_ops): Adjust.
10837 * spu-low.c (spu_wait): Don't remove the process here.
10838 (spu_target_ops): Adjust.
10839 * win32-low.c (win32_wait): Don't remove the process here.
10840 (win32_target_ops): Adjust.
10842 2010-04-11 Pedro Alves <pedro@codesourcery.com>
10844 * regcache.c (realloc_register_cache): Invalidate inferior's
10845 regcache before recreating it.
10847 2010-04-09 Pedro Alves <pedro@codesourcery.com>
10849 * tracepoint.c (cmd_qtstatus): Report trace buffer circularity.
10851 2010-04-09 Stan Shebs <stan@codesourcery.com>
10852 Pedro Alves <pedro@codesourcery.com>
10854 * server.h (LONGEST): New.
10855 (struct thread_info) <while_stepping>: New field.
10856 (unpack_varlen_hex, xrealloc, pulongest, plongest, phex_nz):
10858 (initialize_tracepoint, handle_tracepoint_general_set)
10859 (handle_tracepoint_query, tracepoint_finished_step)
10860 (tracepoint_was_hit, release_while_stepping_state_list):
10861 (current_traceframe): Declare.
10862 * server.c (handle_general_set): Handle tracepoint packets.
10863 (read_memory): New.
10864 (write_memory): New.
10865 (handle_search_memory_1): Use read_memory.
10866 (handle_query): Report support for conditional tracepoints, trace
10867 state variables, and tracepoint sources. Handle tracepoint
10869 (main): Initialize the tracepoints module.
10870 (process_serial_event): Handle traceframe reads/writes.
10872 * linux-low.c (handle_tracepoints): New.
10873 (linux_wait_1): Call it.
10874 (linux_resume_one_lwp): Handle while-stepping.
10875 (linux_supports_tracepoints, linux_read_pc, linux_write_pc): New.
10876 (linux_target_ops): Install them.
10877 * linux-low.h (struct linux_target_ops) <supports_tracepoints>:
10879 * linux-x86-low.c (x86_supports_tracepoints): New.
10880 (the_low_target). Install it.
10882 * mem-break.h (delete_breakpoint): Declare.
10883 * mem-break.c (delete_breakpoint): Make external.
10885 * target.h (struct target_ops): Add `supports_tracepoints',
10886 `read_pc', and `write_pc' fields.
10887 (target_supports_tracepoints): Define.
10888 * utils.c (xrealloc, decimal2str, pulongest, plongest, thirty_two)
10891 * regcache.h (struct regcache) <registers_owned>: New field.
10892 (init_register_cache, regcache_cpy): Declare.
10893 (regcache_read_pc, regcache_write_pc): Declare.
10894 (register_cache_size): Declare.
10895 (supply_regblock): Declare.
10896 * regcache.c (init_register_cache): New.
10897 (new_register_cache): Use it.
10898 (regcache_cpy): New.
10899 (register_cache_size): New.
10900 (supply_regblock): New.
10901 (regcache_read_pc, regcache_write_pc): New.
10903 * tracepoint.c: New.
10905 * Makefile.in (OBS): Add tracepoint.o.
10906 (tracepoint.o): New rule.
10908 2010-04-08 H.J. Lu <hongjiu.lu@intel.com>
10910 * Makefile.in (clean): Also remove i386-mmx.c i386-mmx-linux.c.
10912 (i386-mmx.c): Likewise.
10913 (i386-mmx-linux.o): Likewise.
10914 (i386-mmx-linux.c): Likewise.
10916 * configure.srv (srv_i386_regobj): Add i386-mmx.o.
10917 (srv_i386_linux_regobj): Add i386-mmx-linux.o.
10918 (srv_i386_xmlfiles): Add i386/i386-mmx.xml.
10919 (srv_i386_linux_xmlfiles): Add i386/i386-mmx-linux.xml.
10921 * linux-x86-low.c (init_registers_i386_mmx_linux): New.
10922 (x86_linux_update_xmltarget): Call init_registers_i386_mmx_linux
10923 and return if ptrace PTRACE_GETFPXREGS failed in 32bit.
10925 2010-04-07 H.J. Lu <hongjiu.lu@intel.com>
10927 * Makefile.in (clean): Updated.
10929 (i386-avx.c): Likewise.
10930 (i386-avx-linux.o): Likewise.
10931 (i386-avx-linux.c): Likewise.
10932 (amd64-avx.o): Likewise.
10933 (amd64-avx.c): Likewise.
10934 (amd64-avx-linux.o): Likewise.
10935 (amd64-avx-linux.c): Likewise.
10937 * configure.srv (srv_i386_regobj): Add i386-avx.o.
10938 (srv_i386_linux_regobj): Add i386-avx-linux.o.
10939 (srv_amd64_regobj): Add amd64-avx.o.
10940 (srv_amd64_linux_regobj): Add amd64-avx-linux.o.
10941 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx.xml.
10942 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx.xml.
10943 (srv_i386_xmlfiles): Add i386/i386-avx.xml.
10944 (srv_amd64_xmlfiles): Add i386/amd64-avx.xml.
10945 (srv_i386_linux_xmlfiles): Add i386/i386-avx-linux.xml.
10946 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-linux.xml.
10948 * i387-fp.c: Include "i386-xstate.h".
10950 (i387_cache_to_xsave): Likewise.
10951 (i387_xsave_to_cache): Likewise.
10952 (x86_xcr0): Likewise.
10954 * i387-fp.h (i387_cache_to_xsave): Likewise.
10955 (i387_xsave_to_cache): Likewise.
10956 (x86_xcr0): Likewise.
10958 * linux-arm-low.c (target_regsets): Initialize nt_type to 0.
10959 * linux-crisv32-low.c (target_regsets): Likewise.
10960 * linux-m68k-low.c (target_regsets): Likewise.
10961 * linux-mips-low.c (target_regsets): Likewise.
10962 * linux-ppc-low.c (target_regsets): Likewise.
10963 * linux-s390-low.c (target_regsets): Likewise.
10964 * linux-sh-low.c (target_regsets): Likewise.
10965 * linux-sparc-low.c (target_regsets): Likewise.
10966 * linux-xtensa-low.c (target_regsets): Likewise.
10968 * linux-low.c: Include <sys/uio.h>.
10969 (regsets_fetch_inferior_registers): Support nt_type.
10970 (regsets_store_inferior_registers): Likewise.
10971 (linux_process_qsupported): New.
10972 (linux_target_ops): Add linux_process_qsupported.
10974 * linux-low.h (regset_info): Add nt_type.
10975 (linux_target_ops): Add process_qsupported.
10977 * linux-x86-low.c: Include "i386-xstate.h", "elf/common.h"
10979 (init_registers_i386_avx_linux): New.
10980 (init_registers_amd64_avx_linux): Likewise.
10981 (xmltarget_i386_linux_no_xml): Likewise.
10982 (xmltarget_amd64_linux_no_xml): Likewise.
10983 (PTRACE_GETREGSET): Likewise.
10984 (PTRACE_SETREGSET): Likewise.
10985 (x86_fill_xstateregset): Likewise.
10986 (x86_store_xstateregset): Likewise.
10987 (use_xml): Likewise.
10988 (x86_linux_update_xmltarget): Likewise.
10989 (x86_linux_process_qsupported): Likewise.
10990 (target_regsets): Add NT_X86_XSTATE entry and Initialize nt_type.
10991 (x86_arch_setup): Don't call init_registers_amd64_linux nor
10992 init_registers_i386_linux here. Call
10993 x86_linux_update_xmltarget.
10994 (the_low_target): Add x86_linux_process_qsupported.
10996 * server.c (handle_query): Call target_process_qsupported.
10998 * target.h (target_ops): Add process_qsupported.
10999 (target_process_qsupported): New.
11001 2010-04-03 Pedro Alves <pedro@codesourcery.com>
11003 * inferiors.c (add_thread): Set last_status kind to
11004 TARGET_WAITKIND_IGNORE.
11005 * linux-low.c (cancel_breakpoint): Remove unnecessary regcache
11006 fetch. Use ptid_of. Avoid unnecessary get_lwp_thread calls.
11007 (linux_wait_1): Move `thread' local definition to block that uses
11008 it. Don't NULL initialize `event_child'.
11009 (linux_resume_one_thread): Avoid unnecessary get_lwp_thread calls.
11010 Alway set the thread's last_status to TARGET_WAITKIND_IGNORE.
11011 * linux-x86-low.c (x86_breakpoint_at): Read raw memory.
11013 2010-04-01 Pedro Alves <pedro@codesourcery.com>
11015 * linux-low.c (get_stop_pc): Don't adjust the PC if stopped with
11016 an extended waitstatus, or by a watchpoint.
11017 (cancel_breakpoints_callback): Don't cancel a breakpoint if the
11018 thread was stepping or has been stopped by a watchpoint.
11020 2010-04-01 Pedro Alves <pedro@codesourcery.com>
11022 * mem-break.c (struct raw_breakpoint): New field shlib_disabled.
11023 (set_gdb_breakpoint_at): If GDB is inserting a breakpoint on top
11024 of another, then delete the previous, and validate all
11026 (validate_inserted_breakpoint): New.
11027 (delete_disabled_breakpoints): New.
11028 (validate_breakpoints): New.
11029 (check_mem_read): Validate breakpoints before trusting their
11030 shadow. Delete disabled breakpoints.
11031 (check_mem_write): Validate breakpoints before trusting they
11032 should be inserted. Delete disabled breakpoints.
11033 * mem-break.h (validate_breakpoints):
11034 * server.c (handle_query): Validate breakpoints when we see a
11037 2010-04-01 Pedro Alves <pedro@codesourcery.com>
11039 * linux-low.c (linux_wait_1): Avoid setting need_step_over is
11040 there's a GDB breakpoint at stop_pc. Always report a trap to GDB
11041 if we could tell there's a GDB breakpoint at stop_pc.
11042 (need_step_over_p): Don't do a step over if we find a GDB
11043 breakpoint at the resume PC.
11045 * mem-break.c (struct raw_breakpoint): New.
11046 (enum bkpt_type): New type `gdb_breakpoint'.
11047 (struct breakpoint): Delete the `PC', `old_data' and `inserted'
11048 fields. New field `raw'.
11049 (find_raw_breakpoint_at): New.
11050 (set_raw_breakpoint_at): Handle refcounting. Create a raw
11051 breakpoint instead.
11052 (set_breakpoint_at): Adjust.
11053 (delete_raw_breakpoint): New.
11054 (release_breakpoint): New.
11055 (delete_breakpoint): Rename to...
11056 (delete_breakpoint_1): ... this. Add proc parameter. Use
11057 release_breakpoint. Return ENOENT.
11058 (delete_breakpoint): Reimplement.
11059 (find_breakpoint_at): Delete.
11060 (find_gdb_breakpoint_at): New.
11061 (delete_breakpoint_at): Delete.
11062 (set_gdb_breakpoint_at): New.
11063 (delete_gdb_breakpoint_at): New.
11064 (gdb_breakpoint_here): New.
11065 (set_reinsert_breakpoint): Use release_breakpoint.
11066 (uninsert_breakpoint): Rename to ...
11067 (uninsert_raw_breakpoint): ... this.
11068 (uninsert_breakpoints_at): Adjust to handle raw breakpoints.
11069 (reinsert_raw_breakpoint): Change parameter type to
11071 (reinsert_breakpoints_at): Adjust to handle raw breakpoints
11073 (check_breakpoints): Adjust. Use release_breakpoint.
11074 (breakpoint_here): Rewrite using find_raw_breakpoint_at.
11075 (breakpoint_inserted_here): Ditto.
11076 (check_mem_read): Adjust to iterate over raw breakpoints instead.
11077 Don't trust the breakpoint's shadow if it is not inserted.
11078 (check_mem_write): Adjust to iterate over raw breakpoints instead.
11079 (delete_all_breakpoints): Adjust.
11080 (free_all_breakpoints): Mark all breakpoints as uninserted, and
11081 use delete_breakpoint_1.
11083 * mem-break.h (breakpoints_supported): Delete declaration.
11084 (set_gdb_breakpoint_at): Declare.
11085 (gdb_breakpoint_here): Declare.
11086 (delete_breakpoint_at): Delete.
11087 (delete_gdb_breakpoint_at): Declare.
11089 * server.h (struct raw_breakpoint): Forward declare.
11090 (struct process_info): New field `raw_breakpoints'.
11092 * linux-x86-low.c (x86_insert_point, x86_remote_point): Handle Z0
11095 2010-03-24 Pedro Alves <pedro@codesourcery.com>
11097 * linux-low.c (status_pending_p_callback): Fix comment.
11098 (linux_wait_for_event_1): Move most of the internal breakpoint
11099 handling from here...
11100 (linux_wait_1): ... to here.
11101 (count_events_callback): New.
11102 (select_singlestep_lwp_callback): New.
11103 (select_event_lwp_callback): New.
11104 (cancel_breakpoints_callback): New.
11105 (select_event_lwp): New.
11106 (linux_wait_1): Simplify internal breakpoint handling. Give equal
11107 priority to all LWPs that have had events that should be reported
11108 to the client. Cancel breakpoints when about to reporting the
11109 event to the client, not while stopping lwps. No longer cancel
11110 finished single-steps here.
11111 (cancel_finished_single_step): Delete.
11112 (cancel_finished_single_steps): Delete.
11114 2010-03-24 Pedro Alves <pedro@codesourcery.com>
11116 * mem-break.c (enum bkpt_type): New.
11117 (struct breakpoint): New field `type'.
11118 (set_breakpoint_at): Change return type to struct breakpoint
11119 pointer. Set type to `other_breakpoint' by default.
11120 (delete_breakpoint): Rewrite, supporting more than one breakpoint
11121 in the breakpoint list.
11122 (delete_reinsert_breakpoints): Only delete reinsert breakpoints.
11123 (reinsert_breakpoint): Rename to ...
11124 (reinsert_raw_breakpoint): ... this.
11125 (reinsert_breakpoints_at): Adjust.
11126 * mem-break.h (struct breakpoint): Declare.
11127 (set_breakpoint_at): Change return type to struct breakpoint
11130 2010-03-24 Pedro Alves <pedro@codesourcery.com>
11132 * server.c (handle_query): Assign, not compare.
11134 2010-03-24 Pedro Alves <pedro@codesourcery.com>
11136 Teach linux gdbserver to step-over-breakpoints.
11138 * linux-low.c (can_hardware_single_step): New.
11139 (supports_breakpoints): New.
11140 (handle_extended_wait): If stopping threads, read the stop pc of
11141 the new cloned LWP.
11143 (get_stop_pc): Add `lwp' parameter. Handle it. Bail out if the
11144 low target doesn't support retrieving the PC.
11145 (add_lwp): Set last_resume_kind to resume_continue.
11146 (linux_attach_lwp_1): Adjust comments. Always set stop_expected.
11147 (linux_attach): Don't clear stop_expected. Set the lwp's
11148 last_resume_kind to resume_stop.
11149 (linux_detach_one_lwp): Don't check for removed breakpoints.
11150 (check_removed_breakpoint): Delete.
11151 (status_pending_p): Rename to ...
11152 (status_pending_p_callback): ... this. Don't check for removed
11153 breakpoints. Don't consider threads that are stopped from GDB's
11155 (linux_wait_for_lwp): Always read the stop_pc here.
11156 (cancel_breakpoint): New.
11157 (step_over_bkpt): New global.
11158 (linux_wait_for_event_1): Implement stepping over breakpoints.
11159 (gdb_wants_lwp_stopped): New.
11160 (gdb_wants_all_stopped): New.
11161 (linux_wait_1): Tag threads as gdb-wants-stopped. Cancel finished
11162 single-step traps here. Store the thread's last reported target
11164 (send_sigstop): Don't clear stop_expected. Always set it,
11166 (mark_lwp_dead): Remove reference to pending_is_breakpoint.
11167 (cancel_finished_single_step): New.
11168 (cancel_finished_single_steps): New.
11169 (wait_for_sigstop): Don't cancel finished single-step traps here.
11170 (linux_resume_one_lwp): Don't check for removed breakpoints.
11171 Don't set `step' on non-hardware step archs.
11172 (linux_set_resume_request): Ignore resume_stop requests if already
11173 stopping or stopped. Set the lwp's last_resume_kind.
11174 (resume_status_pending_p): Don't check for removed breakpoints.
11175 (need_step_over_p): New.
11176 (start_step_over): New.
11177 (finish_step_over): New.
11178 (linux_resume_one_thread): Always queue a sigstop for resume_stop
11179 requests. Clear the thread's last reported target waitstatus.
11180 Don't use the `suspended' flag. Don't consider pending breakpoints.
11181 (linux_resume): Start a step-over if necessary.
11182 (proceed_one_lwp): New.
11183 (proceed_all_lwps): New.
11184 (unstop_all_lwps): New.
11185 * linux-low.h (struct lwp_info): Rewrite comment for the
11186 `suspended' flag. Add the `stop_pc' field. Delete the
11187 `pending_stop_pc' field. Tweak the `stepping' flag's comment.
11188 Add `'last_resume_kind' and `need_step_over' fields.
11189 * inferiors.c (struct thread_info): Delete, moved elsewhere.
11190 * mem-break.c (struct breakpoint): Delete `reinserting' flag.
11191 Delete `breakpoint_to_reinsert' field. New flag `inserted'.
11192 (set_raw_breakpoint_at): New.
11193 (set_breakpoint_at): Rewrite to use it.
11194 (reinsert_breakpoint_handler): Delete.
11195 (set_reinsert_breakpoint): New.
11196 (reinsert_breakpoint_by_bp): Delete.
11197 (delete_reinsert_breakpoints): New.
11198 (uninsert_breakpoint): Rewrite.
11199 (uninsert_breakpoints_at): New.
11200 (reinsert_breakpoint): Rewrite.
11201 (reinsert_breakpoints_at): New.
11202 (check_breakpoints): Rewrite.
11203 (breakpoint_here): New.
11204 (breakpoint_inserted_here): New.
11205 (check_mem_read): Adjust.
11206 * mem-break.h (breakpoints_supported, breakpoint_here)
11207 (breakpoint_inserted_here, set_reinsert_breakpoint): Declare.
11208 (reinsert_breakpoint_by_bp): Delete declaration.
11209 (delete_reinsert_breakpoints): Declare.
11210 (reinsert_breakpoint): Delete declaration.
11211 (reinsert_breakpoints_at): Declare.
11212 (uninsert_breakpoint): Delete declaration.
11213 (uninsert_breakpoints_at): Declare.
11214 (check_breakpoints): Adjust prototype.
11215 * server.h: Adjust include order.
11216 (struct thread_info): Declare here. Add a `last_status' field.
11218 2010-03-23 Michael Snyder <msnyder@vmware.com>
11220 * server.c (crc32): New function.
11221 (handle_query): Add handling for 'qCRC:' request.
11223 2010-03-23 Pedro Alves <pedro@codesourcery.com>
11225 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR6 if the
11226 lwp had been stopped by a watchpoint.
11228 2010-03-16 Pedro Alves <pedro@codesourcery.com>
11230 * server.h (internal_error): Declare.
11231 (gdb_assert, ASSERT_FUNCTION, gdb_assert_fail): Define.
11232 * utils.c (internal_error): New function.
11234 2010-03-15 Andreas Schwab <schwab@redhat.com>
11236 * configure.srv: Fix typo setting srv_regobj.
11238 2010-03-15 Pedro Alves <pedro@codesourcery.com>
11240 * linux-low.c (fetch_register): Avoid passing a non string literal
11242 (usr_store_inferior_registers): Ditto.
11244 2010-03-14 Pedro Alves <pedro@codesourcery.com>
11246 * linux-low.c (linux_write_memory): Bail out early if peeking
11249 2010-03-14 Pedro Alves <pedro@codesourcery.com>
11251 * linux-low.h (struct lwp_info): New fields
11252 `stopped_by_watchpoint' and `stopped_data_address'.
11253 * linux-low.c (linux_wait_for_lwp): Check for watchpoint triggers
11254 here, and cache them in the lwp object.
11255 (wait_for_sigstop): Check stopped_by_watchpoint lwp field
11257 (linux_resume_one_lwp): Clear the lwp's stopped_by_watchpoint
11259 (linux_stopped_by_watchpoint): Rewrite.
11260 (linux_stopped_data_address): Rewrite.
11262 2010-03-06 Simo Melenius <simo.melenius@iki.fi>
11264 * linux-low.c (linux_wait_for_lwp): Fetch the regcache after
11265 switching the current inferior, not before.
11267 2010-03-01 H.J. Lu <hongjiu.lu@intel.com>
11269 * Makefile.in (clean): Replace reg-i386.c, reg-x86-64.c,
11270 reg-i386-linux.c and reg-x86-64-linux.c with i386.c, amd64.c,
11271 i386-linux.c and amd64-linux.c.
11272 (reg-i386.o): Removed.
11273 (reg-i386.c): Likewise.
11274 (reg-i386-linux.o): Likewise.
11275 (reg-i386-linux.c): Likewise.
11276 (reg-x86-64.o): Likewise.
11277 (reg-x86-64.c): Likewise.
11278 (reg-x86-64-linux.o): Likewise.
11279 (reg-x86-64-linux.c): Likewise.
11281 (i386.c): Likewise.
11282 (i386-linux.o): Likewise.
11283 (i386-linux.c): Likewise.
11284 (amd64.o): Likewise.
11285 (amd64.c): Likewise.
11286 (amd64-linux.o): Likewise.
11287 (amd64-linux.c): Likewise.
11289 * configure.srv (srv_i386_regobj): New.
11290 (srv_i386_linux_regobj): Likewise.
11291 (srv_amd64_regobj): Likewise.
11292 (srv_amd64_linux_regobj): Likewise.
11293 (srv_i386_32bit_xmlfiles): Likewise.
11294 (srv_i386_64bit_xmlfiles): Likewise.
11295 (srv_i386_xmlfiles): Likewise.
11296 (srv_amd64_xmlfiles): Likewise.
11297 (srv_i386_linux_xmlfiles): Likewise.
11298 (srv_amd64_linux_xmlfiles): Likewise.
11299 (i[34567]86-*-cygwin*): Set srv_regobj to $srv_i386_regobj. Set
11300 srv_xmlfiles to $srv_i386_xmlfiles.
11301 (i[34567]86-*-mingw32ce*): Likewise.
11302 (i[34567]86-*-mingw*): Likewise.
11303 (i[34567]86-*-nto*): Likewise.
11304 (i[34567]86-*-linux*): Set srv_regobj to $srv_i386_linux_regobj
11305 and $srv_amd64_linux_regobj. Set srv_xmlfiles to
11306 $srv_i386_linux_xmlfiles and $srv_amd64_linux_xmlfiles.
11307 (x86_64-*-linux*): Likewise.
11309 * linux-x86-low.c (init_registers_x86_64_linux): Removed.
11310 (init_registers_amd64_linux): New.
11311 (x86_arch_setup): Replace init_registers_x86_64_linux with
11312 init_registers_amd64_linux.
11314 2010-02-23 Maxim Kuvyrkov <maxim@codesourcery.com>
11316 * configure.ac: Check for libdl. If it is not available link against
11317 static libthread_db.
11318 * configure: Regenerate.
11320 2010-02-22 Pedro Alves <pedro@codesourcery.com>
11324 * i386-low.c (i386_length_and_rw_bits): Throw a fatal error if
11325 handing a read watchpoint.
11326 (i386_low_insert_watchpoint): Read watchpoints aren't supported.
11328 2010-02-12 Doug Evans <dje@google.com>
11330 * linux-low.c (linux_supports_tracefork_flag): Document.
11331 (linux_look_up_symbols): Add comment.
11333 2010-02-03 H.J. Lu <hongjiu.lu@intel.com>
11335 * regcache.c (supply_register): Clear regcache if buf is NULL.
11337 2010-02-02 Nicolas Roche <roche@sourceware.org>
11338 Joel Brobecker <brobecker@adacore.com>
11340 * inferiors.c (find_inferior): Add function documentation.
11341 (unloaded_dll): Handle the case where the unloaded dll has not
11342 been previously registered in the dll list.
11344 2010-02-01 Daniel Jacobowitz <dan@codesourcery.com>
11346 * linux-arm-low.c (thumb_breakpoint_len): Delete.
11347 (thumb2_breakpoint): New.
11348 (arm_breakpoint_at): Check for Thumb-2 breakpoints.
11350 2010-01-29 Daniel Jacobowitz <dan@codesourcery.com>
11352 * linux-low.c (get_stop_pc): Check for SIGTRAP.
11353 (linux_wait_for_event_1): Handle SIGILL and SIGSEGV as possible
11356 2010-01-21 Pedro Alves <pedro@codesourcery.com>
11358 * linux-ppc-low.c (ppc_arch_setup): Adjust to regcache changes.
11360 2010-01-21 Jan Kratochvil <jan.kratochvil@redhat.com>
11362 * linux-s390-low.c (s390_collect_ptrace_register)
11363 (s390_supply_ptrace_register): Adjust it for the new regcache parameter.
11365 2010-01-21 Doug Evans <dje@google.com>
11367 * linux-low.c (PTRACE_ARG3_TYPE): Change from long to void*.
11368 (PTRACE_ARG4_TYPE): New macro.
11369 (handle_extended_wait): Cast ptrace arg4 to PTRACE_ARG4_TYPE.
11370 (linux_wait_for_event_1, linux_resume_one_lwp): Ditto.
11371 (fetch_register): Cast to uintptr_t before casting to PTRACE_ARG3_TYPE.
11372 (usr_store_inferior_registers): Ditto.
11373 (linux_read_memory, linux_write_memory): Ditto.
11374 (linux_test_for_tracefork): Ditto.
11376 * linux-arm-low.c: Remove redundant include of gdb_proc_service.h.
11377 Only include elf.h if gdb_proc_service.h didn't include linux/elf.h.
11379 2010-01-21 Pedro Alves <pedro@codesourcery.com>
11381 * proc-service.c (ps_lgetregs): Don't refetch registers from the
11384 2010-01-21 Pedro Alves <pedro@codesourcery.com>
11386 * spu-low.c (spu_fetch_registers, spu_store_registers): Change
11387 prototype to take a regcache. Adjust.
11389 2010-01-20 Pedro Alves <pedro@codesourcery.com>
11391 * regcache.h (struct thread_info): Forward declare.
11392 (struct regcache): New.
11393 (new_register_cache): Adjust prototype.
11394 (get_thread_regcache): Declare.
11395 (free_register_cache): Adjust prototype.
11396 (registers_to_string, registers_from_string): Ditto.
11397 (supply_register, supply_register_by_name, collect_register)
11398 (collect_register_as_string, collect_register_by_name): Ditto.
11399 * regcache.c (struct inferior_regcache_data): Delete.
11400 (get_regcache): Rename to ...
11401 (get_thread_regcache): ... this. Adjust. Switch inferior before
11402 fetching registers.
11403 (regcache_invalidate_one): Adjust.
11404 (regcache_invalidate): Fix prototype.
11405 (new_register_cache): Return the new register cache.
11406 (free_register_cache): Change prototype.
11407 (realloc_register_cache): Adjust.
11408 (registers_to_string): Change prototype to take a regcache. Adjust.
11409 (registers_from_string): Ditto.
11410 (register_data): Ditto.
11411 (supply_register): Ditto.
11412 (supply_register_by_name): Ditto.
11413 (collect_register): Ditto.
11414 (collect_register_as_string): Ditto.
11415 (collect_register_by_name): Ditto.
11416 * server.c (process_serial_event): Adjust.
11417 * linux-low.h (regset_fill_func, regset_store_func): Change
11419 (get_pc, set_pc, collect_ptrace_register, supply_ptrace_register):
11421 * linux-low.c (get_stop_pc): Adjust.
11422 (check_removed_breakpoint): Adjust.
11423 (linux_wait_for_event): Adjust.
11424 (linux_resume_one_lwp): Adjust.
11425 (fetch_register): Add regcache parameter. Adjust.
11426 (usr_store_inferior_registers): Ditto.
11427 (regsets_fetch_inferior_registers): Ditto.
11428 (regsets_store_inferior_registers): Ditto.
11429 (linux_fetch_registers, linux_store_registers): Ditto.
11430 * i387-fp.c (i387_cache_to_fsave): Change prototype to take a
11432 (i387_fsave_to_cache, i387_cache_to_fxsave, i387_fxsave_to_cache):
11434 * i387-fp.h (i387_cache_to_fsave, i387_fsave_to_cache): Change
11435 prototype to take a regcache.
11436 (i387_cache_to_fxsave, i387_fxsave_to_cache): Ditto.
11437 * remote-utils.c (convert_ascii_to_int, outreg)
11438 (prepare_resume_reply): Change prototype to take a regcache.
11440 * target.h (struct target_ops) <fetch_registers, store_registers>:
11441 Change prototype to take a regcache.
11442 (fetch_inferior_registers, store_inferior_registers): Change
11443 prototype to take a regcache. Adjust.
11444 * proc-service.c (ps_lgetregs): Adjust.
11445 * linux-x86-low.c (x86_fill_gregset, x86_store_gregset)
11446 (x86_fill_fpregset, x86_store_fpregset, x86_fill_fpxregset)
11447 (x86_store_fpxregset, x86_get_pc, x86_set_pc): Change prototype to
11448 take a regcache. Adjust.
11449 * linux-arm-low.c (arm_fill_gregset, arm_store_gregset)
11450 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
11451 (arm_store_vfpregset, arm_get_pc, arm_set_pc):
11452 (arm_breakpoint_at): Change prototype to take a regcache. Adjust.
11453 * linux-cris-low.c (cris_get_pc, cris_set_pc)
11454 (cris_cannot_fetch_register):
11455 (cris_breakpoint_at): Change prototype to take a regcache.
11457 * linux-crisv32-low.c (cris_get_pc, cris_set_pc,
11458 cris_reinsert_addr, cris_write_data_breakpoint): Change prototype
11459 to take a regcache. Adjust.
11460 (cris_breakpoint_at, cris_insert_point, cris_remove_point):
11462 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Change prototype to
11463 take a regcache. Adjust.
11464 * linux-m68k-low.c (m68k_fill_gregset, m68k_store_gregset)
11465 (m68k_fill_fpregset, m68k_store_fpregset, m68k_get_pc,
11466 (m68k_set_pc): Change prototype to take a regcache. Adjust.
11467 * linux-mips-low.c (mips_get_pc):
11468 (mips_set_pc): Change prototype to take a regcache. Adjust.
11469 (mips_reinsert_addr): Adjust.
11470 (mips_collect_register): Change prototype to take a regcache.
11472 (mips_supply_register):
11473 (mips_collect_register_32bit, mips_supply_register_32bit)
11474 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
11475 (mips_store_fpregset): Ditto.
11476 * linux-ppc-low.c (ppc_supply_ptrace_register)
11477 (ppc_supply_ptrace_register): Ditto.
11478 (parse_spufs_run): Adjust.
11479 (ppc_get_pc, ppc_set_pc, ppc_fill_gregset, ppc_fill_vsxregset)
11480 (ppc_store_vsxregset, ppc_fill_vrregset, ppc_store_vrregset)
11481 (ppc_fill_evrregset, ppc_store_evrregset): Change prototype to
11482 take a regcache. Adjust.
11483 * linux-s390-low.c (s390_collect_ptrace_register)
11484 (s390_supply_ptrace_register, s390_fill_gregset, s390_get_pc)
11485 (s390_set_pc): Change prototype to take a regcache. Adjust.
11486 (s390_arch_setup): Adjust.
11487 * linux-sh-low.c (sh_get_pc, sh_breakpoint_at)
11488 (sh_fill_gregset): Change prototype to take a regcache. Adjust.
11489 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
11490 (sparc_fill_gregset, sparc_store_gregset_from_stack)
11491 (sparc_store_gregset, sparc_get_pc): Change prototype to take a
11493 (sparc_breakpoint_at): Adjust.
11494 * linux-xtensa-low.c (xtensa_fill_gregset):
11495 (xtensa_store_gregset):
11496 (xtensa_fill_xtregset, xtensa_store_xtregset, xtensa_get_pc)
11497 (xtensa_set_pc): Change prototype to take a regcache. Adjust.
11498 * nto-low.c (nto_fetch_registers, nto_store_registers): Change
11499 prototype to take a regcache. Adjust.
11500 * win32-arm-low.c (arm_fetch_inferior_register)
11501 (arm_store_inferior_register): Change prototype to take a
11503 * win32-i386-low.c (i386_fetch_inferior_register)
11504 (i386_store_inferior_register): Change prototype to take a
11506 * win32-low.c (child_fetch_inferior_registers)
11507 (child_store_inferior_registers): Change prototype to take a
11509 (win32_wait): Adjust.
11510 (win32_fetch_inferior_registers): Change prototype to take a
11512 (win32_store_inferior_registers): Adjust.
11513 * win32-low.h (struct win32_target_ops) <fetch_inferior_register,
11514 store_inferior_register>: Change prototype to take a regcache.
11516 2010-01-20 Doug Evans <dje@google.com>
11518 * linux-low.c (linux_create_inferior): Wrap use of __SIGRTMIN in
11520 (linux_wait_for_event1, linux_init_signals): Ditto.
11521 (W_STOPCODE): Provide definition if missing.
11523 2010-01-13 Vladimir Prus <vladimir@codesourcery.com>
11525 * linux-low.c (linux_core_of_thread): New.
11526 (compare_ints, show_process, list_threads): New.
11527 (linux_qxfer_osdata): Report threads and cores.
11528 (linux_target_op): Register linux_core_of_thread.
11529 * remote-utils.c (prepare_resume_reply): Report the core.
11530 (buffer_xml_printf): Support %d specifier.
11531 * server.c (handle_threads_qxfer_proper, handle_threads_qxfer):
11533 (handle_query): Handle qXfer:threads. Announce availability
11535 * target.h (struct target_ops): New field core_of_thread.
11537 2010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
11539 * Makefile.in (clean): Remove new generated files.
11540 (reg-s390.o, reg-s390.c): Remove rules.
11541 (reg-s390x.o, reg-s390x.c): Likewise.
11542 (s390-linux32.o, s390-linux32.c): Add rules.
11543 (s390-linux64.o, s390-linux64.c): Likewise.
11544 (s390x-linux64.o, s390x-linux64.c): Likewise.
11545 * configure.srv (s390*-*-linux*): Update srv_regobj and srv_xmlfiles.
11546 * linux-s390-low.c: Include <elf.h>.
11547 (HWCAP_S390_HIGH_GPRS): Define if undefined.
11548 (init_registers_s390): Remove prototype.
11549 (init_registers_s390x): Likewise.
11550 (init_registers_s390_linux32): Add prototype.
11551 (init_registers_s390_linux64): Likewise.
11552 (init_registers_s390x_linux64): Likewise.
11553 (s390_num_regs_3264): New define.
11554 (s390_regmap_3264): New global variable.
11555 (s390_cannot_fetch_register): Remove obsolete check.
11556 (s390_cannot_store_register): Likewise.
11557 (s390_collect_ptrace_register): Handle upper/lower register halves.
11558 (s390_supply_ptrace_register): Likewise.
11559 (s390_fill_gregset): Update to register number changes.
11560 (s390_get_hwcap): New routine.
11561 (s390_arch_setup): Detect 32-bit process running on 64-bit system.
11562 Install appropriate regmap and register set.
11564 2010-01-01 Joel Brobecker <brobecker@adacore.com>
11566 * server.c (gdbserver_version): Update copyright year to 2010.
11567 * gdbreplay.c (gdbreplay_version): Likewise.
11569 2009-12-28 Doug Evans <dje@google.com>
11571 * linux-low.c: Delete inclusion of ansidecl.h, elf/common.h,
11572 elf/external.h. Include <elf.h> instead but only if necessary.
11574 2009-12-28 Pedro Alves <pedro@codesourcery.com>
11576 * linux-low.c (linux_remove_process): Remove `detaching'
11577 parameter. Don't release/detach from thread_db here.
11578 (linux_kill): Release/detach from thread_db here, ...
11579 (linux_detach): ... and here, before actually detaching.
11580 (linux_wait_1): ... and here, when a process exits.
11581 * thread-db.c (any_thread_of): New.
11582 (thread_db_free): Switch the current inferior to a thread of the
11585 2009-12-21 Doug Evans <dje@google.com>
11587 * linux-x86-low.c: Delete outdated comment about Elf32_Phdr.
11589 * linux-low.c (kill_lwp): Use __NR_tkill instead of SYS_tkill.
11590 Move definition of tkill_failed to ifdef __NR_tkill to avoid gcc
11591 warning ifndef __NR_tkill. Move setting of errno there too.
11592 Delete unnecessary resetting of errno after syscall.
11593 Minor comment changes to match gdb/linux-nat.c:kill_lwp.
11595 * configure.ac: Check for dladdr.
11596 * config.in: Regenerate.
11597 * configure: Regenerate.
11598 * thread-db.c (dladdr_to_soname): Only define ifdef HAVE_DLADDR.
11599 (try_thread_db_load): Update.
11601 * linux-low.c (my_waitpid): Delete unnecessary prototype.
11603 2009-12-18 Doug Evans <dje@google.com>
11605 * event-loop.c: Include unistd.h if it exists.
11607 * linux-low.c (my_waitpid): Move definition away from being in
11608 between linux_tracefork_child/linux_test_for_tracefork.
11610 * gdb_proc_service.h (psaddr_t): Fix type.
11611 * thread-db.c (thread_db_info.td_thr_tls_get_addr_p): Fix
11612 signature to match glibc.
11614 2009-12-16 Doug Evans <dje@google.com>
11616 * linux-low.c (linux_read_memory): Fix argument to read.
11618 2009-11-26 Pedro Alves <pedro@codesourcery.com>
11620 * win32-low.c (get_child_debug_event): On EXIT_THREAD_DEBUG_EVENT
11621 events, don't leave current_inferior pointing at null.
11623 2009-11-26 Pedro Alves <pedro@codesourcery.com>
11625 * win32-low.c (LOG): Delete.
11626 (OUTMSG): Output to stderr.
11627 (OUTMSG2): Conditionalize on `debug_threads' variable, instead of
11628 on compile time LOG macro.
11629 (win32_wait): Fix debug output.
11631 2009-11-26 Pedro Alves <pedro@codesourcery.com>
11633 * win32-low.c (win32_add_one_solib): If the dll name is
11634 "ntdll.dll", prepend the system directory to the dll path.
11636 2009-11-17 Daniel Jacobowitz <dan@codesourcery.com>
11638 * m68k-tdep.c (m68k_gdbarch_init): Reuse previous initialization.
11640 2009-11-17 Nathan Sidwell <nathan@codesourcery.com>
11641 Vladimir Prus <vladimir@codesourcery.com>
11643 * Makefile.in (reg-cf.o, reg-cf.c): New targets.
11644 * configure.ac: Check for __mcoldfire__ and set
11645 gdb_cv_m68k_is_coldfire.
11646 * configure.srv: Use gdb_cv_m68k_is_coldfire to select between
11647 reg-cf.o and reg-m68k.o.
11648 * configure: Regenerated.
11650 2009-11-16 Pedro Alves <pedro@codesourcery.com>
11652 * linux-low.c (linux_remove_process): Add `detaching' parameter.
11653 Pass it to thread_db_free.
11654 (linux_kill, linux_detach, linux_wait_1): Adjust to pass the
11655 proper `detaching' argument to linux_remove_process.
11656 * linux-low.h (thread_db_free): Add `detaching' parameter.
11657 * thread-db.c (thread_db_init): Pass false as `detaching' argument
11659 (thread_db_free): Add `detaching' parameter. Only
11660 call td_ta_clear_event if detaching from process.
11662 2009-11-12 Maxim Kuvyrkov <maxim@codesourcery.com>
11664 * thread-db.c (thread_db_free): Fix typo.
11666 2009-11-11 Paul Pluzhnikov <ppluzhnikov@google.com>
11669 * thread-db.c (thread_db_free): Call td_ta_clear_event.
11671 2009-11-03 Nathan Sidwell <nathan@codesourcery.com>
11673 * configure.ac (i[34567]86-*): Check if we're targetting x86-64
11674 with an i686 compiler.
11675 * configure.srv (i[34567]86-*-linux*): Pull in x86-64 handling if
11677 * configure: Rebuilt.
11679 2009-10-29 Sandra Loosemore <sandra@codesourcery.com>
11683 * server.c (handle_search_memory_1): Correct read_addr initialization
11684 in loop for searching subsequent chunks.
11686 2009-10-29 Paul Pluzhnikov <ppluzhnikov@google.com>
11688 * configure.ac: New --with-libthread-db option.
11689 * thread-db.c: Allow direct dependence on libthread_db.
11690 (thread_db_free): Adjust.
11691 * config.in: Regenerate.
11692 * configure: Likewise.
11694 2009-10-28 Paul Pluzhnikov <ppluzhnikov@google.com>
11697 * thread-db.c (attach_thread): New function.
11698 (maybe_attach_thread): Return success/failure.
11699 (find_new_threads_callback): Adjust.
11700 (thread_db_find_new_threads): Loop until no new threads.
11702 2009-10-13 Pedro Alves <pedro@codesourcery.com>
11704 * proc-service.c (ps_lgetregs): Formatting.
11706 2009-10-08 Paul Pluzhnikov <ppluzhnikov@google.com>
11708 * acinclude.m4: (SRV_CHECK_THREAD_DB, SRV_CHECK_TLS_GET_ADDR): Remove.
11709 * configure.ac: Adjust.
11710 * linux-low.h (struct process_info_private): Move members to struct
11712 (thread_db_free, thread_db_handle_monitor_command): New prototype.
11713 * linux-low.c (linux_remove_process): Adjust.
11714 (linux_wait_for_event_1, linux_look_up_symbols): Likewise.
11715 * server.c (handle_query): Move code ...
11716 (handle_monitor_command): ... here. New function.
11717 * target.h (struct target_ops): New member.
11718 * thread-db.c (struct thread_db): New.
11719 (libthread_db_search_path): New variable.
11720 (thread_db_create_event, thread_db_enable_reporting)
11721 (find_one_thread, maybe_attach_thread, find_new_threads_callback)
11722 (thread_db_find_new_threads, (thread_db_get_tls_address): Adjust.
11723 (try_thread_db_load_1, dladdr_to_soname): New functions.
11724 (try_thread_db_load, thread_db_load_search): New functions.
11725 (thread_db_init): Search for libthread_db.
11726 (thread_db_free): New function.
11727 (thread_db_handle_monitor_command): Likewise.
11728 * config.in: Regenerate.
11729 * configure: Regenerate.
11731 2009-09-27 Ulrich Weigand <uweigand@de.ibm.com>
11733 * spu-low.c (spu_kill): Wait for inferior to terminate.
11734 Call clear_inferiors.
11735 (spu_detach): Call clear_inferiors.
11737 2009-08-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
11739 * aclocal.m4: Regenerate.
11740 * config.in: Likewise.
11741 * configure: Likewise.
11743 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
11745 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Define.
11746 (parse_spufs_run): New function.
11747 (ppc_get_pc, ppc_set_pc): Detect and handle SPU PC.
11748 (ppc_breakpoint_at): Handle SPU breakpoints.
11750 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
11752 * linux-low.c: Include <sys/stat.h> and <sys/vfs.h>.
11753 (SPUFS_MAGIC): Define.
11754 (spu_enumerate_spu_ids): New function.
11755 (linux_qxfer_spu): New function.
11756 (linux_target_ops): Install linux_qxfer_spu.
11758 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
11760 * configure.srv (powerpc*-*-linux*): Add powerpc-cell32l.o
11761 and powerpc-cell64l.o to srv_regobj. Add rs6000/powerpc-cell32l.xml
11762 and rs6000/powerpc-cell64l.xml to srv_xmlfiles.
11763 * Makefile.in (powerpc-cell32l.o, powerpc-cell32l.c): New rules.
11764 (powerpc-cell64l.o, powerpc-cell64l.c): Likewise.
11765 (clean): Handle powerpc-cell32l.c and powerpc-cell64l.c.
11766 * linux-ppc-low.c (PPC_FEATURE_CELL): Define.
11767 (init_registers_powerpc_cell32l): Add prototype.
11768 (init_registers_powerpc_cell64l): Likewise.
11769 (ppc_arch_setup): Detect Cell/B.E. architecture.
11771 2009-07-30 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
11773 * Makefile.in (datarootdir): New variable.
11775 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
11777 * linux-low.c (linux_write_memory): Update debugging output.
11778 * Makefile.in (clean): Add new descriptions.
11779 (arm-with-vfpv2.o, arm-with-vfpv2.c, arm-with-vfpv3.o)
11780 (arm-with-vfpv3.c, arm-with-neon.o, arm-with-neon.c): New rules.
11781 * configure.srv: Add new files for arm*-*-linux*.
11782 * linux-arm-low.c: Add new declarations.
11783 (PTRACE_GETVFPREGS, PTRACE_SETVFPREGS): Define if undefined.
11784 (arm_hwcap, HWCAP_VFP, HWCAP_IWMMXT, HWCAP_NEON, HWCAP_VFPv3)
11785 (HWCAP_VFPv3D16): New.
11786 (arm_fill_wmmxregset, arm_store_wmmxregset): Check HWCAP_IWMMXT
11787 instead of __IWMMXT__.
11788 (arm_fill_vfpregset, arm_store_vfpregset, arm_get_hwcap)
11789 (arm_arch_setup): New.
11790 (target_regsets): Remove #ifdef. Add VFP regset.
11791 (the_low_target): Use arm_arch_setup.
11793 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
11795 * linux-low.c (linux_kill_one_lwp): Adjust kernel workaround to skip
11796 the main thread again.
11798 2009-07-06 Aleksandar Ristovski <aristovski@qnx.com>
11800 Adding Neutrino gdbserver.
11801 * configure: Regenerated.
11802 * configure.ac: Add case for srv_qnx and set LIBS accordingly.
11803 * configure.srv (i[34567]86-*-nto*): New target.
11804 * nto-low.c, nto-low.h, nto-x86-low.c: New files.
11805 * remote-utils.c [__QNX__]: Include sys/iomgr.h
11806 (nto_comctrl) [__QNX__]: New function.
11807 (enable_async_io, disable_async_io) [__QNX__]: Call nto_comctrl.
11809 2009-07-05 Danny Backx <dannybackx@users.sourceforge.net>
11811 * configure.srv (i[34567]86-*-mingw32ce*): Add i386-low.o to
11814 2009-07-04 Danny Backx <dannybackx@users.sourceforge.net>
11815 Pedro Alves <pedro@codesourcery.com>
11817 * win32-i386-low.c (i386_get_thread_context): Handle systems that
11818 don't support CONTEXT_EXTENDED_REGISTERS.
11819 (i386_win32_breakpoint, i386_win32_breakpoint_len): New.
11820 (the_low_target): Install them.
11821 * win32-low.c (get_child_debug_event): Handle WaitForDebugEvent
11822 failing with ERROR_PIPE_NOT_CONNECTED.
11824 2009-06-30 Doug Evans <dje@google.com>
11825 Pierre Muller <muller@ics.u-strasbg.fr>
11827 Add h/w watchpoint support to x86-linux, win32-i386.
11828 * Makefile.in (SFILES): Add i386-low.c
11829 (i386_low_h): Define.
11830 (i386-low.o): Add dependencies.
11831 (linux-x86-low.o): Add i386-low.h dependency.
11832 (win32-i386-low.o): Ditto.
11833 * i386-low.c: New file.
11834 * i386-low.h: New file.
11835 * configure.srv (i[34567]86-*-cygwin*): Add i386-low.o to srv_tgtobj.
11836 (i[34567]86-*-linux*, i[34567]86-*-mingw*, x86_64-*-linux*): Ditto.
11837 * linux-low.c (linux_add_process): Initialize arch_private.
11838 (linux_remove_process): Free arch_private.
11839 (add_lwp): Initialize arch_private.
11840 (delete_lwp): Free arch_private.
11841 (linux_resume_one_lwp): Call the_low_target.prepare_to_resume if
11843 * linux-low.h (process_info_private): New member arch_private.
11844 (lwp_info): New member arch_private.
11845 (linux_target_ops): New members new_process, new_thread,
11847 (ptid_of): New macro.
11848 * linux-x86-low.c: Include stddef.h, i386-low.h.
11849 (arch_process_info): New struct.
11850 (arch_lwp_info): New struct.
11851 (x86_linux_dr_get, x86_linux_dr_set): New functions.
11852 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
11853 (i386_dr_low_get_status): New function.
11854 (x86_insert_point, x86_remove_point): New functions.
11855 (x86_stopped_by_watchpoint): New function.
11856 (x86_stopped_data_address): New function.
11857 (x86_linux_new_process, x86_linux_new_thread): New functions.
11858 (x86_linux_prepare_to_resume): New function.
11859 (the_low_target): Add entries for insert_point, remove_point,
11860 stopped_by_watchpoint, stopped_data_address, new_process, new_thread,
11862 * server.c (debug_hw_points): New global.
11863 (monitor_show_help): Document set debug-hw-points.
11864 (handle_query): Process "set debug-hw-points".
11865 * server.h (debug_hw_points): Declare.
11866 (paddress): Declare.
11867 * utils.c (NUMCELLS, CELLSIZE): New macros.
11868 (get_sell, xsnprintf, paddress): New functions.
11869 * win32-arm-low.c (the_low_target): Add entries for insert_point,
11870 remove_point, stopped_by_watchpoint, stopped_data_address.
11871 * win32-i386-low.c: Include i386-low.h.
11872 (debug_reg_state): Replaces dr.
11873 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
11874 (i386_dr_low_get_status): New function.
11875 (i386_insert_point, i386_remove_point): New functions.
11876 (i386_stopped_by_watchpoint): New function.
11877 (i386_stopped_data_address): New function.
11878 (i386_initial_stuff): Update.
11879 (get_thread_context,set_thread_context,i386_thread_added): Update.
11880 (the_low_target): Add entries for insert_point,
11881 remove_point, stopped_by_watchpoint, stopped_data_address.
11882 * win32-low.c (win32_insert_watchpoint): New function.
11883 (win32_remove_watchpoint): New function.
11884 (win32_stopped_by_watchpoint): New function.
11885 (win32_stopped_data_address): New function.
11886 (win32_target_ops): Add entries for insert_watchpoint,
11887 remove_watchpoint, stopped_by_watchpoint, stopped_data_address.
11888 * win32-low.h (win32_target_ops): New members insert_point,
11889 remove_point, stopped_by_watchpoint, stopped_data_address.
11891 2009-06-25 Pedro Alves <pedro@codesourcery.com>
11893 * server.c (process_serial_event): Re-return unsupported, not
11894 error, if the type isn't recognized. Re-allow supporting only
11895 insert or remove packets. Also call require_running for
11896 breakpoints. Add missing break statement to default case. Tidy.
11897 * target.h (struct target_ops): Rename insert_watchpoint to
11898 insert_point, and remove_watchpoint to remove_point.
11900 * linux-low.h (struct linux_target_ops): Likewise.
11901 * linux-low.c (linux_insert_watchpoint): Rename to ...
11902 (linux_insert_point): ... this. Adjust.
11903 (linux_remove_watchpoint): Rename to ...
11904 (linux_remove_point): ... this. Adjust.
11905 (linux_target_ops): Adjust.
11906 * linux-crisv32-low.c (cris_insert_watchpoint): Rename to ...
11907 (cris_insert_point): ... this.
11908 (cris_remove_watchpoint): Rename to ...
11909 (cris_remove_point): ... this.
11910 (the_low_target): Adjust.
11912 2009-06-24 Pierre Muller <muller@ics.u-strasbg.fr>
11914 * server.c (handle_v_kill): Pass signal_pid to
11915 kill_inferior if multi_process is zero.
11917 2009-06-23 Aleksandar Ristovski <aristovski@qnx.com>
11919 * server.c (process_serial_event): Add support for Z0 and Z1 packet.
11920 * target.h (target_ops): Comment for *_watchpoint to make it clear
11921 the functions can get types '0' and '1'.
11923 2009-06-22 Aleksandar Ristovski <aristovski@qnx.com>
11925 * linux-low.c (usr_fetch_inferior_registers): Remove check for regno 0.
11926 * proc-service.c (ps_lgetregs): Pass -1 to fetch all registers.
11927 * regcache.c (get_regcache): Likewise.
11928 * spu-low.c (spu_fetch_registers): Remove 0 to -1 conversion.
11929 * win32-low.c (child_fetch_inferior_registers): Remove check for
11932 2009-06-19 Aleksandar Ristovski <aristovski@qnx.com>
11933 Pedro Alves <pedro@codesourcery.com>
11935 * target.h (struct target_ops) <supports_multi_process>: New
11937 (target_supports_multi_process): New.
11938 * server.c (handle_query): Even if GDB reports support, only
11939 enable multi-process if the target also supports it. Report
11940 multi-process support only if the target backend supports it.
11941 * linux-low.c (linux_supports_multi_process): New function.
11942 (linux_target_ops): Install it as target_supports_multi_process
11945 2009-05-24 Doug Evans <dje@google.com>
11947 Global renaming of find_thread_pid to find_thread_ptid.
11948 * server.h (find_thread_ptid): Renamed from find_thread_pid.
11949 * inferiors.c (find_thread_ptid): Renamed from find_thread_pid.
11950 All callers updated.
11952 * linux-low.c (handle_extended_wait): Use linux_resume_one_lwp
11953 to resume the newly created thread, don't call ptrace (PTRACE_CONT)
11956 * linux-low.c (get_stop_pc): Print pc if debug_threads.
11957 (check_removed_breakpoint, linux_wait_for_lwp): Ditto.
11958 (linux_resume_one_lwp): Ditto.
11960 2009-05-23 Doug Evans <dje@google.com>
11962 * linux-low.c (linux_resume_one_lwp): Change type of first arg
11963 from struct inferior_list_entry * to struct lwp_info *.
11964 All callers updated.
11966 2009-05-13 Doug Evans <dje@google.com>
11968 * linux-x86-low.c: Don't include assert.h.
11969 (x86_siginfo_fixup): Use fatal, not assert.
11970 (x86_arch_setup): Fix comment.
11972 2009-05-12 Doug Evans <dje@google.com>
11974 Biarch support for i386/amd64 gdbserver.
11975 * Makefile.in (SFILES): Remove linux-i386-low.c, linux-x86-64-low.c.
11976 Add linux-x86-low.c.
11977 (linux-i386-low.o, linux-x86-64-low.o): Delete.
11978 (linux-x86-low.o): Add.
11979 * linux-x86-64-low.c: Delete.
11980 * linux-i386-low.c: Delete.
11981 * linux-x86-low.c: New file.
11982 * configure.srv (i?86-linux srv_tgtobj): Replace linux-i386-low.o with
11984 (x86_64-linux srv_tgtobj): Replace linux-x86-64-low.o with
11986 (x86_64-linux srv_regobj): Add reg-i386-linux.o.
11987 * linux-low.c: Include ansidecl.h, elf/common.h, elf/external.h.
11988 (linux_child_pid_to_exec_file): New function.
11989 (elf_64_header_p, elf_64_file_p): New functions.
11990 (siginfo_fixup): New function.
11991 (linux_xfer_siginfo): New local inf_siginfo. Call siginfo_fixup to
11992 give target a chance to convert layout.
11993 * linux-low.h (linux_target_ops): New member siginfo_fixup.
11994 (linux_child_pid_to_exec_file, elf_64_file_p): Declare.
11996 2009-05-07 Doug Evans <dje@google.com>
11998 * linux-low.c (regsets_fetch_inferior_registers): Fix memory leak.
11999 (regsets_store_inferior_registers): Ditto.
12001 2009-05-06 Pedro Alves <pedro@codesourcery.com>
12005 * linux-low.c (must_set_ptrace_flags): Delete.
12006 (linux_create_inferior): Set `lwp->must_set_ptrace_flags' instead
12008 (linux_attach_lwp_1): Don't set PTRACE_SETOPTIONS here. Set
12009 `lwp->must_set_ptrace_flags' instead.
12010 (linux_wait_for_event_1): Set ptrace options here.
12011 (linux_wait_1): ... not here.
12013 2009-04-30 Doug Evans <dje@google.com>
12015 * inferiors.c (started_inferior_callback): New function.
12016 (attached_inferior_callback): New function.
12017 (have_started_inferiors_p, have_attached_inferiors_p): New functions.
12018 * server.c (print_started_pid, print_attached_pid): New functions.
12019 (detach_or_kill_for_exit): New function.
12020 (main): Call it instead of for_each_inferior (kill_inferior_callback).
12021 * server.h (have_started_inferiors_p): Declare.
12022 (have_attached_inferiors_p): Declare.
12024 * inferiors.c (remove_process): Fix memory leak, free process.
12025 * linux-low.c (linux_remove_process): New function.
12026 (linux_kill): Call it instead of remove_process.
12027 (linux_detach, linux_wait_1): Ditto.
12029 2009-04-19 Danny Backx <dannybackx@users.sourceforge.net>
12031 * configure.srv: Add x86 Windows CE target.
12033 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
12035 * inferiors.c (get_thread_process): Make global.
12036 * server.h (get_thread_process): Add prototype.
12037 * thread-db.c (find_one_thread): Use get_thread_process
12038 instead of current_process.
12039 (thread_db_get_tls_address): Do not crash if called when
12040 thread layer is not yet initialized.
12042 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
12044 * remote-utils.c (prepare_resume_reply): Null-terminate packet.
12045 * spu-low.c (current_tid): Rename to ...
12046 (current_ptid): ... this.
12047 (fetch_ppc_register, fetch_ppc_memory, store_ppc_memory,
12048 spu_proc_xfer_spu, spu_resume, spu_request_interrupt): Use
12049 ptid_get_lwp (current_ptid) instead of current_tid.
12050 (spu_kill, spu_detach, spu_join, spu_wait): Use pid argument
12051 instead of current_tid. Use find_process_pid to verify pid
12052 argument is valid. Pass proper argument to remove_process.
12053 (spu_thread_alive): Compare current_ptid instead of current_tid.
12054 (spu_resume): Likewise.
12056 2009-04-02 Pedro Alves <pedro@codesourcery.com>
12058 * linux-low.c (usr_store_inferior_registers): Declare local `pid'
12061 2009-04-01 Pedro Alves <pedro@codesourcery.com>
12063 Implement the multiprocess extensions, and add linux multiprocess
12066 * server.h (ULONGEST): Declare.
12067 (struct ptid, ptid_t): New.
12068 (minus_one_ptid, null_ptid): Declare.
12069 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
12070 (ptid_get_tid, ptid_equal, ptid_is_pid): Declare.
12071 (struct inferior_list_entry): Change `id' type from unsigned from
12073 (struct sym_cache, struct breakpoint, struct
12074 process_info_private): Forward declare.
12075 (struct process_info): Declare.
12076 (current_process): Declare.
12077 (all_processes): Declare.
12078 (initialize_inferiors): Declare.
12079 (add_thread): Adjust to use ptid_t.
12080 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): Ditto.
12081 (add_process, remove_process, find_thread_pid): Declare.
12082 (find_inferior_id): Adjust to use ptid_t.
12083 (cont_thread, general_thread, step_thread): Change type to ptid_t.
12084 (multi_process): Declare.
12085 (push_event): Adjust to use ptid_t.
12086 (read_ptid, write_ptid): Declare.
12087 (prepare_resume_reply): Adjust to use ptid_t.
12088 (clear_symbol_cache): Declare.
12089 * inferiors.c (all_processes): New.
12090 (null_ptid, minus_one_ptid): New.
12091 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
12092 (ptid_get_tid, ptid_equal, ptid_is_pid): New.
12093 (add_thread): Change unsigned long to ptid. Remove gdb_id
12095 (thread_id_to_gdb_id, thread_to_gdb_id): Change unsigned long to ptid.
12096 (gdb_id_to_thread): Rename to ...
12097 (find_thread_pid): ... this. Change unsigned long to ptid.
12098 (gdb_id_to_thread_id, find_inferior_id): Change unsigned long to ptid.
12099 (loaded_dll, pull_pid_from_list): Adjust.
12100 (add_process, remove_process, find_process_pid)
12101 (get_thread_process, current_process, initialize_inferiors): New.
12102 * target.h (struct thread_resume) <thread>: Change type to ptid_t.
12103 (struct target_waitstatus) <related_pid>: Ditto.
12104 (struct target_ops) <kill, detach>: Add `pid' argument. Change
12105 return type to int.
12106 (struct target_ops) <join>: Add `pid' argument.
12107 (struct target_ops) <thread_alive>: Change pid's type to ptid_t.
12108 (struct target_ops) <wait>: Add `ptid' field. Change return type
12110 (kill_inferior, detach_inferior, join_inferior): Add `pid' argument.
12111 (mywait): Add `ptid' argument. Change return type to ptid_t.
12112 (target_pid_to_str): Declare.
12113 * target.c (set_desired_inferior): Adjust to use ptids.
12114 (mywait): Add new `ptid' argument. Adjust.
12115 (target_pid_to_str): New.
12116 * mem-break.h (free_all_breakpoints): Declare.
12117 * mem-break.c (breakpoints): Delelete.
12118 (set_breakpoint_at, delete_breakpoint, find_breakpoint_at)
12119 (check_mem_read, check_mem_write, delete_all_breakpoints): Adjust
12120 to use per-process breakpoint list.
12121 (free_all_breakpoints): New.
12122 * remote-utils.c (struct sym_cache) <name>: Drop `const'.
12123 (symbol_cache, all_symbols_looked_up): Delete.
12125 (ishex, unpack_varlen_hex, write_ptid, hex_or_minus_one,
12127 (prepare_resume_reply): Change ptid argument's type from unsigned
12128 long to ptid_t. Adjust. Implement W;process and X;process.
12129 (free_sym_cache, clear_symbol_cache): New.
12130 (look_up_one_symbol): Adjust to per-process symbol cache. *
12131 * server.c (cont_thread, general_thread, step_thread): Change type
12133 (attached): Delete.
12134 (multi_process): New.
12135 (last_ptid): Change type to ptid_t.
12136 (struct vstop_notif) <ptid>: Change type to ptid_t.
12137 (queue_stop_reply, push_event): Change `ptid' argument's type to
12139 (discard_queued_stop_replies): Add `pid' argument.
12140 (start_inferior): Adjust to use ptids. Adjust to mywait interface
12141 changes. Don't reference the `attached' global.
12142 (attach_inferior): Adjust to mywait interface changes.
12143 (handle_query): Adjust to use ptids. Parse GDB's qSupported
12144 features. Handle and report "multiprocess+". Handle
12146 (handle_v_cont): Adjust to use ptids. Adjust to mywait interface
12148 (handle_v_kill): New.
12149 (handle_v_stopped): Adjust to use target_pid_to_str.
12150 (handle_v_requests): Allow multiple attaches and runs when
12151 multiprocess extensions are in effect. Handle "vKill".
12152 (myresume): Adjust to use ptids.
12153 (queue_stop_reply_callback): Add `arg' parameter. Handle it.
12154 (handle_status): Adjust to discard_queued_stop_replies interface
12156 (first_thread_of, kill_inferior_callback)
12157 (detach_or_kill_inferior_callback, join_inferiors_callback): New.
12158 (main): Call initialize_inferiors. Adjust to use ptids, killing
12159 and detaching from all inferiors. Handle multiprocess packet
12161 * linux-low.h: Include gdb_proc_service.h.
12162 (struct process_info_private): New.
12163 (struct linux_target_ops) <pid_of>: Use ptid_get_pid.
12164 <lwpid_of>: Use ptid_get_lwp.
12165 (get_lwp_thread): Adjust.
12166 (struct lwp_info): Add `dead' member.
12167 (find_lwp_pid): Declare.
12168 * linux-low.c (thread_db_active): Delete.
12169 (new_inferior): Adjust comment.
12170 (inferior_pid): Delete.
12171 (linux_add_process): New.
12172 (handle_extended_wait): Adjust.
12173 (add_lwp): Change unsigned long to ptid.
12174 (linux_create_inferior): Add process to processes table. Adjust
12175 to use ptids. Don't set new_inferior here.
12176 (linux_attach_lwp): Rename to ...
12177 (linux_attach_lwp_1): ... this. Add `initial' argument. Handle
12178 it. Adjust to use ptids.
12179 (linux_attach_lwp): New.
12180 (linux_attach): Add process to processes table. Don't set
12182 (struct counter): New.
12183 (second_thread_of_pid_p, last_thread_of_process_p): New.
12184 (linux_kill_one_lwp): Add `args' parameter. Handle it. Adjust to
12185 multiple processes.
12186 (linux_kill): Add `pid' argument. Handle it. Adjust to multiple
12187 processes. Remove process from process table.
12188 (linux_detach_one_lwp): Add `args' parameter. Handle it. Adjust
12189 to multiple processes.
12190 (any_thread_of): New.
12191 (linux_detach): Add `pid' argument, and handle it. Remove process
12192 from processes table.
12193 (linux_join): Add `pid' argument. Handle it.
12194 (linux_thread_alive): Change unsighed long argument to ptid_t.
12195 Consider dead lwps as not being alive.
12196 (status_pending_p): Rename `dummy' argument to `arg'. Filter out
12197 threads we're not interested in.
12198 (same_lwp, find_lwp_pid): New.
12199 (linux_wait_for_lwp): Change `pid' argument's type from int to
12201 (linux_wait_for_event): Rename to ...
12202 (linux_wait_for_event_1): ... this. Change `pid' argument's type
12203 from int to ptid_t. Adjust.
12204 (linux_wait_for_event): New.
12205 (linux_wait_1): Add `ptid' argument. Change return type to
12206 ptid_t. Adjust. Use last_thread_of_process_p. Remove processes
12207 that exit from the process table.
12208 (linux_wait): Add `ptid' argument. Change return type to ptid_t.
12210 (mark_lwp_dead): New.
12211 (wait_for_sigstop): Adjust to use ptids. If a process exits while
12212 stopping all threads, mark its main lwp as dead.
12213 (linux_set_resume_request, linux_resume_one_thread): Adjust to use
12215 (fetch_register, usr_store_inferior_registers)
12216 (regsets_fetch_inferior_registers)
12217 (regsets_store_inferior_registers, linux_read_memory)
12218 (linux_write_memory): Inline `inferior_pid'.
12219 (linux_look_up_symbols): Adjust to use per-process
12220 `thread_db_active'.
12221 (linux_request_interrupt): Adjust to use ptids.
12222 (linux_read_auxv): Inline `inferior_pid'.
12223 (initialize_low): Don't reference thread_db_active.
12224 * gdb_proc_service.h (struct ps_prochandle) <pid>: Remove.
12225 * proc-service.c (ps_lgetregs): Use find_lwp_pid.
12226 (ps_getpid): Return the pid of the current inferior.
12227 * thread-db.c (proc_handle, thread_agent): Delete.
12228 (thread_db_create_event, thread_db_enable_reporting): Adjust to
12230 (find_one_thread): Change argument type to ptid_t. Adjust to
12232 (maybe_attach_thread): Adjust to per-process data and ptids.
12233 (thread_db_find_new_threads): Ditto.
12234 (thread_db_init): Ditto.
12235 * spu-low.c (spu_create_inferior, spu_attach): Add process to
12236 processes table. Adjust to use ptids.
12237 (spu_kill, spu_detach): Adjust interface. Remove process from
12239 (spu_join, spu_thread_alive): Adjust interface.
12240 (spu_wait): Adjust interface. Remove process from processes
12241 table. Adjust to use ptids.
12242 * win32-low.c (current_inferior_tid): Delete.
12243 (current_inferior_ptid): New.
12244 (debug_event_ptid): New.
12245 (thread_rec): Take a ptid. Adjust.
12246 (child_add_thread): Add `pid' argument. Adjust to use ptids.
12247 (child_delete_thread): Ditto.
12248 (do_initial_child_stuff): Add `attached' argument. Add process to
12250 (child_fetch_inferior_registers, child_store_inferior_registers):
12252 (win32_create_inferior): Pass 0 to do_initial_child_stuff.
12253 (win32_attach): Pass 1 to do_initial_child_stuff.
12254 (win32_kill): Adjust interface. Remove process from processes
12256 (win32_detach): Ditto.
12257 (win32_join): Adjust interface.
12258 (win32_thread_alive): Take a ptid.
12259 (win32_resume): Adjust to use ptids.
12260 (get_child_debug_event): Ditto.
12261 (win32_wait): Adjust interface. Remove exiting process from
12264 2009-04-01 Pedro Alves <pedro@codesourcery.com>
12266 Non-stop mode support.
12268 * server.h (non_stop): Declare.
12269 (gdb_client_data, handler_func): Declare.
12270 (delete_file_handler, add_file_handler, start_event_loop):
12272 (handle_serial_event, handle_target_event, push_event)
12273 (putpkt_notif): Declare.
12274 * target.h (enum resume_kind): New.
12275 (struct thread_resume): Replace `step' field by `kind' field.
12276 (TARGET_WNOHANG): Define.
12277 (struct target_ops) <wait>: Add `options' argument.
12278 <supports_non_stop, async, start_non_stop>: New fields.
12279 (target_supports_non_stop, target_async): New.
12280 (start_non_stop): Declare.
12281 (mywait): Add `options' argument.
12282 * target.c (mywait): Add `options' argument. Print child exit
12283 notifications here.
12284 (start_non_stop): New.
12285 * server.c (non_stop, own_buf, mem_buf): New globals.
12286 (struct vstop_notif): New.
12287 (notif_queue): New global.
12288 (queue_stop_reply, push_event, discard_queued_stop_replies)
12289 (send_next_stop_reply): New.
12290 (start_inferior): Adjust to use resume_kind. Adjust to mywait
12292 (attach_inferior): In non-stop mode, don't wait for the target
12294 (handle_general_set): Handle QNonStop.
12295 (handle_query): When handling qC, return the current general
12296 thread, instead of the first thread of the list.
12297 (handle_query): If the backend supports non-stop mode, include
12298 QNonStop+ in the qSupported query response.
12299 (handle_v_cont): Adjust to use resume_kind. Handle resume_stop
12301 (handle_v_attach, handle_v_run): Handle non-stop mode.
12302 (handle_v_stopped): New.
12303 (handle_v_requests): Report support for vCont;t. Handle vStopped.
12304 (myresume): Adjust to use resume_kind. Handle non-stop.
12305 (queue_stop_reply_callback): New.
12306 (handle_status): Handle non-stop mode.
12307 (main): Clear non_stop flag on reconnection. Use the event-loop.
12308 Refactor serial protocol handling from here ...
12309 (process_serial_event): ... to this new function. When GDB
12310 selects any thread, select one here. In non-stop mode, wait until
12311 GDB acks all pending events before exiting.
12312 (handle_serial_event, handle_target_event): New.
12313 * remote-utils.c (remote_open): Install remote_desc in the event
12315 (remote_close): Remove remote_desc from the event loop.
12316 (putpkt_binary): Rename to...
12317 (putpkt_binary_1): ... this. Add `is_notic' argument. Handle it.
12318 (putpkt_binary): New as wrapper around putpkt_binary_1.
12319 (putpkt_notif): New.
12320 (prepare_resume_reply): In non-stop mode, don't change the
12322 * event-loop.c: New.
12323 * Makefile.in (OBJ): Add event-loop.o.
12324 (event-loop.o): New rule.
12326 * linux-low.h (pid_of): Moved here.
12328 (get_lwp_thread): Use lwpid_of.
12329 (struct lwp_info): Delete `lwpid' field. Add `suspended' field.
12330 * linux-low.c (pid_of): Delete.
12331 (inferior_pid): Use lwpid_of.
12332 (linux_event_pipe): New.
12333 (target_is_async_p): New.
12335 (handle_extended_wait): Use lwpid_of.
12336 (add_lwp): Don't set lwpid field.
12337 (linux_attach_lwp): Adjust debug output. Use lwpid_of.
12338 (linux_kill_one_lwp): If killing a running lwp, stop it first.
12339 Use lwpid_of. Adjust to linux_wait_for_event interface changes.
12340 (linux_detach_one_lwp): If detaching from a running lwp, stop it
12341 first. Adjust to linux_wait_for_event interface changes. Use
12343 (linux_detach): Don't delete the main lwp here.
12344 (linux_join): Use my_waitpid. Avoid signal_pid. Use lwpid_of.
12345 (status_pending_p): Don't consider explicitly suspended lwps.
12346 (linux_wait_for_lwp): Take an integer pid instead of a lwp_info
12347 pointer. Add OPTIONS argument. Change return type to int. Use
12348 my_waitpid instead of sleeping. Handle WNOHANG. Use lwpid_of.
12349 (linux_wait_for_event): Take an integer pid instead of a lwp_info
12350 pointer. Add status pointer argument. Return a pid instead of a
12351 status. Use lwpid_of. Adjust to linux_wait_for_lwp interface
12352 changes. In non-stop mode, don't switch to a random thread.
12353 (linux_wait): Rename to...
12354 (linux_wait_1): ... this. Add target_options argument, and handle
12355 it. Adjust to use resume_kind. Use lwpid_of. In non-stop mode,
12356 don't handle the continue thread. Handle TARGET_WNOHANG. Merge
12357 clean exit and signal exit code. Don't stop all threads in
12358 non-stop mode. In all-stop mode, only stop all threads when
12359 reporting a stop to GDB. Handle explicit thread stop requests.
12360 (async_file_flush, async_file_mark): New.
12362 (send_sigstop): Use lwpid_of.
12363 (wait_for_sigstop): Use lwpid_of. Adjust to linux_wait_for_event
12364 interface changes. In non-stop mode, don't switch to a random
12366 (linux_resume_one_lwp): Use lwpid_of.
12367 (linux_continue_one_thread, linux_queue_one_thread): Merge into ...
12368 (linux_resume_one_thread): ... this. Handle resume_stop. In
12369 non-stop mode, don't look for pending flag in all threads.
12370 (resume_status_pending_p): Don't consider explicitly suspended
12372 (my_waitpid): Reimplement. Emulate __WALL.
12373 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
12375 (sigchld_handler, linux_supports_non_stop, linux_async)
12376 (linux_start_non_stop): New.
12377 (linux_target_ops): Register linux_supports_non_stop, linux_async
12378 and linux_start_non_stop.
12379 (initialize_low): Install SIGCHLD handler.
12380 * thread-db.c (thread_db_create_event, find_one_thread)
12381 (thread_db_get_tls_address): Use lwpid_of.
12382 * win32-low.c (win32_detach): Adjust to use resume_kind.
12383 (win32_wait): Add `options' argument.
12384 * spu-low.c (spu_resume): Adjust to use resume_kind.
12385 (spu_wait): Add `options' argument.
12387 2009-04-01 Pedro Alves <pedro@codesourcery.com>
12389 Decouple target code from remote protocol.
12391 * target.h (enum target_waitkind): New.
12392 (struct target_waitstatus): New.
12393 (struct target_ops) <wait>: Return an unsigned long. Take a
12394 target_waitstatus pointer instead of a char pointer.
12395 (mywait): Likewise.
12396 * target.c (mywait): Change prototype to return an unsigned long.
12397 Take a target_waitstatus pointer instead of a char pointer. Adjust.
12398 * server.h (thread_from_wait, old_thread_from_wait): Delete
12400 (prepare_resume_reply): Change prototype to take a
12402 * server.c (thread_from_wait, old_thread_from_wait): Delete.
12403 (last_status, last_ptid): New.
12404 (start_inferior): Remove "statusptr" argument. Adjust. Return a
12405 pid instead of a signal.
12406 (attach_inferior): Remove "status" and "signal" parameters.
12408 (handle_query): For qGetTLSAddr, parse the thread id with strtol,
12410 (handle_v_cont, handle_v_attach, handle_v_run, handle_v_kill)
12411 (handle_v_requests, myresume): Remove "status" and "signal"
12412 parameters. Adjust.
12413 (handle_status): New.
12414 (main): Delete local `status'. Adjust.
12415 * remote-utils.c: Include target.h.
12416 (prepare_resume_reply): Change prototype to take a
12417 target_waitstatus. Adjust.
12419 * linux-low.c (linux_wait): Adjust to new target_ops->wait
12421 * spu-low.c (spu_wait): Adjust.
12422 * win32-low.c (enum target_waitkind, struct target_waitstatus):
12424 (win32_wait): Adjust.
12426 2009-04-01 Pedro Alves <pedro@codesourcery.com>
12428 * target.h (struct thread_resume): Delete leave_stopped member.
12429 (struct target_ops): Add a `n' argument to the `resume' callback.
12430 * server.c (start_inferior): Adjust.
12431 (handle_v_cont, myresume): Adjust.
12432 * linux-low.c (check_removed_breakpoint): Adjust to resume
12433 interface change, and to removed leave_stopped field.
12434 (resume_ptr): Delete.
12435 (struct thread_resume_array): New.
12436 (linux_set_resume_request): Add new `arg' parameter. Adjust to
12437 resume interface change.
12438 (linux_continue_one_thread, linux_queue_one_thread)
12439 (resume_status_pending_p): Check if the resume field is NULL
12440 instead of checking the leave_stopped member.
12441 (linux_resume): Adjust to the target resume interface change.
12442 * spu-low.c (spu_resume): Adjust to the target resume interface
12444 * win32-low.c (win32_detach, win32_resume): Ditto.
12446 2009-04-01 Pedro Alves <pedro@codesourcery.com>
12448 * linux-low.c (linux_wait_for_event): Don't clear the `stepping'
12450 (wait_for_sigstop): Don't leave a finished single-step SIGTRAP
12452 (linux_continue_one_thread): Only preserve the stepping flag if
12453 there's a pending breakpoint.
12455 2009-03-31 Pedro Alves <pedro@codesourcery.com>
12457 * server.c (main): After the inferior having exited, call
12458 remote_close before exiting gdbserver.
12460 2009-03-25 Thiago Jung Bauermann <bauerman@br.ibm.com>
12462 Fix size of FPSCR in Power 7 processors.
12463 * linux-ppc-low.c (PPC_FEATURE_ARCH_2_05): Remove #define.
12464 (PPC_FEATURE_HAS_DFP): New #define.
12465 (ppc_arch_setup): Check for DFP feature instead of ISA 2.05 to decide on
12468 2009-03-23 Pedro Alves <pedro@codesourcery.com>
12470 * server.c (handle_query) Whitespace and formatting.
12472 2009-03-22 Pedro Alves <pedro@codesourcery.com>
12474 * i387-fp.c, linux-arm-low.c, linux-cris-low.c,
12475 linux-crisv32-low.c, linux-i386-low.c, linux-low.c,
12476 linux-mips-low.c, linux-s390-low.c, linux-sparc-low.c,
12477 linux-x86-64-low.c, linux-xtensa-low.c, proc-service.c,
12478 regcache.c, remote-utils.c, server.c, spu-low.c, target.h,
12479 thread-db.c, win32-low.c, xtensa-xtregs.c, gdbreplay.c,
12480 Makefile.in, configure.ac: Fix whitespace throughout.
12481 * configure: Regenerate.
12483 2009-03-22 Pedro Alves <pedro@codesourcery.com>
12485 * inferiors.c (find_inferior): Make it safe for the callback
12486 function to delete the currently iterated inferior.
12488 2009-03-22 Pedro Alves <pedro@codesourcery.com>
12490 * Makefile.in (linuw_low_h): Move higher.
12491 (thread-db.o): Depend on $(linux_low_h).
12493 2009-03-17 Pedro Alves <pedro@codesourcery.com>
12495 Rename "process" to "lwp" throughout.
12497 * linux-low.c (all_processes): Rename to...
12498 (all_lwps): ... this.
12499 (inferior_pid, handle_extended_wait, get_stop_pc): Adjust.
12500 (add_process): Rename to ...
12501 (add_lwp): ... this. Adjust.
12502 (linux_create_inferior): Adjust.
12503 (linux_attach_lwp): Adjust.
12504 (linux_attach): Adjust.
12505 (linux_kill_one_process): Rename to ...
12506 (linux_kill_one_lwp): ... this. Adjust.
12507 (linux_kill): Adjust.
12508 (linux_detach_one_process): Rename to ...
12509 (linux_detach_one_lwp): ... this. Adjust.
12510 (linux_detach): Adjust.
12511 (check_removed_breakpoint): Adjust.
12512 (status_pending_p): Adjust.
12513 (linux_wait_for_process): Rename to ...
12514 (linux_wait_for_lwp): ... this. Adjust.
12515 (linux_wait_for_event): Adjust.
12516 (send_sigstop): Adjust.
12517 (wait_for_sigstop): Adjust.
12518 (stop_all_processes): Rename to ...
12519 (stop_all_lwps): ... this.
12520 (linux_resume_one_process): Rename to ...
12521 (linux_resume_one_lwp): ... this. Adjust.
12522 (linux_set_resume_request, linux_continue_one_thread)
12523 (linux_queue_one_thread, resume_status_pending_p)
12524 (usr_store_inferior_registers, regsets_store_inferior_registers)
12525 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
12527 * linux-low.h (get_process): Rename to ...
12528 (get_lwp): ... this. Adjust.
12529 (get_thread_process): Rename to ...
12530 (get_thread_lwp): ... this. Adjust.
12531 (get_process_thread): Rename to ...
12532 (get_lwp_thread): ... this. Adjust.
12533 (struct process_info): Rename to ...
12534 (struct lwp_info): ... this.
12535 (all_processes): Rename to ...
12536 (all_lwps): ... this.
12537 * proc-service.c (ps_lgetregs): Adjust.
12538 * thread-db.c (thread_db_create_event, find_one_thread)
12539 (maybe_attach_thread, thread_db_get_tls_address): Adjust.
12541 2009-03-14 Pedro Alves <pedro@codesourcery.com>
12543 * server.c (handle_query): Handle "qAttached".
12545 2009-03-13 Nathan Sidwell <nathan@codesourcery.com>
12547 * Makefile.in, hostio-errno.c, errno.c, xtensa-xtregs.c: Change to
12548 GPLv3, update license URL.
12550 2009-03-01 Doug Evans <dje@google.com>
12552 * Makefile.in (INCLUDE_CFLAGS): Add -I$(srcdir)/../common.
12553 (server_h): Add gdb_signals.h.
12554 (signals.o): Update.
12555 * server.h (target_signal_from_host,target_signal_to_host_p)
12556 (target_signal_to_host,target_signal_to_name): Moved to gdb_signals.h.
12558 2009-02-14 Pierre Muller <muller@ics.u-strasbg.fr>
12560 * remote-utils.c (getpkt): Also generate remote-debug
12561 information if noack_mode is set.
12563 2009-02-06 Pedro Alves <pedro@codesourcery.com>
12565 * server.c (handle_query): Report qXfer:siginfo:read and
12566 qXfer:siginfo:write as supported and handle them.
12567 * target.h (struct target_ops) <qxfer_siginfo>: New field.
12568 * linux-low.c (linux_xfer_siginfo): New.
12569 (linux_target_ops): Set it.
12571 2009-01-26 Pedro Alves <pedro@codesourcery.com>
12573 * server.c (gdbserver_usage): Mention --remote-debug.
12574 (main): Accept '--remote-debug' switch.
12576 2009-01-18 Doug Evans <dje@google.com>
12578 * regcache.c (new_register_cache): No need to check result of xcalloc.
12579 * server.c (handle_search_memory): Back out calls to xmalloc,
12580 result is checked and error is returned to user upon failure.
12581 (handle_query): Ditto. Add more checks for result of malloc.
12582 (handle_v_cont): Check result of malloc, report error back to
12584 (handle_v_run): Ditto. Call freeargv.
12585 * server.h (freeargv): Declare.
12586 * utils.c (freeargv): New fn.
12588 2009-01-15 Doug Evans <dje@google.com>
12590 * gdbreplay.c (perror_with_name): Make arg const char *.
12591 * server.h (target_signal_to_name): Make return type const char *.
12592 * thread-db.c (thread_db_err_str): Make return type const char *.
12593 * utils.c (perror_with_name): Make arg const char *.
12595 2009-01-14 Pedro Alves <pedro@codesourcery.com>
12597 * win32-low.c (get_child_debug_event): Issue a final DBG_CONTINUE
12598 when handling a EXIT_PROCESS_DEBUG_EVENT.
12600 2009-01-06 Joel Brobecker <brobecker@adacore.com>
12602 * gdbreplay.c (gdbreplay_version): Update copyright year.
12603 * server.c (gdbserver_version): Likewise.
12605 2009-01-05 Doug Evans <dje@google.com>
12607 * linux-low.c (linux_attach_lwp): Add some comments/fixmes.
12608 (handle_extended_wait): Improve comment.
12610 2008-12-13 Doug Evans <dje@google.com>
12612 * utils.c (xmalloc,xcalloc,xstrdup): New fns.
12613 * server.h (ATTR_MALLOC): New macro.
12614 (xmalloc,xcalloc,xstrdup): Declare.
12615 * hostio.c: Replace malloc,calloc,strdup with xmalloc,xcalloc,xstrdup.
12616 * inferiors.c: Ditto.
12617 * linux-low.c: Ditto.
12618 * mem-break.c: Ditto.
12619 * regcache.c: Ditto.
12620 * remote-utils.c: Ditto.
12623 * win32-low.c: Ditto.
12625 2008-12-12 Doug Evans <dje@google.com>
12627 * linux-low.c (linux_wait_for_process): Don't clobber current_inferior
12628 in debugging printf.
12630 * linux-low.c (handle_extended_wait): Simplify, use my_waitpid.
12632 2008-12-09 Doug Evans <dje@google.com>
12634 * linux-low.h (struct process_info): Delete member tid, unused.
12635 * thread-db.c (find_one_thread): Update.
12636 (maybe_attach_thread): Update.
12638 2008-12-02 Pedro Alves <pedro@codesourcery.com>
12640 * target.h (struct target_ops): Add qxfer_osdata member.
12641 * linux-low.c: Include ctype.h and pwd.h and sys/types.h
12643 (linux_qxfer_osdata): New functions.
12644 (linux_target_ops): Register linux_qxfer_osdata as qxfer_osdata
12646 * server.c (handle_query): Handle "qXfer:osdata:read:".
12647 * remote-utils.c (buffer_grow, buffer_free, buffer_init, buffer_finish)
12648 (buffer_xml_printf): New functions.
12649 * server.h (struct buffer): New.
12650 (buffer_grow_str, buffer_grow_str0): New macros.
12651 (buffer_grow, buffer_free, buffer_init, buffer_finish)
12652 (buffer_xml_printf): Declare.
12654 2008-11-24 Doug Evans <dje@google.com>
12656 * Makefile.in (VERSION,DIST,LINT,LINTFLAGS): Delete, unused.
12658 2008-11-24 Daniel Jacobowitz <dan@codesourcery.com>
12660 * server.c (handle_v_run): Always use the supplied argument list.
12662 2008-11-19 Bob Wilson <bob.wilson@acm.org>
12664 * xtensa-xtregs.c (XTENSA_ELF_XTREG_SIZE): Change to 4.
12665 (xtensa_regmap_table): Add entry for scompare1.
12667 2008-11-18 Thiago Jung Bauermann <bauerman@br.ibm.com>
12669 * Makefile.in (powerpc-isa205-32l.o, powerpc-isa205-32l.c,
12670 powerpc-isa205-altivec32l.o, powerpc-isa205-altivec32l.c,
12671 powerpc-isa205-vsx32l.o, powerpc-isa205-vsx32l.c,
12672 powerpc-isa205-64l.o, powerpc-isa205-64l.c,
12673 powerpc-isa205-altivec64l.o, powerpc-isa205-altivec64l.c,
12674 powerpc-isa205-vsx64l.o, powerpc-isa205-vsx64l.c): New targets.
12675 * configure.srv (powerpc*-*-linux*): Add ISA 2.05 object files and
12676 XML target descriptions.
12677 * linux-ppc-low.c (ppc_arch_setup): Init registers with 64-bit FPSCR
12678 when inferior is running on an ISA 2.05 or later processor. Add
12679 special case to return offset for full 64-bit slot of FPSCR when
12682 2008-11-14 Daniel Gutson <dgutson@codesourcery.com>
12684 * Makefile.in (SFILES, clean): Added sparc64 files.
12685 (reg-sparc64.o, reg-sparc64.c): New.
12686 * configure.srv (sparc*-*-linux*): New configuration.
12687 * linux-low.c (regsets_fetch_inferior_registers): Swap ptrace
12688 syscall arguments for SPARC.
12689 (regsets_store_inferior_registers): Likewise.
12690 * linux-sparc-low.c: New file.
12692 2008-10-21 Doug Evans <dje@google.com>
12694 * Makefile.in (BFD_DIR,BFD,BFD_SRC,BFD_CFLAGS): Delete.
12695 (READLINE_DIR,READLINE_DEP): Delete.
12696 (INTERNAL_CFLAGS): Update.
12697 (LINTFLAGS): Update.
12699 2008-10-10 Pedro Alves <pedro@codesourcery.com>
12701 * server.c (handle_v_run): If GDB didn't specify an argv, use the
12702 whole argv from the last run, not just argv[0].
12704 2008-09-08 Pedro Alves <pedro@codesourcery.com>
12706 * regcache.c (new_register_cache): Return NULL if the register
12707 cache size isn't known yet.
12708 (free_register_cache): Avoid dereferencing a NULL regcache.
12710 2008-09-04 Daniel Jacobowitz <dan@codesourcery.com>
12712 * configure.srv: Merge MIPS and MIPS64.
12714 2008-08-24 Maciej W. Rozycki <macro@linux-mips.org>
12716 * Makefile.in (uninstall): Apply $(EXEEXT) too.
12718 2008-08-18 Luis Machado <luisgpm@br.ibm.com>
12720 * Makefile.in: Add required vsx dependencies.
12722 * linux-ppc-low: Define PPC_FEATURE_HAS_VSX.
12723 Declare init_registers_powerpc_vsx32l.
12724 Declare init_registers_powerpc_vsx64l.
12725 Define PTRACE_GETVSXREGS and PTRACE_SETVSXREGS.
12726 (ppc_arch_setup): Check for VSX in hwcap.
12727 (ppc_fill_vsxregset): New function.
12728 (ppc_store_vsxregset): New function.
12729 Add new VSX entry in regset_info target_regsets.
12731 * configure.srv: Add new VSX dependencies.
12733 2008-08-12 Pedro Alves <pedro@codesourcery.com>
12735 * remote-utils.c (noack_mode, transport_is_reliable): New globals.
12736 (remote_open): Set or clear transport_is_reliable.
12737 (putpkt_binary): Don't expect acks in noack mode.
12738 (getpkt): Don't send ack/nac in noack mode.
12739 * server.c (handle_general_set): Handle QStartNoAckMode.
12740 (handle_query): If connected by tcp pass QStartNoAckMode+ in
12742 (main): Reset noack_mode on every connection.
12743 * server.h (noack_mode): Declare.
12745 2008-08-07 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
12747 * Makefile.in (GDBREPLAY_OBS): New variable.
12748 (gdbreplay$(EXEEXT)): Use it to avoid unportable $^.
12750 2008-08-05 Ulrich Weigand <uweigand@de.ibm.com>
12751 Daniel Jacobowitz <dan@codesourcery.com>
12753 * linux-low.c (linux_resume_one_process): Ignore ESRCH.
12754 (usr_store_inferior_registers): Likewise.
12755 (regsets_store_inferior_registers): Likewise.
12757 2008-07-31 Rolf Jansen <rj@surtec.com>
12758 Pedro Alves <pedro@codesourcery.com>
12760 * configure.ac: Check for memmem declaration.
12761 * server.c [HAVE_MALLOC_H]: Include malloc.h.
12762 (disable_packet_vCont, disable_packet_Tthread, disable_packet_qC)
12763 (disable_packet_qfThreadInfo): Unconditionally compile.
12764 * server.h [!HAVE_DECL_MEMMEM]: Declare memmem.
12765 * configure, config.in: Regenerate.
12767 2008-07-28 Doug Kwan <dougkwan@google.com>
12769 * linux-low.c (sys/dir.h, sys/user.h): Remove includes.
12770 (linux_write_memory): Remove declaration of errno.
12772 2008-07-12 Ulrich Weigand <uweigand@de.ibm.com>
12774 * linux-low.c (handle_extended_wait): Do not use "status"
12775 variable uninitialized.
12777 2008-07-07 Pedro Alves <pedro@codesourcery.com>
12779 * server.c (handle_v_attach): Inhibit reporting dll changes.
12781 2008-06-27 Pedro Alves <pedro@codesourcery.com>
12783 * remote-utils.c (prepare_resume_reply): If requested, don't
12784 output "thread:TID" in the T stop reply.
12786 * server.c (disable_packet_vCont, disable_packet_Tthread)
12787 (disable_packet_qC, disable_packet_qfThreadInfo): New globals.
12788 (handle_query): If requested, disable support for qC, qfThreadInfo
12790 (handle_v_requests): If requested, disable support for vCont.
12791 (gdbserver_show_disableable): New.
12792 (main): Handle --disable-packet and --disable-packet=LIST.
12794 * server.h (disable_packet_vCont, disable_packet_Tthread)
12795 (disable_packet_qC, disable_packet_qfThreadInfo): Declare.
12797 2008-06-20 Carlos O'Donell <carlos@codesourcery.com>
12799 * server.c (gdbserver_usage): Mention --version.
12801 2008-06-06 Daniel Jacobowitz <dan@codesourcery.com>
12803 * Makefile.in (gdbreplay.o): New rule.
12805 2008-06-06 Joseph Myers <joseph@codesourcery.com>
12807 * gdbreplay.c (gdbreplay_version): Say gdbreplay in version
12808 message, not gdbserver.
12810 2008-06-05 Vladimir Prus <vladimir@codesourcery.com>
12811 Nathan Sidwell <nathan@codesourcery.com>
12812 Joseph Myers <joseph@codesourcery.com>
12814 * acinclude.m4: Include ../../config/acx.m4.
12815 * configure.ac: Use ACX_PKGVERSION and ACX_BUGURL.
12816 * configure, config.in: Regenerate.
12817 * Makefile.in (gdbreplay$(EXEEXT)): Add version.o.
12818 * server.c (gdbserver_version): Print PKGVERSION.
12819 (gdbsrever_usage): Add stream parameter. Print REPORT_BUGS_TO.
12820 (main): Adjust gdbserver_usage calls.
12821 * gdbreplay.c (version, host_name): Add declarations.
12822 (gdbreplay_version, gdbreplay_usage): New.
12823 (main): Accept --version and --help options.
12825 2008-06-04 Daniel Jacobowitz <dan@codesourcery.com>
12827 * linux-arm-low.c (thumb_breakpoint, thumb_breakpoint_len): New.
12828 (arm_breakpoint_at): Handle Thumb.
12829 (the_low_target): Add comment.
12831 2008-05-29 Ulrich Weigand <uweigand@de.ibm.com>
12833 * linux-ppc-low.c (ppc_collect_ptrace_register): Clear buffer.
12835 2008-05-09 Doug Evans <dje@google.com>
12837 * server.h (decode_search_memory_packet): Declare.
12838 * remote-utils.c (decode_search_memory_packet): New fn.
12839 * server.c (handle_search_memory_1): New fn.
12840 (handle_search_memory): New fn.
12841 (handle_query): Process qSearch:memory packets.
12843 2008-05-08 Ulrich Weigand <uweigand@de.ibm.com>
12845 * regcache.c (registers_length): Remove.
12846 (set_register_cache): Verify that PBUFSIZ is large enough to hold a
12847 full register packet.
12848 * regcache.h (registers_length): Remove prototype.
12849 * server.h (PBUFSIZ): Define to 16384.
12851 2008-05-03 Ulrich Weigand <uweigand@de.ibm.com>
12853 * configure.srv (powerpc*-*-linux*): Set srv_regobj to
12854 powerpc-32l.o, powerpc-altivec32l.o, powerpc-e500l.o,
12855 powerpc-64l.o, and powerpc-altivec64l.o.
12856 Remove rs6000/powerpc-32.xml, rs6000/powerpc-64.xml, and
12857 rs6000/powerpc-e500.xml; add rs6000/powerpc-32l.xml,
12858 rs6000/powerpc-altivec32l.xml, rs6000/powerpc-e500l.xml,
12859 rs6000/powerpc-64l.xml, rs6000/powerpc-altivec64l.xml,
12860 rs6000/power-linux.xml, and rs6000/power64-linux.xml
12863 * Makefile.in (reg-ppc.o, reg-ppc.c): Remove, replace by ...
12864 (powerpc-32l.o, powerpc-32l.c): ... these new rules.
12865 (powerpc-32.o, powerpc-32.c): Remove, replace by ...
12866 (powerpc-altivec32l.o, powerpc-altivec32l.c): ... these new rules.
12867 (powerpc-e500.o, powerpc-e500.c): Remove, replace by ...
12868 (powerpc-e500l.o, powerpc-e500l.c): ... these new rules.
12869 (reg-ppc64.o, reg-ppc64.c): Remove, replace by ...
12870 (powerpc-64l.o, powerpc-64l.c): ... these new rules.
12871 (powerpc-64.o, powerpc-64.c): Remove, replace by ...
12872 (powerpc-altivec64l.o, powerpc-altivec64l.c): ... these new rules.
12875 * linux-ppc-low.c (init_registers_ppc): Remove, replace by ...
12876 (init_registers_powerpc_32l): ... this new prototype.
12877 (init_registers_powerpc_32): Remove, replace by ...
12878 (init_registers_powerpc_altivec32l): ... this new prototype.
12879 (init_registers_powerpc_e500): Remove, replace by ...
12880 (init_registers_powerpc_e500l): ... this new prototype.
12881 (init_registers_ppc64): Remove, replace by ...
12882 (init_registers_powerpc_64l): ... this new prototype.
12883 (init_registers_powerpc_64): Remove, replace by ...
12884 (init_registers_powerpc_altivec64l): ... this new prototype.
12885 (ppc_num_regs): Set to 73.
12886 (PT_ORIG_R3, PT_TRAP): Define if necessary.
12887 (ppc_regmap, ppc_regmap_e500): Add values for orig_r3 and trap.
12888 (ppc_cannot_store_register): Handle orig_r3 and trap.
12889 (ppc_arch_setup): Update init_registers_... calls.
12890 (ppc_fill_gregset): Handle orig_r3 and trap.
12892 * inferiors.c (clear_inferiors): Reset current_inferior.
12894 2008-04-23 Paolo Bonzini <bonzini@gnu.org>
12896 * acinclude.m4: Add override.m4.
12897 * configure: Regenerate.
12899 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
12901 * linux-ppc-low.c (ppc_arch_setup): Reset ppc_hwcap after the
12902 initial call to init_register_ppc64.
12904 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
12906 * configure.srv (powerpc64-*-linux*, powerpc-*-linux*): Merge into
12907 single powerpc*-*-linux* case.
12908 (s390-*-linux*, s390x-*-linux*): Merge into single s390*-*-linux* case.
12910 2008-04-17 Ulrich Weigand <uweigand@de.ibm.com>
12912 * configure.srv [powerpc64-*-linux*]: Remove powerpc-e500.o from
12913 srv_regobj. Remove rs6000/powerpc-e500.xml and rs6000/power-spe.xml
12915 * linux-ppc-low.c: Include <elf.h>.
12916 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Define.
12917 (ppc_hwcap): New global variable.
12918 (ppc_regmap): Remove __SPE__ #ifdef sections.
12919 (ppc_regmap_e500): New global variable.
12920 (ppc_cannot_store_register): Update __SPE__ special case.
12921 (ppc_get_hwcap): New function.
12922 (ppc_arch_setup): Use it to determine whether inferior supports
12923 AltiVec or SPE registers. Set the_low_target.regmap if appropriate.
12924 (ppc_fill_vrregset, ppc_store_vrregset): Define unconditionally.
12925 Do not access registers if target does not support AltiVec.
12926 (ppc_fill_evrregset, ppc_store_evrregset): Define unconditionally.
12927 Do not access registers if target does not support SPE.
12928 (target_regsets): Unconditionally include AltiVec and SPE regsets.
12930 2008-04-17 Daniel Jacobowitz <dan@codesourcery.com>
12932 * linux-low.c (disabled_regsets, num_regsets): New.
12933 (use_regsets_p): Delete.
12934 (linux_wait_for_process): Clear disabled_regsets.
12935 (regsets_fetch_inferior_registers): Check and set it.
12936 (regsets_store_inferior_registers): Likewise.
12937 (linux_fetch_registers, linux_store_registers): Do not use
12939 (initialize_low): Allocate disabled_regsets.
12941 2008-04-14 Daniel Jacobowitz <dan@codesourcery.com>
12943 * Makefile.in (LIBOBJS): New.
12944 (OBS): Use LIBOBJS.
12945 (memmem.o): New rule.
12946 * configure.ac: Use AC_CONFIG_LIBOBJ_DIR and check for memmem.
12947 * configure: Regenerated.
12949 2008-04-04 Ulrich Weigand <uweigand@de.ibm.com>
12951 * server.c (handle_query): Never return "unsupported" for
12952 qXfer:features:read queries.
12954 2008-03-27 Ulrich Weigand <uweigand@de.ibm.com>
12956 * server.c (get_features_xml): Fix inverted condition.
12957 (handle_query): Always support qXfer:feature:read.
12959 2008-03-10 Daniel Jacobowitz <dan@codesourcery.com>
12961 * server.c (wrapper_argv): New.
12962 (start_inferior): Handle wrapper_argv. If set, expect an extra
12964 (gdbserver_usage): Document --wrapper.
12965 (main): Parse --wrapper.
12967 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
12969 * configure.srv [powerpc64-*-linux*]: Add all files mentioned for
12970 powerpc-*-linux* to srv_regobj and reg_xmlfiles.
12971 * linux-ppc-low.c (ppc_get_pc): Support bi-arch operation.
12972 (ppc_set_pc): Likewise.
12973 (ppc_arch_setup): New function.
12974 (ppc_fill_gregset): Call ppc_collect_ptrace_register instead
12975 of collect_register.
12976 (the_low_target): Use ppc_arch_setup as arch_setup initializer.
12978 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
12980 * configure.srv [powerpc64-*-linux*]: Use linux-ppc-low.o
12981 instead of linux-ppc64-low.o.
12982 * linux-ppc64-low.c: Remove file.
12983 * Makefile.in (SFILES): Remove linux-ppc64-low.c.
12984 (linux-ppc64-low.o): Remove rule.
12986 * linux-ppc-low.c (init_registers_ppc64): Add prototype.
12987 (init_registers_powerpc_64): Likewise.
12988 (ppc_regmap): Conditionally define depending on __powerpc64__.
12989 (ppc_cannot_store_register): Do not special-case "fpscr" when
12990 compiled on __powerpc64__.
12991 (ppc_collect_ptrace_register): New function.
12992 (ppc_supply_ptrace_register): New function.
12993 (ppc_breakpoint): Change type to "unsigned int".
12994 (ppc_breakpoint_at): Change type of "insn" to "unsigned int".
12995 (the_low_target): Conditionally provide initializers for the
12996 arch_setup member depending on __powerpc64__. Install
12997 collect_ptrace_register and supply_ptrace_register members.
12999 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
13001 * regcache.h (gdbserver_xmltarget): Add extern declaration.
13002 * server.c (gdbserver_xmltarget): Define.
13003 (get_features_xml): Use it to replace "target.xml" and arch_string.
13005 * configure.srv: Remove srv_xmltarget. Add XML files that were
13006 mentioned there to srv_xmlfiles instead. Remove conditional tests
13007 on gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe; set
13008 srv_xmlfiles and srv_regobj to include all possible choices.
13009 * configure.ac (srv_xmltarget): Remove.
13010 (srv_xmlfiles): Do not add "target.xml".
13011 (gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe): Remove
13012 checks for supplementary target information.
13013 * configure: Regenerate.
13014 * Makefile.in (XML_TARGET): Remove.
13015 (target.xml): Remove rule.
13016 (clean): Do not clean up target.xml.
13017 (.PRECIOUS): Do not mention target.xml.
13019 * target.h (struct target_ops): Remove arch_string member.
13020 * linux-low.c (linux_arch_string): Remove.
13021 (linux_target_ops): Remove arch_string initializer.
13022 * linux-low.h (struct linux_target_ops): Remove arch_string member.
13023 * linux-i386-low.c (the_low_target): Remove arch_string initializer.
13024 * linux-x86-64-low.c (the_low_target): Remove arch_string initializer.
13025 * spu-low.c (spu_arch_string): Remove.
13026 (spu_target_ops): Remove arch_string initializer.
13027 * win32-low.c (win32_arch_string): Remove.
13028 (win32_target_ops): Remove arch_string initializer.
13029 * win32-low.h (struct win32_target_ops): Remove arch_string member.
13030 * win32-arm-low.c (the_low_target): Remove arch_string initializer.
13031 * win32-i368-low.c (the_low_target): Remove arch_string initializer.
13033 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
13035 * linux-low.h (struct linux_target_ops): Replace left_pad_xfer field
13036 by collect_ptrace_register and supply_ptrace_register hooks.
13037 * linux-low.c (fetch_register): Use supply_ptrace_register callback
13038 instead of checking for the_low_target.left_pad_xfer.
13039 (usr_store_inferior_registers): Use collect_ptrace_register callback
13040 instead of checking for the_low_target.left_pad_xfer.
13042 * linux-s390-low.c (s390_collect_ptrace_register): New function.
13043 (s390_supply_ptrace_register): Likewise.
13044 (s390_fill_gregset): Call s390_collect_ptrace_register.
13045 (the_low_target): Update.
13047 * linux-ppc64-low.c (ppc_collect_ptrace_register): New function.
13048 (ppc_supply_ptrace_register): Likewise.
13049 (the_low_target): Update.
13051 * linux-i386-low.c (the_low_target): Update.
13052 * linux-x86-64-low.c (the_low_target): Update.
13054 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
13056 * configure.srv [s390x-*-linux*]: Set srv_regobj to include both
13057 reg-s390.o and reg-s390x.o.
13059 * linux-low.c (new_inferior): New global variable.
13060 (linux_create_inferior, linux_attach): Set it.
13061 (linux_wait_for_process): Call the_low_target.arch_setup after the
13062 target has stopped for the first time.
13063 (initialize_low): Do not call the_low_target.arch_setup.
13065 * linux-s390-low.c (s390_get_pc): Support bi-arch operation.
13066 (s390_set_pc): Likewise.
13067 (s390_arch_setup): New function.
13068 (the_low_target): Use s390_arch_setup as arch_setup routine.
13070 * regcache.c (realloc_register_cache): New function.
13071 (set_register_cache): Call it for each existing regcache.
13073 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
13075 * server.h (init_registers): Remove prototype.
13077 * linux-low.h (struct linux_target_ops): Add arch_setup field.
13078 * linux-low.c (initialize_low): Call the_low_target.arch_setup ()
13079 instead of init_registers ().
13080 * linux-arm-low.c (init_registers_arm): Add prototype.
13081 (init_registers_arm_with_iwmmxt): Likewise.
13082 (the_low_target): Add initializer for arch_setup field.
13083 * linux-cris-low.c (init_registers_cris): Add prototype.
13084 (the_low_target): Add initializer for arch_setup field.
13085 * linux-crisv32-low.c (init_registers_crisv32): Add prototype.
13086 (the_low_target): Add initializer for arch_setup field.
13087 * linux-i386-low.c (init_registers_i386_linux): Add prototype.
13088 (the_low_target): Add initializer for arch_setup field.
13089 * linux-ia64-low.c (init_registers_ia64): Add prototype.
13090 (the_low_target): Add initializer for arch_setup field.
13091 * linux-m32r-low.c (init_registers_m32r): Add prototype.
13092 (the_low_target): Add initializer for arch_setup field.
13093 * linux-m68k-low.c (init_registers_m68k): Add prototype.
13094 (the_low_target): Add initializer for arch_setup field.
13095 * linux-mips-low.c (init_registers_mips_linux): Add prototype.
13096 (init_registers_mips64_linux): Likewise.
13097 (the_low_target): Add initializer for arch_setup field.
13098 * linux-ppc-low.c (init_registers_ppc): Add prototype.
13099 (init_registers_powerpc_32, init_registers_powerpc_e500): Likewise.
13100 (the_low_target): Add initializer for arch_setup field.
13101 * linux-ppc64-low.c (init_registers_ppc64): Add prototype.
13102 (init_registers_powerpc_64): Likewise.
13103 (the_low_target): Add initializer for arch_setup field.
13104 * linux-s390-low.c (init_registers_s390): Add prototype.
13105 (init_registers_s390x): Likewise.
13106 (the_low_target): Add initializer for arch_setup field.
13107 * linux-sh-low.c (init_registers_sh): Add prototype.
13108 (the_low_target): Add initializer for arch_setup field.
13109 * linux-x86-64-low.c (init_registers_x86_64_linux): Add prototype.
13110 (the_low_target): Add initializer for arch_setup field.
13111 * linux-xtensa-low.c (init_registers_xtensa): Add prototype.
13112 (the_low_target): Add initializer for arch_setup field.
13114 * win32-low.h (struct win32_target_ops): Add arch_setup field.
13115 * win32-low.c (initialize_low): Call the_low_target.arch_setup ()
13116 instead of init_registers ().
13117 * win32-arm-low.c (init_registers_arm): Add prototype.
13118 (the_low_target): Add initializer for arch_setup field.
13119 * win32-i386-low.c (init_registers_i386): Add prototype.
13120 (the_low_target): Add initializer for arch_setup field.
13122 * spu-low.c (init_registers_spu): Add prototype.
13123 (initialize_low): Call initialie_registers_spu () instead of
13124 initialize_registers ().
13126 2008-02-19 Pedro Alves <pedro@codesourcery.com>
13128 * server.c (handle_v_requests): When handling the vRun and vAttach
13129 packets, if already debugging a process, don't kill it. Return an
13132 2008-02-17 Daniel Jacobowitz <dan@codesourcery.com>
13134 * server.c (handle_query): Correct length check.
13136 2008-02-14 Pedro Alves <pedro_alves@portugalmail.pt>
13138 * win32-low.c (do_initial_child_stuff): Add process handle
13139 parameter. Set current_process_handle and current_process_id from the
13140 parameters. Clear globals.
13141 (win32_create_inferior): Don't set current_process_handle and
13142 current_process_id here. Instead pass them on the call to
13143 do_initial_child_stuff.
13144 (win32_attach): Likewise.
13145 (win32_clear_inferiors): New.
13146 (win32_kill): Don't close the current process handle or the
13147 current thread handle here. Instead call win32_clear_inferiors.
13148 (win32_detach): Don't open a new handle to the process. Call
13149 win32_clear_inferiors.
13150 (win32_join): Don't rely on current_process_handle; open a new
13151 handle using the process id.
13152 (win32_wait): Call win32_clear_inferiors when the inferior process
13155 2008-02-14 Daniel Jacobowitz <dan@codesourcery.com>
13157 * server.c (monitor_show_help): Add "exit".
13159 2008-02-11 Maxim Grigoriev <maxim2405@gmail.com>
13161 * Makefile.in (SFILES): Add linux-xtensa-low.c.
13162 (clean): Add reg-xtensa.c.
13163 (linux-xtensa-low.o, reg-xtensa.o, reg-xtensa.c): New dependencies.
13164 * configure.srv (xtensa*-*-linux*) New target.
13165 * linux-xtensa-low.c: New.
13166 * xtensa-xtregs.c: New.
13168 2008-02-01 Pedro Alves <pedro_alves@portugalmail.pt>
13170 * hostio.c: Don't include errno.h.
13171 (errno_to_fileio_errno): Move to hostio-errno.
13172 * hostio.c: (hostio_error): Remove the error parameter. Defer the
13173 error number outputting to the target->hostio_last_error callback.
13174 (hostio_packet_error): Use FILEIO_EINVAL directly.
13175 (handle_open, handle_pread, hostio_error, handle_unlink): Update
13176 calls to hostio_error.
13177 * hostio-errno.c: New.
13178 * server.h (hostio_last_error_from_errno): Declare.
13179 * target.h (target_ops): Add hostio_last_error member.
13180 * linux-low.c (linux_target_op): Register hostio_last_error_from_errno
13181 as hostio_last_error handler.
13182 * spu-low.c (spu_target_ops): Likewise.
13183 * win32-low.c [_WIN32_WCE] (win32_error_to_fileio_error)
13184 (wince_hostio_last_error): New functions.
13185 (win32_target_ops) [_WIN32_WCE]: Register wince_hostio_last_error
13186 as hostio_last_error handler.
13187 (win32_target_ops) [!_WIN32_WCE]: Register
13188 hostio_last_error_from_errno as hostio_last_error handler.
13189 * Makefile.in (SFILES): Add hostio.c and hostio-errno.c.
13190 (hostio-errno.o): New rule.
13191 * configure.ac (GDBSERVER_DEPFILES): Add $srv_hostio_err_objs.
13192 * configure.srv (srv_hostio_err_objs): New variable. Default to
13194 (arm*-*-mingw32ce*): Set srv_hostio_err_objs to "".
13195 * configure: Regenerate.
13197 2008-01-29 Daniel Jacobowitz <dan@codesourcery.com>
13199 * linux-low.c (linux_attach_lwp): Do not _exit after errors.
13200 (linux_kill, linux_detach): Clean up the process list.
13201 * remote-utils.c (remote_open): Improve port number parsing.
13202 (putpkt_binary, input_interrupt): Only send interrupts if the target
13204 * server.c (extended_protocol): Make static.
13205 (attached): Define earlier.
13206 (exit_requested, response_needed, program_argv): New variables.
13207 (target_running): New.
13208 (start_inferior): Clear attached here.
13209 (attach_inferior): Set attached here.
13210 (require_running): Define.
13211 (handle_query): Use require_running and target_running. Implement
13213 (handle_v_attach, handle_v_run): New.
13214 (handle_v_requests): Use require_running. Handle vAttach and vRun.
13215 (gdbserver_usage): Update.
13216 (main): Redo argument parsing. Handle --debug and --multi. Handle
13217 --attach along with other options or after the port. Save
13218 program_argv. Support no initial program. Resynchronize
13219 communication with GDB after an error. Handle "monitor exit".
13220 Use require_running and target_running. Always allow the extended
13221 protocol. Do not error out for Hc0 or Hc-1. Do not automatically
13222 restart in extended mode.
13223 * README: Refer to the GDB manual. Update --attach usage.
13225 2007-12-20 Andreas Schwab <schwab@suse.de>
13227 * linux-low.c (STACK_SIZE): Define.
13228 (linux_tracefork_child): Use it. Use __clone2 on ia64.
13229 (linux_test_for_tracefork): Likewise.
13231 2007-12-18 Daniel Jacobowitz <dan@codesourcery.com>
13233 * linux-low.c (linux_wait_for_event): Update messages. Do not
13234 reinsert auto-delete breakpoints.
13235 * mem-break.c (struct breakpoint): Change return type of handler to
13237 (set_breakpoint_at): Update handler type.
13238 (reinsert_breakpoint_handler): Return 1 instead of calling
13240 (reinsert_breakpoint_by_bp): Check for the original breakpoint before
13242 (check_breakpoints): Delete auto-delete breakpoints and return 2.
13243 * mem-break.h (set_breakpoint_at): Update handler type.
13244 * thread-db.c (thread_db_create_event, thread_db_create_event): Update.
13245 * win32-low.c (auto_delete_breakpoint): New.
13246 (get_child_debug_event): Use it.
13248 2007-12-16 Daniel Jacobowitz <dan@codesourcery.com>
13250 * configure.ac: Check for pread and pwrite.
13251 * hostio.c (handle_pread): Fall back to lseek and read.
13252 (handle_pwrite): Fall back to lseek and write.
13253 * config.in, configure: Regenerated.
13255 2007-12-07 Daniel Jacobowitz <dan@codesourcery.com>
13257 * server.c (myresume): Add own_buf argument.
13258 (main): Update calls.
13260 2007-12-06 Daniel Jacobowitz <dan@codesourcery.com>
13262 * linux-low.c (linux_wait, linux_resume): Do not handle async I/O.
13263 * remote-utils.c (remote_open): Do not call disable_async_io.
13264 (block_async_io): Delete.
13265 (unblock_async_io): Make static.
13266 (initialize_async_io): New.
13267 * server.c (handle_v_cont): Handle async I/O here.
13268 (myresume): Likewise. Move other common resume tasks here...
13269 (main): ... from here. Call initialize_async_io. Disable async
13270 I/O before the main loop.
13271 * server.h (initialize_async_io): Declare.
13272 (block_async_io, unblock_async_io): Delete prototypes.
13273 * spu-low.c (spu_resume, spu_wait): Do not handle async I/O here.
13275 2007-12-06 Mick Davis <mickd@goanna.iinet.net.au>
13277 * remote-utils.c (readchar): Allow binary data in received messages.
13279 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
13281 * win32-low.c (attaching): New global.
13282 (win32_create_inferior): Clear the `attaching' global.
13283 (win32_attach): Set the `attaching' global.
13284 (get_child_debug_event) [_WIN32_WCE]: Stop the inferior when
13285 attaching. Only set a breakpoint at the entry point if not
13288 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
13290 * server.c (main): Don't report dll events on the initial
13291 connection on attaches.
13293 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
13295 * server.c (main): Relax numerical bases supported for the pid of
13296 the --attach command line argument.
13298 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
13300 * win32-low.c (win32_attach): Call OpenProcess before
13301 DebugActiveProcess, not after. Add last error output to error
13304 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
13306 * win32-low.c (win32_get_thread_context)
13307 (win32_set_thread_context): New functions.
13308 (thread_rec): Use win32_get_thread_context.
13309 (continue_one_thread, win32_resume): Use win32_set_thread_context.
13310 * win32-low.h (win32_thread_info) [_WIN32_WCE]: Add `base_context'
13313 2007-12-03 Leo Zayas
13314 Pedro Alves <pedro_alves@portugalmail.pt>
13316 * win32-low.c (soft_interrupt_requested, faked_breakpoint): New
13318 (child_add_thread): Minor cleanup.
13319 (child_continue): Resume artificially suspended threads before
13320 calling ContinueDebugEvent.
13321 (suspend_one_thread): New.
13322 (fake_breakpoint_event): New.
13323 (get_child_debug_event): Change return type to int. Check here if
13324 gdb sent an interrupt request. If a soft interrupt was requested,
13325 fake a breakpoint event. Return 0 if there is no event to handle,
13327 (win32_wait): Don't check here if gdb sent an interrupt request.
13328 Ensure there is a valid event to handle.
13329 (win32_request_interrupt): Add soft interruption method as last
13332 2007-12-03 Leo Zayas
13333 Pedro Alves <pedro_alves@portugalmail.pt>
13335 * win32-low.h (win32_thread_info): Add descriptions to the
13336 structure members. Replace `suspend_count' counter by a
13338 * win32-low.c (thread_rec): Update condition of when to get the
13339 context from the inferior. Rely on ContextFlags being set if it
13340 has already been retrieved. Only suspend the inferior thread if
13341 we haven't already. Warn if that fails.
13342 (continue_one_thread): s/suspend_count/suspended/. Only call
13343 ResumeThread once. Warn if that fails.
13345 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
13347 * win32-low.c (win32_wait): Don't read from the inferior when it
13348 has already exited.
13350 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
13352 * Makefile.in (win32_low_h): New variable.
13353 (win32-low.o): Add dependency on $(win32_low_h).
13354 (win32-arm-low.o, win32-i386-low.o): New rules.
13356 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
13358 * hostio.c: Correct copyright year.
13360 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
13362 * Makefile.in (OBS): Add hostio.o.
13363 (hostio.o): New rule.
13364 * server.h (handle_vFile): Declare.
13365 * hostio.c: New file.
13366 * server.c (handle_v_requests): Take packet_len and new_packet_len
13367 for binary packets. Call handle_vFile.
13368 (main): Update call to handle_v_requests.
13370 2007-11-05 Daniel Jacobowitz <dan@codesourcery.com>
13372 * linux-low.c: Include <sched.h>.
13374 2007-11-01 Daniel Jacobowitz <dan@codesourcery.com>
13376 * linux-low.c (linux_tracefork_grandchild): New.
13377 (linux_tracefork_child): Use clone.
13378 (linux_test_for_tracefork): Use clone; allocate and free a stack.
13380 2007-10-31 Joel Brobecker <brobecker@adacore.com>
13382 * Makefile.in: Use $(SHELL) instead of "sh" to call regdat.sh.
13384 2007-10-24 Daniel Jacobowitz <dan@codesourcery.com>
13386 * linux-low.c (handle_extended_wait): Handle unexpected signals.
13388 2007-10-23 Daniel Jacobowitz <dan@codesourcery.com>
13390 * inferiors.c (change_inferior_id): Delete.
13391 (add_pid_to_list, pull_pid_from_list): New.
13392 * linux-low.c (PTRACE_SETOPTIONS, PTRACE_GETEVENTMSG)
13393 (PTRACE_O_TRACESYSGOOD, PTRACE_O_TRACEFORK, PTRACE_O_TRACEVFORK)
13394 (PTRACE_O_TRACECLONE, PTRACE_O_TRACEEXEC, PTRACE_O_TRACEVFORKDONE)
13395 (PTRACE_O_TRACEEXIT, PTRACE_EVENT_FORK, PTRACE_EVENT_VFORK)
13396 (PTRACE_EVENT_CLONE, PTRACE_EVENT_EXEC, PTRACE_EVENT_VFORK_DONE)
13397 (PTRACE_EVENT_EXIT, __WALL): Provide default definitions.
13398 (stopped_pids, thread_db_active, must_set_ptrace_flags): New variables.
13399 (using_threads): Always set to 1.
13400 (handle_extended_wait): New.
13401 (add_process): Do not set TID.
13402 (linux_create_inferior): Set must_set_ptrace_flags.
13403 (linux_attach_lwp): Remove TID argument. Do not check using_threads.
13404 Use PTRACE_SETOPTIONS. Call new_thread_notify. Update all callers.
13405 (linux_thread_alive): Rename TID argument to LWPID.
13406 (linux_wait_for_process): Handle unknown processes. Do not use TID.
13407 (linux_wait_for_event): Do not use TID or check using_threads. Update
13408 call to dead_thread_notify. Call handle_extended_wait.
13409 (linux_create_inferior): Use PTRACE_SETOPTIONS.
13410 (send_sigstop): Delete sigstop_sent.
13411 (wait_for_sigstop): Avoid TID.
13412 (linux_supports_tracefork_flag, linux_tracefork_child, my_waitpid)
13413 (linux_test_for_tracefork): New.
13414 (linux_lookup_signals): Use thread_db_active and
13415 linux_supports_tracefork_flag.
13416 (initialize_low): Use thread_db_active and linux_test_for_tracefork.
13417 * linux-low.h (get_process_thread): Avoid TID.
13418 (struct process_ifo): Move thread_known and tid to the end. Remove
13420 (linux_attach_lwp, thread_db_init): Update prototypes.
13421 * server.h (change_inferior_id): Delete prototype.
13422 (add_pid_to_list, pull_pid_from_list): New prototypes.
13423 * thread-db.c (thread_db_use_events): New.
13424 (find_first_thread): Rename to...
13425 (find_one_thread): ...this. Update callers and messages. Do not
13426 call fatal. Check thread_db_use_events. Do not call
13427 change_inferior_id or new_thread_notify.
13428 (maybe_attach_thread): Update. Do not call new_thread_notify.
13429 (thread_db_init): Set thread_db_use_events. Check use_events.
13430 * utils.c (fatal, warning): Correct message prefix.
13432 2007-10-15 Daniel Jacobowitz <dan@codesourcery.com>
13434 * Makefile.in (clean): Remove new files.
13435 (powerpc-32.o, powerpc-32.c, powerpc-e500.o, powerpc-e500.c)
13436 (powerpc-64.o, powerpc-64.c): New rules.
13437 * configure.srv: Use alternate register sets for powerpc64-*-linux*
13438 with AltiVec, powerpc-*-linux* with AltiVec, and powerpc-*-linux*
13440 * linux-ppc-low.c (ppc_regmap): Do not fetch the FP registers for
13442 (ppc_cannot_store_register): Do not check for FPSCR for SPE targets.
13443 (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS, ppc_fill_vrregset)
13444 (ppc_store_vrregset, PTRACE_GETEVRREGS, PTRACE_SETEVRREGS)
13445 (struct gdb_evrregset_t, ppc_fill_evrregset, ppc_store_evrregset): New.
13446 (target_regsets): Add AltiVec and SPE register sets.
13447 * configure.ac: Check for AltiVec and SPE.
13448 * linux-ppc64-low.c (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS)
13449 (ppc_fill_vrregset, ppc_store_vrregset): New.
13450 (target_regsets): Add AltiVec register set.
13451 * configure: Regenerated.
13453 2007-09-19 Daniel Jacobowitz <dan@codesourcery.com>
13455 * linux-low.c (O_LARGEFILE): Define.
13456 (linux_read_memory): Use /proc/PID/mem.
13457 * configure.ac: Use AC_GNU_SOURCE. Check for pread64.
13458 * configure, config.in: Regenerated.
13460 2007-09-04 Daniel Jacobowitz <dan@codesourcery.com>
13462 * linux-low.c (linux_wait_for_event): Do not pass signals while
13465 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
13467 * win32-low.c (create_process): New.
13468 (win32_create_inferior): Use create_process instead of
13469 CreateProcess. If create_process failed retry appending an ".exe"
13470 suffix. Store the GetLastError result immediatelly after
13471 create_process calls and use it on the call to error.
13473 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
13475 * win32-low.c (handle_load_dll): Don't use toolhelp when waiting.
13477 2007-08-23 Joel Brobecker <brobecker@adacore.com>
13479 * configure.ac: Switch license to GPLv3.
13481 2007-08-01 Michael Snyder <msnyder@access-company.com>
13483 * remote-utils.c (putpkt_binary): Memory leak, free buf2.
13485 2007-07-31 Pedro Alves <pedro_alves@portugalmail.pt>
13487 * win32-low.c (winapi_CloseToolhelp32Snapshot) [_WIN32_WCE]: New
13489 (win32_CloseToolhelp32Snapshot) [_WIN32_WCE]: New global var.
13490 (load_toolhelp) [_WIN32_WCE]: Load TOOLHELP.DLL. Get
13491 CloseToolhelp32Snapshot.
13492 (toolhelp_get_dll_name) [_WIN32_WCE]: Close the snapshot with
13493 CloseToolhelp32Snapshot.
13495 2007-07-27 Michael Snyder <michael.snyder@access-company.com>
13497 * server.c (main): Check for inferior exit before main loop.
13499 2007-07-18 Pedro Alves <pedro_alves@portugalmail.pt>
13501 * remote-utils.c (remote_open): Set SO_KEEPALIVE on remote_desc
13502 instead of on tmp_desc.
13504 2007-07-17 Pedro Alves <pedro_alves@portugalmail.pt>
13505 Daniel Jacobowitz <dan@codesourcery.com>
13507 * inferiors.c (all_dlls, dlls_changed, get_dll): New.
13508 (add_thread): Minor cleanups.
13509 (clear_inferiors): Move lower in the file. Clear the DLL
13511 (free_one_dll, match_dll, loaded_dll, unloaded_dll, clear_list): New.
13512 * remote-utils.c (prepare_resume_reply): Check dlls_changed.
13513 (xml_escape_text): New.
13514 * server.c (handle_query): Handle qXfer:libraries:read. Report it
13516 (handle_v_cont): Report errors.
13517 (gdbserver_version): Update.
13518 (main): Correct size of own_buf. Do not report initial DLL events.
13519 * server.h (struct dll_info, all_dlls, dlls_changed, loaded_dll)
13520 (unloaded_dll, xml_escape_text): New.
13521 * win32-low.c (enum target_waitkind): Update comments.
13522 (win32_add_one_solib, get_image_name, winapi_EnumProcessModules)
13523 (winapi_GetModuleInformation, winapi_GetModuleFileNameExA)
13524 (win32_EnumProcessModules, win32_GetModuleInformation)
13525 (win32_GetModuleFileNameExA, load_psapi, psapi_get_dll_name)
13526 (winapi_CreateToolhelp32Snapshot, winapi_Module32First)
13527 (winapi_Module32Next, win32_CreateToolhelp32Snapshot)
13528 (win32_Module32First, win32_Module32Next, load_toolhelp)
13529 (toolhelp_get_dll_name, handle_load_dll, handle_unload_dll): New.
13530 (get_child_debug_event): Handle DLL events.
13531 (win32_wait): Likewise.
13533 2007-07-12 Daniel Jacobowitz <dan@codesourcery.com>
13535 * configure.srv: Set srv_linux_regsets for sh*-*-linux*.
13536 * linux-sh-low.c (sh_fill_gregset, target_regsets): New.
13538 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
13540 * win32-low.c (handle_output_debug_string): Ignore event if not
13543 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
13545 * win32-arm-low.c (arm_wince_breakpoint): Fix typo.
13547 2007-07-03 Daniel Jacobowitz <dan@codesourcery.com>
13549 * remote-utils.c (look_up_one_symbol): Handle 'm' packets.
13551 2007-07-02 Daniel Jacobowitz <dan@codesourcery.com>
13553 * inferiors.c (change_inferior_id): Add comment.
13554 * linux-low.c (check_removed_breakpoint): Add an early
13555 prototype. Improve debug output.
13556 (linux_attach): Doc update.
13557 (linux_detach_one_process, linux_detach): Clean up before releasing
13559 (send_sigstop, wait_for_sigstop): Improve comments and debug output.
13560 * linux-low.h (struct process_info): Doc improvement.
13561 * mem-break.c (delete_all_breakpoints): New.
13562 * mem-break.h (delete_all_breakpoints): New prototype.
13563 * thread-db.c (find_first_thread): New.
13564 (thread_db_create_event): Call it instead of
13565 thread_db_find_new_threads. Clean up unused variables.
13566 (maybe_attach_thread): Remove first thread handling.
13567 (thread_db_find_new_threads): Use find_first_thread.
13568 (thread_db_get_tls_address): Likewise.
13570 2007-06-27 Daniel Jacobowitz <dan@codesourcery.com>
13572 * thread-db.c (thread_db_find_new_threads): Add prototype.
13573 (thread_db_create_event): Check for the main thread before adding
13575 (maybe_attach_thread): Only enable event reporting if TID == 0.
13576 (thread_db_get_tls_address): Check for new threads.
13578 2007-06-20 Daniel Jacobowitz <dan@codesourcery.com>
13580 * linux-low.c (linux_create_inferior): Try execv before execvp.
13581 * spu-low.c (spu_create_inferior): Likewise.
13583 2007-06-13 Mike Frysinger <vapier@gentoo.org>
13585 * linux-low.c (linux_create_inferior): Change execv to execvp.
13586 * spu-low.c (spu_create_inferior): Likewies.
13588 2007-06-13 Daniel Jacobowitz <dan@codesourcery.com>
13590 * Makefile.in (clean): Clean new files instead of deleted ones.
13591 (reg-mips.o, reg-mips.c, reg-mips64.o, reg-mips64.c): Delete.
13592 (mips-linux.o, mips-linux.c, mips64-linux.o, mips64-linux.c): New
13594 * configure.srv: Specify XML files and new regformats for MIPS and
13596 * linux-mips-low.c (mips_num_regs): Set to only used registers.
13597 (mips_regmap): Do not fetch $0. Remove unused registers. Add
13598 an entry for the restart register.
13599 (mips_cannot_fetch_register, mips_cannot_store_register)
13600 (mips_reinsert_addr, mips_fill_fpregset, mips_store_fpregset): Update
13601 register names to match the XML descriptions.
13602 (mips_fill_gregset, mips_store_gregset): Likewise. Handle the
13603 restart register instead of $0.
13605 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
13606 Markus Deuling <deuling@de.ibm.com>
13608 * remote-utils.c (decode_xfer_write): New function.
13609 * server.h (decode_xfer_write): Add prototype.
13610 * server.c (handle_query): Add PACKET_LEN argument. Support
13611 qXfer:spu:read and qXfer:spu:write packets.
13612 (main): Pass packet_len to handle_query.
13613 * spu-low.c (spu_target_ops): Add spu_proc_xfer_spu.
13614 * target.h (target_ops): Add qxfer_spu.
13616 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
13618 * spu-low.c (spu_proc_xfer_spu): Do not return failure when
13619 accessing non-seekable spufs files.
13621 2007-05-16 Markus Deuling <deuling@de.ibm.com>
13623 * server.c (handle_query): Add reply for qC packet.
13625 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
13626 Leo Zayas <lerele@champenstudios@com>
13628 * server.h (check_remote_input_interrupt_request): New function.
13629 * remote_utils.c (INVALID_DESCRIPTOR): New define.
13630 (remote_desc): Initialize with INVALID_DESCRIPTOR.
13631 (input_interrupt): Expose on USE_WIN32API too. Fix whitespace.
13632 (check_remote_input_interrupt_request): New function.
13633 * server.h (check_remote_input_interrupt_request): Declare.
13634 * win32-low.c (winapi_DebugBreakProcess,
13635 winapi_GenerateConsoleCtrlEvent): New typedefs.
13636 (get_child_debug_event): Lower Win32 debug event polling from 1 sec
13638 (win32_wait): Check for remote interrupt request
13639 with check_remote_input_interrupt_request.
13640 (win32_request_interrupt): New function.
13641 (win32_target_op): Set request_interrupt to win32_request_interrupt.
13643 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
13645 * win32-low.c (debug_registers_changed,
13646 debug_registers_used, CONTEXT_EXTENDED_REGISTERS,
13647 CONTEXT_FLOATING_POINT, CONTEXT_DEBUG_REGISTERS,
13648 CONTEXT_DEBUGGER, CONTEXT_DEBUGGER_DR): Delete.
13649 (thread_rec): Get context using the low target.
13650 (child_add_thread): Call thread_added on the low target,
13651 which does the same thing.
13653 (do_initial_child_stuff): Remove debug registers references.
13654 Set context using the low target. Resume threads after
13655 setting the contexts.
13656 (child_continue): Remove dead variable. Remove debug
13657 registers references.
13658 (child_fetch_inferior_registers): Go through the low target.
13659 (do_child_store_inferior_registers): Remove.
13660 (child_store_inferior_registers): Go through the low target.
13661 (win32_resume): Remove debug registers references.
13662 Set context using the low target.
13663 (handle_exception): Change return type to void. Don't record
13664 context here. Set status to TARGET_WAITKIND_SPURIOUS on a
13665 first chance exception.
13666 (get_child_debug_event): Change return type to void. Remove
13667 goto loop. Always return after waiting for debug event.
13668 (win32_wait): Convert to switch statement. Handle spurious
13671 * win32-i386-low.c (debug_registers_changed,
13672 debug_registers_used): New.
13673 (initial_stuff): Rename to ...
13674 (i386_initial_stuff): ... this. Clear debug registers
13676 (store_debug_registers): Delete.
13677 (i386_get_thread_context): New.
13678 (load_debug_registers): Delete.
13679 (i386_set_thread_context): New.
13680 (i386_thread_added): New.
13681 (single_step): Rename to ...
13682 (i386_single_step): ... this.
13683 (do_fetch_inferior_registers): Rename to ...
13684 (i386_fetch_inferior_register): ... this.
13685 (i386_store_inferior_register): New.
13686 (the_low_target): Adapt to new interface.
13688 * win32-arm-low.c (CONTEXT_FLOATING_POINT): Define.
13689 (arm_get_thread_context): New.
13690 (arm_set_thread_context): New.
13692 (do_fetch_inferior_registers): Rename to ...
13693 (arm_fetch_inferior_register): ... this.
13694 (arm_store_inferior_register): New.
13695 (arm_wince_breakpoint): Reimplement as unsigned long.
13696 (arm_wince_breakpoint_len): Define.
13697 (the_low_target): Adapt to new interface.
13699 * win32-low.h (target_ops): Remove regmap, store_debug_registers and
13700 load_debug_registers. Add get_thread_context, set_thread_context,
13701 thread_added and store_inferior_register. Rename
13702 fetch_inferior_registers to fetch_inferior_register.
13703 (regptr): Remove declaration.
13705 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
13707 * linux-low.c (linux_detach): Change return type to int. Return 0.
13708 * spu-low.c (spu_detach): Likewise.
13710 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
13712 * target.h (target_ops): Change return type of detach to int.
13714 (join_inferior): New.
13715 * server.c (main): Don't skip detach support on mingw32.
13716 If the inferior doesn't support detaching return error.
13717 Call join_inferior instead of using waitpid.
13718 * linux-low.c (linux_join): New.
13719 (linux_target_op): Add linux_join.
13720 * spu-low.c (spu_join): New.
13721 (spu_target_ops): Add spu_join.
13722 * win32-low.c (win32_detach): Adapt to new interface.
13723 Reopen current_process_handle before detaching. Issue a child
13724 resume before detaching.
13726 (win32_target_op): Add win32_join.
13728 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
13730 * win32-low.c (win32-attach): Fix return value.
13731 * target.h (target_ops): Describe ATTACH return values.
13733 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
13735 * win32-low.c (GETPROCADDRESS): Define.
13736 (winapi_DebugActiveProcessStop): Add WINAPI. typedef as pointer.
13737 (winapi_DebugSetProcessKillOnExit): Likewise.
13738 (win32_create_inferior): Force usage of ansi CreateProcessA.
13739 (win32_attach): Use GETPROCADDRESS.
13740 (win32_detach): Likewise.
13742 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
13744 * win32-low.c (win32_wait): Don't use WSTOPSIG.
13746 2007-03-30 Pedro Alves <pedro_alves@portugalmail.pt>
13748 * win32-low.c: Commit leftover changes from 2007-03-29.
13750 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
13752 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Make 16-bit
13753 fields short instead of int. Add explicit padding.
13754 (i387_cache_to_fsave): Remove unnecessary casts.
13755 (i387_fsave_to_cache): Doc fix.
13756 (i387_cache_to_fxsave): Remove unnecessary casts and masking.
13758 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
13760 * i387-fp.c (i387_cache_to_fxsave): Reinitialize val2 before use.
13761 (i387_fxsave_to_cache): Check fp->ftag while building ftag value.
13763 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
13765 * configure.srv (arm*-*-mingw32ce*): Move near the other
13768 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
13770 * configure.ac: Add errno checking.
13771 (AC_CHECK_HEADERS): Add errno.h, fcntl.h, signal.h,
13772 sys/file.h and malloc.h.
13773 (AC_CHECK_DECLS): Add perror.
13774 (srv_mingwce): Handle.
13775 * configure.srv (i[34567]86-*-cygwin*): Add
13776 win32-i386-low.o to srv_tgtobj.
13777 (i[34567]86-*-mingw*): Likewise.
13778 (arm*-*-mingw32ce*): Add case.
13779 * gdbreplay.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
13780 HAVE_FCNTL_H, HAVE_ERRNO_H, HAVE_MALLOC_H]: Check.
13781 [__MINGW32CE__] (strerror): New function.
13782 [__MINGW32CE__] (errno): Define to GetLastError.
13783 [__MINGW32CE__] (COUNTOF): New macro.
13784 (remote_open): Remove extra close call.
13785 * mem-break.c (delete_breakpoint_at): New function.
13786 * mem-break.h (delete_breakpoint_at): Declare.
13787 * remote-utils.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
13788 HAVE_FCNTL_H, HAVE_UNISTD_H, HAVE_ERRNO_H]: Check.
13789 [USE_WIN32API] (read, write): Add char* casts.
13790 * server.c [HAVE_UNISTD_H, HAVE_SIGNAL_H]: Check.
13791 * server.h: Include wincecompat.h on Windows CE.
13792 [HAVE_ERRNO_H]: Check.
13793 (perror): Declare if not declared.
13794 * utils.c: Add stdlib.h, errno.h and malloc.h includes.
13795 (perror_with_name): Remove errno declaration.
13796 * wincecompat.h: New.
13797 * wincecompat.c: New.
13798 * win32-low.h: New.
13799 * win32-arm-low.c: New.
13800 * win32-i386-low.c: New.
13801 (win32-low.c): Include mem-break.h and win32-low.h, and winnt.h.
13802 (OUTMSG2): Make it safe.
13804 (COUNTOF): New macro.
13805 (NUM_REGS): Get it from the low target.
13806 (CONTEXT_EXTENDED_REGISTERS, CONTEXT_FLOATING_POINT,
13807 CONTEXT_DEBUG_REGISTERS): Add fallbacks to 0.
13808 (thread_rec): Let low target handle debug registers.
13809 (child_add_thread): Likewise.
13810 (child_init_thread_list): Likewise.
13811 (continue_one_thread): Likewise.
13813 (do_child_fetch_inferior_registers): Move to ...
13814 * win32-i386-low.c: ... here, and rename to ...
13815 (do_fetch_inferior_registers): ... this.
13816 * win32-low.c (child_fetch_inferior_registers):
13817 Go through the low target.
13818 (do_child_store_inferior_registers): Use regptr.
13819 (strwinerror): New function.
13820 (win32_create_inferior): Handle Windows CE.
13821 Use strwinerror instead of strerror on Windows error
13822 codes. Add program to the error output.
13823 Don't close the main thread handle on Windows CE.
13824 (win32_attach): Use coredll.dll on Windows CE.
13825 (win32_kill): Close current process and current
13827 (win32_detach): Use coredll.dll on Windows CE.
13828 (win32_resume): Let low target handle debug registers, and
13830 (handle_exception): Add/Remove initial breakpoint. Avoid
13831 non-existant WSTOPSIG on Windows CE.
13832 (win32_read_inferior_memory): Cast to remove warning.
13833 (win32_arch_string): Go through the low target.
13834 (initialize_low): Call set_breakpoint_data with the low
13835 target's breakpoint.
13836 * win32-low.c (dr, FLAG_TRACE_BIT, FCS_REGNUM,
13837 FOP_REGNUM, mappings): Move to ...
13838 * win32-i386-low.c: ... here.
13839 * win32-low.c (win32_thread_info): Move to ...
13840 * win32-low.h: ... here.
13841 * Makefile.in (SFILES): Add win32-low.c, win32-i386-low.c,
13842 win32-arm-low.c and wincecompat.c.
13843 (all:): Add $EXEEXT.
13844 (install-only:): Likewise.
13845 (gdbserver:): Likewise.
13846 (gdbreplay:): Likewise.
13847 * config.in: Regenerate.
13848 * configure: Regenerate.
13850 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
13852 * win32-low.c: Rename typedef thread_info to
13853 win32_thread_info throughout.
13855 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
13857 * win32-i386-low.c: Rename to ...
13858 * win32-low.c: ... this.
13859 * configure.srv: Replace win32-i386-low.o with win32-low.o.
13860 * Makefile.in: Likewise.
13862 2007-03-27 Pedro Alves <pedro_alves@portugalmail.pt>
13864 * remote-utils.c (monitor_output): Constify msg parameter.
13865 * server.h (monitor_output): Likewise.
13866 * win32-i386-low.c (handle_output_debug_string): New.
13867 (win32_kill): Handle OUTPUT_DEBUG_STRING_EVENT events using
13868 handle_output_debug_string.
13869 (get_child_debug_event): Likewise.
13871 2007-03-27 Mat Hostetter <mat@lcs.mit.edu>
13873 * server.c (main): Correct strtoul check.
13875 2007-03-27 Jon Ringle <jon@ringle.org>
13877 * linux-low.c: Check __ARCH_HAS_MMU__ also.
13879 2007-03-27 Brooks Moses <brooks.moses@codesourcery.com>
13881 * Makefile.in: Add dummy "pdf" and "install-pdf" targets.
13883 2007-02-27 Daniel Jacobowitz <dan@codesourcery.com>
13885 * terminal.h: Check HAVE_SGTTY_H.
13887 2007-02-27 Mat Hostetter <mat@lcs.mit.edu>
13889 * remote-utils.c (remote_open): Print out the assigned port number.
13891 2007-02-26 Daniel Jacobowitz <dan@codesourcery.com>
13893 * remote-utils.c (monitor_output): New function.
13894 * server.c (debug_threads): Define here.
13895 (monitor_show_help): New function.
13896 (handle_query): Handle qRcmd.
13897 (main): Do not handle 'd' packet.
13898 * server.h (debug_threads, remote_debug, monitor_output): Declare.
13899 * linux-low.c, spu-low.c, win32-i386-low.c: Remove definitions
13902 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
13904 * Makefile.in (EXEEXT): New.
13905 (clean): Use $(EXEEXT).
13907 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
13909 * target.h (target_ops): Rename send_signal to request_interrupt,
13910 and remove enum target_signal parameter.
13911 * linux-low.c (linux_request_interrupt): Rename from
13912 linux_send_signal, and always send SIGINT.
13913 * spu-low.c (spu_request_interrupt): Rename from spu_send_signal,
13914 and always send SIGINT.
13915 * remote-utils.c (putpkt_binary): Call request_interrupt, instead
13917 (input_interrupt): Likewise.
13919 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
13921 * server.c (get_features_xml): Check if target implemented
13923 * win32-i386-low.c (win32_arch_string): New.
13924 (win32_target_ops): Add win32_arch_string as arch_string member.
13926 2007-02-22 Markus Deuling <deuling@de.ibm.com>
13928 * spu-low.c (spu_arch_string): New.
13929 (spu_target_ops): Add spu_arch_string.
13931 2007-02-16 Daniel Jacobowitz <dan@codesourcery.com>
13933 * remote-utils.c: Remove HAVE_TERMINAL_H check.
13934 * configure.ac: Do not check for terminal.h.
13935 * configure, config.in: Regenerated.
13937 2007-02-08 Daniel Jacobowitz <dan@codesourcery.com>
13939 * Makefile.in (OBS): Add $(XML_BUILTIN).
13940 (XML_DIR, XML_TARGET, XML_FILES, XML_BUILTIN): New.
13942 (target.xml, xml-builtin.c, stamp-xml, arm-with-iwmmxt.o)
13943 (arm-with-iwmmxt.c): New.
13944 * config.in, configure: Regenerate.
13945 * configure.ac: Check for iWMMXt. Handle srv_xmltarget,
13946 srv_xmlbuiltin, and srv_xmlfiles. Define USE_XML.
13947 * configure.srv: Mention srv_xmltarget and srv_xmlfiles.
13948 (arm*-*-linux*): Add iWMMXt and regset support.
13949 * linux-arm-low.c (PTRACE_GETWMMXREGS, PTRACE_SETWMMXREGS): Define.
13950 (arm_fill_gregset, arm_store_gregset, arm_fill_wmmxregset)
13951 (arm_store_wmmxregset, target_regsets): New.
13952 * server.c (get_features_xml): Take annex argument. Check builtin
13954 (handle_query): Handle multiple annexes.
13956 2007-01-29 Daniel Jacobowitz <dan@codesourcery.com>
13958 * remote-utils.c [USE_WIN32API] (read, write): Define.
13959 (putpkt_binary, input_interrupt, readchar, getpkt): Use read and
13962 2007-01-09 Daniel Jacobowitz <dan@codesourcery.com>
13964 * linux-i386-low.c (the_low_target): Set arch_string.
13965 * linux-x86-64-low.c (the_low_target): Likewise.
13966 * linux-low.c (linux_arch_string): New.
13967 (linux_target_ops): Add it.
13968 * linux-low.h (struct linux_target_ops): Add arch_string.
13969 * server.c (write_qxfer_response): Use const void * for DATA.
13970 (get_features_xml): New.
13971 (handle_query): Handle qXfer:features:read. Report it for qSupported.
13972 * target.h (struct target_ops): Add arch_string method.
13974 2007-01-03 Denis Pilat <denis.pilat@st.com>
13975 Daniel Jacobowitz <dan@codesourcery.com>
13977 * linux-low.c (linux_kill): Handle being called with no threads.
13978 * win32-i386-low.c (win32_kill): Likewise.
13979 (get_child_debug_event): Clear current_process_handle.
13981 2006-12-30 Denis PILAT <denis.pilat@st.com>
13982 Daniel Jacobowitz <dan@codesourcery.com>
13984 * remote-utils.c (remote_open): Check the type of specified
13985 serial port devices before opening them.
13986 * server.c (main): Kill the inferior if an error occurs during
13987 the first remote_open.
13989 2006-12-05 Markus Deuling <deuling@de.ibm.com>
13991 * README: Update supported targets.
13993 2006-11-28 Daniel Jacobowitz <dan@codesourcery.com>
13995 * Makefile.in (clean): Remove reg-mips64.c.
13996 (reg-mips64.c, reg-mips64.o): New rules.
13997 * configure.srv: Handle mips64. Include regset support for mips.
13998 * linux-mips-low.c (union mips_register): New.
13999 (mips_get_pc, mips_set_pc, mips_reinsert_addr): Use it.
14000 (mips_breakpoint, mips_breakpoint_at): Use int.
14001 (mips_collect_register, mips_supply_register)
14002 (mips_collect_register_32bit, mips_supply_register_32bit)
14003 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
14004 (mips_store_fpregset, target_regsets): New.
14005 * thread-db.c (thread_db_get_tls_address): Use uintptr_t.
14007 2006-11-22 Ulrich Weigand <uweigand@de.ibm.com>
14009 * configure.srv: Add target "spu*-*-*".
14010 * Makefile.in (clean): Remove reg-spu.c.
14011 (reg-spu.c, reg-spu.o, spu-low.o): Add dependencies.
14012 * spu-low.c: New file.
14014 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
14016 * configure.ac: Correct td_thr_tls_get_addr test.
14017 * configure: Regenerated.
14019 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
14021 * linux-low.c (linux_wait_for_event): Reformat. Use the
14022 pass_signals array.
14023 * remote-utils.c (decode_address_to_semicolon): New.
14024 * server.c (pass_signals, handle_general_set): New.
14025 (handle_query): Mention QPassSignals for qSupported.
14026 (main): Call handle_general_set.
14027 * server.h (pass_signals, decode_address_to_semicolon): New.
14029 2006-11-06 Daniel Jacobowitz <dan@codesourcery.com>
14031 * server.c (handle_query): Correct error handling for read_auxv.
14033 2005-10-19 Ulrich Weigand <uweigand@de.ibm.com>
14035 * configure.srv [s390-*-linux*, s390x-*-linux*]: Set srv_linux_regsets
14036 and srv_linux_thread_db to yes.
14037 * linux-s390-low.c (s390_fill_gregset): New function.
14038 (target_regsets): Define data structure.
14040 2006-10-17 Daniel Jacobowitz <dan@codesourcery.com>
14042 * acinclude.m4 (SRV_CHECK_TLS_GET_ADDR): New.
14043 * configure.ac: Use it. Define HAVE_TD_THR_TLS_GET_ADDR.
14044 * config.in, configure: Regenerated.
14045 * inferiors.c (gdb_id_to_thread): New function.
14046 (gdb_id_to_thread_id): Use it.
14047 * linux-low.c (linux_target_ops): Use thread_db_get_tls_address.
14048 * linux-low.h (struct process_info): Add th member.
14049 (thread_db_get_tls_address): New prototype.
14050 * remote-utils.c (decode_address): Make non-static.
14051 * server.c (handle_query): Handle qGetTLSAddr.
14052 * server.h (gdb_id_to_thread, decode_address): New prototypes.
14053 * target.h (struct target_ops): Add get_tls_address.
14054 * thread-db.c (maybe_attach_thread): Save the thread handle.
14055 (thread_db_get_tls_address): New.
14057 2006-09-28 Daniel Jacobowitz <dan@codesourcery.com>
14059 * linux-low.c (PTRACE_GETSIGINFO, PTRACE_SETSIGINFO): Define.
14060 (linux_resume_one_process): Take a siginfo_t *. Update all
14061 callers. Queue it if necessary. Use PTRACE_SETSIGINFO.
14062 (struct pending_signals): Add a siginfo_t.
14063 (linux_wait_for_process): Always set last_status.
14064 (linux_wait_for_event): Use PTRACE_GETSIGINFO.
14065 (linux_queue_one_thread): Use PTRACE_GETSIGINFO.
14066 * linux-low.h (struct process_info): Add last_status.
14068 2006-09-21 Daniel Jacobowitz <dan@codesourcery.com>
14070 * remote-utils.c (try_rle): New function.
14071 (putpkt_binary): Use it.
14073 2006-08-19 Daniel Jacobowitz <dan@codesourcery.com>
14075 * Makefile.in (clean): Clean reg-x86-64-linux.c.
14076 (reg-x86-64-linux.o, reg-x86-64-linux.c): New.
14077 * configure.srv (x86_64-*-linux*): Use reg-x86-64-linux.o.
14078 * linux-x86-64-low.c (x86_64_regmap): Include ORIG_RAX.
14079 (x86_64_fill_gregset, x86_64_store_gregset): Skip floating
14082 2006-08-08 Richard Sandiford <richard@codesourcery.com>
14084 * server.c (terminal_fd): New variable.
14085 (old_foreground_pgrp): Likewise.
14086 (restore_old_foreground_pgrp): New function.
14087 (start_inferior): Record the terminal file descriptor in terminal_fd
14088 and its original foreground group in old_foreground_pgrp. Register
14089 restore_old_foreground_pgrp with atexit().
14091 2006-07-26 Daniel Jacobowitz <dan@codesourcery.com>
14093 * server.c (handle_query): Correct qPart to qXfer.
14095 2006-07-22 Daniel Jacobowitz <dan@codesourcery.com>
14097 * configure.ac: Check for more headers which are missing on
14098 Windows. Automatically supply -lwsock32 and USE_WIN32API.
14099 * configure.srv: Add Cygwin and mingw32.
14100 * remote-utils.c: Don't include headers unconditionally which
14101 are missing on mingw32. Include <winsock.h> for mingw32.
14102 (remote_open): Adjust for mingw32 support. Flush
14103 standard error after writing to it.
14104 (remote_close, putpkt_binary, input_interrupt, block_async_io)
14105 (unblock_async_io, enable_async_io, disable_async_io)
14106 (readchar, getpkt): Update for Winsock support.
14107 (prepare_resume_reply): Expect a protocol signal number.
14108 * server.c: Disable <sys/wait.h> on mingw32.
14109 (start_inferior): Adjust for mingw32 support. Flush
14110 standard error after writing to it.
14111 (attach_inferior): Likewise. Use protocol signal
14113 (main): Skip 'D' packet on mingw32. Use protocol signal numbers
14115 * win32-i386-low.c: New file.
14116 * Makefile.in (XM_CLIBS): Set.
14117 (gdbserver, gdbreplay): Use $(INTERNAL_CFLAGS).
14118 (win32-i386-low.o): New dependency rule.
14119 * linux-low.c (linux_wait): Use target signal numbers.
14120 * target.h (struct target_ops): Doc fix.
14121 * server.h (target_signal_to_name): New prototype.
14122 * gdbreplay.c: Don't include headers unconditionally which
14123 are missing on mingw32. Include <winsock.h> for mingw32.
14124 (remote_close, remote_open): Adjust for Winsock support.
14125 * configure, config.in: Regenerated.
14127 2006-07-12 Daniel Jacobowitz <dan@codesourcery.com>
14129 * server.c (decode_xfer_read, write_qxfer_response): New.
14130 (handle_query): Take a packet length argument. Handle
14131 qXfer:auxv:read instead of qPart:auxv:read. Mention it in
14132 the qSupported response.
14133 (main): Update call to handle_query.
14135 2006-06-22 Daniel Jacobowitz <dan@codesourcery.com>
14137 * remote-utils.c (remote_escape_output, remote_unescape_input): New.
14138 (putpkt_binary): Renamed from putpkt and adjusted for binary
14140 (putpkt): New wrapper for putpkt_binary.
14141 (readchar): Don't mask off the high bit.
14142 (decode_X_packet): New function.
14143 * server.c (main): Call putpkt_binary if a handler sets the packet
14144 length. Save the length of the incoming packet. Handle 'X'.
14145 * server.h (gdb_byte, remote_escape_output, decode_X_packet): New.
14147 2006-06-21 Daniel Jacobowitz <dan@codesourcery.com>
14149 * server.c (handle_query): Handle qSupported.
14151 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
14153 * remote-utils.c (all_symbols_looked_up): New variable.
14154 (look_up_one_symbol): Check it.
14155 * server.h (look_up_one_symbol): New declaration.
14156 * thread-db.c (thread_db_init): Set all_symbols_looked_up.
14158 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
14160 * Makefile.in (linux-arm-low.o): Update dependencies.
14161 * linux-arm-low.c: Include "gdb_proc_service.h".
14162 (PTRACE_GET_THREAD_AREA): Define.
14163 (ps_get_thread_area): New function.
14165 2006-05-09 Nathan Sidwell <nathan@codesourcery.com>
14167 * configure.srv (m68k*-*-uclinux*): New target.
14168 * linux-low.c (linux_create_inferior): Use vfork on mmuless systems.
14169 (linux_resume_one_process): Remove extraneous cast.
14170 (linux_read_offsets): New.
14171 (linux_target_op): Add linux_read_offsets on mmuless systems.
14172 * server.c (handle_query): Add qOffsets logic.
14173 * target.h (struct target_ops): Add read_offsets.
14175 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
14177 * linux-mips-low.c: Include <sys/ptrace.h> and "gdb_proc_service.h".
14178 (PTRACE_GET_THREAD_AREA): Define.
14179 (ps_get_thread_area): New function.
14180 * Makefile.in (linux-i386-low.o, linux-mips-low.o)
14181 (linux-x86-64-low.o): Update.
14183 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
14185 * configure.ac: Remove checks for prfpregset_t.
14186 * gdb_proc_service.h: New file.
14187 * linux-i386-low.c, linux-x86-64-low.c, thread-db.c: Use the
14188 new "gdb_proc_service.h".
14189 * proc-service.c: Likewise.
14190 (ps_pglobal_lookup, ps_pdread, ps_pdwrite): Use psaddr_t.
14191 (ps_lgetfpregs, ps_lsetfpregs): Use a void* argument.
14192 * Makefile.in (gdb_proc_service_h): Updated.
14193 * configure, config.in: Regenerated.
14195 2006-03-03 Daniel Jacobowitz <dan@codesourcery.com>
14197 * remote-utils.c (prepare_resume_reply): Move declaration
14198 of gdb_id_from_wait to the top of the block.
14200 2006-02-15 Daniel Jacobowitz <dan@codesourcery.com>
14202 * linux-low.c (regsets_store_inferior_registers): Read the regset
14203 from the target before filling it.
14205 2006-02-08 Daniel Jacobowitz <dan@codesourcery.com>
14207 * server.c (attach_inferior): Return SIGTRAP for a successful
14210 2006-02-01 Daniel Jacobowitz <dan@codesourcery.com>
14212 * Makefile.in (OBS): Add version.o.
14213 (STAGESTUFF): Delete.
14214 (version.o): Add dependencies.
14215 (version.c): Replace rule.
14216 (clean): Remove version.c.
14217 * server.c (gdbserver_version): New.
14218 (gdbserver_usage): Use printf.
14219 (main): Handle --version and --help.
14220 * server.h (version, host_name): Add declarations.
14222 2005-12-23 Eli Zaretskii <eliz@gnu.org>
14234 * linux-x86-64-low.c:
14236 * linux-s390-low.c:
14237 * linux-ppc64-low.c:
14239 * linux-mips-low.c:
14240 * linux-m68k-low.c:
14241 * linux-m32r-low.c:
14244 * linux-ia64-low.c:
14245 * linux-i386-low.c:
14246 * linux-crisv32-low.c:
14258 * gdbserver.1: Add (C) after Copyright. Update the FSF
14261 2005-11-13 Daniel Jacobowitz <dan@codesourcery.com>
14263 * linux-arm-low.c (arm_eabi_breakpoint): New variable.
14264 (arm_breakpoint_at): Recognize both breakpoints.
14265 (the_low_target): Use the correct breakpoint instruction.
14267 2005-11-02 Daniel Jacobowitz <dan@codesourcery.com>
14269 * configure.srv (x86_64-*-linux*): Turn on thread_db support.
14270 * linux-x86-64-low.c (x86_64_breakpoint, x86_64_breakpoint_len)
14271 (x86_64_get_pc, x86_64_set_pc, x86_64_breakpoint_at): New.
14272 (the_low_target): Update.
14274 2005-10-25 Andreas Schwab <schwab@suse.de>
14276 * server.c (main): Allocate mem_buf with PBUFSIZ bytes.
14278 * linux-ia64-low.c (ia64_regmap): Remove NAT registers.
14279 (ia64_num_regs): Reduce to 462.
14281 2005-09-17 Daniel Jacobowitz <dan@codesourcery.com>
14283 * acinclude.m4: Correct quoting.
14284 * aclocal.m4: Regenerated.
14286 Suggested by SZOKOVACS Robert <szo@ies.hu>:
14287 * thread-db.c (thread_db_err_str): Handle TD_VERSION.
14288 (thread_db_init): Call thread_db_err_str.
14289 * configure.ac: Check for TD_VERSION.
14290 * config.in, configure: Regenerated.
14292 2005-07-31 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
14294 * server.h (error, fatal, warning): Add ATTR_FORMAT.
14296 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
14298 * configure.ac: Define HAVE_LINUX_REGSETS even if PTRACE_GETREGS
14299 is not available. Define HAVE_PTRACE_GETREGS if it is.
14300 * config.in, configure: Regenerated.
14301 * configure.srv: Set srv_linux_regsets for PowerPC and PowerPC64.
14302 * linux-i386-low.c, linux-m68k-low.c: Update to use
14303 HAVE_PTRACE_GETREGS.
14304 * linux-low.c (regsets_fetch_inferior_registers)
14305 (regsets_store_inferior_registers): Only return 0 if we processed
14307 * linux-ppc-low.c (ppc_fill_gregset, target_regsets): New.
14308 * linux-ppc64-low.c (ppc_fill_gregset, target_regsets): New.
14310 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
14312 * inferiors.c (struct thread_info): Add gdb_id.
14313 (add_thread): Add gdb_id argument.
14314 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New.
14315 * linux-low.c (linux_create_inferior, linux_attach_lwp): Update
14316 calls to add_thread.
14317 * remote-utils.c (prepare_resume_reply: Use thread_to_gdb_id.
14318 * server.c (handle_query): Use thread_to_gdb_id.
14319 (handle_v_cont, main): Use gdb_id_to_thread_id.
14320 * server.h (add_thread): Update prototype.
14321 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New
14324 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
14326 * linux-low.c (fetch_register, usr_store_inferior_registers): Handle
14327 left-padded registers.
14328 * linux-low.h (struct linux_target_ops): Add left_pad_xfer.
14329 * linux-ppc64-low.c (the_low_target): Set left_pad_xfer.
14331 2005-07-01 Steve Ellcey <sje@cup.hp.com>
14333 * configure.ac (BFD_NEED_DECLARATION): Replace with AC_CHECK_DECLS.
14334 * configure: Regenerate.
14335 * config.in: Regenerate.
14336 * server.h (NEED_DECLARATION_STRERROR):
14337 Replace with !HAVE_DECL_STRERROR.
14339 2005-06-16 Daniel Jacobowitz <dan@codesourcery.com>
14341 * linux-low.c (linux_wait, linux_send_signal): Don't test
14342 an unsigned long variable for > 0 if it could be MAX_ULONG.
14343 * server.c (myresume): Likewise.
14344 * target.c (set_desired_inferior): Likewise.
14346 2005-06-13 Mark Kettenis <kettenis@gnu.org>
14348 * configure.ac: Simplify and improve check for socklen_t.
14349 * configure, config.in: Regenerate.
14351 2005-06-12 Daniel Jacobowitz <dan@codesourcery.com>
14353 * acconfig.h: Remove.
14354 * configure.ac: Add a test for socklen_t. Use three-argument
14355 AC_DEFINE throughout.
14356 * config.in: Regenerated using autoheader 2.59.
14357 * configure: Regenerated.
14359 * gdbreplay.c (socklen_t): Provide a default.
14360 (remote_open): Use socklen_t.
14361 * remote-utils.c (socklen_t): Provide a default.
14362 (remote_open): Use socklen_t.
14363 (convert_int_to_ascii, convert_ascii_to_int, decode_M_packet): Use
14366 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Use unsigned
14368 * linux-low.c (linux_read_memory, linux_write_memory)
14369 (linux_read_auxv): Likewise.
14370 * mem-break.c (breakpoint_data, set_breakpoint_data, check_mem_read)
14371 (check_mem_write): Likewise.
14372 * mem-break.h (set_breakpoint_data, check_mem_read, check_mem_write):
14374 * regcache.c (struct inferior_rgcache_data, registers_to_string)
14375 (registers_from_string, register_data): Likewise.
14376 * server.c (handle_query, main): Likewise.
14377 * server.h (convert_ascii_to_int, convert_int_to_ascii)
14378 (decode_M_packet): Likewise.
14379 * target.c (read_inferior_memory, write_inferior_memory): Likewise.
14380 * target.h (struct target_ops): Update read_memory, write_memory,
14382 (read_inferior_memory, write_inferior_memory): Update.
14383 * linux-low.h (struct linux_target_ops): Change type of breakpoint
14384 to unsigned char *.
14385 * linux-arm-low.c, linux-cris-low.c, linux-crisv32-low.c,
14386 linux-i386-low.c, linux-m32r-low.c, linux-m68k-low.c,
14387 linux-mips-low.c, linux-ppc-low.c, linux-ppc64-low.c,
14388 linux-s390-low.c, linux-sh-low.c: Update for changes in
14389 read_inferior_memory and the_low_target->breakpoint.
14391 2005-05-28 Daniel Jacobowitz <dan@codesourcery.com>
14393 * Makefile.in (SFILES): Add linux-ppc64-low.c.
14394 (linux-ppc64-low.o, reg-ppc64.c, reg-ppc64.o): New targets.
14395 * configure.srv: Add powerpc64-*-linux*.
14396 * linux-ppc64-low.c: New file.
14398 2005-05-23 Orjan Friberg <orjanf@axis.com>
14400 * linux-cris-low.c: New file with support for CRIS.
14401 * linux-crisv32-low.c: Ditto for CRISv32.
14402 * Makefile.in (SFILES): Add linux-cris-low.c, linux-crisv32-low.c.
14403 (clean): Add reg-cris.c and reg-crisv32.c.
14404 Add linux-cris-low.o, linux-crisv32-low.o, reg-cris.o, reg-cris.c,
14405 reg-crisv32.o, and reg-crisv32.c to make rules.
14406 * configure.srv: Add cris-*-linux* and crisv32-*-linux* to list of
14407 recognized targets.
14409 2005-05-16 Ulrich Weigand <uweigand@de.ibm.com>
14411 * linux-low.c (fetch_register): Ensure buffer size is a multiple
14412 of sizeof (PTRACE_XFER_TYPE).
14413 (usr_store_inferior_registers): Likewise. Zero out excess bytes.
14415 2005-05-12 Orjan Friberg <orjanf@axis.com>
14417 * target.h (struct target_ops): Add insert_watchpoint,
14418 remove_watchpoint, stopped_by_watchpoint, stopped_data_address function
14419 pointers for hardware watchpoint support.
14420 * linux-low.h (struct linux_target_ops): Ditto.
14421 * linux-low.c (linux_insert_watchpoint, linux_remove_watchpoint)
14422 (linux_stopped_by_watchpoint, linux_stopped_data_address): New. Add
14423 to linux_target_ops.
14424 * remote-utils.c (prepare_resume_reply): Add watchpoint information to
14426 * server.c (main): Recognize 'Z' and 'z' packets.
14428 2005-05-10 Ulrich Weigand <uweigand@de.ibm.com>
14430 * linux-s390-low.c (s390_breakpoint, s390_breakpoint_len): Define.
14431 (s390_get_pc, s390_set_pc, s390_breakpoint_at): New functions.
14432 (the_low_target): Add new members.
14434 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
14436 * proc-service.c (ps_lgetregs): Search all_processes instead of
14439 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
14441 * server.c (start_inferior): Change return type to int.
14442 (attach_inferior): Change sigptr to int *.
14443 (handle_v_cont, handle_v_requests): Change signal to int *.
14444 (main): Change signal to int.
14446 2005-04-15 Kei Sakamoto <sakamoto.kei@renesas.com>
14448 * Makefile.in: Add linux-m32r-low.o, reg-m32r.c and reg-m32r.o.
14449 * configure.srv: Add m32r*-*-linux*.
14450 * linux-m32r-low.c: New file.
14452 2005-03-04 Daniel Jacobowitz <dan@codesourcery.com>
14454 * Makefile.in (stamp-h): Set CONFIG_HEADERS explicitly.
14456 2005-03-03 Daniel Jacobowitz <dan@codesourcery.com>
14458 * inferiors.c (change_inferior_id, add_thread, find_inferior_id):
14459 Take unsigned long arguments for PIDs.
14460 * linux-low.c (add_process, linux_attach_lwp, linux_attach)
14461 (linux_thread_alive, linux_wait_for_event, kill_lwp, send_sigstop)
14462 (wait_for_sigstop, linux_resume_one_process)
14463 (regsets_fetch_inferior_registers, linux_send_signal)
14464 (linux_read_auxv): Likewise. Update the types of variables holding
14465 PIDs. Update format string specifiers.
14466 * linux-low.h (struct process_info, linux_attach_lwp): Likewise.
14467 * remote-utils.c (prepare_resume_reply): Likewise.
14468 * server.c (cont_thread, general_thread, step_thread)
14469 (thread_from_wait, old_thread_from_wait, signal_pid): Change type to
14471 (handle_query): Update format specifiers.
14472 (handle_v_cont, main): Use strtoul for thread IDs.
14473 * server.h (struct inferior_list_entry): Use unsigned long for ID.
14474 (add_thread, find_inferior_id, change_inferior_id, cont_thread)
14475 (general_thread, step_thread, thread_from_wait)
14476 (old_thread_from_wait): Update.
14477 * target.h (struct thread_resume): Use unsigned long for THREAD.
14478 (struct target_ops): Use unsigned long for arguments to attach and
14481 2005-02-24 Daniel Jacobowitz <dan@codesourcery.com>
14483 * acinclude.m4: Include bfd/bfd.m4 directly.
14484 * configure.ac: Use AC_ARG_PROGRAM. Suggested by Aron Griffis
14485 <agriffis@toolchain.org>.
14486 * aclocal.m4, configure: Regenerated.
14488 2005-01-07 Andrew Cagney <cagney@gnu.org>
14490 * configure.ac: Rename configure.in, require autoconf 2.59.
14491 * configure: Re-generate.
14493 2004-12-08 Daniel Jacobowitz <dan@debian.org>
14495 * acinclude.m4 (SRV_CHECK_THREAD_DB): Add ps_get_thread_area. Reset
14496 LIBS when finished.
14497 * aclocal.m4: Regenerated.
14498 * configure: Regenerated.
14500 2004-11-21 Andreas Schwab <schwab@suse.de>
14502 * linux-m68k-low.c (m68k_num_gregs): Define.
14503 (m68k_fill_gregset, m68k_store_gregset, m68k_fill_fpregset)
14504 (m68k_store_fpregset, target_regsets) [HAVE_LINUX_REGSETS]: New.
14505 (m68k_breakpoint, m68k_breakpoint_len, m68k_get_pc, m68k_set_pc)
14506 (m68k_breakpoint_at): New. Add to the_low_target.
14508 * configure.srv (m68*-*-linux*): Set srv_linux_regsets and
14509 srv_linux_thread_db to yes.
14511 2004-10-20 Joel Brobecker <brobecker@gnat.com>
14513 * linux-x86-64-low.c (ARCH_SET_GS): Add definition if missing.
14514 (ARCH_SET_FS): Likewise.
14515 (ARCH_GET_FS): Likewise.
14516 (ARCH_GET_GS): Likewise.
14518 2004-10-16 Daniel Jacobowitz <dan@debian.org>
14520 * linux-i386-low.c (ps_get_thread_area): New.
14521 * linux-x86-64-low.c (ps_get_thread_area): New.
14522 * linux-low.c: Include <sys/syscall.h>.
14523 (linux_kill_one_process): Don't kill the first thread here.
14524 (linux_kill): Kill the first thread here.
14525 (kill_lwp): New function.
14526 (send_sigstop, linux_send_signal): Use it.
14527 * proc-service.c: Clean up #ifdefs.
14528 (fpregset_info): Delete.
14529 (ps_lgetregs): Update and enable implementation.
14530 (ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs): Remove disabled
14532 * remote-utils.c (struct sym_cache, symbol_cache): New.
14533 (input_interrupt): Print a clearer message.
14534 (async_io_enabled): New variable.
14535 (enable_async_io, disable_async_io): Use it. Update comments.
14536 (look_up_one_symbol): Use the symbol cache.
14537 * thread-db.c (thread_db_look_up_symbols): New function.
14538 (thread_db_init): Update comments. Call thread_db_look_up_symbols.
14540 2004-10-16 Daniel Jacobowitz <dan@debian.org>
14542 * configure.in: Test for -rdynamic.
14543 * configure: Regenerated.
14544 * Makefile (INTERNAL_LDFLAGS): New.
14545 (gdbserver, gdbreplay): Use it.
14547 2004-09-02 Andrew Cagney <cagney@gnu.org>
14549 * Makefile.in (TAGS): Replace TM_FILE with DEPRECATED_TM_FILE.
14551 2004-03-23 Daniel Jacobowitz <drow@mvista.com>
14553 * linux-low.c (linux_wait): Clear all_processes list also.
14555 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
14557 * linux-low.c: Include <errno.h>. Remove extern declaration of
14560 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
14562 * gdbreplay.c, server.h, utils.c: Update copyright years.
14564 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
14566 * server.c (main): Print child status or termination signal from
14567 variable 'signal', not 'sig'.
14569 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
14571 * linux-low.c (linux_read_memory): Change return type to
14572 int. Check for and return error from ptrace().
14573 * target.c (read_inferior_memory): Change return type to int. Pass
14574 back return status from the_target->read_memory().
14575 * target.h (struct target_ops): Adapt *read_memory() prototype.
14577 (read_inferior_memory): Adapt prototype.
14578 * server.c (main): Return an error packet if
14579 read_inferior_memory() returns an error.
14581 2004-03-04 Daniel Jacobowitz <drow@mvista.com>
14583 * Makefile.in (distclean): Remove config.h, stamp-h, and config.log.
14584 Unify with other clean targets.
14586 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
14588 * server.c (handle_v_cont): Call set_desired_inferior.
14590 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
14592 * remote-utils.c (prepare_resume_reply): Always supply "thread:".
14594 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
14596 * linux-low.c (linux_wait): Unblock async I/O.
14597 (linux_resume): Block and enable async I/O.
14598 * remote-utils.c (block_async_io, unblock_async_io): New functions.
14599 * server.h (block_async_io, unblock_async_io): Add prototypes.
14601 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
14603 * remote-utils.c (remote_open): Print a status notice after
14604 opening a TCP port.
14605 * server.c (attach_inferior): Print a status notice after
14608 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
14610 * linux-arm-low.c (arm_get_pc): Print out stop PC in debug mode.
14612 2004-02-26 Daniel Jacobowitz <drow@mvista.com>
14614 * remote-utils.c (write_enn): Use "E01" instead of "ENN" for the
14616 * server.c, target.h: Update copyright years.
14618 2004-02-25 Roland McGrath <roland@redhat.com>
14620 * target.h (struct target_ops): New member `read_auxv'.
14621 * server.c (handle_query): Handle qPart:auxv:read: query using that.
14622 * linux-low.c (linux_read_auxv): New function.
14623 (linux_target_ops): Initialize `read_auxv' member to that.
14625 2004-02-17 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
14627 Committed by Jim Blandy <jimb@redhat.com>.
14629 * linux-s390-low.c (s390_num_regs): Update.
14630 (s390_regmap): Remove control registers. Use __s390x__ predefine
14631 instead of GPR_SIZE to distiguish s390 and s390x targets.
14633 2004-01-31 Daniel Jacobowitz <drow@mvista.com>
14635 * linux-low.c: Update copyright year.
14636 (check_removed_breakpoint): Clear pending_is_breakpoint.
14637 (linux_set_resume_request, linux_queue_one_thread)
14638 (resume_status_pending_p): New functions.
14639 (linux_continue_one_thread): Use process->resume.
14640 (linux_resume): Only resume threads if there are no pending events.
14641 * linux-low.h (struct process_info): Add resume request
14644 2004-01-30 Daniel Jacobowitz <drow@mvista.com>
14646 * regcache.c (new_register_cache): Clear the allocated register
14647 buffer. Suggested by Atsushi Nemoto <anemo@mba.ocn.ne.jp>.
14649 2003-10-13 Daniel Jacobowitz <drow@mvista.com>
14651 * linux-low.c (linux_resume): Take a struct thread_resume *
14653 (linux_wait): Update call.
14654 (resume_ptr): New static variable.
14655 (linux_continue_one_thread): Renamed from
14656 linux_continue_one_process. Use resume_ptr.
14657 (linux_resume): Use linux_continue_one_thread.
14658 * server.c (handle_v_cont, handle_v_requests): New functions.
14659 (myresume): New function.
14660 (main): Handle 'v' case.
14661 * target.h (struct thread_resume): New type.
14662 (struct target_ops): Change argument of "resume" to struct
14664 (myresume): Delete macro.
14666 2003-08-08 H.J. Lu <hongjiu.lu@intel.com>
14668 * Makefile.in (install-only): Create dest dir. Support DESTDIR.
14669 (uninstall): Support DESTDIR.
14671 Mon Jul 21 20:09:34 UTC 2003 Brendan Conoboy <blc@redhat.com>
14673 * configure.srv: Add xscale*linux copy of arm*linux entry.
14675 2003-07-24 Daniel Jacobowitz <drow@mvista.com>
14677 * linux-arm-low.c (arm_reinsert_addr): New function.
14678 (the_low_target): Add arm_reinsert_addr.
14680 2003-07-08 Mark Kettenis <kettenis@gnu.org>
14682 * mem-break.c: Remove whitespace at end of file.
14684 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
14686 * configure.in: Check whether we need to prototype strerror.
14687 * server.h: Optionally prototype strerror.
14688 * gdbreplay.c (perror_with_name): Use strerror.
14689 * linux-low.c (linux_attach_lwp): Use strerror.
14690 * utils.c (perror_with_name): Use strerror.
14691 * config.in, configure: Regenerated.
14693 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
14695 * linux-sh-low.c (sh_regmap): Fix FP register offsets, reported by
14696 SUGIOKA Toshinobu <sugioka@itonet.co.jp>.
14698 2003-06-20 Daniel Jacobowitz <drow@mvista.com>
14700 * Makefile.in (SFILES): Update.
14701 * low-hppabsd.c, low-lynx.c, low-nbsd.c, low-sim.c, low-sparc.c,
14702 low-sun3.c: Remove files.
14704 2003-06-17 Daniel Jacobowitz <drow@mvista.com>
14706 * linux-low.c: Move comment to linux_thread_alive where it belonged.
14707 (linux_detach_one_process, linux_detach): New functions.
14708 (linux_target_ops): Add linux_detach.
14709 * server.c (main): Handle 'D' packet.
14710 * target.h (struct target_ops): Add "detach" member.
14711 (detach_inferior): Define.
14713 2003-06-13 Mark Kettenis <kettenis@gnu.org>
14715 From Kelley Cook <kelleycook@wideopenwest.com>:
14716 * configure.srv: Accept i[34567]86 variants.
14718 2003-06-05 Daniel Jacobowitz <drow@mvista.com>
14720 * linux-low.c (linux_wait_for_event): Correct comment typos.
14721 (linux_resume_one_process): Call check_removed_breakpoint.
14722 (linux_send_signal): New function.
14723 (linux_target_ops): Add linux_send_signal.
14724 * remote-utils.c (putpkt, input_interrupt): Use send_signal instead
14726 * target.h (struct target_ops): Add send_signal.
14728 2003-05-29 Jim Blandy <jimb@redhat.com>
14730 * linux-low.c (usr_store_inferior_registers): Transfer buf in
14731 PTRACE_XFER_TYPE-sized chunks, not int-sized chunks. Otherwise,
14732 if 'int' is smaller than PTRACE_XFER_TYPE, you end up throwing
14733 away part of the register's value.
14735 2003-03-26 Daniel Jacobowitz <drow@mvista.com>
14737 * linux-low.c (linux_create_inferior): Use __SIGRTMIN.
14738 (linux_wait_for_event, linux_init_signals): Likewise.
14740 2003-03-17 Daniel Jacobowitz <drow@mvista.com>
14742 * configure.in: Check for stdlib.h.
14743 * configure: Regenerated.
14744 * config.in: Regenerated.
14746 2003-01-04 Andreas Schwab <schwab@suse.de>
14748 * linux-m68k-low.c (m68k_num_regs): Define to 29 instead of 31.
14750 2003-01-02 Andrew Cagney <ac131313@redhat.com>
14752 * Makefile.in: Remove obsolete code.
14754 2002-11-20 Daniel Jacobowitz <drow@mvista.com>
14756 * linux-s390-low.c (s390_regmap): Check GPR_SIZE instead of
14757 defined(PT_FPR0_HI).
14759 2002-11-17 Stuart Hughes <seh@zee2.com>
14761 * linux-arm-low.c (arm_num_regs): Increase.
14762 (arm_regmap): Include status register.
14764 2002-11-17 Daniel Jacobowitz <drow@mvista.com>
14766 * linux-low.c (register_addr): Remove incorrect -1 check.
14768 2002-08-29 Daniel Jacobowitz <drow@mvista.com>
14770 * linux-low.c (linux_create_inferior): Call setpgid. Return
14772 (unstopped_p, linux_signal_pid): Remove.
14773 (linux_target_ops): Remove linux_signal_pid.
14774 * remote-utils.c (putpkt, input_interrupt): Use signal_pid
14775 global instead of target method.
14776 * target.h (struct target_ops): Remove signal_pid. Update comment
14777 for create_inferior.
14778 * server.c (signal_pid): New variable.
14779 (create_inferior): Set signal_pid. Block SIGTTOU and SIGTTIN in
14780 gdbserver. Set the child to be the foreground process group.
14781 (attach_inferior): Set signal_pid.
14783 2002-08-23 Daniel Jacobowitz <drow@mvista.com>
14785 * ChangeLog: New file, with entries from gdb/ChangeLog after GDB 5.2.
14787 2002-08-20 Jim Blandy <jimb@redhat.com>
14789 * Makefile.in (LDFLAGS): Allow the configure script to establish a
14792 2002-08-01 Andrew Cagney <cagney@redhat.com>
14794 * Makefile.in: Make chill references obsolete.
14796 2002-07-24 Kevin Buettner <kevinb@redhat.com>
14798 * configure.in (unistd.h): Add to AC_CHECK_HEADERS list.
14799 * configure: Regenerate.
14800 * config.in: Regenerate.
14802 2002-07-09 David O'Brien <obrien@FreeBSD.org>
14804 * gdbreplay.c (stdlib.h, unistd.h): Conditionaly include.
14805 (perror_with_name, remote_close, remote_open, expect, play): Static.
14807 2002-07-04 Michal Ludvig <mludvig@suse.cz>
14809 * linux-x86-64-low.c (x86_64_regmap): Make it an array of
14810 byte offsets instead of an array of indexes.
14811 (x86_64_store_gregset, x86_64_store_fpregset): Parameter made const.
14813 2002-06-13 Daniel Jacobowitz <drow@mvista.com>
14815 * regcache.c: Add comment.
14817 2002-06-11 Daniel Jacobowitz <drow@mvista.com>
14819 * thread-db.c: New file.
14820 * proc-service.c: New file.
14821 * acinclude.m4: New file.
14822 * Makefile.in: Add GDBSERVER_LIBS, gdb_proc_service_h,
14823 proc-service.o, and thread-db.o.
14824 (linux-low.o): Add USE_THREAD_DB.
14825 * acconfig.h: Add HAVE_PRGREGSET_T, HAVE_PRFPREGSET_T,
14826 HAVE_LWPID_T, HAVE_PSADDR_T, and PRFPREGSET_T_BROKEN.
14827 * aclocal.m4: Regenerated.
14828 * config.in: Regenerated.
14829 * configure: Regenerated.
14830 * configure.in: Check for proc_service.h, sys/procfs.h,
14831 thread_db.h, and linux/elf.h headrs.
14832 Check for lwpid_t, psaddr_t, prgregset_t, prfpregset_t, and
14833 PRFPREGSET_T_BROKEN. Introduce srv_thread_depfiles and USE_THREAD_DB.
14834 Check for -lthread_db and thread support.
14835 * configure.srv: Enable thread_db support for ARM, i386, MIPS,
14836 PowerPC, and SuperH.
14837 * i387-fp.c: Constify arguments.
14838 * i387-fp.h: Likewise.
14839 * inferiors.c: (struct thread_info): Renamed from
14840 `struct inferior_info'. Remove PID member. Use generic inferior
14841 list header. All uses updated.
14842 (inferiors, signal_pid): Removed.
14843 (all_threads): New variable.
14844 (get_thread): Define.
14845 (add_inferior_to_list): New function.
14846 (for_each_inferior): New function.
14847 (change_inferior_id): New function.
14848 (add_inferior): Removed.
14849 (remove_inferior): New function.
14850 (add_thread): New function.
14851 (free_one_thread): New function.
14852 (remove_thread): New function.
14853 (clear_inferiors): Use for_each_inferior and free_one_thread.
14854 (find_inferior): New function.
14855 (find_inferior_id): New function.
14856 (inferior_target_data): Update argument type.
14857 (set_inferior_target_data): Likewise.
14858 (inferior_regcache_data): Likewise.
14859 (set_inferior_regcache_data): Likewise.
14860 * linux-low.c (linux_bp_reinsert): Remove.
14861 (all_processes, stopping_threads, using_thrads)
14862 (struct pending_signals, debug_threads, pid_of): New.
14863 (inferior_pid): Replace with macro.
14864 (struct inferior_linux_data): Remove.
14865 (get_stop_pc, add_process): New functions.
14866 (linux_create_inferior): Restore SIGRTMIN+1 before calling exec.
14867 Use add_process and add_thread.
14868 (linux_attach_lwp): New function, based on old linux_attach. Use
14869 add_process and add_thread. Set stop_expected for new threads.
14870 (linux_attach): New function.
14871 (linux_kill_one_process): New function.
14872 (linux_kill): Kill all LWPs.
14873 (linux_thread_alive): Use find_inferior_id.
14874 (check_removed_breakpoints, status_pending_p): New functions.
14875 (linux_wait_for_process): Renamed from linux_wait_for_one_inferior.
14876 Update. Use WNOHANG. Wait for cloned processes also. Update process
14877 struct for the found process.
14878 (linux_wait_for_event): New function.
14879 (linux_wait): Use it. Support LWPs.
14880 (send_sigstop, wait_for_sigstop, stop_all_processes)
14881 (linux_resume_one_process, linux_continue_one_process): New functions.
14882 (linux_resume): Support LWPs.
14883 (REGISTER_RAW_SIZE): Remove.
14884 (fetch_register): Use register_size instead. Call supply_register.
14885 (usr_store_inferior_registers): Likewise. Call collect_register.
14886 Fix recursive case.
14887 (regsets_fetch_inferior_registers): Improve error message.
14888 (regsets_store_inferior_registers): Add debugging.
14889 (linux_look_up_symbols): Call thread_db_init if USE_THREAD_DB.
14890 (unstopped_p, linux_signal_pid): New functions.
14891 (linux_target_ops): Add linux_signal_pid.
14892 (linux_init_signals): New function.
14893 (initialize_low): Call it. Initialize using_threads.
14894 * regcache.c (inferior_regcache_data): Add valid
14896 (get_regcache): Fetch registers lazily. Add fetch argument
14897 and update all callers.
14898 (regcache_invalidate_one, regcache_invalidate): New
14900 (new_register_cache): Renamed from create_register_cache.
14901 Return the new regcache.
14902 (free_register_cache): Change argument to a void *.
14903 (registers_to_string, registers_from_string): Call get_regcache
14904 with fetch flag set.
14905 (register_data): Make static. Pass fetch flag to get_regcache.
14906 (supply_register): Call get_regcache with fetch flag clear.
14907 (collect_register): Call get_regcache with fetch flag set.
14908 (collect_register_as_string): New function.
14909 * regcache.h: Update.
14910 * remote-utils.c (putpkt): Flush after debug output and use
14912 Handle input interrupts while waiting for an ACK.
14913 (input_interrupt): Use signal_pid method.
14914 (getpkt): Flush after debug output and use stderr.
14915 (outreg): Use collect_register_as_string.
14916 (new_thread_notify, dead_thread_notify): New functions.
14917 (prepare_resume_reply): Check using_threads. Set thread_from_wait
14918 and general_thread.
14919 (look_up_one_symbol): Flush after debug output.
14920 * server.c (step_thread, server_waiting): New variables.
14921 (start_inferior): Don't use signal_pid. Update call to mywait.
14922 (attach_inferior): Update call to mywait.
14923 (handle_query): Handle qfThreadInfo and qsThreadInfo.
14924 (main): Don't fetch/store registers explicitly. Use
14925 set_desired_inferior. Support proposed ``Hs'' packet. Update
14927 * server.h: Update.
14928 (struct inferior_list, struct_inferior_list_entry): New.
14929 * target.c (set_desired_inferior): New.
14930 (write_inferior_memory): Constify.
14931 (mywait): New function.
14932 * target.h: Update.
14933 (struct target_ops): New signal_pid method.
14934 (mywait): Removed macro, added prototype.
14936 * linux-low.h (regset_func): Removed.
14937 (regset_fill_func, regset_store_func): New.
14938 (enum regset_type): New.
14939 (struct regset_info): Add type field. Use new operation types.
14940 (struct linux_target_ops): stop_pc renamed to get_pc.
14941 Add decr_pc_after_break and breakpoint_at.
14942 (get_process, get_thread_proess, get_process_thread)
14943 (strut process_info, all_processes, linux_attach_lwp)
14944 (thread_db_init): New.
14946 * linux-arm-low.c (arm_get_pc, arm_set_pc,
14947 arm_breakpoint, arm_breakpoint_len, arm_breakpoint_at): New.
14948 (the_low_target): Add new members.
14949 * linux-i386-low.c (i386_store_gregset, i386_store_fpregset)
14950 (i386_store_fpxregset): Constify.
14951 (target_regsets): Add new kind identifier.
14952 (i386_get_pc): Renamed from i386_stop_pc. Simplify.
14953 (i386_set_pc): Add debugging.
14954 (i386_breakpoint_at): New function.
14955 (the_low_target): Add new members.
14956 * linux-mips-low.c (mips_get_pc, mips_set_pc)
14957 (mips_breakpoint, mips_breakpoint_len, mips_reinsert_addr)
14958 (mips_breakpoint_at): New.
14959 (the_low_target): Add new members.
14960 * linux-ppc-low.c (ppc_get_pc, ppc_set_pc)
14961 (ppc_breakpoint, ppc_breakpoint_len, ppc_breakpoint_at): New.
14962 (the_low_target): Add new members.
14963 * linux-sh-low.c (sh_get_pc, sh_set_pc)
14964 (sh_breakpoint, sh_breakpoint_len, sh_breakpoint_at): New.
14965 (the_low_target): Add new members.
14966 * linux-x86-64-low.c (target_regsets): Add new kind
14969 2002-05-15 Daniel Jacobowitz <drow@mvista.com>
14971 From Martin Pool <mbp@samba.org>:
14972 * server.c (gdbserver_usage): New function.
14975 2002-05-14 Daniel Jacobowitz <drow@mvista.com>
14977 * mem-break.c (reinsert_breakpoint_by_bp): Correct typo
14978 stop_at -> stop_pc.
14980 2002-05-04 Andrew Cagney <ac131313@redhat.com>
14982 * Makefile.in: Remove obsolete code.
14984 2002-04-24 Michal Ludvig <mludvig@suse.cz>
14986 * linux-low.c (regsets_fetch_inferior_registers),
14987 (regsets_store_inferior_registers): Removed cast to int from
14989 * regcache.h: Added declaration of struct inferior_info.
14991 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
14993 * inferiors.c (struct inferior_info): Add regcache_data.
14994 (add_inferior): Call create_register_cache.
14995 (clear_inferiors): Call free_register_cache.
14996 (inferior_regcache_data, set_inferior_regcache_data): New functions.
14997 * regcache.c (struct inferior_regcache_data): New.
14998 (registers): Remove.
14999 (get_regcache): New function.
15000 (create_register_cache, free_register_cache): New functions.
15001 (set_register_cache): Don't initialize the register cache here.
15002 (registers_to_string, registers_from_string, register_data): Call
15004 * regcache.h: Add prototypes.
15005 * server.h: Likewise.
15007 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
15009 * mem-break.c: New file.
15010 * mem-break.h: New file.
15011 * Makefile.in: Add mem-break.o rule; update server.h
15013 * inferiors.c (struct inferior_info): Add target_data
15015 (clear_inferiors): Free target_data member if set.
15016 (inferior_target_data, set_inferior_target_data): New functions.
15017 * linux-i386-low.c (i386_breakpoint, i386_breakpoint_len)
15018 (i386_stop_pc, i386_set_pc): New. Add to the_low_target.
15019 * linux-low.c (linux_bp_reinsert): New variable.
15020 (struct inferior_linux_data): New.
15021 (linux_create_inferior): Use set_inferior_target_data.
15022 (linux_attach): Likewise. Call add_inferior.
15023 (linux_wait_for_one_inferior): New function.
15024 (linux_wait): Call it.
15025 (linux_write_memory): Add const.
15026 (initialize_low): Call set_breakpoint_data.
15027 * linux-low.h (struct linux_target_ops): Add breakpoint
15029 * server.c (attach_inferior): Remove extra add_inferior
15031 * server.h: Include mem-break.h. Update inferior.c
15033 * target.c (read_inferior_memory)
15034 (write_inferior_memory): New functions.
15035 * target.h (read_inferior_memory)
15036 (write_inferior_memory): Change macros to prototypes.
15037 (struct target_ops): Update comments. Add const to write_memory
15040 2002-04-11 Daniel Jacobowitz <drow@mvista.com>
15042 * linux-low.c (usr_store_inferior_registers): Support
15043 registers which are allowed to fail to store.
15044 * linux-low.h (linux_target_ops): Likewise.
15045 * linux-ppc-low.c (ppc_regmap): Support FPSCR.
15046 (ppc_cannot_store_register): FPSCR may not be storable.
15048 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
15050 * server.h: Include <string.h> if HAVE_STRING_H.
15051 * ChangeLog: Correct paths in last ChangeLog entry.
15053 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
15055 * linux-low.h: Remove obsolete prototypes.
15056 (struct linux_target_ops): New.
15057 (extern the_low_target): New.
15058 * linux-low.c (num_regs, regmap): Remove declarations.
15059 (register_addr): Use the_low_target explicitly.
15060 (fetch_register): Likewise.
15061 (usr_fetch_inferior_registers): Likewise.
15062 (usr_store_inferior_registers): Likewise.
15063 * linux-arm-low.c (num_regs): Remove.
15064 (arm_num_regs): Define.
15065 (arm_regmap): Renamed from regmap, made static.
15066 (arm_cannot_fetch_register): Renamed from cannot_fetch_register,
15068 (arm_cannot_store_register): Renamed from cannot_store_register,
15070 (the_low_target): New.
15071 * linux-i386-low.c (num_regs): Remove.
15072 (i386_num_regs): Define.
15073 (i386_regmap): Renamed from regmap, made static.
15074 (i386_cannot_fetch_register): Renamed from cannot_fetch_register,
15076 (i386_cannot_store_register): Renamed from cannot_store_register,
15078 (the_low_target): New.
15079 * linux-ia64-low.c (num_regs): Remove.
15080 (ia64_num_regs): Define.
15081 (ia64_regmap): Renamed from regmap, made static.
15082 (ia64_cannot_fetch_register): Renamed from cannot_fetch_register,
15084 (ia64_cannot_store_register): Renamed from cannot_store_register,
15086 (the_low_target): New.
15087 * linux-m68k-low.c (num_regs): Remove.
15088 (m68k_num_regs): Define.
15089 (m68k_regmap): Renamed from regmap, made static.
15090 (m68k_cannot_fetch_register): Renamed from cannot_fetch_register,
15092 (m68k_cannot_store_register): Renamed from cannot_store_register,
15094 (the_low_target): New.
15095 * linux-mips-low.c (num_regs): Remove.
15096 (mips_num_regs): Define.
15097 (mips_regmap): Renamed from regmap, made static.
15098 (mips_cannot_fetch_register): Renamed from cannot_fetch_register,
15100 (mips_cannot_store_register): Renamed from cannot_store_register,
15102 (the_low_target): New.
15103 * linux-ppc-low.c (num_regs): Remove.
15104 (ppc_num_regs): Define.
15105 (ppc_regmap): Renamed from regmap, made static.
15106 (ppc_cannot_fetch_register): Renamed from cannot_fetch_register,
15108 (ppc_cannot_store_register): Renamed from cannot_store_register,
15110 (the_low_target): New.
15111 * linux-s390-low.c (num_regs): Remove.
15112 (s390_num_regs): Define.
15113 (s390_regmap): Renamed from regmap, made static.
15114 (s390_cannot_fetch_register): Renamed from cannot_fetch_register,
15116 (s390_cannot_store_register): Renamed from cannot_store_register,
15118 (the_low_target): New.
15119 * linux-sh-low.c (num_regs): Remove.
15120 (sh_num_regs): Define.
15121 (sh_regmap): Renamed from regmap, made static.
15122 (sh_cannot_fetch_register): Renamed from cannot_fetch_register,
15124 (sh_cannot_store_register): Renamed from cannot_store_register,
15126 (the_low_target): New.
15127 * linux-x86-64-low.c (x86_64_regmap): Renamed from regmap.
15128 (the_low_target): New.
15130 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
15132 * Makefile.in: Add stamp-h target.
15133 * configure.in: Create stamp-h.
15134 * configure: Regenerated.
15136 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
15138 * inferiors.c: New file.
15139 * target.c: New file.
15140 * target.h: New file.
15141 * Makefile.in: Add target.o and inferiors.o. Update
15143 * linux-low.c (inferior_pid): New static variable,
15144 moved from server.c.
15145 (linux_create_inferior): Renamed from create_inferior.
15146 Call add_inferior. Return 0 on success instead of a PID.
15147 (linux_attach): Renamed from myattach.
15148 (linux_kill): Renamed from kill_inferior. Call clear_inferiors ().
15149 (linux_thread_alive): Renamed from mythread_alive.
15150 (linux_wait): Renamed from mywait. Call clear_inferiors () if the
15152 (linux_resume): Renamed from myresume. Add missing ``return 0''.
15153 (regsets_store_inferior_registers): Correct error message.
15154 Add missing ``return 0''.
15155 (linux_fetch_registers): Renamed from fetch_inferior_registers.
15156 (linux_store_registers): Renamed from store_inferior_registers.
15157 (linux_read_memory): Renamed from read_inferior_memory.
15158 (linux_write_memory): Renamed from write_inferior_memory.
15159 (linux_target_ops): New structure.
15160 (initialize_low): Call set_target_ops ().
15161 * remote-utils.c (unhexify): New function.
15162 (hexify): New function.
15163 (input_interrupt): Send signals to ``signal_pid''.
15164 * server.c (inferior_pid): Remove.
15165 (start_inferior): Update create_inferior call.
15166 (attach_inferior): Call add_inferior.
15167 (handle_query): New function.
15168 (main): Call handle_query for `q' packets.
15169 * server.h: Include "target.h". Remove obsolete prototypes.
15170 Add prototypes for "inferiors.c", "target.c", hexify, and unhexify.
15172 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
15174 * Makefile.in: Add WARN_CFLAGS. Update configury
15176 * configure.in: Check for <string.h>
15177 * configure: Regenerate.
15178 * config.in: Regenerate.
15179 * gdbreplay.c: Include needed system headers.
15180 (remote_open): Remove strchr prototype.
15181 * linux-low.h: Correct #ifdef to HAVE_LINUX_USRREGS.
15182 * regcache.c (supply_register): Change buf argument to const void *.
15183 (supply_register_by_name): Likewise.
15184 (collect_register): Change buf argument to void *.
15185 (collect_register_by_name): Likewise.
15186 * regcache.h: Add missing prototypes.
15187 * remote-utils.c: Include <arpa/inet.h> for inet_ntoa.
15188 * server.c (handle_query): New function.
15189 (attached): New static variable, moved out of main.
15190 (main): Quiet longjmp clobber warnings.
15191 * server.h: Add ATTR_NORETURN and ATTR_FORMAT. Update prototypes.
15192 * utils.c (error): Remove NORETURN.