Add NetBSD/i386 gdbserver support
[deliverable/binutils-gdb.git] / gdbserver / ChangeLog
1 2020-10-01 Kamil Rytarowski <n54@gmx.com>
2
3 * netbsd-i386-low.cc: Add.
4 * Makefile.in (SFILES): Register "netbsd-i386-low.c".
5 * configure.srv: Add i[34567]86-*-netbsd*.
6
7 2020-10-01 Kamil Rytarowski <n54@gmx.com>
8
9 * netbsd-amd64-low.cc (netbsd_x86_64_arch_setup): Remove.
10 (netbsd_target_regsets): Now const.
11 (the_low_target): Remove.
12 (class netbsd_amd64_target, the_netbsd_amd64_target)
13 (the_netbsd_target): Add.
14 * netbsd-low.cc (netbsd_process_target::post_create_inferior): Call
15 low_arch_setup ().
16 (netbsd_process_target::fetch_registers)
17 (netbsd_process_target::store_registers, initialize_low): Update.
18 (the_netbsd_target): Remove.
19 * netbsd-low.h (netbsd_target_regsets, netbsd_target_ops)
20 (the_low_target, netbsd_tdesc): Remove.
21 (netbsd_process_target::get_regs_info)
22 (netbsd_process_target::low_arch_setup): Add.
23
24 2020-09-23 Hannes Domani <ssbssa@yahoo.de>
25
26 * win32-low.cc: Remove local wow64_process variable.
27 * win32-low.h: Remove local wow64_process variable.
28
29 2020-09-18 Tom Tromey <tromey@adacore.com>
30
31 * netbsd-low.h (class netbsd_process_target) <wait>: Update.
32 * netbsd-low.cc (netbsd_waitpid, netbsd_wait)
33 (netbsd_process_target::wait): Change type of target_options.
34 * win32-low.h (class win32_process_target) <wait>: Update.
35 * win32-low.cc (win32_process_target::wait): Update.
36 * target.h (class process_stratum_target) <wait>: Update.
37 (mywait): Update.
38 * target.cc (mywait, target_wait): Change type of "options".
39 * linux-low.h (class linux_process_target) <wait, wait_1>:
40 Update.
41 * linux-low.cc (linux_process_target::wait)
42 (linux_process_target::wait_1): Update.
43
44 2020-09-15 Tom Tromey <tromey@adacore.com>
45
46 * linux-x86-low.cc (xmltarget_i386_linux_no_xml)
47 (xmltarget_amd64_linux_no_xml): Now arrays.
48
49 2020-09-14 Tom Tromey <tromey@adacore.com>
50
51 * tracepoint.cc (eval_result_names): Now const.
52 * ax.cc (gdb_agent_op_names): Now const.
53
54 2020-09-10 Kamil Rytarowski <n54@gmx.com>
55
56 * netbsd-low.cc: Add.
57 * netbsd-low.h: Likewise.
58 * netbsd-amd64-low.cc: Likewise.
59 * Makefile.in (SFILES): Register "netbsd-low.cc", "netbsd-low.h",
60 "netbsd-amd64-low.cc".
61 * configure.srv: Add x86_64-*-netbsd*.
62
63 2020-08-13 Simon Marchi <simon.marchi@polymtl.ca>
64
65 * server.cc (captured_main): Accept multiple `--selftest=`
66 options. Pass all `--selftest=` arguments to run_tests.
67
68 2020-07-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
69
70 * configure, config.in: Regenerate.
71
72 2020-07-26 Eli Zaretskii <eliz@gnu.org>
73
74 * configure.ac (AC_CHECK_HEADERS): Add ws2tcpip.h.
75 When checking whether socklen_t type is defined, use ws2tcpip.h if
76 it is available and sys/socket.h isn't.
77 * configure: Regenerate.
78 * config.in: Regenerate.
79
80 2020-07-22 Pedro Alves <pedro@palves.net>
81
82 * inferiors.cc (switch_to_process): New, moved here from
83 thread-db.cc, and made extern.
84 * inferiors.h (switch_to_process): Declare.
85 * server.cc: Include "gdbsupport/scoped_restore.h".
86 (handle_qxfer_threads_proper): Now returns bool. Prepare to
87 access memory around target calls.
88 (handle_qxfer_threads): Handle errors.
89 * thread-db.cc (switch_to_process): Moved to inferiors.cc.
90
91 2020-07-21 Simon Marchi <simon.marchi@efficios.com>
92
93 * linux-low.cc (stopped_pids): Make static.
94
95 2020-07-17 Andrew Burgess <andrew.burgess@embecosm.com>
96
97 * tdesc.cc (allocate_target_description): Add header comment.
98 (target_desc_deleter::operator()): New function.
99 * tdesc.h (struct target_desc): Declare as final.
100
101 2020-07-13 Simon Marchi <simon.marchi@polymtl.ca>
102
103 * server.cc (handle_query): Use std::vector of
104 std::string for `qsupported` vector. Use separate
105 vector for unknowns.
106 * target.h (class process_stratum_target) <process_qsupported>:
107 Change parameters to array_view of const char *.
108 (target_process_qsupported): Remove `count` parameter.
109 * target.cc (process_stratum_target::process_qsupported): Change
110 parameters to array_view of const char *.
111 * linux-x86-low.cc (class x86_target) <process_qsupported>:
112 Likewise.
113
114 2020-06-29 Tom de Vries <tdevries@suse.de>
115
116 * ax.h: Include gdbsupport/debug_agent.h.
117
118 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
119
120 * tdesc.cc (struct tdesc_compatible_info): New struct.
121 (tdesc_compatible_info_list): New function.
122 (tdesc_compatible_info_arch_name): New function.
123
124 2020-06-22 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
125
126 Use std::list to stop pending signal instead of manually-created
127 linked list.
128 * linux-low.h: Include <list>.
129 (struct pending_signal): Move here from linux-low.cc.
130 (struct lwp_info) <pending_signals>
131 <pending_signals_to_report>: Update the type.
132 * linux-low.cc (struct pending_signals): Remove.
133 (linux_process_target::delete_lwp)
134 (linux_process_target::add_lwp)
135 (enqueue_one_deferred_signal)
136 (dequeue_one_deferred_signal)
137 (enqueue_pending_signal)
138 (linux_process_target::resume_one_lwp_throw)
139 (linux_process_target::thread_needs_step_over)
140 (linux_process_target::resume_one_thread)
141 (linux_process_target::proceed_one_lwp): Update the use of pending
142 signal list.
143
144 2020-06-17 Simon Marchi <simon.marchi@efficios.com>
145
146 * Makefile.in (%-generated.cc: ../gdb/regformats/arm/%.dat):
147 Remove.
148
149 2020-06-12 Simon Marchi <simon.marchi@efficios.com>
150
151 * Makefile.in (SFILES): Remove win32-arm-low.cc, wincecompat.cc.
152 * configure.srv: Remove mingw32ce cases.
153 * server.h, win32-low.cc: Remove __MINGW32CE__-guarded code.
154 * win32-low.h (to_back_slashes): Remove.
155 * win32-arm-low.cc, wincecompat.cc, wincecompat.h: Remove.
156
157 2020-06-12 Simon Marchi <simon.marchi@efficios.com>
158
159 * Makefile.in (SFILES): linux-tile-low.cc.
160 * configure.srv: Remove tilegx case.
161 * linux-tile-low.cc: Remove.
162
163 2020-06-12 Simon Marchi <simon.marchi@efficios.com>
164
165 * Makefile.in (SFILES): Remove linux-m32r-low.cc.
166 * configure.srv: Remove m32r case.
167 * linux-m32r-low.cc: Remove.
168
169 2020-06-12 Simon Marchi <simon.marchi@efficios.com>
170
171 * Makefile.in (SFILES): Remove linux-cris-low.c.
172 * configure.srv: Remove cris cases.
173 * linux-cris-low.cc, linux-crisv32-low.cc: Remove.
174
175 2020-06-12 Simon Marchi <simon.marchi@efficios.com>
176
177 * Makefile.in (SFILES): Remove linux-bfin-low.c.
178 * configure.srv: Remove bfin case.
179 * linux-bfin-low.cc: Remove.
180 * linux-low.cc: Remove BFIN-conditional code.
181
182 2020-06-12 Simon Marchi <simon.marchi@efficios.com>
183
184 * configure: Re-generate.
185 * configure.ac: Remove srv_qnx test.
186 * configure.srv: Remove nto case.
187 * nto-low.cc, nto-low.h, nto-x86-low.cc: Remove.
188 * remote-utils.c: Remove __QNX__-guarded code.
189
190 2020-06-12 Simon Marchi <simon.marchi@efficios.com>
191
192 * configure: Re-generate.
193 * configure.ac: Remove srv_lynxos test.
194 * configure.srv: Remove lynxos cases.
195 * lynx-i386-low.cc, lynx-low.cc, lynx-low.h, lynx-ppc-low.c:
196 Remove.
197
198 2020-06-12 Simon Marchi <simon.marchi@efficios.com>
199
200 * README: Fix a few outdated or incoherent things.
201
202 2020-05-27 Hannes Domani <ssbssa@yahoo.de>
203
204 * win32-low.cc (do_initial_child_stuff): Set open_process_used.
205 (win32_clear_inferiors): Use open_process_used.
206 (get_child_debug_event): Likewise.
207
208 2020-05-25 Michael Weghorn <m.weghorn@posteo.de>
209
210 PR gdbserver/25893
211 * linux-low.cc (linux_process_target::create_inferior),
212 lynx-low.cc (lynx_process_target::create_inferior),
213 win32-low.cc (win32_process_target::create_inferior): Use
214 construct_inferior_arguments instead of stringify_argv
215 to get string representation which properly escapes
216 special characters.
217 * server.cc (handle_v_run): Just pass empty program arg
218 as such, since any further processing is now handled via
219 construct_inferior_arguments.
220
221 2020-05-25 Michael Weghorn <m.weghorn@posteo.de>
222
223 * nto-low.cc (nto_process_target::create_inferior): Pass
224 argv to spawnp function as char **.
225
226 2020-05-25 Michael Weghorn <m.weghorn@posteo.de>
227
228 * server.cc (captured_main), (handle_v_run): No longer
229 insert extra NULL element to args vector.
230
231 2020-05-23 Pedro Alves <palves@redhat.com>
232
233 * gdb-safe-ctype.h: New.
234
235 2020-05-16 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
236
237 * linux-ia64-low.cc (ia64_target::sw_breakpoint_from_kind):
238 Fix incorrect 'gdb_assert_no_reached' to 'gdb_assert_not_reached'.
239 (ia64_target::low_breakpoint_at): Ditto.
240
241 2020-05-15 Hannes Domani <ssbssa@yahoo.de>
242
243 * win32-i386-low.cc (i386_supports_z_point_type): Handle
244 Z_PACKET_HW_BP z_type.
245 (i386_insert_point): Handle raw_bkpt_type type.
246 (i386_remove_point): Likewise.
247
248 2020-04-30 Hannes Domani <ssbssa@yahoo.de>
249
250 * configure.srv <x86_64-*-mingw*, x86_64-*-cygwin*> (srv_tgtobj):
251 Add arch/i386.o.
252 * win32-arm-low.cc (arm_num_regs): New function.
253 (struct win32_target_ops): Use arm_num_regs.
254 * win32-i386-low.cc (win32_get_current_dr): Adapt for WOW64
255 processes.
256 (i386_get_thread_context): Likewise.
257 (i386_prepare_to_resume): Likewise.
258 (i386_thread_added): Likewise.
259 (i386_single_step): Likewise.
260 (i386_fetch_inferior_register): Likewise.
261 (i386_store_inferior_register): Likewise.
262 (i386_arch_setup): Likewise.
263 (i386_win32_num_regs): New function.
264 (struct win32_target_ops): Use i386_win32_num_regs.
265 * win32-low.cc (win32_get_thread_context): Adapt for WOW64
266 processes.
267 (win32_require_context): Likewise.
268 (child_add_thread): Likewise.
269 (do_initial_child_stuff): Likewise.
270 (continue_one_thread): Likewise.
271 (win32_process_target::resume): Likewise.
272 (load_psapi): Likewise.
273 (win32_add_all_dlls): Likewise.
274 (maybe_adjust_pc): Likewise.
275 (win32_process_target::qxfer_siginfo): Likewise.
276 (initialize_low): Likewise.
277 * win32-low.h (struct win32_target_ops): Change num_regs to
278 callback function.
279
280 2020-04-27 Simon Marchi <simon.marchi@efficios.com>
281
282 * configure.ac: Remove check for fs_base/gs_base in
283 user_regs_struct.
284 * configure: Re-generate.
285 * config.in: Re-generate.
286 * linux-x86-low.cc (x86_64_regmap, x86_fill_gregset,
287 x86_store_gregset): Adjust.
288
289 2020-04-22 Hannes Domani <ssbssa@yahoo.de>
290
291 * server.cc (handle_search_memory_1): Fix gdb_read_memory return value
292 comparison.
293
294 2020-04-16 Tom Tromey <tromey@adacore.com>
295
296 * win32-low.cc (windows_nat::handle_access_violation): New
297 function.
298
299 2020-04-15 Simon Marchi <simon.marchi@polymtl.ca>
300
301 * win32-low.cc (get_child_debug_event): Fix format string warning.
302
303 2020-04-13 Tom Tromey <tom@tromey.com>
304
305 * server.h (gdb_fildes_t): Remove typedef.
306 * remote-utils.c (remote_desc, list_desc): Now int.
307 (INVALID_DESCRIPTOR): Remove.
308 (gdb_connected, remote_close)
309 (check_remote_input_interrupt_request): Update.
310 * utils.h (pfildes): Don't declare.
311 * utils.c (pfildes): Remove.
312
313 2020-04-13 Tom Tromey <tom@tromey.com>
314
315 * server.h (handle_serial_event, handle_target_event): Update.
316 * server.c: Don't call initialize_event_loop.
317 (keep_processing_events): New global.
318 (handle_serial_event): Return void. Set keep_processing_events.
319 (handle_target_event): Return void.
320 (start_event_loop): Move from event-loop.c. Rewrite.
321 * remote-utils.c (handle_accept_event): Return void.
322 (reset_readchar): Use delete_timer.
323 (process_remaining): Return void.
324 (reschedule): Use create_timer.
325 * event-loop.h: Remove.
326 * event-loop.cc: Remove.
327 * Makefile.in (OBS): Use gdbsupport/event-loop.o, not event-loop.o.
328
329 2020-04-13 Tom Tromey <tom@tromey.com>
330
331 * server.c (invoke_async_signal_handlers)
332 (check_async_event_handlers, flush_streams, gdb_select): New
333 functions.
334
335 2020-04-13 Tom Tromey <tom@tromey.com>
336
337 * configure: Rebuild.
338 * config.in: Rebuild.
339
340 2020-04-08 Tom Tromey <tromey@adacore.com>
341
342 PR gdb/22992
343 * win32-low.c (child_continue): Call matching_pending_stop.
344 (get_child_debug_event): Call fetch_pending_stop. Push pending
345 stop when needed.
346
347 2020-04-08 Tom Tromey <tromey@adacore.com>
348
349 * win32-low.h (win32_process_target::stopped_by_sw_breakpoint)
350 (win32_process_target::supports_stopped_by_sw_breakpoint):
351 Declare.
352 * win32-low.c (win32_supports_z_point_type): Always handle
353 Z_PACKET_SW_BP.
354 (win32_insert_point): Call insert_memory_breakpoint when needed.
355 (win32_remove_point): Call remove_memory_breakpoint when needed.
356 (win32_process_target::stopped_by_sw_breakpoint)
357 (win32_process_target::supports_stopped_by_sw_breakpoint): New
358 methods.
359 (win32_target_ops): Update.
360 (maybe_adjust_pc): New function.
361 (win32_wait): Call maybe_adjust_pc.
362
363 2020-04-08 Tom Tromey <tromey@adacore.com>
364
365 * win32-low.h (struct win32_target_ops) <decr_pc_after_break>: New
366 field.
367 * win32-i386-low.c (the_low_target): Update.
368 * win32-arm-low.c (the_low_target): Update.
369
370 2020-04-08 Tom Tromey <tromey@adacore.com>
371
372 * win32-low.h (win32_process_target::read_pc)
373 (win32_process_target::write_pc): Declare.
374 * win32-low.c (win32_process_target::read_pc)
375 (win32_process_target::write_pc): New methods.
376 * win32-i386-low.c (i386_win32_get_pc, i386_win32_set_pc): New
377 functions.
378 (the_low_target): Update.
379 * win32-arm-low.c (arm_win32_get_pc, arm_win32_set_pc): New
380 functions.
381 (the_low_target): Update.
382
383 2020-04-08 Tom Tromey <tromey@adacore.com>
384
385 * win32-low.c (win32_kill, get_child_debug_event): Use
386 wait_for_debug_event.
387
388 2020-04-08 Tom Tromey <tromey@adacore.com>
389
390 * win32-low.c (child_continue): Call continue_last_debug_event.
391
392 2020-04-08 Tom Tromey <tromey@adacore.com>
393
394 * win32-low.c (handle_exception): Remove.
395 (windows_nat::handle_ms_vc_exception): New function.
396 (get_child_debug_event): Add "continue_status" parameter.
397 Update.
398 (win32_wait): Update.
399
400 2020-04-08 Tom Tromey <tromey@adacore.com>
401
402 * win32-low.c (windows_nat::handle_load_dll): Rename from
403 handle_load_dll. No longer static.
404 (windows_nat::handle_unload_dll): Rename from handle_unload_dll.
405 No longer static.
406
407 2020-04-08 Tom Tromey <tromey@adacore.com>
408
409 * win32-low.c (handle_output_debug_string): Add parameter. Change
410 return type.
411 (win32_kill, get_child_debug_event): Update.
412
413 2020-04-08 Tom Tromey <tromey@adacore.com>
414
415 * win32-low.c (current_process_handle, current_process_id)
416 (main_thread_id, last_sig, current_event, siginfo_er): Move to
417 nat/windows-nat.c.
418
419 2020-04-08 Tom Tromey <tromey@adacore.com>
420
421 * win32-low.c (get_image_name): Remove.
422 (handle_load_dll): Update.
423
424 2020-04-08 Tom Tromey <tromey@adacore.com>
425
426 * win32-low.c (windows_nat::thread_rec): Rename from thread_rec.
427 No longer static. Change parameters.
428 (child_add_thread, child_fetch_inferior_registers)
429 (child_store_inferior_registers, win32_resume)
430 (win32_get_tib_address): Update.
431
432 2020-04-08 Tom Tromey <tromey@adacore.com>
433
434 * win32-low.h (struct win32_target_ops): Use qualified names where
435 needed.
436 * win32-i386-low.c: Add "using namespace".
437 * win32-low.c: Add "using namespace".
438 * win32-arm-low.c: Add "using namespace".
439
440 2020-04-08 Tom Tromey <tromey@adacore.com>
441
442 * win32-low.c (delete_thread_info): Don't call CloseHandle.
443
444 2020-04-08 Tom Tromey <tromey@adacore.com>
445
446 * win32-low.c (win32_require_context, suspend_one_thread): Use
447 windows_thread_info::suspend.
448 (continue_one_thread): Use windows_thread_info::resume.
449 * configure.srv (srv_tgtobj): Add windows-nat.o when needed.
450
451 2020-04-08 Tom Tromey <tromey@adacore.com>
452
453 * win32-i386-low.c (update_debug_registers)
454 (i386_prepare_to_resume, i386_thread_added): Update.
455
456 2020-04-08 Tom Tromey <tromey@adacore.com>
457
458 * win32-low.c (child_add_thread): Use new.
459 (delete_thread_info): Use delete.
460
461 2020-04-08 Tom Tromey <tromey@adacore.com>
462
463 * win32-low.h (struct windows_thread_info): Remove.
464
465 2020-04-08 Tom Tromey <tromey@adacore.com>
466
467 * win32-low.h (struct windows_thread_info): Rename from
468 win32_thread_info. Remove typedef.
469 (struct win32_target_ops, win32_require_context): Update.
470 * win32-low.c (win32_get_thread_context)
471 (win32_set_thread_context, win32_prepare_to_resume)
472 (win32_require_context, thread_rec, child_add_thread)
473 (delete_thread_info, continue_one_thread)
474 (child_fetch_inferior_registers, child_store_inferior_registers)
475 (win32_resume, suspend_one_thread, win32_get_tib_address):
476 Update.
477 * win32-i386-low.c (update_debug_registers)
478 (win32_get_current_dr, i386_get_thread_context)
479 (i386_prepare_to_resume, i386_thread_added, i386_single_step)
480 (i386_fetch_inferior_register, i386_store_inferior_register):
481 Update.
482 * win32-arm-low.c (arm_get_thread_context)
483 (arm_fetch_inferior_register, arm_store_inferior_register):
484 Update.
485
486 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
487
488 * linux-low.h (struct linux_target_ops): Remove.
489 (the_low_target): Remove.
490 * linux-x86-low.cc (the_low_target): Remove.
491 * linux-aarch64-low.cc (the_low_target): Ditto.
492 * linux-arm-low.cc (the_low_target): Ditto.
493 * linux-bfin-low.cc (the_low_target): Ditto.
494 * linux-cris-low.cc (the_low_target): Ditto.
495 * linux-crisv32-low.cc (the_low_target): Ditto.
496 * linux-ia64-low.cc (the_low_target): Ditto.
497 * linux-m32r-low.cc (the_low_target): Ditto.
498 * linux-m68k-low.cc (the_low_target): Ditto.
499 * linux-mips-low.cc (the_low_target): Ditto.
500 * linux-nios2-low.cc (the_low_target): Ditto.
501 * linux-ppc-low.cc (the_low_target): Ditto.
502 * linux-riscv-low.cc (the_low_target): Ditto.
503 * linux-s390-low.cc (the_low_target): Ditto.
504 * linux-sh-low.cc (the_low_target): Ditto.
505 * linux-sparc-low.cc (the_low_target): Ditto.
506 * linux-tic6x-low.cc (the_low_target): Ditto.
507 * linux-tile-low.cc (the_low_target): Ditto.
508 * linux-xtensa-low.cc (the_low_target): Ditto.
509
510 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
511
512 Remove the 'get_ipa_tdesc_idx' linux target op and let a concrete
513 linux target define the op by overriding the declaration in
514 process_stratum_target.
515
516 * linux-low.h (struct linux_target_ops): Remove the op.
517 (class linux_process_target) <get_ipa_tdesc_idx>: Remove.
518 * linux-low.cc (linux_process_target::get_ipa_tdesc_idx): Remove.
519 * linux-x86-low.cc (class x86_target) <get_ipa_tdesc_idx>: Declare.
520 (x86_get_ipa_tdesc_idx): Turn into...
521 (x86_target::get_ipa_tdesc_idx): ...this.
522 (the_low_target): Remove the op field.
523 * linux-ppc-low.cc (class ppc_target) <get_ipa_tdesc_idx>: Declare.
524 (ppc_get_ipa_tdesc_idx): Turn into...
525 (ppc_target::get_ipa_tdesc_idx): ...this.
526 (the_low_target): Remove the op field.
527 * linux-s390-low.cc (class s390_target) <get_ipa_tdesc_idx>: Declare.
528 (s390_get_ipa_tdesc_idx): Turn into...
529 (s390_target::get_ipa_tdesc_idx): ...this.
530 (the_low_target): Remove the op field.
531
532 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
533
534 Turn the 'get_syscall_trapinfo' linux target op into a method
535 of process_stratum_target.
536
537 * linux-low.h (struct linux_target_ops): Remove the op.
538 (class linux_process_target) <get_syscall_trapinfo>
539 <gdb_catch_this_syscall>
540 <low_supports_catch_syscall>
541 <low_get_syscall_trapinfo>: Declare.
542 * linux-low.cc (get_syscall_trapinfo): Turn into...
543 (linux_process_target::get_syscall_trapinfo): ...this.
544 (linux_process_target::low_get_syscall_trapinfo): Define.
545 (gdb_catch_this_syscall_p): Turn into...
546 (linux_process_target::gdb_catch_this_syscall): ...this.
547 (linux_process_target::low_supports_catch_syscall): Define.
548
549 Update the callers below.
550
551 (linux_process_target::wait_1)
552 (linux_process_target::supports_catch_syscall)
553
554 * linux-x86-low.cc (class x86_target) <low_supports_catch_syscall>
555 <low_get_syscall_trapinfo>: Declare.
556 (x86_target::low_supports_catch_syscall): Define.
557 (x86_get_syscall_trapinfo): Turn into...
558 (x86_target::low_get_syscall_trapinfo): ...this.
559 (the_low_target): Remove the op field.
560 * linux-aarch64-low.cc (class aarch64_target)
561 <low_supports_catch_syscall>
562 <low_get_syscall_trapinfo>: Declare.
563 (aarch64_target::low_supports_catch_syscall): Define.
564 (aarch64_get_syscall_trapinfo): Turn into...
565 (aarch64_target::low_get_syscall_trapinfo): ...this.
566 (the_low_target): Remove the op field.
567 * linux-arm-low.cc (class arm_target) <low_supports_catch_syscall>
568 <low_get_syscall_trapinfo>: Declare.
569 (arm_target::low_supports_catch_syscall): Define.
570 (arm_get_syscall_trapinfo): Turn into...
571 (arm_target::low_get_syscall_trapinfo): ...this.
572 (the_low_target): Remove the op field.
573 * linux-ppc-low.cc (the_low_target): Remove the op field.
574 * linux-s390-low.cc (the_low_target): Remove the op field.
575
576 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
577
578 Remove the 'supports_hardware_single_step' linux target op and
579 override the process_stratum_target's op definition in
580 linux_process_target to return true.
581
582 * linux-low.h (struct linux_target_ops): Remove the op.
583 (class linux_process_target) <finish_step_over>
584 <maybe_hw_step>: Declare.
585 * linux-low.cc (can_hardware_single_step): Remove.
586 (maybe_hw_step): Turn into...
587 (linux_process_target::maybe_hw_step): ...this.
588 (finish_step_over): Turn into...
589 (linux_process_target::finish_step_over): ...this.
590 (linux_process_target::supports_hardware_single_step): Update
591 to return true.
592
593 Update the callers below.
594
595 (linux_process_target::single_step)
596 (linux_process_target::resume_one_lwp_throw)
597
598 * linux-arm-low.cc (class arm_target)
599 <supports_hardware_single_step>: Declare.
600 (arm_supports_hardware_single_step): Turn into...
601 (arm_target::supports_hardware_single_step): ...this.
602 (the_low_target): Remove the op field.
603 * linux-x86-low.cc (x86_supports_hardware_single_step): Remove.
604 (the_low_target): Remove the op field.
605 * linux-aarch64-low.cc (aarch64_supports_hardware_single_step):
606 Remove.
607 (the_low_target): Remove the op field.
608 * linux-bfin-low.cc (bfin_supports_hardware_single_step): Remove.
609 (the_low_target): Remove the op field.
610 * linux-crisv32-low.cc (cris_supports_hardware_single_step): Remove.
611 (the_low_target): Remove the op field.
612 * linux-m32r-low.cc (m32r_supports_hardware_single_step): Remove.
613 (the_low_target): Remove the op field.
614 * linux-m68k-low.cc (m68k_supports_hardware_single_step): Remove.
615 (the_low_target): Remove the op field.
616 * linux-ppc-low.cc (ppc_supports_hardware_single_step): Remove.
617 (the_low_target): Remove the op field.
618 * linux-s390-low.cc (s390_supports_hardware_single_step): Remove.
619 (the_low_target): Remove the op field.
620 * linux-sh-low.cc (sh_supports_hardware_single_step): Remove.
621 (the_low_target): Remove the op field.
622 * linux-tic6x-low.cc (tic6x_supports_hardware_single_step): Remove.
623 (the_low_target): Remove the op field.
624 * linux-tile-low.cc (tile_supports_hardware_single_step): Remove.
625 (the_low_target): Remove the op field.
626 * linux-xtensa-low.cc (xtensa_supports_hardware_single_step):
627 Remove.
628 (the_low_target): Remove the op field.
629
630 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
631
632 Turn the 'supports_range_stepping' linux target op into a method
633 of linux_process_target.
634
635 * linux-low.h (struct linux_target_ops): Remove the op.
636 (class linux_process_target) <low_supports_range_stepping>: Declare.
637 * linux-low.cc (linux_process_target::low_supports_range_stepping):
638 Define.
639 (linux_process_target::supports_range_stepping): Update the call
640 site.
641 * linux-x86-low.cc (class x86_target)
642 <low_supports_range_stepping>: Declare.
643 (x86_supports_range_stepping): Turn into...
644 (x86_target::low_supports_range_stepping): ...this.
645 (the_low_target): Remove the op field.
646 * linux-aarch64-low.cc (class aarch64_target)
647 <low_supports_range_stepping>: Declare.
648 (aarch64_supports_range_stepping): Turn into...
649 (aarch64_target::low_supports_range_stepping): ...this.
650 (the_low_target): Remove the op field.
651 * linux-arm-low.cc (the_low_target): Remove the op field.
652 * linux-bfin-low.cc (the_low_target): Ditto.
653 * linux-crisv32-low.cc (the_low_target): Ditto.
654 * linux-m32r-low.cc (the_low_target): Ditto.
655 * linux-m68k-low.cc (the_low_target): Ditto.
656 * linux-ppc-low.cc (the_low_target): Ditto.
657 * linux-s390-low.cc (the_low_target): Ditto.
658 * linux-sh-low.cc (the_low_target): Ditto.
659 * linux-tic6x-low.cc (the_low_target): Ditto.
660 * linux-tile-low.cc (the_low_target): Ditto.
661 * linux-xtensa-low.cc (the_low_target): Ditto.
662
663 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
664
665 Remove the 'emit_ops' linux target ops and let the concrete
666 linux target define the op by overriding the declaration of
667 process_stratum_target.
668
669 * linux-low.h (struct linux_target_ops): Remove the op.
670 (class linux_process_target) <emit_ops>: Remove.
671 * linux-low.cc (linux_process_target::emit_ops): Remove.
672 * linux-x86-low.cc (class x86_target) <emit_ops>: Declare.
673 (x86_emit_ops): Turn into...
674 (x86_target::emit_ops): ...this.
675 (the_low_target): Remove the op field.
676 * linux-aarch64-low.cc (class aarch64_target) <emit_ops>: Declare.
677 (aarch64_emit_ops): Turn into...
678 (aarch64_target::emit_ops): ...this.
679 (the_low_target): Remove the op field.
680 * linux-ppc-low.cc (class ppc_target) <emit_ops>: Declare.
681 (ppc_emit_ops): Turn into...
682 (ppc_target::emit_ops): ...this.
683 (the_low_target): Remove the op field.
684 * linux-s390-low.cc (class s390_target) <emit_ops>: Declare.
685 (s390_emit_ops): Turn into...
686 (s390_target::emit_ops): ...this.
687 (the_low_target): Remove the op field.
688 * linux-arm-low.cc (the_low_target): Remove the op field.
689 * linux-bfin-low.cc (the_low_target): Ditto.
690 * linux-crisv32-low.cc (the_low_target): Ditto.
691 * linux-m32r-low.cc (the_low_target): Ditto.
692 * linux-m68k-low.cc (the_low_target): Ditto.
693 * linux-sh-low.cc (the_low_target): Ditto.
694 * linux-tic6x-low.cc (the_low_target): Ditto.
695 * linux-tile-low.cc (the_low_target): Ditto.
696 * linux-xtensa-low.cc (the_low_target): Ditto.
697
698 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
699
700 Remove the 'install_fast_tracepoint_jump_pad' and
701 'get_min_fast_tracepoint_insn_len' linux target ops to let the
702 concrete linux target define the ops by overriding the declarations
703 of process_stratum_target.
704
705 * linux-low.h (struct linux_target_ops): Remove the ops.
706 (class linux_process_target) <supports_fast_tracepoints>
707 <install_fast_tracepoint_jump_pad>
708 <get_min_fast_tracepoint_insn_len>: Remove.
709 * linux-low.cc (linux_process_target::supports_fast_tracepoints)
710 (linux_process_target::install_fast_tracepoint_jump_pad)
711 (linux_process_target::get_min_fast_tracepoint_insn_len): Remove.
712 * linux-x86-low.cc (class x86_target) <supports_fast_tracepoints>
713 <install_fast_tracepoint_jump_pad>
714 <get_min_fast_tracepoint_insn_len>: Declare.
715 (x86_target::supports_fast_tracepoints): Define.
716 (x86_install_fast_tracepoint_jump_pad): Turn into...
717 (x86_target::install_fast_tracepoint_jump_pad): ...this.
718 (x86_get_min_fast_tracepoint_insn_len): Turn into...
719 (x86_target::get_min_fast_tracepoint_insn_len): ...this.
720 (the_low_target): Remove the op fields.
721 * linux-aarch64-low.cc (class aarch64_target)
722 <supports_fast_tracepoints>
723 <install_fast_tracepoint_jump_pad>
724 <get_min_fast_tracepoint_insn_len>: Declare.
725 (aarch64_target::supports_fast_tracepoints): Define.
726 (aarch64_install_fast_tracepoint_jump_pad): Turn into...
727 (aarch64_target::install_fast_tracepoint_jump_pad): ...this.
728 (aarch64_get_min_fast_tracepoint_insn_len): Turn into...
729 (aarch64_target::get_min_fast_tracepoint_insn_len): ...this.
730 (the_low_target): Remove the op fields.
731 * linux-ppc-low.cc (class ppc_target) <supports_fast_tracepoints>
732 <install_fast_tracepoint_jump_pad>
733 <get_min_fast_tracepoint_insn_len>: Declare.
734 (ppc_target::supports_fast_tracepoints): Define.
735 (ppc_install_fast_tracepoint_jump_pad): Turn into...
736 (ppc_target::install_fast_tracepoint_jump_pad): ...this.
737 (ppc_get_min_fast_tracepoint_insn_len): Turn into...
738 (ppc_target::get_min_fast_tracepoint_insn_len): ...this.
739 (the_low_target): Remove the op fields.
740 * linux-s390-low.cc (class s390_target) <supports_fast_tracepoints>
741 <install_fast_tracepoint_jump_pad>
742 <get_min_fast_tracepoint_insn_len>: Declare.
743 (s390_target::supports_fast_tracepoints): Define.
744 (s390_install_fast_tracepoint_jump_pad): Turn into...
745 (s390_target::install_fast_tracepoint_jump_pad): ...this.
746 (s390_get_min_fast_tracepoint_insn_len): Turn into...
747 (s390_target::get_min_fast_tracepoint_insn_len): ...this.
748 (the_low_target): Remove the op fields.
749 * linux-arm-low.cc (the_low_target): Remove the op fields.
750 * linux-bfin-low.cc (the_low_target): Ditto.
751 * linux-crisv32-low.cc (the_low_target): Ditto.
752 * linux-m32r-low.cc (the_low_target): Ditto.
753 * linux-m68k-low.cc (the_low_target): Ditto.
754 * linux-sh-low.cc (the_low_target): Ditto.
755 * linux-tic6x-low.cc (the_low_target): Ditto.
756 * linux-tile-low.cc (the_low_target): Ditto.
757 * linux-xtensa-low.cc (the_low_target): Ditto.
758
759 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
760
761 Turn the 'get_thread_area' linux target op into a method of
762 process_stratum_target.
763
764 * linux-low.h (struct linux_target_ops): Remove the op.
765 (class linux_process_target) <stuck_in_jump_pad>
766 <linux_fast_tracepoint_collecting>
767 <low_get_thread_area>: Declare.
768 * linux-low.cc (supports_fast_tracepoints): Remove.
769 (linux_fast_tracepoint_collecting): Turn into...
770 (linux_process_target::linux_fast_tracepoint_collecting): ...this.
771 (linux_process_target::low_get_thread_area): Define.
772 (stuck_in_jump_pad_callback): Turn into...
773 (linux_process_target::stuck_in_jump_pad): ...this.
774
775 Update the caller below.
776
777 (linux_process_target::stabilize_threads)
778
779 * linux-x86-low.cc (class x86_target) <low_get_thread_area>:
780 Declare.
781 (x86_get_thread_area): Turn into...
782 (x86_target::low_get_thread_area): ...this.
783 (the_low_target): Remove the op field.
784 * linux-aarch64-low.cc (class aarch64_target) <low_get_thread_area>:
785 Declare.
786 (aarch64_get_thread_area): Turn into...
787 (aarch64_target::low_get_thread_area): ...this.
788 (the_low_target): Remove the op field.
789 * linux-ppc-low.cc (class ppc_target) <low_get_thread_area>:
790 Declare.
791 (ppc_get_thread_area): Turn into...
792 (ppc_target::low_get_thread_area): ...this.
793 (the_low_target): Remove the op field.
794 * linux-s390-low.cc (class s390_target) <low_get_thread_area>:
795 Declare.
796 (s390_get_thread_area): Turn into...
797 (s390_target::low_get_thread_area): ...this.
798 (the_low_target): Remove the op field.
799 * linux-arm-low.cc (the_low_target): Remove the op field.
800 * linux-bfin-low.cc (the_low_target): Ditto.
801 * linux-crisv32-low.cc (the_low_target): Ditto.
802 * linux-m32r-low.cc (the_low_target): Ditto.
803 * linux-m68k-low.cc (the_low_target): Ditto.
804 * linux-sh-low.cc (the_low_target): Ditto.
805 * linux-tic6x-low.cc (the_low_target): Ditto.
806 * linux-tile-low.cc (the_low_target): Ditto.
807 * linux-xtensa-low.cc (the_low_target): Ditto.
808
809 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
810
811 Remote the 'supports_tracepoints' linux target op and let the
812 concrete linux target define it by overriding the op declared in
813 process_stratum_target.
814
815 * linux-low.h (struct linux_target_ops): Remove the op.
816 (class linux_process_target) <supports_tracepoints>: Remove.
817 * linux-low.cc (linux_process_target::supports_tracepoints): Remove.
818 * linux-x86-low.cc (class x86_target) <supports_tracepoints>:
819 Declare.
820 (x86_supports_tracepoints): Turn into...
821 (x86_target::supports_tracepoints): ...this.
822 (the_low_target): Remove the op field.
823 * linux-aarch64-low.cc (class aarch64_target)
824 <supports_tracepoints>: Declare.
825 (aarch64_supports_tracepoints): Turn into...
826 (aarch64_target::supports_tracepoints): ...this.
827 (the_low_target): Remove the op field.
828 * linux-ppc-low.cc (class ppc_target) <supports_tracepoints>:
829 Declare.
830 (ppc_supports_tracepoints): Turn into...
831 (ppc_target::supports_tracepoints): ...this.
832 (the_low_target): Remove the op field.
833 * linux-s390-low.cc (class s390_target) <supports_tracepoints>:
834 Declare.
835 (s390_supports_tracepoints): Turn into...
836 (s390_target::supports_tracepoints): ...this.
837 (the_low_target): Remove the op field.
838 * linux-arm-low.cc (the_low_target): Remove the op field.
839 * linux-bfin-low.cc (the_low_target): Ditto.
840 * linux-crisv32-low.cc (the_low_target): Ditto.
841 * linux-m32r-low.cc (the_low_target): Ditto.
842 * linux-m68k-low.cc (the_low_target): Ditto.
843 * linux-sh-low.cc (the_low_target): Ditto.
844 * linux-tic6x-low.cc (the_low_target): Ditto.
845 * linux-tile-low.cc (the_low_target): Ditto.
846 * linux-xtensa-low.cc (the_low_target): Ditto.
847
848 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
849
850 Remove the 'process_qsupported' linux target op and let a concrete
851 linux target define the op by overriding the op declaration in
852 process_stratum_target.
853
854 * linux-low.h (struct linux_target_ops): Remove the op.
855 (class linux_process_target) <process_qsupported>: Remove.
856 * linux-low.cc (linux_process_target::process_qsupported): Remove.
857 * linux-x86-low.cc (class x86_target) <process_qsupported>: Declare.
858 (x86_linux_process_qsupported): Turn into...
859 (x86_target::process_qsupported): ...this.
860 (the_low_target): Remove the op field.
861 * linux-aarch64-low.cc (the_low_target): Remove the op
862 field.
863 * linux-arm-low.cc (the_low_target): Ditto.
864 * linux-bfin-low.cc (the_low_target): Ditto.
865 * linux-crisv32-low.cc (the_low_target): Ditto.
866 * linux-m32r-low.cc (the_low_target): Ditto.
867 * linux-m68k-low.cc (the_low_target): Ditto.
868 * linux-ppc-low.cc (the_low_target): Ditto.
869 * linux-s390-low.cc (the_low_target): Ditto.
870 * linux-sh-low.cc (the_low_target): Ditto.
871 * linux-tic6x-low.cc (the_low_target): Ditto.
872 * linux-tile-low.cc (the_low_target): Ditto.
873 * linux-xtensa-low.cc (the_low_target): Ditto.
874
875 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
876
877 Turn the 'prepare_to_resume' linux target op into a method of
878 linux_process_target.
879
880 * linux-low.h (struct linux_target_ops): Remove the op.
881 (class linux_process_target) <low_prepare_to_resume>: Declare.
882 * linux-low.cc (linux_process_target::low_prepare_to_resume):
883 Define.
884
885 Update the callers below:
886
887 (linux_process_target::resume_one_lwp_throw)
888 (linux_process_target::low_prepare_to_resume)
889
890 * linux-x86-low.cc (class x86_target) <low_prepare_to_resume>:
891 Declare.
892 (x86_target::low_prepare_to_resume): Define.
893 (the_low_target): Remove the op field.
894 * linux-aarch64-low.cc (class aarch64_target)
895 <low_prepare_to_resume>: Declare.
896 (aarch64_target::low_prepare_to_resume): Define.
897 (the_low_target): Remove the op field.
898 * linux-arm-low.cc (class arm_target) <low_prepare_to_resume>:
899 Declare.
900 (arm_prepare_to_resume): Turn into...
901 (arm_target::low_prepare_to_resume): ...this.
902 (the_low_target): Remove the op field.
903 * linux-mips-low.cc (class mips_target) <low_prepare_to_resume>:
904 Declare.
905 (mips_linux_prepare_to_resume): Turn into...
906 (mips_target::low_prepare_to_resume): ...this.
907 (the_low_target): Remove the op field.
908 * linux-bfin-low.cc (the_low_target): Remove the op field.
909 * linux-crisv32-low.cc (the_low_target): Ditto.
910 * linux-m32r-low.cc (the_low_target): Ditto.
911 * linux-m68k-low.cc (the_low_target): Ditto.
912 * linux-ppc-low.cc (the_low_target): Ditto.
913 * linux-s390-low.cc (the_low_target): Ditto.
914 * linux-sh-low.cc (the_low_target): Ditto.
915 * linux-tic6x-low.cc (the_low_target): Ditto.
916 * linux-tile-low.cc (the_low_target): Ditto.
917 * linux-xtensa-low.cc (the_low_target): Ditto.
918
919 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
920
921 Turn the 'new_process', 'delete_process', 'new_thread',
922 'delete_thread', and 'new_fork' linux target ops into methods
923 of linux_process_target.
924
925 * linux-low.h (struct linux_target_ops): Remove the ops.
926 (class linux_process_target) <add_linux_process>
927 <add_lwp>
928 <delete_lwp>
929 <attach_lwp>
930 <detach_one_lwp>
931 <check_zombie_leaders>
932 <filter_exit_event>
933 <low_new_process>
934 <low_delete_process>
935 <low_new_thread>
936 <low_delete_thread>
937 <low_new_fork>: Declare.
938 * linux-low.cc (delete_lwp): Turn into...
939 (linux_process_target::delete_lwp): ...this.
940 (linux_process_target::low_delete_thread): Define.
941 (linux_add_process): Turn into...
942 (linux_process_target::add_linux_process): ...this.
943 (linux_process_target::low_new_process): Define.
944 (linux_process_target::low_delete_process): Define.
945 (linux_process_target::low_new_fork): Define.
946 (add_lwp): Turn into...
947 (linux_process_target::add_lwp): ...this.
948 (linux_process_target::low_new_thread): Define.
949 (linux_attach_lwp): Turn into...
950 (linux_process_target::attach_lwp): ...this.
951 (linux_detach_one_lwp): Turn into...
952 (linux_process_target::detach_one_lwp): ...this.
953 (linux_detach_lwp_callback): Remove and inline...
954 (linux_process_target::detach): ...here.
955 (check_zombie_leaders): Turn into...
956 (linux_process_target::check_zombie_leaders): ...this.
957 (filter_exit_event): Turn into...
958 (linux_process_target::filter_exit_event): ...this.
959
960 Update the callers below.
961
962 (linux_process_target::handle_extended_wait)
963 (linux_process_target::create_inferior)
964 (attach_proc_task_lwp_callback)
965 (linux_process_target::attach)
966 (linux_process_target::detach)
967 (linux_process_target::mourn)
968 * thread-db.cc (attach_thread)
969
970 * linux-x86-low.cc (class x86_target) <low_new_process>
971 <low_delete_process>
972 <low_new_thread>
973 <low_delete_thread>
974 <low_new_fork>: Declare.
975 (x86_linux_new_process): Turn into...
976 (x86_target::low_new_process): ...this.
977 (x86_linux_delete_process): Turn into...
978 (x86_target::low_delete_process): ...this.
979 (x86_target::low_new_thread): Define.
980 (x86_target::low_delete_thread): Define.
981 (x86_linux_new_fork): Turn into...
982 (x86_target::low_new_fork): ...this.
983 (the_low_target): Remove the op fields.
984 * linux-aarch64-low.cc (class aarch64_target) <low_new_process>
985 <low_delete_process>
986 <low_new_thread>
987 <low_delete_thread>
988 <low_new_fork>: Declare.
989 (aarch64_linux_new_process): Turn into...
990 (aarch64_target::low_new_process): ...this.
991 (aarch64_linux_delete_process): Turn into...
992 (aarch64_target::low_delete_process): ...this.
993 (aarch64_target::low_new_thread): Define.
994 (aarch64_target::low_delete_thread): Define.
995 (aarch64_linux_new_fork): Turn into...
996 (aarch64_target::low_new_fork): ...this.
997 (the_low_target): Remove the op fields.
998 * linux-arm-low.cc (class arm_target) <low_new_process>
999 <low_delete_process>
1000 <low_new_thread>
1001 <low_delete_thread>
1002 <low_new_fork>: Declare.
1003 (arm_new_process): Turn into...
1004 (arm_target::low_new_process): ...this.
1005 (arm_delete_process): Turn into...
1006 (arm_target::low_delete_process): ...this.
1007 (arm_new_thread): Turn into...
1008 (arm_target::low_new_thread): ...this.
1009 (arm_delete_thread): Turn into...
1010 (arm_target::low_delete_thread): ...this.
1011 (arm_new_fork): Turn into...
1012 (arm_target::low_new_fork): ...this.
1013 (the_low_target): Remove the op fields.
1014 * linux-mips-low.cc (class mips_target) <low_new_process>
1015 <low_delete_process>
1016 <low_new_thread>
1017 <low_delete_thread>
1018 <low_new_fork>: Declare.
1019 (mips_linux_new_process): Turn into...
1020 (mips_target::low_new_process): ...this.
1021 (mips_linux_delete_process): Turn into...
1022 (mips_target::low_delete_process): ...this.
1023 (mips_linux_new_thread): Turn into...
1024 (mips_target::low_new_thread): ...this.
1025 (mips_linux_delete_thread): Turn into...
1026 (mips_target::low_delete_thread): ...this.
1027 (mips_linux_new_fork): Turn into...
1028 (mips_target::low_new_fork): ...this.
1029 (the_low_target): Remove the op fields.
1030 * linux-bfin-low.cc (the_low_target): Remove the op fields.
1031 * linux-crisv32-low.cc (the_low_target): Ditto.
1032 * linux-m32r-low.cc (the_low_target): Ditto.
1033 * linux-m68k-low.cc (the_low_target): Ditto.
1034 * linux-ppc-low.cc (the_low_target): Ditto.
1035 * linux-s390-low.cc (the_low_target): Ditto.
1036 * linux-sh-low.cc (the_low_target): Ditto.
1037 * linux-tic6x-low.cc (the_low_target): Ditto.
1038 * linux-tile-low.cc (the_low_target): Ditto.
1039 * linux-xtensa-low.cc (the_low_target): Ditto.
1040
1041 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1042
1043 Turn the 'siginfo_fixup' linux target op into a method of
1044 linux_process_target.
1045
1046 * linux-low.h (struct linux_target_ops): Remove the op.
1047 (class linux_process_target) <siginfo_fixup>
1048 <low_siginfo_fixup>: Declare.
1049 * linux-low.cc (siginfo_fixup): Turn into...
1050 (linux_process_target::siginfo_fixup): ...this.
1051 (linux_process_target::low_siginfo_fixup): Define.
1052 * linux-x86-low.cc (class x86_target) <low_siginfo_fixup>: Declare.
1053 (x86_siginfo_fixup): Turn into...
1054 (x86_target::low_siginfo_fixup): ...this.
1055 (the_low_target): Remove the op field.
1056 * linux-aarch64-low.cc (class aarch64_target):
1057 <low_siginfo_fixup>: Declare.
1058 (aarch64_linux_siginfo_fixup): Turn into...
1059 (aarch64_target::low_siginfo_fixup): ...this.
1060 (the_low_target): Remove the op field.
1061 * linux-arm-low.cc (the_low_target): Remove the op field.
1062 * linux-bfin-low.cc (the_low_target): Ditto.
1063 * linux-crisv32-low.cc (the_low_target): Ditto.
1064 * linux-m32r-low.cc (the_low_target): Ditto.
1065 * linux-m68k-low.cc (the_low_target): Ditto.
1066 * linux-mips-low.cc (the_low_target): Ditto.
1067 * linux-ppc-low.cc (the_low_target): Ditto.
1068 * linux-s390-low.cc (the_low_target): Ditto.
1069 * linux-sh-low.cc (the_low_target): Ditto.
1070 * linux-tic6x-low.cc (the_low_target): Ditto.
1071 * linux-tile-low.cc (the_low_target): Ditto.
1072 * linux-xtensa-low.cc (the_low_target): Ditto.
1073
1074 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1075
1076 Turn the 'collect_ptrace_register' and 'supply_ptrace_register'
1077 linux target ops into methods of linux_process_target.
1078
1079 * linux-low.h (struct linux_target_ops): Remove the ops.
1080 (class linux_process_target) <low_collect_ptrace_register>
1081 <low_store_ptrace_register>: Declare.
1082 * linux-low.cc (linux_process_target::low_collect_ptrace_register)
1083 (linux_process_target::low_supply_ptrace_register): Define.
1084
1085 Update the callers below.
1086
1087 (linux_process_target::fetch_register)
1088 (linux_process_target::store_register)
1089
1090 * linux-x86-low.cc (the_low_target): Remove the op fields.
1091 * linux-aarch64-low.cc (the_low_target): Ditto.
1092 * linux-arm-low.cc (the_low_target): Ditto.
1093 * linux-bfin-low.cc (the_low_target): Ditto.
1094 * linux-crisv32-low.cc (the_low_target): Ditto.
1095 * linux-m32r-low.cc (the_low_target): Ditto.
1096 * linux-m68k-low.cc (the_low_target): Ditto.
1097 * linux-sh-low.cc (the_low_target): Ditto.
1098 * linux-sparc-low.cc (the_low_target): Ditto.
1099 * linux-tic6x-low.cc (the_low_target): Ditto.
1100 * linux-tile-low.cc (the_low_target): Ditto.
1101 * linux-xtensa-low.cc (the_low_target): Ditto.
1102 * linux-mips-low.cc (class mips_target)
1103 <low_collect_ptrace_register>
1104 <low_supply_ptrace_register>: Declare.
1105 (mips_collect_ptrace_register): Turn into ...
1106 (mips_target::low_collect_ptrace_register): ...this.
1107 (mips_supply_ptrace_register): Turn into...
1108 (mips_target::low_supply_ptrace_register): ...this.
1109 (the_low_target): Remove the op fields.
1110 * linux-ppc-low.cc (class ppc_target)
1111 <low_collect_ptrace_register>
1112 <low_supply_ptrace_register>: Declare.
1113 (ppc_collect_ptrace_register): Turn into ...
1114 (ppc_target::low_collect_ptrace_register): ...this.
1115 (ppc_supply_ptrace_register): Turn into ...
1116 (ppc_target::low_supply_ptrace_register): ...this.
1117 (ppc_fill_gregset): Update for the calls to
1118 low_collect_ptrace_register.
1119 (the_low_target): Remove the op fields.
1120 * linux-s390-low.cc (class s390_target)
1121 <low_collect_ptrace_register>
1122 <low_supply_ptrace_register>: Declare.
1123 (s390_collect_ptrace_register): Turn into ...
1124 (s390_target::low_collect_ptrace_register): ...this.
1125 (s390_supply_ptrace_register): Turn into ...
1126 (s390_target::low_supply_ptrace_register): ...this.
1127 (s390_fill_gregset): Update for the calls to
1128 low_collect_ptrace_register.
1129 (the_low_target): Remove the op fields.
1130
1131 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1132
1133 Turn the 'stopped_by_watchpoint' and 'stopped_data_address' linux
1134 target ops into methods of linux_process_target.
1135
1136 * linux-low.h (struct linux_target_ops): Remove the ops.
1137 (class linux_process_target) <check_stopped_by_watchpoint>
1138 <low_stopped_by_watchpoint>
1139 <low_stopped_data_address>: Declare.
1140 * linux-low.cc (check_stopped_by_watchpoint): Turn into...
1141 (linux_process_target::check_stopped_by_watchpoint): ...this.
1142 (linux_process_target::low_stopped_by_watchpoint): Define.
1143 (linux_process_target::low_stopped_data_address): Define.
1144 * linux-x86-low.cc (class x86_target) <low_stopped_by_watchpoint>
1145 <low_stopped_data_address>: Declare.
1146 (x86_stopped_by_watchpoint): Turn into...
1147 (x86_target::low_stopped_by_watchpoint): ...this.
1148 (x86_stopped_data_address): Turn into...
1149 (x86_target::low_stopped_data_address): ...this.
1150 (the_low_target): Remove the op fields.
1151 * linux-aarch64-low.cc (class aarch64_target)
1152 <low_stopped_by_watchpoint>
1153 <low_stopped_data_address>: Declare.
1154 (aarch64_stopped_by_watchpoint): Turn into...
1155 (aarch64_target::low_stopped_by_watchpoint): ...this.
1156 (aarch64_stopped_data_address): Turn into...
1157 (aarch64_target::low_stopped_data_address): ...this.
1158 (the_low_target): Remove the op fields.
1159 * linux-arm-low.cc (class arm_target) <low_stopped_by_watchpoint>
1160 <low_stopped_data_address>: Declare.
1161 (arm_stopped_by_watchpoint): Turn into...
1162 (arm_target::low_stopped_by_watchpoint): ...this.
1163 (arm_stopped_data_address): Turn into...
1164 (arm_target::low_stopped_data_address): ...this.
1165 (the_low_target): Remove the op fields.
1166 * linux-crisv32-low.cc (class crisv32_target)
1167 <low_stopped_by_watchpoint>
1168 <low_stopped_data_address>: Declare.
1169 (cris_stopped_by_watchpoint): Turn into...
1170 (crisv32_target::low_stopped_by_watchpoint): ...this.
1171 (cris_stopped_data_address): Turn into...
1172 (crisv32_target::low_stopped_data_address): ...this.
1173 (the_low_target): Remove the op fields.
1174 * linux-mips-low.cc (class mips_target) <low_stopped_by_watchpoint>
1175 <low_stopped_data_address>: Declare.
1176 (mips_stopped_by_watchpoint): Turn into...
1177 (mips_target::low_stopped_by_watchpoint): ...this.
1178 (mips_stopped_data_address): Turn into...
1179 (mips_target::low_stopped_data_address): ...this.
1180 (the_low_target): Remove the op fields.
1181 * linux-bfin-low.cc (the_low_target): Remove the op fields.
1182 * linux-m32r-low.cc (the_low_target): Ditto.
1183 * linux-m68k-low.cc (the_low_target): Ditto.
1184 * linux-ppc-low.cc (the_low_target): Ditto.
1185 * linux-s390-low.cc (the_low_target): Ditto.
1186 * linux-sh-low.cc (the_low_target): Ditto.
1187 * linux-sparc-low.cc (the_low_target): Ditto.
1188 * linux-tic6x-low.cc (the_low_target): Ditto.
1189 * linux-tile-low.cc (the_low_target): Ditto.
1190 * linux-xtensa-low.cc (the_low_target): Ditto.
1191
1192 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1193
1194 Turn the 'insert_point' and 'remove_point' linux target ops into
1195 methods of linux_process_target.
1196
1197 * linux-low.h (struct linux_target_ops): Remove the ops.
1198 (class linux_process_target) <low_insert_point>
1199 <low_remove_point>: Declare.
1200 * linux-low.cc (linux_process_target::low_insert_point)
1201 (linux_process_target::low_remove_point): Define.
1202 (linux_process_target::insert_point)
1203 (linux_process_target::remove_point): Update for calls to
1204 low_insert_point and low_remove_point.
1205 * linux-x86-low.cc (class x86_target) <low_insert_point>
1206 <low_remove_point>: Declare.
1207 (x86_insert_point): Turn into...
1208 (x86_target::low_insert_point): ...this.
1209 (x86_remove_point): Turn into...
1210 (x86_target::low_remove_point): ...this.
1211 (the_low_target): Remove the op fields.
1212 * linux-aarch64-low.cc (class aarch64_target) <low_insert_point>
1213 <low_remove_point>: Declare.
1214 (aarch64_insert_point): Turn into...
1215 (aarch64_target::low_insert_point): ...this.
1216 (aarch64_remove_point): Turn into...
1217 (aarch64_target::low_remove_point): ...this.
1218 (the_low_target): Remove the op fields.
1219 * linux-arm-low.cc (class arm_target) <low_insert_point>
1220 <low_remove_point>: Declare.
1221 (arm_insert_point): Turn into...
1222 (arm_target::low_insert_point): ...this.
1223 (arm_remove_point): Turn into...
1224 (arm_target::low_remove_point): ...this.
1225 (the_low_target): Remove the op fields.
1226 * linux-crisv32-low.cc (class crisv32_target) <low_insert_point>
1227 <low_remove_point>: Declare.
1228 (crisv32_insert_point): Turn into...
1229 (crisv32_target::low_insert_point): ...this.
1230 (crisv32_remove_point): Turn into...
1231 (crisv32_target::low_remove_point): ...this.
1232 (the_low_target): Remove the op fields.
1233 * linux-mips-low.cc (class mips_target) <low_insert_point>
1234 <low_remove_point>: Declare.
1235 (mips_insert_point): Turn into...
1236 (mips_target::low_insert_point): ...this.
1237 (mips_remove_point): Turn into...
1238 (mips_target::low_remove_point): ...this.
1239 (the_low_target): Remove the op fields.
1240 * linux-ppc-low.cc (class ppc_target) <low_insert_point>
1241 <low_remove_point>: Declare.
1242 (ppc_insert_point): Turn into...
1243 (ppc_target::low_insert_point): ...this.
1244 (ppc_remove_point): Turn into...
1245 (ppc_target::low_remove_point): ...this.
1246 (the_low_target): Remove the op fields.
1247 * linux-bfin-low.cc (the_low_target): Remove the op fields.
1248 * linux-m32r-low.cc (the_low_target): Ditto.
1249 * linux-m68k-low.cc (the_low_target): Ditto.
1250 * linux-s390-low.cc (the_low_target): Ditto.
1251 * linux-sh-low.cc (the_low_target): Ditto.
1252 * linux-sparc-low.cc (the_low_target): Ditto.
1253 * linux-tic6x-low.cc (the_low_target): Ditto.
1254 * linux-tile-low.cc (the_low_target): Ditto.
1255 * linux-xtensa-low.cc (the_low_target): Ditto.
1256
1257 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1258
1259 Remove the 'supports_z_point_type' linux target op and let the
1260 concrete linux target define it by overriding the op declared in
1261 process_stratum_target.
1262
1263 * linux-low.cc (linux_process_target::supports_z_point_type):
1264 Remove.
1265 * linux-low.h (struct linux_target_ops): Remove the op.
1266 (class linux_process_target) <supports_z_point_type>: Remove.
1267 * linux-x86-low.cc (class x86_target) <supports_z_point_type>:
1268 Declare.
1269 (x86_supports_z_point_type): Turn into...
1270 (x86_target::supports_z_point_type): ...this.
1271 (the_low_target): Remove the op field.
1272 * linux-aarch64-low.cc (class aarch64_target)
1273 <supports_z_point_type>: Declare.
1274 (aarch64_supports_z_point_type): Turn into...
1275 (aarch64_target::supports_z_point_type): ...this.
1276 (the_low_target): Remove the op field.
1277 * linux-arm-low.cc (class arm_target) <supports_z_point_type>:
1278 Declare.
1279 (arm_supports_z_point_type): Turn into...
1280 (arm_target::supports_z_point_type): ...this.
1281 (the_low_target): Remove the op field.
1282 * linux-crisv32-low.cc (class crisv32_target)
1283 <supports_z_point_type>: Declare.
1284 (cris_supports_z_point_type): Turn into...
1285 (crisv32_target::supports_z_point_type): ...this.
1286 (the_low_target): Remove the op field.
1287 * linux-mips-low.cc (class mips_target) <supports_z_point_type>:
1288 Declare.
1289 (mips_supports_z_point_type): Turn into...
1290 (mips_target::supports_z_point_type): ...this.
1291 (the_low_target): Remove the op field.
1292 * linux-ppc-low.cc (class ppc_target) <supports_z_point_type>:
1293 Declare.
1294 (ppc_supports_z_point_type): Turn into...
1295 (ppc_target::supports_z_point_type): ...this.
1296 (the_low_target): Remove the op field.
1297 * linux-s390-low.cc (class s390_target) <supports_z_point_type>:
1298 Declare.
1299 (s390_supports_z_point_type): Turn into...
1300 (s390_target::supports_z_point_type): ...this.
1301 (the_low_target): Remove the op field.
1302 * linux-bfin-low.cc (the_low_target): Remove the op field.
1303 * linux-m32r-low.cc (the_low_target): Ditto.
1304 * linux-m68k-low.cc (the_low_target): Ditto.
1305 * linux-sh-low.cc (the_low_target): Ditto.
1306 * linux-sparc-low.cc (the_low_target): Ditto.
1307 * linux-tic6x-low.cc (the_low_target): Ditto.
1308 * linux-tile-low.cc (the_low_target): Ditto.
1309 * linux-xtensa-low.cc (the_low_target): Ditto.
1310
1311 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1312
1313 Turn the 'breakpoint_at' linux target op into a method of
1314 linux_process_target.
1315
1316 * linux-low.h (struct linux_target_ops): Remove the op.
1317 (class linux_process_target) <low_breakpoint_at>: Declare.
1318
1319 Update the callers below:
1320
1321 * linux-low.cc (linux_process_target::save_stop_reason)
1322 (linux_process_target::thread_still_has_status_pending)
1323 (linux_process_target::wait_1)
1324
1325 * linux-x86-low.cc (class x86_target)
1326 <low_breakpoint_at>: Declare.
1327 (x86_breakpoint_at): Turn into...
1328 (x86_target::low_breakpoint_at): ...this.
1329 (the_low_target): Remove the op field.
1330 * linux-aarch64-low.cc (class aarch64_target)
1331 <low_breakpoint_at>: Declare.
1332 (aarch64_breakpoint_at): Turn into...
1333 (aarch64_target::low_breakpoint_at): ...this.
1334 (the_low_target): Remove the op field.
1335 * linux-arm-low.cc (class arm_target)
1336 <low_breakpoint_at>: Declare.
1337 (arm_target::low_breakpoint_at): Define.
1338 (the_low_target): Remove the op field.
1339 * linux-bfin-low.cc (class bfin_target)
1340 <low_breakpoint_at>: Declare.
1341 (bfin_breakpoint_at): Turn into...
1342 (bfin_target::low_breakpoint_at): ...this.
1343 (the_low_target): Remove the op field.
1344 * linux-cris-low.cc (class cris_target)
1345 <low_breakpoint_at>: Declare.
1346 (cris_breakpoint_at): Turn into...
1347 (cris_target::low_breakpoint_at): ...this.
1348 (the_low_target): Remove the op field.
1349 * linux-crisv32-low.cc (class crisv32_target)
1350 <low_breakpoint_at>: Declare.
1351 (crisv32_breakpoint_at): Turn into...
1352 (crisv32_target::low_breakpoint_at): ...this.
1353 (the_low_target): Remove the op field.
1354 * linux-ia64-low.cc (class ia64_target)
1355 <low_breakpoint_at>: Declare.
1356 (ia64_target::low_breakpoint_at): Define.
1357 * linux-m32r-low.cc (class m32r_target)
1358 <low_breakpoint_at>: Declare.
1359 (m32r_breakpoint_at): Turn into...
1360 (m32r_target::low_breakpoint_at): ...this.
1361 (the_low_target): Remove the op field.
1362 * linux-m68k-low.cc (class m68k_target)
1363 <low_breakpoint_at>: Declare.
1364 (m68k_breakpoint_at): Turn into...
1365 (m68k_target::low_breakpoint_at): ...this.
1366 (the_low_target): Remove the op field.
1367 * linux-mips-low.cc (class mips_target)
1368 <low_breakpoint_at>: Declare.
1369 (mips_breakpoint_at): Turn into...
1370 (mips_target::low_breakpoint_at): ...this.
1371 (the_low_target): Remove the op field.
1372 * linux-nios2-low.cc (class nios2_target)
1373 <low_breakpoint_at>: Declare.
1374 (nios2_breakpoint_at): Turn into...
1375 (nios2_target::low_breakpoint_at): ...this.
1376 (the_low_target): Remove the op field.
1377 * linux-ppc-low.cc (class ppc_target)
1378 <low_breakpoint_at>: Declare.
1379 (ppc_breakpoint_at): Turn into...
1380 (ppc_target::low_breakpoint_at): ...this.
1381 (the_low_target): Remove the op field.
1382 * linux-riscv-low.cc (class riscv_target)
1383 <low_breakpoint_at>: Declare.
1384 (riscv_breakpoint_at): Turn into...
1385 (riscv_target::low_breakpoint_at): ...this.
1386 (the_low_target): Remove the op field.
1387 * linux-s390-low.cc (class s390_target)
1388 <low_breakpoint_at>: Declare.
1389 (s390_breakpoint_at): Turn into...
1390 (s390_target::low_breakpoint_at): ...this.
1391 (the_low_target): Remove the op field.
1392 * linux-sh-low.cc (class sh_target)
1393 <low_breakpoint_at>: Declare.
1394 (sh_breakpoint_at): Turn into...
1395 (sh_target::low_breakpoint_at): ...this.
1396 (the_low_target): Remove the op field.
1397 * linux-sparc-low.cc (class sparc_target)
1398 <low_breakpoint_at>: Declare.
1399 (sparc_breakpoint_at): Turn into...
1400 (sparc_target::low_breakpoint_at): ...this.
1401 (the_low_target): Remove the op field.
1402 * linux-tic6x-low.cc (class tic6x_target)
1403 <low_breakpoint_at>: Declare.
1404 (tic6x_breakpoint_at): Turn into...
1405 (tic6x_target::low_breakpoint_at): ...this.
1406 (the_low_target): Remove the op field.
1407 * linux-tile-low.cc (class tile_target)
1408 <low_breakpoint_at>: Declare.
1409 (tile_breakpoint_at): Turn into...
1410 (tile_target::low_breakpoint_at): ...this.
1411 (the_low_target): Remove the op field.
1412 * linux-xtensa-low.cc (class xtensa_target)
1413 <low_breakpoint_at>: Declare.
1414 (xtensa_breakpoint_at): Turn into...
1415 (xtensa_target::low_breakpoint_at): ...this.
1416 (the_low_target): Remove the op field.
1417
1418 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1419
1420 Turn the 'decr_pc_after_break' linux_target_ops field into
1421 a method of linux_process_target.
1422
1423 * linux-low.h (struct linux_target_ops)
1424 <decr_pc_after_break>: Remove.
1425 (class linux_process_target) <low_decr_pc_after_break>: New method
1426 declaration.
1427 * linux-low.cc (linux_process_target::low_decr_pc_after_break):
1428 New method implementation.
1429
1430 Update the users below.
1431
1432 (linux_process_target::save_stop_reason)
1433 (linux_process_target::wait_1)
1434 * linux-x86-low.cc (class x86_target) <low_decr_pc_after_break>:
1435 New declaration.
1436 (x86_target::low_decr_pc_after_break): New method implementation.
1437 (the_low_target): Remove the field.
1438 * linux-bfin-low.cc (class bfin_target) <low_decr_pc_after_break>:
1439 New declaration.
1440 (bfin_target::low_decr_pc_after_break): New method implementation.
1441 (the_low_target): Remove the field.
1442 * linux-m68k-low.cc (class m68k_target) <low_decr_pc_after_break>:
1443 New declaration.
1444 (m68k_target::low_decr_pc_after_break): New method implementation.
1445 (the_low_target): Remove the field.
1446 * linux-s390-low.cc (class s390_target) <low_decr_pc_after_break>:
1447 New declaration.
1448 (s390_target::low_decr_pc_after_break): New method implementation.
1449 (the_low_target): Remove the field.
1450 * linux-aarch64-low.cc (the_low_target): Remove the field.
1451 * linux-arm-low.cc (the_low_target): Remove the field.
1452 * linux-cris-low.cc (the_low_target): Remove the field.
1453 * linux-crisv32-low.cc (the_low_target): Remove the field.
1454 * linux-m32r-low.cc (the_low_target): Remove the field.
1455 * linux-mips-low.cc (the_low_target): Remove the field.
1456 * linux-nios2-low.cc (the_low_target): Remove the field.
1457 * linux-ppc-low.cc (the_low_target): Remove the field.
1458 * linux-riscv-low.cc (the_low_target): Remove the field.
1459 * linux-sh-low.cc (the_low_target): Remove the field.
1460 * linux-sparc-low.cc (the_low_target): Remove the field.
1461 * linux-tic6x-low.cc (the_low_target): Remove the field.
1462 * linux-tile-low.cc (the_low_target): Remove the field.
1463 * linux-xtensa-low.cc (the_low_target): Remove the field.
1464
1465 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1466
1467 Remove the 'supports_software_single_step' linux target op and let
1468 the concrete linux target define it by overriding the op in
1469 process_stratum_target.
1470 Turn the 'get_next_pcs' linux target op into a method of
1471 linux_process_target.
1472
1473 * linux-low.h (struct linux_target_ops): Remove the ops.
1474 (class linux_process_target) <supports_software_single_step>:
1475 Remove.
1476 <low_get_next_pcs>: Declare.
1477 * linux-low.cc (can_software_single_step): Remove.
1478 (linux_process_target::low_get_next_pcs): Define.
1479 (linux_process_target::supports_software_single_step): Remove.
1480
1481 Update the callers below.
1482
1483 (linux_process_target::handle_extended_wait)
1484 (linux_process_target::wait_1)
1485 (linux_process_target::install_software_single_step_breakpoints)
1486 (linux_process_target::single_step)
1487 (linux_process_target::thread_needs_step_over)
1488 (linux_process_target::proceed_one_lwp)
1489 (linux_process_target::supports_range_stepping)
1490
1491 * linux-x86-low.cc (the_low_target): Remove the op field.
1492 * linux-aarch64-low.cc (the_low_target): Ditto.
1493 * linux-bfin-low.cc (the_low_target): Ditto.
1494 * linux-cris-low.cc (the_low_target): Ditto.
1495 * linux-crisv32-low.cc (the_low_target): Ditto.
1496 * linux-m32r-low.cc (the_low_target): Ditto.
1497 * linux-m68k-low.cc (the_low_target): Ditto.
1498 * linux-mips-low.cc (the_low_target): Ditto.
1499 * linux-nios2-low.cc (the_low_target): Ditto.
1500 * linux-ppc-low.cc (the_low_target): Ditto.
1501 * linux-riscv-low.cc (the_low_target): Ditto.
1502 * linux-s390-low.cc (the_low_target): Ditto.
1503 * linux-sh-low.cc (the_low_target): Ditto.
1504 * linux-sparc-low.cc (the_low_target): Ditto.
1505 * linux-tic6x-low.cc (the_low_target): Ditto.
1506 * linux-tile-low.cc (the_low_target): Ditto.
1507 * linux-xtensa-low.cc (the_low_target): Ditto.
1508 * linux-arm-low.cc (class arm_target) <low_get_next_pcs>
1509 <supports_software_single_step>: Declare.
1510 (arm_target::supports_software_single_step): Define.
1511 (arm_gdbserver_get_next_pcs): Turn into...
1512 (arm_target::low_get_next_pcs): ...this.
1513 (the_low_target): Remove the op field.
1514
1515 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1516
1517 Remove the 'sw_breakpoint_from_kind' linux target op, and let
1518 the concrete linux target define it by overriding the op
1519 in process_stratum_target.
1520
1521 * linux-low.cc (linux_process_target::sw_breakpoint_from_kind):
1522 Remove.
1523 * linux-low.h (struct linux_target_ops): Remove the op.
1524 (class linux_process_target) <sw_breakpoint_from_kind>: Remove.
1525 * linux-x86-low.cc (class x86_target) <sw_breakpoint_from_kind>:
1526 Declare.
1527 (x86_sw_breakpoint_from_kind): Turn into...
1528 (x86_target::sw_breakpoint_from_kind): ...this.
1529 (the_low_target): Remove the op field.
1530 * linux-aarch64-low.cc (class aarch64_target)
1531 <sw_breakpoint_from_kind>: Declare.
1532 (aarch64_sw_breakpoint_from_kind): Turn into...
1533 (aarch64_target::sw_breakpoint_from_kind): ...this.
1534 (the_low_target): Remove the op field.
1535 * linux-arm-low.cc (class arm_target) <sw_breakpoint_from_kind>:
1536 Declare.
1537 (arm_target::sw_breakpoint_from_kind): Define.
1538 (the_low_target): Remove the op field.
1539 * linux-bfin-low.cc (class bfin_target) <sw_breakpoint_from_kind>:
1540 Declare.
1541 (bfin_sw_breakpoint_from_kind): Turn into...
1542 (bfin_target::sw_breakpoint_from_kind): ...this.
1543 (the_low_target): Remove the op field.
1544 * linux-cris-low.cc (class cris_target) <sw_breakpoint_from_kind>:
1545 Declare.
1546 (cris_sw_breakpoint_from_kind): Turn into...
1547 (cris_target::sw_breakpoint_from_kind): ...this.
1548 (the_low_target): Remove the op field.
1549 * linux-crisv32-low.cc (class crisv32_target)
1550 <sw_breakpoint_from_kind>: Declare.
1551 (cris_sw_breakpoint_from_kind): Turn into...
1552 (crisv32_target::sw_breakpoint_from_kind): ...this.
1553 (the_low_target): Remove the op field.
1554 * linux-ia64-low.cc (class ia64_target) <sw_breakpoint_from_kind>:
1555 Declare.
1556 (ia64_target::sw_breakpoint_from_kind): Define.
1557 * linux-m32r-low.cc (class m32r_target) <sw_breakpoint_from_kind>:
1558 Declare.
1559 (m32r_sw_breakpoint_from_kind): Turn into...
1560 (m32r_target::sw_breakpoint_from_kind): ...this.
1561 (the_low_target): Remove the op field.
1562 * linux-m68k-low.cc (class m68k_target) <sw_breakpoint_from_kind>:
1563 Declare.
1564 (m68k_sw_breakpoint_from_kind): Turn into...
1565 (m68k_target::sw_breakpoint_from_kind): ...this.
1566 (the_low_target): Remove the op field.
1567 * linux-mips-low.cc (class mips_target) <sw_breakpoint_from_kind>:
1568 Declare.
1569 (mips_sw_breakpoint_from_kind): Turn into...
1570 (mips_target::sw_breakpoint_from_kind): ...this.
1571 (the_low_target): Remove the op field.
1572 * linux-nios2-low.cc (class nios2_target) <sw_breakpoint_from_kind>:
1573 Declare.
1574 (nios2_sw_breakpoint_from_kind): Turn into...
1575 (nios2_target::sw_breakpoint_from_kind): ...this.
1576 (the_low_target): Remove the op field.
1577 * linux-ppc-low.cc (class ppc_target) <sw_breakpoint_from_kind>:
1578 Declare.
1579 (ppc_sw_breakpoint_from_kind): Turn into...
1580 (ppc_target::sw_breakpoint_from_kind): ...this.
1581 (the_low_target): Remove the op field.
1582 * linux-riscv-low.cc (class riscv_target) <sw_breakpoint_from_kind>:
1583 Declare.
1584 (riscv_sw_breakpoint_from_kind): Turn into...
1585 (riscv_target::sw_breakpoint_from_kind): ...this.
1586 (the_low_target): Remove the op field.
1587 * linux-s390-low.cc (class s390_target) <sw_breakpoint_from_kind>:
1588 Declare.
1589 (s390_sw_breakpoint_from_kind): Turn into...
1590 (s390_target::sw_breakpoint_from_kind): ...this.
1591 (the_low_target): Remove the op field.
1592 * linux-sh-low.cc (class sh_target) <sw_breakpoint_from_kind>:
1593 Declare.
1594 (sh_sw_breakpoint_from_kind): Turn into...
1595 (sh_target::sw_breakpoint_from_kind): ...this.
1596 (the_low_target): Remove the op field.
1597 * linux-sparc-low.cc (class sparc_target) <sw_breakpoint_from_kind>:
1598 Declare.
1599 (sparc_sw_breakpoint_from_kind): Turn into...
1600 (sparc_target::sw_breakpoint_from_kind): ...this.
1601 (the_low_target): Remove the op field.
1602 * linux-tic6x-low.cc (class tic6x_target) <sw_breakpoint_from_kind>:
1603 Declare.
1604 (tic6x_sw_breakpoint_from_kind): Turn into...
1605 (tic6x_target::sw_breakpoint_from_kind): ...this.
1606 (the_low_target): Remove the op field.
1607 * linux-tile-low.cc (class tile_target) <sw_breakpoint_from_kind>:
1608 Declare.
1609 (tile_sw_breakpoint_from_kind): Turn into...
1610 (tile_target::sw_breakpoint_from_kind): ...this.
1611 (the_low_target): Remove the op field.
1612 * linux-xtensa-low.cc (class xtensa_target)
1613 <sw_breakpoint_from_kind>: Declare.
1614 (xtensa_sw_breakpoint_from_kind): Turn into...
1615 (xtensa_target::sw_breakpoint_from_kind): ...this.
1616 (the_low_target): Remove the op field.
1617
1618 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1619
1620 Remove the 'breakpoint_kind_from_pc' and
1621 'breakpoint_kind_from_current_state' linux target ops, and let the
1622 concrete linux target define them by overriding the ops of
1623 process_stratum_target.
1624
1625 * linux-low.cc (linux_process_target::breakpoint_kind_from_pc):
1626 Remove.
1627 (linux_process_target::breakpoint_kind_from_current_state): Remove.
1628 * linux-low.h (struct linux_target_ops): Remove ops.
1629 (class linux_process_target) <breakpoint_kind_from_pc>: Remove.
1630 <breakpoint_kind_from_current_state>: Remove.
1631 * linux-x86-low.cc (the_low_target): Remove the op fields.
1632 * linux-bfin-low.cc (the_low_target): Ditto.
1633 * linux-cris-low.cc (the_low_target): Ditto.
1634 * linux-crisv32-low.cc (the_low_target): Ditto.
1635 * linux-m32r-low.cc (the_low_target): Ditto.
1636 * linux-m68k-low.cc (the_low_target): Ditto.
1637 * linux-mips-low.cc (the_low_target): Ditto.
1638 * linux-nios2-low.cc (the_low_target): Ditto.
1639 * linux-ppc-low.cc (the_low_target): Ditto.
1640 * linux-s390-low.cc (the_low_target): Ditto.
1641 * linux-sh-low.cc (the_low_target): Ditto.
1642 * linux-sparc-low.cc (the_low_target): Ditto.
1643 * linux-tic6x-low.cc (the_low_target): Ditto.
1644 * linux-tile-low.cc (the_low_target): Ditto.
1645 * linux-xtensa-low.cc (the_low_target): Ditto.
1646 * linux-aarch64-low.cc (class aarch64_target)
1647 <breakpoint_kind_from_pc>
1648 <breakpoint_kind_from_current_state>: Declare.
1649 (aarch64_breakpoint_kind_from_pc): Turn into...
1650 (aarch64_target::breakpoint_kind_from_pc): ...this.
1651 (aarch64_breakpoint_kind_from_current_state): Turn into...
1652 (aarch64_target::breakpoint_kind_from_current_state): ...this.
1653 (the_low_target): Remove the op fields.
1654 * linux-arm-low.cc (class arm_target):
1655 <breakpoint_kind_from_pc>
1656 <breakpoint_kind_from_current_state>: Declare.
1657 (arm_target::breakpoint_kind_from_pc): Define.
1658 (arm_target::breakpoint_kind_from_current_state): Define.
1659 (the_low_target): Remove the op fields.
1660 * linux-riscv-low.cc (class riscv_target):
1661 <breakpoint_kind_from_pc>: Declare.
1662 (riscv_breakpoint_kind_from_pc): Turn into...
1663 (riscv_target::breakpoint_kind_from_pc): ...this.
1664 (the_low_target): Remove the op fields.
1665
1666 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1667
1668 Turn the 'get_pc' and 'set_pc' linux target ops into methods
1669 of linux_process_target.
1670
1671 * linux-low.h (struct linux_target_ops): Remove the ops.
1672 (class linux_process_target) <low_supports_breakpoints>
1673 <low_get_pc>
1674 <low_set_pc>: Declare.
1675 * linux-low.cc (supports_breakpoints): Turn into...
1676 (linux_process_target::low_supports_breakpoints): ...this.
1677 (linux_process_target::low_get_pc): Define.
1678 (linux_process_target::low_set_pc): Define.
1679
1680 Update the callers below.
1681
1682 (linux_process_target::get_pc)
1683 (linux_process_target::save_stop_reason)
1684 (linux_process_target::maybe_move_out_of_jump_pad)
1685 (linux_process_target::wait_1)
1686 (linux_process_target::resume_one_lwp_throw)
1687 (linux_process_target::resume)
1688 (linux_process_target::proceed_all_lwps)
1689 (linux_process_target::read_pc)
1690 (linux_process_target::write_pc)
1691
1692 * linux-x86-low.cc (class linux_process_target)
1693 <low_supports_breakpoints>
1694 <low_get_pc>
1695 <low_set_pc>: Declare.
1696 (x86_target::low_supports_breakpoints): Define.
1697 (x86_get_pc): Turn into...
1698 (x86_target::low_get_pc): ...this.
1699 (x86_set_pc): Turn into...
1700 (x86_target::low_set_pc): ...this.
1701 (the_low_target): Remove the op fields.
1702 * linux-arm-low.cc (class arm_target)
1703 <low_supports_breakpoints>
1704 <low_get_pc>
1705 <low_set_pc>: Declare.
1706 (arm_target::low_supports_breakpoints)
1707 (arm_target::low_get_pc)
1708 (arm_target::low_set_pc): Define.
1709 (the_low_target): Remove the op fields.
1710 * linux-bfin-low.cc (class bfin_target)
1711 <low_supports_breakpoints>
1712 <low_get_pc>
1713 <low_set_pc>: Declare.
1714 (bfin_target::low_supports_breakpoints)
1715 (bfin_target::low_get_pc)
1716 (bfin_target::low_set_pc): Define.
1717 (the_low_target): Remove the op fields.
1718 * linux-cris-low.cc (class cris_target)
1719 <low_supports_breakpoints>
1720 <low_get_pc>
1721 <low_set_pc>: Declare.
1722 (cris_target::low_supports_breakpoints)
1723 (cris_target::low_get_pc)
1724 (cris_target::low_set_pc): Define.
1725 (the_low_target): Remove the op fields.
1726 * linux-crisv32-low.cc (class crisv32_target)
1727 <low_supports_breakpoints>
1728 <low_get_pc>
1729 <low_set_pc>: Declare.
1730 (crisv32_target::low_supports_breakpoints)
1731 (crisv32_target::low_get_pc)
1732 (crisv32_target::low_set_pc): Define.
1733 (the_low_target): Remove the op fields.
1734 * linux-m32r-low.cc (class m32r_target)
1735 <low_supports_breakpoints>
1736 <low_get_pc>
1737 <low_set_pc>: Declare.
1738 (m32r_target::low_supports_breakpoints)
1739 (m32r_target::low_get_pc)
1740 (m32r_target::low_set_pc): Define.
1741 (the_low_target): Remove the op fields.
1742 * linux-m68k-low.cc (class m68k_target)
1743 <low_supports_breakpoints>
1744 <low_get_pc>
1745 <low_set_pc>: Declare.
1746 (m68k_target::low_supports_breakpoints)
1747 (m68k_target::low_get_pc)
1748 (m68k_target::low_set_pc): Define.
1749 (the_low_target): Remove the op fields.
1750 * linux-nios2-low.cc (class nios2_target)
1751 <low_supports_breakpoints>
1752 <low_get_pc>
1753 <low_set_pc>: Declare.
1754 (nios2_target::low_supports_breakpoints)
1755 (nios2_target::low_get_pc)
1756 (nios2_target::low_set_pc): Define.
1757 (the_low_target): Remove the op fields.
1758 * linux-sh-low.cc (class sh_target)
1759 <low_supports_breakpoints>
1760 <low_get_pc>
1761 <low_set_pc>: Declare.
1762 (sh_target::low_supports_breakpoints)
1763 (sh_target::low_get_pc)
1764 (sh_target::low_set_pc): Define.
1765 (the_low_target): Remove the op fields.
1766 * linux-xtensa-low.cc (class xtensa_target)
1767 <low_supports_breakpoints>
1768 <low_get_pc>
1769 <low_set_pc>: Declare.
1770 (xtensa_target::low_supports_breakpoints)
1771 (xtensa_target::low_get_pc)
1772 (xtensa_target::low_set_pc): Define.
1773 (the_low_target): Remove the op fields.
1774 * linux-sparc-low.cc (class sparc_target)
1775 <low_supports_breakpoints>
1776 <low_get_pc>: Declare.
1777 (sparc_target::low_supports_breakpoints)
1778 (sparc_target::low_get_pc): Define.
1779 (the_low_target): Remove the op fields.
1780 * linux-tile-low.cc (class tile_target)
1781 <low_supports_breakpoints>
1782 <low_get_pc>
1783 <low_set_pc>: Declare.
1784 (tile_target::low_supports_breakpoints)
1785 (tile_target::low_get_pc)
1786 (tile_target::low_set_pc): Define.
1787 (the_low_target): Remove the op fields.
1788 * linux-aarch64-low.cc (class aarch64_target)
1789 <low_supports_breakpoints>
1790 <low_get_pc>
1791 <low_set_pc>: Declare.
1792 (aarch64_target::low_supports_breakpoints): Define.
1793 (aarch64_get_pc): Turn into...
1794 (aarch64_target::low_get_pc): ...this.
1795 (aarch64_set_pc): Turn into...
1796 (aarch64_target::low_set_pc): ...this.
1797 (the_low_target): Remove the op fields.
1798 * linux-mips-low.cc (class mips_target)
1799 <low_supports_breakpoints>
1800 <low_get_pc>
1801 <low_set_pc>: Declare.
1802 (mips_target::low_supports_breakpoints): Define.
1803 (mips_get_pc): Turn into...
1804 (mips_target::low_get_pc): ...this.
1805 (mips_set_pc): Turn into...
1806 (mips_target::low_set_pc): ...this.
1807 (the_low_target): Remove the op fields.
1808 * linux-ppc-low.cc (class ppc_target)
1809 <low_supports_breakpoints>
1810 <low_get_pc>
1811 <low_set_pc>: Declare.
1812 (ppc_target::low_supports_breakpoints): Define.
1813 (ppc_get_pc): Turn into...
1814 (ppc_target::low_get_pc): ...this.
1815 (ppc_set_pc): Turn into...
1816 (ppc_target::low_set_pc): ...this.
1817 (the_low_target): Remove the op fields.
1818 * linux-riscv-low.cc (class riscv_target)
1819 <low_supports_breakpoints>
1820 <low_get_pc>
1821 <low_set_pc>: Declare.
1822 (riscv_target::low_supports_breakpoints): Define.
1823 (riscv_get_pc): Turn into...
1824 (riscv_target::low_get_pc): ...this.
1825 (riscv_set_pc): Turn into...
1826 (riscv_target::low_set_pc): ...this.
1827 (the_low_target): Remove the op fields.
1828 * linux-s390-low.cc (class s390_target)
1829 <low_supports_breakpoints>
1830 <low_get_pc>
1831 <low_set_pc>: Declare.
1832 (s390_target::low_supports_breakpoints): Define.
1833 (s390_get_pc): Turn into...
1834 (s390_target::low_get_pc): ...this.
1835 (s390_set_pc): Turn into...
1836 (s390_target::low_set_pc): ...this.
1837 (the_low_target): Remove the op fields.
1838 * linux-tic6x-low.cc (class tic6x_target)
1839 <low_supports_breakpoints>
1840 <low_get_pc>
1841 <low_set_pc>: Declare.
1842 (tic6x_target::low_supports_breakpoints): Define.
1843 (tic6x_get_pc): Turn into...
1844 (tic6x_target::low_get_pc): ...this.
1845 (tic6x_set_pc): Turn into...
1846 (tic6x_target::low_set_pc): ...this.
1847 (the_low_target): Remove the op fields.
1848
1849 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1850
1851 Turn some more static methods in linux-low into private methods
1852 of linux_process_target.
1853
1854 * linux-low.cc (get_pc): Turn into...
1855 (linux_process_target::get_pc): ...this.
1856 (save_stop_reason): Turn into...
1857 (linux_process_target::save_stop_reason): ...this.
1858 (thread_still_has_status_pending_p): Turn into...
1859 (linux_process_target::thread_still_has_status_pending): ...this.
1860 (status_pending_p_callback): Turn into...
1861 (linux_process_target::status_pending_p_callback): ...this.
1862 (resume_stopped_resumed_lwps): Turn into...
1863 (linux_process_target::resume_stopped_resumed_lwps): ...this.
1864 (install_software_single_step_breakpoints): Turn into...
1865 (linux_process_target::install_software_single_step_breakpoints):
1866 ...this.
1867 (single_step): Turn into...
1868 (linux_process_target::single_step): ...this.
1869 (linux_resume_one_lwp_throw): Turn into...
1870 (linux_process_target::resume_one_lwp_throw): ...this.
1871 (linux_resume_one_lwp): Turn into...
1872 (linux_process_target::resume_one_lwp): ...this.
1873 (resume_status_pending_p): Turn into...
1874 (linux_process_target::resume_status_pending): ...this.
1875 (need_step_over_p): Turn into...
1876 (linux_process_target::thread_needs_step_over): ...this.
1877 (linux_resume_one_thread): Turn into...
1878 (linux_process_target::resume_one_thread): ...this.
1879 (proceed_one_lwp): Turn into...
1880 (linux_process_target::proceed_one_lwp): ...this.
1881 (unsuspend_and_proceed_one_lwp): Turn into...
1882 (linux_process_target::unsuspend_and_proceed_one_lwp): ...this.
1883
1884 Update the calls/references to the above functions below.
1885
1886 (linux_process_target::handle_extended_wait)
1887 (linux_process_target::filter_event)
1888 (linux_process_target::wait_for_event_filtered)
1889 (linux_process_target::wait_1)
1890 (linux_process_target::move_out_of_jump_pad)
1891 (linux_process_target::start_step_over)
1892 (linux_process_target::resume)
1893 (linux_process_target::proceed_all_lwps)
1894 (regsets_store_inferior_registers)
1895 (linux_process_target::store_register)
1896
1897 * linux-low.h (class linux_process_target)
1898 <get_pc>
1899 <save_stop_reason>
1900 <thread_still_has_status_pending>
1901 <status_pending_p_callback>
1902 <resume_stopped_resumed_lwps>
1903 <install_software_single_step_breakpoints>
1904 <single_step>
1905 <resume_one_lwp_throw>
1906 <resume_one_lwp>
1907 <resume_status_pending>
1908 <thread_needs_step_over>
1909 <resume_one_thread>
1910 <proceed_one_lwp>
1911 <unsuspend_and_proceed_one_lwp>: Declare.
1912
1913 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1914
1915 Turn the 'fetch_register' linux target op into a method of
1916 linux_process_target.
1917
1918 * linux-low.h (struct linux_target_ops) <fetch_register>: Remove.
1919 (class linux_process_target) <low_fetch_register>: Declare.
1920 * linux-x86-low.cc (the_low_target)
1921 * linux-aarch64-low.cc (the_low_target)
1922 * linux-arm-low.cc (the_low_target)
1923 * linux-bfin-low.cc (the_low_target)
1924 * linux-cris-low.cc (the_low_target)
1925 * linux-crisv32-low.cc (the_low_target)
1926 * linux-m32r-low.cc (the_low_target)
1927 * linux-m68k-low.cc (the_low_target)
1928 * linux-nios2-low.cc (the_low_target)
1929 * linux-ppc-low.cc (the_low_target)
1930 * linux-s390-low.cc (the_low_target)
1931 * linux-sh-low.cc (the_low_target)
1932 * linux-sparc-low.cc (the_low_target)
1933 * linux-tic6x-low.cc (the_low_target)
1934 * linux-tile-low.cc (the_low_target)
1935 * linux-xtensa-low.cc (the_low_target): Remove the op field.
1936 * linux-ia64-low.cc (class ia64_target) <low_fetch_register>:
1937 Declare.
1938 (ia64_fetch_register): Turn into...
1939 (ia64_target::low_fetch_register): ...this.
1940 (the_low_target): Remove the op field.
1941 * linux-mips-low.cc (class mips_target) <low_fetch_register>:
1942 Declare.
1943 (mips_fetch_register): Turn into...
1944 (mips_target::low_fetch_register): ...this.
1945 (the_low_target): Remove the op field.
1946 * linux-riscv-low.cc (class riscv_target) <low_fetch_register>:
1947 Declare.
1948 (riscv_fetch_register): Turn into...
1949 (riscv_target::low_fetch_register): ...this.
1950 (the_low_target): Remove the op field.
1951
1952 Update the callers below.
1953
1954 * linux-low.cc (linux_process_target::fetch_registers)
1955 (linux_process_target::low_fetch_register)
1956
1957 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1958
1959 Turn the 'cannot_fetch_register' and 'cannot_store_register'
1960 linux target ops into methods of linux_process_target.
1961
1962 * linux-low.h (struct linux_target_ops): Remove the low target ops.
1963 (class linux_process_target) <fetch_register>
1964 <store_register>
1965 <usr_fetch_inferior_registers>
1966 <usr_store_inferior_registers>
1967 <low_cannot_fetch_register>
1968 <low_cannot_fetch_register> Declare.
1969 * linux-low.cc (fetch_register): Turn into...
1970 (linux_process_target::fetch_register): ...this.
1971 (store_register): Turn into ...
1972 (linux_process_target::store_register): ...this.
1973 (usr_fetch_inferior_registers): Turn into...
1974 (linux_process_target::usr_fetch_inferior_registers): ...this.
1975 (usr_store_inferior_registers): Turn into...
1976 (linux_process_target::usr_store_inferior_registers): ...this.
1977 * linux-x86-low.cc (class x86_target)
1978 <low_cannot_fetch_register>
1979 <low_cannot_store_register>: Declare.
1980 (x86_cannot_store_register): Turn into...
1981 (x86_target::low_cannot_store_register): ...this.
1982 (x86_cannot_fetch_register): Turn into...
1983 (x86_target::low_cannot_fetch_register): ...this.
1984 (the_low_target): Remove the target op fields.
1985 * linux-aarch64-low.cc (class aarch64_target)
1986 <low_cannot_fetch_register>
1987 <low_cannot_store_register>: Declare.
1988 (aarch64_target::low_cannot_fetch_register)
1989 (aarch64_target::low_cannot_store_register): Define.
1990 (the_low_target): Remove the op fields.
1991 * linux-arm-low.cc (class arm_target)
1992 <low_cannot_fetch_register>
1993 <low_cannot_store_register>: Declare.
1994 (arm_cannot_fetch_register): Turn into...
1995 (arm_target::low_cannot_fetch_register): ...this.
1996 (arm_cannot_store_register): Turn into...
1997 (arm_target::low_cannot_store_register): ...this.
1998 (the_low_target): Remove the op fields.
1999 * linux-bfin-low.cc (class bfin_target)
2000 <low_cannot_fetch_register>
2001 <low_cannot_store_register>: Declare.
2002 (bfin_cannot_fetch_register): Turn into...
2003 (bfin_target::low_cannot_fetch_register): ...this.
2004 (bfin_cannot_store_register): Turn into...
2005 (bfin_target::low_cannot_store_register): ...this.
2006 (the_low_target): Remove the op fields.
2007 * linux-cris-low.cc (class cris_target)
2008 <low_cannot_fetch_register>
2009 <low_cannot_store_register>: Declare.
2010 (cris_cannot_fetch_register): Turn into...
2011 (cris_target::low_cannot_fetch_register): ...this.
2012 (cris_cannot_store_register): Turn into...
2013 (cris_target::low_cannot_store_register): ...this.
2014 (the_low_target): Remove the op fields.
2015 * linux-crisv32-low.cc (class crisv32_target)
2016 <low_cannot_fetch_register>
2017 <low_cannot_store_register>: Declare.
2018 (crisv32_target::low_cannot_fetch_register)
2019 (crisv32_target::low_cannot_store_register): Define.
2020 (the_low_target): Remove the op fields.
2021 * linux-ia64-low.cc (class ia64_target)
2022 <low_cannot_fetch_register>
2023 <low_cannot_store_register>: Declare.
2024 (ia64_cannot_fetch_register): Turn into...
2025 (ia64_target::low_cannot_fetch_register): ...this.
2026 (ia64_cannot_store_register): Turn into...
2027 (ia64_target::low_cannot_store_register): ...this.
2028 (the_low_target): Remove the op fields.
2029 * linux-m32r-low.cc (class m32r_target)
2030 <low_cannot_fetch_register>
2031 <low_cannot_store_register>: Declare.
2032 (m32r_cannot_fetch_register): Turn into...
2033 (m32r_target::low_cannot_fetch_register): ...this.
2034 (m32r_cannot_store_register): Turn into...
2035 (m32r_target::low_cannot_store_register): ...this.
2036 (the_low_target): Remove the op fields.
2037 * linux-m68k-low.cc (class m68k_target)
2038 <low_cannot_fetch_register>
2039 <low_cannot_store_register>: Declare.
2040 (m68k_cannot_fetch_register): Turn into...
2041 (m68k_target::low_cannot_fetch_register): ...this.
2042 (m68k_cannot_store_register): Turn into...
2043 (m68k_target::low_cannot_store_register): ...this.
2044 (the_low_target): Remove the op fields.
2045 * linux-mips-low.cc (class mips_target)
2046 <low_cannot_fetch_register>
2047 <low_cannot_store_register>: Declare.
2048 (mips_cannot_fetch_register): Turn into...
2049 (mips_target::low_cannot_fetch_register): ...this.
2050 (mips_cannot_store_register): Turn into...
2051 (mips_target::low_cannot_store_register): ...this.
2052 (get_usrregs_info): Inline at the call sites in
2053 low_cannot_fetch_register and low_cannot_store_register,
2054 and remove.
2055 (the_low_target): Remove the op fields.
2056 * linux-nios2-low.cc (class nios2_target)
2057 <low_cannot_fetch_register>
2058 <low_cannot_store_register>: Declare.
2059 (nios2_cannot_fetch_register): Turn into...
2060 (nios2_target::low_cannot_fetch_register): ...this.
2061 (nios2_cannot_store_register): Turn into...
2062 (nios2_target::low_cannot_store_register): ...this.
2063 (the_low_target): Remove the op fields.
2064 * linux-ppc-low.cc (class ppc_target)
2065 <low_cannot_fetch_register>
2066 <low_cannot_store_register>: Declare.
2067 (ppc_cannot_fetch_register): Turn into...
2068 (ppc_target::low_cannot_fetch_register): ...this.
2069 (ppc_cannot_store_register): Turn into...
2070 (ppc_target::low_cannot_store_register): ...this.
2071 (the_low_target): Remove the op fields.
2072 * linux-riscv-low.cc (class riscv_target)
2073 <low_cannot_fetch_register>
2074 <low_cannot_store_register>: Declare.
2075 (riscv_target::low_cannot_fetch_register)
2076 (riscv_target::low_cannot_store_register): Define.
2077 (the_low_target): Remove the op fields.
2078 * linux-s390-low.cc (class s390_target)
2079 <low_cannot_fetch_register>
2080 <low_cannot_store_register>: Declare.
2081 (s390_cannot_fetch_register): Turn into...
2082 (s390_target::low_cannot_fetch_register): ...this.
2083 (s390_cannot_store_register): Turn into...
2084 (s390_target::low_cannot_store_register): ...this.
2085 (the_low_target): Remove the op fields.
2086 * linux-sh-low.cc (class sh_target)
2087 <low_cannot_fetch_register>
2088 <low_cannot_store_register>: Declare.
2089 (sh_cannot_fetch_register): Turn into...
2090 (sh_target::low_cannot_fetch_register): ...this.
2091 (sh_cannot_store_register): Turn into...
2092 (sh_target::low_cannot_store_register): ...this.
2093 (the_low_target): Remove the op fields.
2094 * linux-sparc-low.cc (class sparc_target)
2095 <low_cannot_fetch_register>
2096 <low_cannot_store_register>: Declare.
2097 (sparc_cannot_fetch_register): Turn into...
2098 (sparc_target::low_cannot_fetch_register): ...this.
2099 (sparc_cannot_store_register): Turn into...
2100 (sparc_target::low_cannot_store_register): ...this.
2101 (the_low_target): Remove the op fields.
2102 * linux-tic6x-low.cc (class tic6x_target)
2103 <low_cannot_fetch_register>
2104 <low_cannot_store_register>: Declare.
2105 (tic6x_cannot_fetch_register): Turn into...
2106 (tic6x_target::low_cannot_fetch_register): ...this.
2107 (tic6x_cannot_store_register): Turn into...
2108 (tic6x_target::low_cannot_store_register): ...this.
2109 (the_low_target): Remove the op fields.
2110 * linux-tile-low.cc (class tile_target)
2111 <low_cannot_fetch_register>
2112 <low_cannot_store_register>: Declare.
2113 (tile_cannot_fetch_register): Turn into...
2114 (tile_target::low_cannot_fetch_register): ...this.
2115 (tile_cannot_store_register): Turn into...
2116 (tile_target::low_cannot_store_register): ...this.
2117 (the_low_target): Remove the op fields.
2118 * linux-xtensa-low.cc (class xtensa_target)
2119 <low_cannot_fetch_register>
2120 <low_cannot_store_register>: Declare.
2121 (xtensa_target::low_cannot_fetch_register)
2122 (xtensa_target::low_cannot_store_register): Define.
2123 (the_low_target): Remove the op fields.
2124
2125 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2126
2127 Turn the 'regs_info' linux target op into a method of
2128 linux_process_target.
2129
2130 * linux-low.h (struct linux_target_ops) <regs_info>: Remove.
2131 (class linux_process_target) <get_regs_info>: Define.
2132
2133 Update the callers below.
2134
2135 * linux-low.cc (linux_process_target::fetch_registers)
2136 (linux_process_target::store_registers)
2137 * proc-service.cc (gregset_info)
2138
2139 * linux-x86-low.cc (class x86_target) <get_regs_info>: Declare.
2140 (x86_linux_regs_info): Turn into ...
2141 (x86_target::get_regs_info): ...this.
2142 (the_low_target): Remove the op field.
2143 * linux-aarch64-low.cc (class aarch64_target) <get_regs_info>:
2144 Declare.
2145 (aarch64_regs_info): Turn into ...
2146 (aarch64_target::get_regs_info): ...this.
2147 (the_low_target): Remove the op field.
2148 * linux-arm-low.cc (class arm_target) <get_regs_info>: Declare.
2149 (arm_regs_info): Turn into ...
2150 (arm_target::get_regs_info): ...this.
2151 (the_low_target): Remove the op field.
2152 * linux-bfin-low.cc (class bfin_target) <get_regs_info>: Declare.
2153 (bfin_regs_info): Turn into ...
2154 (bfin_target::get_regs_info): ...this.
2155 (the_low_target): Remove the op field.
2156 * linux-cris-low.cc (class cris_target) <get_regs_info>: Declare.
2157 (cris_regs_info): Turn into ...
2158 (cris_target::get_regs_info): ...this.
2159 (the_low_target): Remove the op field.
2160 * linux-crisv32-low.cc (class crisv32_target) <get_regs_info>:
2161 Declare.
2162 (crisv32_regs_info): Turn into ...
2163 (crisv32_target::get_regs_info): ...this.
2164 (the_low_target): Remove the op field.
2165 * linux-ia64-low.cc (class ia64_target) <get_regs_info>: Declare.
2166 (ia64_regs_info): Turn into ...
2167 (ia64_target::get_regs_info): ...this.
2168 (the_low_target): Remove the op field.
2169 * linux-m32r-low.cc (class m32r_target) <get_regs_info>: Declare.
2170 (m32r_regs_info): Turn into ...
2171 (m32r_target::get_regs_info): ...this.
2172 (the_low_target): Remove the op field.
2173 * linux-m68k-low.cc (class m68k_target) <get_regs_info>: Declare.
2174 (m68k_regs_info): Turn into ...
2175 (m68k_target::get_regs_info): ...this.
2176 (the_low_target): Remove the op field.
2177 * linux-mips-low.cc (class mips_target) <get_regs_info>: Declare.
2178 (mips_regs_info): Turn into ...
2179 (mips_target::get_regs_info): ...this.
2180 (the_low_target): Remove the op field.
2181 (get_usrregs_info): Update the call to the op.
2182 * linux-nios2-low.cc (class nios2_target) <get_regs_info>: Declare.
2183 (nios2_regs_info): Turn into ...
2184 (nios2_target::get_regs_info): ...this.
2185 (the_low_target): Remove the op field.
2186 * linux-ppc-low.cc (class ppc_target) <get_regs_info>: Declare.
2187 (ppc_regs_info): Turn into ...
2188 (ppc_target::get_regs_info): ...this.
2189 (the_low_target): Remove the op field.
2190 * linux-riscv-low.cc (class riscv_target) <get_regs_info>: Declare.
2191 (riscv_regs_info): Turn into ...
2192 (riscv_target::get_regs_info): ...this.
2193 (the_low_target): Remove the op field.
2194 * linux-s390-low.cc (class s390_target) <get_regs_info>: Declare.
2195 (s390_regs_info): Turn into ...
2196 (s390_target::get_regs_info): ...this.
2197 (the_low_target): Remove the op field.
2198 (s390_collect_ptrace_register)
2199 (s390_supply_ptrace_register)
2200 (s390_fill_gregset): Update the call to the op.
2201 * linux-sh-low.cc (class sh_target) <get_regs_info>: Declare.
2202 (sh_regs_info): Turn into ...
2203 (sh_target::get_regs_info): ...this.
2204 (the_low_target): Remove the op field.
2205 * linux-sparc-low.cc (class sparc_target) <get_regs_info>: Declare.
2206 (sparc_regs_info): Turn into ...
2207 (sparc_target::get_regs_info): ...this.
2208 (the_low_target): Remove the op field.
2209 * linux-tic6x-low.cc (class tic6x_target) <get_regs_info>: Declare.
2210 (tic6x_regs_info): Turn into ...
2211 (tic6x_target::get_regs_info): ...this.
2212 (the_low_target): Remove the op field.
2213 * linux-tile-low.cc (class tile_target) <get_regs_info>: Declare.
2214 (tile_regs_info): Turn into ...
2215 (tile_target::get_regs_info): ...this.
2216 (the_low_target): Remove the op field.
2217 * linux-xtensa-low.cc (class xtensa_target) <get_regs_info>:
2218 Declare.
2219 (xtensa_regs_info): Turn into ...
2220 (xtensa_target::get_regs_info): ...this.
2221 (the_low_target): Remove the op field.
2222
2223 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2224
2225 Turn the 'arch_setup' linux target op into a method of
2226 linux_process_target.
2227
2228 * linux-low.h (struct linux_target_ops) <arch_setup>: Delete.
2229 (class linux_process_target) <arch_setup_thread>
2230 <low_arch_setup>: New declarations.
2231 * linux-low.cc (linux_arch_setup): Delete.
2232 (linux_arch_setup_thread): Turn into...
2233 (linux_process_target::arch_setup_thread): ... this.
2234
2235 Update the callers below.
2236
2237 (linux_process_target::handle_extended_wait)
2238 (linux_process_target::post_create_inferior)
2239 (linux_process_target::filter_event)
2240
2241 * linux-x86-low.cc (class x86_target) <low_arch_setup>: New
2242 declaration.
2243 (x86_linux_update_xmltarget): Turn into...
2244 (x86_target::update_xmltarget): ...this.
2245 (x86_linux_process_qsupported): Update the call to
2246 x86_linux_update_xmltarget.
2247 (x86_arch_setup): Turn into ...
2248 (x86_target::low_arch_setup): ...this.
2249 (the_low_target): Remove the op field.
2250 * linux-aarch64-low.cc (class aarch64_target) <low_arch_setup>: New
2251 declaration.
2252 (aarch64_arch_setup): Turn into ...
2253 (aarch64_target::low_arch_setup): ...this.
2254 (the_low_target): Remove the op field.
2255 * linux-arm-low.cc (class arm_target) <low_arch_setup>: New
2256 declaration.
2257 (arm_arch_setup): Turn into ...
2258 (arm_target::low_arch_setup): ...this.
2259 (the_low_target): Remove the op field.
2260 * linux-bfin-low.cc (class bfin_target) <low_arch_setup>: New
2261 declaration.
2262 (bfin_arch_setup): Turn into ...
2263 (bfin_target::low_arch_setup): ...this.
2264 (the_low_target): Remove the op field.
2265 * linux-cris-low.cc (class cris_target) <low_arch_setup>: New
2266 declaration.
2267 (cris_arch_setup): Turn into ...
2268 (cris_target::low_arch_setup): ...this.
2269 (the_low_target): Remove the op field.
2270 * linux-crisv32-low.cc (class crisv32_target) <low_arch_setup>: New
2271 declaration.
2272 (crisv32_arch_setup): Turn into ...
2273 (crisv32_target::low_arch_setup): ...this.
2274 (the_low_target): Remove the op field.
2275 * linux-ia64-low.cc (class ia64_target) <low_arch_setup>: New
2276 declaration.
2277 (ia64_arch_setup): Turn into ...
2278 (ia64_target::low_arch_setup): ...this.
2279 (the_low_target): Remove the op field.
2280 * linux-m32r-low.cc (class m32r_target) <low_arch_setup>: New
2281 declaration.
2282 (m32r_arch_setup): Turn into ...
2283 (m32r_target::low_arch_setup): ...this.
2284 (the_low_target): Remove the op field.
2285 * linux-m68k-low.cc (class m68k_target) <low_arch_setup>: New
2286 declaration.
2287 (m68k_arch_setup): Turn into ...
2288 (m68k_target::low_arch_setup): ...this.
2289 (the_low_target): Remove the op field.
2290 * linux-mips-low.cc (class mips_target) <low_arch_setup>: New
2291 declaration.
2292 (mips_arch_setup): Turn into ...
2293 (mips_target::low_arch_setup): ...this.
2294 (the_low_target): Remove the op field.
2295 * linux-nios2-low.cc (class nios2_target) <low_arch_setup>: New
2296 declaration.
2297 (nios2_arch_setup): Turn into ...
2298 (nios2_target::low_arch_setup): ...this.
2299 (the_low_target): Remove the op field.
2300 * linux-ppc-low.cc (class ppc_target) <low_arch_setup>: New
2301 declaration.
2302 (ppc_arch_setup): Turn into ...
2303 (ppc_target::low_arch_setup): ...this.
2304 (the_low_target): Remove the op field.
2305 * linux-riscv-low.cc (class riscv_target) <low_arch_setup>: New
2306 declaration.
2307 (riscv_arch_setup): Turn into ...
2308 (riscv_target::low_arch_setup): ...this.
2309 (the_low_target): Remove the op field.
2310 * linux-s390-low.cc (class s390_target) <low_arch_setup>: New
2311 declaration.
2312 (s390_arch_setup): Turn into ...
2313 (s390_target::low_arch_setup): ...this.
2314 (the_low_target): Remove the op field.
2315 * linux-sh-low.cc (class sh_target) <low_arch_setup>: New
2316 declaration.
2317 (sh_arch_setup): Turn into ...
2318 (sh_target::low_arch_setup): ...this.
2319 (the_low_target): Remove the op field.
2320 * linux-sparc-low.cc (class sparc_target) <low_arch_setup>: New
2321 declaration.
2322 (sparc_arch_setup): Turn into ...
2323 (sparc_target::low_arch_setup): ...this.
2324 (the_low_target): Remove the op field.
2325 * linux-tic6x-low.cc (class tic6x_target) <low_arch_setup>: New
2326 declaration.
2327 (tic6x_arch_setup): Turn into ...
2328 (tic6x_target::low_arch_setup): ...this.
2329 (the_low_target): Remove the op field.
2330 * linux-tile-low.cc (class tile_target) <low_arch_setup>: New
2331 declaration.
2332 (tile_arch_setup): Turn into ...
2333 (tile_target::low_arch_setup): ...this.
2334 (the_low_target): Remove the op field.
2335 * linux-xtensa-low.cc (class xtensa_target) <low_arch_setup>: New
2336 declaration.
2337 (xtensa_arch_setup): Turn into ...
2338 (xtensa_target::low_arch_setup): ...this.
2339 (the_low_target): Remove the op field.
2340
2341 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2342
2343 * linux-low.h (the_linux_target): New extern declaration.
2344 * linux-low.cc (initialize_low): Use 'the_linux_target' to set
2345 'the_target'.
2346 (the_linux_target): Remove.
2347 * linux-x86-low.cc (class x86_target): New class.
2348 (the_x86_target): New static object.
2349 (the_linux_target): Define as pointer to the_x86_target.
2350 * linux-aarch64-low.cc (class aarch64_target): New class.
2351 (the_aarch64_target): New static object.
2352 (the_linux_target): Define as pointer to the_aarch64_target.
2353 * linux-arm-low.cc (class arm_target): New class.
2354 (the_arm_target): New static object.
2355 (the_linux_target): Define as pointer to the_arm_target.
2356 * linux-bfin-low.cc (class bfin_target): New class.
2357 (the_bfin_target): New static object.
2358 (the_linux_target): Define as pointer to the_bfin_target.
2359 * linux-cris-low.cc (class cris_target): New class.
2360 (the_cris_target): New static object.
2361 (the_linux_target): Define as pointer to the_cris_target.
2362 * linux-crisv32-low.cc (class crisv32_target): New class.
2363 (the_crisv32_target): New static object.
2364 (the_linux_target): Define as pointer to the_crisv32_target.
2365 * linux-ia64-low.cc (class ia64_target): New class.
2366 (the_ia64_target): New static object.
2367 (the_linux_target): Define as pointer to the_ia64_target.
2368 * linux-m32r-low.cc (class m32r_target): New class.
2369 (the_m32r_target): New static object.
2370 (the_linux_target): Define as pointer to the_m32r_target.
2371 * linux-m68k-low.cc (class m68k_target): New class.
2372 (the_m68k_target): New static object.
2373 (the_linux_target): Define as pointer to the_m68k_target.
2374 * linux-mips-low.cc (class mips_target): New class.
2375 (the_mips_target): New static object.
2376 (the_linux_target): Define as pointer to the_mips_target.
2377 * linux-nios2-low.cc (class nios2_target): New class.
2378 (the_nios2_target): New static object.
2379 (the_linux_target): Define as pointer to the_nios2_target.
2380 * linux-ppc-low.cc (class ppc_target): New class.
2381 (the_ppc_target): New static object.
2382 (the_linux_target): Define as pointer to the_ppc_target.
2383 * linux-riscv-low.cc (class riscv_target): New class.
2384 (the_riscv_target): New static object.
2385 (the_linux_target): Define as pointer to the_riscv_target.
2386 * linux-s390-low.cc (class s390_target): New class.
2387 (the_s390_target): New static object.
2388 (the_linux_target): Define as pointer to the_s390_target.
2389 * linux-sh-low.cc (class sh_target): New class.
2390 (the_sh_target): New static object.
2391 (the_linux_target): Define as pointer to the_sh_target.
2392 * linux-sparc-low.cc (class sparc_target): New class.
2393 (the_sparc_target): New static object.
2394 (the_linux_target): Define as pointer to the_sparc_target.
2395 * linux-tic6x-low.cc (class tic6x_target): New class.
2396 (the_tic6x_target): New static object.
2397 (the_linux_target): Define as pointer to the_tic6x_target.
2398 * linux-tile-low.cc (class tile_target): New class.
2399 (the_tile_target): New static object.
2400 (the_linux_target): Define as pointer to the_tile_target.
2401 * linux-xtensa-low.cc (class xtensa_target): New class.
2402 (the_xtensa_target): New static object.
2403 (the_linux_target): Define as pointer to the_xtensa_target.
2404
2405 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2406
2407 Turn some static functions in linux-low.cc into private methods of
2408 linux_process_target.
2409
2410 * linux-low.cc (handle_extended_wait): Turn into ...
2411 (linux_process_target::handle_extended_wait): ...this. Call
2412 'mourn' on 'this' object instead of 'the_target'.
2413 (maybe_move_out_of_jump_pad): Turn into...
2414 (linux_process_target::maybe_move_out_of_jump_pad): ...this.
2415 (linux_low_filter_event): Turn into...
2416 (linux_process_target::filter_event): ...this.
2417 (linux_wait_for_event_filtered): Turn into...
2418 (linux_process_target::wait_for_event_filtered): ...this.
2419 (linux_wait_for_event): Turn into...
2420 (linux_process_target::wait_for_event): ...this.
2421 (linux_wait_1): Turn into...
2422 (linux_process_target::wait_1): ...this.
2423 (wait_for_sigstop): Turn into...
2424 (linux_process_target::wait_for_sigstop): ...this.
2425 (move_out_of_jump_pad_callback): Turn into...
2426 (linux_process_target::move_out_of_jump_pad): ...this.
2427 (stop_all_lwps): Turn into...
2428 (linux_process_target::stop_all_lwps): ...this.
2429 (start_step_over): Turn into...
2430 (linux_process_target::start_step_over): ...this.
2431 (complete_ongoing_step_over): Turn into...
2432 (linux_process_target::complete_ongoing_step_over): ...this.
2433 (proceed_all_lwps): Turn into...
2434 (linux_process_target::proceed_all_lwps): ...this.
2435 (unstop_all_lwps): Turn into...
2436 (linux_process_target::unstop_all_lwps): ...this.
2437
2438 * linux-low.h (class linux_process_target)
2439 <handle_extended_wait>
2440 <maybe_move_out_of_jump_pad>
2441 filter_event>
2442 <wait_for_event_filtered>
2443 <wait_for_event>
2444 <wait_1>
2445 <wait_for_sigstop>
2446 <move_out_of_jump_pad>
2447 <stop_all_lwps>
2448 <start_step_over>
2449 <complete_ongoing_step_over>
2450 <proceed_all_lwps>
2451 <unstop_all_lwps>: Declare.
2452
2453 Update the callers below.
2454
2455 * linux-low.cc (linux_process_target::attach): Update.
2456 (linux_process_target::stabilize_threads): Ditto.
2457 (linux_process_target::wait): Ditto.
2458
2459 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2460
2461 * linux-low.h (struct linux_target_ops): Update the comment for
2462 'cannot_store_register' to return 0 or 1.
2463 * linux-ppc-low.cc (ppc_cannot_store_register): Return 1 instead
2464 of 2.
2465
2466 2020-03-20 Simon Marchi <simon.marchi@efficios.com>
2467
2468 * config.in: Re-generate.
2469 * configure: Re-generate.
2470
2471 2020-03-17 Kamil Rytarowski <n54@gmx.com>
2472
2473 * regcache.cc (find_register_by_number): Update.
2474 * tdesc.cc (init_target_desc): Likewise.
2475 * tdesc.h (target_desc::reg_defs): Likewise.
2476
2477 2020-03-12 Tom Tromey <tom@tromey.com>
2478
2479 * configure: Rebuild.
2480 * configure.ac (GDBSERVER_DEPFILES): Remove srv_selftest_objs.
2481 (WIN32APILIBS): New subst.
2482 * Makefile.in (SFILES, OBS, TAGS, GDBREPLAY_OBS): Remove
2483 gdbsupport files.
2484 (gdbsupport/%.o): Remove target.
2485 (GDBSUPPORT_BUILDDIR, GDBSUPPORT): New variables.
2486 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Add GDBSUPPORT.
2487 (WIN32APILIBS): New variable.
2488 (gdbserver$(EXEEXT)): Add WIN32APILIBS.
2489 (gdbreplay$(EXEEXT)): Likewise.
2490
2491 2020-03-12 Tom Tromey <tom@tromey.com>
2492
2493 * config.in, configure: Rebuild.
2494 * configure.ac: Call ZW_GNU_GETTEXT_SISTER_DIR.
2495 * acinclude.m4: Include gettext-sister.m4.
2496 * Makefile.in (top_builddir, INTL, INTL_DEPS, INTL_CFLAGS): New
2497 variables.
2498 (INCLUDE_CFLAGS): Add INTL_CFLAGS.
2499 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Use INTL_DEPS, INTL.
2500
2501 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
2502
2503 * acinclude.m4: Update path to selftest.m4.
2504
2505 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
2506
2507 * configure.ac: Don't source bfd/development.sh, move
2508 GDB_AC_COMMON higher.
2509 * configure: Re-generate.
2510
2511 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
2512
2513 * configure: Re-generate.
2514
2515 2020-03-11 Simon Marchi <simon.marchi@efficios.com>
2516
2517 * configure: Re-generate.
2518
2519 2020-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
2520
2521 * .dir-locals.el: New file.
2522
2523 2020-03-05 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2524
2525 * .gitattributes: New file.
2526
2527 2020-03-02 Andrew Burgess <andrew.burgess@embecosm.com>
2528
2529 * remote-utils.cc (prepare_resume_reply): Add ability to convert T
2530 reply into an S reply.
2531 * server.cc (disable_packet_T): New global.
2532 (captured_main): Set new global when appropriate.
2533 * server.h (disable_packet_T): Declare.
2534
2535 2020-02-21 Tom Tromey <tom@tromey.com>
2536
2537 * Makefile.in (mostlyclean): New target.
2538
2539 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2540
2541 * target.h (struct process_stratum_target): Remove.
2542 (class process_target): Rename to ...
2543 (class process_stratum_target): ... this.
2544 * linux-low.h (class linux_process_target): Derive from
2545 'process_stratum_target'.
2546 * linux-low.cc (linux_target_ops): Remove.
2547 (initialize_low): Set the_target to the singleton instance of
2548 linux_process_target.
2549 * lynx-low.h (class lynx_process_target): Derive from
2550 'process_stratum_target'.
2551 * lynx-low.cc (lynx_target_ops): Remove.
2552 (initialize_low): Set the_target to the singleton instance of
2553 lynx_process_target.
2554 * nto-low.h (class nto_process_target): Derive from
2555 'process_stratum_target'.
2556 * nto-low.cc (nto_target_ops): Remove.
2557 (initialize_low): Set the_target to the singleton instance of
2558 nto_process_target.
2559 * win32-low.h (class win32_process_target): Derive from
2560 'process_stratum_target'.
2561 * win32-low.cc (win32_target_ops): Remove.
2562 (initialize_low): Set the_target to the singleton instance of
2563 win32_process_target.
2564
2565 Replace 'the_target->pt' with 'the_target' in the uses below.
2566
2567 * hostio.cc (hostio_error)
2568 (handle_setfs)
2569 (handle_open)
2570 (handle_unlink)
2571 (handle_readlink)
2572 * linux-aarch32-low.cc (arm_breakpoint_at)
2573 * linux-aarch64-low.cc (aarch64_breakpoint_at)
2574 * linux-arm-low.cc (arm_sigreturn_next_pc)
2575 (arm_get_hwcap)
2576 (arm_get_syscall_trapinfo)
2577 * linux-cris-low.cc (cris_breakpoint_at)
2578 * linux-crisv32-low.cc (cris_breakpoint_at)
2579 * linux-low.cc (handle_extended_wait)
2580 (linux_wait_1)
2581 (linux_read_memory)
2582 (linux_process_target::breakpoint_kind_from_pc)
2583 (linux_get_auxv)
2584 * linux-m32r-low.cc (m32r_breakpoint_at)
2585 * linux-mips-low.cc (mips_breakpoint_at)
2586 * linux-nios2-low.cc (nios2_breakpoint_at)
2587 * linux-ppc-low.cc (ppc_breakpoint_at)
2588 * linux-s390-low.cc (s390_get_hwcap)
2589 * linux-sh-low.cc (sh_breakpoint_at)
2590 * linux-sparc-low.cc (sparc_fill_gregset_to_stack)
2591 (sparc_store_gregset_from_stack)
2592 (sparc_breakpoint_at)
2593 * linux-tic6x-low.cc (tic6x_breakpoint_at)
2594 * linux-tile-low.cc (tile_breakpoint_at)
2595 * linux-x86-low.cc (x86_breakpoint_at)
2596 * linux-xtensa-low.cc (xtensa_breakpoint_at)
2597 * mem-break.cc (bp_size)
2598 (bp_opcode)
2599 (insert_memory_breakpoint)
2600 (set_raw_breakpoint_at)
2601 (delete_raw_breakpoint)
2602 (z_type_supported)
2603 (uninsert_raw_breakpoint)
2604 (reinsert_raw_breakpoint)
2605 (validate_inserted_breakpoint)
2606 * regcache.cc (regcache_read_pc)
2607 (regcache_write_pc)
2608 * remote-utils.cc (putpkt_binary_1)
2609 (input_interrupt)
2610 (getpkt)
2611 (prepare_resume_reply)
2612 * server.cc (handle_general_set)
2613 (handle_detach)
2614 (handle_qxfer_auxv)
2615 (handle_qxfer_exec_file)
2616 (handle_qxfer_libraries_svr4)
2617 (handle_qxfer_osdata)
2618 (handle_qxfer_siginfo)
2619 (handle_qxfer_fdpic)
2620 (handle_query)
2621 (resume)
2622 (handle_v_requests)
2623 (queue_stop_reply_callback)
2624 (captured_main)
2625 * target.cc (prepare_to_access_memory)
2626 (done_accessing_memory)
2627 (read_inferior_memory)
2628 (target_write_memory)
2629 (target_stop_and_wait)
2630 (target_wait)
2631 (target_mourn_inferior)
2632 (target_continue_no_signal)
2633 (target_continue)
2634 (target_supports_multi_process)
2635 (kill_inferior)
2636 * target.h
2637 (target_create_inferior)
2638 (target_post_create_inferior)
2639 (myattach)
2640 (target_supports_fork_events)
2641 (target_supports_vfork_events)
2642 (target_supports_exec_events)
2643 (target_handle_new_gdb_connection)
2644 (detach_inferior)
2645 (mythread_alive)
2646 (fetch_inferior_registers)
2647 (store_inferior_registers)
2648 (join_inferior)
2649 (target_supports_non_stop)
2650 (target_async)
2651 (target_process_qsupported)
2652 (target_supports_catch_syscall)
2653 (target_get_ipa_tdesc_idx)
2654 (target_supports_tracepoints)
2655 (target_supports_fast_tracepoints)
2656 (target_get_min_fast_tracepoint_insn_len)
2657 (target_thread_stopped)
2658 (target_pause_all)
2659 (target_unpause_all)
2660 (target_stabilize_threads)
2661 (target_install_fast_tracepoint_jump_pad)
2662 (target_emit_ops)
2663 (target_supports_disable_randomization)
2664 (target_supports_agent)
2665 (target_enable_btrace)
2666 (target_disable_btrace)
2667 (target_read_btrace)
2668 (target_read_btrace_conf)
2669 (target_supports_range_stepping)
2670 (target_supports_stopped_by_sw_breakpoint)
2671 (target_stopped_by_sw_breakpoint)
2672 (target_supports_stopped_by_hw_breakpoint)
2673 (target_supports_hardware_single_step)
2674 (target_stopped_by_hw_breakpoint)
2675 (target_breakpoint_kind_from_pc)
2676 (target_breakpoint_kind_from_current_state)
2677 (target_supports_software_single_step)
2678 (target_core_of_thread)
2679 (target_thread_name)
2680 (target_thread_handle)
2681 * win32-low.cc (do_initial_child_stuff)
2682
2683 Rename target op default definitions listed below.
2684
2685 * target.cc (process_target::post_create_inferior): Rename as ...
2686 (process_stratum_target::post_create_inferior): ... this.
2687 (process_target::prepare_to_access_memory): Rename as ...
2688 (process_stratum_target::prepare_to_access_memory): ... this.
2689 (process_target::done_accessing_memory): Rename as ...
2690 (process_stratum_target::done_accessing_memory): ... this.
2691 (process_target::look_up_symbols): Rename as ...
2692 (process_stratum_target::look_up_symbols): ... this.
2693 (process_target::supports_read_auxv): Rename as ...
2694 (process_stratum_target::supports_read_auxv): ... this.
2695 (process_target::read_auxv): Rename as ...
2696 (process_stratum_target::read_auxv): ... this.
2697 (process_target::supports_z_point_type): Rename as ...
2698 (process_stratum_target::supports_z_point_type): ... this.
2699 (process_target::insert_point): Rename as ...
2700 (process_stratum_target::insert_point): ... this.
2701 (process_target::remove_point): Rename as ...
2702 (process_stratum_target::remove_point): ... this.
2703 (process_target::stopped_by_sw_breakpoint): Rename as ...
2704 (process_stratum_target::stopped_by_sw_breakpoint): ... this.
2705 (process_target::supports_stopped_by_sw_breakpoint): Rename as ...
2706 (process_stratum_target::supports_stopped_by_sw_breakpoint): ... this.
2707 (process_target::stopped_by_hw_breakpoint): Rename as ...
2708 (process_stratum_target::stopped_by_hw_breakpoint): ... this.
2709 (process_target::supports_stopped_by_hw_breakpoint): Rename as ...
2710 (process_stratum_target::supports_stopped_by_hw_breakpoint): ... this.
2711 (process_target::supports_hardware_single_step): Rename as ...
2712 (process_stratum_target::supports_hardware_single_step): ... this.
2713 (process_target::stopped_by_watchpoint): Rename as ...
2714 (process_stratum_target::stopped_by_watchpoint): ... this.
2715 (process_target::stopped_data_address): Rename as ...
2716 (process_stratum_target::stopped_data_address): ... this.
2717 (process_target::supports_read_offsets): Rename as ...
2718 (process_stratum_target::supports_read_offsets): ... this.
2719 (process_target::read_offsets): Rename as ...
2720 (process_stratum_target::read_offsets): ... this.
2721 (process_target::supports_get_tls_address): Rename as ...
2722 (process_stratum_target::supports_get_tls_address): ... this.
2723 (process_target::get_tls_address): Rename as ...
2724 (process_stratum_target::get_tls_address): ... this.
2725 (process_target::hostio_last_error): Rename as ...
2726 (process_stratum_target::hostio_last_error): ... this.
2727 (process_target::supports_qxfer_osdata): Rename as ...
2728 (process_stratum_target::supports_qxfer_osdata): ... this.
2729 (process_target::qxfer_osdata): Rename as ...
2730 (process_stratum_target::qxfer_osdata): ... this.
2731 (process_target::supports_qxfer_siginfo): Rename as ...
2732 (process_stratum_target::supports_qxfer_siginfo): ... this.
2733 (process_target::qxfer_siginfo): Rename as ...
2734 (process_stratum_target::qxfer_siginfo): ... this.
2735 (process_target::supports_non_stop): Rename as ...
2736 (process_stratum_target::supports_non_stop): ... this.
2737 (process_target::async): Rename as ...
2738 (process_stratum_target::async): ... this.
2739 (process_target::start_non_stop): Rename as ...
2740 (process_stratum_target::start_non_stop): ... this.
2741 (process_target::supports_multi_process): Rename as ...
2742 (process_stratum_target::supports_multi_process): ... this.
2743 (process_target::supports_fork_events): Rename as ...
2744 (process_stratum_target::supports_fork_events): ... this.
2745 (process_target::supports_vfork_events): Rename as ...
2746 (process_stratum_target::supports_vfork_events): ... this.
2747 (process_target::supports_exec_events): Rename as ...
2748 (process_stratum_target::supports_exec_events): ... this.
2749 (process_target::handle_new_gdb_connection): Rename as ...
2750 (process_stratum_target::handle_new_gdb_connection): ... this.
2751 (process_target::handle_monitor_command): Rename as ...
2752 (process_stratum_target::handle_monitor_command): ... this.
2753 (process_target::core_of_thread): Rename as ...
2754 (process_stratum_target::core_of_thread): ... this.
2755 (process_target::supports_read_loadmap): Rename as ...
2756 (process_stratum_target::supports_read_loadmap): ... this.
2757 (process_target::read_loadmap): Rename as ...
2758 (process_stratum_target::read_loadmap): ... this.
2759 (process_target::process_qsupported): Rename as ...
2760 (process_stratum_target::process_qsupported): ... this.
2761 (process_target::supports_tracepoints): Rename as ...
2762 (process_stratum_target::supports_tracepoints): ... this.
2763 (process_target::read_pc): Rename as ...
2764 (process_stratum_target::read_pc): ... this.
2765 (process_target::write_pc): Rename as ...
2766 (process_stratum_target::write_pc): ... this.
2767 (process_target::supports_thread_stopped): Rename as ...
2768 (process_stratum_target::supports_thread_stopped): ... this.
2769 (process_target::thread_stopped): Rename as ...
2770 (process_stratum_target::thread_stopped): ... this.
2771 (process_target::supports_get_tib_address): Rename as ...
2772 (process_stratum_target::supports_get_tib_address): ... this.
2773 (process_target::get_tib_address): Rename as ...
2774 (process_stratum_target::get_tib_address): ... this.
2775 (process_target::pause_all): Rename as ...
2776 (process_stratum_target::pause_all): ... this.
2777 (process_target::unpause_all): Rename as ...
2778 (process_stratum_target::unpause_all): ... this.
2779 (process_target::stabilize_threads): Rename as ...
2780 (process_stratum_target::stabilize_threads): ... this.
2781 (process_target::supports_fast_tracepoints): Rename as ...
2782 (process_stratum_target::supports_fast_tracepoints): ... this.
2783 (process_target::get_min_fast_tracepoint_insn_len): Rename as ...
2784 (process_stratum_target::get_min_fast_tracepoint_insn_len): ... this.
2785 (process_target::emit_ops): Rename as ...
2786 (process_stratum_target::emit_ops): ... this.
2787 (process_target::supports_disable_randomization): Rename as ...
2788 (process_stratum_target::supports_disable_randomization): ... this.
2789 (process_target::supports_qxfer_libraries_svr4): Rename as ...
2790 (process_stratum_target::supports_qxfer_libraries_svr4): ... this.
2791 (process_target::qxfer_libraries_svr4): Rename as ...
2792 (process_stratum_target::qxfer_libraries_svr4): ... this.
2793 (process_target::supports_agent): Rename as ...
2794 (process_stratum_target::supports_agent): ... this.
2795 (process_target::enable_btrace): Rename as ...
2796 (process_stratum_target::enable_btrace): ... this.
2797 (process_target::disable_btrace): Rename as ...
2798 (process_stratum_target::disable_btrace): ... this.
2799 (process_target::read_btrace): Rename as ...
2800 (process_stratum_target::read_btrace): ... this.
2801 (process_target::read_btrace_conf): Rename as ...
2802 (process_stratum_target::read_btrace_conf): ... this.
2803 (process_target::supports_range_stepping): Rename as ...
2804 (process_stratum_target::supports_range_stepping): ... this.
2805 (process_target::supports_pid_to_exec_file): Rename as ...
2806 (process_stratum_target::supports_pid_to_exec_file): ... this.
2807 (process_target::pid_to_exec_file): Rename as ...
2808 (process_stratum_target::pid_to_exec_file): ... this.
2809 (process_target::supports_multifs): Rename as ...
2810 (process_stratum_target::supports_multifs): ... this.
2811 (process_target::multifs_open): Rename as ...
2812 (process_stratum_target::multifs_open): ... this.
2813 (process_target::multifs_unlink): Rename as ...
2814 (process_stratum_target::multifs_unlink): ... this.
2815 (process_target::multifs_readlink): Rename as ...
2816 (process_stratum_target::multifs_readlink): ... this.
2817 (process_target::breakpoint_kind_from_pc): Rename as ...
2818 (process_stratum_target::breakpoint_kind_from_pc): ... this.
2819 (process_target::breakpoint_kind_from_current_state): Rename as ...
2820 (process_stratum_target::breakpoint_kind_from_current_state): ... this.
2821 (process_target::thread_name): Rename as ...
2822 (process_stratum_target::thread_name): ... this.
2823 (process_target::thread_handle): Rename as ...
2824 (process_stratum_target::thread_handle): ... this.
2825 (process_target::supports_software_single_step): Rename as ...
2826 (process_stratum_target::supports_software_single_step): ... this.
2827 (process_target::supports_catch_syscall): Rename as ...
2828 (process_stratum_target::supports_catch_syscall): ... this.
2829 (process_target::get_ipa_tdesc_idx): Rename as ...
2830 (process_stratum_target::get_ipa_tdesc_idx): ... this.
2831
2832 2020-02-20 Pedro Alves <palves@redhat.com>
2833
2834 * target.cc (set_target_ops): Simply copy the given target pointer
2835 instead of creating a copy of the pointed object.
2836
2837 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2838
2839 Turn process_stratum_target's get_ipa_tdesc_idx op into a method
2840 of process_target.
2841
2842 * target.h (struct process_stratum_target): Remove the target op.
2843 (class process_target): Add the target op.
2844 (target_get_ipa_tdesc_idx): Update the macro.
2845 * target.cc (process_target::get_ipa_tdesc_idx): Define.
2846
2847 Update the derived classes and callers below.
2848
2849 * linux-low.cc (linux_target_ops): Update.
2850 (linux_get_ipa_tdesc_idx): Turn into ...
2851 (linux_process_target::get_ipa_tdesc_idx): ... this.
2852 * linux-low.h (class linux_process_target): Update.
2853 * lynx-low.cc (lynx_target_ops): Update.
2854 * nto-low.cc (nto_target_ops): Update.
2855 * win32-low.cc (win32_target_ops): Update.
2856
2857 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2858
2859 Turn process_stratum_target's supports_catch_syscall op into a
2860 method of process_target.
2861
2862 * target.h (struct process_stratum_target): Remove the target op.
2863 (class process_target): Add the target op.
2864 (target_supports_catch_syscall): Update the macro.
2865 * target.cc (process_target::supports_catch_syscall): Define.
2866
2867 Update the derived classes and callers below.
2868
2869 * linux-low.cc (linux_target_ops): Update.
2870 (linux_supports_catch_syscall): Turn into ...
2871 (linux_process_target::supports_catch_syscall): ... this.
2872 * linux-low.h (class linux_process_target): Update.
2873 * lynx-low.cc (lynx_target_ops): Update.
2874 * nto-low.cc (nto_target_ops): Update.
2875 * win32-low.cc (win32_target_ops): Update.
2876
2877 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2878
2879 Turn process_stratum_target's supports_software_single_step op
2880 into a method of process_target.
2881
2882 * target.h (struct process_stratum_target): Remove the target op.
2883 (class process_target): Add the target op.
2884 (target_supports_software_single_step): Update the macro.
2885 * target.cc (process_target::supports_software_single_step): Define.
2886
2887 Update the derived classes and callers below.
2888
2889 * linux-low.cc (linux_target_ops): Update.
2890 (linux_supports_software_single_step): Turn into ...
2891 (linux_process_target::supports_software_single_step): ... this.
2892 * linux-low.h (class linux_process_target): Update.
2893 * lynx-low.cc (lynx_target_ops): Update.
2894 * nto-low.cc (nto_target_ops): Update.
2895 * win32-low.cc (win32_target_ops): Update.
2896
2897 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2898
2899 Turn process_stratum_target's thread_name and thread_handle ops
2900 into methods of process_target.
2901
2902 * target.h (struct process_stratum_target): Remove the target ops.
2903 (class process_target): Add the target ops.
2904 (target_thread_name): Update the macro.
2905 (target_thread_handle): Update the macro.
2906 * target.cc (process_target::thread_name): Define.
2907 (process_target::thread_handle): Define.
2908
2909 Update the derived classes and callers below.
2910
2911 * linux-low.cc (linux_target_ops): Update.
2912 (linux_process_target::thread_name): Define.
2913 (linux_process_target::thread_handle): Define.
2914 * linux-low.h (class linux_process_target): Update.
2915 * lynx-low.cc (lynx_target_ops): Update.
2916 * nto-low.cc (nto_target_ops): Update.
2917 * win32-low.cc (win32_target_ops): Update.
2918
2919 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2920
2921 Turn process_stratum_target's breakpoint_kind_from_pc,
2922 sw_breakpoint_from_kind, and breakpoint_kind_from_current_state
2923 ops into methods of process_target.
2924
2925 * target.h (struct process_stratum_target): Remove the target op.
2926 (class process_target): Add the target op.
2927 (target_breakpoint_kind_from_pc): Update the macro.
2928 (target_breakpoint_kind_from_current_state): Update the macro.
2929 (default_breakpoint_kind_from_pc): Remove declaration.
2930 * target.cc (default_breakpoint_kind_from_pc): Turn into ...
2931 (process_target::breakpoint_kind_from_pc): ... this.
2932 (process_target::breakpoint_kind_from_current_state): Define.
2933
2934 Update the derived classes and callers below.
2935
2936 * mem-break.cc (bp_size): Update.
2937 (bp_opcode): Update.
2938 * linux-low.cc (linux_target_ops): Update.
2939 (linux_wait_1): Update.
2940 (linux_breakpoint_kind_from_pc): Turn into ...
2941 (linux_process_target::breakpoint_kind_from_pc): ... this.
2942 (linux_sw_breakpoint_from_kind): Turn into ...
2943 (linux_process_target::sw_breakpoint_from_kind): ... this.
2944 (linux_breakpoint_kind_from_current_state): Turn into ...
2945 (linux_process_target::breakpoint_kind_from_current_state): ... this.
2946 * linux-low.h (class linux_process_target): Update.
2947 * lynx-low.cc (lynx_target_ops): Update.
2948 (lynx_process_target::sw_breakpoint_from_kind): Define.
2949 * lynx-low.h (class lynx_process_target): Update.
2950 * nto-low.cc (nto_target_ops): Update.
2951 (nto_sw_breakpoint_from_kind): Turn into ...
2952 (nto_process_target::sw_breakpoint_from_kind): ... this.
2953 * nto-low.h (class nto_process_target): Update.
2954 * win32-low.cc (win32_target_ops): Update.
2955 (win32_sw_breakpoint_from_kind): Turn into ...
2956 (win32_process_target::sw_breakpoint_from_kind): ... this.
2957 * win32-low.h (class win32_process_target): Update.
2958
2959 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2960
2961 Turn process_stratum_target's multifs_open, multifs_readlink,
2962 multifs_unlink ops into methods of process_target.
2963
2964 * target.h (struct process_stratum_target): Remove the target ops.
2965 (class process_target): Add the target ops. Also add
2966 'supports_multifs'.
2967 * target.cc: Include "fcntl.h", "unistd.h", "sys/types.h", and
2968 "sys/stat.h".
2969 (process_target::supports_multifs): Define.
2970 (process_target::multifs_open): Define.
2971 (process_target::multifs_readlink): Define.
2972 (process_target::multifs_unlink): Define.
2973
2974 Update the derived classes and callers below.
2975
2976 * hostio.cc (handle_setfs): Update.
2977 (handle_open): Update.
2978 (handle_unlink): Update.
2979 (handle_readlink): Update.
2980 * linux-low.cc (linux_target_ops): Update.
2981 (linux_process_target::supports_multifs): Define.
2982 (linux_process_target::multifs_open): Define.
2983 (linux_process_target::multifs_readlink): Define.
2984 (linux_process_target::multifs_unlink): Define.
2985 * linux-low.h (class linux_process_target): Update.
2986 * lynx-low.cc (lynx_target_ops): Update.
2987 * nto-low.cc (nto_target_ops): Update.
2988 * win32-low.cc (win32_target_ops): Update.
2989
2990 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2991
2992 Turn process_stratum_target's pid_to_exec_file op into a method
2993 of process_target.
2994
2995 * target.h (struct process_stratum_target): Remove the target op.
2996 (class process_target): Add the target op. Also add
2997 'supports_pid_to_exec_file'.
2998 * target.cc (process_target::pid_to_exec_file): Define.
2999 (process_target::supports_pid_to_exec_file): Define.
3000
3001 Update the derived classes and callers below.
3002
3003 * server.cc (handle_qxfer_exec_file): Update.
3004 (handle_query): Update.
3005 * linux-low.cc (linux_target_ops): Update.
3006 (linux_process_target::supports_pid_to_exec_file): Define.
3007 (linux_process_target::pid_to_exec_file): Define.
3008 * linux-low.h (class linux_process_target): Update.
3009 * lynx-low.cc (lynx_target_ops): Update.
3010 * nto-low.cc (nto_target_ops): Update.
3011 * win32-low.cc (win32_target_ops): Update.
3012
3013 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3014
3015 Turn process_stratum_target's supports_range_stepping op into a
3016 method of process_target.
3017
3018 * target.h (struct process_stratum_target): Remove the target op.
3019 (class process_target): Add the target op.
3020 (target_supports_range_stepping): Update the macro.
3021 * target.cc (process_target::supports_range_stepping): Define.
3022
3023 Update the derived classes and callers below.
3024
3025 * linux-low.cc (linux_target_ops): Update.
3026 (linux_supports_range_stepping): Turn into ...
3027 (linux_process_target::supports_range_stepping): ... this.
3028 * linux-low.h (class linux_process_target): Update.
3029 * lynx-low.cc (lynx_target_ops): Update.
3030 * nto-low.cc (nto_target_ops): Update.
3031 * win32-low.cc (win32_target_ops): Update.
3032
3033 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3034
3035 Turn process_stratum_target's btrace-related ops (enable_btrace,
3036 disable_btrace, read_btrace, read_btrace_conf) into methods of
3037 process_target.
3038
3039 * target.h (struct process_stratum_target): Remove the target ops.
3040 (class process_target): Add the target ops.
3041 (target_enable_btrace): Update.
3042 (target_disable_btrace): Update.
3043 (target_read_btrace): Update.
3044 (target_read_btrace_conf): Update.
3045 * target.cc (process_target::enable_btrace): Define.
3046 (process_target::disable_btrace): Define.
3047 (process_target::read_btrace): Define.
3048 (process_target::read_btrace_conf): Define.
3049
3050 Update the derived classes and callers below.
3051
3052 * linux-low.cc (linux_target_ops): Update.
3053 (linux_process_target:enable_btrace): Define as a wrapper around
3054 linux_enable_btrace.
3055 (linux_low_disable_btrace): Turn into ...
3056 (linux_process_target::disable_btrace): ... this.
3057 (linux_low_read_btrace): Turn into ...
3058 (linux_process_target::read_btrace): ... this.
3059 (linux_low_btrace_conf): Turn into ...
3060 (linux_process_target::read_btrace_conf): ... this.
3061 * linux-low.h (class linux_process_target): Update.
3062 * lynx-low.cc (lynx_target_ops): Update.
3063 * nto-low.cc (nto_target_ops): Update.
3064 * win32-low.cc (win32_target_ops): Update.
3065
3066 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3067
3068 Turn process_stratum_target's supports_agent op into a method of
3069 process_target.
3070
3071 * target.h (struct process_stratum_target): Remove the target op.
3072 (class process_target): Add the target op.
3073 (target_supports_agent): Update the macro.
3074 * target.cc (process_target::supports_agent): Define.
3075
3076 Update the derived classes and callers below.
3077
3078 * linux-low.cc (linux_target_ops): Update.
3079 (linux_supports_agent): Turn into ...
3080 (linux_process_target::supports_agent): ... this.
3081 * linux-low.h (class linux_process_target): Update.
3082 * lynx-low.cc (lynx_target_ops): Update.
3083 * nto-low.cc (nto_target_ops): Update.
3084 * win32-low.cc (win32_target_ops): Update.
3085
3086 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3087
3088 Turn process_stratum_target's qxfer_libraries_svr4 op into a
3089 method of process_target.
3090
3091 * target.h (struct process_stratum_target): Remove the target op.
3092 (class process_target): Add the target op. Also add
3093 'supports_qxfer_libraries_svr4'.
3094 * target.cc (process_target::qxfer_libraries_svr4): Define.
3095 (process_target::supports_qxfer_libraries_svr4): Define.
3096
3097 Update the derived classes and callers below.
3098
3099 * server.cc (handle_qxfer_libraries_svr4): Update.
3100 (handle_query): Update.
3101 * linux-low.cc (linux_target_ops): Update.
3102 (linux_process_target::supports_qxfer_libraries_svr4): Define.
3103 (linux_qxfer_libraries_svr4): Turn into ...
3104 (linux_process_target::qxfer_libraries_svr4): ... this.
3105 * linux-low.h (class linux_process_target): Update.
3106 * lynx-low.cc (lynx_target_ops): Update.
3107 * nto-low.cc (nto_target_ops): Update.
3108 * win32-low.cc (win32_target_ops): Update.
3109
3110 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3111
3112 Turn process_stratum_target's supports_disable_randomization op
3113 into a method of process_target.
3114
3115 * target.h (struct process_stratum_target): Remove the target op.
3116 (class process_target): Add the target op.
3117 (target_supports_disable_randomization): Update the macro.
3118 * target.cc (process_target::supports_disable_randomization): Define.
3119
3120 Update the derived classes and callers below.
3121
3122 * linux-low.cc (linux_target_ops): Update.
3123 (linux_supports_disable_randomization): Turn into ...
3124 (linux_process_target::supports_disable_randomization): ... this.
3125 * linux-low.h (class linux_process_target): Update.
3126 * lynx-low.cc (lynx_target_ops): Update.
3127 * nto-low.cc (nto_target_ops): Update.
3128 * win32-low.cc (win32_target_ops): Update.
3129
3130 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3131
3132 Turn process_stratum_target's emit_ops op into a method of
3133 process_target.
3134
3135 * target.h (struct process_stratum_target): Remove the target op.
3136 (class process_target): Add the target op.
3137 (target_emit_ops): Update the macro.
3138 * target.cc (process_target::emit_ops): Define.
3139
3140 Update the derived classes and callers below.
3141
3142 * linux-low.cc (linux_target_ops): Update.
3143 (linux_emit_ops): Turn into ...
3144 (linux_process_target::emit_ops): ... this.
3145 * linux-low.h (class linux_process_target): Update.
3146 * lynx-low.cc (lynx_target_ops): Update.
3147 * nto-low.cc (nto_target_ops): Update.
3148 * win32-low.cc (win32_target_ops): Update.
3149
3150 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3151
3152 Turn process_stratum_target's install_fast_tracepoint_jump_pad
3153 and get_min_fast_tracepoint_insn_len ops into methods of
3154 process_target.
3155
3156 * target.h (struct process_stratum_target): Remove the target ops.
3157 (class process_target): Add the target ops. Also add
3158 'supports_fast_tracepoints'.
3159 (target_supports_fast_tracepoints): Update the macro.
3160 (target_get_min_fast_tracepoint_insn_len): Update the macro.
3161 (install_fast_tracepoint_jump_pad): Update and rename the macro
3162 to ...
3163 (target_install_fast_tracepoint_jump_pad): ... this.
3164 * target.cc (process_target::supports_fast_tracepoints): Define.
3165 (process_target::install_fast_tracepoint_jump_pad): Define.
3166 (process_target::get_min_fast_tracepoint_insn_len): Define.
3167
3168 Update the derived classes and callers below.
3169
3170 * tracepoint.cc (install_fast_tracepoint): Update.
3171 * linux-low.cc (linux_target_ops): Update.
3172 (linux_process_target::supports_fast_tracepoints): Define.
3173 (linux_install_fast_tracepoint_jump_pad): Turn into ...
3174 (linux_process_target::install_fast_tracepoint_jump_pad): ... this.
3175 (linux_get_min_fast_tracepoint_insn_len): Turn into ...
3176 (linux_process_target::get_min_fast_tracepoint_insn_len): ... this.
3177 * linux-low.h (class linux_process_target): Update.
3178 * lynx-low.cc (lynx_target_ops): Update.
3179 * nto-low.cc (nto_target_ops): Update.
3180 * win32-low.cc (win32_target_ops): Update.
3181
3182 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3183
3184 Turn process_stratum_target's stabilize_threads op into a
3185 method of process_target.
3186
3187 * target.h (struct process_stratum_target): Remove the target op.
3188 (class process_target): Add the target op.
3189 (target_stabilize_threads): Update the macro.
3190 * target.cc (process_target::stabilize_threads): Define.
3191
3192 Update the derived classes and callers below.
3193
3194 * server.cc (handle_status): Update.
3195 * tracepoint.cc (cmd_qtdp): Update.
3196 (cmd_qtstart): Update.
3197 * linux-low.cc (linux_target_ops): Update.
3198 (linux_stabilize_threads): Turn into ...
3199 (linux_process_target::stabilize_threads): ... this.
3200 (linux_wait_1): Update.
3201 * linux-low.h (class linux_process_target): Update.
3202 * lynx-low.cc (lynx_target_ops): Update.
3203 * nto-low.cc (nto_target_ops): Update.
3204 * win32-low.cc (win32_target_ops): Update.
3205
3206 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3207
3208 Turn process_stratum_target's pause_all and unpause_all ops
3209 into methods of process_target.
3210
3211 * target.h (struct process_stratum_target): Remove the target ops.
3212 (class process_target): Add the target ops.
3213 (pause_all): Update the macro and rename to...
3214 (target_pause_all): ... this.
3215 (unpause_all): Update the macro and rename to...
3216 (target_unpause_all): ... this.
3217 * target.cc (process_target::pause_all): Define.
3218 (process_target::unpause_all): Define.
3219
3220 Update the derived classes and callers below.
3221
3222 * server.cc (handle_status): Update.
3223 * tracepoint.cc (clear_installed_tracepoints): Update.
3224 (cmd_qtdp): Update.
3225 (cmd_qtstart): Update.
3226 (stop_tracing): Update.
3227 (cmd_qtstatus): Update.
3228 (upload_fast_traceframes): Update.
3229 (run_inferior_command): Update.
3230 * linux-low.cc (linux_target_ops): Update.
3231 (linux_pause_all): Turn into ...
3232 (linux_process_target::pause_all): ... this.
3233 (linux_unpause_all): Turn into ...
3234 (linux_process_target::unpause_all): ... this.
3235 (linux_process_target::prepare_to_access_memory): Update.
3236 (linux_process_target::done_accessing_memory): Update.
3237 * linux-low.h (class linux_process_target): Update.
3238 * lynx-low.cc (lynx_target_ops): Update.
3239 * nto-low.cc (nto_target_ops): Update.
3240 * win32-low.cc (win32_target_ops): Update.
3241
3242 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3243
3244 Turn process_stratum_target's get_tib_address op into a method of
3245 process_target.
3246
3247 * target.h (struct process_stratum_target): Remove the target op.
3248 (class process_target): Add the target op. Also add
3249 'supports_get_tib_address'.
3250 * target.cc (process_target::get_tib_address): Define.
3251 (process_target::supports_get_tib_address): Define.
3252
3253 Update the derived classes and callers below.
3254
3255 * server.cc (handle_query): Update.
3256 * linux-low.cc (win32_target_ops): Update.
3257 * lynx-low.cc (lynx_target_ops): Update.
3258 * nto-low.cc (nto_target_ops): Update.
3259 * win32-low.cc (win32_target_ops): Update.
3260 (win32_process_target::supports_get_tib_address): Define.
3261 (win32_get_tib_address): Turn into ...
3262 (win32_process_target::get_tib_address): ... this.
3263 * win32-low.h (class win32_process_target): Update.
3264
3265 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3266
3267 Turn process_stratum_target's thread_stopped op into a method of
3268 process_target.
3269
3270 * target.h (struct process_stratum_target): Remove the target op.
3271 (class process_target): Add the target op. Also add
3272 'supports_thread_stopped'.
3273 (target_thread_stopped): Update the macro.
3274 * target.cc (process_target::thread_stopped): Define.
3275 (process_target::supports_thread_stopped): Define.
3276 (prepare_to_access_memory): Update.
3277
3278 Update the derived classes and callers below.
3279
3280 * server.cc (queue_stop_reply_callback): Update.
3281 * linux-low.cc (linux_target_ops): Update.
3282 (linux_process_target::supports_thread_stopped): Define.
3283 (linux_thread_stopped): Turn into ...
3284 (linux_process_target::thread_stopped): ... this.
3285 * linux-low.h (class linux_process_target): Update.
3286 * lynx-low.cc (lynx_target_ops): Update.
3287 * nto-low.cc (nto_target_ops): Update.
3288 * win32-low.cc (win32_target_ops): Update.
3289
3290 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3291
3292 Turn process_stratum_target's read_pc and write_pc ops into
3293 methods of process_target.
3294
3295 * target.h (struct process_stratum_target): Remove the target ops.
3296 (class process_target): Add the target ops.
3297 * target.cc (process_target::read_pc): Define.
3298 (process_target::write_pc): Define.
3299
3300 Update the derived classes and callers below.
3301
3302 * regcache.cc (regcache_read_pc): Update.
3303 (regcache_write_pc): Update.
3304 * linux-low.cc (linux_target_ops): Update.
3305 (linux_read_pc): Turn into ...
3306 (linux_process_target::read_pc): ... this.
3307 (linux_write_pc): Turn into ...
3308 (linux_process_target::write_pc): ... this.
3309 * linux-low.h (class linux_process_target): Update.
3310 * lynx-low.cc (lynx_target_ops): Update.
3311 * nto-low.cc (nto_target_ops): Update.
3312 * win32-low.cc (win32_target_ops): Update.
3313
3314 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3315
3316 Turn process_stratum_target's supports_tracepoints op into a
3317 method of process_target.
3318
3319 * target.h (struct process_stratum_target): Remove the target op.
3320 (class process_target): Add the target op.
3321 (target_supports_tracepoints): Update the macro.
3322 * target.cc (process_target::supports_tracepoints): Define.
3323
3324 Update the derived classes and callers below.
3325
3326 * linux-low.cc (linux_target_ops): Update.
3327 (linux_supports_tracepoints): Turn into ...
3328 (linux_process_target::supports_tracepoints): ... this.
3329 * linux-low.h (class linux_process_target): Update.
3330 * lynx-low.cc (lynx_target_ops): Update.
3331 * nto-low.cc (nto_target_ops): Update.
3332 * win32-low.cc (win32_target_ops): Update.
3333
3334 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3335
3336 Turn process_stratum_target's process_qsupported op into a method
3337 of process_target.
3338
3339 * target.h (struct process_stratum_target): Remove the target op.
3340 (class process_target): Add the target op.
3341 (target_process_qsupported): Update the macro.
3342 * target.cc (process_target::process_qsupported): Define.
3343
3344 Update the derived classes and callers below.
3345
3346 * linux-low.cc (linux_target_ops): Update.
3347 (linux_process_qsupported): Turn into ...
3348 (linux_process_target::process_qsupported): ... this.
3349 * linux-low.h (class linux_process_target): Update.
3350 * lynx-low.cc (lynx_target_ops): Update.
3351 * nto-low.cc (nto_target_ops): Update.
3352 * win32-low.cc (win32_target_ops): Update.
3353
3354 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3355
3356 Turn process_stratum_target's read_loadmap op into a method of
3357 process_target.
3358
3359 * target.h (struct process_stratum_target): Remove the target op.
3360 (class process_target): Add the target op. Also add
3361 'supports_read_loadmap'.
3362 * target.cc (process_target::read_loadmap): Define.
3363 (process_target::supports_read_loadmap): Define.
3364
3365 Update the derived classes and callers below.
3366
3367 * server.cc (handle_qxfer_fdpic): Update.
3368 (handle_query): Update.
3369 * linux-low.cc (linux_target_ops): Update.
3370 (linux_process_target::supports_read_loadmap): Define.
3371 (linux_read_loadmap): Turn into ...
3372 (linux_process_target::read_loadmap): ... this.
3373 * linux-low.h (class linux_process_target): Update.
3374 * lynx-low.cc (lynx_target_ops): Update.
3375 * nto-low.cc (nto_target_ops): Update.
3376 * win32-low.cc (win32_target_ops): Update.
3377
3378 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3379
3380 Turn process_stratum_target's core_of_thread op into a method of
3381 process_target.
3382
3383 * target.h (struct process_stratum_target): Remove the target op.
3384 (class process_target): Add the target op.
3385 (target_core_of_thread): Update the macro.
3386 * target.cc (process_target::core_of_thread): Define.
3387
3388 Update the derived classes and callers below.
3389
3390 * linux-low.cc (linux_target_ops): Update.
3391 (linux_process_target::core_of_thread): Define.
3392 * linux-low.h (class linux_process_target): Update.
3393 * lynx-low.cc (lynx_target_ops): Update.
3394 * nto-low.cc (nto_target_ops): Update.
3395 * win32-low.cc (win32_target_ops): Update.
3396
3397 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3398
3399 Turn process_stratum_target's handle_monitor_command op into a
3400 method of process_target.
3401
3402 * target.h (struct process_stratum_target): Remove the target op.
3403 (class process_target): Add the target op.
3404 (target_handle_monitor_command): Update the macro.
3405 * target.cc (process_target::handle_monitor_command): Define.
3406
3407 Update the derived classes and callers below.
3408
3409 * server.cc (handle_query): Update.
3410 * linux-low.cc (linux_target_ops): Update.
3411 (linux_process_target::handle_monitor_command): Define.
3412 * linux-low.h (class linux_process_target): Update.
3413 * lynx-low.cc (lynx_target_ops): Update.
3414 * nto-low.cc (nto_target_ops): Update.
3415 * win32-low.cc (win32_target_ops): Update.
3416
3417 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3418
3419 Turn process_stratum_target's handle_new_gdb_connection op into a
3420 method of process_target.
3421
3422 * target.h (struct process_stratum_target): Remove the target op.
3423 (class process_target): Add the target op.
3424 (target_handle_new_gdb_connection): Update the macro.
3425 * target.cc (process_target::handle_new_gdb_connection): Define.
3426
3427 Update the derived classes and callers below.
3428
3429 * linux-low.cc (linux_target_ops): Update.
3430 (linux_handle_new_gdb_connection): Turn into ...
3431 (linux_process_target::handle_new_gdb_connection): ... this.
3432 * linux-low.h (class linux_process_target): Update.
3433 * lynx-low.cc (lynx_target_ops): Update.
3434 * nto-low.cc (nto_target_ops): Update.
3435 * win32-low.cc (win32_target_ops): Update.
3436
3437 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3438
3439 Turn process_stratum_target's supports_fork_events,
3440 supports_vfork_events, and supports_exec_events ops into methods
3441 of process_target.
3442
3443 * target.h (struct process_stratum_target): Remove the target ops.
3444 (class process_target): Add the target ops.
3445 (target_supports_fork_events): Update the macro.
3446 (target_supports_vfork_events): Update the macro.
3447 (target_supports_exec_events): Update the macro.
3448 * target.cc (process_target::supports_fork_events): Define.
3449 (process_target::supports_vfork_events): Define.
3450 (process_target::supports_exec_events): Define.
3451
3452 Update the derived classes and callers below.
3453
3454 * linux-low.cc (linux_target_ops): Update.
3455 (linux_supports_fork_events): Turn into ...
3456 (linux_process_target::supports_fork_events): ... this.
3457 (linux_supports_vfork_events): Turn into ...
3458 (linux_process_target::supports_vfork_events): ... this.
3459 (linux_supports_exec_events): Turn into ...
3460 (linux_process_target::supports_exec_events): ... this.
3461 * linux-low.h (class linux_process_target): Update.
3462 * lynx-low.cc (lynx_target_ops): Update.
3463 * nto-low.cc (nto_target_ops): Update.
3464 * win32-low.cc (win32_target_ops): Update.
3465
3466 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3467
3468 Turn process_stratum_target's supports_multi_process op into a
3469 method of process_target.
3470
3471 * target.h (struct process_stratum_target): Remove the target op.
3472 (class process_target): Add the target op.
3473 * target.cc (process_target::supports_multi_process): Define.
3474 (target_supports_multi_process): Update.
3475
3476 Update the derived classes and callers below.
3477
3478 * linux-low.cc (linux_target_ops): Update.
3479 (linux_supports_multi_process): Turn into ...
3480 (linux_process_target::supports_multi_process): ... this.
3481 * linux-low.h (class linux_process_target): Update.
3482 * lynx-low.cc (lynx_target_ops): Update.
3483 * nto-low.cc (nto_target_ops): Update.
3484 * win32-low.cc (win32_target_ops): Update.
3485
3486 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3487
3488 Turn process_stratum_target's supports_non_stop, async, and
3489 start_non_stop ops into methods of process_target.
3490
3491 * target.h (struct process_stratum_target): Remove the target ops.
3492 (class process_target): Add the target ops.
3493 (target_supports_non_stop): Update the macro.
3494 (target_async): Update the macro.
3495 (start_non_stop): Remove declaration.
3496 * target.cc (process_target::supports_non_stop): Define.
3497 (process_target::async): Define.
3498 (process_target::start_non_stop): Define.
3499 (start_non_stop): Remove.
3500
3501 Update the derived classes and callers below.
3502
3503 * server.cc (handle_qxfer_siginfo): Update.
3504 (handle_query): Update.
3505 * linux-low.cc (linux_target_ops): Update.
3506 (linux_supports_non_stop): Turn into ...
3507 (linux_process_target::supports_non_stop): ... this.
3508 (linux_async): Turn into ...
3509 (linux_process_target::async): ... this.
3510 (linux_start_non_stop): Turn into ...
3511 (linux_process_target::start_non_stop): ... this.
3512 * linux-low.h (class linux_process_target): Update.
3513 * lynx-low.cc (lynx_target_ops): Update.
3514 * nto-low.cc (nto_target_ops): Update.
3515 (nto_supports_non_stop): Remove; rely on the default behavior
3516 instead.
3517 * win32-low.cc (win32_target_ops): Update.
3518
3519 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3520
3521 Turn process_stratum_target's qxfer_siginfo op into a method of
3522 process_target.
3523
3524 * target.h (struct process_stratum_target): Remove the target op.
3525 (class process_target): Add the target op. Also add
3526 'supports_qxfer_siginfo'.
3527 * target.cc (process_target::qxfer_siginfo): Define.
3528 (process_target::supports_qxfer_siginfo): Define.
3529
3530 Update the derived classes and callers below.
3531
3532 * server.cc (handle_qxfer_siginfo): Update.
3533 (handle_query): Update.
3534 * linux-low.cc (linux_target_ops): Update.
3535 (linux_process_target::supports_qxfer_siginfo): Define.
3536 (linux_xfer_siginfo): Turn into ...
3537 (linux_process_target::qxfer_siginfo): ... this.
3538 * linux-low.h (class linux_process_target): Update.
3539 * lynx-low.cc (lynx_target_ops): Update.
3540 * nto-low.cc (nto_target_ops): Update.
3541 * win32-low.cc (win32_target_ops): Update.
3542
3543 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3544
3545 Turn process_stratum_target's qxfer_osdata op into a method of
3546 process_target.
3547
3548 * target.h (struct process_stratum_target): Remove the target op.
3549 (class process_target): Add the target op. Also add
3550 'supports_qxfer_osdata'.
3551 * target.cc (process_target::qxfer_osdata): Define.
3552 (process_target::supports_qxfer_osdata): Define.
3553
3554 Update the derived classes and callers below.
3555
3556 * server.cc (handle_qxfer_osdata): Update.
3557 (handle_query): Update.
3558 * linux-low.cc (linux_target_ops): Update.
3559 (linux_process_target::supports_qxfer_osdata): Define.
3560 (linux_qxfer_osdata): Turn into ...
3561 (linux_process_target::qxfer_osdata): ... this.
3562 * linux-low.h (class linux_process_target): Update.
3563 * lynx-low.cc (lynx_target_ops): Update.
3564 * nto-low.cc (nto_target_ops): Update.
3565 * win32-low.cc (win32_target_ops): Update.
3566
3567 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3568
3569 Turn process_stratum_target's hostio_last_error op into a
3570 method of process_target.
3571
3572 * target.h (struct process_stratum_target): Remove the target op.
3573 (class process_target): Add the target op.
3574 * target.cc: Add "hostio.h" to includes.
3575 (process_target::hostio_last_error): Define.
3576
3577 Update the derived classes and callers below.
3578
3579 * hostio.cc (hostio_error): Update.
3580 * linux-low.cc: Remove "hostio.h" from includes.
3581 (linux_target_ops): Update.
3582 * lynx-low.cc (lynx_target_ops): Update.
3583 * nto-low.cc (nto_target_ops): Update.
3584 * win32-low.h (class win32_process_target): Update.
3585 * win32-low.cc (win32_target_ops): Update.
3586 (wince_hostio_last_error): Turn into ...
3587 (win32_process_target::hostio_last_error): ... this.
3588
3589 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3590
3591 Turn process_stratum_target's get_tls_address op into a method of
3592 process_target.
3593
3594 * target.h (struct process_stratum_target): Remove the target op.
3595 (class process_target): Add the target op. Also add
3596 'supports_get_tls_address'.
3597 * target.cc (process_target::get_tls_address): Define.
3598 (process_target::supports_get_tls_address): Define.
3599
3600 Update the derived classes and callers below.
3601
3602 * server.cc (handle_query): Update.
3603 * linux-low.cc (linux_target_ops): Update.
3604 (linux_process_target::supports_get_tls_address): Define.
3605 (linux_process_target::get_tls_address): Define.
3606 * linux-low.h (class linux_process_target): Update.
3607 * lynx-low.cc (lynx_target_ops): Update.
3608 * nto-low.cc (nto_target_ops): Update.
3609 * win32-low.cc (win32_target_ops): Update.
3610
3611 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3612
3613 Turn process_stratum_target's read_offsets op into a method of
3614 process_target.
3615
3616 * target.h (struct process_stratum_target): Remove the target op.
3617 (class process_target): Add the target op. Also add
3618 'supports_read_offsets'.
3619 * target.cc (process_target::read_offsets): Define.
3620 (process_target::supports_read_offsets): Define.
3621
3622 Update the derived classes and callers below.
3623
3624 * server.cc (handle_query): Update.
3625 * linux-low.cc (SUPPORTS_READ_OFFSETS): New #define directive.
3626 (linux_target_ops): Update.
3627 (linux_process_target::supports_read_offsets): Define.
3628 (linux_read_offsets): Turn into ...
3629 (linux_process_target::read_offsets): ... this.
3630 * linux-low.h (class linux_process_target): Update.
3631 * lynx-low.cc (lynx_target_ops): Update.
3632 * nto-low.cc (nto_target_ops): Update.
3633 * win32-low.cc (win32_target_ops): Update.
3634
3635 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3636
3637 Turn process_stratum_target's stopped_by_watchpoint and
3638 stopped_data_address ops into methods of process_target.
3639
3640 * target.h (struct process_stratum_target): Remove the target ops.
3641 (class process_target): Add the target ops.
3642 * target.cc (process_target::stopped_by_watchpoint): Define.
3643 (process_target::stopped_data_address): Define.
3644
3645 Update the derived classes and callers below.
3646
3647 * remote-utils.cc (prepare_resume_reply): Update.
3648 * linux-low.cc (linux_target_ops): Update.
3649 (linux_stopped_by_watchpoint): Turn into ...
3650 (linux_process_target::stopped_by_watchpoint): ... this.
3651 (linux_stopped_data_address): Turn into ...
3652 (linux_process_target::stopped_data_address): ... this.
3653 * linux-low.h (class linux_process_target): Update.
3654 * lynx-low.cc (lynx_target_ops): Update.
3655 * nto-low.cc (nto_target_ops): Update.
3656 (nto_stopped_by_watchpoint): Turn into ...
3657 (nto_process_target::stopped_by_watchpoint): ... this.
3658 (nto_stopped_data_address): Turn into ...
3659 (nto_process_target::stopped_data_address): ... this.
3660 * nto-low.h (class nto_process_target): Update.
3661 * win32-low.cc (win32_target_ops): Update.
3662 (win32_stopped_by_watchpoint): Turn into ...
3663 (win32_process_target::stopped_by_watchpoint): ... this.
3664 (win32_stopped_data_address): Turn into ...
3665 (win32_process_target::stopped_data_address): ... this.
3666 * win32-low.h (class win32_process_target): Update.
3667
3668 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3669
3670 Turn process_stratum_target's supports_hardware_single_step op into
3671 a method of process_target.
3672
3673 * target.h (struct process_stratum_target): Remove the target op.
3674 (class process_target): Add the target op.
3675 (target_supports_hardware_single_step): Update the macro.
3676 (target_can_do_hardware_single_step): Remove declaration.
3677 * target.cc (process_target::supports_hardware_single_step): Define.
3678 (target_can_do_hardware_single_step): Remove.
3679
3680 Update the derived classes and callers below.
3681
3682 * linux-low.h (class linux_process_target): Update.
3683 * linux-low.cc (linux_target_ops): Update.
3684 (linux_supports_hardware_single_step): Turn into ...
3685 (linux_process_target::supports_hardware_single_step): ... this.
3686 * lynx-low.h (class lynx_process_target): Update.
3687 * lynx-low.cc (lynx_target_ops): Update.
3688 (lynx_process_target::supports_hardware_single_step): Define.
3689 * nto-low.h (class nto_process_target): Update.
3690 * nto-low.cc (nto_target_ops): Update.
3691 (nto_process_target::supports_hardware_single_step): Define.
3692 * win32-low.h (class win32_process_target): Update.
3693 * win32-low.cc (win32_target_ops): Update.
3694 (win32_process_target::supports_hardware_single_step): Define.
3695
3696 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3697
3698 Turn process_stratum_target's {supports_}stopped_by_hw_breakpoint
3699 ops into methods of process_target.
3700
3701 * target.h (struct process_stratum_target): Remove the target ops.
3702 (class process_target): Add the target ops.
3703 (target_stopped_by_hw_breakpoint): Update the macro.
3704 (target_supports_stopped_by_hw_breakpoint): Update the macro.
3705 * target.cc (process_target::stopped_by_hw_breakpoint): Define.
3706 (process_target::supports_stopped_by_hw_breakpoint): Define.
3707
3708 Update the derived classes and callers below.
3709
3710 * linux-low.cc (linux_target_ops): Update.
3711 (linux_stopped_by_hw_breakpoint): Turn into ...
3712 (linux_process_target::stopped_by_hw_breakpoint): ... this.
3713 (linux_supports_stopped_by_hw_breakpoint): Turn into ...
3714 (linux_process_target::supports_stopped_by_hw_breakpoint): ... this.
3715 * linux-low.h (class linux_process_target): Update.
3716 * lynx-low.cc (lynx_target_ops): Update.
3717 * nto-low.cc (nto_target_ops): Update.
3718 * win32-low.cc (win32_target_ops): Update.
3719
3720 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3721
3722 Turn process_stratum_target's {supports_}stopped_by_sw_breakpoint
3723 ops into methods of process_target.
3724
3725 * target.h (struct process_stratum_target): Remove the target ops.
3726 (class process_target): Add the target ops.
3727 (target_stopped_by_sw_breakpoint): Update the macro.
3728 (target_supports_stopped_by_sw_breakpoint): Update the macro.
3729 * target.cc (process_target::stopped_by_sw_breakpoint): Define.
3730 (process_target::supports_stopped_by_sw_breakpoint): Define.
3731
3732 Update the derived classes and callers below.
3733
3734 * linux-low.cc (linux_target_ops): Update.
3735 (linux_stopped_by_sw_breakpoint): Turn into ...
3736 (linux_process_target::stopped_by_sw_breakpoint): ... this.
3737 (linux_supports_stopped_by_sw_breakpoint): Turn into ...
3738 (linux_process_target::supports_stopped_by_sw_breakpoint): ... this.
3739 * linux-low.h (class linux_process_target): Update.
3740 * lynx-low.cc (lynx_target_ops): Update.
3741 * nto-low.cc (nto_target_ops): Update.
3742 * win32-low.cc (win32_target_ops): Update.
3743
3744 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3745
3746 Turn process_stratum_target's insert_point and remove_point ops
3747 into methods of process_target.
3748
3749 * target.h (struct process_stratum_target): Remove the target ops.
3750 (class process_target): Add the target ops.
3751 * target.cc (process_target::insert_point): Define.
3752 (process_target::remove_point): Define.
3753
3754 Update the derived classes and callers below.
3755
3756 * mem-break.cc (set_raw_breakpoint_at): Update.
3757 (delete_raw_breakpoint): Update.
3758 (uninsert_raw_breakpoint): Update.
3759 (reinsert_raw_breakpoint): Update.
3760 * linux-low.cc (linux_target_ops): Update.
3761 (linux_insert_point): Turn into ...
3762 (linux_process_target::insert_point): ... this.
3763 (linux_remove_point): Turn into ...
3764 (linux_process_target::remove_point): ... this.
3765 * linux-low.h (class linux_process_target): Update.
3766 * lynx-low.cc (lynx_target_ops): Update.
3767 * nto-low.cc (nto_target_ops): Update.
3768 (nto_insert_point): Turn into ...
3769 (nto_process_target::insert_point): ... this.
3770 (nto_remove_point): Turn into ...
3771 (nto_process_target::remove_point): ... this.
3772 * nto-low.h (class nto_process_target): Update.
3773 * win32-low.cc (win32_target_ops): Update.
3774 (win32_insert_point): Turn into ...
3775 (win32_process_target::insert_point): ... this.
3776 (win32_remove_point): Turn into ...
3777 (win32_process_target::remove_point): ... this.
3778 * win32-low.h (class win32_process_target): Update.
3779
3780 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3781
3782 Turn process_stratum_target's supports_z_point_type op into a
3783 method of process_target.
3784
3785 * target.h (struct process_stratum_target): Remove the target op.
3786 (class process_target): Add the target op.
3787 * target.cc (process_target::supports_z_point_type): Define.
3788
3789 Update the derived classes and callers below.
3790
3791 * mem-break.cc (z_type_supported): Update.
3792 * linux-low.cc (linux_target_ops): Update.
3793 (linux_supports_z_point_type): Turn into ...
3794 (linux_process_target::supports_z_point_type): ... this.
3795 * linux-low.h (class linux_process_target): Update.
3796 * lynx-low.cc (lynx_target_ops): Update.
3797 * nto-low.cc (nto_target_ops): Update.
3798 (nto_supports_z_point_type): Turn into ...
3799 (nto_process_target::supports_z_point_type): ... this.
3800 * nto-low.h (class nto_process_target): Update.
3801 * win32-low.cc (win32_target_ops): Update.
3802 (win32_supports_z_point_type): Turn into ...
3803 (win32_process_target::supports_z_point_type): ... this.
3804 * win32-low.h (class win32_process_target): Update.
3805
3806 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3807
3808 Turn process_stratum_target's read_auxv op into a method of
3809 process_target.
3810
3811 * target.h (class process_stratum_target): Remove the target op.
3812 (struct process_target): Add the target op. Also add
3813 'supports_read_auxv'.
3814 * target.cc (process_target::read_auxv): Define.
3815 (process_target::supports_read_auxv): Define.
3816
3817 Update the derived classes and callers below.
3818
3819 * server.cc (handle_qxfer_auxv): Update.
3820 (handle_query): Update.
3821 * linux-low.cc (linux_target_ops): Update.
3822 (linux_process_target::supports_read_auxv): Define.
3823 (linux_read_auxv): Turn into ...
3824 (linux_process_target::read_auxv): ... this.
3825 * linux-low.h (class linux_process_target): Update.
3826 * lynx-low.cc (lynx_target_ops): Update.
3827 * nto-low.cc (nto_target_ops): Update.
3828 (nto_process_target::supports_read_auxv): Define.
3829 (nto_read_auxv): Turn into ...
3830 (nto_process_target::read_auxv): ... this.
3831 * nto-low.h (class nto_process_target): Update.
3832 * win32-low.cc (win32_target_ops): Update.
3833
3834 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3835
3836 Turn process_stratum_target's request_interrupt op into a method of
3837 process_target.
3838
3839 * target.h (struct process_stratum_target): Remove the target op.
3840 (class process_target): Add the target op.
3841
3842 Update the derived classes and callers below.
3843
3844 * remote-utils.cc (putpkt_binary_1): Update.
3845 (input_interrupt): Update.
3846 (getpkt): Update.
3847 * server.cc (handle_v_requests): Update.
3848 * linux-low.cc (linux_target_ops): Update.
3849 (linux_request_interrupt): Turn into ...
3850 (linux_process_target::request_interrupt): ... this.
3851 * linux-low.h (class linux_process_target): Update.
3852 * lynx-low.cc (lynx_target_ops): Update.
3853 (lynx_request_interrupt): Turn into ...
3854 (lynx_process_target::request_interrupt): ... this.
3855 * lynx-low.h (class lynx_process_target): Update.
3856 * nto-low.cc (nto_target_ops): Update.
3857 (nto_request_interrupt): Turn into ...
3858 (nto_process_target::request_interrupt): ... this.
3859 * nto-low.h (class nto_process_target): Update.
3860 * win32-low.cc (win32_target_ops): Update.
3861 (win32_request_interrupt): Turn into ...
3862 (win32_process_target::request_interrupt): ... this.
3863 * win32-low.h (class win32_process_target): Update.
3864
3865 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3866
3867 Turn process_stratum_target's look_up_symbols op into a method of
3868 process_target.
3869
3870 * target.h (struct process_stratum_target): Remove the target op.
3871 (class process_target): Add the target op.
3872 * target.cc (process_target::look_up_symbols): Define.
3873
3874 Update the derived classes and callers below.
3875
3876 * server.cc (handle_query): Update.
3877 * linux-low.cc (linux_target_ops): Update.
3878 (linux_look_up_symbols): Turn into ...
3879 (linux_process_target::look_up_symbols): ... this.
3880 * linux-low.h (class linux_process_target): Update.
3881 * lynx-low.cc (lynx_target_ops): Update.
3882 * nto-low.cc (nto_target_ops): Update.
3883 * win32-low.cc (win32_target_ops): Update.
3884
3885 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3886
3887 Turn process_stratum_target's read_memory and write_memory
3888 ops into methods of process_target.
3889
3890 * target.h (struct process_stratum_target): Remove the target ops.
3891 (class process_target): Add the target ops.
3892
3893 Update the derived classes and callers below.
3894
3895 * linux-aarch32-low.cc (arm_breakpoint_at): Update.
3896 * linux-aarch64-low.cc (aarch64_breakpoint_at): Update.
3897 * linux-arm-low.cc (arm_sigreturn_next_pc): Update.
3898 (arm_get_syscall_trapinfo): Update.
3899 * linux-cris-low.cc (cris_breakpoint_at): Update.
3900 * linux-crisv32-low.cc (cris_breakpoint_at): Update.
3901 * linux-m32r-low.cc (m32r_breakpoint_at): Update.
3902 * linux-mips-low.cc (mips_breakpoint_at): Update.
3903 * linux-nios2-low.cc (nios2_breakpoint_at): Update.
3904 * linux-ppc-low.cc (ppc_breakpoint_at): Update.
3905 * linux-sh-low.cc (sh_breakpoint_at): Update.
3906 * linux-sparc-low.cc (sparc_fill_gregset_to_stack): Update.
3907 (sparc_store_gregset_from_stack): Update.
3908 (sparc_breakpoint_at): Update.
3909 * linux-tic6x-low.cc (tic6x_breakpoint_at): Update.
3910 * linux-tile-low.cc (tile_breakpoint_at): Update.
3911 * linux-x86-low.cc (x86_breakpoint_at): Update.
3912 * linux-xtensa-low.cc (xtensa_breakpoint_at): Update.
3913 * mem-brea.cc (insert_memory_breakpoint): Update.
3914 (validate_inserted_breakpoint): Update.
3915 * target.cc (read_inferior_memory): Update.
3916 (target_write_memory): Update.
3917 * linux-low.cc (linux_target_ops): Update.
3918 (linux_read_memory): Make a wrapper around the read_memory target
3919 op call.
3920 (linux_process_target::read_memory): Rename from linux_read_memory.
3921 (linux_write_memory): Turn into ...
3922 (linux_process_target::write_memory): ... this.
3923 * linux-low.h (class linux_process_target): Update.
3924 * lynx-low.cc (lynx_target_ops): Update.
3925 (lynx_read_memory): Turn into ...
3926 (lynx_process_target::read_memory): ... this.
3927 (lynx_write_memory): Turn into ...
3928 (lynx_process_target::write_memory): ... this.
3929 * lynx-low.h (class lynx_process_target): Update.
3930 * nto-low.cc (nto_target_ops): Update.
3931 (nto_read_memory): Turn into ...
3932 (nto_process_target::read_memory): ... this.
3933 (nto_write_memory): Turn into ...
3934 (nto_process_target::write_memory): ... this.
3935 * nto-low.h (class nto_process_target): Update.
3936 * win32-low.cc (win32_target_ops): Update.
3937 (win32_read_inferior_memory): Turn into ...
3938 (win32_process_target::read_memory): ... this.
3939 (win32_write_inferior_memory): Turn into ...
3940 (win32_process_target::write_memory): ... this.
3941 * win32-low.h (class win32_process_target): Update.
3942
3943 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3944
3945 Turn process_stratum_target's prepare_to_access_memory and
3946 done_accessing_memory ops into methods of process_target.
3947
3948 * target.h (struct process_stratum_target): Remove the target ops.
3949 (class process_target): Add the target ops.
3950 * target.cc (process_target::prepare_to_access_memory): Define.
3951 (process_target::done_accessing_memory): Define.
3952 (prepare_to_access_memory): Update.
3953 (done_accessing_memory): Update.
3954
3955 Update the derived classes and callers below.
3956
3957 * linux-low.cc (linux_target_ops): Update.
3958 (linux_prepare_to_access_memory): Turn into ...
3959 (linux_process_target::prepare_to_access_memory): ... this.
3960 (linux_done_accessing_memory): Turn into ...
3961 (linux_process_target::done_accessing_memory): ... this.
3962 * linux-low.h (class linux_process_target): Update.
3963 * lynx-low.cc (lynx_target_ops): Update.
3964 * nto-low.cc (nto_target_ops): Update.
3965 * win32-low.cc (win32_target_ops): Update.
3966
3967 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3968
3969 Turn process_stratum_target's fetch_registers and store_registers
3970 ops into methods of process_target.
3971
3972 * target.h (struct process_stratum_target): Remove the target ops.
3973 (class process_target): Add the target ops.
3974 (fetch_inferior_registers): Update the macro.
3975 (store_inferior_registers): Update the macro.
3976
3977 Update the derived classes and callers below.
3978
3979 * linux-low.cc (linux_target_ops): Update.
3980 (linux_fetch_registers): Turn into ...
3981 (linux_process_target::fetch_registers): ... this.
3982 (linux_store_registers): Turn into ...
3983 (linux_process_target::store_registers): ... this.
3984 * linux-low.h (class linux_process_target): Update.
3985 * lynx-low.cc (lynx_target_ops): Update.
3986 (lynx_fetch_registers): Turn into ...
3987 (lynx_process_target::fetch_registers): ... this.
3988 (lynx_store_registers): Turn into ...
3989 (lynx_process_target::store_registers): ... this.
3990 * lynx-low.h (class lynx_process_target): Update.
3991 * nto-low.cc (nto_target_ops): Update.
3992 (nto_fetch_registers): Turn into ...
3993 (nto_process_target::fetch_registers): ... this.
3994 (nto_store_registers): Turn into ...
3995 (nto_process_target::store_registers): ... this.
3996 * nto-low.h (class nto_process_target): Update.
3997 * win32-low.cc (win32_target_ops): Update.
3998 (win32_fetch_inferior_registers): Turn into ...
3999 (win32_process_target::fetch_registers): ... this.
4000 (win32_store_inferior_registers): Turn into ...
4001 (win32_process_target::store_registers): ... this.
4002 * win32-low.h (class win32_process_target): Update.
4003
4004 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4005
4006 Turn process_stratum_target's wait op into a method of
4007 process_target.
4008
4009 * target.h (struct process_stratum_target): Remove the target op.
4010 (class process_target): Add the target op.
4011
4012 Update the derived classes and callers below.
4013
4014 * target.cc (target_wait): Update.
4015 * linux-low.cc (linux_target_ops): Update.
4016 (linux_wait): Turn into ...
4017 (linux_process_target::wait): ... this.
4018 * linux-low.h (class linux_process_target): Update.
4019 * lynx-low.cc (lynx_target_ops): Update.
4020 (lynx_wait): Turn into ...
4021 (lynx_process_target::wait): ... this.
4022 * lynx-low.h (class lynx_process_target): Update.
4023 * nto-low.cc (nto_target_ops): Update.
4024 (nto_wait): Turn into ...
4025 (nto_process_target::wait): ... this.
4026 * nto-low.h (class nto_process_target): Update.
4027 * win32-low.cc (win32_target_ops): Update.
4028 (win32_wait): Turn into ...
4029 (win32_process_target::wait): ... this.
4030 (do_initial_child_stuff): Update.
4031 * win32-low.h (class win32_process_target): Update.
4032
4033 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4034
4035 Turn process_stratum_target's resume op into a method of
4036 process_target.
4037
4038 * target.h (struct process_stratum_target): Remove the target op.
4039 (class process_target): Add the target op.
4040
4041 Update the derived classes and callers below.
4042
4043 * server.cc (resume): Update.
4044 * target.cc (target_stop_and_wait): Update.
4045 (target_continue_no_signal): Update.
4046 (target_continue): Update.
4047 * linux-low.cc (linux_target_ops): Update.
4048 (linux_resume): Turn into ...
4049 (linux_process_target::resume): ... this.
4050 * linux-low.h (class linux_process_target): Update.
4051 * lynx-low.cc (lynx_target_ops): Update.
4052 (lynx_resume): Turn into ...
4053 (lynx_process_target::resume): ... this.
4054 * lynx-low.h (class lynx_process_target): Update.
4055 * nto-low.cc (nto_target_ops): Update.
4056 (nto_resume): Turn into ...
4057 (nto_process_target::resume): ... this.
4058 * nto-low.h (class nto_process_target): Update.
4059 * win32-low.cc (win32_target_ops): Update.
4060 (win32_resume): Turn into ...
4061 (win32_process_target::resume): ... this.
4062 (win32_process_target::detach): Update.
4063 (do_initial_child_stuff): Update.
4064 * win32-low.h (class win32_process_target): Update.
4065
4066 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4067
4068 Turn process_stratum_target's thread_alive op into a method of
4069 process_target.
4070
4071 * target.h (struct process_stratum_target): Remove the target op.
4072 (class process_target): Add the target op.
4073 (mythread_alive): Update the macro.
4074
4075 Update the derived classes and callers below.
4076
4077 * linux-low.cc (linux_target_ops): Update.
4078 (linux_thread_alive): Turn into ...
4079 (linux_process_target::thread_alive): ... this.
4080 (wait_for_sigstop): Update.
4081 * linux-low.h (class linux_process_target): Update.
4082 * lynx-low.cc (lynx_target_ops): Update.
4083 (lynx_thread_alive): Turn into ...
4084 (lynx_process_target::thread_alive): ... this.
4085 * lynx-low.h (class lynx_process_target): Update.
4086 * nto-low.cc (nto_target_ops): Update.
4087 (nto_thread_alive): Turn into ...
4088 (nto_process_target::thread_alive): ... this.
4089 * nto-low.h (class nto_process_target): Update.
4090 * win32-low.cc (win32_target_ops): Update.
4091 (win32_thread_alive): Turn into ...
4092 (win32_process_target::thread_alive): ... this.
4093 * win32-low.h (class win32_process_target): Update.
4094
4095 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4096
4097 Turn process_stratum_target's join op into a method of
4098 process_target.
4099
4100 * target.h (struct process_stratum_target): Remove the target op.
4101 (class process_target): Add the target op.
4102 (join_inferior): Update the macro.
4103
4104 Update the derived classes and callers below.
4105
4106 * linux-low.cc (linux_target_ops): Update.
4107 (linux_join): Turn into ...
4108 (linux_process_target::join): ... this.
4109 * linux-low.h (class linux_process_target): Update.
4110 * lynx-low.cc (lynx_target_ops): Update.
4111 (lynx_join): Turn into ...
4112 (lynx_process_target::join): ... this.
4113 * lynx-low.h (class lynx_process_target): Update.
4114 * nto-low.cc (nto_target_ops): Update.
4115 (nto_process_target::join): Define.
4116 * nto-low.h (class nto_process_target): Update.
4117 * win32-low.cc (win32_target_ops): Update.
4118 (win32_join): Turn into ...
4119 (win32_process_target::join): ... this.
4120 * win32-low.h (class win32_process_target): Update.
4121
4122 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4123
4124 Turn process_stratum_target's mourn op into a method of
4125 process_target.
4126
4127 * target.h (struct process_stratum_target): Remove the target op.
4128 (class process_target): Add the target op.
4129
4130 Update the derived classes and callers below.
4131
4132 * target.cc (target_mourn_inferior): Update.
4133 * linux-low.cc (linux_target_ops): Update.
4134 (linux_mourn): Turn into ...
4135 (linux_process_target::mourn): ... this.
4136 (handle_extended_wait): Update.
4137 (linux_process_target::kill): Update.
4138 (linux_process_target::detach): Update.
4139 * linux-low.h (class linux_process_target): Update.
4140 * lynx-low.cc (lynx_target_ops): Update.
4141 (lynx_mourn): Turn into ...
4142 (lynx_process_target::mourn): ... this.
4143 * lynx-low.h (class lynx_process_target): Update.
4144 * nto-low.cc (nto_target_ops): Update.
4145 (nto_mourn): Turn into ...
4146 (nto_process_target::mourn): ... this.
4147 * nto-low.h (class nto_process_target): Update.
4148 * win32-low.cc (win32_target_ops): Update.
4149 (win32_mourn): Turn into ...
4150 (win32_process_target::mourn): ... this.
4151 * win32-low.h (class win32_process_target): Update.
4152
4153 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4154
4155 Turn process_stratum_target's detach op into a method of
4156 process_target.
4157
4158 * target.h (struct process_stratum_target): Remove the target op.
4159 (class process_target): Add the target op.
4160 (detach_inferior): Update the macro.
4161
4162 Update the derived classes and callers below.
4163
4164 * linux-low.cc (linux_target_ops): Update.
4165 (linux_detach): Turn into ...
4166 (linux_process_target::detach): ... this.
4167 * linux-low.h (class linux_process_target): Update.
4168 * lynx-low.cc (lynx_target_ops): Update.
4169 (lynx_detach): Turn into ...
4170 (lynx_process_target::detach): ... this.
4171 * lynx-low.h (class lynx_process_target): Update.
4172 * nto-low.cc (nto_target_ops): Update.
4173 (nto_detach): Turn into ...
4174 (nto_process_target::detach): ... this.
4175 * nto-low.h (class nto_process_target): Update.
4176 * win32-low.cc (win32_target_ops): Update.
4177 (win32_detach): Turn into ...
4178 (win32_process_target::detach): ... this.
4179 * win32-low.h (class win32_process_target): Update.
4180
4181 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4182
4183 Turn process_stratum_target's kill op into a method of
4184 process_target.
4185
4186 * target.h (struct process_stratum_target): Remove the target op.
4187 (class process_target): Add the target op.
4188
4189 Update the derived classes and callers below.
4190
4191 * target.cc (kill_inferior): Update.
4192 * linux-low.cc (linux_target_ops): Update.
4193 (linux_kill): Turn into ...
4194 (linux_process_target::kill): ... this.
4195 * linux-low.h (class linux_process_target): Update.
4196 * lynx-low.cc (lynx_target_ops): Update.
4197 (lynx_kill): Turn into ...
4198 (lynx_process_target::kill): ... this.
4199 * lynx-low.h (class lynx_process_target): Update.
4200 * nto-low.cc (nto_target_ops): Update.
4201 (nto_kill): Turn into ...
4202 (nto_process_target::kill): ... this.
4203 * nto-low.h (class nto_process_target): Update.
4204 * win32-low.cc (win32_target_ops): Update.
4205 (win32_kill): Turn into ...
4206 (win32_process_target::kill): ... this.
4207 * win32-low.h (class win32_process_target): Update.
4208
4209 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4210
4211 Turn process_stratum_target's attach op into a method of
4212 process_target.
4213
4214 * target.h (struct process_stratum_target): Remove the target op.
4215 (class process_target): Add the target op.
4216 (myattach): Update the macro.
4217
4218 Update the derived classes and callers below.
4219
4220 * linux-low.cc (linux_target_ops): Update.
4221 (linux_attach): Turn into ...
4222 (linux_process_target::attach): ... this.
4223 * linux-low.h (class linux_process_target): Update.
4224 * lynx-low.cc (lynx_target_ops): Update.
4225 (lynx_attach): Turn into ...
4226 (lynx_process_target::attach): ... this.
4227 * lynx-low.h (class lynx_process_target): Update.
4228 * nto-low.cc (nto_target_ops): Update.
4229 (nto_attach): Turn into ...
4230 (nto_process_target::attach): ... this.
4231 * nto-low.h (class nto_process_target): Update.
4232 * win32-low.cc (win32_target_ops): Update.
4233 (win32_attach): Turn into ...
4234 (win32_process_target::attach): ... this.
4235 * win32-low.h (class win32_process_target): Update.
4236
4237 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4238
4239 Turn process_stratum_target's post_create_inferior op into a method
4240 of process_target.
4241
4242 * target.h (struct process_stratum_target): Remove the target op.
4243 (class process_target): Add the target op.
4244 (target_post_create_inferior): Update the macro.
4245 * target.cc (process_target::post_create_inferior): Define.
4246
4247 Update the derived classes and callers below.
4248
4249 * linux-low.cc (linux_target_ops): Update.
4250 (linux_post_create_inferior): Turn into ...
4251 (linux_process_target::post_create_inferior): ... this.
4252 * linux-low.h (class linux_process_target): Update.
4253 * lynx-low.cc (lynx_target_ops): Update.
4254 * nto-low.cc (nto_target_ops): Update.
4255 * win32-low.cc (win32_target_ops): Update.
4256
4257 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4258
4259 Turn process_stratum_target's create_inferior op into a method of
4260 process_target.
4261
4262 * target.h (struct process_stratum_target): Remove the target op.
4263 (class process_target): Add the target op.
4264 (create_inferior): Rename the macro to ...
4265 (target_create_inferior): ... this.
4266
4267 Update the derived classes and callers below.
4268
4269 * server.cc (handle_v_run): Update.
4270 (captured_main): Update.
4271 (process_serial_event): Update.
4272 * linux-low.cc (linux_target_ops): Update.
4273 (linux_create_inferior): Turn into ...
4274 (linux_process_target::create_inferior): ... this.
4275 * linux-low.h (class linux_process_target): Update.
4276 * lynx-low.cc (lynx_target_ops): Update.
4277 (lynx_create_inferior): Turn into ...
4278 (lynx_process_target::create_inferior): ... this.
4279 * lynx-low.h (class lynx_process_target): Update.
4280 * nto-low.cc (nto_target_ops): Update.
4281 (nto_create_inferior): Turn into ...
4282 (nto_process_target::create_inferior): ... this.
4283 * nto-low.h (class nto_process_target): Update.
4284 * win32-low.cc (win32_target_ops): Update.
4285 (win32_create_inferior): Turn into ...
4286 (win32_process_target::create_inferior): ... this.
4287 * win32-low.h (class win32_process_target): Update.
4288
4289 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4290
4291 * target.h (class process_target): New class definition.
4292 (struct process_stratum_target) <pt>: New field with type
4293 'process_target*'.
4294 * linux-low.h (class linux_process_target): Define as a derived
4295 class of 'process_target'.
4296 * linux-low.cc (linux_target_ops): Add a linux_process_target*
4297 as the 'pt' field.
4298 * lynx-low.h (class lynx_process_target): Define as a derived
4299 class of 'process_target'.
4300 * lynx-low.cc (lynx_target_ops): Add a lynx_process_target*
4301 as the 'pt' field.
4302 * nto-low.h (class nto_process_target): Define as a derived
4303 class of 'process_target'.
4304 * nto-low.cc (nto_target_ops): Add an nto_process_target*
4305 as the 'pt' field.
4306 * win32-low.h (class win32_process_target): Define as a derived
4307 class of 'process_target'.
4308 * win32-low.cc (win32_target_ops): Add a win32_process_target*
4309 as the 'pt' field.
4310
4311 2020-02-19 Andrew Burgess <andrew.burgess@embecosm.com>
4312
4313 * configure: Regenerate.
4314
4315 2020-02-19 Maciej W. Rozycki <macro@wdc.com>
4316 Andrew Burgess <andrew.burgess@embecosm.com>
4317
4318 * linux-riscv-low.cc: New file.
4319 * Makefile.in (SFILES): Add linux-riscv-low.cc, arch/riscv.c,
4320 and nat/riscv-linux-tdesc.c.
4321 * configure.srv <riscv*-*-linux*> (srv_tgtobj)
4322 (srv_linux_regsets, srv_linux_usrregs, srv_linux_thread_db):
4323 Define.
4324
4325 2020-02-14 Tom Tromey <tom@tromey.com>
4326
4327 * acinclude.m4: Don't include acx_configure_dir.m4.
4328 * Makefile.in (LIBIBERTY_BUILDDIR, GNULIB_BUILDDIR): Update.
4329 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): Remove.
4330 (all, install-only, uninstall, clean-info, clean)
4331 (maintainer-clean): Don't recurse.
4332 (subdir_do, all-lib): Remove.
4333 ($(LIBGNU) $(LIBIBERTY) $(GNULIB_H)): Remove rule.
4334 (GNULIB_H): Remove.
4335 (generated_files): Update.
4336 ($(GNULIB_BUILDDIR)/Makefile): Remove rule.
4337 * configure: Rebuild.
4338 * configure.ac: Don't configure gnulib or libiberty.
4339 (GNULIB): Update.
4340
4341 2020-02-14 Eli Zaretskii <eliz@gnu.org>
4342
4343 * win32-low.c (create_process): Prepend PROGRAM to ARGS when
4344 preparing the command line for CreateProcess.
4345 (win32_create_inferior): Reflect the program name in debugging
4346 output that shows the process and its command line.
4347
4348 2020-02-13 Simon Marchi <simon.marchi@efficios.com>
4349
4350 * Makefile.in: Rename source files from .c to .cc.
4351 * %.c: Rename to %.cc.
4352 * configure.ac: Rename server.c to server.cc.
4353 * configure: Re-generate.
4354
4355 2020-02-13 Simon Marchi <simon.marchi@efficios.com>
4356
4357 * Makefile.in: Rename gdbsupport source files from .c to .cc.
4358
4359 2020-02-12 Hannes Domani <ssbssa@yahoo.de>
4360
4361 * win32-low.c (win32_create_inferior): Set signal_pid.
4362
4363 2020-02-12 Maciej W. Rozycki <macro@wdc.com>
4364 Pedro Alves <palves@redhat.com>
4365
4366 Skip building gdbserver in a cross-configuration.
4367 * configure.srv: Set $gdbserver_host depending on whether $target
4368 is $host. Use $gdbserver_host instead of $host.
4369
4370 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
4371
4372 * configure: Re-generate.
4373
4374 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
4375
4376 * configure: Re-generate.
4377
4378 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
4379
4380 * acinclude.m4: Update warning.m4 path.
4381
4382 2020-02-09 Hannes Domani <ssbssa@yahoo.de>
4383
4384 * win32-low.c (win32_clear_inferiors): Reset siginfo_er.
4385 (handle_exception): Set siginfo_er.
4386 (win32_xfer_siginfo): New function.
4387
4388 2020-02-07 Tom Tromey <tom@tromey.com>
4389 Pedro Alves <palves@redhat.com>
4390
4391 * README: Update build documentation.
4392 * configure.srv: Set UNSUPPORTED if host is unsupported. Check
4393 host, not target.
4394 * configure.ac: Update paths.
4395 * configure: Rebuild.
4396 * acinclude.m4: Update paths.
4397 * Makefile.in: Update include paths.
4398 (depcomp, INCLUDE_DIR, INCGNU, INCSUPPORT, INCLUDE_CFLAGS)
4399 (SFILES, XML_DIR, n, $(GNULIB_BUILDDIR)/Makefile, config.status)
4400 (version-generated.c, stamp-xml, regdat_sh, arch/%-ipa.o)
4401 (gdbsupport/%-ipa.o, %-ipa.o, arch/%.o, gdbsupport/%.o, %.o)
4402 (%-generated.c): Update paths.
4403 * Move entire directory from ../gdb/gdbserver.
4404
4405 2020-01-29 Maciej W. Rozycki <macro@wdc.com>
4406
4407 * configure.srv <i[34567]86-*-mingw*>: Fix whitespace damage.
4408
4409 2020-01-29 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4410
4411 * configure.srv (powerpc*-*-linux*): Use srv_tgtobj in second
4412 assignment instead of srv_linux_obj.
4413
4414 2020-01-28 Hannes Domani <ssbssa@yahoo.de>
4415
4416 * server.c (handle_qxfer_libraries): Write segment-address with
4417 paddress.
4418
4419 2020-01-24 Hannes Domani <ssbssa@yahoo.de>
4420
4421 * Makefile.in (install-strip): New target.
4422 (install_sh, INSTALL_STRIP_PROGRAM, STRIP): New variables.
4423 * aclocal.m4: Regenerate.
4424 * configure: Regenerate.
4425 * configure.ac: Add AM_PROG_INSTALL_STRIP.
4426
4427 2020-01-24 Maciej W. Rozycki <macro@wdc.com>
4428
4429 * Makefile.in (SFILES): Adjust paths to point to real files.
4430 (OBS): Move waitstatus.o to target/waitstatus.o.
4431 (TAGS): Transform paths appropriately.
4432 (%.o): Rename to...
4433 (nat/%.o): ... this pattern rule.
4434 (%.o): Rename to...
4435 (target/%.o): ... this pattern rule.
4436 * configure.srv: Adjust paths throughout to include nat/ prefix
4437 with the revant files.
4438 * configure.ac: Add `nat' and `target' to CONFIG_SRC_SUBDIR.
4439 * configure: Regenerate.
4440
4441 2020-01-24 Maciej W. Rozycki <macro@wdc.com>
4442
4443 * Makefile.in (TAGS): Remove config files from the recipe.
4444
4445 2020-01-14 Tom Tromey <tom@tromey.com>
4446
4447 * configure: Rebuild.
4448 * configure.ac: Remove any checks that were added to common.m4.
4449 * acinclude.m4: Include lib-ld.m4, lib-prefix.m4, and
4450 lib-link.m4.
4451
4452 2020-01-14 Tom Tromey <tom@tromey.com>
4453
4454 * server.h: Include config.h.
4455 * gdbreplay.c: Include config.h.
4456 * configure: Rebuild.
4457 * configure.ac: Don't source common.host.
4458 * acinclude.m4: Update path.
4459 * Makefile.in (INCSUPPORT): New variable.
4460 (INCLUDE_CFLAGS): Add INCSUPPORT.
4461 (SFILES): Update paths.
4462 (version-generated.c): Update path to create-version.sh.
4463 (gdbsupport/%-ipa.o, gdbsupport/%.o): Update paths.
4464
4465 2020-01-14 Tom Tromey <tom@tromey.com>
4466
4467 * configure.ac (LIBS): Use WIN32APILIBS.
4468 (USE_WIN32API): Don't define.
4469 * configure: Rebuild.
4470
4471 2020-01-14 Tom Tromey <tom@tromey.com>
4472
4473 * configure: Rebuild.
4474
4475 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
4476
4477 * Makefile.in (%-generated.c): Remove rule for files from
4478 regformats/i386.
4479
4480 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
4481
4482 * configure: Re-generate.
4483
4484 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
4485
4486 * tracepoint.h (IP_AGENT_EXPORT_FUNC) [!IN_PROCESS_AGENT]:
4487 Define to static.
4488 * tracepoint.c (stop_tracing, flush_trace_buffer,
4489 about_to_request_buffer_space, get_trace_state_variable_value,
4490 set_trace_state_variable_value, gdb_collect): Add declaration.
4491
4492 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
4493
4494 * linux-x86-low.c (x86_linux_regs_info, amd64_emit_eq_goto,
4495 amd64_emit_ne_goto, amd64_emit_lt_goto, amd64_emit_le_goto,
4496 amd64_emit_gt_goto, amd64_emit_ge_goto, amd64_emit_ge_goto,
4497 i386_emit_eq_goto, i386_emit_ne_goto, i386_emit_lt_goto,
4498 i386_emit_le_goto, i386_emit_gt_goto, i386_emit_ge_goto): Make
4499 static.
4500
4501 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
4502
4503 * inferiors.c: Include gdbsupport/common-inferior.h.
4504
4505 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
4506
4507 * hostio-errno.c: Include hostio.h.
4508
4509 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
4510
4511 * Makefile.in (%-generated.c): Make $(regdat_sh) a regular
4512 prerequisite.
4513
4514 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
4515
4516 * linux-arm-tdesc.c: Include linux-arm-tdesc.h.
4517 * linux-arm-tdesc.h: Include arch/arm.h.
4518
4519 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
4520
4521 * linux-aarch64-low.c (aarch64_write_goto_address): Make static.
4522
4523 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
4524
4525 * linux-aarch32-tdesc.c: Include linux-aarch32-tdesc.h.
4526 * linux-aarch64-tdesc.c: Include linux-aarch64-tdesc.h.
4527
4528 2020-01-10 Pedro Alves <palves@redhat.com>
4529
4530 * fork-child.c (post_fork_inferior): Pass target down to
4531 startup_inferior.
4532 * inferiors.c (switch_to_thread): Add process_stratum_target
4533 parameter.
4534 * lynx-low.c (lynx_target_ops): Now a process_stratum_target.
4535 * nto-low.c (nto_target_ops): Now a process_stratum_target.
4536 * linux-low.c (linux_target_ops): Now a process_stratum_target.
4537 * remote-utils.c (prepare_resume_reply): Pass the target to
4538 switch_to_thread.
4539 * target.c (the_target): Now a process_stratum_target.
4540 (done_accessing_memory): Pass the target to switch_to_thread.
4541 (set_target_ops): Ajust to use process_stratum_target.
4542 * target.h (struct target_ops): Rename to ...
4543 (struct process_stratum_target): ... this.
4544 (the_target, set_target_ops): Adjust.
4545 (prepare_to_access_memory): Adjust comment.
4546 * win32-low.c (child_xfer_memory): Adjust to use
4547 process_stratum_target.
4548 (win32_target_ops): Now a process_stratum_target.
4549
4550 2020-01-06 Eli Zaretskii <eliz@gnu.org>
4551 Pedro Alves <palves@redhat.com>
4552
4553 * win32-low.c (get_child_debug_event): Extract the fatal exception
4554 from the exit status and convert to the equivalent Posix signal
4555 number.
4556 (win32_wait): Allow TARGET_WAITKIND_SIGNALLED status as well.
4557 * Makefile.in (OBS, SFILES): Add gdb_wait.[co].
4558
4559 2020-01-01 Hannes Domani <ssbssa@yahoo.de>
4560
4561 * Makefile.in: Use INSTALL_PROGRAM_ENV.
4562
4563 2020-01-01 Joel Brobecker <brobecker@adacore.com>
4564
4565 * server.c (gdbserver_version): Change copyright year to 2020.
4566 * gdbreplay.c (gdbreplay_version): Likewise.
4567
4568 2019-12-19 Christian Biesinger <cbiesinger@google.com>
4569
4570 * configure: Regenerate.
4571 * configure.ac: Quote variable arguments of test.
4572
4573 2019-12-16 Bernd Edlinger <bernd.edlinger@hotmail.de>
4574
4575 * Makefile.in: Fix build with GNU Make 3.81
4576
4577 2019-12-16 Tom Tromey <tromey@adacore.com>
4578
4579 * server.c (get_exec_file): Constify result.
4580
4581 2019-12-10 Christian Biesinger <cbiesinger@google.com>
4582
4583 * Makefile.in: Add safe-strerror.c to gdbreplay and IPA, and change
4584 UNDO_GNULIB_CFLAGS to undo strerror_r instead of strerror.
4585 * config.in: Regenerate.
4586 * configure: Regenerate.
4587 * configure.ac: Don't check for strerror.
4588 * linux-i386-ipa.c (initialize_fast_tracepoint_trampoline_buffer):
4589 Call safe_strerror instead of strerror.
4590 * server.h (strerror): Remove this now-unnecessary declaration.
4591 * tracepoint.c (init_named_socket): Call safe_strerror instead of
4592 strerror.
4593 (gdb_agent_helper_thread): Likewise.
4594 * utils.c (perror_with_name): Likewise.
4595
4596 2019-11-26 Tom Tromey <tom@tromey.com>
4597
4598 * configure, config.in: Rebuild.
4599
4600 2019-11-26 Tom Tromey <tom@tromey.com>
4601
4602 * remote-utils.c (block_unblock_async_io): Use gdb_sigmask.
4603 * linux-low.c (linux_wait_for_event_filtered, linux_async): Use
4604 gdb_sigmask.
4605 * configure, config.in: Rebuild.
4606
4607 2019-11-26 Tom Tromey <tom@tromey.com>
4608
4609 * Makefile.in (PTHREAD_CFLAGS, PTHREAD_LIBS): New variables.
4610 (INTERNAL_CFLAGS_BASE): Use PTHREAD_CFLAGS.
4611 (GDBSERVER_LIBS): Use PTHREAD_LIBS.
4612 * acinclude.m4: Include ax_pthread.m4.
4613 * config.in, configure: Rebuild.
4614
4615 2019-11-26 Christian Biesinger <cbiesinger@google.com>
4616
4617 * debug.c (debug_set_output): Call safe_strerror instead of
4618 strerror.
4619 * linux-low.c (attach_proc_task_lwp_callback): Likewise.
4620 (linux_kill_one_lwp): Likewise.
4621 (linux_detach_one_lwp): Likewise.
4622 (linux_wait_for_event_filtered): Likewise.
4623 (store_register): Likewise.
4624 * lynx-low.c (lynx_attach): Likewise.
4625 * mem-break.c (insert_memory_breakpoint): Likewise.
4626 (remove_memory_breakpoint): Likewise.
4627 (delete_fast_tracepoint_jump): Likewise.
4628 (set_fast_tracepoint_jump): Likewise.
4629 (uninsert_fast_tracepoint_jumps_at): Likewise.
4630 (reinsert_fast_tracepoint_jumps_at): Likewise.
4631 * nto-low.c (nto_xfer_memory): Likewise.
4632 (nto_resume): Likewise.
4633
4634 2019-11-20 Luis Machado <luis.machado@linaro.org>
4635
4636 * linux-aarch64-low.c (is_sve_tdesc): Check against target feature
4637 instead of register count.
4638 * tdesc.c (tdesc_contains_feature): New function.
4639 * tdesc.h (tdesc_contains_feature): New prototype.
4640
4641 2019-11-15 Christian Biesinger <cbiesinger@google.com>
4642
4643 * Makefile.in: Add safe-strerror.c.
4644 * configure: Regenerate.
4645 * configure.ac: Don't source common.host.
4646
4647 2019-11-15 Christian Biesinger <cbiesinger@google.com>
4648
4649 * config.in: Regenerate.
4650 * configure: Regenerate.
4651
4652 2019-11-12 Andrew Burgess <andrew.burgess@embecosm.com>
4653
4654 * ax.c (ax_printf): Handle size_t_arg.
4655
4656 2019-11-06 Christian Biesinger <cbiesinger@google.com>
4657
4658 * linux-tdep.c (linux_info_proc): Use strtok_r instead of strtok.
4659 * mi/mi-main.c (output_cores): Likewise.
4660 * nat/linux-osdata.c (linux_xfer_osdata_cpus): Likewise.
4661 (linux_xfer_osdata_modules): Likewise.
4662 * remote.c (register_remote_support_xml): Likewise.
4663 * sparc64-tdep.c (adi_is_addr_mapped): Likewise.
4664 * xml-syscall.c (syscall_create_syscall_desc): Likewise.
4665
4666 2019-11-01 Christian Biesinger <cbiesinger@google.com>
4667
4668 * configure: Regenerate.
4669 * configure.ac: Remove check for strerror_r.
4670
4671 2019-10-31 Christian Biesinger <cbiesinger@google.com>
4672
4673 * config.in: Regenerate.
4674 * configure: Regenerate.
4675 * configure.ac: Also check for strerror_r.
4676
4677 2019-10-31 Christian Biesinger <cbiesinger@google.com>
4678
4679 * ax.h (debug_agent): Remove duplicate declaration.
4680
4681 2019-10-26 Tom de Vries <tdevries@suse.de>
4682
4683 * linux-aarch64-low.c: Fix typos in comments.
4684 * linux-arm-low.c: Same.
4685 * linux-low.c: Same.
4686 * linux-ppc-low.c: Same.
4687 * proc-service.c: Same.
4688 * regcache.h: Same.
4689 * server.c: Same.
4690 * tracepoint.c: Same.
4691 * win32-low.c: Same.
4692
4693 2019-10-25 Tom Tromey <tromey@adacore.com>
4694
4695 * utils.c (xstrdup): Remove.
4696
4697 2019-10-23 Tom Tromey <tom@tromey.com>
4698
4699 * configure, config.in: Rebuild.
4700
4701 2019-10-23 Tom Tromey <tom@tromey.com>
4702
4703 * configure: Rebuild.
4704 * acinclude.m4: Use m4_include, not sinclude.
4705
4706 2019-10-17 Tom Tromey <tromey@adacore.com>
4707
4708 * configure: Rebuild.
4709 * configure.ac: Use AC_CONFIG_HEADERS. Create stamp-h there, not
4710 in AC_CONFIG_FILES invocation.
4711 * Makefile.in (stamp-h, Makefile): Use new-style config.status
4712 invocation.
4713
4714 2019-10-16 Christian Biesinger <cbiesinger@google.com>
4715
4716 * server.c: Include xml-builtin.h.
4717 (get_xml_features): Don't declare xml_builtins here.
4718
4719 2019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
4720
4721 * Makefile.in: Remove references to vec-ipa.o.
4722
4723 2019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
4724
4725 * Makefile.in: Remove references to vec.c.
4726
4727 2019-10-02 Christian Biesinger <cbiesinger@google.com>
4728
4729 * server.c (server_waiting): Change to bool.
4730 (extended_protocol): Likewise.
4731 (response_needed): Likewise.
4732 (exit_requested): Likewise.
4733 (run_once): Likewise.
4734 (report_no_resumed): Likewise.
4735 (non_stop): Likewise.
4736 (disable_packet_vCont): Likewise.
4737 (disable_packet_Tthread): Likewise.
4738 (disable_packet_qC): Likewise.
4739 (disable_packet_qfThreadInfo): Likewise.
4740 (handle_general_set): Update.
4741 (handle_detach): Update.
4742 (handle_monitor_command): Update.
4743 (handle_query): Update.
4744 (captured_main): Update.
4745 (process_serial_event): Update.
4746 * server.h (server_waiting): Change to bool.
4747 (disable_packet_vCont): Likewise.
4748 (disable_packet_Tthread): Likewise.
4749 (disable_packet_qC): Likewise.
4750 (disable_packet_qfThreadInfo): Likewise.
4751 (run_once): Likewise.
4752 (non_stop): Likewise.
4753 * target.c (target_stop_and_wait): Update.
4754
4755 2019-10-02 Tom Tromey <tromey@adacore.com>
4756
4757 * Makefile.in (SFILES): Add common-inferior.c.
4758 (OBS): Add common-inferior.o.
4759 * server.c (startup_with_shell): Don't define.
4760
4761 2019-10-02 Andrew Burgess <andrew.burgess@embecosm.com>
4762
4763 * linux-low.c (linux_low_read_btrace): Update for change to
4764 std::vector.
4765
4766 2019-09-20 Christian Biesinger <cbiesinger@google.com>
4767
4768 * debug.c (debug_threads): Remove comment in favor of the header.
4769 * debug.h (using_threads): Add declaration.
4770 (debug_threads): Add comment.
4771 * linux-aarch64-low.c: Include debug.h and remove declaration of
4772 debug_threads.
4773 * nto-low.c: Likewise.
4774 * remote-utils.c: Likewise.
4775 * thread-db.c: Likewise.
4776
4777 2019-09-20 Ulrich Weigand <uweigand@de.ibm.com>
4778
4779 * configure.srv (ipa_ppc_linux_regobj): Remove powerpc-cell32l-ipa.o
4780 and powerpc-cell64l-ipa.o.
4781 (powerpc*-*-linux*): Remove powerpc-cell32l.o and powerpc-cell64l.o
4782 from srv_regobj. Remove rs6000/powerpc-cell32l.xml and
4783 rs6000/powerpc-cell64l.xml from srv_xmlfiles.
4784 (spu*-*-*): Remove.
4785
4786 * spu-low.c: Remove file.
4787
4788 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Remove.
4789 (parse_spufs_run): Remove.
4790 (ppc_get_pc): Remove Cell/B.E. support.
4791 (ppc_set_pc): Likewise.
4792 (ppc_breakpoint_at): Likewise.
4793 (ppc_arch_setup): Likewise.
4794 (ppc_get_ipa_tdesc_idx): Do not handle tdesc_powerpc_cell64l or
4795 tdesc_powerpc_cell32l.
4796 (initialize_low_arch): Do not call init_registers_powerpc_cell64l
4797 or init_registers_powerpc_cell32l.
4798 * linux-ppc-ipa.c (get_ipa_tdesc): Do not handle PPC_TDESC_CELL.
4799 (initialize_low_tracepoint): Do not call init_registers_powerpc_cell64l
4800 or init_registers_powerpc_cell32l.
4801 * linux-ppc-tdesc-init.h (PPC_TDESC_CELL): Mark as unused.
4802 (init_registers_powerpc_cell32l): Remove prototype.
4803 (init_registers_powerpc_cell64l): Likewise.
4804
4805 * target.h (struct target_ops): Remove qxfer_spu member.
4806 * server.c (handle_qxfer_spu): Remove.
4807 (qxfer_packets): Remove entry for "spu".
4808 (handle_query): No longer support qXfer:spu:read or qXfer:spu:write.
4809 * linux-low.c (SPUFS_MAGIC): Remove.
4810 (spu_enumerate_spu_ids): Remove.
4811 (linux_qxfer_spu): Remove.
4812 (linux_target_ops): Remove qxfer_spu member.
4813 * lynx-low.c (lynx_target_ops): Remove qxfer_spu member.
4814 * nto-low.c (nto_target_ops): Remove qxfer_spu member.
4815 * win32-low.c (win32_target_ops): Remove qxfer_spu member.
4816
4817 2019-08-23 Sergio Durigan Junior <sergiodj@redhat.com>
4818
4819 * Makefile.in (SFILES): Add 'gdbsupport/gdb-dlfcn.c'.
4820 (OBS): Add 'gdbsupport/gdb-dlfcn.o'.
4821 * config.in: Regenerate.
4822 * configure: Regenerate.
4823
4824 2019-08-15 Tom Tromey <tromey@adacore.com>
4825
4826 * target.c (target_write_memory): Use gdb::byte_vector.
4827
4828 2019-08-15 Tom Tromey <tromey@adacore.com>
4829
4830 * tracepoint.c (write_inferior_data_pointer)
4831 (write_inferior_integer, write_inferior_int8)
4832 (write_inferior_uinteger, m_tracepoint_action_download)
4833 (r_tracepoint_action_download, x_tracepoint_action_download)
4834 (l_tracepoint_action_download, clear_inferior_trace_buffer)
4835 (download_agent_expr, download_tracepoint_1)
4836 (download_trace_state_variables, upload_fast_traceframes): Update.
4837 * server.c (gdb_write_memory): Update.
4838 * remote-utils.c (relocate_instruction): Update.
4839 * proc-service.c (ps_pdwrite): Update.
4840 * mem-break.c (remove_memory_breakpoint)
4841 (delete_fast_tracepoint_jump, set_fast_tracepoint_jump)
4842 (uninsert_fast_tracepoint_jumps_at)
4843 (reinsert_fast_tracepoint_jumps_at): Update.
4844 * linux-x86-low.c (append_insns)
4845 (i386_install_fast_tracepoint_jump_pad)
4846 (amd64_write_goto_address, i386_write_goto_address): Update.
4847 * linux-s390-low.c (append_insns, s390_write_goto_address):
4848 Update.
4849 * linux-ppc-low.c (ppc_relocate_instruction)
4850 (ppc_install_fast_tracepoint_jump_pad, emit_insns)
4851 (ppc_write_goto_address): Update.
4852 * linux-aarch64-low.c (append_insns): Update.
4853 * target.h (struct target_ops): Update.
4854 (write_inferior_memory): Don't declare.
4855 * target.c (target_write_memory): Rename from
4856 write_inferior_memory. Remove old target_write_memory.
4857
4858 2019-08-15 Tom Tromey <tromey@adacore.com>
4859
4860 * target.c (write_inferior_memory): Use std::vector.
4861
4862 2019-08-06 Frank Ch. Eigler <fche@redhat.com>
4863
4864 PR build/24886
4865 * configure.ac: Drop enable-libmcheck support.
4866 * configure, config.in: Rebuild.
4867 * acinclude.m4: Don't include it.
4868
4869 2019-07-19 Alan Hayward <alan.hayward@arm.com>
4870
4871 * configure.srv: Remove Arm xml files.
4872
4873 2019-07-19 Alan Hayward <alan.hayward@arm.com>
4874
4875 * configure.srv: Add new files. Remove xml generated files.
4876 * linux-aarch32-low.c (initialize_low_arch_aarch32): Don't init
4877 registers.
4878 * linux-aarch32-low.h (tdesc_arm_with_neon): Remove.
4879 * linux-aarch32-tdesc.c: New file.
4880 * linux-aarch32-tdesc.h: New file.
4881 * linux-aarch64-low.c (aarch64_arch_setup): Call aarch32_linux_read_description.
4882 * linux-arm-low.c (init_registers_arm, tdesc_arm)
4883 (init_registers_arm_with_iwmmxt, tdesc_arm_with_iwmmxt)
4884 (init_registers_arm_with_vfpv2, tdesc_arm_with_vfpv2)
4885 (init_registers_arm_with_vfpv3, tdesc_arm_with_vfpv3): Remove.
4886 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
4887 (arm_store_vfpregset): Call arm_linux_get_tdesc_fp_type.
4888 (arm_read_description): Call arm_linux_read_description.
4889 (initialize_low_arch): Don't init registers.
4890 * linux-arm-tdesc.c: New file.
4891 * linux-arm-tdesc.h: New file.
4892
4893 2019-07-10 Alan Hayward <alan.hayward@arm.com>
4894
4895 * linux-arm-low.c (arm_fill_wmmxregset, arm_store_wmmxregset):
4896 Move counter inside for.
4897 (arm_read_description): Check ptrace earlier.
4898 (arm_arch_setup): Call arm_linux_init_hwbp_cap here.
4899
4900 2019-07-09 Tom Tromey <tom@tromey.com>
4901
4902 * configure: Rebuild.
4903 * configure.ac: Change common to gdbsupport.
4904 * acinclude.m4: Change common to gdbsupport.
4905 * Makefile.in (SFILES, OBS, GDBREPLAY_OBS, IPA_OBJS)
4906 (version-generated.c, gdbsupport/%-ipa.o, gdbsupport/%.o): Change
4907 common to gdbsupport.
4908 * ax.c, event-loop.c, fork-child.c, gdb_proc_service.h,
4909 gdbreplay.c, gdbthread.h, hostio-errno.c, hostio.c, i387-fp.c,
4910 inferiors.c, inferiors.h, linux-aarch64-tdesc-selftest.c,
4911 linux-amd64-ipa.c, linux-i386-ipa.c, linux-low.c,
4912 linux-tic6x-low.c, linux-x86-low.c, linux-x86-tdesc-selftest.c,
4913 linux-x86-tdesc.c, lynx-i386-low.c, lynx-low.c, mem-break.h,
4914 nto-x86-low.c, regcache.c, regcache.h, remote-utils.c, server.c,
4915 server.h, spu-low.c, symbol.c, target.h, tdesc.c, tdesc.h,
4916 thread-db.c, tracepoint.c, win32-i386-low.c, win32-low.c: Change
4917 common to gdbsupport.
4918
4919 2019-07-04 Alan Hayward <alan.hayward@arm.com>
4920
4921 * linux-aarch32-low.c (arm_read_description, arm_regsets): Use new
4922 defines.
4923 * linux-arm-low.c (arm_read_description, arm_regsets): Likewise.
4924
4925 2019-07-04 Alan Hayward <alan.hayward@arm.com>
4926
4927 * configure.srv: Remove legacy xml.
4928 * linux-aarch64-low.c (initialize_low_arch): Remove
4929 initialize_low_tdesc call.
4930 * linux-aarch64-tdesc-selftest.c: Remove file.
4931 * linux-aarch64-tdesc.h (initialize_low_tdesc): Remove.
4932 * linux-x86-low.c (initialize_low_arch): Remove
4933 initialize_low_tdesc call.
4934 * linux-x86-tdesc-selftest.c: Remove file.
4935 * linux-x86-tdesc.h (initialize_low_tdesc): Remove.
4936
4937 2019-06-20 Tom de Vries <tdevries@suse.de>
4938
4939 * linux-s390-ipa.c (get_ipa_tdesc)[!__s390x__]: Use
4940 s390_te_linux64_ft_collect_regmap for S390_TDESC_GS.
4941
4942 2019-06-19 Tom de Vries <tdevries@suse.de>
4943
4944 * debug.h (debug_write): Change return type to ssize_t.
4945 * debug.c (debug_write): Same.
4946
4947 2019-06-14 Tom Tromey <tom@tromey.com>
4948
4949 * configure.ac: Use new path to gnulib.
4950 * configure: Rebuild.
4951 * Makefile.in (INCGNU, $(GNULIB_BUILDDIR)/Makefile): Use new path
4952 to gnulib.
4953
4954 2019-06-11 Tom Tromey <tom@tromey.com>
4955
4956 * Makefile.in (SFILES): Add alloc.c.
4957 (OBS): Add alloc.o.
4958 (IPA_OBJS): Add alloc-ipa.o.
4959 (alloc-ipa.o): New target.
4960 (%.o: ../%.c): New pattern rule.
4961
4962 2019-06-10 Tom Tromey <tromey@adacore.com>
4963
4964 * remote-utils.c (look_up_one_symbol, relocate_instruction): Don't
4965 end warning with a newline.
4966 * linux-s390-low.c (s390_get_wordsize): Don't end warning with a
4967 newline.
4968 * thread-db.c (attach_thread): Don't end warning with a newline.
4969 (thread_db_notice_clone): Likewise.
4970 * tracepoint.c (gdb_agent_helper_thread): Don't end warning with a
4971 newline.
4972 * linux-x86-low.c (x86_get_min_fast_tracepoint_insn_len): Don't
4973 end warning with a newline.
4974
4975 2019-06-04 Pedro Alves <palves@redhat.com>
4976
4977 * server.c (captured_main): Use make_unique_xstrdup.
4978
4979 2019-06-02 Tom Tromey <tom@tromey.com>
4980
4981 * gdbreplay.c (fromhex): Remove.
4982 * Makefile.in (GDBREPLAY_OBS): Add rsp-low.o.
4983
4984 2019-05-29 Tom Tromey <tromey@adacore.com>
4985
4986 * configure: Rebuild.
4987
4988 2019-05-06 Kevin Buettner <kevinb@redhat.com>
4989
4990 * linux-x86-low.c (x86_fill_gregset): Don't compile 64-bit
4991 sign extension code on 32-bit builds.
4992
4993 2019-05-03 Eli Zaretskii <eliz@gnu.org>
4994
4995 * remote-utils.c:
4996 * gdbreplay.c [USE_WIN32API]: Remove the _WIN32_WINNT override.
4997
4998 2019-04-19 Tom Tromey <tom@tromey.com>
4999
5000 * server.c (struct vstop_notif): Derive from notif_event.
5001 <base>: Remove.
5002 (queue_stop_reply): Update.
5003 (remove_all_on_match_ptid): Change type. Rewrite.
5004 (discard_queued_stop_replies): Rewrite.
5005 (in_queued_stop_replies_ptid): Change type.
5006 (in_queued_stop_replies): Rewrite.
5007 (notif_stop): Update.
5008 (queue_stop_reply_callback): Update.
5009 (captured_main): Don't call initialize_notif.
5010 (push_stop_notification): Update.
5011 * notif.c (notif_write_event, handle_notif_ack)
5012 (notif_event_enque, notif_push): Update.
5013 (notif_event_xfree, initialize_notif): Remove.
5014 * notif.h (struct notif_event): Include <list>, not
5015 "common/queue.h".
5016 (struct notif_server) <queue>: Now a std::list.
5017 (notif_event_p): Remove typedef.
5018 (initialize_notif): Don't declare.
5019 (struct notif_event): Add virtual destructor.
5020
5021 2019-04-17 Alan Hayward <alan.hayward@arm.com>
5022
5023 * ax.c (ax_vdebug): Call debug_printf.
5024 * debug.c (debug_write): New function.
5025 * debug.h (debug_write): New declaration.
5026 * linux-low.c (sigchld_handler): Call debug_write.
5027
5028 2019-04-17 Alan Hayward <alan.hayward@arm.com>
5029
5030 * debug.c (debug_set_output): New function.
5031 (debug_vprintf): Send output to debug_file.
5032 (debug_flush): Likewise.
5033 * debug.h (debug_set_output): New declaration.
5034 * server.c (handle_monitor_command): Add debug-file option.
5035 (captured_main): Likewise.
5036
5037 2019-04-17 Alan Hayward <alan.hayward@arm.com>
5038
5039 * debug.c (remote_debug): Add definition.
5040 * debug.h (remote_debug): Add declaration.
5041 * hostio.c (remote_debug): Remove declaration.
5042 * remote-utils.c (struct ui_file): Likewise.
5043 (remote_debug): Likewise.
5044 * remote-utils.h (remote_debug): Likewise,
5045 * server.c (remote_debug): Remove definition.
5046
5047 2019-04-10 Kevin Buettner <kevinb@redhat.com>
5048
5049 * linux-x86-low.c (x86_fill_gregset): Sign extend EAX value
5050 when using a 64-bit gdbserver.
5051
5052 2019-04-09 Tom Tromey <tromey@adacore.com>
5053
5054 * linux-low.c (select_event_lwp): Use find_thread_in_random.
5055
5056 2019-04-08 Tom Tromey <tom@tromey.com>
5057
5058 * linux-low.c (linux_detach_one_lwp): Replace throw_exception with
5059 throw.
5060 (linux_resume_one_lwp): Likewise.
5061
5062 2019-04-08 Tom Tromey <tom@tromey.com>
5063
5064 * gdbreplay.c: Update.
5065 * linux-low.c: Update.
5066 * server.c: Update.
5067
5068 2019-04-08 Tom Tromey <tom@tromey.com>
5069
5070 * server.c: Use C++ exception handling.
5071 * linux-low.c: Use C++ exception handling.
5072 * gdbreplay.c: Use C++ exception handling.
5073
5074 2019-04-08 Tom Tromey <tom@tromey.com>
5075
5076 * server.c (handle_btrace_general_set, handle_qxfer_btrace)
5077 (handle_qxfer_btrace_conf, detach_or_kill_for_exit_cleanup)
5078 (captured_main, main): Update.
5079 * gdbreplay.c (main): Update.
5080
5081 2019-04-05 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5082
5083 * linux-low.c (linux_get_auxv): Remove static. Return auxv entry
5084 value in argument pointer, return 1 if the entry is found and 0
5085 otherwise. Move comment.
5086 (linux_get_hwcap, linux_get_hwcap2): Use modified linux_get_auxv.
5087 * linux-low.h (linux_get_auxv): Declare.
5088 * linux-ppc-low.c (is_elfv2_inferior): Use linux_get_auxv.
5089
5090 2019-04-05 Tom Tromey <tromey@adacore.com>
5091
5092 * server.c (gdbserver_usage): Use upper-case for metasyntactic
5093 variables.
5094
5095 2019-03-28 Alan Hayward <alan.hayward@arm.com>
5096
5097 * linux-low.c (AT_HWCAP2): Add define if not already included.
5098
5099 2019-03-26 Alan Hayward <alan.hayward@arm.com>
5100
5101 * linux-aarch64-low.c (aarch64_get_hwcap): Remove function.
5102 (aarch64_arch_setup): Call linux_get_hwcap.
5103 * linux-arm-low.c (arm_get_hwcap): Remove function.
5104 (arm_read_description): Call linux_get_hwcap.
5105 * linux-low.c (linux_get_auxv): New function.
5106 (linux_get_hwcap): Likewise.
5107 (linux_get_hwcap2): Likewise.
5108 * linux-low.h (linux_get_hwcap): New declaration.
5109 (linux_get_hwcap2): Likewise.
5110 * linux-ppc-low.c (ppc_get_auxv): Remove function.
5111 (ppc_arch_setup): Call linux_get_hwcap.
5112 * linux-s390-low.c (s390_get_hwcap): Remove function.
5113 (s390_arch_setup): Call linux_get_hwcap.
5114
5115 2019-03-22 Alan Hayward <alan.hayward@arm.com>
5116 Jiong Wang <jiong.wang@arm.com>
5117
5118 * linux-aarch64-low.c (aarch64_store_pauthregset): New function.
5119 * linux-low.c (regsets_store_inferior_registers): Allow optional reads
5120 to fail.
5121 * linux-low.h (enum regset_type): Add OPTIONAL_REGS.
5122
5123 2019-03-22 Alan Hayward <alan.hayward@arm.com>
5124 Jiong Wang <jiong.wang@arm.com>
5125
5126 * linux-aarch64-low.c (AARCH64_HWCAP_PACA): New define.
5127 (aarch64_get_hwcap): New function.
5128 (aarch64_arch_setup): Read APIA hwcap.
5129
5130 2019-03-22 Alan Hayward <alan.hayward@arm.com>
5131 Jiong Wang <jiong.wang@arm.com>
5132
5133 * linux-aarch64-ipa.c (get_ipa_tdesc): Add pauth param.
5134 (initialize_low_tracepoint): Likewise.
5135 * linux-aarch64-low.c (aarch64_arch_setup): Likewise.
5136 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Likewise.
5137 * linux-aarch64-tdesc.c (struct target_desc): Likewise.
5138 (aarch64_linux_read_description): Likewise.
5139 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Likewise.
5140
5141 2019-03-12 John Baldwin <jhb@FreeBSD.org>
5142
5143 * linux-x86-tdesc.c (i386_linux_read_description): Update call to
5144 i386_create_target_description for 'segments' parameter.
5145 * lynx-i386-low.c (lynx_i386_arch_setup): Likewise.
5146 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
5147 * win32-i386-low.c (i386_arch_setup): Likewise.
5148
5149 2019-03-12 Tom Tromey <tromey@adacore.com>
5150
5151 * linux-low.c (iterate_over_lwps): Update.
5152
5153 2019-03-06 Tom Tromey <tom@tromey.com>
5154
5155 * server.c (detach_or_kill_for_exit_cleanup): Remove parameter.
5156 (captured_main): Use SCOPE_EXIT.
5157
5158 2019-03-04 Sergio Durigan Junior <sergiodj@redhat.com>
5159
5160 * configure.srv: Use '$enable_unittest' instead of '$development'
5161 when checking whether to fill 'srv_regobj' on 'aarch64*-*-linux*'
5162 case.
5163
5164 2019-02-27 Tom Tromey <tromey@adacore.com>
5165
5166 * gdbreplay.c (logchar): Handle \r\n.
5167
5168 2019-02-07 Alan Hayward <alan.hayward@arm.com>
5169
5170 * linux-low.c (linux_attach): Add process before lwp.
5171 * server.c (attach_inferior): Check if already attached.
5172
5173 2019-02-07 Tom Tromey <tom@tromey.com>
5174
5175 * x86-tdesc.h: Rename include guard.
5176 * x86-low.h: Add include guard.
5177 * wincecompat.h: Rename include guard.
5178 * win32-low.h: Add include guard.
5179 * utils.h: Rename include guard.
5180 * tracepoint.h: Rename include guard.
5181 * tdesc.h: Rename include guard.
5182 * target.h: Rename include guard.
5183 * server.h: Rename include guard.
5184 * remote-utils.h: Rename include guard.
5185 * regcache.h: Rename include guard.
5186 * nto-low.h: Rename include guard.
5187 * notif.h: Add include guard.
5188 * mem-break.h: Rename include guard.
5189 * lynx-low.h: Add include guard.
5190 * linux-x86-tdesc.h: Add include guard.
5191 * linux-s390-tdesc.h: Add include guard.
5192 * linux-ppc-tdesc-init.h: Add include guard.
5193 * linux-low.h: Add include guard.
5194 * linux-aarch64-tdesc.h: Add include guard.
5195 * linux-aarch32-low.h: Add include guard.
5196 * inferiors.h: Rename include guard.
5197 * i387-fp.h: Rename include guard.
5198 * hostio.h: Rename include guard.
5199 * gdbthread.h: Rename include guard.
5200 * gdb_proc_service.h: Rename include guard.
5201 * event-loop.h: Rename include guard.
5202 * dll.h: Rename include guard.
5203 * debug.h: Rename include guard.
5204 * ax.h: Rename include guard.
5205
5206 2018-01-30 Szabolcs Nagy <szabolcs.nagy@arm.com>
5207
5208 PR gdb/23985
5209 * Makefile.in (IPAGENT_CFLAGS): Add UNDO_GNULIB_CFLAGS.
5210 (UNDO_GNULIB_CFLAGS): Undo gnulib replacements.
5211
5212 2019-01-25 Tom Tromey <tom@tromey.com>
5213
5214 * Makefile.in (INCLUDE_CFLAGS): Don't add -I for common.
5215
5216 2019-01-25 Tom Tromey <tom@tromey.com>
5217
5218 * win32-low.c: Fix common/ includes.
5219 * win32-i386-low.c: Fix common/ includes.
5220 * tracepoint.c: Fix common/ includes.
5221 * thread-db.c: Fix common/ includes.
5222 * target.h: Fix common/ includes.
5223 * symbol.c: Fix common/ includes.
5224 * spu-low.c: Fix common/ includes.
5225 * server.h: Fix common/ includes.
5226 * server.c: Fix common/ includes.
5227 * remote-utils.c: Fix common/ includes.
5228 * regcache.h: Fix common/ includes.
5229 * regcache.c: Fix common/ includes.
5230 * nto-x86-low.c: Fix common/ includes.
5231 * notif.h: Fix common/ includes.
5232 * mem-break.h: Fix common/ includes.
5233 * lynx-low.c: Fix common/ includes.
5234 * lynx-i386-low.c: Fix common/ includes.
5235 * linux-x86-tdesc-selftest.c: Fix common/ includes.
5236 * linux-x86-low.c: Fix common/ includes.
5237 * linux-low.c: Fix common/ includes.
5238 * inferiors.h: Fix common/ includes.
5239 * i387-fp.c: Fix common/ includes.
5240 * hostio.c: Fix common/ includes.
5241 * hostio-errno.c: Fix common/ includes.
5242 * gdbthread.h: Fix common/ includes.
5243 * gdbreplay.c: Fix common/ includes.
5244 * fork-child.c: Fix common/ includes.
5245 * event-loop.c: Fix common/ includes.
5246 * ax.c:
5247 (enum gdb_agent_op): Fix common/ includes.
5248
5249 2019-01-21 Tom Tromey <tom@tromey.com>
5250
5251 * tracepoint.c: Fix includes.
5252 * remote-utils.c: Fix includes.
5253 * linux-x86-low.c: Fix includes.
5254
5255 2019-01-01 Joel Brobecker <brobecker@adacore.com>
5256
5257 * gdbreplay.c (gdbreplay_version): Update copyright year in
5258 version message.
5259 * server.c (gdbserver_version): Likewise.
5260
5261 2018-12-05 Alan Hayward <alan.hayward@arm.com>
5262
5263 * linux-low.c (add_lwp): Switch ordering.
5264
5265 2018-11-29 Tom Tromey <tom@tromey.com>
5266
5267 * win32-low.c (win32_join): Take pid, not process.
5268 * target.h (struct target_ops) <join>: Change argument type.
5269 (join_inferior): Change argument name.
5270 * spu-low.c (spu_join): Take pid, not process.
5271 * server.c (handle_detach): Preserve pid before destroying
5272 process.
5273 * lynx-low.c (lynx_join): Take pid, not process.
5274 * linux-low.c (linux_join): Take pid, not process.
5275
5276 2018-11-23 Alan Hayward <alan.hayward@arm.com>
5277
5278 * linux-aarch64-low.c (aarch64_cannot_store_register): Remove.
5279 (aarch64_cannot_fetch_register): Likewise.
5280 (struct linux_target_ops): Update references.
5281
5282 2018-10-31 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5283
5284 * linux-ppc-low.c: Include nat/linux-ptrace.h.
5285
5286 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5287
5288 * configure.srv (ipa_ppc_linux_regobj): Add
5289 powerpc-isa207-htm-vsx32l-ipa.o and
5290 powerpc-isa207-htm-vsx64l-ipa.o.
5291 (powerpc*-*-linux*): Add powerpc-isa207-htm-vsx32l.o and
5292 powerpc-isa207-htm-vsx64l.o to srv_regobj. Add
5293 rs6000/power-htm-spr.xml, rs6000/power-htm-core.xml,
5294 rs6000/power64-htm-core.xml, rs6000/power-htm-fpu.xml,
5295 rs6000/power-htm-altivec.xml, rs6000/power-htm-vsx.xml,
5296 rs6000/power-htm-ppr.xml, rs6000/power-htm-dscr.xml,
5297 rs6000/power-htm-tar.xml, rs6000/powerpc-isa207-htm-vsx32l.xml,
5298 and rs6000/powerpc-isa207-htm-vsx64l.xml to srv_xmlfiles.
5299 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
5300 <PPC_TDESC_ISA207_HTM_VSX>: New enum value.
5301 (init_registers_powerpc_isa207_htm_vsx32l)
5302 (init_registers_powerpc_isa207_htm_vsx64l): Declare.
5303 * linux-ppc-low.c (ppc_fill_tm_sprregset, ppc_store_tm_sprregset)
5304 (ppc_store_tm_cgprregset, ppc_store_tm_cfprregset)
5305 (ppc_store_tm_cvrregset, ppc_store_tm_cvsxregset)
5306 (ppc_store_tm_cpprregset, ppc_store_tm_cdscrregset)
5307 (ppc_store_tm_ctarregset): New functions.
5308 (ppc_regsets): Add entries for HTM regsets.
5309 (ppc_arch_setup): Set htm in features struct when needed. Set
5310 sizes for the HTM regsets.
5311 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_HTM_VSX.
5312 (initialize_low_arch): Call
5313 init_registers_powerpc_isa207_htm_vsx32l and
5314 init_registers_powerpc_isa207_htm_vsx64l.
5315 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
5316 PPC_TDESC_ISA207_HTM_VSX.
5317 (initialize_low_tracepoint): Call
5318 init_registers_powerpc_isa207_htm_vsx32l and
5319 init_registers_powerpc_isa207_htm_vsx64l.
5320
5321 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5322
5323 * configure.srv (powerpc*-*-linux*): Add rs6000/power-ebb.xml and
5324 rs6000/power-linux-pmu.xml to srv_xmlfiles.
5325 * linux-ppc-low.c (ppc_store_ebbregset, ppc_fill_pmuregset)
5326 (ppc_store_pmuregset): New functions.
5327 (ppc_regsets): Add entries for ebb and pmu regsets.
5328 (ppc_arch_setup): Set isa207 in features struct if the ebb and
5329 pmu regsets are available. Set sizes for these regsets.
5330
5331 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5332
5333 * configure.srv (ipa_ppc_linux_regobj): Add
5334 powerpc-isa207-vsx64l-ipa.o and powerpc-isa207-vsx32l-ipa.o.
5335 (powerpc*-*-linux*): Add powerpc-isa207-vsx32l.o and
5336 powerpc-isa207-vsx64l.o to srv_regobj, add rs6000/power-tar.xml,
5337 rs6000/powerpc-isa207-vsx32l.xml, and
5338 rs6000/powerpc-isa207-vsx64l.xml to srv_xmlfiles.
5339 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
5340 <PPC_TDESC_ISA207_VSX>: New enum value.
5341 (init_registers_powerpc_isa207_vsx32l): Declare.
5342 (init_registers_powerpc_isa207_vsx64l): Declare.
5343 * linux-ppc-low.c (ppc_fill_tarregset): New function.
5344 (ppc_store_tarregset): New function.
5345 (ppc_regsets): Add entry for the TAR regset.
5346 (ppc_arch_setup): Set isa207 in features struct when needed. Set
5347 size for the TAR regsets.
5348 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_VSX.
5349 (initialize_low_arch): Call init_registers_powerpc_isa207_vsx32l
5350 and init_registers_powerpc_isa207_vsx64l.
5351 * linux-ppc-ipa.c (get_ipa_tdesc): Handle PPC_TDESC_ISA207_VSX.
5352 (initialize_low_tracepoint): Call
5353 init_registers_powerpc_isa207_vsx32l and
5354 init_registers_powerpc_isa207_vsx64l.
5355
5356 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
5357 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5358
5359 * configure.srv (ipa_ppc_linux_regobj): Add
5360 powerpc-isa205-ppr-dscr-vsx32l-ipa.o and
5361 powerpc-isa205-ppr-dscr-vsx64l-ipa.o.
5362 (powerpc*-*-linux*): Add powerpc-isa205-ppr-dscr-vsx32l.o and
5363 powerpc-isa205-ppr-dscr-vsx64l.o to srv_regobj, add
5364 rs6000/power-dscr.xml, rs6000/power-ppr.xml,
5365 rs6000/powerpc-isa205-ppr-dscr-vsx32l.xml and
5366 rs6000/powerpc-isa205-ppr-dscr-vsx64l.xml to srv_xmlfiles.
5367 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
5368 <PPC_TDESC_ISA205_PPR_DSCR_VSX>: New enum value.
5369 (init_registers_powerpc_isa205_ppr_dscr_vsx32l)
5370 (init_registers_powerpc_isa205_ppr_dscr_vsx64l): Declare.
5371 * linux-ppc-low.c: Include "elf/common.h" and <sys/uio.h>.
5372 (ppc_hwcap): Add comment.
5373 (ppc_hwcap2): New global.
5374 (ppc_check_regset, ppc_fill_pprregset, ppc_store_pprregset)
5375 (ppc_fill_dscrregset, ppc_store_dscrregset): New functions.
5376 (ppc_regsets): Add entries for the DSCR and PPR regsets.
5377 (ppc_arch_setup): Get AT_HWCAP2. Set ppr_dscr in features struct
5378 when needed. Set sizes for the the DSCR and PPR regsets.
5379 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA205_PPR_DSCR_VSX.
5380 (initialize_low_arch): Call
5381 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
5382 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
5383 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
5384 PPC_TDESC_ISA205_PPR_DSCR_VSX.
5385 (initialize_low_tracepoint): Call
5386 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
5387 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
5388
5389 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5390
5391 * linux-ppc-low.c (ppc_fill_vrregset): Remove memset calls.
5392
5393 2018-10-10 Sergio Durigan Junior <sergiodj@redhat.com>
5394 Simon Marchi <simark@simark.ca>
5395
5396 * acinclude.m4: Include "../selftest.m4".
5397 * configure: Regenerate.
5398 * configure.ac: Use "GDB_AC_SELFTEST".
5399 * configure.srv: Use "$enable_unittests" instead of
5400 "$development" when checking whether unit tests have been
5401 enabled.
5402 * server.c (captured_main): Update message informing that
5403 selftests have been disabled.
5404
5405 2018-10-04 Tom Tromey <tom@tromey.com>
5406
5407 * configure: Rebuild.
5408
5409 2018-10-04 Tom Tromey <tom@tromey.com>
5410
5411 * server.c (handle_status): Rename inner "thread".
5412 (process_serial_event): Declare "res" in 'm' case.
5413 * linux-low.c (last_thread_of_process_p, find_lwp_pid)
5414 (iterate_over_lwps): Rename inner "thread".
5415 (linux_qxfer_libraries_svr4): Rename inner "len".
5416 * gdbthread.h (find_thread_in_random): Rename inner "thread".
5417
5418 2018-10-01 Gary Benson <gbenson@redhat.com>
5419
5420 * gdb_proc_service.h: Moved common code to
5421 common/gdb_proc_service.h.
5422
5423 2018-10-01 Gary Benson <gbenson@redhat.com>
5424
5425 * gdb_proc_service.h: Synchronize comments and whitespace with
5426 GDB's version of this file.
5427
5428 2018-09-25 Tom Tromey <tom@tromey.com>
5429
5430 * configure: Rebuild.
5431 * configure.ac (WARN_CFLAGS): Don't remove -Wmissing-prototypes.
5432
5433 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
5434
5435 * Makefile.in (gdbserver$(EXEEXT)): Sort OBS.
5436 (gdbreplay$(EXEEXT)): Sort GDBREPLAY_OBS.
5437 ($(IPA_LIB)): Sort IPA_OBJS.
5438
5439 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
5440
5441 * Makefile.in: Remove references to $(ADD_DEPS).
5442
5443 2018-09-16 Tom Tromey <tom@tromey.com>
5444
5445 * remote-utils.c (remote_open): Use GNU style for metasyntactic
5446 variables.
5447 * gdbreplay.c (gdbreplay_usage): Use GNU style for metasyntactic
5448 variables.
5449
5450 2018-09-05 Tom Tromey <tom@tromey.com>
5451
5452 * configure: Rebuild.
5453
5454 2018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
5455
5456 PR build/23399
5457 * tracepoint.c (IPA_SYM_STRUCT_NAME): Define.
5458
5459 2018-08-27 Tom Tromey <tom@tromey.com>
5460
5461 PR build/23087:
5462 * configure: Rebuild.
5463
5464 2018-08-27 Tom Tromey <tom@tromey.com>
5465
5466 * linux-s390-low.c (s390_emit_ext, s390_emit_litpool)
5467 (s390_emit_const, s390_emit_reg, s390_emit_zero_ext)
5468 (s390_emit_stack_adjust, s390_emit_set_r2, s390x_emit_ext)
5469 (s390x_emit_const, s390x_emit_reg, s390x_emit_zero_ext)
5470 (s390x_emit_stack_adjust): Add casts to unsigned char.
5471
5472 2018-08-22 Simon Marchi <simon.marchi@ericsson.com>
5473
5474 PR gdb/23374
5475 PR gdb/23375
5476 * server.h (struct client_state) <disable_randomization>:
5477 Initialize to 1.
5478
5479 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
5480
5481 * linux-mips-low.c (mips_collect_ptrace_register): Remove unused
5482 variable.
5483 (mips_supply_ptrace_register): Likewise.
5484
5485 2018-07-22 Tom Tromey <tom@tromey.com>
5486
5487 * configure: Rebuild.
5488
5489 2018-07-22 Tom Tromey <tom@tromey.com>
5490
5491 * win32-low.c (win32_create_inferior): Remove unused variables.
5492 * gdbreplay.c (remote_open): Remove unused variable.
5493 * remote-utils.c (remote_prepare): Remove unused variable.
5494 * x86-tdesc.h (X86_TDESC_H): Define.
5495 (amd64_expedite_regs): Define conditionally.
5496 (i386_expedite_regs): Mark ATTRIBUTE_UNUSED.
5497 * linux-x86-tdesc.c (i386_tdescs): Move inside #if.
5498 * remote-utils.c (readchar): Remove unused variable.
5499
5500 2018-07-13 Pedro Alves <palves@redhat.com>
5501
5502 * linux-low.c (linux_kill): Change parameter to process_info
5503 pointer instead of pid. Adjust.
5504 * lynx-low.c (lynx_kill): Likewise.
5505 * nto-low.c (nto_kill): Likewise.
5506 * spu-low.c (spu_kill): Likewise.
5507 * win32-low.c (win32_kill): Likewise.
5508 * server.c (handle_v_kill, kill_inferior_callback)
5509 (detach_or_kill_for_exit): Adjust.
5510 * target.c (kill_inferior): Change parameter to process_info
5511 pointer instead of pid. Adjust.
5512 * target.h (struct target_ops) <kill>: Change parameter to
5513 process_info pointer instead of pid. Adjust all implementations
5514 and callers.
5515 (kill_inferior): Likewise.
5516
5517 2018-07-13 Pedro Alves <palves@redhat.com>
5518
5519 * linux-low.c (linux_detach, linux_join): Change parameter to
5520 process_info pointer instead of pid. Adjust.
5521 * lynx-low.c (lynx_detach, lynx_join): Likewise.
5522 * nto-low.c (nto_detach): Likewise.
5523 * spu-low.c (spu_detach, spu_join): Likewise.
5524 * win32-low.c (win32_detach, win32_join): Likewise.
5525 * server.c (handle_detach, detach_or_kill_for_exit): Adjust.
5526 * target.h (struct target_ops) <detach, join>: Change parameter to
5527 process_info pointer instead of pid. Adjust all implementations
5528 and callers.
5529 (detach_inferior, join_inferior): Rename 'pid' parameter to
5530 'proc'.
5531
5532 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
5533 Jan Kratochvil <jan.kratochvil@redhat.com>
5534 Paul Fertser <fercerpav@gmail.com>
5535 Tsutomu Seki <sekiriki@gmail.com>
5536
5537 * Makefile.in (SFILES): Add '$(srcdir)/common/netstuff.c'.
5538 (OBS): Add 'common/netstuff.o'.
5539 (GDBREPLAY_OBS): Likewise.
5540 * gdbreplay.c: Include 'wspiapi.h' and 'netstuff.h'.
5541 (remote_open): Implement support for IPv6
5542 connections.
5543 * remote-utils.c: Include 'netstuff.h', 'filestuff.h'
5544 and 'wspiapi.h'.
5545 (handle_accept_event): Accept connections from IPv6 sources.
5546 (remote_prepare): Handle IPv6-style hostnames; implement
5547 support for IPv6 connections.
5548 (remote_open): Implement support for printing connections from
5549 IPv6 sources.
5550
5551 2018-07-11 Pedro Alves <palves@redhat.com>
5552
5553 PR gdb/23377
5554 * mem-break.c (any_persistent_commands): Add process_info
5555 parameter and use it instead of relying on the current process.
5556 Change return type to bool.
5557 * mem-break.h (any_persistent_commands): Add process_info
5558 parameter and change return type to bool.
5559 * server.c (handle_detach): Remove require_running_or_return call.
5560 Look up the process_info for the process we're about to detach.
5561 If not found, return back error to GDB. Adjust
5562 any_persistent_commands call to pass down a process pointer.
5563
5564 2018-07-11 Pedro Alves <palves@redhat.com>
5565
5566 * i387-fp.c (i387_cache_to_fsave, cache_to_fxsave)
5567 (i387_cache_to_xsave): Use regcache_raw_get_unsigned_by_name
5568 instead of collect_register_by_name.
5569 * regcache.c (regcache_raw_get_unsigned_by_name): New.
5570 * regcache.h (regcache_raw_get_unsigned_by_name): New.
5571
5572 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
5573 Pedro Alves <palves@redhat.com>
5574
5575 * linux-low.c (initialize_low): Call linux_proc_init_warnings.
5576
5577 2018-07-03 Tom Tromey <tom@tromey.com>
5578
5579 * linux-low.c: Update.
5580 * lynx-low.c: Update.
5581 * mem-break.c: Update.
5582 * nto-low.c: Update.
5583 * remote-utils.c: Update.
5584 * server.c: Update.
5585 * spu-low.c: Update.
5586 * target.c: Update.
5587 * win32-low.c: Update.
5588
5589 2018-07-03 Tom Tromey <tom@tromey.com>
5590
5591 * server.c: Update.
5592
5593 2018-07-03 Tom Tromey <tom@tromey.com>
5594
5595 * linux-low.c: Update.
5596
5597 2018-07-03 Tom Tromey <tom@tromey.com>
5598
5599 * target.c: Update.
5600
5601 2018-07-03 Tom Tromey <tom@tromey.com>
5602
5603 * linux-low.c: Update.
5604 * linux-mips-low.c: Update.
5605 * lynx-low.c: Update.
5606 * nto-low.c: Update.
5607 * remote-utils.c: Update.
5608 * server.c: Update.
5609 * spu-low.c: Update.
5610 * target.c: Update.
5611 * thread-db.c: Update.
5612
5613 2018-07-03 Tom Tromey <tom@tromey.com>
5614
5615 * linux-low.c: Update.
5616 * linux-mips-low.c: Update.
5617 * lynx-low.c: Update.
5618 * mem-break.c: Update.
5619 * nto-low.c: Update.
5620 * remote-utils.c: Update.
5621 * server.c: Update.
5622 * spu-low.c: Update.
5623 * target.c: Update.
5624 * tracepoint.c: Update.
5625
5626 2018-07-03 Tom Tromey <tom@tromey.com>
5627
5628 * linux-low.c: Update.
5629 * linux-ppc-low.c: Update.
5630 * linux-x86-low.c: Update.
5631 * proc-service.c: Update.
5632 * server.c: Update.
5633 * spu-low.c: Update.
5634 * thread-db.c: Update.
5635 * win32-low.c: Update.
5636
5637 2018-07-03 Tom Tromey <tom@tromey.com>
5638
5639 * linux-low.c: Update.
5640 * lynx-low.c: Update.
5641 * nto-low.c: Update.
5642 * remote-utils.c: Update.
5643 * spu-low.c: Update.
5644 * thread-db.c: Update.
5645 * win32-low.c: Update.
5646
5647 2018-06-29 Joel Brobecker <brobecker@adacore.com>
5648
5649 * linux-x86-tdesc.c (amd64_linux_read_description): Add missing
5650 parameter in call to 'amd64_create_target_description'.
5651
5652 2018-06-28 Jan Kratochvil <jan.kratochvil@redhat.com>
5653
5654 * x86-tdesc.h: Remove executable permission flag.
5655
5656 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
5657
5658 * configure.ac: Remove AC_PREREQ, add missing quoting.
5659 * configure: Re-generate.
5660 * config.in: Re-generate.
5661 * aclocal.m4: Re-generate.
5662
5663 2018-06-18 Simon Marchi <simon.marchi@ericsson.com>
5664
5665 * tracepoint.h (current_traceframe): Remove declaration.
5666
5667 2018-06-18 Alan Hayward <alan.hayward@arm.com>
5668
5669 * linux-aarch64-low.c (is_sve_tdesc): New function.
5670 (aarch64_sve_regs_copy_to_regcache): Likewise.
5671 (aarch64_sve_regs_copy_from_regcache): Likewise.
5672 (aarch64_regs_info): Add SVE checks.
5673 (initialize_low_arch): Initialize SVE.
5674
5675 2018-06-18 Alan Hayward <alan.hayward@arm.com>
5676
5677 * Makefile.in: Add aarch64-sve-linux-ptrace.c.
5678
5679 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5680
5681 * linux-aarch64-ipa.c (get_ipa_tdesc): Add null VQ param.
5682 (initialize_low_tracepoint): Likewise
5683 * linux-aarch64-low.c (aarch64_arch_setup): Get VQ.
5684 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Add null VQ
5685 param.
5686 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add VQ
5687 checks.
5688 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Add VQ.
5689
5690 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5691
5692 * server.h (PBUFSIZ): Increase size
5693
5694 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5695
5696 * regcache.c (regcache::raw_compare): New function.
5697 * regcache.h (regcache::raw_compare): New declaration.
5698
5699 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5700
5701 * regcache.c (new_register_cache): Use new.
5702 (free_register_cache): Use delete.
5703 (register_data): Use const.
5704 (supply_register): Move body inside regcache.
5705 (regcache::raw_supply): New override function.
5706 (collect_register): Move body inside regcache.
5707 (regcache::raw_collect): New override function.
5708 (regcache::get_register_status): New override function.
5709 * regcache.h (struct regcache): Inherit from reg_buffer_common.
5710
5711 2018-06-09 Tom Tromey <tom@tromey.com>
5712
5713 * event-loop.c (gdb_event, gdb_event_p): Remove typedefs. Don't
5714 declare queue.
5715 (event_queue): Use std::queue.
5716 (gdb_event_xfree): Remove.
5717 (initialize_event_loop, process_event, wait_for_event): Update.
5718
5719 2018-06-08 Stan Cox <scox@redhat.com>
5720
5721 * win32-low.c (win32_create_inferior): last_ptid and last_status
5722 moved to client_state.
5723
5724 2018-06-08 Pedro Alves <palves@redhat.com>
5725
5726 * Makefile.in (GDBREPLAY_OBS): Add common/cleanups.o,
5727 common/common-exceptions.o, common/common-utils.o,
5728 common/errors.o, common/print-utils.o and utils.o.
5729 * gdbreplay.c: Include "common-defs.h" instead of the two
5730 'config.h's here. Don't include stdio.h, errno.h, stdlib.h,
5731 string.h or alloca.h.
5732 (perror_with_name): Delete.
5733 (remote_open): Use xstrdup instead of strdup.
5734 (main): Rename to ...
5735 (captured_main): ... this.
5736 (main): New.
5737
5738 2018-06-08 Tom Tromey <tom@tromey.com>
5739
5740 * linux-low.c (linux_low_read_btrace): Update.
5741
5742 2018-06-04 Stan Cox <scox@redhat.com>
5743
5744 * server.h (struct client_state): New.
5745 * server.c (cont_thread, general_thread, multi_process)
5746 (report_fork_events, report_vfork_events, report_exec_events)
5747 (report_thread_events, swbreak_feature, hwbreak_feature)
5748 (vCont_supported, disable_randomization, pass_signals)
5749 (program_signals, program_signals_p, last_status, last_ptid, own_buf):
5750 Moved to client_state.
5751 * remote-utils.c (remote_debug, noack_mode)
5752 (transport_is_reliable): Moved to client_state.
5753 * tracepoint.c (current_traceframe): Moved to client_state.
5754
5755 Update all callers.
5756 * server.c, remote-utils.c, tracepoint.c, fork-child.c,
5757 linux-low.c, remote-utils.h, target.c: Use client_state.
5758
5759 2018-05-31 Alan Hayward <alan.hayward@arm.com>
5760
5761 * configure.srv: Add new c/h file.
5762
5763 2018-05-31 Alan Hayward <alan.hayward@arm.com>
5764
5765 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add
5766 null VQ.
5767
5768 2018-05-25 Maciej W. Rozycki <macro@mips.com>
5769
5770 * gdb.arch/mips-fpregset-core.exp: New test.
5771 * gdb.arch/mips-fpregset-core.c: New test source.
5772
5773 2018-05-23 Erik Kurzinger <ekurzinger@nvidia.com>
5774
5775 PR server/23198
5776 * hostio.c (require_int): Do not report overflow for integers
5777 between 0xfffffff and 0x7fffffff.
5778
5779 2018-05-22 Maciej W. Rozycki <macro@mips.com>
5780
5781 * linux-mips-low.c [HAVE_PTRACE_GETREGS] (mips_collect_register)
5782 (mips_supply_register): Move outside HAVE_PTRACE_GETREGS.
5783 (mips_collect_ptrace_register, mips_supply_ptrace_register): New
5784 functions.
5785 (the_low_target): Wire them.
5786
5787 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5788
5789 * linux-ppc-low.c (ppc_fill_vrregset): Add vscr_offset variable.
5790 Set vscr_offset to 0 in little-endian mode and 12 in big-endian
5791 mode. Call collect_register_by_name with vscr using
5792 vscr_offset. Zero-pad vscr and vrsave fields in collector buffer.
5793 (ppc_store_vrregset): Add and set vscr_offset variable as in
5794 ppc_fill_vrregset. Call supply_register_by_name with vscr using
5795 vscr_offset.
5796
5797 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5798
5799 * linux-ppc-low.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
5800 (ppc_arch_setup): Change SIZEOF_VRREGS and SIZEOF_VSXREGS to
5801 PPC_LINUX_SIZEOF_VRREGSET and PPC_LINUX_SIZEOF_VSXREGSET.
5802
5803 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5804
5805 * linux-ppc-low.c (ppc_fill_vsxregset): Remove ppc_hwcap check.
5806 (ppc_store_vsxregset): Likewise.
5807 (ppc_fill_vrregset): Likewise.
5808 (ppc_store_vrregset): Likewise.
5809 (ppc_fill_evrregset): Likewise.
5810 (ppc_store_evrregset): Likewise.
5811 (ppc_regsets): Set VSX/VR/EVR regset sizes to 0.
5812 (ppc_arch_setup): Iterate through ppc_regsets and set sizes when
5813 needed.
5814
5815 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5816
5817 * linux-ppc-low.c (ppc_arch_setup): Remove code for getting the
5818 wordsize of the inferior. Call ppc_linux_target_wordsize.
5819
5820 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5821
5822 * configure.srv (srv_tgtobj): Add arch/ppc-linux-common.o.
5823 * Makefile.in (SFILES): Add arch/ppc-linux-common.c.
5824 * linux-ppc-tdesc.h: Rename to linux-ppc-tdesc-init.h.
5825 * linux-ppc-tdesc-init.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
5826 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
5827 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
5828 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
5829 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
5830 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
5831 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
5832 (tdesc_powerpc_e500l): Remove.
5833 * linux-ppc-ipa.c: Include arch/ppc-linux-tdesc.h and
5834 linux-ppc-tdesc-init.h. Don't include linux-ppc-tdesc.h.
5835 * linux-ppc-low.c: Include arch/ppc-linux-common.h,
5836 arch/ppc-linux-tdesc.h, and linux-ppc-tdesc-init.h. Don't include
5837 linux-ppc-tdesc.h.
5838 (ppc_arch_setup): Remove target description matching code. Fill a
5839 ppc_linux_features struct and call ppc_linux_match_description
5840 with it.
5841
5842 2018-05-22 Maciej W. Rozycki <macro@mips.com>
5843
5844 * linux-mips-low.c (mips_cannot_fetch_register): Return 1 if the
5845 width of the requested register exceeds the width of the
5846 `ptrace' data type.
5847 (mips_cannot_store_register): Likewise.
5848
5849 2018-05-21 Maciej W. Rozycki <macro@mips.com>
5850
5851 * linux-mips-low.c (mips_fetch_register): New function. Update
5852 preceding comment.
5853 (mips_store_gregset): Supply 0 rather than $restart for $zero.
5854 (the_low_target): Wire `mips_fetch_register'.
5855
5856 2018-05-10 Joel Brobecker <brobecker@adacore.com>
5857
5858 * lynx-i386-low.c (LYNXOS_178): New macro.
5859 [LYNXOS_178] (usr_fcontext_t): Provide a definition that matches
5860 the layout on LynxOS-178.
5861 (lynx_i386_fill_fpregset, lynx_i386_store_fpregset): Do not
5862 handle floating point registers that are not supported by
5863 LynxOS-178.
5864
5865 2018-05-10 Tom Tromey <tom@tromey.com>
5866
5867 * configure: Rebuild.
5868
5869 2018-05-10 Joel Brobecker <brobecker@adacore.com>
5870
5871 PR server/23158:
5872 * tdesc.h (init_target_desc) <expedite_regs>: New parameter.
5873 * tdesc.c (init_target_desc) <expedite_regs>: New parameter.
5874 Use it to set the expedite_regs field in the given tdesc.
5875 * x86-tdesc.h: New file.
5876 * linux-aarch64-tdesc.c (aarch64_linux_read_description):
5877 Adjust following the addition of the new expedite_regs parameter
5878 to init_target_desc.
5879 * linux-tic6x-low.c (tic6x_read_description): Likewise.
5880 * linux-x86-tdesc.c: #include "x86-tdesc.h".
5881 (i386_linux_read_description, amd64_linux_read_description):
5882 Adjust following the addition of the new expedite_regs parameter
5883 to init_target_desc.
5884 * lynx-i386-low.c: #include "x86-tdesc.h".
5885 (lynx_i386_arch_setup): Adjust following the addition of the new
5886 expedite_regs parameter to init_target_desc.
5887 * nto-x86-low.c: #include "x86-tdesc.h".
5888 (nto_x86_arch_setup): Adjust following the addition of the new
5889 expedite_regs parameter to init_target_desc.
5890 * win32-i386-low.c: #include "x86-tdesc.h".
5891 (i386_arch_setup): Adjust following the addition of the new
5892 expedite_regs parameter to init_target_desc.
5893
5894 2018-05-10 Joel Brobecker <brobecker@adacore.com>
5895
5896 PR server/23158:
5897 * win32-low.c (win32_create_inferior): Add call to my_wait
5898 setting last_status global.
5899
5900 2018-05-10 Joel Brobecker <brobecker@adacore.com>
5901
5902 PR server/23158:
5903 * win32-low.c (create_process): Only call gdb_tilde_expand if
5904 inferior_cwd is not NULL.
5905
5906 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
5907
5908 * i387-fp.c (i387_cache_to_xsave): Only write x87 control
5909 registers to the cache if their values have changed.
5910 (i387_xsave_to_cache): Provide default values for x87 control
5911 registers when these features are available, but disabled.
5912 * regcache.c (supply_register_by_name_zeroed): New function.
5913 * regcache.h (supply_register_by_name_zeroed): Declare new
5914 function.
5915
5916 2018-05-07 Tom Tromey <tom@tromey.com>
5917
5918 * configure: Rebuild.
5919
5920 2018-05-04 Tom Tromey <tom@tromey.com>
5921
5922 * configure: Rebuild.
5923
5924 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
5925 Pedro Alves <palves@redhat.com>
5926
5927 * linux-aarch64-low.c (aarch64_stopped_data_address):
5928 Likewise.
5929
5930 2018-04-27 Tom Tromey <tom@tromey.com>
5931
5932 * configure: Rebuild.
5933
5934 2018-04-23 Tom Tromey <tom@tromey.com>
5935
5936 * configure: Rebuild.
5937
5938 2018-04-19 Simon Marchi <simon.marchi@ericsson.com>
5939
5940 * Makefile.in (depcomp): Add "..".
5941 (all_deps_files): New and use it.
5942
5943 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5944
5945 * configure.srv (aarch64*-*-linux*): Don't include xml.
5946 (i[34567]86-*-cygwin*): Likewise.
5947 (i[34567]86-*-linux*): Likewise.
5948 (i[34567]86-*-lynxos*): Likewise.
5949 (i[34567]86-*-mingw32ce*): Likewise.
5950 (i[34567]86-*-mingw*): Likewise.
5951 (i[34567]86-*-nto*): Likewise.
5952 (tic6x-*-uclinux): Likewise.
5953 (x86_64-*-linux*): Likewise.
5954 (x86_64-*-mingw*): Likewise.
5955 (x86_64-*-cygwin*): Likewise.
5956
5957 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5958
5959 * tdesc.c: Remove xml parameter.
5960
5961 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5962
5963 * server.c (get_features_xml): Remove cast.
5964 * tdesc.c (void target_desc::accept): Fill in function.
5965 (tdesc_get_features_xml): Remove old xml creation.
5966 (print_xml_feature::visit_pre): Add xml vistor.
5967 * tdesc.h (struct target_desc): Make xmltarget mutable.
5968 (tdesc_get_features_xml): Remove declaration.
5969
5970 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5971
5972 * tdesc.c (tdesc_architecture_name): Add new function.
5973 (tdesc_osabi_name): Likewise.
5974 (tdesc_get_features_xml): Use new functions.
5975
5976 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5977
5978 * tdesc.c (tdesc_create_flags): Remove.
5979 (tdesc_add_flag): Likewise.
5980 (tdesc_named_type): Likewise.
5981 (tdesc_create_union): Likewise.
5982 (tdesc_create_struct): Likewise.
5983 (tdesc_create_vector): Likewise.
5984 (tdesc_add_bitfield): Likewise.
5985 (tdesc_add_field): Likewise.
5986 (tdesc_set_struct_size): Likewise.
5987
5988 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5989
5990 * tdesc.c (~target_desc): Remove implictly deleted items.
5991 (init_target_desc): Iterate all features.
5992 (tdesc_get_features_xml): Use vector.
5993 (tdesc_create_feature): Create feature.
5994 * tdesc.h (tdesc_feature) Remove
5995 (target_desc): Add features.
5996
5997 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5998
5999 * Makefile.in: Add common/tdesc.c
6000 * tdesc.c (init_target_desc): init all reg_defs from register
6001 vector.
6002 (tdesc_create_reg): Create tdesc_reg.
6003 * tdesc.h (tdesc_feature): Add register vector.
6004
6005 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
6006
6007 * tdesc.h (struct target_desc) <features>: Change type to
6008 std::vector<std::string>.
6009 * tdesc.c (target_desc::~target_desc): Adjust to std::vector
6010 changes.
6011 (tdesc_get_features_xml): Likewise.
6012 (tdesc_create_feature): Likewise.
6013
6014 2018-03-26 Alan Hayward <alan.hayward@arm.com>
6015
6016 * regcache.c (find_register_by_number): Return a ref.
6017 (find_regno): Use references.
6018 (register_size): Likewise.
6019 (register_data): Likewise.
6020 * tdesc.c (target_desc::~target_desc): Remove free calls.
6021 (target_desc::operator==): Use std::vector compare.
6022 (init_target_desc): Use reference.
6023 (tdesc_create_reg): Use reg constructors.
6024 * tdesc.h (struct target_desc): Replace pointer with object.
6025
6026 2018-03-23 Alan Hayward <alan.hayward@arm.com>
6027
6028 * regcache.c (find_register_by_number): Make static.
6029 (find_regno): Use find_register_by_number
6030 * regcache.h (struct reg): Remove declaration.
6031
6032 2018-03-23 Alan Hayward <alan.hayward@arm.com>
6033
6034 * tdesc.c (target_desc::~target_desc): Move to here.
6035 (target_desc::operator==): Likewise.
6036 * tdesc.h (target_desc::~target_desc): Move from here.
6037 (target_desc::operator==): Likewise.
6038
6039 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
6040
6041 * linux-s390-low.c (s390_get_wordsize): Correct brace style.
6042
6043 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
6044
6045 * linux-s390-ipa.c (get_ipa_tdesc): Add handling for
6046 S390_TDESC_GS.
6047 * linux-s390-low.c (s390_get_ipa_tdesc_idx): Likewise.
6048 (initialize_low_tracepoint): Call init_registers_s390x_gs_linux64
6049 and init_registers_s390_gs_linux64.
6050
6051 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
6052
6053 * linux-s390-low.c (s390_fill_gs): Remove function.
6054 (s390_fill_gsbc): Remove function.
6055 (s390_regsets): Set fill functions for the guarded storage regsets
6056 to NULL.
6057
6058 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
6059
6060 * linux-s390-low.c (s390_get_hwcap): Replace tdesc parameter by
6061 the word size. Add comment.
6062 (s390_get_wordsize): New function.
6063 (s390_arch_setup): No longer select a temporary tdesc to fetch the
6064 pswm with it. Instead, use s390_get_wordsize to determine the
6065 word size first and derive the correct tdesc from that directly.
6066
6067 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
6068
6069 * Makefile.in: Include silent-rules.mk.
6070 (srcdir, abs_top_srcdir, abs_srcdir, VPATH): Move up.
6071 (COMPILE): Add ECHO_CXX.
6072 (gdbserver$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
6073 (gdbreplay$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
6074 ($(IPA_LIB)): Add SILENCE and ECHO_CXXLD.
6075 (version-generated.c): Add ECHO_GEN.
6076 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN_GENERATED.
6077 (IPAGENT_COMPILE): Add ECHO_CXX.
6078 (%-generated.c): Add ECHO_REGDAT.
6079
6080 2018-03-14 Tom Tromey <tom@tromey.com>
6081
6082 PR cli/14977:
6083 * ax.c (ax_printf): Special case for NULL.
6084
6085 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
6086
6087 * linux-low.c (linux_qxfer_libraries_svr4): Use
6088 xml_escape_text_append.
6089
6090 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
6091
6092 * linux-low.c (linux_qxfer_libraries_svr4): Use std::string.
6093
6094 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
6095
6096 * server.c (handle_general_set): Remove unnecessary xstrdup.
6097
6098 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
6099
6100 * server.c (parse_debug_format_options): Adjust to
6101 delim_string_to_char_ptr_vec changes.
6102 * thread-db.c (thread_db_load_search): Adjust to
6103 dirnames_to_char_ptr_vec changes.
6104
6105 2018-03-01 Markus Metzger <markus.t.metzger@intel.com>
6106
6107 * target.h (target_enable_btrace, target_disable_btrace)
6108 (target_read_btrace, target_read_btrace_conf): Turn macro into
6109 inline function. Throw error if target method is not defined.
6110 * server.c (handle_qxfer_btrace handle_qxfer_btrace_conf): Remove
6111 check for btrace target method. Be prepared to handle exceptions
6112 from btrace target methods.
6113
6114 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
6115
6116 * server.c (captured_main): Change order of error message printed
6117 when the current working directory cannot be found.
6118
6119 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
6120
6121 * server.c: Include "filenames.h" and "pathstuff.h".
6122 (program_name): Delete variable.
6123 (program_path): New anonymous class.
6124 (get_exec_wrapper): Use "program_path" instead of
6125 "program_name".
6126 (handle_v_run): Likewise.
6127 (captured_main): Likewise.
6128 (process_serial_event): Likewise.
6129
6130 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
6131
6132 * Makefile.in (SFILES): Add "$(srcdir)/common/pathstuff.c".
6133 (OBJS): Add "pathstuff.o".
6134 * server.c (current_directory): New global variable.
6135 (captured_main): Initialize "current_directory".
6136
6137 2018-02-26 Alan Hayward <alan.hayward@arm.com>
6138
6139 * tdesc.c: Use common/tdesc.h.
6140 * tdesc.h: Likewise.
6141
6142 2018-02-20 Alan Hayward <alan.hayward@arm.com>
6143 Simon Marchi <simon.marchi@ericsson.com>
6144
6145 * Makefile.in: Switch order of make rules.
6146
6147 2018-02-19 Alan Hayward <alan.hayward@arm.com>
6148
6149 * Makefile.in: Add common directory in build.
6150 * configure.ac: Add common reference.
6151 * configure: Regenerate.
6152
6153 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
6154
6155 * linux-low.c (linux_target_ops): Remove linux_supports_btrace.
6156 * nto-low.c (nto_target_ops): Remove NULL for supports_btrace.
6157 * spu-low.c (spu_target_ops): Likewise.
6158 * win32-low.c (win32_target_ops): Likewise.
6159 * server.c (supported_btrace_packets): Report packets unconditionally.
6160 * target.h (target_ops) <supports_btrace>: Remove.
6161 (target_supports_btrace): Remove.
6162
6163 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
6164
6165 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt)
6166 (handle_btrace_disable): Change return type to void. Use exceptions
6167 to report errors.
6168 (handle_btrace_general_set): Catch exception and copy message to
6169 return message.
6170
6171 2018-02-08 Tom Tromey <tom@tromey.com>
6172
6173 * linux-low.c (install_software_single_step_breakpoints): Use
6174 make_scoped_restore.
6175 * inferiors.c (make_cleanup_restore_current_thread): Remove.
6176 (do_restore_current_thread_cleanup): Remove.
6177 * gdbthread.h (make_cleanup_restore_current_thread): Don't
6178 declare.
6179
6180 2018-02-08 Tom Tromey <tom@tromey.com>
6181
6182 * mem-break.c (set_raw_breakpoint_at): Use
6183 gdb::unique_xmalloc_ptr.
6184
6185 2018-01-30 Pedro Alves <palves@redhat.com>
6186
6187 PR gdb/13211
6188 * target.c (target_terminal::terminal_state): Rename to ...
6189 (target_terminal::m_terminal_state): ... this.
6190
6191 2018-01-19 James Clarke <jrtc27@jrtc27.com>
6192
6193 * linux-low.c (handle_extended_wait): Surround call to
6194 thread_db_notice_clone with #ifdef USE_THREAD_DB.
6195
6196 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
6197
6198 * linux-low.c (attach_proc_task_lwp_callback): Adjust to
6199 linux_ptrace_attach_fail_reason_string now returning an
6200 std::string.
6201 (linux_attach): Likewise.
6202 * thread-db.c (attach_thread): Likewise.
6203
6204 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
6205
6206 PR gdb/21559
6207 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
6208 checking for fs_base/gs_base fields in struct user_regs_struct.
6209 * configure: Regenerate.
6210
6211 2018-01-16 Yao Qi <yao.qi@linaro.org>
6212
6213 PR gdb/18749
6214 * linux-low.c (fetch_register): Call supply_register instead of
6215 error.
6216
6217 2018-01-08 Yao Qi <yao.qi@linaro.org>
6218 Simon Marchi <simon.marchi@ericsson.com>
6219
6220 * Makefile.in (OBS): Remove selftest.o.
6221 * configure.ac: Set srv_selftest_objs if $development is true.
6222 (GDBSERVER_DEPFILES): Append $srv_selftest_objs.
6223 * configure: Re-generated.
6224 * server.c (captured_main): Wrap variable selftest_filter with
6225 GDB_SELF_TEST.
6226
6227 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
6228
6229 * server.c (parse_debug_format_options): Return std::string.
6230 (handle_monitor_command, captured_main): Adjust.
6231
6232 2018-01-05 Pedro Alves <palves@redhat.com>
6233
6234 PR gdb/18653
6235 * server.c (captured_main): Pass quiet=false to
6236 save_original_signals_state.
6237
6238 2018-01-01 Joel Brobecker <brobecker@adacore.com>
6239
6240 * gdbreplay.c (gdbreplay_version): Update copyright year in
6241 version message.
6242 * server.c (gdbserver_version): Likewise.
6243
6244 2017-12-08 Tom Tromey <tom@tromey.com>
6245
6246 * ax.c (ax_printf): Update.
6247
6248 2017-12-07 Yao Qi <yao.qi@linaro.org>
6249
6250 * linux-aarch64-ipa.c (initialize_low_tracepoint): Call
6251 aarch64_linux_read_description.
6252 * linux-amd64-ipa.c (idx2mask): New array.
6253 (get_ipa_tdesc): Move idx2mask out.
6254 (initialize_low_tracepoint): Initialize target descriptions.
6255 * linux-i386-ipa.c (idx2mask): New array.
6256 (get_ipa_tdesc): Move idx2mask out.
6257 (initialize_low_tracepoint): Initialize target descriptions.
6258
6259 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
6260
6261 * tdesc.c (struct tdesc_type): Change return type.
6262 (tdesc_add_flag): Change parameter type.
6263 (tdesc_add_bitfield): Likewise.
6264 (tdesc_add_field): Likewise.
6265 (tdesc_set_struct_size): Likewise.
6266
6267 2017-12-05 Simon Marchi <simon.marchi@ericsson.com>
6268
6269 * regcache.c (registers_to_string): Remove unused variable.
6270
6271 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6272
6273 * inferiors.c (for_each_inferior_with_data): Remove.
6274 * inferiors.h (for_each_inferior_with_data): Remove.
6275 * server.c (handle_qxfer_threads_worker): Change parameter type.
6276 (handle_qxfer_threads_proper): Use for_each_thread.
6277
6278 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6279
6280 * inferiors.c (for_each_inferior): Remove.
6281 (clear_inferiors): Use for_each_thread.
6282 * inferiors.h (for_each_inferior): Remove.
6283 * linux-low.c (linux_wait_for_event_filtered): Use
6284 for_each_thread.
6285 (linux_stabilize_threads): Likewise.
6286 * regcache.c (regcache_release): Likewise.
6287 * server.c (gdb_wants_all_threads_stopped): Likewise.
6288 (clear_pending_status_callback): Remove.
6289 (handle_status): Use for_each_thread.
6290 (captured_main): Likewise.
6291 * win32-low.c (child_init_thread_list): Likewise.
6292 (win32_clear_inferiors): Likewise.
6293 (fake_breakpoint_event): Likewise.
6294
6295 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6296
6297 * inferiors.h (find_inferior): Remove.
6298 * inferiors.c (find_inferior): Remove.
6299
6300 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6301
6302 * linux-low.c (resume_status_pending_p): Update comment.
6303 (need_step_over_p): Update comment.
6304
6305 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6306
6307 * linux-low.c (proceed_one_lwp): Return void, change parameter
6308 type.
6309 (unsuspend_and_proceed_one_lwp): Likewise.
6310 (proceed_all_lwps): Use for_each_thread.
6311 (unstop_all_lwps): Likewise.
6312
6313 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6314
6315 * linux-low.c (linux_resume_one_thread): Return void, take
6316 parameter directly.
6317 (linux_resume): Use for_each_thread.
6318
6319 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6320
6321 * linux-low.c (send_sigstop_callback): Return void, change
6322 parameter type. Rename to...
6323 (send_sigstop): ... this.
6324 (suspend_and_send_sigstop_callback): Return void, change parameter
6325 type. Rename to...
6326 (suspend_and_send_sigstop): ... this.
6327 (stop_all_lwps): Use for_each_thread.
6328
6329 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6330
6331 * linux-low.c (lwp_running): Return bool, remove unused
6332 argument.
6333 (linux_stabilize_threads): Use find_thread.
6334
6335 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6336
6337 * linux-low.c (select_singlestep_lwp_callback): Remove.
6338 (count_events_callback): Remove.
6339 (select_event_lwp_callback): Remove.
6340 (select_event_lwp): Use find_thread/for_each_thread.
6341
6342 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6343
6344 * linux-low.c (not_stopped_callback): Return bool, take filter
6345 argument directly.
6346 (linux_wait_for_event_filtered): Use find_thread.
6347 (linux_wait_1): Likewise.
6348
6349 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6350
6351 * linux-low.c (same_lwp): Remove.
6352 (find_lwp_pid): Use find_thread.
6353
6354 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6355
6356 * linux-low.c (delete_lwp_callback): Remove.
6357 (linux_mourn): Use for_each_thread.
6358
6359 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6360
6361 * linux-low.c (linux_detach_lwp_callback): Return void, remove
6362 args parameter, don't check for pid.
6363 (linux_detach): Use for_each_thread.
6364
6365 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6366
6367 * linux-low.c (struct counter): Remove.
6368 (second_thread_of_pid_p): Remove.
6369 (last_thread_of_process_p): Use find_thread.
6370
6371 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6372
6373 * inferiors.c (find_inferior_in_random): Remove.
6374 * inferiors.h (find_inferior_in_random): Remove.
6375 * linux-low.c (status_pending_p_callback): Return bool, accept
6376 parameter ptid directly.
6377 (linux_wait_for_event_filtered): Use find_thread_in_random.
6378 (linux_wait_1): Likewise.
6379
6380 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6381
6382 * inferiors.c (find_inferior_id): Remove.
6383 (find_thread_ptid): Move implemention from find_inferior_id to
6384 here.
6385 * inferiors.h (find_inferior_id): Remove.
6386 * server.c (handle_status): Use find_thread_ptid.
6387 (process_serial_event): Likewise.
6388 * thread-db.c (find_one_thread): Likewise.
6389 (thread_db_thread_handle): Likewise.
6390 * win32-low.c (thread_rec): Likewise.
6391 (child_delete_thread): Likewise.
6392 (win32_thread_alive): Likewise.
6393 (get_child_debug_event): Likewise.
6394
6395 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6396
6397 * linux-mips-low.c (update_watch_registers_callback): Return
6398 void, remove pid_p parameter, don't check for pid.
6399 (mips_insert_point, mips_remove_point): Use for_each_thread.
6400
6401 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6402
6403 * lynx.low (lynx_delete_thread_callback): Remove.
6404 (lynx_mourn): Use for_each_thread.
6405
6406 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6407
6408 * regcache.c (regcache_invalidate_one): Remove.
6409 (regcache_invalidate_pid): use for_each_thread.
6410
6411 2017-11-26 Tom Tromey <tom@tromey.com>
6412
6413 * linux-low.c (linux_create_inferior): Update.
6414
6415 2017-11-24 Ulrich Weigand <uweigand@de.ibm.com>
6416
6417 * spu-low.c (spu_create_inferior): Fix typo in argument name.
6418
6419 2017-11-24 Alan Hayward <alan.hayward@arm.com>
6420
6421 * configure.srv: Add linux-aarch64-tdesc-selftest.o.
6422 * linux-aarch64-low.c (initialize_low_arch): Call init func.
6423 * linux-aarch64-tdesc-selftest.c: New file.
6424 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
6425
6426 2017-11-24 Alan Hayward <alan.hayward@arm.com>
6427
6428 * configure.srv: Add new file.
6429 * linux-aarch64-low.c (initialize_low_arch): Call init func.
6430 * linux-aarch64-tdesc-selftest.c: New file.
6431 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
6432
6433 2017-11-24 Alan Hayward <alan.hayward@arm.com>
6434
6435 * linux-aarch64-ipa.c (initialize_low_tracepoint): Remove init.
6436 * linux-aarch64-low.c (initialize_low_arch): Remove init.
6437 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add init.
6438
6439 2017-11-24 Alan Hayward <alan.hayward@arm.com>
6440
6441 * configure.srv: Add new files.
6442 * linux-aarch64-ipa.c (get_ipa_tdesc): Call
6443 aarch64_linux_read_description.
6444 * linux-aarch64-low.c (aarch64_linux_read_description):
6445 Merge with aarch64_arch_setup.
6446 (aarch64_arch_setup): Call aarch64_linux_read_description.
6447 * linux-aarch64-tdesc.c: New file.
6448 * linux-aarch64-tdesc.h: New file.
6449
6450 2017-11-24 Yao Qi <yao.qi@linaro.org>
6451
6452 * configure.srv: Set $srv_regobj for tic6x-linux.
6453 * linux-tic6x-low.c: Include "arch/tic6x.h" and "tdesc.h".
6454 (tic6x_read_description): Move some code to tic6x_arch_setup.
6455 (tic6x_tdesc_test): New function.
6456 (initialize_low_arch): Call selftests::register_test.
6457
6458 2017-11-22 Yao Qi <yao.qi@linaro.org>
6459
6460 * remote-utils.c (prepare_resume_reply): Use memcpy.
6461
6462 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6463
6464 * linux-low.c (kill_one_lwp_callback): Return void, take
6465 argument directly, don't filter on pid.
6466 (linux_kill): Use for_each_thread.
6467
6468 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6469
6470 * linux-low.c (need_step_over_p): Return bool, remove dummy
6471 argument.
6472 (linux_resume, proceed_all_lwps): Use find_thread.
6473
6474 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6475
6476 * linux-low.c (resume_status_pending_p): Return bool, remove
6477 flag_p argument.
6478 (linux_resume): Use find_thread.
6479
6480 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6481
6482 * linux-low.c (struct thread_resume_array): Remove.
6483 (linux_set_resume_request): Return void, take arguments
6484 directly.
6485 (linux_resume): Use for_each_thread.
6486
6487 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6488
6489 * linux-low.c (stuck_in_jump_pad_callback): Change prototype,
6490 return bool, remove data argument.
6491 (linux_stabilize_threads): Use find_thread.
6492
6493 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6494
6495 * linux-low.c (unsuspend_one_lwp): Remove.
6496 (unsuspend_all_lwps): Use for_each_thread, inline code from
6497 unsuspend_one_lwp.
6498
6499 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6500
6501 * gdbthread.h (find_thread): Add overload with ptid_t filter.
6502 * linux-low.c (struct iterate_over_lwps_args): Remove.
6503 (iterate_over_lwps_filter): Remove.
6504 (iterate_over_lwps): Use find_thread.
6505
6506 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6507
6508 * linux-low.c (reset_lwp_ptrace_options_callback): Remove.
6509 (linux_handle_new_gdb_connection): Use for_each_thread, inline
6510 code from reset_lwp_ptrace_options_callback.
6511
6512 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6513
6514 * linux-arm-low.c (struct update_registers_data): Remove.
6515 (update_registers_callback): Return void, take arguments
6516 directly, don't check thread's pid.
6517 (arm_insert_point, arm_remove_point): Use for_each_thread.
6518
6519 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6520
6521 * win32-low.c (continue_one_thread): Return void, take argument
6522 directly.
6523 (child_continue): Use for_each_thread.
6524
6525 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6526
6527 * win32-i386-low.c (update_debug_registers_callback): Rename
6528 to ...
6529 (update_debug_registers): ... this, return void, remove pid_p arg.
6530 (x86_dr_low_set_addr, x86_dr_low_set_control): Use for_each_thread.
6531
6532 2017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
6533
6534 * inferiors.h (struct process_info): Add constructor, initialize
6535 fields..
6536 <syscalls_to_catch>: Change type to std::vector<int>.
6537 * inferiors.c (add_process): Allocate process_info with new.
6538 (remove_process): Free process_info with delete.
6539 * linux-low.c (handle_extended_wait): Adjust.
6540 (gdb_catching_syscalls_p, gdb_catch_this_syscall_p): Adjust.
6541 * server.c (handle_general_set): Adjust.
6542
6543 2017-11-16 Pedro Alves <palves@redhat.com>
6544
6545 * remote-utils.c (remote_close): Block SIGIO signals instead of
6546 uninstalling the SIGIO handler.
6547
6548 2017-11-16 Alan Hayward <alan.hayward@arm.com>
6549
6550 * tdesc.c (tdesc_get_features_xml): Allow null osabi.
6551
6552 2017-11-16 Yao Qi <yao.qi@linaro.org>
6553
6554 * linux-tic6x-low.c (tic6x_fill_gregset): Cast buf.
6555 (tic6x_store_gregset): Likewise.
6556 (tic6x_usrregs_info): Move it up.
6557
6558 2017-11-15 Alan Hayward <alan.hayward@arm.com>
6559
6560 * Makefile.in: Update arch rules.
6561 * configure.srv: Explicitly mark arch/ files.
6562
6563 2017-11-13 Andreas Schwab <schwab@suse.de>
6564
6565 * linux-m68k-low.c (m68k_supports_hardware_single_step): New
6566 function.
6567 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6568
6569 2017-11-06 Pedro Alves <palves@redhat.com>
6570
6571 * config.in, configure: Regenerate.
6572
6573 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
6574
6575 * target.c (struct thread_search): Remove.
6576 (thread_search_callback): Remove.
6577 (prepare_to_access_memory): Use for_each_thread instead of
6578 find_inferior. Inline code from thread_search_callback.
6579
6580 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
6581
6582 * server.c (struct visit_actioned_threads_data): Remove.
6583 (visit_actioned_threads): Change prototype to take arguments
6584 directly.
6585 (resume): Use find_thread instead of find_inferior.
6586
6587 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
6588
6589 * server.c (queue_stop_reply_callback): Change prototype, return
6590 void.
6591 (find_status_pending_thread_callback): Remove.
6592 (handle_status): Replace find_inferior with find_thread and
6593 for_each_thread.
6594
6595 2017-10-25 Alan Hayward <alan.hayward@arm.com>
6596
6597 * linux-aarch64-low.c (aarch64_fill_gregset): Replace defines
6598 with REGNO.
6599 (aarch64_store_gregset): Likewise.
6600 (aarch64_fill_fpregset): Likewise.
6601 (aarch64_store_fpregset): Likewise.
6602
6603 2017-10-21 Simon Marchi <simon.marchi@ericsson.com>
6604
6605 * gdbthread.h (find_thread, for_each_thread): New functions.
6606 * inferiors.c (thread_of_pid): Remove.
6607 (find_any_thread_of_pid): Use find_thread.
6608 * linux-low.c (num_lwps): Use for_each_thread.
6609
6610 2017-10-17 Yao Qi <yao.qi@linaro.org>
6611
6612 * Makefile.in: Remove one rule.
6613 * configure.srv: Rename aarch64-insn.o with arch/aarch64-insn.o.
6614
6615 2017-10-17 Yao Qi <yao.qi@linaro.org>
6616
6617 * configure.srv: Rename arm-linux.o with arch/arm-linux.o.
6618 Rename arm-get-next-pcs.o with arch/arm-get-next-pcs.o.
6619
6620 2017-10-17 Yao Qi <yao.qi@linaro.org>
6621
6622 * configure.srv: Rename arm.o with arch/arm.o.
6623
6624 2017-10-17 Yao Qi <yao.qi@linaro.org>
6625
6626 * Makefile.in (CONFIG_SRC_SUBDIR): New variable.
6627 (clean): Remove .o files in CONFIG_SRC_SUBDIR.
6628 (distclean): Remove DEPDIR in CONFIG_SRC_SUBDIR.
6629 (arch-i386.o, arch-amd64.o): Remove rules.
6630 (arch/%.o): New rule.
6631 Update POSTCOMPILE and COMPILE.pre.
6632 * configure.ac: Invoke AC_CONFIG_COMMANDS.
6633 * configure: Re-generated.
6634 * configure.srv: Replace arch-i386.o with arch/i386.o.
6635 Replace arch-amd64.o with arch/amd64.o.
6636
6637 2017-10-16 Yao Qi <yao.qi@linaro.org>
6638
6639 * configure: Regenerated.
6640
6641 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
6642
6643 * inferiors.h: (struct inferior_list): Remove.
6644 (struct inferior_list_entry); Remove.
6645 (add_inferior_to_list, clear_inferior_list, one_inferior_p,
6646 A_I_NEXT, ALL_INFERIORS_TYPE, ALL_INFERIORS, remove_inferior,
6647 get_first_inferior): Remove.
6648 (for_each_inferior, for_each_inferior_with_data, find_inferior,
6649 find_inferior_id, find_inferior_in_random): Change signature.
6650 * inferiors.c (all_threads): Change type to
6651 std::list<thread_info *>.
6652 (get_thread): Remove macro.
6653 (find_inferior, find_inferior_id): Change signature, implement
6654 using find_thread.
6655 (find_inferior_in_random): Change signature, implement using
6656 find_thread_in_random.
6657 (for_each_inferior, for_each_inferior_with_data): Change
6658 signature, implement using for_each_thread.
6659 (add_inferior_to_list, remove_inferior): Remove.
6660 (add_thread, get_first_thread, thread_of_pid,
6661 find_any_thread_of_pid, free_one_thread, remove_thread): Update.
6662 (get_first_inferior, one_inferior_p, clear_inferior_list):
6663 Remove.
6664 (clear_inferiors, get_thread_process): Update.
6665 * gdbthread.h: Include <list>.
6666 (struct thread_info) <entry>: Remove field.
6667 <id>: New field.
6668 (all_threads): Change type to std::list<thread_info *>.
6669 (get_first_inferior): Add doc.
6670 (find_thread, for_each_thread, find_thread_in_random): New
6671 functions.
6672 (current_ptid, pid_of, ptid_of, lwpid_of): Update.
6673 * linux-arm-low.c (update_registers_callback): Update.
6674 * linux-low.c (second_thread_of_pid_p): Update.
6675 (kill_one_lwp_callback, linux_detach_lwp_callback,
6676 delete_lwp_callback, status_pending_p_callback, same_lwp,
6677 find_lwp_pid, num_lwps, iterate_over_lwps_filter,
6678 iterate_over_lwps, not_stopped_callback,
6679 resume_stopped_resumed_lwps, count_events_callback,
6680 select_singlestep_lwp_callback, select_event_lwp_callback,
6681 unsuspend_one_lwp, linux_wait_1, send_sigstop_callback,
6682 suspend_and_send_sigstop_callback, wait_for_sigstop,
6683 stuck_in_jump_pad_callback, move_out_of_jump_pad_callback,
6684 lwp_running, linux_set_resume_request, resume_status_pending_p,
6685 need_step_over_p, start_step_over, linux_resume_one_thread,
6686 proceed_one_lwp, unsuspend_and_proceed_one_lwp,
6687 reset_lwp_ptrace_options_callback): Update.
6688 * linux-mips-low.c (update_watch_registers_callback): Update.
6689 * regcache.c (regcache_invalidate_one, regcache_invalidate):
6690 Update.
6691 (free_register_cache_thread_one): Remove.
6692 (regcache_release): Update.
6693 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt,
6694 handle_qxfer_threads_worker): Update.
6695 (handle_query): Update, use list iterator.
6696 (visit_actioned_threads, handle_pending_status,
6697 queue_stop_reply_callback, gdb_wants_all_threads_stopped,
6698 clear_pending_status_callback, set_pending_status_callback,
6699 find_status_pending_thread_callback, handle_status,
6700 process_serial_event): Update.
6701 * target.c (thread_search_callback): Update.
6702 * thread-db.c (thread_db_get_tls_address): Update.
6703 * tracepoint.c (tracepoint_finished_step, tracepoint_was_hit):
6704 Update.
6705 * win32-i386-low.c (update_debug_registers_callback): Update.
6706 * win32-low.c (delete_thread_info, child_delete_thread,
6707 continue_one_thread, suspend_one_thread,
6708 get_child_debug_event): Adjust.
6709
6710 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
6711
6712 * gdbthread.h (ptid_of, pid_of, lwpid_of): New functions.
6713 * inferiors.h: Include <list>.
6714 (struct process_info) <entry>: Remove field.
6715 <pid>: New field.
6716 (pid_of): Change macro to function.
6717 (ptid_of, lwpid_of): Remove macro.
6718 (all_processes): Change type to std::list<process_info *>.
6719 (ALL_PROCESSES): Remove macro.
6720 (for_each_process, find_process): New function.
6721 * inferiors.c (all_processes): Change type to
6722 std::list<process_info *>.
6723 (find_thread_process): Adjust.
6724 (add_process): Likewise.
6725 (remove_process): Likewise.
6726 (find_process_pid): Likewise.
6727 (get_first_process): Likewise.
6728 (started_inferior_callback): Remove.
6729 (have_started_inferiors_p): Adjust.
6730 (attached_inferior_callback): Remove.
6731 (have_attached_inferiors_p): Adjust.
6732 * linux-low.c (check_zombie_leaders): Likewise.
6733 * linux-x86-low.c (x86_arch_setup_process_callback): Remove.
6734 (x86_linux_update_xmltarget): Adjust.
6735 * server.c (handle_query): Likewise.
6736 (gdb_reattached_process): Remove.
6737 (handle_status): Adjust.
6738 (kill_inferior_callback): Likewise.
6739 (detach_or_kill_inferior): Remove.
6740 (print_started_pid): Likewise.
6741 (print_attached_pid): Likewise.
6742 (detach_or_kill_for_exit): Update.
6743 (process_serial_event): Likewise.
6744 * linux-arm-low.c (arm_new_fork): Likewise.
6745
6746 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
6747
6748 * dll.h: Include <list>.
6749 (struct dll_info): Add constructor.
6750 <entry>: Remove field.
6751 (all_dlls): Change type to std::list<dll_info>.
6752 * dll.c: Include <algorithm>.
6753 (get_dll): Remove macro.
6754 (all_dlls): Change type to std::list<dll_info *>.
6755 (free_one_dll): Remove.
6756 (match_dll): Likewise.
6757 (loaded_dll): Adjust.
6758 (unloaded_dll): Adjust to all_dlls type change, use
6759 std::find_if. Inline code from match_dll.
6760 (clear_dlls): Adjust to all_dlls type change.
6761 * server.c (emit_dll_description): Remove.
6762 (handle_qxfer_libraries): Adjust to all_dlls type change,
6763 integrate emit_dll_description's functionality.
6764
6765 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
6766
6767 * linux-low.h (struct linux_target_ops) <delete_process>: New
6768 field.
6769 * linux-low.c (linux_mourn): Call the_low_target.delete_process.
6770 * linux-aarch64-low.c (aarch64_linux_delete_process): New.
6771 (struct linux_target_ops): Add delete_process callback.
6772 * linux-arm-low.c (arm_delete_process): New.
6773 (struct linux_target_ops): Add delete_process callback.
6774 * linux-bfin-low.c (struct linux_target_ops): Likewise.
6775 * linux-crisv32-low.c (struct linux_target_ops): Likewise.
6776 * linux-m32r-low.c (struct linux_target_ops): Likewise.
6777 * linux-mips-low.c (mips_linux_delete_process): New.
6778 (struct linux_target_ops): Add delete_process callback.
6779 * linux-ppc-low.c (struct linux_target_ops): Likewise.
6780 * linux-s390-low.c (struct linux_target_ops): Likewise.
6781 * linux-sh-low.c (struct linux_target_ops): Likewise.
6782 * linux-tic6x-low.c (struct linux_target_ops): Likewise.
6783 * linux-tile-low.c (struct linux_target_ops): Likewise.
6784 * linux-x86-low.c (x86_linux_delete_process): New.
6785 (struct linux_target_ops): Add delete_process callback.
6786 * linux-xtensa-low.c (struct linux_target_ops): Likewise.
6787
6788 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
6789
6790 * linux-aarch64-low.c (the_low_target): Add thread delete
6791 callback.
6792 * linux-arm-low.c (arm_delete_thread): New function.
6793 (the_low_target): Add thread delete callback.
6794 * linux-bfin-low.c (the_low_target): Likewise.
6795 * linux-crisv32-low.c (the_low_target): Likewise.
6796 * linux-low.c (delete_lwp): Invoke delete_thread callback if
6797 set.
6798 * linux-low.h (struct linux_target_ops) <delete_thread>: New
6799 field.
6800 * linux-m32r-low.c (the_low_target): Add thread delete callback.
6801 * linux-mips-low.c (mips_linux_delete_thread): New function.
6802 (the_low_target): Add thread delete callback.
6803 * linux-ppc-low.c (the_low_target): Likewise.
6804 * linux-s390-low.c (the_low_target): Likewise.
6805 * linux-sh-low.c (the_low_target): Likewise.
6806 * linux-tic6x-low.c (the_low_target): Likewise.
6807 * linux-tile-low.c (the_low_target): Likewise.
6808 * linux-x86-low.c (the_low_target): Likewise.
6809 * linux-xtensa-low.c (the_low_target): Likewise.
6810
6811 2017-10-06 Yuanhui Zhang <asmwarrior@gmail.com>
6812
6813 * win32-low.c: Include "common-inferior.h".
6814
6815 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
6816
6817 * inferiors.c (set_inferior_cwd): New function.
6818 * server.c (handle_general_set): Handle QSetWorkingDir packet.
6819 (handle_query): Inform that QSetWorkingDir is supported.
6820 * win32-low.c (create_process): Pass the inferior's cwd to
6821 CreateProcess.
6822
6823 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
6824
6825 * inferiors.c (current_inferior_cwd): New global variable.
6826 (get_inferior_cwd): New function.
6827 * inferiors.h (struct process_info) <cwd>: New field.
6828
6829 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
6830
6831 * Makefile.in (SFILES): Add $(srcdir)/common/gdb_tilde_expand.c.
6832 (OBS): Add gdb_tilde_expand.o.
6833
6834 2017-10-02 Simon Marchi <simon.marchi@ericsson.com>
6835
6836 * lynx-i386-low.c (lynx_i386_arch_setup): Call init_target_desc.
6837 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
6838
6839 2017-09-29 Pedro Alves <palves@redhat.com>
6840
6841 * ax.c (gdb_parse_agent_expr): Constify.
6842 * ax.h (gdb_parse_agent_expr): Constify.
6843 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
6844 Constify.
6845 * mem-break.h (add_breakpoint_condition, add_breakpoint_commands): Constify.
6846 * remote-utils.c (hex_or_minus_one, read_ptid): Constify.
6847 * remote-utils.h (read_ptid): Constify.
6848 * server.c (handle_qxfer_exec_file, handle_query, handle_v_cont)
6849 (process_point_options, process_serial_event): Constify.
6850 * tracepoint.c (add_tracepoint_action, cmd_qtdp, cmd_qtdpsrc)
6851 (cmd_qtdv, cmd_qtenable_disable, cmd_qtro, cmd_qtframe, cmd_qtp)
6852 (cmd_qtbuffer): Constify.
6853
6854 2017-09-29 Pedro Alves <palves@redhat.com>
6855
6856 * proc-service.c (ps_pdread): Return PS_ERR if reading memory
6857 fails.
6858
6859 2017-09-29 Pedro Alves <palves@redhat.com>
6860
6861 * linux-low.c (handle_extended_wait): Pass parent thread instead
6862 of process to thread_db_notice_clone.
6863 * linux-low.h (thread_db_notice_clone): Replace parent process
6864 parameter with parent thread parameter.
6865 * thread-db.c (find_one_thread): Add comment.
6866 (thread_db_notice_clone): Replace parent process parameter with
6867 parent thread parameter. Temporarily switch to the parent thread.
6868
6869 2017-09-26 Sergio Durigan Junior <sergiodj@redhat.com>
6870
6871 * gdbthread.h: Include "common-gdbthread.h".
6872 * inferiors.c (switch_to_thread): Use "gdb_assert" instead of
6873 "if" when validating the ptid.
6874 * remote-utils.c: Include "gdbthread.h".
6875 (prepare_resume_reply): Use "switch_to_thread".
6876 * target.c (done_accessing_memory): Likewise.
6877
6878 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
6879
6880 * configure.srv (s390*-*-linux*): Add s390-gs-linux64.o and
6881 s390x-gs-linux64.o to srv_regobj. Add s390-gs-linux64.xml,
6882 s390x-gs-linux64.xml, s390-gs.xml, and s390-gsbc.xml to
6883 srv_xmlfiles. Add s390-gs-linux64-ipa.o and
6884 s390x-gs-linux64-ipa.o to ipa_obj.
6885 * linux-s390-low.c (HWCAP_S390_GS): New define.
6886 (s390_fill_gs, s390_store_gs, s390_fill_gsbc, s390_store_gsbc):
6887 New functions.
6888 (s390_regsets): Add regsets for NT_S390_GS_CB and NT_S390_GS_BC.
6889 (s390_arch_setup): Check for guarded-storage support and choose
6890 appropriate tdesc.
6891 (initialize_low_arch): Invoke init_registers_s390_gs_linux64 and
6892 init_registers_s390x_gs_linux64.
6893 * linux-s390-tdesc.h (enum s390_linux_tdesc) <S390_TDESC_GS>: New
6894 enum value.
6895 (init_registers_s390x_gs_linux64, tdesc_s390x_gs_linux64)
6896 (init_registers_s390_gs_linux64, tdesc_s390_gs_linux64): Declare.
6897
6898 2017-09-22 Simon Marchi <simon.marchi@ericsson.com>
6899
6900 * win32-i386-low.c (i386_arch_setup): Call init_target_desc.
6901
6902 2017-09-21 Kevin Buettner <kevinb@redhat.com>
6903
6904 * linux-low.h (struct lwp_info): Add new field, thread_handle.
6905 (thread_db_thread_handle): Declare.
6906 * linux-low.c (linux_target_ops): Initialize thread_handle.
6907 * server.c (handle_qxfer_threads_worker): Add support for
6908 "handle" attribute.
6909 * target.h (struct target_ops): Add new function pointer,
6910 thread_handle.
6911 (target_thread_handle): Define.
6912 * thread-db.c (find_one_thread, attach_thread): Set thread_handle
6913 field in lwp.
6914 (thread_db_thread_handle): New function.
6915
6916 2017-09-21 Kevin Buettner <kevinb@redhat.com>
6917
6918 * linux-low.c (handle_extended_wait): Call thread_db_notice_clone().
6919 * linux-low.h (thread_db_notice_clone): Declare.
6920 * thread-db.c (thread_db_notice_clone): New function.
6921
6922 2017-09-21 Pedro Alves <palves@redhat.com>
6923
6924 * server.c (gdb_read_memory, handle_status, process_serial_event)
6925 (handle_serial_event, handle_target_event): Adjust to
6926 set_desired_thread prototype change.
6927 * target.c (set_desired_thread): Remove 'use_general' parameter
6928 and adjust.
6929 * target.h (set_desired_thread): Remove 'use_general' parameter.
6930
6931 2017-09-20 Tom Tromey <tom@tromey.com>
6932
6933 * target.c (target_terminal::terminal_state): Define.
6934 (target_terminal::init): Rename from target_terminal_init.
6935 (target_terminal::inferior): Rename from
6936 target_terminal_inferior.
6937 (target_terminal::ours): Rename from target_terminal_ours.
6938 (target_terminal::ours_for_output, target_terminal::info): New.
6939
6940 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6941
6942 * server.c (accumulate_file_name_length): Remove.
6943 (emit_dll_description): Adjust to std::string change.
6944 (handle_qxfer_libraries): Use std::string to hold document.
6945
6946 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6947
6948 * linux-low.c (linux_qxfer_libraries_svr4): Adjust to change of
6949 return type of xml_escape_text.
6950 * server.c (emit_dll_description): Likewise.
6951
6952 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6953
6954 * server.c (captured_main): Accept argument for --selftest.
6955 Update run_tests call.
6956 * linux-x86-tdesc-selftest.c (initialize_low_tdesc): Add names
6957 when registering selftests.
6958
6959 2017-09-16 Sergio Durigan Junior <sergiodj@redhat.com>
6960
6961 * regcache.c (get_thread_regcache): Update code to use "std::vector"
6962 instead of "VEC" for "target_desc.reg_defs".
6963 (regcache_cpy): Likewise.
6964 (registers_to_string): Likewise.
6965 (registers_from_string): Likewise.
6966 (find_regno): Likewise.
6967 (supply_regblock): Likewise.
6968 (regcache_raw_read_unsigned): Likewise.
6969 * tdesc.c (init_target_desc): Likewise.
6970 (tdesc_create_reg): Likewise.
6971 * tdesc.h: Remove declaration of "tdesc_reg_p". Include <vector>.
6972 (struct target_desc) <reg_defs>: Convert to "std::vector".
6973 (target_desc): Do not initialize "reg_defs".
6974 (~target_desc): Update code to use "std::vector" instead of "VEC"
6975 for "target_desc.reg_defs".
6976 (operator==): Likewise.
6977
6978 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6979
6980 * inferiors.h (thread_to_gdb_id): Remove.
6981 * inferiors.c (thread_to_gdb_id): Remove.
6982 * server.c (handle_qxfer_threads_worker, handle_query): Adjust.
6983 * lynx-low.c (lynx_resume, lynx_wait_1, lynx_fetch_registers,
6984 lynx_store_registers, lynx_read_memory, lynx_write_memory):
6985 Likewise.
6986 * nto-low.c (nto_fetch_registers, nto_store_registers,
6987 nto_stopped_by_watchpoint, nto_stopped_data_address): Likewise.
6988
6989 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6990
6991 * inferiors.h (gdb_id_to_thread_id): Remove.
6992 * inferiors.c (gdb_id_to_thread_id): Remove.
6993 * server.c (process_serial_event): Adjust to gdb_id_to_thread_id
6994 removal. Move pid declaration closer to where it's used.
6995
6996 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6997
6998 * server.c (handle_detach): New function.
6999 (process_serial_event): Move code out, call handle_detach.
7000
7001 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
7002
7003 * server.c (require_running): Rename to ...
7004 (require_running_or_return): ... this ...
7005 (require_running_or_break): ... and this.
7006 (handle_query, process_serial_event): Adjust.
7007
7008 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
7009
7010 * linux-low.c (linux_set_resume_request): Remove unused
7011 variables.
7012
7013 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
7014
7015 * server.c (first_thread_of): Remove.
7016 (process_serial_event): Replace usage of first_thread_of with
7017 find_any_thread_of_pid.
7018 * tracepoint.c (same_process_p): Remove.
7019 (gdb_agent_about_to_close): Replace usage of same_process_p with
7020 find_any_thread_of_pid.
7021 * linux-x86-low.c (same_process_callback): Remove.
7022 (x86_arch_setup_process_callback): Replace usage of
7023 same_process_callback with find_any_thread_of_pid.
7024 * thread-db.c (any_thread_of): Remove.
7025 (switch_to_process): Replace usage of any_thread_of with
7026 find_any_thread_of_pid.
7027 * inferiors.c (thread_pid_matches_callback): Remove.
7028 (find_thread_process): Adjust to use find_any_thread_of_pid.
7029
7030 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
7031
7032 * regcache.c (get_thread_regcache): Guard calls to "memset"
7033 with "!VEC_empty".
7034
7035 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
7036
7037 * linux-low.c (handle_extended_wait): Use
7038 "allocate_target_description" instead of "XNEW".
7039 * linux-x86-low.c (initialize_low_arch): Likewise.
7040
7041 2017-09-05 Yao Qi <yao.qi@linaro.org>
7042
7043 * configure.srv (srv_i386_regobj): Remove.
7044 (srv_amd64_regobj): Remove.
7045 (srv_regobj): Set it to "" for x86 non-linux targets.
7046 * linux-x86-tdesc.c (i386_linux_read_description):
7047 * lynx-i386-low.c: Include x86-xstate.h and arch/i386.h.
7048 (init_registers_i386): Remove the declaration.
7049 (tdesc_i386): Remove the declaration.
7050 (lynx_i386_arch_setup): Call i386_create_target_description.
7051 * nto-x86-low.c: Likewise.
7052 * win32-i386-low.c [__x86_64__]: include arch/amd64.h.
7053 [!__x86_64__]: include arch/i386.h.
7054 (i386_arch_setup) [__x86_64__]: Call amd64_create_target_description.
7055
7056 2017-09-05 Yao Qi <yao.qi@linaro.org>
7057
7058 * configure.srv (srv_amd64_linux_xmlfiles): Remove
7059 i386/amd64-XXX-linux from it.
7060
7061 2017-09-05 Yao Qi <yao.qi@linaro.org>
7062
7063 * configure.srv: Empty srv_amd64_linux_regobj if $development is
7064 false.
7065 (ipa_amd64_linux_regobj): Remove.
7066 (ipa_x32_linux_regobj): Remove.
7067
7068 2017-09-05 Yao Qi <yao.qi@linaro.org>
7069
7070 * Makefile.in (arch-amd64.o): New rule.
7071 * configure.srv: Append arch-amd64.o.
7072 * linux-amd64-ipa.c: Include common/x86-xstate.h.
7073 (get_ipa_tdesc): Call amd64_linux_read_description.
7074 (initialize_low_tracepoint): Don't call init_registers_x32_XXX
7075 and init_registers_amd64_XXX.
7076 * linux-x86-low.c (x86_linux_read_description): Call
7077 amd64_linux_read_description.
7078 (x86_get_ipa_tdesc_idx): Call amd64_get_ipa_tdesc_idx.
7079 (initialize_low_arch): Don't call init_registers_x32_XXX and
7080 init_registers_amd64_XXX.
7081 * linux-x86-tdesc-selftest.c: Declare init_registers_amd64_XXX
7082 and tdesc_amd64_XXX.
7083 [__x86_64__] (amd64_tdesc_test): New function.
7084 (initialize_low_tdesc) [__x86_64__]: Call init_registers_x32_XXX
7085 and init_registers_amd64_XXX.
7086 * linux-x86-tdesc.c: Include arch/amd64.h.
7087 (xcr0_to_tdesc_idx): New function.
7088 (i386_linux_read_description): New function.
7089 (amd64_get_ipa_tdesc_idx): New function.
7090 * linux-x86-tdesc.h (amd64_get_ipa_tdesc_idx): Declare.
7091 (amd64_get_ipa_tdesc): Declare.
7092
7093 2017-09-05 Yao Qi <yao.qi@linaro.org>
7094
7095 * configure.srv (srv_i386_linux_xmlfiles): Remove
7096 i386/i386-XXX-linux.xml from it.
7097
7098 2017-09-05 Yao Qi <yao.qi@linaro.org>
7099
7100 * configure.srv: Set srv_i386_linux_regobj empty if $development
7101 is false.
7102 * linux-i386-ipa.c (initialize_low_tracepoint): Don't call
7103 initialize_low_tdesc.
7104 * linux-x86-low.c (initialize_low_arch): Wrap initialize_low_tdesc
7105 with #if initialize_low_tdesc.
7106 * linux-x86-tdesc-selftest.c: New file.
7107 * linux-x86-tdesc.c: Move code to linux-x86-tdesc-selftest.c.
7108
7109 2017-09-05 Yao Qi <yao.qi@linaro.org>
7110
7111 * Makefile.in (arch-i386.o): New rule.
7112 * configure.srv (i[34567]86-*-linux*): Add arch-i386.o.
7113 (x86_64-*-linux*): Likewise.
7114 * linux-x86-tdesc.c: Don't include ../features/i386/32bit-XXX.c,
7115 include arch/i386.h.
7116 (i386_linux_read_description): Remove code and call
7117 i386_create_target_description.
7118 * tdesc.c (allocate_target_description): New function.
7119 * tdesc.h (set_tdesc_architecture): Remove declaration.
7120 (set_tdesc_osabi): Likewise.
7121
7122 2017-09-05 Yao Qi <yao.qi@linaro.org>
7123
7124 * linux-x86-tdesc.c: Don't include <inttypes.h>.
7125 (i386_linux_read_description) [!IN_PROCESS_AGENT]: Call
7126 set_tdesc_architecture and set_tdesc_osabi. Remove code setting
7127 .xmltarget.
7128 * server.c (get_features_xml): Call tdesc_get_features_xml.
7129 * tdesc.c (set_tdesc_architecture): New function.
7130 (set_tdesc_osabi): New function.
7131 (tdesc_get_features_xml): New function.
7132 (tdesc_create_feature): Add an argument.
7133 * tdesc.h (struct target_desc) <features>: New field.
7134 <arch, osabi>: New field.
7135 (~target_desc): xfree features, arch, and osabi.
7136 (target_desc::oerator==): Don't compare .xmltarget.
7137 [!IN_PROCESS_AGENT] (set_tdesc_architecture): Declare.
7138 (set_tdesc_osabi): Likewise.
7139 (tdesc_get_features_xml): Likewise.
7140
7141 2017-09-05 Yao Qi <yao.qi@linaro.org>
7142
7143 * linux-x86-tdesc.c: Include selftest.h.
7144 (i386_tdesc_test): New function.
7145 (initialize_low_tdesc): Call selftests::register_test.
7146 * tdesc.h: Include regdef.h.
7147 (target_desc): Override operator == and !=.
7148
7149 2017-09-05 Yao Qi <yao.qi@linaro.org>
7150
7151 * configure.srv (srv_tgtobj): Append linux-x86-tdesc.o.
7152 (ipa_obj): Likewise.
7153 * linux-i386-ipa.c: Include common/x86-xstate.h
7154 (get_ipa_tdesc): Call i386_linux_read_description.
7155 (initialize_low_tracepoint): Don't call init_registers_XXX
7156 functions, call initialize_low_tdesc instead.
7157 * linux-x86-low.c (x86_linux_read_description): Call
7158 i386_linux_read_description.
7159 (initialize_low_arch): Don't call init_registers_i386_XXX
7160 functions, call initialize_low_tdesc.
7161 * linux-x86-tdesc.c: New file.
7162 * linux-x86-tdesc.h (x86_linux_tdesc): New X86_TDESC_LAST.
7163 (i386_get_ipa_tdesc_idx): Declare.
7164 (i386_get_ipa_tdesc): Declare.
7165 (initialize_low_tdesc): Declare.
7166
7167 2017-09-05 Yao Qi <yao.qi@linaro.org>
7168
7169 * linux-x86-low.c (x86_get_ipa_tdesc_idx): Use X86_TDESC_MMX
7170 instead of 0.
7171
7172 2017-09-05 Yao Qi <yao.qi@linaro.org>
7173
7174 * Makefile.in (IPA_OBJS): Add vec-ipa.o
7175 * regcache.c (get_thread_regcache): Use VEC_length.
7176 (init_register_cache): Likewise.
7177 (regcache_cpy): Likewise.
7178 (registers_to_string): Iterate reg_defs via VEC_iterate.
7179 (find_regno): Likewise.
7180 (find_register_by_number): Use VEC_index.
7181 (register_size): Call find_register_by_number.
7182 (register_data): Call find_register_by_number.
7183 (supply_regblock): Use VEC_length.
7184 (regcache_raw_read_unsigned): Likewise.
7185 * tdesc.c (init_target_desc): Iterate reg_defs via
7186 VEC_iterate.
7187 (default_description): Update initializer.
7188 (copy_target_description): Don't update field num_registers.
7189 * tdesc.h (struct target_desc) <reg_defs>: Change it to VEC.
7190 <num_registers>: Remove.
7191
7192 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
7193
7194 * Makefile.in (.SECONDARY): Define target.
7195
7196 2017-09-03 Simon Marchi <simon.marchi@ericsson.com>
7197
7198 * linux-low.c (linux_wait_1): Adjust.
7199 * server.c (queue_stop_reply_callback): Adjust.
7200
7201 2017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
7202
7203 * server.c (handle_general_set): Handle QEnvironmentHexEncoded,
7204 QEnvironmentUnset and QEnvironmentReset packets.
7205 (handle_query): Inform remote that QEnvironmentHexEncoded,
7206 QEnvironmentUnset and QEnvironmentReset are supported.
7207
7208 2017-08-25 Simon Marchi <simon.marchi@ericsson.com>
7209
7210 * inferiors.h (inferior_target_data): Rename to ...
7211 (thread_target_data): ... this.
7212 (inferior_regcache_data): Rename to ...
7213 (thread_regcache_data): ... this.
7214 (set_inferior_regcache_data): Rename to ...
7215 (set_thread_regcache_data): ... this.
7216 * inferiors.c (inferior_target_data): Rename to ...
7217 (thread_target_data): ... this.
7218 (inferior_regcache_data): Rename to ...
7219 (thread_regcache_data): ... this.
7220 (set_inferior_regcache_data): Rename to ...
7221 (set_thread_regcache_data): ... this.
7222 (free_one_thread): Update.
7223 * linux-low.h (get_thread_lwp): Update.
7224 * regcache.c (get_thread_regcache): Update.
7225 (regcache_invalidate_thread): Update.
7226 (free_register_cache_thread): Update.
7227 * win32-i386-low.c (update_debug_registers_callback): Update.
7228 (win32_get_current_dr): Update.
7229 * win32-low.c (thread_rec): Update.
7230 (delete_thread_info): Update.
7231 (continue_one_thread): Update.
7232 (suspend_one_thread): Update.
7233
7234 2017-08-24 Simon Marchi <simon.marchi@ericsson.com>
7235
7236 * inferiors.c (set_inferior_target_data): Remove.
7237 * inferiors.h (set_inferior_target_data): Remove.
7238
7239 2017-08-18 Yao Qi <yao.qi@linaro.org>
7240
7241 * Makefile.in (OBS): Add selftest.o.
7242 * configure.ac: AC_DEFINE GDB_SELF_TEST if $development.
7243 * configure, config.in: Re-generated.
7244 * server.c: Include common/sefltest.h.
7245 (captured_main): Handle option --selftest.
7246
7247 2017-08-09 Yao Qi <yao.qi@linaro.org>
7248
7249 * configure.srv (srv_i386_regobj): Remove i386-avx.o,
7250 i386-avx-avx512.o, i386-avx-mpx-avx512-pku.o, i386-mpx.o,
7251 i386-avx-mpx.o and i386-mmx.o.
7252 (srv_amd64_regobj): Remove amd64-avx.o, amd64-avx-avx512.o,
7253 amd64-avx-mpx-avx512-pku.o, amd64-mpx.o and amd64-avx-mpx.o.
7254 (srv_i386_xmlfiles): Remove i386/i386-avx.xml,
7255 i386/i386-avx-avx512.xml, i386/i386-avx-mpx-avx512-pku.xml,
7256 i386/i386-mpx.xml, i386/i386-avx-mpx.xml and i386/i386-mmx.xml.
7257 (srv_amd64_xmlfile):i386/amd64-avx.xml, i386/amd64-avx-avx512.xml,
7258 i386/amd64-avx-mpx-avx512-pku.xml, i386/amd64-mpx.xml,
7259 i386/amd64-avx-mpx.xml.
7260
7261 2017-08-09 Yao Qi <yao.qi@linaro.org>
7262
7263 * configure.srv (srv_amd64_regobj): Remove x32.o, x32-avx.o
7264 and x32-avx-avx512.o.
7265 (srv_amd64_xmlfiles): Remove i386/x32.xml, i386/x32-avx.xml
7266 i386/x32-avx-avx512.xml.
7267
7268 2017-07-26 Simon Marchi <simon.marchi@ericsson.com>
7269
7270 * tracepoint.h (enum class fast_tpoint_collect_result): New
7271 enumeration.
7272 (fast_tracepoint_collecting): Change return type to
7273 fast_tpoint_collect_result.
7274 * tracepoint.c (fast_tracepoint_collecting): Likewise.
7275 * linux-low.h: Include tracepoint.h.
7276 (struct lwp_info) <collecting_fast_tracepoint>: Change type to
7277 fast_tpoint_collect_result.
7278 * linux-low.c (handle_tracepoints): Adjust.
7279 (linux_fast_tracepoint_collecting): Change return type to
7280 fast_tpoint_collect_result.
7281 (maybe_move_out_of_jump_pad, linux_wait_for_event_filtered,
7282 linux_wait_1, stuck_in_jump_pad_callback,
7283 lwp_signal_can_be_delivered, linux_resume_one_lwp_throw,
7284 proceed_one_lwp): Adjust to type change.
7285
7286 2017-07-10 Yao Qi <yao.qi@linaro.org>
7287
7288 * linux-x86-low.c (x86_linux_read_description): Re-indent the code.
7289
7290 2017-06-29 Yao Qi <yao.qi@linaro.org>
7291
7292 * tdesc.h (struct target_desc) [IN_PROCESS_AGENT] <expedite_regs>:
7293 Remove.
7294 [IN_PROCESS_AGENT] <xmltarget>: Likewise.
7295
7296 2017-06-20 Simon Marchi <simon.marchi@ericsson.com>
7297
7298 * Makefile.in (IPA_OBJS): Sort and format one item per line.
7299
7300 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
7301
7302 * linux-low.c (linux_create_inferior): Adjust code to access the
7303 environment information via 'gdb_environ' class.
7304 * lynx-low.c (lynx_create_inferior): Likewise.
7305 * server.c (our_environ): Make it an instance of 'gdb_environ'.
7306 (get_environ): Return a pointer to 'our_environ'.
7307 (captured_main): Initialize 'our_environ'.
7308 * server.h (get_environ): Adjust prototype.
7309 * spu-low.c (spu_create_inferior): Adjust code to access the
7310 environment information via 'gdb_environ' class.
7311
7312 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
7313
7314 * linux-low.c (linux_read_memory, linux_write_memory): Remove
7315 usage of "register" keyword.
7316
7317 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
7318
7319 * configure: Re-generate.
7320
7321 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
7322
7323 * configure: Re-generate.
7324
7325 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
7326
7327 * Makefile.in (COMPILE.pre): Add "-x c++".
7328
7329 2017-06-09 Sergio Durigan Junior <sergiodj@redhat.com>
7330
7331 * fork-child.c: Conditionally include <signal.h>.
7332
7333 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
7334
7335 * server.c (handle_general_set): Handle new packet
7336 "QStartupWithShell".
7337 (handle_query): Add "QStartupWithShell" to the list of supported
7338 packets.
7339 (gdbserver_usage): Add help text explaining the
7340 new "--startup-with-shell" and "--no-startup-with-shell" CLI
7341 options.
7342 (captured_main): Recognize and act upon the presence of the new
7343 CLI options.
7344
7345 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
7346 Pedro Alves <palves@redhat.com>
7347
7348 * Makefile.in (SFILES): Add "nat/fork-inferior.o".
7349 * configure: Regenerate.
7350 * configure.srv (srv_linux_obj): Add "fork-child.o" and
7351 "fork-inferior.o".
7352 (i[34567]86-*-lynxos*): Likewise.
7353 (spu*-*-*): Likewise.
7354 * fork-child.c: New file.
7355 * linux-low.c: Include "common-inferior.h", "nat/fork-inferior.h"
7356 and "environ.h".
7357 (linux_ptrace_fun): New function.
7358 (linux_create_inferior): Adjust function prototype to reflect
7359 change on "target.h". Adjust function code to use
7360 "fork_inferior".
7361 (linux_request_interrupt): Delete "signal_pid".
7362 * lynx-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
7363 (lynx_ptrace_fun): New function.
7364 (lynx_create_inferior): Adjust function prototype to reflect
7365 change on "target.h". Adjust function code to use
7366 "fork_inferior".
7367 * nto-low.c (nto_create_inferior): Adjust function prototype and
7368 code to reflect change on "target.h". Update comments.
7369 * server.c: Include "common-inferior.h", "nat/fork-inferior.h",
7370 "common-terminal.h" and "environ.h".
7371 (terminal_fd): Moved to fork-child.c.
7372 (old_foreground_pgrp): Likewise.
7373 (restore_old_foreground_pgrp): Likewise.
7374 (last_status): Make it global.
7375 (last_ptid): Likewise.
7376 (our_environ): New variable.
7377 (startup_with_shell): Likewise.
7378 (program_name): Likewise.
7379 (program_argv): Rename to...
7380 (program_args): ...this.
7381 (wrapper_argv): New variable.
7382 (start_inferior): Delete function.
7383 (get_exec_wrapper): New function.
7384 (get_exec_file): Likewise.
7385 (get_environ): Likewise.
7386 (prefork_hook): Likewise.
7387 (post_fork_inferior): Likewise.
7388 (postfork_hook): Likewise.
7389 (postfork_child_hook): Likewise.
7390 (handle_v_run): Update code to deal with arguments coming from the
7391 remote host. Update calls from "start_inferior" to
7392 "create_inferior".
7393 (captured_main): Likewise. Initialize environment variable. Call
7394 "have_job_control".
7395 * server.h (post_fork_inferior): New prototype.
7396 (get_environ): Likewise.
7397 (last_status): Declare.
7398 (last_ptid): Likewise.
7399 (signal_pid): Likewise.
7400 * spu-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
7401 (spu_ptrace_fun): New function.
7402 (spu_create_inferior): Adjust function prototype to reflect change
7403 on "target.h". Adjust function code to use "fork_inferior".
7404 * target.c (target_terminal_init): New function.
7405 (target_terminal_inferior): Likewise.
7406 (target_terminal_ours): Likewise.
7407 * target.h: Include <vector>.
7408 (struct target_ops) <create_inferior>: Update prototype.
7409 (create_inferior): Update macro.
7410 * utils.c (gdb_flush_out_err): New function.
7411 * win32-low.c (win32_create_inferior): Adjust function prototype
7412 and code to reflect change on "target.h".
7413
7414 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
7415
7416 * inferiors.c (switch_to_thread): New function.
7417
7418 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
7419
7420 * Makefile.in (SFILE): Add "common/job-control.c".
7421 (OBS): Add "job-control.o".
7422
7423 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
7424
7425 * Makefile: Remove "@host_makefile_frag@".
7426
7427 2017-05-05 Pedro Alves <palves@redhat.com>
7428
7429 * configure: Regenerate.
7430
7431 2017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
7432
7433 * configure: Regenerate.
7434
7435 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
7436
7437 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Adjust to
7438 software_single_step change of return type to
7439 std::vector<CORE_ADDR>.
7440 * linux-low.c (install_software_single_step_breakpoints):
7441 Likewise.
7442 * linux-low.h (install_software_single_step_breakpoints):
7443 Likewise.
7444
7445 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
7446
7447 * remote-utils.c: Include "gdb_termios.h" instead of
7448 "terminal.h".
7449 * terminal.h: Delete file.
7450
7451 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
7452
7453 * server.c: Include <vector>.
7454 <program_argv, wrapper_argv>: Convert to std::vector.
7455 (start_inferior): Rewrite function to use C++.
7456 (handle_v_run): Likewise. Update code that calculates the argv
7457 based on the vRun packet; use C++.
7458 (captured_main): Likewise.
7459
7460 2017-04-06 Simon Marchi <simon.marchi@ericsson.com>
7461
7462 * server.c (handle_v_cont): Initialize thread_resume::thread
7463 with null_ptid.
7464
7465 2017-04-05 Pedro Alves <palves@redhat.com>
7466
7467 * configure: Regenerate.
7468
7469 2017-04-05 Pedro Alves <palves@redhat.com>
7470
7471 * gdbreplay.c (sync_error): Constify.
7472 * linux-x86-low.c (push_opcode): Constify.
7473
7474 2017-04-05 Pedro Alves <palves@redhat.com>
7475
7476 * win32-low.c (get_child_debug_event)
7477 <CREATE_PROCESS_DEBUG_EVENT>: Don't report TARGET_WAITKIND_EXECD.
7478 Report TARGET_WAITKIND_SPURIOUS instead.
7479
7480 2017-04-05 Pedro Alves <palves@redhat.com>
7481
7482 * remote-utils.c (remote_prepare, remote_open): Constify.
7483 * remote-utils.h (remote_prepare, remote_open): Constify.
7484 * server.c (captured_main): Constify 'port' handling.
7485
7486 2017-04-04 Simon Marchi <simon.marchi@ericsson.com>
7487
7488 * Makefile.in (clean): Clear .deps.
7489
7490 2017-03-31 Simon Marchi <simon.marchi@polymtl.ca>
7491
7492 * .gitignore: Remove generated files, replace with wildcard.
7493 * (clean): Replace removal of generated files with wildcard.
7494 (version.c): Replace with...
7495 (version-generated.c): ...this.
7496 (xml-builtin.c): Replace with...
7497 (xml-builtin-generated.c): ...this.
7498 (%-ipa.o: %-generated.c, %.o: %-generated.c): New rules.
7499 (%.c: *regformats*): Replace with...
7500 (%-generated.c: *regformats*): ...this.
7501
7502 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
7503
7504 * linux-xtensa-low.c (regnum::R_THREADPTR): New enum member.
7505 (xtensa_fill_gregset): Call collect_register_by_name for
7506 threadptr register.
7507 (xtensa_store_gregset): Call supply_register_by_name for
7508 threadptr register.
7509
7510 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
7511
7512 * linux-xtensa-low.c (xtensa_fill_gregset): Call collect_register
7513 for all registers in a0_regnum..a0_regnum + C0_NREGS range.
7514 (xtensa_store_gregset): Call supply_register for all registers in
7515 a0_regnum..a0_regnum + C0_NREGS range.
7516
7517 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7518
7519 * Makefile.in (%-ipa.o: %-ipa.c): New rule.
7520 (ax-ipa.o: ax.c): Remove.
7521 (linux-i386-ipa.o: linux-i386-ipa.c): Remove.
7522 (linux-amd64-ipa.o: linux-amd64-ipa.c): Remove.
7523 (linux-aarch64-ipa.o: linux-aarch64-ipa.c): Remove.
7524 (linux-s390-ipa.o: linux-s390-ipa.c): Remove.
7525 (linux-ppc-ipa.o: linux-ppc-ipa.c): Remove.
7526
7527 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7528
7529 * Makefile.in (%-ipa.o: ../common/%.c): New rule.
7530 (print-utils-ipa.o: ../common/print-utils.c): Remove.
7531 (rsp-low-ipa.o: ../common/rsp-low.c): Remove.
7532 (errors-ipa.o: ../common/errors.c): Remove.
7533 (format-ipa.o: ../common/format.c): Remove.
7534 (common-utils-ipa.o: ../common/common-utils.c): Remove.
7535
7536 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7537
7538 * Makefile.in (%-ipa.o: %.c): New rule.
7539 (tracepoint-ipa.o: tracepoint.c): Remove.
7540 (utils-ipa.o: utils.c): Remove.
7541 (remote-utils-ipa.o: remote-utils.c): Remove.
7542 (regcache-ipa.o: regcache.c): Remove.
7543 (i386-linux-ipa.o: i386-linux.c): Remove.
7544 (i386-mmx-linux-ipa.o: i386-mmx-linux.c): Remove.
7545 (i386-avx-linux-ipa.o: i386-avx-linux.c): Remove.
7546 (i386-mpx-linux-ipa.o: i386-mpx-linux.c): Remove.
7547 (i386-avx-mpx-linux-ipa.o: i386-avx-mpx-linux.c): Remove.
7548 (i386-avx-avx512-linux-ipa.o: i386-avx-avx512-linux.c): Remove.
7549 (i386-avx-mpx-avx512-pku-linux-ipa.o: i386-avx-mpx-avx512-pku-linux.c): Remove.
7550 (amd64-linux-ipa.o: amd64-linux.c): Remove.
7551 (amd64-avx-linux-ipa.o: amd64-avx-linux.c): Remove.
7552 (amd64-mpx-linux-ipa.o: amd64-mpx-linux.c): Remove.
7553 (amd64-avx-mpx-linux-ipa.o: amd64-avx-mpx-linux.c): Remove.
7554 (amd64-avx-avx512-linux-ipa.o: amd64-avx-avx512-linux.c): Remove.
7555 (amd64-avx-mpx-avx512-pku-linux-ipa.o: amd64-avx-mpx-avx512-pku-linux.c): Remove.
7556 (aarch64-ipa.o: aarch64.c): Remove.
7557 (s390-linux32-ipa.o: s390-linux32.c): Remove.
7558 (s390-linux32v1-ipa.o: s390-linux32v1.c): Remove.
7559 (s390-linux32v2-ipa.o: s390-linux32v2.c): Remove.
7560 (s390-linux64-ipa.o: s390-linux64.c): Remove.
7561 (s390-linux64v1-ipa.o: s390-linux64v1.c): Remove.
7562 (s390-linux64v2-ipa.o: s390-linux64v2.c): Remove.
7563 (s390-te-linux64-ipa.o: s390-te-linux64.c): Remove.
7564 (s390-vx-linux64-ipa.o: s390-vx-linux64.c): Remove.
7565 (s390-tevx-linux64-ipa.o: s390-tevx-linux64.c): Remove.
7566 (s390x-linux64-ipa.o: s390x-linux64.c): Remove.
7567 (s390x-linux64v1-ipa.o: s390x-linux64v1.c): Remove.
7568 (s390x-linux64v2-ipa.o: s390x-linux64v2.c): Remove.
7569 (s390x-te-linux64-ipa.o: s390x-te-linux64.c): Remove.
7570 (s390x-vx-linux64-ipa.o: s390x-vx-linux64.c): Remove.
7571 (s390x-tevx-linux64-ipa.o: s390x-tevx-linux64.c): Remove.
7572 (powerpc-32l-ipa.o: powerpc-32l.c): Remove.
7573 (powerpc-altivec32l-ipa.o: powerpc-altivec32l.c): Remove.
7574 (powerpc-cell32l-ipa.o: powerpc-cell32l.c): Remove.
7575 (powerpc-vsx32l-ipa.o: powerpc-vsx32l.c): Remove.
7576 (powerpc-isa205-32l-ipa.o: powerpc-isa205-32l.c): Remove.
7577 (powerpc-isa205-altivec32l-ipa.o: powerpc-isa205-altivec32l.c): Remove.
7578 (powerpc-isa205-vsx32l-ipa.o: powerpc-isa205-vsx32l.c): Remove.
7579 (powerpc-e500l-ipa.o: powerpc-e500l.c): Remove.
7580 (powerpc-64l-ipa.o: powerpc-64l.c): Remove.
7581 (powerpc-altivec64l-ipa.o: powerpc-altivec64l.c): Remove.
7582 (powerpc-cell64l-ipa.o: powerpc-cell64l.c): Remove.
7583 (powerpc-vsx64l-ipa.o: powerpc-vsx64l.c): Remove.
7584 (powerpc-isa205-64l-ipa.o: powerpc-isa205-64l.c): Remove.
7585 (powerpc-isa205-altivec64l-ipa.o: powerpc-isa205-altivec64l.c): Remove.
7586 (powerpc-isa205-vsx64l-ipa.o: powerpc-isa205-vsx64l.c): Remove.
7587 (tdesc-ipa.o: tdesc.c): Remove.
7588 (x32-linux-ipa.o: x32-linux.c): Remove.
7589 (x32-avx-linux-ipa.o: x32-avx-linux.c): Remove.
7590 (x32-avx512-linux-ipa.o: x32-avx512-linux.c): Remove.
7591
7592 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7593
7594 * Makefile.in (%.o: ../arch/%.c): New rule.
7595 (arm.o: ../arch/arm.c): Remove.
7596 (arm-linux.o: ../arch/arm-linux.c): Remove.
7597 (arm-get-next-pcs.o: ../arch/arm-get-next-pcs.c): Remove.
7598 (aarch64-insn.o: ../arch/aarch64-insn.c): Remove.
7599
7600 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7601
7602 * Makefile.in (%.o: ../nat/%.c): New rule.
7603 (x86-dregs.o: ../nat/x86-dregs.c): Remove.
7604 (amd64-linux-siginfo.o: ../nat/amd64-linux-siginfo.c): Remove.
7605 (linux-btrace.o: ../nat/linux-btrace.c): Remove.
7606 (linux-osdata.o: ../nat/linux-osdata.c): Remove.
7607 (linux-procfs.o: ../nat/linux-procfs.c): Remove.
7608 (linux-ptrace.o: ../nat/linux-ptrace.c): Remove.
7609 (linux-waitpid.o: ../nat/linux-waitpid.c): Remove.
7610 (mips-linux-watch.o: ../nat/mips-linux-watch.c): Remove.
7611 (ppc-linux.o: ../nat/ppc-linux.c): Remove.
7612 (linux-personality.o: ../nat/linux-personality.c): Remove.
7613 (aarch64-linux-hw-point.o: ../nat/aarch64-linux-hw-point.c): Remove.
7614 (aarch64-linux.o: ../nat/aarch64-linux.c): Remove.
7615 (x86-linux.o: ../nat/x86-linux.c): Remove.
7616 (x86-linux-dregs.o: ../nat/x86-linux-dregs.c): Remove.
7617 (linux-namespaces.o: ../nat/linux-namespaces.c): Remove.
7618
7619 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7620
7621 * Makefile.in (%.o: ../common/%.c): New rule.
7622 (signals.o: ../common/signals.c): Remove.
7623 (print-utils.o: ../common/print-utils.c): Remove.
7624 (rsp-low.o: ../common/rsp-low.c): Remove.
7625 (common-utils.o: ../common/common-utils.c): Remove.
7626 (posix-strerror.o: ../common/posix-strerror.c): Remove.
7627 (mingw-strerror.o: ../common/mingw-strerror.c): Remove.
7628 (vec.o: ../common/vec.c): Remove.
7629 (gdb_vecs.o: ../common/gdb_vecs.c): Remove.
7630 (xml-utils.o: ../common/xml-utils.c): Remove.
7631 (ptid.o: ../common/ptid.c): Remove.
7632 (buffer.o: ../common/buffer.c): Remove.
7633 (format.o: ../common/format.c): Remove.
7634 (filestuff.o: ../common/filestuff.c): Remove.
7635 (agent.o: ../common/agent.c): Remove.
7636 (errors.o: ../common/errors.c): Remove.
7637 (environ.o: ../common/environ.c): Remove.
7638 (common-debug.o: ../common/common-debug.c): Remove.
7639 (cleanups.o: ../common/cleanups.c): Remove.
7640 (common-exceptions.o: ../common/common-exceptions.c): Remove.
7641 (fileio.o: ../common/fileio.c): Remove.
7642 (common-regcache.o: ../common/common-regcache.c): Remove.
7643 (signals-state-save-restore.o: ../common/signals-state-save-restore.c): Remove.
7644 (new-op.o: ../common/new-op.c): Remove.
7645 (btrace-common.o: ../common/btrace-common.c): Remove.
7646
7647 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7648
7649 * Makefile.in (%.o: ../target/%.c): New rule.
7650 (waitstatus.o: ../target/waitstatus.c): Remove.
7651
7652 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7653
7654 * Makefile.in
7655 (%.c: ../regformats/%.dat,
7656 (%.c: ../regformats/arm/%.dat,
7657 (%.c: ../regformats/i386/%.dat,
7658 (%.c: ../regformats/rs6000/%.dat): New rules.
7659 (aarch64.c): Remove.
7660 (reg-arm.c): Remove.
7661 (arm-with-iwmmxt.c): Remove.
7662 (arm-with-vfpv2.c): Remove.
7663 (arm-with-vfpv3.c): Remove.
7664 (arm-with-neon.c): Remove.
7665 (reg-bfin.c): Remove.
7666 (reg-cris.c): Remove.
7667 (reg-crisv32.c): Remove.
7668 (i386.c): Remove.
7669 (i386-linux.c): Remove.
7670 (i386-avx.c): Remove.
7671 (i386-avx-linux.c): Remove.
7672 (i386-avx-avx512.c): Remove.
7673 (i386-avx-avx512-linux.c): Remove.
7674 (i386-mpx.c): Remove.
7675 (i386-mpx-linux.c): Remove.
7676 (i386-avx-mpx-avx512-pku.c): Remove.
7677 (i386-avx-mpx-avx512-pku-linux.c): Remove.
7678 (i386-avx-mpx.c): Remove.
7679 (i386-avx-mpx-linux.c): Remove.
7680 (i386-mmx.c): Remove.
7681 (i386-mmx-linux.c): Remove.
7682 (reg-ia64.c): Remove.
7683 (reg-m32r.c): Remove.
7684 (reg-m68k.c): Remove.
7685 (reg-cf.c): Remove.
7686 (mips-linux.c): Remove.
7687 (mips-dsp-linux.c): Remove.
7688 (mips64-linux.c): Remove.
7689 (mips64-dsp-linux.c): Remove.
7690 (nios2-linux.c): Remove.
7691 (powerpc-32.c): Remove.
7692 (powerpc-32l.c): Remove.
7693 (powerpc-altivec32l.c): Remove.
7694 (powerpc-cell32l.c): Remove.
7695 (powerpc-vsx32l.c): Remove.
7696 (powerpc-isa205-32l.c): Remove.
7697 (powerpc-isa205-altivec32l.c): Remove.
7698 (powerpc-isa205-vsx32l.c): Remove.
7699 (powerpc-e500l.c): Remove.
7700 (powerpc-64l.c): Remove.
7701 (powerpc-altivec64l.c): Remove.
7702 (powerpc-cell64l.c): Remove.
7703 (powerpc-vsx64l.c): Remove.
7704 (powerpc-isa205-64l.c): Remove.
7705 (powerpc-isa205-altivec64l.c): Remove.
7706 (powerpc-isa205-vsx64l.c): Remove.
7707 (s390-linux32.c): Remove.
7708 (s390-linux32v1.c): Remove.
7709 (s390-linux32v2.c): Remove.
7710 (s390-linux64.c): Remove.
7711 (s390-linux64v1.c): Remove.
7712 (s390-linux64v2.c): Remove.
7713 (s390-te-linux64.c): Remove.
7714 (s390-vx-linux64.c): Remove.
7715 (s390-tevx-linux64.c): Remove.
7716 (s390x-linux64.c): Remove.
7717 (s390x-linux64v1.c): Remove.
7718 (s390x-linux64v2.c): Remove.
7719 (s390x-te-linux64.c): Remove.
7720 (s390x-vx-linux64.c): Remove.
7721 (s390x-tevx-linux64.c): Remove.
7722 (tic6x-c64xp-linux.c): Remove.
7723 (tic6x-c64x-linux.c): Remove.
7724 (tic6x-c62x-linux.c): Remove.
7725 (reg-sh.c): Remove.
7726 (reg-sparc64.c): Remove.
7727 (reg-spu.c): Remove.
7728 (amd64.c): Remove.
7729 (amd64-linux.c): Remove.
7730 (amd64-avx.c): Remove.
7731 (amd64-avx-linux.c): Remove.
7732 (amd64-avx-avx512.c): Remove.
7733 (amd64-avx-avx512-linux.c): Remove.
7734 (amd64-mpx.c): Remove.
7735 (amd64-mpx-linux.c): Remove.
7736 (amd64-avx-mpx-avx512-pku.c): Remove.
7737 (amd64-avx-mpx-avx512-pku-linux.c): Remove.
7738 (amd64-avx-mpx.c): Remove.
7739 (amd64-avx-mpx-linux.c): Remove.
7740 (x32.c): Remove.
7741 (x32-linux.c): Remove.
7742 (x32-avx.c): Remove.
7743 (x32-avx-linux.c): Remove.
7744 (x32-avx-avx512.c): Remove.
7745 (x32-avx-avx512-linux.c): Remove.
7746 (reg-xtensa.c): Remove.
7747 (reg-tilegx.c): Remove.
7748 (reg-tilegx32.c): Remove.
7749
7750 2017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
7751
7752 * Makefile.in (SFILES): Add "common/environ.c".
7753 (OBJS): Add "common/environ.h".
7754
7755 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
7756
7757 * configure.ac: Check if the fs_base and gs_base members of
7758 `struct user_regs_struct' exist.
7759 * config.in: Regenerated.
7760 * configure: Likewise.
7761
7762 2017-01-09 Antoine Tremblay <antoine.tremblay@ericsson.com>
7763
7764 * linux-aarch32-low.c (arm_breakpoint_kind_from_pc): Use
7765 target_read_memory.
7766 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer): Likewise.
7767 (get_next_pcs_syscall_next_pc): Likewise.
7768
7769 2016-12-23 Luis Machado <lgustavo@codesourcery.com>
7770
7771 * win32-i386-low.c: Fix incorrect reference to a couple source files.
7772 * nto-x86-low.c: Likewise.
7773
7774 2016-11-30 Simon Marchi <simon.marchi@polymtl.ca>
7775
7776 * Makefile.in: Include disable-implicit-rules.mk.
7777
7778 2016-11-23 Pedro Alves <palves@redhat.com>
7779
7780 * debug.c: Include <chrono> instead of "gdb_sys_time.h".
7781 (debug_vprintf): Use std::chrono::steady_clock instead of
7782 gettimeofday. Use '.' instead of ':'.
7783 * tracepoint.c: Include <chrono> instead of "gdb_sys_time.h".
7784 (get_timestamp): Use std::chrono::steady_clock instead of
7785 gettimeofday.
7786
7787 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
7788
7789 * Makefile.in: Fix whitespace formatting.
7790
7791 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
7792
7793 * Makefile.in (SFILES, OBS): Flatten list and order
7794 alphabetically.
7795
7796 2016-11-23 Pedro Alves <palves@redhat.com>
7797
7798 * event-loop.c (handle_file_event): Use warning.
7799 * linux-low.c (linux_resume_one_lwp_throw): Use warning.
7800 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
7801 Use warning.
7802
7803 2016-11-23 Pedro Alves <palves@redhat.com>
7804
7805 * linux-low.c (check_zombie_leaders): Use debug_printf for debug
7806 output.
7807 * notif.c (handle_notif_ack, notif_event_enque): Likewise.
7808 * remote-utils.c (putpkt_binary_1, readchar, getpkt): Use
7809 debug_printf and debug_flush for debug output.
7810 * server.c (handle_general_set): Likewise.
7811 * thread-db.c (try_thread_db_load): Use debug_printf for debug
7812 output.
7813
7814 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
7815
7816 * Makefile.in (.c.o): Replace rule with ...
7817 (%.o: %.c): ... this one.
7818
7819 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
7820
7821 * Makefile.in: Remove @GMAKE_TRUE@ prefixes and removes lines
7822 prefixed with @GMAKE_FALSE@. Update comment related to non-GNU
7823 make.
7824 * configure.ac: Remove checks for the make program.
7825 * configure: Re-generate.
7826
7827 2016-10-28 Pedro Alves <palves@redhat.com>
7828
7829 * Makefile.in (CXX_DIALECT): Get from configure.
7830 (COMPILE.pre, CC_LD): Append $(CXX_DIALECT).
7831 * acinclude.m4: Include ../ax_cxx_compile_stdcxx.m4.
7832 * configure.ac: Call AX_CXX_COMPILE_STDCXX.
7833 * config.in: Regenerate.
7834 * configure: Regenerate.
7835
7836 2016-10-27 Yao Qi <yao.qi@linaro.org>
7837
7838 * linux-low.c (linux_supports_range_stepping): Return true if
7839 can_software_single_step return true.
7840
7841 2016-10-27 Yao Qi <yao.qi@linaro.org>
7842
7843 * inferiors.c (find_inferior_in_random): New function.
7844 * inferiors.h (find_inferior_in_random): Declare.
7845 * linux-low.c (linux_wait_for_event_filtered): Call
7846 find_inferior_in_random instead of find_inferior.
7847
7848 2016-10-27 Yao Qi <yao.qi@linaro.org>
7849
7850 * linux-low.c (linux_wait_1): If single-step breakpoints are
7851 inserted, remove them.
7852
7853 2016-10-26 Pedro Alves <palves@redhat.com>
7854
7855 * linux-low.c (handle_extended_wait): Link parent/child fork
7856 threads.
7857 (linux_wait_1): Unlink them.
7858 (linux_set_resume_request): Ignore resume requests for
7859 already-resumed and unhandled fork child threads.
7860 * linux-low.h (struct lwp_info) <fork_relative>: New field.
7861 * server.c (in_queued_stop_replies_ptid, in_queued_stop_replies):
7862 New functions.
7863 (handle_v_requests) <vCont>: Don't call require_running.
7864 * server.h (in_queued_stop_replies): New declaration.
7865
7866 2016-10-24 Yao Qi <yao.qi@linaro.org>
7867
7868 PR server/20733
7869 * linux-aarch64-low.c (append_insns): Cast the return value to
7870 'uint32_t *'.
7871
7872 2016-10-10 Yao Qi <yao.qi@linaro.org>
7873
7874 * linux-aarch32-low.c (enum arm_breakpoint_kinds): Remove.
7875
7876 2016-10-06 Sergio Durigan Junior <sergiodj@redhat.com>
7877
7878 * target.c (target_supports_multi_process): New function, moved
7879 from...
7880 * target.h (target_supports_multi_process): ... here. Remove
7881 macro.
7882
7883 2016-10-05 Tom Tromey <tom@tromey.com>
7884
7885 PR remote/20655:
7886 * tracepoint.c (handle_tracepoint_bkpts): Check
7887 ipa_error_tracepoint, not ipa_stopping_tracepoint.
7888
7889 2016-10-05 Yao Qi <yao.qi@linaro.org>
7890
7891 * configure.srv: Update the path of arm-*.xml files.
7892
7893 2016-10-05 Terry Guo <terry.guo@arm.com>
7894 Yao Qi <yao.qi@linaro.org>
7895
7896 * Makefile.in: Adjust the path of rules.
7897 * configure.srv: Update the path of xml files.
7898 * regformats/arm-with-iwmmxt.dat: Regenerated.
7899 * regformats/arm-with-neon.dat: Likewise.
7900 * regformats/arm-with-vfpv2.dat: Likewise.
7901 * regformats/arm-with-vfpv3.dat Likewise.
7902
7903 2016-09-30 Yao Qi <yao.qi@linaro.org>
7904
7905 PR gdbserver/20627
7906 * target.c (target_stop_and_wait): Don't call
7907 target_continue_no_signal, use resume_stop instead.
7908
7909 2016-09-26 Yao Qi <yao.qi@linaro.org>
7910
7911 * linux-low.c (linux_wait_1): Call debug_exit.
7912
7913 2016-09-23 Pedro Alves <palves@redhat.com>
7914
7915 * Makefile.in (SFILES): Add common/new-op.c.
7916 (OBS): Add common/new-op.o.
7917 (new-op.o): New rule.
7918
7919 2016-09-21 Simon Marchi <simon.marchi@ericsson.com>
7920
7921 * .gitinore: Ignore more files.
7922
7923 2016-09-21 Yao Qi <yao.qi@linaro.org>
7924
7925 * linux-aarch32-low.c (arm_fill_gregset): Keep bits 20 to
7926 23.
7927
7928 2016-09-19 Sergio Durigan Junior <sergiodj@redhat.com>
7929
7930 * server.c (start_inferior): Call target_mourn_inferior instead of
7931 mourn_inferior; pass ptid_t argument to it.
7932 (resume): Likewise.
7933 (handle_target_event): Likewise.
7934 * target.c (target_mourn_inferior): New function.
7935 * target.h (mourn_inferior): Delete macro.
7936
7937 2016-09-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
7938
7939 * linux-low.c (lwp_is_stepping): New function.
7940
7941 2016-09-06 Carl Love <cel@us.ibm.com>
7942
7943 * server.c (start_inferior): Fixed comment, requested comment change
7944 didn't get updated correctly. Removed reference to ptrace () call as
7945 it is only true on Linux systems.
7946
7947 2016-09-06 Carl Love <cel@us.ibm.com>
7948
7949 * server.c (start_inferior): Do not call
7950 function target_post_create_inferior () if the
7951 inferior process has already exited.
7952
7953 2016-09-05 Pedro Alves <palves@redhat.com>
7954
7955 * Makefile.in (COMPILER, COMPILER_CFLAGS): Remove.
7956 (COMPILE.pre, CC_LD): Use CXX directly.
7957 (INTERNAL_CFLAGS_BASE): Use CXXFLAGS directly.
7958 * acinclude.m4: Don't include build-with-cxx.m4.
7959 * configure.ac: Remove GDB_AC_BUILD_WITH_CXX call.
7960 * configure: Regenerate.
7961
7962 2016-09-02 Akash Trehan <akash.trehan123@gmail.com>
7963
7964 PR gdb/19495
7965 * remote-utils.c (relocate_instruction): Remove redundant strcpy()
7966 call writing data to own_buf.
7967
7968 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
7969
7970 * target.c (mywait): Call target_wait instead of
7971 the_target->wait.
7972 (target_wait): New function.
7973
7974 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
7975
7976 * server.c (start_inferior): New variable 'ptid'. Replace calls
7977 to the_target->resume by target_continue{,_no_signal}, depending
7978 on the case.
7979 * target.c (target_stop_and_wait): Call target_continue_no_signal
7980 instead of the_target->resume.
7981 (target_continue): New function.
7982
7983 2016-08-31 Antoine Tremblay <antoine.tremblay@ericsson.com>
7984
7985 * linux-low.c (linux_wait_1): Move event switch after unsuspend_lwps.
7986
7987 2016-08-25 Adhemerval Zanella <adhemerval.zanella@linaro.org>
7988
7989 PR server/20491
7990 * gdb_proc_service.h (ps_get_thread_area): Remove const from struct
7991 ps_prochandle.
7992 * linux-aarch64-low.c (ps_get_thread_area): Likewise.
7993 * linux-arm-low.c (ps_get_thread_area): Likewise.
7994 * linux-crisv32-low.c (ps_get_thread_area): Likewise.
7995 * linux-m68k-low.c (ps_get_thread_area): Likewise.
7996 * linux-mips-low.c (ps_get_thread_area): Likewise.
7997 * linux-nios2-low.c (ps_get_thread_area): Likewise.
7998 * linux-tic6x-low.c (ps_get_thread_area): Likewise.
7999 * linux-x86-low.c (ps_get_thread_area): Likewise.
8000 * linux-xtensa-low.c (ps_get_thread_area): Likewise.
8001
8002 2016-08-19 Pedro Alves <palves@redhat.com>
8003
8004 * linux-x86-low.c (amd64_emit_call): Emit missing call opcode.
8005
8006 2016-08-19 Pedro Alves <palves@redhat.com>
8007
8008 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Fix
8009 comment. Use memcpy instead of casting through unsigned long.
8010
8011 2016-08-19 Pedro Alves <palves@redhat.com>
8012
8013 * linux-amd64-ipa.c (alloc_jump_pad_buffer) [__ILP32__]: Try
8014 allocating around 0x80000000.
8015
8016 2016-08-19 Pedro Alves <palves@redhat.com>
8017
8018 PR gdb/20415
8019 * Makefile.in (x32-linux-ipa.o, x32-avx-linux-ipa.o)
8020 (x32-avx512-linux-ipa.o): New rules.
8021 * configure.ac (x86_64-*-linux*): New x32 check.
8022 * configure.srv (ipa_x32_linux_regobj): New.
8023 (x86_64-*-linux*): Use $ipa_x32_linux_regobj if building for x32.
8024 * linux-amd64-ipa.c (get_ipa_tdesc) [__ILP32__]: Return x32
8025 descriptions.
8026 (initialize_low_tracepoint) [__ILP32__]: Initialize x32
8027 descriptions.
8028 * configure: Regenerate.
8029
8030 2016-08-09 Pedro Alves <palves@redhat.com>
8031
8032 PR gdb/18653
8033 * Makefile.in (OBS): Add signals-state-save-restore.o.
8034 (signals-state-save-restore.o): New rule.
8035 * config.in: Regenerate.
8036 * configure: Regenerate.
8037 * linux-low.c: Include "signals-state-save-restore.h".
8038 (linux_create_inferior): Call
8039 restore_original_signals_state.
8040 * server.c: Include "dispositions-save-restore.h".
8041 (captured_main): Call save_original_signals_state.
8042
8043 2016-08-05 Pedro Alves <palves@redhat.com>
8044
8045 * configure: Regenerate.
8046
8047 2016-08-04 Yao Qi <yao.qi@linaro.org>
8048
8049 * linux-low.c (regsets_fetch_inferior_registers): Check
8050 errno is ESRCH or not.
8051
8052 2016-08-02 Yao Qi <yao.qi@linaro.org>
8053
8054 * thread-db.c (struct thread_db) <td_ta_event_getmsg_p>: Remove.
8055 <td_ta_set_event_p, td_ta_event_addr_p>: Remove.
8056 (thread_db_load_search): Update.
8057 (try_thread_db_load_1): Don't look for td_ta_event_addr,
8058 td_ta_set_event and td_ta_event_getmsg.
8059
8060 2016-07-26 Pedro Alves <palves@redhat.com>
8061
8062 PR server/20414
8063 * linux-x86-low.c (x86_get_pc, x86_set_pc): Use uint64_t instead
8064 of unsigned long for 64-bit registers and use uint32_t instead of
8065 unsigned int for 32-bit registers.
8066
8067 2016-07-26 Pedro Alves <palves@redhat.com>
8068
8069 * linux-x86-low.c (x86_siginfo_fixup): Rename 'native' parameter
8070 to 'ptrace'.
8071
8072 2016-07-21 Tom Tromey <tom@tromey.com>
8073
8074 * configure: Rebuild.
8075
8076 2016-07-21 Yao Qi <yao.qi@linaro.org>
8077
8078 * mem-break.c (find_gdb_breakpoint): Cast bp to
8079 'struct gdb_breakpoint *' rather than 'gdb_breakpoint *'.
8080
8081 2016-07-21 Yao Qi <yao.qi@linaro.org>
8082
8083 * server.c (handle_v_requests): Support s and S actions
8084 if target_supports_software_single_step return true.
8085
8086 2016-07-21 Yao Qi <yao.qi@linaro.org>
8087
8088 * linux-low.c (resume_stopped_resumed_lwps): If resume request
8089 is resume_step, call maybe_hw_step.
8090 (linux_wait_1): Stop all threads, remove reinsert breakpoints,
8091 and unstop them.
8092 (linux_resume_one_lwp_throw): Don't assert the thread has reinsert
8093 breakpoints or not.
8094 (proceed_one_lwp): If resume request is resume_step, install
8095 reinsert breakpoints and call maybe_hw_step.
8096
8097 2016-07-21 Yao Qi <yao.qi@linaro.org>
8098
8099 * linux-low.c (proceed_one_lwp): Declare.
8100 (linux_resume_one_thread): Remove local variable 'step'.
8101 Lift code enqueue signal. Call proceed_one_lwp instead of
8102 linux_resume_one_lwp.
8103
8104 2016-07-21 Yao Qi <yao.qi@linaro.org>
8105
8106 * linux-low.c (linux_resume_one_thread): Call
8107 enqueue_pending_signal.
8108
8109 2016-07-21 Yao Qi <yao.qi@linaro.org>
8110
8111 * gdbthread.h (make_cleanup_restore_current_thread): Declare.
8112 * inferiors.c (do_restore_current_thread_cleanup): New function.
8113 (make_cleanup_restore_current_thread): Likewise.
8114 * linux-low.c (install_software_single_step_breakpoints): Call
8115 make_cleanup_restore_current_thread. Switch current_thread to
8116 thread.
8117
8118 2016-07-21 Yao Qi <yao.qi@linaro.org>
8119
8120 * mem-break.c (struct reinsert_breakpoint) <ptid>: New field.
8121 (set_reinsert_breakpoint): New parameter ptid. Callers updated.
8122 (clone_one_breakpoint): Likewise.
8123 (delete_reinsert_breakpoints): Change parameter to thread.
8124 Callers updated.
8125 (has_reinsert_breakpoints): Likewise.
8126 (uninsert_reinsert_breakpoints): Likewise.
8127 (reinsert_reinsert_breakpoints): Likewise.
8128 * mem-break.h (set_reinsert_breakpoint): Update declaration.
8129 (delete_reinsert_breakpoints): Likewise.
8130 (reinsert_reinsert_breakpoints): Likewise.
8131 (uninsert_reinsert_breakpoints): Likewise.
8132 (has_reinsert_breakpoints): Likewise.
8133
8134 2016-07-21 Yao Qi <yao.qi@linaro.org>
8135
8136 * inferiors.c (get_thread_process): Make parameter const.
8137 * inferiors.h (get_thread_process): Update declaration.
8138 * mem-break.c (clone_all_breakpoints): Remove all parameters.
8139 Add new parameters child_thread and parent_thread. Callers
8140 updated.
8141 * mem-break.h (clone_all_breakpoints): Update declaration.
8142
8143 2016-07-21 Yao Qi <yao.qi@linaro.org>
8144
8145 * mem-break.c (struct breakpoint) <cond_list>: Remove.
8146 <command_list, handler>: Remove.
8147 (struct gdb_breakpoint): New.
8148 (struct other_breakpoint): New.
8149 (struct reinsert_breakpoint): New.
8150 (is_gdb_breakpoint): New function.
8151 (any_persistent_commands): Update command_list if
8152 is_gdb_breakpoint returns true.
8153 (set_breakpoint): Create breakpoints according to their types.
8154 (find_gdb_breakpoint): Return 'struct gdb_breakpoint *'.
8155 (set_gdb_breakpoint_1): Likewise.
8156 (set_gdb_breakpoint): Likewise.
8157 (clear_breakpoint_conditions): Change parameter type to
8158 'struct gdb_breakpoint *'.
8159 (clear_breakpoint_commands): Likewise.
8160 (clear_breakpoint_conditions_and_commands): Likewise.
8161 (add_condition_to_breakpoint): Likewise.
8162 (add_breakpoint_condition): Likewise.
8163 (add_commands_to_breakpoint): Likewise.
8164 (check_breakpoints): Check other_breakpoint.
8165 (clone_one_breakpoint): Clone breakpopint according to its type.
8166 * mem-break.h (struct gdb_breakpoint): Declare.
8167 (set_gdb_breakpoint): Update declaration.
8168 (clear_breakpoint_conditions_and_commands): Likewise.
8169 (add_breakpoint_condition): Likewise.
8170 (add_breakpoint_commands): Likewise.
8171 * server.c (process_point_options): Change parameter type to
8172 'struct gdb_breakpoint *'.
8173
8174 2016-07-21 Yao Qi <yao.qi@linaro.org>
8175
8176 * mem-break.c (set_breakpoint_at): Rename it to ...
8177 (set_breakpoint_type_at): ... it.
8178 (set_breakpoint_at): Call set_breakpoint_type_at.
8179 (set_reinsert_breakpoint): Call set_breakpoint_type_at.
8180 * mem-break.h (set_breakpoint_at): Update comments.
8181
8182 2016-07-12 Chung-Lin Tang <cltang@codesourcery.com>
8183
8184 * linux-nios2-low.c (nios2_fill_gregset): Add type cast
8185 to buf parameter.
8186 (nios2_store_gregset): Likewise.
8187
8188 2016-07-01 Pedro Alves <palves@redhat.com>
8189 Antoine Tremblay <antoine.tremblay@ericsson.com>
8190
8191 * linux-low.c: Change interface to take the target lwp_info
8192 pointer directly and return void. Handle detaching from a zombie
8193 thread.
8194 (linux_detach_lwp_callback): New function.
8195 (linux_detach): Detach from the leader thread after detaching from
8196 the clone threads.
8197
8198 2016-06-28 Yao Qi <yao.qi@linaro.org>
8199
8200 * linux-aarch64-low.c (aarch64_ftrace_insn_reloc_b): Use int64_t
8201 for variable new_offset.
8202 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
8203 (aarch64_ftrace_insn_reloc_cb): Likewise.
8204 (aarch64_ftrace_insn_reloc_tb): Likewise.
8205 (aarch64_install_fast_tracepoint_jump_pad): Likewise. Use
8206 PRIx64 instead of PRIx32.
8207
8208 2016-06-28 Yao Qi <yao.qi@linaro.org>
8209
8210 * linux-arm-low.c (arm_get_syscall_trapinfo): New function.
8211 (the_low_target): Install arm_get_syscall_trapinfo.
8212
8213 2016-06-28 Yao Qi <yao.qi@linaro.org>
8214
8215 * linux-aarch64-low.c (aarch64_get_syscall_trapinfo): New
8216 function.
8217 (the_low_target): Install aarch64_get_syscall_trapinfo.
8218
8219 2016-06-28 Yao Qi <yao.qi@linaro.org>
8220
8221 * linux-low.c (get_syscall_trapinfo): Remove parameter sysret.
8222 Callers updated.
8223 * linux-low.h (struct linux_target_ops) <get_syscall_trapinfo>:
8224 Remove parameter sysno.
8225 * linux-x86-low.c (x86_get_syscall_trapinfo): Remove parameter
8226 sysret.
8227
8228 2016-06-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
8229
8230 * linux-s390-low.c (s390_emit_eq_goto): Mark function static.
8231 (s390_emit_ne_goto): Likewise.
8232 (s390_emit_lt_goto): Likewise.
8233 (s390_emit_le_goto): Likewise.
8234 (s390_emit_gt_goto): Likewise.
8235 (s390_emit_ge_goto): Likewise.
8236 (s390x_emit_eq_goto): Likewise.
8237 (s390x_emit_ne_goto): Likewise.
8238 (s390x_emit_lt_goto): Likewise.
8239 (s390x_emit_le_goto): Likewise.
8240 (s390x_emit_gt_goto): Likewise.
8241 (s390x_emit_ge_goto): Likewise.
8242 (s390_emit_ops_impl): Mark variable static.
8243 (s390x_emit_ops): Likewise.
8244
8245 2016-06-17 Yao Qi <yao.qi@linaro.org>
8246
8247 * linux-low.c (handle_extended_wait): Call
8248 uninsert_reinsert_breakpoints for the parent process. Remove
8249 reinsert breakpoints from the child process. Reinsert them to
8250 the parent process when vfork is done.
8251 * mem-break.c (uninsert_reinsert_breakpoints): New function.
8252 (reinsert_reinsert_breakpoints): New function.
8253 * mem-break.h (uninsert_reinsert_breakpoints): Declare
8254 (reinsert_reinsert_breakpoints): Declare.
8255
8256 2016-06-17 Yao Qi <yao.qi@linaro.org>
8257
8258 * linux-low.c (handle_extended_wait): If the parent is doing
8259 step-over, remove the reinsert breakpoints from the forked child.
8260
8261 2016-06-17 Yao Qi <yao.qi@linaro.org>
8262
8263 * linux-low.c (unsuspend_all_lwps): Declare.
8264 (linux_low_filter_event): If thread exited, call finish_step_over.
8265 If step-over is finished, unsuspend other threads.
8266
8267 2016-06-17 Yao Qi <yao.qi@linaro.org>
8268
8269 * linux-low.c (linux_resume_one_lwp_throw): Assert
8270 has_reinsert_breakpoints returns false.
8271 * mem-break.c (delete_disabled_breakpoints): Assert
8272 bp type isn't reinsert_breakpoint.
8273
8274 2016-06-17 Yao Qi <yao.qi@linaro.org>
8275
8276 * linux-low.c (maybe_hw_step): New function.
8277 (linux_resume_one_lwp_throw): Call maybe_hw_step.
8278 (finish_step_over): Switch current_thread to lwp temporarily,
8279 and assert has_reinsert_breakpoints returns true.
8280 (proceed_one_lwp): Call maybe_hw_step.
8281 * mem-break.c (has_reinsert_breakpoints): New function.
8282 * mem-break.h (has_reinsert_breakpoints): Declare.
8283
8284 2016-06-02 Jon Turney <jon.turney@dronecode.org.uk>
8285
8286 * win32-low.c (win32_create_inferior): Add pointer casts for C++.
8287
8288 2016-05-17 Yao Qi <yao.qi@linaro.org>
8289
8290 * linux-low.c (linux_stabilize_threads): Call unsuspend_all_lwps
8291 instead of find_inferior.
8292
8293 2016-05-05 Yao Qi <yao.qi@linaro.org>
8294
8295 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer):
8296 Initialize res to zero.
8297
8298 2016-05-05 Yao Qi <yao.qi@linaro.org>
8299
8300 * linux-arm-low.c (arm_sigreturn_next_pc): Change type of cpsr
8301 to uint32_t.
8302
8303 2016-05-04 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
8304
8305 * spu-low.c (fetch_ppc_register): Cast PowerPC-Linux-specific value
8306 used as first ptrace argument to PTRACE_TYPE_ARG1 for C++.
8307 (fetch_ppc_memory_1, store_ppc_memory_1): Likewise.
8308
8309 2016-04-28 Par Olsson <par.olsson@windriver.com>
8310 Simon Marchi <simon.marchi@ericsson.com>
8311
8312 * tracepoint.c (write_inferior_int8): New function.
8313 (cmd_qtenable_disable): Write enable flag using
8314 write_inferior_int8.
8315
8316 2016-04-25 Yao Qi <yao.qi@linaro.org>
8317
8318 * linux-low.c (lwp_signal_can_be_delivered): Adjust.
8319 (need_step_over_p): Return zero if the LWP has pending signals
8320 can be delivered on software single step target.
8321
8322 2016-04-25 Yao Qi <yao.qi@linaro.org>
8323
8324 * linux-low.c (reinsert_raw_breakpoint): If bp->inserted is true
8325 return instead of error.
8326
8327 2016-04-22 Yao Qi <yao.qi@linaro.org>
8328
8329 * linux-aarch32-low.c (arm_store_gregset): Clear CPSR bits 20
8330 to 23.
8331
8332 2016-04-22 Yao Qi <yao.qi@linaro.org>
8333
8334 * linux-low.c (lwp_signal_can_be_delivered): Don't deliver
8335 signal when stepping over breakpoint with software single
8336 step.
8337
8338 2016-04-21 Pedro Alves <palves@redhat.com>
8339
8340 * linux-s390-low.c (s390_collect_ptrace_register)
8341 (s390_supply_ptrace_register, s390_get_hwcap): Use gdb_byte * and
8342 add casts.
8343 (s390_check_regset): Use void * instead of gdb_byte *.
8344
8345 2016-04-20 Pedro Alves <palves@redhat.com>
8346
8347 * configure: Renegerate.
8348
8349 2016-04-20 Yao Qi <yao.qi@linaro.org>
8350
8351 * linux-aarch32-low.c: Include "arch/arm-linux.h".
8352 (arm_fill_gregset): Use ARM_CPSR_GREGNUM rather than magic
8353 number 16.
8354 (arm_store_gregset): Likewise.
8355
8356 2016-04-16 Walfred Tedeschi <walfred.tedeschi@intel.com>
8357
8358 * Makefile.in (clean): Add removal for i386-avx-mpx.c,
8359 i386-avx-mpx-linux.c, amd64-avx-mpx.c and amd64-avx-mpx-linux.c.
8360 (i386-avx-mpx.c, i386-avx-mpx-linux.c, amd64-avx-mpx.c)
8361 (amd64-avx-mpx-linux.c): New rules.
8362 (amd64-avx-mpx-linux-ipa.o, i386-avx-mpx-linux-ipa.o): New rule.
8363 * configure.srv (srv_i386_regobj): Add i386-avx-mpx.o.
8364 (srv_i386_linux_regobj): Add i386-avx-mpx-linux.o.
8365 (srv_amd64_regobj): Add amd64-avx-mpx.o.
8366 (srv_amd64_linux_regobj): Add amd64-avx-mpx-linux.o.
8367 (srv_i386_xmlfiles): Add i386/i386-avx-mpx.xml.
8368 (srv_amd64_xmlfiles): Add i386/amd64-avx-mpx.xml.
8369 (srv_i386_linux_xmlfiles): Add i386/i386-avx-mpx-linux.xml.
8370 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-mpx-linux.xml.
8371 (ipa_i386_linux_regobj): Add i386-avx-mpx-linux-ipa.o.
8372 (ipa_amd64_linux_regobj): Add amd64-avx-mpx-linux-ipa.o.
8373 * linux-x86-low.c (x86_linux_read_description): Add case for
8374 X86_XSTATE_AVX_MPX_MASK.
8375 (x86_get_ipa_tdesc_idx): Add cases for avx_mpx.
8376 (initialize_low_arch): Call init_registers_amd64_avx_mpx_linux and
8377 init_registers_i386_avx_mpx_linux.
8378 * linux-i386-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
8379 (initialize_low_tracepoint): Call
8380 init_registers_i386_avx_mpx_linux.
8381 * linux-amd64-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
8382 (initialize_low_tracepoint): Call
8383 init_registers_amd64_avx_mpx_linux.
8384 * linux-x86-tdesc.h (X86_TDESC_AVX_MPX): New enum value.
8385 (init_registers_amd64_avx_mpx_linux, tdesc_amd64_avx_mpx_linux)
8386 (init_registers_i386_avx_mpx_linux, tdesc_i386_avx_mpx_linux): New
8387 declarations.
8388
8389 2016-04-18 Pedro Alves <palves@redhat.com>
8390
8391 * configure: Regenerate.
8392
8393 2016-04-13 Antoine Tremblay <antoine.tremblay@ericsson.com>
8394
8395 * linux-aarch64-low.c (aarch64_emit_add): Switch x1 and x0.
8396 (aarch64_emit_sub): Likewise.
8397
8398 2016-04-12 Pedro Alves <palves@redhat.com>
8399
8400 * utils.c (prepare_to_throw_exception): Delete.
8401
8402 2016-04-05 Simon Marchi <simon.marchi@ericsson.com>
8403
8404 * Makefile.in ($(IPA_LIB)): Set SONAME of the IPA lib.
8405
8406 2016-04-05 Marcin Kościelnicki <koriakin@0x04.net>
8407
8408 * tracepoint.c (getauxval): Move to #ifdef IN_PROCESS_AGENT.
8409
8410 2016-04-03 Marcin Kościelnicki <koriakin@0x04.net>
8411
8412 * linux-aarch64-ipa.c: Add <elf.h> include.
8413 * linux-ppc-ipa.c: Add <elf.h> include.
8414 * linux-s390-ipa.c: Add <elf.h> include.
8415
8416 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
8417
8418 * tracepoint.c (gdb_collect_ptr): Remove const qualifier.
8419 (get_raw_reg_ptr): Likewise.
8420 (get_trace_state_variable_value_ptr): Likewise.
8421 (set_trace_state_variable_value_ptr): Likewise.
8422 (initialize_tracepoint): Cast alloc_jump_pad_buffer result to
8423 char *.
8424
8425 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
8426 Marcin Kościelnicki <koriakin@0x04.net>
8427
8428 PR/17221
8429 * linux-ppc-low.c (emit_insns): New function.
8430 (__EMIT_ASM, _EMIT_ASM, EMIT_ASM): New macros.
8431 (ppc_emit_prologue): New function.
8432 (ppc_emit_epilogue): New function.
8433 (ppc_emit_add): New function.
8434 (ppc_emit_sub): New function.
8435 (ppc_emit_mul): New function.
8436 (ppc_emit_lsh): New function.
8437 (ppc_emit_rsh_signed): New function.
8438 (ppc_emit_rsh_unsigned): New function.
8439 (ppc_emit_ext): New function.
8440 (ppc_emit_zero_ext): New function.
8441 (ppc_emit_log_not): New function.
8442 (ppc_emit_bit_and): New function.
8443 (ppc_emit_bit_or): New function.
8444 (ppc_emit_bit_xor): New function.
8445 (ppc_emit_bit_not): New function.
8446 (ppc_emit_equal): New function.
8447 (ppc_emit_less_signed): New function.
8448 (ppc_emit_less_unsigned): New function.
8449 (ppc_emit_ref): New function.
8450 (ppc_emit_const): New function.
8451 (ppc_emit_reg): New function.
8452 (ppc_emit_pop): New function.
8453 (ppc_emit_stack_flush): New function.
8454 (ppc_emit_swap): New function.
8455 (ppc_emit_stack_adjust): New function.
8456 (ppc_emit_call): New function.
8457 (ppc_emit_int_call_1): New function.
8458 (ppc_emit_void_call_2): New function.
8459 (ppc_emit_if_goto): New function.
8460 (ppc_emit_goto): New function.
8461 (ppc_emit_eq_goto): New function.
8462 (ppc_emit_ne_goto): New function.
8463 (ppc_emit_lt_goto): New function.
8464 (ppc_emit_le_goto): New function.
8465 (ppc_emit_gt_goto): New function.
8466 (ppc_emit_ge_goto): New function.
8467 (ppc_write_goto_address): New function.
8468 (ppc_emit_ops_impl): New static variable.
8469 (ppc64v1_emit_prologue): New function.
8470 (ppc64v2_emit_prologue): New function.
8471 (ppc64_emit_epilogue): New function.
8472 (ppc64_emit_add): New function.
8473 (ppc64_emit_sub): New function.
8474 (ppc64_emit_mul): New function.
8475 (ppc64_emit_lsh): New function.
8476 (ppc64_emit_rsh_signed): New function.
8477 (ppc64_emit_rsh_unsigned): New function.
8478 (ppc64_emit_ext): New function.
8479 (ppc64_emit_zero_ext): New function.
8480 (ppc64_emit_log_not): New function.
8481 (ppc64_emit_bit_and): New function.
8482 (ppc64_emit_bit_or): New function.
8483 (ppc64_emit_bit_xor): New function.
8484 (ppc64_emit_bit_not): New function.
8485 (ppc64_emit_equal): New function.
8486 (ppc64_emit_less_signed): New function.
8487 (ppc64_emit_less_unsigned): New function.
8488 (ppc64_emit_ref): New function.
8489 (ppc64_emit_const): New function.
8490 (ppc64v1_emit_reg): New function.
8491 (ppc64v2_emit_reg): New function.
8492 (ppc64_emit_pop): New function.
8493 (ppc64_emit_stack_flush): New function.
8494 (ppc64_emit_swap): New function.
8495 (ppc64v1_emit_call): New function.
8496 (ppc64v2_emit_call): New function.
8497 (ppc64v1_emit_int_call_1): New function.
8498 (ppc64v2_emit_int_call_1): New function.
8499 (ppc64v1_emit_void_call_2): New function.
8500 (ppc64v2_emit_void_call_2): New function.
8501 (ppc64_emit_if_goto): New function.
8502 (ppc64_emit_eq_goto): New function.
8503 (ppc64_emit_ne_goto): New function.
8504 (ppc64_emit_lt_goto): New function.
8505 (ppc64_emit_le_goto): New function.
8506 (ppc64_emit_gt_goto): New function.
8507 (ppc64_emit_ge_goto): New function.
8508 (ppc64v1_emit_ops_impl): New static variable.
8509 (ppc64v2_emit_ops_impl): New static variable.
8510 (ppc_emit_ops): New function.
8511 (linux_low_target): Wire in ppc_emit_ops.
8512
8513 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
8514 Marcin Kościelnicki <koriakin@0x04.net>
8515
8516 PR/17221
8517 * Makefile.in: Add powerpc-*-ipa.o
8518 * configure.srv: Add ipa_obj for powerpc*-linux.
8519 * linux-ppc-ipa.c: New file.
8520 * linux-ppc-low.c: Added linux-ppc-tdesc.h, ax.h, tracepoint.h
8521 includes.
8522 (PPC_FIELD): New macro.
8523 (PPC_SEXT): New macro.
8524 (PPC_OP6): New macro.
8525 (PPC_BO): New macro.
8526 (PPC_LI): New macro.
8527 (PPC_BD): New macro.
8528 (init_registers_*): Move prototype to linux-ppc-tdesc.h.
8529 (tdesc_*): Move declaration to linux-ppc-tdesc.h.
8530 (ppc_get_hwcap): Rename to ppc_get_auxv and add type parameter.
8531 (ppc_get_thread_area): New function.
8532 (is_elfv2_inferior): New function.
8533 (gen_ds_form): New function.
8534 (GEN_STD): New macro.
8535 (GEN_STDU): New macro.
8536 (GEN_LD): New macro.
8537 (GEN_LDU): New macro.
8538 (gen_d_form): New function.
8539 (GEN_ADDI): New macro.
8540 (GEN_ADDIS): New macro.
8541 (GEN_LI): New macro.
8542 (GEN_LIS): New macro.
8543 (GEN_ORI): New macro.
8544 (GEN_ORIS): New macro.
8545 (GEN_LWZ): New macro.
8546 (GEN_STW): New macro.
8547 (GEN_STWU): New macro.
8548 (gen_xfx_form): New function.
8549 (GEN_MFSPR): New macro.
8550 (GEN_MTSPR): New macro.
8551 (GEN_MFCR): New macro.
8552 (GEN_MTCR): New macro.
8553 (GEN_SYNC): New macro.
8554 (GEN_LWSYNC): New macro.
8555 (gen_x_form): New function.
8556 (GEN_OR): New macro.
8557 (GEN_MR): New macro.
8558 (GEN_LWARX): New macro.
8559 (GEN_STWCX): New macro.
8560 (GEN_CMPW): New macro.
8561 (gen_md_form): New function.
8562 (GEN_RLDICL): New macro.
8563 (GEN_RLDICR): New macro.
8564 (gen_i_form): New function.
8565 (GEN_B): New macro.
8566 (GEN_BL): New macro.
8567 (gen_b_form): New function.
8568 (GEN_BNE): New macro.
8569 (GEN_LOAD): New macro.
8570 (GEN_STORE): New macro.
8571 (gen_limm): New function.
8572 (gen_atomic_xchg): New function.
8573 (gen_call): New function.
8574 (ppc_relocate_instruction): New function.
8575 (ppc_install_fast_tracepoint_jump_pad): New function.
8576 (ppc_get_min_fast_tracepoint_insn_len): New function.
8577 (ppc_get_ipa_tdesc_idx): New function.
8578 (the_low_target): Wire in the new functions.
8579 (initialize_low_arch) [!__powerpc64__]: Don'it initialize 64-bit
8580 tdescs.
8581 * linux-ppc-tdesc.h: New file.
8582
8583 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
8584
8585 * linux-aarch64-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
8586 (alloc_jump_pad_buffer): New function.
8587 * linux-amd64-ipa.c: Add <sys/mman.h> include.
8588 (alloc_jump_pad_buffer): New function.
8589 * linux-i386-ipa.c (alloc_jump_pad_buffer): New function.
8590 * linux-s390-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
8591 (alloc_jump_pad_buffer): New function.
8592 * tracepoint.c (getauxval) [!HAVE_GETAUXVAL]: New function.
8593 (initialize_tracepoint): Delegate to alloc_jump_pad_buffer.
8594 * tracepoint.h (alloc_jump_pad_buffer): New prototype.
8595 (getauxval) [!HAVE_GETAUXVAL]: New prototype.
8596
8597 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
8598
8599 * linux-aarch64-ipa.c: Rename gdb_agent_get_raw_reg to get_raw_reg.
8600 * linux-amd64-ipa.c: Likewise.
8601 * linux-i386-ipa.c: Likewise.
8602 * linux-s390-ipa.c: Likewise.
8603 * tracepoint.c: IPA-export gdb_collect_ptr instead of gdb_collect,
8604 ditto for get_raw_reg_ptr, get_trace_state_variable_value_ptr,
8605 set_trace_state_variable_value_ptr.
8606 (struct ipa_sym_addresses): Likewise.
8607 (symbol_list): Likewise.
8608 (install_fast_tracepoint): Dereference gdb_collect_ptr instead of
8609 accessing gdb_collect directly.
8610 (gdb_collect_ptr_type): New typedef.
8611 (get_raw_reg_ptr_type): New typedef.
8612 (get_trace_state_variable_value_ptr_type): New typedef.
8613 (set_trace_state_variable_value_ptr_type): New typedef.
8614 (gdb_collect_ptr): New global.
8615 (get_raw_reg_ptr): New global.
8616 (get_trace_state_variable_value_ptr): New global.
8617 (set_trace_state_variable_value_ptr): New global.
8618 (get_raw_reg_func_addr): Dereference get_raw_reg_ptr instead of
8619 accessing get_raw_reg directly.
8620 (get_get_tsv_func_addr): Likewise for
8621 get_trace_state_variable_value_ptr.
8622 (get_set_tsv_func_addr): Likewise for
8623 set_trace_state_variable_value_ptr.
8624 * tracepoint.h: Rename gdb_agent_get_raw_reg to get_raw_reg.
8625
8626 2016-03-30 Simon Marchi <simon.marchi@ericsson.com>
8627
8628 * tracepoint.c (cmd_qtenable_disable): Remove whitespace.
8629
8630 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
8631
8632 * remote-utils.c (look_up_one_symbol): Remove own_buf, handle 'v'
8633 packets.
8634 (relocate_instruction): Remove own_buf.
8635 * server.c (own_buf): Make global.
8636 (handle_v_requests): Make global.
8637 * server.h (own_buf): New declaration.
8638 (handle_v_requests): New prototype.
8639
8640 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
8641
8642 PR 18377
8643 * linux-s390-low.c (add_insns): New function.
8644 (s390_emit_prologue): New function.
8645 (s390_emit_epilogue): New function.
8646 (s390_emit_add): New function.
8647 (s390_emit_sub): New function.
8648 (s390_emit_mul): New function.
8649 (s390_emit_lsh): New function.
8650 (s390_emit_rsh_signed): New function.
8651 (s390_emit_rsh_unsigned): New function.
8652 (s390_emit_ext): New function.
8653 (s390_emit_log_not): New function.
8654 (s390_emit_bit_and): New function.
8655 (s390_emit_bit_or): New function.
8656 (s390_emit_bit_xor): New function.
8657 (s390_emit_bit_not): New function.
8658 (s390_emit_equal): New function.
8659 (s390_emit_less_signed): New function.
8660 (s390_emit_less_unsigned): New function.
8661 (s390_emit_ref): New function.
8662 (s390_emit_if_goto): New function.
8663 (s390_emit_goto): New function.
8664 (s390_write_goto_address): New function.
8665 (s390_emit_litpool): New function.
8666 (s390_emit_const): New function.
8667 (s390_emit_call): New function.
8668 (s390_emit_reg): New function.
8669 (s390_emit_pop): New function.
8670 (s390_emit_stack_flush): New function.
8671 (s390_emit_zero_ext): New function.
8672 (s390_emit_swap): New function.
8673 (s390_emit_stack_adjust): New function.
8674 (s390_emit_set_r2): New function.
8675 (s390_emit_int_call_1): New function.
8676 (s390_emit_void_call_2): New function.
8677 (s390_emit_eq_goto): New function.
8678 (s390_emit_ne_goto): New function.
8679 (s390_emit_lt_goto): New function.
8680 (s390_emit_le_goto): New function.
8681 (s390_emit_gt_goto): New function.
8682 (s390_emit_ge_goto): New function.
8683 (s390x_emit_prologue): New function.
8684 (s390x_emit_epilogue): New function.
8685 (s390x_emit_add): New function.
8686 (s390x_emit_sub): New function.
8687 (s390x_emit_mul): New function.
8688 (s390x_emit_lsh): New function.
8689 (s390x_emit_rsh_signed): New function.
8690 (s390x_emit_rsh_unsigned): New function.
8691 (s390x_emit_ext): New function.
8692 (s390x_emit_log_not): New function.
8693 (s390x_emit_bit_and): New function.
8694 (s390x_emit_bit_or): New function.
8695 (s390x_emit_bit_xor): New function.
8696 (s390x_emit_bit_not): New function.
8697 (s390x_emit_equal): New function.
8698 (s390x_emit_less_signed): New function.
8699 (s390x_emit_less_unsigned): New function.
8700 (s390x_emit_ref): New function.
8701 (s390x_emit_if_goto): New function.
8702 (s390x_emit_const): New function.
8703 (s390x_emit_call): New function.
8704 (s390x_emit_reg): New function.
8705 (s390x_emit_pop): New function.
8706 (s390x_emit_stack_flush): New function.
8707 (s390x_emit_zero_ext): New function.
8708 (s390x_emit_swap): New function.
8709 (s390x_emit_stack_adjust): New function.
8710 (s390x_emit_int_call_1): New function.
8711 (s390x_emit_void_call_2): New function.
8712 (s390x_emit_eq_goto): New function.
8713 (s390x_emit_ne_goto): New function.
8714 (s390x_emit_lt_goto): New function.
8715 (s390x_emit_le_goto): New function.
8716 (s390x_emit_gt_goto): New function.
8717 (s390x_emit_ge_goto): New function.
8718 (s390_emit_ops): New function.
8719 (struct linux_target_ops): Fill in emit_ops hook.
8720
8721 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
8722
8723 PR 18377
8724 * Makefile.in: Add s390 IPA files.
8725 * configure.srv: Build IPA for s390.
8726 * linux-s390-ipa.c: New file.
8727 * linux-s390-low.c: New includes - inttypes.h and linux-s390-tdesc.h.
8728 (init_registers_s390_linux32): Move declaration to linux-s390-tdesc.h.
8729 (tdesc_s390_linux32): Likewise.
8730 (init_registers_s390_linux32v1): Likewise.
8731 (tdesc_s390_linux32v1): Likewise.
8732 (init_registers_s390_linux32v2): Likewise.
8733 (tdesc_s390_linux32v2): Likewise.
8734 (init_registers_s390_linux64): Likewise.
8735 (tdesc_s390_linux64): Likewise.
8736 (init_registers_s390_linux64v1): Likewise.
8737 (tdesc_s390_linux64v1): Likewise.
8738 (init_registers_s390_linux64v2): Likewise.
8739 (tdesc_s390_linux64v2): Likewise.
8740 (init_registers_s390_te_linux64): Likewise.
8741 (tdesc_s390_te_linux64): Likewise.
8742 (init_registers_s390_vx_linux64): Likewise.
8743 (tdesc_s390_vx_linux64): Likewise.
8744 (init_registers_s390_tevx_linux64): Likewise.
8745 (tdesc_s390_tevx_linux64): Likewise.
8746 (init_registers_s390x_linux64): Likewise.
8747 (tdesc_s390x_linux64): Likewise.
8748 (init_registers_s390x_linux64v1): Likewise.
8749 (tdesc_s390x_linux64v1): Likewise.
8750 (init_registers_s390x_linux64v2): Likewise.
8751 (tdesc_s390x_linux64v2): Likewise.
8752 (init_registers_s390x_te_linux64): Likewise.
8753 (tdesc_s390x_te_linux64): Likewise.
8754 (init_registers_s390x_vx_linux64): Likewise.
8755 (tdesc_s390x_vx_linux64): Likewise.
8756 (init_registers_s390x_tevx_linux64): Likewise.
8757 (tdesc_s390x_tevx_linux64): Likewise.
8758 (have_hwcap_s390_vx): New static variable.
8759 (s390_arch_setup): Fill have_hwcap_s390_vx.
8760 (s390_get_thread_area): New function.
8761 (s390_ft_entry_gpr_esa): New const.
8762 (s390_ft_entry_gpr_zarch): New const.
8763 (s390_ft_entry_misc): New const.
8764 (s390_ft_entry_fr): New const.
8765 (s390_ft_entry_vr): New const.
8766 (s390_ft_main_31): New const.
8767 (s390_ft_main_64): New const.
8768 (s390_ft_exit_fr): New const.
8769 (s390_ft_exit_vr): New const.
8770 (s390_ft_exit_misc): New const.
8771 (s390_ft_exit_gpr_esa): New const.
8772 (s390_ft_exit_gpr_zarch): New const.
8773 (append_insns): New function.
8774 (s390_relocate_instruction): New function.
8775 (s390_install_fast_tracepoint_jump_pad): New function.
8776 (s390_get_min_fast_tracepoint_insn_len): New function.
8777 (s390_get_ipa_tdesc_idx): New function.
8778 (struct linux_target_ops): Wire in the above functions.
8779 (initialize_low_arch) [!__s390x__]: Don't initialize s390x tdescs.
8780 * linux-s390-tdesc.h: New file.
8781
8782 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
8783
8784 * linux-s390-low.c (s390_supports_tracepoints): New function.
8785 (struct linux_target_ops): Fill supports_tracepoints hook.
8786
8787 2016-03-18 Yao Qi <yao.qi@linaro.org>
8788
8789 * linux-low.c (lwp_signal_can_be_delivered): New function.
8790 (linux_resume_one_lwp_throw): Use lwp_signal_can_be_delivered.
8791
8792 2016-03-18 Yao Qi <yao.qi@linaro.org>
8793
8794 * linux-low.c (linux_resume_one_lwp_throw): Set 'signal' to
8795 0 if signal is enqueued. Remove 'signal' from one debugging
8796 message. Move one debugging message to some lines below.
8797 Remove code setting 'signal' to 0.
8798
8799 2016-03-18 Yao Qi <yao.qi@linaro.org>
8800
8801 * linux-low.c (linux_low_filter_event): Remove redundant
8802 WIFSTOPPED check together with linux_wstatus_maybe_breakpoint.
8803
8804 2016-03-09 Marcin Kościelnicki <koriakin@0x04.net>
8805
8806 * linux-ppc-low.c (ppc_supports_tracepoints): New function.
8807 (struct linux_target_ops): Wire in the above.
8808
8809 2016-03-03 Yao Qi <yao.qi@linaro.org>
8810
8811 * linux-low.c: Update comments to start_step_over.
8812
8813 2016-03-03 Yao Qi <yao.qi@linaro.org>
8814
8815 PR server/19736
8816 * linux-low.c (handle_extended_wait): Set child suspended
8817 if event_lwp->bp_reinsert isn't zero.
8818
8819 2016-03-02 Yao Qi <yao.qi@linaro.org>
8820
8821 * linux-low.c (linux_resume_one_lwp_throw): Replace code with
8822 enqueue_pending_signal.
8823
8824 2016-03-02 Marcin Kościelnicki <koriakin@0x04.net>
8825
8826 * tracepoint.c (cmd_qtstart): Only set ipa_tdesc_idx if agent
8827 is actually loaded.
8828
8829 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
8830
8831 * linux-s390-low.c (s390_num_regs_3264): Define on 31-bit too.
8832 (s390_regmap_3264) [!__s390x__]: New global.
8833 (s390_collect_ptrace_register): Skip map entries containing -1.
8834 (s390_supply_ptrace_register): Ditto.
8835 (s390_fill_gprs_high): New function.
8836 (s390_store_gprs_high): New function.
8837 (s390_regsets): Add NT_S390_HIGH_GPRS.
8838 (s390_get_hwcap): Enable on 31-bit.
8839 (have_hwcap_s390_high_gprs): Enable on 31-bit.
8840 (s390_arch_setup): Enable detection of high GPRs, TDB, VX on 31-bit.
8841 Detect NT_S390_HIGH_GPRS.
8842 (s390_usrregs_info_3264): Enable on 31-bit.
8843 (s390_regs_info): Enable regs_info_3264 on 31-bit.
8844 (initialize_low_arch): Initialize s390_regsets_info_3264 on 31-bit.
8845
8846 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
8847
8848 PR gdb/13808
8849 * Makefile.in: Add i386-*-linux-ipa.o and amd64-*-linux-ipa.o.
8850 * configure.srv: Ditto.
8851 * linux-aarch64-ipa.c (get_ipa_tdesc): New function.
8852 (initialize_low_tracepoint): Remove ipa_tdesc assignment.
8853 * linux-amd64-ipa.c: Add "linux-x86-tdesc.h" include.
8854 (init_registers_amd64_linux): Remove prototype.
8855 (tdesc_amd64_linux): Remove declaration.
8856 (get_ipa_tdesc): New function.
8857 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
8858 initialize remaining tdescs.
8859 * linux-i386-ipa.c: Add "linux-x86-tdesc.h" include.
8860 (init_registers_i386_linux): Remove prototype.
8861 (tdesc_i386_linux): Remove declaration.
8862 (get_ipa_tdesc): New function.
8863 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
8864 initialize remaining tdescs.
8865 * linux-low.c (linux_get_ipa_tdesc_idx): New function.
8866 (linux_target_ops): wire in linux_get_ipa_tdesc_idx.
8867 * linux-low.h (struct linux_target_ops): Add get_ipa_tdesc_idx.
8868 * linux-x86-low.c: Move tdesc declarations to linux-x86-tdesc.h.
8869 (x86_get_ipa_tdesc_idx): New function.
8870 (the_low_target): Wire in x86_get_ipa_tdesc_idx.
8871 * linux-x86-tdesc.h: New file.
8872 * target.h (struct target_ops): Add get_ipa_tdesc_idx.
8873 (target_get_ipa_tdesc_idx): New macro.
8874 * tracepoint.c (ipa_tdesc_idx): New macro.
8875 (struct ipa_sym_addresses): Add addr_ipa_tdesc_idx.
8876 (symbol_list): Add ipa_tdesc_idx.
8877 (cmd_qtstart): Write ipa_tdesc_idx in the target.
8878 (ipa_tdesc): Remove.
8879 (ipa_tdesc_idx): New variable.
8880 (get_context_regcache): Use get_ipa_tdesc.
8881 (gdb_collect): Ditto.
8882 (gdb_probe): Ditto.
8883 * tracepoint.h (get_ipa_tdesc): New prototype.
8884 (ipa_tdesc): Remove.
8885
8886 2016-02-24 Pedro Alves <palves@redhat.com>
8887
8888 * linux-low.c (check_stopped_by_breakpoint): Rename to ...
8889 (save_stop_reason): ... this. Use GDB_ARCH_IS_TRAP_HWBKPT and
8890 handle ambiguous GDB_ARCH_IS_TRAP_BRKPT / GDB_ARCH_IS_TRAP_HWBKPT.
8891 Factor out common code between the USE_SIGTRAP_SIGINFO and
8892 !USE_SIGTRAP_SIGINFO blocks.
8893 (linux_low_filter_event): Call save_stop_reason instead of
8894 check_stopped_by_breakpoint and check_stopped_by_watchpoint.
8895 Update comments.
8896 (linux_wait_1): Update comments.
8897
8898 2016-02-24 Wei-cheng Wang <cole945@gmail.com>
8899
8900 * linux-ppc-low.c (ppc_supports_z_point_type): New function:
8901 (ppc_insert_point, ppc_remove_point): Insert/remove z-packet breakpoints.
8902 (ppc64_emit_ops_vector): Add target ops - ppc_supports_z_point_type,
8903 ppc_insert_point, ppc_remove_point.
8904
8905 2016-02-17 Marcin Kościelnicki <koriakin@0x04.net>
8906
8907 * linux-s390-low.c (s390_supports_z_point_type): New function.
8908 (struct linux_target_ops): Wire s390_supports_z_point_type in.
8909
8910 2016-02-16 Yao Qi <yao.qi@linaro.org>
8911
8912 * linux-arm-low.c (get_next_pcs_syscall_next_pc): Remove argument
8913 PC. Get pc from regcache_read_pc.
8914
8915 2016-02-12 Yao Qi <yao.qi@linaro.org>
8916
8917 * linux-aarch64-low.c (aarch64_get_pc): Call linux_get_pc_64bit
8918 or linux_get_pc_32bit.
8919 (aarch64_set_pc): Call linux_set_pc_64bit or linux_set_pc_32bit.
8920
8921 2016-02-12 Yao Qi <yao.qi@linaro.org>
8922
8923 * linux-arm-low.c (get_next_pcs_ops): Initialize it with
8924 arm_linux_get_next_pcs_fixup.
8925
8926 2016-02-12 Marcin Kościelnicki <koriakin@0x04.net>
8927
8928 * tracepoint.c (x_tracepoint_action_download): Change
8929 write_inferior_data_ptr to write_inferior_data_pointer.
8930 (cmd_qtstart): Likewise.
8931 (write_inferior_data_ptr): Remove.
8932 (download_agent_expr): Change write_inferior_data_ptr to
8933 write_inferior_data_pointer.
8934 (download_tracepoint_1): Likewise.
8935 (download_tracepoint): Likewise.
8936 (download_trace_state_variables): Likewise.
8937
8938 2016-02-11 Wei-cheng Wang <cole945@gmail.com>
8939 Marcin Kościelnicki <koriakin@0x04.net>
8940
8941 * tracepoint.c (struct tracepoint_action_ops): Remove.
8942 (struct tracepoint_action): Remove ops.
8943 (m_tracepoint_action_download, r_tracepoint_action_download)
8944 (x_tracepoint_action_download, l_tracepoint_action_download): Adjust
8945 size and offset accordingly.
8946 (m_tracepoint_action_ops, r_tracepoint_action_ops)
8947 (x_tracepoint_action_ops, l_tracepoint_action_ops): Remove.
8948 (tracepoint_action_send, tracepoint_action_download): New functions.
8949 Helpers for trace action handlers.
8950 (add_tracepoint_action): Remove setup actions ops.
8951 (download_tracepoint_1, tracepoint_send_agent): Call helper functions.
8952
8953 2016-02-10 Yao Qi <yao.qi@linaro.org>
8954
8955 * regcache.c (regcache_raw_read_unsigned): Clear *VAL.
8956
8957 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
8958
8959 * configure.ac: Use AC_CONFIG_FILES instead of passing arguments
8960 to AC_OUTPUT.
8961 * configure: Regenerate.
8962
8963 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
8964
8965 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): Change
8966 void * to gdb_byte *.
8967 * linux-low.c (siginfo_fixup): Likewise.
8968 (linux_xfer_siginfo): Likewise.
8969 * linux-low.h (struct linux_target_ops) <siginfo_fixup>:
8970 Likewise.
8971 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
8972
8973 2016-02-02 Walfred Tedeschi <walfred.tedeschi@intel.com>
8974
8975 * configure.srv (x86_64-*-linux*): Add amd64-linux-siginfo.o
8976 to srv_tgtobj.
8977 (i[34567]86-*-linux*): Add amd64-linux-siginfo.o
8978 to srv_tgtobj.
8979 * linux-x86-low.c [__x86_64__]: Include
8980 "nat/amd64-linux-siginfo.h".
8981 (compat_siginfo_from_siginfo, siginfo_from_compat_siginfo)
8982 (compat_x32_siginfo_from_siginfo, siginfo_from_compat_x32_siginfo)
8983 (compat_timeval, compat_sigval, compat_x32_clock, cpt_si_pid)
8984 (cpt_si_uid, cpt_si_timerid, cpt_si_overrun, cpt_si_status)
8985 (cpt_si_utime, cpt_si_stime, cpt_si_ptr, cpt_si_addr, cpt_si_band)
8986 (cpt_si_fd, si_timerid, si_overrun): Move from
8987 nat/amd64-linux-siginfo.c.
8988 * Makefile.in (amd64-linux-siginfo.o:): New rule.
8989
8990 2016-01-28 Simon Marchi <simon.marchi@ericsson.com>
8991
8992 * server.c (skip_to_semicolon): Remove.
8993 (process_point_options): Use strchrnul instead of
8994 skip_to_semicolon.
8995
8996 2016-01-26 Yao Qi <yao.qi@linaro.org>
8997
8998 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Remove argument pc.
8999 * linux-low.c (install_software_single_step_breakpoints): Don't
9000 call regcache_read_pc.
9001 * linux-low.h (struct linux_target_ops) <get_next_pcs>: Remove
9002 argument pc.
9003
9004 2016-01-26 Yao Qi <yao.qi@linaro.org>
9005
9006 * linux-low.c (install_software_single_step_breakpoints): Call
9007 regcache_read_pc instead of get_pc.
9008
9009 2016-01-26 Yao Qi <yao.qi@linaro.org>
9010
9011 * remote-utils.c (remote_close) [!USE_WIN32API]: Ignore SIGIO.
9012 (unblock_async_io): Rename to ...
9013 (block_unblock_async_io): ... it. New function.
9014 (enable_async_io): Don't install SIGIO handler. Unblock it
9015 instead.
9016 (disable_async_io): Don't ignore SIGIO. Block it instead.
9017 (initialize_async_io): Install SIGIO handler. Don't call
9018 unblock_async_io.
9019
9020 2016-01-26 Yao Qi <yao.qi@linaro.org>
9021
9022 * remote-utils.c (getpkt): If the buffer isn't empty, and the
9023 first character is '\003', call *the_target->request_interrupt.
9024
9025 2016-01-25 Yao Qi <yao.qi@linaro.org>
9026
9027 * remote-utils.c (new_thread_notify): Remove.
9028 (dead_thread_notify): Likewise.
9029 * remote-utils.h (new_thread_notify): Remove declaration.
9030 (dead_thread_notify): Likewise.
9031
9032 2016-01-23 Marcin Kościelnicki <koriakin@0x04.net>
9033
9034 * gdb.trace/pending.exp: Fix expected message on continue.
9035
9036 2016-01-22 Marcin Kościelnicki <koriakin@0x04.net>
9037
9038 * tracepoint.c (write_inferior_data_ptr): Cast to uintptr_t, so that
9039 it works properly on big-endian machines where sizeof (CORE_ADDR)
9040 != sizeof (void *).
9041
9042 2016-01-21 Pedro Alves <palves@redhat.com>
9043
9044 * Makefile.in (COMPILER_CFLAGS, CXXFLAGS): New.
9045 (INTERNAL_CFLAGS_BASE): Use COMPILER_CFLAGS instead of CFLAGS.
9046 * configure: Regenerate.
9047
9048 2016-01-21 Yao Qi <yao.qi@linaro.org>
9049
9050 * linux-arm-low.c (arm_sigreturn_next_pc): Add parameter
9051 is_thumb and set it according to CPSR saved on the stack.
9052 (get_next_pcs_syscall_next_pc): Pass is_thumb to
9053 arm_sigreturn_next_pc.
9054
9055 2016-01-18 Yao Qi <yao.qi@linaro.org>
9056
9057 * linux-low.c (linux_set_pc_64bit): New function.
9058 (linux_get_pc_64bit): New function.
9059 * linux-low.h (linux_set_pc_64bit, linux_get_pc_64bit):
9060 Declare.
9061 * linux-sparc-low.c (debug_threads): Remove declaration.
9062 (sparc_get_pc): Remove.
9063 (the_low_target): Use linux_get_pc_64bit instead of
9064 sparc_get_pc.
9065 * linux-tile-low.c (tile_get_pc, tile_set_pc): Remove.
9066 (the_low_target): Use linux_get_pc_64bit and
9067 linux_set_pc_64bit.
9068
9069 2016-01-18 Yao Qi <yao.qi@linaro.org>
9070
9071 * linux-arm-low.c (debug_threads): Remove declaration.
9072 (arm_get_pc, arm_set_pc): Remove.
9073 (the_low_target): Use linux_get_pc_32bit and
9074 linux_set_pc_32bit.
9075 * linux-bfin-low.c (bfin_get_pc, bfin_set_pc): Remove.
9076 (the_low_target): Use linux_get_pc_32bit and
9077 linux_set_pc_32bit.
9078 * linux-cris-low.c (debug_threads): Remove declaration.
9079 (cris_get_pc, cris_set_pc,): Remove.
9080 (the_low_target): Use linux_get_pc_32bit and
9081 linux_set_pc_32bit.
9082 * linux-crisv32-low.c (debug_threads): Remove declaration.
9083 (cris_get_pc, cris_set_pc): Remove.
9084 (the_low_target): Use linux_get_pc_32bit and
9085 linux_set_pc_32bit.
9086 * linux-low.c: Include inttypes.h.
9087 (linux_get_pc_32bit, linux_set_pc_32bit): New functions.
9088 * linux-low.h (linux_get_pc_32bit, linux_set_pc_32bit): Declare.
9089 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Remove.
9090 (the_low_target): Use linux_get_pc_32bit and
9091 linux_set_pc_32bit.
9092 * linux-m68k-low.c (m68k_get_pc, m68k_set_pc): Remove.
9093 (the_low_target): Use linux_get_pc_32bit and
9094 linux_set_pc_32bit.
9095 * linux-nios2-low.c (nios2_get_pc, nios2_set_pc): Remove.
9096 (the_low_target): Use linux_get_pc_32bit and
9097 linux_set_pc_32bit.
9098 * linux-sh-low.c (sh_get_pc, sh_set_pc): Remove.
9099 (the_low_target): Use linux_get_pc_32bit and
9100 linux_set_pc_32bit.
9101 * linux-xtensa-low.c (xtensa_get_pc, xtensa_set_pc): Remove.
9102 (the_low_target): Use linux_get_pc_32bit and
9103 linux_set_pc_32bit.
9104
9105 2016-01-18 Gary Benson <gbenson@redhat.com>
9106
9107 * configure.ac (AC_FUNC_FORK): New check.
9108 * config.in: Regenerate.
9109 * configure: Likewise.
9110
9111 2016-01-14 Yao Qi <yao.qi@linaro.org>
9112
9113 * linux-aarch32-low.c (thumb2_breakpoint): Make it static.
9114 * linux-aarch32-low.h (thumb2_breakpoint): Remove declaration.
9115 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Pass 1 to
9116 arm_get_next_pcs_ctor.
9117
9118 2016-01-12 Josh Stone <jistone@redhat.com>
9119 Philippe Waroquiers <philippe.waroquiers@skynet.be>
9120
9121 * inferiors.h: Include "gdb_vecs.h".
9122 (struct process_info): Add syscalls_to_catch.
9123 * inferiors.c (remove_process): Free syscalls_to_catch.
9124 * remote-utils.c (prepare_resume_reply): Report syscall_entry and
9125 syscall_return stops.
9126 * server.h (UNKNOWN_SYSCALL, ANY_SYSCALL): Define.
9127 * server.c (handle_general_set): Handle QCatchSyscalls.
9128 (handle_query): Report support for QCatchSyscalls.
9129 * target.h (struct target_ops): Add supports_catch_syscall.
9130 (target_supports_catch_syscall): New macro.
9131 * linux-low.h (struct linux_target_ops): Add get_syscall_trapinfo.
9132 (struct lwp_info): Add syscall_state.
9133 * linux-low.c (handle_extended_wait): Mark syscall_state as an entry.
9134 Maintain syscall_state and syscalls_to_catch across exec.
9135 (get_syscall_trapinfo): New function, proxy to the_low_target.
9136 (linux_low_ptrace_options): Enable PTRACE_O_TRACESYSGOOD.
9137 (linux_low_filter_event): Toggle syscall_state entry/return for
9138 syscall traps, and set it ignored for all others.
9139 (gdb_catching_syscalls_p): New function.
9140 (gdb_catch_this_syscall_p): New function.
9141 (linux_wait_1): Handle SYSCALL_SIGTRAP.
9142 (linux_resume_one_lwp_throw): Add PTRACE_SYSCALL possibility.
9143 (linux_supports_catch_syscall): New function.
9144 (linux_target_ops): Install it.
9145 * linux-x86-low.c (x86_get_syscall_trapinfo): New function.
9146 (the_low_target): Install it.
9147
9148 2016-01-12 Mike Frysinger <vapier@gentoo.org>
9149
9150 * acinclude.m4: Include new ../warning.m4 file.
9151 * configure: Regenerated.
9152 * configure.ac: Replace all warning logic with AM_GDB_WARNINGS.
9153
9154 2016-01-12 Mike Frysinger <vapier@gentoo.org>
9155
9156 * ax.c (is_goto_target): Mark static.
9157 * linux-low.c (register_addr): Likewise.
9158 (linux_fetch_registers, linux_store_registers): Likewise.
9159 * mem-break.c (any_persistent_commands): Fix old prototype.
9160 (add_commands_to_breakpoint): Mark static.
9161 * regcache.c (find_register_by_name): Delete unused func.
9162 * remote-utils.c (hex_or_minus_one): Mark static.
9163 * server.c (monitor_show_help): Mark static.
9164 (handle_query, handle_v_cont, handle_v_attach, handle_v_kill,
9165 handle_v_requests): Likewise.
9166
9167 2016-01-12 Pedro Alves <palves@redhat.com>
9168
9169 Remove use of the registered trademark symbol throughout.
9170
9171 2016-01-08 Yao Qi <yao.qi@linaro.org>
9172
9173 * remote-utils.c (getpkt): If c is '\003', call target hook
9174 request_interrupt.
9175
9176 2016-01-06 Yao Qi <yao.qi@linaro.org>
9177
9178 * linux-aarch32-low.h (arm_abi_breakpoint): Move to
9179 linux-aarch32-low.c.
9180 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
9181 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
9182 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
9183 (thumb2_breakpoint): Declare.
9184 * linux-aarch32-low.c (arm_abi_breakpoint): Moved from
9185 linux-aarch32-low.h.
9186 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
9187 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
9188 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
9189
9190 2016-01-01 Joel Brobecker <brobecker@adacore.com>
9191
9192 * gdbreplay.c (gdbreplay_version): Change copyright year in
9193 version message.
9194 * server.c (gdbserver_version): Likewise.
9195
9196 2015-12-28 Patrick Palka <patrick@parcs.ath.cx>
9197
9198 * server.c (crc32_table): Delete.
9199 (crc32): Use libiberty's xcrc32 function.
9200
9201 2015-12-22 Joel Brobecker <brobecker@adacore.com>
9202
9203 * lynx-low.c (lynx_delete_thread_callback): New function.
9204 (lynx_mourn): Properly delete our process and all of its
9205 threads. Remove call to clear_inferiors.
9206
9207 2015-12-22 Joel Brobecker <brobecker@adacore.com>
9208
9209 * target.c (thread_search_callback): Add check that
9210 the thread_stopped target callback is not NULL before
9211 calling it.
9212
9213 2015-12-21 Yao Qi <yao.qi@linaro.org>
9214
9215 * linux-aarch32-low.h [__aarch64__]: Use arm_abi_breakpoint
9216 arm breakpoint.
9217
9218 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
9219
9220 * server.c (handle_query): Call target_supports_software_single_step.
9221
9222 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
9223
9224 * linux-low.c (single_step): New function.
9225 (linux_resume_one_lwp_throw): Call single_step.
9226 (start_step_over): Likewise.
9227
9228 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
9229
9230 * Makefile.in (SFILES): Append arch/arm-linux.c,
9231 arch/arm-get-next-pcs.c.
9232 (arm-linux.o): New rule.
9233 (arm-get-next-pcs.o): New rule.
9234 * configure.srv (arm*-*-linux*): Add arm-get-next-pcs.o,
9235 arm-linux.o.
9236 * linux-aarch32-low.c (arm_abi_breakpoint): Remove macro. Moved
9237 to linux-aarch32-low.c.
9238 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
9239 (arm_breakpoint_len, thumb_breakpoint): Likewise.
9240 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
9241 (thumb2_breakpoint_len): Likewise.
9242 (arm_is_thumb_mode): Make non-static.
9243 * linux-aarch32-low.h (arm_abi_breakpoint): New macro. Moved
9244 from linux-aarch32-low.c.
9245 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
9246 (arm_breakpoint_len, thumb_breakpoint): Likewise.
9247 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
9248 (thumb2_breakpoint_len): Likewise.
9249 (arm_is_thumb_mode): New declaration.
9250 * linux-arm-low.c: Include arch/arm-linux.h
9251 aarch/arm-get-next-pcs.h, sys/syscall.h.
9252 (get_next_pcs_ops): New struct.
9253 (get_next_pcs_addr_bits_remove): New function.
9254 (get_next_pcs_is_thumb): New function.
9255 (get_next_pcs_read_memory_unsigned_integer): Likewise.
9256 (arm_sigreturn_next_pc): Likewise.
9257 (get_next_pcs_syscall_next_pc): Likewise.
9258 (arm_gdbserver_get_next_pcs): Likewise.
9259 (struct linux_target_ops) <arm_gdbserver_get_next_pcs>:
9260 Initialize.
9261 * linux-low.h: Move CORE_ADDR vector definition to gdb_vecs.h.
9262 * server.h: Include gdb_vecs.h.
9263
9264 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
9265
9266 * Makefile.in (SFILES): Append common/common-regcache.c.
9267 (OBS): Append common-regcache.o.
9268 (common-regcache.o): New rule.
9269 * regcache.c (init_register_cache): Initialize cache to
9270 REG_UNAVAILABLE.
9271 (regcache_raw_read_unsigned): New function.
9272 * regcache.h (REG_UNAVAILABLE, REG_VALID): Replaced by shared
9273 register_status enum.
9274
9275 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
9276
9277 * linux-aarch64-low.c (the_low_targets): Rename
9278 breakpoint_reinsert_addr to get_next_pcs.
9279 * linux-arm-low.c (the_low_targets): Likewise.
9280 * linux-bfin-low.c (the_low_targets): Likewise.
9281 * linux-cris-low.c (the_low_targets): Likewise.
9282 * linux-crisv32-low.c (the_low_targets): Likewise.
9283 * linux-low.c (can_software_single_step): Likewise.
9284 (install_software_single_step_breakpoints): New function.
9285 (start_step_over): Use install_software_single_step_breakpoints.
9286 * linux-low.h: New CORE_ADDR vector.
9287 (struct linux_target_ops) Rename breakpoint_reinsert_addr to
9288 get_next_pcs.
9289 * linux-mips-low.c (the_low_targets): Likewise.
9290 * linux-nios2-low.c (the_low_targets): Likewise.
9291 * linux-sparc-low.c (the_low_targets): Likewise.
9292
9293 2015-12-17 Pedro Alves <palves@redhat.com>
9294
9295 * linux-low.c (linux_kill_one_lwp): Remove references to
9296 LinuxThreads.
9297 (kill_lwp): Remove HAVE_TKILL_SYSCALL check. No longer fall back
9298 to 'kill'.
9299 (linux_init_signals): Delete.
9300 (initialize_low): Adjust.
9301 * thread-db.c (thread_db_init): Remove LinuxThreads reference.
9302
9303 2015-12-16 Pedro Alves <palves@redhat.com>
9304
9305 * configure.ac (compiler warning flags): When testing a
9306 -Wno-foo option, check whether -Wfoo works instead.
9307 * configure: Regenerate.
9308
9309 2015-12-11 Don Breazeal <donb@codesourcery.com>
9310
9311 * server.c (process_serial_event): Don't exit from gdbserver
9312 in remote mode if there are still active inferiors.
9313
9314 2015-12-11 Yao Qi <yao.qi@linaro.org>
9315
9316 * linux-aarch64-low.c (aarch64_breakpoint_at): Call
9317 arm_breakpoint_at if the process is 32-bit.
9318
9319 2015-12-11 Yao Qi <yao.qi@linaro.org>
9320
9321 * linux-aarch32-low.c [__aarch64__]: Use arm_abi_breakpoint
9322 arm breakpoint.
9323
9324 2015-12-07 Yao Qi <yao.qi@linaro.org>
9325
9326 * configure.srv: Append arm.o to srv_tgtobj for
9327 aarch64*-*-linux* target.
9328 * linux-aarch32-low.c (arm_abi_breakpoint): New macro. Moved
9329 from linux-arm-low.c.
9330 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
9331 (arm_breakpoint_len, thumb_breakpoint): Likewise.
9332 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
9333 (thumb2_breakpoint_len): Likewise.
9334 (arm_is_thumb_mode, arm_breakpoint_at): Likewise.
9335 (arm_breakpoint_kinds): Likewise.
9336 (arm_breakpoint_kind_from_pc): Likewise.
9337 (arm_sw_breakpoint_from_kind): Likewise.
9338 (arm_breakpoint_kind_from_current_state): Likewise.
9339 * linux-aarch32-low.h (arm_breakpoint_kind_from_pc): Declare.
9340 (arm_sw_breakpoint_from_kind): Declare.
9341 (arm_breakpoint_kind_from_current_state): Declare.
9342 (arm_breakpoint_at): Declare.
9343 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): Call
9344 arm_sw_breakpoint_from_kind if process is 32-bit.
9345 (aarch64_breakpoint_kind_from_pc): New function.
9346 (aarch64_breakpoint_kind_from_current_state): New function.
9347 (the_low_target): Initialize fields breakpoint_kind_from_pc
9348 and breakpoint_kind_from_current_state.
9349 * linux-arm-low.c (arm_breakpoint_kinds): Move to
9350 linux-aarch32-low.c.
9351 (arm_abi_breakpoint, arm_eabi_breakpoint): Likewise.
9352 (arm_breakpoint, arm_breakpoint_len): Likewise.
9353 (thumb_breakpoint, thumb_breakpoint_len): Likewise.
9354 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
9355 (arm_is_thumb_mode): Likewise.
9356 (arm_breakpoint_at): Likewise.
9357 (arm_breakpoint_kind_from_pc): Likewise.
9358 (arm_sw_breakpoint_from_kind): Likewise.
9359 (arm_breakpoint_kind_from_current_state): Likewise.
9360
9361 Revert:
9362 2015-08-04 Yao Qi <yao.qi@linaro.org>
9363
9364 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
9365 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
9366 * server.c (extended_protocol): Remove "static".
9367 * server.h (extended_protocol): Declare it.
9368
9369 2015-12-04 Josh Stone <jistone@redhat.com>
9370
9371 * target.h (struct target_ops) <arch_setup>: Rename to ...
9372 (struct target_ops) <post_create_inferior>: ... this.
9373 (target_arch_setup): Rename to ...
9374 (target_post_create_inferior): ... this, calling post_create_inferior.
9375 * server.c (start_inferior): Update target_arch_setup calls to
9376 target_post_create_inferior.
9377 * linux-low.c (linux_low_ptrace_options): Forward declare.
9378 (linux_arch_setup): Update its comment for general use.
9379 (linux_post_create_inferior): New, run arch_setup and setup ptrace.
9380 (struct linux_target_ops): Use linux_post_create_inferior.
9381 * lynx-low.c (struct lynx_target_ops): Update arch_setup stub comment
9382 to post_create_inferior.
9383 * nto-low.c (struct nto_target_ops): Likewise.
9384 * spu-low.c (struct spu_target_ops): Likewise.
9385 * win32-low.c (struct win32_target_ops): Likewise.
9386
9387 2015-12-03 Antoine Tremblay <antoine.tremblay@ericsson.com>
9388
9389 * linux-arm-low.c: Remove duplicate arch/arm.h include.
9390
9391 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
9392
9393 * linux-arm-low.c (arm_reinsert_addr): Remove function.
9394 (struct linux_target_ops <breakpoint_reinsert_addr>: Set to NULL.
9395 * linux-cris-low.c (cris_reinsert_addr> Remove function.
9396 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
9397 * linux-crisv32-low.c (cris_reinsert_addr): Remove function.
9398 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
9399 * linux-mips-low.c (mips_reinsert_addr): Remove function.
9400 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
9401 * linux-nios2-low.c (nios2_reinsert_addr): Remove function.
9402 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
9403 * linux-sparc-low.c (sparc_reinsert_addr): Remove function.
9404 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
9405
9406 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
9407
9408 * linux-low.c (linux_look_up_symbols): Don't call
9409 linux_supports_traceclone.
9410 * linux-low.h (thread_db_init): Remove use_events argument.
9411 * thread-db.c (thread_db_use_event): Remove global variable.
9412 (struct thread_db) <td_thr_event_enable_p>: Remove field.
9413 (struct thread_db) <td_create_bp>: Remove field.
9414 (thread_db_create_event): Remove function.
9415 (thread_db_enable_reporting): Likewise.
9416 (find_one_thread): Don't check for thread_db_use_events.
9417 (attach_thread): Likewise.
9418 (thread_db_load_search): Remove td_thr_event_enable_p initialization.
9419 (try_thread_db_load_1): Don't check for thread_db_use_events.
9420 (thread_db_init): Remove use_events argument and thread events
9421 handling.
9422 (remove_thread_event_breakpoints): Remove function.
9423 (thread_db_detach): Remove call to remove_thred_event_breakpoints.
9424
9425 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
9426
9427 * linux-aarch64-low.c (aarch64_supports_hardware_single_step):
9428 New function.
9429 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9430 * linux-arm-low.c (arm_supports_hardware_single_step): New function.
9431 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9432 * linux-bfin-low.c (bfin_supports_hardware_single_step): New function.
9433 (struct linux_target_ops) <bfin_supports_hardware_single_step>:
9434 Initialize.
9435 * linux-crisv32-low.c (cris_supports_hardware_single_step):
9436 New function.
9437 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9438 * linux-low.c (can_hardware_single_step): Use
9439 supports_hardware_single_step.
9440 (can_software_single_step): New function.
9441 (start_step_over): Call can_software_single_step.
9442 (linux_supports_hardware_single_step): New function.
9443 (struct target_ops) <supports_software_single_step>: Initialize.
9444 * linux-low.h (struct linux_target_ops)
9445 <supports_hardware_single_step>: Initialize.
9446 * linux-m32r-low.c (m32r_supports_hardware_single_step): New function.
9447 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9448 * linux-ppc-low.c (ppc_supports_hardware_single_step): New function.
9449 (struct linux_target_ops) <supports_hardware_single_step> Initialize.
9450 * linux-s390-low.c (s390_supports_hardware_single_step): New function.
9451 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9452 * linux-sh-low.c (sh_supports_hardware_single_step): New function.
9453 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9454 * linux-tic6x-low.c (tic6x_supports_hardware_single_step): New function.
9455 (struct linux_target_ops) <tic6x_supports_hardware_single_step>:
9456 Initialize.
9457 * linux-tile-low.c (tile_supports_hardware_single_step): New function.
9458 (struct linux_target_ops) <tile_supports_hardware_single_step>:
9459 Initialize.
9460 * linux-x86-low.c (x86_supports_hardware_single_step) New function.
9461 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9462 * linux-xtensa-low.c (xtensa_supports_hardware_single_step):
9463 New function.
9464 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9465 * target.h (struct target_ops): <supports_software_single_step>:
9466 New field.
9467 (target_supports_software_single_step): New macro.
9468
9469 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
9470
9471 * linux-low.c (linux_wait_1): Fix pc advance condition.
9472 * mem-break.c (reinsert_breakpoint_inserted_here): New function.
9473 * mem-break.h (reinsert_breakpoint_inserted_here): New declaration.
9474
9475 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
9476
9477 * linux-arm-low.c (arm_is_thumb_mode): New function.
9478 (arm_breakpoint_at): Use arm_is_thumb_mode.
9479 (arm_breakpoint_kind_from_current_state): New function.
9480 (struct linux_target_ops) <breakpoint_kind_from_current_state>:
9481 Initialize.
9482 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_current_state.
9483 (linux_breakpoint_kind_from_current_state): New function.
9484 (struct target_ops <breakpoint_kind_from_current_state>: Initialize.
9485 * linux-low.h (struct linux_target_ops)
9486 <breakpoint_kind_from_current_state>: New field.
9487 * target.h (struct target_ops): Likewise.
9488 (target_breakpoint_kind_from_current_state): New macro.
9489
9490 2015-11-30 Pedro Alves <palves@redhat.com>
9491
9492 * linux-low.c (linux_resume): Wake up the event loop before
9493 returning.
9494
9495 2015-11-30 Pedro Alves <palves@redhat.com>
9496
9497 * mem-break.c (check_gdb_bp_preconditions): Remove current_thread
9498 check.
9499 (set_gdb_breakpoint): If prepare_to_access_memory fails, set *ERR
9500 to -1.
9501 * target.c (struct thread_search): New structure.
9502 (thread_search_callback): New function.
9503 (prev_general_thread): New global.
9504 (prepare_to_access_memory, done_accessing_memory): New functions.
9505 * target.h (prepare_to_access_memory, done_accessing_memory):
9506 Replace macros with function declarations.
9507
9508 2015-11-30 Pedro Alves <palves@redhat.com>
9509
9510 PR 14618
9511 * linux-low.c (linux_wait_1): If the last resumed thread is gone,
9512 report TARGET_WAITKIND_NO_RESUMED.
9513 * remote-utils.c (prepare_resume_reply): Handle
9514 TARGET_WAITKIND_NO_RESUMED.
9515 * server.c (report_no_resumed): New global.
9516 (handle_query) <qSupported>: Handle "no-resumed+". Report
9517 "no-resumed+" support.
9518 (resume): When the target reports TARGET_WAITKIND_NO_RESUMED, only
9519 return error if the client doesn't support no-resumed events.
9520 (push_stop_notification): New function.
9521 (handle_target_event): Use it. Report TARGET_WAITKIND_NO_RESUMED
9522 events if the client supports them.
9523
9524 2015-11-30 Pedro Alves <palves@redhat.com>
9525
9526 * linux-low.c (thread_still_has_status_pending_p): Don't check
9527 vCont;t here.
9528 (lwp_resumed): New function.
9529 (status_pending_p_callback): Return early if the LWP is not
9530 supposed to be resumed.
9531
9532 2015-11-30 Pedro Alves <palves@redhat.com>
9533
9534 * linux-low.c (handle_extended_wait): Assert that the LWP's
9535 waitstatus is TARGET_WAITKIND_IGNORE. If GDB wants to hear about
9536 thread create events, leave the new child's status pending.
9537 (linux_low_filter_event): If GDB wants to hear about thread exit
9538 events, leave the LWP marked dead and don't delete it.
9539 (linux_wait_for_event_filtered): Don't check for thread exit.
9540 (filter_exit_event): New function.
9541 (linux_wait_1): Use it, when returning an exit event.
9542 (linux_resume_one_lwp_throw): Assert that the LWP's
9543 waitstatus is TARGET_WAITKIND_IGNORE.
9544 * remote-utils.c (prepare_resume_reply): Handle
9545 TARGET_WAITKIND_THREAD_CREATED and TARGET_WAITKIND_THREAD_EXITED.
9546 * server.c (report_thread_events): New global.
9547 (handle_general_set): Handle QThreadEvents.
9548 (handle_query) <qSupported>: Handle and report QThreadEvents+;
9549 (handle_target_event): Handle TARGET_WAITKIND_THREAD_CREATED and
9550 TARGET_WAITKIND_THREAD_EXITED.
9551 * server.h (report_thread_events): Declare.
9552
9553 2015-11-30 Pedro Alves <palves@redhat.com>
9554
9555 * linux-low.c (resume_stopped_resumed_lwps): Don't check whether
9556 the thread's last_resume_kind was resume_stop.
9557
9558 2015-11-30 Pedro Alves <palves@redhat.com>
9559
9560 * linux-low.c (linux_attach): In non-stop mode, wait for one stop
9561 before returning.
9562
9563 2015-11-30 Pedro Alves <palves@redhat.com>
9564
9565 * server.c (handle_v_requests): Handle vCtrlC.
9566
9567 2015-11-30 Pedro Alves <palves@redhat.com>
9568
9569 * gdbthread.h (find_any_thread_of_pid): Declare.
9570 * inferiors.c (thread_of_pid, find_any_thread_of_pid): New
9571 functions.
9572 * server.c (handle_query): If current_thread is NULL, look for
9573 another thread of the selected process.
9574
9575 2015-11-26 Daniel Colascione <dancol@dancol.org>
9576 Simon Marchi <simon.marchi@ericsson.com>
9577
9578 * linux-low.c (linux_target_ops): Use linux_proc_tid_get_name.
9579 * server.c (handle_qxfer_threads_worker): Refactor to include thread
9580 name in reply.
9581 * target.h (struct target_ops) <thread_name>: New field.
9582 (target_thread_name): New macro.
9583
9584 2015-11-23 Joel Brobecker <brobecker@adacore.com>
9585
9586 * regcache.h (regcache_invalidate_pid): Add declaration.
9587 * regcache.c (regcache_invalidate_pid): New function, extracted
9588 from regcache_invalidate.
9589 (regcache_invalidate): Reimplement using regcache_invalidate_pid.
9590 Add trivial documentation comment.
9591 * lynx-low.c: Use regcache_invalidate_pid instead of
9592 regcache_invalidate.
9593
9594 2015-11-23 Joel Brobecker <brobecker@adacore.com>
9595
9596 * configure.ac: Do not call AC_CHECK_TYPES for Elf32_auxv_t
9597 and Elf64_auxv_t if the target is Android.
9598
9599 2015-11-22 Doug Evans <xdje42@gmail.com>
9600
9601 * target.h: #include <sys/types.h>.
9602
9603 2015-11-19 Pedro Alves <palves@redhat.com>
9604
9605 * linux-low.c (linux_process_qsupported): Change prototype.
9606 Adjust.
9607 * linux-low.h (struct linux_target_ops) <process_qsupported>:
9608 Change prototype.
9609 * linux-x86-low.c (x86_linux_process_qsupported): Change prototype
9610 and adjust to loop over all features.
9611 * server.c (handle_query) <qSupported>: Adjust to call
9612 target_process_qsupported once, passing it a vector of unprocessed
9613 features.
9614 * target.h (struct target_ops) <process_qsupported>: Change
9615 prototype.
9616 (target_process_qsupported): Adjust.
9617
9618 2015-11-19 Pedro Alves <palves@redhat.com>
9619
9620 * configure.ac (ERROR_ON_WARNING): Don't check whether in C++
9621 mode.
9622 * configure: Regenerate.
9623
9624 2015-11-19 Pedro Alves <palves@redhat.com>
9625
9626 * configure: Regenerate.
9627
9628 2015-11-19 Yao Qi <yao.qi@linaro.org>
9629
9630 * linux-aarch64-low.c (emit_data_processing_reg): Change opcode
9631 type to uint32_t.
9632
9633 2015-11-19 Yao Qi <yao.qi@linaro.org>
9634
9635 * linux-aarch64-low.c (enum aarch64_operand_type): New.
9636 (struct aarch64_operand): Move enum out.
9637
9638 2015-11-19 Yao Qi <yao.qi@linaro.org>
9639
9640 * linux-aarch64-low.c (aarch64_fill_fpregset): Cast buf to
9641 struct user_fpsimd_state *.
9642 (aarch64_store_fpregset): Likewise.
9643
9644 2015-11-19 Yao Qi <yao.qi@linaro.org>
9645
9646 * linux-aarch64-low.c (aarch64_fill_gregset): Cast buf to
9647 struct user_pt_regs *.
9648 (aarch64_store_gregset): Likewise.
9649
9650 2015-11-18 Pedro Alves <palves@redhat.com>
9651
9652 * Makefile.in (all_object_files): Add $IPA_OBJS.
9653
9654 2015-11-17 Pedro Alves <palves@redhat.com>
9655
9656 * win32-low.c (win32_resume): Use gdb_signal_from_host,
9657 GDB_SIGNAL_0 and gdb_signal_to_string.
9658
9659 2015-11-17 Pedro Alves <palves@redhat.com>
9660
9661 * win32-low.c (handle_output_debug_string): Remove parameter.
9662 (win32_kill): Remove our_status local and adjust call to
9663 handle_output_debug_string.
9664 (get_child_debug_event): Adjust call to
9665 handle_output_debug_string.
9666
9667 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9668
9669 * linux-mips-low.c (mips_fill_gregset): Add cast.
9670 (mips_store_gregset): Likewise.
9671 (mips_fill_fpregset): Likewise.
9672 (mips_store_fpregset): Likewise.
9673
9674 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9675
9676 * linux-mips-low.c (mips_add_watchpoint): Rename private to
9677 priv.
9678
9679 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9680
9681 * linux-mips-low.c (mips_linux_new_thread): Change type of
9682 watch_type to enum target_hw_bp_type.
9683
9684 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9685
9686 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type):
9687 Change return type to arm_hwbp_type.
9688
9689 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9690
9691 * linux-aarch32-low.c (arm_fill_gregset): Add cast.
9692 (arm_store_gregset): Likewise.
9693 * linux-arm-low.c (arm_get_hwcap): Likewise.
9694 (arm_read_description): Likewise.
9695
9696 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9697
9698 * linux-aarch32-low.c (aarch32_regsets): Use NULL_REGSET.
9699
9700 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9701
9702 * linux-ppc-low.c (ppc_get_hwcap): Add cast.
9703 (ppc_fill_vsxregset): Likewise.
9704 (ppc_store_vsxregset): Likewise.
9705 (ppc_fill_vrregset): Likewise.
9706 (ppc_store_vrregset): Likewise.
9707 (ppc_fill_evrregset): Likewise.
9708 (ppc_store_evrregset): Likewise.
9709
9710 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9711
9712 * linux-ppc-low.c (ppc_usrregs_info): Remove
9713 forward-declaration.
9714 (ppc_arch_setup): Move lower in file.
9715
9716 2015-10-30 Simon Marchi <simon.marchi@ericsson.com>
9717
9718 * proc-service.c (ps_pdread): Change CORE_ADDR cast to uintptr_t.
9719 (ps_pdwrite): Likewise.
9720
9721 2015-10-29 Henrik Wallin <henrik.wallin@windriver.com>
9722
9723 * linux-arm-low.c (arm_new_thread): Move pointer dereference
9724 to after assert checks.
9725
9726 2015-10-29 Simon Marchi <simon.marchi@ericsson.com>
9727
9728 * proc-service.c (ps_pdread): Add/adjust casts.
9729 (ps_pdwrite): Add/adjust casts.
9730
9731 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
9732
9733 * server.c (handle_search_memory_1): Cast return value of
9734 memmem.
9735
9736 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
9737
9738 * server.c (write_qxfer_response): Change type of data to
9739 gdb_byte *.
9740
9741 2015-10-29 Pedro Alves <palves@redhat.com>
9742
9743 * mem-break.c (Z_packet_to_bkpt_type): Add cast.
9744
9745 2015-10-29 Pedro Alves <palves@redhat.com>
9746
9747 * tracepoint.c (clear_installed_tracepoints): Add casts.
9748
9749 2015-10-29 Pedro Alves <palves@redhat.com>
9750
9751 * server.c (handle_v_cont, process_serial_event): Add enum
9752 gdb_signal casts to signal parsing code.
9753
9754 2015-10-29 Pedro Alves <palves@redhat.com>
9755
9756 * linux-low.h (NULL_REGSET): Define.
9757 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
9758 * linux-arm-low.c (arm_regsets): Likewise.
9759 * linux-crisv32-low.c (cris_regsets): Likewise.
9760 * linux-m68k-low.c (m68k_regsets): Likewise.
9761 * linux-mips-low.c (mips_regsets): Likewise.
9762 * linux-nios2-low.c (nios2_regsets): Likewise.
9763 * linux-ppc-low.c (ppc_regsets): Likewise.
9764 * linux-s390-low.c (s390_regsets): Likewise.
9765 * linux-sh-low.c (sh_regsets): Likewise.
9766 * linux-sparc-low.c (sparc_regsets): Likewise.
9767 * linux-tic6x-low.c (tic6x_regsets): Likewise.
9768 * linux-tile-low.c (tile_regsets): Likewise.
9769 * linux-x86-low.c (x86_regsets): Likewise.
9770 * linux-xtensa-low.c (xtensa_regsets): Likewise.
9771
9772 2015-10-29 Pedro Alves <palves@redhat.com>
9773
9774 * linux-low.h (NULL_REGSET): Define.
9775 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
9776 * linux-arm-low.c (arm_regsets): Likewise.
9777 * linux-crisv32-low.c (cris_regsets): Likewise.
9778 * linux-m68k-low.c (m68k_regsets): Likewise.
9779 * linux-mips-low.c (mips_regsets): Likewise.
9780 * linux-nios2-low.c (nios2_regsets): Likewise.
9781 * linux-ppc-low.c (ppc_regsets): Likewise.
9782 * linux-s390-low.c (s390_regsets): Likewise.
9783 * linux-sh-low.c (sh_regsets): Likewise.
9784 * linux-sparc-low.c (sparc_regsets): Likewise.
9785 * linux-tic6x-low.c (tic6x_regsets): Likewise.
9786 * linux-tile-low.c (tile_regsets): Likewise.
9787 * linux-x86-low.c (x86_regsets): Likewise.
9788 * linux-xtensa-low.c (xtensa_regsets): Likewise.
9789
9790 2015-10-26 Doug Evans <dje@google.com>
9791
9792 * linux-low.c (__SIGRTMIN): Move to nat/linux-nat.h.
9793
9794 2015-10-26 Doug Evans <dje@google.com>
9795
9796 * linux-low.c (W_STOPCODE): Moved to common/gdb_wait.h.
9797
9798 2015-10-26 Doug Evans <dje@google.com>
9799
9800 * thread-db.c (find_one_thread): Cast ti.ti_tid to unsigned long
9801 for debug_printf.
9802 (attach_thread, find_new_threads_callback): Ditto.
9803
9804 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
9805
9806 * mem-break.h (set_breakpoint_data): Remove.
9807
9808 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
9809
9810 * nto-low.c (nto_sw_breakpoint_from_kind): New function.
9811 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
9812 (initialize_low): Remove set_breakpoint_data call.
9813 * spu-low.c (spu_sw_breakpoint_from_kind): New function.
9814 (struct target_ops) <sw_breakpoint_from_kind>: Iniitalize.
9815 (initialize_low): Remove set_breakpoint_data call.
9816 * win32-low.c (win32_sw_breakpoint_from_kind): New function.
9817 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
9818 (initialize_low): Remove set_breakpoint_data call.
9819
9820 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
9821
9822 * linux-low.c (default_breakpoint_kind_from_pc): Move to target.c.
9823 * mem-break.c (set_breakpoint_at): Use target_breakpoint_kind_from_pc.
9824 * target.c (default_breakpoint_kind_from_pc): Moved from linux-low.c
9825 * target.h (target_breakpoint_kind_from_pc): New macro.
9826
9827 2015-10-22 Antoine Tremblay <antoine.tremblay@ericsson.com>
9828
9829 * linux-low.c (default_breakpoint_kind_from_pc): New function.
9830 (linux_breakpoint_kind_from_pc): Use default_breakpoint_kind_from_pc for
9831 the default breakpoint kind.
9832
9833 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9834
9835 * linux-arm-low.c (arm_supports_z_point_type): Add software
9836 breakpoint support.
9837
9838 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9839
9840 * linux-arm-low.c: Refactor breakpoint definitions.
9841 (arm_breakpoint_at): Adjust for arm_abi_breakpoint.
9842 (arm_sw_breakpoint_from_kind): Adjust for arm_breakpoint.
9843
9844 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9845
9846 * Makefile.in: Add arm.c/o.
9847 * configure.srv: Likewise.
9848 * linux-arm-low.c (arm_breakpoint_kinds): New enum.
9849 (arm_breakpoint_kind_from_pc): New function.
9850 (arm_sw_breakpoint_from_kind): Return proper kind.
9851 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize.
9852
9853 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9854
9855 * linux-low.c (initialize_low): Ajdust for breakpoint global variables
9856 removal.
9857 * mem-break.c : Remove breakpoint_data/breakpoint_len global variables.
9858 (struct raw_breakpoint) <size>: Remove.
9859 (struct raw_breakpoint) <kind>: Add.
9860 (bp_size): New function.
9861 (bp_opcode): Likewise.
9862 (find_raw_breakpoint_at): Adjust for kind.
9863 (insert_memory_breakpoint): Adjust for kind call bp_size,bp_opcode.
9864 (remove_memory_breakpoint): Adjust for kind call bp_size.
9865 (set_raw_breakpoint_at): Adjust for kind.
9866 (set_breakpoint): Likewise.
9867 (set_breakpoint_at): Call breakpoint_kind_from_pc.
9868 (delete_raw_breakpoint): Adjust for kind.
9869 (delete_breakpoint): Likewise.
9870 (find_gdb_breakpoint): Likewise.
9871 (set_gdb_breakpoint_1): Likewise.
9872 (set_gdb_breakpoint): Likewise.
9873 (delete_gdb_breakpoint_1): Likewise.
9874 (delete_gdb_breakpoint): Likewise.
9875 (uninsert_raw_breakpoint): Likewise.
9876 (reinsert_raw_breakpoint): Likewise.
9877 (set_breakpoint_data): Remove.
9878 (validate_inserted_breakpoint): Adjust for kind call bp_size,bp_opcode.
9879 (check_mem_read): Adjust for kind call bp_size.
9880 (check_mem_write): Adjust for kind call bp_size,bp_opcode.
9881 (clone_one_breakpoint): Adjust for kind.
9882 * mem-break.h (set_gdb_breakpoint): Likewise.
9883 (delete_gdb_breakpoint): Likewise.
9884 * server.c (process_serial_event): Likewise.
9885
9886 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9887
9888 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): New function.
9889 (struct linux_target_ops) <breakpoint>: Remove.
9890 (struct linux_target_ops) <breakpoint_len>: Remove.
9891 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9892 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9893 * linux-arm-low.c (arm_breakpoint_kind_from_pc): New function.
9894 (arm_sw_breakpoint_from_kind): New function.
9895 * linux-bfin-low.c (bfin_sw_breakpoint_from_kind): New function.
9896 (struct linux_target_ops) <breakpoint>: Remove.
9897 (struct linux_target_ops) <breakpoint_len>: Remove.
9898 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9899 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9900 * linux-cris-low.c (cris_sw_breakpoint_from_kind): New function.
9901 (struct linux_target_ops) <breakpoint>: Remove.
9902 (struct linux_target_ops) <breakpoint_len>: Remove.
9903 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9904 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9905 * linux-crisv32-low.c (cris_sw_breakpoint_from_kind): New function.
9906 (struct linux_target_ops) <breakpoint>: Remove.
9907 (struct linux_target_ops) <breakpoint_len>: Remove.
9908 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9909 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9910 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_pc
9911 and sw_breakpoint_from_kind to increment the pc.
9912 (linux_breakpoint_kind_from_pc): New function.
9913 (linux_sw_breakpoint_from_kind): New function.
9914 (struct target_ops) <sw_breakpoint_from_kind>: Initialize field.
9915 (initialize_low): Call breakpoint_kind_from_pc and
9916 sw_breakpoint_from_kind to replace breakpoint_data/len.
9917 * linux-low.h (struct linux_target_ops) <breakpoint_kind_from_pc>:
9918 New field.
9919 (struct linux_target_ops) <sw_breakpoint_from_kind>: Likewise.
9920 * linux-m32r-low.c (m32r_sw_breakpoint_from_kind): New function.
9921 (struct linux_target_ops) <breakpoint>: Remove.
9922 (struct linux_target_ops) <breakpoint_len>: Remove.
9923 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9924 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9925 * linux-m68k-low.c (m68k_sw_breakpoint_from_kind): New function.
9926 (struct linux_target_ops) <breakpoint>: Remove.
9927 (struct linux_target_ops) <breakpoint_len>: Remove.
9928 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9929 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9930 * linux-mips-low.c (mips_sw_breakpoint_from_kind): New function.
9931 (struct linux_target_ops) <breakpoint>: Remove.
9932 (struct linux_target_ops) <breakpoint_len>: Remove.
9933 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9934 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9935 * linux-nios2-low.c (nios2_sw_breakpoint_from_kind): New function.
9936 (struct linux_target_ops) <breakpoint>: Remove.
9937 (struct linux_target_ops) <breakpoint_len>: Remove.
9938 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9939 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9940 * linux-ppc-low.c (ppc_sw_breakpoint_from_kind): New function.
9941 (struct linux_target_ops) <breakpoint>: Remove.
9942 (struct linux_target_ops) <breakpoint_len>: Remove.
9943 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9944 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9945 * linux-s390-low.c (s390_sw_breakpoint_from_kind): New function.
9946 (struct linux_target_ops) <breakpoint>: Remove.
9947 (struct linux_target_ops) <breakpoint_len>: Remove.
9948 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9949 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9950 * linux-sh-low.c (sh_sw_breakpoint_from_kind): New function.
9951 (struct linux_target_ops) <breakpoint>: Remove.
9952 (struct linux_target_ops) <breakpoint_len>: Remove.
9953 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9954 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9955 * linux-sparc-low.c (sparc_sw_breakpoint_from_kind): New function.
9956 (struct linux_target_ops) <breakpoint>: Remove.
9957 (struct linux_target_ops) <breakpoint_len>: Remove.
9958 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9959 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9960 * linux-tic6x-low.c (tic6x_sw_breakpoint_from_kind): New function.
9961 (struct linux_target_ops) <breakpoint>: Remove.
9962 (struct linux_target_ops) <breakpoint_len>: Remove.
9963 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9964 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9965 * linux-tile-low.c (tile_sw_breakpoint_from_kind): New function.
9966 * linux-x86-low.c (x86_sw_breakpoint_from_kind): New function.
9967 (struct linux_target_ops) <breakpoint>: Remove.
9968 (struct linux_target_ops) <breakpoint_len>: Remove.
9969 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9970 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9971 * linux-xtensa-low.c (xtensa_sw_breakpoint_from_kind) New function.
9972 (struct linux_target_ops) <breakpoint>: Remove.
9973 (struct linux_target_ops) <breakpoint_len>: Remove.
9974 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9975 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9976
9977 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9978
9979 * linux-cris-low.c (cris_get_pc): Remove void arg.
9980
9981 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
9982
9983 * gdbserver/nto-low.c (nto_insert_point, nto_remove_point): Fix
9984 variable name.
9985
9986 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
9987
9988 * inferiors.c (thread_pid_matches_callback): New function.
9989 (find_thread_process): New function.
9990 (remove_thread): Reset current_thread.
9991 (remove_process): Assert threads have been removed first.
9992
9993 2015-10-15 Yao Qi <yao.qi@linaro.org>
9994
9995 * linux-aarch64-low.c (aarch64_insert_point): Set len to 2
9996 if it is 3.
9997 (aarch64_remove_point): Likewise.
9998 * regcache.c (regcache_register_size): New function.
9999
10000 2015-10-12 Yao Qi <yao.qi@linaro.org>
10001
10002 * linux-aarch64-low.c: Update all callers as emit_load_store
10003 is renamed to aarch64_emit_load_store.
10004
10005 2015-10-12 Yao Qi <yao.qi@linaro.org>
10006
10007 * linux-aarch64-low.c: Update all callers of function renaming
10008 from emit_insn to aarch64_emit_insn.
10009
10010 2015-10-12 Yao Qi <yao.qi@linaro.org>
10011
10012 * linux-aarch64-low.c (enum aarch64_opcodes): Move to
10013 arch/aarch64-insn.h.
10014 (struct aarch64_memory_operand): Likewise.
10015 (ENCODE): Likewise.
10016 (emit_insn): Move to arch/aarch64-insn.c.
10017 (emit_b, emit_bcond, emit_cb, emit_tb): Remove.
10018 (emit_load_store): Move to arch/aarch64-insn.c.
10019 (emit_ldr, emit_ldrb, emit_ldrsw, emit_nop): Remove.
10020 (can_encode_int32): Remove.
10021
10022 2015-10-12 Yao Qi <yao.qi@linaro.org>
10023
10024 * linux-aarch64-low.c (extract_signed_bitfield): Remove.
10025 (aarch64_decode_ldr_literal): Move to gdb/arch/aarch64-insn.c.
10026 (aarch64_relocate_instruction): Likewise.
10027 (struct aarch64_insn_data): Move to gdb/arch/aarch64-insn.h.
10028 (struct aarch64_insn_visitor): Likewise.
10029
10030 2015-10-12 Yao Qi <yao.qi@linaro.org>
10031
10032 * linux-aarch64-low.c (struct aarch64_insn_data): New.
10033 (struct aarch64_insn_visitor): New.
10034 (struct aarch64_insn_relocation_data): New.
10035 (aarch64_ftrace_insn_reloc_b): New function.
10036 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
10037 (aarch64_ftrace_insn_reloc_cb): Likewise.
10038 (aarch64_ftrace_insn_reloc_tb): Likewise.
10039 (aarch64_ftrace_insn_reloc_adr): Likewise.
10040 (aarch64_ftrace_insn_reloc_ldr_literal): Likewise.
10041 (aarch64_ftrace_insn_reloc_others): Likewise.
10042 (visitor): New.
10043 (aarch64_relocate_instruction): Use visitor.
10044
10045 2015-10-12 Yao Qi <yao.qi@linaro.org>
10046
10047 * linux-aarch64-low.c (aarch64_relocate_instruction): Return
10048 int. Add argument buf.
10049 (aarch64_install_fast_tracepoint_jump_pad): Pass buf to
10050 aarch64_relocate_instruction.
10051
10052 2015-10-12 Yao Qi <yao.qi@linaro.org>
10053
10054 * linux-aarch64-low.c (aarch64_relocate_instruction): Add
10055 argument insn. Remove local variable insn. Don't call
10056 target_read_uint32.
10057 (aarch64_install_fast_tracepoint_jump_pad): Call
10058 target_read_uint32.
10059
10060 2015-09-30 Yao Qi <yao.qi@linaro.org>
10061
10062 * linux-aarch64-low.c (emit_movk): Shorten a long line.
10063 (emit_load_store_pair): Likewise.
10064
10065 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
10066
10067 * dll.c (match_dll): Add cast(s).
10068 (unloaded_dll): Likewise.
10069 * linux-low.c (second_thread_of_pid_p): Likewise.
10070 (delete_lwp_callback): Likewise.
10071 (count_events_callback): Likewise.
10072 (select_event_lwp_callback): Likewise.
10073 (linux_set_resume_request): Likewise.
10074 * server.c (accumulate_file_name_length): Likewise.
10075 (emit_dll_description): Likewise.
10076 (handle_qxfer_threads_worker): Likewise.
10077 (visit_actioned_threads): Likewise.
10078 * thread-db.c (any_thread_of): Likewise.
10079 * tracepoint.c (same_process_p): Likewise.
10080 (match_blocktype): Likewise.
10081 (build_traceframe_info_xml): Likewise.
10082
10083 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
10084
10085 * ax.c (gdb_parse_agent_expr): Add cast to allocation result
10086 assignment.
10087 (gdb_unparse_agent_expr): Likewise.
10088 * hostio.c (require_data): Likewise.
10089 (handle_pread): Likewise.
10090 * linux-low.c (disable_regset): Likewise.
10091 (fetch_register): Likewise.
10092 (store_register): Likewise.
10093 (get_dynamic): Likewise.
10094 (linux_qxfer_libraries_svr4): Likewise.
10095 * mem-break.c (delete_fast_tracepoint_jump): Likewise.
10096 (set_fast_tracepoint_jump): Likewise.
10097 (uninsert_fast_tracepoint_jumps_at): Likewise.
10098 (reinsert_fast_tracepoint_jumps_at): Likewise.
10099 (validate_inserted_breakpoint): Likewise.
10100 (clone_agent_expr): Likewise.
10101 * regcache.c (init_register_cache): Likewise.
10102 * remote-utils.c (putpkt_binary_1): Likewise.
10103 (decode_M_packet): Likewise.
10104 (decode_X_packet): Likewise.
10105 (look_up_one_symbol): Likewise.
10106 (relocate_instruction): Likewise.
10107 (monitor_output): Likewise.
10108 * server.c (handle_search_memory): Likewise.
10109 (handle_qxfer_exec_file): Likewise.
10110 (handle_qxfer_libraries): Likewise.
10111 (handle_qxfer): Likewise.
10112 (handle_query): Likewise.
10113 (handle_v_cont): Likewise.
10114 (handle_v_run): Likewise.
10115 (captured_main): Likewise.
10116 * target.c (write_inferior_memory): Likewise.
10117 * thread-db.c (try_thread_db_load_from_dir): Likewise.
10118 * tracepoint.c (init_trace_buffer): Likewise.
10119 (add_tracepoint_action): Likewise.
10120 (add_traceframe): Likewise.
10121 (add_traceframe_block): Likewise.
10122 (cmd_qtdpsrc): Likewise.
10123 (cmd_qtdv): Likewise.
10124 (cmd_qtstatus): Likewise.
10125 (response_source): Likewise.
10126 (response_tsv): Likewise.
10127 (cmd_qtnotes): Likewise.
10128 (gdb_collect): Likewise.
10129 (initialize_tracepoint): Likewise.
10130
10131 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
10132
10133 * linux-aarch64-low-.c: Include ax.h and tracepoint.h.
10134 (enum aarch64_opcodes) <RET>, <SUBS>, <AND>, <ORR>, <ORN>,
10135 <EOR>, <LSLV>, <LSRV>, <ASRV>, <SBFM>, <UBFM>, <CSINC>, <MUL>,
10136 <NOP>: New.
10137 (enum aarch64_condition_codes): New enum.
10138 (w0): New static global.
10139 (fp): Likewise.
10140 (lr): Likewise.
10141 (struct aarch64_memory_operand) <type>: New
10142 MEMORY_OPERAND_POSTINDEX type.
10143 (postindex_memory_operand): New helper function.
10144 (emit_ret): New function.
10145 (emit_load_store_pair): New function, factored out of emit_stp
10146 with support for MEMORY_OPERAND_POSTINDEX.
10147 (emit_stp): Rewrite using emit_load_store_pair.
10148 (emit_ldp): New function.
10149 (emit_load_store): Likewise.
10150 (emit_ldr): Mention post-index instruction in comment.
10151 (emit_ldrh): New function.
10152 (emit_ldrb): New function.
10153 (emit_ldrsw): Mention post-index instruction in comment.
10154 (emit_str): Likewise.
10155 (emit_subs): New function.
10156 (emit_cmp): Likewise.
10157 (emit_and): Likewise.
10158 (emit_orr): Likewise.
10159 (emit_orn): Likewise.
10160 (emit_eor): Likewise.
10161 (emit_mvn): Likewise.
10162 (emit_lslv): Likewise.
10163 (emit_lsrv): Likewise.
10164 (emit_asrv): Likewise.
10165 (emit_mul): Likewise.
10166 (emit_sbfm): Likewise.
10167 (emit_sbfx): Likewise.
10168 (emit_ubfm): Likewise.
10169 (emit_ubfx): Likewise.
10170 (emit_csinc): Likewise.
10171 (emit_cset): Likewise.
10172 (emit_nop): Likewise.
10173 (emit_ops_insns): New helper function.
10174 (emit_pop): Likewise.
10175 (emit_push): Likewise.
10176 (aarch64_emit_prologue): New function.
10177 (aarch64_emit_epilogue): Likewise.
10178 (aarch64_emit_add): Likewise.
10179 (aarch64_emit_sub): Likewise.
10180 (aarch64_emit_mul): Likewise.
10181 (aarch64_emit_lsh): Likewise.
10182 (aarch64_emit_rsh_signed): Likewise.
10183 (aarch64_emit_rsh_unsigned): Likewise.
10184 (aarch64_emit_ext): Likewise.
10185 (aarch64_emit_log_not): Likewise.
10186 (aarch64_emit_bit_and): Likewise.
10187 (aarch64_emit_bit_or): Likewise.
10188 (aarch64_emit_bit_xor): Likewise.
10189 (aarch64_emit_bit_not): Likewise.
10190 (aarch64_emit_equal): Likewise.
10191 (aarch64_emit_less_signed): Likewise.
10192 (aarch64_emit_less_unsigned): Likewise.
10193 (aarch64_emit_ref): Likewise.
10194 (aarch64_emit_if_goto): Likewise.
10195 (aarch64_emit_goto): Likewise.
10196 (aarch64_write_goto_address): Likewise.
10197 (aarch64_emit_const): Likewise.
10198 (aarch64_emit_call): Likewise.
10199 (aarch64_emit_reg): Likewise.
10200 (aarch64_emit_pop): Likewise.
10201 (aarch64_emit_stack_flush): Likewise.
10202 (aarch64_emit_zero_ext): Likewise.
10203 (aarch64_emit_swap): Likewise.
10204 (aarch64_emit_stack_adjust): Likewise.
10205 (aarch64_emit_int_call_1): Likewise.
10206 (aarch64_emit_void_call_2): Likewise.
10207 (aarch64_emit_eq_goto): Likewise.
10208 (aarch64_emit_ne_goto): Likewise.
10209 (aarch64_emit_lt_goto): Likewise.
10210 (aarch64_emit_le_goto): Likewise.
10211 (aarch64_emit_gt_goto): Likewise.
10212 (aarch64_emit_ge_got): Likewise.
10213 (aarch64_emit_ops_impl): New static global variable.
10214 (aarch64_emit_ops): New target function, return
10215 &aarch64_emit_ops_impl.
10216 (struct linux_target_ops): Install it.
10217
10218 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
10219
10220 * Makefile.in (linux-aarch64-ipa.o, aarch64-ipa.o): New rules.
10221 * configure.srv (aarch64*-*-linux*): Add linux-aarch64-ipa.o and
10222 aarch64-ipa.o.
10223 * linux-aarch64-ipa.c: New file.
10224 * linux-aarch64-low.c: Include arch/aarch64-insn.h, inttypes.h
10225 and endian.h.
10226 (aarch64_get_thread_area): New target method.
10227 (extract_signed_bitfield): New helper function.
10228 (aarch64_decode_ldr_literal): New function.
10229 (enum aarch64_opcodes): New enum.
10230 (struct aarch64_register): New struct.
10231 (struct aarch64_operand): New struct.
10232 (x0): New static global.
10233 (x1): Likewise.
10234 (x2): Likewise.
10235 (x3): Likewise.
10236 (x4): Likewise.
10237 (w2): Likewise.
10238 (ip0): Likewise.
10239 (sp): Likewise.
10240 (xzr): Likewise.
10241 (aarch64_register): New helper function.
10242 (register_operand): Likewise.
10243 (immediate_operand): Likewise.
10244 (struct aarch64_memory_operand): New struct.
10245 (offset_memory_operand): New helper function.
10246 (preindex_memory_operand): Likewise.
10247 (enum aarch64_system_control_registers): New enum.
10248 (ENCODE): New macro.
10249 (emit_insn): New helper function.
10250 (emit_b): New function.
10251 (emit_bcond): Likewise.
10252 (emit_cb): Likewise.
10253 (emit_tb): Likewise.
10254 (emit_blr): Likewise.
10255 (emit_stp): Likewise.
10256 (emit_ldp_q_offset): Likewise.
10257 (emit_stp_q_offset): Likewise.
10258 (emit_load_store): Likewise.
10259 (emit_ldr): Likewise.
10260 (emit_ldrsw): Likewise.
10261 (emit_str): Likewise.
10262 (emit_ldaxr): Likewise.
10263 (emit_stxr): Likewise.
10264 (emit_stlr): Likewise.
10265 (emit_data_processing_reg): Likewise.
10266 (emit_data_processing): Likewise.
10267 (emit_add): Likewise.
10268 (emit_sub): Likewise.
10269 (emit_mov): Likewise.
10270 (emit_movk): Likewise.
10271 (emit_mov_addr): Likewise.
10272 (emit_mrs): Likewise.
10273 (emit_msr): Likewise.
10274 (emit_sevl): Likewise.
10275 (emit_wfe): Likewise.
10276 (append_insns): Likewise.
10277 (can_encode_int32_in): New helper function.
10278 (aarch64_relocate_instruction): New function.
10279 (aarch64_install_fast_tracepoint_jump_pad): Likewise.
10280 (aarch64_get_min_fast_tracepoint_insn_len): Likewise.
10281 (struct linux_target_ops): Install aarch64_get_thread_area,
10282 aarch64_install_fast_tracepoint_jump_pad and
10283 aarch64_get_min_fast_tracepoint_insn_len.
10284
10285 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
10286
10287 * Makefile.in (aarch64-insn.o): New rule.
10288 * configure.srv (aarch64*-*-linux*): Add aarch64-insn.o.
10289
10290 2015-09-21 Yao Qi <yao.qi@linaro.org>
10291
10292 * ax.c [!IN_PROCESS_AGENT] (gdb_agent_op_sizes): Define it.
10293
10294 2015-09-21 Yao Qi <yao.qi@linaro.org>
10295
10296 * tracepoint.c (max_jump_pad_size): Remove.
10297
10298 2015-09-18 Yao Qi <yao.qi@linaro.org>
10299
10300 * linux-aarch64-low.c: Don't include sys/uio.h.
10301 (ps_get_thread_area): Call aarch64_ps_get_thread_area.
10302
10303 2015-09-16 Wei-cheng Wang <cole945@gmail.com>
10304
10305 * tracepoint.c (eval_result_type): Change prototype.
10306 (condition_true_at_tracepoint): Fix argument to compiled_cond.
10307
10308 2015-09-15 Pedro Alves <palves@redhat.com>
10309
10310 * remote-utils.c (prepare_resume_reply) <TARGET_WAITKIND_EXECD>:
10311 Check whether to report exec events instead of checking whether
10312 multiprocess is enabled.
10313
10314 2015-09-15 Pedro Alves <palves@redhat.com>
10315
10316 PR remote/18965
10317 * remote-utils.c (prepare_resume_reply): Merge
10318 TARGET_WAITKIND_VFORK_DONE switch case with the
10319 TARGET_WAITKIND_FORKED case.
10320
10321 2015-09-15 Yao Qi <yao.qi@linaro.org>
10322
10323 * server.c (handle_query): Check string comparison using
10324 "else if" instead of "if".
10325
10326 2015-09-15 Yao Qi <yao.qi@linaro.org>
10327
10328 * server.c (vCont_supported): New global variable.
10329 (handle_query): Set vCont_supported to 1 if "vContSupported+"
10330 matches. Append ";vContSupported+" to own_buf.
10331 (handle_v_requests): Append ";s;S" to own_buf if target supports
10332 hardware single step or vCont_supported is false.
10333 (capture_main): Set vCont_supported to zero.
10334
10335 2015-09-15 Yao Qi <yao.qi@linaro.org>
10336
10337 * linux-low.c (linux_supports_conditional_breakpoints): Rename
10338 it to ...
10339 (linux_supports_hardware_single_step): ... New function.
10340 (linux_target_ops): Update.
10341 * lynx-low.c (lynx_target_ops): Set field
10342 supports_hardware_single_step to target_can_do_hardware_single_step.
10343 * nto-low.c (nto_target_ops): Likewise.
10344 * spu-low.c (spu_target_ops): Likewise.
10345 * win32-low.c (win32_target_ops): Likewise.
10346 * target.c (target_can_do_hardware_single_step): New function.
10347 * target.h (struct target_ops) <supports_conditional_breakpoints>:
10348 Remove. <supports_hardware_single_step>: New field.
10349 (target_supports_conditional_breakpoints): Remove.
10350 (target_supports_hardware_single_step): New macro.
10351 (target_can_do_hardware_single_step): Declare.
10352 * server.c (handle_query): Use target_supports_hardware_single_step
10353 instead of target_supports_conditional_breakpoints.
10354
10355 2015-09-15 Yao Qi <yao.qi@linaro.org>
10356
10357 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): New
10358 function.
10359 (struct linux_target_ops the_low_target): Install
10360 aarch64_linux_siginfo_fixup.
10361
10362 2015-09-11 Don Breazeal <donb@codesourcery.com>
10363 Luis Machado <lgustavo@codesourcery.com>
10364
10365 * linux-low.c (linux_mourn): Static declaration.
10366 (linux_arch_setup): Move in front of
10367 handle_extended_wait.
10368 (linux_arch_setup_thread): New function.
10369 (handle_extended_wait): Handle exec events. Call
10370 linux_arch_setup_thread. Make event_lwp argument a
10371 pointer-to-a-pointer.
10372 (check_zombie_leaders): Do not check stopped threads.
10373 (linux_low_ptrace_options): Add PTRACE_O_TRACEEXEC.
10374 (linux_low_filter_event): Add lwp and thread for exec'ing
10375 non-leader thread if leader thread has been deleted.
10376 Refactor code into linux_arch_setup_thread and call it.
10377 Pass child lwp pointer by reference to handle_extended_wait.
10378 (linux_wait_for_event_filtered): Update comment.
10379 (linux_wait_1): Prevent clobbering exec event status.
10380 (linux_supports_exec_events): New function.
10381 (linux_target_ops) <supports_exec_events>: Initialize new member.
10382 * lynx-low.c (lynx_target_ops) <supports_exec_events>: Initialize
10383 new member.
10384 * remote-utils.c (prepare_resume_reply): New stop reason 'exec'.
10385 * server.c (report_exec_events): New global variable.
10386 (handle_query): Handle qSupported query for exec-events feature.
10387 (captured_main): Initialize report_exec_events.
10388 * server.h (report_exec_events): Declare new global variable.
10389 * target.h (struct target_ops) <supports_exec_events>: New
10390 member.
10391 (target_supports_exec_events): New macro.
10392 * win32-low.c (win32_target_ops) <supports_exec_events>:
10393 Initialize new member.
10394
10395 2015-09-09 Markus Metzger <markus.t.metzger@intel.com>
10396
10397 * linux-low.c (linux_low_enable_btrace): Remove.
10398 (linux_target_ops): Replace linux_low_enable_btrace with
10399 linux_enable_btrace.
10400
10401 2015-09-03 Yao Qi <yao.qi@linaro.org>
10402
10403 * linux-aarch64-low.c (aarch64_insert_point): Call
10404 aarch64_handle_watchpoint if aarch64_linux_region_ok_for_watchpoint
10405 returns true.
10406
10407 2015-08-27 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
10408
10409 * linux-low.c (check_stopped_by_breakpoint): Use
10410 GDB_ARCH_IS_TRAP_BRKPT instead of GDB_ARCH_TRAP_BRKPT.
10411
10412 2015-08-27 Pedro Alves <palves@redhat.com>
10413
10414 * proc-service.c (ps_pdwrite): Return PS_ERR/PS_OK explicily.
10415
10416 2015-08-26 Simon Marchi <simon.marchi@ericsson.com>
10417
10418 * ax.c (gdb_parse_agent_expr): Replace xmalloc-family function with
10419 the XNEW-family equivalent.
10420 (compile_bytecodes): Likewise.
10421 * dll.c (loaded_dll): Likewise.
10422 * event-loop.c (append_callback_event): Likewise.
10423 (create_file_handler): Likewise.
10424 (create_file_event): Likewise.
10425 * hostio.c (handle_open): Likewise.
10426 * inferiors.c (add_thread): Likewise.
10427 (add_process): Likewise.
10428 * linux-aarch64-low.c (aarch64_linux_new_process): Likewise.
10429 * linux-arm-low.c (arm_new_process): Likewise.
10430 (arm_new_thread): Likewise.
10431 * linux-low.c (add_to_pid_list): Likewise.
10432 (linux_add_process): Likewise.
10433 (handle_extended_wait): Likewise.
10434 (add_lwp): Likewise.
10435 (enqueue_one_deferred_signal): Likewise.
10436 (enqueue_pending_signal): Likewise.
10437 (linux_resume_one_lwp_throw): Likewise.
10438 (linux_resume_one_thread): Likewise.
10439 (linux_read_memory): Likewise.
10440 (linux_write_memory): Likewise.
10441 * linux-mips-low.c (mips_linux_new_process): Likewise.
10442 (mips_linux_new_thread): Likewise.
10443 (mips_add_watchpoint): Likewise.
10444 * linux-x86-low.c (initialize_low_arch): Likewise.
10445 * lynx-low.c (lynx_add_process): Likewise.
10446 * mem-break.c (set_raw_breakpoint_at): Likewise.
10447 (set_breakpoint): Likewise.
10448 (add_condition_to_breakpoint): Likewise.
10449 (add_commands_to_breakpoint): Likewise.
10450 (clone_agent_expr): Likewise.
10451 (clone_one_breakpoint): Likewise.
10452 * regcache.c (new_register_cache): Likewise.
10453 * remote-utils.c (look_up_one_symbol): Likewise.
10454 * server.c (queue_stop_reply): Likewise.
10455 (start_inferior): Likewise.
10456 (queue_stop_reply_callback): Likewise.
10457 (handle_target_event): Likewise.
10458 * spu-low.c (fetch_ppc_memory): Likewise.
10459 (store_ppc_memory): Likewise.
10460 * target.c (set_target_ops): Likewise.
10461 * thread-db.c (thread_db_load_search): Likewise.
10462 (try_thread_db_load_1): Likewise.
10463 * tracepoint.c (add_tracepoint): Likewise.
10464 (add_tracepoint_action): Likewise.
10465 (create_trace_state_variable): Likewise.
10466 (cmd_qtdpsrc): Likewise.
10467 (cmd_qtro): Likewise.
10468 (add_while_stepping_state): Likewise.
10469 * win32-low.c (child_add_thread): Likewise.
10470 (get_image_name): Likewise.
10471
10472 2015-08-25 Yao Qi <yao.qi@linaro.org>
10473
10474 * linux-aarch64-low.c (aarch64_linux_new_thread): Remove.
10475
10476 2015-08-25 Yao Qi <yao.qi@linaro.org>
10477
10478 * Makefile.in (aarch64-linux.o): New rule.
10479 * configure.srv (aarch64*-*-linux*): Append aarch64-linux.o to
10480 srv_tgtobj.
10481 * linux-aarch64-low.c: Include nat/aarch64-linux.h.
10482 (aarch64_init_debug_reg_state): Make it extern.
10483 (aarch64_linux_prepare_to_resume): Remove.
10484
10485 2015-08-25 Yao Qi <yao.qi@linaro.org>
10486
10487 * linux-aarch64-low.c (aarch64_linux_prepare_to_resume): Use
10488 lwp_arch_private_info and ptid_of_lwp.
10489
10490 2015-08-25 Yao Qi <yao.qi@linaro.org>
10491
10492 * linux-aarch64-low.c (aarch64_get_debug_reg_state): Add argument pid.
10493 Find proc_info by find_process_pid. All callers updated.
10494
10495 2015-08-25 Yao Qi <yao.qi@linaro.org>
10496
10497 * linux-aarch64-low.c (struct arch64_dr_update_callback_param):
10498 Remove.
10499 (debug_reg_change_callback): Remove.
10500 (aarch64_notify_debug_reg_change): Remove.
10501
10502 2015-08-25 Yao Qi <yao.qi@linaro.org>
10503
10504 * linux-aarch64-low.c (aarch64_notify_debug_reg_change):
10505 Call current_lwp_ptid.
10506
10507 2015-08-25 Yao Qi <yao.qi@linaro.org>
10508
10509 * linux-aarch64-low.c (debug_reg_change_callback): Use
10510 debug_printf.
10511
10512 2015-08-25 Yao Qi <yao.qi@linaro.org>
10513
10514 * linux-aarch64-low.c (debug_reg_change_callback): Use phex.
10515
10516 2015-08-25 Yao Qi <yao.qi@linaro.org>
10517
10518 * linux-aarch64-low.c (debug_reg_change_callback): Remove comments.
10519
10520 2015-08-25 Yao Qi <yao.qi@linaro.org>
10521
10522 * linux-aarch64-low.c (debug_reg_change_callback): Re-indent
10523 the code.
10524
10525 2015-08-25 Yao Qi <yao.qi@linaro.org>
10526
10527 * linux-aarch64-low.c (aarch64_dr_update_callback_param) <pid>:
10528 Remove.
10529 (debug_reg_change_callback): Remove argument entry and add argument
10530 lwp. Remove local variable thread. Don't print thread id in the
10531 debugging output. Don't check whether pid of thread equals to pid.
10532 (aarch64_notify_debug_reg_change): Don't set param.pid. Call
10533 iterate_over_lwps instead find_inferior.
10534
10535 2015-08-24 Pedro Alves <palves@redhat.com>
10536
10537 * inferiors.c (get_first_process): New function.
10538 * inferiors.h (get_first_process): New declaration.
10539 * remote-utils.c (read_ptid): Default to the first process in the
10540 list, instead of to the current thread's process.
10541
10542 2015-08-24 Pedro Alves <palves@redhat.com>
10543
10544 * debug.c: Include gdb_sys_time.h instead of sys/time.h.
10545 * event-loop.c: Likewise.
10546 * remote-utils.c: Likewise.
10547 * tracepoint.c: Likewise.
10548
10549 2015-08-24 Pedro Alves <palves@redhat.com>
10550
10551 * spu-low.c (spu_request_interrupt): Use lwpid_of instead of
10552 ptid_get_lwp.
10553
10554 2015-08-21 Pedro Alves <palves@redhat.com>
10555
10556 * ax.c (gdb_eval_agent_expr): Return expr_eval_unhandled_opcode
10557 instead of literal 1.
10558
10559 2015-08-21 Pedro Alves <palves@redhat.com>
10560
10561 * tdesc.c (default_description): Explicitly zero-initialize.
10562
10563 2015-08-21 Pedro Alves <palves@redhat.com>
10564
10565 PR gdb/18749
10566 * inferiors.c (remove_thread): Discard any pending stop reply for
10567 this thread.
10568 * server.c (remove_all_on_match_pid): Rename to ...
10569 (remove_all_on_match_ptid): ... this. Work with a filter ptid
10570 instead of a pid.
10571 (discard_queued_stop_replies): Change parameter to a ptid. Now
10572 extern.
10573 (handle_v_kill, kill_inferior_callback, captured_main)
10574 (process_serial_event): Adjust.
10575 * server.h (discard_queued_stop_replies): Declare.
10576
10577 2015-08-21 Pedro Alves <palves@redhat.com>
10578
10579 * linux-low.c (wait_for_sigstop): Always switch to no thread
10580 selected if the previously current thread dies.
10581 * lynx-low.c (lynx_request_interrupt): Use the first thread's
10582 process instead of the current thread's.
10583 * remote-utils.c (input_interrupt): Don't check if there's no
10584 current thread.
10585 * server.c (gdb_read_memory, gdb_write_memory): If setting the
10586 current thread to the general thread fails, error out.
10587 (handle_qxfer_auxv, handle_qxfer_libraries)
10588 (handle_qxfer_libraries_svr4, handle_qxfer_siginfo)
10589 (handle_qxfer_spu, handle_qxfer_statictrace, handle_qxfer_fdpic)
10590 (handle_query): Check if there's a thread selected instead of
10591 checking whether there's any thread in the thread list.
10592 (handle_qxfer_threads, handle_qxfer_btrace)
10593 (handle_qxfer_btrace_conf): Don't error out early if there's no
10594 thread in the thread list.
10595 (handle_v_cont, myresume): Don't set the current thread to the
10596 continue thread.
10597 (process_serial_event) <Hg handling>: Also set thread_id if the
10598 previous general thread is still alive.
10599 (process_serial_event) <g/G handling>: If setting the current
10600 thread to the general thread fails, error out.
10601 * spu-low.c (spu_resume, spu_request_interrupt): Use the first
10602 thread's lwp instead of the current thread's.
10603 * target.c (set_desired_thread): If the desired thread was not
10604 found, leave the current thread pointing to NULL. Return an int
10605 (boolean) indicating success.
10606 * target.h (set_desired_thread): Change return type to int.
10607
10608 2015-08-20 Max Filippov <jcmvbkbc@gmail.com>
10609
10610 * configure.srv (xtensa*-*-linux*): Add srv_linux_thread_db=yes.
10611 * linux-xtensa-low.c (arch/xtensa.h gdb_proc_service.h): New
10612 #includes.
10613 (ps_get_thread_area): New function.
10614
10615 2015-08-19 Gary Benson <gbenson@redhat.com>
10616
10617 * hostio.c (handle_pread): Do not attempt to read more data
10618 than hostio_reply_with_data can fit in a packet.
10619
10620 2015-08-18 Joel Brobecker <brobecker@adacore.com>
10621
10622 * linux-aarch32-low.c (NT_ARM_VFP): Define if not already defined.
10623
10624 2015-08-14 Matthew Fortune <matthew.fortune@imgtec.com>
10625
10626 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP_REL.
10627
10628 2015-08-06 Pedro Alves <palves@redhat.com>
10629
10630 * tracepoint.c (expr_eval_result): Now an int.
10631
10632 2015-08-06 Pedro Alves <palves@redhat.com>
10633
10634 * gdbthread.h (struct regcache): Forward declare.
10635 (struct thread_info) <regcache_data>: Now a struct regcache
10636 pointer.
10637 * inferiors.c (inferior_regcache_data)
10638 (set_inferior_regcache_data): Now work with struct regcache
10639 pointers.
10640 * inferiors.h (struct regcache): Forward declare.
10641 (inferior_regcache_data, set_inferior_regcache_data): Now work
10642 with struct regcache pointers.
10643 * regcache.c (get_thread_regcache, regcache_invalidate_thread)
10644 (free_register_cache_thread): Remove struct regcache pointer
10645 casts.
10646
10647 2015-08-06 Pedro Alves <palves@redhat.com>
10648
10649 * server.c (captured_main): On error, print the exception message
10650 to stderr, and if run_once is set, throw a quit.
10651
10652 2015-08-06 Pedro Alves <palves@redhat.com>
10653
10654 * linux-low.c (move_out_of_jump_pad_callback): Temporarily switch
10655 the current thread.
10656
10657 2015-08-06 Pedro Alves <palves@redhat.com>
10658
10659 * linux-low.c (linux_write_memory): Rewrite debug output to avoid
10660 reading beyond the passed in buffer length.
10661
10662 2015-08-06 Pierre Langlois <pierre.langlois@arm.com>
10663
10664 * tracepoint.c (symbol_list) <required>: Remove.
10665
10666 2015-08-06 Pedro Alves <palves@redhat.com>
10667
10668 * linux-low.c (handle_extended_wait): Set the fork child's suspend
10669 count if stopping and suspending threads.
10670 (check_stopped_by_breakpoint): If stopped by trace, set the LWP's
10671 stop reason to TARGET_STOPPED_BY_SINGLE_STEP.
10672 (linux_detach): Complete an ongoing step-over.
10673 (lwp_suspended_inc, lwp_suspended_decr): New functions. Use
10674 throughout.
10675 (resume_stopped_resumed_lwps): Don't resume a suspended thread.
10676 (linux_wait_1): If passing a signal to the inferior after
10677 finishing a step-over, unsuspend and re-resume all lwps. If we
10678 see a single-step event but the thread should be continuing, don't
10679 pass the trap to gdb.
10680 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback): Use
10681 internal_error instead of gdb_assert.
10682 (enqueue_pending_signal): New function.
10683 (check_ptrace_stopped_lwp_gone): Add debug output.
10684 (start_step_over): Use internal_error instead of gdb_assert.
10685 (complete_ongoing_step_over): New function.
10686 (linux_resume_one_thread): Don't resume a suspended thread.
10687 (proceed_one_lwp): If the LWP is stepping over a breakpoint, reset
10688 it stepping.
10689
10690 2015-08-06 Pedro Alves <palves@redhat.com>
10691
10692 * linux-low.c (add_lwp): Set waitstatus to TARGET_WAITKIND_IGNORE.
10693 (linux_thread_alive): Use lwp_is_marked_dead.
10694 (extended_event_reported): Delete.
10695 (linux_wait_1): Check if waitstatus is TARGET_WAITKIND_IGNORE
10696 instead of extended_event_reported.
10697 (mark_lwp_dead): Don't set the 'dead' flag. Store the waitstatus
10698 as well.
10699 (lwp_is_marked_dead): New function.
10700 (lwp_running): Use lwp_is_marked_dead.
10701 * linux-low.h: Delete 'dead' field, and update 'waitstatus's
10702 comment.
10703
10704 2015-08-06 Pedro Alves <palves@redhat.com>
10705
10706 * linux-low.c (linux_wait_1): Move fork event output out of the
10707 !report_to_gdb check. Pass event_child->waitstatus to
10708 target_waitstatus_to_string instead of ourstatus.
10709
10710 2015-08-04 Yao Qi <yao.qi@linaro.org>
10711
10712 * linux-aarch64-low.c (aarch64_supports_tracepoints): Return 0
10713 if current_thread is 32 bit.
10714
10715 2015-08-04 Yao Qi <yao.qi@linaro.org>
10716
10717 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
10718 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
10719 * server.c (extended_protocol): Remove "static".
10720 * server.h (extended_protocol): Declare it.
10721
10722 2015-08-04 Yao Qi <yao.qi@linaro.org>
10723
10724 * linux-aarch64-low.c (aarch64_get_pc): Get PC register on
10725 both aarch64 and aarch32.
10726 (aarch64_set_pc): Likewise.
10727
10728 2015-08-04 Yao Qi <yao.qi@linaro.org>
10729
10730 * configure.srv (case aarch64*-*-linux*): Append arm-with-neon.o
10731 to srv_regobj and append arm-core.xml arm-vfpv3.xml and
10732 arm-with-neon.xml to srv_xmlfiles.
10733 * linux-aarch64-low.c: Include linux-aarch32-low.h.
10734 (is_64bit_tdesc): New function.
10735 (aarch64_linux_read_description): New function.
10736 (aarch64_arch_setup): Call aarch64_linux_read_description.
10737 (regs_info): Rename to regs_info_aarch64.
10738 (aarch64_regs_info): Return right regs_info.
10739 (initialize_low_arch): Call initialize_low_arch_aarch32.
10740
10741 2015-08-04 Yao Qi <yao.qi@linaro.org>
10742
10743 * configure.srv (srv_tgtobj): Add linux-aarch32-low.o.
10744 * linux-aarch32-low.c: New file.
10745 * linux-aarch32-low.h: New file.
10746 * linux-arm-low.c (arm_fill_gregset): Move it to
10747 linux-aarch32-low.c.
10748 (arm_store_gregset): Likewise.
10749 (arm_fill_vfpregset): Call arm_fill_vfpregset_num
10750 (arm_store_vfpregset): Call arm_store_vfpregset_num.
10751 (arm_arch_setup): Check if PTRACE_GETREGSET works.
10752 (regs_info): Rename to regs_info_arm.
10753 (arm_regs_info): Return regs_info_aarch32 if
10754 have_ptrace_getregset is 1 and target description is
10755 arm_with_neon or arm_with_vfpv3.
10756 (initialize_low_arch): Don't call init_registers_arm_with_neon.
10757 Call initialize_low_arch_aarch32 instead.
10758
10759 2015-08-04 Yao Qi <yao.qi@linaro.org>
10760
10761 * linux-x86-low.c (have_ptrace_getregset): Move it to ...
10762 * linux-low.c: ... here.
10763 * linux-low.h (have_ptrace_getregset): Declare it.
10764
10765 2015-08-04 Pedro Alves <palves@redhat.com>
10766
10767 * thread-db.c (struct thread_db): Use new typedefs.
10768 (try_thread_db_load_1): Define local TDB_DLSYM macro and use it in
10769 CHK calls.
10770 (disable_thread_event_reporting): Cast result of dlsym to
10771 destination function pointer type.
10772 (thread_db_mourn): Use td_ta_delete_ftype.
10773
10774 2015-08-03 Sandra Loosemore <sandra@codesourcery.com>
10775
10776 * linux-nios2-low.c (NIOS2_BREAKPOINT): Conditionalize for
10777 arch variant.
10778 (CDX_BREAKPOINT): Define for R2.
10779 (nios2_breakpoint_at): Check for CDX_BREAKPOINT when R2.
10780 (the_low_target): Add comments.
10781
10782 2015-07-30 Yao Qi <yao.qi@linaro.org>
10783
10784 * linux-arm-low.c (arm_hwcap): Remove it.
10785 (arm_read_description): New local variable arm_hwcap. Don't
10786 set arm_hwcap to zero.
10787
10788 2015-07-30 Yao Qi <yao.qi@linaro.org>
10789
10790 * linux-arm-low.c (arm_fill_wmmxregset): Don't use arm_hwcap.
10791 Use regcache->tdesc instead.
10792 (arm_store_wmmxregset): Likewise.
10793 (arm_fill_vfpregset): Likewise.
10794 (arm_store_vfpregset): Likewise.
10795
10796 2015-07-30 Yao Qi <yao.qi@linaro.org>
10797
10798 * linux-arm-low.c: Include arch/arm.h.
10799 (arm_fill_gregset): Don't use arm_num_regs and arm_regmap.
10800 (arm_store_gregset): Likewise.
10801
10802 2015-07-29 Simon Marchi <simon.marchi@ericsson.com>
10803
10804 * linux-mips-low.c (mips_linux_prepare_to_resume): Add NULL as
10805 ptrace's 4th parameter.
10806
10807 2015-07-27 Yao Qi <yao.qi@linaro.org>
10808
10809 * configure.srv (case aarch64*-*-linux*): Don't set
10810 srv_linux_usrregs.
10811
10812 2015-07-24 Pedro Alves <palves@redhat.c: Likewise.om>
10813
10814 * linux-aarch64-low.c: Include nat/gdb_ptrace.h instead of
10815 sys/ptrace.h.
10816 * linux-arm-low.c: Likewise.
10817 * linux-cris-low.c: Likewise.
10818 * linux-crisv32-low.c: Likewise.
10819 * linux-low.c: Likewise.
10820 * linux-m68k-low.c: Likewise.
10821 * linux-mips-low.c: Likewise.
10822 * linux-nios2-low.c: Likewise.
10823 * linux-s390-low.c: Likewise.
10824 * linux-sparc-low.c: Likewise.
10825 * linux-tic6x-low.c: Likewise.
10826 * linux-tile-low.c: Likewise.
10827 * linux-x86-low.c: Likewise.
10828
10829 2015-07-24 Pedro Alves <palves@redhat.com>
10830
10831 * config.in: Regenerate.
10832 * configure: Regenerate.
10833
10834 2015-07-24 Pedro Alves <palves@redhat.com>
10835
10836 * acinclude.m4: Include ../ptrace.m4.
10837 * configure.ac: Call GDB_AC_PTRACE.
10838 * config.in, configure: Regenerate.
10839
10840 2015-07-24 Yao Qi <yao.qi@linaro.org>
10841
10842 * linux-low.c (linux_create_inferior): Remove setting to
10843 proc->priv->new_inferior.
10844 (linux_attach): Likewise.
10845 (linux_low_filter_event): Likewise.
10846 * linux-low.h (struct process_info_private) <new_inferior>: Remove.
10847
10848 2015-07-24 Yao Qi <yao.qi@linaro.org>
10849
10850 * linux-low.c (linux_arch_setup): New function.
10851 (linux_low_filter_event): If proc->tdesc is NULL and
10852 proc->attached is true, call the_low_target.arch_setup.
10853 Otherwise, keep status pending, and return.
10854 (linux_resume_one_lwp_throw): Don't call get_pc if
10855 thread->while_stepping isn't NULL. Don't call
10856 get_thread_regcache if proc->tdesc is NULL.
10857 (need_step_over_p): Return 0 if proc->tdesc is NULL.
10858 (linux_target_ops): Install arch_setup.
10859 * server.c (start_inferior): Call the_target->arch_setup.
10860 * target.h (struct target_ops) <arch_setup>: New field.
10861 (target_arch_setup): New marco.
10862 * lynx-low.c (lynx_target_ops): Update.
10863 * nto-low.c (nto_target_ops): Update.
10864 * spu-low.c (spu_target_ops): Update.
10865 * win32-low.c (win32_target_ops): Update.
10866
10867 2015-07-24 Yao Qi <yao.qi@linaro.org>
10868
10869 * linux-low.c (linux_add_process): Don't set
10870 proc->priv->new_inferior.
10871 (linux_create_inferior): Set proc->priv->new_inferior to 1.
10872 (linux_attach): Likewise.
10873
10874 2015-07-24 Yao Qi <yao.qi@linaro.org>
10875
10876 * server.c (start_inferior): Code refactor.
10877
10878 2015-07-24 Yao Qi <yao.qi@linaro.org>
10879
10880 * server.c (process_serial_event): Set general_thread.
10881
10882 2015-07-21 Yao Qi <yao.qi@linaro.org>
10883
10884 * linux-aarch64-low.c (aarch64_arch_setup): Remove code and call
10885 aarch64_linux_get_debug_reg_capacity.
10886
10887 2015-07-17 Yao Qi <yao.qi@linaro.org>
10888
10889 * Makefile.in (aarch64-linux-hw-point.o): New rule.
10890 * configure.srv (srv_tgtobj): Append aarch64-linux-hw-point.o.
10891 * linux-aarch64-low.c: Include nat/aarch64-linux-hw-point.h.
10892 (AARCH64_HBP_MAX_NUM): Move to nat/aarch64-linux-hw-point.h.
10893 (AARCH64_HWP_MAX_NUM, AARCH64_HBP_ALIGNMENT): Likewise.
10894 (AARCH64_HWP_ALIGNMENT): Likewise.
10895 (AARCH64_HWP_MAX_LEN_PER_REG): Likewise.
10896 (AARCH64_DEBUG_NUM_SLOTS, AARCH64_DEBUG_ARCH): Likewise.
10897 (aarch64_num_bp_regs, aarch64_num_wp_regs): Likewise.
10898 (AARCH64_DEBUG_ARCH_V8, DR_MARK_ALL_CHANGED): Likewise.
10899 (DR_MARK_N_CHANGED, DR_CLEAR_CHANGED): Likewise.
10900 (DR_HAS_CHANGED, DR_N_HAS_CHANGE): Likewise.
10901 (struct aarch64_debug_reg_state): Likewise.
10902 (struct arch_lwp_info): Likewise.
10903 (aarch64_align_watchpoint): Likewise.
10904 (DR_CONTROL_ENABLED, DR_CONTROL_LENGTH): Likewise.
10905 (aarch64_watchpoint_length): Likewise.
10906 (aarch64_point_encode_ctrl_reg): Likewise
10907 (aarch64_point_is_aligned): Likewise.
10908 (aarch64_align_watchpoint): Likewise.
10909 (aarch64_linux_set_debug_regs):
10910 (aarch64_dr_state_insert_one_point): Likewise.
10911 (aarch64_dr_state_remove_one_point): Likewise.
10912 (aarch64_handle_breakpoint): Likewise.
10913 (aarch64_handle_aligned_watchpoint): Likewise.
10914 (aarch64_handle_unaligned_watchpoint): Likewise.
10915 (aarch64_handle_watchpoint): Likewise.
10916
10917 2015-07-17 Yao Qi <yao.qi@linaro.org>
10918
10919 * linux-aarch64-low.c (aarch64_handle_breakpoint): Add argument state
10920 and don't aarch64_get_debug_reg_state. All callers update.
10921 (aarch64_handle_aligned_watchpoint): Likewise.
10922 (aarch64_handle_unaligned_watchpoint): Likewise.
10923 (aarch64_handle_watchpoint): Likewise.
10924 (aarch64_insert_point): Call aarch64_get_debug_reg_state earlier.
10925 (aarch64_remove_point): Likewise.
10926
10927 2015-07-17 Yao Qi <yao.qi@linaro.org>
10928
10929 * linux-aarch64-low.c (aarch64_show_debug_reg_state): Use
10930 debug_printf.
10931 (aarch64_handle_unaligned_watchpoint): Likewise.
10932
10933 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
10934
10935 Revert the previous 3 commits:
10936 Move gdb_regex* to common/
10937 Move linux_find_memory_regions_full & co.
10938 gdbserver build-id attribute generator
10939
10940 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
10941 Jan Kratochvil <jan.kratochvil@redhat.com>
10942
10943 gdbserver build-id attribute generator.
10944 * linux-low.c (nat/linux-maps.h, search.h, rsp-low.h): Include.
10945 (ElfXX_Ehdr, ElfXX_Phdr, ElfXX_Nhdr): New.
10946 (ELFXX_FLD, ELFXX_SIZEOF, ELFXX_ROUNDUP, BUILD_ID_INVALID): New.
10947 (find_phdr): New.
10948 (get_dynamic): Use find_pdhr to traverse program headers.
10949 (struct mapping_entry, mapping_entry_s, free_mapping_entry_vec)
10950 (compare_mapping_entry_range, struct find_memory_region_callback_data)
10951 (read_build_id, find_memory_region_callback, lrfind_mapping_entry)
10952 (get_hex_build_id): New.
10953 (linux_qxfer_libraries_svr4): Add optional build-id attribute
10954 to reply XML document.
10955
10956 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
10957 Jan Kratochvil <jan.kratochvil@redhat.com>
10958
10959 * target.c: Include target/target-utils.h and fcntl.h.
10960 (target_fileio_read_stralloc_1_pread, target_fileio_read_stralloc_1)
10961 (target_fileio_read_stralloc): New functions.
10962
10963 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
10964
10965 * Makefile.in (OBS): Add gdb_regex.o.
10966 (gdb_regex.o): New.
10967 * config.in: Rebuilt.
10968 * configure: Rebuilt.
10969
10970 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
10971 Jan Kratochvil <jan.kratochvil@redhat.com>
10972
10973 Create empty nat/linux-maps.[ch] and common/target-utils.[ch].
10974 * Makefile.in (OBS): Add target-utils.o.
10975 (linux-maps.o, target-utils.o): New.
10976 * configure.srv (srv_linux_obj): Add linux-maps.o.
10977
10978 2015-07-15 Pierre Langlois <pierre.langlois@arm.com>
10979
10980 * linux-aarch64-low.c (aarch64_supports_range_stepping): New
10981 function, return 1.
10982 (the_low_target): Install it.
10983
10984 2015-07-14 Pedro Alves <palves@redhat.com>
10985
10986 * linux-low.c (kill_wait_lwp): Don't assert if waitpid fails.
10987 Instead, ignore ECHILD, and throw an error for other errnos.
10988
10989 2015-07-10 Pedro Alves <palves@redhat.com>
10990
10991 * event-loop.c (struct callback_event) <data>: Change type to
10992 gdb_client_data instance instead of gdb_client_data pointer.
10993 (append_callback_event): Adjust.
10994
10995 2015-07-10 Pierre Langlois <pierre.langlois@arm.com>
10996
10997 * linux-aarch64-low.c: Add comments for each linux_target_ops
10998 method. Remove comments already covered in target_ops and
10999 linux_target_ops definitions.
11000 (the_low_target): Add comments for each unimplemented method.
11001
11002 2015-07-09 Yao Qi <yao.qi@linaro.org>
11003
11004 * linux-aarch64-low.c (aarch64_regmap): Remove.
11005 (aarch64_usrregs_info): Remove.
11006 (regs_info): Set field usrregs to NULL.
11007
11008 2015-07-02 Markus Metzger <markus.t.metzger@intel.com>
11009
11010 * linux-low.c: Include "rsp-low.h"
11011 (linux_low_encode_pt_config, linux_low_encode_raw): New.
11012 (linux_low_read_btrace): Support BTRACE_FORMAT_PT.
11013 (linux_low_btrace_conf): Support BTRACE_FORMAT_PT.
11014 (handle_btrace_enable_pt): New.
11015 (handle_btrace_general_set): Support "pt".
11016 (handle_btrace_conf_general_set): Support "pt:size".
11017
11018 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
11019
11020 * linux-aarch64-low.c (aarch64_supports_z_point_type): Enable for
11021 Z_PACKET_SW_BP.
11022
11023 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
11024
11025 * linux-aarch64-low.c: Remove comment about endianness.
11026 (aarch64_breakpoint): Change type to gdb_byte[]. Set to "brk #0".
11027 (aarch64_breakpoint_at): Change type of insn to gdb_byte[]. Use
11028 memcmp.
11029
11030 2015-06-24 Gary Benson <gbenson@redhat.com>
11031
11032 * linux-i386-ipa.c (stdint.h): Do not include.
11033 * lynx-i386-low.c (stdint.h): Likewise.
11034 * lynx-ppc-low.c (stdint.h): Likewise.
11035 * mem-break.c (stdint.h): Likewise.
11036 * thread-db.c (stdint.h): Likewise.
11037 * tracepoint.c (stdint.h): Likewise.
11038 * win32-low.c (stdint.h): Likewise.
11039
11040 2015-06-18 Simon Marchi <simon.marchi@ericsson.com>
11041
11042 * server.c (write_qxfer_response): Update call to
11043 remote_escape_output.
11044
11045 2015-06-15 Aleksandar Ristovski <aristovski@qnx.com
11046 Jan Kratochvil <jan.kratochvil@redhat.com>
11047
11048 Merge multiple hex conversions.
11049 * gdbreplay.c (tohex): Rename to 'fromhex'.
11050 (logchar): Use fromhex.
11051
11052 2015-06-10 Jan Kratochvil <jan.kratochvil@redhat.com>
11053
11054 * server.c (handle_qxfer_libraries): Set `version' attribute for
11055 <library-list>.
11056
11057 2015-06-10 Gary Benson <gbenson@redhat.com>
11058
11059 * target.h (struct target_ops) <multifs_open>: New field.
11060 <multifs_unlink>: Likewise.
11061 <multifs_readlink>: Likewise.
11062 * linux-low.c (nat/linux-namespaces.h): New include.
11063 (linux_target_ops): Initialize the_target->multifs_open,
11064 the_target->multifs_unlink and the_target->multifs_readlink.
11065 * hostio.h (hostio_handle_new_gdb_connection): New declaration.
11066 * hostio.c (hostio_fs_pid): New static variable.
11067 (hostio_handle_new_gdb_connection): New function.
11068 (handle_setfs): Likewise.
11069 (handle_open): Use the_target->multifs_open as appropriate.
11070 (handle_unlink): Use the_target->multifs_unlink as appropriate.
11071 (handle_readlink): Use the_target->multifs_readlink as
11072 appropriate.
11073 (handle_vFile): Handle vFile:setfs packets.
11074 * server.c (handle_query): Call hostio_handle_new_gdb_connection
11075 after target_handle_new_gdb_connection.
11076
11077 2015-06-10 Gary Benson <gbenson@redhat.com>
11078
11079 * configure.ac (AC_CHECK_FUNCS): Add setns.
11080 * config.in: Regenerate.
11081 * configure: Likewise.
11082 * Makefile.in (SFILES): Add nat/linux-namespaces.c.
11083 (linux-namespaces.o): New rule.
11084 * configure.srv (srv_linux_obj): Add linux-namespaces.o.
11085
11086 2015-06-09 Gary Benson <gbenson@redhat.com>
11087
11088 * hostio.c (handle_open): Process mode argument with
11089 fileio_to_host_mode.
11090
11091 2015-06-01 Yao Qi <yao.qi@linaro.org>
11092
11093 * linux-s390-low.c (PTRACE_GETREGSET, PTRACE_SETREGSET): Remove.
11094 * linux-x86-low.c: Likewise.
11095
11096 2015-05-28 Don Breazeal <donb@codesourcery.com>
11097
11098 * linux-low.c (handle_extended_wait): Initialize
11099 thread_info.last_resume_kind for new fork children.
11100
11101 2015-05-15 Pedro Alves <palves@redhat.com>
11102
11103 * target.h (target_handle_new_gdb_connection): Rewrite using if
11104 wrapped in do/while.
11105
11106 2015-05-14 Joel Brobecker <brobecker@adacore.com>
11107
11108 * configure.ac: Add prfpregset_t BFD_HAVE_SYS_PROCFS_TYPE check.
11109 * configure, config.in: Regenerate.
11110 * gdb_proc_service.h [HAVE_PRFPREGSET_T] (prfpregset_t):
11111 Declare typedef.
11112
11113 2015-05-12 Don Breazeal <donb@codesourcery.com>
11114
11115 * linux-low.c (handle_extended_wait): Handle PTRACE_EVENT_FORK and
11116 PTRACE_EVENT_VFORK_DONE.
11117 (linux_low_ptrace_options, extended_event_reported): Add vfork
11118 events.
11119 * remote-utils.c (prepare_resume_reply): New stop reasons "vfork"
11120 and "vforkdone" for RSP 'T' Stop Reply Packet.
11121 * server.h (report_vfork_events): Declare
11122 global variable.
11123
11124 2015-05-12 Don Breazeal <donb@codesourcery.com>
11125
11126 * linux-aarch64-low.c (aarch64_linux_new_fork): New function.
11127 (the_low_target) <new_fork>: Initialize new member.
11128 * linux-arm-low.c (arm_new_fork): New function.
11129 (the_low_target) <new_fork>: Initialize new member.
11130 * linux-low.c (handle_extended_wait): Call new target function
11131 new_fork.
11132 * linux-low.h (struct linux_target_ops) <new_fork>: New member.
11133 * linux-mips-low.c (mips_add_watchpoint): New function
11134 extracted from mips_insert_point.
11135 (the_low_target) <new_fork>: Initialize new member.
11136 (mips_linux_new_fork): New function.
11137 (mips_insert_point): Call mips_add_watchpoint.
11138 * linux-x86-low.c (x86_linux_new_fork): New function.
11139 (the_low_target) <new_fork>: Initialize new member.
11140
11141 2015-05-12 Don Breazeal <donb@codesourcery.com>
11142
11143 * linux-low.c (handle_extended_wait): Implement return value,
11144 rename argument 'event_child' to 'event_lwp', handle
11145 PTRACE_EVENT_FORK, call internal_error for unrecognized event.
11146 (linux_low_ptrace_options): New function.
11147 (linux_low_filter_event): Call linux_low_ptrace_options,
11148 use different argument fo linux_enable_event_reporting,
11149 use return value from handle_extended_wait.
11150 (extended_event_reported): New function.
11151 (linux_wait_1): Call extended_event_reported and set
11152 status to report fork events.
11153 (linux_write_memory): Add pid to debug message.
11154 (reset_lwp_ptrace_options_callback): New function.
11155 (linux_handle_new_gdb_connection): New function.
11156 (linux_target_ops): Initialize new structure member.
11157 * linux-low.h (struct lwp_info) <waitstatus>: New member.
11158 * lynx-low.c: Initialize new structure member.
11159 * remote-utils.c (prepare_resume_reply): Implement stop reason
11160 "fork" for "T" stop message.
11161 * server.c (handle_query): Call handle_new_gdb_connection.
11162 * server.h (report_fork_events): Declare global flag.
11163 * target.h (struct target_ops) <handle_new_gdb_connection>:
11164 New member.
11165 (target_handle_new_gdb_connection): New macro.
11166 * win32-low.c: Initialize new structure member.
11167
11168 2015-05-12 Don Breazeal <donb@codesourcery.com>
11169
11170 * mem-break.c (APPEND_TO_LIST): Define macro.
11171 (clone_agent_expr): New function.
11172 (clone_one_breakpoint): New function.
11173 (clone_all_breakpoints): New function.
11174 * mem-break.h: Declare new functions.
11175
11176 2015-05-12 Don Breazeal <donb@codesourcery.com>
11177
11178 * linux-low.c (linux_supports_fork_events): New function.
11179 (linux_supports_vfork_events): New function.
11180 (linux_target_ops): Initialize new structure members.
11181 (initialize_low): Call linux_check_ptrace_features.
11182 * lynx-low.c (lynx_target_ops): Initialize new structure
11183 members.
11184 * server.c (report_fork_events, report_vfork_events):
11185 New global flags.
11186 (handle_query): Add new features to qSupported packet and
11187 response.
11188 (captured_main): Initialize new global variables.
11189 * target.h (struct target_ops) <supports_fork_events>:
11190 New member.
11191 <supports_vfork_events>: New member.
11192 (target_supports_fork_events): New macro.
11193 (target_supports_vfork_events): New macro.
11194 * win32-low.c (win32_target_ops): Initialize new structure
11195 members.
11196
11197 2015-05-12 Gary Benson <gbenson@redhat.com>
11198
11199 * server.c (handle_qxfer_exec_file): Use current process
11200 if annex is empty.
11201
11202 2015-05-08 Sandra Loosemore <sandra@codesourcery.com>
11203
11204 * linux-nios2-low.c: Include elf/common.h. Adjust comments.
11205 Remove HAVE_PTRACE_GETREGS conditionals.
11206 (nios2_regsets): Use PTRACE_GETREGSET and PTRACE_SETREGSET
11207 instead of PTRACE_GETREGS and PTRACE_SETREGS.
11208
11209 2015-05-08 Yao Qi <yao.qi@linaro.org>
11210
11211 * linux-low.c (linux_supports_conditional_breakpoints): New
11212 function.
11213 (linux_target_ops): Install new target method.
11214 * lynx-low.c (lynx_target_ops): Install NULL hook for
11215 supports_conditional_breakpoints.
11216 * nto-low.c (nto_target_ops): Likewise.
11217 * spu-low.c (spu_target_ops): Likewise.
11218 * win32-low.c (win32_target_ops): Likewise.
11219 * server.c (handle_query): Check
11220 target_supports_conditional_breakpoints.
11221 * target.h (struct target_ops) <supports_conditional_breakpoints>:
11222 New field.
11223 (target_supports_conditional_breakpoints): New macro.
11224
11225 2015-05-06 Pedro Alves <palves@redhat.com>
11226
11227 PR server/18081
11228 * server.c (start_inferior): If the process exits, mourn it.
11229
11230 2015-04-21 Gary Benson <gbenson@redhat.com>
11231
11232 * hostio.c (fileio_open_flags_to_host): Factored out to
11233 fileio_to_host_openflags in common/fileio.c. Single use
11234 updated.
11235
11236 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
11237
11238 * linux-xtensa-low.c (xtensa_fill_gregset)
11239 (xtensa_store_gregset): Check XCHAL_HAVE_LOOPS instead of
11240 XCHAL_HAVE_LOOP.
11241
11242 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
11243
11244 * linux-xtensa-low.c (xtensa_usrregs_info): Remove.
11245 (regs_info): Replace usrregs pointer with NULL.
11246
11247 2015-04-17 Gary Benson <gbenson@redhat.com>
11248
11249 * target.h (struct target_ops) <pid_to_exec_file>: New field.
11250 * linux-low.c (linux_target_ops): Initialize pid_to_exec_file.
11251 * server.c (handle_qxfer_exec_file): New function.
11252 (qxfer_packets): Add exec-file entry.
11253 (handle_query): Report qXfer:exec-file:read as supported packet.
11254
11255 2015-04-14 Romain Naour <romain.naour@openwide.fr> (tiny change)
11256
11257 * linux-low.c (linux_read_offsets): Remove get_thread_lwp.
11258
11259 2015-04-09 Gary Benson <gbenson@redhat.com>
11260
11261 * hostio-errno.c (errno_to_fileio_error): Remove function.
11262 Update caller to use remote_fileio_to_fio_error.
11263
11264 2015-04-09 Yao Qi <yao.qi@linaro.org>
11265
11266 * linux-low.c (linux_insert_point): Call
11267 insert_memory_breakpoint if TYPE is raw_bkpt_type_sw.
11268 (linux_remove_point): Call remove_memory_breakpoint if type is
11269 raw_bkpt_type_sw.
11270 * linux-x86-low.c (x86_insert_point): Don't call
11271 insert_memory_breakpoint.
11272 (x86_remove_point): Don't call remove_memory_breakpoint.
11273
11274 2015-04-01 Pedro Alves <palves@redhat.com>
11275 Cleber Rosa <crosa@redhat.com>
11276
11277 * server.c (gdbserver_usage): Reorganize and extend the usage
11278 message.
11279
11280 2015-03-24 Pedro Alves <palves@redhat.com>
11281
11282 * linux-low.c (check_stopped_by_breakpoint): Tweak debug log
11283 output. Also dump TRAP_TRACE.
11284 (linux_low_filter_event): In debug output, distinguish a
11285 resume_stop SIGSTOP from a delayed SIGSTOP.
11286
11287 2015-03-24 Gary Benson <gbenson@redhat.com>
11288
11289 * linux-x86-low.c (x86_linux_new_thread): Moved to
11290 nat/x86-linux.c.
11291 (x86_linux_prepare_to_resume): Likewise.
11292
11293 2015-03-24 Gary Benson <gbenson@redhat.com>
11294
11295 * Makefile.in (x86-linux-dregs.o): New rule.
11296 * configure.srv: Add x86-linux-dregs.o to relevant targets.
11297 * linux-x86-low.c: Include nat/x86-linux-dregs.h.
11298 (u_debugreg_offset): Moved to nat/x86-linux-dregs.c.
11299 (x86_linux_dr_get): Likewise.
11300 (x86_linux_dr_set): Likewise.
11301 (update_debug_registers_callback): Likewise.
11302 (x86_linux_dr_set_addr): Likewise.
11303 (x86_linux_dr_get_addr): Likewise.
11304 (x86_linux_dr_set_control): Likewise.
11305 (x86_linux_dr_get_control): Likewise.
11306 (x86_linux_dr_get_status): Likewise.
11307 (x86_linux_update_debug_registers): Likewise.
11308
11309 2015-03-24 Gary Benson <gbenson@redhat.com>
11310
11311 * linux-x86-low.c (x86_linux_update_debug_registers):
11312 New function, factored out from...
11313 (x86_linux_prepare_to_resume): ...this.
11314
11315 2015-03-24 Gary Benson <gbenson@redhat.com>
11316
11317 * linux-x86-low.c (x86_linux_dr_get): Update comments.
11318 (x86_linux_dr_set): Likewise.
11319 (update_debug_registers_callback): Likewise.
11320 (x86_linux_dr_set_addr): Likewise.
11321 (x86_linux_dr_get_addr): Likewise.
11322 (x86_linux_dr_set_control): Likewise.
11323 (x86_linux_dr_get_control): Likewise.
11324 (x86_linux_dr_get_status): Likewise.
11325 (x86_linux_prepare_to_resume): Likewise.
11326
11327 2015-03-24 Gary Benson <gbenson@redhat.com>
11328
11329 * linux-x86-low.c (x86_linux_dr_get): Add assertion.
11330 Use perror_with_name. Pass string through gettext.
11331 (x86_linux_dr_set): Likewise.
11332
11333 2015-03-24 Gary Benson <gbenson@redhat.com>
11334
11335 * linux-x86-low.c (x86_dr_low_set_addr): Rename to...
11336 (x86_linux_dr_set_addr): ...this.
11337 (x86_dr_low_get_addr): Rename to...
11338 (x86_linux_dr_get_addr): ...this.
11339 (x86_dr_low_set_control): Rename to...
11340 (x86_linux_dr_set_control): ...this.
11341 (x86_dr_low_get_control): Rename to...
11342 (x86_linux_dr_get_control): ...this.
11343 (x86_dr_low_get_status): Rename to...
11344 (x86_linux_dr_get_status): ...this.
11345 (x86_dr_low): Update with new function names.
11346
11347 2015-03-24 Gary Benson <gbenson@redhat.com>
11348
11349 * Makefile.in (x86-linux.o): New rule.
11350 * configure.srv: Add x86-linux.o to relevant targets.
11351 * linux-low.c (lwp_set_arch_private_info): New function.
11352 (lwp_arch_private_info): Likewise.
11353 * linux-x86-low.c: Include nat/x86-linux.h.
11354 (arch_lwp_info): Removed structure.
11355 (update_debug_registers_callback):
11356 Use lwp_set_debug_registers_changed.
11357 (x86_linux_prepare_to_resume): Use lwp_debug_registers_changed
11358 and lwp_set_debug_registers_changed.
11359 (x86_linux_new_thread): Use lwp_set_debug_registers_changed.
11360
11361 2015-03-24 Gary Benson <gbenson@redhat.com>
11362
11363 * linux-low.h (linux_target_ops) <new_thread>: Changed signature.
11364 * linux-arm-low.c (arm_new_thread): Likewise.
11365 * linux-aarch64-low.c (aarch64_linux_new_thread): Likewise.
11366 * linux-mips-low.c (mips_linux_new_thread): Likewise.
11367 * linux-x86-low.c (x86_linux_new_thread): Likewise.
11368 * linux-low.c (add_lwp): Update the_low_target.new_thread call.
11369
11370 2015-03-24 Gary Benson <gbenson@redhat.com>
11371
11372 * linux-low.c (ptid_of_lwp): New function.
11373 (lwp_is_stopped): Likewise.
11374 (lwp_stop_reason): Likewise.
11375 * linux-x86-low.c (update_debug_registers_callback):
11376 Use lwp_is_stopped.
11377 (x86_linux_prepare_to_resume): Use ptid_of_lwp and
11378 lwp_stop_reason.
11379
11380 2015-03-24 Gary Benson <gbenson@redhat.com>
11381
11382 * linux-low.h (linux_stop_lwp): Remove declaration.
11383
11384 2015-03-24 Gary Benson <gbenson@redhat.com>
11385
11386 * linux-low.h: Include nat/linux-nat.h.
11387 * linux-low.c (iterate_over_lwps_args): New structure.
11388 (iterate_over_lwps_filter): New function.
11389 (iterate_over_lwps): Likewise.
11390 * linux-x86-low.c (update_debug_registers_callback):
11391 Update signature to what iterate_over_lwps expects.
11392 Remove PID check that iterate_over_lwps now performs.
11393 (x86_dr_low_set_addr): Use iterate_over_lwps.
11394 (x86_dr_low_set_control): Likewise.
11395
11396 2015-03-24 Gary Benson <gbenson@redhat.com>
11397
11398 * linux-x86-low.c (x86_debug_reg_state): New function.
11399 (x86_linux_prepare_to_resume): Use the above.
11400
11401 2015-03-24 Gary Benson <gbenson@redhat.com>
11402
11403 * linux-low.c (current_lwp_ptid): New function.
11404 * linux-x86-low.c: Include nat/linux-nat.h.
11405 (x86_dr_low_get_addr): Use current_lwp_ptid.
11406 (x86_dr_low_get_control): Likewise.
11407 (x86_dr_low_get_status): Likewise.
11408
11409 2015-03-20 Pedro Alves <palves@redhat.com>
11410
11411 * tracepoint.c (cmd_qtstatus): Make "str" const.
11412
11413 2015-03-20 Pedro Alves <palves@redhat.com>
11414
11415 * server.c (handle_general_set): Make "req_str" const.
11416
11417 2015-03-19 Pedro Alves <palves@redhat.com>
11418
11419 * linux-low.c (linux_resume_one_lwp): Rename to ...
11420 (linux_resume_one_lwp_throw): ... this. Don't handle ESRCH here,
11421 instead call perror_with_name.
11422 (check_ptrace_stopped_lwp_gone): New function.
11423 (linux_resume_one_lwp): Reimplement as wrapper around
11424 linux_resume_one_lwp_throw that swallows errors if the LWP is
11425 gone.
11426
11427 2015-03-19 Pedro Alves <palves@redhat.com>
11428
11429 * linux-low.c (count_events_callback, select_event_lwp_callback):
11430 No longer check whether the thread has resume_stop as last resume
11431 kind.
11432
11433 2015-03-19 Pedro Alves <palves@redhat.com>
11434
11435 * linux-low.c (count_events_callback, select_event_lwp_callback):
11436 Use the lwp's status_pending_p field, not the thread's.
11437
11438 2015-03-19 Pedro Alves <palves@redhat.com>
11439
11440 * linux-low.c (select_event_lwp_callback): Update comments to
11441 no longer mention SIGTRAP.
11442
11443 2015-03-18 Gary Benson <gbenson@redhat.com>
11444
11445 * server.c (handle_query): Do not report vFile:fstat as supported.
11446
11447 2015-03-11 Gary Benson <gbenson@redhat.com>
11448
11449 * hostio.c (sys/types.h): New include.
11450 (sys/stat.h): Likewise.
11451 (common-remote-fileio.h): Likewise.
11452 (handle_fstat): New function.
11453 (handle_vFile): Handle vFile:fstat packets.
11454
11455 2015-03-11 Gary Benson <gbenson@redhat.com>
11456
11457 * configure.ac (AC_CHECK_MEMBERS): Add checks for
11458 struct stat.st_blocks and struct stat.st_blksize.
11459 * configure: Regenerate.
11460 * config.in: Likewise.
11461 * Makefile.in (SFILES): Add common/common-remote-fileio.c.
11462 (OBS): Add common-remote-fileio.o.
11463 (common-remote-fileio.o): New rule.
11464
11465 2015-03-09 Pedro Alves <palves@redhat.com>
11466
11467 * tracepoint.c (gdb_agent_helper_thread): Cast '&sockaddr' to
11468 'struct sockaddr' pointer in 'accept' call.
11469
11470 2015-03-09 Pedro Alves <palves@redhat.com>
11471
11472 Revert:
11473 2015-03-07 Pedro Alves <palves@redhat.com>
11474 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
11475 or <winsock2.h> here. Instead include "gdb_socket.h".
11476 (remote_open): Use union gdb_sockaddr_u.
11477 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
11478 or <winsock2.h> here. Instead include "gdb_socket.h".
11479 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
11480 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
11481 or <sys/un.h>.
11482 (init_named_socket, gdb_agent_helper_thread): Use union
11483 gdb_sockaddr_u.
11484
11485 2015-03-07 Pedro Alves <palves@redhat.com>
11486
11487 * configure.ac (build_warnings): Move
11488 -Wdeclaration-after-statement to the C-specific set.
11489 * configure: Regenerate.
11490
11491 2015-03-07 Pedro Alves <palves@redhat.com>
11492
11493 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
11494 or <winsock2.h> here. Instead include "gdb_socket.h".
11495 (remote_open): Use union gdb_sockaddr_u.
11496 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
11497 or <winsock2.h> here. Instead include "gdb_socket.h".
11498 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
11499 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
11500 or <sys/un.h>.
11501 (init_named_socket, gdb_agent_helper_thread): Use union
11502 gdb_sockaddr_u.
11503
11504 2015-03-07 Pedro Alves <palves@redhat.com>
11505
11506 Adjust all callers of TRY_CATCH to use TRY/CATCH/END_CATCH
11507 instead.
11508
11509 2015-03-06 Yao Qi <yao.qi@linaro.org>
11510
11511 * linux-aarch64-low.c (aarch64_insert_point): Use
11512 show_debug_regs as a boolean.
11513 (aarch64_remove_point): Likewise.
11514
11515 2015-03-05 Pedro Alves <palves@redhat.com>
11516
11517 * lynx-low.c (lynx_target_ops): Install NULL hooks for
11518 stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
11519 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint.
11520 * nto-low.c (nto_target_ops): Likewise.
11521 * spu-low.c (spu_target_ops): Likewise.
11522 * win32-low.c (win32_target_ops): Likewise.
11523
11524 2015-03-04 Pedro Alves <palves@redhat.com>
11525
11526 * linux-low.c (check_stopped_by_breakpoint) [USE_SIGTRAP_SIGINFO]:
11527 Decide whether a breakpoint triggered based on the SIGTRAP's
11528 siginfo.si_code.
11529 (thread_still_has_status_pending_p) [USE_SIGTRAP_SIGINFO]: Don't check whether a
11530 breakpoint is inserted if relying on SIGTRAP's siginfo.si_code.
11531 (linux_low_filter_event): Check for breakpoints before checking
11532 watchpoints.
11533 (linux_wait_1): Don't re-increment the PC if relying on SIGTRAP's
11534 siginfo.si_code.
11535 (linux_stopped_by_sw_breakpoint)
11536 (linux_supports_stopped_by_sw_breakpoint)
11537 (linux_stopped_by_hw_breakpoint)
11538 (linux_supports_stopped_by_hw_breakpoint): New functions.
11539 (linux_target_ops): Install new target methods.
11540
11541 2015-03-04 Pedro Alves <palves@redhat.com>
11542
11543 * remote-utils.c (prepare_resume_reply): Report swbreak/hbreak.
11544 * server.c (swbreak_feature, hwbreak_feature): New globals.
11545 (handle_query) <qSupported>: Handle "swbreak+" and "hwbreak+".
11546 (captured_main): Clear swbreak_feature and hwbreak_feature.
11547 * server.h (swbreak_feature, hwbreak_feature): Declare.
11548 * target.h (struct target_ops) <stopped_by_sw_breakpoint,
11549 supports_stopped_by_sw_breakpoint, stopped_by_hw_breakpoint,
11550 supports_stopped_by_hw_breakpoint>: New fields.
11551 (target_supports_stopped_by_sw_breakpoint)
11552 (target_stopped_by_sw_breakpoint)
11553 (target_supports_stopped_by_hw_breakpoint)
11554 (target_stopped_by_hw_breakpoint): Declare.
11555
11556 2015-03-04 Pedro Alves <palves@redhat.com>
11557
11558 enum lwp_stop_reason -> enum target_stop_reason
11559 * linux-low.c (check_stopped_by_breakpoint): Adjust.
11560 (thread_still_has_status_pending_p, check_stopped_by_watchpoint)
11561 (linux_wait_1, stuck_in_jump_pad_callback)
11562 (move_out_of_jump_pad_callback, linux_resume_one_lwp)
11563 (linux_stopped_by_watchpoint):
11564 * linux-low.h (enum lwp_stop_reason): Delete.
11565 (struct lwp_info) <stop_reason>: Now an enum target_stop_reason.
11566 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
11567
11568 2015-03-04 Yao Qi <yao.qi@linaro.org>
11569
11570 * Makefile.in (SFILES): Add linux-aarch64-low.c.
11571
11572 2015-03-03 Gary Benson <gbenson@redhat.com>
11573
11574 * hostio.c (handle_vFile): Fix prefix lengths.
11575
11576 2015-03-03 Markus Metzger <markus.t.metzger@intel.com>
11577
11578 * linux-low.c (linux_low_enable_btrace): Do not overwrite non-zero
11579 ptr_bits.
11580
11581 2015-03-02 Andreas Arnez <arnez@linux.vnet.ibm.com>
11582
11583 * Makefile.in (s390-vx-linux64.c, s390-tevx-linux64.c)
11584 (s390x-vx-linux64.c, s390x-tevx-linux64.c): New rules.
11585 (clean): Add "rm -f" for above C files.
11586 * configure.srv (srv_regobj): Add s390-vx-linux64.o,
11587 s390-tevx-linux64.o, s390x-vx-linux64.o, and s390x-tevx-linux64.o.
11588 (srv_xmlfiles): Add s390-vx-linux64.xml, s390-tevx-linux64.xml,
11589 s390x-vx-linux64.xml, s390x-tevx-linux64.xml, and s390-vx.xml.
11590 * linux-s390-low.c (HWCAP_S390_VX): New macro.
11591 (init_registers_s390_vx_linux64, init_registers_s390_tevx_linux64)
11592 (init_registers_s390x_vx_linux64)
11593 (init_registers_s390x_tevx_linux64)
11594 (tdesc_s390_vx_linux64, tdesc_s390_tevx_linux64)
11595 (tdesc_s390x_vx_linux64, tdesc_s390x_tevx_linux64): New extern
11596 declarations.
11597 (s390_fill_vxrs_low, s390_store_vxrs_low, s390_fill_vxrs_high)
11598 (s390_store_vxrs_high): New functions.
11599 (s390_regsets): Add entries for NT_S390_VXRS_LOW and
11600 NT_S390_VXRS_HIGH.
11601 (s390_arch_setup): Add logic for selecting one of the new target
11602 descriptions. Activate the new vector regsets if applicable.
11603 (initialize_low_arch): Also invoke init_registers_s390_vx_linux64,
11604 init_registers_s390_tevx_linux64, init_registers_s390x_vx_linux64,
11605 and init_registers_s390x_tevx_linux64.
11606
11607 2015-03-01 Pedro Alves <palves@redhat.com>
11608
11609 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Constify 'raw_regs'
11610 parameter.
11611
11612 2015-02-27 Pedro Alves <palves@redhat.com>
11613
11614 * linux-x86-low.c (u_debugreg_offset): New function.
11615 (x86_linux_dr_get, x86_linux_dr_set): Use it.
11616
11617 2015-02-27 Pedro Alves <palves@redhat.com>
11618
11619 * gdb_proc_service.h: Wrap with EXTERN_C_PUSH/EXTERN_C_POP.
11620 [!HAVE_PROC_SERVICE_H] (struct ps_prochandle): Forward declare.
11621 [!HAVE_PROC_SERVICE_H] (ps_pdread, ps_pdwrite, ps_ptread)
11622 ps_ptwrite, ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
11623 (ps_lsetfpregs, ps_getpid)
11624 (ps_get_thread_area, ps_pglobal_lookup, ps_pstop, ps_pcontinue)
11625 (ps_lstop, ps_lcontinue, ps_lgetxregsize, ps_lgetxregs)
11626 (ps_lsetxregs, ps_plog): Declare.
11627
11628 2015-02-27 Pedro Alves <palves@redhat.com>
11629
11630 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Use
11631 IP_AGENT_EXPORT_FUNC.
11632 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Use
11633 IP_AGENT_EXPORT_FUNC.
11634 * tracepoint.c (ATTR_USED, ATTR_NOINLINE, ATTR_CONSTRUCTOR)
11635 (IP_AGENT_EXPORT): Delete.
11636 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
11637 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
11638 (gdb_trampoline_buffer_error, collecting, gdb_collect)
11639 (stop_tracing, flush_trace_buffer, about_to_request_buffer_space)
11640 (trace_buffer_is_full, stopping_tracepoint, expr_eval_result)
11641 (error_tracepoint, tracepoints, tracing, trace_buffer_ctrl)
11642 (trace_buffer_ctrl_curr, trace_buffer_lo, trace_buffer_hi)
11643 (traceframe_read_count, traceframe_write_count)
11644 (traceframes_created, trace_state_variables, get_raw_reg)
11645 (get_trace_state_variable_value, set_trace_state_variable_value)
11646 (ust_loaded, helper_thread_id, cmd_buf): Use
11647 IPA_SYM_EXPORTED_NAME.
11648 (stop_tracing, flush_trace_buffer): Use IP_AGENT_EXPORT_FUNC.
11649 (tracepoints) Use IP_AGENT_EXPORT_VAR.
11650 (stopping_tracepoint, trace_buffer_is_full, expr_eval_result): Use
11651 IP_AGENT_EXPORT_VAR and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
11652 (last_tracepoint): Move into !IN_PROCESS_AGENT block.
11653 (error_tracepoint): Use IP_AGENT_EXPORT_VAR and wrap in
11654 EXTERN_C_PUSH/EXTERN_C_POP.
11655 (trace_state_variables): Use IP_AGENT_EXPORT_VAR.
11656 (trace_buffer_lo, trace_buffer_hi): Use IP_AGENT_EXPORT_VAR and
11657 wrap in EXTERN_C_PUSH/EXTERN_C_POP.
11658 (trace_buffer_ctrl, trace_buffer_ctrl_curr)
11659 (traceframe_write_count, traceframe_read_count)
11660 (traceframes_created, tracing): Use IP_AGENT_EXPORT_VAR.
11661 (about_to_request_buffer_space, get_trace_state_variable_value)
11662 (set_trace_state_variable_value): Use IP_AGENT_EXPORT_FUNC.
11663 (collecting): Use IP_AGENT_EXPORT_VAR and wrap in
11664 EXTERN_C_PUSH/EXTERN_C_POP.
11665 (gdb_collect): Use IP_AGENT_EXPORT_FUNC.
11666 (ust_loaded, cmd_buf): Use IP_AGENT_EXPORT_VAR.
11667 (helper_thread_id, gdb_agent_capability): Use IP_AGENT_EXPORT_VAR
11668 and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
11669 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
11670 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
11671 (gdb_trampoline_buffer_error): Use IP_AGENT_EXPORT_VAR.
11672 * tracepoint.h (ATTR_USED, ATTR_NOINLINE, EXPORTED_SYMBOL):
11673 Define.
11674 (IP_AGENT_EXPORT_FUNC, IP_AGENT_EXPORT_VAR)
11675 (IP_AGENT_EXPORT_VAR_DECL): Define.
11676 (tracing): Declare.
11677 (gdb_agent_get_raw_reg): Declare.
11678
11679 2015-02-27 Tom Tromey <tromey@redhat.com>
11680 Pedro Alves <palves@redhat.com>
11681
11682 Rename symbols whose names are reserved C++ keywords throughout.
11683
11684 2015-02-27 Pedro Alves <palves@redhat.com>
11685
11686 * Makefile.in (COMPILER): New, get it from autoconf.
11687 (CXX): Get from autoconf instead.
11688 (COMPILE.pre): Use COMPILER.
11689 (CC-LD): Rename to ...
11690 (CC_LD): ... this. Use COMPILER.
11691 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT), $(IPA_LIB)): Adjust.
11692 (CXX_FOR_TARGET): Default to g++ instead of gcc.
11693 * acinclude.m4: Include build-with-cxx.m4.
11694 * configure.ac: Call AC_PROG_CXX and GDB_AC_BUILD_WITH_CXX.
11695 Disable -Werror by default if building in C++ mode.
11696 (build_warnings): Add -Wno-sign-compare, -Wno-write-strings and
11697 -Wno-narrowing in C++ mode. Run supported-warning-flags tests with
11698 the C++ compiler. Save/restore CXXFLAGS too.
11699 * configure: Regenerate.
11700
11701 2015-02-27 Pedro Alves <palves@redhat.com>
11702
11703 * acinclude.m4: Include libiberty.m4.
11704 * configure.ac: Call libiberty_INIT.
11705 * config.in, configure: Regenerate.
11706
11707 2015-02-26 Pedro Alves <palves@redhat.com>
11708
11709 * linux-low.c (linux_wait_1): When incrementing the PC past a
11710 program breakpoint always use the_low_target.breakpoint_len as
11711 increment, rather than the maximum between that and
11712 the_low_target.decr_pc_after_break.
11713
11714 2015-02-23 Pedro Alves <palves@redhat.com>
11715
11716 * linux-low.c (check_stopped_by_breakpoint): Don't check if the
11717 thread was doing a step-over; always adjust the PC if
11718 we stepped over a permanent breakpoint.
11719 (linux_wait_1): If we stepped over breakpoint that was on top of a
11720 permanent breakpoint, manually advance the PC past it.
11721
11722 2015-02-23 Pedro Alves <palves@redhat.com>
11723
11724 * linux-x86-low.c (REGSIZE): Define in both 32-bit and 64-bit
11725 modes.
11726 (x86_fill_gregset, x86_store_gregset): Use it when handling
11727 $orig_eax.
11728
11729 2015-02-20 Pedro Alves <palves@redhat.com>
11730
11731 * thread-db.c: Include "nat/linux-procfs.h".
11732 (thread_db_init): Skip listing new threads if the kernel supports
11733 PTRACE_EVENT_CLONE and /proc/PID/task/ is accessible.
11734
11735 2015-02-20 Pedro Alves <palves@redhat.com>
11736
11737 * linux-low.c (status_pending_p_callback): Use ptid_match.
11738
11739 2015-02-19 Antoine Tremblay <antoine.tremblay@ericsson.com>
11740
11741 PR breakpoints/16812
11742 * linux-low.c (wstatus_maybe_breakpoint): Remove.
11743 (linux_low_filter_event): Update wstatus_maybe_breakpoint name.
11744 (linux_wait_1): Report SIGTRAP,SIGILL,SIGSEGV.
11745
11746 2015-02-10 Antoine Tremblay <antoine.tremblay@ericsson.com>
11747
11748 PR breakpoints/15956
11749 * tracepoint.c (cmd_qtinit): Add check for current_thread.
11750
11751 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
11752
11753 * linux-low.c (linux_low_btrace_conf): Print size.
11754 * server.c (handle_btrace_conf_general_set): New.
11755 (hanle_general_set): Call handle_btrace_conf_general_set.
11756 (handle_query): Report Qbtrace-conf:bts:size as supported.
11757
11758 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
11759
11760 * linux-low.c (linux_low_enable_btrace): Update parameters.
11761 (linux_low_btrace_conf): New.
11762 (linux_target_ops)<to_btrace_conf>: Initialize.
11763 * server.c (current_btrace_conf): New.
11764 (handle_btrace_enable): Rename to ...
11765 (handle_btrace_enable_bts): ... this. Pass &current_btrace_conf
11766 to target_enable_btrace. Update comment. Update users.
11767 (handle_qxfer_btrace_conf): New.
11768 (qxfer_packets): Add btrace-conf entry.
11769 (handle_query): Report qXfer:btrace-conf:read as supported packet.
11770 * target.h (target_ops)<enable_btrace>: Update parameters and comment.
11771 (target_ops)<read_btrace_conf>: New.
11772 (target_enable_btrace): Update parameters.
11773 (target_read_btrace_conf): New.
11774
11775 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
11776
11777 * server.c (handle_btrace_general_set): Remove call to
11778 target_supports_btrace.
11779 (supported_btrace_packets): New.
11780 (handle_query): Call supported_btrace_packets.
11781 * target.h: include btrace-common.h.
11782 (btrace_target_info): Removed.
11783 (supports_btrace, target_supports_btrace): Update parameters.
11784
11785 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
11786
11787 * Makefile.in (SFILES): Add common/btrace-common.c.
11788 (OBS): Add common/btrace-common.o.
11789 (btrace-common.o): Add build rules.
11790 * linux-low: Include btrace-common.h.
11791 (linux_low_read_btrace): Use struct btrace_data. Call
11792 btrace_data_init and btrace_data_fini.
11793
11794 2015-02-06 Pedro Alves <palves@redhat.com>
11795
11796 * thread-db.c (find_new_threads_callback): Add debug output.
11797
11798 2015-02-04 Pedro Alves <palves@redhat.com>
11799
11800 * linux-low.c (handle_extended_wait): Don't resume LWPs here.
11801 (resume_stopped_resumed_lwps): New function.
11802 (linux_wait_for_event_filtered): Use it.
11803
11804 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
11805
11806 * Makefile.in (SFILES): Add linux-personality.c.
11807 (linux-personality.o): New rule.
11808 * configure.srv (srv_linux_obj): Add linux-personality.o to the
11809 list of objects to be built.
11810 * linux-low.c: Include nat/linux-personality.h.
11811 (linux_create_inferior): Remove code to disable address space
11812 randomization (moved to ../nat/linux-personality.c). Create
11813 cleanup to disable address space randomization.
11814
11815 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
11816
11817 * Makefile.in (posix-strerror.o): New rule.
11818 (mingw-strerror.o): Likewise.
11819 * configure: Regenerated.
11820 * configure.ac: Source file ../common/common.host. Initialize new
11821 variable srv_host_obs. Add srv_host_obs to GDBSERVER_DEPFILES.
11822
11823 2015-01-14 Yao Qi <yao@codesourcery.com>
11824
11825 * Makefile.in (SFILES): Add nat/ppc-linux.c.
11826 (ppc-linux.o): New rule.
11827 * configure.srv (powerpc*-*-linux*): Add ppc-linux.o.
11828 * configure.ac: AC_CHECK_FUNCS(getauxval).
11829 * config.in: Re-generated.
11830 * configure: Re-generated.
11831 * linux-ppc-low.c (ppc_arch_setup) [__powerpc64__]: Call
11832 ppc64_64bit_inferior_p
11833
11834 2015-01-14 Yao Qi <yao@codesourcery.com>
11835
11836 * linux-ppc-low.c: Include "nat/ppc-linux.h".
11837 (PPC_FEATURE_HAS_VSX): Move to nat/ppc-linux.h.
11838 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Likewise.
11839 (PT_ORIG_R3, PT_TRAP): Likewise.
11840 (PTRACE_GETVSXREGS, PTRACE_SETVSXREGS): Likewise.
11841 (PTRACE_GETVRREGS, PTRACE_SETVRREGS): Likewise.
11842 (PTRACE_GETEVRREGS, PTRACE_SETEVRREGS): Likewise.
11843
11844 2015-01-10 Joel Brobecker <brobecker@adacore.com>
11845
11846 * i387-fp.c (i387_cache_to_xsave): In look over
11847 num_avx512_zmmh_high_registers, replace use of struct i387_xsave
11848 zmmh_low_space field by use of zmmh_high_space.
11849
11850 2015-01-09 Pedro Alves <palves@redhat.com>
11851
11852 * linux-low.c (step_over_bkpt): Move higher up in the file.
11853 (handle_extended_wait): Don't store the stop_pc here.
11854 (get_stop_pc): Adjust comments and rename to ...
11855 (check_stopped_by_breakpoint): ... this. Record whether the LWP
11856 stopped for a software breakpoint or hardware breakpoint.
11857 (thread_still_has_status_pending_p): New function.
11858 (status_pending_p_callback): Use
11859 thread_still_has_status_pending_p. If the event is no longer
11860 interesting, resume the LWP.
11861 (handle_tracepoints): Add assert.
11862 (maybe_move_out_of_jump_pad): Remove cancel_breakpoints call.
11863 (wstatus_maybe_breakpoint): New function.
11864 (cancel_breakpoint): Delete function.
11865 (check_stopped_by_watchpoint): New function, factored out from
11866 linux_low_filter_event.
11867 (lp_status_maybe_breakpoint): Delete function.
11868 (linux_low_filter_event): Remove filter_ptid argument.
11869 Leave thread group exits pending here. Store the LWP's stop PC.
11870 Always leave events pending.
11871 (linux_wait_for_event_filtered): Pull all events out of the
11872 kernel, and leave them all pending.
11873 (count_events_callback, select_event_lwp_callback): Consider all
11874 events.
11875 (cancel_breakpoints_callback, linux_cancel_breakpoints): Delete.
11876 (select_event_lwp): Only give preference to the stepping LWP in
11877 all-stop mode. Adjust comments.
11878 (ignore_event): New function.
11879 (linux_wait_1): Delete 'retry' label. Use ignore_event. Remove
11880 references to cancel_breakpoints. Adjust to renames. Also give
11881 equal priority to all LWPs that have had events in non-stop mode.
11882 If reporting a software breakpoint event, unadjust the LWP's PC.
11883 (linux_wait): If linux_wait_1 returned an ignored event, retry.
11884 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback):
11885 Adjust.
11886 (linux_resume_one_lwp): Store the LWP's PC. Adjust.
11887 (resume_status_pending_p): Use thread_still_has_status_pending_p.
11888 (linux_stopped_by_watchpoint): Adjust.
11889 (linux_target_ops): Remove reference to linux_cancel_breakpoints.
11890 * linux-low.h (enum lwp_stop_reason): New.
11891 (struct lwp_info) <stop_pc>: Adjust comment.
11892 <stopped_by_watchpoint>: Delete field.
11893 <stop_reason>: New field.
11894 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
11895 * mem-break.c (software_breakpoint_inserted_here)
11896 (hardware_breakpoint_inserted_here): New function.
11897 * mem-break.h (software_breakpoint_inserted_here)
11898 (hardware_breakpoint_inserted_here): Declare.
11899 * target.h (struct target_ops) <cancel_breakpoints>: Remove field.
11900 (cancel_breakpoints): Delete.
11901 * tracepoint.c (clear_installed_tracepoints, stop_tracing)
11902 (upload_fast_traceframes): Remove references to
11903 cancel_breakpoints.
11904
11905 2015-01-09 Pedro Alves <palves@redhat.com>
11906
11907 * thread-db.c (find_new_threads_callback): Ignore thread if the
11908 kernel thread ID is -1.
11909
11910 2015-01-09 Pedro Alves <palves@redhat.com>
11911
11912 * linux-low.c (linux_attach_fail_reason_string): Move to
11913 nat/linux-ptrace.c, and rename.
11914 (linux_attach_lwp): Update comment.
11915 (attach_proc_task_lwp_callback): New function.
11916 (linux_attach): Adjust to rename and use
11917 linux_proc_attach_tgid_threads.
11918 (linux_attach_fail_reason_string): Delete declaration.
11919
11920 2015-01-01 Joel Brobecker <brobecker@adacore.com>
11921
11922 * gdbreplay.c (gdbreplay_version): Update copyright year to 2015.
11923 * server.c (gdbserver_version): Likewise.
11924
11925 2014-12-29 Sergio Durigan Junior <sergiodj@redhat.com>
11926
11927 * remote-utils.c: Include ctype.h.
11928 (input_interrupt): Explicitly handle the case when the char
11929 received is the NUL byte. Improve the printing of non-ASCII
11930 characters.
11931
11932 2014-12-16 Joel Brobecker <brobecker@adacore.com>
11933
11934 * linux-low.c (linux_low_filter_event): Update call to
11935 linux_enable_event_reporting following the addition of
11936 a new parameter to that function.
11937
11938 2014-12-16 Catalin Udma <catalin.udma@freescale.com>
11939
11940 PR server/17457
11941 * linux-aarch64-low.c (AARCH64_FPSR_REGNO): New define.
11942 (AARCH64_FPCR_REGNO): Likewise.
11943 (AARCH64_NUM_REGS): Update to include fpsr/fpcr registers.
11944 (aarch64_fill_fpregset): Add missing fpsr/fpcr registers.
11945 (aarch64_store_fpregset): Likewise.
11946
11947 2014-12-15 Joel Brobecker <brobecker@adacore.com>
11948
11949 * lynx-low.c (lynx_resume): Use PTRACE_SINGLESTEP_ONE if N == 1.
11950 Remove FIXME comment about assumption about N.
11951
11952 2014-12-13 Joel Brobecker <brobecker@adacore.com>
11953
11954 * configure.ac: If large-file support is disabled in GDBserver,
11955 pass --disable-largefile to ACX_CONFIGURE_DIR call for "gnulib".
11956 * configure: Regenerate.
11957
11958 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
11959
11960 * linux-low.c (regsets_fetch_inferior_registers): Suppress the
11961 warning upon ENODATA from ptrace.
11962 * linux-s390-low.c (s390_store_tdb): New.
11963 (s390_regsets): Add regset for NT_S390_TDB.
11964
11965 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
11966
11967 * linux-low.c (regsets_store_inferior_registers): Skip regsets
11968 without a fill_function.
11969 * linux-s390-low.c (s390_fill_last_break): Remove.
11970 (s390_regsets): Set fill_function to NULL for NT_S390_LAST_BREAK.
11971 (s390_arch_setup): Use regset's size instead of fill_function for
11972 loop end condition.
11973
11974 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
11975
11976 * linux-low.c (regsets_fetch_inferior_registers): Do not invoke
11977 the regset's store function when ptrace returned an error.
11978 * regcache.c (get_thread_regcache): Invalidate register cache
11979 before fetching inferior's registers.
11980
11981 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
11982
11983 * linux-low.c (regsets_fetch_inferior_registers): Rephrase
11984 while-loop as for-loop.
11985 (regsets_store_inferior_registers): Likewise.
11986
11987 2014-11-28 Yao Qi <yao@codesourcery.com>
11988
11989 * configure.ac(AC_CHECK_FUNCS): Remove readlink.
11990 * config.in, configure: Re-generate.
11991 * hostio.c (handle_unlink): Remove code checking HAVE_READLINK
11992 is defined.
11993
11994 2014-11-21 Yao Qi <yao@codesourcery.com>
11995
11996 * configure.ac: Don't invoke AC_FUNC_ALLOCA.
11997 (AC_CHECK_HEADERS): Remove malloc.h.
11998 * configure: Re-generated.
11999 * config.in: Re-generated.
12000 * server.h: Don't include alloca.h and malloc.h.
12001 * gdbreplay.c: Don't check HAVE_ALLOCA_H is defined.
12002 Don't include malloc.h.
12003
12004 2014-11-17 Joel Brobecker <brobecker@adacore.com>
12005
12006 * lynx-low.c (lynx_write_memory): Put lynx_read_memory and
12007 corresponding ERRNO check in same block.
12008
12009 2014-11-12 Pedro Alves <palves@redhat.com>
12010
12011 * server.c (cont_thread): Update comment.
12012 (start_inferior, attach_inferior): No longer clear cont_thread.
12013 (handle_v_cont): No longer set cont_thread.
12014 (captured_main): Clear cont_thread each time a GDB connects.
12015
12016 2014-11-12 Pedro Alves <palves@redhat.com>
12017
12018 * linux-low.c (linux_wait_1): Don't force a wait for the Hc
12019 thread, and don't resume all threads if the Hc thread has exited.
12020
12021 2014-11-12 Pedro Alves <palves@redhat.com>
12022
12023 * linux-low.c (linux_request_interrupt): Always send a SIGINT to
12024 the process group instead of to a specific LWP.
12025
12026 2014-10-15 Pedro Alves <palves@redhat.com>
12027
12028 PR server/17487
12029 * win32-arm-low.c (arm_set_thread_context): Remove current_event
12030 parameter.
12031 (arm_set_thread_context): Delete.
12032 (the_low_target): Adjust.
12033 * win32-i386-low.c (debug_registers_changed)
12034 (debug_registers_used): Delete.
12035 (update_debug_registers_callback): New function.
12036 (x86_dr_low_set_addr, x86_dr_low_set_control): Mark all threads as
12037 needing to update their debug registers.
12038 (win32_get_current_dr): New function.
12039 (x86_dr_low_get_addr, x86_dr_low_get_control)
12040 (x86_dr_low_get_status): Fetch the debug register from the thread
12041 record's context.
12042 (i386_initial_stuff): Adjust.
12043 (i386_get_thread_context): Remove current_event parameter. Don't
12044 clear debug_registers_changed nor copy DR values to
12045 debug_reg_state.
12046 (i386_set_thread_context): Delete.
12047 (i386_prepare_to_resume): New function.
12048 (i386_thread_added): Mark the thread as needing to update irs
12049 debug registers.
12050 (the_low_target): Remove i386_set_thread_context and install
12051 i386_prepare_to_resume.
12052 * win32-low.c (win32_get_thread_context): Adjust.
12053 (win32_set_thread_context): Use SetThreadContext
12054 directly.
12055 (win32_prepare_to_resume): New function.
12056 (win32_require_context): New function, factored out from ...
12057 (thread_rec): ... this.
12058 (continue_one_thread): Call win32_prepare_to_resume on each thread
12059 we're about to continue.
12060 (win32_resume): Call win32_prepare_to_resume on the event thread.
12061 * win32-low.h (struct win32_thread_info)
12062 <debug_registers_changed>: New field.
12063 (struct win32_target_ops): Change prototype of set_thread_context,
12064 delete set_thread_context and add prepare_to_resume.
12065 (win32_require_context): New declaration.
12066
12067 2014-10-08 Gary Benson <gbenson@redhat.com>
12068
12069 * server.h: Do not include common-exceptions.h.
12070
12071 2014-10-08 Gary Benson <gbenson@redhat.com>
12072
12073 * server.h: Do not include cleanups.h.
12074
12075 2014-09-30 James Hogan <james.hogan@imgtec.com>
12076
12077 * Makefile.in (clean): Add rm -f commands for mips-dsp-linux.c and
12078 mips64-dsp-linux.c.
12079
12080 2014-09-23 Yao Qi <yao@codesourcery.com>
12081
12082 * linux-low.c (lp_status_maybe_breakpoint): New function.
12083 (linux_low_filter_event): Call lp_status_maybe_breakpoint.
12084 (count_events_callback): Likewise.
12085 (select_event_lwp_callback): Likewise.
12086 (cancel_breakpoints_callback): Likewise.
12087
12088 2014-09-19 Don Breazeal <donb@codesourcery.com>
12089
12090 * linux-low.c (handle_extended_wait): Call
12091 linux_ptrace_get_extended_event.
12092 (get_stop_pc, get_detach_signal, linux_low_filter_event): Call
12093 linux_is_extended_waitstatus.
12094
12095 2014-09-16 Joel Brobecker <brobecker@adacore.com>
12096
12097 * Makefile.in (CPPFLAGS): Define.
12098 (INTERNAL_CFLAGS_BASE): Add ${CPPFLAGS}.
12099 (IPAGENT_CFLAGS): Remove ${CPPFLAGS}.
12100
12101 2014-09-16 Gary Benson <gbenson@redhat.com>
12102
12103 * inferiors.h (current_inferior): Renamed as...
12104 (current_thread): New variable. All uses updated.
12105 * linux-low.c (get_pc): Renamed saved_inferior as saved_thread.
12106 (maybe_move_out_of_jump_pad): Likewise.
12107 (cancel_breakpoint): Likewise.
12108 (linux_low_filter_event): Likewise.
12109 (wait_for_sigstop): Likewise.
12110 (linux_resume_one_lwp): Likewise.
12111 (need_step_over_p): Likewise.
12112 (start_step_over): Likewise.
12113 (linux_stabilize_threads): Renamed save_inferior as saved_thread.
12114 * linux-x86-low.c (x86_linux_update_xmltarget): Likewise.
12115 * proc-service.c (ps_lgetregs): Renamed reg_inferior as reg_thread
12116 and save_inferior as saved_thread.
12117 * regcache.c (get_thread_regcache): Renamed saved_inferior as
12118 saved_thread.
12119 (regcache_invalidate_thread): Likewise.
12120 * remote-utils.c (prepare_resume_reply): Likewise.
12121 * thread-db.c (thread_db_get_tls_address): Likewise.
12122 (disable_thread_event_reporting): Likewise.
12123 (remove_thread_event_breakpoints): Likewise.
12124 * tracepoint.c (gdb_agent_about_to_close): Renamed save_inferior
12125 as saved_thread.
12126 * target.h (set_desired_inferior): Renamed as...
12127 (set_desired_thread): New declaration. All uses updated.
12128 * server.c (myresume): Updated comment to reference thread instead
12129 of inferior.
12130 (handle_serial_event): Likewise.
12131 (handle_target_event): Likewise.
12132
12133 2014-09-12 Tom Tromey <tromey@redhat.com>
12134 Gary Benson <gbenson@redhat.com>
12135
12136 * regcache.h: Include common-regcache.h.
12137 (regcache_read_pc): Don't declare.
12138 * regcache.c (get_thread_regcache_for_ptid): New function.
12139
12140 2014-09-11 Tom Tromey <tromey@redhat.com>
12141 Gary Benson <gbenson@redhat.com>
12142
12143 * symbol.c: New file.
12144 * Makefile.in (SFILES): Add symbol.c.
12145 (OBS): Add symbol.o.
12146
12147 2014-09-11 Gary Benson <gbenson@redhat.com>
12148
12149 * target.c (target_stop_ptid, target_continue_ptid): New
12150 functions.
12151
12152 2014-09-11 Tom Tromey <tromey@redhat.com>
12153 Gary Benson <gbenson@redhat.com>
12154
12155 * target.h: Include target/target.h.
12156 * target.c (target_read_memory, target_read_uint32)
12157 (target_write_memory): New functions.
12158
12159 2014-09-11 Gary Benson <gbenson@redhat.com>
12160
12161 * server.h (debug_hw_points): Don't declare.
12162 * server.c (debug_hw_points): Don't define. Replace all uses
12163 with show_debug_regs.
12164 * linux-aarch64-low.c (debug_hw_points): Don't define. Replace
12165 all uses with show_debug_regs.
12166
12167 2014-09-08 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
12168
12169 * linux-ppc-low.c (ppc_collect_ptrace_register): Adjust routine to take
12170 endianness into account.
12171 (ppc_supply_ptrace_register): Likewise.
12172
12173 2014-09-03 James Hogan <james.hogan@imgtec.com>
12174
12175 * linux-mips-low.c (mips_read_description): Reset errno to 0 prior
12176 to reading DSP_CONTROL with PTRACE_PEEKUSER ptrace call.
12177
12178 2014-09-03 Gary Benson <gbenson@redhat.com>
12179
12180 * linux-x86-low.c (x86_linux_prepare_to_resume): Use
12181 ALL_DEBUG_ADDRESS_REGISTERS.
12182
12183 2014-09-02 Gary Benson <gbenson@redhat.com>
12184
12185 * i386-low.h: Renamed as...
12186 * x86-low.h: New file. All type, function and variable name
12187 prefixes changed from "i386_" to "x86_". All references updated.
12188 * i386-low.c: Renamed as...
12189 * x86-low.c: New file. All type, function and variable name
12190 prefixes changed from "i386_" to "x86_". All references updated.
12191
12192 2014-09-02 Gary Benson <gbenson@redhat.com>
12193
12194 * linux-x86-low.c (x86_linux_new_process): Use XCNEW.
12195 (x86_linux_new_thread): Likewise.
12196
12197 2014-08-29 Gary Benson <gbenson@redhat.com>
12198
12199 * server.h (setjmp.h): Do not include.
12200 (toplevel): Do not declare.
12201 (common-exceptions.h): Include.
12202 (cleanups.h): Likewise.
12203 * server.c (toplevel): Do not define.
12204 (exit_code): New static global.
12205 (detach_or_kill_for_exit_cleanup): New function.
12206 (main): New function. Original main renamed to...
12207 (captured_main): New function.
12208 * utils.c (verror) [!IN_PROCESS_AGENT]: Use throw_verror.
12209
12210 2014-08-29 Gary Benson <gbenson@redhat.com>
12211
12212 * Makefile.in (SFILES): Add common/common-exceptions.c.
12213 (OBS): Add common-exceptions.o.
12214 (common-exceptions.o): New rule.
12215 * utils.c (prepare_to_throw_exception): New function.
12216
12217 2014-08-29 Gary Benson <gbenson@redhat.com>
12218
12219 * config.in: Regenerate.
12220 * configure: Likewise.
12221
12222 2014-08-29 Gary Benson <gbenson@redhat.com>
12223
12224 * Makefile.in (SFILES): Add common/cleanups.c.
12225 (OBS): cleanups.o.
12226 (cleanups.o): New rule.
12227
12228 2014-08-29 Gary Benson <gbenson@redhat.com>
12229
12230 * utils.c (internal_vwarning): New function.
12231
12232 2014-08-28 Gary Benson <gbenson@redhat.com>
12233
12234 * utils.h (fatal): Remove declaration.
12235 * utils.c (fatal): Remove function.
12236
12237 2014-08-28 Gary Benson <gbenson@redhat.com>
12238
12239 * tracepoint.c (gdb_agent_init): Replace fatal with
12240 perror_with_name.
12241 (initialize_tracepoint): Likewise.
12242
12243 2014-08-28 Gary Benson <gbenson@redhat.com>
12244
12245 * remote-utils.c (remote_prepare): Replace fatal with error.
12246
12247 2014-08-28 Gary Benson <gbenson@redhat.com>
12248
12249 * linux-low.c (linux_async): Replace fatal with warning.
12250 Tidy up and return.
12251 (linux_start_non_stop): Return -1 if linux_async failed.
12252
12253 2014-08-28 Gary Benson <gbenson@redhat.com>
12254
12255 * linux-x86-low.c (i386_dr_low_set_addr): Replace check with
12256 gdb_assert.
12257 (i386_dr_low_get_addr): Remove vague comment.
12258 * win32-i386-low.c (i386_dr_low_set_addr): Replace check with
12259 gdb_assert.
12260
12261 2014-08-28 Gary Benson <gbenson@redhat.com>
12262
12263 * inferiors.c (get_thread_process): Replace check with gdb_assert.
12264 * linux-low.c (linux_wait_for_event_filtered): Replace fatal with
12265 internal_error.
12266 (linux_resume_one_lwp): Likewise.
12267 * linux-x86-low.c (x86_siginfo_fixup): Replace checks with
12268 gdb_assert.
12269 * mem-break.c (raw_bkpt_type_to_target_hw_bp_type): Replace fatal
12270 with internal_error.
12271 * regcache.c (get_thread_regcache): Replace check with gdb_assert.
12272 (init_register_cache): Replace fatal with gdb_assert_not_reached.
12273 (find_register_by_name): Replace fatal with internal_error.
12274 (find_regno): Likewise.
12275 * tdesc.c (init_target_desc): Replace check with gdb_assert.
12276 * thread-db.c (thread_db_create_event): Likewise.
12277 (thread_db_load_search): Likewise.
12278 (try_thread_db_load_1): Likewise.
12279 * tracepoint.c (get_jump_space_head): Replace fatal with
12280 internal_error.
12281 (claim_trampoline_space): Likewise.
12282 (have_fast_tracepoint_trampoline_buffer): Likewise.
12283 (cmd_qtstart): Likewise.
12284 (stop_tracing): Likewise.
12285 (fast_tracepoint_collecting): Likewise.
12286 (target_malloc): Likewise.
12287 (download_tracepoint): Likewise.
12288 (download_trace_state_variables): Replace check with gdb_assert.
12289 (upload_fast_traceframes): Replace fatal with internal_error.
12290
12291 2014-08-19 Tom Tromey <tromey@redhat.com>
12292 Gary Benson <gbenson@redhat.com>
12293
12294 * Makefile.in (SFILES): Add common/common-debug.c.
12295 (OBS): Add common-debug.o.
12296 (common-debug.o): New rule.
12297 * debug.h (debug_printf): Don't declare.
12298 * debug.c (debug_printf): Renamed and rewritten as...
12299 (debug_vprintf): New function.
12300
12301 2014-08-19 Gary Benson <gbenson@redhat.com>
12302
12303 * utils.h: Do not include print-utils.h.
12304
12305 2014-08-19 Tom Tromey <tromey@redhat.com>
12306 Gary Benson <gbenson@redhat.com>
12307
12308 * server.h: Add static assertion.
12309 (gdb_byte, CORE_ADDR, LONGEST, ULONGEST): Remove.
12310
12311 2014-08-19 Tom Tromey <tromey@redhat.com>
12312 Gary Benson <gbenson@redhat.com>
12313
12314 * Makefile.in (SFILES): Add common/errors.c.
12315 (OBS): Add errors.o.
12316 (IPA_OBS): Add errors-ipa.o.
12317 (errors.o): New rule.
12318 (errors-ipa.o): Likewise.
12319 * utils.h (perror_with_name, error, warning): Don't declare.
12320 * utils.c (warning): Renamed and rewritten as...
12321 (vwarning): New function.
12322 (error): Renamed and rewritten as...
12323 (verror): New function.
12324 (internal_error): Renamed and rewritten as...
12325 (internal_verror): New function.
12326
12327 2014-08-07 Gary Benson <gbenson@redhat.com>
12328
12329 * configure.ac (AC_CHECK_HEADERS): Remove errno.h.
12330 * configure: Regenerate.
12331 * config.in: Likewise.
12332 * server.h: Do not include errno.h.
12333 * event-loop.c: Likewise.
12334 * hostio-errno.c: Likewise.
12335 * linux-low.c: Likewise.
12336 * remote-utils.c: Likewise.
12337 * spu-low.c: Likewise.
12338 * utils.c: Likewise.
12339 * gdbreplay.c: Unconditionally include errno.h.
12340
12341 2014-08-07 Gary Benson <gbenson@redhat.com>
12342
12343 * server.h: Do not include string.h.
12344 * event-loop.c: Likewise.
12345 * linux-low.c: Likewise.
12346 * regcache.c: Likewise.
12347 * remote-utils.c: Likewise.
12348 * spu-low.c: Likewise.
12349 * utils.c: Likewise.
12350
12351 2014-08-07 Gary Benson <gbenson@redhat.com>
12352
12353 * server.h: Do not include gdb_assert.h.
12354
12355 2014-08-07 Gary Benson <gbenson@redhat.com>
12356
12357 * server.h: Do not include common-utils.h.
12358
12359 2014-08-07 Gary Benson <gbenson@redhat.com>
12360
12361 * server.h: Do not include ptid.h.
12362 * notif.h: Likewise.
12363
12364 2014-08-07 Gary Benson <gbenson@redhat.com>
12365
12366 * server.h: Do not include gdb_locale.h.
12367
12368 2014-08-07 Gary Benson <gbenson@redhat.com>
12369
12370 * server.h: Do not include gdb/signals.h.
12371 * win32-low.c: Likewise.
12372
12373 2014-08-07 Gary Benson <gbenson@redhat.com>
12374
12375 * server.h: Do not include pathmax.h.
12376
12377 2014-08-07 Gary Benson <gbenson@redhat.com>
12378
12379 * server.h: Do not include libiberty.h.
12380 * linux-bfin-low.c: Likewise.
12381
12382 2014-08-07 Gary Benson <gbenson@redhat.com>
12383
12384 * server.h: Do not include ansidecl.h.
12385
12386 2014-08-07 Gary Benson <gbenson@redhat.com>
12387
12388 * linux-x86-low.c: Do not include stddef.h.
12389 * lynx-ppc-low.c: Likewise.
12390 * tracepoint.c: Likewise.
12391
12392 2014-08-07 Gary Benson <gbenson@redhat.com>
12393
12394 * server.h: Do not include stdarg.h.
12395 * nto-low.c: Likewise.
12396
12397 2014-08-07 Gary Benson <gbenson@redhat.com>
12398
12399 * server.h: Do not include stdlib.h.
12400 * inferiors.c: Likewise.
12401 * linux-low.c: Likewise.
12402 * regcache.c: Likewise.
12403 * spu-low.c: Likewise.
12404 * tracepoint.c: Likewise.
12405 * utils.c: Likewise.
12406
12407 2014-08-07 Gary Benson <gbenson@redhat.com>
12408
12409 * server.h: Do not include stdio.h.
12410 * linux-low.c: Likewise.
12411 * remote-utils.c: Likewise.
12412 * spu-low.c: Likewise.
12413 * utils.c: Likewise.
12414 * wincecompat.c: Likewise.
12415
12416 2014-08-06 Gary Benson <gbenson@redhat.com>
12417
12418 * regcache.c (init_register_cache): Move conditionals inside if.
12419
12420 2014-08-06 Gary Benson <gbenson@redhat.com>
12421
12422 * linux-low.c (linux_supports_non_stop): Use target_is_async_p.
12423
12424 2014-07-31 Gary Benson <gbenson@redhat.com>
12425
12426 * ax.h: Do not include server.h.
12427 * gdbthread.h: Likewise.
12428 * lynx-low.h: Likewise.
12429 * notif.h: Likewise.
12430
12431 2014-07-30 Gary Benson <gbenson@redhat.com>
12432
12433 * server.h: Include common-defs.h.
12434 Do not include config.h or build-gnulib-gdbserver/config.h.
12435
12436 2014-07-30 Gary Benson <gbenson@redhat.com>
12437
12438 * hostio-errno.c: Move server.h to top of includes list.
12439 * inferiors.c: Likewise.
12440 * linux-x86-low.c: Likewise.
12441 * notif.c: Include server.h.
12442
12443 2014-07-24 Tom Tromey <tromey@redhat.com>
12444 Gary Benson <gbenson@redhat.com>
12445
12446 * server.h (CORE_ADDR): Now unsigned.
12447
12448 2014-07-16 Pedro Alves <palves@redhat.com>
12449
12450 * linux-low.c (linux_kill_one_lwp): Use kill_lwp, not kill.
12451
12452 2014-07-15 Pedro Alves <palves@redhat.com>
12453
12454 * linux-low.c (linux_kill_one_lwp): Save errno and work with saved
12455 copy.
12456
12457 2014-07-11 Pedro Alves <palves@redhat.com>
12458
12459 * linux-low.c (kill_wait_lwp): New function, based on
12460 kill_one_lwp_callback, but use my_waitpid directly.
12461 (kill_one_lwp_callback, linux_kill): Use it.
12462
12463 2014-06-23 Pedro Alves <palves@redhat.com>
12464
12465 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR_CONTROL
12466 before setting DR0..DR3.
12467
12468 2014-06-20 Gary Benson <gbenson@redhat.com>
12469
12470 * configure.ac (AC_REPLACE_FUNCS) <vasprintf, vsnprintf>: Removed.
12471 * configure: Regenerated.
12472 * config.in: Likewise.
12473
12474 2014-06-20 Gary Benson <gbenson@redhat.com>
12475
12476 * Makefile.in (SFILES): Update locations for files moved
12477 from common to nat.
12478 (object file files): Reordered.
12479
12480 2014-06-20 Gary Benson <gbenson@redhat.com>
12481
12482 * i386-low.h (i386_dr_low_can_set_addr): Removed.
12483 (i386_dr_low_set_addr): Likewise.
12484 (i386_dr_low_get_addr): Likewise.
12485 (i386_dr_low_can_set_control): Likewise.
12486 (i386_dr_low_set_control): Likewise.
12487 (i386_dr_low_get_control): Likewise.
12488 (i386_dr_low_get_status): Likewise.
12489 (i386_get_debug_register_length): Likewise.
12490 * linux-x86-low.c (i386_dr_low_set_addr):
12491 Changed signature. Made static.
12492 (i386_dr_low_get_addr): Likewise.
12493 (i386_dr_low_set_control): Likewise.
12494 (i386_dr_low_get_control): Likewise.
12495 (i386_dr_low_get_status): Likewise.
12496 (i386_dr_low): New global variable.
12497 * win32-i386-low.c (i386_dr_low_set_addr):
12498 Changed signature. Made static.
12499 (i386_dr_low_get_addr): Likewise.
12500 (i386_dr_low_set_control): Likewise.
12501 (i386_dr_low_get_control): Likewise.
12502 (i386_dr_low_get_status): Likewise.
12503 (i386_dr_low): New global variable.
12504
12505 2014-06-20 Marcus Shawcroft <marcus.shawcroft@arm.com>
12506
12507 * configure.ac: Invoke. AC_CHECK_TOOL(AR, ar).
12508 * Makefile.in (AR, AR_FLAGS): Define.
12509 * configure: Regenerate.
12510
12511 2014-06-19 Gary Benson <gbenson@redhat.com>
12512
12513 * Makefile.in (i386-dregs.o): New rule.
12514 * configure.srv: Add i386-dregs.o to all targets using i386-low.o.
12515 * i386-low.c (target.h): Remove include.
12516 (TARGET_HAS_DR_LEN_8): Now in i386-dregs.c.
12517 (DR_CONTROL_SHIFT): Likewise.
12518 (DR_CONTROL_SIZE): Likewise.
12519 (DR_RW_EXECUTE): Likewise.
12520 (DR_RW_WRITE): Likewise.
12521 (DR_RW_READ): Likewise.
12522 (DR_RW_IORW): Likewise.
12523 (DR_LEN_1): Likewise.
12524 (DR_LEN_2): Likewise.
12525 (DR_LEN_4): Likewise.
12526 (DR_LEN_8): Likewise.
12527 (DR_LOCAL_ENABLE_SHIFT): Likewise.
12528 (DR_GLOBAL_ENABLE_SHIFT): Likewise.
12529 (DR_ENABLE_SIZE): Likewise.
12530 (DR_LOCAL_SLOWDOWN): Likewise.
12531 (DR_GLOBAL_SLOWDOWN): Likewise.
12532 (DR_CONTROL_RESERVED): Likewise.
12533 (I386_DR_CONTROL_MASK): Likewise.
12534 (I386_DR_VACANT): Likewise.
12535 (I386_DR_LOCAL_ENABLE): Likewise.
12536 (I386_DR_GLOBAL_ENABLE): Likewise.
12537 (I386_DR_DISABLE): Likewise.
12538 (I386_DR_SET_RW_LEN): Likewise.
12539 (I386_DR_GET_RW_LEN): Likewise.
12540 (I386_DR_WATCH_HIT): Likewise.
12541 (i386_wp_op_t): Likewise.
12542 (i386_show_dr): Likewise.
12543 (i386_length_and_rw_bits): Likewise.
12544 (i386_insert_aligned_watchpoint): Likewise.
12545 (i386_remove_aligned_watchpoint): Likewise.
12546 (i386_handle_nonaligned_watchpoint): Likewise.
12547 i386_update_inferior_debug_regs(): Likewise.
12548 (i386_dr_insert_watchpoint): Likewise.
12549 (i386_dr_remove_watchpoint): Likewise.
12550 (i386_dr_region_ok_for_watchpoint): Likewise.
12551 (i386_dr_stopped_data_address): Likewise.
12552 (i386_dr_stopped_by_watchpoint): Likewise.
12553
12554 2014-06-19 Gary Benson <gbenson@redhat.com>
12555
12556 * i386-low.c (i386_dr_show): Renamed to
12557 i386_show_dr and made static. All uses updated.
12558 (i386_dr_length_and_rw_bits): Renamed to
12559 i386_length_and_rw_bits and made static.
12560 All uses updated.
12561 (i386_dr_insert_aligned_watchpoint): Renamed to
12562 i386_insert_aligned_watchpoint and made static.
12563 All uses updated.
12564 (i386_dr_remove_aligned_watchpoint): Renamed to
12565 i386_remove_aligned_watchpoint and made static.
12566 All uses updated.
12567 (i386_dr_update_inferior_debug_regs): Renamed to
12568 i386_update_inferior_debug_regs and made static.
12569 All uses updated.
12570
12571 2014-06-18 Gary Benson <gbenson@redhat.com>
12572
12573 * i386-low.h (i386_dr_low_can_set_addr): New macro.
12574 (i386_dr_low_can_set_control): Likewise.
12575 (i386_get_debug_register_length): Likewise.
12576 * i386-low.c (i386_dr_low_can_set_addr): Now in i386-low.h.
12577 (i386_dr_low_can_set_control): Likewise.
12578 (i386_get_debug_register_length): Likewise.
12579
12580 2014-06-17 Gary Benson <gbenson@redhat.com>
12581
12582 * i386-low.h (i386-dregs.h): New include.
12583 (DR_FIRSTADDR): Now in i386-dregs.h.
12584 (DR_LASTADDR): Likewise.
12585 (DR_NADDR): Likewise.
12586 (DR_STATUS): Likewise.
12587 (DR_CONTROL): Likewise.
12588 (i386_debug_reg_state): Likewise.
12589 (i386_dr_insert_watchpoint): Likewise.
12590 (i386_dr_remove_watchpoint): Likewise.
12591 (i386_dr_region_ok_for_watchpoint): Likewise.
12592 (i386_dr_stopped_data_address): Likewise.
12593 (i386_dr_stopped_by_watchpoint): Likewise.
12594 * i386-low.c (ALL_DEBUG_REGISTERS): Likewise.
12595
12596 2014-06-18 Gary Benson <gbenson@redhat.com>
12597
12598 * i386-low.h (i386_low_insert_watchpoint): Renamed to
12599 i386_dr_insert_watchpoint.
12600 (i386_low_remove_watchpoint): Renamed to
12601 i386_dr_remove_watchpoint.
12602 (i386_low_region_ok_for_watchpoint): Renamed to
12603 i386_dr_region_ok_for_watchpoint.
12604 (i386_low_stopped_data_address): Renamed to
12605 i386_dr_stopped_data_address.
12606 (i386_low_stopped_by_watchpoint): Renamed to
12607 i386_dr_stopped_by_watchpoint.
12608 * i386-low.c (i386_show_dr): Renamed to
12609 i386_dr_show and made nonstatic. All uses updated.
12610 (i386_length_and_rw_bits): Renamed to
12611 i386_dr_length_and_rw_bits and made nonstatic.
12612 All uses updated.
12613 (i386_insert_aligned_watchpoint): Renamed to
12614 i386_dr_insert_aligned_watchpoint and made nonstatic.
12615 All uses updated.
12616 (i386_remove_aligned_watchpoint): Renamed to
12617 i386_dr_remove_aligned_watchpoint and made nonstatic.
12618 All uses updated.
12619 (i386_update_inferior_debug_regs): Renamed to
12620 i386_dr_update_inferior_debug_regs and made nonstatic.
12621 All uses updated.
12622 (i386_low_insert_watchpoint): Renamed to
12623 i386_dr_insert_watchpoint. All uses updated.
12624 (i386_low_remove_watchpoint): Renamed to
12625 i386_dr_remove_watchpoint. All uses updated.
12626 (i386_low_region_ok_for_watchpoint): Renamed to
12627 i386_dr_region_ok_for_watchpoint. All uses updated.
12628 (i386_low_stopped_data_address): Renamed to
12629 i386_dr_stopped_data_address. All uses updated.
12630 (i386_low_stopped_by_watchpoint): Renamed to
12631 i386_dr_stopped_by_watchpoint. All uses updated.
12632
12633 2014-06-18 Gary Benson <gbenson@redhat.com>
12634
12635 * i386-low.c (i386_dr_low_can_set_addr): New macro.
12636 (i386_dr_low_can_set_control): Likewise.
12637 (i386_insert_aligned_watchpoint): New check.
12638
12639 2014-06-18 Gary Benson <gbenson@redhat.com>
12640
12641 * i386-low.c (i386_update_inferior_debug_regs) <inf_state>:
12642 Renamed to state.
12643
12644 2014-06-18 Gary Benson <gbenson@redhat.com>
12645
12646 * i386-low.c (i386_length_and_rw_bits): Use internal_error
12647 instead of fatal and error.
12648 (i386_handle_nonaligned_watchpoint): Likewise.
12649
12650 2014-06-18 Gary Benson <gbenson@redhat.com>
12651
12652 * i386-low.c (i386_get_debug_register_length): New macro.
12653 (TARGET_HAS_DR_LEN_8): Remove conditional. Use above macro.
12654 (i386_show_dr): Use debug_printf instead of fprintf. Use
12655 phex to format values.
12656
12657 2014-06-18 Gary Benson <gbenson@redhat.com>
12658
12659 * i386-low.h: Comment changes.
12660 * i386-low.c: Likewise.
12661
12662 2014-06-18 Gary Benson <gbenson@redhat.com>
12663
12664 * i386-low.c: Whitespace changes.
12665
12666 2014-06-12 Tom Tromey <tromey@redhat.com>
12667
12668 * utils.c (freeargv): Remove.
12669
12670 2014-06-12 Tom Tromey <tromey@redhat.com>
12671
12672 * debug.c (debug_printf): Remove HAVE_GETTIMEOFDAY checks.
12673 * server.c (monitor_show_help): Remove HAVE_GETTIMEOFDAY check.
12674 (parse_debug_format_options): Likewise.
12675 (gdbserver_usage): Likewise.
12676 * Makefile.in (LIBIBERTY_BUILDDIR, LIBIBERTY): New variables.
12677 (SUBDIRS, REQUIRED_SUBDIRS): Add libiberty.
12678 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Depend on and link
12679 against libiberty.
12680 ($(LIBGNU)): Depend on libiberty.
12681 (all-lib): Recurse into all subdirs.
12682 (install-only): Invoke "install" target in subdirs.
12683 (vasprintf.o, vsnprintf.o, safe-ctype.o, lbasename.o): Remove
12684 targets.
12685 * configure: Rebuild.
12686 * configure.ac: Add ACX_CONFIGURE_DIR for libiberty. Don't check
12687 for vasprintf, vsnprintf, or gettimeofday.
12688 * configure.srv: Don't add safe-ctype.o or lbasename.o to
12689 srv_tgtobj.
12690
12691 2014-06-05 Joel Brobecker <brobecker@adacore.com>
12692
12693 * development.sh: Delete.
12694 * Makefile.in (config.status): Adjust dependency on development.sh.
12695 * configure.ac: Adjust development.sh source call.
12696 * configure: Regenerate.
12697
12698 2014-06-02 Pedro Alves <palves@redhat.com>
12699
12700 * ax.c (gdb_free_agent_expr): New function.
12701 * ax.h (gdb_free_agent_expr): New declaration.
12702 * mem-break.c (delete_gdb_breakpoint_1): Also clear the commands
12703 list.
12704 (clear_breakpoint_conditions, clear_breakpoint_commands): Make
12705 static.
12706 (clear_breakpoint_conditions_and_commands): New function.
12707 * mem-break.h (clear_breakpoint_conditions): Delete declaration.
12708 (clear_breakpoint_conditions_and_commands): New declaration.
12709
12710 2014-05-23 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
12711
12712 * linux-aarch64-low.c (asm/ptrace.h): Include.
12713
12714 2014-05-21 Jan Kratochvil <jan.kratochvil@redhat.com>
12715
12716 Fix TLS access for -static -pthread.
12717 * gdbserver/thread-db.c (struct thread_db): Add td_thr_tlsbase_p.
12718 (thread_db_get_tls_address): Call it if LOAD_MODULE is zero.
12719 (thread_db_load_search, try_thread_db_load_1): Initialize it.
12720
12721 2014-05-20 Pedro Alves <palves@redhat.com>
12722
12723 * linux-aarch64-low.c (aarch64_insert_point)
12724 (aarch64_remove_point): No longer check whether the type is
12725 supported here. Adjust to new interface.
12726 (the_low_target): Install aarch64_supports_z_point_type as
12727 supports_z_point_type method.
12728 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type): New function.
12729 (arm_linux_hw_point_initialize): Take an enum raw_bkpt_type
12730 instead of a Z packet char. Adjust.
12731 (arm_supports_z_point_type): New function.
12732 (arm_insert_point, arm_remove_point): Adjust to new interface.
12733 (the_low_target): Install arm_supports_z_point_type.
12734 * linux-crisv32-low.c (cris_supports_z_point_type): New function.
12735 (cris_insert_point, cris_remove_point): Adjust to new interface.
12736 Don't check whether the type is supported here.
12737 (the_low_target): Install cris_supports_z_point_type.
12738 * linux-low.c (linux_supports_z_point_type): New function.
12739 (linux_insert_point, linux_remove_point): Adjust to new interface.
12740 * linux-low.h (struct linux_target_ops) <insert_point,
12741 remove_point>: Take an enum raw_bkpt_type instead of a char. Add
12742 raw_breakpoint pointer parameter.
12743 <supports_z_point_type>: New method.
12744 * linux-mips-low.c (mips_supports_z_point_type): New function.
12745 (mips_insert_point, mips_remove_point): Adjust to new interface.
12746 Use mips_supports_z_point_type.
12747 (the_low_target): Install mips_supports_z_point_type.
12748 * linux-ppc-low.c (the_low_target): Install NULL as
12749 supports_z_point_type method.
12750 * linux-s390-low.c (the_low_target): Install NULL as
12751 supports_z_point_type method.
12752 * linux-sparc-low.c (the_low_target): Install NULL as
12753 supports_z_point_type method.
12754 * linux-x86-low.c (x86_supports_z_point_type): New function.
12755 (x86_insert_point): Adjust to new insert_point interface. Use
12756 insert_memory_breakpoint. Adjust to new
12757 i386_low_insert_watchpoint interface.
12758 (x86_remove_point): Adjust to remove_point interface. Use
12759 remove_memory_breakpoint. Adjust to new
12760 i386_low_remove_watchpoint interface.
12761 (the_low_target): Install x86_supports_z_point_type.
12762 * lynx-low.c (lynx_target_ops): Install NULL as
12763 supports_z_point_type callback.
12764 * nto-low.c (nto_supports_z_point_type): New.
12765 (nto_insert_point, nto_remove_point): Adjust to new interface.
12766 (nto_target_ops): Install nto_supports_z_point_type.
12767 * mem-break.c: Adjust intro comment.
12768 (struct raw_breakpoint) <raw_type, size>: New fields.
12769 <inserted>: Update comment.
12770 <shlib_disabled>: Delete field.
12771 (enum bkpt_type) <gdb_breakpoint>: Delete value.
12772 <gdb_breakpoint_Z0, gdb_breakpoint_Z1, gdb_breakpoint_Z2,
12773 gdb_breakpoint_Z3, gdb_breakpoint_Z4>: New values.
12774 (raw_bkpt_type_to_target_hw_bp_type): New function.
12775 (find_enabled_raw_code_breakpoint_at): New function.
12776 (find_raw_breakpoint_at): New type and size parameters. Use them.
12777 (insert_memory_breakpoint): New function, based off
12778 set_raw_breakpoint_at.
12779 (remove_memory_breakpoint): New function.
12780 (set_raw_breakpoint_at): Reimplement.
12781 (set_breakpoint): New, based on set_breakpoint_at.
12782 (set_breakpoint_at): Reimplement.
12783 (delete_raw_breakpoint): Go through the_target->remove_point
12784 instead of assuming memory breakpoints.
12785 (find_gdb_breakpoint_at): Delete.
12786 (Z_packet_to_bkpt_type, Z_packet_to_raw_bkpt_type): New functions.
12787 (find_gdb_breakpoint): New function.
12788 (set_gdb_breakpoint_at): Delete.
12789 (z_type_supported): New function.
12790 (set_gdb_breakpoint_1): New function, loosely based off
12791 set_gdb_breakpoint_at.
12792 (check_gdb_bp_preconditions, set_gdb_breakpoint): New functions.
12793 (delete_gdb_breakpoint_at): Delete.
12794 (delete_gdb_breakpoint_1): New function, loosely based off
12795 delete_gdb_breakpoint_at.
12796 (delete_gdb_breakpoint): New function.
12797 (clear_gdb_breakpoint_conditions): Rename to ...
12798 (clear_breakpoint_conditions): ... this. Don't handle a NULL
12799 breakpoint.
12800 (add_condition_to_breakpoint): Make static.
12801 (add_breakpoint_condition): Take a struct breakpoint pointer
12802 instead of an address. Adjust.
12803 (gdb_condition_true_at_breakpoint): Rename to ...
12804 (gdb_condition_true_at_breakpoint_z_type): ... this, and add
12805 z_type parameter.
12806 (gdb_condition_true_at_breakpoint): Reimplement.
12807 (add_breakpoint_commands): Take a struct breakpoint pointer
12808 instead of an address. Adjust.
12809 (gdb_no_commands_at_breakpoint): Rename to ...
12810 (gdb_no_commands_at_breakpoint_z_type): ... this. Add z_type
12811 parameter. Return true if no breakpoint was found. Change debug
12812 output.
12813 (gdb_no_commands_at_breakpoint): Reimplement.
12814 (run_breakpoint_commands): Rename to ...
12815 (run_breakpoint_commands_z_type): ... this. Add z_type parameter,
12816 and change return type to boolean.
12817 (run_breakpoint_commands): New function.
12818 (gdb_breakpoint_here): Also check for Z1 breakpoints.
12819 (uninsert_raw_breakpoint): Don't try to reinsert a disabled
12820 breakpoint. Go through the_target->remove_point instead of
12821 assuming memory breakpoint.
12822 (uninsert_breakpoints_at, uninsert_all_breakpoints): Uninsert
12823 software and hardware breakpoints.
12824 (reinsert_raw_breakpoint): Go through the_target->insert_point
12825 instead of assuming memory breakpoint.
12826 (reinsert_breakpoints_at, reinsert_all_breakpoints): Reinsert
12827 software and hardware breakpoints.
12828 (check_breakpoints, breakpoint_here, breakpoint_inserted_here):
12829 Check both software and hardware breakpoints.
12830 (validate_inserted_breakpoint): Assert the breakpoint is a
12831 software breakpoint. Set the inserted flag to -1 instead of
12832 setting shlib_disabled.
12833 (delete_disabled_breakpoints): Adjust.
12834 (validate_breakpoints): Only validate software breakpoints.
12835 Adjust to inserted flag change.
12836 (check_mem_read, check_mem_write): Skip breakpoint types other
12837 than software breakpoints. Adjust to inserted flag change.
12838 * mem-break.h (enum raw_bkpt_type): New enum.
12839 (raw_breakpoint, struct process_info): Forward declare.
12840 (Z_packet_to_target_hw_bp_type): Delete declaration.
12841 (raw_bkpt_type_to_target_hw_bp_type, Z_packet_to_raw_bkpt_type)
12842 (set_gdb_breakpoint, delete_gdb_breakpoint)
12843 (clear_breakpoint_conditions): New declarations.
12844 (set_gdb_breakpoint_at, clear_gdb_breakpoint_conditions): Delete.
12845 (breakpoint_inserted_here): Update comment.
12846 (add_breakpoint_condition, add_breakpoint_commands): Replace
12847 address parameter with a breakpoint pointer parameter.
12848 (gdb_breakpoint_here): Update comment.
12849 (delete_gdb_breakpoint_at): Delete.
12850 (insert_memory_breakpoint, remove_memory_breakpoint): Declare.
12851 * server.c (process_point_options): Take a struct breakpoint
12852 pointer instead of an address. Adjust.
12853 (process_serial_event) <Z/z packets>: Use set_gdb_breakpoint and
12854 delete_gdb_breakpoint.
12855 * spu-low.c (spu_target_ops): Install NULL as
12856 supports_z_point_type method.
12857 * target.h: Include mem-break.h.
12858 (struct target_ops) <prepare_to_access_memory>: Update comment.
12859 <supports_z_point_type>: New field.
12860 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
12861 instead of a char. Also take a raw breakpoint pointer.
12862 * win32-arm-low.c (the_low_target): Install NULL as
12863 supports_z_point_type.
12864 * win32-i386-low.c (i386_supports_z_point_type): New function.
12865 (i386_insert_point, i386_remove_point): Adjust to new interface.
12866 (the_low_target): Install i386_supports_z_point_type.
12867 * win32-low.c (win32_supports_z_point_type): New function.
12868 (win32_insert_point, win32_remove_point): Adjust to new interface.
12869 (win32_target_ops): Install win32_supports_z_point_type.
12870 * win32-low.h (struct win32_target_ops):
12871 <supports_z_point_type>: New method.
12872 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
12873 instead of a char. Also take a raw breakpoint pointer.
12874
12875 2014-05-20 Pedro Alves <palves@redhat.com>
12876
12877 * mem-break.h: Include break-common.h.
12878 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
12879 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): New defines.
12880 (Z_packet_to_target_hw_bp_type): New declaration.
12881 * mem-break.c (Z_packet_to_target_hw_bp_type): New function.
12882 * i386-low.c (Z_PACKET_HW_BP, Z_PACKET_WRITE_WP, Z_PACKET_READ_WP)
12883 (Z_PACKET_ACCESS_WP): Delete macros.
12884 (Z_packet_to_hw_type): Delete function.
12885 * i386-low.h: Don't include break-common.h here.
12886 (Z_packet_to_hw_type): Delete declaration.
12887 * linux-x86-low.c (x86_insert_point, x86_insert_point): Call
12888 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
12889 * win32-i386-low.c (i386_insert_point, i386_remove_point): Call
12890 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
12891 * linux-aarch64-low.c: Don't include break-common.h here.
12892 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
12893 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): Delete macros.
12894 (Z_packet_to_target_hw_bp_type): Delete function.
12895 * linux-mips-low.c (rsp_bp_type_to_target_hw_bp_type): Delete
12896 function.
12897 (mips_insert_point, mips_remove_point): Use
12898 Z_packet_to_target_hw_bp_type.
12899
12900 2014-05-20 Pedro Alves <palves@redhat.com>
12901
12902 * linux-aarch64-low.c: Include break-common.h.
12903 (enum target_point_type): Delete.
12904 (Z_packet_to_point_type): Rename to ...
12905 (Z_packet_to_target_hw_bp_type): ... this, and return a
12906 target_hw_bp_type instead.
12907 (aarch64_show_debug_reg_state): Take an enum target_hw_bp_type
12908 instead of an enum target_point_type.
12909 (aarch64_point_encode_ctrl_reg): Likewise. Compute type mask from
12910 breakpoint type.
12911 (aarch64_dr_state_insert_one_point)
12912 (aarch64_dr_state_remove_one_point, aarch64_handle_breakpoint)
12913 (aarch64_handle_aligned_watchpoint)
12914 (aarch64_handle_unaligned_watchpoint, aarch64_handle_watchpoint):
12915 Take an enum target_hw_bp_type instead of an enum
12916 target_point_type.
12917 (aarch64_supports_z_point_type): New function.
12918 (aarch64_insert_point, aarch64_remove_point): Use it. Adjust to
12919 use Z_packet_to_target_hw_bp_type.
12920
12921 2014-05-20 Joel Brobecker <brobecker@adacore.com>
12922
12923 * configure.ac: Only use -Werror by default when DEVELOPMENT
12924 is true.
12925 * configure: Regenerate.
12926
12927 2014-05-19 Jan Kratochvil <jan.kratochvil@redhat.com>
12928
12929 Fix gdbserver qGetTLSAddr for x86_64 -m32.
12930 * linux-x86-low.c (X86_64_USER_REGS): New.
12931 (x86_fill_gregset): Call memset for BUF first in x86_64 -m32 case.
12932
12933 2014-04-28 Yao Qi <yao@codesourcery.com>
12934
12935 * Makefile.in (i386-avx512.c): Fix the typo of generated file
12936 name.
12937
12938 2014-04-25 Pedro Alves <palves@redhat.com>
12939
12940 PR server/16255
12941 * linux-low.c (linux_attach_fail_reason_string): New function.
12942 (linux_attach_lwp): Delete.
12943 (linux_attach_lwp_1): Rename to ...
12944 (linux_attach_lwp): ... this. Take a ptid instead of a pid as
12945 argument. Remove "initial" parameter. Return int instead of
12946 void. Don't error or warn here.
12947 (linux_attach): Adjust to call linux_attach_lwp. Call error on
12948 failure to attach to the tgid. Call warning when failing to
12949 attach to an lwp.
12950 * linux-low.h (linux_attach_lwp): Take a ptid instead of a pid as
12951 argument. Remove "initial" parameter. Return int instead of
12952 void. Don't error or warn here.
12953 (linux_attach_fail_reason_string): New declaration.
12954 * thread-db.c (attach_thread): Adjust to linux_attach_lwp's
12955 interface change. Use linux_attach_fail_reason_string.
12956
12957 2014-04-24 Michael Sturm <michael.sturm@mintel.com>
12958 Walfred Tedeschi <walfred.tedeschi@intel.com>
12959
12960 * Makefile.in: Added rules to handle new files
12961 i386-avx512.c i386-avx512-linux.c amd64-avx512.c
12962 amd64-avx512-linux.c x32-avx512.c x32-avx512-linux.c.
12963 * configure.srv (srv_i386_regobj): Add i386-avx512.o.
12964 (srv_i386_linux_regobj): Add i386-avx512-linux.o.
12965 (srv_amd64_regobj): Add amd64-avx512.o and x32-avx512.o.
12966 (srv_amd64_linux_regobj): Add amd64-avx512-linux.o and
12967 x32-avx512-linux.o.
12968 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx512.xml.
12969 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx512.xml.
12970 (srv_amd64_xmlfiles): Add i386/amd64-avx512.xml and
12971 i386/x32-avx512.xml.
12972 (srv_i386_linux_xmlfiles): Add i386/i386-avx512-linux.xml.
12973 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx512-linux.xml and
12974 i386/x32-avx512-linux.xml.
12975 * i387-fp.c (num_avx512_k_registers): New constant for number
12976 of K registers.
12977 (num_avx512_zmmh_low_registers): New constant for number of
12978 lower ZMM registers (0-15).
12979 (num_avx512_zmmh_high_registers): New constant for number of
12980 higher ZMM registers (16-31).
12981 (num_avx512_ymmh_registers): New contant for number of higher
12982 YMM registers (ymm16-31 added by avx521 on x86_64).
12983 (num_avx512_xmm_registers): New constant for number of higher
12984 XMM registers (xmm16-31 added by AVX512 on x86_64).
12985 (struct i387_xsave): Add space for AVX512 registers.
12986 (i387_cache_to_xsave): Change raw buffer size to 64 characters.
12987 Add code to handle AVX512 registers.
12988 (i387_xsave_to_cache): Add code to handle AVX512 registers.
12989 * linux-x86-low.c (init_registers_amd64_avx512_linux): New
12990 prototypei from generated file.
12991 (tdesc_amd64_avx512_linux): Likewise.
12992 (init_registers_x32_avx512_linux): Likewise.
12993 (tdesc_x32_avx512_linux): Likewise.
12994 (init_registers_i386_avx512_linux): Likewise.
12995 (tdesc_i386_avx512_linux): Likewise.
12996 (x86_64_regmap): Add AVX512 registers.
12997 (x86_linux_read_description): Add code to handle AVX512 XSTATE
12998 mask.
12999 (initialize_low_arch): Add code to initialize AVX512 registers.
13000
13001 2014-04-23 Pedro Alves <palves@redhat.com>
13002
13003 * mem-break.c (find_gdb_breakpoint_at): Make static.
13004 * mem-break.h (find_gdb_breakpoint_at): Delete declaration.
13005
13006 2014-04-23 Pedro Alves <palves@redhat.com>
13007
13008 * i386-low.c: Don't include break-common.h here.
13009 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
13010 prototype to take target_hw_bp_type as argument instead of a Z
13011 packet char.
13012 * i386-low.h: Include break-common.h here.
13013 (Z_packet_to_hw_type): Declare.
13014 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
13015 prototypes.
13016 * linux-x86-low.c (x86_insert_point): Convert the packet number to
13017 a target_hw_bp_type before calling i386_low_insert_watchpoint.
13018 (x86_remove_point): Convert the packet number to a
13019 target_hw_bp_type before calling i386_low_remove_watchpoint.
13020 * win32-i386-low.c (i386_insert_point): Convert the packet number
13021 to a target_hw_bp_type before calling i386_low_insert_watchpoint.
13022 (i386_remove_point): Convert the packet number to a
13023 target_hw_bp_type before calling i386_low_remove_watchpoint.
13024
13025 2014-04-23 Pedro Alves <palves@redhat.com>
13026
13027 * utils.h (perror_with_name): Add ATTRIBUTE_NORETURN.
13028
13029 2014-04-10 Pedro Alves <palves@redhat.com>
13030
13031 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
13032 Check if the condition or command is NULL before checking if the
13033 breakpoint is known. On success, return true.
13034 * mem-break.h (add_breakpoint_condition): Document return.
13035 (add_breakpoint_commands): Add describing comment.
13036 * server.c (skip_to_semicolon): New function.
13037 (process_point_options): Use it.
13038
13039 2014-04-09 Pedro Alves <palves@redhat.com>
13040
13041 * linux-low.c (linux_read_loadmap): Pass current_inferior directly
13042 to lwpid_of.
13043
13044 2014-02-27 Pedro Alves <palves@redhat.com>
13045
13046 PR 12702
13047 * inferiors.h (A_I_NEXT, ALL_INFERIORS_TYPE, ALL_PROCESSES): New
13048 macros.
13049 * linux-low.c (delete_lwp, handle_extended_wait): Add debug
13050 output.
13051 (last_thread_of_process_p): Take a PID argument instead of a
13052 thread pointer.
13053 (linux_wait_for_lwp): Delete.
13054 (num_lwps, check_zombie_leaders, not_stopped_callback): New
13055 functions.
13056 (linux_low_filter_event): New function, party factored out from
13057 linux_wait_for_event.
13058 (linux_wait_for_event): Rename to ...
13059 (linux_wait_for_event_filtered): ... this. Add new filter ptid
13060 argument. Partly rewrite. Always use waitpid(-1, WNOHANG) and
13061 sigsuspend. Check for zombie leaders.
13062 (linux_wait_for_event): Reimplement as wrapper around
13063 linux_wait_for_event_filtered.
13064 (linux_wait_1): Handle TARGET_WAITKIND_NO_RESUMED. Assume that if
13065 a normal or signal exit is seen, it's the whole process exiting.
13066 (wait_for_sigstop): No longer a for_each_inferior callback.
13067 Rewrite on top of linux_wait_for_event_filtered.
13068 (stop_all_lwps): Call wait_for_sigstop directly.
13069 * server.c (resume, handle_target_event): Handle
13070 TARGET_WAITKIND_NO_RESUMED.
13071
13072 2014-02-26 Joel Brobecker <brobecker@adacore.com>
13073
13074 * win32-low.c (psapi_get_dll_name,
13075 * win32_CreateToolhelp32Snapshot): Delete.
13076 (win32_CreateToolhelp32Snapshot, win32_Module32First)
13077 (win32_Module32Next, load_toolhelp, toolhelp_get_dll_name):
13078 Delete.
13079 (handle_load_dll): Add function description.
13080 Remove code using psapi_get_dll_name and toolhelp_get_dll_name.
13081
13082 2014-02-26 Joel Brobecker <brobecker@adacore.com>
13083
13084 * win32-low.c (win32_add_one_solib): Add 0x1000 to load_addr.
13085 Add comment.
13086 (win32_add_all_dlls): Remove 0x1000 offset applied to DLL
13087 base address when calling win32_add_one_solib.
13088 (handle_load_dll): Delete local variable load_addr.
13089 Remove 0x1000 offset applied to DLL base address when calling
13090 win32_add_one_solib.
13091 (handle_unload_dll): Add comment.
13092
13093 2014-02-26 Joel Brobecker <brobecker@adacore.com>
13094
13095 * win32-low.c (win32_add_all_dlls): Renames
13096 win32_ensure_ntdll_loaded. Rewrite function documentation.
13097 Adjust implementation to always load all DLLs.
13098 Add 0x1000 offset to DLL base address when calling
13099 win32_add_one_solib.
13100 (child_initialization_done): New static global.
13101 (do_initial_child_stuff): Set child_initialization_done to
13102 zero during child initialization, and 1 after. Replace call
13103 to win32_ensure_ntdll_loaded by call to win32_add_all_dlls.
13104 Add comment.
13105 (match_dll_by_basename, dll_is_loaded_by_basename): Delete.
13106 (handle_unload_dll): Add function documentation.
13107 (get_child_debug_event): Ignore load and unload DLL events
13108 during child initialization.
13109
13110 2014-02-20 Doug Evans <dje@google.com>
13111
13112 Remove global all_lwps.
13113 * inferiors.h (ptid_of): Move here from linux-low.h.
13114 (pid_of, lwpid_of): Ditto.
13115 * linux-aarch64-low.c (debug_reg_change_callback): Update, "entry"
13116 parameter is a struct thread_info * now.
13117 (aarch64_notify_debug_reg_change): Fetch pid from current_inferior
13118 directly. Pass &all_threads to find_inferior instead of &all_lwps.
13119 (aarch64_stopped_data_address): Fetch lwpid from current_inferior
13120 directly.
13121 (aarch64_linux_prepare_to_resume): Fetch ptid from thread.
13122 (aarch64_arch_setup): Fetch lwpid from current_inferior directly.
13123 * linux-arm-low.c (update_registers_callback): Update, "entry"
13124 parameter is a struct thread_info * now.
13125 Fetch lwpid from current_inferior directly.
13126 (arm_insert_point): Pass &all_threads to find_inferior instead of
13127 &all_lwps.
13128 (arm_remove_point): Ditto.
13129 (arm_stopped_by_watchpoint): Fetch lwp from current_inferior.
13130 (arm_prepare_to_resume): Fetch pid from thread.
13131 (arm_read_description): Fetch lwpid from current_inferior directly.
13132 * linux-low.c (all_lwps): Delete.
13133 (delete_lwp): Delete call to remove_inferior.
13134 (handle_extended_wait): Fetch lwpid from thread.
13135 (add_lwp): Don't set lwp->entry.id. Remove call to
13136 add_inferior_to_list.
13137 (linux_attach_lwp_1): Fetch pid from current_inferior directly.
13138 (linux_kill_one_lwp): Fetch ptid,lwpid from thread.
13139 (kill_one_lwp_callback): Ditto.
13140 (linux_kill): Don't dereference NULL pointer.
13141 Fetch ptid,lwpid from thread.
13142 (get_detach_signal): Fetch ptid from thread.
13143 (linux_detach_one_lwp): Fetch ptid,lwpid from thread.
13144 Simplify call to regcache_invalidate_thread.
13145 (delete_lwp_callback): Update, "entry" parameter is a
13146 struct thread_info * now. Fetch pid from thread.
13147 (linux_mourn): Pass &all_threads to find_inferior instead of &all_lwps.
13148 (status_pending_p_callback): Update, "entry" parameter is a
13149 struct thread_info * now. Fetch ptid from thread.
13150 (find_lwp_pid): Update, "entry" parameter is a
13151 struct thread_info * now.
13152 (linux_wait_for_lwp): Fetch pid from thread.
13153 (linux_fast_tracepoint_collecting): Fetch lwpid from thread.
13154 (maybe_move_out_of_jump_pad): Fetch lwpid from current_inferior.
13155 (enqueue_one_deferred_signal): Fetch lwpid from thread.
13156 (dequeue_one_deferred_signal): Ditto.
13157 (cancel_breakpoint): Fetch ptid from current_inferior.
13158 (linux_wait_for_event): Pass &all_threads to find_inferior,
13159 not &all_lwps. Fetch ptid, lwpid from thread.
13160 (count_events_callback): Update, "entry" parameter is a
13161 struct thread_info * now.
13162 (select_singlestep_lwp_callback): Ditto.
13163 (select_event_lwp_callback): Ditto.
13164 (cancel_breakpoints_callback): Ditto.
13165 (linux_cancel_breakpoints): Pass &all_threads to find_inferior,
13166 not &all_lwps.
13167 (select_event_lwp): Ditto. Fetch ptid from event_thread.
13168 (unsuspend_one_lwp): Update, "entry" parameter is a
13169 struct thread_info * now.
13170 (unsuspend_all_lwps): Pass &all_threads to find_inferior,
13171 not &all_lwps.
13172 (linux_stabilize_threads): Ditto. And for for_each_inferior.
13173 Fetch lwpid from thread, not lwp.
13174 (linux_wait_1): Fetch ptid, lwpid from current_inferior.
13175 Pass &all_threads to find_inferior, not &all_lwps.
13176 (send_sigstop): Fetch lwpid from thread, not lwp.
13177 (send_sigstop_callback): Update, "entry" parameter is a
13178 struct thread_info * now.
13179 (suspend_and_send_sigstop_callback): Ditto.
13180 (wait_for_sigstop): Ditto. Fetch ptid, lwpid from thread, lwp.
13181 (stuck_in_jump_pad_callback): Update, "entry" parameter is a
13182 struct thread_info * now.
13183 (move_out_of_jump_pad_callback): Ditto. Fetch ptid, lwpid
13184 from thread, lwp.
13185 (lwp_running): Update, "entry" parameter is a
13186 struct thread_info * now.
13187 (stop_all_lwps): Fetch ptid from thread.
13188 Pass &all_threads to find_inferior, for_each_inferior, not &all_lwps.
13189 (linux_resume_one_lwp): Fetch lwpid from thread.
13190 (linux_set_resume_request): Update, "entry" parameter is a
13191 struct thread_info * now. Fetch pid, lwpid from thread.
13192 (resume_status_pending_p): Update, "entry" parameter is a
13193 struct thread_info * now.
13194 (need_step_over_p): Ditto. Fetch lwpid from thread.
13195 (start_step_over): Fetch lwpid from thread.
13196 (linux_resume_one_thread): Update, "entry" parameter is a
13197 struct thread_info * now. Fetch lwpid from thread.
13198 (linux_resume): Pass &all_threads to find_inferior, not &all_lwps.
13199 (proceed_one_lwp): Update, "entry" parameter is a
13200 struct thread_info * now. Fetch lwpid from thread.
13201 (unsuspend_and_proceed_one_lwp): Update, "entry" parameter is a
13202 struct thread_info * now.
13203 (proceed_all_lwps): Pass &all_threads to find_inferior, not &all_lwps.
13204 (unstop_all_lwps): Ditto. Fetch lwpid from thread.
13205 (regsets_fetch_inferior_registers): Fetch lwpid from current_inferior
13206 directly.
13207 (regsets_store_inferior_registers): Ditto.
13208 (fetch_register, store_register): Ditto.
13209 (linux_read_memory, linux_write_memory): Ditto.
13210 (linux_request_interrupt): Ditto.
13211 (linux_read_auxv): Ditto.
13212 (linux_xfer_siginfo): Ditto.
13213 (linux_qxfer_spu): Ditto.
13214 (linux_qxfer_libraries_svr4): Ditto.
13215 * linux-low.h (ptid_of, pid_of, lwpid_of): Delete,
13216 moved to inferiors.h.
13217 (get_lwp): Delete.
13218 (get_thread_lwp): Update.
13219 (struct lwp_info): Delete member "entry". Simplify comment for
13220 member "thread".
13221 (all_lwps): Delete.
13222 * linux-mips-low.c (mips_read_description): Fetch lwpid from
13223 current_inferior directly.
13224 (update_watch_registers_callback): Update, "entry" parameter is a
13225 struct thread_info * now. Fetch pid from thread.
13226 (mips_linux_prepare_to_resume): Fetch ptid from thread.
13227 (mips_insert_point): Fetch lwpid from current_inferior.
13228 Pass &all_threads to find_inferior, not &all_lwps.
13229 (mips_remove_point): Pass &all_threads to find_inferior, not &all_lwps.
13230 (mips_stopped_by_watchpoint): Fetch lwpid from current_inferior
13231 directly.
13232 (mips_stopped_data_address): Ditto.
13233 * linux-s390-low.c (s390_arch_setup): Fetch pid from current_inferior
13234 directly.
13235 * linux-tile-low.c (tile_arch_setup): Ditto.
13236 * linux-x86-low.c (x86_get_thread_area): Fetch lwpid from thread.
13237 (update_debug_registers_callback): Update, "entry" parameter is a
13238 struct thread_info * now. Fetch pid from thread.
13239 (i386_dr_low_set_addr): Fetch pid from current_inferior directly.
13240 Pass &all_threads to find_inferior, not &all_lwps.
13241 (i386_dr_low_get_addr): Fetch ptid from current_inferior directly.
13242 (i386_dr_low_set_control): Fetch pid from current_inferior directly.
13243 Pass &all_threads to find_inferior, not &all_lwps.
13244 (i386_dr_low_get_control): Fetch ptid from current_inferior directly.
13245 (i386_dr_low_get_status): Ditto.
13246 (x86_linux_prepare_to_resume): Fetch ptid from thread.
13247 (x86_siginfo_fixup): Fetch lwpid from current_inferior directly.
13248 (x86_linux_read_description): Ditto.
13249 * proc-service.c (ps_getpid): Fetch pid from current_inferior directly.
13250
13251 2014-02-20 Doug Evans <dje@google.com>
13252
13253 * inferiors.c (get_first_inferior): Fix buglet.
13254
13255 2014-02-19 Doug Evans <dje@google.com>
13256
13257 * gdbthread.h (add_thread): Change result type to struct thread_info *.
13258 * inferiors.c (add_thread): Change result type to struct thread_info *.
13259 All callers updated.
13260 (add_lwp): Call add_thread here instead of in callers.
13261 All callers updated.
13262 * linux-low.h (get_lwp_thread): Rewrite.
13263 (struct lwp_info): New member "thread".
13264
13265 2014-02-19 Doug Evans <dje@google.com>
13266
13267 * linux-low.c (add_lwp): Change result to struct lwp_info *.
13268 All callers updated.
13269
13270 2014-02-19 Doug Evans <dje@google.com>
13271
13272 * inferiors.c (add_thread): Fix whitespace.
13273
13274 2014-02-19 Doug Evans <dje@google.com>
13275
13276 * dll.c (clear_dlls): Replace accessing list implemention details
13277 with API function.
13278 * gdbthread.h (get_first_thread): Declare.
13279 * inferiors.c (for_each_inferior_with_data): New function.
13280 (get_first_thread): New function.
13281 (find_thread_ptid): Simplify.
13282 (get_first_inferior): New function.
13283 (clear_list): Delete.
13284 (one_inferior_p): New function.
13285 (clear_inferior_list): New function.
13286 (clear_inferiors): Update.
13287 * inferiors.h (for_each_inferior_with_data): Declare.
13288 (clear_inferior_list): Declare.
13289 (one_inferior_p): Declare.
13290 (get_first_inferior): Declare.
13291 * linux-low.c (linux_wait_for_event): Replace accessing list
13292 implemention details with API function.
13293 * server.c (target_running): Ditto.
13294 (accumulate_file_name_length): New function.
13295 (emit_dll_description): New function.
13296 (handle_qxfer_libraries): Replace accessing list implemention
13297 details with API function.
13298 (handle_qxfer_threads_worker): New function.
13299 (handle_qxfer_threads_proper): Replace accessing list implemention
13300 details with API function.
13301 (handle_query): Ditto.
13302 (visit_actioned_threads_callback_ftype): New typedef.
13303 (visit_actioned_threads_data): New struct.
13304 (visit_actioned_threads): Rewrite to be find_inferior callback.
13305 (resume): Call find_inferior.
13306 (handle_status): Replace accessing list implemention
13307 details with API function.
13308 (process_serial_event): Replace accessing list implemention details
13309 with API function.
13310 * target.c (set_desired_inferior): Replace accessing list implemention
13311 details with API function.
13312 * tracepoint.c (same_process_p): New function.
13313 (gdb_agent_about_to_close): Replace accessing list implemention
13314 details with API function.
13315 * win32-low.c (child_delete_thread): Replace accessing list
13316 implemention details with API function.
13317 (match_dll_by_basename): New function.
13318 (dll_is_loaded_by_basename): New function.
13319 (win32_ensure_ntdll_loaded): Replace accessing list implemention
13320 details call to dll_is_loaded_by_basename.
13321
13322 2014-02-19 Doug Evans <dje@google.com>
13323
13324 * dll.h (struct dll_info): Add comment.
13325 * gdbthread.h (struct thread_info): Add comment.
13326 (current_ptid): Simplify.
13327 * inferiors.c (add_process): Update.
13328 (remove_process): Update.
13329 * inferiors.h (struct process_info): Rename member "head" to "entry".
13330 * linux-low.c (delete_lwp): Update.
13331 (add_lwp): Update.
13332 (last_thread_of_process_p): Update.
13333 (kill_one_lwp_callback, linux_kill): Update.
13334 (status_pending_p_callback): Update.
13335 (wait_for_sigstop): Update. Simplify read of ptid.
13336 (start_step_over): Update.
13337 * linux-low.h (ptid_of, pid_of, lwpid_of): Update.
13338 (get_lwp_thread): Update.
13339 (struct lwp_info): Rename member "head" to "entry".
13340 * regcache.h (inferior_list_entry): Delete.
13341 * server.c (kill_inferior_callback): Update.
13342 (detach_or_kill_inferior_callback): Update.
13343 (print_started_pid): Update.
13344 (print_attached_pid): Update.
13345 (process_serial_event): Simplify read of ptid.
13346 * thread-db.c (thread_db_create_event): Update.
13347 (thread_db_get_tls_address): Update.
13348 * win32-low.c (current_inferior_ptid): Simplify.
13349
13350 2014-02-19 Tom Tromey <tromey@redhat.com>
13351
13352 * target.h (struct target_ops) <supports_btrace>: Add target_ops
13353 argument.
13354 (target_supports_btrace): Update.
13355
13356 2014-02-14 Yao Qi <yao@codesourcery.com>
13357
13358 * Makefile.in (IPA_OBJS): Append rsp-low-ipa.o.
13359 (rsp-low-ipa.o): New target.
13360
13361 2014-02-12 Tom Tromey <tromey@redhat.com>
13362
13363 * ax.c (gdb_parse_agent_expr): Use hex2bin, not
13364 convert_ascii_to_int.
13365 * regcache.c (registers_to_string): Likewise.
13366 * remote-utils.c (decode_M_packet): Likewise.
13367 * server.c (process_serial_event): Likewise.
13368
13369 2014-02-12 Tom Tromey <tromey@redhat.com>
13370
13371 * server.c (handle_query, handle_v_run): Use hex2bin, not
13372 unhexify.
13373 * tracepoint.c (cmd_qtdpsrc, cmd_qtdv, cmd_qtnotes): Likewise.
13374
13375 2014-02-12 Tom Tromey <tromey@redhat.com>
13376
13377 * ax.c (gdb_unparse_agent_expr): Use bin2hex, not
13378 convert_int_to_ascii.
13379 * regcache.c (registers_to_string, collect_register_as_string):
13380 Likewise.
13381 * remote-utils.c (look_up_one_symbol, relocate_instruction):
13382 Likewise.
13383 * server.c (process_serial_event): Likewise.
13384 * tracepoint.c (cmd_qtstatus, response_source, response_tsv)
13385 (cmd_qtbuffer, cstr_to_hexstr): Likewise.
13386
13387 2014-02-12 Tom Tromey <tromey@redhat.com>
13388
13389 * remote-utils.c (look_up_one_symbol, monitor_output): Use
13390 bin2hex, not hexify.
13391 * tracepoint.c (cmd_qtstatus): Likewise.
13392
13393 2014-02-12 Tom Tromey <tromey@redhat.com>
13394
13395 * remote-utils.c (monitor_output): Pass explicit length to
13396 hexify.
13397
13398 2014-02-12 Tom Tromey <tromey@redhat.com>
13399
13400 * tracepoint.c: Include rsp-low.h.
13401 * server.c: Include rsp-low.h.
13402 * remote-utils.h (convert_ascii_to_int, convert_int_to_ascii)
13403 (unhexify, hexify, remote_escape_output, unpack_varlen_hex): Don't
13404 declare.
13405 * remote-utils.c: Include rsp-low.h.
13406 (fromhex, hexchars, ishex, unhexify, tohex, hexify)
13407 (remote_escape_output, remote_unescape_input, unpack_varlen_hex)
13408 (convert_int_to_ascii, convert_ascii_to_int): Move to
13409 common/rsp-low.c.
13410 * regcache.c: Include rsp-low.h.
13411 * ax.c: Include rsp-low.h.
13412 * Makefile.in (SFILES): Add common/rsp-low.c.
13413 (OBS): Add rsp-low.o.
13414 (rsp-low.o): New target.
13415
13416 2014-02-12 Tom Tromey <tromey@redhat.com>
13417
13418 * utils.h (pulongest, plongest, phex_nz): Don't declare.
13419 Include print-utils.h.
13420 * utils.c (NUMCELLS, CELLSIZE, get_cell, decimal2str, pulongest)
13421 (plongest, thirty_two, phex_nz): Remove.
13422 * Makefile.in (SFILES): Add common/print-utils.c.
13423 (OBS): Add print-utils.o.
13424 (print-utils-ipa.o): New target.
13425 (print-utils.o): New target.
13426 (IPA_OBJS): Add print-utils-ipa.o.
13427
13428 2014-02-06 Tom Tromey <tromey@redhat.com>
13429
13430 * Makefile.in (SFILES): Fix indentation.
13431
13432 2014-02-05 Doug Evans <dje@google.com>
13433
13434 * linux-low.c (linux_wait_for_event): Improve comment.
13435 (linux_wait_1): Keep current_inferior in sync with event_child.
13436
13437 2014-01-22 Doug Evans <dje@google.com>
13438
13439 * gdbthread.h (gdb_id_to_thread): Delete, unused.
13440
13441 2014-01-22 Doug Evans <dje@google.com>
13442
13443 * configure.ac (AC_CHECK_FUNCS): Add test for gettimeofday.
13444 * configure: Regenerate.
13445 * config.in: Regenerate.
13446 * Makefile.in (SFILES): Add debug.c.
13447 (OBS): Add debug.o.
13448 * debug.c: New file.
13449 * debug.h: New file.
13450 * linux-aarch64-low.c (*): Update all debugging printfs to use
13451 debug_printf instead of fprintf.
13452 * linux-arm-low.c (*): Ditto.
13453 * linux-cris-low.c (*): Ditto.
13454 * linux-crisv32-low.c (*): Ditto.
13455 * linux-m32r-low.c (*): Ditto.
13456 * linux-sparc-low.c (*): Ditto.
13457 * linux-x86.c (*): Ditto.
13458 * linux-low.c (*): Ditto.
13459 (linux_wait_1): Add calls to debug_enter, debug_exit.
13460 (linux_wait): Remove redundant debugging printf.
13461 (stop_all_lwps): Add calls to debug_enter, debug_exit.
13462 (linux_resume, unstop_all_lwps): Ditto.
13463 * mem-break.c (*): Update all debugging printfs to use
13464 debug_printf instead of fprintf.
13465 * remote-utils.c (*): Ditto.
13466 * thread-db.c (*): Ditto.
13467 * server.c #include <ctype.h>, "gdb_vecs.h".
13468 (debug_threads): Moved to debug.c.
13469 (*): Update all debugging printfs to use debug_printf instead of
13470 fprintf.
13471 (start_inferior): Replace call to fflush with call to debug_flush.
13472 (monitor_show_help): Mention set debug-format.
13473 (parse_debug_format_options): New function.
13474 (handle_monitor_command): Handle "monitor set debug-format".
13475 (gdbserver_usage): Mention --debug-format.
13476 (main): Parse --debug-format.
13477 * server.h (debug_threads): Declaration moved to debug.h.
13478 #include "debug.h".
13479 * tracepoint.c (trace_debug_1) [!IN_PROCESS_AGENT]: Add version of
13480 trace_debug_1 that uses debug_printf.
13481 (tracepoint_look_up_symbols): Update all debugging printfs to use
13482 debug_printf instead of fprintf.
13483
13484 2014-01-20 Baruch Siach <baruch@tkos.co.il>
13485
13486 * linux-xtensa-low.c: Include asm/ptrace.h instead of
13487 sys/ptrace.h.
13488
13489 2014-01-17 Pedro Alves <palves@redhat.com>
13490
13491 PR build/16445
13492 * linux-x86-low.c: Don't include elf/common.h if ELFMAG0 is
13493 defined after including gdb_proc_service.h.
13494
13495 2014-01-16 Doug Evans <dje@google.com>
13496
13497 * dll.c (UNSPECIFIED_CORE_ADDR): New macro.
13498 (match_dll): Use it.
13499
13500 2014-01-16 Markus Metzger <markus.t.metzger@intel.com>
13501
13502 * target.h (target_ops) <read_btrace>: Change parameters and
13503 return type to allow error reporting.
13504 * server.c (handle_qxfer_btrace): Support delta reads. Pass
13505 trace reading errors on.
13506 * linux-low.c (linux_low_read_btrace): Pass trace reading
13507 errors on.
13508 (linux_low_disable_btrace): New.
13509
13510 2014-01-15 Doug Evans <dje@google.com>
13511
13512 * inferiors.c (thread_id_to_gdb_id): Delete.
13513 * inferiors.h (thread_id_to_gdb_id): Delete.
13514
13515 2014-01-13 Eli Zaretskii <eliz@gnu.org>
13516
13517 * Makefile.in (INCLUDE_CFLAGS): Remove trailing slash from
13518 "-I$(srcdir)/../". Fixes MinGW compilation errors with old GCC
13519 versions.
13520
13521 2014-01-08 Pedro Alves <palves@redhat.com>
13522
13523 * server.c (handle_status): Don't discard previous queued stop
13524 replies or thread's pending status here.
13525 (main) <disconnection>: Do it here instead.
13526
13527 2014-01-08 Pedro Alves <palves@redhat.com>
13528
13529 * gdbthread.h (struct thread_info) <status_pending_p>: New field.
13530 * server.c (visit_actioned_threads, handle_pending_status): New
13531 function.
13532 (handle_v_cont): Factor out parts to ...
13533 (resume): ... this new function. If in all-stop, and a thread
13534 being resumed has a pending status, report it without actually
13535 resuming.
13536 (myresume): Adjust to use the new 'resume' function.
13537 (clear_pending_status_callback, set_pending_status_callback)
13538 (find_status_pending_thread_callback): New functions.
13539 (handle_status): Handle the case of multiple threads having
13540 interesting statuses to report. Report threads' real last signal
13541 instead of always reporting GDB_SIGNAL_TRAP. Look for a thread
13542 with an interesting thread to report the status for, instead of
13543 always reporting the status of the first thread.
13544
13545 2014-01-01 Joel Brobecker <brobecker@adacore.com>
13546
13547 * gdbserver.c (gdbserver_version): Set copyright year to 2014.
13548 * gdbreplay.c (gdbreplay_version): Likewise.
13549
13550 2013-12-18 Yufeng Zhang <yufeng.zhang@arm.com>
13551
13552 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Set
13553 iov.iov_len with the real length in use.
13554
13555 2013-12-13 Joel Brobecker <brobecker@adacore.com>
13556
13557 * Makefile.in (safe-ctype.o, lbasename.o): New rules.
13558 * configure.srv: Add safe-ctype.o and lbasename.o to srv_tgtobj
13559 for all targets that use win32-low.c.
13560 * win32-low.c (win32_ensure_ntdll_loaded): New function.
13561 (do_initial_child_stuff): Add call to win32_ensure_ntdll_loaded.
13562
13563 2013-12-13 Pedro Alves <palves@redhat.com>
13564
13565 * target.c (mywait): Set OURSTATUS->KIND to TARGET_WAITKIND_STOPPED
13566 if equal to TARGET_WAITKIND_LOADED.
13567 * win32-low.c (cached_status): New static global.
13568 (win32_wait): Add declaration.
13569 (do_initial_child_stuff): Flush all initial pending debug events
13570 up to the initial breakpoint.
13571 (win32_wait): If CACHED_STATUS was set, return that instead
13572 of doing a real wait. Remove the code resuming the execution
13573 of the inferior after receiving a TARGET_WAITKIND_LOADED event
13574 during the initial phase. Also remove the code changing
13575 OURSTATUS->KIND from TARGET_WAITKIND_LOADED to
13576 TARGET_WAITKIND_STOPPED.
13577
13578 2013-12-11 Yao Qi <yao@codesourcery.com>
13579
13580 * notif.c (handle_notif_ack): Return 0 if no notification
13581 matches.
13582
13583 2013-11-20 Doug Evans <dje@google.com>
13584
13585 * linux-low.c (linux_set_resume_request): Fix comment.
13586
13587 2013-11-20 Doug Evans <dje@google.com>
13588
13589 * linux-low.c (resume_status_pending_p): Tweak comment.
13590
13591 2013-11-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
13592
13593 * Makefile.in: Add i386-mpx.c, i386-mpx-linux.c, amd64-mpx.c,
13594 amd64-mpx-linux.c, x32-mpx.c and x32-mpx-linux.c generation.
13595 * configure.srv (srv_i386_regobj): Add i386-mpx.o.
13596 (srv_i386_linux_regobj): Add i386-mpx-linux.o.
13597 (srv_amd64_regobj): Add amd64-mpx.o.
13598 (srv_amd64_linux_regobj): Add amd64-mpx-linux.o.
13599 (srv_i386_32bit_xmlfiles): Add i386/32bit-mpx.xml.
13600 (srv_i386_64bit_xmlfiles): Add i386/64bit-mpx.xml.
13601 * i387-fp.c (num_pl_bnd_register) Added constant.
13602 (num_pl_bnd_cfg_registers) Added constant.
13603 (struct i387_xsave) Added reserved area and MPX fields.
13604 (i387_cache_to_xsave, i387_xsave_to_cache) Add MPX.
13605 * linux-x86-low.c (init_registers_i386_mpx_linux): Declare new
13606 function.
13607 (tdesc_i386_mpx_linux): Add MPX amd64 target.
13608 (init_registers_amd64_mpx_linux): Declare new function.
13609 (tdesc_amd64_mpx_linux): Add MPX amd64 target.
13610 (x86_64_regmap): Add MPX registers.
13611 (x86_linux_read_description): Add MPX case.
13612 (initialize_low_arch): Initialize MPX targets.
13613
13614 2013-11-18 Tom Tromey <tromey@redhat.com>
13615
13616 * configure: Rebuild.
13617 * configure.ac: Don't check for stdlib.h.
13618 * gdbreplay.c: Unconditionally include stdlib.h.
13619
13620 2013-11-18 Tom Tromey <tromey@redhat.com>
13621
13622 * config.in: Rebuild.
13623 * configure: Rebuild.
13624 * configure.ac: Don't use AC_HEADER_DIRENT.
13625
13626 2013-11-18 Tom Tromey <tromey@redhat.com>
13627
13628 * server.h: Don't check HAVE_STRING_H.
13629 * gdbreplay.c: Don't check HAVE_STRING_H.
13630 * configure: Rebuild.
13631
13632 2013-11-18 Tom Tromey <tromey@redhat.com>
13633
13634 * Makefile.in (gdbreplay$(EXEEXT)): Depend on and link against
13635 LIBGNU.
13636
13637 2013-11-08 Tom Tromey <tromey@redhat.com>
13638
13639 * configure, config.in: Rebuild.
13640 * configure.ac: Remove unused configury.
13641
13642 2013-11-08 Tom Tromey <tromey@redhat.com>
13643
13644 * acinclude.m4: Include common.m4, codeset.m4.
13645 * configure, config.in: Rebuild.
13646 * configure.ac: Use GDB_AC_COMMON.
13647
13648 2013-11-06 Andreas Arnez <arnez@linux.vnet.ibm.com>
13649
13650 * linux-s390-low.c (HWCAP_S390_TE): New define.
13651 (s390_arch_setup): Consider the TE field in the HWCAP for
13652 determining 'have_regset_tdb'.
13653
13654 2013-10-16 Sergio Durigan Junior <sergiodj@redhat.com>
13655
13656 PR gdb/16014
13657 * tracepoint.c (download_tracepoint_1): Remove unnecessary double
13658 call to sizeof.
13659
13660 2013-10-02 Pedro Alves <palves@redhat.com>
13661
13662 * server.c (process_serial_event): Don't output "GDBserver
13663 exiting" if GDB is connected through stdio.
13664 * target.c (mywait): Likewise, be silent if GDB is connected
13665 through stdio.
13666
13667 2013-10-01 Joel Brobecker <brobecker@adacore.com>
13668
13669 * lynx-low.c (lynx_add_threads_after_attach): New function.
13670 (lynx_attach): Remove call to add_thread. Add call to
13671 lynx_add_threads_after_attach instead.
13672
13673 2013-09-28 Mike Frysinger <vapier@gentoo.org>
13674
13675 * configure.ac (AC_CHECK_HEADERS): Add sys/syscall.h
13676 * config.in, configure: Regenerated.
13677
13678 2013-09-18 Yao Qi <yao@codesourcery.com>
13679
13680 PR server/15959
13681 * server.c (start_inferior): Clear 'resume_info'.
13682
13683 2013-09-16 Jiong Wang <jiwang@tilera.com>
13684
13685 * linux-tile-low.c (tile_regsets): Modify the size field to 64-bit
13686 for each register.
13687
13688 2013-09-16 Jiong Wang <jiwang@tilera.com>
13689
13690 * configure.srv <tilegx*-*-linux*>: Remove linux-osdata.o from and add
13691 linux-tile-low.o to srv_tgtobj.
13692
13693 2013-09-16 Will Newton <will.newton@linaro.org>
13694
13695 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Zero
13696 out regs.
13697
13698 2013-09-06 Pedro Alves <palves@redhat.com>
13699
13700 * Makefile.in (gdb_proc_service_h, regdef_h, regcache_h)
13701 (signals_def, signals_h, ptid_h, ax_h, agent_h, linux_btrace_h)
13702 (linux_osdata_h, vec_h, gdb_vecs_h, host_defs_h, libiberty_h)
13703 (server_h, gdbthread_h, linux_low_h, linux_ptrace_h)
13704 (gdb_thread_db_h, linux_procfs_h, lynx_low_h, nto_low_h)
13705 (mips_linux_watch_h, i386_low_h, win32_low_h): Delete.
13706
13707 2013-09-06 Pedro Alves <palves@redhat.com>
13708
13709 * Makefile.in (linux-btrace.o, mips-linux-watch.o): Remove
13710 explicit header dependencies and use $COMPILE/$POSTCOMPILE.
13711
13712 2013-09-06 Pedro Alves <palves@redhat.com>
13713
13714 * linux-amd64-ipa.c: Include tracepoint.h.
13715 * linux-i386-ipa.c: Include tracepoint.h.
13716
13717 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
13718
13719 * linux-crisv32-low.c (PTRACE_GET_THREAD_AREA): New macro.
13720 (ps_get_thread_area): New function.
13721
13722 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
13723
13724 * linux-crisv32-low.c (elf_gregset_t): Delete typedef.
13725 (initialize_low_arch): Call init_registers_crisv32 rather than
13726 init_register_crisv32.
13727
13728 2013-09-05 Pedro Alves <palves@redhat.com>
13729
13730 * server.h (handle_vFile, hostio_last_error_from_errno): Move
13731 to ...
13732 * hostio.h: ... this new file.
13733 * hostio.c, server.c, linux-low.c, nto-low.c, spu-low,
13734 win32-low.c: Include hostio.h.
13735
13736 2013-09-05 Pedro Alves <palves@redhat.com>
13737
13738 * server.h (gdb_client_data, handler_func, callback_handler_func)
13739 (delete_file_handler, add_file_handler, append_callback_event)
13740 (delete_callback_event, start_event_loop, initialize_event_loop):
13741 Move to event-loop.h and include it.
13742 * event-loop.h: New file.
13743
13744 2013-09-05 Pedro Alves <palves@redhat.com>
13745
13746 * dll.c, inferiors.c, remote-utils.c, server.c: Include "dll.h".
13747 * server.h (struct dll_info, all_dlls, dlls_changed, clear_dlls)
13748 (loaded_dll, unloaded_dll): Move to ...
13749 * dll.h: ... this new file.
13750 * inferiors.c, remote-utils.c, win32-low.c: Include "dll.h".
13751
13752 2013-09-05 Pedro Alves <palves@redhat.com>
13753
13754 * server.h (current_process, get_thread_process, all_processes)
13755 (add_inferior_to_list, for_each_inferior, current_inferior)
13756 (remove_inferior, add_process, remove_process, find_process_pid)
13757 (have_started_inferiors_p, have_attached_inferiors_p)
13758 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id)
13759 (clear_inferiors, find_inferior, find_inferior_id)
13760 (inferior_target_data, set_inferior_target_data)
13761 (inferior_regcache_data, set_inferior_regcache_data): Move to
13762 inferiors.h, and include it.
13763 * inferiors.h: New file.
13764
13765 2013-09-05 Pedro Alves <palves@redhat.com>
13766
13767 * server.h (struct emit_ops, current_insn_ptr, emit_error):
13768 Move ...
13769 * ax.h: ... here.
13770
13771 2013-09-05 Pedro Alves <palves@redhat.com>
13772
13773 * ax.c, linux-low.c, linux-x86-low.c, server.c: Include
13774 tracepoint.h.
13775 * server.h (IPA_BUFSIZ, initialize_tracepoint, tracing)
13776 (disconnected_tracing, tracepoint_look_up_symbols, stop_tracing
13777 (handle_tracepoint_general_set, handle_tracepoint_query)
13778 (tracepoint_finished_step, tracepoint_was_hit)
13779 (release_while_stepping_state_list, current_traceframe)
13780 (in_readonly_region, traceframe_read_mem)
13781 (fetch_traceframe_registers, traceframe_read_sdata)
13782 (traceframe_read_info, struct fast_tpoint_collect_status)
13783 (fast_tracepoint_collecting, force_unlock_trace_buffer)
13784 (handle_tracepoit_bkpts, initialize_low_tracepoint)
13785 (supply_fast_tracepoint_registers)
13786 (supply_static_tracepoint_registers, set_trampoline_buffer_space)
13787 (ipa_tdesc, claim_trampoline_space)
13788 (have_fast_tracepoint_trampoline_buffer, gdb_agent_about_to_close)
13789 (agent_mem_read, agent_get_trace_state_variable_value)
13790 (agent_set_trace_state_variable_value, agent_tsv_read)
13791 (agent_mem_read_string, get_raw_reg_func_addr)
13792 (get_get_tsv_func_addr, get_set_tsv_func_addr): Move to ...
13793 * tracepoint.h: ... this new file.
13794
13795 2013-09-05 Pedro Alves <palves@redhat.com>
13796
13797 * server.h (perror_with_name, error, fatal, warning, paddress)
13798 (pulongest, plongest, phex_nz, pfildes): Move to utils.h, and
13799 include it.
13800 * utils.h: New file.
13801
13802 2013-09-05 Pedro Alves <palves@redhat.com>
13803
13804 * server.h (remote_debug, noack_mode, transport_is_reliable)
13805 (gdb_connected, STDIO_CONNECTION_NAME, remote_connection_is_stdio)
13806 (read_ptid, write_ptid, putpkt, putpkt_binary, putpkt_notif)
13807 (getpkt, remote_prepare, remote_open, remote_close, write_ok)
13808 (write_enn, initialize_async_io, enable_async_io)
13809 (disable_async_io, check_remote_input_interrupt_request)
13810 (convert_ascii_to_int, convert_int_to_ascii, new_thread_notify)
13811 (dead_thread_notify, prepare_resume_reply)
13812 (decode_address_to_semicolon, decode_address, decode_m_packet)
13813 (decode_M_packet, decode_X_packet, decode_xfer_write)
13814 (decode_search_memory_packet, unhexify, hexify)
13815 (remote_escape_output, unpack_varlen_hex, clear_symbol_cache)
13816 (look_up_one_symbol, relocate_instruction)
13817 (monitor_output): Move to remote-utils.h, and include it.
13818 * remote-utils.h: New file.
13819
13820 2013-09-05 Pedro Alves <palves@redhat.com>
13821
13822 * server.h (_): Delete.
13823
13824 2013-09-02 Pedro Alves <palves@redhat.com>
13825
13826 * tracepoint.c (TRACEFRAME_EOB_MARKER_SIZE): New macro.
13827 (init_trace_buffer): Ensure at least TRACEFRAME_EOB_MARKER_SIZE is
13828 allocated.
13829 (trace_buffer_alloc): Use TRACEFRAME_EOB_MARKER_SIZE.
13830
13831 2013-09-02 Pierre Muller <muller@sourceware.org>
13832
13833 * win32-low.c (child_xfer_memory): Check if ReadProcessMemory
13834 or WriteProcessMemory complete successfully and handle
13835 ERROR_PARTIAL_COPY error.
13836
13837 2013-09-02 Pedro Alves <palves@redhat.com>
13838
13839 * server.c (gdb_read_memory): Return -1 on traceframe memory read
13840 error instead of EIO.
13841
13842 2013-08-28 Jan Kratochvil <jan.kratochvil@redhat.com>
13843
13844 PR server/15604
13845 * linux-low.c: Include filestuff.h.
13846 (linux_create_inferior) <pid == 0>: Call close_most_fds.
13847 * lynx-low.c: Include filestuff.h.
13848 (lynx_create_inferior) <pid == 0>: Call close_most_fds.
13849 * server.c: Include filestuff.h.
13850 (main): Call notice_open_fds.
13851 * spu-low.c: Include filestuff.h.
13852 (spu_create_inferior) <pid == 0>: Call close_most_fds.
13853
13854 2013-08-22 Luis Machado <lgustavo@codesourcery.com>
13855
13856 * Makefile.in: Explain why ../target and ../nat are not
13857 listed as include file search paths.
13858 (linux-waitpid.o): New object file rule.
13859 * configure.srv (srv_native_linux_obj): New variable.
13860 Replace all occurrences of linux native object files with
13861 $srv_native_linux_obj.
13862 * linux-low.c: Include nat/linux-nat.h and nat/linux-waitpid.h.
13863 (HAS_NOMMU): Move defining logic to common/linux-ptrace.c.
13864 (linux_enable_event_reporting): Remove declaration.
13865 (my_waitpid): Moved to common/linux-waitpid.c.
13866 (linux_wait_for_event): Pass ptid when calling
13867 linux_enable_event_reporting.
13868 (linux_supports_tracefork_flag): Remove.
13869 (linux_enable_event_reporting): Likewise.
13870 (linux_tracefork_grandchild): Remove.
13871 (STACK_SIZE): Moved to common/linux-ptrace.c.
13872 (linux_tracefork_child): Remove.
13873 (linux_test_for_tracefork): Remove.
13874 (linux_look_up_symbols): Call linux_supports_traceclone.
13875 (initialize_low): Remove call to linux_test_for_tracefork.
13876 * linux-low.h (PTRACE_TYPE_ARG3): Move to
13877 common/linux-ptrace.h.
13878 (PTRACE_TYPE_ARG4): Likewise.
13879 Include linux-ptrace.h.
13880
13881 2013-08-21 Pedro Alves <palves@redhat.com>
13882
13883 * config.in: Renegerate.
13884
13885 2013-08-19 Luis Machado <lgustavo@codesourcery.com>
13886
13887 * Makefile.in (INCLUDE_CFLAGS): Include -I$(srcdir)/../.
13888 (SFILES): Remove $(srcdir)/common/target-common.c and
13889 add $(srcdir)/target/waitstatus.c.
13890 (OBS): Remove target-common.o and add waitstatus.o.
13891 (server_h): Remove $(srcdir)/../common/target-common.h and
13892 add $(srcdir)/../target/resume.h, $(srcdir)/../target/wait.h
13893 and $(srcdir)/../target/waitstatus.h.
13894 (target-common.o): Remove.
13895 (waitstatus.o): New target object file.
13896 * target.h: Do not include target-common.h and
13897 include target/resume.h, target/wait.h and
13898 target/waitstatus.h.
13899
13900 2013-08-13 Luis Machado <lgustavo@codesourcery.com>
13901
13902 * linux-arm-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
13903 to PTRACE_TYPE_ARG3.
13904 * linux-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
13905 to PTRACE_TYPE_ARG3 and PTRACE_ARG4_TYPE to
13906 PTRACE_TYPE_ARG4.
13907 * linux-low.h (PTRACE_ARG3_TYPE): Rename to PTRACE_TYPE_ARG3.
13908 (PTRACE_ARG4_TYPE): Rename to PTRACE_TYPE_ARG4.
13909
13910 2013-07-27 Jie Zhang <jie@codesourcery.com>
13911 Daniel Jacobowitz <dan@codesourcery.com>
13912 Yao Qi <yao@codesourcery.com>
13913
13914 * Makefile.in (SFILES): Add common/mips-linux-watch.c.
13915 (mips-linux-watch.o): New rule.
13916 (mips_linux_watch_h): New variable.
13917 * configure.srv <mips*-*-linux*>: Add mips-linux-watch.o to
13918 srv_tgtobj.
13919 * linux-mips-low.c: Include mips-linux-watch.h.
13920 (struct arch_process_info, struct arch_lwp_info): New.
13921 (update_watch_registers_callback): New function.
13922 (mips_linux_new_process, mips_linux_new_thread) New functions.
13923 (mips_linux_prepare_to_resume, mips_insert_point): New
13924 functions.
13925 (mips_remove_point, mips_stopped_by_watchpoint): New
13926 functions.
13927 (rsp_bp_type_to_target_hw_bp_type): New function.
13928 (mips_stopped_data_address): New function.
13929 (the_low_target): Add watchpoint support functions.
13930
13931 2013-07-27 Yao Qi <yao@codesourcery.com>
13932
13933 * i386-low.c: Include break-common.h.
13934 (enum target_hw_bp_type): Remove.
13935
13936 2013-07-24 Luis Machado <lgustavo@codesourcery.com>
13937
13938 * Makefile.in (SFILES): /common/target-common.c.
13939 (OBS): Add target-common.o.
13940 (server_h): Add $(srcdir)/../common/target-common.h.
13941 (target-common.o): New target.
13942 * server.c (queue_stop_reply_callback): Free
13943 status string after use.
13944 * target.c (target_waitstatus_to_string): Remove.
13945 * target.h: Include target-common.h.
13946 (resume_kind): Likewise.
13947 (target_waitkind): Likewise.
13948 (target_waitstatus): Likewise.
13949 (TARGET_WNOHANG): Likewise.
13950
13951 2013-07-04 Yao Qi <yao@codesourcery.com>
13952
13953 * Makefile.in (host_alias): Use @host_noncanonical@.
13954 (target_alias): Use @target_noncanonical@.
13955 * configure.ac: Use ACX_NONCANONICAL_TARGET and
13956 ACX_NONCANONICAL_HOST.
13957 * configure: Regenerated.
13958
13959 Revert:
13960 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
13961
13962 * configure.ac (version_host, version_target): Set and AC_SUBST them.
13963 * configure: Rebuild.
13964 * Makefile.in (version_host, version_target): Get from configure.
13965 (version.c): Use $(version_host) and $(version_target).
13966
13967 2013-07-03 Pedro Alves <palves@redhat.com>
13968
13969 * Makefile.in (config.status): Depend on development.sh.
13970 * acinclude.m4: Include libmcheck.m4.
13971 * configure: Regenerate.
13972
13973 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
13974
13975 * win32-low.c (winapi_DebugActiveProcessStop): Move the WINAPI
13976 attribute inside the parentheses.
13977 (winapi_DebugSetProcessKillOnExit): Ditto.
13978 (winapi_DebugBreakProcess): Ditto.
13979 (winapi_GenerateConsoleCtrlEvent): Ditto.
13980
13981 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
13982
13983 * notif.h (notif_event): Add a dummy member to avoid compiler
13984 errors.
13985
13986 2013-07-01 Pedro Alves <palves@redhat.com>
13987
13988 * hostio.c (HOSTIO_PATH_MAX): Define.
13989 (require_filename, handle_open, handle_unlink, handle_readlink):
13990 Use it.
13991
13992 2013-07-01 Pedro Alves <palves@redhat.com>
13993
13994 * server.h: Include "pathmax.h".
13995 * linux-low.c: Don't include sys/param.h.
13996 (linux_pid_exe_is_elf_64_file): Use PATH_MAX instead of
13997 MAXPATHLEN.
13998 * win32-low.c: Don't include sys/param.h.
13999 (win32_create_inferior): Use PATH_MAX instead of MAXPATHLEN.
14000
14001 2013-07-01 Pedro Alves <palves@redhat.com>
14002
14003 * event-loop.c: Don't check HAVE_UNISTD_H before including
14004 <unistd.h>.
14005 * gdbreplay.c: Likewise.
14006 * remote-utils.c: Likewise.
14007 * server.c: Likewise.
14008 * configure.ac: Don't check for unistd.h.
14009 * configure: Regenerate.
14010
14011 2013-06-28 Tom Tromey <tromey@redhat.com>
14012
14013 * Makefile.in (version.c): Use version.in, not
14014 common/version.in.
14015
14016 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
14017
14018 * configure.ac (version_host, version_target): Set and AC_SUBST them.
14019 * configure: Rebuild.
14020 * Makefile.in (version_host, version_target): Get from configure.
14021 (version.c): Use $(version_host) and $(version_target).
14022
14023 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
14024
14025 Fix trace-status to output user name without trailing colon.
14026 * tracepoint.c (cmd_qtstatus): Remove unnecessary colon from user name.
14027
14028 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
14029
14030 Fix trace-status to output proper start-time and stop-time.
14031 * tracepoint.c (cmd_qtstatus): Modify trace-status output to
14032 output start time and stop time in hex as gdb expects.
14033
14034 2013-06-26 Pedro Alves <pedro@codesourcery.com>
14035
14036 * tracepoint.c (build_traceframe_info_xml): Output trace state
14037 variables present in the trace buffer.
14038
14039 2013-06-24 Tom Tromey <tromey@redhat.com>
14040
14041 * Makefile.in (version.c): Use bfd/version.h, common/version.in,
14042 create-version.sh.
14043 (version.o): Remove.
14044 * gdbreplay.c: Include version.h.
14045 (version, host_name): Don't declare.
14046 * server.h: Include version.h.
14047 (version, host_name): Don't declare.
14048
14049 2013-06-12 Pedro Alves <palves@redhat.com>
14050
14051 * linux-x86-low.c (linux_is_elf64): Delete global.
14052 (x86_siginfo_fixup): Replace reference to `linux_is_elf64' global
14053 with local linux_pid_exe_is_elf_64_file use.
14054
14055 2013-06-11 Pedro Alves <palves@redhat.com>
14056
14057 * linux-low.c (regset_disabled, disable_regset): New functions.
14058 (regsets_fetch_inferior_registers)
14059 (regsets_store_inferior_registers): Use them.
14060 (initialize_regsets_info); Don't allocate the disabled_regsets
14061 array here.
14062 * linux-low.h (struct regsets_info) <disabled_regsets>: Extend
14063 comment.
14064
14065 2013-06-11 Pedro Alves <palves@redhat.com>
14066
14067 * linux-low.c (initialize_regsets_info): Use xcalloc instead of
14068 xmalloc.
14069
14070 2013-06-11 Pedro Alves <palves@redhat.com>
14071
14072 * linux-x86-low.c (initialize_low_arch): Call
14073 init_registers_x32_avx_linux.
14074
14075 2013-06-09 Jan Kratochvil <jan.kratochvil@redhat.com>
14076
14077 Fix compatibility with Android Bionic.
14078 * linux-low.c (linux_qxfer_libraries_svr4): Ignore first entry even if
14079 it is not empty.
14080
14081 2013-06-07 Pedro Alves <palves@redhat.com>
14082
14083 PR server/14823
14084 * Makefile.in (OBS): Add tdesc.o.
14085 (IPA_OBJS): Add tdesc-ipa.o.
14086 (tdesc-ipa.o): New rule.
14087 * ax.c (gdb_eval_agent_expr): Adjust register_size call to new
14088 interface.
14089 * linux-low.c (new_inferior): Delete.
14090 (disabled_regsets, num_regsets): Delete.
14091 (linux_add_process): Adjust to set the new per-process
14092 new_inferior flag.
14093 (linux_detach_one_lwp): Adjust to call regcache_invalidate_thread.
14094 (linux_wait_for_lwp): Adjust. Only call arch_setup if the event
14095 was a stop. When calling arch_setup, switch the current inferior
14096 to the thread that got an event.
14097 (linux_resume_one_lwp): Adjust to call regcache_invalidate_thread.
14098 (regsets_fetch_inferior_registers)
14099 (regsets_store_inferior_registers): New regsets_info parameter.
14100 Adjust to use it.
14101 (linux_register_in_regsets): New regs_info parameter. Adjust to
14102 use it.
14103 (register_addr, fetch_register, store_register): New usrregs_info
14104 parameter. Adjust to use it.
14105 (usr_fetch_inferior_registers, usr_store_inferior_registers): New
14106 parameter regs_info. Adjust to use it.
14107 (linux_fetch_registers): Get the current inferior's regs_info, and
14108 adjust to use it.
14109 (linux_store_registers): Ditto.
14110 [HAVE_LINUX_REGSETS] (initialize_regsets_info): New.
14111 (initialize_low): Don't initialize the target_regsets here. Call
14112 initialize_low_arch.
14113 * linux-low.h (target_regsets): Delete declaration.
14114 (struct regsets_info): New.
14115 (struct usrregs_info): New.
14116 (struct regs_info): New.
14117 (struct process_info_private) <new_inferior>: New field.
14118 (struct linux_target_ops): Delete the num_regs, regmap, and
14119 regset_bitmap fields. New field regs_info.
14120 [HAVE_LINUX_REGSETS] (initialize_regsets_info): Declare.
14121 * i387-fp.c (num_xmm_registers): Delete.
14122 (i387_cache_to_fsave, i387_fsave_to_cache): Adjust find_regno
14123 calls to new interface.
14124 (i387_cache_to_fxsave, i387_cache_to_xsave, i387_fxsave_to_cache)
14125 (i387_xsave_to_cache): Adjust find_regno calls to new interface.
14126 Infer the number of xmm registers from the regcache's target
14127 description.
14128 * i387-fp.h (num_xmm_registers): Delete.
14129 * inferiors.c (add_thread): Don't install the thread's regcache
14130 here.
14131 * proc-service.c (gregset_info): Fetch the current inferior's
14132 regs_info. Adjust to use it.
14133 * regcache.c: Include tdesc.h.
14134 (register_bytes, reg_defs, num_registers)
14135 (gdbserver_expedite_regs): Delete.
14136 (get_thread_regcache): If the thread doesn't have a regcache yet,
14137 create one, instead of aborting gdbserver.
14138 (regcache_invalidate_one): Rename to ...
14139 (regcache_invalidate_thread): ... this.
14140 (regcache_invalidate_one): New.
14141 (regcache_invalidate): Only invalidate registers of the current
14142 process.
14143 (init_register_cache): Add target_desc parameter, and use it.
14144 (new_register_cache): Ditto. Assert the target description has a
14145 non zero registers_size.
14146 (regcache_cpy): Add assertions. Adjust.
14147 (realloc_register_cache, set_register_cache): Delete.
14148 (registers_to_string, registers_from_string): Adjust.
14149 (find_register_by_name, find_regno, find_register_by_number)
14150 (register_cache_size): Add target_desc parameter, and use it.
14151 (free_register_cache_thread, free_register_cache_thread_one)
14152 (regcache_release, register_cache_size): New.
14153 (register_size): Add target_desc parameter, and use it.
14154 (register_data, supply_register, supply_register_zeroed)
14155 (supply_regblock, supply_register_by_name, collect_register)
14156 (collect_register_as_string, collect_register_by_name): Adjust.
14157 * regcache.h (struct target_desc): Forward declare.
14158 (struct regcache) <tdesc>: New field.
14159 (init_register_cache, new_register_cache): Add target_desc
14160 parameter.
14161 (regcache_invalidate_thread): Declare.
14162 (regcache_invalidate_one): Delete declaration.
14163 (regcache_release): Declare.
14164 (find_register_by_number, register_cache_size, register_size)
14165 (find_regno): Add target_desc parameter.
14166 (gdbserver_expedite_regs, gdbserver_xmltarget): Delete
14167 declarations.
14168 * remote-utils.c: Include tdesc.h.
14169 (outreg, prepare_resume_reply): Adjust.
14170 * server.c: Include tdesc.h.
14171 (gdbserver_xmltarget): Delete declaration.
14172 (get_features_xml, process_serial_event): Adjust.
14173 * server.h [IN_PROCESS_AGENT] (struct target_desc): Forward
14174 declare.
14175 (struct process_info) <tdesc>: New field.
14176 (ipa_tdesc): Declare.
14177 * tdesc.c: New file.
14178 * tdesc.h: New file.
14179 * tracepoint.c: Include tdesc.h.
14180 [IN_PROCESS_AGENT] (ipa_tdesc): Define.
14181 (get_context_regcache): Adjust to pass ipa_tdesc down.
14182 (do_action_at_tracepoint): Adjust to get the register cache size
14183 from the context regcache's description.
14184 (traceframe_walk_blocks): Adjust to get the register cache size
14185 from the current trace frame's description.
14186 (traceframe_get_pc): Adjust to get current trace frame's
14187 description and pass it down.
14188 (gdb_collect): Adjust to get the register cache size from the
14189 IPA's description.
14190 * linux-amd64-ipa.c (tdesc_amd64_linux): Declare.
14191 (gdbserver_xmltarget): Delete.
14192 (initialize_low_tracepoint): Set the ipa's target description.
14193 * linux-i386-ipa.c (tdesc_i386_linux): Declare.
14194 (initialize_low_tracepoint): Set the ipa's target description.
14195 * linux-x86-low.c: Include tdesc.h.
14196 [__x86_64__] (is_64bit_tdesc): New.
14197 (ps_get_thread_area, x86_get_thread_area): Use it.
14198 (i386_cannot_store_register): Rename to ...
14199 (x86_cannot_store_register): ... this. Use is_64bit_tdesc.
14200 (i386_cannot_fetch_register): Rename to ...
14201 (x86_cannot_fetch_register): ... this. Use is_64bit_tdesc.
14202 (x86_fill_gregset, x86_store_gregset): Adjust register_size calls
14203 to new interface.
14204 (target_regsets): Rename to ...
14205 (x86_regsets): ... this.
14206 (x86_get_pc, x86_set_pc): Adjust register_size calls to new
14207 interface.
14208 (x86_siginfo_fixup): Use is_64bit_tdesc.
14209 [__x86_64__] (tdesc_amd64_linux, tdesc_amd64_avx_linux)
14210 (tdesc_x32_avx_linux, tdesc_x32_linux)
14211 (tdesc_i386_linux, tdesc_i386_mmx_linux, tdesc_i386_avx_linux):
14212 Declare.
14213 (x86_linux_update_xmltarget): Delete.
14214 (I386_LINUX_XSAVE_XCR0_OFFSET): Define.
14215 (have_ptrace_getfpxregs, have_ptrace_getregset): New.
14216 (AMD64_LINUX_USER64_CS): New.
14217 (x86_linux_read_description): New, based on
14218 x86_linux_update_xmltarget.
14219 (same_process_callback): New.
14220 (x86_arch_setup_process_callback): New.
14221 (x86_linux_update_xmltarget): New.
14222 (x86_regsets_info): New.
14223 (amd64_linux_regs_info): New.
14224 (i386_linux_usrregs_info): New.
14225 (i386_linux_regs_info): New.
14226 (x86_linux_regs_info): New.
14227 (x86_arch_setup): Reimplement.
14228 (x86_install_fast_tracepoint_jump_pad): Use is_64bit_tdesc.
14229 (x86_emit_ops): Ditto.
14230 (the_low_target): Adjust. Install x86_linux_regs_info,
14231 x86_cannot_fetch_register, and x86_cannot_store_register.
14232 (initialize_low_arch): New.
14233 * linux-ia64-low.c (tdesc_ia64): Declare.
14234 (ia64_fetch_register): Adjust.
14235 (ia64_usrregs_info, regs_info): New globals.
14236 (ia64_regs_info): New function.
14237 (the_low_target): Adjust.
14238 (initialize_low_arch): New function.
14239 * linux-sparc-low.c (tdesc_sparc64): Declare.
14240 (sparc_fill_gregset_to_stack, sparc_store_gregset_from_stack):
14241 Adjust.
14242 (sparc_arch_setup): New function.
14243 (sparc_regsets_info, sparc_usrregs_info, regs_info): New globals.
14244 (the_low_target): Adjust.
14245 (initialize_low_arch): New function.
14246 * linux-ppc-low.c (tdesc_powerpc_32l, tdesc_powerpc_altivec32l)
14247 (tdesc_powerpc_cell32l, tdesc_powerpc_vsx32l)
14248 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_altivec32l)
14249 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_e500l)
14250 (tdesc_powerpc_64l, tdesc_powerpc_altivec64l)
14251 (tdesc_powerpc_cell64l, tdesc_powerpc_vsx64l)
14252 (tdesc_powerpc_isa205_64l, tdesc_powerpc_isa205_altivec64l)
14253 (tdesc_powerpc_isa205_vsx64l): Declare.
14254 (ppc_cannot_store_register, ppc_collect_ptrace_register)
14255 (ppc_supply_ptrace_register, parse_spufs_run, ppc_get_pc)
14256 (ppc_set_pc, ppc_get_hwcap): Adjust.
14257 (ppc_usrregs_info): Forward declare.
14258 (!__powerpc64__) ppc_regmap_adjusted: New global.
14259 (ppc_arch_setup): Adjust to the current process'es target
14260 description.
14261 (ppc_fill_vsxregset, ppc_store_vsxregset, ppc_fill_vrregset)
14262 (ppc_store_vrregset, ppc_fill_evrregset, ppc_store_evrregse)
14263 (ppc_store_evrregset): Adjust.
14264 (target_regsets): Rename to ...
14265 (ppc_regsets): ... this, and make static.
14266 (ppc_usrregs_info, ppc_regsets_info, regs_info): New globals.
14267 (ppc_regs_info): New function.
14268 (the_low_target): Adjust.
14269 (initialize_low_arch): New function.
14270 * linux-s390-low.c (tdesc_s390_linux32, tdesc_s390_linux32v1)
14271 (tdesc_s390_linux32v2, tdesc_s390_linux64, tdesc_s390_linux64v1)
14272 (tdesc_s390_linux64v2, tdesc_s390x_linux64, tdesc_s390x_linux64v1)
14273 (tdesc_s390x_linux64v2): Declare.
14274 (s390_collect_ptrace_register, s390_supply_ptrace_register)
14275 (s390_fill_gregset, s390_store_last_break): Adjust.
14276 (target_regsets): Rename to ...
14277 (s390_regsets): ... this, and make static.
14278 (s390_get_pc, s390_set_pc): Adjust.
14279 (s390_get_hwcap): New target_desc parameter, and use it.
14280 [__s390x__] (have_hwcap_s390_high_gprs): New global.
14281 (s390_arch_setup): Adjust to set the current process'es target
14282 description. Don't adjust the regmap.
14283 (s390_usrregs_info, s390_regsets_info, regs_info): New globals.
14284 [__s390x__] (s390_usrregs_info_3264, s390_regsets_info_3264)
14285 (regs_info_3264): New globals.
14286 (s390_regs_info): New function.
14287 (the_low_target): Adjust.
14288 (initialize_low_arch): New function.
14289 * linux-mips-low.c (tdesc_mips_linux, tdesc_mips_dsp_linux)
14290 (tdesc_mips64_linux, tdesc_mips64_dsp_linux): Declare.
14291 [__mips64] (init_registers_mips_linux)
14292 (init_registers_mips_dsp_linux): Delete defines.
14293 [__mips64] (tdesc_mips_linux, tdesc_mips_dsp_linux): New defines.
14294 (have_dsp): New global.
14295 (mips_read_description): New, based on mips_arch_setup.
14296 (mips_arch_setup): Reimplement.
14297 (get_usrregs_info): New function.
14298 (mips_cannot_fetch_register, mips_cannot_store_register)
14299 (mips_get_pc, mips_set_pc, mips_fill_gregset, mips_store_gregset)
14300 (mips_fill_fpregset, mips_store_fpregset): Adjust.
14301 (target_regsets): Rename to ...
14302 (mips_regsets): ... this, and make static.
14303 (mips_regsets_info, mips_dsp_usrregs_info, mips_usrregs_info)
14304 (dsp_regs_info, regs_info): New globals.
14305 (mips_regs_info): New function.
14306 (the_low_target): Adjust.
14307 (initialize_low_arch): New function.
14308 * linux-arm-low.c (tdesc_arm, tdesc_arm_with_iwmmxt)
14309 (tdesc_arm_with_vfpv2, tdesc_arm_with_vfpv3, tdesc_arm_with_neon):
14310 Declare.
14311 (arm_fill_vfpregset, arm_store_vfpregset): Adjust.
14312 (arm_read_description): New, with bits factored from
14313 arm_arch_setup.
14314 (arm_arch_setup): Reimplement.
14315 (target_regsets): Rename to ...
14316 (arm_regsets): ... this, and make static.
14317 (arm_regsets_info, arm_usrregs_info, regs_info): New globals.
14318 (arm_regs_info): New function.
14319 (the_low_target): Adjust.
14320 (initialize_low_arch): New function.
14321 * linux-m68k-low.c (tdesc_m68k): Declare.
14322 (target_regsets): Rename to ...
14323 (m68k_regsets): ... this, and make static.
14324 (m68k_regsets_info, m68k_usrregs_info, regs_info): New globals.
14325 (m68k_regs_info): New function.
14326 (m68k_arch_setup): New function.
14327 (the_low_target): Adjust.
14328 (initialize_low_arch): New function.
14329 * linux-sh-low.c (tdesc_sharch): Declare.
14330 (target_regsets): Rename to ...
14331 (sh_regsets): ... this, and make static.
14332 (sh_regsets_info, sh_usrregs_info, regs_info): New globals.
14333 (sh_regs_info, sh_arch_setup): New functions.
14334 (the_low_target): Adjust.
14335 (initialize_low_arch): New function.
14336 * linux-bfin-low.c (tdesc_bfin): Declare.
14337 (bfin_arch_setup): New function.
14338 (bfin_usrregs_info, regs_info): New globals.
14339 (bfin_regs_info): New function.
14340 (the_low_target): Adjust.
14341 (initialize_low_arch): New function.
14342 * linux-cris-low.c (tdesc_cris): Declare.
14343 (cris_arch_setup): New function.
14344 (cris_usrregs_info, regs_info): New globals.
14345 (cris_regs_info): New function.
14346 (the_low_target): Adjust.
14347 (initialize_low_arch): New function.
14348 * linux-cris-low.c (tdesc_crisv32): Declare.
14349 (cris_arch_setup): New function.
14350 (cris_regsets_info, cris_usrregs_info, regs_info): New globals.
14351 (cris_regs_info): New function.
14352 (the_low_target): Adjust.
14353 (initialize_low_arch): New function.
14354 * linux-m32r-low.c (tdesc_m32r): Declare.
14355 (m32r_arch_setup): New function.
14356 (m32r_usrregs_info, regs_info): New globals.
14357 (m32r_regs_info): Adjust.
14358 (initialize_low_arch): New function.
14359 * linux-tic6x-low.c (tdesc_tic6x_c64xp_linux)
14360 (tdesc_tic6x_c64x_linux, tdesc_tic6x_c62x_linux): Declare.
14361 (tic6x_usrregs_info): Forward declare.
14362 (tic6x_read_description): New function, based on ...
14363 (tic6x_arch_setup): ... this. Reimplement.
14364 (target_regsets): Rename to ...
14365 (tic6x_regsets): ... this, and make static.
14366 (tic6x_regsets_info, tic6x_usrregs_info, regs_info): New globals.
14367 (tic6x_regs_info): New function.
14368 (the_low_target): Adjust.
14369 (initialize_low_arch): New function.
14370 * linux-xtensa-low.c (tdesc_xtensa): Declare.
14371 (xtensa_fill_gregset, xtensa_store_gregset): Adjust.
14372 (target_regsets): Rename to ...
14373 (xtensa_regsets): ... this, and make static.
14374 (xtensa_regsets_info, xtensa_usrregs_info, regs_info): New
14375 globals.
14376 (xtensa_arch_setup, xtensa_regs_info): New functions.
14377 (the_low_target): Adjust.
14378 (initialize_low_arch): New function.
14379 * linux-nios2-low.c (tdesc_nios2_linux): Declare.
14380 (nios2_arch_setup): Set the current process'es tdesc.
14381 (target_regsets): Rename to ...
14382 (nios2_regsets): ... this.
14383 (nios2_regsets_info, nios2_usrregs_info, regs_info): New globals.
14384 (nios2_regs_info): New function.
14385 (the_low_target): Adjust.
14386 (initialize_low_arch): New function.
14387 * linux-aarch64-low.c (tdesc_aarch64): Declare.
14388 (aarch64_arch_setup): Set the current process'es tdesc.
14389 (target_regsets): Rename to ...
14390 (aarch64_regsets): ... this.
14391 (aarch64_regsets_info, aarch64_usrregs_info, regs_info): New globals.
14392 (aarch64_regs_info): New function.
14393 (the_low_target): Adjust.
14394 (initialize_low_arch): New function.
14395 * linux-tile-low.c (tdesc_tilegx, tdesc_tilegx32): Declare
14396 globals.
14397 (target_regsets): Rename to ...
14398 (tile_regsets): ... this.
14399 (tile_regsets_info, tile_usrregs_info, regs_info): New globals.
14400 (tile_regs_info): New function.
14401 (tile_arch_setup): Set the current process'es tdesc.
14402 (the_low_target): Adjust.
14403 (initialize_low_arch): New function.
14404 * spu-low.c (tdesc_spu): Declare.
14405 (spu_create_inferior, spu_attach): Set the new process'es tdesc.
14406 * win32-arm-low.c (tdesc_arm): Declare.
14407 (arm_arch_setup): New function.
14408 (the_low_target): Install arm_arch_setup instead of
14409 init_registers_arm.
14410 * win32-i386-low.c (tdesc_i386, tdesc_amd64): Declare.
14411 (init_windows_x86): Rename to ...
14412 (i386_arch_setup): ... this. Set `win32_tdesc'.
14413 (the_low_target): Adjust.
14414 * win32-low.c (win32_tdesc): New global.
14415 (child_add_thread): Don't create the thread cache here.
14416 (do_initial_child_stuff): Set the new process'es tdesc.
14417 * win32-low.h (struct target_desc): Forward declare.
14418 (win32_tdesc): Declare.
14419 * lynx-i386-low.c (tdesc_i386): Declare global.
14420 (lynx_i386_arch_setup): Set `lynx_tdesc'.
14421 * lynx-low.c (lynx_tdesc): New global.
14422 (lynx_add_process): Set the new process'es tdesc.
14423 * lynx-low.h (struct target_desc): Forward declare.
14424 (lynx_tdesc): Declare global.
14425 * lynx-ppc-low.c (tdesc_powerpc_32): Declare global.
14426 (lynx_ppc_arch_setup): Set `lynx_tdesc'.
14427 * nto-low.c (nto_tdesc): New global.
14428 (do_attach): Set the new process'es tdesc.
14429 * nto-low.h (struct target_desc): Forward declare.
14430 (nto_tdesc): Declare.
14431 * nto-x86-low.c (tdesc_i386): Declare.
14432 (nto_x86_arch_setup): Set `nto_tdesc'.
14433
14434 2013-06-04 Gary Benson <gbenson@redhat.com>
14435
14436 * server.c (handle_query): Add "augmented-libraries-svr4-read+"
14437 to qSupported response when appropriate.
14438 (handle_qxfer_libraries_svr4): Allow qXfer:libraries-svr4:read
14439 with nonzero-length annex.
14440 * linux-low.c (linux_qxfer_libraries_svr4): Parse and handle
14441 arguments supplied in annex.
14442
14443 2013-05-31 Doug Evans <dje@google.com>
14444
14445 PR server/15594
14446 * linux-x86-low.c (ps_get_thread_area): Properly extend address to
14447 64 bits in 64-cross-32 environment.
14448
14449 2013-05-28 Pedro Alves <palves@redhat.com>
14450
14451 * Makefile.in (clean): Remove reference to aarch64-without-fpu.c.
14452 (aarch64-without-fpu.c): Delete rule.
14453 * configure.srv (aarch64*-*-linux*): Remove references to
14454 aarch64-without-fpu.o and aarch64-without-fpu.xml.
14455 * linux-aarch64-low.c (init_registers_aarch64_without_fpu): Remove
14456 declaration.
14457
14458 2013-05-24 Pedro Alves <palves@redhat.com>
14459
14460 * server.c (handle_v_cont) <vCont;r>: Use unpack_varlen_hex
14461 instead of strchr/decode_address. Error if the range isn't split
14462 with a ','. Don't assume there's be a ':' in the action.
14463
14464 2013-05-23 Yao Qi <yao@codesourcery.com>
14465 Pedro Alves <palves@redhat.com>
14466
14467 * linux-low.c (lwp_in_step_range): New function.
14468 (linux_wait_1): If the thread was range stepping and stopped
14469 outside the stepping range, report the stop to GDB. Otherwise,
14470 continue stepping. Add range stepping debug output.
14471 (linux_set_resume_request): Copy the step range from the resume
14472 request to the lwp.
14473 (linux_supports_range_stepping): New.
14474 (linux_target_ops) <supports_range_stepping>: Set to
14475 linux_supports_range_stepping.
14476 * linux-low.h (struct linux_target_ops)
14477 <supports_range_stepping>: New field.
14478 (struct lwp_info) <step_range_start, step_range_end>: New fields.
14479 * linux-x86-low.c (x86_supports_range_stepping): New.
14480 (the_low_target) <supports_range_stepping>: Set to
14481 x86_supports_range_stepping.
14482 * server.c (handle_v_cont): Handle 'r' action.
14483 (handle_v_requests): Append ";r" if the target supports range
14484 stepping.
14485 * target.h (struct thread_resume) <step_range_start,
14486 step_range_end>: New fields.
14487 (struct target_ops) <supports_range_stepping>:
14488 New field.
14489 (target_supports_range_stepping): New macro.
14490
14491 2013-05-17 Joel Brobecker <brobecker@adacore.com>
14492
14493 * lynx-low.c (lynx_resume): Fix null_ptid/minus_one_ptid
14494 confusion in comment.
14495
14496 2013-05-17 Joel Brobecker <brobecker@adacore.com>
14497
14498 * lynx-low.c (struct process_info_private): New type.
14499 (lynx_add_process): New function.
14500 (lynx_create_inferior, lynx_attach): Replace calls to
14501 add_process by calls to lynx_add_process.
14502 (lynx_resume): If PTID is null, then try using
14503 current_process()->private->last_wait_event_ptid.
14504 Add comments.
14505 (lynx_clear_inferiors): Delete. The contents of that function
14506 has been inlined in lynx_mourn;
14507 (lynx_wait_1): Save the ptid in the process's private data.
14508 (lynx_mourn): Free the process' private data. Replace call
14509 to lynx_clear_inferiors by call to clear_inferiors.
14510
14511 2013-05-17 Yao Qi <yao@codesourcery.com>
14512
14513 * i386-low.c (i386_length_and_rw_bits): Move the comment to
14514 the right place.
14515
14516 2013-05-16 Luis Machado <lgustavo@codesourcery.com>
14517
14518 * linux-low.c: Move definition checks upwards for PT_TEXT_ADDR,
14519 PT_DATA_ADDR and PT_TEXT_END_ADDR. Update comments.
14520 (linux_read_offsets): Remove PT_TEXT_ADDR, PT_DATA_ADDR and
14521 PT_TEXT_END_ADDR guards. Update comments.
14522 (linux_target_op) <read_offsets>: Conditionally define to
14523 linux_read_offsets if the target is UCLIBC and if it defines
14524 PT_TEXT_ADDR, PT_DATA_ADDR and PT_TEXT_END_ADDR.
14525
14526 2013-05-06 Sandra Loosemore <sandra@codesourcery.com>
14527 Andrew Jenner <andrew@codesourcery.com>
14528
14529 * Makefile.in (SFILES): Add linux-nios2-low.c.
14530 (clean): Add action to delete nios2-linux.c.
14531 (nios2-linux.c): New rule.
14532 * configure.srv: Add nios2*-*-linux*.
14533 * linux-nios2-low.c: New.
14534
14535 2013-05-03 Hafiz Abid Qadeer <abidh@codesourcery.com>
14536
14537 * tracepoint.c (cmd_qtinit): Call 'stop_tracing'.
14538
14539 2013-04-25 Hui Zhu <hui@codesourcery.com>
14540
14541 PR gdb/15186
14542 * ax.c (ax_printf): Add fflush.
14543
14544 2013-04-22 Tom Tromey <tromey@redhat.com>
14545
14546 * Makefile.in (SFILES): Add filestuff.c.
14547 (OBS): Add filestuff.o.
14548 (filestuff.o): New target.
14549 * config.in, configure: Rebuild.
14550 * configure.ac: Check for fdwalk, pipe2.
14551
14552 2013-04-17 Pedro Alves <palves@redhat.com>
14553
14554 * configure.ac (USE_THREAD_DB): Delete variable.
14555 (if test "$srv_linux_thread_db" = "yes"): AC_DEFINE USE_THREAD_DB.
14556 Don't AC_SUBST USE_THREAD_DB.
14557 * Makefile.in (INTERNAL_CFLAGS): Remove @USE_THREAD_DB@.
14558 * config.in, configure: Regenerate.
14559
14560 2013-04-16 Pedro Alves <palves@redhat.com>
14561
14562 * linux-low.h (struct lwp_info) <thread_known>: Move under
14563 the USE_THREAD_DB #ifdef.
14564
14565 2013-04-16 Pedro Alves <palves@redhat.com>
14566
14567 * Makefile.in (INTERNAL_CFLAGS): Add @USE_THREAD_DB@.
14568 (linux-low.o): Delete rule.
14569 * linux-low.h: Always include "gdb_thread_db.h" instead of
14570 conditionally including thread_db.h.
14571 (struct lwp_info) <th>: Guard with #ifdef USE_THREAD_DB instead of
14572 HAVE_THREAD_DB_H.
14573
14574 2013-04-07 Jan Kratochvil <jan.kratochvil@redhat.com>
14575
14576 * Makefile.in (install-only): Fix make install regression.
14577
14578 2013-04-05 Jan Kratochvil <jan.kratochvil@redhat.com>
14579
14580 Convert man pages to texinfo, new gdbinit.5 texinfo page.
14581 * Makefile.in (install-only): Remove $(man1dir) and gdbserver.1
14582 installation.
14583 * gdbserver.1: Remove.
14584
14585 2013-03-22 Pedro Alves <palves@redhat.com>
14586
14587 * linux-low.c (handle_extended_wait): Don't call
14588 linux_enable_event_reporting.
14589
14590 2013-03-15 Tony Theodore <tonyt@logyst.com>
14591
14592 PR build/9098:
14593 * Makefile.in (SHELL): Use @SHELL@.
14594
14595 2013-03-14 Sergio Durigan Junior <sergiodj@redhat.com>
14596
14597 * tracepoint.c (cmd_qtv): Initialize `val' with zero, silencing
14598 compiler warning.
14599
14600 2013-03-13 Joel Brobecker <brobecker@adacore.com>
14601
14602 * linux-low.c (linux_target_ops) [!HAVE_LINUX_BTRACE]:
14603 Remove extraneous NULL element.
14604
14605 2013-03-13 Yao Qi <yao@codesourcery.com>
14606
14607 * tracepoint.c (traceframe_read_tsv): Look for the last matched
14608 'V' block in trace frame.
14609
14610 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
14611
14612 * target.h (struct target_ops): Add btrace ops.
14613 (target_supports_btrace): New macro.
14614 (target_enable_btrace): New macro.
14615 (target_disable_btrace): New macro.
14616 (target_read_btrace): New macro.
14617 * gdbthread.h (struct thread_info): Add btrace field.
14618 * server.c: Include btrace-common.h.
14619 (handle_btrace_general_set): New function.
14620 (handle_btrace_enable): New function.
14621 (handle_btrace_disable): New function.
14622 (handle_general_set): Call handle_btrace_general_set.
14623 (handle_qxfer_btrace): New function.
14624 (struct qxfer qxfer_packets[]): Add btrace entry.
14625 * inferiors.c (remove_thread): Disable btrace.
14626 * linux-low: Include linux-btrace.h.
14627 (linux_low_enable_btrace): New function.
14628 (linux_low_read_btrace): New function.
14629 (linux_target_ops): Add btrace ops.
14630 * configure.srv (i[34567]86-*-linux*): Add linux-btrace.o.
14631 Add srv_linux_btrace=yes.
14632 (x86_64-*-linux*): Add linux-btrace.o.
14633 Add srv_linux_btrace=yes.
14634 * configure.ac: Define HAVE_LINUX_BTRACE.
14635 * config.in: Regenerated.
14636 * configure: Regenerated.
14637
14638 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
14639
14640 * server.c (handle_qxfer): Preserve error message if -3 is
14641 returned.
14642 (qxfer): Document the -3 return value.
14643
14644 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
14645
14646 * Makefile.in (SFILES): Add $(srcdir)/common/linux-btrace.c.
14647 (linux_btrace_h): New variable.
14648 (linux-btrace.o): New rule.
14649
14650 2013-03-08 Stan Shebs <stan@codesourcery.com>
14651 Hafiz Abid Qadeer <abidh@codesourcery.com>
14652
14653 * tracepoint.c (trace_buffer_size): New global.
14654 (DEFAULT_TRACE_BUFFER_SIZE): New define.
14655 (init_trace_buffer): Change to one-argument function. Allocate
14656 trace buffer memory.
14657 (handle_tracepoint_general_set): Call cmd_bigqtbuffer_size to
14658 handle QTBuffer:size packet.
14659 (cmd_bigqtbuffer_size): New function.
14660 (initialize_tracepoint): Call init_trace_buffer with
14661 DEFAULT_TRACE_BUFFER_SIZE.
14662 * server.c (handle_query): Add QTBuffer:size in the
14663 supported packets.
14664
14665 2013-03-07 Yao Qi <yao@codesourcery.com>
14666
14667 * tracepoint.c (cur_action, cur_step_action): Make them unsigned.
14668 (cmd_qtfp): Initialize cur_action and cur_step_action 0 instead
14669 of -1.
14670 (cmd_qtsp): Adjust condition. Do post increment.
14671 Set cur_action and cur_step_action back to 0.
14672
14673 2013-03-07 Jeremy Bennett <jeremy.bennett@embecosm.com>
14674
14675 PR server/15236
14676 * linux-low.c (linux_write_memory): Return early success if LEN is
14677 zero.
14678
14679 2013-03-05 Corinna Vinschen <vinschen@redhat.de>
14680
14681 * configure.srv: Add x86_64-*-cygwin* as target.
14682
14683 2013-02-28 Tom Tromey <tromey@redhat.com>
14684
14685 * configure.ac: Invoke AC_SYS_LARGEFILE.
14686 * configure, config.in: Rebuild.
14687
14688 2013-02-28 Corinna Vinschen <vinschen@redhat.com>
14689
14690 * win32-low.c: Throughout, fix format strings and casts of
14691 printf-like functions to avoid type related warnings on all
14692 platforms.
14693 (get_child_debug_event): Print dwDebugEventCode as hex since
14694 that's how it's usually documented.
14695
14696 2013-02-28 Yao Qi <yao@codesourcery.com>
14697
14698 * tracepoint.c (cmd_qtbuffer): Call phex_nz instead of
14699 pulongest.
14700
14701 2013-02-27 Jiong Wang <jiwang@tilera.com>
14702
14703 * Makefile.in (clean): Remove reg-tilegx.c, reg-tilegx32.c.
14704 (reg-tilegx32.c): New rule.
14705 * configure.srv (tilegx-*-linux*): Add reg-tilegx32.o to srv_regobj.
14706 * linux-tile-low.c (tile_arch_setup): New function. Invoke
14707 different register info initializer according to elf class.
14708 (init_registers_tilgx32): New function. The tilegx32 register info
14709 initializer.
14710 (tile_fill_gregset): Use "uint_reg_t" to represent register size.
14711 (tile_store_gregset): Likewise.
14712
14713 2013-02-27 Yao Qi <yao@codesourcery.com>
14714
14715 * server.c (process_point_options): Print debug message when
14716 debug_threads is true.
14717
14718 2013-02-26 Yao Qi <yao@codesourcery.com>
14719
14720 * tracepoint.c (cmd_qtbuffer): Don't set '\0' in OWN_BUF.
14721
14722 2013-02-19 Pedro Alves <palves@redhat.com>
14723 Kai Tietz <ktietz@redhat.com>
14724
14725 PR gdb/15161
14726
14727 * server.c (handle_query) <CRC check>: Use unpack_varlen_hex
14728 instead of strtoul to extract address from packet.
14729 (process_serial_event) <'z'>: Likewise.
14730
14731 2013-02-18 Yao Qi <yao@codesourcery.com>
14732
14733 * linux-bfin-low.c (the_low_target): Use NULL instead of 0.
14734
14735 2013-02-14 Pedro Alves <palves@redhat.com>
14736
14737 Plug memory leak.
14738
14739 * tracepoint.c (cmd_qtnotes): Free TRACING_USER_NAME,
14740 TRACING_NOTES and TRACING_STOP_NOTE before clobbering.
14741
14742 2013-02-14 Pedro Alves <palves@redhat.com>
14743
14744 * tracepoint.c (cmd_qtdpsrc): Use savestring.
14745
14746 2013-02-14 Pedro Alves <palves@redhat.com>
14747
14748 * tracepoint.c (save_string): Delete.
14749 (add_tracepoint_action): Use savestring instead of save_string.
14750
14751 2013-02-12 Pedro Alves <palves@redhat.com>
14752
14753 * linux-xtensa-low.c: Ditto.
14754 * xtensa-xtregs.c: Ditto.
14755
14756 2013-02-12 Sanimir Agovic <sanimir.agovic@intel.com>
14757
14758 * thread-db.c (thread_db_get_tls_address): NULL pointer check
14759 thread_db.
14760
14761 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
14762
14763 * linux-aarch64-low.c (aarch64_arch_setup): Clamp
14764 aarch64_num_wp_regs and aarch64_num_bp_regs to
14765 AARCH64_HWP_MAX_NUM and AARCH64_HBP_MAX_NUM respectively.
14766
14767 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
14768
14769 * linux-aarch64-low.c (ps_get_thread_area): Replace
14770 PTRACE_GET_THREAD_AREA with PTRACE_GETREGSET.
14771
14772 2013-02-04 Jim MacArthur <jim.macarthur@arm.com>
14773 Marcus Shawcroft <marcus.shawcroft@arm.com>
14774 Nigel Stephens <nigel.stephens@arm.com>
14775 Yufeng Zhang <yufeng.zhang@arm.com>
14776
14777 * Makefile.in (clean): Remove aarch64.c and aarch64-without-fpu.c.
14778 (aarch64.c, aarch64-without-fpu.c): New targets.
14779 * configure.srv (aarch64*-*-linux*): New.
14780 * linux-aarch64-low.c: New file.
14781
14782 2013-02-04 Marcus Shawcroft <marcus.shawcroft@arm.com>
14783
14784 * linux-low.c (handle_extended_wait, linux_create_inferior)
14785 (linux_attach_lwp_1, linux_kill_one_lwp, linux_attach_one_lwp)
14786 (dequeue_one_deferred_signal, linux_resume_one_thread)
14787 (fetch_register, linux_write_memory, linux_enable_event_reporting)
14788 (linux_tracefork_grandchild, linux_test_for_tracefork)
14789 (linux_read_offsets, linux_xfer_siginfo, linux_xfer_siginfo): Add
14790 PTRACE_ARG3_TYPE and PTRACE_ARG4_TYPE cast to ptrace arguments
14791 where the argument is 0.
14792
14793 2013-01-25 Yao Qi <yao@codesourcery.com>
14794
14795 * event-loop.c: Include "queue.h".
14796 (gdb_event_p): New typedef.
14797 (struct gdb_event) <next_event>: Remove.
14798 (event_queue): Change to QUEUE(gdb_event_p).
14799 (async_queue_event): Remove.
14800 (gdb_event_xfree): New.
14801 (initialize_event_loop): New.
14802 (process_event): Use API from QUEUE.
14803 (wait_for_event): Likewise.
14804 * server.c (main): Call initialize_event_loop.
14805 * server.h (initialize_event_loop): Declare.
14806
14807 2013-01-18 Yao Qi <yao@codesourcery.com>
14808
14809 * ax.h (struct eval_agent_expr_context): New.
14810 (gdb_eval_agent_expr): Update declaration.
14811 * ax.c (gdb_eval_agent_expr): Remove argument REGCACHE and
14812 TFRAME. Add new argument CTX.
14813 * server.h (struct eval_agent_expr_context): Declare.
14814 (agent_mem_read, agent_tsv_read): Update declaration.
14815 (agent_mem_read_string): Likewise.
14816 * tracepoint.c (eval_tracepoint_agent_expr): Remove.
14817 (add_traceframe_block): Add new argument TPOINT.
14818 Increase TPOINT->traceframe_usage.
14819 (do_action_at_tracepoint): Call gdb_eval_agent_expr instead of
14820 eval_tracepoint_agent_expr.
14821 (condition_true_at_tracepoint): Likewise.
14822 (agent_mem_read): Remove argument TFRAME. Add argument CTX.
14823 (agent_mem_read_string, agent_tsv_read): Likewise.
14824
14825 2013-01-16 Yao Qi <yao@codesourcery.com>
14826
14827 * linux-low.c (linux_resume_one_lwp): Don't check
14828 'lwp->bp_reinsert != 0'.
14829
14830 2013-01-07 Joel Brobecker <brobecker@adacore.com>
14831 Pedro Alves <palves@redhat.com>
14832
14833 * lynx-low.c (ptrace_request_to_str): Define a temporary
14834 macro and use it to simplify this function's implementation.
14835
14836 2013-01-07 Joel Brobecker <brobecker@adacore.com>
14837
14838 * lynx-low.c (lynx_resume): Call perror_with_name if lynx_ptrace
14839 sets errno.
14840
14841 2013-01-07 Joel Brobecker <brobecker@adacore.com>
14842
14843 * configure.srv (i[34567]86-*-lynxos*): Set srv_xmlfiles.
14844
14845 2013-01-07 Joel Brobecker <brobecker@adacore.com>
14846
14847 * configure.srv (powerpc-*-lynxos*): Set srv_xmlfiles.
14848
14849 2013-01-07 Joel Brobecker <brobecker@adacore.com>
14850
14851 * lynx-low.c (lynx_resume): Use the resume_info parameter
14852 to determine the ptid for the lynx_ptrace call, unless
14853 it is equal to minus_one_ptid, in which case we use the
14854 ptid of the current_inferior.
14855 (lynx_wait_1): After having received a thread create/exit
14856 event, resume the inferior's execution using the signaling
14857 thread's ptid, rather than the old ptid.
14858
14859 2013-01-07 Joel Brobecker <brobecker@adacore.com>
14860
14861 * lynx-low.c (lynx_resume): Delete variable ret.
14862
14863 2013-01-01 Joel Brobecker <brobecker@adacore.com>
14864
14865 * gdbreplay.c (gdbreplay_version): Update copyright year.
14866 * server.c (gdbserver_version): Likewise.
14867
14868 2012-12-17 Joel Brobecker <brobecker@adacore.com>
14869
14870 * lynx-low.c (lynx_wait_1): Add debug trace before adding
14871 new thread.
14872
14873 2012-12-17 Joel Brobecker <brobecker@adacore.com>
14874
14875 * lynx-low.c (ptrace_request_to_str): Add handling for
14876 PTRACE_GETTRACESIG.
14877
14878 2012-12-17 Joel Brobecker <brobecker@adacore.com>
14879
14880 * lynx-low.c (lynx_attach): Delete variable new_process.
14881
14882 2012-12-17 Joel Brobecker <brobecker@adacore.com>
14883
14884 * lynx-low.c (lynx_create_inferior): Delete variable
14885 new_process.
14886
14887 2012-12-17 Joel Brobecker <brobecker@adacore.com>
14888
14889 * lynx-low.c (ptrace_request_to_str): Do not handle
14890 PTRACE_GETTHREADLIST if this macro does not exist.
14891
14892 2012-12-15 Yao Qi <yao@codesourcery.com>
14893
14894 * Makefile.in (OBS): Add notif.o.
14895 * notif.c, notif.h: New.
14896 * server.c: Include "notif.h".
14897 (struct vstop_notif) <next>: Remove.
14898 <base>: New field.
14899 (queue_stop_reply): Update.
14900 (push_event, send_next_stop_reply): Remove.
14901 (discard_queued_stop_replies): Update.
14902 (notif_stop): New variable.
14903 (handle_v_stopped): Remove.
14904 (handle_v_requests): Don't call handle_v_stopped. Call
14905 handle_ack_notif instead.
14906 (queue_stop_reply_callback): Call notif_event_enque instead
14907 of queue_stop_reply.
14908 (handle_status): Don't call send_next_stop_reply, call
14909 notif_write_event instead.
14910 (kill_inferior_callback): Likewise.
14911 (detach_or_kill_inferior_callback): Likewise.
14912 (main): Call initialize_notif.
14913 (process_serial_event): Call QUEUE_is_empty.
14914 (handle_target_event): Call notif_push instead of push event.
14915 * server.h (push_event): Remove declaration.
14916
14917 2012-12-10 Tom Tromey <tromey@redhat.com>
14918
14919 * Makefile.in (DEPMODE, DEPDIR, depcomp, COMPILE.pre)
14920 (COMPILE.post, COMPILE, POSTCOMPILE, IPAGENT_COMPILE): New
14921 macros.
14922 (.c.o): Rewrite.
14923 (ax-ipa.o, tracepoint-ipa.o, utils-ipa.o, format-ipa.o)
14924 (common-utils-ipa.o, remote-utils-ipa.o, regcache-ipa.o)
14925 (i386-linux-ipa.o, linux-i386-ipa.o, linux-amd64-ipa.o)
14926 (amd64-linux-ipa.o, ax.o): Rewrite.
14927 (event-loop.o, hostio.o, hostio-errno.o, inferiors.o, mem-break.o)
14928 (proc-service.o, regcache.o, remote-utils.o, server.o, target.o)
14929 (thread-db.o, tracepoint.o, utils.o, gdbreplay.o, dll.o): Remove.
14930 (signals.o, linux-procfs.o, linux-ptrace.o, common-utils.o, vec.o)
14931 (gdb_vecs.o, xml-utils.o, linux-osdata.o, ptid.o, buffer.o)
14932 (format.o, agent.o, vasprintf.o, vsnprintf.o): Rewrite.
14933 (i386-low.o, i387-fp.o, linux-low.o, linux-arm-low.o)
14934 (linux-bfin-low.o, linux-cris-low.o, linux-crisv32-low.o)
14935 (linux-ia64-low.o, linux-m32r-low.o, linux-mips-low.o)
14936 (linux-ppc-low.o, linux-s390-low.o, linux-sh-low.o)
14937 (linux-tic6x-low.o, linux-x86-low.o, linux-xtensa-low.o)
14938 (linux-tile-low.o, lynx-low.o, lynx-ppc-low.o, nto-low.o)
14939 (nto-x86-low.o, linux-low.o, win32-low.o, win32-arm-low.o)
14940 (win32-i386-low.o, spu-low.o, reg-arm.o, arm-with-iwmmxt.o)
14941 (arm-with-vfpv2.o, arm-with-vfpv3.o, arm-with-neon.o, reg-bfin.o)
14942 (reg-cris.o, reg-crisv32.o, i386.o, i386-linux.o, i386-avx.o)
14943 (i386-avx-linux.o, i386-mmx.o, i386-mmx-linux.o, reg-ia64.o)
14944 (reg-m32r.o, reg-m68k.o, reg-cf.o, mips-linux.o, mips-dsp-linux.o)
14945 (mips64-linux.o, mips64-dsp-linux.o, powerpc-32.o, powerpc-32l.o)
14946 (powerpc-altivec32l.o, powerpc-cell32l.o, powerpc-vsx32l.o)
14947 (powerpc-isa205-32l.o, powerpc-isa205-altivec32l.o)
14948 (powerpc-isa205-vsx32l.o, powerpc-e500l.o, powerpc-64l.o)
14949 (powerpc-altivec64l.o, powerpc-cell64l.o, powerpc-vsx64l.o)
14950 (powerpc-isa205-64l.o, powerpc-isa205-altivec64l.o)
14951 (powerpc-isa205-vsx64l.o, s390-linux32.o, s390-linux32v1.o)
14952 (s390-linux32v2.o, s390-linux64.o, s390-linux64v1.o)
14953 (s390-linux64v2.o, s390x-linux64.o, s390x-linux64v1.o)
14954 (s390x-linux64v2.o, tic6x-c64xp-linux.o, tic6x-c64x-linux.o)
14955 (tic6x-c62x-linux.o, reg-sh.o, reg-sparc64.o, reg-spu.o, amd64.o)
14956 (amd64-linux.o, amd64-avx.o, amd64-avx-linux.o, x32.o)
14957 (x32-linux.o, x32-avx.o, x32-avx-linux.o, reg-xtensa.o)
14958 (reg-tilegx.o): Remove.
14959 (all_object_files): New macro.
14960 Include .deps files.
14961 * aclocal.m4, configure: Rebuild.
14962 * acinclude.m4: Include depstand.m4, lead-dot.m4.
14963 * configure.ac: Invoke ZW_CREATE_DEPDIR,
14964 ZW_PROG_COMPILER_DEPENDENCIES. Compute GMAKE condition.
14965
14966 2012-12-05 Tom Tromey <tromey@redhat.com>
14967
14968 PR gdb/14917:
14969 * server.h (current_insn_ptr, emit_error): Declare 'extern'.
14970
14971 2012-11-28 Markus Metzger <markus.t.metzger@intel.com>
14972
14973 * configure.ac: Check for linux/perf_event.h.
14974 * config.in: Regenerated.
14975 * configure: Regenerated.
14976
14977 2012-11-26 Maxime Villard <rustyBSD@gmx.fr>
14978
14979 * hostio.c (handle_readlink): Decrease buffer size
14980 parameter passed to readlink by one byte.
14981
14982 2012-11-26 Yao Qi <yao@codesourcery.com>
14983
14984 * configure.ac (build_warnings): Append '-Wempty-body'.
14985 * configure: Regenerated.
14986 * linux-low.c (linux_create_inferior): Use braces for empty 'if'
14987 body.
14988
14989 2012-11-15 Pierre Muller <muller@sourceware.org>
14990
14991 * configure.ac (AC_CHECK_HEADERS): Add wait.h header.
14992 * config.in: Regenerate.
14993 * configure: Regenerate.
14994 * linux-low.c: Use "gdb_stat.h" header instead of <sys/stat.h> header.
14995 Use "gdb_wait.h" header instead of <sys/wait.h> header.
14996 * lynx-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
14997 * remote-utils.c: Use "gdb_stat.h" header instead of <sys/stat.h>
14998 header.
14999 * server.c: Remove HAVE_WAIT_H conditional. Use "gdb_wait.h" header
15000 instead of <sys/wait.h> header.
15001 * spu-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
15002
15003 2012-11-13 Markus Metzger <markus.t.metzger@intel.com>
15004
15005 * Makefile.in: (INTERNAL_CFLAGS): Add -DGDBSERVER
15006 (various make rules): Remove -DGDBSERVER
15007
15008 2012-11-09 Yao Qi <yao@codesourcery.com>
15009
15010 * spu-low.c (current_ptid): Move it to ..
15011 * gdbthread.h: ... here. New.
15012 * remote-utils.c (read_ptid): Use macro 'current_ptid'.
15013 * server.c (myresume, process_serial_event): Likewise.
15014 * thread-db.c (thread_db_find_new_threads): Likewise.
15015 * tracepoint.c (run_inferior_command): Likewise.
15016
15017 2012-10-01 Andrew Burgess <aburgess@broadcom.com>
15018
15019 * server.c (handle_search_memory_1): Include access length in
15020 warning message.
15021
15022 2012-09-05 Michael Brandt <michael.brandt@axis.com>
15023
15024 * linux-crisv32-low.c: Fix compile errors.
15025
15026 2012-09-04 Yao Qi <yao@codesourcery.com>
15027
15028 * tracepoint.c (cmd_qtsv): Adjust debug message.
15029 Don't check CUR_TPOINT.
15030
15031 2012-08-28 Yao Qi <yao@codesourcery.com>
15032
15033 * ax.c, tracepoint.c: Replace ATTR_FORMAT with ATTRIBUTE_PRINTF.
15034 * server.h: Include 'libiberty.h' and 'ansidecl.h'.
15035 (ATTR_NORETURN, ATTR_FORMAT, ATTR_MALLOC): Remove.
15036 Remove declarations of xmalloc, xreallloc, xstrdup and
15037 freeargv.
15038 * Makefile.in (libiberty_h): New.
15039 (server_h): Append dependencies 'libiberty.h' and 'ansidecl.h'.
15040 (linux-bfin-low.o): Append dependency 'libiberty.h'.
15041
15042 2012-08-23 Yao Qi <yao@codesourcery.com>
15043
15044 * server.h: Remove declaration of 'xsnprintf'.
15045
15046 2012-08-22 Keith Seitz <keiths@redhat.com>
15047
15048 * server.h: Include build-gnulib-gbserver/config.h.
15049 * gdbreplay.c: Likewise.
15050
15051 2012-08-08 Doug Evans <dje@google.com>
15052
15053 * Makefile.in (SFILES): Add gdb_vecs.c.
15054 (OBS): Add gdb_vecs.o.
15055 (gdb_vecs_h, host_defs_h): New variables.
15056 (thread-db.o): Add $(gdb_vecs_h) dependency.
15057 (gdb_vecs.o): New rule.
15058 * thread-db.c: #include "gdb_vecs.h".
15059 (thread_db_load_search): Use a vector to iterate over path elements.
15060 Handle text appearing after "$pdir".
15061
15062 * configure.ac: Add check for strstr.
15063 * config.in: Regenerate.
15064 * configure: Regenerate.
15065
15066 2012-08-02 Ulrich Weigand <ulrich.weigand@linaro.org>
15067
15068 * hostio.c (handle_pread): If pread fails, fall back to attempting
15069 lseek/read.
15070 (handle_pwrite): Likewise for pwrite.
15071
15072 2012-08-01 Ulrich Weigand <ulrich.weigand@linaro.org>
15073
15074 * linux-arm-low.c (arm_linux_hw_point_initialize): Distinguish
15075 between unsupported TYPE and unimplementable ADDR/LEN combination.
15076 (arm_insert_point): Act on new return value.
15077
15078 2012-07-31 Pedro Alves <palves@redhat.com>
15079
15080 * server.c (process_point_options): Only skip tokens if we find
15081 one that is unrecognized. Don't treat 'X' specially while
15082 skipping unrecognized tokens.
15083
15084 2012-07-30 Ulrich Weigand <ulrich.weigand@linaro.org>
15085
15086 * linux-arm-low.c (arm_linux_hw_point_initialize): Do not attempt
15087 to 4-byte-align HW breakpoint addresses for Thumb.
15088
15089 2012-07-27 Yao Qi <yao@codesourcery.com>
15090
15091 PR remote/14161.
15092
15093 * server.h: Declare gdb_agent_about_to_close.
15094 * target.c (kill_inferior): Include "agent.h".
15095 New. Send command 'kill'.
15096 * target.h (kill_inferior): Removed macro.
15097 * tracepoint.c (gdb_agent_about_to_close): New.
15098 (gdb_agent_helper_thread): Handle command 'close'.
15099 Wait endlessly until the inferior stops.
15100 Install gdb_agent_remove_socket to atexit hook.
15101 (agent_socket_name): New static variable.
15102 (gdb_agent_socket_init): Replace local variable 'name' with
15103 'agent_socket_name'.
15104 (gdb_agent_remove_socket): New.
15105
15106 2012-07-27 Yao Qi <yao@codesourcery.com>
15107
15108 * server.c (process_point_options): Stop at 'X' when parsing.
15109
15110 2012-07-19 Michael Eager <eager@eagercon.com>
15111
15112 * i386-low.c (Z_packet_to_hw_type): Add Z_PACKET_HW_BP, translate
15113 to hw_execute.
15114 * linux-x86-low.c (x86_insert_point, x86_remove_point):
15115 Call i386_low_insert_watchpoint, i386_low_remove_watchpoint to add/del
15116 hardware breakpoint.
15117
15118 2012-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
15119
15120 * gdbserver/linux-low.c (initialize_low): Call
15121 linux_ptrace_init_warnings.
15122
15123 2012-07-02 Doug Evans <dje@google.com>
15124
15125 * mem-break.c (gdb_no_commands_at_breakpoint): Fix cast from
15126 pointer to int.
15127
15128 2012-07-02 Stan Shebs <stan@codesourcery.com>
15129
15130 * Makefile.in (WARN_CFLAGS_NO_FORMAT): Define.
15131 (ax.o): Add it to build rule.
15132 (ax-ipa.o): Ditto.
15133 (OBS): Add format.o.
15134 (IPA_OBS): Add format.o.
15135 * server.c (handle_query): Claim support for breakpoint commands.
15136 (process_point_options): Add command case.
15137 (process_serial_event): Leave running if there are printfs in
15138 effect.
15139 * mem-break.h (any_persistent_commands): Declare.
15140 (add_breakpoint_commands): Declare.
15141 (gdb_no_commands_at_breakpoint): Declare.
15142 (run_breakpoint_commands): Declare.
15143 * mem-break.c (struct point_command_list): New struct.
15144 (struct breakpoint): New field command_list.
15145 (any_persistent_commands): New function.
15146 (add_commands_to_breakpoint): New function.
15147 (add_breakpoint_commands): New function.
15148 (gdb_no_commands_at_breakpoint): New function.
15149 (run_breakpoint_commands): New function.
15150 * linux-low.c (linux_wait_1): Test for and run breakpoint commands
15151 locally.
15152 * ax.c: Include format.h.
15153 (ax_printf): New function.
15154 (gdb_eval_agent_expr): Add printf opcode.
15155
15156 2012-06-13 Yao Qi <yao@codesourcery.com>
15157
15158 * server.c (start_inferior): Remove duplicated writes to fields
15159 'last_resume_kind' and 'last_status' of 'current_inferior'.
15160
15161 2012-06-12 Yao Qi <yao@codesourcery.com>
15162 Pedro Alves <palves@redhat.com>
15163
15164 * linux-low.c (linux_set_resume_request): Simplify predicate. Add
15165 comment.
15166 * server.c (handle_v_cont): Extend comment.
15167
15168 2012-06-11 Yao Qi <yao@codesourcery.com>
15169
15170 * linux-low.c (linux_attach): Add 'static'.
15171
15172 2012-06-06 Yao Qi <yao@codesourcery.com>
15173
15174 * ax.c (gdb_eval_agent_expr): Print `top' in hex.
15175
15176 2012-06-01 Jan Kratochvil <jan.kratochvil@redhat.com>
15177
15178 Fix gcc -flto compilation warning.
15179 * server.c (main): Make variable multi_mode and attach volatile.
15180
15181 2012-05-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
15182
15183 * linux-low.c (get_r_debug): Disable code using DT_MIPS_RLD_MAP
15184 if the platform doesn't know about it.
15185
15186 2012-05-30 Jeff Kenton <jkenton@tilera.com>
15187
15188 * Makefile.in (SFILES): Add linux-tile-low.c.
15189 (linux-tile-low.o, reg-tilegx.o, reg-tilegx.c): New rules.
15190 * configure.srv: Handle tilegx-*-linux*.
15191 * linux-tile-low.c: New file.
15192
15193 2012-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
15194
15195 * linux-low.c (linux_qxfer_libraries_svr4): Return -1 if R_DEBUG is -1.
15196
15197 2012-05-24 Pedro Alves <palves@redhat.com>
15198
15199 PR gdb/7205
15200
15201 Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.
15202
15203 2012-05-24 Pedro Alves <palves@redhat.com>
15204
15205 PR gdb/7205
15206
15207 Replace target_signal with gdb_signal throughout.
15208
15209 2012-05-22 Maciej W. Rozycki <macro@codesourcery.com>
15210
15211 * linux-low.c (linux_store_registers): Avoid the copying sequence
15212 when no data has been retrieved by ptrace.
15213
15214 2012-05-22 Will Deacon <will.deacon@arm.com>
15215
15216 * linux-low (__UCLIBC__ && !(__UCLIBC_HAS_MMU__ || __ARCH_HAS_MMU__)):
15217 Include asm/ptrace.h.
15218 (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define only if not
15219 already defined.
15220
15221 2012-05-21 Maciej W. Rozycki <macro@codesourcery.com>
15222
15223 * linux-low.c (linux_store_registers): Don't re-retrieve data
15224 with ptrace that has already been obtained from /proc. Always
15225 copy any data retrieved with ptrace to the buffer supplied.
15226
15227 2012-05-11 Yao Qi <yao@codesourcery.com>
15228 Pedro Alves <palves@redhat.com>
15229
15230 * linux-low.c (enum stopping_threads_kind): New.
15231 (stopping_threads): Change type to `enum stopping_threads_kind'.
15232 (handle_extended_wait): If stopping and suspending threads, leave
15233 the new_lwp suspended too.
15234 (linux_wait_for_event): Adjust.
15235 (stop_all_lwps): Set `stopping_threads' to
15236 STOPPING_AND_SUSPENDING_THREADS or STOPPING_THREADS depending on
15237 whether we're suspending threads or just stopping them. Assert no
15238 recursion happens.
15239
15240 2012-04-29 Yao Qi <yao@codesourcery.com>
15241
15242 * server.h: Move some code to ...
15243 * gdbthread.h: ... here. New.
15244 * Makefile.in (inferiors.o, regcache.o): Depends on gdbthread.h
15245 (remote-utils.o, server.o, target.o tracepoint.o): Likewise.
15246 (nto-low.o, win32-low.o): Likewise.
15247 * inferiors.c, linux-low.h, nto-low.c: Include gdbthread.h.
15248 * regcache.c, remote-utils.c, server.c: Likewise.
15249 * target.c, tracepoint.c, win32-low.c: Likewise.
15250
15251 2012-04-24 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
15252
15253 * linux-low.h (PTRACE_ARG3_TYPE): Move macro from linux-low.c.
15254 (PTRACE_ARG4_TYPE): Likewise.
15255 (PTRACE_XFER_TYPE): Likewise.
15256 * linux-arm-low.c (arm_prepare_to_resume): Cast third argument of
15257 ptrace to PTRACE_ARG3_TYPE.
15258 * linux-low.c (PTRACE_ARG3_TYPE): Move macro to linux-low.h.
15259 (PTRACE_ARG4_TYPE): Likewise.
15260 (PTRACE_XFER_TYPE): Likewise.
15261 (linux_detach_one_lwp): Cast fourth argument of
15262 ptrace to long then PTRACE_ARG4_TYPE.
15263 (regsets_fetch_inferior_registers): Cast third argument of
15264 ptrace to long then PTRACE_ARG3_TYPE.
15265 (regsets_store_inferior_registers): Likewise.
15266
15267 2012-04-20 Pedro Alves <palves@redhat.com>
15268
15269 * configure: Regenerate.
15270
15271 2012-04-19 Pedro Alves <palves@redhat.com>
15272
15273 * Makefile.in (GNULIB_BUILDDIR): New.
15274 (LIBGNU, INCGNU, GNULIB_H): Adjust.
15275 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): New.
15276 (all, install-only, uninstall, clean-info, all-lib, clean): No
15277 longer pass GNULIB_FLAGS_TO_PASS. Use subdir_do.
15278 (maintainer-clean realclean distclean): Use subdir_do.
15279 (subdir_do): New.
15280 (gnulib/import/Makefile): Adjust. Replace gnulib/import with
15281 $(GNULIB_BUILDDIR). Don't pass argument to config.status.
15282 * acinclude.m4: Include acx_configure_dir.m4.
15283 * configure.ac: Remove gl_EARLY, gl_INIT, and AM_INIT_AUTOMAKE
15284 calls. Call AC_PROG_RANLIB. Configure gnulib using
15285 ACX_CONFIGURE_DIR.
15286 (GNULIB): New.
15287 (GNULIB_STDINT_H): Adjust.
15288 (AC_OUTPUT): Don't output gnulib/Makefile anymore.
15289 * gdbreplay.c: Include build-gnulib/config.h.
15290 * server.h: Likewise.
15291 * aclocal.m4: Regenerate.
15292 * config.in: Regenerate.
15293 * configure: Regenerate.
15294
15295 2012-04-19 Pedro Alves <palves@redhat.com>
15296
15297 * Makefile.in (LIBGNU, INCGNU): Adjust.
15298 (GNULIB_FLAGS_TO_PASS, GNULIB_H): Adjust.
15299 (all, install-only, uninstall, clean-info, all-lib, clean)
15300 (maintainer-clean, Makefile, gnulib/Makefile): Adjust.
15301 * configure.ac: Adjust AC_OUTPUT output.
15302 * aclocal.m4: Regenerate.
15303 * configure: Regenerate.
15304
15305 2012-04-19 Pedro Alves <palves@redhat.com>
15306
15307 * Makefile.in (generated_files): New.
15308 (server_h): Remove the explicit dependency on config.h, and depend
15309 on $generated_files.
15310
15311 2012-04-19 Pedro Alves <palves@redhat.com>
15312
15313 * Makefile.in (INCGNU): Add -Ignulib.
15314
15315 2012-04-19 Pedro Alves <palves@redhat.com>
15316
15317 * Makefile.in (GNULIB_INCLUDE_DIR): Rename to ...
15318 (INCGNU): ... this, and spell out -I here.
15319 (GNULIB_LIB): Rename to ...
15320 (LIBGNU): ... this.
15321 (INCLUDE_CFLAGS, gdbserver$(EXEEXT), $(GNULIB_LIB) rule): Adjust.
15322
15323 2012-04-19 Pedro Alves <palves@redhat.com>
15324
15325 * config.in: Regenerate.
15326
15327 2012-04-19 Pedro Alves <palves@redhat.com>
15328
15329 * configure.ac: Remove AC_CHECK_DECLS check for memmem.
15330 * server.h (memmem): Remove declaration.
15331 * config.in: Regenerate.
15332 * configure: Regenerate.
15333
15334 2012-04-19 Yao Qi <yao@codesourcery.com>
15335
15336 * Makefile.in (SFILES): Add common/vec.c.
15337 (OBS): Add vec.o.
15338 (vec.o): New rule.
15339
15340 2012-04-19 Yao Qi <yao@codesourcery.com>
15341
15342 * remote-utils.c (prepare_resume_reply): Replace with macro
15343 target_core_of_thread.
15344 * server.c (handle_qxfer_threads_proper): Likewise.
15345 * target.h (traget_core_of_thread): New macro.
15346
15347 2012-04-18 Pedro Alves <palves@redhat.com>
15348
15349 * aclocal.m4: Regenerate.
15350 * configure: Regenerate.
15351
15352 2012-04-16 Yao Qi <yao@codesourcery.com>
15353
15354 * tracepoint.c (cmd_qtstart): Download tracepoints even when they are
15355 duplicated on address.
15356
15357 2012-04-16 Yao Qi <yao@codesourcery.com>
15358
15359 * tracepoint.c (COPY_FIELD_TO_BUF): New macro.
15360 (struct tracepoint_action_ops) <send>: New field.
15361 (m_tracepoint_action_send, r_tracepoint_action_send): New.
15362 (agent_expr_send, x_tracepoint_action_send): New.
15363 (l_tracepoint_action_send): New.
15364 (cmd_qtdp): Download and install tracepoint
15365 according to `use_agent'.
15366 (run_inferior_command): Add one more parameter `len'.
15367 Update callers.
15368 (tracepoint_send_agent): New.
15369 (cmd_qtdp, cmd_qtstart): Call tracepoint_send_agent.
15370
15371 2012-04-16 Yao Qi <yao@codesourcery.com>
15372
15373 * tracepoint.c (download_tracepoints): Moved to ...
15374 (cmd_qtstart): ... here.
15375
15376 2012-04-14 Yao Qi <yao@codesourcery.com>
15377
15378 * tracepoint.c: Include inttypes.h.
15379 (struct collect_memory_action): Use sized types.
15380 (struct tracepoint): Likewise.
15381 (cmd_qtdp, stop_tracing): Update print specifiers.
15382 (cmd_qtp, response_tracepoint): Likewise.
15383 (collect_data_at_tracepoint): Likewise.
15384 (collect_data_at_step): Likewise.
15385
15386 2012-04-14 Yao Qi <yao@codesourcery.com>
15387
15388 Import gnulib module inttypes.
15389 * aclocal.m4, config.in, configure: Regenerated.
15390
15391 2012-04-14 Yao Qi <yao@codesourcery.com>
15392
15393 * Makefile.in (maintainer-clean, realclean, distclean): Remove
15394 Makefile and config.status at last.
15395
15396 2012-04-13 Yao Qi <yao@codesourcery.com>
15397
15398 * tracepoint.c: Include stdint.h unconditionally.
15399
15400 2012-04-13 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
15401
15402 * acinclude.m4 (GDBSERVER_HAVE_THREAD_DB_TYPE): New macro based
15403 on BFD_HAVE_SYS_PROCFS_TYPE.
15404 * configure.ac: Look for lwpid_t and psaddr_t in libthread_db.h.
15405 * configure: Regenerate.
15406 * config.in: Likewise.
15407
15408 2012-04-13 H.J. Lu <hongjiu.lu@intel.com>
15409
15410 * Makefile.in (clean): Also remove x32.c x32-linux.c
15411 x32-avx.c x32-avx-linux.c.
15412 (x32.o): New target.
15413 (x32.c): Likewise.
15414 (x32-linux.o): Likewise.
15415 (x32-linux.c): Likewise.
15416 (x32-avx.o): Likewise.
15417 (x32-avx.c): Likewise.
15418 (x32-avx-linux.o): Likewise.
15419 (x32-avx-linux.c): Likewise.
15420
15421 * configure.srv (srv_amd64_regobj): Add x32.o x32-avx.o.
15422 (srv_amd64_linux_regobj): Add x32-linux.o x32-avx-linux.o.
15423 (srv_i386_64bit_xmlfiles): Add i386/x32-core.xml.
15424 (srv_amd64_xmlfiles): Add i386/x32.xml i386/x32-avx.xml.
15425 (srv_amd64_linux_xmlfiles): Add i386/x32-linux.xml
15426 i386/x32-avx-linux.xml.
15427
15428 * linux-x86-low.c (init_registers_x32_linux): New prototype.
15429 (init_registers_x32_avx_linux): Likwise.
15430 (x86_linux_update_xmltarget): Call init_registers_x32_linux
15431 or init_registers_x32_avx_linux if linux_is_elf64 is false.
15432
15433 2012-04-13 Pedro Alves <palves@redhat.com>
15434
15435 * Makefile.in (GNULIB_FLAGS_TO_PASS): New.
15436 (FLAGS_TO_PASS): Don't change or set $top_srcdir, $srcdir and VPATH.
15437 (all, uninstall, clean-info, all-lib, clean, maintainer-clean)
15438 (realclean, distclean): Explicitly pass $GNULIB_FLAGS_TO_PASS to
15439 the sub-make.
15440
15441 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
15442
15443 * linux-x86-low.c (compat_x32_clock_t): New.
15444 (compat_x32_siginfo_t): Likewise.
15445 (compat_x32_siginfo_from_siginfo): Likewise.
15446 (siginfo_from_compat_x32_siginfo): Likewise.
15447 (linux_is_elf64): Likewise.
15448 (x86_siginfo_fixup): Call compat_x32_siginfo_from_siginfo
15449 and siginfo_from_compat_x32_siginfo for x32.
15450 (x86_arch_setup): Set linux_is_elf64.
15451
15452 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
15453
15454 PR gdb/13969
15455 * linux-low.c (linux_pid_exe_is_elf_64_file): Also return the
15456 e_machine field.
15457 (linux_qxfer_libraries_svr4): Update call to elf_64_file_p.
15458 * linux-low.h (linux_pid_exe_is_elf_64_file): Updated.
15459 * linux-x86-low.c (x86_arch_setup): Check if GDBserver is
15460 compatible with process.
15461
15462 2012-04-12 Yao Qi <yao@codesourcery.com>
15463
15464 * Makefile.in: Define abs_top_srcdir and abs_srcdir.
15465 (INCLUDE_CFLAGS): Append GNULIB_INCLUDE_DIR.
15466 (install-only, install-info, clean): Handle sub dir gnulib.
15467 (all-lib, am--refresh): New targets.
15468 (memmem.o): Remove target.
15469 * configure.ac: Remove AC_CONFIG_LIBOBJ_DIR.
15470 Invoke gl_EARLY. Invoke AC_CHECK_PROGS for make.
15471 (AC_REPLACE_FUNCS): Remove memmem.
15472 Invoke gl_INIT and AM_INIT_AUTOMAKE.
15473 (AC_OUTPUT): Generate Makefile in gnulib/.
15474 * aclocal.m4, config.in, configure: Regenerated.
15475
15476 2012-04-10 Maciej W. Rozycki <macro@codesourcery.com>
15477
15478 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP.
15479
15480 2012-04-05 Pedro Alves <palves@redhat.com>
15481
15482 -Werror=strict-aliasing
15483
15484 * spu-low.c (parse_spufs_run): Avoid dereferencing type-punned
15485 pointer.
15486
15487 2012-04-04 Pedro Alves <palves@redhat.com>
15488
15489 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
15490 (sparc_store_gregset_from_stack, sparc_store_gregset)
15491 (sparc_breakpoint_at): Fix formatting.
15492
15493 2012-03-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
15494
15495 * configure.ac: Check whether Elf32_auxv_t and Elf64_auxv_t
15496 are available.
15497 * linux-low.c [HAVE_ELF32_AUXV_T] (Elf32_auxv_t): Add typedef.
15498 [HAVE_ELF64_AUXV_T] (Elf64_auxv_t): Likewise.
15499 * config.in: Regenerate.
15500 * configure: Likewise.
15501
15502 2012-03-29 Pedro Alves <palves@redhat.com>
15503
15504 * linux-low.c (regsets_store_inferior_registers) [__sparc__]:
15505 Correct ptrace arguments.
15506
15507 2012-03-28 Pedro Alves <palves@redhat.com>
15508
15509 * linux-ia64-low.c (ia64_regmap): Map IA64_EC_REGNUM to PT_AR_EC.
15510 (IA64_GR0_REGNUM, IA64_FR0_REGNUM)
15511 (IA64_FR1_REGNUM): New defines.
15512 (ia64_fetch_register): New.
15513 (the_low_target): Install it.
15514 * linux-low.h (struct linux_target_ops) <fetch_register>: New
15515 field.
15516 * linux-low.c (linux_fetch_registers): Try the
15517 the_low_target.fetch_register hook first.
15518
15519 * linux-arm-low.c (the_low_target): Adjust.
15520 * linux-bfin-low.c (the_low_target): Adjust.
15521 * linux-cris-low.c (the_low_target): Adjust.
15522 * linux-crisv32-low.c (the_low_target): Adjust.
15523 * linux-m32r-low.c (the_low_target): Adjust.
15524 * linux-m68k-low.c (the_low_target): Adjust.
15525 * linux-mips-low.c (the_low_target): Adjust.
15526 * linux-ppc-low.c (the_low_target): Adjust.
15527 * linux-s390-low.c (the_low_target): Adjust.
15528 * linux-sh-low.c (the_low_target): Adjust.
15529 * linux-sparc-low.c (the_low_target): Adjust.
15530 * linux-tic6x-low.c (the_low_target): Adjust.
15531 * linux-x86-low.c (the_low_target): Adjust.
15532 * linux-xtensa-low.c (the_low_target): Adjust.
15533
15534 2012-03-26 Pedro Alves <palves@redhat.com>
15535
15536 * server.c (handle_qxfer_libraries): Don't bail early if
15537 the_target->qxfer_libraries_svr4 is not NULL.
15538
15539 2012-03-26 Pedro Alves <palves@redhat.com>
15540
15541 * linux-low.c (linux_qxfer_libraries_svr4): Fix pasto in comment.
15542
15543 2012-03-23 Pedro Alves <palves@redhat.com>
15544
15545 * linux-low.c (linux_qxfer_libraries_svr4): Terminate the
15546 "library-list-svr4" element's start tag when the the DSO list is
15547 empty.
15548
15549 2012-03-23 Pedro Alves <palves@redhat.com>
15550
15551 * linux-low.c (read_one_ptr): Read the inferior's pointer through
15552 a variable whose type size is the same as the inferior's pointer
15553 size.
15554
15555 2012-03-21 Thomas Schwinge <thomas@codesourcery.com>
15556
15557 * linux-arm-low.c (arm_stopped_by_watchpoint): Use siginfo_t instead of
15558 struct siginfo.
15559 * linux-low.c (siginfo_fixup, linux_xfer_siginfo): Likewise.
15560 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
15561 * linux-low.h: Include <signal.h>.
15562 (struct siginfo): Remove forward declaration.
15563 (struct linux_target_ops) <siginfo_fixup>: Use siginfo_t instead of
15564 struct siginfo.
15565
15566 2012-03-21 Mike Frysinger <vapier@gentoo.org>
15567
15568 * .gitignore: Ignore more files.
15569
15570 2012-03-19 Pedro Alves <palves@redhat.com>
15571 Jan Kratochvil <jan.kratochvil@redhat.com>
15572
15573 * server.c (cont_thread, general_thread): Add describing comments.
15574 (start_inferior): Clear `cont_thread'.
15575 (handle_v_cont): Don't set `cont_thread' if resuming all threads
15576 of a process.
15577
15578 2012-03-15 Yao Qi <yao@codesourcery.com>
15579
15580 * tracepoint.c (install_tracepoint): Move duplicated tracepoint
15581 handling to ...
15582 (cmd_qtdp): ... here.
15583
15584 2012-03-15 Yao Qi <yao@codesourcery.com>
15585
15586 * tracepoint.c (struct tracepoint_action_ops): New.
15587 (struct tracepoint_action) [!IN_PROCESS_AGENT] <ops>: New field.
15588 (m_tracepoint_action_download): New.
15589 (r_tracepoint_action_download): New.
15590 (x_tracepoint_action_download): New.
15591 (l_tracepoint_action_download): New.
15592 (add_tracepoint_action): Install `action->ops' according type.
15593 (download_tracepoint_1): Move code `download' function pointer
15594 of various tracepoint_action_ops.
15595
15596 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
15597
15598 * linux-low.c (linux_attach_lwp_1): New variable buffer. Call
15599 linux_ptrace_attach_warnings.
15600
15601 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
15602
15603 * Makefile.in (linux-ptrace.o): New.
15604 * configure.srv (arm*-*-linux*, bfin-*-*linux*, crisv32-*-linux*)
15605 (cris-*-linux*, i[34567]86-*-linux*, ia64-*-linux*, m32r*-*-linux*)
15606 (m68*-*-linux*, m68*-*-uclinux*, mips*-*-linux*, powerpc*-*-linux*)
15607 (s390*-*-linux*, sh*-*-linux*, sparc*-*-linux*, tic6x-*-uclinux)
15608 (x86_64-*-linux*, xtensa*-*-linux*): Add linux-ptrace.o to SRV_TGTOBJ
15609 of these targets.
15610 * linux-low.c (linux_attach_lwp_1): Remove redundent else clause.
15611
15612 2012-03-08 Yao Qi <yao@codesourcery.com>
15613 Pedro Alves <palves@redhat.com>
15614
15615 Fix PR server/13392.
15616 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Check
15617 offset of JMP insn.
15618 * tracepoint.c (remove_tracepoint): New.
15619 (cmd_qtdp): Call remove_tracepoint when failed to install.
15620
15621 2012-03-07 Pedro Alves <palves@redhat.com>
15622
15623 * linux-low.c (get_detach_signal): New.
15624 (linux_detach_one_lwp): Get rid of a pending SIGSTOP with SIGCONT.
15625 Pass on pending signals to PTRACE_DETACH. Check the result of the
15626 ptrace call.
15627 * server.c (program_signals, program_signals_p): New.
15628 (handle_general_set): Handle QProgramSignals.
15629 * server.h (program_signals, program_signals_p): Declare.
15630
15631 2012-03-05 Pedro Alves <palves@redhat.com>
15632 Jan Kratochvil <jan.kratochvil@redhat.com>
15633
15634 * linux-low.c (get_dynamic): Don't warn when PT_PHDR isn't found.
15635 New comment why.
15636
15637 2012-03-03 Yao Qi <yao@codesourcery.com>
15638
15639 * tracepoint.c (tracepoint_look_up_symbols): Update call to
15640 agent_look_up_symbols.
15641
15642 2012-03-03 Yao Qi <yao@codesourcery.com>
15643
15644 * Makefile.in (linux-low.o): Keep dependence on agent.h.
15645 (linux-x86-low.o): Likewise.
15646 * server.h: Remove in_process_agent_loaded.
15647 * tracepoint.c (in_process_agent_loaded): Removed. Moved it
15648 common/agent.c.
15649 Update callers.
15650
15651 2012-03-03 Yao Qi <yao@codesourcery.com>
15652
15653 * tracepoint.c (gdb_agent_capability): New global.
15654 (in_process_agent_loaded_ust): Renamed to
15655 `in_process_agent_supports_ust'.
15656 Update callers.
15657 (in_process_agent_supports_ust): Call agent_capability_check.
15658 (clear_installed_tracepoints): Assert that agent supports
15659 agent.
15660
15661 2012-03-03 Yao Qi <yao@codesourcery.com>
15662
15663 * linux-low.c (linux_supports_agent): New.
15664 (linux_target_ops): Initialize field `supports_agent' with
15665 linux_supports_agent.
15666 * target.h (struct target_ops) <supports_agent>: New.
15667 (target_supports_agent): New macro.
15668 * server.c (handle_general_set): Handle packet 'QAgent'.
15669 (handle_query): Send `QAgent+'.
15670 * Makefile.in (server.o): Depends on agent.h.
15671
15672 2012-03-03 Yao Qi <yao@codesourcery.com>
15673
15674 * Makefile.in (OBS): Add agent.o.
15675 Add new rule for agent.o.
15676 Track dependence of tracepoint.c on agent.h.
15677 * tracepoint.c (run_inferior_command_1):
15678 (run_inferior_command): Call agent_run_command.
15679 (gdb_ust_connect_sync_socket): Deleted. Move it to
15680 common/agent.c.
15681 (resume_thread, stop_thread): Likewise.
15682 (gdb_ust_socket_init): Renamed to ...
15683 (gdb_agent_socket_init): ... New.
15684 (gdb_ust_thread): Renamed to ...
15685 (gdb_agent_helper_thread): ... New.
15686 (gdb_ust_init): Move some code to ...
15687 (gdb_agent_init): ... here. New.
15688 [HAVE_UST]: Call gdb_ust_init.
15689 (initialize_tracepoint_ftlib): Call gdb_agent_init.
15690 * configure.ac: Add `sys/un.h' to AC_CHECK_HEADERS.
15691 * config.in, configure: Regenerated.
15692
15693 2012-03-02 Pedro Alves <palves@redhat.com>
15694
15695 * inferiors.c (add_pid_to_list, pull_pid_from_list): Delete.
15696 * linux-low.c (struct simple_pid_list): New.
15697 (stopped_pids): New a struct simple_pid_list pointer.
15698 (add_to_pid_list, pull_pid_from_list): New.
15699 (handle_extended_wait): Don't assume the first signal new children
15700 report is SIGSTOP. Adjust call to pull_pid_from_list.
15701 (linux_wait_for_lwp): Adjust.
15702
15703 2012-03-02 Yao Qi <yao@codesourcery.com>
15704
15705 * tracepoint.c (do_action_at_tracepoint): Write `stop_pc' in
15706 debug log.
15707
15708 2012-03-02 Yao Qi <yao@codesourcery.com>
15709
15710 * tracepoint.c (collect_ust_data_at_tracepoint): Remove parameters
15711 `stop_pc' and `tpoint'. Update caller.
15712
15713 2012-03-01 Maciej W. Rozycki <macro@codesourcery.com>
15714
15715 * linux-low.h (linux_target_ops): Add regset_bitmap member.
15716 * linux-low.c (use_linux_regsets): New macro.
15717 [!HAVE_LINUX_REGSETS] (regsets_fetch_inferior_registers): Likewise.
15718 [!HAVE_LINUX_REGSETS] (regsets_store_inferior_registers): Likewise.
15719 (linux_register_in_regsets): New function.
15720 (usr_fetch_inferior_registers): Skip registers covered by
15721 regsets.
15722 (usr_store_inferior_registers): Likewise.
15723 (usr_fetch_inferior_registers): New macro.
15724 (usr_store_inferior_registers): Likewise.
15725 (linux_fetch_registers): Handle mixed regset/non-regset targets.
15726 (linux_store_registers): Likewise.
15727 * linux-mips-low.c (init_registers_mips_dsp_linux): New
15728 prototype.
15729 (init_registers_mips64_dsp_linux): Likewise.
15730 (init_registers_mips_linux): New macro.
15731 (init_registers_mips_dsp_linux): Likewise.
15732 (mips_dsp_num_regs): Likewise.
15733 (DSP_BASE, DSP_CONTROL): New fallback macros.
15734 (mips_base_regs): New macro.
15735 (mips_regmap): Use it. Fix the size.
15736 (mips_dsp_regmap): New variable.
15737 (mips_dsp_regset_bitmap): Likewise.
15738 (mips_arch_setup): New function.
15739 (mips_cannot_fetch_register): Use the_low_target.regmap rather
15740 than mips_regmap.
15741 (mips_cannot_store_register): Likewise.
15742 (the_low_target): Update .arch_setup, .num_regs and .regmap
15743 initializers. Add .regset_bitmap initializer.
15744 * linux-arm-low.c (the_low_target): Add .regset_bitmap
15745 initializer.
15746 * linux-bfin-low.c (the_low_target): Likewise.
15747 * linux-cris-low.c (the_low_target): Likewise.
15748 * linux-crisv32-low.c (the_low_target): Likewise.
15749 * linux-ia64-low.c (the_low_target): Likewise.
15750 * linux-m32r-low.c (the_low_target): Likewise.
15751 * linux-m68k-low.c (the_low_target): Likewise.
15752 * linux-ppc-low.c (the_low_target): Likewise.
15753 * linux-s390-low.c (the_low_target): Likewise.
15754 * linux-sh-low.c (the_low_target): Likewise.
15755 * linux-sparc-low.c (the_low_target): Likewise.
15756 * linux-tic6x-low.c (the_low_target): Likewise.
15757 * linux-x86-low.c (the_low_target): Likewise.
15758 * linux-xtensa-low.c (the_low_target): Likewise.
15759 * configure.srv <mips*-*-linux*>: Add mips-dsp-linux.o and
15760 mips64-dsp-linux.o to srv_regobj. Add mips-dsp-linux.xml,
15761 mips64-dsp-linux.xml, mips-dsp.xml and mips64-dsp.xml to
15762 srv_xmlfiles.
15763 * Makefile.in (mips-dsp-linux.o, mips-dsp-linux.c): New targets.
15764 (mips64-dsp-linux.o, mips64-dsp-linux.c): Likewise.
15765
15766 2012-02-29 Yao Qi <yao@codesourcery.com>
15767 Pedro Alves <palves@redhat.com>
15768
15769 * linux-low.c: (linux_wait_1): Call unsuspend_all_lwps when
15770 `step_over_finished' is true.
15771
15772 2012-02-27 Pedro Alves <palves@redhat.com>
15773
15774 * linux-low.c (pid_is_stopped): Delete, moved to common/.
15775 (linux_attach_lwp_1): Adjust to use linux_proc_pid_is_stopped.
15776
15777 2012-02-27 Pedro Alves <palves@redhat.com>
15778
15779 PR server/9684
15780 * linux-low.c (pid_is_stopped): New.
15781 (linux_attach_lwp_1): Handle attaching to 'T (stopped)' processes.
15782
15783 2012-02-25 Luis Machado <lgustavo@codesourcery.com>
15784
15785 * mem-break.c (clear_gdb_breakpoint_conditions): Fix de-allocation
15786 of conditions.
15787
15788 2012-02-24 Maciej W. Rozycki <macro@codesourcery.com>
15789
15790 * linux-mips-low.c (mips_regmap): Correct the index of $f9.
15791
15792 2012-02-24 Luis Machado <lgustavo@codesourcery>
15793
15794 * server.c (handle_query): Advertise support for target-side
15795 breakpoint condition evaluation.
15796 (process_point_options): New function.
15797 (process_serial_event): When inserting a breakpoint, check for
15798 a target-side condition that should be evaluated.
15799
15800 * mem-break.c: Include regcache.h and ax.h.
15801 (point_cond_list_t): New data structure.
15802 (breakpoint) <cond_list>: New field.
15803 (find_gdb_breakpoint_at): Make non-static.
15804 (delete_gdb_breakpoint_at): Clear any target-side
15805 conditions.
15806 (clear_gdb_breakpoint_conditions): New function.
15807 (add_condition_to_breakpoint): Likewise.
15808 (add_breakpoint_condition): Likewise.
15809 (gdb_condition_true_at_breakpoint): Likewise.
15810 (gdb_breakpoint_here): Return result directly instead
15811 of going through a local variable.
15812
15813 * mem-break.h (find_gdb_breakpoint_at): New prototype.
15814 (clear_gdb_breakpoint_conditions): Likewise.
15815 (add_breakpoint_condition): Likewise.
15816 (gdb_condition_true_at_breakpoint): Likewise.
15817
15818 * linux-low.c (linux_wait_1): Evaluate target-side breakpoint condition.
15819 (need_step_over_p): Take target-side breakpoint condition into
15820 consideration.
15821
15822 2012-02-24 Luis Machado <lgustavo@codesourcery>
15823
15824 * server.h: Include tracepoint.h.
15825 (agent_mem_read, agent_get_trace_state_variable_value,
15826 agent_set_trace_state_variable_value,
15827 agent_tsv_read, agent_mem_read_string, get_get_tsv_func_addr,
15828 get_set_tsv_func_addr): New prototypes.
15829
15830 * ax.h: New include file.
15831 * ax.c: New source file.
15832
15833 * tracepoint.c: Include ax.h.
15834 (gdb_agent_op, gdb_agent_op_names, gdb_agent_op_sizes,
15835 agent_expr, eval_result_type): Move to ax.h.
15836 (parse_agent_expr): Rename to ...
15837 (gdb_parse_agent_expr): ... this, make it non-static and move
15838 to ax.h.
15839 (unparse_agent_expr) Rename to ...
15840 (gdb_unparse_agent_expr): ... this, make it non-static and move
15841 to ax.h.
15842 (eval_agent_expr): Rename to ...
15843 (eval_tracepoint_agent_expr): ... this.
15844 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Remove
15845 forward declarations.
15846 (add_tracepoint_action): Call gdb_parse_agent_expr (...).
15847 (agent_get_trace_state_variable_value): New function.
15848 (agent_set_trace_state_variable_value): New function.
15849 (cmd_qtdp): Call gdb_parse_agent_expr (...).
15850 (response_tracepoint): Call gdb_unparse_agent_expr (...).
15851 (do_action_at_tracepoint): Call eval_tracepoint_agent_expr (...).
15852 (condition_true_at_tracepoint): Likewise.
15853 (parse_agent_expr): Rename to ...
15854 (gdb_parse_agent_expr): ... this and move to ax.c.
15855 (unparse_agent_expr): Rename to ...
15856 (gdb_unparse_agent_expr): ... this and move to ax.c.
15857 (gdb_agent_op_name): Move to ax.c.
15858 (eval_agent_expr): Rename to ...
15859 (gdb_eval_agent_expr): ... this, use regcache passed as parameter
15860 and move to ax.c.
15861 (eval_tracepoint_agent_expr): New function.
15862 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Make
15863 non-static.
15864 (current_insn_ptr, emit_error, struct bytecode_address): Move to
15865 ax.c.
15866 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul, emit_lsh,
15867 emit_rsh_signed, emit_rsh_unsigned, emit_ext, emit_log_not,
15868 emit_bit_and, emit_bit_or, emit_bit_xor, emit_bit_not, emit_equal,
15869 emit_less_signed, emit_less_unsigned, emit_ref, emit_if_goto,
15870 emit_goto, write_goto_address, emit_const, emit_reg, emit_pop,
15871 emit_stack, emit_zero_ext, emit_swap, emit_stack_adjust,
15872 emit_int_call_1, emit_void_call_2, emit_eq_goto, emit_ne_goto,
15873 emit_lt_goto, emit_ge_goto, emit_gt_goto, emit_le_goto): Move to ax.c.
15874 (get_get_tsv_func_addr, get_set_tsv_func_addr): New functions.
15875 (compile_bytecodes): Remove forward declaration.
15876 (is_goto_target): Move to ax.c.
15877 (compile_bytecodes): Move to ax.c and call
15878 agent_get_trace_state_variable_value (...) and
15879 agent_set_trace_state_variable_value (...).
15880
15881 * Makefile.in: Update ax.c and IPA dependencies.
15882
15883 2012-02-24 Pedro Alves <palves@redhat.com>
15884
15885 * tracepoint.c (cmd_bigqtbuffer): Rename as ...
15886 (cmd_bigqtbuffer_circular): ... this. Only handle
15887 'QTBuffer:circular:'.
15888 (handle_tracepoint_general_set): Adjust.
15889
15890 2012-02-16 Yao Qi <yao@codesourcery.com>
15891
15892 * inferiors.c: Move code to ...
15893 * dll.c: .... here. New.
15894 * server.h: Declare clear_dlls.
15895 * Makefile.in (SFILES): Add dll.c.
15896 (OBS): Add dll.o
15897 (dll.o): New rule.
15898
15899 2012-02-11 Yao Qi <yao@codesourcery.com>
15900
15901 * server.c: (handle_monitor_command): Add a new parameter
15902 `own_buf'.
15903 (handle_query): Update caller.
15904
15905 2012-02-09 Joel Brobecker <brobecker@adacore.com>
15906
15907 * configure.ac: Add readlink to AC_CHECK_FUNCS list.
15908 * configure, config.in: Regenerate.
15909 * hostio.c: Provide an alternate implementation if HAVE_READLINK
15910 is not defined.
15911
15912 2012-02-02 Pedro Alves <palves@redhat.com>
15913
15914 Try SIGKILL first, then PTRACE_KILL.
15915 * linux-low.c (linux_kill_one_lwp): New.
15916 (linux_kill_one_lwp): Rename to ...
15917 (kill_one_lwp_callback): ... this. Use the new
15918 linux_kill_one_lwp.
15919
15920 2012-02-02 Pedro Alves <palves@redhat.com>
15921
15922 * tracepoint.c (cmd_qtminftpilen): Return 0 if there's no current
15923 inferior.
15924
15925 2012-01-27 Pedro Alves <palves@redhat.com>
15926
15927 * linux-low.c (linux_child_pid_to_exec_file): Delete.
15928 (elf_64_file_p): Make static.
15929 (linux_pid_exe_is_elf_64_file): New.
15930 * linux-low.h (linux_child_pid_to_exec_file, elf_64_file_p):
15931 Delete declarations.
15932 (linux_pid_exe_is_elf_64_file): Declare.
15933 * linux-x86-low.c (x86_arch_setup): Use
15934 linux_pid_exe_is_elf_64_file.
15935
15936 2012-01-25 Jan Kratochvil <jan.kratochvil@redhat.com>
15937
15938 * linux-low.c (linux_wait_for_event_1): Rename to ...
15939 (linux_wait_for_event): ... here and merge it with former
15940 linux_wait_for_event - new variable wait_ptid, use it.
15941 (linux_wait_for_event): Remove - merge it to linux_wait_for_event_1.
15942
15943 2012-01-23 Pedro Alves <palves@redhat.com>
15944
15945 * server.c (main): Avoid yet another case of infinite loop while
15946 detaching/killing after a longjmp.
15947
15948 2012-01-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15949
15950 Code cleanup.
15951 * linux-low.c (linux_wait_for_event_1): Use ptid_is_pid.
15952
15953 2012-01-20 Ulrich Weigand <ulrich.weigand@linaro.org>
15954
15955 * hostio.c (handle_readlink): New function.
15956 (handle_vFile): Call it to handle "vFile:readlink" packets.
15957
15958 2012-01-20 Pedro Alves <palves@redhat.com>
15959 Ulrich Weigand <ulrich.weigand@linaro.org>
15960
15961 * server.c (handle_v_requests): Only support vAttach and vRun to
15962 start multiple processes when in extended protocol mode.
15963
15964 2012-01-17 Pedro Alves <palves@redhat.com>
15965
15966 * tracepoint.c (initialize_tracepoint): Use mmap instead of
15967 memalign plus mprotect to allocate the scratch buffer.
15968
15969 2012-01-13 Pedro Alves <palves@redhat.com>
15970
15971 * server.c (attach_inferior): Clear `cont_thread'.
15972
15973 2012-01-13 Pedro Alves <palves@redhat.com>
15974
15975 * server.c (main): Avoid infinite loop while detaching/killing
15976 after a longjmp.
15977
15978 2012-01-09 Doug Evans <dje@google.com>
15979
15980 * server.c (start_inferior): Set last_ptid in --wrapper case.
15981
15982 2012-01-06 Yao Qi <yao@codesourcery.com>
15983
15984 * tracepoint.c [IN_PROCESS_AGENT] (debug_threads): Macro
15985 defined.
15986 [IN_PROCESS_AGENT] (debug_agent): New global variable.
15987
15988 2012-01-04 Yao Qi <yao@codesourcery.com>
15989
15990 * tracepoint.c (cmd_qtdp): Print debug message
15991 for static tracepoint.
15992
15993 2012-01-04 Yao Qi <yao@codesourcery.com>
15994
15995 * tracepoint.c (trace_vdebug): Differentiate debug message
15996 between gdbserver and IPA.
15997
15998 2012-01-03 Yao Qi <yao@codesourcery.com>
15999
16000 * tracepoint.c (tracepoint_was_hit): Don't collect for
16001 static tracepoint.
16002
16003 2012-01-02 Joel Brobecker <brobecker@adacore.com>
16004
16005 * terminal.h: Reformat copyright header.
16006
16007 2012-01-02 Joel Brobecker <brobecker@adacore.com>
16008
16009 * server.c (gdbserver_version): Update copyright year.
16010 * gdbreplay.c (gdbreplay_version): Likewise.
16011
16012 2011-12-18 Jan Kratochvil <jan.kratochvil@redhat.com>
16013
16014 * linux-low.c (linux_create_inferior): Put empty if clause for write.
16015
16016 Revert:
16017 2011-12-18 Hui Zhu <teawater@gmail.com>
16018 * linux-low.c (linux_create_inferior): Save return value to ret.
16019
16020 2011-12-18 Hui Zhu <teawater@gmail.com>
16021
16022 * linux-low.c (linux_create_inferior): Save return value to ret.
16023
16024 2011-12-16 Doug Evans <dje@google.com>
16025
16026 * linux-low.c (linux_create_inferior): If stdio connection,
16027 redirect stdin from /dev/null, stdout to stderr.
16028 * remote-utils.c (remote_is_stdio): New static global.
16029 (remote_connection_is_stdio): New function.
16030 (remote_prepare): Handle stdio connection.
16031 (remote_open): Ditto.
16032 (remote_close): Don't close stdin for stdio connections.
16033 (read_prim,write_prim): New functions. Replace all calls to
16034 read/write to these.
16035 * server.c (main): Watch for "-" argument. Move call to
16036 remote_prepare before start_inferior.
16037 * server.h (STDIO_CONNECTION_NAME): New macro.
16038 (remote_connection_is_stdio): Declare.
16039
16040 * remote-utils.c (prepare_resume_reply): Remove extraneous \n
16041 in debugging output.
16042
16043 2011-12-15 Yao Qi <yao@codesourcery.com>
16044
16045 * tracepoint.c: Include sys/syscall.h.
16046 (gdb_ust_thread): Remove preprocessor conditional.
16047
16048 2011-12-14 Pedro Alves <pedro@codesourcery.com>
16049
16050 * linux-low.c (linux_detach_one_lwp): Call
16051 the_low_target.prepare_to_resume before detaching.
16052
16053 2011-12-14 Yao Qi <yao@codesourcery.com>
16054
16055 * tracepoint.c (gdb_ust_thread): Don't ignore return value
16056 of write.
16057
16058 2011-12-14 Yao Qi <yao@codesourcery.com>
16059
16060 * i386-low.c (i386_low_stopped_data_address): Initialize local
16061 variable `control'.
16062
16063 2011-12-13 Pedro Alves <pedro@codesourcery.com>
16064
16065 PR remote/13492
16066
16067 * i386-low.c (i386_low_stopped_data_address): Avoid fetching
16068 DR_CONTROL unless necessary. Extend comments.
16069 * linux-x86-low.c (x86_linux_prepare_to_resume): Don't write to
16070 DR0-3 if not used. If any watchpoint was set, clear DR_STATUS.
16071
16072 2011-12-13 Yao Qi <yao@codesourcery.com>
16073
16074 * tracepoint.c (trace_buffer_alloc): Replace magic numbers with
16075 macros.
16076 (upload_fast_traceframes, upload_fast_traceframes): Likewise.
16077
16078 2011-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
16079
16080 * linux-low.c (linux_kill): Skip PTRACE_KILL if LWP does not exist.
16081 Print new debug message for such case.
16082
16083 2011-12-06 Jan Kratochvil <jan.kratochvil@redhat.com>
16084
16085 Fix overlapping memcpy.
16086 * mem-break.c (set_raw_breakpoint_at): New variable buf. Use it for
16087 the read_inferior_memory transfer.
16088 (delete_fast_tracepoint_jump): New variable buf. Use it for the
16089 write_inferior_memory transfer.
16090 (set_fast_tracepoint_jump): New variable buf. Use it for the
16091 read_inferior_memory and write_inferior_memory transfers.
16092 (uninsert_fast_tracepoint_jumps_at, reinsert_fast_tracepoint_jumps_at)
16093 (delete_raw_breakpoint, uninsert_raw_breakpoint): New variable buf.
16094 Use it for the write_inferior_memory transfer.
16095 (check_mem_read, check_mem_write): New gdb_asserts for overlapping
16096 buffers.
16097
16098 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
16099
16100 * linux-low.c (fetch_register, store_register): Make code
16101 consistent, fix formatting.
16102
16103 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
16104
16105 * linux-low.c (usr_store_inferior_registers): Factor out code
16106 to handle individual registers into...
16107 (store_register): ... this new function.
16108
16109 2011-12-06 Ulrich Weigand <uweigand@de.ibm.com>
16110
16111 * Makefile.in (s390-linux32v1.o, s390-linux32v1.c): New rules.
16112 (s390-linux32v2.o, s390-linux32v2.c): Likewise.
16113 (s390-linux64v1.o, s390-linux64v1.c): Likewise.
16114 (s390-linux64v2.o, s390-linux64v2.c): Likewise.
16115 (s390x-linux64v1.o, s390x-linux64v1.c): Likewise.
16116 (s390x-linux64v2.o, s390x-linux64v2.c): Likewise.
16117 * configure.srv [s390*-*-linux*] (srv_regobj): Add new objects.
16118 (srv_xmlfiles): Add new XML files.
16119
16120 * linux-s390-low.c: Include "elf/common.h", <sys/ptrace.h>,
16121 and <sys/uio.h>.
16122 (PTRACE_GETREGSET, PTRACE_SETREGSET): Define if undefined.
16123 (init_registers_s390_linux32v1): Add prototype.
16124 (init_registers_s390_linux32v2): Likewise.
16125 (init_registers_s390_linux64v1): Likewise.
16126 (init_registers_s390_linux64v2): Likewise.
16127 (init_registers_s390x_linux64v1): Likewise.
16128 (init_registers_s390x_linux64v2): Likewise.
16129 (s390_num_regs): Increment to 52.
16130 (s390_regmap): Add orig_r2 register.
16131 (s390_num_regs_3264): Increment to 68.
16132 (s390_regmap_3264): Add orig_r2 register.
16133 (s390_collect_ptrace_register): Handle orig_r2 register.
16134 (s390_supply_ptrace_register): Likewise.
16135 (s390_fill_last_break): New function.
16136 (s390_store_last_break): Likewise.
16137 (s390_fill_system_call): New function.
16138 (s390_store_system_call): Likewise.
16139 (target_regsets): Handle NT_S390_LAST_BREAK and NT_S390_SYSTEM_CALL
16140 register sets.
16141 (s390_check_regset): New function.
16142 (s390_arch_setup): Check for presence of NT_S390_LAST_BREAK and
16143 NT_S390_SYSTEM_CALL regsets and use appropriate description.
16144 Update target_regsets for available register sets.
16145
16146 2011-12-02 Paul Pluzhnikov <ppluzhnikov@google.com>
16147 Jan Kratochvil <jan.kratochvil@redhat.com>
16148
16149 * linux-low.c (get_phdr_phnum_from_proc_auxv, get_dynamic, get_r_debug)
16150 (read_one_ptr, struct link_map_offsets, linux_qxfer_libraries_svr4):
16151 New.
16152 (struct linux_target_ops): Install linux_qxfer_libraries_svr4.
16153 * linux-low.h (struct process_info_private): New member r_debug.
16154 * server.c (handle_qxfer_libraries): Call
16155 the_target->qxfer_libraries_svr4.
16156 (handle_qxfer_libraries_svr4): New function.
16157 (qxfer_packets): New entry "libraries-svr4".
16158 (handle_query): Check QXFER_LIBRARIES_SVR4 and report libraries-svr4.
16159 * target.h (struct target_ops): New member qxfer_libraries_svr4.
16160 * remote.c (remote_xfer_partial): Call add_packet_config_cmd for
16161 PACKET_qXfer_libraries_svr4.
16162
16163 2011-11-30 Ulrich Weigand <uweigand@de.ibm.com>
16164
16165 * linux-s390-low.c (s390_collect_ptrace_register): Fully convert
16166 PSW address/mask between 8-byte and 16-byte formats.
16167 (s390_supply_ptrace_register): Likewise.
16168 (s390_get_pc, s390_set_pc): 4-byte PSW address always includes
16169 basic addressing mode bit.
16170
16171 2011-11-24 Stan Shebs <stan@codesourcery.com>
16172
16173 * tracepoint.c (cmd_qtstatus): Use plongest instead of %llx.
16174
16175 2011-11-17 Stan Shebs <stan@codesourcery.com>
16176
16177 * tracepoint.c (struct tracepoint): New field traceframe_usage.
16178 (tracing_start_time): New global.
16179 (tracing_stop_time): New global.
16180 (tracing_user_name): New global.
16181 (tracing_notes): New global.
16182 (tracing_stop_note): New global.
16183 (cmd_qtstart): Set traceframe_usage, start_time.
16184 (stop_tracing): Set stop_time.
16185 (cmd_qtstatus): Report additional status.
16186 (cmd_qtp): New function.
16187 (handle_tracepoint_query): Call it.
16188 (cmd_qtnotes): New function.
16189 (handle_tracepoint_general_set): Call it.
16190 (get_timestamp): Rename from tsv_get_timestamp.
16191
16192 2011-11-14 Stan Shebs <stan@codesourcery.com>
16193 Kwok Cheung Yeung <kcy@codesourcery.com>
16194
16195 * linux-x86-low.c (small_jump_insn): New.
16196 (i386_install_fast_tracepoint_jump_pad): Add arguments for
16197 trampoline and error message, build a trampoline and issue a small
16198 jump instruction to it.
16199 (x86_install_fast_tracepoint_jump_pad): Add arguments for
16200 trampoline and error message.
16201 (x86_get_min_fast_tracepoint_insn_len): New.
16202 (the_low_target): Add call to x86_get_min_fast_tracepoint_insn_len.
16203 * linux-low.h (struct linux_target_ops): Add arguments to
16204 install_fast_tracepoint_jump_pad operation, add new operation.
16205 * linux-low.c (linux_install_fast_tracepoint_jump_pad): Add
16206 arguments.
16207 (linux_get_min_fast_tracepoint_insn_len): New function.
16208 (linux_target_op): Add new operation.
16209 * tracepoint.c (gdb_trampoline_buffer): New IPA variable.
16210 (gdb_trampoline_buffer_end): Ditto.
16211 (gdb_trampoline_buffer_error): Ditto.
16212 (struct ipa_sym_addresses): Add fields for new IPA variables.
16213 (symbol_list): Add entries for new IPA variables.
16214 (struct tracepoint): Add fields to hold the address range of the
16215 trampoline used by the tracepoint.
16216 (trampoline_buffer_head): New static variable.
16217 (trampoline_buffer_tail): Ditto.
16218 (claim_trampoline_space): New function.
16219 (have_fast_tracepoint_trampoline_buffer): New function.
16220 (clone_fast_tracepoint): Fill in trampoline fields of tracepoint
16221 structure.
16222 (install_fast_tracepoint): Ditto, also add error buffer argument.
16223 (cmd_qtminftpilen): New function.
16224 (handle_tracepoint_query): Add response to qTMinFTPILen packet.
16225 (fast_tracepoint_from_trampoline_address): New function.
16226 (fast_tracepoint_collecting): Handle trampoline as part of jump
16227 pad space.
16228 (set_trampoline_buffer_space): New function.
16229 (initialize_tracepoint): Initialize new IPA variables.
16230 * target.h (struct target_ops): Add arguments to
16231 install_fast_tracepoint_jump_pad operation, add new
16232 get_min_fast_tracepoint_insn_len operation.
16233 (target_get_min_fast_tracepoint_insn_len): New.
16234 (install_fast_tracepoint_jump_pad): Add arguments.
16235 * server.h (IPA_BUFSIZ): Define.
16236 * linux-i386-ipa.c: Include extra header files.
16237 (initialize_fast_tracepoint_trampoline_buffer): New function.
16238 (initialize_low_tracepoint): Call it.
16239 * server.h (set_trampoline_buffer_space): Declare.
16240 (claim_trampoline_space): Ditto.
16241 (have_fast_tracepoint_trampoline_buffer): Ditto.
16242
16243 2011-11-14 Yao Qi <yao@codesourcery.com>
16244
16245 * server.c (handle_query): Handle InstallInTrace for qSupported.
16246 * tracepoint.c (add_tracepoint): Sort list.
16247 (install_tracepoint, download_tracepoint): New.
16248 (cmd_qtdp): Call them to install and download tracepoints.
16249 (sort_tracepoints): Removed.
16250 (cmd_qtstart): Update.
16251
16252 2011-11-14 Yao Qi <yao@codesourcery.com>
16253
16254 * mem-break.c (inc_ref_fast_tracepoint_jump): New.
16255 * mem-break.h: Declare.
16256 * tracepoint.c (cmd_qtstart): Move some code to ...
16257 (clone_fast_tracepoint, install_fast_tracepoint): ... here.
16258 New.
16259 (download_tracepoints): Move some code to ...
16260 (download_tracepoint_1): ... here. New.
16261
16262 2011-11-08 Yao Qi <yao@codesourcery.com>
16263
16264 * remote-utils.c (relocate_instruction): A comment fix.
16265
16266 2011-11-07 Joel Brobecker <brobecker@adacore.com>
16267
16268 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): Delete.
16269 (i386_dr_low_get_control, i386_dr_low_get_status): Use
16270 dr_status_mirror and dr_control_mirror from debug_reg_state.
16271 (i386_dr_low_get_status): Use debug_reg_state.dr_status_mirror
16272 (i386_initial_stuff): Remove use of deleted globals.
16273 (i386_get_thread_context, i386_set_thread_context,
16274 i386_thread_added): Use dr_status_mirror and dr_control_mirror
16275 from debug_reg_state.
16276
16277 2011-11-05 Yao Qi <yao@codesourcery.com>
16278
16279 * tracepoint.c (gdb_collect): Loop over tracepoints of same
16280 address as TPOINT's.
16281
16282 2011-11-02 Stan Shebs <stan@codesourcery.com>
16283
16284 * tracepoint.c (agent_mem_read_string): New function.
16285 (eval_agent_expr): Call it for tracenz.
16286 * server.c (handle_query): Report support for tracenz.
16287
16288 2011-11-02 Yao Qi <yao@codesourcery.com>
16289
16290 * tracepoint.c (cmd_qtstart): Remove unused local variables.
16291
16292 2011-11-02 Yao Qi <yao@codesourcery.com>
16293
16294 * target.h: Fix a typo in comment.
16295
16296 2011-10-31 Pedro Alves <pedro@codesourcery.com>
16297
16298 * mem-break.c (check_mem_write): Add `myaddr' parameter. Don't
16299 clobber the breakpoints' shadows with fast tracepoint jumps.
16300 * mem-break.h (check_mem_write): Add `myaddr' parameter.
16301 * target.c (write_inferior_memory): Also pass MYADDR down to
16302 check_mem_write.
16303
16304 2011-10-07 Ulrich Weigand <ulrich.weigand@linaro.org>
16305
16306 * configure.ac: Check support for personality routine.
16307 * configure: Regenerate.
16308 * config.in: Likewise.
16309 * linux-low.c: Include <sys/personality.h>.
16310 Define ADDR_NO_RANDOMIZE if necessary.
16311 (linux_create_inferior): Disable address space randomization when
16312 forking inferior, if requested.
16313 (linux_supports_disable_randomization): New function.
16314 (linux_target_ops): Install it.
16315 * server.h (disable_randomization): Declare.
16316 * server.c (disable_randomization): New global variable.
16317 (handle_general_set): Handle QDisableRandomization.
16318 (handle_query): Likewise for qSupported.
16319 (main): Support --disable-randomization and --no-disable-randomization
16320 command line arguments.
16321 * target.h (struct target_ops): Add supports_disable_randomization.
16322 (target_supports_disable_randomization): New macro.
16323
16324 2011-09-29 Mike Frysinger <vapier@gentoo.org>
16325
16326 * linux-low.c (target_loadseg): Add defined PTRACE_GETFDPIC to the
16327 ifdef check.
16328 [PT_GETDSBT] (target_loadmap): Wrap in a defined PT_GETDSBT check.
16329 [!PT_GETDSBT] (target_loadmap): New definition.
16330 (LINUX_LOADMAP, LINUX_LOADMAP_EXEC, LINUX_LOADMAP_INTERP): Define.
16331 (linux_read_loadmap): Change PTRACE_GETDSBT_EXEC to
16332 LINUX_LOADMAP_EXEC, PTRACE_GETDSBT_INTERP to LINUX_LOADMAP_INTERP,
16333 and PT_GETDSBT to LINUX_LOADMAP.
16334 [!PT_GETDSBT] (linux_read_loadmap): Define to NULL.
16335 (linux_target_ops): Delete unnecessary ifdef PT_GETDSBT check.
16336
16337 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
16338
16339 * linux-arm-low.c (struct arm_linux_hwbp_cap): Remove.
16340 (arm_linux_hwbp_cap): New static variable.
16341 (arm_linux_get_hwbp_cap): Replace by ...
16342 (arm_linux_init_hwbp_cap): ... this new function.
16343 (arm_linux_get_hw_breakpoint_count): Use arm_linux_hwbp_cap.
16344 (arm_linux_get_hw_watchpoint_count): Likewise.
16345 (arm_linux_get_hw_watchpoint_max_length): Likewise.
16346 (arm_arch_setup): Call arm_linux_init_hwbp_cap.
16347 (arm_prepare_to_resume): Use perror_with_name instead of error.
16348
16349 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
16350
16351 * linux-arm-low.c: Include <signal.h>.
16352 (PTRACE_GETHBPREGS, PTRACE_SETHBPREGS): Define if necessary.
16353 (struct arm_linux_hwbp_cap): New data type.
16354 (arm_hwbp_type, arm_hwbp_control_t): New typedefs.
16355 (struct arm_linux_hw_breakpoint): New data type.
16356 (MAX_BPTS, MAX_WPTS): Define.
16357 (struct arch_process_info, struct arch_lwp_info): New data types.
16358 (arm_linux_get_hwbp_cap): New function.
16359 (arm_linux_get_hw_breakpoint_count): Likewise.
16360 (arm_linux_get_hw_watchpoint_count): Likewise.
16361 (arm_linux_get_hw_watchpoint_max_length): Likewise.
16362 (arm_hwbp_control_initialize): Likewise.
16363 (arm_hwbp_control_is_enabled): Likewise.
16364 (arm_hwbp_control_is_initialized): Likewise.
16365 (arm_hwbp_control_disable): Likewise.
16366 (arm_linux_hw_breakpoint_equal): Likewise.
16367 (arm_linux_hw_point_initialize): Likewise.
16368 (struct update_registers_data): New data structure.
16369 (update_registers_callback: New function.
16370 (arm_insert_point): Likewise.
16371 (arm_remove_point): Likewise.
16372 (arm_stopped_by_watchpoint): Likewise.
16373 (arm_stopped_data_address): Likewise.
16374 (arm_new_process): Likewise.
16375 (arm_new_thread): Likewise.
16376 (arm_prepare_to_resume): Likewise.
16377 (the_low_target): Register arm_insert_point, arm_remove_point,
16378 arm_stopped_by_watchpoint, arm_stopped_data_address, arm_new_process,
16379 arm_new_thread, and arm_prepare_to_resume.
16380
16381 2011-09-15 Stan Shebs <stan@codesourcery.com>
16382
16383 * server.h (struct emit_ops): Add compare-goto fields.
16384 * tracepoint.c (gdb_agent_op_sizes): New table.
16385 (emit_eq_goto): New function.
16386 (emit_ne_goto): New function.
16387 (emit_lt_goto): New function.
16388 (emit_le_goto): New function.
16389 (emit_gt_goto): New function.
16390 (emit_ge_goto): New function.
16391 (is_goto_target): New function.
16392 (compile_bytecodes): Recognize special cases of compare-goto
16393 combinations and call specialized emitters for them.
16394 * linux-x86-low.c (amd64_emit_eq_goto): New function.
16395 (amd64_emit_ne_goto): New function.
16396 (amd64_emit_lt_goto): New function.
16397 (amd64_emit_le_goto): New function.
16398 (amd64_emit_gt_goto): New function.
16399 (amd64_emit_ge_goto): New function.
16400 (amd64_emit_ops): Add the new functions.
16401 (i386_emit_eq_goto): New function.
16402 (i386_emit_ne_goto): New function.
16403 (i386_emit_lt_goto): New function.
16404 (i386_emit_le_goto): New function.
16405 (i386_emit_gt_goto): New function.
16406 (i386_emit_ge_goto): New function.
16407 (i386_emit_ops): Add the new functions.
16408
16409 2011-09-08 Stan Shebs <stan@codesourcery.com>
16410
16411 * linux-x86-low.c (i386_emit_prologue): Save %ebx.
16412 (i386_emit_epilogue): Restore %ebx.
16413
16414 2011-08-31 Jie Zhang <jzhang918@gmail.com>
16415
16416 * server.c (step_thread): Remove definition.
16417 (process_serial_event): Don't handle Hs.
16418 * server.h (step_thread): Remove declaration.
16419 * target.c (set_desired_inferior): Remove use of step_thread.
16420
16421 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
16422
16423 * linux-low.c: Include linux-procfs.h.
16424 (linux_attach_lwp_1): Update comments.
16425 (linux_attach): Scan for existing threads when attaching to a
16426 process that is the tgid.
16427 * Makefile.in: Update dependencies.
16428
16429 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
16430
16431 * configure.srv: Add linux-procfs.o dependencies.
16432
16433 2011-08-14 Yao Qi <yao@codesourcery.com>
16434
16435 * target.h (struct target_ops): Fix indent.
16436 * win32-low.c (win32_target_ops): Fix comment.
16437
16438 2011-08-14 Andrew Jenner <andrew@codesourcery.com>
16439 Yao Qi <yao@codesourcery.com>
16440
16441 * Makefile.in (clean): Remove tic6x-*.c files.
16442 (linux-tic6x-low.o, tic6x-c62x-linux.o, tic6x-c64x-linux.o): New rules.
16443 (tic6x-c64xp-linux.o, tic6x-c62x-linux.c, tic6x-c64x-linux.c): Likewise.
16444 (tic6x-c64xp-linux.c): Likewise.
16445 * configure.srv: Add support for tic6x-*-uclinux.
16446 * linux-tic6x-low.c: New.
16447 * linux-low.c (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define.
16448
16449 2011-08-14 Andrew Stubbs <ams@codesourcery.com>
16450 Yao Qi <yao@codesourcery.com>
16451
16452 * target.h (struct target_ops): Add read_loadmap.
16453 * linux-low.c (struct target_loadseg): New type.
16454 (struct target_loadmap): New type.
16455 (linux_read_loadmap): New function.
16456 (linux_target_ops): Add linux_read_loadmap.
16457 * server.c (handle_query): Support qXfer:fdpic:read packet.
16458 * win32-low.c (win32_target_ops): Initialize field `read_loadmap'
16459 to NULL.
16460
16461 2011-08-05 Eli Zaretskii <eliz@gnu.org>
16462
16463 * win32-low.c: Include <stdint.h>.
16464
16465 2011-07-22 Pedro Alves <pedro@codesourcery.com>
16466
16467 * i386-low.c (i386_insert_aligned_watchpoint): Don't pass the info
16468 to the inferior here.
16469 (i386_remove_aligned_watchpoint): Ditto.
16470 (i386_handle_nonaligned_watchpoint): Return immediate on fail to
16471 fit part of the watchpoint in the debug registers.
16472 (i386_update_inferior_debug_regs): New.
16473 (i386_low_insert_watchpoint): Work on a local mirror of the debug
16474 registers, and only update the inferior on success.
16475 (i386_low_remove_watchpoint): Ditto.
16476
16477 2011-07-22 Kwok Cheung Yeung <kcy@codesourcery.com>
16478
16479 * linux-low.c (compare_ints, unique, list_threads, show_process,
16480 linux_core_of_thread): Delete.
16481 (linux_target_ops): Change linux_core_of_thread to
16482 linux_common_core_of_thread.
16483 (linux_qxfer_osdata): Defer to linux_common_xfer_osdata.
16484 * utils.c (malloc_failure): Change type of argument.
16485 (xmalloc, xrealloc, xcalloc, xsnprintf): Delete.
16486 * Makefile.in (SFILES): Add common/common-utils.c, common/xml-utils.c,
16487 common/linux-osdata.c, common/ptid.c and common/buffer.c.
16488 (OBS): Add xml-utils.o, common-utils.o, ptid.o and buffer.o.
16489 (IPA_OBJS): Add common-utils-ipa.o.
16490 (ptid_h, linux_osdata_h): New macros.
16491 (server_h): Add common/common-utils.h, common/xml-utils.h,
16492 common/buffer.h, common/gdb_assert.h, common/gdb_locale.h and
16493 common/ptid.h.
16494 (common-utils-ipa.o, common-utils.o, xml-utils.o, linux-osdata.o,
16495 ptid.o, buffer.o): New rules.
16496 (linux-low.o): Add common/linux-osdata.h as a dependency.
16497 * configure.srv (srv_tgtobj): Add linux-osdata.o to Linux targets.
16498 * configure.ac: Add AC_HEADER_DIRENT check.
16499 * config.in: Regenerate.
16500 * configure: Regenerate.
16501 * remote-utils.c (xml_escape_text): Delete.
16502 (buffer_grow, buffer_free, buffer_init, buffer_finish,
16503 buffer_xml_printf): Move to common/buffer.c.
16504 * server.c (main): Remove call to initialize_inferiors.
16505 * server.h (struct ptid, ptid_t, minus_one_ptid, null_ptid,
16506 ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp, ptid_get_tid,
16507 ptid_equal, ptid_is_pid, initialize_inferiors, xml_escape_text,
16508 internal_error, gdb_assert, gdb_assert_fail): Delete.
16509 (struct buffer, buffer_grow, buffer_free, buffer_init, buffer_finish,
16510 buffer_xml_printf, buffer_grow_str, buffer_grow_str0): Move to
16511 common/buffer.h.
16512 * inferiors.c (null_ptid, minus_one_ptid, ptid_build, pid_to_ptid,
16513 ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal, ptid_is_pid,
16514 initialize_inferiors): Delete.
16515
16516 2011-07-20 Pedro Alves <pedro@codesourcery.com>
16517
16518 * tracepoint.c (tracepoint_look_up_symbols): Return upon the first
16519 symbol error.
16520
16521 2011-05-31 Pedro Alves <pedro@codesourcery.com>
16522
16523 * linux-x86-low.c (i386_dr_low_get_addr): Fix off by one in
16524 assertion.
16525 * win32-i386-low.c (i386_dr_low_get_addr): Ditto.
16526
16527 2011-05-26 Yao Qi <yao@codesourcery.com>
16528
16529 * Makefile.in (thread-db.o): Track dependence to
16530 common/gdb_thread_db.h.
16531 * thread-db.c: include gdb_thread_db.h from right place.
16532
16533 2011-05-16 Adrian Cornish <gnu@bluedreamer.com>
16534
16535 * linux-i386-ipa.c (supply_static_tracepoint_registers): Pass
16536 __FILE__ and __LINE__ to internal_error.
16537
16538 2011-05-13 Doug Evans <dje@google.com>
16539
16540 * thread-db.c (try_thread_db_load_from_sdir): New function.
16541 (try_thread_db_load_from_dir): New function.
16542 (thread_db_load_search): Handle $sdir, ignore $pdir.
16543 Remove trying of system directories if search of
16544 libthread-db-search-path fails, that is now done via $sdir.
16545
16546 2011-05-12 Kwok Cheung Yeung <kcy@codesourcery.com>
16547
16548 * server.c (handle_query): Add EnableDisableTracepoints to the list
16549 of supported features.
16550 * tracepoint.c (clear_installed_tracepoints): Uninstall disabled
16551 tracepoints.
16552 (cmd_qtenable_disable): New.
16553 (cmd_qtstart): Install tracepoints even if disabled.
16554 (handle_tracepoint_general_set): Add call to cmd_qtenable_disable on
16555 receiving a QTEnable or QTDisable packet.
16556 (gdb_collect): Skip data collection if fast tracepoint is disabled.
16557 (ust_marker_to_static_tracepoint): Do not ignore disabled static
16558 tracepoints.
16559 (gdb_probe): Skip data collection if static tracepoint is disabled.
16560
16561 2011-05-10 Doug Evans <dje@google.com>
16562
16563 * thread-db.c (thread_db_handle_monitor_command): Handle elided path.
16564
16565 2011-05-04 Doug Evans <dje@google.com>
16566
16567 * linux-low.c (linux_join): Skip process lookup.
16568 * spu-low.c (spu_join): Ditto.
16569 * server.c (join_inferiors_callback): Delete.
16570 (process_serial_event): For 'D' packet (detach) call join_inferior
16571 directly.
16572
16573 2011-05-04 Joseph Myers <joseph@codesourcery.com>
16574
16575 * README: Don't mention xscale*-*-linux*.
16576 * configure.srv (xscale*-*-linux*): Don't handle target.
16577
16578 2011-04-27 Nathan Froyd <froydnj@codesourcery.com>
16579
16580 * linux-x86-low.c (amd64_emit_const): Call memcpy instead of
16581 casting pointers.
16582 (amd64_emit_reg, amd64_emit_int_call_1, amd64_emit_void_call_2):
16583 (i386_emit_const, i386_emit_reg, i386_emit_int_call_1):
16584 (i386_emit_void_call_2): Likewise.
16585
16586 2011-04-26 Yao Qi <yao@codesourcery.com>
16587
16588 * linux-low.c: Move common macros to linux-ptrace.h.
16589 Include linux-ptrace.h.
16590 * Makefile.in (linux_ptrace_h): New.
16591 (linux-low.o): Depends on linux-ptrace.h.
16592
16593 2011-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
16594
16595 * remote-utils.c (handle_accept_event): Close LISTEN_DESC only if
16596 RUN_ONCE. Comment for the LISTEN_DESC delete_file_handler call.
16597 (remote_prepare): New function with most of the TCP code from ...
16598 (remote_open): ... here. Detect PORT here unconditionally. Move also
16599 setting transport_is_reliable.
16600 * server.c (run_once): New variable.
16601 (gdbserver_usage): Document it.
16602 (main): Set run_once for `--once'. Call remote_prepare. Exit after
16603 the first run if RUN_ONCE.
16604 * server.h (run_once, remote_prepare): New declarations.
16605
16606 2011-04-19 Tom Tromey <tromey@redhat.com>
16607
16608 * win32-low.c (handle_load_dll): Remove duplicate "the".
16609
16610 2011-04-07 Pierre Muller <muller@ics.u-strasbg.fr>
16611
16612 Remove support for old Cygwin 1.5 versions.
16613 * win32-low.c (win32_create_inferior): Use new cygwin_path_list
16614 function to avoid warning.
16615 (win32_add_one_solib): Use cygwin_conv_path function to avoid
16616 warning.
16617
16618 2011-03-18 Pierre Muller <muller@ics.u-strasbg.fr>
16619
16620 * gdbserver/server.h (Macro _): Define it if not available.
16621
16622 2011-03-14 Michael Snyder <msnyder@vmware.com>
16623
16624 * hostio.c (handle_close): Remove unnecessary null test.
16625
16626 2011-03-10 Joel Brobecker <brobecker@adacore.com>
16627
16628 * Makefile.in (maintainer-clean realclean distclean): Remove
16629 "make ... subdir_do" command.
16630
16631 2011-03-10 Michael Snyder <msnyder@vmware.com>
16632
16633 * tracepoint.c (tracepoint_finish_step): Fix loop variable.
16634
16635 * server.c (handle_v_run): Free alloced buffer on early return.
16636
16637 2011-03-09 Yao Qi <yao@codesourcery.com>
16638
16639 Revert:
16640 2011-03-04 Yao Qi <yao@codesourcery.com>
16641
16642 * Makefile.in: Remove GNU make feature --directory.
16643
16644 2011-03-05 Yao Qi <yao@codesourcery.com>
16645
16646 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
16647 (subdir_do): New make target. Copied from gdb/Makefile.
16648 (maintainer-clean, realclean, distclean, clean): Call corresponding
16649 make targets in common/Makefile.
16650
16651 2011-02-11 Yao Qi <yao@codesourcery.com>
16652
16653 * configure.ac: Call AC_PROG_RANLIB.
16654 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
16655 * configure: Regenerate.
16656
16657 2011-03-07 Jan Kratochvil <jan.kratochvil@redhat.com>
16658
16659 * remote-utils.c (putpkt_binary_1): Calculate BUF2 size dynamically.
16660
16661 2011-03-06 Yao Qi <yao@codesourcery.com>
16662
16663 * Makefile.in (REQUIRED_SUBDIRS): Remove $(LIBCOMMON_DIR).
16664
16665 2011-03-05 Yao Qi <yao@codesourcery.com>
16666
16667 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
16668 (subdir_do): New make target. Copied from gdb/Makefile.
16669 (maintainer-clean, realclean, distclean, clean): Call corresponding
16670 make targets in common/Makefile.
16671
16672 2011-03-04 Yao Qi <yao@codesourcery.com>
16673
16674 * Makefile.in: Remove GNU make feature --directory.
16675
16676 2011-03-04 Michael Snyder <msnyder@vmware.com>
16677
16678 * server.c (queue_stop_reply): Call xmalloc not malloc.
16679
16680 2011-03-02 Michael Snyder <msnyder@vmware.com>
16681
16682 * linux-arm-low.c (arm_arch_setup): Replace malloc with xmalloc.
16683
16684 2011-02-28 Michael Snyder <msnyder@vmware.com>
16685
16686 * tracepoint.c (cmd_qtv): Discard unused value 'packet'.
16687 (cmd_qtframe): Ditto.
16688 (cmd_qtbuffer): Ditto.
16689 (cmd_bigqtbuffer): Ditto.
16690
16691 * utils.c (decimal2str): Initialize 'width' to nine, then
16692 don't mess with it.
16693
16694 2011-02-28 Ulrich Weigand <uweigand@de.ibm.com>
16695
16696 * hostio.c (require_data): Free *data, not data.
16697
16698 2011-02-28 Jan Kratochvil <jan.kratochvil@redhat.com>
16699
16700 * hostio.c (require_data): Use free, not xfree.
16701
16702 2011-02-27 Michael Snyder <msnyder@vmware.com>
16703
16704 * server.c (handle_query): Discard unused value.
16705
16706 * hostio.c (require_data): Free malloc memory before returning
16707 error.
16708
16709 2011-02-26 Michael Snyder <msnyder@vmware.com>
16710
16711 * linux-low.c (list_threads): Call closedir for dirent.
16712
16713 2011-02-27 Michael Snyder <msnyder@vmware.com>
16714
16715 * i386-low.c (i386-length_and_rw_bits): Comment the fact that
16716 a case statement falls through.
16717
16718 * linux-low.c (linux_xfer_siginfo): Fix fencepost error.
16719
16720 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Fix fencepost error
16721 in comparison.
16722
16723 2011-02-26 Michael Snyder <msnyder@vmware.com>
16724
16725 * utils.c (decimal2str): Eliminate dead code and dead param.
16726 (pulongest): Drop dead param from call to decimal2str.
16727 (plongest): Ditto.
16728
16729 2011-02-24 Joel Brobecker <brobecker@adacore.com>
16730
16731 Revert the following patch (not approved yet):
16732 2011-02-21 Hui Zhu <teawater@gmail.com>
16733 * tracepoint.c (tp_printf): New function.
16734 (eval_agent_expr): Handle gdb_agent_op_printf.
16735
16736 2011-02-21 Hui Zhu <teawater@gmail.com>
16737
16738 * tracepoint.c (tp_printf): New function.
16739 (eval_agent_expr): Handle gdb_agent_op_printf.
16740
16741 2011-02-18 Tom Tromey <tromey@redhat.com>
16742
16743 * Makefile.in (tracepoint-ipa.o): Depend on ax.def.
16744 (tracepoint.o): Likewise.
16745 * tracepoint.c (enum gdb_agent_op): Use ax.def.
16746 (gdb_agent_op_names): Likewise.
16747
16748 2011-02-18 Tom Tromey <tromey@redhat.com>
16749
16750 * tracepoint.c (enum gdb_agent_op) <gdb_agent_op_pick,
16751 gdb_agent_op_rot>: New constants.
16752 (gdb_agent_op_names): Add pick and roll.
16753 (eval_agent_expr) <gdb_agent_op_pick, gdb_agent_op_rot>: New
16754 cases.
16755
16756 2011-02-15 Jan Kratochvil <jan.kratochvil@redhat.com>
16757
16758 * aclocal.m4: Regenerated with aclocal-1.11.1.
16759
16760 2011-02-14 Pedro Alves <pedro@codesourcery.com>
16761
16762 * server.c (handle_qxfer_traceframe_info): New.
16763 (qxfer_packets): Register "traceframe-info".
16764 (handle_query): Report support for qXfer:traceframe-info:read+.
16765 * tracepoint.c (match_blocktype): New.
16766 (traceframe_find_block_type): Rename to ...
16767 (traceframe_walk_blocks): ... this. Add callback filter argument,
16768 and use it.
16769 (traceframe_find_block_type): New, reimplemented on top of
16770 traceframe_walk_blocks.
16771 (build_traceframe_info_xml): New.
16772 (traceframe_read_info): New.
16773 * server.h (traceframe_read_info): Declare.
16774
16775 2011-02-11 Yao Qi <yao@codesourcery.com>
16776
16777 * configure.ac: Call AC_PROG_RANLIB.
16778 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
16779 * configure: Regenerate.
16780
16781 2011-02-07 Pedro Alves <pedro@codesourcery.com>
16782
16783 * server.c (gdb_read_memory): Change return semantics to allow
16784 partial transfers.
16785 (handle_search_memory_1): Adjust.
16786 (process_serial_event) <'m' packet>: Handle partial transfers.
16787 * tracepoint.c (traceframe_read_mem): Handle partial transfers.
16788
16789 2011-01-28 Pedro Alves <pedro@codesourcery.com>
16790
16791 * regcache.c (init_register_cache): Initialize
16792 regcache->register_status.
16793 (free_register_cache): Release regcache->register_status.
16794 (regcache_cpy): Copy register_status.
16795 (registers_to_string): Print 'x's for unavailable registers.
16796 (supply_register): Mark the register's status valid or
16797 unavailable, depending on whether a buffer was passed in or not.
16798 (supply_register_zeroed): New.
16799 (supply_regblock): Mark the registers' status valid or
16800 unavailable, depending on whether a buffer was passed in or not.
16801 * regcache.h (REG_UNAVAILABLE, REG_VALID): New defines.
16802 (struct regcache): New `register_status' field.
16803 (supply_register_zeroed): Declare.
16804 * i387-fp.c (i387_xsave_to_cache): Zero out registers using
16805 supply_register_zeroed, rather than passing a NULL buffer to
16806 supply_register.
16807 * tracepoint.c (fetch_traceframe_registers): Update comment.
16808
16809 2011-01-28 Pedro Alves <pedro@codesourcery.com>
16810
16811 * i387-fp.c (i387_xsave_to_cache): Make passing NULL as register
16812 buffer explicit.
16813
16814 2011-01-25 Pedro Alves <pedro@codesourcery.com>
16815
16816 * server.h (decode_xfer_write): Change prototype.
16817 * remote-utils.c (decode_xfer_write): Remove `annex' parameter,
16818 and don't extract the annex here.
16819 * server.c (decode_xfer_read): Remove `annex' parameter,
16820 and don't extract the annex here.
16821 (decode_xfer): New.
16822 (struct qxfer): New.
16823 (handle_qxfer_auxv, handle_qxfer_features, handle_qxfer_libraries)
16824 (handle_qxfer_osdata, handle_qxfer_siginfo, handle_qxfer_spu)
16825 (handle_qxfer_statictrace): New functions, abstracted out from
16826 handle_query, and made to use the struct qxfer interface.
16827 (handle_threads_qxfer_proper): Rename to ...
16828 (handle_qxfer_threads_proper): ... this.
16829 (handle_threads_qxfer): Rename to ...
16830 (handle_qxfer_threads): ... this. Adjust.
16831 (qxfer_packets): New array.
16832 (handle_qxfer): New function.
16833 (handle_query): Use handle_qxfer.
16834
16835 2011-01-05 Michael Snyder <msnyder@msnyder-server.eng.vmware.com>
16836
16837 * gdbreplay.c: Shorten lines of >= 80 columns.
16838 * linux-low.c: Ditto.
16839 * linux-ppc-low.c: Ditto.
16840 * linux-s390-low.c: Ditto.
16841 * linux-sparc-low.c: Ditto.
16842 * linux-x86-low.c: Ditto.
16843 * linux-xtensa-low.c: Ditto.
16844 * mem-break.c: Ditto.
16845 * nto-low.c: Ditto.
16846 * regcache.h: Ditto.
16847 * remote-utils.c: Ditto.
16848 * server.c: Ditto.
16849 * server.h: Ditto.
16850 * thread-db.c: Ditto.
16851 * tracepoint.c: Ditto.
16852 * utils.c: Ditto.
16853 * win32-low.h: Ditto.
16854
16855 2011-01-05 Joel Brobecker <brobecker@adacore.com>
16856
16857 * gdbserver/configure.ac, gdbserver/gdbserver.1: Copyright year
16858 update.
16859
16860 2011-01-01 Joel Brobecker <brobecker@adacore.com>
16861
16862 * server.c (gdbserver_version): Update copyright year in version
16863 output.
16864 * gdbreplay.c (gdbreplay_version): Ditto.
16865
16866 2010-12-29 Jie Zhang <jie.zhang@analog.com>
16867
16868 * configure.srv (bfin-*-*linux*): Handle Blackfin/Linux targets.
16869 * linux-bfin-low.c: New file.
16870 * linux-low.c: Define PT_TEXT_ADDR, PT_TEXT_END_ADDR, and
16871 PT_DATA_ADDR for BFIN targets.
16872 * Makefile.in (SFILES): Add linux-bfin-low.c.
16873 (clean): Remove reg-bfin.c.
16874 (linux-bfin-low.o, reg-bfin.o, reg-bfin.c): New targets.
16875 * README: Mention supported Blackfin targets.
16876
16877 2010-12-23 Mike Frysinger <vapier@gentoo.org>
16878
16879 * .gitignore: New file.
16880
16881 2010-11-16 Mike Frysinger <vapier@gentoo.org>
16882
16883 * linux-low.c (linux_tracefork_child): Add char* cast to arg.
16884
16885 2010-10-22 Jie Zhang <jie@codesourcery.com>
16886
16887 * Makefile.in: Add FLAGS_TO_PASS variable.
16888 (install): Remove dependency of install-only and recursively
16889 invoke make for install-only.
16890
16891 2010-10-04 Doug Evans <dje@google.com>
16892
16893 * Makefile.in (uninstall): Use $(DESTDIR).
16894
16895 2010-09-24 Pedro Alves <pedro@codesourcery.com>
16896
16897 PR gdb/11842
16898
16899 * linux-x86-low.c (compat_siginfo_from_siginfo)
16900 (siginfo_from_compat_siginfo): Also copy si_pid and si_uid when
16901 si_code is < 0. Check for si_code == SI_TIMER before checking for
16902 si_code < 0.
16903
16904 2010-09-13 Joel Brobecker <brobecker@adacore.com>
16905
16906 * lynx-i386-low.c: New file.
16907 * configure.srv: Add handling of i[34567]86-*-lynxos* targets.
16908
16909 2010-09-13 Joel Brobecker <brobecker@adacore.com>
16910
16911 * lynx-low.c (ptrace_request_to_str): Remove handling for
16912 request values that have been removed in LynxOS 5.x.
16913
16914 2010-09-13 Joel Brobecker <brobecker@adacore.com>
16915
16916 * lynx-low.c, lynx-ppc-loc.c: Include <sys/ptrace.h> instead of
16917 <ptrace.h>
16918
16919 2010-09-09 Nathan Sidwell <nathan@codesourcery.com>
16920
16921 * configure.ac: Add --enable-inprocess-agent option.
16922 * configure: Rebuilt.
16923
16924 2010-09-06 Yao Qi <yao@codesourcery.com>
16925
16926 * linux-low.c (linux_kill): Remove unused variable.
16927 (linux_stabilize_threads): Likewise.
16928 * server.c (start_inferior): Likewise.
16929 (queue_stop_reply_callback): Likewise.
16930 * tracepoint.c (do_action_at_tracepoint): Likewise.
16931
16932 2010-09-06 Yao Qi <yao@codesourcery.com>
16933
16934 * linux-low.c (maybe_move_out_of_jump_pad): Restore current_inferior
16935 on return.
16936
16937 2010-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
16938
16939 * target.c (mywait) <TARGET_WAITKIND_EXITED>: Fix to use INTEGER.
16940
16941 2010-09-06 Pedro Alves <pedro@codesourcery.com>
16942
16943 * Makefile.in (install-only): Replace $IPA_DEPFILES with
16944 "$(IPA_DEPFILES)".
16945
16946 2010-09-01 Joel Brobecker <brobecker@adacore.com>
16947
16948 * gdbserver/lynx-low.c, gdbserver/lynx-low.h,
16949 gdbserver/lynx-ppc-low.c: New files.
16950 * Makefile.in (lynx_low_h): New variable.
16951 (lynx-low.o, lynx-ppc-low.o): New rules.
16952 * configure.ac: On LynxOS, link with -lnetinet.
16953 * configure.srv: Add handling of powerpc-*-lynxos* targets.
16954 * configure: regenerate.
16955
16956 2010-09-01 Joel Brobecker <brobecker@adacore.com>
16957
16958 * Makefile.in (vasprintf.o, vsnprintf.o): New rules.
16959 * configure.ac: Add check for vasprintf and vsnprintf.
16960 * configure, config.in: Regenerate.
16961 * server.h (vasprintf, vsnprintf): Add conditional declarations.
16962
16963 2010-09-01 Joel Brobecker <brobecker@adacore.com>
16964
16965 * gdbreplay.c: Move include of alloca.h up, next to include of
16966 malloc.h.
16967 * server.h: Add include of malloc.h.
16968 * mem-break.c: Remove include of malloc.h.
16969 * server.c, tracepoint.c, utils.c, win32-low.c: Likewise.
16970
16971 2010-09-01 Joel Brobecker <brobecker@adacore.com>
16972
16973 * Makefile.in (memmem.o): Build with -Wno-error.
16974
16975 2010-09-01 Joel Brobecker <brobecker@adacore.com>
16976
16977 * utils.c (xsnprintf): Make non-static.
16978 * server.h: Add xsnprintf declaration.
16979 * linux-low.c, nto-low.c, target.c, thread-db.c, tracepoint.c:
16980 replace calls to snprintf by calls to xsnprintf throughout.
16981
16982 2010-09-01 Joel Brobecker <brobecker@adacore.com>
16983
16984 * configure.ac: Add configure check for alloca.
16985 * configure, config.in: Regenerate.
16986 * server.h: Include alloca.h if it exists.
16987 * gdbreplay.c: Include alloca.h if it exists.
16988
16989 2010-08-28 Pedro Alves <pedro@codesourcery.com>
16990
16991 * linux-low.c (__SIGRTMIN): Define if not already defined.
16992 (linux_create_inferior): Check for __ANDROID__ rather than
16993 __SIGRTMIN.
16994 (enqueue_one_deferred_signal): Don't requeue non-RT signals that
16995 are already deferred.
16996 (linux_wait_1): Check for __ANDROID__ rather than __SIGRTMIN.
16997 (linux_resume_one_thread): Don't queue a SIGSTOP if the lwp is
16998 stopped and already has a pending signal to report.
16999 (proceed_one_lwp): : Don't queue a SIGSTOP if the lwp already has
17000 a pending signal to report or is moving out of a jump pad.
17001 (linux_init_signals): Check for __ANDROID__ rather than
17002 __SIGRTMIN.
17003
17004 2010-08-28 Pedro Alves <pedro@codesourcery.com>
17005
17006 * linux-low.c (linux_stabilize_threads): Wrap debug output in a
17007 debug_threads check. Avoid a linear search when not doing debug
17008 output.
17009
17010 2010-08-27 Pedro Alves <pedro@codesourcery.com>
17011
17012 * event-loop.c (event_handle_func): Adjust to use gdb_fildes_t.
17013 (struct gdb_event) <fd>: Change type to gdb_fildes_t.
17014 (struct file_handler) <fd>: Change type to gdb_fildes_t.
17015 (process_event): Change local fd's type to gdb_fildes_t.
17016 (create_file_handler): Adjust prototype.
17017 (delete_file_handler): Adjust prototype.
17018 (handle_file_event): Adjust prototype. Use pfildes.
17019 (create_file_event): Adjsut prototype.
17020 * remote-utils.c (remote_desc, listen_desc): Change type to
17021 gdb_fildes_t.
17022 * server.h: New gdb_fildes_t typedef.
17023 [USE_WIN32API]: Include winsock2.h.
17024 (delete_file_handler, add_file_handler): Adjust prototypes.
17025 (pfildes): Declare.
17026 * utils.c (pfildes): New.
17027
17028 2010-08-27 Pedro Alves <pedro@codesourcery.com>
17029
17030 * configure.ac (build_warnings): Add -Wno-char-subscripts.
17031 * configure: Regenerate.
17032
17033 2010-08-27 Pedro Alves <pedro@codesourcery.com>
17034
17035 * linux-low.c (linux_unprepare_to_access_memory): Rename to ...
17036 (linux_done_accessing_memory): ... this.
17037 (linux_target_ops): Adjust.
17038 * linux-x86-low.c (x86_insert_point, x86_remove_point): Adjust.
17039 * nto-low.c (nto_target_ops): Adjust comment.
17040 * server.c (gdb_read_memory, gdb_write_memory): Adjust.
17041 * spu-low.c (spu_target_ops): Adjust comment.
17042 * target.h (target_ops): Rename unprepare_to_access_memory field
17043 to done_accessing_memory.
17044 (unprepare_to_access_memory): Rename to ...
17045 (done_accessing_memory): ... this.
17046
17047 2010-08-26 Pedro Alves <pedro@codesourcery.com>
17048
17049 * linux-low.c (linux_prepare_to_access_memory): New.
17050 (linux_unprepare_to_access_memory): New.
17051 (linux_target_ops): Install them.
17052 * server.c (read_memory): Rename to ...
17053 (gdb_read_memory): ... this. Use
17054 prepare_to_access_memory/prepare_to_access_memory.
17055 (write_memory): Rename to ...
17056 (gdb_write_memory): ... this. Use
17057 prepare_to_access_memory/prepare_to_access_memory.
17058 (handle_search_memory_1): Adjust.
17059 (process_serial_event): Adjust.
17060 * target.h (struct target_ops): New fields
17061 prepare_to_access_memory and unprepare_to_access_memory.
17062 (prepare_to_access_memory, unprepare_to_access_memory): New.
17063 * linux-x86-low.c (x86_insert_point, x86_remove_point): Use
17064 prepare_to_access_memory/prepare_to_access_memory.
17065 * nto-low.c (nto_target_ops): Adjust.
17066 * spu-low.c (spu_target_ops): Adjust.
17067 * win32-low.c (win32_target_ops): Adjust.
17068
17069 2010-08-26 Pedro Alves <pedro@codesourcery.com>
17070
17071 * Makefile.in (WARN_CFLAGS): Get it from configure.
17072 (WERROR_CFLAGS): New.
17073 (INTERNAL_CFLAGS): Add WERROR_CFLAGS.
17074 * configure.ac: Introduce --enable-werror, which adds -Werror to
17075 the compiler command line. Enabled by default. Disable with
17076 --disable-werror. Add -Wdeclaration-after-statement
17077 Wpointer-arith and -Wformat-nonliteral to warning flags.
17078 * configure: Regenerate.
17079
17080 2010-08-26 Pedro Alves <pedro@codesourcery.com>
17081
17082 * mem-break.c [HAVE_MALLOC_H]: Include malloc.h.
17083
17084 2010-08-26 Pedro Alves <pedro@codesourcery.com>
17085
17086 * gdbreplay.c (remote_error): New.
17087 (gdbchar): New.
17088 (expect): Use gdbchar. Check for error reading from GDB.
17089 Clarify sync error output.
17090 (play): Check for errors writing to GDB.
17091 * linux-low.c (sigchld_handler): Really ignore `write' errors.
17092 * remote-utils.c (getpkt): Check for errors writing to the remote
17093 descriptor.
17094
17095 2010-08-25 Pedro Alves <pedro@codesourcery.com>
17096
17097 * linux-low.c (linux_wait_1): Move non-debugging code out of
17098 `debug_threads' control.
17099
17100 2010-08-25 Pedro Alves <pedro@codesourcery.com>
17101
17102 * linux-low.c (linux_wait_1): Don't set last_status here.
17103 * server.c (push_event, queue_stop_reply_callback): Assert we're
17104 not pushing a TARGET_WAITKIND_IGNORE event.
17105 (start_inferior, start_inferior, attach_inferior, handle_v_cont)
17106 (myresume, handle_target_event): Set the thread's last_resume_kind
17107 and last_status from the target returned status.
17108
17109 2010-08-25 Pedro Alves <pedro@codesourcery.com>
17110
17111 PR threads/10729
17112
17113 * linux-x86-low.c (update_debug_registers_callback): New.
17114 (i386_dr_low_set_addr): Use it.
17115 (i386_dr_low_get_addr): New.
17116 (i386_dr_low_set_control): Use update_debug_registers_callback.
17117 (i386_dr_low_get_control): New.
17118 (i386_dr_low_get_status): Adjust.
17119 * linux-low.c (linux_stop_lwp): New.
17120 * linux-low.h (linux_stop_lwp): Declare.
17121
17122 * i386-low.c (I386_DR_GET_RW_LEN): Take the dr7 contents as
17123 argument instead of a i386_debug_reg_state.
17124 (I386_DR_WATCH_HIT): Take the dr6 contents as argument instead of
17125 a i386_debug_reg_state.
17126 (i386_insert_aligned_watchpoint): Adjust.
17127 (i386_remove_aligned_watchpoint): Adjust.
17128 (i386_low_stopped_data_address): Read the debug registers from the
17129 inferior instead of from the mirrors.
17130 * i386-low.h (struct i386_debug_reg_state): Extend comment.
17131 (i386_dr_low_get_addr): Declare.
17132 (i386_dr_low_get_control): Declare.
17133 (i386_dr_low_get_status): Change prototype.
17134
17135 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): New globals.
17136 (i386_dr_low_get_addr): New.
17137 (i386_dr_low_get_control): New.
17138 (i386_dr_low_get_status): Adjust prototype. Return
17139 dr_status_mirror.
17140 (i386_initial_stuff): Clear dr_status_mirror and
17141 dr_control_mirror.
17142 (i386_get_thread_context): Adjust.
17143 (i386_set_thread_context): Adjust.
17144 (i386_thread_added): Adjust.
17145
17146 2010-08-24 Pedro Alves <pedro@codesourcery.com>
17147
17148 * linux-low.h (linux_thread_area): Delete declaration.
17149
17150 2010-08-11 Thomas Schwinge <thomas@codesourcery.com>
17151
17152 * linux-low.c (linux_wait_1): Correctly return the ptid of the child
17153 after its termination.
17154
17155 2010-08-09 Pedro Alves <pedro@codesourcery.com>
17156
17157 * linux-low.c (gdb_wants_lwp_stopped): Delete.
17158 (gdb_wants_all_stopped): Delete.
17159 (linux_wait_1): Don't call them.
17160 * server.c (handle_v_cont): Tag all threads as want-stopped.
17161 (gdb_wants_thread_stopped): Fix comments. Tag the thread that
17162 stopped as "client-wants-stopped".
17163
17164 2010-07-31 Pedro Alves <pedro@codesourcery.com>
17165
17166 * Makefile.in (signals_h): New.
17167 (server_h): Depend on it.
17168 (server.o): Don't depend on $(signals_def).
17169 (signals.o): Depend on $(signals_def).
17170
17171 2010-07-31 Jan Kratochvil <jan.kratochvil@redhat.com>
17172
17173 * Makefile.in (signals_def): New.
17174 (server_h): Append include/gdb/signals.h and signals_def.
17175 (server.o): Append signals_def.
17176
17177 2010-07-25 Jan Kratochvil <jan.kratochvil@redhat.com>
17178
17179 * server.c (handle_target_event): Use target_signal_to_host for
17180 resume_info.sig initialization.
17181 * target.h (struct thread_resume) <sig>: New comment.
17182
17183 2010-07-20 Ozkan Sezer <sezeroz@gmail.com>
17184
17185 * server.c (handle_query): strcpy() the returned string from paddress()
17186 instead of sprintf().
17187 * utils.c (paddress): Return phex_nz().
17188
17189 2010-07-07 Joel Brobecker <brobecker@adacore.com>
17190
17191 * server.c (handle_v_cont): Call mourn_inferior if process
17192 just exited.
17193 (myresume): Likewise.
17194
17195 2010-07-01 Pedro Alves <pedro@codesourcery.com>
17196
17197 Static tracepoints, and integration with UST.
17198
17199 * configure.ac: Handle --with-ust. substitute ustlibs and ustinc.
17200 * mem-break.c (uninsert_all_breakpoints)
17201 (reinsert_all_breakpoints): New.
17202 * mem-break.h (reinsert_all_breakpoints, uninsert_all_breakpoints):
17203 * tracepoint.c (ust_loaded, helper_thread_id, cmd_buf): New.
17204 (gdb_agent_ust_loaded, helper_thread_id)
17205 (gdb_agent_helper_thread_id): New macros.
17206 (struct ipa_sym_addresses): Add addr_ust_loaded,
17207 addr_helper_thread_id, addr_cmd_buf.
17208 (symbol_list): Add ust_loaded, helper_thread_id, cmd_buf.
17209 (in_process_agent_loaded_ust): New.
17210 (write_e_ust_not_loaded): New.
17211 (maybe_write_ipa_ust_not_loaded): New.
17212 (struct collect_static_trace_data_action): New.
17213 (enum tracepoint_type) <static_tracepoint>: New.
17214 (struct tracepoint) <handle>: Mention static tracepoints.
17215 (struct static_tracepoint_ctx): New.
17216 (CMD_BUF_SIZE): New.
17217 (add_tracepoint_action): Handle static tracepoint actions.
17218 (unprobe_marker_at): New.
17219 (clear_installed_tracepoints): Handle static tracepoints.
17220 (cmd_qtdp): Handle static tracepoints.
17221 (probe_marker_at): New.
17222 (cmd_qtstart): Handle static tracepoints.
17223 (response_tracepoint): Handle static tracepoints.
17224 (cmd_qtfstm, cmd_qtsstm, cmd_qtstmat): New.
17225 (handle_tracepoint_query): Handle qTfSTM, qTsSTM and qTSTMat.
17226 (get_context_regcache): Handle static tracepoints.
17227 (do_action_at_tracepoint): Handle static tracepoint actions.
17228 (traceframe_find_block_type): Handle static trace data blocks.
17229 (traceframe_read_sdata): New.
17230 (download_tracepoints): Download static tracepoint actions.
17231 [HAVE_UST] Include ust/ust.h, dlfcn.h, sys/socket.h, and sys/un.h.
17232 (GDB_PROBE_NAME): New.
17233 (ust_ops): New.
17234 (GET_UST_SYM): New.
17235 (USTF): New.
17236 (dlsym_ust): New.
17237 (ust_marker_to_static_tracepoint): New.
17238 (gdb_probe): New.
17239 (collect_ust_data_at_tracepoint): New.
17240 (gdb_ust_probe): New.
17241 (UNIX_PATH_MAX, SOCK_DIR): New.
17242 (gdb_ust_connect_sync_socket): New.
17243 (resume_thread, stop_thread): New.
17244 (run_inferior_command): New.
17245 (init_named_socket): New.
17246 (gdb_ust_socket_init): New.
17247 (cstr_to_hexstr): New.
17248 (next_st): New.
17249 (first_marker, next_marker): New.
17250 (response_ust_marker): New.
17251 (cmd_qtfstm, cmd_qtsstm): New.
17252 (unprobe_marker_at, probe_marker_at): New.
17253 (cmd_qtstmat, gdb_ust_thread): New.
17254 (gdb_ust_init): New.
17255 (initialize_tracepoint_ftlib): Call gdb_ust_init.
17256 * linux-amd64-ipa.c [HAVE_UST]: Include ust/processor.h
17257 (ST_REGENTRY): New.
17258 (x86_64_st_collect_regmap): New.
17259 (X86_64_NUM_ST_COLLECT_GREGS): New.
17260 (AMD64_RIP_REGNUM): New.
17261 (supply_static_tracepoint_registers): New.
17262 * linux-i386-ipa.c [HAVE_UST]: Include ust/processor.h
17263 (ST_REGENTRY): New.
17264 (i386_st_collect_regmap): New.
17265 (i386_NUM_ST_COLLECT_GREGS): New.
17266 (supply_static_tracepoint_registers): New.
17267 * server.c (handle_query): Handle qXfer:statictrace:read.
17268 <qSupported>: Report support for StaticTracepoints, and
17269 qXfer:statictrace:read features.
17270 * server.h (traceframe_read_sdata)
17271 (supply_static_tracepoint_registers): Declare.
17272 * remote-utils.c (convert_int_to_ascii, hexchars, ishex, tohex)
17273 (unpack_varlen_hex): Include in IPA build.
17274 * Makefile.in (ustlibs, ustinc): New.
17275 (IPA_OBJS): Add remote-utils-ipa.o.
17276 ($(IPA_LIB)): Link -ldl and -lpthread.
17277 (UST_CFLAGS): New.
17278 (IPAGENT_CFLAGS): Add UST_CFLAGS.
17279 * config.in, configure: Regenerate.
17280
17281 2010-06-20 Ian Lance Taylor <iant@google.com>
17282 Pedro Alves <pedro@codesourcery.com>
17283
17284 * linux-x86-low.c (always_true): Delete.
17285 (EMIT_ASM, EMIT_ASM32): Use an uncondition asm jmp instead of
17286 trying to fool the compiler with always_true.
17287
17288 2010-06-20 Pedro Alves <pedro@codesourcery.com>
17289
17290 * tracepoint.c (condition_true_at_tracepoint): Don't run compiled
17291 conditions in gdbserver.
17292
17293 2010-06-19 Ulrich Weigand <uweigand@de.ibm.com>
17294
17295 * spu-low.c (spu_read_memory): Wrap around local store limit.
17296 (spu_write_memory): Likewise.
17297
17298 2010-06-15 Pedro Alves <pedro@codesourcery.com>
17299
17300 * linux-x86-low.c (amd64_emit_const, amd64_emit_void_call_2)
17301 (i386_emit_const, i386_emit_void_call_2): Replace int64_t uses with
17302 LONGEST uses.
17303 * server.h (struct emit_ops): Replace int64_t uses with LONGEST
17304 uses.
17305 * tracepoint.c (emit_const, emit_void_call_2): Replace int64_t
17306 uses with LONGEST uses.
17307
17308 2010-06-14 Stan Shebs <stan@codesourcery.com>
17309 Pedro Alves <pedro@codesourcery.com>
17310
17311 Bytecode compiler.
17312
17313 * linux-x86-low.c: Include limits.h.
17314 (add_insns): New.
17315 (always_true): New.
17316 (EMIT_ASM): New.
17317 (EMIT_ASM32): New.
17318 (amd64_emit_prologue, amd64_emit_epilogue, amd64_emit_add)
17319 (amd64_emit_sub, amd64_emit_mul, amd64_emit_lsh)
17320 (amd64_emit_rsh_signed, amd64_emit_rsh_unsigned, amd64_emit_ext,
17321 (amd64_emit_log_not, amd64_emit_bit_and, amd64_emit_bit_or)
17322 (amd64_emit_bit_xor, amd64_emit_bit_not, amd64_emit_equal,
17323 (amd64_emit_less_signed, amd64_emit_less_unsigned, amd64_emit_ref,
17324 (amd64_emit_if_goto, amd64_emit_goto, amd64_write_goto_address)
17325 (amd64_emit_const, amd64_emit_call, amd64_emit_reg)
17326 (amd64_emit_pop, amd64_emit_stack_flush, amd64_emit_zero_ext)
17327 (amd64_emit_swap, amd64_emit_stack_adjust, amd64_emit_int_call_1)
17328 (amd64_emit_void_call_2): New.
17329 (amd64_emit_ops): New.
17330 (i386_emit_prologue, i386_emit_epilogue, i386_emit_add)
17331 (i386_emit_sub,i386_emit_mul, i386_emit_lsh, i386_emit_rsh_signed)
17332 (i386_emit_rsh_unsigned, i386_emit_ext, i386_emit_log_not)
17333 (i386_emit_bit_and, i386_emit_bit_or, i386_emit_bit_xor)
17334 (i386_emit_bit_not, i386_emit_equal, i386_emit_less_signed)
17335 (i386_emit_less_unsigned, i386_emit_ref, i386_emit_if_goto)
17336 (i386_emit_goto, i386_write_goto_address, i386_emit_const)
17337 (i386_emit_call, i386_emit_reg, i386_emit_pop)
17338 (i386_emit_stack_flush, i386_emit_zero_ext, i386_emit_swap)
17339 (i386_emit_stack_adjust, i386_emit_int_call_1)
17340 (i386_emit_void_call_2): New.
17341 (i386_emit_ops): New.
17342 (x86_emit_ops): New.
17343 (the_low_target): Install x86_emit_ops.
17344 * server.h (struct emit_ops): New.
17345 (get_raw_reg_func_addr): Declare.
17346 (current_insn_ptr, emit_error): Declare.
17347 * tracepoint.c (get_raw_reg, get_trace_state_variable_value)
17348 (set_trace_state_variable_value): New defines.
17349 (struct ipa_sym_addresses): New fields addr_get_raw_reg,
17350 addr_get_trace_state_variable_value and
17351 addr_set_trace_state_variable_value.
17352 (symbol_list): New fields for get_raw_reg,
17353 get_trace_state_variable_value and set_trace_state_variable_value.
17354 (condfn): New typedef.
17355 (struct tracepoint): New field `compiled_cond'.
17356 (do_action_at_tracepoint): Clear compiled_cond.
17357 (get_trace_state_variable_value, set_trace_state_variable_value):
17358 Export in the IPA.
17359 (condition_true_at_tracepoint): If there's a compiled condition,
17360 run that.
17361 (current_insn_ptr, emit_error): New globals.
17362 (struct bytecode_address): New.
17363 (get_raw_reg_func_addr): New.
17364 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul)
17365 (emit_lsh, emit_rsh_signed, emit_rsh_unsigned, emit_ext)
17366 (emit_log_not, emit_bit_and, emit_bit_or, emit_bit_xor)
17367 (emit_bit_not, emit_equal, emit_less_signed, emit_less_unsigned)
17368 (emit_ref, emit_if_goto, emit_goto, write_goto_address, emit_const)
17369 (emit_reg, emit_pop, emit_stack_flush, emit_zero_ext, emit_swap)
17370 (emit_stack_adjust, emit_int_call_1, emit_void_call_2): New.
17371 (compile_tracepoint_condition, compile_bytecodes): New.
17372 * target.h (emit_ops): Forward declare.
17373 (struct target_ops): New field emit_ops.
17374 (target_emit_ops): New.
17375 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): New.
17376 * linux-i386-ipa.c (gdb_agent_get_raw_reg): New.
17377 * linux-low.c (linux_emit_ops): New.
17378 (linux_target_ops): Install it.
17379 * linux-low.h (struct linux_target_ops): New field emit_ops.
17380
17381 2010-06-14 Ulrich Weigand <uweigand@de.ibm.com>
17382
17383 * linux-ppc-low.c (ppc_arch_setup): Use private regcache to test MSR.
17384 * linux-s390-low.c (ppc_arch_setup): Use private regcache to test PSW.
17385
17386 2010-06-01 Pedro Alves <pedro@codesourcery.com>
17387 Stan Shebs <stan@codesourcery.com>
17388
17389 * Makefile.in (IPA_DEPFILES, extra_libraries): New.
17390 (all): Depend on $(extra_libraries).
17391 (install-only): Install the IPA.
17392 (IPA_OBJS, IPA_LIB): New.
17393 (clean): Remove the IPA lib.
17394 (IPAGENT_CFLAGS): New.
17395 (tracepoint-ipa.o, utils-ipa.o, remote-utils-ipa.o)
17396 (regcache-ipa.o, i386-linux-ipa.o, linux-i386-ipa.o)
17397 (linux-amd64-ipa.o, amd64-linux-ipa.o): New rules.
17398 * linux-amd64-ipa.c, linux-i386-ipa.c: New files.
17399 * configure.ac: Check for atomic builtins support in the compiler.
17400 (IPA_DEPFILES, extra_libraries): Define.
17401 * configure.srv (ipa_obj): Add description.
17402 (ipa_i386_linux_regobj, ipa_amd64_linux_regobj): Define.
17403 (i[34567]86-*-linux*): Set ipa_obj.
17404 (x86_64-*-linux*): Set ipa_obj.
17405 * linux-low.c (stabilizing_threads): New.
17406 (supports_fast_tracepoints): New.
17407 (linux_detach): Stabilize threads before detaching.
17408 (handle_tracepoints): Handle internal tracing breakpoints. Assert
17409 the lwp is either not stabilizing, or is moving out of a jump pad.
17410 (linux_fast_tracepoint_collecting): New.
17411 (maybe_move_out_of_jump_pad): New.
17412 (enqueue_one_deferred_signal): New.
17413 (dequeue_one_deferred_signal): New.
17414 (linux_wait_for_event_1): If moving out of a jump pad, defer
17415 pending signals to later.
17416 (linux_stabilize_threads): New.
17417 (linux_wait_1): Check if threads need moving out of jump pads, and
17418 do it if so.
17419 (stuck_in_jump_pad_callback): New.
17420 (move_out_of_jump_pad_callback): New.
17421 (lwp_running): New.
17422 (linux_resume_one_lwp): Handle moving out of jump pads.
17423 (linux_set_resume_request): Dequeue deferred signals.
17424 (need_step_over_p): Also step over fast tracepoint jumps.
17425 (start_step_over): Also uninsert fast tracepoint jumps.
17426 (finish_step_over): Also reinsert fast tracepoint jumps.
17427 (linux_install_fast_tracepoint_jump): New.
17428 (linux_target_ops): Install linux_stabilize_threads and
17429 linux_install_fast_tracepoint_jump_pad.
17430 * linux-low.h (linux_target_ops) <get_thread_area,
17431 install_fast_tracepoint_jump_pad>: New fields.
17432 (struct lwp_info) <collecting_fast_tracepoint,
17433 pending_signals_to_report, exit_jump_pad_bkpt>: New fields.
17434 (linux_get_thread_area): Declare.
17435 * linux-x86-low.c (jump_insn): New.
17436 (x86_get_thread_area): New.
17437 (append_insns): New.
17438 (push_opcode): New.
17439 (amd64_install_fast_tracepoint_jump_pad): New.
17440 (i386_install_fast_tracepoint_jump_pad): New.
17441 (x86_install_fast_tracepoint_jump_pad): New.
17442 (the_low_target): Install x86_get_thread_area and
17443 x86_install_fast_tracepoint_jump_pad.
17444 * mem-break.c (set_raw_breakpoint_at): Use read_inferior_memory.
17445 (struct fast_tracepoint_jump): New.
17446 (fast_tracepoint_jump_insn): New.
17447 (fast_tracepoint_jump_shadow): New.
17448 (find_fast_tracepoint_jump_at): New.
17449 (fast_tracepoint_jump_here): New.
17450 (delete_fast_tracepoint_jump): New.
17451 (set_fast_tracepoint_jump): New.
17452 (uninsert_fast_tracepoint_jumps_at): New.
17453 (reinsert_fast_tracepoint_jumps_at): New.
17454 (set_breakpoint_at): Use write_inferior_memory.
17455 (uninsert_raw_breakpoint): Use write_inferior_memory.
17456 (check_mem_read): Mask out fast tracepoint jumps.
17457 (check_mem_write): Mask out fast tracepoint jumps.
17458 * mem-break.h (struct fast_tracepoint_jump): Forward declare.
17459 (set_fast_tracepoint_jump): Declare.
17460 (delete_fast_tracepoint_jump)
17461 (fast_tracepoint_jump_here, uninsert_fast_tracepoint_jumps_at)
17462 (reinsert_fast_tracepoint_jumps_at): Declare.
17463 * regcache.c: Don't compile many functions when building the
17464 in-process agent library.
17465 (init_register_cache) [IN_PROCESS_AGENT]: Don't allow allocating
17466 the register buffer in the heap.
17467 (free_register_cache): If the register buffer isn't owned by the
17468 regcache, don't free it.
17469 (set_register_cache) [IN_PROCESS_AGENT]: Don't re-alocate
17470 pre-existing register caches.
17471 * remote-utils.c (convert_int_to_ascii): Constify `from' parameter
17472 type.
17473 (convert_ascii_to_int): : Constify `from' parameter type.
17474 (decode_M_packet, decode_X_packet): Replace the `to' parameter by
17475 a `to_p' pointer to pointer parameter. If TO_P is NULL, malloc
17476 the needed buffer in-place.
17477 (relocate_instruction): New.
17478 * server.c (handle_query) <qSymbols>: If the target supports
17479 tracepoints, give it a chance of looking up symbols. Report
17480 support for fast tracepoints.
17481 (handle_status): Stabilize threads.
17482 (process_serial_event): Adjust.
17483 * server.h (struct fast_tracepoint_jump): Forward declare.
17484 (struct process_info) <fast_tracepoint_jumps>: New field.
17485 (convert_ascii_to_int, convert_int_to_ascii): Adjust.
17486 (decode_X_packet, decode_M_packet): Adjust.
17487 (relocate_instruction): Declare.
17488 (in_process_agent_loaded): Declare.
17489 (tracepoint_look_up_symbols): Declare.
17490 (struct fast_tpoint_collect_status): Declare.
17491 (fast_tracepoint_collecting): Declare.
17492 (force_unlock_trace_buffer): Declare.
17493 (handle_tracepoint_bkpts): Declare.
17494 (initialize_low_tracepoint)
17495 (supply_fast_tracepoint_registers) [IN_PROCESS_AGENT]: Declare.
17496 * target.h (struct target_ops) <stabilize_threads,
17497 install_fast_tracepoint_jump_pad>: New fields.
17498 (stabilize_threads, install_fast_tracepoint_jump_pad): New.
17499 * tracepoint.c [HAVE_MALLOC_H]: Include malloc.h.
17500 [HAVE_STDINT_H]: Include stdint.h.
17501 (trace_debug_1): Rename to ...
17502 (trace_vdebug): ... this.
17503 (trace_debug): Rename to ...
17504 (trace_debug_1): ... this. Add `level' parameter.
17505 (trace_debug): New.
17506 (ATTR_USED, ATTR_NOINLINE): New.
17507 (IP_AGENT_EXPORT): New.
17508 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
17509 (collecting, gdb_collect, stop_tracing, flush_trace_buffer)
17510 (about_to_request_buffer_space, trace_buffer_is_full)
17511 (stopping_tracepoint, expr_eval_result, error_tracepoint)
17512 (tracepoints, tracing, trace_buffer_ctrl, trace_buffer_ctrl_curr)
17513 (trace_buffer_lo, trace_buffer_hi, traceframe_read_count)
17514 (traceframe_write_count, traceframes_created)
17515 (trace_state_variables)
17516 New renaming defines.
17517 (struct ipa_sym_addresses): New.
17518 (STRINGIZE_1, STRINGIZE, IPA_SYM): New.
17519 (symbol_list): New.
17520 (ipa_sym_addrs): New.
17521 (all_tracepoint_symbols_looked_up): New.
17522 (in_process_agent_loaded): New.
17523 (write_e_ipa_not_loaded): New.
17524 (maybe_write_ipa_not_loaded): New.
17525 (tracepoint_look_up_symbols): New.
17526 (debug_threads) [IN_PROCESS_AGENT]: New.
17527 (read_inferior_memory) [IN_PROCESS_AGENT]: New.
17528 (UNKNOWN_SIDE_EFFECTS): New.
17529 (stop_tracing): New.
17530 (flush_trace_buffer): New.
17531 (stop_tracing_bkpt): New.
17532 (flush_trace_buffer_bkpt): New.
17533 (read_inferior_integer): New.
17534 (read_inferior_uinteger): New.
17535 (read_inferior_data_pointer): New.
17536 (write_inferior_data_pointer): New.
17537 (write_inferior_integer): New.
17538 (write_inferior_uinteger): New.
17539 (struct collect_static_trace_data_action): Delete.
17540 (enum tracepoint_type): New.
17541 (struct tracepoint) <type>: New field `type'.
17542 <actions_str, step_actions, step_actions_str>: Only include in
17543 GDBserver.
17544 <orig_size, obj_addr_on_target, adjusted_insn_addr>
17545 <adjusted_insn_addr_end, jump_pad, jump_pad_end>: New fields.
17546 (tracepoints): Use IP_AGENT_EXPORT.
17547 (last_tracepoint): Don't include in the IPA.
17548 (stopping_tracepoint): Use IP_AGENT_EXPORT.
17549 (trace_buffer_is_full): Use IP_AGENT_EXPORT.
17550 (alloced_trace_state_variables): New.
17551 (trace_state_variables): Use IP_AGENT_EXPORT.
17552 (traceframe_t): Delete unused variable.
17553 (circular_trace_buffer): Don't include in the IPA.
17554 (trace_buffer_start): Delete.
17555 (struct trace_buffer_control): New.
17556 (trace_buffer_free): Delete.
17557 (struct ipa_trace_buffer_control): New.
17558 (GDBSERVER_FLUSH_COUNT_MASK, GDBSERVER_FLUSH_COUNT_MASK_PREV)
17559 (GDBSERVER_FLUSH_COUNT_MASK_CURR, GDBSERVER_UPDATED_FLUSH_COUNT_BIT):
17560 New.
17561 (trace_buffer_ctrl): New.
17562 (TRACE_BUFFER_CTRL_CURR): New.
17563 (trace_buffer_start, trace_buffer_free, trace_buffer_end_free):
17564 Reimplement as macros.
17565 (trace_buffer_wrap): Delete.
17566 (traceframe_write_count, traceframe_read_count)
17567 (traceframes_created, tracing): Use IP_AGENT_EXPORT.
17568 (struct tracepoint_hit_ctx) <type>: New field.
17569 (struct fast_tracepoint_ctx): New.
17570 (memory_barrier): New.
17571 (cmpxchg): New.
17572 (record_tracepoint_error): Update atomically in the IPA.
17573 (clear_inferior_trace_buffer): New.
17574 (about_to_request_buffer_space): New.
17575 (trace_buffer_alloc): Handle GDBserver and inferior simulatenous
17576 updating the same buffer.
17577 (add_tracepoint): Default the tracepoint's type to trap
17578 tracepoint, and orig_size to -1.
17579 (get_trace_state_variable) [IN_PROCESS_AGENT]: Handle allocated
17580 internal variables.
17581 (create_trace_state_variable): New parameter `gdb'. Handle it.
17582 (clear_installed_tracepoints): Clear fast tracepoint jumps.
17583 (cmd_qtdp): Handle fast tracepoints.
17584 (cmd_qtdv): Adjust.
17585 (max_jump_pad_size): New.
17586 (gdb_jump_pad_head): New.
17587 (get_jump_space_head): New.
17588 (claim_jump_space): New.
17589 (sort_tracepoints): New.
17590 (MAX_JUMP_SIZE): New.
17591 (cmd_qtstart): Handle fast tracepoints. Sync tracepoints with the
17592 IPA.
17593 (stop_tracing) [IN_PROCESS_AGENT]: Don't include the tdisconnected
17594 support. Upload fast traceframes, and delete internal IPA
17595 breakpoints.
17596 (stop_tracing_handler): New.
17597 (flush_trace_buffer_handler): New.
17598 (cmd_qtstop): Upload fast tracepoints.
17599 (response_tracepoint): Handle fast tracepoints.
17600 (tracepoint_finished_step): Upload fast traceframes. Set the
17601 tracepoint hit context's tracepoint type.
17602 (handle_tracepoint_bkpts): New.
17603 (tracepoint_was_hit): Set the tracepoint hit context's tracepoint
17604 type. Add comment about fast tracepoints.
17605 (collect_data_at_tracepoint) [IN_PROCESS_AGENT]: Don't access the
17606 non-existing action_str field.
17607 (get_context_regcache): Handle fast tracepoints.
17608 (do_action_at_tracepoint) [!IN_PROCESS_AGENT]: Don't write the PC
17609 to the regcache.
17610 (fast_tracepoint_from_jump_pad_address): New.
17611 (fast_tracepoint_from_ipa_tpoint_address): New.
17612 (collecting_t): New.
17613 (force_unlock_trace_buffer): New.
17614 (fast_tracepoint_collecting): New.
17615 (collecting): New.
17616 (gdb_collect): New.
17617 (write_inferior_data_ptr): New.
17618 (target_tp_heap): New.
17619 (target_malloc): New.
17620 (download_agent_expr): New.
17621 (UALIGN): New.
17622 (download_tracepoints): New.
17623 (download_trace_state_variables): New.
17624 (upload_fast_traceframes): New.
17625 (IPA_FIRST_TRACEFRAME): New.
17626 (IPA_NEXT_TRACEFRAME_1): New.
17627 (IPA_NEXT_TRACEFRAME): New.
17628 [IN_PROCESS_AGENT]: Include sys/mman.h and fcntl.h.
17629 [IN_PROCESS_AGENT] (gdb_tp_heap_buffer, gdb_jump_pad_buffer)
17630 (gdb_jump_pad_buffer_end): New.
17631 [IN_PROCESS_AGENT] (initialize_tracepoint_ftlib): New.
17632 (initialize_tracepoint): Adjust.
17633 [IN_PROCESS_AGENT]: Allocate the IPA heap, and jump pad scratch
17634 buffer. Initialize the low module.
17635 * utils.c (PREFIX, TOOLNAME): New.
17636 (malloc_failure): Use PREFIX.
17637 (error): In the IPA, an error causes an exit.
17638 (fatal, warning): Use PREFIX.
17639 (internal_error): Use TOOLNAME.
17640 (NUMCELLS): Increase to 10.
17641 * configure, config.in: Regenerate.
17642
17643 2010-06-01 Pedro Alves <pedro@codesourcery.com>
17644
17645 * server.c (handle_query) <qSupported>: Do two passes over the
17646 qSupported string to avoid nesting strtok.
17647
17648 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
17649
17650 * Makefile.in (SFILES): Add $(srcdir)/proc-service.list.
17651 (CDEPS): New.
17652 * configure.ac (RDYNAMIC): New AC_MSG_CHECKING wrapping. Test also
17653 -Wl,--dynamic-list.
17654 * configure: Regenerate.
17655 * proc-service.list: New.
17656
17657 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
17658
17659 * linux-low.c (linux_core_of_thread): Fix crash on invalid CONTENT.
17660 New comment.
17661
17662 2010-05-26 Ozkan Sezer <sezeroz@gmail.com>
17663
17664 * gdbreplay.c (remote_open): Check error return from socket() call by
17665 its equality to -1 not by it being negative.
17666 * remote-utils.c (remote_open): Likewise.
17667
17668 2010-05-23 Pedro Alves <pedro@codesourcery.com>
17669
17670 * config.h: Regenerate.
17671
17672 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
17673
17674 * linux-m68k-low.c (ps_get_thread_area): Don't define if kernel
17675 doesn't provide PTRACE_GET_THREAD_AREA.
17676
17677 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
17678
17679 * linux-m68k-low.c: Include <asm/ptrace.h>
17680 (ps_get_thread_area): Implement.
17681
17682 2010-05-03 Doug Evans <dje@google.com>
17683
17684 * event-loop.c (struct callback_event): New struct.
17685 (callback_list): New global.
17686 (append_callback_event, delete_callback_event): New functions.
17687 (process_callback): New function.
17688 (start_event_loop): Call it.
17689 * remote-utils.c (NOT_SCHEDULED): Define.
17690 (readchar_buf, readchar_bufcnt, readchar_bufp): New static globals,
17691 moved out of readchar.
17692 (readchar): Rewrite. Call reschedule before returning.
17693 (reset_readchar): New function.
17694 (remote_close): Call it.
17695 (process_remaining, reschedule): New functions.
17696 * server.h (callback_handler_func): New typedef.
17697 (append_callback_event, delete_callback_event): Declare.
17698
17699 2010-05-03 Pedro Alves <pedro@codesourcery.com>
17700
17701 * proc-service.c (ps_pglobal_lookup): Use
17702 thread_db_look_up_one_symbol.
17703 * remote-utils.c (look_up_one_symbol): Add new `may_ask_gdb'
17704 parameter. Use it instead of all_symbols_looked_up.
17705 * server.h (struct process_info) <all_symbols_looked_up>: Delete
17706 field.
17707 (all_symbols_looked_up): Don't declare.
17708 (look_up_one_symbol): Add new `may_ask_gdb' parameter.
17709 * thread-db.c (struct thread_db) <all_symbols_looked_up>: New
17710 field.
17711 (thread_db_look_up_symbols): Adjust call to look_up_one_symbol.
17712 Set all_symbols_looked_up here.
17713 (thread_db_look_up_one_symbol): New.
17714 (thread_db_get_tls_address): Adjust.
17715 (thread_db_load_search, try_thread_db_load_1): Always allocate the
17716 thread_db object on the heap, and tentatively set it in the
17717 process structure.
17718 (thread_db_init): Don't set all_symbols_looked_up here.
17719 * linux-low.h (thread_db_look_up_one_symbol): Declare.
17720
17721 2010-05-03 Pedro Alves <pedro@codesourcery.com>
17722
17723 * linux-low.c (linux_kill, linux_detach): Adjust.
17724 (status_pending_p_callback): Remove redundant statement. Check
17725 for !TARGET_WAITIKIND_IGNORE, instead of
17726 TARGET_WAITKIND_STOPPED.
17727 (handle_tracepoints): Make sure LWP is locked. Adjust.
17728 (linux_wait_for_event_1): Adjust.
17729 (linux_cancel_breakpoints): New.
17730 (unsuspend_one_lwp): New.
17731 (unsuspend_all_lwps): New.
17732 (linux_wait_1): If finishing a step-over, unsuspend all lwps.
17733 (send_sigstop_callback): Change return type to int, add new
17734 `except' parameter and handle it.
17735 (suspend_and_send_sigstop_callback): New.
17736 (stop_all_lwps): Add new `suspend' and `expect' parameters, and
17737 pass them down. If SUSPEND, also increment the lwp's suspend
17738 count.
17739 (linux_resume_one_lwp): Add notice about resuming a suspended LWP.
17740 (need_step_over_p): Don't consider suspended LWPs.
17741 (start_step_over): Adjust.
17742 (proceed_one_lwp): Change return type to int, add new `except'
17743 parameter and handle it.
17744 (unsuspend_and_proceed_one_lwp): New.
17745 (proceed_all_lwps): Use find_inferior instead of
17746 for_each_inferior.
17747 (unstop_all_lwps): Add `unsuspend' parameter. If UNSUSPEND, them
17748 also decrement the suspend count of LWPs. Pass `except' down,
17749 instead of hacking its suspend count.
17750 (linux_pause_all): Add `freeze' parameter. Adjust.
17751 (linux_unpause_all): New.
17752 (linux_target_ops): Install linux_unpause_all.
17753 * server.c (handle_status): Adjust.
17754 * target.h (struct target_ops): New fields `unpause_all' and
17755 `cancel_breakpoints'. Add new parameter to `pause_all'.
17756 (pause_all): Add new `freeze' parameter.
17757 (unpause_all): New.
17758 (cancel_breakpoints): New.
17759 * tracepoint.c (clear_installed_tracepoints): Pause threads, and
17760 cancel breakpoints.
17761 (cmd_qtstart): Pause threads.
17762 (stop_tracing): Pause threads, and cancel breakpoints.
17763 * win32-low.c (win32_target_ops): Adjust.
17764
17765 2010-05-03 Pedro Alves <pedro@codesourcery.com>
17766
17767 * linux-low.c (linux_wait_for_event_1): Move passing the signal to
17768 the inferior right away from here...
17769 (linux_wait_1): ... to here, and adjust to check the thread's
17770 last_resume_kind instead of the lwp's step or stop_expected flags.
17771
17772 2010-05-02 Pedro Alves <pedro@codesourcery.com>
17773
17774 * README: Use consistent `GDB' and `GDBserver' spellings.
17775
17776 2010-05-02 Pedro Alves <pedro@codesourcery.com>
17777
17778 * linux-low.c (linux_kill_one_lwp): Assume the lwp is stopped.
17779 (linux_kill): Stop all lwps here. Don't delete the main lwp here.
17780 (linux_detach_one_lwp): Assume the lwp is stopped.
17781 (any_thread_of): Delete.
17782 (linux_detach): Stop all lwps here. Don't blindly delete all
17783 breakpoints.
17784 (delete_lwp_callback): New.
17785 (linux_mourn): Delete all lwps of the process that is gone.
17786 (linux_wait_1): Don't delete the last lwp of the process here.
17787 * mem-break.h (mark_breakpoints_out): Declare.
17788 * mem-break.c (mark_breakpoints_out): New.
17789 (free_all_breakpoints): Use it.
17790 * server.c (handle_target_event): If the process is gone, mark
17791 breakpoints out.
17792 * thread-db.c (struct thread_db) <create_bp>: New field.
17793 (thread_db_enable_reporting): Fix prototype. Store a thread event
17794 breakpoint reference in the thread_db struct.
17795 (thread_db_load_search): Clear the thread_db object.
17796 (try_thread_db_load_1): Ditto.
17797 (switch_to_process): New.
17798 (disable_thread_event_reporting): Use it.
17799 (remove_thread_event_breakpoints): New.
17800 (thread_db_detach, thread_db_mourn): Use it.
17801
17802 2010-05-01 Pedro Alves <pedro@codesourcery.com>
17803
17804 * linux-low.c (linux_enable_event_reporting): New.
17805 (linux_wait_for_event_1, handle_extended_wait): Use it.
17806
17807 2010-04-30 Pedro Alves <pedro@codesourcery.com>
17808
17809 * linux-low.c (linux_kill_one_lwp, linux_kill)
17810 (linux_detach_one_lwp): Adjust to send_sigstop interface change.
17811 (send_sigstop): Take an lwp_info as parameter instead. Queue a
17812 SIGSTOP even if the LWP is stopped.
17813 (send_sigstop_callback): New.
17814 (stop_all_lwps): Use send_sigstop_callback instead.
17815 (linux_resume_one_thread): Adjust.
17816 (proceed_one_lwp): Still proceed an LWP that the client has
17817 requested to stop, if we haven't reported it as stopped yet. Make
17818 sure that LWPs the client want stopped, have a pending SIGSTOP.
17819
17820 2010-04-26 Doug Evans <dje@google.com>
17821
17822 * server.c (handle_general_set): Make static.
17823
17824 * remote-utils.c (putpkt_binary_1): Call readchar instead of read.
17825 Print received char after testing for error/eof instead of before.
17826 (input_interrupt): Tweak comment.
17827
17828 2010-04-23 Doug Evans <dje@google.com>
17829
17830 * server.c (start_inferior): Print inferior argv if --debug.
17831
17832 2010-04-21 Aleksandar Ristovski <aristovski@qnx.com>
17833
17834 * Makefile.in (nto_low_h nto-low.o nto-x86-low.o): New dependency lists.
17835 * nto-x86-low.c: Include server.h
17836
17837 2010-04-20 Pierre Muller <muller@ics.u-strasbg.fr>
17838
17839 * win32-i386-low.c: Use __x86_64__ macro instead of __x86_64 to
17840 be consistent with other sources of this directory.
17841 (init_registers_amd64): Correct name of source file of this function
17842 in the comment.
17843
17844 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
17845
17846 * configure.srv (x86_64-*-mingw*): New configuration for Windows
17847 64-bit executables.
17848
17849 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
17850
17851 * win32-i386-low.c: Add 64-bit support.
17852 (CONTEXT_EXTENDED_REGISTERS): Set macro to zero if not exisiting.
17853 (init_registers_amd64): Declare.
17854 (mappings): Add 64-bit version of array.
17855 (init_windows_x86): New function.
17856 (the_low_target): Change init_arch field to init_windows_x86.
17857
17858 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
17859
17860 * win32-low.c: Adapt to support also 64-bit architecture.
17861 (child_xfer_memory): Use uintptr_t type for local variable `addr'.
17862 (get_image_name): Use SIZE_T type for local variable `done'.
17863 (psapi_get_dll_name): Use LPVOID type for parameter `BaseAddress'.
17864 (toolhelp_get_dll_name): Idem.
17865 (handle_load_dll): Use CORE_ADDR type for local variable `load_addr'.
17866 Use uintptr_t typecast to avoid warning.
17867 (handle_unload_dll): Use uintptr_t typecast to avoid warning.
17868 (handle_exception): Use phex_nz to avoid warning.
17869 (win32_wait): Remove unused local variable `process'.
17870
17871 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
17872
17873 * configure.srv (srv_amd64_regobj): Replace `x86-64-avx.o' by
17874 `amd64-avx.o'.
17875
17876 2010-04-17 Pierre Muller <muller@ics.u-strasbg.fr>
17877
17878 * configure.ac: Use `ws2_32' library for srv_mingw.
17879 * configure: Regenerate.
17880 * gdbreplay.c: Include winsock2.h instead of winsock.h.
17881 * remote-utils.c: Likewise.
17882
17883 2010-04-17 H.J. Lu <hongjiu.lu@intel.com>
17884
17885 * linux-x86-low.c (xmltarget_amd64_linux_no_xml): Define only
17886 if __x86_64__ is defined.
17887
17888 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
17889
17890 * configure: Regenerate.
17891
17892 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
17893
17894 * server.c (handle_query): Handle 'qGetTIBAddr' query.
17895 * target.h (target_ops): New get_tib_address field.
17896 * win32-low.h (win32_thread_info): Add thread_local_base field.
17897 * win32-low.c (child_add_thread): Add tlb argument.
17898 Set thread_local_base field to TLB.
17899 (get_child_debug_event): Adapt to child_add_thread change.
17900 (win32_get_tib_address): New function.
17901 (win32_target_ops): Set get_tib_address field to
17902 win32_get_tib_address.
17903 * linux-low.c (linux_target_ops): Set get_tib_address field to NULL.
17904
17905 2010-04-12 Pedro Alves <pedro@codesourcery.com>
17906
17907 * linux-low.c (linux_mourn): Also remove the process.
17908 * server.c (handle_target_event): Don't remove the process here.
17909 * nto-low.c (nto_mourn): New.
17910 (nto_target_ops): Install it.
17911 * spu-low.c (spu_mourn): New.
17912 (spu_target_ops): Install it.
17913 * win32-low.c (win32_mourn): New.
17914 (win32_target_ops): Install it.
17915
17916 2010-04-12 Pedro Alves <pedro@codesourcery.com>
17917
17918 * server.h (buffer_xml_printf): Remove redundant `;'.
17919
17920 2010-04-12 Pedro Alves <pedro@codesourcery.com>
17921
17922 * regcache.c (set_register_cache): Invalidate regcaches before
17923 changing the register cache layout.
17924 (regcache_invalidate_one): Allow a NULL regcache.
17925 * linux-x86-low.c (x86_linux_update_xmltarget): Invalidate
17926 regcaches before changing the register cache layout or the target
17927 regsets.
17928
17929 2010-04-12 H.J. Lu <hongjiu.lu@intel.com>
17930
17931 * linux-x86-low.c (x86_linux_update_xmltarget): Avoid unused
17932 variable warning on Linux/x86-64.
17933
17934 2010-04-11 Pedro Alves <pedro@codesourcery.com>
17935
17936 GDBserver disconnected tracing support.
17937
17938 * linux-low.c (linux_remove_process): Delete.
17939 (add_lwp): Don't set last_resume_kind here.
17940 (linux_kill): Use `mourn'.
17941 (linux_detach): Use `thread_db_detach', and `mourn'.
17942 (linux_mourn): New.
17943 (linux_attach_lwp_1): Adjust comment.
17944 (linux_attach): last_resume_kind moved the thread_info; adjust.
17945 (status_pending_p_callback): Adjust.
17946 (linux_wait_for_event_1): Adjust.
17947 (count_events_callback, select_singlestep_lwp_callback)
17948 (select_event_lwp_callback, cancel_breakpoints_callback)
17949 (db_wants_lwp_stopped, linux_wait_1, need_step_over_p)
17950 (proceed_one_lwp): Adjust.
17951 (linux_async): Add debug output.
17952 (linux_thread_stopped): New.
17953 (linux_pause_all): New.
17954 (linux_target_ops): Install linux_mourn, linux_thread_stopped and
17955 linux_pause_all.
17956 * linux-low.h (struct lwp_info): Delete last_resume_kind field.
17957 (thread_db_free): Delete declaration.
17958 (thread_db_detach, thread_db_mourn): Declare.
17959 * thread-db.c (thread_db_init): Use thread_db_mourn.
17960 (thread_db_free): Delete, split in two.
17961 (disable_thread_event_reporting): New.
17962 (thread_db_detach): New.
17963 (thread_db_mourn): New.
17964
17965 * server.h (struct thread_info) <last_resume_kind>: New field.
17966 <attached>: Add comment.
17967 <gdb_detached>: New field.
17968 (handler_func): Change return type to int.
17969 (handle_serial_event, handle_target_event): Ditto.
17970 (gdb_connected): Declare.
17971 (tracing): Delete.
17972 (disconnected_tracing): Declare.
17973 (stop_tracing): Declare.
17974
17975 * server.c (handle_query) <qSupported>: Report support for
17976 disconnected tracing.
17977 (queue_stop_reply_callback): Account for running threads.
17978 (gdb_wants_thread_stopped): New.
17979 (gdb_wants_all_threads_stopped): New.
17980 (gdb_reattached_process): New.
17981 (handle_status): Clear the `gdb_detached' flag of all processes.
17982 In all-stop, stop all threads.
17983 (main): Be sure to leave tfind mode. Handle disconnected tracing.
17984 (process_serial_event): If the remote connection breaks, or if an
17985 exit was forced with "monitor exit", force an event loop exit.
17986 Handle disconnected tracing on detach.
17987 (handle_serial_event): Adjust.
17988 (handle_target_event): If GDB isn't connected, forward events back
17989 to the inferior, unless the last process exited, in which case,
17990 exit gdbserver. Adjust interface.
17991
17992 * remote-utils.c (remote_open): Don't block in accept. Instead
17993 register an event loop source on the listen socket file
17994 descriptor. Refactor bits into ...
17995 (listen_desc): ... this new global.
17996 (gdb_connected): ... this new function.
17997 (enable_async_notification): ... this new function.
17998 (handle_accept_event): ... this new function.
17999 (remote_close): Clear remote_desc.
18000
18001 * inferiors.c (add_thread): Set the new thread's last_resume_kind.
18002
18003 * target.h (struct target_ops) <mourn, thread_stopped, pause_all>:
18004 New fields.
18005 (mourn_inferior): Define.
18006 (target_process_qsupported): Avoid the dangling else problem.
18007 (thread_stopped): Define.
18008 (pause_all): Define.
18009 (target_waitstatus_to_string): Declare.
18010 * target.c (target_waitstatus_to_string): New.
18011
18012 * tracepoint.c (tracing): Make extern.
18013 (disconnected_tracing): New.
18014 (stop_tracing): Make extern. Handle tracing stops due to GDB
18015 disconnecting.
18016 (cmd_qtdisconnected): New.
18017 (cmd_qtstatus): Report disconnected tracing status in trace reply.
18018 (handle_tracepoint_general_set): Handle QTDisconnected.
18019
18020 * event-loop.c (event_handler_func): Change return type to int.
18021 (process_event): Bail out if the event handler wants the event
18022 loop to stop.
18023 (handle_file_event): Ditto.
18024 (start_event_loop): Bail out if the event handler wants the event
18025 loop to stop.
18026
18027 * nto-low.c (nto_target_ops): Adjust.
18028 * spu-low.c (spu_wait): Don't remove the process here.
18029 (spu_target_ops): Adjust.
18030 * win32-low.c (win32_wait): Don't remove the process here.
18031 (win32_target_ops): Adjust.
18032
18033 2010-04-11 Pedro Alves <pedro@codesourcery.com>
18034
18035 * regcache.c (realloc_register_cache): Invalidate inferior's
18036 regcache before recreating it.
18037
18038 2010-04-09 Pedro Alves <pedro@codesourcery.com>
18039
18040 * tracepoint.c (cmd_qtstatus): Report trace buffer circularity.
18041
18042 2010-04-09 Stan Shebs <stan@codesourcery.com>
18043 Pedro Alves <pedro@codesourcery.com>
18044
18045 * server.h (LONGEST): New.
18046 (struct thread_info) <while_stepping>: New field.
18047 (unpack_varlen_hex, xrealloc, pulongest, plongest, phex_nz):
18048 Declare.
18049 (initialize_tracepoint, handle_tracepoint_general_set)
18050 (handle_tracepoint_query, tracepoint_finished_step)
18051 (tracepoint_was_hit, release_while_stepping_state_list):
18052 (current_traceframe): Declare.
18053 * server.c (handle_general_set): Handle tracepoint packets.
18054 (read_memory): New.
18055 (write_memory): New.
18056 (handle_search_memory_1): Use read_memory.
18057 (handle_query): Report support for conditional tracepoints, trace
18058 state variables, and tracepoint sources. Handle tracepoint
18059 queries.
18060 (main): Initialize the tracepoints module.
18061 (process_serial_event): Handle traceframe reads/writes.
18062
18063 * linux-low.c (handle_tracepoints): New.
18064 (linux_wait_1): Call it.
18065 (linux_resume_one_lwp): Handle while-stepping.
18066 (linux_supports_tracepoints, linux_read_pc, linux_write_pc): New.
18067 (linux_target_ops): Install them.
18068 * linux-low.h (struct linux_target_ops) <supports_tracepoints>:
18069 New field.
18070 * linux-x86-low.c (x86_supports_tracepoints): New.
18071 (the_low_target). Install it.
18072
18073 * mem-break.h (delete_breakpoint): Declare.
18074 * mem-break.c (delete_breakpoint): Make external.
18075
18076 * target.h (struct target_ops): Add `supports_tracepoints',
18077 `read_pc', and `write_pc' fields.
18078 (target_supports_tracepoints): Define.
18079 * utils.c (xrealloc, decimal2str, pulongest, plongest, thirty_two)
18080 (phex_nz): New.
18081
18082 * regcache.h (struct regcache) <registers_owned>: New field.
18083 (init_register_cache, regcache_cpy): Declare.
18084 (regcache_read_pc, regcache_write_pc): Declare.
18085 (register_cache_size): Declare.
18086 (supply_regblock): Declare.
18087 * regcache.c (init_register_cache): New.
18088 (new_register_cache): Use it.
18089 (regcache_cpy): New.
18090 (register_cache_size): New.
18091 (supply_regblock): New.
18092 (regcache_read_pc, regcache_write_pc): New.
18093
18094 * tracepoint.c: New.
18095
18096 * Makefile.in (OBS): Add tracepoint.o.
18097 (tracepoint.o): New rule.
18098
18099 2010-04-08 H.J. Lu <hongjiu.lu@intel.com>
18100
18101 * Makefile.in (clean): Also remove i386-mmx.c i386-mmx-linux.c.
18102 (i386-mmx.o): New.
18103 (i386-mmx.c): Likewise.
18104 (i386-mmx-linux.o): Likewise.
18105 (i386-mmx-linux.c): Likewise.
18106
18107 * configure.srv (srv_i386_regobj): Add i386-mmx.o.
18108 (srv_i386_linux_regobj): Add i386-mmx-linux.o.
18109 (srv_i386_xmlfiles): Add i386/i386-mmx.xml.
18110 (srv_i386_linux_xmlfiles): Add i386/i386-mmx-linux.xml.
18111
18112 * linux-x86-low.c (init_registers_i386_mmx_linux): New.
18113 (x86_linux_update_xmltarget): Call init_registers_i386_mmx_linux
18114 and return if ptrace PTRACE_GETFPXREGS failed in 32bit.
18115
18116 2010-04-07 H.J. Lu <hongjiu.lu@intel.com>
18117
18118 * Makefile.in (clean): Updated.
18119 (i386-avx.o): New.
18120 (i386-avx.c): Likewise.
18121 (i386-avx-linux.o): Likewise.
18122 (i386-avx-linux.c): Likewise.
18123 (amd64-avx.o): Likewise.
18124 (amd64-avx.c): Likewise.
18125 (amd64-avx-linux.o): Likewise.
18126 (amd64-avx-linux.c): Likewise.
18127
18128 * configure.srv (srv_i386_regobj): Add i386-avx.o.
18129 (srv_i386_linux_regobj): Add i386-avx-linux.o.
18130 (srv_amd64_regobj): Add amd64-avx.o.
18131 (srv_amd64_linux_regobj): Add amd64-avx-linux.o.
18132 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx.xml.
18133 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx.xml.
18134 (srv_i386_xmlfiles): Add i386/i386-avx.xml.
18135 (srv_amd64_xmlfiles): Add i386/amd64-avx.xml.
18136 (srv_i386_linux_xmlfiles): Add i386/i386-avx-linux.xml.
18137 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-linux.xml.
18138
18139 * i387-fp.c: Include "i386-xstate.h".
18140 (i387_xsave): New.
18141 (i387_cache_to_xsave): Likewise.
18142 (i387_xsave_to_cache): Likewise.
18143 (x86_xcr0): Likewise.
18144
18145 * i387-fp.h (i387_cache_to_xsave): Likewise.
18146 (i387_xsave_to_cache): Likewise.
18147 (x86_xcr0): Likewise.
18148
18149 * linux-arm-low.c (target_regsets): Initialize nt_type to 0.
18150 * linux-crisv32-low.c (target_regsets): Likewise.
18151 * linux-m68k-low.c (target_regsets): Likewise.
18152 * linux-mips-low.c (target_regsets): Likewise.
18153 * linux-ppc-low.c (target_regsets): Likewise.
18154 * linux-s390-low.c (target_regsets): Likewise.
18155 * linux-sh-low.c (target_regsets): Likewise.
18156 * linux-sparc-low.c (target_regsets): Likewise.
18157 * linux-xtensa-low.c (target_regsets): Likewise.
18158
18159 * linux-low.c: Include <sys/uio.h>.
18160 (regsets_fetch_inferior_registers): Support nt_type.
18161 (regsets_store_inferior_registers): Likewise.
18162 (linux_process_qsupported): New.
18163 (linux_target_ops): Add linux_process_qsupported.
18164
18165 * linux-low.h (regset_info): Add nt_type.
18166 (linux_target_ops): Add process_qsupported.
18167
18168 * linux-x86-low.c: Include "i386-xstate.h", "elf/common.h"
18169 and <sys/uio.h>.
18170 (init_registers_i386_avx_linux): New.
18171 (init_registers_amd64_avx_linux): Likewise.
18172 (xmltarget_i386_linux_no_xml): Likewise.
18173 (xmltarget_amd64_linux_no_xml): Likewise.
18174 (PTRACE_GETREGSET): Likewise.
18175 (PTRACE_SETREGSET): Likewise.
18176 (x86_fill_xstateregset): Likewise.
18177 (x86_store_xstateregset): Likewise.
18178 (use_xml): Likewise.
18179 (x86_linux_update_xmltarget): Likewise.
18180 (x86_linux_process_qsupported): Likewise.
18181 (target_regsets): Add NT_X86_XSTATE entry and Initialize nt_type.
18182 (x86_arch_setup): Don't call init_registers_amd64_linux nor
18183 init_registers_i386_linux here. Call
18184 x86_linux_update_xmltarget.
18185 (the_low_target): Add x86_linux_process_qsupported.
18186
18187 * server.c (handle_query): Call target_process_qsupported.
18188
18189 * target.h (target_ops): Add process_qsupported.
18190 (target_process_qsupported): New.
18191
18192 2010-04-03 Pedro Alves <pedro@codesourcery.com>
18193
18194 * inferiors.c (add_thread): Set last_status kind to
18195 TARGET_WAITKIND_IGNORE.
18196 * linux-low.c (cancel_breakpoint): Remove unnecessary regcache
18197 fetch. Use ptid_of. Avoid unnecessary get_lwp_thread calls.
18198 (linux_wait_1): Move `thread' local definition to block that uses
18199 it. Don't NULL initialize `event_child'.
18200 (linux_resume_one_thread): Avoid unnecessary get_lwp_thread calls.
18201 Alway set the thread's last_status to TARGET_WAITKIND_IGNORE.
18202 * linux-x86-low.c (x86_breakpoint_at): Read raw memory.
18203
18204 2010-04-01 Pedro Alves <pedro@codesourcery.com>
18205
18206 * linux-low.c (get_stop_pc): Don't adjust the PC if stopped with
18207 an extended waitstatus, or by a watchpoint.
18208 (cancel_breakpoints_callback): Don't cancel a breakpoint if the
18209 thread was stepping or has been stopped by a watchpoint.
18210
18211 2010-04-01 Pedro Alves <pedro@codesourcery.com>
18212
18213 * mem-break.c (struct raw_breakpoint): New field shlib_disabled.
18214 (set_gdb_breakpoint_at): If GDB is inserting a breakpoint on top
18215 of another, then delete the previous, and validate all
18216 breakpoints.
18217 (validate_inserted_breakpoint): New.
18218 (delete_disabled_breakpoints): New.
18219 (validate_breakpoints): New.
18220 (check_mem_read): Validate breakpoints before trusting their
18221 shadow. Delete disabled breakpoints.
18222 (check_mem_write): Validate breakpoints before trusting they
18223 should be inserted. Delete disabled breakpoints.
18224 * mem-break.h (validate_breakpoints):
18225 * server.c (handle_query): Validate breakpoints when we see a
18226 qSymbol query.
18227
18228 2010-04-01 Pedro Alves <pedro@codesourcery.com>
18229
18230 * linux-low.c (linux_wait_1): Avoid setting need_step_over is
18231 there's a GDB breakpoint at stop_pc. Always report a trap to GDB
18232 if we could tell there's a GDB breakpoint at stop_pc.
18233 (need_step_over_p): Don't do a step over if we find a GDB
18234 breakpoint at the resume PC.
18235
18236 * mem-break.c (struct raw_breakpoint): New.
18237 (enum bkpt_type): New type `gdb_breakpoint'.
18238 (struct breakpoint): Delete the `PC', `old_data' and `inserted'
18239 fields. New field `raw'.
18240 (find_raw_breakpoint_at): New.
18241 (set_raw_breakpoint_at): Handle refcounting. Create a raw
18242 breakpoint instead.
18243 (set_breakpoint_at): Adjust.
18244 (delete_raw_breakpoint): New.
18245 (release_breakpoint): New.
18246 (delete_breakpoint): Rename to...
18247 (delete_breakpoint_1): ... this. Add proc parameter. Use
18248 release_breakpoint. Return ENOENT.
18249 (delete_breakpoint): Reimplement.
18250 (find_breakpoint_at): Delete.
18251 (find_gdb_breakpoint_at): New.
18252 (delete_breakpoint_at): Delete.
18253 (set_gdb_breakpoint_at): New.
18254 (delete_gdb_breakpoint_at): New.
18255 (gdb_breakpoint_here): New.
18256 (set_reinsert_breakpoint): Use release_breakpoint.
18257 (uninsert_breakpoint): Rename to ...
18258 (uninsert_raw_breakpoint): ... this.
18259 (uninsert_breakpoints_at): Adjust to handle raw breakpoints.
18260 (reinsert_raw_breakpoint): Change parameter type to
18261 raw_breakpoint.
18262 (reinsert_breakpoints_at): Adjust to handle raw breakpoints
18263 instead.
18264 (check_breakpoints): Adjust. Use release_breakpoint.
18265 (breakpoint_here): Rewrite using find_raw_breakpoint_at.
18266 (breakpoint_inserted_here): Ditto.
18267 (check_mem_read): Adjust to iterate over raw breakpoints instead.
18268 Don't trust the breakpoint's shadow if it is not inserted.
18269 (check_mem_write): Adjust to iterate over raw breakpoints instead.
18270 (delete_all_breakpoints): Adjust.
18271 (free_all_breakpoints): Mark all breakpoints as uninserted, and
18272 use delete_breakpoint_1.
18273
18274 * mem-break.h (breakpoints_supported): Delete declaration.
18275 (set_gdb_breakpoint_at): Declare.
18276 (gdb_breakpoint_here): Declare.
18277 (delete_breakpoint_at): Delete.
18278 (delete_gdb_breakpoint_at): Declare.
18279
18280 * server.h (struct raw_breakpoint): Forward declare.
18281 (struct process_info): New field `raw_breakpoints'.
18282
18283 * linux-x86-low.c (x86_insert_point, x86_remote_point): Handle Z0
18284 breakpoints.
18285
18286 2010-03-24 Pedro Alves <pedro@codesourcery.com>
18287
18288 * linux-low.c (status_pending_p_callback): Fix comment.
18289 (linux_wait_for_event_1): Move most of the internal breakpoint
18290 handling from here...
18291 (linux_wait_1): ... to here.
18292 (count_events_callback): New.
18293 (select_singlestep_lwp_callback): New.
18294 (select_event_lwp_callback): New.
18295 (cancel_breakpoints_callback): New.
18296 (select_event_lwp): New.
18297 (linux_wait_1): Simplify internal breakpoint handling. Give equal
18298 priority to all LWPs that have had events that should be reported
18299 to the client. Cancel breakpoints when about to reporting the
18300 event to the client, not while stopping lwps. No longer cancel
18301 finished single-steps here.
18302 (cancel_finished_single_step): Delete.
18303 (cancel_finished_single_steps): Delete.
18304
18305 2010-03-24 Pedro Alves <pedro@codesourcery.com>
18306
18307 * mem-break.c (enum bkpt_type): New.
18308 (struct breakpoint): New field `type'.
18309 (set_breakpoint_at): Change return type to struct breakpoint
18310 pointer. Set type to `other_breakpoint' by default.
18311 (delete_breakpoint): Rewrite, supporting more than one breakpoint
18312 in the breakpoint list.
18313 (delete_reinsert_breakpoints): Only delete reinsert breakpoints.
18314 (reinsert_breakpoint): Rename to ...
18315 (reinsert_raw_breakpoint): ... this.
18316 (reinsert_breakpoints_at): Adjust.
18317 * mem-break.h (struct breakpoint): Declare.
18318 (set_breakpoint_at): Change return type to struct breakpoint
18319 pointer.
18320
18321 2010-03-24 Pedro Alves <pedro@codesourcery.com>
18322
18323 * server.c (handle_query): Assign, not compare.
18324
18325 2010-03-24 Pedro Alves <pedro@codesourcery.com>
18326
18327 Teach linux gdbserver to step-over-breakpoints.
18328
18329 * linux-low.c (can_hardware_single_step): New.
18330 (supports_breakpoints): New.
18331 (handle_extended_wait): If stopping threads, read the stop pc of
18332 the new cloned LWP.
18333 (get_pc): New.
18334 (get_stop_pc): Add `lwp' parameter. Handle it. Bail out if the
18335 low target doesn't support retrieving the PC.
18336 (add_lwp): Set last_resume_kind to resume_continue.
18337 (linux_attach_lwp_1): Adjust comments. Always set stop_expected.
18338 (linux_attach): Don't clear stop_expected. Set the lwp's
18339 last_resume_kind to resume_stop.
18340 (linux_detach_one_lwp): Don't check for removed breakpoints.
18341 (check_removed_breakpoint): Delete.
18342 (status_pending_p): Rename to ...
18343 (status_pending_p_callback): ... this. Don't check for removed
18344 breakpoints. Don't consider threads that are stopped from GDB's
18345 perspective.
18346 (linux_wait_for_lwp): Always read the stop_pc here.
18347 (cancel_breakpoint): New.
18348 (step_over_bkpt): New global.
18349 (linux_wait_for_event_1): Implement stepping over breakpoints.
18350 (gdb_wants_lwp_stopped): New.
18351 (gdb_wants_all_stopped): New.
18352 (linux_wait_1): Tag threads as gdb-wants-stopped. Cancel finished
18353 single-step traps here. Store the thread's last reported target
18354 wait status.
18355 (send_sigstop): Don't clear stop_expected. Always set it,
18356 instead.
18357 (mark_lwp_dead): Remove reference to pending_is_breakpoint.
18358 (cancel_finished_single_step): New.
18359 (cancel_finished_single_steps): New.
18360 (wait_for_sigstop): Don't cancel finished single-step traps here.
18361 (linux_resume_one_lwp): Don't check for removed breakpoints.
18362 Don't set `step' on non-hardware step archs.
18363 (linux_set_resume_request): Ignore resume_stop requests if already
18364 stopping or stopped. Set the lwp's last_resume_kind.
18365 (resume_status_pending_p): Don't check for removed breakpoints.
18366 (need_step_over_p): New.
18367 (start_step_over): New.
18368 (finish_step_over): New.
18369 (linux_resume_one_thread): Always queue a sigstop for resume_stop
18370 requests. Clear the thread's last reported target waitstatus.
18371 Don't use the `suspended' flag. Don't consider pending breakpoints.
18372 (linux_resume): Start a step-over if necessary.
18373 (proceed_one_lwp): New.
18374 (proceed_all_lwps): New.
18375 (unstop_all_lwps): New.
18376 * linux-low.h (struct lwp_info): Rewrite comment for the
18377 `suspended' flag. Add the `stop_pc' field. Delete the
18378 `pending_stop_pc' field. Tweak the `stepping' flag's comment.
18379 Add `'last_resume_kind' and `need_step_over' fields.
18380 * inferiors.c (struct thread_info): Delete, moved elsewhere.
18381 * mem-break.c (struct breakpoint): Delete `reinserting' flag.
18382 Delete `breakpoint_to_reinsert' field. New flag `inserted'.
18383 (set_raw_breakpoint_at): New.
18384 (set_breakpoint_at): Rewrite to use it.
18385 (reinsert_breakpoint_handler): Delete.
18386 (set_reinsert_breakpoint): New.
18387 (reinsert_breakpoint_by_bp): Delete.
18388 (delete_reinsert_breakpoints): New.
18389 (uninsert_breakpoint): Rewrite.
18390 (uninsert_breakpoints_at): New.
18391 (reinsert_breakpoint): Rewrite.
18392 (reinsert_breakpoints_at): New.
18393 (check_breakpoints): Rewrite.
18394 (breakpoint_here): New.
18395 (breakpoint_inserted_here): New.
18396 (check_mem_read): Adjust.
18397 * mem-break.h (breakpoints_supported, breakpoint_here)
18398 (breakpoint_inserted_here, set_reinsert_breakpoint): Declare.
18399 (reinsert_breakpoint_by_bp): Delete declaration.
18400 (delete_reinsert_breakpoints): Declare.
18401 (reinsert_breakpoint): Delete declaration.
18402 (reinsert_breakpoints_at): Declare.
18403 (uninsert_breakpoint): Delete declaration.
18404 (uninsert_breakpoints_at): Declare.
18405 (check_breakpoints): Adjust prototype.
18406 * server.h: Adjust include order.
18407 (struct thread_info): Declare here. Add a `last_status' field.
18408
18409 2010-03-23 Michael Snyder <msnyder@vmware.com>
18410
18411 * server.c (crc32): New function.
18412 (handle_query): Add handling for 'qCRC:' request.
18413
18414 2010-03-23 Pedro Alves <pedro@codesourcery.com>
18415
18416 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR6 if the
18417 lwp had been stopped by a watchpoint.
18418
18419 2010-03-16 Pedro Alves <pedro@codesourcery.com>
18420
18421 * server.h (internal_error): Declare.
18422 (gdb_assert, ASSERT_FUNCTION, gdb_assert_fail): Define.
18423 * utils.c (internal_error): New function.
18424
18425 2010-03-15 Andreas Schwab <schwab@redhat.com>
18426
18427 * configure.srv: Fix typo setting srv_regobj.
18428
18429 2010-03-15 Pedro Alves <pedro@codesourcery.com>
18430
18431 * linux-low.c (fetch_register): Avoid passing a non string literal
18432 format to `error'.
18433 (usr_store_inferior_registers): Ditto.
18434
18435 2010-03-14 Pedro Alves <pedro@codesourcery.com>
18436
18437 * linux-low.c (linux_write_memory): Bail out early if peeking
18438 memory failed.
18439
18440 2010-03-14 Pedro Alves <pedro@codesourcery.com>
18441
18442 * linux-low.h (struct lwp_info): New fields
18443 `stopped_by_watchpoint' and `stopped_data_address'.
18444 * linux-low.c (linux_wait_for_lwp): Check for watchpoint triggers
18445 here, and cache them in the lwp object.
18446 (wait_for_sigstop): Check stopped_by_watchpoint lwp field
18447 directly.
18448 (linux_resume_one_lwp): Clear the lwp's stopped_by_watchpoint
18449 field.
18450 (linux_stopped_by_watchpoint): Rewrite.
18451 (linux_stopped_data_address): Rewrite.
18452
18453 2010-03-06 Simo Melenius <simo.melenius@iki.fi>
18454
18455 * linux-low.c (linux_wait_for_lwp): Fetch the regcache after
18456 switching the current inferior, not before.
18457
18458 2010-03-01 H.J. Lu <hongjiu.lu@intel.com>
18459
18460 * Makefile.in (clean): Replace reg-i386.c, reg-x86-64.c,
18461 reg-i386-linux.c and reg-x86-64-linux.c with i386.c, amd64.c,
18462 i386-linux.c and amd64-linux.c.
18463 (reg-i386.o): Removed.
18464 (reg-i386.c): Likewise.
18465 (reg-i386-linux.o): Likewise.
18466 (reg-i386-linux.c): Likewise.
18467 (reg-x86-64.o): Likewise.
18468 (reg-x86-64.c): Likewise.
18469 (reg-x86-64-linux.o): Likewise.
18470 (reg-x86-64-linux.c): Likewise.
18471 (i386.o): New.
18472 (i386.c): Likewise.
18473 (i386-linux.o): Likewise.
18474 (i386-linux.c): Likewise.
18475 (amd64.o): Likewise.
18476 (amd64.c): Likewise.
18477 (amd64-linux.o): Likewise.
18478 (amd64-linux.c): Likewise.
18479
18480 * configure.srv (srv_i386_regobj): New.
18481 (srv_i386_linux_regobj): Likewise.
18482 (srv_amd64_regobj): Likewise.
18483 (srv_amd64_linux_regobj): Likewise.
18484 (srv_i386_32bit_xmlfiles): Likewise.
18485 (srv_i386_64bit_xmlfiles): Likewise.
18486 (srv_i386_xmlfiles): Likewise.
18487 (srv_amd64_xmlfiles): Likewise.
18488 (srv_i386_linux_xmlfiles): Likewise.
18489 (srv_amd64_linux_xmlfiles): Likewise.
18490 (i[34567]86-*-cygwin*): Set srv_regobj to $srv_i386_regobj. Set
18491 srv_xmlfiles to $srv_i386_xmlfiles.
18492 (i[34567]86-*-mingw32ce*): Likewise.
18493 (i[34567]86-*-mingw*): Likewise.
18494 (i[34567]86-*-nto*): Likewise.
18495 (i[34567]86-*-linux*): Set srv_regobj to $srv_i386_linux_regobj
18496 and $srv_amd64_linux_regobj. Set srv_xmlfiles to
18497 $srv_i386_linux_xmlfiles and $srv_amd64_linux_xmlfiles.
18498 (x86_64-*-linux*): Likewise.
18499
18500 * linux-x86-low.c (init_registers_x86_64_linux): Removed.
18501 (init_registers_amd64_linux): New.
18502 (x86_arch_setup): Replace init_registers_x86_64_linux with
18503 init_registers_amd64_linux.
18504
18505 2010-02-23 Maxim Kuvyrkov <maxim@codesourcery.com>
18506
18507 * configure.ac: Check for libdl. If it is not available link against
18508 static libthread_db.
18509 * configure: Regenerate.
18510
18511 2010-02-22 Pedro Alves <pedro@codesourcery.com>
18512
18513 PR9605
18514
18515 * i386-low.c (i386_length_and_rw_bits): Throw a fatal error if
18516 handing a read watchpoint.
18517 (i386_low_insert_watchpoint): Read watchpoints aren't supported.
18518
18519 2010-02-12 Doug Evans <dje@google.com>
18520
18521 * linux-low.c (linux_supports_tracefork_flag): Document.
18522 (linux_look_up_symbols): Add comment.
18523
18524 2010-02-03 H.J. Lu <hongjiu.lu@intel.com>
18525
18526 * regcache.c (supply_register): Clear regcache if buf is NULL.
18527
18528 2010-02-02 Nicolas Roche <roche@sourceware.org>
18529 Joel Brobecker <brobecker@adacore.com>
18530
18531 * inferiors.c (find_inferior): Add function documentation.
18532 (unloaded_dll): Handle the case where the unloaded dll has not
18533 been previously registered in the dll list.
18534
18535 2010-02-01 Daniel Jacobowitz <dan@codesourcery.com>
18536
18537 * linux-arm-low.c (thumb_breakpoint_len): Delete.
18538 (thumb2_breakpoint): New.
18539 (arm_breakpoint_at): Check for Thumb-2 breakpoints.
18540
18541 2010-01-29 Daniel Jacobowitz <dan@codesourcery.com>
18542
18543 * linux-low.c (get_stop_pc): Check for SIGTRAP.
18544 (linux_wait_for_event_1): Handle SIGILL and SIGSEGV as possible
18545 breakpoints.
18546
18547 2010-01-21 Pedro Alves <pedro@codesourcery.com>
18548
18549 * linux-ppc-low.c (ppc_arch_setup): Adjust to regcache changes.
18550
18551 2010-01-21 Jan Kratochvil <jan.kratochvil@redhat.com>
18552
18553 * linux-s390-low.c (s390_collect_ptrace_register)
18554 (s390_supply_ptrace_register): Adjust it for the new regcache parameter.
18555
18556 2010-01-21 Doug Evans <dje@google.com>
18557
18558 * linux-low.c (PTRACE_ARG3_TYPE): Change from long to void*.
18559 (PTRACE_ARG4_TYPE): New macro.
18560 (handle_extended_wait): Cast ptrace arg4 to PTRACE_ARG4_TYPE.
18561 (linux_wait_for_event_1, linux_resume_one_lwp): Ditto.
18562 (fetch_register): Cast to uintptr_t before casting to PTRACE_ARG3_TYPE.
18563 (usr_store_inferior_registers): Ditto.
18564 (linux_read_memory, linux_write_memory): Ditto.
18565 (linux_test_for_tracefork): Ditto.
18566
18567 * linux-arm-low.c: Remove redundant include of gdb_proc_service.h.
18568 Only include elf.h if gdb_proc_service.h didn't include linux/elf.h.
18569
18570 2010-01-21 Pedro Alves <pedro@codesourcery.com>
18571
18572 * proc-service.c (ps_lgetregs): Don't refetch registers from the
18573 target.
18574
18575 2010-01-21 Pedro Alves <pedro@codesourcery.com>
18576
18577 * spu-low.c (spu_fetch_registers, spu_store_registers): Change
18578 prototype to take a regcache. Adjust.
18579
18580 2010-01-20 Pedro Alves <pedro@codesourcery.com>
18581
18582 * regcache.h (struct thread_info): Forward declare.
18583 (struct regcache): New.
18584 (new_register_cache): Adjust prototype.
18585 (get_thread_regcache): Declare.
18586 (free_register_cache): Adjust prototype.
18587 (registers_to_string, registers_from_string): Ditto.
18588 (supply_register, supply_register_by_name, collect_register)
18589 (collect_register_as_string, collect_register_by_name): Ditto.
18590 * regcache.c (struct inferior_regcache_data): Delete.
18591 (get_regcache): Rename to ...
18592 (get_thread_regcache): ... this. Adjust. Switch inferior before
18593 fetching registers.
18594 (regcache_invalidate_one): Adjust.
18595 (regcache_invalidate): Fix prototype.
18596 (new_register_cache): Return the new register cache.
18597 (free_register_cache): Change prototype.
18598 (realloc_register_cache): Adjust.
18599 (registers_to_string): Change prototype to take a regcache. Adjust.
18600 (registers_from_string): Ditto.
18601 (register_data): Ditto.
18602 (supply_register): Ditto.
18603 (supply_register_by_name): Ditto.
18604 (collect_register): Ditto.
18605 (collect_register_as_string): Ditto.
18606 (collect_register_by_name): Ditto.
18607 * server.c (process_serial_event): Adjust.
18608 * linux-low.h (regset_fill_func, regset_store_func): Change
18609 prototype.
18610 (get_pc, set_pc, collect_ptrace_register, supply_ptrace_register):
18611 Change prototype.
18612 * linux-low.c (get_stop_pc): Adjust.
18613 (check_removed_breakpoint): Adjust.
18614 (linux_wait_for_event): Adjust.
18615 (linux_resume_one_lwp): Adjust.
18616 (fetch_register): Add regcache parameter. Adjust.
18617 (usr_store_inferior_registers): Ditto.
18618 (regsets_fetch_inferior_registers): Ditto.
18619 (regsets_store_inferior_registers): Ditto.
18620 (linux_fetch_registers, linux_store_registers): Ditto.
18621 * i387-fp.c (i387_cache_to_fsave): Change prototype to take a
18622 regcache. Adjust.
18623 (i387_fsave_to_cache, i387_cache_to_fxsave, i387_fxsave_to_cache):
18624 Ditto.
18625 * i387-fp.h (i387_cache_to_fsave, i387_fsave_to_cache): Change
18626 prototype to take a regcache.
18627 (i387_cache_to_fxsave, i387_fxsave_to_cache): Ditto.
18628 * remote-utils.c (convert_ascii_to_int, outreg)
18629 (prepare_resume_reply): Change prototype to take a regcache.
18630 Adjust.
18631 * target.h (struct target_ops) <fetch_registers, store_registers>:
18632 Change prototype to take a regcache.
18633 (fetch_inferior_registers, store_inferior_registers): Change
18634 prototype to take a regcache. Adjust.
18635 * proc-service.c (ps_lgetregs): Adjust.
18636 * linux-x86-low.c (x86_fill_gregset, x86_store_gregset)
18637 (x86_fill_fpregset, x86_store_fpregset, x86_fill_fpxregset)
18638 (x86_store_fpxregset, x86_get_pc, x86_set_pc): Change prototype to
18639 take a regcache. Adjust.
18640 * linux-arm-low.c (arm_fill_gregset, arm_store_gregset)
18641 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
18642 (arm_store_vfpregset, arm_get_pc, arm_set_pc):
18643 (arm_breakpoint_at): Change prototype to take a regcache. Adjust.
18644 * linux-cris-low.c (cris_get_pc, cris_set_pc)
18645 (cris_cannot_fetch_register):
18646 (cris_breakpoint_at): Change prototype to take a regcache.
18647 Adjust.
18648 * linux-crisv32-low.c (cris_get_pc, cris_set_pc,
18649 cris_reinsert_addr, cris_write_data_breakpoint): Change prototype
18650 to take a regcache. Adjust.
18651 (cris_breakpoint_at, cris_insert_point, cris_remove_point):
18652 Adjust.
18653 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Change prototype to
18654 take a regcache. Adjust.
18655 * linux-m68k-low.c (m68k_fill_gregset, m68k_store_gregset)
18656 (m68k_fill_fpregset, m68k_store_fpregset, m68k_get_pc,
18657 (m68k_set_pc): Change prototype to take a regcache. Adjust.
18658 * linux-mips-low.c (mips_get_pc):
18659 (mips_set_pc): Change prototype to take a regcache. Adjust.
18660 (mips_reinsert_addr): Adjust.
18661 (mips_collect_register): Change prototype to take a regcache.
18662 Adjust.
18663 (mips_supply_register):
18664 (mips_collect_register_32bit, mips_supply_register_32bit)
18665 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
18666 (mips_store_fpregset): Ditto.
18667 * linux-ppc-low.c (ppc_supply_ptrace_register)
18668 (ppc_supply_ptrace_register): Ditto.
18669 (parse_spufs_run): Adjust.
18670 (ppc_get_pc, ppc_set_pc, ppc_fill_gregset, ppc_fill_vsxregset)
18671 (ppc_store_vsxregset, ppc_fill_vrregset, ppc_store_vrregset)
18672 (ppc_fill_evrregset, ppc_store_evrregset): Change prototype to
18673 take a regcache. Adjust.
18674 * linux-s390-low.c (s390_collect_ptrace_register)
18675 (s390_supply_ptrace_register, s390_fill_gregset, s390_get_pc)
18676 (s390_set_pc): Change prototype to take a regcache. Adjust.
18677 (s390_arch_setup): Adjust.
18678 * linux-sh-low.c (sh_get_pc, sh_breakpoint_at)
18679 (sh_fill_gregset): Change prototype to take a regcache. Adjust.
18680 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
18681 (sparc_fill_gregset, sparc_store_gregset_from_stack)
18682 (sparc_store_gregset, sparc_get_pc): Change prototype to take a
18683 regcache. Adjust.
18684 (sparc_breakpoint_at): Adjust.
18685 * linux-xtensa-low.c (xtensa_fill_gregset):
18686 (xtensa_store_gregset):
18687 (xtensa_fill_xtregset, xtensa_store_xtregset, xtensa_get_pc)
18688 (xtensa_set_pc): Change prototype to take a regcache. Adjust.
18689 * nto-low.c (nto_fetch_registers, nto_store_registers): Change
18690 prototype to take a regcache. Adjust.
18691 * win32-arm-low.c (arm_fetch_inferior_register)
18692 (arm_store_inferior_register): Change prototype to take a
18693 regcache. Adjust.
18694 * win32-i386-low.c (i386_fetch_inferior_register)
18695 (i386_store_inferior_register): Change prototype to take a
18696 regcache. Adjust.
18697 * win32-low.c (child_fetch_inferior_registers)
18698 (child_store_inferior_registers): Change prototype to take a
18699 regcache. Adjust.
18700 (win32_wait): Adjust.
18701 (win32_fetch_inferior_registers): Change prototype to take a
18702 regcache. Adjust.
18703 (win32_store_inferior_registers): Adjust.
18704 * win32-low.h (struct win32_target_ops) <fetch_inferior_register,
18705 store_inferior_register>: Change prototype to take a regcache.
18706
18707 2010-01-20 Doug Evans <dje@google.com>
18708
18709 * linux-low.c (linux_create_inferior): Wrap use of __SIGRTMIN in
18710 #ifdef.
18711 (linux_wait_for_event1, linux_init_signals): Ditto.
18712 (W_STOPCODE): Provide definition if missing.
18713
18714 2010-01-13 Vladimir Prus <vladimir@codesourcery.com>
18715
18716 * linux-low.c (linux_core_of_thread): New.
18717 (compare_ints, show_process, list_threads): New.
18718 (linux_qxfer_osdata): Report threads and cores.
18719 (linux_target_op): Register linux_core_of_thread.
18720 * remote-utils.c (prepare_resume_reply): Report the core.
18721 (buffer_xml_printf): Support %d specifier.
18722 * server.c (handle_threads_qxfer_proper, handle_threads_qxfer):
18723 New.
18724 (handle_query): Handle qXfer:threads. Announce availability
18725 thereof.
18726 * target.h (struct target_ops): New field core_of_thread.
18727
18728 2010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
18729
18730 * Makefile.in (clean): Remove new generated files.
18731 (reg-s390.o, reg-s390.c): Remove rules.
18732 (reg-s390x.o, reg-s390x.c): Likewise.
18733 (s390-linux32.o, s390-linux32.c): Add rules.
18734 (s390-linux64.o, s390-linux64.c): Likewise.
18735 (s390x-linux64.o, s390x-linux64.c): Likewise.
18736 * configure.srv (s390*-*-linux*): Update srv_regobj and srv_xmlfiles.
18737 * linux-s390-low.c: Include <elf.h>.
18738 (HWCAP_S390_HIGH_GPRS): Define if undefined.
18739 (init_registers_s390): Remove prototype.
18740 (init_registers_s390x): Likewise.
18741 (init_registers_s390_linux32): Add prototype.
18742 (init_registers_s390_linux64): Likewise.
18743 (init_registers_s390x_linux64): Likewise.
18744 (s390_num_regs_3264): New define.
18745 (s390_regmap_3264): New global variable.
18746 (s390_cannot_fetch_register): Remove obsolete check.
18747 (s390_cannot_store_register): Likewise.
18748 (s390_collect_ptrace_register): Handle upper/lower register halves.
18749 (s390_supply_ptrace_register): Likewise.
18750 (s390_fill_gregset): Update to register number changes.
18751 (s390_get_hwcap): New routine.
18752 (s390_arch_setup): Detect 32-bit process running on 64-bit system.
18753 Install appropriate regmap and register set.
18754
18755 2010-01-01 Joel Brobecker <brobecker@adacore.com>
18756
18757 * server.c (gdbserver_version): Update copyright year to 2010.
18758 * gdbreplay.c (gdbreplay_version): Likewise.
18759
18760 2009-12-28 Doug Evans <dje@google.com>
18761
18762 * linux-low.c: Delete inclusion of ansidecl.h, elf/common.h,
18763 elf/external.h. Include <elf.h> instead but only if necessary.
18764
18765 2009-12-28 Pedro Alves <pedro@codesourcery.com>
18766
18767 * linux-low.c (linux_remove_process): Remove `detaching'
18768 parameter. Don't release/detach from thread_db here.
18769 (linux_kill): Release/detach from thread_db here, ...
18770 (linux_detach): ... and here, before actually detaching.
18771 (linux_wait_1): ... and here, when a process exits.
18772 * thread-db.c (any_thread_of): New.
18773 (thread_db_free): Switch the current inferior to a thread of the
18774 passed in process.
18775
18776 2009-12-21 Doug Evans <dje@google.com>
18777
18778 * linux-x86-low.c: Delete outdated comment about Elf32_Phdr.
18779
18780 * linux-low.c (kill_lwp): Use __NR_tkill instead of SYS_tkill.
18781 Move definition of tkill_failed to ifdef __NR_tkill to avoid gcc
18782 warning ifndef __NR_tkill. Move setting of errno there too.
18783 Delete unnecessary resetting of errno after syscall.
18784 Minor comment changes to match gdb/linux-nat.c:kill_lwp.
18785
18786 * configure.ac: Check for dladdr.
18787 * config.in: Regenerate.
18788 * configure: Regenerate.
18789 * thread-db.c (dladdr_to_soname): Only define ifdef HAVE_DLADDR.
18790 (try_thread_db_load): Update.
18791
18792 * linux-low.c (my_waitpid): Delete unnecessary prototype.
18793
18794 2009-12-18 Doug Evans <dje@google.com>
18795
18796 * event-loop.c: Include unistd.h if it exists.
18797
18798 * linux-low.c (my_waitpid): Move definition away from being in
18799 between linux_tracefork_child/linux_test_for_tracefork.
18800
18801 * gdb_proc_service.h (psaddr_t): Fix type.
18802 * thread-db.c (thread_db_info.td_thr_tls_get_addr_p): Fix
18803 signature to match glibc.
18804
18805 2009-12-16 Doug Evans <dje@google.com>
18806
18807 * linux-low.c (linux_read_memory): Fix argument to read.
18808
18809 2009-11-26 Pedro Alves <pedro@codesourcery.com>
18810
18811 * win32-low.c (get_child_debug_event): On EXIT_THREAD_DEBUG_EVENT
18812 events, don't leave current_inferior pointing at null.
18813
18814 2009-11-26 Pedro Alves <pedro@codesourcery.com>
18815
18816 * win32-low.c (LOG): Delete.
18817 (OUTMSG): Output to stderr.
18818 (OUTMSG2): Conditionalize on `debug_threads' variable, instead of
18819 on compile time LOG macro.
18820 (win32_wait): Fix debug output.
18821
18822 2009-11-26 Pedro Alves <pedro@codesourcery.com>
18823
18824 * win32-low.c (win32_add_one_solib): If the dll name is
18825 "ntdll.dll", prepend the system directory to the dll path.
18826
18827 2009-11-17 Daniel Jacobowitz <dan@codesourcery.com>
18828
18829 * m68k-tdep.c (m68k_gdbarch_init): Reuse previous initialization.
18830
18831 2009-11-17 Nathan Sidwell <nathan@codesourcery.com>
18832 Vladimir Prus <vladimir@codesourcery.com>
18833
18834 * Makefile.in (reg-cf.o, reg-cf.c): New targets.
18835 * configure.ac: Check for __mcoldfire__ and set
18836 gdb_cv_m68k_is_coldfire.
18837 * configure.srv: Use gdb_cv_m68k_is_coldfire to select between
18838 reg-cf.o and reg-m68k.o.
18839 * configure: Regenerated.
18840
18841 2009-11-16 Pedro Alves <pedro@codesourcery.com>
18842
18843 * linux-low.c (linux_remove_process): Add `detaching' parameter.
18844 Pass it to thread_db_free.
18845 (linux_kill, linux_detach, linux_wait_1): Adjust to pass the
18846 proper `detaching' argument to linux_remove_process.
18847 * linux-low.h (thread_db_free): Add `detaching' parameter.
18848 * thread-db.c (thread_db_init): Pass false as `detaching' argument
18849 to thread_db_free.
18850 (thread_db_free): Add `detaching' parameter. Only
18851 call td_ta_clear_event if detaching from process.
18852
18853 2009-11-12 Maxim Kuvyrkov <maxim@codesourcery.com>
18854
18855 * thread-db.c (thread_db_free): Fix typo.
18856
18857 2009-11-11 Paul Pluzhnikov <ppluzhnikov@google.com>
18858
18859 PR gdb/10838
18860 * thread-db.c (thread_db_free): Call td_ta_clear_event.
18861
18862 2009-11-03 Nathan Sidwell <nathan@codesourcery.com>
18863
18864 * configure.ac (i[34567]86-*): Check if we're targetting x86-64
18865 with an i686 compiler.
18866 * configure.srv (i[34567]86-*-linux*): Pull in x86-64 handling if
18867 needed.
18868 * configure: Rebuilt.
18869
18870 2009-10-29 Sandra Loosemore <sandra@codesourcery.com>
18871
18872 PR gdb/10783
18873
18874 * server.c (handle_search_memory_1): Correct read_addr initialization
18875 in loop for searching subsequent chunks.
18876
18877 2009-10-29 Paul Pluzhnikov <ppluzhnikov@google.com>
18878
18879 * configure.ac: New --with-libthread-db option.
18880 * thread-db.c: Allow direct dependence on libthread_db.
18881 (thread_db_free): Adjust.
18882 * config.in: Regenerate.
18883 * configure: Likewise.
18884
18885 2009-10-28 Paul Pluzhnikov <ppluzhnikov@google.com>
18886
18887 PR gdb/10757
18888 * thread-db.c (attach_thread): New function.
18889 (maybe_attach_thread): Return success/failure.
18890 (find_new_threads_callback): Adjust.
18891 (thread_db_find_new_threads): Loop until no new threads.
18892
18893 2009-10-13 Pedro Alves <pedro@codesourcery.com>
18894
18895 * proc-service.c (ps_lgetregs): Formatting.
18896
18897 2009-10-08 Paul Pluzhnikov <ppluzhnikov@google.com>
18898
18899 * acinclude.m4: (SRV_CHECK_THREAD_DB, SRV_CHECK_TLS_GET_ADDR): Remove.
18900 * configure.ac: Adjust.
18901 * linux-low.h (struct process_info_private): Move members to struct
18902 thread_db.
18903 (thread_db_free, thread_db_handle_monitor_command): New prototype.
18904 * linux-low.c (linux_remove_process): Adjust.
18905 (linux_wait_for_event_1, linux_look_up_symbols): Likewise.
18906 * server.c (handle_query): Move code ...
18907 (handle_monitor_command): ... here. New function.
18908 * target.h (struct target_ops): New member.
18909 * thread-db.c (struct thread_db): New.
18910 (libthread_db_search_path): New variable.
18911 (thread_db_create_event, thread_db_enable_reporting)
18912 (find_one_thread, maybe_attach_thread, find_new_threads_callback)
18913 (thread_db_find_new_threads, (thread_db_get_tls_address): Adjust.
18914 (try_thread_db_load_1, dladdr_to_soname): New functions.
18915 (try_thread_db_load, thread_db_load_search): New functions.
18916 (thread_db_init): Search for libthread_db.
18917 (thread_db_free): New function.
18918 (thread_db_handle_monitor_command): Likewise.
18919 * config.in: Regenerate.
18920 * configure: Regenerate.
18921
18922 2009-09-27 Ulrich Weigand <uweigand@de.ibm.com>
18923
18924 * spu-low.c (spu_kill): Wait for inferior to terminate.
18925 Call clear_inferiors.
18926 (spu_detach): Call clear_inferiors.
18927
18928 2009-08-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
18929
18930 * aclocal.m4: Regenerate.
18931 * config.in: Likewise.
18932 * configure: Likewise.
18933
18934 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
18935
18936 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Define.
18937 (parse_spufs_run): New function.
18938 (ppc_get_pc, ppc_set_pc): Detect and handle SPU PC.
18939 (ppc_breakpoint_at): Handle SPU breakpoints.
18940
18941 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
18942
18943 * linux-low.c: Include <sys/stat.h> and <sys/vfs.h>.
18944 (SPUFS_MAGIC): Define.
18945 (spu_enumerate_spu_ids): New function.
18946 (linux_qxfer_spu): New function.
18947 (linux_target_ops): Install linux_qxfer_spu.
18948
18949 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
18950
18951 * configure.srv (powerpc*-*-linux*): Add powerpc-cell32l.o
18952 and powerpc-cell64l.o to srv_regobj. Add rs6000/powerpc-cell32l.xml
18953 and rs6000/powerpc-cell64l.xml to srv_xmlfiles.
18954 * Makefile.in (powerpc-cell32l.o, powerpc-cell32l.c): New rules.
18955 (powerpc-cell64l.o, powerpc-cell64l.c): Likewise.
18956 (clean): Handle powerpc-cell32l.c and powerpc-cell64l.c.
18957 * linux-ppc-low.c (PPC_FEATURE_CELL): Define.
18958 (init_registers_powerpc_cell32l): Add prototype.
18959 (init_registers_powerpc_cell64l): Likewise.
18960 (ppc_arch_setup): Detect Cell/B.E. architecture.
18961
18962 2009-07-30 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
18963
18964 * Makefile.in (datarootdir): New variable.
18965
18966 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
18967
18968 * linux-low.c (linux_write_memory): Update debugging output.
18969 * Makefile.in (clean): Add new descriptions.
18970 (arm-with-vfpv2.o, arm-with-vfpv2.c, arm-with-vfpv3.o)
18971 (arm-with-vfpv3.c, arm-with-neon.o, arm-with-neon.c): New rules.
18972 * configure.srv: Add new files for arm*-*-linux*.
18973 * linux-arm-low.c: Add new declarations.
18974 (PTRACE_GETVFPREGS, PTRACE_SETVFPREGS): Define if undefined.
18975 (arm_hwcap, HWCAP_VFP, HWCAP_IWMMXT, HWCAP_NEON, HWCAP_VFPv3)
18976 (HWCAP_VFPv3D16): New.
18977 (arm_fill_wmmxregset, arm_store_wmmxregset): Check HWCAP_IWMMXT
18978 instead of __IWMMXT__.
18979 (arm_fill_vfpregset, arm_store_vfpregset, arm_get_hwcap)
18980 (arm_arch_setup): New.
18981 (target_regsets): Remove #ifdef. Add VFP regset.
18982 (the_low_target): Use arm_arch_setup.
18983
18984 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
18985
18986 * linux-low.c (linux_kill_one_lwp): Adjust kernel workaround to skip
18987 the main thread again.
18988
18989 2009-07-06 Aleksandar Ristovski <aristovski@qnx.com>
18990
18991 Adding Neutrino gdbserver.
18992 * configure: Regenerated.
18993 * configure.ac: Add case for srv_qnx and set LIBS accordingly.
18994 * configure.srv (i[34567]86-*-nto*): New target.
18995 * nto-low.c, nto-low.h, nto-x86-low.c: New files.
18996 * remote-utils.c [__QNX__]: Include sys/iomgr.h
18997 (nto_comctrl) [__QNX__]: New function.
18998 (enable_async_io, disable_async_io) [__QNX__]: Call nto_comctrl.
18999
19000 2009-07-05 Danny Backx <dannybackx@users.sourceforge.net>
19001
19002 * configure.srv (i[34567]86-*-mingw32ce*): Add i386-low.o to
19003 srv_tgtobj.
19004
19005 2009-07-04 Danny Backx <dannybackx@users.sourceforge.net>
19006 Pedro Alves <pedro@codesourcery.com>
19007
19008 * win32-i386-low.c (i386_get_thread_context): Handle systems that
19009 don't support CONTEXT_EXTENDED_REGISTERS.
19010 (i386_win32_breakpoint, i386_win32_breakpoint_len): New.
19011 (the_low_target): Install them.
19012 * win32-low.c (get_child_debug_event): Handle WaitForDebugEvent
19013 failing with ERROR_PIPE_NOT_CONNECTED.
19014
19015 2009-06-30 Doug Evans <dje@google.com>
19016 Pierre Muller <muller@ics.u-strasbg.fr>
19017
19018 Add h/w watchpoint support to x86-linux, win32-i386.
19019 * Makefile.in (SFILES): Add i386-low.c
19020 (i386_low_h): Define.
19021 (i386-low.o): Add dependencies.
19022 (linux-x86-low.o): Add i386-low.h dependency.
19023 (win32-i386-low.o): Ditto.
19024 * i386-low.c: New file.
19025 * i386-low.h: New file.
19026 * configure.srv (i[34567]86-*-cygwin*): Add i386-low.o to srv_tgtobj.
19027 (i[34567]86-*-linux*, i[34567]86-*-mingw*, x86_64-*-linux*): Ditto.
19028 * linux-low.c (linux_add_process): Initialize arch_private.
19029 (linux_remove_process): Free arch_private.
19030 (add_lwp): Initialize arch_private.
19031 (delete_lwp): Free arch_private.
19032 (linux_resume_one_lwp): Call the_low_target.prepare_to_resume if
19033 provided.
19034 * linux-low.h (process_info_private): New member arch_private.
19035 (lwp_info): New member arch_private.
19036 (linux_target_ops): New members new_process, new_thread,
19037 prepare_to_resume.
19038 (ptid_of): New macro.
19039 * linux-x86-low.c: Include stddef.h, i386-low.h.
19040 (arch_process_info): New struct.
19041 (arch_lwp_info): New struct.
19042 (x86_linux_dr_get, x86_linux_dr_set): New functions.
19043 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
19044 (i386_dr_low_get_status): New function.
19045 (x86_insert_point, x86_remove_point): New functions.
19046 (x86_stopped_by_watchpoint): New function.
19047 (x86_stopped_data_address): New function.
19048 (x86_linux_new_process, x86_linux_new_thread): New functions.
19049 (x86_linux_prepare_to_resume): New function.
19050 (the_low_target): Add entries for insert_point, remove_point,
19051 stopped_by_watchpoint, stopped_data_address, new_process, new_thread,
19052 prepare_to_resume.
19053 * server.c (debug_hw_points): New global.
19054 (monitor_show_help): Document set debug-hw-points.
19055 (handle_query): Process "set debug-hw-points".
19056 * server.h (debug_hw_points): Declare.
19057 (paddress): Declare.
19058 * utils.c (NUMCELLS, CELLSIZE): New macros.
19059 (get_sell, xsnprintf, paddress): New functions.
19060 * win32-arm-low.c (the_low_target): Add entries for insert_point,
19061 remove_point, stopped_by_watchpoint, stopped_data_address.
19062 * win32-i386-low.c: Include i386-low.h.
19063 (debug_reg_state): Replaces dr.
19064 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
19065 (i386_dr_low_get_status): New function.
19066 (i386_insert_point, i386_remove_point): New functions.
19067 (i386_stopped_by_watchpoint): New function.
19068 (i386_stopped_data_address): New function.
19069 (i386_initial_stuff): Update.
19070 (get_thread_context,set_thread_context,i386_thread_added): Update.
19071 (the_low_target): Add entries for insert_point,
19072 remove_point, stopped_by_watchpoint, stopped_data_address.
19073 * win32-low.c (win32_insert_watchpoint): New function.
19074 (win32_remove_watchpoint): New function.
19075 (win32_stopped_by_watchpoint): New function.
19076 (win32_stopped_data_address): New function.
19077 (win32_target_ops): Add entries for insert_watchpoint,
19078 remove_watchpoint, stopped_by_watchpoint, stopped_data_address.
19079 * win32-low.h (win32_target_ops): New members insert_point,
19080 remove_point, stopped_by_watchpoint, stopped_data_address.
19081
19082 2009-06-25 Pedro Alves <pedro@codesourcery.com>
19083
19084 * server.c (process_serial_event): Re-return unsupported, not
19085 error, if the type isn't recognized. Re-allow supporting only
19086 insert or remove packets. Also call require_running for
19087 breakpoints. Add missing break statement to default case. Tidy.
19088 * target.h (struct target_ops): Rename insert_watchpoint to
19089 insert_point, and remove_watchpoint to remove_point.
19090
19091 * linux-low.h (struct linux_target_ops): Likewise.
19092 * linux-low.c (linux_insert_watchpoint): Rename to ...
19093 (linux_insert_point): ... this. Adjust.
19094 (linux_remove_watchpoint): Rename to ...
19095 (linux_remove_point): ... this. Adjust.
19096 (linux_target_ops): Adjust.
19097 * linux-crisv32-low.c (cris_insert_watchpoint): Rename to ...
19098 (cris_insert_point): ... this.
19099 (cris_remove_watchpoint): Rename to ...
19100 (cris_remove_point): ... this.
19101 (the_low_target): Adjust.
19102
19103 2009-06-24 Pierre Muller <muller@ics.u-strasbg.fr>
19104
19105 * server.c (handle_v_kill): Pass signal_pid to
19106 kill_inferior if multi_process is zero.
19107
19108 2009-06-23 Aleksandar Ristovski <aristovski@qnx.com>
19109
19110 * server.c (process_serial_event): Add support for Z0 and Z1 packet.
19111 * target.h (target_ops): Comment for *_watchpoint to make it clear
19112 the functions can get types '0' and '1'.
19113
19114 2009-06-22 Aleksandar Ristovski <aristovski@qnx.com>
19115
19116 * linux-low.c (usr_fetch_inferior_registers): Remove check for regno 0.
19117 * proc-service.c (ps_lgetregs): Pass -1 to fetch all registers.
19118 * regcache.c (get_regcache): Likewise.
19119 * spu-low.c (spu_fetch_registers): Remove 0 to -1 conversion.
19120 * win32-low.c (child_fetch_inferior_registers): Remove check for
19121 regno 0.
19122
19123 2009-06-19 Aleksandar Ristovski <aristovski@qnx.com>
19124 Pedro Alves <pedro@codesourcery.com>
19125
19126 * target.h (struct target_ops) <supports_multi_process>: New
19127 callback.
19128 (target_supports_multi_process): New.
19129 * server.c (handle_query): Even if GDB reports support, only
19130 enable multi-process if the target also supports it. Report
19131 multi-process support only if the target backend supports it.
19132 * linux-low.c (linux_supports_multi_process): New function.
19133 (linux_target_ops): Install it as target_supports_multi_process
19134 callback.
19135
19136 2009-05-24 Doug Evans <dje@google.com>
19137
19138 Global renaming of find_thread_pid to find_thread_ptid.
19139 * server.h (find_thread_ptid): Renamed from find_thread_pid.
19140 * inferiors.c (find_thread_ptid): Renamed from find_thread_pid.
19141 All callers updated.
19142
19143 * linux-low.c (handle_extended_wait): Use linux_resume_one_lwp
19144 to resume the newly created thread, don't call ptrace (PTRACE_CONT)
19145 directly.
19146
19147 * linux-low.c (get_stop_pc): Print pc if debug_threads.
19148 (check_removed_breakpoint, linux_wait_for_lwp): Ditto.
19149 (linux_resume_one_lwp): Ditto.
19150
19151 2009-05-23 Doug Evans <dje@google.com>
19152
19153 * linux-low.c (linux_resume_one_lwp): Change type of first arg
19154 from struct inferior_list_entry * to struct lwp_info *.
19155 All callers updated.
19156
19157 2009-05-13 Doug Evans <dje@google.com>
19158
19159 * linux-x86-low.c: Don't include assert.h.
19160 (x86_siginfo_fixup): Use fatal, not assert.
19161 (x86_arch_setup): Fix comment.
19162
19163 2009-05-12 Doug Evans <dje@google.com>
19164
19165 Biarch support for i386/amd64 gdbserver.
19166 * Makefile.in (SFILES): Remove linux-i386-low.c, linux-x86-64-low.c.
19167 Add linux-x86-low.c.
19168 (linux-i386-low.o, linux-x86-64-low.o): Delete.
19169 (linux-x86-low.o): Add.
19170 * linux-x86-64-low.c: Delete.
19171 * linux-i386-low.c: Delete.
19172 * linux-x86-low.c: New file.
19173 * configure.srv (i?86-linux srv_tgtobj): Replace linux-i386-low.o with
19174 linux-x86-low.o.
19175 (x86_64-linux srv_tgtobj): Replace linux-x86-64-low.o with
19176 linux-x86-low.o.
19177 (x86_64-linux srv_regobj): Add reg-i386-linux.o.
19178 * linux-low.c: Include ansidecl.h, elf/common.h, elf/external.h.
19179 (linux_child_pid_to_exec_file): New function.
19180 (elf_64_header_p, elf_64_file_p): New functions.
19181 (siginfo_fixup): New function.
19182 (linux_xfer_siginfo): New local inf_siginfo. Call siginfo_fixup to
19183 give target a chance to convert layout.
19184 * linux-low.h (linux_target_ops): New member siginfo_fixup.
19185 (linux_child_pid_to_exec_file, elf_64_file_p): Declare.
19186
19187 2009-05-07 Doug Evans <dje@google.com>
19188
19189 * linux-low.c (regsets_fetch_inferior_registers): Fix memory leak.
19190 (regsets_store_inferior_registers): Ditto.
19191
19192 2009-05-06 Pedro Alves <pedro@codesourcery.com>
19193
19194 PR server/10048
19195
19196 * linux-low.c (must_set_ptrace_flags): Delete.
19197 (linux_create_inferior): Set `lwp->must_set_ptrace_flags' instead
19198 of the global.
19199 (linux_attach_lwp_1): Don't set PTRACE_SETOPTIONS here. Set
19200 `lwp->must_set_ptrace_flags' instead.
19201 (linux_wait_for_event_1): Set ptrace options here.
19202 (linux_wait_1): ... not here.
19203
19204 2009-04-30 Doug Evans <dje@google.com>
19205
19206 * inferiors.c (started_inferior_callback): New function.
19207 (attached_inferior_callback): New function.
19208 (have_started_inferiors_p, have_attached_inferiors_p): New functions.
19209 * server.c (print_started_pid, print_attached_pid): New functions.
19210 (detach_or_kill_for_exit): New function.
19211 (main): Call it instead of for_each_inferior (kill_inferior_callback).
19212 * server.h (have_started_inferiors_p): Declare.
19213 (have_attached_inferiors_p): Declare.
19214
19215 * inferiors.c (remove_process): Fix memory leak, free process.
19216 * linux-low.c (linux_remove_process): New function.
19217 (linux_kill): Call it instead of remove_process.
19218 (linux_detach, linux_wait_1): Ditto.
19219
19220 2009-04-19 Danny Backx <dannybackx@users.sourceforge.net>
19221
19222 * configure.srv: Add x86 Windows CE target.
19223
19224 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
19225
19226 * inferiors.c (get_thread_process): Make global.
19227 * server.h (get_thread_process): Add prototype.
19228 * thread-db.c (find_one_thread): Use get_thread_process
19229 instead of current_process.
19230 (thread_db_get_tls_address): Do not crash if called when
19231 thread layer is not yet initialized.
19232
19233 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
19234
19235 * remote-utils.c (prepare_resume_reply): Null-terminate packet.
19236 * spu-low.c (current_tid): Rename to ...
19237 (current_ptid): ... this.
19238 (fetch_ppc_register, fetch_ppc_memory, store_ppc_memory,
19239 spu_proc_xfer_spu, spu_resume, spu_request_interrupt): Use
19240 ptid_get_lwp (current_ptid) instead of current_tid.
19241 (spu_kill, spu_detach, spu_join, spu_wait): Use pid argument
19242 instead of current_tid. Use find_process_pid to verify pid
19243 argument is valid. Pass proper argument to remove_process.
19244 (spu_thread_alive): Compare current_ptid instead of current_tid.
19245 (spu_resume): Likewise.
19246
19247 2009-04-02 Pedro Alves <pedro@codesourcery.com>
19248
19249 * linux-low.c (usr_store_inferior_registers): Declare local `pid'
19250 variable.
19251
19252 2009-04-01 Pedro Alves <pedro@codesourcery.com>
19253
19254 Implement the multiprocess extensions, and add linux multiprocess
19255 support.
19256
19257 * server.h (ULONGEST): Declare.
19258 (struct ptid, ptid_t): New.
19259 (minus_one_ptid, null_ptid): Declare.
19260 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
19261 (ptid_get_tid, ptid_equal, ptid_is_pid): Declare.
19262 (struct inferior_list_entry): Change `id' type from unsigned from
19263 to ptid_t.
19264 (struct sym_cache, struct breakpoint, struct
19265 process_info_private): Forward declare.
19266 (struct process_info): Declare.
19267 (current_process): Declare.
19268 (all_processes): Declare.
19269 (initialize_inferiors): Declare.
19270 (add_thread): Adjust to use ptid_t.
19271 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): Ditto.
19272 (add_process, remove_process, find_thread_pid): Declare.
19273 (find_inferior_id): Adjust to use ptid_t.
19274 (cont_thread, general_thread, step_thread): Change type to ptid_t.
19275 (multi_process): Declare.
19276 (push_event): Adjust to use ptid_t.
19277 (read_ptid, write_ptid): Declare.
19278 (prepare_resume_reply): Adjust to use ptid_t.
19279 (clear_symbol_cache): Declare.
19280 * inferiors.c (all_processes): New.
19281 (null_ptid, minus_one_ptid): New.
19282 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
19283 (ptid_get_tid, ptid_equal, ptid_is_pid): New.
19284 (add_thread): Change unsigned long to ptid. Remove gdb_id
19285 parameter. Adjust.
19286 (thread_id_to_gdb_id, thread_to_gdb_id): Change unsigned long to ptid.
19287 (gdb_id_to_thread): Rename to ...
19288 (find_thread_pid): ... this. Change unsigned long to ptid.
19289 (gdb_id_to_thread_id, find_inferior_id): Change unsigned long to ptid.
19290 (loaded_dll, pull_pid_from_list): Adjust.
19291 (add_process, remove_process, find_process_pid)
19292 (get_thread_process, current_process, initialize_inferiors): New.
19293 * target.h (struct thread_resume) <thread>: Change type to ptid_t.
19294 (struct target_waitstatus) <related_pid>: Ditto.
19295 (struct target_ops) <kill, detach>: Add `pid' argument. Change
19296 return type to int.
19297 (struct target_ops) <join>: Add `pid' argument.
19298 (struct target_ops) <thread_alive>: Change pid's type to ptid_t.
19299 (struct target_ops) <wait>: Add `ptid' field. Change return type
19300 to ptid.
19301 (kill_inferior, detach_inferior, join_inferior): Add `pid' argument.
19302 (mywait): Add `ptid' argument. Change return type to ptid_t.
19303 (target_pid_to_str): Declare.
19304 * target.c (set_desired_inferior): Adjust to use ptids.
19305 (mywait): Add new `ptid' argument. Adjust.
19306 (target_pid_to_str): New.
19307 * mem-break.h (free_all_breakpoints): Declare.
19308 * mem-break.c (breakpoints): Delelete.
19309 (set_breakpoint_at, delete_breakpoint, find_breakpoint_at)
19310 (check_mem_read, check_mem_write, delete_all_breakpoints): Adjust
19311 to use per-process breakpoint list.
19312 (free_all_breakpoints): New.
19313 * remote-utils.c (struct sym_cache) <name>: Drop `const'.
19314 (symbol_cache, all_symbols_looked_up): Delete.
19315 (hexchars): New.
19316 (ishex, unpack_varlen_hex, write_ptid, hex_or_minus_one,
19317 read_ptid): New.
19318 (prepare_resume_reply): Change ptid argument's type from unsigned
19319 long to ptid_t. Adjust. Implement W;process and X;process.
19320 (free_sym_cache, clear_symbol_cache): New.
19321 (look_up_one_symbol): Adjust to per-process symbol cache. *
19322 * server.c (cont_thread, general_thread, step_thread): Change type
19323 to ptid_t.
19324 (attached): Delete.
19325 (multi_process): New.
19326 (last_ptid): Change type to ptid_t.
19327 (struct vstop_notif) <ptid>: Change type to ptid_t.
19328 (queue_stop_reply, push_event): Change `ptid' argument's type to
19329 ptid_t.
19330 (discard_queued_stop_replies): Add `pid' argument.
19331 (start_inferior): Adjust to use ptids. Adjust to mywait interface
19332 changes. Don't reference the `attached' global.
19333 (attach_inferior): Adjust to mywait interface changes.
19334 (handle_query): Adjust to use ptids. Parse GDB's qSupported
19335 features. Handle and report "multiprocess+". Handle
19336 "qAttached:PID".
19337 (handle_v_cont): Adjust to use ptids. Adjust to mywait interface
19338 changes.
19339 (handle_v_kill): New.
19340 (handle_v_stopped): Adjust to use target_pid_to_str.
19341 (handle_v_requests): Allow multiple attaches and runs when
19342 multiprocess extensions are in effect. Handle "vKill".
19343 (myresume): Adjust to use ptids.
19344 (queue_stop_reply_callback): Add `arg' parameter. Handle it.
19345 (handle_status): Adjust to discard_queued_stop_replies interface
19346 change.
19347 (first_thread_of, kill_inferior_callback)
19348 (detach_or_kill_inferior_callback, join_inferiors_callback): New.
19349 (main): Call initialize_inferiors. Adjust to use ptids, killing
19350 and detaching from all inferiors. Handle multiprocess packet
19351 variants.
19352 * linux-low.h: Include gdb_proc_service.h.
19353 (struct process_info_private): New.
19354 (struct linux_target_ops) <pid_of>: Use ptid_get_pid.
19355 <lwpid_of>: Use ptid_get_lwp.
19356 (get_lwp_thread): Adjust.
19357 (struct lwp_info): Add `dead' member.
19358 (find_lwp_pid): Declare.
19359 * linux-low.c (thread_db_active): Delete.
19360 (new_inferior): Adjust comment.
19361 (inferior_pid): Delete.
19362 (linux_add_process): New.
19363 (handle_extended_wait): Adjust.
19364 (add_lwp): Change unsigned long to ptid.
19365 (linux_create_inferior): Add process to processes table. Adjust
19366 to use ptids. Don't set new_inferior here.
19367 (linux_attach_lwp): Rename to ...
19368 (linux_attach_lwp_1): ... this. Add `initial' argument. Handle
19369 it. Adjust to use ptids.
19370 (linux_attach_lwp): New.
19371 (linux_attach): Add process to processes table. Don't set
19372 new_inferior here.
19373 (struct counter): New.
19374 (second_thread_of_pid_p, last_thread_of_process_p): New.
19375 (linux_kill_one_lwp): Add `args' parameter. Handle it. Adjust to
19376 multiple processes.
19377 (linux_kill): Add `pid' argument. Handle it. Adjust to multiple
19378 processes. Remove process from process table.
19379 (linux_detach_one_lwp): Add `args' parameter. Handle it. Adjust
19380 to multiple processes.
19381 (any_thread_of): New.
19382 (linux_detach): Add `pid' argument, and handle it. Remove process
19383 from processes table.
19384 (linux_join): Add `pid' argument. Handle it.
19385 (linux_thread_alive): Change unsighed long argument to ptid_t.
19386 Consider dead lwps as not being alive.
19387 (status_pending_p): Rename `dummy' argument to `arg'. Filter out
19388 threads we're not interested in.
19389 (same_lwp, find_lwp_pid): New.
19390 (linux_wait_for_lwp): Change `pid' argument's type from int to
19391 ptid_t. Adjust.
19392 (linux_wait_for_event): Rename to ...
19393 (linux_wait_for_event_1): ... this. Change `pid' argument's type
19394 from int to ptid_t. Adjust.
19395 (linux_wait_for_event): New.
19396 (linux_wait_1): Add `ptid' argument. Change return type to
19397 ptid_t. Adjust. Use last_thread_of_process_p. Remove processes
19398 that exit from the process table.
19399 (linux_wait): Add `ptid' argument. Change return type to ptid_t.
19400 Adjust.
19401 (mark_lwp_dead): New.
19402 (wait_for_sigstop): Adjust to use ptids. If a process exits while
19403 stopping all threads, mark its main lwp as dead.
19404 (linux_set_resume_request, linux_resume_one_thread): Adjust to use
19405 ptids.
19406 (fetch_register, usr_store_inferior_registers)
19407 (regsets_fetch_inferior_registers)
19408 (regsets_store_inferior_registers, linux_read_memory)
19409 (linux_write_memory): Inline `inferior_pid'.
19410 (linux_look_up_symbols): Adjust to use per-process
19411 `thread_db_active'.
19412 (linux_request_interrupt): Adjust to use ptids.
19413 (linux_read_auxv): Inline `inferior_pid'.
19414 (initialize_low): Don't reference thread_db_active.
19415 * gdb_proc_service.h (struct ps_prochandle) <pid>: Remove.
19416 * proc-service.c (ps_lgetregs): Use find_lwp_pid.
19417 (ps_getpid): Return the pid of the current inferior.
19418 * thread-db.c (proc_handle, thread_agent): Delete.
19419 (thread_db_create_event, thread_db_enable_reporting): Adjust to
19420 per-process data.
19421 (find_one_thread): Change argument type to ptid_t. Adjust to
19422 per-process data.
19423 (maybe_attach_thread): Adjust to per-process data and ptids.
19424 (thread_db_find_new_threads): Ditto.
19425 (thread_db_init): Ditto.
19426 * spu-low.c (spu_create_inferior, spu_attach): Add process to
19427 processes table. Adjust to use ptids.
19428 (spu_kill, spu_detach): Adjust interface. Remove process from
19429 processes table.
19430 (spu_join, spu_thread_alive): Adjust interface.
19431 (spu_wait): Adjust interface. Remove process from processes
19432 table. Adjust to use ptids.
19433 * win32-low.c (current_inferior_tid): Delete.
19434 (current_inferior_ptid): New.
19435 (debug_event_ptid): New.
19436 (thread_rec): Take a ptid. Adjust.
19437 (child_add_thread): Add `pid' argument. Adjust to use ptids.
19438 (child_delete_thread): Ditto.
19439 (do_initial_child_stuff): Add `attached' argument. Add process to
19440 processes table.
19441 (child_fetch_inferior_registers, child_store_inferior_registers):
19442 Adjust.
19443 (win32_create_inferior): Pass 0 to do_initial_child_stuff.
19444 (win32_attach): Pass 1 to do_initial_child_stuff.
19445 (win32_kill): Adjust interface. Remove process from processes
19446 table.
19447 (win32_detach): Ditto.
19448 (win32_join): Adjust interface.
19449 (win32_thread_alive): Take a ptid.
19450 (win32_resume): Adjust to use ptids.
19451 (get_child_debug_event): Ditto.
19452 (win32_wait): Adjust interface. Remove exiting process from
19453 processes table.
19454
19455 2009-04-01 Pedro Alves <pedro@codesourcery.com>
19456
19457 Non-stop mode support.
19458
19459 * server.h (non_stop): Declare.
19460 (gdb_client_data, handler_func): Declare.
19461 (delete_file_handler, add_file_handler, start_event_loop):
19462 Declare.
19463 (handle_serial_event, handle_target_event, push_event)
19464 (putpkt_notif): Declare.
19465 * target.h (enum resume_kind): New.
19466 (struct thread_resume): Replace `step' field by `kind' field.
19467 (TARGET_WNOHANG): Define.
19468 (struct target_ops) <wait>: Add `options' argument.
19469 <supports_non_stop, async, start_non_stop>: New fields.
19470 (target_supports_non_stop, target_async): New.
19471 (start_non_stop): Declare.
19472 (mywait): Add `options' argument.
19473 * target.c (mywait): Add `options' argument. Print child exit
19474 notifications here.
19475 (start_non_stop): New.
19476 * server.c (non_stop, own_buf, mem_buf): New globals.
19477 (struct vstop_notif): New.
19478 (notif_queue): New global.
19479 (queue_stop_reply, push_event, discard_queued_stop_replies)
19480 (send_next_stop_reply): New.
19481 (start_inferior): Adjust to use resume_kind. Adjust to mywait
19482 interface changes.
19483 (attach_inferior): In non-stop mode, don't wait for the target
19484 here.
19485 (handle_general_set): Handle QNonStop.
19486 (handle_query): When handling qC, return the current general
19487 thread, instead of the first thread of the list.
19488 (handle_query): If the backend supports non-stop mode, include
19489 QNonStop+ in the qSupported query response.
19490 (handle_v_cont): Adjust to use resume_kind. Handle resume_stop
19491 and non-stop mode.
19492 (handle_v_attach, handle_v_run): Handle non-stop mode.
19493 (handle_v_stopped): New.
19494 (handle_v_requests): Report support for vCont;t. Handle vStopped.
19495 (myresume): Adjust to use resume_kind. Handle non-stop.
19496 (queue_stop_reply_callback): New.
19497 (handle_status): Handle non-stop mode.
19498 (main): Clear non_stop flag on reconnection. Use the event-loop.
19499 Refactor serial protocol handling from here ...
19500 (process_serial_event): ... to this new function. When GDB
19501 selects any thread, select one here. In non-stop mode, wait until
19502 GDB acks all pending events before exiting.
19503 (handle_serial_event, handle_target_event): New.
19504 * remote-utils.c (remote_open): Install remote_desc in the event
19505 loop.
19506 (remote_close): Remove remote_desc from the event loop.
19507 (putpkt_binary): Rename to...
19508 (putpkt_binary_1): ... this. Add `is_notic' argument. Handle it.
19509 (putpkt_binary): New as wrapper around putpkt_binary_1.
19510 (putpkt_notif): New.
19511 (prepare_resume_reply): In non-stop mode, don't change the
19512 general_thread.
19513 * event-loop.c: New.
19514 * Makefile.in (OBJ): Add event-loop.o.
19515 (event-loop.o): New rule.
19516
19517 * linux-low.h (pid_of): Moved here.
19518 (lwpid_of): New.
19519 (get_lwp_thread): Use lwpid_of.
19520 (struct lwp_info): Delete `lwpid' field. Add `suspended' field.
19521 * linux-low.c (pid_of): Delete.
19522 (inferior_pid): Use lwpid_of.
19523 (linux_event_pipe): New.
19524 (target_is_async_p): New.
19525 (delete_lwp): New.
19526 (handle_extended_wait): Use lwpid_of.
19527 (add_lwp): Don't set lwpid field.
19528 (linux_attach_lwp): Adjust debug output. Use lwpid_of.
19529 (linux_kill_one_lwp): If killing a running lwp, stop it first.
19530 Use lwpid_of. Adjust to linux_wait_for_event interface changes.
19531 (linux_detach_one_lwp): If detaching from a running lwp, stop it
19532 first. Adjust to linux_wait_for_event interface changes. Use
19533 lwpid_of.
19534 (linux_detach): Don't delete the main lwp here.
19535 (linux_join): Use my_waitpid. Avoid signal_pid. Use lwpid_of.
19536 (status_pending_p): Don't consider explicitly suspended lwps.
19537 (linux_wait_for_lwp): Take an integer pid instead of a lwp_info
19538 pointer. Add OPTIONS argument. Change return type to int. Use
19539 my_waitpid instead of sleeping. Handle WNOHANG. Use lwpid_of.
19540 (linux_wait_for_event): Take an integer pid instead of a lwp_info
19541 pointer. Add status pointer argument. Return a pid instead of a
19542 status. Use lwpid_of. Adjust to linux_wait_for_lwp interface
19543 changes. In non-stop mode, don't switch to a random thread.
19544 (linux_wait): Rename to...
19545 (linux_wait_1): ... this. Add target_options argument, and handle
19546 it. Adjust to use resume_kind. Use lwpid_of. In non-stop mode,
19547 don't handle the continue thread. Handle TARGET_WNOHANG. Merge
19548 clean exit and signal exit code. Don't stop all threads in
19549 non-stop mode. In all-stop mode, only stop all threads when
19550 reporting a stop to GDB. Handle explicit thread stop requests.
19551 (async_file_flush, async_file_mark): New.
19552 (linux_wait): New.
19553 (send_sigstop): Use lwpid_of.
19554 (wait_for_sigstop): Use lwpid_of. Adjust to linux_wait_for_event
19555 interface changes. In non-stop mode, don't switch to a random
19556 thread.
19557 (linux_resume_one_lwp): Use lwpid_of.
19558 (linux_continue_one_thread, linux_queue_one_thread): Merge into ...
19559 (linux_resume_one_thread): ... this. Handle resume_stop. In
19560 non-stop mode, don't look for pending flag in all threads.
19561 (resume_status_pending_p): Don't consider explicitly suspended
19562 threads.
19563 (my_waitpid): Reimplement. Emulate __WALL.
19564 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
19565 Use lwpid_of.
19566 (sigchld_handler, linux_supports_non_stop, linux_async)
19567 (linux_start_non_stop): New.
19568 (linux_target_ops): Register linux_supports_non_stop, linux_async
19569 and linux_start_non_stop.
19570 (initialize_low): Install SIGCHLD handler.
19571 * thread-db.c (thread_db_create_event, find_one_thread)
19572 (thread_db_get_tls_address): Use lwpid_of.
19573 * win32-low.c (win32_detach): Adjust to use resume_kind.
19574 (win32_wait): Add `options' argument.
19575 * spu-low.c (spu_resume): Adjust to use resume_kind.
19576 (spu_wait): Add `options' argument.
19577
19578 2009-04-01 Pedro Alves <pedro@codesourcery.com>
19579
19580 Decouple target code from remote protocol.
19581
19582 * target.h (enum target_waitkind): New.
19583 (struct target_waitstatus): New.
19584 (struct target_ops) <wait>: Return an unsigned long. Take a
19585 target_waitstatus pointer instead of a char pointer.
19586 (mywait): Likewise.
19587 * target.c (mywait): Change prototype to return an unsigned long.
19588 Take a target_waitstatus pointer instead of a char pointer. Adjust.
19589 * server.h (thread_from_wait, old_thread_from_wait): Delete
19590 declarations.
19591 (prepare_resume_reply): Change prototype to take a
19592 target_waitstatus.
19593 * server.c (thread_from_wait, old_thread_from_wait): Delete.
19594 (last_status, last_ptid): New.
19595 (start_inferior): Remove "statusptr" argument. Adjust. Return a
19596 pid instead of a signal.
19597 (attach_inferior): Remove "status" and "signal" parameters.
19598 Adjust.
19599 (handle_query): For qGetTLSAddr, parse the thread id with strtol,
19600 not as an address.
19601 (handle_v_cont, handle_v_attach, handle_v_run, handle_v_kill)
19602 (handle_v_requests, myresume): Remove "status" and "signal"
19603 parameters. Adjust.
19604 (handle_status): New.
19605 (main): Delete local `status'. Adjust.
19606 * remote-utils.c: Include target.h.
19607 (prepare_resume_reply): Change prototype to take a
19608 target_waitstatus. Adjust.
19609
19610 * linux-low.c (linux_wait): Adjust to new target_ops->wait
19611 interface.
19612 * spu-low.c (spu_wait): Adjust.
19613 * win32-low.c (enum target_waitkind, struct target_waitstatus):
19614 Delete.
19615 (win32_wait): Adjust.
19616
19617 2009-04-01 Pedro Alves <pedro@codesourcery.com>
19618
19619 * target.h (struct thread_resume): Delete leave_stopped member.
19620 (struct target_ops): Add a `n' argument to the `resume' callback.
19621 * server.c (start_inferior): Adjust.
19622 (handle_v_cont, myresume): Adjust.
19623 * linux-low.c (check_removed_breakpoint): Adjust to resume
19624 interface change, and to removed leave_stopped field.
19625 (resume_ptr): Delete.
19626 (struct thread_resume_array): New.
19627 (linux_set_resume_request): Add new `arg' parameter. Adjust to
19628 resume interface change.
19629 (linux_continue_one_thread, linux_queue_one_thread)
19630 (resume_status_pending_p): Check if the resume field is NULL
19631 instead of checking the leave_stopped member.
19632 (linux_resume): Adjust to the target resume interface change.
19633 * spu-low.c (spu_resume): Adjust to the target resume interface
19634 change.
19635 * win32-low.c (win32_detach, win32_resume): Ditto.
19636
19637 2009-04-01 Pedro Alves <pedro@codesourcery.com>
19638
19639 * linux-low.c (linux_wait_for_event): Don't clear the `stepping'
19640 flag.
19641 (wait_for_sigstop): Don't leave a finished single-step SIGTRAP
19642 pending.
19643 (linux_continue_one_thread): Only preserve the stepping flag if
19644 there's a pending breakpoint.
19645
19646 2009-03-31 Pedro Alves <pedro@codesourcery.com>
19647
19648 * server.c (main): After the inferior having exited, call
19649 remote_close before exiting gdbserver.
19650
19651 2009-03-25 Thiago Jung Bauermann <bauerman@br.ibm.com>
19652
19653 Fix size of FPSCR in Power 7 processors.
19654 * linux-ppc-low.c (PPC_FEATURE_ARCH_2_05): Remove #define.
19655 (PPC_FEATURE_HAS_DFP): New #define.
19656 (ppc_arch_setup): Check for DFP feature instead of ISA 2.05 to decide on
19657 size of the FPSCR.
19658
19659 2009-03-23 Pedro Alves <pedro@codesourcery.com>
19660
19661 * server.c (handle_query) Whitespace and formatting.
19662
19663 2009-03-22 Pedro Alves <pedro@codesourcery.com>
19664
19665 * i387-fp.c, linux-arm-low.c, linux-cris-low.c,
19666 linux-crisv32-low.c, linux-i386-low.c, linux-low.c,
19667 linux-mips-low.c, linux-s390-low.c, linux-sparc-low.c,
19668 linux-x86-64-low.c, linux-xtensa-low.c, proc-service.c,
19669 regcache.c, remote-utils.c, server.c, spu-low.c, target.h,
19670 thread-db.c, win32-low.c, xtensa-xtregs.c, gdbreplay.c,
19671 Makefile.in, configure.ac: Fix whitespace throughout.
19672 * configure: Regenerate.
19673
19674 2009-03-22 Pedro Alves <pedro@codesourcery.com>
19675
19676 * inferiors.c (find_inferior): Make it safe for the callback
19677 function to delete the currently iterated inferior.
19678
19679 2009-03-22 Pedro Alves <pedro@codesourcery.com>
19680
19681 * Makefile.in (linuw_low_h): Move higher.
19682 (thread-db.o): Depend on $(linux_low_h).
19683
19684 2009-03-17 Pedro Alves <pedro@codesourcery.com>
19685
19686 Rename "process" to "lwp" throughout.
19687
19688 * linux-low.c (all_processes): Rename to...
19689 (all_lwps): ... this.
19690 (inferior_pid, handle_extended_wait, get_stop_pc): Adjust.
19691 (add_process): Rename to ...
19692 (add_lwp): ... this. Adjust.
19693 (linux_create_inferior): Adjust.
19694 (linux_attach_lwp): Adjust.
19695 (linux_attach): Adjust.
19696 (linux_kill_one_process): Rename to ...
19697 (linux_kill_one_lwp): ... this. Adjust.
19698 (linux_kill): Adjust.
19699 (linux_detach_one_process): Rename to ...
19700 (linux_detach_one_lwp): ... this. Adjust.
19701 (linux_detach): Adjust.
19702 (check_removed_breakpoint): Adjust.
19703 (status_pending_p): Adjust.
19704 (linux_wait_for_process): Rename to ...
19705 (linux_wait_for_lwp): ... this. Adjust.
19706 (linux_wait_for_event): Adjust.
19707 (send_sigstop): Adjust.
19708 (wait_for_sigstop): Adjust.
19709 (stop_all_processes): Rename to ...
19710 (stop_all_lwps): ... this.
19711 (linux_resume_one_process): Rename to ...
19712 (linux_resume_one_lwp): ... this. Adjust.
19713 (linux_set_resume_request, linux_continue_one_thread)
19714 (linux_queue_one_thread, resume_status_pending_p)
19715 (usr_store_inferior_registers, regsets_store_inferior_registers)
19716 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
19717 Adjust.
19718 * linux-low.h (get_process): Rename to ...
19719 (get_lwp): ... this. Adjust.
19720 (get_thread_process): Rename to ...
19721 (get_thread_lwp): ... this. Adjust.
19722 (get_process_thread): Rename to ...
19723 (get_lwp_thread): ... this. Adjust.
19724 (struct process_info): Rename to ...
19725 (struct lwp_info): ... this.
19726 (all_processes): Rename to ...
19727 (all_lwps): ... this.
19728 * proc-service.c (ps_lgetregs): Adjust.
19729 * thread-db.c (thread_db_create_event, find_one_thread)
19730 (maybe_attach_thread, thread_db_get_tls_address): Adjust.
19731
19732 2009-03-14 Pedro Alves <pedro@codesourcery.com>
19733
19734 * server.c (handle_query): Handle "qAttached".
19735
19736 2009-03-13 Nathan Sidwell <nathan@codesourcery.com>
19737
19738 * Makefile.in, hostio-errno.c, errno.c, xtensa-xtregs.c: Change to
19739 GPLv3, update license URL.
19740
19741 2009-03-01 Doug Evans <dje@google.com>
19742
19743 * Makefile.in (INCLUDE_CFLAGS): Add -I$(srcdir)/../common.
19744 (server_h): Add gdb_signals.h.
19745 (signals.o): Update.
19746 * server.h (target_signal_from_host,target_signal_to_host_p)
19747 (target_signal_to_host,target_signal_to_name): Moved to gdb_signals.h.
19748
19749 2009-02-14 Pierre Muller <muller@ics.u-strasbg.fr>
19750
19751 * remote-utils.c (getpkt): Also generate remote-debug
19752 information if noack_mode is set.
19753
19754 2009-02-06 Pedro Alves <pedro@codesourcery.com>
19755
19756 * server.c (handle_query): Report qXfer:siginfo:read and
19757 qXfer:siginfo:write as supported and handle them.
19758 * target.h (struct target_ops) <qxfer_siginfo>: New field.
19759 * linux-low.c (linux_xfer_siginfo): New.
19760 (linux_target_ops): Set it.
19761
19762 2009-01-26 Pedro Alves <pedro@codesourcery.com>
19763
19764 * server.c (gdbserver_usage): Mention --remote-debug.
19765 (main): Accept '--remote-debug' switch.
19766
19767 2009-01-18 Doug Evans <dje@google.com>
19768
19769 * regcache.c (new_register_cache): No need to check result of xcalloc.
19770 * server.c (handle_search_memory): Back out calls to xmalloc,
19771 result is checked and error is returned to user upon failure.
19772 (handle_query): Ditto. Add more checks for result of malloc.
19773 (handle_v_cont): Check result of malloc, report error back to
19774 user upon failure.
19775 (handle_v_run): Ditto. Call freeargv.
19776 * server.h (freeargv): Declare.
19777 * utils.c (freeargv): New fn.
19778
19779 2009-01-15 Doug Evans <dje@google.com>
19780
19781 * gdbreplay.c (perror_with_name): Make arg const char *.
19782 * server.h (target_signal_to_name): Make return type const char *.
19783 * thread-db.c (thread_db_err_str): Make return type const char *.
19784 * utils.c (perror_with_name): Make arg const char *.
19785
19786 2009-01-14 Pedro Alves <pedro@codesourcery.com>
19787
19788 * win32-low.c (get_child_debug_event): Issue a final DBG_CONTINUE
19789 when handling a EXIT_PROCESS_DEBUG_EVENT.
19790
19791 2009-01-06 Joel Brobecker <brobecker@adacore.com>
19792
19793 * gdbreplay.c (gdbreplay_version): Update copyright year.
19794 * server.c (gdbserver_version): Likewise.
19795
19796 2009-01-05 Doug Evans <dje@google.com>
19797
19798 * linux-low.c (linux_attach_lwp): Add some comments/fixmes.
19799 (handle_extended_wait): Improve comment.
19800
19801 2008-12-13 Doug Evans <dje@google.com>
19802
19803 * utils.c (xmalloc,xcalloc,xstrdup): New fns.
19804 * server.h (ATTR_MALLOC): New macro.
19805 (xmalloc,xcalloc,xstrdup): Declare.
19806 * hostio.c: Replace malloc,calloc,strdup with xmalloc,xcalloc,xstrdup.
19807 * inferiors.c: Ditto.
19808 * linux-low.c: Ditto.
19809 * mem-break.c: Ditto.
19810 * regcache.c: Ditto.
19811 * remote-utils.c: Ditto.
19812 * server.c: Ditto.
19813 * target.c: Ditto.
19814 * win32-low.c: Ditto.
19815
19816 2008-12-12 Doug Evans <dje@google.com>
19817
19818 * linux-low.c (linux_wait_for_process): Don't clobber current_inferior
19819 in debugging printf.
19820
19821 * linux-low.c (handle_extended_wait): Simplify, use my_waitpid.
19822
19823 2008-12-09 Doug Evans <dje@google.com>
19824
19825 * linux-low.h (struct process_info): Delete member tid, unused.
19826 * thread-db.c (find_one_thread): Update.
19827 (maybe_attach_thread): Update.
19828
19829 2008-12-02 Pedro Alves <pedro@codesourcery.com>
19830
19831 * target.h (struct target_ops): Add qxfer_osdata member.
19832 * linux-low.c: Include ctype.h and pwd.h and sys/types.h
19833 and dirent.h.
19834 (linux_qxfer_osdata): New functions.
19835 (linux_target_ops): Register linux_qxfer_osdata as qxfer_osdata
19836 callback.
19837 * server.c (handle_query): Handle "qXfer:osdata:read:".
19838 * remote-utils.c (buffer_grow, buffer_free, buffer_init, buffer_finish)
19839 (buffer_xml_printf): New functions.
19840 * server.h (struct buffer): New.
19841 (buffer_grow_str, buffer_grow_str0): New macros.
19842 (buffer_grow, buffer_free, buffer_init, buffer_finish)
19843 (buffer_xml_printf): Declare.
19844
19845 2008-11-24 Doug Evans <dje@google.com>
19846
19847 * Makefile.in (VERSION,DIST,LINT,LINTFLAGS): Delete, unused.
19848
19849 2008-11-24 Daniel Jacobowitz <dan@codesourcery.com>
19850
19851 * server.c (handle_v_run): Always use the supplied argument list.
19852
19853 2008-11-19 Bob Wilson <bob.wilson@acm.org>
19854
19855 * xtensa-xtregs.c (XTENSA_ELF_XTREG_SIZE): Change to 4.
19856 (xtensa_regmap_table): Add entry for scompare1.
19857
19858 2008-11-18 Thiago Jung Bauermann <bauerman@br.ibm.com>
19859
19860 * Makefile.in (powerpc-isa205-32l.o, powerpc-isa205-32l.c,
19861 powerpc-isa205-altivec32l.o, powerpc-isa205-altivec32l.c,
19862 powerpc-isa205-vsx32l.o, powerpc-isa205-vsx32l.c,
19863 powerpc-isa205-64l.o, powerpc-isa205-64l.c,
19864 powerpc-isa205-altivec64l.o, powerpc-isa205-altivec64l.c,
19865 powerpc-isa205-vsx64l.o, powerpc-isa205-vsx64l.c): New targets.
19866 * configure.srv (powerpc*-*-linux*): Add ISA 2.05 object files and
19867 XML target descriptions.
19868 * linux-ppc-low.c (ppc_arch_setup): Init registers with 64-bit FPSCR
19869 when inferior is running on an ISA 2.05 or later processor. Add
19870 special case to return offset for full 64-bit slot of FPSCR when
19871 in 32-bits.
19872
19873 2008-11-14 Daniel Gutson <dgutson@codesourcery.com>
19874
19875 * Makefile.in (SFILES, clean): Added sparc64 files.
19876 (reg-sparc64.o, reg-sparc64.c): New.
19877 * configure.srv (sparc*-*-linux*): New configuration.
19878 * linux-low.c (regsets_fetch_inferior_registers): Swap ptrace
19879 syscall arguments for SPARC.
19880 (regsets_store_inferior_registers): Likewise.
19881 * linux-sparc-low.c: New file.
19882
19883 2008-10-21 Doug Evans <dje@google.com>
19884
19885 * Makefile.in (BFD_DIR,BFD,BFD_SRC,BFD_CFLAGS): Delete.
19886 (READLINE_DIR,READLINE_DEP): Delete.
19887 (INTERNAL_CFLAGS): Update.
19888 (LINTFLAGS): Update.
19889
19890 2008-10-10 Pedro Alves <pedro@codesourcery.com>
19891
19892 * server.c (handle_v_run): If GDB didn't specify an argv, use the
19893 whole argv from the last run, not just argv[0].
19894
19895 2008-09-08 Pedro Alves <pedro@codesourcery.com>
19896
19897 * regcache.c (new_register_cache): Return NULL if the register
19898 cache size isn't known yet.
19899 (free_register_cache): Avoid dereferencing a NULL regcache.
19900
19901 2008-09-04 Daniel Jacobowitz <dan@codesourcery.com>
19902
19903 * configure.srv: Merge MIPS and MIPS64.
19904
19905 2008-08-24 Maciej W. Rozycki <macro@linux-mips.org>
19906
19907 * Makefile.in (uninstall): Apply $(EXEEXT) too.
19908
19909 2008-08-18 Luis Machado <luisgpm@br.ibm.com>
19910
19911 * Makefile.in: Add required vsx dependencies.
19912
19913 * linux-ppc-low: Define PPC_FEATURE_HAS_VSX.
19914 Declare init_registers_powerpc_vsx32l.
19915 Declare init_registers_powerpc_vsx64l.
19916 Define PTRACE_GETVSXREGS and PTRACE_SETVSXREGS.
19917 (ppc_arch_setup): Check for VSX in hwcap.
19918 (ppc_fill_vsxregset): New function.
19919 (ppc_store_vsxregset): New function.
19920 Add new VSX entry in regset_info target_regsets.
19921
19922 * configure.srv: Add new VSX dependencies.
19923
19924 2008-08-12 Pedro Alves <pedro@codesourcery.com>
19925
19926 * remote-utils.c (noack_mode, transport_is_reliable): New globals.
19927 (remote_open): Set or clear transport_is_reliable.
19928 (putpkt_binary): Don't expect acks in noack mode.
19929 (getpkt): Don't send ack/nac in noack mode.
19930 * server.c (handle_general_set): Handle QStartNoAckMode.
19931 (handle_query): If connected by tcp pass QStartNoAckMode+ in
19932 qSupported.
19933 (main): Reset noack_mode on every connection.
19934 * server.h (noack_mode): Declare.
19935
19936 2008-08-07 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
19937
19938 * Makefile.in (GDBREPLAY_OBS): New variable.
19939 (gdbreplay$(EXEEXT)): Use it to avoid unportable $^.
19940
19941 2008-08-05 Ulrich Weigand <uweigand@de.ibm.com>
19942 Daniel Jacobowitz <dan@codesourcery.com>
19943
19944 * linux-low.c (linux_resume_one_process): Ignore ESRCH.
19945 (usr_store_inferior_registers): Likewise.
19946 (regsets_store_inferior_registers): Likewise.
19947
19948 2008-07-31 Rolf Jansen <rj@surtec.com>
19949 Pedro Alves <pedro@codesourcery.com>
19950
19951 * configure.ac: Check for memmem declaration.
19952 * server.c [HAVE_MALLOC_H]: Include malloc.h.
19953 (disable_packet_vCont, disable_packet_Tthread, disable_packet_qC)
19954 (disable_packet_qfThreadInfo): Unconditionally compile.
19955 * server.h [!HAVE_DECL_MEMMEM]: Declare memmem.
19956 * configure, config.in: Regenerate.
19957
19958 2008-07-28 Doug Kwan <dougkwan@google.com>
19959
19960 * linux-low.c (sys/dir.h, sys/user.h): Remove includes.
19961 (linux_write_memory): Remove declaration of errno.
19962
19963 2008-07-12 Ulrich Weigand <uweigand@de.ibm.com>
19964
19965 * linux-low.c (handle_extended_wait): Do not use "status"
19966 variable uninitialized.
19967
19968 2008-07-07 Pedro Alves <pedro@codesourcery.com>
19969
19970 * server.c (handle_v_attach): Inhibit reporting dll changes.
19971
19972 2008-06-27 Pedro Alves <pedro@codesourcery.com>
19973
19974 * remote-utils.c (prepare_resume_reply): If requested, don't
19975 output "thread:TID" in the T stop reply.
19976
19977 * server.c (disable_packet_vCont, disable_packet_Tthread)
19978 (disable_packet_qC, disable_packet_qfThreadInfo): New globals.
19979 (handle_query): If requested, disable support for qC, qfThreadInfo
19980 and qsThreadInfo.
19981 (handle_v_requests): If requested, disable support for vCont.
19982 (gdbserver_show_disableable): New.
19983 (main): Handle --disable-packet and --disable-packet=LIST.
19984
19985 * server.h (disable_packet_vCont, disable_packet_Tthread)
19986 (disable_packet_qC, disable_packet_qfThreadInfo): Declare.
19987
19988 2008-06-20 Carlos O'Donell <carlos@codesourcery.com>
19989
19990 * server.c (gdbserver_usage): Mention --version.
19991
19992 2008-06-06 Daniel Jacobowitz <dan@codesourcery.com>
19993
19994 * Makefile.in (gdbreplay.o): New rule.
19995
19996 2008-06-06 Joseph Myers <joseph@codesourcery.com>
19997
19998 * gdbreplay.c (gdbreplay_version): Say gdbreplay in version
19999 message, not gdbserver.
20000
20001 2008-06-05 Vladimir Prus <vladimir@codesourcery.com>
20002 Nathan Sidwell <nathan@codesourcery.com>
20003 Joseph Myers <joseph@codesourcery.com>
20004
20005 * acinclude.m4: Include ../../config/acx.m4.
20006 * configure.ac: Use ACX_PKGVERSION and ACX_BUGURL.
20007 * configure, config.in: Regenerate.
20008 * Makefile.in (gdbreplay$(EXEEXT)): Add version.o.
20009 * server.c (gdbserver_version): Print PKGVERSION.
20010 (gdbsrever_usage): Add stream parameter. Print REPORT_BUGS_TO.
20011 (main): Adjust gdbserver_usage calls.
20012 * gdbreplay.c (version, host_name): Add declarations.
20013 (gdbreplay_version, gdbreplay_usage): New.
20014 (main): Accept --version and --help options.
20015
20016 2008-06-04 Daniel Jacobowitz <dan@codesourcery.com>
20017
20018 * linux-arm-low.c (thumb_breakpoint, thumb_breakpoint_len): New.
20019 (arm_breakpoint_at): Handle Thumb.
20020 (the_low_target): Add comment.
20021
20022 2008-05-29 Ulrich Weigand <uweigand@de.ibm.com>
20023
20024 * linux-ppc-low.c (ppc_collect_ptrace_register): Clear buffer.
20025
20026 2008-05-09 Doug Evans <dje@google.com>
20027
20028 * server.h (decode_search_memory_packet): Declare.
20029 * remote-utils.c (decode_search_memory_packet): New fn.
20030 * server.c (handle_search_memory_1): New fn.
20031 (handle_search_memory): New fn.
20032 (handle_query): Process qSearch:memory packets.
20033
20034 2008-05-08 Ulrich Weigand <uweigand@de.ibm.com>
20035
20036 * regcache.c (registers_length): Remove.
20037 (set_register_cache): Verify that PBUFSIZ is large enough to hold a
20038 full register packet.
20039 * regcache.h (registers_length): Remove prototype.
20040 * server.h (PBUFSIZ): Define to 16384.
20041
20042 2008-05-03 Ulrich Weigand <uweigand@de.ibm.com>
20043
20044 * configure.srv (powerpc*-*-linux*): Set srv_regobj to
20045 powerpc-32l.o, powerpc-altivec32l.o, powerpc-e500l.o,
20046 powerpc-64l.o, and powerpc-altivec64l.o.
20047 Remove rs6000/powerpc-32.xml, rs6000/powerpc-64.xml, and
20048 rs6000/powerpc-e500.xml; add rs6000/powerpc-32l.xml,
20049 rs6000/powerpc-altivec32l.xml, rs6000/powerpc-e500l.xml,
20050 rs6000/powerpc-64l.xml, rs6000/powerpc-altivec64l.xml,
20051 rs6000/power-linux.xml, and rs6000/power64-linux.xml
20052 to srv_xmlfiles.
20053
20054 * Makefile.in (reg-ppc.o, reg-ppc.c): Remove, replace by ...
20055 (powerpc-32l.o, powerpc-32l.c): ... these new rules.
20056 (powerpc-32.o, powerpc-32.c): Remove, replace by ...
20057 (powerpc-altivec32l.o, powerpc-altivec32l.c): ... these new rules.
20058 (powerpc-e500.o, powerpc-e500.c): Remove, replace by ...
20059 (powerpc-e500l.o, powerpc-e500l.c): ... these new rules.
20060 (reg-ppc64.o, reg-ppc64.c): Remove, replace by ...
20061 (powerpc-64l.o, powerpc-64l.c): ... these new rules.
20062 (powerpc-64.o, powerpc-64.c): Remove, replace by ...
20063 (powerpc-altivec64l.o, powerpc-altivec64l.c): ... these new rules.
20064 (clean): Update.
20065
20066 * linux-ppc-low.c (init_registers_ppc): Remove, replace by ...
20067 (init_registers_powerpc_32l): ... this new prototype.
20068 (init_registers_powerpc_32): Remove, replace by ...
20069 (init_registers_powerpc_altivec32l): ... this new prototype.
20070 (init_registers_powerpc_e500): Remove, replace by ...
20071 (init_registers_powerpc_e500l): ... this new prototype.
20072 (init_registers_ppc64): Remove, replace by ...
20073 (init_registers_powerpc_64l): ... this new prototype.
20074 (init_registers_powerpc_64): Remove, replace by ...
20075 (init_registers_powerpc_altivec64l): ... this new prototype.
20076 (ppc_num_regs): Set to 73.
20077 (PT_ORIG_R3, PT_TRAP): Define if necessary.
20078 (ppc_regmap, ppc_regmap_e500): Add values for orig_r3 and trap.
20079 (ppc_cannot_store_register): Handle orig_r3 and trap.
20080 (ppc_arch_setup): Update init_registers_... calls.
20081 (ppc_fill_gregset): Handle orig_r3 and trap.
20082
20083 * inferiors.c (clear_inferiors): Reset current_inferior.
20084
20085 2008-04-23 Paolo Bonzini <bonzini@gnu.org>
20086
20087 * acinclude.m4: Add override.m4.
20088 * configure: Regenerate.
20089
20090 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
20091
20092 * linux-ppc-low.c (ppc_arch_setup): Reset ppc_hwcap after the
20093 initial call to init_register_ppc64.
20094
20095 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
20096
20097 * configure.srv (powerpc64-*-linux*, powerpc-*-linux*): Merge into
20098 single powerpc*-*-linux* case.
20099 (s390-*-linux*, s390x-*-linux*): Merge into single s390*-*-linux* case.
20100
20101 2008-04-17 Ulrich Weigand <uweigand@de.ibm.com>
20102
20103 * configure.srv [powerpc64-*-linux*]: Remove powerpc-e500.o from
20104 srv_regobj. Remove rs6000/powerpc-e500.xml and rs6000/power-spe.xml
20105 from reg_xmlfiles.
20106 * linux-ppc-low.c: Include <elf.h>.
20107 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Define.
20108 (ppc_hwcap): New global variable.
20109 (ppc_regmap): Remove __SPE__ #ifdef sections.
20110 (ppc_regmap_e500): New global variable.
20111 (ppc_cannot_store_register): Update __SPE__ special case.
20112 (ppc_get_hwcap): New function.
20113 (ppc_arch_setup): Use it to determine whether inferior supports
20114 AltiVec or SPE registers. Set the_low_target.regmap if appropriate.
20115 (ppc_fill_vrregset, ppc_store_vrregset): Define unconditionally.
20116 Do not access registers if target does not support AltiVec.
20117 (ppc_fill_evrregset, ppc_store_evrregset): Define unconditionally.
20118 Do not access registers if target does not support SPE.
20119 (target_regsets): Unconditionally include AltiVec and SPE regsets.
20120
20121 2008-04-17 Daniel Jacobowitz <dan@codesourcery.com>
20122
20123 * linux-low.c (disabled_regsets, num_regsets): New.
20124 (use_regsets_p): Delete.
20125 (linux_wait_for_process): Clear disabled_regsets.
20126 (regsets_fetch_inferior_registers): Check and set it.
20127 (regsets_store_inferior_registers): Likewise.
20128 (linux_fetch_registers, linux_store_registers): Do not use
20129 use_regsets_p.
20130 (initialize_low): Allocate disabled_regsets.
20131
20132 2008-04-14 Daniel Jacobowitz <dan@codesourcery.com>
20133
20134 * Makefile.in (LIBOBJS): New.
20135 (OBS): Use LIBOBJS.
20136 (memmem.o): New rule.
20137 * configure.ac: Use AC_CONFIG_LIBOBJ_DIR and check for memmem.
20138 * configure: Regenerated.
20139
20140 2008-04-04 Ulrich Weigand <uweigand@de.ibm.com>
20141
20142 * server.c (handle_query): Never return "unsupported" for
20143 qXfer:features:read queries.
20144
20145 2008-03-27 Ulrich Weigand <uweigand@de.ibm.com>
20146
20147 * server.c (get_features_xml): Fix inverted condition.
20148 (handle_query): Always support qXfer:feature:read.
20149
20150 2008-03-10 Daniel Jacobowitz <dan@codesourcery.com>
20151
20152 * server.c (wrapper_argv): New.
20153 (start_inferior): Handle wrapper_argv. If set, expect an extra
20154 trap.
20155 (gdbserver_usage): Document --wrapper.
20156 (main): Parse --wrapper.
20157
20158 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
20159
20160 * configure.srv [powerpc64-*-linux*]: Add all files mentioned for
20161 powerpc-*-linux* to srv_regobj and reg_xmlfiles.
20162 * linux-ppc-low.c (ppc_get_pc): Support bi-arch operation.
20163 (ppc_set_pc): Likewise.
20164 (ppc_arch_setup): New function.
20165 (ppc_fill_gregset): Call ppc_collect_ptrace_register instead
20166 of collect_register.
20167 (the_low_target): Use ppc_arch_setup as arch_setup initializer.
20168
20169 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
20170
20171 * configure.srv [powerpc64-*-linux*]: Use linux-ppc-low.o
20172 instead of linux-ppc64-low.o.
20173 * linux-ppc64-low.c: Remove file.
20174 * Makefile.in (SFILES): Remove linux-ppc64-low.c.
20175 (linux-ppc64-low.o): Remove rule.
20176
20177 * linux-ppc-low.c (init_registers_ppc64): Add prototype.
20178 (init_registers_powerpc_64): Likewise.
20179 (ppc_regmap): Conditionally define depending on __powerpc64__.
20180 (ppc_cannot_store_register): Do not special-case "fpscr" when
20181 compiled on __powerpc64__.
20182 (ppc_collect_ptrace_register): New function.
20183 (ppc_supply_ptrace_register): New function.
20184 (ppc_breakpoint): Change type to "unsigned int".
20185 (ppc_breakpoint_at): Change type of "insn" to "unsigned int".
20186 (the_low_target): Conditionally provide initializers for the
20187 arch_setup member depending on __powerpc64__. Install
20188 collect_ptrace_register and supply_ptrace_register members.
20189
20190 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
20191
20192 * regcache.h (gdbserver_xmltarget): Add extern declaration.
20193 * server.c (gdbserver_xmltarget): Define.
20194 (get_features_xml): Use it to replace "target.xml" and arch_string.
20195
20196 * configure.srv: Remove srv_xmltarget. Add XML files that were
20197 mentioned there to srv_xmlfiles instead. Remove conditional tests
20198 on gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe; set
20199 srv_xmlfiles and srv_regobj to include all possible choices.
20200 * configure.ac (srv_xmltarget): Remove.
20201 (srv_xmlfiles): Do not add "target.xml".
20202 (gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe): Remove
20203 checks for supplementary target information.
20204 * configure: Regenerate.
20205 * Makefile.in (XML_TARGET): Remove.
20206 (target.xml): Remove rule.
20207 (clean): Do not clean up target.xml.
20208 (.PRECIOUS): Do not mention target.xml.
20209
20210 * target.h (struct target_ops): Remove arch_string member.
20211 * linux-low.c (linux_arch_string): Remove.
20212 (linux_target_ops): Remove arch_string initializer.
20213 * linux-low.h (struct linux_target_ops): Remove arch_string member.
20214 * linux-i386-low.c (the_low_target): Remove arch_string initializer.
20215 * linux-x86-64-low.c (the_low_target): Remove arch_string initializer.
20216 * spu-low.c (spu_arch_string): Remove.
20217 (spu_target_ops): Remove arch_string initializer.
20218 * win32-low.c (win32_arch_string): Remove.
20219 (win32_target_ops): Remove arch_string initializer.
20220 * win32-low.h (struct win32_target_ops): Remove arch_string member.
20221 * win32-arm-low.c (the_low_target): Remove arch_string initializer.
20222 * win32-i368-low.c (the_low_target): Remove arch_string initializer.
20223
20224 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
20225
20226 * linux-low.h (struct linux_target_ops): Replace left_pad_xfer field
20227 by collect_ptrace_register and supply_ptrace_register hooks.
20228 * linux-low.c (fetch_register): Use supply_ptrace_register callback
20229 instead of checking for the_low_target.left_pad_xfer.
20230 (usr_store_inferior_registers): Use collect_ptrace_register callback
20231 instead of checking for the_low_target.left_pad_xfer.
20232
20233 * linux-s390-low.c (s390_collect_ptrace_register): New function.
20234 (s390_supply_ptrace_register): Likewise.
20235 (s390_fill_gregset): Call s390_collect_ptrace_register.
20236 (the_low_target): Update.
20237
20238 * linux-ppc64-low.c (ppc_collect_ptrace_register): New function.
20239 (ppc_supply_ptrace_register): Likewise.
20240 (the_low_target): Update.
20241
20242 * linux-i386-low.c (the_low_target): Update.
20243 * linux-x86-64-low.c (the_low_target): Update.
20244
20245 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
20246
20247 * configure.srv [s390x-*-linux*]: Set srv_regobj to include both
20248 reg-s390.o and reg-s390x.o.
20249
20250 * linux-low.c (new_inferior): New global variable.
20251 (linux_create_inferior, linux_attach): Set it.
20252 (linux_wait_for_process): Call the_low_target.arch_setup after the
20253 target has stopped for the first time.
20254 (initialize_low): Do not call the_low_target.arch_setup.
20255
20256 * linux-s390-low.c (s390_get_pc): Support bi-arch operation.
20257 (s390_set_pc): Likewise.
20258 (s390_arch_setup): New function.
20259 (the_low_target): Use s390_arch_setup as arch_setup routine.
20260
20261 * regcache.c (realloc_register_cache): New function.
20262 (set_register_cache): Call it for each existing regcache.
20263
20264 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
20265
20266 * server.h (init_registers): Remove prototype.
20267
20268 * linux-low.h (struct linux_target_ops): Add arch_setup field.
20269 * linux-low.c (initialize_low): Call the_low_target.arch_setup ()
20270 instead of init_registers ().
20271 * linux-arm-low.c (init_registers_arm): Add prototype.
20272 (init_registers_arm_with_iwmmxt): Likewise.
20273 (the_low_target): Add initializer for arch_setup field.
20274 * linux-cris-low.c (init_registers_cris): Add prototype.
20275 (the_low_target): Add initializer for arch_setup field.
20276 * linux-crisv32-low.c (init_registers_crisv32): Add prototype.
20277 (the_low_target): Add initializer for arch_setup field.
20278 * linux-i386-low.c (init_registers_i386_linux): Add prototype.
20279 (the_low_target): Add initializer for arch_setup field.
20280 * linux-ia64-low.c (init_registers_ia64): Add prototype.
20281 (the_low_target): Add initializer for arch_setup field.
20282 * linux-m32r-low.c (init_registers_m32r): Add prototype.
20283 (the_low_target): Add initializer for arch_setup field.
20284 * linux-m68k-low.c (init_registers_m68k): Add prototype.
20285 (the_low_target): Add initializer for arch_setup field.
20286 * linux-mips-low.c (init_registers_mips_linux): Add prototype.
20287 (init_registers_mips64_linux): Likewise.
20288 (the_low_target): Add initializer for arch_setup field.
20289 * linux-ppc-low.c (init_registers_ppc): Add prototype.
20290 (init_registers_powerpc_32, init_registers_powerpc_e500): Likewise.
20291 (the_low_target): Add initializer for arch_setup field.
20292 * linux-ppc64-low.c (init_registers_ppc64): Add prototype.
20293 (init_registers_powerpc_64): Likewise.
20294 (the_low_target): Add initializer for arch_setup field.
20295 * linux-s390-low.c (init_registers_s390): Add prototype.
20296 (init_registers_s390x): Likewise.
20297 (the_low_target): Add initializer for arch_setup field.
20298 * linux-sh-low.c (init_registers_sh): Add prototype.
20299 (the_low_target): Add initializer for arch_setup field.
20300 * linux-x86-64-low.c (init_registers_x86_64_linux): Add prototype.
20301 (the_low_target): Add initializer for arch_setup field.
20302 * linux-xtensa-low.c (init_registers_xtensa): Add prototype.
20303 (the_low_target): Add initializer for arch_setup field.
20304
20305 * win32-low.h (struct win32_target_ops): Add arch_setup field.
20306 * win32-low.c (initialize_low): Call the_low_target.arch_setup ()
20307 instead of init_registers ().
20308 * win32-arm-low.c (init_registers_arm): Add prototype.
20309 (the_low_target): Add initializer for arch_setup field.
20310 * win32-i386-low.c (init_registers_i386): Add prototype.
20311 (the_low_target): Add initializer for arch_setup field.
20312
20313 * spu-low.c (init_registers_spu): Add prototype.
20314 (initialize_low): Call initialie_registers_spu () instead of
20315 initialize_registers ().
20316
20317 2008-02-19 Pedro Alves <pedro@codesourcery.com>
20318
20319 * server.c (handle_v_requests): When handling the vRun and vAttach
20320 packets, if already debugging a process, don't kill it. Return an
20321 error instead.
20322
20323 2008-02-17 Daniel Jacobowitz <dan@codesourcery.com>
20324
20325 * server.c (handle_query): Correct length check.
20326
20327 2008-02-14 Pedro Alves <pedro_alves@portugalmail.pt>
20328
20329 * win32-low.c (do_initial_child_stuff): Add process handle
20330 parameter. Set current_process_handle and current_process_id from the
20331 parameters. Clear globals.
20332 (win32_create_inferior): Don't set current_process_handle and
20333 current_process_id here. Instead pass them on the call to
20334 do_initial_child_stuff.
20335 (win32_attach): Likewise.
20336 (win32_clear_inferiors): New.
20337 (win32_kill): Don't close the current process handle or the
20338 current thread handle here. Instead call win32_clear_inferiors.
20339 (win32_detach): Don't open a new handle to the process. Call
20340 win32_clear_inferiors.
20341 (win32_join): Don't rely on current_process_handle; open a new
20342 handle using the process id.
20343 (win32_wait): Call win32_clear_inferiors when the inferior process
20344 has exited.
20345
20346 2008-02-14 Daniel Jacobowitz <dan@codesourcery.com>
20347
20348 * server.c (monitor_show_help): Add "exit".
20349
20350 2008-02-11 Maxim Grigoriev <maxim2405@gmail.com>
20351
20352 * Makefile.in (SFILES): Add linux-xtensa-low.c.
20353 (clean): Add reg-xtensa.c.
20354 (linux-xtensa-low.o, reg-xtensa.o, reg-xtensa.c): New dependencies.
20355 * configure.srv (xtensa*-*-linux*) New target.
20356 * linux-xtensa-low.c: New.
20357 * xtensa-xtregs.c: New.
20358
20359 2008-02-01 Pedro Alves <pedro_alves@portugalmail.pt>
20360
20361 * hostio.c: Don't include errno.h.
20362 (errno_to_fileio_errno): Move to hostio-errno.
20363 * hostio.c: (hostio_error): Remove the error parameter. Defer the
20364 error number outputting to the target->hostio_last_error callback.
20365 (hostio_packet_error): Use FILEIO_EINVAL directly.
20366 (handle_open, handle_pread, hostio_error, handle_unlink): Update
20367 calls to hostio_error.
20368 * hostio-errno.c: New.
20369 * server.h (hostio_last_error_from_errno): Declare.
20370 * target.h (target_ops): Add hostio_last_error member.
20371 * linux-low.c (linux_target_op): Register hostio_last_error_from_errno
20372 as hostio_last_error handler.
20373 * spu-low.c (spu_target_ops): Likewise.
20374 * win32-low.c [_WIN32_WCE] (win32_error_to_fileio_error)
20375 (wince_hostio_last_error): New functions.
20376 (win32_target_ops) [_WIN32_WCE]: Register wince_hostio_last_error
20377 as hostio_last_error handler.
20378 (win32_target_ops) [!_WIN32_WCE]: Register
20379 hostio_last_error_from_errno as hostio_last_error handler.
20380 * Makefile.in (SFILES): Add hostio.c and hostio-errno.c.
20381 (hostio-errno.o): New rule.
20382 * configure.ac (GDBSERVER_DEPFILES): Add $srv_hostio_err_objs.
20383 * configure.srv (srv_hostio_err_objs): New variable. Default to
20384 hostio-errno.o.
20385 (arm*-*-mingw32ce*): Set srv_hostio_err_objs to "".
20386 * configure: Regenerate.
20387
20388 2008-01-29 Daniel Jacobowitz <dan@codesourcery.com>
20389
20390 * linux-low.c (linux_attach_lwp): Do not _exit after errors.
20391 (linux_kill, linux_detach): Clean up the process list.
20392 * remote-utils.c (remote_open): Improve port number parsing.
20393 (putpkt_binary, input_interrupt): Only send interrupts if the target
20394 is running.
20395 * server.c (extended_protocol): Make static.
20396 (attached): Define earlier.
20397 (exit_requested, response_needed, program_argv): New variables.
20398 (target_running): New.
20399 (start_inferior): Clear attached here.
20400 (attach_inferior): Set attached here.
20401 (require_running): Define.
20402 (handle_query): Use require_running and target_running. Implement
20403 "monitor exit".
20404 (handle_v_attach, handle_v_run): New.
20405 (handle_v_requests): Use require_running. Handle vAttach and vRun.
20406 (gdbserver_usage): Update.
20407 (main): Redo argument parsing. Handle --debug and --multi. Handle
20408 --attach along with other options or after the port. Save
20409 program_argv. Support no initial program. Resynchronize
20410 communication with GDB after an error. Handle "monitor exit".
20411 Use require_running and target_running. Always allow the extended
20412 protocol. Do not error out for Hc0 or Hc-1. Do not automatically
20413 restart in extended mode.
20414 * README: Refer to the GDB manual. Update --attach usage.
20415
20416 2007-12-20 Andreas Schwab <schwab@suse.de>
20417
20418 * linux-low.c (STACK_SIZE): Define.
20419 (linux_tracefork_child): Use it. Use __clone2 on ia64.
20420 (linux_test_for_tracefork): Likewise.
20421
20422 2007-12-18 Daniel Jacobowitz <dan@codesourcery.com>
20423
20424 * linux-low.c (linux_wait_for_event): Update messages. Do not
20425 reinsert auto-delete breakpoints.
20426 * mem-break.c (struct breakpoint): Change return type of handler to
20427 int.
20428 (set_breakpoint_at): Update handler type.
20429 (reinsert_breakpoint_handler): Return 1 instead of calling
20430 delete_breakpoint.
20431 (reinsert_breakpoint_by_bp): Check for the original breakpoint before
20432 setting a new one.
20433 (check_breakpoints): Delete auto-delete breakpoints and return 2.
20434 * mem-break.h (set_breakpoint_at): Update handler type.
20435 * thread-db.c (thread_db_create_event, thread_db_create_event): Update.
20436 * win32-low.c (auto_delete_breakpoint): New.
20437 (get_child_debug_event): Use it.
20438
20439 2007-12-16 Daniel Jacobowitz <dan@codesourcery.com>
20440
20441 * configure.ac: Check for pread and pwrite.
20442 * hostio.c (handle_pread): Fall back to lseek and read.
20443 (handle_pwrite): Fall back to lseek and write.
20444 * config.in, configure: Regenerated.
20445
20446 2007-12-07 Daniel Jacobowitz <dan@codesourcery.com>
20447
20448 * server.c (myresume): Add own_buf argument.
20449 (main): Update calls.
20450
20451 2007-12-06 Daniel Jacobowitz <dan@codesourcery.com>
20452
20453 * linux-low.c (linux_wait, linux_resume): Do not handle async I/O.
20454 * remote-utils.c (remote_open): Do not call disable_async_io.
20455 (block_async_io): Delete.
20456 (unblock_async_io): Make static.
20457 (initialize_async_io): New.
20458 * server.c (handle_v_cont): Handle async I/O here.
20459 (myresume): Likewise. Move other common resume tasks here...
20460 (main): ... from here. Call initialize_async_io. Disable async
20461 I/O before the main loop.
20462 * server.h (initialize_async_io): Declare.
20463 (block_async_io, unblock_async_io): Delete prototypes.
20464 * spu-low.c (spu_resume, spu_wait): Do not handle async I/O here.
20465
20466 2007-12-06 Mick Davis <mickd@goanna.iinet.net.au>
20467
20468 * remote-utils.c (readchar): Allow binary data in received messages.
20469
20470 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
20471
20472 * win32-low.c (attaching): New global.
20473 (win32_create_inferior): Clear the `attaching' global.
20474 (win32_attach): Set the `attaching' global.
20475 (get_child_debug_event) [_WIN32_WCE]: Stop the inferior when
20476 attaching. Only set a breakpoint at the entry point if not
20477 attaching.
20478
20479 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
20480
20481 * server.c (main): Don't report dll events on the initial
20482 connection on attaches.
20483
20484 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
20485
20486 * server.c (main): Relax numerical bases supported for the pid of
20487 the --attach command line argument.
20488
20489 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
20490
20491 * win32-low.c (win32_attach): Call OpenProcess before
20492 DebugActiveProcess, not after. Add last error output to error
20493 call.
20494
20495 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
20496
20497 * win32-low.c (win32_get_thread_context)
20498 (win32_set_thread_context): New functions.
20499 (thread_rec): Use win32_get_thread_context.
20500 (continue_one_thread, win32_resume): Use win32_set_thread_context.
20501 * win32-low.h (win32_thread_info) [_WIN32_WCE]: Add `base_context'
20502 field.
20503
20504 2007-12-03 Leo Zayas
20505 Pedro Alves <pedro_alves@portugalmail.pt>
20506
20507 * win32-low.c (soft_interrupt_requested, faked_breakpoint): New
20508 global variables.
20509 (child_add_thread): Minor cleanup.
20510 (child_continue): Resume artificially suspended threads before
20511 calling ContinueDebugEvent.
20512 (suspend_one_thread): New.
20513 (fake_breakpoint_event): New.
20514 (get_child_debug_event): Change return type to int. Check here if
20515 gdb sent an interrupt request. If a soft interrupt was requested,
20516 fake a breakpoint event. Return 0 if there is no event to handle,
20517 and 1 otherwise.
20518 (win32_wait): Don't check here if gdb sent an interrupt request.
20519 Ensure there is a valid event to handle.
20520 (win32_request_interrupt): Add soft interruption method as last
20521 resort.
20522
20523 2007-12-03 Leo Zayas
20524 Pedro Alves <pedro_alves@portugalmail.pt>
20525
20526 * win32-low.h (win32_thread_info): Add descriptions to the
20527 structure members. Replace `suspend_count' counter by a
20528 `suspended' flag.
20529 * win32-low.c (thread_rec): Update condition of when to get the
20530 context from the inferior. Rely on ContextFlags being set if it
20531 has already been retrieved. Only suspend the inferior thread if
20532 we haven't already. Warn if that fails.
20533 (continue_one_thread): s/suspend_count/suspended/. Only call
20534 ResumeThread once. Warn if that fails.
20535
20536 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
20537
20538 * win32-low.c (win32_wait): Don't read from the inferior when it
20539 has already exited.
20540
20541 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
20542
20543 * Makefile.in (win32_low_h): New variable.
20544 (win32-low.o): Add dependency on $(win32_low_h).
20545 (win32-arm-low.o, win32-i386-low.o): New rules.
20546
20547 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
20548
20549 * hostio.c: Correct copyright year.
20550
20551 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
20552
20553 * Makefile.in (OBS): Add hostio.o.
20554 (hostio.o): New rule.
20555 * server.h (handle_vFile): Declare.
20556 * hostio.c: New file.
20557 * server.c (handle_v_requests): Take packet_len and new_packet_len
20558 for binary packets. Call handle_vFile.
20559 (main): Update call to handle_v_requests.
20560
20561 2007-11-05 Daniel Jacobowitz <dan@codesourcery.com>
20562
20563 * linux-low.c: Include <sched.h>.
20564
20565 2007-11-01 Daniel Jacobowitz <dan@codesourcery.com>
20566
20567 * linux-low.c (linux_tracefork_grandchild): New.
20568 (linux_tracefork_child): Use clone.
20569 (linux_test_for_tracefork): Use clone; allocate and free a stack.
20570
20571 2007-10-31 Joel Brobecker <brobecker@adacore.com>
20572
20573 * Makefile.in: Use $(SHELL) instead of "sh" to call regdat.sh.
20574
20575 2007-10-24 Daniel Jacobowitz <dan@codesourcery.com>
20576
20577 * linux-low.c (handle_extended_wait): Handle unexpected signals.
20578
20579 2007-10-23 Daniel Jacobowitz <dan@codesourcery.com>
20580
20581 * inferiors.c (change_inferior_id): Delete.
20582 (add_pid_to_list, pull_pid_from_list): New.
20583 * linux-low.c (PTRACE_SETOPTIONS, PTRACE_GETEVENTMSG)
20584 (PTRACE_O_TRACESYSGOOD, PTRACE_O_TRACEFORK, PTRACE_O_TRACEVFORK)
20585 (PTRACE_O_TRACECLONE, PTRACE_O_TRACEEXEC, PTRACE_O_TRACEVFORKDONE)
20586 (PTRACE_O_TRACEEXIT, PTRACE_EVENT_FORK, PTRACE_EVENT_VFORK)
20587 (PTRACE_EVENT_CLONE, PTRACE_EVENT_EXEC, PTRACE_EVENT_VFORK_DONE)
20588 (PTRACE_EVENT_EXIT, __WALL): Provide default definitions.
20589 (stopped_pids, thread_db_active, must_set_ptrace_flags): New variables.
20590 (using_threads): Always set to 1.
20591 (handle_extended_wait): New.
20592 (add_process): Do not set TID.
20593 (linux_create_inferior): Set must_set_ptrace_flags.
20594 (linux_attach_lwp): Remove TID argument. Do not check using_threads.
20595 Use PTRACE_SETOPTIONS. Call new_thread_notify. Update all callers.
20596 (linux_thread_alive): Rename TID argument to LWPID.
20597 (linux_wait_for_process): Handle unknown processes. Do not use TID.
20598 (linux_wait_for_event): Do not use TID or check using_threads. Update
20599 call to dead_thread_notify. Call handle_extended_wait.
20600 (linux_create_inferior): Use PTRACE_SETOPTIONS.
20601 (send_sigstop): Delete sigstop_sent.
20602 (wait_for_sigstop): Avoid TID.
20603 (linux_supports_tracefork_flag, linux_tracefork_child, my_waitpid)
20604 (linux_test_for_tracefork): New.
20605 (linux_lookup_signals): Use thread_db_active and
20606 linux_supports_tracefork_flag.
20607 (initialize_low): Use thread_db_active and linux_test_for_tracefork.
20608 * linux-low.h (get_process_thread): Avoid TID.
20609 (struct process_ifo): Move thread_known and tid to the end. Remove
20610 sigstop_sent.
20611 (linux_attach_lwp, thread_db_init): Update prototypes.
20612 * server.h (change_inferior_id): Delete prototype.
20613 (add_pid_to_list, pull_pid_from_list): New prototypes.
20614 * thread-db.c (thread_db_use_events): New.
20615 (find_first_thread): Rename to...
20616 (find_one_thread): ...this. Update callers and messages. Do not
20617 call fatal. Check thread_db_use_events. Do not call
20618 change_inferior_id or new_thread_notify.
20619 (maybe_attach_thread): Update. Do not call new_thread_notify.
20620 (thread_db_init): Set thread_db_use_events. Check use_events.
20621 * utils.c (fatal, warning): Correct message prefix.
20622
20623 2007-10-15 Daniel Jacobowitz <dan@codesourcery.com>
20624
20625 * Makefile.in (clean): Remove new files.
20626 (powerpc-32.o, powerpc-32.c, powerpc-e500.o, powerpc-e500.c)
20627 (powerpc-64.o, powerpc-64.c): New rules.
20628 * configure.srv: Use alternate register sets for powerpc64-*-linux*
20629 with AltiVec, powerpc-*-linux* with AltiVec, and powerpc-*-linux*
20630 with SPE.
20631 * linux-ppc-low.c (ppc_regmap): Do not fetch the FP registers for
20632 SPE targets.
20633 (ppc_cannot_store_register): Do not check for FPSCR for SPE targets.
20634 (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS, ppc_fill_vrregset)
20635 (ppc_store_vrregset, PTRACE_GETEVRREGS, PTRACE_SETEVRREGS)
20636 (struct gdb_evrregset_t, ppc_fill_evrregset, ppc_store_evrregset): New.
20637 (target_regsets): Add AltiVec and SPE register sets.
20638 * configure.ac: Check for AltiVec and SPE.
20639 * linux-ppc64-low.c (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS)
20640 (ppc_fill_vrregset, ppc_store_vrregset): New.
20641 (target_regsets): Add AltiVec register set.
20642 * configure: Regenerated.
20643
20644 2007-09-19 Daniel Jacobowitz <dan@codesourcery.com>
20645
20646 * linux-low.c (O_LARGEFILE): Define.
20647 (linux_read_memory): Use /proc/PID/mem.
20648 * configure.ac: Use AC_GNU_SOURCE. Check for pread64.
20649 * configure, config.in: Regenerated.
20650
20651 2007-09-04 Daniel Jacobowitz <dan@codesourcery.com>
20652
20653 * linux-low.c (linux_wait_for_event): Do not pass signals while
20654 single-stepping.
20655
20656 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
20657
20658 * win32-low.c (create_process): New.
20659 (win32_create_inferior): Use create_process instead of
20660 CreateProcess. If create_process failed retry appending an ".exe"
20661 suffix. Store the GetLastError result immediatelly after
20662 create_process calls and use it on the call to error.
20663
20664 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
20665
20666 * win32-low.c (handle_load_dll): Don't use toolhelp when waiting.
20667
20668 2007-08-23 Joel Brobecker <brobecker@adacore.com>
20669
20670 * configure.ac: Switch license to GPLv3.
20671
20672 2007-08-01 Michael Snyder <msnyder@access-company.com>
20673
20674 * remote-utils.c (putpkt_binary): Memory leak, free buf2.
20675
20676 2007-07-31 Pedro Alves <pedro_alves@portugalmail.pt>
20677
20678 * win32-low.c (winapi_CloseToolhelp32Snapshot) [_WIN32_WCE]: New
20679 typedef.
20680 (win32_CloseToolhelp32Snapshot) [_WIN32_WCE]: New global var.
20681 (load_toolhelp) [_WIN32_WCE]: Load TOOLHELP.DLL. Get
20682 CloseToolhelp32Snapshot.
20683 (toolhelp_get_dll_name) [_WIN32_WCE]: Close the snapshot with
20684 CloseToolhelp32Snapshot.
20685
20686 2007-07-27 Michael Snyder <michael.snyder@access-company.com>
20687
20688 * server.c (main): Check for inferior exit before main loop.
20689
20690 2007-07-18 Pedro Alves <pedro_alves@portugalmail.pt>
20691
20692 * remote-utils.c (remote_open): Set SO_KEEPALIVE on remote_desc
20693 instead of on tmp_desc.
20694
20695 2007-07-17 Pedro Alves <pedro_alves@portugalmail.pt>
20696 Daniel Jacobowitz <dan@codesourcery.com>
20697
20698 * inferiors.c (all_dlls, dlls_changed, get_dll): New.
20699 (add_thread): Minor cleanups.
20700 (clear_inferiors): Move lower in the file. Clear the DLL
20701 list.
20702 (free_one_dll, match_dll, loaded_dll, unloaded_dll, clear_list): New.
20703 * remote-utils.c (prepare_resume_reply): Check dlls_changed.
20704 (xml_escape_text): New.
20705 * server.c (handle_query): Handle qXfer:libraries:read. Report it
20706 for qSupported.
20707 (handle_v_cont): Report errors.
20708 (gdbserver_version): Update.
20709 (main): Correct size of own_buf. Do not report initial DLL events.
20710 * server.h (struct dll_info, all_dlls, dlls_changed, loaded_dll)
20711 (unloaded_dll, xml_escape_text): New.
20712 * win32-low.c (enum target_waitkind): Update comments.
20713 (win32_add_one_solib, get_image_name, winapi_EnumProcessModules)
20714 (winapi_GetModuleInformation, winapi_GetModuleFileNameExA)
20715 (win32_EnumProcessModules, win32_GetModuleInformation)
20716 (win32_GetModuleFileNameExA, load_psapi, psapi_get_dll_name)
20717 (winapi_CreateToolhelp32Snapshot, winapi_Module32First)
20718 (winapi_Module32Next, win32_CreateToolhelp32Snapshot)
20719 (win32_Module32First, win32_Module32Next, load_toolhelp)
20720 (toolhelp_get_dll_name, handle_load_dll, handle_unload_dll): New.
20721 (get_child_debug_event): Handle DLL events.
20722 (win32_wait): Likewise.
20723
20724 2007-07-12 Daniel Jacobowitz <dan@codesourcery.com>
20725
20726 * configure.srv: Set srv_linux_regsets for sh*-*-linux*.
20727 * linux-sh-low.c (sh_fill_gregset, target_regsets): New.
20728
20729 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
20730
20731 * win32-low.c (handle_output_debug_string): Ignore event if not
20732 waiting.
20733
20734 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
20735
20736 * win32-arm-low.c (arm_wince_breakpoint): Fix typo.
20737
20738 2007-07-03 Daniel Jacobowitz <dan@codesourcery.com>
20739
20740 * remote-utils.c (look_up_one_symbol): Handle 'm' packets.
20741
20742 2007-07-02 Daniel Jacobowitz <dan@codesourcery.com>
20743
20744 * inferiors.c (change_inferior_id): Add comment.
20745 * linux-low.c (check_removed_breakpoint): Add an early
20746 prototype. Improve debug output.
20747 (linux_attach): Doc update.
20748 (linux_detach_one_process, linux_detach): Clean up before releasing
20749 each process.
20750 (send_sigstop, wait_for_sigstop): Improve comments and debug output.
20751 * linux-low.h (struct process_info): Doc improvement.
20752 * mem-break.c (delete_all_breakpoints): New.
20753 * mem-break.h (delete_all_breakpoints): New prototype.
20754 * thread-db.c (find_first_thread): New.
20755 (thread_db_create_event): Call it instead of
20756 thread_db_find_new_threads. Clean up unused variables.
20757 (maybe_attach_thread): Remove first thread handling.
20758 (thread_db_find_new_threads): Use find_first_thread.
20759 (thread_db_get_tls_address): Likewise.
20760
20761 2007-06-27 Daniel Jacobowitz <dan@codesourcery.com>
20762
20763 * thread-db.c (thread_db_find_new_threads): Add prototype.
20764 (thread_db_create_event): Check for the main thread before adding
20765 a new thread.
20766 (maybe_attach_thread): Only enable event reporting if TID == 0.
20767 (thread_db_get_tls_address): Check for new threads.
20768
20769 2007-06-20 Daniel Jacobowitz <dan@codesourcery.com>
20770
20771 * linux-low.c (linux_create_inferior): Try execv before execvp.
20772 * spu-low.c (spu_create_inferior): Likewise.
20773
20774 2007-06-13 Mike Frysinger <vapier@gentoo.org>
20775
20776 * linux-low.c (linux_create_inferior): Change execv to execvp.
20777 * spu-low.c (spu_create_inferior): Likewies.
20778
20779 2007-06-13 Daniel Jacobowitz <dan@codesourcery.com>
20780
20781 * Makefile.in (clean): Clean new files instead of deleted ones.
20782 (reg-mips.o, reg-mips.c, reg-mips64.o, reg-mips64.c): Delete.
20783 (mips-linux.o, mips-linux.c, mips64-linux.o, mips64-linux.c): New
20784 rules.
20785 * configure.srv: Specify XML files and new regformats for MIPS and
20786 MIPS64 GNU/Linux.
20787 * linux-mips-low.c (mips_num_regs): Set to only used registers.
20788 (mips_regmap): Do not fetch $0. Remove unused registers. Add
20789 an entry for the restart register.
20790 (mips_cannot_fetch_register, mips_cannot_store_register)
20791 (mips_reinsert_addr, mips_fill_fpregset, mips_store_fpregset): Update
20792 register names to match the XML descriptions.
20793 (mips_fill_gregset, mips_store_gregset): Likewise. Handle the
20794 restart register instead of $0.
20795
20796 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
20797 Markus Deuling <deuling@de.ibm.com>
20798
20799 * remote-utils.c (decode_xfer_write): New function.
20800 * server.h (decode_xfer_write): Add prototype.
20801 * server.c (handle_query): Add PACKET_LEN argument. Support
20802 qXfer:spu:read and qXfer:spu:write packets.
20803 (main): Pass packet_len to handle_query.
20804 * spu-low.c (spu_target_ops): Add spu_proc_xfer_spu.
20805 * target.h (target_ops): Add qxfer_spu.
20806
20807 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
20808
20809 * spu-low.c (spu_proc_xfer_spu): Do not return failure when
20810 accessing non-seekable spufs files.
20811
20812 2007-05-16 Markus Deuling <deuling@de.ibm.com>
20813
20814 * server.c (handle_query): Add reply for qC packet.
20815
20816 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20817 Leo Zayas <lerele@champenstudios@com>
20818
20819 * server.h (check_remote_input_interrupt_request): New function.
20820 * remote_utils.c (INVALID_DESCRIPTOR): New define.
20821 (remote_desc): Initialize with INVALID_DESCRIPTOR.
20822 (input_interrupt): Expose on USE_WIN32API too. Fix whitespace.
20823 (check_remote_input_interrupt_request): New function.
20824 * server.h (check_remote_input_interrupt_request): Declare.
20825 * win32-low.c (winapi_DebugBreakProcess,
20826 winapi_GenerateConsoleCtrlEvent): New typedefs.
20827 (get_child_debug_event): Lower Win32 debug event polling from 1 sec
20828 to 250 ms.
20829 (win32_wait): Check for remote interrupt request
20830 with check_remote_input_interrupt_request.
20831 (win32_request_interrupt): New function.
20832 (win32_target_op): Set request_interrupt to win32_request_interrupt.
20833
20834 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20835
20836 * win32-low.c (debug_registers_changed,
20837 debug_registers_used, CONTEXT_EXTENDED_REGISTERS,
20838 CONTEXT_FLOATING_POINT, CONTEXT_DEBUG_REGISTERS,
20839 CONTEXT_DEBUGGER, CONTEXT_DEBUGGER_DR): Delete.
20840 (thread_rec): Get context using the low target.
20841 (child_add_thread): Call thread_added on the low target,
20842 which does the same thing.
20843 (regptr): Delete.
20844 (do_initial_child_stuff): Remove debug registers references.
20845 Set context using the low target. Resume threads after
20846 setting the contexts.
20847 (child_continue): Remove dead variable. Remove debug
20848 registers references.
20849 (child_fetch_inferior_registers): Go through the low target.
20850 (do_child_store_inferior_registers): Remove.
20851 (child_store_inferior_registers): Go through the low target.
20852 (win32_resume): Remove debug registers references.
20853 Set context using the low target.
20854 (handle_exception): Change return type to void. Don't record
20855 context here. Set status to TARGET_WAITKIND_SPURIOUS on a
20856 first chance exception.
20857 (get_child_debug_event): Change return type to void. Remove
20858 goto loop. Always return after waiting for debug event.
20859 (win32_wait): Convert to switch statement. Handle spurious
20860 events.
20861
20862 * win32-i386-low.c (debug_registers_changed,
20863 debug_registers_used): New.
20864 (initial_stuff): Rename to ...
20865 (i386_initial_stuff): ... this. Clear debug registers
20866 state variables.
20867 (store_debug_registers): Delete.
20868 (i386_get_thread_context): New.
20869 (load_debug_registers): Delete.
20870 (i386_set_thread_context): New.
20871 (i386_thread_added): New.
20872 (single_step): Rename to ...
20873 (i386_single_step): ... this.
20874 (do_fetch_inferior_registers): Rename to ...
20875 (i386_fetch_inferior_register): ... this.
20876 (i386_store_inferior_register): New.
20877 (the_low_target): Adapt to new interface.
20878
20879 * win32-arm-low.c (CONTEXT_FLOATING_POINT): Define.
20880 (arm_get_thread_context): New.
20881 (arm_set_thread_context): New.
20882 (regptr): New.
20883 (do_fetch_inferior_registers): Rename to ...
20884 (arm_fetch_inferior_register): ... this.
20885 (arm_store_inferior_register): New.
20886 (arm_wince_breakpoint): Reimplement as unsigned long.
20887 (arm_wince_breakpoint_len): Define.
20888 (the_low_target): Adapt to new interface.
20889
20890 * win32-low.h (target_ops): Remove regmap, store_debug_registers and
20891 load_debug_registers. Add get_thread_context, set_thread_context,
20892 thread_added and store_inferior_register. Rename
20893 fetch_inferior_registers to fetch_inferior_register.
20894 (regptr): Remove declaration.
20895
20896 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20897
20898 * linux-low.c (linux_detach): Change return type to int. Return 0.
20899 * spu-low.c (spu_detach): Likewise.
20900
20901 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20902
20903 * target.h (target_ops): Change return type of detach to int.
20904 Add join.
20905 (join_inferior): New.
20906 * server.c (main): Don't skip detach support on mingw32.
20907 If the inferior doesn't support detaching return error.
20908 Call join_inferior instead of using waitpid.
20909 * linux-low.c (linux_join): New.
20910 (linux_target_op): Add linux_join.
20911 * spu-low.c (spu_join): New.
20912 (spu_target_ops): Add spu_join.
20913 * win32-low.c (win32_detach): Adapt to new interface.
20914 Reopen current_process_handle before detaching. Issue a child
20915 resume before detaching.
20916 (win32_join): New.
20917 (win32_target_op): Add win32_join.
20918
20919 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20920
20921 * win32-low.c (win32-attach): Fix return value.
20922 * target.h (target_ops): Describe ATTACH return values.
20923
20924 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20925
20926 * win32-low.c (GETPROCADDRESS): Define.
20927 (winapi_DebugActiveProcessStop): Add WINAPI. typedef as pointer.
20928 (winapi_DebugSetProcessKillOnExit): Likewise.
20929 (win32_create_inferior): Force usage of ansi CreateProcessA.
20930 (win32_attach): Use GETPROCADDRESS.
20931 (win32_detach): Likewise.
20932
20933 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20934
20935 * win32-low.c (win32_wait): Don't use WSTOPSIG.
20936
20937 2007-03-30 Pedro Alves <pedro_alves@portugalmail.pt>
20938
20939 * win32-low.c: Commit leftover changes from 2007-03-29.
20940
20941 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
20942
20943 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Make 16-bit
20944 fields short instead of int. Add explicit padding.
20945 (i387_cache_to_fsave): Remove unnecessary casts.
20946 (i387_fsave_to_cache): Doc fix.
20947 (i387_cache_to_fxsave): Remove unnecessary casts and masking.
20948
20949 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
20950
20951 * i387-fp.c (i387_cache_to_fxsave): Reinitialize val2 before use.
20952 (i387_fxsave_to_cache): Check fp->ftag while building ftag value.
20953
20954 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
20955
20956 * configure.srv (arm*-*-mingw32ce*): Move near the other
20957 arm targets.
20958
20959 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
20960
20961 * configure.ac: Add errno checking.
20962 (AC_CHECK_HEADERS): Add errno.h, fcntl.h, signal.h,
20963 sys/file.h and malloc.h.
20964 (AC_CHECK_DECLS): Add perror.
20965 (srv_mingwce): Handle.
20966 * configure.srv (i[34567]86-*-cygwin*): Add
20967 win32-i386-low.o to srv_tgtobj.
20968 (i[34567]86-*-mingw*): Likewise.
20969 (arm*-*-mingw32ce*): Add case.
20970 * gdbreplay.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
20971 HAVE_FCNTL_H, HAVE_ERRNO_H, HAVE_MALLOC_H]: Check.
20972 [__MINGW32CE__] (strerror): New function.
20973 [__MINGW32CE__] (errno): Define to GetLastError.
20974 [__MINGW32CE__] (COUNTOF): New macro.
20975 (remote_open): Remove extra close call.
20976 * mem-break.c (delete_breakpoint_at): New function.
20977 * mem-break.h (delete_breakpoint_at): Declare.
20978 * remote-utils.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
20979 HAVE_FCNTL_H, HAVE_UNISTD_H, HAVE_ERRNO_H]: Check.
20980 [USE_WIN32API] (read, write): Add char* casts.
20981 * server.c [HAVE_UNISTD_H, HAVE_SIGNAL_H]: Check.
20982 * server.h: Include wincecompat.h on Windows CE.
20983 [HAVE_ERRNO_H]: Check.
20984 (perror): Declare if not declared.
20985 * utils.c: Add stdlib.h, errno.h and malloc.h includes.
20986 (perror_with_name): Remove errno declaration.
20987 * wincecompat.h: New.
20988 * wincecompat.c: New.
20989 * win32-low.h: New.
20990 * win32-arm-low.c: New.
20991 * win32-i386-low.c: New.
20992 (win32-low.c): Include mem-break.h and win32-low.h, and winnt.h.
20993 (OUTMSG2): Make it safe.
20994 (_T): New macro.
20995 (COUNTOF): New macro.
20996 (NUM_REGS): Get it from the low target.
20997 (CONTEXT_EXTENDED_REGISTERS, CONTEXT_FLOATING_POINT,
20998 CONTEXT_DEBUG_REGISTERS): Add fallbacks to 0.
20999 (thread_rec): Let low target handle debug registers.
21000 (child_add_thread): Likewise.
21001 (child_init_thread_list): Likewise.
21002 (continue_one_thread): Likewise.
21003 (regptr): New.
21004 (do_child_fetch_inferior_registers): Move to ...
21005 * win32-i386-low.c: ... here, and rename to ...
21006 (do_fetch_inferior_registers): ... this.
21007 * win32-low.c (child_fetch_inferior_registers):
21008 Go through the low target.
21009 (do_child_store_inferior_registers): Use regptr.
21010 (strwinerror): New function.
21011 (win32_create_inferior): Handle Windows CE.
21012 Use strwinerror instead of strerror on Windows error
21013 codes. Add program to the error output.
21014 Don't close the main thread handle on Windows CE.
21015 (win32_attach): Use coredll.dll on Windows CE.
21016 (win32_kill): Close current process and current
21017 thread handles.
21018 (win32_detach): Use coredll.dll on Windows CE.
21019 (win32_resume): Let low target handle debug registers, and
21020 step request.
21021 (handle_exception): Add/Remove initial breakpoint. Avoid
21022 non-existant WSTOPSIG on Windows CE.
21023 (win32_read_inferior_memory): Cast to remove warning.
21024 (win32_arch_string): Go through the low target.
21025 (initialize_low): Call set_breakpoint_data with the low
21026 target's breakpoint.
21027 * win32-low.c (dr, FLAG_TRACE_BIT, FCS_REGNUM,
21028 FOP_REGNUM, mappings): Move to ...
21029 * win32-i386-low.c: ... here.
21030 * win32-low.c (win32_thread_info): Move to ...
21031 * win32-low.h: ... here.
21032 * Makefile.in (SFILES): Add win32-low.c, win32-i386-low.c,
21033 win32-arm-low.c and wincecompat.c.
21034 (all:): Add $EXEEXT.
21035 (install-only:): Likewise.
21036 (gdbserver:): Likewise.
21037 (gdbreplay:): Likewise.
21038 * config.in: Regenerate.
21039 * configure: Regenerate.
21040
21041 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
21042
21043 * win32-low.c: Rename typedef thread_info to
21044 win32_thread_info throughout.
21045
21046 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
21047
21048 * win32-i386-low.c: Rename to ...
21049 * win32-low.c: ... this.
21050 * configure.srv: Replace win32-i386-low.o with win32-low.o.
21051 * Makefile.in: Likewise.
21052
21053 2007-03-27 Pedro Alves <pedro_alves@portugalmail.pt>
21054
21055 * remote-utils.c (monitor_output): Constify msg parameter.
21056 * server.h (monitor_output): Likewise.
21057 * win32-i386-low.c (handle_output_debug_string): New.
21058 (win32_kill): Handle OUTPUT_DEBUG_STRING_EVENT events using
21059 handle_output_debug_string.
21060 (get_child_debug_event): Likewise.
21061
21062 2007-03-27 Mat Hostetter <mat@lcs.mit.edu>
21063
21064 * server.c (main): Correct strtoul check.
21065
21066 2007-03-27 Jon Ringle <jon@ringle.org>
21067
21068 * linux-low.c: Check __ARCH_HAS_MMU__ also.
21069
21070 2007-03-27 Brooks Moses <brooks.moses@codesourcery.com>
21071
21072 * Makefile.in: Add dummy "pdf" and "install-pdf" targets.
21073
21074 2007-02-27 Daniel Jacobowitz <dan@codesourcery.com>
21075
21076 * terminal.h: Check HAVE_SGTTY_H.
21077
21078 2007-02-27 Mat Hostetter <mat@lcs.mit.edu>
21079
21080 * remote-utils.c (remote_open): Print out the assigned port number.
21081
21082 2007-02-26 Daniel Jacobowitz <dan@codesourcery.com>
21083
21084 * remote-utils.c (monitor_output): New function.
21085 * server.c (debug_threads): Define here.
21086 (monitor_show_help): New function.
21087 (handle_query): Handle qRcmd.
21088 (main): Do not handle 'd' packet.
21089 * server.h (debug_threads, remote_debug, monitor_output): Declare.
21090 * linux-low.c, spu-low.c, win32-i386-low.c: Remove definitions
21091 of debug_threads.
21092
21093 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
21094
21095 * Makefile.in (EXEEXT): New.
21096 (clean): Use $(EXEEXT).
21097
21098 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
21099
21100 * target.h (target_ops): Rename send_signal to request_interrupt,
21101 and remove enum target_signal parameter.
21102 * linux-low.c (linux_request_interrupt): Rename from
21103 linux_send_signal, and always send SIGINT.
21104 * spu-low.c (spu_request_interrupt): Rename from spu_send_signal,
21105 and always send SIGINT.
21106 * remote-utils.c (putpkt_binary): Call request_interrupt, instead
21107 of send_signal.
21108 (input_interrupt): Likewise.
21109
21110 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
21111
21112 * server.c (get_features_xml): Check if target implemented
21113 arch_string.
21114 * win32-i386-low.c (win32_arch_string): New.
21115 (win32_target_ops): Add win32_arch_string as arch_string member.
21116
21117 2007-02-22 Markus Deuling <deuling@de.ibm.com>
21118
21119 * spu-low.c (spu_arch_string): New.
21120 (spu_target_ops): Add spu_arch_string.
21121
21122 2007-02-16 Daniel Jacobowitz <dan@codesourcery.com>
21123
21124 * remote-utils.c: Remove HAVE_TERMINAL_H check.
21125 * configure.ac: Do not check for terminal.h.
21126 * configure, config.in: Regenerated.
21127
21128 2007-02-08 Daniel Jacobowitz <dan@codesourcery.com>
21129
21130 * Makefile.in (OBS): Add $(XML_BUILTIN).
21131 (XML_DIR, XML_TARGET, XML_FILES, XML_BUILTIN): New.
21132 (clean): Update.
21133 (target.xml, xml-builtin.c, stamp-xml, arm-with-iwmmxt.o)
21134 (arm-with-iwmmxt.c): New.
21135 * config.in, configure: Regenerate.
21136 * configure.ac: Check for iWMMXt. Handle srv_xmltarget,
21137 srv_xmlbuiltin, and srv_xmlfiles. Define USE_XML.
21138 * configure.srv: Mention srv_xmltarget and srv_xmlfiles.
21139 (arm*-*-linux*): Add iWMMXt and regset support.
21140 * linux-arm-low.c (PTRACE_GETWMMXREGS, PTRACE_SETWMMXREGS): Define.
21141 (arm_fill_gregset, arm_store_gregset, arm_fill_wmmxregset)
21142 (arm_store_wmmxregset, target_regsets): New.
21143 * server.c (get_features_xml): Take annex argument. Check builtin
21144 XML documents.
21145 (handle_query): Handle multiple annexes.
21146
21147 2007-01-29 Daniel Jacobowitz <dan@codesourcery.com>
21148
21149 * remote-utils.c [USE_WIN32API] (read, write): Define.
21150 (putpkt_binary, input_interrupt, readchar, getpkt): Use read and
21151 write.
21152
21153 2007-01-09 Daniel Jacobowitz <dan@codesourcery.com>
21154
21155 * linux-i386-low.c (the_low_target): Set arch_string.
21156 * linux-x86-64-low.c (the_low_target): Likewise.
21157 * linux-low.c (linux_arch_string): New.
21158 (linux_target_ops): Add it.
21159 * linux-low.h (struct linux_target_ops): Add arch_string.
21160 * server.c (write_qxfer_response): Use const void * for DATA.
21161 (get_features_xml): New.
21162 (handle_query): Handle qXfer:features:read. Report it for qSupported.
21163 * target.h (struct target_ops): Add arch_string method.
21164
21165 2007-01-03 Denis Pilat <denis.pilat@st.com>
21166 Daniel Jacobowitz <dan@codesourcery.com>
21167
21168 * linux-low.c (linux_kill): Handle being called with no threads.
21169 * win32-i386-low.c (win32_kill): Likewise.
21170 (get_child_debug_event): Clear current_process_handle.
21171
21172 2006-12-30 Denis PILAT <denis.pilat@st.com>
21173 Daniel Jacobowitz <dan@codesourcery.com>
21174
21175 * remote-utils.c (remote_open): Check the type of specified
21176 serial port devices before opening them.
21177 * server.c (main): Kill the inferior if an error occurs during
21178 the first remote_open.
21179
21180 2006-12-05 Markus Deuling <deuling@de.ibm.com>
21181
21182 * README: Update supported targets.
21183
21184 2006-11-28 Daniel Jacobowitz <dan@codesourcery.com>
21185
21186 * Makefile.in (clean): Remove reg-mips64.c.
21187 (reg-mips64.c, reg-mips64.o): New rules.
21188 * configure.srv: Handle mips64. Include regset support for mips.
21189 * linux-mips-low.c (union mips_register): New.
21190 (mips_get_pc, mips_set_pc, mips_reinsert_addr): Use it.
21191 (mips_breakpoint, mips_breakpoint_at): Use int.
21192 (mips_collect_register, mips_supply_register)
21193 (mips_collect_register_32bit, mips_supply_register_32bit)
21194 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
21195 (mips_store_fpregset, target_regsets): New.
21196 * thread-db.c (thread_db_get_tls_address): Use uintptr_t.
21197
21198 2006-11-22 Ulrich Weigand <uweigand@de.ibm.com>
21199
21200 * configure.srv: Add target "spu*-*-*".
21201 * Makefile.in (clean): Remove reg-spu.c.
21202 (reg-spu.c, reg-spu.o, spu-low.o): Add dependencies.
21203 * spu-low.c: New file.
21204
21205 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
21206
21207 * configure.ac: Correct td_thr_tls_get_addr test.
21208 * configure: Regenerated.
21209
21210 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
21211
21212 * linux-low.c (linux_wait_for_event): Reformat. Use the
21213 pass_signals array.
21214 * remote-utils.c (decode_address_to_semicolon): New.
21215 * server.c (pass_signals, handle_general_set): New.
21216 (handle_query): Mention QPassSignals for qSupported.
21217 (main): Call handle_general_set.
21218 * server.h (pass_signals, decode_address_to_semicolon): New.
21219
21220 2006-11-06 Daniel Jacobowitz <dan@codesourcery.com>
21221
21222 * server.c (handle_query): Correct error handling for read_auxv.
21223
21224 2005-10-19 Ulrich Weigand <uweigand@de.ibm.com>
21225
21226 * configure.srv [s390-*-linux*, s390x-*-linux*]: Set srv_linux_regsets
21227 and srv_linux_thread_db to yes.
21228 * linux-s390-low.c (s390_fill_gregset): New function.
21229 (target_regsets): Define data structure.
21230
21231 2006-10-17 Daniel Jacobowitz <dan@codesourcery.com>
21232
21233 * acinclude.m4 (SRV_CHECK_TLS_GET_ADDR): New.
21234 * configure.ac: Use it. Define HAVE_TD_THR_TLS_GET_ADDR.
21235 * config.in, configure: Regenerated.
21236 * inferiors.c (gdb_id_to_thread): New function.
21237 (gdb_id_to_thread_id): Use it.
21238 * linux-low.c (linux_target_ops): Use thread_db_get_tls_address.
21239 * linux-low.h (struct process_info): Add th member.
21240 (thread_db_get_tls_address): New prototype.
21241 * remote-utils.c (decode_address): Make non-static.
21242 * server.c (handle_query): Handle qGetTLSAddr.
21243 * server.h (gdb_id_to_thread, decode_address): New prototypes.
21244 * target.h (struct target_ops): Add get_tls_address.
21245 * thread-db.c (maybe_attach_thread): Save the thread handle.
21246 (thread_db_get_tls_address): New.
21247
21248 2006-09-28 Daniel Jacobowitz <dan@codesourcery.com>
21249
21250 * linux-low.c (PTRACE_GETSIGINFO, PTRACE_SETSIGINFO): Define.
21251 (linux_resume_one_process): Take a siginfo_t *. Update all
21252 callers. Queue it if necessary. Use PTRACE_SETSIGINFO.
21253 (struct pending_signals): Add a siginfo_t.
21254 (linux_wait_for_process): Always set last_status.
21255 (linux_wait_for_event): Use PTRACE_GETSIGINFO.
21256 (linux_queue_one_thread): Use PTRACE_GETSIGINFO.
21257 * linux-low.h (struct process_info): Add last_status.
21258
21259 2006-09-21 Daniel Jacobowitz <dan@codesourcery.com>
21260
21261 * remote-utils.c (try_rle): New function.
21262 (putpkt_binary): Use it.
21263
21264 2006-08-19 Daniel Jacobowitz <dan@codesourcery.com>
21265
21266 * Makefile.in (clean): Clean reg-x86-64-linux.c.
21267 (reg-x86-64-linux.o, reg-x86-64-linux.c): New.
21268 * configure.srv (x86_64-*-linux*): Use reg-x86-64-linux.o.
21269 * linux-x86-64-low.c (x86_64_regmap): Include ORIG_RAX.
21270 (x86_64_fill_gregset, x86_64_store_gregset): Skip floating
21271 point registers.
21272
21273 2006-08-08 Richard Sandiford <richard@codesourcery.com>
21274
21275 * server.c (terminal_fd): New variable.
21276 (old_foreground_pgrp): Likewise.
21277 (restore_old_foreground_pgrp): New function.
21278 (start_inferior): Record the terminal file descriptor in terminal_fd
21279 and its original foreground group in old_foreground_pgrp. Register
21280 restore_old_foreground_pgrp with atexit().
21281
21282 2006-07-26 Daniel Jacobowitz <dan@codesourcery.com>
21283
21284 * server.c (handle_query): Correct qPart to qXfer.
21285
21286 2006-07-22 Daniel Jacobowitz <dan@codesourcery.com>
21287
21288 * configure.ac: Check for more headers which are missing on
21289 Windows. Automatically supply -lwsock32 and USE_WIN32API.
21290 * configure.srv: Add Cygwin and mingw32.
21291 * remote-utils.c: Don't include headers unconditionally which
21292 are missing on mingw32. Include <winsock.h> for mingw32.
21293 (remote_open): Adjust for mingw32 support. Flush
21294 standard error after writing to it.
21295 (remote_close, putpkt_binary, input_interrupt, block_async_io)
21296 (unblock_async_io, enable_async_io, disable_async_io)
21297 (readchar, getpkt): Update for Winsock support.
21298 (prepare_resume_reply): Expect a protocol signal number.
21299 * server.c: Disable <sys/wait.h> on mingw32.
21300 (start_inferior): Adjust for mingw32 support. Flush
21301 standard error after writing to it.
21302 (attach_inferior): Likewise. Use protocol signal
21303 numbers.
21304 (main): Skip 'D' packet on mingw32. Use protocol signal numbers
21305 and names.
21306 * win32-i386-low.c: New file.
21307 * Makefile.in (XM_CLIBS): Set.
21308 (gdbserver, gdbreplay): Use $(INTERNAL_CFLAGS).
21309 (win32-i386-low.o): New dependency rule.
21310 * linux-low.c (linux_wait): Use target signal numbers.
21311 * target.h (struct target_ops): Doc fix.
21312 * server.h (target_signal_to_name): New prototype.
21313 * gdbreplay.c: Don't include headers unconditionally which
21314 are missing on mingw32. Include <winsock.h> for mingw32.
21315 (remote_close, remote_open): Adjust for Winsock support.
21316 * configure, config.in: Regenerated.
21317
21318 2006-07-12 Daniel Jacobowitz <dan@codesourcery.com>
21319
21320 * server.c (decode_xfer_read, write_qxfer_response): New.
21321 (handle_query): Take a packet length argument. Handle
21322 qXfer:auxv:read instead of qPart:auxv:read. Mention it in
21323 the qSupported response.
21324 (main): Update call to handle_query.
21325
21326 2006-06-22 Daniel Jacobowitz <dan@codesourcery.com>
21327
21328 * remote-utils.c (remote_escape_output, remote_unescape_input): New.
21329 (putpkt_binary): Renamed from putpkt and adjusted for binary
21330 data.
21331 (putpkt): New wrapper for putpkt_binary.
21332 (readchar): Don't mask off the high bit.
21333 (decode_X_packet): New function.
21334 * server.c (main): Call putpkt_binary if a handler sets the packet
21335 length. Save the length of the incoming packet. Handle 'X'.
21336 * server.h (gdb_byte, remote_escape_output, decode_X_packet): New.
21337
21338 2006-06-21 Daniel Jacobowitz <dan@codesourcery.com>
21339
21340 * server.c (handle_query): Handle qSupported.
21341
21342 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
21343
21344 * remote-utils.c (all_symbols_looked_up): New variable.
21345 (look_up_one_symbol): Check it.
21346 * server.h (look_up_one_symbol): New declaration.
21347 * thread-db.c (thread_db_init): Set all_symbols_looked_up.
21348
21349 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
21350
21351 * Makefile.in (linux-arm-low.o): Update dependencies.
21352 * linux-arm-low.c: Include "gdb_proc_service.h".
21353 (PTRACE_GET_THREAD_AREA): Define.
21354 (ps_get_thread_area): New function.
21355
21356 2006-05-09 Nathan Sidwell <nathan@codesourcery.com>
21357
21358 * configure.srv (m68k*-*-uclinux*): New target.
21359 * linux-low.c (linux_create_inferior): Use vfork on mmuless systems.
21360 (linux_resume_one_process): Remove extraneous cast.
21361 (linux_read_offsets): New.
21362 (linux_target_op): Add linux_read_offsets on mmuless systems.
21363 * server.c (handle_query): Add qOffsets logic.
21364 * target.h (struct target_ops): Add read_offsets.
21365
21366 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
21367
21368 * linux-mips-low.c: Include <sys/ptrace.h> and "gdb_proc_service.h".
21369 (PTRACE_GET_THREAD_AREA): Define.
21370 (ps_get_thread_area): New function.
21371 * Makefile.in (linux-i386-low.o, linux-mips-low.o)
21372 (linux-x86-64-low.o): Update.
21373
21374 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
21375
21376 * configure.ac: Remove checks for prfpregset_t.
21377 * gdb_proc_service.h: New file.
21378 * linux-i386-low.c, linux-x86-64-low.c, thread-db.c: Use the
21379 new "gdb_proc_service.h".
21380 * proc-service.c: Likewise.
21381 (ps_pglobal_lookup, ps_pdread, ps_pdwrite): Use psaddr_t.
21382 (ps_lgetfpregs, ps_lsetfpregs): Use a void* argument.
21383 * Makefile.in (gdb_proc_service_h): Updated.
21384 * configure, config.in: Regenerated.
21385
21386 2006-03-03 Daniel Jacobowitz <dan@codesourcery.com>
21387
21388 * remote-utils.c (prepare_resume_reply): Move declaration
21389 of gdb_id_from_wait to the top of the block.
21390
21391 2006-02-15 Daniel Jacobowitz <dan@codesourcery.com>
21392
21393 * linux-low.c (regsets_store_inferior_registers): Read the regset
21394 from the target before filling it.
21395
21396 2006-02-08 Daniel Jacobowitz <dan@codesourcery.com>
21397
21398 * server.c (attach_inferior): Return SIGTRAP for a successful
21399 attach.
21400
21401 2006-02-01 Daniel Jacobowitz <dan@codesourcery.com>
21402
21403 * Makefile.in (OBS): Add version.o.
21404 (STAGESTUFF): Delete.
21405 (version.o): Add dependencies.
21406 (version.c): Replace rule.
21407 (clean): Remove version.c.
21408 * server.c (gdbserver_version): New.
21409 (gdbserver_usage): Use printf.
21410 (main): Handle --version and --help.
21411 * server.h (version, host_name): Add declarations.
21412
21413 2005-12-23 Eli Zaretskii <eliz@gnu.org>
21414
21415 * linux-arm-low.c:
21416 * linux-arm-low.c:
21417 * inferiors.c:
21418 * i387-fp.h:
21419 * i387-fp.c:
21420 * gdbreplay.c:
21421 * regcache.c:
21422 * proc-service.c:
21423 * mem-break.h:
21424 * mem-break.c:
21425 * linux-x86-64-low.c:
21426 * linux-sh-low.c:
21427 * linux-s390-low.c:
21428 * linux-ppc64-low.c:
21429 * linux-ppc-low.c:
21430 * linux-mips-low.c:
21431 * linux-m68k-low.c:
21432 * linux-m32r-low.c:
21433 * linux-low.h:
21434 * linux-low.c:
21435 * linux-ia64-low.c:
21436 * linux-i386-low.c:
21437 * linux-crisv32-low.c:
21438 * thread-db.c:
21439 * terminal.h:
21440 * target.h:
21441 * target.c:
21442 * server.h:
21443 * server.c:
21444 * remote-utils.c:
21445 * regcache.h:
21446 * utils.c:
21447 * Makefile.in:
21448 * configure.ac:
21449 * gdbserver.1: Add (C) after Copyright. Update the FSF
21450 address.
21451
21452 2005-11-13 Daniel Jacobowitz <dan@codesourcery.com>
21453
21454 * linux-arm-low.c (arm_eabi_breakpoint): New variable.
21455 (arm_breakpoint_at): Recognize both breakpoints.
21456 (the_low_target): Use the correct breakpoint instruction.
21457
21458 2005-11-02 Daniel Jacobowitz <dan@codesourcery.com>
21459
21460 * configure.srv (x86_64-*-linux*): Turn on thread_db support.
21461 * linux-x86-64-low.c (x86_64_breakpoint, x86_64_breakpoint_len)
21462 (x86_64_get_pc, x86_64_set_pc, x86_64_breakpoint_at): New.
21463 (the_low_target): Update.
21464
21465 2005-10-25 Andreas Schwab <schwab@suse.de>
21466
21467 * server.c (main): Allocate mem_buf with PBUFSIZ bytes.
21468
21469 * linux-ia64-low.c (ia64_regmap): Remove NAT registers.
21470 (ia64_num_regs): Reduce to 462.
21471
21472 2005-09-17 Daniel Jacobowitz <dan@codesourcery.com>
21473
21474 * acinclude.m4: Correct quoting.
21475 * aclocal.m4: Regenerated.
21476
21477 Suggested by SZOKOVACS Robert <szo@ies.hu>:
21478 * thread-db.c (thread_db_err_str): Handle TD_VERSION.
21479 (thread_db_init): Call thread_db_err_str.
21480 * configure.ac: Check for TD_VERSION.
21481 * config.in, configure: Regenerated.
21482
21483 2005-07-31 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
21484
21485 * server.h (error, fatal, warning): Add ATTR_FORMAT.
21486
21487 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
21488
21489 * configure.ac: Define HAVE_LINUX_REGSETS even if PTRACE_GETREGS
21490 is not available. Define HAVE_PTRACE_GETREGS if it is.
21491 * config.in, configure: Regenerated.
21492 * configure.srv: Set srv_linux_regsets for PowerPC and PowerPC64.
21493 * linux-i386-low.c, linux-m68k-low.c: Update to use
21494 HAVE_PTRACE_GETREGS.
21495 * linux-low.c (regsets_fetch_inferior_registers)
21496 (regsets_store_inferior_registers): Only return 0 if we processed
21497 GENERAL_REGS.
21498 * linux-ppc-low.c (ppc_fill_gregset, target_regsets): New.
21499 * linux-ppc64-low.c (ppc_fill_gregset, target_regsets): New.
21500
21501 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
21502
21503 * inferiors.c (struct thread_info): Add gdb_id.
21504 (add_thread): Add gdb_id argument.
21505 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New.
21506 * linux-low.c (linux_create_inferior, linux_attach_lwp): Update
21507 calls to add_thread.
21508 * remote-utils.c (prepare_resume_reply: Use thread_to_gdb_id.
21509 * server.c (handle_query): Use thread_to_gdb_id.
21510 (handle_v_cont, main): Use gdb_id_to_thread_id.
21511 * server.h (add_thread): Update prototype.
21512 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New
21513 prototypes.
21514
21515 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
21516
21517 * linux-low.c (fetch_register, usr_store_inferior_registers): Handle
21518 left-padded registers.
21519 * linux-low.h (struct linux_target_ops): Add left_pad_xfer.
21520 * linux-ppc64-low.c (the_low_target): Set left_pad_xfer.
21521
21522 2005-07-01 Steve Ellcey <sje@cup.hp.com>
21523
21524 * configure.ac (BFD_NEED_DECLARATION): Replace with AC_CHECK_DECLS.
21525 * configure: Regenerate.
21526 * config.in: Regenerate.
21527 * server.h (NEED_DECLARATION_STRERROR):
21528 Replace with !HAVE_DECL_STRERROR.
21529
21530 2005-06-16 Daniel Jacobowitz <dan@codesourcery.com>
21531
21532 * linux-low.c (linux_wait, linux_send_signal): Don't test
21533 an unsigned long variable for > 0 if it could be MAX_ULONG.
21534 * server.c (myresume): Likewise.
21535 * target.c (set_desired_inferior): Likewise.
21536
21537 2005-06-13 Mark Kettenis <kettenis@gnu.org>
21538
21539 * configure.ac: Simplify and improve check for socklen_t.
21540 * configure, config.in: Regenerate.
21541
21542 2005-06-12 Daniel Jacobowitz <dan@codesourcery.com>
21543
21544 * acconfig.h: Remove.
21545 * configure.ac: Add a test for socklen_t. Use three-argument
21546 AC_DEFINE throughout.
21547 * config.in: Regenerated using autoheader 2.59.
21548 * configure: Regenerated.
21549
21550 * gdbreplay.c (socklen_t): Provide a default.
21551 (remote_open): Use socklen_t.
21552 * remote-utils.c (socklen_t): Provide a default.
21553 (remote_open): Use socklen_t.
21554 (convert_int_to_ascii, convert_ascii_to_int, decode_M_packet): Use
21555 unsigned char.
21556
21557 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Use unsigned
21558 char for buffers.
21559 * linux-low.c (linux_read_memory, linux_write_memory)
21560 (linux_read_auxv): Likewise.
21561 * mem-break.c (breakpoint_data, set_breakpoint_data, check_mem_read)
21562 (check_mem_write): Likewise.
21563 * mem-break.h (set_breakpoint_data, check_mem_read, check_mem_write):
21564 Likewise.
21565 * regcache.c (struct inferior_rgcache_data, registers_to_string)
21566 (registers_from_string, register_data): Likewise.
21567 * server.c (handle_query, main): Likewise.
21568 * server.h (convert_ascii_to_int, convert_int_to_ascii)
21569 (decode_M_packet): Likewise.
21570 * target.c (read_inferior_memory, write_inferior_memory): Likewise.
21571 * target.h (struct target_ops): Update read_memory, write_memory,
21572 and read_auxv.
21573 (read_inferior_memory, write_inferior_memory): Update.
21574 * linux-low.h (struct linux_target_ops): Change type of breakpoint
21575 to unsigned char *.
21576 * linux-arm-low.c, linux-cris-low.c, linux-crisv32-low.c,
21577 linux-i386-low.c, linux-m32r-low.c, linux-m68k-low.c,
21578 linux-mips-low.c, linux-ppc-low.c, linux-ppc64-low.c,
21579 linux-s390-low.c, linux-sh-low.c: Update for changes in
21580 read_inferior_memory and the_low_target->breakpoint.
21581
21582 2005-05-28 Daniel Jacobowitz <dan@codesourcery.com>
21583
21584 * Makefile.in (SFILES): Add linux-ppc64-low.c.
21585 (linux-ppc64-low.o, reg-ppc64.c, reg-ppc64.o): New targets.
21586 * configure.srv: Add powerpc64-*-linux*.
21587 * linux-ppc64-low.c: New file.
21588
21589 2005-05-23 Orjan Friberg <orjanf@axis.com>
21590
21591 * linux-cris-low.c: New file with support for CRIS.
21592 * linux-crisv32-low.c: Ditto for CRISv32.
21593 * Makefile.in (SFILES): Add linux-cris-low.c, linux-crisv32-low.c.
21594 (clean): Add reg-cris.c and reg-crisv32.c.
21595 Add linux-cris-low.o, linux-crisv32-low.o, reg-cris.o, reg-cris.c,
21596 reg-crisv32.o, and reg-crisv32.c to make rules.
21597 * configure.srv: Add cris-*-linux* and crisv32-*-linux* to list of
21598 recognized targets.
21599
21600 2005-05-16 Ulrich Weigand <uweigand@de.ibm.com>
21601
21602 * linux-low.c (fetch_register): Ensure buffer size is a multiple
21603 of sizeof (PTRACE_XFER_TYPE).
21604 (usr_store_inferior_registers): Likewise. Zero out excess bytes.
21605
21606 2005-05-12 Orjan Friberg <orjanf@axis.com>
21607
21608 * target.h (struct target_ops): Add insert_watchpoint,
21609 remove_watchpoint, stopped_by_watchpoint, stopped_data_address function
21610 pointers for hardware watchpoint support.
21611 * linux-low.h (struct linux_target_ops): Ditto.
21612 * linux-low.c (linux_insert_watchpoint, linux_remove_watchpoint)
21613 (linux_stopped_by_watchpoint, linux_stopped_data_address): New. Add
21614 to linux_target_ops.
21615 * remote-utils.c (prepare_resume_reply): Add watchpoint information to
21616 reply packet.
21617 * server.c (main): Recognize 'Z' and 'z' packets.
21618
21619 2005-05-10 Ulrich Weigand <uweigand@de.ibm.com>
21620
21621 * linux-s390-low.c (s390_breakpoint, s390_breakpoint_len): Define.
21622 (s390_get_pc, s390_set_pc, s390_breakpoint_at): New functions.
21623 (the_low_target): Add new members.
21624
21625 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
21626
21627 * proc-service.c (ps_lgetregs): Search all_processes instead of
21628 all_threads.
21629
21630 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
21631
21632 * server.c (start_inferior): Change return type to int.
21633 (attach_inferior): Change sigptr to int *.
21634 (handle_v_cont, handle_v_requests): Change signal to int *.
21635 (main): Change signal to int.
21636
21637 2005-04-15 Kei Sakamoto <sakamoto.kei@renesas.com>
21638
21639 * Makefile.in: Add linux-m32r-low.o, reg-m32r.c and reg-m32r.o.
21640 * configure.srv: Add m32r*-*-linux*.
21641 * linux-m32r-low.c: New file.
21642
21643 2005-03-04 Daniel Jacobowitz <dan@codesourcery.com>
21644
21645 * Makefile.in (stamp-h): Set CONFIG_HEADERS explicitly.
21646
21647 2005-03-03 Daniel Jacobowitz <dan@codesourcery.com>
21648
21649 * inferiors.c (change_inferior_id, add_thread, find_inferior_id):
21650 Take unsigned long arguments for PIDs.
21651 * linux-low.c (add_process, linux_attach_lwp, linux_attach)
21652 (linux_thread_alive, linux_wait_for_event, kill_lwp, send_sigstop)
21653 (wait_for_sigstop, linux_resume_one_process)
21654 (regsets_fetch_inferior_registers, linux_send_signal)
21655 (linux_read_auxv): Likewise. Update the types of variables holding
21656 PIDs. Update format string specifiers.
21657 * linux-low.h (struct process_info, linux_attach_lwp): Likewise.
21658 * remote-utils.c (prepare_resume_reply): Likewise.
21659 * server.c (cont_thread, general_thread, step_thread)
21660 (thread_from_wait, old_thread_from_wait, signal_pid): Change type to
21661 unsigned long.
21662 (handle_query): Update format specifiers.
21663 (handle_v_cont, main): Use strtoul for thread IDs.
21664 * server.h (struct inferior_list_entry): Use unsigned long for ID.
21665 (add_thread, find_inferior_id, change_inferior_id, cont_thread)
21666 (general_thread, step_thread, thread_from_wait)
21667 (old_thread_from_wait): Update.
21668 * target.h (struct thread_resume): Use unsigned long for THREAD.
21669 (struct target_ops): Use unsigned long for arguments to attach and
21670 thread_alive.
21671
21672 2005-02-24 Daniel Jacobowitz <dan@codesourcery.com>
21673
21674 * acinclude.m4: Include bfd/bfd.m4 directly.
21675 * configure.ac: Use AC_ARG_PROGRAM. Suggested by Aron Griffis
21676 <agriffis@toolchain.org>.
21677 * aclocal.m4, configure: Regenerated.
21678
21679 2005-01-07 Andrew Cagney <cagney@gnu.org>
21680
21681 * configure.ac: Rename configure.in, require autoconf 2.59.
21682 * configure: Re-generate.
21683
21684 2004-12-08 Daniel Jacobowitz <dan@debian.org>
21685
21686 * acinclude.m4 (SRV_CHECK_THREAD_DB): Add ps_get_thread_area. Reset
21687 LIBS when finished.
21688 * aclocal.m4: Regenerated.
21689 * configure: Regenerated.
21690
21691 2004-11-21 Andreas Schwab <schwab@suse.de>
21692
21693 * linux-m68k-low.c (m68k_num_gregs): Define.
21694 (m68k_fill_gregset, m68k_store_gregset, m68k_fill_fpregset)
21695 (m68k_store_fpregset, target_regsets) [HAVE_LINUX_REGSETS]: New.
21696 (m68k_breakpoint, m68k_breakpoint_len, m68k_get_pc, m68k_set_pc)
21697 (m68k_breakpoint_at): New. Add to the_low_target.
21698
21699 * configure.srv (m68*-*-linux*): Set srv_linux_regsets and
21700 srv_linux_thread_db to yes.
21701
21702 2004-10-20 Joel Brobecker <brobecker@gnat.com>
21703
21704 * linux-x86-64-low.c (ARCH_SET_GS): Add definition if missing.
21705 (ARCH_SET_FS): Likewise.
21706 (ARCH_GET_FS): Likewise.
21707 (ARCH_GET_GS): Likewise.
21708
21709 2004-10-16 Daniel Jacobowitz <dan@debian.org>
21710
21711 * linux-i386-low.c (ps_get_thread_area): New.
21712 * linux-x86-64-low.c (ps_get_thread_area): New.
21713 * linux-low.c: Include <sys/syscall.h>.
21714 (linux_kill_one_process): Don't kill the first thread here.
21715 (linux_kill): Kill the first thread here.
21716 (kill_lwp): New function.
21717 (send_sigstop, linux_send_signal): Use it.
21718 * proc-service.c: Clean up #ifdefs.
21719 (fpregset_info): Delete.
21720 (ps_lgetregs): Update and enable implementation.
21721 (ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs): Remove disabled
21722 implementations.
21723 * remote-utils.c (struct sym_cache, symbol_cache): New.
21724 (input_interrupt): Print a clearer message.
21725 (async_io_enabled): New variable.
21726 (enable_async_io, disable_async_io): Use it. Update comments.
21727 (look_up_one_symbol): Use the symbol cache.
21728 * thread-db.c (thread_db_look_up_symbols): New function.
21729 (thread_db_init): Update comments. Call thread_db_look_up_symbols.
21730
21731 2004-10-16 Daniel Jacobowitz <dan@debian.org>
21732
21733 * configure.in: Test for -rdynamic.
21734 * configure: Regenerated.
21735 * Makefile (INTERNAL_LDFLAGS): New.
21736 (gdbserver, gdbreplay): Use it.
21737
21738 2004-09-02 Andrew Cagney <cagney@gnu.org>
21739
21740 * Makefile.in (TAGS): Replace TM_FILE with DEPRECATED_TM_FILE.
21741
21742 2004-03-23 Daniel Jacobowitz <drow@mvista.com>
21743
21744 * linux-low.c (linux_wait): Clear all_processes list also.
21745
21746 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
21747
21748 * linux-low.c: Include <errno.h>. Remove extern declaration of
21749 errno.
21750
21751 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
21752
21753 * gdbreplay.c, server.h, utils.c: Update copyright years.
21754
21755 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
21756
21757 * server.c (main): Print child status or termination signal from
21758 variable 'signal', not 'sig'.
21759
21760 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
21761
21762 * linux-low.c (linux_read_memory): Change return type to
21763 int. Check for and return error from ptrace().
21764 * target.c (read_inferior_memory): Change return type to int. Pass
21765 back return status from the_target->read_memory().
21766 * target.h (struct target_ops): Adapt *read_memory() prototype.
21767 Update comment.
21768 (read_inferior_memory): Adapt prototype.
21769 * server.c (main): Return an error packet if
21770 read_inferior_memory() returns an error.
21771
21772 2004-03-04 Daniel Jacobowitz <drow@mvista.com>
21773
21774 * Makefile.in (distclean): Remove config.h, stamp-h, and config.log.
21775 Unify with other clean targets.
21776
21777 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
21778
21779 * server.c (handle_v_cont): Call set_desired_inferior.
21780
21781 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
21782
21783 * remote-utils.c (prepare_resume_reply): Always supply "thread:".
21784
21785 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
21786
21787 * linux-low.c (linux_wait): Unblock async I/O.
21788 (linux_resume): Block and enable async I/O.
21789 * remote-utils.c (block_async_io, unblock_async_io): New functions.
21790 * server.h (block_async_io, unblock_async_io): Add prototypes.
21791
21792 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
21793
21794 * remote-utils.c (remote_open): Print a status notice after
21795 opening a TCP port.
21796 * server.c (attach_inferior): Print a status notice after
21797 attaching.
21798
21799 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
21800
21801 * linux-arm-low.c (arm_get_pc): Print out stop PC in debug mode.
21802
21803 2004-02-26 Daniel Jacobowitz <drow@mvista.com>
21804
21805 * remote-utils.c (write_enn): Use "E01" instead of "ENN" for the
21806 error packet.
21807 * server.c, target.h: Update copyright years.
21808
21809 2004-02-25 Roland McGrath <roland@redhat.com>
21810
21811 * target.h (struct target_ops): New member `read_auxv'.
21812 * server.c (handle_query): Handle qPart:auxv:read: query using that.
21813 * linux-low.c (linux_read_auxv): New function.
21814 (linux_target_ops): Initialize `read_auxv' member to that.
21815
21816 2004-02-17 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
21817
21818 Committed by Jim Blandy <jimb@redhat.com>.
21819
21820 * linux-s390-low.c (s390_num_regs): Update.
21821 (s390_regmap): Remove control registers. Use __s390x__ predefine
21822 instead of GPR_SIZE to distiguish s390 and s390x targets.
21823
21824 2004-01-31 Daniel Jacobowitz <drow@mvista.com>
21825
21826 * linux-low.c: Update copyright year.
21827 (check_removed_breakpoint): Clear pending_is_breakpoint.
21828 (linux_set_resume_request, linux_queue_one_thread)
21829 (resume_status_pending_p): New functions.
21830 (linux_continue_one_thread): Use process->resume.
21831 (linux_resume): Only resume threads if there are no pending events.
21832 * linux-low.h (struct process_info): Add resume request
21833 pointer.
21834
21835 2004-01-30 Daniel Jacobowitz <drow@mvista.com>
21836
21837 * regcache.c (new_register_cache): Clear the allocated register
21838 buffer. Suggested by Atsushi Nemoto <anemo@mba.ocn.ne.jp>.
21839
21840 2003-10-13 Daniel Jacobowitz <drow@mvista.com>
21841
21842 * linux-low.c (linux_resume): Take a struct thread_resume *
21843 argument.
21844 (linux_wait): Update call.
21845 (resume_ptr): New static variable.
21846 (linux_continue_one_thread): Renamed from
21847 linux_continue_one_process. Use resume_ptr.
21848 (linux_resume): Use linux_continue_one_thread.
21849 * server.c (handle_v_cont, handle_v_requests): New functions.
21850 (myresume): New function.
21851 (main): Handle 'v' case.
21852 * target.h (struct thread_resume): New type.
21853 (struct target_ops): Change argument of "resume" to struct
21854 thread_resume *.
21855 (myresume): Delete macro.
21856
21857 2003-08-08 H.J. Lu <hongjiu.lu@intel.com>
21858
21859 * Makefile.in (install-only): Create dest dir. Support DESTDIR.
21860 (uninstall): Support DESTDIR.
21861
21862 Mon Jul 21 20:09:34 UTC 2003 Brendan Conoboy <blc@redhat.com>
21863
21864 * configure.srv: Add xscale*linux copy of arm*linux entry.
21865
21866 2003-07-24 Daniel Jacobowitz <drow@mvista.com>
21867
21868 * linux-arm-low.c (arm_reinsert_addr): New function.
21869 (the_low_target): Add arm_reinsert_addr.
21870
21871 2003-07-08 Mark Kettenis <kettenis@gnu.org>
21872
21873 * mem-break.c: Remove whitespace at end of file.
21874
21875 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
21876
21877 * configure.in: Check whether we need to prototype strerror.
21878 * server.h: Optionally prototype strerror.
21879 * gdbreplay.c (perror_with_name): Use strerror.
21880 * linux-low.c (linux_attach_lwp): Use strerror.
21881 * utils.c (perror_with_name): Use strerror.
21882 * config.in, configure: Regenerated.
21883
21884 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
21885
21886 * linux-sh-low.c (sh_regmap): Fix FP register offsets, reported by
21887 SUGIOKA Toshinobu <sugioka@itonet.co.jp>.
21888
21889 2003-06-20 Daniel Jacobowitz <drow@mvista.com>
21890
21891 * Makefile.in (SFILES): Update.
21892 * low-hppabsd.c, low-lynx.c, low-nbsd.c, low-sim.c, low-sparc.c,
21893 low-sun3.c: Remove files.
21894
21895 2003-06-17 Daniel Jacobowitz <drow@mvista.com>
21896
21897 * linux-low.c: Move comment to linux_thread_alive where it belonged.
21898 (linux_detach_one_process, linux_detach): New functions.
21899 (linux_target_ops): Add linux_detach.
21900 * server.c (main): Handle 'D' packet.
21901 * target.h (struct target_ops): Add "detach" member.
21902 (detach_inferior): Define.
21903
21904 2003-06-13 Mark Kettenis <kettenis@gnu.org>
21905
21906 From Kelley Cook <kelleycook@wideopenwest.com>:
21907 * configure.srv: Accept i[34567]86 variants.
21908
21909 2003-06-05 Daniel Jacobowitz <drow@mvista.com>
21910
21911 * linux-low.c (linux_wait_for_event): Correct comment typos.
21912 (linux_resume_one_process): Call check_removed_breakpoint.
21913 (linux_send_signal): New function.
21914 (linux_target_ops): Add linux_send_signal.
21915 * remote-utils.c (putpkt, input_interrupt): Use send_signal instead
21916 of kill.
21917 * target.h (struct target_ops): Add send_signal.
21918
21919 2003-05-29 Jim Blandy <jimb@redhat.com>
21920
21921 * linux-low.c (usr_store_inferior_registers): Transfer buf in
21922 PTRACE_XFER_TYPE-sized chunks, not int-sized chunks. Otherwise,
21923 if 'int' is smaller than PTRACE_XFER_TYPE, you end up throwing
21924 away part of the register's value.
21925
21926 2003-03-26 Daniel Jacobowitz <drow@mvista.com>
21927
21928 * linux-low.c (linux_create_inferior): Use __SIGRTMIN.
21929 (linux_wait_for_event, linux_init_signals): Likewise.
21930
21931 2003-03-17 Daniel Jacobowitz <drow@mvista.com>
21932
21933 * configure.in: Check for stdlib.h.
21934 * configure: Regenerated.
21935 * config.in: Regenerated.
21936
21937 2003-01-04 Andreas Schwab <schwab@suse.de>
21938
21939 * linux-m68k-low.c (m68k_num_regs): Define to 29 instead of 31.
21940
21941 2003-01-02 Andrew Cagney <ac131313@redhat.com>
21942
21943 * Makefile.in: Remove obsolete code.
21944
21945 2002-11-20 Daniel Jacobowitz <drow@mvista.com>
21946
21947 * linux-s390-low.c (s390_regmap): Check GPR_SIZE instead of
21948 defined(PT_FPR0_HI).
21949
21950 2002-11-17 Stuart Hughes <seh@zee2.com>
21951
21952 * linux-arm-low.c (arm_num_regs): Increase.
21953 (arm_regmap): Include status register.
21954
21955 2002-11-17 Daniel Jacobowitz <drow@mvista.com>
21956
21957 * linux-low.c (register_addr): Remove incorrect -1 check.
21958
21959 2002-08-29 Daniel Jacobowitz <drow@mvista.com>
21960
21961 * linux-low.c (linux_create_inferior): Call setpgid. Return
21962 the new PID.
21963 (unstopped_p, linux_signal_pid): Remove.
21964 (linux_target_ops): Remove linux_signal_pid.
21965 * remote-utils.c (putpkt, input_interrupt): Use signal_pid
21966 global instead of target method.
21967 * target.h (struct target_ops): Remove signal_pid. Update comment
21968 for create_inferior.
21969 * server.c (signal_pid): New variable.
21970 (create_inferior): Set signal_pid. Block SIGTTOU and SIGTTIN in
21971 gdbserver. Set the child to be the foreground process group.
21972 (attach_inferior): Set signal_pid.
21973
21974 2002-08-23 Daniel Jacobowitz <drow@mvista.com>
21975
21976 * ChangeLog: New file, with entries from gdb/ChangeLog after GDB 5.2.
21977
21978 2002-08-20 Jim Blandy <jimb@redhat.com>
21979
21980 * Makefile.in (LDFLAGS): Allow the configure script to establish a
21981 default for this.
21982
21983 2002-08-01 Andrew Cagney <cagney@redhat.com>
21984
21985 * Makefile.in: Make chill references obsolete.
21986
21987 2002-07-24 Kevin Buettner <kevinb@redhat.com>
21988
21989 * configure.in (unistd.h): Add to AC_CHECK_HEADERS list.
21990 * configure: Regenerate.
21991 * config.in: Regenerate.
21992
21993 2002-07-09 David O'Brien <obrien@FreeBSD.org>
21994
21995 * gdbreplay.c (stdlib.h, unistd.h): Conditionaly include.
21996 (perror_with_name, remote_close, remote_open, expect, play): Static.
21997
21998 2002-07-04 Michal Ludvig <mludvig@suse.cz>
21999
22000 * linux-x86-64-low.c (x86_64_regmap): Make it an array of
22001 byte offsets instead of an array of indexes.
22002 (x86_64_store_gregset, x86_64_store_fpregset): Parameter made const.
22003
22004 2002-06-13 Daniel Jacobowitz <drow@mvista.com>
22005
22006 * regcache.c: Add comment.
22007
22008 2002-06-11 Daniel Jacobowitz <drow@mvista.com>
22009
22010 * thread-db.c: New file.
22011 * proc-service.c: New file.
22012 * acinclude.m4: New file.
22013 * Makefile.in: Add GDBSERVER_LIBS, gdb_proc_service_h,
22014 proc-service.o, and thread-db.o.
22015 (linux-low.o): Add USE_THREAD_DB.
22016 * acconfig.h: Add HAVE_PRGREGSET_T, HAVE_PRFPREGSET_T,
22017 HAVE_LWPID_T, HAVE_PSADDR_T, and PRFPREGSET_T_BROKEN.
22018 * aclocal.m4: Regenerated.
22019 * config.in: Regenerated.
22020 * configure: Regenerated.
22021 * configure.in: Check for proc_service.h, sys/procfs.h,
22022 thread_db.h, and linux/elf.h headrs.
22023 Check for lwpid_t, psaddr_t, prgregset_t, prfpregset_t, and
22024 PRFPREGSET_T_BROKEN. Introduce srv_thread_depfiles and USE_THREAD_DB.
22025 Check for -lthread_db and thread support.
22026 * configure.srv: Enable thread_db support for ARM, i386, MIPS,
22027 PowerPC, and SuperH.
22028 * i387-fp.c: Constify arguments.
22029 * i387-fp.h: Likewise.
22030 * inferiors.c: (struct thread_info): Renamed from
22031 `struct inferior_info'. Remove PID member. Use generic inferior
22032 list header. All uses updated.
22033 (inferiors, signal_pid): Removed.
22034 (all_threads): New variable.
22035 (get_thread): Define.
22036 (add_inferior_to_list): New function.
22037 (for_each_inferior): New function.
22038 (change_inferior_id): New function.
22039 (add_inferior): Removed.
22040 (remove_inferior): New function.
22041 (add_thread): New function.
22042 (free_one_thread): New function.
22043 (remove_thread): New function.
22044 (clear_inferiors): Use for_each_inferior and free_one_thread.
22045 (find_inferior): New function.
22046 (find_inferior_id): New function.
22047 (inferior_target_data): Update argument type.
22048 (set_inferior_target_data): Likewise.
22049 (inferior_regcache_data): Likewise.
22050 (set_inferior_regcache_data): Likewise.
22051 * linux-low.c (linux_bp_reinsert): Remove.
22052 (all_processes, stopping_threads, using_thrads)
22053 (struct pending_signals, debug_threads, pid_of): New.
22054 (inferior_pid): Replace with macro.
22055 (struct inferior_linux_data): Remove.
22056 (get_stop_pc, add_process): New functions.
22057 (linux_create_inferior): Restore SIGRTMIN+1 before calling exec.
22058 Use add_process and add_thread.
22059 (linux_attach_lwp): New function, based on old linux_attach. Use
22060 add_process and add_thread. Set stop_expected for new threads.
22061 (linux_attach): New function.
22062 (linux_kill_one_process): New function.
22063 (linux_kill): Kill all LWPs.
22064 (linux_thread_alive): Use find_inferior_id.
22065 (check_removed_breakpoints, status_pending_p): New functions.
22066 (linux_wait_for_process): Renamed from linux_wait_for_one_inferior.
22067 Update. Use WNOHANG. Wait for cloned processes also. Update process
22068 struct for the found process.
22069 (linux_wait_for_event): New function.
22070 (linux_wait): Use it. Support LWPs.
22071 (send_sigstop, wait_for_sigstop, stop_all_processes)
22072 (linux_resume_one_process, linux_continue_one_process): New functions.
22073 (linux_resume): Support LWPs.
22074 (REGISTER_RAW_SIZE): Remove.
22075 (fetch_register): Use register_size instead. Call supply_register.
22076 (usr_store_inferior_registers): Likewise. Call collect_register.
22077 Fix recursive case.
22078 (regsets_fetch_inferior_registers): Improve error message.
22079 (regsets_store_inferior_registers): Add debugging.
22080 (linux_look_up_symbols): Call thread_db_init if USE_THREAD_DB.
22081 (unstopped_p, linux_signal_pid): New functions.
22082 (linux_target_ops): Add linux_signal_pid.
22083 (linux_init_signals): New function.
22084 (initialize_low): Call it. Initialize using_threads.
22085 * regcache.c (inferior_regcache_data): Add valid
22086 flag.
22087 (get_regcache): Fetch registers lazily. Add fetch argument
22088 and update all callers.
22089 (regcache_invalidate_one, regcache_invalidate): New
22090 functions.
22091 (new_register_cache): Renamed from create_register_cache.
22092 Return the new regcache.
22093 (free_register_cache): Change argument to a void *.
22094 (registers_to_string, registers_from_string): Call get_regcache
22095 with fetch flag set.
22096 (register_data): Make static. Pass fetch flag to get_regcache.
22097 (supply_register): Call get_regcache with fetch flag clear.
22098 (collect_register): Call get_regcache with fetch flag set.
22099 (collect_register_as_string): New function.
22100 * regcache.h: Update.
22101 * remote-utils.c (putpkt): Flush after debug output and use
22102 stderr.
22103 Handle input interrupts while waiting for an ACK.
22104 (input_interrupt): Use signal_pid method.
22105 (getpkt): Flush after debug output and use stderr.
22106 (outreg): Use collect_register_as_string.
22107 (new_thread_notify, dead_thread_notify): New functions.
22108 (prepare_resume_reply): Check using_threads. Set thread_from_wait
22109 and general_thread.
22110 (look_up_one_symbol): Flush after debug output.
22111 * server.c (step_thread, server_waiting): New variables.
22112 (start_inferior): Don't use signal_pid. Update call to mywait.
22113 (attach_inferior): Update call to mywait.
22114 (handle_query): Handle qfThreadInfo and qsThreadInfo.
22115 (main): Don't fetch/store registers explicitly. Use
22116 set_desired_inferior. Support proposed ``Hs'' packet. Update
22117 calls to mywait.
22118 * server.h: Update.
22119 (struct inferior_list, struct_inferior_list_entry): New.
22120 * target.c (set_desired_inferior): New.
22121 (write_inferior_memory): Constify.
22122 (mywait): New function.
22123 * target.h: Update.
22124 (struct target_ops): New signal_pid method.
22125 (mywait): Removed macro, added prototype.
22126
22127 * linux-low.h (regset_func): Removed.
22128 (regset_fill_func, regset_store_func): New.
22129 (enum regset_type): New.
22130 (struct regset_info): Add type field. Use new operation types.
22131 (struct linux_target_ops): stop_pc renamed to get_pc.
22132 Add decr_pc_after_break and breakpoint_at.
22133 (get_process, get_thread_proess, get_process_thread)
22134 (strut process_info, all_processes, linux_attach_lwp)
22135 (thread_db_init): New.
22136
22137 * linux-arm-low.c (arm_get_pc, arm_set_pc,
22138 arm_breakpoint, arm_breakpoint_len, arm_breakpoint_at): New.
22139 (the_low_target): Add new members.
22140 * linux-i386-low.c (i386_store_gregset, i386_store_fpregset)
22141 (i386_store_fpxregset): Constify.
22142 (target_regsets): Add new kind identifier.
22143 (i386_get_pc): Renamed from i386_stop_pc. Simplify.
22144 (i386_set_pc): Add debugging.
22145 (i386_breakpoint_at): New function.
22146 (the_low_target): Add new members.
22147 * linux-mips-low.c (mips_get_pc, mips_set_pc)
22148 (mips_breakpoint, mips_breakpoint_len, mips_reinsert_addr)
22149 (mips_breakpoint_at): New.
22150 (the_low_target): Add new members.
22151 * linux-ppc-low.c (ppc_get_pc, ppc_set_pc)
22152 (ppc_breakpoint, ppc_breakpoint_len, ppc_breakpoint_at): New.
22153 (the_low_target): Add new members.
22154 * linux-sh-low.c (sh_get_pc, sh_set_pc)
22155 (sh_breakpoint, sh_breakpoint_len, sh_breakpoint_at): New.
22156 (the_low_target): Add new members.
22157 * linux-x86-64-low.c (target_regsets): Add new kind
22158 identifier.
22159
22160 2002-05-15 Daniel Jacobowitz <drow@mvista.com>
22161
22162 From Martin Pool <mbp@samba.org>:
22163 * server.c (gdbserver_usage): New function.
22164 (main): Call it.
22165
22166 2002-05-14 Daniel Jacobowitz <drow@mvista.com>
22167
22168 * mem-break.c (reinsert_breakpoint_by_bp): Correct typo
22169 stop_at -> stop_pc.
22170
22171 2002-05-04 Andrew Cagney <ac131313@redhat.com>
22172
22173 * Makefile.in: Remove obsolete code.
22174
22175 2002-04-24 Michal Ludvig <mludvig@suse.cz>
22176
22177 * linux-low.c (regsets_fetch_inferior_registers),
22178 (regsets_store_inferior_registers): Removed cast to int from
22179 ptrace() calls.
22180 * regcache.h: Added declaration of struct inferior_info.
22181
22182 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
22183
22184 * inferiors.c (struct inferior_info): Add regcache_data.
22185 (add_inferior): Call create_register_cache.
22186 (clear_inferiors): Call free_register_cache.
22187 (inferior_regcache_data, set_inferior_regcache_data): New functions.
22188 * regcache.c (struct inferior_regcache_data): New.
22189 (registers): Remove.
22190 (get_regcache): New function.
22191 (create_register_cache, free_register_cache): New functions.
22192 (set_register_cache): Don't initialize the register cache here.
22193 (registers_to_string, registers_from_string, register_data): Call
22194 get_regcache.
22195 * regcache.h: Add prototypes.
22196 * server.h: Likewise.
22197
22198 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
22199
22200 * mem-break.c: New file.
22201 * mem-break.h: New file.
22202 * Makefile.in: Add mem-break.o rule; update server.h
22203 dependencies.
22204 * inferiors.c (struct inferior_info): Add target_data
22205 member.
22206 (clear_inferiors): Free target_data member if set.
22207 (inferior_target_data, set_inferior_target_data): New functions.
22208 * linux-i386-low.c (i386_breakpoint, i386_breakpoint_len)
22209 (i386_stop_pc, i386_set_pc): New. Add to the_low_target.
22210 * linux-low.c (linux_bp_reinsert): New variable.
22211 (struct inferior_linux_data): New.
22212 (linux_create_inferior): Use set_inferior_target_data.
22213 (linux_attach): Likewise. Call add_inferior.
22214 (linux_wait_for_one_inferior): New function.
22215 (linux_wait): Call it.
22216 (linux_write_memory): Add const.
22217 (initialize_low): Call set_breakpoint_data.
22218 * linux-low.h (struct linux_target_ops): Add breakpoint
22219 handling members.
22220 * server.c (attach_inferior): Remove extra add_inferior
22221 call.
22222 * server.h: Include mem-break.h. Update inferior.c
22223 prototypes.
22224 * target.c (read_inferior_memory)
22225 (write_inferior_memory): New functions.
22226 * target.h (read_inferior_memory)
22227 (write_inferior_memory): Change macros to prototypes.
22228 (struct target_ops): Update comments. Add const to write_memory
22229 definition.
22230
22231 2002-04-11 Daniel Jacobowitz <drow@mvista.com>
22232
22233 * linux-low.c (usr_store_inferior_registers): Support
22234 registers which are allowed to fail to store.
22235 * linux-low.h (linux_target_ops): Likewise.
22236 * linux-ppc-low.c (ppc_regmap): Support FPSCR.
22237 (ppc_cannot_store_register): FPSCR may not be storable.
22238
22239 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
22240
22241 * server.h: Include <string.h> if HAVE_STRING_H.
22242 * ChangeLog: Correct paths in last ChangeLog entry.
22243
22244 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
22245
22246 * linux-low.h: Remove obsolete prototypes.
22247 (struct linux_target_ops): New.
22248 (extern the_low_target): New.
22249 * linux-low.c (num_regs, regmap): Remove declarations.
22250 (register_addr): Use the_low_target explicitly.
22251 (fetch_register): Likewise.
22252 (usr_fetch_inferior_registers): Likewise.
22253 (usr_store_inferior_registers): Likewise.
22254 * linux-arm-low.c (num_regs): Remove.
22255 (arm_num_regs): Define.
22256 (arm_regmap): Renamed from regmap, made static.
22257 (arm_cannot_fetch_register): Renamed from cannot_fetch_register,
22258 made static.
22259 (arm_cannot_store_register): Renamed from cannot_store_register,
22260 made static.
22261 (the_low_target): New.
22262 * linux-i386-low.c (num_regs): Remove.
22263 (i386_num_regs): Define.
22264 (i386_regmap): Renamed from regmap, made static.
22265 (i386_cannot_fetch_register): Renamed from cannot_fetch_register,
22266 made static.
22267 (i386_cannot_store_register): Renamed from cannot_store_register,
22268 made static.
22269 (the_low_target): New.
22270 * linux-ia64-low.c (num_regs): Remove.
22271 (ia64_num_regs): Define.
22272 (ia64_regmap): Renamed from regmap, made static.
22273 (ia64_cannot_fetch_register): Renamed from cannot_fetch_register,
22274 made static.
22275 (ia64_cannot_store_register): Renamed from cannot_store_register,
22276 made static.
22277 (the_low_target): New.
22278 * linux-m68k-low.c (num_regs): Remove.
22279 (m68k_num_regs): Define.
22280 (m68k_regmap): Renamed from regmap, made static.
22281 (m68k_cannot_fetch_register): Renamed from cannot_fetch_register,
22282 made static.
22283 (m68k_cannot_store_register): Renamed from cannot_store_register,
22284 made static.
22285 (the_low_target): New.
22286 * linux-mips-low.c (num_regs): Remove.
22287 (mips_num_regs): Define.
22288 (mips_regmap): Renamed from regmap, made static.
22289 (mips_cannot_fetch_register): Renamed from cannot_fetch_register,
22290 made static.
22291 (mips_cannot_store_register): Renamed from cannot_store_register,
22292 made static.
22293 (the_low_target): New.
22294 * linux-ppc-low.c (num_regs): Remove.
22295 (ppc_num_regs): Define.
22296 (ppc_regmap): Renamed from regmap, made static.
22297 (ppc_cannot_fetch_register): Renamed from cannot_fetch_register,
22298 made static.
22299 (ppc_cannot_store_register): Renamed from cannot_store_register,
22300 made static.
22301 (the_low_target): New.
22302 * linux-s390-low.c (num_regs): Remove.
22303 (s390_num_regs): Define.
22304 (s390_regmap): Renamed from regmap, made static.
22305 (s390_cannot_fetch_register): Renamed from cannot_fetch_register,
22306 made static.
22307 (s390_cannot_store_register): Renamed from cannot_store_register,
22308 made static.
22309 (the_low_target): New.
22310 * linux-sh-low.c (num_regs): Remove.
22311 (sh_num_regs): Define.
22312 (sh_regmap): Renamed from regmap, made static.
22313 (sh_cannot_fetch_register): Renamed from cannot_fetch_register,
22314 made static.
22315 (sh_cannot_store_register): Renamed from cannot_store_register,
22316 made static.
22317 (the_low_target): New.
22318 * linux-x86-64-low.c (x86_64_regmap): Renamed from regmap.
22319 (the_low_target): New.
22320
22321 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
22322
22323 * Makefile.in: Add stamp-h target.
22324 * configure.in: Create stamp-h.
22325 * configure: Regenerated.
22326
22327 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
22328
22329 * inferiors.c: New file.
22330 * target.c: New file.
22331 * target.h: New file.
22332 * Makefile.in: Add target.o and inferiors.o. Update
22333 dependencies.
22334 * linux-low.c (inferior_pid): New static variable,
22335 moved from server.c.
22336 (linux_create_inferior): Renamed from create_inferior.
22337 Call add_inferior. Return 0 on success instead of a PID.
22338 (linux_attach): Renamed from myattach.
22339 (linux_kill): Renamed from kill_inferior. Call clear_inferiors ().
22340 (linux_thread_alive): Renamed from mythread_alive.
22341 (linux_wait): Renamed from mywait. Call clear_inferiors () if the
22342 child dies.
22343 (linux_resume): Renamed from myresume. Add missing ``return 0''.
22344 (regsets_store_inferior_registers): Correct error message.
22345 Add missing ``return 0''.
22346 (linux_fetch_registers): Renamed from fetch_inferior_registers.
22347 (linux_store_registers): Renamed from store_inferior_registers.
22348 (linux_read_memory): Renamed from read_inferior_memory.
22349 (linux_write_memory): Renamed from write_inferior_memory.
22350 (linux_target_ops): New structure.
22351 (initialize_low): Call set_target_ops ().
22352 * remote-utils.c (unhexify): New function.
22353 (hexify): New function.
22354 (input_interrupt): Send signals to ``signal_pid''.
22355 * server.c (inferior_pid): Remove.
22356 (start_inferior): Update create_inferior call.
22357 (attach_inferior): Call add_inferior.
22358 (handle_query): New function.
22359 (main): Call handle_query for `q' packets.
22360 * server.h: Include "target.h". Remove obsolete prototypes.
22361 Add prototypes for "inferiors.c", "target.c", hexify, and unhexify.
22362
22363 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
22364
22365 * Makefile.in: Add WARN_CFLAGS. Update configury
22366 dependencies.
22367 * configure.in: Check for <string.h>
22368 * configure: Regenerate.
22369 * config.in: Regenerate.
22370 * gdbreplay.c: Include needed system headers.
22371 (remote_open): Remove strchr prototype.
22372 * linux-low.h: Correct #ifdef to HAVE_LINUX_USRREGS.
22373 * regcache.c (supply_register): Change buf argument to const void *.
22374 (supply_register_by_name): Likewise.
22375 (collect_register): Change buf argument to void *.
22376 (collect_register_by_name): Likewise.
22377 * regcache.h: Add missing prototypes.
22378 * remote-utils.c: Include <arpa/inet.h> for inet_ntoa.
22379 * server.c (handle_query): New function.
22380 (attached): New static variable, moved out of main.
22381 (main): Quiet longjmp clobber warnings.
22382 * server.h: Add ATTR_NORETURN and ATTR_FORMAT. Update prototypes.
22383 * utils.c (error): Remove NORETURN.
22384 (fatal): Likewise.
This page took 0.816326 seconds and 5 git commands to generate.