[GDBserver] Use pre-generated tdesc as test
[deliverable/binutils-gdb.git] / gdb / gdbserver / ChangeLog
CommitLineData
25a93583
YQ
12017-09-05 Yao Qi <yao.qi@linaro.org>
2
3 * configure.srv: Set srv_i386_linux_regobj empty if $development
4 is false.
5 * linux-i386-ipa.c (initialize_low_tracepoint): Don't call
6 initialize_low_tdesc.
7 * linux-x86-low.c (initialize_low_arch): Wrap initialize_low_tdesc
8 with #if initialize_low_tdesc.
9 * linux-x86-tdesc-selftest.c: New file.
10 * linux-x86-tdesc.c: Move code to linux-x86-tdesc-selftest.c.
11
5f035c07
YQ
122017-09-05 Yao Qi <yao.qi@linaro.org>
13
14 * Makefile.in (arch-i386.o): New rule.
15 * configure.srv (i[34567]86-*-linux*): Add arch-i386.o.
16 (x86_64-*-linux*): Likewise.
17 * linux-x86-tdesc.c: Don't include ../features/i386/32bit-XXX.c,
18 include arch/i386.h.
19 (i386_linux_read_description): Remove code and call
20 i386_create_target_description.
21 * tdesc.c (allocate_target_description): New function.
22 * tdesc.h (set_tdesc_architecture): Remove declaration.
23 (set_tdesc_osabi): Likewise.
24
0abe8a89
YQ
252017-09-05 Yao Qi <yao.qi@linaro.org>
26
27 * linux-x86-tdesc.c: Don't include <inttypes.h>.
28 (i386_linux_read_description) [!IN_PROCESS_AGENT]: Call
29 set_tdesc_architecture and set_tdesc_osabi. Remove code setting
30 .xmltarget.
31 * server.c (get_features_xml): Call tdesc_get_features_xml.
32 * tdesc.c (set_tdesc_architecture): New function.
33 (set_tdesc_osabi): New function.
34 (tdesc_get_features_xml): New function.
35 (tdesc_create_feature): Add an argument.
36 * tdesc.h (struct target_desc) <features>: New field.
37 <arch, osabi>: New field.
38 (~target_desc): xfree features, arch, and osabi.
39 (target_desc::oerator==): Don't compare .xmltarget.
40 [!IN_PROCESS_AGENT] (set_tdesc_architecture): Declare.
41 (set_tdesc_osabi): Likewise.
42 (tdesc_get_features_xml): Likewise.
43
0a188386
YQ
442017-09-05 Yao Qi <yao.qi@linaro.org>
45
46 * linux-x86-tdesc.c: Include selftest.h.
47 (i386_tdesc_test): New function.
48 (initialize_low_tdesc): Call selftests::register_test.
49 * tdesc.h: Include regdef.h.
50 (target_desc): Override operator == and !=.
51
f49ff000
YQ
522017-09-05 Yao Qi <yao.qi@linaro.org>
53
54 * configure.srv (srv_tgtobj): Append linux-x86-tdesc.o.
55 (ipa_obj): Likewise.
56 * linux-i386-ipa.c: Include common/x86-xstate.h
57 (get_ipa_tdesc): Call i386_linux_read_description.
58 (initialize_low_tracepoint): Don't call init_registers_XXX
59 functions, call initialize_low_tdesc instead.
60 * linux-x86-low.c (x86_linux_read_description): Call
61 i386_linux_read_description.
62 (initialize_low_arch): Don't call init_registers_i386_XXX
63 functions, call initialize_low_tdesc.
64 * linux-x86-tdesc.c: New file.
65 * linux-x86-tdesc.h (x86_linux_tdesc): New X86_TDESC_LAST.
66 (i386_get_ipa_tdesc_idx): Declare.
67 (i386_get_ipa_tdesc): Declare.
68 (initialize_low_tdesc): Declare.
69
2b68ef2f
YQ
702017-09-05 Yao Qi <yao.qi@linaro.org>
71
72 * linux-x86-low.c (x86_get_ipa_tdesc_idx): Use X86_TDESC_MMX
73 instead of 0.
74
f7000548
YQ
752017-09-05 Yao Qi <yao.qi@linaro.org>
76
77 * Makefile.in (IPA_OBJS): Add vec-ipa.o
78 * regcache.c (get_thread_regcache): Use VEC_length.
79 (init_register_cache): Likewise.
80 (regcache_cpy): Likewise.
81 (registers_to_string): Iterate reg_defs via VEC_iterate.
82 (find_regno): Likewise.
83 (find_register_by_number): Use VEC_index.
84 (register_size): Call find_register_by_number.
85 (register_data): Call find_register_by_number.
86 (supply_regblock): Use VEC_length.
87 (regcache_raw_read_unsigned): Likewise.
88 * tdesc.c (init_target_desc): Iterate reg_defs via
89 VEC_iterate.
90 (default_description): Update initializer.
91 (copy_target_description): Don't update field num_registers.
92 * tdesc.h (struct target_desc) <reg_defs>: Change it to VEC.
93 <num_registers>: Remove.
94
50a421ac
SM
952017-09-04 Simon Marchi <simon.marchi@ericsson.com>
96
97 * Makefile.in (.SECONDARY): Define target.
98
23fdd69e
SM
992017-09-03 Simon Marchi <simon.marchi@ericsson.com>
100
101 * linux-low.c (linux_wait_1): Adjust.
102 * server.c (queue_stop_reply_callback): Adjust.
103
0a2dde4a
SDJ
1042017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
105
106 * server.c (handle_general_set): Handle QEnvironmentHexEncoded,
107 QEnvironmentUnset and QEnvironmentReset packets.
108 (handle_query): Inform remote that QEnvironmentHexEncoded,
109 QEnvironmentUnset and QEnvironmentReset are supported.
110
6afd337d
SM
1112017-08-25 Simon Marchi <simon.marchi@ericsson.com>
112
113 * inferiors.h (inferior_target_data): Rename to ...
114 (thread_target_data): ... this.
115 (inferior_regcache_data): Rename to ...
116 (thread_regcache_data): ... this.
117 (set_inferior_regcache_data): Rename to ...
118 (set_thread_regcache_data): ... this.
119 * inferiors.c (inferior_target_data): Rename to ...
120 (thread_target_data): ... this.
121 (inferior_regcache_data): Rename to ...
122 (thread_regcache_data): ... this.
123 (set_inferior_regcache_data): Rename to ...
124 (set_thread_regcache_data): ... this.
125 (free_one_thread): Update.
126 * linux-low.h (get_thread_lwp): Update.
127 * regcache.c (get_thread_regcache): Update.
128 (regcache_invalidate_thread): Update.
129 (free_register_cache_thread): Update.
130 * win32-i386-low.c (update_debug_registers_callback): Update.
131 (win32_get_current_dr): Update.
132 * win32-low.c (thread_rec): Update.
133 (delete_thread_info): Update.
134 (continue_one_thread): Update.
135 (suspend_one_thread): Update.
136
a160cc46
SM
1372017-08-24 Simon Marchi <simon.marchi@ericsson.com>
138
139 * inferiors.c (set_inferior_target_data): Remove.
140 * inferiors.h (set_inferior_target_data): Remove.
141
6d580b63
YQ
1422017-08-18 Yao Qi <yao.qi@linaro.org>
143
144 * Makefile.in (OBS): Add selftest.o.
145 * configure.ac: AC_DEFINE GDB_SELF_TEST if $development.
146 * configure, config.in: Re-generated.
147 * server.c: Include common/sefltest.h.
148 (captured_main): Handle option --selftest.
149
f5a29eb0
YQ
1502017-08-09 Yao Qi <yao.qi@linaro.org>
151
152 * configure.srv (srv_i386_regobj): Remove i386-avx.o,
153 i386-avx-avx512.o, i386-avx-mpx-avx512-pku.o, i386-mpx.o,
154 i386-avx-mpx.o and i386-mmx.o.
155 (srv_amd64_regobj): Remove amd64-avx.o, amd64-avx-avx512.o,
156 amd64-avx-mpx-avx512-pku.o, amd64-mpx.o and amd64-avx-mpx.o.
157 (srv_i386_xmlfiles): Remove i386/i386-avx.xml,
158 i386/i386-avx-avx512.xml, i386/i386-avx-mpx-avx512-pku.xml,
159 i386/i386-mpx.xml, i386/i386-avx-mpx.xml and i386/i386-mmx.xml.
160 (srv_amd64_xmlfile):i386/amd64-avx.xml, i386/amd64-avx-avx512.xml,
161 i386/amd64-avx-mpx-avx512-pku.xml, i386/amd64-mpx.xml,
162 i386/amd64-avx-mpx.xml.
163
57757c2f
YQ
1642017-08-09 Yao Qi <yao.qi@linaro.org>
165
166 * configure.srv (srv_amd64_regobj): Remove x32.o, x32-avx.o
167 and x32-avx-avx512.o.
168 (srv_amd64_xmlfiles): Remove i386/x32.xml, i386/x32-avx.xml
169 i386/x32-avx-avx512.xml.
170
229d26fc
SM
1712017-07-26 Simon Marchi <simon.marchi@ericsson.com>
172
173 * tracepoint.h (enum class fast_tpoint_collect_result): New
174 enumeration.
175 (fast_tracepoint_collecting): Change return type to
176 fast_tpoint_collect_result.
177 * tracepoint.c (fast_tracepoint_collecting): Likewise.
178 * linux-low.h: Include tracepoint.h.
179 (struct lwp_info) <collecting_fast_tracepoint>: Change type to
180 fast_tpoint_collect_result.
181 * linux-low.c (handle_tracepoints): Adjust.
182 (linux_fast_tracepoint_collecting): Change return type to
183 fast_tpoint_collect_result.
184 (maybe_move_out_of_jump_pad, linux_wait_for_event_filtered,
185 linux_wait_1, stuck_in_jump_pad_callback,
186 lwp_signal_can_be_delivered, linux_resume_one_lwp_throw,
187 proceed_one_lwp): Adjust to type change.
188
2e1e43e1
YQ
1892017-07-10 Yao Qi <yao.qi@linaro.org>
190
191 * linux-x86-low.c (x86_linux_read_description): Re-indent the code.
192
adc764e7
YQ
1932017-06-29 Yao Qi <yao.qi@linaro.org>
194
195 * tdesc.h (struct target_desc) [IN_PROCESS_AGENT] <expedite_regs>:
196 Remove.
197 [IN_PROCESS_AGENT] <xmltarget>: Likewise.
198
a206891a
SM
1992017-06-20 Simon Marchi <simon.marchi@ericsson.com>
200
201 * Makefile.in (IPA_OBJS): Sort and format one item per line.
202
9a6c7d9c
SDJ
2032017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
204
205 * linux-low.c (linux_create_inferior): Adjust code to access the
206 environment information via 'gdb_environ' class.
207 * lynx-low.c (lynx_create_inferior): Likewise.
208 * server.c (our_environ): Make it an instance of 'gdb_environ'.
209 (get_environ): Return a pointer to 'our_environ'.
210 (captured_main): Initialize 'our_environ'.
211 * server.h (get_environ): Adjust prototype.
212 * spu-low.c (spu_create_inferior): Adjust code to access the
213 environment information via 'gdb_environ' class.
214
ae3e2ccf
SM
2152017-06-17 Simon Marchi <simon.marchi@ericsson.com>
216
217 * linux-low.c (linux_read_memory, linux_write_memory): Remove
218 usage of "register" keyword.
219
3e019bdc
SM
2202017-06-17 Simon Marchi <simon.marchi@ericsson.com>
221
222 * configure: Re-generate.
223
8465943a
SM
2242017-06-17 Simon Marchi <simon.marchi@ericsson.com>
225
226 * configure: Re-generate.
227
cf0dd6f0
SM
2282017-06-17 Simon Marchi <simon.marchi@ericsson.com>
229
230 * Makefile.in (COMPILE.pre): Add "-x c++".
231
9845682b
SDJ
2322017-06-09 Sergio Durigan Junior <sergiodj@redhat.com>
233
234 * fork-child.c: Conditionally include <signal.h>.
235
aefd8b33
SDJ
2362017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
237
238 * server.c (handle_general_set): Handle new packet
239 "QStartupWithShell".
240 (handle_query): Add "QStartupWithShell" to the list of supported
241 packets.
242 (gdbserver_usage): Add help text explaining the
243 new "--startup-with-shell" and "--no-startup-with-shell" CLI
244 options.
245 (captured_main): Recognize and act upon the presence of the new
246 CLI options.
247
2090129c
SDJ
2482017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
249 Pedro Alves <palves@redhat.com>
250
251 * Makefile.in (SFILES): Add "nat/fork-inferior.o".
252 * configure: Regenerate.
253 * configure.srv (srv_linux_obj): Add "fork-child.o" and
254 "fork-inferior.o".
255 (i[34567]86-*-lynxos*): Likewise.
256 (spu*-*-*): Likewise.
257 * fork-child.c: New file.
258 * linux-low.c: Include "common-inferior.h", "nat/fork-inferior.h"
259 and "environ.h".
260 (linux_ptrace_fun): New function.
261 (linux_create_inferior): Adjust function prototype to reflect
262 change on "target.h". Adjust function code to use
263 "fork_inferior".
264 (linux_request_interrupt): Delete "signal_pid".
265 * lynx-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
266 (lynx_ptrace_fun): New function.
267 (lynx_create_inferior): Adjust function prototype to reflect
268 change on "target.h". Adjust function code to use
269 "fork_inferior".
270 * nto-low.c (nto_create_inferior): Adjust function prototype and
271 code to reflect change on "target.h". Update comments.
272 * server.c: Include "common-inferior.h", "nat/fork-inferior.h",
273 "common-terminal.h" and "environ.h".
274 (terminal_fd): Moved to fork-child.c.
275 (old_foreground_pgrp): Likewise.
276 (restore_old_foreground_pgrp): Likewise.
277 (last_status): Make it global.
278 (last_ptid): Likewise.
279 (our_environ): New variable.
280 (startup_with_shell): Likewise.
281 (program_name): Likewise.
282 (program_argv): Rename to...
283 (program_args): ...this.
284 (wrapper_argv): New variable.
285 (start_inferior): Delete function.
286 (get_exec_wrapper): New function.
287 (get_exec_file): Likewise.
288 (get_environ): Likewise.
289 (prefork_hook): Likewise.
290 (post_fork_inferior): Likewise.
291 (postfork_hook): Likewise.
292 (postfork_child_hook): Likewise.
293 (handle_v_run): Update code to deal with arguments coming from the
294 remote host. Update calls from "start_inferior" to
295 "create_inferior".
296 (captured_main): Likewise. Initialize environment variable. Call
297 "have_job_control".
298 * server.h (post_fork_inferior): New prototype.
299 (get_environ): Likewise.
300 (last_status): Declare.
301 (last_ptid): Likewise.
302 (signal_pid): Likewise.
303 * spu-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
304 (spu_ptrace_fun): New function.
305 (spu_create_inferior): Adjust function prototype to reflect change
306 on "target.h". Adjust function code to use "fork_inferior".
307 * target.c (target_terminal_init): New function.
308 (target_terminal_inferior): Likewise.
309 (target_terminal_ours): Likewise.
310 * target.h: Include <vector>.
311 (struct target_ops) <create_inferior>: Update prototype.
312 (create_inferior): Update macro.
313 * utils.c (gdb_flush_out_err): New function.
314 * win32-low.c (win32_create_inferior): Adjust function prototype
315 and code to reflect change on "target.h".
316
043a4934
SDJ
3172017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
318
319 * inferiors.c (switch_to_thread): New function.
320
15652511
SDJ
3212017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
322
323 * Makefile.in (SFILE): Add "common/job-control.c".
324 (OBS): Add "job-control.o".
325
21ea5acd
SDJ
3262017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
327
328 * Makefile: Remove "@host_makefile_frag@".
329
e13cb306
PA
3302017-05-05 Pedro Alves <palves@redhat.com>
331
332 * configure: Regenerate.
333
c94fee56
SDJ
3342017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
335
336 * configure: Regenerate.
337
a0ff9e1a
SM
3382017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
339
340 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Adjust to
341 software_single_step change of return type to
342 std::vector<CORE_ADDR>.
343 * linux-low.c (install_software_single_step_breakpoints):
344 Likewise.
345 * linux-low.h (install_software_single_step_breakpoints):
346 Likewise.
347
be628ab8
SDJ
3482017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
349
350 * remote-utils.c: Include "gdb_termios.h" instead of
351 "terminal.h".
352 * terminal.h: Delete file.
353
7c5ded6a
SDJ
3542017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
355
356 * server.c: Include <vector>.
357 <program_argv, wrapper_argv>: Convert to std::vector.
358 (start_inferior): Rewrite function to use C++.
359 (handle_v_run): Likewise. Update code that calculates the argv
360 based on the vRun packet; use C++.
361 (captured_main): Likewise.
362
436252de
SM
3632017-04-06 Simon Marchi <simon.marchi@ericsson.com>
364
365 * server.c (handle_v_cont): Initialize thread_resume::thread
366 with null_ptid.
367
9bf2a700
PA
3682017-04-05 Pedro Alves <palves@redhat.com>
369
370 * configure: Regenerate.
371
a121b7c1
PA
3722017-04-05 Pedro Alves <palves@redhat.com>
373
374 * gdbreplay.c (sync_error): Constify.
375 * linux-x86-low.c (push_opcode): Constify.
376
21c8a587
PA
3772017-04-05 Pedro Alves <palves@redhat.com>
378
379 * win32-low.c (get_child_debug_event)
380 <CREATE_PROCESS_DEBUG_EVENT>: Don't report TARGET_WAITKIND_EXECD.
381 Report TARGET_WAITKIND_SPURIOUS instead.
382
fb32b4f7
PA
3832017-04-05 Pedro Alves <palves@redhat.com>
384
385 * remote-utils.c (remote_prepare, remote_open): Constify.
386 * remote-utils.h (remote_prepare, remote_open): Constify.
387 * server.c (captured_main): Constify 'port' handling.
388
65dd1e59
SM
3892017-04-04 Simon Marchi <simon.marchi@ericsson.com>
390
391 * Makefile.in (clean): Clear .deps.
392
8fa5b777
SM
3932017-03-31 Simon Marchi <simon.marchi@polymtl.ca>
394
395 * .gitignore: Remove generated files, replace with wildcard.
396 * (clean): Replace removal of generated files with wildcard.
397 (version.c): Replace with...
398 (version-generated.c): ...this.
399 (xml-builtin.c): Replace with...
400 (xml-builtin-generated.c): ...this.
401 (%-ipa.o: %-generated.c, %.o: %-generated.c): New rules.
402 (%.c: *regformats*): Replace with...
403 (%-generated.c: *regformats*): ...this.
404
a12e714b
MF
4052017-03-27 Max Filippov <jcmvbkbc@gmail.com>
406
407 * linux-xtensa-low.c (regnum::R_THREADPTR): New enum member.
408 (xtensa_fill_gregset): Call collect_register_by_name for
409 threadptr register.
410 (xtensa_store_gregset): Call supply_register_by_name for
411 threadptr register.
412
1a09b50a
MF
4132017-03-27 Max Filippov <jcmvbkbc@gmail.com>
414
415 * linux-xtensa-low.c (xtensa_fill_gregset): Call collect_register
416 for all registers in a0_regnum..a0_regnum + C0_NREGS range.
417 (xtensa_store_gregset): Call supply_register for all registers in
418 a0_regnum..a0_regnum + C0_NREGS range.
419
1a01e7c6
SM
4202017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
421
422 * Makefile.in (%-ipa.o: %-ipa.c): New rule.
423 (ax-ipa.o: ax.c): Remove.
424 (linux-i386-ipa.o: linux-i386-ipa.c): Remove.
425 (linux-amd64-ipa.o: linux-amd64-ipa.c): Remove.
426 (linux-aarch64-ipa.o: linux-aarch64-ipa.c): Remove.
427 (linux-s390-ipa.o: linux-s390-ipa.c): Remove.
428 (linux-ppc-ipa.o: linux-ppc-ipa.c): Remove.
429
36bc18a8
SM
4302017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
431
432 * Makefile.in (%-ipa.o: ../common/%.c): New rule.
433 (print-utils-ipa.o: ../common/print-utils.c): Remove.
434 (rsp-low-ipa.o: ../common/rsp-low.c): Remove.
435 (errors-ipa.o: ../common/errors.c): Remove.
436 (format-ipa.o: ../common/format.c): Remove.
437 (common-utils-ipa.o: ../common/common-utils.c): Remove.
438
a8ebe3d5
SM
4392017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
440
441 * Makefile.in (%-ipa.o: %.c): New rule.
442 (tracepoint-ipa.o: tracepoint.c): Remove.
443 (utils-ipa.o: utils.c): Remove.
444 (remote-utils-ipa.o: remote-utils.c): Remove.
445 (regcache-ipa.o: regcache.c): Remove.
446 (i386-linux-ipa.o: i386-linux.c): Remove.
447 (i386-mmx-linux-ipa.o: i386-mmx-linux.c): Remove.
448 (i386-avx-linux-ipa.o: i386-avx-linux.c): Remove.
449 (i386-mpx-linux-ipa.o: i386-mpx-linux.c): Remove.
450 (i386-avx-mpx-linux-ipa.o: i386-avx-mpx-linux.c): Remove.
451 (i386-avx-avx512-linux-ipa.o: i386-avx-avx512-linux.c): Remove.
452 (i386-avx-mpx-avx512-pku-linux-ipa.o: i386-avx-mpx-avx512-pku-linux.c): Remove.
453 (amd64-linux-ipa.o: amd64-linux.c): Remove.
454 (amd64-avx-linux-ipa.o: amd64-avx-linux.c): Remove.
455 (amd64-mpx-linux-ipa.o: amd64-mpx-linux.c): Remove.
456 (amd64-avx-mpx-linux-ipa.o: amd64-avx-mpx-linux.c): Remove.
457 (amd64-avx-avx512-linux-ipa.o: amd64-avx-avx512-linux.c): Remove.
458 (amd64-avx-mpx-avx512-pku-linux-ipa.o: amd64-avx-mpx-avx512-pku-linux.c): Remove.
459 (aarch64-ipa.o: aarch64.c): Remove.
460 (s390-linux32-ipa.o: s390-linux32.c): Remove.
461 (s390-linux32v1-ipa.o: s390-linux32v1.c): Remove.
462 (s390-linux32v2-ipa.o: s390-linux32v2.c): Remove.
463 (s390-linux64-ipa.o: s390-linux64.c): Remove.
464 (s390-linux64v1-ipa.o: s390-linux64v1.c): Remove.
465 (s390-linux64v2-ipa.o: s390-linux64v2.c): Remove.
466 (s390-te-linux64-ipa.o: s390-te-linux64.c): Remove.
467 (s390-vx-linux64-ipa.o: s390-vx-linux64.c): Remove.
468 (s390-tevx-linux64-ipa.o: s390-tevx-linux64.c): Remove.
469 (s390x-linux64-ipa.o: s390x-linux64.c): Remove.
470 (s390x-linux64v1-ipa.o: s390x-linux64v1.c): Remove.
471 (s390x-linux64v2-ipa.o: s390x-linux64v2.c): Remove.
472 (s390x-te-linux64-ipa.o: s390x-te-linux64.c): Remove.
473 (s390x-vx-linux64-ipa.o: s390x-vx-linux64.c): Remove.
474 (s390x-tevx-linux64-ipa.o: s390x-tevx-linux64.c): Remove.
475 (powerpc-32l-ipa.o: powerpc-32l.c): Remove.
476 (powerpc-altivec32l-ipa.o: powerpc-altivec32l.c): Remove.
477 (powerpc-cell32l-ipa.o: powerpc-cell32l.c): Remove.
478 (powerpc-vsx32l-ipa.o: powerpc-vsx32l.c): Remove.
479 (powerpc-isa205-32l-ipa.o: powerpc-isa205-32l.c): Remove.
480 (powerpc-isa205-altivec32l-ipa.o: powerpc-isa205-altivec32l.c): Remove.
481 (powerpc-isa205-vsx32l-ipa.o: powerpc-isa205-vsx32l.c): Remove.
482 (powerpc-e500l-ipa.o: powerpc-e500l.c): Remove.
483 (powerpc-64l-ipa.o: powerpc-64l.c): Remove.
484 (powerpc-altivec64l-ipa.o: powerpc-altivec64l.c): Remove.
485 (powerpc-cell64l-ipa.o: powerpc-cell64l.c): Remove.
486 (powerpc-vsx64l-ipa.o: powerpc-vsx64l.c): Remove.
487 (powerpc-isa205-64l-ipa.o: powerpc-isa205-64l.c): Remove.
488 (powerpc-isa205-altivec64l-ipa.o: powerpc-isa205-altivec64l.c): Remove.
489 (powerpc-isa205-vsx64l-ipa.o: powerpc-isa205-vsx64l.c): Remove.
490 (tdesc-ipa.o: tdesc.c): Remove.
491 (x32-linux-ipa.o: x32-linux.c): Remove.
492 (x32-avx-linux-ipa.o: x32-avx-linux.c): Remove.
493 (x32-avx512-linux-ipa.o: x32-avx512-linux.c): Remove.
494
50cfacb7
SM
4952017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
496
497 * Makefile.in (%.o: ../arch/%.c): New rule.
498 (arm.o: ../arch/arm.c): Remove.
499 (arm-linux.o: ../arch/arm-linux.c): Remove.
500 (arm-get-next-pcs.o: ../arch/arm-get-next-pcs.c): Remove.
501 (aarch64-insn.o: ../arch/aarch64-insn.c): Remove.
502
c5a22423
SM
5032017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
504
505 * Makefile.in (%.o: ../nat/%.c): New rule.
506 (x86-dregs.o: ../nat/x86-dregs.c): Remove.
507 (amd64-linux-siginfo.o: ../nat/amd64-linux-siginfo.c): Remove.
508 (linux-btrace.o: ../nat/linux-btrace.c): Remove.
509 (linux-osdata.o: ../nat/linux-osdata.c): Remove.
510 (linux-procfs.o: ../nat/linux-procfs.c): Remove.
511 (linux-ptrace.o: ../nat/linux-ptrace.c): Remove.
512 (linux-waitpid.o: ../nat/linux-waitpid.c): Remove.
513 (mips-linux-watch.o: ../nat/mips-linux-watch.c): Remove.
514 (ppc-linux.o: ../nat/ppc-linux.c): Remove.
515 (linux-personality.o: ../nat/linux-personality.c): Remove.
516 (aarch64-linux-hw-point.o: ../nat/aarch64-linux-hw-point.c): Remove.
517 (aarch64-linux.o: ../nat/aarch64-linux.c): Remove.
518 (x86-linux.o: ../nat/x86-linux.c): Remove.
519 (x86-linux-dregs.o: ../nat/x86-linux-dregs.c): Remove.
520 (linux-namespaces.o: ../nat/linux-namespaces.c): Remove.
521
6bda016b
SM
5222017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
523
524 * Makefile.in (%.o: ../common/%.c): New rule.
525 (signals.o: ../common/signals.c): Remove.
526 (print-utils.o: ../common/print-utils.c): Remove.
527 (rsp-low.o: ../common/rsp-low.c): Remove.
528 (common-utils.o: ../common/common-utils.c): Remove.
529 (posix-strerror.o: ../common/posix-strerror.c): Remove.
530 (mingw-strerror.o: ../common/mingw-strerror.c): Remove.
531 (vec.o: ../common/vec.c): Remove.
532 (gdb_vecs.o: ../common/gdb_vecs.c): Remove.
533 (xml-utils.o: ../common/xml-utils.c): Remove.
534 (ptid.o: ../common/ptid.c): Remove.
535 (buffer.o: ../common/buffer.c): Remove.
536 (format.o: ../common/format.c): Remove.
537 (filestuff.o: ../common/filestuff.c): Remove.
538 (agent.o: ../common/agent.c): Remove.
539 (errors.o: ../common/errors.c): Remove.
540 (environ.o: ../common/environ.c): Remove.
541 (common-debug.o: ../common/common-debug.c): Remove.
542 (cleanups.o: ../common/cleanups.c): Remove.
543 (common-exceptions.o: ../common/common-exceptions.c): Remove.
544 (fileio.o: ../common/fileio.c): Remove.
545 (common-regcache.o: ../common/common-regcache.c): Remove.
546 (signals-state-save-restore.o: ../common/signals-state-save-restore.c): Remove.
547 (new-op.o: ../common/new-op.c): Remove.
548 (btrace-common.o: ../common/btrace-common.c): Remove.
549
21122961
SM
5502017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
551
552 * Makefile.in (%.o: ../target/%.c): New rule.
553 (waitstatus.o: ../target/waitstatus.c): Remove.
554
c362e621
SM
5552017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
556
557 * Makefile.in
558 (%.c: ../regformats/%.dat,
559 (%.c: ../regformats/arm/%.dat,
560 (%.c: ../regformats/i386/%.dat,
561 (%.c: ../regformats/rs6000/%.dat): New rules.
562 (aarch64.c): Remove.
563 (reg-arm.c): Remove.
564 (arm-with-iwmmxt.c): Remove.
565 (arm-with-vfpv2.c): Remove.
566 (arm-with-vfpv3.c): Remove.
567 (arm-with-neon.c): Remove.
568 (reg-bfin.c): Remove.
569 (reg-cris.c): Remove.
570 (reg-crisv32.c): Remove.
571 (i386.c): Remove.
572 (i386-linux.c): Remove.
573 (i386-avx.c): Remove.
574 (i386-avx-linux.c): Remove.
575 (i386-avx-avx512.c): Remove.
576 (i386-avx-avx512-linux.c): Remove.
577 (i386-mpx.c): Remove.
578 (i386-mpx-linux.c): Remove.
579 (i386-avx-mpx-avx512-pku.c): Remove.
580 (i386-avx-mpx-avx512-pku-linux.c): Remove.
581 (i386-avx-mpx.c): Remove.
582 (i386-avx-mpx-linux.c): Remove.
583 (i386-mmx.c): Remove.
584 (i386-mmx-linux.c): Remove.
585 (reg-ia64.c): Remove.
586 (reg-m32r.c): Remove.
587 (reg-m68k.c): Remove.
588 (reg-cf.c): Remove.
589 (mips-linux.c): Remove.
590 (mips-dsp-linux.c): Remove.
591 (mips64-linux.c): Remove.
592 (mips64-dsp-linux.c): Remove.
593 (nios2-linux.c): Remove.
594 (powerpc-32.c): Remove.
595 (powerpc-32l.c): Remove.
596 (powerpc-altivec32l.c): Remove.
597 (powerpc-cell32l.c): Remove.
598 (powerpc-vsx32l.c): Remove.
599 (powerpc-isa205-32l.c): Remove.
600 (powerpc-isa205-altivec32l.c): Remove.
601 (powerpc-isa205-vsx32l.c): Remove.
602 (powerpc-e500l.c): Remove.
603 (powerpc-64l.c): Remove.
604 (powerpc-altivec64l.c): Remove.
605 (powerpc-cell64l.c): Remove.
606 (powerpc-vsx64l.c): Remove.
607 (powerpc-isa205-64l.c): Remove.
608 (powerpc-isa205-altivec64l.c): Remove.
609 (powerpc-isa205-vsx64l.c): Remove.
610 (s390-linux32.c): Remove.
611 (s390-linux32v1.c): Remove.
612 (s390-linux32v2.c): Remove.
613 (s390-linux64.c): Remove.
614 (s390-linux64v1.c): Remove.
615 (s390-linux64v2.c): Remove.
616 (s390-te-linux64.c): Remove.
617 (s390-vx-linux64.c): Remove.
618 (s390-tevx-linux64.c): Remove.
619 (s390x-linux64.c): Remove.
620 (s390x-linux64v1.c): Remove.
621 (s390x-linux64v2.c): Remove.
622 (s390x-te-linux64.c): Remove.
623 (s390x-vx-linux64.c): Remove.
624 (s390x-tevx-linux64.c): Remove.
625 (tic6x-c64xp-linux.c): Remove.
626 (tic6x-c64x-linux.c): Remove.
627 (tic6x-c62x-linux.c): Remove.
628 (reg-sh.c): Remove.
629 (reg-sparc64.c): Remove.
630 (reg-spu.c): Remove.
631 (amd64.c): Remove.
632 (amd64-linux.c): Remove.
633 (amd64-avx.c): Remove.
634 (amd64-avx-linux.c): Remove.
635 (amd64-avx-avx512.c): Remove.
636 (amd64-avx-avx512-linux.c): Remove.
637 (amd64-mpx.c): Remove.
638 (amd64-mpx-linux.c): Remove.
639 (amd64-avx-mpx-avx512-pku.c): Remove.
640 (amd64-avx-mpx-avx512-pku-linux.c): Remove.
641 (amd64-avx-mpx.c): Remove.
642 (amd64-avx-mpx-linux.c): Remove.
643 (x32.c): Remove.
644 (x32-linux.c): Remove.
645 (x32-avx.c): Remove.
646 (x32-avx-linux.c): Remove.
647 (x32-avx-avx512.c): Remove.
648 (x32-avx-avx512-linux.c): Remove.
649 (reg-xtensa.c): Remove.
650 (reg-tilegx.c): Remove.
651 (reg-tilegx32.c): Remove.
652
1672e0d9
SDJ
6532017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
654
655 * Makefile.in (SFILES): Add "common/environ.c".
656 (OBJS): Add "common/environ.h".
657
239b6d10
WT
6582017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
659
660 * configure.ac: Check if the fs_base and gs_base members of
661 `struct user_regs_struct' exist.
662 * config.in: Regenerated.
663 * configure: Likewise.
664
694b382c
AT
6652017-01-09 Antoine Tremblay <antoine.tremblay@ericsson.com>
666
667 * linux-aarch32-low.c (arm_breakpoint_kind_from_pc): Use
668 target_read_memory.
669 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer): Likewise.
670 (get_next_pcs_syscall_next_pc): Likewise.
671
7dc53023
LM
6722016-12-23 Luis Machado <lgustavo@codesourcery.com>
673
674 * win32-i386-low.c: Fix incorrect reference to a couple source files.
675 * nto-x86-low.c: Likewise.
676
ad02e4fe
SM
6772016-11-30 Simon Marchi <simon.marchi@polymtl.ca>
678
679 * Makefile.in: Include disable-implicit-rules.mk.
680
dcb07cfa
PA
6812016-11-23 Pedro Alves <palves@redhat.com>
682
683 * debug.c: Include <chrono> instead of "gdb_sys_time.h".
684 (debug_vprintf): Use std::chrono::steady_clock instead of
685 gettimeofday. Use '.' instead of ':'.
686 * tracepoint.c: Include <chrono> instead of "gdb_sys_time.h".
687 (get_timestamp): Use std::chrono::steady_clock instead of
688 gettimeofday.
689
8629c02c
SM
6902016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
691
692 * Makefile.in: Fix whitespace formatting.
693
b593ecca
SM
6942016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
695
696 * Makefile.in (SFILES, OBS): Flatten list and order
697 alphabetically.
698
9986ba08
PA
6992016-11-23 Pedro Alves <palves@redhat.com>
700
701 * event-loop.c (handle_file_event): Use warning.
702 * linux-low.c (linux_resume_one_lwp_throw): Use warning.
703 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
704 Use warning.
705
4eefa7bc
PA
7062016-11-23 Pedro Alves <palves@redhat.com>
707
708 * linux-low.c (check_zombie_leaders): Use debug_printf for debug
709 output.
710 * notif.c (handle_notif_ack, notif_event_enque): Likewise.
711 * remote-utils.c (putpkt_binary_1, readchar, getpkt): Use
712 debug_printf and debug_flush for debug output.
713 * server.c (handle_general_set): Likewise.
714 * thread-db.c (try_thread_db_load): Use debug_printf for debug
715 output.
716
5443506e
SM
7172016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
718
719 * Makefile.in (.c.o): Replace rule with ...
720 (%.o: %.c): ... this one.
721
3b165252
SM
7222016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
723
724 * Makefile.in: Remove @GMAKE_TRUE@ prefixes and removes lines
725 prefixed with @GMAKE_FALSE@. Update comment related to non-GNU
726 make.
727 * configure.ac: Remove checks for the make program.
728 * configure: Re-generate.
729
0bcda685
PA
7302016-10-28 Pedro Alves <palves@redhat.com>
731
732 * Makefile.in (CXX_DIALECT): Get from configure.
733 (COMPILE.pre, CC_LD): Append $(CXX_DIALECT).
734 * acinclude.m4: Include ../ax_cxx_compile_stdcxx.m4.
735 * configure.ac: Call AX_CXX_COMPILE_STDCXX.
736 * config.in: Regenerate.
737 * configure: Regenerate.
738
c3805894
YQ
7392016-10-27 Yao Qi <yao.qi@linaro.org>
740
741 * linux-low.c (linux_supports_range_stepping): Return true if
742 can_software_single_step return true.
743
89342618
YQ
7442016-10-27 Yao Qi <yao.qi@linaro.org>
745
746 * inferiors.c (find_inferior_in_random): New function.
747 * inferiors.h (find_inferior_in_random): Declare.
748 * linux-low.c (linux_wait_for_event_filtered): Call
749 find_inferior_in_random instead of find_inferior.
750
e3652c84
YQ
7512016-10-27 Yao Qi <yao.qi@linaro.org>
752
753 * linux-low.c (linux_wait_1): If single-step breakpoints are
754 inserted, remove them.
755
5a04c4cf
PA
7562016-10-26 Pedro Alves <palves@redhat.com>
757
758 * linux-low.c (handle_extended_wait): Link parent/child fork
759 threads.
760 (linux_wait_1): Unlink them.
761 (linux_set_resume_request): Ignore resume requests for
762 already-resumed and unhandled fork child threads.
763 * linux-low.h (struct lwp_info) <fork_relative>: New field.
764 * server.c (in_queued_stop_replies_ptid, in_queued_stop_replies):
765 New functions.
766 (handle_v_requests) <vCont>: Don't call require_running.
767 * server.h (in_queued_stop_replies): New declaration.
768
cb93dc7f
YQ
7692016-10-24 Yao Qi <yao.qi@linaro.org>
770
771 PR server/20733
772 * linux-aarch64-low.c (append_insns): Cast the return value to
773 'uint32_t *'.
774
a1078bea
YQ
7752016-10-10 Yao Qi <yao.qi@linaro.org>
776
777 * linux-aarch32-low.c (enum arm_breakpoint_kinds): Remove.
778
1fb77080
SDJ
7792016-10-06 Sergio Durigan Junior <sergiodj@redhat.com>
780
781 * target.c (target_supports_multi_process): New function, moved
782 from...
783 * target.h (target_supports_multi_process): ... here. Remove
784 macro.
785
39b5a3b9
TT
7862016-10-05 Tom Tromey <tom@tromey.com>
787
788 PR remote/20655:
789 * tracepoint.c (handle_tracepoint_bkpts): Check
790 ipa_error_tracepoint, not ipa_stopping_tracepoint.
791
c1d0b70a
YQ
7922016-10-05 Yao Qi <yao.qi@linaro.org>
793
794 * configure.srv: Update the path of arm-*.xml files.
795
0a69eedb
YQ
7962016-10-05 Terry Guo <terry.guo@arm.com>
797 Yao Qi <yao.qi@linaro.org>
798
799 * Makefile.in: Adjust the path of rules.
800 * configure.srv: Update the path of xml files.
801 * regformats/arm-with-iwmmxt.dat: Regenerated.
802 * regformats/arm-with-neon.dat: Likewise.
803 * regformats/arm-with-vfpv2.dat: Likewise.
804 * regformats/arm-with-vfpv3.dat Likewise.
805
17e16485
YQ
8062016-09-30 Yao Qi <yao.qi@linaro.org>
807
808 PR gdbserver/20627
809 * target.c (target_stop_and_wait): Don't call
810 target_continue_no_signal, use resume_stop instead.
811
edeeb602
YQ
8122016-09-26 Yao Qi <yao.qi@linaro.org>
813
814 * linux-low.c (linux_wait_1): Call debug_exit.
815
503b1c39
PA
8162016-09-23 Pedro Alves <palves@redhat.com>
817
818 * Makefile.in (SFILES): Add common/new-op.c.
819 (OBS): Add common/new-op.o.
820 (new-op.o): New rule.
821
74172ecf
SM
8222016-09-21 Simon Marchi <simon.marchi@ericsson.com>
823
824 * .gitinore: Ignore more files.
825
fc6cda2e
YQ
8262016-09-21 Yao Qi <yao.qi@linaro.org>
827
828 * linux-aarch32-low.c (arm_fill_gregset): Keep bits 20 to
829 23.
830
bc1e6c81
SDJ
8312016-09-19 Sergio Durigan Junior <sergiodj@redhat.com>
832
833 * server.c (start_inferior): Call target_mourn_inferior instead of
834 mourn_inferior; pass ptid_t argument to it.
835 (resume): Likewise.
836 (handle_target_event): Likewise.
837 * target.c (target_mourn_inferior): New function.
838 * target.h (mourn_inferior): Delete macro.
839
0e00e962
AA
8402016-09-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
841
842 * linux-low.c (lwp_is_stepping): New function.
843
1d8cb77d
CL
8442016-09-06 Carl Love <cel@us.ibm.com>
845
846 * server.c (start_inferior): Fixed comment, requested comment change
847 didn't get updated correctly. Removed reference to ptrace () call as
848 it is only true on Linux systems.
849
7313bced
CL
8502016-09-06 Carl Love <cel@us.ibm.com>
851
852 * server.c (start_inferior): Do not call
853 function target_post_create_inferior () if the
854 inferior process has already exited.
855
cf6de44d
PA
8562016-09-05 Pedro Alves <palves@redhat.com>
857
858 * Makefile.in (COMPILER, COMPILER_CFLAGS): Remove.
859 (COMPILE.pre, CC_LD): Use CXX directly.
860 (INTERNAL_CFLAGS_BASE): Use CXXFLAGS directly.
861 * acinclude.m4: Don't include build-with-cxx.m4.
862 * configure.ac: Remove GDB_AC_BUILD_WITH_CXX call.
863 * configure: Regenerate.
864
c1da6748
AT
8652016-09-02 Akash Trehan <akash.trehan123@gmail.com>
866
867 PR gdb/19495
868 * remote-utils.c (relocate_instruction): Remove redundant strcpy()
869 call writing data to own_buf.
870
f2b9e3df
SDJ
8712016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
872
873 * target.c (mywait): Call target_wait instead of
874 the_target->wait.
875 (target_wait): New function.
876
049a8570
SDJ
8772016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
878
879 * server.c (start_inferior): New variable 'ptid'. Replace calls
880 to the_target->resume by target_continue{,_no_signal}, depending
881 on the case.
882 * target.c (target_stop_and_wait): Call target_continue_no_signal
883 instead of the_target->resume.
884 (target_continue): New function.
885
3aa5cfa0
AT
8862016-08-31 Antoine Tremblay <antoine.tremblay@ericsson.com>
887
888 * linux-low.c (linux_wait_1): Move event switch after unsuspend_lwps.
889
754653a7
AZ
8902016-08-25 Adhemerval Zanella <adhemerval.zanella@linaro.org>
891
892 PR server/20491
893 * gdb_proc_service.h (ps_get_thread_area): Remove const from struct
894 ps_prochandle.
895 * linux-aarch64-low.c (ps_get_thread_area): Likewise.
896 * linux-arm-low.c (ps_get_thread_area): Likewise.
897 * linux-crisv32-low.c (ps_get_thread_area): Likewise.
898 * linux-m68k-low.c (ps_get_thread_area): Likewise.
899 * linux-mips-low.c (ps_get_thread_area): Likewise.
900 * linux-nios2-low.c (ps_get_thread_area): Likewise.
901 * linux-tic6x-low.c (ps_get_thread_area): Likewise.
902 * linux-x86-low.c (ps_get_thread_area): Likewise.
903 * linux-xtensa-low.c (ps_get_thread_area): Likewise.
904
ed036b40
PA
9052016-08-19 Pedro Alves <palves@redhat.com>
906
907 * linux-x86-low.c (amd64_emit_call): Emit missing call opcode.
908
c8ef42ee
PA
9092016-08-19 Pedro Alves <palves@redhat.com>
910
911 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Fix
912 comment. Use memcpy instead of casting through unsigned long.
913
9c235a72
PA
9142016-08-19 Pedro Alves <palves@redhat.com>
915
916 * linux-amd64-ipa.c (alloc_jump_pad_buffer) [__ILP32__]: Try
917 allocating around 0x80000000.
918
201506da
PA
9192016-08-19 Pedro Alves <palves@redhat.com>
920
921 PR gdb/20415
922 * Makefile.in (x32-linux-ipa.o, x32-avx-linux-ipa.o)
923 (x32-avx512-linux-ipa.o): New rules.
924 * configure.ac (x86_64-*-linux*): New x32 check.
925 * configure.srv (ipa_x32_linux_regobj): New.
926 (x86_64-*-linux*): Use $ipa_x32_linux_regobj if building for x32.
927 * linux-amd64-ipa.c (get_ipa_tdesc) [__ILP32__]: Return x32
928 descriptions.
929 (initialize_low_tracepoint) [__ILP32__]: Initialize x32
930 descriptions.
931 * configure: Regenerate.
932
f348d89a
PA
9332016-08-09 Pedro Alves <palves@redhat.com>
934
935 PR gdb/18653
936 * Makefile.in (OBS): Add signals-state-save-restore.o.
937 (signals-state-save-restore.o): New rule.
938 * config.in: Regenerate.
939 * configure: Regenerate.
940 * linux-low.c: Include "signals-state-save-restore.h".
941 (linux_create_inferior): Call
942 restore_original_signals_state.
943 * server.c: Include "dispositions-save-restore.h".
944 (captured_main): Call save_original_signals_state.
945
1baf5149
PA
9462016-08-05 Pedro Alves <palves@redhat.com>
947
948 * configure: Regenerate.
949
fcd4a73d
YQ
9502016-08-04 Yao Qi <yao.qi@linaro.org>
951
952 * linux-low.c (regsets_fetch_inferior_registers): Check
953 errno is ESRCH or not.
954
979659d0
YQ
9552016-08-02 Yao Qi <yao.qi@linaro.org>
956
957 * thread-db.c (struct thread_db) <td_ta_event_getmsg_p>: Remove.
958 <td_ta_set_event_p, td_ta_event_addr_p>: Remove.
959 (thread_db_load_search): Update.
960 (try_thread_db_load_1): Don't look for td_ta_event_addr,
961 td_ta_set_event and td_ta_event_getmsg.
962
6598661d
PA
9632016-07-26 Pedro Alves <palves@redhat.com>
964
965 PR server/20414
966 * linux-x86-low.c (x86_get_pc, x86_set_pc): Use uint64_t instead
967 of unsigned long for 64-bit registers and use uint32_t instead of
968 unsigned int for 32-bit registers.
969
9cf12d57
PA
9702016-07-26 Pedro Alves <palves@redhat.com>
971
972 * linux-x86-low.c (x86_siginfo_fixup): Rename 'native' parameter
973 to 'ptrace'.
974
305450ed
TT
9752016-07-21 Tom Tromey <tom@tromey.com>
976
977 * configure: Rebuild.
978
2583da7c
YQ
9792016-07-21 Yao Qi <yao.qi@linaro.org>
980
981 * mem-break.c (find_gdb_breakpoint): Cast bp to
982 'struct gdb_breakpoint *' rather than 'gdb_breakpoint *'.
983
21536b36
YQ
9842016-07-21 Yao Qi <yao.qi@linaro.org>
985
986 * server.c (handle_v_requests): Support s and S actions
987 if target_supports_software_single_step return true.
988
8901d193
YQ
9892016-07-21 Yao Qi <yao.qi@linaro.org>
990
991 * linux-low.c (resume_stopped_resumed_lwps): If resume request
992 is resume_step, call maybe_hw_step.
993 (linux_wait_1): Stop all threads, remove reinsert breakpoints,
994 and unstop them.
995 (linux_resume_one_lwp_throw): Don't assert the thread has reinsert
996 breakpoints or not.
997 (proceed_one_lwp): If resume request is resume_step, install
998 reinsert breakpoints and call maybe_hw_step.
999
0e9a339e
YQ
10002016-07-21 Yao Qi <yao.qi@linaro.org>
1001
1002 * linux-low.c (proceed_one_lwp): Declare.
1003 (linux_resume_one_thread): Remove local variable 'step'.
1004 Lift code enqueue signal. Call proceed_one_lwp instead of
1005 linux_resume_one_lwp.
1006
4281b351
YQ
10072016-07-21 Yao Qi <yao.qi@linaro.org>
1008
1009 * linux-low.c (linux_resume_one_thread): Call
1010 enqueue_pending_signal.
1011
984a2c04
YQ
10122016-07-21 Yao Qi <yao.qi@linaro.org>
1013
1014 * gdbthread.h (make_cleanup_restore_current_thread): Declare.
1015 * inferiors.c (do_restore_current_thread_cleanup): New function.
1016 (make_cleanup_restore_current_thread): Likewise.
1017 * linux-low.c (install_software_single_step_breakpoints): Call
1018 make_cleanup_restore_current_thread. Switch current_thread to
1019 thread.
1020
bec903c9
YQ
10212016-07-21 Yao Qi <yao.qi@linaro.org>
1022
1023 * mem-break.c (struct reinsert_breakpoint) <ptid>: New field.
1024 (set_reinsert_breakpoint): New parameter ptid. Callers updated.
1025 (clone_one_breakpoint): Likewise.
1026 (delete_reinsert_breakpoints): Change parameter to thread.
1027 Callers updated.
1028 (has_reinsert_breakpoints): Likewise.
1029 (uninsert_reinsert_breakpoints): Likewise.
1030 (reinsert_reinsert_breakpoints): Likewise.
1031 * mem-break.h (set_reinsert_breakpoint): Update declaration.
1032 (delete_reinsert_breakpoints): Likewise.
1033 (reinsert_reinsert_breakpoints): Likewise.
1034 (uninsert_reinsert_breakpoints): Likewise.
1035 (has_reinsert_breakpoints): Likewise.
1036
63c40ec7
YQ
10372016-07-21 Yao Qi <yao.qi@linaro.org>
1038
1039 * inferiors.c (get_thread_process): Make parameter const.
1040 * inferiors.h (get_thread_process): Update declaration.
1041 * mem-break.c (clone_all_breakpoints): Remove all parameters.
1042 Add new parameters child_thread and parent_thread. Callers
1043 updated.
1044 * mem-break.h (clone_all_breakpoints): Update declaration.
1045
9aa76cd0
YQ
10462016-07-21 Yao Qi <yao.qi@linaro.org>
1047
1048 * mem-break.c (struct breakpoint) <cond_list>: Remove.
1049 <command_list, handler>: Remove.
1050 (struct gdb_breakpoint): New.
1051 (struct other_breakpoint): New.
1052 (struct reinsert_breakpoint): New.
1053 (is_gdb_breakpoint): New function.
1054 (any_persistent_commands): Update command_list if
1055 is_gdb_breakpoint returns true.
1056 (set_breakpoint): Create breakpoints according to their types.
1057 (find_gdb_breakpoint): Return 'struct gdb_breakpoint *'.
1058 (set_gdb_breakpoint_1): Likewise.
1059 (set_gdb_breakpoint): Likewise.
1060 (clear_breakpoint_conditions): Change parameter type to
1061 'struct gdb_breakpoint *'.
1062 (clear_breakpoint_commands): Likewise.
1063 (clear_breakpoint_conditions_and_commands): Likewise.
1064 (add_condition_to_breakpoint): Likewise.
1065 (add_breakpoint_condition): Likewise.
1066 (add_commands_to_breakpoint): Likewise.
1067 (check_breakpoints): Check other_breakpoint.
1068 (clone_one_breakpoint): Clone breakpopint according to its type.
1069 * mem-break.h (struct gdb_breakpoint): Declare.
1070 (set_gdb_breakpoint): Update declaration.
1071 (clear_breakpoint_conditions_and_commands): Likewise.
1072 (add_breakpoint_condition): Likewise.
1073 (add_breakpoint_commands): Likewise.
1074 * server.c (process_point_options): Change parameter type to
1075 'struct gdb_breakpoint *'.
1076
811f8301
YQ
10772016-07-21 Yao Qi <yao.qi@linaro.org>
1078
1079 * mem-break.c (set_breakpoint_at): Rename it to ...
1080 (set_breakpoint_type_at): ... it.
1081 (set_breakpoint_at): Call set_breakpoint_type_at.
1082 (set_reinsert_breakpoint): Call set_breakpoint_type_at.
1083 * mem-break.h (set_breakpoint_at): Update comments.
1084
b1c51e36
CLT
10852016-07-12 Chung-Lin Tang <cltang@codesourcery.com>
1086
1087 * linux-nios2-low.c (nios2_fill_gregset): Add type cast
1088 to buf parameter.
1089 (nios2_store_gregset): Likewise.
1090
ced2dffb
PA
10912016-07-01 Pedro Alves <palves@redhat.com>
1092 Antoine Tremblay <antoine.tremblay@ericsson.com>
1093
1094 * linux-low.c: Change interface to take the target lwp_info
1095 pointer directly and return void. Handle detaching from a zombie
1096 thread.
1097 (linux_detach_lwp_callback): New function.
1098 (linux_detach): Detach from the leader thread after detaching from
1099 the clone threads.
1100
2ac09a5b
YQ
11012016-06-28 Yao Qi <yao.qi@linaro.org>
1102
1103 * linux-aarch64-low.c (aarch64_ftrace_insn_reloc_b): Use int64_t
1104 for variable new_offset.
1105 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
1106 (aarch64_ftrace_insn_reloc_cb): Likewise.
1107 (aarch64_ftrace_insn_reloc_tb): Likewise.
1108 (aarch64_install_fast_tracepoint_jump_pad): Likewise. Use
1109 PRIx64 instead of PRIx32.
1110
79e7fd4f
YQ
11112016-06-28 Yao Qi <yao.qi@linaro.org>
1112
1113 * linux-arm-low.c (arm_get_syscall_trapinfo): New function.
1114 (the_low_target): Install arm_get_syscall_trapinfo.
1115
061fc021
YQ
11162016-06-28 Yao Qi <yao.qi@linaro.org>
1117
1118 * linux-aarch64-low.c (aarch64_get_syscall_trapinfo): New
1119 function.
1120 (the_low_target): Install aarch64_get_syscall_trapinfo.
1121
4cc32bec
YQ
11222016-06-28 Yao Qi <yao.qi@linaro.org>
1123
1124 * linux-low.c (get_syscall_trapinfo): Remove parameter sysret.
1125 Callers updated.
1126 * linux-low.h (struct linux_target_ops) <get_syscall_trapinfo>:
1127 Remove parameter sysno.
1128 * linux-x86-low.c (x86_get_syscall_trapinfo): Remove parameter
1129 sysret.
1130
782c1122
AA
11312016-06-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
1132
1133 * linux-s390-low.c (s390_emit_eq_goto): Mark function static.
1134 (s390_emit_ne_goto): Likewise.
1135 (s390_emit_lt_goto): Likewise.
1136 (s390_emit_le_goto): Likewise.
1137 (s390_emit_gt_goto): Likewise.
1138 (s390_emit_ge_goto): Likewise.
1139 (s390x_emit_eq_goto): Likewise.
1140 (s390x_emit_ne_goto): Likewise.
1141 (s390x_emit_lt_goto): Likewise.
1142 (s390x_emit_le_goto): Likewise.
1143 (s390x_emit_gt_goto): Likewise.
1144 (s390x_emit_ge_goto): Likewise.
1145 (s390_emit_ops_impl): Mark variable static.
1146 (s390x_emit_ops): Likewise.
1147
2e7b624b
YQ
11482016-06-17 Yao Qi <yao.qi@linaro.org>
1149
1150 * linux-low.c (handle_extended_wait): Call
1151 uninsert_reinsert_breakpoints for the parent process. Remove
1152 reinsert breakpoints from the child process. Reinsert them to
1153 the parent process when vfork is done.
1154 * mem-break.c (uninsert_reinsert_breakpoints): New function.
1155 (reinsert_reinsert_breakpoints): New function.
1156 * mem-break.h (uninsert_reinsert_breakpoints): Declare
1157 (reinsert_reinsert_breakpoints): Declare.
1158
8a81c5d7
YQ
11592016-06-17 Yao Qi <yao.qi@linaro.org>
1160
1161 * linux-low.c (handle_extended_wait): If the parent is doing
1162 step-over, remove the reinsert breakpoints from the forked child.
1163
f50bf8e5
YQ
11642016-06-17 Yao Qi <yao.qi@linaro.org>
1165
1166 * linux-low.c (unsuspend_all_lwps): Declare.
1167 (linux_low_filter_event): If thread exited, call finish_step_over.
1168 If step-over is finished, unsuspend other threads.
1169
8376a3cb
YQ
11702016-06-17 Yao Qi <yao.qi@linaro.org>
1171
1172 * linux-low.c (linux_resume_one_lwp_throw): Assert
1173 has_reinsert_breakpoints returns false.
1174 * mem-break.c (delete_disabled_breakpoints): Assert
1175 bp type isn't reinsert_breakpoint.
1176
f79b145d
YQ
11772016-06-17 Yao Qi <yao.qi@linaro.org>
1178
1179 * linux-low.c (maybe_hw_step): New function.
1180 (linux_resume_one_lwp_throw): Call maybe_hw_step.
1181 (finish_step_over): Switch current_thread to lwp temporarily,
1182 and assert has_reinsert_breakpoints returns true.
1183 (proceed_one_lwp): Call maybe_hw_step.
1184 * mem-break.c (has_reinsert_breakpoints): New function.
1185 * mem-break.h (has_reinsert_breakpoints): Declare.
1186
0ae534d2
JT
11872016-06-02 Jon Turney <jon.turney@dronecode.org.uk>
1188
1189 * win32-low.c (win32_create_inferior): Add pointer casts for C++.
1190
fcdad592
YQ
11912016-05-17 Yao Qi <yao.qi@linaro.org>
1192
1193 * linux-low.c (linux_stabilize_threads): Call unsuspend_all_lwps
1194 instead of find_inferior.
1195
9e784964
YQ
11962016-05-05 Yao Qi <yao.qi@linaro.org>
1197
1198 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer):
1199 Initialize res to zero.
1200
cf2ebb6e
YQ
12012016-05-05 Yao Qi <yao.qi@linaro.org>
1202
1203 * linux-arm-low.c (arm_sigreturn_next_pc): Change type of cpsr
1204 to uint32_t.
1205
c1aebf87
UW
12062016-05-04 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
1207
1208 * spu-low.c (fetch_ppc_register): Cast PowerPC-Linux-specific value
1209 used as first ptrace argument to PTRACE_TYPE_ARG1 for C++.
1210 (fetch_ppc_memory_1, store_ppc_memory_1): Likewise.
1211
35fd2deb 12122016-04-28 Par Olsson <par.olsson@windriver.com>
cbe14bcf 1213 Simon Marchi <simon.marchi@ericsson.com>
35fd2deb
PO
1214
1215 * tracepoint.c (write_inferior_int8): New function.
1216 (cmd_qtenable_disable): Write enable flag using
1217 write_inferior_int8.
1218
484b3c32
YQ
12192016-04-25 Yao Qi <yao.qi@linaro.org>
1220
1221 * linux-low.c (lwp_signal_can_be_delivered): Adjust.
1222 (need_step_over_p): Return zero if the LWP has pending signals
1223 can be delivered on software single step target.
1224
85ba7d86
YQ
12252016-04-25 Yao Qi <yao.qi@linaro.org>
1226
1227 * linux-low.c (reinsert_raw_breakpoint): If bp->inserted is true
1228 return instead of error.
1229
3539aa13
YQ
12302016-04-22 Yao Qi <yao.qi@linaro.org>
1231
1232 * linux-aarch32-low.c (arm_store_gregset): Clear CPSR bits 20
1233 to 23.
1234
5b061e98
YQ
12352016-04-22 Yao Qi <yao.qi@linaro.org>
1236
1237 * linux-low.c (lwp_signal_can_be_delivered): Don't deliver
1238 signal when stepping over breakpoint with software single
1239 step.
1240
3451269c
PA
12412016-04-21 Pedro Alves <palves@redhat.com>
1242
1243 * linux-s390-low.c (s390_collect_ptrace_register)
1244 (s390_supply_ptrace_register, s390_get_hwcap): Use gdb_byte * and
1245 add casts.
1246 (s390_check_regset): Use void * instead of gdb_byte *.
1247
a2358508
PA
12482016-04-20 Pedro Alves <palves@redhat.com>
1249
1250 * configure: Renegerate.
1251
6885166d
YQ
12522016-04-20 Yao Qi <yao.qi@linaro.org>
1253
1254 * linux-aarch32-low.c: Include "arch/arm-linux.h".
1255 (arm_fill_gregset): Use ARM_CPSR_GREGNUM rather than magic
1256 number 16.
1257 (arm_store_gregset): Likewise.
1258
2b863f51
WT
12592016-04-16 Walfred Tedeschi <walfred.tedeschi@intel.com>
1260
1261 * Makefile.in (clean): Add removal for i386-avx-mpx.c,
1262 i386-avx-mpx-linux.c, amd64-avx-mpx.c and amd64-avx-mpx-linux.c.
1263 (i386-avx-mpx.c, i386-avx-mpx-linux.c, amd64-avx-mpx.c)
1264 (amd64-avx-mpx-linux.c): New rules.
1265 (amd64-avx-mpx-linux-ipa.o, i386-avx-mpx-linux-ipa.o): New rule.
1266 * configure.srv (srv_i386_regobj): Add i386-avx-mpx.o.
1267 (srv_i386_linux_regobj): Add i386-avx-mpx-linux.o.
1268 (srv_amd64_regobj): Add amd64-avx-mpx.o.
1269 (srv_amd64_linux_regobj): Add amd64-avx-mpx-linux.o.
1270 (srv_i386_xmlfiles): Add i386/i386-avx-mpx.xml.
1271 (srv_amd64_xmlfiles): Add i386/amd64-avx-mpx.xml.
1272 (srv_i386_linux_xmlfiles): Add i386/i386-avx-mpx-linux.xml.
1273 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-mpx-linux.xml.
1274 (ipa_i386_linux_regobj): Add i386-avx-mpx-linux-ipa.o.
1275 (ipa_amd64_linux_regobj): Add amd64-avx-mpx-linux-ipa.o.
1276 * linux-x86-low.c (x86_linux_read_description): Add case for
1277 X86_XSTATE_AVX_MPX_MASK.
1278 (x86_get_ipa_tdesc_idx): Add cases for avx_mpx.
1279 (initialize_low_arch): Call init_registers_amd64_avx_mpx_linux and
1280 init_registers_i386_avx_mpx_linux.
1281 * linux-i386-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
1282 (initialize_low_tracepoint): Call
1283 init_registers_i386_avx_mpx_linux.
1284 * linux-amd64-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
1285 (initialize_low_tracepoint): Call
1286 init_registers_amd64_avx_mpx_linux.
1287 * linux-x86-tdesc.h (X86_TDESC_AVX_MPX): New enum value.
1288 (init_registers_amd64_avx_mpx_linux, tdesc_amd64_avx_mpx_linux)
1289 (init_registers_i386_avx_mpx_linux, tdesc_i386_avx_mpx_linux): New
1290 declarations.
1291
9b30624b
PA
12922016-04-18 Pedro Alves <palves@redhat.com>
1293
1294 * configure: Regenerate.
1295
45e3745e
AT
12962016-04-13 Antoine Tremblay <antoine.tremblay@ericsson.com>
1297
1298 * linux-aarch64-low.c (aarch64_emit_add): Switch x1 and x0.
1299 (aarch64_emit_sub): Likewise.
1300
2afc13ff
PA
13012016-04-12 Pedro Alves <palves@redhat.com>
1302
1303 * utils.c (prepare_to_throw_exception): Delete.
1304
6e774b13
SM
13052016-04-05 Simon Marchi <simon.marchi@ericsson.com>
1306
1307 * Makefile.in ($(IPA_LIB)): Set SONAME of the IPA lib.
1308
4dca19f8
MK
13092016-04-05 Marcin Kościelnicki <koriakin@0x04.net>
1310
1311 * tracepoint.c (getauxval): Move to #ifdef IN_PROCESS_AGENT.
1312
d0a9981f
MK
13132016-04-03 Marcin Kościelnicki <koriakin@0x04.net>
1314
1315 * linux-aarch64-ipa.c: Add <elf.h> include.
1316 * linux-ppc-ipa.c: Add <elf.h> include.
1317 * linux-s390-ipa.c: Add <elf.h> include.
1318
252db07e
MK
13192016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
1320
1321 * tracepoint.c (gdb_collect_ptr): Remove const qualifier.
1322 (get_raw_reg_ptr): Likewise.
1323 (get_trace_state_variable_value_ptr): Likewise.
1324 (set_trace_state_variable_value_ptr): Likewise.
1325 (initialize_tracepoint): Cast alloc_jump_pad_buffer result to
1326 char *.
1327
14e2b6d9
MK
13282016-03-31 Wei-cheng Wang <cole945@gmail.com>
1329 Marcin Kościelnicki <koriakin@0x04.net>
1330
1331 PR/17221
1332 * linux-ppc-low.c (emit_insns): New function.
1333 (__EMIT_ASM, _EMIT_ASM, EMIT_ASM): New macros.
1334 (ppc_emit_prologue): New function.
1335 (ppc_emit_epilogue): New function.
1336 (ppc_emit_add): New function.
1337 (ppc_emit_sub): New function.
1338 (ppc_emit_mul): New function.
1339 (ppc_emit_lsh): New function.
1340 (ppc_emit_rsh_signed): New function.
1341 (ppc_emit_rsh_unsigned): New function.
1342 (ppc_emit_ext): New function.
1343 (ppc_emit_zero_ext): New function.
1344 (ppc_emit_log_not): New function.
1345 (ppc_emit_bit_and): New function.
1346 (ppc_emit_bit_or): New function.
1347 (ppc_emit_bit_xor): New function.
1348 (ppc_emit_bit_not): New function.
1349 (ppc_emit_equal): New function.
1350 (ppc_emit_less_signed): New function.
1351 (ppc_emit_less_unsigned): New function.
1352 (ppc_emit_ref): New function.
1353 (ppc_emit_const): New function.
1354 (ppc_emit_reg): New function.
1355 (ppc_emit_pop): New function.
1356 (ppc_emit_stack_flush): New function.
1357 (ppc_emit_swap): New function.
1358 (ppc_emit_stack_adjust): New function.
1359 (ppc_emit_call): New function.
1360 (ppc_emit_int_call_1): New function.
1361 (ppc_emit_void_call_2): New function.
1362 (ppc_emit_if_goto): New function.
1363 (ppc_emit_goto): New function.
1364 (ppc_emit_eq_goto): New function.
1365 (ppc_emit_ne_goto): New function.
1366 (ppc_emit_lt_goto): New function.
1367 (ppc_emit_le_goto): New function.
1368 (ppc_emit_gt_goto): New function.
1369 (ppc_emit_ge_goto): New function.
1370 (ppc_write_goto_address): New function.
1371 (ppc_emit_ops_impl): New static variable.
1372 (ppc64v1_emit_prologue): New function.
1373 (ppc64v2_emit_prologue): New function.
1374 (ppc64_emit_epilogue): New function.
1375 (ppc64_emit_add): New function.
1376 (ppc64_emit_sub): New function.
1377 (ppc64_emit_mul): New function.
1378 (ppc64_emit_lsh): New function.
1379 (ppc64_emit_rsh_signed): New function.
1380 (ppc64_emit_rsh_unsigned): New function.
1381 (ppc64_emit_ext): New function.
1382 (ppc64_emit_zero_ext): New function.
1383 (ppc64_emit_log_not): New function.
1384 (ppc64_emit_bit_and): New function.
1385 (ppc64_emit_bit_or): New function.
1386 (ppc64_emit_bit_xor): New function.
1387 (ppc64_emit_bit_not): New function.
1388 (ppc64_emit_equal): New function.
1389 (ppc64_emit_less_signed): New function.
1390 (ppc64_emit_less_unsigned): New function.
1391 (ppc64_emit_ref): New function.
1392 (ppc64_emit_const): New function.
1393 (ppc64v1_emit_reg): New function.
1394 (ppc64v2_emit_reg): New function.
1395 (ppc64_emit_pop): New function.
1396 (ppc64_emit_stack_flush): New function.
1397 (ppc64_emit_swap): New function.
1398 (ppc64v1_emit_call): New function.
1399 (ppc64v2_emit_call): New function.
1400 (ppc64v1_emit_int_call_1): New function.
1401 (ppc64v2_emit_int_call_1): New function.
1402 (ppc64v1_emit_void_call_2): New function.
1403 (ppc64v2_emit_void_call_2): New function.
1404 (ppc64_emit_if_goto): New function.
1405 (ppc64_emit_eq_goto): New function.
1406 (ppc64_emit_ne_goto): New function.
1407 (ppc64_emit_lt_goto): New function.
1408 (ppc64_emit_le_goto): New function.
1409 (ppc64_emit_gt_goto): New function.
1410 (ppc64_emit_ge_goto): New function.
1411 (ppc64v1_emit_ops_impl): New static variable.
1412 (ppc64v2_emit_ops_impl): New static variable.
1413 (ppc_emit_ops): New function.
1414 (linux_low_target): Wire in ppc_emit_ops.
1415
a2174ba4
MK
14162016-03-31 Wei-cheng Wang <cole945@gmail.com>
1417 Marcin Kościelnicki <koriakin@0x04.net>
1418
1419 PR/17221
1420 * Makefile.in: Add powerpc-*-ipa.o
1421 * configure.srv: Add ipa_obj for powerpc*-linux.
1422 * linux-ppc-ipa.c: New file.
1423 * linux-ppc-low.c: Added linux-ppc-tdesc.h, ax.h, tracepoint.h
1424 includes.
1425 (PPC_FIELD): New macro.
1426 (PPC_SEXT): New macro.
1427 (PPC_OP6): New macro.
1428 (PPC_BO): New macro.
1429 (PPC_LI): New macro.
1430 (PPC_BD): New macro.
1431 (init_registers_*): Move prototype to linux-ppc-tdesc.h.
1432 (tdesc_*): Move declaration to linux-ppc-tdesc.h.
1433 (ppc_get_hwcap): Rename to ppc_get_auxv and add type parameter.
1434 (ppc_get_thread_area): New function.
1435 (is_elfv2_inferior): New function.
1436 (gen_ds_form): New function.
1437 (GEN_STD): New macro.
1438 (GEN_STDU): New macro.
1439 (GEN_LD): New macro.
1440 (GEN_LDU): New macro.
1441 (gen_d_form): New function.
1442 (GEN_ADDI): New macro.
1443 (GEN_ADDIS): New macro.
1444 (GEN_LI): New macro.
1445 (GEN_LIS): New macro.
1446 (GEN_ORI): New macro.
1447 (GEN_ORIS): New macro.
1448 (GEN_LWZ): New macro.
1449 (GEN_STW): New macro.
1450 (GEN_STWU): New macro.
1451 (gen_xfx_form): New function.
1452 (GEN_MFSPR): New macro.
1453 (GEN_MTSPR): New macro.
1454 (GEN_MFCR): New macro.
1455 (GEN_MTCR): New macro.
1456 (GEN_SYNC): New macro.
1457 (GEN_LWSYNC): New macro.
1458 (gen_x_form): New function.
1459 (GEN_OR): New macro.
1460 (GEN_MR): New macro.
1461 (GEN_LWARX): New macro.
1462 (GEN_STWCX): New macro.
1463 (GEN_CMPW): New macro.
1464 (gen_md_form): New function.
1465 (GEN_RLDICL): New macro.
1466 (GEN_RLDICR): New macro.
1467 (gen_i_form): New function.
1468 (GEN_B): New macro.
1469 (GEN_BL): New macro.
1470 (gen_b_form): New function.
1471 (GEN_BNE): New macro.
1472 (GEN_LOAD): New macro.
1473 (GEN_STORE): New macro.
1474 (gen_limm): New function.
1475 (gen_atomic_xchg): New function.
1476 (gen_call): New function.
1477 (ppc_relocate_instruction): New function.
1478 (ppc_install_fast_tracepoint_jump_pad): New function.
1479 (ppc_get_min_fast_tracepoint_insn_len): New function.
1480 (ppc_get_ipa_tdesc_idx): New function.
1481 (the_low_target): Wire in the new functions.
1482 (initialize_low_arch) [!__powerpc64__]: Don'it initialize 64-bit
1483 tdescs.
1484 * linux-ppc-tdesc.h: New file.
1485
a13c4696
MK
14862016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
1487
1488 * linux-aarch64-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
1489 (alloc_jump_pad_buffer): New function.
1490 * linux-amd64-ipa.c: Add <sys/mman.h> include.
1491 (alloc_jump_pad_buffer): New function.
1492 * linux-i386-ipa.c (alloc_jump_pad_buffer): New function.
1493 * linux-s390-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
1494 (alloc_jump_pad_buffer): New function.
1495 * tracepoint.c (getauxval) [!HAVE_GETAUXVAL]: New function.
1496 (initialize_tracepoint): Delegate to alloc_jump_pad_buffer.
1497 * tracepoint.h (alloc_jump_pad_buffer): New prototype.
1498 (getauxval) [!HAVE_GETAUXVAL]: New prototype.
1499
1cda1512
MK
15002016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
1501
1502 * linux-aarch64-ipa.c: Rename gdb_agent_get_raw_reg to get_raw_reg.
1503 * linux-amd64-ipa.c: Likewise.
1504 * linux-i386-ipa.c: Likewise.
1505 * linux-s390-ipa.c: Likewise.
1506 * tracepoint.c: IPA-export gdb_collect_ptr instead of gdb_collect,
1507 ditto for get_raw_reg_ptr, get_trace_state_variable_value_ptr,
1508 set_trace_state_variable_value_ptr.
1509 (struct ipa_sym_addresses): Likewise.
1510 (symbol_list): Likewise.
1511 (install_fast_tracepoint): Dereference gdb_collect_ptr instead of
1512 accessing gdb_collect directly.
1513 (gdb_collect_ptr_type): New typedef.
1514 (get_raw_reg_ptr_type): New typedef.
1515 (get_trace_state_variable_value_ptr_type): New typedef.
1516 (set_trace_state_variable_value_ptr_type): New typedef.
1517 (gdb_collect_ptr): New global.
1518 (get_raw_reg_ptr): New global.
1519 (get_trace_state_variable_value_ptr): New global.
1520 (set_trace_state_variable_value_ptr): New global.
1521 (get_raw_reg_func_addr): Dereference get_raw_reg_ptr instead of
1522 accessing get_raw_reg directly.
1523 (get_get_tsv_func_addr): Likewise for
1524 get_trace_state_variable_value_ptr.
1525 (get_set_tsv_func_addr): Likewise for
1526 set_trace_state_variable_value_ptr.
1527 * tracepoint.h: Rename gdb_agent_get_raw_reg to get_raw_reg.
1528
72fb5488
SM
15292016-03-30 Simon Marchi <simon.marchi@ericsson.com>
1530
1531 * tracepoint.c (cmd_qtenable_disable): Remove whitespace.
1532
28170b88
MK
15332016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
1534
1535 * remote-utils.c (look_up_one_symbol): Remove own_buf, handle 'v'
1536 packets.
1537 (relocate_instruction): Remove own_buf.
1538 * server.c (own_buf): Make global.
1539 (handle_v_requests): Make global.
1540 * server.h (own_buf): New declaration.
1541 (handle_v_requests): New prototype.
1542
f39e8743
MK
15432016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
1544
1545 PR 18377
1546 * linux-s390-low.c (add_insns): New function.
1547 (s390_emit_prologue): New function.
1548 (s390_emit_epilogue): New function.
1549 (s390_emit_add): New function.
1550 (s390_emit_sub): New function.
1551 (s390_emit_mul): New function.
1552 (s390_emit_lsh): New function.
1553 (s390_emit_rsh_signed): New function.
1554 (s390_emit_rsh_unsigned): New function.
1555 (s390_emit_ext): New function.
1556 (s390_emit_log_not): New function.
1557 (s390_emit_bit_and): New function.
1558 (s390_emit_bit_or): New function.
1559 (s390_emit_bit_xor): New function.
1560 (s390_emit_bit_not): New function.
1561 (s390_emit_equal): New function.
1562 (s390_emit_less_signed): New function.
1563 (s390_emit_less_unsigned): New function.
1564 (s390_emit_ref): New function.
1565 (s390_emit_if_goto): New function.
1566 (s390_emit_goto): New function.
1567 (s390_write_goto_address): New function.
1568 (s390_emit_litpool): New function.
1569 (s390_emit_const): New function.
1570 (s390_emit_call): New function.
1571 (s390_emit_reg): New function.
1572 (s390_emit_pop): New function.
1573 (s390_emit_stack_flush): New function.
1574 (s390_emit_zero_ext): New function.
1575 (s390_emit_swap): New function.
1576 (s390_emit_stack_adjust): New function.
1577 (s390_emit_set_r2): New function.
1578 (s390_emit_int_call_1): New function.
1579 (s390_emit_void_call_2): New function.
1580 (s390_emit_eq_goto): New function.
1581 (s390_emit_ne_goto): New function.
1582 (s390_emit_lt_goto): New function.
1583 (s390_emit_le_goto): New function.
1584 (s390_emit_gt_goto): New function.
1585 (s390_emit_ge_goto): New function.
1586 (s390x_emit_prologue): New function.
1587 (s390x_emit_epilogue): New function.
1588 (s390x_emit_add): New function.
1589 (s390x_emit_sub): New function.
1590 (s390x_emit_mul): New function.
1591 (s390x_emit_lsh): New function.
1592 (s390x_emit_rsh_signed): New function.
1593 (s390x_emit_rsh_unsigned): New function.
1594 (s390x_emit_ext): New function.
1595 (s390x_emit_log_not): New function.
1596 (s390x_emit_bit_and): New function.
1597 (s390x_emit_bit_or): New function.
1598 (s390x_emit_bit_xor): New function.
1599 (s390x_emit_bit_not): New function.
1600 (s390x_emit_equal): New function.
1601 (s390x_emit_less_signed): New function.
1602 (s390x_emit_less_unsigned): New function.
1603 (s390x_emit_ref): New function.
1604 (s390x_emit_if_goto): New function.
1605 (s390x_emit_const): New function.
1606 (s390x_emit_call): New function.
1607 (s390x_emit_reg): New function.
1608 (s390x_emit_pop): New function.
1609 (s390x_emit_stack_flush): New function.
1610 (s390x_emit_zero_ext): New function.
1611 (s390x_emit_swap): New function.
1612 (s390x_emit_stack_adjust): New function.
1613 (s390x_emit_int_call_1): New function.
1614 (s390x_emit_void_call_2): New function.
1615 (s390x_emit_eq_goto): New function.
1616 (s390x_emit_ne_goto): New function.
1617 (s390x_emit_lt_goto): New function.
1618 (s390x_emit_le_goto): New function.
1619 (s390x_emit_gt_goto): New function.
1620 (s390x_emit_ge_goto): New function.
1621 (s390_emit_ops): New function.
1622 (struct linux_target_ops): Fill in emit_ops hook.
1623
abd9baf9
MK
16242016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
1625
1626 PR 18377
1627 * Makefile.in: Add s390 IPA files.
1628 * configure.srv: Build IPA for s390.
1629 * linux-s390-ipa.c: New file.
1630 * linux-s390-low.c: New includes - inttypes.h and linux-s390-tdesc.h.
1631 (init_registers_s390_linux32): Move declaration to linux-s390-tdesc.h.
1632 (tdesc_s390_linux32): Likewise.
1633 (init_registers_s390_linux32v1): Likewise.
1634 (tdesc_s390_linux32v1): Likewise.
1635 (init_registers_s390_linux32v2): Likewise.
1636 (tdesc_s390_linux32v2): Likewise.
1637 (init_registers_s390_linux64): Likewise.
1638 (tdesc_s390_linux64): Likewise.
1639 (init_registers_s390_linux64v1): Likewise.
1640 (tdesc_s390_linux64v1): Likewise.
1641 (init_registers_s390_linux64v2): Likewise.
1642 (tdesc_s390_linux64v2): Likewise.
1643 (init_registers_s390_te_linux64): Likewise.
1644 (tdesc_s390_te_linux64): Likewise.
1645 (init_registers_s390_vx_linux64): Likewise.
1646 (tdesc_s390_vx_linux64): Likewise.
1647 (init_registers_s390_tevx_linux64): Likewise.
1648 (tdesc_s390_tevx_linux64): Likewise.
1649 (init_registers_s390x_linux64): Likewise.
1650 (tdesc_s390x_linux64): Likewise.
1651 (init_registers_s390x_linux64v1): Likewise.
1652 (tdesc_s390x_linux64v1): Likewise.
1653 (init_registers_s390x_linux64v2): Likewise.
1654 (tdesc_s390x_linux64v2): Likewise.
1655 (init_registers_s390x_te_linux64): Likewise.
1656 (tdesc_s390x_te_linux64): Likewise.
1657 (init_registers_s390x_vx_linux64): Likewise.
1658 (tdesc_s390x_vx_linux64): Likewise.
1659 (init_registers_s390x_tevx_linux64): Likewise.
1660 (tdesc_s390x_tevx_linux64): Likewise.
1661 (have_hwcap_s390_vx): New static variable.
1662 (s390_arch_setup): Fill have_hwcap_s390_vx.
1663 (s390_get_thread_area): New function.
1664 (s390_ft_entry_gpr_esa): New const.
1665 (s390_ft_entry_gpr_zarch): New const.
1666 (s390_ft_entry_misc): New const.
1667 (s390_ft_entry_fr): New const.
1668 (s390_ft_entry_vr): New const.
1669 (s390_ft_main_31): New const.
1670 (s390_ft_main_64): New const.
1671 (s390_ft_exit_fr): New const.
1672 (s390_ft_exit_vr): New const.
1673 (s390_ft_exit_misc): New const.
1674 (s390_ft_exit_gpr_esa): New const.
1675 (s390_ft_exit_gpr_zarch): New const.
1676 (append_insns): New function.
1677 (s390_relocate_instruction): New function.
1678 (s390_install_fast_tracepoint_jump_pad): New function.
1679 (s390_get_min_fast_tracepoint_insn_len): New function.
1680 (s390_get_ipa_tdesc_idx): New function.
1681 (struct linux_target_ops): Wire in the above functions.
1682 (initialize_low_arch) [!__s390x__]: Don't initialize s390x tdescs.
1683 * linux-s390-tdesc.h: New file.
1684
a4105d04
MK
16852016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
1686
1687 * linux-s390-low.c (s390_supports_tracepoints): New function.
1688 (struct linux_target_ops): Fill supports_tracepoints hook.
1689
35ac8b3e
YQ
16902016-03-18 Yao Qi <yao.qi@linaro.org>
1691
1692 * linux-low.c (lwp_signal_can_be_delivered): New function.
1693 (linux_resume_one_lwp_throw): Use lwp_signal_can_be_delivered.
1694
94610ec4
YQ
16952016-03-18 Yao Qi <yao.qi@linaro.org>
1696
1697 * linux-low.c (linux_resume_one_lwp_throw): Set 'signal' to
1698 0 if signal is enqueued. Remove 'signal' from one debugging
1699 message. Move one debugging message to some lines below.
1700 Remove code setting 'signal' to 0.
1701
80aea927
YQ
17022016-03-18 Yao Qi <yao.qi@linaro.org>
1703
1704 * linux-low.c (linux_low_filter_event): Remove redundant
1705 WIFSTOPPED check together with linux_wstatus_maybe_breakpoint.
1706
b04fd3be
MK
17072016-03-09 Marcin Kościelnicki <koriakin@0x04.net>
1708
1709 * linux-ppc-low.c (ppc_supports_tracepoints): New function.
1710 (struct linux_target_ops): Wire in the above.
1711
c40c8d4b
YQ
17122016-03-03 Yao Qi <yao.qi@linaro.org>
1713
1714 * linux-low.c: Update comments to start_step_over.
1715
0f8288ae
YQ
17162016-03-03 Yao Qi <yao.qi@linaro.org>
1717
1718 PR server/19736
1719 * linux-low.c (handle_extended_wait): Set child suspended
1720 if event_lwp->bp_reinsert isn't zero.
1721
fdbd04a8
YQ
17222016-03-02 Yao Qi <yao.qi@linaro.org>
1723
1724 * linux-low.c (linux_resume_one_lwp_throw): Replace code with
1725 enqueue_pending_signal.
1726
6896a8fa
MK
17272016-03-02 Marcin Kościelnicki <koriakin@0x04.net>
1728
1729 * tracepoint.c (cmd_qtstart): Only set ipa_tdesc_idx if agent
1730 is actually loaded.
1731
ab503087
MK
17322016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
1733
1734 * linux-s390-low.c (s390_num_regs_3264): Define on 31-bit too.
1735 (s390_regmap_3264) [!__s390x__]: New global.
1736 (s390_collect_ptrace_register): Skip map entries containing -1.
1737 (s390_supply_ptrace_register): Ditto.
1738 (s390_fill_gprs_high): New function.
1739 (s390_store_gprs_high): New function.
1740 (s390_regsets): Add NT_S390_HIGH_GPRS.
1741 (s390_get_hwcap): Enable on 31-bit.
1742 (have_hwcap_s390_high_gprs): Enable on 31-bit.
1743 (s390_arch_setup): Enable detection of high GPRs, TDB, VX on 31-bit.
1744 Detect NT_S390_HIGH_GPRS.
1745 (s390_usrregs_info_3264): Enable on 31-bit.
1746 (s390_regs_info): Enable regs_info_3264 on 31-bit.
1747 (initialize_low_arch): Initialize s390_regsets_info_3264 on 31-bit.
1748
ae91f625
MK
17492016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
1750
1751 PR gdb/13808
1752 * Makefile.in: Add i386-*-linux-ipa.o and amd64-*-linux-ipa.o.
1753 * configure.srv: Ditto.
1754 * linux-aarch64-ipa.c (get_ipa_tdesc): New function.
1755 (initialize_low_tracepoint): Remove ipa_tdesc assignment.
1756 * linux-amd64-ipa.c: Add "linux-x86-tdesc.h" include.
1757 (init_registers_amd64_linux): Remove prototype.
1758 (tdesc_amd64_linux): Remove declaration.
1759 (get_ipa_tdesc): New function.
1760 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
1761 initialize remaining tdescs.
1762 * linux-i386-ipa.c: Add "linux-x86-tdesc.h" include.
1763 (init_registers_i386_linux): Remove prototype.
1764 (tdesc_i386_linux): Remove declaration.
1765 (get_ipa_tdesc): New function.
1766 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
1767 initialize remaining tdescs.
1768 * linux-low.c (linux_get_ipa_tdesc_idx): New function.
1769 (linux_target_ops): wire in linux_get_ipa_tdesc_idx.
1770 * linux-low.h (struct linux_target_ops): Add get_ipa_tdesc_idx.
1771 * linux-x86-low.c: Move tdesc declarations to linux-x86-tdesc.h.
1772 (x86_get_ipa_tdesc_idx): New function.
1773 (the_low_target): Wire in x86_get_ipa_tdesc_idx.
1774 * linux-x86-tdesc.h: New file.
1775 * target.h (struct target_ops): Add get_ipa_tdesc_idx.
1776 (target_get_ipa_tdesc_idx): New macro.
1777 * tracepoint.c (ipa_tdesc_idx): New macro.
1778 (struct ipa_sym_addresses): Add addr_ipa_tdesc_idx.
1779 (symbol_list): Add ipa_tdesc_idx.
1780 (cmd_qtstart): Write ipa_tdesc_idx in the target.
1781 (ipa_tdesc): Remove.
1782 (ipa_tdesc_idx): New variable.
1783 (get_context_regcache): Use get_ipa_tdesc.
1784 (gdb_collect): Ditto.
1785 (gdb_probe): Ditto.
1786 * tracepoint.h (get_ipa_tdesc): New prototype.
1787 (ipa_tdesc): Remove.
1788
e7ad2f14
PA
17892016-02-24 Pedro Alves <palves@redhat.com>
1790
1791 * linux-low.c (check_stopped_by_breakpoint): Rename to ...
1792 (save_stop_reason): ... this. Use GDB_ARCH_IS_TRAP_HWBKPT and
1793 handle ambiguous GDB_ARCH_IS_TRAP_BRKPT / GDB_ARCH_IS_TRAP_HWBKPT.
1794 Factor out common code between the USE_SIGTRAP_SIGINFO and
1795 !USE_SIGTRAP_SIGINFO blocks.
1796 (linux_low_filter_event): Call save_stop_reason instead of
1797 check_stopped_by_breakpoint and check_stopped_by_watchpoint.
1798 Update comments.
1799 (linux_wait_1): Update comments.
1800
657f9cde
WW
18012016-02-24 Wei-cheng Wang <cole945@gmail.com>
1802
1803 * linux-ppc-low.c (ppc_supports_z_point_type): New function:
1804 (ppc_insert_point, ppc_remove_point): Insert/remove z-packet breakpoints.
1805 (ppc64_emit_ops_vector): Add target ops - ppc_supports_z_point_type,
1806 ppc_insert_point, ppc_remove_point.
1807
b00b61e1
MK
18082016-02-17 Marcin Kościelnicki <koriakin@0x04.net>
1809
1810 * linux-s390-low.c (s390_supports_z_point_type): New function.
1811 (struct linux_target_ops): Wire s390_supports_z_point_type in.
1812
553cb527
YQ
18132016-02-16 Yao Qi <yao.qi@linaro.org>
1814
1815 * linux-arm-low.c (get_next_pcs_syscall_next_pc): Remove argument
1816 PC. Get pc from regcache_read_pc.
1817
a5652c21
YQ
18182016-02-12 Yao Qi <yao.qi@linaro.org>
1819
1820 * linux-aarch64-low.c (aarch64_get_pc): Call linux_get_pc_64bit
1821 or linux_get_pc_32bit.
1822 (aarch64_set_pc): Call linux_set_pc_64bit or linux_set_pc_32bit.
1823
ed443b61
YQ
18242016-02-12 Yao Qi <yao.qi@linaro.org>
1825
1826 * linux-arm-low.c (get_next_pcs_ops): Initialize it with
1827 arm_linux_get_next_pcs_fixup.
1828
020ecd38
MK
18292016-02-12 Marcin Kościelnicki <koriakin@0x04.net>
1830
1831 * tracepoint.c (x_tracepoint_action_download): Change
1832 write_inferior_data_ptr to write_inferior_data_pointer.
1833 (cmd_qtstart): Likewise.
1834 (write_inferior_data_ptr): Remove.
1835 (download_agent_expr): Change write_inferior_data_ptr to
1836 write_inferior_data_pointer.
1837 (download_tracepoint_1): Likewise.
1838 (download_tracepoint): Likewise.
1839 (download_trace_state_variables): Likewise.
1840
7cae9051
WW
18412016-02-11 Wei-cheng Wang <cole945@gmail.com>
1842 Marcin Kościelnicki <koriakin@0x04.net>
1843
1844 * tracepoint.c (struct tracepoint_action_ops): Remove.
1845 (struct tracepoint_action): Remove ops.
1846 (m_tracepoint_action_download, r_tracepoint_action_download)
1847 (x_tracepoint_action_download, l_tracepoint_action_download): Adjust
1848 size and offset accordingly.
1849 (m_tracepoint_action_ops, r_tracepoint_action_ops)
1850 (x_tracepoint_action_ops, l_tracepoint_action_ops): Remove.
1851 (tracepoint_action_send, tracepoint_action_download): New functions.
1852 Helpers for trace action handlers.
1853 (add_tracepoint_action): Remove setup actions ops.
1854 (download_tracepoint_1, tracepoint_send_agent): Call helper functions.
1855
9f6a71b4
YQ
18562016-02-10 Yao Qi <yao.qi@linaro.org>
1857
1858 * regcache.c (regcache_raw_read_unsigned): Clear *VAL.
1859
1e94266c
SM
18602016-02-09 Simon Marchi <simon.marchi@ericsson.com>
1861
1862 * configure.ac: Use AC_CONFIG_FILES instead of passing arguments
1863 to AC_OUTPUT.
1864 * configure: Regenerate.
1865
8adce034
SM
18662016-02-09 Simon Marchi <simon.marchi@ericsson.com>
1867
1868 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): Change
1869 void * to gdb_byte *.
1870 * linux-low.c (siginfo_fixup): Likewise.
1871 (linux_xfer_siginfo): Likewise.
1872 * linux-low.h (struct linux_target_ops) <siginfo_fixup>:
1873 Likewise.
1874 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
1875
93813b37
WT
18762016-02-02 Walfred Tedeschi <walfred.tedeschi@intel.com>
1877
1878 * configure.srv (x86_64-*-linux*): Add amd64-linux-siginfo.o
1879 to srv_tgtobj.
1880 (i[34567]86-*-linux*): Add amd64-linux-siginfo.o
1881 to srv_tgtobj.
1882 * linux-x86-low.c [__x86_64__]: Include
1883 "nat/amd64-linux-siginfo.h".
1884 (compat_siginfo_from_siginfo, siginfo_from_compat_siginfo)
1885 (compat_x32_siginfo_from_siginfo, siginfo_from_compat_x32_siginfo)
1886 (compat_timeval, compat_sigval, compat_x32_clock, cpt_si_pid)
1887 (cpt_si_uid, cpt_si_timerid, cpt_si_overrun, cpt_si_status)
1888 (cpt_si_utime, cpt_si_stime, cpt_si_ptr, cpt_si_addr, cpt_si_band)
1889 (cpt_si_fd, si_timerid, si_overrun): Move from
1890 nat/amd64-linux-siginfo.c.
1891 * Makefile.in (amd64-linux-siginfo.o:): New rule.
1892
8424cc97
SM
18932016-01-28 Simon Marchi <simon.marchi@ericsson.com>
1894
1895 * server.c (skip_to_semicolon): Remove.
1896 (process_point_options): Use strchrnul instead of
1897 skip_to_semicolon.
1898
4d18591b
YQ
18992016-01-26 Yao Qi <yao.qi@linaro.org>
1900
1901 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Remove argument pc.
1902 * linux-low.c (install_software_single_step_breakpoints): Don't
1903 call regcache_read_pc.
1904 * linux-low.h (struct linux_target_ops) <get_next_pcs>: Remove
1905 argument pc.
1906
d8020970
YQ
19072016-01-26 Yao Qi <yao.qi@linaro.org>
1908
1909 * linux-low.c (install_software_single_step_breakpoints): Call
1910 regcache_read_pc instead of get_pc.
1911
8b207339
YQ
19122016-01-26 Yao Qi <yao.qi@linaro.org>
1913
1914 * remote-utils.c (remote_close) [!USE_WIN32API]: Ignore SIGIO.
1915 (unblock_async_io): Rename to ...
1916 (block_unblock_async_io): ... it. New function.
1917 (enable_async_io): Don't install SIGIO handler. Unblock it
1918 instead.
1919 (disable_async_io): Don't ignore SIGIO. Block it instead.
1920 (initialize_async_io): Install SIGIO handler. Don't call
1921 unblock_async_io.
1922
18879fef
YQ
19232016-01-26 Yao Qi <yao.qi@linaro.org>
1924
1925 * remote-utils.c (getpkt): If the buffer isn't empty, and the
1926 first character is '\003', call *the_target->request_interrupt.
1927
a0f8e08a
YQ
19282016-01-25 Yao Qi <yao.qi@linaro.org>
1929
1930 * remote-utils.c (new_thread_notify): Remove.
1931 (dead_thread_notify): Likewise.
1932 * remote-utils.h (new_thread_notify): Remove declaration.
1933 (dead_thread_notify): Likewise.
1934
cc5fd9ab
MK
19352016-01-23 Marcin Kościelnicki <koriakin@0x04.net>
1936
1937 * gdb.trace/pending.exp: Fix expected message on continue.
1938
99e8eb11
MK
19392016-01-22 Marcin Kościelnicki <koriakin@0x04.net>
1940
1941 * tracepoint.c (write_inferior_data_ptr): Cast to uintptr_t, so that
1942 it works properly on big-endian machines where sizeof (CORE_ADDR)
1943 != sizeof (void *).
1944
a994041d
PA
19452016-01-21 Pedro Alves <palves@redhat.com>
1946
1947 * Makefile.in (COMPILER_CFLAGS, CXXFLAGS): New.
1948 (INTERNAL_CFLAGS_BASE): Use COMPILER_CFLAGS instead of CFLAGS.
1949 * configure: Regenerate.
1950
f7a6a40d
YQ
19512016-01-21 Yao Qi <yao.qi@linaro.org>
1952
1953 * linux-arm-low.c (arm_sigreturn_next_pc): Add parameter
1954 is_thumb and set it according to CPSR saved on the stack.
1955 (get_next_pcs_syscall_next_pc): Pass is_thumb to
1956 arm_sigreturn_next_pc.
1957
6f69e520
YQ
19582016-01-18 Yao Qi <yao.qi@linaro.org>
1959
1960 * linux-low.c (linux_set_pc_64bit): New function.
1961 (linux_get_pc_64bit): New function.
1962 * linux-low.h (linux_set_pc_64bit, linux_get_pc_64bit):
1963 Declare.
1964 * linux-sparc-low.c (debug_threads): Remove declaration.
1965 (sparc_get_pc): Remove.
1966 (the_low_target): Use linux_get_pc_64bit instead of
1967 sparc_get_pc.
1968 * linux-tile-low.c (tile_get_pc, tile_set_pc): Remove.
1969 (the_low_target): Use linux_get_pc_64bit and
1970 linux_set_pc_64bit.
1971
276d4552
YQ
19722016-01-18 Yao Qi <yao.qi@linaro.org>
1973
1974 * linux-arm-low.c (debug_threads): Remove declaration.
1975 (arm_get_pc, arm_set_pc): Remove.
1976 (the_low_target): Use linux_get_pc_32bit and
1977 linux_set_pc_32bit.
1978 * linux-bfin-low.c (bfin_get_pc, bfin_set_pc): Remove.
1979 (the_low_target): Use linux_get_pc_32bit and
1980 linux_set_pc_32bit.
1981 * linux-cris-low.c (debug_threads): Remove declaration.
1982 (cris_get_pc, cris_set_pc,): Remove.
1983 (the_low_target): Use linux_get_pc_32bit and
1984 linux_set_pc_32bit.
1985 * linux-crisv32-low.c (debug_threads): Remove declaration.
1986 (cris_get_pc, cris_set_pc): Remove.
1987 (the_low_target): Use linux_get_pc_32bit and
1988 linux_set_pc_32bit.
1989 * linux-low.c: Include inttypes.h.
1990 (linux_get_pc_32bit, linux_set_pc_32bit): New functions.
1991 * linux-low.h (linux_get_pc_32bit, linux_set_pc_32bit): Declare.
1992 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Remove.
1993 (the_low_target): Use linux_get_pc_32bit and
1994 linux_set_pc_32bit.
1995 * linux-m68k-low.c (m68k_get_pc, m68k_set_pc): Remove.
1996 (the_low_target): Use linux_get_pc_32bit and
1997 linux_set_pc_32bit.
1998 * linux-nios2-low.c (nios2_get_pc, nios2_set_pc): Remove.
1999 (the_low_target): Use linux_get_pc_32bit and
2000 linux_set_pc_32bit.
2001 * linux-sh-low.c (sh_get_pc, sh_set_pc): Remove.
2002 (the_low_target): Use linux_get_pc_32bit and
2003 linux_set_pc_32bit.
2004 * linux-xtensa-low.c (xtensa_get_pc, xtensa_set_pc): Remove.
2005 (the_low_target): Use linux_get_pc_32bit and
2006 linux_set_pc_32bit.
2007
eb0edac8
GB
20082016-01-18 Gary Benson <gbenson@redhat.com>
2009
2010 * configure.ac (AC_FUNC_FORK): New check.
2011 * config.in: Regenerate.
2012 * configure: Likewise.
2013
1b451dda
YQ
20142016-01-14 Yao Qi <yao.qi@linaro.org>
2015
2016 * linux-aarch32-low.c (thumb2_breakpoint): Make it static.
2017 * linux-aarch32-low.h (thumb2_breakpoint): Remove declaration.
2018 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Pass 1 to
2019 arm_get_next_pcs_ctor.
2020
82075af2
JS
20212016-01-12 Josh Stone <jistone@redhat.com>
2022 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2023
2024 * inferiors.h: Include "gdb_vecs.h".
2025 (struct process_info): Add syscalls_to_catch.
2026 * inferiors.c (remove_process): Free syscalls_to_catch.
2027 * remote-utils.c (prepare_resume_reply): Report syscall_entry and
2028 syscall_return stops.
2029 * server.h (UNKNOWN_SYSCALL, ANY_SYSCALL): Define.
2030 * server.c (handle_general_set): Handle QCatchSyscalls.
2031 (handle_query): Report support for QCatchSyscalls.
2032 * target.h (struct target_ops): Add supports_catch_syscall.
2033 (target_supports_catch_syscall): New macro.
2034 * linux-low.h (struct linux_target_ops): Add get_syscall_trapinfo.
2035 (struct lwp_info): Add syscall_state.
2036 * linux-low.c (handle_extended_wait): Mark syscall_state as an entry.
2037 Maintain syscall_state and syscalls_to_catch across exec.
2038 (get_syscall_trapinfo): New function, proxy to the_low_target.
2039 (linux_low_ptrace_options): Enable PTRACE_O_TRACESYSGOOD.
2040 (linux_low_filter_event): Toggle syscall_state entry/return for
2041 syscall traps, and set it ignored for all others.
2042 (gdb_catching_syscalls_p): New function.
2043 (gdb_catch_this_syscall_p): New function.
2044 (linux_wait_1): Handle SYSCALL_SIGTRAP.
2045 (linux_resume_one_lwp_throw): Add PTRACE_SYSCALL possibility.
2046 (linux_supports_catch_syscall): New function.
2047 (linux_target_ops): Install it.
2048 * linux-x86-low.c (x86_get_syscall_trapinfo): New function.
2049 (the_low_target): Install it.
2050
8f13a3ce
MF
20512016-01-12 Mike Frysinger <vapier@gentoo.org>
2052
2053 * acinclude.m4: Include new ../warning.m4 file.
2054 * configure: Regenerated.
2055 * configure.ac: Replace all warning logic with AM_GDB_WARNINGS.
2056
5b3da067
MF
20572016-01-12 Mike Frysinger <vapier@gentoo.org>
2058
2059 * ax.c (is_goto_target): Mark static.
2060 * linux-low.c (register_addr): Likewise.
2061 (linux_fetch_registers, linux_store_registers): Likewise.
2062 * mem-break.c (any_persistent_commands): Fix old prototype.
2063 (add_commands_to_breakpoint): Mark static.
2064 * regcache.c (find_register_by_name): Delete unused func.
2065 * remote-utils.c (hex_or_minus_one): Mark static.
2066 * server.c (monitor_show_help): Mark static.
2067 (handle_query, handle_v_cont, handle_v_attach, handle_v_kill,
2068 handle_v_requests): Likewise.
2069
bc504a31
PA
20702016-01-12 Pedro Alves <palves@redhat.com>
2071
2072 Remove use of the registered trademark symbol throughout.
2073
5a0dd67a
YQ
20742016-01-08 Yao Qi <yao.qi@linaro.org>
2075
2076 * remote-utils.c (getpkt): If c is '\003', call target hook
2077 request_interrupt.
2078
b2ca446f
YQ
20792016-01-06 Yao Qi <yao.qi@linaro.org>
2080
2081 * linux-aarch32-low.h (arm_abi_breakpoint): Move to
2082 linux-aarch32-low.c.
2083 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
2084 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
2085 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
2086 (thumb2_breakpoint): Declare.
2087 * linux-aarch32-low.c (arm_abi_breakpoint): Moved from
2088 linux-aarch32-low.h.
2089 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
2090 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
2091 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
2092
edd88788
JB
20932016-01-01 Joel Brobecker <brobecker@adacore.com>
2094
2095 * gdbreplay.c (gdbreplay_version): Change copyright year in
2096 version message.
2097 * server.c (gdbserver_version): Likewise.
2098
65da7f14
PP
20992015-12-28 Patrick Palka <patrick@parcs.ath.cx>
2100
2101 * server.c (crc32_table): Delete.
2102 (crc32): Use libiberty's xcrc32 function.
2103
4abd5ed2
JB
21042015-12-22 Joel Brobecker <brobecker@adacore.com>
2105
2106 * lynx-low.c (lynx_delete_thread_callback): New function.
2107 (lynx_mourn): Properly delete our process and all of its
2108 threads. Remove call to clear_inferiors.
2109
0e50fe5c
JB
21102015-12-22 Joel Brobecker <brobecker@adacore.com>
2111
2112 * target.c (thread_search_callback): Add check that
2113 the thread_stopped target callback is not NULL before
2114 calling it.
2115
35adc03f
YQ
21162015-12-21 Yao Qi <yao.qi@linaro.org>
2117
2118 * linux-aarch32-low.h [__aarch64__]: Use arm_abi_breakpoint
2119 arm breakpoint.
2120
bd2b2909
AT
21212015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
2122
2123 * server.c (handle_query): Call target_supports_software_single_step.
2124
7fe5e27e
AT
21252015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
2126
2127 * linux-low.c (single_step): New function.
2128 (linux_resume_one_lwp_throw): Call single_step.
2129 (start_step_over): Likewise.
2130
d9311bfa
AT
21312015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
2132
2133 * Makefile.in (SFILES): Append arch/arm-linux.c,
2134 arch/arm-get-next-pcs.c.
2135 (arm-linux.o): New rule.
2136 (arm-get-next-pcs.o): New rule.
2137 * configure.srv (arm*-*-linux*): Add arm-get-next-pcs.o,
2138 arm-linux.o.
2139 * linux-aarch32-low.c (arm_abi_breakpoint): Remove macro. Moved
2140 to linux-aarch32-low.c.
2141 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
2142 (arm_breakpoint_len, thumb_breakpoint): Likewise.
2143 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
2144 (thumb2_breakpoint_len): Likewise.
2145 (arm_is_thumb_mode): Make non-static.
2146 * linux-aarch32-low.h (arm_abi_breakpoint): New macro. Moved
2147 from linux-aarch32-low.c.
2148 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
2149 (arm_breakpoint_len, thumb_breakpoint): Likewise.
2150 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
2151 (thumb2_breakpoint_len): Likewise.
2152 (arm_is_thumb_mode): New declaration.
2153 * linux-arm-low.c: Include arch/arm-linux.h
2154 aarch/arm-get-next-pcs.h, sys/syscall.h.
2155 (get_next_pcs_ops): New struct.
2156 (get_next_pcs_addr_bits_remove): New function.
2157 (get_next_pcs_is_thumb): New function.
2158 (get_next_pcs_read_memory_unsigned_integer): Likewise.
2159 (arm_sigreturn_next_pc): Likewise.
2160 (get_next_pcs_syscall_next_pc): Likewise.
2161 (arm_gdbserver_get_next_pcs): Likewise.
2162 (struct linux_target_ops) <arm_gdbserver_get_next_pcs>:
2163 Initialize.
2164 * linux-low.h: Move CORE_ADDR vector definition to gdb_vecs.h.
2165 * server.h: Include gdb_vecs.h.
2166
68ce2059
AT
21672015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
2168
2169 * Makefile.in (SFILES): Append common/common-regcache.c.
2170 (OBS): Append common-regcache.o.
2171 (common-regcache.o): New rule.
2172 * regcache.c (init_register_cache): Initialize cache to
2173 REG_UNAVAILABLE.
2174 (regcache_raw_read_unsigned): New function.
2175 * regcache.h (REG_UNAVAILABLE, REG_VALID): Replaced by shared
2176 register_status enum.
2177
fa5308bd
AT
21782015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
2179
2180 * linux-aarch64-low.c (the_low_targets): Rename
2181 breakpoint_reinsert_addr to get_next_pcs.
2182 * linux-arm-low.c (the_low_targets): Likewise.
2183 * linux-bfin-low.c (the_low_targets): Likewise.
2184 * linux-cris-low.c (the_low_targets): Likewise.
2185 * linux-crisv32-low.c (the_low_targets): Likewise.
2186 * linux-low.c (can_software_single_step): Likewise.
2187 (install_software_single_step_breakpoints): New function.
2188 (start_step_over): Use install_software_single_step_breakpoints.
2189 * linux-low.h: New CORE_ADDR vector.
2190 (struct linux_target_ops) Rename breakpoint_reinsert_addr to
2191 get_next_pcs.
2192 * linux-mips-low.c (the_low_targets): Likewise.
2193 * linux-nios2-low.c (the_low_targets): Likewise.
2194 * linux-sparc-low.c (the_low_targets): Likewise.
2195
4a6ed09b
PA
21962015-12-17 Pedro Alves <palves@redhat.com>
2197
2198 * linux-low.c (linux_kill_one_lwp): Remove references to
2199 LinuxThreads.
2200 (kill_lwp): Remove HAVE_TKILL_SYSCALL check. No longer fall back
2201 to 'kill'.
2202 (linux_init_signals): Delete.
2203 (initialize_low): Adjust.
2204 * thread-db.c (thread_db_init): Remove LinuxThreads reference.
2205
7544db95
PA
22062015-12-16 Pedro Alves <palves@redhat.com>
2207
2208 * configure.ac (compiler warning flags): When testing a
2209 -Wno-foo option, check whether -Wfoo works instead.
2210 * configure: Regenerate.
2211
8020350c
DB
22122015-12-11 Don Breazeal <donb@codesourcery.com>
2213
2214 * server.c (process_serial_event): Don't exit from gdbserver
2215 in remote mode if there are still active inferiors.
2216
db91f502
YQ
22172015-12-11 Yao Qi <yao.qi@linaro.org>
2218
2219 * linux-aarch64-low.c (aarch64_breakpoint_at): Call
2220 arm_breakpoint_at if the process is 32-bit.
2221
b37a6290
YQ
22222015-12-11 Yao Qi <yao.qi@linaro.org>
2223
2224 * linux-aarch32-low.c [__aarch64__]: Use arm_abi_breakpoint
2225 arm breakpoint.
2226
17b1509a
YQ
22272015-12-07 Yao Qi <yao.qi@linaro.org>
2228
2229 * configure.srv: Append arm.o to srv_tgtobj for
2230 aarch64*-*-linux* target.
2231 * linux-aarch32-low.c (arm_abi_breakpoint): New macro. Moved
2232 from linux-arm-low.c.
2233 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
2234 (arm_breakpoint_len, thumb_breakpoint): Likewise.
2235 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
2236 (thumb2_breakpoint_len): Likewise.
2237 (arm_is_thumb_mode, arm_breakpoint_at): Likewise.
2238 (arm_breakpoint_kinds): Likewise.
2239 (arm_breakpoint_kind_from_pc): Likewise.
2240 (arm_sw_breakpoint_from_kind): Likewise.
2241 (arm_breakpoint_kind_from_current_state): Likewise.
2242 * linux-aarch32-low.h (arm_breakpoint_kind_from_pc): Declare.
2243 (arm_sw_breakpoint_from_kind): Declare.
2244 (arm_breakpoint_kind_from_current_state): Declare.
2245 (arm_breakpoint_at): Declare.
2246 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): Call
2247 arm_sw_breakpoint_from_kind if process is 32-bit.
2248 (aarch64_breakpoint_kind_from_pc): New function.
2249 (aarch64_breakpoint_kind_from_current_state): New function.
2250 (the_low_target): Initialize fields breakpoint_kind_from_pc
2251 and breakpoint_kind_from_current_state.
2252 * linux-arm-low.c (arm_breakpoint_kinds): Move to
2253 linux-aarch32-low.c.
2254 (arm_abi_breakpoint, arm_eabi_breakpoint): Likewise.
2255 (arm_breakpoint, arm_breakpoint_len): Likewise.
2256 (thumb_breakpoint, thumb_breakpoint_len): Likewise.
2257 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
2258 (arm_is_thumb_mode): Likewise.
2259 (arm_breakpoint_at): Likewise.
2260 (arm_breakpoint_kind_from_pc): Likewise.
2261 (arm_sw_breakpoint_from_kind): Likewise.
2262 (arm_breakpoint_kind_from_current_state): Likewise.
2263
2264 Revert:
2265 2015-08-04 Yao Qi <yao.qi@linaro.org>
2266
2267 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
2268 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
2269 * server.c (extended_protocol): Remove "static".
2270 * server.h (extended_protocol): Declare it.
2271
ece66d65
JS
22722015-12-04 Josh Stone <jistone@redhat.com>
2273
2274 * target.h (struct target_ops) <arch_setup>: Rename to ...
2275 (struct target_ops) <post_create_inferior>: ... this.
2276 (target_arch_setup): Rename to ...
2277 (target_post_create_inferior): ... this, calling post_create_inferior.
2278 * server.c (start_inferior): Update target_arch_setup calls to
2279 target_post_create_inferior.
2280 * linux-low.c (linux_low_ptrace_options): Forward declare.
2281 (linux_arch_setup): Update its comment for general use.
2282 (linux_post_create_inferior): New, run arch_setup and setup ptrace.
2283 (struct linux_target_ops): Use linux_post_create_inferior.
2284 * lynx-low.c (struct lynx_target_ops): Update arch_setup stub comment
2285 to post_create_inferior.
2286 * nto-low.c (struct nto_target_ops): Likewise.
2287 * spu-low.c (struct spu_target_ops): Likewise.
2288 * win32-low.c (struct win32_target_ops): Likewise.
2289
e58c48b4
AT
22902015-12-03 Antoine Tremblay <antoine.tremblay@ericsson.com>
2291
2292 * linux-arm-low.c: Remove duplicate arch/arm.h include.
2293
fbec8956
AT
22942015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
2295
2296 * linux-arm-low.c (arm_reinsert_addr): Remove function.
2297 (struct linux_target_ops <breakpoint_reinsert_addr>: Set to NULL.
2298 * linux-cris-low.c (cris_reinsert_addr> Remove function.
2299 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
2300 * linux-crisv32-low.c (cris_reinsert_addr): Remove function.
2301 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
2302 * linux-mips-low.c (mips_reinsert_addr): Remove function.
2303 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
2304 * linux-nios2-low.c (nios2_reinsert_addr): Remove function.
2305 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
2306 * linux-sparc-low.c (sparc_reinsert_addr): Remove function.
2307 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
2308
9b4c5f87
AT
23092015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
2310
2311 * linux-low.c (linux_look_up_symbols): Don't call
2312 linux_supports_traceclone.
2313 * linux-low.h (thread_db_init): Remove use_events argument.
2314 * thread-db.c (thread_db_use_event): Remove global variable.
2315 (struct thread_db) <td_thr_event_enable_p>: Remove field.
2316 (struct thread_db) <td_create_bp>: Remove field.
2317 (thread_db_create_event): Remove function.
2318 (thread_db_enable_reporting): Likewise.
2319 (find_one_thread): Don't check for thread_db_use_events.
2320 (attach_thread): Likewise.
2321 (thread_db_load_search): Remove td_thr_event_enable_p initialization.
2322 (try_thread_db_load_1): Don't check for thread_db_use_events.
2323 (thread_db_init): Remove use_events argument and thread events
2324 handling.
2325 (remove_thread_event_breakpoints): Remove function.
2326 (thread_db_detach): Remove call to remove_thred_event_breakpoints.
2327
7d00775e
AT
23282015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
2329
2330 * linux-aarch64-low.c (aarch64_supports_hardware_single_step):
2331 New function.
2332 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
2333 * linux-arm-low.c (arm_supports_hardware_single_step): New function.
2334 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
2335 * linux-bfin-low.c (bfin_supports_hardware_single_step): New function.
2336 (struct linux_target_ops) <bfin_supports_hardware_single_step>:
2337 Initialize.
2338 * linux-crisv32-low.c (cris_supports_hardware_single_step):
2339 New function.
2340 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
2341 * linux-low.c (can_hardware_single_step): Use
2342 supports_hardware_single_step.
2343 (can_software_single_step): New function.
2344 (start_step_over): Call can_software_single_step.
2345 (linux_supports_hardware_single_step): New function.
2346 (struct target_ops) <supports_software_single_step>: Initialize.
2347 * linux-low.h (struct linux_target_ops)
2348 <supports_hardware_single_step>: Initialize.
2349 * linux-m32r-low.c (m32r_supports_hardware_single_step): New function.
2350 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
2351 * linux-ppc-low.c (ppc_supports_hardware_single_step): New function.
2352 (struct linux_target_ops) <supports_hardware_single_step> Initialize.
2353 * linux-s390-low.c (s390_supports_hardware_single_step): New function.
2354 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
2355 * linux-sh-low.c (sh_supports_hardware_single_step): New function.
2356 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
2357 * linux-tic6x-low.c (tic6x_supports_hardware_single_step): New function.
2358 (struct linux_target_ops) <tic6x_supports_hardware_single_step>:
2359 Initialize.
2360 * linux-tile-low.c (tile_supports_hardware_single_step): New function.
2361 (struct linux_target_ops) <tile_supports_hardware_single_step>:
2362 Initialize.
2363 * linux-x86-low.c (x86_supports_hardware_single_step) New function.
2364 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
2365 * linux-xtensa-low.c (xtensa_supports_hardware_single_step):
2366 New function.
2367 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
2368 * target.h (struct target_ops): <supports_software_single_step>:
2369 New field.
2370 (target_supports_software_single_step): New macro.
2371
2d97cd35
AT
23722015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
2373
2374 * linux-low.c (linux_wait_1): Fix pc advance condition.
2375 * mem-break.c (reinsert_breakpoint_inserted_here): New function.
2376 * mem-break.h (reinsert_breakpoint_inserted_here): New declaration.
2377
769ef81f
AT
23782015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
2379
2380 * linux-arm-low.c (arm_is_thumb_mode): New function.
2381 (arm_breakpoint_at): Use arm_is_thumb_mode.
2382 (arm_breakpoint_kind_from_current_state): New function.
2383 (struct linux_target_ops) <breakpoint_kind_from_current_state>:
2384 Initialize.
2385 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_current_state.
2386 (linux_breakpoint_kind_from_current_state): New function.
2387 (struct target_ops <breakpoint_kind_from_current_state>: Initialize.
2388 * linux-low.h (struct linux_target_ops)
2389 <breakpoint_kind_from_current_state>: New field.
2390 * target.h (struct target_ops): Likewise.
2391 (target_breakpoint_kind_from_current_state): New macro.
2392
1bebeeca
PA
23932015-11-30 Pedro Alves <palves@redhat.com>
2394
2395 * linux-low.c (linux_resume): Wake up the event loop before
2396 returning.
2397
a67a9fae
PA
23982015-11-30 Pedro Alves <palves@redhat.com>
2399
2400 * mem-break.c (check_gdb_bp_preconditions): Remove current_thread
2401 check.
2402 (set_gdb_breakpoint): If prepare_to_access_memory fails, set *ERR
2403 to -1.
2404 * target.c (struct thread_search): New structure.
2405 (thread_search_callback): New function.
2406 (prev_general_thread): New global.
2407 (prepare_to_access_memory, done_accessing_memory): New functions.
2408 * target.h (prepare_to_access_memory, done_accessing_memory):
2409 Replace macros with function declarations.
2410
f2faf941
PA
24112015-11-30 Pedro Alves <palves@redhat.com>
2412
2413 PR 14618
2414 * linux-low.c (linux_wait_1): If the last resumed thread is gone,
2415 report TARGET_WAITKIND_NO_RESUMED.
2416 * remote-utils.c (prepare_resume_reply): Handle
2417 TARGET_WAITKIND_NO_RESUMED.
2418 * server.c (report_no_resumed): New global.
2419 (handle_query) <qSupported>: Handle "no-resumed+". Report
2420 "no-resumed+" support.
2421 (resume): When the target reports TARGET_WAITKIND_NO_RESUMED, only
2422 return error if the client doesn't support no-resumed events.
2423 (push_stop_notification): New function.
2424 (handle_target_event): Use it. Report TARGET_WAITKIND_NO_RESUMED
2425 events if the client supports them.
2426
a681f9c9
PA
24272015-11-30 Pedro Alves <palves@redhat.com>
2428
2429 * linux-low.c (thread_still_has_status_pending_p): Don't check
2430 vCont;t here.
2431 (lwp_resumed): New function.
2432 (status_pending_p_callback): Return early if the LWP is not
2433 supposed to be resumed.
2434
65706a29
PA
24352015-11-30 Pedro Alves <palves@redhat.com>
2436
2437 * linux-low.c (handle_extended_wait): Assert that the LWP's
2438 waitstatus is TARGET_WAITKIND_IGNORE. If GDB wants to hear about
2439 thread create events, leave the new child's status pending.
2440 (linux_low_filter_event): If GDB wants to hear about thread exit
2441 events, leave the LWP marked dead and don't delete it.
2442 (linux_wait_for_event_filtered): Don't check for thread exit.
2443 (filter_exit_event): New function.
2444 (linux_wait_1): Use it, when returning an exit event.
2445 (linux_resume_one_lwp_throw): Assert that the LWP's
2446 waitstatus is TARGET_WAITKIND_IGNORE.
2447 * remote-utils.c (prepare_resume_reply): Handle
2448 TARGET_WAITKIND_THREAD_CREATED and TARGET_WAITKIND_THREAD_EXITED.
2449 * server.c (report_thread_events): New global.
2450 (handle_general_set): Handle QThreadEvents.
2451 (handle_query) <qSupported>: Handle and report QThreadEvents+;
2452 (handle_target_event): Handle TARGET_WAITKIND_THREAD_CREATED and
2453 TARGET_WAITKIND_THREAD_EXITED.
2454 * server.h (report_thread_events): Declare.
2455
56cf4bed
PA
24562015-11-30 Pedro Alves <palves@redhat.com>
2457
2458 * linux-low.c (resume_stopped_resumed_lwps): Don't check whether
2459 the thread's last_resume_kind was resume_stop.
2460
500c1d85
PA
24612015-11-30 Pedro Alves <palves@redhat.com>
2462
2463 * linux-low.c (linux_attach): In non-stop mode, wait for one stop
2464 before returning.
2465
de979965
PA
24662015-11-30 Pedro Alves <palves@redhat.com>
2467
2468 * server.c (handle_v_requests): Handle vCtrlC.
2469
34c65914
PA
24702015-11-30 Pedro Alves <palves@redhat.com>
2471
2472 * gdbthread.h (find_any_thread_of_pid): Declare.
2473 * inferiors.c (thread_of_pid, find_any_thread_of_pid): New
2474 functions.
2475 * server.c (handle_query): If current_thread is NULL, look for
2476 another thread of the selected process.
2477
79efa585 24782015-11-26 Daniel Colascione <dancol@dancol.org>
01a49af8 2479 Simon Marchi <simon.marchi@ericsson.com>
79efa585
SM
2480
2481 * linux-low.c (linux_target_ops): Use linux_proc_tid_get_name.
2482 * server.c (handle_qxfer_threads_worker): Refactor to include thread
2483 name in reply.
2484 * target.h (struct target_ops) <thread_name>: New field.
2485 (target_thread_name): New macro.
2486
80d82c19
JB
24872015-11-23 Joel Brobecker <brobecker@adacore.com>
2488
2489 * regcache.h (regcache_invalidate_pid): Add declaration.
2490 * regcache.c (regcache_invalidate_pid): New function, extracted
2491 from regcache_invalidate.
2492 (regcache_invalidate): Reimplement using regcache_invalidate_pid.
2493 Add trivial documentation comment.
2494 * lynx-low.c: Use regcache_invalidate_pid instead of
2495 regcache_invalidate.
2496
64da5dd5
JB
24972015-11-23 Joel Brobecker <brobecker@adacore.com>
2498
2499 * configure.ac: Do not call AC_CHECK_TYPES for Elf32_auxv_t
2500 and Elf64_auxv_t if the target is Android.
2501
37ce4055
DE
25022015-11-22 Doug Evans <xdje42@gmail.com>
2503
2504 * target.h: #include <sys/types.h>.
2505
06e03fff
PA
25062015-11-19 Pedro Alves <palves@redhat.com>
2507
2508 * linux-low.c (linux_process_qsupported): Change prototype.
2509 Adjust.
2510 * linux-low.h (struct linux_target_ops) <process_qsupported>:
2511 Change prototype.
2512 * linux-x86-low.c (x86_linux_process_qsupported): Change prototype
2513 and adjust to loop over all features.
2514 * server.c (handle_query) <qSupported>: Adjust to call
2515 target_process_qsupported once, passing it a vector of unprocessed
2516 features.
2517 * target.h (struct target_ops) <process_qsupported>: Change
2518 prototype.
2519 (target_process_qsupported): Adjust.
2520
9a084706
PA
25212015-11-19 Pedro Alves <palves@redhat.com>
2522
2523 * configure.ac (ERROR_ON_WARNING): Don't check whether in C++
2524 mode.
2525 * configure: Regenerate.
2526
dad44a1f
PA
25272015-11-19 Pedro Alves <palves@redhat.com>
2528
2529 * configure: Regenerate.
2530
231c0592
YQ
25312015-11-19 Yao Qi <yao.qi@linaro.org>
2532
2533 * linux-aarch64-low.c (emit_data_processing_reg): Change opcode
2534 type to uint32_t.
2535
6c1c9a8b
YQ
25362015-11-19 Yao Qi <yao.qi@linaro.org>
2537
2538 * linux-aarch64-low.c (enum aarch64_operand_type): New.
2539 (struct aarch64_operand): Move enum out.
2540
9caa3311
YQ
25412015-11-19 Yao Qi <yao.qi@linaro.org>
2542
2543 * linux-aarch64-low.c (aarch64_fill_fpregset): Cast buf to
2544 struct user_fpsimd_state *.
2545 (aarch64_store_fpregset): Likewise.
2546
6a69a054
YQ
25472015-11-19 Yao Qi <yao.qi@linaro.org>
2548
2549 * linux-aarch64-low.c (aarch64_fill_gregset): Cast buf to
2550 struct user_pt_regs *.
2551 (aarch64_store_gregset): Likewise.
2552
1798301e
PA
25532015-11-18 Pedro Alves <palves@redhat.com>
2554
2555 * Makefile.in (all_object_files): Add $IPA_OBJS.
2556
ce7715e2
PA
25572015-11-17 Pedro Alves <palves@redhat.com>
2558
2559 * win32-low.c (win32_resume): Use gdb_signal_from_host,
2560 GDB_SIGNAL_0 and gdb_signal_to_string.
2561
c0879059
PA
25622015-11-17 Pedro Alves <palves@redhat.com>
2563
2564 * win32-low.c (handle_output_debug_string): Remove parameter.
2565 (win32_kill): Remove our_status local and adjust call to
2566 handle_output_debug_string.
2567 (get_child_debug_event): Adjust call to
2568 handle_output_debug_string.
2569
1996e237
SM
25702015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
2571
2572 * linux-mips-low.c (mips_fill_gregset): Add cast.
2573 (mips_store_gregset): Likewise.
2574 (mips_fill_fpregset): Likewise.
2575 (mips_store_fpregset): Likewise.
2576
cbec665b
SM
25772015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
2578
2579 * linux-mips-low.c (mips_add_watchpoint): Rename private to
2580 priv.
2581
eb3e3c67
SM
25822015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
2583
2584 * linux-mips-low.c (mips_linux_new_thread): Change type of
2585 watch_type to enum target_hw_bp_type.
2586
171de4b8
SM
25872015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
2588
2589 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type):
2590 Change return type to arm_hwbp_type.
2591
04248ead
SM
25922015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
2593
2594 * linux-aarch32-low.c (arm_fill_gregset): Add cast.
2595 (arm_store_gregset): Likewise.
2596 * linux-arm-low.c (arm_get_hwcap): Likewise.
2597 (arm_read_description): Likewise.
2598
04b3479c
SM
25992015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
2600
2601 * linux-aarch32-low.c (aarch32_regsets): Use NULL_REGSET.
2602
2bc84e8a
SM
26032015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
2604
2605 * linux-ppc-low.c (ppc_get_hwcap): Add cast.
2606 (ppc_fill_vsxregset): Likewise.
2607 (ppc_store_vsxregset): Likewise.
2608 (ppc_fill_vrregset): Likewise.
2609 (ppc_store_vrregset): Likewise.
2610 (ppc_fill_evrregset): Likewise.
2611 (ppc_store_evrregset): Likewise.
2612
e6c5bb05
SM
26132015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
2614
2615 * linux-ppc-low.c (ppc_usrregs_info): Remove
2616 forward-declaration.
2617 (ppc_arch_setup): Move lower in file.
2618
7ea45d72
SM
26192015-10-30 Simon Marchi <simon.marchi@ericsson.com>
2620
2621 * proc-service.c (ps_pdread): Change CORE_ADDR cast to uintptr_t.
2622 (ps_pdwrite): Likewise.
2623
69291610
HW
26242015-10-29 Henrik Wallin <henrik.wallin@windriver.com>
2625
2626 * linux-arm-low.c (arm_new_thread): Move pointer dereference
2627 to after assert checks.
2628
b42945fd
SM
26292015-10-29 Simon Marchi <simon.marchi@ericsson.com>
2630
2631 * proc-service.c (ps_pdread): Add/adjust casts.
2632 (ps_pdwrite): Add/adjust casts.
2633
d6f85c84
SM
26342015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
2635
2636 * server.c (handle_search_memory_1): Cast return value of
2637 memmem.
2638
f98cd059
SM
26392015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
2640
2641 * server.c (write_qxfer_response): Change type of data to
2642 gdb_byte *.
2643
d2412fa5
PA
26442015-10-29 Pedro Alves <palves@redhat.com>
2645
2646 * mem-break.c (Z_packet_to_bkpt_type): Add cast.
2647
c17414a2
PA
26482015-10-29 Pedro Alves <palves@redhat.com>
2649
2650 * tracepoint.c (clear_installed_tracepoints): Add casts.
2651
e053fbc4
PA
26522015-10-29 Pedro Alves <palves@redhat.com>
2653
2654 * server.c (handle_v_cont, process_serial_event): Add enum
2655 gdb_signal casts to signal parsing code.
2656
add67df8
PA
26572015-10-29 Pedro Alves <palves@redhat.com>
2658
2659 * linux-low.h (NULL_REGSET): Define.
2660 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
2661 * linux-arm-low.c (arm_regsets): Likewise.
2662 * linux-crisv32-low.c (cris_regsets): Likewise.
2663 * linux-m68k-low.c (m68k_regsets): Likewise.
2664 * linux-mips-low.c (mips_regsets): Likewise.
2665 * linux-nios2-low.c (nios2_regsets): Likewise.
2666 * linux-ppc-low.c (ppc_regsets): Likewise.
2667 * linux-s390-low.c (s390_regsets): Likewise.
2668 * linux-sh-low.c (sh_regsets): Likewise.
2669 * linux-sparc-low.c (sparc_regsets): Likewise.
2670 * linux-tic6x-low.c (tic6x_regsets): Likewise.
2671 * linux-tile-low.c (tile_regsets): Likewise.
2672 * linux-x86-low.c (x86_regsets): Likewise.
2673 * linux-xtensa-low.c (xtensa_regsets): Likewise.
2674
50bc912a
PA
26752015-10-29 Pedro Alves <palves@redhat.com>
2676
2677 * linux-low.h (NULL_REGSET): Define.
2678 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
2679 * linux-arm-low.c (arm_regsets): Likewise.
2680 * linux-crisv32-low.c (cris_regsets): Likewise.
2681 * linux-m68k-low.c (m68k_regsets): Likewise.
2682 * linux-mips-low.c (mips_regsets): Likewise.
2683 * linux-nios2-low.c (nios2_regsets): Likewise.
2684 * linux-ppc-low.c (ppc_regsets): Likewise.
2685 * linux-s390-low.c (s390_regsets): Likewise.
2686 * linux-sh-low.c (sh_regsets): Likewise.
2687 * linux-sparc-low.c (sparc_regsets): Likewise.
2688 * linux-tic6x-low.c (tic6x_regsets): Likewise.
2689 * linux-tile-low.c (tile_regsets): Likewise.
2690 * linux-x86-low.c (x86_regsets): Likewise.
2691 * linux-xtensa-low.c (xtensa_regsets): Likewise.
2692
682b2546
DE
26932015-10-26 Doug Evans <dje@google.com>
2694
2695 * linux-low.c (__SIGRTMIN): Move to nat/linux-nat.h.
2696
963843d4
DE
26972015-10-26 Doug Evans <dje@google.com>
2698
2699 * linux-low.c (W_STOPCODE): Moved to common/gdb_wait.h.
2700
d41401ac
DE
27012015-10-26 Doug Evans <dje@google.com>
2702
2703 * thread-db.c (find_one_thread): Cast ti.ti_tid to unsigned long
2704 for debug_printf.
2705 (attach_thread, find_new_threads_callback): Ditto.
2706
3db28855
AT
27072015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
2708
2709 * mem-break.h (set_breakpoint_data): Remove.
2710
fb78e89c
AT
27112015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
2712
2713 * nto-low.c (nto_sw_breakpoint_from_kind): New function.
2714 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
2715 (initialize_low): Remove set_breakpoint_data call.
2716 * spu-low.c (spu_sw_breakpoint_from_kind): New function.
2717 (struct target_ops) <sw_breakpoint_from_kind>: Iniitalize.
2718 (initialize_low): Remove set_breakpoint_data call.
2719 * win32-low.c (win32_sw_breakpoint_from_kind): New function.
2720 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
2721 (initialize_low): Remove set_breakpoint_data call.
2722
2e6ee069
AT
27232015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
2724
2725 * linux-low.c (default_breakpoint_kind_from_pc): Move to target.c.
2726 * mem-break.c (set_breakpoint_at): Use target_breakpoint_kind_from_pc.
2727 * target.c (default_breakpoint_kind_from_pc): Moved from linux-low.c
2728 * target.h (target_breakpoint_kind_from_pc): New macro.
2729
1652a986
AT
27302015-10-22 Antoine Tremblay <antoine.tremblay@ericsson.com>
2731
2732 * linux-low.c (default_breakpoint_kind_from_pc): New function.
2733 (linux_breakpoint_kind_from_pc): Use default_breakpoint_kind_from_pc for
2734 the default breakpoint kind.
2735
abeead09
AT
27362015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
2737
2738 * linux-arm-low.c (arm_supports_z_point_type): Add software
2739 breakpoint support.
2740
b0b4b501
AT
27412015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
2742
2743 * linux-arm-low.c: Refactor breakpoint definitions.
2744 (arm_breakpoint_at): Adjust for arm_abi_breakpoint.
2745 (arm_sw_breakpoint_from_kind): Adjust for arm_breakpoint.
2746
8689682c
AT
27472015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
2748
2749 * Makefile.in: Add arm.c/o.
2750 * configure.srv: Likewise.
2751 * linux-arm-low.c (arm_breakpoint_kinds): New enum.
2752 (arm_breakpoint_kind_from_pc): New function.
2753 (arm_sw_breakpoint_from_kind): Return proper kind.
2754 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize.
2755
27165294
AT
27562015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
2757
2758 * linux-low.c (initialize_low): Ajdust for breakpoint global variables
2759 removal.
2760 * mem-break.c : Remove breakpoint_data/breakpoint_len global variables.
2761 (struct raw_breakpoint) <size>: Remove.
2762 (struct raw_breakpoint) <kind>: Add.
2763 (bp_size): New function.
2764 (bp_opcode): Likewise.
2765 (find_raw_breakpoint_at): Adjust for kind.
2766 (insert_memory_breakpoint): Adjust for kind call bp_size,bp_opcode.
2767 (remove_memory_breakpoint): Adjust for kind call bp_size.
2768 (set_raw_breakpoint_at): Adjust for kind.
2769 (set_breakpoint): Likewise.
2770 (set_breakpoint_at): Call breakpoint_kind_from_pc.
2771 (delete_raw_breakpoint): Adjust for kind.
2772 (delete_breakpoint): Likewise.
2773 (find_gdb_breakpoint): Likewise.
2774 (set_gdb_breakpoint_1): Likewise.
2775 (set_gdb_breakpoint): Likewise.
2776 (delete_gdb_breakpoint_1): Likewise.
2777 (delete_gdb_breakpoint): Likewise.
2778 (uninsert_raw_breakpoint): Likewise.
2779 (reinsert_raw_breakpoint): Likewise.
2780 (set_breakpoint_data): Remove.
2781 (validate_inserted_breakpoint): Adjust for kind call bp_size,bp_opcode.
2782 (check_mem_read): Adjust for kind call bp_size.
2783 (check_mem_write): Adjust for kind call bp_size,bp_opcode.
2784 (clone_one_breakpoint): Adjust for kind.
2785 * mem-break.h (set_gdb_breakpoint): Likewise.
2786 (delete_gdb_breakpoint): Likewise.
2787 * server.c (process_serial_event): Likewise.
2788
dd373349
AT
27892015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
2790
2791 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): New function.
2792 (struct linux_target_ops) <breakpoint>: Remove.
2793 (struct linux_target_ops) <breakpoint_len>: Remove.
2794 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
2795 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
2796 * linux-arm-low.c (arm_breakpoint_kind_from_pc): New function.
2797 (arm_sw_breakpoint_from_kind): New function.
2798 * linux-bfin-low.c (bfin_sw_breakpoint_from_kind): New function.
2799 (struct linux_target_ops) <breakpoint>: Remove.
2800 (struct linux_target_ops) <breakpoint_len>: Remove.
2801 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
2802 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
2803 * linux-cris-low.c (cris_sw_breakpoint_from_kind): New function.
2804 (struct linux_target_ops) <breakpoint>: Remove.
2805 (struct linux_target_ops) <breakpoint_len>: Remove.
2806 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
2807 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
2808 * linux-crisv32-low.c (cris_sw_breakpoint_from_kind): New function.
2809 (struct linux_target_ops) <breakpoint>: Remove.
2810 (struct linux_target_ops) <breakpoint_len>: Remove.
2811 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
2812 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
2813 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_pc
2814 and sw_breakpoint_from_kind to increment the pc.
2815 (linux_breakpoint_kind_from_pc): New function.
2816 (linux_sw_breakpoint_from_kind): New function.
2817 (struct target_ops) <sw_breakpoint_from_kind>: Initialize field.
2818 (initialize_low): Call breakpoint_kind_from_pc and
2819 sw_breakpoint_from_kind to replace breakpoint_data/len.
2820 * linux-low.h (struct linux_target_ops) <breakpoint_kind_from_pc>:
2821 New field.
2822 (struct linux_target_ops) <sw_breakpoint_from_kind>: Likewise.
2823 * linux-m32r-low.c (m32r_sw_breakpoint_from_kind): New function.
2824 (struct linux_target_ops) <breakpoint>: Remove.
2825 (struct linux_target_ops) <breakpoint_len>: Remove.
2826 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
2827 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
2828 * linux-m68k-low.c (m68k_sw_breakpoint_from_kind): New function.
2829 (struct linux_target_ops) <breakpoint>: Remove.
2830 (struct linux_target_ops) <breakpoint_len>: Remove.
2831 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
2832 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
2833 * linux-mips-low.c (mips_sw_breakpoint_from_kind): New function.
2834 (struct linux_target_ops) <breakpoint>: Remove.
2835 (struct linux_target_ops) <breakpoint_len>: Remove.
2836 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
2837 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
2838 * linux-nios2-low.c (nios2_sw_breakpoint_from_kind): New function.
2839 (struct linux_target_ops) <breakpoint>: Remove.
2840 (struct linux_target_ops) <breakpoint_len>: Remove.
2841 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
2842 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
2843 * linux-ppc-low.c (ppc_sw_breakpoint_from_kind): New function.
2844 (struct linux_target_ops) <breakpoint>: Remove.
2845 (struct linux_target_ops) <breakpoint_len>: Remove.
2846 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
2847 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
2848 * linux-s390-low.c (s390_sw_breakpoint_from_kind): New function.
2849 (struct linux_target_ops) <breakpoint>: Remove.
2850 (struct linux_target_ops) <breakpoint_len>: Remove.
2851 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
2852 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
2853 * linux-sh-low.c (sh_sw_breakpoint_from_kind): New function.
2854 (struct linux_target_ops) <breakpoint>: Remove.
2855 (struct linux_target_ops) <breakpoint_len>: Remove.
2856 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
2857 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
2858 * linux-sparc-low.c (sparc_sw_breakpoint_from_kind): New function.
2859 (struct linux_target_ops) <breakpoint>: Remove.
2860 (struct linux_target_ops) <breakpoint_len>: Remove.
2861 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
2862 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
2863 * linux-tic6x-low.c (tic6x_sw_breakpoint_from_kind): New function.
2864 (struct linux_target_ops) <breakpoint>: Remove.
2865 (struct linux_target_ops) <breakpoint_len>: Remove.
2866 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
2867 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
2868 * linux-tile-low.c (tile_sw_breakpoint_from_kind): New function.
2869 * linux-x86-low.c (x86_sw_breakpoint_from_kind): New function.
2870 (struct linux_target_ops) <breakpoint>: Remove.
2871 (struct linux_target_ops) <breakpoint_len>: Remove.
2872 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
2873 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
2874 * linux-xtensa-low.c (xtensa_sw_breakpoint_from_kind) New function.
2875 (struct linux_target_ops) <breakpoint>: Remove.
2876 (struct linux_target_ops) <breakpoint_len>: Remove.
2877 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
2878 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
2879
4cd98a19
AT
28802015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
2881
2882 * linux-cris-low.c (cris_get_pc): Remove void arg.
2883
774ee6d2
AR
28842015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
2885
2886 * gdbserver/nto-low.c (nto_insert_point, nto_remove_point): Fix
2887 variable name.
2888
833dcd29
AR
28892015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
2890
2891 * inferiors.c (thread_pid_matches_callback): New function.
2892 (find_thread_process): New function.
2893 (remove_thread): Reset current_thread.
2894 (remove_process): Assert threads have been removed first.
2895
8d689ee5
YQ
28962015-10-15 Yao Qi <yao.qi@linaro.org>
2897
2898 * linux-aarch64-low.c (aarch64_insert_point): Set len to 2
2899 if it is 3.
2900 (aarch64_remove_point): Likewise.
2901 * regcache.c (regcache_register_size): New function.
2902
1c2e1515
YQ
29032015-10-12 Yao Qi <yao.qi@linaro.org>
2904
2905 * linux-aarch64-low.c: Update all callers as emit_load_store
2906 is renamed to aarch64_emit_load_store.
2907
e1c587c3
YQ
29082015-10-12 Yao Qi <yao.qi@linaro.org>
2909
2910 * linux-aarch64-low.c: Update all callers of function renaming
2911 from emit_insn to aarch64_emit_insn.
2912
b6542f81
YQ
29132015-10-12 Yao Qi <yao.qi@linaro.org>
2914
2915 * linux-aarch64-low.c (enum aarch64_opcodes): Move to
2916 arch/aarch64-insn.h.
2917 (struct aarch64_memory_operand): Likewise.
2918 (ENCODE): Likewise.
2919 (emit_insn): Move to arch/aarch64-insn.c.
2920 (emit_b, emit_bcond, emit_cb, emit_tb): Remove.
2921 (emit_load_store): Move to arch/aarch64-insn.c.
2922 (emit_ldr, emit_ldrb, emit_ldrsw, emit_nop): Remove.
2923 (can_encode_int32): Remove.
2924
246994ce
YQ
29252015-10-12 Yao Qi <yao.qi@linaro.org>
2926
2927 * linux-aarch64-low.c (extract_signed_bitfield): Remove.
2928 (aarch64_decode_ldr_literal): Move to gdb/arch/aarch64-insn.c.
2929 (aarch64_relocate_instruction): Likewise.
2930 (struct aarch64_insn_data): Move to gdb/arch/aarch64-insn.h.
2931 (struct aarch64_insn_visitor): Likewise.
2932
0badd99f
YQ
29332015-10-12 Yao Qi <yao.qi@linaro.org>
2934
2935 * linux-aarch64-low.c (struct aarch64_insn_data): New.
2936 (struct aarch64_insn_visitor): New.
2937 (struct aarch64_insn_relocation_data): New.
2938 (aarch64_ftrace_insn_reloc_b): New function.
2939 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
2940 (aarch64_ftrace_insn_reloc_cb): Likewise.
2941 (aarch64_ftrace_insn_reloc_tb): Likewise.
2942 (aarch64_ftrace_insn_reloc_adr): Likewise.
2943 (aarch64_ftrace_insn_reloc_ldr_literal): Likewise.
2944 (aarch64_ftrace_insn_reloc_others): Likewise.
2945 (visitor): New.
2946 (aarch64_relocate_instruction): Use visitor.
2947
dfaffe9d
YQ
29482015-10-12 Yao Qi <yao.qi@linaro.org>
2949
2950 * linux-aarch64-low.c (aarch64_relocate_instruction): Return
2951 int. Add argument buf.
2952 (aarch64_install_fast_tracepoint_jump_pad): Pass buf to
2953 aarch64_relocate_instruction.
2954
70b439f0
YQ
29552015-10-12 Yao Qi <yao.qi@linaro.org>
2956
2957 * linux-aarch64-low.c (aarch64_relocate_instruction): Add
2958 argument insn. Remove local variable insn. Don't call
2959 target_read_uint32.
2960 (aarch64_install_fast_tracepoint_jump_pad): Call
2961 target_read_uint32.
2962
7781c06f
YQ
29632015-09-30 Yao Qi <yao.qi@linaro.org>
2964
2965 * linux-aarch64-low.c (emit_movk): Shorten a long line.
2966 (emit_load_store_pair): Likewise.
2967
9a3c8263
SM
29682015-09-25 Simon Marchi <simon.marchi@ericsson.com>
2969
2970 * dll.c (match_dll): Add cast(s).
2971 (unloaded_dll): Likewise.
2972 * linux-low.c (second_thread_of_pid_p): Likewise.
2973 (delete_lwp_callback): Likewise.
2974 (count_events_callback): Likewise.
2975 (select_event_lwp_callback): Likewise.
2976 (linux_set_resume_request): Likewise.
2977 * server.c (accumulate_file_name_length): Likewise.
2978 (emit_dll_description): Likewise.
2979 (handle_qxfer_threads_worker): Likewise.
2980 (visit_actioned_threads): Likewise.
2981 * thread-db.c (any_thread_of): Likewise.
2982 * tracepoint.c (same_process_p): Likewise.
2983 (match_blocktype): Likewise.
2984 (build_traceframe_info_xml): Likewise.
2985
224c3ddb
SM
29862015-09-25 Simon Marchi <simon.marchi@ericsson.com>
2987
2988 * ax.c (gdb_parse_agent_expr): Add cast to allocation result
2989 assignment.
2990 (gdb_unparse_agent_expr): Likewise.
2991 * hostio.c (require_data): Likewise.
2992 (handle_pread): Likewise.
2993 * linux-low.c (disable_regset): Likewise.
2994 (fetch_register): Likewise.
2995 (store_register): Likewise.
2996 (get_dynamic): Likewise.
2997 (linux_qxfer_libraries_svr4): Likewise.
2998 * mem-break.c (delete_fast_tracepoint_jump): Likewise.
2999 (set_fast_tracepoint_jump): Likewise.
3000 (uninsert_fast_tracepoint_jumps_at): Likewise.
3001 (reinsert_fast_tracepoint_jumps_at): Likewise.
3002 (validate_inserted_breakpoint): Likewise.
3003 (clone_agent_expr): Likewise.
3004 * regcache.c (init_register_cache): Likewise.
3005 * remote-utils.c (putpkt_binary_1): Likewise.
3006 (decode_M_packet): Likewise.
3007 (decode_X_packet): Likewise.
3008 (look_up_one_symbol): Likewise.
3009 (relocate_instruction): Likewise.
3010 (monitor_output): Likewise.
3011 * server.c (handle_search_memory): Likewise.
3012 (handle_qxfer_exec_file): Likewise.
3013 (handle_qxfer_libraries): Likewise.
3014 (handle_qxfer): Likewise.
3015 (handle_query): Likewise.
3016 (handle_v_cont): Likewise.
3017 (handle_v_run): Likewise.
3018 (captured_main): Likewise.
3019 * target.c (write_inferior_memory): Likewise.
3020 * thread-db.c (try_thread_db_load_from_dir): Likewise.
3021 * tracepoint.c (init_trace_buffer): Likewise.
3022 (add_tracepoint_action): Likewise.
3023 (add_traceframe): Likewise.
3024 (add_traceframe_block): Likewise.
3025 (cmd_qtdpsrc): Likewise.
3026 (cmd_qtdv): Likewise.
3027 (cmd_qtstatus): Likewise.
3028 (response_source): Likewise.
3029 (response_tsv): Likewise.
3030 (cmd_qtnotes): Likewise.
3031 (gdb_collect): Likewise.
3032 (initialize_tracepoint): Likewise.
3033
afbe19f8
PL
30342015-09-21 Pierre Langlois <pierre.langlois@arm.com>
3035
3036 * linux-aarch64-low-.c: Include ax.h and tracepoint.h.
3037 (enum aarch64_opcodes) <RET>, <SUBS>, <AND>, <ORR>, <ORN>,
3038 <EOR>, <LSLV>, <LSRV>, <ASRV>, <SBFM>, <UBFM>, <CSINC>, <MUL>,
3039 <NOP>: New.
3040 (enum aarch64_condition_codes): New enum.
3041 (w0): New static global.
3042 (fp): Likewise.
3043 (lr): Likewise.
3044 (struct aarch64_memory_operand) <type>: New
3045 MEMORY_OPERAND_POSTINDEX type.
3046 (postindex_memory_operand): New helper function.
3047 (emit_ret): New function.
3048 (emit_load_store_pair): New function, factored out of emit_stp
3049 with support for MEMORY_OPERAND_POSTINDEX.
3050 (emit_stp): Rewrite using emit_load_store_pair.
3051 (emit_ldp): New function.
3052 (emit_load_store): Likewise.
3053 (emit_ldr): Mention post-index instruction in comment.
3054 (emit_ldrh): New function.
3055 (emit_ldrb): New function.
3056 (emit_ldrsw): Mention post-index instruction in comment.
3057 (emit_str): Likewise.
3058 (emit_subs): New function.
3059 (emit_cmp): Likewise.
3060 (emit_and): Likewise.
3061 (emit_orr): Likewise.
3062 (emit_orn): Likewise.
3063 (emit_eor): Likewise.
3064 (emit_mvn): Likewise.
3065 (emit_lslv): Likewise.
3066 (emit_lsrv): Likewise.
3067 (emit_asrv): Likewise.
3068 (emit_mul): Likewise.
3069 (emit_sbfm): Likewise.
3070 (emit_sbfx): Likewise.
3071 (emit_ubfm): Likewise.
3072 (emit_ubfx): Likewise.
3073 (emit_csinc): Likewise.
3074 (emit_cset): Likewise.
3075 (emit_nop): Likewise.
3076 (emit_ops_insns): New helper function.
3077 (emit_pop): Likewise.
3078 (emit_push): Likewise.
3079 (aarch64_emit_prologue): New function.
3080 (aarch64_emit_epilogue): Likewise.
3081 (aarch64_emit_add): Likewise.
3082 (aarch64_emit_sub): Likewise.
3083 (aarch64_emit_mul): Likewise.
3084 (aarch64_emit_lsh): Likewise.
3085 (aarch64_emit_rsh_signed): Likewise.
3086 (aarch64_emit_rsh_unsigned): Likewise.
3087 (aarch64_emit_ext): Likewise.
3088 (aarch64_emit_log_not): Likewise.
3089 (aarch64_emit_bit_and): Likewise.
3090 (aarch64_emit_bit_or): Likewise.
3091 (aarch64_emit_bit_xor): Likewise.
3092 (aarch64_emit_bit_not): Likewise.
3093 (aarch64_emit_equal): Likewise.
3094 (aarch64_emit_less_signed): Likewise.
3095 (aarch64_emit_less_unsigned): Likewise.
3096 (aarch64_emit_ref): Likewise.
3097 (aarch64_emit_if_goto): Likewise.
3098 (aarch64_emit_goto): Likewise.
3099 (aarch64_write_goto_address): Likewise.
3100 (aarch64_emit_const): Likewise.
3101 (aarch64_emit_call): Likewise.
3102 (aarch64_emit_reg): Likewise.
3103 (aarch64_emit_pop): Likewise.
3104 (aarch64_emit_stack_flush): Likewise.
3105 (aarch64_emit_zero_ext): Likewise.
3106 (aarch64_emit_swap): Likewise.
3107 (aarch64_emit_stack_adjust): Likewise.
3108 (aarch64_emit_int_call_1): Likewise.
3109 (aarch64_emit_void_call_2): Likewise.
3110 (aarch64_emit_eq_goto): Likewise.
3111 (aarch64_emit_ne_goto): Likewise.
3112 (aarch64_emit_lt_goto): Likewise.
3113 (aarch64_emit_le_goto): Likewise.
3114 (aarch64_emit_gt_goto): Likewise.
3115 (aarch64_emit_ge_got): Likewise.
3116 (aarch64_emit_ops_impl): New static global variable.
3117 (aarch64_emit_ops): New target function, return
3118 &aarch64_emit_ops_impl.
3119 (struct linux_target_ops): Install it.
3120
bb903df0
PL
31212015-09-21 Pierre Langlois <pierre.langlois@arm.com>
3122
3123 * Makefile.in (linux-aarch64-ipa.o, aarch64-ipa.o): New rules.
3124 * configure.srv (aarch64*-*-linux*): Add linux-aarch64-ipa.o and
3125 aarch64-ipa.o.
3126 * linux-aarch64-ipa.c: New file.
3127 * linux-aarch64-low.c: Include arch/aarch64-insn.h, inttypes.h
3128 and endian.h.
3129 (aarch64_get_thread_area): New target method.
3130 (extract_signed_bitfield): New helper function.
3131 (aarch64_decode_ldr_literal): New function.
3132 (enum aarch64_opcodes): New enum.
3133 (struct aarch64_register): New struct.
3134 (struct aarch64_operand): New struct.
3135 (x0): New static global.
3136 (x1): Likewise.
3137 (x2): Likewise.
3138 (x3): Likewise.
3139 (x4): Likewise.
3140 (w2): Likewise.
3141 (ip0): Likewise.
3142 (sp): Likewise.
3143 (xzr): Likewise.
3144 (aarch64_register): New helper function.
3145 (register_operand): Likewise.
3146 (immediate_operand): Likewise.
3147 (struct aarch64_memory_operand): New struct.
3148 (offset_memory_operand): New helper function.
3149 (preindex_memory_operand): Likewise.
3150 (enum aarch64_system_control_registers): New enum.
3151 (ENCODE): New macro.
3152 (emit_insn): New helper function.
3153 (emit_b): New function.
3154 (emit_bcond): Likewise.
3155 (emit_cb): Likewise.
3156 (emit_tb): Likewise.
3157 (emit_blr): Likewise.
3158 (emit_stp): Likewise.
3159 (emit_ldp_q_offset): Likewise.
3160 (emit_stp_q_offset): Likewise.
3161 (emit_load_store): Likewise.
3162 (emit_ldr): Likewise.
3163 (emit_ldrsw): Likewise.
3164 (emit_str): Likewise.
3165 (emit_ldaxr): Likewise.
3166 (emit_stxr): Likewise.
3167 (emit_stlr): Likewise.
3168 (emit_data_processing_reg): Likewise.
3169 (emit_data_processing): Likewise.
3170 (emit_add): Likewise.
3171 (emit_sub): Likewise.
3172 (emit_mov): Likewise.
3173 (emit_movk): Likewise.
3174 (emit_mov_addr): Likewise.
3175 (emit_mrs): Likewise.
3176 (emit_msr): Likewise.
3177 (emit_sevl): Likewise.
3178 (emit_wfe): Likewise.
3179 (append_insns): Likewise.
3180 (can_encode_int32_in): New helper function.
3181 (aarch64_relocate_instruction): New function.
3182 (aarch64_install_fast_tracepoint_jump_pad): Likewise.
3183 (aarch64_get_min_fast_tracepoint_insn_len): Likewise.
3184 (struct linux_target_ops): Install aarch64_get_thread_area,
3185 aarch64_install_fast_tracepoint_jump_pad and
3186 aarch64_get_min_fast_tracepoint_insn_len.
3187
787749ea
PL
31882015-09-21 Pierre Langlois <pierre.langlois@arm.com>
3189
3190 * Makefile.in (aarch64-insn.o): New rule.
3191 * configure.srv (aarch64*-*-linux*): Add aarch64-insn.o.
3192
9812b2e6
YQ
31932015-09-21 Yao Qi <yao.qi@linaro.org>
3194
3195 * ax.c [!IN_PROCESS_AGENT] (gdb_agent_op_sizes): Define it.
3196
18fe412b
YQ
31972015-09-21 Yao Qi <yao.qi@linaro.org>
3198
3199 * tracepoint.c (max_jump_pad_size): Remove.
3200
a0cc84cd
YQ
32012015-09-18 Yao Qi <yao.qi@linaro.org>
3202
3203 * linux-aarch64-low.c: Don't include sys/uio.h.
3204 (ps_get_thread_area): Call aarch64_ps_get_thread_area.
3205
d78908cf
WW
32062015-09-16 Wei-cheng Wang <cole945@gmail.com>
3207
3208 * tracepoint.c (eval_result_type): Change prototype.
3209 (condition_true_at_tracepoint): Fix argument to compiled_cond.
3210
d57e0d50
PA
32112015-09-15 Pedro Alves <palves@redhat.com>
3212
3213 * remote-utils.c (prepare_resume_reply) <TARGET_WAITKIND_EXECD>:
3214 Check whether to report exec events instead of checking whether
3215 multiprocess is enabled.
3216
5a676acc
PA
32172015-09-15 Pedro Alves <palves@redhat.com>
3218
3219 PR remote/18965
3220 * remote-utils.c (prepare_resume_reply): Merge
3221 TARGET_WAITKIND_VFORK_DONE switch case with the
3222 TARGET_WAITKIND_FORKED case.
3223
7c5d0fad
YQ
32242015-09-15 Yao Qi <yao.qi@linaro.org>
3225
3226 * server.c (handle_query): Check string comparison using
3227 "else if" instead of "if".
3228
750ce8d1
YQ
32292015-09-15 Yao Qi <yao.qi@linaro.org>
3230
3231 * server.c (vCont_supported): New global variable.
3232 (handle_query): Set vCont_supported to 1 if "vContSupported+"
3233 matches. Append ";vContSupported+" to own_buf.
3234 (handle_v_requests): Append ";s;S" to own_buf if target supports
3235 hardware single step or vCont_supported is false.
3236 (capture_main): Set vCont_supported to zero.
3237
70b90b91
YQ
32382015-09-15 Yao Qi <yao.qi@linaro.org>
3239
3240 * linux-low.c (linux_supports_conditional_breakpoints): Rename
3241 it to ...
3242 (linux_supports_hardware_single_step): ... New function.
3243 (linux_target_ops): Update.
3244 * lynx-low.c (lynx_target_ops): Set field
3245 supports_hardware_single_step to target_can_do_hardware_single_step.
3246 * nto-low.c (nto_target_ops): Likewise.
3247 * spu-low.c (spu_target_ops): Likewise.
3248 * win32-low.c (win32_target_ops): Likewise.
3249 * target.c (target_can_do_hardware_single_step): New function.
3250 * target.h (struct target_ops) <supports_conditional_breakpoints>:
3251 Remove. <supports_hardware_single_step>: New field.
3252 (target_supports_conditional_breakpoints): Remove.
3253 (target_supports_hardware_single_step): New macro.
3254 (target_can_do_hardware_single_step): Declare.
3255 * server.c (handle_query): Use target_supports_hardware_single_step
3256 instead of target_supports_conditional_breakpoints.
3257
ade90bde
YQ
32582015-09-15 Yao Qi <yao.qi@linaro.org>
3259
3260 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): New
3261 function.
3262 (struct linux_target_ops the_low_target): Install
3263 aarch64_linux_siginfo_fixup.
3264
94585166
DB
32652015-09-11 Don Breazeal <donb@codesourcery.com>
3266 Luis Machado <lgustavo@codesourcery.com>
3267
3268 * linux-low.c (linux_mourn): Static declaration.
3269 (linux_arch_setup): Move in front of
3270 handle_extended_wait.
3271 (linux_arch_setup_thread): New function.
3272 (handle_extended_wait): Handle exec events. Call
3273 linux_arch_setup_thread. Make event_lwp argument a
3274 pointer-to-a-pointer.
3275 (check_zombie_leaders): Do not check stopped threads.
3276 (linux_low_ptrace_options): Add PTRACE_O_TRACEEXEC.
3277 (linux_low_filter_event): Add lwp and thread for exec'ing
3278 non-leader thread if leader thread has been deleted.
3279 Refactor code into linux_arch_setup_thread and call it.
3280 Pass child lwp pointer by reference to handle_extended_wait.
3281 (linux_wait_for_event_filtered): Update comment.
3282 (linux_wait_1): Prevent clobbering exec event status.
3283 (linux_supports_exec_events): New function.
3284 (linux_target_ops) <supports_exec_events>: Initialize new member.
3285 * lynx-low.c (lynx_target_ops) <supports_exec_events>: Initialize
3286 new member.
3287 * remote-utils.c (prepare_resume_reply): New stop reason 'exec'.
3288 * server.c (report_exec_events): New global variable.
3289 (handle_query): Handle qSupported query for exec-events feature.
3290 (captured_main): Initialize report_exec_events.
3291 * server.h (report_exec_events): Declare new global variable.
3292 * target.h (struct target_ops) <supports_exec_events>: New
3293 member.
3294 (target_supports_exec_events): New macro.
3295 * win32-low.c (win32_target_ops) <supports_exec_events>:
3296 Initialize new member.
3297
0568462b
MM
32982015-09-09 Markus Metzger <markus.t.metzger@intel.com>
3299
3300 * linux-low.c (linux_low_enable_btrace): Remove.
3301 (linux_target_ops): Replace linux_low_enable_btrace with
3302 linux_enable_btrace.
3303
39edd165
YQ
33042015-09-03 Yao Qi <yao.qi@linaro.org>
3305
3306 * linux-aarch64-low.c (aarch64_insert_point): Call
3307 aarch64_handle_watchpoint if aarch64_linux_region_ok_for_watchpoint
3308 returns true.
3309
1db33b5a
UW
33102015-08-27 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
3311
3312 * linux-low.c (check_stopped_by_breakpoint): Use
3313 GDB_ARCH_IS_TRAP_BRKPT instead of GDB_ARCH_TRAP_BRKPT.
3314
ab290430
PA
33152015-08-27 Pedro Alves <palves@redhat.com>
3316
3317 * proc-service.c (ps_pdwrite): Return PS_ERR/PS_OK explicily.
3318
8d749320
SM
33192015-08-26 Simon Marchi <simon.marchi@ericsson.com>
3320
6711b7f8
SM
3321 * ax.c (gdb_parse_agent_expr): Replace xmalloc-family function with
3322 the XNEW-family equivalent.
8d749320
SM
3323 (compile_bytecodes): Likewise.
3324 * dll.c (loaded_dll): Likewise.
3325 * event-loop.c (append_callback_event): Likewise.
3326 (create_file_handler): Likewise.
3327 (create_file_event): Likewise.
3328 * hostio.c (handle_open): Likewise.
3329 * inferiors.c (add_thread): Likewise.
3330 (add_process): Likewise.
3331 * linux-aarch64-low.c (aarch64_linux_new_process): Likewise.
3332 * linux-arm-low.c (arm_new_process): Likewise.
3333 (arm_new_thread): Likewise.
3334 * linux-low.c (add_to_pid_list): Likewise.
3335 (linux_add_process): Likewise.
3336 (handle_extended_wait): Likewise.
3337 (add_lwp): Likewise.
3338 (enqueue_one_deferred_signal): Likewise.
3339 (enqueue_pending_signal): Likewise.
3340 (linux_resume_one_lwp_throw): Likewise.
3341 (linux_resume_one_thread): Likewise.
3342 (linux_read_memory): Likewise.
3343 (linux_write_memory): Likewise.
3344 * linux-mips-low.c (mips_linux_new_process): Likewise.
3345 (mips_linux_new_thread): Likewise.
3346 (mips_add_watchpoint): Likewise.
3347 * linux-x86-low.c (initialize_low_arch): Likewise.
3348 * lynx-low.c (lynx_add_process): Likewise.
3349 * mem-break.c (set_raw_breakpoint_at): Likewise.
3350 (set_breakpoint): Likewise.
3351 (add_condition_to_breakpoint): Likewise.
3352 (add_commands_to_breakpoint): Likewise.
3353 (clone_agent_expr): Likewise.
3354 (clone_one_breakpoint): Likewise.
3355 * regcache.c (new_register_cache): Likewise.
3356 * remote-utils.c (look_up_one_symbol): Likewise.
3357 * server.c (queue_stop_reply): Likewise.
3358 (start_inferior): Likewise.
3359 (queue_stop_reply_callback): Likewise.
3360 (handle_target_event): Likewise.
3361 * spu-low.c (fetch_ppc_memory): Likewise.
3362 (store_ppc_memory): Likewise.
3363 * target.c (set_target_ops): Likewise.
3364 * thread-db.c (thread_db_load_search): Likewise.
3365 (try_thread_db_load_1): Likewise.
3366 * tracepoint.c (add_tracepoint): Likewise.
3367 (add_tracepoint_action): Likewise.
3368 (create_trace_state_variable): Likewise.
3369 (cmd_qtdpsrc): Likewise.
3370 (cmd_qtro): Likewise.
3371 (add_while_stepping_state): Likewise.
3372 * win32-low.c (child_add_thread): Likewise.
3373 (get_image_name): Likewise.
3374
ed8b7b42
YQ
33752015-08-25 Yao Qi <yao.qi@linaro.org>
3376
3377 * linux-aarch64-low.c (aarch64_linux_new_thread): Remove.
3378
db3cb7cb
YQ
33792015-08-25 Yao Qi <yao.qi@linaro.org>
3380
3381 * Makefile.in (aarch64-linux.o): New rule.
3382 * configure.srv (aarch64*-*-linux*): Append aarch64-linux.o to
3383 srv_tgtobj.
3384 * linux-aarch64-low.c: Include nat/aarch64-linux.h.
3385 (aarch64_init_debug_reg_state): Make it extern.
3386 (aarch64_linux_prepare_to_resume): Remove.
3387
f6011a1c
YQ
33882015-08-25 Yao Qi <yao.qi@linaro.org>
3389
3390 * linux-aarch64-low.c (aarch64_linux_prepare_to_resume): Use
3391 lwp_arch_private_info and ptid_of_lwp.
3392
88e2cf7e
YQ
33932015-08-25 Yao Qi <yao.qi@linaro.org>
3394
3395 * linux-aarch64-low.c (aarch64_get_debug_reg_state): Add argument pid.
3396 Find proc_info by find_process_pid. All callers updated.
3397
5e35436e
YQ
33982015-08-25 Yao Qi <yao.qi@linaro.org>
3399
3400 * linux-aarch64-low.c (struct arch64_dr_update_callback_param):
3401 Remove.
3402 (debug_reg_change_callback): Remove.
3403 (aarch64_notify_debug_reg_change): Remove.
3404
4a8a7965
YQ
34052015-08-25 Yao Qi <yao.qi@linaro.org>
3406
3407 * linux-aarch64-low.c (aarch64_notify_debug_reg_change):
3408 Call current_lwp_ptid.
3409
32a271ee
YQ
34102015-08-25 Yao Qi <yao.qi@linaro.org>
3411
3412 * linux-aarch64-low.c (debug_reg_change_callback): Use
3413 debug_printf.
3414
0d51c8d7
YQ
34152015-08-25 Yao Qi <yao.qi@linaro.org>
3416
3417 * linux-aarch64-low.c (debug_reg_change_callback): Use phex.
3418
31a43dd5
YQ
34192015-08-25 Yao Qi <yao.qi@linaro.org>
3420
3421 * linux-aarch64-low.c (debug_reg_change_callback): Remove comments.
3422
8ee52567
YQ
34232015-08-25 Yao Qi <yao.qi@linaro.org>
3424
3425 * linux-aarch64-low.c (debug_reg_change_callback): Re-indent
3426 the code.
3427
ff3f0f45
YQ
34282015-08-25 Yao Qi <yao.qi@linaro.org>
3429
3430 * linux-aarch64-low.c (aarch64_dr_update_callback_param) <pid>:
3431 Remove.
3432 (debug_reg_change_callback): Remove argument entry and add argument
3433 lwp. Remove local variable thread. Don't print thread id in the
3434 debugging output. Don't check whether pid of thread equals to pid.
3435 (aarch64_notify_debug_reg_change): Don't set param.pid. Call
3436 iterate_over_lwps instead find_inferior.
3437
3d40fbb5
PA
34382015-08-24 Pedro Alves <palves@redhat.com>
3439
3440 * inferiors.c (get_first_process): New function.
3441 * inferiors.h (get_first_process): New declaration.
3442 * remote-utils.c (read_ptid): Default to the first process in the
3443 list, instead of to the current thread's process.
3444
438e1e42
PA
34452015-08-24 Pedro Alves <palves@redhat.com>
3446
3447 * debug.c: Include gdb_sys_time.h instead of sys/time.h.
3448 * event-loop.c: Likewise.
3449 * remote-utils.c: Likewise.
3450 * tracepoint.c: Likewise.
3451
a8c6d4fc
PA
34522015-08-24 Pedro Alves <palves@redhat.com>
3453
3454 * spu-low.c (spu_request_interrupt): Use lwpid_of instead of
3455 ptid_get_lwp.
3456
99b0bb12
PA
34572015-08-21 Pedro Alves <palves@redhat.com>
3458
3459 * ax.c (gdb_eval_agent_expr): Return expr_eval_unhandled_opcode
3460 instead of literal 1.
3461
f8904751
PA
34622015-08-21 Pedro Alves <palves@redhat.com>
3463
3464 * tdesc.c (default_description): Explicitly zero-initialize.
3465
465a859e
PA
34662015-08-21 Pedro Alves <palves@redhat.com>
3467
3468 PR gdb/18749
3469 * inferiors.c (remove_thread): Discard any pending stop reply for
3470 this thread.
3471 * server.c (remove_all_on_match_pid): Rename to ...
3472 (remove_all_on_match_ptid): ... this. Work with a filter ptid
3473 instead of a pid.
3474 (discard_queued_stop_replies): Change parameter to a ptid. Now
3475 extern.
3476 (handle_v_kill, kill_inferior_callback, captured_main)
3477 (process_serial_event): Adjust.
3478 * server.h (discard_queued_stop_replies): Declare.
3479
f0db101d
PA
34802015-08-21 Pedro Alves <palves@redhat.com>
3481
3482 * linux-low.c (wait_for_sigstop): Always switch to no thread
3483 selected if the previously current thread dies.
3484 * lynx-low.c (lynx_request_interrupt): Use the first thread's
3485 process instead of the current thread's.
3486 * remote-utils.c (input_interrupt): Don't check if there's no
3487 current thread.
3488 * server.c (gdb_read_memory, gdb_write_memory): If setting the
3489 current thread to the general thread fails, error out.
3490 (handle_qxfer_auxv, handle_qxfer_libraries)
3491 (handle_qxfer_libraries_svr4, handle_qxfer_siginfo)
3492 (handle_qxfer_spu, handle_qxfer_statictrace, handle_qxfer_fdpic)
3493 (handle_query): Check if there's a thread selected instead of
3494 checking whether there's any thread in the thread list.
3495 (handle_qxfer_threads, handle_qxfer_btrace)
3496 (handle_qxfer_btrace_conf): Don't error out early if there's no
3497 thread in the thread list.
3498 (handle_v_cont, myresume): Don't set the current thread to the
3499 continue thread.
3500 (process_serial_event) <Hg handling>: Also set thread_id if the
3501 previous general thread is still alive.
3502 (process_serial_event) <g/G handling>: If setting the current
3503 thread to the general thread fails, error out.
3504 * spu-low.c (spu_resume, spu_request_interrupt): Use the first
3505 thread's lwp instead of the current thread's.
3506 * target.c (set_desired_thread): If the desired thread was not
3507 found, leave the current thread pointing to NULL. Return an int
3508 (boolean) indicating success.
3509 * target.h (set_desired_thread): Change return type to int.
3510
40045d91
MF
35112015-08-20 Max Filippov <jcmvbkbc@gmail.com>
3512
3513 * configure.srv (xtensa*-*-linux*): Add srv_linux_thread_db=yes.
3514 * linux-xtensa-low.c (arch/xtensa.h gdb_proc_service.h): New
3515 #includes.
3516 (ps_get_thread_area): New function.
3517
45face3b
GB
35182015-08-19 Gary Benson <gbenson@redhat.com>
3519
3520 * hostio.c (handle_pread): Do not attempt to read more data
3521 than hostio_reply_with_data can fit in a packet.
3522
16d5f642
JB
35232015-08-18 Joel Brobecker <brobecker@adacore.com>
3524
3525 * linux-aarch32-low.c (NT_ARM_VFP): Define if not already defined.
3526
a738da3a
MF
35272015-08-14 Matthew Fortune <matthew.fortune@imgtec.com>
3528
3529 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP_REL.
3530
33ebda9d
PA
35312015-08-06 Pedro Alves <palves@redhat.com>
3532
3533 * tracepoint.c (expr_eval_result): Now an int.
3534
a44892be
PA
35352015-08-06 Pedro Alves <palves@redhat.com>
3536
3537 * gdbthread.h (struct regcache): Forward declare.
3538 (struct thread_info) <regcache_data>: Now a struct regcache
3539 pointer.
3540 * inferiors.c (inferior_regcache_data)
3541 (set_inferior_regcache_data): Now work with struct regcache
3542 pointers.
3543 * inferiors.h (struct regcache): Forward declare.
3544 (inferior_regcache_data, set_inferior_regcache_data): Now work
3545 with struct regcache pointers.
3546 * regcache.c (get_thread_regcache, regcache_invalidate_thread)
3547 (free_register_cache_thread): Remove struct regcache pointer
3548 casts.
3549
608a1e46
PA
35502015-08-06 Pedro Alves <palves@redhat.com>
3551
3552 * server.c (captured_main): On error, print the exception message
3553 to stderr, and if run_once is set, throw a quit.
3554
f0ce0d3a
PA
35552015-08-06 Pedro Alves <palves@redhat.com>
3556
3557 * linux-low.c (move_out_of_jump_pad_callback): Temporarily switch
3558 the current thread.
3559
bf47e248
PA
35602015-08-06 Pedro Alves <palves@redhat.com>
3561
3562 * linux-low.c (linux_write_memory): Rewrite debug output to avoid
3563 reading beyond the passed in buffer length.
3564
b6b9ffcc
PL
35652015-08-06 Pierre Langlois <pierre.langlois@arm.com>
3566
3567 * tracepoint.c (symbol_list) <required>: Remove.
3568
863d01bd
PA
35692015-08-06 Pedro Alves <palves@redhat.com>
3570
3571 * linux-low.c (handle_extended_wait): Set the fork child's suspend
3572 count if stopping and suspending threads.
3573 (check_stopped_by_breakpoint): If stopped by trace, set the LWP's
3574 stop reason to TARGET_STOPPED_BY_SINGLE_STEP.
3575 (linux_detach): Complete an ongoing step-over.
3576 (lwp_suspended_inc, lwp_suspended_decr): New functions. Use
3577 throughout.
3578 (resume_stopped_resumed_lwps): Don't resume a suspended thread.
3579 (linux_wait_1): If passing a signal to the inferior after
3580 finishing a step-over, unsuspend and re-resume all lwps. If we
3581 see a single-step event but the thread should be continuing, don't
3582 pass the trap to gdb.
3583 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback): Use
3584 internal_error instead of gdb_assert.
3585 (enqueue_pending_signal): New function.
3586 (check_ptrace_stopped_lwp_gone): Add debug output.
3587 (start_step_over): Use internal_error instead of gdb_assert.
3588 (complete_ongoing_step_over): New function.
3589 (linux_resume_one_thread): Don't resume a suspended thread.
3590 (proceed_one_lwp): If the LWP is stepping over a breakpoint, reset
3591 it stepping.
3592
00db26fa
PA
35932015-08-06 Pedro Alves <palves@redhat.com>
3594
3595 * linux-low.c (add_lwp): Set waitstatus to TARGET_WAITKIND_IGNORE.
3596 (linux_thread_alive): Use lwp_is_marked_dead.
3597 (extended_event_reported): Delete.
3598 (linux_wait_1): Check if waitstatus is TARGET_WAITKIND_IGNORE
3599 instead of extended_event_reported.
3600 (mark_lwp_dead): Don't set the 'dead' flag. Store the waitstatus
3601 as well.
3602 (lwp_is_marked_dead): New function.
3603 (lwp_running): Use lwp_is_marked_dead.
3604 * linux-low.h: Delete 'dead' field, and update 'waitstatus's
3605 comment.
3606
ad071a30
PA
36072015-08-06 Pedro Alves <palves@redhat.com>
3608
3609 * linux-low.c (linux_wait_1): Move fork event output out of the
3610 !report_to_gdb check. Pass event_child->waitstatus to
3611 target_waitstatus_to_string instead of ourstatus.
3612
524b57e6
YQ
36132015-08-04 Yao Qi <yao.qi@linaro.org>
3614
3615 * linux-aarch64-low.c (aarch64_supports_tracepoints): Return 0
3616 if current_thread is 32 bit.
3617
6085d6f6
YQ
36182015-08-04 Yao Qi <yao.qi@linaro.org>
3619
3620 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
3621 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
3622 * server.c (extended_protocol): Remove "static".
3623 * server.h (extended_protocol): Declare it.
3624
8a7e4587
YQ
36252015-08-04 Yao Qi <yao.qi@linaro.org>
3626
3627 * linux-aarch64-low.c (aarch64_get_pc): Get PC register on
3628 both aarch64 and aarch32.
3629 (aarch64_set_pc): Likewise.
3630
3b53ae99
YQ
36312015-08-04 Yao Qi <yao.qi@linaro.org>
3632
3633 * configure.srv (case aarch64*-*-linux*): Append arm-with-neon.o
3634 to srv_regobj and append arm-core.xml arm-vfpv3.xml and
3635 arm-with-neon.xml to srv_xmlfiles.
3636 * linux-aarch64-low.c: Include linux-aarch32-low.h.
3637 (is_64bit_tdesc): New function.
3638 (aarch64_linux_read_description): New function.
3639 (aarch64_arch_setup): Call aarch64_linux_read_description.
3640 (regs_info): Rename to regs_info_aarch64.
3641 (aarch64_regs_info): Return right regs_info.
3642 (initialize_low_arch): Call initialize_low_arch_aarch32.
3643
bd9e6534
YQ
36442015-08-04 Yao Qi <yao.qi@linaro.org>
3645
3646 * configure.srv (srv_tgtobj): Add linux-aarch32-low.o.
3647 * linux-aarch32-low.c: New file.
3648 * linux-aarch32-low.h: New file.
3649 * linux-arm-low.c (arm_fill_gregset): Move it to
3650 linux-aarch32-low.c.
3651 (arm_store_gregset): Likewise.
3652 (arm_fill_vfpregset): Call arm_fill_vfpregset_num
3653 (arm_store_vfpregset): Call arm_store_vfpregset_num.
3654 (arm_arch_setup): Check if PTRACE_GETREGSET works.
3655 (regs_info): Rename to regs_info_arm.
3656 (arm_regs_info): Return regs_info_aarch32 if
3657 have_ptrace_getregset is 1 and target description is
3658 arm_with_neon or arm_with_vfpv3.
3659 (initialize_low_arch): Don't call init_registers_arm_with_neon.
3660 Call initialize_low_arch_aarch32 instead.
3661
ded48a5e
YQ
36622015-08-04 Yao Qi <yao.qi@linaro.org>
3663
3664 * linux-x86-low.c (have_ptrace_getregset): Move it to ...
3665 * linux-low.c: ... here.
3666 * linux-low.h (have_ptrace_getregset): Declare it.
3667
96e9210f
PA
36682015-08-04 Pedro Alves <palves@redhat.com>
3669
3670 * thread-db.c (struct thread_db): Use new typedefs.
3671 (try_thread_db_load_1): Define local TDB_DLSYM macro and use it in
3672 CHK calls.
3673 (disable_thread_event_reporting): Cast result of dlsym to
3674 destination function pointer type.
3675 (thread_db_mourn): Use td_ta_delete_ftype.
3676
af60a1ef
SL
36772015-08-03 Sandra Loosemore <sandra@codesourcery.com>
3678
3679 * linux-nios2-low.c (NIOS2_BREAKPOINT): Conditionalize for
3680 arch variant.
3681 (CDX_BREAKPOINT): Define for R2.
3682 (nios2_breakpoint_at): Check for CDX_BREAKPOINT when R2.
3683 (the_low_target): Add comments.
3684
e8b41681
YQ
36852015-07-30 Yao Qi <yao.qi@linaro.org>
3686
3687 * linux-arm-low.c (arm_hwcap): Remove it.
3688 (arm_read_description): New local variable arm_hwcap. Don't
3689 set arm_hwcap to zero.
3690
89abb039
YQ
36912015-07-30 Yao Qi <yao.qi@linaro.org>
3692
3693 * linux-arm-low.c (arm_fill_wmmxregset): Don't use arm_hwcap.
3694 Use regcache->tdesc instead.
3695 (arm_store_wmmxregset): Likewise.
3696 (arm_fill_vfpregset): Likewise.
3697 (arm_store_vfpregset): Likewise.
3698
deca266c
YQ
36992015-07-30 Yao Qi <yao.qi@linaro.org>
3700
3701 * linux-arm-low.c: Include arch/arm.h.
3702 (arm_fill_gregset): Don't use arm_num_regs and arm_regmap.
3703 (arm_store_gregset): Likewise.
3704
aa58a496
SM
37052015-07-29 Simon Marchi <simon.marchi@ericsson.com>
3706
3707 * linux-mips-low.c (mips_linux_prepare_to_resume): Add NULL as
3708 ptrace's 4th parameter.
3709
50904b25
YQ
37102015-07-27 Yao Qi <yao.qi@linaro.org>
3711
3712 * configure.srv (case aarch64*-*-linux*): Don't set
3713 srv_linux_usrregs.
3714
5826e159
PA
37152015-07-24 Pedro Alves <palves@redhat.c: Likewise.om>
3716
3717 * linux-aarch64-low.c: Include nat/gdb_ptrace.h instead of
3718 sys/ptrace.h.
3719 * linux-arm-low.c: Likewise.
3720 * linux-cris-low.c: Likewise.
3721 * linux-crisv32-low.c: Likewise.
3722 * linux-low.c: Likewise.
3723 * linux-m68k-low.c: Likewise.
3724 * linux-mips-low.c: Likewise.
3725 * linux-nios2-low.c: Likewise.
3726 * linux-s390-low.c: Likewise.
3727 * linux-sparc-low.c: Likewise.
3728 * linux-tic6x-low.c: Likewise.
3729 * linux-tile-low.c: Likewise.
3730 * linux-x86-low.c: Likewise.
3731
54019719
PA
37322015-07-24 Pedro Alves <palves@redhat.com>
3733
3734 * config.in: Regenerate.
3735 * configure: Regenerate.
3736
eb7aa561
PA
37372015-07-24 Pedro Alves <palves@redhat.com>
3738
3739 * acinclude.m4: Include ../ptrace.m4.
3740 * configure.ac: Call GDB_AC_PTRACE.
3741 * config.in, configure: Regenerate.
3742
55d7b841
YQ
37432015-07-24 Yao Qi <yao.qi@linaro.org>
3744
3745 * linux-low.c (linux_create_inferior): Remove setting to
3746 proc->priv->new_inferior.
3747 (linux_attach): Likewise.
3748 (linux_low_filter_event): Likewise.
3749 * linux-low.h (struct process_info_private) <new_inferior>: Remove.
3750
c06cbd92
YQ
37512015-07-24 Yao Qi <yao.qi@linaro.org>
3752
3753 * linux-low.c (linux_arch_setup): New function.
3754 (linux_low_filter_event): If proc->tdesc is NULL and
3755 proc->attached is true, call the_low_target.arch_setup.
3756 Otherwise, keep status pending, and return.
3757 (linux_resume_one_lwp_throw): Don't call get_pc if
3758 thread->while_stepping isn't NULL. Don't call
3759 get_thread_regcache if proc->tdesc is NULL.
3760 (need_step_over_p): Return 0 if proc->tdesc is NULL.
3761 (linux_target_ops): Install arch_setup.
3762 * server.c (start_inferior): Call the_target->arch_setup.
3763 * target.h (struct target_ops) <arch_setup>: New field.
3764 (target_arch_setup): New marco.
3765 * lynx-low.c (lynx_target_ops): Update.
3766 * nto-low.c (nto_target_ops): Update.
3767 * spu-low.c (spu_target_ops): Update.
3768 * win32-low.c (win32_target_ops): Update.
3769
5ae3ebba
YQ
37702015-07-24 Yao Qi <yao.qi@linaro.org>
3771
3772 * linux-low.c (linux_add_process): Don't set
3773 proc->priv->new_inferior.
3774 (linux_create_inferior): Set proc->priv->new_inferior to 1.
3775 (linux_attach): Likewise.
3776
eb97750b
YQ
37772015-07-24 Yao Qi <yao.qi@linaro.org>
3778
3779 * server.c (start_inferior): Code refactor.
3780
51aee833
YQ
37812015-07-24 Yao Qi <yao.qi@linaro.org>
3782
3783 * server.c (process_serial_event): Set general_thread.
3784
af1b22f3
YQ
37852015-07-21 Yao Qi <yao.qi@linaro.org>
3786
3787 * linux-aarch64-low.c (aarch64_arch_setup): Remove code and call
3788 aarch64_linux_get_debug_reg_capacity.
3789
554717a3
YQ
37902015-07-17 Yao Qi <yao.qi@linaro.org>
3791
3792 * Makefile.in (aarch64-linux-hw-point.o): New rule.
3793 * configure.srv (srv_tgtobj): Append aarch64-linux-hw-point.o.
3794 * linux-aarch64-low.c: Include nat/aarch64-linux-hw-point.h.
3795 (AARCH64_HBP_MAX_NUM): Move to nat/aarch64-linux-hw-point.h.
3796 (AARCH64_HWP_MAX_NUM, AARCH64_HBP_ALIGNMENT): Likewise.
3797 (AARCH64_HWP_ALIGNMENT): Likewise.
3798 (AARCH64_HWP_MAX_LEN_PER_REG): Likewise.
3799 (AARCH64_DEBUG_NUM_SLOTS, AARCH64_DEBUG_ARCH): Likewise.
3800 (aarch64_num_bp_regs, aarch64_num_wp_regs): Likewise.
3801 (AARCH64_DEBUG_ARCH_V8, DR_MARK_ALL_CHANGED): Likewise.
3802 (DR_MARK_N_CHANGED, DR_CLEAR_CHANGED): Likewise.
3803 (DR_HAS_CHANGED, DR_N_HAS_CHANGE): Likewise.
3804 (struct aarch64_debug_reg_state): Likewise.
3805 (struct arch_lwp_info): Likewise.
3806 (aarch64_align_watchpoint): Likewise.
3807 (DR_CONTROL_ENABLED, DR_CONTROL_LENGTH): Likewise.
3808 (aarch64_watchpoint_length): Likewise.
3809 (aarch64_point_encode_ctrl_reg): Likewise
3810 (aarch64_point_is_aligned): Likewise.
3811 (aarch64_align_watchpoint): Likewise.
3812 (aarch64_linux_set_debug_regs):
3813 (aarch64_dr_state_insert_one_point): Likewise.
3814 (aarch64_dr_state_remove_one_point): Likewise.
3815 (aarch64_handle_breakpoint): Likewise.
3816 (aarch64_handle_aligned_watchpoint): Likewise.
3817 (aarch64_handle_unaligned_watchpoint): Likewise.
3818 (aarch64_handle_watchpoint): Likewise.
3819
c67ca4de
YQ
38202015-07-17 Yao Qi <yao.qi@linaro.org>
3821
3822 * linux-aarch64-low.c (aarch64_handle_breakpoint): Add argument state
3823 and don't aarch64_get_debug_reg_state. All callers update.
3824 (aarch64_handle_aligned_watchpoint): Likewise.
3825 (aarch64_handle_unaligned_watchpoint): Likewise.
3826 (aarch64_handle_watchpoint): Likewise.
3827 (aarch64_insert_point): Call aarch64_get_debug_reg_state earlier.
3828 (aarch64_remove_point): Likewise.
3829
25abf979
YQ
38302015-07-17 Yao Qi <yao.qi@linaro.org>
3831
3832 * linux-aarch64-low.c (aarch64_show_debug_reg_state): Use
3833 debug_printf.
3834 (aarch64_handle_unaligned_watchpoint): Likewise.
3835
db1ff28b
JK
38362015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
3837
3838 Revert the previous 3 commits:
3839 Move gdb_regex* to common/
3840 Move linux_find_memory_regions_full & co.
3841 gdbserver build-id attribute generator
3842
700ca40f
JK
38432015-07-15 Aleksandar Ristovski <aristovski@qnx.com
3844 Jan Kratochvil <jan.kratochvil@redhat.com>
3845
3846 gdbserver build-id attribute generator.
3847 * linux-low.c (nat/linux-maps.h, search.h, rsp-low.h): Include.
3848 (ElfXX_Ehdr, ElfXX_Phdr, ElfXX_Nhdr): New.
3849 (ELFXX_FLD, ELFXX_SIZEOF, ELFXX_ROUNDUP, BUILD_ID_INVALID): New.
3850 (find_phdr): New.
3851 (get_dynamic): Use find_pdhr to traverse program headers.
3852 (struct mapping_entry, mapping_entry_s, free_mapping_entry_vec)
3853 (compare_mapping_entry_range, struct find_memory_region_callback_data)
3854 (read_build_id, find_memory_region_callback, lrfind_mapping_entry)
3855 (get_hex_build_id): New.
3856 (linux_qxfer_libraries_svr4): Add optional build-id attribute
3857 to reply XML document.
3858
9904185c
JK
38592015-07-15 Aleksandar Ristovski <aristovski@qnx.com
3860 Jan Kratochvil <jan.kratochvil@redhat.com>
3861
3862 * target.c: Include target/target-utils.h and fcntl.h.
3863 (target_fileio_read_stralloc_1_pread, target_fileio_read_stralloc_1)
3864 (target_fileio_read_stralloc): New functions.
3865
6e5b4429
JK
38662015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
3867
3868 * Makefile.in (OBS): Add gdb_regex.o.
3869 (gdb_regex.o): New.
3870 * config.in: Rebuilt.
3871 * configure: Rebuilt.
3872
ddc98fbf
JK
38732015-07-15 Aleksandar Ristovski <aristovski@qnx.com
3874 Jan Kratochvil <jan.kratochvil@redhat.com>
3875
3876 Create empty nat/linux-maps.[ch] and common/target-utils.[ch].
3877 * Makefile.in (OBS): Add target-utils.o.
3878 (linux-maps.o, target-utils.o): New.
3879 * configure.srv (srv_linux_obj): Add linux-maps.o.
3880
e57bb7a0
PL
38812015-07-15 Pierre Langlois <pierre.langlois@arm.com>
3882
3883 * linux-aarch64-low.c (aarch64_supports_range_stepping): New
3884 function, return 1.
3885 (the_low_target): Install it.
3886
586b02a9
PA
38872015-07-14 Pedro Alves <palves@redhat.com>
3888
3889 * linux-low.c (kill_wait_lwp): Don't assert if waitpid fails.
3890 Instead, ignore ECHILD, and throw an error for other errnos.
3891
58c1b36c
PA
38922015-07-10 Pedro Alves <palves@redhat.com>
3893
3894 * event-loop.c (struct callback_event) <data>: Change type to
3895 gdb_client_data instance instead of gdb_client_data pointer.
3896 (append_callback_event): Adjust.
3897
421530db
PL
38982015-07-10 Pierre Langlois <pierre.langlois@arm.com>
3899
3900 * linux-aarch64-low.c: Add comments for each linux_target_ops
3901 method. Remove comments already covered in target_ops and
3902 linux_target_ops definitions.
3903 (the_low_target): Add comments for each unimplemented method.
3904
c2d65f38
YQ
39052015-07-09 Yao Qi <yao.qi@linaro.org>
3906
3907 * linux-aarch64-low.c (aarch64_regmap): Remove.
3908 (aarch64_usrregs_info): Remove.
3909 (regs_info): Set field usrregs to NULL.
3910
b20a6524
MM
39112015-07-02 Markus Metzger <markus.t.metzger@intel.com>
3912
3913 * linux-low.c: Include "rsp-low.h"
3914 (linux_low_encode_pt_config, linux_low_encode_raw): New.
3915 (linux_low_read_btrace): Support BTRACE_FORMAT_PT.
3916 (linux_low_btrace_conf): Support BTRACE_FORMAT_PT.
3917 (handle_btrace_enable_pt): New.
3918 (handle_btrace_general_set): Support "pt".
3919 (handle_btrace_conf_general_set): Support "pt:size".
3920
96c97461
PL
39212015-06-29 Pierre Langlois <pierre.langlois@arm.com>
3922
3923 * linux-aarch64-low.c (aarch64_supports_z_point_type): Enable for
3924 Z_PACKET_SW_BP.
3925
37d66942
PL
39262015-06-29 Pierre Langlois <pierre.langlois@arm.com>
3927
3928 * linux-aarch64-low.c: Remove comment about endianness.
3929 (aarch64_breakpoint): Change type to gdb_byte[]. Set to "brk #0".
3930 (aarch64_breakpoint_at): Change type of insn to gdb_byte[]. Use
3931 memcmp.
3932
dc06243f
GB
39332015-06-24 Gary Benson <gbenson@redhat.com>
3934
3935 * linux-i386-ipa.c (stdint.h): Do not include.
3936 * lynx-i386-low.c (stdint.h): Likewise.
3937 * lynx-ppc-low.c (stdint.h): Likewise.
3938 * mem-break.c (stdint.h): Likewise.
3939 * thread-db.c (stdint.h): Likewise.
3940 * tracepoint.c (stdint.h): Likewise.
3941 * win32-low.c (stdint.h): Likewise.
3942
124e13d9
SM
39432015-06-18 Simon Marchi <simon.marchi@ericsson.com>
3944
3945 * server.c (write_qxfer_response): Update call to
3946 remote_escape_output.
3947
909c2cda
JK
39482015-06-15 Aleksandar Ristovski <aristovski@qnx.com
3949 Jan Kratochvil <jan.kratochvil@redhat.com>
3950
3951 Merge multiple hex conversions.
3952 * gdbreplay.c (tohex): Rename to 'fromhex'.
3953 (logchar): Use fromhex.
3954
24c05f46
JK
39552015-06-10 Jan Kratochvil <jan.kratochvil@redhat.com>
3956
3957 * server.c (handle_qxfer_libraries): Set `version' attribute for
3958 <library-list>.
3959
14d2069a
GB
39602015-06-10 Gary Benson <gbenson@redhat.com>
3961
3962 * target.h (struct target_ops) <multifs_open>: New field.
3963 <multifs_unlink>: Likewise.
3964 <multifs_readlink>: Likewise.
3965 * linux-low.c (nat/linux-namespaces.h): New include.
3966 (linux_target_ops): Initialize the_target->multifs_open,
3967 the_target->multifs_unlink and the_target->multifs_readlink.
3968 * hostio.h (hostio_handle_new_gdb_connection): New declaration.
3969 * hostio.c (hostio_fs_pid): New static variable.
3970 (hostio_handle_new_gdb_connection): New function.
3971 (handle_setfs): Likewise.
3972 (handle_open): Use the_target->multifs_open as appropriate.
3973 (handle_unlink): Use the_target->multifs_unlink as appropriate.
3974 (handle_readlink): Use the_target->multifs_readlink as
3975 appropriate.
3976 (handle_vFile): Handle vFile:setfs packets.
3977 * server.c (handle_query): Call hostio_handle_new_gdb_connection
3978 after target_handle_new_gdb_connection.
3979
4b8b5e72
GB
39802015-06-10 Gary Benson <gbenson@redhat.com>
3981
3982 * configure.ac (AC_CHECK_FUNCS): Add setns.
3983 * config.in: Regenerate.
3984 * configure: Likewise.
3985 * Makefile.in (SFILES): Add nat/linux-namespaces.c.
3986 (linux-namespaces.o): New rule.
3987 * configure.srv (srv_linux_obj): Add linux-namespaces.o.
3988
3ac2e371
GB
39892015-06-09 Gary Benson <gbenson@redhat.com>
3990
3991 * hostio.c (handle_open): Process mode argument with
3992 fileio_to_host_mode.
3993
ca9b78ce
YQ
39942015-06-01 Yao Qi <yao.qi@linaro.org>
3995
3996 * linux-s390-low.c (PTRACE_GETREGSET, PTRACE_SETREGSET): Remove.
3997 * linux-x86-low.c: Likewise.
3998
bfacd19d
DB
39992015-05-28 Don Breazeal <donb@codesourcery.com>
4000
4001 * linux-low.c (handle_extended_wait): Initialize
4002 thread_info.last_resume_kind for new fork children.
4003
452003ef
PA
40042015-05-15 Pedro Alves <palves@redhat.com>
4005
4006 * target.h (target_handle_new_gdb_connection): Rewrite using if
4007 wrapped in do/while.
4008
1041a03c
JB
40092015-05-14 Joel Brobecker <brobecker@adacore.com>
4010
4011 * configure.ac: Add prfpregset_t BFD_HAVE_SYS_PROCFS_TYPE check.
4012 * configure, config.in: Regenerate.
4013 * gdb_proc_service.h [HAVE_PRFPREGSET_T] (prfpregset_t):
4014 Declare typedef.
4015
c269dbdb
DB
40162015-05-12 Don Breazeal <donb@codesourcery.com>
4017
4018 * linux-low.c (handle_extended_wait): Handle PTRACE_EVENT_FORK and
4019 PTRACE_EVENT_VFORK_DONE.
4020 (linux_low_ptrace_options, extended_event_reported): Add vfork
4021 events.
4022 * remote-utils.c (prepare_resume_reply): New stop reasons "vfork"
4023 and "vforkdone" for RSP 'T' Stop Reply Packet.
4024 * server.h (report_vfork_events): Declare
4025 global variable.
4026
3a8a0396
DB
40272015-05-12 Don Breazeal <donb@codesourcery.com>
4028
4029 * linux-aarch64-low.c (aarch64_linux_new_fork): New function.
4030 (the_low_target) <new_fork>: Initialize new member.
4031 * linux-arm-low.c (arm_new_fork): New function.
4032 (the_low_target) <new_fork>: Initialize new member.
4033 * linux-low.c (handle_extended_wait): Call new target function
4034 new_fork.
4035 * linux-low.h (struct linux_target_ops) <new_fork>: New member.
4036 * linux-mips-low.c (mips_add_watchpoint): New function
4037 extracted from mips_insert_point.
4038 (the_low_target) <new_fork>: Initialize new member.
4039 (mips_linux_new_fork): New function.
4040 (mips_insert_point): Call mips_add_watchpoint.
4041 * linux-x86-low.c (x86_linux_new_fork): New function.
4042 (the_low_target) <new_fork>: Initialize new member.
4043
de0d863e
DB
40442015-05-12 Don Breazeal <donb@codesourcery.com>
4045
4046 * linux-low.c (handle_extended_wait): Implement return value,
4047 rename argument 'event_child' to 'event_lwp', handle
4048 PTRACE_EVENT_FORK, call internal_error for unrecognized event.
4049 (linux_low_ptrace_options): New function.
4050 (linux_low_filter_event): Call linux_low_ptrace_options,
4051 use different argument fo linux_enable_event_reporting,
4052 use return value from handle_extended_wait.
4053 (extended_event_reported): New function.
4054 (linux_wait_1): Call extended_event_reported and set
4055 status to report fork events.
4056 (linux_write_memory): Add pid to debug message.
4057 (reset_lwp_ptrace_options_callback): New function.
4058 (linux_handle_new_gdb_connection): New function.
4059 (linux_target_ops): Initialize new structure member.
4060 * linux-low.h (struct lwp_info) <waitstatus>: New member.
4061 * lynx-low.c: Initialize new structure member.
4062 * remote-utils.c (prepare_resume_reply): Implement stop reason
4063 "fork" for "T" stop message.
4064 * server.c (handle_query): Call handle_new_gdb_connection.
4065 * server.h (report_fork_events): Declare global flag.
4066 * target.h (struct target_ops) <handle_new_gdb_connection>:
4067 New member.
4068 (target_handle_new_gdb_connection): New macro.
4069 * win32-low.c: Initialize new structure member.
4070
ddcbc397
DB
40712015-05-12 Don Breazeal <donb@codesourcery.com>
4072
4073 * mem-break.c (APPEND_TO_LIST): Define macro.
4074 (clone_agent_expr): New function.
4075 (clone_one_breakpoint): New function.
4076 (clone_all_breakpoints): New function.
4077 * mem-break.h: Declare new functions.
4078
89245bc0
DB
40792015-05-12 Don Breazeal <donb@codesourcery.com>
4080
4081 * linux-low.c (linux_supports_fork_events): New function.
4082 (linux_supports_vfork_events): New function.
4083 (linux_target_ops): Initialize new structure members.
4084 (initialize_low): Call linux_check_ptrace_features.
4085 * lynx-low.c (lynx_target_ops): Initialize new structure
4086 members.
4087 * server.c (report_fork_events, report_vfork_events):
4088 New global flags.
4089 (handle_query): Add new features to qSupported packet and
4090 response.
4091 (captured_main): Initialize new global variables.
4092 * target.h (struct target_ops) <supports_fork_events>:
4093 New member.
4094 <supports_vfork_events>: New member.
4095 (target_supports_fork_events): New macro.
4096 (target_supports_vfork_events): New macro.
4097 * win32-low.c (win32_target_ops): Initialize new structure
4098 members.
4099
835205d0
GB
41002015-05-12 Gary Benson <gbenson@redhat.com>
4101
4102 * server.c (handle_qxfer_exec_file): Use current process
4103 if annex is empty.
4104
21e94bd9
SL
41052015-05-08 Sandra Loosemore <sandra@codesourcery.com>
4106
4107 * linux-nios2-low.c: Include elf/common.h. Adjust comments.
4108 Remove HAVE_PTRACE_GETREGS conditionals.
4109 (nios2_regsets): Use PTRACE_GETREGSET and PTRACE_SETREGSET
4110 instead of PTRACE_GETREGS and PTRACE_SETREGS.
4111
45614f15
YQ
41122015-05-08 Yao Qi <yao.qi@linaro.org>
4113
4114 * linux-low.c (linux_supports_conditional_breakpoints): New
4115 function.
4116 (linux_target_ops): Install new target method.
4117 * lynx-low.c (lynx_target_ops): Install NULL hook for
4118 supports_conditional_breakpoints.
4119 * nto-low.c (nto_target_ops): Likewise.
4120 * spu-low.c (spu_target_ops): Likewise.
4121 * win32-low.c (win32_target_ops): Likewise.
4122 * server.c (handle_query): Check
4123 target_supports_conditional_breakpoints.
4124 * target.h (struct target_ops) <supports_conditional_breakpoints>:
4125 New field.
4126 (target_supports_conditional_breakpoints): New macro.
4127
80ad801e
PA
41282015-05-06 Pedro Alves <palves@redhat.com>
4129
4130 PR server/18081
4131 * server.c (start_inferior): If the process exits, mourn it.
4132
819843c7
GB
41332015-04-21 Gary Benson <gbenson@redhat.com>
4134
4135 * hostio.c (fileio_open_flags_to_host): Factored out to
4136 fileio_to_host_openflags in common/fileio.c. Single use
4137 updated.
4138
a2d5a9d7
MF
41392015-04-17 Max Filippov <jcmvbkbc@gmail.com>
4140
4141 * linux-xtensa-low.c (xtensa_fill_gregset)
4142 (xtensa_store_gregset): Check XCHAL_HAVE_LOOPS instead of
4143 XCHAL_HAVE_LOOP.
4144
deb44829
MF
41452015-04-17 Max Filippov <jcmvbkbc@gmail.com>
4146
4147 * linux-xtensa-low.c (xtensa_usrregs_info): Remove.
4148 (regs_info): Replace usrregs pointer with NULL.
4149
e57f1de3
GB
41502015-04-17 Gary Benson <gbenson@redhat.com>
4151
4152 * target.h (struct target_ops) <pid_to_exec_file>: New field.
4153 * linux-low.c (linux_target_ops): Initialize pid_to_exec_file.
4154 * server.c (handle_qxfer_exec_file): New function.
4155 (qxfer_packets): Add exec-file entry.
4156 (handle_query): Report qXfer:exec-file:read as supported packet.
4157
62828379
RN
41582015-04-14 Romain Naour <romain.naour@openwide.fr> (tiny change)
4159
4160 * linux-low.c (linux_read_offsets): Remove get_thread_lwp.
4161
b88bb450
GB
41622015-04-09 Gary Benson <gbenson@redhat.com>
4163
4164 * hostio-errno.c (errno_to_fileio_error): Remove function.
4165 Update caller to use remote_fileio_to_fio_error.
4166
c8f4bfdd
YQ
41672015-04-09 Yao Qi <yao.qi@linaro.org>
4168
4169 * linux-low.c (linux_insert_point): Call
4170 insert_memory_breakpoint if TYPE is raw_bkpt_type_sw.
4171 (linux_remove_point): Call remove_memory_breakpoint if type is
4172 raw_bkpt_type_sw.
4173 * linux-x86-low.c (x86_insert_point): Don't call
4174 insert_memory_breakpoint.
4175 (x86_remove_point): Don't call remove_memory_breakpoint.
4176
41f98f02
PA
41772015-04-01 Pedro Alves <palves@redhat.com>
4178 Cleber Rosa <crosa@redhat.com>
4179
4180 * server.c (gdbserver_usage): Reorganize and extend the usage
4181 message.
4182
2bf6fb9d
PA
41832015-03-24 Pedro Alves <palves@redhat.com>
4184
4185 * linux-low.c (check_stopped_by_breakpoint): Tweak debug log
4186 output. Also dump TRAP_TRACE.
4187 (linux_low_filter_event): In debug output, distinguish a
4188 resume_stop SIGSTOP from a delayed SIGSTOP.
4189
369f6daa
GB
41902015-03-24 Gary Benson <gbenson@redhat.com>
4191
4192 * linux-x86-low.c (x86_linux_new_thread): Moved to
4193 nat/x86-linux.c.
4194 (x86_linux_prepare_to_resume): Likewise.
4195
8e5d4070
GB
41962015-03-24 Gary Benson <gbenson@redhat.com>
4197
4198 * Makefile.in (x86-linux-dregs.o): New rule.
4199 * configure.srv: Add x86-linux-dregs.o to relevant targets.
4200 * linux-x86-low.c: Include nat/x86-linux-dregs.h.
4201 (u_debugreg_offset): Moved to nat/x86-linux-dregs.c.
4202 (x86_linux_dr_get): Likewise.
4203 (x86_linux_dr_set): Likewise.
4204 (update_debug_registers_callback): Likewise.
4205 (x86_linux_dr_set_addr): Likewise.
4206 (x86_linux_dr_get_addr): Likewise.
4207 (x86_linux_dr_set_control): Likewise.
4208 (x86_linux_dr_get_control): Likewise.
4209 (x86_linux_dr_get_status): Likewise.
4210 (x86_linux_update_debug_registers): Likewise.
4211
2b95d440
GB
42122015-03-24 Gary Benson <gbenson@redhat.com>
4213
4214 * linux-x86-low.c (x86_linux_update_debug_registers):
4215 New function, factored out from...
4216 (x86_linux_prepare_to_resume): ...this.
4217
14b0bc68
GB
42182015-03-24 Gary Benson <gbenson@redhat.com>
4219
4220 * linux-x86-low.c (x86_linux_dr_get): Update comments.
4221 (x86_linux_dr_set): Likewise.
4222 (update_debug_registers_callback): Likewise.
4223 (x86_linux_dr_set_addr): Likewise.
4224 (x86_linux_dr_get_addr): Likewise.
4225 (x86_linux_dr_set_control): Likewise.
4226 (x86_linux_dr_get_control): Likewise.
4227 (x86_linux_dr_get_status): Likewise.
4228 (x86_linux_prepare_to_resume): Likewise.
4229
5dfe6ca8
GB
42302015-03-24 Gary Benson <gbenson@redhat.com>
4231
4232 * linux-x86-low.c (x86_linux_dr_get): Add assertion.
4233 Use perror_with_name. Pass string through gettext.
4234 (x86_linux_dr_set): Likewise.
4235
d33472ad
GB
42362015-03-24 Gary Benson <gbenson@redhat.com>
4237
4238 * linux-x86-low.c (x86_dr_low_set_addr): Rename to...
4239 (x86_linux_dr_set_addr): ...this.
4240 (x86_dr_low_get_addr): Rename to...
4241 (x86_linux_dr_get_addr): ...this.
4242 (x86_dr_low_set_control): Rename to...
4243 (x86_linux_dr_set_control): ...this.
4244 (x86_dr_low_get_control): Rename to...
4245 (x86_linux_dr_get_control): ...this.
4246 (x86_dr_low_get_status): Rename to...
4247 (x86_linux_dr_get_status): ...this.
4248 (x86_dr_low): Update with new function names.
4249
4b134ca1
GB
42502015-03-24 Gary Benson <gbenson@redhat.com>
4251
4252 * Makefile.in (x86-linux.o): New rule.
4253 * configure.srv: Add x86-linux.o to relevant targets.
4254 * linux-low.c (lwp_set_arch_private_info): New function.
4255 (lwp_arch_private_info): Likewise.
4256 * linux-x86-low.c: Include nat/x86-linux.h.
4257 (arch_lwp_info): Removed structure.
4258 (update_debug_registers_callback):
4259 Use lwp_set_debug_registers_changed.
4260 (x86_linux_prepare_to_resume): Use lwp_debug_registers_changed
4261 and lwp_set_debug_registers_changed.
4262 (x86_linux_new_thread): Use lwp_set_debug_registers_changed.
4263
34c703da
GB
42642015-03-24 Gary Benson <gbenson@redhat.com>
4265
4266 * linux-low.h (linux_target_ops) <new_thread>: Changed signature.
4267 * linux-arm-low.c (arm_new_thread): Likewise.
4268 * linux-aarch64-low.c (aarch64_linux_new_thread): Likewise.
4269 * linux-mips-low.c (mips_linux_new_thread): Likewise.
4270 * linux-x86-low.c (x86_linux_new_thread): Likewise.
4271 * linux-low.c (add_lwp): Update the_low_target.new_thread call.
4272
cff068da
GB
42732015-03-24 Gary Benson <gbenson@redhat.com>
4274
4275 * linux-low.c (ptid_of_lwp): New function.
4276 (lwp_is_stopped): Likewise.
4277 (lwp_stop_reason): Likewise.
4278 * linux-x86-low.c (update_debug_registers_callback):
4279 Use lwp_is_stopped.
4280 (x86_linux_prepare_to_resume): Use ptid_of_lwp and
4281 lwp_stop_reason.
4282
b2f7c7e8
GB
42832015-03-24 Gary Benson <gbenson@redhat.com>
4284
4285 * linux-low.h (linux_stop_lwp): Remove declaration.
4286
6d4ee8c6
GB
42872015-03-24 Gary Benson <gbenson@redhat.com>
4288
4289 * linux-low.h: Include nat/linux-nat.h.
4290 * linux-low.c (iterate_over_lwps_args): New structure.
4291 (iterate_over_lwps_filter): New function.
4292 (iterate_over_lwps): Likewise.
4293 * linux-x86-low.c (update_debug_registers_callback):
4294 Update signature to what iterate_over_lwps expects.
4295 Remove PID check that iterate_over_lwps now performs.
4296 (x86_dr_low_set_addr): Use iterate_over_lwps.
4297 (x86_dr_low_set_control): Likewise.
4298
70a0bb6b
GB
42992015-03-24 Gary Benson <gbenson@redhat.com>
4300
4301 * linux-x86-low.c (x86_debug_reg_state): New function.
4302 (x86_linux_prepare_to_resume): Use the above.
4303
7b669087
GB
43042015-03-24 Gary Benson <gbenson@redhat.com>
4305
4306 * linux-low.c (current_lwp_ptid): New function.
4307 * linux-x86-low.c: Include nat/linux-nat.h.
4308 (x86_dr_low_get_addr): Use current_lwp_ptid.
4309 (x86_dr_low_get_control): Likewise.
4310 (x86_dr_low_get_status): Likewise.
4311
eef49a3d
PA
43122015-03-20 Pedro Alves <palves@redhat.com>
4313
4314 * tracepoint.c (cmd_qtstatus): Make "str" const.
4315
b2333d22
PA
43162015-03-20 Pedro Alves <palves@redhat.com>
4317
4318 * server.c (handle_general_set): Make "req_str" const.
4319
23f238d3
PA
43202015-03-19 Pedro Alves <palves@redhat.com>
4321
4322 * linux-low.c (linux_resume_one_lwp): Rename to ...
4323 (linux_resume_one_lwp_throw): ... this. Don't handle ESRCH here,
4324 instead call perror_with_name.
4325 (check_ptrace_stopped_lwp_gone): New function.
4326 (linux_resume_one_lwp): Reimplement as wrapper around
4327 linux_resume_one_lwp_throw that swallows errors if the LWP is
4328 gone.
4329
91baf43f
PA
43302015-03-19 Pedro Alves <palves@redhat.com>
4331
4332 * linux-low.c (count_events_callback, select_event_lwp_callback):
4333 No longer check whether the thread has resume_stop as last resume
4334 kind.
4335
8bf3b159
PA
43362015-03-19 Pedro Alves <palves@redhat.com>
4337
4338 * linux-low.c (count_events_callback, select_event_lwp_callback):
4339 Use the lwp's status_pending_p field, not the thread's.
4340
b90fc188
PA
43412015-03-19 Pedro Alves <palves@redhat.com>
4342
4343 * linux-low.c (select_event_lwp_callback): Update comments to
4344 no longer mention SIGTRAP.
4345
464b0089
GB
43462015-03-18 Gary Benson <gbenson@redhat.com>
4347
4348 * server.c (handle_query): Do not report vFile:fstat as supported.
4349
aa9e327f
GB
43502015-03-11 Gary Benson <gbenson@redhat.com>
4351
4352 * hostio.c (sys/types.h): New include.
4353 (sys/stat.h): Likewise.
4354 (common-remote-fileio.h): Likewise.
4355 (handle_fstat): New function.
4356 (handle_vFile): Handle vFile:fstat packets.
aa9e327f 4357
791c0056
GB
43582015-03-11 Gary Benson <gbenson@redhat.com>
4359
4360 * configure.ac (AC_CHECK_MEMBERS): Add checks for
4361 struct stat.st_blocks and struct stat.st_blksize.
4362 * configure: Regenerate.
4363 * config.in: Likewise.
4364 * Makefile.in (SFILES): Add common/common-remote-fileio.c.
4365 (OBS): Add common-remote-fileio.o.
4366 (common-remote-fileio.o): New rule.
4367
9a9df970
PA
43682015-03-09 Pedro Alves <palves@redhat.com>
4369
4370 * tracepoint.c (gdb_agent_helper_thread): Cast '&sockaddr' to
4371 'struct sockaddr' pointer in 'accept' call.
4372
9eb1356e
PA
43732015-03-09 Pedro Alves <palves@redhat.com>
4374
4375 Revert:
4376 2015-03-07 Pedro Alves <palves@redhat.com>
4377 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
4378 or <winsock2.h> here. Instead include "gdb_socket.h".
4379 (remote_open): Use union gdb_sockaddr_u.
4380 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
4381 or <winsock2.h> here. Instead include "gdb_socket.h".
4382 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
4383 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
4384 or <sys/un.h>.
4385 (init_named_socket, gdb_agent_helper_thread): Use union
4386 gdb_sockaddr_u.
4387
aac331e4
PA
43882015-03-07 Pedro Alves <palves@redhat.com>
4389
4390 * configure.ac (build_warnings): Move
4391 -Wdeclaration-after-statement to the C-specific set.
4392 * configure: Regenerate.
4393
366c75fc
PA
43942015-03-07 Pedro Alves <palves@redhat.com>
4395
4396 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
4397 or <winsock2.h> here. Instead include "gdb_socket.h".
4398 (remote_open): Use union gdb_sockaddr_u.
4399 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
4400 or <winsock2.h> here. Instead include "gdb_socket.h".
4401 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
4402 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
4403 or <sys/un.h>.
4404 (init_named_socket, gdb_agent_helper_thread): Use union
4405 gdb_sockaddr_u.
4406
492d29ea
PA
44072015-03-07 Pedro Alves <palves@redhat.com>
4408
4409 Adjust all callers of TRY_CATCH to use TRY/CATCH/END_CATCH
4410 instead.
4411
60a191ed
YQ
44122015-03-06 Yao Qi <yao.qi@linaro.org>
4413
4414 * linux-aarch64-low.c (aarch64_insert_point): Use
4415 show_debug_regs as a boolean.
4416 (aarch64_remove_point): Likewise.
4417
f5771b1d
PA
44182015-03-05 Pedro Alves <palves@redhat.com>
4419
4420 * lynx-low.c (lynx_target_ops): Install NULL hooks for
4421 stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
4422 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint.
4423 * nto-low.c (nto_target_ops): Likewise.
4424 * spu-low.c (spu_target_ops): Likewise.
4425 * win32-low.c (win32_target_ops): Likewise.
4426
3e572f71
PA
44272015-03-04 Pedro Alves <palves@redhat.com>
4428
72f4393d 4429 * linux-low.c (check_stopped_by_breakpoint) [USE_SIGTRAP_SIGINFO]:
3e572f71
PA
4430 Decide whether a breakpoint triggered based on the SIGTRAP's
4431 siginfo.si_code.
72f4393d
L
4432 (thread_still_has_status_pending_p) [USE_SIGTRAP_SIGINFO]: Don't check whether a
4433 breakpoint is inserted if relying on SIGTRAP's siginfo.si_code.
3e572f71
PA
4434 (linux_low_filter_event): Check for breakpoints before checking
4435 watchpoints.
4436 (linux_wait_1): Don't re-increment the PC if relying on SIGTRAP's
4437 siginfo.si_code.
72f4393d
L
4438 (linux_stopped_by_sw_breakpoint)
4439 (linux_supports_stopped_by_sw_breakpoint)
4440 (linux_stopped_by_hw_breakpoint)
4441 (linux_supports_stopped_by_hw_breakpoint): New functions.
4442 (linux_target_ops): Install new target methods.
3e572f71 4443
1ec68e26
PA
44442015-03-04 Pedro Alves <palves@redhat.com>
4445
4446 * remote-utils.c (prepare_resume_reply): Report swbreak/hbreak.
4447 * server.c (swbreak_feature, hwbreak_feature): New globals.
4448 (handle_query) <qSupported>: Handle "swbreak+" and "hwbreak+".
4449 (captured_main): Clear swbreak_feature and hwbreak_feature.
4450 * server.h (swbreak_feature, hwbreak_feature): Declare.
4451 * target.h (struct target_ops) <stopped_by_sw_breakpoint,
4452 supports_stopped_by_sw_breakpoint, stopped_by_hw_breakpoint,
4453 supports_stopped_by_hw_breakpoint>: New fields.
4454 (target_supports_stopped_by_sw_breakpoint)
4455 (target_stopped_by_sw_breakpoint)
4456 (target_supports_stopped_by_hw_breakpoint)
4457 (target_stopped_by_hw_breakpoint): Declare.
4458
15c66dd6
PA
44592015-03-04 Pedro Alves <palves@redhat.com>
4460
4461 enum lwp_stop_reason -> enum target_stop_reason
4462 * linux-low.c (check_stopped_by_breakpoint): Adjust.
4463 (thread_still_has_status_pending_p, check_stopped_by_watchpoint)
4464 (linux_wait_1, stuck_in_jump_pad_callback)
4465 (move_out_of_jump_pad_callback, linux_resume_one_lwp)
4466 (linux_stopped_by_watchpoint):
4467 * linux-low.h (enum lwp_stop_reason): Delete.
4468 (struct lwp_info) <stop_reason>: Now an enum target_stop_reason.
4469 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
4470
98fc70d6
YQ
44712015-03-04 Yao Qi <yao.qi@linaro.org>
4472
4473 * Makefile.in (SFILES): Add linux-aarch64-low.c.
4474
dd2ac174
GB
44752015-03-03 Gary Benson <gbenson@redhat.com>
4476
4477 * hostio.c (handle_vFile): Fix prefix lengths.
4478
d68e53f4
MM
44792015-03-03 Markus Metzger <markus.t.metzger@intel.com>
4480
4481 * linux-low.c (linux_low_enable_btrace): Do not overwrite non-zero
4482 ptr_bits.
4483
bf2d68ab
AA
44842015-03-02 Andreas Arnez <arnez@linux.vnet.ibm.com>
4485
4486 * Makefile.in (s390-vx-linux64.c, s390-tevx-linux64.c)
4487 (s390x-vx-linux64.c, s390x-tevx-linux64.c): New rules.
4488 (clean): Add "rm -f" for above C files.
4489 * configure.srv (srv_regobj): Add s390-vx-linux64.o,
4490 s390-tevx-linux64.o, s390x-vx-linux64.o, and s390x-tevx-linux64.o.
4491 (srv_xmlfiles): Add s390-vx-linux64.xml, s390-tevx-linux64.xml,
4492 s390x-vx-linux64.xml, s390x-tevx-linux64.xml, and s390-vx.xml.
4493 * linux-s390-low.c (HWCAP_S390_VX): New macro.
4494 (init_registers_s390_vx_linux64, init_registers_s390_tevx_linux64)
4495 (init_registers_s390x_vx_linux64)
4496 (init_registers_s390x_tevx_linux64)
4497 (tdesc_s390_vx_linux64, tdesc_s390_tevx_linux64)
4498 (tdesc_s390x_vx_linux64, tdesc_s390x_tevx_linux64): New extern
4499 declarations.
4500 (s390_fill_vxrs_low, s390_store_vxrs_low, s390_fill_vxrs_high)
4501 (s390_store_vxrs_high): New functions.
4502 (s390_regsets): Add entries for NT_S390_VXRS_LOW and
4503 NT_S390_VXRS_HIGH.
4504 (s390_arch_setup): Add logic for selecting one of the new target
4505 descriptions. Activate the new vector regsets if applicable.
4506 (initialize_low_arch): Also invoke init_registers_s390_vx_linux64,
4507 init_registers_s390_tevx_linux64, init_registers_s390x_vx_linux64,
4508 and init_registers_s390x_tevx_linux64.
4509
c966a859
PA
45102015-03-01 Pedro Alves <palves@redhat.com>
4511
4512 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Constify 'raw_regs'
4513 parameter.
4514
4180215b
PA
45152015-02-27 Pedro Alves <palves@redhat.com>
4516
4517 * linux-x86-low.c (u_debugreg_offset): New function.
4518 (x86_linux_dr_get, x86_linux_dr_set): Use it.
4519
749bab01
PA
45202015-02-27 Pedro Alves <palves@redhat.com>
4521
4522 * gdb_proc_service.h: Wrap with EXTERN_C_PUSH/EXTERN_C_POP.
4523 [!HAVE_PROC_SERVICE_H] (struct ps_prochandle): Forward declare.
4524 [!HAVE_PROC_SERVICE_H] (ps_pdread, ps_pdwrite, ps_ptread)
4525 ps_ptwrite, ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
4526 (ps_lsetfpregs, ps_getpid)
4527 (ps_get_thread_area, ps_pglobal_lookup, ps_pstop, ps_pcontinue)
4528 (ps_lstop, ps_lcontinue, ps_lgetxregsize, ps_lgetxregs)
4529 (ps_lsetxregs, ps_plog): Declare.
4530
3c14e5a3
PA
45312015-02-27 Pedro Alves <palves@redhat.com>
4532
4533 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Use
4534 IP_AGENT_EXPORT_FUNC.
4535 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Use
4536 IP_AGENT_EXPORT_FUNC.
4537 * tracepoint.c (ATTR_USED, ATTR_NOINLINE, ATTR_CONSTRUCTOR)
4538 (IP_AGENT_EXPORT): Delete.
4539 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
4540 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
4541 (gdb_trampoline_buffer_error, collecting, gdb_collect)
4542 (stop_tracing, flush_trace_buffer, about_to_request_buffer_space)
4543 (trace_buffer_is_full, stopping_tracepoint, expr_eval_result)
4544 (error_tracepoint, tracepoints, tracing, trace_buffer_ctrl)
4545 (trace_buffer_ctrl_curr, trace_buffer_lo, trace_buffer_hi)
4546 (traceframe_read_count, traceframe_write_count)
4547 (traceframes_created, trace_state_variables, get_raw_reg)
4548 (get_trace_state_variable_value, set_trace_state_variable_value)
4549 (ust_loaded, helper_thread_id, cmd_buf): Use
4550 IPA_SYM_EXPORTED_NAME.
4551 (stop_tracing, flush_trace_buffer): Use IP_AGENT_EXPORT_FUNC.
4552 (tracepoints) Use IP_AGENT_EXPORT_VAR.
4553 (stopping_tracepoint, trace_buffer_is_full, expr_eval_result): Use
4554 IP_AGENT_EXPORT_VAR and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
4555 (last_tracepoint): Move into !IN_PROCESS_AGENT block.
4556 (error_tracepoint): Use IP_AGENT_EXPORT_VAR and wrap in
4557 EXTERN_C_PUSH/EXTERN_C_POP.
4558 (trace_state_variables): Use IP_AGENT_EXPORT_VAR.
4559 (trace_buffer_lo, trace_buffer_hi): Use IP_AGENT_EXPORT_VAR and
4560 wrap in EXTERN_C_PUSH/EXTERN_C_POP.
4561 (trace_buffer_ctrl, trace_buffer_ctrl_curr)
4562 (traceframe_write_count, traceframe_read_count)
4563 (traceframes_created, tracing): Use IP_AGENT_EXPORT_VAR.
4564 (about_to_request_buffer_space, get_trace_state_variable_value)
4565 (set_trace_state_variable_value): Use IP_AGENT_EXPORT_FUNC.
4566 (collecting): Use IP_AGENT_EXPORT_VAR and wrap in
4567 EXTERN_C_PUSH/EXTERN_C_POP.
4568 (gdb_collect): Use IP_AGENT_EXPORT_FUNC.
4569 (ust_loaded, cmd_buf): Use IP_AGENT_EXPORT_VAR.
4570 (helper_thread_id, gdb_agent_capability): Use IP_AGENT_EXPORT_VAR
4571 and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
4572 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
4573 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
4574 (gdb_trampoline_buffer_error): Use IP_AGENT_EXPORT_VAR.
4575 * tracepoint.h (ATTR_USED, ATTR_NOINLINE, EXPORTED_SYMBOL):
4576 Define.
4577 (IP_AGENT_EXPORT_FUNC, IP_AGENT_EXPORT_VAR)
4578 (IP_AGENT_EXPORT_VAR_DECL): Define.
4579 (tracing): Declare.
4580 (gdb_agent_get_raw_reg): Declare.
4581
fe978cb0
PA
45822015-02-27 Tom Tromey <tromey@redhat.com>
4583 Pedro Alves <palves@redhat.com>
4584
4585 Rename symbols whose names are reserved C++ keywords throughout.
4586
3bc3d82a
PA
45872015-02-27 Pedro Alves <palves@redhat.com>
4588
4589 * Makefile.in (COMPILER): New, get it from autoconf.
4590 (CXX): Get from autoconf instead.
4591 (COMPILE.pre): Use COMPILER.
4592 (CC-LD): Rename to ...
4593 (CC_LD): ... this. Use COMPILER.
4594 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT), $(IPA_LIB)): Adjust.
4595 (CXX_FOR_TARGET): Default to g++ instead of gcc.
4596 * acinclude.m4: Include build-with-cxx.m4.
4597 * configure.ac: Call AC_PROG_CXX and GDB_AC_BUILD_WITH_CXX.
4598 Disable -Werror by default if building in C++ mode.
4599 (build_warnings): Add -Wno-sign-compare, -Wno-write-strings and
4600 -Wno-narrowing in C++ mode. Run supported-warning-flags tests with
4601 the C++ compiler. Save/restore CXXFLAGS too.
4602 * configure: Regenerate.
4603
07697489
PA
46042015-02-27 Pedro Alves <palves@redhat.com>
4605
4606 * acinclude.m4: Include libiberty.m4.
4607 * configure.ac: Call libiberty_INIT.
4608 * config.in, configure: Regenerate.
4609
9beb7c4e
PA
46102015-02-26 Pedro Alves <palves@redhat.com>
4611
4612 * linux-low.c (linux_wait_1): When incrementing the PC past a
4613 program breakpoint always use the_low_target.breakpoint_len as
4614 increment, rather than the maximum between that and
4615 the_low_target.decr_pc_after_break.
4616
8090aef2
PA
46172015-02-23 Pedro Alves <palves@redhat.com>
4618
4619 * linux-low.c (check_stopped_by_breakpoint): Don't check if the
4620 thread was doing a step-over; always adjust the PC if
4621 we stepped over a permanent breakpoint.
4622 (linux_wait_1): If we stepped over breakpoint that was on top of a
4623 permanent breakpoint, manually advance the PC past it.
4624
bc9540e8
PA
46252015-02-23 Pedro Alves <palves@redhat.com>
4626
4627 * linux-x86-low.c (REGSIZE): Define in both 32-bit and 64-bit
4628 modes.
4629 (x86_fill_gregset, x86_store_gregset): Use it when handling
4630 $orig_eax.
4631
2db9a427
PA
46322015-02-20 Pedro Alves <palves@redhat.com>
4633
4634 * thread-db.c: Include "nat/linux-procfs.h".
4635 (thread_db_init): Skip listing new threads if the kernel supports
4636 PTRACE_EVENT_CLONE and /proc/PID/task/ is accessible.
4637
afa8d396
PA
46382015-02-20 Pedro Alves <palves@redhat.com>
4639
4640 * linux-low.c (status_pending_p_callback): Use ptid_match.
4641
c9587f88
AT
46422015-02-19 Antoine Tremblay <antoine.tremblay@ericsson.com>
4643
4644 PR breakpoints/16812
4645 * linux-low.c (wstatus_maybe_breakpoint): Remove.
4646 (linux_low_filter_event): Update wstatus_maybe_breakpoint name.
4647 (linux_wait_1): Report SIGTRAP,SIGILL,SIGSEGV.
4648
b05ec7a5
AT
46492015-02-10 Antoine Tremblay <antoine.tremblay@ericsson.com>
4650
4651 PR breakpoints/15956
4652 * tracepoint.c (cmd_qtinit): Add check for current_thread.
4653
d33501a5
MM
46542015-02-09 Markus Metzger <markus.t.metzger@intel.com>
4655
4656 * linux-low.c (linux_low_btrace_conf): Print size.
4657 * server.c (handle_btrace_conf_general_set): New.
4658 (hanle_general_set): Call handle_btrace_conf_general_set.
4659 (handle_query): Report Qbtrace-conf:bts:size as supported.
4660
f4abbc16
MM
46612015-02-09 Markus Metzger <markus.t.metzger@intel.com>
4662
4663 * linux-low.c (linux_low_enable_btrace): Update parameters.
4664 (linux_low_btrace_conf): New.
4665 (linux_target_ops)<to_btrace_conf>: Initialize.
4666 * server.c (current_btrace_conf): New.
4667 (handle_btrace_enable): Rename to ...
4668 (handle_btrace_enable_bts): ... this. Pass &current_btrace_conf
4669 to target_enable_btrace. Update comment. Update users.
4670 (handle_qxfer_btrace_conf): New.
4671 (qxfer_packets): Add btrace-conf entry.
4672 (handle_query): Report qXfer:btrace-conf:read as supported packet.
4673 * target.h (target_ops)<enable_btrace>: Update parameters and comment.
4674 (target_ops)<read_btrace_conf>: New.
4675 (target_enable_btrace): Update parameters.
4676 (target_read_btrace_conf): New.
4677
043c3577
MM
46782015-02-09 Markus Metzger <markus.t.metzger@intel.com>
4679
4680 * server.c (handle_btrace_general_set): Remove call to
4681 target_supports_btrace.
4682 (supported_btrace_packets): New.
4683 (handle_query): Call supported_btrace_packets.
4684 * target.h: include btrace-common.h.
4685 (btrace_target_info): Removed.
4686 (supports_btrace, target_supports_btrace): Update parameters.
4687
734b0e4b
MM
46882015-02-09 Markus Metzger <markus.t.metzger@intel.com>
4689
4690 * Makefile.in (SFILES): Add common/btrace-common.c.
4691 (OBS): Add common/btrace-common.o.
4692 (btrace-common.o): Add build rules.
4693 * linux-low: Include btrace-common.h.
4694 (linux_low_read_btrace): Use struct btrace_data. Call
4695 btrace_data_init and btrace_data_fini.
4696
d6c146e9
PA
46972015-02-06 Pedro Alves <palves@redhat.com>
4698
4699 * thread-db.c (find_new_threads_callback): Add debug output.
4700
20ba1ce6
PA
47012015-02-04 Pedro Alves <palves@redhat.com>
4702
4703 * linux-low.c (handle_extended_wait): Don't resume LWPs here.
4704 (resume_stopped_resumed_lwps): New function.
4705 (linux_wait_for_event_filtered): Use it.
4706
8cc73a39
SDJ
47072015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
4708
4709 * Makefile.in (SFILES): Add linux-personality.c.
4710 (linux-personality.o): New rule.
4711 * configure.srv (srv_linux_obj): Add linux-personality.o to the
4712 list of objects to be built.
4713 * linux-low.c: Include nat/linux-personality.h.
4714 (linux_create_inferior): Remove code to disable address space
4715 randomization (moved to ../nat/linux-personality.c). Create
4716 cleanup to disable address space randomization.
4717
fb23d554
SDJ
47182015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
4719
4720 * Makefile.in (posix-strerror.o): New rule.
4721 (mingw-strerror.o): Likewise.
4722 * configure: Regenerated.
4723 * configure.ac: Source file ../common/common.host. Initialize new
4724 variable srv_host_obs. Add srv_host_obs to GDBSERVER_DEPFILES.
4725
cdf43629
YQ
47262015-01-14 Yao Qi <yao@codesourcery.com>
4727
4728 * Makefile.in (SFILES): Add nat/ppc-linux.c.
4729 (ppc-linux.o): New rule.
4730 * configure.srv (powerpc*-*-linux*): Add ppc-linux.o.
4731 * configure.ac: AC_CHECK_FUNCS(getauxval).
4732 * config.in: Re-generated.
4733 * configure: Re-generated.
4734 * linux-ppc-low.c (ppc_arch_setup) [__powerpc64__]: Call
4735 ppc64_64bit_inferior_p
4736
514c5338
YQ
47372015-01-14 Yao Qi <yao@codesourcery.com>
4738
4739 * linux-ppc-low.c: Include "nat/ppc-linux.h".
4740 (PPC_FEATURE_HAS_VSX): Move to nat/ppc-linux.h.
4741 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Likewise.
4742 (PT_ORIG_R3, PT_TRAP): Likewise.
4743 (PTRACE_GETVSXREGS, PTRACE_SETVSXREGS): Likewise.
4744 (PTRACE_GETVRREGS, PTRACE_SETVRREGS): Likewise.
4745 (PTRACE_GETEVRREGS, PTRACE_SETEVRREGS): Likewise.
4746
3368c1e5
JB
47472015-01-10 Joel Brobecker <brobecker@adacore.com>
4748
4749 * i387-fp.c (i387_cache_to_xsave): In look over
4750 num_avx512_zmmh_high_registers, replace use of struct i387_xsave
4751 zmmh_low_space field by use of zmmh_high_space.
4752
582511be
PA
47532015-01-09 Pedro Alves <palves@redhat.com>
4754
4755 * linux-low.c (step_over_bkpt): Move higher up in the file.
4756 (handle_extended_wait): Don't store the stop_pc here.
4757 (get_stop_pc): Adjust comments and rename to ...
4758 (check_stopped_by_breakpoint): ... this. Record whether the LWP
4759 stopped for a software breakpoint or hardware breakpoint.
4760 (thread_still_has_status_pending_p): New function.
4761 (status_pending_p_callback): Use
4762 thread_still_has_status_pending_p. If the event is no longer
4763 interesting, resume the LWP.
4764 (handle_tracepoints): Add assert.
4765 (maybe_move_out_of_jump_pad): Remove cancel_breakpoints call.
4766 (wstatus_maybe_breakpoint): New function.
4767 (cancel_breakpoint): Delete function.
4768 (check_stopped_by_watchpoint): New function, factored out from
4769 linux_low_filter_event.
4770 (lp_status_maybe_breakpoint): Delete function.
4771 (linux_low_filter_event): Remove filter_ptid argument.
4772 Leave thread group exits pending here. Store the LWP's stop PC.
4773 Always leave events pending.
4774 (linux_wait_for_event_filtered): Pull all events out of the
4775 kernel, and leave them all pending.
4776 (count_events_callback, select_event_lwp_callback): Consider all
4777 events.
4778 (cancel_breakpoints_callback, linux_cancel_breakpoints): Delete.
4779 (select_event_lwp): Only give preference to the stepping LWP in
4780 all-stop mode. Adjust comments.
4781 (ignore_event): New function.
4782 (linux_wait_1): Delete 'retry' label. Use ignore_event. Remove
4783 references to cancel_breakpoints. Adjust to renames. Also give
4784 equal priority to all LWPs that have had events in non-stop mode.
4785 If reporting a software breakpoint event, unadjust the LWP's PC.
4786 (linux_wait): If linux_wait_1 returned an ignored event, retry.
4787 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback):
4788 Adjust.
4789 (linux_resume_one_lwp): Store the LWP's PC. Adjust.
4790 (resume_status_pending_p): Use thread_still_has_status_pending_p.
4791 (linux_stopped_by_watchpoint): Adjust.
4792 (linux_target_ops): Remove reference to linux_cancel_breakpoints.
4793 * linux-low.h (enum lwp_stop_reason): New.
4794 (struct lwp_info) <stop_pc>: Adjust comment.
4795 <stopped_by_watchpoint>: Delete field.
4796 <stop_reason>: New field.
4797 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
4798 * mem-break.c (software_breakpoint_inserted_here)
4799 (hardware_breakpoint_inserted_here): New function.
4800 * mem-break.h (software_breakpoint_inserted_here)
4801 (hardware_breakpoint_inserted_here): Declare.
4802 * target.h (struct target_ops) <cancel_breakpoints>: Remove field.
4803 (cancel_breakpoints): Delete.
4804 * tracepoint.c (clear_installed_tracepoints, stop_tracing)
4805 (upload_fast_traceframes): Remove references to
4806 cancel_breakpoints.
4807
a33e3959
PA
48082015-01-09 Pedro Alves <palves@redhat.com>
4809
4810 * thread-db.c (find_new_threads_callback): Ignore thread if the
4811 kernel thread ID is -1.
4812
8784d563
PA
48132015-01-09 Pedro Alves <palves@redhat.com>
4814
4815 * linux-low.c (linux_attach_fail_reason_string): Move to
4816 nat/linux-ptrace.c, and rename.
4817 (linux_attach_lwp): Update comment.
4818 (attach_proc_task_lwp_callback): New function.
4819 (linux_attach): Adjust to rename and use
4820 linux_proc_attach_tgid_threads.
4821 (linux_attach_fail_reason_string): Delete declaration.
4822
76f2b779
JB
48232015-01-01 Joel Brobecker <brobecker@adacore.com>
4824
4825 * gdbreplay.c (gdbreplay_version): Update copyright year to 2015.
4826 * server.c (gdbserver_version): Likewise.
4827
fafcc06a
SDJ
48282014-12-29 Sergio Durigan Junior <sergiodj@redhat.com>
4829
4830 * remote-utils.c: Include ctype.h.
4831 (input_interrupt): Explicitly handle the case when the char
4832 received is the NUL byte. Improve the printing of non-ASCII
4833 characters.
4834
beed38b8
JB
48352014-12-16 Joel Brobecker <brobecker@adacore.com>
4836
4837 * linux-low.c (linux_low_filter_event): Update call to
4838 linux_enable_event_reporting following the addition of
4839 a new parameter to that function.
4840
bf330350
CU
48412014-12-16 Catalin Udma <catalin.udma@freescale.com>
4842
4843 PR server/17457
4844 * linux-aarch64-low.c (AARCH64_FPSR_REGNO): New define.
4845 (AARCH64_FPCR_REGNO): Likewise.
4846 (AARCH64_NUM_REGS): Update to include fpsr/fpcr registers.
4847 (aarch64_fill_fpregset): Add missing fpsr/fpcr registers.
4848 (aarch64_store_fpregset): Likewise.
4849
5227d625
JB
48502014-12-15 Joel Brobecker <brobecker@adacore.com>
4851
4852 * lynx-low.c (lynx_resume): Use PTRACE_SINGLESTEP_ONE if N == 1.
4853 Remove FIXME comment about assumption about N.
4854
f93b65a0
JB
48552014-12-13 Joel Brobecker <brobecker@adacore.com>
4856
4857 * configure.ac: If large-file support is disabled in GDBserver,
4858 pass --disable-largefile to ACX_CONFIGURE_DIR call for "gnulib".
4859 * configure: Regenerate.
4860
e5a9158d
AA
48612014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
4862
4863 * linux-low.c (regsets_fetch_inferior_registers): Suppress the
4864 warning upon ENODATA from ptrace.
4865 * linux-s390-low.c (s390_store_tdb): New.
4866 (s390_regsets): Add regset for NT_S390_TDB.
4867
feea5f36
AA
48682014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
4869
4870 * linux-low.c (regsets_store_inferior_registers): Skip regsets
4871 without a fill_function.
4872 * linux-s390-low.c (s390_fill_last_break): Remove.
4873 (s390_regsets): Set fill_function to NULL for NT_S390_LAST_BREAK.
4874 (s390_arch_setup): Use regset's size instead of fill_function for
4875 loop end condition.
4876
098dbe61
AA
48772014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
4878
4879 * linux-low.c (regsets_fetch_inferior_registers): Do not invoke
4880 the regset's store function when ptrace returned an error.
4881 * regcache.c (get_thread_regcache): Invalidate register cache
4882 before fetching inferior's registers.
4883
28eef672
AA
48842014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
4885
4886 * linux-low.c (regsets_fetch_inferior_registers): Rephrase
4887 while-loop as for-loop.
4888 (regsets_store_inferior_registers): Likewise.
4889
bdca27a2
YQ
48902014-11-28 Yao Qi <yao@codesourcery.com>
4891
4892 * configure.ac(AC_CHECK_FUNCS): Remove readlink.
4893 * config.in, configure: Re-generate.
4894 * hostio.c (handle_unlink): Remove code checking HAVE_READLINK
4895 is defined.
4896
9c232dda
YQ
48972014-11-21 Yao Qi <yao@codesourcery.com>
4898
4899 * configure.ac: Don't invoke AC_FUNC_ALLOCA.
4900 (AC_CHECK_HEADERS): Remove malloc.h.
4901 * configure: Re-generated.
4902 * config.in: Re-generated.
4903 * server.h: Don't include alloca.h and malloc.h.
4904 * gdbreplay.c: Don't check HAVE_ALLOCA_H is defined.
4905 Don't include malloc.h.
4906
43968415
JB
49072014-11-17 Joel Brobecker <brobecker@adacore.com>
4908
4909 * lynx-low.c (lynx_write_memory): Put lynx_read_memory and
4910 corresponding ERRNO check in same block.
4911
40e91bc7
PA
49122014-11-12 Pedro Alves <palves@redhat.com>
4913
4914 * server.c (cont_thread): Update comment.
4915 (start_inferior, attach_inferior): No longer clear cont_thread.
4916 (handle_v_cont): No longer set cont_thread.
4917 (captured_main): Clear cont_thread each time a GDB connects.
4918
c2c118cf
PA
49192014-11-12 Pedro Alves <palves@redhat.com>
4920
4921 * linux-low.c (linux_wait_1): Don't force a wait for the Hc
4922 thread, and don't resume all threads if the Hc thread has exited.
4923
78708b7c
PA
49242014-11-12 Pedro Alves <palves@redhat.com>
4925
4926 * linux-low.c (linux_request_interrupt): Always send a SIGINT to
4927 the process group instead of to a specific LWP.
4928
a2abc7de
PA
49292014-10-15 Pedro Alves <palves@redhat.com>
4930
4931 PR server/17487
4932 * win32-arm-low.c (arm_set_thread_context): Remove current_event
4933 parameter.
4934 (arm_set_thread_context): Delete.
4935 (the_low_target): Adjust.
4936 * win32-i386-low.c (debug_registers_changed)
4937 (debug_registers_used): Delete.
4938 (update_debug_registers_callback): New function.
4939 (x86_dr_low_set_addr, x86_dr_low_set_control): Mark all threads as
4940 needing to update their debug registers.
4941 (win32_get_current_dr): New function.
4942 (x86_dr_low_get_addr, x86_dr_low_get_control)
4943 (x86_dr_low_get_status): Fetch the debug register from the thread
4944 record's context.
4945 (i386_initial_stuff): Adjust.
4946 (i386_get_thread_context): Remove current_event parameter. Don't
4947 clear debug_registers_changed nor copy DR values to
4948 debug_reg_state.
4949 (i386_set_thread_context): Delete.
4950 (i386_prepare_to_resume): New function.
4951 (i386_thread_added): Mark the thread as needing to update irs
4952 debug registers.
4953 (the_low_target): Remove i386_set_thread_context and install
4954 i386_prepare_to_resume.
4955 * win32-low.c (win32_get_thread_context): Adjust.
4956 (win32_set_thread_context): Use SetThreadContext
4957 directly.
4958 (win32_prepare_to_resume): New function.
4959 (win32_require_context): New function, factored out from ...
4960 (thread_rec): ... this.
4961 (continue_one_thread): Call win32_prepare_to_resume on each thread
4962 we're about to continue.
4963 (win32_resume): Call win32_prepare_to_resume on the event thread.
4964 * win32-low.h (struct win32_thread_info)
4965 <debug_registers_changed>: New field.
4966 (struct win32_target_ops): Change prototype of set_thread_context,
4967 delete set_thread_context and add prepare_to_resume.
4968 (win32_require_context): New declaration.
4969
a442d071
GB
49702014-10-08 Gary Benson <gbenson@redhat.com>
4971
4972 * server.h: Do not include common-exceptions.h.
4973
6f1947e8
GB
49742014-10-08 Gary Benson <gbenson@redhat.com>
4975
4976 * server.h: Do not include cleanups.h.
4977
63b434a4
JH
49782014-09-30 James Hogan <james.hogan@imgtec.com>
4979
4980 * Makefile.in (clean): Add rm -f commands for mips-dsp-linux.c and
4981 mips64-dsp-linux.c.
4982
c4d9ceb6
YQ
49832014-09-23 Yao Qi <yao@codesourcery.com>
4984
4985 * linux-low.c (lp_status_maybe_breakpoint): New function.
4986 (linux_low_filter_event): Call lp_status_maybe_breakpoint.
4987 (count_events_callback): Likewise.
4988 (select_event_lwp_callback): Likewise.
4989 (cancel_breakpoints_callback): Likewise.
4990
89a5711c
DB
49912014-09-19 Don Breazeal <donb@codesourcery.com>
4992
4993 * linux-low.c (handle_extended_wait): Call
4994 linux_ptrace_get_extended_event.
4995 (get_stop_pc, get_detach_signal, linux_low_filter_event): Call
4996 linux_is_extended_waitstatus.
4997
bffc0964
JB
49982014-09-16 Joel Brobecker <brobecker@adacore.com>
4999
5000 * Makefile.in (CPPFLAGS): Define.
5001 (INTERNAL_CFLAGS_BASE): Add ${CPPFLAGS}.
5002 (IPAGENT_CFLAGS): Remove ${CPPFLAGS}.
5003
0bfdf32f
GB
50042014-09-16 Gary Benson <gbenson@redhat.com>
5005
5006 * inferiors.h (current_inferior): Renamed as...
5007 (current_thread): New variable. All uses updated.
5008 * linux-low.c (get_pc): Renamed saved_inferior as saved_thread.
5009 (maybe_move_out_of_jump_pad): Likewise.
5010 (cancel_breakpoint): Likewise.
5011 (linux_low_filter_event): Likewise.
5012 (wait_for_sigstop): Likewise.
5013 (linux_resume_one_lwp): Likewise.
5014 (need_step_over_p): Likewise.
5015 (start_step_over): Likewise.
5016 (linux_stabilize_threads): Renamed save_inferior as saved_thread.
5017 * linux-x86-low.c (x86_linux_update_xmltarget): Likewise.
5018 * proc-service.c (ps_lgetregs): Renamed reg_inferior as reg_thread
5019 and save_inferior as saved_thread.
5020 * regcache.c (get_thread_regcache): Renamed saved_inferior as
5021 saved_thread.
5022 (regcache_invalidate_thread): Likewise.
5023 * remote-utils.c (prepare_resume_reply): Likewise.
5024 * thread-db.c (thread_db_get_tls_address): Likewise.
5025 (disable_thread_event_reporting): Likewise.
5026 (remove_thread_event_breakpoints): Likewise.
5027 * tracepoint.c (gdb_agent_about_to_close): Renamed save_inferior
5028 as saved_thread.
5029 * target.h (set_desired_inferior): Renamed as...
5030 (set_desired_thread): New declaration. All uses updated.
5031 * server.c (myresume): Updated comment to reference thread instead
5032 of inferior.
5033 (handle_serial_event): Likewise.
5034 (handle_target_event): Likewise.
5035
361c8ade
GB
50362014-09-12 Tom Tromey <tromey@redhat.com>
5037 Gary Benson <gbenson@redhat.com>
5038
5039 * regcache.h: Include common-regcache.h.
5040 (regcache_read_pc): Don't declare.
5041 * regcache.c (get_thread_regcache_for_ptid): New function.
5042
bd9269f7
GB
50432014-09-11 Tom Tromey <tromey@redhat.com>
5044 Gary Benson <gbenson@redhat.com>
5045
5046 * symbol.c: New file.
5047 * Makefile.in (SFILES): Add symbol.c.
5048 (OBS): Add symbol.o.
5049
f8c1d06b
GB
50502014-09-11 Gary Benson <gbenson@redhat.com>
5051
5052 * target.c (target_stop_ptid, target_continue_ptid): New
5053 functions.
5054
721ec300
GB
50552014-09-11 Tom Tromey <tromey@redhat.com>
5056 Gary Benson <gbenson@redhat.com>
5057
5058 * target.h: Include target/target.h.
5059 * target.c (target_read_memory, target_read_uint32)
5060 (target_write_memory): New functions.
5061
c5e92cca
GB
50622014-09-11 Gary Benson <gbenson@redhat.com>
5063
5064 * server.h (debug_hw_points): Don't declare.
5065 * server.c (debug_hw_points): Don't define. Replace all uses
5066 with show_debug_regs.
5067 * linux-aarch64-low.c (debug_hw_points): Don't define. Replace
5068 all uses with show_debug_regs.
5069
2e4bb98a
EBM
50702014-09-08 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
5071
5072 * linux-ppc-low.c (ppc_collect_ptrace_register): Adjust routine to take
5073 endianness into account.
5074 (ppc_supply_ptrace_register): Likewise.
5075
ac740bc7
JH
50762014-09-03 James Hogan <james.hogan@imgtec.com>
5077
5078 * linux-mips-low.c (mips_read_description): Reset errno to 0 prior
5079 to reading DSP_CONTROL with PTRACE_PEEKUSER ptrace call.
5080
97ea6506
GB
50812014-09-03 Gary Benson <gbenson@redhat.com>
5082
5083 * linux-x86-low.c (x86_linux_prepare_to_resume): Use
5084 ALL_DEBUG_ADDRESS_REGISTERS.
5085
df7e5265
GB
50862014-09-02 Gary Benson <gbenson@redhat.com>
5087
5088 * i386-low.h: Renamed as...
5089 * x86-low.h: New file. All type, function and variable name
5090 prefixes changed from "i386_" to "x86_". All references updated.
5091 * i386-low.c: Renamed as...
5092 * x86-low.c: New file. All type, function and variable name
5093 prefixes changed from "i386_" to "x86_". All references updated.
5094
ed859da7
GB
50952014-09-02 Gary Benson <gbenson@redhat.com>
5096
5097 * linux-x86-low.c (x86_linux_new_process): Use XCNEW.
5098 (x86_linux_new_thread): Likewise.
5099
860789c7
GB
51002014-08-29 Gary Benson <gbenson@redhat.com>
5101
5102 * server.h (setjmp.h): Do not include.
5103 (toplevel): Do not declare.
5104 (common-exceptions.h): Include.
5105 (cleanups.h): Likewise.
5106 * server.c (toplevel): Do not define.
5107 (exit_code): New static global.
5108 (detach_or_kill_for_exit_cleanup): New function.
5109 (main): New function. Original main renamed to...
5110 (captured_main): New function.
5111 * utils.c (verror) [!IN_PROCESS_AGENT]: Use throw_verror.
5112
ff55e1b5
GB
51132014-08-29 Gary Benson <gbenson@redhat.com>
5114
5115 * Makefile.in (SFILES): Add common/common-exceptions.c.
5116 (OBS): Add common-exceptions.o.
5117 (common-exceptions.o): New rule.
5118 * utils.c (prepare_to_throw_exception): New function.
5119
e9bcb658
GB
51202014-08-29 Gary Benson <gbenson@redhat.com>
5121
5122 * config.in: Regenerate.
5123 * configure: Likewise.
5124
e3180625
GB
51252014-08-29 Gary Benson <gbenson@redhat.com>
5126
5127 * Makefile.in (SFILES): Add common/cleanups.c.
5128 (OBS): cleanups.o.
5129 (cleanups.o): New rule.
5130
e3d6ba5d
GB
51312014-08-29 Gary Benson <gbenson@redhat.com>
5132
5133 * utils.c (internal_vwarning): New function.
5134
7096e886
GB
51352014-08-28 Gary Benson <gbenson@redhat.com>
5136
5137 * utils.h (fatal): Remove declaration.
5138 * utils.c (fatal): Remove function.
5139
14ce3192
GB
51402014-08-28 Gary Benson <gbenson@redhat.com>
5141
5142 * tracepoint.c (gdb_agent_init): Replace fatal with
5143 perror_with_name.
5144 (initialize_tracepoint): Likewise.
5145
50278d59
GB
51462014-08-28 Gary Benson <gbenson@redhat.com>
5147
5148 * remote-utils.c (remote_prepare): Replace fatal with error.
5149
aa96c426
GB
51502014-08-28 Gary Benson <gbenson@redhat.com>
5151
5152 * linux-low.c (linux_async): Replace fatal with warning.
5153 Tidy up and return.
5154 (linux_start_non_stop): Return -1 if linux_async failed.
5155
f7160e97
GB
51562014-08-28 Gary Benson <gbenson@redhat.com>
5157
5158 * linux-x86-low.c (i386_dr_low_set_addr): Replace check with
5159 gdb_assert.
5160 (i386_dr_low_get_addr): Remove vague comment.
5161 * win32-i386-low.c (i386_dr_low_set_addr): Replace check with
5162 gdb_assert.
5163
38e08fca
GB
51642014-08-28 Gary Benson <gbenson@redhat.com>
5165
5166 * inferiors.c (get_thread_process): Replace check with gdb_assert.
5167 * linux-low.c (linux_wait_for_event_filtered): Replace fatal with
5168 internal_error.
5169 (linux_resume_one_lwp): Likewise.
5170 * linux-x86-low.c (x86_siginfo_fixup): Replace checks with
5171 gdb_assert.
5172 * mem-break.c (raw_bkpt_type_to_target_hw_bp_type): Replace fatal
5173 with internal_error.
5174 * regcache.c (get_thread_regcache): Replace check with gdb_assert.
5175 (init_register_cache): Replace fatal with gdb_assert_not_reached.
5176 (find_register_by_name): Replace fatal with internal_error.
5177 (find_regno): Likewise.
5178 * tdesc.c (init_target_desc): Replace check with gdb_assert.
5179 * thread-db.c (thread_db_create_event): Likewise.
5180 (thread_db_load_search): Likewise.
5181 (try_thread_db_load_1): Likewise.
5182 * tracepoint.c (get_jump_space_head): Replace fatal with
5183 internal_error.
5184 (claim_trampoline_space): Likewise.
5185 (have_fast_tracepoint_trampoline_buffer): Likewise.
5186 (cmd_qtstart): Likewise.
5187 (stop_tracing): Likewise.
5188 (fast_tracepoint_collecting): Likewise.
5189 (target_malloc): Likewise.
5190 (download_tracepoint): Likewise.
5191 (download_trace_state_variables): Replace check with gdb_assert.
5192 (upload_fast_traceframes): Replace fatal with internal_error.
5193
34abf635
GB
51942014-08-19 Tom Tromey <tromey@redhat.com>
5195 Gary Benson <gbenson@redhat.com>
5196
5197 * Makefile.in (SFILES): Add common/common-debug.c.
5198 (OBS): Add common-debug.o.
5199 (common-debug.o): New rule.
5200 * debug.h (debug_printf): Don't declare.
5201 * debug.c (debug_printf): Renamed and rewritten as...
5202 (debug_vprintf): New function.
5203
f6e94d78
GB
52042014-08-19 Gary Benson <gbenson@redhat.com>
5205
5206 * utils.h: Do not include print-utils.h.
5207
9239eeab
GB
52082014-08-19 Tom Tromey <tromey@redhat.com>
5209 Gary Benson <gbenson@redhat.com>
5210
5211 * server.h: Add static assertion.
5212 (gdb_byte, CORE_ADDR, LONGEST, ULONGEST): Remove.
5213
ef87c8bb
GB
52142014-08-19 Tom Tromey <tromey@redhat.com>
5215 Gary Benson <gbenson@redhat.com>
5216
5217 * Makefile.in (SFILES): Add common/errors.c.
5218 (OBS): Add errors.o.
5219 (IPA_OBS): Add errors-ipa.o.
5220 (errors.o): New rule.
5221 (errors-ipa.o): Likewise.
5222 * utils.h (perror_with_name, error, warning): Don't declare.
5223 * utils.c (warning): Renamed and rewritten as...
5224 (vwarning): New function.
5225 (error): Renamed and rewritten as...
5226 (verror): New function.
5227 (internal_error): Renamed and rewritten as...
5228 (internal_verror): New function.
5229
bb974a24
GB
52302014-08-07 Gary Benson <gbenson@redhat.com>
5231
5232 * configure.ac (AC_CHECK_HEADERS): Remove errno.h.
5233 * configure: Regenerate.
5234 * config.in: Likewise.
5235 * server.h: Do not include errno.h.
5236 * event-loop.c: Likewise.
5237 * hostio-errno.c: Likewise.
5238 * linux-low.c: Likewise.
5239 * remote-utils.c: Likewise.
5240 * spu-low.c: Likewise.
5241 * utils.c: Likewise.
5242 * gdbreplay.c: Unconditionally include errno.h.
5243
6d3d12eb
GB
52442014-08-07 Gary Benson <gbenson@redhat.com>
5245
5246 * server.h: Do not include string.h.
5247 * event-loop.c: Likewise.
5248 * linux-low.c: Likewise.
5249 * regcache.c: Likewise.
5250 * remote-utils.c: Likewise.
5251 * spu-low.c: Likewise.
5252 * utils.c: Likewise.
5253
dccbb609
GB
52542014-08-07 Gary Benson <gbenson@redhat.com>
5255
5256 * server.h: Do not include gdb_assert.h.
5257
e76df0d0
GB
52582014-08-07 Gary Benson <gbenson@redhat.com>
5259
5260 * server.h: Do not include common-utils.h.
5261
4cb9c816
GB
52622014-08-07 Gary Benson <gbenson@redhat.com>
5263
5264 * server.h: Do not include ptid.h.
5265 * notif.h: Likewise.
5266
3995eeee
GB
52672014-08-07 Gary Benson <gbenson@redhat.com>
5268
5269 * server.h: Do not include gdb_locale.h.
5270
cb9f1a9b
GB
52712014-08-07 Gary Benson <gbenson@redhat.com>
5272
5273 * server.h: Do not include gdb/signals.h.
5274 * win32-low.c: Likewise.
5275
a5fceff8
GB
52762014-08-07 Gary Benson <gbenson@redhat.com>
5277
5278 * server.h: Do not include pathmax.h.
5279
b9391142
GB
52802014-08-07 Gary Benson <gbenson@redhat.com>
5281
5282 * server.h: Do not include libiberty.h.
5283 * linux-bfin-low.c: Likewise.
5284
0e443c87
GB
52852014-08-07 Gary Benson <gbenson@redhat.com>
5286
5287 * server.h: Do not include ansidecl.h.
5288
8ebb3f56
GB
52892014-08-07 Gary Benson <gbenson@redhat.com>
5290
5291 * linux-x86-low.c: Do not include stddef.h.
5292 * lynx-ppc-low.c: Likewise.
5293 * tracepoint.c: Likewise.
5294
8980bdf6
GB
52952014-08-07 Gary Benson <gbenson@redhat.com>
5296
5297 * server.h: Do not include stdarg.h.
5298 * nto-low.c: Likewise.
5299
d7096f71
GB
53002014-08-07 Gary Benson <gbenson@redhat.com>
5301
5302 * server.h: Do not include stdlib.h.
5303 * inferiors.c: Likewise.
5304 * linux-low.c: Likewise.
5305 * regcache.c: Likewise.
5306 * spu-low.c: Likewise.
5307 * tracepoint.c: Likewise.
5308 * utils.c: Likewise.
5309
d02f550d
GB
53102014-08-07 Gary Benson <gbenson@redhat.com>
5311
5312 * server.h: Do not include stdio.h.
5313 * linux-low.c: Likewise.
5314 * remote-utils.c: Likewise.
5315 * spu-low.c: Likewise.
5316 * utils.c: Likewise.
5317 * wincecompat.c: Likewise.
5318
87f6c4e3
GB
53192014-08-06 Gary Benson <gbenson@redhat.com>
5320
5321 * regcache.c (init_register_cache): Move conditionals inside if.
5322
7089dca4
GB
53232014-08-06 Gary Benson <gbenson@redhat.com>
5324
5325 * linux-low.c (linux_supports_non_stop): Use target_is_async_p.
5326
462f517e
GB
53272014-07-31 Gary Benson <gbenson@redhat.com>
5328
5329 * ax.h: Do not include server.h.
5330 * gdbthread.h: Likewise.
5331 * lynx-low.h: Likewise.
5332 * notif.h: Likewise.
5333
976411d6
GB
53342014-07-30 Gary Benson <gbenson@redhat.com>
5335
5336 * server.h: Include common-defs.h.
5337 Do not include config.h or build-gnulib-gdbserver/config.h.
5338
d41f6d8e
GB
53392014-07-30 Gary Benson <gbenson@redhat.com>
5340
5341 * hostio-errno.c: Move server.h to top of includes list.
5342 * inferiors.c: Likewise.
5343 * linux-x86-low.c: Likewise.
5344 * notif.c: Include server.h.
5345
314c6a35
TT
53462014-07-24 Tom Tromey <tromey@redhat.com>
5347 Gary Benson <gbenson@redhat.com>
5348
5349 * server.h (CORE_ADDR): Now unsigned.
5350
69ff6be5
PA
53512014-07-16 Pedro Alves <palves@redhat.com>
5352
5353 * linux-low.c (linux_kill_one_lwp): Use kill_lwp, not kill.
5354
ce9e3fe7
PA
53552014-07-15 Pedro Alves <palves@redhat.com>
5356
5357 * linux-low.c (linux_kill_one_lwp): Save errno and work with saved
5358 copy.
5359
e76126e8
PA
53602014-07-11 Pedro Alves <palves@redhat.com>
5361
5362 * linux-low.c (kill_wait_lwp): New function, based on
5363 kill_one_lwp_callback, but use my_waitpid directly.
5364 (kill_one_lwp_callback, linux_kill): Use it.
5365
8e9db26e
PA
53662014-06-23 Pedro Alves <palves@redhat.com>
5367
5368 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR_CONTROL
5369 before setting DR0..DR3.
5370
698b3e08
GB
53712014-06-20 Gary Benson <gbenson@redhat.com>
5372
5373 * configure.ac (AC_REPLACE_FUNCS) <vasprintf, vsnprintf>: Removed.
5374 * configure: Regenerated.
5375 * config.in: Likewise.
5376
125f8a3d
GB
53772014-06-20 Gary Benson <gbenson@redhat.com>
5378
5379 * Makefile.in (SFILES): Update locations for files moved
5380 from common to nat.
5381 (object file files): Reordered.
5382
42995dbd
GB
53832014-06-20 Gary Benson <gbenson@redhat.com>
5384
5385 * i386-low.h (i386_dr_low_can_set_addr): Removed.
5386 (i386_dr_low_set_addr): Likewise.
5387 (i386_dr_low_get_addr): Likewise.
5388 (i386_dr_low_can_set_control): Likewise.
5389 (i386_dr_low_set_control): Likewise.
5390 (i386_dr_low_get_control): Likewise.
5391 (i386_dr_low_get_status): Likewise.
5392 (i386_get_debug_register_length): Likewise.
5393 * linux-x86-low.c (i386_dr_low_set_addr):
5394 Changed signature. Made static.
5395 (i386_dr_low_get_addr): Likewise.
5396 (i386_dr_low_set_control): Likewise.
5397 (i386_dr_low_get_control): Likewise.
5398 (i386_dr_low_get_status): Likewise.
5399 (i386_dr_low): New global variable.
5400 * win32-i386-low.c (i386_dr_low_set_addr):
5401 Changed signature. Made static.
5402 (i386_dr_low_get_addr): Likewise.
5403 (i386_dr_low_set_control): Likewise.
5404 (i386_dr_low_get_control): Likewise.
5405 (i386_dr_low_get_status): Likewise.
5406 (i386_dr_low): New global variable.
5407
e1d2394b
MS
54082014-06-20 Marcus Shawcroft <marcus.shawcroft@arm.com>
5409
5410 * configure.ac: Invoke. AC_CHECK_TOOL(AR, ar).
5411 * Makefile.in (AR, AR_FLAGS): Define.
5412 * configure: Regenerate.
5413
3a8ee006
GB
54142014-06-19 Gary Benson <gbenson@redhat.com>
5415
5416 * Makefile.in (i386-dregs.o): New rule.
5417 * configure.srv: Add i386-dregs.o to all targets using i386-low.o.
5418 * i386-low.c (target.h): Remove include.
5419 (TARGET_HAS_DR_LEN_8): Now in i386-dregs.c.
5420 (DR_CONTROL_SHIFT): Likewise.
5421 (DR_CONTROL_SIZE): Likewise.
5422 (DR_RW_EXECUTE): Likewise.
5423 (DR_RW_WRITE): Likewise.
5424 (DR_RW_READ): Likewise.
5425 (DR_RW_IORW): Likewise.
5426 (DR_LEN_1): Likewise.
5427 (DR_LEN_2): Likewise.
5428 (DR_LEN_4): Likewise.
5429 (DR_LEN_8): Likewise.
5430 (DR_LOCAL_ENABLE_SHIFT): Likewise.
5431 (DR_GLOBAL_ENABLE_SHIFT): Likewise.
5432 (DR_ENABLE_SIZE): Likewise.
5433 (DR_LOCAL_SLOWDOWN): Likewise.
5434 (DR_GLOBAL_SLOWDOWN): Likewise.
5435 (DR_CONTROL_RESERVED): Likewise.
5436 (I386_DR_CONTROL_MASK): Likewise.
5437 (I386_DR_VACANT): Likewise.
5438 (I386_DR_LOCAL_ENABLE): Likewise.
5439 (I386_DR_GLOBAL_ENABLE): Likewise.
5440 (I386_DR_DISABLE): Likewise.
5441 (I386_DR_SET_RW_LEN): Likewise.
5442 (I386_DR_GET_RW_LEN): Likewise.
5443 (I386_DR_WATCH_HIT): Likewise.
5444 (i386_wp_op_t): Likewise.
5445 (i386_show_dr): Likewise.
5446 (i386_length_and_rw_bits): Likewise.
5447 (i386_insert_aligned_watchpoint): Likewise.
5448 (i386_remove_aligned_watchpoint): Likewise.
5449 (i386_handle_nonaligned_watchpoint): Likewise.
5450 i386_update_inferior_debug_regs(): Likewise.
5451 (i386_dr_insert_watchpoint): Likewise.
5452 (i386_dr_remove_watchpoint): Likewise.
5453 (i386_dr_region_ok_for_watchpoint): Likewise.
5454 (i386_dr_stopped_data_address): Likewise.
5455 (i386_dr_stopped_by_watchpoint): Likewise.
5456
8f26655c
GB
54572014-06-19 Gary Benson <gbenson@redhat.com>
5458
5459 * i386-low.c (i386_dr_show): Renamed to
5460 i386_show_dr and made static. All uses updated.
5461 (i386_dr_length_and_rw_bits): Renamed to
5462 i386_length_and_rw_bits and made static.
5463 All uses updated.
5464 (i386_dr_insert_aligned_watchpoint): Renamed to
5465 i386_insert_aligned_watchpoint and made static.
5466 All uses updated.
5467 (i386_dr_remove_aligned_watchpoint): Renamed to
5468 i386_remove_aligned_watchpoint and made static.
5469 All uses updated.
5470 (i386_dr_update_inferior_debug_regs): Renamed to
5471 i386_update_inferior_debug_regs and made static.
5472 All uses updated.
5473
b9228891
GB
54742014-06-18 Gary Benson <gbenson@redhat.com>
5475
5171def3
GB
5476 * i386-low.h (i386_dr_low_can_set_addr): New macro.
5477 (i386_dr_low_can_set_control): Likewise.
5478 (i386_get_debug_register_length): Likewise.
5479 * i386-low.c (i386_dr_low_can_set_addr): Now in i386-low.h.
5480 (i386_dr_low_can_set_control): Likewise.
5481 (i386_get_debug_register_length): Likewise.
5482
54832014-06-17 Gary Benson <gbenson@redhat.com>
5484
b9228891
GB
5485 * i386-low.h (i386-dregs.h): New include.
5486 (DR_FIRSTADDR): Now in i386-dregs.h.
5487 (DR_LASTADDR): Likewise.
5488 (DR_NADDR): Likewise.
5489 (DR_STATUS): Likewise.
5490 (DR_CONTROL): Likewise.
5491 (i386_debug_reg_state): Likewise.
5492 (i386_dr_insert_watchpoint): Likewise.
5493 (i386_dr_remove_watchpoint): Likewise.
5494 (i386_dr_region_ok_for_watchpoint): Likewise.
5495 (i386_dr_stopped_data_address): Likewise.
5496 (i386_dr_stopped_by_watchpoint): Likewise.
5497 * i386-low.c (ALL_DEBUG_REGISTERS): Likewise.
5498
4be83cc2
GB
54992014-06-18 Gary Benson <gbenson@redhat.com>
5500
5501 * i386-low.h (i386_low_insert_watchpoint): Renamed to
5502 i386_dr_insert_watchpoint.
5503 (i386_low_remove_watchpoint): Renamed to
5504 i386_dr_remove_watchpoint.
5505 (i386_low_region_ok_for_watchpoint): Renamed to
5506 i386_dr_region_ok_for_watchpoint.
5507 (i386_low_stopped_data_address): Renamed to
5508 i386_dr_stopped_data_address.
5509 (i386_low_stopped_by_watchpoint): Renamed to
5510 i386_dr_stopped_by_watchpoint.
5511 * i386-low.c (i386_show_dr): Renamed to
5512 i386_dr_show and made nonstatic. All uses updated.
5513 (i386_length_and_rw_bits): Renamed to
5514 i386_dr_length_and_rw_bits and made nonstatic.
5515 All uses updated.
5516 (i386_insert_aligned_watchpoint): Renamed to
5517 i386_dr_insert_aligned_watchpoint and made nonstatic.
5518 All uses updated.
5519 (i386_remove_aligned_watchpoint): Renamed to
5520 i386_dr_remove_aligned_watchpoint and made nonstatic.
5521 All uses updated.
5522 (i386_update_inferior_debug_regs): Renamed to
5523 i386_dr_update_inferior_debug_regs and made nonstatic.
5524 All uses updated.
5525 (i386_low_insert_watchpoint): Renamed to
5526 i386_dr_insert_watchpoint. All uses updated.
5527 (i386_low_remove_watchpoint): Renamed to
5528 i386_dr_remove_watchpoint. All uses updated.
5529 (i386_low_region_ok_for_watchpoint): Renamed to
5530 i386_dr_region_ok_for_watchpoint. All uses updated.
5531 (i386_low_stopped_data_address): Renamed to
5532 i386_dr_stopped_data_address. All uses updated.
5533 (i386_low_stopped_by_watchpoint): Renamed to
5534 i386_dr_stopped_by_watchpoint. All uses updated.
5535
131aa0d4
GB
55362014-06-18 Gary Benson <gbenson@redhat.com>
5537
5538 * i386-low.c (i386_dr_low_can_set_addr): New macro.
5539 (i386_dr_low_can_set_control): Likewise.
5540 (i386_insert_aligned_watchpoint): New check.
5541
d9305f7f
GB
55422014-06-18 Gary Benson <gbenson@redhat.com>
5543
5544 * i386-low.c (i386_update_inferior_debug_regs) <inf_state>:
5545 Renamed to state.
5546
e927c9fc
GB
55472014-06-18 Gary Benson <gbenson@redhat.com>
5548
5549 * i386-low.c (i386_length_and_rw_bits): Use internal_error
5550 instead of fatal and error.
5551 (i386_handle_nonaligned_watchpoint): Likewise.
5552
1b6d4134
GB
55532014-06-18 Gary Benson <gbenson@redhat.com>
5554
5555 * i386-low.c (i386_get_debug_register_length): New macro.
5556 (TARGET_HAS_DR_LEN_8): Remove conditional. Use above macro.
5557 (i386_show_dr): Use debug_printf instead of fprintf. Use
5558 phex to format values.
5559
6e62758f
GB
55602014-06-18 Gary Benson <gbenson@redhat.com>
5561
5562 * i386-low.h: Comment changes.
5563 * i386-low.c: Likewise.
5564
fc6e2f03
GB
55652014-06-18 Gary Benson <gbenson@redhat.com>
5566
5567 * i386-low.c: Whitespace changes.
5568
f9d1eeed
TT
55692014-06-12 Tom Tromey <tromey@redhat.com>
5570
5571 * utils.c (freeargv): Remove.
5572
0b04e523
TT
55732014-06-12 Tom Tromey <tromey@redhat.com>
5574
5575 * debug.c (debug_printf): Remove HAVE_GETTIMEOFDAY checks.
5576 * server.c (monitor_show_help): Remove HAVE_GETTIMEOFDAY check.
5577 (parse_debug_format_options): Likewise.
5578 (gdbserver_usage): Likewise.
5579 * Makefile.in (LIBIBERTY_BUILDDIR, LIBIBERTY): New variables.
5580 (SUBDIRS, REQUIRED_SUBDIRS): Add libiberty.
5581 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Depend on and link
5582 against libiberty.
5583 ($(LIBGNU)): Depend on libiberty.
5584 (all-lib): Recurse into all subdirs.
5585 (install-only): Invoke "install" target in subdirs.
5586 (vasprintf.o, vsnprintf.o, safe-ctype.o, lbasename.o): Remove
5587 targets.
5588 * configure: Rebuild.
5589 * configure.ac: Add ACX_CONFIGURE_DIR for libiberty. Don't check
5590 for vasprintf, vsnprintf, or gettimeofday.
5591 * configure.srv: Don't add safe-ctype.o or lbasename.o to
5592 srv_tgtobj.
5593
270c9937
JB
55942014-06-05 Joel Brobecker <brobecker@adacore.com>
5595
5596 * development.sh: Delete.
5597 * Makefile.in (config.status): Adjust dependency on development.sh.
5598 * configure.ac: Adjust development.sh source call.
5599 * configure: Regenerate.
5600
0a261ed8
PA
56012014-06-02 Pedro Alves <palves@redhat.com>
5602
5603 * ax.c (gdb_free_agent_expr): New function.
5604 * ax.h (gdb_free_agent_expr): New declaration.
5605 * mem-break.c (delete_gdb_breakpoint_1): Also clear the commands
5606 list.
5607 (clear_breakpoint_conditions, clear_breakpoint_commands): Make
5608 static.
5609 (clear_breakpoint_conditions_and_commands): New function.
5610 * mem-break.h (clear_breakpoint_conditions): Delete declaration.
5611 (clear_breakpoint_conditions_and_commands): New declaration.
5612
e9dae05e
RR
56132014-05-23 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
5614
5615 * linux-aarch64-low.c (asm/ptrace.h): Include.
5616
5876f503
JK
56172014-05-21 Jan Kratochvil <jan.kratochvil@redhat.com>
5618
5619 Fix TLS access for -static -pthread.
5620 * gdbserver/thread-db.c (struct thread_db): Add td_thr_tlsbase_p.
5621 (thread_db_get_tls_address): Call it if LOAD_MODULE is zero.
5622 (thread_db_load_search, try_thread_db_load_1): Initialize it.
5623
802e8e6d
PA
56242014-05-20 Pedro Alves <palves@redhat.com>
5625
5626 * linux-aarch64-low.c (aarch64_insert_point)
5627 (aarch64_remove_point): No longer check whether the type is
5628 supported here. Adjust to new interface.
5629 (the_low_target): Install aarch64_supports_z_point_type as
5630 supports_z_point_type method.
5631 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type): New function.
5632 (arm_linux_hw_point_initialize): Take an enum raw_bkpt_type
5633 instead of a Z packet char. Adjust.
5634 (arm_supports_z_point_type): New function.
5635 (arm_insert_point, arm_remove_point): Adjust to new interface.
5636 (the_low_target): Install arm_supports_z_point_type.
5637 * linux-crisv32-low.c (cris_supports_z_point_type): New function.
5638 (cris_insert_point, cris_remove_point): Adjust to new interface.
5639 Don't check whether the type is supported here.
5640 (the_low_target): Install cris_supports_z_point_type.
5641 * linux-low.c (linux_supports_z_point_type): New function.
5642 (linux_insert_point, linux_remove_point): Adjust to new interface.
5643 * linux-low.h (struct linux_target_ops) <insert_point,
5644 remove_point>: Take an enum raw_bkpt_type instead of a char. Add
5645 raw_breakpoint pointer parameter.
5646 <supports_z_point_type>: New method.
5647 * linux-mips-low.c (mips_supports_z_point_type): New function.
5648 (mips_insert_point, mips_remove_point): Adjust to new interface.
5649 Use mips_supports_z_point_type.
5650 (the_low_target): Install mips_supports_z_point_type.
5651 * linux-ppc-low.c (the_low_target): Install NULL as
5652 supports_z_point_type method.
5653 * linux-s390-low.c (the_low_target): Install NULL as
5654 supports_z_point_type method.
5655 * linux-sparc-low.c (the_low_target): Install NULL as
5656 supports_z_point_type method.
5657 * linux-x86-low.c (x86_supports_z_point_type): New function.
5658 (x86_insert_point): Adjust to new insert_point interface. Use
5659 insert_memory_breakpoint. Adjust to new
5660 i386_low_insert_watchpoint interface.
5661 (x86_remove_point): Adjust to remove_point interface. Use
5662 remove_memory_breakpoint. Adjust to new
5663 i386_low_remove_watchpoint interface.
5664 (the_low_target): Install x86_supports_z_point_type.
5665 * lynx-low.c (lynx_target_ops): Install NULL as
5666 supports_z_point_type callback.
5667 * nto-low.c (nto_supports_z_point_type): New.
5668 (nto_insert_point, nto_remove_point): Adjust to new interface.
5669 (nto_target_ops): Install nto_supports_z_point_type.
5670 * mem-break.c: Adjust intro comment.
5671 (struct raw_breakpoint) <raw_type, size>: New fields.
5672 <inserted>: Update comment.
5673 <shlib_disabled>: Delete field.
5674 (enum bkpt_type) <gdb_breakpoint>: Delete value.
5675 <gdb_breakpoint_Z0, gdb_breakpoint_Z1, gdb_breakpoint_Z2,
5676 gdb_breakpoint_Z3, gdb_breakpoint_Z4>: New values.
5677 (raw_bkpt_type_to_target_hw_bp_type): New function.
5678 (find_enabled_raw_code_breakpoint_at): New function.
5679 (find_raw_breakpoint_at): New type and size parameters. Use them.
5680 (insert_memory_breakpoint): New function, based off
5681 set_raw_breakpoint_at.
5682 (remove_memory_breakpoint): New function.
5683 (set_raw_breakpoint_at): Reimplement.
5684 (set_breakpoint): New, based on set_breakpoint_at.
5685 (set_breakpoint_at): Reimplement.
5686 (delete_raw_breakpoint): Go through the_target->remove_point
5687 instead of assuming memory breakpoints.
5688 (find_gdb_breakpoint_at): Delete.
5689 (Z_packet_to_bkpt_type, Z_packet_to_raw_bkpt_type): New functions.
5690 (find_gdb_breakpoint): New function.
5691 (set_gdb_breakpoint_at): Delete.
5692 (z_type_supported): New function.
5693 (set_gdb_breakpoint_1): New function, loosely based off
5694 set_gdb_breakpoint_at.
5695 (check_gdb_bp_preconditions, set_gdb_breakpoint): New functions.
5696 (delete_gdb_breakpoint_at): Delete.
5697 (delete_gdb_breakpoint_1): New function, loosely based off
5698 delete_gdb_breakpoint_at.
5699 (delete_gdb_breakpoint): New function.
5700 (clear_gdb_breakpoint_conditions): Rename to ...
5701 (clear_breakpoint_conditions): ... this. Don't handle a NULL
5702 breakpoint.
5703 (add_condition_to_breakpoint): Make static.
5704 (add_breakpoint_condition): Take a struct breakpoint pointer
5705 instead of an address. Adjust.
5706 (gdb_condition_true_at_breakpoint): Rename to ...
5707 (gdb_condition_true_at_breakpoint_z_type): ... this, and add
5708 z_type parameter.
5709 (gdb_condition_true_at_breakpoint): Reimplement.
5710 (add_breakpoint_commands): Take a struct breakpoint pointer
5711 instead of an address. Adjust.
5712 (gdb_no_commands_at_breakpoint): Rename to ...
5713 (gdb_no_commands_at_breakpoint_z_type): ... this. Add z_type
5714 parameter. Return true if no breakpoint was found. Change debug
5715 output.
5716 (gdb_no_commands_at_breakpoint): Reimplement.
5717 (run_breakpoint_commands): Rename to ...
5718 (run_breakpoint_commands_z_type): ... this. Add z_type parameter,
5719 and change return type to boolean.
5720 (run_breakpoint_commands): New function.
5721 (gdb_breakpoint_here): Also check for Z1 breakpoints.
5722 (uninsert_raw_breakpoint): Don't try to reinsert a disabled
5723 breakpoint. Go through the_target->remove_point instead of
5724 assuming memory breakpoint.
5725 (uninsert_breakpoints_at, uninsert_all_breakpoints): Uninsert
5726 software and hardware breakpoints.
5727 (reinsert_raw_breakpoint): Go through the_target->insert_point
5728 instead of assuming memory breakpoint.
5729 (reinsert_breakpoints_at, reinsert_all_breakpoints): Reinsert
5730 software and hardware breakpoints.
5731 (check_breakpoints, breakpoint_here, breakpoint_inserted_here):
5732 Check both software and hardware breakpoints.
5733 (validate_inserted_breakpoint): Assert the breakpoint is a
5734 software breakpoint. Set the inserted flag to -1 instead of
5735 setting shlib_disabled.
5736 (delete_disabled_breakpoints): Adjust.
5737 (validate_breakpoints): Only validate software breakpoints.
5738 Adjust to inserted flag change.
5739 (check_mem_read, check_mem_write): Skip breakpoint types other
5740 than software breakpoints. Adjust to inserted flag change.
5741 * mem-break.h (enum raw_bkpt_type): New enum.
5742 (raw_breakpoint, struct process_info): Forward declare.
5743 (Z_packet_to_target_hw_bp_type): Delete declaration.
5744 (raw_bkpt_type_to_target_hw_bp_type, Z_packet_to_raw_bkpt_type)
5745 (set_gdb_breakpoint, delete_gdb_breakpoint)
5746 (clear_breakpoint_conditions): New declarations.
5747 (set_gdb_breakpoint_at, clear_gdb_breakpoint_conditions): Delete.
5748 (breakpoint_inserted_here): Update comment.
5749 (add_breakpoint_condition, add_breakpoint_commands): Replace
5750 address parameter with a breakpoint pointer parameter.
5751 (gdb_breakpoint_here): Update comment.
5752 (delete_gdb_breakpoint_at): Delete.
5753 (insert_memory_breakpoint, remove_memory_breakpoint): Declare.
5754 * server.c (process_point_options): Take a struct breakpoint
5755 pointer instead of an address. Adjust.
5756 (process_serial_event) <Z/z packets>: Use set_gdb_breakpoint and
5757 delete_gdb_breakpoint.
5758 * spu-low.c (spu_target_ops): Install NULL as
5759 supports_z_point_type method.
5760 * target.h: Include mem-break.h.
5761 (struct target_ops) <prepare_to_access_memory>: Update comment.
5762 <supports_z_point_type>: New field.
5763 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
5764 instead of a char. Also take a raw breakpoint pointer.
5765 * win32-arm-low.c (the_low_target): Install NULL as
5766 supports_z_point_type.
5767 * win32-i386-low.c (i386_supports_z_point_type): New function.
5768 (i386_insert_point, i386_remove_point): Adjust to new interface.
5769 (the_low_target): Install i386_supports_z_point_type.
5770 * win32-low.c (win32_supports_z_point_type): New function.
5771 (win32_insert_point, win32_remove_point): Adjust to new interface.
5772 (win32_target_ops): Install win32_supports_z_point_type.
5773 * win32-low.h (struct win32_target_ops):
5774 <supports_z_point_type>: New method.
5775 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
5776 instead of a char. Also take a raw breakpoint pointer.
5777
932539e3
PA
57782014-05-20 Pedro Alves <palves@redhat.com>
5779
5780 * mem-break.h: Include break-common.h.
5781 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
5782 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): New defines.
5783 (Z_packet_to_target_hw_bp_type): New declaration.
5784 * mem-break.c (Z_packet_to_target_hw_bp_type): New function.
5785 * i386-low.c (Z_PACKET_HW_BP, Z_PACKET_WRITE_WP, Z_PACKET_READ_WP)
5786 (Z_PACKET_ACCESS_WP): Delete macros.
5787 (Z_packet_to_hw_type): Delete function.
5788 * i386-low.h: Don't include break-common.h here.
5789 (Z_packet_to_hw_type): Delete declaration.
5790 * linux-x86-low.c (x86_insert_point, x86_insert_point): Call
5791 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
5792 * win32-i386-low.c (i386_insert_point, i386_remove_point): Call
5793 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
5794 * linux-aarch64-low.c: Don't include break-common.h here.
5795 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
5796 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): Delete macros.
5797 (Z_packet_to_target_hw_bp_type): Delete function.
5798 * linux-mips-low.c (rsp_bp_type_to_target_hw_bp_type): Delete
5799 function.
5800 (mips_insert_point, mips_remove_point): Use
5801 Z_packet_to_target_hw_bp_type.
5802
4ff0d3d8
PA
58032014-05-20 Pedro Alves <palves@redhat.com>
5804
5805 * linux-aarch64-low.c: Include break-common.h.
5806 (enum target_point_type): Delete.
5807 (Z_packet_to_point_type): Rename to ...
5808 (Z_packet_to_target_hw_bp_type): ... this, and return a
5809 target_hw_bp_type instead.
5810 (aarch64_show_debug_reg_state): Take an enum target_hw_bp_type
5811 instead of an enum target_point_type.
5812 (aarch64_point_encode_ctrl_reg): Likewise. Compute type mask from
5813 breakpoint type.
5814 (aarch64_dr_state_insert_one_point)
5815 (aarch64_dr_state_remove_one_point, aarch64_handle_breakpoint)
5816 (aarch64_handle_aligned_watchpoint)
5817 (aarch64_handle_unaligned_watchpoint, aarch64_handle_watchpoint):
5818 Take an enum target_hw_bp_type instead of an enum
5819 target_point_type.
5820 (aarch64_supports_z_point_type): New function.
5821 (aarch64_insert_point, aarch64_remove_point): Use it. Adjust to
5822 use Z_packet_to_target_hw_bp_type.
5823
786dc519
JB
58242014-05-20 Joel Brobecker <brobecker@adacore.com>
5825
5826 * configure.ac: Only use -Werror by default when DEVELOPMENT
5827 is true.
5828 * configure: Regenerate.
5829
9e0aa64f
JK
58302014-05-19 Jan Kratochvil <jan.kratochvil@redhat.com>
5831
5832 Fix gdbserver qGetTLSAddr for x86_64 -m32.
5833 * linux-x86-low.c (X86_64_USER_REGS): New.
5834 (x86_fill_gregset): Call memset for BUF first in x86_64 -m32 case.
5835
2b577b92
YQ
58362014-04-28 Yao Qi <yao@codesourcery.com>
5837
5838 * Makefile.in (i386-avx512.c): Fix the typo of generated file
5839 name.
5840
94611da2
PA
58412014-04-25 Pedro Alves <palves@redhat.com>
5842
5843 PR server/16255
5844 * linux-low.c (linux_attach_fail_reason_string): New function.
5845 (linux_attach_lwp): Delete.
5846 (linux_attach_lwp_1): Rename to ...
5847 (linux_attach_lwp): ... this. Take a ptid instead of a pid as
5848 argument. Remove "initial" parameter. Return int instead of
5849 void. Don't error or warn here.
5850 (linux_attach): Adjust to call linux_attach_lwp. Call error on
5851 failure to attach to the tgid. Call warning when failing to
5852 attach to an lwp.
5853 * linux-low.h (linux_attach_lwp): Take a ptid instead of a pid as
5854 argument. Remove "initial" parameter. Return int instead of
5855 void. Don't error or warn here.
5856 (linux_attach_fail_reason_string): New declaration.
5857 * thread-db.c (attach_thread): Adjust to linux_attach_lwp's
5858 interface change. Use linux_attach_fail_reason_string.
5859
01f9f808
MS
58602014-04-24 Michael Sturm <michael.sturm@mintel.com>
5861 Walfred Tedeschi <walfred.tedeschi@intel.com>
5862
5863 * Makefile.in: Added rules to handle new files
5864 i386-avx512.c i386-avx512-linux.c amd64-avx512.c
5865 amd64-avx512-linux.c x32-avx512.c x32-avx512-linux.c.
5866 * configure.srv (srv_i386_regobj): Add i386-avx512.o.
5867 (srv_i386_linux_regobj): Add i386-avx512-linux.o.
5868 (srv_amd64_regobj): Add amd64-avx512.o and x32-avx512.o.
5869 (srv_amd64_linux_regobj): Add amd64-avx512-linux.o and
5870 x32-avx512-linux.o.
5871 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx512.xml.
5872 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx512.xml.
5873 (srv_amd64_xmlfiles): Add i386/amd64-avx512.xml and
5874 i386/x32-avx512.xml.
5875 (srv_i386_linux_xmlfiles): Add i386/i386-avx512-linux.xml.
5876 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx512-linux.xml and
5877 i386/x32-avx512-linux.xml.
5878 * i387-fp.c (num_avx512_k_registers): New constant for number
5879 of K registers.
5880 (num_avx512_zmmh_low_registers): New constant for number of
5881 lower ZMM registers (0-15).
5882 (num_avx512_zmmh_high_registers): New constant for number of
5883 higher ZMM registers (16-31).
5884 (num_avx512_ymmh_registers): New contant for number of higher
5885 YMM registers (ymm16-31 added by avx521 on x86_64).
5886 (num_avx512_xmm_registers): New constant for number of higher
5887 XMM registers (xmm16-31 added by AVX512 on x86_64).
5888 (struct i387_xsave): Add space for AVX512 registers.
5889 (i387_cache_to_xsave): Change raw buffer size to 64 characters.
5890 Add code to handle AVX512 registers.
5891 (i387_xsave_to_cache): Add code to handle AVX512 registers.
5892 * linux-x86-low.c (init_registers_amd64_avx512_linux): New
5893 prototypei from generated file.
5894 (tdesc_amd64_avx512_linux): Likewise.
5895 (init_registers_x32_avx512_linux): Likewise.
5896 (tdesc_x32_avx512_linux): Likewise.
5897 (init_registers_i386_avx512_linux): Likewise.
5898 (tdesc_i386_avx512_linux): Likewise.
5899 (x86_64_regmap): Add AVX512 registers.
5900 (x86_linux_read_description): Add code to handle AVX512 XSTATE
5901 mask.
5902 (initialize_low_arch): Add code to initialize AVX512 registers.
5903
51aa91f9
PA
59042014-04-23 Pedro Alves <palves@redhat.com>
5905
5906 * mem-break.c (find_gdb_breakpoint_at): Make static.
5907 * mem-break.h (find_gdb_breakpoint_at): Delete declaration.
5908
a4165e94
PA
59092014-04-23 Pedro Alves <palves@redhat.com>
5910
5911 * i386-low.c: Don't include break-common.h here.
5912 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
5913 prototype to take target_hw_bp_type as argument instead of a Z
5914 packet char.
5915 * i386-low.h: Include break-common.h here.
5916 (Z_packet_to_hw_type): Declare.
5917 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
5918 prototypes.
5919 * linux-x86-low.c (x86_insert_point): Convert the packet number to
5920 a target_hw_bp_type before calling i386_low_insert_watchpoint.
5921 (x86_remove_point): Convert the packet number to a
5922 target_hw_bp_type before calling i386_low_remove_watchpoint.
5923 * win32-i386-low.c (i386_insert_point): Convert the packet number
5924 to a target_hw_bp_type before calling i386_low_insert_watchpoint.
5925 (i386_remove_point): Convert the packet number to a
5926 target_hw_bp_type before calling i386_low_remove_watchpoint.
5927
b8acf843
PA
59282014-04-23 Pedro Alves <palves@redhat.com>
5929
5930 * utils.h (perror_with_name): Add ATTRIBUTE_NORETURN.
5931
d708bcd1
PA
59322014-04-10 Pedro Alves <palves@redhat.com>
5933
5934 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
5935 Check if the condition or command is NULL before checking if the
5936 breakpoint is known. On success, return true.
5937 * mem-break.h (add_breakpoint_condition): Document return.
5938 (add_breakpoint_commands): Add describing comment.
5939 * server.c (skip_to_semicolon): New function.
5940 (process_point_options): Use it.
5941
2eec7d5b
PA
59422014-04-09 Pedro Alves <palves@redhat.com>
5943
5944 * linux-low.c (linux_read_loadmap): Pass current_inferior directly
5945 to lwpid_of.
5946
fa96cb38
PA
59472014-02-27 Pedro Alves <palves@redhat.com>
5948
5949 PR 12702
5950 * inferiors.h (A_I_NEXT, ALL_INFERIORS_TYPE, ALL_PROCESSES): New
5951 macros.
5952 * linux-low.c (delete_lwp, handle_extended_wait): Add debug
5953 output.
5954 (last_thread_of_process_p): Take a PID argument instead of a
5955 thread pointer.
5956 (linux_wait_for_lwp): Delete.
5957 (num_lwps, check_zombie_leaders, not_stopped_callback): New
5958 functions.
5959 (linux_low_filter_event): New function, party factored out from
5960 linux_wait_for_event.
5961 (linux_wait_for_event): Rename to ...
5962 (linux_wait_for_event_filtered): ... this. Add new filter ptid
5963 argument. Partly rewrite. Always use waitpid(-1, WNOHANG) and
5964 sigsuspend. Check for zombie leaders.
5965 (linux_wait_for_event): Reimplement as wrapper around
5966 linux_wait_for_event_filtered.
5967 (linux_wait_1): Handle TARGET_WAITKIND_NO_RESUMED. Assume that if
5968 a normal or signal exit is seen, it's the whole process exiting.
5969 (wait_for_sigstop): No longer a for_each_inferior callback.
5970 Rewrite on top of linux_wait_for_event_filtered.
5971 (stop_all_lwps): Call wait_for_sigstop directly.
5972 * server.c (resume, handle_target_event): Handle
5973 TARGET_WAITKIND_NO_RESUMED.
5974
d763de10
JB
59752014-02-26 Joel Brobecker <brobecker@adacore.com>
5976
5977 * win32-low.c (psapi_get_dll_name,
5978 * win32_CreateToolhelp32Snapshot): Delete.
5979 (win32_CreateToolhelp32Snapshot, win32_Module32First)
5980 (win32_Module32Next, load_toolhelp, toolhelp_get_dll_name):
5981 Delete.
5982 (handle_load_dll): Add function description.
5983 Remove code using psapi_get_dll_name and toolhelp_get_dll_name.
5984
850a0f76
JB
59852014-02-26 Joel Brobecker <brobecker@adacore.com>
5986
5987 * win32-low.c (win32_add_one_solib): Add 0x1000 to load_addr.
5988 Add comment.
5989 (win32_add_all_dlls): Remove 0x1000 offset applied to DLL
5990 base address when calling win32_add_one_solib.
5991 (handle_load_dll): Delete local variable load_addr.
5992 Remove 0x1000 offset applied to DLL base address when calling
5993 win32_add_one_solib.
5994 (handle_unload_dll): Add comment.
5995
f25b3fc3
JB
59962014-02-26 Joel Brobecker <brobecker@adacore.com>
5997
5998 * win32-low.c (win32_add_all_dlls): Renames
5999 win32_ensure_ntdll_loaded. Rewrite function documentation.
6000 Adjust implementation to always load all DLLs.
6001 Add 0x1000 offset to DLL base address when calling
6002 win32_add_one_solib.
6003 (child_initialization_done): New static global.
6004 (do_initial_child_stuff): Set child_initialization_done to
6005 zero during child initialization, and 1 after. Replace call
6006 to win32_ensure_ntdll_loaded by call to win32_add_all_dlls.
6007 Add comment.
6008 (match_dll_by_basename, dll_is_loaded_by_basename): Delete.
6009 (handle_unload_dll): Add function documentation.
6010 (get_child_debug_event): Ignore load and unload DLL events
6011 during child initialization.
6012
d86d4aaf
DE
60132014-02-20 Doug Evans <dje@google.com>
6014
3bc32da3 6015 Remove global all_lwps.
d86d4aaf
DE
6016 * inferiors.h (ptid_of): Move here from linux-low.h.
6017 (pid_of, lwpid_of): Ditto.
6018 * linux-aarch64-low.c (debug_reg_change_callback): Update, "entry"
6019 parameter is a struct thread_info * now.
6020 (aarch64_notify_debug_reg_change): Fetch pid from current_inferior
6021 directly. Pass &all_threads to find_inferior instead of &all_lwps.
6022 (aarch64_stopped_data_address): Fetch lwpid from current_inferior
6023 directly.
6024 (aarch64_linux_prepare_to_resume): Fetch ptid from thread.
6025 (aarch64_arch_setup): Fetch lwpid from current_inferior directly.
6026 * linux-arm-low.c (update_registers_callback): Update, "entry"
6027 parameter is a struct thread_info * now.
6028 Fetch lwpid from current_inferior directly.
6029 (arm_insert_point): Pass &all_threads to find_inferior instead of
6030 &all_lwps.
6031 (arm_remove_point): Ditto.
6032 (arm_stopped_by_watchpoint): Fetch lwp from current_inferior.
6033 (arm_prepare_to_resume): Fetch pid from thread.
6034 (arm_read_description): Fetch lwpid from current_inferior directly.
6035 * linux-low.c (all_lwps): Delete.
6036 (delete_lwp): Delete call to remove_inferior.
6037 (handle_extended_wait): Fetch lwpid from thread.
6038 (add_lwp): Don't set lwp->entry.id. Remove call to
6039 add_inferior_to_list.
6040 (linux_attach_lwp_1): Fetch pid from current_inferior directly.
6041 (linux_kill_one_lwp): Fetch ptid,lwpid from thread.
6042 (kill_one_lwp_callback): Ditto.
6043 (linux_kill): Don't dereference NULL pointer.
6044 Fetch ptid,lwpid from thread.
6045 (get_detach_signal): Fetch ptid from thread.
6046 (linux_detach_one_lwp): Fetch ptid,lwpid from thread.
6047 Simplify call to regcache_invalidate_thread.
6048 (delete_lwp_callback): Update, "entry" parameter is a
6049 struct thread_info * now. Fetch pid from thread.
6050 (linux_mourn): Pass &all_threads to find_inferior instead of &all_lwps.
6051 (status_pending_p_callback): Update, "entry" parameter is a
6052 struct thread_info * now. Fetch ptid from thread.
6053 (find_lwp_pid): Update, "entry" parameter is a
6054 struct thread_info * now.
6055 (linux_wait_for_lwp): Fetch pid from thread.
6056 (linux_fast_tracepoint_collecting): Fetch lwpid from thread.
6057 (maybe_move_out_of_jump_pad): Fetch lwpid from current_inferior.
6058 (enqueue_one_deferred_signal): Fetch lwpid from thread.
6059 (dequeue_one_deferred_signal): Ditto.
6060 (cancel_breakpoint): Fetch ptid from current_inferior.
6061 (linux_wait_for_event): Pass &all_threads to find_inferior,
6062 not &all_lwps. Fetch ptid, lwpid from thread.
6063 (count_events_callback): Update, "entry" parameter is a
6064 struct thread_info * now.
6065 (select_singlestep_lwp_callback): Ditto.
6066 (select_event_lwp_callback): Ditto.
6067 (cancel_breakpoints_callback): Ditto.
6068 (linux_cancel_breakpoints): Pass &all_threads to find_inferior,
6069 not &all_lwps.
6070 (select_event_lwp): Ditto. Fetch ptid from event_thread.
6071 (unsuspend_one_lwp): Update, "entry" parameter is a
6072 struct thread_info * now.
6073 (unsuspend_all_lwps): Pass &all_threads to find_inferior,
6074 not &all_lwps.
6075 (linux_stabilize_threads): Ditto. And for for_each_inferior.
6076 Fetch lwpid from thread, not lwp.
6077 (linux_wait_1): Fetch ptid, lwpid from current_inferior.
6078 Pass &all_threads to find_inferior, not &all_lwps.
6079 (send_sigstop): Fetch lwpid from thread, not lwp.
6080 (send_sigstop_callback): Update, "entry" parameter is a
6081 struct thread_info * now.
6082 (suspend_and_send_sigstop_callback): Ditto.
6083 (wait_for_sigstop): Ditto. Fetch ptid, lwpid from thread, lwp.
6084 (stuck_in_jump_pad_callback): Update, "entry" parameter is a
6085 struct thread_info * now.
6086 (move_out_of_jump_pad_callback): Ditto. Fetch ptid, lwpid
6087 from thread, lwp.
6088 (lwp_running): Update, "entry" parameter is a
6089 struct thread_info * now.
6090 (stop_all_lwps): Fetch ptid from thread.
6091 Pass &all_threads to find_inferior, for_each_inferior, not &all_lwps.
6092 (linux_resume_one_lwp): Fetch lwpid from thread.
6093 (linux_set_resume_request): Update, "entry" parameter is a
6094 struct thread_info * now. Fetch pid, lwpid from thread.
6095 (resume_status_pending_p): Update, "entry" parameter is a
6096 struct thread_info * now.
6097 (need_step_over_p): Ditto. Fetch lwpid from thread.
6098 (start_step_over): Fetch lwpid from thread.
6099 (linux_resume_one_thread): Update, "entry" parameter is a
6100 struct thread_info * now. Fetch lwpid from thread.
6101 (linux_resume): Pass &all_threads to find_inferior, not &all_lwps.
6102 (proceed_one_lwp): Update, "entry" parameter is a
6103 struct thread_info * now. Fetch lwpid from thread.
6104 (unsuspend_and_proceed_one_lwp): Update, "entry" parameter is a
6105 struct thread_info * now.
6106 (proceed_all_lwps): Pass &all_threads to find_inferior, not &all_lwps.
6107 (unstop_all_lwps): Ditto. Fetch lwpid from thread.
6108 (regsets_fetch_inferior_registers): Fetch lwpid from current_inferior
6109 directly.
6110 (regsets_store_inferior_registers): Ditto.
6111 (fetch_register, store_register): Ditto.
6112 (linux_read_memory, linux_write_memory): Ditto.
6113 (linux_request_interrupt): Ditto.
6114 (linux_read_auxv): Ditto.
6115 (linux_xfer_siginfo): Ditto.
6116 (linux_qxfer_spu): Ditto.
6117 (linux_qxfer_libraries_svr4): Ditto.
6118 * linux-low.h (ptid_of, pid_of, lwpid_of): Delete,
6119 moved to inferiors.h.
6120 (get_lwp): Delete.
6121 (get_thread_lwp): Update.
6122 (struct lwp_info): Delete member "entry". Simplify comment for
6123 member "thread".
6124 (all_lwps): Delete.
6125 * linux-mips-low.c (mips_read_description): Fetch lwpid from
6126 current_inferior directly.
6127 (update_watch_registers_callback): Update, "entry" parameter is a
6128 struct thread_info * now. Fetch pid from thread.
6129 (mips_linux_prepare_to_resume): Fetch ptid from thread.
6130 (mips_insert_point): Fetch lwpid from current_inferior.
6131 Pass &all_threads to find_inferior, not &all_lwps.
6132 (mips_remove_point): Pass &all_threads to find_inferior, not &all_lwps.
6133 (mips_stopped_by_watchpoint): Fetch lwpid from current_inferior
6134 directly.
6135 (mips_stopped_data_address): Ditto.
6136 * linux-s390-low.c (s390_arch_setup): Fetch pid from current_inferior
6137 directly.
6138 * linux-tile-low.c (tile_arch_setup): Ditto.
6139 * linux-x86-low.c (x86_get_thread_area): Fetch lwpid from thread.
6140 (update_debug_registers_callback): Update, "entry" parameter is a
6141 struct thread_info * now. Fetch pid from thread.
6142 (i386_dr_low_set_addr): Fetch pid from current_inferior directly.
6143 Pass &all_threads to find_inferior, not &all_lwps.
6144 (i386_dr_low_get_addr): Fetch ptid from current_inferior directly.
6145 (i386_dr_low_set_control): Fetch pid from current_inferior directly.
6146 Pass &all_threads to find_inferior, not &all_lwps.
6147 (i386_dr_low_get_control): Fetch ptid from current_inferior directly.
6148 (i386_dr_low_get_status): Ditto.
6149 (x86_linux_prepare_to_resume): Fetch ptid from thread.
6150 (x86_siginfo_fixup): Fetch lwpid from current_inferior directly.
6151 (x86_linux_read_description): Ditto.
6152 * proc-service.c (ps_getpid): Fetch pid from current_inferior directly.
6153
3b8361aa
DE
61542014-02-20 Doug Evans <dje@google.com>
6155
6156 * inferiors.c (get_first_inferior): Fix buglet.
6157
f7667f0d
DE
61582014-02-19 Doug Evans <dje@google.com>
6159
6160 * gdbthread.h (add_thread): Change result type to struct thread_info *.
6161 * inferiors.c (add_thread): Change result type to struct thread_info *.
6162 All callers updated.
6163 (add_lwp): Call add_thread here instead of in callers.
6164 All callers updated.
6165 * linux-low.h (get_lwp_thread): Rewrite.
6166 (struct lwp_info): New member "thread".
6167
b3312d80
DE
61682014-02-19 Doug Evans <dje@google.com>
6169
6170 * linux-low.c (add_lwp): Change result to struct lwp_info *.
6171 All callers updated.
6172
ecc6f45c
DE
61732014-02-19 Doug Evans <dje@google.com>
6174
6175 * inferiors.c (add_thread): Fix whitespace.
6176
649ebbca
DE
61772014-02-19 Doug Evans <dje@google.com>
6178
6179 * dll.c (clear_dlls): Replace accessing list implemention details
6180 with API function.
6181 * gdbthread.h (get_first_thread): Declare.
6182 * inferiors.c (for_each_inferior_with_data): New function.
6183 (get_first_thread): New function.
6184 (find_thread_ptid): Simplify.
6185 (get_first_inferior): New function.
6186 (clear_list): Delete.
6187 (one_inferior_p): New function.
6188 (clear_inferior_list): New function.
6189 (clear_inferiors): Update.
6190 * inferiors.h (for_each_inferior_with_data): Declare.
6191 (clear_inferior_list): Declare.
6192 (one_inferior_p): Declare.
6193 (get_first_inferior): Declare.
6194 * linux-low.c (linux_wait_for_event): Replace accessing list
6195 implemention details with API function.
6196 * server.c (target_running): Ditto.
6197 (accumulate_file_name_length): New function.
6198 (emit_dll_description): New function.
6199 (handle_qxfer_libraries): Replace accessing list implemention
6200 details with API function.
6201 (handle_qxfer_threads_worker): New function.
6202 (handle_qxfer_threads_proper): Replace accessing list implemention
6203 details with API function.
6204 (handle_query): Ditto.
6205 (visit_actioned_threads_callback_ftype): New typedef.
6206 (visit_actioned_threads_data): New struct.
6207 (visit_actioned_threads): Rewrite to be find_inferior callback.
6208 (resume): Call find_inferior.
6209 (handle_status): Replace accessing list implemention
6210 details with API function.
6211 (process_serial_event): Replace accessing list implemention details
6212 with API function.
6213 * target.c (set_desired_inferior): Replace accessing list implemention
6214 details with API function.
6215 * tracepoint.c (same_process_p): New function.
6216 (gdb_agent_about_to_close): Replace accessing list implemention
6217 details with API function.
6218 * win32-low.c (child_delete_thread): Replace accessing list
6219 implemention details with API function.
6220 (match_dll_by_basename): New function.
6221 (dll_is_loaded_by_basename): New function.
6222 (win32_ensure_ntdll_loaded): Replace accessing list implemention
6223 details call to dll_is_loaded_by_basename.
6224
80894984
DE
62252014-02-19 Doug Evans <dje@google.com>
6226
6227 * dll.h (struct dll_info): Add comment.
6228 * gdbthread.h (struct thread_info): Add comment.
6229 (current_ptid): Simplify.
6230 * inferiors.c (add_process): Update.
6231 (remove_process): Update.
6232 * inferiors.h (struct process_info): Rename member "head" to "entry".
6233 * linux-low.c (delete_lwp): Update.
6234 (add_lwp): Update.
6235 (last_thread_of_process_p): Update.
6236 (kill_one_lwp_callback, linux_kill): Update.
6237 (status_pending_p_callback): Update.
6238 (wait_for_sigstop): Update. Simplify read of ptid.
6239 (start_step_over): Update.
6240 * linux-low.h (ptid_of, pid_of, lwpid_of): Update.
6241 (get_lwp_thread): Update.
6242 (struct lwp_info): Rename member "head" to "entry".
6243 * regcache.h (inferior_list_entry): Delete.
6244 * server.c (kill_inferior_callback): Update.
6245 (detach_or_kill_inferior_callback): Update.
6246 (print_started_pid): Update.
6247 (print_attached_pid): Update.
6248 (process_serial_event): Simplify read of ptid.
6249 * thread-db.c (thread_db_create_event): Update.
6250 (thread_db_get_tls_address): Update.
6251 * win32-low.c (current_inferior_ptid): Simplify.
6252
46917d26
TT
62532014-02-19 Tom Tromey <tromey@redhat.com>
6254
6255 * target.h (struct target_ops) <supports_btrace>: Add target_ops
6256 argument.
6257 (target_supports_btrace): Update.
6258
0759a81e
YQ
62592014-02-14 Yao Qi <yao@codesourcery.com>
6260
6261 * Makefile.in (IPA_OBJS): Append rsp-low-ipa.o.
6262 (rsp-low-ipa.o): New target.
6263
a7191e8b
TT
62642014-02-12 Tom Tromey <tromey@redhat.com>
6265
6266 * ax.c (gdb_parse_agent_expr): Use hex2bin, not
6267 convert_ascii_to_int.
6268 * regcache.c (registers_to_string): Likewise.
6269 * remote-utils.c (decode_M_packet): Likewise.
6270 * server.c (process_serial_event): Likewise.
6271
ff0e980e
TT
62722014-02-12 Tom Tromey <tromey@redhat.com>
6273
6274 * server.c (handle_query, handle_v_run): Use hex2bin, not
6275 unhexify.
6276 * tracepoint.c (cmd_qtdpsrc, cmd_qtdv, cmd_qtnotes): Likewise.
6277
e9371aff
TT
62782014-02-12 Tom Tromey <tromey@redhat.com>
6279
6280 * ax.c (gdb_unparse_agent_expr): Use bin2hex, not
6281 convert_int_to_ascii.
6282 * regcache.c (registers_to_string, collect_register_as_string):
6283 Likewise.
6284 * remote-utils.c (look_up_one_symbol, relocate_instruction):
6285 Likewise.
6286 * server.c (process_serial_event): Likewise.
6287 * tracepoint.c (cmd_qtstatus, response_source, response_tsv)
6288 (cmd_qtbuffer, cstr_to_hexstr): Likewise.
6289
971dc0b8
TT
62902014-02-12 Tom Tromey <tromey@redhat.com>
6291
6292 * remote-utils.c (look_up_one_symbol, monitor_output): Use
6293 bin2hex, not hexify.
6294 * tracepoint.c (cmd_qtstatus): Likewise.
6295
0a822afb
TT
62962014-02-12 Tom Tromey <tromey@redhat.com>
6297
6298 * remote-utils.c (monitor_output): Pass explicit length to
6299 hexify.
6300
9c3d6531
TT
63012014-02-12 Tom Tromey <tromey@redhat.com>
6302
6303 * tracepoint.c: Include rsp-low.h.
6304 * server.c: Include rsp-low.h.
6305 * remote-utils.h (convert_ascii_to_int, convert_int_to_ascii)
6306 (unhexify, hexify, remote_escape_output, unpack_varlen_hex): Don't
6307 declare.
6308 * remote-utils.c: Include rsp-low.h.
6309 (fromhex, hexchars, ishex, unhexify, tohex, hexify)
6310 (remote_escape_output, remote_unescape_input, unpack_varlen_hex)
6311 (convert_int_to_ascii, convert_ascii_to_int): Move to
6312 common/rsp-low.c.
6313 * regcache.c: Include rsp-low.h.
6314 * ax.c: Include rsp-low.h.
6315 * Makefile.in (SFILES): Add common/rsp-low.c.
6316 (OBS): Add rsp-low.o.
6317 (rsp-low.o): New target.
6318
01fd3ea5
TT
63192014-02-12 Tom Tromey <tromey@redhat.com>
6320
6321 * utils.h (pulongest, plongest, phex_nz): Don't declare.
6322 Include print-utils.h.
6323 * utils.c (NUMCELLS, CELLSIZE, get_cell, decimal2str, pulongest)
6324 (plongest, thirty_two, phex_nz): Remove.
6325 * Makefile.in (SFILES): Add common/print-utils.c.
6326 (OBS): Add print-utils.o.
6327 (print-utils-ipa.o): New target.
6328 (print-utils.o): New target.
6329 (IPA_OBJS): Add print-utils-ipa.o.
6330
e99dc820
TT
63312014-02-06 Tom Tromey <tromey@redhat.com>
6332
6333 * Makefile.in (SFILES): Fix indentation.
6334
ee1e2d4f
DE
63352014-02-05 Doug Evans <dje@google.com>
6336
6337 * linux-low.c (linux_wait_for_event): Improve comment.
6338 (linux_wait_1): Keep current_inferior in sync with event_child.
6339
f5a02773
DE
63402014-01-22 Doug Evans <dje@google.com>
6341
6342 * gdbthread.h (gdb_id_to_thread): Delete, unused.
6343
87ce2a04
DE
63442014-01-22 Doug Evans <dje@google.com>
6345
6346 * configure.ac (AC_CHECK_FUNCS): Add test for gettimeofday.
6347 * configure: Regenerate.
6348 * config.in: Regenerate.
6349 * Makefile.in (SFILES): Add debug.c.
6350 (OBS): Add debug.o.
6351 * debug.c: New file.
6352 * debug.h: New file.
6353 * linux-aarch64-low.c (*): Update all debugging printfs to use
6354 debug_printf instead of fprintf.
6355 * linux-arm-low.c (*): Ditto.
6356 * linux-cris-low.c (*): Ditto.
6357 * linux-crisv32-low.c (*): Ditto.
6358 * linux-m32r-low.c (*): Ditto.
6359 * linux-sparc-low.c (*): Ditto.
6360 * linux-x86.c (*): Ditto.
6361 * linux-low.c (*): Ditto.
6362 (linux_wait_1): Add calls to debug_enter, debug_exit.
6363 (linux_wait): Remove redundant debugging printf.
6364 (stop_all_lwps): Add calls to debug_enter, debug_exit.
6365 (linux_resume, unstop_all_lwps): Ditto.
6366 * mem-break.c (*): Update all debugging printfs to use
6367 debug_printf instead of fprintf.
6368 * remote-utils.c (*): Ditto.
6369 * thread-db.c (*): Ditto.
6370 * server.c #include <ctype.h>, "gdb_vecs.h".
6371 (debug_threads): Moved to debug.c.
6372 (*): Update all debugging printfs to use debug_printf instead of
6373 fprintf.
6374 (start_inferior): Replace call to fflush with call to debug_flush.
6375 (monitor_show_help): Mention set debug-format.
6376 (parse_debug_format_options): New function.
6377 (handle_monitor_command): Handle "monitor set debug-format".
6378 (gdbserver_usage): Mention --debug-format.
6379 (main): Parse --debug-format.
6380 * server.h (debug_threads): Declaration moved to debug.h.
6381 #include "debug.h".
6382 * tracepoint.c (trace_debug_1) [!IN_PROCESS_AGENT]: Add version of
6383 trace_debug_1 that uses debug_printf.
6384 (tracepoint_look_up_symbols): Update all debugging printfs to use
6385 debug_printf instead of fprintf.
6386
e671835b
BS
63872014-01-20 Baruch Siach <baruch@tkos.co.il>
6388
6389 * linux-xtensa-low.c: Include asm/ptrace.h instead of
6390 sys/ptrace.h.
6391
b5737fa9
PA
63922014-01-17 Pedro Alves <palves@redhat.com>
6393
ea38d2a9 6394 PR build/16445
c7faa97a
PA
6395 * linux-x86-low.c: Don't include elf/common.h if ELFMAG0 is
6396 defined after including gdb_proc_service.h.
b5737fa9 6397
40ed484e
DE
63982014-01-16 Doug Evans <dje@google.com>
6399
6400 * dll.c (UNSPECIFIED_CORE_ADDR): New macro.
6401 (match_dll): Use it.
6402
969c39fb
MM
64032014-01-16 Markus Metzger <markus.t.metzger@intel.com>
6404
6405 * target.h (target_ops) <read_btrace>: Change parameters and
6406 return type to allow error reporting.
6407 * server.c (handle_qxfer_btrace): Support delta reads. Pass
6408 trace reading errors on.
6409 * linux-low.c (linux_low_read_btrace): Pass trace reading
6410 errors on.
6411 (linux_low_disable_btrace): New.
6412
ab7f45ba
DE
64132014-01-15 Doug Evans <dje@google.com>
6414
6415 * inferiors.c (thread_id_to_gdb_id): Delete.
6416 * inferiors.h (thread_id_to_gdb_id): Delete.
6417
66af0f44
EZ
64182014-01-13 Eli Zaretskii <eliz@gnu.org>
6419
6420 * Makefile.in (INCLUDE_CFLAGS): Remove trailing slash from
6421 "-I$(srcdir)/../". Fixes MinGW compilation errors with old GCC
6422 versions.
6423
9939e131
PA
64242014-01-08 Pedro Alves <palves@redhat.com>
6425
6426 * server.c (handle_status): Don't discard previous queued stop
6427 replies or thread's pending status here.
6428 (main) <disconnection>: Do it here instead.
6429
b7ea362b
PA
64302014-01-08 Pedro Alves <palves@redhat.com>
6431
6432 * gdbthread.h (struct thread_info) <status_pending_p>: New field.
6433 * server.c (visit_actioned_threads, handle_pending_status): New
6434 function.
6435 (handle_v_cont): Factor out parts to ...
6436 (resume): ... this new function. If in all-stop, and a thread
6437 being resumed has a pending status, report it without actually
6438 resuming.
6439 (myresume): Adjust to use the new 'resume' function.
6440 (clear_pending_status_callback, set_pending_status_callback)
6441 (find_status_pending_thread_callback): New functions.
6442 (handle_status): Handle the case of multiple threads having
6443 interesting statuses to report. Report threads' real last signal
6444 instead of always reporting GDB_SIGNAL_TRAP. Look for a thread
6445 with an interesting thread to report the status for, instead of
6446 always reporting the status of the first thread.
6447
28498c42
JB
64482014-01-01 Joel Brobecker <brobecker@adacore.com>
6449
6450 * gdbserver.c (gdbserver_version): Set copyright year to 2014.
6451 * gdbreplay.c (gdbreplay_version): Likewise.
6452
f45c82da
YZ
64532013-12-18 Yufeng Zhang <yufeng.zhang@arm.com>
6454
6455 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Set
6456 iov.iov_len with the real length in use.
6457
379a5e2d
JB
64582013-12-13 Joel Brobecker <brobecker@adacore.com>
6459
6460 * Makefile.in (safe-ctype.o, lbasename.o): New rules.
6461 * configure.srv: Add safe-ctype.o and lbasename.o to srv_tgtobj
6462 for all targets that use win32-low.c.
6463 * win32-low.c (win32_ensure_ntdll_loaded): New function.
6464 (do_initial_child_stuff): Add call to win32_ensure_ntdll_loaded.
6465
4210d83e
PA
64662013-12-13 Pedro Alves <palves@redhat.com>
6467
6468 * target.c (mywait): Set OURSTATUS->KIND to TARGET_WAITKIND_STOPPED
6469 if equal to TARGET_WAITKIND_LOADED.
6470 * win32-low.c (cached_status): New static global.
6471 (win32_wait): Add declaration.
6472 (do_initial_child_stuff): Flush all initial pending debug events
6473 up to the initial breakpoint.
6474 (win32_wait): If CACHED_STATUS was set, return that instead
6475 of doing a real wait. Remove the code resuming the execution
6476 of the inferior after receiving a TARGET_WAITKIND_LOADED event
6477 during the initial phase. Also remove the code changing
6478 OURSTATUS->KIND from TARGET_WAITKIND_LOADED to
6479 TARGET_WAITKIND_STOPPED.
6480
e7f0d979
YQ
64812013-12-11 Yao Qi <yao@codesourcery.com>
6482
6483 * notif.c (handle_notif_ack): Return 0 if no notification
6484 matches.
6485
ebcf782c
DE
64862013-11-20 Doug Evans <dje@google.com>
6487
6488 * linux-low.c (linux_set_resume_request): Fix comment.
6489
20ad9378
DE
64902013-11-20 Doug Evans <dje@google.com>
6491
6492 * linux-low.c (resume_status_pending_p): Tweak comment.
6493
a196ebeb
WT
64942013-11-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
6495
6496 * Makefile.in: Add i386-mpx.c, i386-mpx-linux.c, amd64-mpx.c,
6497 amd64-mpx-linux.c, x32-mpx.c and x32-mpx-linux.c generation.
6498 * configure.srv (srv_i386_regobj): Add i386-mpx.o.
6499 (srv_i386_linux_regobj): Add i386-mpx-linux.o.
6500 (srv_amd64_regobj): Add amd64-mpx.o.
6501 (srv_amd64_linux_regobj): Add amd64-mpx-linux.o.
6502 (srv_i386_32bit_xmlfiles): Add i386/32bit-mpx.xml.
6503 (srv_i386_64bit_xmlfiles): Add i386/64bit-mpx.xml.
6504 * i387-fp.c (num_pl_bnd_register) Added constant.
6505 (num_pl_bnd_cfg_registers) Added constant.
6506 (struct i387_xsave) Added reserved area and MPX fields.
6507 (i387_cache_to_xsave, i387_xsave_to_cache) Add MPX.
6508 * linux-x86-low.c (init_registers_i386_mpx_linux): Declare new
6509 function.
6510 (tdesc_i386_mpx_linux): Add MPX amd64 target.
6511 (init_registers_amd64_mpx_linux): Declare new function.
6512 (tdesc_amd64_mpx_linux): Add MPX amd64 target.
6513 (x86_64_regmap): Add MPX registers.
6514 (x86_linux_read_description): Add MPX case.
6515 (initialize_low_arch): Initialize MPX targets.
6516
0080a2f6
TT
65172013-11-18 Tom Tromey <tromey@redhat.com>
6518
6519 * configure: Rebuild.
6520 * configure.ac: Don't check for stdlib.h.
6521 * gdbreplay.c: Unconditionally include stdlib.h.
6522
2978b111
TT
65232013-11-18 Tom Tromey <tromey@redhat.com>
6524
6525 * config.in: Rebuild.
6526 * configure: Rebuild.
6527 * configure.ac: Don't use AC_HEADER_DIRENT.
6528
a3d08894
TT
65292013-11-18 Tom Tromey <tromey@redhat.com>
6530
6531 * server.h: Don't check HAVE_STRING_H.
6532 * gdbreplay.c: Don't check HAVE_STRING_H.
6533 * configure: Rebuild.
6534
0a5dd17d
TT
65352013-11-18 Tom Tromey <tromey@redhat.com>
6536
6537 * Makefile.in (gdbreplay$(EXEEXT)): Depend on and link against
6538 LIBGNU.
6539
1bd2f0ba
TT
65402013-11-08 Tom Tromey <tromey@redhat.com>
6541
6542 * configure, config.in: Rebuild.
6543 * configure.ac: Remove unused configury.
6544
3266f10b
TT
65452013-11-08 Tom Tromey <tromey@redhat.com>
6546
6547 * acinclude.m4: Include common.m4, codeset.m4.
6548 * configure, config.in: Rebuild.
6549 * configure.ac: Use GDB_AC_COMMON.
6550
6682d959
AA
65512013-11-06 Andreas Arnez <arnez@linux.vnet.ibm.com>
6552
6553 * linux-s390-low.c (HWCAP_S390_TE): New define.
6554 (s390_arch_setup): Consider the TE field in the HWCAP for
6555 determining 'have_regset_tdb'.
6556
fd0a4d76
SDJ
65572013-10-16 Sergio Durigan Junior <sergiodj@redhat.com>
6558
6559 PR gdb/16014
6560 * tracepoint.c (download_tracepoint_1): Remove unnecessary double
6561 call to sizeof.
6562
1a3d890b
PA
65632013-10-02 Pedro Alves <palves@redhat.com>
6564
6565 * server.c (process_serial_event): Don't output "GDBserver
6566 exiting" if GDB is connected through stdio.
6567 * target.c (mywait): Likewise, be silent if GDB is connected
6568 through stdio.
6569
97ad4581
JB
65702013-10-01 Joel Brobecker <brobecker@adacore.com>
6571
6572 * lynx-low.c (lynx_add_threads_after_attach): New function.
6573 (lynx_attach): Remove call to add_thread. Add call to
6574 lynx_add_threads_after_attach instead.
6575
5b4e221c
MF
65762013-09-28 Mike Frysinger <vapier@gentoo.org>
6577
6578 * configure.ac (AC_CHECK_HEADERS): Add sys/syscall.h
6579 * config.in, configure: Regenerated.
6580
ee47b2f8
YQ
65812013-09-18 Yao Qi <yao@codesourcery.com>
6582
6583 PR server/15959
6584 * server.c (start_inferior): Clear 'resume_info'.
6585
d6707650 65862013-09-16 Jiong Wang <jiwang@tilera.com>
0f63d4db 6587
d6707650
JW
6588 * linux-tile-low.c (tile_regsets): Modify the size field to 64-bit
6589 for each register.
6590
9243dd0e 65912013-09-16 Jiong Wang <jiwang@tilera.com>
0f63d4db 6592
9243dd0e
JW
6593 * configure.srv <tilegx*-*-linux*>: Remove linux-osdata.o from and add
6594 linux-tile-low.o to srv_tgtobj.
6595
c623a6ef
WN
65962013-09-16 Will Newton <will.newton@linaro.org>
6597
6598 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Zero
6599 out regs.
6600
fb71d39e
PA
66012013-09-06 Pedro Alves <palves@redhat.com>
6602
6603 * Makefile.in (gdb_proc_service_h, regdef_h, regcache_h)
6604 (signals_def, signals_h, ptid_h, ax_h, agent_h, linux_btrace_h)
6605 (linux_osdata_h, vec_h, gdb_vecs_h, host_defs_h, libiberty_h)
6606 (server_h, gdbthread_h, linux_low_h, linux_ptrace_h)
6607 (gdb_thread_db_h, linux_procfs_h, lynx_low_h, nto_low_h)
6608 (mips_linux_watch_h, i386_low_h, win32_low_h): Delete.
6609
8e7e9910
PA
66102013-09-06 Pedro Alves <palves@redhat.com>
6611
6612 * Makefile.in (linux-btrace.o, mips-linux-watch.o): Remove
6613 explicit header dependencies and use $COMPILE/$POSTCOMPILE.
6614
7c3a12ca
PA
66152013-09-06 Pedro Alves <palves@redhat.com>
6616
6617 * linux-amd64-ipa.c: Include tracepoint.h.
6618 * linux-i386-ipa.c: Include tracepoint.h.
6619
8eb3d7b6
RW
66202013-09-06 Ricard Wanderlof <ricardw@axis.com>
6621
6622 * linux-crisv32-low.c (PTRACE_GET_THREAD_AREA): New macro.
6623 (ps_get_thread_area): New function.
6624
eddddb9d
RW
66252013-09-06 Ricard Wanderlof <ricardw@axis.com>
6626
6627 * linux-crisv32-low.c (elf_gregset_t): Delete typedef.
6628 (initialize_low_arch): Call init_registers_crisv32 rather than
6629 init_register_crisv32.
6630
533b0600
PA
66312013-09-05 Pedro Alves <palves@redhat.com>
6632
6633 * server.h (handle_vFile, hostio_last_error_from_errno): Move
6634 to ...
6635 * hostio.h: ... this new file.
6636 * hostio.c, server.c, linux-low.c, nto-low.c, spu-low,
6637 win32-low.c: Include hostio.h.
6638
0ce3d3b5
PA
66392013-09-05 Pedro Alves <palves@redhat.com>
6640
6641 * server.h (gdb_client_data, handler_func, callback_handler_func)
6642 (delete_file_handler, add_file_handler, append_callback_event)
6643 (delete_callback_event, start_event_loop, initialize_event_loop):
6644 Move to event-loop.h and include it.
6645 * event-loop.h: New file.
6646
799cdc37
PA
66472013-09-05 Pedro Alves <palves@redhat.com>
6648
6649 * dll.c, inferiors.c, remote-utils.c, server.c: Include "dll.h".
6650 * server.h (struct dll_info, all_dlls, dlls_changed, clear_dlls)
6651 (loaded_dll, unloaded_dll): Move to ...
6652 * dll.h: ... this new file.
6653 * inferiors.c, remote-utils.c, win32-low.c: Include "dll.h".
6654
6a6bbd9d
PA
66552013-09-05 Pedro Alves <palves@redhat.com>
6656
6657 * server.h (current_process, get_thread_process, all_processes)
6658 (add_inferior_to_list, for_each_inferior, current_inferior)
6659 (remove_inferior, add_process, remove_process, find_process_pid)
6660 (have_started_inferiors_p, have_attached_inferiors_p)
6661 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id)
6662 (clear_inferiors, find_inferior, find_inferior_id)
6663 (inferior_target_data, set_inferior_target_data)
6664 (inferior_regcache_data, set_inferior_regcache_data): Move to
6665 inferiors.h, and include it.
6666 * inferiors.h: New file.
6667
f699aaba
PA
66682013-09-05 Pedro Alves <palves@redhat.com>
6669
6670 * server.h (struct emit_ops, current_insn_ptr, emit_error):
6671 Move ...
72f4393d 6672 * ax.h: ... here.
f699aaba 6673
c144c7a0
PA
66742013-09-05 Pedro Alves <palves@redhat.com>
6675
6676 * ax.c, linux-low.c, linux-x86-low.c, server.c: Include
6677 tracepoint.h.
6678 * server.h (IPA_BUFSIZ, initialize_tracepoint, tracing)
6679 (disconnected_tracing, tracepoint_look_up_symbols, stop_tracing
6680 (handle_tracepoint_general_set, handle_tracepoint_query)
6681 (tracepoint_finished_step, tracepoint_was_hit)
6682 (release_while_stepping_state_list, current_traceframe)
6683 (in_readonly_region, traceframe_read_mem)
6684 (fetch_traceframe_registers, traceframe_read_sdata)
6685 (traceframe_read_info, struct fast_tpoint_collect_status)
6686 (fast_tracepoint_collecting, force_unlock_trace_buffer)
6687 (handle_tracepoit_bkpts, initialize_low_tracepoint)
6688 (supply_fast_tracepoint_registers)
6689 (supply_static_tracepoint_registers, set_trampoline_buffer_space)
6690 (ipa_tdesc, claim_trampoline_space)
6691 (have_fast_tracepoint_trampoline_buffer, gdb_agent_about_to_close)
6692 (agent_mem_read, agent_get_trace_state_variable_value)
6693 (agent_set_trace_state_variable_value, agent_tsv_read)
6694 (agent_mem_read_string, get_raw_reg_func_addr)
6695 (get_get_tsv_func_addr, get_set_tsv_func_addr): Move to ...
6696 * tracepoint.h: ... this new file.
6697
ff42e6ab
PA
66982013-09-05 Pedro Alves <palves@redhat.com>
6699
6700 * server.h (perror_with_name, error, fatal, warning, paddress)
6701 (pulongest, plongest, phex_nz, pfildes): Move to utils.h, and
6702 include it.
6703 * utils.h: New file.
6704
541af0f4
PA
67052013-09-05 Pedro Alves <palves@redhat.com>
6706
6707 * server.h (remote_debug, noack_mode, transport_is_reliable)
6708 (gdb_connected, STDIO_CONNECTION_NAME, remote_connection_is_stdio)
6709 (read_ptid, write_ptid, putpkt, putpkt_binary, putpkt_notif)
6710 (getpkt, remote_prepare, remote_open, remote_close, write_ok)
6711 (write_enn, initialize_async_io, enable_async_io)
6712 (disable_async_io, check_remote_input_interrupt_request)
6713 (convert_ascii_to_int, convert_int_to_ascii, new_thread_notify)
6714 (dead_thread_notify, prepare_resume_reply)
6715 (decode_address_to_semicolon, decode_address, decode_m_packet)
6716 (decode_M_packet, decode_X_packet, decode_xfer_write)
6717 (decode_search_memory_packet, unhexify, hexify)
6718 (remote_escape_output, unpack_varlen_hex, clear_symbol_cache)
6719 (look_up_one_symbol, relocate_instruction)
6720 (monitor_output): Move to remote-utils.h, and include it.
6721 * remote-utils.h: New file.
6722
eebdf26b
PA
67232013-09-05 Pedro Alves <palves@redhat.com>
6724
6725 * server.h (_): Delete.
6726
3aafd2ff
PA
67272013-09-02 Pedro Alves <palves@redhat.com>
6728
6729 * tracepoint.c (TRACEFRAME_EOB_MARKER_SIZE): New macro.
6730 (init_trace_buffer): Ensure at least TRACEFRAME_EOB_MARKER_SIZE is
6731 allocated.
6732 (trace_buffer_alloc): Use TRACEFRAME_EOB_MARKER_SIZE.
6733
cee83bcb
PM
67342013-09-02 Pierre Muller <muller@sourceware.org>
6735
6736 * win32-low.c (child_xfer_memory): Check if ReadProcessMemory
6737 or WriteProcessMemory complete successfully and handle
6738 ERROR_PARTIAL_COPY error.
6739
9a13b2fa
PA
67402013-09-02 Pedro Alves <palves@redhat.com>
6741
6742 * server.c (gdb_read_memory): Return -1 on traceframe memory read
6743 error instead of EIO.
6744
602e3198
JK
67452013-08-28 Jan Kratochvil <jan.kratochvil@redhat.com>
6746
6747 PR server/15604
6748 * linux-low.c: Include filestuff.h.
6749 (linux_create_inferior) <pid == 0>: Call close_most_fds.
6750 * lynx-low.c: Include filestuff.h.
6751 (lynx_create_inferior) <pid == 0>: Call close_most_fds.
6752 * server.c: Include filestuff.h.
6753 (main): Call notice_open_fds.
6754 * spu-low.c: Include filestuff.h.
6755 (spu_create_inferior) <pid == 0>: Call close_most_fds.
6756
96d7229d
LM
67572013-08-22 Luis Machado <lgustavo@codesourcery.com>
6758
6759 * Makefile.in: Explain why ../target and ../nat are not
6760 listed as include file search paths.
6761 (linux-waitpid.o): New object file rule.
6762 * configure.srv (srv_native_linux_obj): New variable.
6763 Replace all occurrences of linux native object files with
6764 $srv_native_linux_obj.
6765 * linux-low.c: Include nat/linux-nat.h and nat/linux-waitpid.h.
6766 (HAS_NOMMU): Move defining logic to common/linux-ptrace.c.
6767 (linux_enable_event_reporting): Remove declaration.
6768 (my_waitpid): Moved to common/linux-waitpid.c.
6769 (linux_wait_for_event): Pass ptid when calling
6770 linux_enable_event_reporting.
6771 (linux_supports_tracefork_flag): Remove.
6772 (linux_enable_event_reporting): Likewise.
6773 (linux_tracefork_grandchild): Remove.
6774 (STACK_SIZE): Moved to common/linux-ptrace.c.
6775 (linux_tracefork_child): Remove.
6776 (linux_test_for_tracefork): Remove.
6777 (linux_look_up_symbols): Call linux_supports_traceclone.
6778 (initialize_low): Remove call to linux_test_for_tracefork.
6779 * linux-low.h (PTRACE_TYPE_ARG3): Move to
6780 common/linux-ptrace.h.
6781 (PTRACE_TYPE_ARG4): Likewise.
6782 Include linux-ptrace.h.
6783
32940073
PA
67842013-08-21 Pedro Alves <palves@redhat.com>
6785
6786 * config.in: Renegerate.
6787
33b60d58 67882013-08-19 Luis Machado <lgustavo@codesourcery.com>
a261b8f5 6789
33b60d58
LM
6790 * Makefile.in (INCLUDE_CFLAGS): Include -I$(srcdir)/../.
6791 (SFILES): Remove $(srcdir)/common/target-common.c and
6792 add $(srcdir)/target/waitstatus.c.
6793 (OBS): Remove target-common.o and add waitstatus.o.
6794 (server_h): Remove $(srcdir)/../common/target-common.h and
6795 add $(srcdir)/../target/resume.h, $(srcdir)/../target/wait.h
6796 and $(srcdir)/../target/waitstatus.h.
6797 (target-common.o): Remove.
6798 (waitstatus.o): New target object file.
6799 * target.h: Do not include target-common.h and
6800 include target/resume.h, target/wait.h and
6801 target/waitstatus.h.
6802
b8e1b30e
LM
68032013-08-13 Luis Machado <lgustavo@codesourcery.com>
6804
6805 * linux-arm-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
6806 to PTRACE_TYPE_ARG3.
6807 * linux-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
6808 to PTRACE_TYPE_ARG3 and PTRACE_ARG4_TYPE to
6809 PTRACE_TYPE_ARG4.
6810 * linux-low.h (PTRACE_ARG3_TYPE): Rename to PTRACE_TYPE_ARG3.
6811 (PTRACE_ARG4_TYPE): Rename to PTRACE_TYPE_ARG4.
6812
7a60ad40
YQ
68132013-07-27 Jie Zhang <jie@codesourcery.com>
6814 Daniel Jacobowitz <dan@codesourcery.com>
6815 Yao Qi <yao@codesourcery.com>
6816
6817 * Makefile.in (SFILES): Add common/mips-linux-watch.c.
6818 (mips-linux-watch.o): New rule.
6819 (mips_linux_watch_h): New variable.
6820 * configure.srv <mips*-*-linux*>: Add mips-linux-watch.o to
6821 srv_tgtobj.
6822 * linux-mips-low.c: Include mips-linux-watch.h.
6823 (struct arch_process_info, struct arch_lwp_info): New.
6824 (update_watch_registers_callback): New function.
6825 (mips_linux_new_process, mips_linux_new_thread) New functions.
6826 (mips_linux_prepare_to_resume, mips_insert_point): New
6827 functions.
6828 (mips_remove_point, mips_stopped_by_watchpoint): New
6829 functions.
6830 (rsp_bp_type_to_target_hw_bp_type): New function.
6831 (mips_stopped_data_address): New function.
6832 (the_low_target): Add watchpoint support functions.
6833
de6f69ad
YQ
68342013-07-27 Yao Qi <yao@codesourcery.com>
6835
6836 * i386-low.c: Include break-common.h.
6837 (enum target_hw_bp_type): Remove.
6838
3360c0bf
LM
68392013-07-24 Luis Machado <lgustavo@codesourcery.com>
6840
6841 * Makefile.in (SFILES): /common/target-common.c.
6842 (OBS): Add target-common.o.
6843 (server_h): Add $(srcdir)/../common/target-common.h.
6844 (target-common.o): New target.
6845 * server.c (queue_stop_reply_callback): Free
6846 status string after use.
6847 * target.c (target_waitstatus_to_string): Remove.
6848 * target.h: Include target-common.h.
6849 (resume_kind): Likewise.
6850 (target_waitkind): Likewise.
6851 (target_waitstatus): Likewise.
6852 (TARGET_WNOHANG): Likewise.
6853
bd885420
YQ
68542013-07-04 Yao Qi <yao@codesourcery.com>
6855
6856 * Makefile.in (host_alias): Use @host_noncanonical@.
6857 (target_alias): Use @target_noncanonical@.
6858 * configure.ac: Use ACX_NONCANONICAL_TARGET and
6859 ACX_NONCANONICAL_HOST.
6860 * configure: Regenerated.
6861
6862 Revert:
6863 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
6864
6865 * configure.ac (version_host, version_target): Set and AC_SUBST them.
6866 * configure: Rebuild.
6867 * Makefile.in (version_host, version_target): Get from configure.
6868 (version.c): Use $(version_host) and $(version_target).
6869
17ef446e
PA
68702013-07-03 Pedro Alves <palves@redhat.com>
6871
6872 * Makefile.in (config.status): Depend on development.sh.
6873 * acinclude.m4: Include libmcheck.m4.
6874 * configure: Regenerate.
6875
7a9a7487
MG
68762013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
6877
6878 * win32-low.c (winapi_DebugActiveProcessStop): Move the WINAPI
6879 attribute inside the parentheses.
6880 (winapi_DebugSetProcessKillOnExit): Ditto.
6881 (winapi_DebugBreakProcess): Ditto.
6882 (winapi_GenerateConsoleCtrlEvent): Ditto.
a261b8f5 6883
49b64de6
MG
68842013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
6885
6886 * notif.h (notif_event): Add a dummy member to avoid compiler
6887 errors.
6888
d5749ee7
PA
68892013-07-01 Pedro Alves <palves@redhat.com>
6890
6891 * hostio.c (HOSTIO_PATH_MAX): Define.
6892 (require_filename, handle_open, handle_unlink, handle_readlink):
6893 Use it.
6894
d8d2a3ee
PA
68952013-07-01 Pedro Alves <palves@redhat.com>
6896
6897 * server.h: Include "pathmax.h".
6898 * linux-low.c: Don't include sys/param.h.
6899 (linux_pid_exe_is_elf_64_file): Use PATH_MAX instead of
6900 MAXPATHLEN.
6901 * win32-low.c: Don't include sys/param.h.
6902 (win32_create_inferior): Use PATH_MAX instead of MAXPATHLEN.
6903
bc7dea8d
PA
69042013-07-01 Pedro Alves <palves@redhat.com>
6905
6906 * event-loop.c: Don't check HAVE_UNISTD_H before including
6907 <unistd.h>.
6908 * gdbreplay.c: Likewise.
6909 * remote-utils.c: Likewise.
6910 * server.c: Likewise.
6911 * configure.ac: Don't check for unistd.h.
6912 * configure: Regenerate.
6913
d6c2da54
TT
69142013-06-28 Tom Tromey <tromey@redhat.com>
6915
6916 * Makefile.in (version.c): Use version.in, not
6917 common/version.in.
6918
257b6bec
MG
69192013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
6920
6921 * configure.ac (version_host, version_target): Set and AC_SUBST them.
6922 * configure: Rebuild.
6923 * Makefile.in (version_host, version_target): Get from configure.
6924 (version.c): Use $(version_host) and $(version_target).
6925
86ebe149
DK
69262013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
6927
6928 Fix trace-status to output user name without trailing colon.
6929 * tracepoint.c (cmd_qtstatus): Remove unnecessary colon from user name.
6930
f30aa5af
DK
69312013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
6932
6933 Fix trace-status to output proper start-time and stop-time.
6934 * tracepoint.c (cmd_qtstatus): Modify trace-status output to
6935 output start time and stop time in hex as gdb expects.
6936
28a93511
YQ
69372013-06-26 Pedro Alves <pedro@codesourcery.com>
6938
6939 * tracepoint.c (build_traceframe_info_xml): Output trace state
6940 variables present in the trace buffer.
6941
01208463
TT
69422013-06-24 Tom Tromey <tromey@redhat.com>
6943
6944 * Makefile.in (version.c): Use bfd/version.h, common/version.in,
6945 create-version.sh.
6946 (version.o): Remove.
6947 * gdbreplay.c: Include version.h.
6948 (version, host_name): Don't declare.
6949 * server.h: Include version.h.
6950 (version, host_name): Don't declare.
6951
760256f9
PA
69522013-06-12 Pedro Alves <palves@redhat.com>
6953
6954 * linux-x86-low.c (linux_is_elf64): Delete global.
6955 (x86_siginfo_fixup): Replace reference to `linux_is_elf64' global
6956 with local linux_pid_exe_is_elf_64_file use.
6957
030031ee
PA
69582013-06-11 Pedro Alves <palves@redhat.com>
6959
6960 * linux-low.c (regset_disabled, disable_regset): New functions.
6961 (regsets_fetch_inferior_registers)
6962 (regsets_store_inferior_registers): Use them.
6963 (initialize_regsets_info); Don't allocate the disabled_regsets
6964 array here.
6965 * linux-low.h (struct regsets_info) <disabled_regsets>: Extend
6966 comment.
6967
5da6eb0a
PA
69682013-06-11 Pedro Alves <palves@redhat.com>
6969
6970 * linux-low.c (initialize_regsets_info): Use xcalloc instead of
6971 xmalloc.
6972
7e5aaa09
PA
69732013-06-11 Pedro Alves <palves@redhat.com>
6974
6975 * linux-x86-low.c (initialize_low_arch): Call
6976 init_registers_x32_avx_linux.
6977
d878444c
JK
69782013-06-09 Jan Kratochvil <jan.kratochvil@redhat.com>
6979
6980 Fix compatibility with Android Bionic.
6981 * linux-low.c (linux_qxfer_libraries_svr4): Ignore first entry even if
6982 it is not empty.
6983
3aee8918
PA
69842013-06-07 Pedro Alves <palves@redhat.com>
6985
5f2b57b5 6986 PR server/14823
3aee8918
PA
6987 * Makefile.in (OBS): Add tdesc.o.
6988 (IPA_OBJS): Add tdesc-ipa.o.
6989 (tdesc-ipa.o): New rule.
6990 * ax.c (gdb_eval_agent_expr): Adjust register_size call to new
6991 interface.
6992 * linux-low.c (new_inferior): Delete.
6993 (disabled_regsets, num_regsets): Delete.
6994 (linux_add_process): Adjust to set the new per-process
6995 new_inferior flag.
6996 (linux_detach_one_lwp): Adjust to call regcache_invalidate_thread.
6997 (linux_wait_for_lwp): Adjust. Only call arch_setup if the event
6998 was a stop. When calling arch_setup, switch the current inferior
6999 to the thread that got an event.
7000 (linux_resume_one_lwp): Adjust to call regcache_invalidate_thread.
7001 (regsets_fetch_inferior_registers)
7002 (regsets_store_inferior_registers): New regsets_info parameter.
7003 Adjust to use it.
7004 (linux_register_in_regsets): New regs_info parameter. Adjust to
7005 use it.
7006 (register_addr, fetch_register, store_register): New usrregs_info
7007 parameter. Adjust to use it.
7008 (usr_fetch_inferior_registers, usr_store_inferior_registers): New
7009 parameter regs_info. Adjust to use it.
7010 (linux_fetch_registers): Get the current inferior's regs_info, and
7011 adjust to use it.
7012 (linux_store_registers): Ditto.
7013 [HAVE_LINUX_REGSETS] (initialize_regsets_info): New.
7014 (initialize_low): Don't initialize the target_regsets here. Call
7015 initialize_low_arch.
7016 * linux-low.h (target_regsets): Delete declaration.
7017 (struct regsets_info): New.
7018 (struct usrregs_info): New.
7019 (struct regs_info): New.
7020 (struct process_info_private) <new_inferior>: New field.
7021 (struct linux_target_ops): Delete the num_regs, regmap, and
7022 regset_bitmap fields. New field regs_info.
7023 [HAVE_LINUX_REGSETS] (initialize_regsets_info): Declare.
7024 * i387-fp.c (num_xmm_registers): Delete.
7025 (i387_cache_to_fsave, i387_fsave_to_cache): Adjust find_regno
7026 calls to new interface.
7027 (i387_cache_to_fxsave, i387_cache_to_xsave, i387_fxsave_to_cache)
7028 (i387_xsave_to_cache): Adjust find_regno calls to new interface.
7029 Infer the number of xmm registers from the regcache's target
7030 description.
7031 * i387-fp.h (num_xmm_registers): Delete.
7032 * inferiors.c (add_thread): Don't install the thread's regcache
7033 here.
7034 * proc-service.c (gregset_info): Fetch the current inferior's
7035 regs_info. Adjust to use it.
7036 * regcache.c: Include tdesc.h.
7037 (register_bytes, reg_defs, num_registers)
7038 (gdbserver_expedite_regs): Delete.
7039 (get_thread_regcache): If the thread doesn't have a regcache yet,
7040 create one, instead of aborting gdbserver.
7041 (regcache_invalidate_one): Rename to ...
7042 (regcache_invalidate_thread): ... this.
7043 (regcache_invalidate_one): New.
7044 (regcache_invalidate): Only invalidate registers of the current
7045 process.
7046 (init_register_cache): Add target_desc parameter, and use it.
7047 (new_register_cache): Ditto. Assert the target description has a
7048 non zero registers_size.
7049 (regcache_cpy): Add assertions. Adjust.
7050 (realloc_register_cache, set_register_cache): Delete.
7051 (registers_to_string, registers_from_string): Adjust.
7052 (find_register_by_name, find_regno, find_register_by_number)
7053 (register_cache_size): Add target_desc parameter, and use it.
7054 (free_register_cache_thread, free_register_cache_thread_one)
7055 (regcache_release, register_cache_size): New.
7056 (register_size): Add target_desc parameter, and use it.
7057 (register_data, supply_register, supply_register_zeroed)
7058 (supply_regblock, supply_register_by_name, collect_register)
7059 (collect_register_as_string, collect_register_by_name): Adjust.
7060 * regcache.h (struct target_desc): Forward declare.
7061 (struct regcache) <tdesc>: New field.
7062 (init_register_cache, new_register_cache): Add target_desc
7063 parameter.
7064 (regcache_invalidate_thread): Declare.
7065 (regcache_invalidate_one): Delete declaration.
7066 (regcache_release): Declare.
7067 (find_register_by_number, register_cache_size, register_size)
7068 (find_regno): Add target_desc parameter.
7069 (gdbserver_expedite_regs, gdbserver_xmltarget): Delete
7070 declarations.
7071 * remote-utils.c: Include tdesc.h.
7072 (outreg, prepare_resume_reply): Adjust.
7073 * server.c: Include tdesc.h.
7074 (gdbserver_xmltarget): Delete declaration.
7075 (get_features_xml, process_serial_event): Adjust.
7076 * server.h [IN_PROCESS_AGENT] (struct target_desc): Forward
7077 declare.
7078 (struct process_info) <tdesc>: New field.
7079 (ipa_tdesc): Declare.
7080 * tdesc.c: New file.
7081 * tdesc.h: New file.
7082 * tracepoint.c: Include tdesc.h.
7083 [IN_PROCESS_AGENT] (ipa_tdesc): Define.
7084 (get_context_regcache): Adjust to pass ipa_tdesc down.
7085 (do_action_at_tracepoint): Adjust to get the register cache size
7086 from the context regcache's description.
7087 (traceframe_walk_blocks): Adjust to get the register cache size
7088 from the current trace frame's description.
7089 (traceframe_get_pc): Adjust to get current trace frame's
7090 description and pass it down.
7091 (gdb_collect): Adjust to get the register cache size from the
7092 IPA's description.
7093 * linux-amd64-ipa.c (tdesc_amd64_linux): Declare.
7094 (gdbserver_xmltarget): Delete.
7095 (initialize_low_tracepoint): Set the ipa's target description.
7096 * linux-i386-ipa.c (tdesc_i386_linux): Declare.
7097 (initialize_low_tracepoint): Set the ipa's target description.
7098 * linux-x86-low.c: Include tdesc.h.
7099 [__x86_64__] (is_64bit_tdesc): New.
7100 (ps_get_thread_area, x86_get_thread_area): Use it.
7101 (i386_cannot_store_register): Rename to ...
7102 (x86_cannot_store_register): ... this. Use is_64bit_tdesc.
7103 (i386_cannot_fetch_register): Rename to ...
7104 (x86_cannot_fetch_register): ... this. Use is_64bit_tdesc.
7105 (x86_fill_gregset, x86_store_gregset): Adjust register_size calls
7106 to new interface.
7107 (target_regsets): Rename to ...
7108 (x86_regsets): ... this.
7109 (x86_get_pc, x86_set_pc): Adjust register_size calls to new
7110 interface.
7111 (x86_siginfo_fixup): Use is_64bit_tdesc.
7112 [__x86_64__] (tdesc_amd64_linux, tdesc_amd64_avx_linux)
7113 (tdesc_x32_avx_linux, tdesc_x32_linux)
7114 (tdesc_i386_linux, tdesc_i386_mmx_linux, tdesc_i386_avx_linux):
7115 Declare.
7116 (x86_linux_update_xmltarget): Delete.
7117 (I386_LINUX_XSAVE_XCR0_OFFSET): Define.
7118 (have_ptrace_getfpxregs, have_ptrace_getregset): New.
7119 (AMD64_LINUX_USER64_CS): New.
7120 (x86_linux_read_description): New, based on
7121 x86_linux_update_xmltarget.
7122 (same_process_callback): New.
7123 (x86_arch_setup_process_callback): New.
7124 (x86_linux_update_xmltarget): New.
7125 (x86_regsets_info): New.
7126 (amd64_linux_regs_info): New.
7127 (i386_linux_usrregs_info): New.
7128 (i386_linux_regs_info): New.
7129 (x86_linux_regs_info): New.
7130 (x86_arch_setup): Reimplement.
7131 (x86_install_fast_tracepoint_jump_pad): Use is_64bit_tdesc.
7132 (x86_emit_ops): Ditto.
7133 (the_low_target): Adjust. Install x86_linux_regs_info,
7134 x86_cannot_fetch_register, and x86_cannot_store_register.
7135 (initialize_low_arch): New.
7136 * linux-ia64-low.c (tdesc_ia64): Declare.
7137 (ia64_fetch_register): Adjust.
7138 (ia64_usrregs_info, regs_info): New globals.
7139 (ia64_regs_info): New function.
7140 (the_low_target): Adjust.
7141 (initialize_low_arch): New function.
7142 * linux-sparc-low.c (tdesc_sparc64): Declare.
7143 (sparc_fill_gregset_to_stack, sparc_store_gregset_from_stack):
7144 Adjust.
7145 (sparc_arch_setup): New function.
7146 (sparc_regsets_info, sparc_usrregs_info, regs_info): New globals.
7147 (the_low_target): Adjust.
7148 (initialize_low_arch): New function.
7149 * linux-ppc-low.c (tdesc_powerpc_32l, tdesc_powerpc_altivec32l)
7150 (tdesc_powerpc_cell32l, tdesc_powerpc_vsx32l)
7151 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_altivec32l)
7152 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_e500l)
7153 (tdesc_powerpc_64l, tdesc_powerpc_altivec64l)
7154 (tdesc_powerpc_cell64l, tdesc_powerpc_vsx64l)
7155 (tdesc_powerpc_isa205_64l, tdesc_powerpc_isa205_altivec64l)
7156 (tdesc_powerpc_isa205_vsx64l): Declare.
7157 (ppc_cannot_store_register, ppc_collect_ptrace_register)
7158 (ppc_supply_ptrace_register, parse_spufs_run, ppc_get_pc)
7159 (ppc_set_pc, ppc_get_hwcap): Adjust.
7160 (ppc_usrregs_info): Forward declare.
7161 (!__powerpc64__) ppc_regmap_adjusted: New global.
7162 (ppc_arch_setup): Adjust to the current process'es target
7163 description.
7164 (ppc_fill_vsxregset, ppc_store_vsxregset, ppc_fill_vrregset)
7165 (ppc_store_vrregset, ppc_fill_evrregset, ppc_store_evrregse)
7166 (ppc_store_evrregset): Adjust.
7167 (target_regsets): Rename to ...
7168 (ppc_regsets): ... this, and make static.
7169 (ppc_usrregs_info, ppc_regsets_info, regs_info): New globals.
7170 (ppc_regs_info): New function.
7171 (the_low_target): Adjust.
7172 (initialize_low_arch): New function.
7173 * linux-s390-low.c (tdesc_s390_linux32, tdesc_s390_linux32v1)
7174 (tdesc_s390_linux32v2, tdesc_s390_linux64, tdesc_s390_linux64v1)
7175 (tdesc_s390_linux64v2, tdesc_s390x_linux64, tdesc_s390x_linux64v1)
7176 (tdesc_s390x_linux64v2): Declare.
7177 (s390_collect_ptrace_register, s390_supply_ptrace_register)
7178 (s390_fill_gregset, s390_store_last_break): Adjust.
7179 (target_regsets): Rename to ...
7180 (s390_regsets): ... this, and make static.
7181 (s390_get_pc, s390_set_pc): Adjust.
7182 (s390_get_hwcap): New target_desc parameter, and use it.
7183 [__s390x__] (have_hwcap_s390_high_gprs): New global.
7184 (s390_arch_setup): Adjust to set the current process'es target
7185 description. Don't adjust the regmap.
7186 (s390_usrregs_info, s390_regsets_info, regs_info): New globals.
7187 [__s390x__] (s390_usrregs_info_3264, s390_regsets_info_3264)
7188 (regs_info_3264): New globals.
7189 (s390_regs_info): New function.
7190 (the_low_target): Adjust.
7191 (initialize_low_arch): New function.
7192 * linux-mips-low.c (tdesc_mips_linux, tdesc_mips_dsp_linux)
7193 (tdesc_mips64_linux, tdesc_mips64_dsp_linux): Declare.
7194 [__mips64] (init_registers_mips_linux)
7195 (init_registers_mips_dsp_linux): Delete defines.
7196 [__mips64] (tdesc_mips_linux, tdesc_mips_dsp_linux): New defines.
7197 (have_dsp): New global.
7198 (mips_read_description): New, based on mips_arch_setup.
7199 (mips_arch_setup): Reimplement.
7200 (get_usrregs_info): New function.
7201 (mips_cannot_fetch_register, mips_cannot_store_register)
7202 (mips_get_pc, mips_set_pc, mips_fill_gregset, mips_store_gregset)
7203 (mips_fill_fpregset, mips_store_fpregset): Adjust.
7204 (target_regsets): Rename to ...
7205 (mips_regsets): ... this, and make static.
7206 (mips_regsets_info, mips_dsp_usrregs_info, mips_usrregs_info)
7207 (dsp_regs_info, regs_info): New globals.
7208 (mips_regs_info): New function.
7209 (the_low_target): Adjust.
7210 (initialize_low_arch): New function.
7211 * linux-arm-low.c (tdesc_arm, tdesc_arm_with_iwmmxt)
7212 (tdesc_arm_with_vfpv2, tdesc_arm_with_vfpv3, tdesc_arm_with_neon):
7213 Declare.
7214 (arm_fill_vfpregset, arm_store_vfpregset): Adjust.
7215 (arm_read_description): New, with bits factored from
7216 arm_arch_setup.
7217 (arm_arch_setup): Reimplement.
7218 (target_regsets): Rename to ...
7219 (arm_regsets): ... this, and make static.
7220 (arm_regsets_info, arm_usrregs_info, regs_info): New globals.
7221 (arm_regs_info): New function.
7222 (the_low_target): Adjust.
7223 (initialize_low_arch): New function.
7224 * linux-m68k-low.c (tdesc_m68k): Declare.
7225 (target_regsets): Rename to ...
7226 (m68k_regsets): ... this, and make static.
7227 (m68k_regsets_info, m68k_usrregs_info, regs_info): New globals.
7228 (m68k_regs_info): New function.
7229 (m68k_arch_setup): New function.
7230 (the_low_target): Adjust.
7231 (initialize_low_arch): New function.
7232 * linux-sh-low.c (tdesc_sharch): Declare.
7233 (target_regsets): Rename to ...
7234 (sh_regsets): ... this, and make static.
7235 (sh_regsets_info, sh_usrregs_info, regs_info): New globals.
7236 (sh_regs_info, sh_arch_setup): New functions.
7237 (the_low_target): Adjust.
7238 (initialize_low_arch): New function.
7239 * linux-bfin-low.c (tdesc_bfin): Declare.
7240 (bfin_arch_setup): New function.
7241 (bfin_usrregs_info, regs_info): New globals.
7242 (bfin_regs_info): New function.
7243 (the_low_target): Adjust.
7244 (initialize_low_arch): New function.
7245 * linux-cris-low.c (tdesc_cris): Declare.
7246 (cris_arch_setup): New function.
7247 (cris_usrregs_info, regs_info): New globals.
7248 (cris_regs_info): New function.
7249 (the_low_target): Adjust.
7250 (initialize_low_arch): New function.
7251 * linux-cris-low.c (tdesc_crisv32): Declare.
7252 (cris_arch_setup): New function.
7253 (cris_regsets_info, cris_usrregs_info, regs_info): New globals.
7254 (cris_regs_info): New function.
7255 (the_low_target): Adjust.
7256 (initialize_low_arch): New function.
7257 * linux-m32r-low.c (tdesc_m32r): Declare.
7258 (m32r_arch_setup): New function.
7259 (m32r_usrregs_info, regs_info): New globals.
7260 (m32r_regs_info): Adjust.
7261 (initialize_low_arch): New function.
7262 * linux-tic6x-low.c (tdesc_tic6x_c64xp_linux)
7263 (tdesc_tic6x_c64x_linux, tdesc_tic6x_c62x_linux): Declare.
7264 (tic6x_usrregs_info): Forward declare.
7265 (tic6x_read_description): New function, based on ...
7266 (tic6x_arch_setup): ... this. Reimplement.
7267 (target_regsets): Rename to ...
7268 (tic6x_regsets): ... this, and make static.
7269 (tic6x_regsets_info, tic6x_usrregs_info, regs_info): New globals.
7270 (tic6x_regs_info): New function.
7271 (the_low_target): Adjust.
7272 (initialize_low_arch): New function.
7273 * linux-xtensa-low.c (tdesc_xtensa): Declare.
7274 (xtensa_fill_gregset, xtensa_store_gregset): Adjust.
7275 (target_regsets): Rename to ...
7276 (xtensa_regsets): ... this, and make static.
7277 (xtensa_regsets_info, xtensa_usrregs_info, regs_info): New
7278 globals.
7279 (xtensa_arch_setup, xtensa_regs_info): New functions.
7280 (the_low_target): Adjust.
7281 (initialize_low_arch): New function.
7282 * linux-nios2-low.c (tdesc_nios2_linux): Declare.
7283 (nios2_arch_setup): Set the current process'es tdesc.
7284 (target_regsets): Rename to ...
7285 (nios2_regsets): ... this.
7286 (nios2_regsets_info, nios2_usrregs_info, regs_info): New globals.
7287 (nios2_regs_info): New function.
7288 (the_low_target): Adjust.
7289 (initialize_low_arch): New function.
a261b8f5
PA
7290 * linux-aarch64-low.c (tdesc_aarch64): Declare.
7291 (aarch64_arch_setup): Set the current process'es tdesc.
7292 (target_regsets): Rename to ...
7293 (aarch64_regsets): ... this.
7294 (aarch64_regsets_info, aarch64_usrregs_info, regs_info): New globals.
7295 (aarch64_regs_info): New function.
7296 (the_low_target): Adjust.
7297 (initialize_low_arch): New function.
3aee8918
PA
7298 * linux-tile-low.c (tdesc_tilegx, tdesc_tilegx32): Declare
7299 globals.
7300 (target_regsets): Rename to ...
7301 (tile_regsets): ... this.
7302 (tile_regsets_info, tile_usrregs_info, regs_info): New globals.
7303 (tile_regs_info): New function.
7304 (tile_arch_setup): Set the current process'es tdesc.
7305 (the_low_target): Adjust.
7306 (initialize_low_arch): New function.
7307 * spu-low.c (tdesc_spu): Declare.
7308 (spu_create_inferior, spu_attach): Set the new process'es tdesc.
7309 * win32-arm-low.c (tdesc_arm): Declare.
7310 (arm_arch_setup): New function.
7311 (the_low_target): Install arm_arch_setup instead of
7312 init_registers_arm.
7313 * win32-i386-low.c (tdesc_i386, tdesc_amd64): Declare.
7314 (init_windows_x86): Rename to ...
7315 (i386_arch_setup): ... this. Set `win32_tdesc'.
7316 (the_low_target): Adjust.
7317 * win32-low.c (win32_tdesc): New global.
7318 (child_add_thread): Don't create the thread cache here.
7319 (do_initial_child_stuff): Set the new process'es tdesc.
7320 * win32-low.h (struct target_desc): Forward declare.
7321 (win32_tdesc): Declare.
7322 * lynx-i386-low.c (tdesc_i386): Declare global.
7323 (lynx_i386_arch_setup): Set `lynx_tdesc'.
7324 * lynx-low.c (lynx_tdesc): New global.
7325 (lynx_add_process): Set the new process'es tdesc.
7326 * lynx-low.h (struct target_desc): Forward declare.
7327 (lynx_tdesc): Declare global.
7328 * lynx-ppc-low.c (tdesc_powerpc_32): Declare global.
7329 (lynx_ppc_arch_setup): Set `lynx_tdesc'.
7330 * nto-low.c (nto_tdesc): New global.
7331 (do_attach): Set the new process'es tdesc.
7332 * nto-low.h (struct target_desc): Forward declare.
7333 (nto_tdesc): Declare.
7334 * nto-x86-low.c (tdesc_i386): Declare.
7335 (nto_x86_arch_setup): Set `nto_tdesc'.
7336
b1fbec62
GB
73372013-06-04 Gary Benson <gbenson@redhat.com>
7338
7339 * server.c (handle_query): Add "augmented-libraries-svr4-read+"
7340 to qSupported response when appropriate.
7341 (handle_qxfer_libraries_svr4): Allow qXfer:libraries-svr4:read
7342 with nonzero-length annex.
7343 * linux-low.c (linux_qxfer_libraries_svr4): Parse and handle
7344 arguments supplied in annex.
7345
d1ec4ce7
DE
73462013-05-31 Doug Evans <dje@google.com>
7347
ac44adcb 7348 PR server/15594
d1ec4ce7
DE
7349 * linux-x86-low.c (ps_get_thread_area): Properly extend address to
7350 64 bits in 64-cross-32 environment.
7351
9b25f2d3
PA
73522013-05-28 Pedro Alves <palves@redhat.com>
7353
7354 * Makefile.in (clean): Remove reference to aarch64-without-fpu.c.
7355 (aarch64-without-fpu.c): Delete rule.
7356 * configure.srv (aarch64*-*-linux*): Remove references to
7357 aarch64-without-fpu.o and aarch64-without-fpu.xml.
7358 * linux-aarch64-low.c (init_registers_aarch64_without_fpu): Remove
7359 declaration.
7360
6740dc9c
PA
73612013-05-24 Pedro Alves <palves@redhat.com>
7362
7363 * server.c (handle_v_cont) <vCont;r>: Use unpack_varlen_hex
7364 instead of strchr/decode_address. Error if the range isn't split
7365 with a ','. Don't assume there's be a ':' in the action.
7366
c2d6af84
PA
73672013-05-23 Yao Qi <yao@codesourcery.com>
7368 Pedro Alves <palves@redhat.com>
7369
7370 * linux-low.c (lwp_in_step_range): New function.
7371 (linux_wait_1): If the thread was range stepping and stopped
7372 outside the stepping range, report the stop to GDB. Otherwise,
7373 continue stepping. Add range stepping debug output.
7374 (linux_set_resume_request): Copy the step range from the resume
7375 request to the lwp.
7376 (linux_supports_range_stepping): New.
7377 (linux_target_ops) <supports_range_stepping>: Set to
7378 linux_supports_range_stepping.
7379 * linux-low.h (struct linux_target_ops)
7380 <supports_range_stepping>: New field.
7381 (struct lwp_info) <step_range_start, step_range_end>: New fields.
7382 * linux-x86-low.c (x86_supports_range_stepping): New.
7383 (the_low_target) <supports_range_stepping>: Set to
7384 x86_supports_range_stepping.
7385 * server.c (handle_v_cont): Handle 'r' action.
7386 (handle_v_requests): Append ";r" if the target supports range
7387 stepping.
7388 * target.h (struct thread_resume) <step_range_start,
7389 step_range_end>: New fields.
7390 (struct target_ops) <supports_range_stepping>:
7391 New field.
7392 (target_supports_range_stepping): New macro.
7393
58794e1a
JB
73942013-05-17 Joel Brobecker <brobecker@adacore.com>
7395
7396 * lynx-low.c (lynx_resume): Fix null_ptid/minus_one_ptid
7397 confusion in comment.
7398
d631c5a7
JB
73992013-05-17 Joel Brobecker <brobecker@adacore.com>
7400
7401 * lynx-low.c (struct process_info_private): New type.
7402 (lynx_add_process): New function.
7403 (lynx_create_inferior, lynx_attach): Replace calls to
7404 add_process by calls to lynx_add_process.
7405 (lynx_resume): If PTID is null, then try using
7406 current_process()->private->last_wait_event_ptid.
7407 Add comments.
7408 (lynx_clear_inferiors): Delete. The contents of that function
7409 has been inlined in lynx_mourn;
7410 (lynx_wait_1): Save the ptid in the process's private data.
7411 (lynx_mourn): Free the process' private data. Replace call
7412 to lynx_clear_inferiors by call to clear_inferiors.
7413
96f7a20f
YQ
74142013-05-17 Yao Qi <yao@codesourcery.com>
7415
7416 * i386-low.c (i386_length_and_rw_bits): Move the comment to
7417 the right place.
7418
db0dfaa0
LM
74192013-05-16 Luis Machado <lgustavo@codesourcery.com>
7420
7421 * linux-low.c: Move definition checks upwards for PT_TEXT_ADDR,
7422 PT_DATA_ADDR and PT_TEXT_END_ADDR. Update comments.
7423 (linux_read_offsets): Remove PT_TEXT_ADDR, PT_DATA_ADDR and
7424 PT_TEXT_END_ADDR guards. Update comments.
7425 (linux_target_op) <read_offsets>: Conditionally define to
7426 linux_read_offsets if the target is UCLIBC and if it defines
7427 PT_TEXT_ADDR, PT_DATA_ADDR and PT_TEXT_END_ADDR.
7428
68f5f838
SL
74292013-05-06 Sandra Loosemore <sandra@codesourcery.com>
7430 Andrew Jenner <andrew@codesourcery.com>
7431
7432 * Makefile.in (SFILES): Add linux-nios2-low.c.
7433 (clean): Add action to delete nios2-linux.c.
7434 (nios2-linux.c): New rule.
7435 * configure.srv: Add nios2*-*-linux*.
7436 * linux-nios2-low.c: New.
7437
1ebff1fd
HAQ
74382013-05-03 Hafiz Abid Qadeer <abidh@codesourcery.com>
7439
7440 * tracepoint.c (cmd_qtinit): Call 'stop_tracing'.
7441
f6150862
HZ
74422013-04-25 Hui Zhu <hui@codesourcery.com>
7443
7444 PR gdb/15186
f6150862
HZ
7445 * ax.c (ax_printf): Add fflush.
7446
614c279d
TT
74472013-04-22 Tom Tromey <tromey@redhat.com>
7448
7449 * Makefile.in (SFILES): Add filestuff.c.
7450 (OBS): Add filestuff.o.
7451 (filestuff.o): New target.
7452 * config.in, configure: Rebuild.
7453 * configure.ac: Check for fdwalk, pipe2.
7454
7d4e5717
PA
74552013-04-17 Pedro Alves <palves@redhat.com>
7456
7457 * configure.ac (USE_THREAD_DB): Delete variable.
7458 (if test "$srv_linux_thread_db" = "yes"): AC_DEFINE USE_THREAD_DB.
7459 Don't AC_SUBST USE_THREAD_DB.
7460 * Makefile.in (INTERNAL_CFLAGS): Remove @USE_THREAD_DB@.
7461 * config.in, configure: Regenerate.
7462
d5c93e41
PA
74632013-04-16 Pedro Alves <palves@redhat.com>
7464
7465 * linux-low.h (struct lwp_info) <thread_known>: Move under
7466 the USE_THREAD_DB #ifdef.
7467
04f5fe89
PA
74682013-04-16 Pedro Alves <palves@redhat.com>
7469
7470 * Makefile.in (INTERNAL_CFLAGS): Add @USE_THREAD_DB@.
7471 (linux-low.o): Delete rule.
7472 * linux-low.h: Always include "gdb_thread_db.h" instead of
7473 conditionally including thread_db.h.
7474 (struct lwp_info) <th>: Guard with #ifdef USE_THREAD_DB instead of
7475 HAVE_THREAD_DB_H.
7476
480b27bf
JK
74772013-04-07 Jan Kratochvil <jan.kratochvil@redhat.com>
7478
7479 * Makefile.in (install-only): Fix make install regression.
7480
43662968
JK
74812013-04-05 Jan Kratochvil <jan.kratochvil@redhat.com>
7482
7483 Convert man pages to texinfo, new gdbinit.5 texinfo page.
7484 * Makefile.in (install-only): Remove $(man1dir) and gdbserver.1
7485 installation.
7486 * gdbserver.1: Remove.
7487
3e74e146
PA
74882013-03-22 Pedro Alves <palves@redhat.com>
7489
7490 * linux-low.c (handle_extended_wait): Don't call
7491 linux_enable_event_reporting.
7492
a8347a2a
TT
74932013-03-15 Tony Theodore <tonyt@logyst.com>
7494
7495 PR build/9098:
7496 * Makefile.in (SHELL): Use @SHELL@.
7497
eeb56fa7
SDJ
74982013-03-14 Sergio Durigan Junior <sergiodj@redhat.com>
7499
7500 * tracepoint.c (cmd_qtv): Initialize `val' with zero, silencing
7501 compiler warning.
7502
4fa7e2ff
JB
75032013-03-13 Joel Brobecker <brobecker@adacore.com>
7504
7505 * linux-low.c (linux_target_ops) [!HAVE_LINUX_BTRACE]:
7506 Remove extraneous NULL element.
7507
8ddb1965
YQ
75082013-03-13 Yao Qi <yao@codesourcery.com>
7509
7510 * tracepoint.c (traceframe_read_tsv): Look for the last matched
7511 'V' block in trace frame.
7512
9accd112
MM
75132013-03-11 Markus Metzger <markus.t.metzger@intel.com>
7514
7515 * target.h (struct target_ops): Add btrace ops.
7516 (target_supports_btrace): New macro.
7517 (target_enable_btrace): New macro.
7518 (target_disable_btrace): New macro.
7519 (target_read_btrace): New macro.
7520 * gdbthread.h (struct thread_info): Add btrace field.
7521 * server.c: Include btrace-common.h.
7522 (handle_btrace_general_set): New function.
7523 (handle_btrace_enable): New function.
7524 (handle_btrace_disable): New function.
7525 (handle_general_set): Call handle_btrace_general_set.
7526 (handle_qxfer_btrace): New function.
7527 (struct qxfer qxfer_packets[]): Add btrace entry.
7528 * inferiors.c (remove_thread): Disable btrace.
7529 * linux-low: Include linux-btrace.h.
7530 (linux_low_enable_btrace): New function.
7531 (linux_low_read_btrace): New function.
7532 (linux_target_ops): Add btrace ops.
7533 * configure.srv (i[34567]86-*-linux*): Add linux-btrace.o.
7534 Add srv_linux_btrace=yes.
7535 (x86_64-*-linux*): Add linux-btrace.o.
7536 Add srv_linux_btrace=yes.
7537 * configure.ac: Define HAVE_LINUX_BTRACE.
7538 * config.in: Regenerated.
7539 * configure: Regenerated.
7540
5cc22e4c
MM
75412013-03-11 Markus Metzger <markus.t.metzger@intel.com>
7542
7543 * server.c (handle_qxfer): Preserve error message if -3 is
7544 returned.
7545 (qxfer): Document the -3 return value.
7546
7c97f91e
MM
75472013-03-11 Markus Metzger <markus.t.metzger@intel.com>
7548
7549 * Makefile.in (SFILES): Add $(srcdir)/common/linux-btrace.c.
7550 (linux_btrace_h): New variable.
7551 (linux-btrace.o): New rule.
7552
be9a119c 75532013-03-08 Stan Shebs <stan@codesourcery.com>
f6f899bf
HAQ
7554 Hafiz Abid Qadeer <abidh@codesourcery.com>
7555
7556 * tracepoint.c (trace_buffer_size): New global.
7557 (DEFAULT_TRACE_BUFFER_SIZE): New define.
7558 (init_trace_buffer): Change to one-argument function. Allocate
7559 trace buffer memory.
7560 (handle_tracepoint_general_set): Call cmd_bigqtbuffer_size to
7561 handle QTBuffer:size packet.
7562 (cmd_bigqtbuffer_size): New function.
7563 (initialize_tracepoint): Call init_trace_buffer with
7564 DEFAULT_TRACE_BUFFER_SIZE.
7565 * server.c (handle_query): Add QTBuffer:size in the
7566 supported packets.
7567
e64f7499
YQ
75682013-03-07 Yao Qi <yao@codesourcery.com>
7569
7570 * tracepoint.c (cur_action, cur_step_action): Make them unsigned.
7571 (cmd_qtfp): Initialize cur_action and cur_step_action 0 instead
7572 of -1.
7573 (cmd_qtsp): Adjust condition. Do post increment.
7574 Set cur_action and cur_step_action back to 0.
7575
f0ae6fc3
PA
75762013-03-07 Jeremy Bennett <jeremy.bennett@embecosm.com>
7577
7578 PR server/15236
7579 * linux-low.c (linux_write_memory): Return early success if LEN is
7580 zero.
7581
b5b0b0af
CV
75822013-03-05 Corinna Vinschen <vinschen@redhat.de>
7583
334ad4a8 7584 * configure.srv: Add x86_64-*-cygwin* as target.
b5b0b0af 7585
589bc927
TT
75862013-02-28 Tom Tromey <tromey@redhat.com>
7587
7588 * configure.ac: Invoke AC_SYS_LARGEFILE.
7589 * configure, config.in: Rebuild.
7590
dfe07582
CV
75912013-02-28 Corinna Vinschen <vinschen@redhat.com>
7592
7593 * win32-low.c: Throughout, fix format strings and casts of
7594 printf-like functions to avoid type related warnings on all
7595 platforms.
7596 (get_child_debug_event): Print dwDebugEventCode as hex since
7597 that's how it's usually documented.
7598
736cd585
YQ
75992013-02-28 Yao Qi <yao@codesourcery.com>
7600
7601 * tracepoint.c (cmd_qtbuffer): Call phex_nz instead of
7602 pulongest.
7603
e1f58301
JW
76042013-02-27 Jiong Wang <jiwang@tilera.com>
7605
7606 * Makefile.in (clean): Remove reg-tilegx.c, reg-tilegx32.c.
7607 (reg-tilegx32.c): New rule.
7608 * configure.srv (tilegx-*-linux*): Add reg-tilegx32.o to srv_regobj.
7609 * linux-tile-low.c (tile_arch_setup): New function. Invoke
7610 different register info initializer according to elf class.
7611 (init_registers_tilgx32): New function. The tilegx32 register info
7612 initializer.
7613 (tile_fill_gregset): Use "uint_reg_t" to represent register size.
7614 (tile_store_gregset): Likewise.
7615
d171ca78
YQ
76162013-02-27 Yao Qi <yao@codesourcery.com>
7617
7618 * server.c (process_point_options): Print debug message when
7619 debug_threads is true.
7620
282bbdf3
YQ
76212013-02-26 Yao Qi <yao@codesourcery.com>
7622
7623 * tracepoint.c (cmd_qtbuffer): Don't set '\0' in OWN_BUF.
7624
aca22551
PA
76252013-02-19 Pedro Alves <palves@redhat.com>
7626 Kai Tietz <ktietz@redhat.com>
7627
7628 PR gdb/15161
7629
7630 * server.c (handle_query) <CRC check>: Use unpack_varlen_hex
7631 instead of strtoul to extract address from packet.
7632 (process_serial_event) <'z'>: Likewise.
7633
4f3cee1c
YQ
76342013-02-18 Yao Qi <yao@codesourcery.com>
7635
7636 * linux-bfin-low.c (the_low_target): Use NULL instead of 0.
7637
8e1d55a3
PA
76382013-02-14 Pedro Alves <palves@redhat.com>
7639
7640 Plug memory leak.
7641
7642 * tracepoint.c (cmd_qtnotes): Free TRACING_USER_NAME,
7643 TRACING_NOTES and TRACING_STOP_NOTE before clobbering.
7644
458820da
PA
76452013-02-14 Pedro Alves <palves@redhat.com>
7646
7647 * tracepoint.c (cmd_qtdpsrc): Use savestring.
7648
baea0dae
PA
76492013-02-14 Pedro Alves <palves@redhat.com>
7650
7651 * tracepoint.c (save_string): Delete.
7652 (add_tracepoint_action): Use savestring instead of save_string.
7653
0b1afbb3
PA
76542013-02-12 Pedro Alves <palves@redhat.com>
7655
7656 * linux-xtensa-low.c: Ditto.
7657 * xtensa-xtregs.c: Ditto.
7658
8a4ac37e
PA
76592013-02-12 Sanimir Agovic <sanimir.agovic@intel.com>
7660
7661 * thread-db.c (thread_db_get_tls_address): NULL pointer check
7662 thread_db.
7663
148de6bb
MS
76642013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
7665
7666 * linux-aarch64-low.c (aarch64_arch_setup): Clamp
7667 aarch64_num_wp_regs and aarch64_num_bp_regs to
7668 AARCH64_HWP_MAX_NUM and AARCH64_HBP_MAX_NUM respectively.
7669
55fac6e0
MS
76702013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
7671
7672 * linux-aarch64-low.c (ps_get_thread_area): Replace
7673 PTRACE_GET_THREAD_AREA with PTRACE_GETREGSET.
7674
176eb98c
MS
76752013-02-04 Jim MacArthur <jim.macarthur@arm.com>
7676 Marcus Shawcroft <marcus.shawcroft@arm.com>
7677 Nigel Stephens <nigel.stephens@arm.com>
7678 Yufeng Zhang <yufeng.zhang@arm.com>
7679
7680 * Makefile.in (clean): Remove aarch64.c and aarch64-without-fpu.c.
7681 (aarch64.c, aarch64-without-fpu.c): New targets.
7682 * configure.srv (aarch64*-*-linux*): New.
7683 * linux-aarch64-low.c: New file.
7684
56f7af9c
MS
76852013-02-04 Marcus Shawcroft <marcus.shawcroft@arm.com>
7686
43aaf8b6 7687 * linux-low.c (handle_extended_wait, linux_create_inferior)
56f7af9c
MS
7688 (linux_attach_lwp_1, linux_kill_one_lwp, linux_attach_one_lwp)
7689 (dequeue_one_deferred_signal, linux_resume_one_thread)
7690 (fetch_register, linux_write_memory, linux_enable_event_reporting)
7691 (linux_tracefork_grandchild, linux_test_for_tracefork)
7692 (linux_read_offsets, linux_xfer_siginfo, linux_xfer_siginfo): Add
7693 PTRACE_ARG3_TYPE and PTRACE_ARG4_TYPE cast to ptrace arguments
7694 where the argument is 0.
7695
60f662b0
YQ
76962013-01-25 Yao Qi <yao@codesourcery.com>
7697
7698 * event-loop.c: Include "queue.h".
7699 (gdb_event_p): New typedef.
7700 (struct gdb_event) <next_event>: Remove.
7701 (event_queue): Change to QUEUE(gdb_event_p).
7702 (async_queue_event): Remove.
7703 (gdb_event_xfree): New.
7704 (initialize_event_loop): New.
7705 (process_event): Use API from QUEUE.
7706 (wait_for_event): Likewise.
7707 * server.c (main): Call initialize_event_loop.
7708 * server.h (initialize_event_loop): Declare.
7709
5ae4861a
YQ
77102013-01-18 Yao Qi <yao@codesourcery.com>
7711
7712 * ax.h (struct eval_agent_expr_context): New.
7713 (gdb_eval_agent_expr): Update declaration.
7714 * ax.c (gdb_eval_agent_expr): Remove argument REGCACHE and
7715 TFRAME. Add new argument CTX.
7716 * server.h (struct eval_agent_expr_context): Declare.
7717 (agent_mem_read, agent_tsv_read): Update declaration.
7718 (agent_mem_read_string): Likewise.
7719 * tracepoint.c (eval_tracepoint_agent_expr): Remove.
7720 (add_traceframe_block): Add new argument TPOINT.
7721 Increase TPOINT->traceframe_usage.
7722 (do_action_at_tracepoint): Call gdb_eval_agent_expr instead of
7723 eval_tracepoint_agent_expr.
7724 (condition_true_at_tracepoint): Likewise.
7725 (agent_mem_read): Remove argument TFRAME. Add argument CTX.
7726 (agent_mem_read_string, agent_tsv_read): Likewise.
7727
85e00e85
YQ
77282013-01-16 Yao Qi <yao@codesourcery.com>
7729
7730 * linux-low.c (linux_resume_one_lwp): Don't check
7731 'lwp->bp_reinsert != 0'.
7732
4039cf45
JB
77332013-01-07 Joel Brobecker <brobecker@adacore.com>
7734 Pedro Alves <palves@redhat.com>
7735
7736 * lynx-low.c (ptrace_request_to_str): Define a temporary
7737 macro and use it to simplify this function's implementation.
7738
9044dee2
JB
77392013-01-07 Joel Brobecker <brobecker@adacore.com>
7740
7741 * lynx-low.c (lynx_resume): Call perror_with_name if lynx_ptrace
7742 sets errno.
7743
e6352c8f
JB
77442013-01-07 Joel Brobecker <brobecker@adacore.com>
7745
7746 * configure.srv (i[34567]86-*-lynxos*): Set srv_xmlfiles.
7747
50681a27
JB
77482013-01-07 Joel Brobecker <brobecker@adacore.com>
7749
7750 * configure.srv (powerpc-*-lynxos*): Set srv_xmlfiles.
7751
3f6e77ef
JB
77522013-01-07 Joel Brobecker <brobecker@adacore.com>
7753
7754 * lynx-low.c (lynx_resume): Use the resume_info parameter
7755 to determine the ptid for the lynx_ptrace call, unless
7756 it is equal to minus_one_ptid, in which case we use the
7757 ptid of the current_inferior.
7758 (lynx_wait_1): After having received a thread create/exit
7759 event, resume the inferior's execution using the signaling
7760 thread's ptid, rather than the old ptid.
7761
7fda33ae
JB
77622013-01-07 Joel Brobecker <brobecker@adacore.com>
7763
7764 * lynx-low.c (lynx_resume): Delete variable ret.
7765
b9786c74
JB
77662013-01-01 Joel Brobecker <brobecker@adacore.com>
7767
7768 * gdbreplay.c (gdbreplay_version): Update copyright year.
7769 * server.c (gdbserver_version): Likewise.
7770
8b93d60f
JB
77712012-12-17 Joel Brobecker <brobecker@adacore.com>
7772
7773 * lynx-low.c (lynx_wait_1): Add debug trace before adding
7774 new thread.
7775
037335a7
JB
77762012-12-17 Joel Brobecker <brobecker@adacore.com>
7777
7778 * lynx-low.c (ptrace_request_to_str): Add handling for
7779 PTRACE_GETTRACESIG.
7780
52d4cbd8
JB
77812012-12-17 Joel Brobecker <brobecker@adacore.com>
7782
7783 * lynx-low.c (lynx_attach): Delete variable new_process.
7784
ab8f6ca9
JB
77852012-12-17 Joel Brobecker <brobecker@adacore.com>
7786
7787 * lynx-low.c (lynx_create_inferior): Delete variable
7788 new_process.
7789
78cbc024
JB
77902012-12-17 Joel Brobecker <brobecker@adacore.com>
7791
7792 * lynx-low.c (ptrace_request_to_str): Do not handle
7793 PTRACE_GETTHREADLIST if this macro does not exist.
7794
14a00470
YQ
77952012-12-15 Yao Qi <yao@codesourcery.com>
7796
7797 * Makefile.in (OBS): Add notif.o.
7798 * notif.c, notif.h: New.
7799 * server.c: Include "notif.h".
7800 (struct vstop_notif) <next>: Remove.
7801 <base>: New field.
7802 (queue_stop_reply): Update.
7803 (push_event, send_next_stop_reply): Remove.
7804 (discard_queued_stop_replies): Update.
7805 (notif_stop): New variable.
7806 (handle_v_stopped): Remove.
7807 (handle_v_requests): Don't call handle_v_stopped. Call
7808 handle_ack_notif instead.
7809 (queue_stop_reply_callback): Call notif_event_enque instead
7810 of queue_stop_reply.
7811 (handle_status): Don't call send_next_stop_reply, call
7812 notif_write_event instead.
7813 (kill_inferior_callback): Likewise.
7814 (detach_or_kill_inferior_callback): Likewise.
7815 (main): Call initialize_notif.
7816 (process_serial_event): Call QUEUE_is_empty.
7817 (handle_target_event): Call notif_push instead of push event.
7818 * server.h (push_event): Remove declaration.
7819
61c125b9
TT
78202012-12-10 Tom Tromey <tromey@redhat.com>
7821
7822 * Makefile.in (DEPMODE, DEPDIR, depcomp, COMPILE.pre)
7823 (COMPILE.post, COMPILE, POSTCOMPILE, IPAGENT_COMPILE): New
7824 macros.
7825 (.c.o): Rewrite.
7826 (ax-ipa.o, tracepoint-ipa.o, utils-ipa.o, format-ipa.o)
7827 (common-utils-ipa.o, remote-utils-ipa.o, regcache-ipa.o)
7828 (i386-linux-ipa.o, linux-i386-ipa.o, linux-amd64-ipa.o)
7829 (amd64-linux-ipa.o, ax.o): Rewrite.
7830 (event-loop.o, hostio.o, hostio-errno.o, inferiors.o, mem-break.o)
7831 (proc-service.o, regcache.o, remote-utils.o, server.o, target.o)
7832 (thread-db.o, tracepoint.o, utils.o, gdbreplay.o, dll.o): Remove.
7833 (signals.o, linux-procfs.o, linux-ptrace.o, common-utils.o, vec.o)
7834 (gdb_vecs.o, xml-utils.o, linux-osdata.o, ptid.o, buffer.o)
7835 (format.o, agent.o, vasprintf.o, vsnprintf.o): Rewrite.
7836 (i386-low.o, i387-fp.o, linux-low.o, linux-arm-low.o)
7837 (linux-bfin-low.o, linux-cris-low.o, linux-crisv32-low.o)
7838 (linux-ia64-low.o, linux-m32r-low.o, linux-mips-low.o)
7839 (linux-ppc-low.o, linux-s390-low.o, linux-sh-low.o)
7840 (linux-tic6x-low.o, linux-x86-low.o, linux-xtensa-low.o)
7841 (linux-tile-low.o, lynx-low.o, lynx-ppc-low.o, nto-low.o)
7842 (nto-x86-low.o, linux-low.o, win32-low.o, win32-arm-low.o)
7843 (win32-i386-low.o, spu-low.o, reg-arm.o, arm-with-iwmmxt.o)
7844 (arm-with-vfpv2.o, arm-with-vfpv3.o, arm-with-neon.o, reg-bfin.o)
7845 (reg-cris.o, reg-crisv32.o, i386.o, i386-linux.o, i386-avx.o)
7846 (i386-avx-linux.o, i386-mmx.o, i386-mmx-linux.o, reg-ia64.o)
7847 (reg-m32r.o, reg-m68k.o, reg-cf.o, mips-linux.o, mips-dsp-linux.o)
7848 (mips64-linux.o, mips64-dsp-linux.o, powerpc-32.o, powerpc-32l.o)
7849 (powerpc-altivec32l.o, powerpc-cell32l.o, powerpc-vsx32l.o)
7850 (powerpc-isa205-32l.o, powerpc-isa205-altivec32l.o)
7851 (powerpc-isa205-vsx32l.o, powerpc-e500l.o, powerpc-64l.o)
7852 (powerpc-altivec64l.o, powerpc-cell64l.o, powerpc-vsx64l.o)
7853 (powerpc-isa205-64l.o, powerpc-isa205-altivec64l.o)
7854 (powerpc-isa205-vsx64l.o, s390-linux32.o, s390-linux32v1.o)
7855 (s390-linux32v2.o, s390-linux64.o, s390-linux64v1.o)
7856 (s390-linux64v2.o, s390x-linux64.o, s390x-linux64v1.o)
7857 (s390x-linux64v2.o, tic6x-c64xp-linux.o, tic6x-c64x-linux.o)
7858 (tic6x-c62x-linux.o, reg-sh.o, reg-sparc64.o, reg-spu.o, amd64.o)
7859 (amd64-linux.o, amd64-avx.o, amd64-avx-linux.o, x32.o)
7860 (x32-linux.o, x32-avx.o, x32-avx-linux.o, reg-xtensa.o)
7861 (reg-tilegx.o): Remove.
7862 (all_object_files): New macro.
7863 Include .deps files.
7864 * aclocal.m4, configure: Rebuild.
7865 * acinclude.m4: Include depstand.m4, lead-dot.m4.
7866 * configure.ac: Invoke ZW_CREATE_DEPDIR,
7867 ZW_PROG_COMPILER_DEPENDENCIES. Compute GMAKE condition.
7868
e90e9ad9
TT
78692012-12-05 Tom Tromey <tromey@redhat.com>
7870
7871 PR gdb/14917:
7872 * server.h (current_insn_ptr, emit_error): Declare 'extern'.
7873
02d403bf 78742012-11-28 Markus Metzger <markus.t.metzger@intel.com>
945bf713
MM
7875
7876 * configure.ac: Check for linux/perf_event.h.
7877 * config.in: Regenerated.
7878 * configure: Regenerated.
7879
0270a750
PA
78802012-11-26 Maxime Villard <rustyBSD@gmx.fr>
7881
7882 * hostio.c (handle_readlink): Decrease buffer size
7883 parameter passed to readlink by one byte.
7884
8c29b58e
YQ
78852012-11-26 Yao Qi <yao@codesourcery.com>
7886
7887 * configure.ac (build_warnings): Append '-Wempty-body'.
7888 * configure: Regenerated.
7889 * linux-low.c (linux_create_inferior): Use braces for empty 'if'
7890 body.
7891
8bdce1ff
PM
78922012-11-15 Pierre Muller <muller@sourceware.org>
7893
7894 * configure.ac (AC_CHECK_HEADERS): Add wait.h header.
7895 * config.in: Regenerate.
7896 * configure: Regenerate.
7897 * linux-low.c: Use "gdb_stat.h" header instead of <sys/stat.h> header.
7898 Use "gdb_wait.h" header instead of <sys/wait.h> header.
7899 * lynx-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
7900 * remote-utils.c: Use "gdb_stat.h" header instead of <sys/stat.h>
7901 header.
7902 * server.c: Remove HAVE_WAIT_H conditional. Use "gdb_wait.h" header
7903 instead of <sys/wait.h> header.
7904 * spu-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
7905
02d403bf 79062012-11-13 Markus Metzger <markus.t.metzger@intel.com>
3ba6ad0f
MM
7907
7908 * Makefile.in: (INTERNAL_CFLAGS): Add -DGDBSERVER
7909 (various make rules): Remove -DGDBSERVER
7910
fbd5db48
YQ
79112012-11-09 Yao Qi <yao@codesourcery.com>
7912
7913 * spu-low.c (current_ptid): Move it to ..
7914 * gdbthread.h: ... here. New.
7915 * remote-utils.c (read_ptid): Use macro 'current_ptid'.
7916 * server.c (myresume, process_serial_event): Likewise.
7917 * thread-db.c (thread_db_find_new_threads): Likewise.
7918 * tracepoint.c (run_inferior_command): Likewise.
7919
b3dc46ff
AB
79202012-10-01 Andrew Burgess <aburgess@broadcom.com>
7921
7922 * server.c (handle_search_memory_1): Include access length in
7923 warning message.
7924
07c04788
HPN
79252012-09-05 Michael Brandt <michael.brandt@axis.com>
7926
7927 * linux-crisv32-low.c: Fix compile errors.
7928
918d227b
YQ
79292012-09-04 Yao Qi <yao@codesourcery.com>
7930
7931 * tracepoint.c (cmd_qtsv): Adjust debug message.
7932 Don't check CUR_TPOINT.
7933
18c1b81a
YQ
79342012-08-28 Yao Qi <yao@codesourcery.com>
7935
7936 * ax.c, tracepoint.c: Replace ATTR_FORMAT with ATTRIBUTE_PRINTF.
7937 * server.h: Include 'libiberty.h' and 'ansidecl.h'.
7938 (ATTR_NORETURN, ATTR_FORMAT, ATTR_MALLOC): Remove.
7939 Remove declarations of xmalloc, xreallloc, xstrdup and
7940 freeargv.
7941 * Makefile.in (libiberty_h): New.
7942 (server_h): Append dependencies 'libiberty.h' and 'ansidecl.h'.
7943 (linux-bfin-low.o): Append dependency 'libiberty.h'.
7944
dc82f37b
YQ
79452012-08-23 Yao Qi <yao@codesourcery.com>
7946
7947 * server.h: Remove declaration of 'xsnprintf'.
7948
406b1477
KS
79492012-08-22 Keith Seitz <keiths@redhat.com>
7950
7951 * server.h: Include build-gnulib-gbserver/config.h.
7952 * gdbreplay.c: Likewise.
7953
e6712ff1
DE
79542012-08-08 Doug Evans <dje@google.com>
7955
7956 * Makefile.in (SFILES): Add gdb_vecs.c.
7957 (OBS): Add gdb_vecs.o.
7958 (gdb_vecs_h, host_defs_h): New variables.
7959 (thread-db.o): Add $(gdb_vecs_h) dependency.
7960 (gdb_vecs.o): New rule.
7961 * thread-db.c: #include "gdb_vecs.h".
7962 (thread_db_load_search): Use a vector to iterate over path elements.
7963 Handle text appearing after "$pdir".
7964
7965 * configure.ac: Add check for strstr.
7966 * config.in: Regenerate.
7967 * configure: Regenerate.
7968
7c3270ae
UW
79692012-08-02 Ulrich Weigand <ulrich.weigand@linaro.org>
7970
7971 * hostio.c (handle_pread): If pread fails, fall back to attempting
7972 lseek/read.
7973 (handle_pwrite): Likewise for pwrite.
7974
b62e2b27
UW
79752012-08-01 Ulrich Weigand <ulrich.weigand@linaro.org>
7976
7977 * linux-arm-low.c (arm_linux_hw_point_initialize): Distinguish
7978 between unsupported TYPE and unimplementable ADDR/LEN combination.
7979 (arm_insert_point): Act on new return value.
7980
78a99e91
PA
79812012-07-31 Pedro Alves <palves@redhat.com>
7982
7983 * server.c (process_point_options): Only skip tokens if we find
7984 one that is unrecognized. Don't treat 'X' specially while
7985 skipping unrecognized tokens.
7986
fcf303ab
UW
79872012-07-30 Ulrich Weigand <ulrich.weigand@linaro.org>
7988
7989 * linux-arm-low.c (arm_linux_hw_point_initialize): Do not attempt
7990 to 4-byte-align HW breakpoint addresses for Thumb.
7991
7255706c
YQ
79922012-07-27 Yao Qi <yao@codesourcery.com>
7993
7994 PR remote/14161.
7995
7996 * server.h: Declare gdb_agent_about_to_close.
7997 * target.c (kill_inferior): Include "agent.h".
7998 New. Send command 'kill'.
7999 * target.h (kill_inferior): Removed macro.
8000 * tracepoint.c (gdb_agent_about_to_close): New.
8001 (gdb_agent_helper_thread): Handle command 'close'.
8002 Wait endlessly until the inferior stops.
8003 Install gdb_agent_remove_socket to atexit hook.
8004 (agent_socket_name): New static variable.
8005 (gdb_agent_socket_init): Replace local variable 'name' with
8006 'agent_socket_name'.
8007 (gdb_agent_remove_socket): New.
8008
5a3f286f
YQ
80092012-07-27 Yao Qi <yao@codesourcery.com>
8010
8011 * server.c (process_point_options): Stop at 'X' when parsing.
8012
961bd387
ME
80132012-07-19 Michael Eager <eager@eagercon.com>
8014
a261b8f5 8015 * i386-low.c (Z_packet_to_hw_type): Add Z_PACKET_HW_BP, translate
961bd387
ME
8016 to hw_execute.
8017 * linux-x86-low.c (x86_insert_point, x86_remove_point):
8018 Call i386_low_insert_watchpoint, i386_low_remove_watchpoint to add/del
8019 hardware breakpoint.
8020
aa7c7447
JK
80212012-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
8022
8023 * gdbserver/linux-low.c (initialize_low): Call
8024 linux_ptrace_init_warnings.
8025
7f216e7c
DE
80262012-07-02 Doug Evans <dje@google.com>
8027
8028 * mem-break.c (gdb_no_commands_at_breakpoint): Fix cast from
8029 pointer to int.
8030
d3ce09f5
SS
80312012-07-02 Stan Shebs <stan@codesourcery.com>
8032
8033 * Makefile.in (WARN_CFLAGS_NO_FORMAT): Define.
8034 (ax.o): Add it to build rule.
8035 (ax-ipa.o): Ditto.
8036 (OBS): Add format.o.
8037 (IPA_OBS): Add format.o.
8038 * server.c (handle_query): Claim support for breakpoint commands.
8039 (process_point_options): Add command case.
8040 (process_serial_event): Leave running if there are printfs in
8041 effect.
8042 * mem-break.h (any_persistent_commands): Declare.
8043 (add_breakpoint_commands): Declare.
8044 (gdb_no_commands_at_breakpoint): Declare.
8045 (run_breakpoint_commands): Declare.
8046 * mem-break.c (struct point_command_list): New struct.
8047 (struct breakpoint): New field command_list.
8048 (any_persistent_commands): New function.
8049 (add_commands_to_breakpoint): New function.
8050 (add_breakpoint_commands): New function.
8051 (gdb_no_commands_at_breakpoint): New function.
8052 (run_breakpoint_commands): New function.
8053 * linux-low.c (linux_wait_1): Test for and run breakpoint commands
8054 locally.
8055 * ax.c: Include format.h.
8056 (ax_printf): New function.
8057 (gdb_eval_agent_expr): Add printf opcode.
8058
2f8f6aed
YQ
80592012-06-13 Yao Qi <yao@codesourcery.com>
8060
8061 * server.c (start_inferior): Remove duplicated writes to fields
8062 'last_resume_kind' and 'last_status' of 'current_inferior'.
8063
0c9070b3
YQ
80642012-06-12 Yao Qi <yao@codesourcery.com>
8065 Pedro Alves <palves@redhat.com>
8066
8067 * linux-low.c (linux_set_resume_request): Simplify predicate. Add
8068 comment.
8069 * server.c (handle_v_cont): Extend comment.
8070
c52daf70
YQ
80712012-06-11 Yao Qi <yao@codesourcery.com>
8072
8073 * linux-low.c (linux_attach): Add 'static'.
8074
d38bbb0a
YQ
80752012-06-06 Yao Qi <yao@codesourcery.com>
8076
8077 * ax.c (gdb_eval_agent_expr): Print `top' in hex.
8078
89dc0afd
JK
80792012-06-01 Jan Kratochvil <jan.kratochvil@redhat.com>
8080
8081 Fix gcc -flto compilation warning.
8082 * server.c (main): Make variable multi_mode and attach volatile.
8083
75f62ce7
TJB
80842012-05-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
8085
8086 * linux-low.c (get_r_debug): Disable code using DT_MIPS_RLD_MAP
8087 if the platform doesn't know about it.
8088
65f479b6
PA
80892012-05-30 Jeff Kenton <jkenton@tilera.com>
8090
8091 * Makefile.in (SFILES): Add linux-tile-low.c.
8092 (linux-tile-low.o, reg-tilegx.o, reg-tilegx.c): New rules.
8093 * configure.srv: Handle tilegx-*-linux*.
8094 * linux-tile-low.c: New file.
8095
0c5bf5a9
JK
80962012-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
8097
8098 * linux-low.c (linux_qxfer_libraries_svr4): Return -1 if R_DEBUG is -1.
8099
a493e3e2
PA
81002012-05-24 Pedro Alves <palves@redhat.com>
8101
8102 PR gdb/7205
8103
43aaf8b6 8104 Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.
a493e3e2 8105
2ea28649
PA
81062012-05-24 Pedro Alves <palves@redhat.com>
8107
8108 PR gdb/7205
8109
8110 Replace target_signal with gdb_signal throughout.
8111
8d409d16
MR
81122012-05-22 Maciej W. Rozycki <macro@codesourcery.com>
8113
8114 * linux-low.c (linux_store_registers): Avoid the copying sequence
8115 when no data has been retrieved by ptrace.
8116
23512c01
MGD
81172012-05-22 Will Deacon <will.deacon@arm.com>
8118
8119 * linux-low (__UCLIBC__ && !(__UCLIBC_HAS_MMU__ || __ARCH_HAS_MMU__)):
8120 Include asm/ptrace.h.
8121 (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define only if not
8122 already defined.
8123
4934b29e
MR
81242012-05-21 Maciej W. Rozycki <macro@codesourcery.com>
8125
8126 * linux-low.c (linux_store_registers): Don't re-retrieve data
8127 with ptrace that has already been obtained from /proc. Always
8128 copy any data retrieved with ptrace to the buffer supplied.
8129
bde24c0a
PA
81302012-05-11 Yao Qi <yao@codesourcery.com>
8131 Pedro Alves <palves@redhat.com>
8132
8133 * linux-low.c (enum stopping_threads_kind): New.
8134 (stopping_threads): Change type to `enum stopping_threads_kind'.
8135 (handle_extended_wait): If stopping and suspending threads, leave
8136 the new_lwp suspended too.
8137 (linux_wait_for_event): Adjust.
8138 (stop_all_lwps): Set `stopping_threads' to
8139 STOPPING_AND_SUSPENDING_THREADS or STOPPING_THREADS depending on
8140 whether we're suspending threads or just stopping them. Assert no
8141 recursion happens.
8142
623b6bdf
YQ
81432012-04-29 Yao Qi <yao@codesourcery.com>
8144
8145 * server.h: Move some code to ...
8146 * gdbthread.h: ... here. New.
8147 * Makefile.in (inferiors.o, regcache.o): Depends on gdbthread.h
8148 (remote-utils.o, server.o, target.o tracepoint.o): Likewise.
8149 (nto-low.o, win32-low.o): Likewise.
8150 * inferiors.c, linux-low.h, nto-low.c: Include gdbthread.h.
8151 * regcache.c, remote-utils.c, server.c: Likewise.
8152 * target.c, tracepoint.c, win32-low.c: Likewise.
8153
f15f9948
TJB
81542012-04-24 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
8155
8156 * linux-low.h (PTRACE_ARG3_TYPE): Move macro from linux-low.c.
8157 (PTRACE_ARG4_TYPE): Likewise.
8158 (PTRACE_XFER_TYPE): Likewise.
8159 * linux-arm-low.c (arm_prepare_to_resume): Cast third argument of
8160 ptrace to PTRACE_ARG3_TYPE.
8161 * linux-low.c (PTRACE_ARG3_TYPE): Move macro to linux-low.h.
8162 (PTRACE_ARG4_TYPE): Likewise.
8163 (PTRACE_XFER_TYPE): Likewise.
8164 (linux_detach_one_lwp): Cast fourth argument of
8165 ptrace to long then PTRACE_ARG4_TYPE.
8166 (regsets_fetch_inferior_registers): Cast third argument of
8167 ptrace to long then PTRACE_ARG3_TYPE.
8168 (regsets_store_inferior_registers): Likewise.
8169
38ea300a
PA
81702012-04-20 Pedro Alves <palves@redhat.com>
8171
8172 * configure: Regenerate.
8173
c971b7fa
PA
81742012-04-19 Pedro Alves <palves@redhat.com>
8175
43aaf8b6 8176 * Makefile.in (GNULIB_BUILDDIR): New.
c971b7fa 8177 (LIBGNU, INCGNU, GNULIB_H): Adjust.
43aaf8b6
PA
8178 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): New.
8179 (all, install-only, uninstall, clean-info, all-lib, clean): No
8180 longer pass GNULIB_FLAGS_TO_PASS. Use subdir_do.
8181 (maintainer-clean realclean distclean): Use subdir_do.
8182 (subdir_do): New.
8183 (gnulib/import/Makefile): Adjust. Replace gnulib/import with
c971b7fa 8184 $(GNULIB_BUILDDIR). Don't pass argument to config.status.
43aaf8b6
PA
8185 * acinclude.m4: Include acx_configure_dir.m4.
8186 * configure.ac: Remove gl_EARLY, gl_INIT, and AM_INIT_AUTOMAKE
8187 calls. Call AC_PROG_RANLIB. Configure gnulib using
8188 ACX_CONFIGURE_DIR.
8189 (GNULIB): New.
8190 (GNULIB_STDINT_H): Adjust.
8191 (AC_OUTPUT): Don't output gnulib/Makefile anymore.
8192 * gdbreplay.c: Include build-gnulib/config.h.
8193 * server.h: Likewise.
8194 * aclocal.m4: Regenerate.
8195 * config.in: Regenerate.
8196 * configure: Regenerate.
c971b7fa 8197
809277f8
PA
81982012-04-19 Pedro Alves <palves@redhat.com>
8199
8200 * Makefile.in (LIBGNU, INCGNU): Adjust.
8201 (GNULIB_FLAGS_TO_PASS, GNULIB_H): Adjust.
8202 (all, install-only, uninstall, clean-info, all-lib, clean)
8203 (maintainer-clean, Makefile, gnulib/Makefile): Adjust.
8204 * configure.ac: Adjust AC_OUTPUT output.
8205 * aclocal.m4: Regenerate.
8206 * configure: Regenerate.
8207
fd9bb8b8
PA
82082012-04-19 Pedro Alves <palves@redhat.com>
8209
8210 * Makefile.in (generated_files): New.
8211 (server_h): Remove the explicit dependency on config.h, and depend
8212 on $generated_files.
8213
1c298c66
PA
82142012-04-19 Pedro Alves <palves@redhat.com>
8215
8216 * Makefile.in (INCGNU): Add -Ignulib.
8217
57c4b50b
PA
82182012-04-19 Pedro Alves <palves@redhat.com>
8219
8220 * Makefile.in (GNULIB_INCLUDE_DIR): Rename to ...
8221 (INCGNU): ... this, and spell out -I here.
8222 (GNULIB_LIB): Rename to ...
8223 (LIBGNU): ... this.
8224 (INCLUDE_CFLAGS, gdbserver$(EXEEXT), $(GNULIB_LIB) rule): Adjust.
8225
1030e047
PA
82262012-04-19 Pedro Alves <palves@redhat.com>
8227
8228 * config.in: Regenerate.
8229
447d4319
PA
82302012-04-19 Pedro Alves <palves@redhat.com>
8231
8232 * configure.ac: Remove AC_CHECK_DECLS check for memmem.
8233 * server.h (memmem): Remove declaration.
8234 * config.in: Regenerate.
8235 * configure: Regenerate.
8236
aad9eab9
YQ
82372012-04-19 Yao Qi <yao@codesourcery.com>
8238
8239 * Makefile.in (SFILES): Add common/vec.c.
8240 (OBS): Add vec.o.
8241 (vec.o): New rule.
8242
3e10640f
YQ
82432012-04-19 Yao Qi <yao@codesourcery.com>
8244
8245 * remote-utils.c (prepare_resume_reply): Replace with macro
8246 target_core_of_thread.
8247 * server.c (handle_qxfer_threads_proper): Likewise.
8248 * target.h (traget_core_of_thread): New macro.
8249
71622373
PA
82502012-04-18 Pedro Alves <palves@redhat.com>
8251
8252 * aclocal.m4: Regenerate.
8253 * configure: Regenerate.
8254
80d26939
YQ
82552012-04-16 Yao Qi <yao@codesourcery.com>
8256
8257 * tracepoint.c (cmd_qtstart): Download tracepoints even when they are
8258 duplicated on address.
8259
42476b70
YQ
82602012-04-16 Yao Qi <yao@codesourcery.com>
8261
8262 * tracepoint.c (COPY_FIELD_TO_BUF): New macro.
8263 (struct tracepoint_action_ops) <send>: New field.
8264 (m_tracepoint_action_send, r_tracepoint_action_send): New.
8265 (agent_expr_send, x_tracepoint_action_send): New.
8266 (l_tracepoint_action_send): New.
8267 (cmd_qtdp): Download and install tracepoint
8268 according to `use_agent'.
8269 (run_inferior_command): Add one more parameter `len'.
8270 Update callers.
8271 (tracepoint_send_agent): New.
8272 (cmd_qtdp, cmd_qtstart): Call tracepoint_send_agent.
8273
7bc83639
YQ
82742012-04-16 Yao Qi <yao@codesourcery.com>
8275
8276 * tracepoint.c (download_tracepoints): Moved to ...
8277 (cmd_qtstart): ... here.
8278
5f18041e
YQ
82792012-04-14 Yao Qi <yao@codesourcery.com>
8280
8281 * tracepoint.c: Include inttypes.h.
8282 (struct collect_memory_action): Use sized types.
8283 (struct tracepoint): Likewise.
8284 (cmd_qtdp, stop_tracing): Update print specifiers.
8285 (cmd_qtp, response_tracepoint): Likewise.
8286 (collect_data_at_tracepoint): Likewise.
8287 (collect_data_at_step): Likewise.
8288
55a8c076
YQ
82892012-04-14 Yao Qi <yao@codesourcery.com>
8290
8291 Import gnulib module inttypes.
8292 * aclocal.m4, config.in, configure: Regenerated.
8293
dc750257
YQ
82942012-04-14 Yao Qi <yao@codesourcery.com>
8295
8296 * Makefile.in (maintainer-clean, realclean, distclean): Remove
8297 Makefile and config.status at last.
8298
0ab5faf9
YQ
82992012-04-13 Yao Qi <yao@codesourcery.com>
8300
8301 * tracepoint.c: Include stdint.h unconditionally.
8302
18f5fd81
TJB
83032012-04-13 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
8304
8305 * acinclude.m4 (GDBSERVER_HAVE_THREAD_DB_TYPE): New macro based
8306 on BFD_HAVE_SYS_PROCFS_TYPE.
8307 * configure.ac: Look for lwpid_t and psaddr_t in libthread_db.h.
8308 * configure: Regenerate.
8309 * config.in: Likewise.
8310
4d47af5c
L
83112012-04-13 H.J. Lu <hongjiu.lu@intel.com>
8312
8313 * Makefile.in (clean): Also remove x32.c x32-linux.c
8314 x32-avx.c x32-avx-linux.c.
8315 (x32.o): New target.
8316 (x32.c): Likewise.
8317 (x32-linux.o): Likewise.
8318 (x32-linux.c): Likewise.
8319 (x32-avx.o): Likewise.
8320 (x32-avx.c): Likewise.
8321 (x32-avx-linux.o): Likewise.
8322 (x32-avx-linux.c): Likewise.
8323
8324 * configure.srv (srv_amd64_regobj): Add x32.o x32-avx.o.
8325 (srv_amd64_linux_regobj): Add x32-linux.o x32-avx-linux.o.
8326 (srv_i386_64bit_xmlfiles): Add i386/x32-core.xml.
8327 (srv_amd64_xmlfiles): Add i386/x32.xml i386/x32-avx.xml.
8328 (srv_amd64_linux_xmlfiles): Add i386/x32-linux.xml
8329 i386/x32-avx-linux.xml.
8330
8331 * linux-x86-low.c (init_registers_x32_linux): New prototype.
8332 (init_registers_x32_avx_linux): Likwise.
8333 (x86_linux_update_xmltarget): Call init_registers_x32_linux
8334 or init_registers_x32_avx_linux if linux_is_elf64 is false.
8335
ecedbe58
PA
83362012-04-13 Pedro Alves <palves@redhat.com>
8337
8338 * Makefile.in (GNULIB_FLAGS_TO_PASS): New.
8339 (FLAGS_TO_PASS): Don't change or set $top_srcdir, $srcdir and VPATH.
8340 (all, uninstall, clean-info, all-lib, clean, maintainer-clean)
8341 (realclean, distclean): Explicitly pass $GNULIB_FLAGS_TO_PASS to
8342 the sub-make.
8343
c92b5177
L
83442012-04-12 H.J. Lu <hongjiu.lu@intel.com>
8345
8346 * linux-x86-low.c (compat_x32_clock_t): New.
8347 (compat_x32_siginfo_t): Likewise.
8348 (compat_x32_siginfo_from_siginfo): Likewise.
8349 (siginfo_from_compat_x32_siginfo): Likewise.
8350 (linux_is_elf64): Likewise.
8351 (x86_siginfo_fixup): Call compat_x32_siginfo_from_siginfo
8352 and siginfo_from_compat_x32_siginfo for x32.
8353 (x86_arch_setup): Set linux_is_elf64.
8354
214d508e
L
83552012-04-12 H.J. Lu <hongjiu.lu@intel.com>
8356
8357 PR gdb/13969
8358 * linux-low.c (linux_pid_exe_is_elf_64_file): Also return the
8359 e_machine field.
8360 (linux_qxfer_libraries_svr4): Update call to elf_64_file_p.
8361 * linux-low.h (linux_pid_exe_is_elf_64_file): Updated.
8362 * linux-x86-low.c (x86_arch_setup): Check if GDBserver is
8363 compatible with process.
8364
c9a1864a
YQ
83652012-04-12 Yao Qi <yao@codesourcery.com>
8366
8367 * Makefile.in: Define abs_top_srcdir and abs_srcdir.
8368 (INCLUDE_CFLAGS): Append GNULIB_INCLUDE_DIR.
8369 (install-only, install-info, clean): Handle sub dir gnulib.
8370 (all-lib, am--refresh): New targets.
8371 (memmem.o): Remove target.
8372 * configure.ac: Remove AC_CONFIG_LIBOBJ_DIR.
8373 Invoke gl_EARLY. Invoke AC_CHECK_PROGS for make.
8374 (AC_REPLACE_FUNCS): Remove memmem.
8375 Invoke gl_INIT and AM_INIT_AUTOMAKE.
8376 (AC_OUTPUT): Generate Makefile in gnulib/.
8377 * aclocal.m4, config.in, configure: Regenerated.
8378
367ba2c2
MR
83792012-04-10 Maciej W. Rozycki <macro@codesourcery.com>
8380
8381 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP.
8382
9d236627
PA
83832012-04-05 Pedro Alves <palves@redhat.com>
8384
8385 -Werror=strict-aliasing
8386
8387 * spu-low.c (parse_spufs_run): Avoid dereferencing type-punned
8388 pointer.
8389
111217b3
PA
83902012-04-04 Pedro Alves <palves@redhat.com>
8391
8392 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
8393 (sparc_store_gregset_from_stack, sparc_store_gregset)
8394 (sparc_breakpoint_at): Fix formatting.
8395
8365dcf5
TJB
83962012-03-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
8397
8398 * configure.ac: Check whether Elf32_auxv_t and Elf64_auxv_t
8399 are available.
8400 * linux-low.c [HAVE_ELF32_AUXV_T] (Elf32_auxv_t): Add typedef.
8401 [HAVE_ELF64_AUXV_T] (Elf64_auxv_t): Likewise.
8402 * config.in: Regenerate.
8403 * configure: Likewise.
8404
689cc2ae
PA
84052012-03-29 Pedro Alves <palves@redhat.com>
8406
8407 * linux-low.c (regsets_store_inferior_registers) [__sparc__]:
8408 Correct ptrace arguments.
8409
c14dfd32
PA
84102012-03-28 Pedro Alves <palves@redhat.com>
8411
8412 * linux-ia64-low.c (ia64_regmap): Map IA64_EC_REGNUM to PT_AR_EC.
8413 (IA64_GR0_REGNUM, IA64_FR0_REGNUM)
8414 (IA64_FR1_REGNUM): New defines.
8415 (ia64_fetch_register): New.
8416 (the_low_target): Install it.
8417 * linux-low.h (struct linux_target_ops) <fetch_register>: New
8418 field.
8419 * linux-low.c (linux_fetch_registers): Try the
8420 the_low_target.fetch_register hook first.
8421
8422 * linux-arm-low.c (the_low_target): Adjust.
8423 * linux-bfin-low.c (the_low_target): Adjust.
8424 * linux-cris-low.c (the_low_target): Adjust.
8425 * linux-crisv32-low.c (the_low_target): Adjust.
8426 * linux-m32r-low.c (the_low_target): Adjust.
8427 * linux-m68k-low.c (the_low_target): Adjust.
8428 * linux-mips-low.c (the_low_target): Adjust.
8429 * linux-ppc-low.c (the_low_target): Adjust.
8430 * linux-s390-low.c (the_low_target): Adjust.
8431 * linux-sh-low.c (the_low_target): Adjust.
8432 * linux-sparc-low.c (the_low_target): Adjust.
8433 * linux-tic6x-low.c (the_low_target): Adjust.
8434 * linux-x86-low.c (the_low_target): Adjust.
8435 * linux-xtensa-low.c (the_low_target): Adjust.
8436
63c88e13
PA
84372012-03-26 Pedro Alves <palves@redhat.com>
8438
8439 * server.c (handle_qxfer_libraries): Don't bail early if
8440 the_target->qxfer_libraries_svr4 is not NULL.
8441
fb723180
PA
84422012-03-26 Pedro Alves <palves@redhat.com>
8443
8444 * linux-low.c (linux_qxfer_libraries_svr4): Fix pasto in comment.
8445
0afae3cf
PA
84462012-03-23 Pedro Alves <palves@redhat.com>
8447
8448 * linux-low.c (linux_qxfer_libraries_svr4): Terminate the
8449 "library-list-svr4" element's start tag when the the DSO list is
8450 empty.
8451
485f1ee4
PA
84522012-03-23 Pedro Alves <palves@redhat.com>
8453
8454 * linux-low.c (read_one_ptr): Read the inferior's pointer through
8455 a variable whose type size is the same as the inferior's pointer
8456 size.
8457
a5362b9a
TS
84582012-03-21 Thomas Schwinge <thomas@codesourcery.com>
8459
8460 * linux-arm-low.c (arm_stopped_by_watchpoint): Use siginfo_t instead of
8461 struct siginfo.
8462 * linux-low.c (siginfo_fixup, linux_xfer_siginfo): Likewise.
8463 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
8464 * linux-low.h: Include <signal.h>.
8465 (struct siginfo): Remove forward declaration.
8466 (struct linux_target_ops) <siginfo_fixup>: Use siginfo_t instead of
8467 struct siginfo.
8468
d226c142
MF
84692012-03-21 Mike Frysinger <vapier@gentoo.org>
8470
8471 * .gitignore: Ignore more files.
8472
122f36ef
PA
84732012-03-19 Pedro Alves <palves@redhat.com>
8474 Jan Kratochvil <jan.kratochvil@redhat.com>
8475
8476 * server.c (cont_thread, general_thread): Add describing comments.
8477 (start_inferior): Clear `cont_thread'.
8478 (handle_v_cont): Don't set `cont_thread' if resuming all threads
8479 of a process.
8480
fc3e5175
YQ
84812012-03-15 Yao Qi <yao@codesourcery.com>
8482
8483 * tracepoint.c (install_tracepoint): Move duplicated tracepoint
8484 handling to ...
8485 (cmd_qtdp): ... here.
8486
8d0d92cd
YQ
84872012-03-15 Yao Qi <yao@codesourcery.com>
8488
8489 * tracepoint.c (struct tracepoint_action_ops): New.
8490 (struct tracepoint_action) [!IN_PROCESS_AGENT] <ops>: New field.
8491 (m_tracepoint_action_download): New.
8492 (r_tracepoint_action_download): New.
8493 (x_tracepoint_action_download): New.
8494 (l_tracepoint_action_download): New.
8495 (add_tracepoint_action): Install `action->ops' according type.
8496 (download_tracepoint_1): Move code `download' function pointer
8497 of various tracepoint_action_ops.
8498
87b0bb13
JK
84992012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
8500
8501 * linux-low.c (linux_attach_lwp_1): New variable buffer. Call
8502 linux_ptrace_attach_warnings.
8503
5f572dec
JK
85042012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
8505
8506 * Makefile.in (linux-ptrace.o): New.
8507 * configure.srv (arm*-*-linux*, bfin-*-*linux*, crisv32-*-linux*)
8508 (cris-*-linux*, i[34567]86-*-linux*, ia64-*-linux*, m32r*-*-linux*)
8509 (m68*-*-linux*, m68*-*-uclinux*, mips*-*-linux*, powerpc*-*-linux*)
8510 (s390*-*-linux*, sh*-*-linux*, sparc*-*-linux*, tic6x-*-uclinux)
8511 (x86_64-*-linux*, xtensa*-*-linux*): Add linux-ptrace.o to SRV_TGTOBJ
8512 of these targets.
8513 * linux-low.c (linux_attach_lwp_1): Remove redundent else clause.
8514
f4647387
YQ
85152012-03-08 Yao Qi <yao@codesourcery.com>
8516 Pedro Alves <palves@redhat.com>
8517
8518 Fix PR server/13392.
8519 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Check
8520 offset of JMP insn.
8521 * tracepoint.c (remove_tracepoint): New.
8522 (cmd_qtdp): Call remove_tracepoint when failed to install.
8523
9b224c5e
PA
85242012-03-07 Pedro Alves <palves@redhat.com>
8525
8526 * linux-low.c (get_detach_signal): New.
8527 (linux_detach_one_lwp): Get rid of a pending SIGSTOP with SIGCONT.
8528 Pass on pending signals to PTRACE_DETACH. Check the result of the
8529 ptrace call.
8530 * server.c (program_signals, program_signals_p): New.
8531 (handle_general_set): Handle QProgramSignals.
8532 * server.h (program_signals, program_signals_p): Declare.
8533
e237a7e2
JK
85342012-03-05 Pedro Alves <palves@redhat.com>
8535 Jan Kratochvil <jan.kratochvil@redhat.com>
8536
8537 * linux-low.c (get_dynamic): Don't warn when PT_PHDR isn't found.
8538 New comment why.
8539
5808517f
YQ
85402012-03-03 Yao Qi <yao@codesourcery.com>
8541
8542 * tracepoint.c (tracepoint_look_up_symbols): Update call to
8543 agent_look_up_symbols.
8544
58b4daa5
YQ
85452012-03-03 Yao Qi <yao@codesourcery.com>
8546
8547 * Makefile.in (linux-low.o): Keep dependence on agent.h.
8548 (linux-x86-low.o): Likewise.
8549 * server.h: Remove in_process_agent_loaded.
8550 * tracepoint.c (in_process_agent_loaded): Removed. Moved it
8551 common/agent.c.
8552 Update callers.
8553
8ffcbaaf
YQ
85542012-03-03 Yao Qi <yao@codesourcery.com>
8555
8556 * tracepoint.c (gdb_agent_capability): New global.
8557 (in_process_agent_loaded_ust): Renamed to
8558 `in_process_agent_supports_ust'.
8559 Update callers.
8560 (in_process_agent_supports_ust): Call agent_capability_check.
8561 (clear_installed_tracepoints): Assert that agent supports
8562 agent.
8563
d1feda86
YQ
85642012-03-03 Yao Qi <yao@codesourcery.com>
8565
8566 * linux-low.c (linux_supports_agent): New.
8567 (linux_target_ops): Initialize field `supports_agent' with
8568 linux_supports_agent.
8569 * target.h (struct target_ops) <supports_agent>: New.
8570 (target_supports_agent): New macro.
8571 * server.c (handle_general_set): Handle packet 'QAgent'.
8572 (handle_query): Send `QAgent+'.
8573 * Makefile.in (server.o): Depends on agent.h.
8574
2fa291ac
YQ
85752012-03-03 Yao Qi <yao@codesourcery.com>
8576
8577 * Makefile.in (OBS): Add agent.o.
8578 Add new rule for agent.o.
8579 Track dependence of tracepoint.c on agent.h.
8580 * tracepoint.c (run_inferior_command_1):
8581 (run_inferior_command): Call agent_run_command.
8582 (gdb_ust_connect_sync_socket): Deleted. Move it to
8583 common/agent.c.
8584 (resume_thread, stop_thread): Likewise.
8585 (gdb_ust_socket_init): Renamed to ...
8586 (gdb_agent_socket_init): ... New.
8587 (gdb_ust_thread): Renamed to ...
8588 (gdb_agent_helper_thread): ... New.
8589 (gdb_ust_init): Move some code to ...
8590 (gdb_agent_init): ... here. New.
8591 [HAVE_UST]: Call gdb_ust_init.
8592 (initialize_tracepoint_ftlib): Call gdb_agent_init.
8593 * configure.ac: Add `sys/un.h' to AC_CHECK_HEADERS.
8594 * config.in, configure: Regenerated.
8595
05044653
PA
85962012-03-02 Pedro Alves <palves@redhat.com>
8597
8598 * inferiors.c (add_pid_to_list, pull_pid_from_list): Delete.
8599 * linux-low.c (struct simple_pid_list): New.
8600 (stopped_pids): New a struct simple_pid_list pointer.
8601 (add_to_pid_list, pull_pid_from_list): New.
8602 (handle_extended_wait): Don't assume the first signal new children
8603 report is SIGSTOP. Adjust call to pull_pid_from_list.
8604 (linux_wait_for_lwp): Adjust.
8605
8d00225b
YQ
86062012-03-02 Yao Qi <yao@codesourcery.com>
8607
8608 * tracepoint.c (do_action_at_tracepoint): Write `stop_pc' in
8609 debug log.
8610
19560ba5
YQ
86112012-03-02 Yao Qi <yao@codesourcery.com>
8612
8613 * tracepoint.c (collect_ust_data_at_tracepoint): Remove parameters
8614 `stop_pc' and `tpoint'. Update caller.
8615
1faeff08
MR
86162012-03-01 Maciej W. Rozycki <macro@codesourcery.com>
8617
8618 * linux-low.h (linux_target_ops): Add regset_bitmap member.
8619 * linux-low.c (use_linux_regsets): New macro.
8620 [!HAVE_LINUX_REGSETS] (regsets_fetch_inferior_registers): Likewise.
8621 [!HAVE_LINUX_REGSETS] (regsets_store_inferior_registers): Likewise.
8622 (linux_register_in_regsets): New function.
8623 (usr_fetch_inferior_registers): Skip registers covered by
8624 regsets.
8625 (usr_store_inferior_registers): Likewise.
8626 (usr_fetch_inferior_registers): New macro.
8627 (usr_store_inferior_registers): Likewise.
8628 (linux_fetch_registers): Handle mixed regset/non-regset targets.
8629 (linux_store_registers): Likewise.
8630 * linux-mips-low.c (init_registers_mips_dsp_linux): New
8631 prototype.
8632 (init_registers_mips64_dsp_linux): Likewise.
8633 (init_registers_mips_linux): New macro.
8634 (init_registers_mips_dsp_linux): Likewise.
8635 (mips_dsp_num_regs): Likewise.
8636 (DSP_BASE, DSP_CONTROL): New fallback macros.
8637 (mips_base_regs): New macro.
8638 (mips_regmap): Use it. Fix the size.
8639 (mips_dsp_regmap): New variable.
8640 (mips_dsp_regset_bitmap): Likewise.
8641 (mips_arch_setup): New function.
8642 (mips_cannot_fetch_register): Use the_low_target.regmap rather
8643 than mips_regmap.
8644 (mips_cannot_store_register): Likewise.
8645 (the_low_target): Update .arch_setup, .num_regs and .regmap
8646 initializers. Add .regset_bitmap initializer.
8647 * linux-arm-low.c (the_low_target): Add .regset_bitmap
8648 initializer.
8649 * linux-bfin-low.c (the_low_target): Likewise.
8650 * linux-cris-low.c (the_low_target): Likewise.
8651 * linux-crisv32-low.c (the_low_target): Likewise.
8652 * linux-ia64-low.c (the_low_target): Likewise.
8653 * linux-m32r-low.c (the_low_target): Likewise.
8654 * linux-m68k-low.c (the_low_target): Likewise.
8655 * linux-ppc-low.c (the_low_target): Likewise.
8656 * linux-s390-low.c (the_low_target): Likewise.
8657 * linux-sh-low.c (the_low_target): Likewise.
8658 * linux-sparc-low.c (the_low_target): Likewise.
8659 * linux-tic6x-low.c (the_low_target): Likewise.
8660 * linux-x86-low.c (the_low_target): Likewise.
8661 * linux-xtensa-low.c (the_low_target): Likewise.
8662 * configure.srv <mips*-*-linux*>: Add mips-dsp-linux.o and
8663 mips64-dsp-linux.o to srv_regobj. Add mips-dsp-linux.xml,
8664 mips64-dsp-linux.xml, mips-dsp.xml and mips64-dsp.xml to
8665 srv_xmlfiles.
8666 * Makefile.in (mips-dsp-linux.o, mips-dsp-linux.c): New targets.
8667 (mips64-dsp-linux.o, mips64-dsp-linux.c): Likewise.
8668
c03e6ccc
YQ
86692012-02-29 Yao Qi <yao@codesourcery.com>
8670 Pedro Alves <palves@redhat.com>
8671
8672 * linux-low.c: (linux_wait_1): Call unsuspend_all_lwps when
8673 `step_over_finished' is true.
8674
644cebc9
PA
86752012-02-27 Pedro Alves <palves@redhat.com>
8676
8677 * linux-low.c (pid_is_stopped): Delete, moved to common/.
8678 (linux_attach_lwp_1): Adjust to use linux_proc_pid_is_stopped.
8679
c14d7ab2
PA
86802012-02-27 Pedro Alves <palves@redhat.com>
8681
8682 PR server/9684
8683 * linux-low.c (pid_is_stopped): New.
8684 (linux_attach_lwp_1): Handle attaching to 'T (stopped)' processes.
8685
412c89dd
LM
86862012-02-25 Luis Machado <lgustavo@codesourcery.com>
8687
8688 * mem-break.c (clear_gdb_breakpoint_conditions): Fix de-allocation
8689 of conditions.
8690
b745defe
MR
86912012-02-24 Maciej W. Rozycki <macro@codesourcery.com>
8692
8693 * linux-mips-low.c (mips_regmap): Correct the index of $f9.
8694
9f3a5c85
LM
86952012-02-24 Luis Machado <lgustavo@codesourcery>
8696
8697 * server.c (handle_query): Advertise support for target-side
8698 breakpoint condition evaluation.
8699 (process_point_options): New function.
8700 (process_serial_event): When inserting a breakpoint, check for
8701 a target-side condition that should be evaluated.
8702
8703 * mem-break.c: Include regcache.h and ax.h.
8704 (point_cond_list_t): New data structure.
8705 (breakpoint) <cond_list>: New field.
8706 (find_gdb_breakpoint_at): Make non-static.
8707 (delete_gdb_breakpoint_at): Clear any target-side
8708 conditions.
8709 (clear_gdb_breakpoint_conditions): New function.
8710 (add_condition_to_breakpoint): Likewise.
8711 (add_breakpoint_condition): Likewise.
8712 (gdb_condition_true_at_breakpoint): Likewise.
8713 (gdb_breakpoint_here): Return result directly instead
8714 of going through a local variable.
8715
8716 * mem-break.h (find_gdb_breakpoint_at): New prototype.
8717 (clear_gdb_breakpoint_conditions): Likewise.
8718 (add_breakpoint_condition): Likewise.
8719 (gdb_condition_true_at_breakpoint): Likewise.
8720
8721 * linux-low.c (linux_wait_1): Evaluate target-side breakpoint condition.
8722 (need_step_over_p): Take target-side breakpoint condition into
8723 consideration.
8724
5e1dc496
LM
87252012-02-24 Luis Machado <lgustavo@codesourcery>
8726
8727 * server.h: Include tracepoint.h.
8728 (agent_mem_read, agent_get_trace_state_variable_value,
8729 agent_set_trace_state_variable_value,
8730 agent_tsv_read, agent_mem_read_string, get_get_tsv_func_addr,
8731 get_set_tsv_func_addr): New prototypes.
8732
8733 * ax.h: New include file.
8734 * ax.c: New source file.
8735
8736 * tracepoint.c: Include ax.h.
8737 (gdb_agent_op, gdb_agent_op_names, gdb_agent_op_sizes,
8738 agent_expr, eval_result_type): Move to ax.h.
8739 (parse_agent_expr): Rename to ...
8740 (gdb_parse_agent_expr): ... this, make it non-static and move
8741 to ax.h.
8742 (unparse_agent_expr) Rename to ...
8743 (gdb_unparse_agent_expr): ... this, make it non-static and move
8744 to ax.h.
8745 (eval_agent_expr): Rename to ...
8746 (eval_tracepoint_agent_expr): ... this.
8747 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Remove
8748 forward declarations.
8749 (add_tracepoint_action): Call gdb_parse_agent_expr (...).
8750 (agent_get_trace_state_variable_value): New function.
8751 (agent_set_trace_state_variable_value): New function.
8752 (cmd_qtdp): Call gdb_parse_agent_expr (...).
8753 (response_tracepoint): Call gdb_unparse_agent_expr (...).
8754 (do_action_at_tracepoint): Call eval_tracepoint_agent_expr (...).
8755 (condition_true_at_tracepoint): Likewise.
8756 (parse_agent_expr): Rename to ...
8757 (gdb_parse_agent_expr): ... this and move to ax.c.
8758 (unparse_agent_expr): Rename to ...
8759 (gdb_unparse_agent_expr): ... this and move to ax.c.
8760 (gdb_agent_op_name): Move to ax.c.
8761 (eval_agent_expr): Rename to ...
8762 (gdb_eval_agent_expr): ... this, use regcache passed as parameter
8763 and move to ax.c.
8764 (eval_tracepoint_agent_expr): New function.
8765 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Make
43aaf8b6 8766 non-static.
5e1dc496
LM
8767 (current_insn_ptr, emit_error, struct bytecode_address): Move to
8768 ax.c.
8769 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul, emit_lsh,
8770 emit_rsh_signed, emit_rsh_unsigned, emit_ext, emit_log_not,
8771 emit_bit_and, emit_bit_or, emit_bit_xor, emit_bit_not, emit_equal,
8772 emit_less_signed, emit_less_unsigned, emit_ref, emit_if_goto,
8773 emit_goto, write_goto_address, emit_const, emit_reg, emit_pop,
8774 emit_stack, emit_zero_ext, emit_swap, emit_stack_adjust,
8775 emit_int_call_1, emit_void_call_2, emit_eq_goto, emit_ne_goto,
8776 emit_lt_goto, emit_ge_goto, emit_gt_goto, emit_le_goto): Move to ax.c.
8777 (get_get_tsv_func_addr, get_set_tsv_func_addr): New functions.
8778 (compile_bytecodes): Remove forward declaration.
8779 (is_goto_target): Move to ax.c.
8780 (compile_bytecodes): Move to ax.c and call
8781 agent_get_trace_state_variable_value (...) and
8782 agent_set_trace_state_variable_value (...).
8783
8784 * Makefile.in: Update ax.c and IPA dependencies.
8785
277e4e52
PA
87862012-02-24 Pedro Alves <palves@redhat.com>
8787
8788 * tracepoint.c (cmd_bigqtbuffer): Rename as ...
8789 (cmd_bigqtbuffer_circular): ... this. Only handle
8790 'QTBuffer:circular:'.
8791 (handle_tracepoint_general_set): Adjust.
8792
bf4c19f7
YQ
87932012-02-16 Yao Qi <yao@codesourcery.com>
8794
8795 * inferiors.c: Move code to ...
8796 * dll.c: .... here. New.
8797 * server.h: Declare clear_dlls.
8798 * Makefile.in (SFILES): Add dll.c.
8799 (OBS): Add dll.o
8800 (dll.o): New rule.
8801
d73f2619
YQ
88022012-02-11 Yao Qi <yao@codesourcery.com>
8803
8804 * server.c: (handle_monitor_command): Add a new parameter
8805 `own_buf'.
8806 (handle_query): Update caller.
8807
f8255c2a
JB
88082012-02-09 Joel Brobecker <brobecker@adacore.com>
8809
8810 * configure.ac: Add readlink to AC_CHECK_FUNCS list.
8811 * configure, config.in: Regenerate.
8812 * hostio.c: Provide an alternate implementation if HAVE_READLINK
8813 is not defined.
8814
da84f473
PA
88152012-02-02 Pedro Alves <palves@redhat.com>
8816
8817 Try SIGKILL first, then PTRACE_KILL.
8818 * linux-low.c (linux_kill_one_lwp): New.
8819 (linux_kill_one_lwp): Rename to ...
8820 (kill_one_lwp_callback): ... this. Use the new
8821 linux_kill_one_lwp.
8822
e886a173
PA
88232012-02-02 Pedro Alves <palves@redhat.com>
8824
8825 * tracepoint.c (cmd_qtminftpilen): Return 0 if there's no current
8826 inferior.
8827
be07f1a2
PA
88282012-01-27 Pedro Alves <palves@redhat.com>
8829
8830 * linux-low.c (linux_child_pid_to_exec_file): Delete.
8831 (elf_64_file_p): Make static.
8832 (linux_pid_exe_is_elf_64_file): New.
8833 * linux-low.h (linux_child_pid_to_exec_file, elf_64_file_p):
8834 Delete declarations.
8835 (linux_pid_exe_is_elf_64_file): Declare.
8836 * linux-x86-low.c (x86_arch_setup): Use
8837 linux_pid_exe_is_elf_64_file.
8838
d8301ad1
JK
88392012-01-25 Jan Kratochvil <jan.kratochvil@redhat.com>
8840
8841 * linux-low.c (linux_wait_for_event_1): Rename to ...
8842 (linux_wait_for_event): ... here and merge it with former
8843 linux_wait_for_event - new variable wait_ptid, use it.
8844 (linux_wait_for_event): Remove - merge it to linux_wait_for_event_1.
8845
01b17894
PA
88462012-01-23 Pedro Alves <palves@redhat.com>
8847
8848 * server.c (main): Avoid yet another case of infinite loop while
8849 detaching/killing after a longjmp.
8850
e825046f
JK
88512012-01-20 Jan Kratochvil <jan.kratochvil@redhat.com>
8852
8853 Code cleanup.
8854 * linux-low.c (linux_wait_for_event_1): Use ptid_is_pid.
8855
b9e7b9c3
UW
88562012-01-20 Ulrich Weigand <ulrich.weigand@linaro.org>
8857
8858 * hostio.c (handle_readlink): New function.
8859 (handle_vFile): Call it to handle "vFile:readlink" packets.
8860
901f9912
UW
88612012-01-20 Pedro Alves <palves@redhat.com>
8862 Ulrich Weigand <ulrich.weigand@linaro.org>
8863
8864 * server.c (handle_v_requests): Only support vAttach and vRun to
8865 start multiple processes when in extended protocol mode.
8866
fc1ab1a0
PA
88672012-01-17 Pedro Alves <palves@redhat.com>
8868
8869 * tracepoint.c (initialize_tracepoint): Use mmap instead of
8870 memalign plus mprotect to allocate the scratch buffer.
8871
7d5d4e98
PA
88722012-01-13 Pedro Alves <palves@redhat.com>
8873
8874 * server.c (attach_inferior): Clear `cont_thread'.
8875
f128d5e9
PA
88762012-01-13 Pedro Alves <palves@redhat.com>
8877
8878 * server.c (main): Avoid infinite loop while detaching/killing
8879 after a longjmp.
8880
06db92f0
DE
88812012-01-09 Doug Evans <dje@google.com>
8882
8883 * server.c (start_inferior): Set last_ptid in --wrapper case.
8884
32d92999
YQ
88852012-01-06 Yao Qi <yao@codesourcery.com>
8886
8887 * tracepoint.c [IN_PROCESS_AGENT] (debug_threads): Macro
8888 defined.
8889 [IN_PROCESS_AGENT] (debug_agent): New global variable.
8890
5e0a92a9
YQ
88912012-01-04 Yao Qi <yao@codesourcery.com>
8892
8893 * tracepoint.c (cmd_qtdp): Print debug message
8894 for static tracepoint.
8895
ae639e8c
YQ
88962012-01-04 Yao Qi <yao@codesourcery.com>
8897
8898 * tracepoint.c (trace_vdebug): Differentiate debug message
8899 between gdbserver and IPA.
8900
f72429c5
YQ
89012012-01-03 Yao Qi <yao@codesourcery.com>
8902
8903 * tracepoint.c (tracepoint_was_hit): Don't collect for
8904 static tracepoint.
8905
12c3e59c
JB
89062012-01-02 Joel Brobecker <brobecker@adacore.com>
8907
8908 * terminal.h: Reformat copyright header.
8909
67827812
JB
89102012-01-02 Joel Brobecker <brobecker@adacore.com>
8911
8912 * server.c (gdbserver_version): Update copyright year.
8913 * gdbreplay.c (gdbreplay_version): Likewise.
8914
3e52c33d
JK
89152011-12-18 Jan Kratochvil <jan.kratochvil@redhat.com>
8916
8917 * linux-low.c (linux_create_inferior): Put empty if clause for write.
8918
8919 Revert:
8920 2011-12-18 Hui Zhu <teawater@gmail.com>
8921 * linux-low.c (linux_create_inferior): Save return value to ret.
8922
66f1260e
HZ
89232011-12-18 Hui Zhu <teawater@gmail.com>
8924
8925 * linux-low.c (linux_create_inferior): Save return value to ret.
8926
e77616d7
DE
89272011-12-16 Doug Evans <dje@google.com>
8928
e7b06c57
DE
8929 * linux-low.c (linux_create_inferior): If stdio connection,
8930 redirect stdin from /dev/null, stdout to stderr.
8931 * remote-utils.c (remote_is_stdio): New static global.
8932 (remote_connection_is_stdio): New function.
8933 (remote_prepare): Handle stdio connection.
8934 (remote_open): Ditto.
8935 (remote_close): Don't close stdin for stdio connections.
8936 (read_prim,write_prim): New functions. Replace all calls to
8937 read/write to these.
8938 * server.c (main): Watch for "-" argument. Move call to
8939 remote_prepare before start_inferior.
8940 * server.h (STDIO_CONNECTION_NAME): New macro.
8941 (remote_connection_is_stdio): Declare.
8942
e77616d7
DE
8943 * remote-utils.c (prepare_resume_reply): Remove extraneous \n
8944 in debugging output.
8945
82067193
YQ
89462011-12-15 Yao Qi <yao@codesourcery.com>
8947
8948 * tracepoint.c: Include sys/syscall.h.
8949 (gdb_ust_thread): Remove preprocessor conditional.
8950
82bfbe7e
PA
89512011-12-14 Pedro Alves <pedro@codesourcery.com>
8952
8953 * linux-low.c (linux_detach_one_lwp): Call
8954 the_low_target.prepare_to_resume before detaching.
8955
712c6575
YQ
89562011-12-14 Yao Qi <yao@codesourcery.com>
8957
8958 * tracepoint.c (gdb_ust_thread): Don't ignore return value
8959 of write.
8960
d54d1edf
YQ
89612011-12-14 Yao Qi <yao@codesourcery.com>
8962
8963 * i386-low.c (i386_low_stopped_data_address): Initialize local
8964 variable `control'.
8965
6210a125
PA
89662011-12-13 Pedro Alves <pedro@codesourcery.com>
8967
8968 PR remote/13492
8969
8970 * i386-low.c (i386_low_stopped_data_address): Avoid fetching
8971 DR_CONTROL unless necessary. Extend comments.
8972 * linux-x86-low.c (x86_linux_prepare_to_resume): Don't write to
8973 DR0-3 if not used. If any watchpoint was set, clear DR_STATUS.
8974
2ece8244
YQ
89752011-12-13 Yao Qi <yao@codesourcery.com>
8976
8977 * tracepoint.c (trace_buffer_alloc): Replace magic numbers with
8978 macros.
8979 (upload_fast_traceframes, upload_fast_traceframes): Likewise.
8980
784867a5
JK
89812011-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
8982
8983 * linux-low.c (linux_kill): Skip PTRACE_KILL if LWP does not exist.
8984 Print new debug message for such case.
8985
6bf36717
JK
89862011-12-06 Jan Kratochvil <jan.kratochvil@redhat.com>
8987
8988 Fix overlapping memcpy.
8989 * mem-break.c (set_raw_breakpoint_at): New variable buf. Use it for
8990 the read_inferior_memory transfer.
8991 (delete_fast_tracepoint_jump): New variable buf. Use it for the
8992 write_inferior_memory transfer.
8993 (set_fast_tracepoint_jump): New variable buf. Use it for the
8994 read_inferior_memory and write_inferior_memory transfers.
8995 (uninsert_fast_tracepoint_jumps_at, reinsert_fast_tracepoint_jumps_at)
8996 (delete_raw_breakpoint, uninsert_raw_breakpoint): New variable buf.
8997 Use it for the write_inferior_memory transfer.
8998 (check_mem_read, check_mem_write): New gdb_asserts for overlapping
8999 buffers.
9000
50275556
MR
90012011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
9002
9003 * linux-low.c (fetch_register, store_register): Make code
9004 consistent, fix formatting.
9005
7325beb4
MR
90062011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
9007
9008 * linux-low.c (usr_store_inferior_registers): Factor out code
9009 to handle individual registers into...
9010 (store_register): ... this new function.
9011
c642a434
UW
90122011-12-06 Ulrich Weigand <uweigand@de.ibm.com>
9013
9014 * Makefile.in (s390-linux32v1.o, s390-linux32v1.c): New rules.
9015 (s390-linux32v2.o, s390-linux32v2.c): Likewise.
9016 (s390-linux64v1.o, s390-linux64v1.c): Likewise.
9017 (s390-linux64v2.o, s390-linux64v2.c): Likewise.
9018 (s390x-linux64v1.o, s390x-linux64v1.c): Likewise.
9019 (s390x-linux64v2.o, s390x-linux64v2.c): Likewise.
9020 * configure.srv [s390*-*-linux*] (srv_regobj): Add new objects.
9021 (srv_xmlfiles): Add new XML files.
9022
9023 * linux-s390-low.c: Include "elf/common.h", <sys/ptrace.h>,
9024 and <sys/uio.h>.
9025 (PTRACE_GETREGSET, PTRACE_SETREGSET): Define if undefined.
9026 (init_registers_s390_linux32v1): Add prototype.
9027 (init_registers_s390_linux32v2): Likewise.
9028 (init_registers_s390_linux64v1): Likewise.
9029 (init_registers_s390_linux64v2): Likewise.
9030 (init_registers_s390x_linux64v1): Likewise.
9031 (init_registers_s390x_linux64v2): Likewise.
9032 (s390_num_regs): Increment to 52.
9033 (s390_regmap): Add orig_r2 register.
9034 (s390_num_regs_3264): Increment to 68.
9035 (s390_regmap_3264): Add orig_r2 register.
9036 (s390_collect_ptrace_register): Handle orig_r2 register.
9037 (s390_supply_ptrace_register): Likewise.
9038 (s390_fill_last_break): New function.
9039 (s390_store_last_break): Likewise.
9040 (s390_fill_system_call): New function.
9041 (s390_store_system_call): Likewise.
9042 (target_regsets): Handle NT_S390_LAST_BREAK and NT_S390_SYSTEM_CALL
9043 register sets.
9044 (s390_check_regset): New function.
9045 (s390_arch_setup): Check for presence of NT_S390_LAST_BREAK and
9046 NT_S390_SYSTEM_CALL regsets and use appropriate description.
9047 Update target_regsets for available register sets.
9048
2268b414
JK
90492011-12-02 Paul Pluzhnikov <ppluzhnikov@google.com>
9050 Jan Kratochvil <jan.kratochvil@redhat.com>
9051
9052 * linux-low.c (get_phdr_phnum_from_proc_auxv, get_dynamic, get_r_debug)
9053 (read_one_ptr, struct link_map_offsets, linux_qxfer_libraries_svr4):
9054 New.
9055 (struct linux_target_ops): Install linux_qxfer_libraries_svr4.
9056 * linux-low.h (struct process_info_private): New member r_debug.
9057 * server.c (handle_qxfer_libraries): Call
9058 the_target->qxfer_libraries_svr4.
9059 (handle_qxfer_libraries_svr4): New function.
9060 (qxfer_packets): New entry "libraries-svr4".
9061 (handle_query): Check QXFER_LIBRARIES_SVR4 and report libraries-svr4.
9062 * target.h (struct target_ops): New member qxfer_libraries_svr4.
9063 * remote.c (remote_xfer_partial): Call add_packet_config_cmd for
9064 PACKET_qXfer_libraries_svr4.
9065
d6db1fab
UW
90662011-11-30 Ulrich Weigand <uweigand@de.ibm.com>
9067
9068 * linux-s390-low.c (s390_collect_ptrace_register): Fully convert
9069 PSW address/mask between 8-byte and 16-byte formats.
9070 (s390_supply_ptrace_register): Likewise.
9071 (s390_get_pc, s390_set_pc): 4-byte PSW address always includes
9072 basic addressing mode bit.
9073
242f5f1c
SS
90742011-11-24 Stan Shebs <stan@codesourcery.com>
9075
9076 * tracepoint.c (cmd_qtstatus): Use plongest instead of %llx.
9077
f196051f
SS
90782011-11-17 Stan Shebs <stan@codesourcery.com>
9079
9080 * tracepoint.c (struct tracepoint): New field traceframe_usage.
9081 (tracing_start_time): New global.
9082 (tracing_stop_time): New global.
9083 (tracing_user_name): New global.
9084 (tracing_notes): New global.
9085 (tracing_stop_note): New global.
9086 (cmd_qtstart): Set traceframe_usage, start_time.
9087 (stop_tracing): Set stop_time.
9088 (cmd_qtstatus): Report additional status.
9089 (cmd_qtp): New function.
9090 (handle_tracepoint_query): Call it.
9091 (cmd_qtnotes): New function.
9092 (handle_tracepoint_general_set): Call it.
9093 (get_timestamp): Rename from tsv_get_timestamp.
9094
405f8e94
SS
90952011-11-14 Stan Shebs <stan@codesourcery.com>
9096 Kwok Cheung Yeung <kcy@codesourcery.com>
9097
9098 * linux-x86-low.c (small_jump_insn): New.
9099 (i386_install_fast_tracepoint_jump_pad): Add arguments for
9100 trampoline and error message, build a trampoline and issue a small
9101 jump instruction to it.
9102 (x86_install_fast_tracepoint_jump_pad): Add arguments for
9103 trampoline and error message.
9104 (x86_get_min_fast_tracepoint_insn_len): New.
9105 (the_low_target): Add call to x86_get_min_fast_tracepoint_insn_len.
9106 * linux-low.h (struct linux_target_ops): Add arguments to
9107 install_fast_tracepoint_jump_pad operation, add new operation.
9108 * linux-low.c (linux_install_fast_tracepoint_jump_pad): Add
9109 arguments.
9110 (linux_get_min_fast_tracepoint_insn_len): New function.
9111 (linux_target_op): Add new operation.
9112 * tracepoint.c (gdb_trampoline_buffer): New IPA variable.
9113 (gdb_trampoline_buffer_end): Ditto.
9114 (gdb_trampoline_buffer_error): Ditto.
9115 (struct ipa_sym_addresses): Add fields for new IPA variables.
9116 (symbol_list): Add entries for new IPA variables.
9117 (struct tracepoint): Add fields to hold the address range of the
9118 trampoline used by the tracepoint.
9119 (trampoline_buffer_head): New static variable.
9120 (trampoline_buffer_tail): Ditto.
9121 (claim_trampoline_space): New function.
9122 (have_fast_tracepoint_trampoline_buffer): New function.
9123 (clone_fast_tracepoint): Fill in trampoline fields of tracepoint
9124 structure.
9125 (install_fast_tracepoint): Ditto, also add error buffer argument.
9126 (cmd_qtminftpilen): New function.
9127 (handle_tracepoint_query): Add response to qTMinFTPILen packet.
9128 (fast_tracepoint_from_trampoline_address): New function.
9129 (fast_tracepoint_collecting): Handle trampoline as part of jump
9130 pad space.
9131 (set_trampoline_buffer_space): New function.
9132 (initialize_tracepoint): Initialize new IPA variables.
9133 * target.h (struct target_ops): Add arguments to
9134 install_fast_tracepoint_jump_pad operation, add new
9135 get_min_fast_tracepoint_insn_len operation.
9136 (target_get_min_fast_tracepoint_insn_len): New.
9137 (install_fast_tracepoint_jump_pad): Add arguments.
9138 * server.h (IPA_BUFSIZ): Define.
9139 * linux-i386-ipa.c: Include extra header files.
9140 (initialize_fast_tracepoint_trampoline_buffer): New function.
9141 (initialize_low_tracepoint): Call it.
9142 * server.h (set_trampoline_buffer_space): Declare.
9143 (claim_trampoline_space): Ditto.
9144 (have_fast_tracepoint_trampoline_buffer): Ditto.
9145
1e4d1764
YQ
91462011-11-14 Yao Qi <yao@codesourcery.com>
9147
9148 * server.c (handle_query): Handle InstallInTrace for qSupported.
9149 * tracepoint.c (add_tracepoint): Sort list.
9150 (install_tracepoint, download_tracepoint): New.
9151 (cmd_qtdp): Call them to install and download tracepoints.
9152 (sort_tracepoints): Removed.
9153 (cmd_qtstart): Update.
9154
5c73ff4e
YQ
91552011-11-14 Yao Qi <yao@codesourcery.com>
9156
9157 * mem-break.c (inc_ref_fast_tracepoint_jump): New.
9158 * mem-break.h: Declare.
9159 * tracepoint.c (cmd_qtstart): Move some code to ...
9160 (clone_fast_tracepoint, install_fast_tracepoint): ... here.
9161 New.
9162 (download_tracepoints): Move some code to ...
9163 (download_tracepoint_1): ... here. New.
9164
86a30030
YQ
91652011-11-08 Yao Qi <yao@codesourcery.com>
9166
9167 * remote-utils.c (relocate_instruction): A comment fix.
9168
8d26e50c
JB
91692011-11-07 Joel Brobecker <brobecker@adacore.com>
9170
9171 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): Delete.
9172 (i386_dr_low_get_control, i386_dr_low_get_status): Use
9173 dr_status_mirror and dr_control_mirror from debug_reg_state.
9174 (i386_dr_low_get_status): Use debug_reg_state.dr_status_mirror
9175 (i386_initial_stuff): Remove use of deleted globals.
9176 (i386_get_thread_context, i386_set_thread_context,
9177 i386_thread_added): Use dr_status_mirror and dr_control_mirror
9178 from debug_reg_state.
9179
a59306a3
YQ
91802011-11-05 Yao Qi <yao@codesourcery.com>
9181
9182 * tracepoint.c (gdb_collect): Loop over tracepoints of same
9183 address as TPOINT's.
9184
3065dfb6
SS
91852011-11-02 Stan Shebs <stan@codesourcery.com>
9186
9187 * tracepoint.c (agent_mem_read_string): New function.
9188 (eval_agent_expr): Call it for tracenz.
9189 * server.c (handle_query): Report support for tracenz.
9190
fd0d8c7c
YQ
91912011-11-02 Yao Qi <yao@codesourcery.com>
9192
9193 * tracepoint.c (cmd_qtstart): Remove unused local variables.
9194
609086b1
YQ
91952011-11-02 Yao Qi <yao@codesourcery.com>
9196
9197 * target.h: Fix a typo in comment.
9198
b9fd1791
PA
91992011-10-31 Pedro Alves <pedro@codesourcery.com>
9200
9201 * mem-break.c (check_mem_write): Add `myaddr' parameter. Don't
9202 clobber the breakpoints' shadows with fast tracepoint jumps.
9203 * mem-break.h (check_mem_write): Add `myaddr' parameter.
9204 * target.c (write_inferior_memory): Also pass MYADDR down to
9205 check_mem_write.
9206
03583c20
UW
92072011-10-07 Ulrich Weigand <ulrich.weigand@linaro.org>
9208
9209 * configure.ac: Check support for personality routine.
9210 * configure: Regenerate.
9211 * config.in: Likewise.
9212 * linux-low.c: Include <sys/personality.h>.
9213 Define ADDR_NO_RANDOMIZE if necessary.
9214 (linux_create_inferior): Disable address space randomization when
9215 forking inferior, if requested.
9216 (linux_supports_disable_randomization): New function.
9217 (linux_target_ops): Install it.
9218 * server.h (disable_randomization): Declare.
9219 * server.c (disable_randomization): New global variable.
9220 (handle_general_set): Handle QDisableRandomization.
9221 (handle_query): Likewise for qSupported.
9222 (main): Support --disable-randomization and --no-disable-randomization
9223 command line arguments.
9224 * target.h (struct target_ops): Add supports_disable_randomization.
9225 (target_supports_disable_randomization): New macro.
9226
723b724b
MF
92272011-09-29 Mike Frysinger <vapier@gentoo.org>
9228
9229 * linux-low.c (target_loadseg): Add defined PTRACE_GETFDPIC to the
9230 ifdef check.
9231 [PT_GETDSBT] (target_loadmap): Wrap in a defined PT_GETDSBT check.
9232 [!PT_GETDSBT] (target_loadmap): New definition.
9233 (LINUX_LOADMAP, LINUX_LOADMAP_EXEC, LINUX_LOADMAP_INTERP): Define.
9234 (linux_read_loadmap): Change PTRACE_GETDSBT_EXEC to
9235 LINUX_LOADMAP_EXEC, PTRACE_GETDSBT_INTERP to LINUX_LOADMAP_INTERP,
9236 and PT_GETDSBT to LINUX_LOADMAP.
9237 [!PT_GETDSBT] (linux_read_loadmap): Define to NULL.
9238 (linux_target_ops): Delete unnecessary ifdef PT_GETDSBT check.
9239
55329a5c 92402011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
71487fd7
UW
9241
9242 * linux-arm-low.c (struct arm_linux_hwbp_cap): Remove.
9243 (arm_linux_hwbp_cap): New static variable.
9244 (arm_linux_get_hwbp_cap): Replace by ...
9245 (arm_linux_init_hwbp_cap): ... this new function.
9246 (arm_linux_get_hw_breakpoint_count): Use arm_linux_hwbp_cap.
9247 (arm_linux_get_hw_watchpoint_count): Likewise.
9248 (arm_linux_get_hw_watchpoint_max_length): Likewise.
9249 (arm_arch_setup): Call arm_linux_init_hwbp_cap.
9250 (arm_prepare_to_resume): Use perror_with_name instead of error.
9251
55329a5c 92522011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
09b4ad9f
UW
9253
9254 * linux-arm-low.c: Include <signal.h>.
9255 (PTRACE_GETHBPREGS, PTRACE_SETHBPREGS): Define if necessary.
9256 (struct arm_linux_hwbp_cap): New data type.
9257 (arm_hwbp_type, arm_hwbp_control_t): New typedefs.
9258 (struct arm_linux_hw_breakpoint): New data type.
9259 (MAX_BPTS, MAX_WPTS): Define.
9260 (struct arch_process_info, struct arch_lwp_info): New data types.
9261 (arm_linux_get_hwbp_cap): New function.
9262 (arm_linux_get_hw_breakpoint_count): Likewise.
9263 (arm_linux_get_hw_watchpoint_count): Likewise.
9264 (arm_linux_get_hw_watchpoint_max_length): Likewise.
9265 (arm_hwbp_control_initialize): Likewise.
9266 (arm_hwbp_control_is_enabled): Likewise.
9267 (arm_hwbp_control_is_initialized): Likewise.
9268 (arm_hwbp_control_disable): Likewise.
9269 (arm_linux_hw_breakpoint_equal): Likewise.
9270 (arm_linux_hw_point_initialize): Likewise.
9271 (struct update_registers_data): New data structure.
9272 (update_registers_callback: New function.
9273 (arm_insert_point): Likewise.
9274 (arm_remove_point): Likewise.
9275 (arm_stopped_by_watchpoint): Likewise.
9276 (arm_stopped_data_address): Likewise.
9277 (arm_new_process): Likewise.
9278 (arm_new_thread): Likewise.
9279 (arm_prepare_to_resume): Likewise.
9280 (the_low_target): Register arm_insert_point, arm_remove_point,
9281 arm_stopped_by_watchpoint, arm_stopped_data_address, arm_new_process,
9282 arm_new_thread, and arm_prepare_to_resume.
9283
6b9801d4
SS
92842011-09-15 Stan Shebs <stan@codesourcery.com>
9285
9286 * server.h (struct emit_ops): Add compare-goto fields.
9287 * tracepoint.c (gdb_agent_op_sizes): New table.
9288 (emit_eq_goto): New function.
9289 (emit_ne_goto): New function.
9290 (emit_lt_goto): New function.
9291 (emit_le_goto): New function.
9292 (emit_gt_goto): New function.
9293 (emit_ge_goto): New function.
9294 (is_goto_target): New function.
9295 (compile_bytecodes): Recognize special cases of compare-goto
9296 combinations and call specialized emitters for them.
9297 * linux-x86-low.c (amd64_emit_eq_goto): New function.
9298 (amd64_emit_ne_goto): New function.
9299 (amd64_emit_lt_goto): New function.
9300 (amd64_emit_le_goto): New function.
9301 (amd64_emit_gt_goto): New function.
9302 (amd64_emit_ge_goto): New function.
9303 (amd64_emit_ops): Add the new functions.
9304 (i386_emit_eq_goto): New function.
9305 (i386_emit_ne_goto): New function.
9306 (i386_emit_lt_goto): New function.
9307 (i386_emit_le_goto): New function.
9308 (i386_emit_gt_goto): New function.
9309 (i386_emit_ge_goto): New function.
9310 (i386_emit_ops): Add the new functions.
9311
bf15cbda
SS
93122011-09-08 Stan Shebs <stan@codesourcery.com>
9313
9314 * linux-x86-low.c (i386_emit_prologue): Save %ebx.
9315 (i386_emit_epilogue): Restore %ebx.
9316
943ca1dd
JZ
93172011-08-31 Jie Zhang <jzhang918@gmail.com>
9318
9319 * server.c (step_thread): Remove definition.
9320 (process_serial_event): Don't handle Hs.
9321 * server.h (step_thread): Remove declaration.
9322 * target.c (set_desired_inferior): Remove use of step_thread.
9323
e3deef73
LM
93242011-08-24 Luis Machado <lgustavo@codesourcery.com>
9325
9326 * linux-low.c: Include linux-procfs.h.
9327 (linux_attach_lwp_1): Update comments.
9328 (linux_attach): Scan for existing threads when attaching to a
9329 process that is the tgid.
9330 * Makefile.in: Update dependencies.
9331
13da1c97
LM
93322011-08-24 Luis Machado <lgustavo@codesourcery.com>
9333
9334 * configure.srv: Add linux-procfs.o dependencies.
9335
881127c9
YQ
93362011-08-14 Yao Qi <yao@codesourcery.com>
9337
9338 * target.h (struct target_ops): Fix indent.
9339 * win32-low.c (win32_target_ops): Fix comment.
9340
58dbd541
YQ
93412011-08-14 Andrew Jenner <andrew@codesourcery.com>
9342 Yao Qi <yao@codesourcery.com>
9343
9344 * Makefile.in (clean): Remove tic6x-*.c files.
9345 (linux-tic6x-low.o, tic6x-c62x-linux.o, tic6x-c64x-linux.o): New rules.
9346 (tic6x-c64xp-linux.o, tic6x-c62x-linux.c, tic6x-c64x-linux.c): Likewise.
9347 (tic6x-c64xp-linux.c): Likewise.
9348 * configure.srv: Add support for tic6x-*-uclinux.
9349 * linux-tic6x-low.c: New.
9350 * linux-low.c (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define.
9351
78d85199
YQ
93522011-08-14 Andrew Stubbs <ams@codesourcery.com>
9353 Yao Qi <yao@codesourcery.com>
9354
9355 * target.h (struct target_ops): Add read_loadmap.
9356 * linux-low.c (struct target_loadseg): New type.
9357 (struct target_loadmap): New type.
9358 (linux_read_loadmap): New function.
9359 (linux_target_ops): Add linux_read_loadmap.
9360 * server.c (handle_query): Support qXfer:fdpic:read packet.
43aaf8b6
PA
9361 * win32-low.c (win32_target_ops): Initialize field `read_loadmap'
9362 to NULL.
78d85199 9363
a959a88d
EZ
93642011-08-05 Eli Zaretskii <eliz@gnu.org>
9365
9366 * win32-low.c: Include <stdint.h>.
9367
1ced966e
PA
93682011-07-22 Pedro Alves <pedro@codesourcery.com>
9369
9370 * i386-low.c (i386_insert_aligned_watchpoint): Don't pass the info
9371 to the inferior here.
9372 (i386_remove_aligned_watchpoint): Ditto.
9373 (i386_handle_nonaligned_watchpoint): Return immediate on fail to
9374 fit part of the watchpoint in the debug registers.
9375 (i386_update_inferior_debug_regs): New.
9376 (i386_low_insert_watchpoint): Work on a local mirror of the debug
9377 registers, and only update the inferior on success.
9378 (i386_low_remove_watchpoint): Ditto.
9379
d26e3629
KY
93802011-07-22 Kwok Cheung Yeung <kcy@codesourcery.com>
9381
9382 * linux-low.c (compare_ints, unique, list_threads, show_process,
9383 linux_core_of_thread): Delete.
9384 (linux_target_ops): Change linux_core_of_thread to
9385 linux_common_core_of_thread.
9386 (linux_qxfer_osdata): Defer to linux_common_xfer_osdata.
9387 * utils.c (malloc_failure): Change type of argument.
9388 (xmalloc, xrealloc, xcalloc, xsnprintf): Delete.
9389 * Makefile.in (SFILES): Add common/common-utils.c, common/xml-utils.c,
9390 common/linux-osdata.c, common/ptid.c and common/buffer.c.
9391 (OBS): Add xml-utils.o, common-utils.o, ptid.o and buffer.o.
9392 (IPA_OBJS): Add common-utils-ipa.o.
9393 (ptid_h, linux_osdata_h): New macros.
9394 (server_h): Add common/common-utils.h, common/xml-utils.h,
9395 common/buffer.h, common/gdb_assert.h, common/gdb_locale.h and
9396 common/ptid.h.
9397 (common-utils-ipa.o, common-utils.o, xml-utils.o, linux-osdata.o,
9398 ptid.o, buffer.o): New rules.
9399 (linux-low.o): Add common/linux-osdata.h as a dependency.
9400 * configure.srv (srv_tgtobj): Add linux-osdata.o to Linux targets.
9401 * configure.ac: Add AC_HEADER_DIRENT check.
9402 * config.in: Regenerate.
9403 * configure: Regenerate.
9404 * remote-utils.c (xml_escape_text): Delete.
9405 (buffer_grow, buffer_free, buffer_init, buffer_finish,
9406 buffer_xml_printf): Move to common/buffer.c.
9407 * server.c (main): Remove call to initialize_inferiors.
9408 * server.h (struct ptid, ptid_t, minus_one_ptid, null_ptid,
9409 ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp, ptid_get_tid,
9410 ptid_equal, ptid_is_pid, initialize_inferiors, xml_escape_text,
9411 internal_error, gdb_assert, gdb_assert_fail): Delete.
9412 (struct buffer, buffer_grow, buffer_free, buffer_init, buffer_finish,
9413 buffer_xml_printf, buffer_grow_str, buffer_grow_str0): Move to
9414 common/buffer.h.
9415 * inferiors.c (null_ptid, minus_one_ptid, ptid_build, pid_to_ptid,
9416 ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal, ptid_is_pid,
9417 initialize_inferiors): Delete.
9418
2275a1a7
PA
94192011-07-20 Pedro Alves <pedro@codesourcery.com>
9420
9421 * tracepoint.c (tracepoint_look_up_symbols): Return upon the first
9422 symbol error.
9423
0a5b1e09
PA
94242011-05-31 Pedro Alves <pedro@codesourcery.com>
9425
9426 * linux-x86-low.c (i386_dr_low_get_addr): Fix off by one in
9427 assertion.
9428 * win32-i386-low.c (i386_dr_low_get_addr): Ditto.
9429
6938fd34
YQ
94302011-05-26 Yao Qi <yao@codesourcery.com>
9431
9432 * Makefile.in (thread-db.o): Track dependence to
9433 common/gdb_thread_db.h.
9434 * thread-db.c: include gdb_thread_db.h from right place.
9435
b481f9e0
TT
94362011-05-16 Adrian Cornish <gnu@bluedreamer.com>
9437
9438 * linux-i386-ipa.c (supply_static_tracepoint_registers): Pass
9439 __FILE__ and __LINE__ to internal_error.
9440
98a5dd13
DE
94412011-05-13 Doug Evans <dje@google.com>
9442
9443 * thread-db.c (try_thread_db_load_from_sdir): New function.
9444 (try_thread_db_load_from_dir): New function.
9445 (thread_db_load_search): Handle $sdir, ignore $pdir.
9446 Remove trying of system directories if search of
9447 libthread-db-search-path fails, that is now done via $sdir.
9448
d248b706
KY
94492011-05-12 Kwok Cheung Yeung <kcy@codesourcery.com>
9450
9451 * server.c (handle_query): Add EnableDisableTracepoints to the list
9452 of supported features.
43aaf8b6 9453 * tracepoint.c (clear_installed_tracepoints): Uninstall disabled
d248b706 9454 tracepoints.
43aaf8b6
PA
9455 (cmd_qtenable_disable): New.
9456 (cmd_qtstart): Install tracepoints even if disabled.
9457 (handle_tracepoint_general_set): Add call to cmd_qtenable_disable on
9458 receiving a QTEnable or QTDisable packet.
9459 (gdb_collect): Skip data collection if fast tracepoint is disabled.
9460 (ust_marker_to_static_tracepoint): Do not ignore disabled static
9461 tracepoints.
9462 (gdb_probe): Skip data collection if static tracepoint is disabled.
d248b706 9463
84e578fb
DE
94642011-05-10 Doug Evans <dje@google.com>
9465
9466 * thread-db.c (thread_db_handle_monitor_command): Handle elided path.
9467
71f55dd8
DE
94682011-05-04 Doug Evans <dje@google.com>
9469
9470 * linux-low.c (linux_join): Skip process lookup.
9471 * spu-low.c (spu_join): Ditto.
9472 * server.c (join_inferiors_callback): Delete.
9473 (process_serial_event): For 'D' packet (detach) call join_inferior
9474 directly.
9475
4d393d60
JM
94762011-05-04 Joseph Myers <joseph@codesourcery.com>
9477
9478 * README: Don't mention xscale*-*-linux*.
9479 * configure.srv (xscale*-*-linux*): Don't handle target.
9480
b00ad6ff
NF
94812011-04-27 Nathan Froyd <froydnj@codesourcery.com>
9482
9483 * linux-x86-low.c (amd64_emit_const): Call memcpy instead of
9484 casting pointers.
9485 (amd64_emit_reg, amd64_emit_int_call_1, amd64_emit_void_call_2):
9486 (i386_emit_const, i386_emit_reg, i386_emit_int_call_1):
9487 (i386_emit_void_call_2): Likewise.
9488
af96c192
YQ
94892011-04-26 Yao Qi <yao@codesourcery.com>
9490
43aaf8b6
PA
9491 * linux-low.c: Move common macros to linux-ptrace.h.
9492 Include linux-ptrace.h.
af96c192
YQ
9493 * Makefile.in (linux_ptrace_h): New.
9494 (linux-low.o): Depends on linux-ptrace.h.
9495
03f2bd59
JK
94962011-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
9497
9498 * remote-utils.c (handle_accept_event): Close LISTEN_DESC only if
9499 RUN_ONCE. Comment for the LISTEN_DESC delete_file_handler call.
9500 (remote_prepare): New function with most of the TCP code from ...
9501 (remote_open): ... here. Detect PORT here unconditionally. Move also
9502 setting transport_is_reliable.
9503 * server.c (run_once): New variable.
9504 (gdbserver_usage): Document it.
9505 (main): Set run_once for `--once'. Call remote_prepare. Exit after
9506 the first run if RUN_ONCE.
9507 * server.h (run_once, remote_prepare): New declarations.
9508
7a9dd1b2
TT
95092011-04-19 Tom Tromey <tromey@redhat.com>
9510
9511 * win32-low.c (handle_load_dll): Remove duplicate "the".
9512
81239425
PM
95132011-04-07 Pierre Muller <muller@ics.u-strasbg.fr>
9514
9515 Remove support for old Cygwin 1.5 versions.
9516 * win32-low.c (win32_create_inferior): Use new cygwin_path_list
9517 function to avoid warning.
9518 (win32_add_one_solib): Use cygwin_conv_path function to avoid
9519 warning.
9520
9e0627f1
PM
95212011-03-18 Pierre Muller <muller@ics.u-strasbg.fr>
9522
9523 * gdbserver/server.h (Macro _): Define it if not available.
9524
588eebee
MS
95252011-03-14 Michael Snyder <msnyder@vmware.com>
9526
348af9f7 9527 * hostio.c (handle_close): Remove unnecessary null test.
588eebee 9528
43f70d4c
JB
95292011-03-10 Joel Brobecker <brobecker@adacore.com>
9530
9531 * Makefile.in (maintainer-clean realclean distclean): Remove
9532 "make ... subdir_do" command.
9533
348af9f7
MS
95342011-03-10 Michael Snyder <msnyder@vmware.com>
9535
9536 * tracepoint.c (tracepoint_finish_step): Fix loop variable.
9537
9538 * server.c (handle_v_run): Free alloced buffer on early return.
9539
e637a4f5
YQ
95402011-03-09 Yao Qi <yao@codesourcery.com>
9541
9542 Revert:
9543 2011-03-04 Yao Qi <yao@codesourcery.com>
9544
9545 * Makefile.in: Remove GNU make feature --directory.
9546
9547 2011-03-05 Yao Qi <yao@codesourcery.com>
9548
9549 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
9550 (subdir_do): New make target. Copied from gdb/Makefile.
9551 (maintainer-clean, realclean, distclean, clean): Call corresponding
9552 make targets in common/Makefile.
9553
9554 2011-02-11 Yao Qi <yao@codesourcery.com>
9555
9556 * configure.ac: Call AC_PROG_RANLIB.
9557 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
9558 * configure: Regenerate.
9559
e6edda56
JK
95602011-03-07 Jan Kratochvil <jan.kratochvil@redhat.com>
9561
9562 * remote-utils.c (putpkt_binary_1): Calculate BUF2 size dynamically.
9563
e5141119
JB
95642011-03-06 Yao Qi <yao@codesourcery.com>
9565
9566 * Makefile.in (REQUIRED_SUBDIRS): Remove $(LIBCOMMON_DIR).
9567
64794aa4
JB
95682011-03-05 Yao Qi <yao@codesourcery.com>
9569
9570 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
9571 (subdir_do): New make target. Copied from gdb/Makefile.
9572 (maintainer-clean, realclean, distclean, clean): Call corresponding
9573 make targets in common/Makefile.
9574
7a762829
YQ
95752011-03-04 Yao Qi <yao@codesourcery.com>
9576
9577 * Makefile.in: Remove GNU make feature --directory.
9578
348af9f7
MS
95792011-03-04 Michael Snyder <msnyder@vmware.com>
9580
9581 * server.c (queue_stop_reply): Call xmalloc not malloc.
9582
95832011-03-02 Michael Snyder <msnyder@vmware.com>
9584
9585 * linux-arm-low.c (arm_arch_setup): Replace malloc with xmalloc.
9586
9f72fee2
MS
95872011-02-28 Michael Snyder <msnyder@vmware.com>
9588
588eebee
MS
9589 * tracepoint.c (cmd_qtv): Discard unused value 'packet'.
9590 (cmd_qtframe): Ditto.
9591 (cmd_qtbuffer): Ditto.
9592 (cmd_bigqtbuffer): Ditto.
9593
9f72fee2
MS
9594 * utils.c (decimal2str): Initialize 'width' to nine, then
9595 don't mess with it.
9596
8040bd49
UW
95972011-02-28 Ulrich Weigand <uweigand@de.ibm.com>
9598
9599 * hostio.c (require_data): Free *data, not data.
9600
7e52cbd0
JK
96012011-02-28 Jan Kratochvil <jan.kratochvil@redhat.com>
9602
9603 * hostio.c (require_data): Use free, not xfree.
9604
9130f83e
MS
96052011-02-27 Michael Snyder <msnyder@vmware.com>
9606
4b812f4e
MS
9607 * server.c (handle_query): Discard unused value.
9608
9130f83e
MS
9609 * hostio.c (require_data): Free malloc memory before returning
9610 error.
9611
69d37113
MS
96122011-02-26 Michael Snyder <msnyder@vmware.com>
9613
9614 * linux-low.c (list_threads): Call closedir for dirent.
9615
35f5825a
MS
96162011-02-27 Michael Snyder <msnyder@vmware.com>
9617
2a589cef
MS
9618 * i386-low.c (i386-length_and_rw_bits): Comment the fact that
9619 a case statement falls through.
9620
0adea5f7
MS
9621 * linux-low.c (linux_xfer_siginfo): Fix fencepost error.
9622
35f5825a
MS
9623 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Fix fencepost error
9624 in comparison.
9625
238f1c74
MS
96262011-02-26 Michael Snyder <msnyder@vmware.com>
9627
9628 * utils.c (decimal2str): Eliminate dead code and dead param.
9629 (pulongest): Drop dead param from call to decimal2str.
9630 (plongest): Ditto.
9631
633ff500
JB
96322011-02-24 Joel Brobecker <brobecker@adacore.com>
9633
9634 Revert the following patch (not approved yet):
9635 2011-02-21 Hui Zhu <teawater@gmail.com>
9636 * tracepoint.c (tp_printf): New function.
9637 (eval_agent_expr): Handle gdb_agent_op_printf.
9638
f9c6ff72
HZ
96392011-02-21 Hui Zhu <teawater@gmail.com>
9640
9641 * tracepoint.c (tp_printf): New function.
9642 (eval_agent_expr): Handle gdb_agent_op_printf.
9643
94d5e490
TT
96442011-02-18 Tom Tromey <tromey@redhat.com>
9645
9646 * Makefile.in (tracepoint-ipa.o): Depend on ax.def.
9647 (tracepoint.o): Likewise.
9648 * tracepoint.c (enum gdb_agent_op): Use ax.def.
9649 (gdb_agent_op_names): Likewise.
9650
c7f96d2b
TT
96512011-02-18 Tom Tromey <tromey@redhat.com>
9652
9653 * tracepoint.c (enum gdb_agent_op) <gdb_agent_op_pick,
9654 gdb_agent_op_rot>: New constants.
9655 (gdb_agent_op_names): Add pick and roll.
9656 (eval_agent_expr) <gdb_agent_op_pick, gdb_agent_op_rot>: New
9657 cases.
9658
0feedb2c
JK
96592011-02-15 Jan Kratochvil <jan.kratochvil@redhat.com>
9660
9661 * aclocal.m4: Regenerated with aclocal-1.11.1.
9662
b3b9301e
PA
96632011-02-14 Pedro Alves <pedro@codesourcery.com>
9664
9665 * server.c (handle_qxfer_traceframe_info): New.
9666 (qxfer_packets): Register "traceframe-info".
9667 (handle_query): Report support for qXfer:traceframe-info:read+.
9668 * tracepoint.c (match_blocktype): New.
9669 (traceframe_find_block_type): Rename to ...
9670 (traceframe_walk_blocks): ... this. Add callback filter argument,
9671 and use it.
9672 (traceframe_find_block_type): New, reimplemented on top of
9673 traceframe_walk_blocks.
9674 (build_traceframe_info_xml): New.
9675 (traceframe_read_info): New.
9676 * server.h (traceframe_read_info): Declare.
9677
4f3e6fb7
YQ
96782011-02-11 Yao Qi <yao@codesourcery.com>
9679
9680 * configure.ac: Call AC_PROG_RANLIB.
9681 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
9682 * configure: Regenerate.
9683
764880b7
PA
96842011-02-07 Pedro Alves <pedro@codesourcery.com>
9685
9686 * server.c (gdb_read_memory): Change return semantics to allow
9687 partial transfers.
9688 (handle_search_memory_1): Adjust.
9689 (process_serial_event) <'m' packet>: Handle partial transfers.
9690 * tracepoint.c (traceframe_read_mem): Handle partial transfers.
9691
1c79eb8a
PA
96922011-01-28 Pedro Alves <pedro@codesourcery.com>
9693
9694 * regcache.c (init_register_cache): Initialize
9695 regcache->register_status.
9696 (free_register_cache): Release regcache->register_status.
9697 (regcache_cpy): Copy register_status.
9698 (registers_to_string): Print 'x's for unavailable registers.
9699 (supply_register): Mark the register's status valid or
9700 unavailable, depending on whether a buffer was passed in or not.
9701 (supply_register_zeroed): New.
9702 (supply_regblock): Mark the registers' status valid or
9703 unavailable, depending on whether a buffer was passed in or not.
9704 * regcache.h (REG_UNAVAILABLE, REG_VALID): New defines.
9705 (struct regcache): New `register_status' field.
9706 (supply_register_zeroed): Declare.
9707 * i387-fp.c (i387_xsave_to_cache): Zero out registers using
9708 supply_register_zeroed, rather than passing a NULL buffer to
9709 supply_register.
9710 * tracepoint.c (fetch_traceframe_registers): Update comment.
9711
85724a0e
PA
97122011-01-28 Pedro Alves <pedro@codesourcery.com>
9713
9714 * i387-fp.c (i387_xsave_to_cache): Make passing NULL as register
9715 buffer explicit.
9716
d08aafef
PA
97172011-01-25 Pedro Alves <pedro@codesourcery.com>
9718
9719 * server.h (decode_xfer_write): Change prototype.
9720 * remote-utils.c (decode_xfer_write): Remove `annex' parameter,
9721 and don't extract the annex here.
9722 * server.c (decode_xfer_read): Remove `annex' parameter,
9723 and don't extract the annex here.
9724 (decode_xfer): New.
9725 (struct qxfer): New.
9726 (handle_qxfer_auxv, handle_qxfer_features, handle_qxfer_libraries)
9727 (handle_qxfer_osdata, handle_qxfer_siginfo, handle_qxfer_spu)
9728 (handle_qxfer_statictrace): New functions, abstracted out from
9729 handle_query, and made to use the struct qxfer interface.
9730 (handle_threads_qxfer_proper): Rename to ...
9731 (handle_qxfer_threads_proper): ... this.
9732 (handle_threads_qxfer): Rename to ...
9733 (handle_qxfer_threads): ... this. Adjust.
9734 (qxfer_packets): New array.
9735 (handle_qxfer): New function.
9736 (handle_query): Use handle_qxfer.
9737
493e2a69
MS
97382011-01-05 Michael Snyder <msnyder@msnyder-server.eng.vmware.com>
9739
9740 * gdbreplay.c: Shorten lines of >= 80 columns.
9741 * linux-low.c: Ditto.
9742 * linux-ppc-low.c: Ditto.
9743 * linux-s390-low.c: Ditto.
9744 * linux-sparc-low.c: Ditto.
9745 * linux-x86-low.c: Ditto.
9746 * linux-xtensa-low.c: Ditto.
9747 * mem-break.c: Ditto.
9748 * nto-low.c: Ditto.
9749 * regcache.h: Ditto.
9750 * remote-utils.c: Ditto.
9751 * server.c: Ditto.
9752 * server.h: Ditto.
9753 * thread-db.c: Ditto.
9754 * tracepoint.c: Ditto.
9755 * utils.c: Ditto.
9756 * win32-low.h: Ditto.
9757
44944448
JB
97582011-01-05 Joel Brobecker <brobecker@adacore.com>
9759
9760 * gdbserver/configure.ac, gdbserver/gdbserver.1: Copyright year
9761 update.
9762
71ce852c
JB
97632011-01-01 Joel Brobecker <brobecker@adacore.com>
9764
9765 * server.c (gdbserver_version): Update copyright year in version
9766 output.
9767 * gdbreplay.c (gdbreplay_version): Ditto.
9768
eb826dc6
MF
97692010-12-29 Jie Zhang <jie.zhang@analog.com>
9770
9771 * configure.srv (bfin-*-*linux*): Handle Blackfin/Linux targets.
9772 * linux-bfin-low.c: New file.
9773 * linux-low.c: Define PT_TEXT_ADDR, PT_TEXT_END_ADDR, and
9774 PT_DATA_ADDR for BFIN targets.
9775 * Makefile.in (SFILES): Add linux-bfin-low.c.
9776 (clean): Remove reg-bfin.c.
9777 (linux-bfin-low.o, reg-bfin.o, reg-bfin.c): New targets.
9778 * README: Mention supported Blackfin targets.
9779
39ab222a
MF
97802010-12-23 Mike Frysinger <vapier@gentoo.org>
9781
9782 * .gitignore: New file.
9783
a1f2ce7d
MF
97842010-11-16 Mike Frysinger <vapier@gentoo.org>
9785
9786 * linux-low.c (linux_tracefork_child): Add char* cast to arg.
9787
f474844c
JZ
97882010-10-22 Jie Zhang <jie@codesourcery.com>
9789
9790 * Makefile.in: Add FLAGS_TO_PASS variable.
9791 (install): Remove dependency of install-only and recursively
9792 invoke make for install-only.
9793
f1048712
DE
97942010-10-04 Doug Evans <dje@google.com>
9795
9796 * Makefile.in (uninstall): Use $(DESTDIR).
9797
b53a1623
PA
97982010-09-24 Pedro Alves <pedro@codesourcery.com>
9799
e6ee044d
PA
9800 PR gdb/11842
9801
b53a1623
PA
9802 * linux-x86-low.c (compat_siginfo_from_siginfo)
9803 (siginfo_from_compat_siginfo): Also copy si_pid and si_uid when
9804 si_code is < 0. Check for si_code == SI_TIMER before checking for
9805 si_code < 0.
9806
fa1bd1e4
JB
98072010-09-13 Joel Brobecker <brobecker@adacore.com>
9808
9809 * lynx-i386-low.c: New file.
9810 * configure.srv: Add handling of i[34567]86-*-lynxos* targets.
9811
47fac8f8
JB
98122010-09-13 Joel Brobecker <brobecker@adacore.com>
9813
9814 * lynx-low.c (ptrace_request_to_str): Remove handling for
9815 request values that have been removed in LynxOS 5.x.
9816
1adfc54d
JB
98172010-09-13 Joel Brobecker <brobecker@adacore.com>
9818
9819 * lynx-low.c, lynx-ppc-loc.c: Include <sys/ptrace.h> instead of
9820 <ptrace.h>
9821
c2a66c29
NS
98222010-09-09 Nathan Sidwell <nathan@codesourcery.com>
9823
9824 * configure.ac: Add --enable-inprocess-agent option.
9825 * configure: Rebuilt.
9826
32fcada3
YQ
98272010-09-06 Yao Qi <yao@codesourcery.com>
9828
9829 * linux-low.c (linux_kill): Remove unused variable.
9830 (linux_stabilize_threads): Likewise.
9831 * server.c (start_inferior): Likewise.
9832 (queue_stop_reply_callback): Likewise.
9833 * tracepoint.c (do_action_at_tracepoint): Likewise.
9834
0cccb683
YQ
98352010-09-06 Yao Qi <yao@codesourcery.com>
9836
9837 * linux-low.c (maybe_move_out_of_jump_pad): Restore current_inferior
9838 on return.
9839
423ec54c
JK
98402010-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
9841
9842 * target.c (mywait) <TARGET_WAITKIND_EXITED>: Fix to use INTEGER.
9843
12ac6819
PA
98442010-09-06 Pedro Alves <pedro@codesourcery.com>
9845
9846 * Makefile.in (install-only): Replace $IPA_DEPFILES with
9847 "$(IPA_DEPFILES)".
9848
8ed54b31
JB
98492010-09-01 Joel Brobecker <brobecker@adacore.com>
9850
9851 * gdbserver/lynx-low.c, gdbserver/lynx-low.h,
9852 gdbserver/lynx-ppc-low.c: New files.
9853 * Makefile.in (lynx_low_h): New variable.
9854 (lynx-low.o, lynx-ppc-low.o): New rules.
9855 * configure.ac: On LynxOS, link with -lnetinet.
9856 * configure.srv: Add handling of powerpc-*-lynxos* targets.
9857 * configure: regenerate.
9858
bb0116a4
JB
98592010-09-01 Joel Brobecker <brobecker@adacore.com>
9860
9861 * Makefile.in (vasprintf.o, vsnprintf.o): New rules.
9862 * configure.ac: Add check for vasprintf and vsnprintf.
9863 * configure, config.in: Regenerate.
9864 * server.h (vasprintf, vsnprintf): Add conditional declarations.
9865
a778ab81 98662010-09-01 Joel Brobecker <brobecker@adacore.com>
9867
9868 * gdbreplay.c: Move include of alloca.h up, next to include of
9869 malloc.h.
9870 * server.h: Add include of malloc.h.
9871 * mem-break.c: Remove include of malloc.h.
9872 * server.c, tracepoint.c, utils.c, win32-low.c: Likewise.
9873
8b034a19 98742010-09-01 Joel Brobecker <brobecker@adacore.com>
9875
9876 * Makefile.in (memmem.o): Build with -Wno-error.
9877
98782010-09-01 Joel Brobecker <brobecker@adacore.com>
9879
9880 * utils.c (xsnprintf): Make non-static.
9881 * server.h: Add xsnprintf declaration.
9882 * linux-low.c, nto-low.c, target.c, thread-db.c, tracepoint.c:
9883 replace calls to snprintf by calls to xsnprintf throughout.
9884
98852010-09-01 Joel Brobecker <brobecker@adacore.com>
9886
9887 * configure.ac: Add configure check for alloca.
9888 * configure, config.in: Regenerate.
9889 * server.h: Include alloca.h if it exists.
9890 * gdbreplay.c: Include alloca.h if it exists.
9891
1a981360
PA
98922010-08-28 Pedro Alves <pedro@codesourcery.com>
9893
9894 * linux-low.c (__SIGRTMIN): Define if not already defined.
9895 (linux_create_inferior): Check for __ANDROID__ rather than
9896 __SIGRTMIN.
9897 (enqueue_one_deferred_signal): Don't requeue non-RT signals that
9898 are already deferred.
9899 (linux_wait_1): Check for __ANDROID__ rather than __SIGRTMIN.
9900 (linux_resume_one_thread): Don't queue a SIGSTOP if the lwp is
9901 stopped and already has a pending signal to report.
9902 (proceed_one_lwp): : Don't queue a SIGSTOP if the lwp already has
9903 a pending signal to report or is moving out of a jump pad.
9904 (linux_init_signals): Check for __ANDROID__ rather than
9905 __SIGRTMIN.
9906
b4d51a55
PA
99072010-08-28 Pedro Alves <pedro@codesourcery.com>
9908
9909 * linux-low.c (linux_stabilize_threads): Wrap debug output in a
9910 debug_threads check. Avoid a linear search when not doing debug
9911 output.
9912
ec48365d
PA
99132010-08-27 Pedro Alves <pedro@codesourcery.com>
9914
9915 * event-loop.c (event_handle_func): Adjust to use gdb_fildes_t.
9916 (struct gdb_event) <fd>: Change type to gdb_fildes_t.
9917 (struct file_handler) <fd>: Change type to gdb_fildes_t.
9918 (process_event): Change local fd's type to gdb_fildes_t.
9919 (create_file_handler): Adjust prototype.
9920 (delete_file_handler): Adjust prototype.
9921 (handle_file_event): Adjust prototype. Use pfildes.
9922 (create_file_event): Adjsut prototype.
9923 * remote-utils.c (remote_desc, listen_desc): Change type to
9924 gdb_fildes_t.
9925 * server.h: New gdb_fildes_t typedef.
9926 [USE_WIN32API]: Include winsock2.h.
9927 (delete_file_handler, add_file_handler): Adjust prototypes.
9928 (pfildes): Declare.
9929 * utils.c (pfildes): New.
9930
854d88f0
PA
99312010-08-27 Pedro Alves <pedro@codesourcery.com>
9932
9933 * configure.ac (build_warnings): Add -Wno-char-subscripts.
9934 * configure: Regenerate.
9935
0146f85b
PA
99362010-08-27 Pedro Alves <pedro@codesourcery.com>
9937
9938 * linux-low.c (linux_unprepare_to_access_memory): Rename to ...
9939 (linux_done_accessing_memory): ... this.
9940 (linux_target_ops): Adjust.
9941 * linux-x86-low.c (x86_insert_point, x86_remove_point): Adjust.
9942 * nto-low.c (nto_target_ops): Adjust comment.
9943 * server.c (gdb_read_memory, gdb_write_memory): Adjust.
9944 * spu-low.c (spu_target_ops): Adjust comment.
9945 * target.h (target_ops): Rename unprepare_to_access_memory field
9946 to done_accessing_memory.
9947 (unprepare_to_access_memory): Rename to ...
9948 (done_accessing_memory): ... this.
9949
90d74c30
PA
99502010-08-26 Pedro Alves <pedro@codesourcery.com>
9951
9952 * linux-low.c (linux_prepare_to_access_memory): New.
9953 (linux_unprepare_to_access_memory): New.
9954 (linux_target_ops): Install them.
9955 * server.c (read_memory): Rename to ...
9956 (gdb_read_memory): ... this. Use
9957 prepare_to_access_memory/prepare_to_access_memory.
9958 (write_memory): Rename to ...
9959 (gdb_write_memory): ... this. Use
9960 prepare_to_access_memory/prepare_to_access_memory.
9961 (handle_search_memory_1): Adjust.
9962 (process_serial_event): Adjust.
9963 * target.h (struct target_ops): New fields
9964 prepare_to_access_memory and unprepare_to_access_memory.
9965 (prepare_to_access_memory, unprepare_to_access_memory): New.
9966 * linux-x86-low.c (x86_insert_point, x86_remove_point): Use
9967 prepare_to_access_memory/prepare_to_access_memory.
9968 * nto-low.c (nto_target_ops): Adjust.
9969 * spu-low.c (spu_target_ops): Adjust.
9970 * win32-low.c (win32_target_ops): Adjust.
9971
fd467969
PA
99722010-08-26 Pedro Alves <pedro@codesourcery.com>
9973
9974 * Makefile.in (WARN_CFLAGS): Get it from configure.
9975 (WERROR_CFLAGS): New.
9976 (INTERNAL_CFLAGS): Add WERROR_CFLAGS.
9977 * configure.ac: Introduce --enable-werror, which adds -Werror to
9978 the compiler command line. Enabled by default. Disable with
9979 --disable-werror. Add -Wdeclaration-after-statement
9980 Wpointer-arith and -Wformat-nonliteral to warning flags.
9981 * configure: Regenerate.
9982
331e2f5f
PA
99832010-08-26 Pedro Alves <pedro@codesourcery.com>
9984
9985 * mem-break.c [HAVE_MALLOC_H]: Include malloc.h.
9986
e581f2b4
PA
99872010-08-26 Pedro Alves <pedro@codesourcery.com>
9988
9989 * gdbreplay.c (remote_error): New.
9990 (gdbchar): New.
9991 (expect): Use gdbchar. Check for error reading from GDB.
9992 Clarify sync error output.
9993 (play): Check for errors writing to GDB.
9994 * linux-low.c (sigchld_handler): Really ignore `write' errors.
9995 * remote-utils.c (getpkt): Check for errors writing to the remote
9996 descriptor.
9997
3c11dd79
PA
99982010-08-25 Pedro Alves <pedro@codesourcery.com>
9999
10000 * linux-low.c (linux_wait_1): Move non-debugging code out of
10001 `debug_threads' control.
10002
d20a8ad9
PA
100032010-08-25 Pedro Alves <pedro@codesourcery.com>
10004
10005 * linux-low.c (linux_wait_1): Don't set last_status here.
10006 * server.c (push_event, queue_stop_reply_callback): Assert we're
10007 not pushing a TARGET_WAITKIND_IGNORE event.
10008 (start_inferior, start_inferior, attach_inferior, handle_v_cont)
10009 (myresume, handle_target_event): Set the thread's last_resume_kind
10010 and last_status from the target returned status.
10011
964e4306
PA
100122010-08-25 Pedro Alves <pedro@codesourcery.com>
10013
10014 PR threads/10729
10015
10016 * linux-x86-low.c (update_debug_registers_callback): New.
10017 (i386_dr_low_set_addr): Use it.
10018 (i386_dr_low_get_addr): New.
10019 (i386_dr_low_set_control): Use update_debug_registers_callback.
10020 (i386_dr_low_get_control): New.
10021 (i386_dr_low_get_status): Adjust.
10022 * linux-low.c (linux_stop_lwp): New.
10023 * linux-low.h (linux_stop_lwp): Declare.
10024
10025 * i386-low.c (I386_DR_GET_RW_LEN): Take the dr7 contents as
10026 argument instead of a i386_debug_reg_state.
10027 (I386_DR_WATCH_HIT): Take the dr6 contents as argument instead of
10028 a i386_debug_reg_state.
10029 (i386_insert_aligned_watchpoint): Adjust.
10030 (i386_remove_aligned_watchpoint): Adjust.
10031 (i386_low_stopped_data_address): Read the debug registers from the
10032 inferior instead of from the mirrors.
10033 * i386-low.h (struct i386_debug_reg_state): Extend comment.
10034 (i386_dr_low_get_addr): Declare.
10035 (i386_dr_low_get_control): Declare.
10036 (i386_dr_low_get_status): Change prototype.
10037
10038 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): New globals.
10039 (i386_dr_low_get_addr): New.
10040 (i386_dr_low_get_control): New.
10041 (i386_dr_low_get_status): Adjust prototype. Return
10042 dr_status_mirror.
10043 (i386_initial_stuff): Clear dr_status_mirror and
10044 dr_control_mirror.
10045 (i386_get_thread_context): Adjust.
10046 (i386_set_thread_context): Adjust.
10047 (i386_thread_added): Adjust.
10048
5f21a75b
PA
100492010-08-24 Pedro Alves <pedro@codesourcery.com>
10050
10051 * linux-low.h (linux_thread_area): Delete declaration.
10052
3e4c1235
TS
100532010-08-11 Thomas Schwinge <thomas@codesourcery.com>
10054
10055 * linux-low.c (linux_wait_1): Correctly return the ptid of the child
10056 after its termination.
10057
1971b033
PA
100582010-08-09 Pedro Alves <pedro@codesourcery.com>
10059
10060 * linux-low.c (gdb_wants_lwp_stopped): Delete.
10061 (gdb_wants_all_stopped): Delete.
10062 (linux_wait_1): Don't call them.
10063 * server.c (handle_v_cont): Tag all threads as want-stopped.
10064 (gdb_wants_thread_stopped): Fix comments. Tag the thread that
10065 stopped as "client-wants-stopped".
10066
310444ac
PA
100672010-07-31 Pedro Alves <pedro@codesourcery.com>
10068
10069 * Makefile.in (signals_h): New.
10070 (server_h): Depend on it.
10071 (server.o): Don't depend on $(signals_def).
10072 (signals.o): Depend on $(signals_def).
10073
a19cae16
JK
100742010-07-31 Jan Kratochvil <jan.kratochvil@redhat.com>
10075
10076 * Makefile.in (signals_def): New.
10077 (server_h): Append include/gdb/signals.h and signals_def.
10078 (server.o): Append signals_def.
10079
30d50328
JK
100802010-07-25 Jan Kratochvil <jan.kratochvil@redhat.com>
10081
10082 * server.c (handle_target_event): Use target_signal_to_host for
10083 resume_info.sig initialization.
10084 * target.h (struct thread_resume) <sig>: New comment.
10085
5c3216e2
OS
100862010-07-20 Ozkan Sezer <sezeroz@gmail.com>
10087
c6f46ca0
OS
10088 * server.c (handle_query): strcpy() the returned string from paddress()
10089 instead of sprintf().
5c3216e2
OS
10090 * utils.c (paddress): Return phex_nz().
10091
6bd31874
JB
100922010-07-07 Joel Brobecker <brobecker@adacore.com>
10093
10094 * server.c (handle_v_cont): Call mourn_inferior if process
10095 just exited.
10096 (myresume): Likewise.
10097
0fb4aa4b
PA
100982010-07-01 Pedro Alves <pedro@codesourcery.com>
10099
10100 Static tracepoints, and integration with UST.
10101
10102 * configure.ac: Handle --with-ust. substitute ustlibs and ustinc.
10103 * mem-break.c (uninsert_all_breakpoints)
10104 (reinsert_all_breakpoints): New.
10105 * mem-break.h (reinsert_all_breakpoints, uninsert_all_breakpoints):
10106 * tracepoint.c (ust_loaded, helper_thread_id, cmd_buf): New.
10107 (gdb_agent_ust_loaded, helper_thread_id)
10108 (gdb_agent_helper_thread_id): New macros.
10109 (struct ipa_sym_addresses): Add addr_ust_loaded,
10110 addr_helper_thread_id, addr_cmd_buf.
10111 (symbol_list): Add ust_loaded, helper_thread_id, cmd_buf.
10112 (in_process_agent_loaded_ust): New.
10113 (write_e_ust_not_loaded): New.
10114 (maybe_write_ipa_ust_not_loaded): New.
10115 (struct collect_static_trace_data_action): New.
10116 (enum tracepoint_type) <static_tracepoint>: New.
10117 (struct tracepoint) <handle>: Mention static tracepoints.
10118 (struct static_tracepoint_ctx): New.
10119 (CMD_BUF_SIZE): New.
10120 (add_tracepoint_action): Handle static tracepoint actions.
10121 (unprobe_marker_at): New.
10122 (clear_installed_tracepoints): Handle static tracepoints.
10123 (cmd_qtdp): Handle static tracepoints.
10124 (probe_marker_at): New.
10125 (cmd_qtstart): Handle static tracepoints.
10126 (response_tracepoint): Handle static tracepoints.
10127 (cmd_qtfstm, cmd_qtsstm, cmd_qtstmat): New.
10128 (handle_tracepoint_query): Handle qTfSTM, qTsSTM and qTSTMat.
10129 (get_context_regcache): Handle static tracepoints.
10130 (do_action_at_tracepoint): Handle static tracepoint actions.
10131 (traceframe_find_block_type): Handle static trace data blocks.
10132 (traceframe_read_sdata): New.
10133 (download_tracepoints): Download static tracepoint actions.
10134 [HAVE_UST] Include ust/ust.h, dlfcn.h, sys/socket.h, and sys/un.h.
10135 (GDB_PROBE_NAME): New.
10136 (ust_ops): New.
10137 (GET_UST_SYM): New.
10138 (USTF): New.
10139 (dlsym_ust): New.
10140 (ust_marker_to_static_tracepoint): New.
10141 (gdb_probe): New.
10142 (collect_ust_data_at_tracepoint): New.
10143 (gdb_ust_probe): New.
10144 (UNIX_PATH_MAX, SOCK_DIR): New.
10145 (gdb_ust_connect_sync_socket): New.
10146 (resume_thread, stop_thread): New.
10147 (run_inferior_command): New.
10148 (init_named_socket): New.
10149 (gdb_ust_socket_init): New.
10150 (cstr_to_hexstr): New.
10151 (next_st): New.
10152 (first_marker, next_marker): New.
10153 (response_ust_marker): New.
10154 (cmd_qtfstm, cmd_qtsstm): New.
10155 (unprobe_marker_at, probe_marker_at): New.
10156 (cmd_qtstmat, gdb_ust_thread): New.
10157 (gdb_ust_init): New.
10158 (initialize_tracepoint_ftlib): Call gdb_ust_init.
10159 * linux-amd64-ipa.c [HAVE_UST]: Include ust/processor.h
10160 (ST_REGENTRY): New.
10161 (x86_64_st_collect_regmap): New.
10162 (X86_64_NUM_ST_COLLECT_GREGS): New.
10163 (AMD64_RIP_REGNUM): New.
10164 (supply_static_tracepoint_registers): New.
10165 * linux-i386-ipa.c [HAVE_UST]: Include ust/processor.h
10166 (ST_REGENTRY): New.
10167 (i386_st_collect_regmap): New.
10168 (i386_NUM_ST_COLLECT_GREGS): New.
10169 (supply_static_tracepoint_registers): New.
10170 * server.c (handle_query): Handle qXfer:statictrace:read.
10171 <qSupported>: Report support for StaticTracepoints, and
10172 qXfer:statictrace:read features.
10173 * server.h (traceframe_read_sdata)
10174 (supply_static_tracepoint_registers): Declare.
10175 * remote-utils.c (convert_int_to_ascii, hexchars, ishex, tohex)
10176 (unpack_varlen_hex): Include in IPA build.
10177 * Makefile.in (ustlibs, ustinc): New.
10178 (IPA_OBJS): Add remote-utils-ipa.o.
10179 ($(IPA_LIB)): Link -ldl and -lpthread.
10180 (UST_CFLAGS): New.
10181 (IPAGENT_CFLAGS): Add UST_CFLAGS.
10182 * config.in, configure: Regenerate.
10183
9e4344e5
PA
101842010-06-20 Ian Lance Taylor <iant@google.com>
10185 Pedro Alves <pedro@codesourcery.com>
10186
10187 * linux-x86-low.c (always_true): Delete.
10188 (EMIT_ASM, EMIT_ASM32): Use an uncondition asm jmp instead of
10189 trying to fool the compiler with always_true.
10190
c6beb2cb
PA
101912010-06-20 Pedro Alves <pedro@codesourcery.com>
10192
10193 * tracepoint.c (condition_true_at_tracepoint): Don't run compiled
10194 conditions in gdbserver.
10195
d2ed6730
UW
101962010-06-19 Ulrich Weigand <uweigand@de.ibm.com>
10197
10198 * spu-low.c (spu_read_memory): Wrap around local store limit.
10199 (spu_write_memory): Likewise.
10200
4e29fb54
PA
102012010-06-15 Pedro Alves <pedro@codesourcery.com>
10202
10203 * linux-x86-low.c (amd64_emit_const, amd64_emit_void_call_2)
10204 (i386_emit_const, i386_emit_void_call_2): Replace int64_t uses with
10205 LONGEST uses.
10206 * server.h (struct emit_ops): Replace int64_t uses with LONGEST
10207 uses.
10208 * tracepoint.c (emit_const, emit_void_call_2): Replace int64_t
10209 uses with LONGEST uses.
10210
6a271cae
PA
102112010-06-14 Stan Shebs <stan@codesourcery.com>
10212 Pedro Alves <pedro@codesourcery.com>
10213
10214 Bytecode compiler.
10215
10216 * linux-x86-low.c: Include limits.h.
10217 (add_insns): New.
10218 (always_true): New.
10219 (EMIT_ASM): New.
10220 (EMIT_ASM32): New.
10221 (amd64_emit_prologue, amd64_emit_epilogue, amd64_emit_add)
10222 (amd64_emit_sub, amd64_emit_mul, amd64_emit_lsh)
10223 (amd64_emit_rsh_signed, amd64_emit_rsh_unsigned, amd64_emit_ext,
10224 (amd64_emit_log_not, amd64_emit_bit_and, amd64_emit_bit_or)
10225 (amd64_emit_bit_xor, amd64_emit_bit_not, amd64_emit_equal,
10226 (amd64_emit_less_signed, amd64_emit_less_unsigned, amd64_emit_ref,
10227 (amd64_emit_if_goto, amd64_emit_goto, amd64_write_goto_address)
10228 (amd64_emit_const, amd64_emit_call, amd64_emit_reg)
10229 (amd64_emit_pop, amd64_emit_stack_flush, amd64_emit_zero_ext)
10230 (amd64_emit_swap, amd64_emit_stack_adjust, amd64_emit_int_call_1)
10231 (amd64_emit_void_call_2): New.
10232 (amd64_emit_ops): New.
10233 (i386_emit_prologue, i386_emit_epilogue, i386_emit_add)
10234 (i386_emit_sub,i386_emit_mul, i386_emit_lsh, i386_emit_rsh_signed)
10235 (i386_emit_rsh_unsigned, i386_emit_ext, i386_emit_log_not)
10236 (i386_emit_bit_and, i386_emit_bit_or, i386_emit_bit_xor)
10237 (i386_emit_bit_not, i386_emit_equal, i386_emit_less_signed)
10238 (i386_emit_less_unsigned, i386_emit_ref, i386_emit_if_goto)
10239 (i386_emit_goto, i386_write_goto_address, i386_emit_const)
10240 (i386_emit_call, i386_emit_reg, i386_emit_pop)
10241 (i386_emit_stack_flush, i386_emit_zero_ext, i386_emit_swap)
10242 (i386_emit_stack_adjust, i386_emit_int_call_1)
10243 (i386_emit_void_call_2): New.
10244 (i386_emit_ops): New.
10245 (x86_emit_ops): New.
10246 (the_low_target): Install x86_emit_ops.
10247 * server.h (struct emit_ops): New.
10248 (get_raw_reg_func_addr): Declare.
10249 (current_insn_ptr, emit_error): Declare.
10250 * tracepoint.c (get_raw_reg, get_trace_state_variable_value)
10251 (set_trace_state_variable_value): New defines.
10252 (struct ipa_sym_addresses): New fields addr_get_raw_reg,
10253 addr_get_trace_state_variable_value and
10254 addr_set_trace_state_variable_value.
10255 (symbol_list): New fields for get_raw_reg,
10256 get_trace_state_variable_value and set_trace_state_variable_value.
10257 (condfn): New typedef.
10258 (struct tracepoint): New field `compiled_cond'.
10259 (do_action_at_tracepoint): Clear compiled_cond.
10260 (get_trace_state_variable_value, set_trace_state_variable_value):
10261 Export in the IPA.
10262 (condition_true_at_tracepoint): If there's a compiled condition,
10263 run that.
10264 (current_insn_ptr, emit_error): New globals.
10265 (struct bytecode_address): New.
10266 (get_raw_reg_func_addr): New.
10267 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul)
10268 (emit_lsh, emit_rsh_signed, emit_rsh_unsigned, emit_ext)
10269 (emit_log_not, emit_bit_and, emit_bit_or, emit_bit_xor)
10270 (emit_bit_not, emit_equal, emit_less_signed, emit_less_unsigned)
10271 (emit_ref, emit_if_goto, emit_goto, write_goto_address, emit_const)
10272 (emit_reg, emit_pop, emit_stack_flush, emit_zero_ext, emit_swap)
10273 (emit_stack_adjust, emit_int_call_1, emit_void_call_2): New.
10274 (compile_tracepoint_condition, compile_bytecodes): New.
10275 * target.h (emit_ops): Forward declare.
10276 (struct target_ops): New field emit_ops.
10277 (target_emit_ops): New.
10278 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): New.
10279 * linux-i386-ipa.c (gdb_agent_get_raw_reg): New.
10280 * linux-low.c (linux_emit_ops): New.
10281 (linux_target_ops): Install it.
10282 * linux-low.h (struct linux_target_ops): New field emit_ops.
10283
92b72907
UW
102842010-06-14 Ulrich Weigand <uweigand@de.ibm.com>
10285
10286 * linux-ppc-low.c (ppc_arch_setup): Use private regcache to test MSR.
10287 * linux-s390-low.c (ppc_arch_setup): Use private regcache to test PSW.
10288
fa593d66
PA
102892010-06-01 Pedro Alves <pedro@codesourcery.com>
10290 Stan Shebs <stan@codesourcery.com>
10291
10292 * Makefile.in (IPA_DEPFILES, extra_libraries): New.
10293 (all): Depend on $(extra_libraries).
10294 (install-only): Install the IPA.
10295 (IPA_OBJS, IPA_LIB): New.
10296 (clean): Remove the IPA lib.
10297 (IPAGENT_CFLAGS): New.
10298 (tracepoint-ipa.o, utils-ipa.o, remote-utils-ipa.o)
10299 (regcache-ipa.o, i386-linux-ipa.o, linux-i386-ipa.o)
10300 (linux-amd64-ipa.o, amd64-linux-ipa.o): New rules.
10301 * linux-amd64-ipa.c, linux-i386-ipa.c: New files.
10302 * configure.ac: Check for atomic builtins support in the compiler.
10303 (IPA_DEPFILES, extra_libraries): Define.
10304 * configure.srv (ipa_obj): Add description.
10305 (ipa_i386_linux_regobj, ipa_amd64_linux_regobj): Define.
10306 (i[34567]86-*-linux*): Set ipa_obj.
10307 (x86_64-*-linux*): Set ipa_obj.
10308 * linux-low.c (stabilizing_threads): New.
10309 (supports_fast_tracepoints): New.
10310 (linux_detach): Stabilize threads before detaching.
10311 (handle_tracepoints): Handle internal tracing breakpoints. Assert
10312 the lwp is either not stabilizing, or is moving out of a jump pad.
10313 (linux_fast_tracepoint_collecting): New.
10314 (maybe_move_out_of_jump_pad): New.
10315 (enqueue_one_deferred_signal): New.
10316 (dequeue_one_deferred_signal): New.
10317 (linux_wait_for_event_1): If moving out of a jump pad, defer
10318 pending signals to later.
10319 (linux_stabilize_threads): New.
10320 (linux_wait_1): Check if threads need moving out of jump pads, and
10321 do it if so.
10322 (stuck_in_jump_pad_callback): New.
10323 (move_out_of_jump_pad_callback): New.
10324 (lwp_running): New.
10325 (linux_resume_one_lwp): Handle moving out of jump pads.
10326 (linux_set_resume_request): Dequeue deferred signals.
10327 (need_step_over_p): Also step over fast tracepoint jumps.
10328 (start_step_over): Also uninsert fast tracepoint jumps.
10329 (finish_step_over): Also reinsert fast tracepoint jumps.
10330 (linux_install_fast_tracepoint_jump): New.
10331 (linux_target_ops): Install linux_stabilize_threads and
10332 linux_install_fast_tracepoint_jump_pad.
10333 * linux-low.h (linux_target_ops) <get_thread_area,
10334 install_fast_tracepoint_jump_pad>: New fields.
10335 (struct lwp_info) <collecting_fast_tracepoint,
10336 pending_signals_to_report, exit_jump_pad_bkpt>: New fields.
10337 (linux_get_thread_area): Declare.
10338 * linux-x86-low.c (jump_insn): New.
10339 (x86_get_thread_area): New.
10340 (append_insns): New.
10341 (push_opcode): New.
10342 (amd64_install_fast_tracepoint_jump_pad): New.
10343 (i386_install_fast_tracepoint_jump_pad): New.
10344 (x86_install_fast_tracepoint_jump_pad): New.
10345 (the_low_target): Install x86_get_thread_area and
10346 x86_install_fast_tracepoint_jump_pad.
10347 * mem-break.c (set_raw_breakpoint_at): Use read_inferior_memory.
10348 (struct fast_tracepoint_jump): New.
10349 (fast_tracepoint_jump_insn): New.
10350 (fast_tracepoint_jump_shadow): New.
10351 (find_fast_tracepoint_jump_at): New.
10352 (fast_tracepoint_jump_here): New.
10353 (delete_fast_tracepoint_jump): New.
10354 (set_fast_tracepoint_jump): New.
10355 (uninsert_fast_tracepoint_jumps_at): New.
10356 (reinsert_fast_tracepoint_jumps_at): New.
10357 (set_breakpoint_at): Use write_inferior_memory.
10358 (uninsert_raw_breakpoint): Use write_inferior_memory.
10359 (check_mem_read): Mask out fast tracepoint jumps.
10360 (check_mem_write): Mask out fast tracepoint jumps.
10361 * mem-break.h (struct fast_tracepoint_jump): Forward declare.
10362 (set_fast_tracepoint_jump): Declare.
10363 (delete_fast_tracepoint_jump)
10364 (fast_tracepoint_jump_here, uninsert_fast_tracepoint_jumps_at)
10365 (reinsert_fast_tracepoint_jumps_at): Declare.
10366 * regcache.c: Don't compile many functions when building the
10367 in-process agent library.
10368 (init_register_cache) [IN_PROCESS_AGENT]: Don't allow allocating
10369 the register buffer in the heap.
10370 (free_register_cache): If the register buffer isn't owned by the
10371 regcache, don't free it.
10372 (set_register_cache) [IN_PROCESS_AGENT]: Don't re-alocate
10373 pre-existing register caches.
10374 * remote-utils.c (convert_int_to_ascii): Constify `from' parameter
10375 type.
10376 (convert_ascii_to_int): : Constify `from' parameter type.
10377 (decode_M_packet, decode_X_packet): Replace the `to' parameter by
10378 a `to_p' pointer to pointer parameter. If TO_P is NULL, malloc
10379 the needed buffer in-place.
10380 (relocate_instruction): New.
10381 * server.c (handle_query) <qSymbols>: If the target supports
10382 tracepoints, give it a chance of looking up symbols. Report
10383 support for fast tracepoints.
10384 (handle_status): Stabilize threads.
10385 (process_serial_event): Adjust.
10386 * server.h (struct fast_tracepoint_jump): Forward declare.
10387 (struct process_info) <fast_tracepoint_jumps>: New field.
10388 (convert_ascii_to_int, convert_int_to_ascii): Adjust.
10389 (decode_X_packet, decode_M_packet): Adjust.
10390 (relocate_instruction): Declare.
10391 (in_process_agent_loaded): Declare.
10392 (tracepoint_look_up_symbols): Declare.
10393 (struct fast_tpoint_collect_status): Declare.
10394 (fast_tracepoint_collecting): Declare.
10395 (force_unlock_trace_buffer): Declare.
10396 (handle_tracepoint_bkpts): Declare.
10397 (initialize_low_tracepoint)
10398 (supply_fast_tracepoint_registers) [IN_PROCESS_AGENT]: Declare.
10399 * target.h (struct target_ops) <stabilize_threads,
10400 install_fast_tracepoint_jump_pad>: New fields.
10401 (stabilize_threads, install_fast_tracepoint_jump_pad): New.
10402 * tracepoint.c [HAVE_MALLOC_H]: Include malloc.h.
10403 [HAVE_STDINT_H]: Include stdint.h.
10404 (trace_debug_1): Rename to ...
10405 (trace_vdebug): ... this.
10406 (trace_debug): Rename to ...
10407 (trace_debug_1): ... this. Add `level' parameter.
10408 (trace_debug): New.
10409 (ATTR_USED, ATTR_NOINLINE): New.
10410 (IP_AGENT_EXPORT): New.
10411 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
10412 (collecting, gdb_collect, stop_tracing, flush_trace_buffer)
10413 (about_to_request_buffer_space, trace_buffer_is_full)
10414 (stopping_tracepoint, expr_eval_result, error_tracepoint)
10415 (tracepoints, tracing, trace_buffer_ctrl, trace_buffer_ctrl_curr)
10416 (trace_buffer_lo, trace_buffer_hi, traceframe_read_count)
10417 (traceframe_write_count, traceframes_created)
10418 (trace_state_variables)
10419 New renaming defines.
10420 (struct ipa_sym_addresses): New.
10421 (STRINGIZE_1, STRINGIZE, IPA_SYM): New.
10422 (symbol_list): New.
10423 (ipa_sym_addrs): New.
10424 (all_tracepoint_symbols_looked_up): New.
10425 (in_process_agent_loaded): New.
10426 (write_e_ipa_not_loaded): New.
10427 (maybe_write_ipa_not_loaded): New.
10428 (tracepoint_look_up_symbols): New.
10429 (debug_threads) [IN_PROCESS_AGENT]: New.
10430 (read_inferior_memory) [IN_PROCESS_AGENT]: New.
10431 (UNKNOWN_SIDE_EFFECTS): New.
10432 (stop_tracing): New.
10433 (flush_trace_buffer): New.
10434 (stop_tracing_bkpt): New.
10435 (flush_trace_buffer_bkpt): New.
10436 (read_inferior_integer): New.
10437 (read_inferior_uinteger): New.
10438 (read_inferior_data_pointer): New.
10439 (write_inferior_data_pointer): New.
10440 (write_inferior_integer): New.
10441 (write_inferior_uinteger): New.
10442 (struct collect_static_trace_data_action): Delete.
10443 (enum tracepoint_type): New.
10444 (struct tracepoint) <type>: New field `type'.
43aaf8b6
PA
10445 <actions_str, step_actions, step_actions_str>: Only include in
10446 GDBserver.
fa593d66
PA
10447 <orig_size, obj_addr_on_target, adjusted_insn_addr>
10448 <adjusted_insn_addr_end, jump_pad, jump_pad_end>: New fields.
10449 (tracepoints): Use IP_AGENT_EXPORT.
10450 (last_tracepoint): Don't include in the IPA.
10451 (stopping_tracepoint): Use IP_AGENT_EXPORT.
10452 (trace_buffer_is_full): Use IP_AGENT_EXPORT.
10453 (alloced_trace_state_variables): New.
10454 (trace_state_variables): Use IP_AGENT_EXPORT.
10455 (traceframe_t): Delete unused variable.
10456 (circular_trace_buffer): Don't include in the IPA.
10457 (trace_buffer_start): Delete.
10458 (struct trace_buffer_control): New.
10459 (trace_buffer_free): Delete.
10460 (struct ipa_trace_buffer_control): New.
10461 (GDBSERVER_FLUSH_COUNT_MASK, GDBSERVER_FLUSH_COUNT_MASK_PREV)
10462 (GDBSERVER_FLUSH_COUNT_MASK_CURR, GDBSERVER_UPDATED_FLUSH_COUNT_BIT):
10463 New.
10464 (trace_buffer_ctrl): New.
10465 (TRACE_BUFFER_CTRL_CURR): New.
10466 (trace_buffer_start, trace_buffer_free, trace_buffer_end_free):
10467 Reimplement as macros.
10468 (trace_buffer_wrap): Delete.
10469 (traceframe_write_count, traceframe_read_count)
10470 (traceframes_created, tracing): Use IP_AGENT_EXPORT.
10471 (struct tracepoint_hit_ctx) <type>: New field.
10472 (struct fast_tracepoint_ctx): New.
10473 (memory_barrier): New.
10474 (cmpxchg): New.
10475 (record_tracepoint_error): Update atomically in the IPA.
10476 (clear_inferior_trace_buffer): New.
10477 (about_to_request_buffer_space): New.
10478 (trace_buffer_alloc): Handle GDBserver and inferior simulatenous
10479 updating the same buffer.
10480 (add_tracepoint): Default the tracepoint's type to trap
10481 tracepoint, and orig_size to -1.
10482 (get_trace_state_variable) [IN_PROCESS_AGENT]: Handle allocated
10483 internal variables.
10484 (create_trace_state_variable): New parameter `gdb'. Handle it.
10485 (clear_installed_tracepoints): Clear fast tracepoint jumps.
10486 (cmd_qtdp): Handle fast tracepoints.
10487 (cmd_qtdv): Adjust.
10488 (max_jump_pad_size): New.
10489 (gdb_jump_pad_head): New.
10490 (get_jump_space_head): New.
10491 (claim_jump_space): New.
10492 (sort_tracepoints): New.
10493 (MAX_JUMP_SIZE): New.
10494 (cmd_qtstart): Handle fast tracepoints. Sync tracepoints with the
10495 IPA.
10496 (stop_tracing) [IN_PROCESS_AGENT]: Don't include the tdisconnected
10497 support. Upload fast traceframes, and delete internal IPA
10498 breakpoints.
10499 (stop_tracing_handler): New.
10500 (flush_trace_buffer_handler): New.
10501 (cmd_qtstop): Upload fast tracepoints.
10502 (response_tracepoint): Handle fast tracepoints.
10503 (tracepoint_finished_step): Upload fast traceframes. Set the
10504 tracepoint hit context's tracepoint type.
10505 (handle_tracepoint_bkpts): New.
10506 (tracepoint_was_hit): Set the tracepoint hit context's tracepoint
10507 type. Add comment about fast tracepoints.
10508 (collect_data_at_tracepoint) [IN_PROCESS_AGENT]: Don't access the
10509 non-existing action_str field.
10510 (get_context_regcache): Handle fast tracepoints.
10511 (do_action_at_tracepoint) [!IN_PROCESS_AGENT]: Don't write the PC
10512 to the regcache.
10513 (fast_tracepoint_from_jump_pad_address): New.
10514 (fast_tracepoint_from_ipa_tpoint_address): New.
10515 (collecting_t): New.
10516 (force_unlock_trace_buffer): New.
10517 (fast_tracepoint_collecting): New.
10518 (collecting): New.
10519 (gdb_collect): New.
10520 (write_inferior_data_ptr): New.
10521 (target_tp_heap): New.
10522 (target_malloc): New.
10523 (download_agent_expr): New.
10524 (UALIGN): New.
10525 (download_tracepoints): New.
10526 (download_trace_state_variables): New.
10527 (upload_fast_traceframes): New.
10528 (IPA_FIRST_TRACEFRAME): New.
10529 (IPA_NEXT_TRACEFRAME_1): New.
10530 (IPA_NEXT_TRACEFRAME): New.
10531 [IN_PROCESS_AGENT]: Include sys/mman.h and fcntl.h.
10532 [IN_PROCESS_AGENT] (gdb_tp_heap_buffer, gdb_jump_pad_buffer)
10533 (gdb_jump_pad_buffer_end): New.
10534 [IN_PROCESS_AGENT] (initialize_tracepoint_ftlib): New.
10535 (initialize_tracepoint): Adjust.
10536 [IN_PROCESS_AGENT]: Allocate the IPA heap, and jump pad scratch
10537 buffer. Initialize the low module.
10538 * utils.c (PREFIX, TOOLNAME): New.
10539 (malloc_failure): Use PREFIX.
10540 (error): In the IPA, an error causes an exit.
10541 (fatal, warning): Use PREFIX.
10542 (internal_error): Use TOOLNAME.
10543 (NUMCELLS): Increase to 10.
10544 * configure, config.in: Regenerate.
10545
d149dd1d
PA
105462010-06-01 Pedro Alves <pedro@codesourcery.com>
10547
10548 * server.c (handle_query) <qSupported>: Do two passes over the
10549 qSupported string to avoid nesting strtok.
10550
f6528abd
JK
105512010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
10552
10553 * Makefile.in (SFILES): Add $(srcdir)/proc-service.list.
10554 (CDEPS): New.
10555 * configure.ac (RDYNAMIC): New AC_MSG_CHECKING wrapping. Test also
10556 -Wl,--dynamic-list.
10557 * configure: Regenerate.
10558 * proc-service.list: New.
10559
ca2a87a0
JK
105602010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
10561
10562 * linux-low.c (linux_core_of_thread): Fix crash on invalid CONTENT.
10563 New comment.
10564
363a6e9f
OS
105652010-05-26 Ozkan Sezer <sezeroz@gmail.com>
10566
10567 * gdbreplay.c (remote_open): Check error return from socket() call by
10568 its equality to -1 not by it being negative.
10569 * remote-utils.c (remote_open): Likewise.
10570
d23b6cb1
PA
105712010-05-23 Pedro Alves <pedro@codesourcery.com>
10572
10573 * config.h: Regenerate.
10574
28d3cf85
MK
105752010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
10576
10577 * linux-m68k-low.c (ps_get_thread_area): Don't define if kernel
10578 doesn't provide PTRACE_GET_THREAD_AREA.
10579
fea36a59
MK
105802010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
10581
10582 * linux-m68k-low.c: Include <asm/ptrace.h>
10583 (ps_get_thread_area): Implement.
10584
24b066ba
DE
105852010-05-03 Doug Evans <dje@google.com>
10586
10587 * event-loop.c (struct callback_event): New struct.
10588 (callback_list): New global.
10589 (append_callback_event, delete_callback_event): New functions.
10590 (process_callback): New function.
10591 (start_event_loop): Call it.
10592 * remote-utils.c (NOT_SCHEDULED): Define.
10593 (readchar_buf, readchar_bufcnt, readchar_bufp): New static globals,
10594 moved out of readchar.
10595 (readchar): Rewrite. Call reschedule before returning.
10596 (reset_readchar): New function.
10597 (remote_close): Call it.
10598 (process_remaining, reschedule): New functions.
10599 * server.h (callback_handler_func): New typedef.
10600 (append_callback_event, delete_callback_event): Declare.
10601
9836d6ea
PA
106022010-05-03 Pedro Alves <pedro@codesourcery.com>
10603
10604 * proc-service.c (ps_pglobal_lookup): Use
10605 thread_db_look_up_one_symbol.
10606 * remote-utils.c (look_up_one_symbol): Add new `may_ask_gdb'
10607 parameter. Use it instead of all_symbols_looked_up.
10608 * server.h (struct process_info) <all_symbols_looked_up>: Delete
10609 field.
10610 (all_symbols_looked_up): Don't declare.
10611 (look_up_one_symbol): Add new `may_ask_gdb' parameter.
10612 * thread-db.c (struct thread_db) <all_symbols_looked_up>: New
10613 field.
10614 (thread_db_look_up_symbols): Adjust call to look_up_one_symbol.
10615 Set all_symbols_looked_up here.
10616 (thread_db_look_up_one_symbol): New.
10617 (thread_db_get_tls_address): Adjust.
10618 (thread_db_load_search, try_thread_db_load_1): Always allocate the
10619 thread_db object on the heap, and tentatively set it in the
10620 process structure.
10621 (thread_db_init): Don't set all_symbols_looked_up here.
10622 * linux-low.h (thread_db_look_up_one_symbol): Declare.
10623
7984d532
PA
106242010-05-03 Pedro Alves <pedro@codesourcery.com>
10625
10626 * linux-low.c (linux_kill, linux_detach): Adjust.
10627 (status_pending_p_callback): Remove redundant statement. Check
10628 for !TARGET_WAITIKIND_IGNORE, instead of
10629 TARGET_WAITKIND_STOPPED.
10630 (handle_tracepoints): Make sure LWP is locked. Adjust.
10631 (linux_wait_for_event_1): Adjust.
10632 (linux_cancel_breakpoints): New.
10633 (unsuspend_one_lwp): New.
10634 (unsuspend_all_lwps): New.
10635 (linux_wait_1): If finishing a step-over, unsuspend all lwps.
10636 (send_sigstop_callback): Change return type to int, add new
10637 `except' parameter and handle it.
10638 (suspend_and_send_sigstop_callback): New.
10639 (stop_all_lwps): Add new `suspend' and `expect' parameters, and
10640 pass them down. If SUSPEND, also increment the lwp's suspend
10641 count.
10642 (linux_resume_one_lwp): Add notice about resuming a suspended LWP.
10643 (need_step_over_p): Don't consider suspended LWPs.
10644 (start_step_over): Adjust.
10645 (proceed_one_lwp): Change return type to int, add new `except'
10646 parameter and handle it.
10647 (unsuspend_and_proceed_one_lwp): New.
10648 (proceed_all_lwps): Use find_inferior instead of
10649 for_each_inferior.
10650 (unstop_all_lwps): Add `unsuspend' parameter. If UNSUSPEND, them
10651 also decrement the suspend count of LWPs. Pass `except' down,
10652 instead of hacking its suspend count.
10653 (linux_pause_all): Add `freeze' parameter. Adjust.
10654 (linux_unpause_all): New.
10655 (linux_target_ops): Install linux_unpause_all.
10656 * server.c (handle_status): Adjust.
10657 * target.h (struct target_ops): New fields `unpause_all' and
10658 `cancel_breakpoints'. Add new parameter to `pause_all'.
10659 (pause_all): Add new `freeze' parameter.
10660 (unpause_all): New.
10661 (cancel_breakpoints): New.
10662 * tracepoint.c (clear_installed_tracepoints): Pause threads, and
10663 cancel breakpoints.
10664 (cmd_qtstart): Pause threads.
10665 (stop_tracing): Pause threads, and cancel breakpoints.
10666 * win32-low.c (win32_target_ops): Adjust.
10667
e471f25b
PA
106682010-05-03 Pedro Alves <pedro@codesourcery.com>
10669
10670 * linux-low.c (linux_wait_for_event_1): Move passing the signal to
10671 the inferior right away from here...
10672 (linux_wait_1): ... to here, and adjust to check the thread's
10673 last_resume_kind instead of the lwp's step or stop_expected flags.
10674
1915ef4f
PA
106752010-05-02 Pedro Alves <pedro@codesourcery.com>
10676
10677 * README: Use consistent `GDB' and `GDBserver' spellings.
10678
f9e39928
PA
106792010-05-02 Pedro Alves <pedro@codesourcery.com>
10680
10681 * linux-low.c (linux_kill_one_lwp): Assume the lwp is stopped.
10682 (linux_kill): Stop all lwps here. Don't delete the main lwp here.
10683 (linux_detach_one_lwp): Assume the lwp is stopped.
10684 (any_thread_of): Delete.
10685 (linux_detach): Stop all lwps here. Don't blindly delete all
10686 breakpoints.
10687 (delete_lwp_callback): New.
10688 (linux_mourn): Delete all lwps of the process that is gone.
10689 (linux_wait_1): Don't delete the last lwp of the process here.
10690 * mem-break.h (mark_breakpoints_out): Declare.
10691 * mem-break.c (mark_breakpoints_out): New.
10692 (free_all_breakpoints): Use it.
10693 * server.c (handle_target_event): If the process is gone, mark
10694 breakpoints out.
10695 * thread-db.c (struct thread_db) <create_bp>: New field.
10696 (thread_db_enable_reporting): Fix prototype. Store a thread event
10697 breakpoint reference in the thread_db struct.
10698 (thread_db_load_search): Clear the thread_db object.
10699 (try_thread_db_load_1): Ditto.
10700 (switch_to_process): New.
10701 (disable_thread_event_reporting): Use it.
10702 (remove_thread_event_breakpoints): New.
10703 (thread_db_detach, thread_db_mourn): Use it.
10704
1e7fc18c
PA
107052010-05-01 Pedro Alves <pedro@codesourcery.com>
10706
10707 * linux-low.c (linux_enable_event_reporting): New.
10708 (linux_wait_for_event_1, handle_extended_wait): Use it.
10709
02fc4de7
PA
107102010-04-30 Pedro Alves <pedro@codesourcery.com>
10711
10712 * linux-low.c (linux_kill_one_lwp, linux_kill)
10713 (linux_detach_one_lwp): Adjust to send_sigstop interface change.
10714 (send_sigstop): Take an lwp_info as parameter instead. Queue a
10715 SIGSTOP even if the LWP is stopped.
10716 (send_sigstop_callback): New.
10717 (stop_all_lwps): Use send_sigstop_callback instead.
10718 (linux_resume_one_thread): Adjust.
10719 (proceed_one_lwp): Still proceed an LWP that the client has
10720 requested to stop, if we haven't reported it as stopped yet. Make
10721 sure that LWPs the client want stopped, have a pending SIGSTOP.
10722
bc3b5632
DE
107232010-04-26 Doug Evans <dje@google.com>
10724
ae1ada35
DE
10725 * server.c (handle_general_set): Make static.
10726
bc3b5632
DE
10727 * remote-utils.c (putpkt_binary_1): Call readchar instead of read.
10728 Print received char after testing for error/eof instead of before.
10729 (input_interrupt): Tweak comment.
10730
65730243
DE
107312010-04-23 Doug Evans <dje@google.com>
10732
10733 * server.c (start_inferior): Print inferior argv if --debug.
10734
a8ae7dc0
AR
107352010-04-21 Aleksandar Ristovski <aristovski@qnx.com>
10736
10737 * Makefile.in (nto_low_h nto-low.o nto-x86-low.o): New dependency lists.
10738 * nto-x86-low.c: Include server.h
10739
1c07cc19
PM
107402010-04-20 Pierre Muller <muller@ics.u-strasbg.fr>
10741
10742 * win32-i386-low.c: Use __x86_64__ macro instead of __x86_64 to
10743 be consistent with other sources of this directory.
10744 (init_registers_amd64): Correct name of source file of this function
10745 in the comment.
10746
e0a61e09
PM
107472010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
10748
10749 * configure.srv (x86_64-*-mingw*): New configuration for Windows
10750 64-bit executables.
10751
54709339
PM
107522010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
10753
10754 * win32-i386-low.c: Add 64-bit support.
10755 (CONTEXT_EXTENDED_REGISTERS): Set macro to zero if not exisiting.
10756 (init_registers_amd64): Declare.
10757 (mappings): Add 64-bit version of array.
10758 (init_windows_x86): New function.
10759 (the_low_target): Change init_arch field to init_windows_x86.
10760
e8f0053d
PM
107612010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
10762
10763 * win32-low.c: Adapt to support also 64-bit architecture.
10764 (child_xfer_memory): Use uintptr_t type for local variable `addr'.
10765 (get_image_name): Use SIZE_T type for local variable `done'.
10766 (psapi_get_dll_name): Use LPVOID type for parameter `BaseAddress'.
10767 (toolhelp_get_dll_name): Idem.
10768 (handle_load_dll): Use CORE_ADDR type for local variable `load_addr'.
10769 Use uintptr_t typecast to avoid warning.
10770 (handle_unload_dll): Use uintptr_t typecast to avoid warning.
10771 (handle_exception): Use phex_nz to avoid warning.
10772 (win32_wait): Remove unused local variable `process'.
10773
c481e77e
PM
107742010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
10775
10776 * configure.srv (srv_amd64_regobj): Replace `x86-64-avx.o' by
10777 `amd64-avx.o'.
10778
12ea4b69
PM
107792010-04-17 Pierre Muller <muller@ics.u-strasbg.fr>
10780
10781 * configure.ac: Use `ws2_32' library for srv_mingw.
10782 * configure: Regenerate.
10783 * gdbreplay.c: Include winsock2.h instead of winsock.h.
10784 * remote-utils.c: Likewise.
10785
f6d1620c
L
107862010-04-17 H.J. Lu <hongjiu.lu@intel.com>
10787
10788 * linux-x86-low.c (xmltarget_amd64_linux_no_xml): Define only
10789 if __x86_64__ is defined.
10790
8e642873
PM
107912010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
10792
10793 * configure: Regenerate.
10794
711e434b
PM
107952010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
10796
10797 * server.c (handle_query): Handle 'qGetTIBAddr' query.
10798 * target.h (target_ops): New get_tib_address field.
10799 * win32-low.h (win32_thread_info): Add thread_local_base field.
10800 * win32-low.c (child_add_thread): Add tlb argument.
10801 Set thread_local_base field to TLB.
10802 (get_child_debug_event): Adapt to child_add_thread change.
10803 (win32_get_tib_address): New function.
10804 (win32_target_ops): Set get_tib_address field to
10805 win32_get_tib_address.
10806 * linux-low.c (linux_target_ops): Set get_tib_address field to NULL.
10807
505106cd
PA
108082010-04-12 Pedro Alves <pedro@codesourcery.com>
10809
505106cd
PA
10810 * linux-low.c (linux_mourn): Also remove the process.
10811 * server.c (handle_target_event): Don't remove the process here.
10812 * nto-low.c (nto_mourn): New.
10813 (nto_target_ops): Install it.
10814 * spu-low.c (spu_mourn): New.
10815 (spu_target_ops): Install it.
10816 * win32-low.c (win32_mourn): New.
10817 (win32_target_ops): Install it.
10818
e8470a06
PA
108192010-04-12 Pedro Alves <pedro@codesourcery.com>
10820
10821 * server.h (buffer_xml_printf): Remove redundant `;'.
10822
45ba0d02
PA
108232010-04-12 Pedro Alves <pedro@codesourcery.com>
10824
10825 * regcache.c (set_register_cache): Invalidate regcaches before
10826 changing the register cache layout.
10827 (regcache_invalidate_one): Allow a NULL regcache.
10828 * linux-x86-low.c (x86_linux_update_xmltarget): Invalidate
10829 regcaches before changing the register cache layout or the target
10830 regsets.
10831
59e04013
L
108322010-04-12 H.J. Lu <hongjiu.lu@intel.com>
10833
10834 * linux-x86-low.c (x86_linux_update_xmltarget): Avoid unused
10835 variable warning on Linux/x86-64.
10836
8336d594
PA
108372010-04-11 Pedro Alves <pedro@codesourcery.com>
10838
10839 GDBserver disconnected tracing support.
10840
10841 * linux-low.c (linux_remove_process): Delete.
10842 (add_lwp): Don't set last_resume_kind here.
10843 (linux_kill): Use `mourn'.
10844 (linux_detach): Use `thread_db_detach', and `mourn'.
10845 (linux_mourn): New.
10846 (linux_attach_lwp_1): Adjust comment.
10847 (linux_attach): last_resume_kind moved the thread_info; adjust.
10848 (status_pending_p_callback): Adjust.
10849 (linux_wait_for_event_1): Adjust.
10850 (count_events_callback, select_singlestep_lwp_callback)
10851 (select_event_lwp_callback, cancel_breakpoints_callback)
10852 (db_wants_lwp_stopped, linux_wait_1, need_step_over_p)
10853 (proceed_one_lwp): Adjust.
10854 (linux_async): Add debug output.
10855 (linux_thread_stopped): New.
10856 (linux_pause_all): New.
10857 (linux_target_ops): Install linux_mourn, linux_thread_stopped and
10858 linux_pause_all.
10859 * linux-low.h (struct lwp_info): Delete last_resume_kind field.
10860 (thread_db_free): Delete declaration.
10861 (thread_db_detach, thread_db_mourn): Declare.
10862 * thread-db.c (thread_db_init): Use thread_db_mourn.
10863 (thread_db_free): Delete, split in two.
10864 (disable_thread_event_reporting): New.
10865 (thread_db_detach): New.
10866 (thread_db_mourn): New.
10867
10868 * server.h (struct thread_info) <last_resume_kind>: New field.
10869 <attached>: Add comment.
10870 <gdb_detached>: New field.
10871 (handler_func): Change return type to int.
10872 (handle_serial_event, handle_target_event): Ditto.
10873 (gdb_connected): Declare.
10874 (tracing): Delete.
10875 (disconnected_tracing): Declare.
10876 (stop_tracing): Declare.
10877
10878 * server.c (handle_query) <qSupported>: Report support for
10879 disconnected tracing.
10880 (queue_stop_reply_callback): Account for running threads.
10881 (gdb_wants_thread_stopped): New.
10882 (gdb_wants_all_threads_stopped): New.
10883 (gdb_reattached_process): New.
10884 (handle_status): Clear the `gdb_detached' flag of all processes.
10885 In all-stop, stop all threads.
10886 (main): Be sure to leave tfind mode. Handle disconnected tracing.
10887 (process_serial_event): If the remote connection breaks, or if an
10888 exit was forced with "monitor exit", force an event loop exit.
10889 Handle disconnected tracing on detach.
10890 (handle_serial_event): Adjust.
10891 (handle_target_event): If GDB isn't connected, forward events back
10892 to the inferior, unless the last process exited, in which case,
10893 exit gdbserver. Adjust interface.
10894
10895 * remote-utils.c (remote_open): Don't block in accept. Instead
10896 register an event loop source on the listen socket file
10897 descriptor. Refactor bits into ...
10898 (listen_desc): ... this new global.
10899 (gdb_connected): ... this new function.
10900 (enable_async_notification): ... this new function.
10901 (handle_accept_event): ... this new function.
10902 (remote_close): Clear remote_desc.
10903
10904 * inferiors.c (add_thread): Set the new thread's last_resume_kind.
10905
10906 * target.h (struct target_ops) <mourn, thread_stopped, pause_all>:
10907 New fields.
10908 (mourn_inferior): Define.
10909 (target_process_qsupported): Avoid the dangling else problem.
10910 (thread_stopped): Define.
10911 (pause_all): Define.
10912 (target_waitstatus_to_string): Declare.
10913 * target.c (target_waitstatus_to_string): New.
10914
10915 * tracepoint.c (tracing): Make extern.
10916 (disconnected_tracing): New.
10917 (stop_tracing): Make extern. Handle tracing stops due to GDB
10918 disconnecting.
10919 (cmd_qtdisconnected): New.
10920 (cmd_qtstatus): Report disconnected tracing status in trace reply.
10921 (handle_tracepoint_general_set): Handle QTDisconnected.
10922
10923 * event-loop.c (event_handler_func): Change return type to int.
10924 (process_event): Bail out if the event handler wants the event
10925 loop to stop.
10926 (handle_file_event): Ditto.
10927 (start_event_loop): Bail out if the event handler wants the event
10928 loop to stop.
10929
10930 * nto-low.c (nto_target_ops): Adjust.
10931 * spu-low.c (spu_wait): Don't remove the process here.
10932 (spu_target_ops): Adjust.
10933 * win32-low.c (win32_wait): Don't remove the process here.
10934 (win32_target_ops): Adjust.
10935
5d267c4c
PA
109362010-04-11 Pedro Alves <pedro@codesourcery.com>
10937
10938 * regcache.c (realloc_register_cache): Invalidate inferior's
10939 regcache before recreating it.
10940
623ccd72
PA
109412010-04-09 Pedro Alves <pedro@codesourcery.com>
10942
10943 * tracepoint.c (cmd_qtstatus): Report trace buffer circularity.
10944
219f2f23
PA
109452010-04-09 Stan Shebs <stan@codesourcery.com>
10946 Pedro Alves <pedro@codesourcery.com>
10947
10948 * server.h (LONGEST): New.
10949 (struct thread_info) <while_stepping>: New field.
10950 (unpack_varlen_hex, xrealloc, pulongest, plongest, phex_nz):
10951 Declare.
10952 (initialize_tracepoint, handle_tracepoint_general_set)
10953 (handle_tracepoint_query, tracepoint_finished_step)
10954 (tracepoint_was_hit, release_while_stepping_state_list):
10955 (current_traceframe): Declare.
10956 * server.c (handle_general_set): Handle tracepoint packets.
10957 (read_memory): New.
10958 (write_memory): New.
10959 (handle_search_memory_1): Use read_memory.
10960 (handle_query): Report support for conditional tracepoints, trace
10961 state variables, and tracepoint sources. Handle tracepoint
10962 queries.
10963 (main): Initialize the tracepoints module.
10964 (process_serial_event): Handle traceframe reads/writes.
10965
10966 * linux-low.c (handle_tracepoints): New.
10967 (linux_wait_1): Call it.
10968 (linux_resume_one_lwp): Handle while-stepping.
10969 (linux_supports_tracepoints, linux_read_pc, linux_write_pc): New.
10970 (linux_target_ops): Install them.
10971 * linux-low.h (struct linux_target_ops) <supports_tracepoints>:
10972 New field.
10973 * linux-x86-low.c (x86_supports_tracepoints): New.
10974 (the_low_target). Install it.
10975
10976 * mem-break.h (delete_breakpoint): Declare.
10977 * mem-break.c (delete_breakpoint): Make external.
10978
10979 * target.h (struct target_ops): Add `supports_tracepoints',
10980 `read_pc', and `write_pc' fields.
10981 (target_supports_tracepoints): Define.
10982 * utils.c (xrealloc, decimal2str, pulongest, plongest, thirty_two)
10983 (phex_nz): New.
10984
10985 * regcache.h (struct regcache) <registers_owned>: New field.
10986 (init_register_cache, regcache_cpy): Declare.
10987 (regcache_read_pc, regcache_write_pc): Declare.
10988 (register_cache_size): Declare.
10989 (supply_regblock): Declare.
10990 * regcache.c (init_register_cache): New.
10991 (new_register_cache): Use it.
10992 (regcache_cpy): New.
10993 (register_cache_size): New.
10994 (supply_regblock): New.
10995 (regcache_read_pc, regcache_write_pc): New.
889bf7c5 10996
219f2f23
PA
10997 * tracepoint.c: New.
10998
10999 * Makefile.in (OBS): Add tracepoint.o.
11000 (tracepoint.o): New rule.
11001
3a13a53b
L
110022010-04-08 H.J. Lu <hongjiu.lu@intel.com>
11003
11004 * Makefile.in (clean): Also remove i386-mmx.c i386-mmx-linux.c.
11005 (i386-mmx.o): New.
11006 (i386-mmx.c): Likewise.
11007 (i386-mmx-linux.o): Likewise.
11008 (i386-mmx-linux.c): Likewise.
11009
11010 * configure.srv (srv_i386_regobj): Add i386-mmx.o.
11011 (srv_i386_linux_regobj): Add i386-mmx-linux.o.
11012 (srv_i386_xmlfiles): Add i386/i386-mmx.xml.
11013 (srv_i386_linux_xmlfiles): Add i386/i386-mmx-linux.xml.
11014
11015 * linux-x86-low.c (init_registers_i386_mmx_linux): New.
11016 (x86_linux_update_xmltarget): Call init_registers_i386_mmx_linux
11017 and return if ptrace PTRACE_GETFPXREGS failed in 32bit.
11018
1570b33e
L
110192010-04-07 H.J. Lu <hongjiu.lu@intel.com>
11020
11021 * Makefile.in (clean): Updated.
11022 (i386-avx.o): New.
11023 (i386-avx.c): Likewise.
11024 (i386-avx-linux.o): Likewise.
11025 (i386-avx-linux.c): Likewise.
11026 (amd64-avx.o): Likewise.
11027 (amd64-avx.c): Likewise.
11028 (amd64-avx-linux.o): Likewise.
11029 (amd64-avx-linux.c): Likewise.
11030
11031 * configure.srv (srv_i386_regobj): Add i386-avx.o.
11032 (srv_i386_linux_regobj): Add i386-avx-linux.o.
11033 (srv_amd64_regobj): Add amd64-avx.o.
11034 (srv_amd64_linux_regobj): Add amd64-avx-linux.o.
11035 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx.xml.
11036 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx.xml.
11037 (srv_i386_xmlfiles): Add i386/i386-avx.xml.
11038 (srv_amd64_xmlfiles): Add i386/amd64-avx.xml.
11039 (srv_i386_linux_xmlfiles): Add i386/i386-avx-linux.xml.
11040 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-linux.xml.
11041
11042 * i387-fp.c: Include "i386-xstate.h".
11043 (i387_xsave): New.
11044 (i387_cache_to_xsave): Likewise.
11045 (i387_xsave_to_cache): Likewise.
11046 (x86_xcr0): Likewise.
11047
11048 * i387-fp.h (i387_cache_to_xsave): Likewise.
11049 (i387_xsave_to_cache): Likewise.
11050 (x86_xcr0): Likewise.
11051
11052 * linux-arm-low.c (target_regsets): Initialize nt_type to 0.
11053 * linux-crisv32-low.c (target_regsets): Likewise.
11054 * linux-m68k-low.c (target_regsets): Likewise.
11055 * linux-mips-low.c (target_regsets): Likewise.
11056 * linux-ppc-low.c (target_regsets): Likewise.
11057 * linux-s390-low.c (target_regsets): Likewise.
11058 * linux-sh-low.c (target_regsets): Likewise.
11059 * linux-sparc-low.c (target_regsets): Likewise.
11060 * linux-xtensa-low.c (target_regsets): Likewise.
11061
11062 * linux-low.c: Include <sys/uio.h>.
11063 (regsets_fetch_inferior_registers): Support nt_type.
11064 (regsets_store_inferior_registers): Likewise.
11065 (linux_process_qsupported): New.
11066 (linux_target_ops): Add linux_process_qsupported.
11067
11068 * linux-low.h (regset_info): Add nt_type.
11069 (linux_target_ops): Add process_qsupported.
11070
11071 * linux-x86-low.c: Include "i386-xstate.h", "elf/common.h"
11072 and <sys/uio.h>.
11073 (init_registers_i386_avx_linux): New.
11074 (init_registers_amd64_avx_linux): Likewise.
11075 (xmltarget_i386_linux_no_xml): Likewise.
11076 (xmltarget_amd64_linux_no_xml): Likewise.
11077 (PTRACE_GETREGSET): Likewise.
11078 (PTRACE_SETREGSET): Likewise.
11079 (x86_fill_xstateregset): Likewise.
11080 (x86_store_xstateregset): Likewise.
11081 (use_xml): Likewise.
11082 (x86_linux_update_xmltarget): Likewise.
11083 (x86_linux_process_qsupported): Likewise.
11084 (target_regsets): Add NT_X86_XSTATE entry and Initialize nt_type.
11085 (x86_arch_setup): Don't call init_registers_amd64_linux nor
11086 init_registers_i386_linux here. Call
11087 x86_linux_update_xmltarget.
11088 (the_low_target): Add x86_linux_process_qsupported.
11089
11090 * server.c (handle_query): Call target_process_qsupported.
11091
11092 * target.h (target_ops): Add process_qsupported.
11093 (target_process_qsupported): New.
11094
fc7238bb
PA
110952010-04-03 Pedro Alves <pedro@codesourcery.com>
11096
11097 * inferiors.c (add_thread): Set last_status kind to
11098 TARGET_WAITKIND_IGNORE.
11099 * linux-low.c (cancel_breakpoint): Remove unnecessary regcache
11100 fetch. Use ptid_of. Avoid unnecessary get_lwp_thread calls.
11101 (linux_wait_1): Move `thread' local definition to block that uses
11102 it. Don't NULL initialize `event_child'.
11103 (linux_resume_one_thread): Avoid unnecessary get_lwp_thread calls.
11104 Alway set the thread's last_status to TARGET_WAITKIND_IGNORE.
11105 * linux-x86-low.c (x86_breakpoint_at): Read raw memory.
11106
bdabb078
PA
111072010-04-01 Pedro Alves <pedro@codesourcery.com>
11108
11109 * linux-low.c (get_stop_pc): Don't adjust the PC if stopped with
11110 an extended waitstatus, or by a watchpoint.
11111 (cancel_breakpoints_callback): Don't cancel a breakpoint if the
11112 thread was stepping or has been stopped by a watchpoint.
11113
d3bbe7a0
PA
111142010-04-01 Pedro Alves <pedro@codesourcery.com>
11115
11116 * mem-break.c (struct raw_breakpoint): New field shlib_disabled.
11117 (set_gdb_breakpoint_at): If GDB is inserting a breakpoint on top
11118 of another, then delete the previous, and validate all
11119 breakpoints.
11120 (validate_inserted_breakpoint): New.
11121 (delete_disabled_breakpoints): New.
11122 (validate_breakpoints): New.
11123 (check_mem_read): Validate breakpoints before trusting their
11124 shadow. Delete disabled breakpoints.
11125 (check_mem_write): Validate breakpoints before trusting they
11126 should be inserted. Delete disabled breakpoints.
11127 * mem-break.h (validate_breakpoints):
11128 * server.c (handle_query): Validate breakpoints when we see a
11129 qSymbol query.
11130
8b07ae33
PA
111312010-04-01 Pedro Alves <pedro@codesourcery.com>
11132
11133 * linux-low.c (linux_wait_1): Avoid setting need_step_over is
11134 there's a GDB breakpoint at stop_pc. Always report a trap to GDB
11135 if we could tell there's a GDB breakpoint at stop_pc.
11136 (need_step_over_p): Don't do a step over if we find a GDB
11137 breakpoint at the resume PC.
11138
11139 * mem-break.c (struct raw_breakpoint): New.
11140 (enum bkpt_type): New type `gdb_breakpoint'.
11141 (struct breakpoint): Delete the `PC', `old_data' and `inserted'
11142 fields. New field `raw'.
11143 (find_raw_breakpoint_at): New.
11144 (set_raw_breakpoint_at): Handle refcounting. Create a raw
11145 breakpoint instead.
11146 (set_breakpoint_at): Adjust.
11147 (delete_raw_breakpoint): New.
11148 (release_breakpoint): New.
11149 (delete_breakpoint): Rename to...
11150 (delete_breakpoint_1): ... this. Add proc parameter. Use
11151 release_breakpoint. Return ENOENT.
11152 (delete_breakpoint): Reimplement.
11153 (find_breakpoint_at): Delete.
11154 (find_gdb_breakpoint_at): New.
11155 (delete_breakpoint_at): Delete.
11156 (set_gdb_breakpoint_at): New.
11157 (delete_gdb_breakpoint_at): New.
11158 (gdb_breakpoint_here): New.
11159 (set_reinsert_breakpoint): Use release_breakpoint.
11160 (uninsert_breakpoint): Rename to ...
11161 (uninsert_raw_breakpoint): ... this.
11162 (uninsert_breakpoints_at): Adjust to handle raw breakpoints.
11163 (reinsert_raw_breakpoint): Change parameter type to
11164 raw_breakpoint.
11165 (reinsert_breakpoints_at): Adjust to handle raw breakpoints
11166 instead.
11167 (check_breakpoints): Adjust. Use release_breakpoint.
11168 (breakpoint_here): Rewrite using find_raw_breakpoint_at.
11169 (breakpoint_inserted_here): Ditto.
11170 (check_mem_read): Adjust to iterate over raw breakpoints instead.
11171 Don't trust the breakpoint's shadow if it is not inserted.
11172 (check_mem_write): Adjust to iterate over raw breakpoints instead.
11173 (delete_all_breakpoints): Adjust.
11174 (free_all_breakpoints): Mark all breakpoints as uninserted, and
11175 use delete_breakpoint_1.
11176
11177 * mem-break.h (breakpoints_supported): Delete declaration.
11178 (set_gdb_breakpoint_at): Declare.
11179 (gdb_breakpoint_here): Declare.
11180 (delete_breakpoint_at): Delete.
11181 (delete_gdb_breakpoint_at): Declare.
11182
11183 * server.h (struct raw_breakpoint): Forward declare.
11184 (struct process_info): New field `raw_breakpoints'.
11185
11186 * linux-x86-low.c (x86_insert_point, x86_remote_point): Handle Z0
11187 breakpoints.
11188
6bf5e0ba
PA
111892010-03-24 Pedro Alves <pedro@codesourcery.com>
11190
11191 * linux-low.c (status_pending_p_callback): Fix comment.
11192 (linux_wait_for_event_1): Move most of the internal breakpoint
11193 handling from here...
11194 (linux_wait_1): ... to here.
11195 (count_events_callback): New.
11196 (select_singlestep_lwp_callback): New.
11197 (select_event_lwp_callback): New.
11198 (cancel_breakpoints_callback): New.
11199 (select_event_lwp): New.
11200 (linux_wait_1): Simplify internal breakpoint handling. Give equal
11201 priority to all LWPs that have had events that should be reported
11202 to the client. Cancel breakpoints when about to reporting the
11203 event to the client, not while stopping lwps. No longer cancel
11204 finished single-steps here.
11205 (cancel_finished_single_step): Delete.
11206 (cancel_finished_single_steps): Delete.
11207
414a389f
PA
112082010-03-24 Pedro Alves <pedro@codesourcery.com>
11209
11210 * mem-break.c (enum bkpt_type): New.
11211 (struct breakpoint): New field `type'.
11212 (set_breakpoint_at): Change return type to struct breakpoint
11213 pointer. Set type to `other_breakpoint' by default.
11214 (delete_breakpoint): Rewrite, supporting more than one breakpoint
11215 in the breakpoint list.
11216 (delete_reinsert_breakpoints): Only delete reinsert breakpoints.
11217 (reinsert_breakpoint): Rename to ...
11218 (reinsert_raw_breakpoint): ... this.
11219 (reinsert_breakpoints_at): Adjust.
11220 * mem-break.h (struct breakpoint): Declare.
11221 (set_breakpoint_at): Change return type to struct breakpoint
11222 pointer.
11223
2280c721
PA
112242010-03-24 Pedro Alves <pedro@codesourcery.com>
11225
11226 * server.c (handle_query): Assign, not compare.
11227
d50171e4
PA
112282010-03-24 Pedro Alves <pedro@codesourcery.com>
11229
11230 Teach linux gdbserver to step-over-breakpoints.
11231
11232 * linux-low.c (can_hardware_single_step): New.
11233 (supports_breakpoints): New.
11234 (handle_extended_wait): If stopping threads, read the stop pc of
11235 the new cloned LWP.
11236 (get_pc): New.
11237 (get_stop_pc): Add `lwp' parameter. Handle it. Bail out if the
11238 low target doesn't support retrieving the PC.
11239 (add_lwp): Set last_resume_kind to resume_continue.
11240 (linux_attach_lwp_1): Adjust comments. Always set stop_expected.
11241 (linux_attach): Don't clear stop_expected. Set the lwp's
11242 last_resume_kind to resume_stop.
11243 (linux_detach_one_lwp): Don't check for removed breakpoints.
11244 (check_removed_breakpoint): Delete.
11245 (status_pending_p): Rename to ...
11246 (status_pending_p_callback): ... this. Don't check for removed
11247 breakpoints. Don't consider threads that are stopped from GDB's
11248 perspective.
11249 (linux_wait_for_lwp): Always read the stop_pc here.
11250 (cancel_breakpoint): New.
11251 (step_over_bkpt): New global.
11252 (linux_wait_for_event_1): Implement stepping over breakpoints.
11253 (gdb_wants_lwp_stopped): New.
11254 (gdb_wants_all_stopped): New.
11255 (linux_wait_1): Tag threads as gdb-wants-stopped. Cancel finished
11256 single-step traps here. Store the thread's last reported target
11257 wait status.
11258 (send_sigstop): Don't clear stop_expected. Always set it,
11259 instead.
11260 (mark_lwp_dead): Remove reference to pending_is_breakpoint.
11261 (cancel_finished_single_step): New.
11262 (cancel_finished_single_steps): New.
11263 (wait_for_sigstop): Don't cancel finished single-step traps here.
11264 (linux_resume_one_lwp): Don't check for removed breakpoints.
11265 Don't set `step' on non-hardware step archs.
11266 (linux_set_resume_request): Ignore resume_stop requests if already
11267 stopping or stopped. Set the lwp's last_resume_kind.
11268 (resume_status_pending_p): Don't check for removed breakpoints.
11269 (need_step_over_p): New.
11270 (start_step_over): New.
11271 (finish_step_over): New.
11272 (linux_resume_one_thread): Always queue a sigstop for resume_stop
11273 requests. Clear the thread's last reported target waitstatus.
11274 Don't use the `suspended' flag. Don't consider pending breakpoints.
11275 (linux_resume): Start a step-over if necessary.
11276 (proceed_one_lwp): New.
11277 (proceed_all_lwps): New.
11278 (unstop_all_lwps): New.
11279 * linux-low.h (struct lwp_info): Rewrite comment for the
11280 `suspended' flag. Add the `stop_pc' field. Delete the
11281 `pending_stop_pc' field. Tweak the `stepping' flag's comment.
11282 Add `'last_resume_kind' and `need_step_over' fields.
11283 * inferiors.c (struct thread_info): Delete, moved elsewhere.
11284 * mem-break.c (struct breakpoint): Delete `reinserting' flag.
11285 Delete `breakpoint_to_reinsert' field. New flag `inserted'.
11286 (set_raw_breakpoint_at): New.
11287 (set_breakpoint_at): Rewrite to use it.
11288 (reinsert_breakpoint_handler): Delete.
11289 (set_reinsert_breakpoint): New.
11290 (reinsert_breakpoint_by_bp): Delete.
11291 (delete_reinsert_breakpoints): New.
11292 (uninsert_breakpoint): Rewrite.
11293 (uninsert_breakpoints_at): New.
11294 (reinsert_breakpoint): Rewrite.
11295 (reinsert_breakpoints_at): New.
11296 (check_breakpoints): Rewrite.
11297 (breakpoint_here): New.
11298 (breakpoint_inserted_here): New.
11299 (check_mem_read): Adjust.
11300 * mem-break.h (breakpoints_supported, breakpoint_here)
11301 (breakpoint_inserted_here, set_reinsert_breakpoint): Declare.
11302 (reinsert_breakpoint_by_bp): Delete declaration.
11303 (delete_reinsert_breakpoints): Declare.
11304 (reinsert_breakpoint): Delete declaration.
11305 (reinsert_breakpoints_at): Declare.
11306 (uninsert_breakpoint): Delete declaration.
11307 (uninsert_breakpoints_at): Declare.
11308 (check_breakpoints): Adjust prototype.
11309 * server.h: Adjust include order.
11310 (struct thread_info): Declare here. Add a `last_status' field.
11311
30ba68cb
MS
113122010-03-23 Michael Snyder <msnyder@vmware.com>
11313
11314 * server.c (crc32): New function.
11315 (handle_query): Add handling for 'qCRC:' request.
11316
b9a881c2
PA
113172010-03-23 Pedro Alves <pedro@codesourcery.com>
11318
11319 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR6 if the
11320 lwp had been stopped by a watchpoint.
11321
e92d13d5
PA
113222010-03-16 Pedro Alves <pedro@codesourcery.com>
11323
11324 * server.h (internal_error): Declare.
11325 (gdb_assert, ASSERT_FUNCTION, gdb_assert_fail): Define.
11326 * utils.c (internal_error): New function.
11327
64daa791
AS
113282010-03-15 Andreas Schwab <schwab@redhat.com>
11329
11330 * configure.srv: Fix typo setting srv_regobj.
11331
f52cd8cd
PA
113322010-03-15 Pedro Alves <pedro@codesourcery.com>
11333
11334 * linux-low.c (fetch_register): Avoid passing a non string literal
11335 format to `error'.
11336 (usr_store_inferior_registers): Ditto.
11337
93ae6fdc
PA
113382010-03-14 Pedro Alves <pedro@codesourcery.com>
11339
11340 * linux-low.c (linux_write_memory): Bail out early if peeking
11341 memory failed.
11342
c3adc08c
PA
113432010-03-14 Pedro Alves <pedro@codesourcery.com>
11344
11345 * linux-low.h (struct lwp_info): New fields
11346 `stopped_by_watchpoint' and `stopped_data_address'.
11347 * linux-low.c (linux_wait_for_lwp): Check for watchpoint triggers
11348 here, and cache them in the lwp object.
11349 (wait_for_sigstop): Check stopped_by_watchpoint lwp field
11350 directly.
11351 (linux_resume_one_lwp): Clear the lwp's stopped_by_watchpoint
11352 field.
11353 (linux_stopped_by_watchpoint): Rewrite.
11354 (linux_stopped_data_address): Rewrite.
11355
bce522a2
PA
113562010-03-06 Simo Melenius <simo.melenius@iki.fi>
11357
11358 * linux-low.c (linux_wait_for_lwp): Fetch the regcache after
11359 switching the current inferior, not before.
11360
90884b2b
L
113612010-03-01 H.J. Lu <hongjiu.lu@intel.com>
11362
11363 * Makefile.in (clean): Replace reg-i386.c, reg-x86-64.c,
11364 reg-i386-linux.c and reg-x86-64-linux.c with i386.c, amd64.c,
11365 i386-linux.c and amd64-linux.c.
11366 (reg-i386.o): Removed.
11367 (reg-i386.c): Likewise.
11368 (reg-i386-linux.o): Likewise.
11369 (reg-i386-linux.c): Likewise.
11370 (reg-x86-64.o): Likewise.
11371 (reg-x86-64.c): Likewise.
11372 (reg-x86-64-linux.o): Likewise.
11373 (reg-x86-64-linux.c): Likewise.
11374 (i386.o): New.
11375 (i386.c): Likewise.
11376 (i386-linux.o): Likewise.
11377 (i386-linux.c): Likewise.
11378 (amd64.o): Likewise.
11379 (amd64.c): Likewise.
11380 (amd64-linux.o): Likewise.
11381 (amd64-linux.c): Likewise.
11382
11383 * configure.srv (srv_i386_regobj): New.
11384 (srv_i386_linux_regobj): Likewise.
11385 (srv_amd64_regobj): Likewise.
11386 (srv_amd64_linux_regobj): Likewise.
11387 (srv_i386_32bit_xmlfiles): Likewise.
11388 (srv_i386_64bit_xmlfiles): Likewise.
11389 (srv_i386_xmlfiles): Likewise.
11390 (srv_amd64_xmlfiles): Likewise.
11391 (srv_i386_linux_xmlfiles): Likewise.
11392 (srv_amd64_linux_xmlfiles): Likewise.
11393 (i[34567]86-*-cygwin*): Set srv_regobj to $srv_i386_regobj. Set
11394 srv_xmlfiles to $srv_i386_xmlfiles.
11395 (i[34567]86-*-mingw32ce*): Likewise.
11396 (i[34567]86-*-mingw*): Likewise.
11397 (i[34567]86-*-nto*): Likewise.
11398 (i[34567]86-*-linux*): Set srv_regobj to $srv_i386_linux_regobj
11399 and $srv_amd64_linux_regobj. Set srv_xmlfiles to
11400 $srv_i386_linux_xmlfiles and $srv_amd64_linux_xmlfiles.
11401 (x86_64-*-linux*): Likewise.
11402
11403 * linux-x86-low.c (init_registers_x86_64_linux): Removed.
11404 (init_registers_amd64_linux): New.
11405 (x86_arch_setup): Replace init_registers_x86_64_linux with
11406 init_registers_amd64_linux.
11407
193f13e6
MK
114082010-02-23 Maxim Kuvyrkov <maxim@codesourcery.com>
11409
11410 * configure.ac: Check for libdl. If it is not available link against
11411 static libthread_db.
11412 * configure: Regenerate.
11413
85d721b8
PA
114142010-02-22 Pedro Alves <pedro@codesourcery.com>
11415
11416 PR9605
11417
11418 * i386-low.c (i386_length_and_rw_bits): Throw a fatal error if
11419 handing a read watchpoint.
11420 (i386_low_insert_watchpoint): Read watchpoints aren't supported.
11421
6076632b
DE
114222010-02-12 Doug Evans <dje@google.com>
11423
11424 * linux-low.c (linux_supports_tracefork_flag): Document.
11425 (linux_look_up_symbols): Add comment.
11426
3327ccf7
L
114272010-02-03 H.J. Lu <hongjiu.lu@intel.com>
11428
11429 * regcache.c (supply_register): Clear regcache if buf is NULL.
11430
0718675c 114312010-02-02 Nicolas Roche <roche@sourceware.org>
3327ccf7 11432 Joel Brobecker <brobecker@adacore.com>
0718675c
JB
11433
11434 * inferiors.c (find_inferior): Add function documentation.
11435 (unloaded_dll): Handle the case where the unloaded dll has not
11436 been previously registered in the dll list.
11437
177321bd
DJ
114382010-02-01 Daniel Jacobowitz <dan@codesourcery.com>
11439
11440 * linux-arm-low.c (thumb_breakpoint_len): Delete.
11441 (thumb2_breakpoint): New.
11442 (arm_breakpoint_at): Check for Thumb-2 breakpoints.
11443
2b009048
DJ
114442010-01-29 Daniel Jacobowitz <dan@codesourcery.com>
11445
11446 * linux-low.c (get_stop_pc): Check for SIGTRAP.
11447 (linux_wait_for_event_1): Handle SIGILL and SIGSEGV as possible
11448 breakpoints.
11449
3be029c7
PA
114502010-01-21 Pedro Alves <pedro@codesourcery.com>
11451
11452 * linux-ppc-low.c (ppc_arch_setup): Adjust to regcache changes.
11453
18f5de3b
JK
114542010-01-21 Jan Kratochvil <jan.kratochvil@redhat.com>
11455
11456 * linux-s390-low.c (s390_collect_ptrace_register)
11457 (s390_supply_ptrace_register): Adjust it for the new regcache parameter.
11458
3743bb4f
DE
114592010-01-21 Doug Evans <dje@google.com>
11460
14ce3065
DE
11461 * linux-low.c (PTRACE_ARG3_TYPE): Change from long to void*.
11462 (PTRACE_ARG4_TYPE): New macro.
11463 (handle_extended_wait): Cast ptrace arg4 to PTRACE_ARG4_TYPE.
11464 (linux_wait_for_event_1, linux_resume_one_lwp): Ditto.
11465 (fetch_register): Cast to uintptr_t before casting to PTRACE_ARG3_TYPE.
11466 (usr_store_inferior_registers): Ditto.
11467 (linux_read_memory, linux_write_memory): Ditto.
11468 (linux_test_for_tracefork): Ditto.
11469
3743bb4f
DE
11470 * linux-arm-low.c: Remove redundant include of gdb_proc_service.h.
11471 Only include elf.h if gdb_proc_service.h didn't include linux/elf.h.
11472
8b315be5
PA
114732010-01-21 Pedro Alves <pedro@codesourcery.com>
11474
11475 * proc-service.c (ps_lgetregs): Don't refetch registers from the
11476 target.
11477
85492558
PA
114782010-01-21 Pedro Alves <pedro@codesourcery.com>
11479
11480 * spu-low.c (spu_fetch_registers, spu_store_registers): Change
11481 prototype to take a regcache. Adjust.
11482
442ea881
PA
114832010-01-20 Pedro Alves <pedro@codesourcery.com>
11484
11485 * regcache.h (struct thread_info): Forward declare.
11486 (struct regcache): New.
11487 (new_register_cache): Adjust prototype.
11488 (get_thread_regcache): Declare.
11489 (free_register_cache): Adjust prototype.
11490 (registers_to_string, registers_from_string): Ditto.
11491 (supply_register, supply_register_by_name, collect_register)
11492 (collect_register_as_string, collect_register_by_name): Ditto.
11493 * regcache.c (struct inferior_regcache_data): Delete.
11494 (get_regcache): Rename to ...
11495 (get_thread_regcache): ... this. Adjust. Switch inferior before
11496 fetching registers.
11497 (regcache_invalidate_one): Adjust.
11498 (regcache_invalidate): Fix prototype.
11499 (new_register_cache): Return the new register cache.
11500 (free_register_cache): Change prototype.
11501 (realloc_register_cache): Adjust.
11502 (registers_to_string): Change prototype to take a regcache. Adjust.
11503 (registers_from_string): Ditto.
11504 (register_data): Ditto.
11505 (supply_register): Ditto.
11506 (supply_register_by_name): Ditto.
11507 (collect_register): Ditto.
11508 (collect_register_as_string): Ditto.
11509 (collect_register_by_name): Ditto.
11510 * server.c (process_serial_event): Adjust.
11511 * linux-low.h (regset_fill_func, regset_store_func): Change
11512 prototype.
11513 (get_pc, set_pc, collect_ptrace_register, supply_ptrace_register):
11514 Change prototype.
11515 * linux-low.c (get_stop_pc): Adjust.
11516 (check_removed_breakpoint): Adjust.
11517 (linux_wait_for_event): Adjust.
11518 (linux_resume_one_lwp): Adjust.
11519 (fetch_register): Add regcache parameter. Adjust.
11520 (usr_store_inferior_registers): Ditto.
11521 (regsets_fetch_inferior_registers): Ditto.
11522 (regsets_store_inferior_registers): Ditto.
11523 (linux_fetch_registers, linux_store_registers): Ditto.
11524 * i387-fp.c (i387_cache_to_fsave): Change prototype to take a
11525 regcache. Adjust.
43aaf8b6
PA
11526 (i387_fsave_to_cache, i387_cache_to_fxsave, i387_fxsave_to_cache):
11527 Ditto.
442ea881
PA
11528 * i387-fp.h (i387_cache_to_fsave, i387_fsave_to_cache): Change
11529 prototype to take a regcache.
11530 (i387_cache_to_fxsave, i387_fxsave_to_cache): Ditto.
11531 * remote-utils.c (convert_ascii_to_int, outreg)
11532 (prepare_resume_reply): Change prototype to take a regcache.
11533 Adjust.
11534 * target.h (struct target_ops) <fetch_registers, store_registers>:
11535 Change prototype to take a regcache.
11536 (fetch_inferior_registers, store_inferior_registers): Change
11537 prototype to take a regcache. Adjust.
11538 * proc-service.c (ps_lgetregs): Adjust.
11539 * linux-x86-low.c (x86_fill_gregset, x86_store_gregset)
11540 (x86_fill_fpregset, x86_store_fpregset, x86_fill_fpxregset)
11541 (x86_store_fpxregset, x86_get_pc, x86_set_pc): Change prototype to
11542 take a regcache. Adjust.
11543 * linux-arm-low.c (arm_fill_gregset, arm_store_gregset)
11544 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
11545 (arm_store_vfpregset, arm_get_pc, arm_set_pc):
11546 (arm_breakpoint_at): Change prototype to take a regcache. Adjust.
11547 * linux-cris-low.c (cris_get_pc, cris_set_pc)
11548 (cris_cannot_fetch_register):
11549 (cris_breakpoint_at): Change prototype to take a regcache.
11550 Adjust.
11551 * linux-crisv32-low.c (cris_get_pc, cris_set_pc,
11552 cris_reinsert_addr, cris_write_data_breakpoint): Change prototype
11553 to take a regcache. Adjust.
11554 (cris_breakpoint_at, cris_insert_point, cris_remove_point):
11555 Adjust.
11556 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Change prototype to
11557 take a regcache. Adjust.
11558 * linux-m68k-low.c (m68k_fill_gregset, m68k_store_gregset)
11559 (m68k_fill_fpregset, m68k_store_fpregset, m68k_get_pc,
11560 (m68k_set_pc): Change prototype to take a regcache. Adjust.
11561 * linux-mips-low.c (mips_get_pc):
11562 (mips_set_pc): Change prototype to take a regcache. Adjust.
11563 (mips_reinsert_addr): Adjust.
11564 (mips_collect_register): Change prototype to take a regcache.
11565 Adjust.
11566 (mips_supply_register):
11567 (mips_collect_register_32bit, mips_supply_register_32bit)
11568 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
11569 (mips_store_fpregset): Ditto.
43aaf8b6
PA
11570 * linux-ppc-low.c (ppc_supply_ptrace_register)
11571 (ppc_supply_ptrace_register): Ditto.
442ea881
PA
11572 (parse_spufs_run): Adjust.
11573 (ppc_get_pc, ppc_set_pc, ppc_fill_gregset, ppc_fill_vsxregset)
11574 (ppc_store_vsxregset, ppc_fill_vrregset, ppc_store_vrregset)
11575 (ppc_fill_evrregset, ppc_store_evrregset): Change prototype to
11576 take a regcache. Adjust.
11577 * linux-s390-low.c (s390_collect_ptrace_register)
11578 (s390_supply_ptrace_register, s390_fill_gregset, s390_get_pc)
11579 (s390_set_pc): Change prototype to take a regcache. Adjust.
11580 (s390_arch_setup): Adjust.
11581 * linux-sh-low.c (sh_get_pc, sh_breakpoint_at)
11582 (sh_fill_gregset): Change prototype to take a regcache. Adjust.
11583 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
11584 (sparc_fill_gregset, sparc_store_gregset_from_stack)
11585 (sparc_store_gregset, sparc_get_pc): Change prototype to take a
11586 regcache. Adjust.
11587 (sparc_breakpoint_at): Adjust.
11588 * linux-xtensa-low.c (xtensa_fill_gregset):
11589 (xtensa_store_gregset):
11590 (xtensa_fill_xtregset, xtensa_store_xtregset, xtensa_get_pc)
11591 (xtensa_set_pc): Change prototype to take a regcache. Adjust.
11592 * nto-low.c (nto_fetch_registers, nto_store_registers): Change
11593 prototype to take a regcache. Adjust.
11594 * win32-arm-low.c (arm_fetch_inferior_register)
11595 (arm_store_inferior_register): Change prototype to take a
11596 regcache. Adjust.
11597 * win32-i386-low.c (i386_fetch_inferior_register)
11598 (i386_store_inferior_register): Change prototype to take a
11599 regcache. Adjust.
11600 * win32-low.c (child_fetch_inferior_registers)
11601 (child_store_inferior_registers): Change prototype to take a
11602 regcache. Adjust.
11603 (win32_wait): Adjust.
11604 (win32_fetch_inferior_registers): Change prototype to take a
11605 regcache. Adjust.
11606 (win32_store_inferior_registers): Adjust.
11607 * win32-low.h (struct win32_target_ops) <fetch_inferior_register,
11608 store_inferior_register>: Change prototype to take a regcache.
11609
60c3d7b0
DE
116102010-01-20 Doug Evans <dje@google.com>
11611
11612 * linux-low.c (linux_create_inferior): Wrap use of __SIGRTMIN in
11613 #ifdef.
11614 (linux_wait_for_event1, linux_init_signals): Ditto.
ec8ebe72 11615 (W_STOPCODE): Provide definition if missing.
60c3d7b0 11616
dc146f7c
VP
116172010-01-13 Vladimir Prus <vladimir@codesourcery.com>
11618
11619 * linux-low.c (linux_core_of_thread): New.
11620 (compare_ints, show_process, list_threads): New.
11621 (linux_qxfer_osdata): Report threads and cores.
11622 (linux_target_op): Register linux_core_of_thread.
11623 * remote-utils.c (prepare_resume_reply): Report the core.
11624 (buffer_xml_printf): Support %d specifier.
11625 * server.c (handle_threads_qxfer_proper, handle_threads_qxfer):
11626 New.
11627 (handle_query): Handle qXfer:threads. Announce availability
11628 thereof.
11629 * target.h (struct target_ops): New field core_of_thread.
11630
7803799a
UW
116312010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
11632
11633 * Makefile.in (clean): Remove new generated files.
11634 (reg-s390.o, reg-s390.c): Remove rules.
11635 (reg-s390x.o, reg-s390x.c): Likewise.
11636 (s390-linux32.o, s390-linux32.c): Add rules.
11637 (s390-linux64.o, s390-linux64.c): Likewise.
11638 (s390x-linux64.o, s390x-linux64.c): Likewise.
11639 * configure.srv (s390*-*-linux*): Update srv_regobj and srv_xmlfiles.
11640 * linux-s390-low.c: Include <elf.h>.
11641 (HWCAP_S390_HIGH_GPRS): Define if undefined.
11642 (init_registers_s390): Remove prototype.
11643 (init_registers_s390x): Likewise.
11644 (init_registers_s390_linux32): Add prototype.
11645 (init_registers_s390_linux64): Likewise.
11646 (init_registers_s390x_linux64): Likewise.
11647 (s390_num_regs_3264): New define.
11648 (s390_regmap_3264): New global variable.
11649 (s390_cannot_fetch_register): Remove obsolete check.
11650 (s390_cannot_store_register): Likewise.
11651 (s390_collect_ptrace_register): Handle upper/lower register halves.
11652 (s390_supply_ptrace_register): Likewise.
11653 (s390_fill_gregset): Update to register number changes.
11654 (s390_get_hwcap): New routine.
11655 (s390_arch_setup): Detect 32-bit process running on 64-bit system.
11656 Install appropriate regmap and register set.
11657
6e7ffa39
JB
116582010-01-01 Joel Brobecker <brobecker@adacore.com>
11659
11660 * server.c (gdbserver_version): Update copyright year to 2010.
11661 * gdbreplay.c (gdbreplay_version): Likewise.
11662
957f3f49
DE
116632009-12-28 Doug Evans <dje@google.com>
11664
11665 * linux-low.c: Delete inclusion of ansidecl.h, elf/common.h,
11666 elf/external.h. Include <elf.h> instead but only if necessary.
11667
ca5c370d
PA
116682009-12-28 Pedro Alves <pedro@codesourcery.com>
11669
11670 * linux-low.c (linux_remove_process): Remove `detaching'
11671 parameter. Don't release/detach from thread_db here.
11672 (linux_kill): Release/detach from thread_db here, ...
11673 (linux_detach): ... and here, before actually detaching.
11674 (linux_wait_1): ... and here, when a process exits.
11675 * thread-db.c (any_thread_of): New.
11676 (thread_db_free): Switch the current inferior to a thread of the
11677 passed in process.
11678
4ee62156
DE
116792009-12-21 Doug Evans <dje@google.com>
11680
d90e6a88
DE
11681 * linux-x86-low.c: Delete outdated comment about Elf32_Phdr.
11682
c5f62d5f
DE
11683 * linux-low.c (kill_lwp): Use __NR_tkill instead of SYS_tkill.
11684 Move definition of tkill_failed to ifdef __NR_tkill to avoid gcc
11685 warning ifndef __NR_tkill. Move setting of errno there too.
11686 Delete unnecessary resetting of errno after syscall.
11687 Minor comment changes to match gdb/linux-nat.c:kill_lwp.
11688
10e86dd7
DE
11689 * configure.ac: Check for dladdr.
11690 * config.in: Regenerate.
11691 * configure: Regenerate.
11692 * thread-db.c (dladdr_to_soname): Only define ifdef HAVE_DLADDR.
11693 (try_thread_db_load): Update.
11694
4ee62156
DE
11695 * linux-low.c (my_waitpid): Delete unnecessary prototype.
11696
00f515da
DE
116972009-12-18 Doug Evans <dje@google.com>
11698
e9464885
DE
11699 * event-loop.c: Include unistd.h if it exists.
11700
07d4f67e
DE
11701 * linux-low.c (my_waitpid): Move definition away from being in
11702 between linux_tracefork_child/linux_test_for_tracefork.
11703
00f515da
DE
11704 * gdb_proc_service.h (psaddr_t): Fix type.
11705 * thread-db.c (thread_db_info.td_thr_tls_get_addr_p): Fix
11706 signature to match glibc.
11707
1de1badb
DE
117082009-12-16 Doug Evans <dje@google.com>
11709
11710 * linux-low.c (linux_read_memory): Fix argument to read.
11711
aeeb81d1
PA
117122009-11-26 Pedro Alves <pedro@codesourcery.com>
11713
11714 * win32-low.c (get_child_debug_event): On EXIT_THREAD_DEBUG_EVENT
11715 events, don't leave current_inferior pointing at null.
11716
10357975
PA
117172009-11-26 Pedro Alves <pedro@codesourcery.com>
11718
11719 * win32-low.c (LOG): Delete.
11720 (OUTMSG): Output to stderr.
11721 (OUTMSG2): Conditionalize on `debug_threads' variable, instead of
11722 on compile time LOG macro.
11723 (win32_wait): Fix debug output.
11724
cf6e3471
PA
117252009-11-26 Pedro Alves <pedro@codesourcery.com>
11726
11727 * win32-low.c (win32_add_one_solib): If the dll name is
11728 "ntdll.dll", prepend the system directory to the dll path.
11729
0c85e18e
MK
117302009-11-17 Daniel Jacobowitz <dan@codesourcery.com>
11731
11732 * m68k-tdep.c (m68k_gdbarch_init): Reuse previous initialization.
11733
9ac544ce 117342009-11-17 Nathan Sidwell <nathan@codesourcery.com>
889bf7c5 11735 Vladimir Prus <vladimir@codesourcery.com>
9ac544ce
MK
11736
11737 * Makefile.in (reg-cf.o, reg-cf.c): New targets.
11738 * configure.ac: Check for __mcoldfire__ and set
11739 gdb_cv_m68k_is_coldfire.
11740 * configure.srv: Use gdb_cv_m68k_is_coldfire to select between
11741 reg-cf.o and reg-m68k.o.
11742 * configure: Regenerated.
11743
fd7dd3e6
PA
117442009-11-16 Pedro Alves <pedro@codesourcery.com>
11745
11746 * linux-low.c (linux_remove_process): Add `detaching' parameter.
11747 Pass it to thread_db_free.
11748 (linux_kill, linux_detach, linux_wait_1): Adjust to pass the
11749 proper `detaching' argument to linux_remove_process.
11750 * linux-low.h (thread_db_free): Add `detaching' parameter.
11751 * thread-db.c (thread_db_init): Pass false as `detaching' argument
11752 to thread_db_free.
11753 (thread_db_free): Add `detaching' parameter. Only
11754 call td_ta_clear_event if detaching from process.
11755
75aa492e
MK
117562009-11-12 Maxim Kuvyrkov <maxim@codesourcery.com>
11757
11758 * thread-db.c (thread_db_free): Fix typo.
11759
21e1bee4
PP
117602009-11-11 Paul Pluzhnikov <ppluzhnikov@google.com>
11761
11762 PR gdb/10838
11763 * thread-db.c (thread_db_free): Call td_ta_clear_event.
11764
8838b45e
NS
117652009-11-03 Nathan Sidwell <nathan@codesourcery.com>
11766
11767 * configure.ac (i[34567]86-*): Check if we're targetting x86-64
11768 with an i686 compiler.
11769 * configure.srv (i[34567]86-*-linux*): Pull in x86-64 handling if
11770 needed.
11771 * configure: Rebuilt.
11772
8a35fb51
SL
117732009-10-29 Sandra Loosemore <sandra@codesourcery.com>
11774
11775 PR gdb/10783
11776
11777 * server.c (handle_search_memory_1): Correct read_addr initialization
11778 in loop for searching subsequent chunks.
11779
96f15937
PP
117802009-10-29 Paul Pluzhnikov <ppluzhnikov@google.com>
11781
11782 * configure.ac: New --with-libthread-db option.
11783 * thread-db.c: Allow direct dependence on libthread_db.
11784 (thread_db_free): Adjust.
11785 * config.in: Regenerate.
11786 * configure: Likewise.
889bf7c5 11787
5f7d1694
PP
117882009-10-28 Paul Pluzhnikov <ppluzhnikov@google.com>
11789
11790 PR gdb/10757
11791 * thread-db.c (attach_thread): New function.
11792 (maybe_attach_thread): Return success/failure.
11793 (find_new_threads_callback): Adjust.
889bf7c5
PA
11794 (thread_db_find_new_threads): Loop until no new threads.
11795
88e3b899
PA
117962009-10-13 Pedro Alves <pedro@codesourcery.com>
11797
11798 * proc-service.c (ps_lgetregs): Formatting.
11799
cdbfd419
PP
118002009-10-08 Paul Pluzhnikov <ppluzhnikov@google.com>
11801
11802 * acinclude.m4: (SRV_CHECK_THREAD_DB, SRV_CHECK_TLS_GET_ADDR): Remove.
11803 * configure.ac: Adjust.
11804 * linux-low.h (struct process_info_private): Move members to struct
11805 thread_db.
11806 (thread_db_free, thread_db_handle_monitor_command): New prototype.
11807 * linux-low.c (linux_remove_process): Adjust.
11808 (linux_wait_for_event_1, linux_look_up_symbols): Likewise.
11809 * server.c (handle_query): Move code ...
11810 (handle_monitor_command): ... here. New function.
11811 * target.h (struct target_ops): New member.
11812 * thread-db.c (struct thread_db): New.
11813 (libthread_db_search_path): New variable.
11814 (thread_db_create_event, thread_db_enable_reporting)
11815 (find_one_thread, maybe_attach_thread, find_new_threads_callback)
11816 (thread_db_find_new_threads, (thread_db_get_tls_address): Adjust.
11817 (try_thread_db_load_1, dladdr_to_soname): New functions.
11818 (try_thread_db_load, thread_db_load_search): New functions.
11819 (thread_db_init): Search for libthread_db.
11820 (thread_db_free): New function.
11821 (thread_db_handle_monitor_command): Likewise.
11822 * config.in: Regenerate.
11823 * configure: Regenerate.
889bf7c5 11824
4168d2d6
UW
118252009-09-27 Ulrich Weigand <uweigand@de.ibm.com>
11826
11827 * spu-low.c (spu_kill): Wait for inferior to terminate.
11828 Call clear_inferiors.
11829 (spu_detach): Call clear_inferiors.
11830
81ecdfbb
RW
118312009-08-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
11832
11833 * aclocal.m4: Regenerate.
11834 * config.in: Likewise.
11835 * configure: Likewise.
11836
0b9ff2c0
UW
118372009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
11838
11839 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Define.
11840 (parse_spufs_run): New function.
11841 (ppc_get_pc, ppc_set_pc): Detect and handle SPU PC.
11842 (ppc_breakpoint_at): Handle SPU breakpoints.
11843
efcbbd14
UW
118442009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
11845
11846 * linux-low.c: Include <sys/stat.h> and <sys/vfs.h>.
11847 (SPUFS_MAGIC): Define.
11848 (spu_enumerate_spu_ids): New function.
11849 (linux_qxfer_spu): New function.
11850 (linux_target_ops): Install linux_qxfer_spu.
11851
f4d9bade
UW
118522009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
11853
11854 * configure.srv (powerpc*-*-linux*): Add powerpc-cell32l.o
11855 and powerpc-cell64l.o to srv_regobj. Add rs6000/powerpc-cell32l.xml
11856 and rs6000/powerpc-cell64l.xml to srv_xmlfiles.
11857 * Makefile.in (powerpc-cell32l.o, powerpc-cell32l.c): New rules.
11858 (powerpc-cell64l.o, powerpc-cell64l.c): Likewise.
11859 (clean): Handle powerpc-cell32l.c and powerpc-cell64l.c.
11860 * linux-ppc-low.c (PPC_FEATURE_CELL): Define.
11861 (init_registers_powerpc_cell32l): Add prototype.
11862 (init_registers_powerpc_cell64l): Likewise.
11863 (ppc_arch_setup): Detect Cell/B.E. architecture.
11864
96e946ca
RW
118652009-07-30 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
11866
11867 * Makefile.in (datarootdir): New variable.
11868
58d6951d
DJ
118692009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
11870
11871 * linux-low.c (linux_write_memory): Update debugging output.
11872 * Makefile.in (clean): Add new descriptions.
11873 (arm-with-vfpv2.o, arm-with-vfpv2.c, arm-with-vfpv3.o)
11874 (arm-with-vfpv3.c, arm-with-neon.o, arm-with-neon.c): New rules.
11875 * configure.srv: Add new files for arm*-*-linux*.
11876 * linux-arm-low.c: Add new declarations.
11877 (PTRACE_GETVFPREGS, PTRACE_SETVFPREGS): Define if undefined.
11878 (arm_hwcap, HWCAP_VFP, HWCAP_IWMMXT, HWCAP_NEON, HWCAP_VFPv3)
11879 (HWCAP_VFPv3D16): New.
11880 (arm_fill_wmmxregset, arm_store_wmmxregset): Check HWCAP_IWMMXT
11881 instead of __IWMMXT__.
11882 (arm_fill_vfpregset, arm_store_vfpregset, arm_get_hwcap)
11883 (arm_arch_setup): New.
11884 (target_regsets): Remove #ifdef. Add VFP regset.
11885 (the_low_target): Use arm_arch_setup.
11886
12b42a12
DJ
118872009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
11888
11889 * linux-low.c (linux_kill_one_lwp): Adjust kernel workaround to skip
11890 the main thread again.
11891
ac8c974e
AR
118922009-07-06 Aleksandar Ristovski <aristovski@qnx.com>
11893
11894 Adding Neutrino gdbserver.
11895 * configure: Regenerated.
11896 * configure.ac: Add case for srv_qnx and set LIBS accordingly.
11897 * configure.srv (i[34567]86-*-nto*): New target.
11898 * nto-low.c, nto-low.h, nto-x86-low.c: New files.
11899 * remote-utils.c [__QNX__]: Include sys/iomgr.h
11900 (nto_comctrl) [__QNX__]: New function.
11901 (enable_async_io, disable_async_io) [__QNX__]: Call nto_comctrl.
11902
4424e0c3 119032009-07-05 Danny Backx <dannybackx@users.sourceforge.net>
7437790a
PA
11904
11905 * configure.srv (i[34567]86-*-mingw32ce*): Add i386-low.o to
11906 srv_tgtobj.
11907
912cf4ba
PA
119082009-07-04 Danny Backx <dannybackx@users.sourceforge.net>
11909 Pedro Alves <pedro@codesourcery.com>
11910
11911 * win32-i386-low.c (i386_get_thread_context): Handle systems that
11912 don't support CONTEXT_EXTENDED_REGISTERS.
11913 (i386_win32_breakpoint, i386_win32_breakpoint_len): New.
11914 (the_low_target): Install them.
11915 * win32-low.c (get_child_debug_event): Handle WaitForDebugEvent
11916 failing with ERROR_PIPE_NOT_CONNECTED.
11917
aa5ca48f
DE
119182009-06-30 Doug Evans <dje@google.com>
11919 Pierre Muller <muller@ics.u-strasbg.fr>
11920
11921 Add h/w watchpoint support to x86-linux, win32-i386.
11922 * Makefile.in (SFILES): Add i386-low.c
11923 (i386_low_h): Define.
11924 (i386-low.o): Add dependencies.
11925 (linux-x86-low.o): Add i386-low.h dependency.
11926 (win32-i386-low.o): Ditto.
11927 * i386-low.c: New file.
11928 * i386-low.h: New file.
11929 * configure.srv (i[34567]86-*-cygwin*): Add i386-low.o to srv_tgtobj.
11930 (i[34567]86-*-linux*, i[34567]86-*-mingw*, x86_64-*-linux*): Ditto.
11931 * linux-low.c (linux_add_process): Initialize arch_private.
11932 (linux_remove_process): Free arch_private.
11933 (add_lwp): Initialize arch_private.
11934 (delete_lwp): Free arch_private.
11935 (linux_resume_one_lwp): Call the_low_target.prepare_to_resume if
11936 provided.
11937 * linux-low.h (process_info_private): New member arch_private.
11938 (lwp_info): New member arch_private.
11939 (linux_target_ops): New members new_process, new_thread,
11940 prepare_to_resume.
11941 (ptid_of): New macro.
11942 * linux-x86-low.c: Include stddef.h, i386-low.h.
11943 (arch_process_info): New struct.
11944 (arch_lwp_info): New struct.
11945 (x86_linux_dr_get, x86_linux_dr_set): New functions.
11946 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
11947 (i386_dr_low_get_status): New function.
11948 (x86_insert_point, x86_remove_point): New functions.
11949 (x86_stopped_by_watchpoint): New function.
11950 (x86_stopped_data_address): New function.
11951 (x86_linux_new_process, x86_linux_new_thread): New functions.
11952 (x86_linux_prepare_to_resume): New function.
11953 (the_low_target): Add entries for insert_point, remove_point,
11954 stopped_by_watchpoint, stopped_data_address, new_process, new_thread,
11955 prepare_to_resume.
11956 * server.c (debug_hw_points): New global.
11957 (monitor_show_help): Document set debug-hw-points.
11958 (handle_query): Process "set debug-hw-points".
11959 * server.h (debug_hw_points): Declare.
11960 (paddress): Declare.
11961 * utils.c (NUMCELLS, CELLSIZE): New macros.
11962 (get_sell, xsnprintf, paddress): New functions.
11963 * win32-arm-low.c (the_low_target): Add entries for insert_point,
11964 remove_point, stopped_by_watchpoint, stopped_data_address.
11965 * win32-i386-low.c: Include i386-low.h.
11966 (debug_reg_state): Replaces dr.
11967 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
11968 (i386_dr_low_get_status): New function.
11969 (i386_insert_point, i386_remove_point): New functions.
11970 (i386_stopped_by_watchpoint): New function.
11971 (i386_stopped_data_address): New function.
11972 (i386_initial_stuff): Update.
11973 (get_thread_context,set_thread_context,i386_thread_added): Update.
11974 (the_low_target): Add entries for insert_point,
11975 remove_point, stopped_by_watchpoint, stopped_data_address.
11976 * win32-low.c (win32_insert_watchpoint): New function.
11977 (win32_remove_watchpoint): New function.
11978 (win32_stopped_by_watchpoint): New function.
11979 (win32_stopped_data_address): New function.
11980 (win32_target_ops): Add entries for insert_watchpoint,
11981 remove_watchpoint, stopped_by_watchpoint, stopped_data_address.
11982 * win32-low.h (win32_target_ops): New members insert_point,
11983 remove_point, stopped_by_watchpoint, stopped_data_address.
11984
d993e290
PA
119852009-06-25 Pedro Alves <pedro@codesourcery.com>
11986
11987 * server.c (process_serial_event): Re-return unsupported, not
11988 error, if the type isn't recognized. Re-allow supporting only
11989 insert or remove packets. Also call require_running for
11990 breakpoints. Add missing break statement to default case. Tidy.
11991 * target.h (struct target_ops): Rename insert_watchpoint to
11992 insert_point, and remove_watchpoint to remove_point.
11993
11994 * linux-low.h (struct linux_target_ops): Likewise.
11995 * linux-low.c (linux_insert_watchpoint): Rename to ...
11996 (linux_insert_point): ... this. Adjust.
11997 (linux_remove_watchpoint): Rename to ...
11998 (linux_remove_point): ... this. Adjust.
11999 (linux_target_ops): Adjust.
12000 * linux-crisv32-low.c (cris_insert_watchpoint): Rename to ...
12001 (cris_insert_point): ... this.
12002 (cris_remove_watchpoint): Rename to ...
12003 (cris_remove_point): ... this.
12004 (the_low_target): Adjust.
12005
0f54c268
PM
120062009-06-24 Pierre Muller <muller@ics.u-strasbg.fr>
12007
12008 * server.c (handle_v_kill): Pass signal_pid to
12009 kill_inferior if multi_process is zero.
12010
c6314022
AR
120112009-06-23 Aleksandar Ristovski <aristovski@qnx.com>
12012
12013 * server.c (process_serial_event): Add support for Z0 and Z1 packet.
12014 * target.h (target_ops): Comment for *_watchpoint to make it clear
12015 the functions can get types '0' and '1'.
12016
4463ce24
AR
120172009-06-22 Aleksandar Ristovski <aristovski@qnx.com>
12018
12019 * linux-low.c (usr_fetch_inferior_registers): Remove check for regno 0.
12020 * proc-service.c (ps_lgetregs): Pass -1 to fetch all registers.
12021 * regcache.c (get_regcache): Likewise.
12022 * spu-low.c (spu_fetch_registers): Remove 0 to -1 conversion.
12023 * win32-low.c (child_fetch_inferior_registers): Remove check for
12024 regno 0.
12025
cf8fd78b
PA
120262009-06-19 Aleksandar Ristovski <aristovski@qnx.com>
12027 Pedro Alves <pedro@codesourcery.com>
12028
12029 * target.h (struct target_ops) <supports_multi_process>: New
12030 callback.
12031 (target_supports_multi_process): New.
12032 * server.c (handle_query): Even if GDB reports support, only
12033 enable multi-process if the target also supports it. Report
12034 multi-process support only if the target backend supports it.
12035 * linux-low.c (linux_supports_multi_process): New function.
12036 (linux_target_ops): Install it as target_supports_multi_process
12037 callback.
12038
47c0c975
DE
120392009-05-24 Doug Evans <dje@google.com>
12040
e09875d4
DE
12041 Global renaming of find_thread_pid to find_thread_ptid.
12042 * server.h (find_thread_ptid): Renamed from find_thread_pid.
12043 * inferiors.c (find_thread_ptid): Renamed from find_thread_pid.
12044 All callers updated.
12045
e27d73f6
DE
12046 * linux-low.c (handle_extended_wait): Use linux_resume_one_lwp
12047 to resume the newly created thread, don't call ptrace (PTRACE_CONT)
12048 directly.
12049
47c0c975
DE
12050 * linux-low.c (get_stop_pc): Print pc if debug_threads.
12051 (check_removed_breakpoint, linux_wait_for_lwp): Ditto.
12052 (linux_resume_one_lwp): Ditto.
12053
2acc282a
DE
120542009-05-23 Doug Evans <dje@google.com>
12055
12056 * linux-low.c (linux_resume_one_lwp): Change type of first arg
12057 from struct inferior_list_entry * to struct lwp_info *.
12058 All callers updated.
12059
9f1036c1
DE
120602009-05-13 Doug Evans <dje@google.com>
12061
12062 * linux-x86-low.c: Don't include assert.h.
12063 (x86_siginfo_fixup): Use fatal, not assert.
12064 (x86_arch_setup): Fix comment.
12065
d0722149
DE
120662009-05-12 Doug Evans <dje@google.com>
12067
12068 Biarch support for i386/amd64 gdbserver.
12069 * Makefile.in (SFILES): Remove linux-i386-low.c, linux-x86-64-low.c.
12070 Add linux-x86-low.c.
12071 (linux-i386-low.o, linux-x86-64-low.o): Delete.
12072 (linux-x86-low.o): Add.
12073 * linux-x86-64-low.c: Delete.
12074 * linux-i386-low.c: Delete.
12075 * linux-x86-low.c: New file.
12076 * configure.srv (i?86-linux srv_tgtobj): Replace linux-i386-low.o with
12077 linux-x86-low.o.
12078 (x86_64-linux srv_tgtobj): Replace linux-x86-64-low.o with
12079 linux-x86-low.o.
12080 (x86_64-linux srv_regobj): Add reg-i386-linux.o.
12081 * linux-low.c: Include ansidecl.h, elf/common.h, elf/external.h.
12082 (linux_child_pid_to_exec_file): New function.
12083 (elf_64_header_p, elf_64_file_p): New functions.
12084 (siginfo_fixup): New function.
12085 (linux_xfer_siginfo): New local inf_siginfo. Call siginfo_fixup to
12086 give target a chance to convert layout.
12087 * linux-low.h (linux_target_ops): New member siginfo_fixup.
12088 (linux_child_pid_to_exec_file, elf_64_file_p): Declare.
12089
fdeb2a12
DE
120902009-05-07 Doug Evans <dje@google.com>
12091
12092 * linux-low.c (regsets_fetch_inferior_registers): Fix memory leak.
12093 (regsets_store_inferior_registers): Ditto.
12094
a6dbe5df
PA
120952009-05-06 Pedro Alves <pedro@codesourcery.com>
12096
12097 PR server/10048
12098
12099 * linux-low.c (must_set_ptrace_flags): Delete.
12100 (linux_create_inferior): Set `lwp->must_set_ptrace_flags' instead
12101 of the global.
12102 (linux_attach_lwp_1): Don't set PTRACE_SETOPTIONS here. Set
12103 `lwp->must_set_ptrace_flags' instead.
ba42693b 12104 (linux_wait_for_event_1): Set ptrace options here.
a6dbe5df
PA
12105 (linux_wait_1): ... not here.
12106
5091eb23
DE
121072009-04-30 Doug Evans <dje@google.com>
12108
9f767825
DE
12109 * inferiors.c (started_inferior_callback): New function.
12110 (attached_inferior_callback): New function.
12111 (have_started_inferiors_p, have_attached_inferiors_p): New functions.
12112 * server.c (print_started_pid, print_attached_pid): New functions.
12113 (detach_or_kill_for_exit): New function.
12114 (main): Call it instead of for_each_inferior (kill_inferior_callback).
12115 * server.h (have_started_inferiors_p): Declare.
12116 (have_attached_inferiors_p): Declare.
12117
5091eb23
DE
12118 * inferiors.c (remove_process): Fix memory leak, free process.
12119 * linux-low.c (linux_remove_process): New function.
12120 (linux_kill): Call it instead of remove_process.
12121 (linux_detach, linux_wait_1): Ditto.
12122
155c8968
PA
121232009-04-19 Danny Backx <dannybackx@users.sourceforge.net>
12124
12125 * configure.srv: Add x86 Windows CE target.
12126
7fe519cb
UW
121272009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
12128
12129 * inferiors.c (get_thread_process): Make global.
12130 * server.h (get_thread_process): Add prototype.
12131 * thread-db.c (find_one_thread): Use get_thread_process
12132 instead of current_process.
12133 (thread_db_get_tls_address): Do not crash if called when
12134 thread layer is not yet initialized.
12135
5472f405
UW
121362009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
12137
12138 * remote-utils.c (prepare_resume_reply): Null-terminate packet.
12139 * spu-low.c (current_tid): Rename to ...
12140 (current_ptid): ... this.
12141 (fetch_ppc_register, fetch_ppc_memory, store_ppc_memory,
12142 spu_proc_xfer_spu, spu_resume, spu_request_interrupt): Use
12143 ptid_get_lwp (current_ptid) instead of current_tid.
12144 (spu_kill, spu_detach, spu_join, spu_wait): Use pid argument
12145 instead of current_tid. Use find_process_pid to verify pid
12146 argument is valid. Pass proper argument to remove_process.
12147 (spu_thread_alive): Compare current_ptid instead of current_tid.
12148 (spu_resume): Likewise.
12149
55ac2b99
PA
121502009-04-02 Pedro Alves <pedro@codesourcery.com>
12151
12152 * linux-low.c (usr_store_inferior_registers): Declare local `pid'
12153 variable.
12154
95954743
PA
121552009-04-01 Pedro Alves <pedro@codesourcery.com>
12156
12157 Implement the multiprocess extensions, and add linux multiprocess
12158 support.
12159
12160 * server.h (ULONGEST): Declare.
12161 (struct ptid, ptid_t): New.
12162 (minus_one_ptid, null_ptid): Declare.
12163 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
12164 (ptid_get_tid, ptid_equal, ptid_is_pid): Declare.
12165 (struct inferior_list_entry): Change `id' type from unsigned from
12166 to ptid_t.
12167 (struct sym_cache, struct breakpoint, struct
12168 process_info_private): Forward declare.
12169 (struct process_info): Declare.
12170 (current_process): Declare.
12171 (all_processes): Declare.
12172 (initialize_inferiors): Declare.
12173 (add_thread): Adjust to use ptid_t.
12174 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): Ditto.
12175 (add_process, remove_process, find_thread_pid): Declare.
12176 (find_inferior_id): Adjust to use ptid_t.
12177 (cont_thread, general_thread, step_thread): Change type to ptid_t.
12178 (multi_process): Declare.
12179 (push_event): Adjust to use ptid_t.
12180 (read_ptid, write_ptid): Declare.
12181 (prepare_resume_reply): Adjust to use ptid_t.
12182 (clear_symbol_cache): Declare.
12183 * inferiors.c (all_processes): New.
12184 (null_ptid, minus_one_ptid): New.
12185 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
12186 (ptid_get_tid, ptid_equal, ptid_is_pid): New.
12187 (add_thread): Change unsigned long to ptid. Remove gdb_id
12188 parameter. Adjust.
12189 (thread_id_to_gdb_id, thread_to_gdb_id): Change unsigned long to ptid.
12190 (gdb_id_to_thread): Rename to ...
12191 (find_thread_pid): ... this. Change unsigned long to ptid.
12192 (gdb_id_to_thread_id, find_inferior_id): Change unsigned long to ptid.
12193 (loaded_dll, pull_pid_from_list): Adjust.
12194 (add_process, remove_process, find_process_pid)
12195 (get_thread_process, current_process, initialize_inferiors): New.
12196 * target.h (struct thread_resume) <thread>: Change type to ptid_t.
12197 (struct target_waitstatus) <related_pid>: Ditto.
12198 (struct target_ops) <kill, detach>: Add `pid' argument. Change
12199 return type to int.
12200 (struct target_ops) <join>: Add `pid' argument.
12201 (struct target_ops) <thread_alive>: Change pid's type to ptid_t.
12202 (struct target_ops) <wait>: Add `ptid' field. Change return type
12203 to ptid.
12204 (kill_inferior, detach_inferior, join_inferior): Add `pid' argument.
12205 (mywait): Add `ptid' argument. Change return type to ptid_t.
12206 (target_pid_to_str): Declare.
12207 * target.c (set_desired_inferior): Adjust to use ptids.
12208 (mywait): Add new `ptid' argument. Adjust.
12209 (target_pid_to_str): New.
12210 * mem-break.h (free_all_breakpoints): Declare.
12211 * mem-break.c (breakpoints): Delelete.
12212 (set_breakpoint_at, delete_breakpoint, find_breakpoint_at)
12213 (check_mem_read, check_mem_write, delete_all_breakpoints): Adjust
12214 to use per-process breakpoint list.
12215 (free_all_breakpoints): New.
12216 * remote-utils.c (struct sym_cache) <name>: Drop `const'.
12217 (symbol_cache, all_symbols_looked_up): Delete.
12218 (hexchars): New.
12219 (ishex, unpack_varlen_hex, write_ptid, hex_or_minus_one,
12220 read_ptid): New.
12221 (prepare_resume_reply): Change ptid argument's type from unsigned
12222 long to ptid_t. Adjust. Implement W;process and X;process.
12223 (free_sym_cache, clear_symbol_cache): New.
12224 (look_up_one_symbol): Adjust to per-process symbol cache. *
12225 * server.c (cont_thread, general_thread, step_thread): Change type
12226 to ptid_t.
12227 (attached): Delete.
12228 (multi_process): New.
12229 (last_ptid): Change type to ptid_t.
12230 (struct vstop_notif) <ptid>: Change type to ptid_t.
12231 (queue_stop_reply, push_event): Change `ptid' argument's type to
12232 ptid_t.
12233 (discard_queued_stop_replies): Add `pid' argument.
12234 (start_inferior): Adjust to use ptids. Adjust to mywait interface
12235 changes. Don't reference the `attached' global.
12236 (attach_inferior): Adjust to mywait interface changes.
12237 (handle_query): Adjust to use ptids. Parse GDB's qSupported
12238 features. Handle and report "multiprocess+". Handle
12239 "qAttached:PID".
12240 (handle_v_cont): Adjust to use ptids. Adjust to mywait interface
12241 changes.
12242 (handle_v_kill): New.
12243 (handle_v_stopped): Adjust to use target_pid_to_str.
12244 (handle_v_requests): Allow multiple attaches and runs when
12245 multiprocess extensions are in effect. Handle "vKill".
12246 (myresume): Adjust to use ptids.
12247 (queue_stop_reply_callback): Add `arg' parameter. Handle it.
12248 (handle_status): Adjust to discard_queued_stop_replies interface
12249 change.
12250 (first_thread_of, kill_inferior_callback)
12251 (detach_or_kill_inferior_callback, join_inferiors_callback): New.
12252 (main): Call initialize_inferiors. Adjust to use ptids, killing
12253 and detaching from all inferiors. Handle multiprocess packet
12254 variants.
12255 * linux-low.h: Include gdb_proc_service.h.
12256 (struct process_info_private): New.
12257 (struct linux_target_ops) <pid_of>: Use ptid_get_pid.
12258 <lwpid_of>: Use ptid_get_lwp.
12259 (get_lwp_thread): Adjust.
12260 (struct lwp_info): Add `dead' member.
12261 (find_lwp_pid): Declare.
12262 * linux-low.c (thread_db_active): Delete.
12263 (new_inferior): Adjust comment.
12264 (inferior_pid): Delete.
12265 (linux_add_process): New.
12266 (handle_extended_wait): Adjust.
12267 (add_lwp): Change unsigned long to ptid.
12268 (linux_create_inferior): Add process to processes table. Adjust
12269 to use ptids. Don't set new_inferior here.
12270 (linux_attach_lwp): Rename to ...
12271 (linux_attach_lwp_1): ... this. Add `initial' argument. Handle
12272 it. Adjust to use ptids.
12273 (linux_attach_lwp): New.
12274 (linux_attach): Add process to processes table. Don't set
12275 new_inferior here.
12276 (struct counter): New.
12277 (second_thread_of_pid_p, last_thread_of_process_p): New.
12278 (linux_kill_one_lwp): Add `args' parameter. Handle it. Adjust to
12279 multiple processes.
12280 (linux_kill): Add `pid' argument. Handle it. Adjust to multiple
12281 processes. Remove process from process table.
12282 (linux_detach_one_lwp): Add `args' parameter. Handle it. Adjust
12283 to multiple processes.
12284 (any_thread_of): New.
12285 (linux_detach): Add `pid' argument, and handle it. Remove process
12286 from processes table.
12287 (linux_join): Add `pid' argument. Handle it.
12288 (linux_thread_alive): Change unsighed long argument to ptid_t.
12289 Consider dead lwps as not being alive.
12290 (status_pending_p): Rename `dummy' argument to `arg'. Filter out
12291 threads we're not interested in.
12292 (same_lwp, find_lwp_pid): New.
12293 (linux_wait_for_lwp): Change `pid' argument's type from int to
12294 ptid_t. Adjust.
12295 (linux_wait_for_event): Rename to ...
12296 (linux_wait_for_event_1): ... this. Change `pid' argument's type
12297 from int to ptid_t. Adjust.
12298 (linux_wait_for_event): New.
12299 (linux_wait_1): Add `ptid' argument. Change return type to
12300 ptid_t. Adjust. Use last_thread_of_process_p. Remove processes
12301 that exit from the process table.
12302 (linux_wait): Add `ptid' argument. Change return type to ptid_t.
12303 Adjust.
12304 (mark_lwp_dead): New.
12305 (wait_for_sigstop): Adjust to use ptids. If a process exits while
12306 stopping all threads, mark its main lwp as dead.
12307 (linux_set_resume_request, linux_resume_one_thread): Adjust to use
12308 ptids.
12309 (fetch_register, usr_store_inferior_registers)
12310 (regsets_fetch_inferior_registers)
12311 (regsets_store_inferior_registers, linux_read_memory)
12312 (linux_write_memory): Inline `inferior_pid'.
12313 (linux_look_up_symbols): Adjust to use per-process
12314 `thread_db_active'.
12315 (linux_request_interrupt): Adjust to use ptids.
12316 (linux_read_auxv): Inline `inferior_pid'.
12317 (initialize_low): Don't reference thread_db_active.
12318 * gdb_proc_service.h (struct ps_prochandle) <pid>: Remove.
12319 * proc-service.c (ps_lgetregs): Use find_lwp_pid.
12320 (ps_getpid): Return the pid of the current inferior.
12321 * thread-db.c (proc_handle, thread_agent): Delete.
12322 (thread_db_create_event, thread_db_enable_reporting): Adjust to
12323 per-process data.
12324 (find_one_thread): Change argument type to ptid_t. Adjust to
12325 per-process data.
12326 (maybe_attach_thread): Adjust to per-process data and ptids.
12327 (thread_db_find_new_threads): Ditto.
12328 (thread_db_init): Ditto.
12329 * spu-low.c (spu_create_inferior, spu_attach): Add process to
12330 processes table. Adjust to use ptids.
12331 (spu_kill, spu_detach): Adjust interface. Remove process from
12332 processes table.
12333 (spu_join, spu_thread_alive): Adjust interface.
12334 (spu_wait): Adjust interface. Remove process from processes
12335 table. Adjust to use ptids.
12336 * win32-low.c (current_inferior_tid): Delete.
12337 (current_inferior_ptid): New.
12338 (debug_event_ptid): New.
12339 (thread_rec): Take a ptid. Adjust.
12340 (child_add_thread): Add `pid' argument. Adjust to use ptids.
12341 (child_delete_thread): Ditto.
12342 (do_initial_child_stuff): Add `attached' argument. Add process to
12343 processes table.
12344 (child_fetch_inferior_registers, child_store_inferior_registers):
12345 Adjust.
12346 (win32_create_inferior): Pass 0 to do_initial_child_stuff.
12347 (win32_attach): Pass 1 to do_initial_child_stuff.
12348 (win32_kill): Adjust interface. Remove process from processes
12349 table.
12350 (win32_detach): Ditto.
12351 (win32_join): Adjust interface.
12352 (win32_thread_alive): Take a ptid.
12353 (win32_resume): Adjust to use ptids.
12354 (get_child_debug_event): Ditto.
12355 (win32_wait): Adjust interface. Remove exiting process from
12356 processes table.
12357
bd99dc85
PA
123582009-04-01 Pedro Alves <pedro@codesourcery.com>
12359
12360 Non-stop mode support.
12361
12362 * server.h (non_stop): Declare.
12363 (gdb_client_data, handler_func): Declare.
12364 (delete_file_handler, add_file_handler, start_event_loop):
12365 Declare.
12366 (handle_serial_event, handle_target_event, push_event)
12367 (putpkt_notif): Declare.
12368 * target.h (enum resume_kind): New.
12369 (struct thread_resume): Replace `step' field by `kind' field.
12370 (TARGET_WNOHANG): Define.
12371 (struct target_ops) <wait>: Add `options' argument.
12372 <supports_non_stop, async, start_non_stop>: New fields.
12373 (target_supports_non_stop, target_async): New.
12374 (start_non_stop): Declare.
12375 (mywait): Add `options' argument.
12376 * target.c (mywait): Add `options' argument. Print child exit
12377 notifications here.
12378 (start_non_stop): New.
12379 * server.c (non_stop, own_buf, mem_buf): New globals.
12380 (struct vstop_notif): New.
12381 (notif_queue): New global.
12382 (queue_stop_reply, push_event, discard_queued_stop_replies)
12383 (send_next_stop_reply): New.
12384 (start_inferior): Adjust to use resume_kind. Adjust to mywait
12385 interface changes.
12386 (attach_inferior): In non-stop mode, don't wait for the target
12387 here.
12388 (handle_general_set): Handle QNonStop.
12389 (handle_query): When handling qC, return the current general
12390 thread, instead of the first thread of the list.
12391 (handle_query): If the backend supports non-stop mode, include
12392 QNonStop+ in the qSupported query response.
12393 (handle_v_cont): Adjust to use resume_kind. Handle resume_stop
12394 and non-stop mode.
12395 (handle_v_attach, handle_v_run): Handle non-stop mode.
12396 (handle_v_stopped): New.
12397 (handle_v_requests): Report support for vCont;t. Handle vStopped.
12398 (myresume): Adjust to use resume_kind. Handle non-stop.
12399 (queue_stop_reply_callback): New.
12400 (handle_status): Handle non-stop mode.
12401 (main): Clear non_stop flag on reconnection. Use the event-loop.
12402 Refactor serial protocol handling from here ...
12403 (process_serial_event): ... to this new function. When GDB
12404 selects any thread, select one here. In non-stop mode, wait until
12405 GDB acks all pending events before exiting.
12406 (handle_serial_event, handle_target_event): New.
12407 * remote-utils.c (remote_open): Install remote_desc in the event
12408 loop.
12409 (remote_close): Remove remote_desc from the event loop.
12410 (putpkt_binary): Rename to...
12411 (putpkt_binary_1): ... this. Add `is_notic' argument. Handle it.
12412 (putpkt_binary): New as wrapper around putpkt_binary_1.
12413 (putpkt_notif): New.
12414 (prepare_resume_reply): In non-stop mode, don't change the
12415 general_thread.
12416 * event-loop.c: New.
12417 * Makefile.in (OBJ): Add event-loop.o.
12418 (event-loop.o): New rule.
12419
12420 * linux-low.h (pid_of): Moved here.
12421 (lwpid_of): New.
12422 (get_lwp_thread): Use lwpid_of.
12423 (struct lwp_info): Delete `lwpid' field. Add `suspended' field.
12424 * linux-low.c (pid_of): Delete.
12425 (inferior_pid): Use lwpid_of.
12426 (linux_event_pipe): New.
12427 (target_is_async_p): New.
12428 (delete_lwp): New.
12429 (handle_extended_wait): Use lwpid_of.
12430 (add_lwp): Don't set lwpid field.
12431 (linux_attach_lwp): Adjust debug output. Use lwpid_of.
12432 (linux_kill_one_lwp): If killing a running lwp, stop it first.
12433 Use lwpid_of. Adjust to linux_wait_for_event interface changes.
12434 (linux_detach_one_lwp): If detaching from a running lwp, stop it
12435 first. Adjust to linux_wait_for_event interface changes. Use
12436 lwpid_of.
12437 (linux_detach): Don't delete the main lwp here.
12438 (linux_join): Use my_waitpid. Avoid signal_pid. Use lwpid_of.
12439 (status_pending_p): Don't consider explicitly suspended lwps.
12440 (linux_wait_for_lwp): Take an integer pid instead of a lwp_info
12441 pointer. Add OPTIONS argument. Change return type to int. Use
12442 my_waitpid instead of sleeping. Handle WNOHANG. Use lwpid_of.
12443 (linux_wait_for_event): Take an integer pid instead of a lwp_info
12444 pointer. Add status pointer argument. Return a pid instead of a
12445 status. Use lwpid_of. Adjust to linux_wait_for_lwp interface
12446 changes. In non-stop mode, don't switch to a random thread.
12447 (linux_wait): Rename to...
12448 (linux_wait_1): ... this. Add target_options argument, and handle
12449 it. Adjust to use resume_kind. Use lwpid_of. In non-stop mode,
12450 don't handle the continue thread. Handle TARGET_WNOHANG. Merge
12451 clean exit and signal exit code. Don't stop all threads in
12452 non-stop mode. In all-stop mode, only stop all threads when
12453 reporting a stop to GDB. Handle explicit thread stop requests.
12454 (async_file_flush, async_file_mark): New.
12455 (linux_wait): New.
12456 (send_sigstop): Use lwpid_of.
12457 (wait_for_sigstop): Use lwpid_of. Adjust to linux_wait_for_event
12458 interface changes. In non-stop mode, don't switch to a random
12459 thread.
12460 (linux_resume_one_lwp): Use lwpid_of.
12461 (linux_continue_one_thread, linux_queue_one_thread): Merge into ...
12462 (linux_resume_one_thread): ... this. Handle resume_stop. In
12463 non-stop mode, don't look for pending flag in all threads.
12464 (resume_status_pending_p): Don't consider explicitly suspended
12465 threads.
12466 (my_waitpid): Reimplement. Emulate __WALL.
12467 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
12468 Use lwpid_of.
12469 (sigchld_handler, linux_supports_non_stop, linux_async)
12470 (linux_start_non_stop): New.
12471 (linux_target_ops): Register linux_supports_non_stop, linux_async
12472 and linux_start_non_stop.
12473 (initialize_low): Install SIGCHLD handler.
12474 * thread-db.c (thread_db_create_event, find_one_thread)
12475 (thread_db_get_tls_address): Use lwpid_of.
12476 * win32-low.c (win32_detach): Adjust to use resume_kind.
12477 (win32_wait): Add `options' argument.
12478 * spu-low.c (spu_resume): Adjust to use resume_kind.
12479 (spu_wait): Add `options' argument.
12480
5b1c542e
PA
124812009-04-01 Pedro Alves <pedro@codesourcery.com>
12482
12483 Decouple target code from remote protocol.
12484
12485 * target.h (enum target_waitkind): New.
12486 (struct target_waitstatus): New.
12487 (struct target_ops) <wait>: Return an unsigned long. Take a
12488 target_waitstatus pointer instead of a char pointer.
12489 (mywait): Likewise.
12490 * target.c (mywait): Change prototype to return an unsigned long.
12491 Take a target_waitstatus pointer instead of a char pointer. Adjust.
12492 * server.h (thread_from_wait, old_thread_from_wait): Delete
12493 declarations.
12494 (prepare_resume_reply): Change prototype to take a
12495 target_waitstatus.
12496 * server.c (thread_from_wait, old_thread_from_wait): Delete.
12497 (last_status, last_ptid): New.
12498 (start_inferior): Remove "statusptr" argument. Adjust. Return a
12499 pid instead of a signal.
12500 (attach_inferior): Remove "status" and "signal" parameters.
12501 Adjust.
12502 (handle_query): For qGetTLSAddr, parse the thread id with strtol,
12503 not as an address.
12504 (handle_v_cont, handle_v_attach, handle_v_run, handle_v_kill)
12505 (handle_v_requests, myresume): Remove "status" and "signal"
12506 parameters. Adjust.
12507 (handle_status): New.
12508 (main): Delete local `status'. Adjust.
12509 * remote-utils.c: Include target.h.
12510 (prepare_resume_reply): Change prototype to take a
12511 target_waitstatus. Adjust.
12512
12513 * linux-low.c (linux_wait): Adjust to new target_ops->wait
12514 interface.
12515 * spu-low.c (spu_wait): Adjust.
12516 * win32-low.c (enum target_waitkind, struct target_waitstatus):
12517 Delete.
12518 (win32_wait): Adjust.
12519
2bd7c093
PA
125202009-04-01 Pedro Alves <pedro@codesourcery.com>
12521
12522 * target.h (struct thread_resume): Delete leave_stopped member.
12523 (struct target_ops): Add a `n' argument to the `resume' callback.
12524 * server.c (start_inferior): Adjust.
12525 (handle_v_cont, myresume): Adjust.
12526 * linux-low.c (check_removed_breakpoint): Adjust to resume
12527 interface change, and to removed leave_stopped field.
12528 (resume_ptr): Delete.
12529 (struct thread_resume_array): New.
12530 (linux_set_resume_request): Add new `arg' parameter. Adjust to
12531 resume interface change.
12532 (linux_continue_one_thread, linux_queue_one_thread)
12533 (resume_status_pending_p): Check if the resume field is NULL
12534 instead of checking the leave_stopped member.
12535 (linux_resume): Adjust to the target resume interface change.
12536 * spu-low.c (spu_resume): Adjust to the target resume interface
12537 change.
12538 * win32-low.c (win32_detach, win32_resume): Ditto.
12539
c35fafde
PA
125402009-04-01 Pedro Alves <pedro@codesourcery.com>
12541
12542 * linux-low.c (linux_wait_for_event): Don't clear the `stepping'
12543 flag.
12544 (wait_for_sigstop): Don't leave a finished single-step SIGTRAP
12545 pending.
12546 (linux_continue_one_thread): Only preserve the stepping flag if
12547 there's a pending breakpoint.
12548
0a59d50b
PA
125492009-03-31 Pedro Alves <pedro@codesourcery.com>
12550
12551 * server.c (main): After the inferior having exited, call
12552 remote_close before exiting gdbserver.
12553
f04c6d38
TJB
125542009-03-25 Thiago Jung Bauermann <bauerman@br.ibm.com>
12555
12556 Fix size of FPSCR in Power 7 processors.
12557 * linux-ppc-low.c (PPC_FEATURE_ARCH_2_05): Remove #define.
12558 (PPC_FEATURE_HAS_DFP): New #define.
12559 (ppc_arch_setup): Check for DFP feature instead of ISA 2.05 to decide on
12560 size of the FPSCR.
12561
78e5cee6
PA
125622009-03-23 Pedro Alves <pedro@codesourcery.com>
12563
12564 * server.c (handle_query) Whitespace and formatting.
12565
1b3f6016
PA
125662009-03-22 Pedro Alves <pedro@codesourcery.com>
12567
12568 * i387-fp.c, linux-arm-low.c, linux-cris-low.c,
12569 linux-crisv32-low.c, linux-i386-low.c, linux-low.c,
12570 linux-mips-low.c, linux-s390-low.c, linux-sparc-low.c,
12571 linux-x86-64-low.c, linux-xtensa-low.c, proc-service.c,
12572 regcache.c, remote-utils.c, server.c, spu-low.c, target.h,
12573 thread-db.c, win32-low.c, xtensa-xtregs.c, gdbreplay.c,
12574 Makefile.in, configure.ac: Fix whitespace throughout.
12575 * configure: Regenerate.
12576
a07b2135
PA
125772009-03-22 Pedro Alves <pedro@codesourcery.com>
12578
12579 * inferiors.c (find_inferior): Make it safe for the callback
12580 function to delete the currently iterated inferior.
12581
67cc2626
PA
125822009-03-22 Pedro Alves <pedro@codesourcery.com>
12583
12584 * Makefile.in (linuw_low_h): Move higher.
12585 (thread-db.o): Depend on $(linux_low_h).
12586
54a0b537
PA
125872009-03-17 Pedro Alves <pedro@codesourcery.com>
12588
12589 Rename "process" to "lwp" throughout.
12590
12591 * linux-low.c (all_processes): Rename to...
12592 (all_lwps): ... this.
12593 (inferior_pid, handle_extended_wait, get_stop_pc): Adjust.
12594 (add_process): Rename to ...
12595 (add_lwp): ... this. Adjust.
12596 (linux_create_inferior): Adjust.
12597 (linux_attach_lwp): Adjust.
12598 (linux_attach): Adjust.
12599 (linux_kill_one_process): Rename to ...
12600 (linux_kill_one_lwp): ... this. Adjust.
12601 (linux_kill): Adjust.
12602 (linux_detach_one_process): Rename to ...
12603 (linux_detach_one_lwp): ... this. Adjust.
12604 (linux_detach): Adjust.
12605 (check_removed_breakpoint): Adjust.
12606 (status_pending_p): Adjust.
12607 (linux_wait_for_process): Rename to ...
12608 (linux_wait_for_lwp): ... this. Adjust.
12609 (linux_wait_for_event): Adjust.
12610 (send_sigstop): Adjust.
12611 (wait_for_sigstop): Adjust.
12612 (stop_all_processes): Rename to ...
12613 (stop_all_lwps): ... this.
12614 (linux_resume_one_process): Rename to ...
12615 (linux_resume_one_lwp): ... this. Adjust.
12616 (linux_set_resume_request, linux_continue_one_thread)
12617 (linux_queue_one_thread, resume_status_pending_p)
12618 (usr_store_inferior_registers, regsets_store_inferior_registers)
12619 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
12620 Adjust.
12621 * linux-low.h (get_process): Rename to ...
12622 (get_lwp): ... this. Adjust.
12623 (get_thread_process): Rename to ...
12624 (get_thread_lwp): ... this. Adjust.
12625 (get_process_thread): Rename to ...
12626 (get_lwp_thread): ... this. Adjust.
12627 (struct process_info): Rename to ...
12628 (struct lwp_info): ... this.
12629 (all_processes): Rename to ...
12630 (all_lwps): ... this.
12631 * proc-service.c (ps_lgetregs): Adjust.
12632 * thread-db.c (thread_db_create_event, find_one_thread)
12633 (maybe_attach_thread, thread_db_get_tls_address): Adjust.
12634
0b16c5cf
PA
126352009-03-14 Pedro Alves <pedro@codesourcery.com>
12636
12637 * server.c (handle_query): Handle "qAttached".
12638
32de4b9d
NS
126392009-03-13 Nathan Sidwell <nathan@codesourcery.com>
12640
12641 * Makefile.in, hostio-errno.c, errno.c, xtensa-xtregs.c: Change to
12642 GPLv3, update license URL.
12643
2aecd87f
DE
126442009-03-01 Doug Evans <dje@google.com>
12645
93efd302 12646 * Makefile.in (INCLUDE_CFLAGS): Add -I$(srcdir)/../common.
2aecd87f
DE
12647 (server_h): Add gdb_signals.h.
12648 (signals.o): Update.
12649 * server.h (target_signal_from_host,target_signal_to_host_p)
12650 (target_signal_to_host,target_signal_to_name): Moved to gdb_signals.h.
12651
86b1f9c5
PM
126522009-02-14 Pierre Muller <muller@ics.u-strasbg.fr>
12653
12654 * remote-utils.c (getpkt): Also generate remote-debug
12655 information if noack_mode is set.
12656
4aa995e1
PA
126572009-02-06 Pedro Alves <pedro@codesourcery.com>
12658
12659 * server.c (handle_query): Report qXfer:siginfo:read and
12660 qXfer:siginfo:write as supported and handle them.
12661 * target.h (struct target_ops) <qxfer_siginfo>: New field.
12662 * linux-low.c (linux_xfer_siginfo): New.
12663 (linux_target_ops): Set it.
12664
62709adf
PA
126652009-01-26 Pedro Alves <pedro@codesourcery.com>
12666
12667 * server.c (gdbserver_usage): Mention --remote-debug.
12668 (main): Accept '--remote-debug' switch.
12669
aef93bd7
DE
126702009-01-18 Doug Evans <dje@google.com>
12671
12672 * regcache.c (new_register_cache): No need to check result of xcalloc.
12673 * server.c (handle_search_memory): Back out calls to xmalloc,
12674 result is checked and error is returned to user upon failure.
12675 (handle_query): Ditto. Add more checks for result of malloc.
12676 (handle_v_cont): Check result of malloc, report error back to
12677 user upon failure.
12678 (handle_v_run): Ditto. Call freeargv.
12679 * server.h (freeargv): Declare.
12680 * utils.c (freeargv): New fn.
12681
54363045
DE
126822009-01-15 Doug Evans <dje@google.com>
12683
f626972c
DE
12684 * gdbreplay.c (perror_with_name): Make arg const char *.
12685 * server.h (target_signal_to_name): Make return type const char *.
0842e787 12686 * thread-db.c (thread_db_err_str): Make return type const char *.
f626972c 12687 * utils.c (perror_with_name): Make arg const char *.
54363045 12688
18aae699
PA
126892009-01-14 Pedro Alves <pedro@codesourcery.com>
12690
12691 * win32-low.c (get_child_debug_event): Issue a final DBG_CONTINUE
12692 when handling a EXIT_PROCESS_DEBUG_EVENT.
12693
ff703abe
JB
126942009-01-06 Joel Brobecker <brobecker@adacore.com>
12695
12696 * gdbreplay.c (gdbreplay_version): Update copyright year.
12697 * server.c (gdbserver_version): Likewise.
12698
f21cc1a2 126992009-01-05 Doug Evans <dje@google.com>
0e21c1ec
DE
12700
12701 * linux-low.c (linux_attach_lwp): Add some comments/fixmes.
f21cc1a2 12702 (handle_extended_wait): Improve comment.
0e21c1ec 12703
bca929d3
DE
127042008-12-13 Doug Evans <dje@google.com>
12705
12706 * utils.c (xmalloc,xcalloc,xstrdup): New fns.
12707 * server.h (ATTR_MALLOC): New macro.
12708 (xmalloc,xcalloc,xstrdup): Declare.
12709 * hostio.c: Replace malloc,calloc,strdup with xmalloc,xcalloc,xstrdup.
12710 * inferiors.c: Ditto.
12711 * linux-low.c: Ditto.
12712 * mem-break.c: Ditto.
12713 * regcache.c: Ditto.
12714 * remote-utils.c: Ditto.
12715 * server.c: Ditto.
12716 * target.c: Ditto.
12717 * win32-low.c: Ditto.
12718
97438e3f
DE
127192008-12-12 Doug Evans <dje@google.com>
12720
896c7fbb
DE
12721 * linux-low.c (linux_wait_for_process): Don't clobber current_inferior
12722 in debugging printf.
12723
97438e3f
DE
12724 * linux-low.c (handle_extended_wait): Simplify, use my_waitpid.
12725
e3b886f8
DE
127262008-12-09 Doug Evans <dje@google.com>
12727
12728 * linux-low.h (struct process_info): Delete member tid, unused.
12729 * thread-db.c (find_one_thread): Update.
12730 (maybe_attach_thread): Update.
12731
07e059b5
VP
127322008-12-02 Pedro Alves <pedro@codesourcery.com>
12733
889bf7c5
PA
12734 * target.h (struct target_ops): Add qxfer_osdata member.
12735 * linux-low.c: Include ctype.h and pwd.h and sys/types.h
12736 and dirent.h.
12737 (linux_qxfer_osdata): New functions.
12738 (linux_target_ops): Register linux_qxfer_osdata as qxfer_osdata
12739 callback.
12740 * server.c (handle_query): Handle "qXfer:osdata:read:".
12741 * remote-utils.c (buffer_grow, buffer_free, buffer_init, buffer_finish)
12742 (buffer_xml_printf): New functions.
12743 * server.h (struct buffer): New.
12744 (buffer_grow_str, buffer_grow_str0): New macros.
12745 (buffer_grow, buffer_free, buffer_init, buffer_finish)
12746 (buffer_xml_printf): Declare.
07e059b5 12747
4cab47ab
DE
127482008-11-24 Doug Evans <dje@google.com>
12749
12750 * Makefile.in (VERSION,DIST,LINT,LINTFLAGS): Delete, unused.
12751
f142445f
DJ
127522008-11-24 Daniel Jacobowitz <dan@codesourcery.com>
12753
12754 * server.c (handle_v_run): Always use the supplied argument list.
12755
d0107bb6 127562008-11-19 Bob Wilson <bob.wilson@acm.org>
889bf7c5 12757
d0107bb6
BW
12758 * xtensa-xtregs.c (XTENSA_ELF_XTREG_SIZE): Change to 4.
12759 (xtensa_regmap_table): Add entry for scompare1.
889bf7c5 12760
2c4ad781
TJB
127612008-11-18 Thiago Jung Bauermann <bauerman@br.ibm.com>
12762
12763 * Makefile.in (powerpc-isa205-32l.o, powerpc-isa205-32l.c,
12764 powerpc-isa205-altivec32l.o, powerpc-isa205-altivec32l.c,
12765 powerpc-isa205-vsx32l.o, powerpc-isa205-vsx32l.c,
12766 powerpc-isa205-64l.o, powerpc-isa205-64l.c,
12767 powerpc-isa205-altivec64l.o, powerpc-isa205-altivec64l.c,
12768 powerpc-isa205-vsx64l.o, powerpc-isa205-vsx64l.c): New targets.
12769 * configure.srv (powerpc*-*-linux*): Add ISA 2.05 object files and
12770 XML target descriptions.
12771 * linux-ppc-low.c (ppc_arch_setup): Init registers with 64-bit FPSCR
12772 when inferior is running on an ISA 2.05 or later processor. Add
12773 special case to return offset for full 64-bit slot of FPSCR when
12774 in 32-bits.
12775
dfb64f85
DJ
127762008-11-14 Daniel Gutson <dgutson@codesourcery.com>
12777
12778 * Makefile.in (SFILES, clean): Added sparc64 files.
12779 (reg-sparc64.o, reg-sparc64.c): New.
12780 * configure.srv (sparc*-*-linux*): New configuration.
12781 * linux-low.c (regsets_fetch_inferior_registers): Swap ptrace
12782 syscall arguments for SPARC.
12783 (regsets_store_inferior_registers): Likewise.
12784 * linux-sparc-low.c: New file.
12785
66b6e1dd
DE
127862008-10-21 Doug Evans <dje@google.com>
12787
12788 * Makefile.in (BFD_DIR,BFD,BFD_SRC,BFD_CFLAGS): Delete.
12789 (READLINE_DIR,READLINE_DEP): Delete.
12790 (INTERNAL_CFLAGS): Update.
12791 (LINTFLAGS): Update.
12792
9b710a42
PA
127932008-10-10 Pedro Alves <pedro@codesourcery.com>
12794
12795 * server.c (handle_v_run): If GDB didn't specify an argv, use the
12796 whole argv from the last run, not just argv[0].
12797
5822d809
PA
127982008-09-08 Pedro Alves <pedro@codesourcery.com>
12799
12800 * regcache.c (new_register_cache): Return NULL if the register
12801 cache size isn't known yet.
12802 (free_register_cache): Avoid dereferencing a NULL regcache.
12803
74aac56f
DJ
128042008-09-04 Daniel Jacobowitz <dan@codesourcery.com>
12805
12806 * configure.srv: Merge MIPS and MIPS64.
12807
400b20f5
MR
128082008-08-24 Maciej W. Rozycki <macro@linux-mips.org>
12809
12810 * Makefile.in (uninstall): Apply $(EXEEXT) too.
12811
677c5bb1
LM
128122008-08-18 Luis Machado <luisgpm@br.ibm.com>
12813
12814 * Makefile.in: Add required vsx dependencies.
12815
12816 * linux-ppc-low: Define PPC_FEATURE_HAS_VSX.
12817 Declare init_registers_powerpc_vsx32l.
12818 Declare init_registers_powerpc_vsx64l.
12819 Define PTRACE_GETVSXREGS and PTRACE_SETVSXREGS.
12820 (ppc_arch_setup): Check for VSX in hwcap.
12821 (ppc_fill_vsxregset): New function.
12822 (ppc_store_vsxregset): New function.
12823 Add new VSX entry in regset_info target_regsets.
12824
12825 * configure.srv: Add new VSX dependencies.
12826
a6f3e723
SL
128272008-08-12 Pedro Alves <pedro@codesourcery.com>
12828
12829 * remote-utils.c (noack_mode, transport_is_reliable): New globals.
12830 (remote_open): Set or clear transport_is_reliable.
12831 (putpkt_binary): Don't expect acks in noack mode.
12832 (getpkt): Don't send ack/nac in noack mode.
12833 * server.c (handle_general_set): Handle QStartNoAckMode.
12834 (handle_query): If connected by tcp pass QStartNoAckMode+ in
12835 qSupported.
12836 (main): Reset noack_mode on every connection.
12837 * server.h (noack_mode): Declare.
12838
a417dc56
RW
128392008-08-07 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
12840
12841 * Makefile.in (GDBREPLAY_OBS): New variable.
12842 (gdbreplay$(EXEEXT)): Use it to avoid unportable $^.
12843
3221518c
UW
128442008-08-05 Ulrich Weigand <uweigand@de.ibm.com>
12845 Daniel Jacobowitz <dan@codesourcery.com>
12846
12847 * linux-low.c (linux_resume_one_process): Ignore ESRCH.
12848 (usr_store_inferior_registers): Likewise.
12849 (regsets_store_inferior_registers): Likewise.
12850
ec56be1b
PA
128512008-07-31 Rolf Jansen <rj@surtec.com>
12852 Pedro Alves <pedro@codesourcery.com>
12853
12854 * configure.ac: Check for memmem declaration.
12855 * server.c [HAVE_MALLOC_H]: Include malloc.h.
12856 (disable_packet_vCont, disable_packet_Tthread, disable_packet_qC)
12857 (disable_packet_qfThreadInfo): Unconditionally compile.
12858 * server.h [!HAVE_DECL_MEMMEM]: Declare memmem.
12859 * configure, config.in: Regenerate.
12860
2fe5e3ff
DE
128612008-07-28 Doug Kwan <dougkwan@google.com>
12862
12863 * linux-low.c (sys/dir.h, sys/user.h): Remove includes.
12864 (linux_write_memory): Remove declaration of errno.
12865
836acd6d
UW
128662008-07-12 Ulrich Weigand <uweigand@de.ibm.com>
12867
12868 * linux-low.c (handle_extended_wait): Do not use "status"
12869 variable uninitialized.
12870
aeba519e
PA
128712008-07-07 Pedro Alves <pedro@codesourcery.com>
12872
12873 * server.c (handle_v_attach): Inhibit reporting dll changes.
12874
db42f210
PA
128752008-06-27 Pedro Alves <pedro@codesourcery.com>
12876
12877 * remote-utils.c (prepare_resume_reply): If requested, don't
12878 output "thread:TID" in the T stop reply.
12879
12880 * server.c (disable_packet_vCont, disable_packet_Tthread)
12881 (disable_packet_qC, disable_packet_qfThreadInfo): New globals.
12882 (handle_query): If requested, disable support for qC, qfThreadInfo
12883 and qsThreadInfo.
12884 (handle_v_requests): If requested, disable support for vCont.
12885 (gdbserver_show_disableable): New.
12886 (main): Handle --disable-packet and --disable-packet=LIST.
12887
12888 * server.h (disable_packet_vCont, disable_packet_Tthread)
12889 (disable_packet_qC, disable_packet_qfThreadInfo): Declare.
12890
8e4c5421
CD
128912008-06-20 Carlos O'Donell <carlos@codesourcery.com>
12892
12893 * server.c (gdbserver_usage): Mention --version.
12894
6e23a804
DJ
128952008-06-06 Daniel Jacobowitz <dan@codesourcery.com>
12896
12897 * Makefile.in (gdbreplay.o): New rule.
12898
90aa6a40
JM
128992008-06-06 Joseph Myers <joseph@codesourcery.com>
12900
12901 * gdbreplay.c (gdbreplay_version): Say gdbreplay in version
12902 message, not gdbserver.
12903
c16158bc 129042008-06-05 Vladimir Prus <vladimir@codesourcery.com>
889bf7c5
PA
12905 Nathan Sidwell <nathan@codesourcery.com>
12906 Joseph Myers <joseph@codesourcery.com>
c16158bc
JM
12907
12908 * acinclude.m4: Include ../../config/acx.m4.
12909 * configure.ac: Use ACX_PKGVERSION and ACX_BUGURL.
12910 * configure, config.in: Regenerate.
12911 * Makefile.in (gdbreplay$(EXEEXT)): Add version.o.
12912 * server.c (gdbserver_version): Print PKGVERSION.
12913 (gdbsrever_usage): Add stream parameter. Print REPORT_BUGS_TO.
12914 (main): Adjust gdbserver_usage calls.
12915 * gdbreplay.c (version, host_name): Add declarations.
12916 (gdbreplay_version, gdbreplay_usage): New.
12917 (main): Accept --version and --help options.
12918
aeb75bf5
DJ
129192008-06-04 Daniel Jacobowitz <dan@codesourcery.com>
12920
12921 * linux-arm-low.c (thumb_breakpoint, thumb_breakpoint_len): New.
12922 (arm_breakpoint_at): Handle Thumb.
12923 (the_low_target): Add comment.
12924
76b233dd
UW
129252008-05-29 Ulrich Weigand <uweigand@de.ibm.com>
12926
12927 * linux-ppc-low.c (ppc_collect_ptrace_register): Clear buffer.
12928
08388c79
DE
129292008-05-09 Doug Evans <dje@google.com>
12930
a3c83fae
DE
12931 * server.h (decode_search_memory_packet): Declare.
12932 * remote-utils.c (decode_search_memory_packet): New fn.
12933 * server.c (handle_search_memory_1): New fn.
08388c79
DE
12934 (handle_search_memory): New fn.
12935 (handle_query): Process qSearch:memory packets.
12936
bb9c3d36
UW
129372008-05-08 Ulrich Weigand <uweigand@de.ibm.com>
12938
12939 * regcache.c (registers_length): Remove.
12940 (set_register_cache): Verify that PBUFSIZ is large enough to hold a
12941 full register packet.
12942 * regcache.h (registers_length): Remove prototype.
12943 * server.h (PBUFSIZ): Define to 16384.
12944
7284e1be
UW
129452008-05-03 Ulrich Weigand <uweigand@de.ibm.com>
12946
12947 * configure.srv (powerpc*-*-linux*): Set srv_regobj to
12948 powerpc-32l.o, powerpc-altivec32l.o, powerpc-e500l.o,
12949 powerpc-64l.o, and powerpc-altivec64l.o.
12950 Remove rs6000/powerpc-32.xml, rs6000/powerpc-64.xml, and
12951 rs6000/powerpc-e500.xml; add rs6000/powerpc-32l.xml,
12952 rs6000/powerpc-altivec32l.xml, rs6000/powerpc-e500l.xml,
12953 rs6000/powerpc-64l.xml, rs6000/powerpc-altivec64l.xml,
12954 rs6000/power-linux.xml, and rs6000/power64-linux.xml
12955 to srv_xmlfiles.
12956
12957 * Makefile.in (reg-ppc.o, reg-ppc.c): Remove, replace by ...
12958 (powerpc-32l.o, powerpc-32l.c): ... these new rules.
12959 (powerpc-32.o, powerpc-32.c): Remove, replace by ...
12960 (powerpc-altivec32l.o, powerpc-altivec32l.c): ... these new rules.
12961 (powerpc-e500.o, powerpc-e500.c): Remove, replace by ...
12962 (powerpc-e500l.o, powerpc-e500l.c): ... these new rules.
12963 (reg-ppc64.o, reg-ppc64.c): Remove, replace by ...
12964 (powerpc-64l.o, powerpc-64l.c): ... these new rules.
12965 (powerpc-64.o, powerpc-64.c): Remove, replace by ...
12966 (powerpc-altivec64l.o, powerpc-altivec64l.c): ... these new rules.
12967 (clean): Update.
12968
12969 * linux-ppc-low.c (init_registers_ppc): Remove, replace by ...
12970 (init_registers_powerpc_32l): ... this new prototype.
12971 (init_registers_powerpc_32): Remove, replace by ...
12972 (init_registers_powerpc_altivec32l): ... this new prototype.
12973 (init_registers_powerpc_e500): Remove, replace by ...
12974 (init_registers_powerpc_e500l): ... this new prototype.
12975 (init_registers_ppc64): Remove, replace by ...
12976 (init_registers_powerpc_64l): ... this new prototype.
12977 (init_registers_powerpc_64): Remove, replace by ...
12978 (init_registers_powerpc_altivec64l): ... this new prototype.
12979 (ppc_num_regs): Set to 73.
12980 (PT_ORIG_R3, PT_TRAP): Define if necessary.
12981 (ppc_regmap, ppc_regmap_e500): Add values for orig_r3 and trap.
12982 (ppc_cannot_store_register): Handle orig_r3 and trap.
12983 (ppc_arch_setup): Update init_registers_... calls.
12984 (ppc_fill_gregset): Handle orig_r3 and trap.
12985
12986 * inferiors.c (clear_inferiors): Reset current_inferior.
12987
fdc59709
PB
129882008-04-23 Paolo Bonzini <bonzini@gnu.org>
12989
889bf7c5
PA
12990 * acinclude.m4: Add override.m4.
12991 * configure: Regenerate.
fdc59709 12992
c9b2f845
UW
129932008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
12994
12995 * linux-ppc-low.c (ppc_arch_setup): Reset ppc_hwcap after the
12996 initial call to init_register_ppc64.
12997
550512b8
UW
129982008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
12999
43aaf8b6
PA
13000 * configure.srv (powerpc64-*-linux*, powerpc-*-linux*): Merge into
13001 single powerpc*-*-linux* case.
550512b8
UW
13002 (s390-*-linux*, s390x-*-linux*): Merge into single s390*-*-linux* case.
13003
b6430ec3
UW
130042008-04-17 Ulrich Weigand <uweigand@de.ibm.com>
13005
13006 * configure.srv [powerpc64-*-linux*]: Remove powerpc-e500.o from
889bf7c5 13007 srv_regobj. Remove rs6000/powerpc-e500.xml and rs6000/power-spe.xml
b6430ec3
UW
13008 from reg_xmlfiles.
13009 * linux-ppc-low.c: Include <elf.h>.
13010 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Define.
13011 (ppc_hwcap): New global variable.
13012 (ppc_regmap): Remove __SPE__ #ifdef sections.
13013 (ppc_regmap_e500): New global variable.
13014 (ppc_cannot_store_register): Update __SPE__ special case.
13015 (ppc_get_hwcap): New function.
13016 (ppc_arch_setup): Use it to determine whether inferior supports
13017 AltiVec or SPE registers. Set the_low_target.regmap if appropriate.
13018 (ppc_fill_vrregset, ppc_store_vrregset): Define unconditionally.
13019 Do not access registers if target does not support AltiVec.
13020 (ppc_fill_evrregset, ppc_store_evrregset): Define unconditionally.
13021 Do not access registers if target does not support SPE.
13022 (target_regsets): Unconditionally include AltiVec and SPE regsets.
13023
52fa2412
UW
130242008-04-17 Daniel Jacobowitz <dan@codesourcery.com>
13025
13026 * linux-low.c (disabled_regsets, num_regsets): New.
13027 (use_regsets_p): Delete.
13028 (linux_wait_for_process): Clear disabled_regsets.
13029 (regsets_fetch_inferior_registers): Check and set it.
13030 (regsets_store_inferior_registers): Likewise.
13031 (linux_fetch_registers, linux_store_registers): Do not use
13032 use_regsets_p.
13033 (initialize_low): Allocate disabled_regsets.
13034
e28b3332
DJ
130352008-04-14 Daniel Jacobowitz <dan@codesourcery.com>
13036
13037 * Makefile.in (LIBOBJS): New.
13038 (OBS): Use LIBOBJS.
13039 (memmem.o): New rule.
13040 * configure.ac: Use AC_CONFIG_LIBOBJ_DIR and check for memmem.
13041 * configure: Regenerated.
13042
4536995d
UW
130432008-04-04 Ulrich Weigand <uweigand@de.ibm.com>
13044
13045 * server.c (handle_query): Never return "unsupported" for
13046 qXfer:features:read queries.
13047
221c031f
UW
130482008-03-27 Ulrich Weigand <uweigand@de.ibm.com>
13049
13050 * server.c (get_features_xml): Fix inverted condition.
13051 (handle_query): Always support qXfer:feature:read.
13052
ccd213ac
DJ
130532008-03-10 Daniel Jacobowitz <dan@codesourcery.com>
13054
13055 * server.c (wrapper_argv): New.
13056 (start_inferior): Handle wrapper_argv. If set, expect an extra
13057 trap.
13058 (gdbserver_usage): Document --wrapper.
13059 (main): Parse --wrapper.
13060
6fe305f7
UW
130612008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
13062
13063 * configure.srv [powerpc64-*-linux*]: Add all files mentioned for
13064 powerpc-*-linux* to srv_regobj and reg_xmlfiles.
13065 * linux-ppc-low.c (ppc_get_pc): Support bi-arch operation.
13066 (ppc_set_pc): Likewise.
13067 (ppc_arch_setup): New function.
13068 (ppc_fill_gregset): Call ppc_collect_ptrace_register instead
13069 of collect_register.
889bf7c5 13070 (the_low_target): Use ppc_arch_setup as arch_setup initializer.
6fe305f7 13071
5b0a002e
UW
130722008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
13073
13074 * configure.srv [powerpc64-*-linux*]: Use linux-ppc-low.o
13075 instead of linux-ppc64-low.o.
13076 * linux-ppc64-low.c: Remove file.
13077 * Makefile.in (SFILES): Remove linux-ppc64-low.c.
13078 (linux-ppc64-low.o): Remove rule.
13079
13080 * linux-ppc-low.c (init_registers_ppc64): Add prototype.
13081 (init_registers_powerpc_64): Likewise.
13082 (ppc_regmap): Conditionally define depending on __powerpc64__.
13083 (ppc_cannot_store_register): Do not special-case "fpscr" when
13084 compiled on __powerpc64__.
13085 (ppc_collect_ptrace_register): New function.
13086 (ppc_supply_ptrace_register): New function.
13087 (ppc_breakpoint): Change type to "unsigned int".
13088 (ppc_breakpoint_at): Change type of "insn" to "unsigned int".
13089 (the_low_target): Conditionally provide initializers for the
889bf7c5 13090 arch_setup member depending on __powerpc64__. Install
5b0a002e
UW
13091 collect_ptrace_register and supply_ptrace_register members.
13092
9b4b61c8
UW
130932008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
13094
13095 * regcache.h (gdbserver_xmltarget): Add extern declaration.
13096 * server.c (gdbserver_xmltarget): Define.
13097 (get_features_xml): Use it to replace "target.xml" and arch_string.
13098
13099 * configure.srv: Remove srv_xmltarget. Add XML files that were
13100 mentioned there to srv_xmlfiles instead. Remove conditional tests
13101 on gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe; set
13102 srv_xmlfiles and srv_regobj to include all possible choices.
13103 * configure.ac (srv_xmltarget): Remove.
13104 (srv_xmlfiles): Do not add "target.xml".
13105 (gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe): Remove
13106 checks for supplementary target information.
13107 * configure: Regenerate.
13108 * Makefile.in (XML_TARGET): Remove.
13109 (target.xml): Remove rule.
13110 (clean): Do not clean up target.xml.
13111 (.PRECIOUS): Do not mention target.xml.
13112
13113 * target.h (struct target_ops): Remove arch_string member.
13114 * linux-low.c (linux_arch_string): Remove.
13115 (linux_target_ops): Remove arch_string initializer.
13116 * linux-low.h (struct linux_target_ops): Remove arch_string member.
13117 * linux-i386-low.c (the_low_target): Remove arch_string initializer.
13118 * linux-x86-64-low.c (the_low_target): Remove arch_string initializer.
13119 * spu-low.c (spu_arch_string): Remove.
13120 (spu_target_ops): Remove arch_string initializer.
13121 * win32-low.c (win32_arch_string): Remove.
13122 (win32_target_ops): Remove arch_string initializer.
13123 * win32-low.h (struct win32_target_ops): Remove arch_string member.
13124 * win32-arm-low.c (the_low_target): Remove arch_string initializer.
13125 * win32-i368-low.c (the_low_target): Remove arch_string initializer.
13126
ee1a7ae4
UW
131272008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
13128
13129 * linux-low.h (struct linux_target_ops): Replace left_pad_xfer field
13130 by collect_ptrace_register and supply_ptrace_register hooks.
13131 * linux-low.c (fetch_register): Use supply_ptrace_register callback
13132 instead of checking for the_low_target.left_pad_xfer.
13133 (usr_store_inferior_registers): Use collect_ptrace_register callback
13134 instead of checking for the_low_target.left_pad_xfer.
13135
13136 * linux-s390-low.c (s390_collect_ptrace_register): New function.
13137 (s390_supply_ptrace_register): Likewise.
13138 (s390_fill_gregset): Call s390_collect_ptrace_register.
13139 (the_low_target): Update.
13140
13141 * linux-ppc64-low.c (ppc_collect_ptrace_register): New function.
13142 (ppc_supply_ptrace_register): Likewise.
13143 (the_low_target): Update.
13144
13145 * linux-i386-low.c (the_low_target): Update.
13146 * linux-x86-64-low.c (the_low_target): Update.
13147
d61ddec4
UW
131482008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
13149
13150 * configure.srv [s390x-*-linux*]: Set srv_regobj to include both
13151 reg-s390.o and reg-s390x.o.
13152
13153 * linux-low.c (new_inferior): New global variable.
13154 (linux_create_inferior, linux_attach): Set it.
13155 (linux_wait_for_process): Call the_low_target.arch_setup after the
13156 target has stopped for the first time.
13157 (initialize_low): Do not call the_low_target.arch_setup.
13158
13159 * linux-s390-low.c (s390_get_pc): Support bi-arch operation.
13160 (s390_set_pc): Likewise.
13161 (s390_arch_setup): New function.
13162 (the_low_target): Use s390_arch_setup as arch_setup routine.
13163
13164 * regcache.c (realloc_register_cache): New function.
13165 (set_register_cache): Call it for each existing regcache.
13166
d05b4ac3
UW
131672008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
13168
13169 * server.h (init_registers): Remove prototype.
13170
13171 * linux-low.h (struct linux_target_ops): Add arch_setup field.
13172 * linux-low.c (initialize_low): Call the_low_target.arch_setup ()
13173 instead of init_registers ().
13174 * linux-arm-low.c (init_registers_arm): Add prototype.
13175 (init_registers_arm_with_iwmmxt): Likewise.
13176 (the_low_target): Add initializer for arch_setup field.
13177 * linux-cris-low.c (init_registers_cris): Add prototype.
13178 (the_low_target): Add initializer for arch_setup field.
13179 * linux-crisv32-low.c (init_registers_crisv32): Add prototype.
13180 (the_low_target): Add initializer for arch_setup field.
13181 * linux-i386-low.c (init_registers_i386_linux): Add prototype.
13182 (the_low_target): Add initializer for arch_setup field.
13183 * linux-ia64-low.c (init_registers_ia64): Add prototype.
13184 (the_low_target): Add initializer for arch_setup field.
13185 * linux-m32r-low.c (init_registers_m32r): Add prototype.
13186 (the_low_target): Add initializer for arch_setup field.
13187 * linux-m68k-low.c (init_registers_m68k): Add prototype.
13188 (the_low_target): Add initializer for arch_setup field.
13189 * linux-mips-low.c (init_registers_mips_linux): Add prototype.
13190 (init_registers_mips64_linux): Likewise.
13191 (the_low_target): Add initializer for arch_setup field.
13192 * linux-ppc-low.c (init_registers_ppc): Add prototype.
13193 (init_registers_powerpc_32, init_registers_powerpc_e500): Likewise.
13194 (the_low_target): Add initializer for arch_setup field.
13195 * linux-ppc64-low.c (init_registers_ppc64): Add prototype.
13196 (init_registers_powerpc_64): Likewise.
13197 (the_low_target): Add initializer for arch_setup field.
13198 * linux-s390-low.c (init_registers_s390): Add prototype.
13199 (init_registers_s390x): Likewise.
13200 (the_low_target): Add initializer for arch_setup field.
13201 * linux-sh-low.c (init_registers_sh): Add prototype.
13202 (the_low_target): Add initializer for arch_setup field.
13203 * linux-x86-64-low.c (init_registers_x86_64_linux): Add prototype.
13204 (the_low_target): Add initializer for arch_setup field.
13205 * linux-xtensa-low.c (init_registers_xtensa): Add prototype.
13206 (the_low_target): Add initializer for arch_setup field.
13207
13208 * win32-low.h (struct win32_target_ops): Add arch_setup field.
13209 * win32-low.c (initialize_low): Call the_low_target.arch_setup ()
13210 instead of init_registers ().
13211 * win32-arm-low.c (init_registers_arm): Add prototype.
13212 (the_low_target): Add initializer for arch_setup field.
13213 * win32-i386-low.c (init_registers_i386): Add prototype.
13214 (the_low_target): Add initializer for arch_setup field.
13215
13216 * spu-low.c (init_registers_spu): Add prototype.
13217 (initialize_low): Call initialie_registers_spu () instead of
13218 initialize_registers ().
13219
fd96d250
PA
132202008-02-19 Pedro Alves <pedro@codesourcery.com>
13221
13222 * server.c (handle_v_requests): When handling the vRun and vAttach
13223 packets, if already debugging a process, don't kill it. Return an
13224 error instead.
13225
d41b6bb4
DJ
132262008-02-17 Daniel Jacobowitz <dan@codesourcery.com>
13227
13228 * server.c (handle_query): Correct length check.
13229
5ac588cf
PA
132302008-02-14 Pedro Alves <pedro_alves@portugalmail.pt>
13231
13232 * win32-low.c (do_initial_child_stuff): Add process handle
13233 parameter. Set current_process_handle and current_process_id from the
13234 parameters. Clear globals.
13235 (win32_create_inferior): Don't set current_process_handle and
13236 current_process_id here. Instead pass them on the call to
13237 do_initial_child_stuff.
13238 (win32_attach): Likewise.
13239 (win32_clear_inferiors): New.
13240 (win32_kill): Don't close the current process handle or the
13241 current thread handle here. Instead call win32_clear_inferiors.
13242 (win32_detach): Don't open a new handle to the process. Call
13243 win32_clear_inferiors.
13244 (win32_join): Don't rely on current_process_handle; open a new
13245 handle using the process id.
13246 (win32_wait): Call win32_clear_inferiors when the inferior process
13247 has exited.
13248
ecd7ecbc
DJ
132492008-02-14 Daniel Jacobowitz <dan@codesourcery.com>
13250
13251 * server.c (monitor_show_help): Add "exit".
13252
1525d545
MG
132532008-02-11 Maxim Grigoriev <maxim2405@gmail.com>
13254
ecd7ecbc 13255 * Makefile.in (SFILES): Add linux-xtensa-low.c.
1525d545
MG
13256 (clean): Add reg-xtensa.c.
13257 (linux-xtensa-low.o, reg-xtensa.o, reg-xtensa.c): New dependencies.
ecd7ecbc
DJ
13258 * configure.srv (xtensa*-*-linux*) New target.
13259 * linux-xtensa-low.c: New.
13260 * xtensa-xtregs.c: New.
1525d545 13261
59a016f0
PA
132622008-02-01 Pedro Alves <pedro_alves@portugalmail.pt>
13263
13264 * hostio.c: Don't include errno.h.
13265 (errno_to_fileio_errno): Move to hostio-errno.
13266 * hostio.c: (hostio_error): Remove the error parameter. Defer the
13267 error number outputting to the target->hostio_last_error callback.
13268 (hostio_packet_error): Use FILEIO_EINVAL directly.
13269 (handle_open, handle_pread, hostio_error, handle_unlink): Update
13270 calls to hostio_error.
13271 * hostio-errno.c: New.
13272 * server.h (hostio_last_error_from_errno): Declare.
13273 * target.h (target_ops): Add hostio_last_error member.
13274 * linux-low.c (linux_target_op): Register hostio_last_error_from_errno
13275 as hostio_last_error handler.
889bf7c5 13276 * spu-low.c (spu_target_ops): Likewise.
59a016f0
PA
13277 * win32-low.c [_WIN32_WCE] (win32_error_to_fileio_error)
13278 (wince_hostio_last_error): New functions.
13279 (win32_target_ops) [_WIN32_WCE]: Register wince_hostio_last_error
13280 as hostio_last_error handler.
13281 (win32_target_ops) [!_WIN32_WCE]: Register
13282 hostio_last_error_from_errno as hostio_last_error handler.
13283 * Makefile.in (SFILES): Add hostio.c and hostio-errno.c.
13284 (hostio-errno.o): New rule.
13285 * configure.ac (GDBSERVER_DEPFILES): Add $srv_hostio_err_objs.
13286 * configure.srv (srv_hostio_err_objs): New variable. Default to
13287 hostio-errno.o.
13288 (arm*-*-mingw32ce*): Set srv_hostio_err_objs to "".
13289 * configure: Regenerate.
13290
2d717e4f
DJ
132912008-01-29 Daniel Jacobowitz <dan@codesourcery.com>
13292
13293 * linux-low.c (linux_attach_lwp): Do not _exit after errors.
13294 (linux_kill, linux_detach): Clean up the process list.
13295 * remote-utils.c (remote_open): Improve port number parsing.
13296 (putpkt_binary, input_interrupt): Only send interrupts if the target
13297 is running.
13298 * server.c (extended_protocol): Make static.
13299 (attached): Define earlier.
13300 (exit_requested, response_needed, program_argv): New variables.
13301 (target_running): New.
13302 (start_inferior): Clear attached here.
13303 (attach_inferior): Set attached here.
13304 (require_running): Define.
13305 (handle_query): Use require_running and target_running. Implement
13306 "monitor exit".
13307 (handle_v_attach, handle_v_run): New.
13308 (handle_v_requests): Use require_running. Handle vAttach and vRun.
13309 (gdbserver_usage): Update.
13310 (main): Redo argument parsing. Handle --debug and --multi. Handle
13311 --attach along with other options or after the port. Save
13312 program_argv. Support no initial program. Resynchronize
13313 communication with GDB after an error. Handle "monitor exit".
13314 Use require_running and target_running. Always allow the extended
13315 protocol. Do not error out for Hc0 or Hc-1. Do not automatically
13316 restart in extended mode.
13317 * README: Refer to the GDB manual. Update --attach usage.
13318
7407e2de
AS
133192007-12-20 Andreas Schwab <schwab@suse.de>
13320
13321 * linux-low.c (STACK_SIZE): Define.
13322 (linux_tracefork_child): Use it. Use __clone2 on ia64.
13323 (linux_test_for_tracefork): Likewise.
13324
b65d95c5
DJ
133252007-12-18 Daniel Jacobowitz <dan@codesourcery.com>
13326
13327 * linux-low.c (linux_wait_for_event): Update messages. Do not
13328 reinsert auto-delete breakpoints.
13329 * mem-break.c (struct breakpoint): Change return type of handler to
13330 int.
13331 (set_breakpoint_at): Update handler type.
13332 (reinsert_breakpoint_handler): Return 1 instead of calling
13333 delete_breakpoint.
13334 (reinsert_breakpoint_by_bp): Check for the original breakpoint before
13335 setting a new one.
13336 (check_breakpoints): Delete auto-delete breakpoints and return 2.
13337 * mem-break.h (set_breakpoint_at): Update handler type.
13338 * thread-db.c (thread_db_create_event, thread_db_create_event): Update.
13339 * win32-low.c (auto_delete_breakpoint): New.
13340 (get_child_debug_event): Use it.
13341
4e799345
DJ
133422007-12-16 Daniel Jacobowitz <dan@codesourcery.com>
13343
13344 * configure.ac: Check for pread and pwrite.
13345 * hostio.c (handle_pread): Fall back to lseek and read.
13346 (handle_pwrite): Fall back to lseek and write.
13347 * config.in, configure: Regenerated.
13348
27524b67
DJ
133492007-12-07 Daniel Jacobowitz <dan@codesourcery.com>
13350
13351 * server.c (myresume): Add own_buf argument.
13352 (main): Update calls.
13353
a20d5e98
DJ
133542007-12-06 Daniel Jacobowitz <dan@codesourcery.com>
13355
13356 * linux-low.c (linux_wait, linux_resume): Do not handle async I/O.
13357 * remote-utils.c (remote_open): Do not call disable_async_io.
13358 (block_async_io): Delete.
13359 (unblock_async_io): Make static.
13360 (initialize_async_io): New.
13361 * server.c (handle_v_cont): Handle async I/O here.
13362 (myresume): Likewise. Move other common resume tasks here...
13363 (main): ... from here. Call initialize_async_io. Disable async
13364 I/O before the main loop.
13365 * server.h (initialize_async_io): Declare.
13366 (block_async_io, unblock_async_io): Delete prototypes.
13367 * spu-low.c (spu_resume, spu_wait): Do not handle async I/O here.
13368
b79d787e
DJ
133692007-12-06 Mick Davis <mickd@goanna.iinet.net.au>
13370
13371 * remote-utils.c (readchar): Allow binary data in received messages.
13372
d97903b2
PA
133732007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
13374
13375 * win32-low.c (attaching): New global.
13376 (win32_create_inferior): Clear the `attaching' global.
13377 (win32_attach): Set the `attaching' global.
13378 (get_child_debug_event) [_WIN32_WCE]: Stop the inferior when
13379 attaching. Only set a breakpoint at the entry point if not
13380 attaching.
13381
311de423
PA
133822007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
13383
13384 * server.c (main): Don't report dll events on the initial
13385 connection on attaches.
13386
6c2d16d2
PA
133872007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
13388
13389 * server.c (main): Relax numerical bases supported for the pid of
13390 the --attach command line argument.
13391
5ca906e6
PA
133922007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
13393
13394 * win32-low.c (win32_attach): Call OpenProcess before
13395 DebugActiveProcess, not after. Add last error output to error
13396 call.
13397
9c6c8194
PA
133982007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
13399
13400 * win32-low.c (win32_get_thread_context)
13401 (win32_set_thread_context): New functions.
13402 (thread_rec): Use win32_get_thread_context.
13403 (continue_one_thread, win32_resume): Use win32_set_thread_context.
13404 * win32-low.h (win32_thread_info) [_WIN32_WCE]: Add `base_context'
13405 field.
13406
4d5d1aaa
PA
134072007-12-03 Leo Zayas
13408 Pedro Alves <pedro_alves@portugalmail.pt>
13409
13410 * win32-low.c (soft_interrupt_requested, faked_breakpoint): New
13411 global variables.
13412 (child_add_thread): Minor cleanup.
13413 (child_continue): Resume artificially suspended threads before
13414 calling ContinueDebugEvent.
13415 (suspend_one_thread): New.
13416 (fake_breakpoint_event): New.
13417 (get_child_debug_event): Change return type to int. Check here if
13418 gdb sent an interrupt request. If a soft interrupt was requested,
13419 fake a breakpoint event. Return 0 if there is no event to handle,
13420 and 1 otherwise.
13421 (win32_wait): Don't check here if gdb sent an interrupt request.
13422 Ensure there is a valid event to handle.
13423 (win32_request_interrupt): Add soft interruption method as last
13424 resort.
13425
c436e841
PA
134262007-12-03 Leo Zayas
13427 Pedro Alves <pedro_alves@portugalmail.pt>
13428
13429 * win32-low.h (win32_thread_info): Add descriptions to the
13430 structure members. Replace `suspend_count' counter by a
13431 `suspended' flag.
13432 * win32-low.c (thread_rec): Update condition of when to get the
13433 context from the inferior. Rely on ContextFlags being set if it
13434 has already been retrieved. Only suspend the inferior thread if
13435 we haven't already. Warn if that fails.
13436 (continue_one_thread): s/suspend_count/suspended/. Only call
13437 ResumeThread once. Warn if that fails.
13438
e7b5fa67
PA
134392007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
13440
13441 * win32-low.c (win32_wait): Don't read from the inferior when it
13442 has already exited.
13443
a385171d
PA
134442007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
13445
13446 * Makefile.in (win32_low_h): New variable.
13447 (win32-low.o): Add dependency on $(win32_low_h).
13448 (win32-arm-low.o, win32-i386-low.o): New rules.
13449
f80c84b3
DJ
134502007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
13451
13452 * hostio.c: Correct copyright year.
13453
a6b151f1
DJ
134542007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
13455
13456 * Makefile.in (OBS): Add hostio.o.
13457 (hostio.o): New rule.
13458 * server.h (handle_vFile): Declare.
13459 * hostio.c: New file.
13460 * server.c (handle_v_requests): Take packet_len and new_packet_len
13461 for binary packets. Call handle_vFile.
13462 (main): Update call to handle_v_requests.
13463
f9387fc3
DJ
134642007-11-05 Daniel Jacobowitz <dan@codesourcery.com>
13465
13466 * linux-low.c: Include <sched.h>.
13467
51c2684e
DJ
134682007-11-01 Daniel Jacobowitz <dan@codesourcery.com>
13469
13470 * linux-low.c (linux_tracefork_grandchild): New.
13471 (linux_tracefork_child): Use clone.
13472 (linux_test_for_tracefork): Use clone; allocate and free a stack.
13473
75f83163
JB
134742007-10-31 Joel Brobecker <brobecker@adacore.com>
13475
13476 * Makefile.in: Use $(SHELL) instead of "sh" to call regdat.sh.
13477
da5898ce
DJ
134782007-10-24 Daniel Jacobowitz <dan@codesourcery.com>
13479
13480 * linux-low.c (handle_extended_wait): Handle unexpected signals.
13481
24a09b5f
DJ
134822007-10-23 Daniel Jacobowitz <dan@codesourcery.com>
13483
13484 * inferiors.c (change_inferior_id): Delete.
13485 (add_pid_to_list, pull_pid_from_list): New.
13486 * linux-low.c (PTRACE_SETOPTIONS, PTRACE_GETEVENTMSG)
13487 (PTRACE_O_TRACESYSGOOD, PTRACE_O_TRACEFORK, PTRACE_O_TRACEVFORK)
13488 (PTRACE_O_TRACECLONE, PTRACE_O_TRACEEXEC, PTRACE_O_TRACEVFORKDONE)
13489 (PTRACE_O_TRACEEXIT, PTRACE_EVENT_FORK, PTRACE_EVENT_VFORK)
13490 (PTRACE_EVENT_CLONE, PTRACE_EVENT_EXEC, PTRACE_EVENT_VFORK_DONE)
13491 (PTRACE_EVENT_EXIT, __WALL): Provide default definitions.
13492 (stopped_pids, thread_db_active, must_set_ptrace_flags): New variables.
13493 (using_threads): Always set to 1.
13494 (handle_extended_wait): New.
13495 (add_process): Do not set TID.
13496 (linux_create_inferior): Set must_set_ptrace_flags.
13497 (linux_attach_lwp): Remove TID argument. Do not check using_threads.
13498 Use PTRACE_SETOPTIONS. Call new_thread_notify. Update all callers.
13499 (linux_thread_alive): Rename TID argument to LWPID.
13500 (linux_wait_for_process): Handle unknown processes. Do not use TID.
13501 (linux_wait_for_event): Do not use TID or check using_threads. Update
13502 call to dead_thread_notify. Call handle_extended_wait.
13503 (linux_create_inferior): Use PTRACE_SETOPTIONS.
13504 (send_sigstop): Delete sigstop_sent.
13505 (wait_for_sigstop): Avoid TID.
13506 (linux_supports_tracefork_flag, linux_tracefork_child, my_waitpid)
13507 (linux_test_for_tracefork): New.
13508 (linux_lookup_signals): Use thread_db_active and
13509 linux_supports_tracefork_flag.
13510 (initialize_low): Use thread_db_active and linux_test_for_tracefork.
13511 * linux-low.h (get_process_thread): Avoid TID.
13512 (struct process_ifo): Move thread_known and tid to the end. Remove
13513 sigstop_sent.
13514 (linux_attach_lwp, thread_db_init): Update prototypes.
13515 * server.h (change_inferior_id): Delete prototype.
13516 (add_pid_to_list, pull_pid_from_list): New prototypes.
13517 * thread-db.c (thread_db_use_events): New.
13518 (find_first_thread): Rename to...
13519 (find_one_thread): ...this. Update callers and messages. Do not
13520 call fatal. Check thread_db_use_events. Do not call
13521 change_inferior_id or new_thread_notify.
13522 (maybe_attach_thread): Update. Do not call new_thread_notify.
13523 (thread_db_init): Set thread_db_use_events. Check use_events.
13524 * utils.c (fatal, warning): Correct message prefix.
13525
30ed0a8f
DJ
135262007-10-15 Daniel Jacobowitz <dan@codesourcery.com>
13527
13528 * Makefile.in (clean): Remove new files.
13529 (powerpc-32.o, powerpc-32.c, powerpc-e500.o, powerpc-e500.c)
13530 (powerpc-64.o, powerpc-64.c): New rules.
13531 * configure.srv: Use alternate register sets for powerpc64-*-linux*
13532 with AltiVec, powerpc-*-linux* with AltiVec, and powerpc-*-linux*
13533 with SPE.
13534 * linux-ppc-low.c (ppc_regmap): Do not fetch the FP registers for
13535 SPE targets.
13536 (ppc_cannot_store_register): Do not check for FPSCR for SPE targets.
13537 (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS, ppc_fill_vrregset)
13538 (ppc_store_vrregset, PTRACE_GETEVRREGS, PTRACE_SETEVRREGS)
13539 (struct gdb_evrregset_t, ppc_fill_evrregset, ppc_store_evrregset): New.
13540 (target_regsets): Add AltiVec and SPE register sets.
13541 * configure.ac: Check for AltiVec and SPE.
13542 * linux-ppc64-low.c (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS)
13543 (ppc_fill_vrregset, ppc_store_vrregset): New.
13544 (target_regsets): Add AltiVec register set.
13545 * configure: Regenerated.
13546
fd462a61
DJ
135472007-09-19 Daniel Jacobowitz <dan@codesourcery.com>
13548
13549 * linux-low.c (O_LARGEFILE): Define.
13550 (linux_read_memory): Use /proc/PID/mem.
13551 * configure.ac: Use AC_GNU_SOURCE. Check for pread64.
13552 * configure, config.in: Regenerated.
13553
69f223ed
DJ
135542007-09-04 Daniel Jacobowitz <dan@codesourcery.com>
13555
13556 * linux-low.c (linux_wait_for_event): Do not pass signals while
13557 single-stepping.
13558
aec18585
PA
135592007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
13560
13561 * win32-low.c (create_process): New.
13562 (win32_create_inferior): Use create_process instead of
13563 CreateProcess. If create_process failed retry appending an ".exe"
13564 suffix. Store the GetLastError result immediatelly after
13565 create_process calls and use it on the call to error.
13566
34d86ddd
PA
135672007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
13568
13569 * win32-low.c (handle_load_dll): Don't use toolhelp when waiting.
13570
5a0e3bd0
JB
135712007-08-23 Joel Brobecker <brobecker@adacore.com>
13572
13573 * configure.ac: Switch license to GPLv3.
13574
f88c79e6
MS
135752007-08-01 Michael Snyder <msnyder@access-company.com>
13576
13577 * remote-utils.c (putpkt_binary): Memory leak, free buf2.
13578
6b3d9b83
PA
135792007-07-31 Pedro Alves <pedro_alves@portugalmail.pt>
13580
13581 * win32-low.c (winapi_CloseToolhelp32Snapshot) [_WIN32_WCE]: New
13582 typedef.
13583 (win32_CloseToolhelp32Snapshot) [_WIN32_WCE]: New global var.
13584 (load_toolhelp) [_WIN32_WCE]: Load TOOLHELP.DLL. Get
13585 CloseToolhelp32Snapshot.
13586 (toolhelp_get_dll_name) [_WIN32_WCE]: Close the snapshot with
13587 CloseToolhelp32Snapshot.
13588
c588c53c
MS
135892007-07-27 Michael Snyder <michael.snyder@access-company.com>
13590
13591 * server.c (main): Check for inferior exit before main loop.
13592
aa0403d9
PA
135932007-07-18 Pedro Alves <pedro_alves@portugalmail.pt>
13594
13595 * remote-utils.c (remote_open): Set SO_KEEPALIVE on remote_desc
13596 instead of on tmp_desc.
13597
255e7678
DJ
135982007-07-17 Pedro Alves <pedro_alves@portugalmail.pt>
13599 Daniel Jacobowitz <dan@codesourcery.com>
13600
13601 * inferiors.c (all_dlls, dlls_changed, get_dll): New.
13602 (add_thread): Minor cleanups.
13603 (clear_inferiors): Move lower in the file. Clear the DLL
13604 list.
13605 (free_one_dll, match_dll, loaded_dll, unloaded_dll, clear_list): New.
13606 * remote-utils.c (prepare_resume_reply): Check dlls_changed.
13607 (xml_escape_text): New.
13608 * server.c (handle_query): Handle qXfer:libraries:read. Report it
13609 for qSupported.
13610 (handle_v_cont): Report errors.
13611 (gdbserver_version): Update.
13612 (main): Correct size of own_buf. Do not report initial DLL events.
13613 * server.h (struct dll_info, all_dlls, dlls_changed, loaded_dll)
13614 (unloaded_dll, xml_escape_text): New.
13615 * win32-low.c (enum target_waitkind): Update comments.
13616 (win32_add_one_solib, get_image_name, winapi_EnumProcessModules)
13617 (winapi_GetModuleInformation, winapi_GetModuleFileNameExA)
13618 (win32_EnumProcessModules, win32_GetModuleInformation)
13619 (win32_GetModuleFileNameExA, load_psapi, psapi_get_dll_name)
13620 (winapi_CreateToolhelp32Snapshot, winapi_Module32First)
13621 (winapi_Module32Next, win32_CreateToolhelp32Snapshot)
13622 (win32_Module32First, win32_Module32Next, load_toolhelp)
13623 (toolhelp_get_dll_name, handle_load_dll, handle_unload_dll): New.
13624 (get_child_debug_event): Handle DLL events.
13625 (win32_wait): Likewise.
13626
0d37add9
DJ
136272007-07-12 Daniel Jacobowitz <dan@codesourcery.com>
13628
13629 * configure.srv: Set srv_linux_regsets for sh*-*-linux*.
13630 * linux-sh-low.c (sh_fill_gregset, target_regsets): New.
13631
45e2715e
PA
136322007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
13633
13634 * win32-low.c (handle_output_debug_string): Ignore event if not
13635 waiting.
13636
c5674cf1
PA
136372007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
13638
13639 * win32-arm-low.c (arm_wince_breakpoint): Fix typo.
13640
2bbe3cc1
DJ
136412007-07-03 Daniel Jacobowitz <dan@codesourcery.com>
13642
13643 * remote-utils.c (look_up_one_symbol): Handle 'm' packets.
13644
ae13219e
DJ
136452007-07-02 Daniel Jacobowitz <dan@codesourcery.com>
13646
13647 * inferiors.c (change_inferior_id): Add comment.
13648 * linux-low.c (check_removed_breakpoint): Add an early
13649 prototype. Improve debug output.
13650 (linux_attach): Doc update.
13651 (linux_detach_one_process, linux_detach): Clean up before releasing
13652 each process.
13653 (send_sigstop, wait_for_sigstop): Improve comments and debug output.
13654 * linux-low.h (struct process_info): Doc improvement.
13655 * mem-break.c (delete_all_breakpoints): New.
13656 * mem-break.h (delete_all_breakpoints): New prototype.
13657 * thread-db.c (find_first_thread): New.
13658 (thread_db_create_event): Call it instead of
13659 thread_db_find_new_threads. Clean up unused variables.
13660 (maybe_attach_thread): Remove first thread handling.
13661 (thread_db_find_new_threads): Use find_first_thread.
13662 (thread_db_get_tls_address): Likewise.
13663
4105de34
DJ
136642007-06-27 Daniel Jacobowitz <dan@codesourcery.com>
13665
13666 * thread-db.c (thread_db_find_new_threads): Add prototype.
13667 (thread_db_create_event): Check for the main thread before adding
13668 a new thread.
13669 (maybe_attach_thread): Only enable event reporting if TID == 0.
13670 (thread_db_get_tls_address): Check for new threads.
13671
2b876972
DJ
136722007-06-20 Daniel Jacobowitz <dan@codesourcery.com>
13673
13674 * linux-low.c (linux_create_inferior): Try execv before execvp.
13675 * spu-low.c (spu_create_inferior): Likewise.
13676
7a245884
DJ
136772007-06-13 Mike Frysinger <vapier@gentoo.org>
13678
13679 * linux-low.c (linux_create_inferior): Change execv to execvp.
13680 * spu-low.c (spu_create_inferior): Likewies.
13681
117ce543
DJ
136822007-06-13 Daniel Jacobowitz <dan@codesourcery.com>
13683
13684 * Makefile.in (clean): Clean new files instead of deleted ones.
13685 (reg-mips.o, reg-mips.c, reg-mips64.o, reg-mips64.c): Delete.
13686 (mips-linux.o, mips-linux.c, mips64-linux.o, mips64-linux.c): New
13687 rules.
13688 * configure.srv: Specify XML files and new regformats for MIPS and
13689 MIPS64 GNU/Linux.
13690 * linux-mips-low.c (mips_num_regs): Set to only used registers.
13691 (mips_regmap): Do not fetch $0. Remove unused registers. Add
13692 an entry for the restart register.
13693 (mips_cannot_fetch_register, mips_cannot_store_register)
13694 (mips_reinsert_addr, mips_fill_fpregset, mips_store_fpregset): Update
13695 register names to match the XML descriptions.
13696 (mips_fill_gregset, mips_store_gregset): Likewise. Handle the
13697 restart register instead of $0.
13698
0e7f50da
UW
136992007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
13700 Markus Deuling <deuling@de.ibm.com>
13701
13702 * remote-utils.c (decode_xfer_write): New function.
13703 * server.h (decode_xfer_write): Add prototype.
13704 * server.c (handle_query): Add PACKET_LEN argument. Support
13705 qXfer:spu:read and qXfer:spu:write packets.
13706 (main): Pass packet_len to handle_query.
13707 * spu-low.c (spu_target_ops): Add spu_proc_xfer_spu.
13708 * target.h (target_ops): Add qxfer_spu.
13709
374c1d38
UW
137102007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
13711
13712 * spu-low.c (spu_proc_xfer_spu): Do not return failure when
13713 accessing non-seekable spufs files.
13714
bb63802a
UW
137152007-05-16 Markus Deuling <deuling@de.ibm.com>
13716
889bf7c5 13717 * server.c (handle_query): Add reply for qC packet.
bb63802a 13718
7390519e
PA
137192007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
13720 Leo Zayas <lerele@champenstudios@com>
13721
13722 * server.h (check_remote_input_interrupt_request): New function.
13723 * remote_utils.c (INVALID_DESCRIPTOR): New define.
13724 (remote_desc): Initialize with INVALID_DESCRIPTOR.
13725 (input_interrupt): Expose on USE_WIN32API too. Fix whitespace.
13726 (check_remote_input_interrupt_request): New function.
13727 * server.h (check_remote_input_interrupt_request): Declare.
3ecf0694 13728 * win32-low.c (winapi_DebugBreakProcess,
7390519e
PA
13729 winapi_GenerateConsoleCtrlEvent): New typedefs.
13730 (get_child_debug_event): Lower Win32 debug event polling from 1 sec
13731 to 250 ms.
13732 (win32_wait): Check for remote interrupt request
13733 with check_remote_input_interrupt_request.
13734 (win32_request_interrupt): New function.
13735 (win32_target_op): Set request_interrupt to win32_request_interrupt.
13736
34b34921
PA
137372007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
13738
13739 * win32-low.c (debug_registers_changed,
13740 debug_registers_used, CONTEXT_EXTENDED_REGISTERS,
13741 CONTEXT_FLOATING_POINT, CONTEXT_DEBUG_REGISTERS,
13742 CONTEXT_DEBUGGER, CONTEXT_DEBUGGER_DR): Delete.
13743 (thread_rec): Get context using the low target.
13744 (child_add_thread): Call thread_added on the low target,
13745 which does the same thing.
13746 (regptr): Delete.
13747 (do_initial_child_stuff): Remove debug registers references.
13748 Set context using the low target. Resume threads after
13749 setting the contexts.
13750 (child_continue): Remove dead variable. Remove debug
13751 registers references.
13752 (child_fetch_inferior_registers): Go through the low target.
13753 (do_child_store_inferior_registers): Remove.
13754 (child_store_inferior_registers): Go through the low target.
13755 (win32_resume): Remove debug registers references.
13756 Set context using the low target.
13757 (handle_exception): Change return type to void. Don't record
13758 context here. Set status to TARGET_WAITKIND_SPURIOUS on a
13759 first chance exception.
889bf7c5 13760 (get_child_debug_event): Change return type to void. Remove
34b34921
PA
13761 goto loop. Always return after waiting for debug event.
13762 (win32_wait): Convert to switch statement. Handle spurious
13763 events.
13764
13765 * win32-i386-low.c (debug_registers_changed,
13766 debug_registers_used): New.
13767 (initial_stuff): Rename to ...
13768 (i386_initial_stuff): ... this. Clear debug registers
13769 state variables.
13770 (store_debug_registers): Delete.
13771 (i386_get_thread_context): New.
13772 (load_debug_registers): Delete.
13773 (i386_set_thread_context): New.
13774 (i386_thread_added): New.
13775 (single_step): Rename to ...
13776 (i386_single_step): ... this.
13777 (do_fetch_inferior_registers): Rename to ...
13778 (i386_fetch_inferior_register): ... this.
13779 (i386_store_inferior_register): New.
13780 (the_low_target): Adapt to new interface.
13781
13782 * win32-arm-low.c (CONTEXT_FLOATING_POINT): Define.
13783 (arm_get_thread_context): New.
13784 (arm_set_thread_context): New.
13785 (regptr): New.
13786 (do_fetch_inferior_registers): Rename to ...
13787 (arm_fetch_inferior_register): ... this.
13788 (arm_store_inferior_register): New.
13789 (arm_wince_breakpoint): Reimplement as unsigned long.
13790 (arm_wince_breakpoint_len): Define.
13791 (the_low_target): Adapt to new interface.
13792
13793 * win32-low.h (target_ops): Remove regmap, store_debug_registers and
13794 load_debug_registers. Add get_thread_context, set_thread_context,
13795 thread_added and store_inferior_register. Rename
13796 fetch_inferior_registers to fetch_inferior_register.
13797 (regptr): Remove declaration.
13798
dd6953e1
PA
137992007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
13800
13801 * linux-low.c (linux_detach): Change return type to int. Return 0.
13802 * spu-low.c (spu_detach): Likewise.
13803
444d6139
PA
138042007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
13805
13806 * target.h (target_ops): Change return type of detach to int.
13807 Add join.
13808 (join_inferior): New.
13809 * server.c (main): Don't skip detach support on mingw32.
13810 If the inferior doesn't support detaching return error.
13811 Call join_inferior instead of using waitpid.
13812 * linux-low.c (linux_join): New.
13813 (linux_target_op): Add linux_join.
13814 * spu-low.c (spu_join): New.
13815 (spu_target_ops): Add spu_join.
13816 * win32-low.c (win32_detach): Adapt to new interface.
13817 Reopen current_process_handle before detaching. Issue a child
13818 resume before detaching.
13819 (win32_join): New.
13820 (win32_target_op): Add win32_join.
13821
1d5315fe
PA
138222007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
13823
13824 * win32-low.c (win32-attach): Fix return value.
13825 * target.h (target_ops): Describe ATTACH return values.
13826
bf914831
PA
138272007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
13828
13829 * win32-low.c (GETPROCADDRESS): Define.
13830 (winapi_DebugActiveProcessStop): Add WINAPI. typedef as pointer.
13831 (winapi_DebugSetProcessKillOnExit): Likewise.
13832 (win32_create_inferior): Force usage of ansi CreateProcessA.
13833 (win32_attach): Use GETPROCADDRESS.
13834 (win32_detach): Likewise.
13835
f72f3e60
PA
138362007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
13837
13838 * win32-low.c (win32_wait): Don't use WSTOPSIG.
13839
ed50f18f
PA
138402007-03-30 Pedro Alves <pedro_alves@portugalmail.pt>
13841
13842 * win32-low.c: Commit leftover changes from 2007-03-29.
13843
0c2ead7e
DJ
138442007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
13845
13846 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Make 16-bit
13847 fields short instead of int. Add explicit padding.
13848 (i387_cache_to_fsave): Remove unnecessary casts.
13849 (i387_fsave_to_cache): Doc fix.
13850 (i387_cache_to_fxsave): Remove unnecessary casts and masking.
13851
73725ff3
DJ
138522007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
13853
13854 * i387-fp.c (i387_cache_to_fxsave): Reinitialize val2 before use.
13855 (i387_fxsave_to_cache): Check fp->ftag while building ftag value.
13856
d99f33d8
PA
138572007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
13858
13859 * configure.srv (arm*-*-mingw32ce*): Move near the other
13860 arm targets.
13861
68070c10
PA
138622007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
13863
2482afc6 13864 * configure.ac: Add errno checking.
68070c10
PA
13865 (AC_CHECK_HEADERS): Add errno.h, fcntl.h, signal.h,
13866 sys/file.h and malloc.h.
13867 (AC_CHECK_DECLS): Add perror.
13868 (srv_mingwce): Handle.
2482afc6 13869 * configure.srv (i[34567]86-*-cygwin*): Add
68070c10
PA
13870 win32-i386-low.o to srv_tgtobj.
13871 (i[34567]86-*-mingw*): Likewise.
13872 (arm*-*-mingw32ce*): Add case.
13873 * gdbreplay.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
13874 HAVE_FCNTL_H, HAVE_ERRNO_H, HAVE_MALLOC_H]: Check.
13875 [__MINGW32CE__] (strerror): New function.
13876 [__MINGW32CE__] (errno): Define to GetLastError.
13877 [__MINGW32CE__] (COUNTOF): New macro.
13878 (remote_open): Remove extra close call.
13879 * mem-break.c (delete_breakpoint_at): New function.
13880 * mem-break.h (delete_breakpoint_at): Declare.
13881 * remote-utils.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
13882 HAVE_FCNTL_H, HAVE_UNISTD_H, HAVE_ERRNO_H]: Check.
13883 [USE_WIN32API] (read, write): Add char* casts.
13884 * server.c [HAVE_UNISTD_H, HAVE_SIGNAL_H]: Check.
13885 * server.h: Include wincecompat.h on Windows CE.
13886 [HAVE_ERRNO_H]: Check.
13887 (perror): Declare if not declared.
13888 * utils.c: Add stdlib.h, errno.h and malloc.h includes.
13889 (perror_with_name): Remove errno declaration.
13890 * wincecompat.h: New.
13891 * wincecompat.c: New.
13892 * win32-low.h: New.
13893 * win32-arm-low.c: New.
13894 * win32-i386-low.c: New.
13895 (win32-low.c): Include mem-break.h and win32-low.h, and winnt.h.
13896 (OUTMSG2): Make it safe.
13897 (_T): New macro.
13898 (COUNTOF): New macro.
13899 (NUM_REGS): Get it from the low target.
13900 (CONTEXT_EXTENDED_REGISTERS, CONTEXT_FLOATING_POINT,
13901 CONTEXT_DEBUG_REGISTERS): Add fallbacks to 0.
13902 (thread_rec): Let low target handle debug registers.
13903 (child_add_thread): Likewise.
13904 (child_init_thread_list): Likewise.
13905 (continue_one_thread): Likewise.
13906 (regptr): New.
13907 (do_child_fetch_inferior_registers): Move to ...
13908 * win32-i386-low.c: ... here, and rename to ...
13909 (do_fetch_inferior_registers): ... this.
889bf7c5 13910 * win32-low.c (child_fetch_inferior_registers):
68070c10
PA
13911 Go through the low target.
13912 (do_child_store_inferior_registers): Use regptr.
13913 (strwinerror): New function.
13914 (win32_create_inferior): Handle Windows CE.
13915 Use strwinerror instead of strerror on Windows error
13916 codes. Add program to the error output.
13917 Don't close the main thread handle on Windows CE.
13918 (win32_attach): Use coredll.dll on Windows CE.
13919 (win32_kill): Close current process and current
13920 thread handles.
13921 (win32_detach): Use coredll.dll on Windows CE.
13922 (win32_resume): Let low target handle debug registers, and
13923 step request.
13924 (handle_exception): Add/Remove initial breakpoint. Avoid
13925 non-existant WSTOPSIG on Windows CE.
13926 (win32_read_inferior_memory): Cast to remove warning.
13927 (win32_arch_string): Go through the low target.
13928 (initialize_low): Call set_breakpoint_data with the low
13929 target's breakpoint.
13930 * win32-low.c (dr, FLAG_TRACE_BIT, FCS_REGNUM,
13931 FOP_REGNUM, mappings): Move to ...
13932 * win32-i386-low.c: ... here.
13933 * win32-low.c (win32_thread_info): Move to ...
13934 * win32-low.h: ... here.
13935 * Makefile.in (SFILES): Add win32-low.c, win32-i386-low.c,
13936 win32-arm-low.c and wincecompat.c.
13937 (all:): Add $EXEEXT.
13938 (install-only:): Likewise.
13939 (gdbserver:): Likewise.
13940 (gdbreplay:): Likewise.
13941 * config.in: Regenerate.
13942 * configure: Regenerate.
13943
41093d81
PA
139442007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
13945
13946 * win32-low.c: Rename typedef thread_info to
13947 win32_thread_info throughout.
13948
544afa54
PA
139492007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
13950
13951 * win32-i386-low.c: Rename to ...
13952 * win32-low.c: ... this.
13953 * configure.srv: Replace win32-i386-low.o with win32-low.o.
13954 * Makefile.in: Likewise.
13955
bce7165d
PA
139562007-03-27 Pedro Alves <pedro_alves@portugalmail.pt>
13957
13958 * remote-utils.c (monitor_output): Constify msg parameter.
13959 * server.h (monitor_output): Likewise.
13960 * win32-i386-low.c (handle_output_debug_string): New.
13961 (win32_kill): Handle OUTPUT_DEBUG_STRING_EVENT events using
13962 handle_output_debug_string.
13963 (get_child_debug_event): Likewise.
13964
506c7aa0
DJ
139652007-03-27 Mat Hostetter <mat@lcs.mit.edu>
13966
13967 * server.c (main): Correct strtoul check.
13968
42c81e2a
DJ
139692007-03-27 Jon Ringle <jon@ringle.org>
13970
13971 * linux-low.c: Check __ARCH_HAS_MMU__ also.
13972
9453113a
DJ
139732007-03-27 Brooks Moses <brooks.moses@codesourcery.com>
13974
13975 * Makefile.in: Add dummy "pdf" and "install-pdf" targets.
13976
64a69107
DJ
139772007-02-27 Daniel Jacobowitz <dan@codesourcery.com>
13978
13979 * terminal.h: Check HAVE_SGTTY_H.
13980
139812007-02-27 Mat Hostetter <mat@lcs.mit.edu>
6f8486da
DJ
13982
13983 * remote-utils.c (remote_open): Print out the assigned port number.
13984
c74d0ad8
DJ
139852007-02-26 Daniel Jacobowitz <dan@codesourcery.com>
13986
13987 * remote-utils.c (monitor_output): New function.
13988 * server.c (debug_threads): Define here.
13989 (monitor_show_help): New function.
13990 (handle_query): Handle qRcmd.
13991 (main): Do not handle 'd' packet.
13992 * server.h (debug_threads, remote_debug, monitor_output): Declare.
13993 * linux-low.c, spu-low.c, win32-i386-low.c: Remove definitions
13994 of debug_threads.
13995
de7c3b4a
PA
139962007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
13997
13998 * Makefile.in (EXEEXT): New.
13999 (clean): Use $(EXEEXT).
14000
ef57601b
PA
140012007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
14002
14003 * target.h (target_ops): Rename send_signal to request_interrupt,
14004 and remove enum target_signal parameter.
14005 * linux-low.c (linux_request_interrupt): Rename from
14006 linux_send_signal, and always send SIGINT.
14007 * spu-low.c (spu_request_interrupt): Rename from spu_send_signal,
14008 and always send SIGINT.
14009 * remote-utils.c (putpkt_binary): Call request_interrupt, instead
14010 of send_signal.
14011 (input_interrupt): Likewise.
14012
820f2bda
PA
140132007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
14014
14015 * server.c (get_features_xml): Check if target implemented
14016 arch_string.
14017 * win32-i386-low.c (win32_arch_string): New.
14018 (win32_target_ops): Add win32_arch_string as arch_string member.
14019
ab39bf24
UW
140202007-02-22 Markus Deuling <deuling@de.ibm.com>
14021
14022 * spu-low.c (spu_arch_string): New.
14023 (spu_target_ops): Add spu_arch_string.
14024
61ff6e04
DJ
140252007-02-16 Daniel Jacobowitz <dan@codesourcery.com>
14026
14027 * remote-utils.c: Remove HAVE_TERMINAL_H check.
14028 * configure.ac: Do not check for terminal.h.
14029 * configure, config.in: Regenerated.
14030
fb1e4ffc
DJ
140312007-02-08 Daniel Jacobowitz <dan@codesourcery.com>
14032
14033 * Makefile.in (OBS): Add $(XML_BUILTIN).
14034 (XML_DIR, XML_TARGET, XML_FILES, XML_BUILTIN): New.
14035 (clean): Update.
14036 (target.xml, xml-builtin.c, stamp-xml, arm-with-iwmmxt.o)
14037 (arm-with-iwmmxt.c): New.
14038 * config.in, configure: Regenerate.
14039 * configure.ac: Check for iWMMXt. Handle srv_xmltarget,
14040 srv_xmlbuiltin, and srv_xmlfiles. Define USE_XML.
14041 * configure.srv: Mention srv_xmltarget and srv_xmlfiles.
14042 (arm*-*-linux*): Add iWMMXt and regset support.
14043 * linux-arm-low.c (PTRACE_GETWMMXREGS, PTRACE_SETWMMXREGS): Define.
14044 (arm_fill_gregset, arm_store_gregset, arm_fill_wmmxregset)
14045 (arm_store_wmmxregset, target_regsets): New.
14046 * server.c (get_features_xml): Take annex argument. Check builtin
14047 XML documents.
14048 (handle_query): Handle multiple annexes.
14049
0f48aa01
DJ
140502007-01-29 Daniel Jacobowitz <dan@codesourcery.com>
14051
14052 * remote-utils.c [USE_WIN32API] (read, write): Define.
14053 (putpkt_binary, input_interrupt, readchar, getpkt): Use read and
14054 write.
14055
23181151
DJ
140562007-01-09 Daniel Jacobowitz <dan@codesourcery.com>
14057
14058 * linux-i386-low.c (the_low_target): Set arch_string.
14059 * linux-x86-64-low.c (the_low_target): Likewise.
14060 * linux-low.c (linux_arch_string): New.
14061 (linux_target_ops): Add it.
14062 * linux-low.h (struct linux_target_ops): Add arch_string.
14063 * server.c (write_qxfer_response): Use const void * for DATA.
14064 (get_features_xml): New.
14065 (handle_query): Handle qXfer:features:read. Report it for qSupported.
14066 * target.h (struct target_ops): Add arch_string method.
14067
9d606399
DJ
140682007-01-03 Denis Pilat <denis.pilat@st.com>
14069 Daniel Jacobowitz <dan@codesourcery.com>
14070
14071 * linux-low.c (linux_kill): Handle being called with no threads.
14072 * win32-i386-low.c (win32_kill): Likewise.
14073 (get_child_debug_event): Clear current_process_handle.
14074
140752006-12-30 Denis PILAT <denis.pilat@st.com>
8264bb58
DJ
14076 Daniel Jacobowitz <dan@codesourcery.com>
14077
14078 * remote-utils.c (remote_open): Check the type of specified
14079 serial port devices before opening them.
14080 * server.c (main): Kill the inferior if an error occurs during
14081 the first remote_open.
14082
a5e13d24
DJ
140832006-12-05 Markus Deuling <deuling@de.ibm.com>
14084
14085 * README: Update supported targets.
14086
186947f7
DJ
140872006-11-28 Daniel Jacobowitz <dan@codesourcery.com>
14088
14089 * Makefile.in (clean): Remove reg-mips64.c.
14090 (reg-mips64.c, reg-mips64.o): New rules.
14091 * configure.srv: Handle mips64. Include regset support for mips.
14092 * linux-mips-low.c (union mips_register): New.
14093 (mips_get_pc, mips_set_pc, mips_reinsert_addr): Use it.
14094 (mips_breakpoint, mips_breakpoint_at): Use int.
14095 (mips_collect_register, mips_supply_register)
14096 (mips_collect_register_32bit, mips_supply_register_32bit)
14097 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
14098 (mips_store_fpregset, target_regsets): New.
14099 * thread-db.c (thread_db_get_tls_address): Use uintptr_t.
14100
a13e2c95
UW
141012006-11-22 Ulrich Weigand <uweigand@de.ibm.com>
14102
14103 * configure.srv: Add target "spu*-*-*".
14104 * Makefile.in (clean): Remove reg-spu.c.
14105 (reg-spu.c, reg-spu.o, spu-low.o): Add dependencies.
14106 * spu-low.c: New file.
14107
cb7283db
DJ
141082006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
14109
14110 * configure.ac: Correct td_thr_tls_get_addr test.
14111 * configure: Regenerated.
14112
89be2091
DJ
141132006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
14114
14115 * linux-low.c (linux_wait_for_event): Reformat. Use the
14116 pass_signals array.
14117 * remote-utils.c (decode_address_to_semicolon): New.
14118 * server.c (pass_signals, handle_general_set): New.
14119 (handle_query): Mention QPassSignals for qSupported.
14120 (main): Call handle_general_set.
14121 * server.h (pass_signals, decode_address_to_semicolon): New.
14122
000ef4f0
DJ
141232006-11-06 Daniel Jacobowitz <dan@codesourcery.com>
14124
14125 * server.c (handle_query): Correct error handling for read_auxv.
14126
b7149293
UW
141272005-10-19 Ulrich Weigand <uweigand@de.ibm.com>
14128
14129 * configure.srv [s390-*-linux*, s390x-*-linux*]: Set srv_linux_regsets
14130 and srv_linux_thread_db to yes.
14131 * linux-s390-low.c (s390_fill_gregset): New function.
14132 (target_regsets): Define data structure.
14133
dae5f5cf
DJ
141342006-10-17 Daniel Jacobowitz <dan@codesourcery.com>
14135
14136 * acinclude.m4 (SRV_CHECK_TLS_GET_ADDR): New.
14137 * configure.ac: Use it. Define HAVE_TD_THR_TLS_GET_ADDR.
14138 * config.in, configure: Regenerated.
14139 * inferiors.c (gdb_id_to_thread): New function.
14140 (gdb_id_to_thread_id): Use it.
14141 * linux-low.c (linux_target_ops): Use thread_db_get_tls_address.
14142 * linux-low.h (struct process_info): Add th member.
14143 (thread_db_get_tls_address): New prototype.
14144 * remote-utils.c (decode_address): Make non-static.
14145 * server.c (handle_query): Handle qGetTLSAddr.
14146 * server.h (gdb_id_to_thread, decode_address): New prototypes.
14147 * target.h (struct target_ops): Add get_tls_address.
14148 * thread-db.c (maybe_attach_thread): Save the thread handle.
14149 (thread_db_get_tls_address): New.
14150
32ca6d61
DJ
141512006-09-28 Daniel Jacobowitz <dan@codesourcery.com>
14152
14153 * linux-low.c (PTRACE_GETSIGINFO, PTRACE_SETSIGINFO): Define.
14154 (linux_resume_one_process): Take a siginfo_t *. Update all
14155 callers. Queue it if necessary. Use PTRACE_SETSIGINFO.
14156 (struct pending_signals): Add a siginfo_t.
14157 (linux_wait_for_process): Always set last_status.
14158 (linux_wait_for_event): Use PTRACE_GETSIGINFO.
14159 (linux_queue_one_thread): Use PTRACE_GETSIGINFO.
14160 * linux-low.h (struct process_info): Add last_status.
14161
5ffff7c1
DJ
141622006-09-21 Daniel Jacobowitz <dan@codesourcery.com>
14163
14164 * remote-utils.c (try_rle): New function.
14165 (putpkt_binary): Use it.
14166
8695c747
DJ
141672006-08-19 Daniel Jacobowitz <dan@codesourcery.com>
14168
14169 * Makefile.in (clean): Clean reg-x86-64-linux.c.
14170 (reg-x86-64-linux.o, reg-x86-64-linux.c): New.
14171 * configure.srv (x86_64-*-linux*): Use reg-x86-64-linux.o.
14172 * linux-x86-64-low.c (x86_64_regmap): Include ORIG_RAX.
14173 (x86_64_fill_gregset, x86_64_store_gregset): Skip floating
14174 point registers.
14175
290fadea
RS
141762006-08-08 Richard Sandiford <richard@codesourcery.com>
14177
14178 * server.c (terminal_fd): New variable.
14179 (old_foreground_pgrp): Likewise.
14180 (restore_old_foreground_pgrp): New function.
14181 (start_inferior): Record the terminal file descriptor in terminal_fd
14182 and its original foreground group in old_foreground_pgrp. Register
14183 restore_old_foreground_pgrp with atexit().
14184
9f2e1e63
DJ
141852006-07-26 Daniel Jacobowitz <dan@codesourcery.com>
14186
14187 * server.c (handle_query): Correct qPart to qXfer.
14188
b80864fb
DJ
141892006-07-22 Daniel Jacobowitz <dan@codesourcery.com>
14190
14191 * configure.ac: Check for more headers which are missing on
14192 Windows. Automatically supply -lwsock32 and USE_WIN32API.
14193 * configure.srv: Add Cygwin and mingw32.
14194 * remote-utils.c: Don't include headers unconditionally which
14195 are missing on mingw32. Include <winsock.h> for mingw32.
14196 (remote_open): Adjust for mingw32 support. Flush
14197 standard error after writing to it.
14198 (remote_close, putpkt_binary, input_interrupt, block_async_io)
14199 (unblock_async_io, enable_async_io, disable_async_io)
14200 (readchar, getpkt): Update for Winsock support.
14201 (prepare_resume_reply): Expect a protocol signal number.
14202 * server.c: Disable <sys/wait.h> on mingw32.
14203 (start_inferior): Adjust for mingw32 support. Flush
14204 standard error after writing to it.
14205 (attach_inferior): Likewise. Use protocol signal
14206 numbers.
14207 (main): Skip 'D' packet on mingw32. Use protocol signal numbers
14208 and names.
14209 * win32-i386-low.c: New file.
14210 * Makefile.in (XM_CLIBS): Set.
14211 (gdbserver, gdbreplay): Use $(INTERNAL_CFLAGS).
14212 (win32-i386-low.o): New dependency rule.
14213 * linux-low.c (linux_wait): Use target signal numbers.
14214 * target.h (struct target_ops): Doc fix.
14215 * server.h (target_signal_to_name): New prototype.
14216 * gdbreplay.c: Don't include headers unconditionally which
14217 are missing on mingw32. Include <winsock.h> for mingw32.
14218 (remote_close, remote_open): Adjust for Winsock support.
14219 * configure, config.in: Regenerated.
14220
0876f84a
DJ
142212006-07-12 Daniel Jacobowitz <dan@codesourcery.com>
14222
14223 * server.c (decode_xfer_read, write_qxfer_response): New.
14224 (handle_query): Take a packet length argument. Handle
14225 qXfer:auxv:read instead of qPart:auxv:read. Mention it in
14226 the qSupported response.
14227 (main): Update call to handle_query.
14228
01f9e8fa
DJ
142292006-06-22 Daniel Jacobowitz <dan@codesourcery.com>
14230
14231 * remote-utils.c (remote_escape_output, remote_unescape_input): New.
14232 (putpkt_binary): Renamed from putpkt and adjusted for binary
14233 data.
14234 (putpkt): New wrapper for putpkt_binary.
14235 (readchar): Don't mask off the high bit.
14236 (decode_X_packet): New function.
14237 * server.c (main): Call putpkt_binary if a handler sets the packet
14238 length. Save the length of the incoming packet. Handle 'X'.
14239 * server.h (gdb_byte, remote_escape_output, decode_X_packet): New.
14240
be2a5f71
DJ
142412006-06-21 Daniel Jacobowitz <dan@codesourcery.com>
14242
14243 * server.c (handle_query): Handle qSupported.
14244
ea025f5f
DJ
142452006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
14246
14247 * remote-utils.c (all_symbols_looked_up): New variable.
14248 (look_up_one_symbol): Check it.
14249 * server.h (look_up_one_symbol): New declaration.
14250 * thread-db.c (thread_db_init): Set all_symbols_looked_up.
14251
9308fc88
DJ
142522006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
14253
14254 * Makefile.in (linux-arm-low.o): Update dependencies.
66f338c7 14255 * linux-arm-low.c: Include "gdb_proc_service.h".
9308fc88
DJ
14256 (PTRACE_GET_THREAD_AREA): Define.
14257 (ps_get_thread_area): New function.
14258
52fb6437
NS
142592006-05-09 Nathan Sidwell <nathan@codesourcery.com>
14260
14261 * configure.srv (m68k*-*-uclinux*): New target.
14262 * linux-low.c (linux_create_inferior): Use vfork on mmuless systems.
14263 (linux_resume_one_process): Remove extraneous cast.
14264 (linux_read_offsets): New.
14265 (linux_target_op): Add linux_read_offsets on mmuless systems.
14266 * server.c (handle_query): Add qOffsets logic.
14267 * target.h (struct target_ops): Add read_offsets.
14268
21b0f40c
DJ
142692006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
14270
14271 * linux-mips-low.c: Include <sys/ptrace.h> and "gdb_proc_service.h".
14272 (PTRACE_GET_THREAD_AREA): Define.
14273 (ps_get_thread_area): New function.
14274 * Makefile.in (linux-i386-low.o, linux-mips-low.o)
14275 (linux-x86-64-low.o): Update.
14276
0050a760
DJ
142772006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
14278
14279 * configure.ac: Remove checks for prfpregset_t.
14280 * gdb_proc_service.h: New file.
14281 * linux-i386-low.c, linux-x86-64-low.c, thread-db.c: Use the
14282 new "gdb_proc_service.h".
14283 * proc-service.c: Likewise.
14284 (ps_pglobal_lookup, ps_pdread, ps_pdwrite): Use psaddr_t.
14285 (ps_lgetfpregs, ps_lsetfpregs): Use a void* argument.
14286 * Makefile.in (gdb_proc_service_h): Updated.
14287 * configure, config.in: Regenerated.
14288
b92a518e
DJ
142892006-03-03 Daniel Jacobowitz <dan@codesourcery.com>
14290
14291 * remote-utils.c (prepare_resume_reply): Move declaration
14292 of gdb_id_from_wait to the top of the block.
14293
545587ee
DJ
142942006-02-15 Daniel Jacobowitz <dan@codesourcery.com>
14295
14296 * linux-low.c (regsets_store_inferior_registers): Read the regset
14297 from the target before filling it.
14298
9db87ebd
DJ
142992006-02-08 Daniel Jacobowitz <dan@codesourcery.com>
14300
14301 * server.c (attach_inferior): Return SIGTRAP for a successful
14302 attach.
14303
dd24457d
DJ
143042006-02-01 Daniel Jacobowitz <dan@codesourcery.com>
14305
14306 * Makefile.in (OBS): Add version.o.
14307 (STAGESTUFF): Delete.
14308 (version.o): Add dependencies.
14309 (version.c): Replace rule.
14310 (clean): Remove version.c.
14311 * server.c (gdbserver_version): New.
14312 (gdbserver_usage): Use printf.
14313 (main): Handle --version and --help.
14314 * server.h (version, host_name): Add declarations.
14315
6f0f660e
EZ
143162005-12-23 Eli Zaretskii <eliz@gnu.org>
14317
889bf7c5
PA
14318 * linux-arm-low.c:
14319 * linux-arm-low.c:
14320 * inferiors.c:
14321 * i387-fp.h:
14322 * i387-fp.c:
14323 * gdbreplay.c:
14324 * regcache.c:
14325 * proc-service.c:
14326 * mem-break.h:
14327 * mem-break.c:
14328 * linux-x86-64-low.c:
14329 * linux-sh-low.c:
14330 * linux-s390-low.c:
14331 * linux-ppc64-low.c:
14332 * linux-ppc-low.c:
14333 * linux-mips-low.c:
14334 * linux-m68k-low.c:
14335 * linux-m32r-low.c:
14336 * linux-low.h:
14337 * linux-low.c:
14338 * linux-ia64-low.c:
14339 * linux-i386-low.c:
14340 * linux-crisv32-low.c:
14341 * thread-db.c:
14342 * terminal.h:
14343 * target.h:
14344 * target.c:
14345 * server.h:
14346 * server.c:
14347 * remote-utils.c:
14348 * regcache.h:
14349 * utils.c:
14350 * Makefile.in:
14351 * configure.ac:
6f0f660e
EZ
14352 * gdbserver.1: Add (C) after Copyright. Update the FSF
14353 address.
14354
9d1fb177
DJ
143552005-11-13 Daniel Jacobowitz <dan@codesourcery.com>
14356
14357 * linux-arm-low.c (arm_eabi_breakpoint): New variable.
14358 (arm_breakpoint_at): Recognize both breakpoints.
14359 (the_low_target): Use the correct breakpoint instruction.
14360
011a70c2
DJ
143612005-11-02 Daniel Jacobowitz <dan@codesourcery.com>
14362
14363 * configure.srv (x86_64-*-linux*): Turn on thread_db support.
14364 * linux-x86-64-low.c (x86_64_breakpoint, x86_64_breakpoint_len)
14365 (x86_64_get_pc, x86_64_set_pc, x86_64_breakpoint_at): New.
14366 (the_low_target): Update.
14367
7fb85e41
AS
143682005-10-25 Andreas Schwab <schwab@suse.de>
14369
14370 * server.c (main): Allocate mem_buf with PBUFSIZ bytes.
14371
14372 * linux-ia64-low.c (ia64_regmap): Remove NAT registers.
14373 (ia64_num_regs): Reduce to 462.
14374
3db0444b
DJ
143752005-09-17 Daniel Jacobowitz <dan@codesourcery.com>
14376
14377 * acinclude.m4: Correct quoting.
14378 * aclocal.m4: Regenerated.
14379
14380 Suggested by SZOKOVACS Robert <szo@ies.hu>:
14381 * thread-db.c (thread_db_err_str): Handle TD_VERSION.
14382 (thread_db_init): Call thread_db_err_str.
14383 * configure.ac: Check for TD_VERSION.
14384 * config.in, configure: Regenerated.
14385
bee0189a
DJ
143862005-07-31 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
14387
14388 * server.h (error, fatal, warning): Add ATTR_FORMAT.
14389
e9d25b98
DJ
143902005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
14391
14392 * configure.ac: Define HAVE_LINUX_REGSETS even if PTRACE_GETREGS
14393 is not available. Define HAVE_PTRACE_GETREGS if it is.
14394 * config.in, configure: Regenerated.
14395 * configure.srv: Set srv_linux_regsets for PowerPC and PowerPC64.
14396 * linux-i386-low.c, linux-m68k-low.c: Update to use
14397 HAVE_PTRACE_GETREGS.
14398 * linux-low.c (regsets_fetch_inferior_registers)
14399 (regsets_store_inferior_registers): Only return 0 if we processed
14400 GENERAL_REGS.
14401 * linux-ppc-low.c (ppc_fill_gregset, target_regsets): New.
14402 * linux-ppc64-low.c (ppc_fill_gregset, target_regsets): New.
14403
a06660f7
DJ
144042005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
14405
14406 * inferiors.c (struct thread_info): Add gdb_id.
14407 (add_thread): Add gdb_id argument.
14408 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New.
14409 * linux-low.c (linux_create_inferior, linux_attach_lwp): Update
14410 calls to add_thread.
14411 * remote-utils.c (prepare_resume_reply: Use thread_to_gdb_id.
14412 * server.c (handle_query): Use thread_to_gdb_id.
14413 (handle_v_cont, main): Use gdb_id_to_thread_id.
14414 * server.h (add_thread): Update prototype.
14415 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New
14416 prototypes.
14417
5a1f5858
DJ
144182005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
14419
14420 * linux-low.c (fetch_register, usr_store_inferior_registers): Handle
14421 left-padded registers.
14422 * linux-low.h (struct linux_target_ops): Add left_pad_xfer.
14423 * linux-ppc64-low.c (the_low_target): Set left_pad_xfer.
14424
e122f1f5
SE
144252005-07-01 Steve Ellcey <sje@cup.hp.com>
14426
14427 * configure.ac (BFD_NEED_DECLARATION): Replace with AC_CHECK_DECLS.
14428 * configure: Regenerate.
14429 * config.in: Regenerate.
14430 * server.h (NEED_DECLARATION_STRERROR):
14431 Replace with !HAVE_DECL_STRERROR.
14432
d592fa2f
DJ
144332005-06-16 Daniel Jacobowitz <dan@codesourcery.com>
14434
14435 * linux-low.c (linux_wait, linux_send_signal): Don't test
14436 an unsigned long variable for > 0 if it could be MAX_ULONG.
14437 * server.c (myresume): Likewise.
14438 * target.c (set_desired_inferior): Likewise.
14439
ccbd4912
MK
144402005-06-13 Mark Kettenis <kettenis@gnu.org>
14441
14442 * configure.ac: Simplify and improve check for socklen_t.
14443 * configure, config.in: Regenerate.
14444
f450004a
DJ
144452005-06-12 Daniel Jacobowitz <dan@codesourcery.com>
14446
14447 * acconfig.h: Remove.
14448 * configure.ac: Add a test for socklen_t. Use three-argument
14449 AC_DEFINE throughout.
14450 * config.in: Regenerated using autoheader 2.59.
14451 * configure: Regenerated.
14452
14453 * gdbreplay.c (socklen_t): Provide a default.
14454 (remote_open): Use socklen_t.
14455 * remote-utils.c (socklen_t): Provide a default.
14456 (remote_open): Use socklen_t.
14457 (convert_int_to_ascii, convert_ascii_to_int, decode_M_packet): Use
14458 unsigned char.
14459
14460 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Use unsigned
14461 char for buffers.
14462 * linux-low.c (linux_read_memory, linux_write_memory)
14463 (linux_read_auxv): Likewise.
14464 * mem-break.c (breakpoint_data, set_breakpoint_data, check_mem_read)
14465 (check_mem_write): Likewise.
14466 * mem-break.h (set_breakpoint_data, check_mem_read, check_mem_write):
14467 Likewise.
14468 * regcache.c (struct inferior_rgcache_data, registers_to_string)
14469 (registers_from_string, register_data): Likewise.
14470 * server.c (handle_query, main): Likewise.
14471 * server.h (convert_ascii_to_int, convert_int_to_ascii)
14472 (decode_M_packet): Likewise.
14473 * target.c (read_inferior_memory, write_inferior_memory): Likewise.
14474 * target.h (struct target_ops): Update read_memory, write_memory,
14475 and read_auxv.
14476 (read_inferior_memory, write_inferior_memory): Update.
14477 * linux-low.h (struct linux_target_ops): Change type of breakpoint
14478 to unsigned char *.
14479 * linux-arm-low.c, linux-cris-low.c, linux-crisv32-low.c,
14480 linux-i386-low.c, linux-m32r-low.c, linux-m68k-low.c,
14481 linux-mips-low.c, linux-ppc-low.c, linux-ppc64-low.c,
14482 linux-s390-low.c, linux-sh-low.c: Update for changes in
14483 read_inferior_memory and the_low_target->breakpoint.
14484
eee84df1
DJ
144852005-05-28 Daniel Jacobowitz <dan@codesourcery.com>
14486
14487 * Makefile.in (SFILES): Add linux-ppc64-low.c.
14488 (linux-ppc64-low.o, reg-ppc64.c, reg-ppc64.o): New targets.
14489 * configure.srv: Add powerpc64-*-linux*.
14490 * linux-ppc64-low.c: New file.
14491
45b134e5
OF
144922005-05-23 Orjan Friberg <orjanf@axis.com>
14493
14494 * linux-cris-low.c: New file with support for CRIS.
14495 * linux-crisv32-low.c: Ditto for CRISv32.
14496 * Makefile.in (SFILES): Add linux-cris-low.c, linux-crisv32-low.c.
14497 (clean): Add reg-cris.c and reg-crisv32.c.
889bf7c5 14498 Add linux-cris-low.o, linux-crisv32-low.o, reg-cris.o, reg-cris.c,
45b134e5
OF
14499 reg-crisv32.o, and reg-crisv32.c to make rules.
14500 * configure.srv: Add cris-*-linux* and crisv32-*-linux* to list of
14501 recognized targets.
14502
48d93c75
UW
145032005-05-16 Ulrich Weigand <uweigand@de.ibm.com>
14504
14505 * linux-low.c (fetch_register): Ensure buffer size is a multiple
14506 of sizeof (PTRACE_XFER_TYPE).
14507 (usr_store_inferior_registers): Likewise. Zero out excess bytes.
14508
e013ee27
OF
145092005-05-12 Orjan Friberg <orjanf@axis.com>
14510
889bf7c5 14511 * target.h (struct target_ops): Add insert_watchpoint,
e013ee27
OF
14512 remove_watchpoint, stopped_by_watchpoint, stopped_data_address function
14513 pointers for hardware watchpoint support.
14514 * linux-low.h (struct linux_target_ops): Ditto.
14515 * linux-low.c (linux_insert_watchpoint, linux_remove_watchpoint)
14516 (linux_stopped_by_watchpoint, linux_stopped_data_address): New. Add
14517 to linux_target_ops.
14518 * remote-utils.c (prepare_resume_reply): Add watchpoint information to
14519 reply packet.
14520 * server.c (main): Recognize 'Z' and 'z' packets.
14521
b0ded00b
UW
145222005-05-10 Ulrich Weigand <uweigand@de.ibm.com>
14523
14524 * linux-s390-low.c (s390_breakpoint, s390_breakpoint_len): Define.
14525 (s390_get_pc, s390_set_pc, s390_breakpoint_at): New functions.
14526 (the_low_target): Add new members.
14527
8643e2ad
DJ
145282005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
14529
14530 * proc-service.c (ps_lgetregs): Search all_processes instead of
14531 all_threads.
14532
fc620387
DJ
145332005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
14534
14535 * server.c (start_inferior): Change return type to int.
14536 (attach_inferior): Change sigptr to int *.
14537 (handle_v_cont, handle_v_requests): Change signal to int *.
14538 (main): Change signal to int.
14539
145402005-04-15 Kei Sakamoto <sakamoto.kei@renesas.com>
7cfbc4a0
KI
14541
14542 * Makefile.in: Add linux-m32r-low.o, reg-m32r.c and reg-m32r.o.
14543 * configure.srv: Add m32r*-*-linux*.
14544 * linux-m32r-low.c: New file.
14545
e0e76420
DJ
145462005-03-04 Daniel Jacobowitz <dan@codesourcery.com>
14547
14548 * Makefile.in (stamp-h): Set CONFIG_HEADERS explicitly.
14549
a1928bad
DJ
145502005-03-03 Daniel Jacobowitz <dan@codesourcery.com>
14551
14552 * inferiors.c (change_inferior_id, add_thread, find_inferior_id):
14553 Take unsigned long arguments for PIDs.
14554 * linux-low.c (add_process, linux_attach_lwp, linux_attach)
14555 (linux_thread_alive, linux_wait_for_event, kill_lwp, send_sigstop)
14556 (wait_for_sigstop, linux_resume_one_process)
14557 (regsets_fetch_inferior_registers, linux_send_signal)
14558 (linux_read_auxv): Likewise. Update the types of variables holding
14559 PIDs. Update format string specifiers.
14560 * linux-low.h (struct process_info, linux_attach_lwp): Likewise.
14561 * remote-utils.c (prepare_resume_reply): Likewise.
14562 * server.c (cont_thread, general_thread, step_thread)
14563 (thread_from_wait, old_thread_from_wait, signal_pid): Change type to
14564 unsigned long.
14565 (handle_query): Update format specifiers.
14566 (handle_v_cont, main): Use strtoul for thread IDs.
14567 * server.h (struct inferior_list_entry): Use unsigned long for ID.
14568 (add_thread, find_inferior_id, change_inferior_id, cont_thread)
14569 (general_thread, step_thread, thread_from_wait)
14570 (old_thread_from_wait): Update.
14571 * target.h (struct thread_resume): Use unsigned long for THREAD.
14572 (struct target_ops): Use unsigned long for arguments to attach and
14573 thread_alive.
14574
dcdb98d2
DJ
145752005-02-24 Daniel Jacobowitz <dan@codesourcery.com>
14576
14577 * acinclude.m4: Include bfd/bfd.m4 directly.
14578 * configure.ac: Use AC_ARG_PROGRAM. Suggested by Aron Griffis
14579 <agriffis@toolchain.org>.
14580 * aclocal.m4, configure: Regenerated.
14581
bec39cab
AC
145822005-01-07 Andrew Cagney <cagney@gnu.org>
14583
14584 * configure.ac: Rename configure.in, require autoconf 2.59.
14585 * configure: Re-generate.
14586
434c4c77
DJ
145872004-12-08 Daniel Jacobowitz <dan@debian.org>
14588
14589 * acinclude.m4 (SRV_CHECK_THREAD_DB): Add ps_get_thread_area. Reset
14590 LIBS when finished.
14591 * aclocal.m4: Regenerated.
14592 * configure: Regenerated.
14593
db1d3e1b
AS
145942004-11-21 Andreas Schwab <schwab@suse.de>
14595
14596 * linux-m68k-low.c (m68k_num_gregs): Define.
14597 (m68k_fill_gregset, m68k_store_gregset, m68k_fill_fpregset)
14598 (m68k_store_fpregset, target_regsets) [HAVE_LINUX_REGSETS]: New.
14599 (m68k_breakpoint, m68k_breakpoint_len, m68k_get_pc, m68k_set_pc)
14600 (m68k_breakpoint_at): New. Add to the_low_target.
14601
14602 * configure.srv (m68*-*-linux*): Set srv_linux_regsets and
14603 srv_linux_thread_db to yes.
14604
43360365
JB
146052004-10-20 Joel Brobecker <brobecker@gnat.com>
14606
14607 * linux-x86-64-low.c (ARCH_SET_GS): Add definition if missing.
14608 (ARCH_SET_FS): Likewise.
14609 (ARCH_GET_FS): Likewise.
14610 (ARCH_GET_GS): Likewise.
14611
fd500816
DJ
146122004-10-16 Daniel Jacobowitz <dan@debian.org>
14613
14614 * linux-i386-low.c (ps_get_thread_area): New.
14615 * linux-x86-64-low.c (ps_get_thread_area): New.
14616 * linux-low.c: Include <sys/syscall.h>.
14617 (linux_kill_one_process): Don't kill the first thread here.
14618 (linux_kill): Kill the first thread here.
14619 (kill_lwp): New function.
14620 (send_sigstop, linux_send_signal): Use it.
14621 * proc-service.c: Clean up #ifdefs.
14622 (fpregset_info): Delete.
14623 (ps_lgetregs): Update and enable implementation.
14624 (ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs): Remove disabled
14625 implementations.
14626 * remote-utils.c (struct sym_cache, symbol_cache): New.
14627 (input_interrupt): Print a clearer message.
14628 (async_io_enabled): New variable.
14629 (enable_async_io, disable_async_io): Use it. Update comments.
14630 (look_up_one_symbol): Use the symbol cache.
14631 * thread-db.c (thread_db_look_up_symbols): New function.
14632 (thread_db_init): Update comments. Call thread_db_look_up_symbols.
14633
f6de3c42
DJ
146342004-10-16 Daniel Jacobowitz <dan@debian.org>
14635
14636 * configure.in: Test for -rdynamic.
14637 * configure: Regenerated.
14638 * Makefile (INTERNAL_LDFLAGS): New.
14639 (gdbserver, gdbreplay): Use it.
14640
2c0fc042
AC
146412004-09-02 Andrew Cagney <cagney@gnu.org>
14642
14643 * Makefile.in (TAGS): Replace TM_FILE with DEPRECATED_TM_FILE.
14644
075b3282
DJ
146452004-03-23 Daniel Jacobowitz <drow@mvista.com>
14646
14647 * linux-low.c (linux_wait): Clear all_processes list also.
14648
fa6a77dc
DJ
146492004-03-12 Daniel Jacobowitz <drow@mvista.com>
14650
14651 * linux-low.c: Include <errno.h>. Remove extern declaration of
14652 errno.
14653
6d782a97
DJ
146542004-03-12 Daniel Jacobowitz <drow@mvista.com>
14655
14656 * gdbreplay.c, server.h, utils.c: Update copyright years.
14657
3a7fb99b
DJ
146582004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
14659
14660 * server.c (main): Print child status or termination signal from
14661 variable 'signal', not 'sig'.
14662
c3e735a6
DJ
146632004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
14664
14665 * linux-low.c (linux_read_memory): Change return type to
14666 int. Check for and return error from ptrace().
14667 * target.c (read_inferior_memory): Change return type to int. Pass
14668 back return status from the_target->read_memory().
14669 * target.h (struct target_ops): Adapt *read_memory() prototype.
14670 Update comment.
14671 (read_inferior_memory): Adapt prototype.
14672 * server.c (main): Return an error packet if
14673 read_inferior_memory() returns an error.
14674
a59d1c82
DJ
146752004-03-04 Daniel Jacobowitz <drow@mvista.com>
14676
14677 * Makefile.in (distclean): Remove config.h, stamp-h, and config.log.
14678 Unify with other clean targets.
14679
dc3f8883
DJ
146802004-02-29 Daniel Jacobowitz <drow@mvista.com>
14681
14682 * server.c (handle_v_cont): Call set_desired_inferior.
14683
89a208da
DJ
146842004-02-29 Daniel Jacobowitz <drow@mvista.com>
14685
14686 * remote-utils.c (prepare_resume_reply): Always supply "thread:".
14687
62ea82f5
DJ
146882004-02-29 Daniel Jacobowitz <drow@mvista.com>
14689
14690 * linux-low.c (linux_wait): Unblock async I/O.
14691 (linux_resume): Block and enable async I/O.
14692 * remote-utils.c (block_async_io, unblock_async_io): New functions.
14693 * server.h (block_async_io, unblock_async_io): Add prototypes.
14694
6910d122
DJ
146952004-02-29 Daniel Jacobowitz <drow@mvista.com>
14696
14697 * remote-utils.c (remote_open): Print a status notice after
14698 opening a TCP port.
14699 * server.c (attach_inferior): Print a status notice after
14700 attaching.
14701
147022004-02-29 Daniel Jacobowitz <drow@mvista.com>
d677d77d
DJ
14703
14704 * linux-arm-low.c (arm_get_pc): Print out stop PC in debug mode.
14705
c89dc5d4
DJ
147062004-02-26 Daniel Jacobowitz <drow@mvista.com>
14707
14708 * remote-utils.c (write_enn): Use "E01" instead of "ENN" for the
14709 error packet.
14710 * server.c, target.h: Update copyright years.
14711
4b8dad4a
RM
147122004-02-25 Roland McGrath <roland@redhat.com>
14713
14714 * target.h (struct target_ops): New member `read_auxv'.
14715 * server.c (handle_query): Handle qPart:auxv:read: query using that.
14716 * linux-low.c (linux_read_auxv): New function.
14717 (linux_target_ops): Initialize `read_auxv' member to that.
14718
d7446758
JB
147192004-02-17 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
14720
14721 Committed by Jim Blandy <jimb@redhat.com>.
14722
14723 * linux-s390-low.c (s390_num_regs): Update.
4b8dad4a 14724 (s390_regmap): Remove control registers. Use __s390x__ predefine
d7446758
JB
14725 instead of GPR_SIZE to distiguish s390 and s390x targets.
14726
5544ad89
DJ
147272004-01-31 Daniel Jacobowitz <drow@mvista.com>
14728
14729 * linux-low.c: Update copyright year.
14730 (check_removed_breakpoint): Clear pending_is_breakpoint.
14731 (linux_set_resume_request, linux_queue_one_thread)
14732 (resume_status_pending_p): New functions.
14733 (linux_continue_one_thread): Use process->resume.
14734 (linux_resume): Only resume threads if there are no pending events.
14735 * linux-low.h (struct process_info): Add resume request
14736 pointer.
14737
2a68b70e
DJ
147382004-01-30 Daniel Jacobowitz <drow@mvista.com>
14739
14740 * regcache.c (new_register_cache): Clear the allocated register
14741 buffer. Suggested by Atsushi Nemoto <anemo@mba.ocn.ne.jp>.
14742
64386c31
DJ
147432003-10-13 Daniel Jacobowitz <drow@mvista.com>
14744
14745 * linux-low.c (linux_resume): Take a struct thread_resume *
14746 argument.
14747 (linux_wait): Update call.
14748 (resume_ptr): New static variable.
14749 (linux_continue_one_thread): Renamed from
14750 linux_continue_one_process. Use resume_ptr.
14751 (linux_resume): Use linux_continue_one_thread.
14752 * server.c (handle_v_cont, handle_v_requests): New functions.
14753 (myresume): New function.
14754 (main): Handle 'v' case.
14755 * target.h (struct thread_resume): New type.
14756 (struct target_ops): Change argument of "resume" to struct
14757 thread_resume *.
14758 (myresume): Delete macro.
14759
c938e9b0
L
147602003-08-08 H.J. Lu <hongjiu.lu@intel.com>
14761
14762 * Makefile.in (install-only): Create dest dir. Support DESTDIR.
14763 (uninstall): Support DESTDIR.
14764
7f313d07
BC
14765Mon Jul 21 20:09:34 UTC 2003 Brendan Conoboy <blc@redhat.com>
14766
14767 * configure.srv: Add xscale*linux copy of arm*linux entry.
14768
3b2fc2ea
DJ
147692003-07-24 Daniel Jacobowitz <drow@mvista.com>
14770
14771 * linux-arm-low.c (arm_reinsert_addr): New function.
14772 (the_low_target): Add arm_reinsert_addr.
14773
1c0a559e
MK
147742003-07-08 Mark Kettenis <kettenis@gnu.org>
14775
14776 * mem-break.c: Remove whitespace at end of file.
14777
43d5792c
DJ
147782003-06-28 Daniel Jacobowitz <drow@mvista.com>
14779
14780 * configure.in: Check whether we need to prototype strerror.
14781 * server.h: Optionally prototype strerror.
14782 * gdbreplay.c (perror_with_name): Use strerror.
14783 * linux-low.c (linux_attach_lwp): Use strerror.
14784 * utils.c (perror_with_name): Use strerror.
14785 * config.in, configure: Regenerated.
14786
c8a86edf
DJ
147872003-06-28 Daniel Jacobowitz <drow@mvista.com>
14788
14789 * linux-sh-low.c (sh_regmap): Fix FP register offsets, reported by
14790 SUGIOKA Toshinobu <sugioka@itonet.co.jp>.
14791
73d37363
DJ
147922003-06-20 Daniel Jacobowitz <drow@mvista.com>
14793
14794 * Makefile.in (SFILES): Update.
14795 * low-hppabsd.c, low-lynx.c, low-nbsd.c, low-sim.c, low-sparc.c,
14796 low-sun3.c: Remove files.
14797
6ad8ae5c
DJ
147982003-06-17 Daniel Jacobowitz <drow@mvista.com>
14799
14800 * linux-low.c: Move comment to linux_thread_alive where it belonged.
14801 (linux_detach_one_process, linux_detach): New functions.
14802 (linux_target_ops): Add linux_detach.
14803 * server.c (main): Handle 'D' packet.
14804 * target.h (struct target_ops): Add "detach" member.
14805 (detach_inferior): Define.
14806
1581182a
MK
148072003-06-13 Mark Kettenis <kettenis@gnu.org>
14808
14809 From Kelley Cook <kelleycook@wideopenwest.com>:
14810 * configure.srv: Accept i[34567]86 variants.
14811
e5379b03
DJ
148122003-06-05 Daniel Jacobowitz <drow@mvista.com>
14813
14814 * linux-low.c (linux_wait_for_event): Correct comment typos.
14815 (linux_resume_one_process): Call check_removed_breakpoint.
14816 (linux_send_signal): New function.
14817 (linux_target_ops): Add linux_send_signal.
14818 * remote-utils.c (putpkt, input_interrupt): Use send_signal instead
14819 of kill.
14820 * target.h (struct target_ops): Add send_signal.
14821
2ff29de4
JB
148222003-05-29 Jim Blandy <jimb@redhat.com>
14823
14824 * linux-low.c (usr_store_inferior_registers): Transfer buf in
14825 PTRACE_XFER_TYPE-sized chunks, not int-sized chunks. Otherwise,
14826 if 'int' is smaller than PTRACE_XFER_TYPE, you end up throwing
14827 away part of the register's value.
14828
254787d4
DJ
148292003-03-26 Daniel Jacobowitz <drow@mvista.com>
14830
14831 * linux-low.c (linux_create_inferior): Use __SIGRTMIN.
14832 (linux_wait_for_event, linux_init_signals): Likewise.
14833
94e10508
DJ
148342003-03-17 Daniel Jacobowitz <drow@mvista.com>
14835
14836 * configure.in: Check for stdlib.h.
14837 * configure: Regenerated.
14838 * config.in: Regenerated.
14839
4c0711e0
DJ
148402003-01-04 Andreas Schwab <schwab@suse.de>
14841
14842 * linux-m68k-low.c (m68k_num_regs): Define to 29 instead of 31.
14843
ef66e766
AC
148442003-01-02 Andrew Cagney <ac131313@redhat.com>
14845
14846 * Makefile.in: Remove obsolete code.
14847
a1358604
DJ
148482002-11-20 Daniel Jacobowitz <drow@mvista.com>
14849
14850 * linux-s390-low.c (s390_regmap): Check GPR_SIZE instead of
14851 defined(PT_FPR0_HI).
14852
23ce3b1c
DJ
148532002-11-17 Stuart Hughes <seh@zee2.com>
14854
14855 * linux-arm-low.c (arm_num_regs): Increase.
14856 (arm_regmap): Include status register.
14857
148582002-11-17 Daniel Jacobowitz <drow@mvista.com>
14859
14860 * linux-low.c (register_addr): Remove incorrect -1 check.
14861
a9fa9f7d
DJ
148622002-08-29 Daniel Jacobowitz <drow@mvista.com>
14863
14864 * linux-low.c (linux_create_inferior): Call setpgid. Return
14865 the new PID.
14866 (unstopped_p, linux_signal_pid): Remove.
14867 (linux_target_ops): Remove linux_signal_pid.
14868 * remote-utils.c (putpkt, input_interrupt): Use signal_pid
14869 global instead of target method.
14870 * target.h (struct target_ops): Remove signal_pid. Update comment
14871 for create_inferior.
14872 * server.c (signal_pid): New variable.
14873 (create_inferior): Set signal_pid. Block SIGTTOU and SIGTTIN in
4b8dad4a 14874 gdbserver. Set the child to be the foreground process group.
a9fa9f7d
DJ
14875 (attach_inferior): Set signal_pid.
14876
17574093
DJ
148772002-08-23 Daniel Jacobowitz <drow@mvista.com>
14878
14879 * ChangeLog: New file, with entries from gdb/ChangeLog after GDB 5.2.
14880
148812002-08-20 Jim Blandy <jimb@redhat.com>
14882
14883 * Makefile.in (LDFLAGS): Allow the configure script to establish a
14884 default for this.
14885
148862002-08-01 Andrew Cagney <cagney@redhat.com>
14887
14888 * Makefile.in: Make chill references obsolete.
14889
148902002-07-24 Kevin Buettner <kevinb@redhat.com>
14891
14892 * configure.in (unistd.h): Add to AC_CHECK_HEADERS list.
14893 * configure: Regenerate.
14894 * config.in: Regenerate.
14895
148962002-07-09 David O'Brien <obrien@FreeBSD.org>
14897
14898 * gdbreplay.c (stdlib.h, unistd.h): Conditionaly include.
14899 (perror_with_name, remote_close, remote_open, expect, play): Static.
14900
149012002-07-04 Michal Ludvig <mludvig@suse.cz>
14902
4b8dad4a 14903 * linux-x86-64-low.c (x86_64_regmap): Make it an array of
17574093
DJ
14904 byte offsets instead of an array of indexes.
14905 (x86_64_store_gregset, x86_64_store_fpregset): Parameter made const.
14906
149072002-06-13 Daniel Jacobowitz <drow@mvista.com>
14908
14909 * regcache.c: Add comment.
14910
149112002-06-11 Daniel Jacobowitz <drow@mvista.com>
14912
14913 * thread-db.c: New file.
14914 * proc-service.c: New file.
14915 * acinclude.m4: New file.
14916 * Makefile.in: Add GDBSERVER_LIBS, gdb_proc_service_h,
14917 proc-service.o, and thread-db.o.
14918 (linux-low.o): Add USE_THREAD_DB.
14919 * acconfig.h: Add HAVE_PRGREGSET_T, HAVE_PRFPREGSET_T,
14920 HAVE_LWPID_T, HAVE_PSADDR_T, and PRFPREGSET_T_BROKEN.
14921 * aclocal.m4: Regenerated.
14922 * config.in: Regenerated.
14923 * configure: Regenerated.
14924 * configure.in: Check for proc_service.h, sys/procfs.h,
14925 thread_db.h, and linux/elf.h headrs.
14926 Check for lwpid_t, psaddr_t, prgregset_t, prfpregset_t, and
14927 PRFPREGSET_T_BROKEN. Introduce srv_thread_depfiles and USE_THREAD_DB.
14928 Check for -lthread_db and thread support.
14929 * configure.srv: Enable thread_db support for ARM, i386, MIPS,
14930 PowerPC, and SuperH.
14931 * i387-fp.c: Constify arguments.
14932 * i387-fp.h: Likewise.
14933 * inferiors.c: (struct thread_info): Renamed from
14934 `struct inferior_info'. Remove PID member. Use generic inferior
14935 list header. All uses updated.
14936 (inferiors, signal_pid): Removed.
14937 (all_threads): New variable.
14938 (get_thread): Define.
14939 (add_inferior_to_list): New function.
14940 (for_each_inferior): New function.
14941 (change_inferior_id): New function.
14942 (add_inferior): Removed.
14943 (remove_inferior): New function.
14944 (add_thread): New function.
14945 (free_one_thread): New function.
14946 (remove_thread): New function.
14947 (clear_inferiors): Use for_each_inferior and free_one_thread.
14948 (find_inferior): New function.
14949 (find_inferior_id): New function.
14950 (inferior_target_data): Update argument type.
14951 (set_inferior_target_data): Likewise.
14952 (inferior_regcache_data): Likewise.
14953 (set_inferior_regcache_data): Likewise.
14954 * linux-low.c (linux_bp_reinsert): Remove.
14955 (all_processes, stopping_threads, using_thrads)
14956 (struct pending_signals, debug_threads, pid_of): New.
14957 (inferior_pid): Replace with macro.
14958 (struct inferior_linux_data): Remove.
14959 (get_stop_pc, add_process): New functions.
14960 (linux_create_inferior): Restore SIGRTMIN+1 before calling exec.
14961 Use add_process and add_thread.
14962 (linux_attach_lwp): New function, based on old linux_attach. Use
14963 add_process and add_thread. Set stop_expected for new threads.
14964 (linux_attach): New function.
14965 (linux_kill_one_process): New function.
14966 (linux_kill): Kill all LWPs.
14967 (linux_thread_alive): Use find_inferior_id.
14968 (check_removed_breakpoints, status_pending_p): New functions.
14969 (linux_wait_for_process): Renamed from linux_wait_for_one_inferior.
14970 Update. Use WNOHANG. Wait for cloned processes also. Update process
14971 struct for the found process.
14972 (linux_wait_for_event): New function.
14973 (linux_wait): Use it. Support LWPs.
14974 (send_sigstop, wait_for_sigstop, stop_all_processes)
14975 (linux_resume_one_process, linux_continue_one_process): New functions.
14976 (linux_resume): Support LWPs.
14977 (REGISTER_RAW_SIZE): Remove.
14978 (fetch_register): Use register_size instead. Call supply_register.
14979 (usr_store_inferior_registers): Likewise. Call collect_register.
14980 Fix recursive case.
14981 (regsets_fetch_inferior_registers): Improve error message.
14982 (regsets_store_inferior_registers): Add debugging.
14983 (linux_look_up_symbols): Call thread_db_init if USE_THREAD_DB.
14984 (unstopped_p, linux_signal_pid): New functions.
14985 (linux_target_ops): Add linux_signal_pid.
14986 (linux_init_signals): New function.
14987 (initialize_low): Call it. Initialize using_threads.
14988 * regcache.c (inferior_regcache_data): Add valid
14989 flag.
14990 (get_regcache): Fetch registers lazily. Add fetch argument
14991 and update all callers.
14992 (regcache_invalidate_one, regcache_invalidate): New
14993 functions.
14994 (new_register_cache): Renamed from create_register_cache.
14995 Return the new regcache.
14996 (free_register_cache): Change argument to a void *.
14997 (registers_to_string, registers_from_string): Call get_regcache
14998 with fetch flag set.
14999 (register_data): Make static. Pass fetch flag to get_regcache.
15000 (supply_register): Call get_regcache with fetch flag clear.
15001 (collect_register): Call get_regcache with fetch flag set.
15002 (collect_register_as_string): New function.
15003 * regcache.h: Update.
15004 * remote-utils.c (putpkt): Flush after debug output and use
15005 stderr.
15006 Handle input interrupts while waiting for an ACK.
15007 (input_interrupt): Use signal_pid method.
15008 (getpkt): Flush after debug output and use stderr.
15009 (outreg): Use collect_register_as_string.
15010 (new_thread_notify, dead_thread_notify): New functions.
15011 (prepare_resume_reply): Check using_threads. Set thread_from_wait
15012 and general_thread.
15013 (look_up_one_symbol): Flush after debug output.
15014 * server.c (step_thread, server_waiting): New variables.
15015 (start_inferior): Don't use signal_pid. Update call to mywait.
15016 (attach_inferior): Update call to mywait.
15017 (handle_query): Handle qfThreadInfo and qsThreadInfo.
15018 (main): Don't fetch/store registers explicitly. Use
15019 set_desired_inferior. Support proposed ``Hs'' packet. Update
15020 calls to mywait.
15021 * server.h: Update.
15022 (struct inferior_list, struct_inferior_list_entry): New.
15023 * target.c (set_desired_inferior): New.
15024 (write_inferior_memory): Constify.
15025 (mywait): New function.
15026 * target.h: Update.
15027 (struct target_ops): New signal_pid method.
15028 (mywait): Removed macro, added prototype.
15029
15030 * linux-low.h (regset_func): Removed.
15031 (regset_fill_func, regset_store_func): New.
15032 (enum regset_type): New.
15033 (struct regset_info): Add type field. Use new operation types.
15034 (struct linux_target_ops): stop_pc renamed to get_pc.
15035 Add decr_pc_after_break and breakpoint_at.
15036 (get_process, get_thread_proess, get_process_thread)
15037 (strut process_info, all_processes, linux_attach_lwp)
15038 (thread_db_init): New.
15039
15040 * linux-arm-low.c (arm_get_pc, arm_set_pc,
15041 arm_breakpoint, arm_breakpoint_len, arm_breakpoint_at): New.
15042 (the_low_target): Add new members.
15043 * linux-i386-low.c (i386_store_gregset, i386_store_fpregset)
15044 (i386_store_fpxregset): Constify.
15045 (target_regsets): Add new kind identifier.
15046 (i386_get_pc): Renamed from i386_stop_pc. Simplify.
15047 (i386_set_pc): Add debugging.
15048 (i386_breakpoint_at): New function.
15049 (the_low_target): Add new members.
15050 * linux-mips-low.c (mips_get_pc, mips_set_pc)
15051 (mips_breakpoint, mips_breakpoint_len, mips_reinsert_addr)
15052 (mips_breakpoint_at): New.
15053 (the_low_target): Add new members.
15054 * linux-ppc-low.c (ppc_get_pc, ppc_set_pc)
15055 (ppc_breakpoint, ppc_breakpoint_len, ppc_breakpoint_at): New.
15056 (the_low_target): Add new members.
15057 * linux-sh-low.c (sh_get_pc, sh_set_pc)
15058 (sh_breakpoint, sh_breakpoint_len, sh_breakpoint_at): New.
15059 (the_low_target): Add new members.
15060 * linux-x86-64-low.c (target_regsets): Add new kind
15061 identifier.
15062
150632002-05-15 Daniel Jacobowitz <drow@mvista.com>
15064
15065 From Martin Pool <mbp@samba.org>:
15066 * server.c (gdbserver_usage): New function.
15067 (main): Call it.
15068
150692002-05-14 Daniel Jacobowitz <drow@mvista.com>
15070
15071 * mem-break.c (reinsert_breakpoint_by_bp): Correct typo
15072 stop_at -> stop_pc.
15073
150742002-05-04 Andrew Cagney <ac131313@redhat.com>
15075
15076 * Makefile.in: Remove obsolete code.
15077
150782002-04-24 Michal Ludvig <mludvig@suse.cz>
15079
15080 * linux-low.c (regsets_fetch_inferior_registers),
15081 (regsets_store_inferior_registers): Removed cast to int from
15082 ptrace() calls.
15083 * regcache.h: Added declaration of struct inferior_info.
15084
150852002-04-20 Daniel Jacobowitz <drow@mvista.com>
15086
15087 * inferiors.c (struct inferior_info): Add regcache_data.
15088 (add_inferior): Call create_register_cache.
15089 (clear_inferiors): Call free_register_cache.
15090 (inferior_regcache_data, set_inferior_regcache_data): New functions.
15091 * regcache.c (struct inferior_regcache_data): New.
15092 (registers): Remove.
15093 (get_regcache): New function.
15094 (create_register_cache, free_register_cache): New functions.
15095 (set_register_cache): Don't initialize the register cache here.
15096 (registers_to_string, registers_from_string, register_data): Call
15097 get_regcache.
15098 * regcache.h: Add prototypes.
15099 * server.h: Likewise.
15100
151012002-04-20 Daniel Jacobowitz <drow@mvista.com>
15102
15103 * mem-break.c: New file.
15104 * mem-break.h: New file.
15105 * Makefile.in: Add mem-break.o rule; update server.h
15106 dependencies.
15107 * inferiors.c (struct inferior_info): Add target_data
15108 member.
15109 (clear_inferiors): Free target_data member if set.
15110 (inferior_target_data, set_inferior_target_data): New functions.
15111 * linux-i386-low.c (i386_breakpoint, i386_breakpoint_len)
15112 (i386_stop_pc, i386_set_pc): New. Add to the_low_target.
15113 * linux-low.c (linux_bp_reinsert): New variable.
15114 (struct inferior_linux_data): New.
15115 (linux_create_inferior): Use set_inferior_target_data.
15116 (linux_attach): Likewise. Call add_inferior.
15117 (linux_wait_for_one_inferior): New function.
15118 (linux_wait): Call it.
15119 (linux_write_memory): Add const.
15120 (initialize_low): Call set_breakpoint_data.
15121 * linux-low.h (struct linux_target_ops): Add breakpoint
15122 handling members.
15123 * server.c (attach_inferior): Remove extra add_inferior
15124 call.
15125 * server.h: Include mem-break.h. Update inferior.c
15126 prototypes.
15127 * target.c (read_inferior_memory)
15128 (write_inferior_memory): New functions.
15129 * target.h (read_inferior_memory)
15130 (write_inferior_memory): Change macros to prototypes.
15131 (struct target_ops): Update comments. Add const to write_memory
15132 definition.
15133
151342002-04-11 Daniel Jacobowitz <drow@mvista.com>
15135
15136 * linux-low.c (usr_store_inferior_registers): Support
15137 registers which are allowed to fail to store.
15138 * linux-low.h (linux_target_ops): Likewise.
15139 * linux-ppc-low.c (ppc_regmap): Support FPSCR.
15140 (ppc_cannot_store_register): FPSCR may not be storable.
15141
151422002-04-09 Daniel Jacobowitz <drow@mvista.com>
15143
15144 * server.h: Include <string.h> if HAVE_STRING_H.
15145 * ChangeLog: Correct paths in last ChangeLog entry.
15146
151472002-04-09 Daniel Jacobowitz <drow@mvista.com>
15148
15149 * linux-low.h: Remove obsolete prototypes.
15150 (struct linux_target_ops): New.
15151 (extern the_low_target): New.
15152 * linux-low.c (num_regs, regmap): Remove declarations.
15153 (register_addr): Use the_low_target explicitly.
15154 (fetch_register): Likewise.
15155 (usr_fetch_inferior_registers): Likewise.
15156 (usr_store_inferior_registers): Likewise.
15157 * linux-arm-low.c (num_regs): Remove.
15158 (arm_num_regs): Define.
15159 (arm_regmap): Renamed from regmap, made static.
15160 (arm_cannot_fetch_register): Renamed from cannot_fetch_register,
15161 made static.
15162 (arm_cannot_store_register): Renamed from cannot_store_register,
15163 made static.
15164 (the_low_target): New.
15165 * linux-i386-low.c (num_regs): Remove.
15166 (i386_num_regs): Define.
15167 (i386_regmap): Renamed from regmap, made static.
15168 (i386_cannot_fetch_register): Renamed from cannot_fetch_register,
15169 made static.
15170 (i386_cannot_store_register): Renamed from cannot_store_register,
15171 made static.
15172 (the_low_target): New.
15173 * linux-ia64-low.c (num_regs): Remove.
15174 (ia64_num_regs): Define.
15175 (ia64_regmap): Renamed from regmap, made static.
15176 (ia64_cannot_fetch_register): Renamed from cannot_fetch_register,
15177 made static.
15178 (ia64_cannot_store_register): Renamed from cannot_store_register,
15179 made static.
15180 (the_low_target): New.
15181 * linux-m68k-low.c (num_regs): Remove.
15182 (m68k_num_regs): Define.
15183 (m68k_regmap): Renamed from regmap, made static.
15184 (m68k_cannot_fetch_register): Renamed from cannot_fetch_register,
15185 made static.
15186 (m68k_cannot_store_register): Renamed from cannot_store_register,
15187 made static.
15188 (the_low_target): New.
15189 * linux-mips-low.c (num_regs): Remove.
15190 (mips_num_regs): Define.
15191 (mips_regmap): Renamed from regmap, made static.
15192 (mips_cannot_fetch_register): Renamed from cannot_fetch_register,
15193 made static.
15194 (mips_cannot_store_register): Renamed from cannot_store_register,
15195 made static.
15196 (the_low_target): New.
15197 * linux-ppc-low.c (num_regs): Remove.
15198 (ppc_num_regs): Define.
15199 (ppc_regmap): Renamed from regmap, made static.
15200 (ppc_cannot_fetch_register): Renamed from cannot_fetch_register,
15201 made static.
15202 (ppc_cannot_store_register): Renamed from cannot_store_register,
15203 made static.
15204 (the_low_target): New.
15205 * linux-s390-low.c (num_regs): Remove.
15206 (s390_num_regs): Define.
15207 (s390_regmap): Renamed from regmap, made static.
15208 (s390_cannot_fetch_register): Renamed from cannot_fetch_register,
15209 made static.
15210 (s390_cannot_store_register): Renamed from cannot_store_register,
15211 made static.
15212 (the_low_target): New.
15213 * linux-sh-low.c (num_regs): Remove.
15214 (sh_num_regs): Define.
15215 (sh_regmap): Renamed from regmap, made static.
15216 (sh_cannot_fetch_register): Renamed from cannot_fetch_register,
15217 made static.
15218 (sh_cannot_store_register): Renamed from cannot_store_register,
15219 made static.
15220 (the_low_target): New.
15221 * linux-x86-64-low.c (x86_64_regmap): Renamed from regmap.
15222 (the_low_target): New.
15223
152242002-04-09 Daniel Jacobowitz <drow@mvista.com>
15225
15226 * Makefile.in: Add stamp-h target.
15227 * configure.in: Create stamp-h.
15228 * configure: Regenerated.
15229
152302002-04-09 Daniel Jacobowitz <drow@mvista.com>
15231
15232 * inferiors.c: New file.
15233 * target.c: New file.
15234 * target.h: New file.
15235 * Makefile.in: Add target.o and inferiors.o. Update
15236 dependencies.
15237 * linux-low.c (inferior_pid): New static variable,
15238 moved from server.c.
15239 (linux_create_inferior): Renamed from create_inferior.
15240 Call add_inferior. Return 0 on success instead of a PID.
15241 (linux_attach): Renamed from myattach.
15242 (linux_kill): Renamed from kill_inferior. Call clear_inferiors ().
15243 (linux_thread_alive): Renamed from mythread_alive.
15244 (linux_wait): Renamed from mywait. Call clear_inferiors () if the
15245 child dies.
15246 (linux_resume): Renamed from myresume. Add missing ``return 0''.
15247 (regsets_store_inferior_registers): Correct error message.
15248 Add missing ``return 0''.
15249 (linux_fetch_registers): Renamed from fetch_inferior_registers.
15250 (linux_store_registers): Renamed from store_inferior_registers.
15251 (linux_read_memory): Renamed from read_inferior_memory.
15252 (linux_write_memory): Renamed from write_inferior_memory.
15253 (linux_target_ops): New structure.
15254 (initialize_low): Call set_target_ops ().
15255 * remote-utils.c (unhexify): New function.
15256 (hexify): New function.
15257 (input_interrupt): Send signals to ``signal_pid''.
15258 * server.c (inferior_pid): Remove.
15259 (start_inferior): Update create_inferior call.
15260 (attach_inferior): Call add_inferior.
15261 (handle_query): New function.
15262 (main): Call handle_query for `q' packets.
15263 * server.h: Include "target.h". Remove obsolete prototypes.
15264 Add prototypes for "inferiors.c", "target.c", hexify, and unhexify.
15265
152662002-04-09 Daniel Jacobowitz <drow@mvista.com>
15267
15268 * Makefile.in: Add WARN_CFLAGS. Update configury
15269 dependencies.
15270 * configure.in: Check for <string.h>
15271 * configure: Regenerate.
15272 * config.in: Regenerate.
15273 * gdbreplay.c: Include needed system headers.
15274 (remote_open): Remove strchr prototype.
15275 * linux-low.h: Correct #ifdef to HAVE_LINUX_USRREGS.
15276 * regcache.c (supply_register): Change buf argument to const void *.
15277 (supply_register_by_name): Likewise.
15278 (collect_register): Change buf argument to void *.
15279 (collect_register_by_name): Likewise.
15280 * regcache.h: Add missing prototypes.
15281 * remote-utils.c: Include <arpa/inet.h> for inet_ntoa.
15282 * server.c (handle_query): New function.
15283 (attached): New static variable, moved out of main.
15284 (main): Quiet longjmp clobber warnings.
15285 * server.h: Add ATTR_NORETURN and ATTR_FORMAT. Update prototypes.
15286 * utils.c (error): Remove NORETURN.
15287 (fatal): Likewise.
This page took 1.826216 seconds and 4 git commands to generate.