Per-inferior target_terminal state, fix PR gdb/13211, more
[deliverable/binutils-gdb.git] / gdb / gdbserver / ChangeLog
1 2018-01-30 Pedro Alves <palves@redhat.com>
2
3 PR gdb/13211
4 * target.c (target_terminal::terminal_state): Rename to ...
5 (target_terminal::m_terminal_state): ... this.
6
7 2018-01-19 James Clarke <jrtc27@jrtc27.com>
8
9 * linux-low.c (handle_extended_wait): Surround call to
10 thread_db_notice_clone with #ifdef USE_THREAD_DB.
11
12 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
13
14 * linux-low.c (attach_proc_task_lwp_callback): Adjust to
15 linux_ptrace_attach_fail_reason_string now returning an
16 std::string.
17 (linux_attach): Likewise.
18 * thread-db.c (attach_thread): Likewise.
19
20 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
21
22 PR gdb/21559
23 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
24 checking for fs_base/gs_base fields in struct user_regs_struct.
25 * configure: Regenerate.
26
27 2018-01-16 Yao Qi <yao.qi@linaro.org>
28
29 PR gdb/18749
30 * linux-low.c (fetch_register): Call supply_register instead of
31 error.
32
33 2018-01-08 Yao Qi <yao.qi@linaro.org>
34 Simon Marchi <simon.marchi@ericsson.com>
35
36 * Makefile.in (OBS): Remove selftest.o.
37 * configure.ac: Set srv_selftest_objs if $development is true.
38 (GDBSERVER_DEPFILES): Append $srv_selftest_objs.
39 * configure: Re-generated.
40 * server.c (captured_main): Wrap variable selftest_filter with
41 GDB_SELF_TEST.
42
43 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
44
45 * server.c (parse_debug_format_options): Return std::string.
46 (handle_monitor_command, captured_main): Adjust.
47
48 2018-01-05 Pedro Alves <palves@redhat.com>
49
50 PR gdb/18653
51 * server.c (captured_main): Pass quiet=false to
52 save_original_signals_state.
53
54 2018-01-01 Joel Brobecker <brobecker@adacore.com>
55
56 * gdbreplay.c (gdbreplay_version): Update copyright year in
57 version message.
58 * server.c (gdbserver_version): Likewise.
59
60 2017-12-08 Tom Tromey <tom@tromey.com>
61
62 * ax.c (ax_printf): Update.
63
64 2017-12-07 Yao Qi <yao.qi@linaro.org>
65
66 * linux-aarch64-ipa.c (initialize_low_tracepoint): Call
67 aarch64_linux_read_description.
68 * linux-amd64-ipa.c (idx2mask): New array.
69 (get_ipa_tdesc): Move idx2mask out.
70 (initialize_low_tracepoint): Initialize target descriptions.
71 * linux-i386-ipa.c (idx2mask): New array.
72 (get_ipa_tdesc): Move idx2mask out.
73 (initialize_low_tracepoint): Initialize target descriptions.
74
75 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
76
77 * tdesc.c (struct tdesc_type): Change return type.
78 (tdesc_add_flag): Change parameter type.
79 (tdesc_add_bitfield): Likewise.
80 (tdesc_add_field): Likewise.
81 (tdesc_set_struct_size): Likewise.
82
83 2017-12-05 Simon Marchi <simon.marchi@ericsson.com>
84
85 * regcache.c (registers_to_string): Remove unused variable.
86
87 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
88
89 * inferiors.c (for_each_inferior_with_data): Remove.
90 * inferiors.h (for_each_inferior_with_data): Remove.
91 * server.c (handle_qxfer_threads_worker): Change parameter type.
92 (handle_qxfer_threads_proper): Use for_each_thread.
93
94 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
95
96 * inferiors.c (for_each_inferior): Remove.
97 (clear_inferiors): Use for_each_thread.
98 * inferiors.h (for_each_inferior): Remove.
99 * linux-low.c (linux_wait_for_event_filtered): Use
100 for_each_thread.
101 (linux_stabilize_threads): Likewise.
102 * regcache.c (regcache_release): Likewise.
103 * server.c (gdb_wants_all_threads_stopped): Likewise.
104 (clear_pending_status_callback): Remove.
105 (handle_status): Use for_each_thread.
106 (captured_main): Likewise.
107 * win32-low.c (child_init_thread_list): Likewise.
108 (win32_clear_inferiors): Likewise.
109 (fake_breakpoint_event): Likewise.
110
111 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
112
113 * inferiors.h (find_inferior): Remove.
114 * inferiors.c (find_inferior): Remove.
115
116 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
117
118 * linux-low.c (resume_status_pending_p): Update comment.
119 (need_step_over_p): Update comment.
120
121 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
122
123 * linux-low.c (proceed_one_lwp): Return void, change parameter
124 type.
125 (unsuspend_and_proceed_one_lwp): Likewise.
126 (proceed_all_lwps): Use for_each_thread.
127 (unstop_all_lwps): Likewise.
128
129 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
130
131 * linux-low.c (linux_resume_one_thread): Return void, take
132 parameter directly.
133 (linux_resume): Use for_each_thread.
134
135 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
136
137 * linux-low.c (send_sigstop_callback): Return void, change
138 parameter type. Rename to...
139 (send_sigstop): ... this.
140 (suspend_and_send_sigstop_callback): Return void, change parameter
141 type. Rename to...
142 (suspend_and_send_sigstop): ... this.
143 (stop_all_lwps): Use for_each_thread.
144
145 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
146
147 * linux-low.c (lwp_running): Return bool, remove unused
148 argument.
149 (linux_stabilize_threads): Use find_thread.
150
151 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
152
153 * linux-low.c (select_singlestep_lwp_callback): Remove.
154 (count_events_callback): Remove.
155 (select_event_lwp_callback): Remove.
156 (select_event_lwp): Use find_thread/for_each_thread.
157
158 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
159
160 * linux-low.c (not_stopped_callback): Return bool, take filter
161 argument directly.
162 (linux_wait_for_event_filtered): Use find_thread.
163 (linux_wait_1): Likewise.
164
165 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
166
167 * linux-low.c (same_lwp): Remove.
168 (find_lwp_pid): Use find_thread.
169
170 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
171
172 * linux-low.c (delete_lwp_callback): Remove.
173 (linux_mourn): Use for_each_thread.
174
175 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
176
177 * linux-low.c (linux_detach_lwp_callback): Return void, remove
178 args parameter, don't check for pid.
179 (linux_detach): Use for_each_thread.
180
181 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
182
183 * linux-low.c (struct counter): Remove.
184 (second_thread_of_pid_p): Remove.
185 (last_thread_of_process_p): Use find_thread.
186
187 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
188
189 * inferiors.c (find_inferior_in_random): Remove.
190 * inferiors.h (find_inferior_in_random): Remove.
191 * linux-low.c (status_pending_p_callback): Return bool, accept
192 parameter ptid directly.
193 (linux_wait_for_event_filtered): Use find_thread_in_random.
194 (linux_wait_1): Likewise.
195
196 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
197
198 * inferiors.c (find_inferior_id): Remove.
199 (find_thread_ptid): Move implemention from find_inferior_id to
200 here.
201 * inferiors.h (find_inferior_id): Remove.
202 * server.c (handle_status): Use find_thread_ptid.
203 (process_serial_event): Likewise.
204 * thread-db.c (find_one_thread): Likewise.
205 (thread_db_thread_handle): Likewise.
206 * win32-low.c (thread_rec): Likewise.
207 (child_delete_thread): Likewise.
208 (win32_thread_alive): Likewise.
209 (get_child_debug_event): Likewise.
210
211 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
212
213 * linux-mips-low.c (update_watch_registers_callback): Return
214 void, remove pid_p parameter, don't check for pid.
215 (mips_insert_point, mips_remove_point): Use for_each_thread.
216
217 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
218
219 * lynx.low (lynx_delete_thread_callback): Remove.
220 (lynx_mourn): Use for_each_thread.
221
222 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
223
224 * regcache.c (regcache_invalidate_one): Remove.
225 (regcache_invalidate_pid): use for_each_thread.
226
227 2017-11-26 Tom Tromey <tom@tromey.com>
228
229 * linux-low.c (linux_create_inferior): Update.
230
231 2017-11-24 Ulrich Weigand <uweigand@de.ibm.com>
232
233 * spu-low.c (spu_create_inferior): Fix typo in argument name.
234
235 2017-11-24 Alan Hayward <alan.hayward@arm.com>
236
237 * configure.srv: Add linux-aarch64-tdesc-selftest.o.
238 * linux-aarch64-low.c (initialize_low_arch): Call init func.
239 * linux-aarch64-tdesc-selftest.c: New file.
240 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
241
242 2017-11-24 Alan Hayward <alan.hayward@arm.com>
243
244 * configure.srv: Add new file.
245 * linux-aarch64-low.c (initialize_low_arch): Call init func.
246 * linux-aarch64-tdesc-selftest.c: New file.
247 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
248
249 2017-11-24 Alan Hayward <alan.hayward@arm.com>
250
251 * linux-aarch64-ipa.c (initialize_low_tracepoint): Remove init.
252 * linux-aarch64-low.c (initialize_low_arch): Remove init.
253 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add init.
254
255 2017-11-24 Alan Hayward <alan.hayward@arm.com>
256
257 * configure.srv: Add new files.
258 * linux-aarch64-ipa.c (get_ipa_tdesc): Call
259 aarch64_linux_read_description.
260 * linux-aarch64-low.c (aarch64_linux_read_description):
261 Merge with aarch64_arch_setup.
262 (aarch64_arch_setup): Call aarch64_linux_read_description.
263 * linux-aarch64-tdesc.c: New file.
264 * linux-aarch64-tdesc.h: New file.
265
266 2017-11-24 Yao Qi <yao.qi@linaro.org>
267
268 * configure.srv: Set $srv_regobj for tic6x-linux.
269 * linux-tic6x-low.c: Include "arch/tic6x.h" and "tdesc.h".
270 (tic6x_read_description): Move some code to tic6x_arch_setup.
271 (tic6x_tdesc_test): New function.
272 (initialize_low_arch): Call selftests::register_test.
273
274 2017-11-22 Yao Qi <yao.qi@linaro.org>
275
276 * remote-utils.c (prepare_resume_reply): Use memcpy.
277
278 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
279
280 * linux-low.c (kill_one_lwp_callback): Return void, take
281 argument directly, don't filter on pid.
282 (linux_kill): Use for_each_thread.
283
284 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
285
286 * linux-low.c (need_step_over_p): Return bool, remove dummy
287 argument.
288 (linux_resume, proceed_all_lwps): Use find_thread.
289
290 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
291
292 * linux-low.c (resume_status_pending_p): Return bool, remove
293 flag_p argument.
294 (linux_resume): Use find_thread.
295
296 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
297
298 * linux-low.c (struct thread_resume_array): Remove.
299 (linux_set_resume_request): Return void, take arguments
300 directly.
301 (linux_resume): Use for_each_thread.
302
303 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
304
305 * linux-low.c (stuck_in_jump_pad_callback): Change prototype,
306 return bool, remove data argument.
307 (linux_stabilize_threads): Use find_thread.
308
309 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
310
311 * linux-low.c (unsuspend_one_lwp): Remove.
312 (unsuspend_all_lwps): Use for_each_thread, inline code from
313 unsuspend_one_lwp.
314
315 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
316
317 * gdbthread.h (find_thread): Add overload with ptid_t filter.
318 * linux-low.c (struct iterate_over_lwps_args): Remove.
319 (iterate_over_lwps_filter): Remove.
320 (iterate_over_lwps): Use find_thread.
321
322 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
323
324 * linux-low.c (reset_lwp_ptrace_options_callback): Remove.
325 (linux_handle_new_gdb_connection): Use for_each_thread, inline
326 code from reset_lwp_ptrace_options_callback.
327
328 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
329
330 * linux-arm-low.c (struct update_registers_data): Remove.
331 (update_registers_callback): Return void, take arguments
332 directly, don't check thread's pid.
333 (arm_insert_point, arm_remove_point): Use for_each_thread.
334
335 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
336
337 * win32-low.c (continue_one_thread): Return void, take argument
338 directly.
339 (child_continue): Use for_each_thread.
340
341 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
342
343 * win32-i386-low.c (update_debug_registers_callback): Rename
344 to ...
345 (update_debug_registers): ... this, return void, remove pid_p arg.
346 (x86_dr_low_set_addr, x86_dr_low_set_control): Use for_each_thread.
347
348 2017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
349
350 * inferiors.h (struct process_info): Add constructor, initialize
351 fields..
352 <syscalls_to_catch>: Change type to std::vector<int>.
353 * inferiors.c (add_process): Allocate process_info with new.
354 (remove_process): Free process_info with delete.
355 * linux-low.c (handle_extended_wait): Adjust.
356 (gdb_catching_syscalls_p, gdb_catch_this_syscall_p): Adjust.
357 * server.c (handle_general_set): Adjust.
358
359 2017-11-16 Pedro Alves <palves@redhat.com>
360
361 * remote-utils.c (remote_close): Block SIGIO signals instead of
362 uninstalling the SIGIO handler.
363
364 2017-11-16 Alan Hayward <alan.hayward@arm.com>
365
366 * tdesc.c (tdesc_get_features_xml): Allow null osabi.
367
368 2017-11-16 Yao Qi <yao.qi@linaro.org>
369
370 * linux-tic6x-low.c (tic6x_fill_gregset): Cast buf.
371 (tic6x_store_gregset): Likewise.
372 (tic6x_usrregs_info): Move it up.
373
374 2017-11-15 Alan Hayward <alan.hayward@arm.com>
375
376 * Makefile.in: Update arch rules.
377 * configure.srv: Explicitly mark arch/ files.
378
379 2017-11-13 Andreas Schwab <schwab@suse.de>
380
381 * linux-m68k-low.c (m68k_supports_hardware_single_step): New
382 function.
383 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
384
385 2017-11-06 Pedro Alves <palves@redhat.com>
386
387 * config.in, configure: Regenerate.
388
389 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
390
391 * target.c (struct thread_search): Remove.
392 (thread_search_callback): Remove.
393 (prepare_to_access_memory): Use for_each_thread instead of
394 find_inferior. Inline code from thread_search_callback.
395
396 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
397
398 * server.c (struct visit_actioned_threads_data): Remove.
399 (visit_actioned_threads): Change prototype to take arguments
400 directly.
401 (resume): Use find_thread instead of find_inferior.
402
403 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
404
405 * server.c (queue_stop_reply_callback): Change prototype, return
406 void.
407 (find_status_pending_thread_callback): Remove.
408 (handle_status): Replace find_inferior with find_thread and
409 for_each_thread.
410
411 2017-10-25 Alan Hayward <alan.hayward@arm.com>
412
413 * linux-aarch64-low.c (aarch64_fill_gregset): Replace defines
414 with REGNO.
415 (aarch64_store_gregset): Likewise.
416 (aarch64_fill_fpregset): Likewise.
417 (aarch64_store_fpregset): Likewise.
418
419 2017-10-21 Simon Marchi <simon.marchi@ericsson.com>
420
421 * gdbthread.h (find_thread, for_each_thread): New functions.
422 * inferiors.c (thread_of_pid): Remove.
423 (find_any_thread_of_pid): Use find_thread.
424 * linux-low.c (num_lwps): Use for_each_thread.
425
426 2017-10-17 Yao Qi <yao.qi@linaro.org>
427
428 * Makefile.in: Remove one rule.
429 * configure.srv: Rename aarch64-insn.o with arch/aarch64-insn.o.
430
431 2017-10-17 Yao Qi <yao.qi@linaro.org>
432
433 * configure.srv: Rename arm-linux.o with arch/arm-linux.o.
434 Rename arm-get-next-pcs.o with arch/arm-get-next-pcs.o.
435
436 2017-10-17 Yao Qi <yao.qi@linaro.org>
437
438 * configure.srv: Rename arm.o with arch/arm.o.
439
440 2017-10-17 Yao Qi <yao.qi@linaro.org>
441
442 * Makefile.in (CONFIG_SRC_SUBDIR): New variable.
443 (clean): Remove .o files in CONFIG_SRC_SUBDIR.
444 (distclean): Remove DEPDIR in CONFIG_SRC_SUBDIR.
445 (arch-i386.o, arch-amd64.o): Remove rules.
446 (arch/%.o): New rule.
447 Update POSTCOMPILE and COMPILE.pre.
448 * configure.ac: Invoke AC_CONFIG_COMMANDS.
449 * configure: Re-generated.
450 * configure.srv: Replace arch-i386.o with arch/i386.o.
451 Replace arch-amd64.o with arch/amd64.o.
452
453 2017-10-16 Yao Qi <yao.qi@linaro.org>
454
455 * configure: Regenerated.
456
457 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
458
459 * inferiors.h: (struct inferior_list): Remove.
460 (struct inferior_list_entry); Remove.
461 (add_inferior_to_list, clear_inferior_list, one_inferior_p,
462 A_I_NEXT, ALL_INFERIORS_TYPE, ALL_INFERIORS, remove_inferior,
463 get_first_inferior): Remove.
464 (for_each_inferior, for_each_inferior_with_data, find_inferior,
465 find_inferior_id, find_inferior_in_random): Change signature.
466 * inferiors.c (all_threads): Change type to
467 std::list<thread_info *>.
468 (get_thread): Remove macro.
469 (find_inferior, find_inferior_id): Change signature, implement
470 using find_thread.
471 (find_inferior_in_random): Change signature, implement using
472 find_thread_in_random.
473 (for_each_inferior, for_each_inferior_with_data): Change
474 signature, implement using for_each_thread.
475 (add_inferior_to_list, remove_inferior): Remove.
476 (add_thread, get_first_thread, thread_of_pid,
477 find_any_thread_of_pid, free_one_thread, remove_thread): Update.
478 (get_first_inferior, one_inferior_p, clear_inferior_list):
479 Remove.
480 (clear_inferiors, get_thread_process): Update.
481 * gdbthread.h: Include <list>.
482 (struct thread_info) <entry>: Remove field.
483 <id>: New field.
484 (all_threads): Change type to std::list<thread_info *>.
485 (get_first_inferior): Add doc.
486 (find_thread, for_each_thread, find_thread_in_random): New
487 functions.
488 (current_ptid, pid_of, ptid_of, lwpid_of): Update.
489 * linux-arm-low.c (update_registers_callback): Update.
490 * linux-low.c (second_thread_of_pid_p): Update.
491 (kill_one_lwp_callback, linux_detach_lwp_callback,
492 delete_lwp_callback, status_pending_p_callback, same_lwp,
493 find_lwp_pid, num_lwps, iterate_over_lwps_filter,
494 iterate_over_lwps, not_stopped_callback,
495 resume_stopped_resumed_lwps, count_events_callback,
496 select_singlestep_lwp_callback, select_event_lwp_callback,
497 unsuspend_one_lwp, linux_wait_1, send_sigstop_callback,
498 suspend_and_send_sigstop_callback, wait_for_sigstop,
499 stuck_in_jump_pad_callback, move_out_of_jump_pad_callback,
500 lwp_running, linux_set_resume_request, resume_status_pending_p,
501 need_step_over_p, start_step_over, linux_resume_one_thread,
502 proceed_one_lwp, unsuspend_and_proceed_one_lwp,
503 reset_lwp_ptrace_options_callback): Update.
504 * linux-mips-low.c (update_watch_registers_callback): Update.
505 * regcache.c (regcache_invalidate_one, regcache_invalidate):
506 Update.
507 (free_register_cache_thread_one): Remove.
508 (regcache_release): Update.
509 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt,
510 handle_qxfer_threads_worker): Update.
511 (handle_query): Update, use list iterator.
512 (visit_actioned_threads, handle_pending_status,
513 queue_stop_reply_callback, gdb_wants_all_threads_stopped,
514 clear_pending_status_callback, set_pending_status_callback,
515 find_status_pending_thread_callback, handle_status,
516 process_serial_event): Update.
517 * target.c (thread_search_callback): Update.
518 * thread-db.c (thread_db_get_tls_address): Update.
519 * tracepoint.c (tracepoint_finished_step, tracepoint_was_hit):
520 Update.
521 * win32-i386-low.c (update_debug_registers_callback): Update.
522 * win32-low.c (delete_thread_info, child_delete_thread,
523 continue_one_thread, suspend_one_thread,
524 get_child_debug_event): Adjust.
525
526 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
527
528 * gdbthread.h (ptid_of, pid_of, lwpid_of): New functions.
529 * inferiors.h: Include <list>.
530 (struct process_info) <entry>: Remove field.
531 <pid>: New field.
532 (pid_of): Change macro to function.
533 (ptid_of, lwpid_of): Remove macro.
534 (all_processes): Change type to std::list<process_info *>.
535 (ALL_PROCESSES): Remove macro.
536 (for_each_process, find_process): New function.
537 * inferiors.c (all_processes): Change type to
538 std::list<process_info *>.
539 (find_thread_process): Adjust.
540 (add_process): Likewise.
541 (remove_process): Likewise.
542 (find_process_pid): Likewise.
543 (get_first_process): Likewise.
544 (started_inferior_callback): Remove.
545 (have_started_inferiors_p): Adjust.
546 (attached_inferior_callback): Remove.
547 (have_attached_inferiors_p): Adjust.
548 * linux-low.c (check_zombie_leaders): Likewise.
549 * linux-x86-low.c (x86_arch_setup_process_callback): Remove.
550 (x86_linux_update_xmltarget): Adjust.
551 * server.c (handle_query): Likewise.
552 (gdb_reattached_process): Remove.
553 (handle_status): Adjust.
554 (kill_inferior_callback): Likewise.
555 (detach_or_kill_inferior): Remove.
556 (print_started_pid): Likewise.
557 (print_attached_pid): Likewise.
558 (detach_or_kill_for_exit): Update.
559 (process_serial_event): Likewise.
560 * linux-arm-low.c (arm_new_fork): Likewise.
561
562 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
563
564 * dll.h: Include <list>.
565 (struct dll_info): Add constructor.
566 <entry>: Remove field.
567 (all_dlls): Change type to std::list<dll_info>.
568 * dll.c: Include <algorithm>.
569 (get_dll): Remove macro.
570 (all_dlls): Change type to std::list<dll_info *>.
571 (free_one_dll): Remove.
572 (match_dll): Likewise.
573 (loaded_dll): Adjust.
574 (unloaded_dll): Adjust to all_dlls type change, use
575 std::find_if. Inline code from match_dll.
576 (clear_dlls): Adjust to all_dlls type change.
577 * server.c (emit_dll_description): Remove.
578 (handle_qxfer_libraries): Adjust to all_dlls type change,
579 integrate emit_dll_description's functionality.
580
581 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
582
583 * linux-low.h (struct linux_target_ops) <delete_process>: New
584 field.
585 * linux-low.c (linux_mourn): Call the_low_target.delete_process.
586 * linux-aarch64-low.c (aarch64_linux_delete_process): New.
587 (struct linux_target_ops): Add delete_process callback.
588 * linux-arm-low.c (arm_delete_process): New.
589 (struct linux_target_ops): Add delete_process callback.
590 * linux-bfin-low.c (struct linux_target_ops): Likewise.
591 * linux-crisv32-low.c (struct linux_target_ops): Likewise.
592 * linux-m32r-low.c (struct linux_target_ops): Likewise.
593 * linux-mips-low.c (mips_linux_delete_process): New.
594 (struct linux_target_ops): Add delete_process callback.
595 * linux-ppc-low.c (struct linux_target_ops): Likewise.
596 * linux-s390-low.c (struct linux_target_ops): Likewise.
597 * linux-sh-low.c (struct linux_target_ops): Likewise.
598 * linux-tic6x-low.c (struct linux_target_ops): Likewise.
599 * linux-tile-low.c (struct linux_target_ops): Likewise.
600 * linux-x86-low.c (x86_linux_delete_process): New.
601 (struct linux_target_ops): Add delete_process callback.
602 * linux-xtensa-low.c (struct linux_target_ops): Likewise.
603
604 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
605
606 * linux-aarch64-low.c (the_low_target): Add thread delete
607 callback.
608 * linux-arm-low.c (arm_delete_thread): New function.
609 (the_low_target): Add thread delete callback.
610 * linux-bfin-low.c (the_low_target): Likewise.
611 * linux-crisv32-low.c (the_low_target): Likewise.
612 * linux-low.c (delete_lwp): Invoke delete_thread callback if
613 set.
614 * linux-low.h (struct linux_target_ops) <delete_thread>: New
615 field.
616 * linux-m32r-low.c (the_low_target): Add thread delete callback.
617 * linux-mips-low.c (mips_linux_delete_thread): New function.
618 (the_low_target): Add thread delete callback.
619 * linux-ppc-low.c (the_low_target): Likewise.
620 * linux-s390-low.c (the_low_target): Likewise.
621 * linux-sh-low.c (the_low_target): Likewise.
622 * linux-tic6x-low.c (the_low_target): Likewise.
623 * linux-tile-low.c (the_low_target): Likewise.
624 * linux-x86-low.c (the_low_target): Likewise.
625 * linux-xtensa-low.c (the_low_target): Likewise.
626
627 2017-10-06 Yuanhui Zhang <asmwarrior@gmail.com>
628
629 * win32-low.c: Include "common-inferior.h".
630
631 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
632
633 * inferiors.c (set_inferior_cwd): New function.
634 * server.c (handle_general_set): Handle QSetWorkingDir packet.
635 (handle_query): Inform that QSetWorkingDir is supported.
636 * win32-low.c (create_process): Pass the inferior's cwd to
637 CreateProcess.
638
639 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
640
641 * inferiors.c (current_inferior_cwd): New global variable.
642 (get_inferior_cwd): New function.
643 * inferiors.h (struct process_info) <cwd>: New field.
644
645 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
646
647 * Makefile.in (SFILES): Add $(srcdir)/common/gdb_tilde_expand.c.
648 (OBS): Add gdb_tilde_expand.o.
649
650 2017-10-02 Simon Marchi <simon.marchi@ericsson.com>
651
652 * lynx-i386-low.c (lynx_i386_arch_setup): Call init_target_desc.
653 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
654
655 2017-09-29 Pedro Alves <palves@redhat.com>
656
657 * ax.c (gdb_parse_agent_expr): Constify.
658 * ax.h (gdb_parse_agent_expr): Constify.
659 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
660 Constify.
661 * mem-break.h (add_breakpoint_condition, add_breakpoint_commands): Constify.
662 * remote-utils.c (hex_or_minus_one, read_ptid): Constify.
663 * remote-utils.h (read_ptid): Constify.
664 * server.c (handle_qxfer_exec_file, handle_query, handle_v_cont)
665 (process_point_options, process_serial_event): Constify.
666 * tracepoint.c (add_tracepoint_action, cmd_qtdp, cmd_qtdpsrc)
667 (cmd_qtdv, cmd_qtenable_disable, cmd_qtro, cmd_qtframe, cmd_qtp)
668 (cmd_qtbuffer): Constify.
669
670 2017-09-29 Pedro Alves <palves@redhat.com>
671
672 * proc-service.c (ps_pdread): Return PS_ERR if reading memory
673 fails.
674
675 2017-09-29 Pedro Alves <palves@redhat.com>
676
677 * linux-low.c (handle_extended_wait): Pass parent thread instead
678 of process to thread_db_notice_clone.
679 * linux-low.h (thread_db_notice_clone): Replace parent process
680 parameter with parent thread parameter.
681 * thread-db.c (find_one_thread): Add comment.
682 (thread_db_notice_clone): Replace parent process parameter with
683 parent thread parameter. Temporarily switch to the parent thread.
684
685 2017-09-26 Sergio Durigan Junior <sergiodj@redhat.com>
686
687 * gdbthread.h: Include "common-gdbthread.h".
688 * inferiors.c (switch_to_thread): Use "gdb_assert" instead of
689 "if" when validating the ptid.
690 * remote-utils.c: Include "gdbthread.h".
691 (prepare_resume_reply): Use "switch_to_thread".
692 * target.c (done_accessing_memory): Likewise.
693
694 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
695
696 * configure.srv (s390*-*-linux*): Add s390-gs-linux64.o and
697 s390x-gs-linux64.o to srv_regobj. Add s390-gs-linux64.xml,
698 s390x-gs-linux64.xml, s390-gs.xml, and s390-gsbc.xml to
699 srv_xmlfiles. Add s390-gs-linux64-ipa.o and
700 s390x-gs-linux64-ipa.o to ipa_obj.
701 * linux-s390-low.c (HWCAP_S390_GS): New define.
702 (s390_fill_gs, s390_store_gs, s390_fill_gsbc, s390_store_gsbc):
703 New functions.
704 (s390_regsets): Add regsets for NT_S390_GS_CB and NT_S390_GS_BC.
705 (s390_arch_setup): Check for guarded-storage support and choose
706 appropriate tdesc.
707 (initialize_low_arch): Invoke init_registers_s390_gs_linux64 and
708 init_registers_s390x_gs_linux64.
709 * linux-s390-tdesc.h (enum s390_linux_tdesc) <S390_TDESC_GS>: New
710 enum value.
711 (init_registers_s390x_gs_linux64, tdesc_s390x_gs_linux64)
712 (init_registers_s390_gs_linux64, tdesc_s390_gs_linux64): Declare.
713
714 2017-09-22 Simon Marchi <simon.marchi@ericsson.com>
715
716 * win32-i386-low.c (i386_arch_setup): Call init_target_desc.
717
718 2017-09-21 Kevin Buettner <kevinb@redhat.com>
719
720 * linux-low.h (struct lwp_info): Add new field, thread_handle.
721 (thread_db_thread_handle): Declare.
722 * linux-low.c (linux_target_ops): Initialize thread_handle.
723 * server.c (handle_qxfer_threads_worker): Add support for
724 "handle" attribute.
725 * target.h (struct target_ops): Add new function pointer,
726 thread_handle.
727 (target_thread_handle): Define.
728 * thread-db.c (find_one_thread, attach_thread): Set thread_handle
729 field in lwp.
730 (thread_db_thread_handle): New function.
731
732 2017-09-21 Kevin Buettner <kevinb@redhat.com>
733
734 * linux-low.c (handle_extended_wait): Call thread_db_notice_clone().
735 * linux-low.h (thread_db_notice_clone): Declare.
736 * thread-db.c (thread_db_notice_clone): New function.
737
738 2017-09-21 Pedro Alves <palves@redhat.com>
739
740 * server.c (gdb_read_memory, handle_status, process_serial_event)
741 (handle_serial_event, handle_target_event): Adjust to
742 set_desired_thread prototype change.
743 * target.c (set_desired_thread): Remove 'use_general' parameter
744 and adjust.
745 * target.h (set_desired_thread): Remove 'use_general' parameter.
746
747 2017-09-20 Tom Tromey <tom@tromey.com>
748
749 * target.c (target_terminal::terminal_state): Define.
750 (target_terminal::init): Rename from target_terminal_init.
751 (target_terminal::inferior): Rename from
752 target_terminal_inferior.
753 (target_terminal::ours): Rename from target_terminal_ours.
754 (target_terminal::ours_for_output, target_terminal::info): New.
755
756 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
757
758 * server.c (accumulate_file_name_length): Remove.
759 (emit_dll_description): Adjust to std::string change.
760 (handle_qxfer_libraries): Use std::string to hold document.
761
762 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
763
764 * linux-low.c (linux_qxfer_libraries_svr4): Adjust to change of
765 return type of xml_escape_text.
766 * server.c (emit_dll_description): Likewise.
767
768 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
769
770 * server.c (captured_main): Accept argument for --selftest.
771 Update run_tests call.
772 * linux-x86-tdesc-selftest.c (initialize_low_tdesc): Add names
773 when registering selftests.
774
775 2017-09-16 Sergio Durigan Junior <sergiodj@redhat.com>
776
777 * regcache.c (get_thread_regcache): Update code to use "std::vector"
778 instead of "VEC" for "target_desc.reg_defs".
779 (regcache_cpy): Likewise.
780 (registers_to_string): Likewise.
781 (registers_from_string): Likewise.
782 (find_regno): Likewise.
783 (supply_regblock): Likewise.
784 (regcache_raw_read_unsigned): Likewise.
785 * tdesc.c (init_target_desc): Likewise.
786 (tdesc_create_reg): Likewise.
787 * tdesc.h: Remove declaration of "tdesc_reg_p". Include <vector>.
788 (struct target_desc) <reg_defs>: Convert to "std::vector".
789 (target_desc): Do not initialize "reg_defs".
790 (~target_desc): Update code to use "std::vector" instead of "VEC"
791 for "target_desc.reg_defs".
792 (operator==): Likewise.
793
794 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
795
796 * inferiors.h (thread_to_gdb_id): Remove.
797 * inferiors.c (thread_to_gdb_id): Remove.
798 * server.c (handle_qxfer_threads_worker, handle_query): Adjust.
799 * lynx-low.c (lynx_resume, lynx_wait_1, lynx_fetch_registers,
800 lynx_store_registers, lynx_read_memory, lynx_write_memory):
801 Likewise.
802 * nto-low.c (nto_fetch_registers, nto_store_registers,
803 nto_stopped_by_watchpoint, nto_stopped_data_address): Likewise.
804
805 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
806
807 * inferiors.h (gdb_id_to_thread_id): Remove.
808 * inferiors.c (gdb_id_to_thread_id): Remove.
809 * server.c (process_serial_event): Adjust to gdb_id_to_thread_id
810 removal. Move pid declaration closer to where it's used.
811
812 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
813
814 * server.c (handle_detach): New function.
815 (process_serial_event): Move code out, call handle_detach.
816
817 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
818
819 * server.c (require_running): Rename to ...
820 (require_running_or_return): ... this ...
821 (require_running_or_break): ... and this.
822 (handle_query, process_serial_event): Adjust.
823
824 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
825
826 * linux-low.c (linux_set_resume_request): Remove unused
827 variables.
828
829 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
830
831 * server.c (first_thread_of): Remove.
832 (process_serial_event): Replace usage of first_thread_of with
833 find_any_thread_of_pid.
834 * tracepoint.c (same_process_p): Remove.
835 (gdb_agent_about_to_close): Replace usage of same_process_p with
836 find_any_thread_of_pid.
837 * linux-x86-low.c (same_process_callback): Remove.
838 (x86_arch_setup_process_callback): Replace usage of
839 same_process_callback with find_any_thread_of_pid.
840 * thread-db.c (any_thread_of): Remove.
841 (switch_to_process): Replace usage of any_thread_of with
842 find_any_thread_of_pid.
843 * inferiors.c (thread_pid_matches_callback): Remove.
844 (find_thread_process): Adjust to use find_any_thread_of_pid.
845
846 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
847
848 * regcache.c (get_thread_regcache): Guard calls to "memset"
849 with "!VEC_empty".
850
851 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
852
853 * linux-low.c (handle_extended_wait): Use
854 "allocate_target_description" instead of "XNEW".
855 * linux-x86-low.c (initialize_low_arch): Likewise.
856
857 2017-09-05 Yao Qi <yao.qi@linaro.org>
858
859 * configure.srv (srv_i386_regobj): Remove.
860 (srv_amd64_regobj): Remove.
861 (srv_regobj): Set it to "" for x86 non-linux targets.
862 * linux-x86-tdesc.c (i386_linux_read_description):
863 * lynx-i386-low.c: Include x86-xstate.h and arch/i386.h.
864 (init_registers_i386): Remove the declaration.
865 (tdesc_i386): Remove the declaration.
866 (lynx_i386_arch_setup): Call i386_create_target_description.
867 * nto-x86-low.c: Likewise.
868 * win32-i386-low.c [__x86_64__]: include arch/amd64.h.
869 [!__x86_64__]: include arch/i386.h.
870 (i386_arch_setup) [__x86_64__]: Call amd64_create_target_description.
871
872 2017-09-05 Yao Qi <yao.qi@linaro.org>
873
874 * configure.srv (srv_amd64_linux_xmlfiles): Remove
875 i386/amd64-XXX-linux from it.
876
877 2017-09-05 Yao Qi <yao.qi@linaro.org>
878
879 * configure.srv: Empty srv_amd64_linux_regobj if $development is
880 false.
881 (ipa_amd64_linux_regobj): Remove.
882 (ipa_x32_linux_regobj): Remove.
883
884 2017-09-05 Yao Qi <yao.qi@linaro.org>
885
886 * Makefile.in (arch-amd64.o): New rule.
887 * configure.srv: Append arch-amd64.o.
888 * linux-amd64-ipa.c: Include common/x86-xstate.h.
889 (get_ipa_tdesc): Call amd64_linux_read_description.
890 (initialize_low_tracepoint): Don't call init_registers_x32_XXX
891 and init_registers_amd64_XXX.
892 * linux-x86-low.c (x86_linux_read_description): Call
893 amd64_linux_read_description.
894 (x86_get_ipa_tdesc_idx): Call amd64_get_ipa_tdesc_idx.
895 (initialize_low_arch): Don't call init_registers_x32_XXX and
896 init_registers_amd64_XXX.
897 * linux-x86-tdesc-selftest.c: Declare init_registers_amd64_XXX
898 and tdesc_amd64_XXX.
899 [__x86_64__] (amd64_tdesc_test): New function.
900 (initialize_low_tdesc) [__x86_64__]: Call init_registers_x32_XXX
901 and init_registers_amd64_XXX.
902 * linux-x86-tdesc.c: Include arch/amd64.h.
903 (xcr0_to_tdesc_idx): New function.
904 (i386_linux_read_description): New function.
905 (amd64_get_ipa_tdesc_idx): New function.
906 * linux-x86-tdesc.h (amd64_get_ipa_tdesc_idx): Declare.
907 (amd64_get_ipa_tdesc): Declare.
908
909 2017-09-05 Yao Qi <yao.qi@linaro.org>
910
911 * configure.srv (srv_i386_linux_xmlfiles): Remove
912 i386/i386-XXX-linux.xml from it.
913
914 2017-09-05 Yao Qi <yao.qi@linaro.org>
915
916 * configure.srv: Set srv_i386_linux_regobj empty if $development
917 is false.
918 * linux-i386-ipa.c (initialize_low_tracepoint): Don't call
919 initialize_low_tdesc.
920 * linux-x86-low.c (initialize_low_arch): Wrap initialize_low_tdesc
921 with #if initialize_low_tdesc.
922 * linux-x86-tdesc-selftest.c: New file.
923 * linux-x86-tdesc.c: Move code to linux-x86-tdesc-selftest.c.
924
925 2017-09-05 Yao Qi <yao.qi@linaro.org>
926
927 * Makefile.in (arch-i386.o): New rule.
928 * configure.srv (i[34567]86-*-linux*): Add arch-i386.o.
929 (x86_64-*-linux*): Likewise.
930 * linux-x86-tdesc.c: Don't include ../features/i386/32bit-XXX.c,
931 include arch/i386.h.
932 (i386_linux_read_description): Remove code and call
933 i386_create_target_description.
934 * tdesc.c (allocate_target_description): New function.
935 * tdesc.h (set_tdesc_architecture): Remove declaration.
936 (set_tdesc_osabi): Likewise.
937
938 2017-09-05 Yao Qi <yao.qi@linaro.org>
939
940 * linux-x86-tdesc.c: Don't include <inttypes.h>.
941 (i386_linux_read_description) [!IN_PROCESS_AGENT]: Call
942 set_tdesc_architecture and set_tdesc_osabi. Remove code setting
943 .xmltarget.
944 * server.c (get_features_xml): Call tdesc_get_features_xml.
945 * tdesc.c (set_tdesc_architecture): New function.
946 (set_tdesc_osabi): New function.
947 (tdesc_get_features_xml): New function.
948 (tdesc_create_feature): Add an argument.
949 * tdesc.h (struct target_desc) <features>: New field.
950 <arch, osabi>: New field.
951 (~target_desc): xfree features, arch, and osabi.
952 (target_desc::oerator==): Don't compare .xmltarget.
953 [!IN_PROCESS_AGENT] (set_tdesc_architecture): Declare.
954 (set_tdesc_osabi): Likewise.
955 (tdesc_get_features_xml): Likewise.
956
957 2017-09-05 Yao Qi <yao.qi@linaro.org>
958
959 * linux-x86-tdesc.c: Include selftest.h.
960 (i386_tdesc_test): New function.
961 (initialize_low_tdesc): Call selftests::register_test.
962 * tdesc.h: Include regdef.h.
963 (target_desc): Override operator == and !=.
964
965 2017-09-05 Yao Qi <yao.qi@linaro.org>
966
967 * configure.srv (srv_tgtobj): Append linux-x86-tdesc.o.
968 (ipa_obj): Likewise.
969 * linux-i386-ipa.c: Include common/x86-xstate.h
970 (get_ipa_tdesc): Call i386_linux_read_description.
971 (initialize_low_tracepoint): Don't call init_registers_XXX
972 functions, call initialize_low_tdesc instead.
973 * linux-x86-low.c (x86_linux_read_description): Call
974 i386_linux_read_description.
975 (initialize_low_arch): Don't call init_registers_i386_XXX
976 functions, call initialize_low_tdesc.
977 * linux-x86-tdesc.c: New file.
978 * linux-x86-tdesc.h (x86_linux_tdesc): New X86_TDESC_LAST.
979 (i386_get_ipa_tdesc_idx): Declare.
980 (i386_get_ipa_tdesc): Declare.
981 (initialize_low_tdesc): Declare.
982
983 2017-09-05 Yao Qi <yao.qi@linaro.org>
984
985 * linux-x86-low.c (x86_get_ipa_tdesc_idx): Use X86_TDESC_MMX
986 instead of 0.
987
988 2017-09-05 Yao Qi <yao.qi@linaro.org>
989
990 * Makefile.in (IPA_OBJS): Add vec-ipa.o
991 * regcache.c (get_thread_regcache): Use VEC_length.
992 (init_register_cache): Likewise.
993 (regcache_cpy): Likewise.
994 (registers_to_string): Iterate reg_defs via VEC_iterate.
995 (find_regno): Likewise.
996 (find_register_by_number): Use VEC_index.
997 (register_size): Call find_register_by_number.
998 (register_data): Call find_register_by_number.
999 (supply_regblock): Use VEC_length.
1000 (regcache_raw_read_unsigned): Likewise.
1001 * tdesc.c (init_target_desc): Iterate reg_defs via
1002 VEC_iterate.
1003 (default_description): Update initializer.
1004 (copy_target_description): Don't update field num_registers.
1005 * tdesc.h (struct target_desc) <reg_defs>: Change it to VEC.
1006 <num_registers>: Remove.
1007
1008 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
1009
1010 * Makefile.in (.SECONDARY): Define target.
1011
1012 2017-09-03 Simon Marchi <simon.marchi@ericsson.com>
1013
1014 * linux-low.c (linux_wait_1): Adjust.
1015 * server.c (queue_stop_reply_callback): Adjust.
1016
1017 2017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
1018
1019 * server.c (handle_general_set): Handle QEnvironmentHexEncoded,
1020 QEnvironmentUnset and QEnvironmentReset packets.
1021 (handle_query): Inform remote that QEnvironmentHexEncoded,
1022 QEnvironmentUnset and QEnvironmentReset are supported.
1023
1024 2017-08-25 Simon Marchi <simon.marchi@ericsson.com>
1025
1026 * inferiors.h (inferior_target_data): Rename to ...
1027 (thread_target_data): ... this.
1028 (inferior_regcache_data): Rename to ...
1029 (thread_regcache_data): ... this.
1030 (set_inferior_regcache_data): Rename to ...
1031 (set_thread_regcache_data): ... this.
1032 * inferiors.c (inferior_target_data): Rename to ...
1033 (thread_target_data): ... this.
1034 (inferior_regcache_data): Rename to ...
1035 (thread_regcache_data): ... this.
1036 (set_inferior_regcache_data): Rename to ...
1037 (set_thread_regcache_data): ... this.
1038 (free_one_thread): Update.
1039 * linux-low.h (get_thread_lwp): Update.
1040 * regcache.c (get_thread_regcache): Update.
1041 (regcache_invalidate_thread): Update.
1042 (free_register_cache_thread): Update.
1043 * win32-i386-low.c (update_debug_registers_callback): Update.
1044 (win32_get_current_dr): Update.
1045 * win32-low.c (thread_rec): Update.
1046 (delete_thread_info): Update.
1047 (continue_one_thread): Update.
1048 (suspend_one_thread): Update.
1049
1050 2017-08-24 Simon Marchi <simon.marchi@ericsson.com>
1051
1052 * inferiors.c (set_inferior_target_data): Remove.
1053 * inferiors.h (set_inferior_target_data): Remove.
1054
1055 2017-08-18 Yao Qi <yao.qi@linaro.org>
1056
1057 * Makefile.in (OBS): Add selftest.o.
1058 * configure.ac: AC_DEFINE GDB_SELF_TEST if $development.
1059 * configure, config.in: Re-generated.
1060 * server.c: Include common/sefltest.h.
1061 (captured_main): Handle option --selftest.
1062
1063 2017-08-09 Yao Qi <yao.qi@linaro.org>
1064
1065 * configure.srv (srv_i386_regobj): Remove i386-avx.o,
1066 i386-avx-avx512.o, i386-avx-mpx-avx512-pku.o, i386-mpx.o,
1067 i386-avx-mpx.o and i386-mmx.o.
1068 (srv_amd64_regobj): Remove amd64-avx.o, amd64-avx-avx512.o,
1069 amd64-avx-mpx-avx512-pku.o, amd64-mpx.o and amd64-avx-mpx.o.
1070 (srv_i386_xmlfiles): Remove i386/i386-avx.xml,
1071 i386/i386-avx-avx512.xml, i386/i386-avx-mpx-avx512-pku.xml,
1072 i386/i386-mpx.xml, i386/i386-avx-mpx.xml and i386/i386-mmx.xml.
1073 (srv_amd64_xmlfile):i386/amd64-avx.xml, i386/amd64-avx-avx512.xml,
1074 i386/amd64-avx-mpx-avx512-pku.xml, i386/amd64-mpx.xml,
1075 i386/amd64-avx-mpx.xml.
1076
1077 2017-08-09 Yao Qi <yao.qi@linaro.org>
1078
1079 * configure.srv (srv_amd64_regobj): Remove x32.o, x32-avx.o
1080 and x32-avx-avx512.o.
1081 (srv_amd64_xmlfiles): Remove i386/x32.xml, i386/x32-avx.xml
1082 i386/x32-avx-avx512.xml.
1083
1084 2017-07-26 Simon Marchi <simon.marchi@ericsson.com>
1085
1086 * tracepoint.h (enum class fast_tpoint_collect_result): New
1087 enumeration.
1088 (fast_tracepoint_collecting): Change return type to
1089 fast_tpoint_collect_result.
1090 * tracepoint.c (fast_tracepoint_collecting): Likewise.
1091 * linux-low.h: Include tracepoint.h.
1092 (struct lwp_info) <collecting_fast_tracepoint>: Change type to
1093 fast_tpoint_collect_result.
1094 * linux-low.c (handle_tracepoints): Adjust.
1095 (linux_fast_tracepoint_collecting): Change return type to
1096 fast_tpoint_collect_result.
1097 (maybe_move_out_of_jump_pad, linux_wait_for_event_filtered,
1098 linux_wait_1, stuck_in_jump_pad_callback,
1099 lwp_signal_can_be_delivered, linux_resume_one_lwp_throw,
1100 proceed_one_lwp): Adjust to type change.
1101
1102 2017-07-10 Yao Qi <yao.qi@linaro.org>
1103
1104 * linux-x86-low.c (x86_linux_read_description): Re-indent the code.
1105
1106 2017-06-29 Yao Qi <yao.qi@linaro.org>
1107
1108 * tdesc.h (struct target_desc) [IN_PROCESS_AGENT] <expedite_regs>:
1109 Remove.
1110 [IN_PROCESS_AGENT] <xmltarget>: Likewise.
1111
1112 2017-06-20 Simon Marchi <simon.marchi@ericsson.com>
1113
1114 * Makefile.in (IPA_OBJS): Sort and format one item per line.
1115
1116 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
1117
1118 * linux-low.c (linux_create_inferior): Adjust code to access the
1119 environment information via 'gdb_environ' class.
1120 * lynx-low.c (lynx_create_inferior): Likewise.
1121 * server.c (our_environ): Make it an instance of 'gdb_environ'.
1122 (get_environ): Return a pointer to 'our_environ'.
1123 (captured_main): Initialize 'our_environ'.
1124 * server.h (get_environ): Adjust prototype.
1125 * spu-low.c (spu_create_inferior): Adjust code to access the
1126 environment information via 'gdb_environ' class.
1127
1128 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
1129
1130 * linux-low.c (linux_read_memory, linux_write_memory): Remove
1131 usage of "register" keyword.
1132
1133 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
1134
1135 * configure: Re-generate.
1136
1137 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
1138
1139 * configure: Re-generate.
1140
1141 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
1142
1143 * Makefile.in (COMPILE.pre): Add "-x c++".
1144
1145 2017-06-09 Sergio Durigan Junior <sergiodj@redhat.com>
1146
1147 * fork-child.c: Conditionally include <signal.h>.
1148
1149 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
1150
1151 * server.c (handle_general_set): Handle new packet
1152 "QStartupWithShell".
1153 (handle_query): Add "QStartupWithShell" to the list of supported
1154 packets.
1155 (gdbserver_usage): Add help text explaining the
1156 new "--startup-with-shell" and "--no-startup-with-shell" CLI
1157 options.
1158 (captured_main): Recognize and act upon the presence of the new
1159 CLI options.
1160
1161 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
1162 Pedro Alves <palves@redhat.com>
1163
1164 * Makefile.in (SFILES): Add "nat/fork-inferior.o".
1165 * configure: Regenerate.
1166 * configure.srv (srv_linux_obj): Add "fork-child.o" and
1167 "fork-inferior.o".
1168 (i[34567]86-*-lynxos*): Likewise.
1169 (spu*-*-*): Likewise.
1170 * fork-child.c: New file.
1171 * linux-low.c: Include "common-inferior.h", "nat/fork-inferior.h"
1172 and "environ.h".
1173 (linux_ptrace_fun): New function.
1174 (linux_create_inferior): Adjust function prototype to reflect
1175 change on "target.h". Adjust function code to use
1176 "fork_inferior".
1177 (linux_request_interrupt): Delete "signal_pid".
1178 * lynx-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
1179 (lynx_ptrace_fun): New function.
1180 (lynx_create_inferior): Adjust function prototype to reflect
1181 change on "target.h". Adjust function code to use
1182 "fork_inferior".
1183 * nto-low.c (nto_create_inferior): Adjust function prototype and
1184 code to reflect change on "target.h". Update comments.
1185 * server.c: Include "common-inferior.h", "nat/fork-inferior.h",
1186 "common-terminal.h" and "environ.h".
1187 (terminal_fd): Moved to fork-child.c.
1188 (old_foreground_pgrp): Likewise.
1189 (restore_old_foreground_pgrp): Likewise.
1190 (last_status): Make it global.
1191 (last_ptid): Likewise.
1192 (our_environ): New variable.
1193 (startup_with_shell): Likewise.
1194 (program_name): Likewise.
1195 (program_argv): Rename to...
1196 (program_args): ...this.
1197 (wrapper_argv): New variable.
1198 (start_inferior): Delete function.
1199 (get_exec_wrapper): New function.
1200 (get_exec_file): Likewise.
1201 (get_environ): Likewise.
1202 (prefork_hook): Likewise.
1203 (post_fork_inferior): Likewise.
1204 (postfork_hook): Likewise.
1205 (postfork_child_hook): Likewise.
1206 (handle_v_run): Update code to deal with arguments coming from the
1207 remote host. Update calls from "start_inferior" to
1208 "create_inferior".
1209 (captured_main): Likewise. Initialize environment variable. Call
1210 "have_job_control".
1211 * server.h (post_fork_inferior): New prototype.
1212 (get_environ): Likewise.
1213 (last_status): Declare.
1214 (last_ptid): Likewise.
1215 (signal_pid): Likewise.
1216 * spu-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
1217 (spu_ptrace_fun): New function.
1218 (spu_create_inferior): Adjust function prototype to reflect change
1219 on "target.h". Adjust function code to use "fork_inferior".
1220 * target.c (target_terminal_init): New function.
1221 (target_terminal_inferior): Likewise.
1222 (target_terminal_ours): Likewise.
1223 * target.h: Include <vector>.
1224 (struct target_ops) <create_inferior>: Update prototype.
1225 (create_inferior): Update macro.
1226 * utils.c (gdb_flush_out_err): New function.
1227 * win32-low.c (win32_create_inferior): Adjust function prototype
1228 and code to reflect change on "target.h".
1229
1230 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
1231
1232 * inferiors.c (switch_to_thread): New function.
1233
1234 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
1235
1236 * Makefile.in (SFILE): Add "common/job-control.c".
1237 (OBS): Add "job-control.o".
1238
1239 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
1240
1241 * Makefile: Remove "@host_makefile_frag@".
1242
1243 2017-05-05 Pedro Alves <palves@redhat.com>
1244
1245 * configure: Regenerate.
1246
1247 2017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
1248
1249 * configure: Regenerate.
1250
1251 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
1252
1253 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Adjust to
1254 software_single_step change of return type to
1255 std::vector<CORE_ADDR>.
1256 * linux-low.c (install_software_single_step_breakpoints):
1257 Likewise.
1258 * linux-low.h (install_software_single_step_breakpoints):
1259 Likewise.
1260
1261 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
1262
1263 * remote-utils.c: Include "gdb_termios.h" instead of
1264 "terminal.h".
1265 * terminal.h: Delete file.
1266
1267 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
1268
1269 * server.c: Include <vector>.
1270 <program_argv, wrapper_argv>: Convert to std::vector.
1271 (start_inferior): Rewrite function to use C++.
1272 (handle_v_run): Likewise. Update code that calculates the argv
1273 based on the vRun packet; use C++.
1274 (captured_main): Likewise.
1275
1276 2017-04-06 Simon Marchi <simon.marchi@ericsson.com>
1277
1278 * server.c (handle_v_cont): Initialize thread_resume::thread
1279 with null_ptid.
1280
1281 2017-04-05 Pedro Alves <palves@redhat.com>
1282
1283 * configure: Regenerate.
1284
1285 2017-04-05 Pedro Alves <palves@redhat.com>
1286
1287 * gdbreplay.c (sync_error): Constify.
1288 * linux-x86-low.c (push_opcode): Constify.
1289
1290 2017-04-05 Pedro Alves <palves@redhat.com>
1291
1292 * win32-low.c (get_child_debug_event)
1293 <CREATE_PROCESS_DEBUG_EVENT>: Don't report TARGET_WAITKIND_EXECD.
1294 Report TARGET_WAITKIND_SPURIOUS instead.
1295
1296 2017-04-05 Pedro Alves <palves@redhat.com>
1297
1298 * remote-utils.c (remote_prepare, remote_open): Constify.
1299 * remote-utils.h (remote_prepare, remote_open): Constify.
1300 * server.c (captured_main): Constify 'port' handling.
1301
1302 2017-04-04 Simon Marchi <simon.marchi@ericsson.com>
1303
1304 * Makefile.in (clean): Clear .deps.
1305
1306 2017-03-31 Simon Marchi <simon.marchi@polymtl.ca>
1307
1308 * .gitignore: Remove generated files, replace with wildcard.
1309 * (clean): Replace removal of generated files with wildcard.
1310 (version.c): Replace with...
1311 (version-generated.c): ...this.
1312 (xml-builtin.c): Replace with...
1313 (xml-builtin-generated.c): ...this.
1314 (%-ipa.o: %-generated.c, %.o: %-generated.c): New rules.
1315 (%.c: *regformats*): Replace with...
1316 (%-generated.c: *regformats*): ...this.
1317
1318 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
1319
1320 * linux-xtensa-low.c (regnum::R_THREADPTR): New enum member.
1321 (xtensa_fill_gregset): Call collect_register_by_name for
1322 threadptr register.
1323 (xtensa_store_gregset): Call supply_register_by_name for
1324 threadptr register.
1325
1326 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
1327
1328 * linux-xtensa-low.c (xtensa_fill_gregset): Call collect_register
1329 for all registers in a0_regnum..a0_regnum + C0_NREGS range.
1330 (xtensa_store_gregset): Call supply_register for all registers in
1331 a0_regnum..a0_regnum + C0_NREGS range.
1332
1333 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
1334
1335 * Makefile.in (%-ipa.o: %-ipa.c): New rule.
1336 (ax-ipa.o: ax.c): Remove.
1337 (linux-i386-ipa.o: linux-i386-ipa.c): Remove.
1338 (linux-amd64-ipa.o: linux-amd64-ipa.c): Remove.
1339 (linux-aarch64-ipa.o: linux-aarch64-ipa.c): Remove.
1340 (linux-s390-ipa.o: linux-s390-ipa.c): Remove.
1341 (linux-ppc-ipa.o: linux-ppc-ipa.c): Remove.
1342
1343 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
1344
1345 * Makefile.in (%-ipa.o: ../common/%.c): New rule.
1346 (print-utils-ipa.o: ../common/print-utils.c): Remove.
1347 (rsp-low-ipa.o: ../common/rsp-low.c): Remove.
1348 (errors-ipa.o: ../common/errors.c): Remove.
1349 (format-ipa.o: ../common/format.c): Remove.
1350 (common-utils-ipa.o: ../common/common-utils.c): Remove.
1351
1352 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
1353
1354 * Makefile.in (%-ipa.o: %.c): New rule.
1355 (tracepoint-ipa.o: tracepoint.c): Remove.
1356 (utils-ipa.o: utils.c): Remove.
1357 (remote-utils-ipa.o: remote-utils.c): Remove.
1358 (regcache-ipa.o: regcache.c): Remove.
1359 (i386-linux-ipa.o: i386-linux.c): Remove.
1360 (i386-mmx-linux-ipa.o: i386-mmx-linux.c): Remove.
1361 (i386-avx-linux-ipa.o: i386-avx-linux.c): Remove.
1362 (i386-mpx-linux-ipa.o: i386-mpx-linux.c): Remove.
1363 (i386-avx-mpx-linux-ipa.o: i386-avx-mpx-linux.c): Remove.
1364 (i386-avx-avx512-linux-ipa.o: i386-avx-avx512-linux.c): Remove.
1365 (i386-avx-mpx-avx512-pku-linux-ipa.o: i386-avx-mpx-avx512-pku-linux.c): Remove.
1366 (amd64-linux-ipa.o: amd64-linux.c): Remove.
1367 (amd64-avx-linux-ipa.o: amd64-avx-linux.c): Remove.
1368 (amd64-mpx-linux-ipa.o: amd64-mpx-linux.c): Remove.
1369 (amd64-avx-mpx-linux-ipa.o: amd64-avx-mpx-linux.c): Remove.
1370 (amd64-avx-avx512-linux-ipa.o: amd64-avx-avx512-linux.c): Remove.
1371 (amd64-avx-mpx-avx512-pku-linux-ipa.o: amd64-avx-mpx-avx512-pku-linux.c): Remove.
1372 (aarch64-ipa.o: aarch64.c): Remove.
1373 (s390-linux32-ipa.o: s390-linux32.c): Remove.
1374 (s390-linux32v1-ipa.o: s390-linux32v1.c): Remove.
1375 (s390-linux32v2-ipa.o: s390-linux32v2.c): Remove.
1376 (s390-linux64-ipa.o: s390-linux64.c): Remove.
1377 (s390-linux64v1-ipa.o: s390-linux64v1.c): Remove.
1378 (s390-linux64v2-ipa.o: s390-linux64v2.c): Remove.
1379 (s390-te-linux64-ipa.o: s390-te-linux64.c): Remove.
1380 (s390-vx-linux64-ipa.o: s390-vx-linux64.c): Remove.
1381 (s390-tevx-linux64-ipa.o: s390-tevx-linux64.c): Remove.
1382 (s390x-linux64-ipa.o: s390x-linux64.c): Remove.
1383 (s390x-linux64v1-ipa.o: s390x-linux64v1.c): Remove.
1384 (s390x-linux64v2-ipa.o: s390x-linux64v2.c): Remove.
1385 (s390x-te-linux64-ipa.o: s390x-te-linux64.c): Remove.
1386 (s390x-vx-linux64-ipa.o: s390x-vx-linux64.c): Remove.
1387 (s390x-tevx-linux64-ipa.o: s390x-tevx-linux64.c): Remove.
1388 (powerpc-32l-ipa.o: powerpc-32l.c): Remove.
1389 (powerpc-altivec32l-ipa.o: powerpc-altivec32l.c): Remove.
1390 (powerpc-cell32l-ipa.o: powerpc-cell32l.c): Remove.
1391 (powerpc-vsx32l-ipa.o: powerpc-vsx32l.c): Remove.
1392 (powerpc-isa205-32l-ipa.o: powerpc-isa205-32l.c): Remove.
1393 (powerpc-isa205-altivec32l-ipa.o: powerpc-isa205-altivec32l.c): Remove.
1394 (powerpc-isa205-vsx32l-ipa.o: powerpc-isa205-vsx32l.c): Remove.
1395 (powerpc-e500l-ipa.o: powerpc-e500l.c): Remove.
1396 (powerpc-64l-ipa.o: powerpc-64l.c): Remove.
1397 (powerpc-altivec64l-ipa.o: powerpc-altivec64l.c): Remove.
1398 (powerpc-cell64l-ipa.o: powerpc-cell64l.c): Remove.
1399 (powerpc-vsx64l-ipa.o: powerpc-vsx64l.c): Remove.
1400 (powerpc-isa205-64l-ipa.o: powerpc-isa205-64l.c): Remove.
1401 (powerpc-isa205-altivec64l-ipa.o: powerpc-isa205-altivec64l.c): Remove.
1402 (powerpc-isa205-vsx64l-ipa.o: powerpc-isa205-vsx64l.c): Remove.
1403 (tdesc-ipa.o: tdesc.c): Remove.
1404 (x32-linux-ipa.o: x32-linux.c): Remove.
1405 (x32-avx-linux-ipa.o: x32-avx-linux.c): Remove.
1406 (x32-avx512-linux-ipa.o: x32-avx512-linux.c): Remove.
1407
1408 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
1409
1410 * Makefile.in (%.o: ../arch/%.c): New rule.
1411 (arm.o: ../arch/arm.c): Remove.
1412 (arm-linux.o: ../arch/arm-linux.c): Remove.
1413 (arm-get-next-pcs.o: ../arch/arm-get-next-pcs.c): Remove.
1414 (aarch64-insn.o: ../arch/aarch64-insn.c): Remove.
1415
1416 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
1417
1418 * Makefile.in (%.o: ../nat/%.c): New rule.
1419 (x86-dregs.o: ../nat/x86-dregs.c): Remove.
1420 (amd64-linux-siginfo.o: ../nat/amd64-linux-siginfo.c): Remove.
1421 (linux-btrace.o: ../nat/linux-btrace.c): Remove.
1422 (linux-osdata.o: ../nat/linux-osdata.c): Remove.
1423 (linux-procfs.o: ../nat/linux-procfs.c): Remove.
1424 (linux-ptrace.o: ../nat/linux-ptrace.c): Remove.
1425 (linux-waitpid.o: ../nat/linux-waitpid.c): Remove.
1426 (mips-linux-watch.o: ../nat/mips-linux-watch.c): Remove.
1427 (ppc-linux.o: ../nat/ppc-linux.c): Remove.
1428 (linux-personality.o: ../nat/linux-personality.c): Remove.
1429 (aarch64-linux-hw-point.o: ../nat/aarch64-linux-hw-point.c): Remove.
1430 (aarch64-linux.o: ../nat/aarch64-linux.c): Remove.
1431 (x86-linux.o: ../nat/x86-linux.c): Remove.
1432 (x86-linux-dregs.o: ../nat/x86-linux-dregs.c): Remove.
1433 (linux-namespaces.o: ../nat/linux-namespaces.c): Remove.
1434
1435 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
1436
1437 * Makefile.in (%.o: ../common/%.c): New rule.
1438 (signals.o: ../common/signals.c): Remove.
1439 (print-utils.o: ../common/print-utils.c): Remove.
1440 (rsp-low.o: ../common/rsp-low.c): Remove.
1441 (common-utils.o: ../common/common-utils.c): Remove.
1442 (posix-strerror.o: ../common/posix-strerror.c): Remove.
1443 (mingw-strerror.o: ../common/mingw-strerror.c): Remove.
1444 (vec.o: ../common/vec.c): Remove.
1445 (gdb_vecs.o: ../common/gdb_vecs.c): Remove.
1446 (xml-utils.o: ../common/xml-utils.c): Remove.
1447 (ptid.o: ../common/ptid.c): Remove.
1448 (buffer.o: ../common/buffer.c): Remove.
1449 (format.o: ../common/format.c): Remove.
1450 (filestuff.o: ../common/filestuff.c): Remove.
1451 (agent.o: ../common/agent.c): Remove.
1452 (errors.o: ../common/errors.c): Remove.
1453 (environ.o: ../common/environ.c): Remove.
1454 (common-debug.o: ../common/common-debug.c): Remove.
1455 (cleanups.o: ../common/cleanups.c): Remove.
1456 (common-exceptions.o: ../common/common-exceptions.c): Remove.
1457 (fileio.o: ../common/fileio.c): Remove.
1458 (common-regcache.o: ../common/common-regcache.c): Remove.
1459 (signals-state-save-restore.o: ../common/signals-state-save-restore.c): Remove.
1460 (new-op.o: ../common/new-op.c): Remove.
1461 (btrace-common.o: ../common/btrace-common.c): Remove.
1462
1463 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
1464
1465 * Makefile.in (%.o: ../target/%.c): New rule.
1466 (waitstatus.o: ../target/waitstatus.c): Remove.
1467
1468 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
1469
1470 * Makefile.in
1471 (%.c: ../regformats/%.dat,
1472 (%.c: ../regformats/arm/%.dat,
1473 (%.c: ../regformats/i386/%.dat,
1474 (%.c: ../regformats/rs6000/%.dat): New rules.
1475 (aarch64.c): Remove.
1476 (reg-arm.c): Remove.
1477 (arm-with-iwmmxt.c): Remove.
1478 (arm-with-vfpv2.c): Remove.
1479 (arm-with-vfpv3.c): Remove.
1480 (arm-with-neon.c): Remove.
1481 (reg-bfin.c): Remove.
1482 (reg-cris.c): Remove.
1483 (reg-crisv32.c): Remove.
1484 (i386.c): Remove.
1485 (i386-linux.c): Remove.
1486 (i386-avx.c): Remove.
1487 (i386-avx-linux.c): Remove.
1488 (i386-avx-avx512.c): Remove.
1489 (i386-avx-avx512-linux.c): Remove.
1490 (i386-mpx.c): Remove.
1491 (i386-mpx-linux.c): Remove.
1492 (i386-avx-mpx-avx512-pku.c): Remove.
1493 (i386-avx-mpx-avx512-pku-linux.c): Remove.
1494 (i386-avx-mpx.c): Remove.
1495 (i386-avx-mpx-linux.c): Remove.
1496 (i386-mmx.c): Remove.
1497 (i386-mmx-linux.c): Remove.
1498 (reg-ia64.c): Remove.
1499 (reg-m32r.c): Remove.
1500 (reg-m68k.c): Remove.
1501 (reg-cf.c): Remove.
1502 (mips-linux.c): Remove.
1503 (mips-dsp-linux.c): Remove.
1504 (mips64-linux.c): Remove.
1505 (mips64-dsp-linux.c): Remove.
1506 (nios2-linux.c): Remove.
1507 (powerpc-32.c): Remove.
1508 (powerpc-32l.c): Remove.
1509 (powerpc-altivec32l.c): Remove.
1510 (powerpc-cell32l.c): Remove.
1511 (powerpc-vsx32l.c): Remove.
1512 (powerpc-isa205-32l.c): Remove.
1513 (powerpc-isa205-altivec32l.c): Remove.
1514 (powerpc-isa205-vsx32l.c): Remove.
1515 (powerpc-e500l.c): Remove.
1516 (powerpc-64l.c): Remove.
1517 (powerpc-altivec64l.c): Remove.
1518 (powerpc-cell64l.c): Remove.
1519 (powerpc-vsx64l.c): Remove.
1520 (powerpc-isa205-64l.c): Remove.
1521 (powerpc-isa205-altivec64l.c): Remove.
1522 (powerpc-isa205-vsx64l.c): Remove.
1523 (s390-linux32.c): Remove.
1524 (s390-linux32v1.c): Remove.
1525 (s390-linux32v2.c): Remove.
1526 (s390-linux64.c): Remove.
1527 (s390-linux64v1.c): Remove.
1528 (s390-linux64v2.c): Remove.
1529 (s390-te-linux64.c): Remove.
1530 (s390-vx-linux64.c): Remove.
1531 (s390-tevx-linux64.c): Remove.
1532 (s390x-linux64.c): Remove.
1533 (s390x-linux64v1.c): Remove.
1534 (s390x-linux64v2.c): Remove.
1535 (s390x-te-linux64.c): Remove.
1536 (s390x-vx-linux64.c): Remove.
1537 (s390x-tevx-linux64.c): Remove.
1538 (tic6x-c64xp-linux.c): Remove.
1539 (tic6x-c64x-linux.c): Remove.
1540 (tic6x-c62x-linux.c): Remove.
1541 (reg-sh.c): Remove.
1542 (reg-sparc64.c): Remove.
1543 (reg-spu.c): Remove.
1544 (amd64.c): Remove.
1545 (amd64-linux.c): Remove.
1546 (amd64-avx.c): Remove.
1547 (amd64-avx-linux.c): Remove.
1548 (amd64-avx-avx512.c): Remove.
1549 (amd64-avx-avx512-linux.c): Remove.
1550 (amd64-mpx.c): Remove.
1551 (amd64-mpx-linux.c): Remove.
1552 (amd64-avx-mpx-avx512-pku.c): Remove.
1553 (amd64-avx-mpx-avx512-pku-linux.c): Remove.
1554 (amd64-avx-mpx.c): Remove.
1555 (amd64-avx-mpx-linux.c): Remove.
1556 (x32.c): Remove.
1557 (x32-linux.c): Remove.
1558 (x32-avx.c): Remove.
1559 (x32-avx-linux.c): Remove.
1560 (x32-avx-avx512.c): Remove.
1561 (x32-avx-avx512-linux.c): Remove.
1562 (reg-xtensa.c): Remove.
1563 (reg-tilegx.c): Remove.
1564 (reg-tilegx32.c): Remove.
1565
1566 2017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
1567
1568 * Makefile.in (SFILES): Add "common/environ.c".
1569 (OBJS): Add "common/environ.h".
1570
1571 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
1572
1573 * configure.ac: Check if the fs_base and gs_base members of
1574 `struct user_regs_struct' exist.
1575 * config.in: Regenerated.
1576 * configure: Likewise.
1577
1578 2017-01-09 Antoine Tremblay <antoine.tremblay@ericsson.com>
1579
1580 * linux-aarch32-low.c (arm_breakpoint_kind_from_pc): Use
1581 target_read_memory.
1582 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer): Likewise.
1583 (get_next_pcs_syscall_next_pc): Likewise.
1584
1585 2016-12-23 Luis Machado <lgustavo@codesourcery.com>
1586
1587 * win32-i386-low.c: Fix incorrect reference to a couple source files.
1588 * nto-x86-low.c: Likewise.
1589
1590 2016-11-30 Simon Marchi <simon.marchi@polymtl.ca>
1591
1592 * Makefile.in: Include disable-implicit-rules.mk.
1593
1594 2016-11-23 Pedro Alves <palves@redhat.com>
1595
1596 * debug.c: Include <chrono> instead of "gdb_sys_time.h".
1597 (debug_vprintf): Use std::chrono::steady_clock instead of
1598 gettimeofday. Use '.' instead of ':'.
1599 * tracepoint.c: Include <chrono> instead of "gdb_sys_time.h".
1600 (get_timestamp): Use std::chrono::steady_clock instead of
1601 gettimeofday.
1602
1603 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
1604
1605 * Makefile.in: Fix whitespace formatting.
1606
1607 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
1608
1609 * Makefile.in (SFILES, OBS): Flatten list and order
1610 alphabetically.
1611
1612 2016-11-23 Pedro Alves <palves@redhat.com>
1613
1614 * event-loop.c (handle_file_event): Use warning.
1615 * linux-low.c (linux_resume_one_lwp_throw): Use warning.
1616 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
1617 Use warning.
1618
1619 2016-11-23 Pedro Alves <palves@redhat.com>
1620
1621 * linux-low.c (check_zombie_leaders): Use debug_printf for debug
1622 output.
1623 * notif.c (handle_notif_ack, notif_event_enque): Likewise.
1624 * remote-utils.c (putpkt_binary_1, readchar, getpkt): Use
1625 debug_printf and debug_flush for debug output.
1626 * server.c (handle_general_set): Likewise.
1627 * thread-db.c (try_thread_db_load): Use debug_printf for debug
1628 output.
1629
1630 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
1631
1632 * Makefile.in (.c.o): Replace rule with ...
1633 (%.o: %.c): ... this one.
1634
1635 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
1636
1637 * Makefile.in: Remove @GMAKE_TRUE@ prefixes and removes lines
1638 prefixed with @GMAKE_FALSE@. Update comment related to non-GNU
1639 make.
1640 * configure.ac: Remove checks for the make program.
1641 * configure: Re-generate.
1642
1643 2016-10-28 Pedro Alves <palves@redhat.com>
1644
1645 * Makefile.in (CXX_DIALECT): Get from configure.
1646 (COMPILE.pre, CC_LD): Append $(CXX_DIALECT).
1647 * acinclude.m4: Include ../ax_cxx_compile_stdcxx.m4.
1648 * configure.ac: Call AX_CXX_COMPILE_STDCXX.
1649 * config.in: Regenerate.
1650 * configure: Regenerate.
1651
1652 2016-10-27 Yao Qi <yao.qi@linaro.org>
1653
1654 * linux-low.c (linux_supports_range_stepping): Return true if
1655 can_software_single_step return true.
1656
1657 2016-10-27 Yao Qi <yao.qi@linaro.org>
1658
1659 * inferiors.c (find_inferior_in_random): New function.
1660 * inferiors.h (find_inferior_in_random): Declare.
1661 * linux-low.c (linux_wait_for_event_filtered): Call
1662 find_inferior_in_random instead of find_inferior.
1663
1664 2016-10-27 Yao Qi <yao.qi@linaro.org>
1665
1666 * linux-low.c (linux_wait_1): If single-step breakpoints are
1667 inserted, remove them.
1668
1669 2016-10-26 Pedro Alves <palves@redhat.com>
1670
1671 * linux-low.c (handle_extended_wait): Link parent/child fork
1672 threads.
1673 (linux_wait_1): Unlink them.
1674 (linux_set_resume_request): Ignore resume requests for
1675 already-resumed and unhandled fork child threads.
1676 * linux-low.h (struct lwp_info) <fork_relative>: New field.
1677 * server.c (in_queued_stop_replies_ptid, in_queued_stop_replies):
1678 New functions.
1679 (handle_v_requests) <vCont>: Don't call require_running.
1680 * server.h (in_queued_stop_replies): New declaration.
1681
1682 2016-10-24 Yao Qi <yao.qi@linaro.org>
1683
1684 PR server/20733
1685 * linux-aarch64-low.c (append_insns): Cast the return value to
1686 'uint32_t *'.
1687
1688 2016-10-10 Yao Qi <yao.qi@linaro.org>
1689
1690 * linux-aarch32-low.c (enum arm_breakpoint_kinds): Remove.
1691
1692 2016-10-06 Sergio Durigan Junior <sergiodj@redhat.com>
1693
1694 * target.c (target_supports_multi_process): New function, moved
1695 from...
1696 * target.h (target_supports_multi_process): ... here. Remove
1697 macro.
1698
1699 2016-10-05 Tom Tromey <tom@tromey.com>
1700
1701 PR remote/20655:
1702 * tracepoint.c (handle_tracepoint_bkpts): Check
1703 ipa_error_tracepoint, not ipa_stopping_tracepoint.
1704
1705 2016-10-05 Yao Qi <yao.qi@linaro.org>
1706
1707 * configure.srv: Update the path of arm-*.xml files.
1708
1709 2016-10-05 Terry Guo <terry.guo@arm.com>
1710 Yao Qi <yao.qi@linaro.org>
1711
1712 * Makefile.in: Adjust the path of rules.
1713 * configure.srv: Update the path of xml files.
1714 * regformats/arm-with-iwmmxt.dat: Regenerated.
1715 * regformats/arm-with-neon.dat: Likewise.
1716 * regformats/arm-with-vfpv2.dat: Likewise.
1717 * regformats/arm-with-vfpv3.dat Likewise.
1718
1719 2016-09-30 Yao Qi <yao.qi@linaro.org>
1720
1721 PR gdbserver/20627
1722 * target.c (target_stop_and_wait): Don't call
1723 target_continue_no_signal, use resume_stop instead.
1724
1725 2016-09-26 Yao Qi <yao.qi@linaro.org>
1726
1727 * linux-low.c (linux_wait_1): Call debug_exit.
1728
1729 2016-09-23 Pedro Alves <palves@redhat.com>
1730
1731 * Makefile.in (SFILES): Add common/new-op.c.
1732 (OBS): Add common/new-op.o.
1733 (new-op.o): New rule.
1734
1735 2016-09-21 Simon Marchi <simon.marchi@ericsson.com>
1736
1737 * .gitinore: Ignore more files.
1738
1739 2016-09-21 Yao Qi <yao.qi@linaro.org>
1740
1741 * linux-aarch32-low.c (arm_fill_gregset): Keep bits 20 to
1742 23.
1743
1744 2016-09-19 Sergio Durigan Junior <sergiodj@redhat.com>
1745
1746 * server.c (start_inferior): Call target_mourn_inferior instead of
1747 mourn_inferior; pass ptid_t argument to it.
1748 (resume): Likewise.
1749 (handle_target_event): Likewise.
1750 * target.c (target_mourn_inferior): New function.
1751 * target.h (mourn_inferior): Delete macro.
1752
1753 2016-09-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
1754
1755 * linux-low.c (lwp_is_stepping): New function.
1756
1757 2016-09-06 Carl Love <cel@us.ibm.com>
1758
1759 * server.c (start_inferior): Fixed comment, requested comment change
1760 didn't get updated correctly. Removed reference to ptrace () call as
1761 it is only true on Linux systems.
1762
1763 2016-09-06 Carl Love <cel@us.ibm.com>
1764
1765 * server.c (start_inferior): Do not call
1766 function target_post_create_inferior () if the
1767 inferior process has already exited.
1768
1769 2016-09-05 Pedro Alves <palves@redhat.com>
1770
1771 * Makefile.in (COMPILER, COMPILER_CFLAGS): Remove.
1772 (COMPILE.pre, CC_LD): Use CXX directly.
1773 (INTERNAL_CFLAGS_BASE): Use CXXFLAGS directly.
1774 * acinclude.m4: Don't include build-with-cxx.m4.
1775 * configure.ac: Remove GDB_AC_BUILD_WITH_CXX call.
1776 * configure: Regenerate.
1777
1778 2016-09-02 Akash Trehan <akash.trehan123@gmail.com>
1779
1780 PR gdb/19495
1781 * remote-utils.c (relocate_instruction): Remove redundant strcpy()
1782 call writing data to own_buf.
1783
1784 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
1785
1786 * target.c (mywait): Call target_wait instead of
1787 the_target->wait.
1788 (target_wait): New function.
1789
1790 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
1791
1792 * server.c (start_inferior): New variable 'ptid'. Replace calls
1793 to the_target->resume by target_continue{,_no_signal}, depending
1794 on the case.
1795 * target.c (target_stop_and_wait): Call target_continue_no_signal
1796 instead of the_target->resume.
1797 (target_continue): New function.
1798
1799 2016-08-31 Antoine Tremblay <antoine.tremblay@ericsson.com>
1800
1801 * linux-low.c (linux_wait_1): Move event switch after unsuspend_lwps.
1802
1803 2016-08-25 Adhemerval Zanella <adhemerval.zanella@linaro.org>
1804
1805 PR server/20491
1806 * gdb_proc_service.h (ps_get_thread_area): Remove const from struct
1807 ps_prochandle.
1808 * linux-aarch64-low.c (ps_get_thread_area): Likewise.
1809 * linux-arm-low.c (ps_get_thread_area): Likewise.
1810 * linux-crisv32-low.c (ps_get_thread_area): Likewise.
1811 * linux-m68k-low.c (ps_get_thread_area): Likewise.
1812 * linux-mips-low.c (ps_get_thread_area): Likewise.
1813 * linux-nios2-low.c (ps_get_thread_area): Likewise.
1814 * linux-tic6x-low.c (ps_get_thread_area): Likewise.
1815 * linux-x86-low.c (ps_get_thread_area): Likewise.
1816 * linux-xtensa-low.c (ps_get_thread_area): Likewise.
1817
1818 2016-08-19 Pedro Alves <palves@redhat.com>
1819
1820 * linux-x86-low.c (amd64_emit_call): Emit missing call opcode.
1821
1822 2016-08-19 Pedro Alves <palves@redhat.com>
1823
1824 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Fix
1825 comment. Use memcpy instead of casting through unsigned long.
1826
1827 2016-08-19 Pedro Alves <palves@redhat.com>
1828
1829 * linux-amd64-ipa.c (alloc_jump_pad_buffer) [__ILP32__]: Try
1830 allocating around 0x80000000.
1831
1832 2016-08-19 Pedro Alves <palves@redhat.com>
1833
1834 PR gdb/20415
1835 * Makefile.in (x32-linux-ipa.o, x32-avx-linux-ipa.o)
1836 (x32-avx512-linux-ipa.o): New rules.
1837 * configure.ac (x86_64-*-linux*): New x32 check.
1838 * configure.srv (ipa_x32_linux_regobj): New.
1839 (x86_64-*-linux*): Use $ipa_x32_linux_regobj if building for x32.
1840 * linux-amd64-ipa.c (get_ipa_tdesc) [__ILP32__]: Return x32
1841 descriptions.
1842 (initialize_low_tracepoint) [__ILP32__]: Initialize x32
1843 descriptions.
1844 * configure: Regenerate.
1845
1846 2016-08-09 Pedro Alves <palves@redhat.com>
1847
1848 PR gdb/18653
1849 * Makefile.in (OBS): Add signals-state-save-restore.o.
1850 (signals-state-save-restore.o): New rule.
1851 * config.in: Regenerate.
1852 * configure: Regenerate.
1853 * linux-low.c: Include "signals-state-save-restore.h".
1854 (linux_create_inferior): Call
1855 restore_original_signals_state.
1856 * server.c: Include "dispositions-save-restore.h".
1857 (captured_main): Call save_original_signals_state.
1858
1859 2016-08-05 Pedro Alves <palves@redhat.com>
1860
1861 * configure: Regenerate.
1862
1863 2016-08-04 Yao Qi <yao.qi@linaro.org>
1864
1865 * linux-low.c (regsets_fetch_inferior_registers): Check
1866 errno is ESRCH or not.
1867
1868 2016-08-02 Yao Qi <yao.qi@linaro.org>
1869
1870 * thread-db.c (struct thread_db) <td_ta_event_getmsg_p>: Remove.
1871 <td_ta_set_event_p, td_ta_event_addr_p>: Remove.
1872 (thread_db_load_search): Update.
1873 (try_thread_db_load_1): Don't look for td_ta_event_addr,
1874 td_ta_set_event and td_ta_event_getmsg.
1875
1876 2016-07-26 Pedro Alves <palves@redhat.com>
1877
1878 PR server/20414
1879 * linux-x86-low.c (x86_get_pc, x86_set_pc): Use uint64_t instead
1880 of unsigned long for 64-bit registers and use uint32_t instead of
1881 unsigned int for 32-bit registers.
1882
1883 2016-07-26 Pedro Alves <palves@redhat.com>
1884
1885 * linux-x86-low.c (x86_siginfo_fixup): Rename 'native' parameter
1886 to 'ptrace'.
1887
1888 2016-07-21 Tom Tromey <tom@tromey.com>
1889
1890 * configure: Rebuild.
1891
1892 2016-07-21 Yao Qi <yao.qi@linaro.org>
1893
1894 * mem-break.c (find_gdb_breakpoint): Cast bp to
1895 'struct gdb_breakpoint *' rather than 'gdb_breakpoint *'.
1896
1897 2016-07-21 Yao Qi <yao.qi@linaro.org>
1898
1899 * server.c (handle_v_requests): Support s and S actions
1900 if target_supports_software_single_step return true.
1901
1902 2016-07-21 Yao Qi <yao.qi@linaro.org>
1903
1904 * linux-low.c (resume_stopped_resumed_lwps): If resume request
1905 is resume_step, call maybe_hw_step.
1906 (linux_wait_1): Stop all threads, remove reinsert breakpoints,
1907 and unstop them.
1908 (linux_resume_one_lwp_throw): Don't assert the thread has reinsert
1909 breakpoints or not.
1910 (proceed_one_lwp): If resume request is resume_step, install
1911 reinsert breakpoints and call maybe_hw_step.
1912
1913 2016-07-21 Yao Qi <yao.qi@linaro.org>
1914
1915 * linux-low.c (proceed_one_lwp): Declare.
1916 (linux_resume_one_thread): Remove local variable 'step'.
1917 Lift code enqueue signal. Call proceed_one_lwp instead of
1918 linux_resume_one_lwp.
1919
1920 2016-07-21 Yao Qi <yao.qi@linaro.org>
1921
1922 * linux-low.c (linux_resume_one_thread): Call
1923 enqueue_pending_signal.
1924
1925 2016-07-21 Yao Qi <yao.qi@linaro.org>
1926
1927 * gdbthread.h (make_cleanup_restore_current_thread): Declare.
1928 * inferiors.c (do_restore_current_thread_cleanup): New function.
1929 (make_cleanup_restore_current_thread): Likewise.
1930 * linux-low.c (install_software_single_step_breakpoints): Call
1931 make_cleanup_restore_current_thread. Switch current_thread to
1932 thread.
1933
1934 2016-07-21 Yao Qi <yao.qi@linaro.org>
1935
1936 * mem-break.c (struct reinsert_breakpoint) <ptid>: New field.
1937 (set_reinsert_breakpoint): New parameter ptid. Callers updated.
1938 (clone_one_breakpoint): Likewise.
1939 (delete_reinsert_breakpoints): Change parameter to thread.
1940 Callers updated.
1941 (has_reinsert_breakpoints): Likewise.
1942 (uninsert_reinsert_breakpoints): Likewise.
1943 (reinsert_reinsert_breakpoints): Likewise.
1944 * mem-break.h (set_reinsert_breakpoint): Update declaration.
1945 (delete_reinsert_breakpoints): Likewise.
1946 (reinsert_reinsert_breakpoints): Likewise.
1947 (uninsert_reinsert_breakpoints): Likewise.
1948 (has_reinsert_breakpoints): Likewise.
1949
1950 2016-07-21 Yao Qi <yao.qi@linaro.org>
1951
1952 * inferiors.c (get_thread_process): Make parameter const.
1953 * inferiors.h (get_thread_process): Update declaration.
1954 * mem-break.c (clone_all_breakpoints): Remove all parameters.
1955 Add new parameters child_thread and parent_thread. Callers
1956 updated.
1957 * mem-break.h (clone_all_breakpoints): Update declaration.
1958
1959 2016-07-21 Yao Qi <yao.qi@linaro.org>
1960
1961 * mem-break.c (struct breakpoint) <cond_list>: Remove.
1962 <command_list, handler>: Remove.
1963 (struct gdb_breakpoint): New.
1964 (struct other_breakpoint): New.
1965 (struct reinsert_breakpoint): New.
1966 (is_gdb_breakpoint): New function.
1967 (any_persistent_commands): Update command_list if
1968 is_gdb_breakpoint returns true.
1969 (set_breakpoint): Create breakpoints according to their types.
1970 (find_gdb_breakpoint): Return 'struct gdb_breakpoint *'.
1971 (set_gdb_breakpoint_1): Likewise.
1972 (set_gdb_breakpoint): Likewise.
1973 (clear_breakpoint_conditions): Change parameter type to
1974 'struct gdb_breakpoint *'.
1975 (clear_breakpoint_commands): Likewise.
1976 (clear_breakpoint_conditions_and_commands): Likewise.
1977 (add_condition_to_breakpoint): Likewise.
1978 (add_breakpoint_condition): Likewise.
1979 (add_commands_to_breakpoint): Likewise.
1980 (check_breakpoints): Check other_breakpoint.
1981 (clone_one_breakpoint): Clone breakpopint according to its type.
1982 * mem-break.h (struct gdb_breakpoint): Declare.
1983 (set_gdb_breakpoint): Update declaration.
1984 (clear_breakpoint_conditions_and_commands): Likewise.
1985 (add_breakpoint_condition): Likewise.
1986 (add_breakpoint_commands): Likewise.
1987 * server.c (process_point_options): Change parameter type to
1988 'struct gdb_breakpoint *'.
1989
1990 2016-07-21 Yao Qi <yao.qi@linaro.org>
1991
1992 * mem-break.c (set_breakpoint_at): Rename it to ...
1993 (set_breakpoint_type_at): ... it.
1994 (set_breakpoint_at): Call set_breakpoint_type_at.
1995 (set_reinsert_breakpoint): Call set_breakpoint_type_at.
1996 * mem-break.h (set_breakpoint_at): Update comments.
1997
1998 2016-07-12 Chung-Lin Tang <cltang@codesourcery.com>
1999
2000 * linux-nios2-low.c (nios2_fill_gregset): Add type cast
2001 to buf parameter.
2002 (nios2_store_gregset): Likewise.
2003
2004 2016-07-01 Pedro Alves <palves@redhat.com>
2005 Antoine Tremblay <antoine.tremblay@ericsson.com>
2006
2007 * linux-low.c: Change interface to take the target lwp_info
2008 pointer directly and return void. Handle detaching from a zombie
2009 thread.
2010 (linux_detach_lwp_callback): New function.
2011 (linux_detach): Detach from the leader thread after detaching from
2012 the clone threads.
2013
2014 2016-06-28 Yao Qi <yao.qi@linaro.org>
2015
2016 * linux-aarch64-low.c (aarch64_ftrace_insn_reloc_b): Use int64_t
2017 for variable new_offset.
2018 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
2019 (aarch64_ftrace_insn_reloc_cb): Likewise.
2020 (aarch64_ftrace_insn_reloc_tb): Likewise.
2021 (aarch64_install_fast_tracepoint_jump_pad): Likewise. Use
2022 PRIx64 instead of PRIx32.
2023
2024 2016-06-28 Yao Qi <yao.qi@linaro.org>
2025
2026 * linux-arm-low.c (arm_get_syscall_trapinfo): New function.
2027 (the_low_target): Install arm_get_syscall_trapinfo.
2028
2029 2016-06-28 Yao Qi <yao.qi@linaro.org>
2030
2031 * linux-aarch64-low.c (aarch64_get_syscall_trapinfo): New
2032 function.
2033 (the_low_target): Install aarch64_get_syscall_trapinfo.
2034
2035 2016-06-28 Yao Qi <yao.qi@linaro.org>
2036
2037 * linux-low.c (get_syscall_trapinfo): Remove parameter sysret.
2038 Callers updated.
2039 * linux-low.h (struct linux_target_ops) <get_syscall_trapinfo>:
2040 Remove parameter sysno.
2041 * linux-x86-low.c (x86_get_syscall_trapinfo): Remove parameter
2042 sysret.
2043
2044 2016-06-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
2045
2046 * linux-s390-low.c (s390_emit_eq_goto): Mark function static.
2047 (s390_emit_ne_goto): Likewise.
2048 (s390_emit_lt_goto): Likewise.
2049 (s390_emit_le_goto): Likewise.
2050 (s390_emit_gt_goto): Likewise.
2051 (s390_emit_ge_goto): Likewise.
2052 (s390x_emit_eq_goto): Likewise.
2053 (s390x_emit_ne_goto): Likewise.
2054 (s390x_emit_lt_goto): Likewise.
2055 (s390x_emit_le_goto): Likewise.
2056 (s390x_emit_gt_goto): Likewise.
2057 (s390x_emit_ge_goto): Likewise.
2058 (s390_emit_ops_impl): Mark variable static.
2059 (s390x_emit_ops): Likewise.
2060
2061 2016-06-17 Yao Qi <yao.qi@linaro.org>
2062
2063 * linux-low.c (handle_extended_wait): Call
2064 uninsert_reinsert_breakpoints for the parent process. Remove
2065 reinsert breakpoints from the child process. Reinsert them to
2066 the parent process when vfork is done.
2067 * mem-break.c (uninsert_reinsert_breakpoints): New function.
2068 (reinsert_reinsert_breakpoints): New function.
2069 * mem-break.h (uninsert_reinsert_breakpoints): Declare
2070 (reinsert_reinsert_breakpoints): Declare.
2071
2072 2016-06-17 Yao Qi <yao.qi@linaro.org>
2073
2074 * linux-low.c (handle_extended_wait): If the parent is doing
2075 step-over, remove the reinsert breakpoints from the forked child.
2076
2077 2016-06-17 Yao Qi <yao.qi@linaro.org>
2078
2079 * linux-low.c (unsuspend_all_lwps): Declare.
2080 (linux_low_filter_event): If thread exited, call finish_step_over.
2081 If step-over is finished, unsuspend other threads.
2082
2083 2016-06-17 Yao Qi <yao.qi@linaro.org>
2084
2085 * linux-low.c (linux_resume_one_lwp_throw): Assert
2086 has_reinsert_breakpoints returns false.
2087 * mem-break.c (delete_disabled_breakpoints): Assert
2088 bp type isn't reinsert_breakpoint.
2089
2090 2016-06-17 Yao Qi <yao.qi@linaro.org>
2091
2092 * linux-low.c (maybe_hw_step): New function.
2093 (linux_resume_one_lwp_throw): Call maybe_hw_step.
2094 (finish_step_over): Switch current_thread to lwp temporarily,
2095 and assert has_reinsert_breakpoints returns true.
2096 (proceed_one_lwp): Call maybe_hw_step.
2097 * mem-break.c (has_reinsert_breakpoints): New function.
2098 * mem-break.h (has_reinsert_breakpoints): Declare.
2099
2100 2016-06-02 Jon Turney <jon.turney@dronecode.org.uk>
2101
2102 * win32-low.c (win32_create_inferior): Add pointer casts for C++.
2103
2104 2016-05-17 Yao Qi <yao.qi@linaro.org>
2105
2106 * linux-low.c (linux_stabilize_threads): Call unsuspend_all_lwps
2107 instead of find_inferior.
2108
2109 2016-05-05 Yao Qi <yao.qi@linaro.org>
2110
2111 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer):
2112 Initialize res to zero.
2113
2114 2016-05-05 Yao Qi <yao.qi@linaro.org>
2115
2116 * linux-arm-low.c (arm_sigreturn_next_pc): Change type of cpsr
2117 to uint32_t.
2118
2119 2016-05-04 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
2120
2121 * spu-low.c (fetch_ppc_register): Cast PowerPC-Linux-specific value
2122 used as first ptrace argument to PTRACE_TYPE_ARG1 for C++.
2123 (fetch_ppc_memory_1, store_ppc_memory_1): Likewise.
2124
2125 2016-04-28 Par Olsson <par.olsson@windriver.com>
2126 Simon Marchi <simon.marchi@ericsson.com>
2127
2128 * tracepoint.c (write_inferior_int8): New function.
2129 (cmd_qtenable_disable): Write enable flag using
2130 write_inferior_int8.
2131
2132 2016-04-25 Yao Qi <yao.qi@linaro.org>
2133
2134 * linux-low.c (lwp_signal_can_be_delivered): Adjust.
2135 (need_step_over_p): Return zero if the LWP has pending signals
2136 can be delivered on software single step target.
2137
2138 2016-04-25 Yao Qi <yao.qi@linaro.org>
2139
2140 * linux-low.c (reinsert_raw_breakpoint): If bp->inserted is true
2141 return instead of error.
2142
2143 2016-04-22 Yao Qi <yao.qi@linaro.org>
2144
2145 * linux-aarch32-low.c (arm_store_gregset): Clear CPSR bits 20
2146 to 23.
2147
2148 2016-04-22 Yao Qi <yao.qi@linaro.org>
2149
2150 * linux-low.c (lwp_signal_can_be_delivered): Don't deliver
2151 signal when stepping over breakpoint with software single
2152 step.
2153
2154 2016-04-21 Pedro Alves <palves@redhat.com>
2155
2156 * linux-s390-low.c (s390_collect_ptrace_register)
2157 (s390_supply_ptrace_register, s390_get_hwcap): Use gdb_byte * and
2158 add casts.
2159 (s390_check_regset): Use void * instead of gdb_byte *.
2160
2161 2016-04-20 Pedro Alves <palves@redhat.com>
2162
2163 * configure: Renegerate.
2164
2165 2016-04-20 Yao Qi <yao.qi@linaro.org>
2166
2167 * linux-aarch32-low.c: Include "arch/arm-linux.h".
2168 (arm_fill_gregset): Use ARM_CPSR_GREGNUM rather than magic
2169 number 16.
2170 (arm_store_gregset): Likewise.
2171
2172 2016-04-16 Walfred Tedeschi <walfred.tedeschi@intel.com>
2173
2174 * Makefile.in (clean): Add removal for i386-avx-mpx.c,
2175 i386-avx-mpx-linux.c, amd64-avx-mpx.c and amd64-avx-mpx-linux.c.
2176 (i386-avx-mpx.c, i386-avx-mpx-linux.c, amd64-avx-mpx.c)
2177 (amd64-avx-mpx-linux.c): New rules.
2178 (amd64-avx-mpx-linux-ipa.o, i386-avx-mpx-linux-ipa.o): New rule.
2179 * configure.srv (srv_i386_regobj): Add i386-avx-mpx.o.
2180 (srv_i386_linux_regobj): Add i386-avx-mpx-linux.o.
2181 (srv_amd64_regobj): Add amd64-avx-mpx.o.
2182 (srv_amd64_linux_regobj): Add amd64-avx-mpx-linux.o.
2183 (srv_i386_xmlfiles): Add i386/i386-avx-mpx.xml.
2184 (srv_amd64_xmlfiles): Add i386/amd64-avx-mpx.xml.
2185 (srv_i386_linux_xmlfiles): Add i386/i386-avx-mpx-linux.xml.
2186 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-mpx-linux.xml.
2187 (ipa_i386_linux_regobj): Add i386-avx-mpx-linux-ipa.o.
2188 (ipa_amd64_linux_regobj): Add amd64-avx-mpx-linux-ipa.o.
2189 * linux-x86-low.c (x86_linux_read_description): Add case for
2190 X86_XSTATE_AVX_MPX_MASK.
2191 (x86_get_ipa_tdesc_idx): Add cases for avx_mpx.
2192 (initialize_low_arch): Call init_registers_amd64_avx_mpx_linux and
2193 init_registers_i386_avx_mpx_linux.
2194 * linux-i386-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
2195 (initialize_low_tracepoint): Call
2196 init_registers_i386_avx_mpx_linux.
2197 * linux-amd64-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
2198 (initialize_low_tracepoint): Call
2199 init_registers_amd64_avx_mpx_linux.
2200 * linux-x86-tdesc.h (X86_TDESC_AVX_MPX): New enum value.
2201 (init_registers_amd64_avx_mpx_linux, tdesc_amd64_avx_mpx_linux)
2202 (init_registers_i386_avx_mpx_linux, tdesc_i386_avx_mpx_linux): New
2203 declarations.
2204
2205 2016-04-18 Pedro Alves <palves@redhat.com>
2206
2207 * configure: Regenerate.
2208
2209 2016-04-13 Antoine Tremblay <antoine.tremblay@ericsson.com>
2210
2211 * linux-aarch64-low.c (aarch64_emit_add): Switch x1 and x0.
2212 (aarch64_emit_sub): Likewise.
2213
2214 2016-04-12 Pedro Alves <palves@redhat.com>
2215
2216 * utils.c (prepare_to_throw_exception): Delete.
2217
2218 2016-04-05 Simon Marchi <simon.marchi@ericsson.com>
2219
2220 * Makefile.in ($(IPA_LIB)): Set SONAME of the IPA lib.
2221
2222 2016-04-05 Marcin Kościelnicki <koriakin@0x04.net>
2223
2224 * tracepoint.c (getauxval): Move to #ifdef IN_PROCESS_AGENT.
2225
2226 2016-04-03 Marcin Kościelnicki <koriakin@0x04.net>
2227
2228 * linux-aarch64-ipa.c: Add <elf.h> include.
2229 * linux-ppc-ipa.c: Add <elf.h> include.
2230 * linux-s390-ipa.c: Add <elf.h> include.
2231
2232 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
2233
2234 * tracepoint.c (gdb_collect_ptr): Remove const qualifier.
2235 (get_raw_reg_ptr): Likewise.
2236 (get_trace_state_variable_value_ptr): Likewise.
2237 (set_trace_state_variable_value_ptr): Likewise.
2238 (initialize_tracepoint): Cast alloc_jump_pad_buffer result to
2239 char *.
2240
2241 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
2242 Marcin Kościelnicki <koriakin@0x04.net>
2243
2244 PR/17221
2245 * linux-ppc-low.c (emit_insns): New function.
2246 (__EMIT_ASM, _EMIT_ASM, EMIT_ASM): New macros.
2247 (ppc_emit_prologue): New function.
2248 (ppc_emit_epilogue): New function.
2249 (ppc_emit_add): New function.
2250 (ppc_emit_sub): New function.
2251 (ppc_emit_mul): New function.
2252 (ppc_emit_lsh): New function.
2253 (ppc_emit_rsh_signed): New function.
2254 (ppc_emit_rsh_unsigned): New function.
2255 (ppc_emit_ext): New function.
2256 (ppc_emit_zero_ext): New function.
2257 (ppc_emit_log_not): New function.
2258 (ppc_emit_bit_and): New function.
2259 (ppc_emit_bit_or): New function.
2260 (ppc_emit_bit_xor): New function.
2261 (ppc_emit_bit_not): New function.
2262 (ppc_emit_equal): New function.
2263 (ppc_emit_less_signed): New function.
2264 (ppc_emit_less_unsigned): New function.
2265 (ppc_emit_ref): New function.
2266 (ppc_emit_const): New function.
2267 (ppc_emit_reg): New function.
2268 (ppc_emit_pop): New function.
2269 (ppc_emit_stack_flush): New function.
2270 (ppc_emit_swap): New function.
2271 (ppc_emit_stack_adjust): New function.
2272 (ppc_emit_call): New function.
2273 (ppc_emit_int_call_1): New function.
2274 (ppc_emit_void_call_2): New function.
2275 (ppc_emit_if_goto): New function.
2276 (ppc_emit_goto): New function.
2277 (ppc_emit_eq_goto): New function.
2278 (ppc_emit_ne_goto): New function.
2279 (ppc_emit_lt_goto): New function.
2280 (ppc_emit_le_goto): New function.
2281 (ppc_emit_gt_goto): New function.
2282 (ppc_emit_ge_goto): New function.
2283 (ppc_write_goto_address): New function.
2284 (ppc_emit_ops_impl): New static variable.
2285 (ppc64v1_emit_prologue): New function.
2286 (ppc64v2_emit_prologue): New function.
2287 (ppc64_emit_epilogue): New function.
2288 (ppc64_emit_add): New function.
2289 (ppc64_emit_sub): New function.
2290 (ppc64_emit_mul): New function.
2291 (ppc64_emit_lsh): New function.
2292 (ppc64_emit_rsh_signed): New function.
2293 (ppc64_emit_rsh_unsigned): New function.
2294 (ppc64_emit_ext): New function.
2295 (ppc64_emit_zero_ext): New function.
2296 (ppc64_emit_log_not): New function.
2297 (ppc64_emit_bit_and): New function.
2298 (ppc64_emit_bit_or): New function.
2299 (ppc64_emit_bit_xor): New function.
2300 (ppc64_emit_bit_not): New function.
2301 (ppc64_emit_equal): New function.
2302 (ppc64_emit_less_signed): New function.
2303 (ppc64_emit_less_unsigned): New function.
2304 (ppc64_emit_ref): New function.
2305 (ppc64_emit_const): New function.
2306 (ppc64v1_emit_reg): New function.
2307 (ppc64v2_emit_reg): New function.
2308 (ppc64_emit_pop): New function.
2309 (ppc64_emit_stack_flush): New function.
2310 (ppc64_emit_swap): New function.
2311 (ppc64v1_emit_call): New function.
2312 (ppc64v2_emit_call): New function.
2313 (ppc64v1_emit_int_call_1): New function.
2314 (ppc64v2_emit_int_call_1): New function.
2315 (ppc64v1_emit_void_call_2): New function.
2316 (ppc64v2_emit_void_call_2): New function.
2317 (ppc64_emit_if_goto): New function.
2318 (ppc64_emit_eq_goto): New function.
2319 (ppc64_emit_ne_goto): New function.
2320 (ppc64_emit_lt_goto): New function.
2321 (ppc64_emit_le_goto): New function.
2322 (ppc64_emit_gt_goto): New function.
2323 (ppc64_emit_ge_goto): New function.
2324 (ppc64v1_emit_ops_impl): New static variable.
2325 (ppc64v2_emit_ops_impl): New static variable.
2326 (ppc_emit_ops): New function.
2327 (linux_low_target): Wire in ppc_emit_ops.
2328
2329 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
2330 Marcin Kościelnicki <koriakin@0x04.net>
2331
2332 PR/17221
2333 * Makefile.in: Add powerpc-*-ipa.o
2334 * configure.srv: Add ipa_obj for powerpc*-linux.
2335 * linux-ppc-ipa.c: New file.
2336 * linux-ppc-low.c: Added linux-ppc-tdesc.h, ax.h, tracepoint.h
2337 includes.
2338 (PPC_FIELD): New macro.
2339 (PPC_SEXT): New macro.
2340 (PPC_OP6): New macro.
2341 (PPC_BO): New macro.
2342 (PPC_LI): New macro.
2343 (PPC_BD): New macro.
2344 (init_registers_*): Move prototype to linux-ppc-tdesc.h.
2345 (tdesc_*): Move declaration to linux-ppc-tdesc.h.
2346 (ppc_get_hwcap): Rename to ppc_get_auxv and add type parameter.
2347 (ppc_get_thread_area): New function.
2348 (is_elfv2_inferior): New function.
2349 (gen_ds_form): New function.
2350 (GEN_STD): New macro.
2351 (GEN_STDU): New macro.
2352 (GEN_LD): New macro.
2353 (GEN_LDU): New macro.
2354 (gen_d_form): New function.
2355 (GEN_ADDI): New macro.
2356 (GEN_ADDIS): New macro.
2357 (GEN_LI): New macro.
2358 (GEN_LIS): New macro.
2359 (GEN_ORI): New macro.
2360 (GEN_ORIS): New macro.
2361 (GEN_LWZ): New macro.
2362 (GEN_STW): New macro.
2363 (GEN_STWU): New macro.
2364 (gen_xfx_form): New function.
2365 (GEN_MFSPR): New macro.
2366 (GEN_MTSPR): New macro.
2367 (GEN_MFCR): New macro.
2368 (GEN_MTCR): New macro.
2369 (GEN_SYNC): New macro.
2370 (GEN_LWSYNC): New macro.
2371 (gen_x_form): New function.
2372 (GEN_OR): New macro.
2373 (GEN_MR): New macro.
2374 (GEN_LWARX): New macro.
2375 (GEN_STWCX): New macro.
2376 (GEN_CMPW): New macro.
2377 (gen_md_form): New function.
2378 (GEN_RLDICL): New macro.
2379 (GEN_RLDICR): New macro.
2380 (gen_i_form): New function.
2381 (GEN_B): New macro.
2382 (GEN_BL): New macro.
2383 (gen_b_form): New function.
2384 (GEN_BNE): New macro.
2385 (GEN_LOAD): New macro.
2386 (GEN_STORE): New macro.
2387 (gen_limm): New function.
2388 (gen_atomic_xchg): New function.
2389 (gen_call): New function.
2390 (ppc_relocate_instruction): New function.
2391 (ppc_install_fast_tracepoint_jump_pad): New function.
2392 (ppc_get_min_fast_tracepoint_insn_len): New function.
2393 (ppc_get_ipa_tdesc_idx): New function.
2394 (the_low_target): Wire in the new functions.
2395 (initialize_low_arch) [!__powerpc64__]: Don'it initialize 64-bit
2396 tdescs.
2397 * linux-ppc-tdesc.h: New file.
2398
2399 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
2400
2401 * linux-aarch64-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
2402 (alloc_jump_pad_buffer): New function.
2403 * linux-amd64-ipa.c: Add <sys/mman.h> include.
2404 (alloc_jump_pad_buffer): New function.
2405 * linux-i386-ipa.c (alloc_jump_pad_buffer): New function.
2406 * linux-s390-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
2407 (alloc_jump_pad_buffer): New function.
2408 * tracepoint.c (getauxval) [!HAVE_GETAUXVAL]: New function.
2409 (initialize_tracepoint): Delegate to alloc_jump_pad_buffer.
2410 * tracepoint.h (alloc_jump_pad_buffer): New prototype.
2411 (getauxval) [!HAVE_GETAUXVAL]: New prototype.
2412
2413 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
2414
2415 * linux-aarch64-ipa.c: Rename gdb_agent_get_raw_reg to get_raw_reg.
2416 * linux-amd64-ipa.c: Likewise.
2417 * linux-i386-ipa.c: Likewise.
2418 * linux-s390-ipa.c: Likewise.
2419 * tracepoint.c: IPA-export gdb_collect_ptr instead of gdb_collect,
2420 ditto for get_raw_reg_ptr, get_trace_state_variable_value_ptr,
2421 set_trace_state_variable_value_ptr.
2422 (struct ipa_sym_addresses): Likewise.
2423 (symbol_list): Likewise.
2424 (install_fast_tracepoint): Dereference gdb_collect_ptr instead of
2425 accessing gdb_collect directly.
2426 (gdb_collect_ptr_type): New typedef.
2427 (get_raw_reg_ptr_type): New typedef.
2428 (get_trace_state_variable_value_ptr_type): New typedef.
2429 (set_trace_state_variable_value_ptr_type): New typedef.
2430 (gdb_collect_ptr): New global.
2431 (get_raw_reg_ptr): New global.
2432 (get_trace_state_variable_value_ptr): New global.
2433 (set_trace_state_variable_value_ptr): New global.
2434 (get_raw_reg_func_addr): Dereference get_raw_reg_ptr instead of
2435 accessing get_raw_reg directly.
2436 (get_get_tsv_func_addr): Likewise for
2437 get_trace_state_variable_value_ptr.
2438 (get_set_tsv_func_addr): Likewise for
2439 set_trace_state_variable_value_ptr.
2440 * tracepoint.h: Rename gdb_agent_get_raw_reg to get_raw_reg.
2441
2442 2016-03-30 Simon Marchi <simon.marchi@ericsson.com>
2443
2444 * tracepoint.c (cmd_qtenable_disable): Remove whitespace.
2445
2446 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
2447
2448 * remote-utils.c (look_up_one_symbol): Remove own_buf, handle 'v'
2449 packets.
2450 (relocate_instruction): Remove own_buf.
2451 * server.c (own_buf): Make global.
2452 (handle_v_requests): Make global.
2453 * server.h (own_buf): New declaration.
2454 (handle_v_requests): New prototype.
2455
2456 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
2457
2458 PR 18377
2459 * linux-s390-low.c (add_insns): New function.
2460 (s390_emit_prologue): New function.
2461 (s390_emit_epilogue): New function.
2462 (s390_emit_add): New function.
2463 (s390_emit_sub): New function.
2464 (s390_emit_mul): New function.
2465 (s390_emit_lsh): New function.
2466 (s390_emit_rsh_signed): New function.
2467 (s390_emit_rsh_unsigned): New function.
2468 (s390_emit_ext): New function.
2469 (s390_emit_log_not): New function.
2470 (s390_emit_bit_and): New function.
2471 (s390_emit_bit_or): New function.
2472 (s390_emit_bit_xor): New function.
2473 (s390_emit_bit_not): New function.
2474 (s390_emit_equal): New function.
2475 (s390_emit_less_signed): New function.
2476 (s390_emit_less_unsigned): New function.
2477 (s390_emit_ref): New function.
2478 (s390_emit_if_goto): New function.
2479 (s390_emit_goto): New function.
2480 (s390_write_goto_address): New function.
2481 (s390_emit_litpool): New function.
2482 (s390_emit_const): New function.
2483 (s390_emit_call): New function.
2484 (s390_emit_reg): New function.
2485 (s390_emit_pop): New function.
2486 (s390_emit_stack_flush): New function.
2487 (s390_emit_zero_ext): New function.
2488 (s390_emit_swap): New function.
2489 (s390_emit_stack_adjust): New function.
2490 (s390_emit_set_r2): New function.
2491 (s390_emit_int_call_1): New function.
2492 (s390_emit_void_call_2): New function.
2493 (s390_emit_eq_goto): New function.
2494 (s390_emit_ne_goto): New function.
2495 (s390_emit_lt_goto): New function.
2496 (s390_emit_le_goto): New function.
2497 (s390_emit_gt_goto): New function.
2498 (s390_emit_ge_goto): New function.
2499 (s390x_emit_prologue): New function.
2500 (s390x_emit_epilogue): New function.
2501 (s390x_emit_add): New function.
2502 (s390x_emit_sub): New function.
2503 (s390x_emit_mul): New function.
2504 (s390x_emit_lsh): New function.
2505 (s390x_emit_rsh_signed): New function.
2506 (s390x_emit_rsh_unsigned): New function.
2507 (s390x_emit_ext): New function.
2508 (s390x_emit_log_not): New function.
2509 (s390x_emit_bit_and): New function.
2510 (s390x_emit_bit_or): New function.
2511 (s390x_emit_bit_xor): New function.
2512 (s390x_emit_bit_not): New function.
2513 (s390x_emit_equal): New function.
2514 (s390x_emit_less_signed): New function.
2515 (s390x_emit_less_unsigned): New function.
2516 (s390x_emit_ref): New function.
2517 (s390x_emit_if_goto): New function.
2518 (s390x_emit_const): New function.
2519 (s390x_emit_call): New function.
2520 (s390x_emit_reg): New function.
2521 (s390x_emit_pop): New function.
2522 (s390x_emit_stack_flush): New function.
2523 (s390x_emit_zero_ext): New function.
2524 (s390x_emit_swap): New function.
2525 (s390x_emit_stack_adjust): New function.
2526 (s390x_emit_int_call_1): New function.
2527 (s390x_emit_void_call_2): New function.
2528 (s390x_emit_eq_goto): New function.
2529 (s390x_emit_ne_goto): New function.
2530 (s390x_emit_lt_goto): New function.
2531 (s390x_emit_le_goto): New function.
2532 (s390x_emit_gt_goto): New function.
2533 (s390x_emit_ge_goto): New function.
2534 (s390_emit_ops): New function.
2535 (struct linux_target_ops): Fill in emit_ops hook.
2536
2537 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
2538
2539 PR 18377
2540 * Makefile.in: Add s390 IPA files.
2541 * configure.srv: Build IPA for s390.
2542 * linux-s390-ipa.c: New file.
2543 * linux-s390-low.c: New includes - inttypes.h and linux-s390-tdesc.h.
2544 (init_registers_s390_linux32): Move declaration to linux-s390-tdesc.h.
2545 (tdesc_s390_linux32): Likewise.
2546 (init_registers_s390_linux32v1): Likewise.
2547 (tdesc_s390_linux32v1): Likewise.
2548 (init_registers_s390_linux32v2): Likewise.
2549 (tdesc_s390_linux32v2): Likewise.
2550 (init_registers_s390_linux64): Likewise.
2551 (tdesc_s390_linux64): Likewise.
2552 (init_registers_s390_linux64v1): Likewise.
2553 (tdesc_s390_linux64v1): Likewise.
2554 (init_registers_s390_linux64v2): Likewise.
2555 (tdesc_s390_linux64v2): Likewise.
2556 (init_registers_s390_te_linux64): Likewise.
2557 (tdesc_s390_te_linux64): Likewise.
2558 (init_registers_s390_vx_linux64): Likewise.
2559 (tdesc_s390_vx_linux64): Likewise.
2560 (init_registers_s390_tevx_linux64): Likewise.
2561 (tdesc_s390_tevx_linux64): Likewise.
2562 (init_registers_s390x_linux64): Likewise.
2563 (tdesc_s390x_linux64): Likewise.
2564 (init_registers_s390x_linux64v1): Likewise.
2565 (tdesc_s390x_linux64v1): Likewise.
2566 (init_registers_s390x_linux64v2): Likewise.
2567 (tdesc_s390x_linux64v2): Likewise.
2568 (init_registers_s390x_te_linux64): Likewise.
2569 (tdesc_s390x_te_linux64): Likewise.
2570 (init_registers_s390x_vx_linux64): Likewise.
2571 (tdesc_s390x_vx_linux64): Likewise.
2572 (init_registers_s390x_tevx_linux64): Likewise.
2573 (tdesc_s390x_tevx_linux64): Likewise.
2574 (have_hwcap_s390_vx): New static variable.
2575 (s390_arch_setup): Fill have_hwcap_s390_vx.
2576 (s390_get_thread_area): New function.
2577 (s390_ft_entry_gpr_esa): New const.
2578 (s390_ft_entry_gpr_zarch): New const.
2579 (s390_ft_entry_misc): New const.
2580 (s390_ft_entry_fr): New const.
2581 (s390_ft_entry_vr): New const.
2582 (s390_ft_main_31): New const.
2583 (s390_ft_main_64): New const.
2584 (s390_ft_exit_fr): New const.
2585 (s390_ft_exit_vr): New const.
2586 (s390_ft_exit_misc): New const.
2587 (s390_ft_exit_gpr_esa): New const.
2588 (s390_ft_exit_gpr_zarch): New const.
2589 (append_insns): New function.
2590 (s390_relocate_instruction): New function.
2591 (s390_install_fast_tracepoint_jump_pad): New function.
2592 (s390_get_min_fast_tracepoint_insn_len): New function.
2593 (s390_get_ipa_tdesc_idx): New function.
2594 (struct linux_target_ops): Wire in the above functions.
2595 (initialize_low_arch) [!__s390x__]: Don't initialize s390x tdescs.
2596 * linux-s390-tdesc.h: New file.
2597
2598 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
2599
2600 * linux-s390-low.c (s390_supports_tracepoints): New function.
2601 (struct linux_target_ops): Fill supports_tracepoints hook.
2602
2603 2016-03-18 Yao Qi <yao.qi@linaro.org>
2604
2605 * linux-low.c (lwp_signal_can_be_delivered): New function.
2606 (linux_resume_one_lwp_throw): Use lwp_signal_can_be_delivered.
2607
2608 2016-03-18 Yao Qi <yao.qi@linaro.org>
2609
2610 * linux-low.c (linux_resume_one_lwp_throw): Set 'signal' to
2611 0 if signal is enqueued. Remove 'signal' from one debugging
2612 message. Move one debugging message to some lines below.
2613 Remove code setting 'signal' to 0.
2614
2615 2016-03-18 Yao Qi <yao.qi@linaro.org>
2616
2617 * linux-low.c (linux_low_filter_event): Remove redundant
2618 WIFSTOPPED check together with linux_wstatus_maybe_breakpoint.
2619
2620 2016-03-09 Marcin Kościelnicki <koriakin@0x04.net>
2621
2622 * linux-ppc-low.c (ppc_supports_tracepoints): New function.
2623 (struct linux_target_ops): Wire in the above.
2624
2625 2016-03-03 Yao Qi <yao.qi@linaro.org>
2626
2627 * linux-low.c: Update comments to start_step_over.
2628
2629 2016-03-03 Yao Qi <yao.qi@linaro.org>
2630
2631 PR server/19736
2632 * linux-low.c (handle_extended_wait): Set child suspended
2633 if event_lwp->bp_reinsert isn't zero.
2634
2635 2016-03-02 Yao Qi <yao.qi@linaro.org>
2636
2637 * linux-low.c (linux_resume_one_lwp_throw): Replace code with
2638 enqueue_pending_signal.
2639
2640 2016-03-02 Marcin Kościelnicki <koriakin@0x04.net>
2641
2642 * tracepoint.c (cmd_qtstart): Only set ipa_tdesc_idx if agent
2643 is actually loaded.
2644
2645 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
2646
2647 * linux-s390-low.c (s390_num_regs_3264): Define on 31-bit too.
2648 (s390_regmap_3264) [!__s390x__]: New global.
2649 (s390_collect_ptrace_register): Skip map entries containing -1.
2650 (s390_supply_ptrace_register): Ditto.
2651 (s390_fill_gprs_high): New function.
2652 (s390_store_gprs_high): New function.
2653 (s390_regsets): Add NT_S390_HIGH_GPRS.
2654 (s390_get_hwcap): Enable on 31-bit.
2655 (have_hwcap_s390_high_gprs): Enable on 31-bit.
2656 (s390_arch_setup): Enable detection of high GPRs, TDB, VX on 31-bit.
2657 Detect NT_S390_HIGH_GPRS.
2658 (s390_usrregs_info_3264): Enable on 31-bit.
2659 (s390_regs_info): Enable regs_info_3264 on 31-bit.
2660 (initialize_low_arch): Initialize s390_regsets_info_3264 on 31-bit.
2661
2662 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
2663
2664 PR gdb/13808
2665 * Makefile.in: Add i386-*-linux-ipa.o and amd64-*-linux-ipa.o.
2666 * configure.srv: Ditto.
2667 * linux-aarch64-ipa.c (get_ipa_tdesc): New function.
2668 (initialize_low_tracepoint): Remove ipa_tdesc assignment.
2669 * linux-amd64-ipa.c: Add "linux-x86-tdesc.h" include.
2670 (init_registers_amd64_linux): Remove prototype.
2671 (tdesc_amd64_linux): Remove declaration.
2672 (get_ipa_tdesc): New function.
2673 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
2674 initialize remaining tdescs.
2675 * linux-i386-ipa.c: Add "linux-x86-tdesc.h" include.
2676 (init_registers_i386_linux): Remove prototype.
2677 (tdesc_i386_linux): Remove declaration.
2678 (get_ipa_tdesc): New function.
2679 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
2680 initialize remaining tdescs.
2681 * linux-low.c (linux_get_ipa_tdesc_idx): New function.
2682 (linux_target_ops): wire in linux_get_ipa_tdesc_idx.
2683 * linux-low.h (struct linux_target_ops): Add get_ipa_tdesc_idx.
2684 * linux-x86-low.c: Move tdesc declarations to linux-x86-tdesc.h.
2685 (x86_get_ipa_tdesc_idx): New function.
2686 (the_low_target): Wire in x86_get_ipa_tdesc_idx.
2687 * linux-x86-tdesc.h: New file.
2688 * target.h (struct target_ops): Add get_ipa_tdesc_idx.
2689 (target_get_ipa_tdesc_idx): New macro.
2690 * tracepoint.c (ipa_tdesc_idx): New macro.
2691 (struct ipa_sym_addresses): Add addr_ipa_tdesc_idx.
2692 (symbol_list): Add ipa_tdesc_idx.
2693 (cmd_qtstart): Write ipa_tdesc_idx in the target.
2694 (ipa_tdesc): Remove.
2695 (ipa_tdesc_idx): New variable.
2696 (get_context_regcache): Use get_ipa_tdesc.
2697 (gdb_collect): Ditto.
2698 (gdb_probe): Ditto.
2699 * tracepoint.h (get_ipa_tdesc): New prototype.
2700 (ipa_tdesc): Remove.
2701
2702 2016-02-24 Pedro Alves <palves@redhat.com>
2703
2704 * linux-low.c (check_stopped_by_breakpoint): Rename to ...
2705 (save_stop_reason): ... this. Use GDB_ARCH_IS_TRAP_HWBKPT and
2706 handle ambiguous GDB_ARCH_IS_TRAP_BRKPT / GDB_ARCH_IS_TRAP_HWBKPT.
2707 Factor out common code between the USE_SIGTRAP_SIGINFO and
2708 !USE_SIGTRAP_SIGINFO blocks.
2709 (linux_low_filter_event): Call save_stop_reason instead of
2710 check_stopped_by_breakpoint and check_stopped_by_watchpoint.
2711 Update comments.
2712 (linux_wait_1): Update comments.
2713
2714 2016-02-24 Wei-cheng Wang <cole945@gmail.com>
2715
2716 * linux-ppc-low.c (ppc_supports_z_point_type): New function:
2717 (ppc_insert_point, ppc_remove_point): Insert/remove z-packet breakpoints.
2718 (ppc64_emit_ops_vector): Add target ops - ppc_supports_z_point_type,
2719 ppc_insert_point, ppc_remove_point.
2720
2721 2016-02-17 Marcin Kościelnicki <koriakin@0x04.net>
2722
2723 * linux-s390-low.c (s390_supports_z_point_type): New function.
2724 (struct linux_target_ops): Wire s390_supports_z_point_type in.
2725
2726 2016-02-16 Yao Qi <yao.qi@linaro.org>
2727
2728 * linux-arm-low.c (get_next_pcs_syscall_next_pc): Remove argument
2729 PC. Get pc from regcache_read_pc.
2730
2731 2016-02-12 Yao Qi <yao.qi@linaro.org>
2732
2733 * linux-aarch64-low.c (aarch64_get_pc): Call linux_get_pc_64bit
2734 or linux_get_pc_32bit.
2735 (aarch64_set_pc): Call linux_set_pc_64bit or linux_set_pc_32bit.
2736
2737 2016-02-12 Yao Qi <yao.qi@linaro.org>
2738
2739 * linux-arm-low.c (get_next_pcs_ops): Initialize it with
2740 arm_linux_get_next_pcs_fixup.
2741
2742 2016-02-12 Marcin Kościelnicki <koriakin@0x04.net>
2743
2744 * tracepoint.c (x_tracepoint_action_download): Change
2745 write_inferior_data_ptr to write_inferior_data_pointer.
2746 (cmd_qtstart): Likewise.
2747 (write_inferior_data_ptr): Remove.
2748 (download_agent_expr): Change write_inferior_data_ptr to
2749 write_inferior_data_pointer.
2750 (download_tracepoint_1): Likewise.
2751 (download_tracepoint): Likewise.
2752 (download_trace_state_variables): Likewise.
2753
2754 2016-02-11 Wei-cheng Wang <cole945@gmail.com>
2755 Marcin Kościelnicki <koriakin@0x04.net>
2756
2757 * tracepoint.c (struct tracepoint_action_ops): Remove.
2758 (struct tracepoint_action): Remove ops.
2759 (m_tracepoint_action_download, r_tracepoint_action_download)
2760 (x_tracepoint_action_download, l_tracepoint_action_download): Adjust
2761 size and offset accordingly.
2762 (m_tracepoint_action_ops, r_tracepoint_action_ops)
2763 (x_tracepoint_action_ops, l_tracepoint_action_ops): Remove.
2764 (tracepoint_action_send, tracepoint_action_download): New functions.
2765 Helpers for trace action handlers.
2766 (add_tracepoint_action): Remove setup actions ops.
2767 (download_tracepoint_1, tracepoint_send_agent): Call helper functions.
2768
2769 2016-02-10 Yao Qi <yao.qi@linaro.org>
2770
2771 * regcache.c (regcache_raw_read_unsigned): Clear *VAL.
2772
2773 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
2774
2775 * configure.ac: Use AC_CONFIG_FILES instead of passing arguments
2776 to AC_OUTPUT.
2777 * configure: Regenerate.
2778
2779 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
2780
2781 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): Change
2782 void * to gdb_byte *.
2783 * linux-low.c (siginfo_fixup): Likewise.
2784 (linux_xfer_siginfo): Likewise.
2785 * linux-low.h (struct linux_target_ops) <siginfo_fixup>:
2786 Likewise.
2787 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
2788
2789 2016-02-02 Walfred Tedeschi <walfred.tedeschi@intel.com>
2790
2791 * configure.srv (x86_64-*-linux*): Add amd64-linux-siginfo.o
2792 to srv_tgtobj.
2793 (i[34567]86-*-linux*): Add amd64-linux-siginfo.o
2794 to srv_tgtobj.
2795 * linux-x86-low.c [__x86_64__]: Include
2796 "nat/amd64-linux-siginfo.h".
2797 (compat_siginfo_from_siginfo, siginfo_from_compat_siginfo)
2798 (compat_x32_siginfo_from_siginfo, siginfo_from_compat_x32_siginfo)
2799 (compat_timeval, compat_sigval, compat_x32_clock, cpt_si_pid)
2800 (cpt_si_uid, cpt_si_timerid, cpt_si_overrun, cpt_si_status)
2801 (cpt_si_utime, cpt_si_stime, cpt_si_ptr, cpt_si_addr, cpt_si_band)
2802 (cpt_si_fd, si_timerid, si_overrun): Move from
2803 nat/amd64-linux-siginfo.c.
2804 * Makefile.in (amd64-linux-siginfo.o:): New rule.
2805
2806 2016-01-28 Simon Marchi <simon.marchi@ericsson.com>
2807
2808 * server.c (skip_to_semicolon): Remove.
2809 (process_point_options): Use strchrnul instead of
2810 skip_to_semicolon.
2811
2812 2016-01-26 Yao Qi <yao.qi@linaro.org>
2813
2814 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Remove argument pc.
2815 * linux-low.c (install_software_single_step_breakpoints): Don't
2816 call regcache_read_pc.
2817 * linux-low.h (struct linux_target_ops) <get_next_pcs>: Remove
2818 argument pc.
2819
2820 2016-01-26 Yao Qi <yao.qi@linaro.org>
2821
2822 * linux-low.c (install_software_single_step_breakpoints): Call
2823 regcache_read_pc instead of get_pc.
2824
2825 2016-01-26 Yao Qi <yao.qi@linaro.org>
2826
2827 * remote-utils.c (remote_close) [!USE_WIN32API]: Ignore SIGIO.
2828 (unblock_async_io): Rename to ...
2829 (block_unblock_async_io): ... it. New function.
2830 (enable_async_io): Don't install SIGIO handler. Unblock it
2831 instead.
2832 (disable_async_io): Don't ignore SIGIO. Block it instead.
2833 (initialize_async_io): Install SIGIO handler. Don't call
2834 unblock_async_io.
2835
2836 2016-01-26 Yao Qi <yao.qi@linaro.org>
2837
2838 * remote-utils.c (getpkt): If the buffer isn't empty, and the
2839 first character is '\003', call *the_target->request_interrupt.
2840
2841 2016-01-25 Yao Qi <yao.qi@linaro.org>
2842
2843 * remote-utils.c (new_thread_notify): Remove.
2844 (dead_thread_notify): Likewise.
2845 * remote-utils.h (new_thread_notify): Remove declaration.
2846 (dead_thread_notify): Likewise.
2847
2848 2016-01-23 Marcin Kościelnicki <koriakin@0x04.net>
2849
2850 * gdb.trace/pending.exp: Fix expected message on continue.
2851
2852 2016-01-22 Marcin Kościelnicki <koriakin@0x04.net>
2853
2854 * tracepoint.c (write_inferior_data_ptr): Cast to uintptr_t, so that
2855 it works properly on big-endian machines where sizeof (CORE_ADDR)
2856 != sizeof (void *).
2857
2858 2016-01-21 Pedro Alves <palves@redhat.com>
2859
2860 * Makefile.in (COMPILER_CFLAGS, CXXFLAGS): New.
2861 (INTERNAL_CFLAGS_BASE): Use COMPILER_CFLAGS instead of CFLAGS.
2862 * configure: Regenerate.
2863
2864 2016-01-21 Yao Qi <yao.qi@linaro.org>
2865
2866 * linux-arm-low.c (arm_sigreturn_next_pc): Add parameter
2867 is_thumb and set it according to CPSR saved on the stack.
2868 (get_next_pcs_syscall_next_pc): Pass is_thumb to
2869 arm_sigreturn_next_pc.
2870
2871 2016-01-18 Yao Qi <yao.qi@linaro.org>
2872
2873 * linux-low.c (linux_set_pc_64bit): New function.
2874 (linux_get_pc_64bit): New function.
2875 * linux-low.h (linux_set_pc_64bit, linux_get_pc_64bit):
2876 Declare.
2877 * linux-sparc-low.c (debug_threads): Remove declaration.
2878 (sparc_get_pc): Remove.
2879 (the_low_target): Use linux_get_pc_64bit instead of
2880 sparc_get_pc.
2881 * linux-tile-low.c (tile_get_pc, tile_set_pc): Remove.
2882 (the_low_target): Use linux_get_pc_64bit and
2883 linux_set_pc_64bit.
2884
2885 2016-01-18 Yao Qi <yao.qi@linaro.org>
2886
2887 * linux-arm-low.c (debug_threads): Remove declaration.
2888 (arm_get_pc, arm_set_pc): Remove.
2889 (the_low_target): Use linux_get_pc_32bit and
2890 linux_set_pc_32bit.
2891 * linux-bfin-low.c (bfin_get_pc, bfin_set_pc): Remove.
2892 (the_low_target): Use linux_get_pc_32bit and
2893 linux_set_pc_32bit.
2894 * linux-cris-low.c (debug_threads): Remove declaration.
2895 (cris_get_pc, cris_set_pc,): Remove.
2896 (the_low_target): Use linux_get_pc_32bit and
2897 linux_set_pc_32bit.
2898 * linux-crisv32-low.c (debug_threads): Remove declaration.
2899 (cris_get_pc, cris_set_pc): Remove.
2900 (the_low_target): Use linux_get_pc_32bit and
2901 linux_set_pc_32bit.
2902 * linux-low.c: Include inttypes.h.
2903 (linux_get_pc_32bit, linux_set_pc_32bit): New functions.
2904 * linux-low.h (linux_get_pc_32bit, linux_set_pc_32bit): Declare.
2905 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Remove.
2906 (the_low_target): Use linux_get_pc_32bit and
2907 linux_set_pc_32bit.
2908 * linux-m68k-low.c (m68k_get_pc, m68k_set_pc): Remove.
2909 (the_low_target): Use linux_get_pc_32bit and
2910 linux_set_pc_32bit.
2911 * linux-nios2-low.c (nios2_get_pc, nios2_set_pc): Remove.
2912 (the_low_target): Use linux_get_pc_32bit and
2913 linux_set_pc_32bit.
2914 * linux-sh-low.c (sh_get_pc, sh_set_pc): Remove.
2915 (the_low_target): Use linux_get_pc_32bit and
2916 linux_set_pc_32bit.
2917 * linux-xtensa-low.c (xtensa_get_pc, xtensa_set_pc): Remove.
2918 (the_low_target): Use linux_get_pc_32bit and
2919 linux_set_pc_32bit.
2920
2921 2016-01-18 Gary Benson <gbenson@redhat.com>
2922
2923 * configure.ac (AC_FUNC_FORK): New check.
2924 * config.in: Regenerate.
2925 * configure: Likewise.
2926
2927 2016-01-14 Yao Qi <yao.qi@linaro.org>
2928
2929 * linux-aarch32-low.c (thumb2_breakpoint): Make it static.
2930 * linux-aarch32-low.h (thumb2_breakpoint): Remove declaration.
2931 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Pass 1 to
2932 arm_get_next_pcs_ctor.
2933
2934 2016-01-12 Josh Stone <jistone@redhat.com>
2935 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2936
2937 * inferiors.h: Include "gdb_vecs.h".
2938 (struct process_info): Add syscalls_to_catch.
2939 * inferiors.c (remove_process): Free syscalls_to_catch.
2940 * remote-utils.c (prepare_resume_reply): Report syscall_entry and
2941 syscall_return stops.
2942 * server.h (UNKNOWN_SYSCALL, ANY_SYSCALL): Define.
2943 * server.c (handle_general_set): Handle QCatchSyscalls.
2944 (handle_query): Report support for QCatchSyscalls.
2945 * target.h (struct target_ops): Add supports_catch_syscall.
2946 (target_supports_catch_syscall): New macro.
2947 * linux-low.h (struct linux_target_ops): Add get_syscall_trapinfo.
2948 (struct lwp_info): Add syscall_state.
2949 * linux-low.c (handle_extended_wait): Mark syscall_state as an entry.
2950 Maintain syscall_state and syscalls_to_catch across exec.
2951 (get_syscall_trapinfo): New function, proxy to the_low_target.
2952 (linux_low_ptrace_options): Enable PTRACE_O_TRACESYSGOOD.
2953 (linux_low_filter_event): Toggle syscall_state entry/return for
2954 syscall traps, and set it ignored for all others.
2955 (gdb_catching_syscalls_p): New function.
2956 (gdb_catch_this_syscall_p): New function.
2957 (linux_wait_1): Handle SYSCALL_SIGTRAP.
2958 (linux_resume_one_lwp_throw): Add PTRACE_SYSCALL possibility.
2959 (linux_supports_catch_syscall): New function.
2960 (linux_target_ops): Install it.
2961 * linux-x86-low.c (x86_get_syscall_trapinfo): New function.
2962 (the_low_target): Install it.
2963
2964 2016-01-12 Mike Frysinger <vapier@gentoo.org>
2965
2966 * acinclude.m4: Include new ../warning.m4 file.
2967 * configure: Regenerated.
2968 * configure.ac: Replace all warning logic with AM_GDB_WARNINGS.
2969
2970 2016-01-12 Mike Frysinger <vapier@gentoo.org>
2971
2972 * ax.c (is_goto_target): Mark static.
2973 * linux-low.c (register_addr): Likewise.
2974 (linux_fetch_registers, linux_store_registers): Likewise.
2975 * mem-break.c (any_persistent_commands): Fix old prototype.
2976 (add_commands_to_breakpoint): Mark static.
2977 * regcache.c (find_register_by_name): Delete unused func.
2978 * remote-utils.c (hex_or_minus_one): Mark static.
2979 * server.c (monitor_show_help): Mark static.
2980 (handle_query, handle_v_cont, handle_v_attach, handle_v_kill,
2981 handle_v_requests): Likewise.
2982
2983 2016-01-12 Pedro Alves <palves@redhat.com>
2984
2985 Remove use of the registered trademark symbol throughout.
2986
2987 2016-01-08 Yao Qi <yao.qi@linaro.org>
2988
2989 * remote-utils.c (getpkt): If c is '\003', call target hook
2990 request_interrupt.
2991
2992 2016-01-06 Yao Qi <yao.qi@linaro.org>
2993
2994 * linux-aarch32-low.h (arm_abi_breakpoint): Move to
2995 linux-aarch32-low.c.
2996 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
2997 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
2998 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
2999 (thumb2_breakpoint): Declare.
3000 * linux-aarch32-low.c (arm_abi_breakpoint): Moved from
3001 linux-aarch32-low.h.
3002 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
3003 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
3004 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
3005
3006 2016-01-01 Joel Brobecker <brobecker@adacore.com>
3007
3008 * gdbreplay.c (gdbreplay_version): Change copyright year in
3009 version message.
3010 * server.c (gdbserver_version): Likewise.
3011
3012 2015-12-28 Patrick Palka <patrick@parcs.ath.cx>
3013
3014 * server.c (crc32_table): Delete.
3015 (crc32): Use libiberty's xcrc32 function.
3016
3017 2015-12-22 Joel Brobecker <brobecker@adacore.com>
3018
3019 * lynx-low.c (lynx_delete_thread_callback): New function.
3020 (lynx_mourn): Properly delete our process and all of its
3021 threads. Remove call to clear_inferiors.
3022
3023 2015-12-22 Joel Brobecker <brobecker@adacore.com>
3024
3025 * target.c (thread_search_callback): Add check that
3026 the thread_stopped target callback is not NULL before
3027 calling it.
3028
3029 2015-12-21 Yao Qi <yao.qi@linaro.org>
3030
3031 * linux-aarch32-low.h [__aarch64__]: Use arm_abi_breakpoint
3032 arm breakpoint.
3033
3034 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
3035
3036 * server.c (handle_query): Call target_supports_software_single_step.
3037
3038 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
3039
3040 * linux-low.c (single_step): New function.
3041 (linux_resume_one_lwp_throw): Call single_step.
3042 (start_step_over): Likewise.
3043
3044 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
3045
3046 * Makefile.in (SFILES): Append arch/arm-linux.c,
3047 arch/arm-get-next-pcs.c.
3048 (arm-linux.o): New rule.
3049 (arm-get-next-pcs.o): New rule.
3050 * configure.srv (arm*-*-linux*): Add arm-get-next-pcs.o,
3051 arm-linux.o.
3052 * linux-aarch32-low.c (arm_abi_breakpoint): Remove macro. Moved
3053 to linux-aarch32-low.c.
3054 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
3055 (arm_breakpoint_len, thumb_breakpoint): Likewise.
3056 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
3057 (thumb2_breakpoint_len): Likewise.
3058 (arm_is_thumb_mode): Make non-static.
3059 * linux-aarch32-low.h (arm_abi_breakpoint): New macro. Moved
3060 from linux-aarch32-low.c.
3061 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
3062 (arm_breakpoint_len, thumb_breakpoint): Likewise.
3063 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
3064 (thumb2_breakpoint_len): Likewise.
3065 (arm_is_thumb_mode): New declaration.
3066 * linux-arm-low.c: Include arch/arm-linux.h
3067 aarch/arm-get-next-pcs.h, sys/syscall.h.
3068 (get_next_pcs_ops): New struct.
3069 (get_next_pcs_addr_bits_remove): New function.
3070 (get_next_pcs_is_thumb): New function.
3071 (get_next_pcs_read_memory_unsigned_integer): Likewise.
3072 (arm_sigreturn_next_pc): Likewise.
3073 (get_next_pcs_syscall_next_pc): Likewise.
3074 (arm_gdbserver_get_next_pcs): Likewise.
3075 (struct linux_target_ops) <arm_gdbserver_get_next_pcs>:
3076 Initialize.
3077 * linux-low.h: Move CORE_ADDR vector definition to gdb_vecs.h.
3078 * server.h: Include gdb_vecs.h.
3079
3080 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
3081
3082 * Makefile.in (SFILES): Append common/common-regcache.c.
3083 (OBS): Append common-regcache.o.
3084 (common-regcache.o): New rule.
3085 * regcache.c (init_register_cache): Initialize cache to
3086 REG_UNAVAILABLE.
3087 (regcache_raw_read_unsigned): New function.
3088 * regcache.h (REG_UNAVAILABLE, REG_VALID): Replaced by shared
3089 register_status enum.
3090
3091 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
3092
3093 * linux-aarch64-low.c (the_low_targets): Rename
3094 breakpoint_reinsert_addr to get_next_pcs.
3095 * linux-arm-low.c (the_low_targets): Likewise.
3096 * linux-bfin-low.c (the_low_targets): Likewise.
3097 * linux-cris-low.c (the_low_targets): Likewise.
3098 * linux-crisv32-low.c (the_low_targets): Likewise.
3099 * linux-low.c (can_software_single_step): Likewise.
3100 (install_software_single_step_breakpoints): New function.
3101 (start_step_over): Use install_software_single_step_breakpoints.
3102 * linux-low.h: New CORE_ADDR vector.
3103 (struct linux_target_ops) Rename breakpoint_reinsert_addr to
3104 get_next_pcs.
3105 * linux-mips-low.c (the_low_targets): Likewise.
3106 * linux-nios2-low.c (the_low_targets): Likewise.
3107 * linux-sparc-low.c (the_low_targets): Likewise.
3108
3109 2015-12-17 Pedro Alves <palves@redhat.com>
3110
3111 * linux-low.c (linux_kill_one_lwp): Remove references to
3112 LinuxThreads.
3113 (kill_lwp): Remove HAVE_TKILL_SYSCALL check. No longer fall back
3114 to 'kill'.
3115 (linux_init_signals): Delete.
3116 (initialize_low): Adjust.
3117 * thread-db.c (thread_db_init): Remove LinuxThreads reference.
3118
3119 2015-12-16 Pedro Alves <palves@redhat.com>
3120
3121 * configure.ac (compiler warning flags): When testing a
3122 -Wno-foo option, check whether -Wfoo works instead.
3123 * configure: Regenerate.
3124
3125 2015-12-11 Don Breazeal <donb@codesourcery.com>
3126
3127 * server.c (process_serial_event): Don't exit from gdbserver
3128 in remote mode if there are still active inferiors.
3129
3130 2015-12-11 Yao Qi <yao.qi@linaro.org>
3131
3132 * linux-aarch64-low.c (aarch64_breakpoint_at): Call
3133 arm_breakpoint_at if the process is 32-bit.
3134
3135 2015-12-11 Yao Qi <yao.qi@linaro.org>
3136
3137 * linux-aarch32-low.c [__aarch64__]: Use arm_abi_breakpoint
3138 arm breakpoint.
3139
3140 2015-12-07 Yao Qi <yao.qi@linaro.org>
3141
3142 * configure.srv: Append arm.o to srv_tgtobj for
3143 aarch64*-*-linux* target.
3144 * linux-aarch32-low.c (arm_abi_breakpoint): New macro. Moved
3145 from linux-arm-low.c.
3146 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
3147 (arm_breakpoint_len, thumb_breakpoint): Likewise.
3148 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
3149 (thumb2_breakpoint_len): Likewise.
3150 (arm_is_thumb_mode, arm_breakpoint_at): Likewise.
3151 (arm_breakpoint_kinds): Likewise.
3152 (arm_breakpoint_kind_from_pc): Likewise.
3153 (arm_sw_breakpoint_from_kind): Likewise.
3154 (arm_breakpoint_kind_from_current_state): Likewise.
3155 * linux-aarch32-low.h (arm_breakpoint_kind_from_pc): Declare.
3156 (arm_sw_breakpoint_from_kind): Declare.
3157 (arm_breakpoint_kind_from_current_state): Declare.
3158 (arm_breakpoint_at): Declare.
3159 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): Call
3160 arm_sw_breakpoint_from_kind if process is 32-bit.
3161 (aarch64_breakpoint_kind_from_pc): New function.
3162 (aarch64_breakpoint_kind_from_current_state): New function.
3163 (the_low_target): Initialize fields breakpoint_kind_from_pc
3164 and breakpoint_kind_from_current_state.
3165 * linux-arm-low.c (arm_breakpoint_kinds): Move to
3166 linux-aarch32-low.c.
3167 (arm_abi_breakpoint, arm_eabi_breakpoint): Likewise.
3168 (arm_breakpoint, arm_breakpoint_len): Likewise.
3169 (thumb_breakpoint, thumb_breakpoint_len): Likewise.
3170 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
3171 (arm_is_thumb_mode): Likewise.
3172 (arm_breakpoint_at): Likewise.
3173 (arm_breakpoint_kind_from_pc): Likewise.
3174 (arm_sw_breakpoint_from_kind): Likewise.
3175 (arm_breakpoint_kind_from_current_state): Likewise.
3176
3177 Revert:
3178 2015-08-04 Yao Qi <yao.qi@linaro.org>
3179
3180 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
3181 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
3182 * server.c (extended_protocol): Remove "static".
3183 * server.h (extended_protocol): Declare it.
3184
3185 2015-12-04 Josh Stone <jistone@redhat.com>
3186
3187 * target.h (struct target_ops) <arch_setup>: Rename to ...
3188 (struct target_ops) <post_create_inferior>: ... this.
3189 (target_arch_setup): Rename to ...
3190 (target_post_create_inferior): ... this, calling post_create_inferior.
3191 * server.c (start_inferior): Update target_arch_setup calls to
3192 target_post_create_inferior.
3193 * linux-low.c (linux_low_ptrace_options): Forward declare.
3194 (linux_arch_setup): Update its comment for general use.
3195 (linux_post_create_inferior): New, run arch_setup and setup ptrace.
3196 (struct linux_target_ops): Use linux_post_create_inferior.
3197 * lynx-low.c (struct lynx_target_ops): Update arch_setup stub comment
3198 to post_create_inferior.
3199 * nto-low.c (struct nto_target_ops): Likewise.
3200 * spu-low.c (struct spu_target_ops): Likewise.
3201 * win32-low.c (struct win32_target_ops): Likewise.
3202
3203 2015-12-03 Antoine Tremblay <antoine.tremblay@ericsson.com>
3204
3205 * linux-arm-low.c: Remove duplicate arch/arm.h include.
3206
3207 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
3208
3209 * linux-arm-low.c (arm_reinsert_addr): Remove function.
3210 (struct linux_target_ops <breakpoint_reinsert_addr>: Set to NULL.
3211 * linux-cris-low.c (cris_reinsert_addr> Remove function.
3212 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
3213 * linux-crisv32-low.c (cris_reinsert_addr): Remove function.
3214 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
3215 * linux-mips-low.c (mips_reinsert_addr): Remove function.
3216 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
3217 * linux-nios2-low.c (nios2_reinsert_addr): Remove function.
3218 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
3219 * linux-sparc-low.c (sparc_reinsert_addr): Remove function.
3220 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
3221
3222 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
3223
3224 * linux-low.c (linux_look_up_symbols): Don't call
3225 linux_supports_traceclone.
3226 * linux-low.h (thread_db_init): Remove use_events argument.
3227 * thread-db.c (thread_db_use_event): Remove global variable.
3228 (struct thread_db) <td_thr_event_enable_p>: Remove field.
3229 (struct thread_db) <td_create_bp>: Remove field.
3230 (thread_db_create_event): Remove function.
3231 (thread_db_enable_reporting): Likewise.
3232 (find_one_thread): Don't check for thread_db_use_events.
3233 (attach_thread): Likewise.
3234 (thread_db_load_search): Remove td_thr_event_enable_p initialization.
3235 (try_thread_db_load_1): Don't check for thread_db_use_events.
3236 (thread_db_init): Remove use_events argument and thread events
3237 handling.
3238 (remove_thread_event_breakpoints): Remove function.
3239 (thread_db_detach): Remove call to remove_thred_event_breakpoints.
3240
3241 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
3242
3243 * linux-aarch64-low.c (aarch64_supports_hardware_single_step):
3244 New function.
3245 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
3246 * linux-arm-low.c (arm_supports_hardware_single_step): New function.
3247 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
3248 * linux-bfin-low.c (bfin_supports_hardware_single_step): New function.
3249 (struct linux_target_ops) <bfin_supports_hardware_single_step>:
3250 Initialize.
3251 * linux-crisv32-low.c (cris_supports_hardware_single_step):
3252 New function.
3253 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
3254 * linux-low.c (can_hardware_single_step): Use
3255 supports_hardware_single_step.
3256 (can_software_single_step): New function.
3257 (start_step_over): Call can_software_single_step.
3258 (linux_supports_hardware_single_step): New function.
3259 (struct target_ops) <supports_software_single_step>: Initialize.
3260 * linux-low.h (struct linux_target_ops)
3261 <supports_hardware_single_step>: Initialize.
3262 * linux-m32r-low.c (m32r_supports_hardware_single_step): New function.
3263 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
3264 * linux-ppc-low.c (ppc_supports_hardware_single_step): New function.
3265 (struct linux_target_ops) <supports_hardware_single_step> Initialize.
3266 * linux-s390-low.c (s390_supports_hardware_single_step): New function.
3267 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
3268 * linux-sh-low.c (sh_supports_hardware_single_step): New function.
3269 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
3270 * linux-tic6x-low.c (tic6x_supports_hardware_single_step): New function.
3271 (struct linux_target_ops) <tic6x_supports_hardware_single_step>:
3272 Initialize.
3273 * linux-tile-low.c (tile_supports_hardware_single_step): New function.
3274 (struct linux_target_ops) <tile_supports_hardware_single_step>:
3275 Initialize.
3276 * linux-x86-low.c (x86_supports_hardware_single_step) New function.
3277 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
3278 * linux-xtensa-low.c (xtensa_supports_hardware_single_step):
3279 New function.
3280 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
3281 * target.h (struct target_ops): <supports_software_single_step>:
3282 New field.
3283 (target_supports_software_single_step): New macro.
3284
3285 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
3286
3287 * linux-low.c (linux_wait_1): Fix pc advance condition.
3288 * mem-break.c (reinsert_breakpoint_inserted_here): New function.
3289 * mem-break.h (reinsert_breakpoint_inserted_here): New declaration.
3290
3291 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
3292
3293 * linux-arm-low.c (arm_is_thumb_mode): New function.
3294 (arm_breakpoint_at): Use arm_is_thumb_mode.
3295 (arm_breakpoint_kind_from_current_state): New function.
3296 (struct linux_target_ops) <breakpoint_kind_from_current_state>:
3297 Initialize.
3298 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_current_state.
3299 (linux_breakpoint_kind_from_current_state): New function.
3300 (struct target_ops <breakpoint_kind_from_current_state>: Initialize.
3301 * linux-low.h (struct linux_target_ops)
3302 <breakpoint_kind_from_current_state>: New field.
3303 * target.h (struct target_ops): Likewise.
3304 (target_breakpoint_kind_from_current_state): New macro.
3305
3306 2015-11-30 Pedro Alves <palves@redhat.com>
3307
3308 * linux-low.c (linux_resume): Wake up the event loop before
3309 returning.
3310
3311 2015-11-30 Pedro Alves <palves@redhat.com>
3312
3313 * mem-break.c (check_gdb_bp_preconditions): Remove current_thread
3314 check.
3315 (set_gdb_breakpoint): If prepare_to_access_memory fails, set *ERR
3316 to -1.
3317 * target.c (struct thread_search): New structure.
3318 (thread_search_callback): New function.
3319 (prev_general_thread): New global.
3320 (prepare_to_access_memory, done_accessing_memory): New functions.
3321 * target.h (prepare_to_access_memory, done_accessing_memory):
3322 Replace macros with function declarations.
3323
3324 2015-11-30 Pedro Alves <palves@redhat.com>
3325
3326 PR 14618
3327 * linux-low.c (linux_wait_1): If the last resumed thread is gone,
3328 report TARGET_WAITKIND_NO_RESUMED.
3329 * remote-utils.c (prepare_resume_reply): Handle
3330 TARGET_WAITKIND_NO_RESUMED.
3331 * server.c (report_no_resumed): New global.
3332 (handle_query) <qSupported>: Handle "no-resumed+". Report
3333 "no-resumed+" support.
3334 (resume): When the target reports TARGET_WAITKIND_NO_RESUMED, only
3335 return error if the client doesn't support no-resumed events.
3336 (push_stop_notification): New function.
3337 (handle_target_event): Use it. Report TARGET_WAITKIND_NO_RESUMED
3338 events if the client supports them.
3339
3340 2015-11-30 Pedro Alves <palves@redhat.com>
3341
3342 * linux-low.c (thread_still_has_status_pending_p): Don't check
3343 vCont;t here.
3344 (lwp_resumed): New function.
3345 (status_pending_p_callback): Return early if the LWP is not
3346 supposed to be resumed.
3347
3348 2015-11-30 Pedro Alves <palves@redhat.com>
3349
3350 * linux-low.c (handle_extended_wait): Assert that the LWP's
3351 waitstatus is TARGET_WAITKIND_IGNORE. If GDB wants to hear about
3352 thread create events, leave the new child's status pending.
3353 (linux_low_filter_event): If GDB wants to hear about thread exit
3354 events, leave the LWP marked dead and don't delete it.
3355 (linux_wait_for_event_filtered): Don't check for thread exit.
3356 (filter_exit_event): New function.
3357 (linux_wait_1): Use it, when returning an exit event.
3358 (linux_resume_one_lwp_throw): Assert that the LWP's
3359 waitstatus is TARGET_WAITKIND_IGNORE.
3360 * remote-utils.c (prepare_resume_reply): Handle
3361 TARGET_WAITKIND_THREAD_CREATED and TARGET_WAITKIND_THREAD_EXITED.
3362 * server.c (report_thread_events): New global.
3363 (handle_general_set): Handle QThreadEvents.
3364 (handle_query) <qSupported>: Handle and report QThreadEvents+;
3365 (handle_target_event): Handle TARGET_WAITKIND_THREAD_CREATED and
3366 TARGET_WAITKIND_THREAD_EXITED.
3367 * server.h (report_thread_events): Declare.
3368
3369 2015-11-30 Pedro Alves <palves@redhat.com>
3370
3371 * linux-low.c (resume_stopped_resumed_lwps): Don't check whether
3372 the thread's last_resume_kind was resume_stop.
3373
3374 2015-11-30 Pedro Alves <palves@redhat.com>
3375
3376 * linux-low.c (linux_attach): In non-stop mode, wait for one stop
3377 before returning.
3378
3379 2015-11-30 Pedro Alves <palves@redhat.com>
3380
3381 * server.c (handle_v_requests): Handle vCtrlC.
3382
3383 2015-11-30 Pedro Alves <palves@redhat.com>
3384
3385 * gdbthread.h (find_any_thread_of_pid): Declare.
3386 * inferiors.c (thread_of_pid, find_any_thread_of_pid): New
3387 functions.
3388 * server.c (handle_query): If current_thread is NULL, look for
3389 another thread of the selected process.
3390
3391 2015-11-26 Daniel Colascione <dancol@dancol.org>
3392 Simon Marchi <simon.marchi@ericsson.com>
3393
3394 * linux-low.c (linux_target_ops): Use linux_proc_tid_get_name.
3395 * server.c (handle_qxfer_threads_worker): Refactor to include thread
3396 name in reply.
3397 * target.h (struct target_ops) <thread_name>: New field.
3398 (target_thread_name): New macro.
3399
3400 2015-11-23 Joel Brobecker <brobecker@adacore.com>
3401
3402 * regcache.h (regcache_invalidate_pid): Add declaration.
3403 * regcache.c (regcache_invalidate_pid): New function, extracted
3404 from regcache_invalidate.
3405 (regcache_invalidate): Reimplement using regcache_invalidate_pid.
3406 Add trivial documentation comment.
3407 * lynx-low.c: Use regcache_invalidate_pid instead of
3408 regcache_invalidate.
3409
3410 2015-11-23 Joel Brobecker <brobecker@adacore.com>
3411
3412 * configure.ac: Do not call AC_CHECK_TYPES for Elf32_auxv_t
3413 and Elf64_auxv_t if the target is Android.
3414
3415 2015-11-22 Doug Evans <xdje42@gmail.com>
3416
3417 * target.h: #include <sys/types.h>.
3418
3419 2015-11-19 Pedro Alves <palves@redhat.com>
3420
3421 * linux-low.c (linux_process_qsupported): Change prototype.
3422 Adjust.
3423 * linux-low.h (struct linux_target_ops) <process_qsupported>:
3424 Change prototype.
3425 * linux-x86-low.c (x86_linux_process_qsupported): Change prototype
3426 and adjust to loop over all features.
3427 * server.c (handle_query) <qSupported>: Adjust to call
3428 target_process_qsupported once, passing it a vector of unprocessed
3429 features.
3430 * target.h (struct target_ops) <process_qsupported>: Change
3431 prototype.
3432 (target_process_qsupported): Adjust.
3433
3434 2015-11-19 Pedro Alves <palves@redhat.com>
3435
3436 * configure.ac (ERROR_ON_WARNING): Don't check whether in C++
3437 mode.
3438 * configure: Regenerate.
3439
3440 2015-11-19 Pedro Alves <palves@redhat.com>
3441
3442 * configure: Regenerate.
3443
3444 2015-11-19 Yao Qi <yao.qi@linaro.org>
3445
3446 * linux-aarch64-low.c (emit_data_processing_reg): Change opcode
3447 type to uint32_t.
3448
3449 2015-11-19 Yao Qi <yao.qi@linaro.org>
3450
3451 * linux-aarch64-low.c (enum aarch64_operand_type): New.
3452 (struct aarch64_operand): Move enum out.
3453
3454 2015-11-19 Yao Qi <yao.qi@linaro.org>
3455
3456 * linux-aarch64-low.c (aarch64_fill_fpregset): Cast buf to
3457 struct user_fpsimd_state *.
3458 (aarch64_store_fpregset): Likewise.
3459
3460 2015-11-19 Yao Qi <yao.qi@linaro.org>
3461
3462 * linux-aarch64-low.c (aarch64_fill_gregset): Cast buf to
3463 struct user_pt_regs *.
3464 (aarch64_store_gregset): Likewise.
3465
3466 2015-11-18 Pedro Alves <palves@redhat.com>
3467
3468 * Makefile.in (all_object_files): Add $IPA_OBJS.
3469
3470 2015-11-17 Pedro Alves <palves@redhat.com>
3471
3472 * win32-low.c (win32_resume): Use gdb_signal_from_host,
3473 GDB_SIGNAL_0 and gdb_signal_to_string.
3474
3475 2015-11-17 Pedro Alves <palves@redhat.com>
3476
3477 * win32-low.c (handle_output_debug_string): Remove parameter.
3478 (win32_kill): Remove our_status local and adjust call to
3479 handle_output_debug_string.
3480 (get_child_debug_event): Adjust call to
3481 handle_output_debug_string.
3482
3483 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
3484
3485 * linux-mips-low.c (mips_fill_gregset): Add cast.
3486 (mips_store_gregset): Likewise.
3487 (mips_fill_fpregset): Likewise.
3488 (mips_store_fpregset): Likewise.
3489
3490 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
3491
3492 * linux-mips-low.c (mips_add_watchpoint): Rename private to
3493 priv.
3494
3495 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
3496
3497 * linux-mips-low.c (mips_linux_new_thread): Change type of
3498 watch_type to enum target_hw_bp_type.
3499
3500 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
3501
3502 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type):
3503 Change return type to arm_hwbp_type.
3504
3505 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
3506
3507 * linux-aarch32-low.c (arm_fill_gregset): Add cast.
3508 (arm_store_gregset): Likewise.
3509 * linux-arm-low.c (arm_get_hwcap): Likewise.
3510 (arm_read_description): Likewise.
3511
3512 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
3513
3514 * linux-aarch32-low.c (aarch32_regsets): Use NULL_REGSET.
3515
3516 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
3517
3518 * linux-ppc-low.c (ppc_get_hwcap): Add cast.
3519 (ppc_fill_vsxregset): Likewise.
3520 (ppc_store_vsxregset): Likewise.
3521 (ppc_fill_vrregset): Likewise.
3522 (ppc_store_vrregset): Likewise.
3523 (ppc_fill_evrregset): Likewise.
3524 (ppc_store_evrregset): Likewise.
3525
3526 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
3527
3528 * linux-ppc-low.c (ppc_usrregs_info): Remove
3529 forward-declaration.
3530 (ppc_arch_setup): Move lower in file.
3531
3532 2015-10-30 Simon Marchi <simon.marchi@ericsson.com>
3533
3534 * proc-service.c (ps_pdread): Change CORE_ADDR cast to uintptr_t.
3535 (ps_pdwrite): Likewise.
3536
3537 2015-10-29 Henrik Wallin <henrik.wallin@windriver.com>
3538
3539 * linux-arm-low.c (arm_new_thread): Move pointer dereference
3540 to after assert checks.
3541
3542 2015-10-29 Simon Marchi <simon.marchi@ericsson.com>
3543
3544 * proc-service.c (ps_pdread): Add/adjust casts.
3545 (ps_pdwrite): Add/adjust casts.
3546
3547 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
3548
3549 * server.c (handle_search_memory_1): Cast return value of
3550 memmem.
3551
3552 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
3553
3554 * server.c (write_qxfer_response): Change type of data to
3555 gdb_byte *.
3556
3557 2015-10-29 Pedro Alves <palves@redhat.com>
3558
3559 * mem-break.c (Z_packet_to_bkpt_type): Add cast.
3560
3561 2015-10-29 Pedro Alves <palves@redhat.com>
3562
3563 * tracepoint.c (clear_installed_tracepoints): Add casts.
3564
3565 2015-10-29 Pedro Alves <palves@redhat.com>
3566
3567 * server.c (handle_v_cont, process_serial_event): Add enum
3568 gdb_signal casts to signal parsing code.
3569
3570 2015-10-29 Pedro Alves <palves@redhat.com>
3571
3572 * linux-low.h (NULL_REGSET): Define.
3573 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
3574 * linux-arm-low.c (arm_regsets): Likewise.
3575 * linux-crisv32-low.c (cris_regsets): Likewise.
3576 * linux-m68k-low.c (m68k_regsets): Likewise.
3577 * linux-mips-low.c (mips_regsets): Likewise.
3578 * linux-nios2-low.c (nios2_regsets): Likewise.
3579 * linux-ppc-low.c (ppc_regsets): Likewise.
3580 * linux-s390-low.c (s390_regsets): Likewise.
3581 * linux-sh-low.c (sh_regsets): Likewise.
3582 * linux-sparc-low.c (sparc_regsets): Likewise.
3583 * linux-tic6x-low.c (tic6x_regsets): Likewise.
3584 * linux-tile-low.c (tile_regsets): Likewise.
3585 * linux-x86-low.c (x86_regsets): Likewise.
3586 * linux-xtensa-low.c (xtensa_regsets): Likewise.
3587
3588 2015-10-29 Pedro Alves <palves@redhat.com>
3589
3590 * linux-low.h (NULL_REGSET): Define.
3591 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
3592 * linux-arm-low.c (arm_regsets): Likewise.
3593 * linux-crisv32-low.c (cris_regsets): Likewise.
3594 * linux-m68k-low.c (m68k_regsets): Likewise.
3595 * linux-mips-low.c (mips_regsets): Likewise.
3596 * linux-nios2-low.c (nios2_regsets): Likewise.
3597 * linux-ppc-low.c (ppc_regsets): Likewise.
3598 * linux-s390-low.c (s390_regsets): Likewise.
3599 * linux-sh-low.c (sh_regsets): Likewise.
3600 * linux-sparc-low.c (sparc_regsets): Likewise.
3601 * linux-tic6x-low.c (tic6x_regsets): Likewise.
3602 * linux-tile-low.c (tile_regsets): Likewise.
3603 * linux-x86-low.c (x86_regsets): Likewise.
3604 * linux-xtensa-low.c (xtensa_regsets): Likewise.
3605
3606 2015-10-26 Doug Evans <dje@google.com>
3607
3608 * linux-low.c (__SIGRTMIN): Move to nat/linux-nat.h.
3609
3610 2015-10-26 Doug Evans <dje@google.com>
3611
3612 * linux-low.c (W_STOPCODE): Moved to common/gdb_wait.h.
3613
3614 2015-10-26 Doug Evans <dje@google.com>
3615
3616 * thread-db.c (find_one_thread): Cast ti.ti_tid to unsigned long
3617 for debug_printf.
3618 (attach_thread, find_new_threads_callback): Ditto.
3619
3620 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
3621
3622 * mem-break.h (set_breakpoint_data): Remove.
3623
3624 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
3625
3626 * nto-low.c (nto_sw_breakpoint_from_kind): New function.
3627 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
3628 (initialize_low): Remove set_breakpoint_data call.
3629 * spu-low.c (spu_sw_breakpoint_from_kind): New function.
3630 (struct target_ops) <sw_breakpoint_from_kind>: Iniitalize.
3631 (initialize_low): Remove set_breakpoint_data call.
3632 * win32-low.c (win32_sw_breakpoint_from_kind): New function.
3633 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
3634 (initialize_low): Remove set_breakpoint_data call.
3635
3636 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
3637
3638 * linux-low.c (default_breakpoint_kind_from_pc): Move to target.c.
3639 * mem-break.c (set_breakpoint_at): Use target_breakpoint_kind_from_pc.
3640 * target.c (default_breakpoint_kind_from_pc): Moved from linux-low.c
3641 * target.h (target_breakpoint_kind_from_pc): New macro.
3642
3643 2015-10-22 Antoine Tremblay <antoine.tremblay@ericsson.com>
3644
3645 * linux-low.c (default_breakpoint_kind_from_pc): New function.
3646 (linux_breakpoint_kind_from_pc): Use default_breakpoint_kind_from_pc for
3647 the default breakpoint kind.
3648
3649 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
3650
3651 * linux-arm-low.c (arm_supports_z_point_type): Add software
3652 breakpoint support.
3653
3654 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
3655
3656 * linux-arm-low.c: Refactor breakpoint definitions.
3657 (arm_breakpoint_at): Adjust for arm_abi_breakpoint.
3658 (arm_sw_breakpoint_from_kind): Adjust for arm_breakpoint.
3659
3660 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
3661
3662 * Makefile.in: Add arm.c/o.
3663 * configure.srv: Likewise.
3664 * linux-arm-low.c (arm_breakpoint_kinds): New enum.
3665 (arm_breakpoint_kind_from_pc): New function.
3666 (arm_sw_breakpoint_from_kind): Return proper kind.
3667 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize.
3668
3669 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
3670
3671 * linux-low.c (initialize_low): Ajdust for breakpoint global variables
3672 removal.
3673 * mem-break.c : Remove breakpoint_data/breakpoint_len global variables.
3674 (struct raw_breakpoint) <size>: Remove.
3675 (struct raw_breakpoint) <kind>: Add.
3676 (bp_size): New function.
3677 (bp_opcode): Likewise.
3678 (find_raw_breakpoint_at): Adjust for kind.
3679 (insert_memory_breakpoint): Adjust for kind call bp_size,bp_opcode.
3680 (remove_memory_breakpoint): Adjust for kind call bp_size.
3681 (set_raw_breakpoint_at): Adjust for kind.
3682 (set_breakpoint): Likewise.
3683 (set_breakpoint_at): Call breakpoint_kind_from_pc.
3684 (delete_raw_breakpoint): Adjust for kind.
3685 (delete_breakpoint): Likewise.
3686 (find_gdb_breakpoint): Likewise.
3687 (set_gdb_breakpoint_1): Likewise.
3688 (set_gdb_breakpoint): Likewise.
3689 (delete_gdb_breakpoint_1): Likewise.
3690 (delete_gdb_breakpoint): Likewise.
3691 (uninsert_raw_breakpoint): Likewise.
3692 (reinsert_raw_breakpoint): Likewise.
3693 (set_breakpoint_data): Remove.
3694 (validate_inserted_breakpoint): Adjust for kind call bp_size,bp_opcode.
3695 (check_mem_read): Adjust for kind call bp_size.
3696 (check_mem_write): Adjust for kind call bp_size,bp_opcode.
3697 (clone_one_breakpoint): Adjust for kind.
3698 * mem-break.h (set_gdb_breakpoint): Likewise.
3699 (delete_gdb_breakpoint): Likewise.
3700 * server.c (process_serial_event): Likewise.
3701
3702 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
3703
3704 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): New function.
3705 (struct linux_target_ops) <breakpoint>: Remove.
3706 (struct linux_target_ops) <breakpoint_len>: Remove.
3707 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
3708 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
3709 * linux-arm-low.c (arm_breakpoint_kind_from_pc): New function.
3710 (arm_sw_breakpoint_from_kind): New function.
3711 * linux-bfin-low.c (bfin_sw_breakpoint_from_kind): New function.
3712 (struct linux_target_ops) <breakpoint>: Remove.
3713 (struct linux_target_ops) <breakpoint_len>: Remove.
3714 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
3715 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
3716 * linux-cris-low.c (cris_sw_breakpoint_from_kind): New function.
3717 (struct linux_target_ops) <breakpoint>: Remove.
3718 (struct linux_target_ops) <breakpoint_len>: Remove.
3719 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
3720 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
3721 * linux-crisv32-low.c (cris_sw_breakpoint_from_kind): New function.
3722 (struct linux_target_ops) <breakpoint>: Remove.
3723 (struct linux_target_ops) <breakpoint_len>: Remove.
3724 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
3725 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
3726 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_pc
3727 and sw_breakpoint_from_kind to increment the pc.
3728 (linux_breakpoint_kind_from_pc): New function.
3729 (linux_sw_breakpoint_from_kind): New function.
3730 (struct target_ops) <sw_breakpoint_from_kind>: Initialize field.
3731 (initialize_low): Call breakpoint_kind_from_pc and
3732 sw_breakpoint_from_kind to replace breakpoint_data/len.
3733 * linux-low.h (struct linux_target_ops) <breakpoint_kind_from_pc>:
3734 New field.
3735 (struct linux_target_ops) <sw_breakpoint_from_kind>: Likewise.
3736 * linux-m32r-low.c (m32r_sw_breakpoint_from_kind): New function.
3737 (struct linux_target_ops) <breakpoint>: Remove.
3738 (struct linux_target_ops) <breakpoint_len>: Remove.
3739 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
3740 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
3741 * linux-m68k-low.c (m68k_sw_breakpoint_from_kind): New function.
3742 (struct linux_target_ops) <breakpoint>: Remove.
3743 (struct linux_target_ops) <breakpoint_len>: Remove.
3744 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
3745 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
3746 * linux-mips-low.c (mips_sw_breakpoint_from_kind): New function.
3747 (struct linux_target_ops) <breakpoint>: Remove.
3748 (struct linux_target_ops) <breakpoint_len>: Remove.
3749 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
3750 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
3751 * linux-nios2-low.c (nios2_sw_breakpoint_from_kind): New function.
3752 (struct linux_target_ops) <breakpoint>: Remove.
3753 (struct linux_target_ops) <breakpoint_len>: Remove.
3754 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
3755 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
3756 * linux-ppc-low.c (ppc_sw_breakpoint_from_kind): New function.
3757 (struct linux_target_ops) <breakpoint>: Remove.
3758 (struct linux_target_ops) <breakpoint_len>: Remove.
3759 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
3760 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
3761 * linux-s390-low.c (s390_sw_breakpoint_from_kind): New function.
3762 (struct linux_target_ops) <breakpoint>: Remove.
3763 (struct linux_target_ops) <breakpoint_len>: Remove.
3764 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
3765 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
3766 * linux-sh-low.c (sh_sw_breakpoint_from_kind): New function.
3767 (struct linux_target_ops) <breakpoint>: Remove.
3768 (struct linux_target_ops) <breakpoint_len>: Remove.
3769 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
3770 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
3771 * linux-sparc-low.c (sparc_sw_breakpoint_from_kind): New function.
3772 (struct linux_target_ops) <breakpoint>: Remove.
3773 (struct linux_target_ops) <breakpoint_len>: Remove.
3774 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
3775 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
3776 * linux-tic6x-low.c (tic6x_sw_breakpoint_from_kind): New function.
3777 (struct linux_target_ops) <breakpoint>: Remove.
3778 (struct linux_target_ops) <breakpoint_len>: Remove.
3779 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
3780 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
3781 * linux-tile-low.c (tile_sw_breakpoint_from_kind): New function.
3782 * linux-x86-low.c (x86_sw_breakpoint_from_kind): New function.
3783 (struct linux_target_ops) <breakpoint>: Remove.
3784 (struct linux_target_ops) <breakpoint_len>: Remove.
3785 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
3786 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
3787 * linux-xtensa-low.c (xtensa_sw_breakpoint_from_kind) New function.
3788 (struct linux_target_ops) <breakpoint>: Remove.
3789 (struct linux_target_ops) <breakpoint_len>: Remove.
3790 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
3791 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
3792
3793 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
3794
3795 * linux-cris-low.c (cris_get_pc): Remove void arg.
3796
3797 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
3798
3799 * gdbserver/nto-low.c (nto_insert_point, nto_remove_point): Fix
3800 variable name.
3801
3802 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
3803
3804 * inferiors.c (thread_pid_matches_callback): New function.
3805 (find_thread_process): New function.
3806 (remove_thread): Reset current_thread.
3807 (remove_process): Assert threads have been removed first.
3808
3809 2015-10-15 Yao Qi <yao.qi@linaro.org>
3810
3811 * linux-aarch64-low.c (aarch64_insert_point): Set len to 2
3812 if it is 3.
3813 (aarch64_remove_point): Likewise.
3814 * regcache.c (regcache_register_size): New function.
3815
3816 2015-10-12 Yao Qi <yao.qi@linaro.org>
3817
3818 * linux-aarch64-low.c: Update all callers as emit_load_store
3819 is renamed to aarch64_emit_load_store.
3820
3821 2015-10-12 Yao Qi <yao.qi@linaro.org>
3822
3823 * linux-aarch64-low.c: Update all callers of function renaming
3824 from emit_insn to aarch64_emit_insn.
3825
3826 2015-10-12 Yao Qi <yao.qi@linaro.org>
3827
3828 * linux-aarch64-low.c (enum aarch64_opcodes): Move to
3829 arch/aarch64-insn.h.
3830 (struct aarch64_memory_operand): Likewise.
3831 (ENCODE): Likewise.
3832 (emit_insn): Move to arch/aarch64-insn.c.
3833 (emit_b, emit_bcond, emit_cb, emit_tb): Remove.
3834 (emit_load_store): Move to arch/aarch64-insn.c.
3835 (emit_ldr, emit_ldrb, emit_ldrsw, emit_nop): Remove.
3836 (can_encode_int32): Remove.
3837
3838 2015-10-12 Yao Qi <yao.qi@linaro.org>
3839
3840 * linux-aarch64-low.c (extract_signed_bitfield): Remove.
3841 (aarch64_decode_ldr_literal): Move to gdb/arch/aarch64-insn.c.
3842 (aarch64_relocate_instruction): Likewise.
3843 (struct aarch64_insn_data): Move to gdb/arch/aarch64-insn.h.
3844 (struct aarch64_insn_visitor): Likewise.
3845
3846 2015-10-12 Yao Qi <yao.qi@linaro.org>
3847
3848 * linux-aarch64-low.c (struct aarch64_insn_data): New.
3849 (struct aarch64_insn_visitor): New.
3850 (struct aarch64_insn_relocation_data): New.
3851 (aarch64_ftrace_insn_reloc_b): New function.
3852 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
3853 (aarch64_ftrace_insn_reloc_cb): Likewise.
3854 (aarch64_ftrace_insn_reloc_tb): Likewise.
3855 (aarch64_ftrace_insn_reloc_adr): Likewise.
3856 (aarch64_ftrace_insn_reloc_ldr_literal): Likewise.
3857 (aarch64_ftrace_insn_reloc_others): Likewise.
3858 (visitor): New.
3859 (aarch64_relocate_instruction): Use visitor.
3860
3861 2015-10-12 Yao Qi <yao.qi@linaro.org>
3862
3863 * linux-aarch64-low.c (aarch64_relocate_instruction): Return
3864 int. Add argument buf.
3865 (aarch64_install_fast_tracepoint_jump_pad): Pass buf to
3866 aarch64_relocate_instruction.
3867
3868 2015-10-12 Yao Qi <yao.qi@linaro.org>
3869
3870 * linux-aarch64-low.c (aarch64_relocate_instruction): Add
3871 argument insn. Remove local variable insn. Don't call
3872 target_read_uint32.
3873 (aarch64_install_fast_tracepoint_jump_pad): Call
3874 target_read_uint32.
3875
3876 2015-09-30 Yao Qi <yao.qi@linaro.org>
3877
3878 * linux-aarch64-low.c (emit_movk): Shorten a long line.
3879 (emit_load_store_pair): Likewise.
3880
3881 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
3882
3883 * dll.c (match_dll): Add cast(s).
3884 (unloaded_dll): Likewise.
3885 * linux-low.c (second_thread_of_pid_p): Likewise.
3886 (delete_lwp_callback): Likewise.
3887 (count_events_callback): Likewise.
3888 (select_event_lwp_callback): Likewise.
3889 (linux_set_resume_request): Likewise.
3890 * server.c (accumulate_file_name_length): Likewise.
3891 (emit_dll_description): Likewise.
3892 (handle_qxfer_threads_worker): Likewise.
3893 (visit_actioned_threads): Likewise.
3894 * thread-db.c (any_thread_of): Likewise.
3895 * tracepoint.c (same_process_p): Likewise.
3896 (match_blocktype): Likewise.
3897 (build_traceframe_info_xml): Likewise.
3898
3899 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
3900
3901 * ax.c (gdb_parse_agent_expr): Add cast to allocation result
3902 assignment.
3903 (gdb_unparse_agent_expr): Likewise.
3904 * hostio.c (require_data): Likewise.
3905 (handle_pread): Likewise.
3906 * linux-low.c (disable_regset): Likewise.
3907 (fetch_register): Likewise.
3908 (store_register): Likewise.
3909 (get_dynamic): Likewise.
3910 (linux_qxfer_libraries_svr4): Likewise.
3911 * mem-break.c (delete_fast_tracepoint_jump): Likewise.
3912 (set_fast_tracepoint_jump): Likewise.
3913 (uninsert_fast_tracepoint_jumps_at): Likewise.
3914 (reinsert_fast_tracepoint_jumps_at): Likewise.
3915 (validate_inserted_breakpoint): Likewise.
3916 (clone_agent_expr): Likewise.
3917 * regcache.c (init_register_cache): Likewise.
3918 * remote-utils.c (putpkt_binary_1): Likewise.
3919 (decode_M_packet): Likewise.
3920 (decode_X_packet): Likewise.
3921 (look_up_one_symbol): Likewise.
3922 (relocate_instruction): Likewise.
3923 (monitor_output): Likewise.
3924 * server.c (handle_search_memory): Likewise.
3925 (handle_qxfer_exec_file): Likewise.
3926 (handle_qxfer_libraries): Likewise.
3927 (handle_qxfer): Likewise.
3928 (handle_query): Likewise.
3929 (handle_v_cont): Likewise.
3930 (handle_v_run): Likewise.
3931 (captured_main): Likewise.
3932 * target.c (write_inferior_memory): Likewise.
3933 * thread-db.c (try_thread_db_load_from_dir): Likewise.
3934 * tracepoint.c (init_trace_buffer): Likewise.
3935 (add_tracepoint_action): Likewise.
3936 (add_traceframe): Likewise.
3937 (add_traceframe_block): Likewise.
3938 (cmd_qtdpsrc): Likewise.
3939 (cmd_qtdv): Likewise.
3940 (cmd_qtstatus): Likewise.
3941 (response_source): Likewise.
3942 (response_tsv): Likewise.
3943 (cmd_qtnotes): Likewise.
3944 (gdb_collect): Likewise.
3945 (initialize_tracepoint): Likewise.
3946
3947 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
3948
3949 * linux-aarch64-low-.c: Include ax.h and tracepoint.h.
3950 (enum aarch64_opcodes) <RET>, <SUBS>, <AND>, <ORR>, <ORN>,
3951 <EOR>, <LSLV>, <LSRV>, <ASRV>, <SBFM>, <UBFM>, <CSINC>, <MUL>,
3952 <NOP>: New.
3953 (enum aarch64_condition_codes): New enum.
3954 (w0): New static global.
3955 (fp): Likewise.
3956 (lr): Likewise.
3957 (struct aarch64_memory_operand) <type>: New
3958 MEMORY_OPERAND_POSTINDEX type.
3959 (postindex_memory_operand): New helper function.
3960 (emit_ret): New function.
3961 (emit_load_store_pair): New function, factored out of emit_stp
3962 with support for MEMORY_OPERAND_POSTINDEX.
3963 (emit_stp): Rewrite using emit_load_store_pair.
3964 (emit_ldp): New function.
3965 (emit_load_store): Likewise.
3966 (emit_ldr): Mention post-index instruction in comment.
3967 (emit_ldrh): New function.
3968 (emit_ldrb): New function.
3969 (emit_ldrsw): Mention post-index instruction in comment.
3970 (emit_str): Likewise.
3971 (emit_subs): New function.
3972 (emit_cmp): Likewise.
3973 (emit_and): Likewise.
3974 (emit_orr): Likewise.
3975 (emit_orn): Likewise.
3976 (emit_eor): Likewise.
3977 (emit_mvn): Likewise.
3978 (emit_lslv): Likewise.
3979 (emit_lsrv): Likewise.
3980 (emit_asrv): Likewise.
3981 (emit_mul): Likewise.
3982 (emit_sbfm): Likewise.
3983 (emit_sbfx): Likewise.
3984 (emit_ubfm): Likewise.
3985 (emit_ubfx): Likewise.
3986 (emit_csinc): Likewise.
3987 (emit_cset): Likewise.
3988 (emit_nop): Likewise.
3989 (emit_ops_insns): New helper function.
3990 (emit_pop): Likewise.
3991 (emit_push): Likewise.
3992 (aarch64_emit_prologue): New function.
3993 (aarch64_emit_epilogue): Likewise.
3994 (aarch64_emit_add): Likewise.
3995 (aarch64_emit_sub): Likewise.
3996 (aarch64_emit_mul): Likewise.
3997 (aarch64_emit_lsh): Likewise.
3998 (aarch64_emit_rsh_signed): Likewise.
3999 (aarch64_emit_rsh_unsigned): Likewise.
4000 (aarch64_emit_ext): Likewise.
4001 (aarch64_emit_log_not): Likewise.
4002 (aarch64_emit_bit_and): Likewise.
4003 (aarch64_emit_bit_or): Likewise.
4004 (aarch64_emit_bit_xor): Likewise.
4005 (aarch64_emit_bit_not): Likewise.
4006 (aarch64_emit_equal): Likewise.
4007 (aarch64_emit_less_signed): Likewise.
4008 (aarch64_emit_less_unsigned): Likewise.
4009 (aarch64_emit_ref): Likewise.
4010 (aarch64_emit_if_goto): Likewise.
4011 (aarch64_emit_goto): Likewise.
4012 (aarch64_write_goto_address): Likewise.
4013 (aarch64_emit_const): Likewise.
4014 (aarch64_emit_call): Likewise.
4015 (aarch64_emit_reg): Likewise.
4016 (aarch64_emit_pop): Likewise.
4017 (aarch64_emit_stack_flush): Likewise.
4018 (aarch64_emit_zero_ext): Likewise.
4019 (aarch64_emit_swap): Likewise.
4020 (aarch64_emit_stack_adjust): Likewise.
4021 (aarch64_emit_int_call_1): Likewise.
4022 (aarch64_emit_void_call_2): Likewise.
4023 (aarch64_emit_eq_goto): Likewise.
4024 (aarch64_emit_ne_goto): Likewise.
4025 (aarch64_emit_lt_goto): Likewise.
4026 (aarch64_emit_le_goto): Likewise.
4027 (aarch64_emit_gt_goto): Likewise.
4028 (aarch64_emit_ge_got): Likewise.
4029 (aarch64_emit_ops_impl): New static global variable.
4030 (aarch64_emit_ops): New target function, return
4031 &aarch64_emit_ops_impl.
4032 (struct linux_target_ops): Install it.
4033
4034 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
4035
4036 * Makefile.in (linux-aarch64-ipa.o, aarch64-ipa.o): New rules.
4037 * configure.srv (aarch64*-*-linux*): Add linux-aarch64-ipa.o and
4038 aarch64-ipa.o.
4039 * linux-aarch64-ipa.c: New file.
4040 * linux-aarch64-low.c: Include arch/aarch64-insn.h, inttypes.h
4041 and endian.h.
4042 (aarch64_get_thread_area): New target method.
4043 (extract_signed_bitfield): New helper function.
4044 (aarch64_decode_ldr_literal): New function.
4045 (enum aarch64_opcodes): New enum.
4046 (struct aarch64_register): New struct.
4047 (struct aarch64_operand): New struct.
4048 (x0): New static global.
4049 (x1): Likewise.
4050 (x2): Likewise.
4051 (x3): Likewise.
4052 (x4): Likewise.
4053 (w2): Likewise.
4054 (ip0): Likewise.
4055 (sp): Likewise.
4056 (xzr): Likewise.
4057 (aarch64_register): New helper function.
4058 (register_operand): Likewise.
4059 (immediate_operand): Likewise.
4060 (struct aarch64_memory_operand): New struct.
4061 (offset_memory_operand): New helper function.
4062 (preindex_memory_operand): Likewise.
4063 (enum aarch64_system_control_registers): New enum.
4064 (ENCODE): New macro.
4065 (emit_insn): New helper function.
4066 (emit_b): New function.
4067 (emit_bcond): Likewise.
4068 (emit_cb): Likewise.
4069 (emit_tb): Likewise.
4070 (emit_blr): Likewise.
4071 (emit_stp): Likewise.
4072 (emit_ldp_q_offset): Likewise.
4073 (emit_stp_q_offset): Likewise.
4074 (emit_load_store): Likewise.
4075 (emit_ldr): Likewise.
4076 (emit_ldrsw): Likewise.
4077 (emit_str): Likewise.
4078 (emit_ldaxr): Likewise.
4079 (emit_stxr): Likewise.
4080 (emit_stlr): Likewise.
4081 (emit_data_processing_reg): Likewise.
4082 (emit_data_processing): Likewise.
4083 (emit_add): Likewise.
4084 (emit_sub): Likewise.
4085 (emit_mov): Likewise.
4086 (emit_movk): Likewise.
4087 (emit_mov_addr): Likewise.
4088 (emit_mrs): Likewise.
4089 (emit_msr): Likewise.
4090 (emit_sevl): Likewise.
4091 (emit_wfe): Likewise.
4092 (append_insns): Likewise.
4093 (can_encode_int32_in): New helper function.
4094 (aarch64_relocate_instruction): New function.
4095 (aarch64_install_fast_tracepoint_jump_pad): Likewise.
4096 (aarch64_get_min_fast_tracepoint_insn_len): Likewise.
4097 (struct linux_target_ops): Install aarch64_get_thread_area,
4098 aarch64_install_fast_tracepoint_jump_pad and
4099 aarch64_get_min_fast_tracepoint_insn_len.
4100
4101 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
4102
4103 * Makefile.in (aarch64-insn.o): New rule.
4104 * configure.srv (aarch64*-*-linux*): Add aarch64-insn.o.
4105
4106 2015-09-21 Yao Qi <yao.qi@linaro.org>
4107
4108 * ax.c [!IN_PROCESS_AGENT] (gdb_agent_op_sizes): Define it.
4109
4110 2015-09-21 Yao Qi <yao.qi@linaro.org>
4111
4112 * tracepoint.c (max_jump_pad_size): Remove.
4113
4114 2015-09-18 Yao Qi <yao.qi@linaro.org>
4115
4116 * linux-aarch64-low.c: Don't include sys/uio.h.
4117 (ps_get_thread_area): Call aarch64_ps_get_thread_area.
4118
4119 2015-09-16 Wei-cheng Wang <cole945@gmail.com>
4120
4121 * tracepoint.c (eval_result_type): Change prototype.
4122 (condition_true_at_tracepoint): Fix argument to compiled_cond.
4123
4124 2015-09-15 Pedro Alves <palves@redhat.com>
4125
4126 * remote-utils.c (prepare_resume_reply) <TARGET_WAITKIND_EXECD>:
4127 Check whether to report exec events instead of checking whether
4128 multiprocess is enabled.
4129
4130 2015-09-15 Pedro Alves <palves@redhat.com>
4131
4132 PR remote/18965
4133 * remote-utils.c (prepare_resume_reply): Merge
4134 TARGET_WAITKIND_VFORK_DONE switch case with the
4135 TARGET_WAITKIND_FORKED case.
4136
4137 2015-09-15 Yao Qi <yao.qi@linaro.org>
4138
4139 * server.c (handle_query): Check string comparison using
4140 "else if" instead of "if".
4141
4142 2015-09-15 Yao Qi <yao.qi@linaro.org>
4143
4144 * server.c (vCont_supported): New global variable.
4145 (handle_query): Set vCont_supported to 1 if "vContSupported+"
4146 matches. Append ";vContSupported+" to own_buf.
4147 (handle_v_requests): Append ";s;S" to own_buf if target supports
4148 hardware single step or vCont_supported is false.
4149 (capture_main): Set vCont_supported to zero.
4150
4151 2015-09-15 Yao Qi <yao.qi@linaro.org>
4152
4153 * linux-low.c (linux_supports_conditional_breakpoints): Rename
4154 it to ...
4155 (linux_supports_hardware_single_step): ... New function.
4156 (linux_target_ops): Update.
4157 * lynx-low.c (lynx_target_ops): Set field
4158 supports_hardware_single_step to target_can_do_hardware_single_step.
4159 * nto-low.c (nto_target_ops): Likewise.
4160 * spu-low.c (spu_target_ops): Likewise.
4161 * win32-low.c (win32_target_ops): Likewise.
4162 * target.c (target_can_do_hardware_single_step): New function.
4163 * target.h (struct target_ops) <supports_conditional_breakpoints>:
4164 Remove. <supports_hardware_single_step>: New field.
4165 (target_supports_conditional_breakpoints): Remove.
4166 (target_supports_hardware_single_step): New macro.
4167 (target_can_do_hardware_single_step): Declare.
4168 * server.c (handle_query): Use target_supports_hardware_single_step
4169 instead of target_supports_conditional_breakpoints.
4170
4171 2015-09-15 Yao Qi <yao.qi@linaro.org>
4172
4173 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): New
4174 function.
4175 (struct linux_target_ops the_low_target): Install
4176 aarch64_linux_siginfo_fixup.
4177
4178 2015-09-11 Don Breazeal <donb@codesourcery.com>
4179 Luis Machado <lgustavo@codesourcery.com>
4180
4181 * linux-low.c (linux_mourn): Static declaration.
4182 (linux_arch_setup): Move in front of
4183 handle_extended_wait.
4184 (linux_arch_setup_thread): New function.
4185 (handle_extended_wait): Handle exec events. Call
4186 linux_arch_setup_thread. Make event_lwp argument a
4187 pointer-to-a-pointer.
4188 (check_zombie_leaders): Do not check stopped threads.
4189 (linux_low_ptrace_options): Add PTRACE_O_TRACEEXEC.
4190 (linux_low_filter_event): Add lwp and thread for exec'ing
4191 non-leader thread if leader thread has been deleted.
4192 Refactor code into linux_arch_setup_thread and call it.
4193 Pass child lwp pointer by reference to handle_extended_wait.
4194 (linux_wait_for_event_filtered): Update comment.
4195 (linux_wait_1): Prevent clobbering exec event status.
4196 (linux_supports_exec_events): New function.
4197 (linux_target_ops) <supports_exec_events>: Initialize new member.
4198 * lynx-low.c (lynx_target_ops) <supports_exec_events>: Initialize
4199 new member.
4200 * remote-utils.c (prepare_resume_reply): New stop reason 'exec'.
4201 * server.c (report_exec_events): New global variable.
4202 (handle_query): Handle qSupported query for exec-events feature.
4203 (captured_main): Initialize report_exec_events.
4204 * server.h (report_exec_events): Declare new global variable.
4205 * target.h (struct target_ops) <supports_exec_events>: New
4206 member.
4207 (target_supports_exec_events): New macro.
4208 * win32-low.c (win32_target_ops) <supports_exec_events>:
4209 Initialize new member.
4210
4211 2015-09-09 Markus Metzger <markus.t.metzger@intel.com>
4212
4213 * linux-low.c (linux_low_enable_btrace): Remove.
4214 (linux_target_ops): Replace linux_low_enable_btrace with
4215 linux_enable_btrace.
4216
4217 2015-09-03 Yao Qi <yao.qi@linaro.org>
4218
4219 * linux-aarch64-low.c (aarch64_insert_point): Call
4220 aarch64_handle_watchpoint if aarch64_linux_region_ok_for_watchpoint
4221 returns true.
4222
4223 2015-08-27 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
4224
4225 * linux-low.c (check_stopped_by_breakpoint): Use
4226 GDB_ARCH_IS_TRAP_BRKPT instead of GDB_ARCH_TRAP_BRKPT.
4227
4228 2015-08-27 Pedro Alves <palves@redhat.com>
4229
4230 * proc-service.c (ps_pdwrite): Return PS_ERR/PS_OK explicily.
4231
4232 2015-08-26 Simon Marchi <simon.marchi@ericsson.com>
4233
4234 * ax.c (gdb_parse_agent_expr): Replace xmalloc-family function with
4235 the XNEW-family equivalent.
4236 (compile_bytecodes): Likewise.
4237 * dll.c (loaded_dll): Likewise.
4238 * event-loop.c (append_callback_event): Likewise.
4239 (create_file_handler): Likewise.
4240 (create_file_event): Likewise.
4241 * hostio.c (handle_open): Likewise.
4242 * inferiors.c (add_thread): Likewise.
4243 (add_process): Likewise.
4244 * linux-aarch64-low.c (aarch64_linux_new_process): Likewise.
4245 * linux-arm-low.c (arm_new_process): Likewise.
4246 (arm_new_thread): Likewise.
4247 * linux-low.c (add_to_pid_list): Likewise.
4248 (linux_add_process): Likewise.
4249 (handle_extended_wait): Likewise.
4250 (add_lwp): Likewise.
4251 (enqueue_one_deferred_signal): Likewise.
4252 (enqueue_pending_signal): Likewise.
4253 (linux_resume_one_lwp_throw): Likewise.
4254 (linux_resume_one_thread): Likewise.
4255 (linux_read_memory): Likewise.
4256 (linux_write_memory): Likewise.
4257 * linux-mips-low.c (mips_linux_new_process): Likewise.
4258 (mips_linux_new_thread): Likewise.
4259 (mips_add_watchpoint): Likewise.
4260 * linux-x86-low.c (initialize_low_arch): Likewise.
4261 * lynx-low.c (lynx_add_process): Likewise.
4262 * mem-break.c (set_raw_breakpoint_at): Likewise.
4263 (set_breakpoint): Likewise.
4264 (add_condition_to_breakpoint): Likewise.
4265 (add_commands_to_breakpoint): Likewise.
4266 (clone_agent_expr): Likewise.
4267 (clone_one_breakpoint): Likewise.
4268 * regcache.c (new_register_cache): Likewise.
4269 * remote-utils.c (look_up_one_symbol): Likewise.
4270 * server.c (queue_stop_reply): Likewise.
4271 (start_inferior): Likewise.
4272 (queue_stop_reply_callback): Likewise.
4273 (handle_target_event): Likewise.
4274 * spu-low.c (fetch_ppc_memory): Likewise.
4275 (store_ppc_memory): Likewise.
4276 * target.c (set_target_ops): Likewise.
4277 * thread-db.c (thread_db_load_search): Likewise.
4278 (try_thread_db_load_1): Likewise.
4279 * tracepoint.c (add_tracepoint): Likewise.
4280 (add_tracepoint_action): Likewise.
4281 (create_trace_state_variable): Likewise.
4282 (cmd_qtdpsrc): Likewise.
4283 (cmd_qtro): Likewise.
4284 (add_while_stepping_state): Likewise.
4285 * win32-low.c (child_add_thread): Likewise.
4286 (get_image_name): Likewise.
4287
4288 2015-08-25 Yao Qi <yao.qi@linaro.org>
4289
4290 * linux-aarch64-low.c (aarch64_linux_new_thread): Remove.
4291
4292 2015-08-25 Yao Qi <yao.qi@linaro.org>
4293
4294 * Makefile.in (aarch64-linux.o): New rule.
4295 * configure.srv (aarch64*-*-linux*): Append aarch64-linux.o to
4296 srv_tgtobj.
4297 * linux-aarch64-low.c: Include nat/aarch64-linux.h.
4298 (aarch64_init_debug_reg_state): Make it extern.
4299 (aarch64_linux_prepare_to_resume): Remove.
4300
4301 2015-08-25 Yao Qi <yao.qi@linaro.org>
4302
4303 * linux-aarch64-low.c (aarch64_linux_prepare_to_resume): Use
4304 lwp_arch_private_info and ptid_of_lwp.
4305
4306 2015-08-25 Yao Qi <yao.qi@linaro.org>
4307
4308 * linux-aarch64-low.c (aarch64_get_debug_reg_state): Add argument pid.
4309 Find proc_info by find_process_pid. All callers updated.
4310
4311 2015-08-25 Yao Qi <yao.qi@linaro.org>
4312
4313 * linux-aarch64-low.c (struct arch64_dr_update_callback_param):
4314 Remove.
4315 (debug_reg_change_callback): Remove.
4316 (aarch64_notify_debug_reg_change): Remove.
4317
4318 2015-08-25 Yao Qi <yao.qi@linaro.org>
4319
4320 * linux-aarch64-low.c (aarch64_notify_debug_reg_change):
4321 Call current_lwp_ptid.
4322
4323 2015-08-25 Yao Qi <yao.qi@linaro.org>
4324
4325 * linux-aarch64-low.c (debug_reg_change_callback): Use
4326 debug_printf.
4327
4328 2015-08-25 Yao Qi <yao.qi@linaro.org>
4329
4330 * linux-aarch64-low.c (debug_reg_change_callback): Use phex.
4331
4332 2015-08-25 Yao Qi <yao.qi@linaro.org>
4333
4334 * linux-aarch64-low.c (debug_reg_change_callback): Remove comments.
4335
4336 2015-08-25 Yao Qi <yao.qi@linaro.org>
4337
4338 * linux-aarch64-low.c (debug_reg_change_callback): Re-indent
4339 the code.
4340
4341 2015-08-25 Yao Qi <yao.qi@linaro.org>
4342
4343 * linux-aarch64-low.c (aarch64_dr_update_callback_param) <pid>:
4344 Remove.
4345 (debug_reg_change_callback): Remove argument entry and add argument
4346 lwp. Remove local variable thread. Don't print thread id in the
4347 debugging output. Don't check whether pid of thread equals to pid.
4348 (aarch64_notify_debug_reg_change): Don't set param.pid. Call
4349 iterate_over_lwps instead find_inferior.
4350
4351 2015-08-24 Pedro Alves <palves@redhat.com>
4352
4353 * inferiors.c (get_first_process): New function.
4354 * inferiors.h (get_first_process): New declaration.
4355 * remote-utils.c (read_ptid): Default to the first process in the
4356 list, instead of to the current thread's process.
4357
4358 2015-08-24 Pedro Alves <palves@redhat.com>
4359
4360 * debug.c: Include gdb_sys_time.h instead of sys/time.h.
4361 * event-loop.c: Likewise.
4362 * remote-utils.c: Likewise.
4363 * tracepoint.c: Likewise.
4364
4365 2015-08-24 Pedro Alves <palves@redhat.com>
4366
4367 * spu-low.c (spu_request_interrupt): Use lwpid_of instead of
4368 ptid_get_lwp.
4369
4370 2015-08-21 Pedro Alves <palves@redhat.com>
4371
4372 * ax.c (gdb_eval_agent_expr): Return expr_eval_unhandled_opcode
4373 instead of literal 1.
4374
4375 2015-08-21 Pedro Alves <palves@redhat.com>
4376
4377 * tdesc.c (default_description): Explicitly zero-initialize.
4378
4379 2015-08-21 Pedro Alves <palves@redhat.com>
4380
4381 PR gdb/18749
4382 * inferiors.c (remove_thread): Discard any pending stop reply for
4383 this thread.
4384 * server.c (remove_all_on_match_pid): Rename to ...
4385 (remove_all_on_match_ptid): ... this. Work with a filter ptid
4386 instead of a pid.
4387 (discard_queued_stop_replies): Change parameter to a ptid. Now
4388 extern.
4389 (handle_v_kill, kill_inferior_callback, captured_main)
4390 (process_serial_event): Adjust.
4391 * server.h (discard_queued_stop_replies): Declare.
4392
4393 2015-08-21 Pedro Alves <palves@redhat.com>
4394
4395 * linux-low.c (wait_for_sigstop): Always switch to no thread
4396 selected if the previously current thread dies.
4397 * lynx-low.c (lynx_request_interrupt): Use the first thread's
4398 process instead of the current thread's.
4399 * remote-utils.c (input_interrupt): Don't check if there's no
4400 current thread.
4401 * server.c (gdb_read_memory, gdb_write_memory): If setting the
4402 current thread to the general thread fails, error out.
4403 (handle_qxfer_auxv, handle_qxfer_libraries)
4404 (handle_qxfer_libraries_svr4, handle_qxfer_siginfo)
4405 (handle_qxfer_spu, handle_qxfer_statictrace, handle_qxfer_fdpic)
4406 (handle_query): Check if there's a thread selected instead of
4407 checking whether there's any thread in the thread list.
4408 (handle_qxfer_threads, handle_qxfer_btrace)
4409 (handle_qxfer_btrace_conf): Don't error out early if there's no
4410 thread in the thread list.
4411 (handle_v_cont, myresume): Don't set the current thread to the
4412 continue thread.
4413 (process_serial_event) <Hg handling>: Also set thread_id if the
4414 previous general thread is still alive.
4415 (process_serial_event) <g/G handling>: If setting the current
4416 thread to the general thread fails, error out.
4417 * spu-low.c (spu_resume, spu_request_interrupt): Use the first
4418 thread's lwp instead of the current thread's.
4419 * target.c (set_desired_thread): If the desired thread was not
4420 found, leave the current thread pointing to NULL. Return an int
4421 (boolean) indicating success.
4422 * target.h (set_desired_thread): Change return type to int.
4423
4424 2015-08-20 Max Filippov <jcmvbkbc@gmail.com>
4425
4426 * configure.srv (xtensa*-*-linux*): Add srv_linux_thread_db=yes.
4427 * linux-xtensa-low.c (arch/xtensa.h gdb_proc_service.h): New
4428 #includes.
4429 (ps_get_thread_area): New function.
4430
4431 2015-08-19 Gary Benson <gbenson@redhat.com>
4432
4433 * hostio.c (handle_pread): Do not attempt to read more data
4434 than hostio_reply_with_data can fit in a packet.
4435
4436 2015-08-18 Joel Brobecker <brobecker@adacore.com>
4437
4438 * linux-aarch32-low.c (NT_ARM_VFP): Define if not already defined.
4439
4440 2015-08-14 Matthew Fortune <matthew.fortune@imgtec.com>
4441
4442 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP_REL.
4443
4444 2015-08-06 Pedro Alves <palves@redhat.com>
4445
4446 * tracepoint.c (expr_eval_result): Now an int.
4447
4448 2015-08-06 Pedro Alves <palves@redhat.com>
4449
4450 * gdbthread.h (struct regcache): Forward declare.
4451 (struct thread_info) <regcache_data>: Now a struct regcache
4452 pointer.
4453 * inferiors.c (inferior_regcache_data)
4454 (set_inferior_regcache_data): Now work with struct regcache
4455 pointers.
4456 * inferiors.h (struct regcache): Forward declare.
4457 (inferior_regcache_data, set_inferior_regcache_data): Now work
4458 with struct regcache pointers.
4459 * regcache.c (get_thread_regcache, regcache_invalidate_thread)
4460 (free_register_cache_thread): Remove struct regcache pointer
4461 casts.
4462
4463 2015-08-06 Pedro Alves <palves@redhat.com>
4464
4465 * server.c (captured_main): On error, print the exception message
4466 to stderr, and if run_once is set, throw a quit.
4467
4468 2015-08-06 Pedro Alves <palves@redhat.com>
4469
4470 * linux-low.c (move_out_of_jump_pad_callback): Temporarily switch
4471 the current thread.
4472
4473 2015-08-06 Pedro Alves <palves@redhat.com>
4474
4475 * linux-low.c (linux_write_memory): Rewrite debug output to avoid
4476 reading beyond the passed in buffer length.
4477
4478 2015-08-06 Pierre Langlois <pierre.langlois@arm.com>
4479
4480 * tracepoint.c (symbol_list) <required>: Remove.
4481
4482 2015-08-06 Pedro Alves <palves@redhat.com>
4483
4484 * linux-low.c (handle_extended_wait): Set the fork child's suspend
4485 count if stopping and suspending threads.
4486 (check_stopped_by_breakpoint): If stopped by trace, set the LWP's
4487 stop reason to TARGET_STOPPED_BY_SINGLE_STEP.
4488 (linux_detach): Complete an ongoing step-over.
4489 (lwp_suspended_inc, lwp_suspended_decr): New functions. Use
4490 throughout.
4491 (resume_stopped_resumed_lwps): Don't resume a suspended thread.
4492 (linux_wait_1): If passing a signal to the inferior after
4493 finishing a step-over, unsuspend and re-resume all lwps. If we
4494 see a single-step event but the thread should be continuing, don't
4495 pass the trap to gdb.
4496 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback): Use
4497 internal_error instead of gdb_assert.
4498 (enqueue_pending_signal): New function.
4499 (check_ptrace_stopped_lwp_gone): Add debug output.
4500 (start_step_over): Use internal_error instead of gdb_assert.
4501 (complete_ongoing_step_over): New function.
4502 (linux_resume_one_thread): Don't resume a suspended thread.
4503 (proceed_one_lwp): If the LWP is stepping over a breakpoint, reset
4504 it stepping.
4505
4506 2015-08-06 Pedro Alves <palves@redhat.com>
4507
4508 * linux-low.c (add_lwp): Set waitstatus to TARGET_WAITKIND_IGNORE.
4509 (linux_thread_alive): Use lwp_is_marked_dead.
4510 (extended_event_reported): Delete.
4511 (linux_wait_1): Check if waitstatus is TARGET_WAITKIND_IGNORE
4512 instead of extended_event_reported.
4513 (mark_lwp_dead): Don't set the 'dead' flag. Store the waitstatus
4514 as well.
4515 (lwp_is_marked_dead): New function.
4516 (lwp_running): Use lwp_is_marked_dead.
4517 * linux-low.h: Delete 'dead' field, and update 'waitstatus's
4518 comment.
4519
4520 2015-08-06 Pedro Alves <palves@redhat.com>
4521
4522 * linux-low.c (linux_wait_1): Move fork event output out of the
4523 !report_to_gdb check. Pass event_child->waitstatus to
4524 target_waitstatus_to_string instead of ourstatus.
4525
4526 2015-08-04 Yao Qi <yao.qi@linaro.org>
4527
4528 * linux-aarch64-low.c (aarch64_supports_tracepoints): Return 0
4529 if current_thread is 32 bit.
4530
4531 2015-08-04 Yao Qi <yao.qi@linaro.org>
4532
4533 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
4534 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
4535 * server.c (extended_protocol): Remove "static".
4536 * server.h (extended_protocol): Declare it.
4537
4538 2015-08-04 Yao Qi <yao.qi@linaro.org>
4539
4540 * linux-aarch64-low.c (aarch64_get_pc): Get PC register on
4541 both aarch64 and aarch32.
4542 (aarch64_set_pc): Likewise.
4543
4544 2015-08-04 Yao Qi <yao.qi@linaro.org>
4545
4546 * configure.srv (case aarch64*-*-linux*): Append arm-with-neon.o
4547 to srv_regobj and append arm-core.xml arm-vfpv3.xml and
4548 arm-with-neon.xml to srv_xmlfiles.
4549 * linux-aarch64-low.c: Include linux-aarch32-low.h.
4550 (is_64bit_tdesc): New function.
4551 (aarch64_linux_read_description): New function.
4552 (aarch64_arch_setup): Call aarch64_linux_read_description.
4553 (regs_info): Rename to regs_info_aarch64.
4554 (aarch64_regs_info): Return right regs_info.
4555 (initialize_low_arch): Call initialize_low_arch_aarch32.
4556
4557 2015-08-04 Yao Qi <yao.qi@linaro.org>
4558
4559 * configure.srv (srv_tgtobj): Add linux-aarch32-low.o.
4560 * linux-aarch32-low.c: New file.
4561 * linux-aarch32-low.h: New file.
4562 * linux-arm-low.c (arm_fill_gregset): Move it to
4563 linux-aarch32-low.c.
4564 (arm_store_gregset): Likewise.
4565 (arm_fill_vfpregset): Call arm_fill_vfpregset_num
4566 (arm_store_vfpregset): Call arm_store_vfpregset_num.
4567 (arm_arch_setup): Check if PTRACE_GETREGSET works.
4568 (regs_info): Rename to regs_info_arm.
4569 (arm_regs_info): Return regs_info_aarch32 if
4570 have_ptrace_getregset is 1 and target description is
4571 arm_with_neon or arm_with_vfpv3.
4572 (initialize_low_arch): Don't call init_registers_arm_with_neon.
4573 Call initialize_low_arch_aarch32 instead.
4574
4575 2015-08-04 Yao Qi <yao.qi@linaro.org>
4576
4577 * linux-x86-low.c (have_ptrace_getregset): Move it to ...
4578 * linux-low.c: ... here.
4579 * linux-low.h (have_ptrace_getregset): Declare it.
4580
4581 2015-08-04 Pedro Alves <palves@redhat.com>
4582
4583 * thread-db.c (struct thread_db): Use new typedefs.
4584 (try_thread_db_load_1): Define local TDB_DLSYM macro and use it in
4585 CHK calls.
4586 (disable_thread_event_reporting): Cast result of dlsym to
4587 destination function pointer type.
4588 (thread_db_mourn): Use td_ta_delete_ftype.
4589
4590 2015-08-03 Sandra Loosemore <sandra@codesourcery.com>
4591
4592 * linux-nios2-low.c (NIOS2_BREAKPOINT): Conditionalize for
4593 arch variant.
4594 (CDX_BREAKPOINT): Define for R2.
4595 (nios2_breakpoint_at): Check for CDX_BREAKPOINT when R2.
4596 (the_low_target): Add comments.
4597
4598 2015-07-30 Yao Qi <yao.qi@linaro.org>
4599
4600 * linux-arm-low.c (arm_hwcap): Remove it.
4601 (arm_read_description): New local variable arm_hwcap. Don't
4602 set arm_hwcap to zero.
4603
4604 2015-07-30 Yao Qi <yao.qi@linaro.org>
4605
4606 * linux-arm-low.c (arm_fill_wmmxregset): Don't use arm_hwcap.
4607 Use regcache->tdesc instead.
4608 (arm_store_wmmxregset): Likewise.
4609 (arm_fill_vfpregset): Likewise.
4610 (arm_store_vfpregset): Likewise.
4611
4612 2015-07-30 Yao Qi <yao.qi@linaro.org>
4613
4614 * linux-arm-low.c: Include arch/arm.h.
4615 (arm_fill_gregset): Don't use arm_num_regs and arm_regmap.
4616 (arm_store_gregset): Likewise.
4617
4618 2015-07-29 Simon Marchi <simon.marchi@ericsson.com>
4619
4620 * linux-mips-low.c (mips_linux_prepare_to_resume): Add NULL as
4621 ptrace's 4th parameter.
4622
4623 2015-07-27 Yao Qi <yao.qi@linaro.org>
4624
4625 * configure.srv (case aarch64*-*-linux*): Don't set
4626 srv_linux_usrregs.
4627
4628 2015-07-24 Pedro Alves <palves@redhat.c: Likewise.om>
4629
4630 * linux-aarch64-low.c: Include nat/gdb_ptrace.h instead of
4631 sys/ptrace.h.
4632 * linux-arm-low.c: Likewise.
4633 * linux-cris-low.c: Likewise.
4634 * linux-crisv32-low.c: Likewise.
4635 * linux-low.c: Likewise.
4636 * linux-m68k-low.c: Likewise.
4637 * linux-mips-low.c: Likewise.
4638 * linux-nios2-low.c: Likewise.
4639 * linux-s390-low.c: Likewise.
4640 * linux-sparc-low.c: Likewise.
4641 * linux-tic6x-low.c: Likewise.
4642 * linux-tile-low.c: Likewise.
4643 * linux-x86-low.c: Likewise.
4644
4645 2015-07-24 Pedro Alves <palves@redhat.com>
4646
4647 * config.in: Regenerate.
4648 * configure: Regenerate.
4649
4650 2015-07-24 Pedro Alves <palves@redhat.com>
4651
4652 * acinclude.m4: Include ../ptrace.m4.
4653 * configure.ac: Call GDB_AC_PTRACE.
4654 * config.in, configure: Regenerate.
4655
4656 2015-07-24 Yao Qi <yao.qi@linaro.org>
4657
4658 * linux-low.c (linux_create_inferior): Remove setting to
4659 proc->priv->new_inferior.
4660 (linux_attach): Likewise.
4661 (linux_low_filter_event): Likewise.
4662 * linux-low.h (struct process_info_private) <new_inferior>: Remove.
4663
4664 2015-07-24 Yao Qi <yao.qi@linaro.org>
4665
4666 * linux-low.c (linux_arch_setup): New function.
4667 (linux_low_filter_event): If proc->tdesc is NULL and
4668 proc->attached is true, call the_low_target.arch_setup.
4669 Otherwise, keep status pending, and return.
4670 (linux_resume_one_lwp_throw): Don't call get_pc if
4671 thread->while_stepping isn't NULL. Don't call
4672 get_thread_regcache if proc->tdesc is NULL.
4673 (need_step_over_p): Return 0 if proc->tdesc is NULL.
4674 (linux_target_ops): Install arch_setup.
4675 * server.c (start_inferior): Call the_target->arch_setup.
4676 * target.h (struct target_ops) <arch_setup>: New field.
4677 (target_arch_setup): New marco.
4678 * lynx-low.c (lynx_target_ops): Update.
4679 * nto-low.c (nto_target_ops): Update.
4680 * spu-low.c (spu_target_ops): Update.
4681 * win32-low.c (win32_target_ops): Update.
4682
4683 2015-07-24 Yao Qi <yao.qi@linaro.org>
4684
4685 * linux-low.c (linux_add_process): Don't set
4686 proc->priv->new_inferior.
4687 (linux_create_inferior): Set proc->priv->new_inferior to 1.
4688 (linux_attach): Likewise.
4689
4690 2015-07-24 Yao Qi <yao.qi@linaro.org>
4691
4692 * server.c (start_inferior): Code refactor.
4693
4694 2015-07-24 Yao Qi <yao.qi@linaro.org>
4695
4696 * server.c (process_serial_event): Set general_thread.
4697
4698 2015-07-21 Yao Qi <yao.qi@linaro.org>
4699
4700 * linux-aarch64-low.c (aarch64_arch_setup): Remove code and call
4701 aarch64_linux_get_debug_reg_capacity.
4702
4703 2015-07-17 Yao Qi <yao.qi@linaro.org>
4704
4705 * Makefile.in (aarch64-linux-hw-point.o): New rule.
4706 * configure.srv (srv_tgtobj): Append aarch64-linux-hw-point.o.
4707 * linux-aarch64-low.c: Include nat/aarch64-linux-hw-point.h.
4708 (AARCH64_HBP_MAX_NUM): Move to nat/aarch64-linux-hw-point.h.
4709 (AARCH64_HWP_MAX_NUM, AARCH64_HBP_ALIGNMENT): Likewise.
4710 (AARCH64_HWP_ALIGNMENT): Likewise.
4711 (AARCH64_HWP_MAX_LEN_PER_REG): Likewise.
4712 (AARCH64_DEBUG_NUM_SLOTS, AARCH64_DEBUG_ARCH): Likewise.
4713 (aarch64_num_bp_regs, aarch64_num_wp_regs): Likewise.
4714 (AARCH64_DEBUG_ARCH_V8, DR_MARK_ALL_CHANGED): Likewise.
4715 (DR_MARK_N_CHANGED, DR_CLEAR_CHANGED): Likewise.
4716 (DR_HAS_CHANGED, DR_N_HAS_CHANGE): Likewise.
4717 (struct aarch64_debug_reg_state): Likewise.
4718 (struct arch_lwp_info): Likewise.
4719 (aarch64_align_watchpoint): Likewise.
4720 (DR_CONTROL_ENABLED, DR_CONTROL_LENGTH): Likewise.
4721 (aarch64_watchpoint_length): Likewise.
4722 (aarch64_point_encode_ctrl_reg): Likewise
4723 (aarch64_point_is_aligned): Likewise.
4724 (aarch64_align_watchpoint): Likewise.
4725 (aarch64_linux_set_debug_regs):
4726 (aarch64_dr_state_insert_one_point): Likewise.
4727 (aarch64_dr_state_remove_one_point): Likewise.
4728 (aarch64_handle_breakpoint): Likewise.
4729 (aarch64_handle_aligned_watchpoint): Likewise.
4730 (aarch64_handle_unaligned_watchpoint): Likewise.
4731 (aarch64_handle_watchpoint): Likewise.
4732
4733 2015-07-17 Yao Qi <yao.qi@linaro.org>
4734
4735 * linux-aarch64-low.c (aarch64_handle_breakpoint): Add argument state
4736 and don't aarch64_get_debug_reg_state. All callers update.
4737 (aarch64_handle_aligned_watchpoint): Likewise.
4738 (aarch64_handle_unaligned_watchpoint): Likewise.
4739 (aarch64_handle_watchpoint): Likewise.
4740 (aarch64_insert_point): Call aarch64_get_debug_reg_state earlier.
4741 (aarch64_remove_point): Likewise.
4742
4743 2015-07-17 Yao Qi <yao.qi@linaro.org>
4744
4745 * linux-aarch64-low.c (aarch64_show_debug_reg_state): Use
4746 debug_printf.
4747 (aarch64_handle_unaligned_watchpoint): Likewise.
4748
4749 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
4750
4751 Revert the previous 3 commits:
4752 Move gdb_regex* to common/
4753 Move linux_find_memory_regions_full & co.
4754 gdbserver build-id attribute generator
4755
4756 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
4757 Jan Kratochvil <jan.kratochvil@redhat.com>
4758
4759 gdbserver build-id attribute generator.
4760 * linux-low.c (nat/linux-maps.h, search.h, rsp-low.h): Include.
4761 (ElfXX_Ehdr, ElfXX_Phdr, ElfXX_Nhdr): New.
4762 (ELFXX_FLD, ELFXX_SIZEOF, ELFXX_ROUNDUP, BUILD_ID_INVALID): New.
4763 (find_phdr): New.
4764 (get_dynamic): Use find_pdhr to traverse program headers.
4765 (struct mapping_entry, mapping_entry_s, free_mapping_entry_vec)
4766 (compare_mapping_entry_range, struct find_memory_region_callback_data)
4767 (read_build_id, find_memory_region_callback, lrfind_mapping_entry)
4768 (get_hex_build_id): New.
4769 (linux_qxfer_libraries_svr4): Add optional build-id attribute
4770 to reply XML document.
4771
4772 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
4773 Jan Kratochvil <jan.kratochvil@redhat.com>
4774
4775 * target.c: Include target/target-utils.h and fcntl.h.
4776 (target_fileio_read_stralloc_1_pread, target_fileio_read_stralloc_1)
4777 (target_fileio_read_stralloc): New functions.
4778
4779 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
4780
4781 * Makefile.in (OBS): Add gdb_regex.o.
4782 (gdb_regex.o): New.
4783 * config.in: Rebuilt.
4784 * configure: Rebuilt.
4785
4786 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
4787 Jan Kratochvil <jan.kratochvil@redhat.com>
4788
4789 Create empty nat/linux-maps.[ch] and common/target-utils.[ch].
4790 * Makefile.in (OBS): Add target-utils.o.
4791 (linux-maps.o, target-utils.o): New.
4792 * configure.srv (srv_linux_obj): Add linux-maps.o.
4793
4794 2015-07-15 Pierre Langlois <pierre.langlois@arm.com>
4795
4796 * linux-aarch64-low.c (aarch64_supports_range_stepping): New
4797 function, return 1.
4798 (the_low_target): Install it.
4799
4800 2015-07-14 Pedro Alves <palves@redhat.com>
4801
4802 * linux-low.c (kill_wait_lwp): Don't assert if waitpid fails.
4803 Instead, ignore ECHILD, and throw an error for other errnos.
4804
4805 2015-07-10 Pedro Alves <palves@redhat.com>
4806
4807 * event-loop.c (struct callback_event) <data>: Change type to
4808 gdb_client_data instance instead of gdb_client_data pointer.
4809 (append_callback_event): Adjust.
4810
4811 2015-07-10 Pierre Langlois <pierre.langlois@arm.com>
4812
4813 * linux-aarch64-low.c: Add comments for each linux_target_ops
4814 method. Remove comments already covered in target_ops and
4815 linux_target_ops definitions.
4816 (the_low_target): Add comments for each unimplemented method.
4817
4818 2015-07-09 Yao Qi <yao.qi@linaro.org>
4819
4820 * linux-aarch64-low.c (aarch64_regmap): Remove.
4821 (aarch64_usrregs_info): Remove.
4822 (regs_info): Set field usrregs to NULL.
4823
4824 2015-07-02 Markus Metzger <markus.t.metzger@intel.com>
4825
4826 * linux-low.c: Include "rsp-low.h"
4827 (linux_low_encode_pt_config, linux_low_encode_raw): New.
4828 (linux_low_read_btrace): Support BTRACE_FORMAT_PT.
4829 (linux_low_btrace_conf): Support BTRACE_FORMAT_PT.
4830 (handle_btrace_enable_pt): New.
4831 (handle_btrace_general_set): Support "pt".
4832 (handle_btrace_conf_general_set): Support "pt:size".
4833
4834 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
4835
4836 * linux-aarch64-low.c (aarch64_supports_z_point_type): Enable for
4837 Z_PACKET_SW_BP.
4838
4839 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
4840
4841 * linux-aarch64-low.c: Remove comment about endianness.
4842 (aarch64_breakpoint): Change type to gdb_byte[]. Set to "brk #0".
4843 (aarch64_breakpoint_at): Change type of insn to gdb_byte[]. Use
4844 memcmp.
4845
4846 2015-06-24 Gary Benson <gbenson@redhat.com>
4847
4848 * linux-i386-ipa.c (stdint.h): Do not include.
4849 * lynx-i386-low.c (stdint.h): Likewise.
4850 * lynx-ppc-low.c (stdint.h): Likewise.
4851 * mem-break.c (stdint.h): Likewise.
4852 * thread-db.c (stdint.h): Likewise.
4853 * tracepoint.c (stdint.h): Likewise.
4854 * win32-low.c (stdint.h): Likewise.
4855
4856 2015-06-18 Simon Marchi <simon.marchi@ericsson.com>
4857
4858 * server.c (write_qxfer_response): Update call to
4859 remote_escape_output.
4860
4861 2015-06-15 Aleksandar Ristovski <aristovski@qnx.com
4862 Jan Kratochvil <jan.kratochvil@redhat.com>
4863
4864 Merge multiple hex conversions.
4865 * gdbreplay.c (tohex): Rename to 'fromhex'.
4866 (logchar): Use fromhex.
4867
4868 2015-06-10 Jan Kratochvil <jan.kratochvil@redhat.com>
4869
4870 * server.c (handle_qxfer_libraries): Set `version' attribute for
4871 <library-list>.
4872
4873 2015-06-10 Gary Benson <gbenson@redhat.com>
4874
4875 * target.h (struct target_ops) <multifs_open>: New field.
4876 <multifs_unlink>: Likewise.
4877 <multifs_readlink>: Likewise.
4878 * linux-low.c (nat/linux-namespaces.h): New include.
4879 (linux_target_ops): Initialize the_target->multifs_open,
4880 the_target->multifs_unlink and the_target->multifs_readlink.
4881 * hostio.h (hostio_handle_new_gdb_connection): New declaration.
4882 * hostio.c (hostio_fs_pid): New static variable.
4883 (hostio_handle_new_gdb_connection): New function.
4884 (handle_setfs): Likewise.
4885 (handle_open): Use the_target->multifs_open as appropriate.
4886 (handle_unlink): Use the_target->multifs_unlink as appropriate.
4887 (handle_readlink): Use the_target->multifs_readlink as
4888 appropriate.
4889 (handle_vFile): Handle vFile:setfs packets.
4890 * server.c (handle_query): Call hostio_handle_new_gdb_connection
4891 after target_handle_new_gdb_connection.
4892
4893 2015-06-10 Gary Benson <gbenson@redhat.com>
4894
4895 * configure.ac (AC_CHECK_FUNCS): Add setns.
4896 * config.in: Regenerate.
4897 * configure: Likewise.
4898 * Makefile.in (SFILES): Add nat/linux-namespaces.c.
4899 (linux-namespaces.o): New rule.
4900 * configure.srv (srv_linux_obj): Add linux-namespaces.o.
4901
4902 2015-06-09 Gary Benson <gbenson@redhat.com>
4903
4904 * hostio.c (handle_open): Process mode argument with
4905 fileio_to_host_mode.
4906
4907 2015-06-01 Yao Qi <yao.qi@linaro.org>
4908
4909 * linux-s390-low.c (PTRACE_GETREGSET, PTRACE_SETREGSET): Remove.
4910 * linux-x86-low.c: Likewise.
4911
4912 2015-05-28 Don Breazeal <donb@codesourcery.com>
4913
4914 * linux-low.c (handle_extended_wait): Initialize
4915 thread_info.last_resume_kind for new fork children.
4916
4917 2015-05-15 Pedro Alves <palves@redhat.com>
4918
4919 * target.h (target_handle_new_gdb_connection): Rewrite using if
4920 wrapped in do/while.
4921
4922 2015-05-14 Joel Brobecker <brobecker@adacore.com>
4923
4924 * configure.ac: Add prfpregset_t BFD_HAVE_SYS_PROCFS_TYPE check.
4925 * configure, config.in: Regenerate.
4926 * gdb_proc_service.h [HAVE_PRFPREGSET_T] (prfpregset_t):
4927 Declare typedef.
4928
4929 2015-05-12 Don Breazeal <donb@codesourcery.com>
4930
4931 * linux-low.c (handle_extended_wait): Handle PTRACE_EVENT_FORK and
4932 PTRACE_EVENT_VFORK_DONE.
4933 (linux_low_ptrace_options, extended_event_reported): Add vfork
4934 events.
4935 * remote-utils.c (prepare_resume_reply): New stop reasons "vfork"
4936 and "vforkdone" for RSP 'T' Stop Reply Packet.
4937 * server.h (report_vfork_events): Declare
4938 global variable.
4939
4940 2015-05-12 Don Breazeal <donb@codesourcery.com>
4941
4942 * linux-aarch64-low.c (aarch64_linux_new_fork): New function.
4943 (the_low_target) <new_fork>: Initialize new member.
4944 * linux-arm-low.c (arm_new_fork): New function.
4945 (the_low_target) <new_fork>: Initialize new member.
4946 * linux-low.c (handle_extended_wait): Call new target function
4947 new_fork.
4948 * linux-low.h (struct linux_target_ops) <new_fork>: New member.
4949 * linux-mips-low.c (mips_add_watchpoint): New function
4950 extracted from mips_insert_point.
4951 (the_low_target) <new_fork>: Initialize new member.
4952 (mips_linux_new_fork): New function.
4953 (mips_insert_point): Call mips_add_watchpoint.
4954 * linux-x86-low.c (x86_linux_new_fork): New function.
4955 (the_low_target) <new_fork>: Initialize new member.
4956
4957 2015-05-12 Don Breazeal <donb@codesourcery.com>
4958
4959 * linux-low.c (handle_extended_wait): Implement return value,
4960 rename argument 'event_child' to 'event_lwp', handle
4961 PTRACE_EVENT_FORK, call internal_error for unrecognized event.
4962 (linux_low_ptrace_options): New function.
4963 (linux_low_filter_event): Call linux_low_ptrace_options,
4964 use different argument fo linux_enable_event_reporting,
4965 use return value from handle_extended_wait.
4966 (extended_event_reported): New function.
4967 (linux_wait_1): Call extended_event_reported and set
4968 status to report fork events.
4969 (linux_write_memory): Add pid to debug message.
4970 (reset_lwp_ptrace_options_callback): New function.
4971 (linux_handle_new_gdb_connection): New function.
4972 (linux_target_ops): Initialize new structure member.
4973 * linux-low.h (struct lwp_info) <waitstatus>: New member.
4974 * lynx-low.c: Initialize new structure member.
4975 * remote-utils.c (prepare_resume_reply): Implement stop reason
4976 "fork" for "T" stop message.
4977 * server.c (handle_query): Call handle_new_gdb_connection.
4978 * server.h (report_fork_events): Declare global flag.
4979 * target.h (struct target_ops) <handle_new_gdb_connection>:
4980 New member.
4981 (target_handle_new_gdb_connection): New macro.
4982 * win32-low.c: Initialize new structure member.
4983
4984 2015-05-12 Don Breazeal <donb@codesourcery.com>
4985
4986 * mem-break.c (APPEND_TO_LIST): Define macro.
4987 (clone_agent_expr): New function.
4988 (clone_one_breakpoint): New function.
4989 (clone_all_breakpoints): New function.
4990 * mem-break.h: Declare new functions.
4991
4992 2015-05-12 Don Breazeal <donb@codesourcery.com>
4993
4994 * linux-low.c (linux_supports_fork_events): New function.
4995 (linux_supports_vfork_events): New function.
4996 (linux_target_ops): Initialize new structure members.
4997 (initialize_low): Call linux_check_ptrace_features.
4998 * lynx-low.c (lynx_target_ops): Initialize new structure
4999 members.
5000 * server.c (report_fork_events, report_vfork_events):
5001 New global flags.
5002 (handle_query): Add new features to qSupported packet and
5003 response.
5004 (captured_main): Initialize new global variables.
5005 * target.h (struct target_ops) <supports_fork_events>:
5006 New member.
5007 <supports_vfork_events>: New member.
5008 (target_supports_fork_events): New macro.
5009 (target_supports_vfork_events): New macro.
5010 * win32-low.c (win32_target_ops): Initialize new structure
5011 members.
5012
5013 2015-05-12 Gary Benson <gbenson@redhat.com>
5014
5015 * server.c (handle_qxfer_exec_file): Use current process
5016 if annex is empty.
5017
5018 2015-05-08 Sandra Loosemore <sandra@codesourcery.com>
5019
5020 * linux-nios2-low.c: Include elf/common.h. Adjust comments.
5021 Remove HAVE_PTRACE_GETREGS conditionals.
5022 (nios2_regsets): Use PTRACE_GETREGSET and PTRACE_SETREGSET
5023 instead of PTRACE_GETREGS and PTRACE_SETREGS.
5024
5025 2015-05-08 Yao Qi <yao.qi@linaro.org>
5026
5027 * linux-low.c (linux_supports_conditional_breakpoints): New
5028 function.
5029 (linux_target_ops): Install new target method.
5030 * lynx-low.c (lynx_target_ops): Install NULL hook for
5031 supports_conditional_breakpoints.
5032 * nto-low.c (nto_target_ops): Likewise.
5033 * spu-low.c (spu_target_ops): Likewise.
5034 * win32-low.c (win32_target_ops): Likewise.
5035 * server.c (handle_query): Check
5036 target_supports_conditional_breakpoints.
5037 * target.h (struct target_ops) <supports_conditional_breakpoints>:
5038 New field.
5039 (target_supports_conditional_breakpoints): New macro.
5040
5041 2015-05-06 Pedro Alves <palves@redhat.com>
5042
5043 PR server/18081
5044 * server.c (start_inferior): If the process exits, mourn it.
5045
5046 2015-04-21 Gary Benson <gbenson@redhat.com>
5047
5048 * hostio.c (fileio_open_flags_to_host): Factored out to
5049 fileio_to_host_openflags in common/fileio.c. Single use
5050 updated.
5051
5052 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
5053
5054 * linux-xtensa-low.c (xtensa_fill_gregset)
5055 (xtensa_store_gregset): Check XCHAL_HAVE_LOOPS instead of
5056 XCHAL_HAVE_LOOP.
5057
5058 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
5059
5060 * linux-xtensa-low.c (xtensa_usrregs_info): Remove.
5061 (regs_info): Replace usrregs pointer with NULL.
5062
5063 2015-04-17 Gary Benson <gbenson@redhat.com>
5064
5065 * target.h (struct target_ops) <pid_to_exec_file>: New field.
5066 * linux-low.c (linux_target_ops): Initialize pid_to_exec_file.
5067 * server.c (handle_qxfer_exec_file): New function.
5068 (qxfer_packets): Add exec-file entry.
5069 (handle_query): Report qXfer:exec-file:read as supported packet.
5070
5071 2015-04-14 Romain Naour <romain.naour@openwide.fr> (tiny change)
5072
5073 * linux-low.c (linux_read_offsets): Remove get_thread_lwp.
5074
5075 2015-04-09 Gary Benson <gbenson@redhat.com>
5076
5077 * hostio-errno.c (errno_to_fileio_error): Remove function.
5078 Update caller to use remote_fileio_to_fio_error.
5079
5080 2015-04-09 Yao Qi <yao.qi@linaro.org>
5081
5082 * linux-low.c (linux_insert_point): Call
5083 insert_memory_breakpoint if TYPE is raw_bkpt_type_sw.
5084 (linux_remove_point): Call remove_memory_breakpoint if type is
5085 raw_bkpt_type_sw.
5086 * linux-x86-low.c (x86_insert_point): Don't call
5087 insert_memory_breakpoint.
5088 (x86_remove_point): Don't call remove_memory_breakpoint.
5089
5090 2015-04-01 Pedro Alves <palves@redhat.com>
5091 Cleber Rosa <crosa@redhat.com>
5092
5093 * server.c (gdbserver_usage): Reorganize and extend the usage
5094 message.
5095
5096 2015-03-24 Pedro Alves <palves@redhat.com>
5097
5098 * linux-low.c (check_stopped_by_breakpoint): Tweak debug log
5099 output. Also dump TRAP_TRACE.
5100 (linux_low_filter_event): In debug output, distinguish a
5101 resume_stop SIGSTOP from a delayed SIGSTOP.
5102
5103 2015-03-24 Gary Benson <gbenson@redhat.com>
5104
5105 * linux-x86-low.c (x86_linux_new_thread): Moved to
5106 nat/x86-linux.c.
5107 (x86_linux_prepare_to_resume): Likewise.
5108
5109 2015-03-24 Gary Benson <gbenson@redhat.com>
5110
5111 * Makefile.in (x86-linux-dregs.o): New rule.
5112 * configure.srv: Add x86-linux-dregs.o to relevant targets.
5113 * linux-x86-low.c: Include nat/x86-linux-dregs.h.
5114 (u_debugreg_offset): Moved to nat/x86-linux-dregs.c.
5115 (x86_linux_dr_get): Likewise.
5116 (x86_linux_dr_set): Likewise.
5117 (update_debug_registers_callback): Likewise.
5118 (x86_linux_dr_set_addr): Likewise.
5119 (x86_linux_dr_get_addr): Likewise.
5120 (x86_linux_dr_set_control): Likewise.
5121 (x86_linux_dr_get_control): Likewise.
5122 (x86_linux_dr_get_status): Likewise.
5123 (x86_linux_update_debug_registers): Likewise.
5124
5125 2015-03-24 Gary Benson <gbenson@redhat.com>
5126
5127 * linux-x86-low.c (x86_linux_update_debug_registers):
5128 New function, factored out from...
5129 (x86_linux_prepare_to_resume): ...this.
5130
5131 2015-03-24 Gary Benson <gbenson@redhat.com>
5132
5133 * linux-x86-low.c (x86_linux_dr_get): Update comments.
5134 (x86_linux_dr_set): Likewise.
5135 (update_debug_registers_callback): Likewise.
5136 (x86_linux_dr_set_addr): Likewise.
5137 (x86_linux_dr_get_addr): Likewise.
5138 (x86_linux_dr_set_control): Likewise.
5139 (x86_linux_dr_get_control): Likewise.
5140 (x86_linux_dr_get_status): Likewise.
5141 (x86_linux_prepare_to_resume): Likewise.
5142
5143 2015-03-24 Gary Benson <gbenson@redhat.com>
5144
5145 * linux-x86-low.c (x86_linux_dr_get): Add assertion.
5146 Use perror_with_name. Pass string through gettext.
5147 (x86_linux_dr_set): Likewise.
5148
5149 2015-03-24 Gary Benson <gbenson@redhat.com>
5150
5151 * linux-x86-low.c (x86_dr_low_set_addr): Rename to...
5152 (x86_linux_dr_set_addr): ...this.
5153 (x86_dr_low_get_addr): Rename to...
5154 (x86_linux_dr_get_addr): ...this.
5155 (x86_dr_low_set_control): Rename to...
5156 (x86_linux_dr_set_control): ...this.
5157 (x86_dr_low_get_control): Rename to...
5158 (x86_linux_dr_get_control): ...this.
5159 (x86_dr_low_get_status): Rename to...
5160 (x86_linux_dr_get_status): ...this.
5161 (x86_dr_low): Update with new function names.
5162
5163 2015-03-24 Gary Benson <gbenson@redhat.com>
5164
5165 * Makefile.in (x86-linux.o): New rule.
5166 * configure.srv: Add x86-linux.o to relevant targets.
5167 * linux-low.c (lwp_set_arch_private_info): New function.
5168 (lwp_arch_private_info): Likewise.
5169 * linux-x86-low.c: Include nat/x86-linux.h.
5170 (arch_lwp_info): Removed structure.
5171 (update_debug_registers_callback):
5172 Use lwp_set_debug_registers_changed.
5173 (x86_linux_prepare_to_resume): Use lwp_debug_registers_changed
5174 and lwp_set_debug_registers_changed.
5175 (x86_linux_new_thread): Use lwp_set_debug_registers_changed.
5176
5177 2015-03-24 Gary Benson <gbenson@redhat.com>
5178
5179 * linux-low.h (linux_target_ops) <new_thread>: Changed signature.
5180 * linux-arm-low.c (arm_new_thread): Likewise.
5181 * linux-aarch64-low.c (aarch64_linux_new_thread): Likewise.
5182 * linux-mips-low.c (mips_linux_new_thread): Likewise.
5183 * linux-x86-low.c (x86_linux_new_thread): Likewise.
5184 * linux-low.c (add_lwp): Update the_low_target.new_thread call.
5185
5186 2015-03-24 Gary Benson <gbenson@redhat.com>
5187
5188 * linux-low.c (ptid_of_lwp): New function.
5189 (lwp_is_stopped): Likewise.
5190 (lwp_stop_reason): Likewise.
5191 * linux-x86-low.c (update_debug_registers_callback):
5192 Use lwp_is_stopped.
5193 (x86_linux_prepare_to_resume): Use ptid_of_lwp and
5194 lwp_stop_reason.
5195
5196 2015-03-24 Gary Benson <gbenson@redhat.com>
5197
5198 * linux-low.h (linux_stop_lwp): Remove declaration.
5199
5200 2015-03-24 Gary Benson <gbenson@redhat.com>
5201
5202 * linux-low.h: Include nat/linux-nat.h.
5203 * linux-low.c (iterate_over_lwps_args): New structure.
5204 (iterate_over_lwps_filter): New function.
5205 (iterate_over_lwps): Likewise.
5206 * linux-x86-low.c (update_debug_registers_callback):
5207 Update signature to what iterate_over_lwps expects.
5208 Remove PID check that iterate_over_lwps now performs.
5209 (x86_dr_low_set_addr): Use iterate_over_lwps.
5210 (x86_dr_low_set_control): Likewise.
5211
5212 2015-03-24 Gary Benson <gbenson@redhat.com>
5213
5214 * linux-x86-low.c (x86_debug_reg_state): New function.
5215 (x86_linux_prepare_to_resume): Use the above.
5216
5217 2015-03-24 Gary Benson <gbenson@redhat.com>
5218
5219 * linux-low.c (current_lwp_ptid): New function.
5220 * linux-x86-low.c: Include nat/linux-nat.h.
5221 (x86_dr_low_get_addr): Use current_lwp_ptid.
5222 (x86_dr_low_get_control): Likewise.
5223 (x86_dr_low_get_status): Likewise.
5224
5225 2015-03-20 Pedro Alves <palves@redhat.com>
5226
5227 * tracepoint.c (cmd_qtstatus): Make "str" const.
5228
5229 2015-03-20 Pedro Alves <palves@redhat.com>
5230
5231 * server.c (handle_general_set): Make "req_str" const.
5232
5233 2015-03-19 Pedro Alves <palves@redhat.com>
5234
5235 * linux-low.c (linux_resume_one_lwp): Rename to ...
5236 (linux_resume_one_lwp_throw): ... this. Don't handle ESRCH here,
5237 instead call perror_with_name.
5238 (check_ptrace_stopped_lwp_gone): New function.
5239 (linux_resume_one_lwp): Reimplement as wrapper around
5240 linux_resume_one_lwp_throw that swallows errors if the LWP is
5241 gone.
5242
5243 2015-03-19 Pedro Alves <palves@redhat.com>
5244
5245 * linux-low.c (count_events_callback, select_event_lwp_callback):
5246 No longer check whether the thread has resume_stop as last resume
5247 kind.
5248
5249 2015-03-19 Pedro Alves <palves@redhat.com>
5250
5251 * linux-low.c (count_events_callback, select_event_lwp_callback):
5252 Use the lwp's status_pending_p field, not the thread's.
5253
5254 2015-03-19 Pedro Alves <palves@redhat.com>
5255
5256 * linux-low.c (select_event_lwp_callback): Update comments to
5257 no longer mention SIGTRAP.
5258
5259 2015-03-18 Gary Benson <gbenson@redhat.com>
5260
5261 * server.c (handle_query): Do not report vFile:fstat as supported.
5262
5263 2015-03-11 Gary Benson <gbenson@redhat.com>
5264
5265 * hostio.c (sys/types.h): New include.
5266 (sys/stat.h): Likewise.
5267 (common-remote-fileio.h): Likewise.
5268 (handle_fstat): New function.
5269 (handle_vFile): Handle vFile:fstat packets.
5270
5271 2015-03-11 Gary Benson <gbenson@redhat.com>
5272
5273 * configure.ac (AC_CHECK_MEMBERS): Add checks for
5274 struct stat.st_blocks and struct stat.st_blksize.
5275 * configure: Regenerate.
5276 * config.in: Likewise.
5277 * Makefile.in (SFILES): Add common/common-remote-fileio.c.
5278 (OBS): Add common-remote-fileio.o.
5279 (common-remote-fileio.o): New rule.
5280
5281 2015-03-09 Pedro Alves <palves@redhat.com>
5282
5283 * tracepoint.c (gdb_agent_helper_thread): Cast '&sockaddr' to
5284 'struct sockaddr' pointer in 'accept' call.
5285
5286 2015-03-09 Pedro Alves <palves@redhat.com>
5287
5288 Revert:
5289 2015-03-07 Pedro Alves <palves@redhat.com>
5290 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
5291 or <winsock2.h> here. Instead include "gdb_socket.h".
5292 (remote_open): Use union gdb_sockaddr_u.
5293 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
5294 or <winsock2.h> here. Instead include "gdb_socket.h".
5295 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
5296 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
5297 or <sys/un.h>.
5298 (init_named_socket, gdb_agent_helper_thread): Use union
5299 gdb_sockaddr_u.
5300
5301 2015-03-07 Pedro Alves <palves@redhat.com>
5302
5303 * configure.ac (build_warnings): Move
5304 -Wdeclaration-after-statement to the C-specific set.
5305 * configure: Regenerate.
5306
5307 2015-03-07 Pedro Alves <palves@redhat.com>
5308
5309 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
5310 or <winsock2.h> here. Instead include "gdb_socket.h".
5311 (remote_open): Use union gdb_sockaddr_u.
5312 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
5313 or <winsock2.h> here. Instead include "gdb_socket.h".
5314 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
5315 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
5316 or <sys/un.h>.
5317 (init_named_socket, gdb_agent_helper_thread): Use union
5318 gdb_sockaddr_u.
5319
5320 2015-03-07 Pedro Alves <palves@redhat.com>
5321
5322 Adjust all callers of TRY_CATCH to use TRY/CATCH/END_CATCH
5323 instead.
5324
5325 2015-03-06 Yao Qi <yao.qi@linaro.org>
5326
5327 * linux-aarch64-low.c (aarch64_insert_point): Use
5328 show_debug_regs as a boolean.
5329 (aarch64_remove_point): Likewise.
5330
5331 2015-03-05 Pedro Alves <palves@redhat.com>
5332
5333 * lynx-low.c (lynx_target_ops): Install NULL hooks for
5334 stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
5335 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint.
5336 * nto-low.c (nto_target_ops): Likewise.
5337 * spu-low.c (spu_target_ops): Likewise.
5338 * win32-low.c (win32_target_ops): Likewise.
5339
5340 2015-03-04 Pedro Alves <palves@redhat.com>
5341
5342 * linux-low.c (check_stopped_by_breakpoint) [USE_SIGTRAP_SIGINFO]:
5343 Decide whether a breakpoint triggered based on the SIGTRAP's
5344 siginfo.si_code.
5345 (thread_still_has_status_pending_p) [USE_SIGTRAP_SIGINFO]: Don't check whether a
5346 breakpoint is inserted if relying on SIGTRAP's siginfo.si_code.
5347 (linux_low_filter_event): Check for breakpoints before checking
5348 watchpoints.
5349 (linux_wait_1): Don't re-increment the PC if relying on SIGTRAP's
5350 siginfo.si_code.
5351 (linux_stopped_by_sw_breakpoint)
5352 (linux_supports_stopped_by_sw_breakpoint)
5353 (linux_stopped_by_hw_breakpoint)
5354 (linux_supports_stopped_by_hw_breakpoint): New functions.
5355 (linux_target_ops): Install new target methods.
5356
5357 2015-03-04 Pedro Alves <palves@redhat.com>
5358
5359 * remote-utils.c (prepare_resume_reply): Report swbreak/hbreak.
5360 * server.c (swbreak_feature, hwbreak_feature): New globals.
5361 (handle_query) <qSupported>: Handle "swbreak+" and "hwbreak+".
5362 (captured_main): Clear swbreak_feature and hwbreak_feature.
5363 * server.h (swbreak_feature, hwbreak_feature): Declare.
5364 * target.h (struct target_ops) <stopped_by_sw_breakpoint,
5365 supports_stopped_by_sw_breakpoint, stopped_by_hw_breakpoint,
5366 supports_stopped_by_hw_breakpoint>: New fields.
5367 (target_supports_stopped_by_sw_breakpoint)
5368 (target_stopped_by_sw_breakpoint)
5369 (target_supports_stopped_by_hw_breakpoint)
5370 (target_stopped_by_hw_breakpoint): Declare.
5371
5372 2015-03-04 Pedro Alves <palves@redhat.com>
5373
5374 enum lwp_stop_reason -> enum target_stop_reason
5375 * linux-low.c (check_stopped_by_breakpoint): Adjust.
5376 (thread_still_has_status_pending_p, check_stopped_by_watchpoint)
5377 (linux_wait_1, stuck_in_jump_pad_callback)
5378 (move_out_of_jump_pad_callback, linux_resume_one_lwp)
5379 (linux_stopped_by_watchpoint):
5380 * linux-low.h (enum lwp_stop_reason): Delete.
5381 (struct lwp_info) <stop_reason>: Now an enum target_stop_reason.
5382 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
5383
5384 2015-03-04 Yao Qi <yao.qi@linaro.org>
5385
5386 * Makefile.in (SFILES): Add linux-aarch64-low.c.
5387
5388 2015-03-03 Gary Benson <gbenson@redhat.com>
5389
5390 * hostio.c (handle_vFile): Fix prefix lengths.
5391
5392 2015-03-03 Markus Metzger <markus.t.metzger@intel.com>
5393
5394 * linux-low.c (linux_low_enable_btrace): Do not overwrite non-zero
5395 ptr_bits.
5396
5397 2015-03-02 Andreas Arnez <arnez@linux.vnet.ibm.com>
5398
5399 * Makefile.in (s390-vx-linux64.c, s390-tevx-linux64.c)
5400 (s390x-vx-linux64.c, s390x-tevx-linux64.c): New rules.
5401 (clean): Add "rm -f" for above C files.
5402 * configure.srv (srv_regobj): Add s390-vx-linux64.o,
5403 s390-tevx-linux64.o, s390x-vx-linux64.o, and s390x-tevx-linux64.o.
5404 (srv_xmlfiles): Add s390-vx-linux64.xml, s390-tevx-linux64.xml,
5405 s390x-vx-linux64.xml, s390x-tevx-linux64.xml, and s390-vx.xml.
5406 * linux-s390-low.c (HWCAP_S390_VX): New macro.
5407 (init_registers_s390_vx_linux64, init_registers_s390_tevx_linux64)
5408 (init_registers_s390x_vx_linux64)
5409 (init_registers_s390x_tevx_linux64)
5410 (tdesc_s390_vx_linux64, tdesc_s390_tevx_linux64)
5411 (tdesc_s390x_vx_linux64, tdesc_s390x_tevx_linux64): New extern
5412 declarations.
5413 (s390_fill_vxrs_low, s390_store_vxrs_low, s390_fill_vxrs_high)
5414 (s390_store_vxrs_high): New functions.
5415 (s390_regsets): Add entries for NT_S390_VXRS_LOW and
5416 NT_S390_VXRS_HIGH.
5417 (s390_arch_setup): Add logic for selecting one of the new target
5418 descriptions. Activate the new vector regsets if applicable.
5419 (initialize_low_arch): Also invoke init_registers_s390_vx_linux64,
5420 init_registers_s390_tevx_linux64, init_registers_s390x_vx_linux64,
5421 and init_registers_s390x_tevx_linux64.
5422
5423 2015-03-01 Pedro Alves <palves@redhat.com>
5424
5425 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Constify 'raw_regs'
5426 parameter.
5427
5428 2015-02-27 Pedro Alves <palves@redhat.com>
5429
5430 * linux-x86-low.c (u_debugreg_offset): New function.
5431 (x86_linux_dr_get, x86_linux_dr_set): Use it.
5432
5433 2015-02-27 Pedro Alves <palves@redhat.com>
5434
5435 * gdb_proc_service.h: Wrap with EXTERN_C_PUSH/EXTERN_C_POP.
5436 [!HAVE_PROC_SERVICE_H] (struct ps_prochandle): Forward declare.
5437 [!HAVE_PROC_SERVICE_H] (ps_pdread, ps_pdwrite, ps_ptread)
5438 ps_ptwrite, ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
5439 (ps_lsetfpregs, ps_getpid)
5440 (ps_get_thread_area, ps_pglobal_lookup, ps_pstop, ps_pcontinue)
5441 (ps_lstop, ps_lcontinue, ps_lgetxregsize, ps_lgetxregs)
5442 (ps_lsetxregs, ps_plog): Declare.
5443
5444 2015-02-27 Pedro Alves <palves@redhat.com>
5445
5446 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Use
5447 IP_AGENT_EXPORT_FUNC.
5448 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Use
5449 IP_AGENT_EXPORT_FUNC.
5450 * tracepoint.c (ATTR_USED, ATTR_NOINLINE, ATTR_CONSTRUCTOR)
5451 (IP_AGENT_EXPORT): Delete.
5452 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
5453 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
5454 (gdb_trampoline_buffer_error, collecting, gdb_collect)
5455 (stop_tracing, flush_trace_buffer, about_to_request_buffer_space)
5456 (trace_buffer_is_full, stopping_tracepoint, expr_eval_result)
5457 (error_tracepoint, tracepoints, tracing, trace_buffer_ctrl)
5458 (trace_buffer_ctrl_curr, trace_buffer_lo, trace_buffer_hi)
5459 (traceframe_read_count, traceframe_write_count)
5460 (traceframes_created, trace_state_variables, get_raw_reg)
5461 (get_trace_state_variable_value, set_trace_state_variable_value)
5462 (ust_loaded, helper_thread_id, cmd_buf): Use
5463 IPA_SYM_EXPORTED_NAME.
5464 (stop_tracing, flush_trace_buffer): Use IP_AGENT_EXPORT_FUNC.
5465 (tracepoints) Use IP_AGENT_EXPORT_VAR.
5466 (stopping_tracepoint, trace_buffer_is_full, expr_eval_result): Use
5467 IP_AGENT_EXPORT_VAR and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
5468 (last_tracepoint): Move into !IN_PROCESS_AGENT block.
5469 (error_tracepoint): Use IP_AGENT_EXPORT_VAR and wrap in
5470 EXTERN_C_PUSH/EXTERN_C_POP.
5471 (trace_state_variables): Use IP_AGENT_EXPORT_VAR.
5472 (trace_buffer_lo, trace_buffer_hi): Use IP_AGENT_EXPORT_VAR and
5473 wrap in EXTERN_C_PUSH/EXTERN_C_POP.
5474 (trace_buffer_ctrl, trace_buffer_ctrl_curr)
5475 (traceframe_write_count, traceframe_read_count)
5476 (traceframes_created, tracing): Use IP_AGENT_EXPORT_VAR.
5477 (about_to_request_buffer_space, get_trace_state_variable_value)
5478 (set_trace_state_variable_value): Use IP_AGENT_EXPORT_FUNC.
5479 (collecting): Use IP_AGENT_EXPORT_VAR and wrap in
5480 EXTERN_C_PUSH/EXTERN_C_POP.
5481 (gdb_collect): Use IP_AGENT_EXPORT_FUNC.
5482 (ust_loaded, cmd_buf): Use IP_AGENT_EXPORT_VAR.
5483 (helper_thread_id, gdb_agent_capability): Use IP_AGENT_EXPORT_VAR
5484 and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
5485 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
5486 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
5487 (gdb_trampoline_buffer_error): Use IP_AGENT_EXPORT_VAR.
5488 * tracepoint.h (ATTR_USED, ATTR_NOINLINE, EXPORTED_SYMBOL):
5489 Define.
5490 (IP_AGENT_EXPORT_FUNC, IP_AGENT_EXPORT_VAR)
5491 (IP_AGENT_EXPORT_VAR_DECL): Define.
5492 (tracing): Declare.
5493 (gdb_agent_get_raw_reg): Declare.
5494
5495 2015-02-27 Tom Tromey <tromey@redhat.com>
5496 Pedro Alves <palves@redhat.com>
5497
5498 Rename symbols whose names are reserved C++ keywords throughout.
5499
5500 2015-02-27 Pedro Alves <palves@redhat.com>
5501
5502 * Makefile.in (COMPILER): New, get it from autoconf.
5503 (CXX): Get from autoconf instead.
5504 (COMPILE.pre): Use COMPILER.
5505 (CC-LD): Rename to ...
5506 (CC_LD): ... this. Use COMPILER.
5507 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT), $(IPA_LIB)): Adjust.
5508 (CXX_FOR_TARGET): Default to g++ instead of gcc.
5509 * acinclude.m4: Include build-with-cxx.m4.
5510 * configure.ac: Call AC_PROG_CXX and GDB_AC_BUILD_WITH_CXX.
5511 Disable -Werror by default if building in C++ mode.
5512 (build_warnings): Add -Wno-sign-compare, -Wno-write-strings and
5513 -Wno-narrowing in C++ mode. Run supported-warning-flags tests with
5514 the C++ compiler. Save/restore CXXFLAGS too.
5515 * configure: Regenerate.
5516
5517 2015-02-27 Pedro Alves <palves@redhat.com>
5518
5519 * acinclude.m4: Include libiberty.m4.
5520 * configure.ac: Call libiberty_INIT.
5521 * config.in, configure: Regenerate.
5522
5523 2015-02-26 Pedro Alves <palves@redhat.com>
5524
5525 * linux-low.c (linux_wait_1): When incrementing the PC past a
5526 program breakpoint always use the_low_target.breakpoint_len as
5527 increment, rather than the maximum between that and
5528 the_low_target.decr_pc_after_break.
5529
5530 2015-02-23 Pedro Alves <palves@redhat.com>
5531
5532 * linux-low.c (check_stopped_by_breakpoint): Don't check if the
5533 thread was doing a step-over; always adjust the PC if
5534 we stepped over a permanent breakpoint.
5535 (linux_wait_1): If we stepped over breakpoint that was on top of a
5536 permanent breakpoint, manually advance the PC past it.
5537
5538 2015-02-23 Pedro Alves <palves@redhat.com>
5539
5540 * linux-x86-low.c (REGSIZE): Define in both 32-bit and 64-bit
5541 modes.
5542 (x86_fill_gregset, x86_store_gregset): Use it when handling
5543 $orig_eax.
5544
5545 2015-02-20 Pedro Alves <palves@redhat.com>
5546
5547 * thread-db.c: Include "nat/linux-procfs.h".
5548 (thread_db_init): Skip listing new threads if the kernel supports
5549 PTRACE_EVENT_CLONE and /proc/PID/task/ is accessible.
5550
5551 2015-02-20 Pedro Alves <palves@redhat.com>
5552
5553 * linux-low.c (status_pending_p_callback): Use ptid_match.
5554
5555 2015-02-19 Antoine Tremblay <antoine.tremblay@ericsson.com>
5556
5557 PR breakpoints/16812
5558 * linux-low.c (wstatus_maybe_breakpoint): Remove.
5559 (linux_low_filter_event): Update wstatus_maybe_breakpoint name.
5560 (linux_wait_1): Report SIGTRAP,SIGILL,SIGSEGV.
5561
5562 2015-02-10 Antoine Tremblay <antoine.tremblay@ericsson.com>
5563
5564 PR breakpoints/15956
5565 * tracepoint.c (cmd_qtinit): Add check for current_thread.
5566
5567 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
5568
5569 * linux-low.c (linux_low_btrace_conf): Print size.
5570 * server.c (handle_btrace_conf_general_set): New.
5571 (hanle_general_set): Call handle_btrace_conf_general_set.
5572 (handle_query): Report Qbtrace-conf:bts:size as supported.
5573
5574 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
5575
5576 * linux-low.c (linux_low_enable_btrace): Update parameters.
5577 (linux_low_btrace_conf): New.
5578 (linux_target_ops)<to_btrace_conf>: Initialize.
5579 * server.c (current_btrace_conf): New.
5580 (handle_btrace_enable): Rename to ...
5581 (handle_btrace_enable_bts): ... this. Pass &current_btrace_conf
5582 to target_enable_btrace. Update comment. Update users.
5583 (handle_qxfer_btrace_conf): New.
5584 (qxfer_packets): Add btrace-conf entry.
5585 (handle_query): Report qXfer:btrace-conf:read as supported packet.
5586 * target.h (target_ops)<enable_btrace>: Update parameters and comment.
5587 (target_ops)<read_btrace_conf>: New.
5588 (target_enable_btrace): Update parameters.
5589 (target_read_btrace_conf): New.
5590
5591 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
5592
5593 * server.c (handle_btrace_general_set): Remove call to
5594 target_supports_btrace.
5595 (supported_btrace_packets): New.
5596 (handle_query): Call supported_btrace_packets.
5597 * target.h: include btrace-common.h.
5598 (btrace_target_info): Removed.
5599 (supports_btrace, target_supports_btrace): Update parameters.
5600
5601 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
5602
5603 * Makefile.in (SFILES): Add common/btrace-common.c.
5604 (OBS): Add common/btrace-common.o.
5605 (btrace-common.o): Add build rules.
5606 * linux-low: Include btrace-common.h.
5607 (linux_low_read_btrace): Use struct btrace_data. Call
5608 btrace_data_init and btrace_data_fini.
5609
5610 2015-02-06 Pedro Alves <palves@redhat.com>
5611
5612 * thread-db.c (find_new_threads_callback): Add debug output.
5613
5614 2015-02-04 Pedro Alves <palves@redhat.com>
5615
5616 * linux-low.c (handle_extended_wait): Don't resume LWPs here.
5617 (resume_stopped_resumed_lwps): New function.
5618 (linux_wait_for_event_filtered): Use it.
5619
5620 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
5621
5622 * Makefile.in (SFILES): Add linux-personality.c.
5623 (linux-personality.o): New rule.
5624 * configure.srv (srv_linux_obj): Add linux-personality.o to the
5625 list of objects to be built.
5626 * linux-low.c: Include nat/linux-personality.h.
5627 (linux_create_inferior): Remove code to disable address space
5628 randomization (moved to ../nat/linux-personality.c). Create
5629 cleanup to disable address space randomization.
5630
5631 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
5632
5633 * Makefile.in (posix-strerror.o): New rule.
5634 (mingw-strerror.o): Likewise.
5635 * configure: Regenerated.
5636 * configure.ac: Source file ../common/common.host. Initialize new
5637 variable srv_host_obs. Add srv_host_obs to GDBSERVER_DEPFILES.
5638
5639 2015-01-14 Yao Qi <yao@codesourcery.com>
5640
5641 * Makefile.in (SFILES): Add nat/ppc-linux.c.
5642 (ppc-linux.o): New rule.
5643 * configure.srv (powerpc*-*-linux*): Add ppc-linux.o.
5644 * configure.ac: AC_CHECK_FUNCS(getauxval).
5645 * config.in: Re-generated.
5646 * configure: Re-generated.
5647 * linux-ppc-low.c (ppc_arch_setup) [__powerpc64__]: Call
5648 ppc64_64bit_inferior_p
5649
5650 2015-01-14 Yao Qi <yao@codesourcery.com>
5651
5652 * linux-ppc-low.c: Include "nat/ppc-linux.h".
5653 (PPC_FEATURE_HAS_VSX): Move to nat/ppc-linux.h.
5654 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Likewise.
5655 (PT_ORIG_R3, PT_TRAP): Likewise.
5656 (PTRACE_GETVSXREGS, PTRACE_SETVSXREGS): Likewise.
5657 (PTRACE_GETVRREGS, PTRACE_SETVRREGS): Likewise.
5658 (PTRACE_GETEVRREGS, PTRACE_SETEVRREGS): Likewise.
5659
5660 2015-01-10 Joel Brobecker <brobecker@adacore.com>
5661
5662 * i387-fp.c (i387_cache_to_xsave): In look over
5663 num_avx512_zmmh_high_registers, replace use of struct i387_xsave
5664 zmmh_low_space field by use of zmmh_high_space.
5665
5666 2015-01-09 Pedro Alves <palves@redhat.com>
5667
5668 * linux-low.c (step_over_bkpt): Move higher up in the file.
5669 (handle_extended_wait): Don't store the stop_pc here.
5670 (get_stop_pc): Adjust comments and rename to ...
5671 (check_stopped_by_breakpoint): ... this. Record whether the LWP
5672 stopped for a software breakpoint or hardware breakpoint.
5673 (thread_still_has_status_pending_p): New function.
5674 (status_pending_p_callback): Use
5675 thread_still_has_status_pending_p. If the event is no longer
5676 interesting, resume the LWP.
5677 (handle_tracepoints): Add assert.
5678 (maybe_move_out_of_jump_pad): Remove cancel_breakpoints call.
5679 (wstatus_maybe_breakpoint): New function.
5680 (cancel_breakpoint): Delete function.
5681 (check_stopped_by_watchpoint): New function, factored out from
5682 linux_low_filter_event.
5683 (lp_status_maybe_breakpoint): Delete function.
5684 (linux_low_filter_event): Remove filter_ptid argument.
5685 Leave thread group exits pending here. Store the LWP's stop PC.
5686 Always leave events pending.
5687 (linux_wait_for_event_filtered): Pull all events out of the
5688 kernel, and leave them all pending.
5689 (count_events_callback, select_event_lwp_callback): Consider all
5690 events.
5691 (cancel_breakpoints_callback, linux_cancel_breakpoints): Delete.
5692 (select_event_lwp): Only give preference to the stepping LWP in
5693 all-stop mode. Adjust comments.
5694 (ignore_event): New function.
5695 (linux_wait_1): Delete 'retry' label. Use ignore_event. Remove
5696 references to cancel_breakpoints. Adjust to renames. Also give
5697 equal priority to all LWPs that have had events in non-stop mode.
5698 If reporting a software breakpoint event, unadjust the LWP's PC.
5699 (linux_wait): If linux_wait_1 returned an ignored event, retry.
5700 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback):
5701 Adjust.
5702 (linux_resume_one_lwp): Store the LWP's PC. Adjust.
5703 (resume_status_pending_p): Use thread_still_has_status_pending_p.
5704 (linux_stopped_by_watchpoint): Adjust.
5705 (linux_target_ops): Remove reference to linux_cancel_breakpoints.
5706 * linux-low.h (enum lwp_stop_reason): New.
5707 (struct lwp_info) <stop_pc>: Adjust comment.
5708 <stopped_by_watchpoint>: Delete field.
5709 <stop_reason>: New field.
5710 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
5711 * mem-break.c (software_breakpoint_inserted_here)
5712 (hardware_breakpoint_inserted_here): New function.
5713 * mem-break.h (software_breakpoint_inserted_here)
5714 (hardware_breakpoint_inserted_here): Declare.
5715 * target.h (struct target_ops) <cancel_breakpoints>: Remove field.
5716 (cancel_breakpoints): Delete.
5717 * tracepoint.c (clear_installed_tracepoints, stop_tracing)
5718 (upload_fast_traceframes): Remove references to
5719 cancel_breakpoints.
5720
5721 2015-01-09 Pedro Alves <palves@redhat.com>
5722
5723 * thread-db.c (find_new_threads_callback): Ignore thread if the
5724 kernel thread ID is -1.
5725
5726 2015-01-09 Pedro Alves <palves@redhat.com>
5727
5728 * linux-low.c (linux_attach_fail_reason_string): Move to
5729 nat/linux-ptrace.c, and rename.
5730 (linux_attach_lwp): Update comment.
5731 (attach_proc_task_lwp_callback): New function.
5732 (linux_attach): Adjust to rename and use
5733 linux_proc_attach_tgid_threads.
5734 (linux_attach_fail_reason_string): Delete declaration.
5735
5736 2015-01-01 Joel Brobecker <brobecker@adacore.com>
5737
5738 * gdbreplay.c (gdbreplay_version): Update copyright year to 2015.
5739 * server.c (gdbserver_version): Likewise.
5740
5741 2014-12-29 Sergio Durigan Junior <sergiodj@redhat.com>
5742
5743 * remote-utils.c: Include ctype.h.
5744 (input_interrupt): Explicitly handle the case when the char
5745 received is the NUL byte. Improve the printing of non-ASCII
5746 characters.
5747
5748 2014-12-16 Joel Brobecker <brobecker@adacore.com>
5749
5750 * linux-low.c (linux_low_filter_event): Update call to
5751 linux_enable_event_reporting following the addition of
5752 a new parameter to that function.
5753
5754 2014-12-16 Catalin Udma <catalin.udma@freescale.com>
5755
5756 PR server/17457
5757 * linux-aarch64-low.c (AARCH64_FPSR_REGNO): New define.
5758 (AARCH64_FPCR_REGNO): Likewise.
5759 (AARCH64_NUM_REGS): Update to include fpsr/fpcr registers.
5760 (aarch64_fill_fpregset): Add missing fpsr/fpcr registers.
5761 (aarch64_store_fpregset): Likewise.
5762
5763 2014-12-15 Joel Brobecker <brobecker@adacore.com>
5764
5765 * lynx-low.c (lynx_resume): Use PTRACE_SINGLESTEP_ONE if N == 1.
5766 Remove FIXME comment about assumption about N.
5767
5768 2014-12-13 Joel Brobecker <brobecker@adacore.com>
5769
5770 * configure.ac: If large-file support is disabled in GDBserver,
5771 pass --disable-largefile to ACX_CONFIGURE_DIR call for "gnulib".
5772 * configure: Regenerate.
5773
5774 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
5775
5776 * linux-low.c (regsets_fetch_inferior_registers): Suppress the
5777 warning upon ENODATA from ptrace.
5778 * linux-s390-low.c (s390_store_tdb): New.
5779 (s390_regsets): Add regset for NT_S390_TDB.
5780
5781 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
5782
5783 * linux-low.c (regsets_store_inferior_registers): Skip regsets
5784 without a fill_function.
5785 * linux-s390-low.c (s390_fill_last_break): Remove.
5786 (s390_regsets): Set fill_function to NULL for NT_S390_LAST_BREAK.
5787 (s390_arch_setup): Use regset's size instead of fill_function for
5788 loop end condition.
5789
5790 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
5791
5792 * linux-low.c (regsets_fetch_inferior_registers): Do not invoke
5793 the regset's store function when ptrace returned an error.
5794 * regcache.c (get_thread_regcache): Invalidate register cache
5795 before fetching inferior's registers.
5796
5797 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
5798
5799 * linux-low.c (regsets_fetch_inferior_registers): Rephrase
5800 while-loop as for-loop.
5801 (regsets_store_inferior_registers): Likewise.
5802
5803 2014-11-28 Yao Qi <yao@codesourcery.com>
5804
5805 * configure.ac(AC_CHECK_FUNCS): Remove readlink.
5806 * config.in, configure: Re-generate.
5807 * hostio.c (handle_unlink): Remove code checking HAVE_READLINK
5808 is defined.
5809
5810 2014-11-21 Yao Qi <yao@codesourcery.com>
5811
5812 * configure.ac: Don't invoke AC_FUNC_ALLOCA.
5813 (AC_CHECK_HEADERS): Remove malloc.h.
5814 * configure: Re-generated.
5815 * config.in: Re-generated.
5816 * server.h: Don't include alloca.h and malloc.h.
5817 * gdbreplay.c: Don't check HAVE_ALLOCA_H is defined.
5818 Don't include malloc.h.
5819
5820 2014-11-17 Joel Brobecker <brobecker@adacore.com>
5821
5822 * lynx-low.c (lynx_write_memory): Put lynx_read_memory and
5823 corresponding ERRNO check in same block.
5824
5825 2014-11-12 Pedro Alves <palves@redhat.com>
5826
5827 * server.c (cont_thread): Update comment.
5828 (start_inferior, attach_inferior): No longer clear cont_thread.
5829 (handle_v_cont): No longer set cont_thread.
5830 (captured_main): Clear cont_thread each time a GDB connects.
5831
5832 2014-11-12 Pedro Alves <palves@redhat.com>
5833
5834 * linux-low.c (linux_wait_1): Don't force a wait for the Hc
5835 thread, and don't resume all threads if the Hc thread has exited.
5836
5837 2014-11-12 Pedro Alves <palves@redhat.com>
5838
5839 * linux-low.c (linux_request_interrupt): Always send a SIGINT to
5840 the process group instead of to a specific LWP.
5841
5842 2014-10-15 Pedro Alves <palves@redhat.com>
5843
5844 PR server/17487
5845 * win32-arm-low.c (arm_set_thread_context): Remove current_event
5846 parameter.
5847 (arm_set_thread_context): Delete.
5848 (the_low_target): Adjust.
5849 * win32-i386-low.c (debug_registers_changed)
5850 (debug_registers_used): Delete.
5851 (update_debug_registers_callback): New function.
5852 (x86_dr_low_set_addr, x86_dr_low_set_control): Mark all threads as
5853 needing to update their debug registers.
5854 (win32_get_current_dr): New function.
5855 (x86_dr_low_get_addr, x86_dr_low_get_control)
5856 (x86_dr_low_get_status): Fetch the debug register from the thread
5857 record's context.
5858 (i386_initial_stuff): Adjust.
5859 (i386_get_thread_context): Remove current_event parameter. Don't
5860 clear debug_registers_changed nor copy DR values to
5861 debug_reg_state.
5862 (i386_set_thread_context): Delete.
5863 (i386_prepare_to_resume): New function.
5864 (i386_thread_added): Mark the thread as needing to update irs
5865 debug registers.
5866 (the_low_target): Remove i386_set_thread_context and install
5867 i386_prepare_to_resume.
5868 * win32-low.c (win32_get_thread_context): Adjust.
5869 (win32_set_thread_context): Use SetThreadContext
5870 directly.
5871 (win32_prepare_to_resume): New function.
5872 (win32_require_context): New function, factored out from ...
5873 (thread_rec): ... this.
5874 (continue_one_thread): Call win32_prepare_to_resume on each thread
5875 we're about to continue.
5876 (win32_resume): Call win32_prepare_to_resume on the event thread.
5877 * win32-low.h (struct win32_thread_info)
5878 <debug_registers_changed>: New field.
5879 (struct win32_target_ops): Change prototype of set_thread_context,
5880 delete set_thread_context and add prepare_to_resume.
5881 (win32_require_context): New declaration.
5882
5883 2014-10-08 Gary Benson <gbenson@redhat.com>
5884
5885 * server.h: Do not include common-exceptions.h.
5886
5887 2014-10-08 Gary Benson <gbenson@redhat.com>
5888
5889 * server.h: Do not include cleanups.h.
5890
5891 2014-09-30 James Hogan <james.hogan@imgtec.com>
5892
5893 * Makefile.in (clean): Add rm -f commands for mips-dsp-linux.c and
5894 mips64-dsp-linux.c.
5895
5896 2014-09-23 Yao Qi <yao@codesourcery.com>
5897
5898 * linux-low.c (lp_status_maybe_breakpoint): New function.
5899 (linux_low_filter_event): Call lp_status_maybe_breakpoint.
5900 (count_events_callback): Likewise.
5901 (select_event_lwp_callback): Likewise.
5902 (cancel_breakpoints_callback): Likewise.
5903
5904 2014-09-19 Don Breazeal <donb@codesourcery.com>
5905
5906 * linux-low.c (handle_extended_wait): Call
5907 linux_ptrace_get_extended_event.
5908 (get_stop_pc, get_detach_signal, linux_low_filter_event): Call
5909 linux_is_extended_waitstatus.
5910
5911 2014-09-16 Joel Brobecker <brobecker@adacore.com>
5912
5913 * Makefile.in (CPPFLAGS): Define.
5914 (INTERNAL_CFLAGS_BASE): Add ${CPPFLAGS}.
5915 (IPAGENT_CFLAGS): Remove ${CPPFLAGS}.
5916
5917 2014-09-16 Gary Benson <gbenson@redhat.com>
5918
5919 * inferiors.h (current_inferior): Renamed as...
5920 (current_thread): New variable. All uses updated.
5921 * linux-low.c (get_pc): Renamed saved_inferior as saved_thread.
5922 (maybe_move_out_of_jump_pad): Likewise.
5923 (cancel_breakpoint): Likewise.
5924 (linux_low_filter_event): Likewise.
5925 (wait_for_sigstop): Likewise.
5926 (linux_resume_one_lwp): Likewise.
5927 (need_step_over_p): Likewise.
5928 (start_step_over): Likewise.
5929 (linux_stabilize_threads): Renamed save_inferior as saved_thread.
5930 * linux-x86-low.c (x86_linux_update_xmltarget): Likewise.
5931 * proc-service.c (ps_lgetregs): Renamed reg_inferior as reg_thread
5932 and save_inferior as saved_thread.
5933 * regcache.c (get_thread_regcache): Renamed saved_inferior as
5934 saved_thread.
5935 (regcache_invalidate_thread): Likewise.
5936 * remote-utils.c (prepare_resume_reply): Likewise.
5937 * thread-db.c (thread_db_get_tls_address): Likewise.
5938 (disable_thread_event_reporting): Likewise.
5939 (remove_thread_event_breakpoints): Likewise.
5940 * tracepoint.c (gdb_agent_about_to_close): Renamed save_inferior
5941 as saved_thread.
5942 * target.h (set_desired_inferior): Renamed as...
5943 (set_desired_thread): New declaration. All uses updated.
5944 * server.c (myresume): Updated comment to reference thread instead
5945 of inferior.
5946 (handle_serial_event): Likewise.
5947 (handle_target_event): Likewise.
5948
5949 2014-09-12 Tom Tromey <tromey@redhat.com>
5950 Gary Benson <gbenson@redhat.com>
5951
5952 * regcache.h: Include common-regcache.h.
5953 (regcache_read_pc): Don't declare.
5954 * regcache.c (get_thread_regcache_for_ptid): New function.
5955
5956 2014-09-11 Tom Tromey <tromey@redhat.com>
5957 Gary Benson <gbenson@redhat.com>
5958
5959 * symbol.c: New file.
5960 * Makefile.in (SFILES): Add symbol.c.
5961 (OBS): Add symbol.o.
5962
5963 2014-09-11 Gary Benson <gbenson@redhat.com>
5964
5965 * target.c (target_stop_ptid, target_continue_ptid): New
5966 functions.
5967
5968 2014-09-11 Tom Tromey <tromey@redhat.com>
5969 Gary Benson <gbenson@redhat.com>
5970
5971 * target.h: Include target/target.h.
5972 * target.c (target_read_memory, target_read_uint32)
5973 (target_write_memory): New functions.
5974
5975 2014-09-11 Gary Benson <gbenson@redhat.com>
5976
5977 * server.h (debug_hw_points): Don't declare.
5978 * server.c (debug_hw_points): Don't define. Replace all uses
5979 with show_debug_regs.
5980 * linux-aarch64-low.c (debug_hw_points): Don't define. Replace
5981 all uses with show_debug_regs.
5982
5983 2014-09-08 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
5984
5985 * linux-ppc-low.c (ppc_collect_ptrace_register): Adjust routine to take
5986 endianness into account.
5987 (ppc_supply_ptrace_register): Likewise.
5988
5989 2014-09-03 James Hogan <james.hogan@imgtec.com>
5990
5991 * linux-mips-low.c (mips_read_description): Reset errno to 0 prior
5992 to reading DSP_CONTROL with PTRACE_PEEKUSER ptrace call.
5993
5994 2014-09-03 Gary Benson <gbenson@redhat.com>
5995
5996 * linux-x86-low.c (x86_linux_prepare_to_resume): Use
5997 ALL_DEBUG_ADDRESS_REGISTERS.
5998
5999 2014-09-02 Gary Benson <gbenson@redhat.com>
6000
6001 * i386-low.h: Renamed as...
6002 * x86-low.h: New file. All type, function and variable name
6003 prefixes changed from "i386_" to "x86_". All references updated.
6004 * i386-low.c: Renamed as...
6005 * x86-low.c: New file. All type, function and variable name
6006 prefixes changed from "i386_" to "x86_". All references updated.
6007
6008 2014-09-02 Gary Benson <gbenson@redhat.com>
6009
6010 * linux-x86-low.c (x86_linux_new_process): Use XCNEW.
6011 (x86_linux_new_thread): Likewise.
6012
6013 2014-08-29 Gary Benson <gbenson@redhat.com>
6014
6015 * server.h (setjmp.h): Do not include.
6016 (toplevel): Do not declare.
6017 (common-exceptions.h): Include.
6018 (cleanups.h): Likewise.
6019 * server.c (toplevel): Do not define.
6020 (exit_code): New static global.
6021 (detach_or_kill_for_exit_cleanup): New function.
6022 (main): New function. Original main renamed to...
6023 (captured_main): New function.
6024 * utils.c (verror) [!IN_PROCESS_AGENT]: Use throw_verror.
6025
6026 2014-08-29 Gary Benson <gbenson@redhat.com>
6027
6028 * Makefile.in (SFILES): Add common/common-exceptions.c.
6029 (OBS): Add common-exceptions.o.
6030 (common-exceptions.o): New rule.
6031 * utils.c (prepare_to_throw_exception): New function.
6032
6033 2014-08-29 Gary Benson <gbenson@redhat.com>
6034
6035 * config.in: Regenerate.
6036 * configure: Likewise.
6037
6038 2014-08-29 Gary Benson <gbenson@redhat.com>
6039
6040 * Makefile.in (SFILES): Add common/cleanups.c.
6041 (OBS): cleanups.o.
6042 (cleanups.o): New rule.
6043
6044 2014-08-29 Gary Benson <gbenson@redhat.com>
6045
6046 * utils.c (internal_vwarning): New function.
6047
6048 2014-08-28 Gary Benson <gbenson@redhat.com>
6049
6050 * utils.h (fatal): Remove declaration.
6051 * utils.c (fatal): Remove function.
6052
6053 2014-08-28 Gary Benson <gbenson@redhat.com>
6054
6055 * tracepoint.c (gdb_agent_init): Replace fatal with
6056 perror_with_name.
6057 (initialize_tracepoint): Likewise.
6058
6059 2014-08-28 Gary Benson <gbenson@redhat.com>
6060
6061 * remote-utils.c (remote_prepare): Replace fatal with error.
6062
6063 2014-08-28 Gary Benson <gbenson@redhat.com>
6064
6065 * linux-low.c (linux_async): Replace fatal with warning.
6066 Tidy up and return.
6067 (linux_start_non_stop): Return -1 if linux_async failed.
6068
6069 2014-08-28 Gary Benson <gbenson@redhat.com>
6070
6071 * linux-x86-low.c (i386_dr_low_set_addr): Replace check with
6072 gdb_assert.
6073 (i386_dr_low_get_addr): Remove vague comment.
6074 * win32-i386-low.c (i386_dr_low_set_addr): Replace check with
6075 gdb_assert.
6076
6077 2014-08-28 Gary Benson <gbenson@redhat.com>
6078
6079 * inferiors.c (get_thread_process): Replace check with gdb_assert.
6080 * linux-low.c (linux_wait_for_event_filtered): Replace fatal with
6081 internal_error.
6082 (linux_resume_one_lwp): Likewise.
6083 * linux-x86-low.c (x86_siginfo_fixup): Replace checks with
6084 gdb_assert.
6085 * mem-break.c (raw_bkpt_type_to_target_hw_bp_type): Replace fatal
6086 with internal_error.
6087 * regcache.c (get_thread_regcache): Replace check with gdb_assert.
6088 (init_register_cache): Replace fatal with gdb_assert_not_reached.
6089 (find_register_by_name): Replace fatal with internal_error.
6090 (find_regno): Likewise.
6091 * tdesc.c (init_target_desc): Replace check with gdb_assert.
6092 * thread-db.c (thread_db_create_event): Likewise.
6093 (thread_db_load_search): Likewise.
6094 (try_thread_db_load_1): Likewise.
6095 * tracepoint.c (get_jump_space_head): Replace fatal with
6096 internal_error.
6097 (claim_trampoline_space): Likewise.
6098 (have_fast_tracepoint_trampoline_buffer): Likewise.
6099 (cmd_qtstart): Likewise.
6100 (stop_tracing): Likewise.
6101 (fast_tracepoint_collecting): Likewise.
6102 (target_malloc): Likewise.
6103 (download_tracepoint): Likewise.
6104 (download_trace_state_variables): Replace check with gdb_assert.
6105 (upload_fast_traceframes): Replace fatal with internal_error.
6106
6107 2014-08-19 Tom Tromey <tromey@redhat.com>
6108 Gary Benson <gbenson@redhat.com>
6109
6110 * Makefile.in (SFILES): Add common/common-debug.c.
6111 (OBS): Add common-debug.o.
6112 (common-debug.o): New rule.
6113 * debug.h (debug_printf): Don't declare.
6114 * debug.c (debug_printf): Renamed and rewritten as...
6115 (debug_vprintf): New function.
6116
6117 2014-08-19 Gary Benson <gbenson@redhat.com>
6118
6119 * utils.h: Do not include print-utils.h.
6120
6121 2014-08-19 Tom Tromey <tromey@redhat.com>
6122 Gary Benson <gbenson@redhat.com>
6123
6124 * server.h: Add static assertion.
6125 (gdb_byte, CORE_ADDR, LONGEST, ULONGEST): Remove.
6126
6127 2014-08-19 Tom Tromey <tromey@redhat.com>
6128 Gary Benson <gbenson@redhat.com>
6129
6130 * Makefile.in (SFILES): Add common/errors.c.
6131 (OBS): Add errors.o.
6132 (IPA_OBS): Add errors-ipa.o.
6133 (errors.o): New rule.
6134 (errors-ipa.o): Likewise.
6135 * utils.h (perror_with_name, error, warning): Don't declare.
6136 * utils.c (warning): Renamed and rewritten as...
6137 (vwarning): New function.
6138 (error): Renamed and rewritten as...
6139 (verror): New function.
6140 (internal_error): Renamed and rewritten as...
6141 (internal_verror): New function.
6142
6143 2014-08-07 Gary Benson <gbenson@redhat.com>
6144
6145 * configure.ac (AC_CHECK_HEADERS): Remove errno.h.
6146 * configure: Regenerate.
6147 * config.in: Likewise.
6148 * server.h: Do not include errno.h.
6149 * event-loop.c: Likewise.
6150 * hostio-errno.c: Likewise.
6151 * linux-low.c: Likewise.
6152 * remote-utils.c: Likewise.
6153 * spu-low.c: Likewise.
6154 * utils.c: Likewise.
6155 * gdbreplay.c: Unconditionally include errno.h.
6156
6157 2014-08-07 Gary Benson <gbenson@redhat.com>
6158
6159 * server.h: Do not include string.h.
6160 * event-loop.c: Likewise.
6161 * linux-low.c: Likewise.
6162 * regcache.c: Likewise.
6163 * remote-utils.c: Likewise.
6164 * spu-low.c: Likewise.
6165 * utils.c: Likewise.
6166
6167 2014-08-07 Gary Benson <gbenson@redhat.com>
6168
6169 * server.h: Do not include gdb_assert.h.
6170
6171 2014-08-07 Gary Benson <gbenson@redhat.com>
6172
6173 * server.h: Do not include common-utils.h.
6174
6175 2014-08-07 Gary Benson <gbenson@redhat.com>
6176
6177 * server.h: Do not include ptid.h.
6178 * notif.h: Likewise.
6179
6180 2014-08-07 Gary Benson <gbenson@redhat.com>
6181
6182 * server.h: Do not include gdb_locale.h.
6183
6184 2014-08-07 Gary Benson <gbenson@redhat.com>
6185
6186 * server.h: Do not include gdb/signals.h.
6187 * win32-low.c: Likewise.
6188
6189 2014-08-07 Gary Benson <gbenson@redhat.com>
6190
6191 * server.h: Do not include pathmax.h.
6192
6193 2014-08-07 Gary Benson <gbenson@redhat.com>
6194
6195 * server.h: Do not include libiberty.h.
6196 * linux-bfin-low.c: Likewise.
6197
6198 2014-08-07 Gary Benson <gbenson@redhat.com>
6199
6200 * server.h: Do not include ansidecl.h.
6201
6202 2014-08-07 Gary Benson <gbenson@redhat.com>
6203
6204 * linux-x86-low.c: Do not include stddef.h.
6205 * lynx-ppc-low.c: Likewise.
6206 * tracepoint.c: Likewise.
6207
6208 2014-08-07 Gary Benson <gbenson@redhat.com>
6209
6210 * server.h: Do not include stdarg.h.
6211 * nto-low.c: Likewise.
6212
6213 2014-08-07 Gary Benson <gbenson@redhat.com>
6214
6215 * server.h: Do not include stdlib.h.
6216 * inferiors.c: Likewise.
6217 * linux-low.c: Likewise.
6218 * regcache.c: Likewise.
6219 * spu-low.c: Likewise.
6220 * tracepoint.c: Likewise.
6221 * utils.c: Likewise.
6222
6223 2014-08-07 Gary Benson <gbenson@redhat.com>
6224
6225 * server.h: Do not include stdio.h.
6226 * linux-low.c: Likewise.
6227 * remote-utils.c: Likewise.
6228 * spu-low.c: Likewise.
6229 * utils.c: Likewise.
6230 * wincecompat.c: Likewise.
6231
6232 2014-08-06 Gary Benson <gbenson@redhat.com>
6233
6234 * regcache.c (init_register_cache): Move conditionals inside if.
6235
6236 2014-08-06 Gary Benson <gbenson@redhat.com>
6237
6238 * linux-low.c (linux_supports_non_stop): Use target_is_async_p.
6239
6240 2014-07-31 Gary Benson <gbenson@redhat.com>
6241
6242 * ax.h: Do not include server.h.
6243 * gdbthread.h: Likewise.
6244 * lynx-low.h: Likewise.
6245 * notif.h: Likewise.
6246
6247 2014-07-30 Gary Benson <gbenson@redhat.com>
6248
6249 * server.h: Include common-defs.h.
6250 Do not include config.h or build-gnulib-gdbserver/config.h.
6251
6252 2014-07-30 Gary Benson <gbenson@redhat.com>
6253
6254 * hostio-errno.c: Move server.h to top of includes list.
6255 * inferiors.c: Likewise.
6256 * linux-x86-low.c: Likewise.
6257 * notif.c: Include server.h.
6258
6259 2014-07-24 Tom Tromey <tromey@redhat.com>
6260 Gary Benson <gbenson@redhat.com>
6261
6262 * server.h (CORE_ADDR): Now unsigned.
6263
6264 2014-07-16 Pedro Alves <palves@redhat.com>
6265
6266 * linux-low.c (linux_kill_one_lwp): Use kill_lwp, not kill.
6267
6268 2014-07-15 Pedro Alves <palves@redhat.com>
6269
6270 * linux-low.c (linux_kill_one_lwp): Save errno and work with saved
6271 copy.
6272
6273 2014-07-11 Pedro Alves <palves@redhat.com>
6274
6275 * linux-low.c (kill_wait_lwp): New function, based on
6276 kill_one_lwp_callback, but use my_waitpid directly.
6277 (kill_one_lwp_callback, linux_kill): Use it.
6278
6279 2014-06-23 Pedro Alves <palves@redhat.com>
6280
6281 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR_CONTROL
6282 before setting DR0..DR3.
6283
6284 2014-06-20 Gary Benson <gbenson@redhat.com>
6285
6286 * configure.ac (AC_REPLACE_FUNCS) <vasprintf, vsnprintf>: Removed.
6287 * configure: Regenerated.
6288 * config.in: Likewise.
6289
6290 2014-06-20 Gary Benson <gbenson@redhat.com>
6291
6292 * Makefile.in (SFILES): Update locations for files moved
6293 from common to nat.
6294 (object file files): Reordered.
6295
6296 2014-06-20 Gary Benson <gbenson@redhat.com>
6297
6298 * i386-low.h (i386_dr_low_can_set_addr): Removed.
6299 (i386_dr_low_set_addr): Likewise.
6300 (i386_dr_low_get_addr): Likewise.
6301 (i386_dr_low_can_set_control): Likewise.
6302 (i386_dr_low_set_control): Likewise.
6303 (i386_dr_low_get_control): Likewise.
6304 (i386_dr_low_get_status): Likewise.
6305 (i386_get_debug_register_length): Likewise.
6306 * linux-x86-low.c (i386_dr_low_set_addr):
6307 Changed signature. Made static.
6308 (i386_dr_low_get_addr): Likewise.
6309 (i386_dr_low_set_control): Likewise.
6310 (i386_dr_low_get_control): Likewise.
6311 (i386_dr_low_get_status): Likewise.
6312 (i386_dr_low): New global variable.
6313 * win32-i386-low.c (i386_dr_low_set_addr):
6314 Changed signature. Made static.
6315 (i386_dr_low_get_addr): Likewise.
6316 (i386_dr_low_set_control): Likewise.
6317 (i386_dr_low_get_control): Likewise.
6318 (i386_dr_low_get_status): Likewise.
6319 (i386_dr_low): New global variable.
6320
6321 2014-06-20 Marcus Shawcroft <marcus.shawcroft@arm.com>
6322
6323 * configure.ac: Invoke. AC_CHECK_TOOL(AR, ar).
6324 * Makefile.in (AR, AR_FLAGS): Define.
6325 * configure: Regenerate.
6326
6327 2014-06-19 Gary Benson <gbenson@redhat.com>
6328
6329 * Makefile.in (i386-dregs.o): New rule.
6330 * configure.srv: Add i386-dregs.o to all targets using i386-low.o.
6331 * i386-low.c (target.h): Remove include.
6332 (TARGET_HAS_DR_LEN_8): Now in i386-dregs.c.
6333 (DR_CONTROL_SHIFT): Likewise.
6334 (DR_CONTROL_SIZE): Likewise.
6335 (DR_RW_EXECUTE): Likewise.
6336 (DR_RW_WRITE): Likewise.
6337 (DR_RW_READ): Likewise.
6338 (DR_RW_IORW): Likewise.
6339 (DR_LEN_1): Likewise.
6340 (DR_LEN_2): Likewise.
6341 (DR_LEN_4): Likewise.
6342 (DR_LEN_8): Likewise.
6343 (DR_LOCAL_ENABLE_SHIFT): Likewise.
6344 (DR_GLOBAL_ENABLE_SHIFT): Likewise.
6345 (DR_ENABLE_SIZE): Likewise.
6346 (DR_LOCAL_SLOWDOWN): Likewise.
6347 (DR_GLOBAL_SLOWDOWN): Likewise.
6348 (DR_CONTROL_RESERVED): Likewise.
6349 (I386_DR_CONTROL_MASK): Likewise.
6350 (I386_DR_VACANT): Likewise.
6351 (I386_DR_LOCAL_ENABLE): Likewise.
6352 (I386_DR_GLOBAL_ENABLE): Likewise.
6353 (I386_DR_DISABLE): Likewise.
6354 (I386_DR_SET_RW_LEN): Likewise.
6355 (I386_DR_GET_RW_LEN): Likewise.
6356 (I386_DR_WATCH_HIT): Likewise.
6357 (i386_wp_op_t): Likewise.
6358 (i386_show_dr): Likewise.
6359 (i386_length_and_rw_bits): Likewise.
6360 (i386_insert_aligned_watchpoint): Likewise.
6361 (i386_remove_aligned_watchpoint): Likewise.
6362 (i386_handle_nonaligned_watchpoint): Likewise.
6363 i386_update_inferior_debug_regs(): Likewise.
6364 (i386_dr_insert_watchpoint): Likewise.
6365 (i386_dr_remove_watchpoint): Likewise.
6366 (i386_dr_region_ok_for_watchpoint): Likewise.
6367 (i386_dr_stopped_data_address): Likewise.
6368 (i386_dr_stopped_by_watchpoint): Likewise.
6369
6370 2014-06-19 Gary Benson <gbenson@redhat.com>
6371
6372 * i386-low.c (i386_dr_show): Renamed to
6373 i386_show_dr and made static. All uses updated.
6374 (i386_dr_length_and_rw_bits): Renamed to
6375 i386_length_and_rw_bits and made static.
6376 All uses updated.
6377 (i386_dr_insert_aligned_watchpoint): Renamed to
6378 i386_insert_aligned_watchpoint and made static.
6379 All uses updated.
6380 (i386_dr_remove_aligned_watchpoint): Renamed to
6381 i386_remove_aligned_watchpoint and made static.
6382 All uses updated.
6383 (i386_dr_update_inferior_debug_regs): Renamed to
6384 i386_update_inferior_debug_regs and made static.
6385 All uses updated.
6386
6387 2014-06-18 Gary Benson <gbenson@redhat.com>
6388
6389 * i386-low.h (i386_dr_low_can_set_addr): New macro.
6390 (i386_dr_low_can_set_control): Likewise.
6391 (i386_get_debug_register_length): Likewise.
6392 * i386-low.c (i386_dr_low_can_set_addr): Now in i386-low.h.
6393 (i386_dr_low_can_set_control): Likewise.
6394 (i386_get_debug_register_length): Likewise.
6395
6396 2014-06-17 Gary Benson <gbenson@redhat.com>
6397
6398 * i386-low.h (i386-dregs.h): New include.
6399 (DR_FIRSTADDR): Now in i386-dregs.h.
6400 (DR_LASTADDR): Likewise.
6401 (DR_NADDR): Likewise.
6402 (DR_STATUS): Likewise.
6403 (DR_CONTROL): Likewise.
6404 (i386_debug_reg_state): Likewise.
6405 (i386_dr_insert_watchpoint): Likewise.
6406 (i386_dr_remove_watchpoint): Likewise.
6407 (i386_dr_region_ok_for_watchpoint): Likewise.
6408 (i386_dr_stopped_data_address): Likewise.
6409 (i386_dr_stopped_by_watchpoint): Likewise.
6410 * i386-low.c (ALL_DEBUG_REGISTERS): Likewise.
6411
6412 2014-06-18 Gary Benson <gbenson@redhat.com>
6413
6414 * i386-low.h (i386_low_insert_watchpoint): Renamed to
6415 i386_dr_insert_watchpoint.
6416 (i386_low_remove_watchpoint): Renamed to
6417 i386_dr_remove_watchpoint.
6418 (i386_low_region_ok_for_watchpoint): Renamed to
6419 i386_dr_region_ok_for_watchpoint.
6420 (i386_low_stopped_data_address): Renamed to
6421 i386_dr_stopped_data_address.
6422 (i386_low_stopped_by_watchpoint): Renamed to
6423 i386_dr_stopped_by_watchpoint.
6424 * i386-low.c (i386_show_dr): Renamed to
6425 i386_dr_show and made nonstatic. All uses updated.
6426 (i386_length_and_rw_bits): Renamed to
6427 i386_dr_length_and_rw_bits and made nonstatic.
6428 All uses updated.
6429 (i386_insert_aligned_watchpoint): Renamed to
6430 i386_dr_insert_aligned_watchpoint and made nonstatic.
6431 All uses updated.
6432 (i386_remove_aligned_watchpoint): Renamed to
6433 i386_dr_remove_aligned_watchpoint and made nonstatic.
6434 All uses updated.
6435 (i386_update_inferior_debug_regs): Renamed to
6436 i386_dr_update_inferior_debug_regs and made nonstatic.
6437 All uses updated.
6438 (i386_low_insert_watchpoint): Renamed to
6439 i386_dr_insert_watchpoint. All uses updated.
6440 (i386_low_remove_watchpoint): Renamed to
6441 i386_dr_remove_watchpoint. All uses updated.
6442 (i386_low_region_ok_for_watchpoint): Renamed to
6443 i386_dr_region_ok_for_watchpoint. All uses updated.
6444 (i386_low_stopped_data_address): Renamed to
6445 i386_dr_stopped_data_address. All uses updated.
6446 (i386_low_stopped_by_watchpoint): Renamed to
6447 i386_dr_stopped_by_watchpoint. All uses updated.
6448
6449 2014-06-18 Gary Benson <gbenson@redhat.com>
6450
6451 * i386-low.c (i386_dr_low_can_set_addr): New macro.
6452 (i386_dr_low_can_set_control): Likewise.
6453 (i386_insert_aligned_watchpoint): New check.
6454
6455 2014-06-18 Gary Benson <gbenson@redhat.com>
6456
6457 * i386-low.c (i386_update_inferior_debug_regs) <inf_state>:
6458 Renamed to state.
6459
6460 2014-06-18 Gary Benson <gbenson@redhat.com>
6461
6462 * i386-low.c (i386_length_and_rw_bits): Use internal_error
6463 instead of fatal and error.
6464 (i386_handle_nonaligned_watchpoint): Likewise.
6465
6466 2014-06-18 Gary Benson <gbenson@redhat.com>
6467
6468 * i386-low.c (i386_get_debug_register_length): New macro.
6469 (TARGET_HAS_DR_LEN_8): Remove conditional. Use above macro.
6470 (i386_show_dr): Use debug_printf instead of fprintf. Use
6471 phex to format values.
6472
6473 2014-06-18 Gary Benson <gbenson@redhat.com>
6474
6475 * i386-low.h: Comment changes.
6476 * i386-low.c: Likewise.
6477
6478 2014-06-18 Gary Benson <gbenson@redhat.com>
6479
6480 * i386-low.c: Whitespace changes.
6481
6482 2014-06-12 Tom Tromey <tromey@redhat.com>
6483
6484 * utils.c (freeargv): Remove.
6485
6486 2014-06-12 Tom Tromey <tromey@redhat.com>
6487
6488 * debug.c (debug_printf): Remove HAVE_GETTIMEOFDAY checks.
6489 * server.c (monitor_show_help): Remove HAVE_GETTIMEOFDAY check.
6490 (parse_debug_format_options): Likewise.
6491 (gdbserver_usage): Likewise.
6492 * Makefile.in (LIBIBERTY_BUILDDIR, LIBIBERTY): New variables.
6493 (SUBDIRS, REQUIRED_SUBDIRS): Add libiberty.
6494 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Depend on and link
6495 against libiberty.
6496 ($(LIBGNU)): Depend on libiberty.
6497 (all-lib): Recurse into all subdirs.
6498 (install-only): Invoke "install" target in subdirs.
6499 (vasprintf.o, vsnprintf.o, safe-ctype.o, lbasename.o): Remove
6500 targets.
6501 * configure: Rebuild.
6502 * configure.ac: Add ACX_CONFIGURE_DIR for libiberty. Don't check
6503 for vasprintf, vsnprintf, or gettimeofday.
6504 * configure.srv: Don't add safe-ctype.o or lbasename.o to
6505 srv_tgtobj.
6506
6507 2014-06-05 Joel Brobecker <brobecker@adacore.com>
6508
6509 * development.sh: Delete.
6510 * Makefile.in (config.status): Adjust dependency on development.sh.
6511 * configure.ac: Adjust development.sh source call.
6512 * configure: Regenerate.
6513
6514 2014-06-02 Pedro Alves <palves@redhat.com>
6515
6516 * ax.c (gdb_free_agent_expr): New function.
6517 * ax.h (gdb_free_agent_expr): New declaration.
6518 * mem-break.c (delete_gdb_breakpoint_1): Also clear the commands
6519 list.
6520 (clear_breakpoint_conditions, clear_breakpoint_commands): Make
6521 static.
6522 (clear_breakpoint_conditions_and_commands): New function.
6523 * mem-break.h (clear_breakpoint_conditions): Delete declaration.
6524 (clear_breakpoint_conditions_and_commands): New declaration.
6525
6526 2014-05-23 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
6527
6528 * linux-aarch64-low.c (asm/ptrace.h): Include.
6529
6530 2014-05-21 Jan Kratochvil <jan.kratochvil@redhat.com>
6531
6532 Fix TLS access for -static -pthread.
6533 * gdbserver/thread-db.c (struct thread_db): Add td_thr_tlsbase_p.
6534 (thread_db_get_tls_address): Call it if LOAD_MODULE is zero.
6535 (thread_db_load_search, try_thread_db_load_1): Initialize it.
6536
6537 2014-05-20 Pedro Alves <palves@redhat.com>
6538
6539 * linux-aarch64-low.c (aarch64_insert_point)
6540 (aarch64_remove_point): No longer check whether the type is
6541 supported here. Adjust to new interface.
6542 (the_low_target): Install aarch64_supports_z_point_type as
6543 supports_z_point_type method.
6544 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type): New function.
6545 (arm_linux_hw_point_initialize): Take an enum raw_bkpt_type
6546 instead of a Z packet char. Adjust.
6547 (arm_supports_z_point_type): New function.
6548 (arm_insert_point, arm_remove_point): Adjust to new interface.
6549 (the_low_target): Install arm_supports_z_point_type.
6550 * linux-crisv32-low.c (cris_supports_z_point_type): New function.
6551 (cris_insert_point, cris_remove_point): Adjust to new interface.
6552 Don't check whether the type is supported here.
6553 (the_low_target): Install cris_supports_z_point_type.
6554 * linux-low.c (linux_supports_z_point_type): New function.
6555 (linux_insert_point, linux_remove_point): Adjust to new interface.
6556 * linux-low.h (struct linux_target_ops) <insert_point,
6557 remove_point>: Take an enum raw_bkpt_type instead of a char. Add
6558 raw_breakpoint pointer parameter.
6559 <supports_z_point_type>: New method.
6560 * linux-mips-low.c (mips_supports_z_point_type): New function.
6561 (mips_insert_point, mips_remove_point): Adjust to new interface.
6562 Use mips_supports_z_point_type.
6563 (the_low_target): Install mips_supports_z_point_type.
6564 * linux-ppc-low.c (the_low_target): Install NULL as
6565 supports_z_point_type method.
6566 * linux-s390-low.c (the_low_target): Install NULL as
6567 supports_z_point_type method.
6568 * linux-sparc-low.c (the_low_target): Install NULL as
6569 supports_z_point_type method.
6570 * linux-x86-low.c (x86_supports_z_point_type): New function.
6571 (x86_insert_point): Adjust to new insert_point interface. Use
6572 insert_memory_breakpoint. Adjust to new
6573 i386_low_insert_watchpoint interface.
6574 (x86_remove_point): Adjust to remove_point interface. Use
6575 remove_memory_breakpoint. Adjust to new
6576 i386_low_remove_watchpoint interface.
6577 (the_low_target): Install x86_supports_z_point_type.
6578 * lynx-low.c (lynx_target_ops): Install NULL as
6579 supports_z_point_type callback.
6580 * nto-low.c (nto_supports_z_point_type): New.
6581 (nto_insert_point, nto_remove_point): Adjust to new interface.
6582 (nto_target_ops): Install nto_supports_z_point_type.
6583 * mem-break.c: Adjust intro comment.
6584 (struct raw_breakpoint) <raw_type, size>: New fields.
6585 <inserted>: Update comment.
6586 <shlib_disabled>: Delete field.
6587 (enum bkpt_type) <gdb_breakpoint>: Delete value.
6588 <gdb_breakpoint_Z0, gdb_breakpoint_Z1, gdb_breakpoint_Z2,
6589 gdb_breakpoint_Z3, gdb_breakpoint_Z4>: New values.
6590 (raw_bkpt_type_to_target_hw_bp_type): New function.
6591 (find_enabled_raw_code_breakpoint_at): New function.
6592 (find_raw_breakpoint_at): New type and size parameters. Use them.
6593 (insert_memory_breakpoint): New function, based off
6594 set_raw_breakpoint_at.
6595 (remove_memory_breakpoint): New function.
6596 (set_raw_breakpoint_at): Reimplement.
6597 (set_breakpoint): New, based on set_breakpoint_at.
6598 (set_breakpoint_at): Reimplement.
6599 (delete_raw_breakpoint): Go through the_target->remove_point
6600 instead of assuming memory breakpoints.
6601 (find_gdb_breakpoint_at): Delete.
6602 (Z_packet_to_bkpt_type, Z_packet_to_raw_bkpt_type): New functions.
6603 (find_gdb_breakpoint): New function.
6604 (set_gdb_breakpoint_at): Delete.
6605 (z_type_supported): New function.
6606 (set_gdb_breakpoint_1): New function, loosely based off
6607 set_gdb_breakpoint_at.
6608 (check_gdb_bp_preconditions, set_gdb_breakpoint): New functions.
6609 (delete_gdb_breakpoint_at): Delete.
6610 (delete_gdb_breakpoint_1): New function, loosely based off
6611 delete_gdb_breakpoint_at.
6612 (delete_gdb_breakpoint): New function.
6613 (clear_gdb_breakpoint_conditions): Rename to ...
6614 (clear_breakpoint_conditions): ... this. Don't handle a NULL
6615 breakpoint.
6616 (add_condition_to_breakpoint): Make static.
6617 (add_breakpoint_condition): Take a struct breakpoint pointer
6618 instead of an address. Adjust.
6619 (gdb_condition_true_at_breakpoint): Rename to ...
6620 (gdb_condition_true_at_breakpoint_z_type): ... this, and add
6621 z_type parameter.
6622 (gdb_condition_true_at_breakpoint): Reimplement.
6623 (add_breakpoint_commands): Take a struct breakpoint pointer
6624 instead of an address. Adjust.
6625 (gdb_no_commands_at_breakpoint): Rename to ...
6626 (gdb_no_commands_at_breakpoint_z_type): ... this. Add z_type
6627 parameter. Return true if no breakpoint was found. Change debug
6628 output.
6629 (gdb_no_commands_at_breakpoint): Reimplement.
6630 (run_breakpoint_commands): Rename to ...
6631 (run_breakpoint_commands_z_type): ... this. Add z_type parameter,
6632 and change return type to boolean.
6633 (run_breakpoint_commands): New function.
6634 (gdb_breakpoint_here): Also check for Z1 breakpoints.
6635 (uninsert_raw_breakpoint): Don't try to reinsert a disabled
6636 breakpoint. Go through the_target->remove_point instead of
6637 assuming memory breakpoint.
6638 (uninsert_breakpoints_at, uninsert_all_breakpoints): Uninsert
6639 software and hardware breakpoints.
6640 (reinsert_raw_breakpoint): Go through the_target->insert_point
6641 instead of assuming memory breakpoint.
6642 (reinsert_breakpoints_at, reinsert_all_breakpoints): Reinsert
6643 software and hardware breakpoints.
6644 (check_breakpoints, breakpoint_here, breakpoint_inserted_here):
6645 Check both software and hardware breakpoints.
6646 (validate_inserted_breakpoint): Assert the breakpoint is a
6647 software breakpoint. Set the inserted flag to -1 instead of
6648 setting shlib_disabled.
6649 (delete_disabled_breakpoints): Adjust.
6650 (validate_breakpoints): Only validate software breakpoints.
6651 Adjust to inserted flag change.
6652 (check_mem_read, check_mem_write): Skip breakpoint types other
6653 than software breakpoints. Adjust to inserted flag change.
6654 * mem-break.h (enum raw_bkpt_type): New enum.
6655 (raw_breakpoint, struct process_info): Forward declare.
6656 (Z_packet_to_target_hw_bp_type): Delete declaration.
6657 (raw_bkpt_type_to_target_hw_bp_type, Z_packet_to_raw_bkpt_type)
6658 (set_gdb_breakpoint, delete_gdb_breakpoint)
6659 (clear_breakpoint_conditions): New declarations.
6660 (set_gdb_breakpoint_at, clear_gdb_breakpoint_conditions): Delete.
6661 (breakpoint_inserted_here): Update comment.
6662 (add_breakpoint_condition, add_breakpoint_commands): Replace
6663 address parameter with a breakpoint pointer parameter.
6664 (gdb_breakpoint_here): Update comment.
6665 (delete_gdb_breakpoint_at): Delete.
6666 (insert_memory_breakpoint, remove_memory_breakpoint): Declare.
6667 * server.c (process_point_options): Take a struct breakpoint
6668 pointer instead of an address. Adjust.
6669 (process_serial_event) <Z/z packets>: Use set_gdb_breakpoint and
6670 delete_gdb_breakpoint.
6671 * spu-low.c (spu_target_ops): Install NULL as
6672 supports_z_point_type method.
6673 * target.h: Include mem-break.h.
6674 (struct target_ops) <prepare_to_access_memory>: Update comment.
6675 <supports_z_point_type>: New field.
6676 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
6677 instead of a char. Also take a raw breakpoint pointer.
6678 * win32-arm-low.c (the_low_target): Install NULL as
6679 supports_z_point_type.
6680 * win32-i386-low.c (i386_supports_z_point_type): New function.
6681 (i386_insert_point, i386_remove_point): Adjust to new interface.
6682 (the_low_target): Install i386_supports_z_point_type.
6683 * win32-low.c (win32_supports_z_point_type): New function.
6684 (win32_insert_point, win32_remove_point): Adjust to new interface.
6685 (win32_target_ops): Install win32_supports_z_point_type.
6686 * win32-low.h (struct win32_target_ops):
6687 <supports_z_point_type>: New method.
6688 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
6689 instead of a char. Also take a raw breakpoint pointer.
6690
6691 2014-05-20 Pedro Alves <palves@redhat.com>
6692
6693 * mem-break.h: Include break-common.h.
6694 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
6695 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): New defines.
6696 (Z_packet_to_target_hw_bp_type): New declaration.
6697 * mem-break.c (Z_packet_to_target_hw_bp_type): New function.
6698 * i386-low.c (Z_PACKET_HW_BP, Z_PACKET_WRITE_WP, Z_PACKET_READ_WP)
6699 (Z_PACKET_ACCESS_WP): Delete macros.
6700 (Z_packet_to_hw_type): Delete function.
6701 * i386-low.h: Don't include break-common.h here.
6702 (Z_packet_to_hw_type): Delete declaration.
6703 * linux-x86-low.c (x86_insert_point, x86_insert_point): Call
6704 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
6705 * win32-i386-low.c (i386_insert_point, i386_remove_point): Call
6706 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
6707 * linux-aarch64-low.c: Don't include break-common.h here.
6708 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
6709 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): Delete macros.
6710 (Z_packet_to_target_hw_bp_type): Delete function.
6711 * linux-mips-low.c (rsp_bp_type_to_target_hw_bp_type): Delete
6712 function.
6713 (mips_insert_point, mips_remove_point): Use
6714 Z_packet_to_target_hw_bp_type.
6715
6716 2014-05-20 Pedro Alves <palves@redhat.com>
6717
6718 * linux-aarch64-low.c: Include break-common.h.
6719 (enum target_point_type): Delete.
6720 (Z_packet_to_point_type): Rename to ...
6721 (Z_packet_to_target_hw_bp_type): ... this, and return a
6722 target_hw_bp_type instead.
6723 (aarch64_show_debug_reg_state): Take an enum target_hw_bp_type
6724 instead of an enum target_point_type.
6725 (aarch64_point_encode_ctrl_reg): Likewise. Compute type mask from
6726 breakpoint type.
6727 (aarch64_dr_state_insert_one_point)
6728 (aarch64_dr_state_remove_one_point, aarch64_handle_breakpoint)
6729 (aarch64_handle_aligned_watchpoint)
6730 (aarch64_handle_unaligned_watchpoint, aarch64_handle_watchpoint):
6731 Take an enum target_hw_bp_type instead of an enum
6732 target_point_type.
6733 (aarch64_supports_z_point_type): New function.
6734 (aarch64_insert_point, aarch64_remove_point): Use it. Adjust to
6735 use Z_packet_to_target_hw_bp_type.
6736
6737 2014-05-20 Joel Brobecker <brobecker@adacore.com>
6738
6739 * configure.ac: Only use -Werror by default when DEVELOPMENT
6740 is true.
6741 * configure: Regenerate.
6742
6743 2014-05-19 Jan Kratochvil <jan.kratochvil@redhat.com>
6744
6745 Fix gdbserver qGetTLSAddr for x86_64 -m32.
6746 * linux-x86-low.c (X86_64_USER_REGS): New.
6747 (x86_fill_gregset): Call memset for BUF first in x86_64 -m32 case.
6748
6749 2014-04-28 Yao Qi <yao@codesourcery.com>
6750
6751 * Makefile.in (i386-avx512.c): Fix the typo of generated file
6752 name.
6753
6754 2014-04-25 Pedro Alves <palves@redhat.com>
6755
6756 PR server/16255
6757 * linux-low.c (linux_attach_fail_reason_string): New function.
6758 (linux_attach_lwp): Delete.
6759 (linux_attach_lwp_1): Rename to ...
6760 (linux_attach_lwp): ... this. Take a ptid instead of a pid as
6761 argument. Remove "initial" parameter. Return int instead of
6762 void. Don't error or warn here.
6763 (linux_attach): Adjust to call linux_attach_lwp. Call error on
6764 failure to attach to the tgid. Call warning when failing to
6765 attach to an lwp.
6766 * linux-low.h (linux_attach_lwp): Take a ptid instead of a pid as
6767 argument. Remove "initial" parameter. Return int instead of
6768 void. Don't error or warn here.
6769 (linux_attach_fail_reason_string): New declaration.
6770 * thread-db.c (attach_thread): Adjust to linux_attach_lwp's
6771 interface change. Use linux_attach_fail_reason_string.
6772
6773 2014-04-24 Michael Sturm <michael.sturm@mintel.com>
6774 Walfred Tedeschi <walfred.tedeschi@intel.com>
6775
6776 * Makefile.in: Added rules to handle new files
6777 i386-avx512.c i386-avx512-linux.c amd64-avx512.c
6778 amd64-avx512-linux.c x32-avx512.c x32-avx512-linux.c.
6779 * configure.srv (srv_i386_regobj): Add i386-avx512.o.
6780 (srv_i386_linux_regobj): Add i386-avx512-linux.o.
6781 (srv_amd64_regobj): Add amd64-avx512.o and x32-avx512.o.
6782 (srv_amd64_linux_regobj): Add amd64-avx512-linux.o and
6783 x32-avx512-linux.o.
6784 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx512.xml.
6785 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx512.xml.
6786 (srv_amd64_xmlfiles): Add i386/amd64-avx512.xml and
6787 i386/x32-avx512.xml.
6788 (srv_i386_linux_xmlfiles): Add i386/i386-avx512-linux.xml.
6789 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx512-linux.xml and
6790 i386/x32-avx512-linux.xml.
6791 * i387-fp.c (num_avx512_k_registers): New constant for number
6792 of K registers.
6793 (num_avx512_zmmh_low_registers): New constant for number of
6794 lower ZMM registers (0-15).
6795 (num_avx512_zmmh_high_registers): New constant for number of
6796 higher ZMM registers (16-31).
6797 (num_avx512_ymmh_registers): New contant for number of higher
6798 YMM registers (ymm16-31 added by avx521 on x86_64).
6799 (num_avx512_xmm_registers): New constant for number of higher
6800 XMM registers (xmm16-31 added by AVX512 on x86_64).
6801 (struct i387_xsave): Add space for AVX512 registers.
6802 (i387_cache_to_xsave): Change raw buffer size to 64 characters.
6803 Add code to handle AVX512 registers.
6804 (i387_xsave_to_cache): Add code to handle AVX512 registers.
6805 * linux-x86-low.c (init_registers_amd64_avx512_linux): New
6806 prototypei from generated file.
6807 (tdesc_amd64_avx512_linux): Likewise.
6808 (init_registers_x32_avx512_linux): Likewise.
6809 (tdesc_x32_avx512_linux): Likewise.
6810 (init_registers_i386_avx512_linux): Likewise.
6811 (tdesc_i386_avx512_linux): Likewise.
6812 (x86_64_regmap): Add AVX512 registers.
6813 (x86_linux_read_description): Add code to handle AVX512 XSTATE
6814 mask.
6815 (initialize_low_arch): Add code to initialize AVX512 registers.
6816
6817 2014-04-23 Pedro Alves <palves@redhat.com>
6818
6819 * mem-break.c (find_gdb_breakpoint_at): Make static.
6820 * mem-break.h (find_gdb_breakpoint_at): Delete declaration.
6821
6822 2014-04-23 Pedro Alves <palves@redhat.com>
6823
6824 * i386-low.c: Don't include break-common.h here.
6825 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
6826 prototype to take target_hw_bp_type as argument instead of a Z
6827 packet char.
6828 * i386-low.h: Include break-common.h here.
6829 (Z_packet_to_hw_type): Declare.
6830 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
6831 prototypes.
6832 * linux-x86-low.c (x86_insert_point): Convert the packet number to
6833 a target_hw_bp_type before calling i386_low_insert_watchpoint.
6834 (x86_remove_point): Convert the packet number to a
6835 target_hw_bp_type before calling i386_low_remove_watchpoint.
6836 * win32-i386-low.c (i386_insert_point): Convert the packet number
6837 to a target_hw_bp_type before calling i386_low_insert_watchpoint.
6838 (i386_remove_point): Convert the packet number to a
6839 target_hw_bp_type before calling i386_low_remove_watchpoint.
6840
6841 2014-04-23 Pedro Alves <palves@redhat.com>
6842
6843 * utils.h (perror_with_name): Add ATTRIBUTE_NORETURN.
6844
6845 2014-04-10 Pedro Alves <palves@redhat.com>
6846
6847 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
6848 Check if the condition or command is NULL before checking if the
6849 breakpoint is known. On success, return true.
6850 * mem-break.h (add_breakpoint_condition): Document return.
6851 (add_breakpoint_commands): Add describing comment.
6852 * server.c (skip_to_semicolon): New function.
6853 (process_point_options): Use it.
6854
6855 2014-04-09 Pedro Alves <palves@redhat.com>
6856
6857 * linux-low.c (linux_read_loadmap): Pass current_inferior directly
6858 to lwpid_of.
6859
6860 2014-02-27 Pedro Alves <palves@redhat.com>
6861
6862 PR 12702
6863 * inferiors.h (A_I_NEXT, ALL_INFERIORS_TYPE, ALL_PROCESSES): New
6864 macros.
6865 * linux-low.c (delete_lwp, handle_extended_wait): Add debug
6866 output.
6867 (last_thread_of_process_p): Take a PID argument instead of a
6868 thread pointer.
6869 (linux_wait_for_lwp): Delete.
6870 (num_lwps, check_zombie_leaders, not_stopped_callback): New
6871 functions.
6872 (linux_low_filter_event): New function, party factored out from
6873 linux_wait_for_event.
6874 (linux_wait_for_event): Rename to ...
6875 (linux_wait_for_event_filtered): ... this. Add new filter ptid
6876 argument. Partly rewrite. Always use waitpid(-1, WNOHANG) and
6877 sigsuspend. Check for zombie leaders.
6878 (linux_wait_for_event): Reimplement as wrapper around
6879 linux_wait_for_event_filtered.
6880 (linux_wait_1): Handle TARGET_WAITKIND_NO_RESUMED. Assume that if
6881 a normal or signal exit is seen, it's the whole process exiting.
6882 (wait_for_sigstop): No longer a for_each_inferior callback.
6883 Rewrite on top of linux_wait_for_event_filtered.
6884 (stop_all_lwps): Call wait_for_sigstop directly.
6885 * server.c (resume, handle_target_event): Handle
6886 TARGET_WAITKIND_NO_RESUMED.
6887
6888 2014-02-26 Joel Brobecker <brobecker@adacore.com>
6889
6890 * win32-low.c (psapi_get_dll_name,
6891 * win32_CreateToolhelp32Snapshot): Delete.
6892 (win32_CreateToolhelp32Snapshot, win32_Module32First)
6893 (win32_Module32Next, load_toolhelp, toolhelp_get_dll_name):
6894 Delete.
6895 (handle_load_dll): Add function description.
6896 Remove code using psapi_get_dll_name and toolhelp_get_dll_name.
6897
6898 2014-02-26 Joel Brobecker <brobecker@adacore.com>
6899
6900 * win32-low.c (win32_add_one_solib): Add 0x1000 to load_addr.
6901 Add comment.
6902 (win32_add_all_dlls): Remove 0x1000 offset applied to DLL
6903 base address when calling win32_add_one_solib.
6904 (handle_load_dll): Delete local variable load_addr.
6905 Remove 0x1000 offset applied to DLL base address when calling
6906 win32_add_one_solib.
6907 (handle_unload_dll): Add comment.
6908
6909 2014-02-26 Joel Brobecker <brobecker@adacore.com>
6910
6911 * win32-low.c (win32_add_all_dlls): Renames
6912 win32_ensure_ntdll_loaded. Rewrite function documentation.
6913 Adjust implementation to always load all DLLs.
6914 Add 0x1000 offset to DLL base address when calling
6915 win32_add_one_solib.
6916 (child_initialization_done): New static global.
6917 (do_initial_child_stuff): Set child_initialization_done to
6918 zero during child initialization, and 1 after. Replace call
6919 to win32_ensure_ntdll_loaded by call to win32_add_all_dlls.
6920 Add comment.
6921 (match_dll_by_basename, dll_is_loaded_by_basename): Delete.
6922 (handle_unload_dll): Add function documentation.
6923 (get_child_debug_event): Ignore load and unload DLL events
6924 during child initialization.
6925
6926 2014-02-20 Doug Evans <dje@google.com>
6927
6928 Remove global all_lwps.
6929 * inferiors.h (ptid_of): Move here from linux-low.h.
6930 (pid_of, lwpid_of): Ditto.
6931 * linux-aarch64-low.c (debug_reg_change_callback): Update, "entry"
6932 parameter is a struct thread_info * now.
6933 (aarch64_notify_debug_reg_change): Fetch pid from current_inferior
6934 directly. Pass &all_threads to find_inferior instead of &all_lwps.
6935 (aarch64_stopped_data_address): Fetch lwpid from current_inferior
6936 directly.
6937 (aarch64_linux_prepare_to_resume): Fetch ptid from thread.
6938 (aarch64_arch_setup): Fetch lwpid from current_inferior directly.
6939 * linux-arm-low.c (update_registers_callback): Update, "entry"
6940 parameter is a struct thread_info * now.
6941 Fetch lwpid from current_inferior directly.
6942 (arm_insert_point): Pass &all_threads to find_inferior instead of
6943 &all_lwps.
6944 (arm_remove_point): Ditto.
6945 (arm_stopped_by_watchpoint): Fetch lwp from current_inferior.
6946 (arm_prepare_to_resume): Fetch pid from thread.
6947 (arm_read_description): Fetch lwpid from current_inferior directly.
6948 * linux-low.c (all_lwps): Delete.
6949 (delete_lwp): Delete call to remove_inferior.
6950 (handle_extended_wait): Fetch lwpid from thread.
6951 (add_lwp): Don't set lwp->entry.id. Remove call to
6952 add_inferior_to_list.
6953 (linux_attach_lwp_1): Fetch pid from current_inferior directly.
6954 (linux_kill_one_lwp): Fetch ptid,lwpid from thread.
6955 (kill_one_lwp_callback): Ditto.
6956 (linux_kill): Don't dereference NULL pointer.
6957 Fetch ptid,lwpid from thread.
6958 (get_detach_signal): Fetch ptid from thread.
6959 (linux_detach_one_lwp): Fetch ptid,lwpid from thread.
6960 Simplify call to regcache_invalidate_thread.
6961 (delete_lwp_callback): Update, "entry" parameter is a
6962 struct thread_info * now. Fetch pid from thread.
6963 (linux_mourn): Pass &all_threads to find_inferior instead of &all_lwps.
6964 (status_pending_p_callback): Update, "entry" parameter is a
6965 struct thread_info * now. Fetch ptid from thread.
6966 (find_lwp_pid): Update, "entry" parameter is a
6967 struct thread_info * now.
6968 (linux_wait_for_lwp): Fetch pid from thread.
6969 (linux_fast_tracepoint_collecting): Fetch lwpid from thread.
6970 (maybe_move_out_of_jump_pad): Fetch lwpid from current_inferior.
6971 (enqueue_one_deferred_signal): Fetch lwpid from thread.
6972 (dequeue_one_deferred_signal): Ditto.
6973 (cancel_breakpoint): Fetch ptid from current_inferior.
6974 (linux_wait_for_event): Pass &all_threads to find_inferior,
6975 not &all_lwps. Fetch ptid, lwpid from thread.
6976 (count_events_callback): Update, "entry" parameter is a
6977 struct thread_info * now.
6978 (select_singlestep_lwp_callback): Ditto.
6979 (select_event_lwp_callback): Ditto.
6980 (cancel_breakpoints_callback): Ditto.
6981 (linux_cancel_breakpoints): Pass &all_threads to find_inferior,
6982 not &all_lwps.
6983 (select_event_lwp): Ditto. Fetch ptid from event_thread.
6984 (unsuspend_one_lwp): Update, "entry" parameter is a
6985 struct thread_info * now.
6986 (unsuspend_all_lwps): Pass &all_threads to find_inferior,
6987 not &all_lwps.
6988 (linux_stabilize_threads): Ditto. And for for_each_inferior.
6989 Fetch lwpid from thread, not lwp.
6990 (linux_wait_1): Fetch ptid, lwpid from current_inferior.
6991 Pass &all_threads to find_inferior, not &all_lwps.
6992 (send_sigstop): Fetch lwpid from thread, not lwp.
6993 (send_sigstop_callback): Update, "entry" parameter is a
6994 struct thread_info * now.
6995 (suspend_and_send_sigstop_callback): Ditto.
6996 (wait_for_sigstop): Ditto. Fetch ptid, lwpid from thread, lwp.
6997 (stuck_in_jump_pad_callback): Update, "entry" parameter is a
6998 struct thread_info * now.
6999 (move_out_of_jump_pad_callback): Ditto. Fetch ptid, lwpid
7000 from thread, lwp.
7001 (lwp_running): Update, "entry" parameter is a
7002 struct thread_info * now.
7003 (stop_all_lwps): Fetch ptid from thread.
7004 Pass &all_threads to find_inferior, for_each_inferior, not &all_lwps.
7005 (linux_resume_one_lwp): Fetch lwpid from thread.
7006 (linux_set_resume_request): Update, "entry" parameter is a
7007 struct thread_info * now. Fetch pid, lwpid from thread.
7008 (resume_status_pending_p): Update, "entry" parameter is a
7009 struct thread_info * now.
7010 (need_step_over_p): Ditto. Fetch lwpid from thread.
7011 (start_step_over): Fetch lwpid from thread.
7012 (linux_resume_one_thread): Update, "entry" parameter is a
7013 struct thread_info * now. Fetch lwpid from thread.
7014 (linux_resume): Pass &all_threads to find_inferior, not &all_lwps.
7015 (proceed_one_lwp): Update, "entry" parameter is a
7016 struct thread_info * now. Fetch lwpid from thread.
7017 (unsuspend_and_proceed_one_lwp): Update, "entry" parameter is a
7018 struct thread_info * now.
7019 (proceed_all_lwps): Pass &all_threads to find_inferior, not &all_lwps.
7020 (unstop_all_lwps): Ditto. Fetch lwpid from thread.
7021 (regsets_fetch_inferior_registers): Fetch lwpid from current_inferior
7022 directly.
7023 (regsets_store_inferior_registers): Ditto.
7024 (fetch_register, store_register): Ditto.
7025 (linux_read_memory, linux_write_memory): Ditto.
7026 (linux_request_interrupt): Ditto.
7027 (linux_read_auxv): Ditto.
7028 (linux_xfer_siginfo): Ditto.
7029 (linux_qxfer_spu): Ditto.
7030 (linux_qxfer_libraries_svr4): Ditto.
7031 * linux-low.h (ptid_of, pid_of, lwpid_of): Delete,
7032 moved to inferiors.h.
7033 (get_lwp): Delete.
7034 (get_thread_lwp): Update.
7035 (struct lwp_info): Delete member "entry". Simplify comment for
7036 member "thread".
7037 (all_lwps): Delete.
7038 * linux-mips-low.c (mips_read_description): Fetch lwpid from
7039 current_inferior directly.
7040 (update_watch_registers_callback): Update, "entry" parameter is a
7041 struct thread_info * now. Fetch pid from thread.
7042 (mips_linux_prepare_to_resume): Fetch ptid from thread.
7043 (mips_insert_point): Fetch lwpid from current_inferior.
7044 Pass &all_threads to find_inferior, not &all_lwps.
7045 (mips_remove_point): Pass &all_threads to find_inferior, not &all_lwps.
7046 (mips_stopped_by_watchpoint): Fetch lwpid from current_inferior
7047 directly.
7048 (mips_stopped_data_address): Ditto.
7049 * linux-s390-low.c (s390_arch_setup): Fetch pid from current_inferior
7050 directly.
7051 * linux-tile-low.c (tile_arch_setup): Ditto.
7052 * linux-x86-low.c (x86_get_thread_area): Fetch lwpid from thread.
7053 (update_debug_registers_callback): Update, "entry" parameter is a
7054 struct thread_info * now. Fetch pid from thread.
7055 (i386_dr_low_set_addr): Fetch pid from current_inferior directly.
7056 Pass &all_threads to find_inferior, not &all_lwps.
7057 (i386_dr_low_get_addr): Fetch ptid from current_inferior directly.
7058 (i386_dr_low_set_control): Fetch pid from current_inferior directly.
7059 Pass &all_threads to find_inferior, not &all_lwps.
7060 (i386_dr_low_get_control): Fetch ptid from current_inferior directly.
7061 (i386_dr_low_get_status): Ditto.
7062 (x86_linux_prepare_to_resume): Fetch ptid from thread.
7063 (x86_siginfo_fixup): Fetch lwpid from current_inferior directly.
7064 (x86_linux_read_description): Ditto.
7065 * proc-service.c (ps_getpid): Fetch pid from current_inferior directly.
7066
7067 2014-02-20 Doug Evans <dje@google.com>
7068
7069 * inferiors.c (get_first_inferior): Fix buglet.
7070
7071 2014-02-19 Doug Evans <dje@google.com>
7072
7073 * gdbthread.h (add_thread): Change result type to struct thread_info *.
7074 * inferiors.c (add_thread): Change result type to struct thread_info *.
7075 All callers updated.
7076 (add_lwp): Call add_thread here instead of in callers.
7077 All callers updated.
7078 * linux-low.h (get_lwp_thread): Rewrite.
7079 (struct lwp_info): New member "thread".
7080
7081 2014-02-19 Doug Evans <dje@google.com>
7082
7083 * linux-low.c (add_lwp): Change result to struct lwp_info *.
7084 All callers updated.
7085
7086 2014-02-19 Doug Evans <dje@google.com>
7087
7088 * inferiors.c (add_thread): Fix whitespace.
7089
7090 2014-02-19 Doug Evans <dje@google.com>
7091
7092 * dll.c (clear_dlls): Replace accessing list implemention details
7093 with API function.
7094 * gdbthread.h (get_first_thread): Declare.
7095 * inferiors.c (for_each_inferior_with_data): New function.
7096 (get_first_thread): New function.
7097 (find_thread_ptid): Simplify.
7098 (get_first_inferior): New function.
7099 (clear_list): Delete.
7100 (one_inferior_p): New function.
7101 (clear_inferior_list): New function.
7102 (clear_inferiors): Update.
7103 * inferiors.h (for_each_inferior_with_data): Declare.
7104 (clear_inferior_list): Declare.
7105 (one_inferior_p): Declare.
7106 (get_first_inferior): Declare.
7107 * linux-low.c (linux_wait_for_event): Replace accessing list
7108 implemention details with API function.
7109 * server.c (target_running): Ditto.
7110 (accumulate_file_name_length): New function.
7111 (emit_dll_description): New function.
7112 (handle_qxfer_libraries): Replace accessing list implemention
7113 details with API function.
7114 (handle_qxfer_threads_worker): New function.
7115 (handle_qxfer_threads_proper): Replace accessing list implemention
7116 details with API function.
7117 (handle_query): Ditto.
7118 (visit_actioned_threads_callback_ftype): New typedef.
7119 (visit_actioned_threads_data): New struct.
7120 (visit_actioned_threads): Rewrite to be find_inferior callback.
7121 (resume): Call find_inferior.
7122 (handle_status): Replace accessing list implemention
7123 details with API function.
7124 (process_serial_event): Replace accessing list implemention details
7125 with API function.
7126 * target.c (set_desired_inferior): Replace accessing list implemention
7127 details with API function.
7128 * tracepoint.c (same_process_p): New function.
7129 (gdb_agent_about_to_close): Replace accessing list implemention
7130 details with API function.
7131 * win32-low.c (child_delete_thread): Replace accessing list
7132 implemention details with API function.
7133 (match_dll_by_basename): New function.
7134 (dll_is_loaded_by_basename): New function.
7135 (win32_ensure_ntdll_loaded): Replace accessing list implemention
7136 details call to dll_is_loaded_by_basename.
7137
7138 2014-02-19 Doug Evans <dje@google.com>
7139
7140 * dll.h (struct dll_info): Add comment.
7141 * gdbthread.h (struct thread_info): Add comment.
7142 (current_ptid): Simplify.
7143 * inferiors.c (add_process): Update.
7144 (remove_process): Update.
7145 * inferiors.h (struct process_info): Rename member "head" to "entry".
7146 * linux-low.c (delete_lwp): Update.
7147 (add_lwp): Update.
7148 (last_thread_of_process_p): Update.
7149 (kill_one_lwp_callback, linux_kill): Update.
7150 (status_pending_p_callback): Update.
7151 (wait_for_sigstop): Update. Simplify read of ptid.
7152 (start_step_over): Update.
7153 * linux-low.h (ptid_of, pid_of, lwpid_of): Update.
7154 (get_lwp_thread): Update.
7155 (struct lwp_info): Rename member "head" to "entry".
7156 * regcache.h (inferior_list_entry): Delete.
7157 * server.c (kill_inferior_callback): Update.
7158 (detach_or_kill_inferior_callback): Update.
7159 (print_started_pid): Update.
7160 (print_attached_pid): Update.
7161 (process_serial_event): Simplify read of ptid.
7162 * thread-db.c (thread_db_create_event): Update.
7163 (thread_db_get_tls_address): Update.
7164 * win32-low.c (current_inferior_ptid): Simplify.
7165
7166 2014-02-19 Tom Tromey <tromey@redhat.com>
7167
7168 * target.h (struct target_ops) <supports_btrace>: Add target_ops
7169 argument.
7170 (target_supports_btrace): Update.
7171
7172 2014-02-14 Yao Qi <yao@codesourcery.com>
7173
7174 * Makefile.in (IPA_OBJS): Append rsp-low-ipa.o.
7175 (rsp-low-ipa.o): New target.
7176
7177 2014-02-12 Tom Tromey <tromey@redhat.com>
7178
7179 * ax.c (gdb_parse_agent_expr): Use hex2bin, not
7180 convert_ascii_to_int.
7181 * regcache.c (registers_to_string): Likewise.
7182 * remote-utils.c (decode_M_packet): Likewise.
7183 * server.c (process_serial_event): Likewise.
7184
7185 2014-02-12 Tom Tromey <tromey@redhat.com>
7186
7187 * server.c (handle_query, handle_v_run): Use hex2bin, not
7188 unhexify.
7189 * tracepoint.c (cmd_qtdpsrc, cmd_qtdv, cmd_qtnotes): Likewise.
7190
7191 2014-02-12 Tom Tromey <tromey@redhat.com>
7192
7193 * ax.c (gdb_unparse_agent_expr): Use bin2hex, not
7194 convert_int_to_ascii.
7195 * regcache.c (registers_to_string, collect_register_as_string):
7196 Likewise.
7197 * remote-utils.c (look_up_one_symbol, relocate_instruction):
7198 Likewise.
7199 * server.c (process_serial_event): Likewise.
7200 * tracepoint.c (cmd_qtstatus, response_source, response_tsv)
7201 (cmd_qtbuffer, cstr_to_hexstr): Likewise.
7202
7203 2014-02-12 Tom Tromey <tromey@redhat.com>
7204
7205 * remote-utils.c (look_up_one_symbol, monitor_output): Use
7206 bin2hex, not hexify.
7207 * tracepoint.c (cmd_qtstatus): Likewise.
7208
7209 2014-02-12 Tom Tromey <tromey@redhat.com>
7210
7211 * remote-utils.c (monitor_output): Pass explicit length to
7212 hexify.
7213
7214 2014-02-12 Tom Tromey <tromey@redhat.com>
7215
7216 * tracepoint.c: Include rsp-low.h.
7217 * server.c: Include rsp-low.h.
7218 * remote-utils.h (convert_ascii_to_int, convert_int_to_ascii)
7219 (unhexify, hexify, remote_escape_output, unpack_varlen_hex): Don't
7220 declare.
7221 * remote-utils.c: Include rsp-low.h.
7222 (fromhex, hexchars, ishex, unhexify, tohex, hexify)
7223 (remote_escape_output, remote_unescape_input, unpack_varlen_hex)
7224 (convert_int_to_ascii, convert_ascii_to_int): Move to
7225 common/rsp-low.c.
7226 * regcache.c: Include rsp-low.h.
7227 * ax.c: Include rsp-low.h.
7228 * Makefile.in (SFILES): Add common/rsp-low.c.
7229 (OBS): Add rsp-low.o.
7230 (rsp-low.o): New target.
7231
7232 2014-02-12 Tom Tromey <tromey@redhat.com>
7233
7234 * utils.h (pulongest, plongest, phex_nz): Don't declare.
7235 Include print-utils.h.
7236 * utils.c (NUMCELLS, CELLSIZE, get_cell, decimal2str, pulongest)
7237 (plongest, thirty_two, phex_nz): Remove.
7238 * Makefile.in (SFILES): Add common/print-utils.c.
7239 (OBS): Add print-utils.o.
7240 (print-utils-ipa.o): New target.
7241 (print-utils.o): New target.
7242 (IPA_OBJS): Add print-utils-ipa.o.
7243
7244 2014-02-06 Tom Tromey <tromey@redhat.com>
7245
7246 * Makefile.in (SFILES): Fix indentation.
7247
7248 2014-02-05 Doug Evans <dje@google.com>
7249
7250 * linux-low.c (linux_wait_for_event): Improve comment.
7251 (linux_wait_1): Keep current_inferior in sync with event_child.
7252
7253 2014-01-22 Doug Evans <dje@google.com>
7254
7255 * gdbthread.h (gdb_id_to_thread): Delete, unused.
7256
7257 2014-01-22 Doug Evans <dje@google.com>
7258
7259 * configure.ac (AC_CHECK_FUNCS): Add test for gettimeofday.
7260 * configure: Regenerate.
7261 * config.in: Regenerate.
7262 * Makefile.in (SFILES): Add debug.c.
7263 (OBS): Add debug.o.
7264 * debug.c: New file.
7265 * debug.h: New file.
7266 * linux-aarch64-low.c (*): Update all debugging printfs to use
7267 debug_printf instead of fprintf.
7268 * linux-arm-low.c (*): Ditto.
7269 * linux-cris-low.c (*): Ditto.
7270 * linux-crisv32-low.c (*): Ditto.
7271 * linux-m32r-low.c (*): Ditto.
7272 * linux-sparc-low.c (*): Ditto.
7273 * linux-x86.c (*): Ditto.
7274 * linux-low.c (*): Ditto.
7275 (linux_wait_1): Add calls to debug_enter, debug_exit.
7276 (linux_wait): Remove redundant debugging printf.
7277 (stop_all_lwps): Add calls to debug_enter, debug_exit.
7278 (linux_resume, unstop_all_lwps): Ditto.
7279 * mem-break.c (*): Update all debugging printfs to use
7280 debug_printf instead of fprintf.
7281 * remote-utils.c (*): Ditto.
7282 * thread-db.c (*): Ditto.
7283 * server.c #include <ctype.h>, "gdb_vecs.h".
7284 (debug_threads): Moved to debug.c.
7285 (*): Update all debugging printfs to use debug_printf instead of
7286 fprintf.
7287 (start_inferior): Replace call to fflush with call to debug_flush.
7288 (monitor_show_help): Mention set debug-format.
7289 (parse_debug_format_options): New function.
7290 (handle_monitor_command): Handle "monitor set debug-format".
7291 (gdbserver_usage): Mention --debug-format.
7292 (main): Parse --debug-format.
7293 * server.h (debug_threads): Declaration moved to debug.h.
7294 #include "debug.h".
7295 * tracepoint.c (trace_debug_1) [!IN_PROCESS_AGENT]: Add version of
7296 trace_debug_1 that uses debug_printf.
7297 (tracepoint_look_up_symbols): Update all debugging printfs to use
7298 debug_printf instead of fprintf.
7299
7300 2014-01-20 Baruch Siach <baruch@tkos.co.il>
7301
7302 * linux-xtensa-low.c: Include asm/ptrace.h instead of
7303 sys/ptrace.h.
7304
7305 2014-01-17 Pedro Alves <palves@redhat.com>
7306
7307 PR build/16445
7308 * linux-x86-low.c: Don't include elf/common.h if ELFMAG0 is
7309 defined after including gdb_proc_service.h.
7310
7311 2014-01-16 Doug Evans <dje@google.com>
7312
7313 * dll.c (UNSPECIFIED_CORE_ADDR): New macro.
7314 (match_dll): Use it.
7315
7316 2014-01-16 Markus Metzger <markus.t.metzger@intel.com>
7317
7318 * target.h (target_ops) <read_btrace>: Change parameters and
7319 return type to allow error reporting.
7320 * server.c (handle_qxfer_btrace): Support delta reads. Pass
7321 trace reading errors on.
7322 * linux-low.c (linux_low_read_btrace): Pass trace reading
7323 errors on.
7324 (linux_low_disable_btrace): New.
7325
7326 2014-01-15 Doug Evans <dje@google.com>
7327
7328 * inferiors.c (thread_id_to_gdb_id): Delete.
7329 * inferiors.h (thread_id_to_gdb_id): Delete.
7330
7331 2014-01-13 Eli Zaretskii <eliz@gnu.org>
7332
7333 * Makefile.in (INCLUDE_CFLAGS): Remove trailing slash from
7334 "-I$(srcdir)/../". Fixes MinGW compilation errors with old GCC
7335 versions.
7336
7337 2014-01-08 Pedro Alves <palves@redhat.com>
7338
7339 * server.c (handle_status): Don't discard previous queued stop
7340 replies or thread's pending status here.
7341 (main) <disconnection>: Do it here instead.
7342
7343 2014-01-08 Pedro Alves <palves@redhat.com>
7344
7345 * gdbthread.h (struct thread_info) <status_pending_p>: New field.
7346 * server.c (visit_actioned_threads, handle_pending_status): New
7347 function.
7348 (handle_v_cont): Factor out parts to ...
7349 (resume): ... this new function. If in all-stop, and a thread
7350 being resumed has a pending status, report it without actually
7351 resuming.
7352 (myresume): Adjust to use the new 'resume' function.
7353 (clear_pending_status_callback, set_pending_status_callback)
7354 (find_status_pending_thread_callback): New functions.
7355 (handle_status): Handle the case of multiple threads having
7356 interesting statuses to report. Report threads' real last signal
7357 instead of always reporting GDB_SIGNAL_TRAP. Look for a thread
7358 with an interesting thread to report the status for, instead of
7359 always reporting the status of the first thread.
7360
7361 2014-01-01 Joel Brobecker <brobecker@adacore.com>
7362
7363 * gdbserver.c (gdbserver_version): Set copyright year to 2014.
7364 * gdbreplay.c (gdbreplay_version): Likewise.
7365
7366 2013-12-18 Yufeng Zhang <yufeng.zhang@arm.com>
7367
7368 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Set
7369 iov.iov_len with the real length in use.
7370
7371 2013-12-13 Joel Brobecker <brobecker@adacore.com>
7372
7373 * Makefile.in (safe-ctype.o, lbasename.o): New rules.
7374 * configure.srv: Add safe-ctype.o and lbasename.o to srv_tgtobj
7375 for all targets that use win32-low.c.
7376 * win32-low.c (win32_ensure_ntdll_loaded): New function.
7377 (do_initial_child_stuff): Add call to win32_ensure_ntdll_loaded.
7378
7379 2013-12-13 Pedro Alves <palves@redhat.com>
7380
7381 * target.c (mywait): Set OURSTATUS->KIND to TARGET_WAITKIND_STOPPED
7382 if equal to TARGET_WAITKIND_LOADED.
7383 * win32-low.c (cached_status): New static global.
7384 (win32_wait): Add declaration.
7385 (do_initial_child_stuff): Flush all initial pending debug events
7386 up to the initial breakpoint.
7387 (win32_wait): If CACHED_STATUS was set, return that instead
7388 of doing a real wait. Remove the code resuming the execution
7389 of the inferior after receiving a TARGET_WAITKIND_LOADED event
7390 during the initial phase. Also remove the code changing
7391 OURSTATUS->KIND from TARGET_WAITKIND_LOADED to
7392 TARGET_WAITKIND_STOPPED.
7393
7394 2013-12-11 Yao Qi <yao@codesourcery.com>
7395
7396 * notif.c (handle_notif_ack): Return 0 if no notification
7397 matches.
7398
7399 2013-11-20 Doug Evans <dje@google.com>
7400
7401 * linux-low.c (linux_set_resume_request): Fix comment.
7402
7403 2013-11-20 Doug Evans <dje@google.com>
7404
7405 * linux-low.c (resume_status_pending_p): Tweak comment.
7406
7407 2013-11-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
7408
7409 * Makefile.in: Add i386-mpx.c, i386-mpx-linux.c, amd64-mpx.c,
7410 amd64-mpx-linux.c, x32-mpx.c and x32-mpx-linux.c generation.
7411 * configure.srv (srv_i386_regobj): Add i386-mpx.o.
7412 (srv_i386_linux_regobj): Add i386-mpx-linux.o.
7413 (srv_amd64_regobj): Add amd64-mpx.o.
7414 (srv_amd64_linux_regobj): Add amd64-mpx-linux.o.
7415 (srv_i386_32bit_xmlfiles): Add i386/32bit-mpx.xml.
7416 (srv_i386_64bit_xmlfiles): Add i386/64bit-mpx.xml.
7417 * i387-fp.c (num_pl_bnd_register) Added constant.
7418 (num_pl_bnd_cfg_registers) Added constant.
7419 (struct i387_xsave) Added reserved area and MPX fields.
7420 (i387_cache_to_xsave, i387_xsave_to_cache) Add MPX.
7421 * linux-x86-low.c (init_registers_i386_mpx_linux): Declare new
7422 function.
7423 (tdesc_i386_mpx_linux): Add MPX amd64 target.
7424 (init_registers_amd64_mpx_linux): Declare new function.
7425 (tdesc_amd64_mpx_linux): Add MPX amd64 target.
7426 (x86_64_regmap): Add MPX registers.
7427 (x86_linux_read_description): Add MPX case.
7428 (initialize_low_arch): Initialize MPX targets.
7429
7430 2013-11-18 Tom Tromey <tromey@redhat.com>
7431
7432 * configure: Rebuild.
7433 * configure.ac: Don't check for stdlib.h.
7434 * gdbreplay.c: Unconditionally include stdlib.h.
7435
7436 2013-11-18 Tom Tromey <tromey@redhat.com>
7437
7438 * config.in: Rebuild.
7439 * configure: Rebuild.
7440 * configure.ac: Don't use AC_HEADER_DIRENT.
7441
7442 2013-11-18 Tom Tromey <tromey@redhat.com>
7443
7444 * server.h: Don't check HAVE_STRING_H.
7445 * gdbreplay.c: Don't check HAVE_STRING_H.
7446 * configure: Rebuild.
7447
7448 2013-11-18 Tom Tromey <tromey@redhat.com>
7449
7450 * Makefile.in (gdbreplay$(EXEEXT)): Depend on and link against
7451 LIBGNU.
7452
7453 2013-11-08 Tom Tromey <tromey@redhat.com>
7454
7455 * configure, config.in: Rebuild.
7456 * configure.ac: Remove unused configury.
7457
7458 2013-11-08 Tom Tromey <tromey@redhat.com>
7459
7460 * acinclude.m4: Include common.m4, codeset.m4.
7461 * configure, config.in: Rebuild.
7462 * configure.ac: Use GDB_AC_COMMON.
7463
7464 2013-11-06 Andreas Arnez <arnez@linux.vnet.ibm.com>
7465
7466 * linux-s390-low.c (HWCAP_S390_TE): New define.
7467 (s390_arch_setup): Consider the TE field in the HWCAP for
7468 determining 'have_regset_tdb'.
7469
7470 2013-10-16 Sergio Durigan Junior <sergiodj@redhat.com>
7471
7472 PR gdb/16014
7473 * tracepoint.c (download_tracepoint_1): Remove unnecessary double
7474 call to sizeof.
7475
7476 2013-10-02 Pedro Alves <palves@redhat.com>
7477
7478 * server.c (process_serial_event): Don't output "GDBserver
7479 exiting" if GDB is connected through stdio.
7480 * target.c (mywait): Likewise, be silent if GDB is connected
7481 through stdio.
7482
7483 2013-10-01 Joel Brobecker <brobecker@adacore.com>
7484
7485 * lynx-low.c (lynx_add_threads_after_attach): New function.
7486 (lynx_attach): Remove call to add_thread. Add call to
7487 lynx_add_threads_after_attach instead.
7488
7489 2013-09-28 Mike Frysinger <vapier@gentoo.org>
7490
7491 * configure.ac (AC_CHECK_HEADERS): Add sys/syscall.h
7492 * config.in, configure: Regenerated.
7493
7494 2013-09-18 Yao Qi <yao@codesourcery.com>
7495
7496 PR server/15959
7497 * server.c (start_inferior): Clear 'resume_info'.
7498
7499 2013-09-16 Jiong Wang <jiwang@tilera.com>
7500
7501 * linux-tile-low.c (tile_regsets): Modify the size field to 64-bit
7502 for each register.
7503
7504 2013-09-16 Jiong Wang <jiwang@tilera.com>
7505
7506 * configure.srv <tilegx*-*-linux*>: Remove linux-osdata.o from and add
7507 linux-tile-low.o to srv_tgtobj.
7508
7509 2013-09-16 Will Newton <will.newton@linaro.org>
7510
7511 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Zero
7512 out regs.
7513
7514 2013-09-06 Pedro Alves <palves@redhat.com>
7515
7516 * Makefile.in (gdb_proc_service_h, regdef_h, regcache_h)
7517 (signals_def, signals_h, ptid_h, ax_h, agent_h, linux_btrace_h)
7518 (linux_osdata_h, vec_h, gdb_vecs_h, host_defs_h, libiberty_h)
7519 (server_h, gdbthread_h, linux_low_h, linux_ptrace_h)
7520 (gdb_thread_db_h, linux_procfs_h, lynx_low_h, nto_low_h)
7521 (mips_linux_watch_h, i386_low_h, win32_low_h): Delete.
7522
7523 2013-09-06 Pedro Alves <palves@redhat.com>
7524
7525 * Makefile.in (linux-btrace.o, mips-linux-watch.o): Remove
7526 explicit header dependencies and use $COMPILE/$POSTCOMPILE.
7527
7528 2013-09-06 Pedro Alves <palves@redhat.com>
7529
7530 * linux-amd64-ipa.c: Include tracepoint.h.
7531 * linux-i386-ipa.c: Include tracepoint.h.
7532
7533 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
7534
7535 * linux-crisv32-low.c (PTRACE_GET_THREAD_AREA): New macro.
7536 (ps_get_thread_area): New function.
7537
7538 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
7539
7540 * linux-crisv32-low.c (elf_gregset_t): Delete typedef.
7541 (initialize_low_arch): Call init_registers_crisv32 rather than
7542 init_register_crisv32.
7543
7544 2013-09-05 Pedro Alves <palves@redhat.com>
7545
7546 * server.h (handle_vFile, hostio_last_error_from_errno): Move
7547 to ...
7548 * hostio.h: ... this new file.
7549 * hostio.c, server.c, linux-low.c, nto-low.c, spu-low,
7550 win32-low.c: Include hostio.h.
7551
7552 2013-09-05 Pedro Alves <palves@redhat.com>
7553
7554 * server.h (gdb_client_data, handler_func, callback_handler_func)
7555 (delete_file_handler, add_file_handler, append_callback_event)
7556 (delete_callback_event, start_event_loop, initialize_event_loop):
7557 Move to event-loop.h and include it.
7558 * event-loop.h: New file.
7559
7560 2013-09-05 Pedro Alves <palves@redhat.com>
7561
7562 * dll.c, inferiors.c, remote-utils.c, server.c: Include "dll.h".
7563 * server.h (struct dll_info, all_dlls, dlls_changed, clear_dlls)
7564 (loaded_dll, unloaded_dll): Move to ...
7565 * dll.h: ... this new file.
7566 * inferiors.c, remote-utils.c, win32-low.c: Include "dll.h".
7567
7568 2013-09-05 Pedro Alves <palves@redhat.com>
7569
7570 * server.h (current_process, get_thread_process, all_processes)
7571 (add_inferior_to_list, for_each_inferior, current_inferior)
7572 (remove_inferior, add_process, remove_process, find_process_pid)
7573 (have_started_inferiors_p, have_attached_inferiors_p)
7574 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id)
7575 (clear_inferiors, find_inferior, find_inferior_id)
7576 (inferior_target_data, set_inferior_target_data)
7577 (inferior_regcache_data, set_inferior_regcache_data): Move to
7578 inferiors.h, and include it.
7579 * inferiors.h: New file.
7580
7581 2013-09-05 Pedro Alves <palves@redhat.com>
7582
7583 * server.h (struct emit_ops, current_insn_ptr, emit_error):
7584 Move ...
7585 * ax.h: ... here.
7586
7587 2013-09-05 Pedro Alves <palves@redhat.com>
7588
7589 * ax.c, linux-low.c, linux-x86-low.c, server.c: Include
7590 tracepoint.h.
7591 * server.h (IPA_BUFSIZ, initialize_tracepoint, tracing)
7592 (disconnected_tracing, tracepoint_look_up_symbols, stop_tracing
7593 (handle_tracepoint_general_set, handle_tracepoint_query)
7594 (tracepoint_finished_step, tracepoint_was_hit)
7595 (release_while_stepping_state_list, current_traceframe)
7596 (in_readonly_region, traceframe_read_mem)
7597 (fetch_traceframe_registers, traceframe_read_sdata)
7598 (traceframe_read_info, struct fast_tpoint_collect_status)
7599 (fast_tracepoint_collecting, force_unlock_trace_buffer)
7600 (handle_tracepoit_bkpts, initialize_low_tracepoint)
7601 (supply_fast_tracepoint_registers)
7602 (supply_static_tracepoint_registers, set_trampoline_buffer_space)
7603 (ipa_tdesc, claim_trampoline_space)
7604 (have_fast_tracepoint_trampoline_buffer, gdb_agent_about_to_close)
7605 (agent_mem_read, agent_get_trace_state_variable_value)
7606 (agent_set_trace_state_variable_value, agent_tsv_read)
7607 (agent_mem_read_string, get_raw_reg_func_addr)
7608 (get_get_tsv_func_addr, get_set_tsv_func_addr): Move to ...
7609 * tracepoint.h: ... this new file.
7610
7611 2013-09-05 Pedro Alves <palves@redhat.com>
7612
7613 * server.h (perror_with_name, error, fatal, warning, paddress)
7614 (pulongest, plongest, phex_nz, pfildes): Move to utils.h, and
7615 include it.
7616 * utils.h: New file.
7617
7618 2013-09-05 Pedro Alves <palves@redhat.com>
7619
7620 * server.h (remote_debug, noack_mode, transport_is_reliable)
7621 (gdb_connected, STDIO_CONNECTION_NAME, remote_connection_is_stdio)
7622 (read_ptid, write_ptid, putpkt, putpkt_binary, putpkt_notif)
7623 (getpkt, remote_prepare, remote_open, remote_close, write_ok)
7624 (write_enn, initialize_async_io, enable_async_io)
7625 (disable_async_io, check_remote_input_interrupt_request)
7626 (convert_ascii_to_int, convert_int_to_ascii, new_thread_notify)
7627 (dead_thread_notify, prepare_resume_reply)
7628 (decode_address_to_semicolon, decode_address, decode_m_packet)
7629 (decode_M_packet, decode_X_packet, decode_xfer_write)
7630 (decode_search_memory_packet, unhexify, hexify)
7631 (remote_escape_output, unpack_varlen_hex, clear_symbol_cache)
7632 (look_up_one_symbol, relocate_instruction)
7633 (monitor_output): Move to remote-utils.h, and include it.
7634 * remote-utils.h: New file.
7635
7636 2013-09-05 Pedro Alves <palves@redhat.com>
7637
7638 * server.h (_): Delete.
7639
7640 2013-09-02 Pedro Alves <palves@redhat.com>
7641
7642 * tracepoint.c (TRACEFRAME_EOB_MARKER_SIZE): New macro.
7643 (init_trace_buffer): Ensure at least TRACEFRAME_EOB_MARKER_SIZE is
7644 allocated.
7645 (trace_buffer_alloc): Use TRACEFRAME_EOB_MARKER_SIZE.
7646
7647 2013-09-02 Pierre Muller <muller@sourceware.org>
7648
7649 * win32-low.c (child_xfer_memory): Check if ReadProcessMemory
7650 or WriteProcessMemory complete successfully and handle
7651 ERROR_PARTIAL_COPY error.
7652
7653 2013-09-02 Pedro Alves <palves@redhat.com>
7654
7655 * server.c (gdb_read_memory): Return -1 on traceframe memory read
7656 error instead of EIO.
7657
7658 2013-08-28 Jan Kratochvil <jan.kratochvil@redhat.com>
7659
7660 PR server/15604
7661 * linux-low.c: Include filestuff.h.
7662 (linux_create_inferior) <pid == 0>: Call close_most_fds.
7663 * lynx-low.c: Include filestuff.h.
7664 (lynx_create_inferior) <pid == 0>: Call close_most_fds.
7665 * server.c: Include filestuff.h.
7666 (main): Call notice_open_fds.
7667 * spu-low.c: Include filestuff.h.
7668 (spu_create_inferior) <pid == 0>: Call close_most_fds.
7669
7670 2013-08-22 Luis Machado <lgustavo@codesourcery.com>
7671
7672 * Makefile.in: Explain why ../target and ../nat are not
7673 listed as include file search paths.
7674 (linux-waitpid.o): New object file rule.
7675 * configure.srv (srv_native_linux_obj): New variable.
7676 Replace all occurrences of linux native object files with
7677 $srv_native_linux_obj.
7678 * linux-low.c: Include nat/linux-nat.h and nat/linux-waitpid.h.
7679 (HAS_NOMMU): Move defining logic to common/linux-ptrace.c.
7680 (linux_enable_event_reporting): Remove declaration.
7681 (my_waitpid): Moved to common/linux-waitpid.c.
7682 (linux_wait_for_event): Pass ptid when calling
7683 linux_enable_event_reporting.
7684 (linux_supports_tracefork_flag): Remove.
7685 (linux_enable_event_reporting): Likewise.
7686 (linux_tracefork_grandchild): Remove.
7687 (STACK_SIZE): Moved to common/linux-ptrace.c.
7688 (linux_tracefork_child): Remove.
7689 (linux_test_for_tracefork): Remove.
7690 (linux_look_up_symbols): Call linux_supports_traceclone.
7691 (initialize_low): Remove call to linux_test_for_tracefork.
7692 * linux-low.h (PTRACE_TYPE_ARG3): Move to
7693 common/linux-ptrace.h.
7694 (PTRACE_TYPE_ARG4): Likewise.
7695 Include linux-ptrace.h.
7696
7697 2013-08-21 Pedro Alves <palves@redhat.com>
7698
7699 * config.in: Renegerate.
7700
7701 2013-08-19 Luis Machado <lgustavo@codesourcery.com>
7702
7703 * Makefile.in (INCLUDE_CFLAGS): Include -I$(srcdir)/../.
7704 (SFILES): Remove $(srcdir)/common/target-common.c and
7705 add $(srcdir)/target/waitstatus.c.
7706 (OBS): Remove target-common.o and add waitstatus.o.
7707 (server_h): Remove $(srcdir)/../common/target-common.h and
7708 add $(srcdir)/../target/resume.h, $(srcdir)/../target/wait.h
7709 and $(srcdir)/../target/waitstatus.h.
7710 (target-common.o): Remove.
7711 (waitstatus.o): New target object file.
7712 * target.h: Do not include target-common.h and
7713 include target/resume.h, target/wait.h and
7714 target/waitstatus.h.
7715
7716 2013-08-13 Luis Machado <lgustavo@codesourcery.com>
7717
7718 * linux-arm-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
7719 to PTRACE_TYPE_ARG3.
7720 * linux-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
7721 to PTRACE_TYPE_ARG3 and PTRACE_ARG4_TYPE to
7722 PTRACE_TYPE_ARG4.
7723 * linux-low.h (PTRACE_ARG3_TYPE): Rename to PTRACE_TYPE_ARG3.
7724 (PTRACE_ARG4_TYPE): Rename to PTRACE_TYPE_ARG4.
7725
7726 2013-07-27 Jie Zhang <jie@codesourcery.com>
7727 Daniel Jacobowitz <dan@codesourcery.com>
7728 Yao Qi <yao@codesourcery.com>
7729
7730 * Makefile.in (SFILES): Add common/mips-linux-watch.c.
7731 (mips-linux-watch.o): New rule.
7732 (mips_linux_watch_h): New variable.
7733 * configure.srv <mips*-*-linux*>: Add mips-linux-watch.o to
7734 srv_tgtobj.
7735 * linux-mips-low.c: Include mips-linux-watch.h.
7736 (struct arch_process_info, struct arch_lwp_info): New.
7737 (update_watch_registers_callback): New function.
7738 (mips_linux_new_process, mips_linux_new_thread) New functions.
7739 (mips_linux_prepare_to_resume, mips_insert_point): New
7740 functions.
7741 (mips_remove_point, mips_stopped_by_watchpoint): New
7742 functions.
7743 (rsp_bp_type_to_target_hw_bp_type): New function.
7744 (mips_stopped_data_address): New function.
7745 (the_low_target): Add watchpoint support functions.
7746
7747 2013-07-27 Yao Qi <yao@codesourcery.com>
7748
7749 * i386-low.c: Include break-common.h.
7750 (enum target_hw_bp_type): Remove.
7751
7752 2013-07-24 Luis Machado <lgustavo@codesourcery.com>
7753
7754 * Makefile.in (SFILES): /common/target-common.c.
7755 (OBS): Add target-common.o.
7756 (server_h): Add $(srcdir)/../common/target-common.h.
7757 (target-common.o): New target.
7758 * server.c (queue_stop_reply_callback): Free
7759 status string after use.
7760 * target.c (target_waitstatus_to_string): Remove.
7761 * target.h: Include target-common.h.
7762 (resume_kind): Likewise.
7763 (target_waitkind): Likewise.
7764 (target_waitstatus): Likewise.
7765 (TARGET_WNOHANG): Likewise.
7766
7767 2013-07-04 Yao Qi <yao@codesourcery.com>
7768
7769 * Makefile.in (host_alias): Use @host_noncanonical@.
7770 (target_alias): Use @target_noncanonical@.
7771 * configure.ac: Use ACX_NONCANONICAL_TARGET and
7772 ACX_NONCANONICAL_HOST.
7773 * configure: Regenerated.
7774
7775 Revert:
7776 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
7777
7778 * configure.ac (version_host, version_target): Set and AC_SUBST them.
7779 * configure: Rebuild.
7780 * Makefile.in (version_host, version_target): Get from configure.
7781 (version.c): Use $(version_host) and $(version_target).
7782
7783 2013-07-03 Pedro Alves <palves@redhat.com>
7784
7785 * Makefile.in (config.status): Depend on development.sh.
7786 * acinclude.m4: Include libmcheck.m4.
7787 * configure: Regenerate.
7788
7789 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
7790
7791 * win32-low.c (winapi_DebugActiveProcessStop): Move the WINAPI
7792 attribute inside the parentheses.
7793 (winapi_DebugSetProcessKillOnExit): Ditto.
7794 (winapi_DebugBreakProcess): Ditto.
7795 (winapi_GenerateConsoleCtrlEvent): Ditto.
7796
7797 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
7798
7799 * notif.h (notif_event): Add a dummy member to avoid compiler
7800 errors.
7801
7802 2013-07-01 Pedro Alves <palves@redhat.com>
7803
7804 * hostio.c (HOSTIO_PATH_MAX): Define.
7805 (require_filename, handle_open, handle_unlink, handle_readlink):
7806 Use it.
7807
7808 2013-07-01 Pedro Alves <palves@redhat.com>
7809
7810 * server.h: Include "pathmax.h".
7811 * linux-low.c: Don't include sys/param.h.
7812 (linux_pid_exe_is_elf_64_file): Use PATH_MAX instead of
7813 MAXPATHLEN.
7814 * win32-low.c: Don't include sys/param.h.
7815 (win32_create_inferior): Use PATH_MAX instead of MAXPATHLEN.
7816
7817 2013-07-01 Pedro Alves <palves@redhat.com>
7818
7819 * event-loop.c: Don't check HAVE_UNISTD_H before including
7820 <unistd.h>.
7821 * gdbreplay.c: Likewise.
7822 * remote-utils.c: Likewise.
7823 * server.c: Likewise.
7824 * configure.ac: Don't check for unistd.h.
7825 * configure: Regenerate.
7826
7827 2013-06-28 Tom Tromey <tromey@redhat.com>
7828
7829 * Makefile.in (version.c): Use version.in, not
7830 common/version.in.
7831
7832 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
7833
7834 * configure.ac (version_host, version_target): Set and AC_SUBST them.
7835 * configure: Rebuild.
7836 * Makefile.in (version_host, version_target): Get from configure.
7837 (version.c): Use $(version_host) and $(version_target).
7838
7839 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
7840
7841 Fix trace-status to output user name without trailing colon.
7842 * tracepoint.c (cmd_qtstatus): Remove unnecessary colon from user name.
7843
7844 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
7845
7846 Fix trace-status to output proper start-time and stop-time.
7847 * tracepoint.c (cmd_qtstatus): Modify trace-status output to
7848 output start time and stop time in hex as gdb expects.
7849
7850 2013-06-26 Pedro Alves <pedro@codesourcery.com>
7851
7852 * tracepoint.c (build_traceframe_info_xml): Output trace state
7853 variables present in the trace buffer.
7854
7855 2013-06-24 Tom Tromey <tromey@redhat.com>
7856
7857 * Makefile.in (version.c): Use bfd/version.h, common/version.in,
7858 create-version.sh.
7859 (version.o): Remove.
7860 * gdbreplay.c: Include version.h.
7861 (version, host_name): Don't declare.
7862 * server.h: Include version.h.
7863 (version, host_name): Don't declare.
7864
7865 2013-06-12 Pedro Alves <palves@redhat.com>
7866
7867 * linux-x86-low.c (linux_is_elf64): Delete global.
7868 (x86_siginfo_fixup): Replace reference to `linux_is_elf64' global
7869 with local linux_pid_exe_is_elf_64_file use.
7870
7871 2013-06-11 Pedro Alves <palves@redhat.com>
7872
7873 * linux-low.c (regset_disabled, disable_regset): New functions.
7874 (regsets_fetch_inferior_registers)
7875 (regsets_store_inferior_registers): Use them.
7876 (initialize_regsets_info); Don't allocate the disabled_regsets
7877 array here.
7878 * linux-low.h (struct regsets_info) <disabled_regsets>: Extend
7879 comment.
7880
7881 2013-06-11 Pedro Alves <palves@redhat.com>
7882
7883 * linux-low.c (initialize_regsets_info): Use xcalloc instead of
7884 xmalloc.
7885
7886 2013-06-11 Pedro Alves <palves@redhat.com>
7887
7888 * linux-x86-low.c (initialize_low_arch): Call
7889 init_registers_x32_avx_linux.
7890
7891 2013-06-09 Jan Kratochvil <jan.kratochvil@redhat.com>
7892
7893 Fix compatibility with Android Bionic.
7894 * linux-low.c (linux_qxfer_libraries_svr4): Ignore first entry even if
7895 it is not empty.
7896
7897 2013-06-07 Pedro Alves <palves@redhat.com>
7898
7899 PR server/14823
7900 * Makefile.in (OBS): Add tdesc.o.
7901 (IPA_OBJS): Add tdesc-ipa.o.
7902 (tdesc-ipa.o): New rule.
7903 * ax.c (gdb_eval_agent_expr): Adjust register_size call to new
7904 interface.
7905 * linux-low.c (new_inferior): Delete.
7906 (disabled_regsets, num_regsets): Delete.
7907 (linux_add_process): Adjust to set the new per-process
7908 new_inferior flag.
7909 (linux_detach_one_lwp): Adjust to call regcache_invalidate_thread.
7910 (linux_wait_for_lwp): Adjust. Only call arch_setup if the event
7911 was a stop. When calling arch_setup, switch the current inferior
7912 to the thread that got an event.
7913 (linux_resume_one_lwp): Adjust to call regcache_invalidate_thread.
7914 (regsets_fetch_inferior_registers)
7915 (regsets_store_inferior_registers): New regsets_info parameter.
7916 Adjust to use it.
7917 (linux_register_in_regsets): New regs_info parameter. Adjust to
7918 use it.
7919 (register_addr, fetch_register, store_register): New usrregs_info
7920 parameter. Adjust to use it.
7921 (usr_fetch_inferior_registers, usr_store_inferior_registers): New
7922 parameter regs_info. Adjust to use it.
7923 (linux_fetch_registers): Get the current inferior's regs_info, and
7924 adjust to use it.
7925 (linux_store_registers): Ditto.
7926 [HAVE_LINUX_REGSETS] (initialize_regsets_info): New.
7927 (initialize_low): Don't initialize the target_regsets here. Call
7928 initialize_low_arch.
7929 * linux-low.h (target_regsets): Delete declaration.
7930 (struct regsets_info): New.
7931 (struct usrregs_info): New.
7932 (struct regs_info): New.
7933 (struct process_info_private) <new_inferior>: New field.
7934 (struct linux_target_ops): Delete the num_regs, regmap, and
7935 regset_bitmap fields. New field regs_info.
7936 [HAVE_LINUX_REGSETS] (initialize_regsets_info): Declare.
7937 * i387-fp.c (num_xmm_registers): Delete.
7938 (i387_cache_to_fsave, i387_fsave_to_cache): Adjust find_regno
7939 calls to new interface.
7940 (i387_cache_to_fxsave, i387_cache_to_xsave, i387_fxsave_to_cache)
7941 (i387_xsave_to_cache): Adjust find_regno calls to new interface.
7942 Infer the number of xmm registers from the regcache's target
7943 description.
7944 * i387-fp.h (num_xmm_registers): Delete.
7945 * inferiors.c (add_thread): Don't install the thread's regcache
7946 here.
7947 * proc-service.c (gregset_info): Fetch the current inferior's
7948 regs_info. Adjust to use it.
7949 * regcache.c: Include tdesc.h.
7950 (register_bytes, reg_defs, num_registers)
7951 (gdbserver_expedite_regs): Delete.
7952 (get_thread_regcache): If the thread doesn't have a regcache yet,
7953 create one, instead of aborting gdbserver.
7954 (regcache_invalidate_one): Rename to ...
7955 (regcache_invalidate_thread): ... this.
7956 (regcache_invalidate_one): New.
7957 (regcache_invalidate): Only invalidate registers of the current
7958 process.
7959 (init_register_cache): Add target_desc parameter, and use it.
7960 (new_register_cache): Ditto. Assert the target description has a
7961 non zero registers_size.
7962 (regcache_cpy): Add assertions. Adjust.
7963 (realloc_register_cache, set_register_cache): Delete.
7964 (registers_to_string, registers_from_string): Adjust.
7965 (find_register_by_name, find_regno, find_register_by_number)
7966 (register_cache_size): Add target_desc parameter, and use it.
7967 (free_register_cache_thread, free_register_cache_thread_one)
7968 (regcache_release, register_cache_size): New.
7969 (register_size): Add target_desc parameter, and use it.
7970 (register_data, supply_register, supply_register_zeroed)
7971 (supply_regblock, supply_register_by_name, collect_register)
7972 (collect_register_as_string, collect_register_by_name): Adjust.
7973 * regcache.h (struct target_desc): Forward declare.
7974 (struct regcache) <tdesc>: New field.
7975 (init_register_cache, new_register_cache): Add target_desc
7976 parameter.
7977 (regcache_invalidate_thread): Declare.
7978 (regcache_invalidate_one): Delete declaration.
7979 (regcache_release): Declare.
7980 (find_register_by_number, register_cache_size, register_size)
7981 (find_regno): Add target_desc parameter.
7982 (gdbserver_expedite_regs, gdbserver_xmltarget): Delete
7983 declarations.
7984 * remote-utils.c: Include tdesc.h.
7985 (outreg, prepare_resume_reply): Adjust.
7986 * server.c: Include tdesc.h.
7987 (gdbserver_xmltarget): Delete declaration.
7988 (get_features_xml, process_serial_event): Adjust.
7989 * server.h [IN_PROCESS_AGENT] (struct target_desc): Forward
7990 declare.
7991 (struct process_info) <tdesc>: New field.
7992 (ipa_tdesc): Declare.
7993 * tdesc.c: New file.
7994 * tdesc.h: New file.
7995 * tracepoint.c: Include tdesc.h.
7996 [IN_PROCESS_AGENT] (ipa_tdesc): Define.
7997 (get_context_regcache): Adjust to pass ipa_tdesc down.
7998 (do_action_at_tracepoint): Adjust to get the register cache size
7999 from the context regcache's description.
8000 (traceframe_walk_blocks): Adjust to get the register cache size
8001 from the current trace frame's description.
8002 (traceframe_get_pc): Adjust to get current trace frame's
8003 description and pass it down.
8004 (gdb_collect): Adjust to get the register cache size from the
8005 IPA's description.
8006 * linux-amd64-ipa.c (tdesc_amd64_linux): Declare.
8007 (gdbserver_xmltarget): Delete.
8008 (initialize_low_tracepoint): Set the ipa's target description.
8009 * linux-i386-ipa.c (tdesc_i386_linux): Declare.
8010 (initialize_low_tracepoint): Set the ipa's target description.
8011 * linux-x86-low.c: Include tdesc.h.
8012 [__x86_64__] (is_64bit_tdesc): New.
8013 (ps_get_thread_area, x86_get_thread_area): Use it.
8014 (i386_cannot_store_register): Rename to ...
8015 (x86_cannot_store_register): ... this. Use is_64bit_tdesc.
8016 (i386_cannot_fetch_register): Rename to ...
8017 (x86_cannot_fetch_register): ... this. Use is_64bit_tdesc.
8018 (x86_fill_gregset, x86_store_gregset): Adjust register_size calls
8019 to new interface.
8020 (target_regsets): Rename to ...
8021 (x86_regsets): ... this.
8022 (x86_get_pc, x86_set_pc): Adjust register_size calls to new
8023 interface.
8024 (x86_siginfo_fixup): Use is_64bit_tdesc.
8025 [__x86_64__] (tdesc_amd64_linux, tdesc_amd64_avx_linux)
8026 (tdesc_x32_avx_linux, tdesc_x32_linux)
8027 (tdesc_i386_linux, tdesc_i386_mmx_linux, tdesc_i386_avx_linux):
8028 Declare.
8029 (x86_linux_update_xmltarget): Delete.
8030 (I386_LINUX_XSAVE_XCR0_OFFSET): Define.
8031 (have_ptrace_getfpxregs, have_ptrace_getregset): New.
8032 (AMD64_LINUX_USER64_CS): New.
8033 (x86_linux_read_description): New, based on
8034 x86_linux_update_xmltarget.
8035 (same_process_callback): New.
8036 (x86_arch_setup_process_callback): New.
8037 (x86_linux_update_xmltarget): New.
8038 (x86_regsets_info): New.
8039 (amd64_linux_regs_info): New.
8040 (i386_linux_usrregs_info): New.
8041 (i386_linux_regs_info): New.
8042 (x86_linux_regs_info): New.
8043 (x86_arch_setup): Reimplement.
8044 (x86_install_fast_tracepoint_jump_pad): Use is_64bit_tdesc.
8045 (x86_emit_ops): Ditto.
8046 (the_low_target): Adjust. Install x86_linux_regs_info,
8047 x86_cannot_fetch_register, and x86_cannot_store_register.
8048 (initialize_low_arch): New.
8049 * linux-ia64-low.c (tdesc_ia64): Declare.
8050 (ia64_fetch_register): Adjust.
8051 (ia64_usrregs_info, regs_info): New globals.
8052 (ia64_regs_info): New function.
8053 (the_low_target): Adjust.
8054 (initialize_low_arch): New function.
8055 * linux-sparc-low.c (tdesc_sparc64): Declare.
8056 (sparc_fill_gregset_to_stack, sparc_store_gregset_from_stack):
8057 Adjust.
8058 (sparc_arch_setup): New function.
8059 (sparc_regsets_info, sparc_usrregs_info, regs_info): New globals.
8060 (the_low_target): Adjust.
8061 (initialize_low_arch): New function.
8062 * linux-ppc-low.c (tdesc_powerpc_32l, tdesc_powerpc_altivec32l)
8063 (tdesc_powerpc_cell32l, tdesc_powerpc_vsx32l)
8064 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_altivec32l)
8065 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_e500l)
8066 (tdesc_powerpc_64l, tdesc_powerpc_altivec64l)
8067 (tdesc_powerpc_cell64l, tdesc_powerpc_vsx64l)
8068 (tdesc_powerpc_isa205_64l, tdesc_powerpc_isa205_altivec64l)
8069 (tdesc_powerpc_isa205_vsx64l): Declare.
8070 (ppc_cannot_store_register, ppc_collect_ptrace_register)
8071 (ppc_supply_ptrace_register, parse_spufs_run, ppc_get_pc)
8072 (ppc_set_pc, ppc_get_hwcap): Adjust.
8073 (ppc_usrregs_info): Forward declare.
8074 (!__powerpc64__) ppc_regmap_adjusted: New global.
8075 (ppc_arch_setup): Adjust to the current process'es target
8076 description.
8077 (ppc_fill_vsxregset, ppc_store_vsxregset, ppc_fill_vrregset)
8078 (ppc_store_vrregset, ppc_fill_evrregset, ppc_store_evrregse)
8079 (ppc_store_evrregset): Adjust.
8080 (target_regsets): Rename to ...
8081 (ppc_regsets): ... this, and make static.
8082 (ppc_usrregs_info, ppc_regsets_info, regs_info): New globals.
8083 (ppc_regs_info): New function.
8084 (the_low_target): Adjust.
8085 (initialize_low_arch): New function.
8086 * linux-s390-low.c (tdesc_s390_linux32, tdesc_s390_linux32v1)
8087 (tdesc_s390_linux32v2, tdesc_s390_linux64, tdesc_s390_linux64v1)
8088 (tdesc_s390_linux64v2, tdesc_s390x_linux64, tdesc_s390x_linux64v1)
8089 (tdesc_s390x_linux64v2): Declare.
8090 (s390_collect_ptrace_register, s390_supply_ptrace_register)
8091 (s390_fill_gregset, s390_store_last_break): Adjust.
8092 (target_regsets): Rename to ...
8093 (s390_regsets): ... this, and make static.
8094 (s390_get_pc, s390_set_pc): Adjust.
8095 (s390_get_hwcap): New target_desc parameter, and use it.
8096 [__s390x__] (have_hwcap_s390_high_gprs): New global.
8097 (s390_arch_setup): Adjust to set the current process'es target
8098 description. Don't adjust the regmap.
8099 (s390_usrregs_info, s390_regsets_info, regs_info): New globals.
8100 [__s390x__] (s390_usrregs_info_3264, s390_regsets_info_3264)
8101 (regs_info_3264): New globals.
8102 (s390_regs_info): New function.
8103 (the_low_target): Adjust.
8104 (initialize_low_arch): New function.
8105 * linux-mips-low.c (tdesc_mips_linux, tdesc_mips_dsp_linux)
8106 (tdesc_mips64_linux, tdesc_mips64_dsp_linux): Declare.
8107 [__mips64] (init_registers_mips_linux)
8108 (init_registers_mips_dsp_linux): Delete defines.
8109 [__mips64] (tdesc_mips_linux, tdesc_mips_dsp_linux): New defines.
8110 (have_dsp): New global.
8111 (mips_read_description): New, based on mips_arch_setup.
8112 (mips_arch_setup): Reimplement.
8113 (get_usrregs_info): New function.
8114 (mips_cannot_fetch_register, mips_cannot_store_register)
8115 (mips_get_pc, mips_set_pc, mips_fill_gregset, mips_store_gregset)
8116 (mips_fill_fpregset, mips_store_fpregset): Adjust.
8117 (target_regsets): Rename to ...
8118 (mips_regsets): ... this, and make static.
8119 (mips_regsets_info, mips_dsp_usrregs_info, mips_usrregs_info)
8120 (dsp_regs_info, regs_info): New globals.
8121 (mips_regs_info): New function.
8122 (the_low_target): Adjust.
8123 (initialize_low_arch): New function.
8124 * linux-arm-low.c (tdesc_arm, tdesc_arm_with_iwmmxt)
8125 (tdesc_arm_with_vfpv2, tdesc_arm_with_vfpv3, tdesc_arm_with_neon):
8126 Declare.
8127 (arm_fill_vfpregset, arm_store_vfpregset): Adjust.
8128 (arm_read_description): New, with bits factored from
8129 arm_arch_setup.
8130 (arm_arch_setup): Reimplement.
8131 (target_regsets): Rename to ...
8132 (arm_regsets): ... this, and make static.
8133 (arm_regsets_info, arm_usrregs_info, regs_info): New globals.
8134 (arm_regs_info): New function.
8135 (the_low_target): Adjust.
8136 (initialize_low_arch): New function.
8137 * linux-m68k-low.c (tdesc_m68k): Declare.
8138 (target_regsets): Rename to ...
8139 (m68k_regsets): ... this, and make static.
8140 (m68k_regsets_info, m68k_usrregs_info, regs_info): New globals.
8141 (m68k_regs_info): New function.
8142 (m68k_arch_setup): New function.
8143 (the_low_target): Adjust.
8144 (initialize_low_arch): New function.
8145 * linux-sh-low.c (tdesc_sharch): Declare.
8146 (target_regsets): Rename to ...
8147 (sh_regsets): ... this, and make static.
8148 (sh_regsets_info, sh_usrregs_info, regs_info): New globals.
8149 (sh_regs_info, sh_arch_setup): New functions.
8150 (the_low_target): Adjust.
8151 (initialize_low_arch): New function.
8152 * linux-bfin-low.c (tdesc_bfin): Declare.
8153 (bfin_arch_setup): New function.
8154 (bfin_usrregs_info, regs_info): New globals.
8155 (bfin_regs_info): New function.
8156 (the_low_target): Adjust.
8157 (initialize_low_arch): New function.
8158 * linux-cris-low.c (tdesc_cris): Declare.
8159 (cris_arch_setup): New function.
8160 (cris_usrregs_info, regs_info): New globals.
8161 (cris_regs_info): New function.
8162 (the_low_target): Adjust.
8163 (initialize_low_arch): New function.
8164 * linux-cris-low.c (tdesc_crisv32): Declare.
8165 (cris_arch_setup): New function.
8166 (cris_regsets_info, cris_usrregs_info, regs_info): New globals.
8167 (cris_regs_info): New function.
8168 (the_low_target): Adjust.
8169 (initialize_low_arch): New function.
8170 * linux-m32r-low.c (tdesc_m32r): Declare.
8171 (m32r_arch_setup): New function.
8172 (m32r_usrregs_info, regs_info): New globals.
8173 (m32r_regs_info): Adjust.
8174 (initialize_low_arch): New function.
8175 * linux-tic6x-low.c (tdesc_tic6x_c64xp_linux)
8176 (tdesc_tic6x_c64x_linux, tdesc_tic6x_c62x_linux): Declare.
8177 (tic6x_usrregs_info): Forward declare.
8178 (tic6x_read_description): New function, based on ...
8179 (tic6x_arch_setup): ... this. Reimplement.
8180 (target_regsets): Rename to ...
8181 (tic6x_regsets): ... this, and make static.
8182 (tic6x_regsets_info, tic6x_usrregs_info, regs_info): New globals.
8183 (tic6x_regs_info): New function.
8184 (the_low_target): Adjust.
8185 (initialize_low_arch): New function.
8186 * linux-xtensa-low.c (tdesc_xtensa): Declare.
8187 (xtensa_fill_gregset, xtensa_store_gregset): Adjust.
8188 (target_regsets): Rename to ...
8189 (xtensa_regsets): ... this, and make static.
8190 (xtensa_regsets_info, xtensa_usrregs_info, regs_info): New
8191 globals.
8192 (xtensa_arch_setup, xtensa_regs_info): New functions.
8193 (the_low_target): Adjust.
8194 (initialize_low_arch): New function.
8195 * linux-nios2-low.c (tdesc_nios2_linux): Declare.
8196 (nios2_arch_setup): Set the current process'es tdesc.
8197 (target_regsets): Rename to ...
8198 (nios2_regsets): ... this.
8199 (nios2_regsets_info, nios2_usrregs_info, regs_info): New globals.
8200 (nios2_regs_info): New function.
8201 (the_low_target): Adjust.
8202 (initialize_low_arch): New function.
8203 * linux-aarch64-low.c (tdesc_aarch64): Declare.
8204 (aarch64_arch_setup): Set the current process'es tdesc.
8205 (target_regsets): Rename to ...
8206 (aarch64_regsets): ... this.
8207 (aarch64_regsets_info, aarch64_usrregs_info, regs_info): New globals.
8208 (aarch64_regs_info): New function.
8209 (the_low_target): Adjust.
8210 (initialize_low_arch): New function.
8211 * linux-tile-low.c (tdesc_tilegx, tdesc_tilegx32): Declare
8212 globals.
8213 (target_regsets): Rename to ...
8214 (tile_regsets): ... this.
8215 (tile_regsets_info, tile_usrregs_info, regs_info): New globals.
8216 (tile_regs_info): New function.
8217 (tile_arch_setup): Set the current process'es tdesc.
8218 (the_low_target): Adjust.
8219 (initialize_low_arch): New function.
8220 * spu-low.c (tdesc_spu): Declare.
8221 (spu_create_inferior, spu_attach): Set the new process'es tdesc.
8222 * win32-arm-low.c (tdesc_arm): Declare.
8223 (arm_arch_setup): New function.
8224 (the_low_target): Install arm_arch_setup instead of
8225 init_registers_arm.
8226 * win32-i386-low.c (tdesc_i386, tdesc_amd64): Declare.
8227 (init_windows_x86): Rename to ...
8228 (i386_arch_setup): ... this. Set `win32_tdesc'.
8229 (the_low_target): Adjust.
8230 * win32-low.c (win32_tdesc): New global.
8231 (child_add_thread): Don't create the thread cache here.
8232 (do_initial_child_stuff): Set the new process'es tdesc.
8233 * win32-low.h (struct target_desc): Forward declare.
8234 (win32_tdesc): Declare.
8235 * lynx-i386-low.c (tdesc_i386): Declare global.
8236 (lynx_i386_arch_setup): Set `lynx_tdesc'.
8237 * lynx-low.c (lynx_tdesc): New global.
8238 (lynx_add_process): Set the new process'es tdesc.
8239 * lynx-low.h (struct target_desc): Forward declare.
8240 (lynx_tdesc): Declare global.
8241 * lynx-ppc-low.c (tdesc_powerpc_32): Declare global.
8242 (lynx_ppc_arch_setup): Set `lynx_tdesc'.
8243 * nto-low.c (nto_tdesc): New global.
8244 (do_attach): Set the new process'es tdesc.
8245 * nto-low.h (struct target_desc): Forward declare.
8246 (nto_tdesc): Declare.
8247 * nto-x86-low.c (tdesc_i386): Declare.
8248 (nto_x86_arch_setup): Set `nto_tdesc'.
8249
8250 2013-06-04 Gary Benson <gbenson@redhat.com>
8251
8252 * server.c (handle_query): Add "augmented-libraries-svr4-read+"
8253 to qSupported response when appropriate.
8254 (handle_qxfer_libraries_svr4): Allow qXfer:libraries-svr4:read
8255 with nonzero-length annex.
8256 * linux-low.c (linux_qxfer_libraries_svr4): Parse and handle
8257 arguments supplied in annex.
8258
8259 2013-05-31 Doug Evans <dje@google.com>
8260
8261 PR server/15594
8262 * linux-x86-low.c (ps_get_thread_area): Properly extend address to
8263 64 bits in 64-cross-32 environment.
8264
8265 2013-05-28 Pedro Alves <palves@redhat.com>
8266
8267 * Makefile.in (clean): Remove reference to aarch64-without-fpu.c.
8268 (aarch64-without-fpu.c): Delete rule.
8269 * configure.srv (aarch64*-*-linux*): Remove references to
8270 aarch64-without-fpu.o and aarch64-without-fpu.xml.
8271 * linux-aarch64-low.c (init_registers_aarch64_without_fpu): Remove
8272 declaration.
8273
8274 2013-05-24 Pedro Alves <palves@redhat.com>
8275
8276 * server.c (handle_v_cont) <vCont;r>: Use unpack_varlen_hex
8277 instead of strchr/decode_address. Error if the range isn't split
8278 with a ','. Don't assume there's be a ':' in the action.
8279
8280 2013-05-23 Yao Qi <yao@codesourcery.com>
8281 Pedro Alves <palves@redhat.com>
8282
8283 * linux-low.c (lwp_in_step_range): New function.
8284 (linux_wait_1): If the thread was range stepping and stopped
8285 outside the stepping range, report the stop to GDB. Otherwise,
8286 continue stepping. Add range stepping debug output.
8287 (linux_set_resume_request): Copy the step range from the resume
8288 request to the lwp.
8289 (linux_supports_range_stepping): New.
8290 (linux_target_ops) <supports_range_stepping>: Set to
8291 linux_supports_range_stepping.
8292 * linux-low.h (struct linux_target_ops)
8293 <supports_range_stepping>: New field.
8294 (struct lwp_info) <step_range_start, step_range_end>: New fields.
8295 * linux-x86-low.c (x86_supports_range_stepping): New.
8296 (the_low_target) <supports_range_stepping>: Set to
8297 x86_supports_range_stepping.
8298 * server.c (handle_v_cont): Handle 'r' action.
8299 (handle_v_requests): Append ";r" if the target supports range
8300 stepping.
8301 * target.h (struct thread_resume) <step_range_start,
8302 step_range_end>: New fields.
8303 (struct target_ops) <supports_range_stepping>:
8304 New field.
8305 (target_supports_range_stepping): New macro.
8306
8307 2013-05-17 Joel Brobecker <brobecker@adacore.com>
8308
8309 * lynx-low.c (lynx_resume): Fix null_ptid/minus_one_ptid
8310 confusion in comment.
8311
8312 2013-05-17 Joel Brobecker <brobecker@adacore.com>
8313
8314 * lynx-low.c (struct process_info_private): New type.
8315 (lynx_add_process): New function.
8316 (lynx_create_inferior, lynx_attach): Replace calls to
8317 add_process by calls to lynx_add_process.
8318 (lynx_resume): If PTID is null, then try using
8319 current_process()->private->last_wait_event_ptid.
8320 Add comments.
8321 (lynx_clear_inferiors): Delete. The contents of that function
8322 has been inlined in lynx_mourn;
8323 (lynx_wait_1): Save the ptid in the process's private data.
8324 (lynx_mourn): Free the process' private data. Replace call
8325 to lynx_clear_inferiors by call to clear_inferiors.
8326
8327 2013-05-17 Yao Qi <yao@codesourcery.com>
8328
8329 * i386-low.c (i386_length_and_rw_bits): Move the comment to
8330 the right place.
8331
8332 2013-05-16 Luis Machado <lgustavo@codesourcery.com>
8333
8334 * linux-low.c: Move definition checks upwards for PT_TEXT_ADDR,
8335 PT_DATA_ADDR and PT_TEXT_END_ADDR. Update comments.
8336 (linux_read_offsets): Remove PT_TEXT_ADDR, PT_DATA_ADDR and
8337 PT_TEXT_END_ADDR guards. Update comments.
8338 (linux_target_op) <read_offsets>: Conditionally define to
8339 linux_read_offsets if the target is UCLIBC and if it defines
8340 PT_TEXT_ADDR, PT_DATA_ADDR and PT_TEXT_END_ADDR.
8341
8342 2013-05-06 Sandra Loosemore <sandra@codesourcery.com>
8343 Andrew Jenner <andrew@codesourcery.com>
8344
8345 * Makefile.in (SFILES): Add linux-nios2-low.c.
8346 (clean): Add action to delete nios2-linux.c.
8347 (nios2-linux.c): New rule.
8348 * configure.srv: Add nios2*-*-linux*.
8349 * linux-nios2-low.c: New.
8350
8351 2013-05-03 Hafiz Abid Qadeer <abidh@codesourcery.com>
8352
8353 * tracepoint.c (cmd_qtinit): Call 'stop_tracing'.
8354
8355 2013-04-25 Hui Zhu <hui@codesourcery.com>
8356
8357 PR gdb/15186
8358 * ax.c (ax_printf): Add fflush.
8359
8360 2013-04-22 Tom Tromey <tromey@redhat.com>
8361
8362 * Makefile.in (SFILES): Add filestuff.c.
8363 (OBS): Add filestuff.o.
8364 (filestuff.o): New target.
8365 * config.in, configure: Rebuild.
8366 * configure.ac: Check for fdwalk, pipe2.
8367
8368 2013-04-17 Pedro Alves <palves@redhat.com>
8369
8370 * configure.ac (USE_THREAD_DB): Delete variable.
8371 (if test "$srv_linux_thread_db" = "yes"): AC_DEFINE USE_THREAD_DB.
8372 Don't AC_SUBST USE_THREAD_DB.
8373 * Makefile.in (INTERNAL_CFLAGS): Remove @USE_THREAD_DB@.
8374 * config.in, configure: Regenerate.
8375
8376 2013-04-16 Pedro Alves <palves@redhat.com>
8377
8378 * linux-low.h (struct lwp_info) <thread_known>: Move under
8379 the USE_THREAD_DB #ifdef.
8380
8381 2013-04-16 Pedro Alves <palves@redhat.com>
8382
8383 * Makefile.in (INTERNAL_CFLAGS): Add @USE_THREAD_DB@.
8384 (linux-low.o): Delete rule.
8385 * linux-low.h: Always include "gdb_thread_db.h" instead of
8386 conditionally including thread_db.h.
8387 (struct lwp_info) <th>: Guard with #ifdef USE_THREAD_DB instead of
8388 HAVE_THREAD_DB_H.
8389
8390 2013-04-07 Jan Kratochvil <jan.kratochvil@redhat.com>
8391
8392 * Makefile.in (install-only): Fix make install regression.
8393
8394 2013-04-05 Jan Kratochvil <jan.kratochvil@redhat.com>
8395
8396 Convert man pages to texinfo, new gdbinit.5 texinfo page.
8397 * Makefile.in (install-only): Remove $(man1dir) and gdbserver.1
8398 installation.
8399 * gdbserver.1: Remove.
8400
8401 2013-03-22 Pedro Alves <palves@redhat.com>
8402
8403 * linux-low.c (handle_extended_wait): Don't call
8404 linux_enable_event_reporting.
8405
8406 2013-03-15 Tony Theodore <tonyt@logyst.com>
8407
8408 PR build/9098:
8409 * Makefile.in (SHELL): Use @SHELL@.
8410
8411 2013-03-14 Sergio Durigan Junior <sergiodj@redhat.com>
8412
8413 * tracepoint.c (cmd_qtv): Initialize `val' with zero, silencing
8414 compiler warning.
8415
8416 2013-03-13 Joel Brobecker <brobecker@adacore.com>
8417
8418 * linux-low.c (linux_target_ops) [!HAVE_LINUX_BTRACE]:
8419 Remove extraneous NULL element.
8420
8421 2013-03-13 Yao Qi <yao@codesourcery.com>
8422
8423 * tracepoint.c (traceframe_read_tsv): Look for the last matched
8424 'V' block in trace frame.
8425
8426 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
8427
8428 * target.h (struct target_ops): Add btrace ops.
8429 (target_supports_btrace): New macro.
8430 (target_enable_btrace): New macro.
8431 (target_disable_btrace): New macro.
8432 (target_read_btrace): New macro.
8433 * gdbthread.h (struct thread_info): Add btrace field.
8434 * server.c: Include btrace-common.h.
8435 (handle_btrace_general_set): New function.
8436 (handle_btrace_enable): New function.
8437 (handle_btrace_disable): New function.
8438 (handle_general_set): Call handle_btrace_general_set.
8439 (handle_qxfer_btrace): New function.
8440 (struct qxfer qxfer_packets[]): Add btrace entry.
8441 * inferiors.c (remove_thread): Disable btrace.
8442 * linux-low: Include linux-btrace.h.
8443 (linux_low_enable_btrace): New function.
8444 (linux_low_read_btrace): New function.
8445 (linux_target_ops): Add btrace ops.
8446 * configure.srv (i[34567]86-*-linux*): Add linux-btrace.o.
8447 Add srv_linux_btrace=yes.
8448 (x86_64-*-linux*): Add linux-btrace.o.
8449 Add srv_linux_btrace=yes.
8450 * configure.ac: Define HAVE_LINUX_BTRACE.
8451 * config.in: Regenerated.
8452 * configure: Regenerated.
8453
8454 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
8455
8456 * server.c (handle_qxfer): Preserve error message if -3 is
8457 returned.
8458 (qxfer): Document the -3 return value.
8459
8460 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
8461
8462 * Makefile.in (SFILES): Add $(srcdir)/common/linux-btrace.c.
8463 (linux_btrace_h): New variable.
8464 (linux-btrace.o): New rule.
8465
8466 2013-03-08 Stan Shebs <stan@codesourcery.com>
8467 Hafiz Abid Qadeer <abidh@codesourcery.com>
8468
8469 * tracepoint.c (trace_buffer_size): New global.
8470 (DEFAULT_TRACE_BUFFER_SIZE): New define.
8471 (init_trace_buffer): Change to one-argument function. Allocate
8472 trace buffer memory.
8473 (handle_tracepoint_general_set): Call cmd_bigqtbuffer_size to
8474 handle QTBuffer:size packet.
8475 (cmd_bigqtbuffer_size): New function.
8476 (initialize_tracepoint): Call init_trace_buffer with
8477 DEFAULT_TRACE_BUFFER_SIZE.
8478 * server.c (handle_query): Add QTBuffer:size in the
8479 supported packets.
8480
8481 2013-03-07 Yao Qi <yao@codesourcery.com>
8482
8483 * tracepoint.c (cur_action, cur_step_action): Make them unsigned.
8484 (cmd_qtfp): Initialize cur_action and cur_step_action 0 instead
8485 of -1.
8486 (cmd_qtsp): Adjust condition. Do post increment.
8487 Set cur_action and cur_step_action back to 0.
8488
8489 2013-03-07 Jeremy Bennett <jeremy.bennett@embecosm.com>
8490
8491 PR server/15236
8492 * linux-low.c (linux_write_memory): Return early success if LEN is
8493 zero.
8494
8495 2013-03-05 Corinna Vinschen <vinschen@redhat.de>
8496
8497 * configure.srv: Add x86_64-*-cygwin* as target.
8498
8499 2013-02-28 Tom Tromey <tromey@redhat.com>
8500
8501 * configure.ac: Invoke AC_SYS_LARGEFILE.
8502 * configure, config.in: Rebuild.
8503
8504 2013-02-28 Corinna Vinschen <vinschen@redhat.com>
8505
8506 * win32-low.c: Throughout, fix format strings and casts of
8507 printf-like functions to avoid type related warnings on all
8508 platforms.
8509 (get_child_debug_event): Print dwDebugEventCode as hex since
8510 that's how it's usually documented.
8511
8512 2013-02-28 Yao Qi <yao@codesourcery.com>
8513
8514 * tracepoint.c (cmd_qtbuffer): Call phex_nz instead of
8515 pulongest.
8516
8517 2013-02-27 Jiong Wang <jiwang@tilera.com>
8518
8519 * Makefile.in (clean): Remove reg-tilegx.c, reg-tilegx32.c.
8520 (reg-tilegx32.c): New rule.
8521 * configure.srv (tilegx-*-linux*): Add reg-tilegx32.o to srv_regobj.
8522 * linux-tile-low.c (tile_arch_setup): New function. Invoke
8523 different register info initializer according to elf class.
8524 (init_registers_tilgx32): New function. The tilegx32 register info
8525 initializer.
8526 (tile_fill_gregset): Use "uint_reg_t" to represent register size.
8527 (tile_store_gregset): Likewise.
8528
8529 2013-02-27 Yao Qi <yao@codesourcery.com>
8530
8531 * server.c (process_point_options): Print debug message when
8532 debug_threads is true.
8533
8534 2013-02-26 Yao Qi <yao@codesourcery.com>
8535
8536 * tracepoint.c (cmd_qtbuffer): Don't set '\0' in OWN_BUF.
8537
8538 2013-02-19 Pedro Alves <palves@redhat.com>
8539 Kai Tietz <ktietz@redhat.com>
8540
8541 PR gdb/15161
8542
8543 * server.c (handle_query) <CRC check>: Use unpack_varlen_hex
8544 instead of strtoul to extract address from packet.
8545 (process_serial_event) <'z'>: Likewise.
8546
8547 2013-02-18 Yao Qi <yao@codesourcery.com>
8548
8549 * linux-bfin-low.c (the_low_target): Use NULL instead of 0.
8550
8551 2013-02-14 Pedro Alves <palves@redhat.com>
8552
8553 Plug memory leak.
8554
8555 * tracepoint.c (cmd_qtnotes): Free TRACING_USER_NAME,
8556 TRACING_NOTES and TRACING_STOP_NOTE before clobbering.
8557
8558 2013-02-14 Pedro Alves <palves@redhat.com>
8559
8560 * tracepoint.c (cmd_qtdpsrc): Use savestring.
8561
8562 2013-02-14 Pedro Alves <palves@redhat.com>
8563
8564 * tracepoint.c (save_string): Delete.
8565 (add_tracepoint_action): Use savestring instead of save_string.
8566
8567 2013-02-12 Pedro Alves <palves@redhat.com>
8568
8569 * linux-xtensa-low.c: Ditto.
8570 * xtensa-xtregs.c: Ditto.
8571
8572 2013-02-12 Sanimir Agovic <sanimir.agovic@intel.com>
8573
8574 * thread-db.c (thread_db_get_tls_address): NULL pointer check
8575 thread_db.
8576
8577 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
8578
8579 * linux-aarch64-low.c (aarch64_arch_setup): Clamp
8580 aarch64_num_wp_regs and aarch64_num_bp_regs to
8581 AARCH64_HWP_MAX_NUM and AARCH64_HBP_MAX_NUM respectively.
8582
8583 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
8584
8585 * linux-aarch64-low.c (ps_get_thread_area): Replace
8586 PTRACE_GET_THREAD_AREA with PTRACE_GETREGSET.
8587
8588 2013-02-04 Jim MacArthur <jim.macarthur@arm.com>
8589 Marcus Shawcroft <marcus.shawcroft@arm.com>
8590 Nigel Stephens <nigel.stephens@arm.com>
8591 Yufeng Zhang <yufeng.zhang@arm.com>
8592
8593 * Makefile.in (clean): Remove aarch64.c and aarch64-without-fpu.c.
8594 (aarch64.c, aarch64-without-fpu.c): New targets.
8595 * configure.srv (aarch64*-*-linux*): New.
8596 * linux-aarch64-low.c: New file.
8597
8598 2013-02-04 Marcus Shawcroft <marcus.shawcroft@arm.com>
8599
8600 * linux-low.c (handle_extended_wait, linux_create_inferior)
8601 (linux_attach_lwp_1, linux_kill_one_lwp, linux_attach_one_lwp)
8602 (dequeue_one_deferred_signal, linux_resume_one_thread)
8603 (fetch_register, linux_write_memory, linux_enable_event_reporting)
8604 (linux_tracefork_grandchild, linux_test_for_tracefork)
8605 (linux_read_offsets, linux_xfer_siginfo, linux_xfer_siginfo): Add
8606 PTRACE_ARG3_TYPE and PTRACE_ARG4_TYPE cast to ptrace arguments
8607 where the argument is 0.
8608
8609 2013-01-25 Yao Qi <yao@codesourcery.com>
8610
8611 * event-loop.c: Include "queue.h".
8612 (gdb_event_p): New typedef.
8613 (struct gdb_event) <next_event>: Remove.
8614 (event_queue): Change to QUEUE(gdb_event_p).
8615 (async_queue_event): Remove.
8616 (gdb_event_xfree): New.
8617 (initialize_event_loop): New.
8618 (process_event): Use API from QUEUE.
8619 (wait_for_event): Likewise.
8620 * server.c (main): Call initialize_event_loop.
8621 * server.h (initialize_event_loop): Declare.
8622
8623 2013-01-18 Yao Qi <yao@codesourcery.com>
8624
8625 * ax.h (struct eval_agent_expr_context): New.
8626 (gdb_eval_agent_expr): Update declaration.
8627 * ax.c (gdb_eval_agent_expr): Remove argument REGCACHE and
8628 TFRAME. Add new argument CTX.
8629 * server.h (struct eval_agent_expr_context): Declare.
8630 (agent_mem_read, agent_tsv_read): Update declaration.
8631 (agent_mem_read_string): Likewise.
8632 * tracepoint.c (eval_tracepoint_agent_expr): Remove.
8633 (add_traceframe_block): Add new argument TPOINT.
8634 Increase TPOINT->traceframe_usage.
8635 (do_action_at_tracepoint): Call gdb_eval_agent_expr instead of
8636 eval_tracepoint_agent_expr.
8637 (condition_true_at_tracepoint): Likewise.
8638 (agent_mem_read): Remove argument TFRAME. Add argument CTX.
8639 (agent_mem_read_string, agent_tsv_read): Likewise.
8640
8641 2013-01-16 Yao Qi <yao@codesourcery.com>
8642
8643 * linux-low.c (linux_resume_one_lwp): Don't check
8644 'lwp->bp_reinsert != 0'.
8645
8646 2013-01-07 Joel Brobecker <brobecker@adacore.com>
8647 Pedro Alves <palves@redhat.com>
8648
8649 * lynx-low.c (ptrace_request_to_str): Define a temporary
8650 macro and use it to simplify this function's implementation.
8651
8652 2013-01-07 Joel Brobecker <brobecker@adacore.com>
8653
8654 * lynx-low.c (lynx_resume): Call perror_with_name if lynx_ptrace
8655 sets errno.
8656
8657 2013-01-07 Joel Brobecker <brobecker@adacore.com>
8658
8659 * configure.srv (i[34567]86-*-lynxos*): Set srv_xmlfiles.
8660
8661 2013-01-07 Joel Brobecker <brobecker@adacore.com>
8662
8663 * configure.srv (powerpc-*-lynxos*): Set srv_xmlfiles.
8664
8665 2013-01-07 Joel Brobecker <brobecker@adacore.com>
8666
8667 * lynx-low.c (lynx_resume): Use the resume_info parameter
8668 to determine the ptid for the lynx_ptrace call, unless
8669 it is equal to minus_one_ptid, in which case we use the
8670 ptid of the current_inferior.
8671 (lynx_wait_1): After having received a thread create/exit
8672 event, resume the inferior's execution using the signaling
8673 thread's ptid, rather than the old ptid.
8674
8675 2013-01-07 Joel Brobecker <brobecker@adacore.com>
8676
8677 * lynx-low.c (lynx_resume): Delete variable ret.
8678
8679 2013-01-01 Joel Brobecker <brobecker@adacore.com>
8680
8681 * gdbreplay.c (gdbreplay_version): Update copyright year.
8682 * server.c (gdbserver_version): Likewise.
8683
8684 2012-12-17 Joel Brobecker <brobecker@adacore.com>
8685
8686 * lynx-low.c (lynx_wait_1): Add debug trace before adding
8687 new thread.
8688
8689 2012-12-17 Joel Brobecker <brobecker@adacore.com>
8690
8691 * lynx-low.c (ptrace_request_to_str): Add handling for
8692 PTRACE_GETTRACESIG.
8693
8694 2012-12-17 Joel Brobecker <brobecker@adacore.com>
8695
8696 * lynx-low.c (lynx_attach): Delete variable new_process.
8697
8698 2012-12-17 Joel Brobecker <brobecker@adacore.com>
8699
8700 * lynx-low.c (lynx_create_inferior): Delete variable
8701 new_process.
8702
8703 2012-12-17 Joel Brobecker <brobecker@adacore.com>
8704
8705 * lynx-low.c (ptrace_request_to_str): Do not handle
8706 PTRACE_GETTHREADLIST if this macro does not exist.
8707
8708 2012-12-15 Yao Qi <yao@codesourcery.com>
8709
8710 * Makefile.in (OBS): Add notif.o.
8711 * notif.c, notif.h: New.
8712 * server.c: Include "notif.h".
8713 (struct vstop_notif) <next>: Remove.
8714 <base>: New field.
8715 (queue_stop_reply): Update.
8716 (push_event, send_next_stop_reply): Remove.
8717 (discard_queued_stop_replies): Update.
8718 (notif_stop): New variable.
8719 (handle_v_stopped): Remove.
8720 (handle_v_requests): Don't call handle_v_stopped. Call
8721 handle_ack_notif instead.
8722 (queue_stop_reply_callback): Call notif_event_enque instead
8723 of queue_stop_reply.
8724 (handle_status): Don't call send_next_stop_reply, call
8725 notif_write_event instead.
8726 (kill_inferior_callback): Likewise.
8727 (detach_or_kill_inferior_callback): Likewise.
8728 (main): Call initialize_notif.
8729 (process_serial_event): Call QUEUE_is_empty.
8730 (handle_target_event): Call notif_push instead of push event.
8731 * server.h (push_event): Remove declaration.
8732
8733 2012-12-10 Tom Tromey <tromey@redhat.com>
8734
8735 * Makefile.in (DEPMODE, DEPDIR, depcomp, COMPILE.pre)
8736 (COMPILE.post, COMPILE, POSTCOMPILE, IPAGENT_COMPILE): New
8737 macros.
8738 (.c.o): Rewrite.
8739 (ax-ipa.o, tracepoint-ipa.o, utils-ipa.o, format-ipa.o)
8740 (common-utils-ipa.o, remote-utils-ipa.o, regcache-ipa.o)
8741 (i386-linux-ipa.o, linux-i386-ipa.o, linux-amd64-ipa.o)
8742 (amd64-linux-ipa.o, ax.o): Rewrite.
8743 (event-loop.o, hostio.o, hostio-errno.o, inferiors.o, mem-break.o)
8744 (proc-service.o, regcache.o, remote-utils.o, server.o, target.o)
8745 (thread-db.o, tracepoint.o, utils.o, gdbreplay.o, dll.o): Remove.
8746 (signals.o, linux-procfs.o, linux-ptrace.o, common-utils.o, vec.o)
8747 (gdb_vecs.o, xml-utils.o, linux-osdata.o, ptid.o, buffer.o)
8748 (format.o, agent.o, vasprintf.o, vsnprintf.o): Rewrite.
8749 (i386-low.o, i387-fp.o, linux-low.o, linux-arm-low.o)
8750 (linux-bfin-low.o, linux-cris-low.o, linux-crisv32-low.o)
8751 (linux-ia64-low.o, linux-m32r-low.o, linux-mips-low.o)
8752 (linux-ppc-low.o, linux-s390-low.o, linux-sh-low.o)
8753 (linux-tic6x-low.o, linux-x86-low.o, linux-xtensa-low.o)
8754 (linux-tile-low.o, lynx-low.o, lynx-ppc-low.o, nto-low.o)
8755 (nto-x86-low.o, linux-low.o, win32-low.o, win32-arm-low.o)
8756 (win32-i386-low.o, spu-low.o, reg-arm.o, arm-with-iwmmxt.o)
8757 (arm-with-vfpv2.o, arm-with-vfpv3.o, arm-with-neon.o, reg-bfin.o)
8758 (reg-cris.o, reg-crisv32.o, i386.o, i386-linux.o, i386-avx.o)
8759 (i386-avx-linux.o, i386-mmx.o, i386-mmx-linux.o, reg-ia64.o)
8760 (reg-m32r.o, reg-m68k.o, reg-cf.o, mips-linux.o, mips-dsp-linux.o)
8761 (mips64-linux.o, mips64-dsp-linux.o, powerpc-32.o, powerpc-32l.o)
8762 (powerpc-altivec32l.o, powerpc-cell32l.o, powerpc-vsx32l.o)
8763 (powerpc-isa205-32l.o, powerpc-isa205-altivec32l.o)
8764 (powerpc-isa205-vsx32l.o, powerpc-e500l.o, powerpc-64l.o)
8765 (powerpc-altivec64l.o, powerpc-cell64l.o, powerpc-vsx64l.o)
8766 (powerpc-isa205-64l.o, powerpc-isa205-altivec64l.o)
8767 (powerpc-isa205-vsx64l.o, s390-linux32.o, s390-linux32v1.o)
8768 (s390-linux32v2.o, s390-linux64.o, s390-linux64v1.o)
8769 (s390-linux64v2.o, s390x-linux64.o, s390x-linux64v1.o)
8770 (s390x-linux64v2.o, tic6x-c64xp-linux.o, tic6x-c64x-linux.o)
8771 (tic6x-c62x-linux.o, reg-sh.o, reg-sparc64.o, reg-spu.o, amd64.o)
8772 (amd64-linux.o, amd64-avx.o, amd64-avx-linux.o, x32.o)
8773 (x32-linux.o, x32-avx.o, x32-avx-linux.o, reg-xtensa.o)
8774 (reg-tilegx.o): Remove.
8775 (all_object_files): New macro.
8776 Include .deps files.
8777 * aclocal.m4, configure: Rebuild.
8778 * acinclude.m4: Include depstand.m4, lead-dot.m4.
8779 * configure.ac: Invoke ZW_CREATE_DEPDIR,
8780 ZW_PROG_COMPILER_DEPENDENCIES. Compute GMAKE condition.
8781
8782 2012-12-05 Tom Tromey <tromey@redhat.com>
8783
8784 PR gdb/14917:
8785 * server.h (current_insn_ptr, emit_error): Declare 'extern'.
8786
8787 2012-11-28 Markus Metzger <markus.t.metzger@intel.com>
8788
8789 * configure.ac: Check for linux/perf_event.h.
8790 * config.in: Regenerated.
8791 * configure: Regenerated.
8792
8793 2012-11-26 Maxime Villard <rustyBSD@gmx.fr>
8794
8795 * hostio.c (handle_readlink): Decrease buffer size
8796 parameter passed to readlink by one byte.
8797
8798 2012-11-26 Yao Qi <yao@codesourcery.com>
8799
8800 * configure.ac (build_warnings): Append '-Wempty-body'.
8801 * configure: Regenerated.
8802 * linux-low.c (linux_create_inferior): Use braces for empty 'if'
8803 body.
8804
8805 2012-11-15 Pierre Muller <muller@sourceware.org>
8806
8807 * configure.ac (AC_CHECK_HEADERS): Add wait.h header.
8808 * config.in: Regenerate.
8809 * configure: Regenerate.
8810 * linux-low.c: Use "gdb_stat.h" header instead of <sys/stat.h> header.
8811 Use "gdb_wait.h" header instead of <sys/wait.h> header.
8812 * lynx-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
8813 * remote-utils.c: Use "gdb_stat.h" header instead of <sys/stat.h>
8814 header.
8815 * server.c: Remove HAVE_WAIT_H conditional. Use "gdb_wait.h" header
8816 instead of <sys/wait.h> header.
8817 * spu-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
8818
8819 2012-11-13 Markus Metzger <markus.t.metzger@intel.com>
8820
8821 * Makefile.in: (INTERNAL_CFLAGS): Add -DGDBSERVER
8822 (various make rules): Remove -DGDBSERVER
8823
8824 2012-11-09 Yao Qi <yao@codesourcery.com>
8825
8826 * spu-low.c (current_ptid): Move it to ..
8827 * gdbthread.h: ... here. New.
8828 * remote-utils.c (read_ptid): Use macro 'current_ptid'.
8829 * server.c (myresume, process_serial_event): Likewise.
8830 * thread-db.c (thread_db_find_new_threads): Likewise.
8831 * tracepoint.c (run_inferior_command): Likewise.
8832
8833 2012-10-01 Andrew Burgess <aburgess@broadcom.com>
8834
8835 * server.c (handle_search_memory_1): Include access length in
8836 warning message.
8837
8838 2012-09-05 Michael Brandt <michael.brandt@axis.com>
8839
8840 * linux-crisv32-low.c: Fix compile errors.
8841
8842 2012-09-04 Yao Qi <yao@codesourcery.com>
8843
8844 * tracepoint.c (cmd_qtsv): Adjust debug message.
8845 Don't check CUR_TPOINT.
8846
8847 2012-08-28 Yao Qi <yao@codesourcery.com>
8848
8849 * ax.c, tracepoint.c: Replace ATTR_FORMAT with ATTRIBUTE_PRINTF.
8850 * server.h: Include 'libiberty.h' and 'ansidecl.h'.
8851 (ATTR_NORETURN, ATTR_FORMAT, ATTR_MALLOC): Remove.
8852 Remove declarations of xmalloc, xreallloc, xstrdup and
8853 freeargv.
8854 * Makefile.in (libiberty_h): New.
8855 (server_h): Append dependencies 'libiberty.h' and 'ansidecl.h'.
8856 (linux-bfin-low.o): Append dependency 'libiberty.h'.
8857
8858 2012-08-23 Yao Qi <yao@codesourcery.com>
8859
8860 * server.h: Remove declaration of 'xsnprintf'.
8861
8862 2012-08-22 Keith Seitz <keiths@redhat.com>
8863
8864 * server.h: Include build-gnulib-gbserver/config.h.
8865 * gdbreplay.c: Likewise.
8866
8867 2012-08-08 Doug Evans <dje@google.com>
8868
8869 * Makefile.in (SFILES): Add gdb_vecs.c.
8870 (OBS): Add gdb_vecs.o.
8871 (gdb_vecs_h, host_defs_h): New variables.
8872 (thread-db.o): Add $(gdb_vecs_h) dependency.
8873 (gdb_vecs.o): New rule.
8874 * thread-db.c: #include "gdb_vecs.h".
8875 (thread_db_load_search): Use a vector to iterate over path elements.
8876 Handle text appearing after "$pdir".
8877
8878 * configure.ac: Add check for strstr.
8879 * config.in: Regenerate.
8880 * configure: Regenerate.
8881
8882 2012-08-02 Ulrich Weigand <ulrich.weigand@linaro.org>
8883
8884 * hostio.c (handle_pread): If pread fails, fall back to attempting
8885 lseek/read.
8886 (handle_pwrite): Likewise for pwrite.
8887
8888 2012-08-01 Ulrich Weigand <ulrich.weigand@linaro.org>
8889
8890 * linux-arm-low.c (arm_linux_hw_point_initialize): Distinguish
8891 between unsupported TYPE and unimplementable ADDR/LEN combination.
8892 (arm_insert_point): Act on new return value.
8893
8894 2012-07-31 Pedro Alves <palves@redhat.com>
8895
8896 * server.c (process_point_options): Only skip tokens if we find
8897 one that is unrecognized. Don't treat 'X' specially while
8898 skipping unrecognized tokens.
8899
8900 2012-07-30 Ulrich Weigand <ulrich.weigand@linaro.org>
8901
8902 * linux-arm-low.c (arm_linux_hw_point_initialize): Do not attempt
8903 to 4-byte-align HW breakpoint addresses for Thumb.
8904
8905 2012-07-27 Yao Qi <yao@codesourcery.com>
8906
8907 PR remote/14161.
8908
8909 * server.h: Declare gdb_agent_about_to_close.
8910 * target.c (kill_inferior): Include "agent.h".
8911 New. Send command 'kill'.
8912 * target.h (kill_inferior): Removed macro.
8913 * tracepoint.c (gdb_agent_about_to_close): New.
8914 (gdb_agent_helper_thread): Handle command 'close'.
8915 Wait endlessly until the inferior stops.
8916 Install gdb_agent_remove_socket to atexit hook.
8917 (agent_socket_name): New static variable.
8918 (gdb_agent_socket_init): Replace local variable 'name' with
8919 'agent_socket_name'.
8920 (gdb_agent_remove_socket): New.
8921
8922 2012-07-27 Yao Qi <yao@codesourcery.com>
8923
8924 * server.c (process_point_options): Stop at 'X' when parsing.
8925
8926 2012-07-19 Michael Eager <eager@eagercon.com>
8927
8928 * i386-low.c (Z_packet_to_hw_type): Add Z_PACKET_HW_BP, translate
8929 to hw_execute.
8930 * linux-x86-low.c (x86_insert_point, x86_remove_point):
8931 Call i386_low_insert_watchpoint, i386_low_remove_watchpoint to add/del
8932 hardware breakpoint.
8933
8934 2012-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
8935
8936 * gdbserver/linux-low.c (initialize_low): Call
8937 linux_ptrace_init_warnings.
8938
8939 2012-07-02 Doug Evans <dje@google.com>
8940
8941 * mem-break.c (gdb_no_commands_at_breakpoint): Fix cast from
8942 pointer to int.
8943
8944 2012-07-02 Stan Shebs <stan@codesourcery.com>
8945
8946 * Makefile.in (WARN_CFLAGS_NO_FORMAT): Define.
8947 (ax.o): Add it to build rule.
8948 (ax-ipa.o): Ditto.
8949 (OBS): Add format.o.
8950 (IPA_OBS): Add format.o.
8951 * server.c (handle_query): Claim support for breakpoint commands.
8952 (process_point_options): Add command case.
8953 (process_serial_event): Leave running if there are printfs in
8954 effect.
8955 * mem-break.h (any_persistent_commands): Declare.
8956 (add_breakpoint_commands): Declare.
8957 (gdb_no_commands_at_breakpoint): Declare.
8958 (run_breakpoint_commands): Declare.
8959 * mem-break.c (struct point_command_list): New struct.
8960 (struct breakpoint): New field command_list.
8961 (any_persistent_commands): New function.
8962 (add_commands_to_breakpoint): New function.
8963 (add_breakpoint_commands): New function.
8964 (gdb_no_commands_at_breakpoint): New function.
8965 (run_breakpoint_commands): New function.
8966 * linux-low.c (linux_wait_1): Test for and run breakpoint commands
8967 locally.
8968 * ax.c: Include format.h.
8969 (ax_printf): New function.
8970 (gdb_eval_agent_expr): Add printf opcode.
8971
8972 2012-06-13 Yao Qi <yao@codesourcery.com>
8973
8974 * server.c (start_inferior): Remove duplicated writes to fields
8975 'last_resume_kind' and 'last_status' of 'current_inferior'.
8976
8977 2012-06-12 Yao Qi <yao@codesourcery.com>
8978 Pedro Alves <palves@redhat.com>
8979
8980 * linux-low.c (linux_set_resume_request): Simplify predicate. Add
8981 comment.
8982 * server.c (handle_v_cont): Extend comment.
8983
8984 2012-06-11 Yao Qi <yao@codesourcery.com>
8985
8986 * linux-low.c (linux_attach): Add 'static'.
8987
8988 2012-06-06 Yao Qi <yao@codesourcery.com>
8989
8990 * ax.c (gdb_eval_agent_expr): Print `top' in hex.
8991
8992 2012-06-01 Jan Kratochvil <jan.kratochvil@redhat.com>
8993
8994 Fix gcc -flto compilation warning.
8995 * server.c (main): Make variable multi_mode and attach volatile.
8996
8997 2012-05-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
8998
8999 * linux-low.c (get_r_debug): Disable code using DT_MIPS_RLD_MAP
9000 if the platform doesn't know about it.
9001
9002 2012-05-30 Jeff Kenton <jkenton@tilera.com>
9003
9004 * Makefile.in (SFILES): Add linux-tile-low.c.
9005 (linux-tile-low.o, reg-tilegx.o, reg-tilegx.c): New rules.
9006 * configure.srv: Handle tilegx-*-linux*.
9007 * linux-tile-low.c: New file.
9008
9009 2012-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
9010
9011 * linux-low.c (linux_qxfer_libraries_svr4): Return -1 if R_DEBUG is -1.
9012
9013 2012-05-24 Pedro Alves <palves@redhat.com>
9014
9015 PR gdb/7205
9016
9017 Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.
9018
9019 2012-05-24 Pedro Alves <palves@redhat.com>
9020
9021 PR gdb/7205
9022
9023 Replace target_signal with gdb_signal throughout.
9024
9025 2012-05-22 Maciej W. Rozycki <macro@codesourcery.com>
9026
9027 * linux-low.c (linux_store_registers): Avoid the copying sequence
9028 when no data has been retrieved by ptrace.
9029
9030 2012-05-22 Will Deacon <will.deacon@arm.com>
9031
9032 * linux-low (__UCLIBC__ && !(__UCLIBC_HAS_MMU__ || __ARCH_HAS_MMU__)):
9033 Include asm/ptrace.h.
9034 (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define only if not
9035 already defined.
9036
9037 2012-05-21 Maciej W. Rozycki <macro@codesourcery.com>
9038
9039 * linux-low.c (linux_store_registers): Don't re-retrieve data
9040 with ptrace that has already been obtained from /proc. Always
9041 copy any data retrieved with ptrace to the buffer supplied.
9042
9043 2012-05-11 Yao Qi <yao@codesourcery.com>
9044 Pedro Alves <palves@redhat.com>
9045
9046 * linux-low.c (enum stopping_threads_kind): New.
9047 (stopping_threads): Change type to `enum stopping_threads_kind'.
9048 (handle_extended_wait): If stopping and suspending threads, leave
9049 the new_lwp suspended too.
9050 (linux_wait_for_event): Adjust.
9051 (stop_all_lwps): Set `stopping_threads' to
9052 STOPPING_AND_SUSPENDING_THREADS or STOPPING_THREADS depending on
9053 whether we're suspending threads or just stopping them. Assert no
9054 recursion happens.
9055
9056 2012-04-29 Yao Qi <yao@codesourcery.com>
9057
9058 * server.h: Move some code to ...
9059 * gdbthread.h: ... here. New.
9060 * Makefile.in (inferiors.o, regcache.o): Depends on gdbthread.h
9061 (remote-utils.o, server.o, target.o tracepoint.o): Likewise.
9062 (nto-low.o, win32-low.o): Likewise.
9063 * inferiors.c, linux-low.h, nto-low.c: Include gdbthread.h.
9064 * regcache.c, remote-utils.c, server.c: Likewise.
9065 * target.c, tracepoint.c, win32-low.c: Likewise.
9066
9067 2012-04-24 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
9068
9069 * linux-low.h (PTRACE_ARG3_TYPE): Move macro from linux-low.c.
9070 (PTRACE_ARG4_TYPE): Likewise.
9071 (PTRACE_XFER_TYPE): Likewise.
9072 * linux-arm-low.c (arm_prepare_to_resume): Cast third argument of
9073 ptrace to PTRACE_ARG3_TYPE.
9074 * linux-low.c (PTRACE_ARG3_TYPE): Move macro to linux-low.h.
9075 (PTRACE_ARG4_TYPE): Likewise.
9076 (PTRACE_XFER_TYPE): Likewise.
9077 (linux_detach_one_lwp): Cast fourth argument of
9078 ptrace to long then PTRACE_ARG4_TYPE.
9079 (regsets_fetch_inferior_registers): Cast third argument of
9080 ptrace to long then PTRACE_ARG3_TYPE.
9081 (regsets_store_inferior_registers): Likewise.
9082
9083 2012-04-20 Pedro Alves <palves@redhat.com>
9084
9085 * configure: Regenerate.
9086
9087 2012-04-19 Pedro Alves <palves@redhat.com>
9088
9089 * Makefile.in (GNULIB_BUILDDIR): New.
9090 (LIBGNU, INCGNU, GNULIB_H): Adjust.
9091 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): New.
9092 (all, install-only, uninstall, clean-info, all-lib, clean): No
9093 longer pass GNULIB_FLAGS_TO_PASS. Use subdir_do.
9094 (maintainer-clean realclean distclean): Use subdir_do.
9095 (subdir_do): New.
9096 (gnulib/import/Makefile): Adjust. Replace gnulib/import with
9097 $(GNULIB_BUILDDIR). Don't pass argument to config.status.
9098 * acinclude.m4: Include acx_configure_dir.m4.
9099 * configure.ac: Remove gl_EARLY, gl_INIT, and AM_INIT_AUTOMAKE
9100 calls. Call AC_PROG_RANLIB. Configure gnulib using
9101 ACX_CONFIGURE_DIR.
9102 (GNULIB): New.
9103 (GNULIB_STDINT_H): Adjust.
9104 (AC_OUTPUT): Don't output gnulib/Makefile anymore.
9105 * gdbreplay.c: Include build-gnulib/config.h.
9106 * server.h: Likewise.
9107 * aclocal.m4: Regenerate.
9108 * config.in: Regenerate.
9109 * configure: Regenerate.
9110
9111 2012-04-19 Pedro Alves <palves@redhat.com>
9112
9113 * Makefile.in (LIBGNU, INCGNU): Adjust.
9114 (GNULIB_FLAGS_TO_PASS, GNULIB_H): Adjust.
9115 (all, install-only, uninstall, clean-info, all-lib, clean)
9116 (maintainer-clean, Makefile, gnulib/Makefile): Adjust.
9117 * configure.ac: Adjust AC_OUTPUT output.
9118 * aclocal.m4: Regenerate.
9119 * configure: Regenerate.
9120
9121 2012-04-19 Pedro Alves <palves@redhat.com>
9122
9123 * Makefile.in (generated_files): New.
9124 (server_h): Remove the explicit dependency on config.h, and depend
9125 on $generated_files.
9126
9127 2012-04-19 Pedro Alves <palves@redhat.com>
9128
9129 * Makefile.in (INCGNU): Add -Ignulib.
9130
9131 2012-04-19 Pedro Alves <palves@redhat.com>
9132
9133 * Makefile.in (GNULIB_INCLUDE_DIR): Rename to ...
9134 (INCGNU): ... this, and spell out -I here.
9135 (GNULIB_LIB): Rename to ...
9136 (LIBGNU): ... this.
9137 (INCLUDE_CFLAGS, gdbserver$(EXEEXT), $(GNULIB_LIB) rule): Adjust.
9138
9139 2012-04-19 Pedro Alves <palves@redhat.com>
9140
9141 * config.in: Regenerate.
9142
9143 2012-04-19 Pedro Alves <palves@redhat.com>
9144
9145 * configure.ac: Remove AC_CHECK_DECLS check for memmem.
9146 * server.h (memmem): Remove declaration.
9147 * config.in: Regenerate.
9148 * configure: Regenerate.
9149
9150 2012-04-19 Yao Qi <yao@codesourcery.com>
9151
9152 * Makefile.in (SFILES): Add common/vec.c.
9153 (OBS): Add vec.o.
9154 (vec.o): New rule.
9155
9156 2012-04-19 Yao Qi <yao@codesourcery.com>
9157
9158 * remote-utils.c (prepare_resume_reply): Replace with macro
9159 target_core_of_thread.
9160 * server.c (handle_qxfer_threads_proper): Likewise.
9161 * target.h (traget_core_of_thread): New macro.
9162
9163 2012-04-18 Pedro Alves <palves@redhat.com>
9164
9165 * aclocal.m4: Regenerate.
9166 * configure: Regenerate.
9167
9168 2012-04-16 Yao Qi <yao@codesourcery.com>
9169
9170 * tracepoint.c (cmd_qtstart): Download tracepoints even when they are
9171 duplicated on address.
9172
9173 2012-04-16 Yao Qi <yao@codesourcery.com>
9174
9175 * tracepoint.c (COPY_FIELD_TO_BUF): New macro.
9176 (struct tracepoint_action_ops) <send>: New field.
9177 (m_tracepoint_action_send, r_tracepoint_action_send): New.
9178 (agent_expr_send, x_tracepoint_action_send): New.
9179 (l_tracepoint_action_send): New.
9180 (cmd_qtdp): Download and install tracepoint
9181 according to `use_agent'.
9182 (run_inferior_command): Add one more parameter `len'.
9183 Update callers.
9184 (tracepoint_send_agent): New.
9185 (cmd_qtdp, cmd_qtstart): Call tracepoint_send_agent.
9186
9187 2012-04-16 Yao Qi <yao@codesourcery.com>
9188
9189 * tracepoint.c (download_tracepoints): Moved to ...
9190 (cmd_qtstart): ... here.
9191
9192 2012-04-14 Yao Qi <yao@codesourcery.com>
9193
9194 * tracepoint.c: Include inttypes.h.
9195 (struct collect_memory_action): Use sized types.
9196 (struct tracepoint): Likewise.
9197 (cmd_qtdp, stop_tracing): Update print specifiers.
9198 (cmd_qtp, response_tracepoint): Likewise.
9199 (collect_data_at_tracepoint): Likewise.
9200 (collect_data_at_step): Likewise.
9201
9202 2012-04-14 Yao Qi <yao@codesourcery.com>
9203
9204 Import gnulib module inttypes.
9205 * aclocal.m4, config.in, configure: Regenerated.
9206
9207 2012-04-14 Yao Qi <yao@codesourcery.com>
9208
9209 * Makefile.in (maintainer-clean, realclean, distclean): Remove
9210 Makefile and config.status at last.
9211
9212 2012-04-13 Yao Qi <yao@codesourcery.com>
9213
9214 * tracepoint.c: Include stdint.h unconditionally.
9215
9216 2012-04-13 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
9217
9218 * acinclude.m4 (GDBSERVER_HAVE_THREAD_DB_TYPE): New macro based
9219 on BFD_HAVE_SYS_PROCFS_TYPE.
9220 * configure.ac: Look for lwpid_t and psaddr_t in libthread_db.h.
9221 * configure: Regenerate.
9222 * config.in: Likewise.
9223
9224 2012-04-13 H.J. Lu <hongjiu.lu@intel.com>
9225
9226 * Makefile.in (clean): Also remove x32.c x32-linux.c
9227 x32-avx.c x32-avx-linux.c.
9228 (x32.o): New target.
9229 (x32.c): Likewise.
9230 (x32-linux.o): Likewise.
9231 (x32-linux.c): Likewise.
9232 (x32-avx.o): Likewise.
9233 (x32-avx.c): Likewise.
9234 (x32-avx-linux.o): Likewise.
9235 (x32-avx-linux.c): Likewise.
9236
9237 * configure.srv (srv_amd64_regobj): Add x32.o x32-avx.o.
9238 (srv_amd64_linux_regobj): Add x32-linux.o x32-avx-linux.o.
9239 (srv_i386_64bit_xmlfiles): Add i386/x32-core.xml.
9240 (srv_amd64_xmlfiles): Add i386/x32.xml i386/x32-avx.xml.
9241 (srv_amd64_linux_xmlfiles): Add i386/x32-linux.xml
9242 i386/x32-avx-linux.xml.
9243
9244 * linux-x86-low.c (init_registers_x32_linux): New prototype.
9245 (init_registers_x32_avx_linux): Likwise.
9246 (x86_linux_update_xmltarget): Call init_registers_x32_linux
9247 or init_registers_x32_avx_linux if linux_is_elf64 is false.
9248
9249 2012-04-13 Pedro Alves <palves@redhat.com>
9250
9251 * Makefile.in (GNULIB_FLAGS_TO_PASS): New.
9252 (FLAGS_TO_PASS): Don't change or set $top_srcdir, $srcdir and VPATH.
9253 (all, uninstall, clean-info, all-lib, clean, maintainer-clean)
9254 (realclean, distclean): Explicitly pass $GNULIB_FLAGS_TO_PASS to
9255 the sub-make.
9256
9257 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
9258
9259 * linux-x86-low.c (compat_x32_clock_t): New.
9260 (compat_x32_siginfo_t): Likewise.
9261 (compat_x32_siginfo_from_siginfo): Likewise.
9262 (siginfo_from_compat_x32_siginfo): Likewise.
9263 (linux_is_elf64): Likewise.
9264 (x86_siginfo_fixup): Call compat_x32_siginfo_from_siginfo
9265 and siginfo_from_compat_x32_siginfo for x32.
9266 (x86_arch_setup): Set linux_is_elf64.
9267
9268 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
9269
9270 PR gdb/13969
9271 * linux-low.c (linux_pid_exe_is_elf_64_file): Also return the
9272 e_machine field.
9273 (linux_qxfer_libraries_svr4): Update call to elf_64_file_p.
9274 * linux-low.h (linux_pid_exe_is_elf_64_file): Updated.
9275 * linux-x86-low.c (x86_arch_setup): Check if GDBserver is
9276 compatible with process.
9277
9278 2012-04-12 Yao Qi <yao@codesourcery.com>
9279
9280 * Makefile.in: Define abs_top_srcdir and abs_srcdir.
9281 (INCLUDE_CFLAGS): Append GNULIB_INCLUDE_DIR.
9282 (install-only, install-info, clean): Handle sub dir gnulib.
9283 (all-lib, am--refresh): New targets.
9284 (memmem.o): Remove target.
9285 * configure.ac: Remove AC_CONFIG_LIBOBJ_DIR.
9286 Invoke gl_EARLY. Invoke AC_CHECK_PROGS for make.
9287 (AC_REPLACE_FUNCS): Remove memmem.
9288 Invoke gl_INIT and AM_INIT_AUTOMAKE.
9289 (AC_OUTPUT): Generate Makefile in gnulib/.
9290 * aclocal.m4, config.in, configure: Regenerated.
9291
9292 2012-04-10 Maciej W. Rozycki <macro@codesourcery.com>
9293
9294 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP.
9295
9296 2012-04-05 Pedro Alves <palves@redhat.com>
9297
9298 -Werror=strict-aliasing
9299
9300 * spu-low.c (parse_spufs_run): Avoid dereferencing type-punned
9301 pointer.
9302
9303 2012-04-04 Pedro Alves <palves@redhat.com>
9304
9305 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
9306 (sparc_store_gregset_from_stack, sparc_store_gregset)
9307 (sparc_breakpoint_at): Fix formatting.
9308
9309 2012-03-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
9310
9311 * configure.ac: Check whether Elf32_auxv_t and Elf64_auxv_t
9312 are available.
9313 * linux-low.c [HAVE_ELF32_AUXV_T] (Elf32_auxv_t): Add typedef.
9314 [HAVE_ELF64_AUXV_T] (Elf64_auxv_t): Likewise.
9315 * config.in: Regenerate.
9316 * configure: Likewise.
9317
9318 2012-03-29 Pedro Alves <palves@redhat.com>
9319
9320 * linux-low.c (regsets_store_inferior_registers) [__sparc__]:
9321 Correct ptrace arguments.
9322
9323 2012-03-28 Pedro Alves <palves@redhat.com>
9324
9325 * linux-ia64-low.c (ia64_regmap): Map IA64_EC_REGNUM to PT_AR_EC.
9326 (IA64_GR0_REGNUM, IA64_FR0_REGNUM)
9327 (IA64_FR1_REGNUM): New defines.
9328 (ia64_fetch_register): New.
9329 (the_low_target): Install it.
9330 * linux-low.h (struct linux_target_ops) <fetch_register>: New
9331 field.
9332 * linux-low.c (linux_fetch_registers): Try the
9333 the_low_target.fetch_register hook first.
9334
9335 * linux-arm-low.c (the_low_target): Adjust.
9336 * linux-bfin-low.c (the_low_target): Adjust.
9337 * linux-cris-low.c (the_low_target): Adjust.
9338 * linux-crisv32-low.c (the_low_target): Adjust.
9339 * linux-m32r-low.c (the_low_target): Adjust.
9340 * linux-m68k-low.c (the_low_target): Adjust.
9341 * linux-mips-low.c (the_low_target): Adjust.
9342 * linux-ppc-low.c (the_low_target): Adjust.
9343 * linux-s390-low.c (the_low_target): Adjust.
9344 * linux-sh-low.c (the_low_target): Adjust.
9345 * linux-sparc-low.c (the_low_target): Adjust.
9346 * linux-tic6x-low.c (the_low_target): Adjust.
9347 * linux-x86-low.c (the_low_target): Adjust.
9348 * linux-xtensa-low.c (the_low_target): Adjust.
9349
9350 2012-03-26 Pedro Alves <palves@redhat.com>
9351
9352 * server.c (handle_qxfer_libraries): Don't bail early if
9353 the_target->qxfer_libraries_svr4 is not NULL.
9354
9355 2012-03-26 Pedro Alves <palves@redhat.com>
9356
9357 * linux-low.c (linux_qxfer_libraries_svr4): Fix pasto in comment.
9358
9359 2012-03-23 Pedro Alves <palves@redhat.com>
9360
9361 * linux-low.c (linux_qxfer_libraries_svr4): Terminate the
9362 "library-list-svr4" element's start tag when the the DSO list is
9363 empty.
9364
9365 2012-03-23 Pedro Alves <palves@redhat.com>
9366
9367 * linux-low.c (read_one_ptr): Read the inferior's pointer through
9368 a variable whose type size is the same as the inferior's pointer
9369 size.
9370
9371 2012-03-21 Thomas Schwinge <thomas@codesourcery.com>
9372
9373 * linux-arm-low.c (arm_stopped_by_watchpoint): Use siginfo_t instead of
9374 struct siginfo.
9375 * linux-low.c (siginfo_fixup, linux_xfer_siginfo): Likewise.
9376 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
9377 * linux-low.h: Include <signal.h>.
9378 (struct siginfo): Remove forward declaration.
9379 (struct linux_target_ops) <siginfo_fixup>: Use siginfo_t instead of
9380 struct siginfo.
9381
9382 2012-03-21 Mike Frysinger <vapier@gentoo.org>
9383
9384 * .gitignore: Ignore more files.
9385
9386 2012-03-19 Pedro Alves <palves@redhat.com>
9387 Jan Kratochvil <jan.kratochvil@redhat.com>
9388
9389 * server.c (cont_thread, general_thread): Add describing comments.
9390 (start_inferior): Clear `cont_thread'.
9391 (handle_v_cont): Don't set `cont_thread' if resuming all threads
9392 of a process.
9393
9394 2012-03-15 Yao Qi <yao@codesourcery.com>
9395
9396 * tracepoint.c (install_tracepoint): Move duplicated tracepoint
9397 handling to ...
9398 (cmd_qtdp): ... here.
9399
9400 2012-03-15 Yao Qi <yao@codesourcery.com>
9401
9402 * tracepoint.c (struct tracepoint_action_ops): New.
9403 (struct tracepoint_action) [!IN_PROCESS_AGENT] <ops>: New field.
9404 (m_tracepoint_action_download): New.
9405 (r_tracepoint_action_download): New.
9406 (x_tracepoint_action_download): New.
9407 (l_tracepoint_action_download): New.
9408 (add_tracepoint_action): Install `action->ops' according type.
9409 (download_tracepoint_1): Move code `download' function pointer
9410 of various tracepoint_action_ops.
9411
9412 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
9413
9414 * linux-low.c (linux_attach_lwp_1): New variable buffer. Call
9415 linux_ptrace_attach_warnings.
9416
9417 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
9418
9419 * Makefile.in (linux-ptrace.o): New.
9420 * configure.srv (arm*-*-linux*, bfin-*-*linux*, crisv32-*-linux*)
9421 (cris-*-linux*, i[34567]86-*-linux*, ia64-*-linux*, m32r*-*-linux*)
9422 (m68*-*-linux*, m68*-*-uclinux*, mips*-*-linux*, powerpc*-*-linux*)
9423 (s390*-*-linux*, sh*-*-linux*, sparc*-*-linux*, tic6x-*-uclinux)
9424 (x86_64-*-linux*, xtensa*-*-linux*): Add linux-ptrace.o to SRV_TGTOBJ
9425 of these targets.
9426 * linux-low.c (linux_attach_lwp_1): Remove redundent else clause.
9427
9428 2012-03-08 Yao Qi <yao@codesourcery.com>
9429 Pedro Alves <palves@redhat.com>
9430
9431 Fix PR server/13392.
9432 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Check
9433 offset of JMP insn.
9434 * tracepoint.c (remove_tracepoint): New.
9435 (cmd_qtdp): Call remove_tracepoint when failed to install.
9436
9437 2012-03-07 Pedro Alves <palves@redhat.com>
9438
9439 * linux-low.c (get_detach_signal): New.
9440 (linux_detach_one_lwp): Get rid of a pending SIGSTOP with SIGCONT.
9441 Pass on pending signals to PTRACE_DETACH. Check the result of the
9442 ptrace call.
9443 * server.c (program_signals, program_signals_p): New.
9444 (handle_general_set): Handle QProgramSignals.
9445 * server.h (program_signals, program_signals_p): Declare.
9446
9447 2012-03-05 Pedro Alves <palves@redhat.com>
9448 Jan Kratochvil <jan.kratochvil@redhat.com>
9449
9450 * linux-low.c (get_dynamic): Don't warn when PT_PHDR isn't found.
9451 New comment why.
9452
9453 2012-03-03 Yao Qi <yao@codesourcery.com>
9454
9455 * tracepoint.c (tracepoint_look_up_symbols): Update call to
9456 agent_look_up_symbols.
9457
9458 2012-03-03 Yao Qi <yao@codesourcery.com>
9459
9460 * Makefile.in (linux-low.o): Keep dependence on agent.h.
9461 (linux-x86-low.o): Likewise.
9462 * server.h: Remove in_process_agent_loaded.
9463 * tracepoint.c (in_process_agent_loaded): Removed. Moved it
9464 common/agent.c.
9465 Update callers.
9466
9467 2012-03-03 Yao Qi <yao@codesourcery.com>
9468
9469 * tracepoint.c (gdb_agent_capability): New global.
9470 (in_process_agent_loaded_ust): Renamed to
9471 `in_process_agent_supports_ust'.
9472 Update callers.
9473 (in_process_agent_supports_ust): Call agent_capability_check.
9474 (clear_installed_tracepoints): Assert that agent supports
9475 agent.
9476
9477 2012-03-03 Yao Qi <yao@codesourcery.com>
9478
9479 * linux-low.c (linux_supports_agent): New.
9480 (linux_target_ops): Initialize field `supports_agent' with
9481 linux_supports_agent.
9482 * target.h (struct target_ops) <supports_agent>: New.
9483 (target_supports_agent): New macro.
9484 * server.c (handle_general_set): Handle packet 'QAgent'.
9485 (handle_query): Send `QAgent+'.
9486 * Makefile.in (server.o): Depends on agent.h.
9487
9488 2012-03-03 Yao Qi <yao@codesourcery.com>
9489
9490 * Makefile.in (OBS): Add agent.o.
9491 Add new rule for agent.o.
9492 Track dependence of tracepoint.c on agent.h.
9493 * tracepoint.c (run_inferior_command_1):
9494 (run_inferior_command): Call agent_run_command.
9495 (gdb_ust_connect_sync_socket): Deleted. Move it to
9496 common/agent.c.
9497 (resume_thread, stop_thread): Likewise.
9498 (gdb_ust_socket_init): Renamed to ...
9499 (gdb_agent_socket_init): ... New.
9500 (gdb_ust_thread): Renamed to ...
9501 (gdb_agent_helper_thread): ... New.
9502 (gdb_ust_init): Move some code to ...
9503 (gdb_agent_init): ... here. New.
9504 [HAVE_UST]: Call gdb_ust_init.
9505 (initialize_tracepoint_ftlib): Call gdb_agent_init.
9506 * configure.ac: Add `sys/un.h' to AC_CHECK_HEADERS.
9507 * config.in, configure: Regenerated.
9508
9509 2012-03-02 Pedro Alves <palves@redhat.com>
9510
9511 * inferiors.c (add_pid_to_list, pull_pid_from_list): Delete.
9512 * linux-low.c (struct simple_pid_list): New.
9513 (stopped_pids): New a struct simple_pid_list pointer.
9514 (add_to_pid_list, pull_pid_from_list): New.
9515 (handle_extended_wait): Don't assume the first signal new children
9516 report is SIGSTOP. Adjust call to pull_pid_from_list.
9517 (linux_wait_for_lwp): Adjust.
9518
9519 2012-03-02 Yao Qi <yao@codesourcery.com>
9520
9521 * tracepoint.c (do_action_at_tracepoint): Write `stop_pc' in
9522 debug log.
9523
9524 2012-03-02 Yao Qi <yao@codesourcery.com>
9525
9526 * tracepoint.c (collect_ust_data_at_tracepoint): Remove parameters
9527 `stop_pc' and `tpoint'. Update caller.
9528
9529 2012-03-01 Maciej W. Rozycki <macro@codesourcery.com>
9530
9531 * linux-low.h (linux_target_ops): Add regset_bitmap member.
9532 * linux-low.c (use_linux_regsets): New macro.
9533 [!HAVE_LINUX_REGSETS] (regsets_fetch_inferior_registers): Likewise.
9534 [!HAVE_LINUX_REGSETS] (regsets_store_inferior_registers): Likewise.
9535 (linux_register_in_regsets): New function.
9536 (usr_fetch_inferior_registers): Skip registers covered by
9537 regsets.
9538 (usr_store_inferior_registers): Likewise.
9539 (usr_fetch_inferior_registers): New macro.
9540 (usr_store_inferior_registers): Likewise.
9541 (linux_fetch_registers): Handle mixed regset/non-regset targets.
9542 (linux_store_registers): Likewise.
9543 * linux-mips-low.c (init_registers_mips_dsp_linux): New
9544 prototype.
9545 (init_registers_mips64_dsp_linux): Likewise.
9546 (init_registers_mips_linux): New macro.
9547 (init_registers_mips_dsp_linux): Likewise.
9548 (mips_dsp_num_regs): Likewise.
9549 (DSP_BASE, DSP_CONTROL): New fallback macros.
9550 (mips_base_regs): New macro.
9551 (mips_regmap): Use it. Fix the size.
9552 (mips_dsp_regmap): New variable.
9553 (mips_dsp_regset_bitmap): Likewise.
9554 (mips_arch_setup): New function.
9555 (mips_cannot_fetch_register): Use the_low_target.regmap rather
9556 than mips_regmap.
9557 (mips_cannot_store_register): Likewise.
9558 (the_low_target): Update .arch_setup, .num_regs and .regmap
9559 initializers. Add .regset_bitmap initializer.
9560 * linux-arm-low.c (the_low_target): Add .regset_bitmap
9561 initializer.
9562 * linux-bfin-low.c (the_low_target): Likewise.
9563 * linux-cris-low.c (the_low_target): Likewise.
9564 * linux-crisv32-low.c (the_low_target): Likewise.
9565 * linux-ia64-low.c (the_low_target): Likewise.
9566 * linux-m32r-low.c (the_low_target): Likewise.
9567 * linux-m68k-low.c (the_low_target): Likewise.
9568 * linux-ppc-low.c (the_low_target): Likewise.
9569 * linux-s390-low.c (the_low_target): Likewise.
9570 * linux-sh-low.c (the_low_target): Likewise.
9571 * linux-sparc-low.c (the_low_target): Likewise.
9572 * linux-tic6x-low.c (the_low_target): Likewise.
9573 * linux-x86-low.c (the_low_target): Likewise.
9574 * linux-xtensa-low.c (the_low_target): Likewise.
9575 * configure.srv <mips*-*-linux*>: Add mips-dsp-linux.o and
9576 mips64-dsp-linux.o to srv_regobj. Add mips-dsp-linux.xml,
9577 mips64-dsp-linux.xml, mips-dsp.xml and mips64-dsp.xml to
9578 srv_xmlfiles.
9579 * Makefile.in (mips-dsp-linux.o, mips-dsp-linux.c): New targets.
9580 (mips64-dsp-linux.o, mips64-dsp-linux.c): Likewise.
9581
9582 2012-02-29 Yao Qi <yao@codesourcery.com>
9583 Pedro Alves <palves@redhat.com>
9584
9585 * linux-low.c: (linux_wait_1): Call unsuspend_all_lwps when
9586 `step_over_finished' is true.
9587
9588 2012-02-27 Pedro Alves <palves@redhat.com>
9589
9590 * linux-low.c (pid_is_stopped): Delete, moved to common/.
9591 (linux_attach_lwp_1): Adjust to use linux_proc_pid_is_stopped.
9592
9593 2012-02-27 Pedro Alves <palves@redhat.com>
9594
9595 PR server/9684
9596 * linux-low.c (pid_is_stopped): New.
9597 (linux_attach_lwp_1): Handle attaching to 'T (stopped)' processes.
9598
9599 2012-02-25 Luis Machado <lgustavo@codesourcery.com>
9600
9601 * mem-break.c (clear_gdb_breakpoint_conditions): Fix de-allocation
9602 of conditions.
9603
9604 2012-02-24 Maciej W. Rozycki <macro@codesourcery.com>
9605
9606 * linux-mips-low.c (mips_regmap): Correct the index of $f9.
9607
9608 2012-02-24 Luis Machado <lgustavo@codesourcery>
9609
9610 * server.c (handle_query): Advertise support for target-side
9611 breakpoint condition evaluation.
9612 (process_point_options): New function.
9613 (process_serial_event): When inserting a breakpoint, check for
9614 a target-side condition that should be evaluated.
9615
9616 * mem-break.c: Include regcache.h and ax.h.
9617 (point_cond_list_t): New data structure.
9618 (breakpoint) <cond_list>: New field.
9619 (find_gdb_breakpoint_at): Make non-static.
9620 (delete_gdb_breakpoint_at): Clear any target-side
9621 conditions.
9622 (clear_gdb_breakpoint_conditions): New function.
9623 (add_condition_to_breakpoint): Likewise.
9624 (add_breakpoint_condition): Likewise.
9625 (gdb_condition_true_at_breakpoint): Likewise.
9626 (gdb_breakpoint_here): Return result directly instead
9627 of going through a local variable.
9628
9629 * mem-break.h (find_gdb_breakpoint_at): New prototype.
9630 (clear_gdb_breakpoint_conditions): Likewise.
9631 (add_breakpoint_condition): Likewise.
9632 (gdb_condition_true_at_breakpoint): Likewise.
9633
9634 * linux-low.c (linux_wait_1): Evaluate target-side breakpoint condition.
9635 (need_step_over_p): Take target-side breakpoint condition into
9636 consideration.
9637
9638 2012-02-24 Luis Machado <lgustavo@codesourcery>
9639
9640 * server.h: Include tracepoint.h.
9641 (agent_mem_read, agent_get_trace_state_variable_value,
9642 agent_set_trace_state_variable_value,
9643 agent_tsv_read, agent_mem_read_string, get_get_tsv_func_addr,
9644 get_set_tsv_func_addr): New prototypes.
9645
9646 * ax.h: New include file.
9647 * ax.c: New source file.
9648
9649 * tracepoint.c: Include ax.h.
9650 (gdb_agent_op, gdb_agent_op_names, gdb_agent_op_sizes,
9651 agent_expr, eval_result_type): Move to ax.h.
9652 (parse_agent_expr): Rename to ...
9653 (gdb_parse_agent_expr): ... this, make it non-static and move
9654 to ax.h.
9655 (unparse_agent_expr) Rename to ...
9656 (gdb_unparse_agent_expr): ... this, make it non-static and move
9657 to ax.h.
9658 (eval_agent_expr): Rename to ...
9659 (eval_tracepoint_agent_expr): ... this.
9660 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Remove
9661 forward declarations.
9662 (add_tracepoint_action): Call gdb_parse_agent_expr (...).
9663 (agent_get_trace_state_variable_value): New function.
9664 (agent_set_trace_state_variable_value): New function.
9665 (cmd_qtdp): Call gdb_parse_agent_expr (...).
9666 (response_tracepoint): Call gdb_unparse_agent_expr (...).
9667 (do_action_at_tracepoint): Call eval_tracepoint_agent_expr (...).
9668 (condition_true_at_tracepoint): Likewise.
9669 (parse_agent_expr): Rename to ...
9670 (gdb_parse_agent_expr): ... this and move to ax.c.
9671 (unparse_agent_expr): Rename to ...
9672 (gdb_unparse_agent_expr): ... this and move to ax.c.
9673 (gdb_agent_op_name): Move to ax.c.
9674 (eval_agent_expr): Rename to ...
9675 (gdb_eval_agent_expr): ... this, use regcache passed as parameter
9676 and move to ax.c.
9677 (eval_tracepoint_agent_expr): New function.
9678 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Make
9679 non-static.
9680 (current_insn_ptr, emit_error, struct bytecode_address): Move to
9681 ax.c.
9682 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul, emit_lsh,
9683 emit_rsh_signed, emit_rsh_unsigned, emit_ext, emit_log_not,
9684 emit_bit_and, emit_bit_or, emit_bit_xor, emit_bit_not, emit_equal,
9685 emit_less_signed, emit_less_unsigned, emit_ref, emit_if_goto,
9686 emit_goto, write_goto_address, emit_const, emit_reg, emit_pop,
9687 emit_stack, emit_zero_ext, emit_swap, emit_stack_adjust,
9688 emit_int_call_1, emit_void_call_2, emit_eq_goto, emit_ne_goto,
9689 emit_lt_goto, emit_ge_goto, emit_gt_goto, emit_le_goto): Move to ax.c.
9690 (get_get_tsv_func_addr, get_set_tsv_func_addr): New functions.
9691 (compile_bytecodes): Remove forward declaration.
9692 (is_goto_target): Move to ax.c.
9693 (compile_bytecodes): Move to ax.c and call
9694 agent_get_trace_state_variable_value (...) and
9695 agent_set_trace_state_variable_value (...).
9696
9697 * Makefile.in: Update ax.c and IPA dependencies.
9698
9699 2012-02-24 Pedro Alves <palves@redhat.com>
9700
9701 * tracepoint.c (cmd_bigqtbuffer): Rename as ...
9702 (cmd_bigqtbuffer_circular): ... this. Only handle
9703 'QTBuffer:circular:'.
9704 (handle_tracepoint_general_set): Adjust.
9705
9706 2012-02-16 Yao Qi <yao@codesourcery.com>
9707
9708 * inferiors.c: Move code to ...
9709 * dll.c: .... here. New.
9710 * server.h: Declare clear_dlls.
9711 * Makefile.in (SFILES): Add dll.c.
9712 (OBS): Add dll.o
9713 (dll.o): New rule.
9714
9715 2012-02-11 Yao Qi <yao@codesourcery.com>
9716
9717 * server.c: (handle_monitor_command): Add a new parameter
9718 `own_buf'.
9719 (handle_query): Update caller.
9720
9721 2012-02-09 Joel Brobecker <brobecker@adacore.com>
9722
9723 * configure.ac: Add readlink to AC_CHECK_FUNCS list.
9724 * configure, config.in: Regenerate.
9725 * hostio.c: Provide an alternate implementation if HAVE_READLINK
9726 is not defined.
9727
9728 2012-02-02 Pedro Alves <palves@redhat.com>
9729
9730 Try SIGKILL first, then PTRACE_KILL.
9731 * linux-low.c (linux_kill_one_lwp): New.
9732 (linux_kill_one_lwp): Rename to ...
9733 (kill_one_lwp_callback): ... this. Use the new
9734 linux_kill_one_lwp.
9735
9736 2012-02-02 Pedro Alves <palves@redhat.com>
9737
9738 * tracepoint.c (cmd_qtminftpilen): Return 0 if there's no current
9739 inferior.
9740
9741 2012-01-27 Pedro Alves <palves@redhat.com>
9742
9743 * linux-low.c (linux_child_pid_to_exec_file): Delete.
9744 (elf_64_file_p): Make static.
9745 (linux_pid_exe_is_elf_64_file): New.
9746 * linux-low.h (linux_child_pid_to_exec_file, elf_64_file_p):
9747 Delete declarations.
9748 (linux_pid_exe_is_elf_64_file): Declare.
9749 * linux-x86-low.c (x86_arch_setup): Use
9750 linux_pid_exe_is_elf_64_file.
9751
9752 2012-01-25 Jan Kratochvil <jan.kratochvil@redhat.com>
9753
9754 * linux-low.c (linux_wait_for_event_1): Rename to ...
9755 (linux_wait_for_event): ... here and merge it with former
9756 linux_wait_for_event - new variable wait_ptid, use it.
9757 (linux_wait_for_event): Remove - merge it to linux_wait_for_event_1.
9758
9759 2012-01-23 Pedro Alves <palves@redhat.com>
9760
9761 * server.c (main): Avoid yet another case of infinite loop while
9762 detaching/killing after a longjmp.
9763
9764 2012-01-20 Jan Kratochvil <jan.kratochvil@redhat.com>
9765
9766 Code cleanup.
9767 * linux-low.c (linux_wait_for_event_1): Use ptid_is_pid.
9768
9769 2012-01-20 Ulrich Weigand <ulrich.weigand@linaro.org>
9770
9771 * hostio.c (handle_readlink): New function.
9772 (handle_vFile): Call it to handle "vFile:readlink" packets.
9773
9774 2012-01-20 Pedro Alves <palves@redhat.com>
9775 Ulrich Weigand <ulrich.weigand@linaro.org>
9776
9777 * server.c (handle_v_requests): Only support vAttach and vRun to
9778 start multiple processes when in extended protocol mode.
9779
9780 2012-01-17 Pedro Alves <palves@redhat.com>
9781
9782 * tracepoint.c (initialize_tracepoint): Use mmap instead of
9783 memalign plus mprotect to allocate the scratch buffer.
9784
9785 2012-01-13 Pedro Alves <palves@redhat.com>
9786
9787 * server.c (attach_inferior): Clear `cont_thread'.
9788
9789 2012-01-13 Pedro Alves <palves@redhat.com>
9790
9791 * server.c (main): Avoid infinite loop while detaching/killing
9792 after a longjmp.
9793
9794 2012-01-09 Doug Evans <dje@google.com>
9795
9796 * server.c (start_inferior): Set last_ptid in --wrapper case.
9797
9798 2012-01-06 Yao Qi <yao@codesourcery.com>
9799
9800 * tracepoint.c [IN_PROCESS_AGENT] (debug_threads): Macro
9801 defined.
9802 [IN_PROCESS_AGENT] (debug_agent): New global variable.
9803
9804 2012-01-04 Yao Qi <yao@codesourcery.com>
9805
9806 * tracepoint.c (cmd_qtdp): Print debug message
9807 for static tracepoint.
9808
9809 2012-01-04 Yao Qi <yao@codesourcery.com>
9810
9811 * tracepoint.c (trace_vdebug): Differentiate debug message
9812 between gdbserver and IPA.
9813
9814 2012-01-03 Yao Qi <yao@codesourcery.com>
9815
9816 * tracepoint.c (tracepoint_was_hit): Don't collect for
9817 static tracepoint.
9818
9819 2012-01-02 Joel Brobecker <brobecker@adacore.com>
9820
9821 * terminal.h: Reformat copyright header.
9822
9823 2012-01-02 Joel Brobecker <brobecker@adacore.com>
9824
9825 * server.c (gdbserver_version): Update copyright year.
9826 * gdbreplay.c (gdbreplay_version): Likewise.
9827
9828 2011-12-18 Jan Kratochvil <jan.kratochvil@redhat.com>
9829
9830 * linux-low.c (linux_create_inferior): Put empty if clause for write.
9831
9832 Revert:
9833 2011-12-18 Hui Zhu <teawater@gmail.com>
9834 * linux-low.c (linux_create_inferior): Save return value to ret.
9835
9836 2011-12-18 Hui Zhu <teawater@gmail.com>
9837
9838 * linux-low.c (linux_create_inferior): Save return value to ret.
9839
9840 2011-12-16 Doug Evans <dje@google.com>
9841
9842 * linux-low.c (linux_create_inferior): If stdio connection,
9843 redirect stdin from /dev/null, stdout to stderr.
9844 * remote-utils.c (remote_is_stdio): New static global.
9845 (remote_connection_is_stdio): New function.
9846 (remote_prepare): Handle stdio connection.
9847 (remote_open): Ditto.
9848 (remote_close): Don't close stdin for stdio connections.
9849 (read_prim,write_prim): New functions. Replace all calls to
9850 read/write to these.
9851 * server.c (main): Watch for "-" argument. Move call to
9852 remote_prepare before start_inferior.
9853 * server.h (STDIO_CONNECTION_NAME): New macro.
9854 (remote_connection_is_stdio): Declare.
9855
9856 * remote-utils.c (prepare_resume_reply): Remove extraneous \n
9857 in debugging output.
9858
9859 2011-12-15 Yao Qi <yao@codesourcery.com>
9860
9861 * tracepoint.c: Include sys/syscall.h.
9862 (gdb_ust_thread): Remove preprocessor conditional.
9863
9864 2011-12-14 Pedro Alves <pedro@codesourcery.com>
9865
9866 * linux-low.c (linux_detach_one_lwp): Call
9867 the_low_target.prepare_to_resume before detaching.
9868
9869 2011-12-14 Yao Qi <yao@codesourcery.com>
9870
9871 * tracepoint.c (gdb_ust_thread): Don't ignore return value
9872 of write.
9873
9874 2011-12-14 Yao Qi <yao@codesourcery.com>
9875
9876 * i386-low.c (i386_low_stopped_data_address): Initialize local
9877 variable `control'.
9878
9879 2011-12-13 Pedro Alves <pedro@codesourcery.com>
9880
9881 PR remote/13492
9882
9883 * i386-low.c (i386_low_stopped_data_address): Avoid fetching
9884 DR_CONTROL unless necessary. Extend comments.
9885 * linux-x86-low.c (x86_linux_prepare_to_resume): Don't write to
9886 DR0-3 if not used. If any watchpoint was set, clear DR_STATUS.
9887
9888 2011-12-13 Yao Qi <yao@codesourcery.com>
9889
9890 * tracepoint.c (trace_buffer_alloc): Replace magic numbers with
9891 macros.
9892 (upload_fast_traceframes, upload_fast_traceframes): Likewise.
9893
9894 2011-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
9895
9896 * linux-low.c (linux_kill): Skip PTRACE_KILL if LWP does not exist.
9897 Print new debug message for such case.
9898
9899 2011-12-06 Jan Kratochvil <jan.kratochvil@redhat.com>
9900
9901 Fix overlapping memcpy.
9902 * mem-break.c (set_raw_breakpoint_at): New variable buf. Use it for
9903 the read_inferior_memory transfer.
9904 (delete_fast_tracepoint_jump): New variable buf. Use it for the
9905 write_inferior_memory transfer.
9906 (set_fast_tracepoint_jump): New variable buf. Use it for the
9907 read_inferior_memory and write_inferior_memory transfers.
9908 (uninsert_fast_tracepoint_jumps_at, reinsert_fast_tracepoint_jumps_at)
9909 (delete_raw_breakpoint, uninsert_raw_breakpoint): New variable buf.
9910 Use it for the write_inferior_memory transfer.
9911 (check_mem_read, check_mem_write): New gdb_asserts for overlapping
9912 buffers.
9913
9914 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
9915
9916 * linux-low.c (fetch_register, store_register): Make code
9917 consistent, fix formatting.
9918
9919 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
9920
9921 * linux-low.c (usr_store_inferior_registers): Factor out code
9922 to handle individual registers into...
9923 (store_register): ... this new function.
9924
9925 2011-12-06 Ulrich Weigand <uweigand@de.ibm.com>
9926
9927 * Makefile.in (s390-linux32v1.o, s390-linux32v1.c): New rules.
9928 (s390-linux32v2.o, s390-linux32v2.c): Likewise.
9929 (s390-linux64v1.o, s390-linux64v1.c): Likewise.
9930 (s390-linux64v2.o, s390-linux64v2.c): Likewise.
9931 (s390x-linux64v1.o, s390x-linux64v1.c): Likewise.
9932 (s390x-linux64v2.o, s390x-linux64v2.c): Likewise.
9933 * configure.srv [s390*-*-linux*] (srv_regobj): Add new objects.
9934 (srv_xmlfiles): Add new XML files.
9935
9936 * linux-s390-low.c: Include "elf/common.h", <sys/ptrace.h>,
9937 and <sys/uio.h>.
9938 (PTRACE_GETREGSET, PTRACE_SETREGSET): Define if undefined.
9939 (init_registers_s390_linux32v1): Add prototype.
9940 (init_registers_s390_linux32v2): Likewise.
9941 (init_registers_s390_linux64v1): Likewise.
9942 (init_registers_s390_linux64v2): Likewise.
9943 (init_registers_s390x_linux64v1): Likewise.
9944 (init_registers_s390x_linux64v2): Likewise.
9945 (s390_num_regs): Increment to 52.
9946 (s390_regmap): Add orig_r2 register.
9947 (s390_num_regs_3264): Increment to 68.
9948 (s390_regmap_3264): Add orig_r2 register.
9949 (s390_collect_ptrace_register): Handle orig_r2 register.
9950 (s390_supply_ptrace_register): Likewise.
9951 (s390_fill_last_break): New function.
9952 (s390_store_last_break): Likewise.
9953 (s390_fill_system_call): New function.
9954 (s390_store_system_call): Likewise.
9955 (target_regsets): Handle NT_S390_LAST_BREAK and NT_S390_SYSTEM_CALL
9956 register sets.
9957 (s390_check_regset): New function.
9958 (s390_arch_setup): Check for presence of NT_S390_LAST_BREAK and
9959 NT_S390_SYSTEM_CALL regsets and use appropriate description.
9960 Update target_regsets for available register sets.
9961
9962 2011-12-02 Paul Pluzhnikov <ppluzhnikov@google.com>
9963 Jan Kratochvil <jan.kratochvil@redhat.com>
9964
9965 * linux-low.c (get_phdr_phnum_from_proc_auxv, get_dynamic, get_r_debug)
9966 (read_one_ptr, struct link_map_offsets, linux_qxfer_libraries_svr4):
9967 New.
9968 (struct linux_target_ops): Install linux_qxfer_libraries_svr4.
9969 * linux-low.h (struct process_info_private): New member r_debug.
9970 * server.c (handle_qxfer_libraries): Call
9971 the_target->qxfer_libraries_svr4.
9972 (handle_qxfer_libraries_svr4): New function.
9973 (qxfer_packets): New entry "libraries-svr4".
9974 (handle_query): Check QXFER_LIBRARIES_SVR4 and report libraries-svr4.
9975 * target.h (struct target_ops): New member qxfer_libraries_svr4.
9976 * remote.c (remote_xfer_partial): Call add_packet_config_cmd for
9977 PACKET_qXfer_libraries_svr4.
9978
9979 2011-11-30 Ulrich Weigand <uweigand@de.ibm.com>
9980
9981 * linux-s390-low.c (s390_collect_ptrace_register): Fully convert
9982 PSW address/mask between 8-byte and 16-byte formats.
9983 (s390_supply_ptrace_register): Likewise.
9984 (s390_get_pc, s390_set_pc): 4-byte PSW address always includes
9985 basic addressing mode bit.
9986
9987 2011-11-24 Stan Shebs <stan@codesourcery.com>
9988
9989 * tracepoint.c (cmd_qtstatus): Use plongest instead of %llx.
9990
9991 2011-11-17 Stan Shebs <stan@codesourcery.com>
9992
9993 * tracepoint.c (struct tracepoint): New field traceframe_usage.
9994 (tracing_start_time): New global.
9995 (tracing_stop_time): New global.
9996 (tracing_user_name): New global.
9997 (tracing_notes): New global.
9998 (tracing_stop_note): New global.
9999 (cmd_qtstart): Set traceframe_usage, start_time.
10000 (stop_tracing): Set stop_time.
10001 (cmd_qtstatus): Report additional status.
10002 (cmd_qtp): New function.
10003 (handle_tracepoint_query): Call it.
10004 (cmd_qtnotes): New function.
10005 (handle_tracepoint_general_set): Call it.
10006 (get_timestamp): Rename from tsv_get_timestamp.
10007
10008 2011-11-14 Stan Shebs <stan@codesourcery.com>
10009 Kwok Cheung Yeung <kcy@codesourcery.com>
10010
10011 * linux-x86-low.c (small_jump_insn): New.
10012 (i386_install_fast_tracepoint_jump_pad): Add arguments for
10013 trampoline and error message, build a trampoline and issue a small
10014 jump instruction to it.
10015 (x86_install_fast_tracepoint_jump_pad): Add arguments for
10016 trampoline and error message.
10017 (x86_get_min_fast_tracepoint_insn_len): New.
10018 (the_low_target): Add call to x86_get_min_fast_tracepoint_insn_len.
10019 * linux-low.h (struct linux_target_ops): Add arguments to
10020 install_fast_tracepoint_jump_pad operation, add new operation.
10021 * linux-low.c (linux_install_fast_tracepoint_jump_pad): Add
10022 arguments.
10023 (linux_get_min_fast_tracepoint_insn_len): New function.
10024 (linux_target_op): Add new operation.
10025 * tracepoint.c (gdb_trampoline_buffer): New IPA variable.
10026 (gdb_trampoline_buffer_end): Ditto.
10027 (gdb_trampoline_buffer_error): Ditto.
10028 (struct ipa_sym_addresses): Add fields for new IPA variables.
10029 (symbol_list): Add entries for new IPA variables.
10030 (struct tracepoint): Add fields to hold the address range of the
10031 trampoline used by the tracepoint.
10032 (trampoline_buffer_head): New static variable.
10033 (trampoline_buffer_tail): Ditto.
10034 (claim_trampoline_space): New function.
10035 (have_fast_tracepoint_trampoline_buffer): New function.
10036 (clone_fast_tracepoint): Fill in trampoline fields of tracepoint
10037 structure.
10038 (install_fast_tracepoint): Ditto, also add error buffer argument.
10039 (cmd_qtminftpilen): New function.
10040 (handle_tracepoint_query): Add response to qTMinFTPILen packet.
10041 (fast_tracepoint_from_trampoline_address): New function.
10042 (fast_tracepoint_collecting): Handle trampoline as part of jump
10043 pad space.
10044 (set_trampoline_buffer_space): New function.
10045 (initialize_tracepoint): Initialize new IPA variables.
10046 * target.h (struct target_ops): Add arguments to
10047 install_fast_tracepoint_jump_pad operation, add new
10048 get_min_fast_tracepoint_insn_len operation.
10049 (target_get_min_fast_tracepoint_insn_len): New.
10050 (install_fast_tracepoint_jump_pad): Add arguments.
10051 * server.h (IPA_BUFSIZ): Define.
10052 * linux-i386-ipa.c: Include extra header files.
10053 (initialize_fast_tracepoint_trampoline_buffer): New function.
10054 (initialize_low_tracepoint): Call it.
10055 * server.h (set_trampoline_buffer_space): Declare.
10056 (claim_trampoline_space): Ditto.
10057 (have_fast_tracepoint_trampoline_buffer): Ditto.
10058
10059 2011-11-14 Yao Qi <yao@codesourcery.com>
10060
10061 * server.c (handle_query): Handle InstallInTrace for qSupported.
10062 * tracepoint.c (add_tracepoint): Sort list.
10063 (install_tracepoint, download_tracepoint): New.
10064 (cmd_qtdp): Call them to install and download tracepoints.
10065 (sort_tracepoints): Removed.
10066 (cmd_qtstart): Update.
10067
10068 2011-11-14 Yao Qi <yao@codesourcery.com>
10069
10070 * mem-break.c (inc_ref_fast_tracepoint_jump): New.
10071 * mem-break.h: Declare.
10072 * tracepoint.c (cmd_qtstart): Move some code to ...
10073 (clone_fast_tracepoint, install_fast_tracepoint): ... here.
10074 New.
10075 (download_tracepoints): Move some code to ...
10076 (download_tracepoint_1): ... here. New.
10077
10078 2011-11-08 Yao Qi <yao@codesourcery.com>
10079
10080 * remote-utils.c (relocate_instruction): A comment fix.
10081
10082 2011-11-07 Joel Brobecker <brobecker@adacore.com>
10083
10084 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): Delete.
10085 (i386_dr_low_get_control, i386_dr_low_get_status): Use
10086 dr_status_mirror and dr_control_mirror from debug_reg_state.
10087 (i386_dr_low_get_status): Use debug_reg_state.dr_status_mirror
10088 (i386_initial_stuff): Remove use of deleted globals.
10089 (i386_get_thread_context, i386_set_thread_context,
10090 i386_thread_added): Use dr_status_mirror and dr_control_mirror
10091 from debug_reg_state.
10092
10093 2011-11-05 Yao Qi <yao@codesourcery.com>
10094
10095 * tracepoint.c (gdb_collect): Loop over tracepoints of same
10096 address as TPOINT's.
10097
10098 2011-11-02 Stan Shebs <stan@codesourcery.com>
10099
10100 * tracepoint.c (agent_mem_read_string): New function.
10101 (eval_agent_expr): Call it for tracenz.
10102 * server.c (handle_query): Report support for tracenz.
10103
10104 2011-11-02 Yao Qi <yao@codesourcery.com>
10105
10106 * tracepoint.c (cmd_qtstart): Remove unused local variables.
10107
10108 2011-11-02 Yao Qi <yao@codesourcery.com>
10109
10110 * target.h: Fix a typo in comment.
10111
10112 2011-10-31 Pedro Alves <pedro@codesourcery.com>
10113
10114 * mem-break.c (check_mem_write): Add `myaddr' parameter. Don't
10115 clobber the breakpoints' shadows with fast tracepoint jumps.
10116 * mem-break.h (check_mem_write): Add `myaddr' parameter.
10117 * target.c (write_inferior_memory): Also pass MYADDR down to
10118 check_mem_write.
10119
10120 2011-10-07 Ulrich Weigand <ulrich.weigand@linaro.org>
10121
10122 * configure.ac: Check support for personality routine.
10123 * configure: Regenerate.
10124 * config.in: Likewise.
10125 * linux-low.c: Include <sys/personality.h>.
10126 Define ADDR_NO_RANDOMIZE if necessary.
10127 (linux_create_inferior): Disable address space randomization when
10128 forking inferior, if requested.
10129 (linux_supports_disable_randomization): New function.
10130 (linux_target_ops): Install it.
10131 * server.h (disable_randomization): Declare.
10132 * server.c (disable_randomization): New global variable.
10133 (handle_general_set): Handle QDisableRandomization.
10134 (handle_query): Likewise for qSupported.
10135 (main): Support --disable-randomization and --no-disable-randomization
10136 command line arguments.
10137 * target.h (struct target_ops): Add supports_disable_randomization.
10138 (target_supports_disable_randomization): New macro.
10139
10140 2011-09-29 Mike Frysinger <vapier@gentoo.org>
10141
10142 * linux-low.c (target_loadseg): Add defined PTRACE_GETFDPIC to the
10143 ifdef check.
10144 [PT_GETDSBT] (target_loadmap): Wrap in a defined PT_GETDSBT check.
10145 [!PT_GETDSBT] (target_loadmap): New definition.
10146 (LINUX_LOADMAP, LINUX_LOADMAP_EXEC, LINUX_LOADMAP_INTERP): Define.
10147 (linux_read_loadmap): Change PTRACE_GETDSBT_EXEC to
10148 LINUX_LOADMAP_EXEC, PTRACE_GETDSBT_INTERP to LINUX_LOADMAP_INTERP,
10149 and PT_GETDSBT to LINUX_LOADMAP.
10150 [!PT_GETDSBT] (linux_read_loadmap): Define to NULL.
10151 (linux_target_ops): Delete unnecessary ifdef PT_GETDSBT check.
10152
10153 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
10154
10155 * linux-arm-low.c (struct arm_linux_hwbp_cap): Remove.
10156 (arm_linux_hwbp_cap): New static variable.
10157 (arm_linux_get_hwbp_cap): Replace by ...
10158 (arm_linux_init_hwbp_cap): ... this new function.
10159 (arm_linux_get_hw_breakpoint_count): Use arm_linux_hwbp_cap.
10160 (arm_linux_get_hw_watchpoint_count): Likewise.
10161 (arm_linux_get_hw_watchpoint_max_length): Likewise.
10162 (arm_arch_setup): Call arm_linux_init_hwbp_cap.
10163 (arm_prepare_to_resume): Use perror_with_name instead of error.
10164
10165 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
10166
10167 * linux-arm-low.c: Include <signal.h>.
10168 (PTRACE_GETHBPREGS, PTRACE_SETHBPREGS): Define if necessary.
10169 (struct arm_linux_hwbp_cap): New data type.
10170 (arm_hwbp_type, arm_hwbp_control_t): New typedefs.
10171 (struct arm_linux_hw_breakpoint): New data type.
10172 (MAX_BPTS, MAX_WPTS): Define.
10173 (struct arch_process_info, struct arch_lwp_info): New data types.
10174 (arm_linux_get_hwbp_cap): New function.
10175 (arm_linux_get_hw_breakpoint_count): Likewise.
10176 (arm_linux_get_hw_watchpoint_count): Likewise.
10177 (arm_linux_get_hw_watchpoint_max_length): Likewise.
10178 (arm_hwbp_control_initialize): Likewise.
10179 (arm_hwbp_control_is_enabled): Likewise.
10180 (arm_hwbp_control_is_initialized): Likewise.
10181 (arm_hwbp_control_disable): Likewise.
10182 (arm_linux_hw_breakpoint_equal): Likewise.
10183 (arm_linux_hw_point_initialize): Likewise.
10184 (struct update_registers_data): New data structure.
10185 (update_registers_callback: New function.
10186 (arm_insert_point): Likewise.
10187 (arm_remove_point): Likewise.
10188 (arm_stopped_by_watchpoint): Likewise.
10189 (arm_stopped_data_address): Likewise.
10190 (arm_new_process): Likewise.
10191 (arm_new_thread): Likewise.
10192 (arm_prepare_to_resume): Likewise.
10193 (the_low_target): Register arm_insert_point, arm_remove_point,
10194 arm_stopped_by_watchpoint, arm_stopped_data_address, arm_new_process,
10195 arm_new_thread, and arm_prepare_to_resume.
10196
10197 2011-09-15 Stan Shebs <stan@codesourcery.com>
10198
10199 * server.h (struct emit_ops): Add compare-goto fields.
10200 * tracepoint.c (gdb_agent_op_sizes): New table.
10201 (emit_eq_goto): New function.
10202 (emit_ne_goto): New function.
10203 (emit_lt_goto): New function.
10204 (emit_le_goto): New function.
10205 (emit_gt_goto): New function.
10206 (emit_ge_goto): New function.
10207 (is_goto_target): New function.
10208 (compile_bytecodes): Recognize special cases of compare-goto
10209 combinations and call specialized emitters for them.
10210 * linux-x86-low.c (amd64_emit_eq_goto): New function.
10211 (amd64_emit_ne_goto): New function.
10212 (amd64_emit_lt_goto): New function.
10213 (amd64_emit_le_goto): New function.
10214 (amd64_emit_gt_goto): New function.
10215 (amd64_emit_ge_goto): New function.
10216 (amd64_emit_ops): Add the new functions.
10217 (i386_emit_eq_goto): New function.
10218 (i386_emit_ne_goto): New function.
10219 (i386_emit_lt_goto): New function.
10220 (i386_emit_le_goto): New function.
10221 (i386_emit_gt_goto): New function.
10222 (i386_emit_ge_goto): New function.
10223 (i386_emit_ops): Add the new functions.
10224
10225 2011-09-08 Stan Shebs <stan@codesourcery.com>
10226
10227 * linux-x86-low.c (i386_emit_prologue): Save %ebx.
10228 (i386_emit_epilogue): Restore %ebx.
10229
10230 2011-08-31 Jie Zhang <jzhang918@gmail.com>
10231
10232 * server.c (step_thread): Remove definition.
10233 (process_serial_event): Don't handle Hs.
10234 * server.h (step_thread): Remove declaration.
10235 * target.c (set_desired_inferior): Remove use of step_thread.
10236
10237 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
10238
10239 * linux-low.c: Include linux-procfs.h.
10240 (linux_attach_lwp_1): Update comments.
10241 (linux_attach): Scan for existing threads when attaching to a
10242 process that is the tgid.
10243 * Makefile.in: Update dependencies.
10244
10245 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
10246
10247 * configure.srv: Add linux-procfs.o dependencies.
10248
10249 2011-08-14 Yao Qi <yao@codesourcery.com>
10250
10251 * target.h (struct target_ops): Fix indent.
10252 * win32-low.c (win32_target_ops): Fix comment.
10253
10254 2011-08-14 Andrew Jenner <andrew@codesourcery.com>
10255 Yao Qi <yao@codesourcery.com>
10256
10257 * Makefile.in (clean): Remove tic6x-*.c files.
10258 (linux-tic6x-low.o, tic6x-c62x-linux.o, tic6x-c64x-linux.o): New rules.
10259 (tic6x-c64xp-linux.o, tic6x-c62x-linux.c, tic6x-c64x-linux.c): Likewise.
10260 (tic6x-c64xp-linux.c): Likewise.
10261 * configure.srv: Add support for tic6x-*-uclinux.
10262 * linux-tic6x-low.c: New.
10263 * linux-low.c (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define.
10264
10265 2011-08-14 Andrew Stubbs <ams@codesourcery.com>
10266 Yao Qi <yao@codesourcery.com>
10267
10268 * target.h (struct target_ops): Add read_loadmap.
10269 * linux-low.c (struct target_loadseg): New type.
10270 (struct target_loadmap): New type.
10271 (linux_read_loadmap): New function.
10272 (linux_target_ops): Add linux_read_loadmap.
10273 * server.c (handle_query): Support qXfer:fdpic:read packet.
10274 * win32-low.c (win32_target_ops): Initialize field `read_loadmap'
10275 to NULL.
10276
10277 2011-08-05 Eli Zaretskii <eliz@gnu.org>
10278
10279 * win32-low.c: Include <stdint.h>.
10280
10281 2011-07-22 Pedro Alves <pedro@codesourcery.com>
10282
10283 * i386-low.c (i386_insert_aligned_watchpoint): Don't pass the info
10284 to the inferior here.
10285 (i386_remove_aligned_watchpoint): Ditto.
10286 (i386_handle_nonaligned_watchpoint): Return immediate on fail to
10287 fit part of the watchpoint in the debug registers.
10288 (i386_update_inferior_debug_regs): New.
10289 (i386_low_insert_watchpoint): Work on a local mirror of the debug
10290 registers, and only update the inferior on success.
10291 (i386_low_remove_watchpoint): Ditto.
10292
10293 2011-07-22 Kwok Cheung Yeung <kcy@codesourcery.com>
10294
10295 * linux-low.c (compare_ints, unique, list_threads, show_process,
10296 linux_core_of_thread): Delete.
10297 (linux_target_ops): Change linux_core_of_thread to
10298 linux_common_core_of_thread.
10299 (linux_qxfer_osdata): Defer to linux_common_xfer_osdata.
10300 * utils.c (malloc_failure): Change type of argument.
10301 (xmalloc, xrealloc, xcalloc, xsnprintf): Delete.
10302 * Makefile.in (SFILES): Add common/common-utils.c, common/xml-utils.c,
10303 common/linux-osdata.c, common/ptid.c and common/buffer.c.
10304 (OBS): Add xml-utils.o, common-utils.o, ptid.o and buffer.o.
10305 (IPA_OBJS): Add common-utils-ipa.o.
10306 (ptid_h, linux_osdata_h): New macros.
10307 (server_h): Add common/common-utils.h, common/xml-utils.h,
10308 common/buffer.h, common/gdb_assert.h, common/gdb_locale.h and
10309 common/ptid.h.
10310 (common-utils-ipa.o, common-utils.o, xml-utils.o, linux-osdata.o,
10311 ptid.o, buffer.o): New rules.
10312 (linux-low.o): Add common/linux-osdata.h as a dependency.
10313 * configure.srv (srv_tgtobj): Add linux-osdata.o to Linux targets.
10314 * configure.ac: Add AC_HEADER_DIRENT check.
10315 * config.in: Regenerate.
10316 * configure: Regenerate.
10317 * remote-utils.c (xml_escape_text): Delete.
10318 (buffer_grow, buffer_free, buffer_init, buffer_finish,
10319 buffer_xml_printf): Move to common/buffer.c.
10320 * server.c (main): Remove call to initialize_inferiors.
10321 * server.h (struct ptid, ptid_t, minus_one_ptid, null_ptid,
10322 ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp, ptid_get_tid,
10323 ptid_equal, ptid_is_pid, initialize_inferiors, xml_escape_text,
10324 internal_error, gdb_assert, gdb_assert_fail): Delete.
10325 (struct buffer, buffer_grow, buffer_free, buffer_init, buffer_finish,
10326 buffer_xml_printf, buffer_grow_str, buffer_grow_str0): Move to
10327 common/buffer.h.
10328 * inferiors.c (null_ptid, minus_one_ptid, ptid_build, pid_to_ptid,
10329 ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal, ptid_is_pid,
10330 initialize_inferiors): Delete.
10331
10332 2011-07-20 Pedro Alves <pedro@codesourcery.com>
10333
10334 * tracepoint.c (tracepoint_look_up_symbols): Return upon the first
10335 symbol error.
10336
10337 2011-05-31 Pedro Alves <pedro@codesourcery.com>
10338
10339 * linux-x86-low.c (i386_dr_low_get_addr): Fix off by one in
10340 assertion.
10341 * win32-i386-low.c (i386_dr_low_get_addr): Ditto.
10342
10343 2011-05-26 Yao Qi <yao@codesourcery.com>
10344
10345 * Makefile.in (thread-db.o): Track dependence to
10346 common/gdb_thread_db.h.
10347 * thread-db.c: include gdb_thread_db.h from right place.
10348
10349 2011-05-16 Adrian Cornish <gnu@bluedreamer.com>
10350
10351 * linux-i386-ipa.c (supply_static_tracepoint_registers): Pass
10352 __FILE__ and __LINE__ to internal_error.
10353
10354 2011-05-13 Doug Evans <dje@google.com>
10355
10356 * thread-db.c (try_thread_db_load_from_sdir): New function.
10357 (try_thread_db_load_from_dir): New function.
10358 (thread_db_load_search): Handle $sdir, ignore $pdir.
10359 Remove trying of system directories if search of
10360 libthread-db-search-path fails, that is now done via $sdir.
10361
10362 2011-05-12 Kwok Cheung Yeung <kcy@codesourcery.com>
10363
10364 * server.c (handle_query): Add EnableDisableTracepoints to the list
10365 of supported features.
10366 * tracepoint.c (clear_installed_tracepoints): Uninstall disabled
10367 tracepoints.
10368 (cmd_qtenable_disable): New.
10369 (cmd_qtstart): Install tracepoints even if disabled.
10370 (handle_tracepoint_general_set): Add call to cmd_qtenable_disable on
10371 receiving a QTEnable or QTDisable packet.
10372 (gdb_collect): Skip data collection if fast tracepoint is disabled.
10373 (ust_marker_to_static_tracepoint): Do not ignore disabled static
10374 tracepoints.
10375 (gdb_probe): Skip data collection if static tracepoint is disabled.
10376
10377 2011-05-10 Doug Evans <dje@google.com>
10378
10379 * thread-db.c (thread_db_handle_monitor_command): Handle elided path.
10380
10381 2011-05-04 Doug Evans <dje@google.com>
10382
10383 * linux-low.c (linux_join): Skip process lookup.
10384 * spu-low.c (spu_join): Ditto.
10385 * server.c (join_inferiors_callback): Delete.
10386 (process_serial_event): For 'D' packet (detach) call join_inferior
10387 directly.
10388
10389 2011-05-04 Joseph Myers <joseph@codesourcery.com>
10390
10391 * README: Don't mention xscale*-*-linux*.
10392 * configure.srv (xscale*-*-linux*): Don't handle target.
10393
10394 2011-04-27 Nathan Froyd <froydnj@codesourcery.com>
10395
10396 * linux-x86-low.c (amd64_emit_const): Call memcpy instead of
10397 casting pointers.
10398 (amd64_emit_reg, amd64_emit_int_call_1, amd64_emit_void_call_2):
10399 (i386_emit_const, i386_emit_reg, i386_emit_int_call_1):
10400 (i386_emit_void_call_2): Likewise.
10401
10402 2011-04-26 Yao Qi <yao@codesourcery.com>
10403
10404 * linux-low.c: Move common macros to linux-ptrace.h.
10405 Include linux-ptrace.h.
10406 * Makefile.in (linux_ptrace_h): New.
10407 (linux-low.o): Depends on linux-ptrace.h.
10408
10409 2011-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
10410
10411 * remote-utils.c (handle_accept_event): Close LISTEN_DESC only if
10412 RUN_ONCE. Comment for the LISTEN_DESC delete_file_handler call.
10413 (remote_prepare): New function with most of the TCP code from ...
10414 (remote_open): ... here. Detect PORT here unconditionally. Move also
10415 setting transport_is_reliable.
10416 * server.c (run_once): New variable.
10417 (gdbserver_usage): Document it.
10418 (main): Set run_once for `--once'. Call remote_prepare. Exit after
10419 the first run if RUN_ONCE.
10420 * server.h (run_once, remote_prepare): New declarations.
10421
10422 2011-04-19 Tom Tromey <tromey@redhat.com>
10423
10424 * win32-low.c (handle_load_dll): Remove duplicate "the".
10425
10426 2011-04-07 Pierre Muller <muller@ics.u-strasbg.fr>
10427
10428 Remove support for old Cygwin 1.5 versions.
10429 * win32-low.c (win32_create_inferior): Use new cygwin_path_list
10430 function to avoid warning.
10431 (win32_add_one_solib): Use cygwin_conv_path function to avoid
10432 warning.
10433
10434 2011-03-18 Pierre Muller <muller@ics.u-strasbg.fr>
10435
10436 * gdbserver/server.h (Macro _): Define it if not available.
10437
10438 2011-03-14 Michael Snyder <msnyder@vmware.com>
10439
10440 * hostio.c (handle_close): Remove unnecessary null test.
10441
10442 2011-03-10 Joel Brobecker <brobecker@adacore.com>
10443
10444 * Makefile.in (maintainer-clean realclean distclean): Remove
10445 "make ... subdir_do" command.
10446
10447 2011-03-10 Michael Snyder <msnyder@vmware.com>
10448
10449 * tracepoint.c (tracepoint_finish_step): Fix loop variable.
10450
10451 * server.c (handle_v_run): Free alloced buffer on early return.
10452
10453 2011-03-09 Yao Qi <yao@codesourcery.com>
10454
10455 Revert:
10456 2011-03-04 Yao Qi <yao@codesourcery.com>
10457
10458 * Makefile.in: Remove GNU make feature --directory.
10459
10460 2011-03-05 Yao Qi <yao@codesourcery.com>
10461
10462 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
10463 (subdir_do): New make target. Copied from gdb/Makefile.
10464 (maintainer-clean, realclean, distclean, clean): Call corresponding
10465 make targets in common/Makefile.
10466
10467 2011-02-11 Yao Qi <yao@codesourcery.com>
10468
10469 * configure.ac: Call AC_PROG_RANLIB.
10470 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
10471 * configure: Regenerate.
10472
10473 2011-03-07 Jan Kratochvil <jan.kratochvil@redhat.com>
10474
10475 * remote-utils.c (putpkt_binary_1): Calculate BUF2 size dynamically.
10476
10477 2011-03-06 Yao Qi <yao@codesourcery.com>
10478
10479 * Makefile.in (REQUIRED_SUBDIRS): Remove $(LIBCOMMON_DIR).
10480
10481 2011-03-05 Yao Qi <yao@codesourcery.com>
10482
10483 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
10484 (subdir_do): New make target. Copied from gdb/Makefile.
10485 (maintainer-clean, realclean, distclean, clean): Call corresponding
10486 make targets in common/Makefile.
10487
10488 2011-03-04 Yao Qi <yao@codesourcery.com>
10489
10490 * Makefile.in: Remove GNU make feature --directory.
10491
10492 2011-03-04 Michael Snyder <msnyder@vmware.com>
10493
10494 * server.c (queue_stop_reply): Call xmalloc not malloc.
10495
10496 2011-03-02 Michael Snyder <msnyder@vmware.com>
10497
10498 * linux-arm-low.c (arm_arch_setup): Replace malloc with xmalloc.
10499
10500 2011-02-28 Michael Snyder <msnyder@vmware.com>
10501
10502 * tracepoint.c (cmd_qtv): Discard unused value 'packet'.
10503 (cmd_qtframe): Ditto.
10504 (cmd_qtbuffer): Ditto.
10505 (cmd_bigqtbuffer): Ditto.
10506
10507 * utils.c (decimal2str): Initialize 'width' to nine, then
10508 don't mess with it.
10509
10510 2011-02-28 Ulrich Weigand <uweigand@de.ibm.com>
10511
10512 * hostio.c (require_data): Free *data, not data.
10513
10514 2011-02-28 Jan Kratochvil <jan.kratochvil@redhat.com>
10515
10516 * hostio.c (require_data): Use free, not xfree.
10517
10518 2011-02-27 Michael Snyder <msnyder@vmware.com>
10519
10520 * server.c (handle_query): Discard unused value.
10521
10522 * hostio.c (require_data): Free malloc memory before returning
10523 error.
10524
10525 2011-02-26 Michael Snyder <msnyder@vmware.com>
10526
10527 * linux-low.c (list_threads): Call closedir for dirent.
10528
10529 2011-02-27 Michael Snyder <msnyder@vmware.com>
10530
10531 * i386-low.c (i386-length_and_rw_bits): Comment the fact that
10532 a case statement falls through.
10533
10534 * linux-low.c (linux_xfer_siginfo): Fix fencepost error.
10535
10536 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Fix fencepost error
10537 in comparison.
10538
10539 2011-02-26 Michael Snyder <msnyder@vmware.com>
10540
10541 * utils.c (decimal2str): Eliminate dead code and dead param.
10542 (pulongest): Drop dead param from call to decimal2str.
10543 (plongest): Ditto.
10544
10545 2011-02-24 Joel Brobecker <brobecker@adacore.com>
10546
10547 Revert the following patch (not approved yet):
10548 2011-02-21 Hui Zhu <teawater@gmail.com>
10549 * tracepoint.c (tp_printf): New function.
10550 (eval_agent_expr): Handle gdb_agent_op_printf.
10551
10552 2011-02-21 Hui Zhu <teawater@gmail.com>
10553
10554 * tracepoint.c (tp_printf): New function.
10555 (eval_agent_expr): Handle gdb_agent_op_printf.
10556
10557 2011-02-18 Tom Tromey <tromey@redhat.com>
10558
10559 * Makefile.in (tracepoint-ipa.o): Depend on ax.def.
10560 (tracepoint.o): Likewise.
10561 * tracepoint.c (enum gdb_agent_op): Use ax.def.
10562 (gdb_agent_op_names): Likewise.
10563
10564 2011-02-18 Tom Tromey <tromey@redhat.com>
10565
10566 * tracepoint.c (enum gdb_agent_op) <gdb_agent_op_pick,
10567 gdb_agent_op_rot>: New constants.
10568 (gdb_agent_op_names): Add pick and roll.
10569 (eval_agent_expr) <gdb_agent_op_pick, gdb_agent_op_rot>: New
10570 cases.
10571
10572 2011-02-15 Jan Kratochvil <jan.kratochvil@redhat.com>
10573
10574 * aclocal.m4: Regenerated with aclocal-1.11.1.
10575
10576 2011-02-14 Pedro Alves <pedro@codesourcery.com>
10577
10578 * server.c (handle_qxfer_traceframe_info): New.
10579 (qxfer_packets): Register "traceframe-info".
10580 (handle_query): Report support for qXfer:traceframe-info:read+.
10581 * tracepoint.c (match_blocktype): New.
10582 (traceframe_find_block_type): Rename to ...
10583 (traceframe_walk_blocks): ... this. Add callback filter argument,
10584 and use it.
10585 (traceframe_find_block_type): New, reimplemented on top of
10586 traceframe_walk_blocks.
10587 (build_traceframe_info_xml): New.
10588 (traceframe_read_info): New.
10589 * server.h (traceframe_read_info): Declare.
10590
10591 2011-02-11 Yao Qi <yao@codesourcery.com>
10592
10593 * configure.ac: Call AC_PROG_RANLIB.
10594 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
10595 * configure: Regenerate.
10596
10597 2011-02-07 Pedro Alves <pedro@codesourcery.com>
10598
10599 * server.c (gdb_read_memory): Change return semantics to allow
10600 partial transfers.
10601 (handle_search_memory_1): Adjust.
10602 (process_serial_event) <'m' packet>: Handle partial transfers.
10603 * tracepoint.c (traceframe_read_mem): Handle partial transfers.
10604
10605 2011-01-28 Pedro Alves <pedro@codesourcery.com>
10606
10607 * regcache.c (init_register_cache): Initialize
10608 regcache->register_status.
10609 (free_register_cache): Release regcache->register_status.
10610 (regcache_cpy): Copy register_status.
10611 (registers_to_string): Print 'x's for unavailable registers.
10612 (supply_register): Mark the register's status valid or
10613 unavailable, depending on whether a buffer was passed in or not.
10614 (supply_register_zeroed): New.
10615 (supply_regblock): Mark the registers' status valid or
10616 unavailable, depending on whether a buffer was passed in or not.
10617 * regcache.h (REG_UNAVAILABLE, REG_VALID): New defines.
10618 (struct regcache): New `register_status' field.
10619 (supply_register_zeroed): Declare.
10620 * i387-fp.c (i387_xsave_to_cache): Zero out registers using
10621 supply_register_zeroed, rather than passing a NULL buffer to
10622 supply_register.
10623 * tracepoint.c (fetch_traceframe_registers): Update comment.
10624
10625 2011-01-28 Pedro Alves <pedro@codesourcery.com>
10626
10627 * i387-fp.c (i387_xsave_to_cache): Make passing NULL as register
10628 buffer explicit.
10629
10630 2011-01-25 Pedro Alves <pedro@codesourcery.com>
10631
10632 * server.h (decode_xfer_write): Change prototype.
10633 * remote-utils.c (decode_xfer_write): Remove `annex' parameter,
10634 and don't extract the annex here.
10635 * server.c (decode_xfer_read): Remove `annex' parameter,
10636 and don't extract the annex here.
10637 (decode_xfer): New.
10638 (struct qxfer): New.
10639 (handle_qxfer_auxv, handle_qxfer_features, handle_qxfer_libraries)
10640 (handle_qxfer_osdata, handle_qxfer_siginfo, handle_qxfer_spu)
10641 (handle_qxfer_statictrace): New functions, abstracted out from
10642 handle_query, and made to use the struct qxfer interface.
10643 (handle_threads_qxfer_proper): Rename to ...
10644 (handle_qxfer_threads_proper): ... this.
10645 (handle_threads_qxfer): Rename to ...
10646 (handle_qxfer_threads): ... this. Adjust.
10647 (qxfer_packets): New array.
10648 (handle_qxfer): New function.
10649 (handle_query): Use handle_qxfer.
10650
10651 2011-01-05 Michael Snyder <msnyder@msnyder-server.eng.vmware.com>
10652
10653 * gdbreplay.c: Shorten lines of >= 80 columns.
10654 * linux-low.c: Ditto.
10655 * linux-ppc-low.c: Ditto.
10656 * linux-s390-low.c: Ditto.
10657 * linux-sparc-low.c: Ditto.
10658 * linux-x86-low.c: Ditto.
10659 * linux-xtensa-low.c: Ditto.
10660 * mem-break.c: Ditto.
10661 * nto-low.c: Ditto.
10662 * regcache.h: Ditto.
10663 * remote-utils.c: Ditto.
10664 * server.c: Ditto.
10665 * server.h: Ditto.
10666 * thread-db.c: Ditto.
10667 * tracepoint.c: Ditto.
10668 * utils.c: Ditto.
10669 * win32-low.h: Ditto.
10670
10671 2011-01-05 Joel Brobecker <brobecker@adacore.com>
10672
10673 * gdbserver/configure.ac, gdbserver/gdbserver.1: Copyright year
10674 update.
10675
10676 2011-01-01 Joel Brobecker <brobecker@adacore.com>
10677
10678 * server.c (gdbserver_version): Update copyright year in version
10679 output.
10680 * gdbreplay.c (gdbreplay_version): Ditto.
10681
10682 2010-12-29 Jie Zhang <jie.zhang@analog.com>
10683
10684 * configure.srv (bfin-*-*linux*): Handle Blackfin/Linux targets.
10685 * linux-bfin-low.c: New file.
10686 * linux-low.c: Define PT_TEXT_ADDR, PT_TEXT_END_ADDR, and
10687 PT_DATA_ADDR for BFIN targets.
10688 * Makefile.in (SFILES): Add linux-bfin-low.c.
10689 (clean): Remove reg-bfin.c.
10690 (linux-bfin-low.o, reg-bfin.o, reg-bfin.c): New targets.
10691 * README: Mention supported Blackfin targets.
10692
10693 2010-12-23 Mike Frysinger <vapier@gentoo.org>
10694
10695 * .gitignore: New file.
10696
10697 2010-11-16 Mike Frysinger <vapier@gentoo.org>
10698
10699 * linux-low.c (linux_tracefork_child): Add char* cast to arg.
10700
10701 2010-10-22 Jie Zhang <jie@codesourcery.com>
10702
10703 * Makefile.in: Add FLAGS_TO_PASS variable.
10704 (install): Remove dependency of install-only and recursively
10705 invoke make for install-only.
10706
10707 2010-10-04 Doug Evans <dje@google.com>
10708
10709 * Makefile.in (uninstall): Use $(DESTDIR).
10710
10711 2010-09-24 Pedro Alves <pedro@codesourcery.com>
10712
10713 PR gdb/11842
10714
10715 * linux-x86-low.c (compat_siginfo_from_siginfo)
10716 (siginfo_from_compat_siginfo): Also copy si_pid and si_uid when
10717 si_code is < 0. Check for si_code == SI_TIMER before checking for
10718 si_code < 0.
10719
10720 2010-09-13 Joel Brobecker <brobecker@adacore.com>
10721
10722 * lynx-i386-low.c: New file.
10723 * configure.srv: Add handling of i[34567]86-*-lynxos* targets.
10724
10725 2010-09-13 Joel Brobecker <brobecker@adacore.com>
10726
10727 * lynx-low.c (ptrace_request_to_str): Remove handling for
10728 request values that have been removed in LynxOS 5.x.
10729
10730 2010-09-13 Joel Brobecker <brobecker@adacore.com>
10731
10732 * lynx-low.c, lynx-ppc-loc.c: Include <sys/ptrace.h> instead of
10733 <ptrace.h>
10734
10735 2010-09-09 Nathan Sidwell <nathan@codesourcery.com>
10736
10737 * configure.ac: Add --enable-inprocess-agent option.
10738 * configure: Rebuilt.
10739
10740 2010-09-06 Yao Qi <yao@codesourcery.com>
10741
10742 * linux-low.c (linux_kill): Remove unused variable.
10743 (linux_stabilize_threads): Likewise.
10744 * server.c (start_inferior): Likewise.
10745 (queue_stop_reply_callback): Likewise.
10746 * tracepoint.c (do_action_at_tracepoint): Likewise.
10747
10748 2010-09-06 Yao Qi <yao@codesourcery.com>
10749
10750 * linux-low.c (maybe_move_out_of_jump_pad): Restore current_inferior
10751 on return.
10752
10753 2010-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
10754
10755 * target.c (mywait) <TARGET_WAITKIND_EXITED>: Fix to use INTEGER.
10756
10757 2010-09-06 Pedro Alves <pedro@codesourcery.com>
10758
10759 * Makefile.in (install-only): Replace $IPA_DEPFILES with
10760 "$(IPA_DEPFILES)".
10761
10762 2010-09-01 Joel Brobecker <brobecker@adacore.com>
10763
10764 * gdbserver/lynx-low.c, gdbserver/lynx-low.h,
10765 gdbserver/lynx-ppc-low.c: New files.
10766 * Makefile.in (lynx_low_h): New variable.
10767 (lynx-low.o, lynx-ppc-low.o): New rules.
10768 * configure.ac: On LynxOS, link with -lnetinet.
10769 * configure.srv: Add handling of powerpc-*-lynxos* targets.
10770 * configure: regenerate.
10771
10772 2010-09-01 Joel Brobecker <brobecker@adacore.com>
10773
10774 * Makefile.in (vasprintf.o, vsnprintf.o): New rules.
10775 * configure.ac: Add check for vasprintf and vsnprintf.
10776 * configure, config.in: Regenerate.
10777 * server.h (vasprintf, vsnprintf): Add conditional declarations.
10778
10779 2010-09-01 Joel Brobecker <brobecker@adacore.com>
10780
10781 * gdbreplay.c: Move include of alloca.h up, next to include of
10782 malloc.h.
10783 * server.h: Add include of malloc.h.
10784 * mem-break.c: Remove include of malloc.h.
10785 * server.c, tracepoint.c, utils.c, win32-low.c: Likewise.
10786
10787 2010-09-01 Joel Brobecker <brobecker@adacore.com>
10788
10789 * Makefile.in (memmem.o): Build with -Wno-error.
10790
10791 2010-09-01 Joel Brobecker <brobecker@adacore.com>
10792
10793 * utils.c (xsnprintf): Make non-static.
10794 * server.h: Add xsnprintf declaration.
10795 * linux-low.c, nto-low.c, target.c, thread-db.c, tracepoint.c:
10796 replace calls to snprintf by calls to xsnprintf throughout.
10797
10798 2010-09-01 Joel Brobecker <brobecker@adacore.com>
10799
10800 * configure.ac: Add configure check for alloca.
10801 * configure, config.in: Regenerate.
10802 * server.h: Include alloca.h if it exists.
10803 * gdbreplay.c: Include alloca.h if it exists.
10804
10805 2010-08-28 Pedro Alves <pedro@codesourcery.com>
10806
10807 * linux-low.c (__SIGRTMIN): Define if not already defined.
10808 (linux_create_inferior): Check for __ANDROID__ rather than
10809 __SIGRTMIN.
10810 (enqueue_one_deferred_signal): Don't requeue non-RT signals that
10811 are already deferred.
10812 (linux_wait_1): Check for __ANDROID__ rather than __SIGRTMIN.
10813 (linux_resume_one_thread): Don't queue a SIGSTOP if the lwp is
10814 stopped and already has a pending signal to report.
10815 (proceed_one_lwp): : Don't queue a SIGSTOP if the lwp already has
10816 a pending signal to report or is moving out of a jump pad.
10817 (linux_init_signals): Check for __ANDROID__ rather than
10818 __SIGRTMIN.
10819
10820 2010-08-28 Pedro Alves <pedro@codesourcery.com>
10821
10822 * linux-low.c (linux_stabilize_threads): Wrap debug output in a
10823 debug_threads check. Avoid a linear search when not doing debug
10824 output.
10825
10826 2010-08-27 Pedro Alves <pedro@codesourcery.com>
10827
10828 * event-loop.c (event_handle_func): Adjust to use gdb_fildes_t.
10829 (struct gdb_event) <fd>: Change type to gdb_fildes_t.
10830 (struct file_handler) <fd>: Change type to gdb_fildes_t.
10831 (process_event): Change local fd's type to gdb_fildes_t.
10832 (create_file_handler): Adjust prototype.
10833 (delete_file_handler): Adjust prototype.
10834 (handle_file_event): Adjust prototype. Use pfildes.
10835 (create_file_event): Adjsut prototype.
10836 * remote-utils.c (remote_desc, listen_desc): Change type to
10837 gdb_fildes_t.
10838 * server.h: New gdb_fildes_t typedef.
10839 [USE_WIN32API]: Include winsock2.h.
10840 (delete_file_handler, add_file_handler): Adjust prototypes.
10841 (pfildes): Declare.
10842 * utils.c (pfildes): New.
10843
10844 2010-08-27 Pedro Alves <pedro@codesourcery.com>
10845
10846 * configure.ac (build_warnings): Add -Wno-char-subscripts.
10847 * configure: Regenerate.
10848
10849 2010-08-27 Pedro Alves <pedro@codesourcery.com>
10850
10851 * linux-low.c (linux_unprepare_to_access_memory): Rename to ...
10852 (linux_done_accessing_memory): ... this.
10853 (linux_target_ops): Adjust.
10854 * linux-x86-low.c (x86_insert_point, x86_remove_point): Adjust.
10855 * nto-low.c (nto_target_ops): Adjust comment.
10856 * server.c (gdb_read_memory, gdb_write_memory): Adjust.
10857 * spu-low.c (spu_target_ops): Adjust comment.
10858 * target.h (target_ops): Rename unprepare_to_access_memory field
10859 to done_accessing_memory.
10860 (unprepare_to_access_memory): Rename to ...
10861 (done_accessing_memory): ... this.
10862
10863 2010-08-26 Pedro Alves <pedro@codesourcery.com>
10864
10865 * linux-low.c (linux_prepare_to_access_memory): New.
10866 (linux_unprepare_to_access_memory): New.
10867 (linux_target_ops): Install them.
10868 * server.c (read_memory): Rename to ...
10869 (gdb_read_memory): ... this. Use
10870 prepare_to_access_memory/prepare_to_access_memory.
10871 (write_memory): Rename to ...
10872 (gdb_write_memory): ... this. Use
10873 prepare_to_access_memory/prepare_to_access_memory.
10874 (handle_search_memory_1): Adjust.
10875 (process_serial_event): Adjust.
10876 * target.h (struct target_ops): New fields
10877 prepare_to_access_memory and unprepare_to_access_memory.
10878 (prepare_to_access_memory, unprepare_to_access_memory): New.
10879 * linux-x86-low.c (x86_insert_point, x86_remove_point): Use
10880 prepare_to_access_memory/prepare_to_access_memory.
10881 * nto-low.c (nto_target_ops): Adjust.
10882 * spu-low.c (spu_target_ops): Adjust.
10883 * win32-low.c (win32_target_ops): Adjust.
10884
10885 2010-08-26 Pedro Alves <pedro@codesourcery.com>
10886
10887 * Makefile.in (WARN_CFLAGS): Get it from configure.
10888 (WERROR_CFLAGS): New.
10889 (INTERNAL_CFLAGS): Add WERROR_CFLAGS.
10890 * configure.ac: Introduce --enable-werror, which adds -Werror to
10891 the compiler command line. Enabled by default. Disable with
10892 --disable-werror. Add -Wdeclaration-after-statement
10893 Wpointer-arith and -Wformat-nonliteral to warning flags.
10894 * configure: Regenerate.
10895
10896 2010-08-26 Pedro Alves <pedro@codesourcery.com>
10897
10898 * mem-break.c [HAVE_MALLOC_H]: Include malloc.h.
10899
10900 2010-08-26 Pedro Alves <pedro@codesourcery.com>
10901
10902 * gdbreplay.c (remote_error): New.
10903 (gdbchar): New.
10904 (expect): Use gdbchar. Check for error reading from GDB.
10905 Clarify sync error output.
10906 (play): Check for errors writing to GDB.
10907 * linux-low.c (sigchld_handler): Really ignore `write' errors.
10908 * remote-utils.c (getpkt): Check for errors writing to the remote
10909 descriptor.
10910
10911 2010-08-25 Pedro Alves <pedro@codesourcery.com>
10912
10913 * linux-low.c (linux_wait_1): Move non-debugging code out of
10914 `debug_threads' control.
10915
10916 2010-08-25 Pedro Alves <pedro@codesourcery.com>
10917
10918 * linux-low.c (linux_wait_1): Don't set last_status here.
10919 * server.c (push_event, queue_stop_reply_callback): Assert we're
10920 not pushing a TARGET_WAITKIND_IGNORE event.
10921 (start_inferior, start_inferior, attach_inferior, handle_v_cont)
10922 (myresume, handle_target_event): Set the thread's last_resume_kind
10923 and last_status from the target returned status.
10924
10925 2010-08-25 Pedro Alves <pedro@codesourcery.com>
10926
10927 PR threads/10729
10928
10929 * linux-x86-low.c (update_debug_registers_callback): New.
10930 (i386_dr_low_set_addr): Use it.
10931 (i386_dr_low_get_addr): New.
10932 (i386_dr_low_set_control): Use update_debug_registers_callback.
10933 (i386_dr_low_get_control): New.
10934 (i386_dr_low_get_status): Adjust.
10935 * linux-low.c (linux_stop_lwp): New.
10936 * linux-low.h (linux_stop_lwp): Declare.
10937
10938 * i386-low.c (I386_DR_GET_RW_LEN): Take the dr7 contents as
10939 argument instead of a i386_debug_reg_state.
10940 (I386_DR_WATCH_HIT): Take the dr6 contents as argument instead of
10941 a i386_debug_reg_state.
10942 (i386_insert_aligned_watchpoint): Adjust.
10943 (i386_remove_aligned_watchpoint): Adjust.
10944 (i386_low_stopped_data_address): Read the debug registers from the
10945 inferior instead of from the mirrors.
10946 * i386-low.h (struct i386_debug_reg_state): Extend comment.
10947 (i386_dr_low_get_addr): Declare.
10948 (i386_dr_low_get_control): Declare.
10949 (i386_dr_low_get_status): Change prototype.
10950
10951 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): New globals.
10952 (i386_dr_low_get_addr): New.
10953 (i386_dr_low_get_control): New.
10954 (i386_dr_low_get_status): Adjust prototype. Return
10955 dr_status_mirror.
10956 (i386_initial_stuff): Clear dr_status_mirror and
10957 dr_control_mirror.
10958 (i386_get_thread_context): Adjust.
10959 (i386_set_thread_context): Adjust.
10960 (i386_thread_added): Adjust.
10961
10962 2010-08-24 Pedro Alves <pedro@codesourcery.com>
10963
10964 * linux-low.h (linux_thread_area): Delete declaration.
10965
10966 2010-08-11 Thomas Schwinge <thomas@codesourcery.com>
10967
10968 * linux-low.c (linux_wait_1): Correctly return the ptid of the child
10969 after its termination.
10970
10971 2010-08-09 Pedro Alves <pedro@codesourcery.com>
10972
10973 * linux-low.c (gdb_wants_lwp_stopped): Delete.
10974 (gdb_wants_all_stopped): Delete.
10975 (linux_wait_1): Don't call them.
10976 * server.c (handle_v_cont): Tag all threads as want-stopped.
10977 (gdb_wants_thread_stopped): Fix comments. Tag the thread that
10978 stopped as "client-wants-stopped".
10979
10980 2010-07-31 Pedro Alves <pedro@codesourcery.com>
10981
10982 * Makefile.in (signals_h): New.
10983 (server_h): Depend on it.
10984 (server.o): Don't depend on $(signals_def).
10985 (signals.o): Depend on $(signals_def).
10986
10987 2010-07-31 Jan Kratochvil <jan.kratochvil@redhat.com>
10988
10989 * Makefile.in (signals_def): New.
10990 (server_h): Append include/gdb/signals.h and signals_def.
10991 (server.o): Append signals_def.
10992
10993 2010-07-25 Jan Kratochvil <jan.kratochvil@redhat.com>
10994
10995 * server.c (handle_target_event): Use target_signal_to_host for
10996 resume_info.sig initialization.
10997 * target.h (struct thread_resume) <sig>: New comment.
10998
10999 2010-07-20 Ozkan Sezer <sezeroz@gmail.com>
11000
11001 * server.c (handle_query): strcpy() the returned string from paddress()
11002 instead of sprintf().
11003 * utils.c (paddress): Return phex_nz().
11004
11005 2010-07-07 Joel Brobecker <brobecker@adacore.com>
11006
11007 * server.c (handle_v_cont): Call mourn_inferior if process
11008 just exited.
11009 (myresume): Likewise.
11010
11011 2010-07-01 Pedro Alves <pedro@codesourcery.com>
11012
11013 Static tracepoints, and integration with UST.
11014
11015 * configure.ac: Handle --with-ust. substitute ustlibs and ustinc.
11016 * mem-break.c (uninsert_all_breakpoints)
11017 (reinsert_all_breakpoints): New.
11018 * mem-break.h (reinsert_all_breakpoints, uninsert_all_breakpoints):
11019 * tracepoint.c (ust_loaded, helper_thread_id, cmd_buf): New.
11020 (gdb_agent_ust_loaded, helper_thread_id)
11021 (gdb_agent_helper_thread_id): New macros.
11022 (struct ipa_sym_addresses): Add addr_ust_loaded,
11023 addr_helper_thread_id, addr_cmd_buf.
11024 (symbol_list): Add ust_loaded, helper_thread_id, cmd_buf.
11025 (in_process_agent_loaded_ust): New.
11026 (write_e_ust_not_loaded): New.
11027 (maybe_write_ipa_ust_not_loaded): New.
11028 (struct collect_static_trace_data_action): New.
11029 (enum tracepoint_type) <static_tracepoint>: New.
11030 (struct tracepoint) <handle>: Mention static tracepoints.
11031 (struct static_tracepoint_ctx): New.
11032 (CMD_BUF_SIZE): New.
11033 (add_tracepoint_action): Handle static tracepoint actions.
11034 (unprobe_marker_at): New.
11035 (clear_installed_tracepoints): Handle static tracepoints.
11036 (cmd_qtdp): Handle static tracepoints.
11037 (probe_marker_at): New.
11038 (cmd_qtstart): Handle static tracepoints.
11039 (response_tracepoint): Handle static tracepoints.
11040 (cmd_qtfstm, cmd_qtsstm, cmd_qtstmat): New.
11041 (handle_tracepoint_query): Handle qTfSTM, qTsSTM and qTSTMat.
11042 (get_context_regcache): Handle static tracepoints.
11043 (do_action_at_tracepoint): Handle static tracepoint actions.
11044 (traceframe_find_block_type): Handle static trace data blocks.
11045 (traceframe_read_sdata): New.
11046 (download_tracepoints): Download static tracepoint actions.
11047 [HAVE_UST] Include ust/ust.h, dlfcn.h, sys/socket.h, and sys/un.h.
11048 (GDB_PROBE_NAME): New.
11049 (ust_ops): New.
11050 (GET_UST_SYM): New.
11051 (USTF): New.
11052 (dlsym_ust): New.
11053 (ust_marker_to_static_tracepoint): New.
11054 (gdb_probe): New.
11055 (collect_ust_data_at_tracepoint): New.
11056 (gdb_ust_probe): New.
11057 (UNIX_PATH_MAX, SOCK_DIR): New.
11058 (gdb_ust_connect_sync_socket): New.
11059 (resume_thread, stop_thread): New.
11060 (run_inferior_command): New.
11061 (init_named_socket): New.
11062 (gdb_ust_socket_init): New.
11063 (cstr_to_hexstr): New.
11064 (next_st): New.
11065 (first_marker, next_marker): New.
11066 (response_ust_marker): New.
11067 (cmd_qtfstm, cmd_qtsstm): New.
11068 (unprobe_marker_at, probe_marker_at): New.
11069 (cmd_qtstmat, gdb_ust_thread): New.
11070 (gdb_ust_init): New.
11071 (initialize_tracepoint_ftlib): Call gdb_ust_init.
11072 * linux-amd64-ipa.c [HAVE_UST]: Include ust/processor.h
11073 (ST_REGENTRY): New.
11074 (x86_64_st_collect_regmap): New.
11075 (X86_64_NUM_ST_COLLECT_GREGS): New.
11076 (AMD64_RIP_REGNUM): New.
11077 (supply_static_tracepoint_registers): New.
11078 * linux-i386-ipa.c [HAVE_UST]: Include ust/processor.h
11079 (ST_REGENTRY): New.
11080 (i386_st_collect_regmap): New.
11081 (i386_NUM_ST_COLLECT_GREGS): New.
11082 (supply_static_tracepoint_registers): New.
11083 * server.c (handle_query): Handle qXfer:statictrace:read.
11084 <qSupported>: Report support for StaticTracepoints, and
11085 qXfer:statictrace:read features.
11086 * server.h (traceframe_read_sdata)
11087 (supply_static_tracepoint_registers): Declare.
11088 * remote-utils.c (convert_int_to_ascii, hexchars, ishex, tohex)
11089 (unpack_varlen_hex): Include in IPA build.
11090 * Makefile.in (ustlibs, ustinc): New.
11091 (IPA_OBJS): Add remote-utils-ipa.o.
11092 ($(IPA_LIB)): Link -ldl and -lpthread.
11093 (UST_CFLAGS): New.
11094 (IPAGENT_CFLAGS): Add UST_CFLAGS.
11095 * config.in, configure: Regenerate.
11096
11097 2010-06-20 Ian Lance Taylor <iant@google.com>
11098 Pedro Alves <pedro@codesourcery.com>
11099
11100 * linux-x86-low.c (always_true): Delete.
11101 (EMIT_ASM, EMIT_ASM32): Use an uncondition asm jmp instead of
11102 trying to fool the compiler with always_true.
11103
11104 2010-06-20 Pedro Alves <pedro@codesourcery.com>
11105
11106 * tracepoint.c (condition_true_at_tracepoint): Don't run compiled
11107 conditions in gdbserver.
11108
11109 2010-06-19 Ulrich Weigand <uweigand@de.ibm.com>
11110
11111 * spu-low.c (spu_read_memory): Wrap around local store limit.
11112 (spu_write_memory): Likewise.
11113
11114 2010-06-15 Pedro Alves <pedro@codesourcery.com>
11115
11116 * linux-x86-low.c (amd64_emit_const, amd64_emit_void_call_2)
11117 (i386_emit_const, i386_emit_void_call_2): Replace int64_t uses with
11118 LONGEST uses.
11119 * server.h (struct emit_ops): Replace int64_t uses with LONGEST
11120 uses.
11121 * tracepoint.c (emit_const, emit_void_call_2): Replace int64_t
11122 uses with LONGEST uses.
11123
11124 2010-06-14 Stan Shebs <stan@codesourcery.com>
11125 Pedro Alves <pedro@codesourcery.com>
11126
11127 Bytecode compiler.
11128
11129 * linux-x86-low.c: Include limits.h.
11130 (add_insns): New.
11131 (always_true): New.
11132 (EMIT_ASM): New.
11133 (EMIT_ASM32): New.
11134 (amd64_emit_prologue, amd64_emit_epilogue, amd64_emit_add)
11135 (amd64_emit_sub, amd64_emit_mul, amd64_emit_lsh)
11136 (amd64_emit_rsh_signed, amd64_emit_rsh_unsigned, amd64_emit_ext,
11137 (amd64_emit_log_not, amd64_emit_bit_and, amd64_emit_bit_or)
11138 (amd64_emit_bit_xor, amd64_emit_bit_not, amd64_emit_equal,
11139 (amd64_emit_less_signed, amd64_emit_less_unsigned, amd64_emit_ref,
11140 (amd64_emit_if_goto, amd64_emit_goto, amd64_write_goto_address)
11141 (amd64_emit_const, amd64_emit_call, amd64_emit_reg)
11142 (amd64_emit_pop, amd64_emit_stack_flush, amd64_emit_zero_ext)
11143 (amd64_emit_swap, amd64_emit_stack_adjust, amd64_emit_int_call_1)
11144 (amd64_emit_void_call_2): New.
11145 (amd64_emit_ops): New.
11146 (i386_emit_prologue, i386_emit_epilogue, i386_emit_add)
11147 (i386_emit_sub,i386_emit_mul, i386_emit_lsh, i386_emit_rsh_signed)
11148 (i386_emit_rsh_unsigned, i386_emit_ext, i386_emit_log_not)
11149 (i386_emit_bit_and, i386_emit_bit_or, i386_emit_bit_xor)
11150 (i386_emit_bit_not, i386_emit_equal, i386_emit_less_signed)
11151 (i386_emit_less_unsigned, i386_emit_ref, i386_emit_if_goto)
11152 (i386_emit_goto, i386_write_goto_address, i386_emit_const)
11153 (i386_emit_call, i386_emit_reg, i386_emit_pop)
11154 (i386_emit_stack_flush, i386_emit_zero_ext, i386_emit_swap)
11155 (i386_emit_stack_adjust, i386_emit_int_call_1)
11156 (i386_emit_void_call_2): New.
11157 (i386_emit_ops): New.
11158 (x86_emit_ops): New.
11159 (the_low_target): Install x86_emit_ops.
11160 * server.h (struct emit_ops): New.
11161 (get_raw_reg_func_addr): Declare.
11162 (current_insn_ptr, emit_error): Declare.
11163 * tracepoint.c (get_raw_reg, get_trace_state_variable_value)
11164 (set_trace_state_variable_value): New defines.
11165 (struct ipa_sym_addresses): New fields addr_get_raw_reg,
11166 addr_get_trace_state_variable_value and
11167 addr_set_trace_state_variable_value.
11168 (symbol_list): New fields for get_raw_reg,
11169 get_trace_state_variable_value and set_trace_state_variable_value.
11170 (condfn): New typedef.
11171 (struct tracepoint): New field `compiled_cond'.
11172 (do_action_at_tracepoint): Clear compiled_cond.
11173 (get_trace_state_variable_value, set_trace_state_variable_value):
11174 Export in the IPA.
11175 (condition_true_at_tracepoint): If there's a compiled condition,
11176 run that.
11177 (current_insn_ptr, emit_error): New globals.
11178 (struct bytecode_address): New.
11179 (get_raw_reg_func_addr): New.
11180 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul)
11181 (emit_lsh, emit_rsh_signed, emit_rsh_unsigned, emit_ext)
11182 (emit_log_not, emit_bit_and, emit_bit_or, emit_bit_xor)
11183 (emit_bit_not, emit_equal, emit_less_signed, emit_less_unsigned)
11184 (emit_ref, emit_if_goto, emit_goto, write_goto_address, emit_const)
11185 (emit_reg, emit_pop, emit_stack_flush, emit_zero_ext, emit_swap)
11186 (emit_stack_adjust, emit_int_call_1, emit_void_call_2): New.
11187 (compile_tracepoint_condition, compile_bytecodes): New.
11188 * target.h (emit_ops): Forward declare.
11189 (struct target_ops): New field emit_ops.
11190 (target_emit_ops): New.
11191 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): New.
11192 * linux-i386-ipa.c (gdb_agent_get_raw_reg): New.
11193 * linux-low.c (linux_emit_ops): New.
11194 (linux_target_ops): Install it.
11195 * linux-low.h (struct linux_target_ops): New field emit_ops.
11196
11197 2010-06-14 Ulrich Weigand <uweigand@de.ibm.com>
11198
11199 * linux-ppc-low.c (ppc_arch_setup): Use private regcache to test MSR.
11200 * linux-s390-low.c (ppc_arch_setup): Use private regcache to test PSW.
11201
11202 2010-06-01 Pedro Alves <pedro@codesourcery.com>
11203 Stan Shebs <stan@codesourcery.com>
11204
11205 * Makefile.in (IPA_DEPFILES, extra_libraries): New.
11206 (all): Depend on $(extra_libraries).
11207 (install-only): Install the IPA.
11208 (IPA_OBJS, IPA_LIB): New.
11209 (clean): Remove the IPA lib.
11210 (IPAGENT_CFLAGS): New.
11211 (tracepoint-ipa.o, utils-ipa.o, remote-utils-ipa.o)
11212 (regcache-ipa.o, i386-linux-ipa.o, linux-i386-ipa.o)
11213 (linux-amd64-ipa.o, amd64-linux-ipa.o): New rules.
11214 * linux-amd64-ipa.c, linux-i386-ipa.c: New files.
11215 * configure.ac: Check for atomic builtins support in the compiler.
11216 (IPA_DEPFILES, extra_libraries): Define.
11217 * configure.srv (ipa_obj): Add description.
11218 (ipa_i386_linux_regobj, ipa_amd64_linux_regobj): Define.
11219 (i[34567]86-*-linux*): Set ipa_obj.
11220 (x86_64-*-linux*): Set ipa_obj.
11221 * linux-low.c (stabilizing_threads): New.
11222 (supports_fast_tracepoints): New.
11223 (linux_detach): Stabilize threads before detaching.
11224 (handle_tracepoints): Handle internal tracing breakpoints. Assert
11225 the lwp is either not stabilizing, or is moving out of a jump pad.
11226 (linux_fast_tracepoint_collecting): New.
11227 (maybe_move_out_of_jump_pad): New.
11228 (enqueue_one_deferred_signal): New.
11229 (dequeue_one_deferred_signal): New.
11230 (linux_wait_for_event_1): If moving out of a jump pad, defer
11231 pending signals to later.
11232 (linux_stabilize_threads): New.
11233 (linux_wait_1): Check if threads need moving out of jump pads, and
11234 do it if so.
11235 (stuck_in_jump_pad_callback): New.
11236 (move_out_of_jump_pad_callback): New.
11237 (lwp_running): New.
11238 (linux_resume_one_lwp): Handle moving out of jump pads.
11239 (linux_set_resume_request): Dequeue deferred signals.
11240 (need_step_over_p): Also step over fast tracepoint jumps.
11241 (start_step_over): Also uninsert fast tracepoint jumps.
11242 (finish_step_over): Also reinsert fast tracepoint jumps.
11243 (linux_install_fast_tracepoint_jump): New.
11244 (linux_target_ops): Install linux_stabilize_threads and
11245 linux_install_fast_tracepoint_jump_pad.
11246 * linux-low.h (linux_target_ops) <get_thread_area,
11247 install_fast_tracepoint_jump_pad>: New fields.
11248 (struct lwp_info) <collecting_fast_tracepoint,
11249 pending_signals_to_report, exit_jump_pad_bkpt>: New fields.
11250 (linux_get_thread_area): Declare.
11251 * linux-x86-low.c (jump_insn): New.
11252 (x86_get_thread_area): New.
11253 (append_insns): New.
11254 (push_opcode): New.
11255 (amd64_install_fast_tracepoint_jump_pad): New.
11256 (i386_install_fast_tracepoint_jump_pad): New.
11257 (x86_install_fast_tracepoint_jump_pad): New.
11258 (the_low_target): Install x86_get_thread_area and
11259 x86_install_fast_tracepoint_jump_pad.
11260 * mem-break.c (set_raw_breakpoint_at): Use read_inferior_memory.
11261 (struct fast_tracepoint_jump): New.
11262 (fast_tracepoint_jump_insn): New.
11263 (fast_tracepoint_jump_shadow): New.
11264 (find_fast_tracepoint_jump_at): New.
11265 (fast_tracepoint_jump_here): New.
11266 (delete_fast_tracepoint_jump): New.
11267 (set_fast_tracepoint_jump): New.
11268 (uninsert_fast_tracepoint_jumps_at): New.
11269 (reinsert_fast_tracepoint_jumps_at): New.
11270 (set_breakpoint_at): Use write_inferior_memory.
11271 (uninsert_raw_breakpoint): Use write_inferior_memory.
11272 (check_mem_read): Mask out fast tracepoint jumps.
11273 (check_mem_write): Mask out fast tracepoint jumps.
11274 * mem-break.h (struct fast_tracepoint_jump): Forward declare.
11275 (set_fast_tracepoint_jump): Declare.
11276 (delete_fast_tracepoint_jump)
11277 (fast_tracepoint_jump_here, uninsert_fast_tracepoint_jumps_at)
11278 (reinsert_fast_tracepoint_jumps_at): Declare.
11279 * regcache.c: Don't compile many functions when building the
11280 in-process agent library.
11281 (init_register_cache) [IN_PROCESS_AGENT]: Don't allow allocating
11282 the register buffer in the heap.
11283 (free_register_cache): If the register buffer isn't owned by the
11284 regcache, don't free it.
11285 (set_register_cache) [IN_PROCESS_AGENT]: Don't re-alocate
11286 pre-existing register caches.
11287 * remote-utils.c (convert_int_to_ascii): Constify `from' parameter
11288 type.
11289 (convert_ascii_to_int): : Constify `from' parameter type.
11290 (decode_M_packet, decode_X_packet): Replace the `to' parameter by
11291 a `to_p' pointer to pointer parameter. If TO_P is NULL, malloc
11292 the needed buffer in-place.
11293 (relocate_instruction): New.
11294 * server.c (handle_query) <qSymbols>: If the target supports
11295 tracepoints, give it a chance of looking up symbols. Report
11296 support for fast tracepoints.
11297 (handle_status): Stabilize threads.
11298 (process_serial_event): Adjust.
11299 * server.h (struct fast_tracepoint_jump): Forward declare.
11300 (struct process_info) <fast_tracepoint_jumps>: New field.
11301 (convert_ascii_to_int, convert_int_to_ascii): Adjust.
11302 (decode_X_packet, decode_M_packet): Adjust.
11303 (relocate_instruction): Declare.
11304 (in_process_agent_loaded): Declare.
11305 (tracepoint_look_up_symbols): Declare.
11306 (struct fast_tpoint_collect_status): Declare.
11307 (fast_tracepoint_collecting): Declare.
11308 (force_unlock_trace_buffer): Declare.
11309 (handle_tracepoint_bkpts): Declare.
11310 (initialize_low_tracepoint)
11311 (supply_fast_tracepoint_registers) [IN_PROCESS_AGENT]: Declare.
11312 * target.h (struct target_ops) <stabilize_threads,
11313 install_fast_tracepoint_jump_pad>: New fields.
11314 (stabilize_threads, install_fast_tracepoint_jump_pad): New.
11315 * tracepoint.c [HAVE_MALLOC_H]: Include malloc.h.
11316 [HAVE_STDINT_H]: Include stdint.h.
11317 (trace_debug_1): Rename to ...
11318 (trace_vdebug): ... this.
11319 (trace_debug): Rename to ...
11320 (trace_debug_1): ... this. Add `level' parameter.
11321 (trace_debug): New.
11322 (ATTR_USED, ATTR_NOINLINE): New.
11323 (IP_AGENT_EXPORT): New.
11324 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
11325 (collecting, gdb_collect, stop_tracing, flush_trace_buffer)
11326 (about_to_request_buffer_space, trace_buffer_is_full)
11327 (stopping_tracepoint, expr_eval_result, error_tracepoint)
11328 (tracepoints, tracing, trace_buffer_ctrl, trace_buffer_ctrl_curr)
11329 (trace_buffer_lo, trace_buffer_hi, traceframe_read_count)
11330 (traceframe_write_count, traceframes_created)
11331 (trace_state_variables)
11332 New renaming defines.
11333 (struct ipa_sym_addresses): New.
11334 (STRINGIZE_1, STRINGIZE, IPA_SYM): New.
11335 (symbol_list): New.
11336 (ipa_sym_addrs): New.
11337 (all_tracepoint_symbols_looked_up): New.
11338 (in_process_agent_loaded): New.
11339 (write_e_ipa_not_loaded): New.
11340 (maybe_write_ipa_not_loaded): New.
11341 (tracepoint_look_up_symbols): New.
11342 (debug_threads) [IN_PROCESS_AGENT]: New.
11343 (read_inferior_memory) [IN_PROCESS_AGENT]: New.
11344 (UNKNOWN_SIDE_EFFECTS): New.
11345 (stop_tracing): New.
11346 (flush_trace_buffer): New.
11347 (stop_tracing_bkpt): New.
11348 (flush_trace_buffer_bkpt): New.
11349 (read_inferior_integer): New.
11350 (read_inferior_uinteger): New.
11351 (read_inferior_data_pointer): New.
11352 (write_inferior_data_pointer): New.
11353 (write_inferior_integer): New.
11354 (write_inferior_uinteger): New.
11355 (struct collect_static_trace_data_action): Delete.
11356 (enum tracepoint_type): New.
11357 (struct tracepoint) <type>: New field `type'.
11358 <actions_str, step_actions, step_actions_str>: Only include in
11359 GDBserver.
11360 <orig_size, obj_addr_on_target, adjusted_insn_addr>
11361 <adjusted_insn_addr_end, jump_pad, jump_pad_end>: New fields.
11362 (tracepoints): Use IP_AGENT_EXPORT.
11363 (last_tracepoint): Don't include in the IPA.
11364 (stopping_tracepoint): Use IP_AGENT_EXPORT.
11365 (trace_buffer_is_full): Use IP_AGENT_EXPORT.
11366 (alloced_trace_state_variables): New.
11367 (trace_state_variables): Use IP_AGENT_EXPORT.
11368 (traceframe_t): Delete unused variable.
11369 (circular_trace_buffer): Don't include in the IPA.
11370 (trace_buffer_start): Delete.
11371 (struct trace_buffer_control): New.
11372 (trace_buffer_free): Delete.
11373 (struct ipa_trace_buffer_control): New.
11374 (GDBSERVER_FLUSH_COUNT_MASK, GDBSERVER_FLUSH_COUNT_MASK_PREV)
11375 (GDBSERVER_FLUSH_COUNT_MASK_CURR, GDBSERVER_UPDATED_FLUSH_COUNT_BIT):
11376 New.
11377 (trace_buffer_ctrl): New.
11378 (TRACE_BUFFER_CTRL_CURR): New.
11379 (trace_buffer_start, trace_buffer_free, trace_buffer_end_free):
11380 Reimplement as macros.
11381 (trace_buffer_wrap): Delete.
11382 (traceframe_write_count, traceframe_read_count)
11383 (traceframes_created, tracing): Use IP_AGENT_EXPORT.
11384 (struct tracepoint_hit_ctx) <type>: New field.
11385 (struct fast_tracepoint_ctx): New.
11386 (memory_barrier): New.
11387 (cmpxchg): New.
11388 (record_tracepoint_error): Update atomically in the IPA.
11389 (clear_inferior_trace_buffer): New.
11390 (about_to_request_buffer_space): New.
11391 (trace_buffer_alloc): Handle GDBserver and inferior simulatenous
11392 updating the same buffer.
11393 (add_tracepoint): Default the tracepoint's type to trap
11394 tracepoint, and orig_size to -1.
11395 (get_trace_state_variable) [IN_PROCESS_AGENT]: Handle allocated
11396 internal variables.
11397 (create_trace_state_variable): New parameter `gdb'. Handle it.
11398 (clear_installed_tracepoints): Clear fast tracepoint jumps.
11399 (cmd_qtdp): Handle fast tracepoints.
11400 (cmd_qtdv): Adjust.
11401 (max_jump_pad_size): New.
11402 (gdb_jump_pad_head): New.
11403 (get_jump_space_head): New.
11404 (claim_jump_space): New.
11405 (sort_tracepoints): New.
11406 (MAX_JUMP_SIZE): New.
11407 (cmd_qtstart): Handle fast tracepoints. Sync tracepoints with the
11408 IPA.
11409 (stop_tracing) [IN_PROCESS_AGENT]: Don't include the tdisconnected
11410 support. Upload fast traceframes, and delete internal IPA
11411 breakpoints.
11412 (stop_tracing_handler): New.
11413 (flush_trace_buffer_handler): New.
11414 (cmd_qtstop): Upload fast tracepoints.
11415 (response_tracepoint): Handle fast tracepoints.
11416 (tracepoint_finished_step): Upload fast traceframes. Set the
11417 tracepoint hit context's tracepoint type.
11418 (handle_tracepoint_bkpts): New.
11419 (tracepoint_was_hit): Set the tracepoint hit context's tracepoint
11420 type. Add comment about fast tracepoints.
11421 (collect_data_at_tracepoint) [IN_PROCESS_AGENT]: Don't access the
11422 non-existing action_str field.
11423 (get_context_regcache): Handle fast tracepoints.
11424 (do_action_at_tracepoint) [!IN_PROCESS_AGENT]: Don't write the PC
11425 to the regcache.
11426 (fast_tracepoint_from_jump_pad_address): New.
11427 (fast_tracepoint_from_ipa_tpoint_address): New.
11428 (collecting_t): New.
11429 (force_unlock_trace_buffer): New.
11430 (fast_tracepoint_collecting): New.
11431 (collecting): New.
11432 (gdb_collect): New.
11433 (write_inferior_data_ptr): New.
11434 (target_tp_heap): New.
11435 (target_malloc): New.
11436 (download_agent_expr): New.
11437 (UALIGN): New.
11438 (download_tracepoints): New.
11439 (download_trace_state_variables): New.
11440 (upload_fast_traceframes): New.
11441 (IPA_FIRST_TRACEFRAME): New.
11442 (IPA_NEXT_TRACEFRAME_1): New.
11443 (IPA_NEXT_TRACEFRAME): New.
11444 [IN_PROCESS_AGENT]: Include sys/mman.h and fcntl.h.
11445 [IN_PROCESS_AGENT] (gdb_tp_heap_buffer, gdb_jump_pad_buffer)
11446 (gdb_jump_pad_buffer_end): New.
11447 [IN_PROCESS_AGENT] (initialize_tracepoint_ftlib): New.
11448 (initialize_tracepoint): Adjust.
11449 [IN_PROCESS_AGENT]: Allocate the IPA heap, and jump pad scratch
11450 buffer. Initialize the low module.
11451 * utils.c (PREFIX, TOOLNAME): New.
11452 (malloc_failure): Use PREFIX.
11453 (error): In the IPA, an error causes an exit.
11454 (fatal, warning): Use PREFIX.
11455 (internal_error): Use TOOLNAME.
11456 (NUMCELLS): Increase to 10.
11457 * configure, config.in: Regenerate.
11458
11459 2010-06-01 Pedro Alves <pedro@codesourcery.com>
11460
11461 * server.c (handle_query) <qSupported>: Do two passes over the
11462 qSupported string to avoid nesting strtok.
11463
11464 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
11465
11466 * Makefile.in (SFILES): Add $(srcdir)/proc-service.list.
11467 (CDEPS): New.
11468 * configure.ac (RDYNAMIC): New AC_MSG_CHECKING wrapping. Test also
11469 -Wl,--dynamic-list.
11470 * configure: Regenerate.
11471 * proc-service.list: New.
11472
11473 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
11474
11475 * linux-low.c (linux_core_of_thread): Fix crash on invalid CONTENT.
11476 New comment.
11477
11478 2010-05-26 Ozkan Sezer <sezeroz@gmail.com>
11479
11480 * gdbreplay.c (remote_open): Check error return from socket() call by
11481 its equality to -1 not by it being negative.
11482 * remote-utils.c (remote_open): Likewise.
11483
11484 2010-05-23 Pedro Alves <pedro@codesourcery.com>
11485
11486 * config.h: Regenerate.
11487
11488 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
11489
11490 * linux-m68k-low.c (ps_get_thread_area): Don't define if kernel
11491 doesn't provide PTRACE_GET_THREAD_AREA.
11492
11493 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
11494
11495 * linux-m68k-low.c: Include <asm/ptrace.h>
11496 (ps_get_thread_area): Implement.
11497
11498 2010-05-03 Doug Evans <dje@google.com>
11499
11500 * event-loop.c (struct callback_event): New struct.
11501 (callback_list): New global.
11502 (append_callback_event, delete_callback_event): New functions.
11503 (process_callback): New function.
11504 (start_event_loop): Call it.
11505 * remote-utils.c (NOT_SCHEDULED): Define.
11506 (readchar_buf, readchar_bufcnt, readchar_bufp): New static globals,
11507 moved out of readchar.
11508 (readchar): Rewrite. Call reschedule before returning.
11509 (reset_readchar): New function.
11510 (remote_close): Call it.
11511 (process_remaining, reschedule): New functions.
11512 * server.h (callback_handler_func): New typedef.
11513 (append_callback_event, delete_callback_event): Declare.
11514
11515 2010-05-03 Pedro Alves <pedro@codesourcery.com>
11516
11517 * proc-service.c (ps_pglobal_lookup): Use
11518 thread_db_look_up_one_symbol.
11519 * remote-utils.c (look_up_one_symbol): Add new `may_ask_gdb'
11520 parameter. Use it instead of all_symbols_looked_up.
11521 * server.h (struct process_info) <all_symbols_looked_up>: Delete
11522 field.
11523 (all_symbols_looked_up): Don't declare.
11524 (look_up_one_symbol): Add new `may_ask_gdb' parameter.
11525 * thread-db.c (struct thread_db) <all_symbols_looked_up>: New
11526 field.
11527 (thread_db_look_up_symbols): Adjust call to look_up_one_symbol.
11528 Set all_symbols_looked_up here.
11529 (thread_db_look_up_one_symbol): New.
11530 (thread_db_get_tls_address): Adjust.
11531 (thread_db_load_search, try_thread_db_load_1): Always allocate the
11532 thread_db object on the heap, and tentatively set it in the
11533 process structure.
11534 (thread_db_init): Don't set all_symbols_looked_up here.
11535 * linux-low.h (thread_db_look_up_one_symbol): Declare.
11536
11537 2010-05-03 Pedro Alves <pedro@codesourcery.com>
11538
11539 * linux-low.c (linux_kill, linux_detach): Adjust.
11540 (status_pending_p_callback): Remove redundant statement. Check
11541 for !TARGET_WAITIKIND_IGNORE, instead of
11542 TARGET_WAITKIND_STOPPED.
11543 (handle_tracepoints): Make sure LWP is locked. Adjust.
11544 (linux_wait_for_event_1): Adjust.
11545 (linux_cancel_breakpoints): New.
11546 (unsuspend_one_lwp): New.
11547 (unsuspend_all_lwps): New.
11548 (linux_wait_1): If finishing a step-over, unsuspend all lwps.
11549 (send_sigstop_callback): Change return type to int, add new
11550 `except' parameter and handle it.
11551 (suspend_and_send_sigstop_callback): New.
11552 (stop_all_lwps): Add new `suspend' and `expect' parameters, and
11553 pass them down. If SUSPEND, also increment the lwp's suspend
11554 count.
11555 (linux_resume_one_lwp): Add notice about resuming a suspended LWP.
11556 (need_step_over_p): Don't consider suspended LWPs.
11557 (start_step_over): Adjust.
11558 (proceed_one_lwp): Change return type to int, add new `except'
11559 parameter and handle it.
11560 (unsuspend_and_proceed_one_lwp): New.
11561 (proceed_all_lwps): Use find_inferior instead of
11562 for_each_inferior.
11563 (unstop_all_lwps): Add `unsuspend' parameter. If UNSUSPEND, them
11564 also decrement the suspend count of LWPs. Pass `except' down,
11565 instead of hacking its suspend count.
11566 (linux_pause_all): Add `freeze' parameter. Adjust.
11567 (linux_unpause_all): New.
11568 (linux_target_ops): Install linux_unpause_all.
11569 * server.c (handle_status): Adjust.
11570 * target.h (struct target_ops): New fields `unpause_all' and
11571 `cancel_breakpoints'. Add new parameter to `pause_all'.
11572 (pause_all): Add new `freeze' parameter.
11573 (unpause_all): New.
11574 (cancel_breakpoints): New.
11575 * tracepoint.c (clear_installed_tracepoints): Pause threads, and
11576 cancel breakpoints.
11577 (cmd_qtstart): Pause threads.
11578 (stop_tracing): Pause threads, and cancel breakpoints.
11579 * win32-low.c (win32_target_ops): Adjust.
11580
11581 2010-05-03 Pedro Alves <pedro@codesourcery.com>
11582
11583 * linux-low.c (linux_wait_for_event_1): Move passing the signal to
11584 the inferior right away from here...
11585 (linux_wait_1): ... to here, and adjust to check the thread's
11586 last_resume_kind instead of the lwp's step or stop_expected flags.
11587
11588 2010-05-02 Pedro Alves <pedro@codesourcery.com>
11589
11590 * README: Use consistent `GDB' and `GDBserver' spellings.
11591
11592 2010-05-02 Pedro Alves <pedro@codesourcery.com>
11593
11594 * linux-low.c (linux_kill_one_lwp): Assume the lwp is stopped.
11595 (linux_kill): Stop all lwps here. Don't delete the main lwp here.
11596 (linux_detach_one_lwp): Assume the lwp is stopped.
11597 (any_thread_of): Delete.
11598 (linux_detach): Stop all lwps here. Don't blindly delete all
11599 breakpoints.
11600 (delete_lwp_callback): New.
11601 (linux_mourn): Delete all lwps of the process that is gone.
11602 (linux_wait_1): Don't delete the last lwp of the process here.
11603 * mem-break.h (mark_breakpoints_out): Declare.
11604 * mem-break.c (mark_breakpoints_out): New.
11605 (free_all_breakpoints): Use it.
11606 * server.c (handle_target_event): If the process is gone, mark
11607 breakpoints out.
11608 * thread-db.c (struct thread_db) <create_bp>: New field.
11609 (thread_db_enable_reporting): Fix prototype. Store a thread event
11610 breakpoint reference in the thread_db struct.
11611 (thread_db_load_search): Clear the thread_db object.
11612 (try_thread_db_load_1): Ditto.
11613 (switch_to_process): New.
11614 (disable_thread_event_reporting): Use it.
11615 (remove_thread_event_breakpoints): New.
11616 (thread_db_detach, thread_db_mourn): Use it.
11617
11618 2010-05-01 Pedro Alves <pedro@codesourcery.com>
11619
11620 * linux-low.c (linux_enable_event_reporting): New.
11621 (linux_wait_for_event_1, handle_extended_wait): Use it.
11622
11623 2010-04-30 Pedro Alves <pedro@codesourcery.com>
11624
11625 * linux-low.c (linux_kill_one_lwp, linux_kill)
11626 (linux_detach_one_lwp): Adjust to send_sigstop interface change.
11627 (send_sigstop): Take an lwp_info as parameter instead. Queue a
11628 SIGSTOP even if the LWP is stopped.
11629 (send_sigstop_callback): New.
11630 (stop_all_lwps): Use send_sigstop_callback instead.
11631 (linux_resume_one_thread): Adjust.
11632 (proceed_one_lwp): Still proceed an LWP that the client has
11633 requested to stop, if we haven't reported it as stopped yet. Make
11634 sure that LWPs the client want stopped, have a pending SIGSTOP.
11635
11636 2010-04-26 Doug Evans <dje@google.com>
11637
11638 * server.c (handle_general_set): Make static.
11639
11640 * remote-utils.c (putpkt_binary_1): Call readchar instead of read.
11641 Print received char after testing for error/eof instead of before.
11642 (input_interrupt): Tweak comment.
11643
11644 2010-04-23 Doug Evans <dje@google.com>
11645
11646 * server.c (start_inferior): Print inferior argv if --debug.
11647
11648 2010-04-21 Aleksandar Ristovski <aristovski@qnx.com>
11649
11650 * Makefile.in (nto_low_h nto-low.o nto-x86-low.o): New dependency lists.
11651 * nto-x86-low.c: Include server.h
11652
11653 2010-04-20 Pierre Muller <muller@ics.u-strasbg.fr>
11654
11655 * win32-i386-low.c: Use __x86_64__ macro instead of __x86_64 to
11656 be consistent with other sources of this directory.
11657 (init_registers_amd64): Correct name of source file of this function
11658 in the comment.
11659
11660 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
11661
11662 * configure.srv (x86_64-*-mingw*): New configuration for Windows
11663 64-bit executables.
11664
11665 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
11666
11667 * win32-i386-low.c: Add 64-bit support.
11668 (CONTEXT_EXTENDED_REGISTERS): Set macro to zero if not exisiting.
11669 (init_registers_amd64): Declare.
11670 (mappings): Add 64-bit version of array.
11671 (init_windows_x86): New function.
11672 (the_low_target): Change init_arch field to init_windows_x86.
11673
11674 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
11675
11676 * win32-low.c: Adapt to support also 64-bit architecture.
11677 (child_xfer_memory): Use uintptr_t type for local variable `addr'.
11678 (get_image_name): Use SIZE_T type for local variable `done'.
11679 (psapi_get_dll_name): Use LPVOID type for parameter `BaseAddress'.
11680 (toolhelp_get_dll_name): Idem.
11681 (handle_load_dll): Use CORE_ADDR type for local variable `load_addr'.
11682 Use uintptr_t typecast to avoid warning.
11683 (handle_unload_dll): Use uintptr_t typecast to avoid warning.
11684 (handle_exception): Use phex_nz to avoid warning.
11685 (win32_wait): Remove unused local variable `process'.
11686
11687 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
11688
11689 * configure.srv (srv_amd64_regobj): Replace `x86-64-avx.o' by
11690 `amd64-avx.o'.
11691
11692 2010-04-17 Pierre Muller <muller@ics.u-strasbg.fr>
11693
11694 * configure.ac: Use `ws2_32' library for srv_mingw.
11695 * configure: Regenerate.
11696 * gdbreplay.c: Include winsock2.h instead of winsock.h.
11697 * remote-utils.c: Likewise.
11698
11699 2010-04-17 H.J. Lu <hongjiu.lu@intel.com>
11700
11701 * linux-x86-low.c (xmltarget_amd64_linux_no_xml): Define only
11702 if __x86_64__ is defined.
11703
11704 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
11705
11706 * configure: Regenerate.
11707
11708 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
11709
11710 * server.c (handle_query): Handle 'qGetTIBAddr' query.
11711 * target.h (target_ops): New get_tib_address field.
11712 * win32-low.h (win32_thread_info): Add thread_local_base field.
11713 * win32-low.c (child_add_thread): Add tlb argument.
11714 Set thread_local_base field to TLB.
11715 (get_child_debug_event): Adapt to child_add_thread change.
11716 (win32_get_tib_address): New function.
11717 (win32_target_ops): Set get_tib_address field to
11718 win32_get_tib_address.
11719 * linux-low.c (linux_target_ops): Set get_tib_address field to NULL.
11720
11721 2010-04-12 Pedro Alves <pedro@codesourcery.com>
11722
11723 * linux-low.c (linux_mourn): Also remove the process.
11724 * server.c (handle_target_event): Don't remove the process here.
11725 * nto-low.c (nto_mourn): New.
11726 (nto_target_ops): Install it.
11727 * spu-low.c (spu_mourn): New.
11728 (spu_target_ops): Install it.
11729 * win32-low.c (win32_mourn): New.
11730 (win32_target_ops): Install it.
11731
11732 2010-04-12 Pedro Alves <pedro@codesourcery.com>
11733
11734 * server.h (buffer_xml_printf): Remove redundant `;'.
11735
11736 2010-04-12 Pedro Alves <pedro@codesourcery.com>
11737
11738 * regcache.c (set_register_cache): Invalidate regcaches before
11739 changing the register cache layout.
11740 (regcache_invalidate_one): Allow a NULL regcache.
11741 * linux-x86-low.c (x86_linux_update_xmltarget): Invalidate
11742 regcaches before changing the register cache layout or the target
11743 regsets.
11744
11745 2010-04-12 H.J. Lu <hongjiu.lu@intel.com>
11746
11747 * linux-x86-low.c (x86_linux_update_xmltarget): Avoid unused
11748 variable warning on Linux/x86-64.
11749
11750 2010-04-11 Pedro Alves <pedro@codesourcery.com>
11751
11752 GDBserver disconnected tracing support.
11753
11754 * linux-low.c (linux_remove_process): Delete.
11755 (add_lwp): Don't set last_resume_kind here.
11756 (linux_kill): Use `mourn'.
11757 (linux_detach): Use `thread_db_detach', and `mourn'.
11758 (linux_mourn): New.
11759 (linux_attach_lwp_1): Adjust comment.
11760 (linux_attach): last_resume_kind moved the thread_info; adjust.
11761 (status_pending_p_callback): Adjust.
11762 (linux_wait_for_event_1): Adjust.
11763 (count_events_callback, select_singlestep_lwp_callback)
11764 (select_event_lwp_callback, cancel_breakpoints_callback)
11765 (db_wants_lwp_stopped, linux_wait_1, need_step_over_p)
11766 (proceed_one_lwp): Adjust.
11767 (linux_async): Add debug output.
11768 (linux_thread_stopped): New.
11769 (linux_pause_all): New.
11770 (linux_target_ops): Install linux_mourn, linux_thread_stopped and
11771 linux_pause_all.
11772 * linux-low.h (struct lwp_info): Delete last_resume_kind field.
11773 (thread_db_free): Delete declaration.
11774 (thread_db_detach, thread_db_mourn): Declare.
11775 * thread-db.c (thread_db_init): Use thread_db_mourn.
11776 (thread_db_free): Delete, split in two.
11777 (disable_thread_event_reporting): New.
11778 (thread_db_detach): New.
11779 (thread_db_mourn): New.
11780
11781 * server.h (struct thread_info) <last_resume_kind>: New field.
11782 <attached>: Add comment.
11783 <gdb_detached>: New field.
11784 (handler_func): Change return type to int.
11785 (handle_serial_event, handle_target_event): Ditto.
11786 (gdb_connected): Declare.
11787 (tracing): Delete.
11788 (disconnected_tracing): Declare.
11789 (stop_tracing): Declare.
11790
11791 * server.c (handle_query) <qSupported>: Report support for
11792 disconnected tracing.
11793 (queue_stop_reply_callback): Account for running threads.
11794 (gdb_wants_thread_stopped): New.
11795 (gdb_wants_all_threads_stopped): New.
11796 (gdb_reattached_process): New.
11797 (handle_status): Clear the `gdb_detached' flag of all processes.
11798 In all-stop, stop all threads.
11799 (main): Be sure to leave tfind mode. Handle disconnected tracing.
11800 (process_serial_event): If the remote connection breaks, or if an
11801 exit was forced with "monitor exit", force an event loop exit.
11802 Handle disconnected tracing on detach.
11803 (handle_serial_event): Adjust.
11804 (handle_target_event): If GDB isn't connected, forward events back
11805 to the inferior, unless the last process exited, in which case,
11806 exit gdbserver. Adjust interface.
11807
11808 * remote-utils.c (remote_open): Don't block in accept. Instead
11809 register an event loop source on the listen socket file
11810 descriptor. Refactor bits into ...
11811 (listen_desc): ... this new global.
11812 (gdb_connected): ... this new function.
11813 (enable_async_notification): ... this new function.
11814 (handle_accept_event): ... this new function.
11815 (remote_close): Clear remote_desc.
11816
11817 * inferiors.c (add_thread): Set the new thread's last_resume_kind.
11818
11819 * target.h (struct target_ops) <mourn, thread_stopped, pause_all>:
11820 New fields.
11821 (mourn_inferior): Define.
11822 (target_process_qsupported): Avoid the dangling else problem.
11823 (thread_stopped): Define.
11824 (pause_all): Define.
11825 (target_waitstatus_to_string): Declare.
11826 * target.c (target_waitstatus_to_string): New.
11827
11828 * tracepoint.c (tracing): Make extern.
11829 (disconnected_tracing): New.
11830 (stop_tracing): Make extern. Handle tracing stops due to GDB
11831 disconnecting.
11832 (cmd_qtdisconnected): New.
11833 (cmd_qtstatus): Report disconnected tracing status in trace reply.
11834 (handle_tracepoint_general_set): Handle QTDisconnected.
11835
11836 * event-loop.c (event_handler_func): Change return type to int.
11837 (process_event): Bail out if the event handler wants the event
11838 loop to stop.
11839 (handle_file_event): Ditto.
11840 (start_event_loop): Bail out if the event handler wants the event
11841 loop to stop.
11842
11843 * nto-low.c (nto_target_ops): Adjust.
11844 * spu-low.c (spu_wait): Don't remove the process here.
11845 (spu_target_ops): Adjust.
11846 * win32-low.c (win32_wait): Don't remove the process here.
11847 (win32_target_ops): Adjust.
11848
11849 2010-04-11 Pedro Alves <pedro@codesourcery.com>
11850
11851 * regcache.c (realloc_register_cache): Invalidate inferior's
11852 regcache before recreating it.
11853
11854 2010-04-09 Pedro Alves <pedro@codesourcery.com>
11855
11856 * tracepoint.c (cmd_qtstatus): Report trace buffer circularity.
11857
11858 2010-04-09 Stan Shebs <stan@codesourcery.com>
11859 Pedro Alves <pedro@codesourcery.com>
11860
11861 * server.h (LONGEST): New.
11862 (struct thread_info) <while_stepping>: New field.
11863 (unpack_varlen_hex, xrealloc, pulongest, plongest, phex_nz):
11864 Declare.
11865 (initialize_tracepoint, handle_tracepoint_general_set)
11866 (handle_tracepoint_query, tracepoint_finished_step)
11867 (tracepoint_was_hit, release_while_stepping_state_list):
11868 (current_traceframe): Declare.
11869 * server.c (handle_general_set): Handle tracepoint packets.
11870 (read_memory): New.
11871 (write_memory): New.
11872 (handle_search_memory_1): Use read_memory.
11873 (handle_query): Report support for conditional tracepoints, trace
11874 state variables, and tracepoint sources. Handle tracepoint
11875 queries.
11876 (main): Initialize the tracepoints module.
11877 (process_serial_event): Handle traceframe reads/writes.
11878
11879 * linux-low.c (handle_tracepoints): New.
11880 (linux_wait_1): Call it.
11881 (linux_resume_one_lwp): Handle while-stepping.
11882 (linux_supports_tracepoints, linux_read_pc, linux_write_pc): New.
11883 (linux_target_ops): Install them.
11884 * linux-low.h (struct linux_target_ops) <supports_tracepoints>:
11885 New field.
11886 * linux-x86-low.c (x86_supports_tracepoints): New.
11887 (the_low_target). Install it.
11888
11889 * mem-break.h (delete_breakpoint): Declare.
11890 * mem-break.c (delete_breakpoint): Make external.
11891
11892 * target.h (struct target_ops): Add `supports_tracepoints',
11893 `read_pc', and `write_pc' fields.
11894 (target_supports_tracepoints): Define.
11895 * utils.c (xrealloc, decimal2str, pulongest, plongest, thirty_two)
11896 (phex_nz): New.
11897
11898 * regcache.h (struct regcache) <registers_owned>: New field.
11899 (init_register_cache, regcache_cpy): Declare.
11900 (regcache_read_pc, regcache_write_pc): Declare.
11901 (register_cache_size): Declare.
11902 (supply_regblock): Declare.
11903 * regcache.c (init_register_cache): New.
11904 (new_register_cache): Use it.
11905 (regcache_cpy): New.
11906 (register_cache_size): New.
11907 (supply_regblock): New.
11908 (regcache_read_pc, regcache_write_pc): New.
11909
11910 * tracepoint.c: New.
11911
11912 * Makefile.in (OBS): Add tracepoint.o.
11913 (tracepoint.o): New rule.
11914
11915 2010-04-08 H.J. Lu <hongjiu.lu@intel.com>
11916
11917 * Makefile.in (clean): Also remove i386-mmx.c i386-mmx-linux.c.
11918 (i386-mmx.o): New.
11919 (i386-mmx.c): Likewise.
11920 (i386-mmx-linux.o): Likewise.
11921 (i386-mmx-linux.c): Likewise.
11922
11923 * configure.srv (srv_i386_regobj): Add i386-mmx.o.
11924 (srv_i386_linux_regobj): Add i386-mmx-linux.o.
11925 (srv_i386_xmlfiles): Add i386/i386-mmx.xml.
11926 (srv_i386_linux_xmlfiles): Add i386/i386-mmx-linux.xml.
11927
11928 * linux-x86-low.c (init_registers_i386_mmx_linux): New.
11929 (x86_linux_update_xmltarget): Call init_registers_i386_mmx_linux
11930 and return if ptrace PTRACE_GETFPXREGS failed in 32bit.
11931
11932 2010-04-07 H.J. Lu <hongjiu.lu@intel.com>
11933
11934 * Makefile.in (clean): Updated.
11935 (i386-avx.o): New.
11936 (i386-avx.c): Likewise.
11937 (i386-avx-linux.o): Likewise.
11938 (i386-avx-linux.c): Likewise.
11939 (amd64-avx.o): Likewise.
11940 (amd64-avx.c): Likewise.
11941 (amd64-avx-linux.o): Likewise.
11942 (amd64-avx-linux.c): Likewise.
11943
11944 * configure.srv (srv_i386_regobj): Add i386-avx.o.
11945 (srv_i386_linux_regobj): Add i386-avx-linux.o.
11946 (srv_amd64_regobj): Add amd64-avx.o.
11947 (srv_amd64_linux_regobj): Add amd64-avx-linux.o.
11948 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx.xml.
11949 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx.xml.
11950 (srv_i386_xmlfiles): Add i386/i386-avx.xml.
11951 (srv_amd64_xmlfiles): Add i386/amd64-avx.xml.
11952 (srv_i386_linux_xmlfiles): Add i386/i386-avx-linux.xml.
11953 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-linux.xml.
11954
11955 * i387-fp.c: Include "i386-xstate.h".
11956 (i387_xsave): New.
11957 (i387_cache_to_xsave): Likewise.
11958 (i387_xsave_to_cache): Likewise.
11959 (x86_xcr0): Likewise.
11960
11961 * i387-fp.h (i387_cache_to_xsave): Likewise.
11962 (i387_xsave_to_cache): Likewise.
11963 (x86_xcr0): Likewise.
11964
11965 * linux-arm-low.c (target_regsets): Initialize nt_type to 0.
11966 * linux-crisv32-low.c (target_regsets): Likewise.
11967 * linux-m68k-low.c (target_regsets): Likewise.
11968 * linux-mips-low.c (target_regsets): Likewise.
11969 * linux-ppc-low.c (target_regsets): Likewise.
11970 * linux-s390-low.c (target_regsets): Likewise.
11971 * linux-sh-low.c (target_regsets): Likewise.
11972 * linux-sparc-low.c (target_regsets): Likewise.
11973 * linux-xtensa-low.c (target_regsets): Likewise.
11974
11975 * linux-low.c: Include <sys/uio.h>.
11976 (regsets_fetch_inferior_registers): Support nt_type.
11977 (regsets_store_inferior_registers): Likewise.
11978 (linux_process_qsupported): New.
11979 (linux_target_ops): Add linux_process_qsupported.
11980
11981 * linux-low.h (regset_info): Add nt_type.
11982 (linux_target_ops): Add process_qsupported.
11983
11984 * linux-x86-low.c: Include "i386-xstate.h", "elf/common.h"
11985 and <sys/uio.h>.
11986 (init_registers_i386_avx_linux): New.
11987 (init_registers_amd64_avx_linux): Likewise.
11988 (xmltarget_i386_linux_no_xml): Likewise.
11989 (xmltarget_amd64_linux_no_xml): Likewise.
11990 (PTRACE_GETREGSET): Likewise.
11991 (PTRACE_SETREGSET): Likewise.
11992 (x86_fill_xstateregset): Likewise.
11993 (x86_store_xstateregset): Likewise.
11994 (use_xml): Likewise.
11995 (x86_linux_update_xmltarget): Likewise.
11996 (x86_linux_process_qsupported): Likewise.
11997 (target_regsets): Add NT_X86_XSTATE entry and Initialize nt_type.
11998 (x86_arch_setup): Don't call init_registers_amd64_linux nor
11999 init_registers_i386_linux here. Call
12000 x86_linux_update_xmltarget.
12001 (the_low_target): Add x86_linux_process_qsupported.
12002
12003 * server.c (handle_query): Call target_process_qsupported.
12004
12005 * target.h (target_ops): Add process_qsupported.
12006 (target_process_qsupported): New.
12007
12008 2010-04-03 Pedro Alves <pedro@codesourcery.com>
12009
12010 * inferiors.c (add_thread): Set last_status kind to
12011 TARGET_WAITKIND_IGNORE.
12012 * linux-low.c (cancel_breakpoint): Remove unnecessary regcache
12013 fetch. Use ptid_of. Avoid unnecessary get_lwp_thread calls.
12014 (linux_wait_1): Move `thread' local definition to block that uses
12015 it. Don't NULL initialize `event_child'.
12016 (linux_resume_one_thread): Avoid unnecessary get_lwp_thread calls.
12017 Alway set the thread's last_status to TARGET_WAITKIND_IGNORE.
12018 * linux-x86-low.c (x86_breakpoint_at): Read raw memory.
12019
12020 2010-04-01 Pedro Alves <pedro@codesourcery.com>
12021
12022 * linux-low.c (get_stop_pc): Don't adjust the PC if stopped with
12023 an extended waitstatus, or by a watchpoint.
12024 (cancel_breakpoints_callback): Don't cancel a breakpoint if the
12025 thread was stepping or has been stopped by a watchpoint.
12026
12027 2010-04-01 Pedro Alves <pedro@codesourcery.com>
12028
12029 * mem-break.c (struct raw_breakpoint): New field shlib_disabled.
12030 (set_gdb_breakpoint_at): If GDB is inserting a breakpoint on top
12031 of another, then delete the previous, and validate all
12032 breakpoints.
12033 (validate_inserted_breakpoint): New.
12034 (delete_disabled_breakpoints): New.
12035 (validate_breakpoints): New.
12036 (check_mem_read): Validate breakpoints before trusting their
12037 shadow. Delete disabled breakpoints.
12038 (check_mem_write): Validate breakpoints before trusting they
12039 should be inserted. Delete disabled breakpoints.
12040 * mem-break.h (validate_breakpoints):
12041 * server.c (handle_query): Validate breakpoints when we see a
12042 qSymbol query.
12043
12044 2010-04-01 Pedro Alves <pedro@codesourcery.com>
12045
12046 * linux-low.c (linux_wait_1): Avoid setting need_step_over is
12047 there's a GDB breakpoint at stop_pc. Always report a trap to GDB
12048 if we could tell there's a GDB breakpoint at stop_pc.
12049 (need_step_over_p): Don't do a step over if we find a GDB
12050 breakpoint at the resume PC.
12051
12052 * mem-break.c (struct raw_breakpoint): New.
12053 (enum bkpt_type): New type `gdb_breakpoint'.
12054 (struct breakpoint): Delete the `PC', `old_data' and `inserted'
12055 fields. New field `raw'.
12056 (find_raw_breakpoint_at): New.
12057 (set_raw_breakpoint_at): Handle refcounting. Create a raw
12058 breakpoint instead.
12059 (set_breakpoint_at): Adjust.
12060 (delete_raw_breakpoint): New.
12061 (release_breakpoint): New.
12062 (delete_breakpoint): Rename to...
12063 (delete_breakpoint_1): ... this. Add proc parameter. Use
12064 release_breakpoint. Return ENOENT.
12065 (delete_breakpoint): Reimplement.
12066 (find_breakpoint_at): Delete.
12067 (find_gdb_breakpoint_at): New.
12068 (delete_breakpoint_at): Delete.
12069 (set_gdb_breakpoint_at): New.
12070 (delete_gdb_breakpoint_at): New.
12071 (gdb_breakpoint_here): New.
12072 (set_reinsert_breakpoint): Use release_breakpoint.
12073 (uninsert_breakpoint): Rename to ...
12074 (uninsert_raw_breakpoint): ... this.
12075 (uninsert_breakpoints_at): Adjust to handle raw breakpoints.
12076 (reinsert_raw_breakpoint): Change parameter type to
12077 raw_breakpoint.
12078 (reinsert_breakpoints_at): Adjust to handle raw breakpoints
12079 instead.
12080 (check_breakpoints): Adjust. Use release_breakpoint.
12081 (breakpoint_here): Rewrite using find_raw_breakpoint_at.
12082 (breakpoint_inserted_here): Ditto.
12083 (check_mem_read): Adjust to iterate over raw breakpoints instead.
12084 Don't trust the breakpoint's shadow if it is not inserted.
12085 (check_mem_write): Adjust to iterate over raw breakpoints instead.
12086 (delete_all_breakpoints): Adjust.
12087 (free_all_breakpoints): Mark all breakpoints as uninserted, and
12088 use delete_breakpoint_1.
12089
12090 * mem-break.h (breakpoints_supported): Delete declaration.
12091 (set_gdb_breakpoint_at): Declare.
12092 (gdb_breakpoint_here): Declare.
12093 (delete_breakpoint_at): Delete.
12094 (delete_gdb_breakpoint_at): Declare.
12095
12096 * server.h (struct raw_breakpoint): Forward declare.
12097 (struct process_info): New field `raw_breakpoints'.
12098
12099 * linux-x86-low.c (x86_insert_point, x86_remote_point): Handle Z0
12100 breakpoints.
12101
12102 2010-03-24 Pedro Alves <pedro@codesourcery.com>
12103
12104 * linux-low.c (status_pending_p_callback): Fix comment.
12105 (linux_wait_for_event_1): Move most of the internal breakpoint
12106 handling from here...
12107 (linux_wait_1): ... to here.
12108 (count_events_callback): New.
12109 (select_singlestep_lwp_callback): New.
12110 (select_event_lwp_callback): New.
12111 (cancel_breakpoints_callback): New.
12112 (select_event_lwp): New.
12113 (linux_wait_1): Simplify internal breakpoint handling. Give equal
12114 priority to all LWPs that have had events that should be reported
12115 to the client. Cancel breakpoints when about to reporting the
12116 event to the client, not while stopping lwps. No longer cancel
12117 finished single-steps here.
12118 (cancel_finished_single_step): Delete.
12119 (cancel_finished_single_steps): Delete.
12120
12121 2010-03-24 Pedro Alves <pedro@codesourcery.com>
12122
12123 * mem-break.c (enum bkpt_type): New.
12124 (struct breakpoint): New field `type'.
12125 (set_breakpoint_at): Change return type to struct breakpoint
12126 pointer. Set type to `other_breakpoint' by default.
12127 (delete_breakpoint): Rewrite, supporting more than one breakpoint
12128 in the breakpoint list.
12129 (delete_reinsert_breakpoints): Only delete reinsert breakpoints.
12130 (reinsert_breakpoint): Rename to ...
12131 (reinsert_raw_breakpoint): ... this.
12132 (reinsert_breakpoints_at): Adjust.
12133 * mem-break.h (struct breakpoint): Declare.
12134 (set_breakpoint_at): Change return type to struct breakpoint
12135 pointer.
12136
12137 2010-03-24 Pedro Alves <pedro@codesourcery.com>
12138
12139 * server.c (handle_query): Assign, not compare.
12140
12141 2010-03-24 Pedro Alves <pedro@codesourcery.com>
12142
12143 Teach linux gdbserver to step-over-breakpoints.
12144
12145 * linux-low.c (can_hardware_single_step): New.
12146 (supports_breakpoints): New.
12147 (handle_extended_wait): If stopping threads, read the stop pc of
12148 the new cloned LWP.
12149 (get_pc): New.
12150 (get_stop_pc): Add `lwp' parameter. Handle it. Bail out if the
12151 low target doesn't support retrieving the PC.
12152 (add_lwp): Set last_resume_kind to resume_continue.
12153 (linux_attach_lwp_1): Adjust comments. Always set stop_expected.
12154 (linux_attach): Don't clear stop_expected. Set the lwp's
12155 last_resume_kind to resume_stop.
12156 (linux_detach_one_lwp): Don't check for removed breakpoints.
12157 (check_removed_breakpoint): Delete.
12158 (status_pending_p): Rename to ...
12159 (status_pending_p_callback): ... this. Don't check for removed
12160 breakpoints. Don't consider threads that are stopped from GDB's
12161 perspective.
12162 (linux_wait_for_lwp): Always read the stop_pc here.
12163 (cancel_breakpoint): New.
12164 (step_over_bkpt): New global.
12165 (linux_wait_for_event_1): Implement stepping over breakpoints.
12166 (gdb_wants_lwp_stopped): New.
12167 (gdb_wants_all_stopped): New.
12168 (linux_wait_1): Tag threads as gdb-wants-stopped. Cancel finished
12169 single-step traps here. Store the thread's last reported target
12170 wait status.
12171 (send_sigstop): Don't clear stop_expected. Always set it,
12172 instead.
12173 (mark_lwp_dead): Remove reference to pending_is_breakpoint.
12174 (cancel_finished_single_step): New.
12175 (cancel_finished_single_steps): New.
12176 (wait_for_sigstop): Don't cancel finished single-step traps here.
12177 (linux_resume_one_lwp): Don't check for removed breakpoints.
12178 Don't set `step' on non-hardware step archs.
12179 (linux_set_resume_request): Ignore resume_stop requests if already
12180 stopping or stopped. Set the lwp's last_resume_kind.
12181 (resume_status_pending_p): Don't check for removed breakpoints.
12182 (need_step_over_p): New.
12183 (start_step_over): New.
12184 (finish_step_over): New.
12185 (linux_resume_one_thread): Always queue a sigstop for resume_stop
12186 requests. Clear the thread's last reported target waitstatus.
12187 Don't use the `suspended' flag. Don't consider pending breakpoints.
12188 (linux_resume): Start a step-over if necessary.
12189 (proceed_one_lwp): New.
12190 (proceed_all_lwps): New.
12191 (unstop_all_lwps): New.
12192 * linux-low.h (struct lwp_info): Rewrite comment for the
12193 `suspended' flag. Add the `stop_pc' field. Delete the
12194 `pending_stop_pc' field. Tweak the `stepping' flag's comment.
12195 Add `'last_resume_kind' and `need_step_over' fields.
12196 * inferiors.c (struct thread_info): Delete, moved elsewhere.
12197 * mem-break.c (struct breakpoint): Delete `reinserting' flag.
12198 Delete `breakpoint_to_reinsert' field. New flag `inserted'.
12199 (set_raw_breakpoint_at): New.
12200 (set_breakpoint_at): Rewrite to use it.
12201 (reinsert_breakpoint_handler): Delete.
12202 (set_reinsert_breakpoint): New.
12203 (reinsert_breakpoint_by_bp): Delete.
12204 (delete_reinsert_breakpoints): New.
12205 (uninsert_breakpoint): Rewrite.
12206 (uninsert_breakpoints_at): New.
12207 (reinsert_breakpoint): Rewrite.
12208 (reinsert_breakpoints_at): New.
12209 (check_breakpoints): Rewrite.
12210 (breakpoint_here): New.
12211 (breakpoint_inserted_here): New.
12212 (check_mem_read): Adjust.
12213 * mem-break.h (breakpoints_supported, breakpoint_here)
12214 (breakpoint_inserted_here, set_reinsert_breakpoint): Declare.
12215 (reinsert_breakpoint_by_bp): Delete declaration.
12216 (delete_reinsert_breakpoints): Declare.
12217 (reinsert_breakpoint): Delete declaration.
12218 (reinsert_breakpoints_at): Declare.
12219 (uninsert_breakpoint): Delete declaration.
12220 (uninsert_breakpoints_at): Declare.
12221 (check_breakpoints): Adjust prototype.
12222 * server.h: Adjust include order.
12223 (struct thread_info): Declare here. Add a `last_status' field.
12224
12225 2010-03-23 Michael Snyder <msnyder@vmware.com>
12226
12227 * server.c (crc32): New function.
12228 (handle_query): Add handling for 'qCRC:' request.
12229
12230 2010-03-23 Pedro Alves <pedro@codesourcery.com>
12231
12232 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR6 if the
12233 lwp had been stopped by a watchpoint.
12234
12235 2010-03-16 Pedro Alves <pedro@codesourcery.com>
12236
12237 * server.h (internal_error): Declare.
12238 (gdb_assert, ASSERT_FUNCTION, gdb_assert_fail): Define.
12239 * utils.c (internal_error): New function.
12240
12241 2010-03-15 Andreas Schwab <schwab@redhat.com>
12242
12243 * configure.srv: Fix typo setting srv_regobj.
12244
12245 2010-03-15 Pedro Alves <pedro@codesourcery.com>
12246
12247 * linux-low.c (fetch_register): Avoid passing a non string literal
12248 format to `error'.
12249 (usr_store_inferior_registers): Ditto.
12250
12251 2010-03-14 Pedro Alves <pedro@codesourcery.com>
12252
12253 * linux-low.c (linux_write_memory): Bail out early if peeking
12254 memory failed.
12255
12256 2010-03-14 Pedro Alves <pedro@codesourcery.com>
12257
12258 * linux-low.h (struct lwp_info): New fields
12259 `stopped_by_watchpoint' and `stopped_data_address'.
12260 * linux-low.c (linux_wait_for_lwp): Check for watchpoint triggers
12261 here, and cache them in the lwp object.
12262 (wait_for_sigstop): Check stopped_by_watchpoint lwp field
12263 directly.
12264 (linux_resume_one_lwp): Clear the lwp's stopped_by_watchpoint
12265 field.
12266 (linux_stopped_by_watchpoint): Rewrite.
12267 (linux_stopped_data_address): Rewrite.
12268
12269 2010-03-06 Simo Melenius <simo.melenius@iki.fi>
12270
12271 * linux-low.c (linux_wait_for_lwp): Fetch the regcache after
12272 switching the current inferior, not before.
12273
12274 2010-03-01 H.J. Lu <hongjiu.lu@intel.com>
12275
12276 * Makefile.in (clean): Replace reg-i386.c, reg-x86-64.c,
12277 reg-i386-linux.c and reg-x86-64-linux.c with i386.c, amd64.c,
12278 i386-linux.c and amd64-linux.c.
12279 (reg-i386.o): Removed.
12280 (reg-i386.c): Likewise.
12281 (reg-i386-linux.o): Likewise.
12282 (reg-i386-linux.c): Likewise.
12283 (reg-x86-64.o): Likewise.
12284 (reg-x86-64.c): Likewise.
12285 (reg-x86-64-linux.o): Likewise.
12286 (reg-x86-64-linux.c): Likewise.
12287 (i386.o): New.
12288 (i386.c): Likewise.
12289 (i386-linux.o): Likewise.
12290 (i386-linux.c): Likewise.
12291 (amd64.o): Likewise.
12292 (amd64.c): Likewise.
12293 (amd64-linux.o): Likewise.
12294 (amd64-linux.c): Likewise.
12295
12296 * configure.srv (srv_i386_regobj): New.
12297 (srv_i386_linux_regobj): Likewise.
12298 (srv_amd64_regobj): Likewise.
12299 (srv_amd64_linux_regobj): Likewise.
12300 (srv_i386_32bit_xmlfiles): Likewise.
12301 (srv_i386_64bit_xmlfiles): Likewise.
12302 (srv_i386_xmlfiles): Likewise.
12303 (srv_amd64_xmlfiles): Likewise.
12304 (srv_i386_linux_xmlfiles): Likewise.
12305 (srv_amd64_linux_xmlfiles): Likewise.
12306 (i[34567]86-*-cygwin*): Set srv_regobj to $srv_i386_regobj. Set
12307 srv_xmlfiles to $srv_i386_xmlfiles.
12308 (i[34567]86-*-mingw32ce*): Likewise.
12309 (i[34567]86-*-mingw*): Likewise.
12310 (i[34567]86-*-nto*): Likewise.
12311 (i[34567]86-*-linux*): Set srv_regobj to $srv_i386_linux_regobj
12312 and $srv_amd64_linux_regobj. Set srv_xmlfiles to
12313 $srv_i386_linux_xmlfiles and $srv_amd64_linux_xmlfiles.
12314 (x86_64-*-linux*): Likewise.
12315
12316 * linux-x86-low.c (init_registers_x86_64_linux): Removed.
12317 (init_registers_amd64_linux): New.
12318 (x86_arch_setup): Replace init_registers_x86_64_linux with
12319 init_registers_amd64_linux.
12320
12321 2010-02-23 Maxim Kuvyrkov <maxim@codesourcery.com>
12322
12323 * configure.ac: Check for libdl. If it is not available link against
12324 static libthread_db.
12325 * configure: Regenerate.
12326
12327 2010-02-22 Pedro Alves <pedro@codesourcery.com>
12328
12329 PR9605
12330
12331 * i386-low.c (i386_length_and_rw_bits): Throw a fatal error if
12332 handing a read watchpoint.
12333 (i386_low_insert_watchpoint): Read watchpoints aren't supported.
12334
12335 2010-02-12 Doug Evans <dje@google.com>
12336
12337 * linux-low.c (linux_supports_tracefork_flag): Document.
12338 (linux_look_up_symbols): Add comment.
12339
12340 2010-02-03 H.J. Lu <hongjiu.lu@intel.com>
12341
12342 * regcache.c (supply_register): Clear regcache if buf is NULL.
12343
12344 2010-02-02 Nicolas Roche <roche@sourceware.org>
12345 Joel Brobecker <brobecker@adacore.com>
12346
12347 * inferiors.c (find_inferior): Add function documentation.
12348 (unloaded_dll): Handle the case where the unloaded dll has not
12349 been previously registered in the dll list.
12350
12351 2010-02-01 Daniel Jacobowitz <dan@codesourcery.com>
12352
12353 * linux-arm-low.c (thumb_breakpoint_len): Delete.
12354 (thumb2_breakpoint): New.
12355 (arm_breakpoint_at): Check for Thumb-2 breakpoints.
12356
12357 2010-01-29 Daniel Jacobowitz <dan@codesourcery.com>
12358
12359 * linux-low.c (get_stop_pc): Check for SIGTRAP.
12360 (linux_wait_for_event_1): Handle SIGILL and SIGSEGV as possible
12361 breakpoints.
12362
12363 2010-01-21 Pedro Alves <pedro@codesourcery.com>
12364
12365 * linux-ppc-low.c (ppc_arch_setup): Adjust to regcache changes.
12366
12367 2010-01-21 Jan Kratochvil <jan.kratochvil@redhat.com>
12368
12369 * linux-s390-low.c (s390_collect_ptrace_register)
12370 (s390_supply_ptrace_register): Adjust it for the new regcache parameter.
12371
12372 2010-01-21 Doug Evans <dje@google.com>
12373
12374 * linux-low.c (PTRACE_ARG3_TYPE): Change from long to void*.
12375 (PTRACE_ARG4_TYPE): New macro.
12376 (handle_extended_wait): Cast ptrace arg4 to PTRACE_ARG4_TYPE.
12377 (linux_wait_for_event_1, linux_resume_one_lwp): Ditto.
12378 (fetch_register): Cast to uintptr_t before casting to PTRACE_ARG3_TYPE.
12379 (usr_store_inferior_registers): Ditto.
12380 (linux_read_memory, linux_write_memory): Ditto.
12381 (linux_test_for_tracefork): Ditto.
12382
12383 * linux-arm-low.c: Remove redundant include of gdb_proc_service.h.
12384 Only include elf.h if gdb_proc_service.h didn't include linux/elf.h.
12385
12386 2010-01-21 Pedro Alves <pedro@codesourcery.com>
12387
12388 * proc-service.c (ps_lgetregs): Don't refetch registers from the
12389 target.
12390
12391 2010-01-21 Pedro Alves <pedro@codesourcery.com>
12392
12393 * spu-low.c (spu_fetch_registers, spu_store_registers): Change
12394 prototype to take a regcache. Adjust.
12395
12396 2010-01-20 Pedro Alves <pedro@codesourcery.com>
12397
12398 * regcache.h (struct thread_info): Forward declare.
12399 (struct regcache): New.
12400 (new_register_cache): Adjust prototype.
12401 (get_thread_regcache): Declare.
12402 (free_register_cache): Adjust prototype.
12403 (registers_to_string, registers_from_string): Ditto.
12404 (supply_register, supply_register_by_name, collect_register)
12405 (collect_register_as_string, collect_register_by_name): Ditto.
12406 * regcache.c (struct inferior_regcache_data): Delete.
12407 (get_regcache): Rename to ...
12408 (get_thread_regcache): ... this. Adjust. Switch inferior before
12409 fetching registers.
12410 (regcache_invalidate_one): Adjust.
12411 (regcache_invalidate): Fix prototype.
12412 (new_register_cache): Return the new register cache.
12413 (free_register_cache): Change prototype.
12414 (realloc_register_cache): Adjust.
12415 (registers_to_string): Change prototype to take a regcache. Adjust.
12416 (registers_from_string): Ditto.
12417 (register_data): Ditto.
12418 (supply_register): Ditto.
12419 (supply_register_by_name): Ditto.
12420 (collect_register): Ditto.
12421 (collect_register_as_string): Ditto.
12422 (collect_register_by_name): Ditto.
12423 * server.c (process_serial_event): Adjust.
12424 * linux-low.h (regset_fill_func, regset_store_func): Change
12425 prototype.
12426 (get_pc, set_pc, collect_ptrace_register, supply_ptrace_register):
12427 Change prototype.
12428 * linux-low.c (get_stop_pc): Adjust.
12429 (check_removed_breakpoint): Adjust.
12430 (linux_wait_for_event): Adjust.
12431 (linux_resume_one_lwp): Adjust.
12432 (fetch_register): Add regcache parameter. Adjust.
12433 (usr_store_inferior_registers): Ditto.
12434 (regsets_fetch_inferior_registers): Ditto.
12435 (regsets_store_inferior_registers): Ditto.
12436 (linux_fetch_registers, linux_store_registers): Ditto.
12437 * i387-fp.c (i387_cache_to_fsave): Change prototype to take a
12438 regcache. Adjust.
12439 (i387_fsave_to_cache, i387_cache_to_fxsave, i387_fxsave_to_cache):
12440 Ditto.
12441 * i387-fp.h (i387_cache_to_fsave, i387_fsave_to_cache): Change
12442 prototype to take a regcache.
12443 (i387_cache_to_fxsave, i387_fxsave_to_cache): Ditto.
12444 * remote-utils.c (convert_ascii_to_int, outreg)
12445 (prepare_resume_reply): Change prototype to take a regcache.
12446 Adjust.
12447 * target.h (struct target_ops) <fetch_registers, store_registers>:
12448 Change prototype to take a regcache.
12449 (fetch_inferior_registers, store_inferior_registers): Change
12450 prototype to take a regcache. Adjust.
12451 * proc-service.c (ps_lgetregs): Adjust.
12452 * linux-x86-low.c (x86_fill_gregset, x86_store_gregset)
12453 (x86_fill_fpregset, x86_store_fpregset, x86_fill_fpxregset)
12454 (x86_store_fpxregset, x86_get_pc, x86_set_pc): Change prototype to
12455 take a regcache. Adjust.
12456 * linux-arm-low.c (arm_fill_gregset, arm_store_gregset)
12457 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
12458 (arm_store_vfpregset, arm_get_pc, arm_set_pc):
12459 (arm_breakpoint_at): Change prototype to take a regcache. Adjust.
12460 * linux-cris-low.c (cris_get_pc, cris_set_pc)
12461 (cris_cannot_fetch_register):
12462 (cris_breakpoint_at): Change prototype to take a regcache.
12463 Adjust.
12464 * linux-crisv32-low.c (cris_get_pc, cris_set_pc,
12465 cris_reinsert_addr, cris_write_data_breakpoint): Change prototype
12466 to take a regcache. Adjust.
12467 (cris_breakpoint_at, cris_insert_point, cris_remove_point):
12468 Adjust.
12469 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Change prototype to
12470 take a regcache. Adjust.
12471 * linux-m68k-low.c (m68k_fill_gregset, m68k_store_gregset)
12472 (m68k_fill_fpregset, m68k_store_fpregset, m68k_get_pc,
12473 (m68k_set_pc): Change prototype to take a regcache. Adjust.
12474 * linux-mips-low.c (mips_get_pc):
12475 (mips_set_pc): Change prototype to take a regcache. Adjust.
12476 (mips_reinsert_addr): Adjust.
12477 (mips_collect_register): Change prototype to take a regcache.
12478 Adjust.
12479 (mips_supply_register):
12480 (mips_collect_register_32bit, mips_supply_register_32bit)
12481 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
12482 (mips_store_fpregset): Ditto.
12483 * linux-ppc-low.c (ppc_supply_ptrace_register)
12484 (ppc_supply_ptrace_register): Ditto.
12485 (parse_spufs_run): Adjust.
12486 (ppc_get_pc, ppc_set_pc, ppc_fill_gregset, ppc_fill_vsxregset)
12487 (ppc_store_vsxregset, ppc_fill_vrregset, ppc_store_vrregset)
12488 (ppc_fill_evrregset, ppc_store_evrregset): Change prototype to
12489 take a regcache. Adjust.
12490 * linux-s390-low.c (s390_collect_ptrace_register)
12491 (s390_supply_ptrace_register, s390_fill_gregset, s390_get_pc)
12492 (s390_set_pc): Change prototype to take a regcache. Adjust.
12493 (s390_arch_setup): Adjust.
12494 * linux-sh-low.c (sh_get_pc, sh_breakpoint_at)
12495 (sh_fill_gregset): Change prototype to take a regcache. Adjust.
12496 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
12497 (sparc_fill_gregset, sparc_store_gregset_from_stack)
12498 (sparc_store_gregset, sparc_get_pc): Change prototype to take a
12499 regcache. Adjust.
12500 (sparc_breakpoint_at): Adjust.
12501 * linux-xtensa-low.c (xtensa_fill_gregset):
12502 (xtensa_store_gregset):
12503 (xtensa_fill_xtregset, xtensa_store_xtregset, xtensa_get_pc)
12504 (xtensa_set_pc): Change prototype to take a regcache. Adjust.
12505 * nto-low.c (nto_fetch_registers, nto_store_registers): Change
12506 prototype to take a regcache. Adjust.
12507 * win32-arm-low.c (arm_fetch_inferior_register)
12508 (arm_store_inferior_register): Change prototype to take a
12509 regcache. Adjust.
12510 * win32-i386-low.c (i386_fetch_inferior_register)
12511 (i386_store_inferior_register): Change prototype to take a
12512 regcache. Adjust.
12513 * win32-low.c (child_fetch_inferior_registers)
12514 (child_store_inferior_registers): Change prototype to take a
12515 regcache. Adjust.
12516 (win32_wait): Adjust.
12517 (win32_fetch_inferior_registers): Change prototype to take a
12518 regcache. Adjust.
12519 (win32_store_inferior_registers): Adjust.
12520 * win32-low.h (struct win32_target_ops) <fetch_inferior_register,
12521 store_inferior_register>: Change prototype to take a regcache.
12522
12523 2010-01-20 Doug Evans <dje@google.com>
12524
12525 * linux-low.c (linux_create_inferior): Wrap use of __SIGRTMIN in
12526 #ifdef.
12527 (linux_wait_for_event1, linux_init_signals): Ditto.
12528 (W_STOPCODE): Provide definition if missing.
12529
12530 2010-01-13 Vladimir Prus <vladimir@codesourcery.com>
12531
12532 * linux-low.c (linux_core_of_thread): New.
12533 (compare_ints, show_process, list_threads): New.
12534 (linux_qxfer_osdata): Report threads and cores.
12535 (linux_target_op): Register linux_core_of_thread.
12536 * remote-utils.c (prepare_resume_reply): Report the core.
12537 (buffer_xml_printf): Support %d specifier.
12538 * server.c (handle_threads_qxfer_proper, handle_threads_qxfer):
12539 New.
12540 (handle_query): Handle qXfer:threads. Announce availability
12541 thereof.
12542 * target.h (struct target_ops): New field core_of_thread.
12543
12544 2010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
12545
12546 * Makefile.in (clean): Remove new generated files.
12547 (reg-s390.o, reg-s390.c): Remove rules.
12548 (reg-s390x.o, reg-s390x.c): Likewise.
12549 (s390-linux32.o, s390-linux32.c): Add rules.
12550 (s390-linux64.o, s390-linux64.c): Likewise.
12551 (s390x-linux64.o, s390x-linux64.c): Likewise.
12552 * configure.srv (s390*-*-linux*): Update srv_regobj and srv_xmlfiles.
12553 * linux-s390-low.c: Include <elf.h>.
12554 (HWCAP_S390_HIGH_GPRS): Define if undefined.
12555 (init_registers_s390): Remove prototype.
12556 (init_registers_s390x): Likewise.
12557 (init_registers_s390_linux32): Add prototype.
12558 (init_registers_s390_linux64): Likewise.
12559 (init_registers_s390x_linux64): Likewise.
12560 (s390_num_regs_3264): New define.
12561 (s390_regmap_3264): New global variable.
12562 (s390_cannot_fetch_register): Remove obsolete check.
12563 (s390_cannot_store_register): Likewise.
12564 (s390_collect_ptrace_register): Handle upper/lower register halves.
12565 (s390_supply_ptrace_register): Likewise.
12566 (s390_fill_gregset): Update to register number changes.
12567 (s390_get_hwcap): New routine.
12568 (s390_arch_setup): Detect 32-bit process running on 64-bit system.
12569 Install appropriate regmap and register set.
12570
12571 2010-01-01 Joel Brobecker <brobecker@adacore.com>
12572
12573 * server.c (gdbserver_version): Update copyright year to 2010.
12574 * gdbreplay.c (gdbreplay_version): Likewise.
12575
12576 2009-12-28 Doug Evans <dje@google.com>
12577
12578 * linux-low.c: Delete inclusion of ansidecl.h, elf/common.h,
12579 elf/external.h. Include <elf.h> instead but only if necessary.
12580
12581 2009-12-28 Pedro Alves <pedro@codesourcery.com>
12582
12583 * linux-low.c (linux_remove_process): Remove `detaching'
12584 parameter. Don't release/detach from thread_db here.
12585 (linux_kill): Release/detach from thread_db here, ...
12586 (linux_detach): ... and here, before actually detaching.
12587 (linux_wait_1): ... and here, when a process exits.
12588 * thread-db.c (any_thread_of): New.
12589 (thread_db_free): Switch the current inferior to a thread of the
12590 passed in process.
12591
12592 2009-12-21 Doug Evans <dje@google.com>
12593
12594 * linux-x86-low.c: Delete outdated comment about Elf32_Phdr.
12595
12596 * linux-low.c (kill_lwp): Use __NR_tkill instead of SYS_tkill.
12597 Move definition of tkill_failed to ifdef __NR_tkill to avoid gcc
12598 warning ifndef __NR_tkill. Move setting of errno there too.
12599 Delete unnecessary resetting of errno after syscall.
12600 Minor comment changes to match gdb/linux-nat.c:kill_lwp.
12601
12602 * configure.ac: Check for dladdr.
12603 * config.in: Regenerate.
12604 * configure: Regenerate.
12605 * thread-db.c (dladdr_to_soname): Only define ifdef HAVE_DLADDR.
12606 (try_thread_db_load): Update.
12607
12608 * linux-low.c (my_waitpid): Delete unnecessary prototype.
12609
12610 2009-12-18 Doug Evans <dje@google.com>
12611
12612 * event-loop.c: Include unistd.h if it exists.
12613
12614 * linux-low.c (my_waitpid): Move definition away from being in
12615 between linux_tracefork_child/linux_test_for_tracefork.
12616
12617 * gdb_proc_service.h (psaddr_t): Fix type.
12618 * thread-db.c (thread_db_info.td_thr_tls_get_addr_p): Fix
12619 signature to match glibc.
12620
12621 2009-12-16 Doug Evans <dje@google.com>
12622
12623 * linux-low.c (linux_read_memory): Fix argument to read.
12624
12625 2009-11-26 Pedro Alves <pedro@codesourcery.com>
12626
12627 * win32-low.c (get_child_debug_event): On EXIT_THREAD_DEBUG_EVENT
12628 events, don't leave current_inferior pointing at null.
12629
12630 2009-11-26 Pedro Alves <pedro@codesourcery.com>
12631
12632 * win32-low.c (LOG): Delete.
12633 (OUTMSG): Output to stderr.
12634 (OUTMSG2): Conditionalize on `debug_threads' variable, instead of
12635 on compile time LOG macro.
12636 (win32_wait): Fix debug output.
12637
12638 2009-11-26 Pedro Alves <pedro@codesourcery.com>
12639
12640 * win32-low.c (win32_add_one_solib): If the dll name is
12641 "ntdll.dll", prepend the system directory to the dll path.
12642
12643 2009-11-17 Daniel Jacobowitz <dan@codesourcery.com>
12644
12645 * m68k-tdep.c (m68k_gdbarch_init): Reuse previous initialization.
12646
12647 2009-11-17 Nathan Sidwell <nathan@codesourcery.com>
12648 Vladimir Prus <vladimir@codesourcery.com>
12649
12650 * Makefile.in (reg-cf.o, reg-cf.c): New targets.
12651 * configure.ac: Check for __mcoldfire__ and set
12652 gdb_cv_m68k_is_coldfire.
12653 * configure.srv: Use gdb_cv_m68k_is_coldfire to select between
12654 reg-cf.o and reg-m68k.o.
12655 * configure: Regenerated.
12656
12657 2009-11-16 Pedro Alves <pedro@codesourcery.com>
12658
12659 * linux-low.c (linux_remove_process): Add `detaching' parameter.
12660 Pass it to thread_db_free.
12661 (linux_kill, linux_detach, linux_wait_1): Adjust to pass the
12662 proper `detaching' argument to linux_remove_process.
12663 * linux-low.h (thread_db_free): Add `detaching' parameter.
12664 * thread-db.c (thread_db_init): Pass false as `detaching' argument
12665 to thread_db_free.
12666 (thread_db_free): Add `detaching' parameter. Only
12667 call td_ta_clear_event if detaching from process.
12668
12669 2009-11-12 Maxim Kuvyrkov <maxim@codesourcery.com>
12670
12671 * thread-db.c (thread_db_free): Fix typo.
12672
12673 2009-11-11 Paul Pluzhnikov <ppluzhnikov@google.com>
12674
12675 PR gdb/10838
12676 * thread-db.c (thread_db_free): Call td_ta_clear_event.
12677
12678 2009-11-03 Nathan Sidwell <nathan@codesourcery.com>
12679
12680 * configure.ac (i[34567]86-*): Check if we're targetting x86-64
12681 with an i686 compiler.
12682 * configure.srv (i[34567]86-*-linux*): Pull in x86-64 handling if
12683 needed.
12684 * configure: Rebuilt.
12685
12686 2009-10-29 Sandra Loosemore <sandra@codesourcery.com>
12687
12688 PR gdb/10783
12689
12690 * server.c (handle_search_memory_1): Correct read_addr initialization
12691 in loop for searching subsequent chunks.
12692
12693 2009-10-29 Paul Pluzhnikov <ppluzhnikov@google.com>
12694
12695 * configure.ac: New --with-libthread-db option.
12696 * thread-db.c: Allow direct dependence on libthread_db.
12697 (thread_db_free): Adjust.
12698 * config.in: Regenerate.
12699 * configure: Likewise.
12700
12701 2009-10-28 Paul Pluzhnikov <ppluzhnikov@google.com>
12702
12703 PR gdb/10757
12704 * thread-db.c (attach_thread): New function.
12705 (maybe_attach_thread): Return success/failure.
12706 (find_new_threads_callback): Adjust.
12707 (thread_db_find_new_threads): Loop until no new threads.
12708
12709 2009-10-13 Pedro Alves <pedro@codesourcery.com>
12710
12711 * proc-service.c (ps_lgetregs): Formatting.
12712
12713 2009-10-08 Paul Pluzhnikov <ppluzhnikov@google.com>
12714
12715 * acinclude.m4: (SRV_CHECK_THREAD_DB, SRV_CHECK_TLS_GET_ADDR): Remove.
12716 * configure.ac: Adjust.
12717 * linux-low.h (struct process_info_private): Move members to struct
12718 thread_db.
12719 (thread_db_free, thread_db_handle_monitor_command): New prototype.
12720 * linux-low.c (linux_remove_process): Adjust.
12721 (linux_wait_for_event_1, linux_look_up_symbols): Likewise.
12722 * server.c (handle_query): Move code ...
12723 (handle_monitor_command): ... here. New function.
12724 * target.h (struct target_ops): New member.
12725 * thread-db.c (struct thread_db): New.
12726 (libthread_db_search_path): New variable.
12727 (thread_db_create_event, thread_db_enable_reporting)
12728 (find_one_thread, maybe_attach_thread, find_new_threads_callback)
12729 (thread_db_find_new_threads, (thread_db_get_tls_address): Adjust.
12730 (try_thread_db_load_1, dladdr_to_soname): New functions.
12731 (try_thread_db_load, thread_db_load_search): New functions.
12732 (thread_db_init): Search for libthread_db.
12733 (thread_db_free): New function.
12734 (thread_db_handle_monitor_command): Likewise.
12735 * config.in: Regenerate.
12736 * configure: Regenerate.
12737
12738 2009-09-27 Ulrich Weigand <uweigand@de.ibm.com>
12739
12740 * spu-low.c (spu_kill): Wait for inferior to terminate.
12741 Call clear_inferiors.
12742 (spu_detach): Call clear_inferiors.
12743
12744 2009-08-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
12745
12746 * aclocal.m4: Regenerate.
12747 * config.in: Likewise.
12748 * configure: Likewise.
12749
12750 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
12751
12752 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Define.
12753 (parse_spufs_run): New function.
12754 (ppc_get_pc, ppc_set_pc): Detect and handle SPU PC.
12755 (ppc_breakpoint_at): Handle SPU breakpoints.
12756
12757 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
12758
12759 * linux-low.c: Include <sys/stat.h> and <sys/vfs.h>.
12760 (SPUFS_MAGIC): Define.
12761 (spu_enumerate_spu_ids): New function.
12762 (linux_qxfer_spu): New function.
12763 (linux_target_ops): Install linux_qxfer_spu.
12764
12765 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
12766
12767 * configure.srv (powerpc*-*-linux*): Add powerpc-cell32l.o
12768 and powerpc-cell64l.o to srv_regobj. Add rs6000/powerpc-cell32l.xml
12769 and rs6000/powerpc-cell64l.xml to srv_xmlfiles.
12770 * Makefile.in (powerpc-cell32l.o, powerpc-cell32l.c): New rules.
12771 (powerpc-cell64l.o, powerpc-cell64l.c): Likewise.
12772 (clean): Handle powerpc-cell32l.c and powerpc-cell64l.c.
12773 * linux-ppc-low.c (PPC_FEATURE_CELL): Define.
12774 (init_registers_powerpc_cell32l): Add prototype.
12775 (init_registers_powerpc_cell64l): Likewise.
12776 (ppc_arch_setup): Detect Cell/B.E. architecture.
12777
12778 2009-07-30 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
12779
12780 * Makefile.in (datarootdir): New variable.
12781
12782 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
12783
12784 * linux-low.c (linux_write_memory): Update debugging output.
12785 * Makefile.in (clean): Add new descriptions.
12786 (arm-with-vfpv2.o, arm-with-vfpv2.c, arm-with-vfpv3.o)
12787 (arm-with-vfpv3.c, arm-with-neon.o, arm-with-neon.c): New rules.
12788 * configure.srv: Add new files for arm*-*-linux*.
12789 * linux-arm-low.c: Add new declarations.
12790 (PTRACE_GETVFPREGS, PTRACE_SETVFPREGS): Define if undefined.
12791 (arm_hwcap, HWCAP_VFP, HWCAP_IWMMXT, HWCAP_NEON, HWCAP_VFPv3)
12792 (HWCAP_VFPv3D16): New.
12793 (arm_fill_wmmxregset, arm_store_wmmxregset): Check HWCAP_IWMMXT
12794 instead of __IWMMXT__.
12795 (arm_fill_vfpregset, arm_store_vfpregset, arm_get_hwcap)
12796 (arm_arch_setup): New.
12797 (target_regsets): Remove #ifdef. Add VFP regset.
12798 (the_low_target): Use arm_arch_setup.
12799
12800 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
12801
12802 * linux-low.c (linux_kill_one_lwp): Adjust kernel workaround to skip
12803 the main thread again.
12804
12805 2009-07-06 Aleksandar Ristovski <aristovski@qnx.com>
12806
12807 Adding Neutrino gdbserver.
12808 * configure: Regenerated.
12809 * configure.ac: Add case for srv_qnx and set LIBS accordingly.
12810 * configure.srv (i[34567]86-*-nto*): New target.
12811 * nto-low.c, nto-low.h, nto-x86-low.c: New files.
12812 * remote-utils.c [__QNX__]: Include sys/iomgr.h
12813 (nto_comctrl) [__QNX__]: New function.
12814 (enable_async_io, disable_async_io) [__QNX__]: Call nto_comctrl.
12815
12816 2009-07-05 Danny Backx <dannybackx@users.sourceforge.net>
12817
12818 * configure.srv (i[34567]86-*-mingw32ce*): Add i386-low.o to
12819 srv_tgtobj.
12820
12821 2009-07-04 Danny Backx <dannybackx@users.sourceforge.net>
12822 Pedro Alves <pedro@codesourcery.com>
12823
12824 * win32-i386-low.c (i386_get_thread_context): Handle systems that
12825 don't support CONTEXT_EXTENDED_REGISTERS.
12826 (i386_win32_breakpoint, i386_win32_breakpoint_len): New.
12827 (the_low_target): Install them.
12828 * win32-low.c (get_child_debug_event): Handle WaitForDebugEvent
12829 failing with ERROR_PIPE_NOT_CONNECTED.
12830
12831 2009-06-30 Doug Evans <dje@google.com>
12832 Pierre Muller <muller@ics.u-strasbg.fr>
12833
12834 Add h/w watchpoint support to x86-linux, win32-i386.
12835 * Makefile.in (SFILES): Add i386-low.c
12836 (i386_low_h): Define.
12837 (i386-low.o): Add dependencies.
12838 (linux-x86-low.o): Add i386-low.h dependency.
12839 (win32-i386-low.o): Ditto.
12840 * i386-low.c: New file.
12841 * i386-low.h: New file.
12842 * configure.srv (i[34567]86-*-cygwin*): Add i386-low.o to srv_tgtobj.
12843 (i[34567]86-*-linux*, i[34567]86-*-mingw*, x86_64-*-linux*): Ditto.
12844 * linux-low.c (linux_add_process): Initialize arch_private.
12845 (linux_remove_process): Free arch_private.
12846 (add_lwp): Initialize arch_private.
12847 (delete_lwp): Free arch_private.
12848 (linux_resume_one_lwp): Call the_low_target.prepare_to_resume if
12849 provided.
12850 * linux-low.h (process_info_private): New member arch_private.
12851 (lwp_info): New member arch_private.
12852 (linux_target_ops): New members new_process, new_thread,
12853 prepare_to_resume.
12854 (ptid_of): New macro.
12855 * linux-x86-low.c: Include stddef.h, i386-low.h.
12856 (arch_process_info): New struct.
12857 (arch_lwp_info): New struct.
12858 (x86_linux_dr_get, x86_linux_dr_set): New functions.
12859 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
12860 (i386_dr_low_get_status): New function.
12861 (x86_insert_point, x86_remove_point): New functions.
12862 (x86_stopped_by_watchpoint): New function.
12863 (x86_stopped_data_address): New function.
12864 (x86_linux_new_process, x86_linux_new_thread): New functions.
12865 (x86_linux_prepare_to_resume): New function.
12866 (the_low_target): Add entries for insert_point, remove_point,
12867 stopped_by_watchpoint, stopped_data_address, new_process, new_thread,
12868 prepare_to_resume.
12869 * server.c (debug_hw_points): New global.
12870 (monitor_show_help): Document set debug-hw-points.
12871 (handle_query): Process "set debug-hw-points".
12872 * server.h (debug_hw_points): Declare.
12873 (paddress): Declare.
12874 * utils.c (NUMCELLS, CELLSIZE): New macros.
12875 (get_sell, xsnprintf, paddress): New functions.
12876 * win32-arm-low.c (the_low_target): Add entries for insert_point,
12877 remove_point, stopped_by_watchpoint, stopped_data_address.
12878 * win32-i386-low.c: Include i386-low.h.
12879 (debug_reg_state): Replaces dr.
12880 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
12881 (i386_dr_low_get_status): New function.
12882 (i386_insert_point, i386_remove_point): New functions.
12883 (i386_stopped_by_watchpoint): New function.
12884 (i386_stopped_data_address): New function.
12885 (i386_initial_stuff): Update.
12886 (get_thread_context,set_thread_context,i386_thread_added): Update.
12887 (the_low_target): Add entries for insert_point,
12888 remove_point, stopped_by_watchpoint, stopped_data_address.
12889 * win32-low.c (win32_insert_watchpoint): New function.
12890 (win32_remove_watchpoint): New function.
12891 (win32_stopped_by_watchpoint): New function.
12892 (win32_stopped_data_address): New function.
12893 (win32_target_ops): Add entries for insert_watchpoint,
12894 remove_watchpoint, stopped_by_watchpoint, stopped_data_address.
12895 * win32-low.h (win32_target_ops): New members insert_point,
12896 remove_point, stopped_by_watchpoint, stopped_data_address.
12897
12898 2009-06-25 Pedro Alves <pedro@codesourcery.com>
12899
12900 * server.c (process_serial_event): Re-return unsupported, not
12901 error, if the type isn't recognized. Re-allow supporting only
12902 insert or remove packets. Also call require_running for
12903 breakpoints. Add missing break statement to default case. Tidy.
12904 * target.h (struct target_ops): Rename insert_watchpoint to
12905 insert_point, and remove_watchpoint to remove_point.
12906
12907 * linux-low.h (struct linux_target_ops): Likewise.
12908 * linux-low.c (linux_insert_watchpoint): Rename to ...
12909 (linux_insert_point): ... this. Adjust.
12910 (linux_remove_watchpoint): Rename to ...
12911 (linux_remove_point): ... this. Adjust.
12912 (linux_target_ops): Adjust.
12913 * linux-crisv32-low.c (cris_insert_watchpoint): Rename to ...
12914 (cris_insert_point): ... this.
12915 (cris_remove_watchpoint): Rename to ...
12916 (cris_remove_point): ... this.
12917 (the_low_target): Adjust.
12918
12919 2009-06-24 Pierre Muller <muller@ics.u-strasbg.fr>
12920
12921 * server.c (handle_v_kill): Pass signal_pid to
12922 kill_inferior if multi_process is zero.
12923
12924 2009-06-23 Aleksandar Ristovski <aristovski@qnx.com>
12925
12926 * server.c (process_serial_event): Add support for Z0 and Z1 packet.
12927 * target.h (target_ops): Comment for *_watchpoint to make it clear
12928 the functions can get types '0' and '1'.
12929
12930 2009-06-22 Aleksandar Ristovski <aristovski@qnx.com>
12931
12932 * linux-low.c (usr_fetch_inferior_registers): Remove check for regno 0.
12933 * proc-service.c (ps_lgetregs): Pass -1 to fetch all registers.
12934 * regcache.c (get_regcache): Likewise.
12935 * spu-low.c (spu_fetch_registers): Remove 0 to -1 conversion.
12936 * win32-low.c (child_fetch_inferior_registers): Remove check for
12937 regno 0.
12938
12939 2009-06-19 Aleksandar Ristovski <aristovski@qnx.com>
12940 Pedro Alves <pedro@codesourcery.com>
12941
12942 * target.h (struct target_ops) <supports_multi_process>: New
12943 callback.
12944 (target_supports_multi_process): New.
12945 * server.c (handle_query): Even if GDB reports support, only
12946 enable multi-process if the target also supports it. Report
12947 multi-process support only if the target backend supports it.
12948 * linux-low.c (linux_supports_multi_process): New function.
12949 (linux_target_ops): Install it as target_supports_multi_process
12950 callback.
12951
12952 2009-05-24 Doug Evans <dje@google.com>
12953
12954 Global renaming of find_thread_pid to find_thread_ptid.
12955 * server.h (find_thread_ptid): Renamed from find_thread_pid.
12956 * inferiors.c (find_thread_ptid): Renamed from find_thread_pid.
12957 All callers updated.
12958
12959 * linux-low.c (handle_extended_wait): Use linux_resume_one_lwp
12960 to resume the newly created thread, don't call ptrace (PTRACE_CONT)
12961 directly.
12962
12963 * linux-low.c (get_stop_pc): Print pc if debug_threads.
12964 (check_removed_breakpoint, linux_wait_for_lwp): Ditto.
12965 (linux_resume_one_lwp): Ditto.
12966
12967 2009-05-23 Doug Evans <dje@google.com>
12968
12969 * linux-low.c (linux_resume_one_lwp): Change type of first arg
12970 from struct inferior_list_entry * to struct lwp_info *.
12971 All callers updated.
12972
12973 2009-05-13 Doug Evans <dje@google.com>
12974
12975 * linux-x86-low.c: Don't include assert.h.
12976 (x86_siginfo_fixup): Use fatal, not assert.
12977 (x86_arch_setup): Fix comment.
12978
12979 2009-05-12 Doug Evans <dje@google.com>
12980
12981 Biarch support for i386/amd64 gdbserver.
12982 * Makefile.in (SFILES): Remove linux-i386-low.c, linux-x86-64-low.c.
12983 Add linux-x86-low.c.
12984 (linux-i386-low.o, linux-x86-64-low.o): Delete.
12985 (linux-x86-low.o): Add.
12986 * linux-x86-64-low.c: Delete.
12987 * linux-i386-low.c: Delete.
12988 * linux-x86-low.c: New file.
12989 * configure.srv (i?86-linux srv_tgtobj): Replace linux-i386-low.o with
12990 linux-x86-low.o.
12991 (x86_64-linux srv_tgtobj): Replace linux-x86-64-low.o with
12992 linux-x86-low.o.
12993 (x86_64-linux srv_regobj): Add reg-i386-linux.o.
12994 * linux-low.c: Include ansidecl.h, elf/common.h, elf/external.h.
12995 (linux_child_pid_to_exec_file): New function.
12996 (elf_64_header_p, elf_64_file_p): New functions.
12997 (siginfo_fixup): New function.
12998 (linux_xfer_siginfo): New local inf_siginfo. Call siginfo_fixup to
12999 give target a chance to convert layout.
13000 * linux-low.h (linux_target_ops): New member siginfo_fixup.
13001 (linux_child_pid_to_exec_file, elf_64_file_p): Declare.
13002
13003 2009-05-07 Doug Evans <dje@google.com>
13004
13005 * linux-low.c (regsets_fetch_inferior_registers): Fix memory leak.
13006 (regsets_store_inferior_registers): Ditto.
13007
13008 2009-05-06 Pedro Alves <pedro@codesourcery.com>
13009
13010 PR server/10048
13011
13012 * linux-low.c (must_set_ptrace_flags): Delete.
13013 (linux_create_inferior): Set `lwp->must_set_ptrace_flags' instead
13014 of the global.
13015 (linux_attach_lwp_1): Don't set PTRACE_SETOPTIONS here. Set
13016 `lwp->must_set_ptrace_flags' instead.
13017 (linux_wait_for_event_1): Set ptrace options here.
13018 (linux_wait_1): ... not here.
13019
13020 2009-04-30 Doug Evans <dje@google.com>
13021
13022 * inferiors.c (started_inferior_callback): New function.
13023 (attached_inferior_callback): New function.
13024 (have_started_inferiors_p, have_attached_inferiors_p): New functions.
13025 * server.c (print_started_pid, print_attached_pid): New functions.
13026 (detach_or_kill_for_exit): New function.
13027 (main): Call it instead of for_each_inferior (kill_inferior_callback).
13028 * server.h (have_started_inferiors_p): Declare.
13029 (have_attached_inferiors_p): Declare.
13030
13031 * inferiors.c (remove_process): Fix memory leak, free process.
13032 * linux-low.c (linux_remove_process): New function.
13033 (linux_kill): Call it instead of remove_process.
13034 (linux_detach, linux_wait_1): Ditto.
13035
13036 2009-04-19 Danny Backx <dannybackx@users.sourceforge.net>
13037
13038 * configure.srv: Add x86 Windows CE target.
13039
13040 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
13041
13042 * inferiors.c (get_thread_process): Make global.
13043 * server.h (get_thread_process): Add prototype.
13044 * thread-db.c (find_one_thread): Use get_thread_process
13045 instead of current_process.
13046 (thread_db_get_tls_address): Do not crash if called when
13047 thread layer is not yet initialized.
13048
13049 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
13050
13051 * remote-utils.c (prepare_resume_reply): Null-terminate packet.
13052 * spu-low.c (current_tid): Rename to ...
13053 (current_ptid): ... this.
13054 (fetch_ppc_register, fetch_ppc_memory, store_ppc_memory,
13055 spu_proc_xfer_spu, spu_resume, spu_request_interrupt): Use
13056 ptid_get_lwp (current_ptid) instead of current_tid.
13057 (spu_kill, spu_detach, spu_join, spu_wait): Use pid argument
13058 instead of current_tid. Use find_process_pid to verify pid
13059 argument is valid. Pass proper argument to remove_process.
13060 (spu_thread_alive): Compare current_ptid instead of current_tid.
13061 (spu_resume): Likewise.
13062
13063 2009-04-02 Pedro Alves <pedro@codesourcery.com>
13064
13065 * linux-low.c (usr_store_inferior_registers): Declare local `pid'
13066 variable.
13067
13068 2009-04-01 Pedro Alves <pedro@codesourcery.com>
13069
13070 Implement the multiprocess extensions, and add linux multiprocess
13071 support.
13072
13073 * server.h (ULONGEST): Declare.
13074 (struct ptid, ptid_t): New.
13075 (minus_one_ptid, null_ptid): Declare.
13076 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
13077 (ptid_get_tid, ptid_equal, ptid_is_pid): Declare.
13078 (struct inferior_list_entry): Change `id' type from unsigned from
13079 to ptid_t.
13080 (struct sym_cache, struct breakpoint, struct
13081 process_info_private): Forward declare.
13082 (struct process_info): Declare.
13083 (current_process): Declare.
13084 (all_processes): Declare.
13085 (initialize_inferiors): Declare.
13086 (add_thread): Adjust to use ptid_t.
13087 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): Ditto.
13088 (add_process, remove_process, find_thread_pid): Declare.
13089 (find_inferior_id): Adjust to use ptid_t.
13090 (cont_thread, general_thread, step_thread): Change type to ptid_t.
13091 (multi_process): Declare.
13092 (push_event): Adjust to use ptid_t.
13093 (read_ptid, write_ptid): Declare.
13094 (prepare_resume_reply): Adjust to use ptid_t.
13095 (clear_symbol_cache): Declare.
13096 * inferiors.c (all_processes): New.
13097 (null_ptid, minus_one_ptid): New.
13098 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
13099 (ptid_get_tid, ptid_equal, ptid_is_pid): New.
13100 (add_thread): Change unsigned long to ptid. Remove gdb_id
13101 parameter. Adjust.
13102 (thread_id_to_gdb_id, thread_to_gdb_id): Change unsigned long to ptid.
13103 (gdb_id_to_thread): Rename to ...
13104 (find_thread_pid): ... this. Change unsigned long to ptid.
13105 (gdb_id_to_thread_id, find_inferior_id): Change unsigned long to ptid.
13106 (loaded_dll, pull_pid_from_list): Adjust.
13107 (add_process, remove_process, find_process_pid)
13108 (get_thread_process, current_process, initialize_inferiors): New.
13109 * target.h (struct thread_resume) <thread>: Change type to ptid_t.
13110 (struct target_waitstatus) <related_pid>: Ditto.
13111 (struct target_ops) <kill, detach>: Add `pid' argument. Change
13112 return type to int.
13113 (struct target_ops) <join>: Add `pid' argument.
13114 (struct target_ops) <thread_alive>: Change pid's type to ptid_t.
13115 (struct target_ops) <wait>: Add `ptid' field. Change return type
13116 to ptid.
13117 (kill_inferior, detach_inferior, join_inferior): Add `pid' argument.
13118 (mywait): Add `ptid' argument. Change return type to ptid_t.
13119 (target_pid_to_str): Declare.
13120 * target.c (set_desired_inferior): Adjust to use ptids.
13121 (mywait): Add new `ptid' argument. Adjust.
13122 (target_pid_to_str): New.
13123 * mem-break.h (free_all_breakpoints): Declare.
13124 * mem-break.c (breakpoints): Delelete.
13125 (set_breakpoint_at, delete_breakpoint, find_breakpoint_at)
13126 (check_mem_read, check_mem_write, delete_all_breakpoints): Adjust
13127 to use per-process breakpoint list.
13128 (free_all_breakpoints): New.
13129 * remote-utils.c (struct sym_cache) <name>: Drop `const'.
13130 (symbol_cache, all_symbols_looked_up): Delete.
13131 (hexchars): New.
13132 (ishex, unpack_varlen_hex, write_ptid, hex_or_minus_one,
13133 read_ptid): New.
13134 (prepare_resume_reply): Change ptid argument's type from unsigned
13135 long to ptid_t. Adjust. Implement W;process and X;process.
13136 (free_sym_cache, clear_symbol_cache): New.
13137 (look_up_one_symbol): Adjust to per-process symbol cache. *
13138 * server.c (cont_thread, general_thread, step_thread): Change type
13139 to ptid_t.
13140 (attached): Delete.
13141 (multi_process): New.
13142 (last_ptid): Change type to ptid_t.
13143 (struct vstop_notif) <ptid>: Change type to ptid_t.
13144 (queue_stop_reply, push_event): Change `ptid' argument's type to
13145 ptid_t.
13146 (discard_queued_stop_replies): Add `pid' argument.
13147 (start_inferior): Adjust to use ptids. Adjust to mywait interface
13148 changes. Don't reference the `attached' global.
13149 (attach_inferior): Adjust to mywait interface changes.
13150 (handle_query): Adjust to use ptids. Parse GDB's qSupported
13151 features. Handle and report "multiprocess+". Handle
13152 "qAttached:PID".
13153 (handle_v_cont): Adjust to use ptids. Adjust to mywait interface
13154 changes.
13155 (handle_v_kill): New.
13156 (handle_v_stopped): Adjust to use target_pid_to_str.
13157 (handle_v_requests): Allow multiple attaches and runs when
13158 multiprocess extensions are in effect. Handle "vKill".
13159 (myresume): Adjust to use ptids.
13160 (queue_stop_reply_callback): Add `arg' parameter. Handle it.
13161 (handle_status): Adjust to discard_queued_stop_replies interface
13162 change.
13163 (first_thread_of, kill_inferior_callback)
13164 (detach_or_kill_inferior_callback, join_inferiors_callback): New.
13165 (main): Call initialize_inferiors. Adjust to use ptids, killing
13166 and detaching from all inferiors. Handle multiprocess packet
13167 variants.
13168 * linux-low.h: Include gdb_proc_service.h.
13169 (struct process_info_private): New.
13170 (struct linux_target_ops) <pid_of>: Use ptid_get_pid.
13171 <lwpid_of>: Use ptid_get_lwp.
13172 (get_lwp_thread): Adjust.
13173 (struct lwp_info): Add `dead' member.
13174 (find_lwp_pid): Declare.
13175 * linux-low.c (thread_db_active): Delete.
13176 (new_inferior): Adjust comment.
13177 (inferior_pid): Delete.
13178 (linux_add_process): New.
13179 (handle_extended_wait): Adjust.
13180 (add_lwp): Change unsigned long to ptid.
13181 (linux_create_inferior): Add process to processes table. Adjust
13182 to use ptids. Don't set new_inferior here.
13183 (linux_attach_lwp): Rename to ...
13184 (linux_attach_lwp_1): ... this. Add `initial' argument. Handle
13185 it. Adjust to use ptids.
13186 (linux_attach_lwp): New.
13187 (linux_attach): Add process to processes table. Don't set
13188 new_inferior here.
13189 (struct counter): New.
13190 (second_thread_of_pid_p, last_thread_of_process_p): New.
13191 (linux_kill_one_lwp): Add `args' parameter. Handle it. Adjust to
13192 multiple processes.
13193 (linux_kill): Add `pid' argument. Handle it. Adjust to multiple
13194 processes. Remove process from process table.
13195 (linux_detach_one_lwp): Add `args' parameter. Handle it. Adjust
13196 to multiple processes.
13197 (any_thread_of): New.
13198 (linux_detach): Add `pid' argument, and handle it. Remove process
13199 from processes table.
13200 (linux_join): Add `pid' argument. Handle it.
13201 (linux_thread_alive): Change unsighed long argument to ptid_t.
13202 Consider dead lwps as not being alive.
13203 (status_pending_p): Rename `dummy' argument to `arg'. Filter out
13204 threads we're not interested in.
13205 (same_lwp, find_lwp_pid): New.
13206 (linux_wait_for_lwp): Change `pid' argument's type from int to
13207 ptid_t. Adjust.
13208 (linux_wait_for_event): Rename to ...
13209 (linux_wait_for_event_1): ... this. Change `pid' argument's type
13210 from int to ptid_t. Adjust.
13211 (linux_wait_for_event): New.
13212 (linux_wait_1): Add `ptid' argument. Change return type to
13213 ptid_t. Adjust. Use last_thread_of_process_p. Remove processes
13214 that exit from the process table.
13215 (linux_wait): Add `ptid' argument. Change return type to ptid_t.
13216 Adjust.
13217 (mark_lwp_dead): New.
13218 (wait_for_sigstop): Adjust to use ptids. If a process exits while
13219 stopping all threads, mark its main lwp as dead.
13220 (linux_set_resume_request, linux_resume_one_thread): Adjust to use
13221 ptids.
13222 (fetch_register, usr_store_inferior_registers)
13223 (regsets_fetch_inferior_registers)
13224 (regsets_store_inferior_registers, linux_read_memory)
13225 (linux_write_memory): Inline `inferior_pid'.
13226 (linux_look_up_symbols): Adjust to use per-process
13227 `thread_db_active'.
13228 (linux_request_interrupt): Adjust to use ptids.
13229 (linux_read_auxv): Inline `inferior_pid'.
13230 (initialize_low): Don't reference thread_db_active.
13231 * gdb_proc_service.h (struct ps_prochandle) <pid>: Remove.
13232 * proc-service.c (ps_lgetregs): Use find_lwp_pid.
13233 (ps_getpid): Return the pid of the current inferior.
13234 * thread-db.c (proc_handle, thread_agent): Delete.
13235 (thread_db_create_event, thread_db_enable_reporting): Adjust to
13236 per-process data.
13237 (find_one_thread): Change argument type to ptid_t. Adjust to
13238 per-process data.
13239 (maybe_attach_thread): Adjust to per-process data and ptids.
13240 (thread_db_find_new_threads): Ditto.
13241 (thread_db_init): Ditto.
13242 * spu-low.c (spu_create_inferior, spu_attach): Add process to
13243 processes table. Adjust to use ptids.
13244 (spu_kill, spu_detach): Adjust interface. Remove process from
13245 processes table.
13246 (spu_join, spu_thread_alive): Adjust interface.
13247 (spu_wait): Adjust interface. Remove process from processes
13248 table. Adjust to use ptids.
13249 * win32-low.c (current_inferior_tid): Delete.
13250 (current_inferior_ptid): New.
13251 (debug_event_ptid): New.
13252 (thread_rec): Take a ptid. Adjust.
13253 (child_add_thread): Add `pid' argument. Adjust to use ptids.
13254 (child_delete_thread): Ditto.
13255 (do_initial_child_stuff): Add `attached' argument. Add process to
13256 processes table.
13257 (child_fetch_inferior_registers, child_store_inferior_registers):
13258 Adjust.
13259 (win32_create_inferior): Pass 0 to do_initial_child_stuff.
13260 (win32_attach): Pass 1 to do_initial_child_stuff.
13261 (win32_kill): Adjust interface. Remove process from processes
13262 table.
13263 (win32_detach): Ditto.
13264 (win32_join): Adjust interface.
13265 (win32_thread_alive): Take a ptid.
13266 (win32_resume): Adjust to use ptids.
13267 (get_child_debug_event): Ditto.
13268 (win32_wait): Adjust interface. Remove exiting process from
13269 processes table.
13270
13271 2009-04-01 Pedro Alves <pedro@codesourcery.com>
13272
13273 Non-stop mode support.
13274
13275 * server.h (non_stop): Declare.
13276 (gdb_client_data, handler_func): Declare.
13277 (delete_file_handler, add_file_handler, start_event_loop):
13278 Declare.
13279 (handle_serial_event, handle_target_event, push_event)
13280 (putpkt_notif): Declare.
13281 * target.h (enum resume_kind): New.
13282 (struct thread_resume): Replace `step' field by `kind' field.
13283 (TARGET_WNOHANG): Define.
13284 (struct target_ops) <wait>: Add `options' argument.
13285 <supports_non_stop, async, start_non_stop>: New fields.
13286 (target_supports_non_stop, target_async): New.
13287 (start_non_stop): Declare.
13288 (mywait): Add `options' argument.
13289 * target.c (mywait): Add `options' argument. Print child exit
13290 notifications here.
13291 (start_non_stop): New.
13292 * server.c (non_stop, own_buf, mem_buf): New globals.
13293 (struct vstop_notif): New.
13294 (notif_queue): New global.
13295 (queue_stop_reply, push_event, discard_queued_stop_replies)
13296 (send_next_stop_reply): New.
13297 (start_inferior): Adjust to use resume_kind. Adjust to mywait
13298 interface changes.
13299 (attach_inferior): In non-stop mode, don't wait for the target
13300 here.
13301 (handle_general_set): Handle QNonStop.
13302 (handle_query): When handling qC, return the current general
13303 thread, instead of the first thread of the list.
13304 (handle_query): If the backend supports non-stop mode, include
13305 QNonStop+ in the qSupported query response.
13306 (handle_v_cont): Adjust to use resume_kind. Handle resume_stop
13307 and non-stop mode.
13308 (handle_v_attach, handle_v_run): Handle non-stop mode.
13309 (handle_v_stopped): New.
13310 (handle_v_requests): Report support for vCont;t. Handle vStopped.
13311 (myresume): Adjust to use resume_kind. Handle non-stop.
13312 (queue_stop_reply_callback): New.
13313 (handle_status): Handle non-stop mode.
13314 (main): Clear non_stop flag on reconnection. Use the event-loop.
13315 Refactor serial protocol handling from here ...
13316 (process_serial_event): ... to this new function. When GDB
13317 selects any thread, select one here. In non-stop mode, wait until
13318 GDB acks all pending events before exiting.
13319 (handle_serial_event, handle_target_event): New.
13320 * remote-utils.c (remote_open): Install remote_desc in the event
13321 loop.
13322 (remote_close): Remove remote_desc from the event loop.
13323 (putpkt_binary): Rename to...
13324 (putpkt_binary_1): ... this. Add `is_notic' argument. Handle it.
13325 (putpkt_binary): New as wrapper around putpkt_binary_1.
13326 (putpkt_notif): New.
13327 (prepare_resume_reply): In non-stop mode, don't change the
13328 general_thread.
13329 * event-loop.c: New.
13330 * Makefile.in (OBJ): Add event-loop.o.
13331 (event-loop.o): New rule.
13332
13333 * linux-low.h (pid_of): Moved here.
13334 (lwpid_of): New.
13335 (get_lwp_thread): Use lwpid_of.
13336 (struct lwp_info): Delete `lwpid' field. Add `suspended' field.
13337 * linux-low.c (pid_of): Delete.
13338 (inferior_pid): Use lwpid_of.
13339 (linux_event_pipe): New.
13340 (target_is_async_p): New.
13341 (delete_lwp): New.
13342 (handle_extended_wait): Use lwpid_of.
13343 (add_lwp): Don't set lwpid field.
13344 (linux_attach_lwp): Adjust debug output. Use lwpid_of.
13345 (linux_kill_one_lwp): If killing a running lwp, stop it first.
13346 Use lwpid_of. Adjust to linux_wait_for_event interface changes.
13347 (linux_detach_one_lwp): If detaching from a running lwp, stop it
13348 first. Adjust to linux_wait_for_event interface changes. Use
13349 lwpid_of.
13350 (linux_detach): Don't delete the main lwp here.
13351 (linux_join): Use my_waitpid. Avoid signal_pid. Use lwpid_of.
13352 (status_pending_p): Don't consider explicitly suspended lwps.
13353 (linux_wait_for_lwp): Take an integer pid instead of a lwp_info
13354 pointer. Add OPTIONS argument. Change return type to int. Use
13355 my_waitpid instead of sleeping. Handle WNOHANG. Use lwpid_of.
13356 (linux_wait_for_event): Take an integer pid instead of a lwp_info
13357 pointer. Add status pointer argument. Return a pid instead of a
13358 status. Use lwpid_of. Adjust to linux_wait_for_lwp interface
13359 changes. In non-stop mode, don't switch to a random thread.
13360 (linux_wait): Rename to...
13361 (linux_wait_1): ... this. Add target_options argument, and handle
13362 it. Adjust to use resume_kind. Use lwpid_of. In non-stop mode,
13363 don't handle the continue thread. Handle TARGET_WNOHANG. Merge
13364 clean exit and signal exit code. Don't stop all threads in
13365 non-stop mode. In all-stop mode, only stop all threads when
13366 reporting a stop to GDB. Handle explicit thread stop requests.
13367 (async_file_flush, async_file_mark): New.
13368 (linux_wait): New.
13369 (send_sigstop): Use lwpid_of.
13370 (wait_for_sigstop): Use lwpid_of. Adjust to linux_wait_for_event
13371 interface changes. In non-stop mode, don't switch to a random
13372 thread.
13373 (linux_resume_one_lwp): Use lwpid_of.
13374 (linux_continue_one_thread, linux_queue_one_thread): Merge into ...
13375 (linux_resume_one_thread): ... this. Handle resume_stop. In
13376 non-stop mode, don't look for pending flag in all threads.
13377 (resume_status_pending_p): Don't consider explicitly suspended
13378 threads.
13379 (my_waitpid): Reimplement. Emulate __WALL.
13380 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
13381 Use lwpid_of.
13382 (sigchld_handler, linux_supports_non_stop, linux_async)
13383 (linux_start_non_stop): New.
13384 (linux_target_ops): Register linux_supports_non_stop, linux_async
13385 and linux_start_non_stop.
13386 (initialize_low): Install SIGCHLD handler.
13387 * thread-db.c (thread_db_create_event, find_one_thread)
13388 (thread_db_get_tls_address): Use lwpid_of.
13389 * win32-low.c (win32_detach): Adjust to use resume_kind.
13390 (win32_wait): Add `options' argument.
13391 * spu-low.c (spu_resume): Adjust to use resume_kind.
13392 (spu_wait): Add `options' argument.
13393
13394 2009-04-01 Pedro Alves <pedro@codesourcery.com>
13395
13396 Decouple target code from remote protocol.
13397
13398 * target.h (enum target_waitkind): New.
13399 (struct target_waitstatus): New.
13400 (struct target_ops) <wait>: Return an unsigned long. Take a
13401 target_waitstatus pointer instead of a char pointer.
13402 (mywait): Likewise.
13403 * target.c (mywait): Change prototype to return an unsigned long.
13404 Take a target_waitstatus pointer instead of a char pointer. Adjust.
13405 * server.h (thread_from_wait, old_thread_from_wait): Delete
13406 declarations.
13407 (prepare_resume_reply): Change prototype to take a
13408 target_waitstatus.
13409 * server.c (thread_from_wait, old_thread_from_wait): Delete.
13410 (last_status, last_ptid): New.
13411 (start_inferior): Remove "statusptr" argument. Adjust. Return a
13412 pid instead of a signal.
13413 (attach_inferior): Remove "status" and "signal" parameters.
13414 Adjust.
13415 (handle_query): For qGetTLSAddr, parse the thread id with strtol,
13416 not as an address.
13417 (handle_v_cont, handle_v_attach, handle_v_run, handle_v_kill)
13418 (handle_v_requests, myresume): Remove "status" and "signal"
13419 parameters. Adjust.
13420 (handle_status): New.
13421 (main): Delete local `status'. Adjust.
13422 * remote-utils.c: Include target.h.
13423 (prepare_resume_reply): Change prototype to take a
13424 target_waitstatus. Adjust.
13425
13426 * linux-low.c (linux_wait): Adjust to new target_ops->wait
13427 interface.
13428 * spu-low.c (spu_wait): Adjust.
13429 * win32-low.c (enum target_waitkind, struct target_waitstatus):
13430 Delete.
13431 (win32_wait): Adjust.
13432
13433 2009-04-01 Pedro Alves <pedro@codesourcery.com>
13434
13435 * target.h (struct thread_resume): Delete leave_stopped member.
13436 (struct target_ops): Add a `n' argument to the `resume' callback.
13437 * server.c (start_inferior): Adjust.
13438 (handle_v_cont, myresume): Adjust.
13439 * linux-low.c (check_removed_breakpoint): Adjust to resume
13440 interface change, and to removed leave_stopped field.
13441 (resume_ptr): Delete.
13442 (struct thread_resume_array): New.
13443 (linux_set_resume_request): Add new `arg' parameter. Adjust to
13444 resume interface change.
13445 (linux_continue_one_thread, linux_queue_one_thread)
13446 (resume_status_pending_p): Check if the resume field is NULL
13447 instead of checking the leave_stopped member.
13448 (linux_resume): Adjust to the target resume interface change.
13449 * spu-low.c (spu_resume): Adjust to the target resume interface
13450 change.
13451 * win32-low.c (win32_detach, win32_resume): Ditto.
13452
13453 2009-04-01 Pedro Alves <pedro@codesourcery.com>
13454
13455 * linux-low.c (linux_wait_for_event): Don't clear the `stepping'
13456 flag.
13457 (wait_for_sigstop): Don't leave a finished single-step SIGTRAP
13458 pending.
13459 (linux_continue_one_thread): Only preserve the stepping flag if
13460 there's a pending breakpoint.
13461
13462 2009-03-31 Pedro Alves <pedro@codesourcery.com>
13463
13464 * server.c (main): After the inferior having exited, call
13465 remote_close before exiting gdbserver.
13466
13467 2009-03-25 Thiago Jung Bauermann <bauerman@br.ibm.com>
13468
13469 Fix size of FPSCR in Power 7 processors.
13470 * linux-ppc-low.c (PPC_FEATURE_ARCH_2_05): Remove #define.
13471 (PPC_FEATURE_HAS_DFP): New #define.
13472 (ppc_arch_setup): Check for DFP feature instead of ISA 2.05 to decide on
13473 size of the FPSCR.
13474
13475 2009-03-23 Pedro Alves <pedro@codesourcery.com>
13476
13477 * server.c (handle_query) Whitespace and formatting.
13478
13479 2009-03-22 Pedro Alves <pedro@codesourcery.com>
13480
13481 * i387-fp.c, linux-arm-low.c, linux-cris-low.c,
13482 linux-crisv32-low.c, linux-i386-low.c, linux-low.c,
13483 linux-mips-low.c, linux-s390-low.c, linux-sparc-low.c,
13484 linux-x86-64-low.c, linux-xtensa-low.c, proc-service.c,
13485 regcache.c, remote-utils.c, server.c, spu-low.c, target.h,
13486 thread-db.c, win32-low.c, xtensa-xtregs.c, gdbreplay.c,
13487 Makefile.in, configure.ac: Fix whitespace throughout.
13488 * configure: Regenerate.
13489
13490 2009-03-22 Pedro Alves <pedro@codesourcery.com>
13491
13492 * inferiors.c (find_inferior): Make it safe for the callback
13493 function to delete the currently iterated inferior.
13494
13495 2009-03-22 Pedro Alves <pedro@codesourcery.com>
13496
13497 * Makefile.in (linuw_low_h): Move higher.
13498 (thread-db.o): Depend on $(linux_low_h).
13499
13500 2009-03-17 Pedro Alves <pedro@codesourcery.com>
13501
13502 Rename "process" to "lwp" throughout.
13503
13504 * linux-low.c (all_processes): Rename to...
13505 (all_lwps): ... this.
13506 (inferior_pid, handle_extended_wait, get_stop_pc): Adjust.
13507 (add_process): Rename to ...
13508 (add_lwp): ... this. Adjust.
13509 (linux_create_inferior): Adjust.
13510 (linux_attach_lwp): Adjust.
13511 (linux_attach): Adjust.
13512 (linux_kill_one_process): Rename to ...
13513 (linux_kill_one_lwp): ... this. Adjust.
13514 (linux_kill): Adjust.
13515 (linux_detach_one_process): Rename to ...
13516 (linux_detach_one_lwp): ... this. Adjust.
13517 (linux_detach): Adjust.
13518 (check_removed_breakpoint): Adjust.
13519 (status_pending_p): Adjust.
13520 (linux_wait_for_process): Rename to ...
13521 (linux_wait_for_lwp): ... this. Adjust.
13522 (linux_wait_for_event): Adjust.
13523 (send_sigstop): Adjust.
13524 (wait_for_sigstop): Adjust.
13525 (stop_all_processes): Rename to ...
13526 (stop_all_lwps): ... this.
13527 (linux_resume_one_process): Rename to ...
13528 (linux_resume_one_lwp): ... this. Adjust.
13529 (linux_set_resume_request, linux_continue_one_thread)
13530 (linux_queue_one_thread, resume_status_pending_p)
13531 (usr_store_inferior_registers, regsets_store_inferior_registers)
13532 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
13533 Adjust.
13534 * linux-low.h (get_process): Rename to ...
13535 (get_lwp): ... this. Adjust.
13536 (get_thread_process): Rename to ...
13537 (get_thread_lwp): ... this. Adjust.
13538 (get_process_thread): Rename to ...
13539 (get_lwp_thread): ... this. Adjust.
13540 (struct process_info): Rename to ...
13541 (struct lwp_info): ... this.
13542 (all_processes): Rename to ...
13543 (all_lwps): ... this.
13544 * proc-service.c (ps_lgetregs): Adjust.
13545 * thread-db.c (thread_db_create_event, find_one_thread)
13546 (maybe_attach_thread, thread_db_get_tls_address): Adjust.
13547
13548 2009-03-14 Pedro Alves <pedro@codesourcery.com>
13549
13550 * server.c (handle_query): Handle "qAttached".
13551
13552 2009-03-13 Nathan Sidwell <nathan@codesourcery.com>
13553
13554 * Makefile.in, hostio-errno.c, errno.c, xtensa-xtregs.c: Change to
13555 GPLv3, update license URL.
13556
13557 2009-03-01 Doug Evans <dje@google.com>
13558
13559 * Makefile.in (INCLUDE_CFLAGS): Add -I$(srcdir)/../common.
13560 (server_h): Add gdb_signals.h.
13561 (signals.o): Update.
13562 * server.h (target_signal_from_host,target_signal_to_host_p)
13563 (target_signal_to_host,target_signal_to_name): Moved to gdb_signals.h.
13564
13565 2009-02-14 Pierre Muller <muller@ics.u-strasbg.fr>
13566
13567 * remote-utils.c (getpkt): Also generate remote-debug
13568 information if noack_mode is set.
13569
13570 2009-02-06 Pedro Alves <pedro@codesourcery.com>
13571
13572 * server.c (handle_query): Report qXfer:siginfo:read and
13573 qXfer:siginfo:write as supported and handle them.
13574 * target.h (struct target_ops) <qxfer_siginfo>: New field.
13575 * linux-low.c (linux_xfer_siginfo): New.
13576 (linux_target_ops): Set it.
13577
13578 2009-01-26 Pedro Alves <pedro@codesourcery.com>
13579
13580 * server.c (gdbserver_usage): Mention --remote-debug.
13581 (main): Accept '--remote-debug' switch.
13582
13583 2009-01-18 Doug Evans <dje@google.com>
13584
13585 * regcache.c (new_register_cache): No need to check result of xcalloc.
13586 * server.c (handle_search_memory): Back out calls to xmalloc,
13587 result is checked and error is returned to user upon failure.
13588 (handle_query): Ditto. Add more checks for result of malloc.
13589 (handle_v_cont): Check result of malloc, report error back to
13590 user upon failure.
13591 (handle_v_run): Ditto. Call freeargv.
13592 * server.h (freeargv): Declare.
13593 * utils.c (freeargv): New fn.
13594
13595 2009-01-15 Doug Evans <dje@google.com>
13596
13597 * gdbreplay.c (perror_with_name): Make arg const char *.
13598 * server.h (target_signal_to_name): Make return type const char *.
13599 * thread-db.c (thread_db_err_str): Make return type const char *.
13600 * utils.c (perror_with_name): Make arg const char *.
13601
13602 2009-01-14 Pedro Alves <pedro@codesourcery.com>
13603
13604 * win32-low.c (get_child_debug_event): Issue a final DBG_CONTINUE
13605 when handling a EXIT_PROCESS_DEBUG_EVENT.
13606
13607 2009-01-06 Joel Brobecker <brobecker@adacore.com>
13608
13609 * gdbreplay.c (gdbreplay_version): Update copyright year.
13610 * server.c (gdbserver_version): Likewise.
13611
13612 2009-01-05 Doug Evans <dje@google.com>
13613
13614 * linux-low.c (linux_attach_lwp): Add some comments/fixmes.
13615 (handle_extended_wait): Improve comment.
13616
13617 2008-12-13 Doug Evans <dje@google.com>
13618
13619 * utils.c (xmalloc,xcalloc,xstrdup): New fns.
13620 * server.h (ATTR_MALLOC): New macro.
13621 (xmalloc,xcalloc,xstrdup): Declare.
13622 * hostio.c: Replace malloc,calloc,strdup with xmalloc,xcalloc,xstrdup.
13623 * inferiors.c: Ditto.
13624 * linux-low.c: Ditto.
13625 * mem-break.c: Ditto.
13626 * regcache.c: Ditto.
13627 * remote-utils.c: Ditto.
13628 * server.c: Ditto.
13629 * target.c: Ditto.
13630 * win32-low.c: Ditto.
13631
13632 2008-12-12 Doug Evans <dje@google.com>
13633
13634 * linux-low.c (linux_wait_for_process): Don't clobber current_inferior
13635 in debugging printf.
13636
13637 * linux-low.c (handle_extended_wait): Simplify, use my_waitpid.
13638
13639 2008-12-09 Doug Evans <dje@google.com>
13640
13641 * linux-low.h (struct process_info): Delete member tid, unused.
13642 * thread-db.c (find_one_thread): Update.
13643 (maybe_attach_thread): Update.
13644
13645 2008-12-02 Pedro Alves <pedro@codesourcery.com>
13646
13647 * target.h (struct target_ops): Add qxfer_osdata member.
13648 * linux-low.c: Include ctype.h and pwd.h and sys/types.h
13649 and dirent.h.
13650 (linux_qxfer_osdata): New functions.
13651 (linux_target_ops): Register linux_qxfer_osdata as qxfer_osdata
13652 callback.
13653 * server.c (handle_query): Handle "qXfer:osdata:read:".
13654 * remote-utils.c (buffer_grow, buffer_free, buffer_init, buffer_finish)
13655 (buffer_xml_printf): New functions.
13656 * server.h (struct buffer): New.
13657 (buffer_grow_str, buffer_grow_str0): New macros.
13658 (buffer_grow, buffer_free, buffer_init, buffer_finish)
13659 (buffer_xml_printf): Declare.
13660
13661 2008-11-24 Doug Evans <dje@google.com>
13662
13663 * Makefile.in (VERSION,DIST,LINT,LINTFLAGS): Delete, unused.
13664
13665 2008-11-24 Daniel Jacobowitz <dan@codesourcery.com>
13666
13667 * server.c (handle_v_run): Always use the supplied argument list.
13668
13669 2008-11-19 Bob Wilson <bob.wilson@acm.org>
13670
13671 * xtensa-xtregs.c (XTENSA_ELF_XTREG_SIZE): Change to 4.
13672 (xtensa_regmap_table): Add entry for scompare1.
13673
13674 2008-11-18 Thiago Jung Bauermann <bauerman@br.ibm.com>
13675
13676 * Makefile.in (powerpc-isa205-32l.o, powerpc-isa205-32l.c,
13677 powerpc-isa205-altivec32l.o, powerpc-isa205-altivec32l.c,
13678 powerpc-isa205-vsx32l.o, powerpc-isa205-vsx32l.c,
13679 powerpc-isa205-64l.o, powerpc-isa205-64l.c,
13680 powerpc-isa205-altivec64l.o, powerpc-isa205-altivec64l.c,
13681 powerpc-isa205-vsx64l.o, powerpc-isa205-vsx64l.c): New targets.
13682 * configure.srv (powerpc*-*-linux*): Add ISA 2.05 object files and
13683 XML target descriptions.
13684 * linux-ppc-low.c (ppc_arch_setup): Init registers with 64-bit FPSCR
13685 when inferior is running on an ISA 2.05 or later processor. Add
13686 special case to return offset for full 64-bit slot of FPSCR when
13687 in 32-bits.
13688
13689 2008-11-14 Daniel Gutson <dgutson@codesourcery.com>
13690
13691 * Makefile.in (SFILES, clean): Added sparc64 files.
13692 (reg-sparc64.o, reg-sparc64.c): New.
13693 * configure.srv (sparc*-*-linux*): New configuration.
13694 * linux-low.c (regsets_fetch_inferior_registers): Swap ptrace
13695 syscall arguments for SPARC.
13696 (regsets_store_inferior_registers): Likewise.
13697 * linux-sparc-low.c: New file.
13698
13699 2008-10-21 Doug Evans <dje@google.com>
13700
13701 * Makefile.in (BFD_DIR,BFD,BFD_SRC,BFD_CFLAGS): Delete.
13702 (READLINE_DIR,READLINE_DEP): Delete.
13703 (INTERNAL_CFLAGS): Update.
13704 (LINTFLAGS): Update.
13705
13706 2008-10-10 Pedro Alves <pedro@codesourcery.com>
13707
13708 * server.c (handle_v_run): If GDB didn't specify an argv, use the
13709 whole argv from the last run, not just argv[0].
13710
13711 2008-09-08 Pedro Alves <pedro@codesourcery.com>
13712
13713 * regcache.c (new_register_cache): Return NULL if the register
13714 cache size isn't known yet.
13715 (free_register_cache): Avoid dereferencing a NULL regcache.
13716
13717 2008-09-04 Daniel Jacobowitz <dan@codesourcery.com>
13718
13719 * configure.srv: Merge MIPS and MIPS64.
13720
13721 2008-08-24 Maciej W. Rozycki <macro@linux-mips.org>
13722
13723 * Makefile.in (uninstall): Apply $(EXEEXT) too.
13724
13725 2008-08-18 Luis Machado <luisgpm@br.ibm.com>
13726
13727 * Makefile.in: Add required vsx dependencies.
13728
13729 * linux-ppc-low: Define PPC_FEATURE_HAS_VSX.
13730 Declare init_registers_powerpc_vsx32l.
13731 Declare init_registers_powerpc_vsx64l.
13732 Define PTRACE_GETVSXREGS and PTRACE_SETVSXREGS.
13733 (ppc_arch_setup): Check for VSX in hwcap.
13734 (ppc_fill_vsxregset): New function.
13735 (ppc_store_vsxregset): New function.
13736 Add new VSX entry in regset_info target_regsets.
13737
13738 * configure.srv: Add new VSX dependencies.
13739
13740 2008-08-12 Pedro Alves <pedro@codesourcery.com>
13741
13742 * remote-utils.c (noack_mode, transport_is_reliable): New globals.
13743 (remote_open): Set or clear transport_is_reliable.
13744 (putpkt_binary): Don't expect acks in noack mode.
13745 (getpkt): Don't send ack/nac in noack mode.
13746 * server.c (handle_general_set): Handle QStartNoAckMode.
13747 (handle_query): If connected by tcp pass QStartNoAckMode+ in
13748 qSupported.
13749 (main): Reset noack_mode on every connection.
13750 * server.h (noack_mode): Declare.
13751
13752 2008-08-07 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
13753
13754 * Makefile.in (GDBREPLAY_OBS): New variable.
13755 (gdbreplay$(EXEEXT)): Use it to avoid unportable $^.
13756
13757 2008-08-05 Ulrich Weigand <uweigand@de.ibm.com>
13758 Daniel Jacobowitz <dan@codesourcery.com>
13759
13760 * linux-low.c (linux_resume_one_process): Ignore ESRCH.
13761 (usr_store_inferior_registers): Likewise.
13762 (regsets_store_inferior_registers): Likewise.
13763
13764 2008-07-31 Rolf Jansen <rj@surtec.com>
13765 Pedro Alves <pedro@codesourcery.com>
13766
13767 * configure.ac: Check for memmem declaration.
13768 * server.c [HAVE_MALLOC_H]: Include malloc.h.
13769 (disable_packet_vCont, disable_packet_Tthread, disable_packet_qC)
13770 (disable_packet_qfThreadInfo): Unconditionally compile.
13771 * server.h [!HAVE_DECL_MEMMEM]: Declare memmem.
13772 * configure, config.in: Regenerate.
13773
13774 2008-07-28 Doug Kwan <dougkwan@google.com>
13775
13776 * linux-low.c (sys/dir.h, sys/user.h): Remove includes.
13777 (linux_write_memory): Remove declaration of errno.
13778
13779 2008-07-12 Ulrich Weigand <uweigand@de.ibm.com>
13780
13781 * linux-low.c (handle_extended_wait): Do not use "status"
13782 variable uninitialized.
13783
13784 2008-07-07 Pedro Alves <pedro@codesourcery.com>
13785
13786 * server.c (handle_v_attach): Inhibit reporting dll changes.
13787
13788 2008-06-27 Pedro Alves <pedro@codesourcery.com>
13789
13790 * remote-utils.c (prepare_resume_reply): If requested, don't
13791 output "thread:TID" in the T stop reply.
13792
13793 * server.c (disable_packet_vCont, disable_packet_Tthread)
13794 (disable_packet_qC, disable_packet_qfThreadInfo): New globals.
13795 (handle_query): If requested, disable support for qC, qfThreadInfo
13796 and qsThreadInfo.
13797 (handle_v_requests): If requested, disable support for vCont.
13798 (gdbserver_show_disableable): New.
13799 (main): Handle --disable-packet and --disable-packet=LIST.
13800
13801 * server.h (disable_packet_vCont, disable_packet_Tthread)
13802 (disable_packet_qC, disable_packet_qfThreadInfo): Declare.
13803
13804 2008-06-20 Carlos O'Donell <carlos@codesourcery.com>
13805
13806 * server.c (gdbserver_usage): Mention --version.
13807
13808 2008-06-06 Daniel Jacobowitz <dan@codesourcery.com>
13809
13810 * Makefile.in (gdbreplay.o): New rule.
13811
13812 2008-06-06 Joseph Myers <joseph@codesourcery.com>
13813
13814 * gdbreplay.c (gdbreplay_version): Say gdbreplay in version
13815 message, not gdbserver.
13816
13817 2008-06-05 Vladimir Prus <vladimir@codesourcery.com>
13818 Nathan Sidwell <nathan@codesourcery.com>
13819 Joseph Myers <joseph@codesourcery.com>
13820
13821 * acinclude.m4: Include ../../config/acx.m4.
13822 * configure.ac: Use ACX_PKGVERSION and ACX_BUGURL.
13823 * configure, config.in: Regenerate.
13824 * Makefile.in (gdbreplay$(EXEEXT)): Add version.o.
13825 * server.c (gdbserver_version): Print PKGVERSION.
13826 (gdbsrever_usage): Add stream parameter. Print REPORT_BUGS_TO.
13827 (main): Adjust gdbserver_usage calls.
13828 * gdbreplay.c (version, host_name): Add declarations.
13829 (gdbreplay_version, gdbreplay_usage): New.
13830 (main): Accept --version and --help options.
13831
13832 2008-06-04 Daniel Jacobowitz <dan@codesourcery.com>
13833
13834 * linux-arm-low.c (thumb_breakpoint, thumb_breakpoint_len): New.
13835 (arm_breakpoint_at): Handle Thumb.
13836 (the_low_target): Add comment.
13837
13838 2008-05-29 Ulrich Weigand <uweigand@de.ibm.com>
13839
13840 * linux-ppc-low.c (ppc_collect_ptrace_register): Clear buffer.
13841
13842 2008-05-09 Doug Evans <dje@google.com>
13843
13844 * server.h (decode_search_memory_packet): Declare.
13845 * remote-utils.c (decode_search_memory_packet): New fn.
13846 * server.c (handle_search_memory_1): New fn.
13847 (handle_search_memory): New fn.
13848 (handle_query): Process qSearch:memory packets.
13849
13850 2008-05-08 Ulrich Weigand <uweigand@de.ibm.com>
13851
13852 * regcache.c (registers_length): Remove.
13853 (set_register_cache): Verify that PBUFSIZ is large enough to hold a
13854 full register packet.
13855 * regcache.h (registers_length): Remove prototype.
13856 * server.h (PBUFSIZ): Define to 16384.
13857
13858 2008-05-03 Ulrich Weigand <uweigand@de.ibm.com>
13859
13860 * configure.srv (powerpc*-*-linux*): Set srv_regobj to
13861 powerpc-32l.o, powerpc-altivec32l.o, powerpc-e500l.o,
13862 powerpc-64l.o, and powerpc-altivec64l.o.
13863 Remove rs6000/powerpc-32.xml, rs6000/powerpc-64.xml, and
13864 rs6000/powerpc-e500.xml; add rs6000/powerpc-32l.xml,
13865 rs6000/powerpc-altivec32l.xml, rs6000/powerpc-e500l.xml,
13866 rs6000/powerpc-64l.xml, rs6000/powerpc-altivec64l.xml,
13867 rs6000/power-linux.xml, and rs6000/power64-linux.xml
13868 to srv_xmlfiles.
13869
13870 * Makefile.in (reg-ppc.o, reg-ppc.c): Remove, replace by ...
13871 (powerpc-32l.o, powerpc-32l.c): ... these new rules.
13872 (powerpc-32.o, powerpc-32.c): Remove, replace by ...
13873 (powerpc-altivec32l.o, powerpc-altivec32l.c): ... these new rules.
13874 (powerpc-e500.o, powerpc-e500.c): Remove, replace by ...
13875 (powerpc-e500l.o, powerpc-e500l.c): ... these new rules.
13876 (reg-ppc64.o, reg-ppc64.c): Remove, replace by ...
13877 (powerpc-64l.o, powerpc-64l.c): ... these new rules.
13878 (powerpc-64.o, powerpc-64.c): Remove, replace by ...
13879 (powerpc-altivec64l.o, powerpc-altivec64l.c): ... these new rules.
13880 (clean): Update.
13881
13882 * linux-ppc-low.c (init_registers_ppc): Remove, replace by ...
13883 (init_registers_powerpc_32l): ... this new prototype.
13884 (init_registers_powerpc_32): Remove, replace by ...
13885 (init_registers_powerpc_altivec32l): ... this new prototype.
13886 (init_registers_powerpc_e500): Remove, replace by ...
13887 (init_registers_powerpc_e500l): ... this new prototype.
13888 (init_registers_ppc64): Remove, replace by ...
13889 (init_registers_powerpc_64l): ... this new prototype.
13890 (init_registers_powerpc_64): Remove, replace by ...
13891 (init_registers_powerpc_altivec64l): ... this new prototype.
13892 (ppc_num_regs): Set to 73.
13893 (PT_ORIG_R3, PT_TRAP): Define if necessary.
13894 (ppc_regmap, ppc_regmap_e500): Add values for orig_r3 and trap.
13895 (ppc_cannot_store_register): Handle orig_r3 and trap.
13896 (ppc_arch_setup): Update init_registers_... calls.
13897 (ppc_fill_gregset): Handle orig_r3 and trap.
13898
13899 * inferiors.c (clear_inferiors): Reset current_inferior.
13900
13901 2008-04-23 Paolo Bonzini <bonzini@gnu.org>
13902
13903 * acinclude.m4: Add override.m4.
13904 * configure: Regenerate.
13905
13906 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
13907
13908 * linux-ppc-low.c (ppc_arch_setup): Reset ppc_hwcap after the
13909 initial call to init_register_ppc64.
13910
13911 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
13912
13913 * configure.srv (powerpc64-*-linux*, powerpc-*-linux*): Merge into
13914 single powerpc*-*-linux* case.
13915 (s390-*-linux*, s390x-*-linux*): Merge into single s390*-*-linux* case.
13916
13917 2008-04-17 Ulrich Weigand <uweigand@de.ibm.com>
13918
13919 * configure.srv [powerpc64-*-linux*]: Remove powerpc-e500.o from
13920 srv_regobj. Remove rs6000/powerpc-e500.xml and rs6000/power-spe.xml
13921 from reg_xmlfiles.
13922 * linux-ppc-low.c: Include <elf.h>.
13923 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Define.
13924 (ppc_hwcap): New global variable.
13925 (ppc_regmap): Remove __SPE__ #ifdef sections.
13926 (ppc_regmap_e500): New global variable.
13927 (ppc_cannot_store_register): Update __SPE__ special case.
13928 (ppc_get_hwcap): New function.
13929 (ppc_arch_setup): Use it to determine whether inferior supports
13930 AltiVec or SPE registers. Set the_low_target.regmap if appropriate.
13931 (ppc_fill_vrregset, ppc_store_vrregset): Define unconditionally.
13932 Do not access registers if target does not support AltiVec.
13933 (ppc_fill_evrregset, ppc_store_evrregset): Define unconditionally.
13934 Do not access registers if target does not support SPE.
13935 (target_regsets): Unconditionally include AltiVec and SPE regsets.
13936
13937 2008-04-17 Daniel Jacobowitz <dan@codesourcery.com>
13938
13939 * linux-low.c (disabled_regsets, num_regsets): New.
13940 (use_regsets_p): Delete.
13941 (linux_wait_for_process): Clear disabled_regsets.
13942 (regsets_fetch_inferior_registers): Check and set it.
13943 (regsets_store_inferior_registers): Likewise.
13944 (linux_fetch_registers, linux_store_registers): Do not use
13945 use_regsets_p.
13946 (initialize_low): Allocate disabled_regsets.
13947
13948 2008-04-14 Daniel Jacobowitz <dan@codesourcery.com>
13949
13950 * Makefile.in (LIBOBJS): New.
13951 (OBS): Use LIBOBJS.
13952 (memmem.o): New rule.
13953 * configure.ac: Use AC_CONFIG_LIBOBJ_DIR and check for memmem.
13954 * configure: Regenerated.
13955
13956 2008-04-04 Ulrich Weigand <uweigand@de.ibm.com>
13957
13958 * server.c (handle_query): Never return "unsupported" for
13959 qXfer:features:read queries.
13960
13961 2008-03-27 Ulrich Weigand <uweigand@de.ibm.com>
13962
13963 * server.c (get_features_xml): Fix inverted condition.
13964 (handle_query): Always support qXfer:feature:read.
13965
13966 2008-03-10 Daniel Jacobowitz <dan@codesourcery.com>
13967
13968 * server.c (wrapper_argv): New.
13969 (start_inferior): Handle wrapper_argv. If set, expect an extra
13970 trap.
13971 (gdbserver_usage): Document --wrapper.
13972 (main): Parse --wrapper.
13973
13974 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
13975
13976 * configure.srv [powerpc64-*-linux*]: Add all files mentioned for
13977 powerpc-*-linux* to srv_regobj and reg_xmlfiles.
13978 * linux-ppc-low.c (ppc_get_pc): Support bi-arch operation.
13979 (ppc_set_pc): Likewise.
13980 (ppc_arch_setup): New function.
13981 (ppc_fill_gregset): Call ppc_collect_ptrace_register instead
13982 of collect_register.
13983 (the_low_target): Use ppc_arch_setup as arch_setup initializer.
13984
13985 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
13986
13987 * configure.srv [powerpc64-*-linux*]: Use linux-ppc-low.o
13988 instead of linux-ppc64-low.o.
13989 * linux-ppc64-low.c: Remove file.
13990 * Makefile.in (SFILES): Remove linux-ppc64-low.c.
13991 (linux-ppc64-low.o): Remove rule.
13992
13993 * linux-ppc-low.c (init_registers_ppc64): Add prototype.
13994 (init_registers_powerpc_64): Likewise.
13995 (ppc_regmap): Conditionally define depending on __powerpc64__.
13996 (ppc_cannot_store_register): Do not special-case "fpscr" when
13997 compiled on __powerpc64__.
13998 (ppc_collect_ptrace_register): New function.
13999 (ppc_supply_ptrace_register): New function.
14000 (ppc_breakpoint): Change type to "unsigned int".
14001 (ppc_breakpoint_at): Change type of "insn" to "unsigned int".
14002 (the_low_target): Conditionally provide initializers for the
14003 arch_setup member depending on __powerpc64__. Install
14004 collect_ptrace_register and supply_ptrace_register members.
14005
14006 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
14007
14008 * regcache.h (gdbserver_xmltarget): Add extern declaration.
14009 * server.c (gdbserver_xmltarget): Define.
14010 (get_features_xml): Use it to replace "target.xml" and arch_string.
14011
14012 * configure.srv: Remove srv_xmltarget. Add XML files that were
14013 mentioned there to srv_xmlfiles instead. Remove conditional tests
14014 on gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe; set
14015 srv_xmlfiles and srv_regobj to include all possible choices.
14016 * configure.ac (srv_xmltarget): Remove.
14017 (srv_xmlfiles): Do not add "target.xml".
14018 (gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe): Remove
14019 checks for supplementary target information.
14020 * configure: Regenerate.
14021 * Makefile.in (XML_TARGET): Remove.
14022 (target.xml): Remove rule.
14023 (clean): Do not clean up target.xml.
14024 (.PRECIOUS): Do not mention target.xml.
14025
14026 * target.h (struct target_ops): Remove arch_string member.
14027 * linux-low.c (linux_arch_string): Remove.
14028 (linux_target_ops): Remove arch_string initializer.
14029 * linux-low.h (struct linux_target_ops): Remove arch_string member.
14030 * linux-i386-low.c (the_low_target): Remove arch_string initializer.
14031 * linux-x86-64-low.c (the_low_target): Remove arch_string initializer.
14032 * spu-low.c (spu_arch_string): Remove.
14033 (spu_target_ops): Remove arch_string initializer.
14034 * win32-low.c (win32_arch_string): Remove.
14035 (win32_target_ops): Remove arch_string initializer.
14036 * win32-low.h (struct win32_target_ops): Remove arch_string member.
14037 * win32-arm-low.c (the_low_target): Remove arch_string initializer.
14038 * win32-i368-low.c (the_low_target): Remove arch_string initializer.
14039
14040 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
14041
14042 * linux-low.h (struct linux_target_ops): Replace left_pad_xfer field
14043 by collect_ptrace_register and supply_ptrace_register hooks.
14044 * linux-low.c (fetch_register): Use supply_ptrace_register callback
14045 instead of checking for the_low_target.left_pad_xfer.
14046 (usr_store_inferior_registers): Use collect_ptrace_register callback
14047 instead of checking for the_low_target.left_pad_xfer.
14048
14049 * linux-s390-low.c (s390_collect_ptrace_register): New function.
14050 (s390_supply_ptrace_register): Likewise.
14051 (s390_fill_gregset): Call s390_collect_ptrace_register.
14052 (the_low_target): Update.
14053
14054 * linux-ppc64-low.c (ppc_collect_ptrace_register): New function.
14055 (ppc_supply_ptrace_register): Likewise.
14056 (the_low_target): Update.
14057
14058 * linux-i386-low.c (the_low_target): Update.
14059 * linux-x86-64-low.c (the_low_target): Update.
14060
14061 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
14062
14063 * configure.srv [s390x-*-linux*]: Set srv_regobj to include both
14064 reg-s390.o and reg-s390x.o.
14065
14066 * linux-low.c (new_inferior): New global variable.
14067 (linux_create_inferior, linux_attach): Set it.
14068 (linux_wait_for_process): Call the_low_target.arch_setup after the
14069 target has stopped for the first time.
14070 (initialize_low): Do not call the_low_target.arch_setup.
14071
14072 * linux-s390-low.c (s390_get_pc): Support bi-arch operation.
14073 (s390_set_pc): Likewise.
14074 (s390_arch_setup): New function.
14075 (the_low_target): Use s390_arch_setup as arch_setup routine.
14076
14077 * regcache.c (realloc_register_cache): New function.
14078 (set_register_cache): Call it for each existing regcache.
14079
14080 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
14081
14082 * server.h (init_registers): Remove prototype.
14083
14084 * linux-low.h (struct linux_target_ops): Add arch_setup field.
14085 * linux-low.c (initialize_low): Call the_low_target.arch_setup ()
14086 instead of init_registers ().
14087 * linux-arm-low.c (init_registers_arm): Add prototype.
14088 (init_registers_arm_with_iwmmxt): Likewise.
14089 (the_low_target): Add initializer for arch_setup field.
14090 * linux-cris-low.c (init_registers_cris): Add prototype.
14091 (the_low_target): Add initializer for arch_setup field.
14092 * linux-crisv32-low.c (init_registers_crisv32): Add prototype.
14093 (the_low_target): Add initializer for arch_setup field.
14094 * linux-i386-low.c (init_registers_i386_linux): Add prototype.
14095 (the_low_target): Add initializer for arch_setup field.
14096 * linux-ia64-low.c (init_registers_ia64): Add prototype.
14097 (the_low_target): Add initializer for arch_setup field.
14098 * linux-m32r-low.c (init_registers_m32r): Add prototype.
14099 (the_low_target): Add initializer for arch_setup field.
14100 * linux-m68k-low.c (init_registers_m68k): Add prototype.
14101 (the_low_target): Add initializer for arch_setup field.
14102 * linux-mips-low.c (init_registers_mips_linux): Add prototype.
14103 (init_registers_mips64_linux): Likewise.
14104 (the_low_target): Add initializer for arch_setup field.
14105 * linux-ppc-low.c (init_registers_ppc): Add prototype.
14106 (init_registers_powerpc_32, init_registers_powerpc_e500): Likewise.
14107 (the_low_target): Add initializer for arch_setup field.
14108 * linux-ppc64-low.c (init_registers_ppc64): Add prototype.
14109 (init_registers_powerpc_64): Likewise.
14110 (the_low_target): Add initializer for arch_setup field.
14111 * linux-s390-low.c (init_registers_s390): Add prototype.
14112 (init_registers_s390x): Likewise.
14113 (the_low_target): Add initializer for arch_setup field.
14114 * linux-sh-low.c (init_registers_sh): Add prototype.
14115 (the_low_target): Add initializer for arch_setup field.
14116 * linux-x86-64-low.c (init_registers_x86_64_linux): Add prototype.
14117 (the_low_target): Add initializer for arch_setup field.
14118 * linux-xtensa-low.c (init_registers_xtensa): Add prototype.
14119 (the_low_target): Add initializer for arch_setup field.
14120
14121 * win32-low.h (struct win32_target_ops): Add arch_setup field.
14122 * win32-low.c (initialize_low): Call the_low_target.arch_setup ()
14123 instead of init_registers ().
14124 * win32-arm-low.c (init_registers_arm): Add prototype.
14125 (the_low_target): Add initializer for arch_setup field.
14126 * win32-i386-low.c (init_registers_i386): Add prototype.
14127 (the_low_target): Add initializer for arch_setup field.
14128
14129 * spu-low.c (init_registers_spu): Add prototype.
14130 (initialize_low): Call initialie_registers_spu () instead of
14131 initialize_registers ().
14132
14133 2008-02-19 Pedro Alves <pedro@codesourcery.com>
14134
14135 * server.c (handle_v_requests): When handling the vRun and vAttach
14136 packets, if already debugging a process, don't kill it. Return an
14137 error instead.
14138
14139 2008-02-17 Daniel Jacobowitz <dan@codesourcery.com>
14140
14141 * server.c (handle_query): Correct length check.
14142
14143 2008-02-14 Pedro Alves <pedro_alves@portugalmail.pt>
14144
14145 * win32-low.c (do_initial_child_stuff): Add process handle
14146 parameter. Set current_process_handle and current_process_id from the
14147 parameters. Clear globals.
14148 (win32_create_inferior): Don't set current_process_handle and
14149 current_process_id here. Instead pass them on the call to
14150 do_initial_child_stuff.
14151 (win32_attach): Likewise.
14152 (win32_clear_inferiors): New.
14153 (win32_kill): Don't close the current process handle or the
14154 current thread handle here. Instead call win32_clear_inferiors.
14155 (win32_detach): Don't open a new handle to the process. Call
14156 win32_clear_inferiors.
14157 (win32_join): Don't rely on current_process_handle; open a new
14158 handle using the process id.
14159 (win32_wait): Call win32_clear_inferiors when the inferior process
14160 has exited.
14161
14162 2008-02-14 Daniel Jacobowitz <dan@codesourcery.com>
14163
14164 * server.c (monitor_show_help): Add "exit".
14165
14166 2008-02-11 Maxim Grigoriev <maxim2405@gmail.com>
14167
14168 * Makefile.in (SFILES): Add linux-xtensa-low.c.
14169 (clean): Add reg-xtensa.c.
14170 (linux-xtensa-low.o, reg-xtensa.o, reg-xtensa.c): New dependencies.
14171 * configure.srv (xtensa*-*-linux*) New target.
14172 * linux-xtensa-low.c: New.
14173 * xtensa-xtregs.c: New.
14174
14175 2008-02-01 Pedro Alves <pedro_alves@portugalmail.pt>
14176
14177 * hostio.c: Don't include errno.h.
14178 (errno_to_fileio_errno): Move to hostio-errno.
14179 * hostio.c: (hostio_error): Remove the error parameter. Defer the
14180 error number outputting to the target->hostio_last_error callback.
14181 (hostio_packet_error): Use FILEIO_EINVAL directly.
14182 (handle_open, handle_pread, hostio_error, handle_unlink): Update
14183 calls to hostio_error.
14184 * hostio-errno.c: New.
14185 * server.h (hostio_last_error_from_errno): Declare.
14186 * target.h (target_ops): Add hostio_last_error member.
14187 * linux-low.c (linux_target_op): Register hostio_last_error_from_errno
14188 as hostio_last_error handler.
14189 * spu-low.c (spu_target_ops): Likewise.
14190 * win32-low.c [_WIN32_WCE] (win32_error_to_fileio_error)
14191 (wince_hostio_last_error): New functions.
14192 (win32_target_ops) [_WIN32_WCE]: Register wince_hostio_last_error
14193 as hostio_last_error handler.
14194 (win32_target_ops) [!_WIN32_WCE]: Register
14195 hostio_last_error_from_errno as hostio_last_error handler.
14196 * Makefile.in (SFILES): Add hostio.c and hostio-errno.c.
14197 (hostio-errno.o): New rule.
14198 * configure.ac (GDBSERVER_DEPFILES): Add $srv_hostio_err_objs.
14199 * configure.srv (srv_hostio_err_objs): New variable. Default to
14200 hostio-errno.o.
14201 (arm*-*-mingw32ce*): Set srv_hostio_err_objs to "".
14202 * configure: Regenerate.
14203
14204 2008-01-29 Daniel Jacobowitz <dan@codesourcery.com>
14205
14206 * linux-low.c (linux_attach_lwp): Do not _exit after errors.
14207 (linux_kill, linux_detach): Clean up the process list.
14208 * remote-utils.c (remote_open): Improve port number parsing.
14209 (putpkt_binary, input_interrupt): Only send interrupts if the target
14210 is running.
14211 * server.c (extended_protocol): Make static.
14212 (attached): Define earlier.
14213 (exit_requested, response_needed, program_argv): New variables.
14214 (target_running): New.
14215 (start_inferior): Clear attached here.
14216 (attach_inferior): Set attached here.
14217 (require_running): Define.
14218 (handle_query): Use require_running and target_running. Implement
14219 "monitor exit".
14220 (handle_v_attach, handle_v_run): New.
14221 (handle_v_requests): Use require_running. Handle vAttach and vRun.
14222 (gdbserver_usage): Update.
14223 (main): Redo argument parsing. Handle --debug and --multi. Handle
14224 --attach along with other options or after the port. Save
14225 program_argv. Support no initial program. Resynchronize
14226 communication with GDB after an error. Handle "monitor exit".
14227 Use require_running and target_running. Always allow the extended
14228 protocol. Do not error out for Hc0 or Hc-1. Do not automatically
14229 restart in extended mode.
14230 * README: Refer to the GDB manual. Update --attach usage.
14231
14232 2007-12-20 Andreas Schwab <schwab@suse.de>
14233
14234 * linux-low.c (STACK_SIZE): Define.
14235 (linux_tracefork_child): Use it. Use __clone2 on ia64.
14236 (linux_test_for_tracefork): Likewise.
14237
14238 2007-12-18 Daniel Jacobowitz <dan@codesourcery.com>
14239
14240 * linux-low.c (linux_wait_for_event): Update messages. Do not
14241 reinsert auto-delete breakpoints.
14242 * mem-break.c (struct breakpoint): Change return type of handler to
14243 int.
14244 (set_breakpoint_at): Update handler type.
14245 (reinsert_breakpoint_handler): Return 1 instead of calling
14246 delete_breakpoint.
14247 (reinsert_breakpoint_by_bp): Check for the original breakpoint before
14248 setting a new one.
14249 (check_breakpoints): Delete auto-delete breakpoints and return 2.
14250 * mem-break.h (set_breakpoint_at): Update handler type.
14251 * thread-db.c (thread_db_create_event, thread_db_create_event): Update.
14252 * win32-low.c (auto_delete_breakpoint): New.
14253 (get_child_debug_event): Use it.
14254
14255 2007-12-16 Daniel Jacobowitz <dan@codesourcery.com>
14256
14257 * configure.ac: Check for pread and pwrite.
14258 * hostio.c (handle_pread): Fall back to lseek and read.
14259 (handle_pwrite): Fall back to lseek and write.
14260 * config.in, configure: Regenerated.
14261
14262 2007-12-07 Daniel Jacobowitz <dan@codesourcery.com>
14263
14264 * server.c (myresume): Add own_buf argument.
14265 (main): Update calls.
14266
14267 2007-12-06 Daniel Jacobowitz <dan@codesourcery.com>
14268
14269 * linux-low.c (linux_wait, linux_resume): Do not handle async I/O.
14270 * remote-utils.c (remote_open): Do not call disable_async_io.
14271 (block_async_io): Delete.
14272 (unblock_async_io): Make static.
14273 (initialize_async_io): New.
14274 * server.c (handle_v_cont): Handle async I/O here.
14275 (myresume): Likewise. Move other common resume tasks here...
14276 (main): ... from here. Call initialize_async_io. Disable async
14277 I/O before the main loop.
14278 * server.h (initialize_async_io): Declare.
14279 (block_async_io, unblock_async_io): Delete prototypes.
14280 * spu-low.c (spu_resume, spu_wait): Do not handle async I/O here.
14281
14282 2007-12-06 Mick Davis <mickd@goanna.iinet.net.au>
14283
14284 * remote-utils.c (readchar): Allow binary data in received messages.
14285
14286 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
14287
14288 * win32-low.c (attaching): New global.
14289 (win32_create_inferior): Clear the `attaching' global.
14290 (win32_attach): Set the `attaching' global.
14291 (get_child_debug_event) [_WIN32_WCE]: Stop the inferior when
14292 attaching. Only set a breakpoint at the entry point if not
14293 attaching.
14294
14295 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
14296
14297 * server.c (main): Don't report dll events on the initial
14298 connection on attaches.
14299
14300 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
14301
14302 * server.c (main): Relax numerical bases supported for the pid of
14303 the --attach command line argument.
14304
14305 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
14306
14307 * win32-low.c (win32_attach): Call OpenProcess before
14308 DebugActiveProcess, not after. Add last error output to error
14309 call.
14310
14311 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
14312
14313 * win32-low.c (win32_get_thread_context)
14314 (win32_set_thread_context): New functions.
14315 (thread_rec): Use win32_get_thread_context.
14316 (continue_one_thread, win32_resume): Use win32_set_thread_context.
14317 * win32-low.h (win32_thread_info) [_WIN32_WCE]: Add `base_context'
14318 field.
14319
14320 2007-12-03 Leo Zayas
14321 Pedro Alves <pedro_alves@portugalmail.pt>
14322
14323 * win32-low.c (soft_interrupt_requested, faked_breakpoint): New
14324 global variables.
14325 (child_add_thread): Minor cleanup.
14326 (child_continue): Resume artificially suspended threads before
14327 calling ContinueDebugEvent.
14328 (suspend_one_thread): New.
14329 (fake_breakpoint_event): New.
14330 (get_child_debug_event): Change return type to int. Check here if
14331 gdb sent an interrupt request. If a soft interrupt was requested,
14332 fake a breakpoint event. Return 0 if there is no event to handle,
14333 and 1 otherwise.
14334 (win32_wait): Don't check here if gdb sent an interrupt request.
14335 Ensure there is a valid event to handle.
14336 (win32_request_interrupt): Add soft interruption method as last
14337 resort.
14338
14339 2007-12-03 Leo Zayas
14340 Pedro Alves <pedro_alves@portugalmail.pt>
14341
14342 * win32-low.h (win32_thread_info): Add descriptions to the
14343 structure members. Replace `suspend_count' counter by a
14344 `suspended' flag.
14345 * win32-low.c (thread_rec): Update condition of when to get the
14346 context from the inferior. Rely on ContextFlags being set if it
14347 has already been retrieved. Only suspend the inferior thread if
14348 we haven't already. Warn if that fails.
14349 (continue_one_thread): s/suspend_count/suspended/. Only call
14350 ResumeThread once. Warn if that fails.
14351
14352 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
14353
14354 * win32-low.c (win32_wait): Don't read from the inferior when it
14355 has already exited.
14356
14357 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
14358
14359 * Makefile.in (win32_low_h): New variable.
14360 (win32-low.o): Add dependency on $(win32_low_h).
14361 (win32-arm-low.o, win32-i386-low.o): New rules.
14362
14363 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
14364
14365 * hostio.c: Correct copyright year.
14366
14367 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
14368
14369 * Makefile.in (OBS): Add hostio.o.
14370 (hostio.o): New rule.
14371 * server.h (handle_vFile): Declare.
14372 * hostio.c: New file.
14373 * server.c (handle_v_requests): Take packet_len and new_packet_len
14374 for binary packets. Call handle_vFile.
14375 (main): Update call to handle_v_requests.
14376
14377 2007-11-05 Daniel Jacobowitz <dan@codesourcery.com>
14378
14379 * linux-low.c: Include <sched.h>.
14380
14381 2007-11-01 Daniel Jacobowitz <dan@codesourcery.com>
14382
14383 * linux-low.c (linux_tracefork_grandchild): New.
14384 (linux_tracefork_child): Use clone.
14385 (linux_test_for_tracefork): Use clone; allocate and free a stack.
14386
14387 2007-10-31 Joel Brobecker <brobecker@adacore.com>
14388
14389 * Makefile.in: Use $(SHELL) instead of "sh" to call regdat.sh.
14390
14391 2007-10-24 Daniel Jacobowitz <dan@codesourcery.com>
14392
14393 * linux-low.c (handle_extended_wait): Handle unexpected signals.
14394
14395 2007-10-23 Daniel Jacobowitz <dan@codesourcery.com>
14396
14397 * inferiors.c (change_inferior_id): Delete.
14398 (add_pid_to_list, pull_pid_from_list): New.
14399 * linux-low.c (PTRACE_SETOPTIONS, PTRACE_GETEVENTMSG)
14400 (PTRACE_O_TRACESYSGOOD, PTRACE_O_TRACEFORK, PTRACE_O_TRACEVFORK)
14401 (PTRACE_O_TRACECLONE, PTRACE_O_TRACEEXEC, PTRACE_O_TRACEVFORKDONE)
14402 (PTRACE_O_TRACEEXIT, PTRACE_EVENT_FORK, PTRACE_EVENT_VFORK)
14403 (PTRACE_EVENT_CLONE, PTRACE_EVENT_EXEC, PTRACE_EVENT_VFORK_DONE)
14404 (PTRACE_EVENT_EXIT, __WALL): Provide default definitions.
14405 (stopped_pids, thread_db_active, must_set_ptrace_flags): New variables.
14406 (using_threads): Always set to 1.
14407 (handle_extended_wait): New.
14408 (add_process): Do not set TID.
14409 (linux_create_inferior): Set must_set_ptrace_flags.
14410 (linux_attach_lwp): Remove TID argument. Do not check using_threads.
14411 Use PTRACE_SETOPTIONS. Call new_thread_notify. Update all callers.
14412 (linux_thread_alive): Rename TID argument to LWPID.
14413 (linux_wait_for_process): Handle unknown processes. Do not use TID.
14414 (linux_wait_for_event): Do not use TID or check using_threads. Update
14415 call to dead_thread_notify. Call handle_extended_wait.
14416 (linux_create_inferior): Use PTRACE_SETOPTIONS.
14417 (send_sigstop): Delete sigstop_sent.
14418 (wait_for_sigstop): Avoid TID.
14419 (linux_supports_tracefork_flag, linux_tracefork_child, my_waitpid)
14420 (linux_test_for_tracefork): New.
14421 (linux_lookup_signals): Use thread_db_active and
14422 linux_supports_tracefork_flag.
14423 (initialize_low): Use thread_db_active and linux_test_for_tracefork.
14424 * linux-low.h (get_process_thread): Avoid TID.
14425 (struct process_ifo): Move thread_known and tid to the end. Remove
14426 sigstop_sent.
14427 (linux_attach_lwp, thread_db_init): Update prototypes.
14428 * server.h (change_inferior_id): Delete prototype.
14429 (add_pid_to_list, pull_pid_from_list): New prototypes.
14430 * thread-db.c (thread_db_use_events): New.
14431 (find_first_thread): Rename to...
14432 (find_one_thread): ...this. Update callers and messages. Do not
14433 call fatal. Check thread_db_use_events. Do not call
14434 change_inferior_id or new_thread_notify.
14435 (maybe_attach_thread): Update. Do not call new_thread_notify.
14436 (thread_db_init): Set thread_db_use_events. Check use_events.
14437 * utils.c (fatal, warning): Correct message prefix.
14438
14439 2007-10-15 Daniel Jacobowitz <dan@codesourcery.com>
14440
14441 * Makefile.in (clean): Remove new files.
14442 (powerpc-32.o, powerpc-32.c, powerpc-e500.o, powerpc-e500.c)
14443 (powerpc-64.o, powerpc-64.c): New rules.
14444 * configure.srv: Use alternate register sets for powerpc64-*-linux*
14445 with AltiVec, powerpc-*-linux* with AltiVec, and powerpc-*-linux*
14446 with SPE.
14447 * linux-ppc-low.c (ppc_regmap): Do not fetch the FP registers for
14448 SPE targets.
14449 (ppc_cannot_store_register): Do not check for FPSCR for SPE targets.
14450 (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS, ppc_fill_vrregset)
14451 (ppc_store_vrregset, PTRACE_GETEVRREGS, PTRACE_SETEVRREGS)
14452 (struct gdb_evrregset_t, ppc_fill_evrregset, ppc_store_evrregset): New.
14453 (target_regsets): Add AltiVec and SPE register sets.
14454 * configure.ac: Check for AltiVec and SPE.
14455 * linux-ppc64-low.c (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS)
14456 (ppc_fill_vrregset, ppc_store_vrregset): New.
14457 (target_regsets): Add AltiVec register set.
14458 * configure: Regenerated.
14459
14460 2007-09-19 Daniel Jacobowitz <dan@codesourcery.com>
14461
14462 * linux-low.c (O_LARGEFILE): Define.
14463 (linux_read_memory): Use /proc/PID/mem.
14464 * configure.ac: Use AC_GNU_SOURCE. Check for pread64.
14465 * configure, config.in: Regenerated.
14466
14467 2007-09-04 Daniel Jacobowitz <dan@codesourcery.com>
14468
14469 * linux-low.c (linux_wait_for_event): Do not pass signals while
14470 single-stepping.
14471
14472 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
14473
14474 * win32-low.c (create_process): New.
14475 (win32_create_inferior): Use create_process instead of
14476 CreateProcess. If create_process failed retry appending an ".exe"
14477 suffix. Store the GetLastError result immediatelly after
14478 create_process calls and use it on the call to error.
14479
14480 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
14481
14482 * win32-low.c (handle_load_dll): Don't use toolhelp when waiting.
14483
14484 2007-08-23 Joel Brobecker <brobecker@adacore.com>
14485
14486 * configure.ac: Switch license to GPLv3.
14487
14488 2007-08-01 Michael Snyder <msnyder@access-company.com>
14489
14490 * remote-utils.c (putpkt_binary): Memory leak, free buf2.
14491
14492 2007-07-31 Pedro Alves <pedro_alves@portugalmail.pt>
14493
14494 * win32-low.c (winapi_CloseToolhelp32Snapshot) [_WIN32_WCE]: New
14495 typedef.
14496 (win32_CloseToolhelp32Snapshot) [_WIN32_WCE]: New global var.
14497 (load_toolhelp) [_WIN32_WCE]: Load TOOLHELP.DLL. Get
14498 CloseToolhelp32Snapshot.
14499 (toolhelp_get_dll_name) [_WIN32_WCE]: Close the snapshot with
14500 CloseToolhelp32Snapshot.
14501
14502 2007-07-27 Michael Snyder <michael.snyder@access-company.com>
14503
14504 * server.c (main): Check for inferior exit before main loop.
14505
14506 2007-07-18 Pedro Alves <pedro_alves@portugalmail.pt>
14507
14508 * remote-utils.c (remote_open): Set SO_KEEPALIVE on remote_desc
14509 instead of on tmp_desc.
14510
14511 2007-07-17 Pedro Alves <pedro_alves@portugalmail.pt>
14512 Daniel Jacobowitz <dan@codesourcery.com>
14513
14514 * inferiors.c (all_dlls, dlls_changed, get_dll): New.
14515 (add_thread): Minor cleanups.
14516 (clear_inferiors): Move lower in the file. Clear the DLL
14517 list.
14518 (free_one_dll, match_dll, loaded_dll, unloaded_dll, clear_list): New.
14519 * remote-utils.c (prepare_resume_reply): Check dlls_changed.
14520 (xml_escape_text): New.
14521 * server.c (handle_query): Handle qXfer:libraries:read. Report it
14522 for qSupported.
14523 (handle_v_cont): Report errors.
14524 (gdbserver_version): Update.
14525 (main): Correct size of own_buf. Do not report initial DLL events.
14526 * server.h (struct dll_info, all_dlls, dlls_changed, loaded_dll)
14527 (unloaded_dll, xml_escape_text): New.
14528 * win32-low.c (enum target_waitkind): Update comments.
14529 (win32_add_one_solib, get_image_name, winapi_EnumProcessModules)
14530 (winapi_GetModuleInformation, winapi_GetModuleFileNameExA)
14531 (win32_EnumProcessModules, win32_GetModuleInformation)
14532 (win32_GetModuleFileNameExA, load_psapi, psapi_get_dll_name)
14533 (winapi_CreateToolhelp32Snapshot, winapi_Module32First)
14534 (winapi_Module32Next, win32_CreateToolhelp32Snapshot)
14535 (win32_Module32First, win32_Module32Next, load_toolhelp)
14536 (toolhelp_get_dll_name, handle_load_dll, handle_unload_dll): New.
14537 (get_child_debug_event): Handle DLL events.
14538 (win32_wait): Likewise.
14539
14540 2007-07-12 Daniel Jacobowitz <dan@codesourcery.com>
14541
14542 * configure.srv: Set srv_linux_regsets for sh*-*-linux*.
14543 * linux-sh-low.c (sh_fill_gregset, target_regsets): New.
14544
14545 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
14546
14547 * win32-low.c (handle_output_debug_string): Ignore event if not
14548 waiting.
14549
14550 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
14551
14552 * win32-arm-low.c (arm_wince_breakpoint): Fix typo.
14553
14554 2007-07-03 Daniel Jacobowitz <dan@codesourcery.com>
14555
14556 * remote-utils.c (look_up_one_symbol): Handle 'm' packets.
14557
14558 2007-07-02 Daniel Jacobowitz <dan@codesourcery.com>
14559
14560 * inferiors.c (change_inferior_id): Add comment.
14561 * linux-low.c (check_removed_breakpoint): Add an early
14562 prototype. Improve debug output.
14563 (linux_attach): Doc update.
14564 (linux_detach_one_process, linux_detach): Clean up before releasing
14565 each process.
14566 (send_sigstop, wait_for_sigstop): Improve comments and debug output.
14567 * linux-low.h (struct process_info): Doc improvement.
14568 * mem-break.c (delete_all_breakpoints): New.
14569 * mem-break.h (delete_all_breakpoints): New prototype.
14570 * thread-db.c (find_first_thread): New.
14571 (thread_db_create_event): Call it instead of
14572 thread_db_find_new_threads. Clean up unused variables.
14573 (maybe_attach_thread): Remove first thread handling.
14574 (thread_db_find_new_threads): Use find_first_thread.
14575 (thread_db_get_tls_address): Likewise.
14576
14577 2007-06-27 Daniel Jacobowitz <dan@codesourcery.com>
14578
14579 * thread-db.c (thread_db_find_new_threads): Add prototype.
14580 (thread_db_create_event): Check for the main thread before adding
14581 a new thread.
14582 (maybe_attach_thread): Only enable event reporting if TID == 0.
14583 (thread_db_get_tls_address): Check for new threads.
14584
14585 2007-06-20 Daniel Jacobowitz <dan@codesourcery.com>
14586
14587 * linux-low.c (linux_create_inferior): Try execv before execvp.
14588 * spu-low.c (spu_create_inferior): Likewise.
14589
14590 2007-06-13 Mike Frysinger <vapier@gentoo.org>
14591
14592 * linux-low.c (linux_create_inferior): Change execv to execvp.
14593 * spu-low.c (spu_create_inferior): Likewies.
14594
14595 2007-06-13 Daniel Jacobowitz <dan@codesourcery.com>
14596
14597 * Makefile.in (clean): Clean new files instead of deleted ones.
14598 (reg-mips.o, reg-mips.c, reg-mips64.o, reg-mips64.c): Delete.
14599 (mips-linux.o, mips-linux.c, mips64-linux.o, mips64-linux.c): New
14600 rules.
14601 * configure.srv: Specify XML files and new regformats for MIPS and
14602 MIPS64 GNU/Linux.
14603 * linux-mips-low.c (mips_num_regs): Set to only used registers.
14604 (mips_regmap): Do not fetch $0. Remove unused registers. Add
14605 an entry for the restart register.
14606 (mips_cannot_fetch_register, mips_cannot_store_register)
14607 (mips_reinsert_addr, mips_fill_fpregset, mips_store_fpregset): Update
14608 register names to match the XML descriptions.
14609 (mips_fill_gregset, mips_store_gregset): Likewise. Handle the
14610 restart register instead of $0.
14611
14612 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
14613 Markus Deuling <deuling@de.ibm.com>
14614
14615 * remote-utils.c (decode_xfer_write): New function.
14616 * server.h (decode_xfer_write): Add prototype.
14617 * server.c (handle_query): Add PACKET_LEN argument. Support
14618 qXfer:spu:read and qXfer:spu:write packets.
14619 (main): Pass packet_len to handle_query.
14620 * spu-low.c (spu_target_ops): Add spu_proc_xfer_spu.
14621 * target.h (target_ops): Add qxfer_spu.
14622
14623 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
14624
14625 * spu-low.c (spu_proc_xfer_spu): Do not return failure when
14626 accessing non-seekable spufs files.
14627
14628 2007-05-16 Markus Deuling <deuling@de.ibm.com>
14629
14630 * server.c (handle_query): Add reply for qC packet.
14631
14632 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
14633 Leo Zayas <lerele@champenstudios@com>
14634
14635 * server.h (check_remote_input_interrupt_request): New function.
14636 * remote_utils.c (INVALID_DESCRIPTOR): New define.
14637 (remote_desc): Initialize with INVALID_DESCRIPTOR.
14638 (input_interrupt): Expose on USE_WIN32API too. Fix whitespace.
14639 (check_remote_input_interrupt_request): New function.
14640 * server.h (check_remote_input_interrupt_request): Declare.
14641 * win32-low.c (winapi_DebugBreakProcess,
14642 winapi_GenerateConsoleCtrlEvent): New typedefs.
14643 (get_child_debug_event): Lower Win32 debug event polling from 1 sec
14644 to 250 ms.
14645 (win32_wait): Check for remote interrupt request
14646 with check_remote_input_interrupt_request.
14647 (win32_request_interrupt): New function.
14648 (win32_target_op): Set request_interrupt to win32_request_interrupt.
14649
14650 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
14651
14652 * win32-low.c (debug_registers_changed,
14653 debug_registers_used, CONTEXT_EXTENDED_REGISTERS,
14654 CONTEXT_FLOATING_POINT, CONTEXT_DEBUG_REGISTERS,
14655 CONTEXT_DEBUGGER, CONTEXT_DEBUGGER_DR): Delete.
14656 (thread_rec): Get context using the low target.
14657 (child_add_thread): Call thread_added on the low target,
14658 which does the same thing.
14659 (regptr): Delete.
14660 (do_initial_child_stuff): Remove debug registers references.
14661 Set context using the low target. Resume threads after
14662 setting the contexts.
14663 (child_continue): Remove dead variable. Remove debug
14664 registers references.
14665 (child_fetch_inferior_registers): Go through the low target.
14666 (do_child_store_inferior_registers): Remove.
14667 (child_store_inferior_registers): Go through the low target.
14668 (win32_resume): Remove debug registers references.
14669 Set context using the low target.
14670 (handle_exception): Change return type to void. Don't record
14671 context here. Set status to TARGET_WAITKIND_SPURIOUS on a
14672 first chance exception.
14673 (get_child_debug_event): Change return type to void. Remove
14674 goto loop. Always return after waiting for debug event.
14675 (win32_wait): Convert to switch statement. Handle spurious
14676 events.
14677
14678 * win32-i386-low.c (debug_registers_changed,
14679 debug_registers_used): New.
14680 (initial_stuff): Rename to ...
14681 (i386_initial_stuff): ... this. Clear debug registers
14682 state variables.
14683 (store_debug_registers): Delete.
14684 (i386_get_thread_context): New.
14685 (load_debug_registers): Delete.
14686 (i386_set_thread_context): New.
14687 (i386_thread_added): New.
14688 (single_step): Rename to ...
14689 (i386_single_step): ... this.
14690 (do_fetch_inferior_registers): Rename to ...
14691 (i386_fetch_inferior_register): ... this.
14692 (i386_store_inferior_register): New.
14693 (the_low_target): Adapt to new interface.
14694
14695 * win32-arm-low.c (CONTEXT_FLOATING_POINT): Define.
14696 (arm_get_thread_context): New.
14697 (arm_set_thread_context): New.
14698 (regptr): New.
14699 (do_fetch_inferior_registers): Rename to ...
14700 (arm_fetch_inferior_register): ... this.
14701 (arm_store_inferior_register): New.
14702 (arm_wince_breakpoint): Reimplement as unsigned long.
14703 (arm_wince_breakpoint_len): Define.
14704 (the_low_target): Adapt to new interface.
14705
14706 * win32-low.h (target_ops): Remove regmap, store_debug_registers and
14707 load_debug_registers. Add get_thread_context, set_thread_context,
14708 thread_added and store_inferior_register. Rename
14709 fetch_inferior_registers to fetch_inferior_register.
14710 (regptr): Remove declaration.
14711
14712 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
14713
14714 * linux-low.c (linux_detach): Change return type to int. Return 0.
14715 * spu-low.c (spu_detach): Likewise.
14716
14717 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
14718
14719 * target.h (target_ops): Change return type of detach to int.
14720 Add join.
14721 (join_inferior): New.
14722 * server.c (main): Don't skip detach support on mingw32.
14723 If the inferior doesn't support detaching return error.
14724 Call join_inferior instead of using waitpid.
14725 * linux-low.c (linux_join): New.
14726 (linux_target_op): Add linux_join.
14727 * spu-low.c (spu_join): New.
14728 (spu_target_ops): Add spu_join.
14729 * win32-low.c (win32_detach): Adapt to new interface.
14730 Reopen current_process_handle before detaching. Issue a child
14731 resume before detaching.
14732 (win32_join): New.
14733 (win32_target_op): Add win32_join.
14734
14735 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
14736
14737 * win32-low.c (win32-attach): Fix return value.
14738 * target.h (target_ops): Describe ATTACH return values.
14739
14740 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
14741
14742 * win32-low.c (GETPROCADDRESS): Define.
14743 (winapi_DebugActiveProcessStop): Add WINAPI. typedef as pointer.
14744 (winapi_DebugSetProcessKillOnExit): Likewise.
14745 (win32_create_inferior): Force usage of ansi CreateProcessA.
14746 (win32_attach): Use GETPROCADDRESS.
14747 (win32_detach): Likewise.
14748
14749 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
14750
14751 * win32-low.c (win32_wait): Don't use WSTOPSIG.
14752
14753 2007-03-30 Pedro Alves <pedro_alves@portugalmail.pt>
14754
14755 * win32-low.c: Commit leftover changes from 2007-03-29.
14756
14757 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
14758
14759 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Make 16-bit
14760 fields short instead of int. Add explicit padding.
14761 (i387_cache_to_fsave): Remove unnecessary casts.
14762 (i387_fsave_to_cache): Doc fix.
14763 (i387_cache_to_fxsave): Remove unnecessary casts and masking.
14764
14765 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
14766
14767 * i387-fp.c (i387_cache_to_fxsave): Reinitialize val2 before use.
14768 (i387_fxsave_to_cache): Check fp->ftag while building ftag value.
14769
14770 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
14771
14772 * configure.srv (arm*-*-mingw32ce*): Move near the other
14773 arm targets.
14774
14775 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
14776
14777 * configure.ac: Add errno checking.
14778 (AC_CHECK_HEADERS): Add errno.h, fcntl.h, signal.h,
14779 sys/file.h and malloc.h.
14780 (AC_CHECK_DECLS): Add perror.
14781 (srv_mingwce): Handle.
14782 * configure.srv (i[34567]86-*-cygwin*): Add
14783 win32-i386-low.o to srv_tgtobj.
14784 (i[34567]86-*-mingw*): Likewise.
14785 (arm*-*-mingw32ce*): Add case.
14786 * gdbreplay.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
14787 HAVE_FCNTL_H, HAVE_ERRNO_H, HAVE_MALLOC_H]: Check.
14788 [__MINGW32CE__] (strerror): New function.
14789 [__MINGW32CE__] (errno): Define to GetLastError.
14790 [__MINGW32CE__] (COUNTOF): New macro.
14791 (remote_open): Remove extra close call.
14792 * mem-break.c (delete_breakpoint_at): New function.
14793 * mem-break.h (delete_breakpoint_at): Declare.
14794 * remote-utils.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
14795 HAVE_FCNTL_H, HAVE_UNISTD_H, HAVE_ERRNO_H]: Check.
14796 [USE_WIN32API] (read, write): Add char* casts.
14797 * server.c [HAVE_UNISTD_H, HAVE_SIGNAL_H]: Check.
14798 * server.h: Include wincecompat.h on Windows CE.
14799 [HAVE_ERRNO_H]: Check.
14800 (perror): Declare if not declared.
14801 * utils.c: Add stdlib.h, errno.h and malloc.h includes.
14802 (perror_with_name): Remove errno declaration.
14803 * wincecompat.h: New.
14804 * wincecompat.c: New.
14805 * win32-low.h: New.
14806 * win32-arm-low.c: New.
14807 * win32-i386-low.c: New.
14808 (win32-low.c): Include mem-break.h and win32-low.h, and winnt.h.
14809 (OUTMSG2): Make it safe.
14810 (_T): New macro.
14811 (COUNTOF): New macro.
14812 (NUM_REGS): Get it from the low target.
14813 (CONTEXT_EXTENDED_REGISTERS, CONTEXT_FLOATING_POINT,
14814 CONTEXT_DEBUG_REGISTERS): Add fallbacks to 0.
14815 (thread_rec): Let low target handle debug registers.
14816 (child_add_thread): Likewise.
14817 (child_init_thread_list): Likewise.
14818 (continue_one_thread): Likewise.
14819 (regptr): New.
14820 (do_child_fetch_inferior_registers): Move to ...
14821 * win32-i386-low.c: ... here, and rename to ...
14822 (do_fetch_inferior_registers): ... this.
14823 * win32-low.c (child_fetch_inferior_registers):
14824 Go through the low target.
14825 (do_child_store_inferior_registers): Use regptr.
14826 (strwinerror): New function.
14827 (win32_create_inferior): Handle Windows CE.
14828 Use strwinerror instead of strerror on Windows error
14829 codes. Add program to the error output.
14830 Don't close the main thread handle on Windows CE.
14831 (win32_attach): Use coredll.dll on Windows CE.
14832 (win32_kill): Close current process and current
14833 thread handles.
14834 (win32_detach): Use coredll.dll on Windows CE.
14835 (win32_resume): Let low target handle debug registers, and
14836 step request.
14837 (handle_exception): Add/Remove initial breakpoint. Avoid
14838 non-existant WSTOPSIG on Windows CE.
14839 (win32_read_inferior_memory): Cast to remove warning.
14840 (win32_arch_string): Go through the low target.
14841 (initialize_low): Call set_breakpoint_data with the low
14842 target's breakpoint.
14843 * win32-low.c (dr, FLAG_TRACE_BIT, FCS_REGNUM,
14844 FOP_REGNUM, mappings): Move to ...
14845 * win32-i386-low.c: ... here.
14846 * win32-low.c (win32_thread_info): Move to ...
14847 * win32-low.h: ... here.
14848 * Makefile.in (SFILES): Add win32-low.c, win32-i386-low.c,
14849 win32-arm-low.c and wincecompat.c.
14850 (all:): Add $EXEEXT.
14851 (install-only:): Likewise.
14852 (gdbserver:): Likewise.
14853 (gdbreplay:): Likewise.
14854 * config.in: Regenerate.
14855 * configure: Regenerate.
14856
14857 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
14858
14859 * win32-low.c: Rename typedef thread_info to
14860 win32_thread_info throughout.
14861
14862 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
14863
14864 * win32-i386-low.c: Rename to ...
14865 * win32-low.c: ... this.
14866 * configure.srv: Replace win32-i386-low.o with win32-low.o.
14867 * Makefile.in: Likewise.
14868
14869 2007-03-27 Pedro Alves <pedro_alves@portugalmail.pt>
14870
14871 * remote-utils.c (monitor_output): Constify msg parameter.
14872 * server.h (monitor_output): Likewise.
14873 * win32-i386-low.c (handle_output_debug_string): New.
14874 (win32_kill): Handle OUTPUT_DEBUG_STRING_EVENT events using
14875 handle_output_debug_string.
14876 (get_child_debug_event): Likewise.
14877
14878 2007-03-27 Mat Hostetter <mat@lcs.mit.edu>
14879
14880 * server.c (main): Correct strtoul check.
14881
14882 2007-03-27 Jon Ringle <jon@ringle.org>
14883
14884 * linux-low.c: Check __ARCH_HAS_MMU__ also.
14885
14886 2007-03-27 Brooks Moses <brooks.moses@codesourcery.com>
14887
14888 * Makefile.in: Add dummy "pdf" and "install-pdf" targets.
14889
14890 2007-02-27 Daniel Jacobowitz <dan@codesourcery.com>
14891
14892 * terminal.h: Check HAVE_SGTTY_H.
14893
14894 2007-02-27 Mat Hostetter <mat@lcs.mit.edu>
14895
14896 * remote-utils.c (remote_open): Print out the assigned port number.
14897
14898 2007-02-26 Daniel Jacobowitz <dan@codesourcery.com>
14899
14900 * remote-utils.c (monitor_output): New function.
14901 * server.c (debug_threads): Define here.
14902 (monitor_show_help): New function.
14903 (handle_query): Handle qRcmd.
14904 (main): Do not handle 'd' packet.
14905 * server.h (debug_threads, remote_debug, monitor_output): Declare.
14906 * linux-low.c, spu-low.c, win32-i386-low.c: Remove definitions
14907 of debug_threads.
14908
14909 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
14910
14911 * Makefile.in (EXEEXT): New.
14912 (clean): Use $(EXEEXT).
14913
14914 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
14915
14916 * target.h (target_ops): Rename send_signal to request_interrupt,
14917 and remove enum target_signal parameter.
14918 * linux-low.c (linux_request_interrupt): Rename from
14919 linux_send_signal, and always send SIGINT.
14920 * spu-low.c (spu_request_interrupt): Rename from spu_send_signal,
14921 and always send SIGINT.
14922 * remote-utils.c (putpkt_binary): Call request_interrupt, instead
14923 of send_signal.
14924 (input_interrupt): Likewise.
14925
14926 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
14927
14928 * server.c (get_features_xml): Check if target implemented
14929 arch_string.
14930 * win32-i386-low.c (win32_arch_string): New.
14931 (win32_target_ops): Add win32_arch_string as arch_string member.
14932
14933 2007-02-22 Markus Deuling <deuling@de.ibm.com>
14934
14935 * spu-low.c (spu_arch_string): New.
14936 (spu_target_ops): Add spu_arch_string.
14937
14938 2007-02-16 Daniel Jacobowitz <dan@codesourcery.com>
14939
14940 * remote-utils.c: Remove HAVE_TERMINAL_H check.
14941 * configure.ac: Do not check for terminal.h.
14942 * configure, config.in: Regenerated.
14943
14944 2007-02-08 Daniel Jacobowitz <dan@codesourcery.com>
14945
14946 * Makefile.in (OBS): Add $(XML_BUILTIN).
14947 (XML_DIR, XML_TARGET, XML_FILES, XML_BUILTIN): New.
14948 (clean): Update.
14949 (target.xml, xml-builtin.c, stamp-xml, arm-with-iwmmxt.o)
14950 (arm-with-iwmmxt.c): New.
14951 * config.in, configure: Regenerate.
14952 * configure.ac: Check for iWMMXt. Handle srv_xmltarget,
14953 srv_xmlbuiltin, and srv_xmlfiles. Define USE_XML.
14954 * configure.srv: Mention srv_xmltarget and srv_xmlfiles.
14955 (arm*-*-linux*): Add iWMMXt and regset support.
14956 * linux-arm-low.c (PTRACE_GETWMMXREGS, PTRACE_SETWMMXREGS): Define.
14957 (arm_fill_gregset, arm_store_gregset, arm_fill_wmmxregset)
14958 (arm_store_wmmxregset, target_regsets): New.
14959 * server.c (get_features_xml): Take annex argument. Check builtin
14960 XML documents.
14961 (handle_query): Handle multiple annexes.
14962
14963 2007-01-29 Daniel Jacobowitz <dan@codesourcery.com>
14964
14965 * remote-utils.c [USE_WIN32API] (read, write): Define.
14966 (putpkt_binary, input_interrupt, readchar, getpkt): Use read and
14967 write.
14968
14969 2007-01-09 Daniel Jacobowitz <dan@codesourcery.com>
14970
14971 * linux-i386-low.c (the_low_target): Set arch_string.
14972 * linux-x86-64-low.c (the_low_target): Likewise.
14973 * linux-low.c (linux_arch_string): New.
14974 (linux_target_ops): Add it.
14975 * linux-low.h (struct linux_target_ops): Add arch_string.
14976 * server.c (write_qxfer_response): Use const void * for DATA.
14977 (get_features_xml): New.
14978 (handle_query): Handle qXfer:features:read. Report it for qSupported.
14979 * target.h (struct target_ops): Add arch_string method.
14980
14981 2007-01-03 Denis Pilat <denis.pilat@st.com>
14982 Daniel Jacobowitz <dan@codesourcery.com>
14983
14984 * linux-low.c (linux_kill): Handle being called with no threads.
14985 * win32-i386-low.c (win32_kill): Likewise.
14986 (get_child_debug_event): Clear current_process_handle.
14987
14988 2006-12-30 Denis PILAT <denis.pilat@st.com>
14989 Daniel Jacobowitz <dan@codesourcery.com>
14990
14991 * remote-utils.c (remote_open): Check the type of specified
14992 serial port devices before opening them.
14993 * server.c (main): Kill the inferior if an error occurs during
14994 the first remote_open.
14995
14996 2006-12-05 Markus Deuling <deuling@de.ibm.com>
14997
14998 * README: Update supported targets.
14999
15000 2006-11-28 Daniel Jacobowitz <dan@codesourcery.com>
15001
15002 * Makefile.in (clean): Remove reg-mips64.c.
15003 (reg-mips64.c, reg-mips64.o): New rules.
15004 * configure.srv: Handle mips64. Include regset support for mips.
15005 * linux-mips-low.c (union mips_register): New.
15006 (mips_get_pc, mips_set_pc, mips_reinsert_addr): Use it.
15007 (mips_breakpoint, mips_breakpoint_at): Use int.
15008 (mips_collect_register, mips_supply_register)
15009 (mips_collect_register_32bit, mips_supply_register_32bit)
15010 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
15011 (mips_store_fpregset, target_regsets): New.
15012 * thread-db.c (thread_db_get_tls_address): Use uintptr_t.
15013
15014 2006-11-22 Ulrich Weigand <uweigand@de.ibm.com>
15015
15016 * configure.srv: Add target "spu*-*-*".
15017 * Makefile.in (clean): Remove reg-spu.c.
15018 (reg-spu.c, reg-spu.o, spu-low.o): Add dependencies.
15019 * spu-low.c: New file.
15020
15021 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
15022
15023 * configure.ac: Correct td_thr_tls_get_addr test.
15024 * configure: Regenerated.
15025
15026 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
15027
15028 * linux-low.c (linux_wait_for_event): Reformat. Use the
15029 pass_signals array.
15030 * remote-utils.c (decode_address_to_semicolon): New.
15031 * server.c (pass_signals, handle_general_set): New.
15032 (handle_query): Mention QPassSignals for qSupported.
15033 (main): Call handle_general_set.
15034 * server.h (pass_signals, decode_address_to_semicolon): New.
15035
15036 2006-11-06 Daniel Jacobowitz <dan@codesourcery.com>
15037
15038 * server.c (handle_query): Correct error handling for read_auxv.
15039
15040 2005-10-19 Ulrich Weigand <uweigand@de.ibm.com>
15041
15042 * configure.srv [s390-*-linux*, s390x-*-linux*]: Set srv_linux_regsets
15043 and srv_linux_thread_db to yes.
15044 * linux-s390-low.c (s390_fill_gregset): New function.
15045 (target_regsets): Define data structure.
15046
15047 2006-10-17 Daniel Jacobowitz <dan@codesourcery.com>
15048
15049 * acinclude.m4 (SRV_CHECK_TLS_GET_ADDR): New.
15050 * configure.ac: Use it. Define HAVE_TD_THR_TLS_GET_ADDR.
15051 * config.in, configure: Regenerated.
15052 * inferiors.c (gdb_id_to_thread): New function.
15053 (gdb_id_to_thread_id): Use it.
15054 * linux-low.c (linux_target_ops): Use thread_db_get_tls_address.
15055 * linux-low.h (struct process_info): Add th member.
15056 (thread_db_get_tls_address): New prototype.
15057 * remote-utils.c (decode_address): Make non-static.
15058 * server.c (handle_query): Handle qGetTLSAddr.
15059 * server.h (gdb_id_to_thread, decode_address): New prototypes.
15060 * target.h (struct target_ops): Add get_tls_address.
15061 * thread-db.c (maybe_attach_thread): Save the thread handle.
15062 (thread_db_get_tls_address): New.
15063
15064 2006-09-28 Daniel Jacobowitz <dan@codesourcery.com>
15065
15066 * linux-low.c (PTRACE_GETSIGINFO, PTRACE_SETSIGINFO): Define.
15067 (linux_resume_one_process): Take a siginfo_t *. Update all
15068 callers. Queue it if necessary. Use PTRACE_SETSIGINFO.
15069 (struct pending_signals): Add a siginfo_t.
15070 (linux_wait_for_process): Always set last_status.
15071 (linux_wait_for_event): Use PTRACE_GETSIGINFO.
15072 (linux_queue_one_thread): Use PTRACE_GETSIGINFO.
15073 * linux-low.h (struct process_info): Add last_status.
15074
15075 2006-09-21 Daniel Jacobowitz <dan@codesourcery.com>
15076
15077 * remote-utils.c (try_rle): New function.
15078 (putpkt_binary): Use it.
15079
15080 2006-08-19 Daniel Jacobowitz <dan@codesourcery.com>
15081
15082 * Makefile.in (clean): Clean reg-x86-64-linux.c.
15083 (reg-x86-64-linux.o, reg-x86-64-linux.c): New.
15084 * configure.srv (x86_64-*-linux*): Use reg-x86-64-linux.o.
15085 * linux-x86-64-low.c (x86_64_regmap): Include ORIG_RAX.
15086 (x86_64_fill_gregset, x86_64_store_gregset): Skip floating
15087 point registers.
15088
15089 2006-08-08 Richard Sandiford <richard@codesourcery.com>
15090
15091 * server.c (terminal_fd): New variable.
15092 (old_foreground_pgrp): Likewise.
15093 (restore_old_foreground_pgrp): New function.
15094 (start_inferior): Record the terminal file descriptor in terminal_fd
15095 and its original foreground group in old_foreground_pgrp. Register
15096 restore_old_foreground_pgrp with atexit().
15097
15098 2006-07-26 Daniel Jacobowitz <dan@codesourcery.com>
15099
15100 * server.c (handle_query): Correct qPart to qXfer.
15101
15102 2006-07-22 Daniel Jacobowitz <dan@codesourcery.com>
15103
15104 * configure.ac: Check for more headers which are missing on
15105 Windows. Automatically supply -lwsock32 and USE_WIN32API.
15106 * configure.srv: Add Cygwin and mingw32.
15107 * remote-utils.c: Don't include headers unconditionally which
15108 are missing on mingw32. Include <winsock.h> for mingw32.
15109 (remote_open): Adjust for mingw32 support. Flush
15110 standard error after writing to it.
15111 (remote_close, putpkt_binary, input_interrupt, block_async_io)
15112 (unblock_async_io, enable_async_io, disable_async_io)
15113 (readchar, getpkt): Update for Winsock support.
15114 (prepare_resume_reply): Expect a protocol signal number.
15115 * server.c: Disable <sys/wait.h> on mingw32.
15116 (start_inferior): Adjust for mingw32 support. Flush
15117 standard error after writing to it.
15118 (attach_inferior): Likewise. Use protocol signal
15119 numbers.
15120 (main): Skip 'D' packet on mingw32. Use protocol signal numbers
15121 and names.
15122 * win32-i386-low.c: New file.
15123 * Makefile.in (XM_CLIBS): Set.
15124 (gdbserver, gdbreplay): Use $(INTERNAL_CFLAGS).
15125 (win32-i386-low.o): New dependency rule.
15126 * linux-low.c (linux_wait): Use target signal numbers.
15127 * target.h (struct target_ops): Doc fix.
15128 * server.h (target_signal_to_name): New prototype.
15129 * gdbreplay.c: Don't include headers unconditionally which
15130 are missing on mingw32. Include <winsock.h> for mingw32.
15131 (remote_close, remote_open): Adjust for Winsock support.
15132 * configure, config.in: Regenerated.
15133
15134 2006-07-12 Daniel Jacobowitz <dan@codesourcery.com>
15135
15136 * server.c (decode_xfer_read, write_qxfer_response): New.
15137 (handle_query): Take a packet length argument. Handle
15138 qXfer:auxv:read instead of qPart:auxv:read. Mention it in
15139 the qSupported response.
15140 (main): Update call to handle_query.
15141
15142 2006-06-22 Daniel Jacobowitz <dan@codesourcery.com>
15143
15144 * remote-utils.c (remote_escape_output, remote_unescape_input): New.
15145 (putpkt_binary): Renamed from putpkt and adjusted for binary
15146 data.
15147 (putpkt): New wrapper for putpkt_binary.
15148 (readchar): Don't mask off the high bit.
15149 (decode_X_packet): New function.
15150 * server.c (main): Call putpkt_binary if a handler sets the packet
15151 length. Save the length of the incoming packet. Handle 'X'.
15152 * server.h (gdb_byte, remote_escape_output, decode_X_packet): New.
15153
15154 2006-06-21 Daniel Jacobowitz <dan@codesourcery.com>
15155
15156 * server.c (handle_query): Handle qSupported.
15157
15158 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
15159
15160 * remote-utils.c (all_symbols_looked_up): New variable.
15161 (look_up_one_symbol): Check it.
15162 * server.h (look_up_one_symbol): New declaration.
15163 * thread-db.c (thread_db_init): Set all_symbols_looked_up.
15164
15165 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
15166
15167 * Makefile.in (linux-arm-low.o): Update dependencies.
15168 * linux-arm-low.c: Include "gdb_proc_service.h".
15169 (PTRACE_GET_THREAD_AREA): Define.
15170 (ps_get_thread_area): New function.
15171
15172 2006-05-09 Nathan Sidwell <nathan@codesourcery.com>
15173
15174 * configure.srv (m68k*-*-uclinux*): New target.
15175 * linux-low.c (linux_create_inferior): Use vfork on mmuless systems.
15176 (linux_resume_one_process): Remove extraneous cast.
15177 (linux_read_offsets): New.
15178 (linux_target_op): Add linux_read_offsets on mmuless systems.
15179 * server.c (handle_query): Add qOffsets logic.
15180 * target.h (struct target_ops): Add read_offsets.
15181
15182 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
15183
15184 * linux-mips-low.c: Include <sys/ptrace.h> and "gdb_proc_service.h".
15185 (PTRACE_GET_THREAD_AREA): Define.
15186 (ps_get_thread_area): New function.
15187 * Makefile.in (linux-i386-low.o, linux-mips-low.o)
15188 (linux-x86-64-low.o): Update.
15189
15190 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
15191
15192 * configure.ac: Remove checks for prfpregset_t.
15193 * gdb_proc_service.h: New file.
15194 * linux-i386-low.c, linux-x86-64-low.c, thread-db.c: Use the
15195 new "gdb_proc_service.h".
15196 * proc-service.c: Likewise.
15197 (ps_pglobal_lookup, ps_pdread, ps_pdwrite): Use psaddr_t.
15198 (ps_lgetfpregs, ps_lsetfpregs): Use a void* argument.
15199 * Makefile.in (gdb_proc_service_h): Updated.
15200 * configure, config.in: Regenerated.
15201
15202 2006-03-03 Daniel Jacobowitz <dan@codesourcery.com>
15203
15204 * remote-utils.c (prepare_resume_reply): Move declaration
15205 of gdb_id_from_wait to the top of the block.
15206
15207 2006-02-15 Daniel Jacobowitz <dan@codesourcery.com>
15208
15209 * linux-low.c (regsets_store_inferior_registers): Read the regset
15210 from the target before filling it.
15211
15212 2006-02-08 Daniel Jacobowitz <dan@codesourcery.com>
15213
15214 * server.c (attach_inferior): Return SIGTRAP for a successful
15215 attach.
15216
15217 2006-02-01 Daniel Jacobowitz <dan@codesourcery.com>
15218
15219 * Makefile.in (OBS): Add version.o.
15220 (STAGESTUFF): Delete.
15221 (version.o): Add dependencies.
15222 (version.c): Replace rule.
15223 (clean): Remove version.c.
15224 * server.c (gdbserver_version): New.
15225 (gdbserver_usage): Use printf.
15226 (main): Handle --version and --help.
15227 * server.h (version, host_name): Add declarations.
15228
15229 2005-12-23 Eli Zaretskii <eliz@gnu.org>
15230
15231 * linux-arm-low.c:
15232 * linux-arm-low.c:
15233 * inferiors.c:
15234 * i387-fp.h:
15235 * i387-fp.c:
15236 * gdbreplay.c:
15237 * regcache.c:
15238 * proc-service.c:
15239 * mem-break.h:
15240 * mem-break.c:
15241 * linux-x86-64-low.c:
15242 * linux-sh-low.c:
15243 * linux-s390-low.c:
15244 * linux-ppc64-low.c:
15245 * linux-ppc-low.c:
15246 * linux-mips-low.c:
15247 * linux-m68k-low.c:
15248 * linux-m32r-low.c:
15249 * linux-low.h:
15250 * linux-low.c:
15251 * linux-ia64-low.c:
15252 * linux-i386-low.c:
15253 * linux-crisv32-low.c:
15254 * thread-db.c:
15255 * terminal.h:
15256 * target.h:
15257 * target.c:
15258 * server.h:
15259 * server.c:
15260 * remote-utils.c:
15261 * regcache.h:
15262 * utils.c:
15263 * Makefile.in:
15264 * configure.ac:
15265 * gdbserver.1: Add (C) after Copyright. Update the FSF
15266 address.
15267
15268 2005-11-13 Daniel Jacobowitz <dan@codesourcery.com>
15269
15270 * linux-arm-low.c (arm_eabi_breakpoint): New variable.
15271 (arm_breakpoint_at): Recognize both breakpoints.
15272 (the_low_target): Use the correct breakpoint instruction.
15273
15274 2005-11-02 Daniel Jacobowitz <dan@codesourcery.com>
15275
15276 * configure.srv (x86_64-*-linux*): Turn on thread_db support.
15277 * linux-x86-64-low.c (x86_64_breakpoint, x86_64_breakpoint_len)
15278 (x86_64_get_pc, x86_64_set_pc, x86_64_breakpoint_at): New.
15279 (the_low_target): Update.
15280
15281 2005-10-25 Andreas Schwab <schwab@suse.de>
15282
15283 * server.c (main): Allocate mem_buf with PBUFSIZ bytes.
15284
15285 * linux-ia64-low.c (ia64_regmap): Remove NAT registers.
15286 (ia64_num_regs): Reduce to 462.
15287
15288 2005-09-17 Daniel Jacobowitz <dan@codesourcery.com>
15289
15290 * acinclude.m4: Correct quoting.
15291 * aclocal.m4: Regenerated.
15292
15293 Suggested by SZOKOVACS Robert <szo@ies.hu>:
15294 * thread-db.c (thread_db_err_str): Handle TD_VERSION.
15295 (thread_db_init): Call thread_db_err_str.
15296 * configure.ac: Check for TD_VERSION.
15297 * config.in, configure: Regenerated.
15298
15299 2005-07-31 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
15300
15301 * server.h (error, fatal, warning): Add ATTR_FORMAT.
15302
15303 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
15304
15305 * configure.ac: Define HAVE_LINUX_REGSETS even if PTRACE_GETREGS
15306 is not available. Define HAVE_PTRACE_GETREGS if it is.
15307 * config.in, configure: Regenerated.
15308 * configure.srv: Set srv_linux_regsets for PowerPC and PowerPC64.
15309 * linux-i386-low.c, linux-m68k-low.c: Update to use
15310 HAVE_PTRACE_GETREGS.
15311 * linux-low.c (regsets_fetch_inferior_registers)
15312 (regsets_store_inferior_registers): Only return 0 if we processed
15313 GENERAL_REGS.
15314 * linux-ppc-low.c (ppc_fill_gregset, target_regsets): New.
15315 * linux-ppc64-low.c (ppc_fill_gregset, target_regsets): New.
15316
15317 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
15318
15319 * inferiors.c (struct thread_info): Add gdb_id.
15320 (add_thread): Add gdb_id argument.
15321 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New.
15322 * linux-low.c (linux_create_inferior, linux_attach_lwp): Update
15323 calls to add_thread.
15324 * remote-utils.c (prepare_resume_reply: Use thread_to_gdb_id.
15325 * server.c (handle_query): Use thread_to_gdb_id.
15326 (handle_v_cont, main): Use gdb_id_to_thread_id.
15327 * server.h (add_thread): Update prototype.
15328 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New
15329 prototypes.
15330
15331 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
15332
15333 * linux-low.c (fetch_register, usr_store_inferior_registers): Handle
15334 left-padded registers.
15335 * linux-low.h (struct linux_target_ops): Add left_pad_xfer.
15336 * linux-ppc64-low.c (the_low_target): Set left_pad_xfer.
15337
15338 2005-07-01 Steve Ellcey <sje@cup.hp.com>
15339
15340 * configure.ac (BFD_NEED_DECLARATION): Replace with AC_CHECK_DECLS.
15341 * configure: Regenerate.
15342 * config.in: Regenerate.
15343 * server.h (NEED_DECLARATION_STRERROR):
15344 Replace with !HAVE_DECL_STRERROR.
15345
15346 2005-06-16 Daniel Jacobowitz <dan@codesourcery.com>
15347
15348 * linux-low.c (linux_wait, linux_send_signal): Don't test
15349 an unsigned long variable for > 0 if it could be MAX_ULONG.
15350 * server.c (myresume): Likewise.
15351 * target.c (set_desired_inferior): Likewise.
15352
15353 2005-06-13 Mark Kettenis <kettenis@gnu.org>
15354
15355 * configure.ac: Simplify and improve check for socklen_t.
15356 * configure, config.in: Regenerate.
15357
15358 2005-06-12 Daniel Jacobowitz <dan@codesourcery.com>
15359
15360 * acconfig.h: Remove.
15361 * configure.ac: Add a test for socklen_t. Use three-argument
15362 AC_DEFINE throughout.
15363 * config.in: Regenerated using autoheader 2.59.
15364 * configure: Regenerated.
15365
15366 * gdbreplay.c (socklen_t): Provide a default.
15367 (remote_open): Use socklen_t.
15368 * remote-utils.c (socklen_t): Provide a default.
15369 (remote_open): Use socklen_t.
15370 (convert_int_to_ascii, convert_ascii_to_int, decode_M_packet): Use
15371 unsigned char.
15372
15373 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Use unsigned
15374 char for buffers.
15375 * linux-low.c (linux_read_memory, linux_write_memory)
15376 (linux_read_auxv): Likewise.
15377 * mem-break.c (breakpoint_data, set_breakpoint_data, check_mem_read)
15378 (check_mem_write): Likewise.
15379 * mem-break.h (set_breakpoint_data, check_mem_read, check_mem_write):
15380 Likewise.
15381 * regcache.c (struct inferior_rgcache_data, registers_to_string)
15382 (registers_from_string, register_data): Likewise.
15383 * server.c (handle_query, main): Likewise.
15384 * server.h (convert_ascii_to_int, convert_int_to_ascii)
15385 (decode_M_packet): Likewise.
15386 * target.c (read_inferior_memory, write_inferior_memory): Likewise.
15387 * target.h (struct target_ops): Update read_memory, write_memory,
15388 and read_auxv.
15389 (read_inferior_memory, write_inferior_memory): Update.
15390 * linux-low.h (struct linux_target_ops): Change type of breakpoint
15391 to unsigned char *.
15392 * linux-arm-low.c, linux-cris-low.c, linux-crisv32-low.c,
15393 linux-i386-low.c, linux-m32r-low.c, linux-m68k-low.c,
15394 linux-mips-low.c, linux-ppc-low.c, linux-ppc64-low.c,
15395 linux-s390-low.c, linux-sh-low.c: Update for changes in
15396 read_inferior_memory and the_low_target->breakpoint.
15397
15398 2005-05-28 Daniel Jacobowitz <dan@codesourcery.com>
15399
15400 * Makefile.in (SFILES): Add linux-ppc64-low.c.
15401 (linux-ppc64-low.o, reg-ppc64.c, reg-ppc64.o): New targets.
15402 * configure.srv: Add powerpc64-*-linux*.
15403 * linux-ppc64-low.c: New file.
15404
15405 2005-05-23 Orjan Friberg <orjanf@axis.com>
15406
15407 * linux-cris-low.c: New file with support for CRIS.
15408 * linux-crisv32-low.c: Ditto for CRISv32.
15409 * Makefile.in (SFILES): Add linux-cris-low.c, linux-crisv32-low.c.
15410 (clean): Add reg-cris.c and reg-crisv32.c.
15411 Add linux-cris-low.o, linux-crisv32-low.o, reg-cris.o, reg-cris.c,
15412 reg-crisv32.o, and reg-crisv32.c to make rules.
15413 * configure.srv: Add cris-*-linux* and crisv32-*-linux* to list of
15414 recognized targets.
15415
15416 2005-05-16 Ulrich Weigand <uweigand@de.ibm.com>
15417
15418 * linux-low.c (fetch_register): Ensure buffer size is a multiple
15419 of sizeof (PTRACE_XFER_TYPE).
15420 (usr_store_inferior_registers): Likewise. Zero out excess bytes.
15421
15422 2005-05-12 Orjan Friberg <orjanf@axis.com>
15423
15424 * target.h (struct target_ops): Add insert_watchpoint,
15425 remove_watchpoint, stopped_by_watchpoint, stopped_data_address function
15426 pointers for hardware watchpoint support.
15427 * linux-low.h (struct linux_target_ops): Ditto.
15428 * linux-low.c (linux_insert_watchpoint, linux_remove_watchpoint)
15429 (linux_stopped_by_watchpoint, linux_stopped_data_address): New. Add
15430 to linux_target_ops.
15431 * remote-utils.c (prepare_resume_reply): Add watchpoint information to
15432 reply packet.
15433 * server.c (main): Recognize 'Z' and 'z' packets.
15434
15435 2005-05-10 Ulrich Weigand <uweigand@de.ibm.com>
15436
15437 * linux-s390-low.c (s390_breakpoint, s390_breakpoint_len): Define.
15438 (s390_get_pc, s390_set_pc, s390_breakpoint_at): New functions.
15439 (the_low_target): Add new members.
15440
15441 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
15442
15443 * proc-service.c (ps_lgetregs): Search all_processes instead of
15444 all_threads.
15445
15446 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
15447
15448 * server.c (start_inferior): Change return type to int.
15449 (attach_inferior): Change sigptr to int *.
15450 (handle_v_cont, handle_v_requests): Change signal to int *.
15451 (main): Change signal to int.
15452
15453 2005-04-15 Kei Sakamoto <sakamoto.kei@renesas.com>
15454
15455 * Makefile.in: Add linux-m32r-low.o, reg-m32r.c and reg-m32r.o.
15456 * configure.srv: Add m32r*-*-linux*.
15457 * linux-m32r-low.c: New file.
15458
15459 2005-03-04 Daniel Jacobowitz <dan@codesourcery.com>
15460
15461 * Makefile.in (stamp-h): Set CONFIG_HEADERS explicitly.
15462
15463 2005-03-03 Daniel Jacobowitz <dan@codesourcery.com>
15464
15465 * inferiors.c (change_inferior_id, add_thread, find_inferior_id):
15466 Take unsigned long arguments for PIDs.
15467 * linux-low.c (add_process, linux_attach_lwp, linux_attach)
15468 (linux_thread_alive, linux_wait_for_event, kill_lwp, send_sigstop)
15469 (wait_for_sigstop, linux_resume_one_process)
15470 (regsets_fetch_inferior_registers, linux_send_signal)
15471 (linux_read_auxv): Likewise. Update the types of variables holding
15472 PIDs. Update format string specifiers.
15473 * linux-low.h (struct process_info, linux_attach_lwp): Likewise.
15474 * remote-utils.c (prepare_resume_reply): Likewise.
15475 * server.c (cont_thread, general_thread, step_thread)
15476 (thread_from_wait, old_thread_from_wait, signal_pid): Change type to
15477 unsigned long.
15478 (handle_query): Update format specifiers.
15479 (handle_v_cont, main): Use strtoul for thread IDs.
15480 * server.h (struct inferior_list_entry): Use unsigned long for ID.
15481 (add_thread, find_inferior_id, change_inferior_id, cont_thread)
15482 (general_thread, step_thread, thread_from_wait)
15483 (old_thread_from_wait): Update.
15484 * target.h (struct thread_resume): Use unsigned long for THREAD.
15485 (struct target_ops): Use unsigned long for arguments to attach and
15486 thread_alive.
15487
15488 2005-02-24 Daniel Jacobowitz <dan@codesourcery.com>
15489
15490 * acinclude.m4: Include bfd/bfd.m4 directly.
15491 * configure.ac: Use AC_ARG_PROGRAM. Suggested by Aron Griffis
15492 <agriffis@toolchain.org>.
15493 * aclocal.m4, configure: Regenerated.
15494
15495 2005-01-07 Andrew Cagney <cagney@gnu.org>
15496
15497 * configure.ac: Rename configure.in, require autoconf 2.59.
15498 * configure: Re-generate.
15499
15500 2004-12-08 Daniel Jacobowitz <dan@debian.org>
15501
15502 * acinclude.m4 (SRV_CHECK_THREAD_DB): Add ps_get_thread_area. Reset
15503 LIBS when finished.
15504 * aclocal.m4: Regenerated.
15505 * configure: Regenerated.
15506
15507 2004-11-21 Andreas Schwab <schwab@suse.de>
15508
15509 * linux-m68k-low.c (m68k_num_gregs): Define.
15510 (m68k_fill_gregset, m68k_store_gregset, m68k_fill_fpregset)
15511 (m68k_store_fpregset, target_regsets) [HAVE_LINUX_REGSETS]: New.
15512 (m68k_breakpoint, m68k_breakpoint_len, m68k_get_pc, m68k_set_pc)
15513 (m68k_breakpoint_at): New. Add to the_low_target.
15514
15515 * configure.srv (m68*-*-linux*): Set srv_linux_regsets and
15516 srv_linux_thread_db to yes.
15517
15518 2004-10-20 Joel Brobecker <brobecker@gnat.com>
15519
15520 * linux-x86-64-low.c (ARCH_SET_GS): Add definition if missing.
15521 (ARCH_SET_FS): Likewise.
15522 (ARCH_GET_FS): Likewise.
15523 (ARCH_GET_GS): Likewise.
15524
15525 2004-10-16 Daniel Jacobowitz <dan@debian.org>
15526
15527 * linux-i386-low.c (ps_get_thread_area): New.
15528 * linux-x86-64-low.c (ps_get_thread_area): New.
15529 * linux-low.c: Include <sys/syscall.h>.
15530 (linux_kill_one_process): Don't kill the first thread here.
15531 (linux_kill): Kill the first thread here.
15532 (kill_lwp): New function.
15533 (send_sigstop, linux_send_signal): Use it.
15534 * proc-service.c: Clean up #ifdefs.
15535 (fpregset_info): Delete.
15536 (ps_lgetregs): Update and enable implementation.
15537 (ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs): Remove disabled
15538 implementations.
15539 * remote-utils.c (struct sym_cache, symbol_cache): New.
15540 (input_interrupt): Print a clearer message.
15541 (async_io_enabled): New variable.
15542 (enable_async_io, disable_async_io): Use it. Update comments.
15543 (look_up_one_symbol): Use the symbol cache.
15544 * thread-db.c (thread_db_look_up_symbols): New function.
15545 (thread_db_init): Update comments. Call thread_db_look_up_symbols.
15546
15547 2004-10-16 Daniel Jacobowitz <dan@debian.org>
15548
15549 * configure.in: Test for -rdynamic.
15550 * configure: Regenerated.
15551 * Makefile (INTERNAL_LDFLAGS): New.
15552 (gdbserver, gdbreplay): Use it.
15553
15554 2004-09-02 Andrew Cagney <cagney@gnu.org>
15555
15556 * Makefile.in (TAGS): Replace TM_FILE with DEPRECATED_TM_FILE.
15557
15558 2004-03-23 Daniel Jacobowitz <drow@mvista.com>
15559
15560 * linux-low.c (linux_wait): Clear all_processes list also.
15561
15562 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
15563
15564 * linux-low.c: Include <errno.h>. Remove extern declaration of
15565 errno.
15566
15567 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
15568
15569 * gdbreplay.c, server.h, utils.c: Update copyright years.
15570
15571 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
15572
15573 * server.c (main): Print child status or termination signal from
15574 variable 'signal', not 'sig'.
15575
15576 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
15577
15578 * linux-low.c (linux_read_memory): Change return type to
15579 int. Check for and return error from ptrace().
15580 * target.c (read_inferior_memory): Change return type to int. Pass
15581 back return status from the_target->read_memory().
15582 * target.h (struct target_ops): Adapt *read_memory() prototype.
15583 Update comment.
15584 (read_inferior_memory): Adapt prototype.
15585 * server.c (main): Return an error packet if
15586 read_inferior_memory() returns an error.
15587
15588 2004-03-04 Daniel Jacobowitz <drow@mvista.com>
15589
15590 * Makefile.in (distclean): Remove config.h, stamp-h, and config.log.
15591 Unify with other clean targets.
15592
15593 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
15594
15595 * server.c (handle_v_cont): Call set_desired_inferior.
15596
15597 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
15598
15599 * remote-utils.c (prepare_resume_reply): Always supply "thread:".
15600
15601 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
15602
15603 * linux-low.c (linux_wait): Unblock async I/O.
15604 (linux_resume): Block and enable async I/O.
15605 * remote-utils.c (block_async_io, unblock_async_io): New functions.
15606 * server.h (block_async_io, unblock_async_io): Add prototypes.
15607
15608 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
15609
15610 * remote-utils.c (remote_open): Print a status notice after
15611 opening a TCP port.
15612 * server.c (attach_inferior): Print a status notice after
15613 attaching.
15614
15615 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
15616
15617 * linux-arm-low.c (arm_get_pc): Print out stop PC in debug mode.
15618
15619 2004-02-26 Daniel Jacobowitz <drow@mvista.com>
15620
15621 * remote-utils.c (write_enn): Use "E01" instead of "ENN" for the
15622 error packet.
15623 * server.c, target.h: Update copyright years.
15624
15625 2004-02-25 Roland McGrath <roland@redhat.com>
15626
15627 * target.h (struct target_ops): New member `read_auxv'.
15628 * server.c (handle_query): Handle qPart:auxv:read: query using that.
15629 * linux-low.c (linux_read_auxv): New function.
15630 (linux_target_ops): Initialize `read_auxv' member to that.
15631
15632 2004-02-17 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
15633
15634 Committed by Jim Blandy <jimb@redhat.com>.
15635
15636 * linux-s390-low.c (s390_num_regs): Update.
15637 (s390_regmap): Remove control registers. Use __s390x__ predefine
15638 instead of GPR_SIZE to distiguish s390 and s390x targets.
15639
15640 2004-01-31 Daniel Jacobowitz <drow@mvista.com>
15641
15642 * linux-low.c: Update copyright year.
15643 (check_removed_breakpoint): Clear pending_is_breakpoint.
15644 (linux_set_resume_request, linux_queue_one_thread)
15645 (resume_status_pending_p): New functions.
15646 (linux_continue_one_thread): Use process->resume.
15647 (linux_resume): Only resume threads if there are no pending events.
15648 * linux-low.h (struct process_info): Add resume request
15649 pointer.
15650
15651 2004-01-30 Daniel Jacobowitz <drow@mvista.com>
15652
15653 * regcache.c (new_register_cache): Clear the allocated register
15654 buffer. Suggested by Atsushi Nemoto <anemo@mba.ocn.ne.jp>.
15655
15656 2003-10-13 Daniel Jacobowitz <drow@mvista.com>
15657
15658 * linux-low.c (linux_resume): Take a struct thread_resume *
15659 argument.
15660 (linux_wait): Update call.
15661 (resume_ptr): New static variable.
15662 (linux_continue_one_thread): Renamed from
15663 linux_continue_one_process. Use resume_ptr.
15664 (linux_resume): Use linux_continue_one_thread.
15665 * server.c (handle_v_cont, handle_v_requests): New functions.
15666 (myresume): New function.
15667 (main): Handle 'v' case.
15668 * target.h (struct thread_resume): New type.
15669 (struct target_ops): Change argument of "resume" to struct
15670 thread_resume *.
15671 (myresume): Delete macro.
15672
15673 2003-08-08 H.J. Lu <hongjiu.lu@intel.com>
15674
15675 * Makefile.in (install-only): Create dest dir. Support DESTDIR.
15676 (uninstall): Support DESTDIR.
15677
15678 Mon Jul 21 20:09:34 UTC 2003 Brendan Conoboy <blc@redhat.com>
15679
15680 * configure.srv: Add xscale*linux copy of arm*linux entry.
15681
15682 2003-07-24 Daniel Jacobowitz <drow@mvista.com>
15683
15684 * linux-arm-low.c (arm_reinsert_addr): New function.
15685 (the_low_target): Add arm_reinsert_addr.
15686
15687 2003-07-08 Mark Kettenis <kettenis@gnu.org>
15688
15689 * mem-break.c: Remove whitespace at end of file.
15690
15691 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
15692
15693 * configure.in: Check whether we need to prototype strerror.
15694 * server.h: Optionally prototype strerror.
15695 * gdbreplay.c (perror_with_name): Use strerror.
15696 * linux-low.c (linux_attach_lwp): Use strerror.
15697 * utils.c (perror_with_name): Use strerror.
15698 * config.in, configure: Regenerated.
15699
15700 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
15701
15702 * linux-sh-low.c (sh_regmap): Fix FP register offsets, reported by
15703 SUGIOKA Toshinobu <sugioka@itonet.co.jp>.
15704
15705 2003-06-20 Daniel Jacobowitz <drow@mvista.com>
15706
15707 * Makefile.in (SFILES): Update.
15708 * low-hppabsd.c, low-lynx.c, low-nbsd.c, low-sim.c, low-sparc.c,
15709 low-sun3.c: Remove files.
15710
15711 2003-06-17 Daniel Jacobowitz <drow@mvista.com>
15712
15713 * linux-low.c: Move comment to linux_thread_alive where it belonged.
15714 (linux_detach_one_process, linux_detach): New functions.
15715 (linux_target_ops): Add linux_detach.
15716 * server.c (main): Handle 'D' packet.
15717 * target.h (struct target_ops): Add "detach" member.
15718 (detach_inferior): Define.
15719
15720 2003-06-13 Mark Kettenis <kettenis@gnu.org>
15721
15722 From Kelley Cook <kelleycook@wideopenwest.com>:
15723 * configure.srv: Accept i[34567]86 variants.
15724
15725 2003-06-05 Daniel Jacobowitz <drow@mvista.com>
15726
15727 * linux-low.c (linux_wait_for_event): Correct comment typos.
15728 (linux_resume_one_process): Call check_removed_breakpoint.
15729 (linux_send_signal): New function.
15730 (linux_target_ops): Add linux_send_signal.
15731 * remote-utils.c (putpkt, input_interrupt): Use send_signal instead
15732 of kill.
15733 * target.h (struct target_ops): Add send_signal.
15734
15735 2003-05-29 Jim Blandy <jimb@redhat.com>
15736
15737 * linux-low.c (usr_store_inferior_registers): Transfer buf in
15738 PTRACE_XFER_TYPE-sized chunks, not int-sized chunks. Otherwise,
15739 if 'int' is smaller than PTRACE_XFER_TYPE, you end up throwing
15740 away part of the register's value.
15741
15742 2003-03-26 Daniel Jacobowitz <drow@mvista.com>
15743
15744 * linux-low.c (linux_create_inferior): Use __SIGRTMIN.
15745 (linux_wait_for_event, linux_init_signals): Likewise.
15746
15747 2003-03-17 Daniel Jacobowitz <drow@mvista.com>
15748
15749 * configure.in: Check for stdlib.h.
15750 * configure: Regenerated.
15751 * config.in: Regenerated.
15752
15753 2003-01-04 Andreas Schwab <schwab@suse.de>
15754
15755 * linux-m68k-low.c (m68k_num_regs): Define to 29 instead of 31.
15756
15757 2003-01-02 Andrew Cagney <ac131313@redhat.com>
15758
15759 * Makefile.in: Remove obsolete code.
15760
15761 2002-11-20 Daniel Jacobowitz <drow@mvista.com>
15762
15763 * linux-s390-low.c (s390_regmap): Check GPR_SIZE instead of
15764 defined(PT_FPR0_HI).
15765
15766 2002-11-17 Stuart Hughes <seh@zee2.com>
15767
15768 * linux-arm-low.c (arm_num_regs): Increase.
15769 (arm_regmap): Include status register.
15770
15771 2002-11-17 Daniel Jacobowitz <drow@mvista.com>
15772
15773 * linux-low.c (register_addr): Remove incorrect -1 check.
15774
15775 2002-08-29 Daniel Jacobowitz <drow@mvista.com>
15776
15777 * linux-low.c (linux_create_inferior): Call setpgid. Return
15778 the new PID.
15779 (unstopped_p, linux_signal_pid): Remove.
15780 (linux_target_ops): Remove linux_signal_pid.
15781 * remote-utils.c (putpkt, input_interrupt): Use signal_pid
15782 global instead of target method.
15783 * target.h (struct target_ops): Remove signal_pid. Update comment
15784 for create_inferior.
15785 * server.c (signal_pid): New variable.
15786 (create_inferior): Set signal_pid. Block SIGTTOU and SIGTTIN in
15787 gdbserver. Set the child to be the foreground process group.
15788 (attach_inferior): Set signal_pid.
15789
15790 2002-08-23 Daniel Jacobowitz <drow@mvista.com>
15791
15792 * ChangeLog: New file, with entries from gdb/ChangeLog after GDB 5.2.
15793
15794 2002-08-20 Jim Blandy <jimb@redhat.com>
15795
15796 * Makefile.in (LDFLAGS): Allow the configure script to establish a
15797 default for this.
15798
15799 2002-08-01 Andrew Cagney <cagney@redhat.com>
15800
15801 * Makefile.in: Make chill references obsolete.
15802
15803 2002-07-24 Kevin Buettner <kevinb@redhat.com>
15804
15805 * configure.in (unistd.h): Add to AC_CHECK_HEADERS list.
15806 * configure: Regenerate.
15807 * config.in: Regenerate.
15808
15809 2002-07-09 David O'Brien <obrien@FreeBSD.org>
15810
15811 * gdbreplay.c (stdlib.h, unistd.h): Conditionaly include.
15812 (perror_with_name, remote_close, remote_open, expect, play): Static.
15813
15814 2002-07-04 Michal Ludvig <mludvig@suse.cz>
15815
15816 * linux-x86-64-low.c (x86_64_regmap): Make it an array of
15817 byte offsets instead of an array of indexes.
15818 (x86_64_store_gregset, x86_64_store_fpregset): Parameter made const.
15819
15820 2002-06-13 Daniel Jacobowitz <drow@mvista.com>
15821
15822 * regcache.c: Add comment.
15823
15824 2002-06-11 Daniel Jacobowitz <drow@mvista.com>
15825
15826 * thread-db.c: New file.
15827 * proc-service.c: New file.
15828 * acinclude.m4: New file.
15829 * Makefile.in: Add GDBSERVER_LIBS, gdb_proc_service_h,
15830 proc-service.o, and thread-db.o.
15831 (linux-low.o): Add USE_THREAD_DB.
15832 * acconfig.h: Add HAVE_PRGREGSET_T, HAVE_PRFPREGSET_T,
15833 HAVE_LWPID_T, HAVE_PSADDR_T, and PRFPREGSET_T_BROKEN.
15834 * aclocal.m4: Regenerated.
15835 * config.in: Regenerated.
15836 * configure: Regenerated.
15837 * configure.in: Check for proc_service.h, sys/procfs.h,
15838 thread_db.h, and linux/elf.h headrs.
15839 Check for lwpid_t, psaddr_t, prgregset_t, prfpregset_t, and
15840 PRFPREGSET_T_BROKEN. Introduce srv_thread_depfiles and USE_THREAD_DB.
15841 Check for -lthread_db and thread support.
15842 * configure.srv: Enable thread_db support for ARM, i386, MIPS,
15843 PowerPC, and SuperH.
15844 * i387-fp.c: Constify arguments.
15845 * i387-fp.h: Likewise.
15846 * inferiors.c: (struct thread_info): Renamed from
15847 `struct inferior_info'. Remove PID member. Use generic inferior
15848 list header. All uses updated.
15849 (inferiors, signal_pid): Removed.
15850 (all_threads): New variable.
15851 (get_thread): Define.
15852 (add_inferior_to_list): New function.
15853 (for_each_inferior): New function.
15854 (change_inferior_id): New function.
15855 (add_inferior): Removed.
15856 (remove_inferior): New function.
15857 (add_thread): New function.
15858 (free_one_thread): New function.
15859 (remove_thread): New function.
15860 (clear_inferiors): Use for_each_inferior and free_one_thread.
15861 (find_inferior): New function.
15862 (find_inferior_id): New function.
15863 (inferior_target_data): Update argument type.
15864 (set_inferior_target_data): Likewise.
15865 (inferior_regcache_data): Likewise.
15866 (set_inferior_regcache_data): Likewise.
15867 * linux-low.c (linux_bp_reinsert): Remove.
15868 (all_processes, stopping_threads, using_thrads)
15869 (struct pending_signals, debug_threads, pid_of): New.
15870 (inferior_pid): Replace with macro.
15871 (struct inferior_linux_data): Remove.
15872 (get_stop_pc, add_process): New functions.
15873 (linux_create_inferior): Restore SIGRTMIN+1 before calling exec.
15874 Use add_process and add_thread.
15875 (linux_attach_lwp): New function, based on old linux_attach. Use
15876 add_process and add_thread. Set stop_expected for new threads.
15877 (linux_attach): New function.
15878 (linux_kill_one_process): New function.
15879 (linux_kill): Kill all LWPs.
15880 (linux_thread_alive): Use find_inferior_id.
15881 (check_removed_breakpoints, status_pending_p): New functions.
15882 (linux_wait_for_process): Renamed from linux_wait_for_one_inferior.
15883 Update. Use WNOHANG. Wait for cloned processes also. Update process
15884 struct for the found process.
15885 (linux_wait_for_event): New function.
15886 (linux_wait): Use it. Support LWPs.
15887 (send_sigstop, wait_for_sigstop, stop_all_processes)
15888 (linux_resume_one_process, linux_continue_one_process): New functions.
15889 (linux_resume): Support LWPs.
15890 (REGISTER_RAW_SIZE): Remove.
15891 (fetch_register): Use register_size instead. Call supply_register.
15892 (usr_store_inferior_registers): Likewise. Call collect_register.
15893 Fix recursive case.
15894 (regsets_fetch_inferior_registers): Improve error message.
15895 (regsets_store_inferior_registers): Add debugging.
15896 (linux_look_up_symbols): Call thread_db_init if USE_THREAD_DB.
15897 (unstopped_p, linux_signal_pid): New functions.
15898 (linux_target_ops): Add linux_signal_pid.
15899 (linux_init_signals): New function.
15900 (initialize_low): Call it. Initialize using_threads.
15901 * regcache.c (inferior_regcache_data): Add valid
15902 flag.
15903 (get_regcache): Fetch registers lazily. Add fetch argument
15904 and update all callers.
15905 (regcache_invalidate_one, regcache_invalidate): New
15906 functions.
15907 (new_register_cache): Renamed from create_register_cache.
15908 Return the new regcache.
15909 (free_register_cache): Change argument to a void *.
15910 (registers_to_string, registers_from_string): Call get_regcache
15911 with fetch flag set.
15912 (register_data): Make static. Pass fetch flag to get_regcache.
15913 (supply_register): Call get_regcache with fetch flag clear.
15914 (collect_register): Call get_regcache with fetch flag set.
15915 (collect_register_as_string): New function.
15916 * regcache.h: Update.
15917 * remote-utils.c (putpkt): Flush after debug output and use
15918 stderr.
15919 Handle input interrupts while waiting for an ACK.
15920 (input_interrupt): Use signal_pid method.
15921 (getpkt): Flush after debug output and use stderr.
15922 (outreg): Use collect_register_as_string.
15923 (new_thread_notify, dead_thread_notify): New functions.
15924 (prepare_resume_reply): Check using_threads. Set thread_from_wait
15925 and general_thread.
15926 (look_up_one_symbol): Flush after debug output.
15927 * server.c (step_thread, server_waiting): New variables.
15928 (start_inferior): Don't use signal_pid. Update call to mywait.
15929 (attach_inferior): Update call to mywait.
15930 (handle_query): Handle qfThreadInfo and qsThreadInfo.
15931 (main): Don't fetch/store registers explicitly. Use
15932 set_desired_inferior. Support proposed ``Hs'' packet. Update
15933 calls to mywait.
15934 * server.h: Update.
15935 (struct inferior_list, struct_inferior_list_entry): New.
15936 * target.c (set_desired_inferior): New.
15937 (write_inferior_memory): Constify.
15938 (mywait): New function.
15939 * target.h: Update.
15940 (struct target_ops): New signal_pid method.
15941 (mywait): Removed macro, added prototype.
15942
15943 * linux-low.h (regset_func): Removed.
15944 (regset_fill_func, regset_store_func): New.
15945 (enum regset_type): New.
15946 (struct regset_info): Add type field. Use new operation types.
15947 (struct linux_target_ops): stop_pc renamed to get_pc.
15948 Add decr_pc_after_break and breakpoint_at.
15949 (get_process, get_thread_proess, get_process_thread)
15950 (strut process_info, all_processes, linux_attach_lwp)
15951 (thread_db_init): New.
15952
15953 * linux-arm-low.c (arm_get_pc, arm_set_pc,
15954 arm_breakpoint, arm_breakpoint_len, arm_breakpoint_at): New.
15955 (the_low_target): Add new members.
15956 * linux-i386-low.c (i386_store_gregset, i386_store_fpregset)
15957 (i386_store_fpxregset): Constify.
15958 (target_regsets): Add new kind identifier.
15959 (i386_get_pc): Renamed from i386_stop_pc. Simplify.
15960 (i386_set_pc): Add debugging.
15961 (i386_breakpoint_at): New function.
15962 (the_low_target): Add new members.
15963 * linux-mips-low.c (mips_get_pc, mips_set_pc)
15964 (mips_breakpoint, mips_breakpoint_len, mips_reinsert_addr)
15965 (mips_breakpoint_at): New.
15966 (the_low_target): Add new members.
15967 * linux-ppc-low.c (ppc_get_pc, ppc_set_pc)
15968 (ppc_breakpoint, ppc_breakpoint_len, ppc_breakpoint_at): New.
15969 (the_low_target): Add new members.
15970 * linux-sh-low.c (sh_get_pc, sh_set_pc)
15971 (sh_breakpoint, sh_breakpoint_len, sh_breakpoint_at): New.
15972 (the_low_target): Add new members.
15973 * linux-x86-64-low.c (target_regsets): Add new kind
15974 identifier.
15975
15976 2002-05-15 Daniel Jacobowitz <drow@mvista.com>
15977
15978 From Martin Pool <mbp@samba.org>:
15979 * server.c (gdbserver_usage): New function.
15980 (main): Call it.
15981
15982 2002-05-14 Daniel Jacobowitz <drow@mvista.com>
15983
15984 * mem-break.c (reinsert_breakpoint_by_bp): Correct typo
15985 stop_at -> stop_pc.
15986
15987 2002-05-04 Andrew Cagney <ac131313@redhat.com>
15988
15989 * Makefile.in: Remove obsolete code.
15990
15991 2002-04-24 Michal Ludvig <mludvig@suse.cz>
15992
15993 * linux-low.c (regsets_fetch_inferior_registers),
15994 (regsets_store_inferior_registers): Removed cast to int from
15995 ptrace() calls.
15996 * regcache.h: Added declaration of struct inferior_info.
15997
15998 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
15999
16000 * inferiors.c (struct inferior_info): Add regcache_data.
16001 (add_inferior): Call create_register_cache.
16002 (clear_inferiors): Call free_register_cache.
16003 (inferior_regcache_data, set_inferior_regcache_data): New functions.
16004 * regcache.c (struct inferior_regcache_data): New.
16005 (registers): Remove.
16006 (get_regcache): New function.
16007 (create_register_cache, free_register_cache): New functions.
16008 (set_register_cache): Don't initialize the register cache here.
16009 (registers_to_string, registers_from_string, register_data): Call
16010 get_regcache.
16011 * regcache.h: Add prototypes.
16012 * server.h: Likewise.
16013
16014 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
16015
16016 * mem-break.c: New file.
16017 * mem-break.h: New file.
16018 * Makefile.in: Add mem-break.o rule; update server.h
16019 dependencies.
16020 * inferiors.c (struct inferior_info): Add target_data
16021 member.
16022 (clear_inferiors): Free target_data member if set.
16023 (inferior_target_data, set_inferior_target_data): New functions.
16024 * linux-i386-low.c (i386_breakpoint, i386_breakpoint_len)
16025 (i386_stop_pc, i386_set_pc): New. Add to the_low_target.
16026 * linux-low.c (linux_bp_reinsert): New variable.
16027 (struct inferior_linux_data): New.
16028 (linux_create_inferior): Use set_inferior_target_data.
16029 (linux_attach): Likewise. Call add_inferior.
16030 (linux_wait_for_one_inferior): New function.
16031 (linux_wait): Call it.
16032 (linux_write_memory): Add const.
16033 (initialize_low): Call set_breakpoint_data.
16034 * linux-low.h (struct linux_target_ops): Add breakpoint
16035 handling members.
16036 * server.c (attach_inferior): Remove extra add_inferior
16037 call.
16038 * server.h: Include mem-break.h. Update inferior.c
16039 prototypes.
16040 * target.c (read_inferior_memory)
16041 (write_inferior_memory): New functions.
16042 * target.h (read_inferior_memory)
16043 (write_inferior_memory): Change macros to prototypes.
16044 (struct target_ops): Update comments. Add const to write_memory
16045 definition.
16046
16047 2002-04-11 Daniel Jacobowitz <drow@mvista.com>
16048
16049 * linux-low.c (usr_store_inferior_registers): Support
16050 registers which are allowed to fail to store.
16051 * linux-low.h (linux_target_ops): Likewise.
16052 * linux-ppc-low.c (ppc_regmap): Support FPSCR.
16053 (ppc_cannot_store_register): FPSCR may not be storable.
16054
16055 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
16056
16057 * server.h: Include <string.h> if HAVE_STRING_H.
16058 * ChangeLog: Correct paths in last ChangeLog entry.
16059
16060 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
16061
16062 * linux-low.h: Remove obsolete prototypes.
16063 (struct linux_target_ops): New.
16064 (extern the_low_target): New.
16065 * linux-low.c (num_regs, regmap): Remove declarations.
16066 (register_addr): Use the_low_target explicitly.
16067 (fetch_register): Likewise.
16068 (usr_fetch_inferior_registers): Likewise.
16069 (usr_store_inferior_registers): Likewise.
16070 * linux-arm-low.c (num_regs): Remove.
16071 (arm_num_regs): Define.
16072 (arm_regmap): Renamed from regmap, made static.
16073 (arm_cannot_fetch_register): Renamed from cannot_fetch_register,
16074 made static.
16075 (arm_cannot_store_register): Renamed from cannot_store_register,
16076 made static.
16077 (the_low_target): New.
16078 * linux-i386-low.c (num_regs): Remove.
16079 (i386_num_regs): Define.
16080 (i386_regmap): Renamed from regmap, made static.
16081 (i386_cannot_fetch_register): Renamed from cannot_fetch_register,
16082 made static.
16083 (i386_cannot_store_register): Renamed from cannot_store_register,
16084 made static.
16085 (the_low_target): New.
16086 * linux-ia64-low.c (num_regs): Remove.
16087 (ia64_num_regs): Define.
16088 (ia64_regmap): Renamed from regmap, made static.
16089 (ia64_cannot_fetch_register): Renamed from cannot_fetch_register,
16090 made static.
16091 (ia64_cannot_store_register): Renamed from cannot_store_register,
16092 made static.
16093 (the_low_target): New.
16094 * linux-m68k-low.c (num_regs): Remove.
16095 (m68k_num_regs): Define.
16096 (m68k_regmap): Renamed from regmap, made static.
16097 (m68k_cannot_fetch_register): Renamed from cannot_fetch_register,
16098 made static.
16099 (m68k_cannot_store_register): Renamed from cannot_store_register,
16100 made static.
16101 (the_low_target): New.
16102 * linux-mips-low.c (num_regs): Remove.
16103 (mips_num_regs): Define.
16104 (mips_regmap): Renamed from regmap, made static.
16105 (mips_cannot_fetch_register): Renamed from cannot_fetch_register,
16106 made static.
16107 (mips_cannot_store_register): Renamed from cannot_store_register,
16108 made static.
16109 (the_low_target): New.
16110 * linux-ppc-low.c (num_regs): Remove.
16111 (ppc_num_regs): Define.
16112 (ppc_regmap): Renamed from regmap, made static.
16113 (ppc_cannot_fetch_register): Renamed from cannot_fetch_register,
16114 made static.
16115 (ppc_cannot_store_register): Renamed from cannot_store_register,
16116 made static.
16117 (the_low_target): New.
16118 * linux-s390-low.c (num_regs): Remove.
16119 (s390_num_regs): Define.
16120 (s390_regmap): Renamed from regmap, made static.
16121 (s390_cannot_fetch_register): Renamed from cannot_fetch_register,
16122 made static.
16123 (s390_cannot_store_register): Renamed from cannot_store_register,
16124 made static.
16125 (the_low_target): New.
16126 * linux-sh-low.c (num_regs): Remove.
16127 (sh_num_regs): Define.
16128 (sh_regmap): Renamed from regmap, made static.
16129 (sh_cannot_fetch_register): Renamed from cannot_fetch_register,
16130 made static.
16131 (sh_cannot_store_register): Renamed from cannot_store_register,
16132 made static.
16133 (the_low_target): New.
16134 * linux-x86-64-low.c (x86_64_regmap): Renamed from regmap.
16135 (the_low_target): New.
16136
16137 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
16138
16139 * Makefile.in: Add stamp-h target.
16140 * configure.in: Create stamp-h.
16141 * configure: Regenerated.
16142
16143 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
16144
16145 * inferiors.c: New file.
16146 * target.c: New file.
16147 * target.h: New file.
16148 * Makefile.in: Add target.o and inferiors.o. Update
16149 dependencies.
16150 * linux-low.c (inferior_pid): New static variable,
16151 moved from server.c.
16152 (linux_create_inferior): Renamed from create_inferior.
16153 Call add_inferior. Return 0 on success instead of a PID.
16154 (linux_attach): Renamed from myattach.
16155 (linux_kill): Renamed from kill_inferior. Call clear_inferiors ().
16156 (linux_thread_alive): Renamed from mythread_alive.
16157 (linux_wait): Renamed from mywait. Call clear_inferiors () if the
16158 child dies.
16159 (linux_resume): Renamed from myresume. Add missing ``return 0''.
16160 (regsets_store_inferior_registers): Correct error message.
16161 Add missing ``return 0''.
16162 (linux_fetch_registers): Renamed from fetch_inferior_registers.
16163 (linux_store_registers): Renamed from store_inferior_registers.
16164 (linux_read_memory): Renamed from read_inferior_memory.
16165 (linux_write_memory): Renamed from write_inferior_memory.
16166 (linux_target_ops): New structure.
16167 (initialize_low): Call set_target_ops ().
16168 * remote-utils.c (unhexify): New function.
16169 (hexify): New function.
16170 (input_interrupt): Send signals to ``signal_pid''.
16171 * server.c (inferior_pid): Remove.
16172 (start_inferior): Update create_inferior call.
16173 (attach_inferior): Call add_inferior.
16174 (handle_query): New function.
16175 (main): Call handle_query for `q' packets.
16176 * server.h: Include "target.h". Remove obsolete prototypes.
16177 Add prototypes for "inferiors.c", "target.c", hexify, and unhexify.
16178
16179 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
16180
16181 * Makefile.in: Add WARN_CFLAGS. Update configury
16182 dependencies.
16183 * configure.in: Check for <string.h>
16184 * configure: Regenerate.
16185 * config.in: Regenerate.
16186 * gdbreplay.c: Include needed system headers.
16187 (remote_open): Remove strchr prototype.
16188 * linux-low.h: Correct #ifdef to HAVE_LINUX_USRREGS.
16189 * regcache.c (supply_register): Change buf argument to const void *.
16190 (supply_register_by_name): Likewise.
16191 (collect_register): Change buf argument to void *.
16192 (collect_register_by_name): Likewise.
16193 * regcache.h: Add missing prototypes.
16194 * remote-utils.c: Include <arpa/inet.h> for inet_ntoa.
16195 * server.c (handle_query): New function.
16196 (attached): New static variable, moved out of main.
16197 (main): Quiet longjmp clobber warnings.
16198 * server.h: Add ATTR_NORETURN and ATTR_FORMAT. Update prototypes.
16199 * utils.c (error): Remove NORETURN.
16200 (fatal): Likewise.
This page took 0.389715 seconds and 4 git commands to generate.