]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blame - gdbserver/ChangeLog
Add Makefile.in entry for "Add NetBSD/aarch64 gdbserver support"
[thirdparty/binutils-gdb.git] / gdbserver / ChangeLog
CommitLineData
bbe90b5d 12020-10-07 Anton Kolesov <anton.kolesov@synopsys.com>
6d2d7c56
AK
2
3 * configure.srv: Support ARC architecture.
4 * Makefile.in: Add linux-arc-low.cc and arch/arc.o.
5 * linux-arc-low.cc: New file.
6
48491055
KR
72020-10-07 Kamil Rytarowski <n54@gmx.com>
8
9 * netbsd-low.cc (get_dynamic, get_r_debug, read_one_ptr)
10 (netbsd_qxfer_libraries_svr4): Remove "target" argument and update.
11 (netbsd_process_target::qxfer_libraries_svr4): Update.
12
2be01f63
KR
132020-10-07 Kamil Rytarowski <n54@gmx.com>
14
15 * netbsd-low.cc: Fix whitespace formatting.
16 * netbsd-amd64-low.cc: Likewise.
17
91e5e8db
KR
182020-10-07 Kamil Rytarowski <n54@gmx.com>
19
20 * netbsd-low.cc (netbsd_process_target::read_memory)
21 (netbsd_process_target::write_memory): Update.
22
9529c852
KR
232020-10-07 Kamil Rytarowski <n54@gmx.com>
24
25 * netbsd-aarch64-low.cc: Add.
26 * Makefile.in (SFILES): Register "netbsd-aarch64-low.c".
27 * configure.srv: Add aarch64*-*-netbsd*.
28
981b570a
SV
292020-10-06 Shahab Vahedi <shahab@synopsys.com>
30
31 * regcache.cc (register_data): Remove unused "fetch" argument.
32
6b01403b
SM
332020-10-02 Simon Marchi <simon.marchi@polymtl.ca>
34
35 * server.cc (handle_monitor_command): Handle "set
36 debug-event-loop".
37 (captured_main): Handle "--debug-event-loop".
38 (monitor_show_help): Mention new setting.
39 (gdbserver_usage): Mention new flag.
40
2554f6f5
SM
412020-10-02 Simon Marchi <simon.marchi@polymtl.ca>
42
43 * linux-low.cc (linux_process_target::async): Pass name to
44 add_file_handler.
45 * remote-utils.cc (handle_accept_event): Likewise.
46 (remote_open): Likewise.
47
8b667fae
KR
482020-10-01 Kamil Rytarowski <n54@gmx.com>
49
50 * netbsd-i386-low.cc: Add.
51 * Makefile.in (SFILES): Register "netbsd-i386-low.c".
52 * configure.srv: Add i[34567]86-*-netbsd*.
53
15397b0e
KR
542020-10-01 Kamil Rytarowski <n54@gmx.com>
55
56 * netbsd-amd64-low.cc (netbsd_x86_64_arch_setup): Remove.
57 (netbsd_target_regsets): Now const.
58 (the_low_target): Remove.
59 (class netbsd_amd64_target, the_netbsd_amd64_target)
60 (the_netbsd_target): Add.
61 * netbsd-low.cc (netbsd_process_target::post_create_inferior): Call
62 low_arch_setup ().
63 (netbsd_process_target::fetch_registers)
64 (netbsd_process_target::store_registers, initialize_low): Update.
65 (the_netbsd_target): Remove.
66 * netbsd-low.h (netbsd_target_regsets, netbsd_target_ops)
67 (the_low_target, netbsd_tdesc): Remove.
68 (netbsd_process_target::get_regs_info)
69 (netbsd_process_target::low_arch_setup): Add.
70
99bb393f
HD
712020-09-23 Hannes Domani <ssbssa@yahoo.de>
72
73 * win32-low.cc: Remove local wow64_process variable.
74 * win32-low.h: Remove local wow64_process variable.
75
b60cea74
TT
762020-09-18 Tom Tromey <tromey@adacore.com>
77
78 * netbsd-low.h (class netbsd_process_target) <wait>: Update.
79 * netbsd-low.cc (netbsd_waitpid, netbsd_wait)
80 (netbsd_process_target::wait): Change type of target_options.
81 * win32-low.h (class win32_process_target) <wait>: Update.
82 * win32-low.cc (win32_process_target::wait): Update.
83 * target.h (class process_stratum_target) <wait>: Update.
84 (mywait): Update.
85 * target.cc (mywait, target_wait): Change type of "options".
86 * linux-low.h (class linux_process_target) <wait, wait_1>:
87 Update.
88 * linux-low.cc (linux_process_target::wait)
89 (linux_process_target::wait_1): Update.
90
db92ac45
TT
912020-09-15 Tom Tromey <tromey@adacore.com>
92
93 * linux-x86-low.cc (xmltarget_i386_linux_no_xml)
94 (xmltarget_amd64_linux_no_xml): Now arrays.
95
27087b7f
TT
962020-09-14 Tom Tromey <tromey@adacore.com>
97
98 * tracepoint.cc (eval_result_names): Now const.
99 * ax.cc (gdb_agent_op_names): Now const.
100
62ba5048
KR
1012020-09-10 Kamil Rytarowski <n54@gmx.com>
102
103 * netbsd-low.cc: Add.
104 * netbsd-low.h: Likewise.
105 * netbsd-amd64-low.cc: Likewise.
106 * Makefile.in (SFILES): Register "netbsd-low.cc", "netbsd-low.h",
107 "netbsd-amd64-low.cc".
108 * configure.srv: Add x86_64-*-netbsd*.
109
ece5bc8a
SM
1102020-08-13 Simon Marchi <simon.marchi@polymtl.ca>
111
112 * server.cc (captured_main): Accept multiple `--selftest=`
113 options. Pass all `--selftest=` arguments to run_tests.
114
c8693053
RO
1152020-07-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
116
117 * configure, config.in: Regenerate.
118
05a6b8c2
EZ
1192020-07-26 Eli Zaretskii <eliz@gnu.org>
120
121 * configure.ac (AC_CHECK_HEADERS): Add ws2tcpip.h.
122 When checking whether socklen_t type is defined, use ws2tcpip.h if
123 it is available and sys/socket.h isn't.
124 * configure: Regenerate.
125 * config.in: Regenerate.
126
028a4603
PA
1272020-07-22 Pedro Alves <pedro@palves.net>
128
129 * inferiors.cc (switch_to_process): New, moved here from
130 thread-db.cc, and made extern.
131 * inferiors.h (switch_to_process): Declare.
132 * server.cc: Include "gdbsupport/scoped_restore.h".
133 (handle_qxfer_threads_proper): Now returns bool. Prepare to
134 access memory around target calls.
135 (handle_qxfer_threads): Handle errors.
136 * thread-db.cc (switch_to_process): Moved to inferiors.cc.
137
05c309a8
SM
1382020-07-21 Simon Marchi <simon.marchi@efficios.com>
139
140 * linux-low.cc (stopped_pids): Make static.
141
0e267416
AB
1422020-07-17 Andrew Burgess <andrew.burgess@embecosm.com>
143
144 * tdesc.cc (allocate_target_description): Add header comment.
145 (target_desc_deleter::operator()): New function.
146 * tdesc.h (struct target_desc): Declare as final.
147
b315b67d
SM
1482020-07-13 Simon Marchi <simon.marchi@polymtl.ca>
149
150 * server.cc (handle_query): Use std::vector of
151 std::string for `qsupported` vector. Use separate
152 vector for unknowns.
153 * target.h (class process_stratum_target) <process_qsupported>:
154 Change parameters to array_view of const char *.
155 (target_process_qsupported): Remove `count` parameter.
156 * target.cc (process_stratum_target::process_qsupported): Change
157 parameters to array_view of const char *.
158 * linux-x86-low.cc (class x86_target) <process_qsupported>:
159 Likewise.
160
f638ed73
TV
1612020-06-29 Tom de Vries <tdevries@suse.de>
162
163 * ax.h: Include gdbsupport/debug_agent.h.
164
fbf42f4e
AB
1652020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
166
167 * tdesc.cc (struct tdesc_compatible_info): New struct.
168 (tdesc_compatible_info_list): New function.
169 (tdesc_compatible_info_arch_name): New function.
170
013e3554
TBA
1712020-06-22 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
172
173 Use std::list to stop pending signal instead of manually-created
174 linked list.
175 * linux-low.h: Include <list>.
176 (struct pending_signal): Move here from linux-low.cc.
177 (struct lwp_info) <pending_signals>
178 <pending_signals_to_report>: Update the type.
179 * linux-low.cc (struct pending_signals): Remove.
180 (linux_process_target::delete_lwp)
181 (linux_process_target::add_lwp)
182 (enqueue_one_deferred_signal)
183 (dequeue_one_deferred_signal)
184 (enqueue_pending_signal)
185 (linux_process_target::resume_one_lwp_throw)
186 (linux_process_target::thread_needs_step_over)
187 (linux_process_target::resume_one_thread)
188 (linux_process_target::proceed_one_lwp): Update the use of pending
189 signal list.
190
7d458ea5
SM
1912020-06-17 Simon Marchi <simon.marchi@efficios.com>
192
193 * Makefile.in (%-generated.cc: ../gdb/regformats/arm/%.dat):
194 Remove.
195
84b300de
SM
1962020-06-12 Simon Marchi <simon.marchi@efficios.com>
197
198 * Makefile.in (SFILES): Remove win32-arm-low.cc, wincecompat.cc.
199 * configure.srv: Remove mingw32ce cases.
200 * server.h, win32-low.cc: Remove __MINGW32CE__-guarded code.
201 * win32-low.h (to_back_slashes): Remove.
202 * win32-arm-low.cc, wincecompat.cc, wincecompat.h: Remove.
203
96c16e2b
SM
2042020-06-12 Simon Marchi <simon.marchi@efficios.com>
205
206 * Makefile.in (SFILES): linux-tile-low.cc.
207 * configure.srv: Remove tilegx case.
208 * linux-tile-low.cc: Remove.
209
bd1467ae
SM
2102020-06-12 Simon Marchi <simon.marchi@efficios.com>
211
212 * Makefile.in (SFILES): Remove linux-m32r-low.cc.
213 * configure.srv: Remove m32r case.
214 * linux-m32r-low.cc: Remove.
215
7b46bf6f
SM
2162020-06-12 Simon Marchi <simon.marchi@efficios.com>
217
218 * Makefile.in (SFILES): Remove linux-cris-low.c.
219 * configure.srv: Remove cris cases.
220 * linux-cris-low.cc, linux-crisv32-low.cc: Remove.
221
1fa29f56
SM
2222020-06-12 Simon Marchi <simon.marchi@efficios.com>
223
224 * Makefile.in (SFILES): Remove linux-bfin-low.c.
225 * configure.srv: Remove bfin case.
226 * linux-bfin-low.cc: Remove.
227 * linux-low.cc: Remove BFIN-conditional code.
228
613f149a
SM
2292020-06-12 Simon Marchi <simon.marchi@efficios.com>
230
231 * configure: Re-generate.
232 * configure.ac: Remove srv_qnx test.
233 * configure.srv: Remove nto case.
234 * nto-low.cc, nto-low.h, nto-x86-low.cc: Remove.
235 * remote-utils.c: Remove __QNX__-guarded code.
236
fdb95bf5
SM
2372020-06-12 Simon Marchi <simon.marchi@efficios.com>
238
239 * configure: Re-generate.
240 * configure.ac: Remove srv_lynxos test.
241 * configure.srv: Remove lynxos cases.
242 * lynx-i386-low.cc, lynx-low.cc, lynx-low.h, lynx-ppc-low.c:
243 Remove.
244
c00094dc
SM
2452020-06-12 Simon Marchi <simon.marchi@efficios.com>
246
247 * README: Fix a few outdated or incoherent things.
248
6479bf85
HD
2492020-05-27 Hannes Domani <ssbssa@yahoo.de>
250
251 * win32-low.cc (do_initial_child_stuff): Set open_process_used.
252 (win32_clear_inferiors): Use open_process_used.
253 (get_child_debug_event): Likewise.
254
bea571eb
MW
2552020-05-25 Michael Weghorn <m.weghorn@posteo.de>
256
257 PR gdbserver/25893
258 * linux-low.cc (linux_process_target::create_inferior),
259 lynx-low.cc (lynx_process_target::create_inferior),
260 win32-low.cc (win32_process_target::create_inferior): Use
261 construct_inferior_arguments instead of stringify_argv
262 to get string representation which properly escapes
263 special characters.
264 * server.cc (handle_v_run): Just pass empty program arg
265 as such, since any further processing is now handled via
266 construct_inferior_arguments.
267
ace6b919
MW
2682020-05-25 Michael Weghorn <m.weghorn@posteo.de>
269
270 * nto-low.cc (nto_process_target::create_inferior): Pass
271 argv to spawnp function as char **.
272
b69ca137
MW
2732020-05-25 Michael Weghorn <m.weghorn@posteo.de>
274
275 * server.cc (captured_main), (handle_v_run): No longer
276 insert extra NULL element to args vector.
277
51e2cfa2
PA
2782020-05-23 Pedro Alves <palves@redhat.com>
279
280 * gdb-safe-ctype.h: New.
281
8bbf0394
TBA
2822020-05-16 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
283
284 * linux-ia64-low.cc (ia64_target::sw_breakpoint_from_kind):
285 Fix incorrect 'gdb_assert_no_reached' to 'gdb_assert_not_reached'.
286 (ia64_target::low_breakpoint_at): Ditto.
287
01370779
HD
2882020-05-15 Hannes Domani <ssbssa@yahoo.de>
289
290 * win32-i386-low.cc (i386_supports_z_point_type): Handle
291 Z_PACKET_HW_BP z_type.
292 (i386_insert_point): Handle raw_bkpt_type type.
293 (i386_remove_point): Likewise.
294
7d186bc0
HD
2952020-04-30 Hannes Domani <ssbssa@yahoo.de>
296
297 * configure.srv <x86_64-*-mingw*, x86_64-*-cygwin*> (srv_tgtobj):
298 Add arch/i386.o.
299 * win32-arm-low.cc (arm_num_regs): New function.
300 (struct win32_target_ops): Use arm_num_regs.
301 * win32-i386-low.cc (win32_get_current_dr): Adapt for WOW64
302 processes.
303 (i386_get_thread_context): Likewise.
304 (i386_prepare_to_resume): Likewise.
305 (i386_thread_added): Likewise.
306 (i386_single_step): Likewise.
307 (i386_fetch_inferior_register): Likewise.
308 (i386_store_inferior_register): Likewise.
309 (i386_arch_setup): Likewise.
310 (i386_win32_num_regs): New function.
311 (struct win32_target_ops): Use i386_win32_num_regs.
312 * win32-low.cc (win32_get_thread_context): Adapt for WOW64
313 processes.
314 (win32_require_context): Likewise.
315 (child_add_thread): Likewise.
316 (do_initial_child_stuff): Likewise.
317 (continue_one_thread): Likewise.
318 (win32_process_target::resume): Likewise.
319 (load_psapi): Likewise.
320 (win32_add_all_dlls): Likewise.
321 (maybe_adjust_pc): Likewise.
322 (win32_process_target::qxfer_siginfo): Likewise.
323 (initialize_low): Likewise.
324 * win32-low.h (struct win32_target_ops): Change num_regs to
325 callback function.
326
1eb39914
SM
3272020-04-27 Simon Marchi <simon.marchi@efficios.com>
328
329 * configure.ac: Remove check for fs_base/gs_base in
330 user_regs_struct.
331 * configure: Re-generate.
332 * config.in: Re-generate.
333 * linux-x86-low.cc (x86_64_regmap, x86_fill_gregset,
334 x86_store_gregset): Adjust.
335
51ac8e22
HD
3362020-04-22 Hannes Domani <ssbssa@yahoo.de>
337
338 * server.cc (handle_search_memory_1): Fix gdb_read_memory return value
339 comparison.
340
a010605f
TT
3412020-04-16 Tom Tromey <tromey@adacore.com>
342
343 * win32-low.cc (windows_nat::handle_access_violation): New
344 function.
345
e2275c6e
SM
3462020-04-15 Simon Marchi <simon.marchi@polymtl.ca>
347
348 * win32-low.cc (get_child_debug_event): Fix format string warning.
349
73944e9f
TT
3502020-04-13 Tom Tromey <tom@tromey.com>
351
352 * server.h (gdb_fildes_t): Remove typedef.
353 * remote-utils.c (remote_desc, list_desc): Now int.
354 (INVALID_DESCRIPTOR): Remove.
355 (gdb_connected, remote_close)
356 (check_remote_input_interrupt_request): Update.
357 * utils.h (pfildes): Don't declare.
358 * utils.c (pfildes): Remove.
359
55d7aec8
TT
3602020-04-13 Tom Tromey <tom@tromey.com>
361
362 * server.h (handle_serial_event, handle_target_event): Update.
363 * server.c: Don't call initialize_event_loop.
364 (keep_processing_events): New global.
365 (handle_serial_event): Return void. Set keep_processing_events.
366 (handle_target_event): Return void.
367 (start_event_loop): Move from event-loop.c. Rewrite.
368 * remote-utils.c (handle_accept_event): Return void.
369 (reset_readchar): Use delete_timer.
370 (process_remaining): Return void.
371 (reschedule): Use create_timer.
372 * event-loop.h: Remove.
373 * event-loop.cc: Remove.
374 * Makefile.in (OBS): Use gdbsupport/event-loop.o, not event-loop.o.
375
e487f994
TT
3762020-04-13 Tom Tromey <tom@tromey.com>
377
378 * server.c (invoke_async_signal_handlers)
379 (check_async_event_handlers, flush_streams, gdb_select): New
380 functions.
381
8ae8e197
TT
3822020-04-13 Tom Tromey <tom@tromey.com>
383
384 * configure: Rebuild.
385 * config.in: Rebuild.
386
360ad8b3
TT
3872020-04-08 Tom Tromey <tromey@adacore.com>
388
389 PR gdb/22992
390 * win32-low.c (child_continue): Call matching_pending_stop.
391 (get_child_debug_event): Call fetch_pending_stop. Push pending
392 stop when needed.
393
523d4f80
TT
3942020-04-08 Tom Tromey <tromey@adacore.com>
395
396 * win32-low.h (win32_process_target::stopped_by_sw_breakpoint)
397 (win32_process_target::supports_stopped_by_sw_breakpoint):
398 Declare.
399 * win32-low.c (win32_supports_z_point_type): Always handle
400 Z_PACKET_SW_BP.
401 (win32_insert_point): Call insert_memory_breakpoint when needed.
402 (win32_remove_point): Call remove_memory_breakpoint when needed.
403 (win32_process_target::stopped_by_sw_breakpoint)
404 (win32_process_target::supports_stopped_by_sw_breakpoint): New
405 methods.
406 (win32_target_ops): Update.
407 (maybe_adjust_pc): New function.
408 (win32_wait): Call maybe_adjust_pc.
409
e54e5929
TT
4102020-04-08 Tom Tromey <tromey@adacore.com>
411
412 * win32-low.h (struct win32_target_ops) <decr_pc_after_break>: New
413 field.
414 * win32-i386-low.c (the_low_target): Update.
415 * win32-arm-low.c (the_low_target): Update.
416
d6225aff
TT
4172020-04-08 Tom Tromey <tromey@adacore.com>
418
419 * win32-low.h (win32_process_target::read_pc)
420 (win32_process_target::write_pc): Declare.
421 * win32-low.c (win32_process_target::read_pc)
422 (win32_process_target::write_pc): New methods.
423 * win32-i386-low.c (i386_win32_get_pc, i386_win32_set_pc): New
424 functions.
425 (the_low_target): Update.
426 * win32-arm-low.c (arm_win32_get_pc, arm_win32_set_pc): New
427 functions.
428 (the_low_target): Update.
429
2c1d95e8
TT
4302020-04-08 Tom Tromey <tromey@adacore.com>
431
432 * win32-low.c (win32_kill, get_child_debug_event): Use
433 wait_for_debug_event.
434
e758e19c
TT
4352020-04-08 Tom Tromey <tromey@adacore.com>
436
437 * win32-low.c (child_continue): Call continue_last_debug_event.
438
8d30e395
TT
4392020-04-08 Tom Tromey <tromey@adacore.com>
440
441 * win32-low.c (handle_exception): Remove.
442 (windows_nat::handle_ms_vc_exception): New function.
443 (get_child_debug_event): Add "continue_status" parameter.
444 Update.
445 (win32_wait): Update.
446
a816ba18
TT
4472020-04-08 Tom Tromey <tromey@adacore.com>
448
449 * win32-low.c (windows_nat::handle_load_dll): Rename from
450 handle_load_dll. No longer static.
451 (windows_nat::handle_unload_dll): Rename from handle_unload_dll.
452 No longer static.
453
d41b524f
TT
4542020-04-08 Tom Tromey <tromey@adacore.com>
455
456 * win32-low.c (handle_output_debug_string): Add parameter. Change
457 return type.
458 (win32_kill, get_child_debug_event): Update.
459
3c76026d
TT
4602020-04-08 Tom Tromey <tromey@adacore.com>
461
462 * win32-low.c (current_process_handle, current_process_id)
463 (main_thread_id, last_sig, current_event, siginfo_er): Move to
464 nat/windows-nat.c.
465
9d8679cc
TT
4662020-04-08 Tom Tromey <tromey@adacore.com>
467
468 * win32-low.c (get_image_name): Remove.
469 (handle_load_dll): Update.
470
28688adf
TT
4712020-04-08 Tom Tromey <tromey@adacore.com>
472
473 * win32-low.c (windows_nat::thread_rec): Rename from thread_rec.
474 No longer static. Change parameters.
475 (child_add_thread, child_fetch_inferior_registers)
476 (child_store_inferior_registers, win32_resume)
477 (win32_get_tib_address): Update.
478
4834dad0
TT
4792020-04-08 Tom Tromey <tromey@adacore.com>
480
481 * win32-low.h (struct win32_target_ops): Use qualified names where
482 needed.
483 * win32-i386-low.c: Add "using namespace".
484 * win32-low.c: Add "using namespace".
485 * win32-arm-low.c: Add "using namespace".
486
65bafd5b
TT
4872020-04-08 Tom Tromey <tromey@adacore.com>
488
489 * win32-low.c (delete_thread_info): Don't call CloseHandle.
490
98a03287
TT
4912020-04-08 Tom Tromey <tromey@adacore.com>
492
493 * win32-low.c (win32_require_context, suspend_one_thread): Use
494 windows_thread_info::suspend.
495 (continue_one_thread): Use windows_thread_info::resume.
496 * configure.srv (srv_tgtobj): Add windows-nat.o when needed.
497
62fe396b
TT
4982020-04-08 Tom Tromey <tromey@adacore.com>
499
500 * win32-i386-low.c (update_debug_registers)
501 (i386_prepare_to_resume, i386_thread_added): Update.
502
e9534bd2
TT
5032020-04-08 Tom Tromey <tromey@adacore.com>
504
505 * win32-low.c (child_add_thread): Use new.
506 (delete_thread_info): Use delete.
507
ae1f8880
TT
5082020-04-08 Tom Tromey <tromey@adacore.com>
509
510 * win32-low.h (struct windows_thread_info): Remove.
511
e56f8ccb
TT
5122020-04-08 Tom Tromey <tromey@adacore.com>
513
514 * win32-low.h (struct windows_thread_info): Rename from
515 win32_thread_info. Remove typedef.
516 (struct win32_target_ops, win32_require_context): Update.
517 * win32-low.c (win32_get_thread_context)
518 (win32_set_thread_context, win32_prepare_to_resume)
519 (win32_require_context, thread_rec, child_add_thread)
520 (delete_thread_info, continue_one_thread)
521 (child_fetch_inferior_registers, child_store_inferior_registers)
522 (win32_resume, suspend_one_thread, win32_get_tib_address):
523 Update.
524 * win32-i386-low.c (update_debug_registers)
525 (win32_get_current_dr, i386_get_thread_context)
526 (i386_prepare_to_resume, i386_thread_added, i386_single_step)
527 (i386_fetch_inferior_register, i386_store_inferior_register):
528 Update.
529 * win32-arm-low.c (arm_get_thread_context)
530 (arm_fetch_inferior_register, arm_store_inferior_register):
531 Update.
532
0dd7b52e
TBA
5332020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
534
535 * linux-low.h (struct linux_target_ops): Remove.
536 (the_low_target): Remove.
537 * linux-x86-low.cc (the_low_target): Remove.
538 * linux-aarch64-low.cc (the_low_target): Ditto.
539 * linux-arm-low.cc (the_low_target): Ditto.
540 * linux-bfin-low.cc (the_low_target): Ditto.
541 * linux-cris-low.cc (the_low_target): Ditto.
542 * linux-crisv32-low.cc (the_low_target): Ditto.
543 * linux-ia64-low.cc (the_low_target): Ditto.
544 * linux-m32r-low.cc (the_low_target): Ditto.
545 * linux-m68k-low.cc (the_low_target): Ditto.
546 * linux-mips-low.cc (the_low_target): Ditto.
547 * linux-nios2-low.cc (the_low_target): Ditto.
548 * linux-ppc-low.cc (the_low_target): Ditto.
549 * linux-riscv-low.cc (the_low_target): Ditto.
550 * linux-s390-low.cc (the_low_target): Ditto.
551 * linux-sh-low.cc (the_low_target): Ditto.
552 * linux-sparc-low.cc (the_low_target): Ditto.
553 * linux-tic6x-low.cc (the_low_target): Ditto.
554 * linux-tile-low.cc (the_low_target): Ditto.
555 * linux-xtensa-low.cc (the_low_target): Ditto.
556
fc5ecdb6
TBA
5572020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
558
559 Remove the 'get_ipa_tdesc_idx' linux target op and let a concrete
560 linux target define the op by overriding the declaration in
561 process_stratum_target.
562
563 * linux-low.h (struct linux_target_ops): Remove the op.
564 (class linux_process_target) <get_ipa_tdesc_idx>: Remove.
565 * linux-low.cc (linux_process_target::get_ipa_tdesc_idx): Remove.
566 * linux-x86-low.cc (class x86_target) <get_ipa_tdesc_idx>: Declare.
567 (x86_get_ipa_tdesc_idx): Turn into...
568 (x86_target::get_ipa_tdesc_idx): ...this.
569 (the_low_target): Remove the op field.
570 * linux-ppc-low.cc (class ppc_target) <get_ipa_tdesc_idx>: Declare.
571 (ppc_get_ipa_tdesc_idx): Turn into...
572 (ppc_target::get_ipa_tdesc_idx): ...this.
573 (the_low_target): Remove the op field.
574 * linux-s390-low.cc (class s390_target) <get_ipa_tdesc_idx>: Declare.
575 (s390_get_ipa_tdesc_idx): Turn into...
576 (s390_target::get_ipa_tdesc_idx): ...this.
577 (the_low_target): Remove the op field.
578
9eedd27d
TBA
5792020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
580
581 Turn the 'get_syscall_trapinfo' linux target op into a method
582 of process_stratum_target.
583
584 * linux-low.h (struct linux_target_ops): Remove the op.
585 (class linux_process_target) <get_syscall_trapinfo>
586 <gdb_catch_this_syscall>
587 <low_supports_catch_syscall>
588 <low_get_syscall_trapinfo>: Declare.
589 * linux-low.cc (get_syscall_trapinfo): Turn into...
590 (linux_process_target::get_syscall_trapinfo): ...this.
591 (linux_process_target::low_get_syscall_trapinfo): Define.
592 (gdb_catch_this_syscall_p): Turn into...
593 (linux_process_target::gdb_catch_this_syscall): ...this.
594 (linux_process_target::low_supports_catch_syscall): Define.
595
596 Update the callers below.
597
598 (linux_process_target::wait_1)
599 (linux_process_target::supports_catch_syscall)
600
601 * linux-x86-low.cc (class x86_target) <low_supports_catch_syscall>
602 <low_get_syscall_trapinfo>: Declare.
603 (x86_target::low_supports_catch_syscall): Define.
604 (x86_get_syscall_trapinfo): Turn into...
605 (x86_target::low_get_syscall_trapinfo): ...this.
606 (the_low_target): Remove the op field.
607 * linux-aarch64-low.cc (class aarch64_target)
608 <low_supports_catch_syscall>
609 <low_get_syscall_trapinfo>: Declare.
610 (aarch64_target::low_supports_catch_syscall): Define.
611 (aarch64_get_syscall_trapinfo): Turn into...
612 (aarch64_target::low_get_syscall_trapinfo): ...this.
613 (the_low_target): Remove the op field.
614 * linux-arm-low.cc (class arm_target) <low_supports_catch_syscall>
615 <low_get_syscall_trapinfo>: Declare.
616 (arm_target::low_supports_catch_syscall): Define.
617 (arm_get_syscall_trapinfo): Turn into...
618 (arm_target::low_get_syscall_trapinfo): ...this.
619 (the_low_target): Remove the op field.
620 * linux-ppc-low.cc (the_low_target): Remove the op field.
621 * linux-s390-low.cc (the_low_target): Remove the op field.
622
b31cdfa6
TBA
6232020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
624
625 Remove the 'supports_hardware_single_step' linux target op and
626 override the process_stratum_target's op definition in
627 linux_process_target to return true.
628
629 * linux-low.h (struct linux_target_ops): Remove the op.
630 (class linux_process_target) <finish_step_over>
631 <maybe_hw_step>: Declare.
632 * linux-low.cc (can_hardware_single_step): Remove.
633 (maybe_hw_step): Turn into...
634 (linux_process_target::maybe_hw_step): ...this.
635 (finish_step_over): Turn into...
636 (linux_process_target::finish_step_over): ...this.
637 (linux_process_target::supports_hardware_single_step): Update
638 to return true.
639
640 Update the callers below.
641
642 (linux_process_target::single_step)
643 (linux_process_target::resume_one_lwp_throw)
644
645 * linux-arm-low.cc (class arm_target)
646 <supports_hardware_single_step>: Declare.
647 (arm_supports_hardware_single_step): Turn into...
648 (arm_target::supports_hardware_single_step): ...this.
649 (the_low_target): Remove the op field.
650 * linux-x86-low.cc (x86_supports_hardware_single_step): Remove.
651 (the_low_target): Remove the op field.
652 * linux-aarch64-low.cc (aarch64_supports_hardware_single_step):
653 Remove.
654 (the_low_target): Remove the op field.
655 * linux-bfin-low.cc (bfin_supports_hardware_single_step): Remove.
656 (the_low_target): Remove the op field.
657 * linux-crisv32-low.cc (cris_supports_hardware_single_step): Remove.
658 (the_low_target): Remove the op field.
659 * linux-m32r-low.cc (m32r_supports_hardware_single_step): Remove.
660 (the_low_target): Remove the op field.
661 * linux-m68k-low.cc (m68k_supports_hardware_single_step): Remove.
662 (the_low_target): Remove the op field.
663 * linux-ppc-low.cc (ppc_supports_hardware_single_step): Remove.
664 (the_low_target): Remove the op field.
665 * linux-s390-low.cc (s390_supports_hardware_single_step): Remove.
666 (the_low_target): Remove the op field.
667 * linux-sh-low.cc (sh_supports_hardware_single_step): Remove.
668 (the_low_target): Remove the op field.
669 * linux-tic6x-low.cc (tic6x_supports_hardware_single_step): Remove.
670 (the_low_target): Remove the op field.
671 * linux-tile-low.cc (tile_supports_hardware_single_step): Remove.
672 (the_low_target): Remove the op field.
673 * linux-xtensa-low.cc (xtensa_supports_hardware_single_step):
674 Remove.
675 (the_low_target): Remove the op field.
676
9cfd8715
TBA
6772020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
678
679 Turn the 'supports_range_stepping' linux target op into a method
680 of linux_process_target.
681
682 * linux-low.h (struct linux_target_ops): Remove the op.
683 (class linux_process_target) <low_supports_range_stepping>: Declare.
684 * linux-low.cc (linux_process_target::low_supports_range_stepping):
685 Define.
686 (linux_process_target::supports_range_stepping): Update the call
687 site.
688 * linux-x86-low.cc (class x86_target)
689 <low_supports_range_stepping>: Declare.
690 (x86_supports_range_stepping): Turn into...
691 (x86_target::low_supports_range_stepping): ...this.
692 (the_low_target): Remove the op field.
693 * linux-aarch64-low.cc (class aarch64_target)
694 <low_supports_range_stepping>: Declare.
695 (aarch64_supports_range_stepping): Turn into...
696 (aarch64_target::low_supports_range_stepping): ...this.
697 (the_low_target): Remove the op field.
698 * linux-arm-low.cc (the_low_target): Remove the op field.
699 * linux-bfin-low.cc (the_low_target): Ditto.
700 * linux-crisv32-low.cc (the_low_target): Ditto.
701 * linux-m32r-low.cc (the_low_target): Ditto.
702 * linux-m68k-low.cc (the_low_target): Ditto.
703 * linux-ppc-low.cc (the_low_target): Ditto.
704 * linux-s390-low.cc (the_low_target): Ditto.
705 * linux-sh-low.cc (the_low_target): Ditto.
706 * linux-tic6x-low.cc (the_low_target): Ditto.
707 * linux-tile-low.cc (the_low_target): Ditto.
708 * linux-xtensa-low.cc (the_low_target): Ditto.
709
ab64c999
TBA
7102020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
711
712 Remove the 'emit_ops' linux target ops and let the concrete
713 linux target define the op by overriding the declaration of
714 process_stratum_target.
715
716 * linux-low.h (struct linux_target_ops): Remove the op.
717 (class linux_process_target) <emit_ops>: Remove.
718 * linux-low.cc (linux_process_target::emit_ops): Remove.
719 * linux-x86-low.cc (class x86_target) <emit_ops>: Declare.
720 (x86_emit_ops): Turn into...
721 (x86_target::emit_ops): ...this.
722 (the_low_target): Remove the op field.
723 * linux-aarch64-low.cc (class aarch64_target) <emit_ops>: Declare.
724 (aarch64_emit_ops): Turn into...
725 (aarch64_target::emit_ops): ...this.
726 (the_low_target): Remove the op field.
727 * linux-ppc-low.cc (class ppc_target) <emit_ops>: Declare.
728 (ppc_emit_ops): Turn into...
729 (ppc_target::emit_ops): ...this.
730 (the_low_target): Remove the op field.
731 * linux-s390-low.cc (class s390_target) <emit_ops>: Declare.
732 (s390_emit_ops): Turn into...
733 (s390_target::emit_ops): ...this.
734 (the_low_target): Remove the op field.
735 * linux-arm-low.cc (the_low_target): Remove the op field.
736 * linux-bfin-low.cc (the_low_target): Ditto.
737 * linux-crisv32-low.cc (the_low_target): Ditto.
738 * linux-m32r-low.cc (the_low_target): Ditto.
739 * linux-m68k-low.cc (the_low_target): Ditto.
740 * linux-sh-low.cc (the_low_target): Ditto.
741 * linux-tic6x-low.cc (the_low_target): Ditto.
742 * linux-tile-low.cc (the_low_target): Ditto.
743 * linux-xtensa-low.cc (the_low_target): Ditto.
744
809a0c35
TBA
7452020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
746
747 Remove the 'install_fast_tracepoint_jump_pad' and
748 'get_min_fast_tracepoint_insn_len' linux target ops to let the
749 concrete linux target define the ops by overriding the declarations
750 of process_stratum_target.
751
752 * linux-low.h (struct linux_target_ops): Remove the ops.
753 (class linux_process_target) <supports_fast_tracepoints>
754 <install_fast_tracepoint_jump_pad>
755 <get_min_fast_tracepoint_insn_len>: Remove.
756 * linux-low.cc (linux_process_target::supports_fast_tracepoints)
757 (linux_process_target::install_fast_tracepoint_jump_pad)
758 (linux_process_target::get_min_fast_tracepoint_insn_len): Remove.
759 * linux-x86-low.cc (class x86_target) <supports_fast_tracepoints>
760 <install_fast_tracepoint_jump_pad>
761 <get_min_fast_tracepoint_insn_len>: Declare.
762 (x86_target::supports_fast_tracepoints): Define.
763 (x86_install_fast_tracepoint_jump_pad): Turn into...
764 (x86_target::install_fast_tracepoint_jump_pad): ...this.
765 (x86_get_min_fast_tracepoint_insn_len): Turn into...
766 (x86_target::get_min_fast_tracepoint_insn_len): ...this.
767 (the_low_target): Remove the op fields.
768 * linux-aarch64-low.cc (class aarch64_target)
769 <supports_fast_tracepoints>
770 <install_fast_tracepoint_jump_pad>
771 <get_min_fast_tracepoint_insn_len>: Declare.
772 (aarch64_target::supports_fast_tracepoints): Define.
773 (aarch64_install_fast_tracepoint_jump_pad): Turn into...
774 (aarch64_target::install_fast_tracepoint_jump_pad): ...this.
775 (aarch64_get_min_fast_tracepoint_insn_len): Turn into...
776 (aarch64_target::get_min_fast_tracepoint_insn_len): ...this.
777 (the_low_target): Remove the op fields.
778 * linux-ppc-low.cc (class ppc_target) <supports_fast_tracepoints>
779 <install_fast_tracepoint_jump_pad>
780 <get_min_fast_tracepoint_insn_len>: Declare.
781 (ppc_target::supports_fast_tracepoints): Define.
782 (ppc_install_fast_tracepoint_jump_pad): Turn into...
783 (ppc_target::install_fast_tracepoint_jump_pad): ...this.
784 (ppc_get_min_fast_tracepoint_insn_len): Turn into...
785 (ppc_target::get_min_fast_tracepoint_insn_len): ...this.
786 (the_low_target): Remove the op fields.
787 * linux-s390-low.cc (class s390_target) <supports_fast_tracepoints>
788 <install_fast_tracepoint_jump_pad>
789 <get_min_fast_tracepoint_insn_len>: Declare.
790 (s390_target::supports_fast_tracepoints): Define.
791 (s390_install_fast_tracepoint_jump_pad): Turn into...
792 (s390_target::install_fast_tracepoint_jump_pad): ...this.
793 (s390_get_min_fast_tracepoint_insn_len): Turn into...
794 (s390_target::get_min_fast_tracepoint_insn_len): ...this.
795 (the_low_target): Remove the op fields.
796 * linux-arm-low.cc (the_low_target): Remove the op fields.
797 * linux-bfin-low.cc (the_low_target): Ditto.
798 * linux-crisv32-low.cc (the_low_target): Ditto.
799 * linux-m32r-low.cc (the_low_target): Ditto.
800 * linux-m68k-low.cc (the_low_target): Ditto.
801 * linux-sh-low.cc (the_low_target): Ditto.
802 * linux-tic6x-low.cc (the_low_target): Ditto.
803 * linux-tile-low.cc (the_low_target): Ditto.
804 * linux-xtensa-low.cc (the_low_target): Ditto.
805
13e567af
TBA
8062020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
807
808 Turn the 'get_thread_area' linux target op into a method of
809 process_stratum_target.
810
811 * linux-low.h (struct linux_target_ops): Remove the op.
812 (class linux_process_target) <stuck_in_jump_pad>
813 <linux_fast_tracepoint_collecting>
814 <low_get_thread_area>: Declare.
815 * linux-low.cc (supports_fast_tracepoints): Remove.
816 (linux_fast_tracepoint_collecting): Turn into...
817 (linux_process_target::linux_fast_tracepoint_collecting): ...this.
818 (linux_process_target::low_get_thread_area): Define.
819 (stuck_in_jump_pad_callback): Turn into...
820 (linux_process_target::stuck_in_jump_pad): ...this.
821
822 Update the caller below.
823
824 (linux_process_target::stabilize_threads)
825
826 * linux-x86-low.cc (class x86_target) <low_get_thread_area>:
827 Declare.
828 (x86_get_thread_area): Turn into...
829 (x86_target::low_get_thread_area): ...this.
830 (the_low_target): Remove the op field.
831 * linux-aarch64-low.cc (class aarch64_target) <low_get_thread_area>:
832 Declare.
833 (aarch64_get_thread_area): Turn into...
834 (aarch64_target::low_get_thread_area): ...this.
835 (the_low_target): Remove the op field.
836 * linux-ppc-low.cc (class ppc_target) <low_get_thread_area>:
837 Declare.
838 (ppc_get_thread_area): Turn into...
839 (ppc_target::low_get_thread_area): ...this.
840 (the_low_target): Remove the op field.
841 * linux-s390-low.cc (class s390_target) <low_get_thread_area>:
842 Declare.
843 (s390_get_thread_area): Turn into...
844 (s390_target::low_get_thread_area): ...this.
845 (the_low_target): Remove the op field.
846 * linux-arm-low.cc (the_low_target): Remove the op field.
847 * linux-bfin-low.cc (the_low_target): Ditto.
848 * linux-crisv32-low.cc (the_low_target): Ditto.
849 * linux-m32r-low.cc (the_low_target): Ditto.
850 * linux-m68k-low.cc (the_low_target): Ditto.
851 * linux-sh-low.cc (the_low_target): Ditto.
852 * linux-tic6x-low.cc (the_low_target): Ditto.
853 * linux-tile-low.cc (the_low_target): Ditto.
854 * linux-xtensa-low.cc (the_low_target): Ditto.
855
47f70aa7
TBA
8562020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
857
858 Remote the 'supports_tracepoints' linux target op and let the
859 concrete linux target define it by overriding the op declared in
860 process_stratum_target.
861
862 * linux-low.h (struct linux_target_ops): Remove the op.
863 (class linux_process_target) <supports_tracepoints>: Remove.
864 * linux-low.cc (linux_process_target::supports_tracepoints): Remove.
865 * linux-x86-low.cc (class x86_target) <supports_tracepoints>:
866 Declare.
867 (x86_supports_tracepoints): Turn into...
868 (x86_target::supports_tracepoints): ...this.
869 (the_low_target): Remove the op field.
870 * linux-aarch64-low.cc (class aarch64_target)
871 <supports_tracepoints>: Declare.
872 (aarch64_supports_tracepoints): Turn into...
873 (aarch64_target::supports_tracepoints): ...this.
874 (the_low_target): Remove the op field.
875 * linux-ppc-low.cc (class ppc_target) <supports_tracepoints>:
876 Declare.
877 (ppc_supports_tracepoints): Turn into...
878 (ppc_target::supports_tracepoints): ...this.
879 (the_low_target): Remove the op field.
880 * linux-s390-low.cc (class s390_target) <supports_tracepoints>:
881 Declare.
882 (s390_supports_tracepoints): Turn into...
883 (s390_target::supports_tracepoints): ...this.
884 (the_low_target): Remove the op field.
885 * linux-arm-low.cc (the_low_target): Remove the op field.
886 * linux-bfin-low.cc (the_low_target): Ditto.
887 * linux-crisv32-low.cc (the_low_target): Ditto.
888 * linux-m32r-low.cc (the_low_target): Ditto.
889 * linux-m68k-low.cc (the_low_target): Ditto.
890 * linux-sh-low.cc (the_low_target): Ditto.
891 * linux-tic6x-low.cc (the_low_target): Ditto.
892 * linux-tile-low.cc (the_low_target): Ditto.
893 * linux-xtensa-low.cc (the_low_target): Ditto.
894
a5b5da92
TBA
8952020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
896
897 Remove the 'process_qsupported' linux target op and let a concrete
898 linux target define the op by overriding the op declaration in
899 process_stratum_target.
900
901 * linux-low.h (struct linux_target_ops): Remove the op.
902 (class linux_process_target) <process_qsupported>: Remove.
903 * linux-low.cc (linux_process_target::process_qsupported): Remove.
904 * linux-x86-low.cc (class x86_target) <process_qsupported>: Declare.
905 (x86_linux_process_qsupported): Turn into...
906 (x86_target::process_qsupported): ...this.
907 (the_low_target): Remove the op field.
908 * linux-aarch64-low.cc (the_low_target): Remove the op
909 field.
910 * linux-arm-low.cc (the_low_target): Ditto.
911 * linux-bfin-low.cc (the_low_target): Ditto.
912 * linux-crisv32-low.cc (the_low_target): Ditto.
913 * linux-m32r-low.cc (the_low_target): Ditto.
914 * linux-m68k-low.cc (the_low_target): Ditto.
915 * linux-ppc-low.cc (the_low_target): Ditto.
916 * linux-s390-low.cc (the_low_target): Ditto.
917 * linux-sh-low.cc (the_low_target): Ditto.
918 * linux-tic6x-low.cc (the_low_target): Ditto.
919 * linux-tile-low.cc (the_low_target): Ditto.
920 * linux-xtensa-low.cc (the_low_target): Ditto.
921
d7599cc0
TBA
9222020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
923
924 Turn the 'prepare_to_resume' linux target op into a method of
925 linux_process_target.
926
927 * linux-low.h (struct linux_target_ops): Remove the op.
928 (class linux_process_target) <low_prepare_to_resume>: Declare.
929 * linux-low.cc (linux_process_target::low_prepare_to_resume):
930 Define.
931
932 Update the callers below:
933
934 (linux_process_target::resume_one_lwp_throw)
935 (linux_process_target::low_prepare_to_resume)
936
937 * linux-x86-low.cc (class x86_target) <low_prepare_to_resume>:
938 Declare.
939 (x86_target::low_prepare_to_resume): Define.
940 (the_low_target): Remove the op field.
941 * linux-aarch64-low.cc (class aarch64_target)
942 <low_prepare_to_resume>: Declare.
943 (aarch64_target::low_prepare_to_resume): Define.
944 (the_low_target): Remove the op field.
945 * linux-arm-low.cc (class arm_target) <low_prepare_to_resume>:
946 Declare.
947 (arm_prepare_to_resume): Turn into...
948 (arm_target::low_prepare_to_resume): ...this.
949 (the_low_target): Remove the op field.
950 * linux-mips-low.cc (class mips_target) <low_prepare_to_resume>:
951 Declare.
952 (mips_linux_prepare_to_resume): Turn into...
953 (mips_target::low_prepare_to_resume): ...this.
954 (the_low_target): Remove the op field.
955 * linux-bfin-low.cc (the_low_target): Remove the op field.
956 * linux-crisv32-low.cc (the_low_target): Ditto.
957 * linux-m32r-low.cc (the_low_target): Ditto.
958 * linux-m68k-low.cc (the_low_target): Ditto.
959 * linux-ppc-low.cc (the_low_target): Ditto.
960 * linux-s390-low.cc (the_low_target): Ditto.
961 * linux-sh-low.cc (the_low_target): Ditto.
962 * linux-tic6x-low.cc (the_low_target): Ditto.
963 * linux-tile-low.cc (the_low_target): Ditto.
964 * linux-xtensa-low.cc (the_low_target): Ditto.
965
fd000fb3
TBA
9662020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
967
968 Turn the 'new_process', 'delete_process', 'new_thread',
969 'delete_thread', and 'new_fork' linux target ops into methods
970 of linux_process_target.
971
972 * linux-low.h (struct linux_target_ops): Remove the ops.
973 (class linux_process_target) <add_linux_process>
974 <add_lwp>
975 <delete_lwp>
976 <attach_lwp>
977 <detach_one_lwp>
978 <check_zombie_leaders>
979 <filter_exit_event>
980 <low_new_process>
981 <low_delete_process>
982 <low_new_thread>
983 <low_delete_thread>
984 <low_new_fork>: Declare.
985 * linux-low.cc (delete_lwp): Turn into...
986 (linux_process_target::delete_lwp): ...this.
987 (linux_process_target::low_delete_thread): Define.
988 (linux_add_process): Turn into...
989 (linux_process_target::add_linux_process): ...this.
990 (linux_process_target::low_new_process): Define.
991 (linux_process_target::low_delete_process): Define.
992 (linux_process_target::low_new_fork): Define.
993 (add_lwp): Turn into...
994 (linux_process_target::add_lwp): ...this.
995 (linux_process_target::low_new_thread): Define.
996 (linux_attach_lwp): Turn into...
997 (linux_process_target::attach_lwp): ...this.
998 (linux_detach_one_lwp): Turn into...
999 (linux_process_target::detach_one_lwp): ...this.
1000 (linux_detach_lwp_callback): Remove and inline...
1001 (linux_process_target::detach): ...here.
1002 (check_zombie_leaders): Turn into...
1003 (linux_process_target::check_zombie_leaders): ...this.
1004 (filter_exit_event): Turn into...
1005 (linux_process_target::filter_exit_event): ...this.
1006
1007 Update the callers below.
1008
1009 (linux_process_target::handle_extended_wait)
1010 (linux_process_target::create_inferior)
1011 (attach_proc_task_lwp_callback)
1012 (linux_process_target::attach)
1013 (linux_process_target::detach)
1014 (linux_process_target::mourn)
1015 * thread-db.cc (attach_thread)
1016
1017 * linux-x86-low.cc (class x86_target) <low_new_process>
1018 <low_delete_process>
1019 <low_new_thread>
1020 <low_delete_thread>
1021 <low_new_fork>: Declare.
1022 (x86_linux_new_process): Turn into...
1023 (x86_target::low_new_process): ...this.
1024 (x86_linux_delete_process): Turn into...
1025 (x86_target::low_delete_process): ...this.
1026 (x86_target::low_new_thread): Define.
1027 (x86_target::low_delete_thread): Define.
1028 (x86_linux_new_fork): Turn into...
1029 (x86_target::low_new_fork): ...this.
1030 (the_low_target): Remove the op fields.
1031 * linux-aarch64-low.cc (class aarch64_target) <low_new_process>
1032 <low_delete_process>
1033 <low_new_thread>
1034 <low_delete_thread>
1035 <low_new_fork>: Declare.
1036 (aarch64_linux_new_process): Turn into...
1037 (aarch64_target::low_new_process): ...this.
1038 (aarch64_linux_delete_process): Turn into...
1039 (aarch64_target::low_delete_process): ...this.
1040 (aarch64_target::low_new_thread): Define.
1041 (aarch64_target::low_delete_thread): Define.
1042 (aarch64_linux_new_fork): Turn into...
1043 (aarch64_target::low_new_fork): ...this.
1044 (the_low_target): Remove the op fields.
1045 * linux-arm-low.cc (class arm_target) <low_new_process>
1046 <low_delete_process>
1047 <low_new_thread>
1048 <low_delete_thread>
1049 <low_new_fork>: Declare.
1050 (arm_new_process): Turn into...
1051 (arm_target::low_new_process): ...this.
1052 (arm_delete_process): Turn into...
1053 (arm_target::low_delete_process): ...this.
1054 (arm_new_thread): Turn into...
1055 (arm_target::low_new_thread): ...this.
1056 (arm_delete_thread): Turn into...
1057 (arm_target::low_delete_thread): ...this.
1058 (arm_new_fork): Turn into...
1059 (arm_target::low_new_fork): ...this.
1060 (the_low_target): Remove the op fields.
1061 * linux-mips-low.cc (class mips_target) <low_new_process>
1062 <low_delete_process>
1063 <low_new_thread>
1064 <low_delete_thread>
1065 <low_new_fork>: Declare.
1066 (mips_linux_new_process): Turn into...
1067 (mips_target::low_new_process): ...this.
1068 (mips_linux_delete_process): Turn into...
1069 (mips_target::low_delete_process): ...this.
1070 (mips_linux_new_thread): Turn into...
1071 (mips_target::low_new_thread): ...this.
1072 (mips_linux_delete_thread): Turn into...
1073 (mips_target::low_delete_thread): ...this.
1074 (mips_linux_new_fork): Turn into...
1075 (mips_target::low_new_fork): ...this.
1076 (the_low_target): Remove the op fields.
1077 * linux-bfin-low.cc (the_low_target): Remove the op fields.
1078 * linux-crisv32-low.cc (the_low_target): Ditto.
1079 * linux-m32r-low.cc (the_low_target): Ditto.
1080 * linux-m68k-low.cc (the_low_target): Ditto.
1081 * linux-ppc-low.cc (the_low_target): Ditto.
1082 * linux-s390-low.cc (the_low_target): Ditto.
1083 * linux-sh-low.cc (the_low_target): Ditto.
1084 * linux-tic6x-low.cc (the_low_target): Ditto.
1085 * linux-tile-low.cc (the_low_target): Ditto.
1086 * linux-xtensa-low.cc (the_low_target): Ditto.
1087
cb63de7c
TBA
10882020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1089
1090 Turn the 'siginfo_fixup' linux target op into a method of
1091 linux_process_target.
1092
1093 * linux-low.h (struct linux_target_ops): Remove the op.
1094 (class linux_process_target) <siginfo_fixup>
1095 <low_siginfo_fixup>: Declare.
1096 * linux-low.cc (siginfo_fixup): Turn into...
1097 (linux_process_target::siginfo_fixup): ...this.
1098 (linux_process_target::low_siginfo_fixup): Define.
1099 * linux-x86-low.cc (class x86_target) <low_siginfo_fixup>: Declare.
1100 (x86_siginfo_fixup): Turn into...
1101 (x86_target::low_siginfo_fixup): ...this.
1102 (the_low_target): Remove the op field.
1103 * linux-aarch64-low.cc (class aarch64_target):
1104 <low_siginfo_fixup>: Declare.
1105 (aarch64_linux_siginfo_fixup): Turn into...
1106 (aarch64_target::low_siginfo_fixup): ...this.
1107 (the_low_target): Remove the op field.
1108 * linux-arm-low.cc (the_low_target): Remove the op field.
1109 * linux-bfin-low.cc (the_low_target): Ditto.
1110 * linux-crisv32-low.cc (the_low_target): Ditto.
1111 * linux-m32r-low.cc (the_low_target): Ditto.
1112 * linux-m68k-low.cc (the_low_target): Ditto.
1113 * linux-mips-low.cc (the_low_target): Ditto.
1114 * linux-ppc-low.cc (the_low_target): Ditto.
1115 * linux-s390-low.cc (the_low_target): Ditto.
1116 * linux-sh-low.cc (the_low_target): Ditto.
1117 * linux-tic6x-low.cc (the_low_target): Ditto.
1118 * linux-tile-low.cc (the_low_target): Ditto.
1119 * linux-xtensa-low.cc (the_low_target): Ditto.
1120
b35db733
TBA
11212020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1122
1123 Turn the 'collect_ptrace_register' and 'supply_ptrace_register'
1124 linux target ops into methods of linux_process_target.
1125
1126 * linux-low.h (struct linux_target_ops): Remove the ops.
1127 (class linux_process_target) <low_collect_ptrace_register>
1128 <low_store_ptrace_register>: Declare.
1129 * linux-low.cc (linux_process_target::low_collect_ptrace_register)
1130 (linux_process_target::low_supply_ptrace_register): Define.
1131
1132 Update the callers below.
1133
1134 (linux_process_target::fetch_register)
1135 (linux_process_target::store_register)
1136
1137 * linux-x86-low.cc (the_low_target): Remove the op fields.
1138 * linux-aarch64-low.cc (the_low_target): Ditto.
1139 * linux-arm-low.cc (the_low_target): Ditto.
1140 * linux-bfin-low.cc (the_low_target): Ditto.
1141 * linux-crisv32-low.cc (the_low_target): Ditto.
1142 * linux-m32r-low.cc (the_low_target): Ditto.
1143 * linux-m68k-low.cc (the_low_target): Ditto.
1144 * linux-sh-low.cc (the_low_target): Ditto.
1145 * linux-sparc-low.cc (the_low_target): Ditto.
1146 * linux-tic6x-low.cc (the_low_target): Ditto.
1147 * linux-tile-low.cc (the_low_target): Ditto.
1148 * linux-xtensa-low.cc (the_low_target): Ditto.
1149 * linux-mips-low.cc (class mips_target)
1150 <low_collect_ptrace_register>
1151 <low_supply_ptrace_register>: Declare.
1152 (mips_collect_ptrace_register): Turn into ...
1153 (mips_target::low_collect_ptrace_register): ...this.
1154 (mips_supply_ptrace_register): Turn into...
1155 (mips_target::low_supply_ptrace_register): ...this.
1156 (the_low_target): Remove the op fields.
1157 * linux-ppc-low.cc (class ppc_target)
1158 <low_collect_ptrace_register>
1159 <low_supply_ptrace_register>: Declare.
1160 (ppc_collect_ptrace_register): Turn into ...
1161 (ppc_target::low_collect_ptrace_register): ...this.
1162 (ppc_supply_ptrace_register): Turn into ...
1163 (ppc_target::low_supply_ptrace_register): ...this.
1164 (ppc_fill_gregset): Update for the calls to
1165 low_collect_ptrace_register.
1166 (the_low_target): Remove the op fields.
1167 * linux-s390-low.cc (class s390_target)
1168 <low_collect_ptrace_register>
1169 <low_supply_ptrace_register>: Declare.
1170 (s390_collect_ptrace_register): Turn into ...
1171 (s390_target::low_collect_ptrace_register): ...this.
1172 (s390_supply_ptrace_register): Turn into ...
1173 (s390_target::low_supply_ptrace_register): ...this.
1174 (s390_fill_gregset): Update for the calls to
1175 low_collect_ptrace_register.
1176 (the_low_target): Remove the op fields.
1177
ac1bbaca
TBA
11782020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1179
1180 Turn the 'stopped_by_watchpoint' and 'stopped_data_address' linux
1181 target ops into methods of linux_process_target.
1182
1183 * linux-low.h (struct linux_target_ops): Remove the ops.
1184 (class linux_process_target) <check_stopped_by_watchpoint>
1185 <low_stopped_by_watchpoint>
1186 <low_stopped_data_address>: Declare.
1187 * linux-low.cc (check_stopped_by_watchpoint): Turn into...
1188 (linux_process_target::check_stopped_by_watchpoint): ...this.
1189 (linux_process_target::low_stopped_by_watchpoint): Define.
1190 (linux_process_target::low_stopped_data_address): Define.
1191 * linux-x86-low.cc (class x86_target) <low_stopped_by_watchpoint>
1192 <low_stopped_data_address>: Declare.
1193 (x86_stopped_by_watchpoint): Turn into...
1194 (x86_target::low_stopped_by_watchpoint): ...this.
1195 (x86_stopped_data_address): Turn into...
1196 (x86_target::low_stopped_data_address): ...this.
1197 (the_low_target): Remove the op fields.
1198 * linux-aarch64-low.cc (class aarch64_target)
1199 <low_stopped_by_watchpoint>
1200 <low_stopped_data_address>: Declare.
1201 (aarch64_stopped_by_watchpoint): Turn into...
1202 (aarch64_target::low_stopped_by_watchpoint): ...this.
1203 (aarch64_stopped_data_address): Turn into...
1204 (aarch64_target::low_stopped_data_address): ...this.
1205 (the_low_target): Remove the op fields.
1206 * linux-arm-low.cc (class arm_target) <low_stopped_by_watchpoint>
1207 <low_stopped_data_address>: Declare.
1208 (arm_stopped_by_watchpoint): Turn into...
1209 (arm_target::low_stopped_by_watchpoint): ...this.
1210 (arm_stopped_data_address): Turn into...
1211 (arm_target::low_stopped_data_address): ...this.
1212 (the_low_target): Remove the op fields.
1213 * linux-crisv32-low.cc (class crisv32_target)
1214 <low_stopped_by_watchpoint>
1215 <low_stopped_data_address>: Declare.
1216 (cris_stopped_by_watchpoint): Turn into...
1217 (crisv32_target::low_stopped_by_watchpoint): ...this.
1218 (cris_stopped_data_address): Turn into...
1219 (crisv32_target::low_stopped_data_address): ...this.
1220 (the_low_target): Remove the op fields.
1221 * linux-mips-low.cc (class mips_target) <low_stopped_by_watchpoint>
1222 <low_stopped_data_address>: Declare.
1223 (mips_stopped_by_watchpoint): Turn into...
1224 (mips_target::low_stopped_by_watchpoint): ...this.
1225 (mips_stopped_data_address): Turn into...
1226 (mips_target::low_stopped_data_address): ...this.
1227 (the_low_target): Remove the op fields.
1228 * linux-bfin-low.cc (the_low_target): Remove the op fields.
1229 * linux-m32r-low.cc (the_low_target): Ditto.
1230 * linux-m68k-low.cc (the_low_target): Ditto.
1231 * linux-ppc-low.cc (the_low_target): Ditto.
1232 * linux-s390-low.cc (the_low_target): Ditto.
1233 * linux-sh-low.cc (the_low_target): Ditto.
1234 * linux-sparc-low.cc (the_low_target): Ditto.
1235 * linux-tic6x-low.cc (the_low_target): Ditto.
1236 * linux-tile-low.cc (the_low_target): Ditto.
1237 * linux-xtensa-low.cc (the_low_target): Ditto.
1238
9db9aa23
TBA
12392020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1240
1241 Turn the 'insert_point' and 'remove_point' linux target ops into
1242 methods of linux_process_target.
1243
1244 * linux-low.h (struct linux_target_ops): Remove the ops.
1245 (class linux_process_target) <low_insert_point>
1246 <low_remove_point>: Declare.
1247 * linux-low.cc (linux_process_target::low_insert_point)
1248 (linux_process_target::low_remove_point): Define.
1249 (linux_process_target::insert_point)
1250 (linux_process_target::remove_point): Update for calls to
1251 low_insert_point and low_remove_point.
1252 * linux-x86-low.cc (class x86_target) <low_insert_point>
1253 <low_remove_point>: Declare.
1254 (x86_insert_point): Turn into...
1255 (x86_target::low_insert_point): ...this.
1256 (x86_remove_point): Turn into...
1257 (x86_target::low_remove_point): ...this.
1258 (the_low_target): Remove the op fields.
1259 * linux-aarch64-low.cc (class aarch64_target) <low_insert_point>
1260 <low_remove_point>: Declare.
1261 (aarch64_insert_point): Turn into...
1262 (aarch64_target::low_insert_point): ...this.
1263 (aarch64_remove_point): Turn into...
1264 (aarch64_target::low_remove_point): ...this.
1265 (the_low_target): Remove the op fields.
1266 * linux-arm-low.cc (class arm_target) <low_insert_point>
1267 <low_remove_point>: Declare.
1268 (arm_insert_point): Turn into...
1269 (arm_target::low_insert_point): ...this.
1270 (arm_remove_point): Turn into...
1271 (arm_target::low_remove_point): ...this.
1272 (the_low_target): Remove the op fields.
1273 * linux-crisv32-low.cc (class crisv32_target) <low_insert_point>
1274 <low_remove_point>: Declare.
1275 (crisv32_insert_point): Turn into...
1276 (crisv32_target::low_insert_point): ...this.
1277 (crisv32_remove_point): Turn into...
1278 (crisv32_target::low_remove_point): ...this.
1279 (the_low_target): Remove the op fields.
1280 * linux-mips-low.cc (class mips_target) <low_insert_point>
1281 <low_remove_point>: Declare.
1282 (mips_insert_point): Turn into...
1283 (mips_target::low_insert_point): ...this.
1284 (mips_remove_point): Turn into...
1285 (mips_target::low_remove_point): ...this.
1286 (the_low_target): Remove the op fields.
1287 * linux-ppc-low.cc (class ppc_target) <low_insert_point>
1288 <low_remove_point>: Declare.
1289 (ppc_insert_point): Turn into...
1290 (ppc_target::low_insert_point): ...this.
1291 (ppc_remove_point): Turn into...
1292 (ppc_target::low_remove_point): ...this.
1293 (the_low_target): Remove the op fields.
1294 * linux-bfin-low.cc (the_low_target): Remove the op fields.
1295 * linux-m32r-low.cc (the_low_target): Ditto.
1296 * linux-m68k-low.cc (the_low_target): Ditto.
1297 * linux-s390-low.cc (the_low_target): Ditto.
1298 * linux-sh-low.cc (the_low_target): Ditto.
1299 * linux-sparc-low.cc (the_low_target): Ditto.
1300 * linux-tic6x-low.cc (the_low_target): Ditto.
1301 * linux-tile-low.cc (the_low_target): Ditto.
1302 * linux-xtensa-low.cc (the_low_target): Ditto.
1303
007c9b97
TBA
13042020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1305
1306 Remove the 'supports_z_point_type' linux target op and let the
1307 concrete linux target define it by overriding the op declared in
1308 process_stratum_target.
1309
1310 * linux-low.cc (linux_process_target::supports_z_point_type):
1311 Remove.
1312 * linux-low.h (struct linux_target_ops): Remove the op.
1313 (class linux_process_target) <supports_z_point_type>: Remove.
1314 * linux-x86-low.cc (class x86_target) <supports_z_point_type>:
1315 Declare.
1316 (x86_supports_z_point_type): Turn into...
1317 (x86_target::supports_z_point_type): ...this.
1318 (the_low_target): Remove the op field.
1319 * linux-aarch64-low.cc (class aarch64_target)
1320 <supports_z_point_type>: Declare.
1321 (aarch64_supports_z_point_type): Turn into...
1322 (aarch64_target::supports_z_point_type): ...this.
1323 (the_low_target): Remove the op field.
1324 * linux-arm-low.cc (class arm_target) <supports_z_point_type>:
1325 Declare.
1326 (arm_supports_z_point_type): Turn into...
1327 (arm_target::supports_z_point_type): ...this.
1328 (the_low_target): Remove the op field.
1329 * linux-crisv32-low.cc (class crisv32_target)
1330 <supports_z_point_type>: Declare.
1331 (cris_supports_z_point_type): Turn into...
1332 (crisv32_target::supports_z_point_type): ...this.
1333 (the_low_target): Remove the op field.
1334 * linux-mips-low.cc (class mips_target) <supports_z_point_type>:
1335 Declare.
1336 (mips_supports_z_point_type): Turn into...
1337 (mips_target::supports_z_point_type): ...this.
1338 (the_low_target): Remove the op field.
1339 * linux-ppc-low.cc (class ppc_target) <supports_z_point_type>:
1340 Declare.
1341 (ppc_supports_z_point_type): Turn into...
1342 (ppc_target::supports_z_point_type): ...this.
1343 (the_low_target): Remove the op field.
1344 * linux-s390-low.cc (class s390_target) <supports_z_point_type>:
1345 Declare.
1346 (s390_supports_z_point_type): Turn into...
1347 (s390_target::supports_z_point_type): ...this.
1348 (the_low_target): Remove the op field.
1349 * linux-bfin-low.cc (the_low_target): Remove the op field.
1350 * linux-m32r-low.cc (the_low_target): Ditto.
1351 * linux-m68k-low.cc (the_low_target): Ditto.
1352 * linux-sh-low.cc (the_low_target): Ditto.
1353 * linux-sparc-low.cc (the_low_target): Ditto.
1354 * linux-tic6x-low.cc (the_low_target): Ditto.
1355 * linux-tile-low.cc (the_low_target): Ditto.
1356 * linux-xtensa-low.cc (the_low_target): Ditto.
1357
d7146cda
TBA
13582020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1359
1360 Turn the 'breakpoint_at' linux target op into a method of
1361 linux_process_target.
1362
1363 * linux-low.h (struct linux_target_ops): Remove the op.
1364 (class linux_process_target) <low_breakpoint_at>: Declare.
1365
1366 Update the callers below:
1367
1368 * linux-low.cc (linux_process_target::save_stop_reason)
1369 (linux_process_target::thread_still_has_status_pending)
1370 (linux_process_target::wait_1)
1371
1372 * linux-x86-low.cc (class x86_target)
1373 <low_breakpoint_at>: Declare.
1374 (x86_breakpoint_at): Turn into...
1375 (x86_target::low_breakpoint_at): ...this.
1376 (the_low_target): Remove the op field.
1377 * linux-aarch64-low.cc (class aarch64_target)
1378 <low_breakpoint_at>: Declare.
1379 (aarch64_breakpoint_at): Turn into...
1380 (aarch64_target::low_breakpoint_at): ...this.
1381 (the_low_target): Remove the op field.
1382 * linux-arm-low.cc (class arm_target)
1383 <low_breakpoint_at>: Declare.
1384 (arm_target::low_breakpoint_at): Define.
1385 (the_low_target): Remove the op field.
1386 * linux-bfin-low.cc (class bfin_target)
1387 <low_breakpoint_at>: Declare.
1388 (bfin_breakpoint_at): Turn into...
1389 (bfin_target::low_breakpoint_at): ...this.
1390 (the_low_target): Remove the op field.
1391 * linux-cris-low.cc (class cris_target)
1392 <low_breakpoint_at>: Declare.
1393 (cris_breakpoint_at): Turn into...
1394 (cris_target::low_breakpoint_at): ...this.
1395 (the_low_target): Remove the op field.
1396 * linux-crisv32-low.cc (class crisv32_target)
1397 <low_breakpoint_at>: Declare.
1398 (crisv32_breakpoint_at): Turn into...
1399 (crisv32_target::low_breakpoint_at): ...this.
1400 (the_low_target): Remove the op field.
1401 * linux-ia64-low.cc (class ia64_target)
1402 <low_breakpoint_at>: Declare.
1403 (ia64_target::low_breakpoint_at): Define.
1404 * linux-m32r-low.cc (class m32r_target)
1405 <low_breakpoint_at>: Declare.
1406 (m32r_breakpoint_at): Turn into...
1407 (m32r_target::low_breakpoint_at): ...this.
1408 (the_low_target): Remove the op field.
1409 * linux-m68k-low.cc (class m68k_target)
1410 <low_breakpoint_at>: Declare.
1411 (m68k_breakpoint_at): Turn into...
1412 (m68k_target::low_breakpoint_at): ...this.
1413 (the_low_target): Remove the op field.
1414 * linux-mips-low.cc (class mips_target)
1415 <low_breakpoint_at>: Declare.
1416 (mips_breakpoint_at): Turn into...
1417 (mips_target::low_breakpoint_at): ...this.
1418 (the_low_target): Remove the op field.
1419 * linux-nios2-low.cc (class nios2_target)
1420 <low_breakpoint_at>: Declare.
1421 (nios2_breakpoint_at): Turn into...
1422 (nios2_target::low_breakpoint_at): ...this.
1423 (the_low_target): Remove the op field.
1424 * linux-ppc-low.cc (class ppc_target)
1425 <low_breakpoint_at>: Declare.
1426 (ppc_breakpoint_at): Turn into...
1427 (ppc_target::low_breakpoint_at): ...this.
1428 (the_low_target): Remove the op field.
1429 * linux-riscv-low.cc (class riscv_target)
1430 <low_breakpoint_at>: Declare.
1431 (riscv_breakpoint_at): Turn into...
1432 (riscv_target::low_breakpoint_at): ...this.
1433 (the_low_target): Remove the op field.
1434 * linux-s390-low.cc (class s390_target)
1435 <low_breakpoint_at>: Declare.
1436 (s390_breakpoint_at): Turn into...
1437 (s390_target::low_breakpoint_at): ...this.
1438 (the_low_target): Remove the op field.
1439 * linux-sh-low.cc (class sh_target)
1440 <low_breakpoint_at>: Declare.
1441 (sh_breakpoint_at): Turn into...
1442 (sh_target::low_breakpoint_at): ...this.
1443 (the_low_target): Remove the op field.
1444 * linux-sparc-low.cc (class sparc_target)
1445 <low_breakpoint_at>: Declare.
1446 (sparc_breakpoint_at): Turn into...
1447 (sparc_target::low_breakpoint_at): ...this.
1448 (the_low_target): Remove the op field.
1449 * linux-tic6x-low.cc (class tic6x_target)
1450 <low_breakpoint_at>: Declare.
1451 (tic6x_breakpoint_at): Turn into...
1452 (tic6x_target::low_breakpoint_at): ...this.
1453 (the_low_target): Remove the op field.
1454 * linux-tile-low.cc (class tile_target)
1455 <low_breakpoint_at>: Declare.
1456 (tile_breakpoint_at): Turn into...
1457 (tile_target::low_breakpoint_at): ...this.
1458 (the_low_target): Remove the op field.
1459 * linux-xtensa-low.cc (class xtensa_target)
1460 <low_breakpoint_at>: Declare.
1461 (xtensa_breakpoint_at): Turn into...
1462 (xtensa_target::low_breakpoint_at): ...this.
1463 (the_low_target): Remove the op field.
1464
d4807ea2
TBA
14652020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1466
1467 Turn the 'decr_pc_after_break' linux_target_ops field into
1468 a method of linux_process_target.
1469
1470 * linux-low.h (struct linux_target_ops)
1471 <decr_pc_after_break>: Remove.
1472 (class linux_process_target) <low_decr_pc_after_break>: New method
1473 declaration.
1474 * linux-low.cc (linux_process_target::low_decr_pc_after_break):
1475 New method implementation.
1476
1477 Update the users below.
1478
1479 (linux_process_target::save_stop_reason)
1480 (linux_process_target::wait_1)
1481 * linux-x86-low.cc (class x86_target) <low_decr_pc_after_break>:
1482 New declaration.
1483 (x86_target::low_decr_pc_after_break): New method implementation.
1484 (the_low_target): Remove the field.
1485 * linux-bfin-low.cc (class bfin_target) <low_decr_pc_after_break>:
1486 New declaration.
1487 (bfin_target::low_decr_pc_after_break): New method implementation.
1488 (the_low_target): Remove the field.
1489 * linux-m68k-low.cc (class m68k_target) <low_decr_pc_after_break>:
1490 New declaration.
1491 (m68k_target::low_decr_pc_after_break): New method implementation.
1492 (the_low_target): Remove the field.
1493 * linux-s390-low.cc (class s390_target) <low_decr_pc_after_break>:
1494 New declaration.
1495 (s390_target::low_decr_pc_after_break): New method implementation.
1496 (the_low_target): Remove the field.
1497 * linux-aarch64-low.cc (the_low_target): Remove the field.
1498 * linux-arm-low.cc (the_low_target): Remove the field.
1499 * linux-cris-low.cc (the_low_target): Remove the field.
1500 * linux-crisv32-low.cc (the_low_target): Remove the field.
1501 * linux-m32r-low.cc (the_low_target): Remove the field.
1502 * linux-mips-low.cc (the_low_target): Remove the field.
1503 * linux-nios2-low.cc (the_low_target): Remove the field.
1504 * linux-ppc-low.cc (the_low_target): Remove the field.
1505 * linux-riscv-low.cc (the_low_target): Remove the field.
1506 * linux-sh-low.cc (the_low_target): Remove the field.
1507 * linux-sparc-low.cc (the_low_target): Remove the field.
1508 * linux-tic6x-low.cc (the_low_target): Remove the field.
1509 * linux-tile-low.cc (the_low_target): Remove the field.
1510 * linux-xtensa-low.cc (the_low_target): Remove the field.
1511
7582c77c
TBA
15122020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1513
1514 Remove the 'supports_software_single_step' linux target op and let
1515 the concrete linux target define it by overriding the op in
1516 process_stratum_target.
1517 Turn the 'get_next_pcs' linux target op into a method of
1518 linux_process_target.
1519
1520 * linux-low.h (struct linux_target_ops): Remove the ops.
1521 (class linux_process_target) <supports_software_single_step>:
1522 Remove.
1523 <low_get_next_pcs>: Declare.
1524 * linux-low.cc (can_software_single_step): Remove.
1525 (linux_process_target::low_get_next_pcs): Define.
1526 (linux_process_target::supports_software_single_step): Remove.
1527
1528 Update the callers below.
1529
1530 (linux_process_target::handle_extended_wait)
1531 (linux_process_target::wait_1)
1532 (linux_process_target::install_software_single_step_breakpoints)
1533 (linux_process_target::single_step)
1534 (linux_process_target::thread_needs_step_over)
1535 (linux_process_target::proceed_one_lwp)
1536 (linux_process_target::supports_range_stepping)
1537
1538 * linux-x86-low.cc (the_low_target): Remove the op field.
1539 * linux-aarch64-low.cc (the_low_target): Ditto.
1540 * linux-bfin-low.cc (the_low_target): Ditto.
1541 * linux-cris-low.cc (the_low_target): Ditto.
1542 * linux-crisv32-low.cc (the_low_target): Ditto.
1543 * linux-m32r-low.cc (the_low_target): Ditto.
1544 * linux-m68k-low.cc (the_low_target): Ditto.
1545 * linux-mips-low.cc (the_low_target): Ditto.
1546 * linux-nios2-low.cc (the_low_target): Ditto.
1547 * linux-ppc-low.cc (the_low_target): Ditto.
1548 * linux-riscv-low.cc (the_low_target): Ditto.
1549 * linux-s390-low.cc (the_low_target): Ditto.
1550 * linux-sh-low.cc (the_low_target): Ditto.
1551 * linux-sparc-low.cc (the_low_target): Ditto.
1552 * linux-tic6x-low.cc (the_low_target): Ditto.
1553 * linux-tile-low.cc (the_low_target): Ditto.
1554 * linux-xtensa-low.cc (the_low_target): Ditto.
1555 * linux-arm-low.cc (class arm_target) <low_get_next_pcs>
1556 <supports_software_single_step>: Declare.
1557 (arm_target::supports_software_single_step): Define.
1558 (arm_gdbserver_get_next_pcs): Turn into...
1559 (arm_target::low_get_next_pcs): ...this.
1560 (the_low_target): Remove the op field.
1561
3ca4edb6
TBA
15622020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1563
1564 Remove the 'sw_breakpoint_from_kind' linux target op, and let
1565 the concrete linux target define it by overriding the op
1566 in process_stratum_target.
1567
1568 * linux-low.cc (linux_process_target::sw_breakpoint_from_kind):
1569 Remove.
1570 * linux-low.h (struct linux_target_ops): Remove the op.
1571 (class linux_process_target) <sw_breakpoint_from_kind>: Remove.
1572 * linux-x86-low.cc (class x86_target) <sw_breakpoint_from_kind>:
1573 Declare.
1574 (x86_sw_breakpoint_from_kind): Turn into...
1575 (x86_target::sw_breakpoint_from_kind): ...this.
1576 (the_low_target): Remove the op field.
1577 * linux-aarch64-low.cc (class aarch64_target)
1578 <sw_breakpoint_from_kind>: Declare.
1579 (aarch64_sw_breakpoint_from_kind): Turn into...
1580 (aarch64_target::sw_breakpoint_from_kind): ...this.
1581 (the_low_target): Remove the op field.
1582 * linux-arm-low.cc (class arm_target) <sw_breakpoint_from_kind>:
1583 Declare.
1584 (arm_target::sw_breakpoint_from_kind): Define.
1585 (the_low_target): Remove the op field.
1586 * linux-bfin-low.cc (class bfin_target) <sw_breakpoint_from_kind>:
1587 Declare.
1588 (bfin_sw_breakpoint_from_kind): Turn into...
1589 (bfin_target::sw_breakpoint_from_kind): ...this.
1590 (the_low_target): Remove the op field.
1591 * linux-cris-low.cc (class cris_target) <sw_breakpoint_from_kind>:
1592 Declare.
1593 (cris_sw_breakpoint_from_kind): Turn into...
1594 (cris_target::sw_breakpoint_from_kind): ...this.
1595 (the_low_target): Remove the op field.
1596 * linux-crisv32-low.cc (class crisv32_target)
1597 <sw_breakpoint_from_kind>: Declare.
1598 (cris_sw_breakpoint_from_kind): Turn into...
1599 (crisv32_target::sw_breakpoint_from_kind): ...this.
1600 (the_low_target): Remove the op field.
1601 * linux-ia64-low.cc (class ia64_target) <sw_breakpoint_from_kind>:
1602 Declare.
1603 (ia64_target::sw_breakpoint_from_kind): Define.
1604 * linux-m32r-low.cc (class m32r_target) <sw_breakpoint_from_kind>:
1605 Declare.
1606 (m32r_sw_breakpoint_from_kind): Turn into...
1607 (m32r_target::sw_breakpoint_from_kind): ...this.
1608 (the_low_target): Remove the op field.
1609 * linux-m68k-low.cc (class m68k_target) <sw_breakpoint_from_kind>:
1610 Declare.
1611 (m68k_sw_breakpoint_from_kind): Turn into...
1612 (m68k_target::sw_breakpoint_from_kind): ...this.
1613 (the_low_target): Remove the op field.
1614 * linux-mips-low.cc (class mips_target) <sw_breakpoint_from_kind>:
1615 Declare.
1616 (mips_sw_breakpoint_from_kind): Turn into...
1617 (mips_target::sw_breakpoint_from_kind): ...this.
1618 (the_low_target): Remove the op field.
1619 * linux-nios2-low.cc (class nios2_target) <sw_breakpoint_from_kind>:
1620 Declare.
1621 (nios2_sw_breakpoint_from_kind): Turn into...
1622 (nios2_target::sw_breakpoint_from_kind): ...this.
1623 (the_low_target): Remove the op field.
1624 * linux-ppc-low.cc (class ppc_target) <sw_breakpoint_from_kind>:
1625 Declare.
1626 (ppc_sw_breakpoint_from_kind): Turn into...
1627 (ppc_target::sw_breakpoint_from_kind): ...this.
1628 (the_low_target): Remove the op field.
1629 * linux-riscv-low.cc (class riscv_target) <sw_breakpoint_from_kind>:
1630 Declare.
1631 (riscv_sw_breakpoint_from_kind): Turn into...
1632 (riscv_target::sw_breakpoint_from_kind): ...this.
1633 (the_low_target): Remove the op field.
1634 * linux-s390-low.cc (class s390_target) <sw_breakpoint_from_kind>:
1635 Declare.
1636 (s390_sw_breakpoint_from_kind): Turn into...
1637 (s390_target::sw_breakpoint_from_kind): ...this.
1638 (the_low_target): Remove the op field.
1639 * linux-sh-low.cc (class sh_target) <sw_breakpoint_from_kind>:
1640 Declare.
1641 (sh_sw_breakpoint_from_kind): Turn into...
1642 (sh_target::sw_breakpoint_from_kind): ...this.
1643 (the_low_target): Remove the op field.
1644 * linux-sparc-low.cc (class sparc_target) <sw_breakpoint_from_kind>:
1645 Declare.
1646 (sparc_sw_breakpoint_from_kind): Turn into...
1647 (sparc_target::sw_breakpoint_from_kind): ...this.
1648 (the_low_target): Remove the op field.
1649 * linux-tic6x-low.cc (class tic6x_target) <sw_breakpoint_from_kind>:
1650 Declare.
1651 (tic6x_sw_breakpoint_from_kind): Turn into...
1652 (tic6x_target::sw_breakpoint_from_kind): ...this.
1653 (the_low_target): Remove the op field.
1654 * linux-tile-low.cc (class tile_target) <sw_breakpoint_from_kind>:
1655 Declare.
1656 (tile_sw_breakpoint_from_kind): Turn into...
1657 (tile_target::sw_breakpoint_from_kind): ...this.
1658 (the_low_target): Remove the op field.
1659 * linux-xtensa-low.cc (class xtensa_target)
1660 <sw_breakpoint_from_kind>: Declare.
1661 (xtensa_sw_breakpoint_from_kind): Turn into...
1662 (xtensa_target::sw_breakpoint_from_kind): ...this.
1663 (the_low_target): Remove the op field.
1664
06250e4e
TBA
16652020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1666
1667 Remove the 'breakpoint_kind_from_pc' and
1668 'breakpoint_kind_from_current_state' linux target ops, and let the
1669 concrete linux target define them by overriding the ops of
1670 process_stratum_target.
1671
1672 * linux-low.cc (linux_process_target::breakpoint_kind_from_pc):
1673 Remove.
1674 (linux_process_target::breakpoint_kind_from_current_state): Remove.
1675 * linux-low.h (struct linux_target_ops): Remove ops.
1676 (class linux_process_target) <breakpoint_kind_from_pc>: Remove.
1677 <breakpoint_kind_from_current_state>: Remove.
1678 * linux-x86-low.cc (the_low_target): Remove the op fields.
1679 * linux-bfin-low.cc (the_low_target): Ditto.
1680 * linux-cris-low.cc (the_low_target): Ditto.
1681 * linux-crisv32-low.cc (the_low_target): Ditto.
1682 * linux-m32r-low.cc (the_low_target): Ditto.
1683 * linux-m68k-low.cc (the_low_target): Ditto.
1684 * linux-mips-low.cc (the_low_target): Ditto.
1685 * linux-nios2-low.cc (the_low_target): Ditto.
1686 * linux-ppc-low.cc (the_low_target): Ditto.
1687 * linux-s390-low.cc (the_low_target): Ditto.
1688 * linux-sh-low.cc (the_low_target): Ditto.
1689 * linux-sparc-low.cc (the_low_target): Ditto.
1690 * linux-tic6x-low.cc (the_low_target): Ditto.
1691 * linux-tile-low.cc (the_low_target): Ditto.
1692 * linux-xtensa-low.cc (the_low_target): Ditto.
1693 * linux-aarch64-low.cc (class aarch64_target)
1694 <breakpoint_kind_from_pc>
1695 <breakpoint_kind_from_current_state>: Declare.
1696 (aarch64_breakpoint_kind_from_pc): Turn into...
1697 (aarch64_target::breakpoint_kind_from_pc): ...this.
1698 (aarch64_breakpoint_kind_from_current_state): Turn into...
1699 (aarch64_target::breakpoint_kind_from_current_state): ...this.
1700 (the_low_target): Remove the op fields.
1701 * linux-arm-low.cc (class arm_target):
1702 <breakpoint_kind_from_pc>
1703 <breakpoint_kind_from_current_state>: Declare.
1704 (arm_target::breakpoint_kind_from_pc): Define.
1705 (arm_target::breakpoint_kind_from_current_state): Define.
1706 (the_low_target): Remove the op fields.
1707 * linux-riscv-low.cc (class riscv_target):
1708 <breakpoint_kind_from_pc>: Declare.
1709 (riscv_breakpoint_kind_from_pc): Turn into...
1710 (riscv_target::breakpoint_kind_from_pc): ...this.
1711 (the_low_target): Remove the op fields.
1712
bf9ae9d8
TBA
17132020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1714
1715 Turn the 'get_pc' and 'set_pc' linux target ops into methods
1716 of linux_process_target.
1717
1718 * linux-low.h (struct linux_target_ops): Remove the ops.
1719 (class linux_process_target) <low_supports_breakpoints>
1720 <low_get_pc>
1721 <low_set_pc>: Declare.
1722 * linux-low.cc (supports_breakpoints): Turn into...
1723 (linux_process_target::low_supports_breakpoints): ...this.
1724 (linux_process_target::low_get_pc): Define.
1725 (linux_process_target::low_set_pc): Define.
1726
1727 Update the callers below.
1728
1729 (linux_process_target::get_pc)
1730 (linux_process_target::save_stop_reason)
1731 (linux_process_target::maybe_move_out_of_jump_pad)
1732 (linux_process_target::wait_1)
1733 (linux_process_target::resume_one_lwp_throw)
1734 (linux_process_target::resume)
1735 (linux_process_target::proceed_all_lwps)
1736 (linux_process_target::read_pc)
1737 (linux_process_target::write_pc)
1738
1739 * linux-x86-low.cc (class linux_process_target)
1740 <low_supports_breakpoints>
1741 <low_get_pc>
1742 <low_set_pc>: Declare.
1743 (x86_target::low_supports_breakpoints): Define.
1744 (x86_get_pc): Turn into...
1745 (x86_target::low_get_pc): ...this.
1746 (x86_set_pc): Turn into...
1747 (x86_target::low_set_pc): ...this.
1748 (the_low_target): Remove the op fields.
1749 * linux-arm-low.cc (class arm_target)
1750 <low_supports_breakpoints>
1751 <low_get_pc>
1752 <low_set_pc>: Declare.
1753 (arm_target::low_supports_breakpoints)
1754 (arm_target::low_get_pc)
1755 (arm_target::low_set_pc): Define.
1756 (the_low_target): Remove the op fields.
1757 * linux-bfin-low.cc (class bfin_target)
1758 <low_supports_breakpoints>
1759 <low_get_pc>
1760 <low_set_pc>: Declare.
1761 (bfin_target::low_supports_breakpoints)
1762 (bfin_target::low_get_pc)
1763 (bfin_target::low_set_pc): Define.
1764 (the_low_target): Remove the op fields.
1765 * linux-cris-low.cc (class cris_target)
1766 <low_supports_breakpoints>
1767 <low_get_pc>
1768 <low_set_pc>: Declare.
1769 (cris_target::low_supports_breakpoints)
1770 (cris_target::low_get_pc)
1771 (cris_target::low_set_pc): Define.
1772 (the_low_target): Remove the op fields.
1773 * linux-crisv32-low.cc (class crisv32_target)
1774 <low_supports_breakpoints>
1775 <low_get_pc>
1776 <low_set_pc>: Declare.
1777 (crisv32_target::low_supports_breakpoints)
1778 (crisv32_target::low_get_pc)
1779 (crisv32_target::low_set_pc): Define.
1780 (the_low_target): Remove the op fields.
1781 * linux-m32r-low.cc (class m32r_target)
1782 <low_supports_breakpoints>
1783 <low_get_pc>
1784 <low_set_pc>: Declare.
1785 (m32r_target::low_supports_breakpoints)
1786 (m32r_target::low_get_pc)
1787 (m32r_target::low_set_pc): Define.
1788 (the_low_target): Remove the op fields.
1789 * linux-m68k-low.cc (class m68k_target)
1790 <low_supports_breakpoints>
1791 <low_get_pc>
1792 <low_set_pc>: Declare.
1793 (m68k_target::low_supports_breakpoints)
1794 (m68k_target::low_get_pc)
1795 (m68k_target::low_set_pc): Define.
1796 (the_low_target): Remove the op fields.
1797 * linux-nios2-low.cc (class nios2_target)
1798 <low_supports_breakpoints>
1799 <low_get_pc>
1800 <low_set_pc>: Declare.
1801 (nios2_target::low_supports_breakpoints)
1802 (nios2_target::low_get_pc)
1803 (nios2_target::low_set_pc): Define.
1804 (the_low_target): Remove the op fields.
1805 * linux-sh-low.cc (class sh_target)
1806 <low_supports_breakpoints>
1807 <low_get_pc>
1808 <low_set_pc>: Declare.
1809 (sh_target::low_supports_breakpoints)
1810 (sh_target::low_get_pc)
1811 (sh_target::low_set_pc): Define.
1812 (the_low_target): Remove the op fields.
1813 * linux-xtensa-low.cc (class xtensa_target)
1814 <low_supports_breakpoints>
1815 <low_get_pc>
1816 <low_set_pc>: Declare.
1817 (xtensa_target::low_supports_breakpoints)
1818 (xtensa_target::low_get_pc)
1819 (xtensa_target::low_set_pc): Define.
1820 (the_low_target): Remove the op fields.
1821 * linux-sparc-low.cc (class sparc_target)
1822 <low_supports_breakpoints>
1823 <low_get_pc>: Declare.
1824 (sparc_target::low_supports_breakpoints)
1825 (sparc_target::low_get_pc): Define.
1826 (the_low_target): Remove the op fields.
1827 * linux-tile-low.cc (class tile_target)
1828 <low_supports_breakpoints>
1829 <low_get_pc>
1830 <low_set_pc>: Declare.
1831 (tile_target::low_supports_breakpoints)
1832 (tile_target::low_get_pc)
1833 (tile_target::low_set_pc): Define.
1834 (the_low_target): Remove the op fields.
1835 * linux-aarch64-low.cc (class aarch64_target)
1836 <low_supports_breakpoints>
1837 <low_get_pc>
1838 <low_set_pc>: Declare.
1839 (aarch64_target::low_supports_breakpoints): Define.
1840 (aarch64_get_pc): Turn into...
1841 (aarch64_target::low_get_pc): ...this.
1842 (aarch64_set_pc): Turn into...
1843 (aarch64_target::low_set_pc): ...this.
1844 (the_low_target): Remove the op fields.
1845 * linux-mips-low.cc (class mips_target)
1846 <low_supports_breakpoints>
1847 <low_get_pc>
1848 <low_set_pc>: Declare.
1849 (mips_target::low_supports_breakpoints): Define.
1850 (mips_get_pc): Turn into...
1851 (mips_target::low_get_pc): ...this.
1852 (mips_set_pc): Turn into...
1853 (mips_target::low_set_pc): ...this.
1854 (the_low_target): Remove the op fields.
1855 * linux-ppc-low.cc (class ppc_target)
1856 <low_supports_breakpoints>
1857 <low_get_pc>
1858 <low_set_pc>: Declare.
1859 (ppc_target::low_supports_breakpoints): Define.
1860 (ppc_get_pc): Turn into...
1861 (ppc_target::low_get_pc): ...this.
1862 (ppc_set_pc): Turn into...
1863 (ppc_target::low_set_pc): ...this.
1864 (the_low_target): Remove the op fields.
1865 * linux-riscv-low.cc (class riscv_target)
1866 <low_supports_breakpoints>
1867 <low_get_pc>
1868 <low_set_pc>: Declare.
1869 (riscv_target::low_supports_breakpoints): Define.
1870 (riscv_get_pc): Turn into...
1871 (riscv_target::low_get_pc): ...this.
1872 (riscv_set_pc): Turn into...
1873 (riscv_target::low_set_pc): ...this.
1874 (the_low_target): Remove the op fields.
1875 * linux-s390-low.cc (class s390_target)
1876 <low_supports_breakpoints>
1877 <low_get_pc>
1878 <low_set_pc>: Declare.
1879 (s390_target::low_supports_breakpoints): Define.
1880 (s390_get_pc): Turn into...
1881 (s390_target::low_get_pc): ...this.
1882 (s390_set_pc): Turn into...
1883 (s390_target::low_set_pc): ...this.
1884 (the_low_target): Remove the op fields.
1885 * linux-tic6x-low.cc (class tic6x_target)
1886 <low_supports_breakpoints>
1887 <low_get_pc>
1888 <low_set_pc>: Declare.
1889 (tic6x_target::low_supports_breakpoints): Define.
1890 (tic6x_get_pc): Turn into...
1891 (tic6x_target::low_get_pc): ...this.
1892 (tic6x_set_pc): Turn into...
1893 (tic6x_target::low_set_pc): ...this.
1894 (the_low_target): Remove the op fields.
1895
df95181f
TBA
18962020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1897
1898 Turn some more static methods in linux-low into private methods
1899 of linux_process_target.
1900
1901 * linux-low.cc (get_pc): Turn into...
1902 (linux_process_target::get_pc): ...this.
1903 (save_stop_reason): Turn into...
1904 (linux_process_target::save_stop_reason): ...this.
1905 (thread_still_has_status_pending_p): Turn into...
1906 (linux_process_target::thread_still_has_status_pending): ...this.
1907 (status_pending_p_callback): Turn into...
1908 (linux_process_target::status_pending_p_callback): ...this.
1909 (resume_stopped_resumed_lwps): Turn into...
1910 (linux_process_target::resume_stopped_resumed_lwps): ...this.
1911 (install_software_single_step_breakpoints): Turn into...
1912 (linux_process_target::install_software_single_step_breakpoints):
1913 ...this.
1914 (single_step): Turn into...
1915 (linux_process_target::single_step): ...this.
1916 (linux_resume_one_lwp_throw): Turn into...
1917 (linux_process_target::resume_one_lwp_throw): ...this.
1918 (linux_resume_one_lwp): Turn into...
1919 (linux_process_target::resume_one_lwp): ...this.
1920 (resume_status_pending_p): Turn into...
1921 (linux_process_target::resume_status_pending): ...this.
1922 (need_step_over_p): Turn into...
1923 (linux_process_target::thread_needs_step_over): ...this.
1924 (linux_resume_one_thread): Turn into...
1925 (linux_process_target::resume_one_thread): ...this.
1926 (proceed_one_lwp): Turn into...
1927 (linux_process_target::proceed_one_lwp): ...this.
1928 (unsuspend_and_proceed_one_lwp): Turn into...
1929 (linux_process_target::unsuspend_and_proceed_one_lwp): ...this.
1930
1931 Update the calls/references to the above functions below.
1932
1933 (linux_process_target::handle_extended_wait)
1934 (linux_process_target::filter_event)
1935 (linux_process_target::wait_for_event_filtered)
1936 (linux_process_target::wait_1)
1937 (linux_process_target::move_out_of_jump_pad)
1938 (linux_process_target::start_step_over)
1939 (linux_process_target::resume)
1940 (linux_process_target::proceed_all_lwps)
1941 (regsets_store_inferior_registers)
1942 (linux_process_target::store_register)
1943
1944 * linux-low.h (class linux_process_target)
1945 <get_pc>
1946 <save_stop_reason>
1947 <thread_still_has_status_pending>
1948 <status_pending_p_callback>
1949 <resume_stopped_resumed_lwps>
1950 <install_software_single_step_breakpoints>
1951 <single_step>
1952 <resume_one_lwp_throw>
1953 <resume_one_lwp>
1954 <resume_status_pending>
1955 <thread_needs_step_over>
1956 <resume_one_thread>
1957 <proceed_one_lwp>
1958 <unsuspend_and_proceed_one_lwp>: Declare.
1959
bd70b1f2
TBA
19602020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1961
1962 Turn the 'fetch_register' linux target op into a method of
1963 linux_process_target.
1964
1965 * linux-low.h (struct linux_target_ops) <fetch_register>: Remove.
1966 (class linux_process_target) <low_fetch_register>: Declare.
1967 * linux-x86-low.cc (the_low_target)
1968 * linux-aarch64-low.cc (the_low_target)
1969 * linux-arm-low.cc (the_low_target)
1970 * linux-bfin-low.cc (the_low_target)
1971 * linux-cris-low.cc (the_low_target)
1972 * linux-crisv32-low.cc (the_low_target)
1973 * linux-m32r-low.cc (the_low_target)
1974 * linux-m68k-low.cc (the_low_target)
1975 * linux-nios2-low.cc (the_low_target)
1976 * linux-ppc-low.cc (the_low_target)
1977 * linux-s390-low.cc (the_low_target)
1978 * linux-sh-low.cc (the_low_target)
1979 * linux-sparc-low.cc (the_low_target)
1980 * linux-tic6x-low.cc (the_low_target)
1981 * linux-tile-low.cc (the_low_target)
1982 * linux-xtensa-low.cc (the_low_target): Remove the op field.
1983 * linux-ia64-low.cc (class ia64_target) <low_fetch_register>:
1984 Declare.
1985 (ia64_fetch_register): Turn into...
1986 (ia64_target::low_fetch_register): ...this.
1987 (the_low_target): Remove the op field.
1988 * linux-mips-low.cc (class mips_target) <low_fetch_register>:
1989 Declare.
1990 (mips_fetch_register): Turn into...
1991 (mips_target::low_fetch_register): ...this.
1992 (the_low_target): Remove the op field.
1993 * linux-riscv-low.cc (class riscv_target) <low_fetch_register>:
1994 Declare.
1995 (riscv_fetch_register): Turn into...
1996 (riscv_target::low_fetch_register): ...this.
1997 (the_low_target): Remove the op field.
1998
1999 Update the callers below.
2000
2001 * linux-low.cc (linux_process_target::fetch_registers)
2002 (linux_process_target::low_fetch_register)
2003
daca57a7
TBA
20042020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2005
2006 Turn the 'cannot_fetch_register' and 'cannot_store_register'
2007 linux target ops into methods of linux_process_target.
2008
2009 * linux-low.h (struct linux_target_ops): Remove the low target ops.
2010 (class linux_process_target) <fetch_register>
2011 <store_register>
2012 <usr_fetch_inferior_registers>
2013 <usr_store_inferior_registers>
2014 <low_cannot_fetch_register>
2015 <low_cannot_fetch_register> Declare.
2016 * linux-low.cc (fetch_register): Turn into...
2017 (linux_process_target::fetch_register): ...this.
2018 (store_register): Turn into ...
2019 (linux_process_target::store_register): ...this.
2020 (usr_fetch_inferior_registers): Turn into...
2021 (linux_process_target::usr_fetch_inferior_registers): ...this.
2022 (usr_store_inferior_registers): Turn into...
2023 (linux_process_target::usr_store_inferior_registers): ...this.
2024 * linux-x86-low.cc (class x86_target)
2025 <low_cannot_fetch_register>
2026 <low_cannot_store_register>: Declare.
2027 (x86_cannot_store_register): Turn into...
2028 (x86_target::low_cannot_store_register): ...this.
2029 (x86_cannot_fetch_register): Turn into...
2030 (x86_target::low_cannot_fetch_register): ...this.
2031 (the_low_target): Remove the target op fields.
2032 * linux-aarch64-low.cc (class aarch64_target)
2033 <low_cannot_fetch_register>
2034 <low_cannot_store_register>: Declare.
2035 (aarch64_target::low_cannot_fetch_register)
2036 (aarch64_target::low_cannot_store_register): Define.
2037 (the_low_target): Remove the op fields.
2038 * linux-arm-low.cc (class arm_target)
2039 <low_cannot_fetch_register>
2040 <low_cannot_store_register>: Declare.
2041 (arm_cannot_fetch_register): Turn into...
2042 (arm_target::low_cannot_fetch_register): ...this.
2043 (arm_cannot_store_register): Turn into...
2044 (arm_target::low_cannot_store_register): ...this.
2045 (the_low_target): Remove the op fields.
2046 * linux-bfin-low.cc (class bfin_target)
2047 <low_cannot_fetch_register>
2048 <low_cannot_store_register>: Declare.
2049 (bfin_cannot_fetch_register): Turn into...
2050 (bfin_target::low_cannot_fetch_register): ...this.
2051 (bfin_cannot_store_register): Turn into...
2052 (bfin_target::low_cannot_store_register): ...this.
2053 (the_low_target): Remove the op fields.
2054 * linux-cris-low.cc (class cris_target)
2055 <low_cannot_fetch_register>
2056 <low_cannot_store_register>: Declare.
2057 (cris_cannot_fetch_register): Turn into...
2058 (cris_target::low_cannot_fetch_register): ...this.
2059 (cris_cannot_store_register): Turn into...
2060 (cris_target::low_cannot_store_register): ...this.
2061 (the_low_target): Remove the op fields.
2062 * linux-crisv32-low.cc (class crisv32_target)
2063 <low_cannot_fetch_register>
2064 <low_cannot_store_register>: Declare.
2065 (crisv32_target::low_cannot_fetch_register)
2066 (crisv32_target::low_cannot_store_register): Define.
2067 (the_low_target): Remove the op fields.
2068 * linux-ia64-low.cc (class ia64_target)
2069 <low_cannot_fetch_register>
2070 <low_cannot_store_register>: Declare.
2071 (ia64_cannot_fetch_register): Turn into...
2072 (ia64_target::low_cannot_fetch_register): ...this.
2073 (ia64_cannot_store_register): Turn into...
2074 (ia64_target::low_cannot_store_register): ...this.
2075 (the_low_target): Remove the op fields.
2076 * linux-m32r-low.cc (class m32r_target)
2077 <low_cannot_fetch_register>
2078 <low_cannot_store_register>: Declare.
2079 (m32r_cannot_fetch_register): Turn into...
2080 (m32r_target::low_cannot_fetch_register): ...this.
2081 (m32r_cannot_store_register): Turn into...
2082 (m32r_target::low_cannot_store_register): ...this.
2083 (the_low_target): Remove the op fields.
2084 * linux-m68k-low.cc (class m68k_target)
2085 <low_cannot_fetch_register>
2086 <low_cannot_store_register>: Declare.
2087 (m68k_cannot_fetch_register): Turn into...
2088 (m68k_target::low_cannot_fetch_register): ...this.
2089 (m68k_cannot_store_register): Turn into...
2090 (m68k_target::low_cannot_store_register): ...this.
2091 (the_low_target): Remove the op fields.
2092 * linux-mips-low.cc (class mips_target)
2093 <low_cannot_fetch_register>
2094 <low_cannot_store_register>: Declare.
2095 (mips_cannot_fetch_register): Turn into...
2096 (mips_target::low_cannot_fetch_register): ...this.
2097 (mips_cannot_store_register): Turn into...
2098 (mips_target::low_cannot_store_register): ...this.
2099 (get_usrregs_info): Inline at the call sites in
2100 low_cannot_fetch_register and low_cannot_store_register,
2101 and remove.
2102 (the_low_target): Remove the op fields.
2103 * linux-nios2-low.cc (class nios2_target)
2104 <low_cannot_fetch_register>
2105 <low_cannot_store_register>: Declare.
2106 (nios2_cannot_fetch_register): Turn into...
2107 (nios2_target::low_cannot_fetch_register): ...this.
2108 (nios2_cannot_store_register): Turn into...
2109 (nios2_target::low_cannot_store_register): ...this.
2110 (the_low_target): Remove the op fields.
2111 * linux-ppc-low.cc (class ppc_target)
2112 <low_cannot_fetch_register>
2113 <low_cannot_store_register>: Declare.
2114 (ppc_cannot_fetch_register): Turn into...
2115 (ppc_target::low_cannot_fetch_register): ...this.
2116 (ppc_cannot_store_register): Turn into...
2117 (ppc_target::low_cannot_store_register): ...this.
2118 (the_low_target): Remove the op fields.
2119 * linux-riscv-low.cc (class riscv_target)
2120 <low_cannot_fetch_register>
2121 <low_cannot_store_register>: Declare.
2122 (riscv_target::low_cannot_fetch_register)
2123 (riscv_target::low_cannot_store_register): Define.
2124 (the_low_target): Remove the op fields.
2125 * linux-s390-low.cc (class s390_target)
2126 <low_cannot_fetch_register>
2127 <low_cannot_store_register>: Declare.
2128 (s390_cannot_fetch_register): Turn into...
2129 (s390_target::low_cannot_fetch_register): ...this.
2130 (s390_cannot_store_register): Turn into...
2131 (s390_target::low_cannot_store_register): ...this.
2132 (the_low_target): Remove the op fields.
2133 * linux-sh-low.cc (class sh_target)
2134 <low_cannot_fetch_register>
2135 <low_cannot_store_register>: Declare.
2136 (sh_cannot_fetch_register): Turn into...
2137 (sh_target::low_cannot_fetch_register): ...this.
2138 (sh_cannot_store_register): Turn into...
2139 (sh_target::low_cannot_store_register): ...this.
2140 (the_low_target): Remove the op fields.
2141 * linux-sparc-low.cc (class sparc_target)
2142 <low_cannot_fetch_register>
2143 <low_cannot_store_register>: Declare.
2144 (sparc_cannot_fetch_register): Turn into...
2145 (sparc_target::low_cannot_fetch_register): ...this.
2146 (sparc_cannot_store_register): Turn into...
2147 (sparc_target::low_cannot_store_register): ...this.
2148 (the_low_target): Remove the op fields.
2149 * linux-tic6x-low.cc (class tic6x_target)
2150 <low_cannot_fetch_register>
2151 <low_cannot_store_register>: Declare.
2152 (tic6x_cannot_fetch_register): Turn into...
2153 (tic6x_target::low_cannot_fetch_register): ...this.
2154 (tic6x_cannot_store_register): Turn into...
2155 (tic6x_target::low_cannot_store_register): ...this.
2156 (the_low_target): Remove the op fields.
2157 * linux-tile-low.cc (class tile_target)
2158 <low_cannot_fetch_register>
2159 <low_cannot_store_register>: Declare.
2160 (tile_cannot_fetch_register): Turn into...
2161 (tile_target::low_cannot_fetch_register): ...this.
2162 (tile_cannot_store_register): Turn into...
2163 (tile_target::low_cannot_store_register): ...this.
2164 (the_low_target): Remove the op fields.
2165 * linux-xtensa-low.cc (class xtensa_target)
2166 <low_cannot_fetch_register>
2167 <low_cannot_store_register>: Declare.
2168 (xtensa_target::low_cannot_fetch_register)
2169 (xtensa_target::low_cannot_store_register): Define.
2170 (the_low_target): Remove the op fields.
2171
aa8d21c9
TBA
21722020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2173
2174 Turn the 'regs_info' linux target op into a method of
2175 linux_process_target.
2176
2177 * linux-low.h (struct linux_target_ops) <regs_info>: Remove.
2178 (class linux_process_target) <get_regs_info>: Define.
2179
2180 Update the callers below.
2181
2182 * linux-low.cc (linux_process_target::fetch_registers)
2183 (linux_process_target::store_registers)
2184 * proc-service.cc (gregset_info)
2185
2186 * linux-x86-low.cc (class x86_target) <get_regs_info>: Declare.
2187 (x86_linux_regs_info): Turn into ...
2188 (x86_target::get_regs_info): ...this.
2189 (the_low_target): Remove the op field.
2190 * linux-aarch64-low.cc (class aarch64_target) <get_regs_info>:
2191 Declare.
2192 (aarch64_regs_info): Turn into ...
2193 (aarch64_target::get_regs_info): ...this.
2194 (the_low_target): Remove the op field.
2195 * linux-arm-low.cc (class arm_target) <get_regs_info>: Declare.
2196 (arm_regs_info): Turn into ...
2197 (arm_target::get_regs_info): ...this.
2198 (the_low_target): Remove the op field.
2199 * linux-bfin-low.cc (class bfin_target) <get_regs_info>: Declare.
2200 (bfin_regs_info): Turn into ...
2201 (bfin_target::get_regs_info): ...this.
2202 (the_low_target): Remove the op field.
2203 * linux-cris-low.cc (class cris_target) <get_regs_info>: Declare.
2204 (cris_regs_info): Turn into ...
2205 (cris_target::get_regs_info): ...this.
2206 (the_low_target): Remove the op field.
2207 * linux-crisv32-low.cc (class crisv32_target) <get_regs_info>:
2208 Declare.
2209 (crisv32_regs_info): Turn into ...
2210 (crisv32_target::get_regs_info): ...this.
2211 (the_low_target): Remove the op field.
2212 * linux-ia64-low.cc (class ia64_target) <get_regs_info>: Declare.
2213 (ia64_regs_info): Turn into ...
2214 (ia64_target::get_regs_info): ...this.
2215 (the_low_target): Remove the op field.
2216 * linux-m32r-low.cc (class m32r_target) <get_regs_info>: Declare.
2217 (m32r_regs_info): Turn into ...
2218 (m32r_target::get_regs_info): ...this.
2219 (the_low_target): Remove the op field.
2220 * linux-m68k-low.cc (class m68k_target) <get_regs_info>: Declare.
2221 (m68k_regs_info): Turn into ...
2222 (m68k_target::get_regs_info): ...this.
2223 (the_low_target): Remove the op field.
2224 * linux-mips-low.cc (class mips_target) <get_regs_info>: Declare.
2225 (mips_regs_info): Turn into ...
2226 (mips_target::get_regs_info): ...this.
2227 (the_low_target): Remove the op field.
2228 (get_usrregs_info): Update the call to the op.
2229 * linux-nios2-low.cc (class nios2_target) <get_regs_info>: Declare.
2230 (nios2_regs_info): Turn into ...
2231 (nios2_target::get_regs_info): ...this.
2232 (the_low_target): Remove the op field.
2233 * linux-ppc-low.cc (class ppc_target) <get_regs_info>: Declare.
2234 (ppc_regs_info): Turn into ...
2235 (ppc_target::get_regs_info): ...this.
2236 (the_low_target): Remove the op field.
2237 * linux-riscv-low.cc (class riscv_target) <get_regs_info>: Declare.
2238 (riscv_regs_info): Turn into ...
2239 (riscv_target::get_regs_info): ...this.
2240 (the_low_target): Remove the op field.
2241 * linux-s390-low.cc (class s390_target) <get_regs_info>: Declare.
2242 (s390_regs_info): Turn into ...
2243 (s390_target::get_regs_info): ...this.
2244 (the_low_target): Remove the op field.
2245 (s390_collect_ptrace_register)
2246 (s390_supply_ptrace_register)
2247 (s390_fill_gregset): Update the call to the op.
2248 * linux-sh-low.cc (class sh_target) <get_regs_info>: Declare.
2249 (sh_regs_info): Turn into ...
2250 (sh_target::get_regs_info): ...this.
2251 (the_low_target): Remove the op field.
2252 * linux-sparc-low.cc (class sparc_target) <get_regs_info>: Declare.
2253 (sparc_regs_info): Turn into ...
2254 (sparc_target::get_regs_info): ...this.
2255 (the_low_target): Remove the op field.
2256 * linux-tic6x-low.cc (class tic6x_target) <get_regs_info>: Declare.
2257 (tic6x_regs_info): Turn into ...
2258 (tic6x_target::get_regs_info): ...this.
2259 (the_low_target): Remove the op field.
2260 * linux-tile-low.cc (class tile_target) <get_regs_info>: Declare.
2261 (tile_regs_info): Turn into ...
2262 (tile_target::get_regs_info): ...this.
2263 (the_low_target): Remove the op field.
2264 * linux-xtensa-low.cc (class xtensa_target) <get_regs_info>:
2265 Declare.
2266 (xtensa_regs_info): Turn into ...
2267 (xtensa_target::get_regs_info): ...this.
2268 (the_low_target): Remove the op field.
2269
797bcff5
TBA
22702020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2271
2272 Turn the 'arch_setup' linux target op into a method of
2273 linux_process_target.
2274
2275 * linux-low.h (struct linux_target_ops) <arch_setup>: Delete.
2276 (class linux_process_target) <arch_setup_thread>
2277 <low_arch_setup>: New declarations.
2278 * linux-low.cc (linux_arch_setup): Delete.
2279 (linux_arch_setup_thread): Turn into...
2280 (linux_process_target::arch_setup_thread): ... this.
2281
2282 Update the callers below.
2283
2284 (linux_process_target::handle_extended_wait)
2285 (linux_process_target::post_create_inferior)
2286 (linux_process_target::filter_event)
2287
2288 * linux-x86-low.cc (class x86_target) <low_arch_setup>: New
2289 declaration.
2290 (x86_linux_update_xmltarget): Turn into...
2291 (x86_target::update_xmltarget): ...this.
2292 (x86_linux_process_qsupported): Update the call to
2293 x86_linux_update_xmltarget.
2294 (x86_arch_setup): Turn into ...
2295 (x86_target::low_arch_setup): ...this.
2296 (the_low_target): Remove the op field.
2297 * linux-aarch64-low.cc (class aarch64_target) <low_arch_setup>: New
2298 declaration.
2299 (aarch64_arch_setup): Turn into ...
2300 (aarch64_target::low_arch_setup): ...this.
2301 (the_low_target): Remove the op field.
2302 * linux-arm-low.cc (class arm_target) <low_arch_setup>: New
2303 declaration.
2304 (arm_arch_setup): Turn into ...
2305 (arm_target::low_arch_setup): ...this.
2306 (the_low_target): Remove the op field.
2307 * linux-bfin-low.cc (class bfin_target) <low_arch_setup>: New
2308 declaration.
2309 (bfin_arch_setup): Turn into ...
2310 (bfin_target::low_arch_setup): ...this.
2311 (the_low_target): Remove the op field.
2312 * linux-cris-low.cc (class cris_target) <low_arch_setup>: New
2313 declaration.
2314 (cris_arch_setup): Turn into ...
2315 (cris_target::low_arch_setup): ...this.
2316 (the_low_target): Remove the op field.
2317 * linux-crisv32-low.cc (class crisv32_target) <low_arch_setup>: New
2318 declaration.
2319 (crisv32_arch_setup): Turn into ...
2320 (crisv32_target::low_arch_setup): ...this.
2321 (the_low_target): Remove the op field.
2322 * linux-ia64-low.cc (class ia64_target) <low_arch_setup>: New
2323 declaration.
2324 (ia64_arch_setup): Turn into ...
2325 (ia64_target::low_arch_setup): ...this.
2326 (the_low_target): Remove the op field.
2327 * linux-m32r-low.cc (class m32r_target) <low_arch_setup>: New
2328 declaration.
2329 (m32r_arch_setup): Turn into ...
2330 (m32r_target::low_arch_setup): ...this.
2331 (the_low_target): Remove the op field.
2332 * linux-m68k-low.cc (class m68k_target) <low_arch_setup>: New
2333 declaration.
2334 (m68k_arch_setup): Turn into ...
2335 (m68k_target::low_arch_setup): ...this.
2336 (the_low_target): Remove the op field.
2337 * linux-mips-low.cc (class mips_target) <low_arch_setup>: New
2338 declaration.
2339 (mips_arch_setup): Turn into ...
2340 (mips_target::low_arch_setup): ...this.
2341 (the_low_target): Remove the op field.
2342 * linux-nios2-low.cc (class nios2_target) <low_arch_setup>: New
2343 declaration.
2344 (nios2_arch_setup): Turn into ...
2345 (nios2_target::low_arch_setup): ...this.
2346 (the_low_target): Remove the op field.
2347 * linux-ppc-low.cc (class ppc_target) <low_arch_setup>: New
2348 declaration.
2349 (ppc_arch_setup): Turn into ...
2350 (ppc_target::low_arch_setup): ...this.
2351 (the_low_target): Remove the op field.
2352 * linux-riscv-low.cc (class riscv_target) <low_arch_setup>: New
2353 declaration.
2354 (riscv_arch_setup): Turn into ...
2355 (riscv_target::low_arch_setup): ...this.
2356 (the_low_target): Remove the op field.
2357 * linux-s390-low.cc (class s390_target) <low_arch_setup>: New
2358 declaration.
2359 (s390_arch_setup): Turn into ...
2360 (s390_target::low_arch_setup): ...this.
2361 (the_low_target): Remove the op field.
2362 * linux-sh-low.cc (class sh_target) <low_arch_setup>: New
2363 declaration.
2364 (sh_arch_setup): Turn into ...
2365 (sh_target::low_arch_setup): ...this.
2366 (the_low_target): Remove the op field.
2367 * linux-sparc-low.cc (class sparc_target) <low_arch_setup>: New
2368 declaration.
2369 (sparc_arch_setup): Turn into ...
2370 (sparc_target::low_arch_setup): ...this.
2371 (the_low_target): Remove the op field.
2372 * linux-tic6x-low.cc (class tic6x_target) <low_arch_setup>: New
2373 declaration.
2374 (tic6x_arch_setup): Turn into ...
2375 (tic6x_target::low_arch_setup): ...this.
2376 (the_low_target): Remove the op field.
2377 * linux-tile-low.cc (class tile_target) <low_arch_setup>: New
2378 declaration.
2379 (tile_arch_setup): Turn into ...
2380 (tile_target::low_arch_setup): ...this.
2381 (the_low_target): Remove the op field.
2382 * linux-xtensa-low.cc (class xtensa_target) <low_arch_setup>: New
2383 declaration.
2384 (xtensa_arch_setup): Turn into ...
2385 (xtensa_target::low_arch_setup): ...this.
2386 (the_low_target): Remove the op field.
2387
ef0478f6
TBA
23882020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2389
2390 * linux-low.h (the_linux_target): New extern declaration.
2391 * linux-low.cc (initialize_low): Use 'the_linux_target' to set
2392 'the_target'.
2393 (the_linux_target): Remove.
2394 * linux-x86-low.cc (class x86_target): New class.
2395 (the_x86_target): New static object.
2396 (the_linux_target): Define as pointer to the_x86_target.
2397 * linux-aarch64-low.cc (class aarch64_target): New class.
2398 (the_aarch64_target): New static object.
2399 (the_linux_target): Define as pointer to the_aarch64_target.
2400 * linux-arm-low.cc (class arm_target): New class.
2401 (the_arm_target): New static object.
2402 (the_linux_target): Define as pointer to the_arm_target.
2403 * linux-bfin-low.cc (class bfin_target): New class.
2404 (the_bfin_target): New static object.
2405 (the_linux_target): Define as pointer to the_bfin_target.
2406 * linux-cris-low.cc (class cris_target): New class.
2407 (the_cris_target): New static object.
2408 (the_linux_target): Define as pointer to the_cris_target.
2409 * linux-crisv32-low.cc (class crisv32_target): New class.
2410 (the_crisv32_target): New static object.
2411 (the_linux_target): Define as pointer to the_crisv32_target.
2412 * linux-ia64-low.cc (class ia64_target): New class.
2413 (the_ia64_target): New static object.
2414 (the_linux_target): Define as pointer to the_ia64_target.
2415 * linux-m32r-low.cc (class m32r_target): New class.
2416 (the_m32r_target): New static object.
2417 (the_linux_target): Define as pointer to the_m32r_target.
2418 * linux-m68k-low.cc (class m68k_target): New class.
2419 (the_m68k_target): New static object.
2420 (the_linux_target): Define as pointer to the_m68k_target.
2421 * linux-mips-low.cc (class mips_target): New class.
2422 (the_mips_target): New static object.
2423 (the_linux_target): Define as pointer to the_mips_target.
2424 * linux-nios2-low.cc (class nios2_target): New class.
2425 (the_nios2_target): New static object.
2426 (the_linux_target): Define as pointer to the_nios2_target.
2427 * linux-ppc-low.cc (class ppc_target): New class.
2428 (the_ppc_target): New static object.
2429 (the_linux_target): Define as pointer to the_ppc_target.
2430 * linux-riscv-low.cc (class riscv_target): New class.
2431 (the_riscv_target): New static object.
2432 (the_linux_target): Define as pointer to the_riscv_target.
2433 * linux-s390-low.cc (class s390_target): New class.
2434 (the_s390_target): New static object.
2435 (the_linux_target): Define as pointer to the_s390_target.
2436 * linux-sh-low.cc (class sh_target): New class.
2437 (the_sh_target): New static object.
2438 (the_linux_target): Define as pointer to the_sh_target.
2439 * linux-sparc-low.cc (class sparc_target): New class.
2440 (the_sparc_target): New static object.
2441 (the_linux_target): Define as pointer to the_sparc_target.
2442 * linux-tic6x-low.cc (class tic6x_target): New class.
2443 (the_tic6x_target): New static object.
2444 (the_linux_target): Define as pointer to the_tic6x_target.
2445 * linux-tile-low.cc (class tile_target): New class.
2446 (the_tile_target): New static object.
2447 (the_linux_target): Define as pointer to the_tile_target.
2448 * linux-xtensa-low.cc (class xtensa_target): New class.
2449 (the_xtensa_target): New static object.
2450 (the_linux_target): Define as pointer to the_xtensa_target.
2451
d16f3f6c
TBA
24522020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2453
2454 Turn some static functions in linux-low.cc into private methods of
2455 linux_process_target.
2456
2457 * linux-low.cc (handle_extended_wait): Turn into ...
2458 (linux_process_target::handle_extended_wait): ...this. Call
2459 'mourn' on 'this' object instead of 'the_target'.
2460 (maybe_move_out_of_jump_pad): Turn into...
2461 (linux_process_target::maybe_move_out_of_jump_pad): ...this.
2462 (linux_low_filter_event): Turn into...
2463 (linux_process_target::filter_event): ...this.
2464 (linux_wait_for_event_filtered): Turn into...
2465 (linux_process_target::wait_for_event_filtered): ...this.
2466 (linux_wait_for_event): Turn into...
2467 (linux_process_target::wait_for_event): ...this.
2468 (linux_wait_1): Turn into...
2469 (linux_process_target::wait_1): ...this.
2470 (wait_for_sigstop): Turn into...
2471 (linux_process_target::wait_for_sigstop): ...this.
2472 (move_out_of_jump_pad_callback): Turn into...
2473 (linux_process_target::move_out_of_jump_pad): ...this.
2474 (stop_all_lwps): Turn into...
2475 (linux_process_target::stop_all_lwps): ...this.
2476 (start_step_over): Turn into...
2477 (linux_process_target::start_step_over): ...this.
2478 (complete_ongoing_step_over): Turn into...
2479 (linux_process_target::complete_ongoing_step_over): ...this.
2480 (proceed_all_lwps): Turn into...
2481 (linux_process_target::proceed_all_lwps): ...this.
2482 (unstop_all_lwps): Turn into...
2483 (linux_process_target::unstop_all_lwps): ...this.
2484
2485 * linux-low.h (class linux_process_target)
2486 <handle_extended_wait>
2487 <maybe_move_out_of_jump_pad>
2488 filter_event>
2489 <wait_for_event_filtered>
2490 <wait_for_event>
2491 <wait_1>
2492 <wait_for_sigstop>
2493 <move_out_of_jump_pad>
2494 <stop_all_lwps>
2495 <start_step_over>
2496 <complete_ongoing_step_over>
2497 <proceed_all_lwps>
2498 <unstop_all_lwps>: Declare.
2499
2500 Update the callers below.
2501
2502 * linux-low.cc (linux_process_target::attach): Update.
2503 (linux_process_target::stabilize_threads): Ditto.
2504 (linux_process_target::wait): Ditto.
2505
a5863204
TBA
25062020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2507
2508 * linux-low.h (struct linux_target_ops): Update the comment for
2509 'cannot_store_register' to return 0 or 1.
2510 * linux-ppc-low.cc (ppc_cannot_store_register): Return 1 instead
2511 of 2.
2512
c884cc46
SM
25132020-03-20 Simon Marchi <simon.marchi@efficios.com>
2514
2515 * config.in: Re-generate.
2516 * configure: Re-generate.
2517
5a82b8a1
KR
25182020-03-17 Kamil Rytarowski <n54@gmx.com>
2519
2520 * regcache.cc (find_register_by_number): Update.
2521 * tdesc.cc (init_target_desc): Likewise.
2522 * tdesc.h (target_desc::reg_defs): Likewise.
2523
4635ff97
TT
25242020-03-12 Tom Tromey <tom@tromey.com>
2525
2526 * configure: Rebuild.
2527 * configure.ac (GDBSERVER_DEPFILES): Remove srv_selftest_objs.
2528 (WIN32APILIBS): New subst.
2529 * Makefile.in (SFILES, OBS, TAGS, GDBREPLAY_OBS): Remove
2530 gdbsupport files.
2531 (gdbsupport/%.o): Remove target.
2532 (GDBSUPPORT_BUILDDIR, GDBSUPPORT): New variables.
2533 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Add GDBSUPPORT.
2534 (WIN32APILIBS): New variable.
2535 (gdbserver$(EXEEXT)): Add WIN32APILIBS.
2536 (gdbreplay$(EXEEXT)): Likewise.
2537
9a665d62
TT
25382020-03-12 Tom Tromey <tom@tromey.com>
2539
2540 * config.in, configure: Rebuild.
2541 * configure.ac: Call ZW_GNU_GETTEXT_SISTER_DIR.
2542 * acinclude.m4: Include gettext-sister.m4.
2543 * Makefile.in (top_builddir, INTL, INTL_DEPS, INTL_CFLAGS): New
2544 variables.
2545 (INCLUDE_CFLAGS): Add INTL_CFLAGS.
2546 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Use INTL_DEPS, INTL.
2547
272cd5a3
SM
25482020-03-12 Simon Marchi <simon.marchi@efficios.com>
2549
2550 * acinclude.m4: Update path to selftest.m4.
2551
db6878ac
SM
25522020-03-12 Simon Marchi <simon.marchi@efficios.com>
2553
2554 * configure.ac: Don't source bfd/development.sh, move
2555 GDB_AC_COMMON higher.
2556 * configure: Re-generate.
2557
4d696a5c
SM
25582020-03-12 Simon Marchi <simon.marchi@efficios.com>
2559
2560 * configure: Re-generate.
2561
a0761e34
SM
25622020-03-11 Simon Marchi <simon.marchi@efficios.com>
2563
2564 * configure: Re-generate.
2565
20ea4a60
AB
25662020-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
2567
2568 * .dir-locals.el: New file.
2569
842806cb
TBA
25702020-03-05 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2571
2572 * .gitattributes: New file.
2573
442131c1
AB
25742020-03-02 Andrew Burgess <andrew.burgess@embecosm.com>
2575
2576 * remote-utils.cc (prepare_resume_reply): Add ability to convert T
2577 reply into an S reply.
2578 * server.cc (disable_packet_T): New global.
2579 (captured_main): Set new global when appropriate.
2580 * server.h (disable_packet_T): Declare.
2581
dda42c0b
TT
25822020-02-21 Tom Tromey <tom@tromey.com>
2583
2584 * Makefile.in (mostlyclean): New target.
2585
52405d85
TBA
25862020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2587
2588 * target.h (struct process_stratum_target): Remove.
2589 (class process_target): Rename to ...
2590 (class process_stratum_target): ... this.
2591 * linux-low.h (class linux_process_target): Derive from
2592 'process_stratum_target'.
2593 * linux-low.cc (linux_target_ops): Remove.
2594 (initialize_low): Set the_target to the singleton instance of
2595 linux_process_target.
2596 * lynx-low.h (class lynx_process_target): Derive from
2597 'process_stratum_target'.
2598 * lynx-low.cc (lynx_target_ops): Remove.
2599 (initialize_low): Set the_target to the singleton instance of
2600 lynx_process_target.
2601 * nto-low.h (class nto_process_target): Derive from
2602 'process_stratum_target'.
2603 * nto-low.cc (nto_target_ops): Remove.
2604 (initialize_low): Set the_target to the singleton instance of
2605 nto_process_target.
2606 * win32-low.h (class win32_process_target): Derive from
2607 'process_stratum_target'.
2608 * win32-low.cc (win32_target_ops): Remove.
2609 (initialize_low): Set the_target to the singleton instance of
2610 win32_process_target.
2611
2612 Replace 'the_target->pt' with 'the_target' in the uses below.
2613
2614 * hostio.cc (hostio_error)
2615 (handle_setfs)
2616 (handle_open)
2617 (handle_unlink)
2618 (handle_readlink)
2619 * linux-aarch32-low.cc (arm_breakpoint_at)
2620 * linux-aarch64-low.cc (aarch64_breakpoint_at)
2621 * linux-arm-low.cc (arm_sigreturn_next_pc)
2622 (arm_get_hwcap)
2623 (arm_get_syscall_trapinfo)
2624 * linux-cris-low.cc (cris_breakpoint_at)
2625 * linux-crisv32-low.cc (cris_breakpoint_at)
2626 * linux-low.cc (handle_extended_wait)
2627 (linux_wait_1)
2628 (linux_read_memory)
2629 (linux_process_target::breakpoint_kind_from_pc)
2630 (linux_get_auxv)
2631 * linux-m32r-low.cc (m32r_breakpoint_at)
2632 * linux-mips-low.cc (mips_breakpoint_at)
2633 * linux-nios2-low.cc (nios2_breakpoint_at)
2634 * linux-ppc-low.cc (ppc_breakpoint_at)
2635 * linux-s390-low.cc (s390_get_hwcap)
2636 * linux-sh-low.cc (sh_breakpoint_at)
2637 * linux-sparc-low.cc (sparc_fill_gregset_to_stack)
2638 (sparc_store_gregset_from_stack)
2639 (sparc_breakpoint_at)
2640 * linux-tic6x-low.cc (tic6x_breakpoint_at)
2641 * linux-tile-low.cc (tile_breakpoint_at)
2642 * linux-x86-low.cc (x86_breakpoint_at)
2643 * linux-xtensa-low.cc (xtensa_breakpoint_at)
2644 * mem-break.cc (bp_size)
2645 (bp_opcode)
2646 (insert_memory_breakpoint)
2647 (set_raw_breakpoint_at)
2648 (delete_raw_breakpoint)
2649 (z_type_supported)
2650 (uninsert_raw_breakpoint)
2651 (reinsert_raw_breakpoint)
2652 (validate_inserted_breakpoint)
2653 * regcache.cc (regcache_read_pc)
2654 (regcache_write_pc)
2655 * remote-utils.cc (putpkt_binary_1)
2656 (input_interrupt)
2657 (getpkt)
2658 (prepare_resume_reply)
2659 * server.cc (handle_general_set)
2660 (handle_detach)
2661 (handle_qxfer_auxv)
2662 (handle_qxfer_exec_file)
2663 (handle_qxfer_libraries_svr4)
2664 (handle_qxfer_osdata)
2665 (handle_qxfer_siginfo)
2666 (handle_qxfer_fdpic)
2667 (handle_query)
2668 (resume)
2669 (handle_v_requests)
2670 (queue_stop_reply_callback)
2671 (captured_main)
2672 * target.cc (prepare_to_access_memory)
2673 (done_accessing_memory)
2674 (read_inferior_memory)
2675 (target_write_memory)
2676 (target_stop_and_wait)
2677 (target_wait)
2678 (target_mourn_inferior)
2679 (target_continue_no_signal)
2680 (target_continue)
2681 (target_supports_multi_process)
2682 (kill_inferior)
2683 * target.h
2684 (target_create_inferior)
2685 (target_post_create_inferior)
2686 (myattach)
2687 (target_supports_fork_events)
2688 (target_supports_vfork_events)
2689 (target_supports_exec_events)
2690 (target_handle_new_gdb_connection)
2691 (detach_inferior)
2692 (mythread_alive)
2693 (fetch_inferior_registers)
2694 (store_inferior_registers)
2695 (join_inferior)
2696 (target_supports_non_stop)
2697 (target_async)
2698 (target_process_qsupported)
2699 (target_supports_catch_syscall)
2700 (target_get_ipa_tdesc_idx)
2701 (target_supports_tracepoints)
2702 (target_supports_fast_tracepoints)
2703 (target_get_min_fast_tracepoint_insn_len)
2704 (target_thread_stopped)
2705 (target_pause_all)
2706 (target_unpause_all)
2707 (target_stabilize_threads)
2708 (target_install_fast_tracepoint_jump_pad)
2709 (target_emit_ops)
2710 (target_supports_disable_randomization)
2711 (target_supports_agent)
2712 (target_enable_btrace)
2713 (target_disable_btrace)
2714 (target_read_btrace)
2715 (target_read_btrace_conf)
2716 (target_supports_range_stepping)
2717 (target_supports_stopped_by_sw_breakpoint)
2718 (target_stopped_by_sw_breakpoint)
2719 (target_supports_stopped_by_hw_breakpoint)
2720 (target_supports_hardware_single_step)
2721 (target_stopped_by_hw_breakpoint)
2722 (target_breakpoint_kind_from_pc)
2723 (target_breakpoint_kind_from_current_state)
2724 (target_supports_software_single_step)
2725 (target_core_of_thread)
2726 (target_thread_name)
2727 (target_thread_handle)
2728 * win32-low.cc (do_initial_child_stuff)
2729
2730 Rename target op default definitions listed below.
2731
2732 * target.cc (process_target::post_create_inferior): Rename as ...
2733 (process_stratum_target::post_create_inferior): ... this.
2734 (process_target::prepare_to_access_memory): Rename as ...
2735 (process_stratum_target::prepare_to_access_memory): ... this.
2736 (process_target::done_accessing_memory): Rename as ...
2737 (process_stratum_target::done_accessing_memory): ... this.
2738 (process_target::look_up_symbols): Rename as ...
2739 (process_stratum_target::look_up_symbols): ... this.
2740 (process_target::supports_read_auxv): Rename as ...
2741 (process_stratum_target::supports_read_auxv): ... this.
2742 (process_target::read_auxv): Rename as ...
2743 (process_stratum_target::read_auxv): ... this.
2744 (process_target::supports_z_point_type): Rename as ...
2745 (process_stratum_target::supports_z_point_type): ... this.
2746 (process_target::insert_point): Rename as ...
2747 (process_stratum_target::insert_point): ... this.
2748 (process_target::remove_point): Rename as ...
2749 (process_stratum_target::remove_point): ... this.
2750 (process_target::stopped_by_sw_breakpoint): Rename as ...
2751 (process_stratum_target::stopped_by_sw_breakpoint): ... this.
2752 (process_target::supports_stopped_by_sw_breakpoint): Rename as ...
2753 (process_stratum_target::supports_stopped_by_sw_breakpoint): ... this.
2754 (process_target::stopped_by_hw_breakpoint): Rename as ...
2755 (process_stratum_target::stopped_by_hw_breakpoint): ... this.
2756 (process_target::supports_stopped_by_hw_breakpoint): Rename as ...
2757 (process_stratum_target::supports_stopped_by_hw_breakpoint): ... this.
2758 (process_target::supports_hardware_single_step): Rename as ...
2759 (process_stratum_target::supports_hardware_single_step): ... this.
2760 (process_target::stopped_by_watchpoint): Rename as ...
2761 (process_stratum_target::stopped_by_watchpoint): ... this.
2762 (process_target::stopped_data_address): Rename as ...
2763 (process_stratum_target::stopped_data_address): ... this.
2764 (process_target::supports_read_offsets): Rename as ...
2765 (process_stratum_target::supports_read_offsets): ... this.
2766 (process_target::read_offsets): Rename as ...
2767 (process_stratum_target::read_offsets): ... this.
2768 (process_target::supports_get_tls_address): Rename as ...
2769 (process_stratum_target::supports_get_tls_address): ... this.
2770 (process_target::get_tls_address): Rename as ...
2771 (process_stratum_target::get_tls_address): ... this.
2772 (process_target::hostio_last_error): Rename as ...
2773 (process_stratum_target::hostio_last_error): ... this.
2774 (process_target::supports_qxfer_osdata): Rename as ...
2775 (process_stratum_target::supports_qxfer_osdata): ... this.
2776 (process_target::qxfer_osdata): Rename as ...
2777 (process_stratum_target::qxfer_osdata): ... this.
2778 (process_target::supports_qxfer_siginfo): Rename as ...
2779 (process_stratum_target::supports_qxfer_siginfo): ... this.
2780 (process_target::qxfer_siginfo): Rename as ...
2781 (process_stratum_target::qxfer_siginfo): ... this.
2782 (process_target::supports_non_stop): Rename as ...
2783 (process_stratum_target::supports_non_stop): ... this.
2784 (process_target::async): Rename as ...
2785 (process_stratum_target::async): ... this.
2786 (process_target::start_non_stop): Rename as ...
2787 (process_stratum_target::start_non_stop): ... this.
2788 (process_target::supports_multi_process): Rename as ...
2789 (process_stratum_target::supports_multi_process): ... this.
2790 (process_target::supports_fork_events): Rename as ...
2791 (process_stratum_target::supports_fork_events): ... this.
2792 (process_target::supports_vfork_events): Rename as ...
2793 (process_stratum_target::supports_vfork_events): ... this.
2794 (process_target::supports_exec_events): Rename as ...
2795 (process_stratum_target::supports_exec_events): ... this.
2796 (process_target::handle_new_gdb_connection): Rename as ...
2797 (process_stratum_target::handle_new_gdb_connection): ... this.
2798 (process_target::handle_monitor_command): Rename as ...
2799 (process_stratum_target::handle_monitor_command): ... this.
2800 (process_target::core_of_thread): Rename as ...
2801 (process_stratum_target::core_of_thread): ... this.
2802 (process_target::supports_read_loadmap): Rename as ...
2803 (process_stratum_target::supports_read_loadmap): ... this.
2804 (process_target::read_loadmap): Rename as ...
2805 (process_stratum_target::read_loadmap): ... this.
2806 (process_target::process_qsupported): Rename as ...
2807 (process_stratum_target::process_qsupported): ... this.
2808 (process_target::supports_tracepoints): Rename as ...
2809 (process_stratum_target::supports_tracepoints): ... this.
2810 (process_target::read_pc): Rename as ...
2811 (process_stratum_target::read_pc): ... this.
2812 (process_target::write_pc): Rename as ...
2813 (process_stratum_target::write_pc): ... this.
2814 (process_target::supports_thread_stopped): Rename as ...
2815 (process_stratum_target::supports_thread_stopped): ... this.
2816 (process_target::thread_stopped): Rename as ...
2817 (process_stratum_target::thread_stopped): ... this.
2818 (process_target::supports_get_tib_address): Rename as ...
2819 (process_stratum_target::supports_get_tib_address): ... this.
2820 (process_target::get_tib_address): Rename as ...
2821 (process_stratum_target::get_tib_address): ... this.
2822 (process_target::pause_all): Rename as ...
2823 (process_stratum_target::pause_all): ... this.
2824 (process_target::unpause_all): Rename as ...
2825 (process_stratum_target::unpause_all): ... this.
2826 (process_target::stabilize_threads): Rename as ...
2827 (process_stratum_target::stabilize_threads): ... this.
2828 (process_target::supports_fast_tracepoints): Rename as ...
2829 (process_stratum_target::supports_fast_tracepoints): ... this.
2830 (process_target::get_min_fast_tracepoint_insn_len): Rename as ...
2831 (process_stratum_target::get_min_fast_tracepoint_insn_len): ... this.
2832 (process_target::emit_ops): Rename as ...
2833 (process_stratum_target::emit_ops): ... this.
2834 (process_target::supports_disable_randomization): Rename as ...
2835 (process_stratum_target::supports_disable_randomization): ... this.
2836 (process_target::supports_qxfer_libraries_svr4): Rename as ...
2837 (process_stratum_target::supports_qxfer_libraries_svr4): ... this.
2838 (process_target::qxfer_libraries_svr4): Rename as ...
2839 (process_stratum_target::qxfer_libraries_svr4): ... this.
2840 (process_target::supports_agent): Rename as ...
2841 (process_stratum_target::supports_agent): ... this.
2842 (process_target::enable_btrace): Rename as ...
2843 (process_stratum_target::enable_btrace): ... this.
2844 (process_target::disable_btrace): Rename as ...
2845 (process_stratum_target::disable_btrace): ... this.
2846 (process_target::read_btrace): Rename as ...
2847 (process_stratum_target::read_btrace): ... this.
2848 (process_target::read_btrace_conf): Rename as ...
2849 (process_stratum_target::read_btrace_conf): ... this.
2850 (process_target::supports_range_stepping): Rename as ...
2851 (process_stratum_target::supports_range_stepping): ... this.
2852 (process_target::supports_pid_to_exec_file): Rename as ...
2853 (process_stratum_target::supports_pid_to_exec_file): ... this.
2854 (process_target::pid_to_exec_file): Rename as ...
2855 (process_stratum_target::pid_to_exec_file): ... this.
2856 (process_target::supports_multifs): Rename as ...
2857 (process_stratum_target::supports_multifs): ... this.
2858 (process_target::multifs_open): Rename as ...
2859 (process_stratum_target::multifs_open): ... this.
2860 (process_target::multifs_unlink): Rename as ...
2861 (process_stratum_target::multifs_unlink): ... this.
2862 (process_target::multifs_readlink): Rename as ...
2863 (process_stratum_target::multifs_readlink): ... this.
2864 (process_target::breakpoint_kind_from_pc): Rename as ...
2865 (process_stratum_target::breakpoint_kind_from_pc): ... this.
2866 (process_target::breakpoint_kind_from_current_state): Rename as ...
2867 (process_stratum_target::breakpoint_kind_from_current_state): ... this.
2868 (process_target::thread_name): Rename as ...
2869 (process_stratum_target::thread_name): ... this.
2870 (process_target::thread_handle): Rename as ...
2871 (process_stratum_target::thread_handle): ... this.
2872 (process_target::supports_software_single_step): Rename as ...
2873 (process_stratum_target::supports_software_single_step): ... this.
2874 (process_target::supports_catch_syscall): Rename as ...
2875 (process_stratum_target::supports_catch_syscall): ... this.
2876 (process_target::get_ipa_tdesc_idx): Rename as ...
2877 (process_stratum_target::get_ipa_tdesc_idx): ... this.
2878
478f9adf
PA
28792020-02-20 Pedro Alves <palves@redhat.com>
2880
2881 * target.cc (set_target_ops): Simply copy the given target pointer
2882 instead of creating a copy of the pointed object.
2883
d633e831
TBA
28842020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2885
2886 Turn process_stratum_target's get_ipa_tdesc_idx op into a method
2887 of process_target.
2888
2889 * target.h (struct process_stratum_target): Remove the target op.
2890 (class process_target): Add the target op.
2891 (target_get_ipa_tdesc_idx): Update the macro.
2892 * target.cc (process_target::get_ipa_tdesc_idx): Define.
2893
2894 Update the derived classes and callers below.
2895
2896 * linux-low.cc (linux_target_ops): Update.
2897 (linux_get_ipa_tdesc_idx): Turn into ...
2898 (linux_process_target::get_ipa_tdesc_idx): ... this.
2899 * linux-low.h (class linux_process_target): Update.
2900 * lynx-low.cc (lynx_target_ops): Update.
2901 * nto-low.cc (nto_target_ops): Update.
2902 * win32-low.cc (win32_target_ops): Update.
2903
bc8d3ae4
TBA
29042020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2905
2906 Turn process_stratum_target's supports_catch_syscall op into a
2907 method of process_target.
2908
2909 * target.h (struct process_stratum_target): Remove the target op.
2910 (class process_target): Add the target op.
2911 (target_supports_catch_syscall): Update the macro.
2912 * target.cc (process_target::supports_catch_syscall): Define.
2913
2914 Update the derived classes and callers below.
2915
2916 * linux-low.cc (linux_target_ops): Update.
2917 (linux_supports_catch_syscall): Turn into ...
2918 (linux_process_target::supports_catch_syscall): ... this.
2919 * linux-low.h (class linux_process_target): Update.
2920 * lynx-low.cc (lynx_target_ops): Update.
2921 * nto-low.cc (nto_target_ops): Update.
2922 * win32-low.cc (win32_target_ops): Update.
2923
5303a34f
TBA
29242020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2925
2926 Turn process_stratum_target's supports_software_single_step op
2927 into a method of process_target.
2928
2929 * target.h (struct process_stratum_target): Remove the target op.
2930 (class process_target): Add the target op.
2931 (target_supports_software_single_step): Update the macro.
2932 * target.cc (process_target::supports_software_single_step): Define.
2933
2934 Update the derived classes and callers below.
2935
2936 * linux-low.cc (linux_target_ops): Update.
2937 (linux_supports_software_single_step): Turn into ...
2938 (linux_process_target::supports_software_single_step): ... this.
2939 * linux-low.h (class linux_process_target): Update.
2940 * lynx-low.cc (lynx_target_ops): Update.
2941 * nto-low.cc (nto_target_ops): Update.
2942 * win32-low.cc (win32_target_ops): Update.
2943
7f63b89b
TBA
29442020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2945
2946 Turn process_stratum_target's thread_name and thread_handle ops
2947 into methods of process_target.
2948
2949 * target.h (struct process_stratum_target): Remove the target ops.
2950 (class process_target): Add the target ops.
2951 (target_thread_name): Update the macro.
2952 (target_thread_handle): Update the macro.
2953 * target.cc (process_target::thread_name): Define.
2954 (process_target::thread_handle): Define.
2955
2956 Update the derived classes and callers below.
2957
2958 * linux-low.cc (linux_target_ops): Update.
2959 (linux_process_target::thread_name): Define.
2960 (linux_process_target::thread_handle): Define.
2961 * linux-low.h (class linux_process_target): Update.
2962 * lynx-low.cc (lynx_target_ops): Update.
2963 * nto-low.cc (nto_target_ops): Update.
2964 * win32-low.cc (win32_target_ops): Update.
2965
d367006f
TBA
29662020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2967
2968 Turn process_stratum_target's breakpoint_kind_from_pc,
2969 sw_breakpoint_from_kind, and breakpoint_kind_from_current_state
2970 ops into methods of process_target.
2971
2972 * target.h (struct process_stratum_target): Remove the target op.
2973 (class process_target): Add the target op.
2974 (target_breakpoint_kind_from_pc): Update the macro.
2975 (target_breakpoint_kind_from_current_state): Update the macro.
2976 (default_breakpoint_kind_from_pc): Remove declaration.
2977 * target.cc (default_breakpoint_kind_from_pc): Turn into ...
2978 (process_target::breakpoint_kind_from_pc): ... this.
2979 (process_target::breakpoint_kind_from_current_state): Define.
2980
2981 Update the derived classes and callers below.
2982
2983 * mem-break.cc (bp_size): Update.
2984 (bp_opcode): Update.
2985 * linux-low.cc (linux_target_ops): Update.
2986 (linux_wait_1): Update.
2987 (linux_breakpoint_kind_from_pc): Turn into ...
2988 (linux_process_target::breakpoint_kind_from_pc): ... this.
2989 (linux_sw_breakpoint_from_kind): Turn into ...
2990 (linux_process_target::sw_breakpoint_from_kind): ... this.
2991 (linux_breakpoint_kind_from_current_state): Turn into ...
2992 (linux_process_target::breakpoint_kind_from_current_state): ... this.
2993 * linux-low.h (class linux_process_target): Update.
2994 * lynx-low.cc (lynx_target_ops): Update.
2995 (lynx_process_target::sw_breakpoint_from_kind): Define.
2996 * lynx-low.h (class lynx_process_target): Update.
2997 * nto-low.cc (nto_target_ops): Update.
2998 (nto_sw_breakpoint_from_kind): Turn into ...
2999 (nto_process_target::sw_breakpoint_from_kind): ... this.
3000 * nto-low.h (class nto_process_target): Update.
3001 * win32-low.cc (win32_target_ops): Update.
3002 (win32_sw_breakpoint_from_kind): Turn into ...
3003 (win32_process_target::sw_breakpoint_from_kind): ... this.
3004 * win32-low.h (class win32_process_target): Update.
3005
c9b7b804
TBA
30062020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3007
3008 Turn process_stratum_target's multifs_open, multifs_readlink,
3009 multifs_unlink ops into methods of process_target.
3010
3011 * target.h (struct process_stratum_target): Remove the target ops.
3012 (class process_target): Add the target ops. Also add
3013 'supports_multifs'.
3014 * target.cc: Include "fcntl.h", "unistd.h", "sys/types.h", and
3015 "sys/stat.h".
3016 (process_target::supports_multifs): Define.
3017 (process_target::multifs_open): Define.
3018 (process_target::multifs_readlink): Define.
3019 (process_target::multifs_unlink): Define.
3020
3021 Update the derived classes and callers below.
3022
3023 * hostio.cc (handle_setfs): Update.
3024 (handle_open): Update.
3025 (handle_unlink): Update.
3026 (handle_readlink): Update.
3027 * linux-low.cc (linux_target_ops): Update.
3028 (linux_process_target::supports_multifs): Define.
3029 (linux_process_target::multifs_open): Define.
3030 (linux_process_target::multifs_readlink): Define.
3031 (linux_process_target::multifs_unlink): Define.
3032 * linux-low.h (class linux_process_target): Update.
3033 * lynx-low.cc (lynx_target_ops): Update.
3034 * nto-low.cc (nto_target_ops): Update.
3035 * win32-low.cc (win32_target_ops): Update.
3036
8247b823
TBA
30372020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3038
3039 Turn process_stratum_target's pid_to_exec_file op into a method
3040 of process_target.
3041
3042 * target.h (struct process_stratum_target): Remove the target op.
3043 (class process_target): Add the target op. Also add
3044 'supports_pid_to_exec_file'.
3045 * target.cc (process_target::pid_to_exec_file): Define.
3046 (process_target::supports_pid_to_exec_file): Define.
3047
3048 Update the derived classes and callers below.
3049
3050 * server.cc (handle_qxfer_exec_file): Update.
3051 (handle_query): Update.
3052 * linux-low.cc (linux_target_ops): Update.
3053 (linux_process_target::supports_pid_to_exec_file): Define.
3054 (linux_process_target::pid_to_exec_file): Define.
3055 * linux-low.h (class linux_process_target): Update.
3056 * lynx-low.cc (lynx_target_ops): Update.
3057 * nto-low.cc (nto_target_ops): Update.
3058 * win32-low.cc (win32_target_ops): Update.
3059
2526e0cd
TBA
30602020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3061
3062 Turn process_stratum_target's supports_range_stepping op into a
3063 method of process_target.
3064
3065 * target.h (struct process_stratum_target): Remove the target op.
3066 (class process_target): Add the target op.
3067 (target_supports_range_stepping): Update the macro.
3068 * target.cc (process_target::supports_range_stepping): Define.
3069
3070 Update the derived classes and callers below.
3071
3072 * linux-low.cc (linux_target_ops): Update.
3073 (linux_supports_range_stepping): Turn into ...
3074 (linux_process_target::supports_range_stepping): ... this.
3075 * linux-low.h (class linux_process_target): Update.
3076 * lynx-low.cc (lynx_target_ops): Update.
3077 * nto-low.cc (nto_target_ops): Update.
3078 * win32-low.cc (win32_target_ops): Update.
3079
79597bdd
TBA
30802020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3081
3082 Turn process_stratum_target's btrace-related ops (enable_btrace,
3083 disable_btrace, read_btrace, read_btrace_conf) into methods of
3084 process_target.
3085
3086 * target.h (struct process_stratum_target): Remove the target ops.
3087 (class process_target): Add the target ops.
3088 (target_enable_btrace): Update.
3089 (target_disable_btrace): Update.
3090 (target_read_btrace): Update.
3091 (target_read_btrace_conf): Update.
3092 * target.cc (process_target::enable_btrace): Define.
3093 (process_target::disable_btrace): Define.
3094 (process_target::read_btrace): Define.
3095 (process_target::read_btrace_conf): Define.
3096
3097 Update the derived classes and callers below.
3098
3099 * linux-low.cc (linux_target_ops): Update.
3100 (linux_process_target:enable_btrace): Define as a wrapper around
3101 linux_enable_btrace.
3102 (linux_low_disable_btrace): Turn into ...
3103 (linux_process_target::disable_btrace): ... this.
3104 (linux_low_read_btrace): Turn into ...
3105 (linux_process_target::read_btrace): ... this.
3106 (linux_low_btrace_conf): Turn into ...
3107 (linux_process_target::read_btrace_conf): ... this.
3108 * linux-low.h (class linux_process_target): Update.
3109 * lynx-low.cc (lynx_target_ops): Update.
3110 * nto-low.cc (nto_target_ops): Update.
3111 * win32-low.cc (win32_target_ops): Update.
3112
c0245cb9
TBA
31132020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3114
3115 Turn process_stratum_target's supports_agent op into a method of
3116 process_target.
3117
3118 * target.h (struct process_stratum_target): Remove the target op.
3119 (class process_target): Add the target op.
3120 (target_supports_agent): Update the macro.
3121 * target.cc (process_target::supports_agent): Define.
3122
3123 Update the derived classes and callers below.
3124
3125 * linux-low.cc (linux_target_ops): Update.
3126 (linux_supports_agent): Turn into ...
3127 (linux_process_target::supports_agent): ... this.
3128 * linux-low.h (class linux_process_target): Update.
3129 * lynx-low.cc (lynx_target_ops): Update.
3130 * nto-low.cc (nto_target_ops): Update.
3131 * win32-low.cc (win32_target_ops): Update.
3132
974387bb
TBA
31332020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3134
3135 Turn process_stratum_target's qxfer_libraries_svr4 op into a
3136 method of process_target.
3137
3138 * target.h (struct process_stratum_target): Remove the target op.
3139 (class process_target): Add the target op. Also add
3140 'supports_qxfer_libraries_svr4'.
3141 * target.cc (process_target::qxfer_libraries_svr4): Define.
3142 (process_target::supports_qxfer_libraries_svr4): Define.
3143
3144 Update the derived classes and callers below.
3145
3146 * server.cc (handle_qxfer_libraries_svr4): Update.
3147 (handle_query): Update.
3148 * linux-low.cc (linux_target_ops): Update.
3149 (linux_process_target::supports_qxfer_libraries_svr4): Define.
3150 (linux_qxfer_libraries_svr4): Turn into ...
3151 (linux_process_target::qxfer_libraries_svr4): ... this.
3152 * linux-low.h (class linux_process_target): Update.
3153 * lynx-low.cc (lynx_target_ops): Update.
3154 * nto-low.cc (nto_target_ops): Update.
3155 * win32-low.cc (win32_target_ops): Update.
3156
c756403b
TBA
31572020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3158
3159 Turn process_stratum_target's supports_disable_randomization op
3160 into a method of process_target.
3161
3162 * target.h (struct process_stratum_target): Remove the target op.
3163 (class process_target): Add the target op.
3164 (target_supports_disable_randomization): Update the macro.
3165 * target.cc (process_target::supports_disable_randomization): Define.
3166
3167 Update the derived classes and callers below.
3168
3169 * linux-low.cc (linux_target_ops): Update.
3170 (linux_supports_disable_randomization): Turn into ...
3171 (linux_process_target::supports_disable_randomization): ... this.
3172 * linux-low.h (class linux_process_target): Update.
3173 * lynx-low.cc (lynx_target_ops): Update.
3174 * nto-low.cc (nto_target_ops): Update.
3175 * win32-low.cc (win32_target_ops): Update.
3176
345dafad
TBA
31772020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3178
3179 Turn process_stratum_target's emit_ops op into a method of
3180 process_target.
3181
3182 * target.h (struct process_stratum_target): Remove the target op.
3183 (class process_target): Add the target op.
3184 (target_emit_ops): Update the macro.
3185 * target.cc (process_target::emit_ops): Define.
3186
3187 Update the derived classes and callers below.
3188
3189 * linux-low.cc (linux_target_ops): Update.
3190 (linux_emit_ops): Turn into ...
3191 (linux_process_target::emit_ops): ... this.
3192 * linux-low.h (class linux_process_target): Update.
3193 * lynx-low.cc (lynx_target_ops): Update.
3194 * nto-low.cc (nto_target_ops): Update.
3195 * win32-low.cc (win32_target_ops): Update.
3196
c23c9391
TBA
31972020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3198
3199 Turn process_stratum_target's install_fast_tracepoint_jump_pad
3200 and get_min_fast_tracepoint_insn_len ops into methods of
3201 process_target.
3202
3203 * target.h (struct process_stratum_target): Remove the target ops.
3204 (class process_target): Add the target ops. Also add
3205 'supports_fast_tracepoints'.
3206 (target_supports_fast_tracepoints): Update the macro.
3207 (target_get_min_fast_tracepoint_insn_len): Update the macro.
3208 (install_fast_tracepoint_jump_pad): Update and rename the macro
3209 to ...
3210 (target_install_fast_tracepoint_jump_pad): ... this.
3211 * target.cc (process_target::supports_fast_tracepoints): Define.
3212 (process_target::install_fast_tracepoint_jump_pad): Define.
3213 (process_target::get_min_fast_tracepoint_insn_len): Define.
3214
3215 Update the derived classes and callers below.
3216
3217 * tracepoint.cc (install_fast_tracepoint): Update.
3218 * linux-low.cc (linux_target_ops): Update.
3219 (linux_process_target::supports_fast_tracepoints): Define.
3220 (linux_install_fast_tracepoint_jump_pad): Turn into ...
3221 (linux_process_target::install_fast_tracepoint_jump_pad): ... this.
3222 (linux_get_min_fast_tracepoint_insn_len): Turn into ...
3223 (linux_process_target::get_min_fast_tracepoint_insn_len): ... this.
3224 * linux-low.h (class linux_process_target): Update.
3225 * lynx-low.cc (lynx_target_ops): Update.
3226 * nto-low.cc (nto_target_ops): Update.
3227 * win32-low.cc (win32_target_ops): Update.
3228
5c9eb2f2
TBA
32292020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3230
3231 Turn process_stratum_target's stabilize_threads op into a
3232 method of process_target.
3233
3234 * target.h (struct process_stratum_target): Remove the target op.
3235 (class process_target): Add the target op.
3236 (target_stabilize_threads): Update the macro.
3237 * target.cc (process_target::stabilize_threads): Define.
3238
3239 Update the derived classes and callers below.
3240
3241 * server.cc (handle_status): Update.
3242 * tracepoint.cc (cmd_qtdp): Update.
3243 (cmd_qtstart): Update.
3244 * linux-low.cc (linux_target_ops): Update.
3245 (linux_stabilize_threads): Turn into ...
3246 (linux_process_target::stabilize_threads): ... this.
3247 (linux_wait_1): Update.
3248 * linux-low.h (class linux_process_target): Update.
3249 * lynx-low.cc (lynx_target_ops): Update.
3250 * nto-low.cc (nto_target_ops): Update.
3251 * win32-low.cc (win32_target_ops): Update.
3252
29e8dc09
TBA
32532020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3254
3255 Turn process_stratum_target's pause_all and unpause_all ops
3256 into methods of process_target.
3257
3258 * target.h (struct process_stratum_target): Remove the target ops.
3259 (class process_target): Add the target ops.
3260 (pause_all): Update the macro and rename to...
3261 (target_pause_all): ... this.
3262 (unpause_all): Update the macro and rename to...
3263 (target_unpause_all): ... this.
3264 * target.cc (process_target::pause_all): Define.
3265 (process_target::unpause_all): Define.
3266
3267 Update the derived classes and callers below.
3268
3269 * server.cc (handle_status): Update.
3270 * tracepoint.cc (clear_installed_tracepoints): Update.
3271 (cmd_qtdp): Update.
3272 (cmd_qtstart): Update.
3273 (stop_tracing): Update.
3274 (cmd_qtstatus): Update.
3275 (upload_fast_traceframes): Update.
3276 (run_inferior_command): Update.
3277 * linux-low.cc (linux_target_ops): Update.
3278 (linux_pause_all): Turn into ...
3279 (linux_process_target::pause_all): ... this.
3280 (linux_unpause_all): Turn into ...
3281 (linux_process_target::unpause_all): ... this.
3282 (linux_process_target::prepare_to_access_memory): Update.
3283 (linux_process_target::done_accessing_memory): Update.
3284 * linux-low.h (class linux_process_target): Update.
3285 * lynx-low.cc (lynx_target_ops): Update.
3286 * nto-low.cc (nto_target_ops): Update.
3287 * win32-low.cc (win32_target_ops): Update.
3288
4e2e869c
TBA
32892020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3290
3291 Turn process_stratum_target's get_tib_address op into a method of
3292 process_target.
3293
3294 * target.h (struct process_stratum_target): Remove the target op.
3295 (class process_target): Add the target op. Also add
3296 'supports_get_tib_address'.
3297 * target.cc (process_target::get_tib_address): Define.
3298 (process_target::supports_get_tib_address): Define.
3299
3300 Update the derived classes and callers below.
3301
3302 * server.cc (handle_query): Update.
3303 * linux-low.cc (win32_target_ops): Update.
3304 * lynx-low.cc (lynx_target_ops): Update.
3305 * nto-low.cc (nto_target_ops): Update.
3306 * win32-low.cc (win32_target_ops): Update.
3307 (win32_process_target::supports_get_tib_address): Define.
3308 (win32_get_tib_address): Turn into ...
3309 (win32_process_target::get_tib_address): ... this.
3310 * win32-low.h (class win32_process_target): Update.
3311
68119632
TBA
33122020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3313
3314 Turn process_stratum_target's thread_stopped op into a method of
3315 process_target.
3316
3317 * target.h (struct process_stratum_target): Remove the target op.
3318 (class process_target): Add the target op. Also add
3319 'supports_thread_stopped'.
3320 (target_thread_stopped): Update the macro.
3321 * target.cc (process_target::thread_stopped): Define.
3322 (process_target::supports_thread_stopped): Define.
3323 (prepare_to_access_memory): Update.
3324
3325 Update the derived classes and callers below.
3326
3327 * server.cc (queue_stop_reply_callback): Update.
3328 * linux-low.cc (linux_target_ops): Update.
3329 (linux_process_target::supports_thread_stopped): Define.
3330 (linux_thread_stopped): Turn into ...
3331 (linux_process_target::thread_stopped): ... this.
3332 * linux-low.h (class linux_process_target): Update.
3333 * lynx-low.cc (lynx_target_ops): Update.
3334 * nto-low.cc (nto_target_ops): Update.
3335 * win32-low.cc (win32_target_ops): Update.
3336
770d8f6a
TBA
33372020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3338
3339 Turn process_stratum_target's read_pc and write_pc ops into
3340 methods of process_target.
3341
3342 * target.h (struct process_stratum_target): Remove the target ops.
3343 (class process_target): Add the target ops.
3344 * target.cc (process_target::read_pc): Define.
3345 (process_target::write_pc): Define.
3346
3347 Update the derived classes and callers below.
3348
3349 * regcache.cc (regcache_read_pc): Update.
3350 (regcache_write_pc): Update.
3351 * linux-low.cc (linux_target_ops): Update.
3352 (linux_read_pc): Turn into ...
3353 (linux_process_target::read_pc): ... this.
3354 (linux_write_pc): Turn into ...
3355 (linux_process_target::write_pc): ... this.
3356 * linux-low.h (class linux_process_target): Update.
3357 * lynx-low.cc (lynx_target_ops): Update.
3358 * nto-low.cc (nto_target_ops): Update.
3359 * win32-low.cc (win32_target_ops): Update.
3360
290732bf
TBA
33612020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3362
3363 Turn process_stratum_target's supports_tracepoints op into a
3364 method of process_target.
3365
3366 * target.h (struct process_stratum_target): Remove the target op.
3367 (class process_target): Add the target op.
3368 (target_supports_tracepoints): Update the macro.
3369 * target.cc (process_target::supports_tracepoints): Define.
3370
3371 Update the derived classes and callers below.
3372
3373 * linux-low.cc (linux_target_ops): Update.
3374 (linux_supports_tracepoints): Turn into ...
3375 (linux_process_target::supports_tracepoints): ... this.
3376 * linux-low.h (class linux_process_target): Update.
3377 * lynx-low.cc (lynx_target_ops): Update.
3378 * nto-low.cc (nto_target_ops): Update.
3379 * win32-low.cc (win32_target_ops): Update.
3380
0df28b1b
TBA
33812020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3382
3383 Turn process_stratum_target's process_qsupported op into a method
3384 of process_target.
3385
3386 * target.h (struct process_stratum_target): Remove the target op.
3387 (class process_target): Add the target op.
3388 (target_process_qsupported): Update the macro.
3389 * target.cc (process_target::process_qsupported): Define.
3390
3391 Update the derived classes and callers below.
3392
3393 * linux-low.cc (linux_target_ops): Update.
3394 (linux_process_qsupported): Turn into ...
3395 (linux_process_target::process_qsupported): ... this.
3396 * linux-low.h (class linux_process_target): Update.
3397 * lynx-low.cc (lynx_target_ops): Update.
3398 * nto-low.cc (nto_target_ops): Update.
3399 * win32-low.cc (win32_target_ops): Update.
3400
9da41fda
TBA
34012020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3402
3403 Turn process_stratum_target's read_loadmap op into a method of
3404 process_target.
3405
3406 * target.h (struct process_stratum_target): Remove the target op.
3407 (class process_target): Add the target op. Also add
3408 'supports_read_loadmap'.
3409 * target.cc (process_target::read_loadmap): Define.
3410 (process_target::supports_read_loadmap): Define.
3411
3412 Update the derived classes and callers below.
3413
3414 * server.cc (handle_qxfer_fdpic): Update.
3415 (handle_query): Update.
3416 * linux-low.cc (linux_target_ops): Update.
3417 (linux_process_target::supports_read_loadmap): Define.
3418 (linux_read_loadmap): Turn into ...
3419 (linux_process_target::read_loadmap): ... this.
3420 * linux-low.h (class linux_process_target): Update.
3421 * lynx-low.cc (lynx_target_ops): Update.
3422 * nto-low.cc (nto_target_ops): Update.
3423 * win32-low.cc (win32_target_ops): Update.
3424
95a45fc1
TBA
34252020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3426
3427 Turn process_stratum_target's core_of_thread op into a method of
3428 process_target.
3429
3430 * target.h (struct process_stratum_target): Remove the target op.
3431 (class process_target): Add the target op.
3432 (target_core_of_thread): Update the macro.
3433 * target.cc (process_target::core_of_thread): Define.
3434
3435 Update the derived classes and callers below.
3436
3437 * linux-low.cc (linux_target_ops): Update.
3438 (linux_process_target::core_of_thread): Define.
3439 * linux-low.h (class linux_process_target): Update.
3440 * lynx-low.cc (lynx_target_ops): Update.
3441 * nto-low.cc (nto_target_ops): Update.
3442 * win32-low.cc (win32_target_ops): Update.
3443
55cf3021
TBA
34442020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3445
3446 Turn process_stratum_target's handle_monitor_command op into a
3447 method of process_target.
3448
3449 * target.h (struct process_stratum_target): Remove the target op.
3450 (class process_target): Add the target op.
3451 (target_handle_monitor_command): Update the macro.
3452 * target.cc (process_target::handle_monitor_command): Define.
3453
3454 Update the derived classes and callers below.
3455
3456 * server.cc (handle_query): Update.
3457 * linux-low.cc (linux_target_ops): Update.
3458 (linux_process_target::handle_monitor_command): Define.
3459 * linux-low.h (class linux_process_target): Update.
3460 * lynx-low.cc (lynx_target_ops): Update.
3461 * nto-low.cc (nto_target_ops): Update.
3462 * win32-low.cc (win32_target_ops): Update.
3463
fb00dfce
TBA
34642020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3465
3466 Turn process_stratum_target's handle_new_gdb_connection op into a
3467 method of process_target.
3468
3469 * target.h (struct process_stratum_target): Remove the target op.
3470 (class process_target): Add the target op.
3471 (target_handle_new_gdb_connection): Update the macro.
3472 * target.cc (process_target::handle_new_gdb_connection): Define.
3473
3474 Update the derived classes and callers below.
3475
3476 * linux-low.cc (linux_target_ops): Update.
3477 (linux_handle_new_gdb_connection): Turn into ...
3478 (linux_process_target::handle_new_gdb_connection): ... this.
3479 * linux-low.h (class linux_process_target): Update.
3480 * lynx-low.cc (lynx_target_ops): Update.
3481 * nto-low.cc (nto_target_ops): Update.
3482 * win32-low.cc (win32_target_ops): Update.
3483
9690a72a
TBA
34842020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3485
3486 Turn process_stratum_target's supports_fork_events,
3487 supports_vfork_events, and supports_exec_events ops into methods
3488 of process_target.
3489
3490 * target.h (struct process_stratum_target): Remove the target ops.
3491 (class process_target): Add the target ops.
3492 (target_supports_fork_events): Update the macro.
3493 (target_supports_vfork_events): Update the macro.
3494 (target_supports_exec_events): Update the macro.
3495 * target.cc (process_target::supports_fork_events): Define.
3496 (process_target::supports_vfork_events): Define.
3497 (process_target::supports_exec_events): Define.
3498
3499 Update the derived classes and callers below.
3500
3501 * linux-low.cc (linux_target_ops): Update.
3502 (linux_supports_fork_events): Turn into ...
3503 (linux_process_target::supports_fork_events): ... this.
3504 (linux_supports_vfork_events): Turn into ...
3505 (linux_process_target::supports_vfork_events): ... this.
3506 (linux_supports_exec_events): Turn into ...
3507 (linux_process_target::supports_exec_events): ... this.
3508 * linux-low.h (class linux_process_target): Update.
3509 * lynx-low.cc (lynx_target_ops): Update.
3510 * nto-low.cc (nto_target_ops): Update.
3511 * win32-low.cc (win32_target_ops): Update.
3512
652aef77
TBA
35132020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3514
3515 Turn process_stratum_target's supports_multi_process op into a
3516 method of process_target.
3517
3518 * target.h (struct process_stratum_target): Remove the target op.
3519 (class process_target): Add the target op.
3520 * target.cc (process_target::supports_multi_process): Define.
3521 (target_supports_multi_process): Update.
3522
3523 Update the derived classes and callers below.
3524
3525 * linux-low.cc (linux_target_ops): Update.
3526 (linux_supports_multi_process): Turn into ...
3527 (linux_process_target::supports_multi_process): ... this.
3528 * linux-low.h (class linux_process_target): Update.
3529 * lynx-low.cc (lynx_target_ops): Update.
3530 * nto-low.cc (nto_target_ops): Update.
3531 * win32-low.cc (win32_target_ops): Update.
3532
0dc587d4
TBA
35332020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3534
3535 Turn process_stratum_target's supports_non_stop, async, and
3536 start_non_stop ops into methods of process_target.
3537
3538 * target.h (struct process_stratum_target): Remove the target ops.
3539 (class process_target): Add the target ops.
3540 (target_supports_non_stop): Update the macro.
3541 (target_async): Update the macro.
3542 (start_non_stop): Remove declaration.
3543 * target.cc (process_target::supports_non_stop): Define.
3544 (process_target::async): Define.
3545 (process_target::start_non_stop): Define.
3546 (start_non_stop): Remove.
3547
3548 Update the derived classes and callers below.
3549
3550 * server.cc (handle_qxfer_siginfo): Update.
3551 (handle_query): Update.
3552 * linux-low.cc (linux_target_ops): Update.
3553 (linux_supports_non_stop): Turn into ...
3554 (linux_process_target::supports_non_stop): ... this.
3555 (linux_async): Turn into ...
3556 (linux_process_target::async): ... this.
3557 (linux_start_non_stop): Turn into ...
3558 (linux_process_target::start_non_stop): ... this.
3559 * linux-low.h (class linux_process_target): Update.
3560 * lynx-low.cc (lynx_target_ops): Update.
3561 * nto-low.cc (nto_target_ops): Update.
3562 (nto_supports_non_stop): Remove; rely on the default behavior
3563 instead.
3564 * win32-low.cc (win32_target_ops): Update.
3565
d7abedf7
TBA
35662020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3567
3568 Turn process_stratum_target's qxfer_siginfo op into a method of
3569 process_target.
3570
3571 * target.h (struct process_stratum_target): Remove the target op.
3572 (class process_target): Add the target op. Also add
3573 'supports_qxfer_siginfo'.
3574 * target.cc (process_target::qxfer_siginfo): Define.
3575 (process_target::supports_qxfer_siginfo): Define.
3576
3577 Update the derived classes and callers below.
3578
3579 * server.cc (handle_qxfer_siginfo): Update.
3580 (handle_query): Update.
3581 * linux-low.cc (linux_target_ops): Update.
3582 (linux_process_target::supports_qxfer_siginfo): Define.
3583 (linux_xfer_siginfo): Turn into ...
3584 (linux_process_target::qxfer_siginfo): ... this.
3585 * linux-low.h (class linux_process_target): Update.
3586 * lynx-low.cc (lynx_target_ops): Update.
3587 * nto-low.cc (nto_target_ops): Update.
3588 * win32-low.cc (win32_target_ops): Update.
3589
2d0795ee
TBA
35902020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3591
3592 Turn process_stratum_target's qxfer_osdata op into a method of
3593 process_target.
3594
3595 * target.h (struct process_stratum_target): Remove the target op.
3596 (class process_target): Add the target op. Also add
3597 'supports_qxfer_osdata'.
3598 * target.cc (process_target::qxfer_osdata): Define.
3599 (process_target::supports_qxfer_osdata): Define.
3600
3601 Update the derived classes and callers below.
3602
3603 * server.cc (handle_qxfer_osdata): Update.
3604 (handle_query): Update.
3605 * linux-low.cc (linux_target_ops): Update.
3606 (linux_process_target::supports_qxfer_osdata): Define.
3607 (linux_qxfer_osdata): Turn into ...
3608 (linux_process_target::qxfer_osdata): ... this.
3609 * linux-low.h (class linux_process_target): Update.
3610 * lynx-low.cc (lynx_target_ops): Update.
3611 * nto-low.cc (nto_target_ops): Update.
3612 * win32-low.cc (win32_target_ops): Update.
3613
ea06bbaa
TBA
36142020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3615
3616 Turn process_stratum_target's hostio_last_error op into a
3617 method of process_target.
3618
3619 * target.h (struct process_stratum_target): Remove the target op.
3620 (class process_target): Add the target op.
3621 * target.cc: Add "hostio.h" to includes.
3622 (process_target::hostio_last_error): Define.
3623
3624 Update the derived classes and callers below.
3625
3626 * hostio.cc (hostio_error): Update.
3627 * linux-low.cc: Remove "hostio.h" from includes.
3628 (linux_target_ops): Update.
3629 * lynx-low.cc (lynx_target_ops): Update.
3630 * nto-low.cc (nto_target_ops): Update.
3631 * win32-low.h (class win32_process_target): Update.
3632 * win32-low.cc (win32_target_ops): Update.
3633 (wince_hostio_last_error): Turn into ...
3634 (win32_process_target::hostio_last_error): ... this.
3635
6e3fd7e9
TBA
36362020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3637
3638 Turn process_stratum_target's get_tls_address op into a method of
3639 process_target.
3640
3641 * target.h (struct process_stratum_target): Remove the target op.
3642 (class process_target): Add the target op. Also add
3643 'supports_get_tls_address'.
3644 * target.cc (process_target::get_tls_address): Define.
3645 (process_target::supports_get_tls_address): Define.
3646
3647 Update the derived classes and callers below.
3648
3649 * server.cc (handle_query): Update.
3650 * linux-low.cc (linux_target_ops): Update.
3651 (linux_process_target::supports_get_tls_address): Define.
3652 (linux_process_target::get_tls_address): Define.
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 * win32-low.cc (win32_target_ops): Update.
3657
5203ae1e
TBA
36582020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3659
3660 Turn process_stratum_target's read_offsets op into a method of
3661 process_target.
3662
3663 * target.h (struct process_stratum_target): Remove the target op.
3664 (class process_target): Add the target op. Also add
3665 'supports_read_offsets'.
3666 * target.cc (process_target::read_offsets): Define.
3667 (process_target::supports_read_offsets): Define.
3668
3669 Update the derived classes and callers below.
3670
3671 * server.cc (handle_query): Update.
3672 * linux-low.cc (SUPPORTS_READ_OFFSETS): New #define directive.
3673 (linux_target_ops): Update.
3674 (linux_process_target::supports_read_offsets): Define.
3675 (linux_read_offsets): Turn into ...
3676 (linux_process_target::read_offsets): ... this.
3677 * linux-low.h (class linux_process_target): Update.
3678 * lynx-low.cc (lynx_target_ops): Update.
3679 * nto-low.cc (nto_target_ops): Update.
3680 * win32-low.cc (win32_target_ops): Update.
3681
6eeb5c55
TBA
36822020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3683
3684 Turn process_stratum_target's stopped_by_watchpoint and
3685 stopped_data_address ops into methods of process_target.
3686
3687 * target.h (struct process_stratum_target): Remove the target ops.
3688 (class process_target): Add the target ops.
3689 * target.cc (process_target::stopped_by_watchpoint): Define.
3690 (process_target::stopped_data_address): Define.
3691
3692 Update the derived classes and callers below.
3693
3694 * remote-utils.cc (prepare_resume_reply): Update.
3695 * linux-low.cc (linux_target_ops): Update.
3696 (linux_stopped_by_watchpoint): Turn into ...
3697 (linux_process_target::stopped_by_watchpoint): ... this.
3698 (linux_stopped_data_address): Turn into ...
3699 (linux_process_target::stopped_data_address): ... this.
3700 * linux-low.h (class linux_process_target): Update.
3701 * lynx-low.cc (lynx_target_ops): Update.
3702 * nto-low.cc (nto_target_ops): Update.
3703 (nto_stopped_by_watchpoint): Turn into ...
3704 (nto_process_target::stopped_by_watchpoint): ... this.
3705 (nto_stopped_data_address): Turn into ...
3706 (nto_process_target::stopped_data_address): ... this.
3707 * nto-low.h (class nto_process_target): Update.
3708 * win32-low.cc (win32_target_ops): Update.
3709 (win32_stopped_by_watchpoint): Turn into ...
3710 (win32_process_target::stopped_by_watchpoint): ... this.
3711 (win32_stopped_data_address): Turn into ...
3712 (win32_process_target::stopped_data_address): ... this.
3713 * win32-low.h (class win32_process_target): Update.
3714
22aa6223
TBA
37152020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3716
3717 Turn process_stratum_target's supports_hardware_single_step op into
3718 a method of process_target.
3719
3720 * target.h (struct process_stratum_target): Remove the target op.
3721 (class process_target): Add the target op.
3722 (target_supports_hardware_single_step): Update the macro.
3723 (target_can_do_hardware_single_step): Remove declaration.
3724 * target.cc (process_target::supports_hardware_single_step): Define.
3725 (target_can_do_hardware_single_step): Remove.
3726
3727 Update the derived classes and callers below.
3728
3729 * linux-low.h (class linux_process_target): Update.
3730 * linux-low.cc (linux_target_ops): Update.
3731 (linux_supports_hardware_single_step): Turn into ...
3732 (linux_process_target::supports_hardware_single_step): ... this.
3733 * lynx-low.h (class lynx_process_target): Update.
3734 * lynx-low.cc (lynx_target_ops): Update.
3735 (lynx_process_target::supports_hardware_single_step): Define.
3736 * nto-low.h (class nto_process_target): Update.
3737 * nto-low.cc (nto_target_ops): Update.
3738 (nto_process_target::supports_hardware_single_step): Define.
3739 * win32-low.h (class win32_process_target): Update.
3740 * win32-low.cc (win32_target_ops): Update.
3741 (win32_process_target::supports_hardware_single_step): Define.
3742
93fe88b2
TBA
37432020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3744
3745 Turn process_stratum_target's {supports_}stopped_by_hw_breakpoint
3746 ops into methods of process_target.
3747
3748 * target.h (struct process_stratum_target): Remove the target ops.
3749 (class process_target): Add the target ops.
3750 (target_stopped_by_hw_breakpoint): Update the macro.
3751 (target_supports_stopped_by_hw_breakpoint): Update the macro.
3752 * target.cc (process_target::stopped_by_hw_breakpoint): Define.
3753 (process_target::supports_stopped_by_hw_breakpoint): Define.
3754
3755 Update the derived classes and callers below.
3756
3757 * linux-low.cc (linux_target_ops): Update.
3758 (linux_stopped_by_hw_breakpoint): Turn into ...
3759 (linux_process_target::stopped_by_hw_breakpoint): ... this.
3760 (linux_supports_stopped_by_hw_breakpoint): Turn into ...
3761 (linux_process_target::supports_stopped_by_hw_breakpoint): ... this.
3762 * linux-low.h (class linux_process_target): Update.
3763 * lynx-low.cc (lynx_target_ops): Update.
3764 * nto-low.cc (nto_target_ops): Update.
3765 * win32-low.cc (win32_target_ops): Update.
3766
84320c4e
TBA
37672020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3768
3769 Turn process_stratum_target's {supports_}stopped_by_sw_breakpoint
3770 ops into methods of process_target.
3771
3772 * target.h (struct process_stratum_target): Remove the target ops.
3773 (class process_target): Add the target ops.
3774 (target_stopped_by_sw_breakpoint): Update the macro.
3775 (target_supports_stopped_by_sw_breakpoint): Update the macro.
3776 * target.cc (process_target::stopped_by_sw_breakpoint): Define.
3777 (process_target::supports_stopped_by_sw_breakpoint): Define.
3778
3779 Update the derived classes and callers below.
3780
3781 * linux-low.cc (linux_target_ops): Update.
3782 (linux_stopped_by_sw_breakpoint): Turn into ...
3783 (linux_process_target::stopped_by_sw_breakpoint): ... this.
3784 (linux_supports_stopped_by_sw_breakpoint): Turn into ...
3785 (linux_process_target::supports_stopped_by_sw_breakpoint): ... this.
3786 * linux-low.h (class linux_process_target): Update.
3787 * lynx-low.cc (lynx_target_ops): Update.
3788 * nto-low.cc (nto_target_ops): Update.
3789 * win32-low.cc (win32_target_ops): Update.
3790
7e0bde70
TBA
37912020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3792
3793 Turn process_stratum_target's insert_point and remove_point ops
3794 into methods of process_target.
3795
3796 * target.h (struct process_stratum_target): Remove the target ops.
3797 (class process_target): Add the target ops.
3798 * target.cc (process_target::insert_point): Define.
3799 (process_target::remove_point): Define.
3800
3801 Update the derived classes and callers below.
3802
3803 * mem-break.cc (set_raw_breakpoint_at): Update.
3804 (delete_raw_breakpoint): Update.
3805 (uninsert_raw_breakpoint): Update.
3806 (reinsert_raw_breakpoint): Update.
3807 * linux-low.cc (linux_target_ops): Update.
3808 (linux_insert_point): Turn into ...
3809 (linux_process_target::insert_point): ... this.
3810 (linux_remove_point): Turn into ...
3811 (linux_process_target::remove_point): ... this.
3812 * linux-low.h (class linux_process_target): Update.
3813 * lynx-low.cc (lynx_target_ops): Update.
3814 * nto-low.cc (nto_target_ops): Update.
3815 (nto_insert_point): Turn into ...
3816 (nto_process_target::insert_point): ... this.
3817 (nto_remove_point): Turn into ...
3818 (nto_process_target::remove_point): ... this.
3819 * nto-low.h (class nto_process_target): Update.
3820 * win32-low.cc (win32_target_ops): Update.
3821 (win32_insert_point): Turn into ...
3822 (win32_process_target::insert_point): ... this.
3823 (win32_remove_point): Turn into ...
3824 (win32_process_target::remove_point): ... this.
3825 * win32-low.h (class win32_process_target): Update.
3826
a2b2297a
TBA
38272020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3828
3829 Turn process_stratum_target's supports_z_point_type op into a
3830 method of process_target.
3831
3832 * target.h (struct process_stratum_target): Remove the target op.
3833 (class process_target): Add the target op.
3834 * target.cc (process_target::supports_z_point_type): Define.
3835
3836 Update the derived classes and callers below.
3837
3838 * mem-break.cc (z_type_supported): Update.
3839 * linux-low.cc (linux_target_ops): Update.
3840 (linux_supports_z_point_type): Turn into ...
3841 (linux_process_target::supports_z_point_type): ... this.
3842 * linux-low.h (class linux_process_target): Update.
3843 * lynx-low.cc (lynx_target_ops): Update.
3844 * nto-low.cc (nto_target_ops): Update.
3845 (nto_supports_z_point_type): Turn into ...
3846 (nto_process_target::supports_z_point_type): ... this.
3847 * nto-low.h (class nto_process_target): Update.
3848 * win32-low.cc (win32_target_ops): Update.
3849 (win32_supports_z_point_type): Turn into ...
3850 (win32_process_target::supports_z_point_type): ... this.
3851 * win32-low.h (class win32_process_target): Update.
3852
eac215cc
TBA
38532020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3854
3855 Turn process_stratum_target's read_auxv op into a method of
3856 process_target.
3857
3858 * target.h (class process_stratum_target): Remove the target op.
3859 (struct process_target): Add the target op. Also add
3860 'supports_read_auxv'.
3861 * target.cc (process_target::read_auxv): Define.
3862 (process_target::supports_read_auxv): Define.
3863
3864 Update the derived classes and callers below.
3865
3866 * server.cc (handle_qxfer_auxv): Update.
3867 (handle_query): Update.
3868 * linux-low.cc (linux_target_ops): Update.
3869 (linux_process_target::supports_read_auxv): Define.
3870 (linux_read_auxv): Turn into ...
3871 (linux_process_target::read_auxv): ... this.
3872 * linux-low.h (class linux_process_target): Update.
3873 * lynx-low.cc (lynx_target_ops): Update.
3874 * nto-low.cc (nto_target_ops): Update.
3875 (nto_process_target::supports_read_auxv): Define.
3876 (nto_read_auxv): Turn into ...
3877 (nto_process_target::read_auxv): ... this.
3878 * nto-low.h (class nto_process_target): Update.
3879 * win32-low.cc (win32_target_ops): Update.
3880
eb497a2a
TBA
38812020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3882
3883 Turn process_stratum_target's request_interrupt op into a method of
3884 process_target.
3885
3886 * target.h (struct process_stratum_target): Remove the target op.
3887 (class process_target): Add the target op.
3888
3889 Update the derived classes and callers below.
3890
3891 * remote-utils.cc (putpkt_binary_1): Update.
3892 (input_interrupt): Update.
3893 (getpkt): Update.
3894 * server.cc (handle_v_requests): Update.
3895 * linux-low.cc (linux_target_ops): Update.
3896 (linux_request_interrupt): Turn into ...
3897 (linux_process_target::request_interrupt): ... this.
3898 * linux-low.h (class linux_process_target): Update.
3899 * lynx-low.cc (lynx_target_ops): Update.
3900 (lynx_request_interrupt): Turn into ...
3901 (lynx_process_target::request_interrupt): ... this.
3902 * lynx-low.h (class lynx_process_target): Update.
3903 * nto-low.cc (nto_target_ops): Update.
3904 (nto_request_interrupt): Turn into ...
3905 (nto_process_target::request_interrupt): ... this.
3906 * nto-low.h (class nto_process_target): Update.
3907 * win32-low.cc (win32_target_ops): Update.
3908 (win32_request_interrupt): Turn into ...
3909 (win32_process_target::request_interrupt): ... this.
3910 * win32-low.h (class win32_process_target): Update.
3911
2a31c7aa
TBA
39122020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3913
3914 Turn process_stratum_target's look_up_symbols op into a method of
3915 process_target.
3916
3917 * target.h (struct process_stratum_target): Remove the target op.
3918 (class process_target): Add the target op.
3919 * target.cc (process_target::look_up_symbols): Define.
3920
3921 Update the derived classes and callers below.
3922
3923 * server.cc (handle_query): Update.
3924 * linux-low.cc (linux_target_ops): Update.
3925 (linux_look_up_symbols): Turn into ...
3926 (linux_process_target::look_up_symbols): ... this.
3927 * linux-low.h (class linux_process_target): Update.
3928 * lynx-low.cc (lynx_target_ops): Update.
3929 * nto-low.cc (nto_target_ops): Update.
3930 * win32-low.cc (win32_target_ops): Update.
3931
e2558df3
TBA
39322020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3933
3934 Turn process_stratum_target's read_memory and write_memory
3935 ops into methods of process_target.
3936
3937 * target.h (struct process_stratum_target): Remove the target ops.
3938 (class process_target): Add the target ops.
3939
3940 Update the derived classes and callers below.
3941
3942 * linux-aarch32-low.cc (arm_breakpoint_at): Update.
3943 * linux-aarch64-low.cc (aarch64_breakpoint_at): Update.
3944 * linux-arm-low.cc (arm_sigreturn_next_pc): Update.
3945 (arm_get_syscall_trapinfo): Update.
3946 * linux-cris-low.cc (cris_breakpoint_at): Update.
3947 * linux-crisv32-low.cc (cris_breakpoint_at): Update.
3948 * linux-m32r-low.cc (m32r_breakpoint_at): Update.
3949 * linux-mips-low.cc (mips_breakpoint_at): Update.
3950 * linux-nios2-low.cc (nios2_breakpoint_at): Update.
3951 * linux-ppc-low.cc (ppc_breakpoint_at): Update.
3952 * linux-sh-low.cc (sh_breakpoint_at): Update.
3953 * linux-sparc-low.cc (sparc_fill_gregset_to_stack): Update.
3954 (sparc_store_gregset_from_stack): Update.
3955 (sparc_breakpoint_at): Update.
3956 * linux-tic6x-low.cc (tic6x_breakpoint_at): Update.
3957 * linux-tile-low.cc (tile_breakpoint_at): Update.
3958 * linux-x86-low.cc (x86_breakpoint_at): Update.
3959 * linux-xtensa-low.cc (xtensa_breakpoint_at): Update.
3960 * mem-brea.cc (insert_memory_breakpoint): Update.
3961 (validate_inserted_breakpoint): Update.
3962 * target.cc (read_inferior_memory): Update.
3963 (target_write_memory): Update.
3964 * linux-low.cc (linux_target_ops): Update.
3965 (linux_read_memory): Make a wrapper around the read_memory target
3966 op call.
3967 (linux_process_target::read_memory): Rename from linux_read_memory.
3968 (linux_write_memory): Turn into ...
3969 (linux_process_target::write_memory): ... this.
3970 * linux-low.h (class linux_process_target): Update.
3971 * lynx-low.cc (lynx_target_ops): Update.
3972 (lynx_read_memory): Turn into ...
3973 (lynx_process_target::read_memory): ... this.
3974 (lynx_write_memory): Turn into ...
3975 (lynx_process_target::write_memory): ... this.
3976 * lynx-low.h (class lynx_process_target): Update.
3977 * nto-low.cc (nto_target_ops): Update.
3978 (nto_read_memory): Turn into ...
3979 (nto_process_target::read_memory): ... this.
3980 (nto_write_memory): Turn into ...
3981 (nto_process_target::write_memory): ... this.
3982 * nto-low.h (class nto_process_target): Update.
3983 * win32-low.cc (win32_target_ops): Update.
3984 (win32_read_inferior_memory): Turn into ...
3985 (win32_process_target::read_memory): ... this.
3986 (win32_write_inferior_memory): Turn into ...
3987 (win32_process_target::write_memory): ... this.
3988 * win32-low.h (class win32_process_target): Update.
3989
79b44087
TBA
39902020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3991
3992 Turn process_stratum_target's prepare_to_access_memory and
3993 done_accessing_memory ops into methods of process_target.
3994
3995 * target.h (struct process_stratum_target): Remove the target ops.
3996 (class process_target): Add the target ops.
3997 * target.cc (process_target::prepare_to_access_memory): Define.
3998 (process_target::done_accessing_memory): Define.
3999 (prepare_to_access_memory): Update.
4000 (done_accessing_memory): Update.
4001
4002 Update the derived classes and callers below.
4003
4004 * linux-low.cc (linux_target_ops): Update.
4005 (linux_prepare_to_access_memory): Turn into ...
4006 (linux_process_target::prepare_to_access_memory): ... this.
4007 (linux_done_accessing_memory): Turn into ...
4008 (linux_process_target::done_accessing_memory): ... this.
4009 * linux-low.h (class linux_process_target): Update.
4010 * lynx-low.cc (lynx_target_ops): Update.
4011 * nto-low.cc (nto_target_ops): Update.
4012 * win32-low.cc (win32_target_ops): Update.
4013
a5a4d4cd
TBA
40142020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4015
4016 Turn process_stratum_target's fetch_registers and store_registers
4017 ops into methods of process_target.
4018
4019 * target.h (struct process_stratum_target): Remove the target ops.
4020 (class process_target): Add the target ops.
4021 (fetch_inferior_registers): Update the macro.
4022 (store_inferior_registers): Update the macro.
4023
4024 Update the derived classes and callers below.
4025
4026 * linux-low.cc (linux_target_ops): Update.
4027 (linux_fetch_registers): Turn into ...
4028 (linux_process_target::fetch_registers): ... this.
4029 (linux_store_registers): Turn into ...
4030 (linux_process_target::store_registers): ... this.
4031 * linux-low.h (class linux_process_target): Update.
4032 * lynx-low.cc (lynx_target_ops): Update.
4033 (lynx_fetch_registers): Turn into ...
4034 (lynx_process_target::fetch_registers): ... this.
4035 (lynx_store_registers): Turn into ...
4036 (lynx_process_target::store_registers): ... this.
4037 * lynx-low.h (class lynx_process_target): Update.
4038 * nto-low.cc (nto_target_ops): Update.
4039 (nto_fetch_registers): Turn into ...
4040 (nto_process_target::fetch_registers): ... this.
4041 (nto_store_registers): Turn into ...
4042 (nto_process_target::store_registers): ... this.
4043 * nto-low.h (class nto_process_target): Update.
4044 * win32-low.cc (win32_target_ops): Update.
4045 (win32_fetch_inferior_registers): Turn into ...
4046 (win32_process_target::fetch_registers): ... this.
4047 (win32_store_inferior_registers): Turn into ...
4048 (win32_process_target::store_registers): ... this.
4049 * win32-low.h (class win32_process_target): Update.
4050
6532e7e3
TBA
40512020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4052
4053 Turn process_stratum_target's wait op into a method of
4054 process_target.
4055
4056 * target.h (struct process_stratum_target): Remove the target op.
4057 (class process_target): Add the target op.
4058
4059 Update the derived classes and callers below.
4060
4061 * target.cc (target_wait): Update.
4062 * linux-low.cc (linux_target_ops): Update.
4063 (linux_wait): Turn into ...
4064 (linux_process_target::wait): ... this.
4065 * linux-low.h (class linux_process_target): Update.
4066 * lynx-low.cc (lynx_target_ops): Update.
4067 (lynx_wait): Turn into ...
4068 (lynx_process_target::wait): ... this.
4069 * lynx-low.h (class lynx_process_target): Update.
4070 * nto-low.cc (nto_target_ops): Update.
4071 (nto_wait): Turn into ...
4072 (nto_process_target::wait): ... this.
4073 * nto-low.h (class nto_process_target): Update.
4074 * win32-low.cc (win32_target_ops): Update.
4075 (win32_wait): Turn into ...
4076 (win32_process_target::wait): ... this.
4077 (do_initial_child_stuff): Update.
4078 * win32-low.h (class win32_process_target): Update.
4079
0e4d7e35
TBA
40802020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4081
4082 Turn process_stratum_target's resume op into a method of
4083 process_target.
4084
4085 * target.h (struct process_stratum_target): Remove the target op.
4086 (class process_target): Add the target op.
4087
4088 Update the derived classes and callers below.
4089
4090 * server.cc (resume): Update.
4091 * target.cc (target_stop_and_wait): Update.
4092 (target_continue_no_signal): Update.
4093 (target_continue): Update.
4094 * linux-low.cc (linux_target_ops): Update.
4095 (linux_resume): Turn into ...
4096 (linux_process_target::resume): ... this.
4097 * linux-low.h (class linux_process_target): Update.
4098 * lynx-low.cc (lynx_target_ops): Update.
4099 (lynx_resume): Turn into ...
4100 (lynx_process_target::resume): ... this.
4101 * lynx-low.h (class lynx_process_target): Update.
4102 * nto-low.cc (nto_target_ops): Update.
4103 (nto_resume): Turn into ...
4104 (nto_process_target::resume): ... this.
4105 * nto-low.h (class nto_process_target): Update.
4106 * win32-low.cc (win32_target_ops): Update.
4107 (win32_resume): Turn into ...
4108 (win32_process_target::resume): ... this.
4109 (win32_process_target::detach): Update.
4110 (do_initial_child_stuff): Update.
4111 * win32-low.h (class win32_process_target): Update.
4112
13d3d99b
TBA
41132020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4114
4115 Turn process_stratum_target's thread_alive op into a method of
4116 process_target.
4117
4118 * target.h (struct process_stratum_target): Remove the target op.
4119 (class process_target): Add the target op.
4120 (mythread_alive): Update the macro.
4121
4122 Update the derived classes and callers below.
4123
4124 * linux-low.cc (linux_target_ops): Update.
4125 (linux_thread_alive): Turn into ...
4126 (linux_process_target::thread_alive): ... this.
4127 (wait_for_sigstop): Update.
4128 * linux-low.h (class linux_process_target): Update.
4129 * lynx-low.cc (lynx_target_ops): Update.
4130 (lynx_thread_alive): Turn into ...
4131 (lynx_process_target::thread_alive): ... this.
4132 * lynx-low.h (class lynx_process_target): Update.
4133 * nto-low.cc (nto_target_ops): Update.
4134 (nto_thread_alive): Turn into ...
4135 (nto_process_target::thread_alive): ... this.
4136 * nto-low.h (class nto_process_target): Update.
4137 * win32-low.cc (win32_target_ops): Update.
4138 (win32_thread_alive): Turn into ...
4139 (win32_process_target::thread_alive): ... this.
4140 * win32-low.h (class win32_process_target): Update.
4141
95a49a39
TBA
41422020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4143
4144 Turn process_stratum_target's join op into a method of
4145 process_target.
4146
4147 * target.h (struct process_stratum_target): Remove the target op.
4148 (class process_target): Add the target op.
4149 (join_inferior): Update the macro.
4150
4151 Update the derived classes and callers below.
4152
4153 * linux-low.cc (linux_target_ops): Update.
4154 (linux_join): Turn into ...
4155 (linux_process_target::join): ... this.
4156 * linux-low.h (class linux_process_target): Update.
4157 * lynx-low.cc (lynx_target_ops): Update.
4158 (lynx_join): Turn into ...
4159 (lynx_process_target::join): ... this.
4160 * lynx-low.h (class lynx_process_target): Update.
4161 * nto-low.cc (nto_target_ops): Update.
4162 (nto_process_target::join): Define.
4163 * nto-low.h (class nto_process_target): Update.
4164 * win32-low.cc (win32_target_ops): Update.
4165 (win32_join): Turn into ...
4166 (win32_process_target::join): ... this.
4167 * win32-low.h (class win32_process_target): Update.
4168
8adb37b9
TBA
41692020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4170
4171 Turn process_stratum_target's mourn op into a method of
4172 process_target.
4173
4174 * target.h (struct process_stratum_target): Remove the target op.
4175 (class process_target): Add the target op.
4176
4177 Update the derived classes and callers below.
4178
4179 * target.cc (target_mourn_inferior): Update.
4180 * linux-low.cc (linux_target_ops): Update.
4181 (linux_mourn): Turn into ...
4182 (linux_process_target::mourn): ... this.
4183 (handle_extended_wait): Update.
4184 (linux_process_target::kill): Update.
4185 (linux_process_target::detach): Update.
4186 * linux-low.h (class linux_process_target): Update.
4187 * lynx-low.cc (lynx_target_ops): Update.
4188 (lynx_mourn): Turn into ...
4189 (lynx_process_target::mourn): ... this.
4190 * lynx-low.h (class lynx_process_target): Update.
4191 * nto-low.cc (nto_target_ops): Update.
4192 (nto_mourn): Turn into ...
4193 (nto_process_target::mourn): ... this.
4194 * nto-low.h (class nto_process_target): Update.
4195 * win32-low.cc (win32_target_ops): Update.
4196 (win32_mourn): Turn into ...
4197 (win32_process_target::mourn): ... this.
4198 * win32-low.h (class win32_process_target): Update.
4199
9061c9cf
TBA
42002020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4201
4202 Turn process_stratum_target's detach op into a method of
4203 process_target.
4204
4205 * target.h (struct process_stratum_target): Remove the target op.
4206 (class process_target): Add the target op.
4207 (detach_inferior): Update the macro.
4208
4209 Update the derived classes and callers below.
4210
4211 * linux-low.cc (linux_target_ops): Update.
4212 (linux_detach): Turn into ...
4213 (linux_process_target::detach): ... this.
4214 * linux-low.h (class linux_process_target): Update.
4215 * lynx-low.cc (lynx_target_ops): Update.
4216 (lynx_detach): Turn into ...
4217 (lynx_process_target::detach): ... this.
4218 * lynx-low.h (class lynx_process_target): Update.
4219 * nto-low.cc (nto_target_ops): Update.
4220 (nto_detach): Turn into ...
4221 (nto_process_target::detach): ... this.
4222 * nto-low.h (class nto_process_target): Update.
4223 * win32-low.cc (win32_target_ops): Update.
4224 (win32_detach): Turn into ...
4225 (win32_process_target::detach): ... this.
4226 * win32-low.h (class win32_process_target): Update.
4227
c6885a57
TBA
42282020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4229
4230 Turn process_stratum_target's kill op into a method of
4231 process_target.
4232
4233 * target.h (struct process_stratum_target): Remove the target op.
4234 (class process_target): Add the target op.
4235
4236 Update the derived classes and callers below.
4237
4238 * target.cc (kill_inferior): Update.
4239 * linux-low.cc (linux_target_ops): Update.
4240 (linux_kill): Turn into ...
4241 (linux_process_target::kill): ... this.
4242 * linux-low.h (class linux_process_target): Update.
4243 * lynx-low.cc (lynx_target_ops): Update.
4244 (lynx_kill): Turn into ...
4245 (lynx_process_target::kill): ... this.
4246 * lynx-low.h (class lynx_process_target): Update.
4247 * nto-low.cc (nto_target_ops): Update.
4248 (nto_kill): Turn into ...
4249 (nto_process_target::kill): ... this.
4250 * nto-low.h (class nto_process_target): Update.
4251 * win32-low.cc (win32_target_ops): Update.
4252 (win32_kill): Turn into ...
4253 (win32_process_target::kill): ... this.
4254 * win32-low.h (class win32_process_target): Update.
4255
ef03dad8
TBA
42562020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4257
4258 Turn process_stratum_target's attach op into a method of
4259 process_target.
4260
4261 * target.h (struct process_stratum_target): Remove the target op.
4262 (class process_target): Add the target op.
4263 (myattach): Update the macro.
4264
4265 Update the derived classes and callers below.
4266
4267 * linux-low.cc (linux_target_ops): Update.
4268 (linux_attach): Turn into ...
4269 (linux_process_target::attach): ... this.
4270 * linux-low.h (class linux_process_target): Update.
4271 * lynx-low.cc (lynx_target_ops): Update.
4272 (lynx_attach): Turn into ...
4273 (lynx_process_target::attach): ... this.
4274 * lynx-low.h (class lynx_process_target): Update.
4275 * nto-low.cc (nto_target_ops): Update.
4276 (nto_attach): Turn into ...
4277 (nto_process_target::attach): ... this.
4278 * nto-low.h (class nto_process_target): Update.
4279 * win32-low.cc (win32_target_ops): Update.
4280 (win32_attach): Turn into ...
4281 (win32_process_target::attach): ... this.
4282 * win32-low.h (class win32_process_target): Update.
4283
6dee9afb
TBA
42842020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4285
4286 Turn process_stratum_target's post_create_inferior op into a method
4287 of process_target.
4288
4289 * target.h (struct process_stratum_target): Remove the target op.
4290 (class process_target): Add the target op.
4291 (target_post_create_inferior): Update the macro.
4292 * target.cc (process_target::post_create_inferior): Define.
4293
4294 Update the derived classes and callers below.
4295
4296 * linux-low.cc (linux_target_ops): Update.
4297 (linux_post_create_inferior): Turn into ...
4298 (linux_process_target::post_create_inferior): ... this.
4299 * linux-low.h (class linux_process_target): Update.
4300 * lynx-low.cc (lynx_target_ops): Update.
4301 * nto-low.cc (nto_target_ops): Update.
4302 * win32-low.cc (win32_target_ops): Update.
4303
15295543
TBA
43042020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4305
4306 Turn process_stratum_target's create_inferior op into a method of
4307 process_target.
4308
4309 * target.h (struct process_stratum_target): Remove the target op.
4310 (class process_target): Add the target op.
4311 (create_inferior): Rename the macro to ...
4312 (target_create_inferior): ... this.
4313
4314 Update the derived classes and callers below.
4315
4316 * server.cc (handle_v_run): Update.
4317 (captured_main): Update.
4318 (process_serial_event): Update.
4319 * linux-low.cc (linux_target_ops): Update.
4320 (linux_create_inferior): Turn into ...
4321 (linux_process_target::create_inferior): ... this.
4322 * linux-low.h (class linux_process_target): Update.
4323 * lynx-low.cc (lynx_target_ops): Update.
4324 (lynx_create_inferior): Turn into ...
4325 (lynx_process_target::create_inferior): ... this.
4326 * lynx-low.h (class lynx_process_target): Update.
4327 * nto-low.cc (nto_target_ops): Update.
4328 (nto_create_inferior): Turn into ...
4329 (nto_process_target::create_inferior): ... this.
4330 * nto-low.h (class nto_process_target): Update.
4331 * win32-low.cc (win32_target_ops): Update.
4332 (win32_create_inferior): Turn into ...
4333 (win32_process_target::create_inferior): ... this.
4334 * win32-low.h (class win32_process_target): Update.
4335
5ef9273d
TBA
43362020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4337
4338 * target.h (class process_target): New class definition.
4339 (struct process_stratum_target) <pt>: New field with type
4340 'process_target*'.
4341 * linux-low.h (class linux_process_target): Define as a derived
4342 class of 'process_target'.
4343 * linux-low.cc (linux_target_ops): Add a linux_process_target*
4344 as the 'pt' field.
4345 * lynx-low.h (class lynx_process_target): Define as a derived
4346 class of 'process_target'.
4347 * lynx-low.cc (lynx_target_ops): Add a lynx_process_target*
4348 as the 'pt' field.
4349 * nto-low.h (class nto_process_target): Define as a derived
4350 class of 'process_target'.
4351 * nto-low.cc (nto_target_ops): Add an nto_process_target*
4352 as the 'pt' field.
4353 * win32-low.h (class win32_process_target): Define as a derived
4354 class of 'process_target'.
4355 * win32-low.cc (win32_target_ops): Add a win32_process_target*
4356 as the 'pt' field.
4357
9f1528a1
AB
43582020-02-19 Andrew Burgess <andrew.burgess@embecosm.com>
4359
4360 * configure: Regenerate.
4361
bf84f706
MR
43622020-02-19 Maciej W. Rozycki <macro@wdc.com>
4363 Andrew Burgess <andrew.burgess@embecosm.com>
4364
4365 * linux-riscv-low.cc: New file.
4366 * Makefile.in (SFILES): Add linux-riscv-low.cc, arch/riscv.c,
4367 and nat/riscv-linux-tdesc.c.
4368 * configure.srv <riscv*-*-linux*> (srv_tgtobj)
4369 (srv_linux_regsets, srv_linux_usrregs, srv_linux_thread_db):
4370 Define.
4371
1a627e7e
TT
43722020-02-14 Tom Tromey <tom@tromey.com>
4373
4374 * acinclude.m4: Don't include acx_configure_dir.m4.
4375 * Makefile.in (LIBIBERTY_BUILDDIR, GNULIB_BUILDDIR): Update.
4376 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): Remove.
4377 (all, install-only, uninstall, clean-info, clean)
4378 (maintainer-clean): Don't recurse.
4379 (subdir_do, all-lib): Remove.
4380 ($(LIBGNU) $(LIBIBERTY) $(GNULIB_H)): Remove rule.
4381 (GNULIB_H): Remove.
4382 (generated_files): Update.
4383 ($(GNULIB_BUILDDIR)/Makefile): Remove rule.
4384 * configure: Rebuild.
4385 * configure.ac: Don't configure gnulib or libiberty.
4386 (GNULIB): Update.
4387
a9b34532
EZ
43882020-02-14 Eli Zaretskii <eliz@gnu.org>
4389
4390 * win32-low.c (create_process): Prepend PROGRAM to ARGS when
4391 preparing the command line for CreateProcess.
4392 (win32_create_inferior): Reflect the program name in debugging
4393 output that shows the process and its command line.
4394
feacfcac
SM
43952020-02-13 Simon Marchi <simon.marchi@efficios.com>
4396
4397 * Makefile.in: Rename source files from .c to .cc.
4398 * %.c: Rename to %.cc.
4399 * configure.ac: Rename server.c to server.cc.
4400 * configure: Re-generate.
4401
06b3c5bd
SM
44022020-02-13 Simon Marchi <simon.marchi@efficios.com>
4403
4404 * Makefile.in: Rename gdbsupport source files from .c to .cc.
4405
052793ad
HD
44062020-02-12 Hannes Domani <ssbssa@yahoo.de>
4407
4408 * win32-low.c (win32_create_inferior): Set signal_pid.
4409
f20e3e82
MR
44102020-02-12 Maciej W. Rozycki <macro@wdc.com>
4411 Pedro Alves <palves@redhat.com>
4412
4413 Skip building gdbserver in a cross-configuration.
4414 * configure.srv: Set $gdbserver_host depending on whether $target
4415 is $host. Use $gdbserver_host instead of $host.
4416
8ddd8e0e
SM
44172020-02-11 Simon Marchi <simon.marchi@efficios.com>
4418
4419 * configure: Re-generate.
4420
898e7f60
SM
44212020-02-11 Simon Marchi <simon.marchi@efficios.com>
4422
4423 * configure: Re-generate.
4424
58df732b
SM
44252020-02-11 Simon Marchi <simon.marchi@efficios.com>
4426
4427 * acinclude.m4: Update warning.m4 path.
4428
7928d571
HD
44292020-02-09 Hannes Domani <ssbssa@yahoo.de>
4430
4431 * win32-low.c (win32_clear_inferiors): Reset siginfo_er.
4432 (handle_exception): Set siginfo_er.
4433 (win32_xfer_siginfo): New function.
4434
919adfe8
TT
44352020-02-07 Tom Tromey <tom@tromey.com>
4436 Pedro Alves <palves@redhat.com>
4437
4438 * README: Update build documentation.
4439 * configure.srv: Set UNSUPPORTED if host is unsupported. Check
4440 host, not target.
4441 * configure.ac: Update paths.
4442 * configure: Rebuild.
4443 * acinclude.m4: Update paths.
4444 * Makefile.in: Update include paths.
4445 (depcomp, INCLUDE_DIR, INCGNU, INCSUPPORT, INCLUDE_CFLAGS)
4446 (SFILES, XML_DIR, n, $(GNULIB_BUILDDIR)/Makefile, config.status)
4447 (version-generated.c, stamp-xml, regdat_sh, arch/%-ipa.o)
4448 (gdbsupport/%-ipa.o, %-ipa.o, arch/%.o, gdbsupport/%.o, %.o)
4449 (%-generated.c): Update paths.
4450 * Move entire directory from ../gdb/gdbserver.
4451
287c844a
MR
44522020-01-29 Maciej W. Rozycki <macro@wdc.com>
4453
4454 * configure.srv <i[34567]86-*-mingw*>: Fix whitespace damage.
4455
548a204f
PFC
44562020-01-29 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4457
4458 * configure.srv (powerpc*-*-linux*): Use srv_tgtobj in second
4459 assignment instead of srv_linux_obj.
4460
a2236a08
HD
44612020-01-28 Hannes Domani <ssbssa@yahoo.de>
4462
4463 * server.c (handle_qxfer_libraries): Write segment-address with
4464 paddress.
4465
bdaed379
HD
44662020-01-24 Hannes Domani <ssbssa@yahoo.de>
4467
4468 * Makefile.in (install-strip): New target.
4469 (install_sh, INSTALL_STRIP_PROGRAM, STRIP): New variables.
4470 * aclocal.m4: Regenerate.
4471 * configure: Regenerate.
4472 * configure.ac: Add AM_PROG_INSTALL_STRIP.
4473
42cd72aa
MR
44742020-01-24 Maciej W. Rozycki <macro@wdc.com>
4475
4476 * Makefile.in (SFILES): Adjust paths to point to real files.
4477 (OBS): Move waitstatus.o to target/waitstatus.o.
4478 (TAGS): Transform paths appropriately.
4479 (%.o): Rename to...
4480 (nat/%.o): ... this pattern rule.
4481 (%.o): Rename to...
4482 (target/%.o): ... this pattern rule.
4483 * configure.srv: Adjust paths throughout to include nat/ prefix
4484 with the revant files.
4485 * configure.ac: Add `nat' and `target' to CONFIG_SRC_SUBDIR.
4486 * configure: Regenerate.
4487
42ba50ec
MR
44882020-01-24 Maciej W. Rozycki <macro@wdc.com>
4489
4490 * Makefile.in (TAGS): Remove config files from the recipe.
4491
05ea2a05
TT
44922020-01-14 Tom Tromey <tom@tromey.com>
4493
4494 * configure: Rebuild.
4495 * configure.ac: Remove any checks that were added to common.m4.
4496 * acinclude.m4: Include lib-ld.m4, lib-prefix.m4, and
4497 lib-link.m4.
4498
01027315
TT
44992020-01-14 Tom Tromey <tom@tromey.com>
4500
4501 * server.h: Include config.h.
4502 * gdbreplay.c: Include config.h.
4503 * configure: Rebuild.
4504 * configure.ac: Don't source common.host.
4505 * acinclude.m4: Update path.
4506 * Makefile.in (INCSUPPORT): New variable.
4507 (INCLUDE_CFLAGS): Add INCSUPPORT.
4508 (SFILES): Update paths.
4509 (version-generated.c): Update path to create-version.sh.
4510 (gdbsupport/%-ipa.o, gdbsupport/%.o): Update paths.
4511
b2ceabe8
TT
45122020-01-14 Tom Tromey <tom@tromey.com>
4513
4514 * configure.ac (LIBS): Use WIN32APILIBS.
4515 (USE_WIN32API): Don't define.
4516 * configure: Rebuild.
4517
25c51f71
TT
45182020-01-14 Tom Tromey <tom@tromey.com>
4519
4520 * configure: Rebuild.
4521
c0bd321d
SM
45222020-01-13 Simon Marchi <simon.marchi@efficios.com>
4523
4524 * Makefile.in (%-generated.c): Remove rule for files from
4525 regformats/i386.
4526
bb564c58
SM
45272020-01-13 Simon Marchi <simon.marchi@efficios.com>
4528
4529 * configure: Re-generate.
4530
6e37c371
SM
45312020-01-13 Simon Marchi <simon.marchi@efficios.com>
4532
4533 * tracepoint.h (IP_AGENT_EXPORT_FUNC) [!IN_PROCESS_AGENT]:
4534 Define to static.
4535 * tracepoint.c (stop_tracing, flush_trace_buffer,
4536 about_to_request_buffer_space, get_trace_state_variable_value,
4537 set_trace_state_variable_value, gdb_collect): Add declaration.
4538
df4a0200
SM
45392020-01-13 Simon Marchi <simon.marchi@efficios.com>
4540
4541 * linux-x86-low.c (x86_linux_regs_info, amd64_emit_eq_goto,
4542 amd64_emit_ne_goto, amd64_emit_lt_goto, amd64_emit_le_goto,
4543 amd64_emit_gt_goto, amd64_emit_ge_goto, amd64_emit_ge_goto,
4544 i386_emit_eq_goto, i386_emit_ne_goto, i386_emit_lt_goto,
4545 i386_emit_le_goto, i386_emit_gt_goto, i386_emit_ge_goto): Make
4546 static.
4547
89e94ec9
SM
45482020-01-13 Simon Marchi <simon.marchi@efficios.com>
4549
4550 * inferiors.c: Include gdbsupport/common-inferior.h.
4551
2552728a
SM
45522020-01-13 Simon Marchi <simon.marchi@efficios.com>
4553
4554 * hostio-errno.c: Include hostio.h.
4555
4025fa09
SM
45562020-01-13 Simon Marchi <simon.marchi@efficios.com>
4557
4558 * Makefile.in (%-generated.c): Make $(regdat_sh) a regular
4559 prerequisite.
4560
c0b0a142
SM
45612020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
4562
4563 * linux-arm-tdesc.c: Include linux-arm-tdesc.h.
4564 * linux-arm-tdesc.h: Include arch/arm.h.
4565
bb1183e2
SM
45662020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
4567
4568 * linux-aarch64-low.c (aarch64_write_goto_address): Make static.
4569
f5df0b5f
SM
45702020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
4571
4572 * linux-aarch32-tdesc.c: Include linux-aarch32-tdesc.h.
4573 * linux-aarch64-tdesc.c: Include linux-aarch64-tdesc.h.
4574
5b6d1e4f
PA
45752020-01-10 Pedro Alves <palves@redhat.com>
4576
4577 * fork-child.c (post_fork_inferior): Pass target down to
4578 startup_inferior.
4579 * inferiors.c (switch_to_thread): Add process_stratum_target
4580 parameter.
4581 * lynx-low.c (lynx_target_ops): Now a process_stratum_target.
4582 * nto-low.c (nto_target_ops): Now a process_stratum_target.
4583 * linux-low.c (linux_target_ops): Now a process_stratum_target.
4584 * remote-utils.c (prepare_resume_reply): Pass the target to
4585 switch_to_thread.
4586 * target.c (the_target): Now a process_stratum_target.
4587 (done_accessing_memory): Pass the target to switch_to_thread.
4588 (set_target_ops): Ajust to use process_stratum_target.
4589 * target.h (struct target_ops): Rename to ...
4590 (struct process_stratum_target): ... this.
4591 (the_target, set_target_ops): Adjust.
4592 (prepare_to_access_memory): Adjust comment.
4593 * win32-low.c (child_xfer_memory): Adjust to use
4594 process_stratum_target.
4595 (win32_target_ops): Now a process_stratum_target.
4596
559e7e50
EZ
45972020-01-06 Eli Zaretskii <eliz@gnu.org>
4598 Pedro Alves <palves@redhat.com>
4599
4600 * win32-low.c (get_child_debug_event): Extract the fatal exception
4601 from the exit status and convert to the equivalent Posix signal
4602 number.
4603 (win32_wait): Allow TARGET_WAITKIND_SIGNALLED status as well.
4604 * Makefile.in (OBS, SFILES): Add gdb_wait.[co].
4605
48189bec
HD
46062020-01-01 Hannes Domani <ssbssa@yahoo.de>
4607
4608 * Makefile.in: Use INSTALL_PROGRAM_ENV.
4609
5dd8bf88
JB
46102020-01-01 Joel Brobecker <brobecker@adacore.com>
4611
4612 * server.c (gdbserver_version): Change copyright year to 2020.
4613 * gdbreplay.c (gdbreplay_version): Likewise.
4614
0ad6b8ee
CB
46152019-12-19 Christian Biesinger <cbiesinger@google.com>
4616
4617 * configure: Regenerate.
4618 * configure.ac: Quote variable arguments of test.
4619
1ee7b812
BE
46202019-12-16 Bernd Edlinger <bernd.edlinger@hotmail.de>
4621
4622 * Makefile.in: Fix build with GNU Make 3.81
4623
d9fa87f4
TT
46242019-12-16 Tom Tromey <tromey@adacore.com>
4625
4626 * server.c (get_exec_file): Constify result.
4627
ab7d13f0
CB
46282019-12-10 Christian Biesinger <cbiesinger@google.com>
4629
4630 * Makefile.in: Add safe-strerror.c to gdbreplay and IPA, and change
4631 UNDO_GNULIB_CFLAGS to undo strerror_r instead of strerror.
4632 * config.in: Regenerate.
4633 * configure: Regenerate.
4634 * configure.ac: Don't check for strerror.
4635 * linux-i386-ipa.c (initialize_fast_tracepoint_trampoline_buffer):
4636 Call safe_strerror instead of strerror.
4637 * server.h (strerror): Remove this now-unnecessary declaration.
4638 * tracepoint.c (init_named_socket): Call safe_strerror instead of
4639 strerror.
4640 (gdb_agent_helper_thread): Likewise.
4641 * utils.c (perror_with_name): Likewise.
4642
4da8c3a8
TT
46432019-11-26 Tom Tromey <tom@tromey.com>
4644
4645 * configure, config.in: Rebuild.
4646
21987b9c
TT
46472019-11-26 Tom Tromey <tom@tromey.com>
4648
4649 * remote-utils.c (block_unblock_async_io): Use gdb_sigmask.
4650 * linux-low.c (linux_wait_for_event_filtered, linux_async): Use
4651 gdb_sigmask.
4652 * configure, config.in: Rebuild.
4653
5e030278
TT
46542019-11-26 Tom Tromey <tom@tromey.com>
4655
4656 * Makefile.in (PTHREAD_CFLAGS, PTHREAD_LIBS): New variables.
4657 (INTERNAL_CFLAGS_BASE): Use PTHREAD_CFLAGS.
4658 (GDBSERVER_LIBS): Use PTHREAD_LIBS.
4659 * acinclude.m4: Include ax_pthread.m4.
4660 * config.in, configure: Rebuild.
4661
6d91ce9a
CB
46622019-11-26 Christian Biesinger <cbiesinger@google.com>
4663
4664 * debug.c (debug_set_output): Call safe_strerror instead of
4665 strerror.
4666 * linux-low.c (attach_proc_task_lwp_callback): Likewise.
4667 (linux_kill_one_lwp): Likewise.
4668 (linux_detach_one_lwp): Likewise.
4669 (linux_wait_for_event_filtered): Likewise.
4670 (store_register): Likewise.
4671 * lynx-low.c (lynx_attach): Likewise.
4672 * mem-break.c (insert_memory_breakpoint): Likewise.
4673 (remove_memory_breakpoint): Likewise.
4674 (delete_fast_tracepoint_jump): Likewise.
4675 (set_fast_tracepoint_jump): Likewise.
4676 (uninsert_fast_tracepoint_jumps_at): Likewise.
4677 (reinsert_fast_tracepoint_jumps_at): Likewise.
4678 * nto-low.c (nto_xfer_memory): Likewise.
4679 (nto_resume): Likewise.
4680
6cdd651f
LM
46812019-11-20 Luis Machado <luis.machado@linaro.org>
4682
4683 * linux-aarch64-low.c (is_sve_tdesc): Check against target feature
4684 instead of register count.
4685 * tdesc.c (tdesc_contains_feature): New function.
4686 * tdesc.h (tdesc_contains_feature): New prototype.
4687
cd850b40
CB
46882019-11-15 Christian Biesinger <cbiesinger@google.com>
4689
4690 * Makefile.in: Add safe-strerror.c.
4691 * configure: Regenerate.
4692 * configure.ac: Don't source common.host.
4693
5abebf3c
CB
46942019-11-15 Christian Biesinger <cbiesinger@google.com>
4695
4696 * config.in: Regenerate.
4697 * configure: Regenerate.
4698
e06f3d6e
AB
46992019-11-12 Andrew Burgess <andrew.burgess@embecosm.com>
4700
4701 * ax.c (ax_printf): Handle size_t_arg.
4702
ca3a04f6
CB
47032019-11-06 Christian Biesinger <cbiesinger@google.com>
4704
4705 * linux-tdep.c (linux_info_proc): Use strtok_r instead of strtok.
4706 * mi/mi-main.c (output_cores): Likewise.
4707 * nat/linux-osdata.c (linux_xfer_osdata_cpus): Likewise.
4708 (linux_xfer_osdata_modules): Likewise.
4709 * remote.c (register_remote_support_xml): Likewise.
4710 * sparc64-tdep.c (adi_is_addr_mapped): Likewise.
4711 * xml-syscall.c (syscall_create_syscall_desc): Likewise.
4712
e48f6033
CB
47132019-11-01 Christian Biesinger <cbiesinger@google.com>
4714
4715 * configure: Regenerate.
4716 * configure.ac: Remove check for strerror_r.
4717
e7e97a2e
CB
47182019-10-31 Christian Biesinger <cbiesinger@google.com>
4719
4720 * config.in: Regenerate.
4721 * configure: Regenerate.
4722 * configure.ac: Also check for strerror_r.
4723
75cafaa6
CB
47242019-10-31 Christian Biesinger <cbiesinger@google.com>
4725
4726 * ax.h (debug_agent): Remove duplicate declaration.
4727
30baf67b
TV
47282019-10-26 Tom de Vries <tdevries@suse.de>
4729
4730 * linux-aarch64-low.c: Fix typos in comments.
4731 * linux-arm-low.c: Same.
4732 * linux-low.c: Same.
4733 * linux-ppc-low.c: Same.
4734 * proc-service.c: Same.
4735 * regcache.h: Same.
4736 * server.c: Same.
4737 * tracepoint.c: Same.
4738 * win32-low.c: Same.
4739
52c64cf7
TT
47402019-10-25 Tom Tromey <tromey@adacore.com>
4741
4742 * utils.c (xstrdup): Remove.
4743
c12d372d
TT
47442019-10-23 Tom Tromey <tom@tromey.com>
4745
4746 * configure, config.in: Rebuild.
4747
4d0b984b
TT
47482019-10-23 Tom Tromey <tom@tromey.com>
4749
4750 * configure: Rebuild.
4751 * acinclude.m4: Use m4_include, not sinclude.
4752
c5adaa19
TT
47532019-10-17 Tom Tromey <tromey@adacore.com>
4754
4755 * configure: Rebuild.
4756 * configure.ac: Use AC_CONFIG_HEADERS. Create stamp-h there, not
4757 in AC_CONFIG_FILES invocation.
4758 * Makefile.in (stamp-h, Makefile): Use new-style config.status
4759 invocation.
4760
fec4e896
CB
47612019-10-16 Christian Biesinger <cbiesinger@google.com>
4762
4763 * server.c: Include xml-builtin.h.
4764 (get_xml_features): Don't declare xml_builtins here.
4765
00975ff6
AB
47662019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
4767
4768 * Makefile.in: Remove references to vec-ipa.o.
4769
0dc32745
AB
47702019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
4771
4772 * Makefile.in: Remove references to vec.c.
4773
3e6ec53a
CB
47742019-10-02 Christian Biesinger <cbiesinger@google.com>
4775
4776 * server.c (server_waiting): Change to bool.
4777 (extended_protocol): Likewise.
4778 (response_needed): Likewise.
4779 (exit_requested): Likewise.
4780 (run_once): Likewise.
4781 (report_no_resumed): Likewise.
4782 (non_stop): Likewise.
4783 (disable_packet_vCont): Likewise.
4784 (disable_packet_Tthread): Likewise.
4785 (disable_packet_qC): Likewise.
4786 (disable_packet_qfThreadInfo): Likewise.
4787 (handle_general_set): Update.
4788 (handle_detach): Update.
4789 (handle_monitor_command): Update.
4790 (handle_query): Update.
4791 (captured_main): Update.
4792 (process_serial_event): Update.
4793 * server.h (server_waiting): Change to bool.
4794 (disable_packet_vCont): Likewise.
4795 (disable_packet_Tthread): Likewise.
4796 (disable_packet_qC): Likewise.
4797 (disable_packet_qfThreadInfo): Likewise.
4798 (run_once): Likewise.
4799 (non_stop): Likewise.
4800 * target.c (target_stop_and_wait): Update.
4801
80fd2826
TT
48022019-10-02 Tom Tromey <tromey@adacore.com>
4803
4804 * Makefile.in (SFILES): Add common-inferior.c.
4805 (OBS): Add common-inferior.o.
4806 * server.c (startup_with_shell): Don't define.
4807
46f29a9a
AB
48082019-10-02 Andrew Burgess <andrew.burgess@embecosm.com>
4809
4810 * linux-low.c (linux_low_read_btrace): Update for change to
4811 std::vector.
4812
f9d949fb
CB
48132019-09-20 Christian Biesinger <cbiesinger@google.com>
4814
4815 * debug.c (debug_threads): Remove comment in favor of the header.
4816 * debug.h (using_threads): Add declaration.
4817 (debug_threads): Add comment.
4818 * linux-aarch64-low.c: Include debug.h and remove declaration of
4819 debug_threads.
4820 * nto-low.c: Likewise.
4821 * remote-utils.c: Likewise.
4822 * thread-db.c: Likewise.
4823
abf516c6
UW
48242019-09-20 Ulrich Weigand <uweigand@de.ibm.com>
4825
4826 * configure.srv (ipa_ppc_linux_regobj): Remove powerpc-cell32l-ipa.o
4827 and powerpc-cell64l-ipa.o.
4828 (powerpc*-*-linux*): Remove powerpc-cell32l.o and powerpc-cell64l.o
4829 from srv_regobj. Remove rs6000/powerpc-cell32l.xml and
4830 rs6000/powerpc-cell64l.xml from srv_xmlfiles.
4831 (spu*-*-*): Remove.
4832
4833 * spu-low.c: Remove file.
4834
4835 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Remove.
4836 (parse_spufs_run): Remove.
4837 (ppc_get_pc): Remove Cell/B.E. support.
4838 (ppc_set_pc): Likewise.
4839 (ppc_breakpoint_at): Likewise.
4840 (ppc_arch_setup): Likewise.
4841 (ppc_get_ipa_tdesc_idx): Do not handle tdesc_powerpc_cell64l or
4842 tdesc_powerpc_cell32l.
4843 (initialize_low_arch): Do not call init_registers_powerpc_cell64l
4844 or init_registers_powerpc_cell32l.
4845 * linux-ppc-ipa.c (get_ipa_tdesc): Do not handle PPC_TDESC_CELL.
4846 (initialize_low_tracepoint): Do not call init_registers_powerpc_cell64l
4847 or init_registers_powerpc_cell32l.
4848 * linux-ppc-tdesc-init.h (PPC_TDESC_CELL): Mark as unused.
4849 (init_registers_powerpc_cell32l): Remove prototype.
4850 (init_registers_powerpc_cell64l): Likewise.
4851
4852 * target.h (struct target_ops): Remove qxfer_spu member.
4853 * server.c (handle_qxfer_spu): Remove.
4854 (qxfer_packets): Remove entry for "spu".
4855 (handle_query): No longer support qXfer:spu:read or qXfer:spu:write.
4856 * linux-low.c (SPUFS_MAGIC): Remove.
4857 (spu_enumerate_spu_ids): Remove.
4858 (linux_qxfer_spu): Remove.
4859 (linux_target_ops): Remove qxfer_spu member.
4860 * lynx-low.c (lynx_target_ops): Remove qxfer_spu member.
4861 * nto-low.c (nto_target_ops): Remove qxfer_spu member.
4862 * win32-low.c (win32_target_ops): Remove qxfer_spu member.
4863
2d41fa11
SDJ
48642019-08-23 Sergio Durigan Junior <sergiodj@redhat.com>
4865
4866 * Makefile.in (SFILES): Add 'gdbsupport/gdb-dlfcn.c'.
4867 (OBS): Add 'gdbsupport/gdb-dlfcn.o'.
4868 * config.in: Regenerate.
4869 * configure: Regenerate.
4870
d59b55f0
TT
48712019-08-15 Tom Tromey <tromey@adacore.com>
4872
4873 * target.c (target_write_memory): Use gdb::byte_vector.
4874
4196ab2a
TT
48752019-08-15 Tom Tromey <tromey@adacore.com>
4876
4877 * tracepoint.c (write_inferior_data_pointer)
4878 (write_inferior_integer, write_inferior_int8)
4879 (write_inferior_uinteger, m_tracepoint_action_download)
4880 (r_tracepoint_action_download, x_tracepoint_action_download)
4881 (l_tracepoint_action_download, clear_inferior_trace_buffer)
4882 (download_agent_expr, download_tracepoint_1)
4883 (download_trace_state_variables, upload_fast_traceframes): Update.
4884 * server.c (gdb_write_memory): Update.
4885 * remote-utils.c (relocate_instruction): Update.
4886 * proc-service.c (ps_pdwrite): Update.
4887 * mem-break.c (remove_memory_breakpoint)
4888 (delete_fast_tracepoint_jump, set_fast_tracepoint_jump)
4889 (uninsert_fast_tracepoint_jumps_at)
4890 (reinsert_fast_tracepoint_jumps_at): Update.
4891 * linux-x86-low.c (append_insns)
4892 (i386_install_fast_tracepoint_jump_pad)
4893 (amd64_write_goto_address, i386_write_goto_address): Update.
4894 * linux-s390-low.c (append_insns, s390_write_goto_address):
4895 Update.
4896 * linux-ppc-low.c (ppc_relocate_instruction)
4897 (ppc_install_fast_tracepoint_jump_pad, emit_insns)
4898 (ppc_write_goto_address): Update.
4899 * linux-aarch64-low.c (append_insns): Update.
4900 * target.h (struct target_ops): Update.
4901 (write_inferior_memory): Don't declare.
4902 * target.c (target_write_memory): Rename from
4903 write_inferior_memory. Remove old target_write_memory.
4904
c6778d00
TT
49052019-08-15 Tom Tromey <tromey@adacore.com>
4906
4907 * target.c (write_inferior_memory): Use std::vector.
4908
404f2902
FCE
49092019-08-06 Frank Ch. Eigler <fche@redhat.com>
4910
4911 PR build/24886
4912 * configure.ac: Drop enable-libmcheck support.
4913 * configure, config.in: Rebuild.
4914 * acinclude.m4: Don't include it.
4915
4c5aa8e0
AH
49162019-07-19 Alan Hayward <alan.hayward@arm.com>
4917
4918 * configure.srv: Remove Arm xml files.
4919
7cc17433
AH
49202019-07-19 Alan Hayward <alan.hayward@arm.com>
4921
4922 * configure.srv: Add new files. Remove xml generated files.
4923 * linux-aarch32-low.c (initialize_low_arch_aarch32): Don't init
4924 registers.
4925 * linux-aarch32-low.h (tdesc_arm_with_neon): Remove.
4926 * linux-aarch32-tdesc.c: New file.
4927 * linux-aarch32-tdesc.h: New file.
4928 * linux-aarch64-low.c (aarch64_arch_setup): Call aarch32_linux_read_description.
4929 * linux-arm-low.c (init_registers_arm, tdesc_arm)
4930 (init_registers_arm_with_iwmmxt, tdesc_arm_with_iwmmxt)
4931 (init_registers_arm_with_vfpv2, tdesc_arm_with_vfpv2)
4932 (init_registers_arm_with_vfpv3, tdesc_arm_with_vfpv3): Remove.
4933 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
4934 (arm_store_vfpregset): Call arm_linux_get_tdesc_fp_type.
4935 (arm_read_description): Call arm_linux_read_description.
4936 (initialize_low_arch): Don't init registers.
4937 * linux-arm-tdesc.c: New file.
4938 * linux-arm-tdesc.h: New file.
4939
166a82be
AH
49402019-07-10 Alan Hayward <alan.hayward@arm.com>
4941
4942 * linux-arm-low.c (arm_fill_wmmxregset, arm_store_wmmxregset):
4943 Move counter inside for.
4944 (arm_read_description): Check ptrace earlier.
4945 (arm_arch_setup): Call arm_linux_init_hwbp_cap here.
4946
268a13a5
TT
49472019-07-09 Tom Tromey <tom@tromey.com>
4948
4949 * configure: Rebuild.
4950 * configure.ac: Change common to gdbsupport.
4951 * acinclude.m4: Change common to gdbsupport.
4952 * Makefile.in (SFILES, OBS, GDBREPLAY_OBS, IPA_OBJS)
4953 (version-generated.c, gdbsupport/%-ipa.o, gdbsupport/%.o): Change
4954 common to gdbsupport.
4955 * ax.c, event-loop.c, fork-child.c, gdb_proc_service.h,
4956 gdbreplay.c, gdbthread.h, hostio-errno.c, hostio.c, i387-fp.c,
4957 inferiors.c, inferiors.h, linux-aarch64-tdesc-selftest.c,
4958 linux-amd64-ipa.c, linux-i386-ipa.c, linux-low.c,
4959 linux-tic6x-low.c, linux-x86-low.c, linux-x86-tdesc-selftest.c,
4960 linux-x86-tdesc.c, lynx-i386-low.c, lynx-low.c, mem-break.h,
4961 nto-x86-low.c, regcache.c, regcache.h, remote-utils.c, server.c,
4962 server.h, spu-low.c, symbol.c, target.h, tdesc.c, tdesc.h,
4963 thread-db.c, tracepoint.c, win32-i386-low.c, win32-low.c: Change
4964 common to gdbsupport.
4965
350fab54
AH
49662019-07-04 Alan Hayward <alan.hayward@arm.com>
4967
4968 * linux-aarch32-low.c (arm_read_description, arm_regsets): Use new
4969 defines.
4970 * linux-arm-low.c (arm_read_description, arm_regsets): Likewise.
4971
2b40fda7
AH
49722019-07-04 Alan Hayward <alan.hayward@arm.com>
4973
4974 * configure.srv: Remove legacy xml.
4975 * linux-aarch64-low.c (initialize_low_arch): Remove
4976 initialize_low_tdesc call.
4977 * linux-aarch64-tdesc-selftest.c: Remove file.
4978 * linux-aarch64-tdesc.h (initialize_low_tdesc): Remove.
4979 * linux-x86-low.c (initialize_low_arch): Remove
4980 initialize_low_tdesc call.
4981 * linux-x86-tdesc-selftest.c: Remove file.
4982 * linux-x86-tdesc.h (initialize_low_tdesc): Remove.
4983
7d10623d
TV
49842019-06-20 Tom de Vries <tdevries@suse.de>
4985
4986 * linux-s390-ipa.c (get_ipa_tdesc)[!__s390x__]: Use
4987 s390_te_linux64_ft_collect_regmap for S390_TDESC_GS.
4988
8d6a48df
TV
49892019-06-19 Tom de Vries <tdevries@suse.de>
4990
4991 * debug.h (debug_write): Change return type to ssize_t.
4992 * debug.c (debug_write): Same.
4993
73cc7272
TT
49942019-06-14 Tom Tromey <tom@tromey.com>
4995
4996 * configure.ac: Use new path to gnulib.
4997 * configure: Rebuild.
4998 * Makefile.in (INCGNU, $(GNULIB_BUILDDIR)/Makefile): Use new path
4999 to gnulib.
5000
08f10e02
TT
50012019-06-11 Tom Tromey <tom@tromey.com>
5002
5003 * Makefile.in (SFILES): Add alloc.c.
5004 (OBS): Add alloc.o.
5005 (IPA_OBJS): Add alloc-ipa.o.
5006 (alloc-ipa.o): New target.
5007 (%.o: ../%.c): New pattern rule.
5008
422186a9
TT
50092019-06-10 Tom Tromey <tromey@adacore.com>
5010
5011 * remote-utils.c (look_up_one_symbol, relocate_instruction): Don't
5012 end warning with a newline.
5013 * linux-s390-low.c (s390_get_wordsize): Don't end warning with a
5014 newline.
5015 * thread-db.c (attach_thread): Don't end warning with a newline.
5016 (thread_db_notice_clone): Likewise.
5017 * tracepoint.c (gdb_agent_helper_thread): Don't end warning with a
5018 newline.
5019 * linux-x86-low.c (x86_get_min_fast_tracepoint_insn_len): Don't
5020 end warning with a newline.
5021
b02f78f9
PA
50222019-06-04 Pedro Alves <palves@redhat.com>
5023
5024 * server.c (captured_main): Use make_unique_xstrdup.
5025
88ed7edb
TT
50262019-06-02 Tom Tromey <tom@tromey.com>
5027
5028 * gdbreplay.c (fromhex): Remove.
5029 * Makefile.in (GDBREPLAY_OBS): Add rsp-low.o.
5030
33a6bc35
TT
50312019-05-29 Tom Tromey <tromey@adacore.com>
5032
5033 * configure: Rebuild.
5034
e90a813d
KB
50352019-05-06 Kevin Buettner <kevinb@redhat.com>
5036
5037 * linux-x86-low.c (x86_fill_gregset): Don't compile 64-bit
5038 sign extension code on 32-bit builds.
5039
353ea2d1
EZ
50402019-05-03 Eli Zaretskii <eliz@gnu.org>
5041
5042 * remote-utils.c:
5043 * gdbreplay.c [USE_WIN32API]: Remove the _WIN32_WINNT override.
5044
b494cdff
TT
50452019-04-19 Tom Tromey <tom@tromey.com>
5046
5047 * server.c (struct vstop_notif): Derive from notif_event.
5048 <base>: Remove.
5049 (queue_stop_reply): Update.
5050 (remove_all_on_match_ptid): Change type. Rewrite.
5051 (discard_queued_stop_replies): Rewrite.
5052 (in_queued_stop_replies_ptid): Change type.
5053 (in_queued_stop_replies): Rewrite.
5054 (notif_stop): Update.
5055 (queue_stop_reply_callback): Update.
5056 (captured_main): Don't call initialize_notif.
5057 (push_stop_notification): Update.
5058 * notif.c (notif_write_event, handle_notif_ack)
5059 (notif_event_enque, notif_push): Update.
5060 (notif_event_xfree, initialize_notif): Remove.
5061 * notif.h (struct notif_event): Include <list>, not
5062 "common/queue.h".
5063 (struct notif_server) <queue>: Now a std::list.
5064 (notif_event_p): Remove typedef.
5065 (initialize_notif): Don't declare.
5066 (struct notif_event): Add virtual destructor.
5067
a7e559cc
AH
50682019-04-17 Alan Hayward <alan.hayward@arm.com>
5069
5070 * ax.c (ax_vdebug): Call debug_printf.
5071 * debug.c (debug_write): New function.
5072 * debug.h (debug_write): New declaration.
5073 * linux-low.c (sigchld_handler): Call debug_write.
5074
aeb2e706
AH
50752019-04-17 Alan Hayward <alan.hayward@arm.com>
5076
5077 * debug.c (debug_set_output): New function.
5078 (debug_vprintf): Send output to debug_file.
5079 (debug_flush): Likewise.
5080 * debug.h (debug_set_output): New declaration.
5081 * server.c (handle_monitor_command): Add debug-file option.
5082 (captured_main): Likewise.
5083
c1bc0935
AH
50842019-04-17 Alan Hayward <alan.hayward@arm.com>
5085
5086 * debug.c (remote_debug): Add definition.
5087 * debug.h (remote_debug): Add declaration.
5088 * hostio.c (remote_debug): Remove declaration.
5089 * remote-utils.c (struct ui_file): Likewise.
5090 (remote_debug): Likewise.
5091 * remote-utils.h (remote_debug): Likewise,
5092 * server.c (remote_debug): Remove definition.
5093
3f52fdbc
KB
50942019-04-10 Kevin Buettner <kevinb@redhat.com>
5095
5096 * linux-x86-low.c (x86_fill_gregset): Sign extend EAX value
5097 when using a 64-bit gdbserver.
5098
b0319eaa
TT
50992019-04-09 Tom Tromey <tromey@adacore.com>
5100
5101 * linux-low.c (select_event_lwp): Use find_thread_in_random.
5102
eedc3f4f
TT
51032019-04-08 Tom Tromey <tom@tromey.com>
5104
5105 * linux-low.c (linux_detach_one_lwp): Replace throw_exception with
5106 throw.
5107 (linux_resume_one_lwp): Likewise.
5108
230d2906
TT
51092019-04-08 Tom Tromey <tom@tromey.com>
5110
5111 * gdbreplay.c: Update.
5112 * linux-low.c: Update.
5113 * server.c: Update.
5114
a70b8144
TT
51152019-04-08 Tom Tromey <tom@tromey.com>
5116
5117 * server.c: Use C++ exception handling.
5118 * linux-low.c: Use C++ exception handling.
5119 * gdbreplay.c: Use C++ exception handling.
5120
3d6e9d23
TT
51212019-04-08 Tom Tromey <tom@tromey.com>
5122
5123 * server.c (handle_btrace_general_set, handle_qxfer_btrace)
5124 (handle_qxfer_btrace_conf, detach_or_kill_for_exit_cleanup)
5125 (captured_main, main): Update.
5126 * gdbreplay.c (main): Update.
5127
0570503d
PFC
51282019-04-05 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5129
5130 * linux-low.c (linux_get_auxv): Remove static. Return auxv entry
5131 value in argument pointer, return 1 if the entry is found and 0
5132 otherwise. Move comment.
5133 (linux_get_hwcap, linux_get_hwcap2): Use modified linux_get_auxv.
5134 * linux-low.h (linux_get_auxv): Declare.
5135 * linux-ppc-low.c (is_elfv2_inferior): Use linux_get_auxv.
5136
227a9e65
TT
51372019-04-05 Tom Tromey <tromey@adacore.com>
5138
5139 * server.c (gdbserver_usage): Use upper-case for metasyntactic
5140 variables.
5141
69f4c9cc
AH
51422019-03-28 Alan Hayward <alan.hayward@arm.com>
5143
5144 * linux-low.c (AT_HWCAP2): Add define if not already included.
5145
974c89e0
AH
51462019-03-26 Alan Hayward <alan.hayward@arm.com>
5147
5148 * linux-aarch64-low.c (aarch64_get_hwcap): Remove function.
5149 (aarch64_arch_setup): Call linux_get_hwcap.
5150 * linux-arm-low.c (arm_get_hwcap): Remove function.
5151 (arm_read_description): Call linux_get_hwcap.
5152 * linux-low.c (linux_get_auxv): New function.
5153 (linux_get_hwcap): Likewise.
5154 (linux_get_hwcap2): Likewise.
5155 * linux-low.h (linux_get_hwcap): New declaration.
5156 (linux_get_hwcap2): Likewise.
5157 * linux-ppc-low.c (ppc_get_auxv): Remove function.
5158 (ppc_arch_setup): Call linux_get_hwcap.
5159 * linux-s390-low.c (s390_get_hwcap): Remove function.
5160 (s390_arch_setup): Call linux_get_hwcap.
5161
1ef53e6b
AH
51622019-03-22 Alan Hayward <alan.hayward@arm.com>
5163 Jiong Wang <jiong.wang@arm.com>
5164
5165 * linux-aarch64-low.c (aarch64_store_pauthregset): New function.
5166 * linux-low.c (regsets_store_inferior_registers): Allow optional reads
5167 to fail.
5168 * linux-low.h (enum regset_type): Add OPTIONAL_REGS.
5169
ee4fbcfa
AH
51702019-03-22 Alan Hayward <alan.hayward@arm.com>
5171 Jiong Wang <jiong.wang@arm.com>
5172
5173 * linux-aarch64-low.c (AARCH64_HWCAP_PACA): New define.
5174 (aarch64_get_hwcap): New function.
5175 (aarch64_arch_setup): Read APIA hwcap.
5176
6dc0ebde
AH
51772019-03-22 Alan Hayward <alan.hayward@arm.com>
5178 Jiong Wang <jiong.wang@arm.com>
5179
5180 * linux-aarch64-ipa.c (get_ipa_tdesc): Add pauth param.
5181 (initialize_low_tracepoint): Likewise.
5182 * linux-aarch64-low.c (aarch64_arch_setup): Likewise.
5183 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Likewise.
5184 * linux-aarch64-tdesc.c (struct target_desc): Likewise.
5185 (aarch64_linux_read_description): Likewise.
5186 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Likewise.
5187
1163a4b7
JB
51882019-03-12 John Baldwin <jhb@FreeBSD.org>
5189
5190 * linux-x86-tdesc.c (i386_linux_read_description): Update call to
5191 i386_create_target_description for 'segments' parameter.
5192 * lynx-i386-low.c (lynx_i386_arch_setup): Likewise.
5193 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
5194 * win32-i386-low.c (i386_arch_setup): Likewise.
5195
d3a70e03
TT
51962019-03-12 Tom Tromey <tromey@adacore.com>
5197
5198 * linux-low.c (iterate_over_lwps): Update.
5199
37991b4f
TT
52002019-03-06 Tom Tromey <tom@tromey.com>
5201
5202 * server.c (detach_or_kill_for_exit_cleanup): Remove parameter.
5203 (captured_main): Use SCOPE_EXIT.
5204
45950eb6
SDJ
52052019-03-04 Sergio Durigan Junior <sergiodj@redhat.com>
5206
5207 * configure.srv: Use '$enable_unittest' instead of '$development'
5208 when checking whether to fill 'srv_regobj' on 'aarch64*-*-linux*'
5209 case.
5210
43ac54fc
TT
52112019-02-27 Tom Tromey <tromey@adacore.com>
5212
5213 * gdbreplay.c (logchar): Handle \r\n.
5214
df0da8a2
AH
52152019-02-07 Alan Hayward <alan.hayward@arm.com>
5216
5217 * linux-low.c (linux_attach): Add process before lwp.
5218 * server.c (attach_inferior): Check if already attached.
5219
1a5c2598
TT
52202019-02-07 Tom Tromey <tom@tromey.com>
5221
5222 * x86-tdesc.h: Rename include guard.
5223 * x86-low.h: Add include guard.
5224 * wincecompat.h: Rename include guard.
5225 * win32-low.h: Add include guard.
5226 * utils.h: Rename include guard.
5227 * tracepoint.h: Rename include guard.
5228 * tdesc.h: Rename include guard.
5229 * target.h: Rename include guard.
5230 * server.h: Rename include guard.
5231 * remote-utils.h: Rename include guard.
5232 * regcache.h: Rename include guard.
5233 * nto-low.h: Rename include guard.
5234 * notif.h: Add include guard.
5235 * mem-break.h: Rename include guard.
5236 * lynx-low.h: Add include guard.
5237 * linux-x86-tdesc.h: Add include guard.
5238 * linux-s390-tdesc.h: Add include guard.
5239 * linux-ppc-tdesc-init.h: Add include guard.
5240 * linux-low.h: Add include guard.
5241 * linux-aarch64-tdesc.h: Add include guard.
5242 * linux-aarch32-low.h: Add include guard.
5243 * inferiors.h: Rename include guard.
5244 * i387-fp.h: Rename include guard.
5245 * hostio.h: Rename include guard.
5246 * gdbthread.h: Rename include guard.
5247 * gdb_proc_service.h: Rename include guard.
5248 * event-loop.h: Rename include guard.
5249 * dll.h: Rename include guard.
5250 * debug.h: Rename include guard.
5251 * ax.h: Rename include guard.
5252
956cc47c
SN
52532018-01-30 Szabolcs Nagy <szabolcs.nagy@arm.com>
5254
5255 PR gdb/23985
5256 * Makefile.in (IPAGENT_CFLAGS): Add UNDO_GNULIB_CFLAGS.
5257 (UNDO_GNULIB_CFLAGS): Undo gnulib replacements.
5258
a0707f3c
TT
52592019-01-25 Tom Tromey <tom@tromey.com>
5260
5261 * Makefile.in (INCLUDE_CFLAGS): Don't add -I for common.
5262
0747795c
TT
52632019-01-25 Tom Tromey <tom@tromey.com>
5264
5265 * win32-low.c: Fix common/ includes.
5266 * win32-i386-low.c: Fix common/ includes.
5267 * tracepoint.c: Fix common/ includes.
5268 * thread-db.c: Fix common/ includes.
5269 * target.h: Fix common/ includes.
5270 * symbol.c: Fix common/ includes.
5271 * spu-low.c: Fix common/ includes.
5272 * server.h: Fix common/ includes.
5273 * server.c: Fix common/ includes.
5274 * remote-utils.c: Fix common/ includes.
5275 * regcache.h: Fix common/ includes.
5276 * regcache.c: Fix common/ includes.
5277 * nto-x86-low.c: Fix common/ includes.
5278 * notif.h: Fix common/ includes.
5279 * mem-break.h: Fix common/ includes.
5280 * lynx-low.c: Fix common/ includes.
5281 * lynx-i386-low.c: Fix common/ includes.
5282 * linux-x86-tdesc-selftest.c: Fix common/ includes.
5283 * linux-x86-low.c: Fix common/ includes.
5284 * linux-low.c: Fix common/ includes.
5285 * inferiors.h: Fix common/ includes.
5286 * i387-fp.c: Fix common/ includes.
5287 * hostio.c: Fix common/ includes.
5288 * hostio-errno.c: Fix common/ includes.
5289 * gdbthread.h: Fix common/ includes.
5290 * gdbreplay.c: Fix common/ includes.
5291 * fork-child.c: Fix common/ includes.
5292 * event-loop.c: Fix common/ includes.
5293 * ax.c:
5294 (enum gdb_agent_op): Fix common/ includes.
5295
be6d4f74
TT
52962019-01-21 Tom Tromey <tom@tromey.com>
5297
5298 * tracepoint.c: Fix includes.
5299 * remote-utils.c: Fix includes.
5300 * linux-x86-low.c: Fix includes.
5301
66d91b39
JB
53022019-01-01 Joel Brobecker <brobecker@adacore.com>
5303
5304 * gdbreplay.c (gdbreplay_version): Update copyright year in
5305 version message.
5306 * server.c (gdbserver_version): Likewise.
5307
754e3168
AH
53082018-12-05 Alan Hayward <alan.hayward@arm.com>
5309
5310 * linux-low.c (add_lwp): Switch ordering.
5311
d105de22
TT
53122018-11-29 Tom Tromey <tom@tromey.com>
5313
5314 * win32-low.c (win32_join): Take pid, not process.
5315 * target.h (struct target_ops) <join>: Change argument type.
5316 (join_inferior): Change argument name.
5317 * spu-low.c (spu_join): Take pid, not process.
5318 * server.c (handle_detach): Preserve pid before destroying
5319 process.
5320 * lynx-low.c (lynx_join): Take pid, not process.
5321 * linux-low.c (linux_join): Take pid, not process.
5322
50138245
AH
53232018-11-23 Alan Hayward <alan.hayward@arm.com>
5324
5325 * linux-aarch64-low.c (aarch64_cannot_store_register): Remove.
5326 (aarch64_cannot_fetch_register): Likewise.
5327 (struct linux_target_ops): Update references.
5328
64f57f3d
PFC
53292018-10-31 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5330
5331 * linux-ppc-low.c: Include nat/linux-ptrace.h.
5332
8d619c01
EBM
53332018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5334
5335 * configure.srv (ipa_ppc_linux_regobj): Add
5336 powerpc-isa207-htm-vsx32l-ipa.o and
5337 powerpc-isa207-htm-vsx64l-ipa.o.
5338 (powerpc*-*-linux*): Add powerpc-isa207-htm-vsx32l.o and
5339 powerpc-isa207-htm-vsx64l.o to srv_regobj. Add
5340 rs6000/power-htm-spr.xml, rs6000/power-htm-core.xml,
5341 rs6000/power64-htm-core.xml, rs6000/power-htm-fpu.xml,
5342 rs6000/power-htm-altivec.xml, rs6000/power-htm-vsx.xml,
5343 rs6000/power-htm-ppr.xml, rs6000/power-htm-dscr.xml,
5344 rs6000/power-htm-tar.xml, rs6000/powerpc-isa207-htm-vsx32l.xml,
5345 and rs6000/powerpc-isa207-htm-vsx64l.xml to srv_xmlfiles.
5346 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
5347 <PPC_TDESC_ISA207_HTM_VSX>: New enum value.
5348 (init_registers_powerpc_isa207_htm_vsx32l)
5349 (init_registers_powerpc_isa207_htm_vsx64l): Declare.
5350 * linux-ppc-low.c (ppc_fill_tm_sprregset, ppc_store_tm_sprregset)
5351 (ppc_store_tm_cgprregset, ppc_store_tm_cfprregset)
5352 (ppc_store_tm_cvrregset, ppc_store_tm_cvsxregset)
5353 (ppc_store_tm_cpprregset, ppc_store_tm_cdscrregset)
5354 (ppc_store_tm_ctarregset): New functions.
5355 (ppc_regsets): Add entries for HTM regsets.
5356 (ppc_arch_setup): Set htm in features struct when needed. Set
5357 sizes for the HTM regsets.
5358 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_HTM_VSX.
5359 (initialize_low_arch): Call
5360 init_registers_powerpc_isa207_htm_vsx32l and
5361 init_registers_powerpc_isa207_htm_vsx64l.
5362 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
5363 PPC_TDESC_ISA207_HTM_VSX.
5364 (initialize_low_tracepoint): Call
5365 init_registers_powerpc_isa207_htm_vsx32l and
5366 init_registers_powerpc_isa207_htm_vsx64l.
5367
232bfb86
EBM
53682018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5369
5370 * configure.srv (powerpc*-*-linux*): Add rs6000/power-ebb.xml and
5371 rs6000/power-linux-pmu.xml to srv_xmlfiles.
5372 * linux-ppc-low.c (ppc_store_ebbregset, ppc_fill_pmuregset)
5373 (ppc_store_pmuregset): New functions.
5374 (ppc_regsets): Add entries for ebb and pmu regsets.
5375 (ppc_arch_setup): Set isa207 in features struct if the ebb and
5376 pmu regsets are available. Set sizes for these regsets.
5377
f2cf6173
EBM
53782018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5379
5380 * configure.srv (ipa_ppc_linux_regobj): Add
5381 powerpc-isa207-vsx64l-ipa.o and powerpc-isa207-vsx32l-ipa.o.
5382 (powerpc*-*-linux*): Add powerpc-isa207-vsx32l.o and
5383 powerpc-isa207-vsx64l.o to srv_regobj, add rs6000/power-tar.xml,
5384 rs6000/powerpc-isa207-vsx32l.xml, and
5385 rs6000/powerpc-isa207-vsx64l.xml to srv_xmlfiles.
5386 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
5387 <PPC_TDESC_ISA207_VSX>: New enum value.
5388 (init_registers_powerpc_isa207_vsx32l): Declare.
5389 (init_registers_powerpc_isa207_vsx64l): Declare.
5390 * linux-ppc-low.c (ppc_fill_tarregset): New function.
5391 (ppc_store_tarregset): New function.
5392 (ppc_regsets): Add entry for the TAR regset.
5393 (ppc_arch_setup): Set isa207 in features struct when needed. Set
5394 size for the TAR regsets.
5395 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_VSX.
5396 (initialize_low_arch): Call init_registers_powerpc_isa207_vsx32l
5397 and init_registers_powerpc_isa207_vsx64l.
5398 * linux-ppc-ipa.c (get_ipa_tdesc): Handle PPC_TDESC_ISA207_VSX.
5399 (initialize_low_tracepoint): Call
5400 init_registers_powerpc_isa207_vsx32l and
5401 init_registers_powerpc_isa207_vsx64l.
5402
7ca18ed6
EBM
54032018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
5404 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5405
5406 * configure.srv (ipa_ppc_linux_regobj): Add
5407 powerpc-isa205-ppr-dscr-vsx32l-ipa.o and
5408 powerpc-isa205-ppr-dscr-vsx64l-ipa.o.
5409 (powerpc*-*-linux*): Add powerpc-isa205-ppr-dscr-vsx32l.o and
5410 powerpc-isa205-ppr-dscr-vsx64l.o to srv_regobj, add
5411 rs6000/power-dscr.xml, rs6000/power-ppr.xml,
5412 rs6000/powerpc-isa205-ppr-dscr-vsx32l.xml and
5413 rs6000/powerpc-isa205-ppr-dscr-vsx64l.xml to srv_xmlfiles.
5414 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
5415 <PPC_TDESC_ISA205_PPR_DSCR_VSX>: New enum value.
5416 (init_registers_powerpc_isa205_ppr_dscr_vsx32l)
5417 (init_registers_powerpc_isa205_ppr_dscr_vsx64l): Declare.
5418 * linux-ppc-low.c: Include "elf/common.h" and <sys/uio.h>.
5419 (ppc_hwcap): Add comment.
5420 (ppc_hwcap2): New global.
5421 (ppc_check_regset, ppc_fill_pprregset, ppc_store_pprregset)
5422 (ppc_fill_dscrregset, ppc_store_dscrregset): New functions.
5423 (ppc_regsets): Add entries for the DSCR and PPR regsets.
5424 (ppc_arch_setup): Get AT_HWCAP2. Set ppr_dscr in features struct
5425 when needed. Set sizes for the the DSCR and PPR regsets.
5426 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA205_PPR_DSCR_VSX.
5427 (initialize_low_arch): Call
5428 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
5429 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
5430 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
5431 PPC_TDESC_ISA205_PPR_DSCR_VSX.
5432 (initialize_low_tracepoint): Call
5433 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
5434 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
5435
5c849b22
PFC
54362018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5437
5438 * linux-ppc-low.c (ppc_fill_vrregset): Remove memset calls.
5439
8ecfd7bd
SDJ
54402018-10-10 Sergio Durigan Junior <sergiodj@redhat.com>
5441 Simon Marchi <simark@simark.ca>
5442
5443 * acinclude.m4: Include "../selftest.m4".
5444 * configure: Regenerate.
5445 * configure.ac: Use "GDB_AC_SELFTEST".
5446 * configure.srv: Use "$enable_unittests" instead of
5447 "$development" when checking whether unit tests have been
5448 enabled.
5449 * server.c (captured_main): Update message informing that
5450 selftests have been disabled.
5451
96643e35
TT
54522018-10-04 Tom Tromey <tom@tromey.com>
5453
5454 * configure: Rebuild.
5455
da4ae14a
TT
54562018-10-04 Tom Tromey <tom@tromey.com>
5457
5458 * server.c (handle_status): Rename inner "thread".
5459 (process_serial_event): Declare "res" in 'm' case.
5460 * linux-low.c (last_thread_of_process_p, find_lwp_pid)
5461 (iterate_over_lwps): Rename inner "thread".
5462 (linux_qxfer_libraries_svr4): Rename inner "len".
5463 * gdbthread.h (find_thread_in_random): Rename inner "thread".
5464
7c619dbd
GB
54652018-10-01 Gary Benson <gbenson@redhat.com>
5466
5467 * gdb_proc_service.h: Moved common code to
5468 common/gdb_proc_service.h.
5469
3795e814
GB
54702018-10-01 Gary Benson <gbenson@redhat.com>
5471
5472 * gdb_proc_service.h: Synchronize comments and whitespace with
5473 GDB's version of this file.
5474
49b036f1
TT
54752018-09-25 Tom Tromey <tom@tromey.com>
5476
5477 * configure: Rebuild.
5478 * configure.ac (WARN_CFLAGS): Don't remove -Wmissing-prototypes.
5479
8ff03f0b
SM
54802018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
5481
5482 * Makefile.in (gdbserver$(EXEEXT)): Sort OBS.
5483 (gdbreplay$(EXEEXT)): Sort GDBREPLAY_OBS.
5484 ($(IPA_LIB)): Sort IPA_OBJS.
5485
a1cd91dc
SM
54862018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
5487
5488 * Makefile.in: Remove references to $(ADD_DEPS).
5489
752312ba
TT
54902018-09-16 Tom Tromey <tom@tromey.com>
5491
5492 * remote-utils.c (remote_open): Use GNU style for metasyntactic
5493 variables.
5494 * gdbreplay.c (gdbreplay_usage): Use GNU style for metasyntactic
5495 variables.
5496
f1628857
TT
54972018-09-05 Tom Tromey <tom@tromey.com>
5498
5499 * configure: Rebuild.
5500
ad202fcc
SM
55012018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
5502
5503 PR build/23399
5504 * tracepoint.c (IPA_SYM_STRUCT_NAME): Define.
5505
d3d8724a
TT
55062018-08-27 Tom Tromey <tom@tromey.com>
5507
5508 PR build/23087:
5509 * configure: Rebuild.
5510
b4f183d2
TT
55112018-08-27 Tom Tromey <tom@tromey.com>
5512
5513 * linux-s390-low.c (s390_emit_ext, s390_emit_litpool)
5514 (s390_emit_const, s390_emit_reg, s390_emit_zero_ext)
5515 (s390_emit_stack_adjust, s390_emit_set_r2, s390x_emit_ext)
5516 (s390x_emit_const, s390x_emit_reg, s390x_emit_zero_ext)
5517 (s390x_emit_stack_adjust): Add casts to unsigned char.
5518
4e2aa472
SM
55192018-08-22 Simon Marchi <simon.marchi@ericsson.com>
5520
5521 PR gdb/23374
5522 PR gdb/23375
5523 * server.h (struct client_state) <disable_randomization>:
5524 Initialize to 1.
5525
cf4088a9
SM
55262018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
5527
5528 * linux-mips-low.c (mips_collect_ptrace_register): Remove unused
5529 variable.
5530 (mips_supply_ptrace_register): Likewise.
5531
a0de763e
TT
55322018-07-22 Tom Tromey <tom@tromey.com>
5533
5534 * configure: Rebuild.
5535
b0a7723d
TT
55362018-07-22 Tom Tromey <tom@tromey.com>
5537
5538 * win32-low.c (win32_create_inferior): Remove unused variables.
5539 * gdbreplay.c (remote_open): Remove unused variable.
5540 * remote-utils.c (remote_prepare): Remove unused variable.
5541 * x86-tdesc.h (X86_TDESC_H): Define.
5542 (amd64_expedite_regs): Define conditionally.
5543 (i386_expedite_regs): Mark ATTRIBUTE_UNUSED.
5544 * linux-x86-tdesc.c (i386_tdescs): Move inside #if.
5545 * remote-utils.c (readchar): Remove unused variable.
5546
a780ef4f
PA
55472018-07-13 Pedro Alves <palves@redhat.com>
5548
5549 * linux-low.c (linux_kill): Change parameter to process_info
5550 pointer instead of pid. Adjust.
5551 * lynx-low.c (lynx_kill): Likewise.
5552 * nto-low.c (nto_kill): Likewise.
5553 * spu-low.c (spu_kill): Likewise.
5554 * win32-low.c (win32_kill): Likewise.
5555 * server.c (handle_v_kill, kill_inferior_callback)
5556 (detach_or_kill_for_exit): Adjust.
5557 * target.c (kill_inferior): Change parameter to process_info
5558 pointer instead of pid. Adjust.
5559 * target.h (struct target_ops) <kill>: Change parameter to
5560 process_info pointer instead of pid. Adjust all implementations
5561 and callers.
5562 (kill_inferior): Likewise.
5563
ef2ddb33
PA
55642018-07-13 Pedro Alves <palves@redhat.com>
5565
5566 * linux-low.c (linux_detach, linux_join): Change parameter to
5567 process_info pointer instead of pid. Adjust.
5568 * lynx-low.c (lynx_detach, lynx_join): Likewise.
5569 * nto-low.c (nto_detach): Likewise.
5570 * spu-low.c (spu_detach, spu_join): Likewise.
5571 * win32-low.c (win32_detach, win32_join): Likewise.
5572 * server.c (handle_detach, detach_or_kill_for_exit): Adjust.
5573 * target.h (struct target_ops) <detach, join>: Change parameter to
5574 process_info pointer instead of pid. Adjust all implementations
5575 and callers.
5576 (detach_inferior, join_inferior): Rename 'pid' parameter to
5577 'proc'.
5578
c7ab0aef
SDJ
55792018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
5580 Jan Kratochvil <jan.kratochvil@redhat.com>
5581 Paul Fertser <fercerpav@gmail.com>
5582 Tsutomu Seki <sekiriki@gmail.com>
5583
5584 * Makefile.in (SFILES): Add '$(srcdir)/common/netstuff.c'.
5585 (OBS): Add 'common/netstuff.o'.
5586 (GDBREPLAY_OBS): Likewise.
5587 * gdbreplay.c: Include 'wspiapi.h' and 'netstuff.h'.
5588 (remote_open): Implement support for IPv6
5589 connections.
5590 * remote-utils.c: Include 'netstuff.h', 'filestuff.h'
5591 and 'wspiapi.h'.
5592 (handle_accept_event): Accept connections from IPv6 sources.
5593 (remote_prepare): Handle IPv6-style hostnames; implement
5594 support for IPv6 connections.
5595 (remote_open): Implement support for printing connections from
5596 IPv6 sources.
5597
31445d10
PA
55982018-07-11 Pedro Alves <palves@redhat.com>
5599
5600 PR gdb/23377
5601 * mem-break.c (any_persistent_commands): Add process_info
5602 parameter and use it instead of relying on the current process.
5603 Change return type to bool.
5604 * mem-break.h (any_persistent_commands): Add process_info
5605 parameter and change return type to bool.
5606 * server.c (handle_detach): Remove require_running_or_return call.
5607 Look up the process_info for the process we're about to detach.
5608 If not found, return back error to GDB. Adjust
5609 any_persistent_commands call to pass down a process pointer.
5610
cb197132
PA
56112018-07-11 Pedro Alves <palves@redhat.com>
5612
5613 * i387-fp.c (i387_cache_to_fsave, cache_to_fxsave)
5614 (i387_cache_to_xsave): Use regcache_raw_get_unsigned_by_name
5615 instead of collect_register_by_name.
5616 * regcache.c (regcache_raw_get_unsigned_by_name): New.
5617 * regcache.h (regcache_raw_get_unsigned_by_name): New.
5618
1b919490
VB
56192018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
5620 Pedro Alves <palves@redhat.com>
5621
5622 * linux-low.c (initialize_low): Call linux_proc_init_warnings.
5623
d7e15655
TT
56242018-07-03 Tom Tromey <tom@tromey.com>
5625
5626 * linux-low.c: Update.
5627 * lynx-low.c: Update.
5628 * mem-break.c: Update.
5629 * nto-low.c: Update.
5630 * remote-utils.c: Update.
5631 * server.c: Update.
5632 * spu-low.c: Update.
5633 * target.c: Update.
5634 * win32-low.c: Update.
5635
26a57c92
TT
56362018-07-03 Tom Tromey <tom@tromey.com>
5637
5638 * server.c: Update.
5639
0e998d96
TT
56402018-07-03 Tom Tromey <tom@tromey.com>
5641
5642 * linux-low.c: Update.
5643
cc6bcb54
TT
56442018-07-03 Tom Tromey <tom@tromey.com>
5645
5646 * target.c: Update.
5647
e38504b3
TT
56482018-07-03 Tom Tromey <tom@tromey.com>
5649
5650 * linux-low.c: Update.
5651 * linux-mips-low.c: Update.
5652 * lynx-low.c: Update.
5653 * nto-low.c: Update.
5654 * remote-utils.c: Update.
5655 * server.c: Update.
5656 * spu-low.c: Update.
5657 * target.c: Update.
5658 * thread-db.c: Update.
5659
e99b03dc
TT
56602018-07-03 Tom Tromey <tom@tromey.com>
5661
5662 * linux-low.c: Update.
5663 * linux-mips-low.c: Update.
5664 * lynx-low.c: Update.
5665 * mem-break.c: Update.
5666 * nto-low.c: Update.
5667 * remote-utils.c: Update.
5668 * server.c: Update.
5669 * spu-low.c: Update.
5670 * target.c: Update.
5671 * tracepoint.c: Update.
5672
f2907e49
TT
56732018-07-03 Tom Tromey <tom@tromey.com>
5674
5675 * linux-low.c: Update.
5676 * linux-ppc-low.c: Update.
5677 * linux-x86-low.c: Update.
5678 * proc-service.c: Update.
5679 * server.c: Update.
5680 * spu-low.c: Update.
5681 * thread-db.c: Update.
5682 * win32-low.c: Update.
5683
fd79271b
TT
56842018-07-03 Tom Tromey <tom@tromey.com>
5685
5686 * linux-low.c: Update.
5687 * lynx-low.c: Update.
5688 * nto-low.c: Update.
5689 * remote-utils.c: Update.
5690 * spu-low.c: Update.
5691 * thread-db.c: Update.
5692 * win32-low.c: Update.
5693
c0867626
SDJ
56942018-06-29 Joel Brobecker <brobecker@adacore.com>
5695
5696 * linux-x86-tdesc.c (amd64_linux_read_description): Add missing
5697 parameter in call to 'amd64_create_target_description'.
5698
2512d7ef
JK
56992018-06-28 Jan Kratochvil <jan.kratochvil@redhat.com>
5700
5701 * x86-tdesc.h: Remove executable permission flag.
5702
d0ac1c44
SM
57032018-06-19 Simon Marchi <simon.marchi@ericsson.com>
5704
5705 * configure.ac: Remove AC_PREREQ, add missing quoting.
5706 * configure: Re-generate.
5707 * config.in: Re-generate.
5708 * aclocal.m4: Re-generate.
5709
c4eb05ff
SM
57102018-06-18 Simon Marchi <simon.marchi@ericsson.com>
5711
5712 * tracepoint.h (current_traceframe): Remove declaration.
5713
02895270
AH
57142018-06-18 Alan Hayward <alan.hayward@arm.com>
5715
5716 * linux-aarch64-low.c (is_sve_tdesc): New function.
5717 (aarch64_sve_regs_copy_to_regcache): Likewise.
5718 (aarch64_sve_regs_copy_from_regcache): Likewise.
5719 (aarch64_regs_info): Add SVE checks.
5720 (initialize_low_arch): Initialize SVE.
5721
e9902bfc
AH
57222018-06-18 Alan Hayward <alan.hayward@arm.com>
5723
5724 * Makefile.in: Add aarch64-sve-linux-ptrace.c.
5725
fefa175e
AH
57262018-06-11 Alan Hayward <alan.hayward@arm.com>
5727
5728 * linux-aarch64-ipa.c (get_ipa_tdesc): Add null VQ param.
5729 (initialize_low_tracepoint): Likewise
5730 * linux-aarch64-low.c (aarch64_arch_setup): Get VQ.
5731 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Add null VQ
5732 param.
5733 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add VQ
5734 checks.
5735 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Add VQ.
5736
b91ad3ff
AH
57372018-06-11 Alan Hayward <alan.hayward@arm.com>
5738
5739 * server.h (PBUFSIZ): Increase size
5740
f868386e
AH
57412018-06-11 Alan Hayward <alan.hayward@arm.com>
5742
5743 * regcache.c (regcache::raw_compare): New function.
5744 * regcache.h (regcache::raw_compare): New declaration.
5745
9c861883
AH
57462018-06-11 Alan Hayward <alan.hayward@arm.com>
5747
5748 * regcache.c (new_register_cache): Use new.
5749 (free_register_cache): Use delete.
5750 (register_data): Use const.
5751 (supply_register): Move body inside regcache.
5752 (regcache::raw_supply): New override function.
5753 (collect_register): Move body inside regcache.
5754 (regcache::raw_collect): New override function.
5755 (regcache::get_register_status): New override function.
5756 * regcache.h (struct regcache): Inherit from reg_buffer_common.
5757
40591844
TT
57582018-06-09 Tom Tromey <tom@tromey.com>
5759
5760 * event-loop.c (gdb_event, gdb_event_p): Remove typedefs. Don't
5761 declare queue.
5762 (event_queue): Use std::queue.
5763 (gdb_event_xfree): Remove.
5764 (initialize_event_loop, process_event, wait_for_event): Update.
5765
6341380d
SC
57662018-06-08 Stan Cox <scox@redhat.com>
5767
5768 * win32-low.c (win32_create_inferior): last_ptid and last_status
5769 moved to client_state.
5770
03349c93
PA
57712018-06-08 Pedro Alves <palves@redhat.com>
5772
5773 * Makefile.in (GDBREPLAY_OBS): Add common/cleanups.o,
5774 common/common-exceptions.o, common/common-utils.o,
5775 common/errors.o, common/print-utils.o and utils.o.
5776 * gdbreplay.c: Include "common-defs.h" instead of the two
5777 'config.h's here. Don't include stdio.h, errno.h, stdlib.h,
5778 string.h or alloca.h.
5779 (perror_with_name): Delete.
5780 (remote_open): Use xstrdup instead of strdup.
5781 (main): Rename to ...
5782 (captured_main): ... this.
5783 (main): New.
5784
8dcc53b3
TT
57852018-06-08 Tom Tromey <tom@tromey.com>
5786
5787 * linux-low.c (linux_low_read_btrace): Update.
5788
c12a5089
SC
57892018-06-04 Stan Cox <scox@redhat.com>
5790
5791 * server.h (struct client_state): New.
5792 * server.c (cont_thread, general_thread, multi_process)
5793 (report_fork_events, report_vfork_events, report_exec_events)
5794 (report_thread_events, swbreak_feature, hwbreak_feature)
5795 (vCont_supported, disable_randomization, pass_signals)
5796 (program_signals, program_signals_p, last_status, last_ptid, own_buf):
5797 Moved to client_state.
5798 * remote-utils.c (remote_debug, noack_mode)
5799 (transport_is_reliable): Moved to client_state.
5800 * tracepoint.c (current_traceframe): Moved to client_state.
5801
5802 Update all callers.
5803 * server.c, remote-utils.c, tracepoint.c, fork-child.c,
5804 linux-low.c, remote-utils.h, target.c: Use client_state.
5805
122394f1
AH
58062018-05-31 Alan Hayward <alan.hayward@arm.com>
5807
5808 * configure.srv: Add new c/h file.
5809
95228a0d
AH
58102018-05-31 Alan Hayward <alan.hayward@arm.com>
5811
5812 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add
5813 null VQ.
5814
d8dab6c3
MR
58152018-05-25 Maciej W. Rozycki <macro@mips.com>
5816
5817 * gdb.arch/mips-fpregset-core.exp: New test.
5818 * gdb.arch/mips-fpregset-core.c: New test source.
5819
81e25b7c
EK
58202018-05-23 Erik Kurzinger <ekurzinger@nvidia.com>
5821
5822 PR server/23198
5823 * hostio.c (require_int): Do not report overflow for integers
5824 between 0xfffffff and 0x7fffffff.
5825
7e947ad3
MR
58262018-05-22 Maciej W. Rozycki <macro@mips.com>
5827
5828 * linux-mips-low.c [HAVE_PTRACE_GETREGS] (mips_collect_register)
5829 (mips_supply_register): Move outside HAVE_PTRACE_GETREGS.
5830 (mips_collect_ptrace_register, mips_supply_ptrace_register): New
5831 functions.
5832 (the_low_target): Wire them.
5833
1d75a658
PFC
58342018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5835
5836 * linux-ppc-low.c (ppc_fill_vrregset): Add vscr_offset variable.
5837 Set vscr_offset to 0 in little-endian mode and 12 in big-endian
5838 mode. Call collect_register_by_name with vscr using
5839 vscr_offset. Zero-pad vscr and vrsave fields in collector buffer.
5840 (ppc_store_vrregset): Add and set vscr_offset variable as in
5841 ppc_fill_vrregset. Call supply_register_by_name with vscr using
5842 vscr_offset.
5843
d078308a
PFC
58442018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5845
5846 * linux-ppc-low.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
5847 (ppc_arch_setup): Change SIZEOF_VRREGS and SIZEOF_VSXREGS to
5848 PPC_LINUX_SIZEOF_VRREGSET and PPC_LINUX_SIZEOF_VSXREGSET.
5849
7273b5fc
PFC
58502018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5851
5852 * linux-ppc-low.c (ppc_fill_vsxregset): Remove ppc_hwcap check.
5853 (ppc_store_vsxregset): Likewise.
5854 (ppc_fill_vrregset): Likewise.
5855 (ppc_store_vrregset): Likewise.
5856 (ppc_fill_evrregset): Likewise.
5857 (ppc_store_evrregset): Likewise.
5858 (ppc_regsets): Set VSX/VR/EVR regset sizes to 0.
5859 (ppc_arch_setup): Iterate through ppc_regsets and set sizes when
5860 needed.
5861
2e077f5e
PFC
58622018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5863
5864 * linux-ppc-low.c (ppc_arch_setup): Remove code for getting the
5865 wordsize of the inferior. Call ppc_linux_target_wordsize.
5866
bd64614e
PFC
58672018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5868
5869 * configure.srv (srv_tgtobj): Add arch/ppc-linux-common.o.
5870 * Makefile.in (SFILES): Add arch/ppc-linux-common.c.
5871 * linux-ppc-tdesc.h: Rename to linux-ppc-tdesc-init.h.
5872 * linux-ppc-tdesc-init.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
5873 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
5874 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
5875 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
5876 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
5877 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
5878 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
5879 (tdesc_powerpc_e500l): Remove.
5880 * linux-ppc-ipa.c: Include arch/ppc-linux-tdesc.h and
5881 linux-ppc-tdesc-init.h. Don't include linux-ppc-tdesc.h.
5882 * linux-ppc-low.c: Include arch/ppc-linux-common.h,
5883 arch/ppc-linux-tdesc.h, and linux-ppc-tdesc-init.h. Don't include
5884 linux-ppc-tdesc.h.
5885 (ppc_arch_setup): Remove target description matching code. Fill a
5886 ppc_linux_features struct and call ppc_linux_match_description
5887 with it.
5888
75d74cca
MR
58892018-05-22 Maciej W. Rozycki <macro@mips.com>
5890
5891 * linux-mips-low.c (mips_cannot_fetch_register): Return 1 if the
5892 width of the requested register exceeds the width of the
5893 `ptrace' data type.
5894 (mips_cannot_store_register): Likewise.
5895
e4439e43
MR
58962018-05-21 Maciej W. Rozycki <macro@mips.com>
5897
5898 * linux-mips-low.c (mips_fetch_register): New function. Update
5899 preceding comment.
5900 (mips_store_gregset): Supply 0 rather than $restart for $zero.
5901 (the_low_target): Wire `mips_fetch_register'.
5902
55271bf9
JB
59032018-05-10 Joel Brobecker <brobecker@adacore.com>
5904
5905 * lynx-i386-low.c (LYNXOS_178): New macro.
5906 [LYNXOS_178] (usr_fcontext_t): Provide a definition that matches
5907 the layout on LynxOS-178.
5908 (lynx_i386_fill_fpregset, lynx_i386_store_fpregset): Do not
5909 handle floating point registers that are not supported by
5910 LynxOS-178.
5911
1a34f210
TT
59122018-05-10 Tom Tromey <tom@tromey.com>
5913
5914 * configure: Rebuild.
5915
190852c8
JB
59162018-05-10 Joel Brobecker <brobecker@adacore.com>
5917
5918 PR server/23158:
5919 * tdesc.h (init_target_desc) <expedite_regs>: New parameter.
5920 * tdesc.c (init_target_desc) <expedite_regs>: New parameter.
5921 Use it to set the expedite_regs field in the given tdesc.
5922 * x86-tdesc.h: New file.
5923 * linux-aarch64-tdesc.c (aarch64_linux_read_description):
5924 Adjust following the addition of the new expedite_regs parameter
5925 to init_target_desc.
5926 * linux-tic6x-low.c (tic6x_read_description): Likewise.
5927 * linux-x86-tdesc.c: #include "x86-tdesc.h".
5928 (i386_linux_read_description, amd64_linux_read_description):
5929 Adjust following the addition of the new expedite_regs parameter
5930 to init_target_desc.
5931 * lynx-i386-low.c: #include "x86-tdesc.h".
5932 (lynx_i386_arch_setup): Adjust following the addition of the new
5933 expedite_regs parameter to init_target_desc.
5934 * nto-x86-low.c: #include "x86-tdesc.h".
5935 (nto_x86_arch_setup): Adjust following the addition of the new
5936 expedite_regs parameter to init_target_desc.
5937 * win32-i386-low.c: #include "x86-tdesc.h".
5938 (i386_arch_setup): Adjust following the addition of the new
5939 expedite_regs parameter to init_target_desc.
5940
7dbac825
JB
59412018-05-10 Joel Brobecker <brobecker@adacore.com>
5942
5943 PR server/23158:
5944 * win32-low.c (win32_create_inferior): Add call to my_wait
5945 setting last_status global.
5946
906994d9
JB
59472018-05-10 Joel Brobecker <brobecker@adacore.com>
5948
5949 PR server/23158:
5950 * win32-low.c (create_process): Only call gdb_tilde_expand if
5951 inferior_cwd is not NULL.
5952
8ee22052
AB
59532018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
5954
5955 * i387-fp.c (i387_cache_to_xsave): Only write x87 control
5956 registers to the cache if their values have changed.
5957 (i387_xsave_to_cache): Provide default values for x87 control
5958 registers when these features are available, but disabled.
5959 * regcache.c (supply_register_by_name_zeroed): New function.
5960 * regcache.h (supply_register_by_name_zeroed): Declare new
5961 function.
5962
aff689d3
TT
59632018-05-07 Tom Tromey <tom@tromey.com>
5964
5965 * configure: Rebuild.
5966
85e26832
TT
59672018-05-04 Tom Tromey <tom@tromey.com>
5968
5969 * configure: Rebuild.
5970
a3b60e45
JK
59712018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
5972 Pedro Alves <palves@redhat.com>
5973
5974 * linux-aarch64-low.c (aarch64_stopped_data_address):
5975 Likewise.
5976
632e107b
TT
59772018-04-27 Tom Tromey <tom@tromey.com>
5978
5979 * configure: Rebuild.
5980
458412c3
TT
59812018-04-23 Tom Tromey <tom@tromey.com>
5982
5983 * configure: Rebuild.
5984
f31c089e
SM
59852018-04-19 Simon Marchi <simon.marchi@ericsson.com>
5986
5987 * Makefile.in (depcomp): Add "..".
5988 (all_deps_files): New and use it.
5989
b319b098
AH
59902018-04-18 Alan Hayward <alan.hayward@arm.com>
5991
5992 * configure.srv (aarch64*-*-linux*): Don't include xml.
5993 (i[34567]86-*-cygwin*): Likewise.
5994 (i[34567]86-*-linux*): Likewise.
5995 (i[34567]86-*-lynxos*): Likewise.
5996 (i[34567]86-*-mingw32ce*): Likewise.
5997 (i[34567]86-*-mingw*): Likewise.
5998 (i[34567]86-*-nto*): Likewise.
5999 (tic6x-*-uclinux): Likewise.
6000 (x86_64-*-linux*): Likewise.
6001 (x86_64-*-mingw*): Likewise.
6002 (x86_64-*-cygwin*): Likewise.
6003
3b74854b
AH
60042018-04-18 Alan Hayward <alan.hayward@arm.com>
6005
6006 * tdesc.c: Remove xml parameter.
6007
e98577a9
AH
60082018-04-18 Alan Hayward <alan.hayward@arm.com>
6009
6010 * server.c (get_features_xml): Remove cast.
6011 * tdesc.c (void target_desc::accept): Fill in function.
6012 (tdesc_get_features_xml): Remove old xml creation.
6013 (print_xml_feature::visit_pre): Add xml vistor.
6014 * tdesc.h (struct target_desc): Make xmltarget mutable.
6015 (tdesc_get_features_xml): Remove declaration.
6016
d278f585
AH
60172018-04-18 Alan Hayward <alan.hayward@arm.com>
6018
6019 * tdesc.c (tdesc_architecture_name): Add new function.
6020 (tdesc_osabi_name): Likewise.
6021 (tdesc_get_features_xml): Use new functions.
6022
eee8a18d
AH
60232018-04-18 Alan Hayward <alan.hayward@arm.com>
6024
6025 * tdesc.c (tdesc_create_flags): Remove.
6026 (tdesc_add_flag): Likewise.
6027 (tdesc_named_type): Likewise.
6028 (tdesc_create_union): Likewise.
6029 (tdesc_create_struct): Likewise.
6030 (tdesc_create_vector): Likewise.
6031 (tdesc_add_bitfield): Likewise.
6032 (tdesc_add_field): Likewise.
6033 (tdesc_set_struct_size): Likewise.
6034
82ec9bc7
AH
60352018-04-18 Alan Hayward <alan.hayward@arm.com>
6036
6037 * tdesc.c (~target_desc): Remove implictly deleted items.
6038 (init_target_desc): Iterate all features.
6039 (tdesc_get_features_xml): Use vector.
6040 (tdesc_create_feature): Create feature.
6041 * tdesc.h (tdesc_feature) Remove
6042 (target_desc): Add features.
6043
ea3e7d71
AH
60442018-04-18 Alan Hayward <alan.hayward@arm.com>
6045
6046 * Makefile.in: Add common/tdesc.c
6047 * tdesc.c (init_target_desc): init all reg_defs from register
6048 vector.
6049 (tdesc_create_reg): Create tdesc_reg.
6050 * tdesc.h (tdesc_feature): Add register vector.
6051
17d08cd4
SM
60522018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
6053
6054 * tdesc.h (struct target_desc) <features>: Change type to
6055 std::vector<std::string>.
6056 * tdesc.c (target_desc::~target_desc): Adjust to std::vector
6057 changes.
6058 (tdesc_get_features_xml): Likewise.
6059 (tdesc_create_feature): Likewise.
6060
5cd3e386
AH
60612018-03-26 Alan Hayward <alan.hayward@arm.com>
6062
6063 * regcache.c (find_register_by_number): Return a ref.
6064 (find_regno): Use references.
6065 (register_size): Likewise.
6066 (register_data): Likewise.
6067 * tdesc.c (target_desc::~target_desc): Remove free calls.
6068 (target_desc::operator==): Use std::vector compare.
6069 (init_target_desc): Use reference.
6070 (tdesc_create_reg): Use reg constructors.
6071 * tdesc.h (struct target_desc): Replace pointer with object.
6072
dff7492c
AH
60732018-03-23 Alan Hayward <alan.hayward@arm.com>
6074
6075 * regcache.c (find_register_by_number): Make static.
6076 (find_regno): Use find_register_by_number
6077 * regcache.h (struct reg): Remove declaration.
6078
d80e5242
AH
60792018-03-23 Alan Hayward <alan.hayward@arm.com>
6080
6081 * tdesc.c (target_desc::~target_desc): Move to here.
6082 (target_desc::operator==): Likewise.
6083 * tdesc.h (target_desc::~target_desc): Move from here.
6084 (target_desc::operator==): Likewise.
6085
f69c5afb
AA
60862018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
6087
6088 * linux-s390-low.c (s390_get_wordsize): Correct brace style.
6089
ce29f843
AA
60902018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
6091
6092 * linux-s390-ipa.c (get_ipa_tdesc): Add handling for
6093 S390_TDESC_GS.
6094 * linux-s390-low.c (s390_get_ipa_tdesc_idx): Likewise.
6095 (initialize_low_tracepoint): Call init_registers_s390x_gs_linux64
6096 and init_registers_s390_gs_linux64.
6097
c49bd90b
AA
60982018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
6099
6100 * linux-s390-low.c (s390_fill_gs): Remove function.
6101 (s390_fill_gsbc): Remove function.
6102 (s390_regsets): Set fill functions for the guarded storage regsets
6103 to NULL.
6104
7edb9bd3
AA
61052018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
6106
6107 * linux-s390-low.c (s390_get_hwcap): Replace tdesc parameter by
6108 the word size. Add comment.
6109 (s390_get_wordsize): New function.
6110 (s390_arch_setup): No longer select a temporary tdesc to fetch the
6111 pswm with it. Instead, use s390_get_wordsize to determine the
6112 word size first and derive the correct tdesc from that directly.
6113
39be3c7e
SM
61142018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
6115
6116 * Makefile.in: Include silent-rules.mk.
6117 (srcdir, abs_top_srcdir, abs_srcdir, VPATH): Move up.
6118 (COMPILE): Add ECHO_CXX.
6119 (gdbserver$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
6120 (gdbreplay$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
6121 ($(IPA_LIB)): Add SILENCE and ECHO_CXXLD.
6122 (version-generated.c): Add ECHO_GEN.
6123 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN_GENERATED.
6124 (IPAGENT_COMPILE): Add ECHO_CXX.
6125 (%-generated.c): Add ECHO_REGDAT.
6126
3ae9ce5d
TT
61272018-03-14 Tom Tromey <tom@tromey.com>
6128
6129 PR cli/14977:
6130 * ax.c (ax_printf): Special case for NULL.
6131
e6a58aa8
SM
61322018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
6133
6134 * linux-low.c (linux_qxfer_libraries_svr4): Use
6135 xml_escape_text_append.
6136
f6e8a41e
SM
61372018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
6138
6139 * linux-low.c (linux_qxfer_libraries_svr4): Use std::string.
6140
b9671caf
SM
61412018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
6142
6143 * server.c (handle_general_set): Remove unnecessary xstrdup.
6144
e80aaf61
SM
61452018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
6146
6147 * server.c (parse_debug_format_options): Adjust to
6148 delim_string_to_char_ptr_vec changes.
6149 * thread-db.c (thread_db_load_search): Adjust to
6150 dirnames_to_char_ptr_vec changes.
6151
b1223e78
MM
61522018-03-01 Markus Metzger <markus.t.metzger@intel.com>
6153
6154 * target.h (target_enable_btrace, target_disable_btrace)
6155 (target_read_btrace, target_read_btrace_conf): Turn macro into
6156 inline function. Throw error if target method is not defined.
6157 * server.c (handle_qxfer_btrace handle_qxfer_btrace_conf): Remove
6158 check for btrace target method. Be prepared to handle exceptions
6159 from btrace target methods.
6160
81561546
SDJ
61612018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
6162
6163 * server.c (captured_main): Change order of error message printed
6164 when the current working directory cannot be found.
6165
25e3c82c
SDJ
61662018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
6167
6168 * server.c: Include "filenames.h" and "pathstuff.h".
6169 (program_name): Delete variable.
6170 (program_path): New anonymous class.
6171 (get_exec_wrapper): Use "program_path" instead of
6172 "program_name".
6173 (handle_v_run): Likewise.
6174 (captured_main): Likewise.
6175 (process_serial_event): Likewise.
6176
b4987c95
SDJ
61772018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
6178
6179 * Makefile.in (SFILES): Add "$(srcdir)/common/pathstuff.c".
6180 (OBJS): Add "pathstuff.o".
6181 * server.c (current_directory): New global variable.
6182 (captured_main): Initialize "current_directory".
6183
f46cd62a
AH
61842018-02-26 Alan Hayward <alan.hayward@arm.com>
6185
6186 * tdesc.c: Use common/tdesc.h.
6187 * tdesc.h: Likewise.
6188
a543c5ca
AH
61892018-02-20 Alan Hayward <alan.hayward@arm.com>
6190 Simon Marchi <simon.marchi@ericsson.com>
6191
6192 * Makefile.in: Switch order of make rules.
6193
b5884fa7
AH
61942018-02-19 Alan Hayward <alan.hayward@arm.com>
6195
6196 * Makefile.in: Add common directory in build.
6197 * configure.ac: Add common reference.
6198 * configure: Regenerate.
6199
de6242d3
MM
62002018-02-09 Markus Metzger <markus.t.metzger@intel.com>
6201
6202 * linux-low.c (linux_target_ops): Remove linux_supports_btrace.
6203 * nto-low.c (nto_target_ops): Remove NULL for supports_btrace.
6204 * spu-low.c (spu_target_ops): Likewise.
6205 * win32-low.c (win32_target_ops): Likewise.
6206 * server.c (supported_btrace_packets): Report packets unconditionally.
6207 * target.h (target_ops) <supports_btrace>: Remove.
6208 (target_supports_btrace): Remove.
6209
9ee23a85
MM
62102018-02-09 Markus Metzger <markus.t.metzger@intel.com>
6211
6212 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt)
6213 (handle_btrace_disable): Change return type to void. Use exceptions
6214 to report errors.
6215 (handle_btrace_general_set): Catch exception and copy message to
6216 return message.
6217
8ce47547
TT
62182018-02-08 Tom Tromey <tom@tromey.com>
6219
6220 * linux-low.c (install_software_single_step_breakpoints): Use
6221 make_scoped_restore.
6222 * inferiors.c (make_cleanup_restore_current_thread): Remove.
6223 (do_restore_current_thread_cleanup): Remove.
6224 * gdbthread.h (make_cleanup_restore_current_thread): Don't
6225 declare.
6226
45dd3607
TT
62272018-02-08 Tom Tromey <tom@tromey.com>
6228
6229 * mem-break.c (set_raw_breakpoint_at): Use
6230 gdb::unique_xmalloc_ptr.
6231
e671cd59
PA
62322018-01-30 Pedro Alves <palves@redhat.com>
6233
6234 PR gdb/13211
6235 * target.c (target_terminal::terminal_state): Rename to ...
6236 (target_terminal::m_terminal_state): ... this.
6237
a0aad537
JC
62382018-01-19 James Clarke <jrtc27@jrtc27.com>
6239
6240 * linux-low.c (handle_extended_wait): Surround call to
6241 thread_db_notice_clone with #ifdef USE_THREAD_DB.
6242
4d9b86e1
SM
62432018-01-17 Simon Marchi <simon.marchi@ericsson.com>
6244
6245 * linux-low.c (attach_proc_task_lwp_callback): Adjust to
6246 linux_ptrace_attach_fail_reason_string now returning an
6247 std::string.
6248 (linux_attach): Likewise.
6249 * thread-db.c (attach_thread): Likewise.
6250
f517c180
EA
62512018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
6252
6253 PR gdb/21559
6254 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
6255 checking for fs_base/gs_base fields in struct user_regs_struct.
6256 * configure: Regenerate.
6257
9a70f35c
YQ
62582018-01-16 Yao Qi <yao.qi@linaro.org>
6259
6260 PR gdb/18749
6261 * linux-low.c (fetch_register): Call supply_register instead of
6262 error.
6263
605fd3c6
YQ
62642018-01-08 Yao Qi <yao.qi@linaro.org>
6265 Simon Marchi <simon.marchi@ericsson.com>
6266
6267 * Makefile.in (OBS): Remove selftest.o.
6268 * configure.ac: Set srv_selftest_objs if $development is true.
6269 (GDBSERVER_DEPFILES): Append $srv_selftest_objs.
6270 * configure: Re-generated.
6271 * server.c (captured_main): Wrap variable selftest_filter with
6272 GDB_SELF_TEST.
6273
2cc05030
SM
62742018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
6275
6276 * server.c (parse_debug_format_options): Return std::string.
6277 (handle_monitor_command, captured_main): Adjust.
6278
e379cee6
PA
62792018-01-05 Pedro Alves <palves@redhat.com>
6280
6281 PR gdb/18653
6282 * server.c (captured_main): Pass quiet=false to
6283 save_original_signals_state.
6284
82e1e79a
JB
62852018-01-01 Joel Brobecker <brobecker@adacore.com>
6286
6287 * gdbreplay.c (gdbreplay_version): Update copyright year in
6288 version message.
6289 * server.c (gdbserver_version): Likewise.
6290
8e481c3b
TT
62912017-12-08 Tom Tromey <tom@tromey.com>
6292
6293 * ax.c (ax_printf): Update.
6294
a8806230
YQ
62952017-12-07 Yao Qi <yao.qi@linaro.org>
6296
6297 * linux-aarch64-ipa.c (initialize_low_tracepoint): Call
6298 aarch64_linux_read_description.
6299 * linux-amd64-ipa.c (idx2mask): New array.
6300 (get_ipa_tdesc): Move idx2mask out.
6301 (initialize_low_tracepoint): Initialize target descriptions.
6302 * linux-i386-ipa.c (idx2mask): New array.
6303 (get_ipa_tdesc): Move idx2mask out.
6304 (initialize_low_tracepoint): Initialize target descriptions.
6305
d4a0e8b5
SM
63062017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
6307
6308 * tdesc.c (struct tdesc_type): Change return type.
6309 (tdesc_add_flag): Change parameter type.
6310 (tdesc_add_bitfield): Likewise.
6311 (tdesc_add_field): Likewise.
6312 (tdesc_set_struct_size): Likewise.
6313
798a7429
SM
63142017-12-05 Simon Marchi <simon.marchi@ericsson.com>
6315
6316 * regcache.c (registers_to_string): Remove unused variable.
6317
c0e15c9b
SM
63182017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6319
6320 * inferiors.c (for_each_inferior_with_data): Remove.
6321 * inferiors.h (for_each_inferior_with_data): Remove.
6322 * server.c (handle_qxfer_threads_worker): Change parameter type.
6323 (handle_qxfer_threads_proper): Use for_each_thread.
6324
f0045347
SM
63252017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6326
6327 * inferiors.c (for_each_inferior): Remove.
6328 (clear_inferiors): Use for_each_thread.
6329 * inferiors.h (for_each_inferior): Remove.
6330 * linux-low.c (linux_wait_for_event_filtered): Use
6331 for_each_thread.
6332 (linux_stabilize_threads): Likewise.
6333 * regcache.c (regcache_release): Likewise.
6334 * server.c (gdb_wants_all_threads_stopped): Likewise.
6335 (clear_pending_status_callback): Remove.
6336 (handle_status): Use for_each_thread.
6337 (captured_main): Likewise.
6338 * win32-low.c (child_init_thread_list): Likewise.
6339 (win32_clear_inferiors): Likewise.
6340 (fake_breakpoint_event): Likewise.
6341
9521758b
SM
63422017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6343
6344 * inferiors.h (find_inferior): Remove.
6345 * inferiors.c (find_inferior): Remove.
6346
8f86d7aa
SM
63472017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6348
6349 * linux-low.c (resume_status_pending_p): Update comment.
6350 (need_step_over_p): Update comment.
6351
e2b44075
SM
63522017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6353
6354 * linux-low.c (proceed_one_lwp): Return void, change parameter
6355 type.
6356 (unsuspend_and_proceed_one_lwp): Likewise.
6357 (proceed_all_lwps): Use for_each_thread.
6358 (unstop_all_lwps): Likewise.
6359
c80825ff
SM
63602017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6361
6362 * linux-low.c (linux_resume_one_thread): Return void, take
6363 parameter directly.
6364 (linux_resume): Use for_each_thread.
6365
df3e4dbe
SM
63662017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6367
6368 * linux-low.c (send_sigstop_callback): Return void, change
6369 parameter type. Rename to...
6370 (send_sigstop): ... this.
6371 (suspend_and_send_sigstop_callback): Return void, change parameter
6372 type. Rename to...
6373 (suspend_and_send_sigstop): ... this.
6374 (stop_all_lwps): Use for_each_thread.
6375
5a6b0a41
SM
63762017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6377
6378 * linux-low.c (lwp_running): Return bool, remove unused
6379 argument.
6380 (linux_stabilize_threads): Use find_thread.
6381
39a64da5
SM
63822017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6383
6384 * linux-low.c (select_singlestep_lwp_callback): Remove.
6385 (count_events_callback): Remove.
6386 (select_event_lwp_callback): Remove.
6387 (select_event_lwp): Use find_thread/for_each_thread.
6388
a1385b7b
SM
63892017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6390
6391 * linux-low.c (not_stopped_callback): Return bool, take filter
6392 argument directly.
6393 (linux_wait_for_event_filtered): Use find_thread.
6394 (linux_wait_1): Likewise.
6395
454296a2
SM
63962017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6397
6398 * linux-low.c (same_lwp): Remove.
6399 (find_lwp_pid): Use find_thread.
6400
6b2a85da
SM
64012017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6402
6403 * linux-low.c (delete_lwp_callback): Remove.
6404 (linux_mourn): Use for_each_thread.
6405
798a38e8
SM
64062017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6407
6408 * linux-low.c (linux_detach_lwp_callback): Return void, remove
6409 args parameter, don't check for pid.
6410 (linux_detach): Use for_each_thread.
6411
e4eb0dec
SM
64122017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6413
6414 * linux-low.c (struct counter): Remove.
6415 (second_thread_of_pid_p): Remove.
6416 (last_thread_of_process_p): Use find_thread.
6417
83e1b6c1
SM
64182017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6419
6420 * inferiors.c (find_inferior_in_random): Remove.
6421 * inferiors.h (find_inferior_in_random): Remove.
6422 * linux-low.c (status_pending_p_callback): Return bool, accept
6423 parameter ptid directly.
6424 (linux_wait_for_event_filtered): Use find_thread_in_random.
6425 (linux_wait_1): Likewise.
6426
8dc7b443
SM
64272017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6428
6429 * inferiors.c (find_inferior_id): Remove.
6430 (find_thread_ptid): Move implemention from find_inferior_id to
6431 here.
6432 * inferiors.h (find_inferior_id): Remove.
6433 * server.c (handle_status): Use find_thread_ptid.
6434 (process_serial_event): Likewise.
6435 * thread-db.c (find_one_thread): Likewise.
6436 (thread_db_thread_handle): Likewise.
6437 * win32-low.c (thread_rec): Likewise.
6438 (child_delete_thread): Likewise.
6439 (win32_thread_alive): Likewise.
6440 (get_child_debug_event): Likewise.
6441
da25033c
SM
64422017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6443
6444 * linux-mips-low.c (update_watch_registers_callback): Return
6445 void, remove pid_p parameter, don't check for pid.
6446 (mips_insert_point, mips_remove_point): Use for_each_thread.
6447
c91bb56b
SM
64482017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6449
6450 * lynx.low (lynx_delete_thread_callback): Remove.
6451 (lynx_mourn): Use for_each_thread.
6452
634a3254
SM
64532017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6454
6455 * regcache.c (regcache_invalidate_one): Remove.
6456 (regcache_invalidate_pid): use for_each_thread.
6457
41272101
TT
64582017-11-26 Tom Tromey <tom@tromey.com>
6459
6460 * linux-low.c (linux_create_inferior): Update.
6461
f5291a6f
UW
64622017-11-24 Ulrich Weigand <uweigand@de.ibm.com>
6463
6464 * spu-low.c (spu_create_inferior): Fix typo in argument name.
6465
6654d750
AH
64662017-11-24 Alan Hayward <alan.hayward@arm.com>
6467
6468 * configure.srv: Add linux-aarch64-tdesc-selftest.o.
6469 * linux-aarch64-low.c (initialize_low_arch): Call init func.
6470 * linux-aarch64-tdesc-selftest.c: New file.
6471 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
6472
64732017-11-24 Alan Hayward <alan.hayward@arm.com>
6474
6475 * configure.srv: Add new file.
6476 * linux-aarch64-low.c (initialize_low_arch): Call init func.
6477 * linux-aarch64-tdesc-selftest.c: New file.
6478 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
6479
49bdb7ee
AH
64802017-11-24 Alan Hayward <alan.hayward@arm.com>
6481
6482 * linux-aarch64-ipa.c (initialize_low_tracepoint): Remove init.
6483 * linux-aarch64-low.c (initialize_low_arch): Remove init.
6484 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add init.
6485
d6d7ce56
AH
64862017-11-24 Alan Hayward <alan.hayward@arm.com>
6487
6488 * configure.srv: Add new files.
6489 * linux-aarch64-ipa.c (get_ipa_tdesc): Call
6490 aarch64_linux_read_description.
6491 * linux-aarch64-low.c (aarch64_linux_read_description):
6492 Merge with aarch64_arch_setup.
6493 (aarch64_arch_setup): Call aarch64_linux_read_description.
6494 * linux-aarch64-tdesc.c: New file.
6495 * linux-aarch64-tdesc.h: New file.
6496
506fe5f4
YQ
64972017-11-24 Yao Qi <yao.qi@linaro.org>
6498
6499 * configure.srv: Set $srv_regobj for tic6x-linux.
6500 * linux-tic6x-low.c: Include "arch/tic6x.h" and "tdesc.h".
6501 (tic6x_read_description): Move some code to tic6x_arch_setup.
6502 (tic6x_tdesc_test): New function.
6503 (initialize_low_arch): Call selftests::register_test.
6504
29f9a567
YQ
65052017-11-22 Yao Qi <yao.qi@linaro.org>
6506
6507 * remote-utils.c (prepare_resume_reply): Use memcpy.
6508
578290ec
SM
65092017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6510
6511 * linux-low.c (kill_one_lwp_callback): Return void, take
6512 argument directly, don't filter on pid.
6513 (linux_kill): Use for_each_thread.
6514
eca55aec
SM
65152017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6516
6517 * linux-low.c (need_step_over_p): Return bool, remove dummy
6518 argument.
6519 (linux_resume, proceed_all_lwps): Use find_thread.
6520
25c28b4d
SM
65212017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6522
6523 * linux-low.c (resume_status_pending_p): Return bool, remove
6524 flag_p argument.
6525 (linux_resume): Use find_thread.
6526
5fdda392
SM
65272017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6528
6529 * linux-low.c (struct thread_resume_array): Remove.
6530 (linux_set_resume_request): Return void, take arguments
6531 directly.
6532 (linux_resume): Use for_each_thread.
6533
fcb056a5
SM
65342017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6535
6536 * linux-low.c (stuck_in_jump_pad_callback): Change prototype,
6537 return bool, remove data argument.
6538 (linux_stabilize_threads): Use find_thread.
6539
139720c5
SM
65402017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6541
6542 * linux-low.c (unsuspend_one_lwp): Remove.
6543 (unsuspend_all_lwps): Use for_each_thread, inline code from
6544 unsuspend_one_lwp.
6545
6d1e5673
SM
65462017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6547
6548 * gdbthread.h (find_thread): Add overload with ptid_t filter.
6549 * linux-low.c (struct iterate_over_lwps_args): Remove.
6550 (iterate_over_lwps_filter): Remove.
6551 (iterate_over_lwps): Use find_thread.
6552
bbf550d5
SM
65532017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6554
6555 * linux-low.c (reset_lwp_ptrace_options_callback): Remove.
6556 (linux_handle_new_gdb_connection): Use for_each_thread, inline
6557 code from reset_lwp_ptrace_options_callback.
6558
00192f77
SM
65592017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6560
6561 * linux-arm-low.c (struct update_registers_data): Remove.
6562 (update_registers_callback): Return void, take arguments
6563 directly, don't check thread's pid.
6564 (arm_insert_point, arm_remove_point): Use for_each_thread.
6565
2bee2b6c
SM
65662017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6567
6568 * win32-low.c (continue_one_thread): Return void, take argument
6569 directly.
6570 (child_continue): Use for_each_thread.
6571
0b360f19
SM
65722017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6573
6574 * win32-i386-low.c (update_debug_registers_callback): Rename
6575 to ...
6576 (update_debug_registers): ... this, return void, remove pid_p arg.
6577 (x86_dr_low_set_addr, x86_dr_low_set_control): Use for_each_thread.
6578
f27866ba
SM
65792017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
6580
6581 * inferiors.h (struct process_info): Add constructor, initialize
6582 fields..
6583 <syscalls_to_catch>: Change type to std::vector<int>.
6584 * inferiors.c (add_process): Allocate process_info with new.
6585 (remove_process): Free process_info with delete.
6586 * linux-low.c (handle_extended_wait): Adjust.
6587 (gdb_catching_syscalls_p, gdb_catch_this_syscall_p): Adjust.
6588 * server.c (handle_general_set): Adjust.
6589
e849ea89
PA
65902017-11-16 Pedro Alves <palves@redhat.com>
6591
6592 * remote-utils.c (remote_close): Block SIGIO signals instead of
6593 uninstalling the SIGIO handler.
6594
1d0aa65c
AH
65952017-11-16 Alan Hayward <alan.hayward@arm.com>
6596
6597 * tdesc.c (tdesc_get_features_xml): Allow null osabi.
6598
3491a34c
YQ
65992017-11-16 Yao Qi <yao.qi@linaro.org>
6600
6601 * linux-tic6x-low.c (tic6x_fill_gregset): Cast buf.
6602 (tic6x_store_gregset): Likewise.
6603 (tic6x_usrregs_info): Move it up.
6604
a602f924
AH
66052017-11-15 Alan Hayward <alan.hayward@arm.com>
6606
6607 * Makefile.in: Update arch rules.
6608 * configure.srv: Explicitly mark arch/ files.
6609
5616b6c3
AS
66102017-11-13 Andreas Schwab <schwab@suse.de>
6611
6612 * linux-m68k-low.c (m68k_supports_hardware_single_step): New
6613 function.
6614 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6615
d1928160
PA
66162017-11-06 Pedro Alves <palves@redhat.com>
6617
6618 * config.in, configure: Regenerate.
6619
bac608e7
SM
66202017-10-27 Simon Marchi <simon.marchi@ericsson.com>
6621
6622 * target.c (struct thread_search): Remove.
6623 (thread_search_callback): Remove.
6624 (prepare_to_access_memory): Use for_each_thread instead of
6625 find_inferior. Inline code from thread_search_callback.
6626
eaddb425
SM
66272017-10-27 Simon Marchi <simon.marchi@ericsson.com>
6628
6629 * server.c (struct visit_actioned_threads_data): Remove.
6630 (visit_actioned_threads): Change prototype to take arguments
6631 directly.
6632 (resume): Use find_thread instead of find_inferior.
6633
99078d34
SM
66342017-10-27 Simon Marchi <simon.marchi@ericsson.com>
6635
6636 * server.c (queue_stop_reply_callback): Change prototype, return
6637 void.
6638 (find_status_pending_thread_callback): Remove.
6639 (handle_status): Replace find_inferior with find_thread and
6640 for_each_thread.
6641
cc628f3d
AH
66422017-10-25 Alan Hayward <alan.hayward@arm.com>
6643
6644 * linux-aarch64-low.c (aarch64_fill_gregset): Replace defines
6645 with REGNO.
6646 (aarch64_store_gregset): Likewise.
6647 (aarch64_fill_fpregset): Likewise.
6648 (aarch64_store_fpregset): Likewise.
6649
4d3bb80e
SM
66502017-10-21 Simon Marchi <simon.marchi@ericsson.com>
6651
6652 * gdbthread.h (find_thread, for_each_thread): New functions.
6653 * inferiors.c (thread_of_pid): Remove.
6654 (find_any_thread_of_pid): Use find_thread.
6655 * linux-low.c (num_lwps): Use for_each_thread.
6656
7a7cdfa0
YQ
66572017-10-17 Yao Qi <yao.qi@linaro.org>
6658
6659 * Makefile.in: Remove one rule.
6660 * configure.srv: Rename aarch64-insn.o with arch/aarch64-insn.o.
6661
e675d170
YQ
66622017-10-17 Yao Qi <yao.qi@linaro.org>
6663
6664 * configure.srv: Rename arm-linux.o with arch/arm-linux.o.
6665 Rename arm-get-next-pcs.o with arch/arm-get-next-pcs.o.
6666
7eb4e0f9
YQ
66672017-10-17 Yao Qi <yao.qi@linaro.org>
6668
6669 * configure.srv: Rename arm.o with arch/arm.o.
6670
60d6cfc9
YQ
66712017-10-17 Yao Qi <yao.qi@linaro.org>
6672
6673 * Makefile.in (CONFIG_SRC_SUBDIR): New variable.
6674 (clean): Remove .o files in CONFIG_SRC_SUBDIR.
6675 (distclean): Remove DEPDIR in CONFIG_SRC_SUBDIR.
6676 (arch-i386.o, arch-amd64.o): Remove rules.
6677 (arch/%.o): New rule.
6678 Update POSTCOMPILE and COMPILE.pre.
6679 * configure.ac: Invoke AC_CONFIG_COMMANDS.
6680 * configure: Re-generated.
6681 * configure.srv: Replace arch-i386.o with arch/i386.o.
6682 Replace arch-amd64.o with arch/amd64.o.
6683
5bfda255
YQ
66842017-10-16 Yao Qi <yao.qi@linaro.org>
6685
6686 * configure: Regenerated.
6687
9c80ecd6
SM
66882017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
6689
6690 * inferiors.h: (struct inferior_list): Remove.
6691 (struct inferior_list_entry); Remove.
6692 (add_inferior_to_list, clear_inferior_list, one_inferior_p,
6693 A_I_NEXT, ALL_INFERIORS_TYPE, ALL_INFERIORS, remove_inferior,
6694 get_first_inferior): Remove.
6695 (for_each_inferior, for_each_inferior_with_data, find_inferior,
6696 find_inferior_id, find_inferior_in_random): Change signature.
6697 * inferiors.c (all_threads): Change type to
6698 std::list<thread_info *>.
6699 (get_thread): Remove macro.
6700 (find_inferior, find_inferior_id): Change signature, implement
6701 using find_thread.
6702 (find_inferior_in_random): Change signature, implement using
6703 find_thread_in_random.
6704 (for_each_inferior, for_each_inferior_with_data): Change
6705 signature, implement using for_each_thread.
6706 (add_inferior_to_list, remove_inferior): Remove.
6707 (add_thread, get_first_thread, thread_of_pid,
6708 find_any_thread_of_pid, free_one_thread, remove_thread): Update.
6709 (get_first_inferior, one_inferior_p, clear_inferior_list):
6710 Remove.
6711 (clear_inferiors, get_thread_process): Update.
6712 * gdbthread.h: Include <list>.
6713 (struct thread_info) <entry>: Remove field.
6714 <id>: New field.
6715 (all_threads): Change type to std::list<thread_info *>.
6716 (get_first_inferior): Add doc.
6717 (find_thread, for_each_thread, find_thread_in_random): New
6718 functions.
6719 (current_ptid, pid_of, ptid_of, lwpid_of): Update.
6720 * linux-arm-low.c (update_registers_callback): Update.
6721 * linux-low.c (second_thread_of_pid_p): Update.
6722 (kill_one_lwp_callback, linux_detach_lwp_callback,
6723 delete_lwp_callback, status_pending_p_callback, same_lwp,
6724 find_lwp_pid, num_lwps, iterate_over_lwps_filter,
6725 iterate_over_lwps, not_stopped_callback,
6726 resume_stopped_resumed_lwps, count_events_callback,
6727 select_singlestep_lwp_callback, select_event_lwp_callback,
6728 unsuspend_one_lwp, linux_wait_1, send_sigstop_callback,
6729 suspend_and_send_sigstop_callback, wait_for_sigstop,
6730 stuck_in_jump_pad_callback, move_out_of_jump_pad_callback,
6731 lwp_running, linux_set_resume_request, resume_status_pending_p,
6732 need_step_over_p, start_step_over, linux_resume_one_thread,
6733 proceed_one_lwp, unsuspend_and_proceed_one_lwp,
6734 reset_lwp_ptrace_options_callback): Update.
6735 * linux-mips-low.c (update_watch_registers_callback): Update.
6736 * regcache.c (regcache_invalidate_one, regcache_invalidate):
6737 Update.
6738 (free_register_cache_thread_one): Remove.
6739 (regcache_release): Update.
6740 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt,
6741 handle_qxfer_threads_worker): Update.
6742 (handle_query): Update, use list iterator.
6743 (visit_actioned_threads, handle_pending_status,
6744 queue_stop_reply_callback, gdb_wants_all_threads_stopped,
6745 clear_pending_status_callback, set_pending_status_callback,
6746 find_status_pending_thread_callback, handle_status,
6747 process_serial_event): Update.
6748 * target.c (thread_search_callback): Update.
6749 * thread-db.c (thread_db_get_tls_address): Update.
6750 * tracepoint.c (tracepoint_finished_step, tracepoint_was_hit):
6751 Update.
6752 * win32-i386-low.c (update_debug_registers_callback): Update.
6753 * win32-low.c (delete_thread_info, child_delete_thread,
6754 continue_one_thread, suspend_one_thread,
6755 get_child_debug_event): Adjust.
6756
9179355e
SM
67572017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
6758
6759 * gdbthread.h (ptid_of, pid_of, lwpid_of): New functions.
6760 * inferiors.h: Include <list>.
6761 (struct process_info) <entry>: Remove field.
6762 <pid>: New field.
6763 (pid_of): Change macro to function.
6764 (ptid_of, lwpid_of): Remove macro.
6765 (all_processes): Change type to std::list<process_info *>.
6766 (ALL_PROCESSES): Remove macro.
6767 (for_each_process, find_process): New function.
6768 * inferiors.c (all_processes): Change type to
6769 std::list<process_info *>.
6770 (find_thread_process): Adjust.
6771 (add_process): Likewise.
6772 (remove_process): Likewise.
6773 (find_process_pid): Likewise.
6774 (get_first_process): Likewise.
6775 (started_inferior_callback): Remove.
6776 (have_started_inferiors_p): Adjust.
6777 (attached_inferior_callback): Remove.
6778 (have_attached_inferiors_p): Adjust.
6779 * linux-low.c (check_zombie_leaders): Likewise.
6780 * linux-x86-low.c (x86_arch_setup_process_callback): Remove.
6781 (x86_linux_update_xmltarget): Adjust.
6782 * server.c (handle_query): Likewise.
6783 (gdb_reattached_process): Remove.
6784 (handle_status): Adjust.
6785 (kill_inferior_callback): Likewise.
6786 (detach_or_kill_inferior): Remove.
6787 (print_started_pid): Likewise.
6788 (print_attached_pid): Likewise.
6789 (detach_or_kill_for_exit): Update.
6790 (process_serial_event): Likewise.
6791 * linux-arm-low.c (arm_new_fork): Likewise.
6792
c9cb8905
SM
67932017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
6794
6795 * dll.h: Include <list>.
6796 (struct dll_info): Add constructor.
6797 <entry>: Remove field.
6798 (all_dlls): Change type to std::list<dll_info>.
6799 * dll.c: Include <algorithm>.
6800 (get_dll): Remove macro.
6801 (all_dlls): Change type to std::list<dll_info *>.
6802 (free_one_dll): Remove.
6803 (match_dll): Likewise.
6804 (loaded_dll): Adjust.
6805 (unloaded_dll): Adjust to all_dlls type change, use
6806 std::find_if. Inline code from match_dll.
6807 (clear_dlls): Adjust to all_dlls type change.
6808 * server.c (emit_dll_description): Remove.
6809 (handle_qxfer_libraries): Adjust to all_dlls type change,
6810 integrate emit_dll_description's functionality.
6811
04ec7890
SM
68122017-10-12 Simon Marchi <simon.marchi@ericsson.com>
6813
6814 * linux-low.h (struct linux_target_ops) <delete_process>: New
6815 field.
6816 * linux-low.c (linux_mourn): Call the_low_target.delete_process.
6817 * linux-aarch64-low.c (aarch64_linux_delete_process): New.
6818 (struct linux_target_ops): Add delete_process callback.
6819 * linux-arm-low.c (arm_delete_process): New.
6820 (struct linux_target_ops): Add delete_process callback.
6821 * linux-bfin-low.c (struct linux_target_ops): Likewise.
6822 * linux-crisv32-low.c (struct linux_target_ops): Likewise.
6823 * linux-m32r-low.c (struct linux_target_ops): Likewise.
6824 * linux-mips-low.c (mips_linux_delete_process): New.
6825 (struct linux_target_ops): Add delete_process callback.
6826 * linux-ppc-low.c (struct linux_target_ops): Likewise.
6827 * linux-s390-low.c (struct linux_target_ops): Likewise.
6828 * linux-sh-low.c (struct linux_target_ops): Likewise.
6829 * linux-tic6x-low.c (struct linux_target_ops): Likewise.
6830 * linux-tile-low.c (struct linux_target_ops): Likewise.
6831 * linux-x86-low.c (x86_linux_delete_process): New.
6832 (struct linux_target_ops): Add delete_process callback.
6833 * linux-xtensa-low.c (struct linux_target_ops): Likewise.
6834
466eecee
SM
68352017-10-12 Simon Marchi <simon.marchi@ericsson.com>
6836
6837 * linux-aarch64-low.c (the_low_target): Add thread delete
6838 callback.
6839 * linux-arm-low.c (arm_delete_thread): New function.
6840 (the_low_target): Add thread delete callback.
6841 * linux-bfin-low.c (the_low_target): Likewise.
6842 * linux-crisv32-low.c (the_low_target): Likewise.
6843 * linux-low.c (delete_lwp): Invoke delete_thread callback if
6844 set.
6845 * linux-low.h (struct linux_target_ops) <delete_thread>: New
6846 field.
6847 * linux-m32r-low.c (the_low_target): Add thread delete callback.
6848 * linux-mips-low.c (mips_linux_delete_thread): New function.
6849 (the_low_target): Add thread delete callback.
6850 * linux-ppc-low.c (the_low_target): Likewise.
6851 * linux-s390-low.c (the_low_target): Likewise.
6852 * linux-sh-low.c (the_low_target): Likewise.
6853 * linux-tic6x-low.c (the_low_target): Likewise.
6854 * linux-tile-low.c (the_low_target): Likewise.
6855 * linux-x86-low.c (the_low_target): Likewise.
6856 * linux-xtensa-low.c (the_low_target): Likewise.
6857
b79f7801
YZ
68582017-10-06 Yuanhui Zhang <asmwarrior@gmail.com>
6859
6860 * win32-low.c: Include "common-inferior.h".
6861
bc3b087d
SDJ
68622017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
6863
6864 * inferiors.c (set_inferior_cwd): New function.
6865 * server.c (handle_general_set): Handle QSetWorkingDir packet.
6866 (handle_query): Inform that QSetWorkingDir is supported.
6867 * win32-low.c (create_process): Pass the inferior's cwd to
6868 CreateProcess.
6869
d092c5a2
SDJ
68702017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
6871
6872 * inferiors.c (current_inferior_cwd): New global variable.
6873 (get_inferior_cwd): New function.
6874 * inferiors.h (struct process_info) <cwd>: New field.
6875
7da0a886
SDJ
68762017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
6877
6878 * Makefile.in (SFILES): Add $(srcdir)/common/gdb_tilde_expand.c.
6879 (OBS): Add gdb_tilde_expand.o.
6880
289a6840
SM
68812017-10-02 Simon Marchi <simon.marchi@ericsson.com>
6882
6883 * lynx-i386-low.c (lynx_i386_arch_setup): Call init_target_desc.
6884 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
6885
256642e8
PA
68862017-09-29 Pedro Alves <palves@redhat.com>
6887
6888 * ax.c (gdb_parse_agent_expr): Constify.
6889 * ax.h (gdb_parse_agent_expr): Constify.
6890 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
6891 Constify.
6892 * mem-break.h (add_breakpoint_condition, add_breakpoint_commands): Constify.
6893 * remote-utils.c (hex_or_minus_one, read_ptid): Constify.
6894 * remote-utils.h (read_ptid): Constify.
6895 * server.c (handle_qxfer_exec_file, handle_query, handle_v_cont)
6896 (process_point_options, process_serial_event): Constify.
6897 * tracepoint.c (add_tracepoint_action, cmd_qtdp, cmd_qtdpsrc)
6898 (cmd_qtdv, cmd_qtenable_disable, cmd_qtro, cmd_qtframe, cmd_qtp)
6899 (cmd_qtbuffer): Constify.
6900
5b9ca4d4
PA
69012017-09-29 Pedro Alves <palves@redhat.com>
6902
6903 * proc-service.c (ps_pdread): Return PS_ERR if reading memory
6904 fails.
6905
94c207e0
PA
69062017-09-29 Pedro Alves <palves@redhat.com>
6907
6908 * linux-low.c (handle_extended_wait): Pass parent thread instead
6909 of process to thread_db_notice_clone.
6910 * linux-low.h (thread_db_notice_clone): Replace parent process
6911 parameter with parent thread parameter.
6912 * thread-db.c (find_one_thread): Add comment.
6913 (thread_db_notice_clone): Replace parent process parameter with
6914 parent thread parameter. Temporarily switch to the parent thread.
6915
75352e28
SDJ
69162017-09-26 Sergio Durigan Junior <sergiodj@redhat.com>
6917
6918 * gdbthread.h: Include "common-gdbthread.h".
6919 * inferiors.c (switch_to_thread): Use "gdb_assert" instead of
6920 "if" when validating the ptid.
6921 * remote-utils.c: Include "gdbthread.h".
6922 (prepare_resume_reply): Use "switch_to_thread".
6923 * target.c (done_accessing_memory): Likewise.
6924
ad339634
AA
69252017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
6926
6927 * configure.srv (s390*-*-linux*): Add s390-gs-linux64.o and
6928 s390x-gs-linux64.o to srv_regobj. Add s390-gs-linux64.xml,
6929 s390x-gs-linux64.xml, s390-gs.xml, and s390-gsbc.xml to
6930 srv_xmlfiles. Add s390-gs-linux64-ipa.o and
6931 s390x-gs-linux64-ipa.o to ipa_obj.
6932 * linux-s390-low.c (HWCAP_S390_GS): New define.
6933 (s390_fill_gs, s390_store_gs, s390_fill_gsbc, s390_store_gsbc):
6934 New functions.
6935 (s390_regsets): Add regsets for NT_S390_GS_CB and NT_S390_GS_BC.
6936 (s390_arch_setup): Check for guarded-storage support and choose
6937 appropriate tdesc.
6938 (initialize_low_arch): Invoke init_registers_s390_gs_linux64 and
6939 init_registers_s390x_gs_linux64.
6940 * linux-s390-tdesc.h (enum s390_linux_tdesc) <S390_TDESC_GS>: New
6941 enum value.
6942 (init_registers_s390x_gs_linux64, tdesc_s390x_gs_linux64)
6943 (init_registers_s390_gs_linux64, tdesc_s390_gs_linux64): Declare.
6944
cc4d742f
SM
69452017-09-22 Simon Marchi <simon.marchi@ericsson.com>
6946
6947 * win32-i386-low.c (i386_arch_setup): Call init_target_desc.
6948
f6327dcb
KB
69492017-09-21 Kevin Buettner <kevinb@redhat.com>
6950
6951 * linux-low.h (struct lwp_info): Add new field, thread_handle.
6952 (thread_db_thread_handle): Declare.
6953 * linux-low.c (linux_target_ops): Initialize thread_handle.
6954 * server.c (handle_qxfer_threads_worker): Add support for
6955 "handle" attribute.
6956 * target.h (struct target_ops): Add new function pointer,
6957 thread_handle.
6958 (target_thread_handle): Define.
6959 * thread-db.c (find_one_thread, attach_thread): Set thread_handle
6960 field in lwp.
6961 (thread_db_thread_handle): New function.
6962
86299109
KB
69632017-09-21 Kevin Buettner <kevinb@redhat.com>
6964
6965 * linux-low.c (handle_extended_wait): Call thread_db_notice_clone().
6966 * linux-low.h (thread_db_notice_clone): Declare.
6967 * thread-db.c (thread_db_notice_clone): New function.
6968
f557a88a
PA
69692017-09-21 Pedro Alves <palves@redhat.com>
6970
6971 * server.c (gdb_read_memory, handle_status, process_serial_event)
6972 (handle_serial_event, handle_target_event): Adjust to
6973 set_desired_thread prototype change.
6974 * target.c (set_desired_thread): Remove 'use_general' parameter
6975 and adjust.
6976 * target.h (set_desired_thread): Remove 'use_general' parameter.
6977
223ffa71
TT
69782017-09-20 Tom Tromey <tom@tromey.com>
6979
6980 * target.c (target_terminal::terminal_state): Define.
6981 (target_terminal::init): Rename from target_terminal_init.
6982 (target_terminal::inferior): Rename from
6983 target_terminal_inferior.
6984 (target_terminal::ours): Rename from target_terminal_ours.
6985 (target_terminal::ours_for_output, target_terminal::info): New.
6986
04fd3ba9
SM
69872017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6988
6989 * server.c (accumulate_file_name_length): Remove.
6990 (emit_dll_description): Adjust to std::string change.
6991 (handle_qxfer_libraries): Use std::string to hold document.
6992
5e187554
SM
69932017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6994
6995 * linux-low.c (linux_qxfer_libraries_svr4): Adjust to change of
6996 return type of xml_escape_text.
6997 * server.c (emit_dll_description): Likewise.
6998
1526853e
SM
69992017-09-16 Simon Marchi <simon.marchi@ericsson.com>
7000
7001 * server.c (captured_main): Accept argument for --selftest.
7002 Update run_tests call.
7003 * linux-x86-tdesc-selftest.c (initialize_low_tdesc): Add names
7004 when registering selftests.
7005
c4dfafab
SDJ
70062017-09-16 Sergio Durigan Junior <sergiodj@redhat.com>
7007
7008 * regcache.c (get_thread_regcache): Update code to use "std::vector"
7009 instead of "VEC" for "target_desc.reg_defs".
7010 (regcache_cpy): Likewise.
7011 (registers_to_string): Likewise.
7012 (registers_from_string): Likewise.
7013 (find_regno): Likewise.
7014 (supply_regblock): Likewise.
7015 (regcache_raw_read_unsigned): Likewise.
7016 * tdesc.c (init_target_desc): Likewise.
7017 (tdesc_create_reg): Likewise.
7018 * tdesc.h: Remove declaration of "tdesc_reg_p". Include <vector>.
7019 (struct target_desc) <reg_defs>: Convert to "std::vector".
7020 (target_desc): Do not initialize "reg_defs".
7021 (~target_desc): Update code to use "std::vector" instead of "VEC"
7022 for "target_desc.reg_defs".
7023 (operator==): Likewise.
7024
124aceb4
SM
70252017-09-15 Simon Marchi <simon.marchi@ericsson.com>
7026
7027 * inferiors.h (thread_to_gdb_id): Remove.
7028 * inferiors.c (thread_to_gdb_id): Remove.
7029 * server.c (handle_qxfer_threads_worker, handle_query): Adjust.
7030 * lynx-low.c (lynx_resume, lynx_wait_1, lynx_fetch_registers,
7031 lynx_store_registers, lynx_read_memory, lynx_write_memory):
7032 Likewise.
7033 * nto-low.c (nto_fetch_registers, nto_store_registers,
7034 nto_stopped_by_watchpoint, nto_stopped_data_address): Likewise.
7035
96cde54f
SM
70362017-09-15 Simon Marchi <simon.marchi@ericsson.com>
7037
7038 * inferiors.h (gdb_id_to_thread_id): Remove.
7039 * inferiors.c (gdb_id_to_thread_id): Remove.
7040 * server.c (process_serial_event): Adjust to gdb_id_to_thread_id
7041 removal. Move pid declaration closer to where it's used.
7042
e8ca139e
SM
70432017-09-15 Simon Marchi <simon.marchi@ericsson.com>
7044
7045 * server.c (handle_detach): New function.
7046 (process_serial_event): Move code out, call handle_detach.
7047
f8a4e119
SM
70482017-09-15 Simon Marchi <simon.marchi@ericsson.com>
7049
7050 * server.c (require_running): Rename to ...
7051 (require_running_or_return): ... this ...
7052 (require_running_or_break): ... and this.
7053 (handle_query, process_serial_event): Adjust.
7054
0eb0a407
SM
70552017-09-15 Simon Marchi <simon.marchi@ericsson.com>
7056
7057 * linux-low.c (linux_set_resume_request): Remove unused
7058 variables.
7059
785922a5
SM
70602017-09-15 Simon Marchi <simon.marchi@ericsson.com>
7061
7062 * server.c (first_thread_of): Remove.
7063 (process_serial_event): Replace usage of first_thread_of with
7064 find_any_thread_of_pid.
7065 * tracepoint.c (same_process_p): Remove.
7066 (gdb_agent_about_to_close): Replace usage of same_process_p with
7067 find_any_thread_of_pid.
7068 * linux-x86-low.c (same_process_callback): Remove.
7069 (x86_arch_setup_process_callback): Replace usage of
7070 same_process_callback with find_any_thread_of_pid.
7071 * thread-db.c (any_thread_of): Remove.
7072 (switch_to_process): Replace usage of any_thread_of with
7073 find_any_thread_of_pid.
7074 * inferiors.c (thread_pid_matches_callback): Remove.
7075 (find_thread_process): Adjust to use find_any_thread_of_pid.
7076
a059f00c
SDJ
70772017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
7078
7079 * regcache.c (get_thread_regcache): Guard calls to "memset"
e79be6e5 7080 with "!VEC_empty".
a059f00c 7081
cc397f3a
SDJ
70822017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
7083
7084 * linux-low.c (handle_extended_wait): Use
7085 "allocate_target_description" instead of "XNEW".
7086 * linux-x86-low.c (initialize_low_arch): Likewise.
7087
22916b07
YQ
70882017-09-05 Yao Qi <yao.qi@linaro.org>
7089
7090 * configure.srv (srv_i386_regobj): Remove.
7091 (srv_amd64_regobj): Remove.
7092 (srv_regobj): Set it to "" for x86 non-linux targets.
7093 * linux-x86-tdesc.c (i386_linux_read_description):
7094 * lynx-i386-low.c: Include x86-xstate.h and arch/i386.h.
7095 (init_registers_i386): Remove the declaration.
7096 (tdesc_i386): Remove the declaration.
7097 (lynx_i386_arch_setup): Call i386_create_target_description.
7098 * nto-x86-low.c: Likewise.
7099 * win32-i386-low.c [__x86_64__]: include arch/amd64.h.
7100 [!__x86_64__]: include arch/i386.h.
7101 (i386_arch_setup) [__x86_64__]: Call amd64_create_target_description.
7102
38602d55
YQ
71032017-09-05 Yao Qi <yao.qi@linaro.org>
7104
7105 * configure.srv (srv_amd64_linux_xmlfiles): Remove
7106 i386/amd64-XXX-linux from it.
7107
44b886ff
YQ
71082017-09-05 Yao Qi <yao.qi@linaro.org>
7109
7110 * configure.srv: Empty srv_amd64_linux_regobj if $development is
7111 false.
7112 (ipa_amd64_linux_regobj): Remove.
7113 (ipa_x32_linux_regobj): Remove.
7114
b4570e4b
YQ
71152017-09-05 Yao Qi <yao.qi@linaro.org>
7116
7117 * Makefile.in (arch-amd64.o): New rule.
7118 * configure.srv: Append arch-amd64.o.
7119 * linux-amd64-ipa.c: Include common/x86-xstate.h.
7120 (get_ipa_tdesc): Call amd64_linux_read_description.
7121 (initialize_low_tracepoint): Don't call init_registers_x32_XXX
7122 and init_registers_amd64_XXX.
7123 * linux-x86-low.c (x86_linux_read_description): Call
7124 amd64_linux_read_description.
7125 (x86_get_ipa_tdesc_idx): Call amd64_get_ipa_tdesc_idx.
7126 (initialize_low_arch): Don't call init_registers_x32_XXX and
7127 init_registers_amd64_XXX.
7128 * linux-x86-tdesc-selftest.c: Declare init_registers_amd64_XXX
7129 and tdesc_amd64_XXX.
7130 [__x86_64__] (amd64_tdesc_test): New function.
7131 (initialize_low_tdesc) [__x86_64__]: Call init_registers_x32_XXX
7132 and init_registers_amd64_XXX.
7133 * linux-x86-tdesc.c: Include arch/amd64.h.
7134 (xcr0_to_tdesc_idx): New function.
7135 (i386_linux_read_description): New function.
7136 (amd64_get_ipa_tdesc_idx): New function.
7137 * linux-x86-tdesc.h (amd64_get_ipa_tdesc_idx): Declare.
7138 (amd64_get_ipa_tdesc): Declare.
7139
d1f28ea2
YQ
71402017-09-05 Yao Qi <yao.qi@linaro.org>
7141
7142 * configure.srv (srv_i386_linux_xmlfiles): Remove
7143 i386/i386-XXX-linux.xml from it.
7144
25a93583
YQ
71452017-09-05 Yao Qi <yao.qi@linaro.org>
7146
7147 * configure.srv: Set srv_i386_linux_regobj empty if $development
7148 is false.
7149 * linux-i386-ipa.c (initialize_low_tracepoint): Don't call
7150 initialize_low_tdesc.
7151 * linux-x86-low.c (initialize_low_arch): Wrap initialize_low_tdesc
7152 with #if initialize_low_tdesc.
7153 * linux-x86-tdesc-selftest.c: New file.
7154 * linux-x86-tdesc.c: Move code to linux-x86-tdesc-selftest.c.
7155
5f035c07
YQ
71562017-09-05 Yao Qi <yao.qi@linaro.org>
7157
7158 * Makefile.in (arch-i386.o): New rule.
7159 * configure.srv (i[34567]86-*-linux*): Add arch-i386.o.
7160 (x86_64-*-linux*): Likewise.
7161 * linux-x86-tdesc.c: Don't include ../features/i386/32bit-XXX.c,
7162 include arch/i386.h.
7163 (i386_linux_read_description): Remove code and call
7164 i386_create_target_description.
7165 * tdesc.c (allocate_target_description): New function.
7166 * tdesc.h (set_tdesc_architecture): Remove declaration.
7167 (set_tdesc_osabi): Likewise.
7168
0abe8a89
YQ
71692017-09-05 Yao Qi <yao.qi@linaro.org>
7170
7171 * linux-x86-tdesc.c: Don't include <inttypes.h>.
7172 (i386_linux_read_description) [!IN_PROCESS_AGENT]: Call
7173 set_tdesc_architecture and set_tdesc_osabi. Remove code setting
7174 .xmltarget.
7175 * server.c (get_features_xml): Call tdesc_get_features_xml.
7176 * tdesc.c (set_tdesc_architecture): New function.
7177 (set_tdesc_osabi): New function.
7178 (tdesc_get_features_xml): New function.
7179 (tdesc_create_feature): Add an argument.
7180 * tdesc.h (struct target_desc) <features>: New field.
7181 <arch, osabi>: New field.
7182 (~target_desc): xfree features, arch, and osabi.
7183 (target_desc::oerator==): Don't compare .xmltarget.
7184 [!IN_PROCESS_AGENT] (set_tdesc_architecture): Declare.
7185 (set_tdesc_osabi): Likewise.
7186 (tdesc_get_features_xml): Likewise.
7187
0a188386
YQ
71882017-09-05 Yao Qi <yao.qi@linaro.org>
7189
7190 * linux-x86-tdesc.c: Include selftest.h.
7191 (i386_tdesc_test): New function.
7192 (initialize_low_tdesc): Call selftests::register_test.
7193 * tdesc.h: Include regdef.h.
7194 (target_desc): Override operator == and !=.
7195
f49ff000
YQ
71962017-09-05 Yao Qi <yao.qi@linaro.org>
7197
7198 * configure.srv (srv_tgtobj): Append linux-x86-tdesc.o.
7199 (ipa_obj): Likewise.
7200 * linux-i386-ipa.c: Include common/x86-xstate.h
7201 (get_ipa_tdesc): Call i386_linux_read_description.
7202 (initialize_low_tracepoint): Don't call init_registers_XXX
7203 functions, call initialize_low_tdesc instead.
7204 * linux-x86-low.c (x86_linux_read_description): Call
7205 i386_linux_read_description.
7206 (initialize_low_arch): Don't call init_registers_i386_XXX
7207 functions, call initialize_low_tdesc.
7208 * linux-x86-tdesc.c: New file.
7209 * linux-x86-tdesc.h (x86_linux_tdesc): New X86_TDESC_LAST.
7210 (i386_get_ipa_tdesc_idx): Declare.
7211 (i386_get_ipa_tdesc): Declare.
7212 (initialize_low_tdesc): Declare.
7213
2b68ef2f
YQ
72142017-09-05 Yao Qi <yao.qi@linaro.org>
7215
7216 * linux-x86-low.c (x86_get_ipa_tdesc_idx): Use X86_TDESC_MMX
7217 instead of 0.
7218
f7000548
YQ
72192017-09-05 Yao Qi <yao.qi@linaro.org>
7220
7221 * Makefile.in (IPA_OBJS): Add vec-ipa.o
7222 * regcache.c (get_thread_regcache): Use VEC_length.
7223 (init_register_cache): Likewise.
7224 (regcache_cpy): Likewise.
7225 (registers_to_string): Iterate reg_defs via VEC_iterate.
7226 (find_regno): Likewise.
7227 (find_register_by_number): Use VEC_index.
7228 (register_size): Call find_register_by_number.
7229 (register_data): Call find_register_by_number.
7230 (supply_regblock): Use VEC_length.
7231 (regcache_raw_read_unsigned): Likewise.
7232 * tdesc.c (init_target_desc): Iterate reg_defs via
7233 VEC_iterate.
7234 (default_description): Update initializer.
7235 (copy_target_description): Don't update field num_registers.
7236 * tdesc.h (struct target_desc) <reg_defs>: Change it to VEC.
7237 <num_registers>: Remove.
7238
50a421ac
SM
72392017-09-04 Simon Marchi <simon.marchi@ericsson.com>
7240
7241 * Makefile.in (.SECONDARY): Define target.
7242
23fdd69e
SM
72432017-09-03 Simon Marchi <simon.marchi@ericsson.com>
7244
7245 * linux-low.c (linux_wait_1): Adjust.
7246 * server.c (queue_stop_reply_callback): Adjust.
7247
0a2dde4a
SDJ
72482017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
7249
7250 * server.c (handle_general_set): Handle QEnvironmentHexEncoded,
7251 QEnvironmentUnset and QEnvironmentReset packets.
7252 (handle_query): Inform remote that QEnvironmentHexEncoded,
7253 QEnvironmentUnset and QEnvironmentReset are supported.
7254
6afd337d
SM
72552017-08-25 Simon Marchi <simon.marchi@ericsson.com>
7256
7257 * inferiors.h (inferior_target_data): Rename to ...
7258 (thread_target_data): ... this.
7259 (inferior_regcache_data): Rename to ...
7260 (thread_regcache_data): ... this.
7261 (set_inferior_regcache_data): Rename to ...
7262 (set_thread_regcache_data): ... this.
7263 * inferiors.c (inferior_target_data): Rename to ...
7264 (thread_target_data): ... this.
7265 (inferior_regcache_data): Rename to ...
7266 (thread_regcache_data): ... this.
7267 (set_inferior_regcache_data): Rename to ...
7268 (set_thread_regcache_data): ... this.
7269 (free_one_thread): Update.
7270 * linux-low.h (get_thread_lwp): Update.
7271 * regcache.c (get_thread_regcache): Update.
7272 (regcache_invalidate_thread): Update.
7273 (free_register_cache_thread): Update.
7274 * win32-i386-low.c (update_debug_registers_callback): Update.
7275 (win32_get_current_dr): Update.
7276 * win32-low.c (thread_rec): Update.
7277 (delete_thread_info): Update.
7278 (continue_one_thread): Update.
7279 (suspend_one_thread): Update.
7280
a160cc46
SM
72812017-08-24 Simon Marchi <simon.marchi@ericsson.com>
7282
7283 * inferiors.c (set_inferior_target_data): Remove.
7284 * inferiors.h (set_inferior_target_data): Remove.
7285
6d580b63
YQ
72862017-08-18 Yao Qi <yao.qi@linaro.org>
7287
7288 * Makefile.in (OBS): Add selftest.o.
7289 * configure.ac: AC_DEFINE GDB_SELF_TEST if $development.
7290 * configure, config.in: Re-generated.
7291 * server.c: Include common/sefltest.h.
7292 (captured_main): Handle option --selftest.
7293
f5a29eb0
YQ
72942017-08-09 Yao Qi <yao.qi@linaro.org>
7295
7296 * configure.srv (srv_i386_regobj): Remove i386-avx.o,
7297 i386-avx-avx512.o, i386-avx-mpx-avx512-pku.o, i386-mpx.o,
7298 i386-avx-mpx.o and i386-mmx.o.
7299 (srv_amd64_regobj): Remove amd64-avx.o, amd64-avx-avx512.o,
7300 amd64-avx-mpx-avx512-pku.o, amd64-mpx.o and amd64-avx-mpx.o.
7301 (srv_i386_xmlfiles): Remove i386/i386-avx.xml,
7302 i386/i386-avx-avx512.xml, i386/i386-avx-mpx-avx512-pku.xml,
7303 i386/i386-mpx.xml, i386/i386-avx-mpx.xml and i386/i386-mmx.xml.
7304 (srv_amd64_xmlfile):i386/amd64-avx.xml, i386/amd64-avx-avx512.xml,
7305 i386/amd64-avx-mpx-avx512-pku.xml, i386/amd64-mpx.xml,
7306 i386/amd64-avx-mpx.xml.
7307
57757c2f
YQ
73082017-08-09 Yao Qi <yao.qi@linaro.org>
7309
7310 * configure.srv (srv_amd64_regobj): Remove x32.o, x32-avx.o
7311 and x32-avx-avx512.o.
7312 (srv_amd64_xmlfiles): Remove i386/x32.xml, i386/x32-avx.xml
7313 i386/x32-avx-avx512.xml.
7314
229d26fc
SM
73152017-07-26 Simon Marchi <simon.marchi@ericsson.com>
7316
7317 * tracepoint.h (enum class fast_tpoint_collect_result): New
7318 enumeration.
7319 (fast_tracepoint_collecting): Change return type to
7320 fast_tpoint_collect_result.
7321 * tracepoint.c (fast_tracepoint_collecting): Likewise.
7322 * linux-low.h: Include tracepoint.h.
7323 (struct lwp_info) <collecting_fast_tracepoint>: Change type to
7324 fast_tpoint_collect_result.
7325 * linux-low.c (handle_tracepoints): Adjust.
7326 (linux_fast_tracepoint_collecting): Change return type to
7327 fast_tpoint_collect_result.
7328 (maybe_move_out_of_jump_pad, linux_wait_for_event_filtered,
7329 linux_wait_1, stuck_in_jump_pad_callback,
7330 lwp_signal_can_be_delivered, linux_resume_one_lwp_throw,
7331 proceed_one_lwp): Adjust to type change.
7332
2e1e43e1
YQ
73332017-07-10 Yao Qi <yao.qi@linaro.org>
7334
7335 * linux-x86-low.c (x86_linux_read_description): Re-indent the code.
7336
adc764e7
YQ
73372017-06-29 Yao Qi <yao.qi@linaro.org>
7338
7339 * tdesc.h (struct target_desc) [IN_PROCESS_AGENT] <expedite_regs>:
7340 Remove.
7341 [IN_PROCESS_AGENT] <xmltarget>: Likewise.
7342
a206891a
SM
73432017-06-20 Simon Marchi <simon.marchi@ericsson.com>
7344
7345 * Makefile.in (IPA_OBJS): Sort and format one item per line.
7346
9a6c7d9c
SDJ
73472017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
7348
7349 * linux-low.c (linux_create_inferior): Adjust code to access the
7350 environment information via 'gdb_environ' class.
7351 * lynx-low.c (lynx_create_inferior): Likewise.
7352 * server.c (our_environ): Make it an instance of 'gdb_environ'.
7353 (get_environ): Return a pointer to 'our_environ'.
7354 (captured_main): Initialize 'our_environ'.
7355 * server.h (get_environ): Adjust prototype.
7356 * spu-low.c (spu_create_inferior): Adjust code to access the
7357 environment information via 'gdb_environ' class.
7358
ae3e2ccf
SM
73592017-06-17 Simon Marchi <simon.marchi@ericsson.com>
7360
7361 * linux-low.c (linux_read_memory, linux_write_memory): Remove
7362 usage of "register" keyword.
7363
3e019bdc
SM
73642017-06-17 Simon Marchi <simon.marchi@ericsson.com>
7365
7366 * configure: Re-generate.
7367
8465943a
SM
73682017-06-17 Simon Marchi <simon.marchi@ericsson.com>
7369
7370 * configure: Re-generate.
7371
cf0dd6f0
SM
73722017-06-17 Simon Marchi <simon.marchi@ericsson.com>
7373
7374 * Makefile.in (COMPILE.pre): Add "-x c++".
7375
9845682b
SDJ
73762017-06-09 Sergio Durigan Junior <sergiodj@redhat.com>
7377
7378 * fork-child.c: Conditionally include <signal.h>.
7379
aefd8b33
SDJ
73802017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
7381
7382 * server.c (handle_general_set): Handle new packet
7383 "QStartupWithShell".
7384 (handle_query): Add "QStartupWithShell" to the list of supported
7385 packets.
7386 (gdbserver_usage): Add help text explaining the
7387 new "--startup-with-shell" and "--no-startup-with-shell" CLI
7388 options.
7389 (captured_main): Recognize and act upon the presence of the new
7390 CLI options.
7391
2090129c
SDJ
73922017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
7393 Pedro Alves <palves@redhat.com>
7394
7395 * Makefile.in (SFILES): Add "nat/fork-inferior.o".
7396 * configure: Regenerate.
7397 * configure.srv (srv_linux_obj): Add "fork-child.o" and
7398 "fork-inferior.o".
7399 (i[34567]86-*-lynxos*): Likewise.
7400 (spu*-*-*): Likewise.
7401 * fork-child.c: New file.
7402 * linux-low.c: Include "common-inferior.h", "nat/fork-inferior.h"
7403 and "environ.h".
7404 (linux_ptrace_fun): New function.
7405 (linux_create_inferior): Adjust function prototype to reflect
7406 change on "target.h". Adjust function code to use
7407 "fork_inferior".
7408 (linux_request_interrupt): Delete "signal_pid".
7409 * lynx-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
7410 (lynx_ptrace_fun): New function.
7411 (lynx_create_inferior): Adjust function prototype to reflect
7412 change on "target.h". Adjust function code to use
7413 "fork_inferior".
7414 * nto-low.c (nto_create_inferior): Adjust function prototype and
7415 code to reflect change on "target.h". Update comments.
7416 * server.c: Include "common-inferior.h", "nat/fork-inferior.h",
7417 "common-terminal.h" and "environ.h".
7418 (terminal_fd): Moved to fork-child.c.
7419 (old_foreground_pgrp): Likewise.
7420 (restore_old_foreground_pgrp): Likewise.
7421 (last_status): Make it global.
7422 (last_ptid): Likewise.
7423 (our_environ): New variable.
7424 (startup_with_shell): Likewise.
7425 (program_name): Likewise.
7426 (program_argv): Rename to...
7427 (program_args): ...this.
7428 (wrapper_argv): New variable.
7429 (start_inferior): Delete function.
7430 (get_exec_wrapper): New function.
7431 (get_exec_file): Likewise.
7432 (get_environ): Likewise.
7433 (prefork_hook): Likewise.
7434 (post_fork_inferior): Likewise.
7435 (postfork_hook): Likewise.
7436 (postfork_child_hook): Likewise.
7437 (handle_v_run): Update code to deal with arguments coming from the
7438 remote host. Update calls from "start_inferior" to
7439 "create_inferior".
7440 (captured_main): Likewise. Initialize environment variable. Call
7441 "have_job_control".
7442 * server.h (post_fork_inferior): New prototype.
7443 (get_environ): Likewise.
7444 (last_status): Declare.
7445 (last_ptid): Likewise.
7446 (signal_pid): Likewise.
7447 * spu-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
7448 (spu_ptrace_fun): New function.
7449 (spu_create_inferior): Adjust function prototype to reflect change
7450 on "target.h". Adjust function code to use "fork_inferior".
7451 * target.c (target_terminal_init): New function.
7452 (target_terminal_inferior): Likewise.
7453 (target_terminal_ours): Likewise.
7454 * target.h: Include <vector>.
7455 (struct target_ops) <create_inferior>: Update prototype.
7456 (create_inferior): Update macro.
7457 * utils.c (gdb_flush_out_err): New function.
7458 * win32-low.c (win32_create_inferior): Adjust function prototype
7459 and code to reflect change on "target.h".
7460
043a4934
SDJ
74612017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
7462
7463 * inferiors.c (switch_to_thread): New function.
7464
15652511
SDJ
74652017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
7466
7467 * Makefile.in (SFILE): Add "common/job-control.c".
7468 (OBS): Add "job-control.o".
7469
21ea5acd
SDJ
74702017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
7471
7472 * Makefile: Remove "@host_makefile_frag@".
7473
e13cb306
PA
74742017-05-05 Pedro Alves <palves@redhat.com>
7475
7476 * configure: Regenerate.
7477
c94fee56
SDJ
74782017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
7479
7480 * configure: Regenerate.
7481
a0ff9e1a
SM
74822017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
7483
7484 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Adjust to
7485 software_single_step change of return type to
7486 std::vector<CORE_ADDR>.
7487 * linux-low.c (install_software_single_step_breakpoints):
7488 Likewise.
7489 * linux-low.h (install_software_single_step_breakpoints):
7490 Likewise.
7491
be628ab8
SDJ
74922017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
7493
7494 * remote-utils.c: Include "gdb_termios.h" instead of
7495 "terminal.h".
7496 * terminal.h: Delete file.
7497
7c5ded6a
SDJ
74982017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
7499
7500 * server.c: Include <vector>.
7501 <program_argv, wrapper_argv>: Convert to std::vector.
7502 (start_inferior): Rewrite function to use C++.
7503 (handle_v_run): Likewise. Update code that calculates the argv
7504 based on the vRun packet; use C++.
7505 (captured_main): Likewise.
7506
436252de
SM
75072017-04-06 Simon Marchi <simon.marchi@ericsson.com>
7508
7509 * server.c (handle_v_cont): Initialize thread_resume::thread
7510 with null_ptid.
7511
9bf2a700
PA
75122017-04-05 Pedro Alves <palves@redhat.com>
7513
7514 * configure: Regenerate.
7515
a121b7c1
PA
75162017-04-05 Pedro Alves <palves@redhat.com>
7517
7518 * gdbreplay.c (sync_error): Constify.
7519 * linux-x86-low.c (push_opcode): Constify.
7520
21c8a587
PA
75212017-04-05 Pedro Alves <palves@redhat.com>
7522
7523 * win32-low.c (get_child_debug_event)
7524 <CREATE_PROCESS_DEBUG_EVENT>: Don't report TARGET_WAITKIND_EXECD.
7525 Report TARGET_WAITKIND_SPURIOUS instead.
7526
fb32b4f7
PA
75272017-04-05 Pedro Alves <palves@redhat.com>
7528
e79be6e5
SM
7529 * remote-utils.c (remote_prepare, remote_open): Constify.
7530 * remote-utils.h (remote_prepare, remote_open): Constify.
7531 * server.c (captured_main): Constify 'port' handling.
fb32b4f7 7532
65dd1e59
SM
75332017-04-04 Simon Marchi <simon.marchi@ericsson.com>
7534
7535 * Makefile.in (clean): Clear .deps.
7536
8fa5b777
SM
75372017-03-31 Simon Marchi <simon.marchi@polymtl.ca>
7538
7539 * .gitignore: Remove generated files, replace with wildcard.
7540 * (clean): Replace removal of generated files with wildcard.
7541 (version.c): Replace with...
7542 (version-generated.c): ...this.
7543 (xml-builtin.c): Replace with...
7544 (xml-builtin-generated.c): ...this.
7545 (%-ipa.o: %-generated.c, %.o: %-generated.c): New rules.
7546 (%.c: *regformats*): Replace with...
7547 (%-generated.c: *regformats*): ...this.
7548
a12e714b
MF
75492017-03-27 Max Filippov <jcmvbkbc@gmail.com>
7550
7551 * linux-xtensa-low.c (regnum::R_THREADPTR): New enum member.
7552 (xtensa_fill_gregset): Call collect_register_by_name for
7553 threadptr register.
7554 (xtensa_store_gregset): Call supply_register_by_name for
7555 threadptr register.
7556
1a09b50a
MF
75572017-03-27 Max Filippov <jcmvbkbc@gmail.com>
7558
7559 * linux-xtensa-low.c (xtensa_fill_gregset): Call collect_register
7560 for all registers in a0_regnum..a0_regnum + C0_NREGS range.
7561 (xtensa_store_gregset): Call supply_register for all registers in
7562 a0_regnum..a0_regnum + C0_NREGS range.
7563
1a01e7c6
SM
75642017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7565
7566 * Makefile.in (%-ipa.o: %-ipa.c): New rule.
7567 (ax-ipa.o: ax.c): Remove.
7568 (linux-i386-ipa.o: linux-i386-ipa.c): Remove.
7569 (linux-amd64-ipa.o: linux-amd64-ipa.c): Remove.
7570 (linux-aarch64-ipa.o: linux-aarch64-ipa.c): Remove.
7571 (linux-s390-ipa.o: linux-s390-ipa.c): Remove.
7572 (linux-ppc-ipa.o: linux-ppc-ipa.c): Remove.
7573
36bc18a8
SM
75742017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7575
7576 * Makefile.in (%-ipa.o: ../common/%.c): New rule.
7577 (print-utils-ipa.o: ../common/print-utils.c): Remove.
7578 (rsp-low-ipa.o: ../common/rsp-low.c): Remove.
7579 (errors-ipa.o: ../common/errors.c): Remove.
7580 (format-ipa.o: ../common/format.c): Remove.
7581 (common-utils-ipa.o: ../common/common-utils.c): Remove.
7582
a8ebe3d5
SM
75832017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7584
7585 * Makefile.in (%-ipa.o: %.c): New rule.
7586 (tracepoint-ipa.o: tracepoint.c): Remove.
7587 (utils-ipa.o: utils.c): Remove.
7588 (remote-utils-ipa.o: remote-utils.c): Remove.
7589 (regcache-ipa.o: regcache.c): Remove.
7590 (i386-linux-ipa.o: i386-linux.c): Remove.
7591 (i386-mmx-linux-ipa.o: i386-mmx-linux.c): Remove.
7592 (i386-avx-linux-ipa.o: i386-avx-linux.c): Remove.
7593 (i386-mpx-linux-ipa.o: i386-mpx-linux.c): Remove.
7594 (i386-avx-mpx-linux-ipa.o: i386-avx-mpx-linux.c): Remove.
7595 (i386-avx-avx512-linux-ipa.o: i386-avx-avx512-linux.c): Remove.
7596 (i386-avx-mpx-avx512-pku-linux-ipa.o: i386-avx-mpx-avx512-pku-linux.c): Remove.
7597 (amd64-linux-ipa.o: amd64-linux.c): Remove.
7598 (amd64-avx-linux-ipa.o: amd64-avx-linux.c): Remove.
7599 (amd64-mpx-linux-ipa.o: amd64-mpx-linux.c): Remove.
7600 (amd64-avx-mpx-linux-ipa.o: amd64-avx-mpx-linux.c): Remove.
7601 (amd64-avx-avx512-linux-ipa.o: amd64-avx-avx512-linux.c): Remove.
7602 (amd64-avx-mpx-avx512-pku-linux-ipa.o: amd64-avx-mpx-avx512-pku-linux.c): Remove.
7603 (aarch64-ipa.o: aarch64.c): Remove.
7604 (s390-linux32-ipa.o: s390-linux32.c): Remove.
7605 (s390-linux32v1-ipa.o: s390-linux32v1.c): Remove.
7606 (s390-linux32v2-ipa.o: s390-linux32v2.c): Remove.
7607 (s390-linux64-ipa.o: s390-linux64.c): Remove.
7608 (s390-linux64v1-ipa.o: s390-linux64v1.c): Remove.
7609 (s390-linux64v2-ipa.o: s390-linux64v2.c): Remove.
7610 (s390-te-linux64-ipa.o: s390-te-linux64.c): Remove.
7611 (s390-vx-linux64-ipa.o: s390-vx-linux64.c): Remove.
7612 (s390-tevx-linux64-ipa.o: s390-tevx-linux64.c): Remove.
7613 (s390x-linux64-ipa.o: s390x-linux64.c): Remove.
7614 (s390x-linux64v1-ipa.o: s390x-linux64v1.c): Remove.
7615 (s390x-linux64v2-ipa.o: s390x-linux64v2.c): Remove.
7616 (s390x-te-linux64-ipa.o: s390x-te-linux64.c): Remove.
7617 (s390x-vx-linux64-ipa.o: s390x-vx-linux64.c): Remove.
7618 (s390x-tevx-linux64-ipa.o: s390x-tevx-linux64.c): Remove.
7619 (powerpc-32l-ipa.o: powerpc-32l.c): Remove.
7620 (powerpc-altivec32l-ipa.o: powerpc-altivec32l.c): Remove.
7621 (powerpc-cell32l-ipa.o: powerpc-cell32l.c): Remove.
7622 (powerpc-vsx32l-ipa.o: powerpc-vsx32l.c): Remove.
7623 (powerpc-isa205-32l-ipa.o: powerpc-isa205-32l.c): Remove.
7624 (powerpc-isa205-altivec32l-ipa.o: powerpc-isa205-altivec32l.c): Remove.
7625 (powerpc-isa205-vsx32l-ipa.o: powerpc-isa205-vsx32l.c): Remove.
7626 (powerpc-e500l-ipa.o: powerpc-e500l.c): Remove.
7627 (powerpc-64l-ipa.o: powerpc-64l.c): Remove.
7628 (powerpc-altivec64l-ipa.o: powerpc-altivec64l.c): Remove.
7629 (powerpc-cell64l-ipa.o: powerpc-cell64l.c): Remove.
7630 (powerpc-vsx64l-ipa.o: powerpc-vsx64l.c): Remove.
7631 (powerpc-isa205-64l-ipa.o: powerpc-isa205-64l.c): Remove.
7632 (powerpc-isa205-altivec64l-ipa.o: powerpc-isa205-altivec64l.c): Remove.
7633 (powerpc-isa205-vsx64l-ipa.o: powerpc-isa205-vsx64l.c): Remove.
7634 (tdesc-ipa.o: tdesc.c): Remove.
7635 (x32-linux-ipa.o: x32-linux.c): Remove.
7636 (x32-avx-linux-ipa.o: x32-avx-linux.c): Remove.
7637 (x32-avx512-linux-ipa.o: x32-avx512-linux.c): Remove.
7638
50cfacb7
SM
76392017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7640
7641 * Makefile.in (%.o: ../arch/%.c): New rule.
7642 (arm.o: ../arch/arm.c): Remove.
7643 (arm-linux.o: ../arch/arm-linux.c): Remove.
7644 (arm-get-next-pcs.o: ../arch/arm-get-next-pcs.c): Remove.
7645 (aarch64-insn.o: ../arch/aarch64-insn.c): Remove.
7646
c5a22423
SM
76472017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7648
7649 * Makefile.in (%.o: ../nat/%.c): New rule.
7650 (x86-dregs.o: ../nat/x86-dregs.c): Remove.
7651 (amd64-linux-siginfo.o: ../nat/amd64-linux-siginfo.c): Remove.
7652 (linux-btrace.o: ../nat/linux-btrace.c): Remove.
7653 (linux-osdata.o: ../nat/linux-osdata.c): Remove.
7654 (linux-procfs.o: ../nat/linux-procfs.c): Remove.
7655 (linux-ptrace.o: ../nat/linux-ptrace.c): Remove.
7656 (linux-waitpid.o: ../nat/linux-waitpid.c): Remove.
7657 (mips-linux-watch.o: ../nat/mips-linux-watch.c): Remove.
7658 (ppc-linux.o: ../nat/ppc-linux.c): Remove.
7659 (linux-personality.o: ../nat/linux-personality.c): Remove.
7660 (aarch64-linux-hw-point.o: ../nat/aarch64-linux-hw-point.c): Remove.
7661 (aarch64-linux.o: ../nat/aarch64-linux.c): Remove.
7662 (x86-linux.o: ../nat/x86-linux.c): Remove.
7663 (x86-linux-dregs.o: ../nat/x86-linux-dregs.c): Remove.
7664 (linux-namespaces.o: ../nat/linux-namespaces.c): Remove.
7665
6bda016b
SM
76662017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7667
7668 * Makefile.in (%.o: ../common/%.c): New rule.
7669 (signals.o: ../common/signals.c): Remove.
7670 (print-utils.o: ../common/print-utils.c): Remove.
7671 (rsp-low.o: ../common/rsp-low.c): Remove.
7672 (common-utils.o: ../common/common-utils.c): Remove.
7673 (posix-strerror.o: ../common/posix-strerror.c): Remove.
7674 (mingw-strerror.o: ../common/mingw-strerror.c): Remove.
7675 (vec.o: ../common/vec.c): Remove.
7676 (gdb_vecs.o: ../common/gdb_vecs.c): Remove.
7677 (xml-utils.o: ../common/xml-utils.c): Remove.
7678 (ptid.o: ../common/ptid.c): Remove.
7679 (buffer.o: ../common/buffer.c): Remove.
7680 (format.o: ../common/format.c): Remove.
7681 (filestuff.o: ../common/filestuff.c): Remove.
7682 (agent.o: ../common/agent.c): Remove.
7683 (errors.o: ../common/errors.c): Remove.
7684 (environ.o: ../common/environ.c): Remove.
7685 (common-debug.o: ../common/common-debug.c): Remove.
7686 (cleanups.o: ../common/cleanups.c): Remove.
7687 (common-exceptions.o: ../common/common-exceptions.c): Remove.
7688 (fileio.o: ../common/fileio.c): Remove.
7689 (common-regcache.o: ../common/common-regcache.c): Remove.
7690 (signals-state-save-restore.o: ../common/signals-state-save-restore.c): Remove.
7691 (new-op.o: ../common/new-op.c): Remove.
7692 (btrace-common.o: ../common/btrace-common.c): Remove.
7693
21122961
SM
76942017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7695
7696 * Makefile.in (%.o: ../target/%.c): New rule.
7697 (waitstatus.o: ../target/waitstatus.c): Remove.
7698
c362e621
SM
76992017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7700
7701 * Makefile.in
7702 (%.c: ../regformats/%.dat,
7703 (%.c: ../regformats/arm/%.dat,
7704 (%.c: ../regformats/i386/%.dat,
7705 (%.c: ../regformats/rs6000/%.dat): New rules.
7706 (aarch64.c): Remove.
7707 (reg-arm.c): Remove.
7708 (arm-with-iwmmxt.c): Remove.
7709 (arm-with-vfpv2.c): Remove.
7710 (arm-with-vfpv3.c): Remove.
7711 (arm-with-neon.c): Remove.
7712 (reg-bfin.c): Remove.
7713 (reg-cris.c): Remove.
7714 (reg-crisv32.c): Remove.
7715 (i386.c): Remove.
7716 (i386-linux.c): Remove.
7717 (i386-avx.c): Remove.
7718 (i386-avx-linux.c): Remove.
7719 (i386-avx-avx512.c): Remove.
7720 (i386-avx-avx512-linux.c): Remove.
7721 (i386-mpx.c): Remove.
7722 (i386-mpx-linux.c): Remove.
7723 (i386-avx-mpx-avx512-pku.c): Remove.
7724 (i386-avx-mpx-avx512-pku-linux.c): Remove.
7725 (i386-avx-mpx.c): Remove.
7726 (i386-avx-mpx-linux.c): Remove.
7727 (i386-mmx.c): Remove.
7728 (i386-mmx-linux.c): Remove.
7729 (reg-ia64.c): Remove.
7730 (reg-m32r.c): Remove.
7731 (reg-m68k.c): Remove.
7732 (reg-cf.c): Remove.
7733 (mips-linux.c): Remove.
7734 (mips-dsp-linux.c): Remove.
7735 (mips64-linux.c): Remove.
7736 (mips64-dsp-linux.c): Remove.
7737 (nios2-linux.c): Remove.
7738 (powerpc-32.c): Remove.
7739 (powerpc-32l.c): Remove.
7740 (powerpc-altivec32l.c): Remove.
7741 (powerpc-cell32l.c): Remove.
7742 (powerpc-vsx32l.c): Remove.
7743 (powerpc-isa205-32l.c): Remove.
7744 (powerpc-isa205-altivec32l.c): Remove.
7745 (powerpc-isa205-vsx32l.c): Remove.
7746 (powerpc-e500l.c): Remove.
7747 (powerpc-64l.c): Remove.
7748 (powerpc-altivec64l.c): Remove.
7749 (powerpc-cell64l.c): Remove.
7750 (powerpc-vsx64l.c): Remove.
7751 (powerpc-isa205-64l.c): Remove.
7752 (powerpc-isa205-altivec64l.c): Remove.
7753 (powerpc-isa205-vsx64l.c): Remove.
7754 (s390-linux32.c): Remove.
7755 (s390-linux32v1.c): Remove.
7756 (s390-linux32v2.c): Remove.
7757 (s390-linux64.c): Remove.
7758 (s390-linux64v1.c): Remove.
7759 (s390-linux64v2.c): Remove.
7760 (s390-te-linux64.c): Remove.
7761 (s390-vx-linux64.c): Remove.
7762 (s390-tevx-linux64.c): Remove.
7763 (s390x-linux64.c): Remove.
7764 (s390x-linux64v1.c): Remove.
7765 (s390x-linux64v2.c): Remove.
7766 (s390x-te-linux64.c): Remove.
7767 (s390x-vx-linux64.c): Remove.
7768 (s390x-tevx-linux64.c): Remove.
7769 (tic6x-c64xp-linux.c): Remove.
7770 (tic6x-c64x-linux.c): Remove.
7771 (tic6x-c62x-linux.c): Remove.
7772 (reg-sh.c): Remove.
7773 (reg-sparc64.c): Remove.
7774 (reg-spu.c): Remove.
7775 (amd64.c): Remove.
7776 (amd64-linux.c): Remove.
7777 (amd64-avx.c): Remove.
7778 (amd64-avx-linux.c): Remove.
7779 (amd64-avx-avx512.c): Remove.
7780 (amd64-avx-avx512-linux.c): Remove.
7781 (amd64-mpx.c): Remove.
7782 (amd64-mpx-linux.c): Remove.
7783 (amd64-avx-mpx-avx512-pku.c): Remove.
7784 (amd64-avx-mpx-avx512-pku-linux.c): Remove.
7785 (amd64-avx-mpx.c): Remove.
7786 (amd64-avx-mpx-linux.c): Remove.
7787 (x32.c): Remove.
7788 (x32-linux.c): Remove.
7789 (x32-avx.c): Remove.
7790 (x32-avx-linux.c): Remove.
7791 (x32-avx-avx512.c): Remove.
7792 (x32-avx-avx512-linux.c): Remove.
7793 (reg-xtensa.c): Remove.
7794 (reg-tilegx.c): Remove.
7795 (reg-tilegx32.c): Remove.
7796
1672e0d9
SDJ
77972017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
7798
7799 * Makefile.in (SFILES): Add "common/environ.c".
7800 (OBJS): Add "common/environ.h".
7801
239b6d10
WT
78022017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
7803
7804 * configure.ac: Check if the fs_base and gs_base members of
7805 `struct user_regs_struct' exist.
7806 * config.in: Regenerated.
7807 * configure: Likewise.
7808
694b382c
AT
78092017-01-09 Antoine Tremblay <antoine.tremblay@ericsson.com>
7810
7811 * linux-aarch32-low.c (arm_breakpoint_kind_from_pc): Use
7812 target_read_memory.
7813 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer): Likewise.
7814 (get_next_pcs_syscall_next_pc): Likewise.
7815
7dc53023
LM
78162016-12-23 Luis Machado <lgustavo@codesourcery.com>
7817
7818 * win32-i386-low.c: Fix incorrect reference to a couple source files.
7819 * nto-x86-low.c: Likewise.
7820
ad02e4fe
SM
78212016-11-30 Simon Marchi <simon.marchi@polymtl.ca>
7822
7823 * Makefile.in: Include disable-implicit-rules.mk.
7824
dcb07cfa
PA
78252016-11-23 Pedro Alves <palves@redhat.com>
7826
7827 * debug.c: Include <chrono> instead of "gdb_sys_time.h".
7828 (debug_vprintf): Use std::chrono::steady_clock instead of
7829 gettimeofday. Use '.' instead of ':'.
7830 * tracepoint.c: Include <chrono> instead of "gdb_sys_time.h".
7831 (get_timestamp): Use std::chrono::steady_clock instead of
7832 gettimeofday.
7833
8629c02c
SM
78342016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
7835
7836 * Makefile.in: Fix whitespace formatting.
7837
b593ecca
SM
78382016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
7839
7840 * Makefile.in (SFILES, OBS): Flatten list and order
7841 alphabetically.
7842
9986ba08
PA
78432016-11-23 Pedro Alves <palves@redhat.com>
7844
7845 * event-loop.c (handle_file_event): Use warning.
7846 * linux-low.c (linux_resume_one_lwp_throw): Use warning.
7847 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
7848 Use warning.
7849
4eefa7bc
PA
78502016-11-23 Pedro Alves <palves@redhat.com>
7851
7852 * linux-low.c (check_zombie_leaders): Use debug_printf for debug
7853 output.
7854 * notif.c (handle_notif_ack, notif_event_enque): Likewise.
7855 * remote-utils.c (putpkt_binary_1, readchar, getpkt): Use
7856 debug_printf and debug_flush for debug output.
7857 * server.c (handle_general_set): Likewise.
7858 * thread-db.c (try_thread_db_load): Use debug_printf for debug
7859 output.
7860
5443506e
SM
78612016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
7862
7863 * Makefile.in (.c.o): Replace rule with ...
7864 (%.o: %.c): ... this one.
7865
3b165252
SM
78662016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
7867
7868 * Makefile.in: Remove @GMAKE_TRUE@ prefixes and removes lines
7869 prefixed with @GMAKE_FALSE@. Update comment related to non-GNU
7870 make.
7871 * configure.ac: Remove checks for the make program.
7872 * configure: Re-generate.
7873
0bcda685
PA
78742016-10-28 Pedro Alves <palves@redhat.com>
7875
7876 * Makefile.in (CXX_DIALECT): Get from configure.
7877 (COMPILE.pre, CC_LD): Append $(CXX_DIALECT).
7878 * acinclude.m4: Include ../ax_cxx_compile_stdcxx.m4.
7879 * configure.ac: Call AX_CXX_COMPILE_STDCXX.
7880 * config.in: Regenerate.
7881 * configure: Regenerate.
7882
c3805894
YQ
78832016-10-27 Yao Qi <yao.qi@linaro.org>
7884
7885 * linux-low.c (linux_supports_range_stepping): Return true if
7886 can_software_single_step return true.
7887
89342618
YQ
78882016-10-27 Yao Qi <yao.qi@linaro.org>
7889
7890 * inferiors.c (find_inferior_in_random): New function.
7891 * inferiors.h (find_inferior_in_random): Declare.
7892 * linux-low.c (linux_wait_for_event_filtered): Call
7893 find_inferior_in_random instead of find_inferior.
7894
e3652c84
YQ
78952016-10-27 Yao Qi <yao.qi@linaro.org>
7896
7897 * linux-low.c (linux_wait_1): If single-step breakpoints are
7898 inserted, remove them.
7899
5a04c4cf
PA
79002016-10-26 Pedro Alves <palves@redhat.com>
7901
7902 * linux-low.c (handle_extended_wait): Link parent/child fork
7903 threads.
7904 (linux_wait_1): Unlink them.
7905 (linux_set_resume_request): Ignore resume requests for
7906 already-resumed and unhandled fork child threads.
7907 * linux-low.h (struct lwp_info) <fork_relative>: New field.
7908 * server.c (in_queued_stop_replies_ptid, in_queued_stop_replies):
7909 New functions.
7910 (handle_v_requests) <vCont>: Don't call require_running.
7911 * server.h (in_queued_stop_replies): New declaration.
7912
cb93dc7f
YQ
79132016-10-24 Yao Qi <yao.qi@linaro.org>
7914
7915 PR server/20733
7916 * linux-aarch64-low.c (append_insns): Cast the return value to
7917 'uint32_t *'.
7918
a1078bea
YQ
79192016-10-10 Yao Qi <yao.qi@linaro.org>
7920
7921 * linux-aarch32-low.c (enum arm_breakpoint_kinds): Remove.
7922
1fb77080
SDJ
79232016-10-06 Sergio Durigan Junior <sergiodj@redhat.com>
7924
7925 * target.c (target_supports_multi_process): New function, moved
7926 from...
7927 * target.h (target_supports_multi_process): ... here. Remove
7928 macro.
7929
39b5a3b9
TT
79302016-10-05 Tom Tromey <tom@tromey.com>
7931
7932 PR remote/20655:
7933 * tracepoint.c (handle_tracepoint_bkpts): Check
7934 ipa_error_tracepoint, not ipa_stopping_tracepoint.
7935
c1d0b70a
YQ
79362016-10-05 Yao Qi <yao.qi@linaro.org>
7937
7938 * configure.srv: Update the path of arm-*.xml files.
7939
0a69eedb
YQ
79402016-10-05 Terry Guo <terry.guo@arm.com>
7941 Yao Qi <yao.qi@linaro.org>
7942
7943 * Makefile.in: Adjust the path of rules.
7944 * configure.srv: Update the path of xml files.
7945 * regformats/arm-with-iwmmxt.dat: Regenerated.
7946 * regformats/arm-with-neon.dat: Likewise.
7947 * regformats/arm-with-vfpv2.dat: Likewise.
7948 * regformats/arm-with-vfpv3.dat Likewise.
7949
17e16485
YQ
79502016-09-30 Yao Qi <yao.qi@linaro.org>
7951
7952 PR gdbserver/20627
7953 * target.c (target_stop_and_wait): Don't call
7954 target_continue_no_signal, use resume_stop instead.
7955
edeeb602
YQ
79562016-09-26 Yao Qi <yao.qi@linaro.org>
7957
7958 * linux-low.c (linux_wait_1): Call debug_exit.
7959
503b1c39
PA
79602016-09-23 Pedro Alves <palves@redhat.com>
7961
7962 * Makefile.in (SFILES): Add common/new-op.c.
7963 (OBS): Add common/new-op.o.
7964 (new-op.o): New rule.
7965
74172ecf
SM
79662016-09-21 Simon Marchi <simon.marchi@ericsson.com>
7967
7968 * .gitinore: Ignore more files.
7969
fc6cda2e
YQ
79702016-09-21 Yao Qi <yao.qi@linaro.org>
7971
7972 * linux-aarch32-low.c (arm_fill_gregset): Keep bits 20 to
7973 23.
7974
bc1e6c81
SDJ
79752016-09-19 Sergio Durigan Junior <sergiodj@redhat.com>
7976
7977 * server.c (start_inferior): Call target_mourn_inferior instead of
7978 mourn_inferior; pass ptid_t argument to it.
7979 (resume): Likewise.
7980 (handle_target_event): Likewise.
7981 * target.c (target_mourn_inferior): New function.
7982 * target.h (mourn_inferior): Delete macro.
7983
0e00e962
AA
79842016-09-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
7985
7986 * linux-low.c (lwp_is_stepping): New function.
7987
1d8cb77d
CL
79882016-09-06 Carl Love <cel@us.ibm.com>
7989
7990 * server.c (start_inferior): Fixed comment, requested comment change
7991 didn't get updated correctly. Removed reference to ptrace () call as
7992 it is only true on Linux systems.
7993
7313bced
CL
79942016-09-06 Carl Love <cel@us.ibm.com>
7995
7996 * server.c (start_inferior): Do not call
7997 function target_post_create_inferior () if the
7998 inferior process has already exited.
7999
cf6de44d
PA
80002016-09-05 Pedro Alves <palves@redhat.com>
8001
8002 * Makefile.in (COMPILER, COMPILER_CFLAGS): Remove.
8003 (COMPILE.pre, CC_LD): Use CXX directly.
8004 (INTERNAL_CFLAGS_BASE): Use CXXFLAGS directly.
8005 * acinclude.m4: Don't include build-with-cxx.m4.
8006 * configure.ac: Remove GDB_AC_BUILD_WITH_CXX call.
8007 * configure: Regenerate.
8008
c1da6748
AT
80092016-09-02 Akash Trehan <akash.trehan123@gmail.com>
8010
8011 PR gdb/19495
8012 * remote-utils.c (relocate_instruction): Remove redundant strcpy()
8013 call writing data to own_buf.
8014
f2b9e3df
SDJ
80152016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
8016
8017 * target.c (mywait): Call target_wait instead of
8018 the_target->wait.
8019 (target_wait): New function.
8020
049a8570
SDJ
80212016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
8022
8023 * server.c (start_inferior): New variable 'ptid'. Replace calls
8024 to the_target->resume by target_continue{,_no_signal}, depending
8025 on the case.
8026 * target.c (target_stop_and_wait): Call target_continue_no_signal
8027 instead of the_target->resume.
8028 (target_continue): New function.
8029
3aa5cfa0
AT
80302016-08-31 Antoine Tremblay <antoine.tremblay@ericsson.com>
8031
8032 * linux-low.c (linux_wait_1): Move event switch after unsuspend_lwps.
8033
754653a7
AZ
80342016-08-25 Adhemerval Zanella <adhemerval.zanella@linaro.org>
8035
8036 PR server/20491
8037 * gdb_proc_service.h (ps_get_thread_area): Remove const from struct
8038 ps_prochandle.
8039 * linux-aarch64-low.c (ps_get_thread_area): Likewise.
8040 * linux-arm-low.c (ps_get_thread_area): Likewise.
8041 * linux-crisv32-low.c (ps_get_thread_area): Likewise.
8042 * linux-m68k-low.c (ps_get_thread_area): Likewise.
8043 * linux-mips-low.c (ps_get_thread_area): Likewise.
8044 * linux-nios2-low.c (ps_get_thread_area): Likewise.
8045 * linux-tic6x-low.c (ps_get_thread_area): Likewise.
8046 * linux-x86-low.c (ps_get_thread_area): Likewise.
8047 * linux-xtensa-low.c (ps_get_thread_area): Likewise.
8048
ed036b40
PA
80492016-08-19 Pedro Alves <palves@redhat.com>
8050
8051 * linux-x86-low.c (amd64_emit_call): Emit missing call opcode.
8052
c8ef42ee
PA
80532016-08-19 Pedro Alves <palves@redhat.com>
8054
8055 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Fix
8056 comment. Use memcpy instead of casting through unsigned long.
8057
9c235a72
PA
80582016-08-19 Pedro Alves <palves@redhat.com>
8059
8060 * linux-amd64-ipa.c (alloc_jump_pad_buffer) [__ILP32__]: Try
8061 allocating around 0x80000000.
8062
201506da
PA
80632016-08-19 Pedro Alves <palves@redhat.com>
8064
8065 PR gdb/20415
8066 * Makefile.in (x32-linux-ipa.o, x32-avx-linux-ipa.o)
8067 (x32-avx512-linux-ipa.o): New rules.
8068 * configure.ac (x86_64-*-linux*): New x32 check.
8069 * configure.srv (ipa_x32_linux_regobj): New.
8070 (x86_64-*-linux*): Use $ipa_x32_linux_regobj if building for x32.
8071 * linux-amd64-ipa.c (get_ipa_tdesc) [__ILP32__]: Return x32
8072 descriptions.
8073 (initialize_low_tracepoint) [__ILP32__]: Initialize x32
8074 descriptions.
8075 * configure: Regenerate.
8076
f348d89a
PA
80772016-08-09 Pedro Alves <palves@redhat.com>
8078
8079 PR gdb/18653
8080 * Makefile.in (OBS): Add signals-state-save-restore.o.
8081 (signals-state-save-restore.o): New rule.
8082 * config.in: Regenerate.
8083 * configure: Regenerate.
8084 * linux-low.c: Include "signals-state-save-restore.h".
8085 (linux_create_inferior): Call
8086 restore_original_signals_state.
8087 * server.c: Include "dispositions-save-restore.h".
8088 (captured_main): Call save_original_signals_state.
8089
1baf5149
PA
80902016-08-05 Pedro Alves <palves@redhat.com>
8091
8092 * configure: Regenerate.
8093
fcd4a73d
YQ
80942016-08-04 Yao Qi <yao.qi@linaro.org>
8095
8096 * linux-low.c (regsets_fetch_inferior_registers): Check
8097 errno is ESRCH or not.
8098
979659d0
YQ
80992016-08-02 Yao Qi <yao.qi@linaro.org>
8100
8101 * thread-db.c (struct thread_db) <td_ta_event_getmsg_p>: Remove.
8102 <td_ta_set_event_p, td_ta_event_addr_p>: Remove.
8103 (thread_db_load_search): Update.
8104 (try_thread_db_load_1): Don't look for td_ta_event_addr,
8105 td_ta_set_event and td_ta_event_getmsg.
8106
6598661d
PA
81072016-07-26 Pedro Alves <palves@redhat.com>
8108
8109 PR server/20414
8110 * linux-x86-low.c (x86_get_pc, x86_set_pc): Use uint64_t instead
8111 of unsigned long for 64-bit registers and use uint32_t instead of
8112 unsigned int for 32-bit registers.
8113
9cf12d57
PA
81142016-07-26 Pedro Alves <palves@redhat.com>
8115
8116 * linux-x86-low.c (x86_siginfo_fixup): Rename 'native' parameter
8117 to 'ptrace'.
8118
305450ed
TT
81192016-07-21 Tom Tromey <tom@tromey.com>
8120
8121 * configure: Rebuild.
8122
2583da7c
YQ
81232016-07-21 Yao Qi <yao.qi@linaro.org>
8124
8125 * mem-break.c (find_gdb_breakpoint): Cast bp to
8126 'struct gdb_breakpoint *' rather than 'gdb_breakpoint *'.
8127
21536b36
YQ
81282016-07-21 Yao Qi <yao.qi@linaro.org>
8129
8130 * server.c (handle_v_requests): Support s and S actions
8131 if target_supports_software_single_step return true.
8132
8901d193
YQ
81332016-07-21 Yao Qi <yao.qi@linaro.org>
8134
8135 * linux-low.c (resume_stopped_resumed_lwps): If resume request
8136 is resume_step, call maybe_hw_step.
8137 (linux_wait_1): Stop all threads, remove reinsert breakpoints,
8138 and unstop them.
8139 (linux_resume_one_lwp_throw): Don't assert the thread has reinsert
8140 breakpoints or not.
8141 (proceed_one_lwp): If resume request is resume_step, install
8142 reinsert breakpoints and call maybe_hw_step.
8143
0e9a339e
YQ
81442016-07-21 Yao Qi <yao.qi@linaro.org>
8145
8146 * linux-low.c (proceed_one_lwp): Declare.
8147 (linux_resume_one_thread): Remove local variable 'step'.
8148 Lift code enqueue signal. Call proceed_one_lwp instead of
8149 linux_resume_one_lwp.
8150
4281b351
YQ
81512016-07-21 Yao Qi <yao.qi@linaro.org>
8152
8153 * linux-low.c (linux_resume_one_thread): Call
8154 enqueue_pending_signal.
8155
984a2c04
YQ
81562016-07-21 Yao Qi <yao.qi@linaro.org>
8157
8158 * gdbthread.h (make_cleanup_restore_current_thread): Declare.
8159 * inferiors.c (do_restore_current_thread_cleanup): New function.
8160 (make_cleanup_restore_current_thread): Likewise.
8161 * linux-low.c (install_software_single_step_breakpoints): Call
8162 make_cleanup_restore_current_thread. Switch current_thread to
8163 thread.
8164
bec903c9
YQ
81652016-07-21 Yao Qi <yao.qi@linaro.org>
8166
8167 * mem-break.c (struct reinsert_breakpoint) <ptid>: New field.
8168 (set_reinsert_breakpoint): New parameter ptid. Callers updated.
8169 (clone_one_breakpoint): Likewise.
8170 (delete_reinsert_breakpoints): Change parameter to thread.
8171 Callers updated.
8172 (has_reinsert_breakpoints): Likewise.
8173 (uninsert_reinsert_breakpoints): Likewise.
8174 (reinsert_reinsert_breakpoints): Likewise.
8175 * mem-break.h (set_reinsert_breakpoint): Update declaration.
8176 (delete_reinsert_breakpoints): Likewise.
8177 (reinsert_reinsert_breakpoints): Likewise.
8178 (uninsert_reinsert_breakpoints): Likewise.
8179 (has_reinsert_breakpoints): Likewise.
8180
63c40ec7
YQ
81812016-07-21 Yao Qi <yao.qi@linaro.org>
8182
8183 * inferiors.c (get_thread_process): Make parameter const.
8184 * inferiors.h (get_thread_process): Update declaration.
8185 * mem-break.c (clone_all_breakpoints): Remove all parameters.
8186 Add new parameters child_thread and parent_thread. Callers
8187 updated.
8188 * mem-break.h (clone_all_breakpoints): Update declaration.
8189
9aa76cd0
YQ
81902016-07-21 Yao Qi <yao.qi@linaro.org>
8191
8192 * mem-break.c (struct breakpoint) <cond_list>: Remove.
8193 <command_list, handler>: Remove.
8194 (struct gdb_breakpoint): New.
8195 (struct other_breakpoint): New.
8196 (struct reinsert_breakpoint): New.
8197 (is_gdb_breakpoint): New function.
8198 (any_persistent_commands): Update command_list if
8199 is_gdb_breakpoint returns true.
8200 (set_breakpoint): Create breakpoints according to their types.
8201 (find_gdb_breakpoint): Return 'struct gdb_breakpoint *'.
8202 (set_gdb_breakpoint_1): Likewise.
8203 (set_gdb_breakpoint): Likewise.
8204 (clear_breakpoint_conditions): Change parameter type to
8205 'struct gdb_breakpoint *'.
8206 (clear_breakpoint_commands): Likewise.
8207 (clear_breakpoint_conditions_and_commands): Likewise.
8208 (add_condition_to_breakpoint): Likewise.
8209 (add_breakpoint_condition): Likewise.
8210 (add_commands_to_breakpoint): Likewise.
8211 (check_breakpoints): Check other_breakpoint.
8212 (clone_one_breakpoint): Clone breakpopint according to its type.
8213 * mem-break.h (struct gdb_breakpoint): Declare.
8214 (set_gdb_breakpoint): Update declaration.
8215 (clear_breakpoint_conditions_and_commands): Likewise.
8216 (add_breakpoint_condition): Likewise.
8217 (add_breakpoint_commands): Likewise.
8218 * server.c (process_point_options): Change parameter type to
8219 'struct gdb_breakpoint *'.
8220
811f8301
YQ
82212016-07-21 Yao Qi <yao.qi@linaro.org>
8222
8223 * mem-break.c (set_breakpoint_at): Rename it to ...
8224 (set_breakpoint_type_at): ... it.
8225 (set_breakpoint_at): Call set_breakpoint_type_at.
8226 (set_reinsert_breakpoint): Call set_breakpoint_type_at.
8227 * mem-break.h (set_breakpoint_at): Update comments.
8228
b1c51e36
CLT
82292016-07-12 Chung-Lin Tang <cltang@codesourcery.com>
8230
8231 * linux-nios2-low.c (nios2_fill_gregset): Add type cast
8232 to buf parameter.
8233 (nios2_store_gregset): Likewise.
8234
ced2dffb
PA
82352016-07-01 Pedro Alves <palves@redhat.com>
8236 Antoine Tremblay <antoine.tremblay@ericsson.com>
8237
8238 * linux-low.c: Change interface to take the target lwp_info
8239 pointer directly and return void. Handle detaching from a zombie
8240 thread.
8241 (linux_detach_lwp_callback): New function.
8242 (linux_detach): Detach from the leader thread after detaching from
8243 the clone threads.
8244
2ac09a5b
YQ
82452016-06-28 Yao Qi <yao.qi@linaro.org>
8246
8247 * linux-aarch64-low.c (aarch64_ftrace_insn_reloc_b): Use int64_t
8248 for variable new_offset.
8249 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
8250 (aarch64_ftrace_insn_reloc_cb): Likewise.
8251 (aarch64_ftrace_insn_reloc_tb): Likewise.
8252 (aarch64_install_fast_tracepoint_jump_pad): Likewise. Use
8253 PRIx64 instead of PRIx32.
8254
79e7fd4f
YQ
82552016-06-28 Yao Qi <yao.qi@linaro.org>
8256
8257 * linux-arm-low.c (arm_get_syscall_trapinfo): New function.
8258 (the_low_target): Install arm_get_syscall_trapinfo.
8259
061fc021
YQ
82602016-06-28 Yao Qi <yao.qi@linaro.org>
8261
8262 * linux-aarch64-low.c (aarch64_get_syscall_trapinfo): New
8263 function.
8264 (the_low_target): Install aarch64_get_syscall_trapinfo.
8265
4cc32bec
YQ
82662016-06-28 Yao Qi <yao.qi@linaro.org>
8267
8268 * linux-low.c (get_syscall_trapinfo): Remove parameter sysret.
8269 Callers updated.
8270 * linux-low.h (struct linux_target_ops) <get_syscall_trapinfo>:
8271 Remove parameter sysno.
8272 * linux-x86-low.c (x86_get_syscall_trapinfo): Remove parameter
8273 sysret.
8274
782c1122
AA
82752016-06-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
8276
8277 * linux-s390-low.c (s390_emit_eq_goto): Mark function static.
8278 (s390_emit_ne_goto): Likewise.
8279 (s390_emit_lt_goto): Likewise.
8280 (s390_emit_le_goto): Likewise.
8281 (s390_emit_gt_goto): Likewise.
8282 (s390_emit_ge_goto): Likewise.
8283 (s390x_emit_eq_goto): Likewise.
8284 (s390x_emit_ne_goto): Likewise.
8285 (s390x_emit_lt_goto): Likewise.
8286 (s390x_emit_le_goto): Likewise.
8287 (s390x_emit_gt_goto): Likewise.
8288 (s390x_emit_ge_goto): Likewise.
8289 (s390_emit_ops_impl): Mark variable static.
8290 (s390x_emit_ops): Likewise.
8291
2e7b624b
YQ
82922016-06-17 Yao Qi <yao.qi@linaro.org>
8293
8294 * linux-low.c (handle_extended_wait): Call
8295 uninsert_reinsert_breakpoints for the parent process. Remove
8296 reinsert breakpoints from the child process. Reinsert them to
8297 the parent process when vfork is done.
8298 * mem-break.c (uninsert_reinsert_breakpoints): New function.
8299 (reinsert_reinsert_breakpoints): New function.
8300 * mem-break.h (uninsert_reinsert_breakpoints): Declare
8301 (reinsert_reinsert_breakpoints): Declare.
8302
8a81c5d7
YQ
83032016-06-17 Yao Qi <yao.qi@linaro.org>
8304
8305 * linux-low.c (handle_extended_wait): If the parent is doing
8306 step-over, remove the reinsert breakpoints from the forked child.
8307
f50bf8e5
YQ
83082016-06-17 Yao Qi <yao.qi@linaro.org>
8309
8310 * linux-low.c (unsuspend_all_lwps): Declare.
8311 (linux_low_filter_event): If thread exited, call finish_step_over.
8312 If step-over is finished, unsuspend other threads.
8313
8376a3cb
YQ
83142016-06-17 Yao Qi <yao.qi@linaro.org>
8315
8316 * linux-low.c (linux_resume_one_lwp_throw): Assert
8317 has_reinsert_breakpoints returns false.
8318 * mem-break.c (delete_disabled_breakpoints): Assert
8319 bp type isn't reinsert_breakpoint.
8320
f79b145d
YQ
83212016-06-17 Yao Qi <yao.qi@linaro.org>
8322
8323 * linux-low.c (maybe_hw_step): New function.
8324 (linux_resume_one_lwp_throw): Call maybe_hw_step.
8325 (finish_step_over): Switch current_thread to lwp temporarily,
8326 and assert has_reinsert_breakpoints returns true.
8327 (proceed_one_lwp): Call maybe_hw_step.
8328 * mem-break.c (has_reinsert_breakpoints): New function.
8329 * mem-break.h (has_reinsert_breakpoints): Declare.
8330
0ae534d2
JT
83312016-06-02 Jon Turney <jon.turney@dronecode.org.uk>
8332
8333 * win32-low.c (win32_create_inferior): Add pointer casts for C++.
8334
fcdad592
YQ
83352016-05-17 Yao Qi <yao.qi@linaro.org>
8336
8337 * linux-low.c (linux_stabilize_threads): Call unsuspend_all_lwps
8338 instead of find_inferior.
8339
9e784964
YQ
83402016-05-05 Yao Qi <yao.qi@linaro.org>
8341
8342 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer):
8343 Initialize res to zero.
8344
cf2ebb6e
YQ
83452016-05-05 Yao Qi <yao.qi@linaro.org>
8346
8347 * linux-arm-low.c (arm_sigreturn_next_pc): Change type of cpsr
8348 to uint32_t.
8349
c1aebf87
UW
83502016-05-04 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
8351
8352 * spu-low.c (fetch_ppc_register): Cast PowerPC-Linux-specific value
8353 used as first ptrace argument to PTRACE_TYPE_ARG1 for C++.
8354 (fetch_ppc_memory_1, store_ppc_memory_1): Likewise.
8355
35fd2deb 83562016-04-28 Par Olsson <par.olsson@windriver.com>
cbe14bcf 8357 Simon Marchi <simon.marchi@ericsson.com>
35fd2deb
PO
8358
8359 * tracepoint.c (write_inferior_int8): New function.
8360 (cmd_qtenable_disable): Write enable flag using
8361 write_inferior_int8.
8362
484b3c32
YQ
83632016-04-25 Yao Qi <yao.qi@linaro.org>
8364
8365 * linux-low.c (lwp_signal_can_be_delivered): Adjust.
8366 (need_step_over_p): Return zero if the LWP has pending signals
8367 can be delivered on software single step target.
8368
85ba7d86
YQ
83692016-04-25 Yao Qi <yao.qi@linaro.org>
8370
8371 * linux-low.c (reinsert_raw_breakpoint): If bp->inserted is true
8372 return instead of error.
8373
3539aa13
YQ
83742016-04-22 Yao Qi <yao.qi@linaro.org>
8375
8376 * linux-aarch32-low.c (arm_store_gregset): Clear CPSR bits 20
8377 to 23.
8378
5b061e98
YQ
83792016-04-22 Yao Qi <yao.qi@linaro.org>
8380
8381 * linux-low.c (lwp_signal_can_be_delivered): Don't deliver
8382 signal when stepping over breakpoint with software single
8383 step.
8384
3451269c
PA
83852016-04-21 Pedro Alves <palves@redhat.com>
8386
8387 * linux-s390-low.c (s390_collect_ptrace_register)
8388 (s390_supply_ptrace_register, s390_get_hwcap): Use gdb_byte * and
8389 add casts.
8390 (s390_check_regset): Use void * instead of gdb_byte *.
8391
a2358508
PA
83922016-04-20 Pedro Alves <palves@redhat.com>
8393
8394 * configure: Renegerate.
8395
6885166d
YQ
83962016-04-20 Yao Qi <yao.qi@linaro.org>
8397
8398 * linux-aarch32-low.c: Include "arch/arm-linux.h".
8399 (arm_fill_gregset): Use ARM_CPSR_GREGNUM rather than magic
8400 number 16.
8401 (arm_store_gregset): Likewise.
8402
2b863f51
WT
84032016-04-16 Walfred Tedeschi <walfred.tedeschi@intel.com>
8404
8405 * Makefile.in (clean): Add removal for i386-avx-mpx.c,
8406 i386-avx-mpx-linux.c, amd64-avx-mpx.c and amd64-avx-mpx-linux.c.
8407 (i386-avx-mpx.c, i386-avx-mpx-linux.c, amd64-avx-mpx.c)
8408 (amd64-avx-mpx-linux.c): New rules.
8409 (amd64-avx-mpx-linux-ipa.o, i386-avx-mpx-linux-ipa.o): New rule.
8410 * configure.srv (srv_i386_regobj): Add i386-avx-mpx.o.
8411 (srv_i386_linux_regobj): Add i386-avx-mpx-linux.o.
8412 (srv_amd64_regobj): Add amd64-avx-mpx.o.
8413 (srv_amd64_linux_regobj): Add amd64-avx-mpx-linux.o.
8414 (srv_i386_xmlfiles): Add i386/i386-avx-mpx.xml.
8415 (srv_amd64_xmlfiles): Add i386/amd64-avx-mpx.xml.
8416 (srv_i386_linux_xmlfiles): Add i386/i386-avx-mpx-linux.xml.
8417 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-mpx-linux.xml.
8418 (ipa_i386_linux_regobj): Add i386-avx-mpx-linux-ipa.o.
8419 (ipa_amd64_linux_regobj): Add amd64-avx-mpx-linux-ipa.o.
8420 * linux-x86-low.c (x86_linux_read_description): Add case for
8421 X86_XSTATE_AVX_MPX_MASK.
8422 (x86_get_ipa_tdesc_idx): Add cases for avx_mpx.
8423 (initialize_low_arch): Call init_registers_amd64_avx_mpx_linux and
8424 init_registers_i386_avx_mpx_linux.
8425 * linux-i386-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
8426 (initialize_low_tracepoint): Call
8427 init_registers_i386_avx_mpx_linux.
8428 * linux-amd64-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
8429 (initialize_low_tracepoint): Call
8430 init_registers_amd64_avx_mpx_linux.
8431 * linux-x86-tdesc.h (X86_TDESC_AVX_MPX): New enum value.
8432 (init_registers_amd64_avx_mpx_linux, tdesc_amd64_avx_mpx_linux)
8433 (init_registers_i386_avx_mpx_linux, tdesc_i386_avx_mpx_linux): New
8434 declarations.
8435
9b30624b
PA
84362016-04-18 Pedro Alves <palves@redhat.com>
8437
8438 * configure: Regenerate.
8439
45e3745e
AT
84402016-04-13 Antoine Tremblay <antoine.tremblay@ericsson.com>
8441
8442 * linux-aarch64-low.c (aarch64_emit_add): Switch x1 and x0.
8443 (aarch64_emit_sub): Likewise.
8444
2afc13ff
PA
84452016-04-12 Pedro Alves <palves@redhat.com>
8446
8447 * utils.c (prepare_to_throw_exception): Delete.
8448
6e774b13
SM
84492016-04-05 Simon Marchi <simon.marchi@ericsson.com>
8450
8451 * Makefile.in ($(IPA_LIB)): Set SONAME of the IPA lib.
8452
4dca19f8
MK
84532016-04-05 Marcin Kościelnicki <koriakin@0x04.net>
8454
8455 * tracepoint.c (getauxval): Move to #ifdef IN_PROCESS_AGENT.
8456
d0a9981f
MK
84572016-04-03 Marcin Kościelnicki <koriakin@0x04.net>
8458
8459 * linux-aarch64-ipa.c: Add <elf.h> include.
8460 * linux-ppc-ipa.c: Add <elf.h> include.
8461 * linux-s390-ipa.c: Add <elf.h> include.
8462
252db07e
MK
84632016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
8464
8465 * tracepoint.c (gdb_collect_ptr): Remove const qualifier.
8466 (get_raw_reg_ptr): Likewise.
8467 (get_trace_state_variable_value_ptr): Likewise.
8468 (set_trace_state_variable_value_ptr): Likewise.
8469 (initialize_tracepoint): Cast alloc_jump_pad_buffer result to
8470 char *.
8471
14e2b6d9
MK
84722016-03-31 Wei-cheng Wang <cole945@gmail.com>
8473 Marcin Kościelnicki <koriakin@0x04.net>
8474
8475 PR/17221
8476 * linux-ppc-low.c (emit_insns): New function.
8477 (__EMIT_ASM, _EMIT_ASM, EMIT_ASM): New macros.
8478 (ppc_emit_prologue): New function.
8479 (ppc_emit_epilogue): New function.
8480 (ppc_emit_add): New function.
8481 (ppc_emit_sub): New function.
8482 (ppc_emit_mul): New function.
8483 (ppc_emit_lsh): New function.
8484 (ppc_emit_rsh_signed): New function.
8485 (ppc_emit_rsh_unsigned): New function.
8486 (ppc_emit_ext): New function.
8487 (ppc_emit_zero_ext): New function.
8488 (ppc_emit_log_not): New function.
8489 (ppc_emit_bit_and): New function.
8490 (ppc_emit_bit_or): New function.
8491 (ppc_emit_bit_xor): New function.
8492 (ppc_emit_bit_not): New function.
8493 (ppc_emit_equal): New function.
8494 (ppc_emit_less_signed): New function.
8495 (ppc_emit_less_unsigned): New function.
8496 (ppc_emit_ref): New function.
8497 (ppc_emit_const): New function.
8498 (ppc_emit_reg): New function.
8499 (ppc_emit_pop): New function.
8500 (ppc_emit_stack_flush): New function.
8501 (ppc_emit_swap): New function.
8502 (ppc_emit_stack_adjust): New function.
8503 (ppc_emit_call): New function.
8504 (ppc_emit_int_call_1): New function.
8505 (ppc_emit_void_call_2): New function.
8506 (ppc_emit_if_goto): New function.
8507 (ppc_emit_goto): New function.
8508 (ppc_emit_eq_goto): New function.
8509 (ppc_emit_ne_goto): New function.
8510 (ppc_emit_lt_goto): New function.
8511 (ppc_emit_le_goto): New function.
8512 (ppc_emit_gt_goto): New function.
8513 (ppc_emit_ge_goto): New function.
8514 (ppc_write_goto_address): New function.
8515 (ppc_emit_ops_impl): New static variable.
8516 (ppc64v1_emit_prologue): New function.
8517 (ppc64v2_emit_prologue): New function.
8518 (ppc64_emit_epilogue): New function.
8519 (ppc64_emit_add): New function.
8520 (ppc64_emit_sub): New function.
8521 (ppc64_emit_mul): New function.
8522 (ppc64_emit_lsh): New function.
8523 (ppc64_emit_rsh_signed): New function.
8524 (ppc64_emit_rsh_unsigned): New function.
8525 (ppc64_emit_ext): New function.
8526 (ppc64_emit_zero_ext): New function.
8527 (ppc64_emit_log_not): New function.
8528 (ppc64_emit_bit_and): New function.
8529 (ppc64_emit_bit_or): New function.
8530 (ppc64_emit_bit_xor): New function.
8531 (ppc64_emit_bit_not): New function.
8532 (ppc64_emit_equal): New function.
8533 (ppc64_emit_less_signed): New function.
8534 (ppc64_emit_less_unsigned): New function.
8535 (ppc64_emit_ref): New function.
8536 (ppc64_emit_const): New function.
8537 (ppc64v1_emit_reg): New function.
8538 (ppc64v2_emit_reg): New function.
8539 (ppc64_emit_pop): New function.
8540 (ppc64_emit_stack_flush): New function.
8541 (ppc64_emit_swap): New function.
8542 (ppc64v1_emit_call): New function.
8543 (ppc64v2_emit_call): New function.
8544 (ppc64v1_emit_int_call_1): New function.
8545 (ppc64v2_emit_int_call_1): New function.
8546 (ppc64v1_emit_void_call_2): New function.
8547 (ppc64v2_emit_void_call_2): New function.
8548 (ppc64_emit_if_goto): New function.
8549 (ppc64_emit_eq_goto): New function.
8550 (ppc64_emit_ne_goto): New function.
8551 (ppc64_emit_lt_goto): New function.
8552 (ppc64_emit_le_goto): New function.
8553 (ppc64_emit_gt_goto): New function.
8554 (ppc64_emit_ge_goto): New function.
8555 (ppc64v1_emit_ops_impl): New static variable.
8556 (ppc64v2_emit_ops_impl): New static variable.
8557 (ppc_emit_ops): New function.
8558 (linux_low_target): Wire in ppc_emit_ops.
8559
a2174ba4
MK
85602016-03-31 Wei-cheng Wang <cole945@gmail.com>
8561 Marcin Kościelnicki <koriakin@0x04.net>
8562
8563 PR/17221
8564 * Makefile.in: Add powerpc-*-ipa.o
8565 * configure.srv: Add ipa_obj for powerpc*-linux.
8566 * linux-ppc-ipa.c: New file.
8567 * linux-ppc-low.c: Added linux-ppc-tdesc.h, ax.h, tracepoint.h
8568 includes.
8569 (PPC_FIELD): New macro.
8570 (PPC_SEXT): New macro.
8571 (PPC_OP6): New macro.
8572 (PPC_BO): New macro.
8573 (PPC_LI): New macro.
8574 (PPC_BD): New macro.
8575 (init_registers_*): Move prototype to linux-ppc-tdesc.h.
8576 (tdesc_*): Move declaration to linux-ppc-tdesc.h.
8577 (ppc_get_hwcap): Rename to ppc_get_auxv and add type parameter.
8578 (ppc_get_thread_area): New function.
8579 (is_elfv2_inferior): New function.
8580 (gen_ds_form): New function.
8581 (GEN_STD): New macro.
8582 (GEN_STDU): New macro.
8583 (GEN_LD): New macro.
8584 (GEN_LDU): New macro.
8585 (gen_d_form): New function.
8586 (GEN_ADDI): New macro.
8587 (GEN_ADDIS): New macro.
8588 (GEN_LI): New macro.
8589 (GEN_LIS): New macro.
8590 (GEN_ORI): New macro.
8591 (GEN_ORIS): New macro.
8592 (GEN_LWZ): New macro.
8593 (GEN_STW): New macro.
8594 (GEN_STWU): New macro.
8595 (gen_xfx_form): New function.
8596 (GEN_MFSPR): New macro.
8597 (GEN_MTSPR): New macro.
8598 (GEN_MFCR): New macro.
8599 (GEN_MTCR): New macro.
8600 (GEN_SYNC): New macro.
8601 (GEN_LWSYNC): New macro.
8602 (gen_x_form): New function.
8603 (GEN_OR): New macro.
8604 (GEN_MR): New macro.
8605 (GEN_LWARX): New macro.
8606 (GEN_STWCX): New macro.
8607 (GEN_CMPW): New macro.
8608 (gen_md_form): New function.
8609 (GEN_RLDICL): New macro.
8610 (GEN_RLDICR): New macro.
8611 (gen_i_form): New function.
8612 (GEN_B): New macro.
8613 (GEN_BL): New macro.
8614 (gen_b_form): New function.
8615 (GEN_BNE): New macro.
8616 (GEN_LOAD): New macro.
8617 (GEN_STORE): New macro.
8618 (gen_limm): New function.
8619 (gen_atomic_xchg): New function.
8620 (gen_call): New function.
8621 (ppc_relocate_instruction): New function.
8622 (ppc_install_fast_tracepoint_jump_pad): New function.
8623 (ppc_get_min_fast_tracepoint_insn_len): New function.
8624 (ppc_get_ipa_tdesc_idx): New function.
8625 (the_low_target): Wire in the new functions.
8626 (initialize_low_arch) [!__powerpc64__]: Don'it initialize 64-bit
8627 tdescs.
8628 * linux-ppc-tdesc.h: New file.
8629
a13c4696
MK
86302016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
8631
8632 * linux-aarch64-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
8633 (alloc_jump_pad_buffer): New function.
8634 * linux-amd64-ipa.c: Add <sys/mman.h> include.
8635 (alloc_jump_pad_buffer): New function.
8636 * linux-i386-ipa.c (alloc_jump_pad_buffer): New function.
8637 * linux-s390-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
8638 (alloc_jump_pad_buffer): New function.
8639 * tracepoint.c (getauxval) [!HAVE_GETAUXVAL]: New function.
8640 (initialize_tracepoint): Delegate to alloc_jump_pad_buffer.
8641 * tracepoint.h (alloc_jump_pad_buffer): New prototype.
8642 (getauxval) [!HAVE_GETAUXVAL]: New prototype.
8643
1cda1512
MK
86442016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
8645
8646 * linux-aarch64-ipa.c: Rename gdb_agent_get_raw_reg to get_raw_reg.
8647 * linux-amd64-ipa.c: Likewise.
8648 * linux-i386-ipa.c: Likewise.
8649 * linux-s390-ipa.c: Likewise.
8650 * tracepoint.c: IPA-export gdb_collect_ptr instead of gdb_collect,
8651 ditto for get_raw_reg_ptr, get_trace_state_variable_value_ptr,
8652 set_trace_state_variable_value_ptr.
8653 (struct ipa_sym_addresses): Likewise.
8654 (symbol_list): Likewise.
8655 (install_fast_tracepoint): Dereference gdb_collect_ptr instead of
8656 accessing gdb_collect directly.
8657 (gdb_collect_ptr_type): New typedef.
8658 (get_raw_reg_ptr_type): New typedef.
8659 (get_trace_state_variable_value_ptr_type): New typedef.
8660 (set_trace_state_variable_value_ptr_type): New typedef.
8661 (gdb_collect_ptr): New global.
8662 (get_raw_reg_ptr): New global.
8663 (get_trace_state_variable_value_ptr): New global.
8664 (set_trace_state_variable_value_ptr): New global.
8665 (get_raw_reg_func_addr): Dereference get_raw_reg_ptr instead of
8666 accessing get_raw_reg directly.
8667 (get_get_tsv_func_addr): Likewise for
8668 get_trace_state_variable_value_ptr.
8669 (get_set_tsv_func_addr): Likewise for
8670 set_trace_state_variable_value_ptr.
8671 * tracepoint.h: Rename gdb_agent_get_raw_reg to get_raw_reg.
8672
72fb5488
SM
86732016-03-30 Simon Marchi <simon.marchi@ericsson.com>
8674
8675 * tracepoint.c (cmd_qtenable_disable): Remove whitespace.
8676
28170b88
MK
86772016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
8678
8679 * remote-utils.c (look_up_one_symbol): Remove own_buf, handle 'v'
8680 packets.
8681 (relocate_instruction): Remove own_buf.
8682 * server.c (own_buf): Make global.
8683 (handle_v_requests): Make global.
8684 * server.h (own_buf): New declaration.
8685 (handle_v_requests): New prototype.
8686
f39e8743
MK
86872016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
8688
8689 PR 18377
8690 * linux-s390-low.c (add_insns): New function.
8691 (s390_emit_prologue): New function.
8692 (s390_emit_epilogue): New function.
8693 (s390_emit_add): New function.
8694 (s390_emit_sub): New function.
8695 (s390_emit_mul): New function.
8696 (s390_emit_lsh): New function.
8697 (s390_emit_rsh_signed): New function.
8698 (s390_emit_rsh_unsigned): New function.
8699 (s390_emit_ext): New function.
8700 (s390_emit_log_not): New function.
8701 (s390_emit_bit_and): New function.
8702 (s390_emit_bit_or): New function.
8703 (s390_emit_bit_xor): New function.
8704 (s390_emit_bit_not): New function.
8705 (s390_emit_equal): New function.
8706 (s390_emit_less_signed): New function.
8707 (s390_emit_less_unsigned): New function.
8708 (s390_emit_ref): New function.
8709 (s390_emit_if_goto): New function.
8710 (s390_emit_goto): New function.
8711 (s390_write_goto_address): New function.
8712 (s390_emit_litpool): New function.
8713 (s390_emit_const): New function.
8714 (s390_emit_call): New function.
8715 (s390_emit_reg): New function.
8716 (s390_emit_pop): New function.
8717 (s390_emit_stack_flush): New function.
8718 (s390_emit_zero_ext): New function.
8719 (s390_emit_swap): New function.
8720 (s390_emit_stack_adjust): New function.
8721 (s390_emit_set_r2): New function.
8722 (s390_emit_int_call_1): New function.
8723 (s390_emit_void_call_2): New function.
8724 (s390_emit_eq_goto): New function.
8725 (s390_emit_ne_goto): New function.
8726 (s390_emit_lt_goto): New function.
8727 (s390_emit_le_goto): New function.
8728 (s390_emit_gt_goto): New function.
8729 (s390_emit_ge_goto): New function.
8730 (s390x_emit_prologue): New function.
8731 (s390x_emit_epilogue): New function.
8732 (s390x_emit_add): New function.
8733 (s390x_emit_sub): New function.
8734 (s390x_emit_mul): New function.
8735 (s390x_emit_lsh): New function.
8736 (s390x_emit_rsh_signed): New function.
8737 (s390x_emit_rsh_unsigned): New function.
8738 (s390x_emit_ext): New function.
8739 (s390x_emit_log_not): New function.
8740 (s390x_emit_bit_and): New function.
8741 (s390x_emit_bit_or): New function.
8742 (s390x_emit_bit_xor): New function.
8743 (s390x_emit_bit_not): New function.
8744 (s390x_emit_equal): New function.
8745 (s390x_emit_less_signed): New function.
8746 (s390x_emit_less_unsigned): New function.
8747 (s390x_emit_ref): New function.
8748 (s390x_emit_if_goto): New function.
8749 (s390x_emit_const): New function.
8750 (s390x_emit_call): New function.
8751 (s390x_emit_reg): New function.
8752 (s390x_emit_pop): New function.
8753 (s390x_emit_stack_flush): New function.
8754 (s390x_emit_zero_ext): New function.
8755 (s390x_emit_swap): New function.
8756 (s390x_emit_stack_adjust): New function.
8757 (s390x_emit_int_call_1): New function.
8758 (s390x_emit_void_call_2): New function.
8759 (s390x_emit_eq_goto): New function.
8760 (s390x_emit_ne_goto): New function.
8761 (s390x_emit_lt_goto): New function.
8762 (s390x_emit_le_goto): New function.
8763 (s390x_emit_gt_goto): New function.
8764 (s390x_emit_ge_goto): New function.
8765 (s390_emit_ops): New function.
8766 (struct linux_target_ops): Fill in emit_ops hook.
8767
abd9baf9
MK
87682016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
8769
8770 PR 18377
8771 * Makefile.in: Add s390 IPA files.
8772 * configure.srv: Build IPA for s390.
8773 * linux-s390-ipa.c: New file.
8774 * linux-s390-low.c: New includes - inttypes.h and linux-s390-tdesc.h.
8775 (init_registers_s390_linux32): Move declaration to linux-s390-tdesc.h.
8776 (tdesc_s390_linux32): Likewise.
8777 (init_registers_s390_linux32v1): Likewise.
8778 (tdesc_s390_linux32v1): Likewise.
8779 (init_registers_s390_linux32v2): Likewise.
8780 (tdesc_s390_linux32v2): Likewise.
8781 (init_registers_s390_linux64): Likewise.
8782 (tdesc_s390_linux64): Likewise.
8783 (init_registers_s390_linux64v1): Likewise.
8784 (tdesc_s390_linux64v1): Likewise.
8785 (init_registers_s390_linux64v2): Likewise.
8786 (tdesc_s390_linux64v2): Likewise.
8787 (init_registers_s390_te_linux64): Likewise.
8788 (tdesc_s390_te_linux64): Likewise.
8789 (init_registers_s390_vx_linux64): Likewise.
8790 (tdesc_s390_vx_linux64): Likewise.
8791 (init_registers_s390_tevx_linux64): Likewise.
8792 (tdesc_s390_tevx_linux64): Likewise.
8793 (init_registers_s390x_linux64): Likewise.
8794 (tdesc_s390x_linux64): Likewise.
8795 (init_registers_s390x_linux64v1): Likewise.
8796 (tdesc_s390x_linux64v1): Likewise.
8797 (init_registers_s390x_linux64v2): Likewise.
8798 (tdesc_s390x_linux64v2): Likewise.
8799 (init_registers_s390x_te_linux64): Likewise.
8800 (tdesc_s390x_te_linux64): Likewise.
8801 (init_registers_s390x_vx_linux64): Likewise.
8802 (tdesc_s390x_vx_linux64): Likewise.
8803 (init_registers_s390x_tevx_linux64): Likewise.
8804 (tdesc_s390x_tevx_linux64): Likewise.
8805 (have_hwcap_s390_vx): New static variable.
8806 (s390_arch_setup): Fill have_hwcap_s390_vx.
8807 (s390_get_thread_area): New function.
8808 (s390_ft_entry_gpr_esa): New const.
8809 (s390_ft_entry_gpr_zarch): New const.
8810 (s390_ft_entry_misc): New const.
8811 (s390_ft_entry_fr): New const.
8812 (s390_ft_entry_vr): New const.
8813 (s390_ft_main_31): New const.
8814 (s390_ft_main_64): New const.
8815 (s390_ft_exit_fr): New const.
8816 (s390_ft_exit_vr): New const.
8817 (s390_ft_exit_misc): New const.
8818 (s390_ft_exit_gpr_esa): New const.
8819 (s390_ft_exit_gpr_zarch): New const.
8820 (append_insns): New function.
8821 (s390_relocate_instruction): New function.
8822 (s390_install_fast_tracepoint_jump_pad): New function.
8823 (s390_get_min_fast_tracepoint_insn_len): New function.
8824 (s390_get_ipa_tdesc_idx): New function.
8825 (struct linux_target_ops): Wire in the above functions.
8826 (initialize_low_arch) [!__s390x__]: Don't initialize s390x tdescs.
8827 * linux-s390-tdesc.h: New file.
8828
a4105d04
MK
88292016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
8830
8831 * linux-s390-low.c (s390_supports_tracepoints): New function.
8832 (struct linux_target_ops): Fill supports_tracepoints hook.
8833
35ac8b3e
YQ
88342016-03-18 Yao Qi <yao.qi@linaro.org>
8835
8836 * linux-low.c (lwp_signal_can_be_delivered): New function.
8837 (linux_resume_one_lwp_throw): Use lwp_signal_can_be_delivered.
8838
94610ec4
YQ
88392016-03-18 Yao Qi <yao.qi@linaro.org>
8840
8841 * linux-low.c (linux_resume_one_lwp_throw): Set 'signal' to
8842 0 if signal is enqueued. Remove 'signal' from one debugging
8843 message. Move one debugging message to some lines below.
8844 Remove code setting 'signal' to 0.
8845
80aea927
YQ
88462016-03-18 Yao Qi <yao.qi@linaro.org>
8847
8848 * linux-low.c (linux_low_filter_event): Remove redundant
8849 WIFSTOPPED check together with linux_wstatus_maybe_breakpoint.
8850
b04fd3be
MK
88512016-03-09 Marcin Kościelnicki <koriakin@0x04.net>
8852
8853 * linux-ppc-low.c (ppc_supports_tracepoints): New function.
8854 (struct linux_target_ops): Wire in the above.
8855
c40c8d4b
YQ
88562016-03-03 Yao Qi <yao.qi@linaro.org>
8857
8858 * linux-low.c: Update comments to start_step_over.
8859
0f8288ae
YQ
88602016-03-03 Yao Qi <yao.qi@linaro.org>
8861
8862 PR server/19736
8863 * linux-low.c (handle_extended_wait): Set child suspended
8864 if event_lwp->bp_reinsert isn't zero.
8865
fdbd04a8
YQ
88662016-03-02 Yao Qi <yao.qi@linaro.org>
8867
8868 * linux-low.c (linux_resume_one_lwp_throw): Replace code with
8869 enqueue_pending_signal.
8870
6896a8fa
MK
88712016-03-02 Marcin Kościelnicki <koriakin@0x04.net>
8872
8873 * tracepoint.c (cmd_qtstart): Only set ipa_tdesc_idx if agent
8874 is actually loaded.
8875
ab503087
MK
88762016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
8877
8878 * linux-s390-low.c (s390_num_regs_3264): Define on 31-bit too.
8879 (s390_regmap_3264) [!__s390x__]: New global.
8880 (s390_collect_ptrace_register): Skip map entries containing -1.
8881 (s390_supply_ptrace_register): Ditto.
8882 (s390_fill_gprs_high): New function.
8883 (s390_store_gprs_high): New function.
8884 (s390_regsets): Add NT_S390_HIGH_GPRS.
8885 (s390_get_hwcap): Enable on 31-bit.
8886 (have_hwcap_s390_high_gprs): Enable on 31-bit.
8887 (s390_arch_setup): Enable detection of high GPRs, TDB, VX on 31-bit.
8888 Detect NT_S390_HIGH_GPRS.
8889 (s390_usrregs_info_3264): Enable on 31-bit.
8890 (s390_regs_info): Enable regs_info_3264 on 31-bit.
8891 (initialize_low_arch): Initialize s390_regsets_info_3264 on 31-bit.
8892
ae91f625
MK
88932016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
8894
8895 PR gdb/13808
8896 * Makefile.in: Add i386-*-linux-ipa.o and amd64-*-linux-ipa.o.
8897 * configure.srv: Ditto.
8898 * linux-aarch64-ipa.c (get_ipa_tdesc): New function.
8899 (initialize_low_tracepoint): Remove ipa_tdesc assignment.
8900 * linux-amd64-ipa.c: Add "linux-x86-tdesc.h" include.
8901 (init_registers_amd64_linux): Remove prototype.
8902 (tdesc_amd64_linux): Remove declaration.
8903 (get_ipa_tdesc): New function.
8904 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
8905 initialize remaining tdescs.
8906 * linux-i386-ipa.c: Add "linux-x86-tdesc.h" include.
8907 (init_registers_i386_linux): Remove prototype.
8908 (tdesc_i386_linux): Remove declaration.
8909 (get_ipa_tdesc): New function.
8910 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
8911 initialize remaining tdescs.
8912 * linux-low.c (linux_get_ipa_tdesc_idx): New function.
8913 (linux_target_ops): wire in linux_get_ipa_tdesc_idx.
8914 * linux-low.h (struct linux_target_ops): Add get_ipa_tdesc_idx.
8915 * linux-x86-low.c: Move tdesc declarations to linux-x86-tdesc.h.
8916 (x86_get_ipa_tdesc_idx): New function.
8917 (the_low_target): Wire in x86_get_ipa_tdesc_idx.
8918 * linux-x86-tdesc.h: New file.
8919 * target.h (struct target_ops): Add get_ipa_tdesc_idx.
8920 (target_get_ipa_tdesc_idx): New macro.
8921 * tracepoint.c (ipa_tdesc_idx): New macro.
8922 (struct ipa_sym_addresses): Add addr_ipa_tdesc_idx.
8923 (symbol_list): Add ipa_tdesc_idx.
8924 (cmd_qtstart): Write ipa_tdesc_idx in the target.
8925 (ipa_tdesc): Remove.
8926 (ipa_tdesc_idx): New variable.
8927 (get_context_regcache): Use get_ipa_tdesc.
8928 (gdb_collect): Ditto.
8929 (gdb_probe): Ditto.
8930 * tracepoint.h (get_ipa_tdesc): New prototype.
8931 (ipa_tdesc): Remove.
8932
e7ad2f14
PA
89332016-02-24 Pedro Alves <palves@redhat.com>
8934
8935 * linux-low.c (check_stopped_by_breakpoint): Rename to ...
8936 (save_stop_reason): ... this. Use GDB_ARCH_IS_TRAP_HWBKPT and
8937 handle ambiguous GDB_ARCH_IS_TRAP_BRKPT / GDB_ARCH_IS_TRAP_HWBKPT.
8938 Factor out common code between the USE_SIGTRAP_SIGINFO and
8939 !USE_SIGTRAP_SIGINFO blocks.
8940 (linux_low_filter_event): Call save_stop_reason instead of
8941 check_stopped_by_breakpoint and check_stopped_by_watchpoint.
8942 Update comments.
8943 (linux_wait_1): Update comments.
8944
657f9cde
WW
89452016-02-24 Wei-cheng Wang <cole945@gmail.com>
8946
8947 * linux-ppc-low.c (ppc_supports_z_point_type): New function:
8948 (ppc_insert_point, ppc_remove_point): Insert/remove z-packet breakpoints.
8949 (ppc64_emit_ops_vector): Add target ops - ppc_supports_z_point_type,
8950 ppc_insert_point, ppc_remove_point.
8951
b00b61e1
MK
89522016-02-17 Marcin Kościelnicki <koriakin@0x04.net>
8953
8954 * linux-s390-low.c (s390_supports_z_point_type): New function.
8955 (struct linux_target_ops): Wire s390_supports_z_point_type in.
8956
553cb527
YQ
89572016-02-16 Yao Qi <yao.qi@linaro.org>
8958
8959 * linux-arm-low.c (get_next_pcs_syscall_next_pc): Remove argument
8960 PC. Get pc from regcache_read_pc.
8961
a5652c21
YQ
89622016-02-12 Yao Qi <yao.qi@linaro.org>
8963
8964 * linux-aarch64-low.c (aarch64_get_pc): Call linux_get_pc_64bit
8965 or linux_get_pc_32bit.
8966 (aarch64_set_pc): Call linux_set_pc_64bit or linux_set_pc_32bit.
8967
ed443b61
YQ
89682016-02-12 Yao Qi <yao.qi@linaro.org>
8969
8970 * linux-arm-low.c (get_next_pcs_ops): Initialize it with
8971 arm_linux_get_next_pcs_fixup.
8972
020ecd38
MK
89732016-02-12 Marcin Kościelnicki <koriakin@0x04.net>
8974
8975 * tracepoint.c (x_tracepoint_action_download): Change
8976 write_inferior_data_ptr to write_inferior_data_pointer.
8977 (cmd_qtstart): Likewise.
8978 (write_inferior_data_ptr): Remove.
8979 (download_agent_expr): Change write_inferior_data_ptr to
8980 write_inferior_data_pointer.
8981 (download_tracepoint_1): Likewise.
8982 (download_tracepoint): Likewise.
8983 (download_trace_state_variables): Likewise.
8984
7cae9051
WW
89852016-02-11 Wei-cheng Wang <cole945@gmail.com>
8986 Marcin Kościelnicki <koriakin@0x04.net>
8987
8988 * tracepoint.c (struct tracepoint_action_ops): Remove.
8989 (struct tracepoint_action): Remove ops.
8990 (m_tracepoint_action_download, r_tracepoint_action_download)
8991 (x_tracepoint_action_download, l_tracepoint_action_download): Adjust
8992 size and offset accordingly.
8993 (m_tracepoint_action_ops, r_tracepoint_action_ops)
8994 (x_tracepoint_action_ops, l_tracepoint_action_ops): Remove.
8995 (tracepoint_action_send, tracepoint_action_download): New functions.
8996 Helpers for trace action handlers.
8997 (add_tracepoint_action): Remove setup actions ops.
8998 (download_tracepoint_1, tracepoint_send_agent): Call helper functions.
8999
9f6a71b4
YQ
90002016-02-10 Yao Qi <yao.qi@linaro.org>
9001
9002 * regcache.c (regcache_raw_read_unsigned): Clear *VAL.
9003
1e94266c
SM
90042016-02-09 Simon Marchi <simon.marchi@ericsson.com>
9005
9006 * configure.ac: Use AC_CONFIG_FILES instead of passing arguments
9007 to AC_OUTPUT.
9008 * configure: Regenerate.
9009
8adce034
SM
90102016-02-09 Simon Marchi <simon.marchi@ericsson.com>
9011
9012 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): Change
9013 void * to gdb_byte *.
9014 * linux-low.c (siginfo_fixup): Likewise.
9015 (linux_xfer_siginfo): Likewise.
9016 * linux-low.h (struct linux_target_ops) <siginfo_fixup>:
9017 Likewise.
9018 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
9019
93813b37
WT
90202016-02-02 Walfred Tedeschi <walfred.tedeschi@intel.com>
9021
9022 * configure.srv (x86_64-*-linux*): Add amd64-linux-siginfo.o
9023 to srv_tgtobj.
9024 (i[34567]86-*-linux*): Add amd64-linux-siginfo.o
9025 to srv_tgtobj.
9026 * linux-x86-low.c [__x86_64__]: Include
9027 "nat/amd64-linux-siginfo.h".
9028 (compat_siginfo_from_siginfo, siginfo_from_compat_siginfo)
9029 (compat_x32_siginfo_from_siginfo, siginfo_from_compat_x32_siginfo)
9030 (compat_timeval, compat_sigval, compat_x32_clock, cpt_si_pid)
9031 (cpt_si_uid, cpt_si_timerid, cpt_si_overrun, cpt_si_status)
9032 (cpt_si_utime, cpt_si_stime, cpt_si_ptr, cpt_si_addr, cpt_si_band)
9033 (cpt_si_fd, si_timerid, si_overrun): Move from
9034 nat/amd64-linux-siginfo.c.
9035 * Makefile.in (amd64-linux-siginfo.o:): New rule.
9036
8424cc97
SM
90372016-01-28 Simon Marchi <simon.marchi@ericsson.com>
9038
9039 * server.c (skip_to_semicolon): Remove.
9040 (process_point_options): Use strchrnul instead of
9041 skip_to_semicolon.
9042
4d18591b
YQ
90432016-01-26 Yao Qi <yao.qi@linaro.org>
9044
9045 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Remove argument pc.
9046 * linux-low.c (install_software_single_step_breakpoints): Don't
9047 call regcache_read_pc.
9048 * linux-low.h (struct linux_target_ops) <get_next_pcs>: Remove
9049 argument pc.
9050
d8020970
YQ
90512016-01-26 Yao Qi <yao.qi@linaro.org>
9052
9053 * linux-low.c (install_software_single_step_breakpoints): Call
9054 regcache_read_pc instead of get_pc.
9055
8b207339
YQ
90562016-01-26 Yao Qi <yao.qi@linaro.org>
9057
9058 * remote-utils.c (remote_close) [!USE_WIN32API]: Ignore SIGIO.
9059 (unblock_async_io): Rename to ...
9060 (block_unblock_async_io): ... it. New function.
9061 (enable_async_io): Don't install SIGIO handler. Unblock it
9062 instead.
9063 (disable_async_io): Don't ignore SIGIO. Block it instead.
9064 (initialize_async_io): Install SIGIO handler. Don't call
9065 unblock_async_io.
9066
18879fef
YQ
90672016-01-26 Yao Qi <yao.qi@linaro.org>
9068
9069 * remote-utils.c (getpkt): If the buffer isn't empty, and the
9070 first character is '\003', call *the_target->request_interrupt.
9071
a0f8e08a
YQ
90722016-01-25 Yao Qi <yao.qi@linaro.org>
9073
9074 * remote-utils.c (new_thread_notify): Remove.
9075 (dead_thread_notify): Likewise.
9076 * remote-utils.h (new_thread_notify): Remove declaration.
9077 (dead_thread_notify): Likewise.
9078
cc5fd9ab
MK
90792016-01-23 Marcin Kościelnicki <koriakin@0x04.net>
9080
9081 * gdb.trace/pending.exp: Fix expected message on continue.
9082
99e8eb11
MK
90832016-01-22 Marcin Kościelnicki <koriakin@0x04.net>
9084
9085 * tracepoint.c (write_inferior_data_ptr): Cast to uintptr_t, so that
9086 it works properly on big-endian machines where sizeof (CORE_ADDR)
9087 != sizeof (void *).
9088
a994041d
PA
90892016-01-21 Pedro Alves <palves@redhat.com>
9090
9091 * Makefile.in (COMPILER_CFLAGS, CXXFLAGS): New.
9092 (INTERNAL_CFLAGS_BASE): Use COMPILER_CFLAGS instead of CFLAGS.
9093 * configure: Regenerate.
9094
f7a6a40d
YQ
90952016-01-21 Yao Qi <yao.qi@linaro.org>
9096
9097 * linux-arm-low.c (arm_sigreturn_next_pc): Add parameter
9098 is_thumb and set it according to CPSR saved on the stack.
9099 (get_next_pcs_syscall_next_pc): Pass is_thumb to
9100 arm_sigreturn_next_pc.
9101
6f69e520
YQ
91022016-01-18 Yao Qi <yao.qi@linaro.org>
9103
9104 * linux-low.c (linux_set_pc_64bit): New function.
9105 (linux_get_pc_64bit): New function.
9106 * linux-low.h (linux_set_pc_64bit, linux_get_pc_64bit):
9107 Declare.
9108 * linux-sparc-low.c (debug_threads): Remove declaration.
9109 (sparc_get_pc): Remove.
9110 (the_low_target): Use linux_get_pc_64bit instead of
9111 sparc_get_pc.
9112 * linux-tile-low.c (tile_get_pc, tile_set_pc): Remove.
9113 (the_low_target): Use linux_get_pc_64bit and
9114 linux_set_pc_64bit.
9115
276d4552
YQ
91162016-01-18 Yao Qi <yao.qi@linaro.org>
9117
9118 * linux-arm-low.c (debug_threads): Remove declaration.
9119 (arm_get_pc, arm_set_pc): Remove.
9120 (the_low_target): Use linux_get_pc_32bit and
9121 linux_set_pc_32bit.
9122 * linux-bfin-low.c (bfin_get_pc, bfin_set_pc): Remove.
9123 (the_low_target): Use linux_get_pc_32bit and
9124 linux_set_pc_32bit.
9125 * linux-cris-low.c (debug_threads): Remove declaration.
9126 (cris_get_pc, cris_set_pc,): Remove.
9127 (the_low_target): Use linux_get_pc_32bit and
9128 linux_set_pc_32bit.
9129 * linux-crisv32-low.c (debug_threads): Remove declaration.
9130 (cris_get_pc, cris_set_pc): Remove.
9131 (the_low_target): Use linux_get_pc_32bit and
9132 linux_set_pc_32bit.
9133 * linux-low.c: Include inttypes.h.
9134 (linux_get_pc_32bit, linux_set_pc_32bit): New functions.
9135 * linux-low.h (linux_get_pc_32bit, linux_set_pc_32bit): Declare.
9136 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Remove.
9137 (the_low_target): Use linux_get_pc_32bit and
9138 linux_set_pc_32bit.
9139 * linux-m68k-low.c (m68k_get_pc, m68k_set_pc): Remove.
9140 (the_low_target): Use linux_get_pc_32bit and
9141 linux_set_pc_32bit.
9142 * linux-nios2-low.c (nios2_get_pc, nios2_set_pc): Remove.
9143 (the_low_target): Use linux_get_pc_32bit and
9144 linux_set_pc_32bit.
9145 * linux-sh-low.c (sh_get_pc, sh_set_pc): Remove.
9146 (the_low_target): Use linux_get_pc_32bit and
9147 linux_set_pc_32bit.
9148 * linux-xtensa-low.c (xtensa_get_pc, xtensa_set_pc): Remove.
9149 (the_low_target): Use linux_get_pc_32bit and
9150 linux_set_pc_32bit.
9151
eb0edac8
GB
91522016-01-18 Gary Benson <gbenson@redhat.com>
9153
9154 * configure.ac (AC_FUNC_FORK): New check.
9155 * config.in: Regenerate.
9156 * configure: Likewise.
9157
1b451dda
YQ
91582016-01-14 Yao Qi <yao.qi@linaro.org>
9159
9160 * linux-aarch32-low.c (thumb2_breakpoint): Make it static.
9161 * linux-aarch32-low.h (thumb2_breakpoint): Remove declaration.
9162 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Pass 1 to
9163 arm_get_next_pcs_ctor.
9164
82075af2
JS
91652016-01-12 Josh Stone <jistone@redhat.com>
9166 Philippe Waroquiers <philippe.waroquiers@skynet.be>
9167
9168 * inferiors.h: Include "gdb_vecs.h".
9169 (struct process_info): Add syscalls_to_catch.
9170 * inferiors.c (remove_process): Free syscalls_to_catch.
9171 * remote-utils.c (prepare_resume_reply): Report syscall_entry and
9172 syscall_return stops.
9173 * server.h (UNKNOWN_SYSCALL, ANY_SYSCALL): Define.
9174 * server.c (handle_general_set): Handle QCatchSyscalls.
9175 (handle_query): Report support for QCatchSyscalls.
9176 * target.h (struct target_ops): Add supports_catch_syscall.
9177 (target_supports_catch_syscall): New macro.
9178 * linux-low.h (struct linux_target_ops): Add get_syscall_trapinfo.
9179 (struct lwp_info): Add syscall_state.
9180 * linux-low.c (handle_extended_wait): Mark syscall_state as an entry.
9181 Maintain syscall_state and syscalls_to_catch across exec.
9182 (get_syscall_trapinfo): New function, proxy to the_low_target.
9183 (linux_low_ptrace_options): Enable PTRACE_O_TRACESYSGOOD.
9184 (linux_low_filter_event): Toggle syscall_state entry/return for
9185 syscall traps, and set it ignored for all others.
9186 (gdb_catching_syscalls_p): New function.
9187 (gdb_catch_this_syscall_p): New function.
9188 (linux_wait_1): Handle SYSCALL_SIGTRAP.
9189 (linux_resume_one_lwp_throw): Add PTRACE_SYSCALL possibility.
9190 (linux_supports_catch_syscall): New function.
9191 (linux_target_ops): Install it.
9192 * linux-x86-low.c (x86_get_syscall_trapinfo): New function.
9193 (the_low_target): Install it.
9194
8f13a3ce
MF
91952016-01-12 Mike Frysinger <vapier@gentoo.org>
9196
9197 * acinclude.m4: Include new ../warning.m4 file.
9198 * configure: Regenerated.
9199 * configure.ac: Replace all warning logic with AM_GDB_WARNINGS.
9200
5b3da067
MF
92012016-01-12 Mike Frysinger <vapier@gentoo.org>
9202
9203 * ax.c (is_goto_target): Mark static.
9204 * linux-low.c (register_addr): Likewise.
9205 (linux_fetch_registers, linux_store_registers): Likewise.
9206 * mem-break.c (any_persistent_commands): Fix old prototype.
9207 (add_commands_to_breakpoint): Mark static.
9208 * regcache.c (find_register_by_name): Delete unused func.
9209 * remote-utils.c (hex_or_minus_one): Mark static.
9210 * server.c (monitor_show_help): Mark static.
9211 (handle_query, handle_v_cont, handle_v_attach, handle_v_kill,
9212 handle_v_requests): Likewise.
9213
bc504a31
PA
92142016-01-12 Pedro Alves <palves@redhat.com>
9215
9216 Remove use of the registered trademark symbol throughout.
9217
5a0dd67a
YQ
92182016-01-08 Yao Qi <yao.qi@linaro.org>
9219
9220 * remote-utils.c (getpkt): If c is '\003', call target hook
9221 request_interrupt.
9222
b2ca446f
YQ
92232016-01-06 Yao Qi <yao.qi@linaro.org>
9224
9225 * linux-aarch32-low.h (arm_abi_breakpoint): Move to
9226 linux-aarch32-low.c.
9227 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
9228 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
9229 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
9230 (thumb2_breakpoint): Declare.
9231 * linux-aarch32-low.c (arm_abi_breakpoint): Moved from
9232 linux-aarch32-low.h.
9233 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
9234 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
9235 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
9236
edd88788
JB
92372016-01-01 Joel Brobecker <brobecker@adacore.com>
9238
9239 * gdbreplay.c (gdbreplay_version): Change copyright year in
9240 version message.
9241 * server.c (gdbserver_version): Likewise.
9242
65da7f14
PP
92432015-12-28 Patrick Palka <patrick@parcs.ath.cx>
9244
9245 * server.c (crc32_table): Delete.
9246 (crc32): Use libiberty's xcrc32 function.
9247
4abd5ed2
JB
92482015-12-22 Joel Brobecker <brobecker@adacore.com>
9249
9250 * lynx-low.c (lynx_delete_thread_callback): New function.
9251 (lynx_mourn): Properly delete our process and all of its
9252 threads. Remove call to clear_inferiors.
9253
0e50fe5c
JB
92542015-12-22 Joel Brobecker <brobecker@adacore.com>
9255
9256 * target.c (thread_search_callback): Add check that
9257 the thread_stopped target callback is not NULL before
9258 calling it.
9259
35adc03f
YQ
92602015-12-21 Yao Qi <yao.qi@linaro.org>
9261
9262 * linux-aarch32-low.h [__aarch64__]: Use arm_abi_breakpoint
9263 arm breakpoint.
9264
bd2b2909
AT
92652015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
9266
9267 * server.c (handle_query): Call target_supports_software_single_step.
9268
7fe5e27e
AT
92692015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
9270
9271 * linux-low.c (single_step): New function.
9272 (linux_resume_one_lwp_throw): Call single_step.
9273 (start_step_over): Likewise.
9274
d9311bfa
AT
92752015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
9276
9277 * Makefile.in (SFILES): Append arch/arm-linux.c,
9278 arch/arm-get-next-pcs.c.
9279 (arm-linux.o): New rule.
9280 (arm-get-next-pcs.o): New rule.
9281 * configure.srv (arm*-*-linux*): Add arm-get-next-pcs.o,
9282 arm-linux.o.
9283 * linux-aarch32-low.c (arm_abi_breakpoint): Remove macro. Moved
9284 to linux-aarch32-low.c.
9285 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
9286 (arm_breakpoint_len, thumb_breakpoint): Likewise.
9287 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
9288 (thumb2_breakpoint_len): Likewise.
9289 (arm_is_thumb_mode): Make non-static.
9290 * linux-aarch32-low.h (arm_abi_breakpoint): New macro. Moved
9291 from linux-aarch32-low.c.
9292 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
9293 (arm_breakpoint_len, thumb_breakpoint): Likewise.
9294 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
9295 (thumb2_breakpoint_len): Likewise.
9296 (arm_is_thumb_mode): New declaration.
9297 * linux-arm-low.c: Include arch/arm-linux.h
9298 aarch/arm-get-next-pcs.h, sys/syscall.h.
9299 (get_next_pcs_ops): New struct.
9300 (get_next_pcs_addr_bits_remove): New function.
9301 (get_next_pcs_is_thumb): New function.
9302 (get_next_pcs_read_memory_unsigned_integer): Likewise.
9303 (arm_sigreturn_next_pc): Likewise.
9304 (get_next_pcs_syscall_next_pc): Likewise.
9305 (arm_gdbserver_get_next_pcs): Likewise.
9306 (struct linux_target_ops) <arm_gdbserver_get_next_pcs>:
9307 Initialize.
9308 * linux-low.h: Move CORE_ADDR vector definition to gdb_vecs.h.
9309 * server.h: Include gdb_vecs.h.
9310
68ce2059
AT
93112015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
9312
9313 * Makefile.in (SFILES): Append common/common-regcache.c.
9314 (OBS): Append common-regcache.o.
9315 (common-regcache.o): New rule.
9316 * regcache.c (init_register_cache): Initialize cache to
9317 REG_UNAVAILABLE.
9318 (regcache_raw_read_unsigned): New function.
9319 * regcache.h (REG_UNAVAILABLE, REG_VALID): Replaced by shared
9320 register_status enum.
9321
fa5308bd
AT
93222015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
9323
9324 * linux-aarch64-low.c (the_low_targets): Rename
9325 breakpoint_reinsert_addr to get_next_pcs.
9326 * linux-arm-low.c (the_low_targets): Likewise.
9327 * linux-bfin-low.c (the_low_targets): Likewise.
9328 * linux-cris-low.c (the_low_targets): Likewise.
9329 * linux-crisv32-low.c (the_low_targets): Likewise.
9330 * linux-low.c (can_software_single_step): Likewise.
9331 (install_software_single_step_breakpoints): New function.
9332 (start_step_over): Use install_software_single_step_breakpoints.
9333 * linux-low.h: New CORE_ADDR vector.
9334 (struct linux_target_ops) Rename breakpoint_reinsert_addr to
9335 get_next_pcs.
9336 * linux-mips-low.c (the_low_targets): Likewise.
9337 * linux-nios2-low.c (the_low_targets): Likewise.
9338 * linux-sparc-low.c (the_low_targets): Likewise.
9339
4a6ed09b
PA
93402015-12-17 Pedro Alves <palves@redhat.com>
9341
9342 * linux-low.c (linux_kill_one_lwp): Remove references to
9343 LinuxThreads.
9344 (kill_lwp): Remove HAVE_TKILL_SYSCALL check. No longer fall back
9345 to 'kill'.
9346 (linux_init_signals): Delete.
9347 (initialize_low): Adjust.
9348 * thread-db.c (thread_db_init): Remove LinuxThreads reference.
9349
7544db95
PA
93502015-12-16 Pedro Alves <palves@redhat.com>
9351
9352 * configure.ac (compiler warning flags): When testing a
9353 -Wno-foo option, check whether -Wfoo works instead.
9354 * configure: Regenerate.
9355
8020350c
DB
93562015-12-11 Don Breazeal <donb@codesourcery.com>
9357
9358 * server.c (process_serial_event): Don't exit from gdbserver
9359 in remote mode if there are still active inferiors.
9360
db91f502
YQ
93612015-12-11 Yao Qi <yao.qi@linaro.org>
9362
9363 * linux-aarch64-low.c (aarch64_breakpoint_at): Call
9364 arm_breakpoint_at if the process is 32-bit.
9365
b37a6290
YQ
93662015-12-11 Yao Qi <yao.qi@linaro.org>
9367
9368 * linux-aarch32-low.c [__aarch64__]: Use arm_abi_breakpoint
9369 arm breakpoint.
9370
17b1509a
YQ
93712015-12-07 Yao Qi <yao.qi@linaro.org>
9372
9373 * configure.srv: Append arm.o to srv_tgtobj for
9374 aarch64*-*-linux* target.
9375 * linux-aarch32-low.c (arm_abi_breakpoint): New macro. Moved
9376 from linux-arm-low.c.
9377 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
9378 (arm_breakpoint_len, thumb_breakpoint): Likewise.
9379 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
9380 (thumb2_breakpoint_len): Likewise.
9381 (arm_is_thumb_mode, arm_breakpoint_at): Likewise.
9382 (arm_breakpoint_kinds): Likewise.
9383 (arm_breakpoint_kind_from_pc): Likewise.
9384 (arm_sw_breakpoint_from_kind): Likewise.
9385 (arm_breakpoint_kind_from_current_state): Likewise.
9386 * linux-aarch32-low.h (arm_breakpoint_kind_from_pc): Declare.
9387 (arm_sw_breakpoint_from_kind): Declare.
9388 (arm_breakpoint_kind_from_current_state): Declare.
9389 (arm_breakpoint_at): Declare.
9390 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): Call
9391 arm_sw_breakpoint_from_kind if process is 32-bit.
9392 (aarch64_breakpoint_kind_from_pc): New function.
9393 (aarch64_breakpoint_kind_from_current_state): New function.
9394 (the_low_target): Initialize fields breakpoint_kind_from_pc
9395 and breakpoint_kind_from_current_state.
9396 * linux-arm-low.c (arm_breakpoint_kinds): Move to
9397 linux-aarch32-low.c.
9398 (arm_abi_breakpoint, arm_eabi_breakpoint): Likewise.
9399 (arm_breakpoint, arm_breakpoint_len): Likewise.
9400 (thumb_breakpoint, thumb_breakpoint_len): Likewise.
9401 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
9402 (arm_is_thumb_mode): Likewise.
9403 (arm_breakpoint_at): Likewise.
9404 (arm_breakpoint_kind_from_pc): Likewise.
9405 (arm_sw_breakpoint_from_kind): Likewise.
9406 (arm_breakpoint_kind_from_current_state): Likewise.
9407
9408 Revert:
9409 2015-08-04 Yao Qi <yao.qi@linaro.org>
9410
9411 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
9412 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
9413 * server.c (extended_protocol): Remove "static".
9414 * server.h (extended_protocol): Declare it.
9415
ece66d65
JS
94162015-12-04 Josh Stone <jistone@redhat.com>
9417
9418 * target.h (struct target_ops) <arch_setup>: Rename to ...
9419 (struct target_ops) <post_create_inferior>: ... this.
9420 (target_arch_setup): Rename to ...
9421 (target_post_create_inferior): ... this, calling post_create_inferior.
9422 * server.c (start_inferior): Update target_arch_setup calls to
9423 target_post_create_inferior.
9424 * linux-low.c (linux_low_ptrace_options): Forward declare.
9425 (linux_arch_setup): Update its comment for general use.
9426 (linux_post_create_inferior): New, run arch_setup and setup ptrace.
9427 (struct linux_target_ops): Use linux_post_create_inferior.
9428 * lynx-low.c (struct lynx_target_ops): Update arch_setup stub comment
9429 to post_create_inferior.
9430 * nto-low.c (struct nto_target_ops): Likewise.
9431 * spu-low.c (struct spu_target_ops): Likewise.
9432 * win32-low.c (struct win32_target_ops): Likewise.
9433
e58c48b4
AT
94342015-12-03 Antoine Tremblay <antoine.tremblay@ericsson.com>
9435
9436 * linux-arm-low.c: Remove duplicate arch/arm.h include.
9437
fbec8956
AT
94382015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
9439
9440 * linux-arm-low.c (arm_reinsert_addr): Remove function.
9441 (struct linux_target_ops <breakpoint_reinsert_addr>: Set to NULL.
9442 * linux-cris-low.c (cris_reinsert_addr> Remove function.
9443 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
9444 * linux-crisv32-low.c (cris_reinsert_addr): Remove function.
9445 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
9446 * linux-mips-low.c (mips_reinsert_addr): Remove function.
9447 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
9448 * linux-nios2-low.c (nios2_reinsert_addr): Remove function.
9449 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
9450 * linux-sparc-low.c (sparc_reinsert_addr): Remove function.
9451 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
9452
9b4c5f87
AT
94532015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
9454
9455 * linux-low.c (linux_look_up_symbols): Don't call
9456 linux_supports_traceclone.
9457 * linux-low.h (thread_db_init): Remove use_events argument.
9458 * thread-db.c (thread_db_use_event): Remove global variable.
9459 (struct thread_db) <td_thr_event_enable_p>: Remove field.
9460 (struct thread_db) <td_create_bp>: Remove field.
9461 (thread_db_create_event): Remove function.
9462 (thread_db_enable_reporting): Likewise.
9463 (find_one_thread): Don't check for thread_db_use_events.
9464 (attach_thread): Likewise.
9465 (thread_db_load_search): Remove td_thr_event_enable_p initialization.
9466 (try_thread_db_load_1): Don't check for thread_db_use_events.
9467 (thread_db_init): Remove use_events argument and thread events
9468 handling.
9469 (remove_thread_event_breakpoints): Remove function.
9470 (thread_db_detach): Remove call to remove_thred_event_breakpoints.
9471
7d00775e
AT
94722015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
9473
9474 * linux-aarch64-low.c (aarch64_supports_hardware_single_step):
9475 New function.
9476 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9477 * linux-arm-low.c (arm_supports_hardware_single_step): New function.
9478 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9479 * linux-bfin-low.c (bfin_supports_hardware_single_step): New function.
9480 (struct linux_target_ops) <bfin_supports_hardware_single_step>:
9481 Initialize.
9482 * linux-crisv32-low.c (cris_supports_hardware_single_step):
9483 New function.
9484 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9485 * linux-low.c (can_hardware_single_step): Use
9486 supports_hardware_single_step.
9487 (can_software_single_step): New function.
9488 (start_step_over): Call can_software_single_step.
9489 (linux_supports_hardware_single_step): New function.
9490 (struct target_ops) <supports_software_single_step>: Initialize.
9491 * linux-low.h (struct linux_target_ops)
9492 <supports_hardware_single_step>: Initialize.
9493 * linux-m32r-low.c (m32r_supports_hardware_single_step): New function.
9494 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9495 * linux-ppc-low.c (ppc_supports_hardware_single_step): New function.
9496 (struct linux_target_ops) <supports_hardware_single_step> Initialize.
9497 * linux-s390-low.c (s390_supports_hardware_single_step): New function.
9498 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9499 * linux-sh-low.c (sh_supports_hardware_single_step): New function.
9500 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9501 * linux-tic6x-low.c (tic6x_supports_hardware_single_step): New function.
9502 (struct linux_target_ops) <tic6x_supports_hardware_single_step>:
9503 Initialize.
9504 * linux-tile-low.c (tile_supports_hardware_single_step): New function.
9505 (struct linux_target_ops) <tile_supports_hardware_single_step>:
9506 Initialize.
9507 * linux-x86-low.c (x86_supports_hardware_single_step) New function.
9508 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9509 * linux-xtensa-low.c (xtensa_supports_hardware_single_step):
9510 New function.
9511 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9512 * target.h (struct target_ops): <supports_software_single_step>:
9513 New field.
9514 (target_supports_software_single_step): New macro.
9515
2d97cd35
AT
95162015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
9517
9518 * linux-low.c (linux_wait_1): Fix pc advance condition.
9519 * mem-break.c (reinsert_breakpoint_inserted_here): New function.
9520 * mem-break.h (reinsert_breakpoint_inserted_here): New declaration.
9521
769ef81f
AT
95222015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
9523
9524 * linux-arm-low.c (arm_is_thumb_mode): New function.
9525 (arm_breakpoint_at): Use arm_is_thumb_mode.
9526 (arm_breakpoint_kind_from_current_state): New function.
9527 (struct linux_target_ops) <breakpoint_kind_from_current_state>:
9528 Initialize.
9529 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_current_state.
9530 (linux_breakpoint_kind_from_current_state): New function.
9531 (struct target_ops <breakpoint_kind_from_current_state>: Initialize.
9532 * linux-low.h (struct linux_target_ops)
9533 <breakpoint_kind_from_current_state>: New field.
9534 * target.h (struct target_ops): Likewise.
9535 (target_breakpoint_kind_from_current_state): New macro.
9536
1bebeeca
PA
95372015-11-30 Pedro Alves <palves@redhat.com>
9538
9539 * linux-low.c (linux_resume): Wake up the event loop before
9540 returning.
9541
a67a9fae
PA
95422015-11-30 Pedro Alves <palves@redhat.com>
9543
9544 * mem-break.c (check_gdb_bp_preconditions): Remove current_thread
9545 check.
9546 (set_gdb_breakpoint): If prepare_to_access_memory fails, set *ERR
9547 to -1.
9548 * target.c (struct thread_search): New structure.
9549 (thread_search_callback): New function.
9550 (prev_general_thread): New global.
9551 (prepare_to_access_memory, done_accessing_memory): New functions.
9552 * target.h (prepare_to_access_memory, done_accessing_memory):
9553 Replace macros with function declarations.
9554
f2faf941
PA
95552015-11-30 Pedro Alves <palves@redhat.com>
9556
9557 PR 14618
9558 * linux-low.c (linux_wait_1): If the last resumed thread is gone,
9559 report TARGET_WAITKIND_NO_RESUMED.
9560 * remote-utils.c (prepare_resume_reply): Handle
9561 TARGET_WAITKIND_NO_RESUMED.
9562 * server.c (report_no_resumed): New global.
9563 (handle_query) <qSupported>: Handle "no-resumed+". Report
9564 "no-resumed+" support.
9565 (resume): When the target reports TARGET_WAITKIND_NO_RESUMED, only
9566 return error if the client doesn't support no-resumed events.
9567 (push_stop_notification): New function.
9568 (handle_target_event): Use it. Report TARGET_WAITKIND_NO_RESUMED
9569 events if the client supports them.
9570
a681f9c9
PA
95712015-11-30 Pedro Alves <palves@redhat.com>
9572
9573 * linux-low.c (thread_still_has_status_pending_p): Don't check
9574 vCont;t here.
9575 (lwp_resumed): New function.
9576 (status_pending_p_callback): Return early if the LWP is not
9577 supposed to be resumed.
9578
65706a29
PA
95792015-11-30 Pedro Alves <palves@redhat.com>
9580
9581 * linux-low.c (handle_extended_wait): Assert that the LWP's
9582 waitstatus is TARGET_WAITKIND_IGNORE. If GDB wants to hear about
9583 thread create events, leave the new child's status pending.
9584 (linux_low_filter_event): If GDB wants to hear about thread exit
9585 events, leave the LWP marked dead and don't delete it.
9586 (linux_wait_for_event_filtered): Don't check for thread exit.
9587 (filter_exit_event): New function.
9588 (linux_wait_1): Use it, when returning an exit event.
9589 (linux_resume_one_lwp_throw): Assert that the LWP's
9590 waitstatus is TARGET_WAITKIND_IGNORE.
9591 * remote-utils.c (prepare_resume_reply): Handle
9592 TARGET_WAITKIND_THREAD_CREATED and TARGET_WAITKIND_THREAD_EXITED.
9593 * server.c (report_thread_events): New global.
9594 (handle_general_set): Handle QThreadEvents.
9595 (handle_query) <qSupported>: Handle and report QThreadEvents+;
9596 (handle_target_event): Handle TARGET_WAITKIND_THREAD_CREATED and
9597 TARGET_WAITKIND_THREAD_EXITED.
9598 * server.h (report_thread_events): Declare.
9599
56cf4bed
PA
96002015-11-30 Pedro Alves <palves@redhat.com>
9601
9602 * linux-low.c (resume_stopped_resumed_lwps): Don't check whether
9603 the thread's last_resume_kind was resume_stop.
9604
500c1d85
PA
96052015-11-30 Pedro Alves <palves@redhat.com>
9606
9607 * linux-low.c (linux_attach): In non-stop mode, wait for one stop
9608 before returning.
9609
de979965
PA
96102015-11-30 Pedro Alves <palves@redhat.com>
9611
9612 * server.c (handle_v_requests): Handle vCtrlC.
9613
34c65914
PA
96142015-11-30 Pedro Alves <palves@redhat.com>
9615
9616 * gdbthread.h (find_any_thread_of_pid): Declare.
9617 * inferiors.c (thread_of_pid, find_any_thread_of_pid): New
9618 functions.
9619 * server.c (handle_query): If current_thread is NULL, look for
9620 another thread of the selected process.
9621
79efa585 96222015-11-26 Daniel Colascione <dancol@dancol.org>
01a49af8 9623 Simon Marchi <simon.marchi@ericsson.com>
79efa585
SM
9624
9625 * linux-low.c (linux_target_ops): Use linux_proc_tid_get_name.
9626 * server.c (handle_qxfer_threads_worker): Refactor to include thread
9627 name in reply.
9628 * target.h (struct target_ops) <thread_name>: New field.
9629 (target_thread_name): New macro.
9630
80d82c19
JB
96312015-11-23 Joel Brobecker <brobecker@adacore.com>
9632
9633 * regcache.h (regcache_invalidate_pid): Add declaration.
9634 * regcache.c (regcache_invalidate_pid): New function, extracted
9635 from regcache_invalidate.
9636 (regcache_invalidate): Reimplement using regcache_invalidate_pid.
9637 Add trivial documentation comment.
9638 * lynx-low.c: Use regcache_invalidate_pid instead of
9639 regcache_invalidate.
9640
64da5dd5
JB
96412015-11-23 Joel Brobecker <brobecker@adacore.com>
9642
9643 * configure.ac: Do not call AC_CHECK_TYPES for Elf32_auxv_t
9644 and Elf64_auxv_t if the target is Android.
9645
37ce4055
DE
96462015-11-22 Doug Evans <xdje42@gmail.com>
9647
9648 * target.h: #include <sys/types.h>.
9649
06e03fff
PA
96502015-11-19 Pedro Alves <palves@redhat.com>
9651
9652 * linux-low.c (linux_process_qsupported): Change prototype.
9653 Adjust.
9654 * linux-low.h (struct linux_target_ops) <process_qsupported>:
9655 Change prototype.
9656 * linux-x86-low.c (x86_linux_process_qsupported): Change prototype
9657 and adjust to loop over all features.
9658 * server.c (handle_query) <qSupported>: Adjust to call
9659 target_process_qsupported once, passing it a vector of unprocessed
9660 features.
9661 * target.h (struct target_ops) <process_qsupported>: Change
9662 prototype.
9663 (target_process_qsupported): Adjust.
9664
9a084706
PA
96652015-11-19 Pedro Alves <palves@redhat.com>
9666
9667 * configure.ac (ERROR_ON_WARNING): Don't check whether in C++
9668 mode.
9669 * configure: Regenerate.
9670
dad44a1f
PA
96712015-11-19 Pedro Alves <palves@redhat.com>
9672
9673 * configure: Regenerate.
9674
231c0592
YQ
96752015-11-19 Yao Qi <yao.qi@linaro.org>
9676
9677 * linux-aarch64-low.c (emit_data_processing_reg): Change opcode
9678 type to uint32_t.
9679
6c1c9a8b
YQ
96802015-11-19 Yao Qi <yao.qi@linaro.org>
9681
9682 * linux-aarch64-low.c (enum aarch64_operand_type): New.
9683 (struct aarch64_operand): Move enum out.
9684
9caa3311
YQ
96852015-11-19 Yao Qi <yao.qi@linaro.org>
9686
9687 * linux-aarch64-low.c (aarch64_fill_fpregset): Cast buf to
9688 struct user_fpsimd_state *.
9689 (aarch64_store_fpregset): Likewise.
9690
6a69a054
YQ
96912015-11-19 Yao Qi <yao.qi@linaro.org>
9692
9693 * linux-aarch64-low.c (aarch64_fill_gregset): Cast buf to
9694 struct user_pt_regs *.
9695 (aarch64_store_gregset): Likewise.
9696
1798301e
PA
96972015-11-18 Pedro Alves <palves@redhat.com>
9698
9699 * Makefile.in (all_object_files): Add $IPA_OBJS.
9700
ce7715e2
PA
97012015-11-17 Pedro Alves <palves@redhat.com>
9702
9703 * win32-low.c (win32_resume): Use gdb_signal_from_host,
9704 GDB_SIGNAL_0 and gdb_signal_to_string.
9705
c0879059
PA
97062015-11-17 Pedro Alves <palves@redhat.com>
9707
9708 * win32-low.c (handle_output_debug_string): Remove parameter.
9709 (win32_kill): Remove our_status local and adjust call to
9710 handle_output_debug_string.
9711 (get_child_debug_event): Adjust call to
9712 handle_output_debug_string.
9713
1996e237
SM
97142015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9715
9716 * linux-mips-low.c (mips_fill_gregset): Add cast.
9717 (mips_store_gregset): Likewise.
9718 (mips_fill_fpregset): Likewise.
9719 (mips_store_fpregset): Likewise.
9720
cbec665b
SM
97212015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9722
9723 * linux-mips-low.c (mips_add_watchpoint): Rename private to
9724 priv.
9725
eb3e3c67
SM
97262015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9727
9728 * linux-mips-low.c (mips_linux_new_thread): Change type of
9729 watch_type to enum target_hw_bp_type.
9730
171de4b8
SM
97312015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9732
9733 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type):
9734 Change return type to arm_hwbp_type.
9735
04248ead
SM
97362015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9737
9738 * linux-aarch32-low.c (arm_fill_gregset): Add cast.
9739 (arm_store_gregset): Likewise.
9740 * linux-arm-low.c (arm_get_hwcap): Likewise.
9741 (arm_read_description): Likewise.
9742
04b3479c
SM
97432015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9744
9745 * linux-aarch32-low.c (aarch32_regsets): Use NULL_REGSET.
9746
2bc84e8a
SM
97472015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9748
9749 * linux-ppc-low.c (ppc_get_hwcap): Add cast.
9750 (ppc_fill_vsxregset): Likewise.
9751 (ppc_store_vsxregset): Likewise.
9752 (ppc_fill_vrregset): Likewise.
9753 (ppc_store_vrregset): Likewise.
9754 (ppc_fill_evrregset): Likewise.
9755 (ppc_store_evrregset): Likewise.
9756
e6c5bb05
SM
97572015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9758
9759 * linux-ppc-low.c (ppc_usrregs_info): Remove
9760 forward-declaration.
9761 (ppc_arch_setup): Move lower in file.
9762
7ea45d72
SM
97632015-10-30 Simon Marchi <simon.marchi@ericsson.com>
9764
9765 * proc-service.c (ps_pdread): Change CORE_ADDR cast to uintptr_t.
9766 (ps_pdwrite): Likewise.
9767
69291610
HW
97682015-10-29 Henrik Wallin <henrik.wallin@windriver.com>
9769
9770 * linux-arm-low.c (arm_new_thread): Move pointer dereference
9771 to after assert checks.
9772
b42945fd
SM
97732015-10-29 Simon Marchi <simon.marchi@ericsson.com>
9774
9775 * proc-service.c (ps_pdread): Add/adjust casts.
9776 (ps_pdwrite): Add/adjust casts.
9777
d6f85c84
SM
97782015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
9779
9780 * server.c (handle_search_memory_1): Cast return value of
9781 memmem.
9782
f98cd059
SM
97832015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
9784
9785 * server.c (write_qxfer_response): Change type of data to
9786 gdb_byte *.
9787
d2412fa5
PA
97882015-10-29 Pedro Alves <palves@redhat.com>
9789
9790 * mem-break.c (Z_packet_to_bkpt_type): Add cast.
9791
c17414a2
PA
97922015-10-29 Pedro Alves <palves@redhat.com>
9793
9794 * tracepoint.c (clear_installed_tracepoints): Add casts.
9795
e053fbc4
PA
97962015-10-29 Pedro Alves <palves@redhat.com>
9797
9798 * server.c (handle_v_cont, process_serial_event): Add enum
9799 gdb_signal casts to signal parsing code.
9800
add67df8
PA
98012015-10-29 Pedro Alves <palves@redhat.com>
9802
9803 * linux-low.h (NULL_REGSET): Define.
9804 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
9805 * linux-arm-low.c (arm_regsets): Likewise.
9806 * linux-crisv32-low.c (cris_regsets): Likewise.
9807 * linux-m68k-low.c (m68k_regsets): Likewise.
9808 * linux-mips-low.c (mips_regsets): Likewise.
9809 * linux-nios2-low.c (nios2_regsets): Likewise.
9810 * linux-ppc-low.c (ppc_regsets): Likewise.
9811 * linux-s390-low.c (s390_regsets): Likewise.
9812 * linux-sh-low.c (sh_regsets): Likewise.
9813 * linux-sparc-low.c (sparc_regsets): Likewise.
9814 * linux-tic6x-low.c (tic6x_regsets): Likewise.
9815 * linux-tile-low.c (tile_regsets): Likewise.
9816 * linux-x86-low.c (x86_regsets): Likewise.
9817 * linux-xtensa-low.c (xtensa_regsets): Likewise.
9818
50bc912a
PA
98192015-10-29 Pedro Alves <palves@redhat.com>
9820
9821 * linux-low.h (NULL_REGSET): Define.
9822 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
9823 * linux-arm-low.c (arm_regsets): Likewise.
9824 * linux-crisv32-low.c (cris_regsets): Likewise.
9825 * linux-m68k-low.c (m68k_regsets): Likewise.
9826 * linux-mips-low.c (mips_regsets): Likewise.
9827 * linux-nios2-low.c (nios2_regsets): Likewise.
9828 * linux-ppc-low.c (ppc_regsets): Likewise.
9829 * linux-s390-low.c (s390_regsets): Likewise.
9830 * linux-sh-low.c (sh_regsets): Likewise.
9831 * linux-sparc-low.c (sparc_regsets): Likewise.
9832 * linux-tic6x-low.c (tic6x_regsets): Likewise.
9833 * linux-tile-low.c (tile_regsets): Likewise.
9834 * linux-x86-low.c (x86_regsets): Likewise.
9835 * linux-xtensa-low.c (xtensa_regsets): Likewise.
9836
682b2546
DE
98372015-10-26 Doug Evans <dje@google.com>
9838
9839 * linux-low.c (__SIGRTMIN): Move to nat/linux-nat.h.
9840
963843d4
DE
98412015-10-26 Doug Evans <dje@google.com>
9842
9843 * linux-low.c (W_STOPCODE): Moved to common/gdb_wait.h.
9844
d41401ac
DE
98452015-10-26 Doug Evans <dje@google.com>
9846
9847 * thread-db.c (find_one_thread): Cast ti.ti_tid to unsigned long
9848 for debug_printf.
9849 (attach_thread, find_new_threads_callback): Ditto.
9850
3db28855
AT
98512015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
9852
9853 * mem-break.h (set_breakpoint_data): Remove.
9854
fb78e89c
AT
98552015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
9856
9857 * nto-low.c (nto_sw_breakpoint_from_kind): New function.
9858 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
9859 (initialize_low): Remove set_breakpoint_data call.
9860 * spu-low.c (spu_sw_breakpoint_from_kind): New function.
9861 (struct target_ops) <sw_breakpoint_from_kind>: Iniitalize.
9862 (initialize_low): Remove set_breakpoint_data call.
9863 * win32-low.c (win32_sw_breakpoint_from_kind): New function.
9864 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
9865 (initialize_low): Remove set_breakpoint_data call.
9866
2e6ee069
AT
98672015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
9868
9869 * linux-low.c (default_breakpoint_kind_from_pc): Move to target.c.
9870 * mem-break.c (set_breakpoint_at): Use target_breakpoint_kind_from_pc.
9871 * target.c (default_breakpoint_kind_from_pc): Moved from linux-low.c
9872 * target.h (target_breakpoint_kind_from_pc): New macro.
9873
1652a986
AT
98742015-10-22 Antoine Tremblay <antoine.tremblay@ericsson.com>
9875
9876 * linux-low.c (default_breakpoint_kind_from_pc): New function.
9877 (linux_breakpoint_kind_from_pc): Use default_breakpoint_kind_from_pc for
9878 the default breakpoint kind.
9879
abeead09
AT
98802015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9881
9882 * linux-arm-low.c (arm_supports_z_point_type): Add software
9883 breakpoint support.
9884
b0b4b501
AT
98852015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9886
9887 * linux-arm-low.c: Refactor breakpoint definitions.
9888 (arm_breakpoint_at): Adjust for arm_abi_breakpoint.
9889 (arm_sw_breakpoint_from_kind): Adjust for arm_breakpoint.
9890
8689682c
AT
98912015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9892
9893 * Makefile.in: Add arm.c/o.
9894 * configure.srv: Likewise.
9895 * linux-arm-low.c (arm_breakpoint_kinds): New enum.
9896 (arm_breakpoint_kind_from_pc): New function.
9897 (arm_sw_breakpoint_from_kind): Return proper kind.
9898 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize.
9899
27165294
AT
99002015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9901
9902 * linux-low.c (initialize_low): Ajdust for breakpoint global variables
9903 removal.
9904 * mem-break.c : Remove breakpoint_data/breakpoint_len global variables.
9905 (struct raw_breakpoint) <size>: Remove.
9906 (struct raw_breakpoint) <kind>: Add.
9907 (bp_size): New function.
9908 (bp_opcode): Likewise.
9909 (find_raw_breakpoint_at): Adjust for kind.
9910 (insert_memory_breakpoint): Adjust for kind call bp_size,bp_opcode.
9911 (remove_memory_breakpoint): Adjust for kind call bp_size.
9912 (set_raw_breakpoint_at): Adjust for kind.
9913 (set_breakpoint): Likewise.
9914 (set_breakpoint_at): Call breakpoint_kind_from_pc.
9915 (delete_raw_breakpoint): Adjust for kind.
9916 (delete_breakpoint): Likewise.
9917 (find_gdb_breakpoint): Likewise.
9918 (set_gdb_breakpoint_1): Likewise.
9919 (set_gdb_breakpoint): Likewise.
9920 (delete_gdb_breakpoint_1): Likewise.
9921 (delete_gdb_breakpoint): Likewise.
9922 (uninsert_raw_breakpoint): Likewise.
9923 (reinsert_raw_breakpoint): Likewise.
9924 (set_breakpoint_data): Remove.
9925 (validate_inserted_breakpoint): Adjust for kind call bp_size,bp_opcode.
9926 (check_mem_read): Adjust for kind call bp_size.
9927 (check_mem_write): Adjust for kind call bp_size,bp_opcode.
9928 (clone_one_breakpoint): Adjust for kind.
9929 * mem-break.h (set_gdb_breakpoint): Likewise.
9930 (delete_gdb_breakpoint): Likewise.
9931 * server.c (process_serial_event): Likewise.
9932
dd373349
AT
99332015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9934
9935 * linux-aarch64-low.c (aarch64_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-arm-low.c (arm_breakpoint_kind_from_pc): New function.
9941 (arm_sw_breakpoint_from_kind): New function.
9942 * linux-bfin-low.c (bfin_sw_breakpoint_from_kind): New function.
9943 (struct linux_target_ops) <breakpoint>: Remove.
9944 (struct linux_target_ops) <breakpoint_len>: Remove.
9945 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9946 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9947 * linux-cris-low.c (cris_sw_breakpoint_from_kind): New function.
9948 (struct linux_target_ops) <breakpoint>: Remove.
9949 (struct linux_target_ops) <breakpoint_len>: Remove.
9950 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9951 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9952 * linux-crisv32-low.c (cris_sw_breakpoint_from_kind): New function.
9953 (struct linux_target_ops) <breakpoint>: Remove.
9954 (struct linux_target_ops) <breakpoint_len>: Remove.
9955 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9956 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9957 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_pc
9958 and sw_breakpoint_from_kind to increment the pc.
9959 (linux_breakpoint_kind_from_pc): New function.
9960 (linux_sw_breakpoint_from_kind): New function.
9961 (struct target_ops) <sw_breakpoint_from_kind>: Initialize field.
9962 (initialize_low): Call breakpoint_kind_from_pc and
9963 sw_breakpoint_from_kind to replace breakpoint_data/len.
9964 * linux-low.h (struct linux_target_ops) <breakpoint_kind_from_pc>:
9965 New field.
9966 (struct linux_target_ops) <sw_breakpoint_from_kind>: Likewise.
9967 * linux-m32r-low.c (m32r_sw_breakpoint_from_kind): New function.
9968 (struct linux_target_ops) <breakpoint>: Remove.
9969 (struct linux_target_ops) <breakpoint_len>: Remove.
9970 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9971 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9972 * linux-m68k-low.c (m68k_sw_breakpoint_from_kind): New function.
9973 (struct linux_target_ops) <breakpoint>: Remove.
9974 (struct linux_target_ops) <breakpoint_len>: Remove.
9975 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9976 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9977 * linux-mips-low.c (mips_sw_breakpoint_from_kind): New function.
9978 (struct linux_target_ops) <breakpoint>: Remove.
9979 (struct linux_target_ops) <breakpoint_len>: Remove.
9980 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9981 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9982 * linux-nios2-low.c (nios2_sw_breakpoint_from_kind): New function.
9983 (struct linux_target_ops) <breakpoint>: Remove.
9984 (struct linux_target_ops) <breakpoint_len>: Remove.
9985 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9986 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9987 * linux-ppc-low.c (ppc_sw_breakpoint_from_kind): New function.
9988 (struct linux_target_ops) <breakpoint>: Remove.
9989 (struct linux_target_ops) <breakpoint_len>: Remove.
9990 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9991 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9992 * linux-s390-low.c (s390_sw_breakpoint_from_kind): New function.
9993 (struct linux_target_ops) <breakpoint>: Remove.
9994 (struct linux_target_ops) <breakpoint_len>: Remove.
9995 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9996 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9997 * linux-sh-low.c (sh_sw_breakpoint_from_kind): New function.
9998 (struct linux_target_ops) <breakpoint>: Remove.
9999 (struct linux_target_ops) <breakpoint_len>: Remove.
10000 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
10001 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
10002 * linux-sparc-low.c (sparc_sw_breakpoint_from_kind): New function.
10003 (struct linux_target_ops) <breakpoint>: Remove.
10004 (struct linux_target_ops) <breakpoint_len>: Remove.
10005 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
10006 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
10007 * linux-tic6x-low.c (tic6x_sw_breakpoint_from_kind): New function.
10008 (struct linux_target_ops) <breakpoint>: Remove.
10009 (struct linux_target_ops) <breakpoint_len>: Remove.
10010 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
10011 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
10012 * linux-tile-low.c (tile_sw_breakpoint_from_kind): New function.
10013 * linux-x86-low.c (x86_sw_breakpoint_from_kind): New function.
10014 (struct linux_target_ops) <breakpoint>: Remove.
10015 (struct linux_target_ops) <breakpoint_len>: Remove.
10016 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
10017 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
10018 * linux-xtensa-low.c (xtensa_sw_breakpoint_from_kind) New function.
10019 (struct linux_target_ops) <breakpoint>: Remove.
10020 (struct linux_target_ops) <breakpoint_len>: Remove.
10021 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
10022 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
10023
4cd98a19
AT
100242015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
10025
10026 * linux-cris-low.c (cris_get_pc): Remove void arg.
10027
774ee6d2
AR
100282015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
10029
10030 * gdbserver/nto-low.c (nto_insert_point, nto_remove_point): Fix
10031 variable name.
10032
833dcd29
AR
100332015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
10034
10035 * inferiors.c (thread_pid_matches_callback): New function.
10036 (find_thread_process): New function.
10037 (remove_thread): Reset current_thread.
10038 (remove_process): Assert threads have been removed first.
10039
8d689ee5
YQ
100402015-10-15 Yao Qi <yao.qi@linaro.org>
10041
10042 * linux-aarch64-low.c (aarch64_insert_point): Set len to 2
10043 if it is 3.
10044 (aarch64_remove_point): Likewise.
10045 * regcache.c (regcache_register_size): New function.
10046
1c2e1515
YQ
100472015-10-12 Yao Qi <yao.qi@linaro.org>
10048
10049 * linux-aarch64-low.c: Update all callers as emit_load_store
10050 is renamed to aarch64_emit_load_store.
10051
e1c587c3
YQ
100522015-10-12 Yao Qi <yao.qi@linaro.org>
10053
10054 * linux-aarch64-low.c: Update all callers of function renaming
10055 from emit_insn to aarch64_emit_insn.
10056
b6542f81
YQ
100572015-10-12 Yao Qi <yao.qi@linaro.org>
10058
10059 * linux-aarch64-low.c (enum aarch64_opcodes): Move to
10060 arch/aarch64-insn.h.
10061 (struct aarch64_memory_operand): Likewise.
10062 (ENCODE): Likewise.
10063 (emit_insn): Move to arch/aarch64-insn.c.
10064 (emit_b, emit_bcond, emit_cb, emit_tb): Remove.
10065 (emit_load_store): Move to arch/aarch64-insn.c.
10066 (emit_ldr, emit_ldrb, emit_ldrsw, emit_nop): Remove.
10067 (can_encode_int32): Remove.
10068
246994ce
YQ
100692015-10-12 Yao Qi <yao.qi@linaro.org>
10070
10071 * linux-aarch64-low.c (extract_signed_bitfield): Remove.
10072 (aarch64_decode_ldr_literal): Move to gdb/arch/aarch64-insn.c.
10073 (aarch64_relocate_instruction): Likewise.
10074 (struct aarch64_insn_data): Move to gdb/arch/aarch64-insn.h.
10075 (struct aarch64_insn_visitor): Likewise.
10076
0badd99f
YQ
100772015-10-12 Yao Qi <yao.qi@linaro.org>
10078
10079 * linux-aarch64-low.c (struct aarch64_insn_data): New.
10080 (struct aarch64_insn_visitor): New.
10081 (struct aarch64_insn_relocation_data): New.
10082 (aarch64_ftrace_insn_reloc_b): New function.
10083 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
10084 (aarch64_ftrace_insn_reloc_cb): Likewise.
10085 (aarch64_ftrace_insn_reloc_tb): Likewise.
10086 (aarch64_ftrace_insn_reloc_adr): Likewise.
10087 (aarch64_ftrace_insn_reloc_ldr_literal): Likewise.
10088 (aarch64_ftrace_insn_reloc_others): Likewise.
10089 (visitor): New.
10090 (aarch64_relocate_instruction): Use visitor.
10091
dfaffe9d
YQ
100922015-10-12 Yao Qi <yao.qi@linaro.org>
10093
10094 * linux-aarch64-low.c (aarch64_relocate_instruction): Return
10095 int. Add argument buf.
10096 (aarch64_install_fast_tracepoint_jump_pad): Pass buf to
10097 aarch64_relocate_instruction.
10098
70b439f0
YQ
100992015-10-12 Yao Qi <yao.qi@linaro.org>
10100
10101 * linux-aarch64-low.c (aarch64_relocate_instruction): Add
10102 argument insn. Remove local variable insn. Don't call
10103 target_read_uint32.
10104 (aarch64_install_fast_tracepoint_jump_pad): Call
10105 target_read_uint32.
10106
7781c06f
YQ
101072015-09-30 Yao Qi <yao.qi@linaro.org>
10108
10109 * linux-aarch64-low.c (emit_movk): Shorten a long line.
10110 (emit_load_store_pair): Likewise.
10111
9a3c8263
SM
101122015-09-25 Simon Marchi <simon.marchi@ericsson.com>
10113
10114 * dll.c (match_dll): Add cast(s).
10115 (unloaded_dll): Likewise.
10116 * linux-low.c (second_thread_of_pid_p): Likewise.
10117 (delete_lwp_callback): Likewise.
10118 (count_events_callback): Likewise.
10119 (select_event_lwp_callback): Likewise.
10120 (linux_set_resume_request): Likewise.
10121 * server.c (accumulate_file_name_length): Likewise.
10122 (emit_dll_description): Likewise.
10123 (handle_qxfer_threads_worker): Likewise.
10124 (visit_actioned_threads): Likewise.
10125 * thread-db.c (any_thread_of): Likewise.
10126 * tracepoint.c (same_process_p): Likewise.
10127 (match_blocktype): Likewise.
10128 (build_traceframe_info_xml): Likewise.
10129
224c3ddb
SM
101302015-09-25 Simon Marchi <simon.marchi@ericsson.com>
10131
10132 * ax.c (gdb_parse_agent_expr): Add cast to allocation result
10133 assignment.
10134 (gdb_unparse_agent_expr): Likewise.
10135 * hostio.c (require_data): Likewise.
10136 (handle_pread): Likewise.
10137 * linux-low.c (disable_regset): Likewise.
10138 (fetch_register): Likewise.
10139 (store_register): Likewise.
10140 (get_dynamic): Likewise.
10141 (linux_qxfer_libraries_svr4): Likewise.
10142 * mem-break.c (delete_fast_tracepoint_jump): Likewise.
10143 (set_fast_tracepoint_jump): Likewise.
10144 (uninsert_fast_tracepoint_jumps_at): Likewise.
10145 (reinsert_fast_tracepoint_jumps_at): Likewise.
10146 (validate_inserted_breakpoint): Likewise.
10147 (clone_agent_expr): Likewise.
10148 * regcache.c (init_register_cache): Likewise.
10149 * remote-utils.c (putpkt_binary_1): Likewise.
10150 (decode_M_packet): Likewise.
10151 (decode_X_packet): Likewise.
10152 (look_up_one_symbol): Likewise.
10153 (relocate_instruction): Likewise.
10154 (monitor_output): Likewise.
10155 * server.c (handle_search_memory): Likewise.
10156 (handle_qxfer_exec_file): Likewise.
10157 (handle_qxfer_libraries): Likewise.
10158 (handle_qxfer): Likewise.
10159 (handle_query): Likewise.
10160 (handle_v_cont): Likewise.
10161 (handle_v_run): Likewise.
10162 (captured_main): Likewise.
10163 * target.c (write_inferior_memory): Likewise.
10164 * thread-db.c (try_thread_db_load_from_dir): Likewise.
10165 * tracepoint.c (init_trace_buffer): Likewise.
10166 (add_tracepoint_action): Likewise.
10167 (add_traceframe): Likewise.
10168 (add_traceframe_block): Likewise.
10169 (cmd_qtdpsrc): Likewise.
10170 (cmd_qtdv): Likewise.
10171 (cmd_qtstatus): Likewise.
10172 (response_source): Likewise.
10173 (response_tsv): Likewise.
10174 (cmd_qtnotes): Likewise.
10175 (gdb_collect): Likewise.
10176 (initialize_tracepoint): Likewise.
10177
afbe19f8
PL
101782015-09-21 Pierre Langlois <pierre.langlois@arm.com>
10179
10180 * linux-aarch64-low-.c: Include ax.h and tracepoint.h.
10181 (enum aarch64_opcodes) <RET>, <SUBS>, <AND>, <ORR>, <ORN>,
10182 <EOR>, <LSLV>, <LSRV>, <ASRV>, <SBFM>, <UBFM>, <CSINC>, <MUL>,
10183 <NOP>: New.
10184 (enum aarch64_condition_codes): New enum.
10185 (w0): New static global.
10186 (fp): Likewise.
10187 (lr): Likewise.
10188 (struct aarch64_memory_operand) <type>: New
10189 MEMORY_OPERAND_POSTINDEX type.
10190 (postindex_memory_operand): New helper function.
10191 (emit_ret): New function.
10192 (emit_load_store_pair): New function, factored out of emit_stp
10193 with support for MEMORY_OPERAND_POSTINDEX.
10194 (emit_stp): Rewrite using emit_load_store_pair.
10195 (emit_ldp): New function.
10196 (emit_load_store): Likewise.
10197 (emit_ldr): Mention post-index instruction in comment.
10198 (emit_ldrh): New function.
10199 (emit_ldrb): New function.
10200 (emit_ldrsw): Mention post-index instruction in comment.
10201 (emit_str): Likewise.
10202 (emit_subs): New function.
10203 (emit_cmp): Likewise.
10204 (emit_and): Likewise.
10205 (emit_orr): Likewise.
10206 (emit_orn): Likewise.
10207 (emit_eor): Likewise.
10208 (emit_mvn): Likewise.
10209 (emit_lslv): Likewise.
10210 (emit_lsrv): Likewise.
10211 (emit_asrv): Likewise.
10212 (emit_mul): Likewise.
10213 (emit_sbfm): Likewise.
10214 (emit_sbfx): Likewise.
10215 (emit_ubfm): Likewise.
10216 (emit_ubfx): Likewise.
10217 (emit_csinc): Likewise.
10218 (emit_cset): Likewise.
10219 (emit_nop): Likewise.
10220 (emit_ops_insns): New helper function.
10221 (emit_pop): Likewise.
10222 (emit_push): Likewise.
10223 (aarch64_emit_prologue): New function.
10224 (aarch64_emit_epilogue): Likewise.
10225 (aarch64_emit_add): Likewise.
10226 (aarch64_emit_sub): Likewise.
10227 (aarch64_emit_mul): Likewise.
10228 (aarch64_emit_lsh): Likewise.
10229 (aarch64_emit_rsh_signed): Likewise.
10230 (aarch64_emit_rsh_unsigned): Likewise.
10231 (aarch64_emit_ext): Likewise.
10232 (aarch64_emit_log_not): Likewise.
10233 (aarch64_emit_bit_and): Likewise.
10234 (aarch64_emit_bit_or): Likewise.
10235 (aarch64_emit_bit_xor): Likewise.
10236 (aarch64_emit_bit_not): Likewise.
10237 (aarch64_emit_equal): Likewise.
10238 (aarch64_emit_less_signed): Likewise.
10239 (aarch64_emit_less_unsigned): Likewise.
10240 (aarch64_emit_ref): Likewise.
10241 (aarch64_emit_if_goto): Likewise.
10242 (aarch64_emit_goto): Likewise.
10243 (aarch64_write_goto_address): Likewise.
10244 (aarch64_emit_const): Likewise.
10245 (aarch64_emit_call): Likewise.
10246 (aarch64_emit_reg): Likewise.
10247 (aarch64_emit_pop): Likewise.
10248 (aarch64_emit_stack_flush): Likewise.
10249 (aarch64_emit_zero_ext): Likewise.
10250 (aarch64_emit_swap): Likewise.
10251 (aarch64_emit_stack_adjust): Likewise.
10252 (aarch64_emit_int_call_1): Likewise.
10253 (aarch64_emit_void_call_2): Likewise.
10254 (aarch64_emit_eq_goto): Likewise.
10255 (aarch64_emit_ne_goto): Likewise.
10256 (aarch64_emit_lt_goto): Likewise.
10257 (aarch64_emit_le_goto): Likewise.
10258 (aarch64_emit_gt_goto): Likewise.
10259 (aarch64_emit_ge_got): Likewise.
10260 (aarch64_emit_ops_impl): New static global variable.
10261 (aarch64_emit_ops): New target function, return
10262 &aarch64_emit_ops_impl.
10263 (struct linux_target_ops): Install it.
10264
bb903df0
PL
102652015-09-21 Pierre Langlois <pierre.langlois@arm.com>
10266
10267 * Makefile.in (linux-aarch64-ipa.o, aarch64-ipa.o): New rules.
10268 * configure.srv (aarch64*-*-linux*): Add linux-aarch64-ipa.o and
10269 aarch64-ipa.o.
10270 * linux-aarch64-ipa.c: New file.
10271 * linux-aarch64-low.c: Include arch/aarch64-insn.h, inttypes.h
10272 and endian.h.
10273 (aarch64_get_thread_area): New target method.
10274 (extract_signed_bitfield): New helper function.
10275 (aarch64_decode_ldr_literal): New function.
10276 (enum aarch64_opcodes): New enum.
10277 (struct aarch64_register): New struct.
10278 (struct aarch64_operand): New struct.
10279 (x0): New static global.
10280 (x1): Likewise.
10281 (x2): Likewise.
10282 (x3): Likewise.
10283 (x4): Likewise.
10284 (w2): Likewise.
10285 (ip0): Likewise.
10286 (sp): Likewise.
10287 (xzr): Likewise.
10288 (aarch64_register): New helper function.
10289 (register_operand): Likewise.
10290 (immediate_operand): Likewise.
10291 (struct aarch64_memory_operand): New struct.
10292 (offset_memory_operand): New helper function.
10293 (preindex_memory_operand): Likewise.
10294 (enum aarch64_system_control_registers): New enum.
10295 (ENCODE): New macro.
10296 (emit_insn): New helper function.
10297 (emit_b): New function.
10298 (emit_bcond): Likewise.
10299 (emit_cb): Likewise.
10300 (emit_tb): Likewise.
10301 (emit_blr): Likewise.
10302 (emit_stp): Likewise.
10303 (emit_ldp_q_offset): Likewise.
10304 (emit_stp_q_offset): Likewise.
10305 (emit_load_store): Likewise.
10306 (emit_ldr): Likewise.
10307 (emit_ldrsw): Likewise.
10308 (emit_str): Likewise.
10309 (emit_ldaxr): Likewise.
10310 (emit_stxr): Likewise.
10311 (emit_stlr): Likewise.
10312 (emit_data_processing_reg): Likewise.
10313 (emit_data_processing): Likewise.
10314 (emit_add): Likewise.
10315 (emit_sub): Likewise.
10316 (emit_mov): Likewise.
10317 (emit_movk): Likewise.
10318 (emit_mov_addr): Likewise.
10319 (emit_mrs): Likewise.
10320 (emit_msr): Likewise.
10321 (emit_sevl): Likewise.
10322 (emit_wfe): Likewise.
10323 (append_insns): Likewise.
10324 (can_encode_int32_in): New helper function.
10325 (aarch64_relocate_instruction): New function.
10326 (aarch64_install_fast_tracepoint_jump_pad): Likewise.
10327 (aarch64_get_min_fast_tracepoint_insn_len): Likewise.
10328 (struct linux_target_ops): Install aarch64_get_thread_area,
10329 aarch64_install_fast_tracepoint_jump_pad and
10330 aarch64_get_min_fast_tracepoint_insn_len.
10331
787749ea
PL
103322015-09-21 Pierre Langlois <pierre.langlois@arm.com>
10333
10334 * Makefile.in (aarch64-insn.o): New rule.
10335 * configure.srv (aarch64*-*-linux*): Add aarch64-insn.o.
10336
9812b2e6
YQ
103372015-09-21 Yao Qi <yao.qi@linaro.org>
10338
10339 * ax.c [!IN_PROCESS_AGENT] (gdb_agent_op_sizes): Define it.
10340
18fe412b
YQ
103412015-09-21 Yao Qi <yao.qi@linaro.org>
10342
10343 * tracepoint.c (max_jump_pad_size): Remove.
10344
a0cc84cd
YQ
103452015-09-18 Yao Qi <yao.qi@linaro.org>
10346
10347 * linux-aarch64-low.c: Don't include sys/uio.h.
10348 (ps_get_thread_area): Call aarch64_ps_get_thread_area.
10349
d78908cf
WW
103502015-09-16 Wei-cheng Wang <cole945@gmail.com>
10351
10352 * tracepoint.c (eval_result_type): Change prototype.
10353 (condition_true_at_tracepoint): Fix argument to compiled_cond.
10354
d57e0d50
PA
103552015-09-15 Pedro Alves <palves@redhat.com>
10356
10357 * remote-utils.c (prepare_resume_reply) <TARGET_WAITKIND_EXECD>:
10358 Check whether to report exec events instead of checking whether
10359 multiprocess is enabled.
10360
5a676acc
PA
103612015-09-15 Pedro Alves <palves@redhat.com>
10362
10363 PR remote/18965
10364 * remote-utils.c (prepare_resume_reply): Merge
10365 TARGET_WAITKIND_VFORK_DONE switch case with the
10366 TARGET_WAITKIND_FORKED case.
10367
7c5d0fad
YQ
103682015-09-15 Yao Qi <yao.qi@linaro.org>
10369
10370 * server.c (handle_query): Check string comparison using
10371 "else if" instead of "if".
10372
750ce8d1
YQ
103732015-09-15 Yao Qi <yao.qi@linaro.org>
10374
10375 * server.c (vCont_supported): New global variable.
10376 (handle_query): Set vCont_supported to 1 if "vContSupported+"
10377 matches. Append ";vContSupported+" to own_buf.
10378 (handle_v_requests): Append ";s;S" to own_buf if target supports
10379 hardware single step or vCont_supported is false.
10380 (capture_main): Set vCont_supported to zero.
10381
70b90b91
YQ
103822015-09-15 Yao Qi <yao.qi@linaro.org>
10383
10384 * linux-low.c (linux_supports_conditional_breakpoints): Rename
10385 it to ...
10386 (linux_supports_hardware_single_step): ... New function.
10387 (linux_target_ops): Update.
10388 * lynx-low.c (lynx_target_ops): Set field
10389 supports_hardware_single_step to target_can_do_hardware_single_step.
10390 * nto-low.c (nto_target_ops): Likewise.
10391 * spu-low.c (spu_target_ops): Likewise.
10392 * win32-low.c (win32_target_ops): Likewise.
10393 * target.c (target_can_do_hardware_single_step): New function.
10394 * target.h (struct target_ops) <supports_conditional_breakpoints>:
10395 Remove. <supports_hardware_single_step>: New field.
10396 (target_supports_conditional_breakpoints): Remove.
10397 (target_supports_hardware_single_step): New macro.
10398 (target_can_do_hardware_single_step): Declare.
10399 * server.c (handle_query): Use target_supports_hardware_single_step
10400 instead of target_supports_conditional_breakpoints.
10401
ade90bde
YQ
104022015-09-15 Yao Qi <yao.qi@linaro.org>
10403
10404 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): New
10405 function.
10406 (struct linux_target_ops the_low_target): Install
10407 aarch64_linux_siginfo_fixup.
10408
94585166
DB
104092015-09-11 Don Breazeal <donb@codesourcery.com>
10410 Luis Machado <lgustavo@codesourcery.com>
10411
10412 * linux-low.c (linux_mourn): Static declaration.
10413 (linux_arch_setup): Move in front of
10414 handle_extended_wait.
10415 (linux_arch_setup_thread): New function.
10416 (handle_extended_wait): Handle exec events. Call
10417 linux_arch_setup_thread. Make event_lwp argument a
10418 pointer-to-a-pointer.
10419 (check_zombie_leaders): Do not check stopped threads.
10420 (linux_low_ptrace_options): Add PTRACE_O_TRACEEXEC.
10421 (linux_low_filter_event): Add lwp and thread for exec'ing
10422 non-leader thread if leader thread has been deleted.
10423 Refactor code into linux_arch_setup_thread and call it.
10424 Pass child lwp pointer by reference to handle_extended_wait.
10425 (linux_wait_for_event_filtered): Update comment.
10426 (linux_wait_1): Prevent clobbering exec event status.
10427 (linux_supports_exec_events): New function.
10428 (linux_target_ops) <supports_exec_events>: Initialize new member.
10429 * lynx-low.c (lynx_target_ops) <supports_exec_events>: Initialize
10430 new member.
10431 * remote-utils.c (prepare_resume_reply): New stop reason 'exec'.
10432 * server.c (report_exec_events): New global variable.
10433 (handle_query): Handle qSupported query for exec-events feature.
10434 (captured_main): Initialize report_exec_events.
10435 * server.h (report_exec_events): Declare new global variable.
10436 * target.h (struct target_ops) <supports_exec_events>: New
10437 member.
10438 (target_supports_exec_events): New macro.
10439 * win32-low.c (win32_target_ops) <supports_exec_events>:
10440 Initialize new member.
10441
0568462b
MM
104422015-09-09 Markus Metzger <markus.t.metzger@intel.com>
10443
10444 * linux-low.c (linux_low_enable_btrace): Remove.
10445 (linux_target_ops): Replace linux_low_enable_btrace with
10446 linux_enable_btrace.
10447
39edd165
YQ
104482015-09-03 Yao Qi <yao.qi@linaro.org>
10449
10450 * linux-aarch64-low.c (aarch64_insert_point): Call
10451 aarch64_handle_watchpoint if aarch64_linux_region_ok_for_watchpoint
10452 returns true.
10453
1db33b5a
UW
104542015-08-27 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
10455
10456 * linux-low.c (check_stopped_by_breakpoint): Use
10457 GDB_ARCH_IS_TRAP_BRKPT instead of GDB_ARCH_TRAP_BRKPT.
10458
ab290430
PA
104592015-08-27 Pedro Alves <palves@redhat.com>
10460
10461 * proc-service.c (ps_pdwrite): Return PS_ERR/PS_OK explicily.
10462
8d749320
SM
104632015-08-26 Simon Marchi <simon.marchi@ericsson.com>
10464
6711b7f8
SM
10465 * ax.c (gdb_parse_agent_expr): Replace xmalloc-family function with
10466 the XNEW-family equivalent.
8d749320
SM
10467 (compile_bytecodes): Likewise.
10468 * dll.c (loaded_dll): Likewise.
10469 * event-loop.c (append_callback_event): Likewise.
10470 (create_file_handler): Likewise.
10471 (create_file_event): Likewise.
10472 * hostio.c (handle_open): Likewise.
10473 * inferiors.c (add_thread): Likewise.
10474 (add_process): Likewise.
10475 * linux-aarch64-low.c (aarch64_linux_new_process): Likewise.
10476 * linux-arm-low.c (arm_new_process): Likewise.
10477 (arm_new_thread): Likewise.
10478 * linux-low.c (add_to_pid_list): Likewise.
10479 (linux_add_process): Likewise.
10480 (handle_extended_wait): Likewise.
10481 (add_lwp): Likewise.
10482 (enqueue_one_deferred_signal): Likewise.
10483 (enqueue_pending_signal): Likewise.
10484 (linux_resume_one_lwp_throw): Likewise.
10485 (linux_resume_one_thread): Likewise.
10486 (linux_read_memory): Likewise.
10487 (linux_write_memory): Likewise.
10488 * linux-mips-low.c (mips_linux_new_process): Likewise.
10489 (mips_linux_new_thread): Likewise.
10490 (mips_add_watchpoint): Likewise.
10491 * linux-x86-low.c (initialize_low_arch): Likewise.
10492 * lynx-low.c (lynx_add_process): Likewise.
10493 * mem-break.c (set_raw_breakpoint_at): Likewise.
10494 (set_breakpoint): Likewise.
10495 (add_condition_to_breakpoint): Likewise.
10496 (add_commands_to_breakpoint): Likewise.
10497 (clone_agent_expr): Likewise.
10498 (clone_one_breakpoint): Likewise.
10499 * regcache.c (new_register_cache): Likewise.
10500 * remote-utils.c (look_up_one_symbol): Likewise.
10501 * server.c (queue_stop_reply): Likewise.
10502 (start_inferior): Likewise.
10503 (queue_stop_reply_callback): Likewise.
10504 (handle_target_event): Likewise.
10505 * spu-low.c (fetch_ppc_memory): Likewise.
10506 (store_ppc_memory): Likewise.
10507 * target.c (set_target_ops): Likewise.
10508 * thread-db.c (thread_db_load_search): Likewise.
10509 (try_thread_db_load_1): Likewise.
10510 * tracepoint.c (add_tracepoint): Likewise.
10511 (add_tracepoint_action): Likewise.
10512 (create_trace_state_variable): Likewise.
10513 (cmd_qtdpsrc): Likewise.
10514 (cmd_qtro): Likewise.
10515 (add_while_stepping_state): Likewise.
10516 * win32-low.c (child_add_thread): Likewise.
10517 (get_image_name): Likewise.
10518
ed8b7b42
YQ
105192015-08-25 Yao Qi <yao.qi@linaro.org>
10520
10521 * linux-aarch64-low.c (aarch64_linux_new_thread): Remove.
10522
db3cb7cb
YQ
105232015-08-25 Yao Qi <yao.qi@linaro.org>
10524
10525 * Makefile.in (aarch64-linux.o): New rule.
10526 * configure.srv (aarch64*-*-linux*): Append aarch64-linux.o to
10527 srv_tgtobj.
10528 * linux-aarch64-low.c: Include nat/aarch64-linux.h.
10529 (aarch64_init_debug_reg_state): Make it extern.
10530 (aarch64_linux_prepare_to_resume): Remove.
10531
f6011a1c
YQ
105322015-08-25 Yao Qi <yao.qi@linaro.org>
10533
10534 * linux-aarch64-low.c (aarch64_linux_prepare_to_resume): Use
10535 lwp_arch_private_info and ptid_of_lwp.
10536
88e2cf7e
YQ
105372015-08-25 Yao Qi <yao.qi@linaro.org>
10538
10539 * linux-aarch64-low.c (aarch64_get_debug_reg_state): Add argument pid.
10540 Find proc_info by find_process_pid. All callers updated.
10541
5e35436e
YQ
105422015-08-25 Yao Qi <yao.qi@linaro.org>
10543
10544 * linux-aarch64-low.c (struct arch64_dr_update_callback_param):
10545 Remove.
10546 (debug_reg_change_callback): Remove.
10547 (aarch64_notify_debug_reg_change): Remove.
10548
4a8a7965
YQ
105492015-08-25 Yao Qi <yao.qi@linaro.org>
10550
10551 * linux-aarch64-low.c (aarch64_notify_debug_reg_change):
10552 Call current_lwp_ptid.
10553
32a271ee
YQ
105542015-08-25 Yao Qi <yao.qi@linaro.org>
10555
10556 * linux-aarch64-low.c (debug_reg_change_callback): Use
10557 debug_printf.
10558
0d51c8d7
YQ
105592015-08-25 Yao Qi <yao.qi@linaro.org>
10560
10561 * linux-aarch64-low.c (debug_reg_change_callback): Use phex.
10562
31a43dd5
YQ
105632015-08-25 Yao Qi <yao.qi@linaro.org>
10564
10565 * linux-aarch64-low.c (debug_reg_change_callback): Remove comments.
10566
8ee52567
YQ
105672015-08-25 Yao Qi <yao.qi@linaro.org>
10568
10569 * linux-aarch64-low.c (debug_reg_change_callback): Re-indent
10570 the code.
10571
ff3f0f45
YQ
105722015-08-25 Yao Qi <yao.qi@linaro.org>
10573
10574 * linux-aarch64-low.c (aarch64_dr_update_callback_param) <pid>:
10575 Remove.
10576 (debug_reg_change_callback): Remove argument entry and add argument
10577 lwp. Remove local variable thread. Don't print thread id in the
10578 debugging output. Don't check whether pid of thread equals to pid.
10579 (aarch64_notify_debug_reg_change): Don't set param.pid. Call
10580 iterate_over_lwps instead find_inferior.
10581
3d40fbb5
PA
105822015-08-24 Pedro Alves <palves@redhat.com>
10583
10584 * inferiors.c (get_first_process): New function.
10585 * inferiors.h (get_first_process): New declaration.
10586 * remote-utils.c (read_ptid): Default to the first process in the
10587 list, instead of to the current thread's process.
10588
438e1e42
PA
105892015-08-24 Pedro Alves <palves@redhat.com>
10590
10591 * debug.c: Include gdb_sys_time.h instead of sys/time.h.
10592 * event-loop.c: Likewise.
10593 * remote-utils.c: Likewise.
10594 * tracepoint.c: Likewise.
10595
a8c6d4fc
PA
105962015-08-24 Pedro Alves <palves@redhat.com>
10597
10598 * spu-low.c (spu_request_interrupt): Use lwpid_of instead of
10599 ptid_get_lwp.
10600
99b0bb12
PA
106012015-08-21 Pedro Alves <palves@redhat.com>
10602
10603 * ax.c (gdb_eval_agent_expr): Return expr_eval_unhandled_opcode
10604 instead of literal 1.
10605
f8904751
PA
106062015-08-21 Pedro Alves <palves@redhat.com>
10607
10608 * tdesc.c (default_description): Explicitly zero-initialize.
10609
465a859e
PA
106102015-08-21 Pedro Alves <palves@redhat.com>
10611
10612 PR gdb/18749
10613 * inferiors.c (remove_thread): Discard any pending stop reply for
10614 this thread.
10615 * server.c (remove_all_on_match_pid): Rename to ...
10616 (remove_all_on_match_ptid): ... this. Work with a filter ptid
10617 instead of a pid.
10618 (discard_queued_stop_replies): Change parameter to a ptid. Now
10619 extern.
10620 (handle_v_kill, kill_inferior_callback, captured_main)
10621 (process_serial_event): Adjust.
10622 * server.h (discard_queued_stop_replies): Declare.
10623
f0db101d
PA
106242015-08-21 Pedro Alves <palves@redhat.com>
10625
10626 * linux-low.c (wait_for_sigstop): Always switch to no thread
10627 selected if the previously current thread dies.
10628 * lynx-low.c (lynx_request_interrupt): Use the first thread's
10629 process instead of the current thread's.
10630 * remote-utils.c (input_interrupt): Don't check if there's no
10631 current thread.
10632 * server.c (gdb_read_memory, gdb_write_memory): If setting the
10633 current thread to the general thread fails, error out.
10634 (handle_qxfer_auxv, handle_qxfer_libraries)
10635 (handle_qxfer_libraries_svr4, handle_qxfer_siginfo)
10636 (handle_qxfer_spu, handle_qxfer_statictrace, handle_qxfer_fdpic)
10637 (handle_query): Check if there's a thread selected instead of
10638 checking whether there's any thread in the thread list.
10639 (handle_qxfer_threads, handle_qxfer_btrace)
10640 (handle_qxfer_btrace_conf): Don't error out early if there's no
10641 thread in the thread list.
10642 (handle_v_cont, myresume): Don't set the current thread to the
10643 continue thread.
10644 (process_serial_event) <Hg handling>: Also set thread_id if the
10645 previous general thread is still alive.
10646 (process_serial_event) <g/G handling>: If setting the current
10647 thread to the general thread fails, error out.
10648 * spu-low.c (spu_resume, spu_request_interrupt): Use the first
10649 thread's lwp instead of the current thread's.
10650 * target.c (set_desired_thread): If the desired thread was not
10651 found, leave the current thread pointing to NULL. Return an int
10652 (boolean) indicating success.
10653 * target.h (set_desired_thread): Change return type to int.
10654
40045d91
MF
106552015-08-20 Max Filippov <jcmvbkbc@gmail.com>
10656
10657 * configure.srv (xtensa*-*-linux*): Add srv_linux_thread_db=yes.
10658 * linux-xtensa-low.c (arch/xtensa.h gdb_proc_service.h): New
10659 #includes.
10660 (ps_get_thread_area): New function.
10661
45face3b
GB
106622015-08-19 Gary Benson <gbenson@redhat.com>
10663
10664 * hostio.c (handle_pread): Do not attempt to read more data
10665 than hostio_reply_with_data can fit in a packet.
10666
16d5f642
JB
106672015-08-18 Joel Brobecker <brobecker@adacore.com>
10668
10669 * linux-aarch32-low.c (NT_ARM_VFP): Define if not already defined.
10670
a738da3a
MF
106712015-08-14 Matthew Fortune <matthew.fortune@imgtec.com>
10672
10673 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP_REL.
10674
33ebda9d
PA
106752015-08-06 Pedro Alves <palves@redhat.com>
10676
10677 * tracepoint.c (expr_eval_result): Now an int.
10678
a44892be
PA
106792015-08-06 Pedro Alves <palves@redhat.com>
10680
10681 * gdbthread.h (struct regcache): Forward declare.
10682 (struct thread_info) <regcache_data>: Now a struct regcache
10683 pointer.
10684 * inferiors.c (inferior_regcache_data)
10685 (set_inferior_regcache_data): Now work with struct regcache
10686 pointers.
10687 * inferiors.h (struct regcache): Forward declare.
10688 (inferior_regcache_data, set_inferior_regcache_data): Now work
10689 with struct regcache pointers.
10690 * regcache.c (get_thread_regcache, regcache_invalidate_thread)
10691 (free_register_cache_thread): Remove struct regcache pointer
10692 casts.
10693
608a1e46
PA
106942015-08-06 Pedro Alves <palves@redhat.com>
10695
10696 * server.c (captured_main): On error, print the exception message
10697 to stderr, and if run_once is set, throw a quit.
10698
f0ce0d3a
PA
106992015-08-06 Pedro Alves <palves@redhat.com>
10700
10701 * linux-low.c (move_out_of_jump_pad_callback): Temporarily switch
10702 the current thread.
10703
bf47e248
PA
107042015-08-06 Pedro Alves <palves@redhat.com>
10705
10706 * linux-low.c (linux_write_memory): Rewrite debug output to avoid
10707 reading beyond the passed in buffer length.
10708
b6b9ffcc
PL
107092015-08-06 Pierre Langlois <pierre.langlois@arm.com>
10710
10711 * tracepoint.c (symbol_list) <required>: Remove.
10712
863d01bd
PA
107132015-08-06 Pedro Alves <palves@redhat.com>
10714
10715 * linux-low.c (handle_extended_wait): Set the fork child's suspend
10716 count if stopping and suspending threads.
10717 (check_stopped_by_breakpoint): If stopped by trace, set the LWP's
10718 stop reason to TARGET_STOPPED_BY_SINGLE_STEP.
10719 (linux_detach): Complete an ongoing step-over.
10720 (lwp_suspended_inc, lwp_suspended_decr): New functions. Use
10721 throughout.
10722 (resume_stopped_resumed_lwps): Don't resume a suspended thread.
10723 (linux_wait_1): If passing a signal to the inferior after
10724 finishing a step-over, unsuspend and re-resume all lwps. If we
10725 see a single-step event but the thread should be continuing, don't
10726 pass the trap to gdb.
10727 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback): Use
10728 internal_error instead of gdb_assert.
10729 (enqueue_pending_signal): New function.
10730 (check_ptrace_stopped_lwp_gone): Add debug output.
10731 (start_step_over): Use internal_error instead of gdb_assert.
10732 (complete_ongoing_step_over): New function.
10733 (linux_resume_one_thread): Don't resume a suspended thread.
10734 (proceed_one_lwp): If the LWP is stepping over a breakpoint, reset
10735 it stepping.
10736
00db26fa
PA
107372015-08-06 Pedro Alves <palves@redhat.com>
10738
10739 * linux-low.c (add_lwp): Set waitstatus to TARGET_WAITKIND_IGNORE.
10740 (linux_thread_alive): Use lwp_is_marked_dead.
10741 (extended_event_reported): Delete.
10742 (linux_wait_1): Check if waitstatus is TARGET_WAITKIND_IGNORE
10743 instead of extended_event_reported.
10744 (mark_lwp_dead): Don't set the 'dead' flag. Store the waitstatus
10745 as well.
10746 (lwp_is_marked_dead): New function.
10747 (lwp_running): Use lwp_is_marked_dead.
10748 * linux-low.h: Delete 'dead' field, and update 'waitstatus's
10749 comment.
10750
ad071a30
PA
107512015-08-06 Pedro Alves <palves@redhat.com>
10752
10753 * linux-low.c (linux_wait_1): Move fork event output out of the
10754 !report_to_gdb check. Pass event_child->waitstatus to
10755 target_waitstatus_to_string instead of ourstatus.
10756
524b57e6
YQ
107572015-08-04 Yao Qi <yao.qi@linaro.org>
10758
10759 * linux-aarch64-low.c (aarch64_supports_tracepoints): Return 0
10760 if current_thread is 32 bit.
10761
6085d6f6
YQ
107622015-08-04 Yao Qi <yao.qi@linaro.org>
10763
10764 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
10765 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
10766 * server.c (extended_protocol): Remove "static".
10767 * server.h (extended_protocol): Declare it.
10768
8a7e4587
YQ
107692015-08-04 Yao Qi <yao.qi@linaro.org>
10770
10771 * linux-aarch64-low.c (aarch64_get_pc): Get PC register on
10772 both aarch64 and aarch32.
10773 (aarch64_set_pc): Likewise.
10774
3b53ae99
YQ
107752015-08-04 Yao Qi <yao.qi@linaro.org>
10776
10777 * configure.srv (case aarch64*-*-linux*): Append arm-with-neon.o
10778 to srv_regobj and append arm-core.xml arm-vfpv3.xml and
10779 arm-with-neon.xml to srv_xmlfiles.
10780 * linux-aarch64-low.c: Include linux-aarch32-low.h.
10781 (is_64bit_tdesc): New function.
10782 (aarch64_linux_read_description): New function.
10783 (aarch64_arch_setup): Call aarch64_linux_read_description.
10784 (regs_info): Rename to regs_info_aarch64.
10785 (aarch64_regs_info): Return right regs_info.
10786 (initialize_low_arch): Call initialize_low_arch_aarch32.
10787
bd9e6534
YQ
107882015-08-04 Yao Qi <yao.qi@linaro.org>
10789
10790 * configure.srv (srv_tgtobj): Add linux-aarch32-low.o.
10791 * linux-aarch32-low.c: New file.
10792 * linux-aarch32-low.h: New file.
10793 * linux-arm-low.c (arm_fill_gregset): Move it to
10794 linux-aarch32-low.c.
10795 (arm_store_gregset): Likewise.
10796 (arm_fill_vfpregset): Call arm_fill_vfpregset_num
10797 (arm_store_vfpregset): Call arm_store_vfpregset_num.
10798 (arm_arch_setup): Check if PTRACE_GETREGSET works.
10799 (regs_info): Rename to regs_info_arm.
10800 (arm_regs_info): Return regs_info_aarch32 if
10801 have_ptrace_getregset is 1 and target description is
10802 arm_with_neon or arm_with_vfpv3.
10803 (initialize_low_arch): Don't call init_registers_arm_with_neon.
10804 Call initialize_low_arch_aarch32 instead.
10805
ded48a5e
YQ
108062015-08-04 Yao Qi <yao.qi@linaro.org>
10807
10808 * linux-x86-low.c (have_ptrace_getregset): Move it to ...
10809 * linux-low.c: ... here.
10810 * linux-low.h (have_ptrace_getregset): Declare it.
10811
96e9210f
PA
108122015-08-04 Pedro Alves <palves@redhat.com>
10813
10814 * thread-db.c (struct thread_db): Use new typedefs.
10815 (try_thread_db_load_1): Define local TDB_DLSYM macro and use it in
10816 CHK calls.
10817 (disable_thread_event_reporting): Cast result of dlsym to
10818 destination function pointer type.
10819 (thread_db_mourn): Use td_ta_delete_ftype.
10820
af60a1ef
SL
108212015-08-03 Sandra Loosemore <sandra@codesourcery.com>
10822
10823 * linux-nios2-low.c (NIOS2_BREAKPOINT): Conditionalize for
10824 arch variant.
10825 (CDX_BREAKPOINT): Define for R2.
10826 (nios2_breakpoint_at): Check for CDX_BREAKPOINT when R2.
10827 (the_low_target): Add comments.
10828
e8b41681
YQ
108292015-07-30 Yao Qi <yao.qi@linaro.org>
10830
10831 * linux-arm-low.c (arm_hwcap): Remove it.
10832 (arm_read_description): New local variable arm_hwcap. Don't
10833 set arm_hwcap to zero.
10834
89abb039
YQ
108352015-07-30 Yao Qi <yao.qi@linaro.org>
10836
10837 * linux-arm-low.c (arm_fill_wmmxregset): Don't use arm_hwcap.
10838 Use regcache->tdesc instead.
10839 (arm_store_wmmxregset): Likewise.
10840 (arm_fill_vfpregset): Likewise.
10841 (arm_store_vfpregset): Likewise.
10842
deca266c
YQ
108432015-07-30 Yao Qi <yao.qi@linaro.org>
10844
10845 * linux-arm-low.c: Include arch/arm.h.
10846 (arm_fill_gregset): Don't use arm_num_regs and arm_regmap.
10847 (arm_store_gregset): Likewise.
10848
aa58a496
SM
108492015-07-29 Simon Marchi <simon.marchi@ericsson.com>
10850
10851 * linux-mips-low.c (mips_linux_prepare_to_resume): Add NULL as
10852 ptrace's 4th parameter.
10853
50904b25
YQ
108542015-07-27 Yao Qi <yao.qi@linaro.org>
10855
10856 * configure.srv (case aarch64*-*-linux*): Don't set
10857 srv_linux_usrregs.
10858
5826e159
PA
108592015-07-24 Pedro Alves <palves@redhat.c: Likewise.om>
10860
10861 * linux-aarch64-low.c: Include nat/gdb_ptrace.h instead of
10862 sys/ptrace.h.
10863 * linux-arm-low.c: Likewise.
10864 * linux-cris-low.c: Likewise.
10865 * linux-crisv32-low.c: Likewise.
10866 * linux-low.c: Likewise.
10867 * linux-m68k-low.c: Likewise.
10868 * linux-mips-low.c: Likewise.
10869 * linux-nios2-low.c: Likewise.
10870 * linux-s390-low.c: Likewise.
10871 * linux-sparc-low.c: Likewise.
10872 * linux-tic6x-low.c: Likewise.
10873 * linux-tile-low.c: Likewise.
10874 * linux-x86-low.c: Likewise.
10875
54019719
PA
108762015-07-24 Pedro Alves <palves@redhat.com>
10877
10878 * config.in: Regenerate.
10879 * configure: Regenerate.
10880
eb7aa561
PA
108812015-07-24 Pedro Alves <palves@redhat.com>
10882
10883 * acinclude.m4: Include ../ptrace.m4.
10884 * configure.ac: Call GDB_AC_PTRACE.
10885 * config.in, configure: Regenerate.
10886
55d7b841
YQ
108872015-07-24 Yao Qi <yao.qi@linaro.org>
10888
10889 * linux-low.c (linux_create_inferior): Remove setting to
10890 proc->priv->new_inferior.
10891 (linux_attach): Likewise.
10892 (linux_low_filter_event): Likewise.
10893 * linux-low.h (struct process_info_private) <new_inferior>: Remove.
10894
c06cbd92
YQ
108952015-07-24 Yao Qi <yao.qi@linaro.org>
10896
10897 * linux-low.c (linux_arch_setup): New function.
10898 (linux_low_filter_event): If proc->tdesc is NULL and
10899 proc->attached is true, call the_low_target.arch_setup.
10900 Otherwise, keep status pending, and return.
10901 (linux_resume_one_lwp_throw): Don't call get_pc if
10902 thread->while_stepping isn't NULL. Don't call
10903 get_thread_regcache if proc->tdesc is NULL.
10904 (need_step_over_p): Return 0 if proc->tdesc is NULL.
10905 (linux_target_ops): Install arch_setup.
10906 * server.c (start_inferior): Call the_target->arch_setup.
10907 * target.h (struct target_ops) <arch_setup>: New field.
10908 (target_arch_setup): New marco.
10909 * lynx-low.c (lynx_target_ops): Update.
10910 * nto-low.c (nto_target_ops): Update.
10911 * spu-low.c (spu_target_ops): Update.
10912 * win32-low.c (win32_target_ops): Update.
10913
5ae3ebba
YQ
109142015-07-24 Yao Qi <yao.qi@linaro.org>
10915
10916 * linux-low.c (linux_add_process): Don't set
10917 proc->priv->new_inferior.
10918 (linux_create_inferior): Set proc->priv->new_inferior to 1.
10919 (linux_attach): Likewise.
10920
eb97750b
YQ
109212015-07-24 Yao Qi <yao.qi@linaro.org>
10922
10923 * server.c (start_inferior): Code refactor.
10924
51aee833
YQ
109252015-07-24 Yao Qi <yao.qi@linaro.org>
10926
10927 * server.c (process_serial_event): Set general_thread.
10928
af1b22f3
YQ
109292015-07-21 Yao Qi <yao.qi@linaro.org>
10930
10931 * linux-aarch64-low.c (aarch64_arch_setup): Remove code and call
10932 aarch64_linux_get_debug_reg_capacity.
10933
554717a3
YQ
109342015-07-17 Yao Qi <yao.qi@linaro.org>
10935
10936 * Makefile.in (aarch64-linux-hw-point.o): New rule.
10937 * configure.srv (srv_tgtobj): Append aarch64-linux-hw-point.o.
10938 * linux-aarch64-low.c: Include nat/aarch64-linux-hw-point.h.
10939 (AARCH64_HBP_MAX_NUM): Move to nat/aarch64-linux-hw-point.h.
10940 (AARCH64_HWP_MAX_NUM, AARCH64_HBP_ALIGNMENT): Likewise.
10941 (AARCH64_HWP_ALIGNMENT): Likewise.
10942 (AARCH64_HWP_MAX_LEN_PER_REG): Likewise.
10943 (AARCH64_DEBUG_NUM_SLOTS, AARCH64_DEBUG_ARCH): Likewise.
10944 (aarch64_num_bp_regs, aarch64_num_wp_regs): Likewise.
10945 (AARCH64_DEBUG_ARCH_V8, DR_MARK_ALL_CHANGED): Likewise.
10946 (DR_MARK_N_CHANGED, DR_CLEAR_CHANGED): Likewise.
10947 (DR_HAS_CHANGED, DR_N_HAS_CHANGE): Likewise.
10948 (struct aarch64_debug_reg_state): Likewise.
10949 (struct arch_lwp_info): Likewise.
10950 (aarch64_align_watchpoint): Likewise.
10951 (DR_CONTROL_ENABLED, DR_CONTROL_LENGTH): Likewise.
10952 (aarch64_watchpoint_length): Likewise.
10953 (aarch64_point_encode_ctrl_reg): Likewise
10954 (aarch64_point_is_aligned): Likewise.
10955 (aarch64_align_watchpoint): Likewise.
10956 (aarch64_linux_set_debug_regs):
10957 (aarch64_dr_state_insert_one_point): Likewise.
10958 (aarch64_dr_state_remove_one_point): Likewise.
10959 (aarch64_handle_breakpoint): Likewise.
10960 (aarch64_handle_aligned_watchpoint): Likewise.
10961 (aarch64_handle_unaligned_watchpoint): Likewise.
10962 (aarch64_handle_watchpoint): Likewise.
10963
c67ca4de
YQ
109642015-07-17 Yao Qi <yao.qi@linaro.org>
10965
10966 * linux-aarch64-low.c (aarch64_handle_breakpoint): Add argument state
10967 and don't aarch64_get_debug_reg_state. All callers update.
10968 (aarch64_handle_aligned_watchpoint): Likewise.
10969 (aarch64_handle_unaligned_watchpoint): Likewise.
10970 (aarch64_handle_watchpoint): Likewise.
10971 (aarch64_insert_point): Call aarch64_get_debug_reg_state earlier.
10972 (aarch64_remove_point): Likewise.
10973
25abf979
YQ
109742015-07-17 Yao Qi <yao.qi@linaro.org>
10975
10976 * linux-aarch64-low.c (aarch64_show_debug_reg_state): Use
10977 debug_printf.
10978 (aarch64_handle_unaligned_watchpoint): Likewise.
10979
db1ff28b
JK
109802015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
10981
10982 Revert the previous 3 commits:
10983 Move gdb_regex* to common/
10984 Move linux_find_memory_regions_full & co.
10985 gdbserver build-id attribute generator
10986
700ca40f
JK
109872015-07-15 Aleksandar Ristovski <aristovski@qnx.com
10988 Jan Kratochvil <jan.kratochvil@redhat.com>
10989
10990 gdbserver build-id attribute generator.
10991 * linux-low.c (nat/linux-maps.h, search.h, rsp-low.h): Include.
10992 (ElfXX_Ehdr, ElfXX_Phdr, ElfXX_Nhdr): New.
10993 (ELFXX_FLD, ELFXX_SIZEOF, ELFXX_ROUNDUP, BUILD_ID_INVALID): New.
10994 (find_phdr): New.
10995 (get_dynamic): Use find_pdhr to traverse program headers.
10996 (struct mapping_entry, mapping_entry_s, free_mapping_entry_vec)
10997 (compare_mapping_entry_range, struct find_memory_region_callback_data)
10998 (read_build_id, find_memory_region_callback, lrfind_mapping_entry)
10999 (get_hex_build_id): New.
11000 (linux_qxfer_libraries_svr4): Add optional build-id attribute
11001 to reply XML document.
11002
9904185c
JK
110032015-07-15 Aleksandar Ristovski <aristovski@qnx.com
11004 Jan Kratochvil <jan.kratochvil@redhat.com>
11005
11006 * target.c: Include target/target-utils.h and fcntl.h.
11007 (target_fileio_read_stralloc_1_pread, target_fileio_read_stralloc_1)
11008 (target_fileio_read_stralloc): New functions.
11009
6e5b4429
JK
110102015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
11011
11012 * Makefile.in (OBS): Add gdb_regex.o.
11013 (gdb_regex.o): New.
11014 * config.in: Rebuilt.
11015 * configure: Rebuilt.
11016
ddc98fbf
JK
110172015-07-15 Aleksandar Ristovski <aristovski@qnx.com
11018 Jan Kratochvil <jan.kratochvil@redhat.com>
11019
11020 Create empty nat/linux-maps.[ch] and common/target-utils.[ch].
11021 * Makefile.in (OBS): Add target-utils.o.
11022 (linux-maps.o, target-utils.o): New.
11023 * configure.srv (srv_linux_obj): Add linux-maps.o.
11024
e57bb7a0
PL
110252015-07-15 Pierre Langlois <pierre.langlois@arm.com>
11026
11027 * linux-aarch64-low.c (aarch64_supports_range_stepping): New
11028 function, return 1.
11029 (the_low_target): Install it.
11030
586b02a9
PA
110312015-07-14 Pedro Alves <palves@redhat.com>
11032
11033 * linux-low.c (kill_wait_lwp): Don't assert if waitpid fails.
11034 Instead, ignore ECHILD, and throw an error for other errnos.
11035
58c1b36c
PA
110362015-07-10 Pedro Alves <palves@redhat.com>
11037
11038 * event-loop.c (struct callback_event) <data>: Change type to
11039 gdb_client_data instance instead of gdb_client_data pointer.
11040 (append_callback_event): Adjust.
11041
421530db
PL
110422015-07-10 Pierre Langlois <pierre.langlois@arm.com>
11043
11044 * linux-aarch64-low.c: Add comments for each linux_target_ops
11045 method. Remove comments already covered in target_ops and
11046 linux_target_ops definitions.
11047 (the_low_target): Add comments for each unimplemented method.
11048
c2d65f38
YQ
110492015-07-09 Yao Qi <yao.qi@linaro.org>
11050
11051 * linux-aarch64-low.c (aarch64_regmap): Remove.
11052 (aarch64_usrregs_info): Remove.
11053 (regs_info): Set field usrregs to NULL.
11054
b20a6524
MM
110552015-07-02 Markus Metzger <markus.t.metzger@intel.com>
11056
11057 * linux-low.c: Include "rsp-low.h"
11058 (linux_low_encode_pt_config, linux_low_encode_raw): New.
11059 (linux_low_read_btrace): Support BTRACE_FORMAT_PT.
11060 (linux_low_btrace_conf): Support BTRACE_FORMAT_PT.
11061 (handle_btrace_enable_pt): New.
11062 (handle_btrace_general_set): Support "pt".
11063 (handle_btrace_conf_general_set): Support "pt:size".
11064
96c97461
PL
110652015-06-29 Pierre Langlois <pierre.langlois@arm.com>
11066
11067 * linux-aarch64-low.c (aarch64_supports_z_point_type): Enable for
11068 Z_PACKET_SW_BP.
11069
37d66942
PL
110702015-06-29 Pierre Langlois <pierre.langlois@arm.com>
11071
11072 * linux-aarch64-low.c: Remove comment about endianness.
11073 (aarch64_breakpoint): Change type to gdb_byte[]. Set to "brk #0".
11074 (aarch64_breakpoint_at): Change type of insn to gdb_byte[]. Use
11075 memcmp.
11076
dc06243f
GB
110772015-06-24 Gary Benson <gbenson@redhat.com>
11078
11079 * linux-i386-ipa.c (stdint.h): Do not include.
11080 * lynx-i386-low.c (stdint.h): Likewise.
11081 * lynx-ppc-low.c (stdint.h): Likewise.
11082 * mem-break.c (stdint.h): Likewise.
11083 * thread-db.c (stdint.h): Likewise.
11084 * tracepoint.c (stdint.h): Likewise.
11085 * win32-low.c (stdint.h): Likewise.
11086
124e13d9
SM
110872015-06-18 Simon Marchi <simon.marchi@ericsson.com>
11088
11089 * server.c (write_qxfer_response): Update call to
11090 remote_escape_output.
11091
909c2cda
JK
110922015-06-15 Aleksandar Ristovski <aristovski@qnx.com
11093 Jan Kratochvil <jan.kratochvil@redhat.com>
11094
11095 Merge multiple hex conversions.
11096 * gdbreplay.c (tohex): Rename to 'fromhex'.
11097 (logchar): Use fromhex.
11098
24c05f46
JK
110992015-06-10 Jan Kratochvil <jan.kratochvil@redhat.com>
11100
11101 * server.c (handle_qxfer_libraries): Set `version' attribute for
11102 <library-list>.
11103
14d2069a
GB
111042015-06-10 Gary Benson <gbenson@redhat.com>
11105
11106 * target.h (struct target_ops) <multifs_open>: New field.
11107 <multifs_unlink>: Likewise.
11108 <multifs_readlink>: Likewise.
11109 * linux-low.c (nat/linux-namespaces.h): New include.
11110 (linux_target_ops): Initialize the_target->multifs_open,
11111 the_target->multifs_unlink and the_target->multifs_readlink.
11112 * hostio.h (hostio_handle_new_gdb_connection): New declaration.
11113 * hostio.c (hostio_fs_pid): New static variable.
11114 (hostio_handle_new_gdb_connection): New function.
11115 (handle_setfs): Likewise.
11116 (handle_open): Use the_target->multifs_open as appropriate.
11117 (handle_unlink): Use the_target->multifs_unlink as appropriate.
11118 (handle_readlink): Use the_target->multifs_readlink as
11119 appropriate.
11120 (handle_vFile): Handle vFile:setfs packets.
11121 * server.c (handle_query): Call hostio_handle_new_gdb_connection
11122 after target_handle_new_gdb_connection.
11123
4b8b5e72
GB
111242015-06-10 Gary Benson <gbenson@redhat.com>
11125
11126 * configure.ac (AC_CHECK_FUNCS): Add setns.
11127 * config.in: Regenerate.
11128 * configure: Likewise.
11129 * Makefile.in (SFILES): Add nat/linux-namespaces.c.
11130 (linux-namespaces.o): New rule.
11131 * configure.srv (srv_linux_obj): Add linux-namespaces.o.
11132
3ac2e371
GB
111332015-06-09 Gary Benson <gbenson@redhat.com>
11134
11135 * hostio.c (handle_open): Process mode argument with
11136 fileio_to_host_mode.
11137
ca9b78ce
YQ
111382015-06-01 Yao Qi <yao.qi@linaro.org>
11139
11140 * linux-s390-low.c (PTRACE_GETREGSET, PTRACE_SETREGSET): Remove.
11141 * linux-x86-low.c: Likewise.
11142
bfacd19d
DB
111432015-05-28 Don Breazeal <donb@codesourcery.com>
11144
11145 * linux-low.c (handle_extended_wait): Initialize
11146 thread_info.last_resume_kind for new fork children.
11147
452003ef
PA
111482015-05-15 Pedro Alves <palves@redhat.com>
11149
11150 * target.h (target_handle_new_gdb_connection): Rewrite using if
11151 wrapped in do/while.
11152
1041a03c
JB
111532015-05-14 Joel Brobecker <brobecker@adacore.com>
11154
11155 * configure.ac: Add prfpregset_t BFD_HAVE_SYS_PROCFS_TYPE check.
11156 * configure, config.in: Regenerate.
11157 * gdb_proc_service.h [HAVE_PRFPREGSET_T] (prfpregset_t):
11158 Declare typedef.
11159
c269dbdb
DB
111602015-05-12 Don Breazeal <donb@codesourcery.com>
11161
11162 * linux-low.c (handle_extended_wait): Handle PTRACE_EVENT_FORK and
11163 PTRACE_EVENT_VFORK_DONE.
11164 (linux_low_ptrace_options, extended_event_reported): Add vfork
11165 events.
11166 * remote-utils.c (prepare_resume_reply): New stop reasons "vfork"
11167 and "vforkdone" for RSP 'T' Stop Reply Packet.
11168 * server.h (report_vfork_events): Declare
11169 global variable.
11170
3a8a0396
DB
111712015-05-12 Don Breazeal <donb@codesourcery.com>
11172
11173 * linux-aarch64-low.c (aarch64_linux_new_fork): New function.
11174 (the_low_target) <new_fork>: Initialize new member.
11175 * linux-arm-low.c (arm_new_fork): New function.
11176 (the_low_target) <new_fork>: Initialize new member.
11177 * linux-low.c (handle_extended_wait): Call new target function
11178 new_fork.
11179 * linux-low.h (struct linux_target_ops) <new_fork>: New member.
11180 * linux-mips-low.c (mips_add_watchpoint): New function
11181 extracted from mips_insert_point.
11182 (the_low_target) <new_fork>: Initialize new member.
11183 (mips_linux_new_fork): New function.
11184 (mips_insert_point): Call mips_add_watchpoint.
11185 * linux-x86-low.c (x86_linux_new_fork): New function.
11186 (the_low_target) <new_fork>: Initialize new member.
11187
de0d863e
DB
111882015-05-12 Don Breazeal <donb@codesourcery.com>
11189
11190 * linux-low.c (handle_extended_wait): Implement return value,
11191 rename argument 'event_child' to 'event_lwp', handle
11192 PTRACE_EVENT_FORK, call internal_error for unrecognized event.
11193 (linux_low_ptrace_options): New function.
11194 (linux_low_filter_event): Call linux_low_ptrace_options,
11195 use different argument fo linux_enable_event_reporting,
11196 use return value from handle_extended_wait.
11197 (extended_event_reported): New function.
11198 (linux_wait_1): Call extended_event_reported and set
11199 status to report fork events.
11200 (linux_write_memory): Add pid to debug message.
11201 (reset_lwp_ptrace_options_callback): New function.
11202 (linux_handle_new_gdb_connection): New function.
11203 (linux_target_ops): Initialize new structure member.
11204 * linux-low.h (struct lwp_info) <waitstatus>: New member.
11205 * lynx-low.c: Initialize new structure member.
11206 * remote-utils.c (prepare_resume_reply): Implement stop reason
11207 "fork" for "T" stop message.
11208 * server.c (handle_query): Call handle_new_gdb_connection.
11209 * server.h (report_fork_events): Declare global flag.
11210 * target.h (struct target_ops) <handle_new_gdb_connection>:
11211 New member.
11212 (target_handle_new_gdb_connection): New macro.
11213 * win32-low.c: Initialize new structure member.
11214
ddcbc397
DB
112152015-05-12 Don Breazeal <donb@codesourcery.com>
11216
11217 * mem-break.c (APPEND_TO_LIST): Define macro.
11218 (clone_agent_expr): New function.
11219 (clone_one_breakpoint): New function.
11220 (clone_all_breakpoints): New function.
11221 * mem-break.h: Declare new functions.
11222
89245bc0
DB
112232015-05-12 Don Breazeal <donb@codesourcery.com>
11224
11225 * linux-low.c (linux_supports_fork_events): New function.
11226 (linux_supports_vfork_events): New function.
11227 (linux_target_ops): Initialize new structure members.
11228 (initialize_low): Call linux_check_ptrace_features.
11229 * lynx-low.c (lynx_target_ops): Initialize new structure
11230 members.
11231 * server.c (report_fork_events, report_vfork_events):
11232 New global flags.
11233 (handle_query): Add new features to qSupported packet and
11234 response.
11235 (captured_main): Initialize new global variables.
11236 * target.h (struct target_ops) <supports_fork_events>:
11237 New member.
11238 <supports_vfork_events>: New member.
11239 (target_supports_fork_events): New macro.
11240 (target_supports_vfork_events): New macro.
11241 * win32-low.c (win32_target_ops): Initialize new structure
11242 members.
11243
835205d0
GB
112442015-05-12 Gary Benson <gbenson@redhat.com>
11245
11246 * server.c (handle_qxfer_exec_file): Use current process
11247 if annex is empty.
11248
21e94bd9
SL
112492015-05-08 Sandra Loosemore <sandra@codesourcery.com>
11250
11251 * linux-nios2-low.c: Include elf/common.h. Adjust comments.
11252 Remove HAVE_PTRACE_GETREGS conditionals.
11253 (nios2_regsets): Use PTRACE_GETREGSET and PTRACE_SETREGSET
11254 instead of PTRACE_GETREGS and PTRACE_SETREGS.
11255
45614f15
YQ
112562015-05-08 Yao Qi <yao.qi@linaro.org>
11257
11258 * linux-low.c (linux_supports_conditional_breakpoints): New
11259 function.
11260 (linux_target_ops): Install new target method.
11261 * lynx-low.c (lynx_target_ops): Install NULL hook for
11262 supports_conditional_breakpoints.
11263 * nto-low.c (nto_target_ops): Likewise.
11264 * spu-low.c (spu_target_ops): Likewise.
11265 * win32-low.c (win32_target_ops): Likewise.
11266 * server.c (handle_query): Check
11267 target_supports_conditional_breakpoints.
11268 * target.h (struct target_ops) <supports_conditional_breakpoints>:
11269 New field.
11270 (target_supports_conditional_breakpoints): New macro.
11271
80ad801e
PA
112722015-05-06 Pedro Alves <palves@redhat.com>
11273
11274 PR server/18081
11275 * server.c (start_inferior): If the process exits, mourn it.
11276
819843c7
GB
112772015-04-21 Gary Benson <gbenson@redhat.com>
11278
11279 * hostio.c (fileio_open_flags_to_host): Factored out to
11280 fileio_to_host_openflags in common/fileio.c. Single use
11281 updated.
11282
a2d5a9d7
MF
112832015-04-17 Max Filippov <jcmvbkbc@gmail.com>
11284
11285 * linux-xtensa-low.c (xtensa_fill_gregset)
11286 (xtensa_store_gregset): Check XCHAL_HAVE_LOOPS instead of
11287 XCHAL_HAVE_LOOP.
11288
deb44829
MF
112892015-04-17 Max Filippov <jcmvbkbc@gmail.com>
11290
11291 * linux-xtensa-low.c (xtensa_usrregs_info): Remove.
11292 (regs_info): Replace usrregs pointer with NULL.
11293
e57f1de3
GB
112942015-04-17 Gary Benson <gbenson@redhat.com>
11295
11296 * target.h (struct target_ops) <pid_to_exec_file>: New field.
11297 * linux-low.c (linux_target_ops): Initialize pid_to_exec_file.
11298 * server.c (handle_qxfer_exec_file): New function.
11299 (qxfer_packets): Add exec-file entry.
11300 (handle_query): Report qXfer:exec-file:read as supported packet.
11301
62828379
RN
113022015-04-14 Romain Naour <romain.naour@openwide.fr> (tiny change)
11303
11304 * linux-low.c (linux_read_offsets): Remove get_thread_lwp.
11305
b88bb450
GB
113062015-04-09 Gary Benson <gbenson@redhat.com>
11307
11308 * hostio-errno.c (errno_to_fileio_error): Remove function.
11309 Update caller to use remote_fileio_to_fio_error.
11310
c8f4bfdd
YQ
113112015-04-09 Yao Qi <yao.qi@linaro.org>
11312
11313 * linux-low.c (linux_insert_point): Call
11314 insert_memory_breakpoint if TYPE is raw_bkpt_type_sw.
11315 (linux_remove_point): Call remove_memory_breakpoint if type is
11316 raw_bkpt_type_sw.
11317 * linux-x86-low.c (x86_insert_point): Don't call
11318 insert_memory_breakpoint.
11319 (x86_remove_point): Don't call remove_memory_breakpoint.
11320
41f98f02
PA
113212015-04-01 Pedro Alves <palves@redhat.com>
11322 Cleber Rosa <crosa@redhat.com>
11323
11324 * server.c (gdbserver_usage): Reorganize and extend the usage
11325 message.
11326
2bf6fb9d
PA
113272015-03-24 Pedro Alves <palves@redhat.com>
11328
11329 * linux-low.c (check_stopped_by_breakpoint): Tweak debug log
11330 output. Also dump TRAP_TRACE.
11331 (linux_low_filter_event): In debug output, distinguish a
11332 resume_stop SIGSTOP from a delayed SIGSTOP.
11333
369f6daa
GB
113342015-03-24 Gary Benson <gbenson@redhat.com>
11335
11336 * linux-x86-low.c (x86_linux_new_thread): Moved to
11337 nat/x86-linux.c.
11338 (x86_linux_prepare_to_resume): Likewise.
11339
8e5d4070
GB
113402015-03-24 Gary Benson <gbenson@redhat.com>
11341
11342 * Makefile.in (x86-linux-dregs.o): New rule.
11343 * configure.srv: Add x86-linux-dregs.o to relevant targets.
11344 * linux-x86-low.c: Include nat/x86-linux-dregs.h.
11345 (u_debugreg_offset): Moved to nat/x86-linux-dregs.c.
11346 (x86_linux_dr_get): Likewise.
11347 (x86_linux_dr_set): Likewise.
11348 (update_debug_registers_callback): Likewise.
11349 (x86_linux_dr_set_addr): Likewise.
11350 (x86_linux_dr_get_addr): Likewise.
11351 (x86_linux_dr_set_control): Likewise.
11352 (x86_linux_dr_get_control): Likewise.
11353 (x86_linux_dr_get_status): Likewise.
11354 (x86_linux_update_debug_registers): Likewise.
11355
2b95d440
GB
113562015-03-24 Gary Benson <gbenson@redhat.com>
11357
11358 * linux-x86-low.c (x86_linux_update_debug_registers):
11359 New function, factored out from...
11360 (x86_linux_prepare_to_resume): ...this.
11361
14b0bc68
GB
113622015-03-24 Gary Benson <gbenson@redhat.com>
11363
11364 * linux-x86-low.c (x86_linux_dr_get): Update comments.
11365 (x86_linux_dr_set): Likewise.
11366 (update_debug_registers_callback): Likewise.
11367 (x86_linux_dr_set_addr): Likewise.
11368 (x86_linux_dr_get_addr): Likewise.
11369 (x86_linux_dr_set_control): Likewise.
11370 (x86_linux_dr_get_control): Likewise.
11371 (x86_linux_dr_get_status): Likewise.
11372 (x86_linux_prepare_to_resume): Likewise.
11373
5dfe6ca8
GB
113742015-03-24 Gary Benson <gbenson@redhat.com>
11375
11376 * linux-x86-low.c (x86_linux_dr_get): Add assertion.
11377 Use perror_with_name. Pass string through gettext.
11378 (x86_linux_dr_set): Likewise.
11379
d33472ad
GB
113802015-03-24 Gary Benson <gbenson@redhat.com>
11381
11382 * linux-x86-low.c (x86_dr_low_set_addr): Rename to...
11383 (x86_linux_dr_set_addr): ...this.
11384 (x86_dr_low_get_addr): Rename to...
11385 (x86_linux_dr_get_addr): ...this.
11386 (x86_dr_low_set_control): Rename to...
11387 (x86_linux_dr_set_control): ...this.
11388 (x86_dr_low_get_control): Rename to...
11389 (x86_linux_dr_get_control): ...this.
11390 (x86_dr_low_get_status): Rename to...
11391 (x86_linux_dr_get_status): ...this.
11392 (x86_dr_low): Update with new function names.
11393
4b134ca1
GB
113942015-03-24 Gary Benson <gbenson@redhat.com>
11395
11396 * Makefile.in (x86-linux.o): New rule.
11397 * configure.srv: Add x86-linux.o to relevant targets.
11398 * linux-low.c (lwp_set_arch_private_info): New function.
11399 (lwp_arch_private_info): Likewise.
11400 * linux-x86-low.c: Include nat/x86-linux.h.
11401 (arch_lwp_info): Removed structure.
11402 (update_debug_registers_callback):
11403 Use lwp_set_debug_registers_changed.
11404 (x86_linux_prepare_to_resume): Use lwp_debug_registers_changed
11405 and lwp_set_debug_registers_changed.
11406 (x86_linux_new_thread): Use lwp_set_debug_registers_changed.
11407
34c703da
GB
114082015-03-24 Gary Benson <gbenson@redhat.com>
11409
11410 * linux-low.h (linux_target_ops) <new_thread>: Changed signature.
11411 * linux-arm-low.c (arm_new_thread): Likewise.
11412 * linux-aarch64-low.c (aarch64_linux_new_thread): Likewise.
11413 * linux-mips-low.c (mips_linux_new_thread): Likewise.
11414 * linux-x86-low.c (x86_linux_new_thread): Likewise.
11415 * linux-low.c (add_lwp): Update the_low_target.new_thread call.
11416
cff068da
GB
114172015-03-24 Gary Benson <gbenson@redhat.com>
11418
11419 * linux-low.c (ptid_of_lwp): New function.
11420 (lwp_is_stopped): Likewise.
11421 (lwp_stop_reason): Likewise.
11422 * linux-x86-low.c (update_debug_registers_callback):
11423 Use lwp_is_stopped.
11424 (x86_linux_prepare_to_resume): Use ptid_of_lwp and
11425 lwp_stop_reason.
11426
b2f7c7e8
GB
114272015-03-24 Gary Benson <gbenson@redhat.com>
11428
11429 * linux-low.h (linux_stop_lwp): Remove declaration.
11430
6d4ee8c6
GB
114312015-03-24 Gary Benson <gbenson@redhat.com>
11432
11433 * linux-low.h: Include nat/linux-nat.h.
11434 * linux-low.c (iterate_over_lwps_args): New structure.
11435 (iterate_over_lwps_filter): New function.
11436 (iterate_over_lwps): Likewise.
11437 * linux-x86-low.c (update_debug_registers_callback):
11438 Update signature to what iterate_over_lwps expects.
11439 Remove PID check that iterate_over_lwps now performs.
11440 (x86_dr_low_set_addr): Use iterate_over_lwps.
11441 (x86_dr_low_set_control): Likewise.
11442
70a0bb6b
GB
114432015-03-24 Gary Benson <gbenson@redhat.com>
11444
11445 * linux-x86-low.c (x86_debug_reg_state): New function.
11446 (x86_linux_prepare_to_resume): Use the above.
11447
7b669087
GB
114482015-03-24 Gary Benson <gbenson@redhat.com>
11449
11450 * linux-low.c (current_lwp_ptid): New function.
11451 * linux-x86-low.c: Include nat/linux-nat.h.
11452 (x86_dr_low_get_addr): Use current_lwp_ptid.
11453 (x86_dr_low_get_control): Likewise.
11454 (x86_dr_low_get_status): Likewise.
11455
eef49a3d
PA
114562015-03-20 Pedro Alves <palves@redhat.com>
11457
11458 * tracepoint.c (cmd_qtstatus): Make "str" const.
11459
b2333d22
PA
114602015-03-20 Pedro Alves <palves@redhat.com>
11461
11462 * server.c (handle_general_set): Make "req_str" const.
11463
23f238d3
PA
114642015-03-19 Pedro Alves <palves@redhat.com>
11465
11466 * linux-low.c (linux_resume_one_lwp): Rename to ...
11467 (linux_resume_one_lwp_throw): ... this. Don't handle ESRCH here,
11468 instead call perror_with_name.
11469 (check_ptrace_stopped_lwp_gone): New function.
11470 (linux_resume_one_lwp): Reimplement as wrapper around
11471 linux_resume_one_lwp_throw that swallows errors if the LWP is
11472 gone.
11473
91baf43f
PA
114742015-03-19 Pedro Alves <palves@redhat.com>
11475
11476 * linux-low.c (count_events_callback, select_event_lwp_callback):
11477 No longer check whether the thread has resume_stop as last resume
11478 kind.
11479
8bf3b159
PA
114802015-03-19 Pedro Alves <palves@redhat.com>
11481
11482 * linux-low.c (count_events_callback, select_event_lwp_callback):
11483 Use the lwp's status_pending_p field, not the thread's.
11484
b90fc188
PA
114852015-03-19 Pedro Alves <palves@redhat.com>
11486
11487 * linux-low.c (select_event_lwp_callback): Update comments to
11488 no longer mention SIGTRAP.
11489
464b0089
GB
114902015-03-18 Gary Benson <gbenson@redhat.com>
11491
11492 * server.c (handle_query): Do not report vFile:fstat as supported.
11493
aa9e327f
GB
114942015-03-11 Gary Benson <gbenson@redhat.com>
11495
11496 * hostio.c (sys/types.h): New include.
11497 (sys/stat.h): Likewise.
11498 (common-remote-fileio.h): Likewise.
11499 (handle_fstat): New function.
11500 (handle_vFile): Handle vFile:fstat packets.
aa9e327f 11501
791c0056
GB
115022015-03-11 Gary Benson <gbenson@redhat.com>
11503
11504 * configure.ac (AC_CHECK_MEMBERS): Add checks for
11505 struct stat.st_blocks and struct stat.st_blksize.
11506 * configure: Regenerate.
11507 * config.in: Likewise.
11508 * Makefile.in (SFILES): Add common/common-remote-fileio.c.
11509 (OBS): Add common-remote-fileio.o.
11510 (common-remote-fileio.o): New rule.
11511
9a9df970
PA
115122015-03-09 Pedro Alves <palves@redhat.com>
11513
11514 * tracepoint.c (gdb_agent_helper_thread): Cast '&sockaddr' to
11515 'struct sockaddr' pointer in 'accept' call.
11516
9eb1356e
PA
115172015-03-09 Pedro Alves <palves@redhat.com>
11518
11519 Revert:
11520 2015-03-07 Pedro Alves <palves@redhat.com>
11521 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
11522 or <winsock2.h> here. Instead include "gdb_socket.h".
11523 (remote_open): Use union gdb_sockaddr_u.
11524 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
11525 or <winsock2.h> here. Instead include "gdb_socket.h".
11526 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
11527 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
11528 or <sys/un.h>.
11529 (init_named_socket, gdb_agent_helper_thread): Use union
11530 gdb_sockaddr_u.
11531
aac331e4
PA
115322015-03-07 Pedro Alves <palves@redhat.com>
11533
11534 * configure.ac (build_warnings): Move
11535 -Wdeclaration-after-statement to the C-specific set.
11536 * configure: Regenerate.
11537
366c75fc
PA
115382015-03-07 Pedro Alves <palves@redhat.com>
11539
11540 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
11541 or <winsock2.h> here. Instead include "gdb_socket.h".
11542 (remote_open): Use union gdb_sockaddr_u.
11543 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
11544 or <winsock2.h> here. Instead include "gdb_socket.h".
11545 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
11546 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
11547 or <sys/un.h>.
11548 (init_named_socket, gdb_agent_helper_thread): Use union
11549 gdb_sockaddr_u.
11550
492d29ea
PA
115512015-03-07 Pedro Alves <palves@redhat.com>
11552
11553 Adjust all callers of TRY_CATCH to use TRY/CATCH/END_CATCH
11554 instead.
11555
60a191ed
YQ
115562015-03-06 Yao Qi <yao.qi@linaro.org>
11557
11558 * linux-aarch64-low.c (aarch64_insert_point): Use
11559 show_debug_regs as a boolean.
11560 (aarch64_remove_point): Likewise.
11561
f5771b1d
PA
115622015-03-05 Pedro Alves <palves@redhat.com>
11563
11564 * lynx-low.c (lynx_target_ops): Install NULL hooks for
11565 stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
11566 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint.
11567 * nto-low.c (nto_target_ops): Likewise.
11568 * spu-low.c (spu_target_ops): Likewise.
11569 * win32-low.c (win32_target_ops): Likewise.
11570
3e572f71
PA
115712015-03-04 Pedro Alves <palves@redhat.com>
11572
72f4393d 11573 * linux-low.c (check_stopped_by_breakpoint) [USE_SIGTRAP_SIGINFO]:
3e572f71
PA
11574 Decide whether a breakpoint triggered based on the SIGTRAP's
11575 siginfo.si_code.
72f4393d
L
11576 (thread_still_has_status_pending_p) [USE_SIGTRAP_SIGINFO]: Don't check whether a
11577 breakpoint is inserted if relying on SIGTRAP's siginfo.si_code.
3e572f71
PA
11578 (linux_low_filter_event): Check for breakpoints before checking
11579 watchpoints.
11580 (linux_wait_1): Don't re-increment the PC if relying on SIGTRAP's
11581 siginfo.si_code.
72f4393d
L
11582 (linux_stopped_by_sw_breakpoint)
11583 (linux_supports_stopped_by_sw_breakpoint)
11584 (linux_stopped_by_hw_breakpoint)
11585 (linux_supports_stopped_by_hw_breakpoint): New functions.
11586 (linux_target_ops): Install new target methods.
3e572f71 11587
1ec68e26
PA
115882015-03-04 Pedro Alves <palves@redhat.com>
11589
11590 * remote-utils.c (prepare_resume_reply): Report swbreak/hbreak.
11591 * server.c (swbreak_feature, hwbreak_feature): New globals.
11592 (handle_query) <qSupported>: Handle "swbreak+" and "hwbreak+".
11593 (captured_main): Clear swbreak_feature and hwbreak_feature.
11594 * server.h (swbreak_feature, hwbreak_feature): Declare.
11595 * target.h (struct target_ops) <stopped_by_sw_breakpoint,
11596 supports_stopped_by_sw_breakpoint, stopped_by_hw_breakpoint,
11597 supports_stopped_by_hw_breakpoint>: New fields.
11598 (target_supports_stopped_by_sw_breakpoint)
11599 (target_stopped_by_sw_breakpoint)
11600 (target_supports_stopped_by_hw_breakpoint)
11601 (target_stopped_by_hw_breakpoint): Declare.
11602
15c66dd6
PA
116032015-03-04 Pedro Alves <palves@redhat.com>
11604
11605 enum lwp_stop_reason -> enum target_stop_reason
11606 * linux-low.c (check_stopped_by_breakpoint): Adjust.
11607 (thread_still_has_status_pending_p, check_stopped_by_watchpoint)
11608 (linux_wait_1, stuck_in_jump_pad_callback)
11609 (move_out_of_jump_pad_callback, linux_resume_one_lwp)
11610 (linux_stopped_by_watchpoint):
11611 * linux-low.h (enum lwp_stop_reason): Delete.
11612 (struct lwp_info) <stop_reason>: Now an enum target_stop_reason.
11613 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
11614
98fc70d6
YQ
116152015-03-04 Yao Qi <yao.qi@linaro.org>
11616
11617 * Makefile.in (SFILES): Add linux-aarch64-low.c.
11618
dd2ac174
GB
116192015-03-03 Gary Benson <gbenson@redhat.com>
11620
11621 * hostio.c (handle_vFile): Fix prefix lengths.
11622
d68e53f4
MM
116232015-03-03 Markus Metzger <markus.t.metzger@intel.com>
11624
11625 * linux-low.c (linux_low_enable_btrace): Do not overwrite non-zero
11626 ptr_bits.
11627
bf2d68ab
AA
116282015-03-02 Andreas Arnez <arnez@linux.vnet.ibm.com>
11629
11630 * Makefile.in (s390-vx-linux64.c, s390-tevx-linux64.c)
11631 (s390x-vx-linux64.c, s390x-tevx-linux64.c): New rules.
11632 (clean): Add "rm -f" for above C files.
11633 * configure.srv (srv_regobj): Add s390-vx-linux64.o,
11634 s390-tevx-linux64.o, s390x-vx-linux64.o, and s390x-tevx-linux64.o.
11635 (srv_xmlfiles): Add s390-vx-linux64.xml, s390-tevx-linux64.xml,
11636 s390x-vx-linux64.xml, s390x-tevx-linux64.xml, and s390-vx.xml.
11637 * linux-s390-low.c (HWCAP_S390_VX): New macro.
11638 (init_registers_s390_vx_linux64, init_registers_s390_tevx_linux64)
11639 (init_registers_s390x_vx_linux64)
11640 (init_registers_s390x_tevx_linux64)
11641 (tdesc_s390_vx_linux64, tdesc_s390_tevx_linux64)
11642 (tdesc_s390x_vx_linux64, tdesc_s390x_tevx_linux64): New extern
11643 declarations.
11644 (s390_fill_vxrs_low, s390_store_vxrs_low, s390_fill_vxrs_high)
11645 (s390_store_vxrs_high): New functions.
11646 (s390_regsets): Add entries for NT_S390_VXRS_LOW and
11647 NT_S390_VXRS_HIGH.
11648 (s390_arch_setup): Add logic for selecting one of the new target
11649 descriptions. Activate the new vector regsets if applicable.
11650 (initialize_low_arch): Also invoke init_registers_s390_vx_linux64,
11651 init_registers_s390_tevx_linux64, init_registers_s390x_vx_linux64,
11652 and init_registers_s390x_tevx_linux64.
11653
c966a859
PA
116542015-03-01 Pedro Alves <palves@redhat.com>
11655
11656 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Constify 'raw_regs'
11657 parameter.
11658
4180215b
PA
116592015-02-27 Pedro Alves <palves@redhat.com>
11660
11661 * linux-x86-low.c (u_debugreg_offset): New function.
11662 (x86_linux_dr_get, x86_linux_dr_set): Use it.
11663
749bab01
PA
116642015-02-27 Pedro Alves <palves@redhat.com>
11665
11666 * gdb_proc_service.h: Wrap with EXTERN_C_PUSH/EXTERN_C_POP.
11667 [!HAVE_PROC_SERVICE_H] (struct ps_prochandle): Forward declare.
11668 [!HAVE_PROC_SERVICE_H] (ps_pdread, ps_pdwrite, ps_ptread)
11669 ps_ptwrite, ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
11670 (ps_lsetfpregs, ps_getpid)
11671 (ps_get_thread_area, ps_pglobal_lookup, ps_pstop, ps_pcontinue)
11672 (ps_lstop, ps_lcontinue, ps_lgetxregsize, ps_lgetxregs)
11673 (ps_lsetxregs, ps_plog): Declare.
11674
3c14e5a3
PA
116752015-02-27 Pedro Alves <palves@redhat.com>
11676
11677 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Use
11678 IP_AGENT_EXPORT_FUNC.
11679 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Use
11680 IP_AGENT_EXPORT_FUNC.
11681 * tracepoint.c (ATTR_USED, ATTR_NOINLINE, ATTR_CONSTRUCTOR)
11682 (IP_AGENT_EXPORT): Delete.
11683 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
11684 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
11685 (gdb_trampoline_buffer_error, collecting, gdb_collect)
11686 (stop_tracing, flush_trace_buffer, about_to_request_buffer_space)
11687 (trace_buffer_is_full, stopping_tracepoint, expr_eval_result)
11688 (error_tracepoint, tracepoints, tracing, trace_buffer_ctrl)
11689 (trace_buffer_ctrl_curr, trace_buffer_lo, trace_buffer_hi)
11690 (traceframe_read_count, traceframe_write_count)
11691 (traceframes_created, trace_state_variables, get_raw_reg)
11692 (get_trace_state_variable_value, set_trace_state_variable_value)
11693 (ust_loaded, helper_thread_id, cmd_buf): Use
11694 IPA_SYM_EXPORTED_NAME.
11695 (stop_tracing, flush_trace_buffer): Use IP_AGENT_EXPORT_FUNC.
11696 (tracepoints) Use IP_AGENT_EXPORT_VAR.
11697 (stopping_tracepoint, trace_buffer_is_full, expr_eval_result): Use
11698 IP_AGENT_EXPORT_VAR and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
11699 (last_tracepoint): Move into !IN_PROCESS_AGENT block.
11700 (error_tracepoint): Use IP_AGENT_EXPORT_VAR and wrap in
11701 EXTERN_C_PUSH/EXTERN_C_POP.
11702 (trace_state_variables): Use IP_AGENT_EXPORT_VAR.
11703 (trace_buffer_lo, trace_buffer_hi): Use IP_AGENT_EXPORT_VAR and
11704 wrap in EXTERN_C_PUSH/EXTERN_C_POP.
11705 (trace_buffer_ctrl, trace_buffer_ctrl_curr)
11706 (traceframe_write_count, traceframe_read_count)
11707 (traceframes_created, tracing): Use IP_AGENT_EXPORT_VAR.
11708 (about_to_request_buffer_space, get_trace_state_variable_value)
11709 (set_trace_state_variable_value): Use IP_AGENT_EXPORT_FUNC.
11710 (collecting): Use IP_AGENT_EXPORT_VAR and wrap in
11711 EXTERN_C_PUSH/EXTERN_C_POP.
11712 (gdb_collect): Use IP_AGENT_EXPORT_FUNC.
11713 (ust_loaded, cmd_buf): Use IP_AGENT_EXPORT_VAR.
11714 (helper_thread_id, gdb_agent_capability): Use IP_AGENT_EXPORT_VAR
11715 and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
11716 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
11717 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
11718 (gdb_trampoline_buffer_error): Use IP_AGENT_EXPORT_VAR.
11719 * tracepoint.h (ATTR_USED, ATTR_NOINLINE, EXPORTED_SYMBOL):
11720 Define.
11721 (IP_AGENT_EXPORT_FUNC, IP_AGENT_EXPORT_VAR)
11722 (IP_AGENT_EXPORT_VAR_DECL): Define.
11723 (tracing): Declare.
11724 (gdb_agent_get_raw_reg): Declare.
11725
fe978cb0
PA
117262015-02-27 Tom Tromey <tromey@redhat.com>
11727 Pedro Alves <palves@redhat.com>
11728
11729 Rename symbols whose names are reserved C++ keywords throughout.
11730
3bc3d82a
PA
117312015-02-27 Pedro Alves <palves@redhat.com>
11732
11733 * Makefile.in (COMPILER): New, get it from autoconf.
11734 (CXX): Get from autoconf instead.
11735 (COMPILE.pre): Use COMPILER.
11736 (CC-LD): Rename to ...
11737 (CC_LD): ... this. Use COMPILER.
11738 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT), $(IPA_LIB)): Adjust.
11739 (CXX_FOR_TARGET): Default to g++ instead of gcc.
11740 * acinclude.m4: Include build-with-cxx.m4.
11741 * configure.ac: Call AC_PROG_CXX and GDB_AC_BUILD_WITH_CXX.
11742 Disable -Werror by default if building in C++ mode.
11743 (build_warnings): Add -Wno-sign-compare, -Wno-write-strings and
11744 -Wno-narrowing in C++ mode. Run supported-warning-flags tests with
11745 the C++ compiler. Save/restore CXXFLAGS too.
11746 * configure: Regenerate.
11747
07697489
PA
117482015-02-27 Pedro Alves <palves@redhat.com>
11749
11750 * acinclude.m4: Include libiberty.m4.
11751 * configure.ac: Call libiberty_INIT.
11752 * config.in, configure: Regenerate.
11753
9beb7c4e
PA
117542015-02-26 Pedro Alves <palves@redhat.com>
11755
11756 * linux-low.c (linux_wait_1): When incrementing the PC past a
11757 program breakpoint always use the_low_target.breakpoint_len as
11758 increment, rather than the maximum between that and
11759 the_low_target.decr_pc_after_break.
11760
8090aef2
PA
117612015-02-23 Pedro Alves <palves@redhat.com>
11762
11763 * linux-low.c (check_stopped_by_breakpoint): Don't check if the
11764 thread was doing a step-over; always adjust the PC if
11765 we stepped over a permanent breakpoint.
11766 (linux_wait_1): If we stepped over breakpoint that was on top of a
11767 permanent breakpoint, manually advance the PC past it.
11768
bc9540e8
PA
117692015-02-23 Pedro Alves <palves@redhat.com>
11770
11771 * linux-x86-low.c (REGSIZE): Define in both 32-bit and 64-bit
11772 modes.
11773 (x86_fill_gregset, x86_store_gregset): Use it when handling
11774 $orig_eax.
11775
2db9a427
PA
117762015-02-20 Pedro Alves <palves@redhat.com>
11777
11778 * thread-db.c: Include "nat/linux-procfs.h".
11779 (thread_db_init): Skip listing new threads if the kernel supports
11780 PTRACE_EVENT_CLONE and /proc/PID/task/ is accessible.
11781
afa8d396
PA
117822015-02-20 Pedro Alves <palves@redhat.com>
11783
11784 * linux-low.c (status_pending_p_callback): Use ptid_match.
11785
c9587f88
AT
117862015-02-19 Antoine Tremblay <antoine.tremblay@ericsson.com>
11787
11788 PR breakpoints/16812
11789 * linux-low.c (wstatus_maybe_breakpoint): Remove.
11790 (linux_low_filter_event): Update wstatus_maybe_breakpoint name.
11791 (linux_wait_1): Report SIGTRAP,SIGILL,SIGSEGV.
11792
b05ec7a5
AT
117932015-02-10 Antoine Tremblay <antoine.tremblay@ericsson.com>
11794
11795 PR breakpoints/15956
11796 * tracepoint.c (cmd_qtinit): Add check for current_thread.
11797
d33501a5
MM
117982015-02-09 Markus Metzger <markus.t.metzger@intel.com>
11799
11800 * linux-low.c (linux_low_btrace_conf): Print size.
11801 * server.c (handle_btrace_conf_general_set): New.
11802 (hanle_general_set): Call handle_btrace_conf_general_set.
11803 (handle_query): Report Qbtrace-conf:bts:size as supported.
11804
f4abbc16
MM
118052015-02-09 Markus Metzger <markus.t.metzger@intel.com>
11806
11807 * linux-low.c (linux_low_enable_btrace): Update parameters.
11808 (linux_low_btrace_conf): New.
11809 (linux_target_ops)<to_btrace_conf>: Initialize.
11810 * server.c (current_btrace_conf): New.
11811 (handle_btrace_enable): Rename to ...
11812 (handle_btrace_enable_bts): ... this. Pass &current_btrace_conf
11813 to target_enable_btrace. Update comment. Update users.
11814 (handle_qxfer_btrace_conf): New.
11815 (qxfer_packets): Add btrace-conf entry.
11816 (handle_query): Report qXfer:btrace-conf:read as supported packet.
11817 * target.h (target_ops)<enable_btrace>: Update parameters and comment.
11818 (target_ops)<read_btrace_conf>: New.
11819 (target_enable_btrace): Update parameters.
11820 (target_read_btrace_conf): New.
11821
043c3577
MM
118222015-02-09 Markus Metzger <markus.t.metzger@intel.com>
11823
11824 * server.c (handle_btrace_general_set): Remove call to
11825 target_supports_btrace.
11826 (supported_btrace_packets): New.
11827 (handle_query): Call supported_btrace_packets.
11828 * target.h: include btrace-common.h.
11829 (btrace_target_info): Removed.
11830 (supports_btrace, target_supports_btrace): Update parameters.
11831
734b0e4b
MM
118322015-02-09 Markus Metzger <markus.t.metzger@intel.com>
11833
11834 * Makefile.in (SFILES): Add common/btrace-common.c.
11835 (OBS): Add common/btrace-common.o.
11836 (btrace-common.o): Add build rules.
11837 * linux-low: Include btrace-common.h.
11838 (linux_low_read_btrace): Use struct btrace_data. Call
11839 btrace_data_init and btrace_data_fini.
11840
d6c146e9
PA
118412015-02-06 Pedro Alves <palves@redhat.com>
11842
11843 * thread-db.c (find_new_threads_callback): Add debug output.
11844
20ba1ce6
PA
118452015-02-04 Pedro Alves <palves@redhat.com>
11846
11847 * linux-low.c (handle_extended_wait): Don't resume LWPs here.
11848 (resume_stopped_resumed_lwps): New function.
11849 (linux_wait_for_event_filtered): Use it.
11850
8cc73a39
SDJ
118512015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
11852
11853 * Makefile.in (SFILES): Add linux-personality.c.
11854 (linux-personality.o): New rule.
11855 * configure.srv (srv_linux_obj): Add linux-personality.o to the
11856 list of objects to be built.
11857 * linux-low.c: Include nat/linux-personality.h.
11858 (linux_create_inferior): Remove code to disable address space
11859 randomization (moved to ../nat/linux-personality.c). Create
11860 cleanup to disable address space randomization.
11861
fb23d554
SDJ
118622015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
11863
11864 * Makefile.in (posix-strerror.o): New rule.
11865 (mingw-strerror.o): Likewise.
11866 * configure: Regenerated.
11867 * configure.ac: Source file ../common/common.host. Initialize new
11868 variable srv_host_obs. Add srv_host_obs to GDBSERVER_DEPFILES.
11869
cdf43629
YQ
118702015-01-14 Yao Qi <yao@codesourcery.com>
11871
11872 * Makefile.in (SFILES): Add nat/ppc-linux.c.
11873 (ppc-linux.o): New rule.
11874 * configure.srv (powerpc*-*-linux*): Add ppc-linux.o.
11875 * configure.ac: AC_CHECK_FUNCS(getauxval).
11876 * config.in: Re-generated.
11877 * configure: Re-generated.
11878 * linux-ppc-low.c (ppc_arch_setup) [__powerpc64__]: Call
11879 ppc64_64bit_inferior_p
11880
514c5338
YQ
118812015-01-14 Yao Qi <yao@codesourcery.com>
11882
11883 * linux-ppc-low.c: Include "nat/ppc-linux.h".
11884 (PPC_FEATURE_HAS_VSX): Move to nat/ppc-linux.h.
11885 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Likewise.
11886 (PT_ORIG_R3, PT_TRAP): Likewise.
11887 (PTRACE_GETVSXREGS, PTRACE_SETVSXREGS): Likewise.
11888 (PTRACE_GETVRREGS, PTRACE_SETVRREGS): Likewise.
11889 (PTRACE_GETEVRREGS, PTRACE_SETEVRREGS): Likewise.
11890
3368c1e5
JB
118912015-01-10 Joel Brobecker <brobecker@adacore.com>
11892
11893 * i387-fp.c (i387_cache_to_xsave): In look over
11894 num_avx512_zmmh_high_registers, replace use of struct i387_xsave
11895 zmmh_low_space field by use of zmmh_high_space.
11896
582511be
PA
118972015-01-09 Pedro Alves <palves@redhat.com>
11898
11899 * linux-low.c (step_over_bkpt): Move higher up in the file.
11900 (handle_extended_wait): Don't store the stop_pc here.
11901 (get_stop_pc): Adjust comments and rename to ...
11902 (check_stopped_by_breakpoint): ... this. Record whether the LWP
11903 stopped for a software breakpoint or hardware breakpoint.
11904 (thread_still_has_status_pending_p): New function.
11905 (status_pending_p_callback): Use
11906 thread_still_has_status_pending_p. If the event is no longer
11907 interesting, resume the LWP.
11908 (handle_tracepoints): Add assert.
11909 (maybe_move_out_of_jump_pad): Remove cancel_breakpoints call.
11910 (wstatus_maybe_breakpoint): New function.
11911 (cancel_breakpoint): Delete function.
11912 (check_stopped_by_watchpoint): New function, factored out from
11913 linux_low_filter_event.
11914 (lp_status_maybe_breakpoint): Delete function.
11915 (linux_low_filter_event): Remove filter_ptid argument.
11916 Leave thread group exits pending here. Store the LWP's stop PC.
11917 Always leave events pending.
11918 (linux_wait_for_event_filtered): Pull all events out of the
11919 kernel, and leave them all pending.
11920 (count_events_callback, select_event_lwp_callback): Consider all
11921 events.
11922 (cancel_breakpoints_callback, linux_cancel_breakpoints): Delete.
11923 (select_event_lwp): Only give preference to the stepping LWP in
11924 all-stop mode. Adjust comments.
11925 (ignore_event): New function.
11926 (linux_wait_1): Delete 'retry' label. Use ignore_event. Remove
11927 references to cancel_breakpoints. Adjust to renames. Also give
11928 equal priority to all LWPs that have had events in non-stop mode.
11929 If reporting a software breakpoint event, unadjust the LWP's PC.
11930 (linux_wait): If linux_wait_1 returned an ignored event, retry.
11931 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback):
11932 Adjust.
11933 (linux_resume_one_lwp): Store the LWP's PC. Adjust.
11934 (resume_status_pending_p): Use thread_still_has_status_pending_p.
11935 (linux_stopped_by_watchpoint): Adjust.
11936 (linux_target_ops): Remove reference to linux_cancel_breakpoints.
11937 * linux-low.h (enum lwp_stop_reason): New.
11938 (struct lwp_info) <stop_pc>: Adjust comment.
11939 <stopped_by_watchpoint>: Delete field.
11940 <stop_reason>: New field.
11941 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
11942 * mem-break.c (software_breakpoint_inserted_here)
11943 (hardware_breakpoint_inserted_here): New function.
11944 * mem-break.h (software_breakpoint_inserted_here)
11945 (hardware_breakpoint_inserted_here): Declare.
11946 * target.h (struct target_ops) <cancel_breakpoints>: Remove field.
11947 (cancel_breakpoints): Delete.
11948 * tracepoint.c (clear_installed_tracepoints, stop_tracing)
11949 (upload_fast_traceframes): Remove references to
11950 cancel_breakpoints.
11951
a33e3959
PA
119522015-01-09 Pedro Alves <palves@redhat.com>
11953
11954 * thread-db.c (find_new_threads_callback): Ignore thread if the
11955 kernel thread ID is -1.
11956
8784d563
PA
119572015-01-09 Pedro Alves <palves@redhat.com>
11958
11959 * linux-low.c (linux_attach_fail_reason_string): Move to
11960 nat/linux-ptrace.c, and rename.
11961 (linux_attach_lwp): Update comment.
11962 (attach_proc_task_lwp_callback): New function.
11963 (linux_attach): Adjust to rename and use
11964 linux_proc_attach_tgid_threads.
11965 (linux_attach_fail_reason_string): Delete declaration.
11966
76f2b779
JB
119672015-01-01 Joel Brobecker <brobecker@adacore.com>
11968
11969 * gdbreplay.c (gdbreplay_version): Update copyright year to 2015.
11970 * server.c (gdbserver_version): Likewise.
11971
fafcc06a
SDJ
119722014-12-29 Sergio Durigan Junior <sergiodj@redhat.com>
11973
11974 * remote-utils.c: Include ctype.h.
11975 (input_interrupt): Explicitly handle the case when the char
11976 received is the NUL byte. Improve the printing of non-ASCII
11977 characters.
11978
beed38b8
JB
119792014-12-16 Joel Brobecker <brobecker@adacore.com>
11980
11981 * linux-low.c (linux_low_filter_event): Update call to
11982 linux_enable_event_reporting following the addition of
11983 a new parameter to that function.
11984
bf330350
CU
119852014-12-16 Catalin Udma <catalin.udma@freescale.com>
11986
11987 PR server/17457
11988 * linux-aarch64-low.c (AARCH64_FPSR_REGNO): New define.
11989 (AARCH64_FPCR_REGNO): Likewise.
11990 (AARCH64_NUM_REGS): Update to include fpsr/fpcr registers.
11991 (aarch64_fill_fpregset): Add missing fpsr/fpcr registers.
11992 (aarch64_store_fpregset): Likewise.
11993
5227d625
JB
119942014-12-15 Joel Brobecker <brobecker@adacore.com>
11995
11996 * lynx-low.c (lynx_resume): Use PTRACE_SINGLESTEP_ONE if N == 1.
11997 Remove FIXME comment about assumption about N.
11998
f93b65a0
JB
119992014-12-13 Joel Brobecker <brobecker@adacore.com>
12000
12001 * configure.ac: If large-file support is disabled in GDBserver,
12002 pass --disable-largefile to ACX_CONFIGURE_DIR call for "gnulib".
12003 * configure: Regenerate.
12004
e5a9158d
AA
120052014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
12006
12007 * linux-low.c (regsets_fetch_inferior_registers): Suppress the
12008 warning upon ENODATA from ptrace.
12009 * linux-s390-low.c (s390_store_tdb): New.
12010 (s390_regsets): Add regset for NT_S390_TDB.
12011
feea5f36
AA
120122014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
12013
12014 * linux-low.c (regsets_store_inferior_registers): Skip regsets
12015 without a fill_function.
12016 * linux-s390-low.c (s390_fill_last_break): Remove.
12017 (s390_regsets): Set fill_function to NULL for NT_S390_LAST_BREAK.
12018 (s390_arch_setup): Use regset's size instead of fill_function for
12019 loop end condition.
12020
098dbe61
AA
120212014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
12022
12023 * linux-low.c (regsets_fetch_inferior_registers): Do not invoke
12024 the regset's store function when ptrace returned an error.
12025 * regcache.c (get_thread_regcache): Invalidate register cache
12026 before fetching inferior's registers.
12027
28eef672
AA
120282014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
12029
12030 * linux-low.c (regsets_fetch_inferior_registers): Rephrase
12031 while-loop as for-loop.
12032 (regsets_store_inferior_registers): Likewise.
12033
bdca27a2
YQ
120342014-11-28 Yao Qi <yao@codesourcery.com>
12035
12036 * configure.ac(AC_CHECK_FUNCS): Remove readlink.
12037 * config.in, configure: Re-generate.
12038 * hostio.c (handle_unlink): Remove code checking HAVE_READLINK
12039 is defined.
12040
9c232dda
YQ
120412014-11-21 Yao Qi <yao@codesourcery.com>
12042
12043 * configure.ac: Don't invoke AC_FUNC_ALLOCA.
12044 (AC_CHECK_HEADERS): Remove malloc.h.
12045 * configure: Re-generated.
12046 * config.in: Re-generated.
12047 * server.h: Don't include alloca.h and malloc.h.
12048 * gdbreplay.c: Don't check HAVE_ALLOCA_H is defined.
12049 Don't include malloc.h.
12050
43968415
JB
120512014-11-17 Joel Brobecker <brobecker@adacore.com>
12052
12053 * lynx-low.c (lynx_write_memory): Put lynx_read_memory and
12054 corresponding ERRNO check in same block.
12055
40e91bc7
PA
120562014-11-12 Pedro Alves <palves@redhat.com>
12057
12058 * server.c (cont_thread): Update comment.
12059 (start_inferior, attach_inferior): No longer clear cont_thread.
12060 (handle_v_cont): No longer set cont_thread.
12061 (captured_main): Clear cont_thread each time a GDB connects.
12062
c2c118cf
PA
120632014-11-12 Pedro Alves <palves@redhat.com>
12064
12065 * linux-low.c (linux_wait_1): Don't force a wait for the Hc
12066 thread, and don't resume all threads if the Hc thread has exited.
12067
78708b7c
PA
120682014-11-12 Pedro Alves <palves@redhat.com>
12069
12070 * linux-low.c (linux_request_interrupt): Always send a SIGINT to
12071 the process group instead of to a specific LWP.
12072
a2abc7de
PA
120732014-10-15 Pedro Alves <palves@redhat.com>
12074
12075 PR server/17487
12076 * win32-arm-low.c (arm_set_thread_context): Remove current_event
12077 parameter.
12078 (arm_set_thread_context): Delete.
12079 (the_low_target): Adjust.
12080 * win32-i386-low.c (debug_registers_changed)
12081 (debug_registers_used): Delete.
12082 (update_debug_registers_callback): New function.
12083 (x86_dr_low_set_addr, x86_dr_low_set_control): Mark all threads as
12084 needing to update their debug registers.
12085 (win32_get_current_dr): New function.
12086 (x86_dr_low_get_addr, x86_dr_low_get_control)
12087 (x86_dr_low_get_status): Fetch the debug register from the thread
12088 record's context.
12089 (i386_initial_stuff): Adjust.
12090 (i386_get_thread_context): Remove current_event parameter. Don't
12091 clear debug_registers_changed nor copy DR values to
12092 debug_reg_state.
12093 (i386_set_thread_context): Delete.
12094 (i386_prepare_to_resume): New function.
12095 (i386_thread_added): Mark the thread as needing to update irs
12096 debug registers.
12097 (the_low_target): Remove i386_set_thread_context and install
12098 i386_prepare_to_resume.
12099 * win32-low.c (win32_get_thread_context): Adjust.
12100 (win32_set_thread_context): Use SetThreadContext
12101 directly.
12102 (win32_prepare_to_resume): New function.
12103 (win32_require_context): New function, factored out from ...
12104 (thread_rec): ... this.
12105 (continue_one_thread): Call win32_prepare_to_resume on each thread
12106 we're about to continue.
12107 (win32_resume): Call win32_prepare_to_resume on the event thread.
12108 * win32-low.h (struct win32_thread_info)
12109 <debug_registers_changed>: New field.
12110 (struct win32_target_ops): Change prototype of set_thread_context,
12111 delete set_thread_context and add prepare_to_resume.
12112 (win32_require_context): New declaration.
12113
a442d071
GB
121142014-10-08 Gary Benson <gbenson@redhat.com>
12115
12116 * server.h: Do not include common-exceptions.h.
12117
6f1947e8
GB
121182014-10-08 Gary Benson <gbenson@redhat.com>
12119
12120 * server.h: Do not include cleanups.h.
12121
63b434a4
JH
121222014-09-30 James Hogan <james.hogan@imgtec.com>
12123
12124 * Makefile.in (clean): Add rm -f commands for mips-dsp-linux.c and
12125 mips64-dsp-linux.c.
12126
c4d9ceb6
YQ
121272014-09-23 Yao Qi <yao@codesourcery.com>
12128
12129 * linux-low.c (lp_status_maybe_breakpoint): New function.
12130 (linux_low_filter_event): Call lp_status_maybe_breakpoint.
12131 (count_events_callback): Likewise.
12132 (select_event_lwp_callback): Likewise.
12133 (cancel_breakpoints_callback): Likewise.
12134
89a5711c
DB
121352014-09-19 Don Breazeal <donb@codesourcery.com>
12136
12137 * linux-low.c (handle_extended_wait): Call
12138 linux_ptrace_get_extended_event.
12139 (get_stop_pc, get_detach_signal, linux_low_filter_event): Call
12140 linux_is_extended_waitstatus.
12141
bffc0964
JB
121422014-09-16 Joel Brobecker <brobecker@adacore.com>
12143
12144 * Makefile.in (CPPFLAGS): Define.
12145 (INTERNAL_CFLAGS_BASE): Add ${CPPFLAGS}.
12146 (IPAGENT_CFLAGS): Remove ${CPPFLAGS}.
12147
0bfdf32f
GB
121482014-09-16 Gary Benson <gbenson@redhat.com>
12149
12150 * inferiors.h (current_inferior): Renamed as...
12151 (current_thread): New variable. All uses updated.
12152 * linux-low.c (get_pc): Renamed saved_inferior as saved_thread.
12153 (maybe_move_out_of_jump_pad): Likewise.
12154 (cancel_breakpoint): Likewise.
12155 (linux_low_filter_event): Likewise.
12156 (wait_for_sigstop): Likewise.
12157 (linux_resume_one_lwp): Likewise.
12158 (need_step_over_p): Likewise.
12159 (start_step_over): Likewise.
12160 (linux_stabilize_threads): Renamed save_inferior as saved_thread.
12161 * linux-x86-low.c (x86_linux_update_xmltarget): Likewise.
12162 * proc-service.c (ps_lgetregs): Renamed reg_inferior as reg_thread
12163 and save_inferior as saved_thread.
12164 * regcache.c (get_thread_regcache): Renamed saved_inferior as
12165 saved_thread.
12166 (regcache_invalidate_thread): Likewise.
12167 * remote-utils.c (prepare_resume_reply): Likewise.
12168 * thread-db.c (thread_db_get_tls_address): Likewise.
12169 (disable_thread_event_reporting): Likewise.
12170 (remove_thread_event_breakpoints): Likewise.
12171 * tracepoint.c (gdb_agent_about_to_close): Renamed save_inferior
12172 as saved_thread.
12173 * target.h (set_desired_inferior): Renamed as...
12174 (set_desired_thread): New declaration. All uses updated.
12175 * server.c (myresume): Updated comment to reference thread instead
12176 of inferior.
12177 (handle_serial_event): Likewise.
12178 (handle_target_event): Likewise.
12179
361c8ade
GB
121802014-09-12 Tom Tromey <tromey@redhat.com>
12181 Gary Benson <gbenson@redhat.com>
12182
12183 * regcache.h: Include common-regcache.h.
12184 (regcache_read_pc): Don't declare.
12185 * regcache.c (get_thread_regcache_for_ptid): New function.
12186
bd9269f7
GB
121872014-09-11 Tom Tromey <tromey@redhat.com>
12188 Gary Benson <gbenson@redhat.com>
12189
12190 * symbol.c: New file.
12191 * Makefile.in (SFILES): Add symbol.c.
12192 (OBS): Add symbol.o.
12193
f8c1d06b
GB
121942014-09-11 Gary Benson <gbenson@redhat.com>
12195
12196 * target.c (target_stop_ptid, target_continue_ptid): New
12197 functions.
12198
721ec300
GB
121992014-09-11 Tom Tromey <tromey@redhat.com>
12200 Gary Benson <gbenson@redhat.com>
12201
12202 * target.h: Include target/target.h.
12203 * target.c (target_read_memory, target_read_uint32)
12204 (target_write_memory): New functions.
12205
c5e92cca
GB
122062014-09-11 Gary Benson <gbenson@redhat.com>
12207
12208 * server.h (debug_hw_points): Don't declare.
12209 * server.c (debug_hw_points): Don't define. Replace all uses
12210 with show_debug_regs.
12211 * linux-aarch64-low.c (debug_hw_points): Don't define. Replace
12212 all uses with show_debug_regs.
12213
2e4bb98a
EBM
122142014-09-08 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
12215
12216 * linux-ppc-low.c (ppc_collect_ptrace_register): Adjust routine to take
12217 endianness into account.
12218 (ppc_supply_ptrace_register): Likewise.
12219
ac740bc7
JH
122202014-09-03 James Hogan <james.hogan@imgtec.com>
12221
12222 * linux-mips-low.c (mips_read_description): Reset errno to 0 prior
12223 to reading DSP_CONTROL with PTRACE_PEEKUSER ptrace call.
12224
97ea6506
GB
122252014-09-03 Gary Benson <gbenson@redhat.com>
12226
12227 * linux-x86-low.c (x86_linux_prepare_to_resume): Use
12228 ALL_DEBUG_ADDRESS_REGISTERS.
12229
df7e5265
GB
122302014-09-02 Gary Benson <gbenson@redhat.com>
12231
12232 * i386-low.h: Renamed as...
12233 * x86-low.h: New file. All type, function and variable name
12234 prefixes changed from "i386_" to "x86_". All references updated.
12235 * i386-low.c: Renamed as...
12236 * x86-low.c: New file. All type, function and variable name
12237 prefixes changed from "i386_" to "x86_". All references updated.
12238
ed859da7
GB
122392014-09-02 Gary Benson <gbenson@redhat.com>
12240
12241 * linux-x86-low.c (x86_linux_new_process): Use XCNEW.
12242 (x86_linux_new_thread): Likewise.
12243
860789c7
GB
122442014-08-29 Gary Benson <gbenson@redhat.com>
12245
12246 * server.h (setjmp.h): Do not include.
12247 (toplevel): Do not declare.
12248 (common-exceptions.h): Include.
12249 (cleanups.h): Likewise.
12250 * server.c (toplevel): Do not define.
12251 (exit_code): New static global.
12252 (detach_or_kill_for_exit_cleanup): New function.
12253 (main): New function. Original main renamed to...
12254 (captured_main): New function.
12255 * utils.c (verror) [!IN_PROCESS_AGENT]: Use throw_verror.
12256
ff55e1b5
GB
122572014-08-29 Gary Benson <gbenson@redhat.com>
12258
12259 * Makefile.in (SFILES): Add common/common-exceptions.c.
12260 (OBS): Add common-exceptions.o.
12261 (common-exceptions.o): New rule.
12262 * utils.c (prepare_to_throw_exception): New function.
12263
e9bcb658
GB
122642014-08-29 Gary Benson <gbenson@redhat.com>
12265
12266 * config.in: Regenerate.
12267 * configure: Likewise.
12268
e3180625
GB
122692014-08-29 Gary Benson <gbenson@redhat.com>
12270
12271 * Makefile.in (SFILES): Add common/cleanups.c.
12272 (OBS): cleanups.o.
12273 (cleanups.o): New rule.
12274
e3d6ba5d
GB
122752014-08-29 Gary Benson <gbenson@redhat.com>
12276
12277 * utils.c (internal_vwarning): New function.
12278
7096e886
GB
122792014-08-28 Gary Benson <gbenson@redhat.com>
12280
12281 * utils.h (fatal): Remove declaration.
12282 * utils.c (fatal): Remove function.
12283
14ce3192
GB
122842014-08-28 Gary Benson <gbenson@redhat.com>
12285
12286 * tracepoint.c (gdb_agent_init): Replace fatal with
12287 perror_with_name.
12288 (initialize_tracepoint): Likewise.
12289
50278d59
GB
122902014-08-28 Gary Benson <gbenson@redhat.com>
12291
12292 * remote-utils.c (remote_prepare): Replace fatal with error.
12293
aa96c426
GB
122942014-08-28 Gary Benson <gbenson@redhat.com>
12295
12296 * linux-low.c (linux_async): Replace fatal with warning.
12297 Tidy up and return.
12298 (linux_start_non_stop): Return -1 if linux_async failed.
12299
f7160e97
GB
123002014-08-28 Gary Benson <gbenson@redhat.com>
12301
12302 * linux-x86-low.c (i386_dr_low_set_addr): Replace check with
12303 gdb_assert.
12304 (i386_dr_low_get_addr): Remove vague comment.
12305 * win32-i386-low.c (i386_dr_low_set_addr): Replace check with
12306 gdb_assert.
12307
38e08fca
GB
123082014-08-28 Gary Benson <gbenson@redhat.com>
12309
12310 * inferiors.c (get_thread_process): Replace check with gdb_assert.
12311 * linux-low.c (linux_wait_for_event_filtered): Replace fatal with
12312 internal_error.
12313 (linux_resume_one_lwp): Likewise.
12314 * linux-x86-low.c (x86_siginfo_fixup): Replace checks with
12315 gdb_assert.
12316 * mem-break.c (raw_bkpt_type_to_target_hw_bp_type): Replace fatal
12317 with internal_error.
12318 * regcache.c (get_thread_regcache): Replace check with gdb_assert.
12319 (init_register_cache): Replace fatal with gdb_assert_not_reached.
12320 (find_register_by_name): Replace fatal with internal_error.
12321 (find_regno): Likewise.
12322 * tdesc.c (init_target_desc): Replace check with gdb_assert.
12323 * thread-db.c (thread_db_create_event): Likewise.
12324 (thread_db_load_search): Likewise.
12325 (try_thread_db_load_1): Likewise.
12326 * tracepoint.c (get_jump_space_head): Replace fatal with
12327 internal_error.
12328 (claim_trampoline_space): Likewise.
12329 (have_fast_tracepoint_trampoline_buffer): Likewise.
12330 (cmd_qtstart): Likewise.
12331 (stop_tracing): Likewise.
12332 (fast_tracepoint_collecting): Likewise.
12333 (target_malloc): Likewise.
12334 (download_tracepoint): Likewise.
12335 (download_trace_state_variables): Replace check with gdb_assert.
12336 (upload_fast_traceframes): Replace fatal with internal_error.
12337
34abf635
GB
123382014-08-19 Tom Tromey <tromey@redhat.com>
12339 Gary Benson <gbenson@redhat.com>
12340
12341 * Makefile.in (SFILES): Add common/common-debug.c.
12342 (OBS): Add common-debug.o.
12343 (common-debug.o): New rule.
12344 * debug.h (debug_printf): Don't declare.
12345 * debug.c (debug_printf): Renamed and rewritten as...
12346 (debug_vprintf): New function.
12347
f6e94d78
GB
123482014-08-19 Gary Benson <gbenson@redhat.com>
12349
12350 * utils.h: Do not include print-utils.h.
12351
9239eeab
GB
123522014-08-19 Tom Tromey <tromey@redhat.com>
12353 Gary Benson <gbenson@redhat.com>
12354
12355 * server.h: Add static assertion.
12356 (gdb_byte, CORE_ADDR, LONGEST, ULONGEST): Remove.
12357
ef87c8bb
GB
123582014-08-19 Tom Tromey <tromey@redhat.com>
12359 Gary Benson <gbenson@redhat.com>
12360
12361 * Makefile.in (SFILES): Add common/errors.c.
12362 (OBS): Add errors.o.
12363 (IPA_OBS): Add errors-ipa.o.
12364 (errors.o): New rule.
12365 (errors-ipa.o): Likewise.
12366 * utils.h (perror_with_name, error, warning): Don't declare.
12367 * utils.c (warning): Renamed and rewritten as...
12368 (vwarning): New function.
12369 (error): Renamed and rewritten as...
12370 (verror): New function.
12371 (internal_error): Renamed and rewritten as...
12372 (internal_verror): New function.
12373
bb974a24
GB
123742014-08-07 Gary Benson <gbenson@redhat.com>
12375
12376 * configure.ac (AC_CHECK_HEADERS): Remove errno.h.
12377 * configure: Regenerate.
12378 * config.in: Likewise.
12379 * server.h: Do not include errno.h.
12380 * event-loop.c: Likewise.
12381 * hostio-errno.c: Likewise.
12382 * linux-low.c: Likewise.
12383 * remote-utils.c: Likewise.
12384 * spu-low.c: Likewise.
12385 * utils.c: Likewise.
12386 * gdbreplay.c: Unconditionally include errno.h.
12387
6d3d12eb
GB
123882014-08-07 Gary Benson <gbenson@redhat.com>
12389
12390 * server.h: Do not include string.h.
12391 * event-loop.c: Likewise.
12392 * linux-low.c: Likewise.
12393 * regcache.c: Likewise.
12394 * remote-utils.c: Likewise.
12395 * spu-low.c: Likewise.
12396 * utils.c: Likewise.
12397
dccbb609
GB
123982014-08-07 Gary Benson <gbenson@redhat.com>
12399
12400 * server.h: Do not include gdb_assert.h.
12401
e76df0d0
GB
124022014-08-07 Gary Benson <gbenson@redhat.com>
12403
12404 * server.h: Do not include common-utils.h.
12405
4cb9c816
GB
124062014-08-07 Gary Benson <gbenson@redhat.com>
12407
12408 * server.h: Do not include ptid.h.
12409 * notif.h: Likewise.
12410
3995eeee
GB
124112014-08-07 Gary Benson <gbenson@redhat.com>
12412
12413 * server.h: Do not include gdb_locale.h.
12414
cb9f1a9b
GB
124152014-08-07 Gary Benson <gbenson@redhat.com>
12416
12417 * server.h: Do not include gdb/signals.h.
12418 * win32-low.c: Likewise.
12419
a5fceff8
GB
124202014-08-07 Gary Benson <gbenson@redhat.com>
12421
12422 * server.h: Do not include pathmax.h.
12423
b9391142
GB
124242014-08-07 Gary Benson <gbenson@redhat.com>
12425
12426 * server.h: Do not include libiberty.h.
12427 * linux-bfin-low.c: Likewise.
12428
0e443c87
GB
124292014-08-07 Gary Benson <gbenson@redhat.com>
12430
12431 * server.h: Do not include ansidecl.h.
12432
8ebb3f56
GB
124332014-08-07 Gary Benson <gbenson@redhat.com>
12434
12435 * linux-x86-low.c: Do not include stddef.h.
12436 * lynx-ppc-low.c: Likewise.
12437 * tracepoint.c: Likewise.
12438
8980bdf6
GB
124392014-08-07 Gary Benson <gbenson@redhat.com>
12440
12441 * server.h: Do not include stdarg.h.
12442 * nto-low.c: Likewise.
12443
d7096f71
GB
124442014-08-07 Gary Benson <gbenson@redhat.com>
12445
12446 * server.h: Do not include stdlib.h.
12447 * inferiors.c: Likewise.
12448 * linux-low.c: Likewise.
12449 * regcache.c: Likewise.
12450 * spu-low.c: Likewise.
12451 * tracepoint.c: Likewise.
12452 * utils.c: Likewise.
12453
d02f550d
GB
124542014-08-07 Gary Benson <gbenson@redhat.com>
12455
12456 * server.h: Do not include stdio.h.
12457 * linux-low.c: Likewise.
12458 * remote-utils.c: Likewise.
12459 * spu-low.c: Likewise.
12460 * utils.c: Likewise.
12461 * wincecompat.c: Likewise.
12462
87f6c4e3
GB
124632014-08-06 Gary Benson <gbenson@redhat.com>
12464
12465 * regcache.c (init_register_cache): Move conditionals inside if.
12466
7089dca4
GB
124672014-08-06 Gary Benson <gbenson@redhat.com>
12468
12469 * linux-low.c (linux_supports_non_stop): Use target_is_async_p.
12470
462f517e
GB
124712014-07-31 Gary Benson <gbenson@redhat.com>
12472
12473 * ax.h: Do not include server.h.
12474 * gdbthread.h: Likewise.
12475 * lynx-low.h: Likewise.
12476 * notif.h: Likewise.
12477
976411d6
GB
124782014-07-30 Gary Benson <gbenson@redhat.com>
12479
12480 * server.h: Include common-defs.h.
12481 Do not include config.h or build-gnulib-gdbserver/config.h.
12482
d41f6d8e
GB
124832014-07-30 Gary Benson <gbenson@redhat.com>
12484
12485 * hostio-errno.c: Move server.h to top of includes list.
12486 * inferiors.c: Likewise.
12487 * linux-x86-low.c: Likewise.
12488 * notif.c: Include server.h.
12489
314c6a35
TT
124902014-07-24 Tom Tromey <tromey@redhat.com>
12491 Gary Benson <gbenson@redhat.com>
12492
12493 * server.h (CORE_ADDR): Now unsigned.
12494
69ff6be5
PA
124952014-07-16 Pedro Alves <palves@redhat.com>
12496
12497 * linux-low.c (linux_kill_one_lwp): Use kill_lwp, not kill.
12498
ce9e3fe7
PA
124992014-07-15 Pedro Alves <palves@redhat.com>
12500
12501 * linux-low.c (linux_kill_one_lwp): Save errno and work with saved
12502 copy.
12503
e76126e8
PA
125042014-07-11 Pedro Alves <palves@redhat.com>
12505
12506 * linux-low.c (kill_wait_lwp): New function, based on
12507 kill_one_lwp_callback, but use my_waitpid directly.
12508 (kill_one_lwp_callback, linux_kill): Use it.
12509
8e9db26e
PA
125102014-06-23 Pedro Alves <palves@redhat.com>
12511
12512 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR_CONTROL
12513 before setting DR0..DR3.
12514
698b3e08
GB
125152014-06-20 Gary Benson <gbenson@redhat.com>
12516
12517 * configure.ac (AC_REPLACE_FUNCS) <vasprintf, vsnprintf>: Removed.
12518 * configure: Regenerated.
12519 * config.in: Likewise.
12520
125f8a3d
GB
125212014-06-20 Gary Benson <gbenson@redhat.com>
12522
12523 * Makefile.in (SFILES): Update locations for files moved
12524 from common to nat.
12525 (object file files): Reordered.
12526
42995dbd
GB
125272014-06-20 Gary Benson <gbenson@redhat.com>
12528
12529 * i386-low.h (i386_dr_low_can_set_addr): Removed.
12530 (i386_dr_low_set_addr): Likewise.
12531 (i386_dr_low_get_addr): Likewise.
12532 (i386_dr_low_can_set_control): Likewise.
12533 (i386_dr_low_set_control): Likewise.
12534 (i386_dr_low_get_control): Likewise.
12535 (i386_dr_low_get_status): Likewise.
12536 (i386_get_debug_register_length): Likewise.
12537 * linux-x86-low.c (i386_dr_low_set_addr):
12538 Changed signature. Made static.
12539 (i386_dr_low_get_addr): Likewise.
12540 (i386_dr_low_set_control): Likewise.
12541 (i386_dr_low_get_control): Likewise.
12542 (i386_dr_low_get_status): Likewise.
12543 (i386_dr_low): New global variable.
12544 * win32-i386-low.c (i386_dr_low_set_addr):
12545 Changed signature. Made static.
12546 (i386_dr_low_get_addr): Likewise.
12547 (i386_dr_low_set_control): Likewise.
12548 (i386_dr_low_get_control): Likewise.
12549 (i386_dr_low_get_status): Likewise.
12550 (i386_dr_low): New global variable.
12551
e1d2394b
MS
125522014-06-20 Marcus Shawcroft <marcus.shawcroft@arm.com>
12553
12554 * configure.ac: Invoke. AC_CHECK_TOOL(AR, ar).
12555 * Makefile.in (AR, AR_FLAGS): Define.
12556 * configure: Regenerate.
12557
3a8ee006
GB
125582014-06-19 Gary Benson <gbenson@redhat.com>
12559
12560 * Makefile.in (i386-dregs.o): New rule.
12561 * configure.srv: Add i386-dregs.o to all targets using i386-low.o.
12562 * i386-low.c (target.h): Remove include.
12563 (TARGET_HAS_DR_LEN_8): Now in i386-dregs.c.
12564 (DR_CONTROL_SHIFT): Likewise.
12565 (DR_CONTROL_SIZE): Likewise.
12566 (DR_RW_EXECUTE): Likewise.
12567 (DR_RW_WRITE): Likewise.
12568 (DR_RW_READ): Likewise.
12569 (DR_RW_IORW): Likewise.
12570 (DR_LEN_1): Likewise.
12571 (DR_LEN_2): Likewise.
12572 (DR_LEN_4): Likewise.
12573 (DR_LEN_8): Likewise.
12574 (DR_LOCAL_ENABLE_SHIFT): Likewise.
12575 (DR_GLOBAL_ENABLE_SHIFT): Likewise.
12576 (DR_ENABLE_SIZE): Likewise.
12577 (DR_LOCAL_SLOWDOWN): Likewise.
12578 (DR_GLOBAL_SLOWDOWN): Likewise.
12579 (DR_CONTROL_RESERVED): Likewise.
12580 (I386_DR_CONTROL_MASK): Likewise.
12581 (I386_DR_VACANT): Likewise.
12582 (I386_DR_LOCAL_ENABLE): Likewise.
12583 (I386_DR_GLOBAL_ENABLE): Likewise.
12584 (I386_DR_DISABLE): Likewise.
12585 (I386_DR_SET_RW_LEN): Likewise.
12586 (I386_DR_GET_RW_LEN): Likewise.
12587 (I386_DR_WATCH_HIT): Likewise.
12588 (i386_wp_op_t): Likewise.
12589 (i386_show_dr): Likewise.
12590 (i386_length_and_rw_bits): Likewise.
12591 (i386_insert_aligned_watchpoint): Likewise.
12592 (i386_remove_aligned_watchpoint): Likewise.
12593 (i386_handle_nonaligned_watchpoint): Likewise.
12594 i386_update_inferior_debug_regs(): Likewise.
12595 (i386_dr_insert_watchpoint): Likewise.
12596 (i386_dr_remove_watchpoint): Likewise.
12597 (i386_dr_region_ok_for_watchpoint): Likewise.
12598 (i386_dr_stopped_data_address): Likewise.
12599 (i386_dr_stopped_by_watchpoint): Likewise.
12600
8f26655c
GB
126012014-06-19 Gary Benson <gbenson@redhat.com>
12602
12603 * i386-low.c (i386_dr_show): Renamed to
12604 i386_show_dr and made static. All uses updated.
12605 (i386_dr_length_and_rw_bits): Renamed to
12606 i386_length_and_rw_bits and made static.
12607 All uses updated.
12608 (i386_dr_insert_aligned_watchpoint): Renamed to
12609 i386_insert_aligned_watchpoint and made static.
12610 All uses updated.
12611 (i386_dr_remove_aligned_watchpoint): Renamed to
12612 i386_remove_aligned_watchpoint and made static.
12613 All uses updated.
12614 (i386_dr_update_inferior_debug_regs): Renamed to
12615 i386_update_inferior_debug_regs and made static.
12616 All uses updated.
12617
b9228891
GB
126182014-06-18 Gary Benson <gbenson@redhat.com>
12619
5171def3
GB
12620 * i386-low.h (i386_dr_low_can_set_addr): New macro.
12621 (i386_dr_low_can_set_control): Likewise.
12622 (i386_get_debug_register_length): Likewise.
12623 * i386-low.c (i386_dr_low_can_set_addr): Now in i386-low.h.
12624 (i386_dr_low_can_set_control): Likewise.
12625 (i386_get_debug_register_length): Likewise.
12626
126272014-06-17 Gary Benson <gbenson@redhat.com>
12628
b9228891
GB
12629 * i386-low.h (i386-dregs.h): New include.
12630 (DR_FIRSTADDR): Now in i386-dregs.h.
12631 (DR_LASTADDR): Likewise.
12632 (DR_NADDR): Likewise.
12633 (DR_STATUS): Likewise.
12634 (DR_CONTROL): Likewise.
12635 (i386_debug_reg_state): Likewise.
12636 (i386_dr_insert_watchpoint): Likewise.
12637 (i386_dr_remove_watchpoint): Likewise.
12638 (i386_dr_region_ok_for_watchpoint): Likewise.
12639 (i386_dr_stopped_data_address): Likewise.
12640 (i386_dr_stopped_by_watchpoint): Likewise.
12641 * i386-low.c (ALL_DEBUG_REGISTERS): Likewise.
12642
4be83cc2
GB
126432014-06-18 Gary Benson <gbenson@redhat.com>
12644
12645 * i386-low.h (i386_low_insert_watchpoint): Renamed to
12646 i386_dr_insert_watchpoint.
12647 (i386_low_remove_watchpoint): Renamed to
12648 i386_dr_remove_watchpoint.
12649 (i386_low_region_ok_for_watchpoint): Renamed to
12650 i386_dr_region_ok_for_watchpoint.
12651 (i386_low_stopped_data_address): Renamed to
12652 i386_dr_stopped_data_address.
12653 (i386_low_stopped_by_watchpoint): Renamed to
12654 i386_dr_stopped_by_watchpoint.
12655 * i386-low.c (i386_show_dr): Renamed to
12656 i386_dr_show and made nonstatic. All uses updated.
12657 (i386_length_and_rw_bits): Renamed to
12658 i386_dr_length_and_rw_bits and made nonstatic.
12659 All uses updated.
12660 (i386_insert_aligned_watchpoint): Renamed to
12661 i386_dr_insert_aligned_watchpoint and made nonstatic.
12662 All uses updated.
12663 (i386_remove_aligned_watchpoint): Renamed to
12664 i386_dr_remove_aligned_watchpoint and made nonstatic.
12665 All uses updated.
12666 (i386_update_inferior_debug_regs): Renamed to
12667 i386_dr_update_inferior_debug_regs and made nonstatic.
12668 All uses updated.
12669 (i386_low_insert_watchpoint): Renamed to
12670 i386_dr_insert_watchpoint. All uses updated.
12671 (i386_low_remove_watchpoint): Renamed to
12672 i386_dr_remove_watchpoint. All uses updated.
12673 (i386_low_region_ok_for_watchpoint): Renamed to
12674 i386_dr_region_ok_for_watchpoint. All uses updated.
12675 (i386_low_stopped_data_address): Renamed to
12676 i386_dr_stopped_data_address. All uses updated.
12677 (i386_low_stopped_by_watchpoint): Renamed to
12678 i386_dr_stopped_by_watchpoint. All uses updated.
12679
131aa0d4
GB
126802014-06-18 Gary Benson <gbenson@redhat.com>
12681
12682 * i386-low.c (i386_dr_low_can_set_addr): New macro.
12683 (i386_dr_low_can_set_control): Likewise.
12684 (i386_insert_aligned_watchpoint): New check.
12685
d9305f7f
GB
126862014-06-18 Gary Benson <gbenson@redhat.com>
12687
12688 * i386-low.c (i386_update_inferior_debug_regs) <inf_state>:
12689 Renamed to state.
12690
e927c9fc
GB
126912014-06-18 Gary Benson <gbenson@redhat.com>
12692
12693 * i386-low.c (i386_length_and_rw_bits): Use internal_error
12694 instead of fatal and error.
12695 (i386_handle_nonaligned_watchpoint): Likewise.
12696
1b6d4134
GB
126972014-06-18 Gary Benson <gbenson@redhat.com>
12698
12699 * i386-low.c (i386_get_debug_register_length): New macro.
12700 (TARGET_HAS_DR_LEN_8): Remove conditional. Use above macro.
12701 (i386_show_dr): Use debug_printf instead of fprintf. Use
12702 phex to format values.
12703
6e62758f
GB
127042014-06-18 Gary Benson <gbenson@redhat.com>
12705
12706 * i386-low.h: Comment changes.
12707 * i386-low.c: Likewise.
12708
fc6e2f03
GB
127092014-06-18 Gary Benson <gbenson@redhat.com>
12710
12711 * i386-low.c: Whitespace changes.
12712
f9d1eeed
TT
127132014-06-12 Tom Tromey <tromey@redhat.com>
12714
12715 * utils.c (freeargv): Remove.
12716
0b04e523
TT
127172014-06-12 Tom Tromey <tromey@redhat.com>
12718
12719 * debug.c (debug_printf): Remove HAVE_GETTIMEOFDAY checks.
12720 * server.c (monitor_show_help): Remove HAVE_GETTIMEOFDAY check.
12721 (parse_debug_format_options): Likewise.
12722 (gdbserver_usage): Likewise.
12723 * Makefile.in (LIBIBERTY_BUILDDIR, LIBIBERTY): New variables.
12724 (SUBDIRS, REQUIRED_SUBDIRS): Add libiberty.
12725 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Depend on and link
12726 against libiberty.
12727 ($(LIBGNU)): Depend on libiberty.
12728 (all-lib): Recurse into all subdirs.
12729 (install-only): Invoke "install" target in subdirs.
12730 (vasprintf.o, vsnprintf.o, safe-ctype.o, lbasename.o): Remove
12731 targets.
12732 * configure: Rebuild.
12733 * configure.ac: Add ACX_CONFIGURE_DIR for libiberty. Don't check
12734 for vasprintf, vsnprintf, or gettimeofday.
12735 * configure.srv: Don't add safe-ctype.o or lbasename.o to
12736 srv_tgtobj.
12737
270c9937
JB
127382014-06-05 Joel Brobecker <brobecker@adacore.com>
12739
12740 * development.sh: Delete.
12741 * Makefile.in (config.status): Adjust dependency on development.sh.
12742 * configure.ac: Adjust development.sh source call.
12743 * configure: Regenerate.
12744
0a261ed8
PA
127452014-06-02 Pedro Alves <palves@redhat.com>
12746
12747 * ax.c (gdb_free_agent_expr): New function.
12748 * ax.h (gdb_free_agent_expr): New declaration.
12749 * mem-break.c (delete_gdb_breakpoint_1): Also clear the commands
12750 list.
12751 (clear_breakpoint_conditions, clear_breakpoint_commands): Make
12752 static.
12753 (clear_breakpoint_conditions_and_commands): New function.
12754 * mem-break.h (clear_breakpoint_conditions): Delete declaration.
12755 (clear_breakpoint_conditions_and_commands): New declaration.
12756
e9dae05e
RR
127572014-05-23 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
12758
12759 * linux-aarch64-low.c (asm/ptrace.h): Include.
12760
5876f503
JK
127612014-05-21 Jan Kratochvil <jan.kratochvil@redhat.com>
12762
12763 Fix TLS access for -static -pthread.
12764 * gdbserver/thread-db.c (struct thread_db): Add td_thr_tlsbase_p.
12765 (thread_db_get_tls_address): Call it if LOAD_MODULE is zero.
12766 (thread_db_load_search, try_thread_db_load_1): Initialize it.
12767
802e8e6d
PA
127682014-05-20 Pedro Alves <palves@redhat.com>
12769
12770 * linux-aarch64-low.c (aarch64_insert_point)
12771 (aarch64_remove_point): No longer check whether the type is
12772 supported here. Adjust to new interface.
12773 (the_low_target): Install aarch64_supports_z_point_type as
12774 supports_z_point_type method.
12775 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type): New function.
12776 (arm_linux_hw_point_initialize): Take an enum raw_bkpt_type
12777 instead of a Z packet char. Adjust.
12778 (arm_supports_z_point_type): New function.
12779 (arm_insert_point, arm_remove_point): Adjust to new interface.
12780 (the_low_target): Install arm_supports_z_point_type.
12781 * linux-crisv32-low.c (cris_supports_z_point_type): New function.
12782 (cris_insert_point, cris_remove_point): Adjust to new interface.
12783 Don't check whether the type is supported here.
12784 (the_low_target): Install cris_supports_z_point_type.
12785 * linux-low.c (linux_supports_z_point_type): New function.
12786 (linux_insert_point, linux_remove_point): Adjust to new interface.
12787 * linux-low.h (struct linux_target_ops) <insert_point,
12788 remove_point>: Take an enum raw_bkpt_type instead of a char. Add
12789 raw_breakpoint pointer parameter.
12790 <supports_z_point_type>: New method.
12791 * linux-mips-low.c (mips_supports_z_point_type): New function.
12792 (mips_insert_point, mips_remove_point): Adjust to new interface.
12793 Use mips_supports_z_point_type.
12794 (the_low_target): Install mips_supports_z_point_type.
12795 * linux-ppc-low.c (the_low_target): Install NULL as
12796 supports_z_point_type method.
12797 * linux-s390-low.c (the_low_target): Install NULL as
12798 supports_z_point_type method.
12799 * linux-sparc-low.c (the_low_target): Install NULL as
12800 supports_z_point_type method.
12801 * linux-x86-low.c (x86_supports_z_point_type): New function.
12802 (x86_insert_point): Adjust to new insert_point interface. Use
12803 insert_memory_breakpoint. Adjust to new
12804 i386_low_insert_watchpoint interface.
12805 (x86_remove_point): Adjust to remove_point interface. Use
12806 remove_memory_breakpoint. Adjust to new
12807 i386_low_remove_watchpoint interface.
12808 (the_low_target): Install x86_supports_z_point_type.
12809 * lynx-low.c (lynx_target_ops): Install NULL as
12810 supports_z_point_type callback.
12811 * nto-low.c (nto_supports_z_point_type): New.
12812 (nto_insert_point, nto_remove_point): Adjust to new interface.
12813 (nto_target_ops): Install nto_supports_z_point_type.
12814 * mem-break.c: Adjust intro comment.
12815 (struct raw_breakpoint) <raw_type, size>: New fields.
12816 <inserted>: Update comment.
12817 <shlib_disabled>: Delete field.
12818 (enum bkpt_type) <gdb_breakpoint>: Delete value.
12819 <gdb_breakpoint_Z0, gdb_breakpoint_Z1, gdb_breakpoint_Z2,
12820 gdb_breakpoint_Z3, gdb_breakpoint_Z4>: New values.
12821 (raw_bkpt_type_to_target_hw_bp_type): New function.
12822 (find_enabled_raw_code_breakpoint_at): New function.
12823 (find_raw_breakpoint_at): New type and size parameters. Use them.
12824 (insert_memory_breakpoint): New function, based off
12825 set_raw_breakpoint_at.
12826 (remove_memory_breakpoint): New function.
12827 (set_raw_breakpoint_at): Reimplement.
12828 (set_breakpoint): New, based on set_breakpoint_at.
12829 (set_breakpoint_at): Reimplement.
12830 (delete_raw_breakpoint): Go through the_target->remove_point
12831 instead of assuming memory breakpoints.
12832 (find_gdb_breakpoint_at): Delete.
12833 (Z_packet_to_bkpt_type, Z_packet_to_raw_bkpt_type): New functions.
12834 (find_gdb_breakpoint): New function.
12835 (set_gdb_breakpoint_at): Delete.
12836 (z_type_supported): New function.
12837 (set_gdb_breakpoint_1): New function, loosely based off
12838 set_gdb_breakpoint_at.
12839 (check_gdb_bp_preconditions, set_gdb_breakpoint): New functions.
12840 (delete_gdb_breakpoint_at): Delete.
12841 (delete_gdb_breakpoint_1): New function, loosely based off
12842 delete_gdb_breakpoint_at.
12843 (delete_gdb_breakpoint): New function.
12844 (clear_gdb_breakpoint_conditions): Rename to ...
12845 (clear_breakpoint_conditions): ... this. Don't handle a NULL
12846 breakpoint.
12847 (add_condition_to_breakpoint): Make static.
12848 (add_breakpoint_condition): Take a struct breakpoint pointer
12849 instead of an address. Adjust.
12850 (gdb_condition_true_at_breakpoint): Rename to ...
12851 (gdb_condition_true_at_breakpoint_z_type): ... this, and add
12852 z_type parameter.
12853 (gdb_condition_true_at_breakpoint): Reimplement.
12854 (add_breakpoint_commands): Take a struct breakpoint pointer
12855 instead of an address. Adjust.
12856 (gdb_no_commands_at_breakpoint): Rename to ...
12857 (gdb_no_commands_at_breakpoint_z_type): ... this. Add z_type
12858 parameter. Return true if no breakpoint was found. Change debug
12859 output.
12860 (gdb_no_commands_at_breakpoint): Reimplement.
12861 (run_breakpoint_commands): Rename to ...
12862 (run_breakpoint_commands_z_type): ... this. Add z_type parameter,
12863 and change return type to boolean.
12864 (run_breakpoint_commands): New function.
12865 (gdb_breakpoint_here): Also check for Z1 breakpoints.
12866 (uninsert_raw_breakpoint): Don't try to reinsert a disabled
12867 breakpoint. Go through the_target->remove_point instead of
12868 assuming memory breakpoint.
12869 (uninsert_breakpoints_at, uninsert_all_breakpoints): Uninsert
12870 software and hardware breakpoints.
12871 (reinsert_raw_breakpoint): Go through the_target->insert_point
12872 instead of assuming memory breakpoint.
12873 (reinsert_breakpoints_at, reinsert_all_breakpoints): Reinsert
12874 software and hardware breakpoints.
12875 (check_breakpoints, breakpoint_here, breakpoint_inserted_here):
12876 Check both software and hardware breakpoints.
12877 (validate_inserted_breakpoint): Assert the breakpoint is a
12878 software breakpoint. Set the inserted flag to -1 instead of
12879 setting shlib_disabled.
12880 (delete_disabled_breakpoints): Adjust.
12881 (validate_breakpoints): Only validate software breakpoints.
12882 Adjust to inserted flag change.
12883 (check_mem_read, check_mem_write): Skip breakpoint types other
12884 than software breakpoints. Adjust to inserted flag change.
12885 * mem-break.h (enum raw_bkpt_type): New enum.
12886 (raw_breakpoint, struct process_info): Forward declare.
12887 (Z_packet_to_target_hw_bp_type): Delete declaration.
12888 (raw_bkpt_type_to_target_hw_bp_type, Z_packet_to_raw_bkpt_type)
12889 (set_gdb_breakpoint, delete_gdb_breakpoint)
12890 (clear_breakpoint_conditions): New declarations.
12891 (set_gdb_breakpoint_at, clear_gdb_breakpoint_conditions): Delete.
12892 (breakpoint_inserted_here): Update comment.
12893 (add_breakpoint_condition, add_breakpoint_commands): Replace
12894 address parameter with a breakpoint pointer parameter.
12895 (gdb_breakpoint_here): Update comment.
12896 (delete_gdb_breakpoint_at): Delete.
12897 (insert_memory_breakpoint, remove_memory_breakpoint): Declare.
12898 * server.c (process_point_options): Take a struct breakpoint
12899 pointer instead of an address. Adjust.
12900 (process_serial_event) <Z/z packets>: Use set_gdb_breakpoint and
12901 delete_gdb_breakpoint.
12902 * spu-low.c (spu_target_ops): Install NULL as
12903 supports_z_point_type method.
12904 * target.h: Include mem-break.h.
12905 (struct target_ops) <prepare_to_access_memory>: Update comment.
12906 <supports_z_point_type>: New field.
12907 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
12908 instead of a char. Also take a raw breakpoint pointer.
12909 * win32-arm-low.c (the_low_target): Install NULL as
12910 supports_z_point_type.
12911 * win32-i386-low.c (i386_supports_z_point_type): New function.
12912 (i386_insert_point, i386_remove_point): Adjust to new interface.
12913 (the_low_target): Install i386_supports_z_point_type.
12914 * win32-low.c (win32_supports_z_point_type): New function.
12915 (win32_insert_point, win32_remove_point): Adjust to new interface.
12916 (win32_target_ops): Install win32_supports_z_point_type.
12917 * win32-low.h (struct win32_target_ops):
12918 <supports_z_point_type>: New method.
12919 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
12920 instead of a char. Also take a raw breakpoint pointer.
12921
932539e3
PA
129222014-05-20 Pedro Alves <palves@redhat.com>
12923
12924 * mem-break.h: Include break-common.h.
12925 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
12926 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): New defines.
12927 (Z_packet_to_target_hw_bp_type): New declaration.
12928 * mem-break.c (Z_packet_to_target_hw_bp_type): New function.
12929 * i386-low.c (Z_PACKET_HW_BP, Z_PACKET_WRITE_WP, Z_PACKET_READ_WP)
12930 (Z_PACKET_ACCESS_WP): Delete macros.
12931 (Z_packet_to_hw_type): Delete function.
12932 * i386-low.h: Don't include break-common.h here.
12933 (Z_packet_to_hw_type): Delete declaration.
12934 * linux-x86-low.c (x86_insert_point, x86_insert_point): Call
12935 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
12936 * win32-i386-low.c (i386_insert_point, i386_remove_point): Call
12937 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
12938 * linux-aarch64-low.c: Don't include break-common.h here.
12939 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
12940 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): Delete macros.
12941 (Z_packet_to_target_hw_bp_type): Delete function.
12942 * linux-mips-low.c (rsp_bp_type_to_target_hw_bp_type): Delete
12943 function.
12944 (mips_insert_point, mips_remove_point): Use
12945 Z_packet_to_target_hw_bp_type.
12946
4ff0d3d8
PA
129472014-05-20 Pedro Alves <palves@redhat.com>
12948
12949 * linux-aarch64-low.c: Include break-common.h.
12950 (enum target_point_type): Delete.
12951 (Z_packet_to_point_type): Rename to ...
12952 (Z_packet_to_target_hw_bp_type): ... this, and return a
12953 target_hw_bp_type instead.
12954 (aarch64_show_debug_reg_state): Take an enum target_hw_bp_type
12955 instead of an enum target_point_type.
12956 (aarch64_point_encode_ctrl_reg): Likewise. Compute type mask from
12957 breakpoint type.
12958 (aarch64_dr_state_insert_one_point)
12959 (aarch64_dr_state_remove_one_point, aarch64_handle_breakpoint)
12960 (aarch64_handle_aligned_watchpoint)
12961 (aarch64_handle_unaligned_watchpoint, aarch64_handle_watchpoint):
12962 Take an enum target_hw_bp_type instead of an enum
12963 target_point_type.
12964 (aarch64_supports_z_point_type): New function.
12965 (aarch64_insert_point, aarch64_remove_point): Use it. Adjust to
12966 use Z_packet_to_target_hw_bp_type.
12967
786dc519
JB
129682014-05-20 Joel Brobecker <brobecker@adacore.com>
12969
12970 * configure.ac: Only use -Werror by default when DEVELOPMENT
12971 is true.
12972 * configure: Regenerate.
12973
9e0aa64f
JK
129742014-05-19 Jan Kratochvil <jan.kratochvil@redhat.com>
12975
12976 Fix gdbserver qGetTLSAddr for x86_64 -m32.
12977 * linux-x86-low.c (X86_64_USER_REGS): New.
12978 (x86_fill_gregset): Call memset for BUF first in x86_64 -m32 case.
12979
2b577b92
YQ
129802014-04-28 Yao Qi <yao@codesourcery.com>
12981
12982 * Makefile.in (i386-avx512.c): Fix the typo of generated file
12983 name.
12984
94611da2
PA
129852014-04-25 Pedro Alves <palves@redhat.com>
12986
12987 PR server/16255
12988 * linux-low.c (linux_attach_fail_reason_string): New function.
12989 (linux_attach_lwp): Delete.
12990 (linux_attach_lwp_1): Rename to ...
12991 (linux_attach_lwp): ... this. Take a ptid instead of a pid as
12992 argument. Remove "initial" parameter. Return int instead of
12993 void. Don't error or warn here.
12994 (linux_attach): Adjust to call linux_attach_lwp. Call error on
12995 failure to attach to the tgid. Call warning when failing to
12996 attach to an lwp.
12997 * linux-low.h (linux_attach_lwp): Take a ptid instead of a pid as
12998 argument. Remove "initial" parameter. Return int instead of
12999 void. Don't error or warn here.
13000 (linux_attach_fail_reason_string): New declaration.
13001 * thread-db.c (attach_thread): Adjust to linux_attach_lwp's
13002 interface change. Use linux_attach_fail_reason_string.
13003
01f9f808
MS
130042014-04-24 Michael Sturm <michael.sturm@mintel.com>
13005 Walfred Tedeschi <walfred.tedeschi@intel.com>
13006
13007 * Makefile.in: Added rules to handle new files
13008 i386-avx512.c i386-avx512-linux.c amd64-avx512.c
13009 amd64-avx512-linux.c x32-avx512.c x32-avx512-linux.c.
13010 * configure.srv (srv_i386_regobj): Add i386-avx512.o.
13011 (srv_i386_linux_regobj): Add i386-avx512-linux.o.
13012 (srv_amd64_regobj): Add amd64-avx512.o and x32-avx512.o.
13013 (srv_amd64_linux_regobj): Add amd64-avx512-linux.o and
13014 x32-avx512-linux.o.
13015 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx512.xml.
13016 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx512.xml.
13017 (srv_amd64_xmlfiles): Add i386/amd64-avx512.xml and
13018 i386/x32-avx512.xml.
13019 (srv_i386_linux_xmlfiles): Add i386/i386-avx512-linux.xml.
13020 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx512-linux.xml and
13021 i386/x32-avx512-linux.xml.
13022 * i387-fp.c (num_avx512_k_registers): New constant for number
13023 of K registers.
13024 (num_avx512_zmmh_low_registers): New constant for number of
13025 lower ZMM registers (0-15).
13026 (num_avx512_zmmh_high_registers): New constant for number of
13027 higher ZMM registers (16-31).
13028 (num_avx512_ymmh_registers): New contant for number of higher
13029 YMM registers (ymm16-31 added by avx521 on x86_64).
13030 (num_avx512_xmm_registers): New constant for number of higher
13031 XMM registers (xmm16-31 added by AVX512 on x86_64).
13032 (struct i387_xsave): Add space for AVX512 registers.
13033 (i387_cache_to_xsave): Change raw buffer size to 64 characters.
13034 Add code to handle AVX512 registers.
13035 (i387_xsave_to_cache): Add code to handle AVX512 registers.
13036 * linux-x86-low.c (init_registers_amd64_avx512_linux): New
13037 prototypei from generated file.
13038 (tdesc_amd64_avx512_linux): Likewise.
13039 (init_registers_x32_avx512_linux): Likewise.
13040 (tdesc_x32_avx512_linux): Likewise.
13041 (init_registers_i386_avx512_linux): Likewise.
13042 (tdesc_i386_avx512_linux): Likewise.
13043 (x86_64_regmap): Add AVX512 registers.
13044 (x86_linux_read_description): Add code to handle AVX512 XSTATE
13045 mask.
13046 (initialize_low_arch): Add code to initialize AVX512 registers.
13047
51aa91f9
PA
130482014-04-23 Pedro Alves <palves@redhat.com>
13049
13050 * mem-break.c (find_gdb_breakpoint_at): Make static.
13051 * mem-break.h (find_gdb_breakpoint_at): Delete declaration.
13052
a4165e94
PA
130532014-04-23 Pedro Alves <palves@redhat.com>
13054
13055 * i386-low.c: Don't include break-common.h here.
13056 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
13057 prototype to take target_hw_bp_type as argument instead of a Z
13058 packet char.
13059 * i386-low.h: Include break-common.h here.
13060 (Z_packet_to_hw_type): Declare.
13061 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
13062 prototypes.
13063 * linux-x86-low.c (x86_insert_point): Convert the packet number to
13064 a target_hw_bp_type before calling i386_low_insert_watchpoint.
13065 (x86_remove_point): Convert the packet number to a
13066 target_hw_bp_type before calling i386_low_remove_watchpoint.
13067 * win32-i386-low.c (i386_insert_point): Convert the packet number
13068 to a target_hw_bp_type before calling i386_low_insert_watchpoint.
13069 (i386_remove_point): Convert the packet number to a
13070 target_hw_bp_type before calling i386_low_remove_watchpoint.
13071
b8acf843
PA
130722014-04-23 Pedro Alves <palves@redhat.com>
13073
13074 * utils.h (perror_with_name): Add ATTRIBUTE_NORETURN.
13075
d708bcd1
PA
130762014-04-10 Pedro Alves <palves@redhat.com>
13077
13078 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
13079 Check if the condition or command is NULL before checking if the
13080 breakpoint is known. On success, return true.
13081 * mem-break.h (add_breakpoint_condition): Document return.
13082 (add_breakpoint_commands): Add describing comment.
13083 * server.c (skip_to_semicolon): New function.
13084 (process_point_options): Use it.
13085
2eec7d5b
PA
130862014-04-09 Pedro Alves <palves@redhat.com>
13087
13088 * linux-low.c (linux_read_loadmap): Pass current_inferior directly
13089 to lwpid_of.
13090
fa96cb38
PA
130912014-02-27 Pedro Alves <palves@redhat.com>
13092
13093 PR 12702
13094 * inferiors.h (A_I_NEXT, ALL_INFERIORS_TYPE, ALL_PROCESSES): New
13095 macros.
13096 * linux-low.c (delete_lwp, handle_extended_wait): Add debug
13097 output.
13098 (last_thread_of_process_p): Take a PID argument instead of a
13099 thread pointer.
13100 (linux_wait_for_lwp): Delete.
13101 (num_lwps, check_zombie_leaders, not_stopped_callback): New
13102 functions.
13103 (linux_low_filter_event): New function, party factored out from
13104 linux_wait_for_event.
13105 (linux_wait_for_event): Rename to ...
13106 (linux_wait_for_event_filtered): ... this. Add new filter ptid
13107 argument. Partly rewrite. Always use waitpid(-1, WNOHANG) and
13108 sigsuspend. Check for zombie leaders.
13109 (linux_wait_for_event): Reimplement as wrapper around
13110 linux_wait_for_event_filtered.
13111 (linux_wait_1): Handle TARGET_WAITKIND_NO_RESUMED. Assume that if
13112 a normal or signal exit is seen, it's the whole process exiting.
13113 (wait_for_sigstop): No longer a for_each_inferior callback.
13114 Rewrite on top of linux_wait_for_event_filtered.
13115 (stop_all_lwps): Call wait_for_sigstop directly.
13116 * server.c (resume, handle_target_event): Handle
13117 TARGET_WAITKIND_NO_RESUMED.
13118
d763de10
JB
131192014-02-26 Joel Brobecker <brobecker@adacore.com>
13120
13121 * win32-low.c (psapi_get_dll_name,
13122 * win32_CreateToolhelp32Snapshot): Delete.
13123 (win32_CreateToolhelp32Snapshot, win32_Module32First)
13124 (win32_Module32Next, load_toolhelp, toolhelp_get_dll_name):
13125 Delete.
13126 (handle_load_dll): Add function description.
13127 Remove code using psapi_get_dll_name and toolhelp_get_dll_name.
13128
850a0f76
JB
131292014-02-26 Joel Brobecker <brobecker@adacore.com>
13130
13131 * win32-low.c (win32_add_one_solib): Add 0x1000 to load_addr.
13132 Add comment.
13133 (win32_add_all_dlls): Remove 0x1000 offset applied to DLL
13134 base address when calling win32_add_one_solib.
13135 (handle_load_dll): Delete local variable load_addr.
13136 Remove 0x1000 offset applied to DLL base address when calling
13137 win32_add_one_solib.
13138 (handle_unload_dll): Add comment.
13139
f25b3fc3
JB
131402014-02-26 Joel Brobecker <brobecker@adacore.com>
13141
13142 * win32-low.c (win32_add_all_dlls): Renames
13143 win32_ensure_ntdll_loaded. Rewrite function documentation.
13144 Adjust implementation to always load all DLLs.
13145 Add 0x1000 offset to DLL base address when calling
13146 win32_add_one_solib.
13147 (child_initialization_done): New static global.
13148 (do_initial_child_stuff): Set child_initialization_done to
13149 zero during child initialization, and 1 after. Replace call
13150 to win32_ensure_ntdll_loaded by call to win32_add_all_dlls.
13151 Add comment.
13152 (match_dll_by_basename, dll_is_loaded_by_basename): Delete.
13153 (handle_unload_dll): Add function documentation.
13154 (get_child_debug_event): Ignore load and unload DLL events
13155 during child initialization.
13156
d86d4aaf
DE
131572014-02-20 Doug Evans <dje@google.com>
13158
3bc32da3 13159 Remove global all_lwps.
d86d4aaf
DE
13160 * inferiors.h (ptid_of): Move here from linux-low.h.
13161 (pid_of, lwpid_of): Ditto.
13162 * linux-aarch64-low.c (debug_reg_change_callback): Update, "entry"
13163 parameter is a struct thread_info * now.
13164 (aarch64_notify_debug_reg_change): Fetch pid from current_inferior
13165 directly. Pass &all_threads to find_inferior instead of &all_lwps.
13166 (aarch64_stopped_data_address): Fetch lwpid from current_inferior
13167 directly.
13168 (aarch64_linux_prepare_to_resume): Fetch ptid from thread.
13169 (aarch64_arch_setup): Fetch lwpid from current_inferior directly.
13170 * linux-arm-low.c (update_registers_callback): Update, "entry"
13171 parameter is a struct thread_info * now.
13172 Fetch lwpid from current_inferior directly.
13173 (arm_insert_point): Pass &all_threads to find_inferior instead of
13174 &all_lwps.
13175 (arm_remove_point): Ditto.
13176 (arm_stopped_by_watchpoint): Fetch lwp from current_inferior.
13177 (arm_prepare_to_resume): Fetch pid from thread.
13178 (arm_read_description): Fetch lwpid from current_inferior directly.
13179 * linux-low.c (all_lwps): Delete.
13180 (delete_lwp): Delete call to remove_inferior.
13181 (handle_extended_wait): Fetch lwpid from thread.
13182 (add_lwp): Don't set lwp->entry.id. Remove call to
13183 add_inferior_to_list.
13184 (linux_attach_lwp_1): Fetch pid from current_inferior directly.
13185 (linux_kill_one_lwp): Fetch ptid,lwpid from thread.
13186 (kill_one_lwp_callback): Ditto.
13187 (linux_kill): Don't dereference NULL pointer.
13188 Fetch ptid,lwpid from thread.
13189 (get_detach_signal): Fetch ptid from thread.
13190 (linux_detach_one_lwp): Fetch ptid,lwpid from thread.
13191 Simplify call to regcache_invalidate_thread.
13192 (delete_lwp_callback): Update, "entry" parameter is a
13193 struct thread_info * now. Fetch pid from thread.
13194 (linux_mourn): Pass &all_threads to find_inferior instead of &all_lwps.
13195 (status_pending_p_callback): Update, "entry" parameter is a
13196 struct thread_info * now. Fetch ptid from thread.
13197 (find_lwp_pid): Update, "entry" parameter is a
13198 struct thread_info * now.
13199 (linux_wait_for_lwp): Fetch pid from thread.
13200 (linux_fast_tracepoint_collecting): Fetch lwpid from thread.
13201 (maybe_move_out_of_jump_pad): Fetch lwpid from current_inferior.
13202 (enqueue_one_deferred_signal): Fetch lwpid from thread.
13203 (dequeue_one_deferred_signal): Ditto.
13204 (cancel_breakpoint): Fetch ptid from current_inferior.
13205 (linux_wait_for_event): Pass &all_threads to find_inferior,
13206 not &all_lwps. Fetch ptid, lwpid from thread.
13207 (count_events_callback): Update, "entry" parameter is a
13208 struct thread_info * now.
13209 (select_singlestep_lwp_callback): Ditto.
13210 (select_event_lwp_callback): Ditto.
13211 (cancel_breakpoints_callback): Ditto.
13212 (linux_cancel_breakpoints): Pass &all_threads to find_inferior,
13213 not &all_lwps.
13214 (select_event_lwp): Ditto. Fetch ptid from event_thread.
13215 (unsuspend_one_lwp): Update, "entry" parameter is a
13216 struct thread_info * now.
13217 (unsuspend_all_lwps): Pass &all_threads to find_inferior,
13218 not &all_lwps.
13219 (linux_stabilize_threads): Ditto. And for for_each_inferior.
13220 Fetch lwpid from thread, not lwp.
13221 (linux_wait_1): Fetch ptid, lwpid from current_inferior.
13222 Pass &all_threads to find_inferior, not &all_lwps.
13223 (send_sigstop): Fetch lwpid from thread, not lwp.
13224 (send_sigstop_callback): Update, "entry" parameter is a
13225 struct thread_info * now.
13226 (suspend_and_send_sigstop_callback): Ditto.
13227 (wait_for_sigstop): Ditto. Fetch ptid, lwpid from thread, lwp.
13228 (stuck_in_jump_pad_callback): Update, "entry" parameter is a
13229 struct thread_info * now.
13230 (move_out_of_jump_pad_callback): Ditto. Fetch ptid, lwpid
13231 from thread, lwp.
13232 (lwp_running): Update, "entry" parameter is a
13233 struct thread_info * now.
13234 (stop_all_lwps): Fetch ptid from thread.
13235 Pass &all_threads to find_inferior, for_each_inferior, not &all_lwps.
13236 (linux_resume_one_lwp): Fetch lwpid from thread.
13237 (linux_set_resume_request): Update, "entry" parameter is a
13238 struct thread_info * now. Fetch pid, lwpid from thread.
13239 (resume_status_pending_p): Update, "entry" parameter is a
13240 struct thread_info * now.
13241 (need_step_over_p): Ditto. Fetch lwpid from thread.
13242 (start_step_over): Fetch lwpid from thread.
13243 (linux_resume_one_thread): Update, "entry" parameter is a
13244 struct thread_info * now. Fetch lwpid from thread.
13245 (linux_resume): Pass &all_threads to find_inferior, not &all_lwps.
13246 (proceed_one_lwp): Update, "entry" parameter is a
13247 struct thread_info * now. Fetch lwpid from thread.
13248 (unsuspend_and_proceed_one_lwp): Update, "entry" parameter is a
13249 struct thread_info * now.
13250 (proceed_all_lwps): Pass &all_threads to find_inferior, not &all_lwps.
13251 (unstop_all_lwps): Ditto. Fetch lwpid from thread.
13252 (regsets_fetch_inferior_registers): Fetch lwpid from current_inferior
13253 directly.
13254 (regsets_store_inferior_registers): Ditto.
13255 (fetch_register, store_register): Ditto.
13256 (linux_read_memory, linux_write_memory): Ditto.
13257 (linux_request_interrupt): Ditto.
13258 (linux_read_auxv): Ditto.
13259 (linux_xfer_siginfo): Ditto.
13260 (linux_qxfer_spu): Ditto.
13261 (linux_qxfer_libraries_svr4): Ditto.
13262 * linux-low.h (ptid_of, pid_of, lwpid_of): Delete,
13263 moved to inferiors.h.
13264 (get_lwp): Delete.
13265 (get_thread_lwp): Update.
13266 (struct lwp_info): Delete member "entry". Simplify comment for
13267 member "thread".
13268 (all_lwps): Delete.
13269 * linux-mips-low.c (mips_read_description): Fetch lwpid from
13270 current_inferior directly.
13271 (update_watch_registers_callback): Update, "entry" parameter is a
13272 struct thread_info * now. Fetch pid from thread.
13273 (mips_linux_prepare_to_resume): Fetch ptid from thread.
13274 (mips_insert_point): Fetch lwpid from current_inferior.
13275 Pass &all_threads to find_inferior, not &all_lwps.
13276 (mips_remove_point): Pass &all_threads to find_inferior, not &all_lwps.
13277 (mips_stopped_by_watchpoint): Fetch lwpid from current_inferior
13278 directly.
13279 (mips_stopped_data_address): Ditto.
13280 * linux-s390-low.c (s390_arch_setup): Fetch pid from current_inferior
13281 directly.
13282 * linux-tile-low.c (tile_arch_setup): Ditto.
13283 * linux-x86-low.c (x86_get_thread_area): Fetch lwpid from thread.
13284 (update_debug_registers_callback): Update, "entry" parameter is a
13285 struct thread_info * now. Fetch pid from thread.
13286 (i386_dr_low_set_addr): Fetch pid from current_inferior directly.
13287 Pass &all_threads to find_inferior, not &all_lwps.
13288 (i386_dr_low_get_addr): Fetch ptid from current_inferior directly.
13289 (i386_dr_low_set_control): Fetch pid from current_inferior directly.
13290 Pass &all_threads to find_inferior, not &all_lwps.
13291 (i386_dr_low_get_control): Fetch ptid from current_inferior directly.
13292 (i386_dr_low_get_status): Ditto.
13293 (x86_linux_prepare_to_resume): Fetch ptid from thread.
13294 (x86_siginfo_fixup): Fetch lwpid from current_inferior directly.
13295 (x86_linux_read_description): Ditto.
13296 * proc-service.c (ps_getpid): Fetch pid from current_inferior directly.
13297
3b8361aa
DE
132982014-02-20 Doug Evans <dje@google.com>
13299
13300 * inferiors.c (get_first_inferior): Fix buglet.
13301
f7667f0d
DE
133022014-02-19 Doug Evans <dje@google.com>
13303
13304 * gdbthread.h (add_thread): Change result type to struct thread_info *.
13305 * inferiors.c (add_thread): Change result type to struct thread_info *.
13306 All callers updated.
13307 (add_lwp): Call add_thread here instead of in callers.
13308 All callers updated.
13309 * linux-low.h (get_lwp_thread): Rewrite.
13310 (struct lwp_info): New member "thread".
13311
b3312d80
DE
133122014-02-19 Doug Evans <dje@google.com>
13313
13314 * linux-low.c (add_lwp): Change result to struct lwp_info *.
13315 All callers updated.
13316
ecc6f45c
DE
133172014-02-19 Doug Evans <dje@google.com>
13318
13319 * inferiors.c (add_thread): Fix whitespace.
13320
649ebbca
DE
133212014-02-19 Doug Evans <dje@google.com>
13322
13323 * dll.c (clear_dlls): Replace accessing list implemention details
13324 with API function.
13325 * gdbthread.h (get_first_thread): Declare.
13326 * inferiors.c (for_each_inferior_with_data): New function.
13327 (get_first_thread): New function.
13328 (find_thread_ptid): Simplify.
13329 (get_first_inferior): New function.
13330 (clear_list): Delete.
13331 (one_inferior_p): New function.
13332 (clear_inferior_list): New function.
13333 (clear_inferiors): Update.
13334 * inferiors.h (for_each_inferior_with_data): Declare.
13335 (clear_inferior_list): Declare.
13336 (one_inferior_p): Declare.
13337 (get_first_inferior): Declare.
13338 * linux-low.c (linux_wait_for_event): Replace accessing list
13339 implemention details with API function.
13340 * server.c (target_running): Ditto.
13341 (accumulate_file_name_length): New function.
13342 (emit_dll_description): New function.
13343 (handle_qxfer_libraries): Replace accessing list implemention
13344 details with API function.
13345 (handle_qxfer_threads_worker): New function.
13346 (handle_qxfer_threads_proper): Replace accessing list implemention
13347 details with API function.
13348 (handle_query): Ditto.
13349 (visit_actioned_threads_callback_ftype): New typedef.
13350 (visit_actioned_threads_data): New struct.
13351 (visit_actioned_threads): Rewrite to be find_inferior callback.
13352 (resume): Call find_inferior.
13353 (handle_status): Replace accessing list implemention
13354 details with API function.
13355 (process_serial_event): Replace accessing list implemention details
13356 with API function.
13357 * target.c (set_desired_inferior): Replace accessing list implemention
13358 details with API function.
13359 * tracepoint.c (same_process_p): New function.
13360 (gdb_agent_about_to_close): Replace accessing list implemention
13361 details with API function.
13362 * win32-low.c (child_delete_thread): Replace accessing list
13363 implemention details with API function.
13364 (match_dll_by_basename): New function.
13365 (dll_is_loaded_by_basename): New function.
13366 (win32_ensure_ntdll_loaded): Replace accessing list implemention
13367 details call to dll_is_loaded_by_basename.
13368
80894984
DE
133692014-02-19 Doug Evans <dje@google.com>
13370
13371 * dll.h (struct dll_info): Add comment.
13372 * gdbthread.h (struct thread_info): Add comment.
13373 (current_ptid): Simplify.
13374 * inferiors.c (add_process): Update.
13375 (remove_process): Update.
13376 * inferiors.h (struct process_info): Rename member "head" to "entry".
13377 * linux-low.c (delete_lwp): Update.
13378 (add_lwp): Update.
13379 (last_thread_of_process_p): Update.
13380 (kill_one_lwp_callback, linux_kill): Update.
13381 (status_pending_p_callback): Update.
13382 (wait_for_sigstop): Update. Simplify read of ptid.
13383 (start_step_over): Update.
13384 * linux-low.h (ptid_of, pid_of, lwpid_of): Update.
13385 (get_lwp_thread): Update.
13386 (struct lwp_info): Rename member "head" to "entry".
13387 * regcache.h (inferior_list_entry): Delete.
13388 * server.c (kill_inferior_callback): Update.
13389 (detach_or_kill_inferior_callback): Update.
13390 (print_started_pid): Update.
13391 (print_attached_pid): Update.
13392 (process_serial_event): Simplify read of ptid.
13393 * thread-db.c (thread_db_create_event): Update.
13394 (thread_db_get_tls_address): Update.
13395 * win32-low.c (current_inferior_ptid): Simplify.
13396
46917d26
TT
133972014-02-19 Tom Tromey <tromey@redhat.com>
13398
13399 * target.h (struct target_ops) <supports_btrace>: Add target_ops
13400 argument.
13401 (target_supports_btrace): Update.
13402
0759a81e
YQ
134032014-02-14 Yao Qi <yao@codesourcery.com>
13404
13405 * Makefile.in (IPA_OBJS): Append rsp-low-ipa.o.
13406 (rsp-low-ipa.o): New target.
13407
a7191e8b
TT
134082014-02-12 Tom Tromey <tromey@redhat.com>
13409
13410 * ax.c (gdb_parse_agent_expr): Use hex2bin, not
13411 convert_ascii_to_int.
13412 * regcache.c (registers_to_string): Likewise.
13413 * remote-utils.c (decode_M_packet): Likewise.
13414 * server.c (process_serial_event): Likewise.
13415
ff0e980e
TT
134162014-02-12 Tom Tromey <tromey@redhat.com>
13417
13418 * server.c (handle_query, handle_v_run): Use hex2bin, not
13419 unhexify.
13420 * tracepoint.c (cmd_qtdpsrc, cmd_qtdv, cmd_qtnotes): Likewise.
13421
e9371aff
TT
134222014-02-12 Tom Tromey <tromey@redhat.com>
13423
13424 * ax.c (gdb_unparse_agent_expr): Use bin2hex, not
13425 convert_int_to_ascii.
13426 * regcache.c (registers_to_string, collect_register_as_string):
13427 Likewise.
13428 * remote-utils.c (look_up_one_symbol, relocate_instruction):
13429 Likewise.
13430 * server.c (process_serial_event): Likewise.
13431 * tracepoint.c (cmd_qtstatus, response_source, response_tsv)
13432 (cmd_qtbuffer, cstr_to_hexstr): Likewise.
13433
971dc0b8
TT
134342014-02-12 Tom Tromey <tromey@redhat.com>
13435
13436 * remote-utils.c (look_up_one_symbol, monitor_output): Use
13437 bin2hex, not hexify.
13438 * tracepoint.c (cmd_qtstatus): Likewise.
13439
0a822afb
TT
134402014-02-12 Tom Tromey <tromey@redhat.com>
13441
13442 * remote-utils.c (monitor_output): Pass explicit length to
13443 hexify.
13444
9c3d6531
TT
134452014-02-12 Tom Tromey <tromey@redhat.com>
13446
13447 * tracepoint.c: Include rsp-low.h.
13448 * server.c: Include rsp-low.h.
13449 * remote-utils.h (convert_ascii_to_int, convert_int_to_ascii)
13450 (unhexify, hexify, remote_escape_output, unpack_varlen_hex): Don't
13451 declare.
13452 * remote-utils.c: Include rsp-low.h.
13453 (fromhex, hexchars, ishex, unhexify, tohex, hexify)
13454 (remote_escape_output, remote_unescape_input, unpack_varlen_hex)
13455 (convert_int_to_ascii, convert_ascii_to_int): Move to
13456 common/rsp-low.c.
13457 * regcache.c: Include rsp-low.h.
13458 * ax.c: Include rsp-low.h.
13459 * Makefile.in (SFILES): Add common/rsp-low.c.
13460 (OBS): Add rsp-low.o.
13461 (rsp-low.o): New target.
13462
01fd3ea5
TT
134632014-02-12 Tom Tromey <tromey@redhat.com>
13464
13465 * utils.h (pulongest, plongest, phex_nz): Don't declare.
13466 Include print-utils.h.
13467 * utils.c (NUMCELLS, CELLSIZE, get_cell, decimal2str, pulongest)
13468 (plongest, thirty_two, phex_nz): Remove.
13469 * Makefile.in (SFILES): Add common/print-utils.c.
13470 (OBS): Add print-utils.o.
13471 (print-utils-ipa.o): New target.
13472 (print-utils.o): New target.
13473 (IPA_OBJS): Add print-utils-ipa.o.
13474
e99dc820
TT
134752014-02-06 Tom Tromey <tromey@redhat.com>
13476
13477 * Makefile.in (SFILES): Fix indentation.
13478
ee1e2d4f
DE
134792014-02-05 Doug Evans <dje@google.com>
13480
13481 * linux-low.c (linux_wait_for_event): Improve comment.
13482 (linux_wait_1): Keep current_inferior in sync with event_child.
13483
f5a02773
DE
134842014-01-22 Doug Evans <dje@google.com>
13485
13486 * gdbthread.h (gdb_id_to_thread): Delete, unused.
13487
87ce2a04
DE
134882014-01-22 Doug Evans <dje@google.com>
13489
13490 * configure.ac (AC_CHECK_FUNCS): Add test for gettimeofday.
13491 * configure: Regenerate.
13492 * config.in: Regenerate.
13493 * Makefile.in (SFILES): Add debug.c.
13494 (OBS): Add debug.o.
13495 * debug.c: New file.
13496 * debug.h: New file.
13497 * linux-aarch64-low.c (*): Update all debugging printfs to use
13498 debug_printf instead of fprintf.
13499 * linux-arm-low.c (*): Ditto.
13500 * linux-cris-low.c (*): Ditto.
13501 * linux-crisv32-low.c (*): Ditto.
13502 * linux-m32r-low.c (*): Ditto.
13503 * linux-sparc-low.c (*): Ditto.
13504 * linux-x86.c (*): Ditto.
13505 * linux-low.c (*): Ditto.
13506 (linux_wait_1): Add calls to debug_enter, debug_exit.
13507 (linux_wait): Remove redundant debugging printf.
13508 (stop_all_lwps): Add calls to debug_enter, debug_exit.
13509 (linux_resume, unstop_all_lwps): Ditto.
13510 * mem-break.c (*): Update all debugging printfs to use
13511 debug_printf instead of fprintf.
13512 * remote-utils.c (*): Ditto.
13513 * thread-db.c (*): Ditto.
13514 * server.c #include <ctype.h>, "gdb_vecs.h".
13515 (debug_threads): Moved to debug.c.
13516 (*): Update all debugging printfs to use debug_printf instead of
13517 fprintf.
13518 (start_inferior): Replace call to fflush with call to debug_flush.
13519 (monitor_show_help): Mention set debug-format.
13520 (parse_debug_format_options): New function.
13521 (handle_monitor_command): Handle "monitor set debug-format".
13522 (gdbserver_usage): Mention --debug-format.
13523 (main): Parse --debug-format.
13524 * server.h (debug_threads): Declaration moved to debug.h.
13525 #include "debug.h".
13526 * tracepoint.c (trace_debug_1) [!IN_PROCESS_AGENT]: Add version of
13527 trace_debug_1 that uses debug_printf.
13528 (tracepoint_look_up_symbols): Update all debugging printfs to use
13529 debug_printf instead of fprintf.
13530
e671835b
BS
135312014-01-20 Baruch Siach <baruch@tkos.co.il>
13532
13533 * linux-xtensa-low.c: Include asm/ptrace.h instead of
13534 sys/ptrace.h.
13535
b5737fa9
PA
135362014-01-17 Pedro Alves <palves@redhat.com>
13537
ea38d2a9 13538 PR build/16445
c7faa97a
PA
13539 * linux-x86-low.c: Don't include elf/common.h if ELFMAG0 is
13540 defined after including gdb_proc_service.h.
b5737fa9 13541
40ed484e
DE
135422014-01-16 Doug Evans <dje@google.com>
13543
13544 * dll.c (UNSPECIFIED_CORE_ADDR): New macro.
13545 (match_dll): Use it.
13546
969c39fb
MM
135472014-01-16 Markus Metzger <markus.t.metzger@intel.com>
13548
13549 * target.h (target_ops) <read_btrace>: Change parameters and
13550 return type to allow error reporting.
13551 * server.c (handle_qxfer_btrace): Support delta reads. Pass
13552 trace reading errors on.
13553 * linux-low.c (linux_low_read_btrace): Pass trace reading
13554 errors on.
13555 (linux_low_disable_btrace): New.
13556
ab7f45ba
DE
135572014-01-15 Doug Evans <dje@google.com>
13558
13559 * inferiors.c (thread_id_to_gdb_id): Delete.
13560 * inferiors.h (thread_id_to_gdb_id): Delete.
13561
66af0f44
EZ
135622014-01-13 Eli Zaretskii <eliz@gnu.org>
13563
13564 * Makefile.in (INCLUDE_CFLAGS): Remove trailing slash from
13565 "-I$(srcdir)/../". Fixes MinGW compilation errors with old GCC
13566 versions.
13567
9939e131
PA
135682014-01-08 Pedro Alves <palves@redhat.com>
13569
13570 * server.c (handle_status): Don't discard previous queued stop
13571 replies or thread's pending status here.
13572 (main) <disconnection>: Do it here instead.
13573
b7ea362b
PA
135742014-01-08 Pedro Alves <palves@redhat.com>
13575
13576 * gdbthread.h (struct thread_info) <status_pending_p>: New field.
13577 * server.c (visit_actioned_threads, handle_pending_status): New
13578 function.
13579 (handle_v_cont): Factor out parts to ...
13580 (resume): ... this new function. If in all-stop, and a thread
13581 being resumed has a pending status, report it without actually
13582 resuming.
13583 (myresume): Adjust to use the new 'resume' function.
13584 (clear_pending_status_callback, set_pending_status_callback)
13585 (find_status_pending_thread_callback): New functions.
13586 (handle_status): Handle the case of multiple threads having
13587 interesting statuses to report. Report threads' real last signal
13588 instead of always reporting GDB_SIGNAL_TRAP. Look for a thread
13589 with an interesting thread to report the status for, instead of
13590 always reporting the status of the first thread.
13591
28498c42
JB
135922014-01-01 Joel Brobecker <brobecker@adacore.com>
13593
13594 * gdbserver.c (gdbserver_version): Set copyright year to 2014.
13595 * gdbreplay.c (gdbreplay_version): Likewise.
13596
f45c82da
YZ
135972013-12-18 Yufeng Zhang <yufeng.zhang@arm.com>
13598
13599 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Set
13600 iov.iov_len with the real length in use.
13601
379a5e2d
JB
136022013-12-13 Joel Brobecker <brobecker@adacore.com>
13603
13604 * Makefile.in (safe-ctype.o, lbasename.o): New rules.
13605 * configure.srv: Add safe-ctype.o and lbasename.o to srv_tgtobj
13606 for all targets that use win32-low.c.
13607 * win32-low.c (win32_ensure_ntdll_loaded): New function.
13608 (do_initial_child_stuff): Add call to win32_ensure_ntdll_loaded.
13609
4210d83e
PA
136102013-12-13 Pedro Alves <palves@redhat.com>
13611
13612 * target.c (mywait): Set OURSTATUS->KIND to TARGET_WAITKIND_STOPPED
13613 if equal to TARGET_WAITKIND_LOADED.
13614 * win32-low.c (cached_status): New static global.
13615 (win32_wait): Add declaration.
13616 (do_initial_child_stuff): Flush all initial pending debug events
13617 up to the initial breakpoint.
13618 (win32_wait): If CACHED_STATUS was set, return that instead
13619 of doing a real wait. Remove the code resuming the execution
13620 of the inferior after receiving a TARGET_WAITKIND_LOADED event
13621 during the initial phase. Also remove the code changing
13622 OURSTATUS->KIND from TARGET_WAITKIND_LOADED to
13623 TARGET_WAITKIND_STOPPED.
13624
e7f0d979
YQ
136252013-12-11 Yao Qi <yao@codesourcery.com>
13626
13627 * notif.c (handle_notif_ack): Return 0 if no notification
13628 matches.
13629
ebcf782c
DE
136302013-11-20 Doug Evans <dje@google.com>
13631
13632 * linux-low.c (linux_set_resume_request): Fix comment.
13633
20ad9378
DE
136342013-11-20 Doug Evans <dje@google.com>
13635
13636 * linux-low.c (resume_status_pending_p): Tweak comment.
13637
a196ebeb
WT
136382013-11-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
13639
13640 * Makefile.in: Add i386-mpx.c, i386-mpx-linux.c, amd64-mpx.c,
13641 amd64-mpx-linux.c, x32-mpx.c and x32-mpx-linux.c generation.
13642 * configure.srv (srv_i386_regobj): Add i386-mpx.o.
13643 (srv_i386_linux_regobj): Add i386-mpx-linux.o.
13644 (srv_amd64_regobj): Add amd64-mpx.o.
13645 (srv_amd64_linux_regobj): Add amd64-mpx-linux.o.
13646 (srv_i386_32bit_xmlfiles): Add i386/32bit-mpx.xml.
13647 (srv_i386_64bit_xmlfiles): Add i386/64bit-mpx.xml.
13648 * i387-fp.c (num_pl_bnd_register) Added constant.
13649 (num_pl_bnd_cfg_registers) Added constant.
13650 (struct i387_xsave) Added reserved area and MPX fields.
13651 (i387_cache_to_xsave, i387_xsave_to_cache) Add MPX.
13652 * linux-x86-low.c (init_registers_i386_mpx_linux): Declare new
13653 function.
13654 (tdesc_i386_mpx_linux): Add MPX amd64 target.
13655 (init_registers_amd64_mpx_linux): Declare new function.
13656 (tdesc_amd64_mpx_linux): Add MPX amd64 target.
13657 (x86_64_regmap): Add MPX registers.
13658 (x86_linux_read_description): Add MPX case.
13659 (initialize_low_arch): Initialize MPX targets.
13660
0080a2f6
TT
136612013-11-18 Tom Tromey <tromey@redhat.com>
13662
13663 * configure: Rebuild.
13664 * configure.ac: Don't check for stdlib.h.
13665 * gdbreplay.c: Unconditionally include stdlib.h.
13666
2978b111
TT
136672013-11-18 Tom Tromey <tromey@redhat.com>
13668
13669 * config.in: Rebuild.
13670 * configure: Rebuild.
13671 * configure.ac: Don't use AC_HEADER_DIRENT.
13672
a3d08894
TT
136732013-11-18 Tom Tromey <tromey@redhat.com>
13674
13675 * server.h: Don't check HAVE_STRING_H.
13676 * gdbreplay.c: Don't check HAVE_STRING_H.
13677 * configure: Rebuild.
13678
0a5dd17d
TT
136792013-11-18 Tom Tromey <tromey@redhat.com>
13680
13681 * Makefile.in (gdbreplay$(EXEEXT)): Depend on and link against
13682 LIBGNU.
13683
1bd2f0ba
TT
136842013-11-08 Tom Tromey <tromey@redhat.com>
13685
13686 * configure, config.in: Rebuild.
13687 * configure.ac: Remove unused configury.
13688
3266f10b
TT
136892013-11-08 Tom Tromey <tromey@redhat.com>
13690
13691 * acinclude.m4: Include common.m4, codeset.m4.
13692 * configure, config.in: Rebuild.
13693 * configure.ac: Use GDB_AC_COMMON.
13694
6682d959
AA
136952013-11-06 Andreas Arnez <arnez@linux.vnet.ibm.com>
13696
13697 * linux-s390-low.c (HWCAP_S390_TE): New define.
13698 (s390_arch_setup): Consider the TE field in the HWCAP for
13699 determining 'have_regset_tdb'.
13700
fd0a4d76
SDJ
137012013-10-16 Sergio Durigan Junior <sergiodj@redhat.com>
13702
13703 PR gdb/16014
13704 * tracepoint.c (download_tracepoint_1): Remove unnecessary double
13705 call to sizeof.
13706
1a3d890b
PA
137072013-10-02 Pedro Alves <palves@redhat.com>
13708
13709 * server.c (process_serial_event): Don't output "GDBserver
13710 exiting" if GDB is connected through stdio.
13711 * target.c (mywait): Likewise, be silent if GDB is connected
13712 through stdio.
13713
97ad4581
JB
137142013-10-01 Joel Brobecker <brobecker@adacore.com>
13715
13716 * lynx-low.c (lynx_add_threads_after_attach): New function.
13717 (lynx_attach): Remove call to add_thread. Add call to
13718 lynx_add_threads_after_attach instead.
13719
5b4e221c
MF
137202013-09-28 Mike Frysinger <vapier@gentoo.org>
13721
13722 * configure.ac (AC_CHECK_HEADERS): Add sys/syscall.h
13723 * config.in, configure: Regenerated.
13724
ee47b2f8
YQ
137252013-09-18 Yao Qi <yao@codesourcery.com>
13726
13727 PR server/15959
13728 * server.c (start_inferior): Clear 'resume_info'.
13729
d6707650 137302013-09-16 Jiong Wang <jiwang@tilera.com>
0f63d4db 13731
d6707650
JW
13732 * linux-tile-low.c (tile_regsets): Modify the size field to 64-bit
13733 for each register.
13734
9243dd0e 137352013-09-16 Jiong Wang <jiwang@tilera.com>
0f63d4db 13736
9243dd0e
JW
13737 * configure.srv <tilegx*-*-linux*>: Remove linux-osdata.o from and add
13738 linux-tile-low.o to srv_tgtobj.
13739
c623a6ef
WN
137402013-09-16 Will Newton <will.newton@linaro.org>
13741
13742 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Zero
13743 out regs.
13744
fb71d39e
PA
137452013-09-06 Pedro Alves <palves@redhat.com>
13746
13747 * Makefile.in (gdb_proc_service_h, regdef_h, regcache_h)
13748 (signals_def, signals_h, ptid_h, ax_h, agent_h, linux_btrace_h)
13749 (linux_osdata_h, vec_h, gdb_vecs_h, host_defs_h, libiberty_h)
13750 (server_h, gdbthread_h, linux_low_h, linux_ptrace_h)
13751 (gdb_thread_db_h, linux_procfs_h, lynx_low_h, nto_low_h)
13752 (mips_linux_watch_h, i386_low_h, win32_low_h): Delete.
13753
8e7e9910
PA
137542013-09-06 Pedro Alves <palves@redhat.com>
13755
13756 * Makefile.in (linux-btrace.o, mips-linux-watch.o): Remove
13757 explicit header dependencies and use $COMPILE/$POSTCOMPILE.
13758
7c3a12ca
PA
137592013-09-06 Pedro Alves <palves@redhat.com>
13760
13761 * linux-amd64-ipa.c: Include tracepoint.h.
13762 * linux-i386-ipa.c: Include tracepoint.h.
13763
8eb3d7b6
RW
137642013-09-06 Ricard Wanderlof <ricardw@axis.com>
13765
13766 * linux-crisv32-low.c (PTRACE_GET_THREAD_AREA): New macro.
13767 (ps_get_thread_area): New function.
13768
eddddb9d
RW
137692013-09-06 Ricard Wanderlof <ricardw@axis.com>
13770
13771 * linux-crisv32-low.c (elf_gregset_t): Delete typedef.
13772 (initialize_low_arch): Call init_registers_crisv32 rather than
13773 init_register_crisv32.
13774
533b0600
PA
137752013-09-05 Pedro Alves <palves@redhat.com>
13776
13777 * server.h (handle_vFile, hostio_last_error_from_errno): Move
13778 to ...
13779 * hostio.h: ... this new file.
13780 * hostio.c, server.c, linux-low.c, nto-low.c, spu-low,
13781 win32-low.c: Include hostio.h.
13782
0ce3d3b5
PA
137832013-09-05 Pedro Alves <palves@redhat.com>
13784
13785 * server.h (gdb_client_data, handler_func, callback_handler_func)
13786 (delete_file_handler, add_file_handler, append_callback_event)
13787 (delete_callback_event, start_event_loop, initialize_event_loop):
13788 Move to event-loop.h and include it.
13789 * event-loop.h: New file.
13790
799cdc37
PA
137912013-09-05 Pedro Alves <palves@redhat.com>
13792
13793 * dll.c, inferiors.c, remote-utils.c, server.c: Include "dll.h".
13794 * server.h (struct dll_info, all_dlls, dlls_changed, clear_dlls)
13795 (loaded_dll, unloaded_dll): Move to ...
13796 * dll.h: ... this new file.
13797 * inferiors.c, remote-utils.c, win32-low.c: Include "dll.h".
13798
6a6bbd9d
PA
137992013-09-05 Pedro Alves <palves@redhat.com>
13800
13801 * server.h (current_process, get_thread_process, all_processes)
13802 (add_inferior_to_list, for_each_inferior, current_inferior)
13803 (remove_inferior, add_process, remove_process, find_process_pid)
13804 (have_started_inferiors_p, have_attached_inferiors_p)
13805 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id)
13806 (clear_inferiors, find_inferior, find_inferior_id)
13807 (inferior_target_data, set_inferior_target_data)
13808 (inferior_regcache_data, set_inferior_regcache_data): Move to
13809 inferiors.h, and include it.
13810 * inferiors.h: New file.
13811
f699aaba
PA
138122013-09-05 Pedro Alves <palves@redhat.com>
13813
13814 * server.h (struct emit_ops, current_insn_ptr, emit_error):
13815 Move ...
72f4393d 13816 * ax.h: ... here.
f699aaba 13817
c144c7a0
PA
138182013-09-05 Pedro Alves <palves@redhat.com>
13819
13820 * ax.c, linux-low.c, linux-x86-low.c, server.c: Include
13821 tracepoint.h.
13822 * server.h (IPA_BUFSIZ, initialize_tracepoint, tracing)
13823 (disconnected_tracing, tracepoint_look_up_symbols, stop_tracing
13824 (handle_tracepoint_general_set, handle_tracepoint_query)
13825 (tracepoint_finished_step, tracepoint_was_hit)
13826 (release_while_stepping_state_list, current_traceframe)
13827 (in_readonly_region, traceframe_read_mem)
13828 (fetch_traceframe_registers, traceframe_read_sdata)
13829 (traceframe_read_info, struct fast_tpoint_collect_status)
13830 (fast_tracepoint_collecting, force_unlock_trace_buffer)
13831 (handle_tracepoit_bkpts, initialize_low_tracepoint)
13832 (supply_fast_tracepoint_registers)
13833 (supply_static_tracepoint_registers, set_trampoline_buffer_space)
13834 (ipa_tdesc, claim_trampoline_space)
13835 (have_fast_tracepoint_trampoline_buffer, gdb_agent_about_to_close)
13836 (agent_mem_read, agent_get_trace_state_variable_value)
13837 (agent_set_trace_state_variable_value, agent_tsv_read)
13838 (agent_mem_read_string, get_raw_reg_func_addr)
13839 (get_get_tsv_func_addr, get_set_tsv_func_addr): Move to ...
13840 * tracepoint.h: ... this new file.
13841
ff42e6ab
PA
138422013-09-05 Pedro Alves <palves@redhat.com>
13843
13844 * server.h (perror_with_name, error, fatal, warning, paddress)
13845 (pulongest, plongest, phex_nz, pfildes): Move to utils.h, and
13846 include it.
13847 * utils.h: New file.
13848
541af0f4
PA
138492013-09-05 Pedro Alves <palves@redhat.com>
13850
13851 * server.h (remote_debug, noack_mode, transport_is_reliable)
13852 (gdb_connected, STDIO_CONNECTION_NAME, remote_connection_is_stdio)
13853 (read_ptid, write_ptid, putpkt, putpkt_binary, putpkt_notif)
13854 (getpkt, remote_prepare, remote_open, remote_close, write_ok)
13855 (write_enn, initialize_async_io, enable_async_io)
13856 (disable_async_io, check_remote_input_interrupt_request)
13857 (convert_ascii_to_int, convert_int_to_ascii, new_thread_notify)
13858 (dead_thread_notify, prepare_resume_reply)
13859 (decode_address_to_semicolon, decode_address, decode_m_packet)
13860 (decode_M_packet, decode_X_packet, decode_xfer_write)
13861 (decode_search_memory_packet, unhexify, hexify)
13862 (remote_escape_output, unpack_varlen_hex, clear_symbol_cache)
13863 (look_up_one_symbol, relocate_instruction)
13864 (monitor_output): Move to remote-utils.h, and include it.
13865 * remote-utils.h: New file.
13866
eebdf26b
PA
138672013-09-05 Pedro Alves <palves@redhat.com>
13868
13869 * server.h (_): Delete.
13870
3aafd2ff
PA
138712013-09-02 Pedro Alves <palves@redhat.com>
13872
13873 * tracepoint.c (TRACEFRAME_EOB_MARKER_SIZE): New macro.
13874 (init_trace_buffer): Ensure at least TRACEFRAME_EOB_MARKER_SIZE is
13875 allocated.
13876 (trace_buffer_alloc): Use TRACEFRAME_EOB_MARKER_SIZE.
13877
cee83bcb
PM
138782013-09-02 Pierre Muller <muller@sourceware.org>
13879
13880 * win32-low.c (child_xfer_memory): Check if ReadProcessMemory
13881 or WriteProcessMemory complete successfully and handle
13882 ERROR_PARTIAL_COPY error.
13883
9a13b2fa
PA
138842013-09-02 Pedro Alves <palves@redhat.com>
13885
13886 * server.c (gdb_read_memory): Return -1 on traceframe memory read
13887 error instead of EIO.
13888
602e3198
JK
138892013-08-28 Jan Kratochvil <jan.kratochvil@redhat.com>
13890
13891 PR server/15604
13892 * linux-low.c: Include filestuff.h.
13893 (linux_create_inferior) <pid == 0>: Call close_most_fds.
13894 * lynx-low.c: Include filestuff.h.
13895 (lynx_create_inferior) <pid == 0>: Call close_most_fds.
13896 * server.c: Include filestuff.h.
13897 (main): Call notice_open_fds.
13898 * spu-low.c: Include filestuff.h.
13899 (spu_create_inferior) <pid == 0>: Call close_most_fds.
13900
96d7229d
LM
139012013-08-22 Luis Machado <lgustavo@codesourcery.com>
13902
13903 * Makefile.in: Explain why ../target and ../nat are not
13904 listed as include file search paths.
13905 (linux-waitpid.o): New object file rule.
13906 * configure.srv (srv_native_linux_obj): New variable.
13907 Replace all occurrences of linux native object files with
13908 $srv_native_linux_obj.
13909 * linux-low.c: Include nat/linux-nat.h and nat/linux-waitpid.h.
13910 (HAS_NOMMU): Move defining logic to common/linux-ptrace.c.
13911 (linux_enable_event_reporting): Remove declaration.
13912 (my_waitpid): Moved to common/linux-waitpid.c.
13913 (linux_wait_for_event): Pass ptid when calling
13914 linux_enable_event_reporting.
13915 (linux_supports_tracefork_flag): Remove.
13916 (linux_enable_event_reporting): Likewise.
13917 (linux_tracefork_grandchild): Remove.
13918 (STACK_SIZE): Moved to common/linux-ptrace.c.
13919 (linux_tracefork_child): Remove.
13920 (linux_test_for_tracefork): Remove.
13921 (linux_look_up_symbols): Call linux_supports_traceclone.
13922 (initialize_low): Remove call to linux_test_for_tracefork.
13923 * linux-low.h (PTRACE_TYPE_ARG3): Move to
13924 common/linux-ptrace.h.
13925 (PTRACE_TYPE_ARG4): Likewise.
13926 Include linux-ptrace.h.
13927
32940073
PA
139282013-08-21 Pedro Alves <palves@redhat.com>
13929
13930 * config.in: Renegerate.
13931
33b60d58 139322013-08-19 Luis Machado <lgustavo@codesourcery.com>
a261b8f5 13933
33b60d58
LM
13934 * Makefile.in (INCLUDE_CFLAGS): Include -I$(srcdir)/../.
13935 (SFILES): Remove $(srcdir)/common/target-common.c and
13936 add $(srcdir)/target/waitstatus.c.
13937 (OBS): Remove target-common.o and add waitstatus.o.
13938 (server_h): Remove $(srcdir)/../common/target-common.h and
13939 add $(srcdir)/../target/resume.h, $(srcdir)/../target/wait.h
13940 and $(srcdir)/../target/waitstatus.h.
13941 (target-common.o): Remove.
13942 (waitstatus.o): New target object file.
13943 * target.h: Do not include target-common.h and
13944 include target/resume.h, target/wait.h and
13945 target/waitstatus.h.
13946
b8e1b30e
LM
139472013-08-13 Luis Machado <lgustavo@codesourcery.com>
13948
13949 * linux-arm-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
13950 to PTRACE_TYPE_ARG3.
13951 * linux-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
13952 to PTRACE_TYPE_ARG3 and PTRACE_ARG4_TYPE to
13953 PTRACE_TYPE_ARG4.
13954 * linux-low.h (PTRACE_ARG3_TYPE): Rename to PTRACE_TYPE_ARG3.
13955 (PTRACE_ARG4_TYPE): Rename to PTRACE_TYPE_ARG4.
13956
7a60ad40
YQ
139572013-07-27 Jie Zhang <jie@codesourcery.com>
13958 Daniel Jacobowitz <dan@codesourcery.com>
13959 Yao Qi <yao@codesourcery.com>
13960
13961 * Makefile.in (SFILES): Add common/mips-linux-watch.c.
13962 (mips-linux-watch.o): New rule.
13963 (mips_linux_watch_h): New variable.
13964 * configure.srv <mips*-*-linux*>: Add mips-linux-watch.o to
13965 srv_tgtobj.
13966 * linux-mips-low.c: Include mips-linux-watch.h.
13967 (struct arch_process_info, struct arch_lwp_info): New.
13968 (update_watch_registers_callback): New function.
13969 (mips_linux_new_process, mips_linux_new_thread) New functions.
13970 (mips_linux_prepare_to_resume, mips_insert_point): New
13971 functions.
13972 (mips_remove_point, mips_stopped_by_watchpoint): New
13973 functions.
13974 (rsp_bp_type_to_target_hw_bp_type): New function.
13975 (mips_stopped_data_address): New function.
13976 (the_low_target): Add watchpoint support functions.
13977
de6f69ad
YQ
139782013-07-27 Yao Qi <yao@codesourcery.com>
13979
13980 * i386-low.c: Include break-common.h.
13981 (enum target_hw_bp_type): Remove.
13982
3360c0bf
LM
139832013-07-24 Luis Machado <lgustavo@codesourcery.com>
13984
13985 * Makefile.in (SFILES): /common/target-common.c.
13986 (OBS): Add target-common.o.
13987 (server_h): Add $(srcdir)/../common/target-common.h.
13988 (target-common.o): New target.
13989 * server.c (queue_stop_reply_callback): Free
13990 status string after use.
13991 * target.c (target_waitstatus_to_string): Remove.
13992 * target.h: Include target-common.h.
13993 (resume_kind): Likewise.
13994 (target_waitkind): Likewise.
13995 (target_waitstatus): Likewise.
13996 (TARGET_WNOHANG): Likewise.
13997
bd885420
YQ
139982013-07-04 Yao Qi <yao@codesourcery.com>
13999
14000 * Makefile.in (host_alias): Use @host_noncanonical@.
14001 (target_alias): Use @target_noncanonical@.
14002 * configure.ac: Use ACX_NONCANONICAL_TARGET and
14003 ACX_NONCANONICAL_HOST.
14004 * configure: Regenerated.
14005
14006 Revert:
14007 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
14008
14009 * configure.ac (version_host, version_target): Set and AC_SUBST them.
14010 * configure: Rebuild.
14011 * Makefile.in (version_host, version_target): Get from configure.
14012 (version.c): Use $(version_host) and $(version_target).
14013
17ef446e
PA
140142013-07-03 Pedro Alves <palves@redhat.com>
14015
14016 * Makefile.in (config.status): Depend on development.sh.
14017 * acinclude.m4: Include libmcheck.m4.
14018 * configure: Regenerate.
14019
7a9a7487
MG
140202013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
14021
14022 * win32-low.c (winapi_DebugActiveProcessStop): Move the WINAPI
14023 attribute inside the parentheses.
14024 (winapi_DebugSetProcessKillOnExit): Ditto.
14025 (winapi_DebugBreakProcess): Ditto.
14026 (winapi_GenerateConsoleCtrlEvent): Ditto.
a261b8f5 14027
49b64de6
MG
140282013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
14029
14030 * notif.h (notif_event): Add a dummy member to avoid compiler
14031 errors.
14032
d5749ee7
PA
140332013-07-01 Pedro Alves <palves@redhat.com>
14034
14035 * hostio.c (HOSTIO_PATH_MAX): Define.
14036 (require_filename, handle_open, handle_unlink, handle_readlink):
14037 Use it.
14038
d8d2a3ee
PA
140392013-07-01 Pedro Alves <palves@redhat.com>
14040
14041 * server.h: Include "pathmax.h".
14042 * linux-low.c: Don't include sys/param.h.
14043 (linux_pid_exe_is_elf_64_file): Use PATH_MAX instead of
14044 MAXPATHLEN.
14045 * win32-low.c: Don't include sys/param.h.
14046 (win32_create_inferior): Use PATH_MAX instead of MAXPATHLEN.
14047
bc7dea8d
PA
140482013-07-01 Pedro Alves <palves@redhat.com>
14049
14050 * event-loop.c: Don't check HAVE_UNISTD_H before including
14051 <unistd.h>.
14052 * gdbreplay.c: Likewise.
14053 * remote-utils.c: Likewise.
14054 * server.c: Likewise.
14055 * configure.ac: Don't check for unistd.h.
14056 * configure: Regenerate.
14057
d6c2da54
TT
140582013-06-28 Tom Tromey <tromey@redhat.com>
14059
14060 * Makefile.in (version.c): Use version.in, not
14061 common/version.in.
14062
257b6bec
MG
140632013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
14064
14065 * configure.ac (version_host, version_target): Set and AC_SUBST them.
14066 * configure: Rebuild.
14067 * Makefile.in (version_host, version_target): Get from configure.
14068 (version.c): Use $(version_host) and $(version_target).
14069
86ebe149
DK
140702013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
14071
14072 Fix trace-status to output user name without trailing colon.
14073 * tracepoint.c (cmd_qtstatus): Remove unnecessary colon from user name.
14074
f30aa5af
DK
140752013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
14076
14077 Fix trace-status to output proper start-time and stop-time.
14078 * tracepoint.c (cmd_qtstatus): Modify trace-status output to
14079 output start time and stop time in hex as gdb expects.
14080
28a93511
YQ
140812013-06-26 Pedro Alves <pedro@codesourcery.com>
14082
14083 * tracepoint.c (build_traceframe_info_xml): Output trace state
14084 variables present in the trace buffer.
14085
01208463
TT
140862013-06-24 Tom Tromey <tromey@redhat.com>
14087
14088 * Makefile.in (version.c): Use bfd/version.h, common/version.in,
14089 create-version.sh.
14090 (version.o): Remove.
14091 * gdbreplay.c: Include version.h.
14092 (version, host_name): Don't declare.
14093 * server.h: Include version.h.
14094 (version, host_name): Don't declare.
14095
760256f9
PA
140962013-06-12 Pedro Alves <palves@redhat.com>
14097
14098 * linux-x86-low.c (linux_is_elf64): Delete global.
14099 (x86_siginfo_fixup): Replace reference to `linux_is_elf64' global
14100 with local linux_pid_exe_is_elf_64_file use.
14101
030031ee
PA
141022013-06-11 Pedro Alves <palves@redhat.com>
14103
14104 * linux-low.c (regset_disabled, disable_regset): New functions.
14105 (regsets_fetch_inferior_registers)
14106 (regsets_store_inferior_registers): Use them.
14107 (initialize_regsets_info); Don't allocate the disabled_regsets
14108 array here.
14109 * linux-low.h (struct regsets_info) <disabled_regsets>: Extend
14110 comment.
14111
5da6eb0a
PA
141122013-06-11 Pedro Alves <palves@redhat.com>
14113
14114 * linux-low.c (initialize_regsets_info): Use xcalloc instead of
14115 xmalloc.
14116
7e5aaa09
PA
141172013-06-11 Pedro Alves <palves@redhat.com>
14118
14119 * linux-x86-low.c (initialize_low_arch): Call
14120 init_registers_x32_avx_linux.
14121
d878444c
JK
141222013-06-09 Jan Kratochvil <jan.kratochvil@redhat.com>
14123
14124 Fix compatibility with Android Bionic.
14125 * linux-low.c (linux_qxfer_libraries_svr4): Ignore first entry even if
14126 it is not empty.
14127
3aee8918
PA
141282013-06-07 Pedro Alves <palves@redhat.com>
14129
5f2b57b5 14130 PR server/14823
3aee8918
PA
14131 * Makefile.in (OBS): Add tdesc.o.
14132 (IPA_OBJS): Add tdesc-ipa.o.
14133 (tdesc-ipa.o): New rule.
14134 * ax.c (gdb_eval_agent_expr): Adjust register_size call to new
14135 interface.
14136 * linux-low.c (new_inferior): Delete.
14137 (disabled_regsets, num_regsets): Delete.
14138 (linux_add_process): Adjust to set the new per-process
14139 new_inferior flag.
14140 (linux_detach_one_lwp): Adjust to call regcache_invalidate_thread.
14141 (linux_wait_for_lwp): Adjust. Only call arch_setup if the event
14142 was a stop. When calling arch_setup, switch the current inferior
14143 to the thread that got an event.
14144 (linux_resume_one_lwp): Adjust to call regcache_invalidate_thread.
14145 (regsets_fetch_inferior_registers)
14146 (regsets_store_inferior_registers): New regsets_info parameter.
14147 Adjust to use it.
14148 (linux_register_in_regsets): New regs_info parameter. Adjust to
14149 use it.
14150 (register_addr, fetch_register, store_register): New usrregs_info
14151 parameter. Adjust to use it.
14152 (usr_fetch_inferior_registers, usr_store_inferior_registers): New
14153 parameter regs_info. Adjust to use it.
14154 (linux_fetch_registers): Get the current inferior's regs_info, and
14155 adjust to use it.
14156 (linux_store_registers): Ditto.
14157 [HAVE_LINUX_REGSETS] (initialize_regsets_info): New.
14158 (initialize_low): Don't initialize the target_regsets here. Call
14159 initialize_low_arch.
14160 * linux-low.h (target_regsets): Delete declaration.
14161 (struct regsets_info): New.
14162 (struct usrregs_info): New.
14163 (struct regs_info): New.
14164 (struct process_info_private) <new_inferior>: New field.
14165 (struct linux_target_ops): Delete the num_regs, regmap, and
14166 regset_bitmap fields. New field regs_info.
14167 [HAVE_LINUX_REGSETS] (initialize_regsets_info): Declare.
14168 * i387-fp.c (num_xmm_registers): Delete.
14169 (i387_cache_to_fsave, i387_fsave_to_cache): Adjust find_regno
14170 calls to new interface.
14171 (i387_cache_to_fxsave, i387_cache_to_xsave, i387_fxsave_to_cache)
14172 (i387_xsave_to_cache): Adjust find_regno calls to new interface.
14173 Infer the number of xmm registers from the regcache's target
14174 description.
14175 * i387-fp.h (num_xmm_registers): Delete.
14176 * inferiors.c (add_thread): Don't install the thread's regcache
14177 here.
14178 * proc-service.c (gregset_info): Fetch the current inferior's
14179 regs_info. Adjust to use it.
14180 * regcache.c: Include tdesc.h.
14181 (register_bytes, reg_defs, num_registers)
14182 (gdbserver_expedite_regs): Delete.
14183 (get_thread_regcache): If the thread doesn't have a regcache yet,
14184 create one, instead of aborting gdbserver.
14185 (regcache_invalidate_one): Rename to ...
14186 (regcache_invalidate_thread): ... this.
14187 (regcache_invalidate_one): New.
14188 (regcache_invalidate): Only invalidate registers of the current
14189 process.
14190 (init_register_cache): Add target_desc parameter, and use it.
14191 (new_register_cache): Ditto. Assert the target description has a
14192 non zero registers_size.
14193 (regcache_cpy): Add assertions. Adjust.
14194 (realloc_register_cache, set_register_cache): Delete.
14195 (registers_to_string, registers_from_string): Adjust.
14196 (find_register_by_name, find_regno, find_register_by_number)
14197 (register_cache_size): Add target_desc parameter, and use it.
14198 (free_register_cache_thread, free_register_cache_thread_one)
14199 (regcache_release, register_cache_size): New.
14200 (register_size): Add target_desc parameter, and use it.
14201 (register_data, supply_register, supply_register_zeroed)
14202 (supply_regblock, supply_register_by_name, collect_register)
14203 (collect_register_as_string, collect_register_by_name): Adjust.
14204 * regcache.h (struct target_desc): Forward declare.
14205 (struct regcache) <tdesc>: New field.
14206 (init_register_cache, new_register_cache): Add target_desc
14207 parameter.
14208 (regcache_invalidate_thread): Declare.
14209 (regcache_invalidate_one): Delete declaration.
14210 (regcache_release): Declare.
14211 (find_register_by_number, register_cache_size, register_size)
14212 (find_regno): Add target_desc parameter.
14213 (gdbserver_expedite_regs, gdbserver_xmltarget): Delete
14214 declarations.
14215 * remote-utils.c: Include tdesc.h.
14216 (outreg, prepare_resume_reply): Adjust.
14217 * server.c: Include tdesc.h.
14218 (gdbserver_xmltarget): Delete declaration.
14219 (get_features_xml, process_serial_event): Adjust.
14220 * server.h [IN_PROCESS_AGENT] (struct target_desc): Forward
14221 declare.
14222 (struct process_info) <tdesc>: New field.
14223 (ipa_tdesc): Declare.
14224 * tdesc.c: New file.
14225 * tdesc.h: New file.
14226 * tracepoint.c: Include tdesc.h.
14227 [IN_PROCESS_AGENT] (ipa_tdesc): Define.
14228 (get_context_regcache): Adjust to pass ipa_tdesc down.
14229 (do_action_at_tracepoint): Adjust to get the register cache size
14230 from the context regcache's description.
14231 (traceframe_walk_blocks): Adjust to get the register cache size
14232 from the current trace frame's description.
14233 (traceframe_get_pc): Adjust to get current trace frame's
14234 description and pass it down.
14235 (gdb_collect): Adjust to get the register cache size from the
14236 IPA's description.
14237 * linux-amd64-ipa.c (tdesc_amd64_linux): Declare.
14238 (gdbserver_xmltarget): Delete.
14239 (initialize_low_tracepoint): Set the ipa's target description.
14240 * linux-i386-ipa.c (tdesc_i386_linux): Declare.
14241 (initialize_low_tracepoint): Set the ipa's target description.
14242 * linux-x86-low.c: Include tdesc.h.
14243 [__x86_64__] (is_64bit_tdesc): New.
14244 (ps_get_thread_area, x86_get_thread_area): Use it.
14245 (i386_cannot_store_register): Rename to ...
14246 (x86_cannot_store_register): ... this. Use is_64bit_tdesc.
14247 (i386_cannot_fetch_register): Rename to ...
14248 (x86_cannot_fetch_register): ... this. Use is_64bit_tdesc.
14249 (x86_fill_gregset, x86_store_gregset): Adjust register_size calls
14250 to new interface.
14251 (target_regsets): Rename to ...
14252 (x86_regsets): ... this.
14253 (x86_get_pc, x86_set_pc): Adjust register_size calls to new
14254 interface.
14255 (x86_siginfo_fixup): Use is_64bit_tdesc.
14256 [__x86_64__] (tdesc_amd64_linux, tdesc_amd64_avx_linux)
14257 (tdesc_x32_avx_linux, tdesc_x32_linux)
14258 (tdesc_i386_linux, tdesc_i386_mmx_linux, tdesc_i386_avx_linux):
14259 Declare.
14260 (x86_linux_update_xmltarget): Delete.
14261 (I386_LINUX_XSAVE_XCR0_OFFSET): Define.
14262 (have_ptrace_getfpxregs, have_ptrace_getregset): New.
14263 (AMD64_LINUX_USER64_CS): New.
14264 (x86_linux_read_description): New, based on
14265 x86_linux_update_xmltarget.
14266 (same_process_callback): New.
14267 (x86_arch_setup_process_callback): New.
14268 (x86_linux_update_xmltarget): New.
14269 (x86_regsets_info): New.
14270 (amd64_linux_regs_info): New.
14271 (i386_linux_usrregs_info): New.
14272 (i386_linux_regs_info): New.
14273 (x86_linux_regs_info): New.
14274 (x86_arch_setup): Reimplement.
14275 (x86_install_fast_tracepoint_jump_pad): Use is_64bit_tdesc.
14276 (x86_emit_ops): Ditto.
14277 (the_low_target): Adjust. Install x86_linux_regs_info,
14278 x86_cannot_fetch_register, and x86_cannot_store_register.
14279 (initialize_low_arch): New.
14280 * linux-ia64-low.c (tdesc_ia64): Declare.
14281 (ia64_fetch_register): Adjust.
14282 (ia64_usrregs_info, regs_info): New globals.
14283 (ia64_regs_info): New function.
14284 (the_low_target): Adjust.
14285 (initialize_low_arch): New function.
14286 * linux-sparc-low.c (tdesc_sparc64): Declare.
14287 (sparc_fill_gregset_to_stack, sparc_store_gregset_from_stack):
14288 Adjust.
14289 (sparc_arch_setup): New function.
14290 (sparc_regsets_info, sparc_usrregs_info, regs_info): New globals.
14291 (the_low_target): Adjust.
14292 (initialize_low_arch): New function.
14293 * linux-ppc-low.c (tdesc_powerpc_32l, tdesc_powerpc_altivec32l)
14294 (tdesc_powerpc_cell32l, tdesc_powerpc_vsx32l)
14295 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_altivec32l)
14296 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_e500l)
14297 (tdesc_powerpc_64l, tdesc_powerpc_altivec64l)
14298 (tdesc_powerpc_cell64l, tdesc_powerpc_vsx64l)
14299 (tdesc_powerpc_isa205_64l, tdesc_powerpc_isa205_altivec64l)
14300 (tdesc_powerpc_isa205_vsx64l): Declare.
14301 (ppc_cannot_store_register, ppc_collect_ptrace_register)
14302 (ppc_supply_ptrace_register, parse_spufs_run, ppc_get_pc)
14303 (ppc_set_pc, ppc_get_hwcap): Adjust.
14304 (ppc_usrregs_info): Forward declare.
14305 (!__powerpc64__) ppc_regmap_adjusted: New global.
14306 (ppc_arch_setup): Adjust to the current process'es target
14307 description.
14308 (ppc_fill_vsxregset, ppc_store_vsxregset, ppc_fill_vrregset)
14309 (ppc_store_vrregset, ppc_fill_evrregset, ppc_store_evrregse)
14310 (ppc_store_evrregset): Adjust.
14311 (target_regsets): Rename to ...
14312 (ppc_regsets): ... this, and make static.
14313 (ppc_usrregs_info, ppc_regsets_info, regs_info): New globals.
14314 (ppc_regs_info): New function.
14315 (the_low_target): Adjust.
14316 (initialize_low_arch): New function.
14317 * linux-s390-low.c (tdesc_s390_linux32, tdesc_s390_linux32v1)
14318 (tdesc_s390_linux32v2, tdesc_s390_linux64, tdesc_s390_linux64v1)
14319 (tdesc_s390_linux64v2, tdesc_s390x_linux64, tdesc_s390x_linux64v1)
14320 (tdesc_s390x_linux64v2): Declare.
14321 (s390_collect_ptrace_register, s390_supply_ptrace_register)
14322 (s390_fill_gregset, s390_store_last_break): Adjust.
14323 (target_regsets): Rename to ...
14324 (s390_regsets): ... this, and make static.
14325 (s390_get_pc, s390_set_pc): Adjust.
14326 (s390_get_hwcap): New target_desc parameter, and use it.
14327 [__s390x__] (have_hwcap_s390_high_gprs): New global.
14328 (s390_arch_setup): Adjust to set the current process'es target
14329 description. Don't adjust the regmap.
14330 (s390_usrregs_info, s390_regsets_info, regs_info): New globals.
14331 [__s390x__] (s390_usrregs_info_3264, s390_regsets_info_3264)
14332 (regs_info_3264): New globals.
14333 (s390_regs_info): New function.
14334 (the_low_target): Adjust.
14335 (initialize_low_arch): New function.
14336 * linux-mips-low.c (tdesc_mips_linux, tdesc_mips_dsp_linux)
14337 (tdesc_mips64_linux, tdesc_mips64_dsp_linux): Declare.
14338 [__mips64] (init_registers_mips_linux)
14339 (init_registers_mips_dsp_linux): Delete defines.
14340 [__mips64] (tdesc_mips_linux, tdesc_mips_dsp_linux): New defines.
14341 (have_dsp): New global.
14342 (mips_read_description): New, based on mips_arch_setup.
14343 (mips_arch_setup): Reimplement.
14344 (get_usrregs_info): New function.
14345 (mips_cannot_fetch_register, mips_cannot_store_register)
14346 (mips_get_pc, mips_set_pc, mips_fill_gregset, mips_store_gregset)
14347 (mips_fill_fpregset, mips_store_fpregset): Adjust.
14348 (target_regsets): Rename to ...
14349 (mips_regsets): ... this, and make static.
14350 (mips_regsets_info, mips_dsp_usrregs_info, mips_usrregs_info)
14351 (dsp_regs_info, regs_info): New globals.
14352 (mips_regs_info): New function.
14353 (the_low_target): Adjust.
14354 (initialize_low_arch): New function.
14355 * linux-arm-low.c (tdesc_arm, tdesc_arm_with_iwmmxt)
14356 (tdesc_arm_with_vfpv2, tdesc_arm_with_vfpv3, tdesc_arm_with_neon):
14357 Declare.
14358 (arm_fill_vfpregset, arm_store_vfpregset): Adjust.
14359 (arm_read_description): New, with bits factored from
14360 arm_arch_setup.
14361 (arm_arch_setup): Reimplement.
14362 (target_regsets): Rename to ...
14363 (arm_regsets): ... this, and make static.
14364 (arm_regsets_info, arm_usrregs_info, regs_info): New globals.
14365 (arm_regs_info): New function.
14366 (the_low_target): Adjust.
14367 (initialize_low_arch): New function.
14368 * linux-m68k-low.c (tdesc_m68k): Declare.
14369 (target_regsets): Rename to ...
14370 (m68k_regsets): ... this, and make static.
14371 (m68k_regsets_info, m68k_usrregs_info, regs_info): New globals.
14372 (m68k_regs_info): New function.
14373 (m68k_arch_setup): New function.
14374 (the_low_target): Adjust.
14375 (initialize_low_arch): New function.
14376 * linux-sh-low.c (tdesc_sharch): Declare.
14377 (target_regsets): Rename to ...
14378 (sh_regsets): ... this, and make static.
14379 (sh_regsets_info, sh_usrregs_info, regs_info): New globals.
14380 (sh_regs_info, sh_arch_setup): New functions.
14381 (the_low_target): Adjust.
14382 (initialize_low_arch): New function.
14383 * linux-bfin-low.c (tdesc_bfin): Declare.
14384 (bfin_arch_setup): New function.
14385 (bfin_usrregs_info, regs_info): New globals.
14386 (bfin_regs_info): New function.
14387 (the_low_target): Adjust.
14388 (initialize_low_arch): New function.
14389 * linux-cris-low.c (tdesc_cris): Declare.
14390 (cris_arch_setup): New function.
14391 (cris_usrregs_info, regs_info): New globals.
14392 (cris_regs_info): New function.
14393 (the_low_target): Adjust.
14394 (initialize_low_arch): New function.
14395 * linux-cris-low.c (tdesc_crisv32): Declare.
14396 (cris_arch_setup): New function.
14397 (cris_regsets_info, cris_usrregs_info, regs_info): New globals.
14398 (cris_regs_info): New function.
14399 (the_low_target): Adjust.
14400 (initialize_low_arch): New function.
14401 * linux-m32r-low.c (tdesc_m32r): Declare.
14402 (m32r_arch_setup): New function.
14403 (m32r_usrregs_info, regs_info): New globals.
14404 (m32r_regs_info): Adjust.
14405 (initialize_low_arch): New function.
14406 * linux-tic6x-low.c (tdesc_tic6x_c64xp_linux)
14407 (tdesc_tic6x_c64x_linux, tdesc_tic6x_c62x_linux): Declare.
14408 (tic6x_usrregs_info): Forward declare.
14409 (tic6x_read_description): New function, based on ...
14410 (tic6x_arch_setup): ... this. Reimplement.
14411 (target_regsets): Rename to ...
14412 (tic6x_regsets): ... this, and make static.
14413 (tic6x_regsets_info, tic6x_usrregs_info, regs_info): New globals.
14414 (tic6x_regs_info): New function.
14415 (the_low_target): Adjust.
14416 (initialize_low_arch): New function.
14417 * linux-xtensa-low.c (tdesc_xtensa): Declare.
14418 (xtensa_fill_gregset, xtensa_store_gregset): Adjust.
14419 (target_regsets): Rename to ...
14420 (xtensa_regsets): ... this, and make static.
14421 (xtensa_regsets_info, xtensa_usrregs_info, regs_info): New
14422 globals.
14423 (xtensa_arch_setup, xtensa_regs_info): New functions.
14424 (the_low_target): Adjust.
14425 (initialize_low_arch): New function.
14426 * linux-nios2-low.c (tdesc_nios2_linux): Declare.
14427 (nios2_arch_setup): Set the current process'es tdesc.
14428 (target_regsets): Rename to ...
14429 (nios2_regsets): ... this.
14430 (nios2_regsets_info, nios2_usrregs_info, regs_info): New globals.
14431 (nios2_regs_info): New function.
14432 (the_low_target): Adjust.
14433 (initialize_low_arch): New function.
a261b8f5
PA
14434 * linux-aarch64-low.c (tdesc_aarch64): Declare.
14435 (aarch64_arch_setup): Set the current process'es tdesc.
14436 (target_regsets): Rename to ...
14437 (aarch64_regsets): ... this.
14438 (aarch64_regsets_info, aarch64_usrregs_info, regs_info): New globals.
14439 (aarch64_regs_info): New function.
14440 (the_low_target): Adjust.
14441 (initialize_low_arch): New function.
3aee8918
PA
14442 * linux-tile-low.c (tdesc_tilegx, tdesc_tilegx32): Declare
14443 globals.
14444 (target_regsets): Rename to ...
14445 (tile_regsets): ... this.
14446 (tile_regsets_info, tile_usrregs_info, regs_info): New globals.
14447 (tile_regs_info): New function.
14448 (tile_arch_setup): Set the current process'es tdesc.
14449 (the_low_target): Adjust.
14450 (initialize_low_arch): New function.
14451 * spu-low.c (tdesc_spu): Declare.
14452 (spu_create_inferior, spu_attach): Set the new process'es tdesc.
14453 * win32-arm-low.c (tdesc_arm): Declare.
14454 (arm_arch_setup): New function.
14455 (the_low_target): Install arm_arch_setup instead of
14456 init_registers_arm.
14457 * win32-i386-low.c (tdesc_i386, tdesc_amd64): Declare.
14458 (init_windows_x86): Rename to ...
14459 (i386_arch_setup): ... this. Set `win32_tdesc'.
14460 (the_low_target): Adjust.
14461 * win32-low.c (win32_tdesc): New global.
14462 (child_add_thread): Don't create the thread cache here.
14463 (do_initial_child_stuff): Set the new process'es tdesc.
14464 * win32-low.h (struct target_desc): Forward declare.
14465 (win32_tdesc): Declare.
14466 * lynx-i386-low.c (tdesc_i386): Declare global.
14467 (lynx_i386_arch_setup): Set `lynx_tdesc'.
14468 * lynx-low.c (lynx_tdesc): New global.
14469 (lynx_add_process): Set the new process'es tdesc.
14470 * lynx-low.h (struct target_desc): Forward declare.
14471 (lynx_tdesc): Declare global.
14472 * lynx-ppc-low.c (tdesc_powerpc_32): Declare global.
14473 (lynx_ppc_arch_setup): Set `lynx_tdesc'.
14474 * nto-low.c (nto_tdesc): New global.
14475 (do_attach): Set the new process'es tdesc.
14476 * nto-low.h (struct target_desc): Forward declare.
14477 (nto_tdesc): Declare.
14478 * nto-x86-low.c (tdesc_i386): Declare.
14479 (nto_x86_arch_setup): Set `nto_tdesc'.
14480
b1fbec62
GB
144812013-06-04 Gary Benson <gbenson@redhat.com>
14482
14483 * server.c (handle_query): Add "augmented-libraries-svr4-read+"
14484 to qSupported response when appropriate.
14485 (handle_qxfer_libraries_svr4): Allow qXfer:libraries-svr4:read
14486 with nonzero-length annex.
14487 * linux-low.c (linux_qxfer_libraries_svr4): Parse and handle
14488 arguments supplied in annex.
14489
d1ec4ce7
DE
144902013-05-31 Doug Evans <dje@google.com>
14491
ac44adcb 14492 PR server/15594
d1ec4ce7
DE
14493 * linux-x86-low.c (ps_get_thread_area): Properly extend address to
14494 64 bits in 64-cross-32 environment.
14495
9b25f2d3
PA
144962013-05-28 Pedro Alves <palves@redhat.com>
14497
14498 * Makefile.in (clean): Remove reference to aarch64-without-fpu.c.
14499 (aarch64-without-fpu.c): Delete rule.
14500 * configure.srv (aarch64*-*-linux*): Remove references to
14501 aarch64-without-fpu.o and aarch64-without-fpu.xml.
14502 * linux-aarch64-low.c (init_registers_aarch64_without_fpu): Remove
14503 declaration.
14504
6740dc9c
PA
145052013-05-24 Pedro Alves <palves@redhat.com>
14506
14507 * server.c (handle_v_cont) <vCont;r>: Use unpack_varlen_hex
14508 instead of strchr/decode_address. Error if the range isn't split
14509 with a ','. Don't assume there's be a ':' in the action.
14510
c2d6af84
PA
145112013-05-23 Yao Qi <yao@codesourcery.com>
14512 Pedro Alves <palves@redhat.com>
14513
14514 * linux-low.c (lwp_in_step_range): New function.
14515 (linux_wait_1): If the thread was range stepping and stopped
14516 outside the stepping range, report the stop to GDB. Otherwise,
14517 continue stepping. Add range stepping debug output.
14518 (linux_set_resume_request): Copy the step range from the resume
14519 request to the lwp.
14520 (linux_supports_range_stepping): New.
14521 (linux_target_ops) <supports_range_stepping>: Set to
14522 linux_supports_range_stepping.
14523 * linux-low.h (struct linux_target_ops)
14524 <supports_range_stepping>: New field.
14525 (struct lwp_info) <step_range_start, step_range_end>: New fields.
14526 * linux-x86-low.c (x86_supports_range_stepping): New.
14527 (the_low_target) <supports_range_stepping>: Set to
14528 x86_supports_range_stepping.
14529 * server.c (handle_v_cont): Handle 'r' action.
14530 (handle_v_requests): Append ";r" if the target supports range
14531 stepping.
14532 * target.h (struct thread_resume) <step_range_start,
14533 step_range_end>: New fields.
14534 (struct target_ops) <supports_range_stepping>:
14535 New field.
14536 (target_supports_range_stepping): New macro.
14537
58794e1a
JB
145382013-05-17 Joel Brobecker <brobecker@adacore.com>
14539
14540 * lynx-low.c (lynx_resume): Fix null_ptid/minus_one_ptid
14541 confusion in comment.
14542
d631c5a7
JB
145432013-05-17 Joel Brobecker <brobecker@adacore.com>
14544
14545 * lynx-low.c (struct process_info_private): New type.
14546 (lynx_add_process): New function.
14547 (lynx_create_inferior, lynx_attach): Replace calls to
14548 add_process by calls to lynx_add_process.
14549 (lynx_resume): If PTID is null, then try using
14550 current_process()->private->last_wait_event_ptid.
14551 Add comments.
14552 (lynx_clear_inferiors): Delete. The contents of that function
14553 has been inlined in lynx_mourn;
14554 (lynx_wait_1): Save the ptid in the process's private data.
14555 (lynx_mourn): Free the process' private data. Replace call
14556 to lynx_clear_inferiors by call to clear_inferiors.
14557
96f7a20f
YQ
145582013-05-17 Yao Qi <yao@codesourcery.com>
14559
14560 * i386-low.c (i386_length_and_rw_bits): Move the comment to
14561 the right place.
14562
db0dfaa0
LM
145632013-05-16 Luis Machado <lgustavo@codesourcery.com>
14564
14565 * linux-low.c: Move definition checks upwards for PT_TEXT_ADDR,
14566 PT_DATA_ADDR and PT_TEXT_END_ADDR. Update comments.
14567 (linux_read_offsets): Remove PT_TEXT_ADDR, PT_DATA_ADDR and
14568 PT_TEXT_END_ADDR guards. Update comments.
14569 (linux_target_op) <read_offsets>: Conditionally define to
14570 linux_read_offsets if the target is UCLIBC and if it defines
14571 PT_TEXT_ADDR, PT_DATA_ADDR and PT_TEXT_END_ADDR.
14572
68f5f838
SL
145732013-05-06 Sandra Loosemore <sandra@codesourcery.com>
14574 Andrew Jenner <andrew@codesourcery.com>
14575
14576 * Makefile.in (SFILES): Add linux-nios2-low.c.
14577 (clean): Add action to delete nios2-linux.c.
14578 (nios2-linux.c): New rule.
14579 * configure.srv: Add nios2*-*-linux*.
14580 * linux-nios2-low.c: New.
14581
1ebff1fd
HAQ
145822013-05-03 Hafiz Abid Qadeer <abidh@codesourcery.com>
14583
14584 * tracepoint.c (cmd_qtinit): Call 'stop_tracing'.
14585
f6150862
HZ
145862013-04-25 Hui Zhu <hui@codesourcery.com>
14587
14588 PR gdb/15186
f6150862
HZ
14589 * ax.c (ax_printf): Add fflush.
14590
614c279d
TT
145912013-04-22 Tom Tromey <tromey@redhat.com>
14592
14593 * Makefile.in (SFILES): Add filestuff.c.
14594 (OBS): Add filestuff.o.
14595 (filestuff.o): New target.
14596 * config.in, configure: Rebuild.
14597 * configure.ac: Check for fdwalk, pipe2.
14598
7d4e5717
PA
145992013-04-17 Pedro Alves <palves@redhat.com>
14600
14601 * configure.ac (USE_THREAD_DB): Delete variable.
14602 (if test "$srv_linux_thread_db" = "yes"): AC_DEFINE USE_THREAD_DB.
14603 Don't AC_SUBST USE_THREAD_DB.
14604 * Makefile.in (INTERNAL_CFLAGS): Remove @USE_THREAD_DB@.
14605 * config.in, configure: Regenerate.
14606
d5c93e41
PA
146072013-04-16 Pedro Alves <palves@redhat.com>
14608
14609 * linux-low.h (struct lwp_info) <thread_known>: Move under
14610 the USE_THREAD_DB #ifdef.
14611
04f5fe89
PA
146122013-04-16 Pedro Alves <palves@redhat.com>
14613
14614 * Makefile.in (INTERNAL_CFLAGS): Add @USE_THREAD_DB@.
14615 (linux-low.o): Delete rule.
14616 * linux-low.h: Always include "gdb_thread_db.h" instead of
14617 conditionally including thread_db.h.
14618 (struct lwp_info) <th>: Guard with #ifdef USE_THREAD_DB instead of
14619 HAVE_THREAD_DB_H.
14620
480b27bf
JK
146212013-04-07 Jan Kratochvil <jan.kratochvil@redhat.com>
14622
14623 * Makefile.in (install-only): Fix make install regression.
14624
43662968
JK
146252013-04-05 Jan Kratochvil <jan.kratochvil@redhat.com>
14626
14627 Convert man pages to texinfo, new gdbinit.5 texinfo page.
14628 * Makefile.in (install-only): Remove $(man1dir) and gdbserver.1
14629 installation.
14630 * gdbserver.1: Remove.
14631
3e74e146
PA
146322013-03-22 Pedro Alves <palves@redhat.com>
14633
14634 * linux-low.c (handle_extended_wait): Don't call
14635 linux_enable_event_reporting.
14636
a8347a2a
TT
146372013-03-15 Tony Theodore <tonyt@logyst.com>
14638
14639 PR build/9098:
14640 * Makefile.in (SHELL): Use @SHELL@.
14641
eeb56fa7
SDJ
146422013-03-14 Sergio Durigan Junior <sergiodj@redhat.com>
14643
14644 * tracepoint.c (cmd_qtv): Initialize `val' with zero, silencing
14645 compiler warning.
14646
4fa7e2ff
JB
146472013-03-13 Joel Brobecker <brobecker@adacore.com>
14648
14649 * linux-low.c (linux_target_ops) [!HAVE_LINUX_BTRACE]:
14650 Remove extraneous NULL element.
14651
8ddb1965
YQ
146522013-03-13 Yao Qi <yao@codesourcery.com>
14653
14654 * tracepoint.c (traceframe_read_tsv): Look for the last matched
14655 'V' block in trace frame.
14656
9accd112
MM
146572013-03-11 Markus Metzger <markus.t.metzger@intel.com>
14658
14659 * target.h (struct target_ops): Add btrace ops.
14660 (target_supports_btrace): New macro.
14661 (target_enable_btrace): New macro.
14662 (target_disable_btrace): New macro.
14663 (target_read_btrace): New macro.
14664 * gdbthread.h (struct thread_info): Add btrace field.
14665 * server.c: Include btrace-common.h.
14666 (handle_btrace_general_set): New function.
14667 (handle_btrace_enable): New function.
14668 (handle_btrace_disable): New function.
14669 (handle_general_set): Call handle_btrace_general_set.
14670 (handle_qxfer_btrace): New function.
14671 (struct qxfer qxfer_packets[]): Add btrace entry.
14672 * inferiors.c (remove_thread): Disable btrace.
14673 * linux-low: Include linux-btrace.h.
14674 (linux_low_enable_btrace): New function.
14675 (linux_low_read_btrace): New function.
14676 (linux_target_ops): Add btrace ops.
14677 * configure.srv (i[34567]86-*-linux*): Add linux-btrace.o.
14678 Add srv_linux_btrace=yes.
14679 (x86_64-*-linux*): Add linux-btrace.o.
14680 Add srv_linux_btrace=yes.
14681 * configure.ac: Define HAVE_LINUX_BTRACE.
14682 * config.in: Regenerated.
14683 * configure: Regenerated.
14684
5cc22e4c
MM
146852013-03-11 Markus Metzger <markus.t.metzger@intel.com>
14686
14687 * server.c (handle_qxfer): Preserve error message if -3 is
14688 returned.
14689 (qxfer): Document the -3 return value.
14690
7c97f91e
MM
146912013-03-11 Markus Metzger <markus.t.metzger@intel.com>
14692
14693 * Makefile.in (SFILES): Add $(srcdir)/common/linux-btrace.c.
14694 (linux_btrace_h): New variable.
14695 (linux-btrace.o): New rule.
14696
be9a119c 146972013-03-08 Stan Shebs <stan@codesourcery.com>
f6f899bf
HAQ
14698 Hafiz Abid Qadeer <abidh@codesourcery.com>
14699
14700 * tracepoint.c (trace_buffer_size): New global.
14701 (DEFAULT_TRACE_BUFFER_SIZE): New define.
14702 (init_trace_buffer): Change to one-argument function. Allocate
14703 trace buffer memory.
14704 (handle_tracepoint_general_set): Call cmd_bigqtbuffer_size to
14705 handle QTBuffer:size packet.
14706 (cmd_bigqtbuffer_size): New function.
14707 (initialize_tracepoint): Call init_trace_buffer with
14708 DEFAULT_TRACE_BUFFER_SIZE.
14709 * server.c (handle_query): Add QTBuffer:size in the
14710 supported packets.
14711
e64f7499
YQ
147122013-03-07 Yao Qi <yao@codesourcery.com>
14713
14714 * tracepoint.c (cur_action, cur_step_action): Make them unsigned.
14715 (cmd_qtfp): Initialize cur_action and cur_step_action 0 instead
14716 of -1.
14717 (cmd_qtsp): Adjust condition. Do post increment.
14718 Set cur_action and cur_step_action back to 0.
14719
f0ae6fc3
PA
147202013-03-07 Jeremy Bennett <jeremy.bennett@embecosm.com>
14721
14722 PR server/15236
14723 * linux-low.c (linux_write_memory): Return early success if LEN is
14724 zero.
14725
b5b0b0af
CV
147262013-03-05 Corinna Vinschen <vinschen@redhat.de>
14727
334ad4a8 14728 * configure.srv: Add x86_64-*-cygwin* as target.
b5b0b0af 14729
589bc927
TT
147302013-02-28 Tom Tromey <tromey@redhat.com>
14731
14732 * configure.ac: Invoke AC_SYS_LARGEFILE.
14733 * configure, config.in: Rebuild.
14734
dfe07582
CV
147352013-02-28 Corinna Vinschen <vinschen@redhat.com>
14736
14737 * win32-low.c: Throughout, fix format strings and casts of
14738 printf-like functions to avoid type related warnings on all
14739 platforms.
14740 (get_child_debug_event): Print dwDebugEventCode as hex since
14741 that's how it's usually documented.
14742
736cd585
YQ
147432013-02-28 Yao Qi <yao@codesourcery.com>
14744
14745 * tracepoint.c (cmd_qtbuffer): Call phex_nz instead of
14746 pulongest.
14747
e1f58301
JW
147482013-02-27 Jiong Wang <jiwang@tilera.com>
14749
14750 * Makefile.in (clean): Remove reg-tilegx.c, reg-tilegx32.c.
14751 (reg-tilegx32.c): New rule.
14752 * configure.srv (tilegx-*-linux*): Add reg-tilegx32.o to srv_regobj.
14753 * linux-tile-low.c (tile_arch_setup): New function. Invoke
14754 different register info initializer according to elf class.
14755 (init_registers_tilgx32): New function. The tilegx32 register info
14756 initializer.
14757 (tile_fill_gregset): Use "uint_reg_t" to represent register size.
14758 (tile_store_gregset): Likewise.
14759
d171ca78
YQ
147602013-02-27 Yao Qi <yao@codesourcery.com>
14761
14762 * server.c (process_point_options): Print debug message when
14763 debug_threads is true.
14764
282bbdf3
YQ
147652013-02-26 Yao Qi <yao@codesourcery.com>
14766
14767 * tracepoint.c (cmd_qtbuffer): Don't set '\0' in OWN_BUF.
14768
aca22551
PA
147692013-02-19 Pedro Alves <palves@redhat.com>
14770 Kai Tietz <ktietz@redhat.com>
14771
14772 PR gdb/15161
14773
14774 * server.c (handle_query) <CRC check>: Use unpack_varlen_hex
14775 instead of strtoul to extract address from packet.
14776 (process_serial_event) <'z'>: Likewise.
14777
4f3cee1c
YQ
147782013-02-18 Yao Qi <yao@codesourcery.com>
14779
14780 * linux-bfin-low.c (the_low_target): Use NULL instead of 0.
14781
8e1d55a3
PA
147822013-02-14 Pedro Alves <palves@redhat.com>
14783
14784 Plug memory leak.
14785
14786 * tracepoint.c (cmd_qtnotes): Free TRACING_USER_NAME,
14787 TRACING_NOTES and TRACING_STOP_NOTE before clobbering.
14788
458820da
PA
147892013-02-14 Pedro Alves <palves@redhat.com>
14790
14791 * tracepoint.c (cmd_qtdpsrc): Use savestring.
14792
baea0dae
PA
147932013-02-14 Pedro Alves <palves@redhat.com>
14794
14795 * tracepoint.c (save_string): Delete.
14796 (add_tracepoint_action): Use savestring instead of save_string.
14797
0b1afbb3
PA
147982013-02-12 Pedro Alves <palves@redhat.com>
14799
14800 * linux-xtensa-low.c: Ditto.
14801 * xtensa-xtregs.c: Ditto.
14802
8a4ac37e
PA
148032013-02-12 Sanimir Agovic <sanimir.agovic@intel.com>
14804
14805 * thread-db.c (thread_db_get_tls_address): NULL pointer check
14806 thread_db.
14807
148de6bb
MS
148082013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
14809
14810 * linux-aarch64-low.c (aarch64_arch_setup): Clamp
14811 aarch64_num_wp_regs and aarch64_num_bp_regs to
14812 AARCH64_HWP_MAX_NUM and AARCH64_HBP_MAX_NUM respectively.
14813
55fac6e0
MS
148142013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
14815
14816 * linux-aarch64-low.c (ps_get_thread_area): Replace
14817 PTRACE_GET_THREAD_AREA with PTRACE_GETREGSET.
14818
176eb98c
MS
148192013-02-04 Jim MacArthur <jim.macarthur@arm.com>
14820 Marcus Shawcroft <marcus.shawcroft@arm.com>
14821 Nigel Stephens <nigel.stephens@arm.com>
14822 Yufeng Zhang <yufeng.zhang@arm.com>
14823
14824 * Makefile.in (clean): Remove aarch64.c and aarch64-without-fpu.c.
14825 (aarch64.c, aarch64-without-fpu.c): New targets.
14826 * configure.srv (aarch64*-*-linux*): New.
14827 * linux-aarch64-low.c: New file.
14828
56f7af9c
MS
148292013-02-04 Marcus Shawcroft <marcus.shawcroft@arm.com>
14830
43aaf8b6 14831 * linux-low.c (handle_extended_wait, linux_create_inferior)
56f7af9c
MS
14832 (linux_attach_lwp_1, linux_kill_one_lwp, linux_attach_one_lwp)
14833 (dequeue_one_deferred_signal, linux_resume_one_thread)
14834 (fetch_register, linux_write_memory, linux_enable_event_reporting)
14835 (linux_tracefork_grandchild, linux_test_for_tracefork)
14836 (linux_read_offsets, linux_xfer_siginfo, linux_xfer_siginfo): Add
14837 PTRACE_ARG3_TYPE and PTRACE_ARG4_TYPE cast to ptrace arguments
14838 where the argument is 0.
14839
60f662b0
YQ
148402013-01-25 Yao Qi <yao@codesourcery.com>
14841
14842 * event-loop.c: Include "queue.h".
14843 (gdb_event_p): New typedef.
14844 (struct gdb_event) <next_event>: Remove.
14845 (event_queue): Change to QUEUE(gdb_event_p).
14846 (async_queue_event): Remove.
14847 (gdb_event_xfree): New.
14848 (initialize_event_loop): New.
14849 (process_event): Use API from QUEUE.
14850 (wait_for_event): Likewise.
14851 * server.c (main): Call initialize_event_loop.
14852 * server.h (initialize_event_loop): Declare.
14853
5ae4861a
YQ
148542013-01-18 Yao Qi <yao@codesourcery.com>
14855
14856 * ax.h (struct eval_agent_expr_context): New.
14857 (gdb_eval_agent_expr): Update declaration.
14858 * ax.c (gdb_eval_agent_expr): Remove argument REGCACHE and
14859 TFRAME. Add new argument CTX.
14860 * server.h (struct eval_agent_expr_context): Declare.
14861 (agent_mem_read, agent_tsv_read): Update declaration.
14862 (agent_mem_read_string): Likewise.
14863 * tracepoint.c (eval_tracepoint_agent_expr): Remove.
14864 (add_traceframe_block): Add new argument TPOINT.
14865 Increase TPOINT->traceframe_usage.
14866 (do_action_at_tracepoint): Call gdb_eval_agent_expr instead of
14867 eval_tracepoint_agent_expr.
14868 (condition_true_at_tracepoint): Likewise.
14869 (agent_mem_read): Remove argument TFRAME. Add argument CTX.
14870 (agent_mem_read_string, agent_tsv_read): Likewise.
14871
85e00e85
YQ
148722013-01-16 Yao Qi <yao@codesourcery.com>
14873
14874 * linux-low.c (linux_resume_one_lwp): Don't check
14875 'lwp->bp_reinsert != 0'.
14876
4039cf45
JB
148772013-01-07 Joel Brobecker <brobecker@adacore.com>
14878 Pedro Alves <palves@redhat.com>
14879
14880 * lynx-low.c (ptrace_request_to_str): Define a temporary
14881 macro and use it to simplify this function's implementation.
14882
9044dee2
JB
148832013-01-07 Joel Brobecker <brobecker@adacore.com>
14884
14885 * lynx-low.c (lynx_resume): Call perror_with_name if lynx_ptrace
14886 sets errno.
14887
e6352c8f
JB
148882013-01-07 Joel Brobecker <brobecker@adacore.com>
14889
14890 * configure.srv (i[34567]86-*-lynxos*): Set srv_xmlfiles.
14891
50681a27
JB
148922013-01-07 Joel Brobecker <brobecker@adacore.com>
14893
14894 * configure.srv (powerpc-*-lynxos*): Set srv_xmlfiles.
14895
3f6e77ef
JB
148962013-01-07 Joel Brobecker <brobecker@adacore.com>
14897
14898 * lynx-low.c (lynx_resume): Use the resume_info parameter
14899 to determine the ptid for the lynx_ptrace call, unless
14900 it is equal to minus_one_ptid, in which case we use the
14901 ptid of the current_inferior.
14902 (lynx_wait_1): After having received a thread create/exit
14903 event, resume the inferior's execution using the signaling
14904 thread's ptid, rather than the old ptid.
14905
7fda33ae
JB
149062013-01-07 Joel Brobecker <brobecker@adacore.com>
14907
14908 * lynx-low.c (lynx_resume): Delete variable ret.
14909
b9786c74
JB
149102013-01-01 Joel Brobecker <brobecker@adacore.com>
14911
14912 * gdbreplay.c (gdbreplay_version): Update copyright year.
14913 * server.c (gdbserver_version): Likewise.
14914
8b93d60f
JB
149152012-12-17 Joel Brobecker <brobecker@adacore.com>
14916
14917 * lynx-low.c (lynx_wait_1): Add debug trace before adding
14918 new thread.
14919
037335a7
JB
149202012-12-17 Joel Brobecker <brobecker@adacore.com>
14921
14922 * lynx-low.c (ptrace_request_to_str): Add handling for
14923 PTRACE_GETTRACESIG.
14924
52d4cbd8
JB
149252012-12-17 Joel Brobecker <brobecker@adacore.com>
14926
14927 * lynx-low.c (lynx_attach): Delete variable new_process.
14928
ab8f6ca9
JB
149292012-12-17 Joel Brobecker <brobecker@adacore.com>
14930
14931 * lynx-low.c (lynx_create_inferior): Delete variable
14932 new_process.
14933
78cbc024
JB
149342012-12-17 Joel Brobecker <brobecker@adacore.com>
14935
14936 * lynx-low.c (ptrace_request_to_str): Do not handle
14937 PTRACE_GETTHREADLIST if this macro does not exist.
14938
14a00470
YQ
149392012-12-15 Yao Qi <yao@codesourcery.com>
14940
14941 * Makefile.in (OBS): Add notif.o.
14942 * notif.c, notif.h: New.
14943 * server.c: Include "notif.h".
14944 (struct vstop_notif) <next>: Remove.
14945 <base>: New field.
14946 (queue_stop_reply): Update.
14947 (push_event, send_next_stop_reply): Remove.
14948 (discard_queued_stop_replies): Update.
14949 (notif_stop): New variable.
14950 (handle_v_stopped): Remove.
14951 (handle_v_requests): Don't call handle_v_stopped. Call
14952 handle_ack_notif instead.
14953 (queue_stop_reply_callback): Call notif_event_enque instead
14954 of queue_stop_reply.
14955 (handle_status): Don't call send_next_stop_reply, call
14956 notif_write_event instead.
14957 (kill_inferior_callback): Likewise.
14958 (detach_or_kill_inferior_callback): Likewise.
14959 (main): Call initialize_notif.
14960 (process_serial_event): Call QUEUE_is_empty.
14961 (handle_target_event): Call notif_push instead of push event.
14962 * server.h (push_event): Remove declaration.
14963
61c125b9
TT
149642012-12-10 Tom Tromey <tromey@redhat.com>
14965
14966 * Makefile.in (DEPMODE, DEPDIR, depcomp, COMPILE.pre)
14967 (COMPILE.post, COMPILE, POSTCOMPILE, IPAGENT_COMPILE): New
14968 macros.
14969 (.c.o): Rewrite.
14970 (ax-ipa.o, tracepoint-ipa.o, utils-ipa.o, format-ipa.o)
14971 (common-utils-ipa.o, remote-utils-ipa.o, regcache-ipa.o)
14972 (i386-linux-ipa.o, linux-i386-ipa.o, linux-amd64-ipa.o)
14973 (amd64-linux-ipa.o, ax.o): Rewrite.
14974 (event-loop.o, hostio.o, hostio-errno.o, inferiors.o, mem-break.o)
14975 (proc-service.o, regcache.o, remote-utils.o, server.o, target.o)
14976 (thread-db.o, tracepoint.o, utils.o, gdbreplay.o, dll.o): Remove.
14977 (signals.o, linux-procfs.o, linux-ptrace.o, common-utils.o, vec.o)
14978 (gdb_vecs.o, xml-utils.o, linux-osdata.o, ptid.o, buffer.o)
14979 (format.o, agent.o, vasprintf.o, vsnprintf.o): Rewrite.
14980 (i386-low.o, i387-fp.o, linux-low.o, linux-arm-low.o)
14981 (linux-bfin-low.o, linux-cris-low.o, linux-crisv32-low.o)
14982 (linux-ia64-low.o, linux-m32r-low.o, linux-mips-low.o)
14983 (linux-ppc-low.o, linux-s390-low.o, linux-sh-low.o)
14984 (linux-tic6x-low.o, linux-x86-low.o, linux-xtensa-low.o)
14985 (linux-tile-low.o, lynx-low.o, lynx-ppc-low.o, nto-low.o)
14986 (nto-x86-low.o, linux-low.o, win32-low.o, win32-arm-low.o)
14987 (win32-i386-low.o, spu-low.o, reg-arm.o, arm-with-iwmmxt.o)
14988 (arm-with-vfpv2.o, arm-with-vfpv3.o, arm-with-neon.o, reg-bfin.o)
14989 (reg-cris.o, reg-crisv32.o, i386.o, i386-linux.o, i386-avx.o)
14990 (i386-avx-linux.o, i386-mmx.o, i386-mmx-linux.o, reg-ia64.o)
14991 (reg-m32r.o, reg-m68k.o, reg-cf.o, mips-linux.o, mips-dsp-linux.o)
14992 (mips64-linux.o, mips64-dsp-linux.o, powerpc-32.o, powerpc-32l.o)
14993 (powerpc-altivec32l.o, powerpc-cell32l.o, powerpc-vsx32l.o)
14994 (powerpc-isa205-32l.o, powerpc-isa205-altivec32l.o)
14995 (powerpc-isa205-vsx32l.o, powerpc-e500l.o, powerpc-64l.o)
14996 (powerpc-altivec64l.o, powerpc-cell64l.o, powerpc-vsx64l.o)
14997 (powerpc-isa205-64l.o, powerpc-isa205-altivec64l.o)
14998 (powerpc-isa205-vsx64l.o, s390-linux32.o, s390-linux32v1.o)
14999 (s390-linux32v2.o, s390-linux64.o, s390-linux64v1.o)
15000 (s390-linux64v2.o, s390x-linux64.o, s390x-linux64v1.o)
15001 (s390x-linux64v2.o, tic6x-c64xp-linux.o, tic6x-c64x-linux.o)
15002 (tic6x-c62x-linux.o, reg-sh.o, reg-sparc64.o, reg-spu.o, amd64.o)
15003 (amd64-linux.o, amd64-avx.o, amd64-avx-linux.o, x32.o)
15004 (x32-linux.o, x32-avx.o, x32-avx-linux.o, reg-xtensa.o)
15005 (reg-tilegx.o): Remove.
15006 (all_object_files): New macro.
15007 Include .deps files.
15008 * aclocal.m4, configure: Rebuild.
15009 * acinclude.m4: Include depstand.m4, lead-dot.m4.
15010 * configure.ac: Invoke ZW_CREATE_DEPDIR,
15011 ZW_PROG_COMPILER_DEPENDENCIES. Compute GMAKE condition.
15012
e90e9ad9
TT
150132012-12-05 Tom Tromey <tromey@redhat.com>
15014
15015 PR gdb/14917:
15016 * server.h (current_insn_ptr, emit_error): Declare 'extern'.
15017
02d403bf 150182012-11-28 Markus Metzger <markus.t.metzger@intel.com>
945bf713
MM
15019
15020 * configure.ac: Check for linux/perf_event.h.
15021 * config.in: Regenerated.
15022 * configure: Regenerated.
15023
0270a750
PA
150242012-11-26 Maxime Villard <rustyBSD@gmx.fr>
15025
15026 * hostio.c (handle_readlink): Decrease buffer size
15027 parameter passed to readlink by one byte.
15028
8c29b58e
YQ
150292012-11-26 Yao Qi <yao@codesourcery.com>
15030
15031 * configure.ac (build_warnings): Append '-Wempty-body'.
15032 * configure: Regenerated.
15033 * linux-low.c (linux_create_inferior): Use braces for empty 'if'
15034 body.
15035
8bdce1ff
PM
150362012-11-15 Pierre Muller <muller@sourceware.org>
15037
15038 * configure.ac (AC_CHECK_HEADERS): Add wait.h header.
15039 * config.in: Regenerate.
15040 * configure: Regenerate.
15041 * linux-low.c: Use "gdb_stat.h" header instead of <sys/stat.h> header.
15042 Use "gdb_wait.h" header instead of <sys/wait.h> header.
15043 * lynx-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
15044 * remote-utils.c: Use "gdb_stat.h" header instead of <sys/stat.h>
15045 header.
15046 * server.c: Remove HAVE_WAIT_H conditional. Use "gdb_wait.h" header
15047 instead of <sys/wait.h> header.
15048 * spu-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
15049
02d403bf 150502012-11-13 Markus Metzger <markus.t.metzger@intel.com>
3ba6ad0f
MM
15051
15052 * Makefile.in: (INTERNAL_CFLAGS): Add -DGDBSERVER
15053 (various make rules): Remove -DGDBSERVER
15054
fbd5db48
YQ
150552012-11-09 Yao Qi <yao@codesourcery.com>
15056
15057 * spu-low.c (current_ptid): Move it to ..
15058 * gdbthread.h: ... here. New.
15059 * remote-utils.c (read_ptid): Use macro 'current_ptid'.
15060 * server.c (myresume, process_serial_event): Likewise.
15061 * thread-db.c (thread_db_find_new_threads): Likewise.
15062 * tracepoint.c (run_inferior_command): Likewise.
15063
b3dc46ff
AB
150642012-10-01 Andrew Burgess <aburgess@broadcom.com>
15065
15066 * server.c (handle_search_memory_1): Include access length in
15067 warning message.
15068
07c04788
HPN
150692012-09-05 Michael Brandt <michael.brandt@axis.com>
15070
15071 * linux-crisv32-low.c: Fix compile errors.
15072
918d227b
YQ
150732012-09-04 Yao Qi <yao@codesourcery.com>
15074
15075 * tracepoint.c (cmd_qtsv): Adjust debug message.
15076 Don't check CUR_TPOINT.
15077
18c1b81a
YQ
150782012-08-28 Yao Qi <yao@codesourcery.com>
15079
15080 * ax.c, tracepoint.c: Replace ATTR_FORMAT with ATTRIBUTE_PRINTF.
15081 * server.h: Include 'libiberty.h' and 'ansidecl.h'.
15082 (ATTR_NORETURN, ATTR_FORMAT, ATTR_MALLOC): Remove.
15083 Remove declarations of xmalloc, xreallloc, xstrdup and
15084 freeargv.
15085 * Makefile.in (libiberty_h): New.
15086 (server_h): Append dependencies 'libiberty.h' and 'ansidecl.h'.
15087 (linux-bfin-low.o): Append dependency 'libiberty.h'.
15088
dc82f37b
YQ
150892012-08-23 Yao Qi <yao@codesourcery.com>
15090
15091 * server.h: Remove declaration of 'xsnprintf'.
15092
406b1477
KS
150932012-08-22 Keith Seitz <keiths@redhat.com>
15094
15095 * server.h: Include build-gnulib-gbserver/config.h.
15096 * gdbreplay.c: Likewise.
15097
e6712ff1
DE
150982012-08-08 Doug Evans <dje@google.com>
15099
15100 * Makefile.in (SFILES): Add gdb_vecs.c.
15101 (OBS): Add gdb_vecs.o.
15102 (gdb_vecs_h, host_defs_h): New variables.
15103 (thread-db.o): Add $(gdb_vecs_h) dependency.
15104 (gdb_vecs.o): New rule.
15105 * thread-db.c: #include "gdb_vecs.h".
15106 (thread_db_load_search): Use a vector to iterate over path elements.
15107 Handle text appearing after "$pdir".
15108
15109 * configure.ac: Add check for strstr.
15110 * config.in: Regenerate.
15111 * configure: Regenerate.
15112
7c3270ae
UW
151132012-08-02 Ulrich Weigand <ulrich.weigand@linaro.org>
15114
15115 * hostio.c (handle_pread): If pread fails, fall back to attempting
15116 lseek/read.
15117 (handle_pwrite): Likewise for pwrite.
15118
b62e2b27
UW
151192012-08-01 Ulrich Weigand <ulrich.weigand@linaro.org>
15120
15121 * linux-arm-low.c (arm_linux_hw_point_initialize): Distinguish
15122 between unsupported TYPE and unimplementable ADDR/LEN combination.
15123 (arm_insert_point): Act on new return value.
15124
78a99e91
PA
151252012-07-31 Pedro Alves <palves@redhat.com>
15126
15127 * server.c (process_point_options): Only skip tokens if we find
15128 one that is unrecognized. Don't treat 'X' specially while
15129 skipping unrecognized tokens.
15130
fcf303ab
UW
151312012-07-30 Ulrich Weigand <ulrich.weigand@linaro.org>
15132
15133 * linux-arm-low.c (arm_linux_hw_point_initialize): Do not attempt
15134 to 4-byte-align HW breakpoint addresses for Thumb.
15135
7255706c
YQ
151362012-07-27 Yao Qi <yao@codesourcery.com>
15137
15138 PR remote/14161.
15139
15140 * server.h: Declare gdb_agent_about_to_close.
15141 * target.c (kill_inferior): Include "agent.h".
15142 New. Send command 'kill'.
15143 * target.h (kill_inferior): Removed macro.
15144 * tracepoint.c (gdb_agent_about_to_close): New.
15145 (gdb_agent_helper_thread): Handle command 'close'.
15146 Wait endlessly until the inferior stops.
15147 Install gdb_agent_remove_socket to atexit hook.
15148 (agent_socket_name): New static variable.
15149 (gdb_agent_socket_init): Replace local variable 'name' with
15150 'agent_socket_name'.
15151 (gdb_agent_remove_socket): New.
15152
5a3f286f
YQ
151532012-07-27 Yao Qi <yao@codesourcery.com>
15154
15155 * server.c (process_point_options): Stop at 'X' when parsing.
15156
961bd387
ME
151572012-07-19 Michael Eager <eager@eagercon.com>
15158
a261b8f5 15159 * i386-low.c (Z_packet_to_hw_type): Add Z_PACKET_HW_BP, translate
961bd387
ME
15160 to hw_execute.
15161 * linux-x86-low.c (x86_insert_point, x86_remove_point):
15162 Call i386_low_insert_watchpoint, i386_low_remove_watchpoint to add/del
15163 hardware breakpoint.
15164
aa7c7447
JK
151652012-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
15166
15167 * gdbserver/linux-low.c (initialize_low): Call
15168 linux_ptrace_init_warnings.
15169
7f216e7c
DE
151702012-07-02 Doug Evans <dje@google.com>
15171
15172 * mem-break.c (gdb_no_commands_at_breakpoint): Fix cast from
15173 pointer to int.
15174
d3ce09f5
SS
151752012-07-02 Stan Shebs <stan@codesourcery.com>
15176
15177 * Makefile.in (WARN_CFLAGS_NO_FORMAT): Define.
15178 (ax.o): Add it to build rule.
15179 (ax-ipa.o): Ditto.
15180 (OBS): Add format.o.
15181 (IPA_OBS): Add format.o.
15182 * server.c (handle_query): Claim support for breakpoint commands.
15183 (process_point_options): Add command case.
15184 (process_serial_event): Leave running if there are printfs in
15185 effect.
15186 * mem-break.h (any_persistent_commands): Declare.
15187 (add_breakpoint_commands): Declare.
15188 (gdb_no_commands_at_breakpoint): Declare.
15189 (run_breakpoint_commands): Declare.
15190 * mem-break.c (struct point_command_list): New struct.
15191 (struct breakpoint): New field command_list.
15192 (any_persistent_commands): New function.
15193 (add_commands_to_breakpoint): New function.
15194 (add_breakpoint_commands): New function.
15195 (gdb_no_commands_at_breakpoint): New function.
15196 (run_breakpoint_commands): New function.
15197 * linux-low.c (linux_wait_1): Test for and run breakpoint commands
15198 locally.
15199 * ax.c: Include format.h.
15200 (ax_printf): New function.
15201 (gdb_eval_agent_expr): Add printf opcode.
15202
2f8f6aed
YQ
152032012-06-13 Yao Qi <yao@codesourcery.com>
15204
15205 * server.c (start_inferior): Remove duplicated writes to fields
15206 'last_resume_kind' and 'last_status' of 'current_inferior'.
15207
0c9070b3
YQ
152082012-06-12 Yao Qi <yao@codesourcery.com>
15209 Pedro Alves <palves@redhat.com>
15210
15211 * linux-low.c (linux_set_resume_request): Simplify predicate. Add
15212 comment.
15213 * server.c (handle_v_cont): Extend comment.
15214
c52daf70
YQ
152152012-06-11 Yao Qi <yao@codesourcery.com>
15216
15217 * linux-low.c (linux_attach): Add 'static'.
15218
d38bbb0a
YQ
152192012-06-06 Yao Qi <yao@codesourcery.com>
15220
15221 * ax.c (gdb_eval_agent_expr): Print `top' in hex.
15222
89dc0afd
JK
152232012-06-01 Jan Kratochvil <jan.kratochvil@redhat.com>
15224
15225 Fix gcc -flto compilation warning.
15226 * server.c (main): Make variable multi_mode and attach volatile.
15227
75f62ce7
TJB
152282012-05-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
15229
15230 * linux-low.c (get_r_debug): Disable code using DT_MIPS_RLD_MAP
15231 if the platform doesn't know about it.
15232
65f479b6
PA
152332012-05-30 Jeff Kenton <jkenton@tilera.com>
15234
15235 * Makefile.in (SFILES): Add linux-tile-low.c.
15236 (linux-tile-low.o, reg-tilegx.o, reg-tilegx.c): New rules.
15237 * configure.srv: Handle tilegx-*-linux*.
15238 * linux-tile-low.c: New file.
15239
0c5bf5a9
JK
152402012-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
15241
15242 * linux-low.c (linux_qxfer_libraries_svr4): Return -1 if R_DEBUG is -1.
15243
a493e3e2
PA
152442012-05-24 Pedro Alves <palves@redhat.com>
15245
15246 PR gdb/7205
15247
43aaf8b6 15248 Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.
a493e3e2 15249
2ea28649
PA
152502012-05-24 Pedro Alves <palves@redhat.com>
15251
15252 PR gdb/7205
15253
15254 Replace target_signal with gdb_signal throughout.
15255
8d409d16
MR
152562012-05-22 Maciej W. Rozycki <macro@codesourcery.com>
15257
15258 * linux-low.c (linux_store_registers): Avoid the copying sequence
15259 when no data has been retrieved by ptrace.
15260
23512c01
MGD
152612012-05-22 Will Deacon <will.deacon@arm.com>
15262
15263 * linux-low (__UCLIBC__ && !(__UCLIBC_HAS_MMU__ || __ARCH_HAS_MMU__)):
15264 Include asm/ptrace.h.
15265 (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define only if not
15266 already defined.
15267
4934b29e
MR
152682012-05-21 Maciej W. Rozycki <macro@codesourcery.com>
15269
15270 * linux-low.c (linux_store_registers): Don't re-retrieve data
15271 with ptrace that has already been obtained from /proc. Always
15272 copy any data retrieved with ptrace to the buffer supplied.
15273
bde24c0a
PA
152742012-05-11 Yao Qi <yao@codesourcery.com>
15275 Pedro Alves <palves@redhat.com>
15276
15277 * linux-low.c (enum stopping_threads_kind): New.
15278 (stopping_threads): Change type to `enum stopping_threads_kind'.
15279 (handle_extended_wait): If stopping and suspending threads, leave
15280 the new_lwp suspended too.
15281 (linux_wait_for_event): Adjust.
15282 (stop_all_lwps): Set `stopping_threads' to
15283 STOPPING_AND_SUSPENDING_THREADS or STOPPING_THREADS depending on
15284 whether we're suspending threads or just stopping them. Assert no
15285 recursion happens.
15286
623b6bdf
YQ
152872012-04-29 Yao Qi <yao@codesourcery.com>
15288
15289 * server.h: Move some code to ...
15290 * gdbthread.h: ... here. New.
15291 * Makefile.in (inferiors.o, regcache.o): Depends on gdbthread.h
15292 (remote-utils.o, server.o, target.o tracepoint.o): Likewise.
15293 (nto-low.o, win32-low.o): Likewise.
15294 * inferiors.c, linux-low.h, nto-low.c: Include gdbthread.h.
15295 * regcache.c, remote-utils.c, server.c: Likewise.
15296 * target.c, tracepoint.c, win32-low.c: Likewise.
15297
f15f9948
TJB
152982012-04-24 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
15299
15300 * linux-low.h (PTRACE_ARG3_TYPE): Move macro from linux-low.c.
15301 (PTRACE_ARG4_TYPE): Likewise.
15302 (PTRACE_XFER_TYPE): Likewise.
15303 * linux-arm-low.c (arm_prepare_to_resume): Cast third argument of
15304 ptrace to PTRACE_ARG3_TYPE.
15305 * linux-low.c (PTRACE_ARG3_TYPE): Move macro to linux-low.h.
15306 (PTRACE_ARG4_TYPE): Likewise.
15307 (PTRACE_XFER_TYPE): Likewise.
15308 (linux_detach_one_lwp): Cast fourth argument of
15309 ptrace to long then PTRACE_ARG4_TYPE.
15310 (regsets_fetch_inferior_registers): Cast third argument of
15311 ptrace to long then PTRACE_ARG3_TYPE.
15312 (regsets_store_inferior_registers): Likewise.
15313
38ea300a
PA
153142012-04-20 Pedro Alves <palves@redhat.com>
15315
15316 * configure: Regenerate.
15317
c971b7fa
PA
153182012-04-19 Pedro Alves <palves@redhat.com>
15319
43aaf8b6 15320 * Makefile.in (GNULIB_BUILDDIR): New.
c971b7fa 15321 (LIBGNU, INCGNU, GNULIB_H): Adjust.
43aaf8b6
PA
15322 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): New.
15323 (all, install-only, uninstall, clean-info, all-lib, clean): No
15324 longer pass GNULIB_FLAGS_TO_PASS. Use subdir_do.
15325 (maintainer-clean realclean distclean): Use subdir_do.
15326 (subdir_do): New.
15327 (gnulib/import/Makefile): Adjust. Replace gnulib/import with
c971b7fa 15328 $(GNULIB_BUILDDIR). Don't pass argument to config.status.
43aaf8b6
PA
15329 * acinclude.m4: Include acx_configure_dir.m4.
15330 * configure.ac: Remove gl_EARLY, gl_INIT, and AM_INIT_AUTOMAKE
15331 calls. Call AC_PROG_RANLIB. Configure gnulib using
15332 ACX_CONFIGURE_DIR.
15333 (GNULIB): New.
15334 (GNULIB_STDINT_H): Adjust.
15335 (AC_OUTPUT): Don't output gnulib/Makefile anymore.
15336 * gdbreplay.c: Include build-gnulib/config.h.
15337 * server.h: Likewise.
15338 * aclocal.m4: Regenerate.
15339 * config.in: Regenerate.
15340 * configure: Regenerate.
c971b7fa 15341
809277f8
PA
153422012-04-19 Pedro Alves <palves@redhat.com>
15343
15344 * Makefile.in (LIBGNU, INCGNU): Adjust.
15345 (GNULIB_FLAGS_TO_PASS, GNULIB_H): Adjust.
15346 (all, install-only, uninstall, clean-info, all-lib, clean)
15347 (maintainer-clean, Makefile, gnulib/Makefile): Adjust.
15348 * configure.ac: Adjust AC_OUTPUT output.
15349 * aclocal.m4: Regenerate.
15350 * configure: Regenerate.
15351
fd9bb8b8
PA
153522012-04-19 Pedro Alves <palves@redhat.com>
15353
15354 * Makefile.in (generated_files): New.
15355 (server_h): Remove the explicit dependency on config.h, and depend
15356 on $generated_files.
15357
1c298c66
PA
153582012-04-19 Pedro Alves <palves@redhat.com>
15359
15360 * Makefile.in (INCGNU): Add -Ignulib.
15361
57c4b50b
PA
153622012-04-19 Pedro Alves <palves@redhat.com>
15363
15364 * Makefile.in (GNULIB_INCLUDE_DIR): Rename to ...
15365 (INCGNU): ... this, and spell out -I here.
15366 (GNULIB_LIB): Rename to ...
15367 (LIBGNU): ... this.
15368 (INCLUDE_CFLAGS, gdbserver$(EXEEXT), $(GNULIB_LIB) rule): Adjust.
15369
1030e047
PA
153702012-04-19 Pedro Alves <palves@redhat.com>
15371
15372 * config.in: Regenerate.
15373
447d4319
PA
153742012-04-19 Pedro Alves <palves@redhat.com>
15375
15376 * configure.ac: Remove AC_CHECK_DECLS check for memmem.
15377 * server.h (memmem): Remove declaration.
15378 * config.in: Regenerate.
15379 * configure: Regenerate.
15380
aad9eab9
YQ
153812012-04-19 Yao Qi <yao@codesourcery.com>
15382
15383 * Makefile.in (SFILES): Add common/vec.c.
15384 (OBS): Add vec.o.
15385 (vec.o): New rule.
15386
3e10640f
YQ
153872012-04-19 Yao Qi <yao@codesourcery.com>
15388
15389 * remote-utils.c (prepare_resume_reply): Replace with macro
15390 target_core_of_thread.
15391 * server.c (handle_qxfer_threads_proper): Likewise.
15392 * target.h (traget_core_of_thread): New macro.
15393
71622373
PA
153942012-04-18 Pedro Alves <palves@redhat.com>
15395
15396 * aclocal.m4: Regenerate.
15397 * configure: Regenerate.
15398
80d26939
YQ
153992012-04-16 Yao Qi <yao@codesourcery.com>
15400
15401 * tracepoint.c (cmd_qtstart): Download tracepoints even when they are
15402 duplicated on address.
15403
42476b70
YQ
154042012-04-16 Yao Qi <yao@codesourcery.com>
15405
15406 * tracepoint.c (COPY_FIELD_TO_BUF): New macro.
15407 (struct tracepoint_action_ops) <send>: New field.
15408 (m_tracepoint_action_send, r_tracepoint_action_send): New.
15409 (agent_expr_send, x_tracepoint_action_send): New.
15410 (l_tracepoint_action_send): New.
15411 (cmd_qtdp): Download and install tracepoint
15412 according to `use_agent'.
15413 (run_inferior_command): Add one more parameter `len'.
15414 Update callers.
15415 (tracepoint_send_agent): New.
15416 (cmd_qtdp, cmd_qtstart): Call tracepoint_send_agent.
15417
7bc83639
YQ
154182012-04-16 Yao Qi <yao@codesourcery.com>
15419
15420 * tracepoint.c (download_tracepoints): Moved to ...
15421 (cmd_qtstart): ... here.
15422
5f18041e
YQ
154232012-04-14 Yao Qi <yao@codesourcery.com>
15424
15425 * tracepoint.c: Include inttypes.h.
15426 (struct collect_memory_action): Use sized types.
15427 (struct tracepoint): Likewise.
15428 (cmd_qtdp, stop_tracing): Update print specifiers.
15429 (cmd_qtp, response_tracepoint): Likewise.
15430 (collect_data_at_tracepoint): Likewise.
15431 (collect_data_at_step): Likewise.
15432
55a8c076
YQ
154332012-04-14 Yao Qi <yao@codesourcery.com>
15434
15435 Import gnulib module inttypes.
15436 * aclocal.m4, config.in, configure: Regenerated.
15437
dc750257
YQ
154382012-04-14 Yao Qi <yao@codesourcery.com>
15439
15440 * Makefile.in (maintainer-clean, realclean, distclean): Remove
15441 Makefile and config.status at last.
15442
0ab5faf9
YQ
154432012-04-13 Yao Qi <yao@codesourcery.com>
15444
15445 * tracepoint.c: Include stdint.h unconditionally.
15446
18f5fd81
TJB
154472012-04-13 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
15448
15449 * acinclude.m4 (GDBSERVER_HAVE_THREAD_DB_TYPE): New macro based
15450 on BFD_HAVE_SYS_PROCFS_TYPE.
15451 * configure.ac: Look for lwpid_t and psaddr_t in libthread_db.h.
15452 * configure: Regenerate.
15453 * config.in: Likewise.
15454
4d47af5c
L
154552012-04-13 H.J. Lu <hongjiu.lu@intel.com>
15456
15457 * Makefile.in (clean): Also remove x32.c x32-linux.c
15458 x32-avx.c x32-avx-linux.c.
15459 (x32.o): New target.
15460 (x32.c): Likewise.
15461 (x32-linux.o): Likewise.
15462 (x32-linux.c): Likewise.
15463 (x32-avx.o): Likewise.
15464 (x32-avx.c): Likewise.
15465 (x32-avx-linux.o): Likewise.
15466 (x32-avx-linux.c): Likewise.
15467
15468 * configure.srv (srv_amd64_regobj): Add x32.o x32-avx.o.
15469 (srv_amd64_linux_regobj): Add x32-linux.o x32-avx-linux.o.
15470 (srv_i386_64bit_xmlfiles): Add i386/x32-core.xml.
15471 (srv_amd64_xmlfiles): Add i386/x32.xml i386/x32-avx.xml.
15472 (srv_amd64_linux_xmlfiles): Add i386/x32-linux.xml
15473 i386/x32-avx-linux.xml.
15474
15475 * linux-x86-low.c (init_registers_x32_linux): New prototype.
15476 (init_registers_x32_avx_linux): Likwise.
15477 (x86_linux_update_xmltarget): Call init_registers_x32_linux
15478 or init_registers_x32_avx_linux if linux_is_elf64 is false.
15479
ecedbe58
PA
154802012-04-13 Pedro Alves <palves@redhat.com>
15481
15482 * Makefile.in (GNULIB_FLAGS_TO_PASS): New.
15483 (FLAGS_TO_PASS): Don't change or set $top_srcdir, $srcdir and VPATH.
15484 (all, uninstall, clean-info, all-lib, clean, maintainer-clean)
15485 (realclean, distclean): Explicitly pass $GNULIB_FLAGS_TO_PASS to
15486 the sub-make.
15487
c92b5177
L
154882012-04-12 H.J. Lu <hongjiu.lu@intel.com>
15489
15490 * linux-x86-low.c (compat_x32_clock_t): New.
15491 (compat_x32_siginfo_t): Likewise.
15492 (compat_x32_siginfo_from_siginfo): Likewise.
15493 (siginfo_from_compat_x32_siginfo): Likewise.
15494 (linux_is_elf64): Likewise.
15495 (x86_siginfo_fixup): Call compat_x32_siginfo_from_siginfo
15496 and siginfo_from_compat_x32_siginfo for x32.
15497 (x86_arch_setup): Set linux_is_elf64.
15498
214d508e
L
154992012-04-12 H.J. Lu <hongjiu.lu@intel.com>
15500
15501 PR gdb/13969
15502 * linux-low.c (linux_pid_exe_is_elf_64_file): Also return the
15503 e_machine field.
15504 (linux_qxfer_libraries_svr4): Update call to elf_64_file_p.
15505 * linux-low.h (linux_pid_exe_is_elf_64_file): Updated.
15506 * linux-x86-low.c (x86_arch_setup): Check if GDBserver is
15507 compatible with process.
15508
c9a1864a
YQ
155092012-04-12 Yao Qi <yao@codesourcery.com>
15510
15511 * Makefile.in: Define abs_top_srcdir and abs_srcdir.
15512 (INCLUDE_CFLAGS): Append GNULIB_INCLUDE_DIR.
15513 (install-only, install-info, clean): Handle sub dir gnulib.
15514 (all-lib, am--refresh): New targets.
15515 (memmem.o): Remove target.
15516 * configure.ac: Remove AC_CONFIG_LIBOBJ_DIR.
15517 Invoke gl_EARLY. Invoke AC_CHECK_PROGS for make.
15518 (AC_REPLACE_FUNCS): Remove memmem.
15519 Invoke gl_INIT and AM_INIT_AUTOMAKE.
15520 (AC_OUTPUT): Generate Makefile in gnulib/.
15521 * aclocal.m4, config.in, configure: Regenerated.
15522
367ba2c2
MR
155232012-04-10 Maciej W. Rozycki <macro@codesourcery.com>
15524
15525 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP.
15526
9d236627
PA
155272012-04-05 Pedro Alves <palves@redhat.com>
15528
15529 -Werror=strict-aliasing
15530
15531 * spu-low.c (parse_spufs_run): Avoid dereferencing type-punned
15532 pointer.
15533
111217b3
PA
155342012-04-04 Pedro Alves <palves@redhat.com>
15535
15536 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
15537 (sparc_store_gregset_from_stack, sparc_store_gregset)
15538 (sparc_breakpoint_at): Fix formatting.
15539
8365dcf5
TJB
155402012-03-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
15541
15542 * configure.ac: Check whether Elf32_auxv_t and Elf64_auxv_t
15543 are available.
15544 * linux-low.c [HAVE_ELF32_AUXV_T] (Elf32_auxv_t): Add typedef.
15545 [HAVE_ELF64_AUXV_T] (Elf64_auxv_t): Likewise.
15546 * config.in: Regenerate.
15547 * configure: Likewise.
15548
689cc2ae
PA
155492012-03-29 Pedro Alves <palves@redhat.com>
15550
15551 * linux-low.c (regsets_store_inferior_registers) [__sparc__]:
15552 Correct ptrace arguments.
15553
c14dfd32
PA
155542012-03-28 Pedro Alves <palves@redhat.com>
15555
15556 * linux-ia64-low.c (ia64_regmap): Map IA64_EC_REGNUM to PT_AR_EC.
15557 (IA64_GR0_REGNUM, IA64_FR0_REGNUM)
15558 (IA64_FR1_REGNUM): New defines.
15559 (ia64_fetch_register): New.
15560 (the_low_target): Install it.
15561 * linux-low.h (struct linux_target_ops) <fetch_register>: New
15562 field.
15563 * linux-low.c (linux_fetch_registers): Try the
15564 the_low_target.fetch_register hook first.
15565
15566 * linux-arm-low.c (the_low_target): Adjust.
15567 * linux-bfin-low.c (the_low_target): Adjust.
15568 * linux-cris-low.c (the_low_target): Adjust.
15569 * linux-crisv32-low.c (the_low_target): Adjust.
15570 * linux-m32r-low.c (the_low_target): Adjust.
15571 * linux-m68k-low.c (the_low_target): Adjust.
15572 * linux-mips-low.c (the_low_target): Adjust.
15573 * linux-ppc-low.c (the_low_target): Adjust.
15574 * linux-s390-low.c (the_low_target): Adjust.
15575 * linux-sh-low.c (the_low_target): Adjust.
15576 * linux-sparc-low.c (the_low_target): Adjust.
15577 * linux-tic6x-low.c (the_low_target): Adjust.
15578 * linux-x86-low.c (the_low_target): Adjust.
15579 * linux-xtensa-low.c (the_low_target): Adjust.
15580
63c88e13
PA
155812012-03-26 Pedro Alves <palves@redhat.com>
15582
15583 * server.c (handle_qxfer_libraries): Don't bail early if
15584 the_target->qxfer_libraries_svr4 is not NULL.
15585
fb723180
PA
155862012-03-26 Pedro Alves <palves@redhat.com>
15587
15588 * linux-low.c (linux_qxfer_libraries_svr4): Fix pasto in comment.
15589
0afae3cf
PA
155902012-03-23 Pedro Alves <palves@redhat.com>
15591
15592 * linux-low.c (linux_qxfer_libraries_svr4): Terminate the
15593 "library-list-svr4" element's start tag when the the DSO list is
15594 empty.
15595
485f1ee4
PA
155962012-03-23 Pedro Alves <palves@redhat.com>
15597
15598 * linux-low.c (read_one_ptr): Read the inferior's pointer through
15599 a variable whose type size is the same as the inferior's pointer
15600 size.
15601
a5362b9a
TS
156022012-03-21 Thomas Schwinge <thomas@codesourcery.com>
15603
15604 * linux-arm-low.c (arm_stopped_by_watchpoint): Use siginfo_t instead of
15605 struct siginfo.
15606 * linux-low.c (siginfo_fixup, linux_xfer_siginfo): Likewise.
15607 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
15608 * linux-low.h: Include <signal.h>.
15609 (struct siginfo): Remove forward declaration.
15610 (struct linux_target_ops) <siginfo_fixup>: Use siginfo_t instead of
15611 struct siginfo.
15612
d226c142
MF
156132012-03-21 Mike Frysinger <vapier@gentoo.org>
15614
15615 * .gitignore: Ignore more files.
15616
122f36ef
PA
156172012-03-19 Pedro Alves <palves@redhat.com>
15618 Jan Kratochvil <jan.kratochvil@redhat.com>
15619
15620 * server.c (cont_thread, general_thread): Add describing comments.
15621 (start_inferior): Clear `cont_thread'.
15622 (handle_v_cont): Don't set `cont_thread' if resuming all threads
15623 of a process.
15624
fc3e5175
YQ
156252012-03-15 Yao Qi <yao@codesourcery.com>
15626
15627 * tracepoint.c (install_tracepoint): Move duplicated tracepoint
15628 handling to ...
15629 (cmd_qtdp): ... here.
15630
8d0d92cd
YQ
156312012-03-15 Yao Qi <yao@codesourcery.com>
15632
15633 * tracepoint.c (struct tracepoint_action_ops): New.
15634 (struct tracepoint_action) [!IN_PROCESS_AGENT] <ops>: New field.
15635 (m_tracepoint_action_download): New.
15636 (r_tracepoint_action_download): New.
15637 (x_tracepoint_action_download): New.
15638 (l_tracepoint_action_download): New.
15639 (add_tracepoint_action): Install `action->ops' according type.
15640 (download_tracepoint_1): Move code `download' function pointer
15641 of various tracepoint_action_ops.
15642
87b0bb13
JK
156432012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
15644
15645 * linux-low.c (linux_attach_lwp_1): New variable buffer. Call
15646 linux_ptrace_attach_warnings.
15647
5f572dec
JK
156482012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
15649
15650 * Makefile.in (linux-ptrace.o): New.
15651 * configure.srv (arm*-*-linux*, bfin-*-*linux*, crisv32-*-linux*)
15652 (cris-*-linux*, i[34567]86-*-linux*, ia64-*-linux*, m32r*-*-linux*)
15653 (m68*-*-linux*, m68*-*-uclinux*, mips*-*-linux*, powerpc*-*-linux*)
15654 (s390*-*-linux*, sh*-*-linux*, sparc*-*-linux*, tic6x-*-uclinux)
15655 (x86_64-*-linux*, xtensa*-*-linux*): Add linux-ptrace.o to SRV_TGTOBJ
15656 of these targets.
15657 * linux-low.c (linux_attach_lwp_1): Remove redundent else clause.
15658
f4647387
YQ
156592012-03-08 Yao Qi <yao@codesourcery.com>
15660 Pedro Alves <palves@redhat.com>
15661
15662 Fix PR server/13392.
15663 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Check
15664 offset of JMP insn.
15665 * tracepoint.c (remove_tracepoint): New.
15666 (cmd_qtdp): Call remove_tracepoint when failed to install.
15667
9b224c5e
PA
156682012-03-07 Pedro Alves <palves@redhat.com>
15669
15670 * linux-low.c (get_detach_signal): New.
15671 (linux_detach_one_lwp): Get rid of a pending SIGSTOP with SIGCONT.
15672 Pass on pending signals to PTRACE_DETACH. Check the result of the
15673 ptrace call.
15674 * server.c (program_signals, program_signals_p): New.
15675 (handle_general_set): Handle QProgramSignals.
15676 * server.h (program_signals, program_signals_p): Declare.
15677
e237a7e2
JK
156782012-03-05 Pedro Alves <palves@redhat.com>
15679 Jan Kratochvil <jan.kratochvil@redhat.com>
15680
15681 * linux-low.c (get_dynamic): Don't warn when PT_PHDR isn't found.
15682 New comment why.
15683
5808517f
YQ
156842012-03-03 Yao Qi <yao@codesourcery.com>
15685
15686 * tracepoint.c (tracepoint_look_up_symbols): Update call to
15687 agent_look_up_symbols.
15688
58b4daa5
YQ
156892012-03-03 Yao Qi <yao@codesourcery.com>
15690
15691 * Makefile.in (linux-low.o): Keep dependence on agent.h.
15692 (linux-x86-low.o): Likewise.
15693 * server.h: Remove in_process_agent_loaded.
15694 * tracepoint.c (in_process_agent_loaded): Removed. Moved it
15695 common/agent.c.
15696 Update callers.
15697
8ffcbaaf
YQ
156982012-03-03 Yao Qi <yao@codesourcery.com>
15699
15700 * tracepoint.c (gdb_agent_capability): New global.
15701 (in_process_agent_loaded_ust): Renamed to
15702 `in_process_agent_supports_ust'.
15703 Update callers.
15704 (in_process_agent_supports_ust): Call agent_capability_check.
15705 (clear_installed_tracepoints): Assert that agent supports
15706 agent.
15707
d1feda86
YQ
157082012-03-03 Yao Qi <yao@codesourcery.com>
15709
15710 * linux-low.c (linux_supports_agent): New.
15711 (linux_target_ops): Initialize field `supports_agent' with
15712 linux_supports_agent.
15713 * target.h (struct target_ops) <supports_agent>: New.
15714 (target_supports_agent): New macro.
15715 * server.c (handle_general_set): Handle packet 'QAgent'.
15716 (handle_query): Send `QAgent+'.
15717 * Makefile.in (server.o): Depends on agent.h.
15718
2fa291ac
YQ
157192012-03-03 Yao Qi <yao@codesourcery.com>
15720
15721 * Makefile.in (OBS): Add agent.o.
15722 Add new rule for agent.o.
15723 Track dependence of tracepoint.c on agent.h.
15724 * tracepoint.c (run_inferior_command_1):
15725 (run_inferior_command): Call agent_run_command.
15726 (gdb_ust_connect_sync_socket): Deleted. Move it to
15727 common/agent.c.
15728 (resume_thread, stop_thread): Likewise.
15729 (gdb_ust_socket_init): Renamed to ...
15730 (gdb_agent_socket_init): ... New.
15731 (gdb_ust_thread): Renamed to ...
15732 (gdb_agent_helper_thread): ... New.
15733 (gdb_ust_init): Move some code to ...
15734 (gdb_agent_init): ... here. New.
15735 [HAVE_UST]: Call gdb_ust_init.
15736 (initialize_tracepoint_ftlib): Call gdb_agent_init.
15737 * configure.ac: Add `sys/un.h' to AC_CHECK_HEADERS.
15738 * config.in, configure: Regenerated.
15739
05044653
PA
157402012-03-02 Pedro Alves <palves@redhat.com>
15741
15742 * inferiors.c (add_pid_to_list, pull_pid_from_list): Delete.
15743 * linux-low.c (struct simple_pid_list): New.
15744 (stopped_pids): New a struct simple_pid_list pointer.
15745 (add_to_pid_list, pull_pid_from_list): New.
15746 (handle_extended_wait): Don't assume the first signal new children
15747 report is SIGSTOP. Adjust call to pull_pid_from_list.
15748 (linux_wait_for_lwp): Adjust.
15749
8d00225b
YQ
157502012-03-02 Yao Qi <yao@codesourcery.com>
15751
15752 * tracepoint.c (do_action_at_tracepoint): Write `stop_pc' in
15753 debug log.
15754
19560ba5
YQ
157552012-03-02 Yao Qi <yao@codesourcery.com>
15756
15757 * tracepoint.c (collect_ust_data_at_tracepoint): Remove parameters
15758 `stop_pc' and `tpoint'. Update caller.
15759
1faeff08
MR
157602012-03-01 Maciej W. Rozycki <macro@codesourcery.com>
15761
15762 * linux-low.h (linux_target_ops): Add regset_bitmap member.
15763 * linux-low.c (use_linux_regsets): New macro.
15764 [!HAVE_LINUX_REGSETS] (regsets_fetch_inferior_registers): Likewise.
15765 [!HAVE_LINUX_REGSETS] (regsets_store_inferior_registers): Likewise.
15766 (linux_register_in_regsets): New function.
15767 (usr_fetch_inferior_registers): Skip registers covered by
15768 regsets.
15769 (usr_store_inferior_registers): Likewise.
15770 (usr_fetch_inferior_registers): New macro.
15771 (usr_store_inferior_registers): Likewise.
15772 (linux_fetch_registers): Handle mixed regset/non-regset targets.
15773 (linux_store_registers): Likewise.
15774 * linux-mips-low.c (init_registers_mips_dsp_linux): New
15775 prototype.
15776 (init_registers_mips64_dsp_linux): Likewise.
15777 (init_registers_mips_linux): New macro.
15778 (init_registers_mips_dsp_linux): Likewise.
15779 (mips_dsp_num_regs): Likewise.
15780 (DSP_BASE, DSP_CONTROL): New fallback macros.
15781 (mips_base_regs): New macro.
15782 (mips_regmap): Use it. Fix the size.
15783 (mips_dsp_regmap): New variable.
15784 (mips_dsp_regset_bitmap): Likewise.
15785 (mips_arch_setup): New function.
15786 (mips_cannot_fetch_register): Use the_low_target.regmap rather
15787 than mips_regmap.
15788 (mips_cannot_store_register): Likewise.
15789 (the_low_target): Update .arch_setup, .num_regs and .regmap
15790 initializers. Add .regset_bitmap initializer.
15791 * linux-arm-low.c (the_low_target): Add .regset_bitmap
15792 initializer.
15793 * linux-bfin-low.c (the_low_target): Likewise.
15794 * linux-cris-low.c (the_low_target): Likewise.
15795 * linux-crisv32-low.c (the_low_target): Likewise.
15796 * linux-ia64-low.c (the_low_target): Likewise.
15797 * linux-m32r-low.c (the_low_target): Likewise.
15798 * linux-m68k-low.c (the_low_target): Likewise.
15799 * linux-ppc-low.c (the_low_target): Likewise.
15800 * linux-s390-low.c (the_low_target): Likewise.
15801 * linux-sh-low.c (the_low_target): Likewise.
15802 * linux-sparc-low.c (the_low_target): Likewise.
15803 * linux-tic6x-low.c (the_low_target): Likewise.
15804 * linux-x86-low.c (the_low_target): Likewise.
15805 * linux-xtensa-low.c (the_low_target): Likewise.
15806 * configure.srv <mips*-*-linux*>: Add mips-dsp-linux.o and
15807 mips64-dsp-linux.o to srv_regobj. Add mips-dsp-linux.xml,
15808 mips64-dsp-linux.xml, mips-dsp.xml and mips64-dsp.xml to
15809 srv_xmlfiles.
15810 * Makefile.in (mips-dsp-linux.o, mips-dsp-linux.c): New targets.
15811 (mips64-dsp-linux.o, mips64-dsp-linux.c): Likewise.
15812
c03e6ccc
YQ
158132012-02-29 Yao Qi <yao@codesourcery.com>
15814 Pedro Alves <palves@redhat.com>
15815
15816 * linux-low.c: (linux_wait_1): Call unsuspend_all_lwps when
15817 `step_over_finished' is true.
15818
644cebc9
PA
158192012-02-27 Pedro Alves <palves@redhat.com>
15820
15821 * linux-low.c (pid_is_stopped): Delete, moved to common/.
15822 (linux_attach_lwp_1): Adjust to use linux_proc_pid_is_stopped.
15823
c14d7ab2
PA
158242012-02-27 Pedro Alves <palves@redhat.com>
15825
15826 PR server/9684
15827 * linux-low.c (pid_is_stopped): New.
15828 (linux_attach_lwp_1): Handle attaching to 'T (stopped)' processes.
15829
412c89dd
LM
158302012-02-25 Luis Machado <lgustavo@codesourcery.com>
15831
15832 * mem-break.c (clear_gdb_breakpoint_conditions): Fix de-allocation
15833 of conditions.
15834
b745defe
MR
158352012-02-24 Maciej W. Rozycki <macro@codesourcery.com>
15836
15837 * linux-mips-low.c (mips_regmap): Correct the index of $f9.
15838
9f3a5c85
LM
158392012-02-24 Luis Machado <lgustavo@codesourcery>
15840
15841 * server.c (handle_query): Advertise support for target-side
15842 breakpoint condition evaluation.
15843 (process_point_options): New function.
15844 (process_serial_event): When inserting a breakpoint, check for
15845 a target-side condition that should be evaluated.
15846
15847 * mem-break.c: Include regcache.h and ax.h.
15848 (point_cond_list_t): New data structure.
15849 (breakpoint) <cond_list>: New field.
15850 (find_gdb_breakpoint_at): Make non-static.
15851 (delete_gdb_breakpoint_at): Clear any target-side
15852 conditions.
15853 (clear_gdb_breakpoint_conditions): New function.
15854 (add_condition_to_breakpoint): Likewise.
15855 (add_breakpoint_condition): Likewise.
15856 (gdb_condition_true_at_breakpoint): Likewise.
15857 (gdb_breakpoint_here): Return result directly instead
15858 of going through a local variable.
15859
15860 * mem-break.h (find_gdb_breakpoint_at): New prototype.
15861 (clear_gdb_breakpoint_conditions): Likewise.
15862 (add_breakpoint_condition): Likewise.
15863 (gdb_condition_true_at_breakpoint): Likewise.
15864
15865 * linux-low.c (linux_wait_1): Evaluate target-side breakpoint condition.
15866 (need_step_over_p): Take target-side breakpoint condition into
15867 consideration.
15868
5e1dc496
LM
158692012-02-24 Luis Machado <lgustavo@codesourcery>
15870
15871 * server.h: Include tracepoint.h.
15872 (agent_mem_read, agent_get_trace_state_variable_value,
15873 agent_set_trace_state_variable_value,
15874 agent_tsv_read, agent_mem_read_string, get_get_tsv_func_addr,
15875 get_set_tsv_func_addr): New prototypes.
15876
15877 * ax.h: New include file.
15878 * ax.c: New source file.
15879
15880 * tracepoint.c: Include ax.h.
15881 (gdb_agent_op, gdb_agent_op_names, gdb_agent_op_sizes,
15882 agent_expr, eval_result_type): Move to ax.h.
15883 (parse_agent_expr): Rename to ...
15884 (gdb_parse_agent_expr): ... this, make it non-static and move
15885 to ax.h.
15886 (unparse_agent_expr) Rename to ...
15887 (gdb_unparse_agent_expr): ... this, make it non-static and move
15888 to ax.h.
15889 (eval_agent_expr): Rename to ...
15890 (eval_tracepoint_agent_expr): ... this.
15891 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Remove
15892 forward declarations.
15893 (add_tracepoint_action): Call gdb_parse_agent_expr (...).
15894 (agent_get_trace_state_variable_value): New function.
15895 (agent_set_trace_state_variable_value): New function.
15896 (cmd_qtdp): Call gdb_parse_agent_expr (...).
15897 (response_tracepoint): Call gdb_unparse_agent_expr (...).
15898 (do_action_at_tracepoint): Call eval_tracepoint_agent_expr (...).
15899 (condition_true_at_tracepoint): Likewise.
15900 (parse_agent_expr): Rename to ...
15901 (gdb_parse_agent_expr): ... this and move to ax.c.
15902 (unparse_agent_expr): Rename to ...
15903 (gdb_unparse_agent_expr): ... this and move to ax.c.
15904 (gdb_agent_op_name): Move to ax.c.
15905 (eval_agent_expr): Rename to ...
15906 (gdb_eval_agent_expr): ... this, use regcache passed as parameter
15907 and move to ax.c.
15908 (eval_tracepoint_agent_expr): New function.
15909 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Make
43aaf8b6 15910 non-static.
5e1dc496
LM
15911 (current_insn_ptr, emit_error, struct bytecode_address): Move to
15912 ax.c.
15913 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul, emit_lsh,
15914 emit_rsh_signed, emit_rsh_unsigned, emit_ext, emit_log_not,
15915 emit_bit_and, emit_bit_or, emit_bit_xor, emit_bit_not, emit_equal,
15916 emit_less_signed, emit_less_unsigned, emit_ref, emit_if_goto,
15917 emit_goto, write_goto_address, emit_const, emit_reg, emit_pop,
15918 emit_stack, emit_zero_ext, emit_swap, emit_stack_adjust,
15919 emit_int_call_1, emit_void_call_2, emit_eq_goto, emit_ne_goto,
15920 emit_lt_goto, emit_ge_goto, emit_gt_goto, emit_le_goto): Move to ax.c.
15921 (get_get_tsv_func_addr, get_set_tsv_func_addr): New functions.
15922 (compile_bytecodes): Remove forward declaration.
15923 (is_goto_target): Move to ax.c.
15924 (compile_bytecodes): Move to ax.c and call
15925 agent_get_trace_state_variable_value (...) and
15926 agent_set_trace_state_variable_value (...).
15927
15928 * Makefile.in: Update ax.c and IPA dependencies.
15929
277e4e52
PA
159302012-02-24 Pedro Alves <palves@redhat.com>
15931
15932 * tracepoint.c (cmd_bigqtbuffer): Rename as ...
15933 (cmd_bigqtbuffer_circular): ... this. Only handle
15934 'QTBuffer:circular:'.
15935 (handle_tracepoint_general_set): Adjust.
15936
bf4c19f7
YQ
159372012-02-16 Yao Qi <yao@codesourcery.com>
15938
15939 * inferiors.c: Move code to ...
15940 * dll.c: .... here. New.
15941 * server.h: Declare clear_dlls.
15942 * Makefile.in (SFILES): Add dll.c.
15943 (OBS): Add dll.o
15944 (dll.o): New rule.
15945
d73f2619
YQ
159462012-02-11 Yao Qi <yao@codesourcery.com>
15947
15948 * server.c: (handle_monitor_command): Add a new parameter
15949 `own_buf'.
15950 (handle_query): Update caller.
15951
f8255c2a
JB
159522012-02-09 Joel Brobecker <brobecker@adacore.com>
15953
15954 * configure.ac: Add readlink to AC_CHECK_FUNCS list.
15955 * configure, config.in: Regenerate.
15956 * hostio.c: Provide an alternate implementation if HAVE_READLINK
15957 is not defined.
15958
da84f473
PA
159592012-02-02 Pedro Alves <palves@redhat.com>
15960
15961 Try SIGKILL first, then PTRACE_KILL.
15962 * linux-low.c (linux_kill_one_lwp): New.
15963 (linux_kill_one_lwp): Rename to ...
15964 (kill_one_lwp_callback): ... this. Use the new
15965 linux_kill_one_lwp.
15966
e886a173
PA
159672012-02-02 Pedro Alves <palves@redhat.com>
15968
15969 * tracepoint.c (cmd_qtminftpilen): Return 0 if there's no current
15970 inferior.
15971
be07f1a2
PA
159722012-01-27 Pedro Alves <palves@redhat.com>
15973
15974 * linux-low.c (linux_child_pid_to_exec_file): Delete.
15975 (elf_64_file_p): Make static.
15976 (linux_pid_exe_is_elf_64_file): New.
15977 * linux-low.h (linux_child_pid_to_exec_file, elf_64_file_p):
15978 Delete declarations.
15979 (linux_pid_exe_is_elf_64_file): Declare.
15980 * linux-x86-low.c (x86_arch_setup): Use
15981 linux_pid_exe_is_elf_64_file.
15982
d8301ad1
JK
159832012-01-25 Jan Kratochvil <jan.kratochvil@redhat.com>
15984
15985 * linux-low.c (linux_wait_for_event_1): Rename to ...
15986 (linux_wait_for_event): ... here and merge it with former
15987 linux_wait_for_event - new variable wait_ptid, use it.
15988 (linux_wait_for_event): Remove - merge it to linux_wait_for_event_1.
15989
01b17894
PA
159902012-01-23 Pedro Alves <palves@redhat.com>
15991
15992 * server.c (main): Avoid yet another case of infinite loop while
15993 detaching/killing after a longjmp.
15994
e825046f
JK
159952012-01-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15996
15997 Code cleanup.
15998 * linux-low.c (linux_wait_for_event_1): Use ptid_is_pid.
15999
b9e7b9c3
UW
160002012-01-20 Ulrich Weigand <ulrich.weigand@linaro.org>
16001
16002 * hostio.c (handle_readlink): New function.
16003 (handle_vFile): Call it to handle "vFile:readlink" packets.
16004
901f9912
UW
160052012-01-20 Pedro Alves <palves@redhat.com>
16006 Ulrich Weigand <ulrich.weigand@linaro.org>
16007
16008 * server.c (handle_v_requests): Only support vAttach and vRun to
16009 start multiple processes when in extended protocol mode.
16010
fc1ab1a0
PA
160112012-01-17 Pedro Alves <palves@redhat.com>
16012
16013 * tracepoint.c (initialize_tracepoint): Use mmap instead of
16014 memalign plus mprotect to allocate the scratch buffer.
16015
7d5d4e98
PA
160162012-01-13 Pedro Alves <palves@redhat.com>
16017
16018 * server.c (attach_inferior): Clear `cont_thread'.
16019
f128d5e9
PA
160202012-01-13 Pedro Alves <palves@redhat.com>
16021
16022 * server.c (main): Avoid infinite loop while detaching/killing
16023 after a longjmp.
16024
06db92f0
DE
160252012-01-09 Doug Evans <dje@google.com>
16026
16027 * server.c (start_inferior): Set last_ptid in --wrapper case.
16028
32d92999
YQ
160292012-01-06 Yao Qi <yao@codesourcery.com>
16030
16031 * tracepoint.c [IN_PROCESS_AGENT] (debug_threads): Macro
16032 defined.
16033 [IN_PROCESS_AGENT] (debug_agent): New global variable.
16034
5e0a92a9
YQ
160352012-01-04 Yao Qi <yao@codesourcery.com>
16036
16037 * tracepoint.c (cmd_qtdp): Print debug message
16038 for static tracepoint.
16039
ae639e8c
YQ
160402012-01-04 Yao Qi <yao@codesourcery.com>
16041
16042 * tracepoint.c (trace_vdebug): Differentiate debug message
16043 between gdbserver and IPA.
16044
f72429c5
YQ
160452012-01-03 Yao Qi <yao@codesourcery.com>
16046
16047 * tracepoint.c (tracepoint_was_hit): Don't collect for
16048 static tracepoint.
16049
12c3e59c
JB
160502012-01-02 Joel Brobecker <brobecker@adacore.com>
16051
16052 * terminal.h: Reformat copyright header.
16053
67827812
JB
160542012-01-02 Joel Brobecker <brobecker@adacore.com>
16055
16056 * server.c (gdbserver_version): Update copyright year.
16057 * gdbreplay.c (gdbreplay_version): Likewise.
16058
3e52c33d
JK
160592011-12-18 Jan Kratochvil <jan.kratochvil@redhat.com>
16060
16061 * linux-low.c (linux_create_inferior): Put empty if clause for write.
16062
16063 Revert:
16064 2011-12-18 Hui Zhu <teawater@gmail.com>
16065 * linux-low.c (linux_create_inferior): Save return value to ret.
16066
66f1260e
HZ
160672011-12-18 Hui Zhu <teawater@gmail.com>
16068
16069 * linux-low.c (linux_create_inferior): Save return value to ret.
16070
e77616d7
DE
160712011-12-16 Doug Evans <dje@google.com>
16072
e7b06c57
DE
16073 * linux-low.c (linux_create_inferior): If stdio connection,
16074 redirect stdin from /dev/null, stdout to stderr.
16075 * remote-utils.c (remote_is_stdio): New static global.
16076 (remote_connection_is_stdio): New function.
16077 (remote_prepare): Handle stdio connection.
16078 (remote_open): Ditto.
16079 (remote_close): Don't close stdin for stdio connections.
16080 (read_prim,write_prim): New functions. Replace all calls to
16081 read/write to these.
16082 * server.c (main): Watch for "-" argument. Move call to
16083 remote_prepare before start_inferior.
16084 * server.h (STDIO_CONNECTION_NAME): New macro.
16085 (remote_connection_is_stdio): Declare.
16086
e77616d7
DE
16087 * remote-utils.c (prepare_resume_reply): Remove extraneous \n
16088 in debugging output.
16089
82067193
YQ
160902011-12-15 Yao Qi <yao@codesourcery.com>
16091
16092 * tracepoint.c: Include sys/syscall.h.
16093 (gdb_ust_thread): Remove preprocessor conditional.
16094
82bfbe7e
PA
160952011-12-14 Pedro Alves <pedro@codesourcery.com>
16096
16097 * linux-low.c (linux_detach_one_lwp): Call
16098 the_low_target.prepare_to_resume before detaching.
16099
712c6575
YQ
161002011-12-14 Yao Qi <yao@codesourcery.com>
16101
16102 * tracepoint.c (gdb_ust_thread): Don't ignore return value
16103 of write.
16104
d54d1edf
YQ
161052011-12-14 Yao Qi <yao@codesourcery.com>
16106
16107 * i386-low.c (i386_low_stopped_data_address): Initialize local
16108 variable `control'.
16109
6210a125
PA
161102011-12-13 Pedro Alves <pedro@codesourcery.com>
16111
16112 PR remote/13492
16113
16114 * i386-low.c (i386_low_stopped_data_address): Avoid fetching
16115 DR_CONTROL unless necessary. Extend comments.
16116 * linux-x86-low.c (x86_linux_prepare_to_resume): Don't write to
16117 DR0-3 if not used. If any watchpoint was set, clear DR_STATUS.
16118
2ece8244
YQ
161192011-12-13 Yao Qi <yao@codesourcery.com>
16120
16121 * tracepoint.c (trace_buffer_alloc): Replace magic numbers with
16122 macros.
16123 (upload_fast_traceframes, upload_fast_traceframes): Likewise.
16124
784867a5
JK
161252011-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
16126
16127 * linux-low.c (linux_kill): Skip PTRACE_KILL if LWP does not exist.
16128 Print new debug message for such case.
16129
6bf36717
JK
161302011-12-06 Jan Kratochvil <jan.kratochvil@redhat.com>
16131
16132 Fix overlapping memcpy.
16133 * mem-break.c (set_raw_breakpoint_at): New variable buf. Use it for
16134 the read_inferior_memory transfer.
16135 (delete_fast_tracepoint_jump): New variable buf. Use it for the
16136 write_inferior_memory transfer.
16137 (set_fast_tracepoint_jump): New variable buf. Use it for the
16138 read_inferior_memory and write_inferior_memory transfers.
16139 (uninsert_fast_tracepoint_jumps_at, reinsert_fast_tracepoint_jumps_at)
16140 (delete_raw_breakpoint, uninsert_raw_breakpoint): New variable buf.
16141 Use it for the write_inferior_memory transfer.
16142 (check_mem_read, check_mem_write): New gdb_asserts for overlapping
16143 buffers.
16144
50275556
MR
161452011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
16146
16147 * linux-low.c (fetch_register, store_register): Make code
16148 consistent, fix formatting.
16149
7325beb4
MR
161502011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
16151
16152 * linux-low.c (usr_store_inferior_registers): Factor out code
16153 to handle individual registers into...
16154 (store_register): ... this new function.
16155
c642a434
UW
161562011-12-06 Ulrich Weigand <uweigand@de.ibm.com>
16157
16158 * Makefile.in (s390-linux32v1.o, s390-linux32v1.c): New rules.
16159 (s390-linux32v2.o, s390-linux32v2.c): Likewise.
16160 (s390-linux64v1.o, s390-linux64v1.c): Likewise.
16161 (s390-linux64v2.o, s390-linux64v2.c): Likewise.
16162 (s390x-linux64v1.o, s390x-linux64v1.c): Likewise.
16163 (s390x-linux64v2.o, s390x-linux64v2.c): Likewise.
16164 * configure.srv [s390*-*-linux*] (srv_regobj): Add new objects.
16165 (srv_xmlfiles): Add new XML files.
16166
16167 * linux-s390-low.c: Include "elf/common.h", <sys/ptrace.h>,
16168 and <sys/uio.h>.
16169 (PTRACE_GETREGSET, PTRACE_SETREGSET): Define if undefined.
16170 (init_registers_s390_linux32v1): Add prototype.
16171 (init_registers_s390_linux32v2): Likewise.
16172 (init_registers_s390_linux64v1): Likewise.
16173 (init_registers_s390_linux64v2): Likewise.
16174 (init_registers_s390x_linux64v1): Likewise.
16175 (init_registers_s390x_linux64v2): Likewise.
16176 (s390_num_regs): Increment to 52.
16177 (s390_regmap): Add orig_r2 register.
16178 (s390_num_regs_3264): Increment to 68.
16179 (s390_regmap_3264): Add orig_r2 register.
16180 (s390_collect_ptrace_register): Handle orig_r2 register.
16181 (s390_supply_ptrace_register): Likewise.
16182 (s390_fill_last_break): New function.
16183 (s390_store_last_break): Likewise.
16184 (s390_fill_system_call): New function.
16185 (s390_store_system_call): Likewise.
16186 (target_regsets): Handle NT_S390_LAST_BREAK and NT_S390_SYSTEM_CALL
16187 register sets.
16188 (s390_check_regset): New function.
16189 (s390_arch_setup): Check for presence of NT_S390_LAST_BREAK and
16190 NT_S390_SYSTEM_CALL regsets and use appropriate description.
16191 Update target_regsets for available register sets.
16192
2268b414
JK
161932011-12-02 Paul Pluzhnikov <ppluzhnikov@google.com>
16194 Jan Kratochvil <jan.kratochvil@redhat.com>
16195
16196 * linux-low.c (get_phdr_phnum_from_proc_auxv, get_dynamic, get_r_debug)
16197 (read_one_ptr, struct link_map_offsets, linux_qxfer_libraries_svr4):
16198 New.
16199 (struct linux_target_ops): Install linux_qxfer_libraries_svr4.
16200 * linux-low.h (struct process_info_private): New member r_debug.
16201 * server.c (handle_qxfer_libraries): Call
16202 the_target->qxfer_libraries_svr4.
16203 (handle_qxfer_libraries_svr4): New function.
16204 (qxfer_packets): New entry "libraries-svr4".
16205 (handle_query): Check QXFER_LIBRARIES_SVR4 and report libraries-svr4.
16206 * target.h (struct target_ops): New member qxfer_libraries_svr4.
16207 * remote.c (remote_xfer_partial): Call add_packet_config_cmd for
16208 PACKET_qXfer_libraries_svr4.
16209
d6db1fab
UW
162102011-11-30 Ulrich Weigand <uweigand@de.ibm.com>
16211
16212 * linux-s390-low.c (s390_collect_ptrace_register): Fully convert
16213 PSW address/mask between 8-byte and 16-byte formats.
16214 (s390_supply_ptrace_register): Likewise.
16215 (s390_get_pc, s390_set_pc): 4-byte PSW address always includes
16216 basic addressing mode bit.
16217
242f5f1c
SS
162182011-11-24 Stan Shebs <stan@codesourcery.com>
16219
16220 * tracepoint.c (cmd_qtstatus): Use plongest instead of %llx.
16221
f196051f
SS
162222011-11-17 Stan Shebs <stan@codesourcery.com>
16223
16224 * tracepoint.c (struct tracepoint): New field traceframe_usage.
16225 (tracing_start_time): New global.
16226 (tracing_stop_time): New global.
16227 (tracing_user_name): New global.
16228 (tracing_notes): New global.
16229 (tracing_stop_note): New global.
16230 (cmd_qtstart): Set traceframe_usage, start_time.
16231 (stop_tracing): Set stop_time.
16232 (cmd_qtstatus): Report additional status.
16233 (cmd_qtp): New function.
16234 (handle_tracepoint_query): Call it.
16235 (cmd_qtnotes): New function.
16236 (handle_tracepoint_general_set): Call it.
16237 (get_timestamp): Rename from tsv_get_timestamp.
16238
405f8e94
SS
162392011-11-14 Stan Shebs <stan@codesourcery.com>
16240 Kwok Cheung Yeung <kcy@codesourcery.com>
16241
16242 * linux-x86-low.c (small_jump_insn): New.
16243 (i386_install_fast_tracepoint_jump_pad): Add arguments for
16244 trampoline and error message, build a trampoline and issue a small
16245 jump instruction to it.
16246 (x86_install_fast_tracepoint_jump_pad): Add arguments for
16247 trampoline and error message.
16248 (x86_get_min_fast_tracepoint_insn_len): New.
16249 (the_low_target): Add call to x86_get_min_fast_tracepoint_insn_len.
16250 * linux-low.h (struct linux_target_ops): Add arguments to
16251 install_fast_tracepoint_jump_pad operation, add new operation.
16252 * linux-low.c (linux_install_fast_tracepoint_jump_pad): Add
16253 arguments.
16254 (linux_get_min_fast_tracepoint_insn_len): New function.
16255 (linux_target_op): Add new operation.
16256 * tracepoint.c (gdb_trampoline_buffer): New IPA variable.
16257 (gdb_trampoline_buffer_end): Ditto.
16258 (gdb_trampoline_buffer_error): Ditto.
16259 (struct ipa_sym_addresses): Add fields for new IPA variables.
16260 (symbol_list): Add entries for new IPA variables.
16261 (struct tracepoint): Add fields to hold the address range of the
16262 trampoline used by the tracepoint.
16263 (trampoline_buffer_head): New static variable.
16264 (trampoline_buffer_tail): Ditto.
16265 (claim_trampoline_space): New function.
16266 (have_fast_tracepoint_trampoline_buffer): New function.
16267 (clone_fast_tracepoint): Fill in trampoline fields of tracepoint
16268 structure.
16269 (install_fast_tracepoint): Ditto, also add error buffer argument.
16270 (cmd_qtminftpilen): New function.
16271 (handle_tracepoint_query): Add response to qTMinFTPILen packet.
16272 (fast_tracepoint_from_trampoline_address): New function.
16273 (fast_tracepoint_collecting): Handle trampoline as part of jump
16274 pad space.
16275 (set_trampoline_buffer_space): New function.
16276 (initialize_tracepoint): Initialize new IPA variables.
16277 * target.h (struct target_ops): Add arguments to
16278 install_fast_tracepoint_jump_pad operation, add new
16279 get_min_fast_tracepoint_insn_len operation.
16280 (target_get_min_fast_tracepoint_insn_len): New.
16281 (install_fast_tracepoint_jump_pad): Add arguments.
16282 * server.h (IPA_BUFSIZ): Define.
16283 * linux-i386-ipa.c: Include extra header files.
16284 (initialize_fast_tracepoint_trampoline_buffer): New function.
16285 (initialize_low_tracepoint): Call it.
16286 * server.h (set_trampoline_buffer_space): Declare.
16287 (claim_trampoline_space): Ditto.
16288 (have_fast_tracepoint_trampoline_buffer): Ditto.
16289
1e4d1764
YQ
162902011-11-14 Yao Qi <yao@codesourcery.com>
16291
16292 * server.c (handle_query): Handle InstallInTrace for qSupported.
16293 * tracepoint.c (add_tracepoint): Sort list.
16294 (install_tracepoint, download_tracepoint): New.
16295 (cmd_qtdp): Call them to install and download tracepoints.
16296 (sort_tracepoints): Removed.
16297 (cmd_qtstart): Update.
16298
5c73ff4e
YQ
162992011-11-14 Yao Qi <yao@codesourcery.com>
16300
16301 * mem-break.c (inc_ref_fast_tracepoint_jump): New.
16302 * mem-break.h: Declare.
16303 * tracepoint.c (cmd_qtstart): Move some code to ...
16304 (clone_fast_tracepoint, install_fast_tracepoint): ... here.
16305 New.
16306 (download_tracepoints): Move some code to ...
16307 (download_tracepoint_1): ... here. New.
16308
86a30030
YQ
163092011-11-08 Yao Qi <yao@codesourcery.com>
16310
16311 * remote-utils.c (relocate_instruction): A comment fix.
16312
8d26e50c
JB
163132011-11-07 Joel Brobecker <brobecker@adacore.com>
16314
16315 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): Delete.
16316 (i386_dr_low_get_control, i386_dr_low_get_status): Use
16317 dr_status_mirror and dr_control_mirror from debug_reg_state.
16318 (i386_dr_low_get_status): Use debug_reg_state.dr_status_mirror
16319 (i386_initial_stuff): Remove use of deleted globals.
16320 (i386_get_thread_context, i386_set_thread_context,
16321 i386_thread_added): Use dr_status_mirror and dr_control_mirror
16322 from debug_reg_state.
16323
a59306a3
YQ
163242011-11-05 Yao Qi <yao@codesourcery.com>
16325
16326 * tracepoint.c (gdb_collect): Loop over tracepoints of same
16327 address as TPOINT's.
16328
3065dfb6
SS
163292011-11-02 Stan Shebs <stan@codesourcery.com>
16330
16331 * tracepoint.c (agent_mem_read_string): New function.
16332 (eval_agent_expr): Call it for tracenz.
16333 * server.c (handle_query): Report support for tracenz.
16334
fd0d8c7c
YQ
163352011-11-02 Yao Qi <yao@codesourcery.com>
16336
16337 * tracepoint.c (cmd_qtstart): Remove unused local variables.
16338
609086b1
YQ
163392011-11-02 Yao Qi <yao@codesourcery.com>
16340
16341 * target.h: Fix a typo in comment.
16342
b9fd1791
PA
163432011-10-31 Pedro Alves <pedro@codesourcery.com>
16344
16345 * mem-break.c (check_mem_write): Add `myaddr' parameter. Don't
16346 clobber the breakpoints' shadows with fast tracepoint jumps.
16347 * mem-break.h (check_mem_write): Add `myaddr' parameter.
16348 * target.c (write_inferior_memory): Also pass MYADDR down to
16349 check_mem_write.
16350
03583c20
UW
163512011-10-07 Ulrich Weigand <ulrich.weigand@linaro.org>
16352
16353 * configure.ac: Check support for personality routine.
16354 * configure: Regenerate.
16355 * config.in: Likewise.
16356 * linux-low.c: Include <sys/personality.h>.
16357 Define ADDR_NO_RANDOMIZE if necessary.
16358 (linux_create_inferior): Disable address space randomization when
16359 forking inferior, if requested.
16360 (linux_supports_disable_randomization): New function.
16361 (linux_target_ops): Install it.
16362 * server.h (disable_randomization): Declare.
16363 * server.c (disable_randomization): New global variable.
16364 (handle_general_set): Handle QDisableRandomization.
16365 (handle_query): Likewise for qSupported.
16366 (main): Support --disable-randomization and --no-disable-randomization
16367 command line arguments.
16368 * target.h (struct target_ops): Add supports_disable_randomization.
16369 (target_supports_disable_randomization): New macro.
16370
723b724b
MF
163712011-09-29 Mike Frysinger <vapier@gentoo.org>
16372
16373 * linux-low.c (target_loadseg): Add defined PTRACE_GETFDPIC to the
16374 ifdef check.
16375 [PT_GETDSBT] (target_loadmap): Wrap in a defined PT_GETDSBT check.
16376 [!PT_GETDSBT] (target_loadmap): New definition.
16377 (LINUX_LOADMAP, LINUX_LOADMAP_EXEC, LINUX_LOADMAP_INTERP): Define.
16378 (linux_read_loadmap): Change PTRACE_GETDSBT_EXEC to
16379 LINUX_LOADMAP_EXEC, PTRACE_GETDSBT_INTERP to LINUX_LOADMAP_INTERP,
16380 and PT_GETDSBT to LINUX_LOADMAP.
16381 [!PT_GETDSBT] (linux_read_loadmap): Define to NULL.
16382 (linux_target_ops): Delete unnecessary ifdef PT_GETDSBT check.
16383
55329a5c 163842011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
71487fd7
UW
16385
16386 * linux-arm-low.c (struct arm_linux_hwbp_cap): Remove.
16387 (arm_linux_hwbp_cap): New static variable.
16388 (arm_linux_get_hwbp_cap): Replace by ...
16389 (arm_linux_init_hwbp_cap): ... this new function.
16390 (arm_linux_get_hw_breakpoint_count): Use arm_linux_hwbp_cap.
16391 (arm_linux_get_hw_watchpoint_count): Likewise.
16392 (arm_linux_get_hw_watchpoint_max_length): Likewise.
16393 (arm_arch_setup): Call arm_linux_init_hwbp_cap.
16394 (arm_prepare_to_resume): Use perror_with_name instead of error.
16395
55329a5c 163962011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
09b4ad9f
UW
16397
16398 * linux-arm-low.c: Include <signal.h>.
16399 (PTRACE_GETHBPREGS, PTRACE_SETHBPREGS): Define if necessary.
16400 (struct arm_linux_hwbp_cap): New data type.
16401 (arm_hwbp_type, arm_hwbp_control_t): New typedefs.
16402 (struct arm_linux_hw_breakpoint): New data type.
16403 (MAX_BPTS, MAX_WPTS): Define.
16404 (struct arch_process_info, struct arch_lwp_info): New data types.
16405 (arm_linux_get_hwbp_cap): New function.
16406 (arm_linux_get_hw_breakpoint_count): Likewise.
16407 (arm_linux_get_hw_watchpoint_count): Likewise.
16408 (arm_linux_get_hw_watchpoint_max_length): Likewise.
16409 (arm_hwbp_control_initialize): Likewise.
16410 (arm_hwbp_control_is_enabled): Likewise.
16411 (arm_hwbp_control_is_initialized): Likewise.
16412 (arm_hwbp_control_disable): Likewise.
16413 (arm_linux_hw_breakpoint_equal): Likewise.
16414 (arm_linux_hw_point_initialize): Likewise.
16415 (struct update_registers_data): New data structure.
16416 (update_registers_callback: New function.
16417 (arm_insert_point): Likewise.
16418 (arm_remove_point): Likewise.
16419 (arm_stopped_by_watchpoint): Likewise.
16420 (arm_stopped_data_address): Likewise.
16421 (arm_new_process): Likewise.
16422 (arm_new_thread): Likewise.
16423 (arm_prepare_to_resume): Likewise.
16424 (the_low_target): Register arm_insert_point, arm_remove_point,
16425 arm_stopped_by_watchpoint, arm_stopped_data_address, arm_new_process,
16426 arm_new_thread, and arm_prepare_to_resume.
16427
6b9801d4
SS
164282011-09-15 Stan Shebs <stan@codesourcery.com>
16429
16430 * server.h (struct emit_ops): Add compare-goto fields.
16431 * tracepoint.c (gdb_agent_op_sizes): New table.
16432 (emit_eq_goto): New function.
16433 (emit_ne_goto): New function.
16434 (emit_lt_goto): New function.
16435 (emit_le_goto): New function.
16436 (emit_gt_goto): New function.
16437 (emit_ge_goto): New function.
16438 (is_goto_target): New function.
16439 (compile_bytecodes): Recognize special cases of compare-goto
16440 combinations and call specialized emitters for them.
16441 * linux-x86-low.c (amd64_emit_eq_goto): New function.
16442 (amd64_emit_ne_goto): New function.
16443 (amd64_emit_lt_goto): New function.
16444 (amd64_emit_le_goto): New function.
16445 (amd64_emit_gt_goto): New function.
16446 (amd64_emit_ge_goto): New function.
16447 (amd64_emit_ops): Add the new functions.
16448 (i386_emit_eq_goto): New function.
16449 (i386_emit_ne_goto): New function.
16450 (i386_emit_lt_goto): New function.
16451 (i386_emit_le_goto): New function.
16452 (i386_emit_gt_goto): New function.
16453 (i386_emit_ge_goto): New function.
16454 (i386_emit_ops): Add the new functions.
16455
bf15cbda
SS
164562011-09-08 Stan Shebs <stan@codesourcery.com>
16457
16458 * linux-x86-low.c (i386_emit_prologue): Save %ebx.
16459 (i386_emit_epilogue): Restore %ebx.
16460
943ca1dd
JZ
164612011-08-31 Jie Zhang <jzhang918@gmail.com>
16462
16463 * server.c (step_thread): Remove definition.
16464 (process_serial_event): Don't handle Hs.
16465 * server.h (step_thread): Remove declaration.
16466 * target.c (set_desired_inferior): Remove use of step_thread.
16467
e3deef73
LM
164682011-08-24 Luis Machado <lgustavo@codesourcery.com>
16469
16470 * linux-low.c: Include linux-procfs.h.
16471 (linux_attach_lwp_1): Update comments.
16472 (linux_attach): Scan for existing threads when attaching to a
16473 process that is the tgid.
16474 * Makefile.in: Update dependencies.
16475
13da1c97
LM
164762011-08-24 Luis Machado <lgustavo@codesourcery.com>
16477
16478 * configure.srv: Add linux-procfs.o dependencies.
16479
881127c9
YQ
164802011-08-14 Yao Qi <yao@codesourcery.com>
16481
16482 * target.h (struct target_ops): Fix indent.
16483 * win32-low.c (win32_target_ops): Fix comment.
16484
58dbd541
YQ
164852011-08-14 Andrew Jenner <andrew@codesourcery.com>
16486 Yao Qi <yao@codesourcery.com>
16487
16488 * Makefile.in (clean): Remove tic6x-*.c files.
16489 (linux-tic6x-low.o, tic6x-c62x-linux.o, tic6x-c64x-linux.o): New rules.
16490 (tic6x-c64xp-linux.o, tic6x-c62x-linux.c, tic6x-c64x-linux.c): Likewise.
16491 (tic6x-c64xp-linux.c): Likewise.
16492 * configure.srv: Add support for tic6x-*-uclinux.
16493 * linux-tic6x-low.c: New.
16494 * linux-low.c (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define.
16495
78d85199
YQ
164962011-08-14 Andrew Stubbs <ams@codesourcery.com>
16497 Yao Qi <yao@codesourcery.com>
16498
16499 * target.h (struct target_ops): Add read_loadmap.
16500 * linux-low.c (struct target_loadseg): New type.
16501 (struct target_loadmap): New type.
16502 (linux_read_loadmap): New function.
16503 (linux_target_ops): Add linux_read_loadmap.
16504 * server.c (handle_query): Support qXfer:fdpic:read packet.
43aaf8b6
PA
16505 * win32-low.c (win32_target_ops): Initialize field `read_loadmap'
16506 to NULL.
78d85199 16507
a959a88d
EZ
165082011-08-05 Eli Zaretskii <eliz@gnu.org>
16509
16510 * win32-low.c: Include <stdint.h>.
16511
1ced966e
PA
165122011-07-22 Pedro Alves <pedro@codesourcery.com>
16513
16514 * i386-low.c (i386_insert_aligned_watchpoint): Don't pass the info
16515 to the inferior here.
16516 (i386_remove_aligned_watchpoint): Ditto.
16517 (i386_handle_nonaligned_watchpoint): Return immediate on fail to
16518 fit part of the watchpoint in the debug registers.
16519 (i386_update_inferior_debug_regs): New.
16520 (i386_low_insert_watchpoint): Work on a local mirror of the debug
16521 registers, and only update the inferior on success.
16522 (i386_low_remove_watchpoint): Ditto.
16523
d26e3629
KY
165242011-07-22 Kwok Cheung Yeung <kcy@codesourcery.com>
16525
16526 * linux-low.c (compare_ints, unique, list_threads, show_process,
16527 linux_core_of_thread): Delete.
16528 (linux_target_ops): Change linux_core_of_thread to
16529 linux_common_core_of_thread.
16530 (linux_qxfer_osdata): Defer to linux_common_xfer_osdata.
16531 * utils.c (malloc_failure): Change type of argument.
16532 (xmalloc, xrealloc, xcalloc, xsnprintf): Delete.
16533 * Makefile.in (SFILES): Add common/common-utils.c, common/xml-utils.c,
16534 common/linux-osdata.c, common/ptid.c and common/buffer.c.
16535 (OBS): Add xml-utils.o, common-utils.o, ptid.o and buffer.o.
16536 (IPA_OBJS): Add common-utils-ipa.o.
16537 (ptid_h, linux_osdata_h): New macros.
16538 (server_h): Add common/common-utils.h, common/xml-utils.h,
16539 common/buffer.h, common/gdb_assert.h, common/gdb_locale.h and
16540 common/ptid.h.
16541 (common-utils-ipa.o, common-utils.o, xml-utils.o, linux-osdata.o,
16542 ptid.o, buffer.o): New rules.
16543 (linux-low.o): Add common/linux-osdata.h as a dependency.
16544 * configure.srv (srv_tgtobj): Add linux-osdata.o to Linux targets.
16545 * configure.ac: Add AC_HEADER_DIRENT check.
16546 * config.in: Regenerate.
16547 * configure: Regenerate.
16548 * remote-utils.c (xml_escape_text): Delete.
16549 (buffer_grow, buffer_free, buffer_init, buffer_finish,
16550 buffer_xml_printf): Move to common/buffer.c.
16551 * server.c (main): Remove call to initialize_inferiors.
16552 * server.h (struct ptid, ptid_t, minus_one_ptid, null_ptid,
16553 ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp, ptid_get_tid,
16554 ptid_equal, ptid_is_pid, initialize_inferiors, xml_escape_text,
16555 internal_error, gdb_assert, gdb_assert_fail): Delete.
16556 (struct buffer, buffer_grow, buffer_free, buffer_init, buffer_finish,
16557 buffer_xml_printf, buffer_grow_str, buffer_grow_str0): Move to
16558 common/buffer.h.
16559 * inferiors.c (null_ptid, minus_one_ptid, ptid_build, pid_to_ptid,
16560 ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal, ptid_is_pid,
16561 initialize_inferiors): Delete.
16562
2275a1a7
PA
165632011-07-20 Pedro Alves <pedro@codesourcery.com>
16564
16565 * tracepoint.c (tracepoint_look_up_symbols): Return upon the first
16566 symbol error.
16567
0a5b1e09
PA
165682011-05-31 Pedro Alves <pedro@codesourcery.com>
16569
16570 * linux-x86-low.c (i386_dr_low_get_addr): Fix off by one in
16571 assertion.
16572 * win32-i386-low.c (i386_dr_low_get_addr): Ditto.
16573
6938fd34
YQ
165742011-05-26 Yao Qi <yao@codesourcery.com>
16575
16576 * Makefile.in (thread-db.o): Track dependence to
16577 common/gdb_thread_db.h.
16578 * thread-db.c: include gdb_thread_db.h from right place.
16579
b481f9e0
TT
165802011-05-16 Adrian Cornish <gnu@bluedreamer.com>
16581
16582 * linux-i386-ipa.c (supply_static_tracepoint_registers): Pass
16583 __FILE__ and __LINE__ to internal_error.
16584
98a5dd13
DE
165852011-05-13 Doug Evans <dje@google.com>
16586
16587 * thread-db.c (try_thread_db_load_from_sdir): New function.
16588 (try_thread_db_load_from_dir): New function.
16589 (thread_db_load_search): Handle $sdir, ignore $pdir.
16590 Remove trying of system directories if search of
16591 libthread-db-search-path fails, that is now done via $sdir.
16592
d248b706
KY
165932011-05-12 Kwok Cheung Yeung <kcy@codesourcery.com>
16594
16595 * server.c (handle_query): Add EnableDisableTracepoints to the list
16596 of supported features.
43aaf8b6 16597 * tracepoint.c (clear_installed_tracepoints): Uninstall disabled
d248b706 16598 tracepoints.
43aaf8b6
PA
16599 (cmd_qtenable_disable): New.
16600 (cmd_qtstart): Install tracepoints even if disabled.
16601 (handle_tracepoint_general_set): Add call to cmd_qtenable_disable on
16602 receiving a QTEnable or QTDisable packet.
16603 (gdb_collect): Skip data collection if fast tracepoint is disabled.
16604 (ust_marker_to_static_tracepoint): Do not ignore disabled static
16605 tracepoints.
16606 (gdb_probe): Skip data collection if static tracepoint is disabled.
d248b706 16607
84e578fb
DE
166082011-05-10 Doug Evans <dje@google.com>
16609
16610 * thread-db.c (thread_db_handle_monitor_command): Handle elided path.
16611
71f55dd8
DE
166122011-05-04 Doug Evans <dje@google.com>
16613
16614 * linux-low.c (linux_join): Skip process lookup.
16615 * spu-low.c (spu_join): Ditto.
16616 * server.c (join_inferiors_callback): Delete.
16617 (process_serial_event): For 'D' packet (detach) call join_inferior
16618 directly.
16619
4d393d60
JM
166202011-05-04 Joseph Myers <joseph@codesourcery.com>
16621
16622 * README: Don't mention xscale*-*-linux*.
16623 * configure.srv (xscale*-*-linux*): Don't handle target.
16624
b00ad6ff
NF
166252011-04-27 Nathan Froyd <froydnj@codesourcery.com>
16626
16627 * linux-x86-low.c (amd64_emit_const): Call memcpy instead of
16628 casting pointers.
16629 (amd64_emit_reg, amd64_emit_int_call_1, amd64_emit_void_call_2):
16630 (i386_emit_const, i386_emit_reg, i386_emit_int_call_1):
16631 (i386_emit_void_call_2): Likewise.
16632
af96c192
YQ
166332011-04-26 Yao Qi <yao@codesourcery.com>
16634
43aaf8b6
PA
16635 * linux-low.c: Move common macros to linux-ptrace.h.
16636 Include linux-ptrace.h.
af96c192
YQ
16637 * Makefile.in (linux_ptrace_h): New.
16638 (linux-low.o): Depends on linux-ptrace.h.
16639
03f2bd59
JK
166402011-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
16641
16642 * remote-utils.c (handle_accept_event): Close LISTEN_DESC only if
16643 RUN_ONCE. Comment for the LISTEN_DESC delete_file_handler call.
16644 (remote_prepare): New function with most of the TCP code from ...
16645 (remote_open): ... here. Detect PORT here unconditionally. Move also
16646 setting transport_is_reliable.
16647 * server.c (run_once): New variable.
16648 (gdbserver_usage): Document it.
16649 (main): Set run_once for `--once'. Call remote_prepare. Exit after
16650 the first run if RUN_ONCE.
16651 * server.h (run_once, remote_prepare): New declarations.
16652
7a9dd1b2
TT
166532011-04-19 Tom Tromey <tromey@redhat.com>
16654
16655 * win32-low.c (handle_load_dll): Remove duplicate "the".
16656
81239425
PM
166572011-04-07 Pierre Muller <muller@ics.u-strasbg.fr>
16658
16659 Remove support for old Cygwin 1.5 versions.
16660 * win32-low.c (win32_create_inferior): Use new cygwin_path_list
16661 function to avoid warning.
16662 (win32_add_one_solib): Use cygwin_conv_path function to avoid
16663 warning.
16664
9e0627f1
PM
166652011-03-18 Pierre Muller <muller@ics.u-strasbg.fr>
16666
16667 * gdbserver/server.h (Macro _): Define it if not available.
16668
588eebee
MS
166692011-03-14 Michael Snyder <msnyder@vmware.com>
16670
348af9f7 16671 * hostio.c (handle_close): Remove unnecessary null test.
588eebee 16672
43f70d4c
JB
166732011-03-10 Joel Brobecker <brobecker@adacore.com>
16674
16675 * Makefile.in (maintainer-clean realclean distclean): Remove
16676 "make ... subdir_do" command.
16677
348af9f7
MS
166782011-03-10 Michael Snyder <msnyder@vmware.com>
16679
16680 * tracepoint.c (tracepoint_finish_step): Fix loop variable.
16681
16682 * server.c (handle_v_run): Free alloced buffer on early return.
16683
e637a4f5
YQ
166842011-03-09 Yao Qi <yao@codesourcery.com>
16685
16686 Revert:
16687 2011-03-04 Yao Qi <yao@codesourcery.com>
16688
16689 * Makefile.in: Remove GNU make feature --directory.
16690
16691 2011-03-05 Yao Qi <yao@codesourcery.com>
16692
16693 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
16694 (subdir_do): New make target. Copied from gdb/Makefile.
16695 (maintainer-clean, realclean, distclean, clean): Call corresponding
16696 make targets in common/Makefile.
16697
16698 2011-02-11 Yao Qi <yao@codesourcery.com>
16699
16700 * configure.ac: Call AC_PROG_RANLIB.
16701 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
16702 * configure: Regenerate.
16703
e6edda56
JK
167042011-03-07 Jan Kratochvil <jan.kratochvil@redhat.com>
16705
16706 * remote-utils.c (putpkt_binary_1): Calculate BUF2 size dynamically.
16707
e5141119
JB
167082011-03-06 Yao Qi <yao@codesourcery.com>
16709
16710 * Makefile.in (REQUIRED_SUBDIRS): Remove $(LIBCOMMON_DIR).
16711
64794aa4
JB
167122011-03-05 Yao Qi <yao@codesourcery.com>
16713
16714 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
16715 (subdir_do): New make target. Copied from gdb/Makefile.
16716 (maintainer-clean, realclean, distclean, clean): Call corresponding
16717 make targets in common/Makefile.
16718
7a762829
YQ
167192011-03-04 Yao Qi <yao@codesourcery.com>
16720
16721 * Makefile.in: Remove GNU make feature --directory.
16722
348af9f7
MS
167232011-03-04 Michael Snyder <msnyder@vmware.com>
16724
16725 * server.c (queue_stop_reply): Call xmalloc not malloc.
16726
167272011-03-02 Michael Snyder <msnyder@vmware.com>
16728
16729 * linux-arm-low.c (arm_arch_setup): Replace malloc with xmalloc.
16730
9f72fee2
MS
167312011-02-28 Michael Snyder <msnyder@vmware.com>
16732
588eebee
MS
16733 * tracepoint.c (cmd_qtv): Discard unused value 'packet'.
16734 (cmd_qtframe): Ditto.
16735 (cmd_qtbuffer): Ditto.
16736 (cmd_bigqtbuffer): Ditto.
16737
9f72fee2
MS
16738 * utils.c (decimal2str): Initialize 'width' to nine, then
16739 don't mess with it.
16740
8040bd49
UW
167412011-02-28 Ulrich Weigand <uweigand@de.ibm.com>
16742
16743 * hostio.c (require_data): Free *data, not data.
16744
7e52cbd0
JK
167452011-02-28 Jan Kratochvil <jan.kratochvil@redhat.com>
16746
16747 * hostio.c (require_data): Use free, not xfree.
16748
9130f83e
MS
167492011-02-27 Michael Snyder <msnyder@vmware.com>
16750
4b812f4e
MS
16751 * server.c (handle_query): Discard unused value.
16752
9130f83e
MS
16753 * hostio.c (require_data): Free malloc memory before returning
16754 error.
16755
69d37113
MS
167562011-02-26 Michael Snyder <msnyder@vmware.com>
16757
16758 * linux-low.c (list_threads): Call closedir for dirent.
16759
35f5825a
MS
167602011-02-27 Michael Snyder <msnyder@vmware.com>
16761
2a589cef
MS
16762 * i386-low.c (i386-length_and_rw_bits): Comment the fact that
16763 a case statement falls through.
16764
0adea5f7
MS
16765 * linux-low.c (linux_xfer_siginfo): Fix fencepost error.
16766
35f5825a
MS
16767 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Fix fencepost error
16768 in comparison.
16769
238f1c74
MS
167702011-02-26 Michael Snyder <msnyder@vmware.com>
16771
16772 * utils.c (decimal2str): Eliminate dead code and dead param.
16773 (pulongest): Drop dead param from call to decimal2str.
16774 (plongest): Ditto.
16775
633ff500
JB
167762011-02-24 Joel Brobecker <brobecker@adacore.com>
16777
16778 Revert the following patch (not approved yet):
16779 2011-02-21 Hui Zhu <teawater@gmail.com>
16780 * tracepoint.c (tp_printf): New function.
16781 (eval_agent_expr): Handle gdb_agent_op_printf.
16782
f9c6ff72
HZ
167832011-02-21 Hui Zhu <teawater@gmail.com>
16784
16785 * tracepoint.c (tp_printf): New function.
16786 (eval_agent_expr): Handle gdb_agent_op_printf.
16787
94d5e490
TT
167882011-02-18 Tom Tromey <tromey@redhat.com>
16789
16790 * Makefile.in (tracepoint-ipa.o): Depend on ax.def.
16791 (tracepoint.o): Likewise.
16792 * tracepoint.c (enum gdb_agent_op): Use ax.def.
16793 (gdb_agent_op_names): Likewise.
16794
c7f96d2b
TT
167952011-02-18 Tom Tromey <tromey@redhat.com>
16796
16797 * tracepoint.c (enum gdb_agent_op) <gdb_agent_op_pick,
16798 gdb_agent_op_rot>: New constants.
16799 (gdb_agent_op_names): Add pick and roll.
16800 (eval_agent_expr) <gdb_agent_op_pick, gdb_agent_op_rot>: New
16801 cases.
16802
0feedb2c
JK
168032011-02-15 Jan Kratochvil <jan.kratochvil@redhat.com>
16804
16805 * aclocal.m4: Regenerated with aclocal-1.11.1.
16806
b3b9301e
PA
168072011-02-14 Pedro Alves <pedro@codesourcery.com>
16808
16809 * server.c (handle_qxfer_traceframe_info): New.
16810 (qxfer_packets): Register "traceframe-info".
16811 (handle_query): Report support for qXfer:traceframe-info:read+.
16812 * tracepoint.c (match_blocktype): New.
16813 (traceframe_find_block_type): Rename to ...
16814 (traceframe_walk_blocks): ... this. Add callback filter argument,
16815 and use it.
16816 (traceframe_find_block_type): New, reimplemented on top of
16817 traceframe_walk_blocks.
16818 (build_traceframe_info_xml): New.
16819 (traceframe_read_info): New.
16820 * server.h (traceframe_read_info): Declare.
16821
4f3e6fb7
YQ
168222011-02-11 Yao Qi <yao@codesourcery.com>
16823
16824 * configure.ac: Call AC_PROG_RANLIB.
16825 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
16826 * configure: Regenerate.
16827
764880b7
PA
168282011-02-07 Pedro Alves <pedro@codesourcery.com>
16829
16830 * server.c (gdb_read_memory): Change return semantics to allow
16831 partial transfers.
16832 (handle_search_memory_1): Adjust.
16833 (process_serial_event) <'m' packet>: Handle partial transfers.
16834 * tracepoint.c (traceframe_read_mem): Handle partial transfers.
16835
1c79eb8a
PA
168362011-01-28 Pedro Alves <pedro@codesourcery.com>
16837
16838 * regcache.c (init_register_cache): Initialize
16839 regcache->register_status.
16840 (free_register_cache): Release regcache->register_status.
16841 (regcache_cpy): Copy register_status.
16842 (registers_to_string): Print 'x's for unavailable registers.
16843 (supply_register): Mark the register's status valid or
16844 unavailable, depending on whether a buffer was passed in or not.
16845 (supply_register_zeroed): New.
16846 (supply_regblock): Mark the registers' status valid or
16847 unavailable, depending on whether a buffer was passed in or not.
16848 * regcache.h (REG_UNAVAILABLE, REG_VALID): New defines.
16849 (struct regcache): New `register_status' field.
16850 (supply_register_zeroed): Declare.
16851 * i387-fp.c (i387_xsave_to_cache): Zero out registers using
16852 supply_register_zeroed, rather than passing a NULL buffer to
16853 supply_register.
16854 * tracepoint.c (fetch_traceframe_registers): Update comment.
16855
85724a0e
PA
168562011-01-28 Pedro Alves <pedro@codesourcery.com>
16857
16858 * i387-fp.c (i387_xsave_to_cache): Make passing NULL as register
16859 buffer explicit.
16860
d08aafef
PA
168612011-01-25 Pedro Alves <pedro@codesourcery.com>
16862
16863 * server.h (decode_xfer_write): Change prototype.
16864 * remote-utils.c (decode_xfer_write): Remove `annex' parameter,
16865 and don't extract the annex here.
16866 * server.c (decode_xfer_read): Remove `annex' parameter,
16867 and don't extract the annex here.
16868 (decode_xfer): New.
16869 (struct qxfer): New.
16870 (handle_qxfer_auxv, handle_qxfer_features, handle_qxfer_libraries)
16871 (handle_qxfer_osdata, handle_qxfer_siginfo, handle_qxfer_spu)
16872 (handle_qxfer_statictrace): New functions, abstracted out from
16873 handle_query, and made to use the struct qxfer interface.
16874 (handle_threads_qxfer_proper): Rename to ...
16875 (handle_qxfer_threads_proper): ... this.
16876 (handle_threads_qxfer): Rename to ...
16877 (handle_qxfer_threads): ... this. Adjust.
16878 (qxfer_packets): New array.
16879 (handle_qxfer): New function.
16880 (handle_query): Use handle_qxfer.
16881
493e2a69
MS
168822011-01-05 Michael Snyder <msnyder@msnyder-server.eng.vmware.com>
16883
16884 * gdbreplay.c: Shorten lines of >= 80 columns.
16885 * linux-low.c: Ditto.
16886 * linux-ppc-low.c: Ditto.
16887 * linux-s390-low.c: Ditto.
16888 * linux-sparc-low.c: Ditto.
16889 * linux-x86-low.c: Ditto.
16890 * linux-xtensa-low.c: Ditto.
16891 * mem-break.c: Ditto.
16892 * nto-low.c: Ditto.
16893 * regcache.h: Ditto.
16894 * remote-utils.c: Ditto.
16895 * server.c: Ditto.
16896 * server.h: Ditto.
16897 * thread-db.c: Ditto.
16898 * tracepoint.c: Ditto.
16899 * utils.c: Ditto.
16900 * win32-low.h: Ditto.
16901
44944448
JB
169022011-01-05 Joel Brobecker <brobecker@adacore.com>
16903
16904 * gdbserver/configure.ac, gdbserver/gdbserver.1: Copyright year
16905 update.
16906
71ce852c
JB
169072011-01-01 Joel Brobecker <brobecker@adacore.com>
16908
16909 * server.c (gdbserver_version): Update copyright year in version
16910 output.
16911 * gdbreplay.c (gdbreplay_version): Ditto.
16912
eb826dc6
MF
169132010-12-29 Jie Zhang <jie.zhang@analog.com>
16914
16915 * configure.srv (bfin-*-*linux*): Handle Blackfin/Linux targets.
16916 * linux-bfin-low.c: New file.
16917 * linux-low.c: Define PT_TEXT_ADDR, PT_TEXT_END_ADDR, and
16918 PT_DATA_ADDR for BFIN targets.
16919 * Makefile.in (SFILES): Add linux-bfin-low.c.
16920 (clean): Remove reg-bfin.c.
16921 (linux-bfin-low.o, reg-bfin.o, reg-bfin.c): New targets.
16922 * README: Mention supported Blackfin targets.
16923
39ab222a
MF
169242010-12-23 Mike Frysinger <vapier@gentoo.org>
16925
16926 * .gitignore: New file.
16927
a1f2ce7d
MF
169282010-11-16 Mike Frysinger <vapier@gentoo.org>
16929
16930 * linux-low.c (linux_tracefork_child): Add char* cast to arg.
16931
f474844c
JZ
169322010-10-22 Jie Zhang <jie@codesourcery.com>
16933
16934 * Makefile.in: Add FLAGS_TO_PASS variable.
16935 (install): Remove dependency of install-only and recursively
16936 invoke make for install-only.
16937
f1048712
DE
169382010-10-04 Doug Evans <dje@google.com>
16939
16940 * Makefile.in (uninstall): Use $(DESTDIR).
16941
b53a1623
PA
169422010-09-24 Pedro Alves <pedro@codesourcery.com>
16943
e6ee044d
PA
16944 PR gdb/11842
16945
b53a1623
PA
16946 * linux-x86-low.c (compat_siginfo_from_siginfo)
16947 (siginfo_from_compat_siginfo): Also copy si_pid and si_uid when
16948 si_code is < 0. Check for si_code == SI_TIMER before checking for
16949 si_code < 0.
16950
fa1bd1e4
JB
169512010-09-13 Joel Brobecker <brobecker@adacore.com>
16952
16953 * lynx-i386-low.c: New file.
16954 * configure.srv: Add handling of i[34567]86-*-lynxos* targets.
16955
47fac8f8
JB
169562010-09-13 Joel Brobecker <brobecker@adacore.com>
16957
16958 * lynx-low.c (ptrace_request_to_str): Remove handling for
16959 request values that have been removed in LynxOS 5.x.
16960
1adfc54d
JB
169612010-09-13 Joel Brobecker <brobecker@adacore.com>
16962
16963 * lynx-low.c, lynx-ppc-loc.c: Include <sys/ptrace.h> instead of
16964 <ptrace.h>
16965
c2a66c29
NS
169662010-09-09 Nathan Sidwell <nathan@codesourcery.com>
16967
16968 * configure.ac: Add --enable-inprocess-agent option.
16969 * configure: Rebuilt.
16970
32fcada3
YQ
169712010-09-06 Yao Qi <yao@codesourcery.com>
16972
16973 * linux-low.c (linux_kill): Remove unused variable.
16974 (linux_stabilize_threads): Likewise.
16975 * server.c (start_inferior): Likewise.
16976 (queue_stop_reply_callback): Likewise.
16977 * tracepoint.c (do_action_at_tracepoint): Likewise.
16978
0cccb683
YQ
169792010-09-06 Yao Qi <yao@codesourcery.com>
16980
16981 * linux-low.c (maybe_move_out_of_jump_pad): Restore current_inferior
16982 on return.
16983
423ec54c
JK
169842010-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
16985
16986 * target.c (mywait) <TARGET_WAITKIND_EXITED>: Fix to use INTEGER.
16987
12ac6819
PA
169882010-09-06 Pedro Alves <pedro@codesourcery.com>
16989
16990 * Makefile.in (install-only): Replace $IPA_DEPFILES with
16991 "$(IPA_DEPFILES)".
16992
8ed54b31
JB
169932010-09-01 Joel Brobecker <brobecker@adacore.com>
16994
16995 * gdbserver/lynx-low.c, gdbserver/lynx-low.h,
16996 gdbserver/lynx-ppc-low.c: New files.
16997 * Makefile.in (lynx_low_h): New variable.
16998 (lynx-low.o, lynx-ppc-low.o): New rules.
16999 * configure.ac: On LynxOS, link with -lnetinet.
17000 * configure.srv: Add handling of powerpc-*-lynxos* targets.
17001 * configure: regenerate.
17002
bb0116a4
JB
170032010-09-01 Joel Brobecker <brobecker@adacore.com>
17004
17005 * Makefile.in (vasprintf.o, vsnprintf.o): New rules.
17006 * configure.ac: Add check for vasprintf and vsnprintf.
17007 * configure, config.in: Regenerate.
17008 * server.h (vasprintf, vsnprintf): Add conditional declarations.
17009
a778ab81 170102010-09-01 Joel Brobecker <brobecker@adacore.com>
17011
17012 * gdbreplay.c: Move include of alloca.h up, next to include of
17013 malloc.h.
17014 * server.h: Add include of malloc.h.
17015 * mem-break.c: Remove include of malloc.h.
17016 * server.c, tracepoint.c, utils.c, win32-low.c: Likewise.
17017
8b034a19 170182010-09-01 Joel Brobecker <brobecker@adacore.com>
17019
17020 * Makefile.in (memmem.o): Build with -Wno-error.
17021
170222010-09-01 Joel Brobecker <brobecker@adacore.com>
17023
17024 * utils.c (xsnprintf): Make non-static.
17025 * server.h: Add xsnprintf declaration.
17026 * linux-low.c, nto-low.c, target.c, thread-db.c, tracepoint.c:
17027 replace calls to snprintf by calls to xsnprintf throughout.
17028
170292010-09-01 Joel Brobecker <brobecker@adacore.com>
17030
17031 * configure.ac: Add configure check for alloca.
17032 * configure, config.in: Regenerate.
17033 * server.h: Include alloca.h if it exists.
17034 * gdbreplay.c: Include alloca.h if it exists.
17035
1a981360
PA
170362010-08-28 Pedro Alves <pedro@codesourcery.com>
17037
17038 * linux-low.c (__SIGRTMIN): Define if not already defined.
17039 (linux_create_inferior): Check for __ANDROID__ rather than
17040 __SIGRTMIN.
17041 (enqueue_one_deferred_signal): Don't requeue non-RT signals that
17042 are already deferred.
17043 (linux_wait_1): Check for __ANDROID__ rather than __SIGRTMIN.
17044 (linux_resume_one_thread): Don't queue a SIGSTOP if the lwp is
17045 stopped and already has a pending signal to report.
17046 (proceed_one_lwp): : Don't queue a SIGSTOP if the lwp already has
17047 a pending signal to report or is moving out of a jump pad.
17048 (linux_init_signals): Check for __ANDROID__ rather than
17049 __SIGRTMIN.
17050
b4d51a55
PA
170512010-08-28 Pedro Alves <pedro@codesourcery.com>
17052
17053 * linux-low.c (linux_stabilize_threads): Wrap debug output in a
17054 debug_threads check. Avoid a linear search when not doing debug
17055 output.
17056
ec48365d
PA
170572010-08-27 Pedro Alves <pedro@codesourcery.com>
17058
17059 * event-loop.c (event_handle_func): Adjust to use gdb_fildes_t.
17060 (struct gdb_event) <fd>: Change type to gdb_fildes_t.
17061 (struct file_handler) <fd>: Change type to gdb_fildes_t.
17062 (process_event): Change local fd's type to gdb_fildes_t.
17063 (create_file_handler): Adjust prototype.
17064 (delete_file_handler): Adjust prototype.
17065 (handle_file_event): Adjust prototype. Use pfildes.
17066 (create_file_event): Adjsut prototype.
17067 * remote-utils.c (remote_desc, listen_desc): Change type to
17068 gdb_fildes_t.
17069 * server.h: New gdb_fildes_t typedef.
17070 [USE_WIN32API]: Include winsock2.h.
17071 (delete_file_handler, add_file_handler): Adjust prototypes.
17072 (pfildes): Declare.
17073 * utils.c (pfildes): New.
17074
854d88f0
PA
170752010-08-27 Pedro Alves <pedro@codesourcery.com>
17076
17077 * configure.ac (build_warnings): Add -Wno-char-subscripts.
17078 * configure: Regenerate.
17079
0146f85b
PA
170802010-08-27 Pedro Alves <pedro@codesourcery.com>
17081
17082 * linux-low.c (linux_unprepare_to_access_memory): Rename to ...
17083 (linux_done_accessing_memory): ... this.
17084 (linux_target_ops): Adjust.
17085 * linux-x86-low.c (x86_insert_point, x86_remove_point): Adjust.
17086 * nto-low.c (nto_target_ops): Adjust comment.
17087 * server.c (gdb_read_memory, gdb_write_memory): Adjust.
17088 * spu-low.c (spu_target_ops): Adjust comment.
17089 * target.h (target_ops): Rename unprepare_to_access_memory field
17090 to done_accessing_memory.
17091 (unprepare_to_access_memory): Rename to ...
17092 (done_accessing_memory): ... this.
17093
90d74c30
PA
170942010-08-26 Pedro Alves <pedro@codesourcery.com>
17095
17096 * linux-low.c (linux_prepare_to_access_memory): New.
17097 (linux_unprepare_to_access_memory): New.
17098 (linux_target_ops): Install them.
17099 * server.c (read_memory): Rename to ...
17100 (gdb_read_memory): ... this. Use
17101 prepare_to_access_memory/prepare_to_access_memory.
17102 (write_memory): Rename to ...
17103 (gdb_write_memory): ... this. Use
17104 prepare_to_access_memory/prepare_to_access_memory.
17105 (handle_search_memory_1): Adjust.
17106 (process_serial_event): Adjust.
17107 * target.h (struct target_ops): New fields
17108 prepare_to_access_memory and unprepare_to_access_memory.
17109 (prepare_to_access_memory, unprepare_to_access_memory): New.
17110 * linux-x86-low.c (x86_insert_point, x86_remove_point): Use
17111 prepare_to_access_memory/prepare_to_access_memory.
17112 * nto-low.c (nto_target_ops): Adjust.
17113 * spu-low.c (spu_target_ops): Adjust.
17114 * win32-low.c (win32_target_ops): Adjust.
17115
fd467969
PA
171162010-08-26 Pedro Alves <pedro@codesourcery.com>
17117
17118 * Makefile.in (WARN_CFLAGS): Get it from configure.
17119 (WERROR_CFLAGS): New.
17120 (INTERNAL_CFLAGS): Add WERROR_CFLAGS.
17121 * configure.ac: Introduce --enable-werror, which adds -Werror to
17122 the compiler command line. Enabled by default. Disable with
17123 --disable-werror. Add -Wdeclaration-after-statement
17124 Wpointer-arith and -Wformat-nonliteral to warning flags.
17125 * configure: Regenerate.
17126
331e2f5f
PA
171272010-08-26 Pedro Alves <pedro@codesourcery.com>
17128
17129 * mem-break.c [HAVE_MALLOC_H]: Include malloc.h.
17130
e581f2b4
PA
171312010-08-26 Pedro Alves <pedro@codesourcery.com>
17132
17133 * gdbreplay.c (remote_error): New.
17134 (gdbchar): New.
17135 (expect): Use gdbchar. Check for error reading from GDB.
17136 Clarify sync error output.
17137 (play): Check for errors writing to GDB.
17138 * linux-low.c (sigchld_handler): Really ignore `write' errors.
17139 * remote-utils.c (getpkt): Check for errors writing to the remote
17140 descriptor.
17141
3c11dd79
PA
171422010-08-25 Pedro Alves <pedro@codesourcery.com>
17143
17144 * linux-low.c (linux_wait_1): Move non-debugging code out of
17145 `debug_threads' control.
17146
d20a8ad9
PA
171472010-08-25 Pedro Alves <pedro@codesourcery.com>
17148
17149 * linux-low.c (linux_wait_1): Don't set last_status here.
17150 * server.c (push_event, queue_stop_reply_callback): Assert we're
17151 not pushing a TARGET_WAITKIND_IGNORE event.
17152 (start_inferior, start_inferior, attach_inferior, handle_v_cont)
17153 (myresume, handle_target_event): Set the thread's last_resume_kind
17154 and last_status from the target returned status.
17155
964e4306
PA
171562010-08-25 Pedro Alves <pedro@codesourcery.com>
17157
17158 PR threads/10729
17159
17160 * linux-x86-low.c (update_debug_registers_callback): New.
17161 (i386_dr_low_set_addr): Use it.
17162 (i386_dr_low_get_addr): New.
17163 (i386_dr_low_set_control): Use update_debug_registers_callback.
17164 (i386_dr_low_get_control): New.
17165 (i386_dr_low_get_status): Adjust.
17166 * linux-low.c (linux_stop_lwp): New.
17167 * linux-low.h (linux_stop_lwp): Declare.
17168
17169 * i386-low.c (I386_DR_GET_RW_LEN): Take the dr7 contents as
17170 argument instead of a i386_debug_reg_state.
17171 (I386_DR_WATCH_HIT): Take the dr6 contents as argument instead of
17172 a i386_debug_reg_state.
17173 (i386_insert_aligned_watchpoint): Adjust.
17174 (i386_remove_aligned_watchpoint): Adjust.
17175 (i386_low_stopped_data_address): Read the debug registers from the
17176 inferior instead of from the mirrors.
17177 * i386-low.h (struct i386_debug_reg_state): Extend comment.
17178 (i386_dr_low_get_addr): Declare.
17179 (i386_dr_low_get_control): Declare.
17180 (i386_dr_low_get_status): Change prototype.
17181
17182 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): New globals.
17183 (i386_dr_low_get_addr): New.
17184 (i386_dr_low_get_control): New.
17185 (i386_dr_low_get_status): Adjust prototype. Return
17186 dr_status_mirror.
17187 (i386_initial_stuff): Clear dr_status_mirror and
17188 dr_control_mirror.
17189 (i386_get_thread_context): Adjust.
17190 (i386_set_thread_context): Adjust.
17191 (i386_thread_added): Adjust.
17192
5f21a75b
PA
171932010-08-24 Pedro Alves <pedro@codesourcery.com>
17194
17195 * linux-low.h (linux_thread_area): Delete declaration.
17196
3e4c1235
TS
171972010-08-11 Thomas Schwinge <thomas@codesourcery.com>
17198
17199 * linux-low.c (linux_wait_1): Correctly return the ptid of the child
17200 after its termination.
17201
1971b033
PA
172022010-08-09 Pedro Alves <pedro@codesourcery.com>
17203
17204 * linux-low.c (gdb_wants_lwp_stopped): Delete.
17205 (gdb_wants_all_stopped): Delete.
17206 (linux_wait_1): Don't call them.
17207 * server.c (handle_v_cont): Tag all threads as want-stopped.
17208 (gdb_wants_thread_stopped): Fix comments. Tag the thread that
17209 stopped as "client-wants-stopped".
17210
310444ac
PA
172112010-07-31 Pedro Alves <pedro@codesourcery.com>
17212
17213 * Makefile.in (signals_h): New.
17214 (server_h): Depend on it.
17215 (server.o): Don't depend on $(signals_def).
17216 (signals.o): Depend on $(signals_def).
17217
a19cae16
JK
172182010-07-31 Jan Kratochvil <jan.kratochvil@redhat.com>
17219
17220 * Makefile.in (signals_def): New.
17221 (server_h): Append include/gdb/signals.h and signals_def.
17222 (server.o): Append signals_def.
17223
30d50328
JK
172242010-07-25 Jan Kratochvil <jan.kratochvil@redhat.com>
17225
17226 * server.c (handle_target_event): Use target_signal_to_host for
17227 resume_info.sig initialization.
17228 * target.h (struct thread_resume) <sig>: New comment.
17229
5c3216e2
OS
172302010-07-20 Ozkan Sezer <sezeroz@gmail.com>
17231
c6f46ca0
OS
17232 * server.c (handle_query): strcpy() the returned string from paddress()
17233 instead of sprintf().
5c3216e2
OS
17234 * utils.c (paddress): Return phex_nz().
17235
6bd31874
JB
172362010-07-07 Joel Brobecker <brobecker@adacore.com>
17237
17238 * server.c (handle_v_cont): Call mourn_inferior if process
17239 just exited.
17240 (myresume): Likewise.
17241
0fb4aa4b
PA
172422010-07-01 Pedro Alves <pedro@codesourcery.com>
17243
17244 Static tracepoints, and integration with UST.
17245
17246 * configure.ac: Handle --with-ust. substitute ustlibs and ustinc.
17247 * mem-break.c (uninsert_all_breakpoints)
17248 (reinsert_all_breakpoints): New.
17249 * mem-break.h (reinsert_all_breakpoints, uninsert_all_breakpoints):
17250 * tracepoint.c (ust_loaded, helper_thread_id, cmd_buf): New.
17251 (gdb_agent_ust_loaded, helper_thread_id)
17252 (gdb_agent_helper_thread_id): New macros.
17253 (struct ipa_sym_addresses): Add addr_ust_loaded,
17254 addr_helper_thread_id, addr_cmd_buf.
17255 (symbol_list): Add ust_loaded, helper_thread_id, cmd_buf.
17256 (in_process_agent_loaded_ust): New.
17257 (write_e_ust_not_loaded): New.
17258 (maybe_write_ipa_ust_not_loaded): New.
17259 (struct collect_static_trace_data_action): New.
17260 (enum tracepoint_type) <static_tracepoint>: New.
17261 (struct tracepoint) <handle>: Mention static tracepoints.
17262 (struct static_tracepoint_ctx): New.
17263 (CMD_BUF_SIZE): New.
17264 (add_tracepoint_action): Handle static tracepoint actions.
17265 (unprobe_marker_at): New.
17266 (clear_installed_tracepoints): Handle static tracepoints.
17267 (cmd_qtdp): Handle static tracepoints.
17268 (probe_marker_at): New.
17269 (cmd_qtstart): Handle static tracepoints.
17270 (response_tracepoint): Handle static tracepoints.
17271 (cmd_qtfstm, cmd_qtsstm, cmd_qtstmat): New.
17272 (handle_tracepoint_query): Handle qTfSTM, qTsSTM and qTSTMat.
17273 (get_context_regcache): Handle static tracepoints.
17274 (do_action_at_tracepoint): Handle static tracepoint actions.
17275 (traceframe_find_block_type): Handle static trace data blocks.
17276 (traceframe_read_sdata): New.
17277 (download_tracepoints): Download static tracepoint actions.
17278 [HAVE_UST] Include ust/ust.h, dlfcn.h, sys/socket.h, and sys/un.h.
17279 (GDB_PROBE_NAME): New.
17280 (ust_ops): New.
17281 (GET_UST_SYM): New.
17282 (USTF): New.
17283 (dlsym_ust): New.
17284 (ust_marker_to_static_tracepoint): New.
17285 (gdb_probe): New.
17286 (collect_ust_data_at_tracepoint): New.
17287 (gdb_ust_probe): New.
17288 (UNIX_PATH_MAX, SOCK_DIR): New.
17289 (gdb_ust_connect_sync_socket): New.
17290 (resume_thread, stop_thread): New.
17291 (run_inferior_command): New.
17292 (init_named_socket): New.
17293 (gdb_ust_socket_init): New.
17294 (cstr_to_hexstr): New.
17295 (next_st): New.
17296 (first_marker, next_marker): New.
17297 (response_ust_marker): New.
17298 (cmd_qtfstm, cmd_qtsstm): New.
17299 (unprobe_marker_at, probe_marker_at): New.
17300 (cmd_qtstmat, gdb_ust_thread): New.
17301 (gdb_ust_init): New.
17302 (initialize_tracepoint_ftlib): Call gdb_ust_init.
17303 * linux-amd64-ipa.c [HAVE_UST]: Include ust/processor.h
17304 (ST_REGENTRY): New.
17305 (x86_64_st_collect_regmap): New.
17306 (X86_64_NUM_ST_COLLECT_GREGS): New.
17307 (AMD64_RIP_REGNUM): New.
17308 (supply_static_tracepoint_registers): New.
17309 * linux-i386-ipa.c [HAVE_UST]: Include ust/processor.h
17310 (ST_REGENTRY): New.
17311 (i386_st_collect_regmap): New.
17312 (i386_NUM_ST_COLLECT_GREGS): New.
17313 (supply_static_tracepoint_registers): New.
17314 * server.c (handle_query): Handle qXfer:statictrace:read.
17315 <qSupported>: Report support for StaticTracepoints, and
17316 qXfer:statictrace:read features.
17317 * server.h (traceframe_read_sdata)
17318 (supply_static_tracepoint_registers): Declare.
17319 * remote-utils.c (convert_int_to_ascii, hexchars, ishex, tohex)
17320 (unpack_varlen_hex): Include in IPA build.
17321 * Makefile.in (ustlibs, ustinc): New.
17322 (IPA_OBJS): Add remote-utils-ipa.o.
17323 ($(IPA_LIB)): Link -ldl and -lpthread.
17324 (UST_CFLAGS): New.
17325 (IPAGENT_CFLAGS): Add UST_CFLAGS.
17326 * config.in, configure: Regenerate.
17327
9e4344e5
PA
173282010-06-20 Ian Lance Taylor <iant@google.com>
17329 Pedro Alves <pedro@codesourcery.com>
17330
17331 * linux-x86-low.c (always_true): Delete.
17332 (EMIT_ASM, EMIT_ASM32): Use an uncondition asm jmp instead of
17333 trying to fool the compiler with always_true.
17334
c6beb2cb
PA
173352010-06-20 Pedro Alves <pedro@codesourcery.com>
17336
17337 * tracepoint.c (condition_true_at_tracepoint): Don't run compiled
17338 conditions in gdbserver.
17339
d2ed6730
UW
173402010-06-19 Ulrich Weigand <uweigand@de.ibm.com>
17341
17342 * spu-low.c (spu_read_memory): Wrap around local store limit.
17343 (spu_write_memory): Likewise.
17344
4e29fb54
PA
173452010-06-15 Pedro Alves <pedro@codesourcery.com>
17346
17347 * linux-x86-low.c (amd64_emit_const, amd64_emit_void_call_2)
17348 (i386_emit_const, i386_emit_void_call_2): Replace int64_t uses with
17349 LONGEST uses.
17350 * server.h (struct emit_ops): Replace int64_t uses with LONGEST
17351 uses.
17352 * tracepoint.c (emit_const, emit_void_call_2): Replace int64_t
17353 uses with LONGEST uses.
17354
6a271cae
PA
173552010-06-14 Stan Shebs <stan@codesourcery.com>
17356 Pedro Alves <pedro@codesourcery.com>
17357
17358 Bytecode compiler.
17359
17360 * linux-x86-low.c: Include limits.h.
17361 (add_insns): New.
17362 (always_true): New.
17363 (EMIT_ASM): New.
17364 (EMIT_ASM32): New.
17365 (amd64_emit_prologue, amd64_emit_epilogue, amd64_emit_add)
17366 (amd64_emit_sub, amd64_emit_mul, amd64_emit_lsh)
17367 (amd64_emit_rsh_signed, amd64_emit_rsh_unsigned, amd64_emit_ext,
17368 (amd64_emit_log_not, amd64_emit_bit_and, amd64_emit_bit_or)
17369 (amd64_emit_bit_xor, amd64_emit_bit_not, amd64_emit_equal,
17370 (amd64_emit_less_signed, amd64_emit_less_unsigned, amd64_emit_ref,
17371 (amd64_emit_if_goto, amd64_emit_goto, amd64_write_goto_address)
17372 (amd64_emit_const, amd64_emit_call, amd64_emit_reg)
17373 (amd64_emit_pop, amd64_emit_stack_flush, amd64_emit_zero_ext)
17374 (amd64_emit_swap, amd64_emit_stack_adjust, amd64_emit_int_call_1)
17375 (amd64_emit_void_call_2): New.
17376 (amd64_emit_ops): New.
17377 (i386_emit_prologue, i386_emit_epilogue, i386_emit_add)
17378 (i386_emit_sub,i386_emit_mul, i386_emit_lsh, i386_emit_rsh_signed)
17379 (i386_emit_rsh_unsigned, i386_emit_ext, i386_emit_log_not)
17380 (i386_emit_bit_and, i386_emit_bit_or, i386_emit_bit_xor)
17381 (i386_emit_bit_not, i386_emit_equal, i386_emit_less_signed)
17382 (i386_emit_less_unsigned, i386_emit_ref, i386_emit_if_goto)
17383 (i386_emit_goto, i386_write_goto_address, i386_emit_const)
17384 (i386_emit_call, i386_emit_reg, i386_emit_pop)
17385 (i386_emit_stack_flush, i386_emit_zero_ext, i386_emit_swap)
17386 (i386_emit_stack_adjust, i386_emit_int_call_1)
17387 (i386_emit_void_call_2): New.
17388 (i386_emit_ops): New.
17389 (x86_emit_ops): New.
17390 (the_low_target): Install x86_emit_ops.
17391 * server.h (struct emit_ops): New.
17392 (get_raw_reg_func_addr): Declare.
17393 (current_insn_ptr, emit_error): Declare.
17394 * tracepoint.c (get_raw_reg, get_trace_state_variable_value)
17395 (set_trace_state_variable_value): New defines.
17396 (struct ipa_sym_addresses): New fields addr_get_raw_reg,
17397 addr_get_trace_state_variable_value and
17398 addr_set_trace_state_variable_value.
17399 (symbol_list): New fields for get_raw_reg,
17400 get_trace_state_variable_value and set_trace_state_variable_value.
17401 (condfn): New typedef.
17402 (struct tracepoint): New field `compiled_cond'.
17403 (do_action_at_tracepoint): Clear compiled_cond.
17404 (get_trace_state_variable_value, set_trace_state_variable_value):
17405 Export in the IPA.
17406 (condition_true_at_tracepoint): If there's a compiled condition,
17407 run that.
17408 (current_insn_ptr, emit_error): New globals.
17409 (struct bytecode_address): New.
17410 (get_raw_reg_func_addr): New.
17411 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul)
17412 (emit_lsh, emit_rsh_signed, emit_rsh_unsigned, emit_ext)
17413 (emit_log_not, emit_bit_and, emit_bit_or, emit_bit_xor)
17414 (emit_bit_not, emit_equal, emit_less_signed, emit_less_unsigned)
17415 (emit_ref, emit_if_goto, emit_goto, write_goto_address, emit_const)
17416 (emit_reg, emit_pop, emit_stack_flush, emit_zero_ext, emit_swap)
17417 (emit_stack_adjust, emit_int_call_1, emit_void_call_2): New.
17418 (compile_tracepoint_condition, compile_bytecodes): New.
17419 * target.h (emit_ops): Forward declare.
17420 (struct target_ops): New field emit_ops.
17421 (target_emit_ops): New.
17422 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): New.
17423 * linux-i386-ipa.c (gdb_agent_get_raw_reg): New.
17424 * linux-low.c (linux_emit_ops): New.
17425 (linux_target_ops): Install it.
17426 * linux-low.h (struct linux_target_ops): New field emit_ops.
17427
92b72907
UW
174282010-06-14 Ulrich Weigand <uweigand@de.ibm.com>
17429
17430 * linux-ppc-low.c (ppc_arch_setup): Use private regcache to test MSR.
17431 * linux-s390-low.c (ppc_arch_setup): Use private regcache to test PSW.
17432
fa593d66
PA
174332010-06-01 Pedro Alves <pedro@codesourcery.com>
17434 Stan Shebs <stan@codesourcery.com>
17435
17436 * Makefile.in (IPA_DEPFILES, extra_libraries): New.
17437 (all): Depend on $(extra_libraries).
17438 (install-only): Install the IPA.
17439 (IPA_OBJS, IPA_LIB): New.
17440 (clean): Remove the IPA lib.
17441 (IPAGENT_CFLAGS): New.
17442 (tracepoint-ipa.o, utils-ipa.o, remote-utils-ipa.o)
17443 (regcache-ipa.o, i386-linux-ipa.o, linux-i386-ipa.o)
17444 (linux-amd64-ipa.o, amd64-linux-ipa.o): New rules.
17445 * linux-amd64-ipa.c, linux-i386-ipa.c: New files.
17446 * configure.ac: Check for atomic builtins support in the compiler.
17447 (IPA_DEPFILES, extra_libraries): Define.
17448 * configure.srv (ipa_obj): Add description.
17449 (ipa_i386_linux_regobj, ipa_amd64_linux_regobj): Define.
17450 (i[34567]86-*-linux*): Set ipa_obj.
17451 (x86_64-*-linux*): Set ipa_obj.
17452 * linux-low.c (stabilizing_threads): New.
17453 (supports_fast_tracepoints): New.
17454 (linux_detach): Stabilize threads before detaching.
17455 (handle_tracepoints): Handle internal tracing breakpoints. Assert
17456 the lwp is either not stabilizing, or is moving out of a jump pad.
17457 (linux_fast_tracepoint_collecting): New.
17458 (maybe_move_out_of_jump_pad): New.
17459 (enqueue_one_deferred_signal): New.
17460 (dequeue_one_deferred_signal): New.
17461 (linux_wait_for_event_1): If moving out of a jump pad, defer
17462 pending signals to later.
17463 (linux_stabilize_threads): New.
17464 (linux_wait_1): Check if threads need moving out of jump pads, and
17465 do it if so.
17466 (stuck_in_jump_pad_callback): New.
17467 (move_out_of_jump_pad_callback): New.
17468 (lwp_running): New.
17469 (linux_resume_one_lwp): Handle moving out of jump pads.
17470 (linux_set_resume_request): Dequeue deferred signals.
17471 (need_step_over_p): Also step over fast tracepoint jumps.
17472 (start_step_over): Also uninsert fast tracepoint jumps.
17473 (finish_step_over): Also reinsert fast tracepoint jumps.
17474 (linux_install_fast_tracepoint_jump): New.
17475 (linux_target_ops): Install linux_stabilize_threads and
17476 linux_install_fast_tracepoint_jump_pad.
17477 * linux-low.h (linux_target_ops) <get_thread_area,
17478 install_fast_tracepoint_jump_pad>: New fields.
17479 (struct lwp_info) <collecting_fast_tracepoint,
17480 pending_signals_to_report, exit_jump_pad_bkpt>: New fields.
17481 (linux_get_thread_area): Declare.
17482 * linux-x86-low.c (jump_insn): New.
17483 (x86_get_thread_area): New.
17484 (append_insns): New.
17485 (push_opcode): New.
17486 (amd64_install_fast_tracepoint_jump_pad): New.
17487 (i386_install_fast_tracepoint_jump_pad): New.
17488 (x86_install_fast_tracepoint_jump_pad): New.
17489 (the_low_target): Install x86_get_thread_area and
17490 x86_install_fast_tracepoint_jump_pad.
17491 * mem-break.c (set_raw_breakpoint_at): Use read_inferior_memory.
17492 (struct fast_tracepoint_jump): New.
17493 (fast_tracepoint_jump_insn): New.
17494 (fast_tracepoint_jump_shadow): New.
17495 (find_fast_tracepoint_jump_at): New.
17496 (fast_tracepoint_jump_here): New.
17497 (delete_fast_tracepoint_jump): New.
17498 (set_fast_tracepoint_jump): New.
17499 (uninsert_fast_tracepoint_jumps_at): New.
17500 (reinsert_fast_tracepoint_jumps_at): New.
17501 (set_breakpoint_at): Use write_inferior_memory.
17502 (uninsert_raw_breakpoint): Use write_inferior_memory.
17503 (check_mem_read): Mask out fast tracepoint jumps.
17504 (check_mem_write): Mask out fast tracepoint jumps.
17505 * mem-break.h (struct fast_tracepoint_jump): Forward declare.
17506 (set_fast_tracepoint_jump): Declare.
17507 (delete_fast_tracepoint_jump)
17508 (fast_tracepoint_jump_here, uninsert_fast_tracepoint_jumps_at)
17509 (reinsert_fast_tracepoint_jumps_at): Declare.
17510 * regcache.c: Don't compile many functions when building the
17511 in-process agent library.
17512 (init_register_cache) [IN_PROCESS_AGENT]: Don't allow allocating
17513 the register buffer in the heap.
17514 (free_register_cache): If the register buffer isn't owned by the
17515 regcache, don't free it.
17516 (set_register_cache) [IN_PROCESS_AGENT]: Don't re-alocate
17517 pre-existing register caches.
17518 * remote-utils.c (convert_int_to_ascii): Constify `from' parameter
17519 type.
17520 (convert_ascii_to_int): : Constify `from' parameter type.
17521 (decode_M_packet, decode_X_packet): Replace the `to' parameter by
17522 a `to_p' pointer to pointer parameter. If TO_P is NULL, malloc
17523 the needed buffer in-place.
17524 (relocate_instruction): New.
17525 * server.c (handle_query) <qSymbols>: If the target supports
17526 tracepoints, give it a chance of looking up symbols. Report
17527 support for fast tracepoints.
17528 (handle_status): Stabilize threads.
17529 (process_serial_event): Adjust.
17530 * server.h (struct fast_tracepoint_jump): Forward declare.
17531 (struct process_info) <fast_tracepoint_jumps>: New field.
17532 (convert_ascii_to_int, convert_int_to_ascii): Adjust.
17533 (decode_X_packet, decode_M_packet): Adjust.
17534 (relocate_instruction): Declare.
17535 (in_process_agent_loaded): Declare.
17536 (tracepoint_look_up_symbols): Declare.
17537 (struct fast_tpoint_collect_status): Declare.
17538 (fast_tracepoint_collecting): Declare.
17539 (force_unlock_trace_buffer): Declare.
17540 (handle_tracepoint_bkpts): Declare.
17541 (initialize_low_tracepoint)
17542 (supply_fast_tracepoint_registers) [IN_PROCESS_AGENT]: Declare.
17543 * target.h (struct target_ops) <stabilize_threads,
17544 install_fast_tracepoint_jump_pad>: New fields.
17545 (stabilize_threads, install_fast_tracepoint_jump_pad): New.
17546 * tracepoint.c [HAVE_MALLOC_H]: Include malloc.h.
17547 [HAVE_STDINT_H]: Include stdint.h.
17548 (trace_debug_1): Rename to ...
17549 (trace_vdebug): ... this.
17550 (trace_debug): Rename to ...
17551 (trace_debug_1): ... this. Add `level' parameter.
17552 (trace_debug): New.
17553 (ATTR_USED, ATTR_NOINLINE): New.
17554 (IP_AGENT_EXPORT): New.
17555 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
17556 (collecting, gdb_collect, stop_tracing, flush_trace_buffer)
17557 (about_to_request_buffer_space, trace_buffer_is_full)
17558 (stopping_tracepoint, expr_eval_result, error_tracepoint)
17559 (tracepoints, tracing, trace_buffer_ctrl, trace_buffer_ctrl_curr)
17560 (trace_buffer_lo, trace_buffer_hi, traceframe_read_count)
17561 (traceframe_write_count, traceframes_created)
17562 (trace_state_variables)
17563 New renaming defines.
17564 (struct ipa_sym_addresses): New.
17565 (STRINGIZE_1, STRINGIZE, IPA_SYM): New.
17566 (symbol_list): New.
17567 (ipa_sym_addrs): New.
17568 (all_tracepoint_symbols_looked_up): New.
17569 (in_process_agent_loaded): New.
17570 (write_e_ipa_not_loaded): New.
17571 (maybe_write_ipa_not_loaded): New.
17572 (tracepoint_look_up_symbols): New.
17573 (debug_threads) [IN_PROCESS_AGENT]: New.
17574 (read_inferior_memory) [IN_PROCESS_AGENT]: New.
17575 (UNKNOWN_SIDE_EFFECTS): New.
17576 (stop_tracing): New.
17577 (flush_trace_buffer): New.
17578 (stop_tracing_bkpt): New.
17579 (flush_trace_buffer_bkpt): New.
17580 (read_inferior_integer): New.
17581 (read_inferior_uinteger): New.
17582 (read_inferior_data_pointer): New.
17583 (write_inferior_data_pointer): New.
17584 (write_inferior_integer): New.
17585 (write_inferior_uinteger): New.
17586 (struct collect_static_trace_data_action): Delete.
17587 (enum tracepoint_type): New.
17588 (struct tracepoint) <type>: New field `type'.
43aaf8b6
PA
17589 <actions_str, step_actions, step_actions_str>: Only include in
17590 GDBserver.
fa593d66
PA
17591 <orig_size, obj_addr_on_target, adjusted_insn_addr>
17592 <adjusted_insn_addr_end, jump_pad, jump_pad_end>: New fields.
17593 (tracepoints): Use IP_AGENT_EXPORT.
17594 (last_tracepoint): Don't include in the IPA.
17595 (stopping_tracepoint): Use IP_AGENT_EXPORT.
17596 (trace_buffer_is_full): Use IP_AGENT_EXPORT.
17597 (alloced_trace_state_variables): New.
17598 (trace_state_variables): Use IP_AGENT_EXPORT.
17599 (traceframe_t): Delete unused variable.
17600 (circular_trace_buffer): Don't include in the IPA.
17601 (trace_buffer_start): Delete.
17602 (struct trace_buffer_control): New.
17603 (trace_buffer_free): Delete.
17604 (struct ipa_trace_buffer_control): New.
17605 (GDBSERVER_FLUSH_COUNT_MASK, GDBSERVER_FLUSH_COUNT_MASK_PREV)
17606 (GDBSERVER_FLUSH_COUNT_MASK_CURR, GDBSERVER_UPDATED_FLUSH_COUNT_BIT):
17607 New.
17608 (trace_buffer_ctrl): New.
17609 (TRACE_BUFFER_CTRL_CURR): New.
17610 (trace_buffer_start, trace_buffer_free, trace_buffer_end_free):
17611 Reimplement as macros.
17612 (trace_buffer_wrap): Delete.
17613 (traceframe_write_count, traceframe_read_count)
17614 (traceframes_created, tracing): Use IP_AGENT_EXPORT.
17615 (struct tracepoint_hit_ctx) <type>: New field.
17616 (struct fast_tracepoint_ctx): New.
17617 (memory_barrier): New.
17618 (cmpxchg): New.
17619 (record_tracepoint_error): Update atomically in the IPA.
17620 (clear_inferior_trace_buffer): New.
17621 (about_to_request_buffer_space): New.
17622 (trace_buffer_alloc): Handle GDBserver and inferior simulatenous
17623 updating the same buffer.
17624 (add_tracepoint): Default the tracepoint's type to trap
17625 tracepoint, and orig_size to -1.
17626 (get_trace_state_variable) [IN_PROCESS_AGENT]: Handle allocated
17627 internal variables.
17628 (create_trace_state_variable): New parameter `gdb'. Handle it.
17629 (clear_installed_tracepoints): Clear fast tracepoint jumps.
17630 (cmd_qtdp): Handle fast tracepoints.
17631 (cmd_qtdv): Adjust.
17632 (max_jump_pad_size): New.
17633 (gdb_jump_pad_head): New.
17634 (get_jump_space_head): New.
17635 (claim_jump_space): New.
17636 (sort_tracepoints): New.
17637 (MAX_JUMP_SIZE): New.
17638 (cmd_qtstart): Handle fast tracepoints. Sync tracepoints with the
17639 IPA.
17640 (stop_tracing) [IN_PROCESS_AGENT]: Don't include the tdisconnected
17641 support. Upload fast traceframes, and delete internal IPA
17642 breakpoints.
17643 (stop_tracing_handler): New.
17644 (flush_trace_buffer_handler): New.
17645 (cmd_qtstop): Upload fast tracepoints.
17646 (response_tracepoint): Handle fast tracepoints.
17647 (tracepoint_finished_step): Upload fast traceframes. Set the
17648 tracepoint hit context's tracepoint type.
17649 (handle_tracepoint_bkpts): New.
17650 (tracepoint_was_hit): Set the tracepoint hit context's tracepoint
17651 type. Add comment about fast tracepoints.
17652 (collect_data_at_tracepoint) [IN_PROCESS_AGENT]: Don't access the
17653 non-existing action_str field.
17654 (get_context_regcache): Handle fast tracepoints.
17655 (do_action_at_tracepoint) [!IN_PROCESS_AGENT]: Don't write the PC
17656 to the regcache.
17657 (fast_tracepoint_from_jump_pad_address): New.
17658 (fast_tracepoint_from_ipa_tpoint_address): New.
17659 (collecting_t): New.
17660 (force_unlock_trace_buffer): New.
17661 (fast_tracepoint_collecting): New.
17662 (collecting): New.
17663 (gdb_collect): New.
17664 (write_inferior_data_ptr): New.
17665 (target_tp_heap): New.
17666 (target_malloc): New.
17667 (download_agent_expr): New.
17668 (UALIGN): New.
17669 (download_tracepoints): New.
17670 (download_trace_state_variables): New.
17671 (upload_fast_traceframes): New.
17672 (IPA_FIRST_TRACEFRAME): New.
17673 (IPA_NEXT_TRACEFRAME_1): New.
17674 (IPA_NEXT_TRACEFRAME): New.
17675 [IN_PROCESS_AGENT]: Include sys/mman.h and fcntl.h.
17676 [IN_PROCESS_AGENT] (gdb_tp_heap_buffer, gdb_jump_pad_buffer)
17677 (gdb_jump_pad_buffer_end): New.
17678 [IN_PROCESS_AGENT] (initialize_tracepoint_ftlib): New.
17679 (initialize_tracepoint): Adjust.
17680 [IN_PROCESS_AGENT]: Allocate the IPA heap, and jump pad scratch
17681 buffer. Initialize the low module.
17682 * utils.c (PREFIX, TOOLNAME): New.
17683 (malloc_failure): Use PREFIX.
17684 (error): In the IPA, an error causes an exit.
17685 (fatal, warning): Use PREFIX.
17686 (internal_error): Use TOOLNAME.
17687 (NUMCELLS): Increase to 10.
17688 * configure, config.in: Regenerate.
17689
d149dd1d
PA
176902010-06-01 Pedro Alves <pedro@codesourcery.com>
17691
17692 * server.c (handle_query) <qSupported>: Do two passes over the
17693 qSupported string to avoid nesting strtok.
17694
f6528abd
JK
176952010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
17696
17697 * Makefile.in (SFILES): Add $(srcdir)/proc-service.list.
17698 (CDEPS): New.
17699 * configure.ac (RDYNAMIC): New AC_MSG_CHECKING wrapping. Test also
17700 -Wl,--dynamic-list.
17701 * configure: Regenerate.
17702 * proc-service.list: New.
17703
ca2a87a0
JK
177042010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
17705
17706 * linux-low.c (linux_core_of_thread): Fix crash on invalid CONTENT.
17707 New comment.
17708
363a6e9f
OS
177092010-05-26 Ozkan Sezer <sezeroz@gmail.com>
17710
17711 * gdbreplay.c (remote_open): Check error return from socket() call by
17712 its equality to -1 not by it being negative.
17713 * remote-utils.c (remote_open): Likewise.
17714
d23b6cb1
PA
177152010-05-23 Pedro Alves <pedro@codesourcery.com>
17716
17717 * config.h: Regenerate.
17718
28d3cf85
MK
177192010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
17720
17721 * linux-m68k-low.c (ps_get_thread_area): Don't define if kernel
17722 doesn't provide PTRACE_GET_THREAD_AREA.
17723
fea36a59
MK
177242010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
17725
17726 * linux-m68k-low.c: Include <asm/ptrace.h>
17727 (ps_get_thread_area): Implement.
17728
24b066ba
DE
177292010-05-03 Doug Evans <dje@google.com>
17730
17731 * event-loop.c (struct callback_event): New struct.
17732 (callback_list): New global.
17733 (append_callback_event, delete_callback_event): New functions.
17734 (process_callback): New function.
17735 (start_event_loop): Call it.
17736 * remote-utils.c (NOT_SCHEDULED): Define.
17737 (readchar_buf, readchar_bufcnt, readchar_bufp): New static globals,
17738 moved out of readchar.
17739 (readchar): Rewrite. Call reschedule before returning.
17740 (reset_readchar): New function.
17741 (remote_close): Call it.
17742 (process_remaining, reschedule): New functions.
17743 * server.h (callback_handler_func): New typedef.
17744 (append_callback_event, delete_callback_event): Declare.
17745
9836d6ea
PA
177462010-05-03 Pedro Alves <pedro@codesourcery.com>
17747
17748 * proc-service.c (ps_pglobal_lookup): Use
17749 thread_db_look_up_one_symbol.
17750 * remote-utils.c (look_up_one_symbol): Add new `may_ask_gdb'
17751 parameter. Use it instead of all_symbols_looked_up.
17752 * server.h (struct process_info) <all_symbols_looked_up>: Delete
17753 field.
17754 (all_symbols_looked_up): Don't declare.
17755 (look_up_one_symbol): Add new `may_ask_gdb' parameter.
17756 * thread-db.c (struct thread_db) <all_symbols_looked_up>: New
17757 field.
17758 (thread_db_look_up_symbols): Adjust call to look_up_one_symbol.
17759 Set all_symbols_looked_up here.
17760 (thread_db_look_up_one_symbol): New.
17761 (thread_db_get_tls_address): Adjust.
17762 (thread_db_load_search, try_thread_db_load_1): Always allocate the
17763 thread_db object on the heap, and tentatively set it in the
17764 process structure.
17765 (thread_db_init): Don't set all_symbols_looked_up here.
17766 * linux-low.h (thread_db_look_up_one_symbol): Declare.
17767
7984d532
PA
177682010-05-03 Pedro Alves <pedro@codesourcery.com>
17769
17770 * linux-low.c (linux_kill, linux_detach): Adjust.
17771 (status_pending_p_callback): Remove redundant statement. Check
17772 for !TARGET_WAITIKIND_IGNORE, instead of
17773 TARGET_WAITKIND_STOPPED.
17774 (handle_tracepoints): Make sure LWP is locked. Adjust.
17775 (linux_wait_for_event_1): Adjust.
17776 (linux_cancel_breakpoints): New.
17777 (unsuspend_one_lwp): New.
17778 (unsuspend_all_lwps): New.
17779 (linux_wait_1): If finishing a step-over, unsuspend all lwps.
17780 (send_sigstop_callback): Change return type to int, add new
17781 `except' parameter and handle it.
17782 (suspend_and_send_sigstop_callback): New.
17783 (stop_all_lwps): Add new `suspend' and `expect' parameters, and
17784 pass them down. If SUSPEND, also increment the lwp's suspend
17785 count.
17786 (linux_resume_one_lwp): Add notice about resuming a suspended LWP.
17787 (need_step_over_p): Don't consider suspended LWPs.
17788 (start_step_over): Adjust.
17789 (proceed_one_lwp): Change return type to int, add new `except'
17790 parameter and handle it.
17791 (unsuspend_and_proceed_one_lwp): New.
17792 (proceed_all_lwps): Use find_inferior instead of
17793 for_each_inferior.
17794 (unstop_all_lwps): Add `unsuspend' parameter. If UNSUSPEND, them
17795 also decrement the suspend count of LWPs. Pass `except' down,
17796 instead of hacking its suspend count.
17797 (linux_pause_all): Add `freeze' parameter. Adjust.
17798 (linux_unpause_all): New.
17799 (linux_target_ops): Install linux_unpause_all.
17800 * server.c (handle_status): Adjust.
17801 * target.h (struct target_ops): New fields `unpause_all' and
17802 `cancel_breakpoints'. Add new parameter to `pause_all'.
17803 (pause_all): Add new `freeze' parameter.
17804 (unpause_all): New.
17805 (cancel_breakpoints): New.
17806 * tracepoint.c (clear_installed_tracepoints): Pause threads, and
17807 cancel breakpoints.
17808 (cmd_qtstart): Pause threads.
17809 (stop_tracing): Pause threads, and cancel breakpoints.
17810 * win32-low.c (win32_target_ops): Adjust.
17811
e471f25b
PA
178122010-05-03 Pedro Alves <pedro@codesourcery.com>
17813
17814 * linux-low.c (linux_wait_for_event_1): Move passing the signal to
17815 the inferior right away from here...
17816 (linux_wait_1): ... to here, and adjust to check the thread's
17817 last_resume_kind instead of the lwp's step or stop_expected flags.
17818
1915ef4f
PA
178192010-05-02 Pedro Alves <pedro@codesourcery.com>
17820
17821 * README: Use consistent `GDB' and `GDBserver' spellings.
17822
f9e39928
PA
178232010-05-02 Pedro Alves <pedro@codesourcery.com>
17824
17825 * linux-low.c (linux_kill_one_lwp): Assume the lwp is stopped.
17826 (linux_kill): Stop all lwps here. Don't delete the main lwp here.
17827 (linux_detach_one_lwp): Assume the lwp is stopped.
17828 (any_thread_of): Delete.
17829 (linux_detach): Stop all lwps here. Don't blindly delete all
17830 breakpoints.
17831 (delete_lwp_callback): New.
17832 (linux_mourn): Delete all lwps of the process that is gone.
17833 (linux_wait_1): Don't delete the last lwp of the process here.
17834 * mem-break.h (mark_breakpoints_out): Declare.
17835 * mem-break.c (mark_breakpoints_out): New.
17836 (free_all_breakpoints): Use it.
17837 * server.c (handle_target_event): If the process is gone, mark
17838 breakpoints out.
17839 * thread-db.c (struct thread_db) <create_bp>: New field.
17840 (thread_db_enable_reporting): Fix prototype. Store a thread event
17841 breakpoint reference in the thread_db struct.
17842 (thread_db_load_search): Clear the thread_db object.
17843 (try_thread_db_load_1): Ditto.
17844 (switch_to_process): New.
17845 (disable_thread_event_reporting): Use it.
17846 (remove_thread_event_breakpoints): New.
17847 (thread_db_detach, thread_db_mourn): Use it.
17848
1e7fc18c
PA
178492010-05-01 Pedro Alves <pedro@codesourcery.com>
17850
17851 * linux-low.c (linux_enable_event_reporting): New.
17852 (linux_wait_for_event_1, handle_extended_wait): Use it.
17853
02fc4de7
PA
178542010-04-30 Pedro Alves <pedro@codesourcery.com>
17855
17856 * linux-low.c (linux_kill_one_lwp, linux_kill)
17857 (linux_detach_one_lwp): Adjust to send_sigstop interface change.
17858 (send_sigstop): Take an lwp_info as parameter instead. Queue a
17859 SIGSTOP even if the LWP is stopped.
17860 (send_sigstop_callback): New.
17861 (stop_all_lwps): Use send_sigstop_callback instead.
17862 (linux_resume_one_thread): Adjust.
17863 (proceed_one_lwp): Still proceed an LWP that the client has
17864 requested to stop, if we haven't reported it as stopped yet. Make
17865 sure that LWPs the client want stopped, have a pending SIGSTOP.
17866
bc3b5632
DE
178672010-04-26 Doug Evans <dje@google.com>
17868
ae1ada35
DE
17869 * server.c (handle_general_set): Make static.
17870
bc3b5632
DE
17871 * remote-utils.c (putpkt_binary_1): Call readchar instead of read.
17872 Print received char after testing for error/eof instead of before.
17873 (input_interrupt): Tweak comment.
17874
65730243
DE
178752010-04-23 Doug Evans <dje@google.com>
17876
17877 * server.c (start_inferior): Print inferior argv if --debug.
17878
a8ae7dc0
AR
178792010-04-21 Aleksandar Ristovski <aristovski@qnx.com>
17880
17881 * Makefile.in (nto_low_h nto-low.o nto-x86-low.o): New dependency lists.
17882 * nto-x86-low.c: Include server.h
17883
1c07cc19
PM
178842010-04-20 Pierre Muller <muller@ics.u-strasbg.fr>
17885
17886 * win32-i386-low.c: Use __x86_64__ macro instead of __x86_64 to
17887 be consistent with other sources of this directory.
17888 (init_registers_amd64): Correct name of source file of this function
17889 in the comment.
17890
e0a61e09
PM
178912010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
17892
17893 * configure.srv (x86_64-*-mingw*): New configuration for Windows
17894 64-bit executables.
17895
54709339
PM
178962010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
17897
17898 * win32-i386-low.c: Add 64-bit support.
17899 (CONTEXT_EXTENDED_REGISTERS): Set macro to zero if not exisiting.
17900 (init_registers_amd64): Declare.
17901 (mappings): Add 64-bit version of array.
17902 (init_windows_x86): New function.
17903 (the_low_target): Change init_arch field to init_windows_x86.
17904
e8f0053d
PM
179052010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
17906
17907 * win32-low.c: Adapt to support also 64-bit architecture.
17908 (child_xfer_memory): Use uintptr_t type for local variable `addr'.
17909 (get_image_name): Use SIZE_T type for local variable `done'.
17910 (psapi_get_dll_name): Use LPVOID type for parameter `BaseAddress'.
17911 (toolhelp_get_dll_name): Idem.
17912 (handle_load_dll): Use CORE_ADDR type for local variable `load_addr'.
17913 Use uintptr_t typecast to avoid warning.
17914 (handle_unload_dll): Use uintptr_t typecast to avoid warning.
17915 (handle_exception): Use phex_nz to avoid warning.
17916 (win32_wait): Remove unused local variable `process'.
17917
c481e77e
PM
179182010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
17919
17920 * configure.srv (srv_amd64_regobj): Replace `x86-64-avx.o' by
17921 `amd64-avx.o'.
17922
12ea4b69
PM
179232010-04-17 Pierre Muller <muller@ics.u-strasbg.fr>
17924
17925 * configure.ac: Use `ws2_32' library for srv_mingw.
17926 * configure: Regenerate.
17927 * gdbreplay.c: Include winsock2.h instead of winsock.h.
17928 * remote-utils.c: Likewise.
17929
f6d1620c
L
179302010-04-17 H.J. Lu <hongjiu.lu@intel.com>
17931
17932 * linux-x86-low.c (xmltarget_amd64_linux_no_xml): Define only
17933 if __x86_64__ is defined.
17934
8e642873
PM
179352010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
17936
17937 * configure: Regenerate.
17938
711e434b
PM
179392010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
17940
17941 * server.c (handle_query): Handle 'qGetTIBAddr' query.
17942 * target.h (target_ops): New get_tib_address field.
17943 * win32-low.h (win32_thread_info): Add thread_local_base field.
17944 * win32-low.c (child_add_thread): Add tlb argument.
17945 Set thread_local_base field to TLB.
17946 (get_child_debug_event): Adapt to child_add_thread change.
17947 (win32_get_tib_address): New function.
17948 (win32_target_ops): Set get_tib_address field to
17949 win32_get_tib_address.
17950 * linux-low.c (linux_target_ops): Set get_tib_address field to NULL.
17951
505106cd
PA
179522010-04-12 Pedro Alves <pedro@codesourcery.com>
17953
505106cd
PA
17954 * linux-low.c (linux_mourn): Also remove the process.
17955 * server.c (handle_target_event): Don't remove the process here.
17956 * nto-low.c (nto_mourn): New.
17957 (nto_target_ops): Install it.
17958 * spu-low.c (spu_mourn): New.
17959 (spu_target_ops): Install it.
17960 * win32-low.c (win32_mourn): New.
17961 (win32_target_ops): Install it.
17962
e8470a06
PA
179632010-04-12 Pedro Alves <pedro@codesourcery.com>
17964
17965 * server.h (buffer_xml_printf): Remove redundant `;'.
17966
45ba0d02
PA
179672010-04-12 Pedro Alves <pedro@codesourcery.com>
17968
17969 * regcache.c (set_register_cache): Invalidate regcaches before
17970 changing the register cache layout.
17971 (regcache_invalidate_one): Allow a NULL regcache.
17972 * linux-x86-low.c (x86_linux_update_xmltarget): Invalidate
17973 regcaches before changing the register cache layout or the target
17974 regsets.
17975
59e04013
L
179762010-04-12 H.J. Lu <hongjiu.lu@intel.com>
17977
17978 * linux-x86-low.c (x86_linux_update_xmltarget): Avoid unused
17979 variable warning on Linux/x86-64.
17980
8336d594
PA
179812010-04-11 Pedro Alves <pedro@codesourcery.com>
17982
17983 GDBserver disconnected tracing support.
17984
17985 * linux-low.c (linux_remove_process): Delete.
17986 (add_lwp): Don't set last_resume_kind here.
17987 (linux_kill): Use `mourn'.
17988 (linux_detach): Use `thread_db_detach', and `mourn'.
17989 (linux_mourn): New.
17990 (linux_attach_lwp_1): Adjust comment.
17991 (linux_attach): last_resume_kind moved the thread_info; adjust.
17992 (status_pending_p_callback): Adjust.
17993 (linux_wait_for_event_1): Adjust.
17994 (count_events_callback, select_singlestep_lwp_callback)
17995 (select_event_lwp_callback, cancel_breakpoints_callback)
17996 (db_wants_lwp_stopped, linux_wait_1, need_step_over_p)
17997 (proceed_one_lwp): Adjust.
17998 (linux_async): Add debug output.
17999 (linux_thread_stopped): New.
18000 (linux_pause_all): New.
18001 (linux_target_ops): Install linux_mourn, linux_thread_stopped and
18002 linux_pause_all.
18003 * linux-low.h (struct lwp_info): Delete last_resume_kind field.
18004 (thread_db_free): Delete declaration.
18005 (thread_db_detach, thread_db_mourn): Declare.
18006 * thread-db.c (thread_db_init): Use thread_db_mourn.
18007 (thread_db_free): Delete, split in two.
18008 (disable_thread_event_reporting): New.
18009 (thread_db_detach): New.
18010 (thread_db_mourn): New.
18011
18012 * server.h (struct thread_info) <last_resume_kind>: New field.
18013 <attached>: Add comment.
18014 <gdb_detached>: New field.
18015 (handler_func): Change return type to int.
18016 (handle_serial_event, handle_target_event): Ditto.
18017 (gdb_connected): Declare.
18018 (tracing): Delete.
18019 (disconnected_tracing): Declare.
18020 (stop_tracing): Declare.
18021
18022 * server.c (handle_query) <qSupported>: Report support for
18023 disconnected tracing.
18024 (queue_stop_reply_callback): Account for running threads.
18025 (gdb_wants_thread_stopped): New.
18026 (gdb_wants_all_threads_stopped): New.
18027 (gdb_reattached_process): New.
18028 (handle_status): Clear the `gdb_detached' flag of all processes.
18029 In all-stop, stop all threads.
18030 (main): Be sure to leave tfind mode. Handle disconnected tracing.
18031 (process_serial_event): If the remote connection breaks, or if an
18032 exit was forced with "monitor exit", force an event loop exit.
18033 Handle disconnected tracing on detach.
18034 (handle_serial_event): Adjust.
18035 (handle_target_event): If GDB isn't connected, forward events back
18036 to the inferior, unless the last process exited, in which case,
18037 exit gdbserver. Adjust interface.
18038
18039 * remote-utils.c (remote_open): Don't block in accept. Instead
18040 register an event loop source on the listen socket file
18041 descriptor. Refactor bits into ...
18042 (listen_desc): ... this new global.
18043 (gdb_connected): ... this new function.
18044 (enable_async_notification): ... this new function.
18045 (handle_accept_event): ... this new function.
18046 (remote_close): Clear remote_desc.
18047
18048 * inferiors.c (add_thread): Set the new thread's last_resume_kind.
18049
18050 * target.h (struct target_ops) <mourn, thread_stopped, pause_all>:
18051 New fields.
18052 (mourn_inferior): Define.
18053 (target_process_qsupported): Avoid the dangling else problem.
18054 (thread_stopped): Define.
18055 (pause_all): Define.
18056 (target_waitstatus_to_string): Declare.
18057 * target.c (target_waitstatus_to_string): New.
18058
18059 * tracepoint.c (tracing): Make extern.
18060 (disconnected_tracing): New.
18061 (stop_tracing): Make extern. Handle tracing stops due to GDB
18062 disconnecting.
18063 (cmd_qtdisconnected): New.
18064 (cmd_qtstatus): Report disconnected tracing status in trace reply.
18065 (handle_tracepoint_general_set): Handle QTDisconnected.
18066
18067 * event-loop.c (event_handler_func): Change return type to int.
18068 (process_event): Bail out if the event handler wants the event
18069 loop to stop.
18070 (handle_file_event): Ditto.
18071 (start_event_loop): Bail out if the event handler wants the event
18072 loop to stop.
18073
18074 * nto-low.c (nto_target_ops): Adjust.
18075 * spu-low.c (spu_wait): Don't remove the process here.
18076 (spu_target_ops): Adjust.
18077 * win32-low.c (win32_wait): Don't remove the process here.
18078 (win32_target_ops): Adjust.
18079
5d267c4c
PA
180802010-04-11 Pedro Alves <pedro@codesourcery.com>
18081
18082 * regcache.c (realloc_register_cache): Invalidate inferior's
18083 regcache before recreating it.
18084
623ccd72
PA
180852010-04-09 Pedro Alves <pedro@codesourcery.com>
18086
18087 * tracepoint.c (cmd_qtstatus): Report trace buffer circularity.
18088
219f2f23
PA
180892010-04-09 Stan Shebs <stan@codesourcery.com>
18090 Pedro Alves <pedro@codesourcery.com>
18091
18092 * server.h (LONGEST): New.
18093 (struct thread_info) <while_stepping>: New field.
18094 (unpack_varlen_hex, xrealloc, pulongest, plongest, phex_nz):
18095 Declare.
18096 (initialize_tracepoint, handle_tracepoint_general_set)
18097 (handle_tracepoint_query, tracepoint_finished_step)
18098 (tracepoint_was_hit, release_while_stepping_state_list):
18099 (current_traceframe): Declare.
18100 * server.c (handle_general_set): Handle tracepoint packets.
18101 (read_memory): New.
18102 (write_memory): New.
18103 (handle_search_memory_1): Use read_memory.
18104 (handle_query): Report support for conditional tracepoints, trace
18105 state variables, and tracepoint sources. Handle tracepoint
18106 queries.
18107 (main): Initialize the tracepoints module.
18108 (process_serial_event): Handle traceframe reads/writes.
18109
18110 * linux-low.c (handle_tracepoints): New.
18111 (linux_wait_1): Call it.
18112 (linux_resume_one_lwp): Handle while-stepping.
18113 (linux_supports_tracepoints, linux_read_pc, linux_write_pc): New.
18114 (linux_target_ops): Install them.
18115 * linux-low.h (struct linux_target_ops) <supports_tracepoints>:
18116 New field.
18117 * linux-x86-low.c (x86_supports_tracepoints): New.
18118 (the_low_target). Install it.
18119
18120 * mem-break.h (delete_breakpoint): Declare.
18121 * mem-break.c (delete_breakpoint): Make external.
18122
18123 * target.h (struct target_ops): Add `supports_tracepoints',
18124 `read_pc', and `write_pc' fields.
18125 (target_supports_tracepoints): Define.
18126 * utils.c (xrealloc, decimal2str, pulongest, plongest, thirty_two)
18127 (phex_nz): New.
18128
18129 * regcache.h (struct regcache) <registers_owned>: New field.
18130 (init_register_cache, regcache_cpy): Declare.
18131 (regcache_read_pc, regcache_write_pc): Declare.
18132 (register_cache_size): Declare.
18133 (supply_regblock): Declare.
18134 * regcache.c (init_register_cache): New.
18135 (new_register_cache): Use it.
18136 (regcache_cpy): New.
18137 (register_cache_size): New.
18138 (supply_regblock): New.
18139 (regcache_read_pc, regcache_write_pc): New.
889bf7c5 18140
219f2f23
PA
18141 * tracepoint.c: New.
18142
18143 * Makefile.in (OBS): Add tracepoint.o.
18144 (tracepoint.o): New rule.
18145
3a13a53b
L
181462010-04-08 H.J. Lu <hongjiu.lu@intel.com>
18147
18148 * Makefile.in (clean): Also remove i386-mmx.c i386-mmx-linux.c.
18149 (i386-mmx.o): New.
18150 (i386-mmx.c): Likewise.
18151 (i386-mmx-linux.o): Likewise.
18152 (i386-mmx-linux.c): Likewise.
18153
18154 * configure.srv (srv_i386_regobj): Add i386-mmx.o.
18155 (srv_i386_linux_regobj): Add i386-mmx-linux.o.
18156 (srv_i386_xmlfiles): Add i386/i386-mmx.xml.
18157 (srv_i386_linux_xmlfiles): Add i386/i386-mmx-linux.xml.
18158
18159 * linux-x86-low.c (init_registers_i386_mmx_linux): New.
18160 (x86_linux_update_xmltarget): Call init_registers_i386_mmx_linux
18161 and return if ptrace PTRACE_GETFPXREGS failed in 32bit.
18162
1570b33e
L
181632010-04-07 H.J. Lu <hongjiu.lu@intel.com>
18164
18165 * Makefile.in (clean): Updated.
18166 (i386-avx.o): New.
18167 (i386-avx.c): Likewise.
18168 (i386-avx-linux.o): Likewise.
18169 (i386-avx-linux.c): Likewise.
18170 (amd64-avx.o): Likewise.
18171 (amd64-avx.c): Likewise.
18172 (amd64-avx-linux.o): Likewise.
18173 (amd64-avx-linux.c): Likewise.
18174
18175 * configure.srv (srv_i386_regobj): Add i386-avx.o.
18176 (srv_i386_linux_regobj): Add i386-avx-linux.o.
18177 (srv_amd64_regobj): Add amd64-avx.o.
18178 (srv_amd64_linux_regobj): Add amd64-avx-linux.o.
18179 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx.xml.
18180 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx.xml.
18181 (srv_i386_xmlfiles): Add i386/i386-avx.xml.
18182 (srv_amd64_xmlfiles): Add i386/amd64-avx.xml.
18183 (srv_i386_linux_xmlfiles): Add i386/i386-avx-linux.xml.
18184 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-linux.xml.
18185
18186 * i387-fp.c: Include "i386-xstate.h".
18187 (i387_xsave): New.
18188 (i387_cache_to_xsave): Likewise.
18189 (i387_xsave_to_cache): Likewise.
18190 (x86_xcr0): Likewise.
18191
18192 * i387-fp.h (i387_cache_to_xsave): Likewise.
18193 (i387_xsave_to_cache): Likewise.
18194 (x86_xcr0): Likewise.
18195
18196 * linux-arm-low.c (target_regsets): Initialize nt_type to 0.
18197 * linux-crisv32-low.c (target_regsets): Likewise.
18198 * linux-m68k-low.c (target_regsets): Likewise.
18199 * linux-mips-low.c (target_regsets): Likewise.
18200 * linux-ppc-low.c (target_regsets): Likewise.
18201 * linux-s390-low.c (target_regsets): Likewise.
18202 * linux-sh-low.c (target_regsets): Likewise.
18203 * linux-sparc-low.c (target_regsets): Likewise.
18204 * linux-xtensa-low.c (target_regsets): Likewise.
18205
18206 * linux-low.c: Include <sys/uio.h>.
18207 (regsets_fetch_inferior_registers): Support nt_type.
18208 (regsets_store_inferior_registers): Likewise.
18209 (linux_process_qsupported): New.
18210 (linux_target_ops): Add linux_process_qsupported.
18211
18212 * linux-low.h (regset_info): Add nt_type.
18213 (linux_target_ops): Add process_qsupported.
18214
18215 * linux-x86-low.c: Include "i386-xstate.h", "elf/common.h"
18216 and <sys/uio.h>.
18217 (init_registers_i386_avx_linux): New.
18218 (init_registers_amd64_avx_linux): Likewise.
18219 (xmltarget_i386_linux_no_xml): Likewise.
18220 (xmltarget_amd64_linux_no_xml): Likewise.
18221 (PTRACE_GETREGSET): Likewise.
18222 (PTRACE_SETREGSET): Likewise.
18223 (x86_fill_xstateregset): Likewise.
18224 (x86_store_xstateregset): Likewise.
18225 (use_xml): Likewise.
18226 (x86_linux_update_xmltarget): Likewise.
18227 (x86_linux_process_qsupported): Likewise.
18228 (target_regsets): Add NT_X86_XSTATE entry and Initialize nt_type.
18229 (x86_arch_setup): Don't call init_registers_amd64_linux nor
18230 init_registers_i386_linux here. Call
18231 x86_linux_update_xmltarget.
18232 (the_low_target): Add x86_linux_process_qsupported.
18233
18234 * server.c (handle_query): Call target_process_qsupported.
18235
18236 * target.h (target_ops): Add process_qsupported.
18237 (target_process_qsupported): New.
18238
fc7238bb
PA
182392010-04-03 Pedro Alves <pedro@codesourcery.com>
18240
18241 * inferiors.c (add_thread): Set last_status kind to
18242 TARGET_WAITKIND_IGNORE.
18243 * linux-low.c (cancel_breakpoint): Remove unnecessary regcache
18244 fetch. Use ptid_of. Avoid unnecessary get_lwp_thread calls.
18245 (linux_wait_1): Move `thread' local definition to block that uses
18246 it. Don't NULL initialize `event_child'.
18247 (linux_resume_one_thread): Avoid unnecessary get_lwp_thread calls.
18248 Alway set the thread's last_status to TARGET_WAITKIND_IGNORE.
18249 * linux-x86-low.c (x86_breakpoint_at): Read raw memory.
18250
bdabb078
PA
182512010-04-01 Pedro Alves <pedro@codesourcery.com>
18252
18253 * linux-low.c (get_stop_pc): Don't adjust the PC if stopped with
18254 an extended waitstatus, or by a watchpoint.
18255 (cancel_breakpoints_callback): Don't cancel a breakpoint if the
18256 thread was stepping or has been stopped by a watchpoint.
18257
d3bbe7a0
PA
182582010-04-01 Pedro Alves <pedro@codesourcery.com>
18259
18260 * mem-break.c (struct raw_breakpoint): New field shlib_disabled.
18261 (set_gdb_breakpoint_at): If GDB is inserting a breakpoint on top
18262 of another, then delete the previous, and validate all
18263 breakpoints.
18264 (validate_inserted_breakpoint): New.
18265 (delete_disabled_breakpoints): New.
18266 (validate_breakpoints): New.
18267 (check_mem_read): Validate breakpoints before trusting their
18268 shadow. Delete disabled breakpoints.
18269 (check_mem_write): Validate breakpoints before trusting they
18270 should be inserted. Delete disabled breakpoints.
18271 * mem-break.h (validate_breakpoints):
18272 * server.c (handle_query): Validate breakpoints when we see a
18273 qSymbol query.
18274
8b07ae33
PA
182752010-04-01 Pedro Alves <pedro@codesourcery.com>
18276
18277 * linux-low.c (linux_wait_1): Avoid setting need_step_over is
18278 there's a GDB breakpoint at stop_pc. Always report a trap to GDB
18279 if we could tell there's a GDB breakpoint at stop_pc.
18280 (need_step_over_p): Don't do a step over if we find a GDB
18281 breakpoint at the resume PC.
18282
18283 * mem-break.c (struct raw_breakpoint): New.
18284 (enum bkpt_type): New type `gdb_breakpoint'.
18285 (struct breakpoint): Delete the `PC', `old_data' and `inserted'
18286 fields. New field `raw'.
18287 (find_raw_breakpoint_at): New.
18288 (set_raw_breakpoint_at): Handle refcounting. Create a raw
18289 breakpoint instead.
18290 (set_breakpoint_at): Adjust.
18291 (delete_raw_breakpoint): New.
18292 (release_breakpoint): New.
18293 (delete_breakpoint): Rename to...
18294 (delete_breakpoint_1): ... this. Add proc parameter. Use
18295 release_breakpoint. Return ENOENT.
18296 (delete_breakpoint): Reimplement.
18297 (find_breakpoint_at): Delete.
18298 (find_gdb_breakpoint_at): New.
18299 (delete_breakpoint_at): Delete.
18300 (set_gdb_breakpoint_at): New.
18301 (delete_gdb_breakpoint_at): New.
18302 (gdb_breakpoint_here): New.
18303 (set_reinsert_breakpoint): Use release_breakpoint.
18304 (uninsert_breakpoint): Rename to ...
18305 (uninsert_raw_breakpoint): ... this.
18306 (uninsert_breakpoints_at): Adjust to handle raw breakpoints.
18307 (reinsert_raw_breakpoint): Change parameter type to
18308 raw_breakpoint.
18309 (reinsert_breakpoints_at): Adjust to handle raw breakpoints
18310 instead.
18311 (check_breakpoints): Adjust. Use release_breakpoint.
18312 (breakpoint_here): Rewrite using find_raw_breakpoint_at.
18313 (breakpoint_inserted_here): Ditto.
18314 (check_mem_read): Adjust to iterate over raw breakpoints instead.
18315 Don't trust the breakpoint's shadow if it is not inserted.
18316 (check_mem_write): Adjust to iterate over raw breakpoints instead.
18317 (delete_all_breakpoints): Adjust.
18318 (free_all_breakpoints): Mark all breakpoints as uninserted, and
18319 use delete_breakpoint_1.
18320
18321 * mem-break.h (breakpoints_supported): Delete declaration.
18322 (set_gdb_breakpoint_at): Declare.
18323 (gdb_breakpoint_here): Declare.
18324 (delete_breakpoint_at): Delete.
18325 (delete_gdb_breakpoint_at): Declare.
18326
18327 * server.h (struct raw_breakpoint): Forward declare.
18328 (struct process_info): New field `raw_breakpoints'.
18329
18330 * linux-x86-low.c (x86_insert_point, x86_remote_point): Handle Z0
18331 breakpoints.
18332
6bf5e0ba
PA
183332010-03-24 Pedro Alves <pedro@codesourcery.com>
18334
18335 * linux-low.c (status_pending_p_callback): Fix comment.
18336 (linux_wait_for_event_1): Move most of the internal breakpoint
18337 handling from here...
18338 (linux_wait_1): ... to here.
18339 (count_events_callback): New.
18340 (select_singlestep_lwp_callback): New.
18341 (select_event_lwp_callback): New.
18342 (cancel_breakpoints_callback): New.
18343 (select_event_lwp): New.
18344 (linux_wait_1): Simplify internal breakpoint handling. Give equal
18345 priority to all LWPs that have had events that should be reported
18346 to the client. Cancel breakpoints when about to reporting the
18347 event to the client, not while stopping lwps. No longer cancel
18348 finished single-steps here.
18349 (cancel_finished_single_step): Delete.
18350 (cancel_finished_single_steps): Delete.
18351
414a389f
PA
183522010-03-24 Pedro Alves <pedro@codesourcery.com>
18353
18354 * mem-break.c (enum bkpt_type): New.
18355 (struct breakpoint): New field `type'.
18356 (set_breakpoint_at): Change return type to struct breakpoint
18357 pointer. Set type to `other_breakpoint' by default.
18358 (delete_breakpoint): Rewrite, supporting more than one breakpoint
18359 in the breakpoint list.
18360 (delete_reinsert_breakpoints): Only delete reinsert breakpoints.
18361 (reinsert_breakpoint): Rename to ...
18362 (reinsert_raw_breakpoint): ... this.
18363 (reinsert_breakpoints_at): Adjust.
18364 * mem-break.h (struct breakpoint): Declare.
18365 (set_breakpoint_at): Change return type to struct breakpoint
18366 pointer.
18367
2280c721
PA
183682010-03-24 Pedro Alves <pedro@codesourcery.com>
18369
18370 * server.c (handle_query): Assign, not compare.
18371
d50171e4
PA
183722010-03-24 Pedro Alves <pedro@codesourcery.com>
18373
18374 Teach linux gdbserver to step-over-breakpoints.
18375
18376 * linux-low.c (can_hardware_single_step): New.
18377 (supports_breakpoints): New.
18378 (handle_extended_wait): If stopping threads, read the stop pc of
18379 the new cloned LWP.
18380 (get_pc): New.
18381 (get_stop_pc): Add `lwp' parameter. Handle it. Bail out if the
18382 low target doesn't support retrieving the PC.
18383 (add_lwp): Set last_resume_kind to resume_continue.
18384 (linux_attach_lwp_1): Adjust comments. Always set stop_expected.
18385 (linux_attach): Don't clear stop_expected. Set the lwp's
18386 last_resume_kind to resume_stop.
18387 (linux_detach_one_lwp): Don't check for removed breakpoints.
18388 (check_removed_breakpoint): Delete.
18389 (status_pending_p): Rename to ...
18390 (status_pending_p_callback): ... this. Don't check for removed
18391 breakpoints. Don't consider threads that are stopped from GDB's
18392 perspective.
18393 (linux_wait_for_lwp): Always read the stop_pc here.
18394 (cancel_breakpoint): New.
18395 (step_over_bkpt): New global.
18396 (linux_wait_for_event_1): Implement stepping over breakpoints.
18397 (gdb_wants_lwp_stopped): New.
18398 (gdb_wants_all_stopped): New.
18399 (linux_wait_1): Tag threads as gdb-wants-stopped. Cancel finished
18400 single-step traps here. Store the thread's last reported target
18401 wait status.
18402 (send_sigstop): Don't clear stop_expected. Always set it,
18403 instead.
18404 (mark_lwp_dead): Remove reference to pending_is_breakpoint.
18405 (cancel_finished_single_step): New.
18406 (cancel_finished_single_steps): New.
18407 (wait_for_sigstop): Don't cancel finished single-step traps here.
18408 (linux_resume_one_lwp): Don't check for removed breakpoints.
18409 Don't set `step' on non-hardware step archs.
18410 (linux_set_resume_request): Ignore resume_stop requests if already
18411 stopping or stopped. Set the lwp's last_resume_kind.
18412 (resume_status_pending_p): Don't check for removed breakpoints.
18413 (need_step_over_p): New.
18414 (start_step_over): New.
18415 (finish_step_over): New.
18416 (linux_resume_one_thread): Always queue a sigstop for resume_stop
18417 requests. Clear the thread's last reported target waitstatus.
18418 Don't use the `suspended' flag. Don't consider pending breakpoints.
18419 (linux_resume): Start a step-over if necessary.
18420 (proceed_one_lwp): New.
18421 (proceed_all_lwps): New.
18422 (unstop_all_lwps): New.
18423 * linux-low.h (struct lwp_info): Rewrite comment for the
18424 `suspended' flag. Add the `stop_pc' field. Delete the
18425 `pending_stop_pc' field. Tweak the `stepping' flag's comment.
18426 Add `'last_resume_kind' and `need_step_over' fields.
18427 * inferiors.c (struct thread_info): Delete, moved elsewhere.
18428 * mem-break.c (struct breakpoint): Delete `reinserting' flag.
18429 Delete `breakpoint_to_reinsert' field. New flag `inserted'.
18430 (set_raw_breakpoint_at): New.
18431 (set_breakpoint_at): Rewrite to use it.
18432 (reinsert_breakpoint_handler): Delete.
18433 (set_reinsert_breakpoint): New.
18434 (reinsert_breakpoint_by_bp): Delete.
18435 (delete_reinsert_breakpoints): New.
18436 (uninsert_breakpoint): Rewrite.
18437 (uninsert_breakpoints_at): New.
18438 (reinsert_breakpoint): Rewrite.
18439 (reinsert_breakpoints_at): New.
18440 (check_breakpoints): Rewrite.
18441 (breakpoint_here): New.
18442 (breakpoint_inserted_here): New.
18443 (check_mem_read): Adjust.
18444 * mem-break.h (breakpoints_supported, breakpoint_here)
18445 (breakpoint_inserted_here, set_reinsert_breakpoint): Declare.
18446 (reinsert_breakpoint_by_bp): Delete declaration.
18447 (delete_reinsert_breakpoints): Declare.
18448 (reinsert_breakpoint): Delete declaration.
18449 (reinsert_breakpoints_at): Declare.
18450 (uninsert_breakpoint): Delete declaration.
18451 (uninsert_breakpoints_at): Declare.
18452 (check_breakpoints): Adjust prototype.
18453 * server.h: Adjust include order.
18454 (struct thread_info): Declare here. Add a `last_status' field.
18455
30ba68cb
MS
184562010-03-23 Michael Snyder <msnyder@vmware.com>
18457
18458 * server.c (crc32): New function.
18459 (handle_query): Add handling for 'qCRC:' request.
18460
b9a881c2
PA
184612010-03-23 Pedro Alves <pedro@codesourcery.com>
18462
18463 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR6 if the
18464 lwp had been stopped by a watchpoint.
18465
e92d13d5
PA
184662010-03-16 Pedro Alves <pedro@codesourcery.com>
18467
18468 * server.h (internal_error): Declare.
18469 (gdb_assert, ASSERT_FUNCTION, gdb_assert_fail): Define.
18470 * utils.c (internal_error): New function.
18471
64daa791
AS
184722010-03-15 Andreas Schwab <schwab@redhat.com>
18473
18474 * configure.srv: Fix typo setting srv_regobj.
18475
f52cd8cd
PA
184762010-03-15 Pedro Alves <pedro@codesourcery.com>
18477
18478 * linux-low.c (fetch_register): Avoid passing a non string literal
18479 format to `error'.
18480 (usr_store_inferior_registers): Ditto.
18481
93ae6fdc
PA
184822010-03-14 Pedro Alves <pedro@codesourcery.com>
18483
18484 * linux-low.c (linux_write_memory): Bail out early if peeking
18485 memory failed.
18486
c3adc08c
PA
184872010-03-14 Pedro Alves <pedro@codesourcery.com>
18488
18489 * linux-low.h (struct lwp_info): New fields
18490 `stopped_by_watchpoint' and `stopped_data_address'.
18491 * linux-low.c (linux_wait_for_lwp): Check for watchpoint triggers
18492 here, and cache them in the lwp object.
18493 (wait_for_sigstop): Check stopped_by_watchpoint lwp field
18494 directly.
18495 (linux_resume_one_lwp): Clear the lwp's stopped_by_watchpoint
18496 field.
18497 (linux_stopped_by_watchpoint): Rewrite.
18498 (linux_stopped_data_address): Rewrite.
18499
bce522a2
PA
185002010-03-06 Simo Melenius <simo.melenius@iki.fi>
18501
18502 * linux-low.c (linux_wait_for_lwp): Fetch the regcache after
18503 switching the current inferior, not before.
18504
90884b2b
L
185052010-03-01 H.J. Lu <hongjiu.lu@intel.com>
18506
18507 * Makefile.in (clean): Replace reg-i386.c, reg-x86-64.c,
18508 reg-i386-linux.c and reg-x86-64-linux.c with i386.c, amd64.c,
18509 i386-linux.c and amd64-linux.c.
18510 (reg-i386.o): Removed.
18511 (reg-i386.c): Likewise.
18512 (reg-i386-linux.o): Likewise.
18513 (reg-i386-linux.c): Likewise.
18514 (reg-x86-64.o): Likewise.
18515 (reg-x86-64.c): Likewise.
18516 (reg-x86-64-linux.o): Likewise.
18517 (reg-x86-64-linux.c): Likewise.
18518 (i386.o): New.
18519 (i386.c): Likewise.
18520 (i386-linux.o): Likewise.
18521 (i386-linux.c): Likewise.
18522 (amd64.o): Likewise.
18523 (amd64.c): Likewise.
18524 (amd64-linux.o): Likewise.
18525 (amd64-linux.c): Likewise.
18526
18527 * configure.srv (srv_i386_regobj): New.
18528 (srv_i386_linux_regobj): Likewise.
18529 (srv_amd64_regobj): Likewise.
18530 (srv_amd64_linux_regobj): Likewise.
18531 (srv_i386_32bit_xmlfiles): Likewise.
18532 (srv_i386_64bit_xmlfiles): Likewise.
18533 (srv_i386_xmlfiles): Likewise.
18534 (srv_amd64_xmlfiles): Likewise.
18535 (srv_i386_linux_xmlfiles): Likewise.
18536 (srv_amd64_linux_xmlfiles): Likewise.
18537 (i[34567]86-*-cygwin*): Set srv_regobj to $srv_i386_regobj. Set
18538 srv_xmlfiles to $srv_i386_xmlfiles.
18539 (i[34567]86-*-mingw32ce*): Likewise.
18540 (i[34567]86-*-mingw*): Likewise.
18541 (i[34567]86-*-nto*): Likewise.
18542 (i[34567]86-*-linux*): Set srv_regobj to $srv_i386_linux_regobj
18543 and $srv_amd64_linux_regobj. Set srv_xmlfiles to
18544 $srv_i386_linux_xmlfiles and $srv_amd64_linux_xmlfiles.
18545 (x86_64-*-linux*): Likewise.
18546
18547 * linux-x86-low.c (init_registers_x86_64_linux): Removed.
18548 (init_registers_amd64_linux): New.
18549 (x86_arch_setup): Replace init_registers_x86_64_linux with
18550 init_registers_amd64_linux.
18551
193f13e6
MK
185522010-02-23 Maxim Kuvyrkov <maxim@codesourcery.com>
18553
18554 * configure.ac: Check for libdl. If it is not available link against
18555 static libthread_db.
18556 * configure: Regenerate.
18557
85d721b8
PA
185582010-02-22 Pedro Alves <pedro@codesourcery.com>
18559
18560 PR9605
18561
18562 * i386-low.c (i386_length_and_rw_bits): Throw a fatal error if
18563 handing a read watchpoint.
18564 (i386_low_insert_watchpoint): Read watchpoints aren't supported.
18565
6076632b
DE
185662010-02-12 Doug Evans <dje@google.com>
18567
18568 * linux-low.c (linux_supports_tracefork_flag): Document.
18569 (linux_look_up_symbols): Add comment.
18570
3327ccf7
L
185712010-02-03 H.J. Lu <hongjiu.lu@intel.com>
18572
18573 * regcache.c (supply_register): Clear regcache if buf is NULL.
18574
0718675c 185752010-02-02 Nicolas Roche <roche@sourceware.org>
3327ccf7 18576 Joel Brobecker <brobecker@adacore.com>
0718675c
JB
18577
18578 * inferiors.c (find_inferior): Add function documentation.
18579 (unloaded_dll): Handle the case where the unloaded dll has not
18580 been previously registered in the dll list.
18581
177321bd
DJ
185822010-02-01 Daniel Jacobowitz <dan@codesourcery.com>
18583
18584 * linux-arm-low.c (thumb_breakpoint_len): Delete.
18585 (thumb2_breakpoint): New.
18586 (arm_breakpoint_at): Check for Thumb-2 breakpoints.
18587
2b009048
DJ
185882010-01-29 Daniel Jacobowitz <dan@codesourcery.com>
18589
18590 * linux-low.c (get_stop_pc): Check for SIGTRAP.
18591 (linux_wait_for_event_1): Handle SIGILL and SIGSEGV as possible
18592 breakpoints.
18593
3be029c7
PA
185942010-01-21 Pedro Alves <pedro@codesourcery.com>
18595
18596 * linux-ppc-low.c (ppc_arch_setup): Adjust to regcache changes.
18597
18f5de3b
JK
185982010-01-21 Jan Kratochvil <jan.kratochvil@redhat.com>
18599
18600 * linux-s390-low.c (s390_collect_ptrace_register)
18601 (s390_supply_ptrace_register): Adjust it for the new regcache parameter.
18602
3743bb4f
DE
186032010-01-21 Doug Evans <dje@google.com>
18604
14ce3065
DE
18605 * linux-low.c (PTRACE_ARG3_TYPE): Change from long to void*.
18606 (PTRACE_ARG4_TYPE): New macro.
18607 (handle_extended_wait): Cast ptrace arg4 to PTRACE_ARG4_TYPE.
18608 (linux_wait_for_event_1, linux_resume_one_lwp): Ditto.
18609 (fetch_register): Cast to uintptr_t before casting to PTRACE_ARG3_TYPE.
18610 (usr_store_inferior_registers): Ditto.
18611 (linux_read_memory, linux_write_memory): Ditto.
18612 (linux_test_for_tracefork): Ditto.
18613
3743bb4f
DE
18614 * linux-arm-low.c: Remove redundant include of gdb_proc_service.h.
18615 Only include elf.h if gdb_proc_service.h didn't include linux/elf.h.
18616
8b315be5
PA
186172010-01-21 Pedro Alves <pedro@codesourcery.com>
18618
18619 * proc-service.c (ps_lgetregs): Don't refetch registers from the
18620 target.
18621
85492558
PA
186222010-01-21 Pedro Alves <pedro@codesourcery.com>
18623
18624 * spu-low.c (spu_fetch_registers, spu_store_registers): Change
18625 prototype to take a regcache. Adjust.
18626
442ea881
PA
186272010-01-20 Pedro Alves <pedro@codesourcery.com>
18628
18629 * regcache.h (struct thread_info): Forward declare.
18630 (struct regcache): New.
18631 (new_register_cache): Adjust prototype.
18632 (get_thread_regcache): Declare.
18633 (free_register_cache): Adjust prototype.
18634 (registers_to_string, registers_from_string): Ditto.
18635 (supply_register, supply_register_by_name, collect_register)
18636 (collect_register_as_string, collect_register_by_name): Ditto.
18637 * regcache.c (struct inferior_regcache_data): Delete.
18638 (get_regcache): Rename to ...
18639 (get_thread_regcache): ... this. Adjust. Switch inferior before
18640 fetching registers.
18641 (regcache_invalidate_one): Adjust.
18642 (regcache_invalidate): Fix prototype.
18643 (new_register_cache): Return the new register cache.
18644 (free_register_cache): Change prototype.
18645 (realloc_register_cache): Adjust.
18646 (registers_to_string): Change prototype to take a regcache. Adjust.
18647 (registers_from_string): Ditto.
18648 (register_data): Ditto.
18649 (supply_register): Ditto.
18650 (supply_register_by_name): Ditto.
18651 (collect_register): Ditto.
18652 (collect_register_as_string): Ditto.
18653 (collect_register_by_name): Ditto.
18654 * server.c (process_serial_event): Adjust.
18655 * linux-low.h (regset_fill_func, regset_store_func): Change
18656 prototype.
18657 (get_pc, set_pc, collect_ptrace_register, supply_ptrace_register):
18658 Change prototype.
18659 * linux-low.c (get_stop_pc): Adjust.
18660 (check_removed_breakpoint): Adjust.
18661 (linux_wait_for_event): Adjust.
18662 (linux_resume_one_lwp): Adjust.
18663 (fetch_register): Add regcache parameter. Adjust.
18664 (usr_store_inferior_registers): Ditto.
18665 (regsets_fetch_inferior_registers): Ditto.
18666 (regsets_store_inferior_registers): Ditto.
18667 (linux_fetch_registers, linux_store_registers): Ditto.
18668 * i387-fp.c (i387_cache_to_fsave): Change prototype to take a
18669 regcache. Adjust.
43aaf8b6
PA
18670 (i387_fsave_to_cache, i387_cache_to_fxsave, i387_fxsave_to_cache):
18671 Ditto.
442ea881
PA
18672 * i387-fp.h (i387_cache_to_fsave, i387_fsave_to_cache): Change
18673 prototype to take a regcache.
18674 (i387_cache_to_fxsave, i387_fxsave_to_cache): Ditto.
18675 * remote-utils.c (convert_ascii_to_int, outreg)
18676 (prepare_resume_reply): Change prototype to take a regcache.
18677 Adjust.
18678 * target.h (struct target_ops) <fetch_registers, store_registers>:
18679 Change prototype to take a regcache.
18680 (fetch_inferior_registers, store_inferior_registers): Change
18681 prototype to take a regcache. Adjust.
18682 * proc-service.c (ps_lgetregs): Adjust.
18683 * linux-x86-low.c (x86_fill_gregset, x86_store_gregset)
18684 (x86_fill_fpregset, x86_store_fpregset, x86_fill_fpxregset)
18685 (x86_store_fpxregset, x86_get_pc, x86_set_pc): Change prototype to
18686 take a regcache. Adjust.
18687 * linux-arm-low.c (arm_fill_gregset, arm_store_gregset)
18688 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
18689 (arm_store_vfpregset, arm_get_pc, arm_set_pc):
18690 (arm_breakpoint_at): Change prototype to take a regcache. Adjust.
18691 * linux-cris-low.c (cris_get_pc, cris_set_pc)
18692 (cris_cannot_fetch_register):
18693 (cris_breakpoint_at): Change prototype to take a regcache.
18694 Adjust.
18695 * linux-crisv32-low.c (cris_get_pc, cris_set_pc,
18696 cris_reinsert_addr, cris_write_data_breakpoint): Change prototype
18697 to take a regcache. Adjust.
18698 (cris_breakpoint_at, cris_insert_point, cris_remove_point):
18699 Adjust.
18700 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Change prototype to
18701 take a regcache. Adjust.
18702 * linux-m68k-low.c (m68k_fill_gregset, m68k_store_gregset)
18703 (m68k_fill_fpregset, m68k_store_fpregset, m68k_get_pc,
18704 (m68k_set_pc): Change prototype to take a regcache. Adjust.
18705 * linux-mips-low.c (mips_get_pc):
18706 (mips_set_pc): Change prototype to take a regcache. Adjust.
18707 (mips_reinsert_addr): Adjust.
18708 (mips_collect_register): Change prototype to take a regcache.
18709 Adjust.
18710 (mips_supply_register):
18711 (mips_collect_register_32bit, mips_supply_register_32bit)
18712 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
18713 (mips_store_fpregset): Ditto.
43aaf8b6
PA
18714 * linux-ppc-low.c (ppc_supply_ptrace_register)
18715 (ppc_supply_ptrace_register): Ditto.
442ea881
PA
18716 (parse_spufs_run): Adjust.
18717 (ppc_get_pc, ppc_set_pc, ppc_fill_gregset, ppc_fill_vsxregset)
18718 (ppc_store_vsxregset, ppc_fill_vrregset, ppc_store_vrregset)
18719 (ppc_fill_evrregset, ppc_store_evrregset): Change prototype to
18720 take a regcache. Adjust.
18721 * linux-s390-low.c (s390_collect_ptrace_register)
18722 (s390_supply_ptrace_register, s390_fill_gregset, s390_get_pc)
18723 (s390_set_pc): Change prototype to take a regcache. Adjust.
18724 (s390_arch_setup): Adjust.
18725 * linux-sh-low.c (sh_get_pc, sh_breakpoint_at)
18726 (sh_fill_gregset): Change prototype to take a regcache. Adjust.
18727 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
18728 (sparc_fill_gregset, sparc_store_gregset_from_stack)
18729 (sparc_store_gregset, sparc_get_pc): Change prototype to take a
18730 regcache. Adjust.
18731 (sparc_breakpoint_at): Adjust.
18732 * linux-xtensa-low.c (xtensa_fill_gregset):
18733 (xtensa_store_gregset):
18734 (xtensa_fill_xtregset, xtensa_store_xtregset, xtensa_get_pc)
18735 (xtensa_set_pc): Change prototype to take a regcache. Adjust.
18736 * nto-low.c (nto_fetch_registers, nto_store_registers): Change
18737 prototype to take a regcache. Adjust.
18738 * win32-arm-low.c (arm_fetch_inferior_register)
18739 (arm_store_inferior_register): Change prototype to take a
18740 regcache. Adjust.
18741 * win32-i386-low.c (i386_fetch_inferior_register)
18742 (i386_store_inferior_register): Change prototype to take a
18743 regcache. Adjust.
18744 * win32-low.c (child_fetch_inferior_registers)
18745 (child_store_inferior_registers): Change prototype to take a
18746 regcache. Adjust.
18747 (win32_wait): Adjust.
18748 (win32_fetch_inferior_registers): Change prototype to take a
18749 regcache. Adjust.
18750 (win32_store_inferior_registers): Adjust.
18751 * win32-low.h (struct win32_target_ops) <fetch_inferior_register,
18752 store_inferior_register>: Change prototype to take a regcache.
18753
60c3d7b0
DE
187542010-01-20 Doug Evans <dje@google.com>
18755
18756 * linux-low.c (linux_create_inferior): Wrap use of __SIGRTMIN in
18757 #ifdef.
18758 (linux_wait_for_event1, linux_init_signals): Ditto.
ec8ebe72 18759 (W_STOPCODE): Provide definition if missing.
60c3d7b0 18760
dc146f7c
VP
187612010-01-13 Vladimir Prus <vladimir@codesourcery.com>
18762
18763 * linux-low.c (linux_core_of_thread): New.
18764 (compare_ints, show_process, list_threads): New.
18765 (linux_qxfer_osdata): Report threads and cores.
18766 (linux_target_op): Register linux_core_of_thread.
18767 * remote-utils.c (prepare_resume_reply): Report the core.
18768 (buffer_xml_printf): Support %d specifier.
18769 * server.c (handle_threads_qxfer_proper, handle_threads_qxfer):
18770 New.
18771 (handle_query): Handle qXfer:threads. Announce availability
18772 thereof.
18773 * target.h (struct target_ops): New field core_of_thread.
18774
7803799a
UW
187752010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
18776
18777 * Makefile.in (clean): Remove new generated files.
18778 (reg-s390.o, reg-s390.c): Remove rules.
18779 (reg-s390x.o, reg-s390x.c): Likewise.
18780 (s390-linux32.o, s390-linux32.c): Add rules.
18781 (s390-linux64.o, s390-linux64.c): Likewise.
18782 (s390x-linux64.o, s390x-linux64.c): Likewise.
18783 * configure.srv (s390*-*-linux*): Update srv_regobj and srv_xmlfiles.
18784 * linux-s390-low.c: Include <elf.h>.
18785 (HWCAP_S390_HIGH_GPRS): Define if undefined.
18786 (init_registers_s390): Remove prototype.
18787 (init_registers_s390x): Likewise.
18788 (init_registers_s390_linux32): Add prototype.
18789 (init_registers_s390_linux64): Likewise.
18790 (init_registers_s390x_linux64): Likewise.
18791 (s390_num_regs_3264): New define.
18792 (s390_regmap_3264): New global variable.
18793 (s390_cannot_fetch_register): Remove obsolete check.
18794 (s390_cannot_store_register): Likewise.
18795 (s390_collect_ptrace_register): Handle upper/lower register halves.
18796 (s390_supply_ptrace_register): Likewise.
18797 (s390_fill_gregset): Update to register number changes.
18798 (s390_get_hwcap): New routine.
18799 (s390_arch_setup): Detect 32-bit process running on 64-bit system.
18800 Install appropriate regmap and register set.
18801
6e7ffa39
JB
188022010-01-01 Joel Brobecker <brobecker@adacore.com>
18803
18804 * server.c (gdbserver_version): Update copyright year to 2010.
18805 * gdbreplay.c (gdbreplay_version): Likewise.
18806
957f3f49
DE
188072009-12-28 Doug Evans <dje@google.com>
18808
18809 * linux-low.c: Delete inclusion of ansidecl.h, elf/common.h,
18810 elf/external.h. Include <elf.h> instead but only if necessary.
18811
ca5c370d
PA
188122009-12-28 Pedro Alves <pedro@codesourcery.com>
18813
18814 * linux-low.c (linux_remove_process): Remove `detaching'
18815 parameter. Don't release/detach from thread_db here.
18816 (linux_kill): Release/detach from thread_db here, ...
18817 (linux_detach): ... and here, before actually detaching.
18818 (linux_wait_1): ... and here, when a process exits.
18819 * thread-db.c (any_thread_of): New.
18820 (thread_db_free): Switch the current inferior to a thread of the
18821 passed in process.
18822
4ee62156
DE
188232009-12-21 Doug Evans <dje@google.com>
18824
d90e6a88
DE
18825 * linux-x86-low.c: Delete outdated comment about Elf32_Phdr.
18826
c5f62d5f
DE
18827 * linux-low.c (kill_lwp): Use __NR_tkill instead of SYS_tkill.
18828 Move definition of tkill_failed to ifdef __NR_tkill to avoid gcc
18829 warning ifndef __NR_tkill. Move setting of errno there too.
18830 Delete unnecessary resetting of errno after syscall.
18831 Minor comment changes to match gdb/linux-nat.c:kill_lwp.
18832
10e86dd7
DE
18833 * configure.ac: Check for dladdr.
18834 * config.in: Regenerate.
18835 * configure: Regenerate.
18836 * thread-db.c (dladdr_to_soname): Only define ifdef HAVE_DLADDR.
18837 (try_thread_db_load): Update.
18838
4ee62156
DE
18839 * linux-low.c (my_waitpid): Delete unnecessary prototype.
18840
00f515da
DE
188412009-12-18 Doug Evans <dje@google.com>
18842
e9464885
DE
18843 * event-loop.c: Include unistd.h if it exists.
18844
07d4f67e
DE
18845 * linux-low.c (my_waitpid): Move definition away from being in
18846 between linux_tracefork_child/linux_test_for_tracefork.
18847
00f515da
DE
18848 * gdb_proc_service.h (psaddr_t): Fix type.
18849 * thread-db.c (thread_db_info.td_thr_tls_get_addr_p): Fix
18850 signature to match glibc.
18851
1de1badb
DE
188522009-12-16 Doug Evans <dje@google.com>
18853
18854 * linux-low.c (linux_read_memory): Fix argument to read.
18855
aeeb81d1
PA
188562009-11-26 Pedro Alves <pedro@codesourcery.com>
18857
18858 * win32-low.c (get_child_debug_event): On EXIT_THREAD_DEBUG_EVENT
18859 events, don't leave current_inferior pointing at null.
18860
10357975
PA
188612009-11-26 Pedro Alves <pedro@codesourcery.com>
18862
18863 * win32-low.c (LOG): Delete.
18864 (OUTMSG): Output to stderr.
18865 (OUTMSG2): Conditionalize on `debug_threads' variable, instead of
18866 on compile time LOG macro.
18867 (win32_wait): Fix debug output.
18868
cf6e3471
PA
188692009-11-26 Pedro Alves <pedro@codesourcery.com>
18870
18871 * win32-low.c (win32_add_one_solib): If the dll name is
18872 "ntdll.dll", prepend the system directory to the dll path.
18873
0c85e18e
MK
188742009-11-17 Daniel Jacobowitz <dan@codesourcery.com>
18875
18876 * m68k-tdep.c (m68k_gdbarch_init): Reuse previous initialization.
18877
9ac544ce 188782009-11-17 Nathan Sidwell <nathan@codesourcery.com>
889bf7c5 18879 Vladimir Prus <vladimir@codesourcery.com>
9ac544ce
MK
18880
18881 * Makefile.in (reg-cf.o, reg-cf.c): New targets.
18882 * configure.ac: Check for __mcoldfire__ and set
18883 gdb_cv_m68k_is_coldfire.
18884 * configure.srv: Use gdb_cv_m68k_is_coldfire to select between
18885 reg-cf.o and reg-m68k.o.
18886 * configure: Regenerated.
18887
fd7dd3e6
PA
188882009-11-16 Pedro Alves <pedro@codesourcery.com>
18889
18890 * linux-low.c (linux_remove_process): Add `detaching' parameter.
18891 Pass it to thread_db_free.
18892 (linux_kill, linux_detach, linux_wait_1): Adjust to pass the
18893 proper `detaching' argument to linux_remove_process.
18894 * linux-low.h (thread_db_free): Add `detaching' parameter.
18895 * thread-db.c (thread_db_init): Pass false as `detaching' argument
18896 to thread_db_free.
18897 (thread_db_free): Add `detaching' parameter. Only
18898 call td_ta_clear_event if detaching from process.
18899
75aa492e
MK
189002009-11-12 Maxim Kuvyrkov <maxim@codesourcery.com>
18901
18902 * thread-db.c (thread_db_free): Fix typo.
18903
21e1bee4
PP
189042009-11-11 Paul Pluzhnikov <ppluzhnikov@google.com>
18905
18906 PR gdb/10838
18907 * thread-db.c (thread_db_free): Call td_ta_clear_event.
18908
8838b45e
NS
189092009-11-03 Nathan Sidwell <nathan@codesourcery.com>
18910
18911 * configure.ac (i[34567]86-*): Check if we're targetting x86-64
18912 with an i686 compiler.
18913 * configure.srv (i[34567]86-*-linux*): Pull in x86-64 handling if
18914 needed.
18915 * configure: Rebuilt.
18916
8a35fb51
SL
189172009-10-29 Sandra Loosemore <sandra@codesourcery.com>
18918
18919 PR gdb/10783
18920
18921 * server.c (handle_search_memory_1): Correct read_addr initialization
18922 in loop for searching subsequent chunks.
18923
96f15937
PP
189242009-10-29 Paul Pluzhnikov <ppluzhnikov@google.com>
18925
18926 * configure.ac: New --with-libthread-db option.
18927 * thread-db.c: Allow direct dependence on libthread_db.
18928 (thread_db_free): Adjust.
18929 * config.in: Regenerate.
18930 * configure: Likewise.
889bf7c5 18931
5f7d1694
PP
189322009-10-28 Paul Pluzhnikov <ppluzhnikov@google.com>
18933
18934 PR gdb/10757
18935 * thread-db.c (attach_thread): New function.
18936 (maybe_attach_thread): Return success/failure.
18937 (find_new_threads_callback): Adjust.
889bf7c5
PA
18938 (thread_db_find_new_threads): Loop until no new threads.
18939
88e3b899
PA
189402009-10-13 Pedro Alves <pedro@codesourcery.com>
18941
18942 * proc-service.c (ps_lgetregs): Formatting.
18943
cdbfd419
PP
189442009-10-08 Paul Pluzhnikov <ppluzhnikov@google.com>
18945
18946 * acinclude.m4: (SRV_CHECK_THREAD_DB, SRV_CHECK_TLS_GET_ADDR): Remove.
18947 * configure.ac: Adjust.
18948 * linux-low.h (struct process_info_private): Move members to struct
18949 thread_db.
18950 (thread_db_free, thread_db_handle_monitor_command): New prototype.
18951 * linux-low.c (linux_remove_process): Adjust.
18952 (linux_wait_for_event_1, linux_look_up_symbols): Likewise.
18953 * server.c (handle_query): Move code ...
18954 (handle_monitor_command): ... here. New function.
18955 * target.h (struct target_ops): New member.
18956 * thread-db.c (struct thread_db): New.
18957 (libthread_db_search_path): New variable.
18958 (thread_db_create_event, thread_db_enable_reporting)
18959 (find_one_thread, maybe_attach_thread, find_new_threads_callback)
18960 (thread_db_find_new_threads, (thread_db_get_tls_address): Adjust.
18961 (try_thread_db_load_1, dladdr_to_soname): New functions.
18962 (try_thread_db_load, thread_db_load_search): New functions.
18963 (thread_db_init): Search for libthread_db.
18964 (thread_db_free): New function.
18965 (thread_db_handle_monitor_command): Likewise.
18966 * config.in: Regenerate.
18967 * configure: Regenerate.
889bf7c5 18968
4168d2d6
UW
189692009-09-27 Ulrich Weigand <uweigand@de.ibm.com>
18970
18971 * spu-low.c (spu_kill): Wait for inferior to terminate.
18972 Call clear_inferiors.
18973 (spu_detach): Call clear_inferiors.
18974
81ecdfbb
RW
189752009-08-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
18976
18977 * aclocal.m4: Regenerate.
18978 * config.in: Likewise.
18979 * configure: Likewise.
18980
0b9ff2c0
UW
189812009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
18982
18983 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Define.
18984 (parse_spufs_run): New function.
18985 (ppc_get_pc, ppc_set_pc): Detect and handle SPU PC.
18986 (ppc_breakpoint_at): Handle SPU breakpoints.
18987
efcbbd14
UW
189882009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
18989
18990 * linux-low.c: Include <sys/stat.h> and <sys/vfs.h>.
18991 (SPUFS_MAGIC): Define.
18992 (spu_enumerate_spu_ids): New function.
18993 (linux_qxfer_spu): New function.
18994 (linux_target_ops): Install linux_qxfer_spu.
18995
f4d9bade
UW
189962009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
18997
18998 * configure.srv (powerpc*-*-linux*): Add powerpc-cell32l.o
18999 and powerpc-cell64l.o to srv_regobj. Add rs6000/powerpc-cell32l.xml
19000 and rs6000/powerpc-cell64l.xml to srv_xmlfiles.
19001 * Makefile.in (powerpc-cell32l.o, powerpc-cell32l.c): New rules.
19002 (powerpc-cell64l.o, powerpc-cell64l.c): Likewise.
19003 (clean): Handle powerpc-cell32l.c and powerpc-cell64l.c.
19004 * linux-ppc-low.c (PPC_FEATURE_CELL): Define.
19005 (init_registers_powerpc_cell32l): Add prototype.
19006 (init_registers_powerpc_cell64l): Likewise.
19007 (ppc_arch_setup): Detect Cell/B.E. architecture.
19008
96e946ca
RW
190092009-07-30 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
19010
19011 * Makefile.in (datarootdir): New variable.
19012
58d6951d
DJ
190132009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
19014
19015 * linux-low.c (linux_write_memory): Update debugging output.
19016 * Makefile.in (clean): Add new descriptions.
19017 (arm-with-vfpv2.o, arm-with-vfpv2.c, arm-with-vfpv3.o)
19018 (arm-with-vfpv3.c, arm-with-neon.o, arm-with-neon.c): New rules.
19019 * configure.srv: Add new files for arm*-*-linux*.
19020 * linux-arm-low.c: Add new declarations.
19021 (PTRACE_GETVFPREGS, PTRACE_SETVFPREGS): Define if undefined.
19022 (arm_hwcap, HWCAP_VFP, HWCAP_IWMMXT, HWCAP_NEON, HWCAP_VFPv3)
19023 (HWCAP_VFPv3D16): New.
19024 (arm_fill_wmmxregset, arm_store_wmmxregset): Check HWCAP_IWMMXT
19025 instead of __IWMMXT__.
19026 (arm_fill_vfpregset, arm_store_vfpregset, arm_get_hwcap)
19027 (arm_arch_setup): New.
19028 (target_regsets): Remove #ifdef. Add VFP regset.
19029 (the_low_target): Use arm_arch_setup.
19030
12b42a12
DJ
190312009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
19032
19033 * linux-low.c (linux_kill_one_lwp): Adjust kernel workaround to skip
19034 the main thread again.
19035
ac8c974e
AR
190362009-07-06 Aleksandar Ristovski <aristovski@qnx.com>
19037
19038 Adding Neutrino gdbserver.
19039 * configure: Regenerated.
19040 * configure.ac: Add case for srv_qnx and set LIBS accordingly.
19041 * configure.srv (i[34567]86-*-nto*): New target.
19042 * nto-low.c, nto-low.h, nto-x86-low.c: New files.
19043 * remote-utils.c [__QNX__]: Include sys/iomgr.h
19044 (nto_comctrl) [__QNX__]: New function.
19045 (enable_async_io, disable_async_io) [__QNX__]: Call nto_comctrl.
19046
4424e0c3 190472009-07-05 Danny Backx <dannybackx@users.sourceforge.net>
7437790a
PA
19048
19049 * configure.srv (i[34567]86-*-mingw32ce*): Add i386-low.o to
19050 srv_tgtobj.
19051
912cf4ba
PA
190522009-07-04 Danny Backx <dannybackx@users.sourceforge.net>
19053 Pedro Alves <pedro@codesourcery.com>
19054
19055 * win32-i386-low.c (i386_get_thread_context): Handle systems that
19056 don't support CONTEXT_EXTENDED_REGISTERS.
19057 (i386_win32_breakpoint, i386_win32_breakpoint_len): New.
19058 (the_low_target): Install them.
19059 * win32-low.c (get_child_debug_event): Handle WaitForDebugEvent
19060 failing with ERROR_PIPE_NOT_CONNECTED.
19061
aa5ca48f
DE
190622009-06-30 Doug Evans <dje@google.com>
19063 Pierre Muller <muller@ics.u-strasbg.fr>
19064
19065 Add h/w watchpoint support to x86-linux, win32-i386.
19066 * Makefile.in (SFILES): Add i386-low.c
19067 (i386_low_h): Define.
19068 (i386-low.o): Add dependencies.
19069 (linux-x86-low.o): Add i386-low.h dependency.
19070 (win32-i386-low.o): Ditto.
19071 * i386-low.c: New file.
19072 * i386-low.h: New file.
19073 * configure.srv (i[34567]86-*-cygwin*): Add i386-low.o to srv_tgtobj.
19074 (i[34567]86-*-linux*, i[34567]86-*-mingw*, x86_64-*-linux*): Ditto.
19075 * linux-low.c (linux_add_process): Initialize arch_private.
19076 (linux_remove_process): Free arch_private.
19077 (add_lwp): Initialize arch_private.
19078 (delete_lwp): Free arch_private.
19079 (linux_resume_one_lwp): Call the_low_target.prepare_to_resume if
19080 provided.
19081 * linux-low.h (process_info_private): New member arch_private.
19082 (lwp_info): New member arch_private.
19083 (linux_target_ops): New members new_process, new_thread,
19084 prepare_to_resume.
19085 (ptid_of): New macro.
19086 * linux-x86-low.c: Include stddef.h, i386-low.h.
19087 (arch_process_info): New struct.
19088 (arch_lwp_info): New struct.
19089 (x86_linux_dr_get, x86_linux_dr_set): New functions.
19090 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
19091 (i386_dr_low_get_status): New function.
19092 (x86_insert_point, x86_remove_point): New functions.
19093 (x86_stopped_by_watchpoint): New function.
19094 (x86_stopped_data_address): New function.
19095 (x86_linux_new_process, x86_linux_new_thread): New functions.
19096 (x86_linux_prepare_to_resume): New function.
19097 (the_low_target): Add entries for insert_point, remove_point,
19098 stopped_by_watchpoint, stopped_data_address, new_process, new_thread,
19099 prepare_to_resume.
19100 * server.c (debug_hw_points): New global.
19101 (monitor_show_help): Document set debug-hw-points.
19102 (handle_query): Process "set debug-hw-points".
19103 * server.h (debug_hw_points): Declare.
19104 (paddress): Declare.
19105 * utils.c (NUMCELLS, CELLSIZE): New macros.
19106 (get_sell, xsnprintf, paddress): New functions.
19107 * win32-arm-low.c (the_low_target): Add entries for insert_point,
19108 remove_point, stopped_by_watchpoint, stopped_data_address.
19109 * win32-i386-low.c: Include i386-low.h.
19110 (debug_reg_state): Replaces dr.
19111 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
19112 (i386_dr_low_get_status): New function.
19113 (i386_insert_point, i386_remove_point): New functions.
19114 (i386_stopped_by_watchpoint): New function.
19115 (i386_stopped_data_address): New function.
19116 (i386_initial_stuff): Update.
19117 (get_thread_context,set_thread_context,i386_thread_added): Update.
19118 (the_low_target): Add entries for insert_point,
19119 remove_point, stopped_by_watchpoint, stopped_data_address.
19120 * win32-low.c (win32_insert_watchpoint): New function.
19121 (win32_remove_watchpoint): New function.
19122 (win32_stopped_by_watchpoint): New function.
19123 (win32_stopped_data_address): New function.
19124 (win32_target_ops): Add entries for insert_watchpoint,
19125 remove_watchpoint, stopped_by_watchpoint, stopped_data_address.
19126 * win32-low.h (win32_target_ops): New members insert_point,
19127 remove_point, stopped_by_watchpoint, stopped_data_address.
19128
d993e290
PA
191292009-06-25 Pedro Alves <pedro@codesourcery.com>
19130
19131 * server.c (process_serial_event): Re-return unsupported, not
19132 error, if the type isn't recognized. Re-allow supporting only
19133 insert or remove packets. Also call require_running for
19134 breakpoints. Add missing break statement to default case. Tidy.
19135 * target.h (struct target_ops): Rename insert_watchpoint to
19136 insert_point, and remove_watchpoint to remove_point.
19137
19138 * linux-low.h (struct linux_target_ops): Likewise.
19139 * linux-low.c (linux_insert_watchpoint): Rename to ...
19140 (linux_insert_point): ... this. Adjust.
19141 (linux_remove_watchpoint): Rename to ...
19142 (linux_remove_point): ... this. Adjust.
19143 (linux_target_ops): Adjust.
19144 * linux-crisv32-low.c (cris_insert_watchpoint): Rename to ...
19145 (cris_insert_point): ... this.
19146 (cris_remove_watchpoint): Rename to ...
19147 (cris_remove_point): ... this.
19148 (the_low_target): Adjust.
19149
0f54c268
PM
191502009-06-24 Pierre Muller <muller@ics.u-strasbg.fr>
19151
19152 * server.c (handle_v_kill): Pass signal_pid to
19153 kill_inferior if multi_process is zero.
19154
c6314022
AR
191552009-06-23 Aleksandar Ristovski <aristovski@qnx.com>
19156
19157 * server.c (process_serial_event): Add support for Z0 and Z1 packet.
19158 * target.h (target_ops): Comment for *_watchpoint to make it clear
19159 the functions can get types '0' and '1'.
19160
4463ce24
AR
191612009-06-22 Aleksandar Ristovski <aristovski@qnx.com>
19162
19163 * linux-low.c (usr_fetch_inferior_registers): Remove check for regno 0.
19164 * proc-service.c (ps_lgetregs): Pass -1 to fetch all registers.
19165 * regcache.c (get_regcache): Likewise.
19166 * spu-low.c (spu_fetch_registers): Remove 0 to -1 conversion.
19167 * win32-low.c (child_fetch_inferior_registers): Remove check for
19168 regno 0.
19169
cf8fd78b
PA
191702009-06-19 Aleksandar Ristovski <aristovski@qnx.com>
19171 Pedro Alves <pedro@codesourcery.com>
19172
19173 * target.h (struct target_ops) <supports_multi_process>: New
19174 callback.
19175 (target_supports_multi_process): New.
19176 * server.c (handle_query): Even if GDB reports support, only
19177 enable multi-process if the target also supports it. Report
19178 multi-process support only if the target backend supports it.
19179 * linux-low.c (linux_supports_multi_process): New function.
19180 (linux_target_ops): Install it as target_supports_multi_process
19181 callback.
19182
47c0c975
DE
191832009-05-24 Doug Evans <dje@google.com>
19184
e09875d4
DE
19185 Global renaming of find_thread_pid to find_thread_ptid.
19186 * server.h (find_thread_ptid): Renamed from find_thread_pid.
19187 * inferiors.c (find_thread_ptid): Renamed from find_thread_pid.
19188 All callers updated.
19189
e27d73f6
DE
19190 * linux-low.c (handle_extended_wait): Use linux_resume_one_lwp
19191 to resume the newly created thread, don't call ptrace (PTRACE_CONT)
19192 directly.
19193
47c0c975
DE
19194 * linux-low.c (get_stop_pc): Print pc if debug_threads.
19195 (check_removed_breakpoint, linux_wait_for_lwp): Ditto.
19196 (linux_resume_one_lwp): Ditto.
19197
2acc282a
DE
191982009-05-23 Doug Evans <dje@google.com>
19199
19200 * linux-low.c (linux_resume_one_lwp): Change type of first arg
19201 from struct inferior_list_entry * to struct lwp_info *.
19202 All callers updated.
19203
9f1036c1
DE
192042009-05-13 Doug Evans <dje@google.com>
19205
19206 * linux-x86-low.c: Don't include assert.h.
19207 (x86_siginfo_fixup): Use fatal, not assert.
19208 (x86_arch_setup): Fix comment.
19209
d0722149
DE
192102009-05-12 Doug Evans <dje@google.com>
19211
19212 Biarch support for i386/amd64 gdbserver.
19213 * Makefile.in (SFILES): Remove linux-i386-low.c, linux-x86-64-low.c.
19214 Add linux-x86-low.c.
19215 (linux-i386-low.o, linux-x86-64-low.o): Delete.
19216 (linux-x86-low.o): Add.
19217 * linux-x86-64-low.c: Delete.
19218 * linux-i386-low.c: Delete.
19219 * linux-x86-low.c: New file.
19220 * configure.srv (i?86-linux srv_tgtobj): Replace linux-i386-low.o with
19221 linux-x86-low.o.
19222 (x86_64-linux srv_tgtobj): Replace linux-x86-64-low.o with
19223 linux-x86-low.o.
19224 (x86_64-linux srv_regobj): Add reg-i386-linux.o.
19225 * linux-low.c: Include ansidecl.h, elf/common.h, elf/external.h.
19226 (linux_child_pid_to_exec_file): New function.
19227 (elf_64_header_p, elf_64_file_p): New functions.
19228 (siginfo_fixup): New function.
19229 (linux_xfer_siginfo): New local inf_siginfo. Call siginfo_fixup to
19230 give target a chance to convert layout.
19231 * linux-low.h (linux_target_ops): New member siginfo_fixup.
19232 (linux_child_pid_to_exec_file, elf_64_file_p): Declare.
19233
fdeb2a12
DE
192342009-05-07 Doug Evans <dje@google.com>
19235
19236 * linux-low.c (regsets_fetch_inferior_registers): Fix memory leak.
19237 (regsets_store_inferior_registers): Ditto.
19238
a6dbe5df
PA
192392009-05-06 Pedro Alves <pedro@codesourcery.com>
19240
19241 PR server/10048
19242
19243 * linux-low.c (must_set_ptrace_flags): Delete.
19244 (linux_create_inferior): Set `lwp->must_set_ptrace_flags' instead
19245 of the global.
19246 (linux_attach_lwp_1): Don't set PTRACE_SETOPTIONS here. Set
19247 `lwp->must_set_ptrace_flags' instead.
ba42693b 19248 (linux_wait_for_event_1): Set ptrace options here.
a6dbe5df
PA
19249 (linux_wait_1): ... not here.
19250
5091eb23
DE
192512009-04-30 Doug Evans <dje@google.com>
19252
9f767825
DE
19253 * inferiors.c (started_inferior_callback): New function.
19254 (attached_inferior_callback): New function.
19255 (have_started_inferiors_p, have_attached_inferiors_p): New functions.
19256 * server.c (print_started_pid, print_attached_pid): New functions.
19257 (detach_or_kill_for_exit): New function.
19258 (main): Call it instead of for_each_inferior (kill_inferior_callback).
19259 * server.h (have_started_inferiors_p): Declare.
19260 (have_attached_inferiors_p): Declare.
19261
5091eb23
DE
19262 * inferiors.c (remove_process): Fix memory leak, free process.
19263 * linux-low.c (linux_remove_process): New function.
19264 (linux_kill): Call it instead of remove_process.
19265 (linux_detach, linux_wait_1): Ditto.
19266
155c8968
PA
192672009-04-19 Danny Backx <dannybackx@users.sourceforge.net>
19268
19269 * configure.srv: Add x86 Windows CE target.
19270
7fe519cb
UW
192712009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
19272
19273 * inferiors.c (get_thread_process): Make global.
19274 * server.h (get_thread_process): Add prototype.
19275 * thread-db.c (find_one_thread): Use get_thread_process
19276 instead of current_process.
19277 (thread_db_get_tls_address): Do not crash if called when
19278 thread layer is not yet initialized.
19279
5472f405
UW
192802009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
19281
19282 * remote-utils.c (prepare_resume_reply): Null-terminate packet.
19283 * spu-low.c (current_tid): Rename to ...
19284 (current_ptid): ... this.
19285 (fetch_ppc_register, fetch_ppc_memory, store_ppc_memory,
19286 spu_proc_xfer_spu, spu_resume, spu_request_interrupt): Use
19287 ptid_get_lwp (current_ptid) instead of current_tid.
19288 (spu_kill, spu_detach, spu_join, spu_wait): Use pid argument
19289 instead of current_tid. Use find_process_pid to verify pid
19290 argument is valid. Pass proper argument to remove_process.
19291 (spu_thread_alive): Compare current_ptid instead of current_tid.
19292 (spu_resume): Likewise.
19293
55ac2b99
PA
192942009-04-02 Pedro Alves <pedro@codesourcery.com>
19295
19296 * linux-low.c (usr_store_inferior_registers): Declare local `pid'
19297 variable.
19298
95954743
PA
192992009-04-01 Pedro Alves <pedro@codesourcery.com>
19300
19301 Implement the multiprocess extensions, and add linux multiprocess
19302 support.
19303
19304 * server.h (ULONGEST): Declare.
19305 (struct ptid, ptid_t): New.
19306 (minus_one_ptid, null_ptid): Declare.
19307 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
19308 (ptid_get_tid, ptid_equal, ptid_is_pid): Declare.
19309 (struct inferior_list_entry): Change `id' type from unsigned from
19310 to ptid_t.
19311 (struct sym_cache, struct breakpoint, struct
19312 process_info_private): Forward declare.
19313 (struct process_info): Declare.
19314 (current_process): Declare.
19315 (all_processes): Declare.
19316 (initialize_inferiors): Declare.
19317 (add_thread): Adjust to use ptid_t.
19318 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): Ditto.
19319 (add_process, remove_process, find_thread_pid): Declare.
19320 (find_inferior_id): Adjust to use ptid_t.
19321 (cont_thread, general_thread, step_thread): Change type to ptid_t.
19322 (multi_process): Declare.
19323 (push_event): Adjust to use ptid_t.
19324 (read_ptid, write_ptid): Declare.
19325 (prepare_resume_reply): Adjust to use ptid_t.
19326 (clear_symbol_cache): Declare.
19327 * inferiors.c (all_processes): New.
19328 (null_ptid, minus_one_ptid): New.
19329 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
19330 (ptid_get_tid, ptid_equal, ptid_is_pid): New.
19331 (add_thread): Change unsigned long to ptid. Remove gdb_id
19332 parameter. Adjust.
19333 (thread_id_to_gdb_id, thread_to_gdb_id): Change unsigned long to ptid.
19334 (gdb_id_to_thread): Rename to ...
19335 (find_thread_pid): ... this. Change unsigned long to ptid.
19336 (gdb_id_to_thread_id, find_inferior_id): Change unsigned long to ptid.
19337 (loaded_dll, pull_pid_from_list): Adjust.
19338 (add_process, remove_process, find_process_pid)
19339 (get_thread_process, current_process, initialize_inferiors): New.
19340 * target.h (struct thread_resume) <thread>: Change type to ptid_t.
19341 (struct target_waitstatus) <related_pid>: Ditto.
19342 (struct target_ops) <kill, detach>: Add `pid' argument. Change
19343 return type to int.
19344 (struct target_ops) <join>: Add `pid' argument.
19345 (struct target_ops) <thread_alive>: Change pid's type to ptid_t.
19346 (struct target_ops) <wait>: Add `ptid' field. Change return type
19347 to ptid.
19348 (kill_inferior, detach_inferior, join_inferior): Add `pid' argument.
19349 (mywait): Add `ptid' argument. Change return type to ptid_t.
19350 (target_pid_to_str): Declare.
19351 * target.c (set_desired_inferior): Adjust to use ptids.
19352 (mywait): Add new `ptid' argument. Adjust.
19353 (target_pid_to_str): New.
19354 * mem-break.h (free_all_breakpoints): Declare.
19355 * mem-break.c (breakpoints): Delelete.
19356 (set_breakpoint_at, delete_breakpoint, find_breakpoint_at)
19357 (check_mem_read, check_mem_write, delete_all_breakpoints): Adjust
19358 to use per-process breakpoint list.
19359 (free_all_breakpoints): New.
19360 * remote-utils.c (struct sym_cache) <name>: Drop `const'.
19361 (symbol_cache, all_symbols_looked_up): Delete.
19362 (hexchars): New.
19363 (ishex, unpack_varlen_hex, write_ptid, hex_or_minus_one,
19364 read_ptid): New.
19365 (prepare_resume_reply): Change ptid argument's type from unsigned
19366 long to ptid_t. Adjust. Implement W;process and X;process.
19367 (free_sym_cache, clear_symbol_cache): New.
19368 (look_up_one_symbol): Adjust to per-process symbol cache. *
19369 * server.c (cont_thread, general_thread, step_thread): Change type
19370 to ptid_t.
19371 (attached): Delete.
19372 (multi_process): New.
19373 (last_ptid): Change type to ptid_t.
19374 (struct vstop_notif) <ptid>: Change type to ptid_t.
19375 (queue_stop_reply, push_event): Change `ptid' argument's type to
19376 ptid_t.
19377 (discard_queued_stop_replies): Add `pid' argument.
19378 (start_inferior): Adjust to use ptids. Adjust to mywait interface
19379 changes. Don't reference the `attached' global.
19380 (attach_inferior): Adjust to mywait interface changes.
19381 (handle_query): Adjust to use ptids. Parse GDB's qSupported
19382 features. Handle and report "multiprocess+". Handle
19383 "qAttached:PID".
19384 (handle_v_cont): Adjust to use ptids. Adjust to mywait interface
19385 changes.
19386 (handle_v_kill): New.
19387 (handle_v_stopped): Adjust to use target_pid_to_str.
19388 (handle_v_requests): Allow multiple attaches and runs when
19389 multiprocess extensions are in effect. Handle "vKill".
19390 (myresume): Adjust to use ptids.
19391 (queue_stop_reply_callback): Add `arg' parameter. Handle it.
19392 (handle_status): Adjust to discard_queued_stop_replies interface
19393 change.
19394 (first_thread_of, kill_inferior_callback)
19395 (detach_or_kill_inferior_callback, join_inferiors_callback): New.
19396 (main): Call initialize_inferiors. Adjust to use ptids, killing
19397 and detaching from all inferiors. Handle multiprocess packet
19398 variants.
19399 * linux-low.h: Include gdb_proc_service.h.
19400 (struct process_info_private): New.
19401 (struct linux_target_ops) <pid_of>: Use ptid_get_pid.
19402 <lwpid_of>: Use ptid_get_lwp.
19403 (get_lwp_thread): Adjust.
19404 (struct lwp_info): Add `dead' member.
19405 (find_lwp_pid): Declare.
19406 * linux-low.c (thread_db_active): Delete.
19407 (new_inferior): Adjust comment.
19408 (inferior_pid): Delete.
19409 (linux_add_process): New.
19410 (handle_extended_wait): Adjust.
19411 (add_lwp): Change unsigned long to ptid.
19412 (linux_create_inferior): Add process to processes table. Adjust
19413 to use ptids. Don't set new_inferior here.
19414 (linux_attach_lwp): Rename to ...
19415 (linux_attach_lwp_1): ... this. Add `initial' argument. Handle
19416 it. Adjust to use ptids.
19417 (linux_attach_lwp): New.
19418 (linux_attach): Add process to processes table. Don't set
19419 new_inferior here.
19420 (struct counter): New.
19421 (second_thread_of_pid_p, last_thread_of_process_p): New.
19422 (linux_kill_one_lwp): Add `args' parameter. Handle it. Adjust to
19423 multiple processes.
19424 (linux_kill): Add `pid' argument. Handle it. Adjust to multiple
19425 processes. Remove process from process table.
19426 (linux_detach_one_lwp): Add `args' parameter. Handle it. Adjust
19427 to multiple processes.
19428 (any_thread_of): New.
19429 (linux_detach): Add `pid' argument, and handle it. Remove process
19430 from processes table.
19431 (linux_join): Add `pid' argument. Handle it.
19432 (linux_thread_alive): Change unsighed long argument to ptid_t.
19433 Consider dead lwps as not being alive.
19434 (status_pending_p): Rename `dummy' argument to `arg'. Filter out
19435 threads we're not interested in.
19436 (same_lwp, find_lwp_pid): New.
19437 (linux_wait_for_lwp): Change `pid' argument's type from int to
19438 ptid_t. Adjust.
19439 (linux_wait_for_event): Rename to ...
19440 (linux_wait_for_event_1): ... this. Change `pid' argument's type
19441 from int to ptid_t. Adjust.
19442 (linux_wait_for_event): New.
19443 (linux_wait_1): Add `ptid' argument. Change return type to
19444 ptid_t. Adjust. Use last_thread_of_process_p. Remove processes
19445 that exit from the process table.
19446 (linux_wait): Add `ptid' argument. Change return type to ptid_t.
19447 Adjust.
19448 (mark_lwp_dead): New.
19449 (wait_for_sigstop): Adjust to use ptids. If a process exits while
19450 stopping all threads, mark its main lwp as dead.
19451 (linux_set_resume_request, linux_resume_one_thread): Adjust to use
19452 ptids.
19453 (fetch_register, usr_store_inferior_registers)
19454 (regsets_fetch_inferior_registers)
19455 (regsets_store_inferior_registers, linux_read_memory)
19456 (linux_write_memory): Inline `inferior_pid'.
19457 (linux_look_up_symbols): Adjust to use per-process
19458 `thread_db_active'.
19459 (linux_request_interrupt): Adjust to use ptids.
19460 (linux_read_auxv): Inline `inferior_pid'.
19461 (initialize_low): Don't reference thread_db_active.
19462 * gdb_proc_service.h (struct ps_prochandle) <pid>: Remove.
19463 * proc-service.c (ps_lgetregs): Use find_lwp_pid.
19464 (ps_getpid): Return the pid of the current inferior.
19465 * thread-db.c (proc_handle, thread_agent): Delete.
19466 (thread_db_create_event, thread_db_enable_reporting): Adjust to
19467 per-process data.
19468 (find_one_thread): Change argument type to ptid_t. Adjust to
19469 per-process data.
19470 (maybe_attach_thread): Adjust to per-process data and ptids.
19471 (thread_db_find_new_threads): Ditto.
19472 (thread_db_init): Ditto.
19473 * spu-low.c (spu_create_inferior, spu_attach): Add process to
19474 processes table. Adjust to use ptids.
19475 (spu_kill, spu_detach): Adjust interface. Remove process from
19476 processes table.
19477 (spu_join, spu_thread_alive): Adjust interface.
19478 (spu_wait): Adjust interface. Remove process from processes
19479 table. Adjust to use ptids.
19480 * win32-low.c (current_inferior_tid): Delete.
19481 (current_inferior_ptid): New.
19482 (debug_event_ptid): New.
19483 (thread_rec): Take a ptid. Adjust.
19484 (child_add_thread): Add `pid' argument. Adjust to use ptids.
19485 (child_delete_thread): Ditto.
19486 (do_initial_child_stuff): Add `attached' argument. Add process to
19487 processes table.
19488 (child_fetch_inferior_registers, child_store_inferior_registers):
19489 Adjust.
19490 (win32_create_inferior): Pass 0 to do_initial_child_stuff.
19491 (win32_attach): Pass 1 to do_initial_child_stuff.
19492 (win32_kill): Adjust interface. Remove process from processes
19493 table.
19494 (win32_detach): Ditto.
19495 (win32_join): Adjust interface.
19496 (win32_thread_alive): Take a ptid.
19497 (win32_resume): Adjust to use ptids.
19498 (get_child_debug_event): Ditto.
19499 (win32_wait): Adjust interface. Remove exiting process from
19500 processes table.
19501
bd99dc85
PA
195022009-04-01 Pedro Alves <pedro@codesourcery.com>
19503
19504 Non-stop mode support.
19505
19506 * server.h (non_stop): Declare.
19507 (gdb_client_data, handler_func): Declare.
19508 (delete_file_handler, add_file_handler, start_event_loop):
19509 Declare.
19510 (handle_serial_event, handle_target_event, push_event)
19511 (putpkt_notif): Declare.
19512 * target.h (enum resume_kind): New.
19513 (struct thread_resume): Replace `step' field by `kind' field.
19514 (TARGET_WNOHANG): Define.
19515 (struct target_ops) <wait>: Add `options' argument.
19516 <supports_non_stop, async, start_non_stop>: New fields.
19517 (target_supports_non_stop, target_async): New.
19518 (start_non_stop): Declare.
19519 (mywait): Add `options' argument.
19520 * target.c (mywait): Add `options' argument. Print child exit
19521 notifications here.
19522 (start_non_stop): New.
19523 * server.c (non_stop, own_buf, mem_buf): New globals.
19524 (struct vstop_notif): New.
19525 (notif_queue): New global.
19526 (queue_stop_reply, push_event, discard_queued_stop_replies)
19527 (send_next_stop_reply): New.
19528 (start_inferior): Adjust to use resume_kind. Adjust to mywait
19529 interface changes.
19530 (attach_inferior): In non-stop mode, don't wait for the target
19531 here.
19532 (handle_general_set): Handle QNonStop.
19533 (handle_query): When handling qC, return the current general
19534 thread, instead of the first thread of the list.
19535 (handle_query): If the backend supports non-stop mode, include
19536 QNonStop+ in the qSupported query response.
19537 (handle_v_cont): Adjust to use resume_kind. Handle resume_stop
19538 and non-stop mode.
19539 (handle_v_attach, handle_v_run): Handle non-stop mode.
19540 (handle_v_stopped): New.
19541 (handle_v_requests): Report support for vCont;t. Handle vStopped.
19542 (myresume): Adjust to use resume_kind. Handle non-stop.
19543 (queue_stop_reply_callback): New.
19544 (handle_status): Handle non-stop mode.
19545 (main): Clear non_stop flag on reconnection. Use the event-loop.
19546 Refactor serial protocol handling from here ...
19547 (process_serial_event): ... to this new function. When GDB
19548 selects any thread, select one here. In non-stop mode, wait until
19549 GDB acks all pending events before exiting.
19550 (handle_serial_event, handle_target_event): New.
19551 * remote-utils.c (remote_open): Install remote_desc in the event
19552 loop.
19553 (remote_close): Remove remote_desc from the event loop.
19554 (putpkt_binary): Rename to...
19555 (putpkt_binary_1): ... this. Add `is_notic' argument. Handle it.
19556 (putpkt_binary): New as wrapper around putpkt_binary_1.
19557 (putpkt_notif): New.
19558 (prepare_resume_reply): In non-stop mode, don't change the
19559 general_thread.
19560 * event-loop.c: New.
19561 * Makefile.in (OBJ): Add event-loop.o.
19562 (event-loop.o): New rule.
19563
19564 * linux-low.h (pid_of): Moved here.
19565 (lwpid_of): New.
19566 (get_lwp_thread): Use lwpid_of.
19567 (struct lwp_info): Delete `lwpid' field. Add `suspended' field.
19568 * linux-low.c (pid_of): Delete.
19569 (inferior_pid): Use lwpid_of.
19570 (linux_event_pipe): New.
19571 (target_is_async_p): New.
19572 (delete_lwp): New.
19573 (handle_extended_wait): Use lwpid_of.
19574 (add_lwp): Don't set lwpid field.
19575 (linux_attach_lwp): Adjust debug output. Use lwpid_of.
19576 (linux_kill_one_lwp): If killing a running lwp, stop it first.
19577 Use lwpid_of. Adjust to linux_wait_for_event interface changes.
19578 (linux_detach_one_lwp): If detaching from a running lwp, stop it
19579 first. Adjust to linux_wait_for_event interface changes. Use
19580 lwpid_of.
19581 (linux_detach): Don't delete the main lwp here.
19582 (linux_join): Use my_waitpid. Avoid signal_pid. Use lwpid_of.
19583 (status_pending_p): Don't consider explicitly suspended lwps.
19584 (linux_wait_for_lwp): Take an integer pid instead of a lwp_info
19585 pointer. Add OPTIONS argument. Change return type to int. Use
19586 my_waitpid instead of sleeping. Handle WNOHANG. Use lwpid_of.
19587 (linux_wait_for_event): Take an integer pid instead of a lwp_info
19588 pointer. Add status pointer argument. Return a pid instead of a
19589 status. Use lwpid_of. Adjust to linux_wait_for_lwp interface
19590 changes. In non-stop mode, don't switch to a random thread.
19591 (linux_wait): Rename to...
19592 (linux_wait_1): ... this. Add target_options argument, and handle
19593 it. Adjust to use resume_kind. Use lwpid_of. In non-stop mode,
19594 don't handle the continue thread. Handle TARGET_WNOHANG. Merge
19595 clean exit and signal exit code. Don't stop all threads in
19596 non-stop mode. In all-stop mode, only stop all threads when
19597 reporting a stop to GDB. Handle explicit thread stop requests.
19598 (async_file_flush, async_file_mark): New.
19599 (linux_wait): New.
19600 (send_sigstop): Use lwpid_of.
19601 (wait_for_sigstop): Use lwpid_of. Adjust to linux_wait_for_event
19602 interface changes. In non-stop mode, don't switch to a random
19603 thread.
19604 (linux_resume_one_lwp): Use lwpid_of.
19605 (linux_continue_one_thread, linux_queue_one_thread): Merge into ...
19606 (linux_resume_one_thread): ... this. Handle resume_stop. In
19607 non-stop mode, don't look for pending flag in all threads.
19608 (resume_status_pending_p): Don't consider explicitly suspended
19609 threads.
19610 (my_waitpid): Reimplement. Emulate __WALL.
19611 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
19612 Use lwpid_of.
19613 (sigchld_handler, linux_supports_non_stop, linux_async)
19614 (linux_start_non_stop): New.
19615 (linux_target_ops): Register linux_supports_non_stop, linux_async
19616 and linux_start_non_stop.
19617 (initialize_low): Install SIGCHLD handler.
19618 * thread-db.c (thread_db_create_event, find_one_thread)
19619 (thread_db_get_tls_address): Use lwpid_of.
19620 * win32-low.c (win32_detach): Adjust to use resume_kind.
19621 (win32_wait): Add `options' argument.
19622 * spu-low.c (spu_resume): Adjust to use resume_kind.
19623 (spu_wait): Add `options' argument.
19624
5b1c542e
PA
196252009-04-01 Pedro Alves <pedro@codesourcery.com>
19626
19627 Decouple target code from remote protocol.
19628
19629 * target.h (enum target_waitkind): New.
19630 (struct target_waitstatus): New.
19631 (struct target_ops) <wait>: Return an unsigned long. Take a
19632 target_waitstatus pointer instead of a char pointer.
19633 (mywait): Likewise.
19634 * target.c (mywait): Change prototype to return an unsigned long.
19635 Take a target_waitstatus pointer instead of a char pointer. Adjust.
19636 * server.h (thread_from_wait, old_thread_from_wait): Delete
19637 declarations.
19638 (prepare_resume_reply): Change prototype to take a
19639 target_waitstatus.
19640 * server.c (thread_from_wait, old_thread_from_wait): Delete.
19641 (last_status, last_ptid): New.
19642 (start_inferior): Remove "statusptr" argument. Adjust. Return a
19643 pid instead of a signal.
19644 (attach_inferior): Remove "status" and "signal" parameters.
19645 Adjust.
19646 (handle_query): For qGetTLSAddr, parse the thread id with strtol,
19647 not as an address.
19648 (handle_v_cont, handle_v_attach, handle_v_run, handle_v_kill)
19649 (handle_v_requests, myresume): Remove "status" and "signal"
19650 parameters. Adjust.
19651 (handle_status): New.
19652 (main): Delete local `status'. Adjust.
19653 * remote-utils.c: Include target.h.
19654 (prepare_resume_reply): Change prototype to take a
19655 target_waitstatus. Adjust.
19656
19657 * linux-low.c (linux_wait): Adjust to new target_ops->wait
19658 interface.
19659 * spu-low.c (spu_wait): Adjust.
19660 * win32-low.c (enum target_waitkind, struct target_waitstatus):
19661 Delete.
19662 (win32_wait): Adjust.
19663
2bd7c093
PA
196642009-04-01 Pedro Alves <pedro@codesourcery.com>
19665
19666 * target.h (struct thread_resume): Delete leave_stopped member.
19667 (struct target_ops): Add a `n' argument to the `resume' callback.
19668 * server.c (start_inferior): Adjust.
19669 (handle_v_cont, myresume): Adjust.
19670 * linux-low.c (check_removed_breakpoint): Adjust to resume
19671 interface change, and to removed leave_stopped field.
19672 (resume_ptr): Delete.
19673 (struct thread_resume_array): New.
19674 (linux_set_resume_request): Add new `arg' parameter. Adjust to
19675 resume interface change.
19676 (linux_continue_one_thread, linux_queue_one_thread)
19677 (resume_status_pending_p): Check if the resume field is NULL
19678 instead of checking the leave_stopped member.
19679 (linux_resume): Adjust to the target resume interface change.
19680 * spu-low.c (spu_resume): Adjust to the target resume interface
19681 change.
19682 * win32-low.c (win32_detach, win32_resume): Ditto.
19683
c35fafde
PA
196842009-04-01 Pedro Alves <pedro@codesourcery.com>
19685
19686 * linux-low.c (linux_wait_for_event): Don't clear the `stepping'
19687 flag.
19688 (wait_for_sigstop): Don't leave a finished single-step SIGTRAP
19689 pending.
19690 (linux_continue_one_thread): Only preserve the stepping flag if
19691 there's a pending breakpoint.
19692
0a59d50b
PA
196932009-03-31 Pedro Alves <pedro@codesourcery.com>
19694
19695 * server.c (main): After the inferior having exited, call
19696 remote_close before exiting gdbserver.
19697
f04c6d38
TJB
196982009-03-25 Thiago Jung Bauermann <bauerman@br.ibm.com>
19699
19700 Fix size of FPSCR in Power 7 processors.
19701 * linux-ppc-low.c (PPC_FEATURE_ARCH_2_05): Remove #define.
19702 (PPC_FEATURE_HAS_DFP): New #define.
19703 (ppc_arch_setup): Check for DFP feature instead of ISA 2.05 to decide on
19704 size of the FPSCR.
19705
78e5cee6
PA
197062009-03-23 Pedro Alves <pedro@codesourcery.com>
19707
19708 * server.c (handle_query) Whitespace and formatting.
19709
1b3f6016
PA
197102009-03-22 Pedro Alves <pedro@codesourcery.com>
19711
19712 * i387-fp.c, linux-arm-low.c, linux-cris-low.c,
19713 linux-crisv32-low.c, linux-i386-low.c, linux-low.c,
19714 linux-mips-low.c, linux-s390-low.c, linux-sparc-low.c,
19715 linux-x86-64-low.c, linux-xtensa-low.c, proc-service.c,
19716 regcache.c, remote-utils.c, server.c, spu-low.c, target.h,
19717 thread-db.c, win32-low.c, xtensa-xtregs.c, gdbreplay.c,
19718 Makefile.in, configure.ac: Fix whitespace throughout.
19719 * configure: Regenerate.
19720
a07b2135
PA
197212009-03-22 Pedro Alves <pedro@codesourcery.com>
19722
19723 * inferiors.c (find_inferior): Make it safe for the callback
19724 function to delete the currently iterated inferior.
19725
67cc2626
PA
197262009-03-22 Pedro Alves <pedro@codesourcery.com>
19727
19728 * Makefile.in (linuw_low_h): Move higher.
19729 (thread-db.o): Depend on $(linux_low_h).
19730
54a0b537
PA
197312009-03-17 Pedro Alves <pedro@codesourcery.com>
19732
19733 Rename "process" to "lwp" throughout.
19734
19735 * linux-low.c (all_processes): Rename to...
19736 (all_lwps): ... this.
19737 (inferior_pid, handle_extended_wait, get_stop_pc): Adjust.
19738 (add_process): Rename to ...
19739 (add_lwp): ... this. Adjust.
19740 (linux_create_inferior): Adjust.
19741 (linux_attach_lwp): Adjust.
19742 (linux_attach): Adjust.
19743 (linux_kill_one_process): Rename to ...
19744 (linux_kill_one_lwp): ... this. Adjust.
19745 (linux_kill): Adjust.
19746 (linux_detach_one_process): Rename to ...
19747 (linux_detach_one_lwp): ... this. Adjust.
19748 (linux_detach): Adjust.
19749 (check_removed_breakpoint): Adjust.
19750 (status_pending_p): Adjust.
19751 (linux_wait_for_process): Rename to ...
19752 (linux_wait_for_lwp): ... this. Adjust.
19753 (linux_wait_for_event): Adjust.
19754 (send_sigstop): Adjust.
19755 (wait_for_sigstop): Adjust.
19756 (stop_all_processes): Rename to ...
19757 (stop_all_lwps): ... this.
19758 (linux_resume_one_process): Rename to ...
19759 (linux_resume_one_lwp): ... this. Adjust.
19760 (linux_set_resume_request, linux_continue_one_thread)
19761 (linux_queue_one_thread, resume_status_pending_p)
19762 (usr_store_inferior_registers, regsets_store_inferior_registers)
19763 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
19764 Adjust.
19765 * linux-low.h (get_process): Rename to ...
19766 (get_lwp): ... this. Adjust.
19767 (get_thread_process): Rename to ...
19768 (get_thread_lwp): ... this. Adjust.
19769 (get_process_thread): Rename to ...
19770 (get_lwp_thread): ... this. Adjust.
19771 (struct process_info): Rename to ...
19772 (struct lwp_info): ... this.
19773 (all_processes): Rename to ...
19774 (all_lwps): ... this.
19775 * proc-service.c (ps_lgetregs): Adjust.
19776 * thread-db.c (thread_db_create_event, find_one_thread)
19777 (maybe_attach_thread, thread_db_get_tls_address): Adjust.
19778
0b16c5cf
PA
197792009-03-14 Pedro Alves <pedro@codesourcery.com>
19780
19781 * server.c (handle_query): Handle "qAttached".
19782
32de4b9d
NS
197832009-03-13 Nathan Sidwell <nathan@codesourcery.com>
19784
19785 * Makefile.in, hostio-errno.c, errno.c, xtensa-xtregs.c: Change to
19786 GPLv3, update license URL.
19787
2aecd87f
DE
197882009-03-01 Doug Evans <dje@google.com>
19789
93efd302 19790 * Makefile.in (INCLUDE_CFLAGS): Add -I$(srcdir)/../common.
2aecd87f
DE
19791 (server_h): Add gdb_signals.h.
19792 (signals.o): Update.
19793 * server.h (target_signal_from_host,target_signal_to_host_p)
19794 (target_signal_to_host,target_signal_to_name): Moved to gdb_signals.h.
19795
86b1f9c5
PM
197962009-02-14 Pierre Muller <muller@ics.u-strasbg.fr>
19797
19798 * remote-utils.c (getpkt): Also generate remote-debug
19799 information if noack_mode is set.
19800
4aa995e1
PA
198012009-02-06 Pedro Alves <pedro@codesourcery.com>
19802
19803 * server.c (handle_query): Report qXfer:siginfo:read and
19804 qXfer:siginfo:write as supported and handle them.
19805 * target.h (struct target_ops) <qxfer_siginfo>: New field.
19806 * linux-low.c (linux_xfer_siginfo): New.
19807 (linux_target_ops): Set it.
19808
62709adf
PA
198092009-01-26 Pedro Alves <pedro@codesourcery.com>
19810
19811 * server.c (gdbserver_usage): Mention --remote-debug.
19812 (main): Accept '--remote-debug' switch.
19813
aef93bd7
DE
198142009-01-18 Doug Evans <dje@google.com>
19815
19816 * regcache.c (new_register_cache): No need to check result of xcalloc.
19817 * server.c (handle_search_memory): Back out calls to xmalloc,
19818 result is checked and error is returned to user upon failure.
19819 (handle_query): Ditto. Add more checks for result of malloc.
19820 (handle_v_cont): Check result of malloc, report error back to
19821 user upon failure.
19822 (handle_v_run): Ditto. Call freeargv.
19823 * server.h (freeargv): Declare.
19824 * utils.c (freeargv): New fn.
19825
54363045
DE
198262009-01-15 Doug Evans <dje@google.com>
19827
f626972c
DE
19828 * gdbreplay.c (perror_with_name): Make arg const char *.
19829 * server.h (target_signal_to_name): Make return type const char *.
0842e787 19830 * thread-db.c (thread_db_err_str): Make return type const char *.
f626972c 19831 * utils.c (perror_with_name): Make arg const char *.
54363045 19832
18aae699
PA
198332009-01-14 Pedro Alves <pedro@codesourcery.com>
19834
19835 * win32-low.c (get_child_debug_event): Issue a final DBG_CONTINUE
19836 when handling a EXIT_PROCESS_DEBUG_EVENT.
19837
ff703abe
JB
198382009-01-06 Joel Brobecker <brobecker@adacore.com>
19839
19840 * gdbreplay.c (gdbreplay_version): Update copyright year.
19841 * server.c (gdbserver_version): Likewise.
19842
f21cc1a2 198432009-01-05 Doug Evans <dje@google.com>
0e21c1ec
DE
19844
19845 * linux-low.c (linux_attach_lwp): Add some comments/fixmes.
f21cc1a2 19846 (handle_extended_wait): Improve comment.
0e21c1ec 19847
bca929d3
DE
198482008-12-13 Doug Evans <dje@google.com>
19849
19850 * utils.c (xmalloc,xcalloc,xstrdup): New fns.
19851 * server.h (ATTR_MALLOC): New macro.
19852 (xmalloc,xcalloc,xstrdup): Declare.
19853 * hostio.c: Replace malloc,calloc,strdup with xmalloc,xcalloc,xstrdup.
19854 * inferiors.c: Ditto.
19855 * linux-low.c: Ditto.
19856 * mem-break.c: Ditto.
19857 * regcache.c: Ditto.
19858 * remote-utils.c: Ditto.
19859 * server.c: Ditto.
19860 * target.c: Ditto.
19861 * win32-low.c: Ditto.
19862
97438e3f
DE
198632008-12-12 Doug Evans <dje@google.com>
19864
896c7fbb
DE
19865 * linux-low.c (linux_wait_for_process): Don't clobber current_inferior
19866 in debugging printf.
19867
97438e3f
DE
19868 * linux-low.c (handle_extended_wait): Simplify, use my_waitpid.
19869
e3b886f8
DE
198702008-12-09 Doug Evans <dje@google.com>
19871
19872 * linux-low.h (struct process_info): Delete member tid, unused.
19873 * thread-db.c (find_one_thread): Update.
19874 (maybe_attach_thread): Update.
19875
07e059b5
VP
198762008-12-02 Pedro Alves <pedro@codesourcery.com>
19877
889bf7c5
PA
19878 * target.h (struct target_ops): Add qxfer_osdata member.
19879 * linux-low.c: Include ctype.h and pwd.h and sys/types.h
19880 and dirent.h.
19881 (linux_qxfer_osdata): New functions.
19882 (linux_target_ops): Register linux_qxfer_osdata as qxfer_osdata
19883 callback.
19884 * server.c (handle_query): Handle "qXfer:osdata:read:".
19885 * remote-utils.c (buffer_grow, buffer_free, buffer_init, buffer_finish)
19886 (buffer_xml_printf): New functions.
19887 * server.h (struct buffer): New.
19888 (buffer_grow_str, buffer_grow_str0): New macros.
19889 (buffer_grow, buffer_free, buffer_init, buffer_finish)
19890 (buffer_xml_printf): Declare.
07e059b5 19891
4cab47ab
DE
198922008-11-24 Doug Evans <dje@google.com>
19893
19894 * Makefile.in (VERSION,DIST,LINT,LINTFLAGS): Delete, unused.
19895
f142445f
DJ
198962008-11-24 Daniel Jacobowitz <dan@codesourcery.com>
19897
19898 * server.c (handle_v_run): Always use the supplied argument list.
19899
d0107bb6 199002008-11-19 Bob Wilson <bob.wilson@acm.org>
889bf7c5 19901
d0107bb6
BW
19902 * xtensa-xtregs.c (XTENSA_ELF_XTREG_SIZE): Change to 4.
19903 (xtensa_regmap_table): Add entry for scompare1.
889bf7c5 19904
2c4ad781
TJB
199052008-11-18 Thiago Jung Bauermann <bauerman@br.ibm.com>
19906
19907 * Makefile.in (powerpc-isa205-32l.o, powerpc-isa205-32l.c,
19908 powerpc-isa205-altivec32l.o, powerpc-isa205-altivec32l.c,
19909 powerpc-isa205-vsx32l.o, powerpc-isa205-vsx32l.c,
19910 powerpc-isa205-64l.o, powerpc-isa205-64l.c,
19911 powerpc-isa205-altivec64l.o, powerpc-isa205-altivec64l.c,
19912 powerpc-isa205-vsx64l.o, powerpc-isa205-vsx64l.c): New targets.
19913 * configure.srv (powerpc*-*-linux*): Add ISA 2.05 object files and
19914 XML target descriptions.
19915 * linux-ppc-low.c (ppc_arch_setup): Init registers with 64-bit FPSCR
19916 when inferior is running on an ISA 2.05 or later processor. Add
19917 special case to return offset for full 64-bit slot of FPSCR when
19918 in 32-bits.
19919
dfb64f85
DJ
199202008-11-14 Daniel Gutson <dgutson@codesourcery.com>
19921
19922 * Makefile.in (SFILES, clean): Added sparc64 files.
19923 (reg-sparc64.o, reg-sparc64.c): New.
19924 * configure.srv (sparc*-*-linux*): New configuration.
19925 * linux-low.c (regsets_fetch_inferior_registers): Swap ptrace
19926 syscall arguments for SPARC.
19927 (regsets_store_inferior_registers): Likewise.
19928 * linux-sparc-low.c: New file.
19929
66b6e1dd
DE
199302008-10-21 Doug Evans <dje@google.com>
19931
19932 * Makefile.in (BFD_DIR,BFD,BFD_SRC,BFD_CFLAGS): Delete.
19933 (READLINE_DIR,READLINE_DEP): Delete.
19934 (INTERNAL_CFLAGS): Update.
19935 (LINTFLAGS): Update.
19936
9b710a42
PA
199372008-10-10 Pedro Alves <pedro@codesourcery.com>
19938
19939 * server.c (handle_v_run): If GDB didn't specify an argv, use the
19940 whole argv from the last run, not just argv[0].
19941
5822d809
PA
199422008-09-08 Pedro Alves <pedro@codesourcery.com>
19943
19944 * regcache.c (new_register_cache): Return NULL if the register
19945 cache size isn't known yet.
19946 (free_register_cache): Avoid dereferencing a NULL regcache.
19947
74aac56f
DJ
199482008-09-04 Daniel Jacobowitz <dan@codesourcery.com>
19949
19950 * configure.srv: Merge MIPS and MIPS64.
19951
400b20f5
MR
199522008-08-24 Maciej W. Rozycki <macro@linux-mips.org>
19953
19954 * Makefile.in (uninstall): Apply $(EXEEXT) too.
19955
677c5bb1
LM
199562008-08-18 Luis Machado <luisgpm@br.ibm.com>
19957
19958 * Makefile.in: Add required vsx dependencies.
19959
19960 * linux-ppc-low: Define PPC_FEATURE_HAS_VSX.
19961 Declare init_registers_powerpc_vsx32l.
19962 Declare init_registers_powerpc_vsx64l.
19963 Define PTRACE_GETVSXREGS and PTRACE_SETVSXREGS.
19964 (ppc_arch_setup): Check for VSX in hwcap.
19965 (ppc_fill_vsxregset): New function.
19966 (ppc_store_vsxregset): New function.
19967 Add new VSX entry in regset_info target_regsets.
19968
19969 * configure.srv: Add new VSX dependencies.
19970
a6f3e723
SL
199712008-08-12 Pedro Alves <pedro@codesourcery.com>
19972
19973 * remote-utils.c (noack_mode, transport_is_reliable): New globals.
19974 (remote_open): Set or clear transport_is_reliable.
19975 (putpkt_binary): Don't expect acks in noack mode.
19976 (getpkt): Don't send ack/nac in noack mode.
19977 * server.c (handle_general_set): Handle QStartNoAckMode.
19978 (handle_query): If connected by tcp pass QStartNoAckMode+ in
19979 qSupported.
19980 (main): Reset noack_mode on every connection.
19981 * server.h (noack_mode): Declare.
19982
a417dc56
RW
199832008-08-07 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
19984
19985 * Makefile.in (GDBREPLAY_OBS): New variable.
19986 (gdbreplay$(EXEEXT)): Use it to avoid unportable $^.
19987
3221518c
UW
199882008-08-05 Ulrich Weigand <uweigand@de.ibm.com>
19989 Daniel Jacobowitz <dan@codesourcery.com>
19990
19991 * linux-low.c (linux_resume_one_process): Ignore ESRCH.
19992 (usr_store_inferior_registers): Likewise.
19993 (regsets_store_inferior_registers): Likewise.
19994
ec56be1b
PA
199952008-07-31 Rolf Jansen <rj@surtec.com>
19996 Pedro Alves <pedro@codesourcery.com>
19997
19998 * configure.ac: Check for memmem declaration.
19999 * server.c [HAVE_MALLOC_H]: Include malloc.h.
20000 (disable_packet_vCont, disable_packet_Tthread, disable_packet_qC)
20001 (disable_packet_qfThreadInfo): Unconditionally compile.
20002 * server.h [!HAVE_DECL_MEMMEM]: Declare memmem.
20003 * configure, config.in: Regenerate.
20004
2fe5e3ff
DE
200052008-07-28 Doug Kwan <dougkwan@google.com>
20006
20007 * linux-low.c (sys/dir.h, sys/user.h): Remove includes.
20008 (linux_write_memory): Remove declaration of errno.
20009
836acd6d
UW
200102008-07-12 Ulrich Weigand <uweigand@de.ibm.com>
20011
20012 * linux-low.c (handle_extended_wait): Do not use "status"
20013 variable uninitialized.
20014
aeba519e
PA
200152008-07-07 Pedro Alves <pedro@codesourcery.com>
20016
20017 * server.c (handle_v_attach): Inhibit reporting dll changes.
20018
db42f210
PA
200192008-06-27 Pedro Alves <pedro@codesourcery.com>
20020
20021 * remote-utils.c (prepare_resume_reply): If requested, don't
20022 output "thread:TID" in the T stop reply.
20023
20024 * server.c (disable_packet_vCont, disable_packet_Tthread)
20025 (disable_packet_qC, disable_packet_qfThreadInfo): New globals.
20026 (handle_query): If requested, disable support for qC, qfThreadInfo
20027 and qsThreadInfo.
20028 (handle_v_requests): If requested, disable support for vCont.
20029 (gdbserver_show_disableable): New.
20030 (main): Handle --disable-packet and --disable-packet=LIST.
20031
20032 * server.h (disable_packet_vCont, disable_packet_Tthread)
20033 (disable_packet_qC, disable_packet_qfThreadInfo): Declare.
20034
8e4c5421
CD
200352008-06-20 Carlos O'Donell <carlos@codesourcery.com>
20036
20037 * server.c (gdbserver_usage): Mention --version.
20038
6e23a804
DJ
200392008-06-06 Daniel Jacobowitz <dan@codesourcery.com>
20040
20041 * Makefile.in (gdbreplay.o): New rule.
20042
90aa6a40
JM
200432008-06-06 Joseph Myers <joseph@codesourcery.com>
20044
20045 * gdbreplay.c (gdbreplay_version): Say gdbreplay in version
20046 message, not gdbserver.
20047
c16158bc 200482008-06-05 Vladimir Prus <vladimir@codesourcery.com>
889bf7c5
PA
20049 Nathan Sidwell <nathan@codesourcery.com>
20050 Joseph Myers <joseph@codesourcery.com>
c16158bc
JM
20051
20052 * acinclude.m4: Include ../../config/acx.m4.
20053 * configure.ac: Use ACX_PKGVERSION and ACX_BUGURL.
20054 * configure, config.in: Regenerate.
20055 * Makefile.in (gdbreplay$(EXEEXT)): Add version.o.
20056 * server.c (gdbserver_version): Print PKGVERSION.
20057 (gdbsrever_usage): Add stream parameter. Print REPORT_BUGS_TO.
20058 (main): Adjust gdbserver_usage calls.
20059 * gdbreplay.c (version, host_name): Add declarations.
20060 (gdbreplay_version, gdbreplay_usage): New.
20061 (main): Accept --version and --help options.
20062
aeb75bf5
DJ
200632008-06-04 Daniel Jacobowitz <dan@codesourcery.com>
20064
20065 * linux-arm-low.c (thumb_breakpoint, thumb_breakpoint_len): New.
20066 (arm_breakpoint_at): Handle Thumb.
20067 (the_low_target): Add comment.
20068
76b233dd
UW
200692008-05-29 Ulrich Weigand <uweigand@de.ibm.com>
20070
20071 * linux-ppc-low.c (ppc_collect_ptrace_register): Clear buffer.
20072
08388c79
DE
200732008-05-09 Doug Evans <dje@google.com>
20074
a3c83fae
DE
20075 * server.h (decode_search_memory_packet): Declare.
20076 * remote-utils.c (decode_search_memory_packet): New fn.
20077 * server.c (handle_search_memory_1): New fn.
08388c79
DE
20078 (handle_search_memory): New fn.
20079 (handle_query): Process qSearch:memory packets.
20080
bb9c3d36
UW
200812008-05-08 Ulrich Weigand <uweigand@de.ibm.com>
20082
20083 * regcache.c (registers_length): Remove.
20084 (set_register_cache): Verify that PBUFSIZ is large enough to hold a
20085 full register packet.
20086 * regcache.h (registers_length): Remove prototype.
20087 * server.h (PBUFSIZ): Define to 16384.
20088
7284e1be
UW
200892008-05-03 Ulrich Weigand <uweigand@de.ibm.com>
20090
20091 * configure.srv (powerpc*-*-linux*): Set srv_regobj to
20092 powerpc-32l.o, powerpc-altivec32l.o, powerpc-e500l.o,
20093 powerpc-64l.o, and powerpc-altivec64l.o.
20094 Remove rs6000/powerpc-32.xml, rs6000/powerpc-64.xml, and
20095 rs6000/powerpc-e500.xml; add rs6000/powerpc-32l.xml,
20096 rs6000/powerpc-altivec32l.xml, rs6000/powerpc-e500l.xml,
20097 rs6000/powerpc-64l.xml, rs6000/powerpc-altivec64l.xml,
20098 rs6000/power-linux.xml, and rs6000/power64-linux.xml
20099 to srv_xmlfiles.
20100
20101 * Makefile.in (reg-ppc.o, reg-ppc.c): Remove, replace by ...
20102 (powerpc-32l.o, powerpc-32l.c): ... these new rules.
20103 (powerpc-32.o, powerpc-32.c): Remove, replace by ...
20104 (powerpc-altivec32l.o, powerpc-altivec32l.c): ... these new rules.
20105 (powerpc-e500.o, powerpc-e500.c): Remove, replace by ...
20106 (powerpc-e500l.o, powerpc-e500l.c): ... these new rules.
20107 (reg-ppc64.o, reg-ppc64.c): Remove, replace by ...
20108 (powerpc-64l.o, powerpc-64l.c): ... these new rules.
20109 (powerpc-64.o, powerpc-64.c): Remove, replace by ...
20110 (powerpc-altivec64l.o, powerpc-altivec64l.c): ... these new rules.
20111 (clean): Update.
20112
20113 * linux-ppc-low.c (init_registers_ppc): Remove, replace by ...
20114 (init_registers_powerpc_32l): ... this new prototype.
20115 (init_registers_powerpc_32): Remove, replace by ...
20116 (init_registers_powerpc_altivec32l): ... this new prototype.
20117 (init_registers_powerpc_e500): Remove, replace by ...
20118 (init_registers_powerpc_e500l): ... this new prototype.
20119 (init_registers_ppc64): Remove, replace by ...
20120 (init_registers_powerpc_64l): ... this new prototype.
20121 (init_registers_powerpc_64): Remove, replace by ...
20122 (init_registers_powerpc_altivec64l): ... this new prototype.
20123 (ppc_num_regs): Set to 73.
20124 (PT_ORIG_R3, PT_TRAP): Define if necessary.
20125 (ppc_regmap, ppc_regmap_e500): Add values for orig_r3 and trap.
20126 (ppc_cannot_store_register): Handle orig_r3 and trap.
20127 (ppc_arch_setup): Update init_registers_... calls.
20128 (ppc_fill_gregset): Handle orig_r3 and trap.
20129
20130 * inferiors.c (clear_inferiors): Reset current_inferior.
20131
fdc59709
PB
201322008-04-23 Paolo Bonzini <bonzini@gnu.org>
20133
889bf7c5
PA
20134 * acinclude.m4: Add override.m4.
20135 * configure: Regenerate.
fdc59709 20136
c9b2f845
UW
201372008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
20138
20139 * linux-ppc-low.c (ppc_arch_setup): Reset ppc_hwcap after the
20140 initial call to init_register_ppc64.
20141
550512b8
UW
201422008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
20143
43aaf8b6
PA
20144 * configure.srv (powerpc64-*-linux*, powerpc-*-linux*): Merge into
20145 single powerpc*-*-linux* case.
550512b8
UW
20146 (s390-*-linux*, s390x-*-linux*): Merge into single s390*-*-linux* case.
20147
b6430ec3
UW
201482008-04-17 Ulrich Weigand <uweigand@de.ibm.com>
20149
20150 * configure.srv [powerpc64-*-linux*]: Remove powerpc-e500.o from
889bf7c5 20151 srv_regobj. Remove rs6000/powerpc-e500.xml and rs6000/power-spe.xml
b6430ec3
UW
20152 from reg_xmlfiles.
20153 * linux-ppc-low.c: Include <elf.h>.
20154 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Define.
20155 (ppc_hwcap): New global variable.
20156 (ppc_regmap): Remove __SPE__ #ifdef sections.
20157 (ppc_regmap_e500): New global variable.
20158 (ppc_cannot_store_register): Update __SPE__ special case.
20159 (ppc_get_hwcap): New function.
20160 (ppc_arch_setup): Use it to determine whether inferior supports
20161 AltiVec or SPE registers. Set the_low_target.regmap if appropriate.
20162 (ppc_fill_vrregset, ppc_store_vrregset): Define unconditionally.
20163 Do not access registers if target does not support AltiVec.
20164 (ppc_fill_evrregset, ppc_store_evrregset): Define unconditionally.
20165 Do not access registers if target does not support SPE.
20166 (target_regsets): Unconditionally include AltiVec and SPE regsets.
20167
52fa2412
UW
201682008-04-17 Daniel Jacobowitz <dan@codesourcery.com>
20169
20170 * linux-low.c (disabled_regsets, num_regsets): New.
20171 (use_regsets_p): Delete.
20172 (linux_wait_for_process): Clear disabled_regsets.
20173 (regsets_fetch_inferior_registers): Check and set it.
20174 (regsets_store_inferior_registers): Likewise.
20175 (linux_fetch_registers, linux_store_registers): Do not use
20176 use_regsets_p.
20177 (initialize_low): Allocate disabled_regsets.
20178
e28b3332
DJ
201792008-04-14 Daniel Jacobowitz <dan@codesourcery.com>
20180
20181 * Makefile.in (LIBOBJS): New.
20182 (OBS): Use LIBOBJS.
20183 (memmem.o): New rule.
20184 * configure.ac: Use AC_CONFIG_LIBOBJ_DIR and check for memmem.
20185 * configure: Regenerated.
20186
4536995d
UW
201872008-04-04 Ulrich Weigand <uweigand@de.ibm.com>
20188
20189 * server.c (handle_query): Never return "unsupported" for
20190 qXfer:features:read queries.
20191
221c031f
UW
201922008-03-27 Ulrich Weigand <uweigand@de.ibm.com>
20193
20194 * server.c (get_features_xml): Fix inverted condition.
20195 (handle_query): Always support qXfer:feature:read.
20196
ccd213ac
DJ
201972008-03-10 Daniel Jacobowitz <dan@codesourcery.com>
20198
20199 * server.c (wrapper_argv): New.
20200 (start_inferior): Handle wrapper_argv. If set, expect an extra
20201 trap.
20202 (gdbserver_usage): Document --wrapper.
20203 (main): Parse --wrapper.
20204
6fe305f7
UW
202052008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
20206
20207 * configure.srv [powerpc64-*-linux*]: Add all files mentioned for
20208 powerpc-*-linux* to srv_regobj and reg_xmlfiles.
20209 * linux-ppc-low.c (ppc_get_pc): Support bi-arch operation.
20210 (ppc_set_pc): Likewise.
20211 (ppc_arch_setup): New function.
20212 (ppc_fill_gregset): Call ppc_collect_ptrace_register instead
20213 of collect_register.
889bf7c5 20214 (the_low_target): Use ppc_arch_setup as arch_setup initializer.
6fe305f7 20215
5b0a002e
UW
202162008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
20217
20218 * configure.srv [powerpc64-*-linux*]: Use linux-ppc-low.o
20219 instead of linux-ppc64-low.o.
20220 * linux-ppc64-low.c: Remove file.
20221 * Makefile.in (SFILES): Remove linux-ppc64-low.c.
20222 (linux-ppc64-low.o): Remove rule.
20223
20224 * linux-ppc-low.c (init_registers_ppc64): Add prototype.
20225 (init_registers_powerpc_64): Likewise.
20226 (ppc_regmap): Conditionally define depending on __powerpc64__.
20227 (ppc_cannot_store_register): Do not special-case "fpscr" when
20228 compiled on __powerpc64__.
20229 (ppc_collect_ptrace_register): New function.
20230 (ppc_supply_ptrace_register): New function.
20231 (ppc_breakpoint): Change type to "unsigned int".
20232 (ppc_breakpoint_at): Change type of "insn" to "unsigned int".
20233 (the_low_target): Conditionally provide initializers for the
889bf7c5 20234 arch_setup member depending on __powerpc64__. Install
5b0a002e
UW
20235 collect_ptrace_register and supply_ptrace_register members.
20236
9b4b61c8
UW
202372008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
20238
20239 * regcache.h (gdbserver_xmltarget): Add extern declaration.
20240 * server.c (gdbserver_xmltarget): Define.
20241 (get_features_xml): Use it to replace "target.xml" and arch_string.
20242
20243 * configure.srv: Remove srv_xmltarget. Add XML files that were
20244 mentioned there to srv_xmlfiles instead. Remove conditional tests
20245 on gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe; set
20246 srv_xmlfiles and srv_regobj to include all possible choices.
20247 * configure.ac (srv_xmltarget): Remove.
20248 (srv_xmlfiles): Do not add "target.xml".
20249 (gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe): Remove
20250 checks for supplementary target information.
20251 * configure: Regenerate.
20252 * Makefile.in (XML_TARGET): Remove.
20253 (target.xml): Remove rule.
20254 (clean): Do not clean up target.xml.
20255 (.PRECIOUS): Do not mention target.xml.
20256
20257 * target.h (struct target_ops): Remove arch_string member.
20258 * linux-low.c (linux_arch_string): Remove.
20259 (linux_target_ops): Remove arch_string initializer.
20260 * linux-low.h (struct linux_target_ops): Remove arch_string member.
20261 * linux-i386-low.c (the_low_target): Remove arch_string initializer.
20262 * linux-x86-64-low.c (the_low_target): Remove arch_string initializer.
20263 * spu-low.c (spu_arch_string): Remove.
20264 (spu_target_ops): Remove arch_string initializer.
20265 * win32-low.c (win32_arch_string): Remove.
20266 (win32_target_ops): Remove arch_string initializer.
20267 * win32-low.h (struct win32_target_ops): Remove arch_string member.
20268 * win32-arm-low.c (the_low_target): Remove arch_string initializer.
20269 * win32-i368-low.c (the_low_target): Remove arch_string initializer.
20270
ee1a7ae4
UW
202712008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
20272
20273 * linux-low.h (struct linux_target_ops): Replace left_pad_xfer field
20274 by collect_ptrace_register and supply_ptrace_register hooks.
20275 * linux-low.c (fetch_register): Use supply_ptrace_register callback
20276 instead of checking for the_low_target.left_pad_xfer.
20277 (usr_store_inferior_registers): Use collect_ptrace_register callback
20278 instead of checking for the_low_target.left_pad_xfer.
20279
20280 * linux-s390-low.c (s390_collect_ptrace_register): New function.
20281 (s390_supply_ptrace_register): Likewise.
20282 (s390_fill_gregset): Call s390_collect_ptrace_register.
20283 (the_low_target): Update.
20284
20285 * linux-ppc64-low.c (ppc_collect_ptrace_register): New function.
20286 (ppc_supply_ptrace_register): Likewise.
20287 (the_low_target): Update.
20288
20289 * linux-i386-low.c (the_low_target): Update.
20290 * linux-x86-64-low.c (the_low_target): Update.
20291
d61ddec4
UW
202922008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
20293
20294 * configure.srv [s390x-*-linux*]: Set srv_regobj to include both
20295 reg-s390.o and reg-s390x.o.
20296
20297 * linux-low.c (new_inferior): New global variable.
20298 (linux_create_inferior, linux_attach): Set it.
20299 (linux_wait_for_process): Call the_low_target.arch_setup after the
20300 target has stopped for the first time.
20301 (initialize_low): Do not call the_low_target.arch_setup.
20302
20303 * linux-s390-low.c (s390_get_pc): Support bi-arch operation.
20304 (s390_set_pc): Likewise.
20305 (s390_arch_setup): New function.
20306 (the_low_target): Use s390_arch_setup as arch_setup routine.
20307
20308 * regcache.c (realloc_register_cache): New function.
20309 (set_register_cache): Call it for each existing regcache.
20310
d05b4ac3
UW
203112008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
20312
20313 * server.h (init_registers): Remove prototype.
20314
20315 * linux-low.h (struct linux_target_ops): Add arch_setup field.
20316 * linux-low.c (initialize_low): Call the_low_target.arch_setup ()
20317 instead of init_registers ().
20318 * linux-arm-low.c (init_registers_arm): Add prototype.
20319 (init_registers_arm_with_iwmmxt): Likewise.
20320 (the_low_target): Add initializer for arch_setup field.
20321 * linux-cris-low.c (init_registers_cris): Add prototype.
20322 (the_low_target): Add initializer for arch_setup field.
20323 * linux-crisv32-low.c (init_registers_crisv32): Add prototype.
20324 (the_low_target): Add initializer for arch_setup field.
20325 * linux-i386-low.c (init_registers_i386_linux): Add prototype.
20326 (the_low_target): Add initializer for arch_setup field.
20327 * linux-ia64-low.c (init_registers_ia64): Add prototype.
20328 (the_low_target): Add initializer for arch_setup field.
20329 * linux-m32r-low.c (init_registers_m32r): Add prototype.
20330 (the_low_target): Add initializer for arch_setup field.
20331 * linux-m68k-low.c (init_registers_m68k): Add prototype.
20332 (the_low_target): Add initializer for arch_setup field.
20333 * linux-mips-low.c (init_registers_mips_linux): Add prototype.
20334 (init_registers_mips64_linux): Likewise.
20335 (the_low_target): Add initializer for arch_setup field.
20336 * linux-ppc-low.c (init_registers_ppc): Add prototype.
20337 (init_registers_powerpc_32, init_registers_powerpc_e500): Likewise.
20338 (the_low_target): Add initializer for arch_setup field.
20339 * linux-ppc64-low.c (init_registers_ppc64): Add prototype.
20340 (init_registers_powerpc_64): Likewise.
20341 (the_low_target): Add initializer for arch_setup field.
20342 * linux-s390-low.c (init_registers_s390): Add prototype.
20343 (init_registers_s390x): Likewise.
20344 (the_low_target): Add initializer for arch_setup field.
20345 * linux-sh-low.c (init_registers_sh): Add prototype.
20346 (the_low_target): Add initializer for arch_setup field.
20347 * linux-x86-64-low.c (init_registers_x86_64_linux): Add prototype.
20348 (the_low_target): Add initializer for arch_setup field.
20349 * linux-xtensa-low.c (init_registers_xtensa): Add prototype.
20350 (the_low_target): Add initializer for arch_setup field.
20351
20352 * win32-low.h (struct win32_target_ops): Add arch_setup field.
20353 * win32-low.c (initialize_low): Call the_low_target.arch_setup ()
20354 instead of init_registers ().
20355 * win32-arm-low.c (init_registers_arm): Add prototype.
20356 (the_low_target): Add initializer for arch_setup field.
20357 * win32-i386-low.c (init_registers_i386): Add prototype.
20358 (the_low_target): Add initializer for arch_setup field.
20359
20360 * spu-low.c (init_registers_spu): Add prototype.
20361 (initialize_low): Call initialie_registers_spu () instead of
20362 initialize_registers ().
20363
fd96d250
PA
203642008-02-19 Pedro Alves <pedro@codesourcery.com>
20365
20366 * server.c (handle_v_requests): When handling the vRun and vAttach
20367 packets, if already debugging a process, don't kill it. Return an
20368 error instead.
20369
d41b6bb4
DJ
203702008-02-17 Daniel Jacobowitz <dan@codesourcery.com>
20371
20372 * server.c (handle_query): Correct length check.
20373
5ac588cf
PA
203742008-02-14 Pedro Alves <pedro_alves@portugalmail.pt>
20375
20376 * win32-low.c (do_initial_child_stuff): Add process handle
20377 parameter. Set current_process_handle and current_process_id from the
20378 parameters. Clear globals.
20379 (win32_create_inferior): Don't set current_process_handle and
20380 current_process_id here. Instead pass them on the call to
20381 do_initial_child_stuff.
20382 (win32_attach): Likewise.
20383 (win32_clear_inferiors): New.
20384 (win32_kill): Don't close the current process handle or the
20385 current thread handle here. Instead call win32_clear_inferiors.
20386 (win32_detach): Don't open a new handle to the process. Call
20387 win32_clear_inferiors.
20388 (win32_join): Don't rely on current_process_handle; open a new
20389 handle using the process id.
20390 (win32_wait): Call win32_clear_inferiors when the inferior process
20391 has exited.
20392
ecd7ecbc
DJ
203932008-02-14 Daniel Jacobowitz <dan@codesourcery.com>
20394
20395 * server.c (monitor_show_help): Add "exit".
20396
1525d545
MG
203972008-02-11 Maxim Grigoriev <maxim2405@gmail.com>
20398
ecd7ecbc 20399 * Makefile.in (SFILES): Add linux-xtensa-low.c.
1525d545
MG
20400 (clean): Add reg-xtensa.c.
20401 (linux-xtensa-low.o, reg-xtensa.o, reg-xtensa.c): New dependencies.
ecd7ecbc
DJ
20402 * configure.srv (xtensa*-*-linux*) New target.
20403 * linux-xtensa-low.c: New.
20404 * xtensa-xtregs.c: New.
1525d545 20405
59a016f0
PA
204062008-02-01 Pedro Alves <pedro_alves@portugalmail.pt>
20407
20408 * hostio.c: Don't include errno.h.
20409 (errno_to_fileio_errno): Move to hostio-errno.
20410 * hostio.c: (hostio_error): Remove the error parameter. Defer the
20411 error number outputting to the target->hostio_last_error callback.
20412 (hostio_packet_error): Use FILEIO_EINVAL directly.
20413 (handle_open, handle_pread, hostio_error, handle_unlink): Update
20414 calls to hostio_error.
20415 * hostio-errno.c: New.
20416 * server.h (hostio_last_error_from_errno): Declare.
20417 * target.h (target_ops): Add hostio_last_error member.
20418 * linux-low.c (linux_target_op): Register hostio_last_error_from_errno
20419 as hostio_last_error handler.
889bf7c5 20420 * spu-low.c (spu_target_ops): Likewise.
59a016f0
PA
20421 * win32-low.c [_WIN32_WCE] (win32_error_to_fileio_error)
20422 (wince_hostio_last_error): New functions.
20423 (win32_target_ops) [_WIN32_WCE]: Register wince_hostio_last_error
20424 as hostio_last_error handler.
20425 (win32_target_ops) [!_WIN32_WCE]: Register
20426 hostio_last_error_from_errno as hostio_last_error handler.
20427 * Makefile.in (SFILES): Add hostio.c and hostio-errno.c.
20428 (hostio-errno.o): New rule.
20429 * configure.ac (GDBSERVER_DEPFILES): Add $srv_hostio_err_objs.
20430 * configure.srv (srv_hostio_err_objs): New variable. Default to
20431 hostio-errno.o.
20432 (arm*-*-mingw32ce*): Set srv_hostio_err_objs to "".
20433 * configure: Regenerate.
20434
2d717e4f
DJ
204352008-01-29 Daniel Jacobowitz <dan@codesourcery.com>
20436
20437 * linux-low.c (linux_attach_lwp): Do not _exit after errors.
20438 (linux_kill, linux_detach): Clean up the process list.
20439 * remote-utils.c (remote_open): Improve port number parsing.
20440 (putpkt_binary, input_interrupt): Only send interrupts if the target
20441 is running.
20442 * server.c (extended_protocol): Make static.
20443 (attached): Define earlier.
20444 (exit_requested, response_needed, program_argv): New variables.
20445 (target_running): New.
20446 (start_inferior): Clear attached here.
20447 (attach_inferior): Set attached here.
20448 (require_running): Define.
20449 (handle_query): Use require_running and target_running. Implement
20450 "monitor exit".
20451 (handle_v_attach, handle_v_run): New.
20452 (handle_v_requests): Use require_running. Handle vAttach and vRun.
20453 (gdbserver_usage): Update.
20454 (main): Redo argument parsing. Handle --debug and --multi. Handle
20455 --attach along with other options or after the port. Save
20456 program_argv. Support no initial program. Resynchronize
20457 communication with GDB after an error. Handle "monitor exit".
20458 Use require_running and target_running. Always allow the extended
20459 protocol. Do not error out for Hc0 or Hc-1. Do not automatically
20460 restart in extended mode.
20461 * README: Refer to the GDB manual. Update --attach usage.
20462
7407e2de
AS
204632007-12-20 Andreas Schwab <schwab@suse.de>
20464
20465 * linux-low.c (STACK_SIZE): Define.
20466 (linux_tracefork_child): Use it. Use __clone2 on ia64.
20467 (linux_test_for_tracefork): Likewise.
20468
b65d95c5
DJ
204692007-12-18 Daniel Jacobowitz <dan@codesourcery.com>
20470
20471 * linux-low.c (linux_wait_for_event): Update messages. Do not
20472 reinsert auto-delete breakpoints.
20473 * mem-break.c (struct breakpoint): Change return type of handler to
20474 int.
20475 (set_breakpoint_at): Update handler type.
20476 (reinsert_breakpoint_handler): Return 1 instead of calling
20477 delete_breakpoint.
20478 (reinsert_breakpoint_by_bp): Check for the original breakpoint before
20479 setting a new one.
20480 (check_breakpoints): Delete auto-delete breakpoints and return 2.
20481 * mem-break.h (set_breakpoint_at): Update handler type.
20482 * thread-db.c (thread_db_create_event, thread_db_create_event): Update.
20483 * win32-low.c (auto_delete_breakpoint): New.
20484 (get_child_debug_event): Use it.
20485
4e799345
DJ
204862007-12-16 Daniel Jacobowitz <dan@codesourcery.com>
20487
20488 * configure.ac: Check for pread and pwrite.
20489 * hostio.c (handle_pread): Fall back to lseek and read.
20490 (handle_pwrite): Fall back to lseek and write.
20491 * config.in, configure: Regenerated.
20492
27524b67
DJ
204932007-12-07 Daniel Jacobowitz <dan@codesourcery.com>
20494
20495 * server.c (myresume): Add own_buf argument.
20496 (main): Update calls.
20497
a20d5e98
DJ
204982007-12-06 Daniel Jacobowitz <dan@codesourcery.com>
20499
20500 * linux-low.c (linux_wait, linux_resume): Do not handle async I/O.
20501 * remote-utils.c (remote_open): Do not call disable_async_io.
20502 (block_async_io): Delete.
20503 (unblock_async_io): Make static.
20504 (initialize_async_io): New.
20505 * server.c (handle_v_cont): Handle async I/O here.
20506 (myresume): Likewise. Move other common resume tasks here...
20507 (main): ... from here. Call initialize_async_io. Disable async
20508 I/O before the main loop.
20509 * server.h (initialize_async_io): Declare.
20510 (block_async_io, unblock_async_io): Delete prototypes.
20511 * spu-low.c (spu_resume, spu_wait): Do not handle async I/O here.
20512
b79d787e
DJ
205132007-12-06 Mick Davis <mickd@goanna.iinet.net.au>
20514
20515 * remote-utils.c (readchar): Allow binary data in received messages.
20516
d97903b2
PA
205172007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
20518
20519 * win32-low.c (attaching): New global.
20520 (win32_create_inferior): Clear the `attaching' global.
20521 (win32_attach): Set the `attaching' global.
20522 (get_child_debug_event) [_WIN32_WCE]: Stop the inferior when
20523 attaching. Only set a breakpoint at the entry point if not
20524 attaching.
20525
311de423
PA
205262007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
20527
20528 * server.c (main): Don't report dll events on the initial
20529 connection on attaches.
20530
6c2d16d2
PA
205312007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
20532
20533 * server.c (main): Relax numerical bases supported for the pid of
20534 the --attach command line argument.
20535
5ca906e6
PA
205362007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
20537
20538 * win32-low.c (win32_attach): Call OpenProcess before
20539 DebugActiveProcess, not after. Add last error output to error
20540 call.
20541
9c6c8194
PA
205422007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
20543
20544 * win32-low.c (win32_get_thread_context)
20545 (win32_set_thread_context): New functions.
20546 (thread_rec): Use win32_get_thread_context.
20547 (continue_one_thread, win32_resume): Use win32_set_thread_context.
20548 * win32-low.h (win32_thread_info) [_WIN32_WCE]: Add `base_context'
20549 field.
20550
4d5d1aaa
PA
205512007-12-03 Leo Zayas
20552 Pedro Alves <pedro_alves@portugalmail.pt>
20553
20554 * win32-low.c (soft_interrupt_requested, faked_breakpoint): New
20555 global variables.
20556 (child_add_thread): Minor cleanup.
20557 (child_continue): Resume artificially suspended threads before
20558 calling ContinueDebugEvent.
20559 (suspend_one_thread): New.
20560 (fake_breakpoint_event): New.
20561 (get_child_debug_event): Change return type to int. Check here if
20562 gdb sent an interrupt request. If a soft interrupt was requested,
20563 fake a breakpoint event. Return 0 if there is no event to handle,
20564 and 1 otherwise.
20565 (win32_wait): Don't check here if gdb sent an interrupt request.
20566 Ensure there is a valid event to handle.
20567 (win32_request_interrupt): Add soft interruption method as last
20568 resort.
20569
c436e841
PA
205702007-12-03 Leo Zayas
20571 Pedro Alves <pedro_alves@portugalmail.pt>
20572
20573 * win32-low.h (win32_thread_info): Add descriptions to the
20574 structure members. Replace `suspend_count' counter by a
20575 `suspended' flag.
20576 * win32-low.c (thread_rec): Update condition of when to get the
20577 context from the inferior. Rely on ContextFlags being set if it
20578 has already been retrieved. Only suspend the inferior thread if
20579 we haven't already. Warn if that fails.
20580 (continue_one_thread): s/suspend_count/suspended/. Only call
20581 ResumeThread once. Warn if that fails.
20582
e7b5fa67
PA
205832007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
20584
20585 * win32-low.c (win32_wait): Don't read from the inferior when it
20586 has already exited.
20587
a385171d
PA
205882007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
20589
20590 * Makefile.in (win32_low_h): New variable.
20591 (win32-low.o): Add dependency on $(win32_low_h).
20592 (win32-arm-low.o, win32-i386-low.o): New rules.
20593
f80c84b3
DJ
205942007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
20595
20596 * hostio.c: Correct copyright year.
20597
a6b151f1
DJ
205982007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
20599
20600 * Makefile.in (OBS): Add hostio.o.
20601 (hostio.o): New rule.
20602 * server.h (handle_vFile): Declare.
20603 * hostio.c: New file.
20604 * server.c (handle_v_requests): Take packet_len and new_packet_len
20605 for binary packets. Call handle_vFile.
20606 (main): Update call to handle_v_requests.
20607
f9387fc3
DJ
206082007-11-05 Daniel Jacobowitz <dan@codesourcery.com>
20609
20610 * linux-low.c: Include <sched.h>.
20611
51c2684e
DJ
206122007-11-01 Daniel Jacobowitz <dan@codesourcery.com>
20613
20614 * linux-low.c (linux_tracefork_grandchild): New.
20615 (linux_tracefork_child): Use clone.
20616 (linux_test_for_tracefork): Use clone; allocate and free a stack.
20617
75f83163
JB
206182007-10-31 Joel Brobecker <brobecker@adacore.com>
20619
20620 * Makefile.in: Use $(SHELL) instead of "sh" to call regdat.sh.
20621
da5898ce
DJ
206222007-10-24 Daniel Jacobowitz <dan@codesourcery.com>
20623
20624 * linux-low.c (handle_extended_wait): Handle unexpected signals.
20625
24a09b5f
DJ
206262007-10-23 Daniel Jacobowitz <dan@codesourcery.com>
20627
20628 * inferiors.c (change_inferior_id): Delete.
20629 (add_pid_to_list, pull_pid_from_list): New.
20630 * linux-low.c (PTRACE_SETOPTIONS, PTRACE_GETEVENTMSG)
20631 (PTRACE_O_TRACESYSGOOD, PTRACE_O_TRACEFORK, PTRACE_O_TRACEVFORK)
20632 (PTRACE_O_TRACECLONE, PTRACE_O_TRACEEXEC, PTRACE_O_TRACEVFORKDONE)
20633 (PTRACE_O_TRACEEXIT, PTRACE_EVENT_FORK, PTRACE_EVENT_VFORK)
20634 (PTRACE_EVENT_CLONE, PTRACE_EVENT_EXEC, PTRACE_EVENT_VFORK_DONE)
20635 (PTRACE_EVENT_EXIT, __WALL): Provide default definitions.
20636 (stopped_pids, thread_db_active, must_set_ptrace_flags): New variables.
20637 (using_threads): Always set to 1.
20638 (handle_extended_wait): New.
20639 (add_process): Do not set TID.
20640 (linux_create_inferior): Set must_set_ptrace_flags.
20641 (linux_attach_lwp): Remove TID argument. Do not check using_threads.
20642 Use PTRACE_SETOPTIONS. Call new_thread_notify. Update all callers.
20643 (linux_thread_alive): Rename TID argument to LWPID.
20644 (linux_wait_for_process): Handle unknown processes. Do not use TID.
20645 (linux_wait_for_event): Do not use TID or check using_threads. Update
20646 call to dead_thread_notify. Call handle_extended_wait.
20647 (linux_create_inferior): Use PTRACE_SETOPTIONS.
20648 (send_sigstop): Delete sigstop_sent.
20649 (wait_for_sigstop): Avoid TID.
20650 (linux_supports_tracefork_flag, linux_tracefork_child, my_waitpid)
20651 (linux_test_for_tracefork): New.
20652 (linux_lookup_signals): Use thread_db_active and
20653 linux_supports_tracefork_flag.
20654 (initialize_low): Use thread_db_active and linux_test_for_tracefork.
20655 * linux-low.h (get_process_thread): Avoid TID.
20656 (struct process_ifo): Move thread_known and tid to the end. Remove
20657 sigstop_sent.
20658 (linux_attach_lwp, thread_db_init): Update prototypes.
20659 * server.h (change_inferior_id): Delete prototype.
20660 (add_pid_to_list, pull_pid_from_list): New prototypes.
20661 * thread-db.c (thread_db_use_events): New.
20662 (find_first_thread): Rename to...
20663 (find_one_thread): ...this. Update callers and messages. Do not
20664 call fatal. Check thread_db_use_events. Do not call
20665 change_inferior_id or new_thread_notify.
20666 (maybe_attach_thread): Update. Do not call new_thread_notify.
20667 (thread_db_init): Set thread_db_use_events. Check use_events.
20668 * utils.c (fatal, warning): Correct message prefix.
20669
30ed0a8f
DJ
206702007-10-15 Daniel Jacobowitz <dan@codesourcery.com>
20671
20672 * Makefile.in (clean): Remove new files.
20673 (powerpc-32.o, powerpc-32.c, powerpc-e500.o, powerpc-e500.c)
20674 (powerpc-64.o, powerpc-64.c): New rules.
20675 * configure.srv: Use alternate register sets for powerpc64-*-linux*
20676 with AltiVec, powerpc-*-linux* with AltiVec, and powerpc-*-linux*
20677 with SPE.
20678 * linux-ppc-low.c (ppc_regmap): Do not fetch the FP registers for
20679 SPE targets.
20680 (ppc_cannot_store_register): Do not check for FPSCR for SPE targets.
20681 (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS, ppc_fill_vrregset)
20682 (ppc_store_vrregset, PTRACE_GETEVRREGS, PTRACE_SETEVRREGS)
20683 (struct gdb_evrregset_t, ppc_fill_evrregset, ppc_store_evrregset): New.
20684 (target_regsets): Add AltiVec and SPE register sets.
20685 * configure.ac: Check for AltiVec and SPE.
20686 * linux-ppc64-low.c (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS)
20687 (ppc_fill_vrregset, ppc_store_vrregset): New.
20688 (target_regsets): Add AltiVec register set.
20689 * configure: Regenerated.
20690
fd462a61
DJ
206912007-09-19 Daniel Jacobowitz <dan@codesourcery.com>
20692
20693 * linux-low.c (O_LARGEFILE): Define.
20694 (linux_read_memory): Use /proc/PID/mem.
20695 * configure.ac: Use AC_GNU_SOURCE. Check for pread64.
20696 * configure, config.in: Regenerated.
20697
69f223ed
DJ
206982007-09-04 Daniel Jacobowitz <dan@codesourcery.com>
20699
20700 * linux-low.c (linux_wait_for_event): Do not pass signals while
20701 single-stepping.
20702
aec18585
PA
207032007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
20704
20705 * win32-low.c (create_process): New.
20706 (win32_create_inferior): Use create_process instead of
20707 CreateProcess. If create_process failed retry appending an ".exe"
20708 suffix. Store the GetLastError result immediatelly after
20709 create_process calls and use it on the call to error.
20710
34d86ddd
PA
207112007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
20712
20713 * win32-low.c (handle_load_dll): Don't use toolhelp when waiting.
20714
5a0e3bd0
JB
207152007-08-23 Joel Brobecker <brobecker@adacore.com>
20716
20717 * configure.ac: Switch license to GPLv3.
20718
f88c79e6
MS
207192007-08-01 Michael Snyder <msnyder@access-company.com>
20720
20721 * remote-utils.c (putpkt_binary): Memory leak, free buf2.
20722
6b3d9b83
PA
207232007-07-31 Pedro Alves <pedro_alves@portugalmail.pt>
20724
20725 * win32-low.c (winapi_CloseToolhelp32Snapshot) [_WIN32_WCE]: New
20726 typedef.
20727 (win32_CloseToolhelp32Snapshot) [_WIN32_WCE]: New global var.
20728 (load_toolhelp) [_WIN32_WCE]: Load TOOLHELP.DLL. Get
20729 CloseToolhelp32Snapshot.
20730 (toolhelp_get_dll_name) [_WIN32_WCE]: Close the snapshot with
20731 CloseToolhelp32Snapshot.
20732
c588c53c
MS
207332007-07-27 Michael Snyder <michael.snyder@access-company.com>
20734
20735 * server.c (main): Check for inferior exit before main loop.
20736
aa0403d9
PA
207372007-07-18 Pedro Alves <pedro_alves@portugalmail.pt>
20738
20739 * remote-utils.c (remote_open): Set SO_KEEPALIVE on remote_desc
20740 instead of on tmp_desc.
20741
255e7678
DJ
207422007-07-17 Pedro Alves <pedro_alves@portugalmail.pt>
20743 Daniel Jacobowitz <dan@codesourcery.com>
20744
20745 * inferiors.c (all_dlls, dlls_changed, get_dll): New.
20746 (add_thread): Minor cleanups.
20747 (clear_inferiors): Move lower in the file. Clear the DLL
20748 list.
20749 (free_one_dll, match_dll, loaded_dll, unloaded_dll, clear_list): New.
20750 * remote-utils.c (prepare_resume_reply): Check dlls_changed.
20751 (xml_escape_text): New.
20752 * server.c (handle_query): Handle qXfer:libraries:read. Report it
20753 for qSupported.
20754 (handle_v_cont): Report errors.
20755 (gdbserver_version): Update.
20756 (main): Correct size of own_buf. Do not report initial DLL events.
20757 * server.h (struct dll_info, all_dlls, dlls_changed, loaded_dll)
20758 (unloaded_dll, xml_escape_text): New.
20759 * win32-low.c (enum target_waitkind): Update comments.
20760 (win32_add_one_solib, get_image_name, winapi_EnumProcessModules)
20761 (winapi_GetModuleInformation, winapi_GetModuleFileNameExA)
20762 (win32_EnumProcessModules, win32_GetModuleInformation)
20763 (win32_GetModuleFileNameExA, load_psapi, psapi_get_dll_name)
20764 (winapi_CreateToolhelp32Snapshot, winapi_Module32First)
20765 (winapi_Module32Next, win32_CreateToolhelp32Snapshot)
20766 (win32_Module32First, win32_Module32Next, load_toolhelp)
20767 (toolhelp_get_dll_name, handle_load_dll, handle_unload_dll): New.
20768 (get_child_debug_event): Handle DLL events.
20769 (win32_wait): Likewise.
20770
0d37add9
DJ
207712007-07-12 Daniel Jacobowitz <dan@codesourcery.com>
20772
20773 * configure.srv: Set srv_linux_regsets for sh*-*-linux*.
20774 * linux-sh-low.c (sh_fill_gregset, target_regsets): New.
20775
45e2715e
PA
207762007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
20777
20778 * win32-low.c (handle_output_debug_string): Ignore event if not
20779 waiting.
20780
c5674cf1
PA
207812007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
20782
20783 * win32-arm-low.c (arm_wince_breakpoint): Fix typo.
20784
2bbe3cc1
DJ
207852007-07-03 Daniel Jacobowitz <dan@codesourcery.com>
20786
20787 * remote-utils.c (look_up_one_symbol): Handle 'm' packets.
20788
ae13219e
DJ
207892007-07-02 Daniel Jacobowitz <dan@codesourcery.com>
20790
20791 * inferiors.c (change_inferior_id): Add comment.
20792 * linux-low.c (check_removed_breakpoint): Add an early
20793 prototype. Improve debug output.
20794 (linux_attach): Doc update.
20795 (linux_detach_one_process, linux_detach): Clean up before releasing
20796 each process.
20797 (send_sigstop, wait_for_sigstop): Improve comments and debug output.
20798 * linux-low.h (struct process_info): Doc improvement.
20799 * mem-break.c (delete_all_breakpoints): New.
20800 * mem-break.h (delete_all_breakpoints): New prototype.
20801 * thread-db.c (find_first_thread): New.
20802 (thread_db_create_event): Call it instead of
20803 thread_db_find_new_threads. Clean up unused variables.
20804 (maybe_attach_thread): Remove first thread handling.
20805 (thread_db_find_new_threads): Use find_first_thread.
20806 (thread_db_get_tls_address): Likewise.
20807
4105de34
DJ
208082007-06-27 Daniel Jacobowitz <dan@codesourcery.com>
20809
20810 * thread-db.c (thread_db_find_new_threads): Add prototype.
20811 (thread_db_create_event): Check for the main thread before adding
20812 a new thread.
20813 (maybe_attach_thread): Only enable event reporting if TID == 0.
20814 (thread_db_get_tls_address): Check for new threads.
20815
2b876972
DJ
208162007-06-20 Daniel Jacobowitz <dan@codesourcery.com>
20817
20818 * linux-low.c (linux_create_inferior): Try execv before execvp.
20819 * spu-low.c (spu_create_inferior): Likewise.
20820
7a245884
DJ
208212007-06-13 Mike Frysinger <vapier@gentoo.org>
20822
20823 * linux-low.c (linux_create_inferior): Change execv to execvp.
20824 * spu-low.c (spu_create_inferior): Likewies.
20825
117ce543
DJ
208262007-06-13 Daniel Jacobowitz <dan@codesourcery.com>
20827
20828 * Makefile.in (clean): Clean new files instead of deleted ones.
20829 (reg-mips.o, reg-mips.c, reg-mips64.o, reg-mips64.c): Delete.
20830 (mips-linux.o, mips-linux.c, mips64-linux.o, mips64-linux.c): New
20831 rules.
20832 * configure.srv: Specify XML files and new regformats for MIPS and
20833 MIPS64 GNU/Linux.
20834 * linux-mips-low.c (mips_num_regs): Set to only used registers.
20835 (mips_regmap): Do not fetch $0. Remove unused registers. Add
20836 an entry for the restart register.
20837 (mips_cannot_fetch_register, mips_cannot_store_register)
20838 (mips_reinsert_addr, mips_fill_fpregset, mips_store_fpregset): Update
20839 register names to match the XML descriptions.
20840 (mips_fill_gregset, mips_store_gregset): Likewise. Handle the
20841 restart register instead of $0.
20842
0e7f50da
UW
208432007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
20844 Markus Deuling <deuling@de.ibm.com>
20845
20846 * remote-utils.c (decode_xfer_write): New function.
20847 * server.h (decode_xfer_write): Add prototype.
20848 * server.c (handle_query): Add PACKET_LEN argument. Support
20849 qXfer:spu:read and qXfer:spu:write packets.
20850 (main): Pass packet_len to handle_query.
20851 * spu-low.c (spu_target_ops): Add spu_proc_xfer_spu.
20852 * target.h (target_ops): Add qxfer_spu.
20853
374c1d38
UW
208542007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
20855
20856 * spu-low.c (spu_proc_xfer_spu): Do not return failure when
20857 accessing non-seekable spufs files.
20858
bb63802a
UW
208592007-05-16 Markus Deuling <deuling@de.ibm.com>
20860
889bf7c5 20861 * server.c (handle_query): Add reply for qC packet.
bb63802a 20862
7390519e
PA
208632007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20864 Leo Zayas <lerele@champenstudios@com>
20865
20866 * server.h (check_remote_input_interrupt_request): New function.
20867 * remote_utils.c (INVALID_DESCRIPTOR): New define.
20868 (remote_desc): Initialize with INVALID_DESCRIPTOR.
20869 (input_interrupt): Expose on USE_WIN32API too. Fix whitespace.
20870 (check_remote_input_interrupt_request): New function.
20871 * server.h (check_remote_input_interrupt_request): Declare.
3ecf0694 20872 * win32-low.c (winapi_DebugBreakProcess,
7390519e
PA
20873 winapi_GenerateConsoleCtrlEvent): New typedefs.
20874 (get_child_debug_event): Lower Win32 debug event polling from 1 sec
20875 to 250 ms.
20876 (win32_wait): Check for remote interrupt request
20877 with check_remote_input_interrupt_request.
20878 (win32_request_interrupt): New function.
20879 (win32_target_op): Set request_interrupt to win32_request_interrupt.
20880
34b34921
PA
208812007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20882
20883 * win32-low.c (debug_registers_changed,
20884 debug_registers_used, CONTEXT_EXTENDED_REGISTERS,
20885 CONTEXT_FLOATING_POINT, CONTEXT_DEBUG_REGISTERS,
20886 CONTEXT_DEBUGGER, CONTEXT_DEBUGGER_DR): Delete.
20887 (thread_rec): Get context using the low target.
20888 (child_add_thread): Call thread_added on the low target,
20889 which does the same thing.
20890 (regptr): Delete.
20891 (do_initial_child_stuff): Remove debug registers references.
20892 Set context using the low target. Resume threads after
20893 setting the contexts.
20894 (child_continue): Remove dead variable. Remove debug
20895 registers references.
20896 (child_fetch_inferior_registers): Go through the low target.
20897 (do_child_store_inferior_registers): Remove.
20898 (child_store_inferior_registers): Go through the low target.
20899 (win32_resume): Remove debug registers references.
20900 Set context using the low target.
20901 (handle_exception): Change return type to void. Don't record
20902 context here. Set status to TARGET_WAITKIND_SPURIOUS on a
20903 first chance exception.
889bf7c5 20904 (get_child_debug_event): Change return type to void. Remove
34b34921
PA
20905 goto loop. Always return after waiting for debug event.
20906 (win32_wait): Convert to switch statement. Handle spurious
20907 events.
20908
20909 * win32-i386-low.c (debug_registers_changed,
20910 debug_registers_used): New.
20911 (initial_stuff): Rename to ...
20912 (i386_initial_stuff): ... this. Clear debug registers
20913 state variables.
20914 (store_debug_registers): Delete.
20915 (i386_get_thread_context): New.
20916 (load_debug_registers): Delete.
20917 (i386_set_thread_context): New.
20918 (i386_thread_added): New.
20919 (single_step): Rename to ...
20920 (i386_single_step): ... this.
20921 (do_fetch_inferior_registers): Rename to ...
20922 (i386_fetch_inferior_register): ... this.
20923 (i386_store_inferior_register): New.
20924 (the_low_target): Adapt to new interface.
20925
20926 * win32-arm-low.c (CONTEXT_FLOATING_POINT): Define.
20927 (arm_get_thread_context): New.
20928 (arm_set_thread_context): New.
20929 (regptr): New.
20930 (do_fetch_inferior_registers): Rename to ...
20931 (arm_fetch_inferior_register): ... this.
20932 (arm_store_inferior_register): New.
20933 (arm_wince_breakpoint): Reimplement as unsigned long.
20934 (arm_wince_breakpoint_len): Define.
20935 (the_low_target): Adapt to new interface.
20936
20937 * win32-low.h (target_ops): Remove regmap, store_debug_registers and
20938 load_debug_registers. Add get_thread_context, set_thread_context,
20939 thread_added and store_inferior_register. Rename
20940 fetch_inferior_registers to fetch_inferior_register.
20941 (regptr): Remove declaration.
20942
dd6953e1
PA
209432007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20944
20945 * linux-low.c (linux_detach): Change return type to int. Return 0.
20946 * spu-low.c (spu_detach): Likewise.
20947
444d6139
PA
209482007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20949
20950 * target.h (target_ops): Change return type of detach to int.
20951 Add join.
20952 (join_inferior): New.
20953 * server.c (main): Don't skip detach support on mingw32.
20954 If the inferior doesn't support detaching return error.
20955 Call join_inferior instead of using waitpid.
20956 * linux-low.c (linux_join): New.
20957 (linux_target_op): Add linux_join.
20958 * spu-low.c (spu_join): New.
20959 (spu_target_ops): Add spu_join.
20960 * win32-low.c (win32_detach): Adapt to new interface.
20961 Reopen current_process_handle before detaching. Issue a child
20962 resume before detaching.
20963 (win32_join): New.
20964 (win32_target_op): Add win32_join.
20965
1d5315fe
PA
209662007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20967
20968 * win32-low.c (win32-attach): Fix return value.
20969 * target.h (target_ops): Describe ATTACH return values.
20970
bf914831
PA
209712007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20972
20973 * win32-low.c (GETPROCADDRESS): Define.
20974 (winapi_DebugActiveProcessStop): Add WINAPI. typedef as pointer.
20975 (winapi_DebugSetProcessKillOnExit): Likewise.
20976 (win32_create_inferior): Force usage of ansi CreateProcessA.
20977 (win32_attach): Use GETPROCADDRESS.
20978 (win32_detach): Likewise.
20979
f72f3e60
PA
209802007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20981
20982 * win32-low.c (win32_wait): Don't use WSTOPSIG.
20983
ed50f18f
PA
209842007-03-30 Pedro Alves <pedro_alves@portugalmail.pt>
20985
20986 * win32-low.c: Commit leftover changes from 2007-03-29.
20987
0c2ead7e
DJ
209882007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
20989
20990 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Make 16-bit
20991 fields short instead of int. Add explicit padding.
20992 (i387_cache_to_fsave): Remove unnecessary casts.
20993 (i387_fsave_to_cache): Doc fix.
20994 (i387_cache_to_fxsave): Remove unnecessary casts and masking.
20995
73725ff3
DJ
209962007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
20997
20998 * i387-fp.c (i387_cache_to_fxsave): Reinitialize val2 before use.
20999 (i387_fxsave_to_cache): Check fp->ftag while building ftag value.
21000
d99f33d8
PA
210012007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
21002
21003 * configure.srv (arm*-*-mingw32ce*): Move near the other
21004 arm targets.
21005
68070c10
PA
210062007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
21007
2482afc6 21008 * configure.ac: Add errno checking.
68070c10
PA
21009 (AC_CHECK_HEADERS): Add errno.h, fcntl.h, signal.h,
21010 sys/file.h and malloc.h.
21011 (AC_CHECK_DECLS): Add perror.
21012 (srv_mingwce): Handle.
2482afc6 21013 * configure.srv (i[34567]86-*-cygwin*): Add
68070c10
PA
21014 win32-i386-low.o to srv_tgtobj.
21015 (i[34567]86-*-mingw*): Likewise.
21016 (arm*-*-mingw32ce*): Add case.
21017 * gdbreplay.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
21018 HAVE_FCNTL_H, HAVE_ERRNO_H, HAVE_MALLOC_H]: Check.
21019 [__MINGW32CE__] (strerror): New function.
21020 [__MINGW32CE__] (errno): Define to GetLastError.
21021 [__MINGW32CE__] (COUNTOF): New macro.
21022 (remote_open): Remove extra close call.
21023 * mem-break.c (delete_breakpoint_at): New function.
21024 * mem-break.h (delete_breakpoint_at): Declare.
21025 * remote-utils.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
21026 HAVE_FCNTL_H, HAVE_UNISTD_H, HAVE_ERRNO_H]: Check.
21027 [USE_WIN32API] (read, write): Add char* casts.
21028 * server.c [HAVE_UNISTD_H, HAVE_SIGNAL_H]: Check.
21029 * server.h: Include wincecompat.h on Windows CE.
21030 [HAVE_ERRNO_H]: Check.
21031 (perror): Declare if not declared.
21032 * utils.c: Add stdlib.h, errno.h and malloc.h includes.
21033 (perror_with_name): Remove errno declaration.
21034 * wincecompat.h: New.
21035 * wincecompat.c: New.
21036 * win32-low.h: New.
21037 * win32-arm-low.c: New.
21038 * win32-i386-low.c: New.
21039 (win32-low.c): Include mem-break.h and win32-low.h, and winnt.h.
21040 (OUTMSG2): Make it safe.
21041 (_T): New macro.
21042 (COUNTOF): New macro.
21043 (NUM_REGS): Get it from the low target.
21044 (CONTEXT_EXTENDED_REGISTERS, CONTEXT_FLOATING_POINT,
21045 CONTEXT_DEBUG_REGISTERS): Add fallbacks to 0.
21046 (thread_rec): Let low target handle debug registers.
21047 (child_add_thread): Likewise.
21048 (child_init_thread_list): Likewise.
21049 (continue_one_thread): Likewise.
21050 (regptr): New.
21051 (do_child_fetch_inferior_registers): Move to ...
21052 * win32-i386-low.c: ... here, and rename to ...
21053 (do_fetch_inferior_registers): ... this.
889bf7c5 21054 * win32-low.c (child_fetch_inferior_registers):
68070c10
PA
21055 Go through the low target.
21056 (do_child_store_inferior_registers): Use regptr.
21057 (strwinerror): New function.
21058 (win32_create_inferior): Handle Windows CE.
21059 Use strwinerror instead of strerror on Windows error
21060 codes. Add program to the error output.
21061 Don't close the main thread handle on Windows CE.
21062 (win32_attach): Use coredll.dll on Windows CE.
21063 (win32_kill): Close current process and current
21064 thread handles.
21065 (win32_detach): Use coredll.dll on Windows CE.
21066 (win32_resume): Let low target handle debug registers, and
21067 step request.
21068 (handle_exception): Add/Remove initial breakpoint. Avoid
21069 non-existant WSTOPSIG on Windows CE.
21070 (win32_read_inferior_memory): Cast to remove warning.
21071 (win32_arch_string): Go through the low target.
21072 (initialize_low): Call set_breakpoint_data with the low
21073 target's breakpoint.
21074 * win32-low.c (dr, FLAG_TRACE_BIT, FCS_REGNUM,
21075 FOP_REGNUM, mappings): Move to ...
21076 * win32-i386-low.c: ... here.
21077 * win32-low.c (win32_thread_info): Move to ...
21078 * win32-low.h: ... here.
21079 * Makefile.in (SFILES): Add win32-low.c, win32-i386-low.c,
21080 win32-arm-low.c and wincecompat.c.
21081 (all:): Add $EXEEXT.
21082 (install-only:): Likewise.
21083 (gdbserver:): Likewise.
21084 (gdbreplay:): Likewise.
21085 * config.in: Regenerate.
21086 * configure: Regenerate.
21087
41093d81
PA
210882007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
21089
21090 * win32-low.c: Rename typedef thread_info to
21091 win32_thread_info throughout.
21092
544afa54
PA
210932007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
21094
21095 * win32-i386-low.c: Rename to ...
21096 * win32-low.c: ... this.
21097 * configure.srv: Replace win32-i386-low.o with win32-low.o.
21098 * Makefile.in: Likewise.
21099
bce7165d
PA
211002007-03-27 Pedro Alves <pedro_alves@portugalmail.pt>
21101
21102 * remote-utils.c (monitor_output): Constify msg parameter.
21103 * server.h (monitor_output): Likewise.
21104 * win32-i386-low.c (handle_output_debug_string): New.
21105 (win32_kill): Handle OUTPUT_DEBUG_STRING_EVENT events using
21106 handle_output_debug_string.
21107 (get_child_debug_event): Likewise.
21108
506c7aa0
DJ
211092007-03-27 Mat Hostetter <mat@lcs.mit.edu>
21110
21111 * server.c (main): Correct strtoul check.
21112
42c81e2a
DJ
211132007-03-27 Jon Ringle <jon@ringle.org>
21114
21115 * linux-low.c: Check __ARCH_HAS_MMU__ also.
21116
9453113a
DJ
211172007-03-27 Brooks Moses <brooks.moses@codesourcery.com>
21118
21119 * Makefile.in: Add dummy "pdf" and "install-pdf" targets.
21120
64a69107
DJ
211212007-02-27 Daniel Jacobowitz <dan@codesourcery.com>
21122
21123 * terminal.h: Check HAVE_SGTTY_H.
21124
211252007-02-27 Mat Hostetter <mat@lcs.mit.edu>
6f8486da
DJ
21126
21127 * remote-utils.c (remote_open): Print out the assigned port number.
21128
c74d0ad8
DJ
211292007-02-26 Daniel Jacobowitz <dan@codesourcery.com>
21130
21131 * remote-utils.c (monitor_output): New function.
21132 * server.c (debug_threads): Define here.
21133 (monitor_show_help): New function.
21134 (handle_query): Handle qRcmd.
21135 (main): Do not handle 'd' packet.
21136 * server.h (debug_threads, remote_debug, monitor_output): Declare.
21137 * linux-low.c, spu-low.c, win32-i386-low.c: Remove definitions
21138 of debug_threads.
21139
de7c3b4a
PA
211402007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
21141
21142 * Makefile.in (EXEEXT): New.
21143 (clean): Use $(EXEEXT).
21144
ef57601b
PA
211452007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
21146
21147 * target.h (target_ops): Rename send_signal to request_interrupt,
21148 and remove enum target_signal parameter.
21149 * linux-low.c (linux_request_interrupt): Rename from
21150 linux_send_signal, and always send SIGINT.
21151 * spu-low.c (spu_request_interrupt): Rename from spu_send_signal,
21152 and always send SIGINT.
21153 * remote-utils.c (putpkt_binary): Call request_interrupt, instead
21154 of send_signal.
21155 (input_interrupt): Likewise.
21156
820f2bda
PA
211572007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
21158
21159 * server.c (get_features_xml): Check if target implemented
21160 arch_string.
21161 * win32-i386-low.c (win32_arch_string): New.
21162 (win32_target_ops): Add win32_arch_string as arch_string member.
21163
ab39bf24
UW
211642007-02-22 Markus Deuling <deuling@de.ibm.com>
21165
21166 * spu-low.c (spu_arch_string): New.
21167 (spu_target_ops): Add spu_arch_string.
21168
61ff6e04
DJ
211692007-02-16 Daniel Jacobowitz <dan@codesourcery.com>
21170
21171 * remote-utils.c: Remove HAVE_TERMINAL_H check.
21172 * configure.ac: Do not check for terminal.h.
21173 * configure, config.in: Regenerated.
21174
fb1e4ffc
DJ
211752007-02-08 Daniel Jacobowitz <dan@codesourcery.com>
21176
21177 * Makefile.in (OBS): Add $(XML_BUILTIN).
21178 (XML_DIR, XML_TARGET, XML_FILES, XML_BUILTIN): New.
21179 (clean): Update.
21180 (target.xml, xml-builtin.c, stamp-xml, arm-with-iwmmxt.o)
21181 (arm-with-iwmmxt.c): New.
21182 * config.in, configure: Regenerate.
21183 * configure.ac: Check for iWMMXt. Handle srv_xmltarget,
21184 srv_xmlbuiltin, and srv_xmlfiles. Define USE_XML.
21185 * configure.srv: Mention srv_xmltarget and srv_xmlfiles.
21186 (arm*-*-linux*): Add iWMMXt and regset support.
21187 * linux-arm-low.c (PTRACE_GETWMMXREGS, PTRACE_SETWMMXREGS): Define.
21188 (arm_fill_gregset, arm_store_gregset, arm_fill_wmmxregset)
21189 (arm_store_wmmxregset, target_regsets): New.
21190 * server.c (get_features_xml): Take annex argument. Check builtin
21191 XML documents.
21192 (handle_query): Handle multiple annexes.
21193
0f48aa01
DJ
211942007-01-29 Daniel Jacobowitz <dan@codesourcery.com>
21195
21196 * remote-utils.c [USE_WIN32API] (read, write): Define.
21197 (putpkt_binary, input_interrupt, readchar, getpkt): Use read and
21198 write.
21199
23181151
DJ
212002007-01-09 Daniel Jacobowitz <dan@codesourcery.com>
21201
21202 * linux-i386-low.c (the_low_target): Set arch_string.
21203 * linux-x86-64-low.c (the_low_target): Likewise.
21204 * linux-low.c (linux_arch_string): New.
21205 (linux_target_ops): Add it.
21206 * linux-low.h (struct linux_target_ops): Add arch_string.
21207 * server.c (write_qxfer_response): Use const void * for DATA.
21208 (get_features_xml): New.
21209 (handle_query): Handle qXfer:features:read. Report it for qSupported.
21210 * target.h (struct target_ops): Add arch_string method.
21211
9d606399
DJ
212122007-01-03 Denis Pilat <denis.pilat@st.com>
21213 Daniel Jacobowitz <dan@codesourcery.com>
21214
21215 * linux-low.c (linux_kill): Handle being called with no threads.
21216 * win32-i386-low.c (win32_kill): Likewise.
21217 (get_child_debug_event): Clear current_process_handle.
21218
212192006-12-30 Denis PILAT <denis.pilat@st.com>
8264bb58
DJ
21220 Daniel Jacobowitz <dan@codesourcery.com>
21221
21222 * remote-utils.c (remote_open): Check the type of specified
21223 serial port devices before opening them.
21224 * server.c (main): Kill the inferior if an error occurs during
21225 the first remote_open.
21226
a5e13d24
DJ
212272006-12-05 Markus Deuling <deuling@de.ibm.com>
21228
21229 * README: Update supported targets.
21230
186947f7
DJ
212312006-11-28 Daniel Jacobowitz <dan@codesourcery.com>
21232
21233 * Makefile.in (clean): Remove reg-mips64.c.
21234 (reg-mips64.c, reg-mips64.o): New rules.
21235 * configure.srv: Handle mips64. Include regset support for mips.
21236 * linux-mips-low.c (union mips_register): New.
21237 (mips_get_pc, mips_set_pc, mips_reinsert_addr): Use it.
21238 (mips_breakpoint, mips_breakpoint_at): Use int.
21239 (mips_collect_register, mips_supply_register)
21240 (mips_collect_register_32bit, mips_supply_register_32bit)
21241 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
21242 (mips_store_fpregset, target_regsets): New.
21243 * thread-db.c (thread_db_get_tls_address): Use uintptr_t.
21244
a13e2c95
UW
212452006-11-22 Ulrich Weigand <uweigand@de.ibm.com>
21246
21247 * configure.srv: Add target "spu*-*-*".
21248 * Makefile.in (clean): Remove reg-spu.c.
21249 (reg-spu.c, reg-spu.o, spu-low.o): Add dependencies.
21250 * spu-low.c: New file.
21251
cb7283db
DJ
212522006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
21253
21254 * configure.ac: Correct td_thr_tls_get_addr test.
21255 * configure: Regenerated.
21256
89be2091
DJ
212572006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
21258
21259 * linux-low.c (linux_wait_for_event): Reformat. Use the
21260 pass_signals array.
21261 * remote-utils.c (decode_address_to_semicolon): New.
21262 * server.c (pass_signals, handle_general_set): New.
21263 (handle_query): Mention QPassSignals for qSupported.
21264 (main): Call handle_general_set.
21265 * server.h (pass_signals, decode_address_to_semicolon): New.
21266
000ef4f0
DJ
212672006-11-06 Daniel Jacobowitz <dan@codesourcery.com>
21268
21269 * server.c (handle_query): Correct error handling for read_auxv.
21270
b7149293
UW
212712005-10-19 Ulrich Weigand <uweigand@de.ibm.com>
21272
21273 * configure.srv [s390-*-linux*, s390x-*-linux*]: Set srv_linux_regsets
21274 and srv_linux_thread_db to yes.
21275 * linux-s390-low.c (s390_fill_gregset): New function.
21276 (target_regsets): Define data structure.
21277
dae5f5cf
DJ
212782006-10-17 Daniel Jacobowitz <dan@codesourcery.com>
21279
21280 * acinclude.m4 (SRV_CHECK_TLS_GET_ADDR): New.
21281 * configure.ac: Use it. Define HAVE_TD_THR_TLS_GET_ADDR.
21282 * config.in, configure: Regenerated.
21283 * inferiors.c (gdb_id_to_thread): New function.
21284 (gdb_id_to_thread_id): Use it.
21285 * linux-low.c (linux_target_ops): Use thread_db_get_tls_address.
21286 * linux-low.h (struct process_info): Add th member.
21287 (thread_db_get_tls_address): New prototype.
21288 * remote-utils.c (decode_address): Make non-static.
21289 * server.c (handle_query): Handle qGetTLSAddr.
21290 * server.h (gdb_id_to_thread, decode_address): New prototypes.
21291 * target.h (struct target_ops): Add get_tls_address.
21292 * thread-db.c (maybe_attach_thread): Save the thread handle.
21293 (thread_db_get_tls_address): New.
21294
32ca6d61
DJ
212952006-09-28 Daniel Jacobowitz <dan@codesourcery.com>
21296
21297 * linux-low.c (PTRACE_GETSIGINFO, PTRACE_SETSIGINFO): Define.
21298 (linux_resume_one_process): Take a siginfo_t *. Update all
21299 callers. Queue it if necessary. Use PTRACE_SETSIGINFO.
21300 (struct pending_signals): Add a siginfo_t.
21301 (linux_wait_for_process): Always set last_status.
21302 (linux_wait_for_event): Use PTRACE_GETSIGINFO.
21303 (linux_queue_one_thread): Use PTRACE_GETSIGINFO.
21304 * linux-low.h (struct process_info): Add last_status.
21305
5ffff7c1
DJ
213062006-09-21 Daniel Jacobowitz <dan@codesourcery.com>
21307
21308 * remote-utils.c (try_rle): New function.
21309 (putpkt_binary): Use it.
21310
8695c747
DJ
213112006-08-19 Daniel Jacobowitz <dan@codesourcery.com>
21312
21313 * Makefile.in (clean): Clean reg-x86-64-linux.c.
21314 (reg-x86-64-linux.o, reg-x86-64-linux.c): New.
21315 * configure.srv (x86_64-*-linux*): Use reg-x86-64-linux.o.
21316 * linux-x86-64-low.c (x86_64_regmap): Include ORIG_RAX.
21317 (x86_64_fill_gregset, x86_64_store_gregset): Skip floating
21318 point registers.
21319
290fadea
RS
213202006-08-08 Richard Sandiford <richard@codesourcery.com>
21321
21322 * server.c (terminal_fd): New variable.
21323 (old_foreground_pgrp): Likewise.
21324 (restore_old_foreground_pgrp): New function.
21325 (start_inferior): Record the terminal file descriptor in terminal_fd
21326 and its original foreground group in old_foreground_pgrp. Register
21327 restore_old_foreground_pgrp with atexit().
21328
9f2e1e63
DJ
213292006-07-26 Daniel Jacobowitz <dan@codesourcery.com>
21330
21331 * server.c (handle_query): Correct qPart to qXfer.
21332
b80864fb
DJ
213332006-07-22 Daniel Jacobowitz <dan@codesourcery.com>
21334
21335 * configure.ac: Check for more headers which are missing on
21336 Windows. Automatically supply -lwsock32 and USE_WIN32API.
21337 * configure.srv: Add Cygwin and mingw32.
21338 * remote-utils.c: Don't include headers unconditionally which
21339 are missing on mingw32. Include <winsock.h> for mingw32.
21340 (remote_open): Adjust for mingw32 support. Flush
21341 standard error after writing to it.
21342 (remote_close, putpkt_binary, input_interrupt, block_async_io)
21343 (unblock_async_io, enable_async_io, disable_async_io)
21344 (readchar, getpkt): Update for Winsock support.
21345 (prepare_resume_reply): Expect a protocol signal number.
21346 * server.c: Disable <sys/wait.h> on mingw32.
21347 (start_inferior): Adjust for mingw32 support. Flush
21348 standard error after writing to it.
21349 (attach_inferior): Likewise. Use protocol signal
21350 numbers.
21351 (main): Skip 'D' packet on mingw32. Use protocol signal numbers
21352 and names.
21353 * win32-i386-low.c: New file.
21354 * Makefile.in (XM_CLIBS): Set.
21355 (gdbserver, gdbreplay): Use $(INTERNAL_CFLAGS).
21356 (win32-i386-low.o): New dependency rule.
21357 * linux-low.c (linux_wait): Use target signal numbers.
21358 * target.h (struct target_ops): Doc fix.
21359 * server.h (target_signal_to_name): New prototype.
21360 * gdbreplay.c: Don't include headers unconditionally which
21361 are missing on mingw32. Include <winsock.h> for mingw32.
21362 (remote_close, remote_open): Adjust for Winsock support.
21363 * configure, config.in: Regenerated.
21364
0876f84a
DJ
213652006-07-12 Daniel Jacobowitz <dan@codesourcery.com>
21366
21367 * server.c (decode_xfer_read, write_qxfer_response): New.
21368 (handle_query): Take a packet length argument. Handle
21369 qXfer:auxv:read instead of qPart:auxv:read. Mention it in
21370 the qSupported response.
21371 (main): Update call to handle_query.
21372
01f9e8fa
DJ
213732006-06-22 Daniel Jacobowitz <dan@codesourcery.com>
21374
21375 * remote-utils.c (remote_escape_output, remote_unescape_input): New.
21376 (putpkt_binary): Renamed from putpkt and adjusted for binary
21377 data.
21378 (putpkt): New wrapper for putpkt_binary.
21379 (readchar): Don't mask off the high bit.
21380 (decode_X_packet): New function.
21381 * server.c (main): Call putpkt_binary if a handler sets the packet
21382 length. Save the length of the incoming packet. Handle 'X'.
21383 * server.h (gdb_byte, remote_escape_output, decode_X_packet): New.
21384
be2a5f71
DJ
213852006-06-21 Daniel Jacobowitz <dan@codesourcery.com>
21386
21387 * server.c (handle_query): Handle qSupported.
21388
ea025f5f
DJ
213892006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
21390
21391 * remote-utils.c (all_symbols_looked_up): New variable.
21392 (look_up_one_symbol): Check it.
21393 * server.h (look_up_one_symbol): New declaration.
21394 * thread-db.c (thread_db_init): Set all_symbols_looked_up.
21395
9308fc88
DJ
213962006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
21397
21398 * Makefile.in (linux-arm-low.o): Update dependencies.
66f338c7 21399 * linux-arm-low.c: Include "gdb_proc_service.h".
9308fc88
DJ
21400 (PTRACE_GET_THREAD_AREA): Define.
21401 (ps_get_thread_area): New function.
21402
52fb6437
NS
214032006-05-09 Nathan Sidwell <nathan@codesourcery.com>
21404
21405 * configure.srv (m68k*-*-uclinux*): New target.
21406 * linux-low.c (linux_create_inferior): Use vfork on mmuless systems.
21407 (linux_resume_one_process): Remove extraneous cast.
21408 (linux_read_offsets): New.
21409 (linux_target_op): Add linux_read_offsets on mmuless systems.
21410 * server.c (handle_query): Add qOffsets logic.
21411 * target.h (struct target_ops): Add read_offsets.
21412
21b0f40c
DJ
214132006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
21414
21415 * linux-mips-low.c: Include <sys/ptrace.h> and "gdb_proc_service.h".
21416 (PTRACE_GET_THREAD_AREA): Define.
21417 (ps_get_thread_area): New function.
21418 * Makefile.in (linux-i386-low.o, linux-mips-low.o)
21419 (linux-x86-64-low.o): Update.
21420
0050a760
DJ
214212006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
21422
21423 * configure.ac: Remove checks for prfpregset_t.
21424 * gdb_proc_service.h: New file.
21425 * linux-i386-low.c, linux-x86-64-low.c, thread-db.c: Use the
21426 new "gdb_proc_service.h".
21427 * proc-service.c: Likewise.
21428 (ps_pglobal_lookup, ps_pdread, ps_pdwrite): Use psaddr_t.
21429 (ps_lgetfpregs, ps_lsetfpregs): Use a void* argument.
21430 * Makefile.in (gdb_proc_service_h): Updated.
21431 * configure, config.in: Regenerated.
21432
b92a518e
DJ
214332006-03-03 Daniel Jacobowitz <dan@codesourcery.com>
21434
21435 * remote-utils.c (prepare_resume_reply): Move declaration
21436 of gdb_id_from_wait to the top of the block.
21437
545587ee
DJ
214382006-02-15 Daniel Jacobowitz <dan@codesourcery.com>
21439
21440 * linux-low.c (regsets_store_inferior_registers): Read the regset
21441 from the target before filling it.
21442
9db87ebd
DJ
214432006-02-08 Daniel Jacobowitz <dan@codesourcery.com>
21444
21445 * server.c (attach_inferior): Return SIGTRAP for a successful
21446 attach.
21447
dd24457d
DJ
214482006-02-01 Daniel Jacobowitz <dan@codesourcery.com>
21449
21450 * Makefile.in (OBS): Add version.o.
21451 (STAGESTUFF): Delete.
21452 (version.o): Add dependencies.
21453 (version.c): Replace rule.
21454 (clean): Remove version.c.
21455 * server.c (gdbserver_version): New.
21456 (gdbserver_usage): Use printf.
21457 (main): Handle --version and --help.
21458 * server.h (version, host_name): Add declarations.
21459
6f0f660e
EZ
214602005-12-23 Eli Zaretskii <eliz@gnu.org>
21461
889bf7c5
PA
21462 * linux-arm-low.c:
21463 * linux-arm-low.c:
21464 * inferiors.c:
21465 * i387-fp.h:
21466 * i387-fp.c:
21467 * gdbreplay.c:
21468 * regcache.c:
21469 * proc-service.c:
21470 * mem-break.h:
21471 * mem-break.c:
21472 * linux-x86-64-low.c:
21473 * linux-sh-low.c:
21474 * linux-s390-low.c:
21475 * linux-ppc64-low.c:
21476 * linux-ppc-low.c:
21477 * linux-mips-low.c:
21478 * linux-m68k-low.c:
21479 * linux-m32r-low.c:
21480 * linux-low.h:
21481 * linux-low.c:
21482 * linux-ia64-low.c:
21483 * linux-i386-low.c:
21484 * linux-crisv32-low.c:
21485 * thread-db.c:
21486 * terminal.h:
21487 * target.h:
21488 * target.c:
21489 * server.h:
21490 * server.c:
21491 * remote-utils.c:
21492 * regcache.h:
21493 * utils.c:
21494 * Makefile.in:
21495 * configure.ac:
6f0f660e
EZ
21496 * gdbserver.1: Add (C) after Copyright. Update the FSF
21497 address.
21498
9d1fb177
DJ
214992005-11-13 Daniel Jacobowitz <dan@codesourcery.com>
21500
21501 * linux-arm-low.c (arm_eabi_breakpoint): New variable.
21502 (arm_breakpoint_at): Recognize both breakpoints.
21503 (the_low_target): Use the correct breakpoint instruction.
21504
011a70c2
DJ
215052005-11-02 Daniel Jacobowitz <dan@codesourcery.com>
21506
21507 * configure.srv (x86_64-*-linux*): Turn on thread_db support.
21508 * linux-x86-64-low.c (x86_64_breakpoint, x86_64_breakpoint_len)
21509 (x86_64_get_pc, x86_64_set_pc, x86_64_breakpoint_at): New.
21510 (the_low_target): Update.
21511
7fb85e41
AS
215122005-10-25 Andreas Schwab <schwab@suse.de>
21513
21514 * server.c (main): Allocate mem_buf with PBUFSIZ bytes.
21515
21516 * linux-ia64-low.c (ia64_regmap): Remove NAT registers.
21517 (ia64_num_regs): Reduce to 462.
21518
3db0444b
DJ
215192005-09-17 Daniel Jacobowitz <dan@codesourcery.com>
21520
21521 * acinclude.m4: Correct quoting.
21522 * aclocal.m4: Regenerated.
21523
21524 Suggested by SZOKOVACS Robert <szo@ies.hu>:
21525 * thread-db.c (thread_db_err_str): Handle TD_VERSION.
21526 (thread_db_init): Call thread_db_err_str.
21527 * configure.ac: Check for TD_VERSION.
21528 * config.in, configure: Regenerated.
21529
bee0189a
DJ
215302005-07-31 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
21531
21532 * server.h (error, fatal, warning): Add ATTR_FORMAT.
21533
e9d25b98
DJ
215342005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
21535
21536 * configure.ac: Define HAVE_LINUX_REGSETS even if PTRACE_GETREGS
21537 is not available. Define HAVE_PTRACE_GETREGS if it is.
21538 * config.in, configure: Regenerated.
21539 * configure.srv: Set srv_linux_regsets for PowerPC and PowerPC64.
21540 * linux-i386-low.c, linux-m68k-low.c: Update to use
21541 HAVE_PTRACE_GETREGS.
21542 * linux-low.c (regsets_fetch_inferior_registers)
21543 (regsets_store_inferior_registers): Only return 0 if we processed
21544 GENERAL_REGS.
21545 * linux-ppc-low.c (ppc_fill_gregset, target_regsets): New.
21546 * linux-ppc64-low.c (ppc_fill_gregset, target_regsets): New.
21547
a06660f7
DJ
215482005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
21549
21550 * inferiors.c (struct thread_info): Add gdb_id.
21551 (add_thread): Add gdb_id argument.
21552 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New.
21553 * linux-low.c (linux_create_inferior, linux_attach_lwp): Update
21554 calls to add_thread.
21555 * remote-utils.c (prepare_resume_reply: Use thread_to_gdb_id.
21556 * server.c (handle_query): Use thread_to_gdb_id.
21557 (handle_v_cont, main): Use gdb_id_to_thread_id.
21558 * server.h (add_thread): Update prototype.
21559 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New
21560 prototypes.
21561
5a1f5858
DJ
215622005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
21563
21564 * linux-low.c (fetch_register, usr_store_inferior_registers): Handle
21565 left-padded registers.
21566 * linux-low.h (struct linux_target_ops): Add left_pad_xfer.
21567 * linux-ppc64-low.c (the_low_target): Set left_pad_xfer.
21568
e122f1f5
SE
215692005-07-01 Steve Ellcey <sje@cup.hp.com>
21570
21571 * configure.ac (BFD_NEED_DECLARATION): Replace with AC_CHECK_DECLS.
21572 * configure: Regenerate.
21573 * config.in: Regenerate.
21574 * server.h (NEED_DECLARATION_STRERROR):
21575 Replace with !HAVE_DECL_STRERROR.
21576
d592fa2f
DJ
215772005-06-16 Daniel Jacobowitz <dan@codesourcery.com>
21578
21579 * linux-low.c (linux_wait, linux_send_signal): Don't test
21580 an unsigned long variable for > 0 if it could be MAX_ULONG.
21581 * server.c (myresume): Likewise.
21582 * target.c (set_desired_inferior): Likewise.
21583
ccbd4912
MK
215842005-06-13 Mark Kettenis <kettenis@gnu.org>
21585
21586 * configure.ac: Simplify and improve check for socklen_t.
21587 * configure, config.in: Regenerate.
21588
f450004a
DJ
215892005-06-12 Daniel Jacobowitz <dan@codesourcery.com>
21590
21591 * acconfig.h: Remove.
21592 * configure.ac: Add a test for socklen_t. Use three-argument
21593 AC_DEFINE throughout.
21594 * config.in: Regenerated using autoheader 2.59.
21595 * configure: Regenerated.
21596
21597 * gdbreplay.c (socklen_t): Provide a default.
21598 (remote_open): Use socklen_t.
21599 * remote-utils.c (socklen_t): Provide a default.
21600 (remote_open): Use socklen_t.
21601 (convert_int_to_ascii, convert_ascii_to_int, decode_M_packet): Use
21602 unsigned char.
21603
21604 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Use unsigned
21605 char for buffers.
21606 * linux-low.c (linux_read_memory, linux_write_memory)
21607 (linux_read_auxv): Likewise.
21608 * mem-break.c (breakpoint_data, set_breakpoint_data, check_mem_read)
21609 (check_mem_write): Likewise.
21610 * mem-break.h (set_breakpoint_data, check_mem_read, check_mem_write):
21611 Likewise.
21612 * regcache.c (struct inferior_rgcache_data, registers_to_string)
21613 (registers_from_string, register_data): Likewise.
21614 * server.c (handle_query, main): Likewise.
21615 * server.h (convert_ascii_to_int, convert_int_to_ascii)
21616 (decode_M_packet): Likewise.
21617 * target.c (read_inferior_memory, write_inferior_memory): Likewise.
21618 * target.h (struct target_ops): Update read_memory, write_memory,
21619 and read_auxv.
21620 (read_inferior_memory, write_inferior_memory): Update.
21621 * linux-low.h (struct linux_target_ops): Change type of breakpoint
21622 to unsigned char *.
21623 * linux-arm-low.c, linux-cris-low.c, linux-crisv32-low.c,
21624 linux-i386-low.c, linux-m32r-low.c, linux-m68k-low.c,
21625 linux-mips-low.c, linux-ppc-low.c, linux-ppc64-low.c,
21626 linux-s390-low.c, linux-sh-low.c: Update for changes in
21627 read_inferior_memory and the_low_target->breakpoint.
21628
eee84df1
DJ
216292005-05-28 Daniel Jacobowitz <dan@codesourcery.com>
21630
21631 * Makefile.in (SFILES): Add linux-ppc64-low.c.
21632 (linux-ppc64-low.o, reg-ppc64.c, reg-ppc64.o): New targets.
21633 * configure.srv: Add powerpc64-*-linux*.
21634 * linux-ppc64-low.c: New file.
21635
45b134e5
OF
216362005-05-23 Orjan Friberg <orjanf@axis.com>
21637
21638 * linux-cris-low.c: New file with support for CRIS.
21639 * linux-crisv32-low.c: Ditto for CRISv32.
21640 * Makefile.in (SFILES): Add linux-cris-low.c, linux-crisv32-low.c.
21641 (clean): Add reg-cris.c and reg-crisv32.c.
889bf7c5 21642 Add linux-cris-low.o, linux-crisv32-low.o, reg-cris.o, reg-cris.c,
45b134e5
OF
21643 reg-crisv32.o, and reg-crisv32.c to make rules.
21644 * configure.srv: Add cris-*-linux* and crisv32-*-linux* to list of
21645 recognized targets.
21646
48d93c75
UW
216472005-05-16 Ulrich Weigand <uweigand@de.ibm.com>
21648
21649 * linux-low.c (fetch_register): Ensure buffer size is a multiple
21650 of sizeof (PTRACE_XFER_TYPE).
21651 (usr_store_inferior_registers): Likewise. Zero out excess bytes.
21652
e013ee27
OF
216532005-05-12 Orjan Friberg <orjanf@axis.com>
21654
889bf7c5 21655 * target.h (struct target_ops): Add insert_watchpoint,
e013ee27
OF
21656 remove_watchpoint, stopped_by_watchpoint, stopped_data_address function
21657 pointers for hardware watchpoint support.
21658 * linux-low.h (struct linux_target_ops): Ditto.
21659 * linux-low.c (linux_insert_watchpoint, linux_remove_watchpoint)
21660 (linux_stopped_by_watchpoint, linux_stopped_data_address): New. Add
21661 to linux_target_ops.
21662 * remote-utils.c (prepare_resume_reply): Add watchpoint information to
21663 reply packet.
21664 * server.c (main): Recognize 'Z' and 'z' packets.
21665
b0ded00b
UW
216662005-05-10 Ulrich Weigand <uweigand@de.ibm.com>
21667
21668 * linux-s390-low.c (s390_breakpoint, s390_breakpoint_len): Define.
21669 (s390_get_pc, s390_set_pc, s390_breakpoint_at): New functions.
21670 (the_low_target): Add new members.
21671
8643e2ad
DJ
216722005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
21673
21674 * proc-service.c (ps_lgetregs): Search all_processes instead of
21675 all_threads.
21676
fc620387
DJ
216772005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
21678
21679 * server.c (start_inferior): Change return type to int.
21680 (attach_inferior): Change sigptr to int *.
21681 (handle_v_cont, handle_v_requests): Change signal to int *.
21682 (main): Change signal to int.
21683
216842005-04-15 Kei Sakamoto <sakamoto.kei@renesas.com>
7cfbc4a0
KI
21685
21686 * Makefile.in: Add linux-m32r-low.o, reg-m32r.c and reg-m32r.o.
21687 * configure.srv: Add m32r*-*-linux*.
21688 * linux-m32r-low.c: New file.
21689
e0e76420
DJ
216902005-03-04 Daniel Jacobowitz <dan@codesourcery.com>
21691
21692 * Makefile.in (stamp-h): Set CONFIG_HEADERS explicitly.
21693
a1928bad
DJ
216942005-03-03 Daniel Jacobowitz <dan@codesourcery.com>
21695
21696 * inferiors.c (change_inferior_id, add_thread, find_inferior_id):
21697 Take unsigned long arguments for PIDs.
21698 * linux-low.c (add_process, linux_attach_lwp, linux_attach)
21699 (linux_thread_alive, linux_wait_for_event, kill_lwp, send_sigstop)
21700 (wait_for_sigstop, linux_resume_one_process)
21701 (regsets_fetch_inferior_registers, linux_send_signal)
21702 (linux_read_auxv): Likewise. Update the types of variables holding
21703 PIDs. Update format string specifiers.
21704 * linux-low.h (struct process_info, linux_attach_lwp): Likewise.
21705 * remote-utils.c (prepare_resume_reply): Likewise.
21706 * server.c (cont_thread, general_thread, step_thread)
21707 (thread_from_wait, old_thread_from_wait, signal_pid): Change type to
21708 unsigned long.
21709 (handle_query): Update format specifiers.
21710 (handle_v_cont, main): Use strtoul for thread IDs.
21711 * server.h (struct inferior_list_entry): Use unsigned long for ID.
21712 (add_thread, find_inferior_id, change_inferior_id, cont_thread)
21713 (general_thread, step_thread, thread_from_wait)
21714 (old_thread_from_wait): Update.
21715 * target.h (struct thread_resume): Use unsigned long for THREAD.
21716 (struct target_ops): Use unsigned long for arguments to attach and
21717 thread_alive.
21718
dcdb98d2
DJ
217192005-02-24 Daniel Jacobowitz <dan@codesourcery.com>
21720
21721 * acinclude.m4: Include bfd/bfd.m4 directly.
21722 * configure.ac: Use AC_ARG_PROGRAM. Suggested by Aron Griffis
21723 <agriffis@toolchain.org>.
21724 * aclocal.m4, configure: Regenerated.
21725
bec39cab
AC
217262005-01-07 Andrew Cagney <cagney@gnu.org>
21727
21728 * configure.ac: Rename configure.in, require autoconf 2.59.
21729 * configure: Re-generate.
21730
434c4c77
DJ
217312004-12-08 Daniel Jacobowitz <dan@debian.org>
21732
21733 * acinclude.m4 (SRV_CHECK_THREAD_DB): Add ps_get_thread_area. Reset
21734 LIBS when finished.
21735 * aclocal.m4: Regenerated.
21736 * configure: Regenerated.
21737
db1d3e1b
AS
217382004-11-21 Andreas Schwab <schwab@suse.de>
21739
21740 * linux-m68k-low.c (m68k_num_gregs): Define.
21741 (m68k_fill_gregset, m68k_store_gregset, m68k_fill_fpregset)
21742 (m68k_store_fpregset, target_regsets) [HAVE_LINUX_REGSETS]: New.
21743 (m68k_breakpoint, m68k_breakpoint_len, m68k_get_pc, m68k_set_pc)
21744 (m68k_breakpoint_at): New. Add to the_low_target.
21745
21746 * configure.srv (m68*-*-linux*): Set srv_linux_regsets and
21747 srv_linux_thread_db to yes.
21748
43360365
JB
217492004-10-20 Joel Brobecker <brobecker@gnat.com>
21750
21751 * linux-x86-64-low.c (ARCH_SET_GS): Add definition if missing.
21752 (ARCH_SET_FS): Likewise.
21753 (ARCH_GET_FS): Likewise.
21754 (ARCH_GET_GS): Likewise.
21755
fd500816
DJ
217562004-10-16 Daniel Jacobowitz <dan@debian.org>
21757
21758 * linux-i386-low.c (ps_get_thread_area): New.
21759 * linux-x86-64-low.c (ps_get_thread_area): New.
21760 * linux-low.c: Include <sys/syscall.h>.
21761 (linux_kill_one_process): Don't kill the first thread here.
21762 (linux_kill): Kill the first thread here.
21763 (kill_lwp): New function.
21764 (send_sigstop, linux_send_signal): Use it.
21765 * proc-service.c: Clean up #ifdefs.
21766 (fpregset_info): Delete.
21767 (ps_lgetregs): Update and enable implementation.
21768 (ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs): Remove disabled
21769 implementations.
21770 * remote-utils.c (struct sym_cache, symbol_cache): New.
21771 (input_interrupt): Print a clearer message.
21772 (async_io_enabled): New variable.
21773 (enable_async_io, disable_async_io): Use it. Update comments.
21774 (look_up_one_symbol): Use the symbol cache.
21775 * thread-db.c (thread_db_look_up_symbols): New function.
21776 (thread_db_init): Update comments. Call thread_db_look_up_symbols.
21777
f6de3c42
DJ
217782004-10-16 Daniel Jacobowitz <dan@debian.org>
21779
21780 * configure.in: Test for -rdynamic.
21781 * configure: Regenerated.
21782 * Makefile (INTERNAL_LDFLAGS): New.
21783 (gdbserver, gdbreplay): Use it.
21784
2c0fc042
AC
217852004-09-02 Andrew Cagney <cagney@gnu.org>
21786
21787 * Makefile.in (TAGS): Replace TM_FILE with DEPRECATED_TM_FILE.
21788
075b3282
DJ
217892004-03-23 Daniel Jacobowitz <drow@mvista.com>
21790
21791 * linux-low.c (linux_wait): Clear all_processes list also.
21792
fa6a77dc
DJ
217932004-03-12 Daniel Jacobowitz <drow@mvista.com>
21794
21795 * linux-low.c: Include <errno.h>. Remove extern declaration of
21796 errno.
21797
6d782a97
DJ
217982004-03-12 Daniel Jacobowitz <drow@mvista.com>
21799
21800 * gdbreplay.c, server.h, utils.c: Update copyright years.
21801
3a7fb99b
DJ
218022004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
21803
21804 * server.c (main): Print child status or termination signal from
21805 variable 'signal', not 'sig'.
21806
c3e735a6
DJ
218072004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
21808
21809 * linux-low.c (linux_read_memory): Change return type to
21810 int. Check for and return error from ptrace().
21811 * target.c (read_inferior_memory): Change return type to int. Pass
21812 back return status from the_target->read_memory().
21813 * target.h (struct target_ops): Adapt *read_memory() prototype.
21814 Update comment.
21815 (read_inferior_memory): Adapt prototype.
21816 * server.c (main): Return an error packet if
21817 read_inferior_memory() returns an error.
21818
a59d1c82
DJ
218192004-03-04 Daniel Jacobowitz <drow@mvista.com>
21820
21821 * Makefile.in (distclean): Remove config.h, stamp-h, and config.log.
21822 Unify with other clean targets.
21823
dc3f8883
DJ
218242004-02-29 Daniel Jacobowitz <drow@mvista.com>
21825
21826 * server.c (handle_v_cont): Call set_desired_inferior.
21827
89a208da
DJ
218282004-02-29 Daniel Jacobowitz <drow@mvista.com>
21829
21830 * remote-utils.c (prepare_resume_reply): Always supply "thread:".
21831
62ea82f5
DJ
218322004-02-29 Daniel Jacobowitz <drow@mvista.com>
21833
21834 * linux-low.c (linux_wait): Unblock async I/O.
21835 (linux_resume): Block and enable async I/O.
21836 * remote-utils.c (block_async_io, unblock_async_io): New functions.
21837 * server.h (block_async_io, unblock_async_io): Add prototypes.
21838
6910d122
DJ
218392004-02-29 Daniel Jacobowitz <drow@mvista.com>
21840
21841 * remote-utils.c (remote_open): Print a status notice after
21842 opening a TCP port.
21843 * server.c (attach_inferior): Print a status notice after
21844 attaching.
21845
218462004-02-29 Daniel Jacobowitz <drow@mvista.com>
d677d77d
DJ
21847
21848 * linux-arm-low.c (arm_get_pc): Print out stop PC in debug mode.
21849
c89dc5d4
DJ
218502004-02-26 Daniel Jacobowitz <drow@mvista.com>
21851
21852 * remote-utils.c (write_enn): Use "E01" instead of "ENN" for the
21853 error packet.
21854 * server.c, target.h: Update copyright years.
21855
4b8dad4a
RM
218562004-02-25 Roland McGrath <roland@redhat.com>
21857
21858 * target.h (struct target_ops): New member `read_auxv'.
21859 * server.c (handle_query): Handle qPart:auxv:read: query using that.
21860 * linux-low.c (linux_read_auxv): New function.
21861 (linux_target_ops): Initialize `read_auxv' member to that.
21862
d7446758
JB
218632004-02-17 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
21864
21865 Committed by Jim Blandy <jimb@redhat.com>.
21866
21867 * linux-s390-low.c (s390_num_regs): Update.
4b8dad4a 21868 (s390_regmap): Remove control registers. Use __s390x__ predefine
d7446758
JB
21869 instead of GPR_SIZE to distiguish s390 and s390x targets.
21870
5544ad89
DJ
218712004-01-31 Daniel Jacobowitz <drow@mvista.com>
21872
21873 * linux-low.c: Update copyright year.
21874 (check_removed_breakpoint): Clear pending_is_breakpoint.
21875 (linux_set_resume_request, linux_queue_one_thread)
21876 (resume_status_pending_p): New functions.
21877 (linux_continue_one_thread): Use process->resume.
21878 (linux_resume): Only resume threads if there are no pending events.
21879 * linux-low.h (struct process_info): Add resume request
21880 pointer.
21881
2a68b70e
DJ
218822004-01-30 Daniel Jacobowitz <drow@mvista.com>
21883
21884 * regcache.c (new_register_cache): Clear the allocated register
21885 buffer. Suggested by Atsushi Nemoto <anemo@mba.ocn.ne.jp>.
21886
64386c31
DJ
218872003-10-13 Daniel Jacobowitz <drow@mvista.com>
21888
21889 * linux-low.c (linux_resume): Take a struct thread_resume *
21890 argument.
21891 (linux_wait): Update call.
21892 (resume_ptr): New static variable.
21893 (linux_continue_one_thread): Renamed from
21894 linux_continue_one_process. Use resume_ptr.
21895 (linux_resume): Use linux_continue_one_thread.
21896 * server.c (handle_v_cont, handle_v_requests): New functions.
21897 (myresume): New function.
21898 (main): Handle 'v' case.
21899 * target.h (struct thread_resume): New type.
21900 (struct target_ops): Change argument of "resume" to struct
21901 thread_resume *.
21902 (myresume): Delete macro.
21903
c938e9b0
L
219042003-08-08 H.J. Lu <hongjiu.lu@intel.com>
21905
21906 * Makefile.in (install-only): Create dest dir. Support DESTDIR.
21907 (uninstall): Support DESTDIR.
21908
7f313d07
BC
21909Mon Jul 21 20:09:34 UTC 2003 Brendan Conoboy <blc@redhat.com>
21910
21911 * configure.srv: Add xscale*linux copy of arm*linux entry.
21912
3b2fc2ea
DJ
219132003-07-24 Daniel Jacobowitz <drow@mvista.com>
21914
21915 * linux-arm-low.c (arm_reinsert_addr): New function.
21916 (the_low_target): Add arm_reinsert_addr.
21917
1c0a559e
MK
219182003-07-08 Mark Kettenis <kettenis@gnu.org>
21919
21920 * mem-break.c: Remove whitespace at end of file.
21921
43d5792c
DJ
219222003-06-28 Daniel Jacobowitz <drow@mvista.com>
21923
21924 * configure.in: Check whether we need to prototype strerror.
21925 * server.h: Optionally prototype strerror.
21926 * gdbreplay.c (perror_with_name): Use strerror.
21927 * linux-low.c (linux_attach_lwp): Use strerror.
21928 * utils.c (perror_with_name): Use strerror.
21929 * config.in, configure: Regenerated.
21930
c8a86edf
DJ
219312003-06-28 Daniel Jacobowitz <drow@mvista.com>
21932
21933 * linux-sh-low.c (sh_regmap): Fix FP register offsets, reported by
21934 SUGIOKA Toshinobu <sugioka@itonet.co.jp>.
21935
73d37363
DJ
219362003-06-20 Daniel Jacobowitz <drow@mvista.com>
21937
21938 * Makefile.in (SFILES): Update.
21939 * low-hppabsd.c, low-lynx.c, low-nbsd.c, low-sim.c, low-sparc.c,
21940 low-sun3.c: Remove files.
21941
6ad8ae5c
DJ
219422003-06-17 Daniel Jacobowitz <drow@mvista.com>
21943
21944 * linux-low.c: Move comment to linux_thread_alive where it belonged.
21945 (linux_detach_one_process, linux_detach): New functions.
21946 (linux_target_ops): Add linux_detach.
21947 * server.c (main): Handle 'D' packet.
21948 * target.h (struct target_ops): Add "detach" member.
21949 (detach_inferior): Define.
21950
1581182a
MK
219512003-06-13 Mark Kettenis <kettenis@gnu.org>
21952
21953 From Kelley Cook <kelleycook@wideopenwest.com>:
21954 * configure.srv: Accept i[34567]86 variants.
21955
e5379b03
DJ
219562003-06-05 Daniel Jacobowitz <drow@mvista.com>
21957
21958 * linux-low.c (linux_wait_for_event): Correct comment typos.
21959 (linux_resume_one_process): Call check_removed_breakpoint.
21960 (linux_send_signal): New function.
21961 (linux_target_ops): Add linux_send_signal.
21962 * remote-utils.c (putpkt, input_interrupt): Use send_signal instead
21963 of kill.
21964 * target.h (struct target_ops): Add send_signal.
21965
2ff29de4
JB
219662003-05-29 Jim Blandy <jimb@redhat.com>
21967
21968 * linux-low.c (usr_store_inferior_registers): Transfer buf in
21969 PTRACE_XFER_TYPE-sized chunks, not int-sized chunks. Otherwise,
21970 if 'int' is smaller than PTRACE_XFER_TYPE, you end up throwing
21971 away part of the register's value.
21972
254787d4
DJ
219732003-03-26 Daniel Jacobowitz <drow@mvista.com>
21974
21975 * linux-low.c (linux_create_inferior): Use __SIGRTMIN.
21976 (linux_wait_for_event, linux_init_signals): Likewise.
21977
94e10508
DJ
219782003-03-17 Daniel Jacobowitz <drow@mvista.com>
21979
21980 * configure.in: Check for stdlib.h.
21981 * configure: Regenerated.
21982 * config.in: Regenerated.
21983
4c0711e0
DJ
219842003-01-04 Andreas Schwab <schwab@suse.de>
21985
21986 * linux-m68k-low.c (m68k_num_regs): Define to 29 instead of 31.
21987
ef66e766
AC
219882003-01-02 Andrew Cagney <ac131313@redhat.com>
21989
21990 * Makefile.in: Remove obsolete code.
21991
a1358604
DJ
219922002-11-20 Daniel Jacobowitz <drow@mvista.com>
21993
21994 * linux-s390-low.c (s390_regmap): Check GPR_SIZE instead of
21995 defined(PT_FPR0_HI).
21996
23ce3b1c
DJ
219972002-11-17 Stuart Hughes <seh@zee2.com>
21998
21999 * linux-arm-low.c (arm_num_regs): Increase.
22000 (arm_regmap): Include status register.
22001
220022002-11-17 Daniel Jacobowitz <drow@mvista.com>
22003
22004 * linux-low.c (register_addr): Remove incorrect -1 check.
22005
a9fa9f7d
DJ
220062002-08-29 Daniel Jacobowitz <drow@mvista.com>
22007
22008 * linux-low.c (linux_create_inferior): Call setpgid. Return
22009 the new PID.
22010 (unstopped_p, linux_signal_pid): Remove.
22011 (linux_target_ops): Remove linux_signal_pid.
22012 * remote-utils.c (putpkt, input_interrupt): Use signal_pid
22013 global instead of target method.
22014 * target.h (struct target_ops): Remove signal_pid. Update comment
22015 for create_inferior.
22016 * server.c (signal_pid): New variable.
22017 (create_inferior): Set signal_pid. Block SIGTTOU and SIGTTIN in
4b8dad4a 22018 gdbserver. Set the child to be the foreground process group.
a9fa9f7d
DJ
22019 (attach_inferior): Set signal_pid.
22020
17574093
DJ
220212002-08-23 Daniel Jacobowitz <drow@mvista.com>
22022
22023 * ChangeLog: New file, with entries from gdb/ChangeLog after GDB 5.2.
22024
220252002-08-20 Jim Blandy <jimb@redhat.com>
22026
22027 * Makefile.in (LDFLAGS): Allow the configure script to establish a
22028 default for this.
22029
220302002-08-01 Andrew Cagney <cagney@redhat.com>
22031
22032 * Makefile.in: Make chill references obsolete.
22033
220342002-07-24 Kevin Buettner <kevinb@redhat.com>
22035
22036 * configure.in (unistd.h): Add to AC_CHECK_HEADERS list.
22037 * configure: Regenerate.
22038 * config.in: Regenerate.
22039
220402002-07-09 David O'Brien <obrien@FreeBSD.org>
22041
22042 * gdbreplay.c (stdlib.h, unistd.h): Conditionaly include.
22043 (perror_with_name, remote_close, remote_open, expect, play): Static.
22044
220452002-07-04 Michal Ludvig <mludvig@suse.cz>
22046
4b8dad4a 22047 * linux-x86-64-low.c (x86_64_regmap): Make it an array of
17574093
DJ
22048 byte offsets instead of an array of indexes.
22049 (x86_64_store_gregset, x86_64_store_fpregset): Parameter made const.
22050
220512002-06-13 Daniel Jacobowitz <drow@mvista.com>
22052
22053 * regcache.c: Add comment.
22054
220552002-06-11 Daniel Jacobowitz <drow@mvista.com>
22056
22057 * thread-db.c: New file.
22058 * proc-service.c: New file.
22059 * acinclude.m4: New file.
22060 * Makefile.in: Add GDBSERVER_LIBS, gdb_proc_service_h,
22061 proc-service.o, and thread-db.o.
22062 (linux-low.o): Add USE_THREAD_DB.
22063 * acconfig.h: Add HAVE_PRGREGSET_T, HAVE_PRFPREGSET_T,
22064 HAVE_LWPID_T, HAVE_PSADDR_T, and PRFPREGSET_T_BROKEN.
22065 * aclocal.m4: Regenerated.
22066 * config.in: Regenerated.
22067 * configure: Regenerated.
22068 * configure.in: Check for proc_service.h, sys/procfs.h,
22069 thread_db.h, and linux/elf.h headrs.
22070 Check for lwpid_t, psaddr_t, prgregset_t, prfpregset_t, and
22071 PRFPREGSET_T_BROKEN. Introduce srv_thread_depfiles and USE_THREAD_DB.
22072 Check for -lthread_db and thread support.
22073 * configure.srv: Enable thread_db support for ARM, i386, MIPS,
22074 PowerPC, and SuperH.
22075 * i387-fp.c: Constify arguments.
22076 * i387-fp.h: Likewise.
22077 * inferiors.c: (struct thread_info): Renamed from
22078 `struct inferior_info'. Remove PID member. Use generic inferior
22079 list header. All uses updated.
22080 (inferiors, signal_pid): Removed.
22081 (all_threads): New variable.
22082 (get_thread): Define.
22083 (add_inferior_to_list): New function.
22084 (for_each_inferior): New function.
22085 (change_inferior_id): New function.
22086 (add_inferior): Removed.
22087 (remove_inferior): New function.
22088 (add_thread): New function.
22089 (free_one_thread): New function.
22090 (remove_thread): New function.
22091 (clear_inferiors): Use for_each_inferior and free_one_thread.
22092 (find_inferior): New function.
22093 (find_inferior_id): New function.
22094 (inferior_target_data): Update argument type.
22095 (set_inferior_target_data): Likewise.
22096 (inferior_regcache_data): Likewise.
22097 (set_inferior_regcache_data): Likewise.
22098 * linux-low.c (linux_bp_reinsert): Remove.
22099 (all_processes, stopping_threads, using_thrads)
22100 (struct pending_signals, debug_threads, pid_of): New.
22101 (inferior_pid): Replace with macro.
22102 (struct inferior_linux_data): Remove.
22103 (get_stop_pc, add_process): New functions.
22104 (linux_create_inferior): Restore SIGRTMIN+1 before calling exec.
22105 Use add_process and add_thread.
22106 (linux_attach_lwp): New function, based on old linux_attach. Use
22107 add_process and add_thread. Set stop_expected for new threads.
22108 (linux_attach): New function.
22109 (linux_kill_one_process): New function.
22110 (linux_kill): Kill all LWPs.
22111 (linux_thread_alive): Use find_inferior_id.
22112 (check_removed_breakpoints, status_pending_p): New functions.
22113 (linux_wait_for_process): Renamed from linux_wait_for_one_inferior.
22114 Update. Use WNOHANG. Wait for cloned processes also. Update process
22115 struct for the found process.
22116 (linux_wait_for_event): New function.
22117 (linux_wait): Use it. Support LWPs.
22118 (send_sigstop, wait_for_sigstop, stop_all_processes)
22119 (linux_resume_one_process, linux_continue_one_process): New functions.
22120 (linux_resume): Support LWPs.
22121 (REGISTER_RAW_SIZE): Remove.
22122 (fetch_register): Use register_size instead. Call supply_register.
22123 (usr_store_inferior_registers): Likewise. Call collect_register.
22124 Fix recursive case.
22125 (regsets_fetch_inferior_registers): Improve error message.
22126 (regsets_store_inferior_registers): Add debugging.
22127 (linux_look_up_symbols): Call thread_db_init if USE_THREAD_DB.
22128 (unstopped_p, linux_signal_pid): New functions.
22129 (linux_target_ops): Add linux_signal_pid.
22130 (linux_init_signals): New function.
22131 (initialize_low): Call it. Initialize using_threads.
22132 * regcache.c (inferior_regcache_data): Add valid
22133 flag.
22134 (get_regcache): Fetch registers lazily. Add fetch argument
22135 and update all callers.
22136 (regcache_invalidate_one, regcache_invalidate): New
22137 functions.
22138 (new_register_cache): Renamed from create_register_cache.
22139 Return the new regcache.
22140 (free_register_cache): Change argument to a void *.
22141 (registers_to_string, registers_from_string): Call get_regcache
22142 with fetch flag set.
22143 (register_data): Make static. Pass fetch flag to get_regcache.
22144 (supply_register): Call get_regcache with fetch flag clear.
22145 (collect_register): Call get_regcache with fetch flag set.
22146 (collect_register_as_string): New function.
22147 * regcache.h: Update.
22148 * remote-utils.c (putpkt): Flush after debug output and use
22149 stderr.
22150 Handle input interrupts while waiting for an ACK.
22151 (input_interrupt): Use signal_pid method.
22152 (getpkt): Flush after debug output and use stderr.
22153 (outreg): Use collect_register_as_string.
22154 (new_thread_notify, dead_thread_notify): New functions.
22155 (prepare_resume_reply): Check using_threads. Set thread_from_wait
22156 and general_thread.
22157 (look_up_one_symbol): Flush after debug output.
22158 * server.c (step_thread, server_waiting): New variables.
22159 (start_inferior): Don't use signal_pid. Update call to mywait.
22160 (attach_inferior): Update call to mywait.
22161 (handle_query): Handle qfThreadInfo and qsThreadInfo.
22162 (main): Don't fetch/store registers explicitly. Use
22163 set_desired_inferior. Support proposed ``Hs'' packet. Update
22164 calls to mywait.
22165 * server.h: Update.
22166 (struct inferior_list, struct_inferior_list_entry): New.
22167 * target.c (set_desired_inferior): New.
22168 (write_inferior_memory): Constify.
22169 (mywait): New function.
22170 * target.h: Update.
22171 (struct target_ops): New signal_pid method.
22172 (mywait): Removed macro, added prototype.
22173
22174 * linux-low.h (regset_func): Removed.
22175 (regset_fill_func, regset_store_func): New.
22176 (enum regset_type): New.
22177 (struct regset_info): Add type field. Use new operation types.
22178 (struct linux_target_ops): stop_pc renamed to get_pc.
22179 Add decr_pc_after_break and breakpoint_at.
22180 (get_process, get_thread_proess, get_process_thread)
22181 (strut process_info, all_processes, linux_attach_lwp)
22182 (thread_db_init): New.
22183
22184 * linux-arm-low.c (arm_get_pc, arm_set_pc,
22185 arm_breakpoint, arm_breakpoint_len, arm_breakpoint_at): New.
22186 (the_low_target): Add new members.
22187 * linux-i386-low.c (i386_store_gregset, i386_store_fpregset)
22188 (i386_store_fpxregset): Constify.
22189 (target_regsets): Add new kind identifier.
22190 (i386_get_pc): Renamed from i386_stop_pc. Simplify.
22191 (i386_set_pc): Add debugging.
22192 (i386_breakpoint_at): New function.
22193 (the_low_target): Add new members.
22194 * linux-mips-low.c (mips_get_pc, mips_set_pc)
22195 (mips_breakpoint, mips_breakpoint_len, mips_reinsert_addr)
22196 (mips_breakpoint_at): New.
22197 (the_low_target): Add new members.
22198 * linux-ppc-low.c (ppc_get_pc, ppc_set_pc)
22199 (ppc_breakpoint, ppc_breakpoint_len, ppc_breakpoint_at): New.
22200 (the_low_target): Add new members.
22201 * linux-sh-low.c (sh_get_pc, sh_set_pc)
22202 (sh_breakpoint, sh_breakpoint_len, sh_breakpoint_at): New.
22203 (the_low_target): Add new members.
22204 * linux-x86-64-low.c (target_regsets): Add new kind
22205 identifier.
22206
222072002-05-15 Daniel Jacobowitz <drow@mvista.com>
22208
22209 From Martin Pool <mbp@samba.org>:
22210 * server.c (gdbserver_usage): New function.
22211 (main): Call it.
22212
222132002-05-14 Daniel Jacobowitz <drow@mvista.com>
22214
22215 * mem-break.c (reinsert_breakpoint_by_bp): Correct typo
22216 stop_at -> stop_pc.
22217
222182002-05-04 Andrew Cagney <ac131313@redhat.com>
22219
22220 * Makefile.in: Remove obsolete code.
22221
222222002-04-24 Michal Ludvig <mludvig@suse.cz>
22223
22224 * linux-low.c (regsets_fetch_inferior_registers),
22225 (regsets_store_inferior_registers): Removed cast to int from
22226 ptrace() calls.
22227 * regcache.h: Added declaration of struct inferior_info.
22228
222292002-04-20 Daniel Jacobowitz <drow@mvista.com>
22230
22231 * inferiors.c (struct inferior_info): Add regcache_data.
22232 (add_inferior): Call create_register_cache.
22233 (clear_inferiors): Call free_register_cache.
22234 (inferior_regcache_data, set_inferior_regcache_data): New functions.
22235 * regcache.c (struct inferior_regcache_data): New.
22236 (registers): Remove.
22237 (get_regcache): New function.
22238 (create_register_cache, free_register_cache): New functions.
22239 (set_register_cache): Don't initialize the register cache here.
22240 (registers_to_string, registers_from_string, register_data): Call
22241 get_regcache.
22242 * regcache.h: Add prototypes.
22243 * server.h: Likewise.
22244
222452002-04-20 Daniel Jacobowitz <drow@mvista.com>
22246
22247 * mem-break.c: New file.
22248 * mem-break.h: New file.
22249 * Makefile.in: Add mem-break.o rule; update server.h
22250 dependencies.
22251 * inferiors.c (struct inferior_info): Add target_data
22252 member.
22253 (clear_inferiors): Free target_data member if set.
22254 (inferior_target_data, set_inferior_target_data): New functions.
22255 * linux-i386-low.c (i386_breakpoint, i386_breakpoint_len)
22256 (i386_stop_pc, i386_set_pc): New. Add to the_low_target.
22257 * linux-low.c (linux_bp_reinsert): New variable.
22258 (struct inferior_linux_data): New.
22259 (linux_create_inferior): Use set_inferior_target_data.
22260 (linux_attach): Likewise. Call add_inferior.
22261 (linux_wait_for_one_inferior): New function.
22262 (linux_wait): Call it.
22263 (linux_write_memory): Add const.
22264 (initialize_low): Call set_breakpoint_data.
22265 * linux-low.h (struct linux_target_ops): Add breakpoint
22266 handling members.
22267 * server.c (attach_inferior): Remove extra add_inferior
22268 call.
22269 * server.h: Include mem-break.h. Update inferior.c
22270 prototypes.
22271 * target.c (read_inferior_memory)
22272 (write_inferior_memory): New functions.
22273 * target.h (read_inferior_memory)
22274 (write_inferior_memory): Change macros to prototypes.
22275 (struct target_ops): Update comments. Add const to write_memory
22276 definition.
22277
222782002-04-11 Daniel Jacobowitz <drow@mvista.com>
22279
22280 * linux-low.c (usr_store_inferior_registers): Support
22281 registers which are allowed to fail to store.
22282 * linux-low.h (linux_target_ops): Likewise.
22283 * linux-ppc-low.c (ppc_regmap): Support FPSCR.
22284 (ppc_cannot_store_register): FPSCR may not be storable.
22285
222862002-04-09 Daniel Jacobowitz <drow@mvista.com>
22287
22288 * server.h: Include <string.h> if HAVE_STRING_H.
22289 * ChangeLog: Correct paths in last ChangeLog entry.
22290
222912002-04-09 Daniel Jacobowitz <drow@mvista.com>
22292
22293 * linux-low.h: Remove obsolete prototypes.
22294 (struct linux_target_ops): New.
22295 (extern the_low_target): New.
22296 * linux-low.c (num_regs, regmap): Remove declarations.
22297 (register_addr): Use the_low_target explicitly.
22298 (fetch_register): Likewise.
22299 (usr_fetch_inferior_registers): Likewise.
22300 (usr_store_inferior_registers): Likewise.
22301 * linux-arm-low.c (num_regs): Remove.
22302 (arm_num_regs): Define.
22303 (arm_regmap): Renamed from regmap, made static.
22304 (arm_cannot_fetch_register): Renamed from cannot_fetch_register,
22305 made static.
22306 (arm_cannot_store_register): Renamed from cannot_store_register,
22307 made static.
22308 (the_low_target): New.
22309 * linux-i386-low.c (num_regs): Remove.
22310 (i386_num_regs): Define.
22311 (i386_regmap): Renamed from regmap, made static.
22312 (i386_cannot_fetch_register): Renamed from cannot_fetch_register,
22313 made static.
22314 (i386_cannot_store_register): Renamed from cannot_store_register,
22315 made static.
22316 (the_low_target): New.
22317 * linux-ia64-low.c (num_regs): Remove.
22318 (ia64_num_regs): Define.
22319 (ia64_regmap): Renamed from regmap, made static.
22320 (ia64_cannot_fetch_register): Renamed from cannot_fetch_register,
22321 made static.
22322 (ia64_cannot_store_register): Renamed from cannot_store_register,
22323 made static.
22324 (the_low_target): New.
22325 * linux-m68k-low.c (num_regs): Remove.
22326 (m68k_num_regs): Define.
22327 (m68k_regmap): Renamed from regmap, made static.
22328 (m68k_cannot_fetch_register): Renamed from cannot_fetch_register,
22329 made static.
22330 (m68k_cannot_store_register): Renamed from cannot_store_register,
22331 made static.
22332 (the_low_target): New.
22333 * linux-mips-low.c (num_regs): Remove.
22334 (mips_num_regs): Define.
22335 (mips_regmap): Renamed from regmap, made static.
22336 (mips_cannot_fetch_register): Renamed from cannot_fetch_register,
22337 made static.
22338 (mips_cannot_store_register): Renamed from cannot_store_register,
22339 made static.
22340 (the_low_target): New.
22341 * linux-ppc-low.c (num_regs): Remove.
22342 (ppc_num_regs): Define.
22343 (ppc_regmap): Renamed from regmap, made static.
22344 (ppc_cannot_fetch_register): Renamed from cannot_fetch_register,
22345 made static.
22346 (ppc_cannot_store_register): Renamed from cannot_store_register,
22347 made static.
22348 (the_low_target): New.
22349 * linux-s390-low.c (num_regs): Remove.
22350 (s390_num_regs): Define.
22351 (s390_regmap): Renamed from regmap, made static.
22352 (s390_cannot_fetch_register): Renamed from cannot_fetch_register,
22353 made static.
22354 (s390_cannot_store_register): Renamed from cannot_store_register,
22355 made static.
22356 (the_low_target): New.
22357 * linux-sh-low.c (num_regs): Remove.
22358 (sh_num_regs): Define.
22359 (sh_regmap): Renamed from regmap, made static.
22360 (sh_cannot_fetch_register): Renamed from cannot_fetch_register,
22361 made static.
22362 (sh_cannot_store_register): Renamed from cannot_store_register,
22363 made static.
22364 (the_low_target): New.
22365 * linux-x86-64-low.c (x86_64_regmap): Renamed from regmap.
22366 (the_low_target): New.
22367
223682002-04-09 Daniel Jacobowitz <drow@mvista.com>
22369
22370 * Makefile.in: Add stamp-h target.
22371 * configure.in: Create stamp-h.
22372 * configure: Regenerated.
22373
223742002-04-09 Daniel Jacobowitz <drow@mvista.com>
22375
22376 * inferiors.c: New file.
22377 * target.c: New file.
22378 * target.h: New file.
22379 * Makefile.in: Add target.o and inferiors.o. Update
22380 dependencies.
22381 * linux-low.c (inferior_pid): New static variable,
22382 moved from server.c.
22383 (linux_create_inferior): Renamed from create_inferior.
22384 Call add_inferior. Return 0 on success instead of a PID.
22385 (linux_attach): Renamed from myattach.
22386 (linux_kill): Renamed from kill_inferior. Call clear_inferiors ().
22387 (linux_thread_alive): Renamed from mythread_alive.
22388 (linux_wait): Renamed from mywait. Call clear_inferiors () if the
22389 child dies.
22390 (linux_resume): Renamed from myresume. Add missing ``return 0''.
22391 (regsets_store_inferior_registers): Correct error message.
22392 Add missing ``return 0''.
22393 (linux_fetch_registers): Renamed from fetch_inferior_registers.
22394 (linux_store_registers): Renamed from store_inferior_registers.
22395 (linux_read_memory): Renamed from read_inferior_memory.
22396 (linux_write_memory): Renamed from write_inferior_memory.
22397 (linux_target_ops): New structure.
22398 (initialize_low): Call set_target_ops ().
22399 * remote-utils.c (unhexify): New function.
22400 (hexify): New function.
22401 (input_interrupt): Send signals to ``signal_pid''.
22402 * server.c (inferior_pid): Remove.
22403 (start_inferior): Update create_inferior call.
22404 (attach_inferior): Call add_inferior.
22405 (handle_query): New function.
22406 (main): Call handle_query for `q' packets.
22407 * server.h: Include "target.h". Remove obsolete prototypes.
22408 Add prototypes for "inferiors.c", "target.c", hexify, and unhexify.
22409
224102002-04-09 Daniel Jacobowitz <drow@mvista.com>
22411
22412 * Makefile.in: Add WARN_CFLAGS. Update configury
22413 dependencies.
22414 * configure.in: Check for <string.h>
22415 * configure: Regenerate.
22416 * config.in: Regenerate.
22417 * gdbreplay.c: Include needed system headers.
22418 (remote_open): Remove strchr prototype.
22419 * linux-low.h: Correct #ifdef to HAVE_LINUX_USRREGS.
22420 * regcache.c (supply_register): Change buf argument to const void *.
22421 (supply_register_by_name): Likewise.
22422 (collect_register): Change buf argument to void *.
22423 (collect_register_by_name): Likewise.
22424 * regcache.h: Add missing prototypes.
22425 * remote-utils.c: Include <arpa/inet.h> for inet_ntoa.
22426 * server.c (handle_query): New function.
22427 (attached): New static variable, moved out of main.
22428 (main): Quiet longjmp clobber warnings.
22429 * server.h: Add ATTR_NORETURN and ATTR_FORMAT. Update prototypes.
22430 * utils.c (error): Remove NORETURN.
22431 (fatal): Likewise.