269fb08508096c9ec60e1a9bad13a25768dbca8e
[deliverable/binutils-gdb.git] / gdb / gdbserver / ChangeLog
1 2010-04-12 Pedro Alves <pedro@codesourcery.com>
2
3 * linux-low.c (linux_mourn): Also remove the process.
4 * server.c (handle_target_event): Don't remove the process here.
5 * nto-low.c (nto_mourn): New.
6 (nto_target_ops): Install it.
7 * spu-low.c (spu_mourn): New.
8 (spu_target_ops): Install it.
9 * win32-low.c (win32_mourn): New.
10 (win32_target_ops): Install it.
11
12 2010-04-12 Pedro Alves <pedro@codesourcery.com>
13
14 * server.h (buffer_xml_printf): Remove redundant `;'.
15
16 2010-04-12 Pedro Alves <pedro@codesourcery.com>
17
18 * regcache.c (set_register_cache): Invalidate regcaches before
19 changing the register cache layout.
20 (regcache_invalidate_one): Allow a NULL regcache.
21 * linux-x86-low.c (x86_linux_update_xmltarget): Invalidate
22 regcaches before changing the register cache layout or the target
23 regsets.
24
25 2010-04-12 H.J. Lu <hongjiu.lu@intel.com>
26
27 * linux-x86-low.c (x86_linux_update_xmltarget): Avoid unused
28 variable warning on Linux/x86-64.
29
30 2010-04-11 Pedro Alves <pedro@codesourcery.com>
31
32 GDBserver disconnected tracing support.
33
34 * linux-low.c (linux_remove_process): Delete.
35 (add_lwp): Don't set last_resume_kind here.
36 (linux_kill): Use `mourn'.
37 (linux_detach): Use `thread_db_detach', and `mourn'.
38 (linux_mourn): New.
39 (linux_attach_lwp_1): Adjust comment.
40 (linux_attach): last_resume_kind moved the thread_info; adjust.
41 (status_pending_p_callback): Adjust.
42 (linux_wait_for_event_1): Adjust.
43 (count_events_callback, select_singlestep_lwp_callback)
44 (select_event_lwp_callback, cancel_breakpoints_callback)
45 (db_wants_lwp_stopped, linux_wait_1, need_step_over_p)
46 (proceed_one_lwp): Adjust.
47 (linux_async): Add debug output.
48 (linux_thread_stopped): New.
49 (linux_pause_all): New.
50 (linux_target_ops): Install linux_mourn, linux_thread_stopped and
51 linux_pause_all.
52 * linux-low.h (struct lwp_info): Delete last_resume_kind field.
53 (thread_db_free): Delete declaration.
54 (thread_db_detach, thread_db_mourn): Declare.
55 * thread-db.c (thread_db_init): Use thread_db_mourn.
56 (thread_db_free): Delete, split in two.
57 (disable_thread_event_reporting): New.
58 (thread_db_detach): New.
59 (thread_db_mourn): New.
60
61 * server.h (struct thread_info) <last_resume_kind>: New field.
62 <attached>: Add comment.
63 <gdb_detached>: New field.
64 (handler_func): Change return type to int.
65 (handle_serial_event, handle_target_event): Ditto.
66 (gdb_connected): Declare.
67 (tracing): Delete.
68 (disconnected_tracing): Declare.
69 (stop_tracing): Declare.
70
71 * server.c (handle_query) <qSupported>: Report support for
72 disconnected tracing.
73 (queue_stop_reply_callback): Account for running threads.
74 (gdb_wants_thread_stopped): New.
75 (gdb_wants_all_threads_stopped): New.
76 (gdb_reattached_process): New.
77 (handle_status): Clear the `gdb_detached' flag of all processes.
78 In all-stop, stop all threads.
79 (main): Be sure to leave tfind mode. Handle disconnected tracing.
80 (process_serial_event): If the remote connection breaks, or if an
81 exit was forced with "monitor exit", force an event loop exit.
82 Handle disconnected tracing on detach.
83 (handle_serial_event): Adjust.
84 (handle_target_event): If GDB isn't connected, forward events back
85 to the inferior, unless the last process exited, in which case,
86 exit gdbserver. Adjust interface.
87
88 * remote-utils.c (remote_open): Don't block in accept. Instead
89 register an event loop source on the listen socket file
90 descriptor. Refactor bits into ...
91 (listen_desc): ... this new global.
92 (gdb_connected): ... this new function.
93 (enable_async_notification): ... this new function.
94 (handle_accept_event): ... this new function.
95 (remote_close): Clear remote_desc.
96
97 * inferiors.c (add_thread): Set the new thread's last_resume_kind.
98
99 * target.h (struct target_ops) <mourn, thread_stopped, pause_all>:
100 New fields.
101 (mourn_inferior): Define.
102 (target_process_qsupported): Avoid the dangling else problem.
103 (thread_stopped): Define.
104 (pause_all): Define.
105 (target_waitstatus_to_string): Declare.
106 * target.c (target_waitstatus_to_string): New.
107
108 * tracepoint.c (tracing): Make extern.
109 (disconnected_tracing): New.
110 (stop_tracing): Make extern. Handle tracing stops due to GDB
111 disconnecting.
112 (cmd_qtdisconnected): New.
113 (cmd_qtstatus): Report disconnected tracing status in trace reply.
114 (handle_tracepoint_general_set): Handle QTDisconnected.
115
116 * event-loop.c (event_handler_func): Change return type to int.
117 (process_event): Bail out if the event handler wants the event
118 loop to stop.
119 (handle_file_event): Ditto.
120 (start_event_loop): Bail out if the event handler wants the event
121 loop to stop.
122
123 * nto-low.c (nto_target_ops): Adjust.
124 * spu-low.c (spu_wait): Don't remove the process here.
125 (spu_target_ops): Adjust.
126 * win32-low.c (win32_wait): Don't remove the process here.
127 (win32_target_ops): Adjust.
128
129 2010-04-11 Pedro Alves <pedro@codesourcery.com>
130
131 * regcache.c (realloc_register_cache): Invalidate inferior's
132 regcache before recreating it.
133
134 2010-04-09 Pedro Alves <pedro@codesourcery.com>
135
136 * tracepoint.c (cmd_qtstatus): Report trace buffer circularity.
137
138 2010-04-09 Stan Shebs <stan@codesourcery.com>
139 Pedro Alves <pedro@codesourcery.com>
140
141 * server.h (LONGEST): New.
142 (struct thread_info) <while_stepping>: New field.
143 (unpack_varlen_hex, xrealloc, pulongest, plongest, phex_nz):
144 Declare.
145 (initialize_tracepoint, handle_tracepoint_general_set)
146 (handle_tracepoint_query, tracepoint_finished_step)
147 (tracepoint_was_hit, release_while_stepping_state_list):
148 (current_traceframe): Declare.
149 * server.c (handle_general_set): Handle tracepoint packets.
150 (read_memory): New.
151 (write_memory): New.
152 (handle_search_memory_1): Use read_memory.
153 (handle_query): Report support for conditional tracepoints, trace
154 state variables, and tracepoint sources. Handle tracepoint
155 queries.
156 (main): Initialize the tracepoints module.
157 (process_serial_event): Handle traceframe reads/writes.
158
159 * linux-low.c (handle_tracepoints): New.
160 (linux_wait_1): Call it.
161 (linux_resume_one_lwp): Handle while-stepping.
162 (linux_supports_tracepoints, linux_read_pc, linux_write_pc): New.
163 (linux_target_ops): Install them.
164 * linux-low.h (struct linux_target_ops) <supports_tracepoints>:
165 New field.
166 * linux-x86-low.c (x86_supports_tracepoints): New.
167 (the_low_target). Install it.
168
169 * mem-break.h (delete_breakpoint): Declare.
170 * mem-break.c (delete_breakpoint): Make external.
171
172 * target.h (struct target_ops): Add `supports_tracepoints',
173 `read_pc', and `write_pc' fields.
174 (target_supports_tracepoints): Define.
175 * utils.c (xrealloc, decimal2str, pulongest, plongest, thirty_two)
176 (phex_nz): New.
177
178 * regcache.h (struct regcache) <registers_owned>: New field.
179 (init_register_cache, regcache_cpy): Declare.
180 (regcache_read_pc, regcache_write_pc): Declare.
181 (register_cache_size): Declare.
182 (supply_regblock): Declare.
183 * regcache.c (init_register_cache): New.
184 (new_register_cache): Use it.
185 (regcache_cpy): New.
186 (register_cache_size): New.
187 (supply_regblock): New.
188 (regcache_read_pc, regcache_write_pc): New.
189
190 * tracepoint.c: New.
191
192 * Makefile.in (OBS): Add tracepoint.o.
193 (tracepoint.o): New rule.
194
195 2010-04-08 H.J. Lu <hongjiu.lu@intel.com>
196
197 * Makefile.in (clean): Also remove i386-mmx.c i386-mmx-linux.c.
198 (i386-mmx.o): New.
199 (i386-mmx.c): Likewise.
200 (i386-mmx-linux.o): Likewise.
201 (i386-mmx-linux.c): Likewise.
202
203 * configure.srv (srv_i386_regobj): Add i386-mmx.o.
204 (srv_i386_linux_regobj): Add i386-mmx-linux.o.
205 (srv_i386_xmlfiles): Add i386/i386-mmx.xml.
206 (srv_i386_linux_xmlfiles): Add i386/i386-mmx-linux.xml.
207
208 * linux-x86-low.c (init_registers_i386_mmx_linux): New.
209 (x86_linux_update_xmltarget): Call init_registers_i386_mmx_linux
210 and return if ptrace PTRACE_GETFPXREGS failed in 32bit.
211
212 2010-04-07 H.J. Lu <hongjiu.lu@intel.com>
213
214 * Makefile.in (clean): Updated.
215 (i386-avx.o): New.
216 (i386-avx.c): Likewise.
217 (i386-avx-linux.o): Likewise.
218 (i386-avx-linux.c): Likewise.
219 (amd64-avx.o): Likewise.
220 (amd64-avx.c): Likewise.
221 (amd64-avx-linux.o): Likewise.
222 (amd64-avx-linux.c): Likewise.
223
224 * configure.srv (srv_i386_regobj): Add i386-avx.o.
225 (srv_i386_linux_regobj): Add i386-avx-linux.o.
226 (srv_amd64_regobj): Add amd64-avx.o.
227 (srv_amd64_linux_regobj): Add amd64-avx-linux.o.
228 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx.xml.
229 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx.xml.
230 (srv_i386_xmlfiles): Add i386/i386-avx.xml.
231 (srv_amd64_xmlfiles): Add i386/amd64-avx.xml.
232 (srv_i386_linux_xmlfiles): Add i386/i386-avx-linux.xml.
233 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-linux.xml.
234
235 * i387-fp.c: Include "i386-xstate.h".
236 (i387_xsave): New.
237 (i387_cache_to_xsave): Likewise.
238 (i387_xsave_to_cache): Likewise.
239 (x86_xcr0): Likewise.
240
241 * i387-fp.h (i387_cache_to_xsave): Likewise.
242 (i387_xsave_to_cache): Likewise.
243 (x86_xcr0): Likewise.
244
245 * linux-arm-low.c (target_regsets): Initialize nt_type to 0.
246 * linux-crisv32-low.c (target_regsets): Likewise.
247 * linux-m68k-low.c (target_regsets): Likewise.
248 * linux-mips-low.c (target_regsets): Likewise.
249 * linux-ppc-low.c (target_regsets): Likewise.
250 * linux-s390-low.c (target_regsets): Likewise.
251 * linux-sh-low.c (target_regsets): Likewise.
252 * linux-sparc-low.c (target_regsets): Likewise.
253 * linux-xtensa-low.c (target_regsets): Likewise.
254
255 * linux-low.c: Include <sys/uio.h>.
256 (regsets_fetch_inferior_registers): Support nt_type.
257 (regsets_store_inferior_registers): Likewise.
258 (linux_process_qsupported): New.
259 (linux_target_ops): Add linux_process_qsupported.
260
261 * linux-low.h (regset_info): Add nt_type.
262 (linux_target_ops): Add process_qsupported.
263
264 * linux-x86-low.c: Include "i386-xstate.h", "elf/common.h"
265 and <sys/uio.h>.
266 (init_registers_i386_avx_linux): New.
267 (init_registers_amd64_avx_linux): Likewise.
268 (xmltarget_i386_linux_no_xml): Likewise.
269 (xmltarget_amd64_linux_no_xml): Likewise.
270 (PTRACE_GETREGSET): Likewise.
271 (PTRACE_SETREGSET): Likewise.
272 (x86_fill_xstateregset): Likewise.
273 (x86_store_xstateregset): Likewise.
274 (use_xml): Likewise.
275 (x86_linux_update_xmltarget): Likewise.
276 (x86_linux_process_qsupported): Likewise.
277 (target_regsets): Add NT_X86_XSTATE entry and Initialize nt_type.
278 (x86_arch_setup): Don't call init_registers_amd64_linux nor
279 init_registers_i386_linux here. Call
280 x86_linux_update_xmltarget.
281 (the_low_target): Add x86_linux_process_qsupported.
282
283 * server.c (handle_query): Call target_process_qsupported.
284
285 * target.h (target_ops): Add process_qsupported.
286 (target_process_qsupported): New.
287
288 2010-04-03 Pedro Alves <pedro@codesourcery.com>
289
290 * inferiors.c (add_thread): Set last_status kind to
291 TARGET_WAITKIND_IGNORE.
292 * linux-low.c (cancel_breakpoint): Remove unnecessary regcache
293 fetch. Use ptid_of. Avoid unnecessary get_lwp_thread calls.
294 (linux_wait_1): Move `thread' local definition to block that uses
295 it. Don't NULL initialize `event_child'.
296 (linux_resume_one_thread): Avoid unnecessary get_lwp_thread calls.
297 Alway set the thread's last_status to TARGET_WAITKIND_IGNORE.
298 * linux-x86-low.c (x86_breakpoint_at): Read raw memory.
299
300 2010-04-01 Pedro Alves <pedro@codesourcery.com>
301
302 * linux-low.c (get_stop_pc): Don't adjust the PC if stopped with
303 an extended waitstatus, or by a watchpoint.
304 (cancel_breakpoints_callback): Don't cancel a breakpoint if the
305 thread was stepping or has been stopped by a watchpoint.
306
307 2010-04-01 Pedro Alves <pedro@codesourcery.com>
308
309 * mem-break.c (struct raw_breakpoint): New field shlib_disabled.
310 (set_gdb_breakpoint_at): If GDB is inserting a breakpoint on top
311 of another, then delete the previous, and validate all
312 breakpoints.
313 (validate_inserted_breakpoint): New.
314 (delete_disabled_breakpoints): New.
315 (validate_breakpoints): New.
316 (check_mem_read): Validate breakpoints before trusting their
317 shadow. Delete disabled breakpoints.
318 (check_mem_write): Validate breakpoints before trusting they
319 should be inserted. Delete disabled breakpoints.
320 * mem-break.h (validate_breakpoints):
321 * server.c (handle_query): Validate breakpoints when we see a
322 qSymbol query.
323
324 2010-04-01 Pedro Alves <pedro@codesourcery.com>
325
326 * linux-low.c (linux_wait_1): Avoid setting need_step_over is
327 there's a GDB breakpoint at stop_pc. Always report a trap to GDB
328 if we could tell there's a GDB breakpoint at stop_pc.
329 (need_step_over_p): Don't do a step over if we find a GDB
330 breakpoint at the resume PC.
331
332 * mem-break.c (struct raw_breakpoint): New.
333 (enum bkpt_type): New type `gdb_breakpoint'.
334 (struct breakpoint): Delete the `PC', `old_data' and `inserted'
335 fields. New field `raw'.
336 (find_raw_breakpoint_at): New.
337 (set_raw_breakpoint_at): Handle refcounting. Create a raw
338 breakpoint instead.
339 (set_breakpoint_at): Adjust.
340 (delete_raw_breakpoint): New.
341 (release_breakpoint): New.
342 (delete_breakpoint): Rename to...
343 (delete_breakpoint_1): ... this. Add proc parameter. Use
344 release_breakpoint. Return ENOENT.
345 (delete_breakpoint): Reimplement.
346 (find_breakpoint_at): Delete.
347 (find_gdb_breakpoint_at): New.
348 (delete_breakpoint_at): Delete.
349 (set_gdb_breakpoint_at): New.
350 (delete_gdb_breakpoint_at): New.
351 (gdb_breakpoint_here): New.
352 (set_reinsert_breakpoint): Use release_breakpoint.
353 (uninsert_breakpoint): Rename to ...
354 (uninsert_raw_breakpoint): ... this.
355 (uninsert_breakpoints_at): Adjust to handle raw breakpoints.
356 (reinsert_raw_breakpoint): Change parameter type to
357 raw_breakpoint.
358 (reinsert_breakpoints_at): Adjust to handle raw breakpoints
359 instead.
360 (check_breakpoints): Adjust. Use release_breakpoint.
361 (breakpoint_here): Rewrite using find_raw_breakpoint_at.
362 (breakpoint_inserted_here): Ditto.
363 (check_mem_read): Adjust to iterate over raw breakpoints instead.
364 Don't trust the breakpoint's shadow if it is not inserted.
365 (check_mem_write): Adjust to iterate over raw breakpoints instead.
366 (delete_all_breakpoints): Adjust.
367 (free_all_breakpoints): Mark all breakpoints as uninserted, and
368 use delete_breakpoint_1.
369
370 * mem-break.h (breakpoints_supported): Delete declaration.
371 (set_gdb_breakpoint_at): Declare.
372 (gdb_breakpoint_here): Declare.
373 (delete_breakpoint_at): Delete.
374 (delete_gdb_breakpoint_at): Declare.
375
376 * server.h (struct raw_breakpoint): Forward declare.
377 (struct process_info): New field `raw_breakpoints'.
378
379 * linux-x86-low.c (x86_insert_point, x86_remote_point): Handle Z0
380 breakpoints.
381
382 2010-03-24 Pedro Alves <pedro@codesourcery.com>
383
384 * linux-low.c (status_pending_p_callback): Fix comment.
385 (linux_wait_for_event_1): Move most of the internal breakpoint
386 handling from here...
387 (linux_wait_1): ... to here.
388 (count_events_callback): New.
389 (select_singlestep_lwp_callback): New.
390 (select_event_lwp_callback): New.
391 (cancel_breakpoints_callback): New.
392 (select_event_lwp): New.
393 (linux_wait_1): Simplify internal breakpoint handling. Give equal
394 priority to all LWPs that have had events that should be reported
395 to the client. Cancel breakpoints when about to reporting the
396 event to the client, not while stopping lwps. No longer cancel
397 finished single-steps here.
398 (cancel_finished_single_step): Delete.
399 (cancel_finished_single_steps): Delete.
400
401 2010-03-24 Pedro Alves <pedro@codesourcery.com>
402
403 * mem-break.c (enum bkpt_type): New.
404 (struct breakpoint): New field `type'.
405 (set_breakpoint_at): Change return type to struct breakpoint
406 pointer. Set type to `other_breakpoint' by default.
407 (delete_breakpoint): Rewrite, supporting more than one breakpoint
408 in the breakpoint list.
409 (delete_reinsert_breakpoints): Only delete reinsert breakpoints.
410 (reinsert_breakpoint): Rename to ...
411 (reinsert_raw_breakpoint): ... this.
412 (reinsert_breakpoints_at): Adjust.
413 * mem-break.h (struct breakpoint): Declare.
414 (set_breakpoint_at): Change return type to struct breakpoint
415 pointer.
416
417 2010-03-24 Pedro Alves <pedro@codesourcery.com>
418
419 * server.c (handle_query): Assign, not compare.
420
421 2010-03-24 Pedro Alves <pedro@codesourcery.com>
422
423 Teach linux gdbserver to step-over-breakpoints.
424
425 * linux-low.c (can_hardware_single_step): New.
426 (supports_breakpoints): New.
427 (handle_extended_wait): If stopping threads, read the stop pc of
428 the new cloned LWP.
429 (get_pc): New.
430 (get_stop_pc): Add `lwp' parameter. Handle it. Bail out if the
431 low target doesn't support retrieving the PC.
432 (add_lwp): Set last_resume_kind to resume_continue.
433 (linux_attach_lwp_1): Adjust comments. Always set stop_expected.
434 (linux_attach): Don't clear stop_expected. Set the lwp's
435 last_resume_kind to resume_stop.
436 (linux_detach_one_lwp): Don't check for removed breakpoints.
437 (check_removed_breakpoint): Delete.
438 (status_pending_p): Rename to ...
439 (status_pending_p_callback): ... this. Don't check for removed
440 breakpoints. Don't consider threads that are stopped from GDB's
441 perspective.
442 (linux_wait_for_lwp): Always read the stop_pc here.
443 (cancel_breakpoint): New.
444 (step_over_bkpt): New global.
445 (linux_wait_for_event_1): Implement stepping over breakpoints.
446 (gdb_wants_lwp_stopped): New.
447 (gdb_wants_all_stopped): New.
448 (linux_wait_1): Tag threads as gdb-wants-stopped. Cancel finished
449 single-step traps here. Store the thread's last reported target
450 wait status.
451 (send_sigstop): Don't clear stop_expected. Always set it,
452 instead.
453 (mark_lwp_dead): Remove reference to pending_is_breakpoint.
454 (cancel_finished_single_step): New.
455 (cancel_finished_single_steps): New.
456 (wait_for_sigstop): Don't cancel finished single-step traps here.
457 (linux_resume_one_lwp): Don't check for removed breakpoints.
458 Don't set `step' on non-hardware step archs.
459 (linux_set_resume_request): Ignore resume_stop requests if already
460 stopping or stopped. Set the lwp's last_resume_kind.
461 (resume_status_pending_p): Don't check for removed breakpoints.
462 (need_step_over_p): New.
463 (start_step_over): New.
464 (finish_step_over): New.
465 (linux_resume_one_thread): Always queue a sigstop for resume_stop
466 requests. Clear the thread's last reported target waitstatus.
467 Don't use the `suspended' flag. Don't consider pending breakpoints.
468 (linux_resume): Start a step-over if necessary.
469 (proceed_one_lwp): New.
470 (proceed_all_lwps): New.
471 (unstop_all_lwps): New.
472 * linux-low.h (struct lwp_info): Rewrite comment for the
473 `suspended' flag. Add the `stop_pc' field. Delete the
474 `pending_stop_pc' field. Tweak the `stepping' flag's comment.
475 Add `'last_resume_kind' and `need_step_over' fields.
476 * inferiors.c (struct thread_info): Delete, moved elsewhere.
477 * mem-break.c (struct breakpoint): Delete `reinserting' flag.
478 Delete `breakpoint_to_reinsert' field. New flag `inserted'.
479 (set_raw_breakpoint_at): New.
480 (set_breakpoint_at): Rewrite to use it.
481 (reinsert_breakpoint_handler): Delete.
482 (set_reinsert_breakpoint): New.
483 (reinsert_breakpoint_by_bp): Delete.
484 (delete_reinsert_breakpoints): New.
485 (uninsert_breakpoint): Rewrite.
486 (uninsert_breakpoints_at): New.
487 (reinsert_breakpoint): Rewrite.
488 (reinsert_breakpoints_at): New.
489 (check_breakpoints): Rewrite.
490 (breakpoint_here): New.
491 (breakpoint_inserted_here): New.
492 (check_mem_read): Adjust.
493 * mem-break.h (breakpoints_supported, breakpoint_here)
494 (breakpoint_inserted_here, set_reinsert_breakpoint): Declare.
495 (reinsert_breakpoint_by_bp): Delete declaration.
496 (delete_reinsert_breakpoints): Declare.
497 (reinsert_breakpoint): Delete declaration.
498 (reinsert_breakpoints_at): Declare.
499 (uninsert_breakpoint): Delete declaration.
500 (uninsert_breakpoints_at): Declare.
501 (check_breakpoints): Adjust prototype.
502 * server.h: Adjust include order.
503 (struct thread_info): Declare here. Add a `last_status' field.
504
505 2010-03-23 Michael Snyder <msnyder@vmware.com>
506
507 * server.c (crc32): New function.
508 (handle_query): Add handling for 'qCRC:' request.
509
510 2010-03-23 Pedro Alves <pedro@codesourcery.com>
511
512 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR6 if the
513 lwp had been stopped by a watchpoint.
514
515 2010-03-16 Pedro Alves <pedro@codesourcery.com>
516
517 * server.h (internal_error): Declare.
518 (gdb_assert, ASSERT_FUNCTION, gdb_assert_fail): Define.
519 * utils.c (internal_error): New function.
520
521 2010-03-15 Andreas Schwab <schwab@redhat.com>
522
523 * configure.srv: Fix typo setting srv_regobj.
524
525 2010-03-15 Pedro Alves <pedro@codesourcery.com>
526
527 * linux-low.c (fetch_register): Avoid passing a non string literal
528 format to `error'.
529 (usr_store_inferior_registers): Ditto.
530
531 2010-03-14 Pedro Alves <pedro@codesourcery.com>
532
533 * linux-low.c (linux_write_memory): Bail out early if peeking
534 memory failed.
535
536 2010-03-14 Pedro Alves <pedro@codesourcery.com>
537
538 * linux-low.h (struct lwp_info): New fields
539 `stopped_by_watchpoint' and `stopped_data_address'.
540 * linux-low.c (linux_wait_for_lwp): Check for watchpoint triggers
541 here, and cache them in the lwp object.
542 (wait_for_sigstop): Check stopped_by_watchpoint lwp field
543 directly.
544 (linux_resume_one_lwp): Clear the lwp's stopped_by_watchpoint
545 field.
546 (linux_stopped_by_watchpoint): Rewrite.
547 (linux_stopped_data_address): Rewrite.
548
549 2010-03-06 Simo Melenius <simo.melenius@iki.fi>
550
551 * linux-low.c (linux_wait_for_lwp): Fetch the regcache after
552 switching the current inferior, not before.
553
554 2010-03-01 H.J. Lu <hongjiu.lu@intel.com>
555
556 * Makefile.in (clean): Replace reg-i386.c, reg-x86-64.c,
557 reg-i386-linux.c and reg-x86-64-linux.c with i386.c, amd64.c,
558 i386-linux.c and amd64-linux.c.
559 (reg-i386.o): Removed.
560 (reg-i386.c): Likewise.
561 (reg-i386-linux.o): Likewise.
562 (reg-i386-linux.c): Likewise.
563 (reg-x86-64.o): Likewise.
564 (reg-x86-64.c): Likewise.
565 (reg-x86-64-linux.o): Likewise.
566 (reg-x86-64-linux.c): Likewise.
567 (i386.o): New.
568 (i386.c): Likewise.
569 (i386-linux.o): Likewise.
570 (i386-linux.c): Likewise.
571 (amd64.o): Likewise.
572 (amd64.c): Likewise.
573 (amd64-linux.o): Likewise.
574 (amd64-linux.c): Likewise.
575
576 * configure.srv (srv_i386_regobj): New.
577 (srv_i386_linux_regobj): Likewise.
578 (srv_amd64_regobj): Likewise.
579 (srv_amd64_linux_regobj): Likewise.
580 (srv_i386_32bit_xmlfiles): Likewise.
581 (srv_i386_64bit_xmlfiles): Likewise.
582 (srv_i386_xmlfiles): Likewise.
583 (srv_amd64_xmlfiles): Likewise.
584 (srv_i386_linux_xmlfiles): Likewise.
585 (srv_amd64_linux_xmlfiles): Likewise.
586 (i[34567]86-*-cygwin*): Set srv_regobj to $srv_i386_regobj. Set
587 srv_xmlfiles to $srv_i386_xmlfiles.
588 (i[34567]86-*-mingw32ce*): Likewise.
589 (i[34567]86-*-mingw*): Likewise.
590 (i[34567]86-*-nto*): Likewise.
591 (i[34567]86-*-linux*): Set srv_regobj to $srv_i386_linux_regobj
592 and $srv_amd64_linux_regobj. Set srv_xmlfiles to
593 $srv_i386_linux_xmlfiles and $srv_amd64_linux_xmlfiles.
594 (x86_64-*-linux*): Likewise.
595
596 * linux-x86-low.c (init_registers_x86_64_linux): Removed.
597 (init_registers_amd64_linux): New.
598 (x86_arch_setup): Replace init_registers_x86_64_linux with
599 init_registers_amd64_linux.
600
601 2010-02-23 Maxim Kuvyrkov <maxim@codesourcery.com>
602
603 * configure.ac: Check for libdl. If it is not available link against
604 static libthread_db.
605 * configure: Regenerate.
606
607 2010-02-22 Pedro Alves <pedro@codesourcery.com>
608
609 PR9605
610
611 * i386-low.c (i386_length_and_rw_bits): Throw a fatal error if
612 handing a read watchpoint.
613 (i386_low_insert_watchpoint): Read watchpoints aren't supported.
614
615 2010-02-12 Doug Evans <dje@google.com>
616
617 * linux-low.c (linux_supports_tracefork_flag): Document.
618 (linux_look_up_symbols): Add comment.
619
620 2010-02-03 H.J. Lu <hongjiu.lu@intel.com>
621
622 * regcache.c (supply_register): Clear regcache if buf is NULL.
623
624 2010-02-02 Nicolas Roche <roche@sourceware.org>
625 Joel Brobecker <brobecker@adacore.com>
626
627 * inferiors.c (find_inferior): Add function documentation.
628 (unloaded_dll): Handle the case where the unloaded dll has not
629 been previously registered in the dll list.
630
631 2010-02-01 Daniel Jacobowitz <dan@codesourcery.com>
632
633 * linux-arm-low.c (thumb_breakpoint_len): Delete.
634 (thumb2_breakpoint): New.
635 (arm_breakpoint_at): Check for Thumb-2 breakpoints.
636
637 2010-01-29 Daniel Jacobowitz <dan@codesourcery.com>
638
639 * linux-low.c (get_stop_pc): Check for SIGTRAP.
640 (linux_wait_for_event_1): Handle SIGILL and SIGSEGV as possible
641 breakpoints.
642
643 2010-01-21 Pedro Alves <pedro@codesourcery.com>
644
645 * linux-ppc-low.c (ppc_arch_setup): Adjust to regcache changes.
646
647 2010-01-21 Jan Kratochvil <jan.kratochvil@redhat.com>
648
649 * linux-s390-low.c (s390_collect_ptrace_register)
650 (s390_supply_ptrace_register): Adjust it for the new regcache parameter.
651
652 2010-01-21 Doug Evans <dje@google.com>
653
654 * linux-low.c (PTRACE_ARG3_TYPE): Change from long to void*.
655 (PTRACE_ARG4_TYPE): New macro.
656 (handle_extended_wait): Cast ptrace arg4 to PTRACE_ARG4_TYPE.
657 (linux_wait_for_event_1, linux_resume_one_lwp): Ditto.
658 (fetch_register): Cast to uintptr_t before casting to PTRACE_ARG3_TYPE.
659 (usr_store_inferior_registers): Ditto.
660 (linux_read_memory, linux_write_memory): Ditto.
661 (linux_test_for_tracefork): Ditto.
662
663 * linux-arm-low.c: Remove redundant include of gdb_proc_service.h.
664 Only include elf.h if gdb_proc_service.h didn't include linux/elf.h.
665
666 2010-01-21 Pedro Alves <pedro@codesourcery.com>
667
668 * proc-service.c (ps_lgetregs): Don't refetch registers from the
669 target.
670
671 2010-01-21 Pedro Alves <pedro@codesourcery.com>
672
673 * spu-low.c (spu_fetch_registers, spu_store_registers): Change
674 prototype to take a regcache. Adjust.
675
676 2010-01-20 Pedro Alves <pedro@codesourcery.com>
677
678 * regcache.h (struct thread_info): Forward declare.
679 (struct regcache): New.
680 (new_register_cache): Adjust prototype.
681 (get_thread_regcache): Declare.
682 (free_register_cache): Adjust prototype.
683 (registers_to_string, registers_from_string): Ditto.
684 (supply_register, supply_register_by_name, collect_register)
685 (collect_register_as_string, collect_register_by_name): Ditto.
686 * regcache.c (struct inferior_regcache_data): Delete.
687 (get_regcache): Rename to ...
688 (get_thread_regcache): ... this. Adjust. Switch inferior before
689 fetching registers.
690 (regcache_invalidate_one): Adjust.
691 (regcache_invalidate): Fix prototype.
692 (new_register_cache): Return the new register cache.
693 (free_register_cache): Change prototype.
694 (realloc_register_cache): Adjust.
695 (registers_to_string): Change prototype to take a regcache. Adjust.
696 (registers_from_string): Ditto.
697 (register_data): Ditto.
698 (supply_register): Ditto.
699 (supply_register_by_name): Ditto.
700 (collect_register): Ditto.
701 (collect_register_as_string): Ditto.
702 (collect_register_by_name): Ditto.
703 * server.c (process_serial_event): Adjust.
704 * linux-low.h (regset_fill_func, regset_store_func): Change
705 prototype.
706 (get_pc, set_pc, collect_ptrace_register, supply_ptrace_register):
707 Change prototype.
708 * linux-low.c (get_stop_pc): Adjust.
709 (check_removed_breakpoint): Adjust.
710 (linux_wait_for_event): Adjust.
711 (linux_resume_one_lwp): Adjust.
712 (fetch_register): Add regcache parameter. Adjust.
713 (usr_store_inferior_registers): Ditto.
714 (regsets_fetch_inferior_registers): Ditto.
715 (regsets_store_inferior_registers): Ditto.
716 (linux_fetch_registers, linux_store_registers): Ditto.
717 * i387-fp.c (i387_cache_to_fsave): Change prototype to take a
718 regcache. Adjust.
719 (i387_fsave_to_cache, i387_cache_to_fxsave, i387_fxsave_to_cache): Ditto.
720 * i387-fp.h (i387_cache_to_fsave, i387_fsave_to_cache): Change
721 prototype to take a regcache.
722 (i387_cache_to_fxsave, i387_fxsave_to_cache): Ditto.
723 * remote-utils.c (convert_ascii_to_int, outreg)
724 (prepare_resume_reply): Change prototype to take a regcache.
725 Adjust.
726 * target.h (struct target_ops) <fetch_registers, store_registers>:
727 Change prototype to take a regcache.
728 (fetch_inferior_registers, store_inferior_registers): Change
729 prototype to take a regcache. Adjust.
730 * proc-service.c (ps_lgetregs): Adjust.
731 * linux-x86-low.c (x86_fill_gregset, x86_store_gregset)
732 (x86_fill_fpregset, x86_store_fpregset, x86_fill_fpxregset)
733 (x86_store_fpxregset, x86_get_pc, x86_set_pc): Change prototype to
734 take a regcache. Adjust.
735 * linux-arm-low.c (arm_fill_gregset, arm_store_gregset)
736 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
737 (arm_store_vfpregset, arm_get_pc, arm_set_pc):
738 (arm_breakpoint_at): Change prototype to take a regcache. Adjust.
739 * linux-cris-low.c (cris_get_pc, cris_set_pc)
740 (cris_cannot_fetch_register):
741 (cris_breakpoint_at): Change prototype to take a regcache.
742 Adjust.
743 * linux-crisv32-low.c (cris_get_pc, cris_set_pc,
744 cris_reinsert_addr, cris_write_data_breakpoint): Change prototype
745 to take a regcache. Adjust.
746 (cris_breakpoint_at, cris_insert_point, cris_remove_point):
747 Adjust.
748 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Change prototype to
749 take a regcache. Adjust.
750 * linux-m68k-low.c (m68k_fill_gregset, m68k_store_gregset)
751 (m68k_fill_fpregset, m68k_store_fpregset, m68k_get_pc,
752 (m68k_set_pc): Change prototype to take a regcache. Adjust.
753 * linux-mips-low.c (mips_get_pc):
754 (mips_set_pc): Change prototype to take a regcache. Adjust.
755 (mips_reinsert_addr): Adjust.
756 (mips_collect_register): Change prototype to take a regcache.
757 Adjust.
758 (mips_supply_register):
759 (mips_collect_register_32bit, mips_supply_register_32bit)
760 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
761 (mips_store_fpregset): Ditto.
762 * linux-ppc-low.c (ppc_supply_ptrace_register, ppc_supply_ptrace_register):
763 Ditto.
764 (parse_spufs_run): Adjust.
765 (ppc_get_pc, ppc_set_pc, ppc_fill_gregset, ppc_fill_vsxregset)
766 (ppc_store_vsxregset, ppc_fill_vrregset, ppc_store_vrregset)
767 (ppc_fill_evrregset, ppc_store_evrregset): Change prototype to
768 take a regcache. Adjust.
769 * linux-s390-low.c (s390_collect_ptrace_register)
770 (s390_supply_ptrace_register, s390_fill_gregset, s390_get_pc)
771 (s390_set_pc): Change prototype to take a regcache. Adjust.
772 (s390_arch_setup): Adjust.
773 * linux-sh-low.c (sh_get_pc, sh_breakpoint_at)
774 (sh_fill_gregset): Change prototype to take a regcache. Adjust.
775 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
776 (sparc_fill_gregset, sparc_store_gregset_from_stack)
777 (sparc_store_gregset, sparc_get_pc): Change prototype to take a
778 regcache. Adjust.
779 (sparc_breakpoint_at): Adjust.
780 * linux-xtensa-low.c (xtensa_fill_gregset):
781 (xtensa_store_gregset):
782 (xtensa_fill_xtregset, xtensa_store_xtregset, xtensa_get_pc)
783 (xtensa_set_pc): Change prototype to take a regcache. Adjust.
784 * nto-low.c (nto_fetch_registers, nto_store_registers): Change
785 prototype to take a regcache. Adjust.
786 * win32-arm-low.c (arm_fetch_inferior_register)
787 (arm_store_inferior_register): Change prototype to take a
788 regcache. Adjust.
789 * win32-i386-low.c (i386_fetch_inferior_register)
790 (i386_store_inferior_register): Change prototype to take a
791 regcache. Adjust.
792 * win32-low.c (child_fetch_inferior_registers)
793 (child_store_inferior_registers): Change prototype to take a
794 regcache. Adjust.
795 (win32_wait): Adjust.
796 (win32_fetch_inferior_registers): Change prototype to take a
797 regcache. Adjust.
798 (win32_store_inferior_registers): Adjust.
799 * win32-low.h (struct win32_target_ops) <fetch_inferior_register,
800 store_inferior_register>: Change prototype to take a regcache.
801
802 2010-01-20 Doug Evans <dje@google.com>
803
804 * linux-low.c (linux_create_inferior): Wrap use of __SIGRTMIN in
805 #ifdef.
806 (linux_wait_for_event1, linux_init_signals): Ditto.
807 (W_STOPCODE): Provide definition if missing.
808
809 2010-01-13 Vladimir Prus <vladimir@codesourcery.com>
810
811 * linux-low.c (linux_core_of_thread): New.
812 (compare_ints, show_process, list_threads): New.
813 (linux_qxfer_osdata): Report threads and cores.
814 (linux_target_op): Register linux_core_of_thread.
815 * remote-utils.c (prepare_resume_reply): Report the core.
816 (buffer_xml_printf): Support %d specifier.
817 * server.c (handle_threads_qxfer_proper, handle_threads_qxfer):
818 New.
819 (handle_query): Handle qXfer:threads. Announce availability
820 thereof.
821 * target.h (struct target_ops): New field core_of_thread.
822
823 2010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
824
825 * Makefile.in (clean): Remove new generated files.
826 (reg-s390.o, reg-s390.c): Remove rules.
827 (reg-s390x.o, reg-s390x.c): Likewise.
828 (s390-linux32.o, s390-linux32.c): Add rules.
829 (s390-linux64.o, s390-linux64.c): Likewise.
830 (s390x-linux64.o, s390x-linux64.c): Likewise.
831 * configure.srv (s390*-*-linux*): Update srv_regobj and srv_xmlfiles.
832 * linux-s390-low.c: Include <elf.h>.
833 (HWCAP_S390_HIGH_GPRS): Define if undefined.
834 (init_registers_s390): Remove prototype.
835 (init_registers_s390x): Likewise.
836 (init_registers_s390_linux32): Add prototype.
837 (init_registers_s390_linux64): Likewise.
838 (init_registers_s390x_linux64): Likewise.
839 (s390_num_regs_3264): New define.
840 (s390_regmap_3264): New global variable.
841 (s390_cannot_fetch_register): Remove obsolete check.
842 (s390_cannot_store_register): Likewise.
843 (s390_collect_ptrace_register): Handle upper/lower register halves.
844 (s390_supply_ptrace_register): Likewise.
845 (s390_fill_gregset): Update to register number changes.
846 (s390_get_hwcap): New routine.
847 (s390_arch_setup): Detect 32-bit process running on 64-bit system.
848 Install appropriate regmap and register set.
849
850 2010-01-01 Joel Brobecker <brobecker@adacore.com>
851
852 * server.c (gdbserver_version): Update copyright year to 2010.
853 * gdbreplay.c (gdbreplay_version): Likewise.
854
855 2009-12-28 Doug Evans <dje@google.com>
856
857 * linux-low.c: Delete inclusion of ansidecl.h, elf/common.h,
858 elf/external.h. Include <elf.h> instead but only if necessary.
859
860 2009-12-28 Pedro Alves <pedro@codesourcery.com>
861
862 * linux-low.c (linux_remove_process): Remove `detaching'
863 parameter. Don't release/detach from thread_db here.
864 (linux_kill): Release/detach from thread_db here, ...
865 (linux_detach): ... and here, before actually detaching.
866 (linux_wait_1): ... and here, when a process exits.
867 * thread-db.c (any_thread_of): New.
868 (thread_db_free): Switch the current inferior to a thread of the
869 passed in process.
870
871 2009-12-21 Doug Evans <dje@google.com>
872
873 * linux-x86-low.c: Delete outdated comment about Elf32_Phdr.
874
875 * linux-low.c (kill_lwp): Use __NR_tkill instead of SYS_tkill.
876 Move definition of tkill_failed to ifdef __NR_tkill to avoid gcc
877 warning ifndef __NR_tkill. Move setting of errno there too.
878 Delete unnecessary resetting of errno after syscall.
879 Minor comment changes to match gdb/linux-nat.c:kill_lwp.
880
881 * configure.ac: Check for dladdr.
882 * config.in: Regenerate.
883 * configure: Regenerate.
884 * thread-db.c (dladdr_to_soname): Only define ifdef HAVE_DLADDR.
885 (try_thread_db_load): Update.
886
887 * linux-low.c (my_waitpid): Delete unnecessary prototype.
888
889 2009-12-18 Doug Evans <dje@google.com>
890
891 * event-loop.c: Include unistd.h if it exists.
892
893 * linux-low.c (my_waitpid): Move definition away from being in
894 between linux_tracefork_child/linux_test_for_tracefork.
895
896 * gdb_proc_service.h (psaddr_t): Fix type.
897 * thread-db.c (thread_db_info.td_thr_tls_get_addr_p): Fix
898 signature to match glibc.
899
900 2009-12-16 Doug Evans <dje@google.com>
901
902 * linux-low.c (linux_read_memory): Fix argument to read.
903
904 2009-11-26 Pedro Alves <pedro@codesourcery.com>
905
906 * win32-low.c (get_child_debug_event): On EXIT_THREAD_DEBUG_EVENT
907 events, don't leave current_inferior pointing at null.
908
909 2009-11-26 Pedro Alves <pedro@codesourcery.com>
910
911 * win32-low.c (LOG): Delete.
912 (OUTMSG): Output to stderr.
913 (OUTMSG2): Conditionalize on `debug_threads' variable, instead of
914 on compile time LOG macro.
915 (win32_wait): Fix debug output.
916
917 2009-11-26 Pedro Alves <pedro@codesourcery.com>
918
919 * win32-low.c (win32_add_one_solib): If the dll name is
920 "ntdll.dll", prepend the system directory to the dll path.
921
922 2009-11-17 Daniel Jacobowitz <dan@codesourcery.com>
923
924 * m68k-tdep.c (m68k_gdbarch_init): Reuse previous initialization.
925
926 2009-11-17 Nathan Sidwell <nathan@codesourcery.com>
927 Vladimir Prus <vladimir@codesourcery.com>
928
929 * Makefile.in (reg-cf.o, reg-cf.c): New targets.
930 * configure.ac: Check for __mcoldfire__ and set
931 gdb_cv_m68k_is_coldfire.
932 * configure.srv: Use gdb_cv_m68k_is_coldfire to select between
933 reg-cf.o and reg-m68k.o.
934 * configure: Regenerated.
935
936 2009-11-16 Pedro Alves <pedro@codesourcery.com>
937
938 * linux-low.c (linux_remove_process): Add `detaching' parameter.
939 Pass it to thread_db_free.
940 (linux_kill, linux_detach, linux_wait_1): Adjust to pass the
941 proper `detaching' argument to linux_remove_process.
942 * linux-low.h (thread_db_free): Add `detaching' parameter.
943 * thread-db.c (thread_db_init): Pass false as `detaching' argument
944 to thread_db_free.
945 (thread_db_free): Add `detaching' parameter. Only
946 call td_ta_clear_event if detaching from process.
947
948 2009-11-12 Maxim Kuvyrkov <maxim@codesourcery.com>
949
950 * thread-db.c (thread_db_free): Fix typo.
951
952 2009-11-11 Paul Pluzhnikov <ppluzhnikov@google.com>
953
954 PR gdb/10838
955 * thread-db.c (thread_db_free): Call td_ta_clear_event.
956
957 2009-11-03 Nathan Sidwell <nathan@codesourcery.com>
958
959 * configure.ac (i[34567]86-*): Check if we're targetting x86-64
960 with an i686 compiler.
961 * configure.srv (i[34567]86-*-linux*): Pull in x86-64 handling if
962 needed.
963 * configure: Rebuilt.
964
965 2009-10-29 Sandra Loosemore <sandra@codesourcery.com>
966
967 PR gdb/10783
968
969 * server.c (handle_search_memory_1): Correct read_addr initialization
970 in loop for searching subsequent chunks.
971
972 2009-10-29 Paul Pluzhnikov <ppluzhnikov@google.com>
973
974 * configure.ac: New --with-libthread-db option.
975 * thread-db.c: Allow direct dependence on libthread_db.
976 (thread_db_free): Adjust.
977 * config.in: Regenerate.
978 * configure: Likewise.
979
980 2009-10-28 Paul Pluzhnikov <ppluzhnikov@google.com>
981
982 PR gdb/10757
983 * thread-db.c (attach_thread): New function.
984 (maybe_attach_thread): Return success/failure.
985 (find_new_threads_callback): Adjust.
986 (thread_db_find_new_threads): Loop until no new threads.
987
988 2009-10-13 Pedro Alves <pedro@codesourcery.com>
989
990 * proc-service.c (ps_lgetregs): Formatting.
991
992 2009-10-08 Paul Pluzhnikov <ppluzhnikov@google.com>
993
994 * acinclude.m4: (SRV_CHECK_THREAD_DB, SRV_CHECK_TLS_GET_ADDR): Remove.
995 * configure.ac: Adjust.
996 * linux-low.h (struct process_info_private): Move members to struct
997 thread_db.
998 (thread_db_free, thread_db_handle_monitor_command): New prototype.
999 * linux-low.c (linux_remove_process): Adjust.
1000 (linux_wait_for_event_1, linux_look_up_symbols): Likewise.
1001 * server.c (handle_query): Move code ...
1002 (handle_monitor_command): ... here. New function.
1003 * target.h (struct target_ops): New member.
1004 * thread-db.c (struct thread_db): New.
1005 (libthread_db_search_path): New variable.
1006 (thread_db_create_event, thread_db_enable_reporting)
1007 (find_one_thread, maybe_attach_thread, find_new_threads_callback)
1008 (thread_db_find_new_threads, (thread_db_get_tls_address): Adjust.
1009 (try_thread_db_load_1, dladdr_to_soname): New functions.
1010 (try_thread_db_load, thread_db_load_search): New functions.
1011 (thread_db_init): Search for libthread_db.
1012 (thread_db_free): New function.
1013 (thread_db_handle_monitor_command): Likewise.
1014 * config.in: Regenerate.
1015 * configure: Regenerate.
1016
1017 2009-09-27 Ulrich Weigand <uweigand@de.ibm.com>
1018
1019 * spu-low.c (spu_kill): Wait for inferior to terminate.
1020 Call clear_inferiors.
1021 (spu_detach): Call clear_inferiors.
1022
1023 2009-08-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
1024
1025 * aclocal.m4: Regenerate.
1026 * config.in: Likewise.
1027 * configure: Likewise.
1028
1029 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
1030
1031 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Define.
1032 (parse_spufs_run): New function.
1033 (ppc_get_pc, ppc_set_pc): Detect and handle SPU PC.
1034 (ppc_breakpoint_at): Handle SPU breakpoints.
1035
1036 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
1037
1038 * linux-low.c: Include <sys/stat.h> and <sys/vfs.h>.
1039 (SPUFS_MAGIC): Define.
1040 (spu_enumerate_spu_ids): New function.
1041 (linux_qxfer_spu): New function.
1042 (linux_target_ops): Install linux_qxfer_spu.
1043
1044 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
1045
1046 * configure.srv (powerpc*-*-linux*): Add powerpc-cell32l.o
1047 and powerpc-cell64l.o to srv_regobj. Add rs6000/powerpc-cell32l.xml
1048 and rs6000/powerpc-cell64l.xml to srv_xmlfiles.
1049 * Makefile.in (powerpc-cell32l.o, powerpc-cell32l.c): New rules.
1050 (powerpc-cell64l.o, powerpc-cell64l.c): Likewise.
1051 (clean): Handle powerpc-cell32l.c and powerpc-cell64l.c.
1052 * linux-ppc-low.c (PPC_FEATURE_CELL): Define.
1053 (init_registers_powerpc_cell32l): Add prototype.
1054 (init_registers_powerpc_cell64l): Likewise.
1055 (ppc_arch_setup): Detect Cell/B.E. architecture.
1056
1057 2009-07-30 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
1058
1059 * Makefile.in (datarootdir): New variable.
1060
1061 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
1062
1063 * linux-low.c (linux_write_memory): Update debugging output.
1064 * Makefile.in (clean): Add new descriptions.
1065 (arm-with-vfpv2.o, arm-with-vfpv2.c, arm-with-vfpv3.o)
1066 (arm-with-vfpv3.c, arm-with-neon.o, arm-with-neon.c): New rules.
1067 * configure.srv: Add new files for arm*-*-linux*.
1068 * linux-arm-low.c: Add new declarations.
1069 (PTRACE_GETVFPREGS, PTRACE_SETVFPREGS): Define if undefined.
1070 (arm_hwcap, HWCAP_VFP, HWCAP_IWMMXT, HWCAP_NEON, HWCAP_VFPv3)
1071 (HWCAP_VFPv3D16): New.
1072 (arm_fill_wmmxregset, arm_store_wmmxregset): Check HWCAP_IWMMXT
1073 instead of __IWMMXT__.
1074 (arm_fill_vfpregset, arm_store_vfpregset, arm_get_hwcap)
1075 (arm_arch_setup): New.
1076 (target_regsets): Remove #ifdef. Add VFP regset.
1077 (the_low_target): Use arm_arch_setup.
1078
1079 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
1080
1081 * linux-low.c (linux_kill_one_lwp): Adjust kernel workaround to skip
1082 the main thread again.
1083
1084 2009-07-06 Aleksandar Ristovski <aristovski@qnx.com>
1085
1086 Adding Neutrino gdbserver.
1087 * configure: Regenerated.
1088 * configure.ac: Add case for srv_qnx and set LIBS accordingly.
1089 * configure.srv (i[34567]86-*-nto*): New target.
1090 * nto-low.c, nto-low.h, nto-x86-low.c: New files.
1091 * remote-utils.c [__QNX__]: Include sys/iomgr.h
1092 (nto_comctrl) [__QNX__]: New function.
1093 (enable_async_io, disable_async_io) [__QNX__]: Call nto_comctrl.
1094
1095 2009-07-05 Danny Backx <dannybackx@users.sourceforge.net>
1096
1097 * configure.srv (i[34567]86-*-mingw32ce*): Add i386-low.o to
1098 srv_tgtobj.
1099
1100 2009-07-04 Danny Backx <dannybackx@users.sourceforge.net>
1101 Pedro Alves <pedro@codesourcery.com>
1102
1103 * win32-i386-low.c (i386_get_thread_context): Handle systems that
1104 don't support CONTEXT_EXTENDED_REGISTERS.
1105 (i386_win32_breakpoint, i386_win32_breakpoint_len): New.
1106 (the_low_target): Install them.
1107 * win32-low.c (get_child_debug_event): Handle WaitForDebugEvent
1108 failing with ERROR_PIPE_NOT_CONNECTED.
1109
1110 2009-06-30 Doug Evans <dje@google.com>
1111 Pierre Muller <muller@ics.u-strasbg.fr>
1112
1113 Add h/w watchpoint support to x86-linux, win32-i386.
1114 * Makefile.in (SFILES): Add i386-low.c
1115 (i386_low_h): Define.
1116 (i386-low.o): Add dependencies.
1117 (linux-x86-low.o): Add i386-low.h dependency.
1118 (win32-i386-low.o): Ditto.
1119 * i386-low.c: New file.
1120 * i386-low.h: New file.
1121 * configure.srv (i[34567]86-*-cygwin*): Add i386-low.o to srv_tgtobj.
1122 (i[34567]86-*-linux*, i[34567]86-*-mingw*, x86_64-*-linux*): Ditto.
1123 * linux-low.c (linux_add_process): Initialize arch_private.
1124 (linux_remove_process): Free arch_private.
1125 (add_lwp): Initialize arch_private.
1126 (delete_lwp): Free arch_private.
1127 (linux_resume_one_lwp): Call the_low_target.prepare_to_resume if
1128 provided.
1129 * linux-low.h (process_info_private): New member arch_private.
1130 (lwp_info): New member arch_private.
1131 (linux_target_ops): New members new_process, new_thread,
1132 prepare_to_resume.
1133 (ptid_of): New macro.
1134 * linux-x86-low.c: Include stddef.h, i386-low.h.
1135 (arch_process_info): New struct.
1136 (arch_lwp_info): New struct.
1137 (x86_linux_dr_get, x86_linux_dr_set): New functions.
1138 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
1139 (i386_dr_low_get_status): New function.
1140 (x86_insert_point, x86_remove_point): New functions.
1141 (x86_stopped_by_watchpoint): New function.
1142 (x86_stopped_data_address): New function.
1143 (x86_linux_new_process, x86_linux_new_thread): New functions.
1144 (x86_linux_prepare_to_resume): New function.
1145 (the_low_target): Add entries for insert_point, remove_point,
1146 stopped_by_watchpoint, stopped_data_address, new_process, new_thread,
1147 prepare_to_resume.
1148 * server.c (debug_hw_points): New global.
1149 (monitor_show_help): Document set debug-hw-points.
1150 (handle_query): Process "set debug-hw-points".
1151 * server.h (debug_hw_points): Declare.
1152 (paddress): Declare.
1153 * utils.c (NUMCELLS, CELLSIZE): New macros.
1154 (get_sell, xsnprintf, paddress): New functions.
1155 * win32-arm-low.c (the_low_target): Add entries for insert_point,
1156 remove_point, stopped_by_watchpoint, stopped_data_address.
1157 * win32-i386-low.c: Include i386-low.h.
1158 (debug_reg_state): Replaces dr.
1159 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
1160 (i386_dr_low_get_status): New function.
1161 (i386_insert_point, i386_remove_point): New functions.
1162 (i386_stopped_by_watchpoint): New function.
1163 (i386_stopped_data_address): New function.
1164 (i386_initial_stuff): Update.
1165 (get_thread_context,set_thread_context,i386_thread_added): Update.
1166 (the_low_target): Add entries for insert_point,
1167 remove_point, stopped_by_watchpoint, stopped_data_address.
1168 * win32-low.c (win32_insert_watchpoint): New function.
1169 (win32_remove_watchpoint): New function.
1170 (win32_stopped_by_watchpoint): New function.
1171 (win32_stopped_data_address): New function.
1172 (win32_target_ops): Add entries for insert_watchpoint,
1173 remove_watchpoint, stopped_by_watchpoint, stopped_data_address.
1174 * win32-low.h (win32_target_ops): New members insert_point,
1175 remove_point, stopped_by_watchpoint, stopped_data_address.
1176
1177 2009-06-25 Pedro Alves <pedro@codesourcery.com>
1178
1179 * server.c (process_serial_event): Re-return unsupported, not
1180 error, if the type isn't recognized. Re-allow supporting only
1181 insert or remove packets. Also call require_running for
1182 breakpoints. Add missing break statement to default case. Tidy.
1183 * target.h (struct target_ops): Rename insert_watchpoint to
1184 insert_point, and remove_watchpoint to remove_point.
1185
1186 * linux-low.h (struct linux_target_ops): Likewise.
1187 * linux-low.c (linux_insert_watchpoint): Rename to ...
1188 (linux_insert_point): ... this. Adjust.
1189 (linux_remove_watchpoint): Rename to ...
1190 (linux_remove_point): ... this. Adjust.
1191 (linux_target_ops): Adjust.
1192 * linux-crisv32-low.c (cris_insert_watchpoint): Rename to ...
1193 (cris_insert_point): ... this.
1194 (cris_remove_watchpoint): Rename to ...
1195 (cris_remove_point): ... this.
1196 (the_low_target): Adjust.
1197
1198 2009-06-24 Pierre Muller <muller@ics.u-strasbg.fr>
1199
1200 * server.c (handle_v_kill): Pass signal_pid to
1201 kill_inferior if multi_process is zero.
1202
1203 2009-06-23 Aleksandar Ristovski <aristovski@qnx.com>
1204
1205 * server.c (process_serial_event): Add support for Z0 and Z1 packet.
1206 * target.h (target_ops): Comment for *_watchpoint to make it clear
1207 the functions can get types '0' and '1'.
1208
1209 2009-06-22 Aleksandar Ristovski <aristovski@qnx.com>
1210
1211 * linux-low.c (usr_fetch_inferior_registers): Remove check for regno 0.
1212 * proc-service.c (ps_lgetregs): Pass -1 to fetch all registers.
1213 * regcache.c (get_regcache): Likewise.
1214 * spu-low.c (spu_fetch_registers): Remove 0 to -1 conversion.
1215 * win32-low.c (child_fetch_inferior_registers): Remove check for
1216 regno 0.
1217
1218 2009-06-19 Aleksandar Ristovski <aristovski@qnx.com>
1219 Pedro Alves <pedro@codesourcery.com>
1220
1221 * target.h (struct target_ops) <supports_multi_process>: New
1222 callback.
1223 (target_supports_multi_process): New.
1224 * server.c (handle_query): Even if GDB reports support, only
1225 enable multi-process if the target also supports it. Report
1226 multi-process support only if the target backend supports it.
1227 * linux-low.c (linux_supports_multi_process): New function.
1228 (linux_target_ops): Install it as target_supports_multi_process
1229 callback.
1230
1231 2009-05-24 Doug Evans <dje@google.com>
1232
1233 Global renaming of find_thread_pid to find_thread_ptid.
1234 * server.h (find_thread_ptid): Renamed from find_thread_pid.
1235 * inferiors.c (find_thread_ptid): Renamed from find_thread_pid.
1236 All callers updated.
1237
1238 * linux-low.c (handle_extended_wait): Use linux_resume_one_lwp
1239 to resume the newly created thread, don't call ptrace (PTRACE_CONT)
1240 directly.
1241
1242 * linux-low.c (get_stop_pc): Print pc if debug_threads.
1243 (check_removed_breakpoint, linux_wait_for_lwp): Ditto.
1244 (linux_resume_one_lwp): Ditto.
1245
1246 2009-05-23 Doug Evans <dje@google.com>
1247
1248 * linux-low.c (linux_resume_one_lwp): Change type of first arg
1249 from struct inferior_list_entry * to struct lwp_info *.
1250 All callers updated.
1251
1252 2009-05-13 Doug Evans <dje@google.com>
1253
1254 * linux-x86-low.c: Don't include assert.h.
1255 (x86_siginfo_fixup): Use fatal, not assert.
1256 (x86_arch_setup): Fix comment.
1257
1258 2009-05-12 Doug Evans <dje@google.com>
1259
1260 Biarch support for i386/amd64 gdbserver.
1261 * Makefile.in (SFILES): Remove linux-i386-low.c, linux-x86-64-low.c.
1262 Add linux-x86-low.c.
1263 (linux-i386-low.o, linux-x86-64-low.o): Delete.
1264 (linux-x86-low.o): Add.
1265 * linux-x86-64-low.c: Delete.
1266 * linux-i386-low.c: Delete.
1267 * linux-x86-low.c: New file.
1268 * configure.srv (i?86-linux srv_tgtobj): Replace linux-i386-low.o with
1269 linux-x86-low.o.
1270 (x86_64-linux srv_tgtobj): Replace linux-x86-64-low.o with
1271 linux-x86-low.o.
1272 (x86_64-linux srv_regobj): Add reg-i386-linux.o.
1273 * linux-low.c: Include ansidecl.h, elf/common.h, elf/external.h.
1274 (linux_child_pid_to_exec_file): New function.
1275 (elf_64_header_p, elf_64_file_p): New functions.
1276 (siginfo_fixup): New function.
1277 (linux_xfer_siginfo): New local inf_siginfo. Call siginfo_fixup to
1278 give target a chance to convert layout.
1279 * linux-low.h (linux_target_ops): New member siginfo_fixup.
1280 (linux_child_pid_to_exec_file, elf_64_file_p): Declare.
1281
1282 2009-05-07 Doug Evans <dje@google.com>
1283
1284 * linux-low.c (regsets_fetch_inferior_registers): Fix memory leak.
1285 (regsets_store_inferior_registers): Ditto.
1286
1287 2009-05-06 Pedro Alves <pedro@codesourcery.com>
1288
1289 PR server/10048
1290
1291 * linux-low.c (must_set_ptrace_flags): Delete.
1292 (linux_create_inferior): Set `lwp->must_set_ptrace_flags' instead
1293 of the global.
1294 (linux_attach_lwp_1): Don't set PTRACE_SETOPTIONS here. Set
1295 `lwp->must_set_ptrace_flags' instead.
1296 (linux_wait_for_event_1): Set ptrace options here.
1297 (linux_wait_1): ... not here.
1298
1299 2009-04-30 Doug Evans <dje@google.com>
1300
1301 * inferiors.c (started_inferior_callback): New function.
1302 (attached_inferior_callback): New function.
1303 (have_started_inferiors_p, have_attached_inferiors_p): New functions.
1304 * server.c (print_started_pid, print_attached_pid): New functions.
1305 (detach_or_kill_for_exit): New function.
1306 (main): Call it instead of for_each_inferior (kill_inferior_callback).
1307 * server.h (have_started_inferiors_p): Declare.
1308 (have_attached_inferiors_p): Declare.
1309
1310 * inferiors.c (remove_process): Fix memory leak, free process.
1311 * linux-low.c (linux_remove_process): New function.
1312 (linux_kill): Call it instead of remove_process.
1313 (linux_detach, linux_wait_1): Ditto.
1314
1315 2009-04-19 Danny Backx <dannybackx@users.sourceforge.net>
1316
1317 * configure.srv: Add x86 Windows CE target.
1318
1319 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
1320
1321 * inferiors.c (get_thread_process): Make global.
1322 * server.h (get_thread_process): Add prototype.
1323 * thread-db.c (find_one_thread): Use get_thread_process
1324 instead of current_process.
1325 (thread_db_get_tls_address): Do not crash if called when
1326 thread layer is not yet initialized.
1327
1328 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
1329
1330 * remote-utils.c (prepare_resume_reply): Null-terminate packet.
1331 * spu-low.c (current_tid): Rename to ...
1332 (current_ptid): ... this.
1333 (fetch_ppc_register, fetch_ppc_memory, store_ppc_memory,
1334 spu_proc_xfer_spu, spu_resume, spu_request_interrupt): Use
1335 ptid_get_lwp (current_ptid) instead of current_tid.
1336 (spu_kill, spu_detach, spu_join, spu_wait): Use pid argument
1337 instead of current_tid. Use find_process_pid to verify pid
1338 argument is valid. Pass proper argument to remove_process.
1339 (spu_thread_alive): Compare current_ptid instead of current_tid.
1340 (spu_resume): Likewise.
1341
1342 2009-04-02 Pedro Alves <pedro@codesourcery.com>
1343
1344 * linux-low.c (usr_store_inferior_registers): Declare local `pid'
1345 variable.
1346
1347 2009-04-01 Pedro Alves <pedro@codesourcery.com>
1348
1349 Implement the multiprocess extensions, and add linux multiprocess
1350 support.
1351
1352 * server.h (ULONGEST): Declare.
1353 (struct ptid, ptid_t): New.
1354 (minus_one_ptid, null_ptid): Declare.
1355 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
1356 (ptid_get_tid, ptid_equal, ptid_is_pid): Declare.
1357 (struct inferior_list_entry): Change `id' type from unsigned from
1358 to ptid_t.
1359 (struct sym_cache, struct breakpoint, struct
1360 process_info_private): Forward declare.
1361 (struct process_info): Declare.
1362 (current_process): Declare.
1363 (all_processes): Declare.
1364 (initialize_inferiors): Declare.
1365 (add_thread): Adjust to use ptid_t.
1366 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): Ditto.
1367 (add_process, remove_process, find_thread_pid): Declare.
1368 (find_inferior_id): Adjust to use ptid_t.
1369 (cont_thread, general_thread, step_thread): Change type to ptid_t.
1370 (multi_process): Declare.
1371 (push_event): Adjust to use ptid_t.
1372 (read_ptid, write_ptid): Declare.
1373 (prepare_resume_reply): Adjust to use ptid_t.
1374 (clear_symbol_cache): Declare.
1375 * inferiors.c (all_processes): New.
1376 (null_ptid, minus_one_ptid): New.
1377 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
1378 (ptid_get_tid, ptid_equal, ptid_is_pid): New.
1379 (add_thread): Change unsigned long to ptid. Remove gdb_id
1380 parameter. Adjust.
1381 (thread_id_to_gdb_id, thread_to_gdb_id): Change unsigned long to ptid.
1382 (gdb_id_to_thread): Rename to ...
1383 (find_thread_pid): ... this. Change unsigned long to ptid.
1384 (gdb_id_to_thread_id, find_inferior_id): Change unsigned long to ptid.
1385 (loaded_dll, pull_pid_from_list): Adjust.
1386 (add_process, remove_process, find_process_pid)
1387 (get_thread_process, current_process, initialize_inferiors): New.
1388 * target.h (struct thread_resume) <thread>: Change type to ptid_t.
1389 (struct target_waitstatus) <related_pid>: Ditto.
1390 (struct target_ops) <kill, detach>: Add `pid' argument. Change
1391 return type to int.
1392 (struct target_ops) <join>: Add `pid' argument.
1393 (struct target_ops) <thread_alive>: Change pid's type to ptid_t.
1394 (struct target_ops) <wait>: Add `ptid' field. Change return type
1395 to ptid.
1396 (kill_inferior, detach_inferior, join_inferior): Add `pid' argument.
1397 (mywait): Add `ptid' argument. Change return type to ptid_t.
1398 (target_pid_to_str): Declare.
1399 * target.c (set_desired_inferior): Adjust to use ptids.
1400 (mywait): Add new `ptid' argument. Adjust.
1401 (target_pid_to_str): New.
1402 * mem-break.h (free_all_breakpoints): Declare.
1403 * mem-break.c (breakpoints): Delelete.
1404 (set_breakpoint_at, delete_breakpoint, find_breakpoint_at)
1405 (check_mem_read, check_mem_write, delete_all_breakpoints): Adjust
1406 to use per-process breakpoint list.
1407 (free_all_breakpoints): New.
1408 * remote-utils.c (struct sym_cache) <name>: Drop `const'.
1409 (symbol_cache, all_symbols_looked_up): Delete.
1410 (hexchars): New.
1411 (ishex, unpack_varlen_hex, write_ptid, hex_or_minus_one,
1412 read_ptid): New.
1413 (prepare_resume_reply): Change ptid argument's type from unsigned
1414 long to ptid_t. Adjust. Implement W;process and X;process.
1415 (free_sym_cache, clear_symbol_cache): New.
1416 (look_up_one_symbol): Adjust to per-process symbol cache. *
1417 * server.c (cont_thread, general_thread, step_thread): Change type
1418 to ptid_t.
1419 (attached): Delete.
1420 (multi_process): New.
1421 (last_ptid): Change type to ptid_t.
1422 (struct vstop_notif) <ptid>: Change type to ptid_t.
1423 (queue_stop_reply, push_event): Change `ptid' argument's type to
1424 ptid_t.
1425 (discard_queued_stop_replies): Add `pid' argument.
1426 (start_inferior): Adjust to use ptids. Adjust to mywait interface
1427 changes. Don't reference the `attached' global.
1428 (attach_inferior): Adjust to mywait interface changes.
1429 (handle_query): Adjust to use ptids. Parse GDB's qSupported
1430 features. Handle and report "multiprocess+". Handle
1431 "qAttached:PID".
1432 (handle_v_cont): Adjust to use ptids. Adjust to mywait interface
1433 changes.
1434 (handle_v_kill): New.
1435 (handle_v_stopped): Adjust to use target_pid_to_str.
1436 (handle_v_requests): Allow multiple attaches and runs when
1437 multiprocess extensions are in effect. Handle "vKill".
1438 (myresume): Adjust to use ptids.
1439 (queue_stop_reply_callback): Add `arg' parameter. Handle it.
1440 (handle_status): Adjust to discard_queued_stop_replies interface
1441 change.
1442 (first_thread_of, kill_inferior_callback)
1443 (detach_or_kill_inferior_callback, join_inferiors_callback): New.
1444 (main): Call initialize_inferiors. Adjust to use ptids, killing
1445 and detaching from all inferiors. Handle multiprocess packet
1446 variants.
1447 * linux-low.h: Include gdb_proc_service.h.
1448 (struct process_info_private): New.
1449 (struct linux_target_ops) <pid_of>: Use ptid_get_pid.
1450 <lwpid_of>: Use ptid_get_lwp.
1451 (get_lwp_thread): Adjust.
1452 (struct lwp_info): Add `dead' member.
1453 (find_lwp_pid): Declare.
1454 * linux-low.c (thread_db_active): Delete.
1455 (new_inferior): Adjust comment.
1456 (inferior_pid): Delete.
1457 (linux_add_process): New.
1458 (handle_extended_wait): Adjust.
1459 (add_lwp): Change unsigned long to ptid.
1460 (linux_create_inferior): Add process to processes table. Adjust
1461 to use ptids. Don't set new_inferior here.
1462 (linux_attach_lwp): Rename to ...
1463 (linux_attach_lwp_1): ... this. Add `initial' argument. Handle
1464 it. Adjust to use ptids.
1465 (linux_attach_lwp): New.
1466 (linux_attach): Add process to processes table. Don't set
1467 new_inferior here.
1468 (struct counter): New.
1469 (second_thread_of_pid_p, last_thread_of_process_p): New.
1470 (linux_kill_one_lwp): Add `args' parameter. Handle it. Adjust to
1471 multiple processes.
1472 (linux_kill): Add `pid' argument. Handle it. Adjust to multiple
1473 processes. Remove process from process table.
1474 (linux_detach_one_lwp): Add `args' parameter. Handle it. Adjust
1475 to multiple processes.
1476 (any_thread_of): New.
1477 (linux_detach): Add `pid' argument, and handle it. Remove process
1478 from processes table.
1479 (linux_join): Add `pid' argument. Handle it.
1480 (linux_thread_alive): Change unsighed long argument to ptid_t.
1481 Consider dead lwps as not being alive.
1482 (status_pending_p): Rename `dummy' argument to `arg'. Filter out
1483 threads we're not interested in.
1484 (same_lwp, find_lwp_pid): New.
1485 (linux_wait_for_lwp): Change `pid' argument's type from int to
1486 ptid_t. Adjust.
1487 (linux_wait_for_event): Rename to ...
1488 (linux_wait_for_event_1): ... this. Change `pid' argument's type
1489 from int to ptid_t. Adjust.
1490 (linux_wait_for_event): New.
1491 (linux_wait_1): Add `ptid' argument. Change return type to
1492 ptid_t. Adjust. Use last_thread_of_process_p. Remove processes
1493 that exit from the process table.
1494 (linux_wait): Add `ptid' argument. Change return type to ptid_t.
1495 Adjust.
1496 (mark_lwp_dead): New.
1497 (wait_for_sigstop): Adjust to use ptids. If a process exits while
1498 stopping all threads, mark its main lwp as dead.
1499 (linux_set_resume_request, linux_resume_one_thread): Adjust to use
1500 ptids.
1501 (fetch_register, usr_store_inferior_registers)
1502 (regsets_fetch_inferior_registers)
1503 (regsets_store_inferior_registers, linux_read_memory)
1504 (linux_write_memory): Inline `inferior_pid'.
1505 (linux_look_up_symbols): Adjust to use per-process
1506 `thread_db_active'.
1507 (linux_request_interrupt): Adjust to use ptids.
1508 (linux_read_auxv): Inline `inferior_pid'.
1509 (initialize_low): Don't reference thread_db_active.
1510 * gdb_proc_service.h (struct ps_prochandle) <pid>: Remove.
1511 * proc-service.c (ps_lgetregs): Use find_lwp_pid.
1512 (ps_getpid): Return the pid of the current inferior.
1513 * thread-db.c (proc_handle, thread_agent): Delete.
1514 (thread_db_create_event, thread_db_enable_reporting): Adjust to
1515 per-process data.
1516 (find_one_thread): Change argument type to ptid_t. Adjust to
1517 per-process data.
1518 (maybe_attach_thread): Adjust to per-process data and ptids.
1519 (thread_db_find_new_threads): Ditto.
1520 (thread_db_init): Ditto.
1521 * spu-low.c (spu_create_inferior, spu_attach): Add process to
1522 processes table. Adjust to use ptids.
1523 (spu_kill, spu_detach): Adjust interface. Remove process from
1524 processes table.
1525 (spu_join, spu_thread_alive): Adjust interface.
1526 (spu_wait): Adjust interface. Remove process from processes
1527 table. Adjust to use ptids.
1528 * win32-low.c (current_inferior_tid): Delete.
1529 (current_inferior_ptid): New.
1530 (debug_event_ptid): New.
1531 (thread_rec): Take a ptid. Adjust.
1532 (child_add_thread): Add `pid' argument. Adjust to use ptids.
1533 (child_delete_thread): Ditto.
1534 (do_initial_child_stuff): Add `attached' argument. Add process to
1535 processes table.
1536 (child_fetch_inferior_registers, child_store_inferior_registers):
1537 Adjust.
1538 (win32_create_inferior): Pass 0 to do_initial_child_stuff.
1539 (win32_attach): Pass 1 to do_initial_child_stuff.
1540 (win32_kill): Adjust interface. Remove process from processes
1541 table.
1542 (win32_detach): Ditto.
1543 (win32_join): Adjust interface.
1544 (win32_thread_alive): Take a ptid.
1545 (win32_resume): Adjust to use ptids.
1546 (get_child_debug_event): Ditto.
1547 (win32_wait): Adjust interface. Remove exiting process from
1548 processes table.
1549
1550 2009-04-01 Pedro Alves <pedro@codesourcery.com>
1551
1552 Non-stop mode support.
1553
1554 * server.h (non_stop): Declare.
1555 (gdb_client_data, handler_func): Declare.
1556 (delete_file_handler, add_file_handler, start_event_loop):
1557 Declare.
1558 (handle_serial_event, handle_target_event, push_event)
1559 (putpkt_notif): Declare.
1560 * target.h (enum resume_kind): New.
1561 (struct thread_resume): Replace `step' field by `kind' field.
1562 (TARGET_WNOHANG): Define.
1563 (struct target_ops) <wait>: Add `options' argument.
1564 <supports_non_stop, async, start_non_stop>: New fields.
1565 (target_supports_non_stop, target_async): New.
1566 (start_non_stop): Declare.
1567 (mywait): Add `options' argument.
1568 * target.c (mywait): Add `options' argument. Print child exit
1569 notifications here.
1570 (start_non_stop): New.
1571 * server.c (non_stop, own_buf, mem_buf): New globals.
1572 (struct vstop_notif): New.
1573 (notif_queue): New global.
1574 (queue_stop_reply, push_event, discard_queued_stop_replies)
1575 (send_next_stop_reply): New.
1576 (start_inferior): Adjust to use resume_kind. Adjust to mywait
1577 interface changes.
1578 (attach_inferior): In non-stop mode, don't wait for the target
1579 here.
1580 (handle_general_set): Handle QNonStop.
1581 (handle_query): When handling qC, return the current general
1582 thread, instead of the first thread of the list.
1583 (handle_query): If the backend supports non-stop mode, include
1584 QNonStop+ in the qSupported query response.
1585 (handle_v_cont): Adjust to use resume_kind. Handle resume_stop
1586 and non-stop mode.
1587 (handle_v_attach, handle_v_run): Handle non-stop mode.
1588 (handle_v_stopped): New.
1589 (handle_v_requests): Report support for vCont;t. Handle vStopped.
1590 (myresume): Adjust to use resume_kind. Handle non-stop.
1591 (queue_stop_reply_callback): New.
1592 (handle_status): Handle non-stop mode.
1593 (main): Clear non_stop flag on reconnection. Use the event-loop.
1594 Refactor serial protocol handling from here ...
1595 (process_serial_event): ... to this new function. When GDB
1596 selects any thread, select one here. In non-stop mode, wait until
1597 GDB acks all pending events before exiting.
1598 (handle_serial_event, handle_target_event): New.
1599 * remote-utils.c (remote_open): Install remote_desc in the event
1600 loop.
1601 (remote_close): Remove remote_desc from the event loop.
1602 (putpkt_binary): Rename to...
1603 (putpkt_binary_1): ... this. Add `is_notic' argument. Handle it.
1604 (putpkt_binary): New as wrapper around putpkt_binary_1.
1605 (putpkt_notif): New.
1606 (prepare_resume_reply): In non-stop mode, don't change the
1607 general_thread.
1608 * event-loop.c: New.
1609 * Makefile.in (OBJ): Add event-loop.o.
1610 (event-loop.o): New rule.
1611
1612 * linux-low.h (pid_of): Moved here.
1613 (lwpid_of): New.
1614 (get_lwp_thread): Use lwpid_of.
1615 (struct lwp_info): Delete `lwpid' field. Add `suspended' field.
1616 * linux-low.c (pid_of): Delete.
1617 (inferior_pid): Use lwpid_of.
1618 (linux_event_pipe): New.
1619 (target_is_async_p): New.
1620 (delete_lwp): New.
1621 (handle_extended_wait): Use lwpid_of.
1622 (add_lwp): Don't set lwpid field.
1623 (linux_attach_lwp): Adjust debug output. Use lwpid_of.
1624 (linux_kill_one_lwp): If killing a running lwp, stop it first.
1625 Use lwpid_of. Adjust to linux_wait_for_event interface changes.
1626 (linux_detach_one_lwp): If detaching from a running lwp, stop it
1627 first. Adjust to linux_wait_for_event interface changes. Use
1628 lwpid_of.
1629 (linux_detach): Don't delete the main lwp here.
1630 (linux_join): Use my_waitpid. Avoid signal_pid. Use lwpid_of.
1631 (status_pending_p): Don't consider explicitly suspended lwps.
1632 (linux_wait_for_lwp): Take an integer pid instead of a lwp_info
1633 pointer. Add OPTIONS argument. Change return type to int. Use
1634 my_waitpid instead of sleeping. Handle WNOHANG. Use lwpid_of.
1635 (linux_wait_for_event): Take an integer pid instead of a lwp_info
1636 pointer. Add status pointer argument. Return a pid instead of a
1637 status. Use lwpid_of. Adjust to linux_wait_for_lwp interface
1638 changes. In non-stop mode, don't switch to a random thread.
1639 (linux_wait): Rename to...
1640 (linux_wait_1): ... this. Add target_options argument, and handle
1641 it. Adjust to use resume_kind. Use lwpid_of. In non-stop mode,
1642 don't handle the continue thread. Handle TARGET_WNOHANG. Merge
1643 clean exit and signal exit code. Don't stop all threads in
1644 non-stop mode. In all-stop mode, only stop all threads when
1645 reporting a stop to GDB. Handle explicit thread stop requests.
1646 (async_file_flush, async_file_mark): New.
1647 (linux_wait): New.
1648 (send_sigstop): Use lwpid_of.
1649 (wait_for_sigstop): Use lwpid_of. Adjust to linux_wait_for_event
1650 interface changes. In non-stop mode, don't switch to a random
1651 thread.
1652 (linux_resume_one_lwp): Use lwpid_of.
1653 (linux_continue_one_thread, linux_queue_one_thread): Merge into ...
1654 (linux_resume_one_thread): ... this. Handle resume_stop. In
1655 non-stop mode, don't look for pending flag in all threads.
1656 (resume_status_pending_p): Don't consider explicitly suspended
1657 threads.
1658 (my_waitpid): Reimplement. Emulate __WALL.
1659 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
1660 Use lwpid_of.
1661 (sigchld_handler, linux_supports_non_stop, linux_async)
1662 (linux_start_non_stop): New.
1663 (linux_target_ops): Register linux_supports_non_stop, linux_async
1664 and linux_start_non_stop.
1665 (initialize_low): Install SIGCHLD handler.
1666 * thread-db.c (thread_db_create_event, find_one_thread)
1667 (thread_db_get_tls_address): Use lwpid_of.
1668 * win32-low.c (win32_detach): Adjust to use resume_kind.
1669 (win32_wait): Add `options' argument.
1670 * spu-low.c (spu_resume): Adjust to use resume_kind.
1671 (spu_wait): Add `options' argument.
1672
1673 2009-04-01 Pedro Alves <pedro@codesourcery.com>
1674
1675 Decouple target code from remote protocol.
1676
1677 * target.h (enum target_waitkind): New.
1678 (struct target_waitstatus): New.
1679 (struct target_ops) <wait>: Return an unsigned long. Take a
1680 target_waitstatus pointer instead of a char pointer.
1681 (mywait): Likewise.
1682 * target.c (mywait): Change prototype to return an unsigned long.
1683 Take a target_waitstatus pointer instead of a char pointer. Adjust.
1684 * server.h (thread_from_wait, old_thread_from_wait): Delete
1685 declarations.
1686 (prepare_resume_reply): Change prototype to take a
1687 target_waitstatus.
1688 * server.c (thread_from_wait, old_thread_from_wait): Delete.
1689 (last_status, last_ptid): New.
1690 (start_inferior): Remove "statusptr" argument. Adjust. Return a
1691 pid instead of a signal.
1692 (attach_inferior): Remove "status" and "signal" parameters.
1693 Adjust.
1694 (handle_query): For qGetTLSAddr, parse the thread id with strtol,
1695 not as an address.
1696 (handle_v_cont, handle_v_attach, handle_v_run, handle_v_kill)
1697 (handle_v_requests, myresume): Remove "status" and "signal"
1698 parameters. Adjust.
1699 (handle_status): New.
1700 (main): Delete local `status'. Adjust.
1701 * remote-utils.c: Include target.h.
1702 (prepare_resume_reply): Change prototype to take a
1703 target_waitstatus. Adjust.
1704
1705 * linux-low.c (linux_wait): Adjust to new target_ops->wait
1706 interface.
1707 * spu-low.c (spu_wait): Adjust.
1708 * win32-low.c (enum target_waitkind, struct target_waitstatus):
1709 Delete.
1710 (win32_wait): Adjust.
1711
1712 2009-04-01 Pedro Alves <pedro@codesourcery.com>
1713
1714 * target.h (struct thread_resume): Delete leave_stopped member.
1715 (struct target_ops): Add a `n' argument to the `resume' callback.
1716 * server.c (start_inferior): Adjust.
1717 (handle_v_cont, myresume): Adjust.
1718 * linux-low.c (check_removed_breakpoint): Adjust to resume
1719 interface change, and to removed leave_stopped field.
1720 (resume_ptr): Delete.
1721 (struct thread_resume_array): New.
1722 (linux_set_resume_request): Add new `arg' parameter. Adjust to
1723 resume interface change.
1724 (linux_continue_one_thread, linux_queue_one_thread)
1725 (resume_status_pending_p): Check if the resume field is NULL
1726 instead of checking the leave_stopped member.
1727 (linux_resume): Adjust to the target resume interface change.
1728 * spu-low.c (spu_resume): Adjust to the target resume interface
1729 change.
1730 * win32-low.c (win32_detach, win32_resume): Ditto.
1731
1732 2009-04-01 Pedro Alves <pedro@codesourcery.com>
1733
1734 * linux-low.c (linux_wait_for_event): Don't clear the `stepping'
1735 flag.
1736 (wait_for_sigstop): Don't leave a finished single-step SIGTRAP
1737 pending.
1738 (linux_continue_one_thread): Only preserve the stepping flag if
1739 there's a pending breakpoint.
1740
1741 2009-03-31 Pedro Alves <pedro@codesourcery.com>
1742
1743 * server.c (main): After the inferior having exited, call
1744 remote_close before exiting gdbserver.
1745
1746 2009-03-25 Thiago Jung Bauermann <bauerman@br.ibm.com>
1747
1748 Fix size of FPSCR in Power 7 processors.
1749 * linux-ppc-low.c (PPC_FEATURE_ARCH_2_05): Remove #define.
1750 (PPC_FEATURE_HAS_DFP): New #define.
1751 (ppc_arch_setup): Check for DFP feature instead of ISA 2.05 to decide on
1752 size of the FPSCR.
1753
1754 2009-03-23 Pedro Alves <pedro@codesourcery.com>
1755
1756 * server.c (handle_query) Whitespace and formatting.
1757
1758 2009-03-22 Pedro Alves <pedro@codesourcery.com>
1759
1760 * i387-fp.c, linux-arm-low.c, linux-cris-low.c,
1761 linux-crisv32-low.c, linux-i386-low.c, linux-low.c,
1762 linux-mips-low.c, linux-s390-low.c, linux-sparc-low.c,
1763 linux-x86-64-low.c, linux-xtensa-low.c, proc-service.c,
1764 regcache.c, remote-utils.c, server.c, spu-low.c, target.h,
1765 thread-db.c, win32-low.c, xtensa-xtregs.c, gdbreplay.c,
1766 Makefile.in, configure.ac: Fix whitespace throughout.
1767 * configure: Regenerate.
1768
1769 2009-03-22 Pedro Alves <pedro@codesourcery.com>
1770
1771 * inferiors.c (find_inferior): Make it safe for the callback
1772 function to delete the currently iterated inferior.
1773
1774 2009-03-22 Pedro Alves <pedro@codesourcery.com>
1775
1776 * Makefile.in (linuw_low_h): Move higher.
1777 (thread-db.o): Depend on $(linux_low_h).
1778
1779 2009-03-17 Pedro Alves <pedro@codesourcery.com>
1780
1781 Rename "process" to "lwp" throughout.
1782
1783 * linux-low.c (all_processes): Rename to...
1784 (all_lwps): ... this.
1785 (inferior_pid, handle_extended_wait, get_stop_pc): Adjust.
1786 (add_process): Rename to ...
1787 (add_lwp): ... this. Adjust.
1788 (linux_create_inferior): Adjust.
1789 (linux_attach_lwp): Adjust.
1790 (linux_attach): Adjust.
1791 (linux_kill_one_process): Rename to ...
1792 (linux_kill_one_lwp): ... this. Adjust.
1793 (linux_kill): Adjust.
1794 (linux_detach_one_process): Rename to ...
1795 (linux_detach_one_lwp): ... this. Adjust.
1796 (linux_detach): Adjust.
1797 (check_removed_breakpoint): Adjust.
1798 (status_pending_p): Adjust.
1799 (linux_wait_for_process): Rename to ...
1800 (linux_wait_for_lwp): ... this. Adjust.
1801 (linux_wait_for_event): Adjust.
1802 (send_sigstop): Adjust.
1803 (wait_for_sigstop): Adjust.
1804 (stop_all_processes): Rename to ...
1805 (stop_all_lwps): ... this.
1806 (linux_resume_one_process): Rename to ...
1807 (linux_resume_one_lwp): ... this. Adjust.
1808 (linux_set_resume_request, linux_continue_one_thread)
1809 (linux_queue_one_thread, resume_status_pending_p)
1810 (usr_store_inferior_registers, regsets_store_inferior_registers)
1811 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
1812 Adjust.
1813 * linux-low.h (get_process): Rename to ...
1814 (get_lwp): ... this. Adjust.
1815 (get_thread_process): Rename to ...
1816 (get_thread_lwp): ... this. Adjust.
1817 (get_process_thread): Rename to ...
1818 (get_lwp_thread): ... this. Adjust.
1819 (struct process_info): Rename to ...
1820 (struct lwp_info): ... this.
1821 (all_processes): Rename to ...
1822 (all_lwps): ... this.
1823 * proc-service.c (ps_lgetregs): Adjust.
1824 * thread-db.c (thread_db_create_event, find_one_thread)
1825 (maybe_attach_thread, thread_db_get_tls_address): Adjust.
1826
1827 2009-03-14 Pedro Alves <pedro@codesourcery.com>
1828
1829 * server.c (handle_query): Handle "qAttached".
1830
1831 2009-03-13 Nathan Sidwell <nathan@codesourcery.com>
1832
1833 * Makefile.in, hostio-errno.c, errno.c, xtensa-xtregs.c: Change to
1834 GPLv3, update license URL.
1835
1836 2009-03-01 Doug Evans <dje@google.com>
1837
1838 * Makefile.in (INCLUDE_CFLAGS): Add -I$(srcdir)/../common.
1839 (server_h): Add gdb_signals.h.
1840 (signals.o): Update.
1841 * server.h (target_signal_from_host,target_signal_to_host_p)
1842 (target_signal_to_host,target_signal_to_name): Moved to gdb_signals.h.
1843
1844 2009-02-14 Pierre Muller <muller@ics.u-strasbg.fr>
1845
1846 * remote-utils.c (getpkt): Also generate remote-debug
1847 information if noack_mode is set.
1848
1849 2009-02-06 Pedro Alves <pedro@codesourcery.com>
1850
1851 * server.c (handle_query): Report qXfer:siginfo:read and
1852 qXfer:siginfo:write as supported and handle them.
1853 * target.h (struct target_ops) <qxfer_siginfo>: New field.
1854 * linux-low.c (linux_xfer_siginfo): New.
1855 (linux_target_ops): Set it.
1856
1857 2009-01-26 Pedro Alves <pedro@codesourcery.com>
1858
1859 * server.c (gdbserver_usage): Mention --remote-debug.
1860 (main): Accept '--remote-debug' switch.
1861
1862 2009-01-18 Doug Evans <dje@google.com>
1863
1864 * regcache.c (new_register_cache): No need to check result of xcalloc.
1865 * server.c (handle_search_memory): Back out calls to xmalloc,
1866 result is checked and error is returned to user upon failure.
1867 (handle_query): Ditto. Add more checks for result of malloc.
1868 (handle_v_cont): Check result of malloc, report error back to
1869 user upon failure.
1870 (handle_v_run): Ditto. Call freeargv.
1871 * server.h (freeargv): Declare.
1872 * utils.c (freeargv): New fn.
1873
1874 2009-01-15 Doug Evans <dje@google.com>
1875
1876 * gdbreplay.c (perror_with_name): Make arg const char *.
1877 * server.h (target_signal_to_name): Make return type const char *.
1878 * thread-db.c (thread_db_err_str): Make return type const char *.
1879 * utils.c (perror_with_name): Make arg const char *.
1880
1881 2009-01-14 Pedro Alves <pedro@codesourcery.com>
1882
1883 * win32-low.c (get_child_debug_event): Issue a final DBG_CONTINUE
1884 when handling a EXIT_PROCESS_DEBUG_EVENT.
1885
1886 2009-01-06 Joel Brobecker <brobecker@adacore.com>
1887
1888 * gdbreplay.c (gdbreplay_version): Update copyright year.
1889 * server.c (gdbserver_version): Likewise.
1890
1891 2009-01-05 Doug Evans <dje@google.com>
1892
1893 * linux-low.c (linux_attach_lwp): Add some comments/fixmes.
1894 (handle_extended_wait): Improve comment.
1895
1896 2008-12-13 Doug Evans <dje@google.com>
1897
1898 * utils.c (xmalloc,xcalloc,xstrdup): New fns.
1899 * server.h (ATTR_MALLOC): New macro.
1900 (xmalloc,xcalloc,xstrdup): Declare.
1901 * hostio.c: Replace malloc,calloc,strdup with xmalloc,xcalloc,xstrdup.
1902 * inferiors.c: Ditto.
1903 * linux-low.c: Ditto.
1904 * mem-break.c: Ditto.
1905 * regcache.c: Ditto.
1906 * remote-utils.c: Ditto.
1907 * server.c: Ditto.
1908 * target.c: Ditto.
1909 * win32-low.c: Ditto.
1910
1911 2008-12-12 Doug Evans <dje@google.com>
1912
1913 * linux-low.c (linux_wait_for_process): Don't clobber current_inferior
1914 in debugging printf.
1915
1916 * linux-low.c (handle_extended_wait): Simplify, use my_waitpid.
1917
1918 2008-12-09 Doug Evans <dje@google.com>
1919
1920 * linux-low.h (struct process_info): Delete member tid, unused.
1921 * thread-db.c (find_one_thread): Update.
1922 (maybe_attach_thread): Update.
1923
1924 2008-12-02 Pedro Alves <pedro@codesourcery.com>
1925
1926 * target.h (struct target_ops): Add qxfer_osdata member.
1927 * linux-low.c: Include ctype.h and pwd.h and sys/types.h
1928 and dirent.h.
1929 (linux_qxfer_osdata): New functions.
1930 (linux_target_ops): Register linux_qxfer_osdata as qxfer_osdata
1931 callback.
1932 * server.c (handle_query): Handle "qXfer:osdata:read:".
1933 * remote-utils.c (buffer_grow, buffer_free, buffer_init, buffer_finish)
1934 (buffer_xml_printf): New functions.
1935 * server.h (struct buffer): New.
1936 (buffer_grow_str, buffer_grow_str0): New macros.
1937 (buffer_grow, buffer_free, buffer_init, buffer_finish)
1938 (buffer_xml_printf): Declare.
1939
1940 2008-11-24 Doug Evans <dje@google.com>
1941
1942 * Makefile.in (VERSION,DIST,LINT,LINTFLAGS): Delete, unused.
1943
1944 2008-11-24 Daniel Jacobowitz <dan@codesourcery.com>
1945
1946 * server.c (handle_v_run): Always use the supplied argument list.
1947
1948 2008-11-19 Bob Wilson <bob.wilson@acm.org>
1949
1950 * xtensa-xtregs.c (XTENSA_ELF_XTREG_SIZE): Change to 4.
1951 (xtensa_regmap_table): Add entry for scompare1.
1952
1953 2008-11-18 Thiago Jung Bauermann <bauerman@br.ibm.com>
1954
1955 * Makefile.in (powerpc-isa205-32l.o, powerpc-isa205-32l.c,
1956 powerpc-isa205-altivec32l.o, powerpc-isa205-altivec32l.c,
1957 powerpc-isa205-vsx32l.o, powerpc-isa205-vsx32l.c,
1958 powerpc-isa205-64l.o, powerpc-isa205-64l.c,
1959 powerpc-isa205-altivec64l.o, powerpc-isa205-altivec64l.c,
1960 powerpc-isa205-vsx64l.o, powerpc-isa205-vsx64l.c): New targets.
1961 * configure.srv (powerpc*-*-linux*): Add ISA 2.05 object files and
1962 XML target descriptions.
1963 * linux-ppc-low.c (ppc_arch_setup): Init registers with 64-bit FPSCR
1964 when inferior is running on an ISA 2.05 or later processor. Add
1965 special case to return offset for full 64-bit slot of FPSCR when
1966 in 32-bits.
1967
1968 2008-11-14 Daniel Gutson <dgutson@codesourcery.com>
1969
1970 * Makefile.in (SFILES, clean): Added sparc64 files.
1971 (reg-sparc64.o, reg-sparc64.c): New.
1972 * configure.srv (sparc*-*-linux*): New configuration.
1973 * linux-low.c (regsets_fetch_inferior_registers): Swap ptrace
1974 syscall arguments for SPARC.
1975 (regsets_store_inferior_registers): Likewise.
1976 * linux-sparc-low.c: New file.
1977
1978 2008-10-21 Doug Evans <dje@google.com>
1979
1980 * Makefile.in (BFD_DIR,BFD,BFD_SRC,BFD_CFLAGS): Delete.
1981 (READLINE_DIR,READLINE_DEP): Delete.
1982 (INTERNAL_CFLAGS): Update.
1983 (LINTFLAGS): Update.
1984
1985 2008-10-10 Pedro Alves <pedro@codesourcery.com>
1986
1987 * server.c (handle_v_run): If GDB didn't specify an argv, use the
1988 whole argv from the last run, not just argv[0].
1989
1990 2008-09-08 Pedro Alves <pedro@codesourcery.com>
1991
1992 * regcache.c (new_register_cache): Return NULL if the register
1993 cache size isn't known yet.
1994 (free_register_cache): Avoid dereferencing a NULL regcache.
1995
1996 2008-09-04 Daniel Jacobowitz <dan@codesourcery.com>
1997
1998 * configure.srv: Merge MIPS and MIPS64.
1999
2000 2008-08-24 Maciej W. Rozycki <macro@linux-mips.org>
2001
2002 * Makefile.in (uninstall): Apply $(EXEEXT) too.
2003
2004 2008-08-18 Luis Machado <luisgpm@br.ibm.com>
2005
2006 * Makefile.in: Add required vsx dependencies.
2007
2008 * linux-ppc-low: Define PPC_FEATURE_HAS_VSX.
2009 Declare init_registers_powerpc_vsx32l.
2010 Declare init_registers_powerpc_vsx64l.
2011 Define PTRACE_GETVSXREGS and PTRACE_SETVSXREGS.
2012 (ppc_arch_setup): Check for VSX in hwcap.
2013 (ppc_fill_vsxregset): New function.
2014 (ppc_store_vsxregset): New function.
2015 Add new VSX entry in regset_info target_regsets.
2016
2017 * configure.srv: Add new VSX dependencies.
2018
2019 2008-08-12 Pedro Alves <pedro@codesourcery.com>
2020
2021 * remote-utils.c (noack_mode, transport_is_reliable): New globals.
2022 (remote_open): Set or clear transport_is_reliable.
2023 (putpkt_binary): Don't expect acks in noack mode.
2024 (getpkt): Don't send ack/nac in noack mode.
2025 * server.c (handle_general_set): Handle QStartNoAckMode.
2026 (handle_query): If connected by tcp pass QStartNoAckMode+ in
2027 qSupported.
2028 (main): Reset noack_mode on every connection.
2029 * server.h (noack_mode): Declare.
2030
2031 2008-08-07 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
2032
2033 * Makefile.in (GDBREPLAY_OBS): New variable.
2034 (gdbreplay$(EXEEXT)): Use it to avoid unportable $^.
2035
2036 2008-08-05 Ulrich Weigand <uweigand@de.ibm.com>
2037 Daniel Jacobowitz <dan@codesourcery.com>
2038
2039 * linux-low.c (linux_resume_one_process): Ignore ESRCH.
2040 (usr_store_inferior_registers): Likewise.
2041 (regsets_store_inferior_registers): Likewise.
2042
2043 2008-07-31 Rolf Jansen <rj@surtec.com>
2044 Pedro Alves <pedro@codesourcery.com>
2045
2046 * configure.ac: Check for memmem declaration.
2047 * server.c [HAVE_MALLOC_H]: Include malloc.h.
2048 (disable_packet_vCont, disable_packet_Tthread, disable_packet_qC)
2049 (disable_packet_qfThreadInfo): Unconditionally compile.
2050 * server.h [!HAVE_DECL_MEMMEM]: Declare memmem.
2051 * configure, config.in: Regenerate.
2052
2053 2008-07-28 Doug Kwan <dougkwan@google.com>
2054
2055 * linux-low.c (sys/dir.h, sys/user.h): Remove includes.
2056 (linux_write_memory): Remove declaration of errno.
2057
2058 2008-07-12 Ulrich Weigand <uweigand@de.ibm.com>
2059
2060 * linux-low.c (handle_extended_wait): Do not use "status"
2061 variable uninitialized.
2062
2063 2008-07-07 Pedro Alves <pedro@codesourcery.com>
2064
2065 * server.c (handle_v_attach): Inhibit reporting dll changes.
2066
2067 2008-06-27 Pedro Alves <pedro@codesourcery.com>
2068
2069 * remote-utils.c (prepare_resume_reply): If requested, don't
2070 output "thread:TID" in the T stop reply.
2071
2072 * server.c (disable_packet_vCont, disable_packet_Tthread)
2073 (disable_packet_qC, disable_packet_qfThreadInfo): New globals.
2074 (handle_query): If requested, disable support for qC, qfThreadInfo
2075 and qsThreadInfo.
2076 (handle_v_requests): If requested, disable support for vCont.
2077 (gdbserver_show_disableable): New.
2078 (main): Handle --disable-packet and --disable-packet=LIST.
2079
2080 * server.h (disable_packet_vCont, disable_packet_Tthread)
2081 (disable_packet_qC, disable_packet_qfThreadInfo): Declare.
2082
2083 2008-06-20 Carlos O'Donell <carlos@codesourcery.com>
2084
2085 * server.c (gdbserver_usage): Mention --version.
2086
2087 2008-06-06 Daniel Jacobowitz <dan@codesourcery.com>
2088
2089 * Makefile.in (gdbreplay.o): New rule.
2090
2091 2008-06-06 Joseph Myers <joseph@codesourcery.com>
2092
2093 * gdbreplay.c (gdbreplay_version): Say gdbreplay in version
2094 message, not gdbserver.
2095
2096 2008-06-05 Vladimir Prus <vladimir@codesourcery.com>
2097 Nathan Sidwell <nathan@codesourcery.com>
2098 Joseph Myers <joseph@codesourcery.com>
2099
2100 * acinclude.m4: Include ../../config/acx.m4.
2101 * configure.ac: Use ACX_PKGVERSION and ACX_BUGURL.
2102 * configure, config.in: Regenerate.
2103 * Makefile.in (gdbreplay$(EXEEXT)): Add version.o.
2104 * server.c (gdbserver_version): Print PKGVERSION.
2105 (gdbsrever_usage): Add stream parameter. Print REPORT_BUGS_TO.
2106 (main): Adjust gdbserver_usage calls.
2107 * gdbreplay.c (version, host_name): Add declarations.
2108 (gdbreplay_version, gdbreplay_usage): New.
2109 (main): Accept --version and --help options.
2110
2111 2008-06-04 Daniel Jacobowitz <dan@codesourcery.com>
2112
2113 * linux-arm-low.c (thumb_breakpoint, thumb_breakpoint_len): New.
2114 (arm_breakpoint_at): Handle Thumb.
2115 (the_low_target): Add comment.
2116
2117 2008-05-29 Ulrich Weigand <uweigand@de.ibm.com>
2118
2119 * linux-ppc-low.c (ppc_collect_ptrace_register): Clear buffer.
2120
2121 2008-05-09 Doug Evans <dje@google.com>
2122
2123 * server.h (decode_search_memory_packet): Declare.
2124 * remote-utils.c (decode_search_memory_packet): New fn.
2125 * server.c (handle_search_memory_1): New fn.
2126 (handle_search_memory): New fn.
2127 (handle_query): Process qSearch:memory packets.
2128
2129 2008-05-08 Ulrich Weigand <uweigand@de.ibm.com>
2130
2131 * regcache.c (registers_length): Remove.
2132 (set_register_cache): Verify that PBUFSIZ is large enough to hold a
2133 full register packet.
2134 * regcache.h (registers_length): Remove prototype.
2135 * server.h (PBUFSIZ): Define to 16384.
2136
2137 2008-05-03 Ulrich Weigand <uweigand@de.ibm.com>
2138
2139 * configure.srv (powerpc*-*-linux*): Set srv_regobj to
2140 powerpc-32l.o, powerpc-altivec32l.o, powerpc-e500l.o,
2141 powerpc-64l.o, and powerpc-altivec64l.o.
2142 Remove rs6000/powerpc-32.xml, rs6000/powerpc-64.xml, and
2143 rs6000/powerpc-e500.xml; add rs6000/powerpc-32l.xml,
2144 rs6000/powerpc-altivec32l.xml, rs6000/powerpc-e500l.xml,
2145 rs6000/powerpc-64l.xml, rs6000/powerpc-altivec64l.xml,
2146 rs6000/power-linux.xml, and rs6000/power64-linux.xml
2147 to srv_xmlfiles.
2148
2149 * Makefile.in (reg-ppc.o, reg-ppc.c): Remove, replace by ...
2150 (powerpc-32l.o, powerpc-32l.c): ... these new rules.
2151 (powerpc-32.o, powerpc-32.c): Remove, replace by ...
2152 (powerpc-altivec32l.o, powerpc-altivec32l.c): ... these new rules.
2153 (powerpc-e500.o, powerpc-e500.c): Remove, replace by ...
2154 (powerpc-e500l.o, powerpc-e500l.c): ... these new rules.
2155 (reg-ppc64.o, reg-ppc64.c): Remove, replace by ...
2156 (powerpc-64l.o, powerpc-64l.c): ... these new rules.
2157 (powerpc-64.o, powerpc-64.c): Remove, replace by ...
2158 (powerpc-altivec64l.o, powerpc-altivec64l.c): ... these new rules.
2159 (clean): Update.
2160
2161 * linux-ppc-low.c (init_registers_ppc): Remove, replace by ...
2162 (init_registers_powerpc_32l): ... this new prototype.
2163 (init_registers_powerpc_32): Remove, replace by ...
2164 (init_registers_powerpc_altivec32l): ... this new prototype.
2165 (init_registers_powerpc_e500): Remove, replace by ...
2166 (init_registers_powerpc_e500l): ... this new prototype.
2167 (init_registers_ppc64): Remove, replace by ...
2168 (init_registers_powerpc_64l): ... this new prototype.
2169 (init_registers_powerpc_64): Remove, replace by ...
2170 (init_registers_powerpc_altivec64l): ... this new prototype.
2171 (ppc_num_regs): Set to 73.
2172 (PT_ORIG_R3, PT_TRAP): Define if necessary.
2173 (ppc_regmap, ppc_regmap_e500): Add values for orig_r3 and trap.
2174 (ppc_cannot_store_register): Handle orig_r3 and trap.
2175 (ppc_arch_setup): Update init_registers_... calls.
2176 (ppc_fill_gregset): Handle orig_r3 and trap.
2177
2178 * inferiors.c (clear_inferiors): Reset current_inferior.
2179
2180 2008-04-23 Paolo Bonzini <bonzini@gnu.org>
2181
2182 * acinclude.m4: Add override.m4.
2183 * configure: Regenerate.
2184
2185 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
2186
2187 * linux-ppc-low.c (ppc_arch_setup): Reset ppc_hwcap after the
2188 initial call to init_register_ppc64.
2189
2190 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
2191
2192 * configure.srv (powerpc64-*-linux*, powerpc-*-linux*): Merge into single
2193 powerpc*-*-linux* case.
2194 (s390-*-linux*, s390x-*-linux*): Merge into single s390*-*-linux* case.
2195
2196 2008-04-17 Ulrich Weigand <uweigand@de.ibm.com>
2197
2198 * configure.srv [powerpc64-*-linux*]: Remove powerpc-e500.o from
2199 srv_regobj. Remove rs6000/powerpc-e500.xml and rs6000/power-spe.xml
2200 from reg_xmlfiles.
2201 * linux-ppc-low.c: Include <elf.h>.
2202 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Define.
2203 (ppc_hwcap): New global variable.
2204 (ppc_regmap): Remove __SPE__ #ifdef sections.
2205 (ppc_regmap_e500): New global variable.
2206 (ppc_cannot_store_register): Update __SPE__ special case.
2207 (ppc_get_hwcap): New function.
2208 (ppc_arch_setup): Use it to determine whether inferior supports
2209 AltiVec or SPE registers. Set the_low_target.regmap if appropriate.
2210 (ppc_fill_vrregset, ppc_store_vrregset): Define unconditionally.
2211 Do not access registers if target does not support AltiVec.
2212 (ppc_fill_evrregset, ppc_store_evrregset): Define unconditionally.
2213 Do not access registers if target does not support SPE.
2214 (target_regsets): Unconditionally include AltiVec and SPE regsets.
2215
2216 2008-04-17 Daniel Jacobowitz <dan@codesourcery.com>
2217
2218 * linux-low.c (disabled_regsets, num_regsets): New.
2219 (use_regsets_p): Delete.
2220 (linux_wait_for_process): Clear disabled_regsets.
2221 (regsets_fetch_inferior_registers): Check and set it.
2222 (regsets_store_inferior_registers): Likewise.
2223 (linux_fetch_registers, linux_store_registers): Do not use
2224 use_regsets_p.
2225 (initialize_low): Allocate disabled_regsets.
2226
2227 2008-04-14 Daniel Jacobowitz <dan@codesourcery.com>
2228
2229 * Makefile.in (LIBOBJS): New.
2230 (OBS): Use LIBOBJS.
2231 (memmem.o): New rule.
2232 * configure.ac: Use AC_CONFIG_LIBOBJ_DIR and check for memmem.
2233 * configure: Regenerated.
2234
2235 2008-04-04 Ulrich Weigand <uweigand@de.ibm.com>
2236
2237 * server.c (handle_query): Never return "unsupported" for
2238 qXfer:features:read queries.
2239
2240 2008-03-27 Ulrich Weigand <uweigand@de.ibm.com>
2241
2242 * server.c (get_features_xml): Fix inverted condition.
2243 (handle_query): Always support qXfer:feature:read.
2244
2245 2008-03-10 Daniel Jacobowitz <dan@codesourcery.com>
2246
2247 * server.c (wrapper_argv): New.
2248 (start_inferior): Handle wrapper_argv. If set, expect an extra
2249 trap.
2250 (gdbserver_usage): Document --wrapper.
2251 (main): Parse --wrapper.
2252
2253 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
2254
2255 * configure.srv [powerpc64-*-linux*]: Add all files mentioned for
2256 powerpc-*-linux* to srv_regobj and reg_xmlfiles.
2257 * linux-ppc-low.c (ppc_get_pc): Support bi-arch operation.
2258 (ppc_set_pc): Likewise.
2259 (ppc_arch_setup): New function.
2260 (ppc_fill_gregset): Call ppc_collect_ptrace_register instead
2261 of collect_register.
2262 (the_low_target): Use ppc_arch_setup as arch_setup initializer.
2263
2264 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
2265
2266 * configure.srv [powerpc64-*-linux*]: Use linux-ppc-low.o
2267 instead of linux-ppc64-low.o.
2268 * linux-ppc64-low.c: Remove file.
2269 * Makefile.in (SFILES): Remove linux-ppc64-low.c.
2270 (linux-ppc64-low.o): Remove rule.
2271
2272 * linux-ppc-low.c (init_registers_ppc64): Add prototype.
2273 (init_registers_powerpc_64): Likewise.
2274 (ppc_regmap): Conditionally define depending on __powerpc64__.
2275 (ppc_cannot_store_register): Do not special-case "fpscr" when
2276 compiled on __powerpc64__.
2277 (ppc_collect_ptrace_register): New function.
2278 (ppc_supply_ptrace_register): New function.
2279 (ppc_breakpoint): Change type to "unsigned int".
2280 (ppc_breakpoint_at): Change type of "insn" to "unsigned int".
2281 (the_low_target): Conditionally provide initializers for the
2282 arch_setup member depending on __powerpc64__. Install
2283 collect_ptrace_register and supply_ptrace_register members.
2284
2285 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
2286
2287 * regcache.h (gdbserver_xmltarget): Add extern declaration.
2288 * server.c (gdbserver_xmltarget): Define.
2289 (get_features_xml): Use it to replace "target.xml" and arch_string.
2290
2291 * configure.srv: Remove srv_xmltarget. Add XML files that were
2292 mentioned there to srv_xmlfiles instead. Remove conditional tests
2293 on gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe; set
2294 srv_xmlfiles and srv_regobj to include all possible choices.
2295 * configure.ac (srv_xmltarget): Remove.
2296 (srv_xmlfiles): Do not add "target.xml".
2297 (gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe): Remove
2298 checks for supplementary target information.
2299 * configure: Regenerate.
2300 * Makefile.in (XML_TARGET): Remove.
2301 (target.xml): Remove rule.
2302 (clean): Do not clean up target.xml.
2303 (.PRECIOUS): Do not mention target.xml.
2304
2305 * target.h (struct target_ops): Remove arch_string member.
2306 * linux-low.c (linux_arch_string): Remove.
2307 (linux_target_ops): Remove arch_string initializer.
2308 * linux-low.h (struct linux_target_ops): Remove arch_string member.
2309 * linux-i386-low.c (the_low_target): Remove arch_string initializer.
2310 * linux-x86-64-low.c (the_low_target): Remove arch_string initializer.
2311 * spu-low.c (spu_arch_string): Remove.
2312 (spu_target_ops): Remove arch_string initializer.
2313 * win32-low.c (win32_arch_string): Remove.
2314 (win32_target_ops): Remove arch_string initializer.
2315 * win32-low.h (struct win32_target_ops): Remove arch_string member.
2316 * win32-arm-low.c (the_low_target): Remove arch_string initializer.
2317 * win32-i368-low.c (the_low_target): Remove arch_string initializer.
2318
2319 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
2320
2321 * linux-low.h (struct linux_target_ops): Replace left_pad_xfer field
2322 by collect_ptrace_register and supply_ptrace_register hooks.
2323 * linux-low.c (fetch_register): Use supply_ptrace_register callback
2324 instead of checking for the_low_target.left_pad_xfer.
2325 (usr_store_inferior_registers): Use collect_ptrace_register callback
2326 instead of checking for the_low_target.left_pad_xfer.
2327
2328 * linux-s390-low.c (s390_collect_ptrace_register): New function.
2329 (s390_supply_ptrace_register): Likewise.
2330 (s390_fill_gregset): Call s390_collect_ptrace_register.
2331 (the_low_target): Update.
2332
2333 * linux-ppc64-low.c (ppc_collect_ptrace_register): New function.
2334 (ppc_supply_ptrace_register): Likewise.
2335 (the_low_target): Update.
2336
2337 * linux-i386-low.c (the_low_target): Update.
2338 * linux-x86-64-low.c (the_low_target): Update.
2339
2340 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
2341
2342 * configure.srv [s390x-*-linux*]: Set srv_regobj to include both
2343 reg-s390.o and reg-s390x.o.
2344
2345 * linux-low.c (new_inferior): New global variable.
2346 (linux_create_inferior, linux_attach): Set it.
2347 (linux_wait_for_process): Call the_low_target.arch_setup after the
2348 target has stopped for the first time.
2349 (initialize_low): Do not call the_low_target.arch_setup.
2350
2351 * linux-s390-low.c (s390_get_pc): Support bi-arch operation.
2352 (s390_set_pc): Likewise.
2353 (s390_arch_setup): New function.
2354 (the_low_target): Use s390_arch_setup as arch_setup routine.
2355
2356 * regcache.c (realloc_register_cache): New function.
2357 (set_register_cache): Call it for each existing regcache.
2358
2359 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
2360
2361 * server.h (init_registers): Remove prototype.
2362
2363 * linux-low.h (struct linux_target_ops): Add arch_setup field.
2364 * linux-low.c (initialize_low): Call the_low_target.arch_setup ()
2365 instead of init_registers ().
2366 * linux-arm-low.c (init_registers_arm): Add prototype.
2367 (init_registers_arm_with_iwmmxt): Likewise.
2368 (the_low_target): Add initializer for arch_setup field.
2369 * linux-cris-low.c (init_registers_cris): Add prototype.
2370 (the_low_target): Add initializer for arch_setup field.
2371 * linux-crisv32-low.c (init_registers_crisv32): Add prototype.
2372 (the_low_target): Add initializer for arch_setup field.
2373 * linux-i386-low.c (init_registers_i386_linux): Add prototype.
2374 (the_low_target): Add initializer for arch_setup field.
2375 * linux-ia64-low.c (init_registers_ia64): Add prototype.
2376 (the_low_target): Add initializer for arch_setup field.
2377 * linux-m32r-low.c (init_registers_m32r): Add prototype.
2378 (the_low_target): Add initializer for arch_setup field.
2379 * linux-m68k-low.c (init_registers_m68k): Add prototype.
2380 (the_low_target): Add initializer for arch_setup field.
2381 * linux-mips-low.c (init_registers_mips_linux): Add prototype.
2382 (init_registers_mips64_linux): Likewise.
2383 (the_low_target): Add initializer for arch_setup field.
2384 * linux-ppc-low.c (init_registers_ppc): Add prototype.
2385 (init_registers_powerpc_32, init_registers_powerpc_e500): Likewise.
2386 (the_low_target): Add initializer for arch_setup field.
2387 * linux-ppc64-low.c (init_registers_ppc64): Add prototype.
2388 (init_registers_powerpc_64): Likewise.
2389 (the_low_target): Add initializer for arch_setup field.
2390 * linux-s390-low.c (init_registers_s390): Add prototype.
2391 (init_registers_s390x): Likewise.
2392 (the_low_target): Add initializer for arch_setup field.
2393 * linux-sh-low.c (init_registers_sh): Add prototype.
2394 (the_low_target): Add initializer for arch_setup field.
2395 * linux-x86-64-low.c (init_registers_x86_64_linux): Add prototype.
2396 (the_low_target): Add initializer for arch_setup field.
2397 * linux-xtensa-low.c (init_registers_xtensa): Add prototype.
2398 (the_low_target): Add initializer for arch_setup field.
2399
2400 * win32-low.h (struct win32_target_ops): Add arch_setup field.
2401 * win32-low.c (initialize_low): Call the_low_target.arch_setup ()
2402 instead of init_registers ().
2403 * win32-arm-low.c (init_registers_arm): Add prototype.
2404 (the_low_target): Add initializer for arch_setup field.
2405 * win32-i386-low.c (init_registers_i386): Add prototype.
2406 (the_low_target): Add initializer for arch_setup field.
2407
2408 * spu-low.c (init_registers_spu): Add prototype.
2409 (initialize_low): Call initialie_registers_spu () instead of
2410 initialize_registers ().
2411
2412 2008-02-19 Pedro Alves <pedro@codesourcery.com>
2413
2414 * server.c (handle_v_requests): When handling the vRun and vAttach
2415 packets, if already debugging a process, don't kill it. Return an
2416 error instead.
2417
2418 2008-02-17 Daniel Jacobowitz <dan@codesourcery.com>
2419
2420 * server.c (handle_query): Correct length check.
2421
2422 2008-02-14 Pedro Alves <pedro_alves@portugalmail.pt>
2423
2424 * win32-low.c (do_initial_child_stuff): Add process handle
2425 parameter. Set current_process_handle and current_process_id from the
2426 parameters. Clear globals.
2427 (win32_create_inferior): Don't set current_process_handle and
2428 current_process_id here. Instead pass them on the call to
2429 do_initial_child_stuff.
2430 (win32_attach): Likewise.
2431 (win32_clear_inferiors): New.
2432 (win32_kill): Don't close the current process handle or the
2433 current thread handle here. Instead call win32_clear_inferiors.
2434 (win32_detach): Don't open a new handle to the process. Call
2435 win32_clear_inferiors.
2436 (win32_join): Don't rely on current_process_handle; open a new
2437 handle using the process id.
2438 (win32_wait): Call win32_clear_inferiors when the inferior process
2439 has exited.
2440
2441 2008-02-14 Daniel Jacobowitz <dan@codesourcery.com>
2442
2443 * server.c (monitor_show_help): Add "exit".
2444
2445 2008-02-11 Maxim Grigoriev <maxim2405@gmail.com>
2446
2447 * Makefile.in (SFILES): Add linux-xtensa-low.c.
2448 (clean): Add reg-xtensa.c.
2449 (linux-xtensa-low.o, reg-xtensa.o, reg-xtensa.c): New dependencies.
2450 * configure.srv (xtensa*-*-linux*) New target.
2451 * linux-xtensa-low.c: New.
2452 * xtensa-xtregs.c: New.
2453
2454 2008-02-01 Pedro Alves <pedro_alves@portugalmail.pt>
2455
2456 * hostio.c: Don't include errno.h.
2457 (errno_to_fileio_errno): Move to hostio-errno.
2458 * hostio.c: (hostio_error): Remove the error parameter. Defer the
2459 error number outputting to the target->hostio_last_error callback.
2460 (hostio_packet_error): Use FILEIO_EINVAL directly.
2461 (handle_open, handle_pread, hostio_error, handle_unlink): Update
2462 calls to hostio_error.
2463 * hostio-errno.c: New.
2464 * server.h (hostio_last_error_from_errno): Declare.
2465 * target.h (target_ops): Add hostio_last_error member.
2466 * linux-low.c (linux_target_op): Register hostio_last_error_from_errno
2467 as hostio_last_error handler.
2468 * spu-low.c (spu_target_ops): Likewise.
2469 * win32-low.c [_WIN32_WCE] (win32_error_to_fileio_error)
2470 (wince_hostio_last_error): New functions.
2471 (win32_target_ops) [_WIN32_WCE]: Register wince_hostio_last_error
2472 as hostio_last_error handler.
2473 (win32_target_ops) [!_WIN32_WCE]: Register
2474 hostio_last_error_from_errno as hostio_last_error handler.
2475 * Makefile.in (SFILES): Add hostio.c and hostio-errno.c.
2476 (hostio-errno.o): New rule.
2477 * configure.ac (GDBSERVER_DEPFILES): Add $srv_hostio_err_objs.
2478 * configure.srv (srv_hostio_err_objs): New variable. Default to
2479 hostio-errno.o.
2480 (arm*-*-mingw32ce*): Set srv_hostio_err_objs to "".
2481 * configure: Regenerate.
2482
2483 2008-01-29 Daniel Jacobowitz <dan@codesourcery.com>
2484
2485 * linux-low.c (linux_attach_lwp): Do not _exit after errors.
2486 (linux_kill, linux_detach): Clean up the process list.
2487 * remote-utils.c (remote_open): Improve port number parsing.
2488 (putpkt_binary, input_interrupt): Only send interrupts if the target
2489 is running.
2490 * server.c (extended_protocol): Make static.
2491 (attached): Define earlier.
2492 (exit_requested, response_needed, program_argv): New variables.
2493 (target_running): New.
2494 (start_inferior): Clear attached here.
2495 (attach_inferior): Set attached here.
2496 (require_running): Define.
2497 (handle_query): Use require_running and target_running. Implement
2498 "monitor exit".
2499 (handle_v_attach, handle_v_run): New.
2500 (handle_v_requests): Use require_running. Handle vAttach and vRun.
2501 (gdbserver_usage): Update.
2502 (main): Redo argument parsing. Handle --debug and --multi. Handle
2503 --attach along with other options or after the port. Save
2504 program_argv. Support no initial program. Resynchronize
2505 communication with GDB after an error. Handle "monitor exit".
2506 Use require_running and target_running. Always allow the extended
2507 protocol. Do not error out for Hc0 or Hc-1. Do not automatically
2508 restart in extended mode.
2509 * README: Refer to the GDB manual. Update --attach usage.
2510
2511 2007-12-20 Andreas Schwab <schwab@suse.de>
2512
2513 * linux-low.c (STACK_SIZE): Define.
2514 (linux_tracefork_child): Use it. Use __clone2 on ia64.
2515 (linux_test_for_tracefork): Likewise.
2516
2517 2007-12-18 Daniel Jacobowitz <dan@codesourcery.com>
2518
2519 * linux-low.c (linux_wait_for_event): Update messages. Do not
2520 reinsert auto-delete breakpoints.
2521 * mem-break.c (struct breakpoint): Change return type of handler to
2522 int.
2523 (set_breakpoint_at): Update handler type.
2524 (reinsert_breakpoint_handler): Return 1 instead of calling
2525 delete_breakpoint.
2526 (reinsert_breakpoint_by_bp): Check for the original breakpoint before
2527 setting a new one.
2528 (check_breakpoints): Delete auto-delete breakpoints and return 2.
2529 * mem-break.h (set_breakpoint_at): Update handler type.
2530 * thread-db.c (thread_db_create_event, thread_db_create_event): Update.
2531 * win32-low.c (auto_delete_breakpoint): New.
2532 (get_child_debug_event): Use it.
2533
2534 2007-12-16 Daniel Jacobowitz <dan@codesourcery.com>
2535
2536 * configure.ac: Check for pread and pwrite.
2537 * hostio.c (handle_pread): Fall back to lseek and read.
2538 (handle_pwrite): Fall back to lseek and write.
2539 * config.in, configure: Regenerated.
2540
2541 2007-12-07 Daniel Jacobowitz <dan@codesourcery.com>
2542
2543 * server.c (myresume): Add own_buf argument.
2544 (main): Update calls.
2545
2546 2007-12-06 Daniel Jacobowitz <dan@codesourcery.com>
2547
2548 * linux-low.c (linux_wait, linux_resume): Do not handle async I/O.
2549 * remote-utils.c (remote_open): Do not call disable_async_io.
2550 (block_async_io): Delete.
2551 (unblock_async_io): Make static.
2552 (initialize_async_io): New.
2553 * server.c (handle_v_cont): Handle async I/O here.
2554 (myresume): Likewise. Move other common resume tasks here...
2555 (main): ... from here. Call initialize_async_io. Disable async
2556 I/O before the main loop.
2557 * server.h (initialize_async_io): Declare.
2558 (block_async_io, unblock_async_io): Delete prototypes.
2559 * spu-low.c (spu_resume, spu_wait): Do not handle async I/O here.
2560
2561 2007-12-06 Mick Davis <mickd@goanna.iinet.net.au>
2562
2563 * remote-utils.c (readchar): Allow binary data in received messages.
2564
2565 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
2566
2567 * win32-low.c (attaching): New global.
2568 (win32_create_inferior): Clear the `attaching' global.
2569 (win32_attach): Set the `attaching' global.
2570 (get_child_debug_event) [_WIN32_WCE]: Stop the inferior when
2571 attaching. Only set a breakpoint at the entry point if not
2572 attaching.
2573
2574 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
2575
2576 * server.c (main): Don't report dll events on the initial
2577 connection on attaches.
2578
2579 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
2580
2581 * server.c (main): Relax numerical bases supported for the pid of
2582 the --attach command line argument.
2583
2584 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
2585
2586 * win32-low.c (win32_attach): Call OpenProcess before
2587 DebugActiveProcess, not after. Add last error output to error
2588 call.
2589
2590 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
2591
2592 * win32-low.c (win32_get_thread_context)
2593 (win32_set_thread_context): New functions.
2594 (thread_rec): Use win32_get_thread_context.
2595 (continue_one_thread, win32_resume): Use win32_set_thread_context.
2596 * win32-low.h (win32_thread_info) [_WIN32_WCE]: Add `base_context'
2597 field.
2598
2599 2007-12-03 Leo Zayas
2600 Pedro Alves <pedro_alves@portugalmail.pt>
2601
2602 * win32-low.c (soft_interrupt_requested, faked_breakpoint): New
2603 global variables.
2604 (child_add_thread): Minor cleanup.
2605 (child_continue): Resume artificially suspended threads before
2606 calling ContinueDebugEvent.
2607 (suspend_one_thread): New.
2608 (fake_breakpoint_event): New.
2609 (get_child_debug_event): Change return type to int. Check here if
2610 gdb sent an interrupt request. If a soft interrupt was requested,
2611 fake a breakpoint event. Return 0 if there is no event to handle,
2612 and 1 otherwise.
2613 (win32_wait): Don't check here if gdb sent an interrupt request.
2614 Ensure there is a valid event to handle.
2615 (win32_request_interrupt): Add soft interruption method as last
2616 resort.
2617
2618 2007-12-03 Leo Zayas
2619 Pedro Alves <pedro_alves@portugalmail.pt>
2620
2621 * win32-low.h (win32_thread_info): Add descriptions to the
2622 structure members. Replace `suspend_count' counter by a
2623 `suspended' flag.
2624 * win32-low.c (thread_rec): Update condition of when to get the
2625 context from the inferior. Rely on ContextFlags being set if it
2626 has already been retrieved. Only suspend the inferior thread if
2627 we haven't already. Warn if that fails.
2628 (continue_one_thread): s/suspend_count/suspended/. Only call
2629 ResumeThread once. Warn if that fails.
2630
2631 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
2632
2633 * win32-low.c (win32_wait): Don't read from the inferior when it
2634 has already exited.
2635
2636 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
2637
2638 * Makefile.in (win32_low_h): New variable.
2639 (win32-low.o): Add dependency on $(win32_low_h).
2640 (win32-arm-low.o, win32-i386-low.o): New rules.
2641
2642 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
2643
2644 * hostio.c: Correct copyright year.
2645
2646 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
2647
2648 * Makefile.in (OBS): Add hostio.o.
2649 (hostio.o): New rule.
2650 * server.h (handle_vFile): Declare.
2651 * hostio.c: New file.
2652 * server.c (handle_v_requests): Take packet_len and new_packet_len
2653 for binary packets. Call handle_vFile.
2654 (main): Update call to handle_v_requests.
2655
2656 2007-11-05 Daniel Jacobowitz <dan@codesourcery.com>
2657
2658 * linux-low.c: Include <sched.h>.
2659
2660 2007-11-01 Daniel Jacobowitz <dan@codesourcery.com>
2661
2662 * linux-low.c (linux_tracefork_grandchild): New.
2663 (linux_tracefork_child): Use clone.
2664 (linux_test_for_tracefork): Use clone; allocate and free a stack.
2665
2666 2007-10-31 Joel Brobecker <brobecker@adacore.com>
2667
2668 * Makefile.in: Use $(SHELL) instead of "sh" to call regdat.sh.
2669
2670 2007-10-24 Daniel Jacobowitz <dan@codesourcery.com>
2671
2672 * linux-low.c (handle_extended_wait): Handle unexpected signals.
2673
2674 2007-10-23 Daniel Jacobowitz <dan@codesourcery.com>
2675
2676 * inferiors.c (change_inferior_id): Delete.
2677 (add_pid_to_list, pull_pid_from_list): New.
2678 * linux-low.c (PTRACE_SETOPTIONS, PTRACE_GETEVENTMSG)
2679 (PTRACE_O_TRACESYSGOOD, PTRACE_O_TRACEFORK, PTRACE_O_TRACEVFORK)
2680 (PTRACE_O_TRACECLONE, PTRACE_O_TRACEEXEC, PTRACE_O_TRACEVFORKDONE)
2681 (PTRACE_O_TRACEEXIT, PTRACE_EVENT_FORK, PTRACE_EVENT_VFORK)
2682 (PTRACE_EVENT_CLONE, PTRACE_EVENT_EXEC, PTRACE_EVENT_VFORK_DONE)
2683 (PTRACE_EVENT_EXIT, __WALL): Provide default definitions.
2684 (stopped_pids, thread_db_active, must_set_ptrace_flags): New variables.
2685 (using_threads): Always set to 1.
2686 (handle_extended_wait): New.
2687 (add_process): Do not set TID.
2688 (linux_create_inferior): Set must_set_ptrace_flags.
2689 (linux_attach_lwp): Remove TID argument. Do not check using_threads.
2690 Use PTRACE_SETOPTIONS. Call new_thread_notify. Update all callers.
2691 (linux_thread_alive): Rename TID argument to LWPID.
2692 (linux_wait_for_process): Handle unknown processes. Do not use TID.
2693 (linux_wait_for_event): Do not use TID or check using_threads. Update
2694 call to dead_thread_notify. Call handle_extended_wait.
2695 (linux_create_inferior): Use PTRACE_SETOPTIONS.
2696 (send_sigstop): Delete sigstop_sent.
2697 (wait_for_sigstop): Avoid TID.
2698 (linux_supports_tracefork_flag, linux_tracefork_child, my_waitpid)
2699 (linux_test_for_tracefork): New.
2700 (linux_lookup_signals): Use thread_db_active and
2701 linux_supports_tracefork_flag.
2702 (initialize_low): Use thread_db_active and linux_test_for_tracefork.
2703 * linux-low.h (get_process_thread): Avoid TID.
2704 (struct process_ifo): Move thread_known and tid to the end. Remove
2705 sigstop_sent.
2706 (linux_attach_lwp, thread_db_init): Update prototypes.
2707 * server.h (change_inferior_id): Delete prototype.
2708 (add_pid_to_list, pull_pid_from_list): New prototypes.
2709 * thread-db.c (thread_db_use_events): New.
2710 (find_first_thread): Rename to...
2711 (find_one_thread): ...this. Update callers and messages. Do not
2712 call fatal. Check thread_db_use_events. Do not call
2713 change_inferior_id or new_thread_notify.
2714 (maybe_attach_thread): Update. Do not call new_thread_notify.
2715 (thread_db_init): Set thread_db_use_events. Check use_events.
2716 * utils.c (fatal, warning): Correct message prefix.
2717
2718 2007-10-15 Daniel Jacobowitz <dan@codesourcery.com>
2719
2720 * Makefile.in (clean): Remove new files.
2721 (powerpc-32.o, powerpc-32.c, powerpc-e500.o, powerpc-e500.c)
2722 (powerpc-64.o, powerpc-64.c): New rules.
2723 * configure.srv: Use alternate register sets for powerpc64-*-linux*
2724 with AltiVec, powerpc-*-linux* with AltiVec, and powerpc-*-linux*
2725 with SPE.
2726 * linux-ppc-low.c (ppc_regmap): Do not fetch the FP registers for
2727 SPE targets.
2728 (ppc_cannot_store_register): Do not check for FPSCR for SPE targets.
2729 (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS, ppc_fill_vrregset)
2730 (ppc_store_vrregset, PTRACE_GETEVRREGS, PTRACE_SETEVRREGS)
2731 (struct gdb_evrregset_t, ppc_fill_evrregset, ppc_store_evrregset): New.
2732 (target_regsets): Add AltiVec and SPE register sets.
2733 * configure.ac: Check for AltiVec and SPE.
2734 * linux-ppc64-low.c (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS)
2735 (ppc_fill_vrregset, ppc_store_vrregset): New.
2736 (target_regsets): Add AltiVec register set.
2737 * configure: Regenerated.
2738
2739 2007-09-19 Daniel Jacobowitz <dan@codesourcery.com>
2740
2741 * linux-low.c (O_LARGEFILE): Define.
2742 (linux_read_memory): Use /proc/PID/mem.
2743 * configure.ac: Use AC_GNU_SOURCE. Check for pread64.
2744 * configure, config.in: Regenerated.
2745
2746 2007-09-04 Daniel Jacobowitz <dan@codesourcery.com>
2747
2748 * linux-low.c (linux_wait_for_event): Do not pass signals while
2749 single-stepping.
2750
2751 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
2752
2753 * win32-low.c (create_process): New.
2754 (win32_create_inferior): Use create_process instead of
2755 CreateProcess. If create_process failed retry appending an ".exe"
2756 suffix. Store the GetLastError result immediatelly after
2757 create_process calls and use it on the call to error.
2758
2759 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
2760
2761 * win32-low.c (handle_load_dll): Don't use toolhelp when waiting.
2762
2763 2007-08-23 Joel Brobecker <brobecker@adacore.com>
2764
2765 * configure.ac: Switch license to GPLv3.
2766
2767 2007-08-01 Michael Snyder <msnyder@access-company.com>
2768
2769 * remote-utils.c (putpkt_binary): Memory leak, free buf2.
2770
2771 2007-07-31 Pedro Alves <pedro_alves@portugalmail.pt>
2772
2773 * win32-low.c (winapi_CloseToolhelp32Snapshot) [_WIN32_WCE]: New
2774 typedef.
2775 (win32_CloseToolhelp32Snapshot) [_WIN32_WCE]: New global var.
2776 (load_toolhelp) [_WIN32_WCE]: Load TOOLHELP.DLL. Get
2777 CloseToolhelp32Snapshot.
2778 (toolhelp_get_dll_name) [_WIN32_WCE]: Close the snapshot with
2779 CloseToolhelp32Snapshot.
2780
2781 2007-07-27 Michael Snyder <michael.snyder@access-company.com>
2782
2783 * server.c (main): Check for inferior exit before main loop.
2784
2785 2007-07-18 Pedro Alves <pedro_alves@portugalmail.pt>
2786
2787 * remote-utils.c (remote_open): Set SO_KEEPALIVE on remote_desc
2788 instead of on tmp_desc.
2789
2790 2007-07-17 Pedro Alves <pedro_alves@portugalmail.pt>
2791 Daniel Jacobowitz <dan@codesourcery.com>
2792
2793 * inferiors.c (all_dlls, dlls_changed, get_dll): New.
2794 (add_thread): Minor cleanups.
2795 (clear_inferiors): Move lower in the file. Clear the DLL
2796 list.
2797 (free_one_dll, match_dll, loaded_dll, unloaded_dll, clear_list): New.
2798 * remote-utils.c (prepare_resume_reply): Check dlls_changed.
2799 (xml_escape_text): New.
2800 * server.c (handle_query): Handle qXfer:libraries:read. Report it
2801 for qSupported.
2802 (handle_v_cont): Report errors.
2803 (gdbserver_version): Update.
2804 (main): Correct size of own_buf. Do not report initial DLL events.
2805 * server.h (struct dll_info, all_dlls, dlls_changed, loaded_dll)
2806 (unloaded_dll, xml_escape_text): New.
2807 * win32-low.c (enum target_waitkind): Update comments.
2808 (win32_add_one_solib, get_image_name, winapi_EnumProcessModules)
2809 (winapi_GetModuleInformation, winapi_GetModuleFileNameExA)
2810 (win32_EnumProcessModules, win32_GetModuleInformation)
2811 (win32_GetModuleFileNameExA, load_psapi, psapi_get_dll_name)
2812 (winapi_CreateToolhelp32Snapshot, winapi_Module32First)
2813 (winapi_Module32Next, win32_CreateToolhelp32Snapshot)
2814 (win32_Module32First, win32_Module32Next, load_toolhelp)
2815 (toolhelp_get_dll_name, handle_load_dll, handle_unload_dll): New.
2816 (get_child_debug_event): Handle DLL events.
2817 (win32_wait): Likewise.
2818
2819 2007-07-12 Daniel Jacobowitz <dan@codesourcery.com>
2820
2821 * configure.srv: Set srv_linux_regsets for sh*-*-linux*.
2822 * linux-sh-low.c (sh_fill_gregset, target_regsets): New.
2823
2824 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
2825
2826 * win32-low.c (handle_output_debug_string): Ignore event if not
2827 waiting.
2828
2829 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
2830
2831 * win32-arm-low.c (arm_wince_breakpoint): Fix typo.
2832
2833 2007-07-03 Daniel Jacobowitz <dan@codesourcery.com>
2834
2835 * remote-utils.c (look_up_one_symbol): Handle 'm' packets.
2836
2837 2007-07-02 Daniel Jacobowitz <dan@codesourcery.com>
2838
2839 * inferiors.c (change_inferior_id): Add comment.
2840 * linux-low.c (check_removed_breakpoint): Add an early
2841 prototype. Improve debug output.
2842 (linux_attach): Doc update.
2843 (linux_detach_one_process, linux_detach): Clean up before releasing
2844 each process.
2845 (send_sigstop, wait_for_sigstop): Improve comments and debug output.
2846 * linux-low.h (struct process_info): Doc improvement.
2847 * mem-break.c (delete_all_breakpoints): New.
2848 * mem-break.h (delete_all_breakpoints): New prototype.
2849 * thread-db.c (find_first_thread): New.
2850 (thread_db_create_event): Call it instead of
2851 thread_db_find_new_threads. Clean up unused variables.
2852 (maybe_attach_thread): Remove first thread handling.
2853 (thread_db_find_new_threads): Use find_first_thread.
2854 (thread_db_get_tls_address): Likewise.
2855
2856 2007-06-27 Daniel Jacobowitz <dan@codesourcery.com>
2857
2858 * thread-db.c (thread_db_find_new_threads): Add prototype.
2859 (thread_db_create_event): Check for the main thread before adding
2860 a new thread.
2861 (maybe_attach_thread): Only enable event reporting if TID == 0.
2862 (thread_db_get_tls_address): Check for new threads.
2863
2864 2007-06-20 Daniel Jacobowitz <dan@codesourcery.com>
2865
2866 * linux-low.c (linux_create_inferior): Try execv before execvp.
2867 * spu-low.c (spu_create_inferior): Likewise.
2868
2869 2007-06-13 Mike Frysinger <vapier@gentoo.org>
2870
2871 * linux-low.c (linux_create_inferior): Change execv to execvp.
2872 * spu-low.c (spu_create_inferior): Likewies.
2873
2874 2007-06-13 Daniel Jacobowitz <dan@codesourcery.com>
2875
2876 * Makefile.in (clean): Clean new files instead of deleted ones.
2877 (reg-mips.o, reg-mips.c, reg-mips64.o, reg-mips64.c): Delete.
2878 (mips-linux.o, mips-linux.c, mips64-linux.o, mips64-linux.c): New
2879 rules.
2880 * configure.srv: Specify XML files and new regformats for MIPS and
2881 MIPS64 GNU/Linux.
2882 * linux-mips-low.c (mips_num_regs): Set to only used registers.
2883 (mips_regmap): Do not fetch $0. Remove unused registers. Add
2884 an entry for the restart register.
2885 (mips_cannot_fetch_register, mips_cannot_store_register)
2886 (mips_reinsert_addr, mips_fill_fpregset, mips_store_fpregset): Update
2887 register names to match the XML descriptions.
2888 (mips_fill_gregset, mips_store_gregset): Likewise. Handle the
2889 restart register instead of $0.
2890
2891 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
2892 Markus Deuling <deuling@de.ibm.com>
2893
2894 * remote-utils.c (decode_xfer_write): New function.
2895 * server.h (decode_xfer_write): Add prototype.
2896 * server.c (handle_query): Add PACKET_LEN argument. Support
2897 qXfer:spu:read and qXfer:spu:write packets.
2898 (main): Pass packet_len to handle_query.
2899 * spu-low.c (spu_target_ops): Add spu_proc_xfer_spu.
2900 * target.h (target_ops): Add qxfer_spu.
2901
2902 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
2903
2904 * spu-low.c (spu_proc_xfer_spu): Do not return failure when
2905 accessing non-seekable spufs files.
2906
2907 2007-05-16 Markus Deuling <deuling@de.ibm.com>
2908
2909 * server.c (handle_query): Add reply for qC packet.
2910
2911 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
2912 Leo Zayas <lerele@champenstudios@com>
2913
2914 * server.h (check_remote_input_interrupt_request): New function.
2915 * remote_utils.c (INVALID_DESCRIPTOR): New define.
2916 (remote_desc): Initialize with INVALID_DESCRIPTOR.
2917 (input_interrupt): Expose on USE_WIN32API too. Fix whitespace.
2918 (check_remote_input_interrupt_request): New function.
2919 * server.h (check_remote_input_interrupt_request): Declare.
2920 * win32-low.c (winapi_DebugBreakProcess,
2921 winapi_GenerateConsoleCtrlEvent): New typedefs.
2922 (get_child_debug_event): Lower Win32 debug event polling from 1 sec
2923 to 250 ms.
2924 (win32_wait): Check for remote interrupt request
2925 with check_remote_input_interrupt_request.
2926 (win32_request_interrupt): New function.
2927 (win32_target_op): Set request_interrupt to win32_request_interrupt.
2928
2929 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
2930
2931 * win32-low.c (debug_registers_changed,
2932 debug_registers_used, CONTEXT_EXTENDED_REGISTERS,
2933 CONTEXT_FLOATING_POINT, CONTEXT_DEBUG_REGISTERS,
2934 CONTEXT_DEBUGGER, CONTEXT_DEBUGGER_DR): Delete.
2935 (thread_rec): Get context using the low target.
2936 (child_add_thread): Call thread_added on the low target,
2937 which does the same thing.
2938 (regptr): Delete.
2939 (do_initial_child_stuff): Remove debug registers references.
2940 Set context using the low target. Resume threads after
2941 setting the contexts.
2942 (child_continue): Remove dead variable. Remove debug
2943 registers references.
2944 (child_fetch_inferior_registers): Go through the low target.
2945 (do_child_store_inferior_registers): Remove.
2946 (child_store_inferior_registers): Go through the low target.
2947 (win32_resume): Remove debug registers references.
2948 Set context using the low target.
2949 (handle_exception): Change return type to void. Don't record
2950 context here. Set status to TARGET_WAITKIND_SPURIOUS on a
2951 first chance exception.
2952 (get_child_debug_event): Change return type to void. Remove
2953 goto loop. Always return after waiting for debug event.
2954 (win32_wait): Convert to switch statement. Handle spurious
2955 events.
2956
2957 * win32-i386-low.c (debug_registers_changed,
2958 debug_registers_used): New.
2959 (initial_stuff): Rename to ...
2960 (i386_initial_stuff): ... this. Clear debug registers
2961 state variables.
2962 (store_debug_registers): Delete.
2963 (i386_get_thread_context): New.
2964 (load_debug_registers): Delete.
2965 (i386_set_thread_context): New.
2966 (i386_thread_added): New.
2967 (single_step): Rename to ...
2968 (i386_single_step): ... this.
2969 (do_fetch_inferior_registers): Rename to ...
2970 (i386_fetch_inferior_register): ... this.
2971 (i386_store_inferior_register): New.
2972 (the_low_target): Adapt to new interface.
2973
2974 * win32-arm-low.c (CONTEXT_FLOATING_POINT): Define.
2975 (arm_get_thread_context): New.
2976 (arm_set_thread_context): New.
2977 (regptr): New.
2978 (do_fetch_inferior_registers): Rename to ...
2979 (arm_fetch_inferior_register): ... this.
2980 (arm_store_inferior_register): New.
2981 (arm_wince_breakpoint): Reimplement as unsigned long.
2982 (arm_wince_breakpoint_len): Define.
2983 (the_low_target): Adapt to new interface.
2984
2985 * win32-low.h (target_ops): Remove regmap, store_debug_registers and
2986 load_debug_registers. Add get_thread_context, set_thread_context,
2987 thread_added and store_inferior_register. Rename
2988 fetch_inferior_registers to fetch_inferior_register.
2989 (regptr): Remove declaration.
2990
2991 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
2992
2993 * linux-low.c (linux_detach): Change return type to int. Return 0.
2994 * spu-low.c (spu_detach): Likewise.
2995
2996 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
2997
2998 * target.h (target_ops): Change return type of detach to int.
2999 Add join.
3000 (join_inferior): New.
3001 * server.c (main): Don't skip detach support on mingw32.
3002 If the inferior doesn't support detaching return error.
3003 Call join_inferior instead of using waitpid.
3004 * linux-low.c (linux_join): New.
3005 (linux_target_op): Add linux_join.
3006 * spu-low.c (spu_join): New.
3007 (spu_target_ops): Add spu_join.
3008 * win32-low.c (win32_detach): Adapt to new interface.
3009 Reopen current_process_handle before detaching. Issue a child
3010 resume before detaching.
3011 (win32_join): New.
3012 (win32_target_op): Add win32_join.
3013
3014 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
3015
3016 * win32-low.c (win32-attach): Fix return value.
3017 * target.h (target_ops): Describe ATTACH return values.
3018
3019 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
3020
3021 * win32-low.c (GETPROCADDRESS): Define.
3022 (winapi_DebugActiveProcessStop): Add WINAPI. typedef as pointer.
3023 (winapi_DebugSetProcessKillOnExit): Likewise.
3024 (win32_create_inferior): Force usage of ansi CreateProcessA.
3025 (win32_attach): Use GETPROCADDRESS.
3026 (win32_detach): Likewise.
3027
3028 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
3029
3030 * win32-low.c (win32_wait): Don't use WSTOPSIG.
3031
3032 2007-03-30 Pedro Alves <pedro_alves@portugalmail.pt>
3033
3034 * win32-low.c: Commit leftover changes from 2007-03-29.
3035
3036 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
3037
3038 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Make 16-bit
3039 fields short instead of int. Add explicit padding.
3040 (i387_cache_to_fsave): Remove unnecessary casts.
3041 (i387_fsave_to_cache): Doc fix.
3042 (i387_cache_to_fxsave): Remove unnecessary casts and masking.
3043
3044 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
3045
3046 * i387-fp.c (i387_cache_to_fxsave): Reinitialize val2 before use.
3047 (i387_fxsave_to_cache): Check fp->ftag while building ftag value.
3048
3049 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
3050
3051 * configure.srv (arm*-*-mingw32ce*): Move near the other
3052 arm targets.
3053
3054 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
3055
3056 * configure.ac: Add errno checking.
3057 (AC_CHECK_HEADERS): Add errno.h, fcntl.h, signal.h,
3058 sys/file.h and malloc.h.
3059 (AC_CHECK_DECLS): Add perror.
3060 (srv_mingwce): Handle.
3061 * configure.srv (i[34567]86-*-cygwin*): Add
3062 win32-i386-low.o to srv_tgtobj.
3063 (i[34567]86-*-mingw*): Likewise.
3064 (arm*-*-mingw32ce*): Add case.
3065 * gdbreplay.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
3066 HAVE_FCNTL_H, HAVE_ERRNO_H, HAVE_MALLOC_H]: Check.
3067 [__MINGW32CE__] (strerror): New function.
3068 [__MINGW32CE__] (errno): Define to GetLastError.
3069 [__MINGW32CE__] (COUNTOF): New macro.
3070 (remote_open): Remove extra close call.
3071 * mem-break.c (delete_breakpoint_at): New function.
3072 * mem-break.h (delete_breakpoint_at): Declare.
3073 * remote-utils.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
3074 HAVE_FCNTL_H, HAVE_UNISTD_H, HAVE_ERRNO_H]: Check.
3075 [USE_WIN32API] (read, write): Add char* casts.
3076 * server.c [HAVE_UNISTD_H, HAVE_SIGNAL_H]: Check.
3077 * server.h: Include wincecompat.h on Windows CE.
3078 [HAVE_ERRNO_H]: Check.
3079 (perror): Declare if not declared.
3080 * utils.c: Add stdlib.h, errno.h and malloc.h includes.
3081 (perror_with_name): Remove errno declaration.
3082 * wincecompat.h: New.
3083 * wincecompat.c: New.
3084 * win32-low.h: New.
3085 * win32-arm-low.c: New.
3086 * win32-i386-low.c: New.
3087 (win32-low.c): Include mem-break.h and win32-low.h, and winnt.h.
3088 (OUTMSG2): Make it safe.
3089 (_T): New macro.
3090 (COUNTOF): New macro.
3091 (NUM_REGS): Get it from the low target.
3092 (CONTEXT_EXTENDED_REGISTERS, CONTEXT_FLOATING_POINT,
3093 CONTEXT_DEBUG_REGISTERS): Add fallbacks to 0.
3094 (thread_rec): Let low target handle debug registers.
3095 (child_add_thread): Likewise.
3096 (child_init_thread_list): Likewise.
3097 (continue_one_thread): Likewise.
3098 (regptr): New.
3099 (do_child_fetch_inferior_registers): Move to ...
3100 * win32-i386-low.c: ... here, and rename to ...
3101 (do_fetch_inferior_registers): ... this.
3102 * win32-low.c (child_fetch_inferior_registers):
3103 Go through the low target.
3104 (do_child_store_inferior_registers): Use regptr.
3105 (strwinerror): New function.
3106 (win32_create_inferior): Handle Windows CE.
3107 Use strwinerror instead of strerror on Windows error
3108 codes. Add program to the error output.
3109 Don't close the main thread handle on Windows CE.
3110 (win32_attach): Use coredll.dll on Windows CE.
3111 (win32_kill): Close current process and current
3112 thread handles.
3113 (win32_detach): Use coredll.dll on Windows CE.
3114 (win32_resume): Let low target handle debug registers, and
3115 step request.
3116 (handle_exception): Add/Remove initial breakpoint. Avoid
3117 non-existant WSTOPSIG on Windows CE.
3118 (win32_read_inferior_memory): Cast to remove warning.
3119 (win32_arch_string): Go through the low target.
3120 (initialize_low): Call set_breakpoint_data with the low
3121 target's breakpoint.
3122 * win32-low.c (dr, FLAG_TRACE_BIT, FCS_REGNUM,
3123 FOP_REGNUM, mappings): Move to ...
3124 * win32-i386-low.c: ... here.
3125 * win32-low.c (win32_thread_info): Move to ...
3126 * win32-low.h: ... here.
3127 * Makefile.in (SFILES): Add win32-low.c, win32-i386-low.c,
3128 win32-arm-low.c and wincecompat.c.
3129 (all:): Add $EXEEXT.
3130 (install-only:): Likewise.
3131 (gdbserver:): Likewise.
3132 (gdbreplay:): Likewise.
3133 * config.in: Regenerate.
3134 * configure: Regenerate.
3135
3136 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
3137
3138 * win32-low.c: Rename typedef thread_info to
3139 win32_thread_info throughout.
3140
3141 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
3142
3143 * win32-i386-low.c: Rename to ...
3144 * win32-low.c: ... this.
3145 * configure.srv: Replace win32-i386-low.o with win32-low.o.
3146 * Makefile.in: Likewise.
3147
3148 2007-03-27 Pedro Alves <pedro_alves@portugalmail.pt>
3149
3150 * remote-utils.c (monitor_output): Constify msg parameter.
3151 * server.h (monitor_output): Likewise.
3152 * win32-i386-low.c (handle_output_debug_string): New.
3153 (win32_kill): Handle OUTPUT_DEBUG_STRING_EVENT events using
3154 handle_output_debug_string.
3155 (get_child_debug_event): Likewise.
3156
3157 2007-03-27 Mat Hostetter <mat@lcs.mit.edu>
3158
3159 * server.c (main): Correct strtoul check.
3160
3161 2007-03-27 Jon Ringle <jon@ringle.org>
3162
3163 * linux-low.c: Check __ARCH_HAS_MMU__ also.
3164
3165 2007-03-27 Brooks Moses <brooks.moses@codesourcery.com>
3166
3167 * Makefile.in: Add dummy "pdf" and "install-pdf" targets.
3168
3169 2007-02-27 Daniel Jacobowitz <dan@codesourcery.com>
3170
3171 * terminal.h: Check HAVE_SGTTY_H.
3172
3173 2007-02-27 Mat Hostetter <mat@lcs.mit.edu>
3174
3175 * remote-utils.c (remote_open): Print out the assigned port number.
3176
3177 2007-02-26 Daniel Jacobowitz <dan@codesourcery.com>
3178
3179 * remote-utils.c (monitor_output): New function.
3180 * server.c (debug_threads): Define here.
3181 (monitor_show_help): New function.
3182 (handle_query): Handle qRcmd.
3183 (main): Do not handle 'd' packet.
3184 * server.h (debug_threads, remote_debug, monitor_output): Declare.
3185 * linux-low.c, spu-low.c, win32-i386-low.c: Remove definitions
3186 of debug_threads.
3187
3188 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
3189
3190 * Makefile.in (EXEEXT): New.
3191 (clean): Use $(EXEEXT).
3192
3193 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
3194
3195 * target.h (target_ops): Rename send_signal to request_interrupt,
3196 and remove enum target_signal parameter.
3197 * linux-low.c (linux_request_interrupt): Rename from
3198 linux_send_signal, and always send SIGINT.
3199 * spu-low.c (spu_request_interrupt): Rename from spu_send_signal,
3200 and always send SIGINT.
3201 * remote-utils.c (putpkt_binary): Call request_interrupt, instead
3202 of send_signal.
3203 (input_interrupt): Likewise.
3204
3205 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
3206
3207 * server.c (get_features_xml): Check if target implemented
3208 arch_string.
3209 * win32-i386-low.c (win32_arch_string): New.
3210 (win32_target_ops): Add win32_arch_string as arch_string member.
3211
3212 2007-02-22 Markus Deuling <deuling@de.ibm.com>
3213
3214 * spu-low.c (spu_arch_string): New.
3215 (spu_target_ops): Add spu_arch_string.
3216
3217 2007-02-16 Daniel Jacobowitz <dan@codesourcery.com>
3218
3219 * remote-utils.c: Remove HAVE_TERMINAL_H check.
3220 * configure.ac: Do not check for terminal.h.
3221 * configure, config.in: Regenerated.
3222
3223 2007-02-08 Daniel Jacobowitz <dan@codesourcery.com>
3224
3225 * Makefile.in (OBS): Add $(XML_BUILTIN).
3226 (XML_DIR, XML_TARGET, XML_FILES, XML_BUILTIN): New.
3227 (clean): Update.
3228 (target.xml, xml-builtin.c, stamp-xml, arm-with-iwmmxt.o)
3229 (arm-with-iwmmxt.c): New.
3230 * config.in, configure: Regenerate.
3231 * configure.ac: Check for iWMMXt. Handle srv_xmltarget,
3232 srv_xmlbuiltin, and srv_xmlfiles. Define USE_XML.
3233 * configure.srv: Mention srv_xmltarget and srv_xmlfiles.
3234 (arm*-*-linux*): Add iWMMXt and regset support.
3235 * linux-arm-low.c (PTRACE_GETWMMXREGS, PTRACE_SETWMMXREGS): Define.
3236 (arm_fill_gregset, arm_store_gregset, arm_fill_wmmxregset)
3237 (arm_store_wmmxregset, target_regsets): New.
3238 * server.c (get_features_xml): Take annex argument. Check builtin
3239 XML documents.
3240 (handle_query): Handle multiple annexes.
3241
3242 2007-01-29 Daniel Jacobowitz <dan@codesourcery.com>
3243
3244 * remote-utils.c [USE_WIN32API] (read, write): Define.
3245 (putpkt_binary, input_interrupt, readchar, getpkt): Use read and
3246 write.
3247
3248 2007-01-09 Daniel Jacobowitz <dan@codesourcery.com>
3249
3250 * linux-i386-low.c (the_low_target): Set arch_string.
3251 * linux-x86-64-low.c (the_low_target): Likewise.
3252 * linux-low.c (linux_arch_string): New.
3253 (linux_target_ops): Add it.
3254 * linux-low.h (struct linux_target_ops): Add arch_string.
3255 * server.c (write_qxfer_response): Use const void * for DATA.
3256 (get_features_xml): New.
3257 (handle_query): Handle qXfer:features:read. Report it for qSupported.
3258 * target.h (struct target_ops): Add arch_string method.
3259
3260 2007-01-03 Denis Pilat <denis.pilat@st.com>
3261 Daniel Jacobowitz <dan@codesourcery.com>
3262
3263 * linux-low.c (linux_kill): Handle being called with no threads.
3264 * win32-i386-low.c (win32_kill): Likewise.
3265 (get_child_debug_event): Clear current_process_handle.
3266
3267 2006-12-30 Denis PILAT <denis.pilat@st.com>
3268 Daniel Jacobowitz <dan@codesourcery.com>
3269
3270 * remote-utils.c (remote_open): Check the type of specified
3271 serial port devices before opening them.
3272 * server.c (main): Kill the inferior if an error occurs during
3273 the first remote_open.
3274
3275 2006-12-05 Markus Deuling <deuling@de.ibm.com>
3276
3277 * README: Update supported targets.
3278
3279 2006-11-28 Daniel Jacobowitz <dan@codesourcery.com>
3280
3281 * Makefile.in (clean): Remove reg-mips64.c.
3282 (reg-mips64.c, reg-mips64.o): New rules.
3283 * configure.srv: Handle mips64. Include regset support for mips.
3284 * linux-mips-low.c (union mips_register): New.
3285 (mips_get_pc, mips_set_pc, mips_reinsert_addr): Use it.
3286 (mips_breakpoint, mips_breakpoint_at): Use int.
3287 (mips_collect_register, mips_supply_register)
3288 (mips_collect_register_32bit, mips_supply_register_32bit)
3289 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
3290 (mips_store_fpregset, target_regsets): New.
3291 * thread-db.c (thread_db_get_tls_address): Use uintptr_t.
3292
3293 2006-11-22 Ulrich Weigand <uweigand@de.ibm.com>
3294
3295 * configure.srv: Add target "spu*-*-*".
3296 * Makefile.in (clean): Remove reg-spu.c.
3297 (reg-spu.c, reg-spu.o, spu-low.o): Add dependencies.
3298 * spu-low.c: New file.
3299
3300 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
3301
3302 * configure.ac: Correct td_thr_tls_get_addr test.
3303 * configure: Regenerated.
3304
3305 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
3306
3307 * linux-low.c (linux_wait_for_event): Reformat. Use the
3308 pass_signals array.
3309 * remote-utils.c (decode_address_to_semicolon): New.
3310 * server.c (pass_signals, handle_general_set): New.
3311 (handle_query): Mention QPassSignals for qSupported.
3312 (main): Call handle_general_set.
3313 * server.h (pass_signals, decode_address_to_semicolon): New.
3314
3315 2006-11-06 Daniel Jacobowitz <dan@codesourcery.com>
3316
3317 * server.c (handle_query): Correct error handling for read_auxv.
3318
3319 2005-10-19 Ulrich Weigand <uweigand@de.ibm.com>
3320
3321 * configure.srv [s390-*-linux*, s390x-*-linux*]: Set srv_linux_regsets
3322 and srv_linux_thread_db to yes.
3323 * linux-s390-low.c (s390_fill_gregset): New function.
3324 (target_regsets): Define data structure.
3325
3326 2006-10-17 Daniel Jacobowitz <dan@codesourcery.com>
3327
3328 * acinclude.m4 (SRV_CHECK_TLS_GET_ADDR): New.
3329 * configure.ac: Use it. Define HAVE_TD_THR_TLS_GET_ADDR.
3330 * config.in, configure: Regenerated.
3331 * inferiors.c (gdb_id_to_thread): New function.
3332 (gdb_id_to_thread_id): Use it.
3333 * linux-low.c (linux_target_ops): Use thread_db_get_tls_address.
3334 * linux-low.h (struct process_info): Add th member.
3335 (thread_db_get_tls_address): New prototype.
3336 * remote-utils.c (decode_address): Make non-static.
3337 * server.c (handle_query): Handle qGetTLSAddr.
3338 * server.h (gdb_id_to_thread, decode_address): New prototypes.
3339 * target.h (struct target_ops): Add get_tls_address.
3340 * thread-db.c (maybe_attach_thread): Save the thread handle.
3341 (thread_db_get_tls_address): New.
3342
3343 2006-09-28 Daniel Jacobowitz <dan@codesourcery.com>
3344
3345 * linux-low.c (PTRACE_GETSIGINFO, PTRACE_SETSIGINFO): Define.
3346 (linux_resume_one_process): Take a siginfo_t *. Update all
3347 callers. Queue it if necessary. Use PTRACE_SETSIGINFO.
3348 (struct pending_signals): Add a siginfo_t.
3349 (linux_wait_for_process): Always set last_status.
3350 (linux_wait_for_event): Use PTRACE_GETSIGINFO.
3351 (linux_queue_one_thread): Use PTRACE_GETSIGINFO.
3352 * linux-low.h (struct process_info): Add last_status.
3353
3354 2006-09-21 Daniel Jacobowitz <dan@codesourcery.com>
3355
3356 * remote-utils.c (try_rle): New function.
3357 (putpkt_binary): Use it.
3358
3359 2006-08-19 Daniel Jacobowitz <dan@codesourcery.com>
3360
3361 * Makefile.in (clean): Clean reg-x86-64-linux.c.
3362 (reg-x86-64-linux.o, reg-x86-64-linux.c): New.
3363 * configure.srv (x86_64-*-linux*): Use reg-x86-64-linux.o.
3364 * linux-x86-64-low.c (x86_64_regmap): Include ORIG_RAX.
3365 (x86_64_fill_gregset, x86_64_store_gregset): Skip floating
3366 point registers.
3367
3368 2006-08-08 Richard Sandiford <richard@codesourcery.com>
3369
3370 * server.c (terminal_fd): New variable.
3371 (old_foreground_pgrp): Likewise.
3372 (restore_old_foreground_pgrp): New function.
3373 (start_inferior): Record the terminal file descriptor in terminal_fd
3374 and its original foreground group in old_foreground_pgrp. Register
3375 restore_old_foreground_pgrp with atexit().
3376
3377 2006-07-26 Daniel Jacobowitz <dan@codesourcery.com>
3378
3379 * server.c (handle_query): Correct qPart to qXfer.
3380
3381 2006-07-22 Daniel Jacobowitz <dan@codesourcery.com>
3382
3383 * configure.ac: Check for more headers which are missing on
3384 Windows. Automatically supply -lwsock32 and USE_WIN32API.
3385 * configure.srv: Add Cygwin and mingw32.
3386 * remote-utils.c: Don't include headers unconditionally which
3387 are missing on mingw32. Include <winsock.h> for mingw32.
3388 (remote_open): Adjust for mingw32 support. Flush
3389 standard error after writing to it.
3390 (remote_close, putpkt_binary, input_interrupt, block_async_io)
3391 (unblock_async_io, enable_async_io, disable_async_io)
3392 (readchar, getpkt): Update for Winsock support.
3393 (prepare_resume_reply): Expect a protocol signal number.
3394 * server.c: Disable <sys/wait.h> on mingw32.
3395 (start_inferior): Adjust for mingw32 support. Flush
3396 standard error after writing to it.
3397 (attach_inferior): Likewise. Use protocol signal
3398 numbers.
3399 (main): Skip 'D' packet on mingw32. Use protocol signal numbers
3400 and names.
3401 * win32-i386-low.c: New file.
3402 * Makefile.in (XM_CLIBS): Set.
3403 (gdbserver, gdbreplay): Use $(INTERNAL_CFLAGS).
3404 (win32-i386-low.o): New dependency rule.
3405 * linux-low.c (linux_wait): Use target signal numbers.
3406 * target.h (struct target_ops): Doc fix.
3407 * server.h (target_signal_to_name): New prototype.
3408 * gdbreplay.c: Don't include headers unconditionally which
3409 are missing on mingw32. Include <winsock.h> for mingw32.
3410 (remote_close, remote_open): Adjust for Winsock support.
3411 * configure, config.in: Regenerated.
3412
3413 2006-07-12 Daniel Jacobowitz <dan@codesourcery.com>
3414
3415 * server.c (decode_xfer_read, write_qxfer_response): New.
3416 (handle_query): Take a packet length argument. Handle
3417 qXfer:auxv:read instead of qPart:auxv:read. Mention it in
3418 the qSupported response.
3419 (main): Update call to handle_query.
3420
3421 2006-06-22 Daniel Jacobowitz <dan@codesourcery.com>
3422
3423 * remote-utils.c (remote_escape_output, remote_unescape_input): New.
3424 (putpkt_binary): Renamed from putpkt and adjusted for binary
3425 data.
3426 (putpkt): New wrapper for putpkt_binary.
3427 (readchar): Don't mask off the high bit.
3428 (decode_X_packet): New function.
3429 * server.c (main): Call putpkt_binary if a handler sets the packet
3430 length. Save the length of the incoming packet. Handle 'X'.
3431 * server.h (gdb_byte, remote_escape_output, decode_X_packet): New.
3432
3433 2006-06-21 Daniel Jacobowitz <dan@codesourcery.com>
3434
3435 * server.c (handle_query): Handle qSupported.
3436
3437 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
3438
3439 * remote-utils.c (all_symbols_looked_up): New variable.
3440 (look_up_one_symbol): Check it.
3441 * server.h (look_up_one_symbol): New declaration.
3442 * thread-db.c (thread_db_init): Set all_symbols_looked_up.
3443
3444 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
3445
3446 * Makefile.in (linux-arm-low.o): Update dependencies.
3447 * linux-arm-low.c: Include "gdb_proc_service.h".
3448 (PTRACE_GET_THREAD_AREA): Define.
3449 (ps_get_thread_area): New function.
3450
3451 2006-05-09 Nathan Sidwell <nathan@codesourcery.com>
3452
3453 * configure.srv (m68k*-*-uclinux*): New target.
3454 * linux-low.c (linux_create_inferior): Use vfork on mmuless systems.
3455 (linux_resume_one_process): Remove extraneous cast.
3456 (linux_read_offsets): New.
3457 (linux_target_op): Add linux_read_offsets on mmuless systems.
3458 * server.c (handle_query): Add qOffsets logic.
3459 * target.h (struct target_ops): Add read_offsets.
3460
3461 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
3462
3463 * linux-mips-low.c: Include <sys/ptrace.h> and "gdb_proc_service.h".
3464 (PTRACE_GET_THREAD_AREA): Define.
3465 (ps_get_thread_area): New function.
3466 * Makefile.in (linux-i386-low.o, linux-mips-low.o)
3467 (linux-x86-64-low.o): Update.
3468
3469 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
3470
3471 * configure.ac: Remove checks for prfpregset_t.
3472 * gdb_proc_service.h: New file.
3473 * linux-i386-low.c, linux-x86-64-low.c, thread-db.c: Use the
3474 new "gdb_proc_service.h".
3475 * proc-service.c: Likewise.
3476 (ps_pglobal_lookup, ps_pdread, ps_pdwrite): Use psaddr_t.
3477 (ps_lgetfpregs, ps_lsetfpregs): Use a void* argument.
3478 * Makefile.in (gdb_proc_service_h): Updated.
3479 * configure, config.in: Regenerated.
3480
3481 2006-03-03 Daniel Jacobowitz <dan@codesourcery.com>
3482
3483 * remote-utils.c (prepare_resume_reply): Move declaration
3484 of gdb_id_from_wait to the top of the block.
3485
3486 2006-02-15 Daniel Jacobowitz <dan@codesourcery.com>
3487
3488 * linux-low.c (regsets_store_inferior_registers): Read the regset
3489 from the target before filling it.
3490
3491 2006-02-08 Daniel Jacobowitz <dan@codesourcery.com>
3492
3493 * server.c (attach_inferior): Return SIGTRAP for a successful
3494 attach.
3495
3496 2006-02-01 Daniel Jacobowitz <dan@codesourcery.com>
3497
3498 * Makefile.in (OBS): Add version.o.
3499 (STAGESTUFF): Delete.
3500 (version.o): Add dependencies.
3501 (version.c): Replace rule.
3502 (clean): Remove version.c.
3503 * server.c (gdbserver_version): New.
3504 (gdbserver_usage): Use printf.
3505 (main): Handle --version and --help.
3506 * server.h (version, host_name): Add declarations.
3507
3508 2005-12-23 Eli Zaretskii <eliz@gnu.org>
3509
3510 * linux-arm-low.c:
3511 * linux-arm-low.c:
3512 * inferiors.c:
3513 * i387-fp.h:
3514 * i387-fp.c:
3515 * gdbreplay.c:
3516 * regcache.c:
3517 * proc-service.c:
3518 * mem-break.h:
3519 * mem-break.c:
3520 * linux-x86-64-low.c:
3521 * linux-sh-low.c:
3522 * linux-s390-low.c:
3523 * linux-ppc64-low.c:
3524 * linux-ppc-low.c:
3525 * linux-mips-low.c:
3526 * linux-m68k-low.c:
3527 * linux-m32r-low.c:
3528 * linux-low.h:
3529 * linux-low.c:
3530 * linux-ia64-low.c:
3531 * linux-i386-low.c:
3532 * linux-crisv32-low.c:
3533 * thread-db.c:
3534 * terminal.h:
3535 * target.h:
3536 * target.c:
3537 * server.h:
3538 * server.c:
3539 * remote-utils.c:
3540 * regcache.h:
3541 * utils.c:
3542 * Makefile.in:
3543 * configure.ac:
3544 * gdbserver.1: Add (C) after Copyright. Update the FSF
3545 address.
3546
3547 2005-11-13 Daniel Jacobowitz <dan@codesourcery.com>
3548
3549 * linux-arm-low.c (arm_eabi_breakpoint): New variable.
3550 (arm_breakpoint_at): Recognize both breakpoints.
3551 (the_low_target): Use the correct breakpoint instruction.
3552
3553 2005-11-02 Daniel Jacobowitz <dan@codesourcery.com>
3554
3555 * configure.srv (x86_64-*-linux*): Turn on thread_db support.
3556 * linux-x86-64-low.c (x86_64_breakpoint, x86_64_breakpoint_len)
3557 (x86_64_get_pc, x86_64_set_pc, x86_64_breakpoint_at): New.
3558 (the_low_target): Update.
3559
3560 2005-10-25 Andreas Schwab <schwab@suse.de>
3561
3562 * server.c (main): Allocate mem_buf with PBUFSIZ bytes.
3563
3564 * linux-ia64-low.c (ia64_regmap): Remove NAT registers.
3565 (ia64_num_regs): Reduce to 462.
3566
3567 2005-09-17 Daniel Jacobowitz <dan@codesourcery.com>
3568
3569 * acinclude.m4: Correct quoting.
3570 * aclocal.m4: Regenerated.
3571
3572 Suggested by SZOKOVACS Robert <szo@ies.hu>:
3573 * thread-db.c (thread_db_err_str): Handle TD_VERSION.
3574 (thread_db_init): Call thread_db_err_str.
3575 * configure.ac: Check for TD_VERSION.
3576 * config.in, configure: Regenerated.
3577
3578 2005-07-31 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
3579
3580 * server.h (error, fatal, warning): Add ATTR_FORMAT.
3581
3582 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
3583
3584 * configure.ac: Define HAVE_LINUX_REGSETS even if PTRACE_GETREGS
3585 is not available. Define HAVE_PTRACE_GETREGS if it is.
3586 * config.in, configure: Regenerated.
3587 * configure.srv: Set srv_linux_regsets for PowerPC and PowerPC64.
3588 * linux-i386-low.c, linux-m68k-low.c: Update to use
3589 HAVE_PTRACE_GETREGS.
3590 * linux-low.c (regsets_fetch_inferior_registers)
3591 (regsets_store_inferior_registers): Only return 0 if we processed
3592 GENERAL_REGS.
3593 * linux-ppc-low.c (ppc_fill_gregset, target_regsets): New.
3594 * linux-ppc64-low.c (ppc_fill_gregset, target_regsets): New.
3595
3596 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
3597
3598 * inferiors.c (struct thread_info): Add gdb_id.
3599 (add_thread): Add gdb_id argument.
3600 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New.
3601 * linux-low.c (linux_create_inferior, linux_attach_lwp): Update
3602 calls to add_thread.
3603 * remote-utils.c (prepare_resume_reply: Use thread_to_gdb_id.
3604 * server.c (handle_query): Use thread_to_gdb_id.
3605 (handle_v_cont, main): Use gdb_id_to_thread_id.
3606 * server.h (add_thread): Update prototype.
3607 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New
3608 prototypes.
3609
3610 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
3611
3612 * linux-low.c (fetch_register, usr_store_inferior_registers): Handle
3613 left-padded registers.
3614 * linux-low.h (struct linux_target_ops): Add left_pad_xfer.
3615 * linux-ppc64-low.c (the_low_target): Set left_pad_xfer.
3616
3617 2005-07-01 Steve Ellcey <sje@cup.hp.com>
3618
3619 * configure.ac (BFD_NEED_DECLARATION): Replace with AC_CHECK_DECLS.
3620 * configure: Regenerate.
3621 * config.in: Regenerate.
3622 * server.h (NEED_DECLARATION_STRERROR):
3623 Replace with !HAVE_DECL_STRERROR.
3624
3625 2005-06-16 Daniel Jacobowitz <dan@codesourcery.com>
3626
3627 * linux-low.c (linux_wait, linux_send_signal): Don't test
3628 an unsigned long variable for > 0 if it could be MAX_ULONG.
3629 * server.c (myresume): Likewise.
3630 * target.c (set_desired_inferior): Likewise.
3631
3632 2005-06-13 Mark Kettenis <kettenis@gnu.org>
3633
3634 * configure.ac: Simplify and improve check for socklen_t.
3635 * configure, config.in: Regenerate.
3636
3637 2005-06-12 Daniel Jacobowitz <dan@codesourcery.com>
3638
3639 * acconfig.h: Remove.
3640 * configure.ac: Add a test for socklen_t. Use three-argument
3641 AC_DEFINE throughout.
3642 * config.in: Regenerated using autoheader 2.59.
3643 * configure: Regenerated.
3644
3645 * gdbreplay.c (socklen_t): Provide a default.
3646 (remote_open): Use socklen_t.
3647 * remote-utils.c (socklen_t): Provide a default.
3648 (remote_open): Use socklen_t.
3649 (convert_int_to_ascii, convert_ascii_to_int, decode_M_packet): Use
3650 unsigned char.
3651
3652 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Use unsigned
3653 char for buffers.
3654 * linux-low.c (linux_read_memory, linux_write_memory)
3655 (linux_read_auxv): Likewise.
3656 * mem-break.c (breakpoint_data, set_breakpoint_data, check_mem_read)
3657 (check_mem_write): Likewise.
3658 * mem-break.h (set_breakpoint_data, check_mem_read, check_mem_write):
3659 Likewise.
3660 * regcache.c (struct inferior_rgcache_data, registers_to_string)
3661 (registers_from_string, register_data): Likewise.
3662 * server.c (handle_query, main): Likewise.
3663 * server.h (convert_ascii_to_int, convert_int_to_ascii)
3664 (decode_M_packet): Likewise.
3665 * target.c (read_inferior_memory, write_inferior_memory): Likewise.
3666 * target.h (struct target_ops): Update read_memory, write_memory,
3667 and read_auxv.
3668 (read_inferior_memory, write_inferior_memory): Update.
3669 * linux-low.h (struct linux_target_ops): Change type of breakpoint
3670 to unsigned char *.
3671 * linux-arm-low.c, linux-cris-low.c, linux-crisv32-low.c,
3672 linux-i386-low.c, linux-m32r-low.c, linux-m68k-low.c,
3673 linux-mips-low.c, linux-ppc-low.c, linux-ppc64-low.c,
3674 linux-s390-low.c, linux-sh-low.c: Update for changes in
3675 read_inferior_memory and the_low_target->breakpoint.
3676
3677 2005-05-28 Daniel Jacobowitz <dan@codesourcery.com>
3678
3679 * Makefile.in (SFILES): Add linux-ppc64-low.c.
3680 (linux-ppc64-low.o, reg-ppc64.c, reg-ppc64.o): New targets.
3681 * configure.srv: Add powerpc64-*-linux*.
3682 * linux-ppc64-low.c: New file.
3683
3684 2005-05-23 Orjan Friberg <orjanf@axis.com>
3685
3686 * linux-cris-low.c: New file with support for CRIS.
3687 * linux-crisv32-low.c: Ditto for CRISv32.
3688 * Makefile.in (SFILES): Add linux-cris-low.c, linux-crisv32-low.c.
3689 (clean): Add reg-cris.c and reg-crisv32.c.
3690 Add linux-cris-low.o, linux-crisv32-low.o, reg-cris.o, reg-cris.c,
3691 reg-crisv32.o, and reg-crisv32.c to make rules.
3692 * configure.srv: Add cris-*-linux* and crisv32-*-linux* to list of
3693 recognized targets.
3694
3695 2005-05-16 Ulrich Weigand <uweigand@de.ibm.com>
3696
3697 * linux-low.c (fetch_register): Ensure buffer size is a multiple
3698 of sizeof (PTRACE_XFER_TYPE).
3699 (usr_store_inferior_registers): Likewise. Zero out excess bytes.
3700
3701 2005-05-12 Orjan Friberg <orjanf@axis.com>
3702
3703 * target.h (struct target_ops): Add insert_watchpoint,
3704 remove_watchpoint, stopped_by_watchpoint, stopped_data_address function
3705 pointers for hardware watchpoint support.
3706 * linux-low.h (struct linux_target_ops): Ditto.
3707 * linux-low.c (linux_insert_watchpoint, linux_remove_watchpoint)
3708 (linux_stopped_by_watchpoint, linux_stopped_data_address): New. Add
3709 to linux_target_ops.
3710 * remote-utils.c (prepare_resume_reply): Add watchpoint information to
3711 reply packet.
3712 * server.c (main): Recognize 'Z' and 'z' packets.
3713
3714 2005-05-10 Ulrich Weigand <uweigand@de.ibm.com>
3715
3716 * linux-s390-low.c (s390_breakpoint, s390_breakpoint_len): Define.
3717 (s390_get_pc, s390_set_pc, s390_breakpoint_at): New functions.
3718 (the_low_target): Add new members.
3719
3720 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
3721
3722 * proc-service.c (ps_lgetregs): Search all_processes instead of
3723 all_threads.
3724
3725 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
3726
3727 * server.c (start_inferior): Change return type to int.
3728 (attach_inferior): Change sigptr to int *.
3729 (handle_v_cont, handle_v_requests): Change signal to int *.
3730 (main): Change signal to int.
3731
3732 2005-04-15 Kei Sakamoto <sakamoto.kei@renesas.com>
3733
3734 * Makefile.in: Add linux-m32r-low.o, reg-m32r.c and reg-m32r.o.
3735 * configure.srv: Add m32r*-*-linux*.
3736 * linux-m32r-low.c: New file.
3737
3738 2005-03-04 Daniel Jacobowitz <dan@codesourcery.com>
3739
3740 * Makefile.in (stamp-h): Set CONFIG_HEADERS explicitly.
3741
3742 2005-03-03 Daniel Jacobowitz <dan@codesourcery.com>
3743
3744 * inferiors.c (change_inferior_id, add_thread, find_inferior_id):
3745 Take unsigned long arguments for PIDs.
3746 * linux-low.c (add_process, linux_attach_lwp, linux_attach)
3747 (linux_thread_alive, linux_wait_for_event, kill_lwp, send_sigstop)
3748 (wait_for_sigstop, linux_resume_one_process)
3749 (regsets_fetch_inferior_registers, linux_send_signal)
3750 (linux_read_auxv): Likewise. Update the types of variables holding
3751 PIDs. Update format string specifiers.
3752 * linux-low.h (struct process_info, linux_attach_lwp): Likewise.
3753 * remote-utils.c (prepare_resume_reply): Likewise.
3754 * server.c (cont_thread, general_thread, step_thread)
3755 (thread_from_wait, old_thread_from_wait, signal_pid): Change type to
3756 unsigned long.
3757 (handle_query): Update format specifiers.
3758 (handle_v_cont, main): Use strtoul for thread IDs.
3759 * server.h (struct inferior_list_entry): Use unsigned long for ID.
3760 (add_thread, find_inferior_id, change_inferior_id, cont_thread)
3761 (general_thread, step_thread, thread_from_wait)
3762 (old_thread_from_wait): Update.
3763 * target.h (struct thread_resume): Use unsigned long for THREAD.
3764 (struct target_ops): Use unsigned long for arguments to attach and
3765 thread_alive.
3766
3767 2005-02-24 Daniel Jacobowitz <dan@codesourcery.com>
3768
3769 * acinclude.m4: Include bfd/bfd.m4 directly.
3770 * configure.ac: Use AC_ARG_PROGRAM. Suggested by Aron Griffis
3771 <agriffis@toolchain.org>.
3772 * aclocal.m4, configure: Regenerated.
3773
3774 2005-01-07 Andrew Cagney <cagney@gnu.org>
3775
3776 * configure.ac: Rename configure.in, require autoconf 2.59.
3777 * configure: Re-generate.
3778
3779 2004-12-08 Daniel Jacobowitz <dan@debian.org>
3780
3781 * acinclude.m4 (SRV_CHECK_THREAD_DB): Add ps_get_thread_area. Reset
3782 LIBS when finished.
3783 * aclocal.m4: Regenerated.
3784 * configure: Regenerated.
3785
3786 2004-11-21 Andreas Schwab <schwab@suse.de>
3787
3788 * linux-m68k-low.c (m68k_num_gregs): Define.
3789 (m68k_fill_gregset, m68k_store_gregset, m68k_fill_fpregset)
3790 (m68k_store_fpregset, target_regsets) [HAVE_LINUX_REGSETS]: New.
3791 (m68k_breakpoint, m68k_breakpoint_len, m68k_get_pc, m68k_set_pc)
3792 (m68k_breakpoint_at): New. Add to the_low_target.
3793
3794 * configure.srv (m68*-*-linux*): Set srv_linux_regsets and
3795 srv_linux_thread_db to yes.
3796
3797 2004-10-20 Joel Brobecker <brobecker@gnat.com>
3798
3799 * linux-x86-64-low.c (ARCH_SET_GS): Add definition if missing.
3800 (ARCH_SET_FS): Likewise.
3801 (ARCH_GET_FS): Likewise.
3802 (ARCH_GET_GS): Likewise.
3803
3804 2004-10-16 Daniel Jacobowitz <dan@debian.org>
3805
3806 * linux-i386-low.c (ps_get_thread_area): New.
3807 * linux-x86-64-low.c (ps_get_thread_area): New.
3808 * linux-low.c: Include <sys/syscall.h>.
3809 (linux_kill_one_process): Don't kill the first thread here.
3810 (linux_kill): Kill the first thread here.
3811 (kill_lwp): New function.
3812 (send_sigstop, linux_send_signal): Use it.
3813 * proc-service.c: Clean up #ifdefs.
3814 (fpregset_info): Delete.
3815 (ps_lgetregs): Update and enable implementation.
3816 (ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs): Remove disabled
3817 implementations.
3818 * remote-utils.c (struct sym_cache, symbol_cache): New.
3819 (input_interrupt): Print a clearer message.
3820 (async_io_enabled): New variable.
3821 (enable_async_io, disable_async_io): Use it. Update comments.
3822 (look_up_one_symbol): Use the symbol cache.
3823 * thread-db.c (thread_db_look_up_symbols): New function.
3824 (thread_db_init): Update comments. Call thread_db_look_up_symbols.
3825
3826 2004-10-16 Daniel Jacobowitz <dan@debian.org>
3827
3828 * configure.in: Test for -rdynamic.
3829 * configure: Regenerated.
3830 * Makefile (INTERNAL_LDFLAGS): New.
3831 (gdbserver, gdbreplay): Use it.
3832
3833 2004-09-02 Andrew Cagney <cagney@gnu.org>
3834
3835 * Makefile.in (TAGS): Replace TM_FILE with DEPRECATED_TM_FILE.
3836
3837 2004-03-23 Daniel Jacobowitz <drow@mvista.com>
3838
3839 * linux-low.c (linux_wait): Clear all_processes list also.
3840
3841 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
3842
3843 * linux-low.c: Include <errno.h>. Remove extern declaration of
3844 errno.
3845
3846 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
3847
3848 * gdbreplay.c, server.h, utils.c: Update copyright years.
3849
3850 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
3851
3852 * server.c (main): Print child status or termination signal from
3853 variable 'signal', not 'sig'.
3854
3855 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
3856
3857 * linux-low.c (linux_read_memory): Change return type to
3858 int. Check for and return error from ptrace().
3859 * target.c (read_inferior_memory): Change return type to int. Pass
3860 back return status from the_target->read_memory().
3861 * target.h (struct target_ops): Adapt *read_memory() prototype.
3862 Update comment.
3863 (read_inferior_memory): Adapt prototype.
3864 * server.c (main): Return an error packet if
3865 read_inferior_memory() returns an error.
3866
3867 2004-03-04 Daniel Jacobowitz <drow@mvista.com>
3868
3869 * Makefile.in (distclean): Remove config.h, stamp-h, and config.log.
3870 Unify with other clean targets.
3871
3872 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
3873
3874 * server.c (handle_v_cont): Call set_desired_inferior.
3875
3876 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
3877
3878 * remote-utils.c (prepare_resume_reply): Always supply "thread:".
3879
3880 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
3881
3882 * linux-low.c (linux_wait): Unblock async I/O.
3883 (linux_resume): Block and enable async I/O.
3884 * remote-utils.c (block_async_io, unblock_async_io): New functions.
3885 * server.h (block_async_io, unblock_async_io): Add prototypes.
3886
3887 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
3888
3889 * remote-utils.c (remote_open): Print a status notice after
3890 opening a TCP port.
3891 * server.c (attach_inferior): Print a status notice after
3892 attaching.
3893
3894 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
3895
3896 * linux-arm-low.c (arm_get_pc): Print out stop PC in debug mode.
3897
3898 2004-02-26 Daniel Jacobowitz <drow@mvista.com>
3899
3900 * remote-utils.c (write_enn): Use "E01" instead of "ENN" for the
3901 error packet.
3902 * server.c, target.h: Update copyright years.
3903
3904 2004-02-25 Roland McGrath <roland@redhat.com>
3905
3906 * target.h (struct target_ops): New member `read_auxv'.
3907 * server.c (handle_query): Handle qPart:auxv:read: query using that.
3908 * linux-low.c (linux_read_auxv): New function.
3909 (linux_target_ops): Initialize `read_auxv' member to that.
3910
3911 2004-02-17 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
3912
3913 Committed by Jim Blandy <jimb@redhat.com>.
3914
3915 * linux-s390-low.c (s390_num_regs): Update.
3916 (s390_regmap): Remove control registers. Use __s390x__ predefine
3917 instead of GPR_SIZE to distiguish s390 and s390x targets.
3918
3919 2004-01-31 Daniel Jacobowitz <drow@mvista.com>
3920
3921 * linux-low.c: Update copyright year.
3922 (check_removed_breakpoint): Clear pending_is_breakpoint.
3923 (linux_set_resume_request, linux_queue_one_thread)
3924 (resume_status_pending_p): New functions.
3925 (linux_continue_one_thread): Use process->resume.
3926 (linux_resume): Only resume threads if there are no pending events.
3927 * linux-low.h (struct process_info): Add resume request
3928 pointer.
3929
3930 2004-01-30 Daniel Jacobowitz <drow@mvista.com>
3931
3932 * regcache.c (new_register_cache): Clear the allocated register
3933 buffer. Suggested by Atsushi Nemoto <anemo@mba.ocn.ne.jp>.
3934
3935 2003-10-13 Daniel Jacobowitz <drow@mvista.com>
3936
3937 * linux-low.c (linux_resume): Take a struct thread_resume *
3938 argument.
3939 (linux_wait): Update call.
3940 (resume_ptr): New static variable.
3941 (linux_continue_one_thread): Renamed from
3942 linux_continue_one_process. Use resume_ptr.
3943 (linux_resume): Use linux_continue_one_thread.
3944 * server.c (handle_v_cont, handle_v_requests): New functions.
3945 (myresume): New function.
3946 (main): Handle 'v' case.
3947 * target.h (struct thread_resume): New type.
3948 (struct target_ops): Change argument of "resume" to struct
3949 thread_resume *.
3950 (myresume): Delete macro.
3951
3952 2003-08-08 H.J. Lu <hongjiu.lu@intel.com>
3953
3954 * Makefile.in (install-only): Create dest dir. Support DESTDIR.
3955 (uninstall): Support DESTDIR.
3956
3957 Mon Jul 21 20:09:34 UTC 2003 Brendan Conoboy <blc@redhat.com>
3958
3959 * configure.srv: Add xscale*linux copy of arm*linux entry.
3960
3961 2003-07-24 Daniel Jacobowitz <drow@mvista.com>
3962
3963 * linux-arm-low.c (arm_reinsert_addr): New function.
3964 (the_low_target): Add arm_reinsert_addr.
3965
3966 2003-07-08 Mark Kettenis <kettenis@gnu.org>
3967
3968 * mem-break.c: Remove whitespace at end of file.
3969
3970 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
3971
3972 * configure.in: Check whether we need to prototype strerror.
3973 * server.h: Optionally prototype strerror.
3974 * gdbreplay.c (perror_with_name): Use strerror.
3975 * linux-low.c (linux_attach_lwp): Use strerror.
3976 * utils.c (perror_with_name): Use strerror.
3977 * config.in, configure: Regenerated.
3978
3979 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
3980
3981 * linux-sh-low.c (sh_regmap): Fix FP register offsets, reported by
3982 SUGIOKA Toshinobu <sugioka@itonet.co.jp>.
3983
3984 2003-06-20 Daniel Jacobowitz <drow@mvista.com>
3985
3986 * Makefile.in (SFILES): Update.
3987 * low-hppabsd.c, low-lynx.c, low-nbsd.c, low-sim.c, low-sparc.c,
3988 low-sun3.c: Remove files.
3989
3990 2003-06-17 Daniel Jacobowitz <drow@mvista.com>
3991
3992 * linux-low.c: Move comment to linux_thread_alive where it belonged.
3993 (linux_detach_one_process, linux_detach): New functions.
3994 (linux_target_ops): Add linux_detach.
3995 * server.c (main): Handle 'D' packet.
3996 * target.h (struct target_ops): Add "detach" member.
3997 (detach_inferior): Define.
3998
3999 2003-06-13 Mark Kettenis <kettenis@gnu.org>
4000
4001 From Kelley Cook <kelleycook@wideopenwest.com>:
4002 * configure.srv: Accept i[34567]86 variants.
4003
4004 2003-06-05 Daniel Jacobowitz <drow@mvista.com>
4005
4006 * linux-low.c (linux_wait_for_event): Correct comment typos.
4007 (linux_resume_one_process): Call check_removed_breakpoint.
4008 (linux_send_signal): New function.
4009 (linux_target_ops): Add linux_send_signal.
4010 * remote-utils.c (putpkt, input_interrupt): Use send_signal instead
4011 of kill.
4012 * target.h (struct target_ops): Add send_signal.
4013
4014 2003-05-29 Jim Blandy <jimb@redhat.com>
4015
4016 * linux-low.c (usr_store_inferior_registers): Transfer buf in
4017 PTRACE_XFER_TYPE-sized chunks, not int-sized chunks. Otherwise,
4018 if 'int' is smaller than PTRACE_XFER_TYPE, you end up throwing
4019 away part of the register's value.
4020
4021 2003-03-26 Daniel Jacobowitz <drow@mvista.com>
4022
4023 * linux-low.c (linux_create_inferior): Use __SIGRTMIN.
4024 (linux_wait_for_event, linux_init_signals): Likewise.
4025
4026 2003-03-17 Daniel Jacobowitz <drow@mvista.com>
4027
4028 * configure.in: Check for stdlib.h.
4029 * configure: Regenerated.
4030 * config.in: Regenerated.
4031
4032 2003-01-04 Andreas Schwab <schwab@suse.de>
4033
4034 * linux-m68k-low.c (m68k_num_regs): Define to 29 instead of 31.
4035
4036 2003-01-02 Andrew Cagney <ac131313@redhat.com>
4037
4038 * Makefile.in: Remove obsolete code.
4039
4040 2002-11-20 Daniel Jacobowitz <drow@mvista.com>
4041
4042 * linux-s390-low.c (s390_regmap): Check GPR_SIZE instead of
4043 defined(PT_FPR0_HI).
4044
4045 2002-11-17 Stuart Hughes <seh@zee2.com>
4046
4047 * linux-arm-low.c (arm_num_regs): Increase.
4048 (arm_regmap): Include status register.
4049
4050 2002-11-17 Daniel Jacobowitz <drow@mvista.com>
4051
4052 * linux-low.c (register_addr): Remove incorrect -1 check.
4053
4054 2002-08-29 Daniel Jacobowitz <drow@mvista.com>
4055
4056 * linux-low.c (linux_create_inferior): Call setpgid. Return
4057 the new PID.
4058 (unstopped_p, linux_signal_pid): Remove.
4059 (linux_target_ops): Remove linux_signal_pid.
4060 * remote-utils.c (putpkt, input_interrupt): Use signal_pid
4061 global instead of target method.
4062 * target.h (struct target_ops): Remove signal_pid. Update comment
4063 for create_inferior.
4064 * server.c (signal_pid): New variable.
4065 (create_inferior): Set signal_pid. Block SIGTTOU and SIGTTIN in
4066 gdbserver. Set the child to be the foreground process group.
4067 (attach_inferior): Set signal_pid.
4068
4069 2002-08-23 Daniel Jacobowitz <drow@mvista.com>
4070
4071 * ChangeLog: New file, with entries from gdb/ChangeLog after GDB 5.2.
4072
4073 2002-08-20 Jim Blandy <jimb@redhat.com>
4074
4075 * Makefile.in (LDFLAGS): Allow the configure script to establish a
4076 default for this.
4077
4078 2002-08-01 Andrew Cagney <cagney@redhat.com>
4079
4080 * Makefile.in: Make chill references obsolete.
4081
4082 2002-07-24 Kevin Buettner <kevinb@redhat.com>
4083
4084 * configure.in (unistd.h): Add to AC_CHECK_HEADERS list.
4085 * configure: Regenerate.
4086 * config.in: Regenerate.
4087
4088 2002-07-09 David O'Brien <obrien@FreeBSD.org>
4089
4090 * gdbreplay.c (stdlib.h, unistd.h): Conditionaly include.
4091 (perror_with_name, remote_close, remote_open, expect, play): Static.
4092
4093 2002-07-04 Michal Ludvig <mludvig@suse.cz>
4094
4095 * linux-x86-64-low.c (x86_64_regmap): Make it an array of
4096 byte offsets instead of an array of indexes.
4097 (x86_64_store_gregset, x86_64_store_fpregset): Parameter made const.
4098
4099 2002-06-13 Daniel Jacobowitz <drow@mvista.com>
4100
4101 * regcache.c: Add comment.
4102
4103 2002-06-11 Daniel Jacobowitz <drow@mvista.com>
4104
4105 * thread-db.c: New file.
4106 * proc-service.c: New file.
4107 * acinclude.m4: New file.
4108 * Makefile.in: Add GDBSERVER_LIBS, gdb_proc_service_h,
4109 proc-service.o, and thread-db.o.
4110 (linux-low.o): Add USE_THREAD_DB.
4111 * acconfig.h: Add HAVE_PRGREGSET_T, HAVE_PRFPREGSET_T,
4112 HAVE_LWPID_T, HAVE_PSADDR_T, and PRFPREGSET_T_BROKEN.
4113 * aclocal.m4: Regenerated.
4114 * config.in: Regenerated.
4115 * configure: Regenerated.
4116 * configure.in: Check for proc_service.h, sys/procfs.h,
4117 thread_db.h, and linux/elf.h headrs.
4118 Check for lwpid_t, psaddr_t, prgregset_t, prfpregset_t, and
4119 PRFPREGSET_T_BROKEN. Introduce srv_thread_depfiles and USE_THREAD_DB.
4120 Check for -lthread_db and thread support.
4121 * configure.srv: Enable thread_db support for ARM, i386, MIPS,
4122 PowerPC, and SuperH.
4123 * i387-fp.c: Constify arguments.
4124 * i387-fp.h: Likewise.
4125 * inferiors.c: (struct thread_info): Renamed from
4126 `struct inferior_info'. Remove PID member. Use generic inferior
4127 list header. All uses updated.
4128 (inferiors, signal_pid): Removed.
4129 (all_threads): New variable.
4130 (get_thread): Define.
4131 (add_inferior_to_list): New function.
4132 (for_each_inferior): New function.
4133 (change_inferior_id): New function.
4134 (add_inferior): Removed.
4135 (remove_inferior): New function.
4136 (add_thread): New function.
4137 (free_one_thread): New function.
4138 (remove_thread): New function.
4139 (clear_inferiors): Use for_each_inferior and free_one_thread.
4140 (find_inferior): New function.
4141 (find_inferior_id): New function.
4142 (inferior_target_data): Update argument type.
4143 (set_inferior_target_data): Likewise.
4144 (inferior_regcache_data): Likewise.
4145 (set_inferior_regcache_data): Likewise.
4146 * linux-low.c (linux_bp_reinsert): Remove.
4147 (all_processes, stopping_threads, using_thrads)
4148 (struct pending_signals, debug_threads, pid_of): New.
4149 (inferior_pid): Replace with macro.
4150 (struct inferior_linux_data): Remove.
4151 (get_stop_pc, add_process): New functions.
4152 (linux_create_inferior): Restore SIGRTMIN+1 before calling exec.
4153 Use add_process and add_thread.
4154 (linux_attach_lwp): New function, based on old linux_attach. Use
4155 add_process and add_thread. Set stop_expected for new threads.
4156 (linux_attach): New function.
4157 (linux_kill_one_process): New function.
4158 (linux_kill): Kill all LWPs.
4159 (linux_thread_alive): Use find_inferior_id.
4160 (check_removed_breakpoints, status_pending_p): New functions.
4161 (linux_wait_for_process): Renamed from linux_wait_for_one_inferior.
4162 Update. Use WNOHANG. Wait for cloned processes also. Update process
4163 struct for the found process.
4164 (linux_wait_for_event): New function.
4165 (linux_wait): Use it. Support LWPs.
4166 (send_sigstop, wait_for_sigstop, stop_all_processes)
4167 (linux_resume_one_process, linux_continue_one_process): New functions.
4168 (linux_resume): Support LWPs.
4169 (REGISTER_RAW_SIZE): Remove.
4170 (fetch_register): Use register_size instead. Call supply_register.
4171 (usr_store_inferior_registers): Likewise. Call collect_register.
4172 Fix recursive case.
4173 (regsets_fetch_inferior_registers): Improve error message.
4174 (regsets_store_inferior_registers): Add debugging.
4175 (linux_look_up_symbols): Call thread_db_init if USE_THREAD_DB.
4176 (unstopped_p, linux_signal_pid): New functions.
4177 (linux_target_ops): Add linux_signal_pid.
4178 (linux_init_signals): New function.
4179 (initialize_low): Call it. Initialize using_threads.
4180 * regcache.c (inferior_regcache_data): Add valid
4181 flag.
4182 (get_regcache): Fetch registers lazily. Add fetch argument
4183 and update all callers.
4184 (regcache_invalidate_one, regcache_invalidate): New
4185 functions.
4186 (new_register_cache): Renamed from create_register_cache.
4187 Return the new regcache.
4188 (free_register_cache): Change argument to a void *.
4189 (registers_to_string, registers_from_string): Call get_regcache
4190 with fetch flag set.
4191 (register_data): Make static. Pass fetch flag to get_regcache.
4192 (supply_register): Call get_regcache with fetch flag clear.
4193 (collect_register): Call get_regcache with fetch flag set.
4194 (collect_register_as_string): New function.
4195 * regcache.h: Update.
4196 * remote-utils.c (putpkt): Flush after debug output and use
4197 stderr.
4198 Handle input interrupts while waiting for an ACK.
4199 (input_interrupt): Use signal_pid method.
4200 (getpkt): Flush after debug output and use stderr.
4201 (outreg): Use collect_register_as_string.
4202 (new_thread_notify, dead_thread_notify): New functions.
4203 (prepare_resume_reply): Check using_threads. Set thread_from_wait
4204 and general_thread.
4205 (look_up_one_symbol): Flush after debug output.
4206 * server.c (step_thread, server_waiting): New variables.
4207 (start_inferior): Don't use signal_pid. Update call to mywait.
4208 (attach_inferior): Update call to mywait.
4209 (handle_query): Handle qfThreadInfo and qsThreadInfo.
4210 (main): Don't fetch/store registers explicitly. Use
4211 set_desired_inferior. Support proposed ``Hs'' packet. Update
4212 calls to mywait.
4213 * server.h: Update.
4214 (struct inferior_list, struct_inferior_list_entry): New.
4215 * target.c (set_desired_inferior): New.
4216 (write_inferior_memory): Constify.
4217 (mywait): New function.
4218 * target.h: Update.
4219 (struct target_ops): New signal_pid method.
4220 (mywait): Removed macro, added prototype.
4221
4222 * linux-low.h (regset_func): Removed.
4223 (regset_fill_func, regset_store_func): New.
4224 (enum regset_type): New.
4225 (struct regset_info): Add type field. Use new operation types.
4226 (struct linux_target_ops): stop_pc renamed to get_pc.
4227 Add decr_pc_after_break and breakpoint_at.
4228 (get_process, get_thread_proess, get_process_thread)
4229 (strut process_info, all_processes, linux_attach_lwp)
4230 (thread_db_init): New.
4231
4232 * linux-arm-low.c (arm_get_pc, arm_set_pc,
4233 arm_breakpoint, arm_breakpoint_len, arm_breakpoint_at): New.
4234 (the_low_target): Add new members.
4235 * linux-i386-low.c (i386_store_gregset, i386_store_fpregset)
4236 (i386_store_fpxregset): Constify.
4237 (target_regsets): Add new kind identifier.
4238 (i386_get_pc): Renamed from i386_stop_pc. Simplify.
4239 (i386_set_pc): Add debugging.
4240 (i386_breakpoint_at): New function.
4241 (the_low_target): Add new members.
4242 * linux-mips-low.c (mips_get_pc, mips_set_pc)
4243 (mips_breakpoint, mips_breakpoint_len, mips_reinsert_addr)
4244 (mips_breakpoint_at): New.
4245 (the_low_target): Add new members.
4246 * linux-ppc-low.c (ppc_get_pc, ppc_set_pc)
4247 (ppc_breakpoint, ppc_breakpoint_len, ppc_breakpoint_at): New.
4248 (the_low_target): Add new members.
4249 * linux-sh-low.c (sh_get_pc, sh_set_pc)
4250 (sh_breakpoint, sh_breakpoint_len, sh_breakpoint_at): New.
4251 (the_low_target): Add new members.
4252 * linux-x86-64-low.c (target_regsets): Add new kind
4253 identifier.
4254
4255 2002-05-15 Daniel Jacobowitz <drow@mvista.com>
4256
4257 From Martin Pool <mbp@samba.org>:
4258 * server.c (gdbserver_usage): New function.
4259 (main): Call it.
4260
4261 2002-05-14 Daniel Jacobowitz <drow@mvista.com>
4262
4263 * mem-break.c (reinsert_breakpoint_by_bp): Correct typo
4264 stop_at -> stop_pc.
4265
4266 2002-05-04 Andrew Cagney <ac131313@redhat.com>
4267
4268 * Makefile.in: Remove obsolete code.
4269
4270 2002-04-24 Michal Ludvig <mludvig@suse.cz>
4271
4272 * linux-low.c (regsets_fetch_inferior_registers),
4273 (regsets_store_inferior_registers): Removed cast to int from
4274 ptrace() calls.
4275 * regcache.h: Added declaration of struct inferior_info.
4276
4277 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
4278
4279 * inferiors.c (struct inferior_info): Add regcache_data.
4280 (add_inferior): Call create_register_cache.
4281 (clear_inferiors): Call free_register_cache.
4282 (inferior_regcache_data, set_inferior_regcache_data): New functions.
4283 * regcache.c (struct inferior_regcache_data): New.
4284 (registers): Remove.
4285 (get_regcache): New function.
4286 (create_register_cache, free_register_cache): New functions.
4287 (set_register_cache): Don't initialize the register cache here.
4288 (registers_to_string, registers_from_string, register_data): Call
4289 get_regcache.
4290 * regcache.h: Add prototypes.
4291 * server.h: Likewise.
4292
4293 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
4294
4295 * mem-break.c: New file.
4296 * mem-break.h: New file.
4297 * Makefile.in: Add mem-break.o rule; update server.h
4298 dependencies.
4299 * inferiors.c (struct inferior_info): Add target_data
4300 member.
4301 (clear_inferiors): Free target_data member if set.
4302 (inferior_target_data, set_inferior_target_data): New functions.
4303 * linux-i386-low.c (i386_breakpoint, i386_breakpoint_len)
4304 (i386_stop_pc, i386_set_pc): New. Add to the_low_target.
4305 * linux-low.c (linux_bp_reinsert): New variable.
4306 (struct inferior_linux_data): New.
4307 (linux_create_inferior): Use set_inferior_target_data.
4308 (linux_attach): Likewise. Call add_inferior.
4309 (linux_wait_for_one_inferior): New function.
4310 (linux_wait): Call it.
4311 (linux_write_memory): Add const.
4312 (initialize_low): Call set_breakpoint_data.
4313 * linux-low.h (struct linux_target_ops): Add breakpoint
4314 handling members.
4315 * server.c (attach_inferior): Remove extra add_inferior
4316 call.
4317 * server.h: Include mem-break.h. Update inferior.c
4318 prototypes.
4319 * target.c (read_inferior_memory)
4320 (write_inferior_memory): New functions.
4321 * target.h (read_inferior_memory)
4322 (write_inferior_memory): Change macros to prototypes.
4323 (struct target_ops): Update comments. Add const to write_memory
4324 definition.
4325
4326 2002-04-11 Daniel Jacobowitz <drow@mvista.com>
4327
4328 * linux-low.c (usr_store_inferior_registers): Support
4329 registers which are allowed to fail to store.
4330 * linux-low.h (linux_target_ops): Likewise.
4331 * linux-ppc-low.c (ppc_regmap): Support FPSCR.
4332 (ppc_cannot_store_register): FPSCR may not be storable.
4333
4334 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
4335
4336 * server.h: Include <string.h> if HAVE_STRING_H.
4337 * ChangeLog: Correct paths in last ChangeLog entry.
4338
4339 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
4340
4341 * linux-low.h: Remove obsolete prototypes.
4342 (struct linux_target_ops): New.
4343 (extern the_low_target): New.
4344 * linux-low.c (num_regs, regmap): Remove declarations.
4345 (register_addr): Use the_low_target explicitly.
4346 (fetch_register): Likewise.
4347 (usr_fetch_inferior_registers): Likewise.
4348 (usr_store_inferior_registers): Likewise.
4349 * linux-arm-low.c (num_regs): Remove.
4350 (arm_num_regs): Define.
4351 (arm_regmap): Renamed from regmap, made static.
4352 (arm_cannot_fetch_register): Renamed from cannot_fetch_register,
4353 made static.
4354 (arm_cannot_store_register): Renamed from cannot_store_register,
4355 made static.
4356 (the_low_target): New.
4357 * linux-i386-low.c (num_regs): Remove.
4358 (i386_num_regs): Define.
4359 (i386_regmap): Renamed from regmap, made static.
4360 (i386_cannot_fetch_register): Renamed from cannot_fetch_register,
4361 made static.
4362 (i386_cannot_store_register): Renamed from cannot_store_register,
4363 made static.
4364 (the_low_target): New.
4365 * linux-ia64-low.c (num_regs): Remove.
4366 (ia64_num_regs): Define.
4367 (ia64_regmap): Renamed from regmap, made static.
4368 (ia64_cannot_fetch_register): Renamed from cannot_fetch_register,
4369 made static.
4370 (ia64_cannot_store_register): Renamed from cannot_store_register,
4371 made static.
4372 (the_low_target): New.
4373 * linux-m68k-low.c (num_regs): Remove.
4374 (m68k_num_regs): Define.
4375 (m68k_regmap): Renamed from regmap, made static.
4376 (m68k_cannot_fetch_register): Renamed from cannot_fetch_register,
4377 made static.
4378 (m68k_cannot_store_register): Renamed from cannot_store_register,
4379 made static.
4380 (the_low_target): New.
4381 * linux-mips-low.c (num_regs): Remove.
4382 (mips_num_regs): Define.
4383 (mips_regmap): Renamed from regmap, made static.
4384 (mips_cannot_fetch_register): Renamed from cannot_fetch_register,
4385 made static.
4386 (mips_cannot_store_register): Renamed from cannot_store_register,
4387 made static.
4388 (the_low_target): New.
4389 * linux-ppc-low.c (num_regs): Remove.
4390 (ppc_num_regs): Define.
4391 (ppc_regmap): Renamed from regmap, made static.
4392 (ppc_cannot_fetch_register): Renamed from cannot_fetch_register,
4393 made static.
4394 (ppc_cannot_store_register): Renamed from cannot_store_register,
4395 made static.
4396 (the_low_target): New.
4397 * linux-s390-low.c (num_regs): Remove.
4398 (s390_num_regs): Define.
4399 (s390_regmap): Renamed from regmap, made static.
4400 (s390_cannot_fetch_register): Renamed from cannot_fetch_register,
4401 made static.
4402 (s390_cannot_store_register): Renamed from cannot_store_register,
4403 made static.
4404 (the_low_target): New.
4405 * linux-sh-low.c (num_regs): Remove.
4406 (sh_num_regs): Define.
4407 (sh_regmap): Renamed from regmap, made static.
4408 (sh_cannot_fetch_register): Renamed from cannot_fetch_register,
4409 made static.
4410 (sh_cannot_store_register): Renamed from cannot_store_register,
4411 made static.
4412 (the_low_target): New.
4413 * linux-x86-64-low.c (x86_64_regmap): Renamed from regmap.
4414 (the_low_target): New.
4415
4416 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
4417
4418 * Makefile.in: Add stamp-h target.
4419 * configure.in: Create stamp-h.
4420 * configure: Regenerated.
4421
4422 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
4423
4424 * inferiors.c: New file.
4425 * target.c: New file.
4426 * target.h: New file.
4427 * Makefile.in: Add target.o and inferiors.o. Update
4428 dependencies.
4429 * linux-low.c (inferior_pid): New static variable,
4430 moved from server.c.
4431 (linux_create_inferior): Renamed from create_inferior.
4432 Call add_inferior. Return 0 on success instead of a PID.
4433 (linux_attach): Renamed from myattach.
4434 (linux_kill): Renamed from kill_inferior. Call clear_inferiors ().
4435 (linux_thread_alive): Renamed from mythread_alive.
4436 (linux_wait): Renamed from mywait. Call clear_inferiors () if the
4437 child dies.
4438 (linux_resume): Renamed from myresume. Add missing ``return 0''.
4439 (regsets_store_inferior_registers): Correct error message.
4440 Add missing ``return 0''.
4441 (linux_fetch_registers): Renamed from fetch_inferior_registers.
4442 (linux_store_registers): Renamed from store_inferior_registers.
4443 (linux_read_memory): Renamed from read_inferior_memory.
4444 (linux_write_memory): Renamed from write_inferior_memory.
4445 (linux_target_ops): New structure.
4446 (initialize_low): Call set_target_ops ().
4447 * remote-utils.c (unhexify): New function.
4448 (hexify): New function.
4449 (input_interrupt): Send signals to ``signal_pid''.
4450 * server.c (inferior_pid): Remove.
4451 (start_inferior): Update create_inferior call.
4452 (attach_inferior): Call add_inferior.
4453 (handle_query): New function.
4454 (main): Call handle_query for `q' packets.
4455 * server.h: Include "target.h". Remove obsolete prototypes.
4456 Add prototypes for "inferiors.c", "target.c", hexify, and unhexify.
4457
4458 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
4459
4460 * Makefile.in: Add WARN_CFLAGS. Update configury
4461 dependencies.
4462 * configure.in: Check for <string.h>
4463 * configure: Regenerate.
4464 * config.in: Regenerate.
4465 * gdbreplay.c: Include needed system headers.
4466 (remote_open): Remove strchr prototype.
4467 * linux-low.h: Correct #ifdef to HAVE_LINUX_USRREGS.
4468 * regcache.c (supply_register): Change buf argument to const void *.
4469 (supply_register_by_name): Likewise.
4470 (collect_register): Change buf argument to void *.
4471 (collect_register_by_name): Likewise.
4472 * regcache.h: Add missing prototypes.
4473 * remote-utils.c: Include <arpa/inet.h> for inet_ntoa.
4474 * server.c (handle_query): New function.
4475 (attached): New static variable, moved out of main.
4476 (main): Quiet longjmp clobber warnings.
4477 * server.h: Add ATTR_NORETURN and ATTR_FORMAT. Update prototypes.
4478 * utils.c (error): Remove NORETURN.
4479 (fatal): Likewise.
This page took 0.139955 seconds and 4 git commands to generate.