gdb/infcmd: remove redundant clear_proceed_status call
[deliverable/binutils-gdb.git] / gdbserver / ChangeLog
CommitLineData
2be01f63
KR
12020-10-07 Kamil Rytarowski <n54@gmx.com>
2
3 * netbsd-low.cc: Fix whitespace formatting.
4 * netbsd-amd64-low.cc: Likewise.
5
91e5e8db
KR
62020-10-07 Kamil Rytarowski <n54@gmx.com>
7
8 * netbsd-low.cc (netbsd_process_target::read_memory)
9 (netbsd_process_target::write_memory): Update.
10
9529c852
KR
112020-10-07 Kamil Rytarowski <n54@gmx.com>
12
13 * netbsd-aarch64-low.cc: Add.
14 * Makefile.in (SFILES): Register "netbsd-aarch64-low.c".
15 * configure.srv: Add aarch64*-*-netbsd*.
16
981b570a
SV
172020-10-06 Shahab Vahedi <shahab@synopsys.com>
18
19 * regcache.cc (register_data): Remove unused "fetch" argument.
20
6b01403b
SM
212020-10-02 Simon Marchi <simon.marchi@polymtl.ca>
22
23 * server.cc (handle_monitor_command): Handle "set
24 debug-event-loop".
25 (captured_main): Handle "--debug-event-loop".
26 (monitor_show_help): Mention new setting.
27 (gdbserver_usage): Mention new flag.
28
2554f6f5
SM
292020-10-02 Simon Marchi <simon.marchi@polymtl.ca>
30
31 * linux-low.cc (linux_process_target::async): Pass name to
32 add_file_handler.
33 * remote-utils.cc (handle_accept_event): Likewise.
34 (remote_open): Likewise.
35
8b667fae
KR
362020-10-01 Kamil Rytarowski <n54@gmx.com>
37
38 * netbsd-i386-low.cc: Add.
39 * Makefile.in (SFILES): Register "netbsd-i386-low.c".
40 * configure.srv: Add i[34567]86-*-netbsd*.
41
15397b0e
KR
422020-10-01 Kamil Rytarowski <n54@gmx.com>
43
44 * netbsd-amd64-low.cc (netbsd_x86_64_arch_setup): Remove.
45 (netbsd_target_regsets): Now const.
46 (the_low_target): Remove.
47 (class netbsd_amd64_target, the_netbsd_amd64_target)
48 (the_netbsd_target): Add.
49 * netbsd-low.cc (netbsd_process_target::post_create_inferior): Call
50 low_arch_setup ().
51 (netbsd_process_target::fetch_registers)
52 (netbsd_process_target::store_registers, initialize_low): Update.
53 (the_netbsd_target): Remove.
54 * netbsd-low.h (netbsd_target_regsets, netbsd_target_ops)
55 (the_low_target, netbsd_tdesc): Remove.
56 (netbsd_process_target::get_regs_info)
57 (netbsd_process_target::low_arch_setup): Add.
58
99bb393f
HD
592020-09-23 Hannes Domani <ssbssa@yahoo.de>
60
61 * win32-low.cc: Remove local wow64_process variable.
62 * win32-low.h: Remove local wow64_process variable.
63
b60cea74
TT
642020-09-18 Tom Tromey <tromey@adacore.com>
65
66 * netbsd-low.h (class netbsd_process_target) <wait>: Update.
67 * netbsd-low.cc (netbsd_waitpid, netbsd_wait)
68 (netbsd_process_target::wait): Change type of target_options.
69 * win32-low.h (class win32_process_target) <wait>: Update.
70 * win32-low.cc (win32_process_target::wait): Update.
71 * target.h (class process_stratum_target) <wait>: Update.
72 (mywait): Update.
73 * target.cc (mywait, target_wait): Change type of "options".
74 * linux-low.h (class linux_process_target) <wait, wait_1>:
75 Update.
76 * linux-low.cc (linux_process_target::wait)
77 (linux_process_target::wait_1): Update.
78
db92ac45
TT
792020-09-15 Tom Tromey <tromey@adacore.com>
80
81 * linux-x86-low.cc (xmltarget_i386_linux_no_xml)
82 (xmltarget_amd64_linux_no_xml): Now arrays.
83
27087b7f
TT
842020-09-14 Tom Tromey <tromey@adacore.com>
85
86 * tracepoint.cc (eval_result_names): Now const.
87 * ax.cc (gdb_agent_op_names): Now const.
88
62ba5048
KR
892020-09-10 Kamil Rytarowski <n54@gmx.com>
90
91 * netbsd-low.cc: Add.
92 * netbsd-low.h: Likewise.
93 * netbsd-amd64-low.cc: Likewise.
94 * Makefile.in (SFILES): Register "netbsd-low.cc", "netbsd-low.h",
95 "netbsd-amd64-low.cc".
96 * configure.srv: Add x86_64-*-netbsd*.
97
ece5bc8a
SM
982020-08-13 Simon Marchi <simon.marchi@polymtl.ca>
99
100 * server.cc (captured_main): Accept multiple `--selftest=`
101 options. Pass all `--selftest=` arguments to run_tests.
102
c8693053
RO
1032020-07-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
104
105 * configure, config.in: Regenerate.
106
05a6b8c2
EZ
1072020-07-26 Eli Zaretskii <eliz@gnu.org>
108
109 * configure.ac (AC_CHECK_HEADERS): Add ws2tcpip.h.
110 When checking whether socklen_t type is defined, use ws2tcpip.h if
111 it is available and sys/socket.h isn't.
112 * configure: Regenerate.
113 * config.in: Regenerate.
114
028a4603
PA
1152020-07-22 Pedro Alves <pedro@palves.net>
116
117 * inferiors.cc (switch_to_process): New, moved here from
118 thread-db.cc, and made extern.
119 * inferiors.h (switch_to_process): Declare.
120 * server.cc: Include "gdbsupport/scoped_restore.h".
121 (handle_qxfer_threads_proper): Now returns bool. Prepare to
122 access memory around target calls.
123 (handle_qxfer_threads): Handle errors.
124 * thread-db.cc (switch_to_process): Moved to inferiors.cc.
125
05c309a8
SM
1262020-07-21 Simon Marchi <simon.marchi@efficios.com>
127
128 * linux-low.cc (stopped_pids): Make static.
129
0e267416
AB
1302020-07-17 Andrew Burgess <andrew.burgess@embecosm.com>
131
132 * tdesc.cc (allocate_target_description): Add header comment.
133 (target_desc_deleter::operator()): New function.
134 * tdesc.h (struct target_desc): Declare as final.
135
b315b67d
SM
1362020-07-13 Simon Marchi <simon.marchi@polymtl.ca>
137
138 * server.cc (handle_query): Use std::vector of
139 std::string for `qsupported` vector. Use separate
140 vector for unknowns.
141 * target.h (class process_stratum_target) <process_qsupported>:
142 Change parameters to array_view of const char *.
143 (target_process_qsupported): Remove `count` parameter.
144 * target.cc (process_stratum_target::process_qsupported): Change
145 parameters to array_view of const char *.
146 * linux-x86-low.cc (class x86_target) <process_qsupported>:
147 Likewise.
148
f638ed73
TV
1492020-06-29 Tom de Vries <tdevries@suse.de>
150
151 * ax.h: Include gdbsupport/debug_agent.h.
152
fbf42f4e
AB
1532020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
154
155 * tdesc.cc (struct tdesc_compatible_info): New struct.
156 (tdesc_compatible_info_list): New function.
157 (tdesc_compatible_info_arch_name): New function.
158
013e3554
TBA
1592020-06-22 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
160
161 Use std::list to stop pending signal instead of manually-created
162 linked list.
163 * linux-low.h: Include <list>.
164 (struct pending_signal): Move here from linux-low.cc.
165 (struct lwp_info) <pending_signals>
166 <pending_signals_to_report>: Update the type.
167 * linux-low.cc (struct pending_signals): Remove.
168 (linux_process_target::delete_lwp)
169 (linux_process_target::add_lwp)
170 (enqueue_one_deferred_signal)
171 (dequeue_one_deferred_signal)
172 (enqueue_pending_signal)
173 (linux_process_target::resume_one_lwp_throw)
174 (linux_process_target::thread_needs_step_over)
175 (linux_process_target::resume_one_thread)
176 (linux_process_target::proceed_one_lwp): Update the use of pending
177 signal list.
178
7d458ea5
SM
1792020-06-17 Simon Marchi <simon.marchi@efficios.com>
180
181 * Makefile.in (%-generated.cc: ../gdb/regformats/arm/%.dat):
182 Remove.
183
84b300de
SM
1842020-06-12 Simon Marchi <simon.marchi@efficios.com>
185
186 * Makefile.in (SFILES): Remove win32-arm-low.cc, wincecompat.cc.
187 * configure.srv: Remove mingw32ce cases.
188 * server.h, win32-low.cc: Remove __MINGW32CE__-guarded code.
189 * win32-low.h (to_back_slashes): Remove.
190 * win32-arm-low.cc, wincecompat.cc, wincecompat.h: Remove.
191
96c16e2b
SM
1922020-06-12 Simon Marchi <simon.marchi@efficios.com>
193
194 * Makefile.in (SFILES): linux-tile-low.cc.
195 * configure.srv: Remove tilegx case.
196 * linux-tile-low.cc: Remove.
197
bd1467ae
SM
1982020-06-12 Simon Marchi <simon.marchi@efficios.com>
199
200 * Makefile.in (SFILES): Remove linux-m32r-low.cc.
201 * configure.srv: Remove m32r case.
202 * linux-m32r-low.cc: Remove.
203
7b46bf6f
SM
2042020-06-12 Simon Marchi <simon.marchi@efficios.com>
205
206 * Makefile.in (SFILES): Remove linux-cris-low.c.
207 * configure.srv: Remove cris cases.
208 * linux-cris-low.cc, linux-crisv32-low.cc: Remove.
209
1fa29f56
SM
2102020-06-12 Simon Marchi <simon.marchi@efficios.com>
211
212 * Makefile.in (SFILES): Remove linux-bfin-low.c.
213 * configure.srv: Remove bfin case.
214 * linux-bfin-low.cc: Remove.
215 * linux-low.cc: Remove BFIN-conditional code.
216
613f149a
SM
2172020-06-12 Simon Marchi <simon.marchi@efficios.com>
218
219 * configure: Re-generate.
220 * configure.ac: Remove srv_qnx test.
221 * configure.srv: Remove nto case.
222 * nto-low.cc, nto-low.h, nto-x86-low.cc: Remove.
223 * remote-utils.c: Remove __QNX__-guarded code.
224
fdb95bf5
SM
2252020-06-12 Simon Marchi <simon.marchi@efficios.com>
226
227 * configure: Re-generate.
228 * configure.ac: Remove srv_lynxos test.
229 * configure.srv: Remove lynxos cases.
230 * lynx-i386-low.cc, lynx-low.cc, lynx-low.h, lynx-ppc-low.c:
231 Remove.
232
c00094dc
SM
2332020-06-12 Simon Marchi <simon.marchi@efficios.com>
234
235 * README: Fix a few outdated or incoherent things.
236
6479bf85
HD
2372020-05-27 Hannes Domani <ssbssa@yahoo.de>
238
239 * win32-low.cc (do_initial_child_stuff): Set open_process_used.
240 (win32_clear_inferiors): Use open_process_used.
241 (get_child_debug_event): Likewise.
242
bea571eb
MW
2432020-05-25 Michael Weghorn <m.weghorn@posteo.de>
244
245 PR gdbserver/25893
246 * linux-low.cc (linux_process_target::create_inferior),
247 lynx-low.cc (lynx_process_target::create_inferior),
248 win32-low.cc (win32_process_target::create_inferior): Use
249 construct_inferior_arguments instead of stringify_argv
250 to get string representation which properly escapes
251 special characters.
252 * server.cc (handle_v_run): Just pass empty program arg
253 as such, since any further processing is now handled via
254 construct_inferior_arguments.
255
ace6b919
MW
2562020-05-25 Michael Weghorn <m.weghorn@posteo.de>
257
258 * nto-low.cc (nto_process_target::create_inferior): Pass
259 argv to spawnp function as char **.
260
b69ca137
MW
2612020-05-25 Michael Weghorn <m.weghorn@posteo.de>
262
263 * server.cc (captured_main), (handle_v_run): No longer
264 insert extra NULL element to args vector.
265
51e2cfa2
PA
2662020-05-23 Pedro Alves <palves@redhat.com>
267
268 * gdb-safe-ctype.h: New.
269
8bbf0394
TBA
2702020-05-16 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
271
272 * linux-ia64-low.cc (ia64_target::sw_breakpoint_from_kind):
273 Fix incorrect 'gdb_assert_no_reached' to 'gdb_assert_not_reached'.
274 (ia64_target::low_breakpoint_at): Ditto.
275
01370779
HD
2762020-05-15 Hannes Domani <ssbssa@yahoo.de>
277
278 * win32-i386-low.cc (i386_supports_z_point_type): Handle
279 Z_PACKET_HW_BP z_type.
280 (i386_insert_point): Handle raw_bkpt_type type.
281 (i386_remove_point): Likewise.
282
7d186bc0
HD
2832020-04-30 Hannes Domani <ssbssa@yahoo.de>
284
285 * configure.srv <x86_64-*-mingw*, x86_64-*-cygwin*> (srv_tgtobj):
286 Add arch/i386.o.
287 * win32-arm-low.cc (arm_num_regs): New function.
288 (struct win32_target_ops): Use arm_num_regs.
289 * win32-i386-low.cc (win32_get_current_dr): Adapt for WOW64
290 processes.
291 (i386_get_thread_context): Likewise.
292 (i386_prepare_to_resume): Likewise.
293 (i386_thread_added): Likewise.
294 (i386_single_step): Likewise.
295 (i386_fetch_inferior_register): Likewise.
296 (i386_store_inferior_register): Likewise.
297 (i386_arch_setup): Likewise.
298 (i386_win32_num_regs): New function.
299 (struct win32_target_ops): Use i386_win32_num_regs.
300 * win32-low.cc (win32_get_thread_context): Adapt for WOW64
301 processes.
302 (win32_require_context): Likewise.
303 (child_add_thread): Likewise.
304 (do_initial_child_stuff): Likewise.
305 (continue_one_thread): Likewise.
306 (win32_process_target::resume): Likewise.
307 (load_psapi): Likewise.
308 (win32_add_all_dlls): Likewise.
309 (maybe_adjust_pc): Likewise.
310 (win32_process_target::qxfer_siginfo): Likewise.
311 (initialize_low): Likewise.
312 * win32-low.h (struct win32_target_ops): Change num_regs to
313 callback function.
314
1eb39914
SM
3152020-04-27 Simon Marchi <simon.marchi@efficios.com>
316
317 * configure.ac: Remove check for fs_base/gs_base in
318 user_regs_struct.
319 * configure: Re-generate.
320 * config.in: Re-generate.
321 * linux-x86-low.cc (x86_64_regmap, x86_fill_gregset,
322 x86_store_gregset): Adjust.
323
51ac8e22
HD
3242020-04-22 Hannes Domani <ssbssa@yahoo.de>
325
326 * server.cc (handle_search_memory_1): Fix gdb_read_memory return value
327 comparison.
328
a010605f
TT
3292020-04-16 Tom Tromey <tromey@adacore.com>
330
331 * win32-low.cc (windows_nat::handle_access_violation): New
332 function.
333
e2275c6e
SM
3342020-04-15 Simon Marchi <simon.marchi@polymtl.ca>
335
336 * win32-low.cc (get_child_debug_event): Fix format string warning.
337
73944e9f
TT
3382020-04-13 Tom Tromey <tom@tromey.com>
339
340 * server.h (gdb_fildes_t): Remove typedef.
341 * remote-utils.c (remote_desc, list_desc): Now int.
342 (INVALID_DESCRIPTOR): Remove.
343 (gdb_connected, remote_close)
344 (check_remote_input_interrupt_request): Update.
345 * utils.h (pfildes): Don't declare.
346 * utils.c (pfildes): Remove.
347
55d7aec8
TT
3482020-04-13 Tom Tromey <tom@tromey.com>
349
350 * server.h (handle_serial_event, handle_target_event): Update.
351 * server.c: Don't call initialize_event_loop.
352 (keep_processing_events): New global.
353 (handle_serial_event): Return void. Set keep_processing_events.
354 (handle_target_event): Return void.
355 (start_event_loop): Move from event-loop.c. Rewrite.
356 * remote-utils.c (handle_accept_event): Return void.
357 (reset_readchar): Use delete_timer.
358 (process_remaining): Return void.
359 (reschedule): Use create_timer.
360 * event-loop.h: Remove.
361 * event-loop.cc: Remove.
362 * Makefile.in (OBS): Use gdbsupport/event-loop.o, not event-loop.o.
363
e487f994
TT
3642020-04-13 Tom Tromey <tom@tromey.com>
365
366 * server.c (invoke_async_signal_handlers)
367 (check_async_event_handlers, flush_streams, gdb_select): New
368 functions.
369
8ae8e197
TT
3702020-04-13 Tom Tromey <tom@tromey.com>
371
372 * configure: Rebuild.
373 * config.in: Rebuild.
374
360ad8b3
TT
3752020-04-08 Tom Tromey <tromey@adacore.com>
376
377 PR gdb/22992
378 * win32-low.c (child_continue): Call matching_pending_stop.
379 (get_child_debug_event): Call fetch_pending_stop. Push pending
380 stop when needed.
381
523d4f80
TT
3822020-04-08 Tom Tromey <tromey@adacore.com>
383
384 * win32-low.h (win32_process_target::stopped_by_sw_breakpoint)
385 (win32_process_target::supports_stopped_by_sw_breakpoint):
386 Declare.
387 * win32-low.c (win32_supports_z_point_type): Always handle
388 Z_PACKET_SW_BP.
389 (win32_insert_point): Call insert_memory_breakpoint when needed.
390 (win32_remove_point): Call remove_memory_breakpoint when needed.
391 (win32_process_target::stopped_by_sw_breakpoint)
392 (win32_process_target::supports_stopped_by_sw_breakpoint): New
393 methods.
394 (win32_target_ops): Update.
395 (maybe_adjust_pc): New function.
396 (win32_wait): Call maybe_adjust_pc.
397
e54e5929
TT
3982020-04-08 Tom Tromey <tromey@adacore.com>
399
400 * win32-low.h (struct win32_target_ops) <decr_pc_after_break>: New
401 field.
402 * win32-i386-low.c (the_low_target): Update.
403 * win32-arm-low.c (the_low_target): Update.
404
d6225aff
TT
4052020-04-08 Tom Tromey <tromey@adacore.com>
406
407 * win32-low.h (win32_process_target::read_pc)
408 (win32_process_target::write_pc): Declare.
409 * win32-low.c (win32_process_target::read_pc)
410 (win32_process_target::write_pc): New methods.
411 * win32-i386-low.c (i386_win32_get_pc, i386_win32_set_pc): New
412 functions.
413 (the_low_target): Update.
414 * win32-arm-low.c (arm_win32_get_pc, arm_win32_set_pc): New
415 functions.
416 (the_low_target): Update.
417
2c1d95e8
TT
4182020-04-08 Tom Tromey <tromey@adacore.com>
419
420 * win32-low.c (win32_kill, get_child_debug_event): Use
421 wait_for_debug_event.
422
e758e19c
TT
4232020-04-08 Tom Tromey <tromey@adacore.com>
424
425 * win32-low.c (child_continue): Call continue_last_debug_event.
426
8d30e395
TT
4272020-04-08 Tom Tromey <tromey@adacore.com>
428
429 * win32-low.c (handle_exception): Remove.
430 (windows_nat::handle_ms_vc_exception): New function.
431 (get_child_debug_event): Add "continue_status" parameter.
432 Update.
433 (win32_wait): Update.
434
a816ba18
TT
4352020-04-08 Tom Tromey <tromey@adacore.com>
436
437 * win32-low.c (windows_nat::handle_load_dll): Rename from
438 handle_load_dll. No longer static.
439 (windows_nat::handle_unload_dll): Rename from handle_unload_dll.
440 No longer static.
441
d41b524f
TT
4422020-04-08 Tom Tromey <tromey@adacore.com>
443
444 * win32-low.c (handle_output_debug_string): Add parameter. Change
445 return type.
446 (win32_kill, get_child_debug_event): Update.
447
3c76026d
TT
4482020-04-08 Tom Tromey <tromey@adacore.com>
449
450 * win32-low.c (current_process_handle, current_process_id)
451 (main_thread_id, last_sig, current_event, siginfo_er): Move to
452 nat/windows-nat.c.
453
9d8679cc
TT
4542020-04-08 Tom Tromey <tromey@adacore.com>
455
456 * win32-low.c (get_image_name): Remove.
457 (handle_load_dll): Update.
458
28688adf
TT
4592020-04-08 Tom Tromey <tromey@adacore.com>
460
461 * win32-low.c (windows_nat::thread_rec): Rename from thread_rec.
462 No longer static. Change parameters.
463 (child_add_thread, child_fetch_inferior_registers)
464 (child_store_inferior_registers, win32_resume)
465 (win32_get_tib_address): Update.
466
4834dad0
TT
4672020-04-08 Tom Tromey <tromey@adacore.com>
468
469 * win32-low.h (struct win32_target_ops): Use qualified names where
470 needed.
471 * win32-i386-low.c: Add "using namespace".
472 * win32-low.c: Add "using namespace".
473 * win32-arm-low.c: Add "using namespace".
474
65bafd5b
TT
4752020-04-08 Tom Tromey <tromey@adacore.com>
476
477 * win32-low.c (delete_thread_info): Don't call CloseHandle.
478
98a03287
TT
4792020-04-08 Tom Tromey <tromey@adacore.com>
480
481 * win32-low.c (win32_require_context, suspend_one_thread): Use
482 windows_thread_info::suspend.
483 (continue_one_thread): Use windows_thread_info::resume.
484 * configure.srv (srv_tgtobj): Add windows-nat.o when needed.
485
62fe396b
TT
4862020-04-08 Tom Tromey <tromey@adacore.com>
487
488 * win32-i386-low.c (update_debug_registers)
489 (i386_prepare_to_resume, i386_thread_added): Update.
490
e9534bd2
TT
4912020-04-08 Tom Tromey <tromey@adacore.com>
492
493 * win32-low.c (child_add_thread): Use new.
494 (delete_thread_info): Use delete.
495
ae1f8880
TT
4962020-04-08 Tom Tromey <tromey@adacore.com>
497
498 * win32-low.h (struct windows_thread_info): Remove.
499
e56f8ccb
TT
5002020-04-08 Tom Tromey <tromey@adacore.com>
501
502 * win32-low.h (struct windows_thread_info): Rename from
503 win32_thread_info. Remove typedef.
504 (struct win32_target_ops, win32_require_context): Update.
505 * win32-low.c (win32_get_thread_context)
506 (win32_set_thread_context, win32_prepare_to_resume)
507 (win32_require_context, thread_rec, child_add_thread)
508 (delete_thread_info, continue_one_thread)
509 (child_fetch_inferior_registers, child_store_inferior_registers)
510 (win32_resume, suspend_one_thread, win32_get_tib_address):
511 Update.
512 * win32-i386-low.c (update_debug_registers)
513 (win32_get_current_dr, i386_get_thread_context)
514 (i386_prepare_to_resume, i386_thread_added, i386_single_step)
515 (i386_fetch_inferior_register, i386_store_inferior_register):
516 Update.
517 * win32-arm-low.c (arm_get_thread_context)
518 (arm_fetch_inferior_register, arm_store_inferior_register):
519 Update.
520
0dd7b52e
TBA
5212020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
522
523 * linux-low.h (struct linux_target_ops): Remove.
524 (the_low_target): Remove.
525 * linux-x86-low.cc (the_low_target): Remove.
526 * linux-aarch64-low.cc (the_low_target): Ditto.
527 * linux-arm-low.cc (the_low_target): Ditto.
528 * linux-bfin-low.cc (the_low_target): Ditto.
529 * linux-cris-low.cc (the_low_target): Ditto.
530 * linux-crisv32-low.cc (the_low_target): Ditto.
531 * linux-ia64-low.cc (the_low_target): Ditto.
532 * linux-m32r-low.cc (the_low_target): Ditto.
533 * linux-m68k-low.cc (the_low_target): Ditto.
534 * linux-mips-low.cc (the_low_target): Ditto.
535 * linux-nios2-low.cc (the_low_target): Ditto.
536 * linux-ppc-low.cc (the_low_target): Ditto.
537 * linux-riscv-low.cc (the_low_target): Ditto.
538 * linux-s390-low.cc (the_low_target): Ditto.
539 * linux-sh-low.cc (the_low_target): Ditto.
540 * linux-sparc-low.cc (the_low_target): Ditto.
541 * linux-tic6x-low.cc (the_low_target): Ditto.
542 * linux-tile-low.cc (the_low_target): Ditto.
543 * linux-xtensa-low.cc (the_low_target): Ditto.
544
fc5ecdb6
TBA
5452020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
546
547 Remove the 'get_ipa_tdesc_idx' linux target op and let a concrete
548 linux target define the op by overriding the declaration in
549 process_stratum_target.
550
551 * linux-low.h (struct linux_target_ops): Remove the op.
552 (class linux_process_target) <get_ipa_tdesc_idx>: Remove.
553 * linux-low.cc (linux_process_target::get_ipa_tdesc_idx): Remove.
554 * linux-x86-low.cc (class x86_target) <get_ipa_tdesc_idx>: Declare.
555 (x86_get_ipa_tdesc_idx): Turn into...
556 (x86_target::get_ipa_tdesc_idx): ...this.
557 (the_low_target): Remove the op field.
558 * linux-ppc-low.cc (class ppc_target) <get_ipa_tdesc_idx>: Declare.
559 (ppc_get_ipa_tdesc_idx): Turn into...
560 (ppc_target::get_ipa_tdesc_idx): ...this.
561 (the_low_target): Remove the op field.
562 * linux-s390-low.cc (class s390_target) <get_ipa_tdesc_idx>: Declare.
563 (s390_get_ipa_tdesc_idx): Turn into...
564 (s390_target::get_ipa_tdesc_idx): ...this.
565 (the_low_target): Remove the op field.
566
9eedd27d
TBA
5672020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
568
569 Turn the 'get_syscall_trapinfo' linux target op into a method
570 of process_stratum_target.
571
572 * linux-low.h (struct linux_target_ops): Remove the op.
573 (class linux_process_target) <get_syscall_trapinfo>
574 <gdb_catch_this_syscall>
575 <low_supports_catch_syscall>
576 <low_get_syscall_trapinfo>: Declare.
577 * linux-low.cc (get_syscall_trapinfo): Turn into...
578 (linux_process_target::get_syscall_trapinfo): ...this.
579 (linux_process_target::low_get_syscall_trapinfo): Define.
580 (gdb_catch_this_syscall_p): Turn into...
581 (linux_process_target::gdb_catch_this_syscall): ...this.
582 (linux_process_target::low_supports_catch_syscall): Define.
583
584 Update the callers below.
585
586 (linux_process_target::wait_1)
587 (linux_process_target::supports_catch_syscall)
588
589 * linux-x86-low.cc (class x86_target) <low_supports_catch_syscall>
590 <low_get_syscall_trapinfo>: Declare.
591 (x86_target::low_supports_catch_syscall): Define.
592 (x86_get_syscall_trapinfo): Turn into...
593 (x86_target::low_get_syscall_trapinfo): ...this.
594 (the_low_target): Remove the op field.
595 * linux-aarch64-low.cc (class aarch64_target)
596 <low_supports_catch_syscall>
597 <low_get_syscall_trapinfo>: Declare.
598 (aarch64_target::low_supports_catch_syscall): Define.
599 (aarch64_get_syscall_trapinfo): Turn into...
600 (aarch64_target::low_get_syscall_trapinfo): ...this.
601 (the_low_target): Remove the op field.
602 * linux-arm-low.cc (class arm_target) <low_supports_catch_syscall>
603 <low_get_syscall_trapinfo>: Declare.
604 (arm_target::low_supports_catch_syscall): Define.
605 (arm_get_syscall_trapinfo): Turn into...
606 (arm_target::low_get_syscall_trapinfo): ...this.
607 (the_low_target): Remove the op field.
608 * linux-ppc-low.cc (the_low_target): Remove the op field.
609 * linux-s390-low.cc (the_low_target): Remove the op field.
610
b31cdfa6
TBA
6112020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
612
613 Remove the 'supports_hardware_single_step' linux target op and
614 override the process_stratum_target's op definition in
615 linux_process_target to return true.
616
617 * linux-low.h (struct linux_target_ops): Remove the op.
618 (class linux_process_target) <finish_step_over>
619 <maybe_hw_step>: Declare.
620 * linux-low.cc (can_hardware_single_step): Remove.
621 (maybe_hw_step): Turn into...
622 (linux_process_target::maybe_hw_step): ...this.
623 (finish_step_over): Turn into...
624 (linux_process_target::finish_step_over): ...this.
625 (linux_process_target::supports_hardware_single_step): Update
626 to return true.
627
628 Update the callers below.
629
630 (linux_process_target::single_step)
631 (linux_process_target::resume_one_lwp_throw)
632
633 * linux-arm-low.cc (class arm_target)
634 <supports_hardware_single_step>: Declare.
635 (arm_supports_hardware_single_step): Turn into...
636 (arm_target::supports_hardware_single_step): ...this.
637 (the_low_target): Remove the op field.
638 * linux-x86-low.cc (x86_supports_hardware_single_step): Remove.
639 (the_low_target): Remove the op field.
640 * linux-aarch64-low.cc (aarch64_supports_hardware_single_step):
641 Remove.
642 (the_low_target): Remove the op field.
643 * linux-bfin-low.cc (bfin_supports_hardware_single_step): Remove.
644 (the_low_target): Remove the op field.
645 * linux-crisv32-low.cc (cris_supports_hardware_single_step): Remove.
646 (the_low_target): Remove the op field.
647 * linux-m32r-low.cc (m32r_supports_hardware_single_step): Remove.
648 (the_low_target): Remove the op field.
649 * linux-m68k-low.cc (m68k_supports_hardware_single_step): Remove.
650 (the_low_target): Remove the op field.
651 * linux-ppc-low.cc (ppc_supports_hardware_single_step): Remove.
652 (the_low_target): Remove the op field.
653 * linux-s390-low.cc (s390_supports_hardware_single_step): Remove.
654 (the_low_target): Remove the op field.
655 * linux-sh-low.cc (sh_supports_hardware_single_step): Remove.
656 (the_low_target): Remove the op field.
657 * linux-tic6x-low.cc (tic6x_supports_hardware_single_step): Remove.
658 (the_low_target): Remove the op field.
659 * linux-tile-low.cc (tile_supports_hardware_single_step): Remove.
660 (the_low_target): Remove the op field.
661 * linux-xtensa-low.cc (xtensa_supports_hardware_single_step):
662 Remove.
663 (the_low_target): Remove the op field.
664
9cfd8715
TBA
6652020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
666
667 Turn the 'supports_range_stepping' linux target op into a method
668 of linux_process_target.
669
670 * linux-low.h (struct linux_target_ops): Remove the op.
671 (class linux_process_target) <low_supports_range_stepping>: Declare.
672 * linux-low.cc (linux_process_target::low_supports_range_stepping):
673 Define.
674 (linux_process_target::supports_range_stepping): Update the call
675 site.
676 * linux-x86-low.cc (class x86_target)
677 <low_supports_range_stepping>: Declare.
678 (x86_supports_range_stepping): Turn into...
679 (x86_target::low_supports_range_stepping): ...this.
680 (the_low_target): Remove the op field.
681 * linux-aarch64-low.cc (class aarch64_target)
682 <low_supports_range_stepping>: Declare.
683 (aarch64_supports_range_stepping): Turn into...
684 (aarch64_target::low_supports_range_stepping): ...this.
685 (the_low_target): Remove the op field.
686 * linux-arm-low.cc (the_low_target): Remove the op field.
687 * linux-bfin-low.cc (the_low_target): Ditto.
688 * linux-crisv32-low.cc (the_low_target): Ditto.
689 * linux-m32r-low.cc (the_low_target): Ditto.
690 * linux-m68k-low.cc (the_low_target): Ditto.
691 * linux-ppc-low.cc (the_low_target): Ditto.
692 * linux-s390-low.cc (the_low_target): Ditto.
693 * linux-sh-low.cc (the_low_target): Ditto.
694 * linux-tic6x-low.cc (the_low_target): Ditto.
695 * linux-tile-low.cc (the_low_target): Ditto.
696 * linux-xtensa-low.cc (the_low_target): Ditto.
697
ab64c999
TBA
6982020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
699
700 Remove the 'emit_ops' linux target ops and let the concrete
701 linux target define the op by overriding the declaration of
702 process_stratum_target.
703
704 * linux-low.h (struct linux_target_ops): Remove the op.
705 (class linux_process_target) <emit_ops>: Remove.
706 * linux-low.cc (linux_process_target::emit_ops): Remove.
707 * linux-x86-low.cc (class x86_target) <emit_ops>: Declare.
708 (x86_emit_ops): Turn into...
709 (x86_target::emit_ops): ...this.
710 (the_low_target): Remove the op field.
711 * linux-aarch64-low.cc (class aarch64_target) <emit_ops>: Declare.
712 (aarch64_emit_ops): Turn into...
713 (aarch64_target::emit_ops): ...this.
714 (the_low_target): Remove the op field.
715 * linux-ppc-low.cc (class ppc_target) <emit_ops>: Declare.
716 (ppc_emit_ops): Turn into...
717 (ppc_target::emit_ops): ...this.
718 (the_low_target): Remove the op field.
719 * linux-s390-low.cc (class s390_target) <emit_ops>: Declare.
720 (s390_emit_ops): Turn into...
721 (s390_target::emit_ops): ...this.
722 (the_low_target): Remove the op field.
723 * linux-arm-low.cc (the_low_target): Remove the op field.
724 * linux-bfin-low.cc (the_low_target): Ditto.
725 * linux-crisv32-low.cc (the_low_target): Ditto.
726 * linux-m32r-low.cc (the_low_target): Ditto.
727 * linux-m68k-low.cc (the_low_target): Ditto.
728 * linux-sh-low.cc (the_low_target): Ditto.
729 * linux-tic6x-low.cc (the_low_target): Ditto.
730 * linux-tile-low.cc (the_low_target): Ditto.
731 * linux-xtensa-low.cc (the_low_target): Ditto.
732
809a0c35
TBA
7332020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
734
735 Remove the 'install_fast_tracepoint_jump_pad' and
736 'get_min_fast_tracepoint_insn_len' linux target ops to let the
737 concrete linux target define the ops by overriding the declarations
738 of process_stratum_target.
739
740 * linux-low.h (struct linux_target_ops): Remove the ops.
741 (class linux_process_target) <supports_fast_tracepoints>
742 <install_fast_tracepoint_jump_pad>
743 <get_min_fast_tracepoint_insn_len>: Remove.
744 * linux-low.cc (linux_process_target::supports_fast_tracepoints)
745 (linux_process_target::install_fast_tracepoint_jump_pad)
746 (linux_process_target::get_min_fast_tracepoint_insn_len): Remove.
747 * linux-x86-low.cc (class x86_target) <supports_fast_tracepoints>
748 <install_fast_tracepoint_jump_pad>
749 <get_min_fast_tracepoint_insn_len>: Declare.
750 (x86_target::supports_fast_tracepoints): Define.
751 (x86_install_fast_tracepoint_jump_pad): Turn into...
752 (x86_target::install_fast_tracepoint_jump_pad): ...this.
753 (x86_get_min_fast_tracepoint_insn_len): Turn into...
754 (x86_target::get_min_fast_tracepoint_insn_len): ...this.
755 (the_low_target): Remove the op fields.
756 * linux-aarch64-low.cc (class aarch64_target)
757 <supports_fast_tracepoints>
758 <install_fast_tracepoint_jump_pad>
759 <get_min_fast_tracepoint_insn_len>: Declare.
760 (aarch64_target::supports_fast_tracepoints): Define.
761 (aarch64_install_fast_tracepoint_jump_pad): Turn into...
762 (aarch64_target::install_fast_tracepoint_jump_pad): ...this.
763 (aarch64_get_min_fast_tracepoint_insn_len): Turn into...
764 (aarch64_target::get_min_fast_tracepoint_insn_len): ...this.
765 (the_low_target): Remove the op fields.
766 * linux-ppc-low.cc (class ppc_target) <supports_fast_tracepoints>
767 <install_fast_tracepoint_jump_pad>
768 <get_min_fast_tracepoint_insn_len>: Declare.
769 (ppc_target::supports_fast_tracepoints): Define.
770 (ppc_install_fast_tracepoint_jump_pad): Turn into...
771 (ppc_target::install_fast_tracepoint_jump_pad): ...this.
772 (ppc_get_min_fast_tracepoint_insn_len): Turn into...
773 (ppc_target::get_min_fast_tracepoint_insn_len): ...this.
774 (the_low_target): Remove the op fields.
775 * linux-s390-low.cc (class s390_target) <supports_fast_tracepoints>
776 <install_fast_tracepoint_jump_pad>
777 <get_min_fast_tracepoint_insn_len>: Declare.
778 (s390_target::supports_fast_tracepoints): Define.
779 (s390_install_fast_tracepoint_jump_pad): Turn into...
780 (s390_target::install_fast_tracepoint_jump_pad): ...this.
781 (s390_get_min_fast_tracepoint_insn_len): Turn into...
782 (s390_target::get_min_fast_tracepoint_insn_len): ...this.
783 (the_low_target): Remove the op fields.
784 * linux-arm-low.cc (the_low_target): Remove the op fields.
785 * linux-bfin-low.cc (the_low_target): Ditto.
786 * linux-crisv32-low.cc (the_low_target): Ditto.
787 * linux-m32r-low.cc (the_low_target): Ditto.
788 * linux-m68k-low.cc (the_low_target): Ditto.
789 * linux-sh-low.cc (the_low_target): Ditto.
790 * linux-tic6x-low.cc (the_low_target): Ditto.
791 * linux-tile-low.cc (the_low_target): Ditto.
792 * linux-xtensa-low.cc (the_low_target): Ditto.
793
13e567af
TBA
7942020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
795
796 Turn the 'get_thread_area' linux target op into a method of
797 process_stratum_target.
798
799 * linux-low.h (struct linux_target_ops): Remove the op.
800 (class linux_process_target) <stuck_in_jump_pad>
801 <linux_fast_tracepoint_collecting>
802 <low_get_thread_area>: Declare.
803 * linux-low.cc (supports_fast_tracepoints): Remove.
804 (linux_fast_tracepoint_collecting): Turn into...
805 (linux_process_target::linux_fast_tracepoint_collecting): ...this.
806 (linux_process_target::low_get_thread_area): Define.
807 (stuck_in_jump_pad_callback): Turn into...
808 (linux_process_target::stuck_in_jump_pad): ...this.
809
810 Update the caller below.
811
812 (linux_process_target::stabilize_threads)
813
814 * linux-x86-low.cc (class x86_target) <low_get_thread_area>:
815 Declare.
816 (x86_get_thread_area): Turn into...
817 (x86_target::low_get_thread_area): ...this.
818 (the_low_target): Remove the op field.
819 * linux-aarch64-low.cc (class aarch64_target) <low_get_thread_area>:
820 Declare.
821 (aarch64_get_thread_area): Turn into...
822 (aarch64_target::low_get_thread_area): ...this.
823 (the_low_target): Remove the op field.
824 * linux-ppc-low.cc (class ppc_target) <low_get_thread_area>:
825 Declare.
826 (ppc_get_thread_area): Turn into...
827 (ppc_target::low_get_thread_area): ...this.
828 (the_low_target): Remove the op field.
829 * linux-s390-low.cc (class s390_target) <low_get_thread_area>:
830 Declare.
831 (s390_get_thread_area): Turn into...
832 (s390_target::low_get_thread_area): ...this.
833 (the_low_target): Remove the op field.
834 * linux-arm-low.cc (the_low_target): Remove the op field.
835 * linux-bfin-low.cc (the_low_target): Ditto.
836 * linux-crisv32-low.cc (the_low_target): Ditto.
837 * linux-m32r-low.cc (the_low_target): Ditto.
838 * linux-m68k-low.cc (the_low_target): Ditto.
839 * linux-sh-low.cc (the_low_target): Ditto.
840 * linux-tic6x-low.cc (the_low_target): Ditto.
841 * linux-tile-low.cc (the_low_target): Ditto.
842 * linux-xtensa-low.cc (the_low_target): Ditto.
843
47f70aa7
TBA
8442020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
845
846 Remote the 'supports_tracepoints' linux target op and let the
847 concrete linux target define it by overriding the op declared in
848 process_stratum_target.
849
850 * linux-low.h (struct linux_target_ops): Remove the op.
851 (class linux_process_target) <supports_tracepoints>: Remove.
852 * linux-low.cc (linux_process_target::supports_tracepoints): Remove.
853 * linux-x86-low.cc (class x86_target) <supports_tracepoints>:
854 Declare.
855 (x86_supports_tracepoints): Turn into...
856 (x86_target::supports_tracepoints): ...this.
857 (the_low_target): Remove the op field.
858 * linux-aarch64-low.cc (class aarch64_target)
859 <supports_tracepoints>: Declare.
860 (aarch64_supports_tracepoints): Turn into...
861 (aarch64_target::supports_tracepoints): ...this.
862 (the_low_target): Remove the op field.
863 * linux-ppc-low.cc (class ppc_target) <supports_tracepoints>:
864 Declare.
865 (ppc_supports_tracepoints): Turn into...
866 (ppc_target::supports_tracepoints): ...this.
867 (the_low_target): Remove the op field.
868 * linux-s390-low.cc (class s390_target) <supports_tracepoints>:
869 Declare.
870 (s390_supports_tracepoints): Turn into...
871 (s390_target::supports_tracepoints): ...this.
872 (the_low_target): Remove the op field.
873 * linux-arm-low.cc (the_low_target): Remove the op field.
874 * linux-bfin-low.cc (the_low_target): Ditto.
875 * linux-crisv32-low.cc (the_low_target): Ditto.
876 * linux-m32r-low.cc (the_low_target): Ditto.
877 * linux-m68k-low.cc (the_low_target): Ditto.
878 * linux-sh-low.cc (the_low_target): Ditto.
879 * linux-tic6x-low.cc (the_low_target): Ditto.
880 * linux-tile-low.cc (the_low_target): Ditto.
881 * linux-xtensa-low.cc (the_low_target): Ditto.
882
a5b5da92
TBA
8832020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
884
885 Remove the 'process_qsupported' linux target op and let a concrete
886 linux target define the op by overriding the op declaration in
887 process_stratum_target.
888
889 * linux-low.h (struct linux_target_ops): Remove the op.
890 (class linux_process_target) <process_qsupported>: Remove.
891 * linux-low.cc (linux_process_target::process_qsupported): Remove.
892 * linux-x86-low.cc (class x86_target) <process_qsupported>: Declare.
893 (x86_linux_process_qsupported): Turn into...
894 (x86_target::process_qsupported): ...this.
895 (the_low_target): Remove the op field.
896 * linux-aarch64-low.cc (the_low_target): Remove the op
897 field.
898 * linux-arm-low.cc (the_low_target): Ditto.
899 * linux-bfin-low.cc (the_low_target): Ditto.
900 * linux-crisv32-low.cc (the_low_target): Ditto.
901 * linux-m32r-low.cc (the_low_target): Ditto.
902 * linux-m68k-low.cc (the_low_target): Ditto.
903 * linux-ppc-low.cc (the_low_target): Ditto.
904 * linux-s390-low.cc (the_low_target): Ditto.
905 * linux-sh-low.cc (the_low_target): Ditto.
906 * linux-tic6x-low.cc (the_low_target): Ditto.
907 * linux-tile-low.cc (the_low_target): Ditto.
908 * linux-xtensa-low.cc (the_low_target): Ditto.
909
d7599cc0
TBA
9102020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
911
912 Turn the 'prepare_to_resume' linux target op into a method of
913 linux_process_target.
914
915 * linux-low.h (struct linux_target_ops): Remove the op.
916 (class linux_process_target) <low_prepare_to_resume>: Declare.
917 * linux-low.cc (linux_process_target::low_prepare_to_resume):
918 Define.
919
920 Update the callers below:
921
922 (linux_process_target::resume_one_lwp_throw)
923 (linux_process_target::low_prepare_to_resume)
924
925 * linux-x86-low.cc (class x86_target) <low_prepare_to_resume>:
926 Declare.
927 (x86_target::low_prepare_to_resume): Define.
928 (the_low_target): Remove the op field.
929 * linux-aarch64-low.cc (class aarch64_target)
930 <low_prepare_to_resume>: Declare.
931 (aarch64_target::low_prepare_to_resume): Define.
932 (the_low_target): Remove the op field.
933 * linux-arm-low.cc (class arm_target) <low_prepare_to_resume>:
934 Declare.
935 (arm_prepare_to_resume): Turn into...
936 (arm_target::low_prepare_to_resume): ...this.
937 (the_low_target): Remove the op field.
938 * linux-mips-low.cc (class mips_target) <low_prepare_to_resume>:
939 Declare.
940 (mips_linux_prepare_to_resume): Turn into...
941 (mips_target::low_prepare_to_resume): ...this.
942 (the_low_target): Remove the op field.
943 * linux-bfin-low.cc (the_low_target): Remove the op field.
944 * linux-crisv32-low.cc (the_low_target): Ditto.
945 * linux-m32r-low.cc (the_low_target): Ditto.
946 * linux-m68k-low.cc (the_low_target): Ditto.
947 * linux-ppc-low.cc (the_low_target): Ditto.
948 * linux-s390-low.cc (the_low_target): Ditto.
949 * linux-sh-low.cc (the_low_target): Ditto.
950 * linux-tic6x-low.cc (the_low_target): Ditto.
951 * linux-tile-low.cc (the_low_target): Ditto.
952 * linux-xtensa-low.cc (the_low_target): Ditto.
953
fd000fb3
TBA
9542020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
955
956 Turn the 'new_process', 'delete_process', 'new_thread',
957 'delete_thread', and 'new_fork' linux target ops into methods
958 of linux_process_target.
959
960 * linux-low.h (struct linux_target_ops): Remove the ops.
961 (class linux_process_target) <add_linux_process>
962 <add_lwp>
963 <delete_lwp>
964 <attach_lwp>
965 <detach_one_lwp>
966 <check_zombie_leaders>
967 <filter_exit_event>
968 <low_new_process>
969 <low_delete_process>
970 <low_new_thread>
971 <low_delete_thread>
972 <low_new_fork>: Declare.
973 * linux-low.cc (delete_lwp): Turn into...
974 (linux_process_target::delete_lwp): ...this.
975 (linux_process_target::low_delete_thread): Define.
976 (linux_add_process): Turn into...
977 (linux_process_target::add_linux_process): ...this.
978 (linux_process_target::low_new_process): Define.
979 (linux_process_target::low_delete_process): Define.
980 (linux_process_target::low_new_fork): Define.
981 (add_lwp): Turn into...
982 (linux_process_target::add_lwp): ...this.
983 (linux_process_target::low_new_thread): Define.
984 (linux_attach_lwp): Turn into...
985 (linux_process_target::attach_lwp): ...this.
986 (linux_detach_one_lwp): Turn into...
987 (linux_process_target::detach_one_lwp): ...this.
988 (linux_detach_lwp_callback): Remove and inline...
989 (linux_process_target::detach): ...here.
990 (check_zombie_leaders): Turn into...
991 (linux_process_target::check_zombie_leaders): ...this.
992 (filter_exit_event): Turn into...
993 (linux_process_target::filter_exit_event): ...this.
994
995 Update the callers below.
996
997 (linux_process_target::handle_extended_wait)
998 (linux_process_target::create_inferior)
999 (attach_proc_task_lwp_callback)
1000 (linux_process_target::attach)
1001 (linux_process_target::detach)
1002 (linux_process_target::mourn)
1003 * thread-db.cc (attach_thread)
1004
1005 * linux-x86-low.cc (class x86_target) <low_new_process>
1006 <low_delete_process>
1007 <low_new_thread>
1008 <low_delete_thread>
1009 <low_new_fork>: Declare.
1010 (x86_linux_new_process): Turn into...
1011 (x86_target::low_new_process): ...this.
1012 (x86_linux_delete_process): Turn into...
1013 (x86_target::low_delete_process): ...this.
1014 (x86_target::low_new_thread): Define.
1015 (x86_target::low_delete_thread): Define.
1016 (x86_linux_new_fork): Turn into...
1017 (x86_target::low_new_fork): ...this.
1018 (the_low_target): Remove the op fields.
1019 * linux-aarch64-low.cc (class aarch64_target) <low_new_process>
1020 <low_delete_process>
1021 <low_new_thread>
1022 <low_delete_thread>
1023 <low_new_fork>: Declare.
1024 (aarch64_linux_new_process): Turn into...
1025 (aarch64_target::low_new_process): ...this.
1026 (aarch64_linux_delete_process): Turn into...
1027 (aarch64_target::low_delete_process): ...this.
1028 (aarch64_target::low_new_thread): Define.
1029 (aarch64_target::low_delete_thread): Define.
1030 (aarch64_linux_new_fork): Turn into...
1031 (aarch64_target::low_new_fork): ...this.
1032 (the_low_target): Remove the op fields.
1033 * linux-arm-low.cc (class arm_target) <low_new_process>
1034 <low_delete_process>
1035 <low_new_thread>
1036 <low_delete_thread>
1037 <low_new_fork>: Declare.
1038 (arm_new_process): Turn into...
1039 (arm_target::low_new_process): ...this.
1040 (arm_delete_process): Turn into...
1041 (arm_target::low_delete_process): ...this.
1042 (arm_new_thread): Turn into...
1043 (arm_target::low_new_thread): ...this.
1044 (arm_delete_thread): Turn into...
1045 (arm_target::low_delete_thread): ...this.
1046 (arm_new_fork): Turn into...
1047 (arm_target::low_new_fork): ...this.
1048 (the_low_target): Remove the op fields.
1049 * linux-mips-low.cc (class mips_target) <low_new_process>
1050 <low_delete_process>
1051 <low_new_thread>
1052 <low_delete_thread>
1053 <low_new_fork>: Declare.
1054 (mips_linux_new_process): Turn into...
1055 (mips_target::low_new_process): ...this.
1056 (mips_linux_delete_process): Turn into...
1057 (mips_target::low_delete_process): ...this.
1058 (mips_linux_new_thread): Turn into...
1059 (mips_target::low_new_thread): ...this.
1060 (mips_linux_delete_thread): Turn into...
1061 (mips_target::low_delete_thread): ...this.
1062 (mips_linux_new_fork): Turn into...
1063 (mips_target::low_new_fork): ...this.
1064 (the_low_target): Remove the op fields.
1065 * linux-bfin-low.cc (the_low_target): Remove the op fields.
1066 * linux-crisv32-low.cc (the_low_target): Ditto.
1067 * linux-m32r-low.cc (the_low_target): Ditto.
1068 * linux-m68k-low.cc (the_low_target): Ditto.
1069 * linux-ppc-low.cc (the_low_target): Ditto.
1070 * linux-s390-low.cc (the_low_target): Ditto.
1071 * linux-sh-low.cc (the_low_target): Ditto.
1072 * linux-tic6x-low.cc (the_low_target): Ditto.
1073 * linux-tile-low.cc (the_low_target): Ditto.
1074 * linux-xtensa-low.cc (the_low_target): Ditto.
1075
cb63de7c
TBA
10762020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1077
1078 Turn the 'siginfo_fixup' linux target op into a method of
1079 linux_process_target.
1080
1081 * linux-low.h (struct linux_target_ops): Remove the op.
1082 (class linux_process_target) <siginfo_fixup>
1083 <low_siginfo_fixup>: Declare.
1084 * linux-low.cc (siginfo_fixup): Turn into...
1085 (linux_process_target::siginfo_fixup): ...this.
1086 (linux_process_target::low_siginfo_fixup): Define.
1087 * linux-x86-low.cc (class x86_target) <low_siginfo_fixup>: Declare.
1088 (x86_siginfo_fixup): Turn into...
1089 (x86_target::low_siginfo_fixup): ...this.
1090 (the_low_target): Remove the op field.
1091 * linux-aarch64-low.cc (class aarch64_target):
1092 <low_siginfo_fixup>: Declare.
1093 (aarch64_linux_siginfo_fixup): Turn into...
1094 (aarch64_target::low_siginfo_fixup): ...this.
1095 (the_low_target): Remove the op field.
1096 * linux-arm-low.cc (the_low_target): Remove the op field.
1097 * linux-bfin-low.cc (the_low_target): Ditto.
1098 * linux-crisv32-low.cc (the_low_target): Ditto.
1099 * linux-m32r-low.cc (the_low_target): Ditto.
1100 * linux-m68k-low.cc (the_low_target): Ditto.
1101 * linux-mips-low.cc (the_low_target): Ditto.
1102 * linux-ppc-low.cc (the_low_target): Ditto.
1103 * linux-s390-low.cc (the_low_target): Ditto.
1104 * linux-sh-low.cc (the_low_target): Ditto.
1105 * linux-tic6x-low.cc (the_low_target): Ditto.
1106 * linux-tile-low.cc (the_low_target): Ditto.
1107 * linux-xtensa-low.cc (the_low_target): Ditto.
1108
b35db733
TBA
11092020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1110
1111 Turn the 'collect_ptrace_register' and 'supply_ptrace_register'
1112 linux target ops into methods of linux_process_target.
1113
1114 * linux-low.h (struct linux_target_ops): Remove the ops.
1115 (class linux_process_target) <low_collect_ptrace_register>
1116 <low_store_ptrace_register>: Declare.
1117 * linux-low.cc (linux_process_target::low_collect_ptrace_register)
1118 (linux_process_target::low_supply_ptrace_register): Define.
1119
1120 Update the callers below.
1121
1122 (linux_process_target::fetch_register)
1123 (linux_process_target::store_register)
1124
1125 * linux-x86-low.cc (the_low_target): Remove the op fields.
1126 * linux-aarch64-low.cc (the_low_target): Ditto.
1127 * linux-arm-low.cc (the_low_target): Ditto.
1128 * linux-bfin-low.cc (the_low_target): Ditto.
1129 * linux-crisv32-low.cc (the_low_target): Ditto.
1130 * linux-m32r-low.cc (the_low_target): Ditto.
1131 * linux-m68k-low.cc (the_low_target): Ditto.
1132 * linux-sh-low.cc (the_low_target): Ditto.
1133 * linux-sparc-low.cc (the_low_target): Ditto.
1134 * linux-tic6x-low.cc (the_low_target): Ditto.
1135 * linux-tile-low.cc (the_low_target): Ditto.
1136 * linux-xtensa-low.cc (the_low_target): Ditto.
1137 * linux-mips-low.cc (class mips_target)
1138 <low_collect_ptrace_register>
1139 <low_supply_ptrace_register>: Declare.
1140 (mips_collect_ptrace_register): Turn into ...
1141 (mips_target::low_collect_ptrace_register): ...this.
1142 (mips_supply_ptrace_register): Turn into...
1143 (mips_target::low_supply_ptrace_register): ...this.
1144 (the_low_target): Remove the op fields.
1145 * linux-ppc-low.cc (class ppc_target)
1146 <low_collect_ptrace_register>
1147 <low_supply_ptrace_register>: Declare.
1148 (ppc_collect_ptrace_register): Turn into ...
1149 (ppc_target::low_collect_ptrace_register): ...this.
1150 (ppc_supply_ptrace_register): Turn into ...
1151 (ppc_target::low_supply_ptrace_register): ...this.
1152 (ppc_fill_gregset): Update for the calls to
1153 low_collect_ptrace_register.
1154 (the_low_target): Remove the op fields.
1155 * linux-s390-low.cc (class s390_target)
1156 <low_collect_ptrace_register>
1157 <low_supply_ptrace_register>: Declare.
1158 (s390_collect_ptrace_register): Turn into ...
1159 (s390_target::low_collect_ptrace_register): ...this.
1160 (s390_supply_ptrace_register): Turn into ...
1161 (s390_target::low_supply_ptrace_register): ...this.
1162 (s390_fill_gregset): Update for the calls to
1163 low_collect_ptrace_register.
1164 (the_low_target): Remove the op fields.
1165
ac1bbaca
TBA
11662020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1167
1168 Turn the 'stopped_by_watchpoint' and 'stopped_data_address' linux
1169 target ops into methods of linux_process_target.
1170
1171 * linux-low.h (struct linux_target_ops): Remove the ops.
1172 (class linux_process_target) <check_stopped_by_watchpoint>
1173 <low_stopped_by_watchpoint>
1174 <low_stopped_data_address>: Declare.
1175 * linux-low.cc (check_stopped_by_watchpoint): Turn into...
1176 (linux_process_target::check_stopped_by_watchpoint): ...this.
1177 (linux_process_target::low_stopped_by_watchpoint): Define.
1178 (linux_process_target::low_stopped_data_address): Define.
1179 * linux-x86-low.cc (class x86_target) <low_stopped_by_watchpoint>
1180 <low_stopped_data_address>: Declare.
1181 (x86_stopped_by_watchpoint): Turn into...
1182 (x86_target::low_stopped_by_watchpoint): ...this.
1183 (x86_stopped_data_address): Turn into...
1184 (x86_target::low_stopped_data_address): ...this.
1185 (the_low_target): Remove the op fields.
1186 * linux-aarch64-low.cc (class aarch64_target)
1187 <low_stopped_by_watchpoint>
1188 <low_stopped_data_address>: Declare.
1189 (aarch64_stopped_by_watchpoint): Turn into...
1190 (aarch64_target::low_stopped_by_watchpoint): ...this.
1191 (aarch64_stopped_data_address): Turn into...
1192 (aarch64_target::low_stopped_data_address): ...this.
1193 (the_low_target): Remove the op fields.
1194 * linux-arm-low.cc (class arm_target) <low_stopped_by_watchpoint>
1195 <low_stopped_data_address>: Declare.
1196 (arm_stopped_by_watchpoint): Turn into...
1197 (arm_target::low_stopped_by_watchpoint): ...this.
1198 (arm_stopped_data_address): Turn into...
1199 (arm_target::low_stopped_data_address): ...this.
1200 (the_low_target): Remove the op fields.
1201 * linux-crisv32-low.cc (class crisv32_target)
1202 <low_stopped_by_watchpoint>
1203 <low_stopped_data_address>: Declare.
1204 (cris_stopped_by_watchpoint): Turn into...
1205 (crisv32_target::low_stopped_by_watchpoint): ...this.
1206 (cris_stopped_data_address): Turn into...
1207 (crisv32_target::low_stopped_data_address): ...this.
1208 (the_low_target): Remove the op fields.
1209 * linux-mips-low.cc (class mips_target) <low_stopped_by_watchpoint>
1210 <low_stopped_data_address>: Declare.
1211 (mips_stopped_by_watchpoint): Turn into...
1212 (mips_target::low_stopped_by_watchpoint): ...this.
1213 (mips_stopped_data_address): Turn into...
1214 (mips_target::low_stopped_data_address): ...this.
1215 (the_low_target): Remove the op fields.
1216 * linux-bfin-low.cc (the_low_target): Remove the op fields.
1217 * linux-m32r-low.cc (the_low_target): Ditto.
1218 * linux-m68k-low.cc (the_low_target): Ditto.
1219 * linux-ppc-low.cc (the_low_target): Ditto.
1220 * linux-s390-low.cc (the_low_target): Ditto.
1221 * linux-sh-low.cc (the_low_target): Ditto.
1222 * linux-sparc-low.cc (the_low_target): Ditto.
1223 * linux-tic6x-low.cc (the_low_target): Ditto.
1224 * linux-tile-low.cc (the_low_target): Ditto.
1225 * linux-xtensa-low.cc (the_low_target): Ditto.
1226
9db9aa23
TBA
12272020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1228
1229 Turn the 'insert_point' and 'remove_point' linux target ops into
1230 methods of linux_process_target.
1231
1232 * linux-low.h (struct linux_target_ops): Remove the ops.
1233 (class linux_process_target) <low_insert_point>
1234 <low_remove_point>: Declare.
1235 * linux-low.cc (linux_process_target::low_insert_point)
1236 (linux_process_target::low_remove_point): Define.
1237 (linux_process_target::insert_point)
1238 (linux_process_target::remove_point): Update for calls to
1239 low_insert_point and low_remove_point.
1240 * linux-x86-low.cc (class x86_target) <low_insert_point>
1241 <low_remove_point>: Declare.
1242 (x86_insert_point): Turn into...
1243 (x86_target::low_insert_point): ...this.
1244 (x86_remove_point): Turn into...
1245 (x86_target::low_remove_point): ...this.
1246 (the_low_target): Remove the op fields.
1247 * linux-aarch64-low.cc (class aarch64_target) <low_insert_point>
1248 <low_remove_point>: Declare.
1249 (aarch64_insert_point): Turn into...
1250 (aarch64_target::low_insert_point): ...this.
1251 (aarch64_remove_point): Turn into...
1252 (aarch64_target::low_remove_point): ...this.
1253 (the_low_target): Remove the op fields.
1254 * linux-arm-low.cc (class arm_target) <low_insert_point>
1255 <low_remove_point>: Declare.
1256 (arm_insert_point): Turn into...
1257 (arm_target::low_insert_point): ...this.
1258 (arm_remove_point): Turn into...
1259 (arm_target::low_remove_point): ...this.
1260 (the_low_target): Remove the op fields.
1261 * linux-crisv32-low.cc (class crisv32_target) <low_insert_point>
1262 <low_remove_point>: Declare.
1263 (crisv32_insert_point): Turn into...
1264 (crisv32_target::low_insert_point): ...this.
1265 (crisv32_remove_point): Turn into...
1266 (crisv32_target::low_remove_point): ...this.
1267 (the_low_target): Remove the op fields.
1268 * linux-mips-low.cc (class mips_target) <low_insert_point>
1269 <low_remove_point>: Declare.
1270 (mips_insert_point): Turn into...
1271 (mips_target::low_insert_point): ...this.
1272 (mips_remove_point): Turn into...
1273 (mips_target::low_remove_point): ...this.
1274 (the_low_target): Remove the op fields.
1275 * linux-ppc-low.cc (class ppc_target) <low_insert_point>
1276 <low_remove_point>: Declare.
1277 (ppc_insert_point): Turn into...
1278 (ppc_target::low_insert_point): ...this.
1279 (ppc_remove_point): Turn into...
1280 (ppc_target::low_remove_point): ...this.
1281 (the_low_target): Remove the op fields.
1282 * linux-bfin-low.cc (the_low_target): Remove the op fields.
1283 * linux-m32r-low.cc (the_low_target): Ditto.
1284 * linux-m68k-low.cc (the_low_target): Ditto.
1285 * linux-s390-low.cc (the_low_target): Ditto.
1286 * linux-sh-low.cc (the_low_target): Ditto.
1287 * linux-sparc-low.cc (the_low_target): Ditto.
1288 * linux-tic6x-low.cc (the_low_target): Ditto.
1289 * linux-tile-low.cc (the_low_target): Ditto.
1290 * linux-xtensa-low.cc (the_low_target): Ditto.
1291
007c9b97
TBA
12922020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1293
1294 Remove the 'supports_z_point_type' linux target op and let the
1295 concrete linux target define it by overriding the op declared in
1296 process_stratum_target.
1297
1298 * linux-low.cc (linux_process_target::supports_z_point_type):
1299 Remove.
1300 * linux-low.h (struct linux_target_ops): Remove the op.
1301 (class linux_process_target) <supports_z_point_type>: Remove.
1302 * linux-x86-low.cc (class x86_target) <supports_z_point_type>:
1303 Declare.
1304 (x86_supports_z_point_type): Turn into...
1305 (x86_target::supports_z_point_type): ...this.
1306 (the_low_target): Remove the op field.
1307 * linux-aarch64-low.cc (class aarch64_target)
1308 <supports_z_point_type>: Declare.
1309 (aarch64_supports_z_point_type): Turn into...
1310 (aarch64_target::supports_z_point_type): ...this.
1311 (the_low_target): Remove the op field.
1312 * linux-arm-low.cc (class arm_target) <supports_z_point_type>:
1313 Declare.
1314 (arm_supports_z_point_type): Turn into...
1315 (arm_target::supports_z_point_type): ...this.
1316 (the_low_target): Remove the op field.
1317 * linux-crisv32-low.cc (class crisv32_target)
1318 <supports_z_point_type>: Declare.
1319 (cris_supports_z_point_type): Turn into...
1320 (crisv32_target::supports_z_point_type): ...this.
1321 (the_low_target): Remove the op field.
1322 * linux-mips-low.cc (class mips_target) <supports_z_point_type>:
1323 Declare.
1324 (mips_supports_z_point_type): Turn into...
1325 (mips_target::supports_z_point_type): ...this.
1326 (the_low_target): Remove the op field.
1327 * linux-ppc-low.cc (class ppc_target) <supports_z_point_type>:
1328 Declare.
1329 (ppc_supports_z_point_type): Turn into...
1330 (ppc_target::supports_z_point_type): ...this.
1331 (the_low_target): Remove the op field.
1332 * linux-s390-low.cc (class s390_target) <supports_z_point_type>:
1333 Declare.
1334 (s390_supports_z_point_type): Turn into...
1335 (s390_target::supports_z_point_type): ...this.
1336 (the_low_target): Remove the op field.
1337 * linux-bfin-low.cc (the_low_target): Remove the op field.
1338 * linux-m32r-low.cc (the_low_target): Ditto.
1339 * linux-m68k-low.cc (the_low_target): Ditto.
1340 * linux-sh-low.cc (the_low_target): Ditto.
1341 * linux-sparc-low.cc (the_low_target): Ditto.
1342 * linux-tic6x-low.cc (the_low_target): Ditto.
1343 * linux-tile-low.cc (the_low_target): Ditto.
1344 * linux-xtensa-low.cc (the_low_target): Ditto.
1345
d7146cda
TBA
13462020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1347
1348 Turn the 'breakpoint_at' linux target op into a method of
1349 linux_process_target.
1350
1351 * linux-low.h (struct linux_target_ops): Remove the op.
1352 (class linux_process_target) <low_breakpoint_at>: Declare.
1353
1354 Update the callers below:
1355
1356 * linux-low.cc (linux_process_target::save_stop_reason)
1357 (linux_process_target::thread_still_has_status_pending)
1358 (linux_process_target::wait_1)
1359
1360 * linux-x86-low.cc (class x86_target)
1361 <low_breakpoint_at>: Declare.
1362 (x86_breakpoint_at): Turn into...
1363 (x86_target::low_breakpoint_at): ...this.
1364 (the_low_target): Remove the op field.
1365 * linux-aarch64-low.cc (class aarch64_target)
1366 <low_breakpoint_at>: Declare.
1367 (aarch64_breakpoint_at): Turn into...
1368 (aarch64_target::low_breakpoint_at): ...this.
1369 (the_low_target): Remove the op field.
1370 * linux-arm-low.cc (class arm_target)
1371 <low_breakpoint_at>: Declare.
1372 (arm_target::low_breakpoint_at): Define.
1373 (the_low_target): Remove the op field.
1374 * linux-bfin-low.cc (class bfin_target)
1375 <low_breakpoint_at>: Declare.
1376 (bfin_breakpoint_at): Turn into...
1377 (bfin_target::low_breakpoint_at): ...this.
1378 (the_low_target): Remove the op field.
1379 * linux-cris-low.cc (class cris_target)
1380 <low_breakpoint_at>: Declare.
1381 (cris_breakpoint_at): Turn into...
1382 (cris_target::low_breakpoint_at): ...this.
1383 (the_low_target): Remove the op field.
1384 * linux-crisv32-low.cc (class crisv32_target)
1385 <low_breakpoint_at>: Declare.
1386 (crisv32_breakpoint_at): Turn into...
1387 (crisv32_target::low_breakpoint_at): ...this.
1388 (the_low_target): Remove the op field.
1389 * linux-ia64-low.cc (class ia64_target)
1390 <low_breakpoint_at>: Declare.
1391 (ia64_target::low_breakpoint_at): Define.
1392 * linux-m32r-low.cc (class m32r_target)
1393 <low_breakpoint_at>: Declare.
1394 (m32r_breakpoint_at): Turn into...
1395 (m32r_target::low_breakpoint_at): ...this.
1396 (the_low_target): Remove the op field.
1397 * linux-m68k-low.cc (class m68k_target)
1398 <low_breakpoint_at>: Declare.
1399 (m68k_breakpoint_at): Turn into...
1400 (m68k_target::low_breakpoint_at): ...this.
1401 (the_low_target): Remove the op field.
1402 * linux-mips-low.cc (class mips_target)
1403 <low_breakpoint_at>: Declare.
1404 (mips_breakpoint_at): Turn into...
1405 (mips_target::low_breakpoint_at): ...this.
1406 (the_low_target): Remove the op field.
1407 * linux-nios2-low.cc (class nios2_target)
1408 <low_breakpoint_at>: Declare.
1409 (nios2_breakpoint_at): Turn into...
1410 (nios2_target::low_breakpoint_at): ...this.
1411 (the_low_target): Remove the op field.
1412 * linux-ppc-low.cc (class ppc_target)
1413 <low_breakpoint_at>: Declare.
1414 (ppc_breakpoint_at): Turn into...
1415 (ppc_target::low_breakpoint_at): ...this.
1416 (the_low_target): Remove the op field.
1417 * linux-riscv-low.cc (class riscv_target)
1418 <low_breakpoint_at>: Declare.
1419 (riscv_breakpoint_at): Turn into...
1420 (riscv_target::low_breakpoint_at): ...this.
1421 (the_low_target): Remove the op field.
1422 * linux-s390-low.cc (class s390_target)
1423 <low_breakpoint_at>: Declare.
1424 (s390_breakpoint_at): Turn into...
1425 (s390_target::low_breakpoint_at): ...this.
1426 (the_low_target): Remove the op field.
1427 * linux-sh-low.cc (class sh_target)
1428 <low_breakpoint_at>: Declare.
1429 (sh_breakpoint_at): Turn into...
1430 (sh_target::low_breakpoint_at): ...this.
1431 (the_low_target): Remove the op field.
1432 * linux-sparc-low.cc (class sparc_target)
1433 <low_breakpoint_at>: Declare.
1434 (sparc_breakpoint_at): Turn into...
1435 (sparc_target::low_breakpoint_at): ...this.
1436 (the_low_target): Remove the op field.
1437 * linux-tic6x-low.cc (class tic6x_target)
1438 <low_breakpoint_at>: Declare.
1439 (tic6x_breakpoint_at): Turn into...
1440 (tic6x_target::low_breakpoint_at): ...this.
1441 (the_low_target): Remove the op field.
1442 * linux-tile-low.cc (class tile_target)
1443 <low_breakpoint_at>: Declare.
1444 (tile_breakpoint_at): Turn into...
1445 (tile_target::low_breakpoint_at): ...this.
1446 (the_low_target): Remove the op field.
1447 * linux-xtensa-low.cc (class xtensa_target)
1448 <low_breakpoint_at>: Declare.
1449 (xtensa_breakpoint_at): Turn into...
1450 (xtensa_target::low_breakpoint_at): ...this.
1451 (the_low_target): Remove the op field.
1452
d4807ea2
TBA
14532020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1454
1455 Turn the 'decr_pc_after_break' linux_target_ops field into
1456 a method of linux_process_target.
1457
1458 * linux-low.h (struct linux_target_ops)
1459 <decr_pc_after_break>: Remove.
1460 (class linux_process_target) <low_decr_pc_after_break>: New method
1461 declaration.
1462 * linux-low.cc (linux_process_target::low_decr_pc_after_break):
1463 New method implementation.
1464
1465 Update the users below.
1466
1467 (linux_process_target::save_stop_reason)
1468 (linux_process_target::wait_1)
1469 * linux-x86-low.cc (class x86_target) <low_decr_pc_after_break>:
1470 New declaration.
1471 (x86_target::low_decr_pc_after_break): New method implementation.
1472 (the_low_target): Remove the field.
1473 * linux-bfin-low.cc (class bfin_target) <low_decr_pc_after_break>:
1474 New declaration.
1475 (bfin_target::low_decr_pc_after_break): New method implementation.
1476 (the_low_target): Remove the field.
1477 * linux-m68k-low.cc (class m68k_target) <low_decr_pc_after_break>:
1478 New declaration.
1479 (m68k_target::low_decr_pc_after_break): New method implementation.
1480 (the_low_target): Remove the field.
1481 * linux-s390-low.cc (class s390_target) <low_decr_pc_after_break>:
1482 New declaration.
1483 (s390_target::low_decr_pc_after_break): New method implementation.
1484 (the_low_target): Remove the field.
1485 * linux-aarch64-low.cc (the_low_target): Remove the field.
1486 * linux-arm-low.cc (the_low_target): Remove the field.
1487 * linux-cris-low.cc (the_low_target): Remove the field.
1488 * linux-crisv32-low.cc (the_low_target): Remove the field.
1489 * linux-m32r-low.cc (the_low_target): Remove the field.
1490 * linux-mips-low.cc (the_low_target): Remove the field.
1491 * linux-nios2-low.cc (the_low_target): Remove the field.
1492 * linux-ppc-low.cc (the_low_target): Remove the field.
1493 * linux-riscv-low.cc (the_low_target): Remove the field.
1494 * linux-sh-low.cc (the_low_target): Remove the field.
1495 * linux-sparc-low.cc (the_low_target): Remove the field.
1496 * linux-tic6x-low.cc (the_low_target): Remove the field.
1497 * linux-tile-low.cc (the_low_target): Remove the field.
1498 * linux-xtensa-low.cc (the_low_target): Remove the field.
1499
7582c77c
TBA
15002020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1501
1502 Remove the 'supports_software_single_step' linux target op and let
1503 the concrete linux target define it by overriding the op in
1504 process_stratum_target.
1505 Turn the 'get_next_pcs' linux target op into a method of
1506 linux_process_target.
1507
1508 * linux-low.h (struct linux_target_ops): Remove the ops.
1509 (class linux_process_target) <supports_software_single_step>:
1510 Remove.
1511 <low_get_next_pcs>: Declare.
1512 * linux-low.cc (can_software_single_step): Remove.
1513 (linux_process_target::low_get_next_pcs): Define.
1514 (linux_process_target::supports_software_single_step): Remove.
1515
1516 Update the callers below.
1517
1518 (linux_process_target::handle_extended_wait)
1519 (linux_process_target::wait_1)
1520 (linux_process_target::install_software_single_step_breakpoints)
1521 (linux_process_target::single_step)
1522 (linux_process_target::thread_needs_step_over)
1523 (linux_process_target::proceed_one_lwp)
1524 (linux_process_target::supports_range_stepping)
1525
1526 * linux-x86-low.cc (the_low_target): Remove the op field.
1527 * linux-aarch64-low.cc (the_low_target): Ditto.
1528 * linux-bfin-low.cc (the_low_target): Ditto.
1529 * linux-cris-low.cc (the_low_target): Ditto.
1530 * linux-crisv32-low.cc (the_low_target): Ditto.
1531 * linux-m32r-low.cc (the_low_target): Ditto.
1532 * linux-m68k-low.cc (the_low_target): Ditto.
1533 * linux-mips-low.cc (the_low_target): Ditto.
1534 * linux-nios2-low.cc (the_low_target): Ditto.
1535 * linux-ppc-low.cc (the_low_target): Ditto.
1536 * linux-riscv-low.cc (the_low_target): Ditto.
1537 * linux-s390-low.cc (the_low_target): Ditto.
1538 * linux-sh-low.cc (the_low_target): Ditto.
1539 * linux-sparc-low.cc (the_low_target): Ditto.
1540 * linux-tic6x-low.cc (the_low_target): Ditto.
1541 * linux-tile-low.cc (the_low_target): Ditto.
1542 * linux-xtensa-low.cc (the_low_target): Ditto.
1543 * linux-arm-low.cc (class arm_target) <low_get_next_pcs>
1544 <supports_software_single_step>: Declare.
1545 (arm_target::supports_software_single_step): Define.
1546 (arm_gdbserver_get_next_pcs): Turn into...
1547 (arm_target::low_get_next_pcs): ...this.
1548 (the_low_target): Remove the op field.
1549
3ca4edb6
TBA
15502020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1551
1552 Remove the 'sw_breakpoint_from_kind' linux target op, and let
1553 the concrete linux target define it by overriding the op
1554 in process_stratum_target.
1555
1556 * linux-low.cc (linux_process_target::sw_breakpoint_from_kind):
1557 Remove.
1558 * linux-low.h (struct linux_target_ops): Remove the op.
1559 (class linux_process_target) <sw_breakpoint_from_kind>: Remove.
1560 * linux-x86-low.cc (class x86_target) <sw_breakpoint_from_kind>:
1561 Declare.
1562 (x86_sw_breakpoint_from_kind): Turn into...
1563 (x86_target::sw_breakpoint_from_kind): ...this.
1564 (the_low_target): Remove the op field.
1565 * linux-aarch64-low.cc (class aarch64_target)
1566 <sw_breakpoint_from_kind>: Declare.
1567 (aarch64_sw_breakpoint_from_kind): Turn into...
1568 (aarch64_target::sw_breakpoint_from_kind): ...this.
1569 (the_low_target): Remove the op field.
1570 * linux-arm-low.cc (class arm_target) <sw_breakpoint_from_kind>:
1571 Declare.
1572 (arm_target::sw_breakpoint_from_kind): Define.
1573 (the_low_target): Remove the op field.
1574 * linux-bfin-low.cc (class bfin_target) <sw_breakpoint_from_kind>:
1575 Declare.
1576 (bfin_sw_breakpoint_from_kind): Turn into...
1577 (bfin_target::sw_breakpoint_from_kind): ...this.
1578 (the_low_target): Remove the op field.
1579 * linux-cris-low.cc (class cris_target) <sw_breakpoint_from_kind>:
1580 Declare.
1581 (cris_sw_breakpoint_from_kind): Turn into...
1582 (cris_target::sw_breakpoint_from_kind): ...this.
1583 (the_low_target): Remove the op field.
1584 * linux-crisv32-low.cc (class crisv32_target)
1585 <sw_breakpoint_from_kind>: Declare.
1586 (cris_sw_breakpoint_from_kind): Turn into...
1587 (crisv32_target::sw_breakpoint_from_kind): ...this.
1588 (the_low_target): Remove the op field.
1589 * linux-ia64-low.cc (class ia64_target) <sw_breakpoint_from_kind>:
1590 Declare.
1591 (ia64_target::sw_breakpoint_from_kind): Define.
1592 * linux-m32r-low.cc (class m32r_target) <sw_breakpoint_from_kind>:
1593 Declare.
1594 (m32r_sw_breakpoint_from_kind): Turn into...
1595 (m32r_target::sw_breakpoint_from_kind): ...this.
1596 (the_low_target): Remove the op field.
1597 * linux-m68k-low.cc (class m68k_target) <sw_breakpoint_from_kind>:
1598 Declare.
1599 (m68k_sw_breakpoint_from_kind): Turn into...
1600 (m68k_target::sw_breakpoint_from_kind): ...this.
1601 (the_low_target): Remove the op field.
1602 * linux-mips-low.cc (class mips_target) <sw_breakpoint_from_kind>:
1603 Declare.
1604 (mips_sw_breakpoint_from_kind): Turn into...
1605 (mips_target::sw_breakpoint_from_kind): ...this.
1606 (the_low_target): Remove the op field.
1607 * linux-nios2-low.cc (class nios2_target) <sw_breakpoint_from_kind>:
1608 Declare.
1609 (nios2_sw_breakpoint_from_kind): Turn into...
1610 (nios2_target::sw_breakpoint_from_kind): ...this.
1611 (the_low_target): Remove the op field.
1612 * linux-ppc-low.cc (class ppc_target) <sw_breakpoint_from_kind>:
1613 Declare.
1614 (ppc_sw_breakpoint_from_kind): Turn into...
1615 (ppc_target::sw_breakpoint_from_kind): ...this.
1616 (the_low_target): Remove the op field.
1617 * linux-riscv-low.cc (class riscv_target) <sw_breakpoint_from_kind>:
1618 Declare.
1619 (riscv_sw_breakpoint_from_kind): Turn into...
1620 (riscv_target::sw_breakpoint_from_kind): ...this.
1621 (the_low_target): Remove the op field.
1622 * linux-s390-low.cc (class s390_target) <sw_breakpoint_from_kind>:
1623 Declare.
1624 (s390_sw_breakpoint_from_kind): Turn into...
1625 (s390_target::sw_breakpoint_from_kind): ...this.
1626 (the_low_target): Remove the op field.
1627 * linux-sh-low.cc (class sh_target) <sw_breakpoint_from_kind>:
1628 Declare.
1629 (sh_sw_breakpoint_from_kind): Turn into...
1630 (sh_target::sw_breakpoint_from_kind): ...this.
1631 (the_low_target): Remove the op field.
1632 * linux-sparc-low.cc (class sparc_target) <sw_breakpoint_from_kind>:
1633 Declare.
1634 (sparc_sw_breakpoint_from_kind): Turn into...
1635 (sparc_target::sw_breakpoint_from_kind): ...this.
1636 (the_low_target): Remove the op field.
1637 * linux-tic6x-low.cc (class tic6x_target) <sw_breakpoint_from_kind>:
1638 Declare.
1639 (tic6x_sw_breakpoint_from_kind): Turn into...
1640 (tic6x_target::sw_breakpoint_from_kind): ...this.
1641 (the_low_target): Remove the op field.
1642 * linux-tile-low.cc (class tile_target) <sw_breakpoint_from_kind>:
1643 Declare.
1644 (tile_sw_breakpoint_from_kind): Turn into...
1645 (tile_target::sw_breakpoint_from_kind): ...this.
1646 (the_low_target): Remove the op field.
1647 * linux-xtensa-low.cc (class xtensa_target)
1648 <sw_breakpoint_from_kind>: Declare.
1649 (xtensa_sw_breakpoint_from_kind): Turn into...
1650 (xtensa_target::sw_breakpoint_from_kind): ...this.
1651 (the_low_target): Remove the op field.
1652
06250e4e
TBA
16532020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1654
1655 Remove the 'breakpoint_kind_from_pc' and
1656 'breakpoint_kind_from_current_state' linux target ops, and let the
1657 concrete linux target define them by overriding the ops of
1658 process_stratum_target.
1659
1660 * linux-low.cc (linux_process_target::breakpoint_kind_from_pc):
1661 Remove.
1662 (linux_process_target::breakpoint_kind_from_current_state): Remove.
1663 * linux-low.h (struct linux_target_ops): Remove ops.
1664 (class linux_process_target) <breakpoint_kind_from_pc>: Remove.
1665 <breakpoint_kind_from_current_state>: Remove.
1666 * linux-x86-low.cc (the_low_target): Remove the op fields.
1667 * linux-bfin-low.cc (the_low_target): Ditto.
1668 * linux-cris-low.cc (the_low_target): Ditto.
1669 * linux-crisv32-low.cc (the_low_target): Ditto.
1670 * linux-m32r-low.cc (the_low_target): Ditto.
1671 * linux-m68k-low.cc (the_low_target): Ditto.
1672 * linux-mips-low.cc (the_low_target): Ditto.
1673 * linux-nios2-low.cc (the_low_target): Ditto.
1674 * linux-ppc-low.cc (the_low_target): Ditto.
1675 * linux-s390-low.cc (the_low_target): Ditto.
1676 * linux-sh-low.cc (the_low_target): Ditto.
1677 * linux-sparc-low.cc (the_low_target): Ditto.
1678 * linux-tic6x-low.cc (the_low_target): Ditto.
1679 * linux-tile-low.cc (the_low_target): Ditto.
1680 * linux-xtensa-low.cc (the_low_target): Ditto.
1681 * linux-aarch64-low.cc (class aarch64_target)
1682 <breakpoint_kind_from_pc>
1683 <breakpoint_kind_from_current_state>: Declare.
1684 (aarch64_breakpoint_kind_from_pc): Turn into...
1685 (aarch64_target::breakpoint_kind_from_pc): ...this.
1686 (aarch64_breakpoint_kind_from_current_state): Turn into...
1687 (aarch64_target::breakpoint_kind_from_current_state): ...this.
1688 (the_low_target): Remove the op fields.
1689 * linux-arm-low.cc (class arm_target):
1690 <breakpoint_kind_from_pc>
1691 <breakpoint_kind_from_current_state>: Declare.
1692 (arm_target::breakpoint_kind_from_pc): Define.
1693 (arm_target::breakpoint_kind_from_current_state): Define.
1694 (the_low_target): Remove the op fields.
1695 * linux-riscv-low.cc (class riscv_target):
1696 <breakpoint_kind_from_pc>: Declare.
1697 (riscv_breakpoint_kind_from_pc): Turn into...
1698 (riscv_target::breakpoint_kind_from_pc): ...this.
1699 (the_low_target): Remove the op fields.
1700
bf9ae9d8
TBA
17012020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1702
1703 Turn the 'get_pc' and 'set_pc' linux target ops into methods
1704 of linux_process_target.
1705
1706 * linux-low.h (struct linux_target_ops): Remove the ops.
1707 (class linux_process_target) <low_supports_breakpoints>
1708 <low_get_pc>
1709 <low_set_pc>: Declare.
1710 * linux-low.cc (supports_breakpoints): Turn into...
1711 (linux_process_target::low_supports_breakpoints): ...this.
1712 (linux_process_target::low_get_pc): Define.
1713 (linux_process_target::low_set_pc): Define.
1714
1715 Update the callers below.
1716
1717 (linux_process_target::get_pc)
1718 (linux_process_target::save_stop_reason)
1719 (linux_process_target::maybe_move_out_of_jump_pad)
1720 (linux_process_target::wait_1)
1721 (linux_process_target::resume_one_lwp_throw)
1722 (linux_process_target::resume)
1723 (linux_process_target::proceed_all_lwps)
1724 (linux_process_target::read_pc)
1725 (linux_process_target::write_pc)
1726
1727 * linux-x86-low.cc (class linux_process_target)
1728 <low_supports_breakpoints>
1729 <low_get_pc>
1730 <low_set_pc>: Declare.
1731 (x86_target::low_supports_breakpoints): Define.
1732 (x86_get_pc): Turn into...
1733 (x86_target::low_get_pc): ...this.
1734 (x86_set_pc): Turn into...
1735 (x86_target::low_set_pc): ...this.
1736 (the_low_target): Remove the op fields.
1737 * linux-arm-low.cc (class arm_target)
1738 <low_supports_breakpoints>
1739 <low_get_pc>
1740 <low_set_pc>: Declare.
1741 (arm_target::low_supports_breakpoints)
1742 (arm_target::low_get_pc)
1743 (arm_target::low_set_pc): Define.
1744 (the_low_target): Remove the op fields.
1745 * linux-bfin-low.cc (class bfin_target)
1746 <low_supports_breakpoints>
1747 <low_get_pc>
1748 <low_set_pc>: Declare.
1749 (bfin_target::low_supports_breakpoints)
1750 (bfin_target::low_get_pc)
1751 (bfin_target::low_set_pc): Define.
1752 (the_low_target): Remove the op fields.
1753 * linux-cris-low.cc (class cris_target)
1754 <low_supports_breakpoints>
1755 <low_get_pc>
1756 <low_set_pc>: Declare.
1757 (cris_target::low_supports_breakpoints)
1758 (cris_target::low_get_pc)
1759 (cris_target::low_set_pc): Define.
1760 (the_low_target): Remove the op fields.
1761 * linux-crisv32-low.cc (class crisv32_target)
1762 <low_supports_breakpoints>
1763 <low_get_pc>
1764 <low_set_pc>: Declare.
1765 (crisv32_target::low_supports_breakpoints)
1766 (crisv32_target::low_get_pc)
1767 (crisv32_target::low_set_pc): Define.
1768 (the_low_target): Remove the op fields.
1769 * linux-m32r-low.cc (class m32r_target)
1770 <low_supports_breakpoints>
1771 <low_get_pc>
1772 <low_set_pc>: Declare.
1773 (m32r_target::low_supports_breakpoints)
1774 (m32r_target::low_get_pc)
1775 (m32r_target::low_set_pc): Define.
1776 (the_low_target): Remove the op fields.
1777 * linux-m68k-low.cc (class m68k_target)
1778 <low_supports_breakpoints>
1779 <low_get_pc>
1780 <low_set_pc>: Declare.
1781 (m68k_target::low_supports_breakpoints)
1782 (m68k_target::low_get_pc)
1783 (m68k_target::low_set_pc): Define.
1784 (the_low_target): Remove the op fields.
1785 * linux-nios2-low.cc (class nios2_target)
1786 <low_supports_breakpoints>
1787 <low_get_pc>
1788 <low_set_pc>: Declare.
1789 (nios2_target::low_supports_breakpoints)
1790 (nios2_target::low_get_pc)
1791 (nios2_target::low_set_pc): Define.
1792 (the_low_target): Remove the op fields.
1793 * linux-sh-low.cc (class sh_target)
1794 <low_supports_breakpoints>
1795 <low_get_pc>
1796 <low_set_pc>: Declare.
1797 (sh_target::low_supports_breakpoints)
1798 (sh_target::low_get_pc)
1799 (sh_target::low_set_pc): Define.
1800 (the_low_target): Remove the op fields.
1801 * linux-xtensa-low.cc (class xtensa_target)
1802 <low_supports_breakpoints>
1803 <low_get_pc>
1804 <low_set_pc>: Declare.
1805 (xtensa_target::low_supports_breakpoints)
1806 (xtensa_target::low_get_pc)
1807 (xtensa_target::low_set_pc): Define.
1808 (the_low_target): Remove the op fields.
1809 * linux-sparc-low.cc (class sparc_target)
1810 <low_supports_breakpoints>
1811 <low_get_pc>: Declare.
1812 (sparc_target::low_supports_breakpoints)
1813 (sparc_target::low_get_pc): Define.
1814 (the_low_target): Remove the op fields.
1815 * linux-tile-low.cc (class tile_target)
1816 <low_supports_breakpoints>
1817 <low_get_pc>
1818 <low_set_pc>: Declare.
1819 (tile_target::low_supports_breakpoints)
1820 (tile_target::low_get_pc)
1821 (tile_target::low_set_pc): Define.
1822 (the_low_target): Remove the op fields.
1823 * linux-aarch64-low.cc (class aarch64_target)
1824 <low_supports_breakpoints>
1825 <low_get_pc>
1826 <low_set_pc>: Declare.
1827 (aarch64_target::low_supports_breakpoints): Define.
1828 (aarch64_get_pc): Turn into...
1829 (aarch64_target::low_get_pc): ...this.
1830 (aarch64_set_pc): Turn into...
1831 (aarch64_target::low_set_pc): ...this.
1832 (the_low_target): Remove the op fields.
1833 * linux-mips-low.cc (class mips_target)
1834 <low_supports_breakpoints>
1835 <low_get_pc>
1836 <low_set_pc>: Declare.
1837 (mips_target::low_supports_breakpoints): Define.
1838 (mips_get_pc): Turn into...
1839 (mips_target::low_get_pc): ...this.
1840 (mips_set_pc): Turn into...
1841 (mips_target::low_set_pc): ...this.
1842 (the_low_target): Remove the op fields.
1843 * linux-ppc-low.cc (class ppc_target)
1844 <low_supports_breakpoints>
1845 <low_get_pc>
1846 <low_set_pc>: Declare.
1847 (ppc_target::low_supports_breakpoints): Define.
1848 (ppc_get_pc): Turn into...
1849 (ppc_target::low_get_pc): ...this.
1850 (ppc_set_pc): Turn into...
1851 (ppc_target::low_set_pc): ...this.
1852 (the_low_target): Remove the op fields.
1853 * linux-riscv-low.cc (class riscv_target)
1854 <low_supports_breakpoints>
1855 <low_get_pc>
1856 <low_set_pc>: Declare.
1857 (riscv_target::low_supports_breakpoints): Define.
1858 (riscv_get_pc): Turn into...
1859 (riscv_target::low_get_pc): ...this.
1860 (riscv_set_pc): Turn into...
1861 (riscv_target::low_set_pc): ...this.
1862 (the_low_target): Remove the op fields.
1863 * linux-s390-low.cc (class s390_target)
1864 <low_supports_breakpoints>
1865 <low_get_pc>
1866 <low_set_pc>: Declare.
1867 (s390_target::low_supports_breakpoints): Define.
1868 (s390_get_pc): Turn into...
1869 (s390_target::low_get_pc): ...this.
1870 (s390_set_pc): Turn into...
1871 (s390_target::low_set_pc): ...this.
1872 (the_low_target): Remove the op fields.
1873 * linux-tic6x-low.cc (class tic6x_target)
1874 <low_supports_breakpoints>
1875 <low_get_pc>
1876 <low_set_pc>: Declare.
1877 (tic6x_target::low_supports_breakpoints): Define.
1878 (tic6x_get_pc): Turn into...
1879 (tic6x_target::low_get_pc): ...this.
1880 (tic6x_set_pc): Turn into...
1881 (tic6x_target::low_set_pc): ...this.
1882 (the_low_target): Remove the op fields.
1883
df95181f
TBA
18842020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1885
1886 Turn some more static methods in linux-low into private methods
1887 of linux_process_target.
1888
1889 * linux-low.cc (get_pc): Turn into...
1890 (linux_process_target::get_pc): ...this.
1891 (save_stop_reason): Turn into...
1892 (linux_process_target::save_stop_reason): ...this.
1893 (thread_still_has_status_pending_p): Turn into...
1894 (linux_process_target::thread_still_has_status_pending): ...this.
1895 (status_pending_p_callback): Turn into...
1896 (linux_process_target::status_pending_p_callback): ...this.
1897 (resume_stopped_resumed_lwps): Turn into...
1898 (linux_process_target::resume_stopped_resumed_lwps): ...this.
1899 (install_software_single_step_breakpoints): Turn into...
1900 (linux_process_target::install_software_single_step_breakpoints):
1901 ...this.
1902 (single_step): Turn into...
1903 (linux_process_target::single_step): ...this.
1904 (linux_resume_one_lwp_throw): Turn into...
1905 (linux_process_target::resume_one_lwp_throw): ...this.
1906 (linux_resume_one_lwp): Turn into...
1907 (linux_process_target::resume_one_lwp): ...this.
1908 (resume_status_pending_p): Turn into...
1909 (linux_process_target::resume_status_pending): ...this.
1910 (need_step_over_p): Turn into...
1911 (linux_process_target::thread_needs_step_over): ...this.
1912 (linux_resume_one_thread): Turn into...
1913 (linux_process_target::resume_one_thread): ...this.
1914 (proceed_one_lwp): Turn into...
1915 (linux_process_target::proceed_one_lwp): ...this.
1916 (unsuspend_and_proceed_one_lwp): Turn into...
1917 (linux_process_target::unsuspend_and_proceed_one_lwp): ...this.
1918
1919 Update the calls/references to the above functions below.
1920
1921 (linux_process_target::handle_extended_wait)
1922 (linux_process_target::filter_event)
1923 (linux_process_target::wait_for_event_filtered)
1924 (linux_process_target::wait_1)
1925 (linux_process_target::move_out_of_jump_pad)
1926 (linux_process_target::start_step_over)
1927 (linux_process_target::resume)
1928 (linux_process_target::proceed_all_lwps)
1929 (regsets_store_inferior_registers)
1930 (linux_process_target::store_register)
1931
1932 * linux-low.h (class linux_process_target)
1933 <get_pc>
1934 <save_stop_reason>
1935 <thread_still_has_status_pending>
1936 <status_pending_p_callback>
1937 <resume_stopped_resumed_lwps>
1938 <install_software_single_step_breakpoints>
1939 <single_step>
1940 <resume_one_lwp_throw>
1941 <resume_one_lwp>
1942 <resume_status_pending>
1943 <thread_needs_step_over>
1944 <resume_one_thread>
1945 <proceed_one_lwp>
1946 <unsuspend_and_proceed_one_lwp>: Declare.
1947
bd70b1f2
TBA
19482020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1949
1950 Turn the 'fetch_register' linux target op into a method of
1951 linux_process_target.
1952
1953 * linux-low.h (struct linux_target_ops) <fetch_register>: Remove.
1954 (class linux_process_target) <low_fetch_register>: Declare.
1955 * linux-x86-low.cc (the_low_target)
1956 * linux-aarch64-low.cc (the_low_target)
1957 * linux-arm-low.cc (the_low_target)
1958 * linux-bfin-low.cc (the_low_target)
1959 * linux-cris-low.cc (the_low_target)
1960 * linux-crisv32-low.cc (the_low_target)
1961 * linux-m32r-low.cc (the_low_target)
1962 * linux-m68k-low.cc (the_low_target)
1963 * linux-nios2-low.cc (the_low_target)
1964 * linux-ppc-low.cc (the_low_target)
1965 * linux-s390-low.cc (the_low_target)
1966 * linux-sh-low.cc (the_low_target)
1967 * linux-sparc-low.cc (the_low_target)
1968 * linux-tic6x-low.cc (the_low_target)
1969 * linux-tile-low.cc (the_low_target)
1970 * linux-xtensa-low.cc (the_low_target): Remove the op field.
1971 * linux-ia64-low.cc (class ia64_target) <low_fetch_register>:
1972 Declare.
1973 (ia64_fetch_register): Turn into...
1974 (ia64_target::low_fetch_register): ...this.
1975 (the_low_target): Remove the op field.
1976 * linux-mips-low.cc (class mips_target) <low_fetch_register>:
1977 Declare.
1978 (mips_fetch_register): Turn into...
1979 (mips_target::low_fetch_register): ...this.
1980 (the_low_target): Remove the op field.
1981 * linux-riscv-low.cc (class riscv_target) <low_fetch_register>:
1982 Declare.
1983 (riscv_fetch_register): Turn into...
1984 (riscv_target::low_fetch_register): ...this.
1985 (the_low_target): Remove the op field.
1986
1987 Update the callers below.
1988
1989 * linux-low.cc (linux_process_target::fetch_registers)
1990 (linux_process_target::low_fetch_register)
1991
daca57a7
TBA
19922020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1993
1994 Turn the 'cannot_fetch_register' and 'cannot_store_register'
1995 linux target ops into methods of linux_process_target.
1996
1997 * linux-low.h (struct linux_target_ops): Remove the low target ops.
1998 (class linux_process_target) <fetch_register>
1999 <store_register>
2000 <usr_fetch_inferior_registers>
2001 <usr_store_inferior_registers>
2002 <low_cannot_fetch_register>
2003 <low_cannot_fetch_register> Declare.
2004 * linux-low.cc (fetch_register): Turn into...
2005 (linux_process_target::fetch_register): ...this.
2006 (store_register): Turn into ...
2007 (linux_process_target::store_register): ...this.
2008 (usr_fetch_inferior_registers): Turn into...
2009 (linux_process_target::usr_fetch_inferior_registers): ...this.
2010 (usr_store_inferior_registers): Turn into...
2011 (linux_process_target::usr_store_inferior_registers): ...this.
2012 * linux-x86-low.cc (class x86_target)
2013 <low_cannot_fetch_register>
2014 <low_cannot_store_register>: Declare.
2015 (x86_cannot_store_register): Turn into...
2016 (x86_target::low_cannot_store_register): ...this.
2017 (x86_cannot_fetch_register): Turn into...
2018 (x86_target::low_cannot_fetch_register): ...this.
2019 (the_low_target): Remove the target op fields.
2020 * linux-aarch64-low.cc (class aarch64_target)
2021 <low_cannot_fetch_register>
2022 <low_cannot_store_register>: Declare.
2023 (aarch64_target::low_cannot_fetch_register)
2024 (aarch64_target::low_cannot_store_register): Define.
2025 (the_low_target): Remove the op fields.
2026 * linux-arm-low.cc (class arm_target)
2027 <low_cannot_fetch_register>
2028 <low_cannot_store_register>: Declare.
2029 (arm_cannot_fetch_register): Turn into...
2030 (arm_target::low_cannot_fetch_register): ...this.
2031 (arm_cannot_store_register): Turn into...
2032 (arm_target::low_cannot_store_register): ...this.
2033 (the_low_target): Remove the op fields.
2034 * linux-bfin-low.cc (class bfin_target)
2035 <low_cannot_fetch_register>
2036 <low_cannot_store_register>: Declare.
2037 (bfin_cannot_fetch_register): Turn into...
2038 (bfin_target::low_cannot_fetch_register): ...this.
2039 (bfin_cannot_store_register): Turn into...
2040 (bfin_target::low_cannot_store_register): ...this.
2041 (the_low_target): Remove the op fields.
2042 * linux-cris-low.cc (class cris_target)
2043 <low_cannot_fetch_register>
2044 <low_cannot_store_register>: Declare.
2045 (cris_cannot_fetch_register): Turn into...
2046 (cris_target::low_cannot_fetch_register): ...this.
2047 (cris_cannot_store_register): Turn into...
2048 (cris_target::low_cannot_store_register): ...this.
2049 (the_low_target): Remove the op fields.
2050 * linux-crisv32-low.cc (class crisv32_target)
2051 <low_cannot_fetch_register>
2052 <low_cannot_store_register>: Declare.
2053 (crisv32_target::low_cannot_fetch_register)
2054 (crisv32_target::low_cannot_store_register): Define.
2055 (the_low_target): Remove the op fields.
2056 * linux-ia64-low.cc (class ia64_target)
2057 <low_cannot_fetch_register>
2058 <low_cannot_store_register>: Declare.
2059 (ia64_cannot_fetch_register): Turn into...
2060 (ia64_target::low_cannot_fetch_register): ...this.
2061 (ia64_cannot_store_register): Turn into...
2062 (ia64_target::low_cannot_store_register): ...this.
2063 (the_low_target): Remove the op fields.
2064 * linux-m32r-low.cc (class m32r_target)
2065 <low_cannot_fetch_register>
2066 <low_cannot_store_register>: Declare.
2067 (m32r_cannot_fetch_register): Turn into...
2068 (m32r_target::low_cannot_fetch_register): ...this.
2069 (m32r_cannot_store_register): Turn into...
2070 (m32r_target::low_cannot_store_register): ...this.
2071 (the_low_target): Remove the op fields.
2072 * linux-m68k-low.cc (class m68k_target)
2073 <low_cannot_fetch_register>
2074 <low_cannot_store_register>: Declare.
2075 (m68k_cannot_fetch_register): Turn into...
2076 (m68k_target::low_cannot_fetch_register): ...this.
2077 (m68k_cannot_store_register): Turn into...
2078 (m68k_target::low_cannot_store_register): ...this.
2079 (the_low_target): Remove the op fields.
2080 * linux-mips-low.cc (class mips_target)
2081 <low_cannot_fetch_register>
2082 <low_cannot_store_register>: Declare.
2083 (mips_cannot_fetch_register): Turn into...
2084 (mips_target::low_cannot_fetch_register): ...this.
2085 (mips_cannot_store_register): Turn into...
2086 (mips_target::low_cannot_store_register): ...this.
2087 (get_usrregs_info): Inline at the call sites in
2088 low_cannot_fetch_register and low_cannot_store_register,
2089 and remove.
2090 (the_low_target): Remove the op fields.
2091 * linux-nios2-low.cc (class nios2_target)
2092 <low_cannot_fetch_register>
2093 <low_cannot_store_register>: Declare.
2094 (nios2_cannot_fetch_register): Turn into...
2095 (nios2_target::low_cannot_fetch_register): ...this.
2096 (nios2_cannot_store_register): Turn into...
2097 (nios2_target::low_cannot_store_register): ...this.
2098 (the_low_target): Remove the op fields.
2099 * linux-ppc-low.cc (class ppc_target)
2100 <low_cannot_fetch_register>
2101 <low_cannot_store_register>: Declare.
2102 (ppc_cannot_fetch_register): Turn into...
2103 (ppc_target::low_cannot_fetch_register): ...this.
2104 (ppc_cannot_store_register): Turn into...
2105 (ppc_target::low_cannot_store_register): ...this.
2106 (the_low_target): Remove the op fields.
2107 * linux-riscv-low.cc (class riscv_target)
2108 <low_cannot_fetch_register>
2109 <low_cannot_store_register>: Declare.
2110 (riscv_target::low_cannot_fetch_register)
2111 (riscv_target::low_cannot_store_register): Define.
2112 (the_low_target): Remove the op fields.
2113 * linux-s390-low.cc (class s390_target)
2114 <low_cannot_fetch_register>
2115 <low_cannot_store_register>: Declare.
2116 (s390_cannot_fetch_register): Turn into...
2117 (s390_target::low_cannot_fetch_register): ...this.
2118 (s390_cannot_store_register): Turn into...
2119 (s390_target::low_cannot_store_register): ...this.
2120 (the_low_target): Remove the op fields.
2121 * linux-sh-low.cc (class sh_target)
2122 <low_cannot_fetch_register>
2123 <low_cannot_store_register>: Declare.
2124 (sh_cannot_fetch_register): Turn into...
2125 (sh_target::low_cannot_fetch_register): ...this.
2126 (sh_cannot_store_register): Turn into...
2127 (sh_target::low_cannot_store_register): ...this.
2128 (the_low_target): Remove the op fields.
2129 * linux-sparc-low.cc (class sparc_target)
2130 <low_cannot_fetch_register>
2131 <low_cannot_store_register>: Declare.
2132 (sparc_cannot_fetch_register): Turn into...
2133 (sparc_target::low_cannot_fetch_register): ...this.
2134 (sparc_cannot_store_register): Turn into...
2135 (sparc_target::low_cannot_store_register): ...this.
2136 (the_low_target): Remove the op fields.
2137 * linux-tic6x-low.cc (class tic6x_target)
2138 <low_cannot_fetch_register>
2139 <low_cannot_store_register>: Declare.
2140 (tic6x_cannot_fetch_register): Turn into...
2141 (tic6x_target::low_cannot_fetch_register): ...this.
2142 (tic6x_cannot_store_register): Turn into...
2143 (tic6x_target::low_cannot_store_register): ...this.
2144 (the_low_target): Remove the op fields.
2145 * linux-tile-low.cc (class tile_target)
2146 <low_cannot_fetch_register>
2147 <low_cannot_store_register>: Declare.
2148 (tile_cannot_fetch_register): Turn into...
2149 (tile_target::low_cannot_fetch_register): ...this.
2150 (tile_cannot_store_register): Turn into...
2151 (tile_target::low_cannot_store_register): ...this.
2152 (the_low_target): Remove the op fields.
2153 * linux-xtensa-low.cc (class xtensa_target)
2154 <low_cannot_fetch_register>
2155 <low_cannot_store_register>: Declare.
2156 (xtensa_target::low_cannot_fetch_register)
2157 (xtensa_target::low_cannot_store_register): Define.
2158 (the_low_target): Remove the op fields.
2159
aa8d21c9
TBA
21602020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2161
2162 Turn the 'regs_info' linux target op into a method of
2163 linux_process_target.
2164
2165 * linux-low.h (struct linux_target_ops) <regs_info>: Remove.
2166 (class linux_process_target) <get_regs_info>: Define.
2167
2168 Update the callers below.
2169
2170 * linux-low.cc (linux_process_target::fetch_registers)
2171 (linux_process_target::store_registers)
2172 * proc-service.cc (gregset_info)
2173
2174 * linux-x86-low.cc (class x86_target) <get_regs_info>: Declare.
2175 (x86_linux_regs_info): Turn into ...
2176 (x86_target::get_regs_info): ...this.
2177 (the_low_target): Remove the op field.
2178 * linux-aarch64-low.cc (class aarch64_target) <get_regs_info>:
2179 Declare.
2180 (aarch64_regs_info): Turn into ...
2181 (aarch64_target::get_regs_info): ...this.
2182 (the_low_target): Remove the op field.
2183 * linux-arm-low.cc (class arm_target) <get_regs_info>: Declare.
2184 (arm_regs_info): Turn into ...
2185 (arm_target::get_regs_info): ...this.
2186 (the_low_target): Remove the op field.
2187 * linux-bfin-low.cc (class bfin_target) <get_regs_info>: Declare.
2188 (bfin_regs_info): Turn into ...
2189 (bfin_target::get_regs_info): ...this.
2190 (the_low_target): Remove the op field.
2191 * linux-cris-low.cc (class cris_target) <get_regs_info>: Declare.
2192 (cris_regs_info): Turn into ...
2193 (cris_target::get_regs_info): ...this.
2194 (the_low_target): Remove the op field.
2195 * linux-crisv32-low.cc (class crisv32_target) <get_regs_info>:
2196 Declare.
2197 (crisv32_regs_info): Turn into ...
2198 (crisv32_target::get_regs_info): ...this.
2199 (the_low_target): Remove the op field.
2200 * linux-ia64-low.cc (class ia64_target) <get_regs_info>: Declare.
2201 (ia64_regs_info): Turn into ...
2202 (ia64_target::get_regs_info): ...this.
2203 (the_low_target): Remove the op field.
2204 * linux-m32r-low.cc (class m32r_target) <get_regs_info>: Declare.
2205 (m32r_regs_info): Turn into ...
2206 (m32r_target::get_regs_info): ...this.
2207 (the_low_target): Remove the op field.
2208 * linux-m68k-low.cc (class m68k_target) <get_regs_info>: Declare.
2209 (m68k_regs_info): Turn into ...
2210 (m68k_target::get_regs_info): ...this.
2211 (the_low_target): Remove the op field.
2212 * linux-mips-low.cc (class mips_target) <get_regs_info>: Declare.
2213 (mips_regs_info): Turn into ...
2214 (mips_target::get_regs_info): ...this.
2215 (the_low_target): Remove the op field.
2216 (get_usrregs_info): Update the call to the op.
2217 * linux-nios2-low.cc (class nios2_target) <get_regs_info>: Declare.
2218 (nios2_regs_info): Turn into ...
2219 (nios2_target::get_regs_info): ...this.
2220 (the_low_target): Remove the op field.
2221 * linux-ppc-low.cc (class ppc_target) <get_regs_info>: Declare.
2222 (ppc_regs_info): Turn into ...
2223 (ppc_target::get_regs_info): ...this.
2224 (the_low_target): Remove the op field.
2225 * linux-riscv-low.cc (class riscv_target) <get_regs_info>: Declare.
2226 (riscv_regs_info): Turn into ...
2227 (riscv_target::get_regs_info): ...this.
2228 (the_low_target): Remove the op field.
2229 * linux-s390-low.cc (class s390_target) <get_regs_info>: Declare.
2230 (s390_regs_info): Turn into ...
2231 (s390_target::get_regs_info): ...this.
2232 (the_low_target): Remove the op field.
2233 (s390_collect_ptrace_register)
2234 (s390_supply_ptrace_register)
2235 (s390_fill_gregset): Update the call to the op.
2236 * linux-sh-low.cc (class sh_target) <get_regs_info>: Declare.
2237 (sh_regs_info): Turn into ...
2238 (sh_target::get_regs_info): ...this.
2239 (the_low_target): Remove the op field.
2240 * linux-sparc-low.cc (class sparc_target) <get_regs_info>: Declare.
2241 (sparc_regs_info): Turn into ...
2242 (sparc_target::get_regs_info): ...this.
2243 (the_low_target): Remove the op field.
2244 * linux-tic6x-low.cc (class tic6x_target) <get_regs_info>: Declare.
2245 (tic6x_regs_info): Turn into ...
2246 (tic6x_target::get_regs_info): ...this.
2247 (the_low_target): Remove the op field.
2248 * linux-tile-low.cc (class tile_target) <get_regs_info>: Declare.
2249 (tile_regs_info): Turn into ...
2250 (tile_target::get_regs_info): ...this.
2251 (the_low_target): Remove the op field.
2252 * linux-xtensa-low.cc (class xtensa_target) <get_regs_info>:
2253 Declare.
2254 (xtensa_regs_info): Turn into ...
2255 (xtensa_target::get_regs_info): ...this.
2256 (the_low_target): Remove the op field.
2257
797bcff5
TBA
22582020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2259
2260 Turn the 'arch_setup' linux target op into a method of
2261 linux_process_target.
2262
2263 * linux-low.h (struct linux_target_ops) <arch_setup>: Delete.
2264 (class linux_process_target) <arch_setup_thread>
2265 <low_arch_setup>: New declarations.
2266 * linux-low.cc (linux_arch_setup): Delete.
2267 (linux_arch_setup_thread): Turn into...
2268 (linux_process_target::arch_setup_thread): ... this.
2269
2270 Update the callers below.
2271
2272 (linux_process_target::handle_extended_wait)
2273 (linux_process_target::post_create_inferior)
2274 (linux_process_target::filter_event)
2275
2276 * linux-x86-low.cc (class x86_target) <low_arch_setup>: New
2277 declaration.
2278 (x86_linux_update_xmltarget): Turn into...
2279 (x86_target::update_xmltarget): ...this.
2280 (x86_linux_process_qsupported): Update the call to
2281 x86_linux_update_xmltarget.
2282 (x86_arch_setup): Turn into ...
2283 (x86_target::low_arch_setup): ...this.
2284 (the_low_target): Remove the op field.
2285 * linux-aarch64-low.cc (class aarch64_target) <low_arch_setup>: New
2286 declaration.
2287 (aarch64_arch_setup): Turn into ...
2288 (aarch64_target::low_arch_setup): ...this.
2289 (the_low_target): Remove the op field.
2290 * linux-arm-low.cc (class arm_target) <low_arch_setup>: New
2291 declaration.
2292 (arm_arch_setup): Turn into ...
2293 (arm_target::low_arch_setup): ...this.
2294 (the_low_target): Remove the op field.
2295 * linux-bfin-low.cc (class bfin_target) <low_arch_setup>: New
2296 declaration.
2297 (bfin_arch_setup): Turn into ...
2298 (bfin_target::low_arch_setup): ...this.
2299 (the_low_target): Remove the op field.
2300 * linux-cris-low.cc (class cris_target) <low_arch_setup>: New
2301 declaration.
2302 (cris_arch_setup): Turn into ...
2303 (cris_target::low_arch_setup): ...this.
2304 (the_low_target): Remove the op field.
2305 * linux-crisv32-low.cc (class crisv32_target) <low_arch_setup>: New
2306 declaration.
2307 (crisv32_arch_setup): Turn into ...
2308 (crisv32_target::low_arch_setup): ...this.
2309 (the_low_target): Remove the op field.
2310 * linux-ia64-low.cc (class ia64_target) <low_arch_setup>: New
2311 declaration.
2312 (ia64_arch_setup): Turn into ...
2313 (ia64_target::low_arch_setup): ...this.
2314 (the_low_target): Remove the op field.
2315 * linux-m32r-low.cc (class m32r_target) <low_arch_setup>: New
2316 declaration.
2317 (m32r_arch_setup): Turn into ...
2318 (m32r_target::low_arch_setup): ...this.
2319 (the_low_target): Remove the op field.
2320 * linux-m68k-low.cc (class m68k_target) <low_arch_setup>: New
2321 declaration.
2322 (m68k_arch_setup): Turn into ...
2323 (m68k_target::low_arch_setup): ...this.
2324 (the_low_target): Remove the op field.
2325 * linux-mips-low.cc (class mips_target) <low_arch_setup>: New
2326 declaration.
2327 (mips_arch_setup): Turn into ...
2328 (mips_target::low_arch_setup): ...this.
2329 (the_low_target): Remove the op field.
2330 * linux-nios2-low.cc (class nios2_target) <low_arch_setup>: New
2331 declaration.
2332 (nios2_arch_setup): Turn into ...
2333 (nios2_target::low_arch_setup): ...this.
2334 (the_low_target): Remove the op field.
2335 * linux-ppc-low.cc (class ppc_target) <low_arch_setup>: New
2336 declaration.
2337 (ppc_arch_setup): Turn into ...
2338 (ppc_target::low_arch_setup): ...this.
2339 (the_low_target): Remove the op field.
2340 * linux-riscv-low.cc (class riscv_target) <low_arch_setup>: New
2341 declaration.
2342 (riscv_arch_setup): Turn into ...
2343 (riscv_target::low_arch_setup): ...this.
2344 (the_low_target): Remove the op field.
2345 * linux-s390-low.cc (class s390_target) <low_arch_setup>: New
2346 declaration.
2347 (s390_arch_setup): Turn into ...
2348 (s390_target::low_arch_setup): ...this.
2349 (the_low_target): Remove the op field.
2350 * linux-sh-low.cc (class sh_target) <low_arch_setup>: New
2351 declaration.
2352 (sh_arch_setup): Turn into ...
2353 (sh_target::low_arch_setup): ...this.
2354 (the_low_target): Remove the op field.
2355 * linux-sparc-low.cc (class sparc_target) <low_arch_setup>: New
2356 declaration.
2357 (sparc_arch_setup): Turn into ...
2358 (sparc_target::low_arch_setup): ...this.
2359 (the_low_target): Remove the op field.
2360 * linux-tic6x-low.cc (class tic6x_target) <low_arch_setup>: New
2361 declaration.
2362 (tic6x_arch_setup): Turn into ...
2363 (tic6x_target::low_arch_setup): ...this.
2364 (the_low_target): Remove the op field.
2365 * linux-tile-low.cc (class tile_target) <low_arch_setup>: New
2366 declaration.
2367 (tile_arch_setup): Turn into ...
2368 (tile_target::low_arch_setup): ...this.
2369 (the_low_target): Remove the op field.
2370 * linux-xtensa-low.cc (class xtensa_target) <low_arch_setup>: New
2371 declaration.
2372 (xtensa_arch_setup): Turn into ...
2373 (xtensa_target::low_arch_setup): ...this.
2374 (the_low_target): Remove the op field.
2375
ef0478f6
TBA
23762020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2377
2378 * linux-low.h (the_linux_target): New extern declaration.
2379 * linux-low.cc (initialize_low): Use 'the_linux_target' to set
2380 'the_target'.
2381 (the_linux_target): Remove.
2382 * linux-x86-low.cc (class x86_target): New class.
2383 (the_x86_target): New static object.
2384 (the_linux_target): Define as pointer to the_x86_target.
2385 * linux-aarch64-low.cc (class aarch64_target): New class.
2386 (the_aarch64_target): New static object.
2387 (the_linux_target): Define as pointer to the_aarch64_target.
2388 * linux-arm-low.cc (class arm_target): New class.
2389 (the_arm_target): New static object.
2390 (the_linux_target): Define as pointer to the_arm_target.
2391 * linux-bfin-low.cc (class bfin_target): New class.
2392 (the_bfin_target): New static object.
2393 (the_linux_target): Define as pointer to the_bfin_target.
2394 * linux-cris-low.cc (class cris_target): New class.
2395 (the_cris_target): New static object.
2396 (the_linux_target): Define as pointer to the_cris_target.
2397 * linux-crisv32-low.cc (class crisv32_target): New class.
2398 (the_crisv32_target): New static object.
2399 (the_linux_target): Define as pointer to the_crisv32_target.
2400 * linux-ia64-low.cc (class ia64_target): New class.
2401 (the_ia64_target): New static object.
2402 (the_linux_target): Define as pointer to the_ia64_target.
2403 * linux-m32r-low.cc (class m32r_target): New class.
2404 (the_m32r_target): New static object.
2405 (the_linux_target): Define as pointer to the_m32r_target.
2406 * linux-m68k-low.cc (class m68k_target): New class.
2407 (the_m68k_target): New static object.
2408 (the_linux_target): Define as pointer to the_m68k_target.
2409 * linux-mips-low.cc (class mips_target): New class.
2410 (the_mips_target): New static object.
2411 (the_linux_target): Define as pointer to the_mips_target.
2412 * linux-nios2-low.cc (class nios2_target): New class.
2413 (the_nios2_target): New static object.
2414 (the_linux_target): Define as pointer to the_nios2_target.
2415 * linux-ppc-low.cc (class ppc_target): New class.
2416 (the_ppc_target): New static object.
2417 (the_linux_target): Define as pointer to the_ppc_target.
2418 * linux-riscv-low.cc (class riscv_target): New class.
2419 (the_riscv_target): New static object.
2420 (the_linux_target): Define as pointer to the_riscv_target.
2421 * linux-s390-low.cc (class s390_target): New class.
2422 (the_s390_target): New static object.
2423 (the_linux_target): Define as pointer to the_s390_target.
2424 * linux-sh-low.cc (class sh_target): New class.
2425 (the_sh_target): New static object.
2426 (the_linux_target): Define as pointer to the_sh_target.
2427 * linux-sparc-low.cc (class sparc_target): New class.
2428 (the_sparc_target): New static object.
2429 (the_linux_target): Define as pointer to the_sparc_target.
2430 * linux-tic6x-low.cc (class tic6x_target): New class.
2431 (the_tic6x_target): New static object.
2432 (the_linux_target): Define as pointer to the_tic6x_target.
2433 * linux-tile-low.cc (class tile_target): New class.
2434 (the_tile_target): New static object.
2435 (the_linux_target): Define as pointer to the_tile_target.
2436 * linux-xtensa-low.cc (class xtensa_target): New class.
2437 (the_xtensa_target): New static object.
2438 (the_linux_target): Define as pointer to the_xtensa_target.
2439
d16f3f6c
TBA
24402020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2441
2442 Turn some static functions in linux-low.cc into private methods of
2443 linux_process_target.
2444
2445 * linux-low.cc (handle_extended_wait): Turn into ...
2446 (linux_process_target::handle_extended_wait): ...this. Call
2447 'mourn' on 'this' object instead of 'the_target'.
2448 (maybe_move_out_of_jump_pad): Turn into...
2449 (linux_process_target::maybe_move_out_of_jump_pad): ...this.
2450 (linux_low_filter_event): Turn into...
2451 (linux_process_target::filter_event): ...this.
2452 (linux_wait_for_event_filtered): Turn into...
2453 (linux_process_target::wait_for_event_filtered): ...this.
2454 (linux_wait_for_event): Turn into...
2455 (linux_process_target::wait_for_event): ...this.
2456 (linux_wait_1): Turn into...
2457 (linux_process_target::wait_1): ...this.
2458 (wait_for_sigstop): Turn into...
2459 (linux_process_target::wait_for_sigstop): ...this.
2460 (move_out_of_jump_pad_callback): Turn into...
2461 (linux_process_target::move_out_of_jump_pad): ...this.
2462 (stop_all_lwps): Turn into...
2463 (linux_process_target::stop_all_lwps): ...this.
2464 (start_step_over): Turn into...
2465 (linux_process_target::start_step_over): ...this.
2466 (complete_ongoing_step_over): Turn into...
2467 (linux_process_target::complete_ongoing_step_over): ...this.
2468 (proceed_all_lwps): Turn into...
2469 (linux_process_target::proceed_all_lwps): ...this.
2470 (unstop_all_lwps): Turn into...
2471 (linux_process_target::unstop_all_lwps): ...this.
2472
2473 * linux-low.h (class linux_process_target)
2474 <handle_extended_wait>
2475 <maybe_move_out_of_jump_pad>
2476 filter_event>
2477 <wait_for_event_filtered>
2478 <wait_for_event>
2479 <wait_1>
2480 <wait_for_sigstop>
2481 <move_out_of_jump_pad>
2482 <stop_all_lwps>
2483 <start_step_over>
2484 <complete_ongoing_step_over>
2485 <proceed_all_lwps>
2486 <unstop_all_lwps>: Declare.
2487
2488 Update the callers below.
2489
2490 * linux-low.cc (linux_process_target::attach): Update.
2491 (linux_process_target::stabilize_threads): Ditto.
2492 (linux_process_target::wait): Ditto.
2493
a5863204
TBA
24942020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2495
2496 * linux-low.h (struct linux_target_ops): Update the comment for
2497 'cannot_store_register' to return 0 or 1.
2498 * linux-ppc-low.cc (ppc_cannot_store_register): Return 1 instead
2499 of 2.
2500
c884cc46
SM
25012020-03-20 Simon Marchi <simon.marchi@efficios.com>
2502
2503 * config.in: Re-generate.
2504 * configure: Re-generate.
2505
5a82b8a1
KR
25062020-03-17 Kamil Rytarowski <n54@gmx.com>
2507
2508 * regcache.cc (find_register_by_number): Update.
2509 * tdesc.cc (init_target_desc): Likewise.
2510 * tdesc.h (target_desc::reg_defs): Likewise.
2511
4635ff97
TT
25122020-03-12 Tom Tromey <tom@tromey.com>
2513
2514 * configure: Rebuild.
2515 * configure.ac (GDBSERVER_DEPFILES): Remove srv_selftest_objs.
2516 (WIN32APILIBS): New subst.
2517 * Makefile.in (SFILES, OBS, TAGS, GDBREPLAY_OBS): Remove
2518 gdbsupport files.
2519 (gdbsupport/%.o): Remove target.
2520 (GDBSUPPORT_BUILDDIR, GDBSUPPORT): New variables.
2521 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Add GDBSUPPORT.
2522 (WIN32APILIBS): New variable.
2523 (gdbserver$(EXEEXT)): Add WIN32APILIBS.
2524 (gdbreplay$(EXEEXT)): Likewise.
2525
9a665d62
TT
25262020-03-12 Tom Tromey <tom@tromey.com>
2527
2528 * config.in, configure: Rebuild.
2529 * configure.ac: Call ZW_GNU_GETTEXT_SISTER_DIR.
2530 * acinclude.m4: Include gettext-sister.m4.
2531 * Makefile.in (top_builddir, INTL, INTL_DEPS, INTL_CFLAGS): New
2532 variables.
2533 (INCLUDE_CFLAGS): Add INTL_CFLAGS.
2534 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Use INTL_DEPS, INTL.
2535
272cd5a3
SM
25362020-03-12 Simon Marchi <simon.marchi@efficios.com>
2537
2538 * acinclude.m4: Update path to selftest.m4.
2539
db6878ac
SM
25402020-03-12 Simon Marchi <simon.marchi@efficios.com>
2541
2542 * configure.ac: Don't source bfd/development.sh, move
2543 GDB_AC_COMMON higher.
2544 * configure: Re-generate.
2545
4d696a5c
SM
25462020-03-12 Simon Marchi <simon.marchi@efficios.com>
2547
2548 * configure: Re-generate.
2549
a0761e34
SM
25502020-03-11 Simon Marchi <simon.marchi@efficios.com>
2551
2552 * configure: Re-generate.
2553
20ea4a60
AB
25542020-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
2555
2556 * .dir-locals.el: New file.
2557
842806cb
TBA
25582020-03-05 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2559
2560 * .gitattributes: New file.
2561
442131c1
AB
25622020-03-02 Andrew Burgess <andrew.burgess@embecosm.com>
2563
2564 * remote-utils.cc (prepare_resume_reply): Add ability to convert T
2565 reply into an S reply.
2566 * server.cc (disable_packet_T): New global.
2567 (captured_main): Set new global when appropriate.
2568 * server.h (disable_packet_T): Declare.
2569
dda42c0b
TT
25702020-02-21 Tom Tromey <tom@tromey.com>
2571
2572 * Makefile.in (mostlyclean): New target.
2573
52405d85
TBA
25742020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2575
2576 * target.h (struct process_stratum_target): Remove.
2577 (class process_target): Rename to ...
2578 (class process_stratum_target): ... this.
2579 * linux-low.h (class linux_process_target): Derive from
2580 'process_stratum_target'.
2581 * linux-low.cc (linux_target_ops): Remove.
2582 (initialize_low): Set the_target to the singleton instance of
2583 linux_process_target.
2584 * lynx-low.h (class lynx_process_target): Derive from
2585 'process_stratum_target'.
2586 * lynx-low.cc (lynx_target_ops): Remove.
2587 (initialize_low): Set the_target to the singleton instance of
2588 lynx_process_target.
2589 * nto-low.h (class nto_process_target): Derive from
2590 'process_stratum_target'.
2591 * nto-low.cc (nto_target_ops): Remove.
2592 (initialize_low): Set the_target to the singleton instance of
2593 nto_process_target.
2594 * win32-low.h (class win32_process_target): Derive from
2595 'process_stratum_target'.
2596 * win32-low.cc (win32_target_ops): Remove.
2597 (initialize_low): Set the_target to the singleton instance of
2598 win32_process_target.
2599
2600 Replace 'the_target->pt' with 'the_target' in the uses below.
2601
2602 * hostio.cc (hostio_error)
2603 (handle_setfs)
2604 (handle_open)
2605 (handle_unlink)
2606 (handle_readlink)
2607 * linux-aarch32-low.cc (arm_breakpoint_at)
2608 * linux-aarch64-low.cc (aarch64_breakpoint_at)
2609 * linux-arm-low.cc (arm_sigreturn_next_pc)
2610 (arm_get_hwcap)
2611 (arm_get_syscall_trapinfo)
2612 * linux-cris-low.cc (cris_breakpoint_at)
2613 * linux-crisv32-low.cc (cris_breakpoint_at)
2614 * linux-low.cc (handle_extended_wait)
2615 (linux_wait_1)
2616 (linux_read_memory)
2617 (linux_process_target::breakpoint_kind_from_pc)
2618 (linux_get_auxv)
2619 * linux-m32r-low.cc (m32r_breakpoint_at)
2620 * linux-mips-low.cc (mips_breakpoint_at)
2621 * linux-nios2-low.cc (nios2_breakpoint_at)
2622 * linux-ppc-low.cc (ppc_breakpoint_at)
2623 * linux-s390-low.cc (s390_get_hwcap)
2624 * linux-sh-low.cc (sh_breakpoint_at)
2625 * linux-sparc-low.cc (sparc_fill_gregset_to_stack)
2626 (sparc_store_gregset_from_stack)
2627 (sparc_breakpoint_at)
2628 * linux-tic6x-low.cc (tic6x_breakpoint_at)
2629 * linux-tile-low.cc (tile_breakpoint_at)
2630 * linux-x86-low.cc (x86_breakpoint_at)
2631 * linux-xtensa-low.cc (xtensa_breakpoint_at)
2632 * mem-break.cc (bp_size)
2633 (bp_opcode)
2634 (insert_memory_breakpoint)
2635 (set_raw_breakpoint_at)
2636 (delete_raw_breakpoint)
2637 (z_type_supported)
2638 (uninsert_raw_breakpoint)
2639 (reinsert_raw_breakpoint)
2640 (validate_inserted_breakpoint)
2641 * regcache.cc (regcache_read_pc)
2642 (regcache_write_pc)
2643 * remote-utils.cc (putpkt_binary_1)
2644 (input_interrupt)
2645 (getpkt)
2646 (prepare_resume_reply)
2647 * server.cc (handle_general_set)
2648 (handle_detach)
2649 (handle_qxfer_auxv)
2650 (handle_qxfer_exec_file)
2651 (handle_qxfer_libraries_svr4)
2652 (handle_qxfer_osdata)
2653 (handle_qxfer_siginfo)
2654 (handle_qxfer_fdpic)
2655 (handle_query)
2656 (resume)
2657 (handle_v_requests)
2658 (queue_stop_reply_callback)
2659 (captured_main)
2660 * target.cc (prepare_to_access_memory)
2661 (done_accessing_memory)
2662 (read_inferior_memory)
2663 (target_write_memory)
2664 (target_stop_and_wait)
2665 (target_wait)
2666 (target_mourn_inferior)
2667 (target_continue_no_signal)
2668 (target_continue)
2669 (target_supports_multi_process)
2670 (kill_inferior)
2671 * target.h
2672 (target_create_inferior)
2673 (target_post_create_inferior)
2674 (myattach)
2675 (target_supports_fork_events)
2676 (target_supports_vfork_events)
2677 (target_supports_exec_events)
2678 (target_handle_new_gdb_connection)
2679 (detach_inferior)
2680 (mythread_alive)
2681 (fetch_inferior_registers)
2682 (store_inferior_registers)
2683 (join_inferior)
2684 (target_supports_non_stop)
2685 (target_async)
2686 (target_process_qsupported)
2687 (target_supports_catch_syscall)
2688 (target_get_ipa_tdesc_idx)
2689 (target_supports_tracepoints)
2690 (target_supports_fast_tracepoints)
2691 (target_get_min_fast_tracepoint_insn_len)
2692 (target_thread_stopped)
2693 (target_pause_all)
2694 (target_unpause_all)
2695 (target_stabilize_threads)
2696 (target_install_fast_tracepoint_jump_pad)
2697 (target_emit_ops)
2698 (target_supports_disable_randomization)
2699 (target_supports_agent)
2700 (target_enable_btrace)
2701 (target_disable_btrace)
2702 (target_read_btrace)
2703 (target_read_btrace_conf)
2704 (target_supports_range_stepping)
2705 (target_supports_stopped_by_sw_breakpoint)
2706 (target_stopped_by_sw_breakpoint)
2707 (target_supports_stopped_by_hw_breakpoint)
2708 (target_supports_hardware_single_step)
2709 (target_stopped_by_hw_breakpoint)
2710 (target_breakpoint_kind_from_pc)
2711 (target_breakpoint_kind_from_current_state)
2712 (target_supports_software_single_step)
2713 (target_core_of_thread)
2714 (target_thread_name)
2715 (target_thread_handle)
2716 * win32-low.cc (do_initial_child_stuff)
2717
2718 Rename target op default definitions listed below.
2719
2720 * target.cc (process_target::post_create_inferior): Rename as ...
2721 (process_stratum_target::post_create_inferior): ... this.
2722 (process_target::prepare_to_access_memory): Rename as ...
2723 (process_stratum_target::prepare_to_access_memory): ... this.
2724 (process_target::done_accessing_memory): Rename as ...
2725 (process_stratum_target::done_accessing_memory): ... this.
2726 (process_target::look_up_symbols): Rename as ...
2727 (process_stratum_target::look_up_symbols): ... this.
2728 (process_target::supports_read_auxv): Rename as ...
2729 (process_stratum_target::supports_read_auxv): ... this.
2730 (process_target::read_auxv): Rename as ...
2731 (process_stratum_target::read_auxv): ... this.
2732 (process_target::supports_z_point_type): Rename as ...
2733 (process_stratum_target::supports_z_point_type): ... this.
2734 (process_target::insert_point): Rename as ...
2735 (process_stratum_target::insert_point): ... this.
2736 (process_target::remove_point): Rename as ...
2737 (process_stratum_target::remove_point): ... this.
2738 (process_target::stopped_by_sw_breakpoint): Rename as ...
2739 (process_stratum_target::stopped_by_sw_breakpoint): ... this.
2740 (process_target::supports_stopped_by_sw_breakpoint): Rename as ...
2741 (process_stratum_target::supports_stopped_by_sw_breakpoint): ... this.
2742 (process_target::stopped_by_hw_breakpoint): Rename as ...
2743 (process_stratum_target::stopped_by_hw_breakpoint): ... this.
2744 (process_target::supports_stopped_by_hw_breakpoint): Rename as ...
2745 (process_stratum_target::supports_stopped_by_hw_breakpoint): ... this.
2746 (process_target::supports_hardware_single_step): Rename as ...
2747 (process_stratum_target::supports_hardware_single_step): ... this.
2748 (process_target::stopped_by_watchpoint): Rename as ...
2749 (process_stratum_target::stopped_by_watchpoint): ... this.
2750 (process_target::stopped_data_address): Rename as ...
2751 (process_stratum_target::stopped_data_address): ... this.
2752 (process_target::supports_read_offsets): Rename as ...
2753 (process_stratum_target::supports_read_offsets): ... this.
2754 (process_target::read_offsets): Rename as ...
2755 (process_stratum_target::read_offsets): ... this.
2756 (process_target::supports_get_tls_address): Rename as ...
2757 (process_stratum_target::supports_get_tls_address): ... this.
2758 (process_target::get_tls_address): Rename as ...
2759 (process_stratum_target::get_tls_address): ... this.
2760 (process_target::hostio_last_error): Rename as ...
2761 (process_stratum_target::hostio_last_error): ... this.
2762 (process_target::supports_qxfer_osdata): Rename as ...
2763 (process_stratum_target::supports_qxfer_osdata): ... this.
2764 (process_target::qxfer_osdata): Rename as ...
2765 (process_stratum_target::qxfer_osdata): ... this.
2766 (process_target::supports_qxfer_siginfo): Rename as ...
2767 (process_stratum_target::supports_qxfer_siginfo): ... this.
2768 (process_target::qxfer_siginfo): Rename as ...
2769 (process_stratum_target::qxfer_siginfo): ... this.
2770 (process_target::supports_non_stop): Rename as ...
2771 (process_stratum_target::supports_non_stop): ... this.
2772 (process_target::async): Rename as ...
2773 (process_stratum_target::async): ... this.
2774 (process_target::start_non_stop): Rename as ...
2775 (process_stratum_target::start_non_stop): ... this.
2776 (process_target::supports_multi_process): Rename as ...
2777 (process_stratum_target::supports_multi_process): ... this.
2778 (process_target::supports_fork_events): Rename as ...
2779 (process_stratum_target::supports_fork_events): ... this.
2780 (process_target::supports_vfork_events): Rename as ...
2781 (process_stratum_target::supports_vfork_events): ... this.
2782 (process_target::supports_exec_events): Rename as ...
2783 (process_stratum_target::supports_exec_events): ... this.
2784 (process_target::handle_new_gdb_connection): Rename as ...
2785 (process_stratum_target::handle_new_gdb_connection): ... this.
2786 (process_target::handle_monitor_command): Rename as ...
2787 (process_stratum_target::handle_monitor_command): ... this.
2788 (process_target::core_of_thread): Rename as ...
2789 (process_stratum_target::core_of_thread): ... this.
2790 (process_target::supports_read_loadmap): Rename as ...
2791 (process_stratum_target::supports_read_loadmap): ... this.
2792 (process_target::read_loadmap): Rename as ...
2793 (process_stratum_target::read_loadmap): ... this.
2794 (process_target::process_qsupported): Rename as ...
2795 (process_stratum_target::process_qsupported): ... this.
2796 (process_target::supports_tracepoints): Rename as ...
2797 (process_stratum_target::supports_tracepoints): ... this.
2798 (process_target::read_pc): Rename as ...
2799 (process_stratum_target::read_pc): ... this.
2800 (process_target::write_pc): Rename as ...
2801 (process_stratum_target::write_pc): ... this.
2802 (process_target::supports_thread_stopped): Rename as ...
2803 (process_stratum_target::supports_thread_stopped): ... this.
2804 (process_target::thread_stopped): Rename as ...
2805 (process_stratum_target::thread_stopped): ... this.
2806 (process_target::supports_get_tib_address): Rename as ...
2807 (process_stratum_target::supports_get_tib_address): ... this.
2808 (process_target::get_tib_address): Rename as ...
2809 (process_stratum_target::get_tib_address): ... this.
2810 (process_target::pause_all): Rename as ...
2811 (process_stratum_target::pause_all): ... this.
2812 (process_target::unpause_all): Rename as ...
2813 (process_stratum_target::unpause_all): ... this.
2814 (process_target::stabilize_threads): Rename as ...
2815 (process_stratum_target::stabilize_threads): ... this.
2816 (process_target::supports_fast_tracepoints): Rename as ...
2817 (process_stratum_target::supports_fast_tracepoints): ... this.
2818 (process_target::get_min_fast_tracepoint_insn_len): Rename as ...
2819 (process_stratum_target::get_min_fast_tracepoint_insn_len): ... this.
2820 (process_target::emit_ops): Rename as ...
2821 (process_stratum_target::emit_ops): ... this.
2822 (process_target::supports_disable_randomization): Rename as ...
2823 (process_stratum_target::supports_disable_randomization): ... this.
2824 (process_target::supports_qxfer_libraries_svr4): Rename as ...
2825 (process_stratum_target::supports_qxfer_libraries_svr4): ... this.
2826 (process_target::qxfer_libraries_svr4): Rename as ...
2827 (process_stratum_target::qxfer_libraries_svr4): ... this.
2828 (process_target::supports_agent): Rename as ...
2829 (process_stratum_target::supports_agent): ... this.
2830 (process_target::enable_btrace): Rename as ...
2831 (process_stratum_target::enable_btrace): ... this.
2832 (process_target::disable_btrace): Rename as ...
2833 (process_stratum_target::disable_btrace): ... this.
2834 (process_target::read_btrace): Rename as ...
2835 (process_stratum_target::read_btrace): ... this.
2836 (process_target::read_btrace_conf): Rename as ...
2837 (process_stratum_target::read_btrace_conf): ... this.
2838 (process_target::supports_range_stepping): Rename as ...
2839 (process_stratum_target::supports_range_stepping): ... this.
2840 (process_target::supports_pid_to_exec_file): Rename as ...
2841 (process_stratum_target::supports_pid_to_exec_file): ... this.
2842 (process_target::pid_to_exec_file): Rename as ...
2843 (process_stratum_target::pid_to_exec_file): ... this.
2844 (process_target::supports_multifs): Rename as ...
2845 (process_stratum_target::supports_multifs): ... this.
2846 (process_target::multifs_open): Rename as ...
2847 (process_stratum_target::multifs_open): ... this.
2848 (process_target::multifs_unlink): Rename as ...
2849 (process_stratum_target::multifs_unlink): ... this.
2850 (process_target::multifs_readlink): Rename as ...
2851 (process_stratum_target::multifs_readlink): ... this.
2852 (process_target::breakpoint_kind_from_pc): Rename as ...
2853 (process_stratum_target::breakpoint_kind_from_pc): ... this.
2854 (process_target::breakpoint_kind_from_current_state): Rename as ...
2855 (process_stratum_target::breakpoint_kind_from_current_state): ... this.
2856 (process_target::thread_name): Rename as ...
2857 (process_stratum_target::thread_name): ... this.
2858 (process_target::thread_handle): Rename as ...
2859 (process_stratum_target::thread_handle): ... this.
2860 (process_target::supports_software_single_step): Rename as ...
2861 (process_stratum_target::supports_software_single_step): ... this.
2862 (process_target::supports_catch_syscall): Rename as ...
2863 (process_stratum_target::supports_catch_syscall): ... this.
2864 (process_target::get_ipa_tdesc_idx): Rename as ...
2865 (process_stratum_target::get_ipa_tdesc_idx): ... this.
2866
478f9adf
PA
28672020-02-20 Pedro Alves <palves@redhat.com>
2868
2869 * target.cc (set_target_ops): Simply copy the given target pointer
2870 instead of creating a copy of the pointed object.
2871
d633e831
TBA
28722020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2873
2874 Turn process_stratum_target's get_ipa_tdesc_idx op into a method
2875 of process_target.
2876
2877 * target.h (struct process_stratum_target): Remove the target op.
2878 (class process_target): Add the target op.
2879 (target_get_ipa_tdesc_idx): Update the macro.
2880 * target.cc (process_target::get_ipa_tdesc_idx): Define.
2881
2882 Update the derived classes and callers below.
2883
2884 * linux-low.cc (linux_target_ops): Update.
2885 (linux_get_ipa_tdesc_idx): Turn into ...
2886 (linux_process_target::get_ipa_tdesc_idx): ... this.
2887 * linux-low.h (class linux_process_target): Update.
2888 * lynx-low.cc (lynx_target_ops): Update.
2889 * nto-low.cc (nto_target_ops): Update.
2890 * win32-low.cc (win32_target_ops): Update.
2891
bc8d3ae4
TBA
28922020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2893
2894 Turn process_stratum_target's supports_catch_syscall op into a
2895 method of process_target.
2896
2897 * target.h (struct process_stratum_target): Remove the target op.
2898 (class process_target): Add the target op.
2899 (target_supports_catch_syscall): Update the macro.
2900 * target.cc (process_target::supports_catch_syscall): Define.
2901
2902 Update the derived classes and callers below.
2903
2904 * linux-low.cc (linux_target_ops): Update.
2905 (linux_supports_catch_syscall): Turn into ...
2906 (linux_process_target::supports_catch_syscall): ... this.
2907 * linux-low.h (class linux_process_target): Update.
2908 * lynx-low.cc (lynx_target_ops): Update.
2909 * nto-low.cc (nto_target_ops): Update.
2910 * win32-low.cc (win32_target_ops): Update.
2911
5303a34f
TBA
29122020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2913
2914 Turn process_stratum_target's supports_software_single_step op
2915 into a method of process_target.
2916
2917 * target.h (struct process_stratum_target): Remove the target op.
2918 (class process_target): Add the target op.
2919 (target_supports_software_single_step): Update the macro.
2920 * target.cc (process_target::supports_software_single_step): Define.
2921
2922 Update the derived classes and callers below.
2923
2924 * linux-low.cc (linux_target_ops): Update.
2925 (linux_supports_software_single_step): Turn into ...
2926 (linux_process_target::supports_software_single_step): ... this.
2927 * linux-low.h (class linux_process_target): Update.
2928 * lynx-low.cc (lynx_target_ops): Update.
2929 * nto-low.cc (nto_target_ops): Update.
2930 * win32-low.cc (win32_target_ops): Update.
2931
7f63b89b
TBA
29322020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2933
2934 Turn process_stratum_target's thread_name and thread_handle ops
2935 into methods of process_target.
2936
2937 * target.h (struct process_stratum_target): Remove the target ops.
2938 (class process_target): Add the target ops.
2939 (target_thread_name): Update the macro.
2940 (target_thread_handle): Update the macro.
2941 * target.cc (process_target::thread_name): Define.
2942 (process_target::thread_handle): Define.
2943
2944 Update the derived classes and callers below.
2945
2946 * linux-low.cc (linux_target_ops): Update.
2947 (linux_process_target::thread_name): Define.
2948 (linux_process_target::thread_handle): Define.
2949 * linux-low.h (class linux_process_target): Update.
2950 * lynx-low.cc (lynx_target_ops): Update.
2951 * nto-low.cc (nto_target_ops): Update.
2952 * win32-low.cc (win32_target_ops): Update.
2953
d367006f
TBA
29542020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2955
2956 Turn process_stratum_target's breakpoint_kind_from_pc,
2957 sw_breakpoint_from_kind, and breakpoint_kind_from_current_state
2958 ops into methods of process_target.
2959
2960 * target.h (struct process_stratum_target): Remove the target op.
2961 (class process_target): Add the target op.
2962 (target_breakpoint_kind_from_pc): Update the macro.
2963 (target_breakpoint_kind_from_current_state): Update the macro.
2964 (default_breakpoint_kind_from_pc): Remove declaration.
2965 * target.cc (default_breakpoint_kind_from_pc): Turn into ...
2966 (process_target::breakpoint_kind_from_pc): ... this.
2967 (process_target::breakpoint_kind_from_current_state): Define.
2968
2969 Update the derived classes and callers below.
2970
2971 * mem-break.cc (bp_size): Update.
2972 (bp_opcode): Update.
2973 * linux-low.cc (linux_target_ops): Update.
2974 (linux_wait_1): Update.
2975 (linux_breakpoint_kind_from_pc): Turn into ...
2976 (linux_process_target::breakpoint_kind_from_pc): ... this.
2977 (linux_sw_breakpoint_from_kind): Turn into ...
2978 (linux_process_target::sw_breakpoint_from_kind): ... this.
2979 (linux_breakpoint_kind_from_current_state): Turn into ...
2980 (linux_process_target::breakpoint_kind_from_current_state): ... this.
2981 * linux-low.h (class linux_process_target): Update.
2982 * lynx-low.cc (lynx_target_ops): Update.
2983 (lynx_process_target::sw_breakpoint_from_kind): Define.
2984 * lynx-low.h (class lynx_process_target): Update.
2985 * nto-low.cc (nto_target_ops): Update.
2986 (nto_sw_breakpoint_from_kind): Turn into ...
2987 (nto_process_target::sw_breakpoint_from_kind): ... this.
2988 * nto-low.h (class nto_process_target): Update.
2989 * win32-low.cc (win32_target_ops): Update.
2990 (win32_sw_breakpoint_from_kind): Turn into ...
2991 (win32_process_target::sw_breakpoint_from_kind): ... this.
2992 * win32-low.h (class win32_process_target): Update.
2993
c9b7b804
TBA
29942020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2995
2996 Turn process_stratum_target's multifs_open, multifs_readlink,
2997 multifs_unlink ops into methods of process_target.
2998
2999 * target.h (struct process_stratum_target): Remove the target ops.
3000 (class process_target): Add the target ops. Also add
3001 'supports_multifs'.
3002 * target.cc: Include "fcntl.h", "unistd.h", "sys/types.h", and
3003 "sys/stat.h".
3004 (process_target::supports_multifs): Define.
3005 (process_target::multifs_open): Define.
3006 (process_target::multifs_readlink): Define.
3007 (process_target::multifs_unlink): Define.
3008
3009 Update the derived classes and callers below.
3010
3011 * hostio.cc (handle_setfs): Update.
3012 (handle_open): Update.
3013 (handle_unlink): Update.
3014 (handle_readlink): Update.
3015 * linux-low.cc (linux_target_ops): Update.
3016 (linux_process_target::supports_multifs): Define.
3017 (linux_process_target::multifs_open): Define.
3018 (linux_process_target::multifs_readlink): Define.
3019 (linux_process_target::multifs_unlink): Define.
3020 * linux-low.h (class linux_process_target): Update.
3021 * lynx-low.cc (lynx_target_ops): Update.
3022 * nto-low.cc (nto_target_ops): Update.
3023 * win32-low.cc (win32_target_ops): Update.
3024
8247b823
TBA
30252020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3026
3027 Turn process_stratum_target's pid_to_exec_file op into a method
3028 of process_target.
3029
3030 * target.h (struct process_stratum_target): Remove the target op.
3031 (class process_target): Add the target op. Also add
3032 'supports_pid_to_exec_file'.
3033 * target.cc (process_target::pid_to_exec_file): Define.
3034 (process_target::supports_pid_to_exec_file): Define.
3035
3036 Update the derived classes and callers below.
3037
3038 * server.cc (handle_qxfer_exec_file): Update.
3039 (handle_query): Update.
3040 * linux-low.cc (linux_target_ops): Update.
3041 (linux_process_target::supports_pid_to_exec_file): Define.
3042 (linux_process_target::pid_to_exec_file): Define.
3043 * linux-low.h (class linux_process_target): Update.
3044 * lynx-low.cc (lynx_target_ops): Update.
3045 * nto-low.cc (nto_target_ops): Update.
3046 * win32-low.cc (win32_target_ops): Update.
3047
2526e0cd
TBA
30482020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3049
3050 Turn process_stratum_target's supports_range_stepping op into a
3051 method of process_target.
3052
3053 * target.h (struct process_stratum_target): Remove the target op.
3054 (class process_target): Add the target op.
3055 (target_supports_range_stepping): Update the macro.
3056 * target.cc (process_target::supports_range_stepping): Define.
3057
3058 Update the derived classes and callers below.
3059
3060 * linux-low.cc (linux_target_ops): Update.
3061 (linux_supports_range_stepping): Turn into ...
3062 (linux_process_target::supports_range_stepping): ... this.
3063 * linux-low.h (class linux_process_target): Update.
3064 * lynx-low.cc (lynx_target_ops): Update.
3065 * nto-low.cc (nto_target_ops): Update.
3066 * win32-low.cc (win32_target_ops): Update.
3067
79597bdd
TBA
30682020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3069
3070 Turn process_stratum_target's btrace-related ops (enable_btrace,
3071 disable_btrace, read_btrace, read_btrace_conf) into methods of
3072 process_target.
3073
3074 * target.h (struct process_stratum_target): Remove the target ops.
3075 (class process_target): Add the target ops.
3076 (target_enable_btrace): Update.
3077 (target_disable_btrace): Update.
3078 (target_read_btrace): Update.
3079 (target_read_btrace_conf): Update.
3080 * target.cc (process_target::enable_btrace): Define.
3081 (process_target::disable_btrace): Define.
3082 (process_target::read_btrace): Define.
3083 (process_target::read_btrace_conf): Define.
3084
3085 Update the derived classes and callers below.
3086
3087 * linux-low.cc (linux_target_ops): Update.
3088 (linux_process_target:enable_btrace): Define as a wrapper around
3089 linux_enable_btrace.
3090 (linux_low_disable_btrace): Turn into ...
3091 (linux_process_target::disable_btrace): ... this.
3092 (linux_low_read_btrace): Turn into ...
3093 (linux_process_target::read_btrace): ... this.
3094 (linux_low_btrace_conf): Turn into ...
3095 (linux_process_target::read_btrace_conf): ... this.
3096 * linux-low.h (class linux_process_target): Update.
3097 * lynx-low.cc (lynx_target_ops): Update.
3098 * nto-low.cc (nto_target_ops): Update.
3099 * win32-low.cc (win32_target_ops): Update.
3100
c0245cb9
TBA
31012020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3102
3103 Turn process_stratum_target's supports_agent op into a method of
3104 process_target.
3105
3106 * target.h (struct process_stratum_target): Remove the target op.
3107 (class process_target): Add the target op.
3108 (target_supports_agent): Update the macro.
3109 * target.cc (process_target::supports_agent): Define.
3110
3111 Update the derived classes and callers below.
3112
3113 * linux-low.cc (linux_target_ops): Update.
3114 (linux_supports_agent): Turn into ...
3115 (linux_process_target::supports_agent): ... this.
3116 * linux-low.h (class linux_process_target): Update.
3117 * lynx-low.cc (lynx_target_ops): Update.
3118 * nto-low.cc (nto_target_ops): Update.
3119 * win32-low.cc (win32_target_ops): Update.
3120
974387bb
TBA
31212020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3122
3123 Turn process_stratum_target's qxfer_libraries_svr4 op into a
3124 method of process_target.
3125
3126 * target.h (struct process_stratum_target): Remove the target op.
3127 (class process_target): Add the target op. Also add
3128 'supports_qxfer_libraries_svr4'.
3129 * target.cc (process_target::qxfer_libraries_svr4): Define.
3130 (process_target::supports_qxfer_libraries_svr4): Define.
3131
3132 Update the derived classes and callers below.
3133
3134 * server.cc (handle_qxfer_libraries_svr4): Update.
3135 (handle_query): Update.
3136 * linux-low.cc (linux_target_ops): Update.
3137 (linux_process_target::supports_qxfer_libraries_svr4): Define.
3138 (linux_qxfer_libraries_svr4): Turn into ...
3139 (linux_process_target::qxfer_libraries_svr4): ... this.
3140 * linux-low.h (class linux_process_target): Update.
3141 * lynx-low.cc (lynx_target_ops): Update.
3142 * nto-low.cc (nto_target_ops): Update.
3143 * win32-low.cc (win32_target_ops): Update.
3144
c756403b
TBA
31452020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3146
3147 Turn process_stratum_target's supports_disable_randomization op
3148 into a method of process_target.
3149
3150 * target.h (struct process_stratum_target): Remove the target op.
3151 (class process_target): Add the target op.
3152 (target_supports_disable_randomization): Update the macro.
3153 * target.cc (process_target::supports_disable_randomization): Define.
3154
3155 Update the derived classes and callers below.
3156
3157 * linux-low.cc (linux_target_ops): Update.
3158 (linux_supports_disable_randomization): Turn into ...
3159 (linux_process_target::supports_disable_randomization): ... this.
3160 * linux-low.h (class linux_process_target): Update.
3161 * lynx-low.cc (lynx_target_ops): Update.
3162 * nto-low.cc (nto_target_ops): Update.
3163 * win32-low.cc (win32_target_ops): Update.
3164
345dafad
TBA
31652020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3166
3167 Turn process_stratum_target's emit_ops op into a method of
3168 process_target.
3169
3170 * target.h (struct process_stratum_target): Remove the target op.
3171 (class process_target): Add the target op.
3172 (target_emit_ops): Update the macro.
3173 * target.cc (process_target::emit_ops): Define.
3174
3175 Update the derived classes and callers below.
3176
3177 * linux-low.cc (linux_target_ops): Update.
3178 (linux_emit_ops): Turn into ...
3179 (linux_process_target::emit_ops): ... this.
3180 * linux-low.h (class linux_process_target): Update.
3181 * lynx-low.cc (lynx_target_ops): Update.
3182 * nto-low.cc (nto_target_ops): Update.
3183 * win32-low.cc (win32_target_ops): Update.
3184
c23c9391
TBA
31852020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3186
3187 Turn process_stratum_target's install_fast_tracepoint_jump_pad
3188 and get_min_fast_tracepoint_insn_len ops into methods of
3189 process_target.
3190
3191 * target.h (struct process_stratum_target): Remove the target ops.
3192 (class process_target): Add the target ops. Also add
3193 'supports_fast_tracepoints'.
3194 (target_supports_fast_tracepoints): Update the macro.
3195 (target_get_min_fast_tracepoint_insn_len): Update the macro.
3196 (install_fast_tracepoint_jump_pad): Update and rename the macro
3197 to ...
3198 (target_install_fast_tracepoint_jump_pad): ... this.
3199 * target.cc (process_target::supports_fast_tracepoints): Define.
3200 (process_target::install_fast_tracepoint_jump_pad): Define.
3201 (process_target::get_min_fast_tracepoint_insn_len): Define.
3202
3203 Update the derived classes and callers below.
3204
3205 * tracepoint.cc (install_fast_tracepoint): Update.
3206 * linux-low.cc (linux_target_ops): Update.
3207 (linux_process_target::supports_fast_tracepoints): Define.
3208 (linux_install_fast_tracepoint_jump_pad): Turn into ...
3209 (linux_process_target::install_fast_tracepoint_jump_pad): ... this.
3210 (linux_get_min_fast_tracepoint_insn_len): Turn into ...
3211 (linux_process_target::get_min_fast_tracepoint_insn_len): ... this.
3212 * linux-low.h (class linux_process_target): Update.
3213 * lynx-low.cc (lynx_target_ops): Update.
3214 * nto-low.cc (nto_target_ops): Update.
3215 * win32-low.cc (win32_target_ops): Update.
3216
5c9eb2f2
TBA
32172020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3218
3219 Turn process_stratum_target's stabilize_threads op into a
3220 method of process_target.
3221
3222 * target.h (struct process_stratum_target): Remove the target op.
3223 (class process_target): Add the target op.
3224 (target_stabilize_threads): Update the macro.
3225 * target.cc (process_target::stabilize_threads): Define.
3226
3227 Update the derived classes and callers below.
3228
3229 * server.cc (handle_status): Update.
3230 * tracepoint.cc (cmd_qtdp): Update.
3231 (cmd_qtstart): Update.
3232 * linux-low.cc (linux_target_ops): Update.
3233 (linux_stabilize_threads): Turn into ...
3234 (linux_process_target::stabilize_threads): ... this.
3235 (linux_wait_1): Update.
3236 * linux-low.h (class linux_process_target): Update.
3237 * lynx-low.cc (lynx_target_ops): Update.
3238 * nto-low.cc (nto_target_ops): Update.
3239 * win32-low.cc (win32_target_ops): Update.
3240
29e8dc09
TBA
32412020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3242
3243 Turn process_stratum_target's pause_all and unpause_all ops
3244 into methods of process_target.
3245
3246 * target.h (struct process_stratum_target): Remove the target ops.
3247 (class process_target): Add the target ops.
3248 (pause_all): Update the macro and rename to...
3249 (target_pause_all): ... this.
3250 (unpause_all): Update the macro and rename to...
3251 (target_unpause_all): ... this.
3252 * target.cc (process_target::pause_all): Define.
3253 (process_target::unpause_all): Define.
3254
3255 Update the derived classes and callers below.
3256
3257 * server.cc (handle_status): Update.
3258 * tracepoint.cc (clear_installed_tracepoints): Update.
3259 (cmd_qtdp): Update.
3260 (cmd_qtstart): Update.
3261 (stop_tracing): Update.
3262 (cmd_qtstatus): Update.
3263 (upload_fast_traceframes): Update.
3264 (run_inferior_command): Update.
3265 * linux-low.cc (linux_target_ops): Update.
3266 (linux_pause_all): Turn into ...
3267 (linux_process_target::pause_all): ... this.
3268 (linux_unpause_all): Turn into ...
3269 (linux_process_target::unpause_all): ... this.
3270 (linux_process_target::prepare_to_access_memory): Update.
3271 (linux_process_target::done_accessing_memory): Update.
3272 * linux-low.h (class linux_process_target): Update.
3273 * lynx-low.cc (lynx_target_ops): Update.
3274 * nto-low.cc (nto_target_ops): Update.
3275 * win32-low.cc (win32_target_ops): Update.
3276
4e2e869c
TBA
32772020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3278
3279 Turn process_stratum_target's get_tib_address op into a method of
3280 process_target.
3281
3282 * target.h (struct process_stratum_target): Remove the target op.
3283 (class process_target): Add the target op. Also add
3284 'supports_get_tib_address'.
3285 * target.cc (process_target::get_tib_address): Define.
3286 (process_target::supports_get_tib_address): Define.
3287
3288 Update the derived classes and callers below.
3289
3290 * server.cc (handle_query): Update.
3291 * linux-low.cc (win32_target_ops): Update.
3292 * lynx-low.cc (lynx_target_ops): Update.
3293 * nto-low.cc (nto_target_ops): Update.
3294 * win32-low.cc (win32_target_ops): Update.
3295 (win32_process_target::supports_get_tib_address): Define.
3296 (win32_get_tib_address): Turn into ...
3297 (win32_process_target::get_tib_address): ... this.
3298 * win32-low.h (class win32_process_target): Update.
3299
68119632
TBA
33002020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3301
3302 Turn process_stratum_target's thread_stopped op into a method of
3303 process_target.
3304
3305 * target.h (struct process_stratum_target): Remove the target op.
3306 (class process_target): Add the target op. Also add
3307 'supports_thread_stopped'.
3308 (target_thread_stopped): Update the macro.
3309 * target.cc (process_target::thread_stopped): Define.
3310 (process_target::supports_thread_stopped): Define.
3311 (prepare_to_access_memory): Update.
3312
3313 Update the derived classes and callers below.
3314
3315 * server.cc (queue_stop_reply_callback): Update.
3316 * linux-low.cc (linux_target_ops): Update.
3317 (linux_process_target::supports_thread_stopped): Define.
3318 (linux_thread_stopped): Turn into ...
3319 (linux_process_target::thread_stopped): ... this.
3320 * linux-low.h (class linux_process_target): Update.
3321 * lynx-low.cc (lynx_target_ops): Update.
3322 * nto-low.cc (nto_target_ops): Update.
3323 * win32-low.cc (win32_target_ops): Update.
3324
770d8f6a
TBA
33252020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3326
3327 Turn process_stratum_target's read_pc and write_pc ops into
3328 methods of process_target.
3329
3330 * target.h (struct process_stratum_target): Remove the target ops.
3331 (class process_target): Add the target ops.
3332 * target.cc (process_target::read_pc): Define.
3333 (process_target::write_pc): Define.
3334
3335 Update the derived classes and callers below.
3336
3337 * regcache.cc (regcache_read_pc): Update.
3338 (regcache_write_pc): Update.
3339 * linux-low.cc (linux_target_ops): Update.
3340 (linux_read_pc): Turn into ...
3341 (linux_process_target::read_pc): ... this.
3342 (linux_write_pc): Turn into ...
3343 (linux_process_target::write_pc): ... this.
3344 * linux-low.h (class linux_process_target): Update.
3345 * lynx-low.cc (lynx_target_ops): Update.
3346 * nto-low.cc (nto_target_ops): Update.
3347 * win32-low.cc (win32_target_ops): Update.
3348
290732bf
TBA
33492020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3350
3351 Turn process_stratum_target's supports_tracepoints op into a
3352 method of process_target.
3353
3354 * target.h (struct process_stratum_target): Remove the target op.
3355 (class process_target): Add the target op.
3356 (target_supports_tracepoints): Update the macro.
3357 * target.cc (process_target::supports_tracepoints): Define.
3358
3359 Update the derived classes and callers below.
3360
3361 * linux-low.cc (linux_target_ops): Update.
3362 (linux_supports_tracepoints): Turn into ...
3363 (linux_process_target::supports_tracepoints): ... this.
3364 * linux-low.h (class linux_process_target): Update.
3365 * lynx-low.cc (lynx_target_ops): Update.
3366 * nto-low.cc (nto_target_ops): Update.
3367 * win32-low.cc (win32_target_ops): Update.
3368
0df28b1b
TBA
33692020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3370
3371 Turn process_stratum_target's process_qsupported op into a method
3372 of process_target.
3373
3374 * target.h (struct process_stratum_target): Remove the target op.
3375 (class process_target): Add the target op.
3376 (target_process_qsupported): Update the macro.
3377 * target.cc (process_target::process_qsupported): Define.
3378
3379 Update the derived classes and callers below.
3380
3381 * linux-low.cc (linux_target_ops): Update.
3382 (linux_process_qsupported): Turn into ...
3383 (linux_process_target::process_qsupported): ... this.
3384 * linux-low.h (class linux_process_target): Update.
3385 * lynx-low.cc (lynx_target_ops): Update.
3386 * nto-low.cc (nto_target_ops): Update.
3387 * win32-low.cc (win32_target_ops): Update.
3388
9da41fda
TBA
33892020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3390
3391 Turn process_stratum_target's read_loadmap op into a method of
3392 process_target.
3393
3394 * target.h (struct process_stratum_target): Remove the target op.
3395 (class process_target): Add the target op. Also add
3396 'supports_read_loadmap'.
3397 * target.cc (process_target::read_loadmap): Define.
3398 (process_target::supports_read_loadmap): Define.
3399
3400 Update the derived classes and callers below.
3401
3402 * server.cc (handle_qxfer_fdpic): Update.
3403 (handle_query): Update.
3404 * linux-low.cc (linux_target_ops): Update.
3405 (linux_process_target::supports_read_loadmap): Define.
3406 (linux_read_loadmap): Turn into ...
3407 (linux_process_target::read_loadmap): ... this.
3408 * linux-low.h (class linux_process_target): Update.
3409 * lynx-low.cc (lynx_target_ops): Update.
3410 * nto-low.cc (nto_target_ops): Update.
3411 * win32-low.cc (win32_target_ops): Update.
3412
95a45fc1
TBA
34132020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3414
3415 Turn process_stratum_target's core_of_thread op into a method of
3416 process_target.
3417
3418 * target.h (struct process_stratum_target): Remove the target op.
3419 (class process_target): Add the target op.
3420 (target_core_of_thread): Update the macro.
3421 * target.cc (process_target::core_of_thread): Define.
3422
3423 Update the derived classes and callers below.
3424
3425 * linux-low.cc (linux_target_ops): Update.
3426 (linux_process_target::core_of_thread): Define.
3427 * linux-low.h (class linux_process_target): Update.
3428 * lynx-low.cc (lynx_target_ops): Update.
3429 * nto-low.cc (nto_target_ops): Update.
3430 * win32-low.cc (win32_target_ops): Update.
3431
55cf3021
TBA
34322020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3433
3434 Turn process_stratum_target's handle_monitor_command op into a
3435 method of process_target.
3436
3437 * target.h (struct process_stratum_target): Remove the target op.
3438 (class process_target): Add the target op.
3439 (target_handle_monitor_command): Update the macro.
3440 * target.cc (process_target::handle_monitor_command): Define.
3441
3442 Update the derived classes and callers below.
3443
3444 * server.cc (handle_query): Update.
3445 * linux-low.cc (linux_target_ops): Update.
3446 (linux_process_target::handle_monitor_command): Define.
3447 * linux-low.h (class linux_process_target): Update.
3448 * lynx-low.cc (lynx_target_ops): Update.
3449 * nto-low.cc (nto_target_ops): Update.
3450 * win32-low.cc (win32_target_ops): Update.
3451
fb00dfce
TBA
34522020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3453
3454 Turn process_stratum_target's handle_new_gdb_connection op into a
3455 method of process_target.
3456
3457 * target.h (struct process_stratum_target): Remove the target op.
3458 (class process_target): Add the target op.
3459 (target_handle_new_gdb_connection): Update the macro.
3460 * target.cc (process_target::handle_new_gdb_connection): Define.
3461
3462 Update the derived classes and callers below.
3463
3464 * linux-low.cc (linux_target_ops): Update.
3465 (linux_handle_new_gdb_connection): Turn into ...
3466 (linux_process_target::handle_new_gdb_connection): ... this.
3467 * linux-low.h (class linux_process_target): Update.
3468 * lynx-low.cc (lynx_target_ops): Update.
3469 * nto-low.cc (nto_target_ops): Update.
3470 * win32-low.cc (win32_target_ops): Update.
3471
9690a72a
TBA
34722020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3473
3474 Turn process_stratum_target's supports_fork_events,
3475 supports_vfork_events, and supports_exec_events ops into methods
3476 of process_target.
3477
3478 * target.h (struct process_stratum_target): Remove the target ops.
3479 (class process_target): Add the target ops.
3480 (target_supports_fork_events): Update the macro.
3481 (target_supports_vfork_events): Update the macro.
3482 (target_supports_exec_events): Update the macro.
3483 * target.cc (process_target::supports_fork_events): Define.
3484 (process_target::supports_vfork_events): Define.
3485 (process_target::supports_exec_events): Define.
3486
3487 Update the derived classes and callers below.
3488
3489 * linux-low.cc (linux_target_ops): Update.
3490 (linux_supports_fork_events): Turn into ...
3491 (linux_process_target::supports_fork_events): ... this.
3492 (linux_supports_vfork_events): Turn into ...
3493 (linux_process_target::supports_vfork_events): ... this.
3494 (linux_supports_exec_events): Turn into ...
3495 (linux_process_target::supports_exec_events): ... this.
3496 * linux-low.h (class linux_process_target): Update.
3497 * lynx-low.cc (lynx_target_ops): Update.
3498 * nto-low.cc (nto_target_ops): Update.
3499 * win32-low.cc (win32_target_ops): Update.
3500
652aef77
TBA
35012020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3502
3503 Turn process_stratum_target's supports_multi_process op into a
3504 method of process_target.
3505
3506 * target.h (struct process_stratum_target): Remove the target op.
3507 (class process_target): Add the target op.
3508 * target.cc (process_target::supports_multi_process): Define.
3509 (target_supports_multi_process): Update.
3510
3511 Update the derived classes and callers below.
3512
3513 * linux-low.cc (linux_target_ops): Update.
3514 (linux_supports_multi_process): Turn into ...
3515 (linux_process_target::supports_multi_process): ... this.
3516 * linux-low.h (class linux_process_target): Update.
3517 * lynx-low.cc (lynx_target_ops): Update.
3518 * nto-low.cc (nto_target_ops): Update.
3519 * win32-low.cc (win32_target_ops): Update.
3520
0dc587d4
TBA
35212020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3522
3523 Turn process_stratum_target's supports_non_stop, async, and
3524 start_non_stop ops into methods of process_target.
3525
3526 * target.h (struct process_stratum_target): Remove the target ops.
3527 (class process_target): Add the target ops.
3528 (target_supports_non_stop): Update the macro.
3529 (target_async): Update the macro.
3530 (start_non_stop): Remove declaration.
3531 * target.cc (process_target::supports_non_stop): Define.
3532 (process_target::async): Define.
3533 (process_target::start_non_stop): Define.
3534 (start_non_stop): Remove.
3535
3536 Update the derived classes and callers below.
3537
3538 * server.cc (handle_qxfer_siginfo): Update.
3539 (handle_query): Update.
3540 * linux-low.cc (linux_target_ops): Update.
3541 (linux_supports_non_stop): Turn into ...
3542 (linux_process_target::supports_non_stop): ... this.
3543 (linux_async): Turn into ...
3544 (linux_process_target::async): ... this.
3545 (linux_start_non_stop): Turn into ...
3546 (linux_process_target::start_non_stop): ... this.
3547 * linux-low.h (class linux_process_target): Update.
3548 * lynx-low.cc (lynx_target_ops): Update.
3549 * nto-low.cc (nto_target_ops): Update.
3550 (nto_supports_non_stop): Remove; rely on the default behavior
3551 instead.
3552 * win32-low.cc (win32_target_ops): Update.
3553
d7abedf7
TBA
35542020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3555
3556 Turn process_stratum_target's qxfer_siginfo op into a method of
3557 process_target.
3558
3559 * target.h (struct process_stratum_target): Remove the target op.
3560 (class process_target): Add the target op. Also add
3561 'supports_qxfer_siginfo'.
3562 * target.cc (process_target::qxfer_siginfo): Define.
3563 (process_target::supports_qxfer_siginfo): Define.
3564
3565 Update the derived classes and callers below.
3566
3567 * server.cc (handle_qxfer_siginfo): Update.
3568 (handle_query): Update.
3569 * linux-low.cc (linux_target_ops): Update.
3570 (linux_process_target::supports_qxfer_siginfo): Define.
3571 (linux_xfer_siginfo): Turn into ...
3572 (linux_process_target::qxfer_siginfo): ... this.
3573 * linux-low.h (class linux_process_target): Update.
3574 * lynx-low.cc (lynx_target_ops): Update.
3575 * nto-low.cc (nto_target_ops): Update.
3576 * win32-low.cc (win32_target_ops): Update.
3577
2d0795ee
TBA
35782020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3579
3580 Turn process_stratum_target's qxfer_osdata op into a method of
3581 process_target.
3582
3583 * target.h (struct process_stratum_target): Remove the target op.
3584 (class process_target): Add the target op. Also add
3585 'supports_qxfer_osdata'.
3586 * target.cc (process_target::qxfer_osdata): Define.
3587 (process_target::supports_qxfer_osdata): Define.
3588
3589 Update the derived classes and callers below.
3590
3591 * server.cc (handle_qxfer_osdata): Update.
3592 (handle_query): Update.
3593 * linux-low.cc (linux_target_ops): Update.
3594 (linux_process_target::supports_qxfer_osdata): Define.
3595 (linux_qxfer_osdata): Turn into ...
3596 (linux_process_target::qxfer_osdata): ... this.
3597 * linux-low.h (class linux_process_target): Update.
3598 * lynx-low.cc (lynx_target_ops): Update.
3599 * nto-low.cc (nto_target_ops): Update.
3600 * win32-low.cc (win32_target_ops): Update.
3601
ea06bbaa
TBA
36022020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3603
3604 Turn process_stratum_target's hostio_last_error op into a
3605 method of process_target.
3606
3607 * target.h (struct process_stratum_target): Remove the target op.
3608 (class process_target): Add the target op.
3609 * target.cc: Add "hostio.h" to includes.
3610 (process_target::hostio_last_error): Define.
3611
3612 Update the derived classes and callers below.
3613
3614 * hostio.cc (hostio_error): Update.
3615 * linux-low.cc: Remove "hostio.h" from includes.
3616 (linux_target_ops): Update.
3617 * lynx-low.cc (lynx_target_ops): Update.
3618 * nto-low.cc (nto_target_ops): Update.
3619 * win32-low.h (class win32_process_target): Update.
3620 * win32-low.cc (win32_target_ops): Update.
3621 (wince_hostio_last_error): Turn into ...
3622 (win32_process_target::hostio_last_error): ... this.
3623
6e3fd7e9
TBA
36242020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3625
3626 Turn process_stratum_target's get_tls_address op into a method of
3627 process_target.
3628
3629 * target.h (struct process_stratum_target): Remove the target op.
3630 (class process_target): Add the target op. Also add
3631 'supports_get_tls_address'.
3632 * target.cc (process_target::get_tls_address): Define.
3633 (process_target::supports_get_tls_address): Define.
3634
3635 Update the derived classes and callers below.
3636
3637 * server.cc (handle_query): Update.
3638 * linux-low.cc (linux_target_ops): Update.
3639 (linux_process_target::supports_get_tls_address): Define.
3640 (linux_process_target::get_tls_address): Define.
3641 * linux-low.h (class linux_process_target): Update.
3642 * lynx-low.cc (lynx_target_ops): Update.
3643 * nto-low.cc (nto_target_ops): Update.
3644 * win32-low.cc (win32_target_ops): Update.
3645
5203ae1e
TBA
36462020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3647
3648 Turn process_stratum_target's read_offsets op into a method of
3649 process_target.
3650
3651 * target.h (struct process_stratum_target): Remove the target op.
3652 (class process_target): Add the target op. Also add
3653 'supports_read_offsets'.
3654 * target.cc (process_target::read_offsets): Define.
3655 (process_target::supports_read_offsets): Define.
3656
3657 Update the derived classes and callers below.
3658
3659 * server.cc (handle_query): Update.
3660 * linux-low.cc (SUPPORTS_READ_OFFSETS): New #define directive.
3661 (linux_target_ops): Update.
3662 (linux_process_target::supports_read_offsets): Define.
3663 (linux_read_offsets): Turn into ...
3664 (linux_process_target::read_offsets): ... this.
3665 * linux-low.h (class linux_process_target): Update.
3666 * lynx-low.cc (lynx_target_ops): Update.
3667 * nto-low.cc (nto_target_ops): Update.
3668 * win32-low.cc (win32_target_ops): Update.
3669
6eeb5c55
TBA
36702020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3671
3672 Turn process_stratum_target's stopped_by_watchpoint and
3673 stopped_data_address ops into methods of process_target.
3674
3675 * target.h (struct process_stratum_target): Remove the target ops.
3676 (class process_target): Add the target ops.
3677 * target.cc (process_target::stopped_by_watchpoint): Define.
3678 (process_target::stopped_data_address): Define.
3679
3680 Update the derived classes and callers below.
3681
3682 * remote-utils.cc (prepare_resume_reply): Update.
3683 * linux-low.cc (linux_target_ops): Update.
3684 (linux_stopped_by_watchpoint): Turn into ...
3685 (linux_process_target::stopped_by_watchpoint): ... this.
3686 (linux_stopped_data_address): Turn into ...
3687 (linux_process_target::stopped_data_address): ... this.
3688 * linux-low.h (class linux_process_target): Update.
3689 * lynx-low.cc (lynx_target_ops): Update.
3690 * nto-low.cc (nto_target_ops): Update.
3691 (nto_stopped_by_watchpoint): Turn into ...
3692 (nto_process_target::stopped_by_watchpoint): ... this.
3693 (nto_stopped_data_address): Turn into ...
3694 (nto_process_target::stopped_data_address): ... this.
3695 * nto-low.h (class nto_process_target): Update.
3696 * win32-low.cc (win32_target_ops): Update.
3697 (win32_stopped_by_watchpoint): Turn into ...
3698 (win32_process_target::stopped_by_watchpoint): ... this.
3699 (win32_stopped_data_address): Turn into ...
3700 (win32_process_target::stopped_data_address): ... this.
3701 * win32-low.h (class win32_process_target): Update.
3702
22aa6223
TBA
37032020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3704
3705 Turn process_stratum_target's supports_hardware_single_step op into
3706 a method of process_target.
3707
3708 * target.h (struct process_stratum_target): Remove the target op.
3709 (class process_target): Add the target op.
3710 (target_supports_hardware_single_step): Update the macro.
3711 (target_can_do_hardware_single_step): Remove declaration.
3712 * target.cc (process_target::supports_hardware_single_step): Define.
3713 (target_can_do_hardware_single_step): Remove.
3714
3715 Update the derived classes and callers below.
3716
3717 * linux-low.h (class linux_process_target): Update.
3718 * linux-low.cc (linux_target_ops): Update.
3719 (linux_supports_hardware_single_step): Turn into ...
3720 (linux_process_target::supports_hardware_single_step): ... this.
3721 * lynx-low.h (class lynx_process_target): Update.
3722 * lynx-low.cc (lynx_target_ops): Update.
3723 (lynx_process_target::supports_hardware_single_step): Define.
3724 * nto-low.h (class nto_process_target): Update.
3725 * nto-low.cc (nto_target_ops): Update.
3726 (nto_process_target::supports_hardware_single_step): Define.
3727 * win32-low.h (class win32_process_target): Update.
3728 * win32-low.cc (win32_target_ops): Update.
3729 (win32_process_target::supports_hardware_single_step): Define.
3730
93fe88b2
TBA
37312020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3732
3733 Turn process_stratum_target's {supports_}stopped_by_hw_breakpoint
3734 ops into methods of process_target.
3735
3736 * target.h (struct process_stratum_target): Remove the target ops.
3737 (class process_target): Add the target ops.
3738 (target_stopped_by_hw_breakpoint): Update the macro.
3739 (target_supports_stopped_by_hw_breakpoint): Update the macro.
3740 * target.cc (process_target::stopped_by_hw_breakpoint): Define.
3741 (process_target::supports_stopped_by_hw_breakpoint): Define.
3742
3743 Update the derived classes and callers below.
3744
3745 * linux-low.cc (linux_target_ops): Update.
3746 (linux_stopped_by_hw_breakpoint): Turn into ...
3747 (linux_process_target::stopped_by_hw_breakpoint): ... this.
3748 (linux_supports_stopped_by_hw_breakpoint): Turn into ...
3749 (linux_process_target::supports_stopped_by_hw_breakpoint): ... this.
3750 * linux-low.h (class linux_process_target): Update.
3751 * lynx-low.cc (lynx_target_ops): Update.
3752 * nto-low.cc (nto_target_ops): Update.
3753 * win32-low.cc (win32_target_ops): Update.
3754
84320c4e
TBA
37552020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3756
3757 Turn process_stratum_target's {supports_}stopped_by_sw_breakpoint
3758 ops into methods of process_target.
3759
3760 * target.h (struct process_stratum_target): Remove the target ops.
3761 (class process_target): Add the target ops.
3762 (target_stopped_by_sw_breakpoint): Update the macro.
3763 (target_supports_stopped_by_sw_breakpoint): Update the macro.
3764 * target.cc (process_target::stopped_by_sw_breakpoint): Define.
3765 (process_target::supports_stopped_by_sw_breakpoint): Define.
3766
3767 Update the derived classes and callers below.
3768
3769 * linux-low.cc (linux_target_ops): Update.
3770 (linux_stopped_by_sw_breakpoint): Turn into ...
3771 (linux_process_target::stopped_by_sw_breakpoint): ... this.
3772 (linux_supports_stopped_by_sw_breakpoint): Turn into ...
3773 (linux_process_target::supports_stopped_by_sw_breakpoint): ... this.
3774 * linux-low.h (class linux_process_target): Update.
3775 * lynx-low.cc (lynx_target_ops): Update.
3776 * nto-low.cc (nto_target_ops): Update.
3777 * win32-low.cc (win32_target_ops): Update.
3778
7e0bde70
TBA
37792020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3780
3781 Turn process_stratum_target's insert_point and remove_point ops
3782 into methods of process_target.
3783
3784 * target.h (struct process_stratum_target): Remove the target ops.
3785 (class process_target): Add the target ops.
3786 * target.cc (process_target::insert_point): Define.
3787 (process_target::remove_point): Define.
3788
3789 Update the derived classes and callers below.
3790
3791 * mem-break.cc (set_raw_breakpoint_at): Update.
3792 (delete_raw_breakpoint): Update.
3793 (uninsert_raw_breakpoint): Update.
3794 (reinsert_raw_breakpoint): Update.
3795 * linux-low.cc (linux_target_ops): Update.
3796 (linux_insert_point): Turn into ...
3797 (linux_process_target::insert_point): ... this.
3798 (linux_remove_point): Turn into ...
3799 (linux_process_target::remove_point): ... this.
3800 * linux-low.h (class linux_process_target): Update.
3801 * lynx-low.cc (lynx_target_ops): Update.
3802 * nto-low.cc (nto_target_ops): Update.
3803 (nto_insert_point): Turn into ...
3804 (nto_process_target::insert_point): ... this.
3805 (nto_remove_point): Turn into ...
3806 (nto_process_target::remove_point): ... this.
3807 * nto-low.h (class nto_process_target): Update.
3808 * win32-low.cc (win32_target_ops): Update.
3809 (win32_insert_point): Turn into ...
3810 (win32_process_target::insert_point): ... this.
3811 (win32_remove_point): Turn into ...
3812 (win32_process_target::remove_point): ... this.
3813 * win32-low.h (class win32_process_target): Update.
3814
a2b2297a
TBA
38152020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3816
3817 Turn process_stratum_target's supports_z_point_type op into a
3818 method of process_target.
3819
3820 * target.h (struct process_stratum_target): Remove the target op.
3821 (class process_target): Add the target op.
3822 * target.cc (process_target::supports_z_point_type): Define.
3823
3824 Update the derived classes and callers below.
3825
3826 * mem-break.cc (z_type_supported): Update.
3827 * linux-low.cc (linux_target_ops): Update.
3828 (linux_supports_z_point_type): Turn into ...
3829 (linux_process_target::supports_z_point_type): ... this.
3830 * linux-low.h (class linux_process_target): Update.
3831 * lynx-low.cc (lynx_target_ops): Update.
3832 * nto-low.cc (nto_target_ops): Update.
3833 (nto_supports_z_point_type): Turn into ...
3834 (nto_process_target::supports_z_point_type): ... this.
3835 * nto-low.h (class nto_process_target): Update.
3836 * win32-low.cc (win32_target_ops): Update.
3837 (win32_supports_z_point_type): Turn into ...
3838 (win32_process_target::supports_z_point_type): ... this.
3839 * win32-low.h (class win32_process_target): Update.
3840
eac215cc
TBA
38412020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3842
3843 Turn process_stratum_target's read_auxv op into a method of
3844 process_target.
3845
3846 * target.h (class process_stratum_target): Remove the target op.
3847 (struct process_target): Add the target op. Also add
3848 'supports_read_auxv'.
3849 * target.cc (process_target::read_auxv): Define.
3850 (process_target::supports_read_auxv): Define.
3851
3852 Update the derived classes and callers below.
3853
3854 * server.cc (handle_qxfer_auxv): Update.
3855 (handle_query): Update.
3856 * linux-low.cc (linux_target_ops): Update.
3857 (linux_process_target::supports_read_auxv): Define.
3858 (linux_read_auxv): Turn into ...
3859 (linux_process_target::read_auxv): ... this.
3860 * linux-low.h (class linux_process_target): Update.
3861 * lynx-low.cc (lynx_target_ops): Update.
3862 * nto-low.cc (nto_target_ops): Update.
3863 (nto_process_target::supports_read_auxv): Define.
3864 (nto_read_auxv): Turn into ...
3865 (nto_process_target::read_auxv): ... this.
3866 * nto-low.h (class nto_process_target): Update.
3867 * win32-low.cc (win32_target_ops): Update.
3868
eb497a2a
TBA
38692020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3870
3871 Turn process_stratum_target's request_interrupt op into a method of
3872 process_target.
3873
3874 * target.h (struct process_stratum_target): Remove the target op.
3875 (class process_target): Add the target op.
3876
3877 Update the derived classes and callers below.
3878
3879 * remote-utils.cc (putpkt_binary_1): Update.
3880 (input_interrupt): Update.
3881 (getpkt): Update.
3882 * server.cc (handle_v_requests): Update.
3883 * linux-low.cc (linux_target_ops): Update.
3884 (linux_request_interrupt): Turn into ...
3885 (linux_process_target::request_interrupt): ... this.
3886 * linux-low.h (class linux_process_target): Update.
3887 * lynx-low.cc (lynx_target_ops): Update.
3888 (lynx_request_interrupt): Turn into ...
3889 (lynx_process_target::request_interrupt): ... this.
3890 * lynx-low.h (class lynx_process_target): Update.
3891 * nto-low.cc (nto_target_ops): Update.
3892 (nto_request_interrupt): Turn into ...
3893 (nto_process_target::request_interrupt): ... this.
3894 * nto-low.h (class nto_process_target): Update.
3895 * win32-low.cc (win32_target_ops): Update.
3896 (win32_request_interrupt): Turn into ...
3897 (win32_process_target::request_interrupt): ... this.
3898 * win32-low.h (class win32_process_target): Update.
3899
2a31c7aa
TBA
39002020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3901
3902 Turn process_stratum_target's look_up_symbols op into a method of
3903 process_target.
3904
3905 * target.h (struct process_stratum_target): Remove the target op.
3906 (class process_target): Add the target op.
3907 * target.cc (process_target::look_up_symbols): Define.
3908
3909 Update the derived classes and callers below.
3910
3911 * server.cc (handle_query): Update.
3912 * linux-low.cc (linux_target_ops): Update.
3913 (linux_look_up_symbols): Turn into ...
3914 (linux_process_target::look_up_symbols): ... this.
3915 * linux-low.h (class linux_process_target): Update.
3916 * lynx-low.cc (lynx_target_ops): Update.
3917 * nto-low.cc (nto_target_ops): Update.
3918 * win32-low.cc (win32_target_ops): Update.
3919
e2558df3
TBA
39202020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3921
3922 Turn process_stratum_target's read_memory and write_memory
3923 ops into methods of process_target.
3924
3925 * target.h (struct process_stratum_target): Remove the target ops.
3926 (class process_target): Add the target ops.
3927
3928 Update the derived classes and callers below.
3929
3930 * linux-aarch32-low.cc (arm_breakpoint_at): Update.
3931 * linux-aarch64-low.cc (aarch64_breakpoint_at): Update.
3932 * linux-arm-low.cc (arm_sigreturn_next_pc): Update.
3933 (arm_get_syscall_trapinfo): Update.
3934 * linux-cris-low.cc (cris_breakpoint_at): Update.
3935 * linux-crisv32-low.cc (cris_breakpoint_at): Update.
3936 * linux-m32r-low.cc (m32r_breakpoint_at): Update.
3937 * linux-mips-low.cc (mips_breakpoint_at): Update.
3938 * linux-nios2-low.cc (nios2_breakpoint_at): Update.
3939 * linux-ppc-low.cc (ppc_breakpoint_at): Update.
3940 * linux-sh-low.cc (sh_breakpoint_at): Update.
3941 * linux-sparc-low.cc (sparc_fill_gregset_to_stack): Update.
3942 (sparc_store_gregset_from_stack): Update.
3943 (sparc_breakpoint_at): Update.
3944 * linux-tic6x-low.cc (tic6x_breakpoint_at): Update.
3945 * linux-tile-low.cc (tile_breakpoint_at): Update.
3946 * linux-x86-low.cc (x86_breakpoint_at): Update.
3947 * linux-xtensa-low.cc (xtensa_breakpoint_at): Update.
3948 * mem-brea.cc (insert_memory_breakpoint): Update.
3949 (validate_inserted_breakpoint): Update.
3950 * target.cc (read_inferior_memory): Update.
3951 (target_write_memory): Update.
3952 * linux-low.cc (linux_target_ops): Update.
3953 (linux_read_memory): Make a wrapper around the read_memory target
3954 op call.
3955 (linux_process_target::read_memory): Rename from linux_read_memory.
3956 (linux_write_memory): Turn into ...
3957 (linux_process_target::write_memory): ... this.
3958 * linux-low.h (class linux_process_target): Update.
3959 * lynx-low.cc (lynx_target_ops): Update.
3960 (lynx_read_memory): Turn into ...
3961 (lynx_process_target::read_memory): ... this.
3962 (lynx_write_memory): Turn into ...
3963 (lynx_process_target::write_memory): ... this.
3964 * lynx-low.h (class lynx_process_target): Update.
3965 * nto-low.cc (nto_target_ops): Update.
3966 (nto_read_memory): Turn into ...
3967 (nto_process_target::read_memory): ... this.
3968 (nto_write_memory): Turn into ...
3969 (nto_process_target::write_memory): ... this.
3970 * nto-low.h (class nto_process_target): Update.
3971 * win32-low.cc (win32_target_ops): Update.
3972 (win32_read_inferior_memory): Turn into ...
3973 (win32_process_target::read_memory): ... this.
3974 (win32_write_inferior_memory): Turn into ...
3975 (win32_process_target::write_memory): ... this.
3976 * win32-low.h (class win32_process_target): Update.
3977
79b44087
TBA
39782020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3979
3980 Turn process_stratum_target's prepare_to_access_memory and
3981 done_accessing_memory ops into methods of process_target.
3982
3983 * target.h (struct process_stratum_target): Remove the target ops.
3984 (class process_target): Add the target ops.
3985 * target.cc (process_target::prepare_to_access_memory): Define.
3986 (process_target::done_accessing_memory): Define.
3987 (prepare_to_access_memory): Update.
3988 (done_accessing_memory): Update.
3989
3990 Update the derived classes and callers below.
3991
3992 * linux-low.cc (linux_target_ops): Update.
3993 (linux_prepare_to_access_memory): Turn into ...
3994 (linux_process_target::prepare_to_access_memory): ... this.
3995 (linux_done_accessing_memory): Turn into ...
3996 (linux_process_target::done_accessing_memory): ... this.
3997 * linux-low.h (class linux_process_target): Update.
3998 * lynx-low.cc (lynx_target_ops): Update.
3999 * nto-low.cc (nto_target_ops): Update.
4000 * win32-low.cc (win32_target_ops): Update.
4001
a5a4d4cd
TBA
40022020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4003
4004 Turn process_stratum_target's fetch_registers and store_registers
4005 ops into methods of process_target.
4006
4007 * target.h (struct process_stratum_target): Remove the target ops.
4008 (class process_target): Add the target ops.
4009 (fetch_inferior_registers): Update the macro.
4010 (store_inferior_registers): Update the macro.
4011
4012 Update the derived classes and callers below.
4013
4014 * linux-low.cc (linux_target_ops): Update.
4015 (linux_fetch_registers): Turn into ...
4016 (linux_process_target::fetch_registers): ... this.
4017 (linux_store_registers): Turn into ...
4018 (linux_process_target::store_registers): ... this.
4019 * linux-low.h (class linux_process_target): Update.
4020 * lynx-low.cc (lynx_target_ops): Update.
4021 (lynx_fetch_registers): Turn into ...
4022 (lynx_process_target::fetch_registers): ... this.
4023 (lynx_store_registers): Turn into ...
4024 (lynx_process_target::store_registers): ... this.
4025 * lynx-low.h (class lynx_process_target): Update.
4026 * nto-low.cc (nto_target_ops): Update.
4027 (nto_fetch_registers): Turn into ...
4028 (nto_process_target::fetch_registers): ... this.
4029 (nto_store_registers): Turn into ...
4030 (nto_process_target::store_registers): ... this.
4031 * nto-low.h (class nto_process_target): Update.
4032 * win32-low.cc (win32_target_ops): Update.
4033 (win32_fetch_inferior_registers): Turn into ...
4034 (win32_process_target::fetch_registers): ... this.
4035 (win32_store_inferior_registers): Turn into ...
4036 (win32_process_target::store_registers): ... this.
4037 * win32-low.h (class win32_process_target): Update.
4038
6532e7e3
TBA
40392020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4040
4041 Turn process_stratum_target's wait op into a method of
4042 process_target.
4043
4044 * target.h (struct process_stratum_target): Remove the target op.
4045 (class process_target): Add the target op.
4046
4047 Update the derived classes and callers below.
4048
4049 * target.cc (target_wait): Update.
4050 * linux-low.cc (linux_target_ops): Update.
4051 (linux_wait): Turn into ...
4052 (linux_process_target::wait): ... this.
4053 * linux-low.h (class linux_process_target): Update.
4054 * lynx-low.cc (lynx_target_ops): Update.
4055 (lynx_wait): Turn into ...
4056 (lynx_process_target::wait): ... this.
4057 * lynx-low.h (class lynx_process_target): Update.
4058 * nto-low.cc (nto_target_ops): Update.
4059 (nto_wait): Turn into ...
4060 (nto_process_target::wait): ... this.
4061 * nto-low.h (class nto_process_target): Update.
4062 * win32-low.cc (win32_target_ops): Update.
4063 (win32_wait): Turn into ...
4064 (win32_process_target::wait): ... this.
4065 (do_initial_child_stuff): Update.
4066 * win32-low.h (class win32_process_target): Update.
4067
0e4d7e35
TBA
40682020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4069
4070 Turn process_stratum_target's resume op into a method of
4071 process_target.
4072
4073 * target.h (struct process_stratum_target): Remove the target op.
4074 (class process_target): Add the target op.
4075
4076 Update the derived classes and callers below.
4077
4078 * server.cc (resume): Update.
4079 * target.cc (target_stop_and_wait): Update.
4080 (target_continue_no_signal): Update.
4081 (target_continue): Update.
4082 * linux-low.cc (linux_target_ops): Update.
4083 (linux_resume): Turn into ...
4084 (linux_process_target::resume): ... this.
4085 * linux-low.h (class linux_process_target): Update.
4086 * lynx-low.cc (lynx_target_ops): Update.
4087 (lynx_resume): Turn into ...
4088 (lynx_process_target::resume): ... this.
4089 * lynx-low.h (class lynx_process_target): Update.
4090 * nto-low.cc (nto_target_ops): Update.
4091 (nto_resume): Turn into ...
4092 (nto_process_target::resume): ... this.
4093 * nto-low.h (class nto_process_target): Update.
4094 * win32-low.cc (win32_target_ops): Update.
4095 (win32_resume): Turn into ...
4096 (win32_process_target::resume): ... this.
4097 (win32_process_target::detach): Update.
4098 (do_initial_child_stuff): Update.
4099 * win32-low.h (class win32_process_target): Update.
4100
13d3d99b
TBA
41012020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4102
4103 Turn process_stratum_target's thread_alive op into a method of
4104 process_target.
4105
4106 * target.h (struct process_stratum_target): Remove the target op.
4107 (class process_target): Add the target op.
4108 (mythread_alive): Update the macro.
4109
4110 Update the derived classes and callers below.
4111
4112 * linux-low.cc (linux_target_ops): Update.
4113 (linux_thread_alive): Turn into ...
4114 (linux_process_target::thread_alive): ... this.
4115 (wait_for_sigstop): Update.
4116 * linux-low.h (class linux_process_target): Update.
4117 * lynx-low.cc (lynx_target_ops): Update.
4118 (lynx_thread_alive): Turn into ...
4119 (lynx_process_target::thread_alive): ... this.
4120 * lynx-low.h (class lynx_process_target): Update.
4121 * nto-low.cc (nto_target_ops): Update.
4122 (nto_thread_alive): Turn into ...
4123 (nto_process_target::thread_alive): ... this.
4124 * nto-low.h (class nto_process_target): Update.
4125 * win32-low.cc (win32_target_ops): Update.
4126 (win32_thread_alive): Turn into ...
4127 (win32_process_target::thread_alive): ... this.
4128 * win32-low.h (class win32_process_target): Update.
4129
95a49a39
TBA
41302020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4131
4132 Turn process_stratum_target's join op into a method of
4133 process_target.
4134
4135 * target.h (struct process_stratum_target): Remove the target op.
4136 (class process_target): Add the target op.
4137 (join_inferior): Update the macro.
4138
4139 Update the derived classes and callers below.
4140
4141 * linux-low.cc (linux_target_ops): Update.
4142 (linux_join): Turn into ...
4143 (linux_process_target::join): ... this.
4144 * linux-low.h (class linux_process_target): Update.
4145 * lynx-low.cc (lynx_target_ops): Update.
4146 (lynx_join): Turn into ...
4147 (lynx_process_target::join): ... this.
4148 * lynx-low.h (class lynx_process_target): Update.
4149 * nto-low.cc (nto_target_ops): Update.
4150 (nto_process_target::join): Define.
4151 * nto-low.h (class nto_process_target): Update.
4152 * win32-low.cc (win32_target_ops): Update.
4153 (win32_join): Turn into ...
4154 (win32_process_target::join): ... this.
4155 * win32-low.h (class win32_process_target): Update.
4156
8adb37b9
TBA
41572020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4158
4159 Turn process_stratum_target's mourn op into a method of
4160 process_target.
4161
4162 * target.h (struct process_stratum_target): Remove the target op.
4163 (class process_target): Add the target op.
4164
4165 Update the derived classes and callers below.
4166
4167 * target.cc (target_mourn_inferior): Update.
4168 * linux-low.cc (linux_target_ops): Update.
4169 (linux_mourn): Turn into ...
4170 (linux_process_target::mourn): ... this.
4171 (handle_extended_wait): Update.
4172 (linux_process_target::kill): Update.
4173 (linux_process_target::detach): Update.
4174 * linux-low.h (class linux_process_target): Update.
4175 * lynx-low.cc (lynx_target_ops): Update.
4176 (lynx_mourn): Turn into ...
4177 (lynx_process_target::mourn): ... this.
4178 * lynx-low.h (class lynx_process_target): Update.
4179 * nto-low.cc (nto_target_ops): Update.
4180 (nto_mourn): Turn into ...
4181 (nto_process_target::mourn): ... this.
4182 * nto-low.h (class nto_process_target): Update.
4183 * win32-low.cc (win32_target_ops): Update.
4184 (win32_mourn): Turn into ...
4185 (win32_process_target::mourn): ... this.
4186 * win32-low.h (class win32_process_target): Update.
4187
9061c9cf
TBA
41882020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4189
4190 Turn process_stratum_target's detach op into a method of
4191 process_target.
4192
4193 * target.h (struct process_stratum_target): Remove the target op.
4194 (class process_target): Add the target op.
4195 (detach_inferior): Update the macro.
4196
4197 Update the derived classes and callers below.
4198
4199 * linux-low.cc (linux_target_ops): Update.
4200 (linux_detach): Turn into ...
4201 (linux_process_target::detach): ... this.
4202 * linux-low.h (class linux_process_target): Update.
4203 * lynx-low.cc (lynx_target_ops): Update.
4204 (lynx_detach): Turn into ...
4205 (lynx_process_target::detach): ... this.
4206 * lynx-low.h (class lynx_process_target): Update.
4207 * nto-low.cc (nto_target_ops): Update.
4208 (nto_detach): Turn into ...
4209 (nto_process_target::detach): ... this.
4210 * nto-low.h (class nto_process_target): Update.
4211 * win32-low.cc (win32_target_ops): Update.
4212 (win32_detach): Turn into ...
4213 (win32_process_target::detach): ... this.
4214 * win32-low.h (class win32_process_target): Update.
4215
c6885a57
TBA
42162020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4217
4218 Turn process_stratum_target's kill op into a method of
4219 process_target.
4220
4221 * target.h (struct process_stratum_target): Remove the target op.
4222 (class process_target): Add the target op.
4223
4224 Update the derived classes and callers below.
4225
4226 * target.cc (kill_inferior): Update.
4227 * linux-low.cc (linux_target_ops): Update.
4228 (linux_kill): Turn into ...
4229 (linux_process_target::kill): ... this.
4230 * linux-low.h (class linux_process_target): Update.
4231 * lynx-low.cc (lynx_target_ops): Update.
4232 (lynx_kill): Turn into ...
4233 (lynx_process_target::kill): ... this.
4234 * lynx-low.h (class lynx_process_target): Update.
4235 * nto-low.cc (nto_target_ops): Update.
4236 (nto_kill): Turn into ...
4237 (nto_process_target::kill): ... this.
4238 * nto-low.h (class nto_process_target): Update.
4239 * win32-low.cc (win32_target_ops): Update.
4240 (win32_kill): Turn into ...
4241 (win32_process_target::kill): ... this.
4242 * win32-low.h (class win32_process_target): Update.
4243
ef03dad8
TBA
42442020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4245
4246 Turn process_stratum_target's attach op into a method of
4247 process_target.
4248
4249 * target.h (struct process_stratum_target): Remove the target op.
4250 (class process_target): Add the target op.
4251 (myattach): Update the macro.
4252
4253 Update the derived classes and callers below.
4254
4255 * linux-low.cc (linux_target_ops): Update.
4256 (linux_attach): Turn into ...
4257 (linux_process_target::attach): ... this.
4258 * linux-low.h (class linux_process_target): Update.
4259 * lynx-low.cc (lynx_target_ops): Update.
4260 (lynx_attach): Turn into ...
4261 (lynx_process_target::attach): ... this.
4262 * lynx-low.h (class lynx_process_target): Update.
4263 * nto-low.cc (nto_target_ops): Update.
4264 (nto_attach): Turn into ...
4265 (nto_process_target::attach): ... this.
4266 * nto-low.h (class nto_process_target): Update.
4267 * win32-low.cc (win32_target_ops): Update.
4268 (win32_attach): Turn into ...
4269 (win32_process_target::attach): ... this.
4270 * win32-low.h (class win32_process_target): Update.
4271
6dee9afb
TBA
42722020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4273
4274 Turn process_stratum_target's post_create_inferior op into a method
4275 of process_target.
4276
4277 * target.h (struct process_stratum_target): Remove the target op.
4278 (class process_target): Add the target op.
4279 (target_post_create_inferior): Update the macro.
4280 * target.cc (process_target::post_create_inferior): Define.
4281
4282 Update the derived classes and callers below.
4283
4284 * linux-low.cc (linux_target_ops): Update.
4285 (linux_post_create_inferior): Turn into ...
4286 (linux_process_target::post_create_inferior): ... this.
4287 * linux-low.h (class linux_process_target): Update.
4288 * lynx-low.cc (lynx_target_ops): Update.
4289 * nto-low.cc (nto_target_ops): Update.
4290 * win32-low.cc (win32_target_ops): Update.
4291
15295543
TBA
42922020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4293
4294 Turn process_stratum_target's create_inferior op into a method of
4295 process_target.
4296
4297 * target.h (struct process_stratum_target): Remove the target op.
4298 (class process_target): Add the target op.
4299 (create_inferior): Rename the macro to ...
4300 (target_create_inferior): ... this.
4301
4302 Update the derived classes and callers below.
4303
4304 * server.cc (handle_v_run): Update.
4305 (captured_main): Update.
4306 (process_serial_event): Update.
4307 * linux-low.cc (linux_target_ops): Update.
4308 (linux_create_inferior): Turn into ...
4309 (linux_process_target::create_inferior): ... this.
4310 * linux-low.h (class linux_process_target): Update.
4311 * lynx-low.cc (lynx_target_ops): Update.
4312 (lynx_create_inferior): Turn into ...
4313 (lynx_process_target::create_inferior): ... this.
4314 * lynx-low.h (class lynx_process_target): Update.
4315 * nto-low.cc (nto_target_ops): Update.
4316 (nto_create_inferior): Turn into ...
4317 (nto_process_target::create_inferior): ... this.
4318 * nto-low.h (class nto_process_target): Update.
4319 * win32-low.cc (win32_target_ops): Update.
4320 (win32_create_inferior): Turn into ...
4321 (win32_process_target::create_inferior): ... this.
4322 * win32-low.h (class win32_process_target): Update.
4323
5ef9273d
TBA
43242020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4325
4326 * target.h (class process_target): New class definition.
4327 (struct process_stratum_target) <pt>: New field with type
4328 'process_target*'.
4329 * linux-low.h (class linux_process_target): Define as a derived
4330 class of 'process_target'.
4331 * linux-low.cc (linux_target_ops): Add a linux_process_target*
4332 as the 'pt' field.
4333 * lynx-low.h (class lynx_process_target): Define as a derived
4334 class of 'process_target'.
4335 * lynx-low.cc (lynx_target_ops): Add a lynx_process_target*
4336 as the 'pt' field.
4337 * nto-low.h (class nto_process_target): Define as a derived
4338 class of 'process_target'.
4339 * nto-low.cc (nto_target_ops): Add an nto_process_target*
4340 as the 'pt' field.
4341 * win32-low.h (class win32_process_target): Define as a derived
4342 class of 'process_target'.
4343 * win32-low.cc (win32_target_ops): Add a win32_process_target*
4344 as the 'pt' field.
4345
9f1528a1
AB
43462020-02-19 Andrew Burgess <andrew.burgess@embecosm.com>
4347
4348 * configure: Regenerate.
4349
bf84f706
MR
43502020-02-19 Maciej W. Rozycki <macro@wdc.com>
4351 Andrew Burgess <andrew.burgess@embecosm.com>
4352
4353 * linux-riscv-low.cc: New file.
4354 * Makefile.in (SFILES): Add linux-riscv-low.cc, arch/riscv.c,
4355 and nat/riscv-linux-tdesc.c.
4356 * configure.srv <riscv*-*-linux*> (srv_tgtobj)
4357 (srv_linux_regsets, srv_linux_usrregs, srv_linux_thread_db):
4358 Define.
4359
1a627e7e
TT
43602020-02-14 Tom Tromey <tom@tromey.com>
4361
4362 * acinclude.m4: Don't include acx_configure_dir.m4.
4363 * Makefile.in (LIBIBERTY_BUILDDIR, GNULIB_BUILDDIR): Update.
4364 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): Remove.
4365 (all, install-only, uninstall, clean-info, clean)
4366 (maintainer-clean): Don't recurse.
4367 (subdir_do, all-lib): Remove.
4368 ($(LIBGNU) $(LIBIBERTY) $(GNULIB_H)): Remove rule.
4369 (GNULIB_H): Remove.
4370 (generated_files): Update.
4371 ($(GNULIB_BUILDDIR)/Makefile): Remove rule.
4372 * configure: Rebuild.
4373 * configure.ac: Don't configure gnulib or libiberty.
4374 (GNULIB): Update.
4375
a9b34532
EZ
43762020-02-14 Eli Zaretskii <eliz@gnu.org>
4377
4378 * win32-low.c (create_process): Prepend PROGRAM to ARGS when
4379 preparing the command line for CreateProcess.
4380 (win32_create_inferior): Reflect the program name in debugging
4381 output that shows the process and its command line.
4382
feacfcac
SM
43832020-02-13 Simon Marchi <simon.marchi@efficios.com>
4384
4385 * Makefile.in: Rename source files from .c to .cc.
4386 * %.c: Rename to %.cc.
4387 * configure.ac: Rename server.c to server.cc.
4388 * configure: Re-generate.
4389
06b3c5bd
SM
43902020-02-13 Simon Marchi <simon.marchi@efficios.com>
4391
4392 * Makefile.in: Rename gdbsupport source files from .c to .cc.
4393
052793ad
HD
43942020-02-12 Hannes Domani <ssbssa@yahoo.de>
4395
4396 * win32-low.c (win32_create_inferior): Set signal_pid.
4397
f20e3e82
MR
43982020-02-12 Maciej W. Rozycki <macro@wdc.com>
4399 Pedro Alves <palves@redhat.com>
4400
4401 Skip building gdbserver in a cross-configuration.
4402 * configure.srv: Set $gdbserver_host depending on whether $target
4403 is $host. Use $gdbserver_host instead of $host.
4404
8ddd8e0e
SM
44052020-02-11 Simon Marchi <simon.marchi@efficios.com>
4406
4407 * configure: Re-generate.
4408
898e7f60
SM
44092020-02-11 Simon Marchi <simon.marchi@efficios.com>
4410
4411 * configure: Re-generate.
4412
58df732b
SM
44132020-02-11 Simon Marchi <simon.marchi@efficios.com>
4414
4415 * acinclude.m4: Update warning.m4 path.
4416
7928d571
HD
44172020-02-09 Hannes Domani <ssbssa@yahoo.de>
4418
4419 * win32-low.c (win32_clear_inferiors): Reset siginfo_er.
4420 (handle_exception): Set siginfo_er.
4421 (win32_xfer_siginfo): New function.
4422
919adfe8
TT
44232020-02-07 Tom Tromey <tom@tromey.com>
4424 Pedro Alves <palves@redhat.com>
4425
4426 * README: Update build documentation.
4427 * configure.srv: Set UNSUPPORTED if host is unsupported. Check
4428 host, not target.
4429 * configure.ac: Update paths.
4430 * configure: Rebuild.
4431 * acinclude.m4: Update paths.
4432 * Makefile.in: Update include paths.
4433 (depcomp, INCLUDE_DIR, INCGNU, INCSUPPORT, INCLUDE_CFLAGS)
4434 (SFILES, XML_DIR, n, $(GNULIB_BUILDDIR)/Makefile, config.status)
4435 (version-generated.c, stamp-xml, regdat_sh, arch/%-ipa.o)
4436 (gdbsupport/%-ipa.o, %-ipa.o, arch/%.o, gdbsupport/%.o, %.o)
4437 (%-generated.c): Update paths.
4438 * Move entire directory from ../gdb/gdbserver.
4439
287c844a
MR
44402020-01-29 Maciej W. Rozycki <macro@wdc.com>
4441
4442 * configure.srv <i[34567]86-*-mingw*>: Fix whitespace damage.
4443
548a204f
PFC
44442020-01-29 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4445
4446 * configure.srv (powerpc*-*-linux*): Use srv_tgtobj in second
4447 assignment instead of srv_linux_obj.
4448
a2236a08
HD
44492020-01-28 Hannes Domani <ssbssa@yahoo.de>
4450
4451 * server.c (handle_qxfer_libraries): Write segment-address with
4452 paddress.
4453
bdaed379
HD
44542020-01-24 Hannes Domani <ssbssa@yahoo.de>
4455
4456 * Makefile.in (install-strip): New target.
4457 (install_sh, INSTALL_STRIP_PROGRAM, STRIP): New variables.
4458 * aclocal.m4: Regenerate.
4459 * configure: Regenerate.
4460 * configure.ac: Add AM_PROG_INSTALL_STRIP.
4461
42cd72aa
MR
44622020-01-24 Maciej W. Rozycki <macro@wdc.com>
4463
4464 * Makefile.in (SFILES): Adjust paths to point to real files.
4465 (OBS): Move waitstatus.o to target/waitstatus.o.
4466 (TAGS): Transform paths appropriately.
4467 (%.o): Rename to...
4468 (nat/%.o): ... this pattern rule.
4469 (%.o): Rename to...
4470 (target/%.o): ... this pattern rule.
4471 * configure.srv: Adjust paths throughout to include nat/ prefix
4472 with the revant files.
4473 * configure.ac: Add `nat' and `target' to CONFIG_SRC_SUBDIR.
4474 * configure: Regenerate.
4475
42ba50ec
MR
44762020-01-24 Maciej W. Rozycki <macro@wdc.com>
4477
4478 * Makefile.in (TAGS): Remove config files from the recipe.
4479
05ea2a05
TT
44802020-01-14 Tom Tromey <tom@tromey.com>
4481
4482 * configure: Rebuild.
4483 * configure.ac: Remove any checks that were added to common.m4.
4484 * acinclude.m4: Include lib-ld.m4, lib-prefix.m4, and
4485 lib-link.m4.
4486
01027315
TT
44872020-01-14 Tom Tromey <tom@tromey.com>
4488
4489 * server.h: Include config.h.
4490 * gdbreplay.c: Include config.h.
4491 * configure: Rebuild.
4492 * configure.ac: Don't source common.host.
4493 * acinclude.m4: Update path.
4494 * Makefile.in (INCSUPPORT): New variable.
4495 (INCLUDE_CFLAGS): Add INCSUPPORT.
4496 (SFILES): Update paths.
4497 (version-generated.c): Update path to create-version.sh.
4498 (gdbsupport/%-ipa.o, gdbsupport/%.o): Update paths.
4499
b2ceabe8
TT
45002020-01-14 Tom Tromey <tom@tromey.com>
4501
4502 * configure.ac (LIBS): Use WIN32APILIBS.
4503 (USE_WIN32API): Don't define.
4504 * configure: Rebuild.
4505
25c51f71
TT
45062020-01-14 Tom Tromey <tom@tromey.com>
4507
4508 * configure: Rebuild.
4509
c0bd321d
SM
45102020-01-13 Simon Marchi <simon.marchi@efficios.com>
4511
4512 * Makefile.in (%-generated.c): Remove rule for files from
4513 regformats/i386.
4514
bb564c58
SM
45152020-01-13 Simon Marchi <simon.marchi@efficios.com>
4516
4517 * configure: Re-generate.
4518
6e37c371
SM
45192020-01-13 Simon Marchi <simon.marchi@efficios.com>
4520
4521 * tracepoint.h (IP_AGENT_EXPORT_FUNC) [!IN_PROCESS_AGENT]:
4522 Define to static.
4523 * tracepoint.c (stop_tracing, flush_trace_buffer,
4524 about_to_request_buffer_space, get_trace_state_variable_value,
4525 set_trace_state_variable_value, gdb_collect): Add declaration.
4526
df4a0200
SM
45272020-01-13 Simon Marchi <simon.marchi@efficios.com>
4528
4529 * linux-x86-low.c (x86_linux_regs_info, amd64_emit_eq_goto,
4530 amd64_emit_ne_goto, amd64_emit_lt_goto, amd64_emit_le_goto,
4531 amd64_emit_gt_goto, amd64_emit_ge_goto, amd64_emit_ge_goto,
4532 i386_emit_eq_goto, i386_emit_ne_goto, i386_emit_lt_goto,
4533 i386_emit_le_goto, i386_emit_gt_goto, i386_emit_ge_goto): Make
4534 static.
4535
89e94ec9
SM
45362020-01-13 Simon Marchi <simon.marchi@efficios.com>
4537
4538 * inferiors.c: Include gdbsupport/common-inferior.h.
4539
2552728a
SM
45402020-01-13 Simon Marchi <simon.marchi@efficios.com>
4541
4542 * hostio-errno.c: Include hostio.h.
4543
4025fa09
SM
45442020-01-13 Simon Marchi <simon.marchi@efficios.com>
4545
4546 * Makefile.in (%-generated.c): Make $(regdat_sh) a regular
4547 prerequisite.
4548
c0b0a142
SM
45492020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
4550
4551 * linux-arm-tdesc.c: Include linux-arm-tdesc.h.
4552 * linux-arm-tdesc.h: Include arch/arm.h.
4553
bb1183e2
SM
45542020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
4555
4556 * linux-aarch64-low.c (aarch64_write_goto_address): Make static.
4557
f5df0b5f
SM
45582020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
4559
4560 * linux-aarch32-tdesc.c: Include linux-aarch32-tdesc.h.
4561 * linux-aarch64-tdesc.c: Include linux-aarch64-tdesc.h.
4562
5b6d1e4f
PA
45632020-01-10 Pedro Alves <palves@redhat.com>
4564
4565 * fork-child.c (post_fork_inferior): Pass target down to
4566 startup_inferior.
4567 * inferiors.c (switch_to_thread): Add process_stratum_target
4568 parameter.
4569 * lynx-low.c (lynx_target_ops): Now a process_stratum_target.
4570 * nto-low.c (nto_target_ops): Now a process_stratum_target.
4571 * linux-low.c (linux_target_ops): Now a process_stratum_target.
4572 * remote-utils.c (prepare_resume_reply): Pass the target to
4573 switch_to_thread.
4574 * target.c (the_target): Now a process_stratum_target.
4575 (done_accessing_memory): Pass the target to switch_to_thread.
4576 (set_target_ops): Ajust to use process_stratum_target.
4577 * target.h (struct target_ops): Rename to ...
4578 (struct process_stratum_target): ... this.
4579 (the_target, set_target_ops): Adjust.
4580 (prepare_to_access_memory): Adjust comment.
4581 * win32-low.c (child_xfer_memory): Adjust to use
4582 process_stratum_target.
4583 (win32_target_ops): Now a process_stratum_target.
4584
559e7e50
EZ
45852020-01-06 Eli Zaretskii <eliz@gnu.org>
4586 Pedro Alves <palves@redhat.com>
4587
4588 * win32-low.c (get_child_debug_event): Extract the fatal exception
4589 from the exit status and convert to the equivalent Posix signal
4590 number.
4591 (win32_wait): Allow TARGET_WAITKIND_SIGNALLED status as well.
4592 * Makefile.in (OBS, SFILES): Add gdb_wait.[co].
4593
48189bec
HD
45942020-01-01 Hannes Domani <ssbssa@yahoo.de>
4595
4596 * Makefile.in: Use INSTALL_PROGRAM_ENV.
4597
5dd8bf88
JB
45982020-01-01 Joel Brobecker <brobecker@adacore.com>
4599
4600 * server.c (gdbserver_version): Change copyright year to 2020.
4601 * gdbreplay.c (gdbreplay_version): Likewise.
4602
0ad6b8ee
CB
46032019-12-19 Christian Biesinger <cbiesinger@google.com>
4604
4605 * configure: Regenerate.
4606 * configure.ac: Quote variable arguments of test.
4607
1ee7b812
BE
46082019-12-16 Bernd Edlinger <bernd.edlinger@hotmail.de>
4609
4610 * Makefile.in: Fix build with GNU Make 3.81
4611
d9fa87f4
TT
46122019-12-16 Tom Tromey <tromey@adacore.com>
4613
4614 * server.c (get_exec_file): Constify result.
4615
ab7d13f0
CB
46162019-12-10 Christian Biesinger <cbiesinger@google.com>
4617
4618 * Makefile.in: Add safe-strerror.c to gdbreplay and IPA, and change
4619 UNDO_GNULIB_CFLAGS to undo strerror_r instead of strerror.
4620 * config.in: Regenerate.
4621 * configure: Regenerate.
4622 * configure.ac: Don't check for strerror.
4623 * linux-i386-ipa.c (initialize_fast_tracepoint_trampoline_buffer):
4624 Call safe_strerror instead of strerror.
4625 * server.h (strerror): Remove this now-unnecessary declaration.
4626 * tracepoint.c (init_named_socket): Call safe_strerror instead of
4627 strerror.
4628 (gdb_agent_helper_thread): Likewise.
4629 * utils.c (perror_with_name): Likewise.
4630
4da8c3a8
TT
46312019-11-26 Tom Tromey <tom@tromey.com>
4632
4633 * configure, config.in: Rebuild.
4634
21987b9c
TT
46352019-11-26 Tom Tromey <tom@tromey.com>
4636
4637 * remote-utils.c (block_unblock_async_io): Use gdb_sigmask.
4638 * linux-low.c (linux_wait_for_event_filtered, linux_async): Use
4639 gdb_sigmask.
4640 * configure, config.in: Rebuild.
4641
5e030278
TT
46422019-11-26 Tom Tromey <tom@tromey.com>
4643
4644 * Makefile.in (PTHREAD_CFLAGS, PTHREAD_LIBS): New variables.
4645 (INTERNAL_CFLAGS_BASE): Use PTHREAD_CFLAGS.
4646 (GDBSERVER_LIBS): Use PTHREAD_LIBS.
4647 * acinclude.m4: Include ax_pthread.m4.
4648 * config.in, configure: Rebuild.
4649
6d91ce9a
CB
46502019-11-26 Christian Biesinger <cbiesinger@google.com>
4651
4652 * debug.c (debug_set_output): Call safe_strerror instead of
4653 strerror.
4654 * linux-low.c (attach_proc_task_lwp_callback): Likewise.
4655 (linux_kill_one_lwp): Likewise.
4656 (linux_detach_one_lwp): Likewise.
4657 (linux_wait_for_event_filtered): Likewise.
4658 (store_register): Likewise.
4659 * lynx-low.c (lynx_attach): Likewise.
4660 * mem-break.c (insert_memory_breakpoint): Likewise.
4661 (remove_memory_breakpoint): Likewise.
4662 (delete_fast_tracepoint_jump): Likewise.
4663 (set_fast_tracepoint_jump): Likewise.
4664 (uninsert_fast_tracepoint_jumps_at): Likewise.
4665 (reinsert_fast_tracepoint_jumps_at): Likewise.
4666 * nto-low.c (nto_xfer_memory): Likewise.
4667 (nto_resume): Likewise.
4668
6cdd651f
LM
46692019-11-20 Luis Machado <luis.machado@linaro.org>
4670
4671 * linux-aarch64-low.c (is_sve_tdesc): Check against target feature
4672 instead of register count.
4673 * tdesc.c (tdesc_contains_feature): New function.
4674 * tdesc.h (tdesc_contains_feature): New prototype.
4675
cd850b40
CB
46762019-11-15 Christian Biesinger <cbiesinger@google.com>
4677
4678 * Makefile.in: Add safe-strerror.c.
4679 * configure: Regenerate.
4680 * configure.ac: Don't source common.host.
4681
5abebf3c
CB
46822019-11-15 Christian Biesinger <cbiesinger@google.com>
4683
4684 * config.in: Regenerate.
4685 * configure: Regenerate.
4686
e06f3d6e
AB
46872019-11-12 Andrew Burgess <andrew.burgess@embecosm.com>
4688
4689 * ax.c (ax_printf): Handle size_t_arg.
4690
ca3a04f6
CB
46912019-11-06 Christian Biesinger <cbiesinger@google.com>
4692
4693 * linux-tdep.c (linux_info_proc): Use strtok_r instead of strtok.
4694 * mi/mi-main.c (output_cores): Likewise.
4695 * nat/linux-osdata.c (linux_xfer_osdata_cpus): Likewise.
4696 (linux_xfer_osdata_modules): Likewise.
4697 * remote.c (register_remote_support_xml): Likewise.
4698 * sparc64-tdep.c (adi_is_addr_mapped): Likewise.
4699 * xml-syscall.c (syscall_create_syscall_desc): Likewise.
4700
e48f6033
CB
47012019-11-01 Christian Biesinger <cbiesinger@google.com>
4702
4703 * configure: Regenerate.
4704 * configure.ac: Remove check for strerror_r.
4705
e7e97a2e
CB
47062019-10-31 Christian Biesinger <cbiesinger@google.com>
4707
4708 * config.in: Regenerate.
4709 * configure: Regenerate.
4710 * configure.ac: Also check for strerror_r.
4711
75cafaa6
CB
47122019-10-31 Christian Biesinger <cbiesinger@google.com>
4713
4714 * ax.h (debug_agent): Remove duplicate declaration.
4715
30baf67b
TV
47162019-10-26 Tom de Vries <tdevries@suse.de>
4717
4718 * linux-aarch64-low.c: Fix typos in comments.
4719 * linux-arm-low.c: Same.
4720 * linux-low.c: Same.
4721 * linux-ppc-low.c: Same.
4722 * proc-service.c: Same.
4723 * regcache.h: Same.
4724 * server.c: Same.
4725 * tracepoint.c: Same.
4726 * win32-low.c: Same.
4727
52c64cf7
TT
47282019-10-25 Tom Tromey <tromey@adacore.com>
4729
4730 * utils.c (xstrdup): Remove.
4731
c12d372d
TT
47322019-10-23 Tom Tromey <tom@tromey.com>
4733
4734 * configure, config.in: Rebuild.
4735
4d0b984b
TT
47362019-10-23 Tom Tromey <tom@tromey.com>
4737
4738 * configure: Rebuild.
4739 * acinclude.m4: Use m4_include, not sinclude.
4740
c5adaa19
TT
47412019-10-17 Tom Tromey <tromey@adacore.com>
4742
4743 * configure: Rebuild.
4744 * configure.ac: Use AC_CONFIG_HEADERS. Create stamp-h there, not
4745 in AC_CONFIG_FILES invocation.
4746 * Makefile.in (stamp-h, Makefile): Use new-style config.status
4747 invocation.
4748
fec4e896
CB
47492019-10-16 Christian Biesinger <cbiesinger@google.com>
4750
4751 * server.c: Include xml-builtin.h.
4752 (get_xml_features): Don't declare xml_builtins here.
4753
00975ff6
AB
47542019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
4755
4756 * Makefile.in: Remove references to vec-ipa.o.
4757
0dc32745
AB
47582019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
4759
4760 * Makefile.in: Remove references to vec.c.
4761
3e6ec53a
CB
47622019-10-02 Christian Biesinger <cbiesinger@google.com>
4763
4764 * server.c (server_waiting): Change to bool.
4765 (extended_protocol): Likewise.
4766 (response_needed): Likewise.
4767 (exit_requested): Likewise.
4768 (run_once): Likewise.
4769 (report_no_resumed): Likewise.
4770 (non_stop): Likewise.
4771 (disable_packet_vCont): Likewise.
4772 (disable_packet_Tthread): Likewise.
4773 (disable_packet_qC): Likewise.
4774 (disable_packet_qfThreadInfo): Likewise.
4775 (handle_general_set): Update.
4776 (handle_detach): Update.
4777 (handle_monitor_command): Update.
4778 (handle_query): Update.
4779 (captured_main): Update.
4780 (process_serial_event): Update.
4781 * server.h (server_waiting): Change to bool.
4782 (disable_packet_vCont): Likewise.
4783 (disable_packet_Tthread): Likewise.
4784 (disable_packet_qC): Likewise.
4785 (disable_packet_qfThreadInfo): Likewise.
4786 (run_once): Likewise.
4787 (non_stop): Likewise.
4788 * target.c (target_stop_and_wait): Update.
4789
80fd2826
TT
47902019-10-02 Tom Tromey <tromey@adacore.com>
4791
4792 * Makefile.in (SFILES): Add common-inferior.c.
4793 (OBS): Add common-inferior.o.
4794 * server.c (startup_with_shell): Don't define.
4795
46f29a9a
AB
47962019-10-02 Andrew Burgess <andrew.burgess@embecosm.com>
4797
4798 * linux-low.c (linux_low_read_btrace): Update for change to
4799 std::vector.
4800
f9d949fb
CB
48012019-09-20 Christian Biesinger <cbiesinger@google.com>
4802
4803 * debug.c (debug_threads): Remove comment in favor of the header.
4804 * debug.h (using_threads): Add declaration.
4805 (debug_threads): Add comment.
4806 * linux-aarch64-low.c: Include debug.h and remove declaration of
4807 debug_threads.
4808 * nto-low.c: Likewise.
4809 * remote-utils.c: Likewise.
4810 * thread-db.c: Likewise.
4811
abf516c6
UW
48122019-09-20 Ulrich Weigand <uweigand@de.ibm.com>
4813
4814 * configure.srv (ipa_ppc_linux_regobj): Remove powerpc-cell32l-ipa.o
4815 and powerpc-cell64l-ipa.o.
4816 (powerpc*-*-linux*): Remove powerpc-cell32l.o and powerpc-cell64l.o
4817 from srv_regobj. Remove rs6000/powerpc-cell32l.xml and
4818 rs6000/powerpc-cell64l.xml from srv_xmlfiles.
4819 (spu*-*-*): Remove.
4820
4821 * spu-low.c: Remove file.
4822
4823 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Remove.
4824 (parse_spufs_run): Remove.
4825 (ppc_get_pc): Remove Cell/B.E. support.
4826 (ppc_set_pc): Likewise.
4827 (ppc_breakpoint_at): Likewise.
4828 (ppc_arch_setup): Likewise.
4829 (ppc_get_ipa_tdesc_idx): Do not handle tdesc_powerpc_cell64l or
4830 tdesc_powerpc_cell32l.
4831 (initialize_low_arch): Do not call init_registers_powerpc_cell64l
4832 or init_registers_powerpc_cell32l.
4833 * linux-ppc-ipa.c (get_ipa_tdesc): Do not handle PPC_TDESC_CELL.
4834 (initialize_low_tracepoint): Do not call init_registers_powerpc_cell64l
4835 or init_registers_powerpc_cell32l.
4836 * linux-ppc-tdesc-init.h (PPC_TDESC_CELL): Mark as unused.
4837 (init_registers_powerpc_cell32l): Remove prototype.
4838 (init_registers_powerpc_cell64l): Likewise.
4839
4840 * target.h (struct target_ops): Remove qxfer_spu member.
4841 * server.c (handle_qxfer_spu): Remove.
4842 (qxfer_packets): Remove entry for "spu".
4843 (handle_query): No longer support qXfer:spu:read or qXfer:spu:write.
4844 * linux-low.c (SPUFS_MAGIC): Remove.
4845 (spu_enumerate_spu_ids): Remove.
4846 (linux_qxfer_spu): Remove.
4847 (linux_target_ops): Remove qxfer_spu member.
4848 * lynx-low.c (lynx_target_ops): Remove qxfer_spu member.
4849 * nto-low.c (nto_target_ops): Remove qxfer_spu member.
4850 * win32-low.c (win32_target_ops): Remove qxfer_spu member.
4851
2d41fa11
SDJ
48522019-08-23 Sergio Durigan Junior <sergiodj@redhat.com>
4853
4854 * Makefile.in (SFILES): Add 'gdbsupport/gdb-dlfcn.c'.
4855 (OBS): Add 'gdbsupport/gdb-dlfcn.o'.
4856 * config.in: Regenerate.
4857 * configure: Regenerate.
4858
d59b55f0
TT
48592019-08-15 Tom Tromey <tromey@adacore.com>
4860
4861 * target.c (target_write_memory): Use gdb::byte_vector.
4862
4196ab2a
TT
48632019-08-15 Tom Tromey <tromey@adacore.com>
4864
4865 * tracepoint.c (write_inferior_data_pointer)
4866 (write_inferior_integer, write_inferior_int8)
4867 (write_inferior_uinteger, m_tracepoint_action_download)
4868 (r_tracepoint_action_download, x_tracepoint_action_download)
4869 (l_tracepoint_action_download, clear_inferior_trace_buffer)
4870 (download_agent_expr, download_tracepoint_1)
4871 (download_trace_state_variables, upload_fast_traceframes): Update.
4872 * server.c (gdb_write_memory): Update.
4873 * remote-utils.c (relocate_instruction): Update.
4874 * proc-service.c (ps_pdwrite): Update.
4875 * mem-break.c (remove_memory_breakpoint)
4876 (delete_fast_tracepoint_jump, set_fast_tracepoint_jump)
4877 (uninsert_fast_tracepoint_jumps_at)
4878 (reinsert_fast_tracepoint_jumps_at): Update.
4879 * linux-x86-low.c (append_insns)
4880 (i386_install_fast_tracepoint_jump_pad)
4881 (amd64_write_goto_address, i386_write_goto_address): Update.
4882 * linux-s390-low.c (append_insns, s390_write_goto_address):
4883 Update.
4884 * linux-ppc-low.c (ppc_relocate_instruction)
4885 (ppc_install_fast_tracepoint_jump_pad, emit_insns)
4886 (ppc_write_goto_address): Update.
4887 * linux-aarch64-low.c (append_insns): Update.
4888 * target.h (struct target_ops): Update.
4889 (write_inferior_memory): Don't declare.
4890 * target.c (target_write_memory): Rename from
4891 write_inferior_memory. Remove old target_write_memory.
4892
c6778d00
TT
48932019-08-15 Tom Tromey <tromey@adacore.com>
4894
4895 * target.c (write_inferior_memory): Use std::vector.
4896
404f2902
FCE
48972019-08-06 Frank Ch. Eigler <fche@redhat.com>
4898
4899 PR build/24886
4900 * configure.ac: Drop enable-libmcheck support.
4901 * configure, config.in: Rebuild.
4902 * acinclude.m4: Don't include it.
4903
4c5aa8e0
AH
49042019-07-19 Alan Hayward <alan.hayward@arm.com>
4905
4906 * configure.srv: Remove Arm xml files.
4907
7cc17433
AH
49082019-07-19 Alan Hayward <alan.hayward@arm.com>
4909
4910 * configure.srv: Add new files. Remove xml generated files.
4911 * linux-aarch32-low.c (initialize_low_arch_aarch32): Don't init
4912 registers.
4913 * linux-aarch32-low.h (tdesc_arm_with_neon): Remove.
4914 * linux-aarch32-tdesc.c: New file.
4915 * linux-aarch32-tdesc.h: New file.
4916 * linux-aarch64-low.c (aarch64_arch_setup): Call aarch32_linux_read_description.
4917 * linux-arm-low.c (init_registers_arm, tdesc_arm)
4918 (init_registers_arm_with_iwmmxt, tdesc_arm_with_iwmmxt)
4919 (init_registers_arm_with_vfpv2, tdesc_arm_with_vfpv2)
4920 (init_registers_arm_with_vfpv3, tdesc_arm_with_vfpv3): Remove.
4921 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
4922 (arm_store_vfpregset): Call arm_linux_get_tdesc_fp_type.
4923 (arm_read_description): Call arm_linux_read_description.
4924 (initialize_low_arch): Don't init registers.
4925 * linux-arm-tdesc.c: New file.
4926 * linux-arm-tdesc.h: New file.
4927
166a82be
AH
49282019-07-10 Alan Hayward <alan.hayward@arm.com>
4929
4930 * linux-arm-low.c (arm_fill_wmmxregset, arm_store_wmmxregset):
4931 Move counter inside for.
4932 (arm_read_description): Check ptrace earlier.
4933 (arm_arch_setup): Call arm_linux_init_hwbp_cap here.
4934
268a13a5
TT
49352019-07-09 Tom Tromey <tom@tromey.com>
4936
4937 * configure: Rebuild.
4938 * configure.ac: Change common to gdbsupport.
4939 * acinclude.m4: Change common to gdbsupport.
4940 * Makefile.in (SFILES, OBS, GDBREPLAY_OBS, IPA_OBJS)
4941 (version-generated.c, gdbsupport/%-ipa.o, gdbsupport/%.o): Change
4942 common to gdbsupport.
4943 * ax.c, event-loop.c, fork-child.c, gdb_proc_service.h,
4944 gdbreplay.c, gdbthread.h, hostio-errno.c, hostio.c, i387-fp.c,
4945 inferiors.c, inferiors.h, linux-aarch64-tdesc-selftest.c,
4946 linux-amd64-ipa.c, linux-i386-ipa.c, linux-low.c,
4947 linux-tic6x-low.c, linux-x86-low.c, linux-x86-tdesc-selftest.c,
4948 linux-x86-tdesc.c, lynx-i386-low.c, lynx-low.c, mem-break.h,
4949 nto-x86-low.c, regcache.c, regcache.h, remote-utils.c, server.c,
4950 server.h, spu-low.c, symbol.c, target.h, tdesc.c, tdesc.h,
4951 thread-db.c, tracepoint.c, win32-i386-low.c, win32-low.c: Change
4952 common to gdbsupport.
4953
350fab54
AH
49542019-07-04 Alan Hayward <alan.hayward@arm.com>
4955
4956 * linux-aarch32-low.c (arm_read_description, arm_regsets): Use new
4957 defines.
4958 * linux-arm-low.c (arm_read_description, arm_regsets): Likewise.
4959
2b40fda7
AH
49602019-07-04 Alan Hayward <alan.hayward@arm.com>
4961
4962 * configure.srv: Remove legacy xml.
4963 * linux-aarch64-low.c (initialize_low_arch): Remove
4964 initialize_low_tdesc call.
4965 * linux-aarch64-tdesc-selftest.c: Remove file.
4966 * linux-aarch64-tdesc.h (initialize_low_tdesc): Remove.
4967 * linux-x86-low.c (initialize_low_arch): Remove
4968 initialize_low_tdesc call.
4969 * linux-x86-tdesc-selftest.c: Remove file.
4970 * linux-x86-tdesc.h (initialize_low_tdesc): Remove.
4971
7d10623d
TV
49722019-06-20 Tom de Vries <tdevries@suse.de>
4973
4974 * linux-s390-ipa.c (get_ipa_tdesc)[!__s390x__]: Use
4975 s390_te_linux64_ft_collect_regmap for S390_TDESC_GS.
4976
8d6a48df
TV
49772019-06-19 Tom de Vries <tdevries@suse.de>
4978
4979 * debug.h (debug_write): Change return type to ssize_t.
4980 * debug.c (debug_write): Same.
4981
73cc7272
TT
49822019-06-14 Tom Tromey <tom@tromey.com>
4983
4984 * configure.ac: Use new path to gnulib.
4985 * configure: Rebuild.
4986 * Makefile.in (INCGNU, $(GNULIB_BUILDDIR)/Makefile): Use new path
4987 to gnulib.
4988
08f10e02
TT
49892019-06-11 Tom Tromey <tom@tromey.com>
4990
4991 * Makefile.in (SFILES): Add alloc.c.
4992 (OBS): Add alloc.o.
4993 (IPA_OBJS): Add alloc-ipa.o.
4994 (alloc-ipa.o): New target.
4995 (%.o: ../%.c): New pattern rule.
4996
422186a9
TT
49972019-06-10 Tom Tromey <tromey@adacore.com>
4998
4999 * remote-utils.c (look_up_one_symbol, relocate_instruction): Don't
5000 end warning with a newline.
5001 * linux-s390-low.c (s390_get_wordsize): Don't end warning with a
5002 newline.
5003 * thread-db.c (attach_thread): Don't end warning with a newline.
5004 (thread_db_notice_clone): Likewise.
5005 * tracepoint.c (gdb_agent_helper_thread): Don't end warning with a
5006 newline.
5007 * linux-x86-low.c (x86_get_min_fast_tracepoint_insn_len): Don't
5008 end warning with a newline.
5009
b02f78f9
PA
50102019-06-04 Pedro Alves <palves@redhat.com>
5011
5012 * server.c (captured_main): Use make_unique_xstrdup.
5013
88ed7edb
TT
50142019-06-02 Tom Tromey <tom@tromey.com>
5015
5016 * gdbreplay.c (fromhex): Remove.
5017 * Makefile.in (GDBREPLAY_OBS): Add rsp-low.o.
5018
33a6bc35
TT
50192019-05-29 Tom Tromey <tromey@adacore.com>
5020
5021 * configure: Rebuild.
5022
e90a813d
KB
50232019-05-06 Kevin Buettner <kevinb@redhat.com>
5024
5025 * linux-x86-low.c (x86_fill_gregset): Don't compile 64-bit
5026 sign extension code on 32-bit builds.
5027
353ea2d1
EZ
50282019-05-03 Eli Zaretskii <eliz@gnu.org>
5029
5030 * remote-utils.c:
5031 * gdbreplay.c [USE_WIN32API]: Remove the _WIN32_WINNT override.
5032
b494cdff
TT
50332019-04-19 Tom Tromey <tom@tromey.com>
5034
5035 * server.c (struct vstop_notif): Derive from notif_event.
5036 <base>: Remove.
5037 (queue_stop_reply): Update.
5038 (remove_all_on_match_ptid): Change type. Rewrite.
5039 (discard_queued_stop_replies): Rewrite.
5040 (in_queued_stop_replies_ptid): Change type.
5041 (in_queued_stop_replies): Rewrite.
5042 (notif_stop): Update.
5043 (queue_stop_reply_callback): Update.
5044 (captured_main): Don't call initialize_notif.
5045 (push_stop_notification): Update.
5046 * notif.c (notif_write_event, handle_notif_ack)
5047 (notif_event_enque, notif_push): Update.
5048 (notif_event_xfree, initialize_notif): Remove.
5049 * notif.h (struct notif_event): Include <list>, not
5050 "common/queue.h".
5051 (struct notif_server) <queue>: Now a std::list.
5052 (notif_event_p): Remove typedef.
5053 (initialize_notif): Don't declare.
5054 (struct notif_event): Add virtual destructor.
5055
a7e559cc
AH
50562019-04-17 Alan Hayward <alan.hayward@arm.com>
5057
5058 * ax.c (ax_vdebug): Call debug_printf.
5059 * debug.c (debug_write): New function.
5060 * debug.h (debug_write): New declaration.
5061 * linux-low.c (sigchld_handler): Call debug_write.
5062
aeb2e706
AH
50632019-04-17 Alan Hayward <alan.hayward@arm.com>
5064
5065 * debug.c (debug_set_output): New function.
5066 (debug_vprintf): Send output to debug_file.
5067 (debug_flush): Likewise.
5068 * debug.h (debug_set_output): New declaration.
5069 * server.c (handle_monitor_command): Add debug-file option.
5070 (captured_main): Likewise.
5071
c1bc0935
AH
50722019-04-17 Alan Hayward <alan.hayward@arm.com>
5073
5074 * debug.c (remote_debug): Add definition.
5075 * debug.h (remote_debug): Add declaration.
5076 * hostio.c (remote_debug): Remove declaration.
5077 * remote-utils.c (struct ui_file): Likewise.
5078 (remote_debug): Likewise.
5079 * remote-utils.h (remote_debug): Likewise,
5080 * server.c (remote_debug): Remove definition.
5081
3f52fdbc
KB
50822019-04-10 Kevin Buettner <kevinb@redhat.com>
5083
5084 * linux-x86-low.c (x86_fill_gregset): Sign extend EAX value
5085 when using a 64-bit gdbserver.
5086
b0319eaa
TT
50872019-04-09 Tom Tromey <tromey@adacore.com>
5088
5089 * linux-low.c (select_event_lwp): Use find_thread_in_random.
5090
eedc3f4f
TT
50912019-04-08 Tom Tromey <tom@tromey.com>
5092
5093 * linux-low.c (linux_detach_one_lwp): Replace throw_exception with
5094 throw.
5095 (linux_resume_one_lwp): Likewise.
5096
230d2906
TT
50972019-04-08 Tom Tromey <tom@tromey.com>
5098
5099 * gdbreplay.c: Update.
5100 * linux-low.c: Update.
5101 * server.c: Update.
5102
a70b8144
TT
51032019-04-08 Tom Tromey <tom@tromey.com>
5104
5105 * server.c: Use C++ exception handling.
5106 * linux-low.c: Use C++ exception handling.
5107 * gdbreplay.c: Use C++ exception handling.
5108
3d6e9d23
TT
51092019-04-08 Tom Tromey <tom@tromey.com>
5110
5111 * server.c (handle_btrace_general_set, handle_qxfer_btrace)
5112 (handle_qxfer_btrace_conf, detach_or_kill_for_exit_cleanup)
5113 (captured_main, main): Update.
5114 * gdbreplay.c (main): Update.
5115
0570503d
PFC
51162019-04-05 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5117
5118 * linux-low.c (linux_get_auxv): Remove static. Return auxv entry
5119 value in argument pointer, return 1 if the entry is found and 0
5120 otherwise. Move comment.
5121 (linux_get_hwcap, linux_get_hwcap2): Use modified linux_get_auxv.
5122 * linux-low.h (linux_get_auxv): Declare.
5123 * linux-ppc-low.c (is_elfv2_inferior): Use linux_get_auxv.
5124
227a9e65
TT
51252019-04-05 Tom Tromey <tromey@adacore.com>
5126
5127 * server.c (gdbserver_usage): Use upper-case for metasyntactic
5128 variables.
5129
69f4c9cc
AH
51302019-03-28 Alan Hayward <alan.hayward@arm.com>
5131
5132 * linux-low.c (AT_HWCAP2): Add define if not already included.
5133
974c89e0
AH
51342019-03-26 Alan Hayward <alan.hayward@arm.com>
5135
5136 * linux-aarch64-low.c (aarch64_get_hwcap): Remove function.
5137 (aarch64_arch_setup): Call linux_get_hwcap.
5138 * linux-arm-low.c (arm_get_hwcap): Remove function.
5139 (arm_read_description): Call linux_get_hwcap.
5140 * linux-low.c (linux_get_auxv): New function.
5141 (linux_get_hwcap): Likewise.
5142 (linux_get_hwcap2): Likewise.
5143 * linux-low.h (linux_get_hwcap): New declaration.
5144 (linux_get_hwcap2): Likewise.
5145 * linux-ppc-low.c (ppc_get_auxv): Remove function.
5146 (ppc_arch_setup): Call linux_get_hwcap.
5147 * linux-s390-low.c (s390_get_hwcap): Remove function.
5148 (s390_arch_setup): Call linux_get_hwcap.
5149
1ef53e6b
AH
51502019-03-22 Alan Hayward <alan.hayward@arm.com>
5151 Jiong Wang <jiong.wang@arm.com>
5152
5153 * linux-aarch64-low.c (aarch64_store_pauthregset): New function.
5154 * linux-low.c (regsets_store_inferior_registers): Allow optional reads
5155 to fail.
5156 * linux-low.h (enum regset_type): Add OPTIONAL_REGS.
5157
ee4fbcfa
AH
51582019-03-22 Alan Hayward <alan.hayward@arm.com>
5159 Jiong Wang <jiong.wang@arm.com>
5160
5161 * linux-aarch64-low.c (AARCH64_HWCAP_PACA): New define.
5162 (aarch64_get_hwcap): New function.
5163 (aarch64_arch_setup): Read APIA hwcap.
5164
6dc0ebde
AH
51652019-03-22 Alan Hayward <alan.hayward@arm.com>
5166 Jiong Wang <jiong.wang@arm.com>
5167
5168 * linux-aarch64-ipa.c (get_ipa_tdesc): Add pauth param.
5169 (initialize_low_tracepoint): Likewise.
5170 * linux-aarch64-low.c (aarch64_arch_setup): Likewise.
5171 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Likewise.
5172 * linux-aarch64-tdesc.c (struct target_desc): Likewise.
5173 (aarch64_linux_read_description): Likewise.
5174 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Likewise.
5175
1163a4b7
JB
51762019-03-12 John Baldwin <jhb@FreeBSD.org>
5177
5178 * linux-x86-tdesc.c (i386_linux_read_description): Update call to
5179 i386_create_target_description for 'segments' parameter.
5180 * lynx-i386-low.c (lynx_i386_arch_setup): Likewise.
5181 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
5182 * win32-i386-low.c (i386_arch_setup): Likewise.
5183
d3a70e03
TT
51842019-03-12 Tom Tromey <tromey@adacore.com>
5185
5186 * linux-low.c (iterate_over_lwps): Update.
5187
37991b4f
TT
51882019-03-06 Tom Tromey <tom@tromey.com>
5189
5190 * server.c (detach_or_kill_for_exit_cleanup): Remove parameter.
5191 (captured_main): Use SCOPE_EXIT.
5192
45950eb6
SDJ
51932019-03-04 Sergio Durigan Junior <sergiodj@redhat.com>
5194
5195 * configure.srv: Use '$enable_unittest' instead of '$development'
5196 when checking whether to fill 'srv_regobj' on 'aarch64*-*-linux*'
5197 case.
5198
43ac54fc
TT
51992019-02-27 Tom Tromey <tromey@adacore.com>
5200
5201 * gdbreplay.c (logchar): Handle \r\n.
5202
df0da8a2
AH
52032019-02-07 Alan Hayward <alan.hayward@arm.com>
5204
5205 * linux-low.c (linux_attach): Add process before lwp.
5206 * server.c (attach_inferior): Check if already attached.
5207
1a5c2598
TT
52082019-02-07 Tom Tromey <tom@tromey.com>
5209
5210 * x86-tdesc.h: Rename include guard.
5211 * x86-low.h: Add include guard.
5212 * wincecompat.h: Rename include guard.
5213 * win32-low.h: Add include guard.
5214 * utils.h: Rename include guard.
5215 * tracepoint.h: Rename include guard.
5216 * tdesc.h: Rename include guard.
5217 * target.h: Rename include guard.
5218 * server.h: Rename include guard.
5219 * remote-utils.h: Rename include guard.
5220 * regcache.h: Rename include guard.
5221 * nto-low.h: Rename include guard.
5222 * notif.h: Add include guard.
5223 * mem-break.h: Rename include guard.
5224 * lynx-low.h: Add include guard.
5225 * linux-x86-tdesc.h: Add include guard.
5226 * linux-s390-tdesc.h: Add include guard.
5227 * linux-ppc-tdesc-init.h: Add include guard.
5228 * linux-low.h: Add include guard.
5229 * linux-aarch64-tdesc.h: Add include guard.
5230 * linux-aarch32-low.h: Add include guard.
5231 * inferiors.h: Rename include guard.
5232 * i387-fp.h: Rename include guard.
5233 * hostio.h: Rename include guard.
5234 * gdbthread.h: Rename include guard.
5235 * gdb_proc_service.h: Rename include guard.
5236 * event-loop.h: Rename include guard.
5237 * dll.h: Rename include guard.
5238 * debug.h: Rename include guard.
5239 * ax.h: Rename include guard.
5240
956cc47c
SN
52412018-01-30 Szabolcs Nagy <szabolcs.nagy@arm.com>
5242
5243 PR gdb/23985
5244 * Makefile.in (IPAGENT_CFLAGS): Add UNDO_GNULIB_CFLAGS.
5245 (UNDO_GNULIB_CFLAGS): Undo gnulib replacements.
5246
a0707f3c
TT
52472019-01-25 Tom Tromey <tom@tromey.com>
5248
5249 * Makefile.in (INCLUDE_CFLAGS): Don't add -I for common.
5250
0747795c
TT
52512019-01-25 Tom Tromey <tom@tromey.com>
5252
5253 * win32-low.c: Fix common/ includes.
5254 * win32-i386-low.c: Fix common/ includes.
5255 * tracepoint.c: Fix common/ includes.
5256 * thread-db.c: Fix common/ includes.
5257 * target.h: Fix common/ includes.
5258 * symbol.c: Fix common/ includes.
5259 * spu-low.c: Fix common/ includes.
5260 * server.h: Fix common/ includes.
5261 * server.c: Fix common/ includes.
5262 * remote-utils.c: Fix common/ includes.
5263 * regcache.h: Fix common/ includes.
5264 * regcache.c: Fix common/ includes.
5265 * nto-x86-low.c: Fix common/ includes.
5266 * notif.h: Fix common/ includes.
5267 * mem-break.h: Fix common/ includes.
5268 * lynx-low.c: Fix common/ includes.
5269 * lynx-i386-low.c: Fix common/ includes.
5270 * linux-x86-tdesc-selftest.c: Fix common/ includes.
5271 * linux-x86-low.c: Fix common/ includes.
5272 * linux-low.c: Fix common/ includes.
5273 * inferiors.h: Fix common/ includes.
5274 * i387-fp.c: Fix common/ includes.
5275 * hostio.c: Fix common/ includes.
5276 * hostio-errno.c: Fix common/ includes.
5277 * gdbthread.h: Fix common/ includes.
5278 * gdbreplay.c: Fix common/ includes.
5279 * fork-child.c: Fix common/ includes.
5280 * event-loop.c: Fix common/ includes.
5281 * ax.c:
5282 (enum gdb_agent_op): Fix common/ includes.
5283
be6d4f74
TT
52842019-01-21 Tom Tromey <tom@tromey.com>
5285
5286 * tracepoint.c: Fix includes.
5287 * remote-utils.c: Fix includes.
5288 * linux-x86-low.c: Fix includes.
5289
66d91b39
JB
52902019-01-01 Joel Brobecker <brobecker@adacore.com>
5291
5292 * gdbreplay.c (gdbreplay_version): Update copyright year in
5293 version message.
5294 * server.c (gdbserver_version): Likewise.
5295
754e3168
AH
52962018-12-05 Alan Hayward <alan.hayward@arm.com>
5297
5298 * linux-low.c (add_lwp): Switch ordering.
5299
d105de22
TT
53002018-11-29 Tom Tromey <tom@tromey.com>
5301
5302 * win32-low.c (win32_join): Take pid, not process.
5303 * target.h (struct target_ops) <join>: Change argument type.
5304 (join_inferior): Change argument name.
5305 * spu-low.c (spu_join): Take pid, not process.
5306 * server.c (handle_detach): Preserve pid before destroying
5307 process.
5308 * lynx-low.c (lynx_join): Take pid, not process.
5309 * linux-low.c (linux_join): Take pid, not process.
5310
50138245
AH
53112018-11-23 Alan Hayward <alan.hayward@arm.com>
5312
5313 * linux-aarch64-low.c (aarch64_cannot_store_register): Remove.
5314 (aarch64_cannot_fetch_register): Likewise.
5315 (struct linux_target_ops): Update references.
5316
64f57f3d
PFC
53172018-10-31 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5318
5319 * linux-ppc-low.c: Include nat/linux-ptrace.h.
5320
8d619c01
EBM
53212018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5322
5323 * configure.srv (ipa_ppc_linux_regobj): Add
5324 powerpc-isa207-htm-vsx32l-ipa.o and
5325 powerpc-isa207-htm-vsx64l-ipa.o.
5326 (powerpc*-*-linux*): Add powerpc-isa207-htm-vsx32l.o and
5327 powerpc-isa207-htm-vsx64l.o to srv_regobj. Add
5328 rs6000/power-htm-spr.xml, rs6000/power-htm-core.xml,
5329 rs6000/power64-htm-core.xml, rs6000/power-htm-fpu.xml,
5330 rs6000/power-htm-altivec.xml, rs6000/power-htm-vsx.xml,
5331 rs6000/power-htm-ppr.xml, rs6000/power-htm-dscr.xml,
5332 rs6000/power-htm-tar.xml, rs6000/powerpc-isa207-htm-vsx32l.xml,
5333 and rs6000/powerpc-isa207-htm-vsx64l.xml to srv_xmlfiles.
5334 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
5335 <PPC_TDESC_ISA207_HTM_VSX>: New enum value.
5336 (init_registers_powerpc_isa207_htm_vsx32l)
5337 (init_registers_powerpc_isa207_htm_vsx64l): Declare.
5338 * linux-ppc-low.c (ppc_fill_tm_sprregset, ppc_store_tm_sprregset)
5339 (ppc_store_tm_cgprregset, ppc_store_tm_cfprregset)
5340 (ppc_store_tm_cvrregset, ppc_store_tm_cvsxregset)
5341 (ppc_store_tm_cpprregset, ppc_store_tm_cdscrregset)
5342 (ppc_store_tm_ctarregset): New functions.
5343 (ppc_regsets): Add entries for HTM regsets.
5344 (ppc_arch_setup): Set htm in features struct when needed. Set
5345 sizes for the HTM regsets.
5346 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_HTM_VSX.
5347 (initialize_low_arch): Call
5348 init_registers_powerpc_isa207_htm_vsx32l and
5349 init_registers_powerpc_isa207_htm_vsx64l.
5350 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
5351 PPC_TDESC_ISA207_HTM_VSX.
5352 (initialize_low_tracepoint): Call
5353 init_registers_powerpc_isa207_htm_vsx32l and
5354 init_registers_powerpc_isa207_htm_vsx64l.
5355
232bfb86
EBM
53562018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5357
5358 * configure.srv (powerpc*-*-linux*): Add rs6000/power-ebb.xml and
5359 rs6000/power-linux-pmu.xml to srv_xmlfiles.
5360 * linux-ppc-low.c (ppc_store_ebbregset, ppc_fill_pmuregset)
5361 (ppc_store_pmuregset): New functions.
5362 (ppc_regsets): Add entries for ebb and pmu regsets.
5363 (ppc_arch_setup): Set isa207 in features struct if the ebb and
5364 pmu regsets are available. Set sizes for these regsets.
5365
f2cf6173
EBM
53662018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5367
5368 * configure.srv (ipa_ppc_linux_regobj): Add
5369 powerpc-isa207-vsx64l-ipa.o and powerpc-isa207-vsx32l-ipa.o.
5370 (powerpc*-*-linux*): Add powerpc-isa207-vsx32l.o and
5371 powerpc-isa207-vsx64l.o to srv_regobj, add rs6000/power-tar.xml,
5372 rs6000/powerpc-isa207-vsx32l.xml, and
5373 rs6000/powerpc-isa207-vsx64l.xml to srv_xmlfiles.
5374 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
5375 <PPC_TDESC_ISA207_VSX>: New enum value.
5376 (init_registers_powerpc_isa207_vsx32l): Declare.
5377 (init_registers_powerpc_isa207_vsx64l): Declare.
5378 * linux-ppc-low.c (ppc_fill_tarregset): New function.
5379 (ppc_store_tarregset): New function.
5380 (ppc_regsets): Add entry for the TAR regset.
5381 (ppc_arch_setup): Set isa207 in features struct when needed. Set
5382 size for the TAR regsets.
5383 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_VSX.
5384 (initialize_low_arch): Call init_registers_powerpc_isa207_vsx32l
5385 and init_registers_powerpc_isa207_vsx64l.
5386 * linux-ppc-ipa.c (get_ipa_tdesc): Handle PPC_TDESC_ISA207_VSX.
5387 (initialize_low_tracepoint): Call
5388 init_registers_powerpc_isa207_vsx32l and
5389 init_registers_powerpc_isa207_vsx64l.
5390
7ca18ed6
EBM
53912018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
5392 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5393
5394 * configure.srv (ipa_ppc_linux_regobj): Add
5395 powerpc-isa205-ppr-dscr-vsx32l-ipa.o and
5396 powerpc-isa205-ppr-dscr-vsx64l-ipa.o.
5397 (powerpc*-*-linux*): Add powerpc-isa205-ppr-dscr-vsx32l.o and
5398 powerpc-isa205-ppr-dscr-vsx64l.o to srv_regobj, add
5399 rs6000/power-dscr.xml, rs6000/power-ppr.xml,
5400 rs6000/powerpc-isa205-ppr-dscr-vsx32l.xml and
5401 rs6000/powerpc-isa205-ppr-dscr-vsx64l.xml to srv_xmlfiles.
5402 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
5403 <PPC_TDESC_ISA205_PPR_DSCR_VSX>: New enum value.
5404 (init_registers_powerpc_isa205_ppr_dscr_vsx32l)
5405 (init_registers_powerpc_isa205_ppr_dscr_vsx64l): Declare.
5406 * linux-ppc-low.c: Include "elf/common.h" and <sys/uio.h>.
5407 (ppc_hwcap): Add comment.
5408 (ppc_hwcap2): New global.
5409 (ppc_check_regset, ppc_fill_pprregset, ppc_store_pprregset)
5410 (ppc_fill_dscrregset, ppc_store_dscrregset): New functions.
5411 (ppc_regsets): Add entries for the DSCR and PPR regsets.
5412 (ppc_arch_setup): Get AT_HWCAP2. Set ppr_dscr in features struct
5413 when needed. Set sizes for the the DSCR and PPR regsets.
5414 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA205_PPR_DSCR_VSX.
5415 (initialize_low_arch): Call
5416 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
5417 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
5418 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
5419 PPC_TDESC_ISA205_PPR_DSCR_VSX.
5420 (initialize_low_tracepoint): Call
5421 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
5422 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
5423
5c849b22
PFC
54242018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5425
5426 * linux-ppc-low.c (ppc_fill_vrregset): Remove memset calls.
5427
8ecfd7bd
SDJ
54282018-10-10 Sergio Durigan Junior <sergiodj@redhat.com>
5429 Simon Marchi <simark@simark.ca>
5430
5431 * acinclude.m4: Include "../selftest.m4".
5432 * configure: Regenerate.
5433 * configure.ac: Use "GDB_AC_SELFTEST".
5434 * configure.srv: Use "$enable_unittests" instead of
5435 "$development" when checking whether unit tests have been
5436 enabled.
5437 * server.c (captured_main): Update message informing that
5438 selftests have been disabled.
5439
96643e35
TT
54402018-10-04 Tom Tromey <tom@tromey.com>
5441
5442 * configure: Rebuild.
5443
da4ae14a
TT
54442018-10-04 Tom Tromey <tom@tromey.com>
5445
5446 * server.c (handle_status): Rename inner "thread".
5447 (process_serial_event): Declare "res" in 'm' case.
5448 * linux-low.c (last_thread_of_process_p, find_lwp_pid)
5449 (iterate_over_lwps): Rename inner "thread".
5450 (linux_qxfer_libraries_svr4): Rename inner "len".
5451 * gdbthread.h (find_thread_in_random): Rename inner "thread".
5452
7c619dbd
GB
54532018-10-01 Gary Benson <gbenson@redhat.com>
5454
5455 * gdb_proc_service.h: Moved common code to
5456 common/gdb_proc_service.h.
5457
3795e814
GB
54582018-10-01 Gary Benson <gbenson@redhat.com>
5459
5460 * gdb_proc_service.h: Synchronize comments and whitespace with
5461 GDB's version of this file.
5462
49b036f1
TT
54632018-09-25 Tom Tromey <tom@tromey.com>
5464
5465 * configure: Rebuild.
5466 * configure.ac (WARN_CFLAGS): Don't remove -Wmissing-prototypes.
5467
8ff03f0b
SM
54682018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
5469
5470 * Makefile.in (gdbserver$(EXEEXT)): Sort OBS.
5471 (gdbreplay$(EXEEXT)): Sort GDBREPLAY_OBS.
5472 ($(IPA_LIB)): Sort IPA_OBJS.
5473
a1cd91dc
SM
54742018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
5475
5476 * Makefile.in: Remove references to $(ADD_DEPS).
5477
752312ba
TT
54782018-09-16 Tom Tromey <tom@tromey.com>
5479
5480 * remote-utils.c (remote_open): Use GNU style for metasyntactic
5481 variables.
5482 * gdbreplay.c (gdbreplay_usage): Use GNU style for metasyntactic
5483 variables.
5484
f1628857
TT
54852018-09-05 Tom Tromey <tom@tromey.com>
5486
5487 * configure: Rebuild.
5488
ad202fcc
SM
54892018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
5490
5491 PR build/23399
5492 * tracepoint.c (IPA_SYM_STRUCT_NAME): Define.
5493
d3d8724a
TT
54942018-08-27 Tom Tromey <tom@tromey.com>
5495
5496 PR build/23087:
5497 * configure: Rebuild.
5498
b4f183d2
TT
54992018-08-27 Tom Tromey <tom@tromey.com>
5500
5501 * linux-s390-low.c (s390_emit_ext, s390_emit_litpool)
5502 (s390_emit_const, s390_emit_reg, s390_emit_zero_ext)
5503 (s390_emit_stack_adjust, s390_emit_set_r2, s390x_emit_ext)
5504 (s390x_emit_const, s390x_emit_reg, s390x_emit_zero_ext)
5505 (s390x_emit_stack_adjust): Add casts to unsigned char.
5506
4e2aa472
SM
55072018-08-22 Simon Marchi <simon.marchi@ericsson.com>
5508
5509 PR gdb/23374
5510 PR gdb/23375
5511 * server.h (struct client_state) <disable_randomization>:
5512 Initialize to 1.
5513
cf4088a9
SM
55142018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
5515
5516 * linux-mips-low.c (mips_collect_ptrace_register): Remove unused
5517 variable.
5518 (mips_supply_ptrace_register): Likewise.
5519
a0de763e
TT
55202018-07-22 Tom Tromey <tom@tromey.com>
5521
5522 * configure: Rebuild.
5523
b0a7723d
TT
55242018-07-22 Tom Tromey <tom@tromey.com>
5525
5526 * win32-low.c (win32_create_inferior): Remove unused variables.
5527 * gdbreplay.c (remote_open): Remove unused variable.
5528 * remote-utils.c (remote_prepare): Remove unused variable.
5529 * x86-tdesc.h (X86_TDESC_H): Define.
5530 (amd64_expedite_regs): Define conditionally.
5531 (i386_expedite_regs): Mark ATTRIBUTE_UNUSED.
5532 * linux-x86-tdesc.c (i386_tdescs): Move inside #if.
5533 * remote-utils.c (readchar): Remove unused variable.
5534
a780ef4f
PA
55352018-07-13 Pedro Alves <palves@redhat.com>
5536
5537 * linux-low.c (linux_kill): Change parameter to process_info
5538 pointer instead of pid. Adjust.
5539 * lynx-low.c (lynx_kill): Likewise.
5540 * nto-low.c (nto_kill): Likewise.
5541 * spu-low.c (spu_kill): Likewise.
5542 * win32-low.c (win32_kill): Likewise.
5543 * server.c (handle_v_kill, kill_inferior_callback)
5544 (detach_or_kill_for_exit): Adjust.
5545 * target.c (kill_inferior): Change parameter to process_info
5546 pointer instead of pid. Adjust.
5547 * target.h (struct target_ops) <kill>: Change parameter to
5548 process_info pointer instead of pid. Adjust all implementations
5549 and callers.
5550 (kill_inferior): Likewise.
5551
ef2ddb33
PA
55522018-07-13 Pedro Alves <palves@redhat.com>
5553
5554 * linux-low.c (linux_detach, linux_join): Change parameter to
5555 process_info pointer instead of pid. Adjust.
5556 * lynx-low.c (lynx_detach, lynx_join): Likewise.
5557 * nto-low.c (nto_detach): Likewise.
5558 * spu-low.c (spu_detach, spu_join): Likewise.
5559 * win32-low.c (win32_detach, win32_join): Likewise.
5560 * server.c (handle_detach, detach_or_kill_for_exit): Adjust.
5561 * target.h (struct target_ops) <detach, join>: Change parameter to
5562 process_info pointer instead of pid. Adjust all implementations
5563 and callers.
5564 (detach_inferior, join_inferior): Rename 'pid' parameter to
5565 'proc'.
5566
c7ab0aef
SDJ
55672018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
5568 Jan Kratochvil <jan.kratochvil@redhat.com>
5569 Paul Fertser <fercerpav@gmail.com>
5570 Tsutomu Seki <sekiriki@gmail.com>
5571
5572 * Makefile.in (SFILES): Add '$(srcdir)/common/netstuff.c'.
5573 (OBS): Add 'common/netstuff.o'.
5574 (GDBREPLAY_OBS): Likewise.
5575 * gdbreplay.c: Include 'wspiapi.h' and 'netstuff.h'.
5576 (remote_open): Implement support for IPv6
5577 connections.
5578 * remote-utils.c: Include 'netstuff.h', 'filestuff.h'
5579 and 'wspiapi.h'.
5580 (handle_accept_event): Accept connections from IPv6 sources.
5581 (remote_prepare): Handle IPv6-style hostnames; implement
5582 support for IPv6 connections.
5583 (remote_open): Implement support for printing connections from
5584 IPv6 sources.
5585
31445d10
PA
55862018-07-11 Pedro Alves <palves@redhat.com>
5587
5588 PR gdb/23377
5589 * mem-break.c (any_persistent_commands): Add process_info
5590 parameter and use it instead of relying on the current process.
5591 Change return type to bool.
5592 * mem-break.h (any_persistent_commands): Add process_info
5593 parameter and change return type to bool.
5594 * server.c (handle_detach): Remove require_running_or_return call.
5595 Look up the process_info for the process we're about to detach.
5596 If not found, return back error to GDB. Adjust
5597 any_persistent_commands call to pass down a process pointer.
5598
cb197132
PA
55992018-07-11 Pedro Alves <palves@redhat.com>
5600
5601 * i387-fp.c (i387_cache_to_fsave, cache_to_fxsave)
5602 (i387_cache_to_xsave): Use regcache_raw_get_unsigned_by_name
5603 instead of collect_register_by_name.
5604 * regcache.c (regcache_raw_get_unsigned_by_name): New.
5605 * regcache.h (regcache_raw_get_unsigned_by_name): New.
5606
1b919490
VB
56072018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
5608 Pedro Alves <palves@redhat.com>
5609
5610 * linux-low.c (initialize_low): Call linux_proc_init_warnings.
5611
d7e15655
TT
56122018-07-03 Tom Tromey <tom@tromey.com>
5613
5614 * linux-low.c: Update.
5615 * lynx-low.c: Update.
5616 * mem-break.c: Update.
5617 * nto-low.c: Update.
5618 * remote-utils.c: Update.
5619 * server.c: Update.
5620 * spu-low.c: Update.
5621 * target.c: Update.
5622 * win32-low.c: Update.
5623
26a57c92
TT
56242018-07-03 Tom Tromey <tom@tromey.com>
5625
5626 * server.c: Update.
5627
0e998d96
TT
56282018-07-03 Tom Tromey <tom@tromey.com>
5629
5630 * linux-low.c: Update.
5631
cc6bcb54
TT
56322018-07-03 Tom Tromey <tom@tromey.com>
5633
5634 * target.c: Update.
5635
e38504b3
TT
56362018-07-03 Tom Tromey <tom@tromey.com>
5637
5638 * linux-low.c: Update.
5639 * linux-mips-low.c: Update.
5640 * lynx-low.c: Update.
5641 * nto-low.c: Update.
5642 * remote-utils.c: Update.
5643 * server.c: Update.
5644 * spu-low.c: Update.
5645 * target.c: Update.
5646 * thread-db.c: Update.
5647
e99b03dc
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 * mem-break.c: Update.
5654 * nto-low.c: Update.
5655 * remote-utils.c: Update.
5656 * server.c: Update.
5657 * spu-low.c: Update.
5658 * target.c: Update.
5659 * tracepoint.c: Update.
5660
f2907e49
TT
56612018-07-03 Tom Tromey <tom@tromey.com>
5662
5663 * linux-low.c: Update.
5664 * linux-ppc-low.c: Update.
5665 * linux-x86-low.c: Update.
5666 * proc-service.c: Update.
5667 * server.c: Update.
5668 * spu-low.c: Update.
5669 * thread-db.c: Update.
5670 * win32-low.c: Update.
5671
fd79271b
TT
56722018-07-03 Tom Tromey <tom@tromey.com>
5673
5674 * linux-low.c: Update.
5675 * lynx-low.c: Update.
5676 * nto-low.c: Update.
5677 * remote-utils.c: Update.
5678 * spu-low.c: Update.
5679 * thread-db.c: Update.
5680 * win32-low.c: Update.
5681
c0867626
SDJ
56822018-06-29 Joel Brobecker <brobecker@adacore.com>
5683
5684 * linux-x86-tdesc.c (amd64_linux_read_description): Add missing
5685 parameter in call to 'amd64_create_target_description'.
5686
2512d7ef
JK
56872018-06-28 Jan Kratochvil <jan.kratochvil@redhat.com>
5688
5689 * x86-tdesc.h: Remove executable permission flag.
5690
d0ac1c44
SM
56912018-06-19 Simon Marchi <simon.marchi@ericsson.com>
5692
5693 * configure.ac: Remove AC_PREREQ, add missing quoting.
5694 * configure: Re-generate.
5695 * config.in: Re-generate.
5696 * aclocal.m4: Re-generate.
5697
c4eb05ff
SM
56982018-06-18 Simon Marchi <simon.marchi@ericsson.com>
5699
5700 * tracepoint.h (current_traceframe): Remove declaration.
5701
02895270
AH
57022018-06-18 Alan Hayward <alan.hayward@arm.com>
5703
5704 * linux-aarch64-low.c (is_sve_tdesc): New function.
5705 (aarch64_sve_regs_copy_to_regcache): Likewise.
5706 (aarch64_sve_regs_copy_from_regcache): Likewise.
5707 (aarch64_regs_info): Add SVE checks.
5708 (initialize_low_arch): Initialize SVE.
5709
e9902bfc
AH
57102018-06-18 Alan Hayward <alan.hayward@arm.com>
5711
5712 * Makefile.in: Add aarch64-sve-linux-ptrace.c.
5713
fefa175e
AH
57142018-06-11 Alan Hayward <alan.hayward@arm.com>
5715
5716 * linux-aarch64-ipa.c (get_ipa_tdesc): Add null VQ param.
5717 (initialize_low_tracepoint): Likewise
5718 * linux-aarch64-low.c (aarch64_arch_setup): Get VQ.
5719 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Add null VQ
5720 param.
5721 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add VQ
5722 checks.
5723 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Add VQ.
5724
b91ad3ff
AH
57252018-06-11 Alan Hayward <alan.hayward@arm.com>
5726
5727 * server.h (PBUFSIZ): Increase size
5728
f868386e
AH
57292018-06-11 Alan Hayward <alan.hayward@arm.com>
5730
5731 * regcache.c (regcache::raw_compare): New function.
5732 * regcache.h (regcache::raw_compare): New declaration.
5733
9c861883
AH
57342018-06-11 Alan Hayward <alan.hayward@arm.com>
5735
5736 * regcache.c (new_register_cache): Use new.
5737 (free_register_cache): Use delete.
5738 (register_data): Use const.
5739 (supply_register): Move body inside regcache.
5740 (regcache::raw_supply): New override function.
5741 (collect_register): Move body inside regcache.
5742 (regcache::raw_collect): New override function.
5743 (regcache::get_register_status): New override function.
5744 * regcache.h (struct regcache): Inherit from reg_buffer_common.
5745
40591844
TT
57462018-06-09 Tom Tromey <tom@tromey.com>
5747
5748 * event-loop.c (gdb_event, gdb_event_p): Remove typedefs. Don't
5749 declare queue.
5750 (event_queue): Use std::queue.
5751 (gdb_event_xfree): Remove.
5752 (initialize_event_loop, process_event, wait_for_event): Update.
5753
6341380d
SC
57542018-06-08 Stan Cox <scox@redhat.com>
5755
5756 * win32-low.c (win32_create_inferior): last_ptid and last_status
5757 moved to client_state.
5758
03349c93
PA
57592018-06-08 Pedro Alves <palves@redhat.com>
5760
5761 * Makefile.in (GDBREPLAY_OBS): Add common/cleanups.o,
5762 common/common-exceptions.o, common/common-utils.o,
5763 common/errors.o, common/print-utils.o and utils.o.
5764 * gdbreplay.c: Include "common-defs.h" instead of the two
5765 'config.h's here. Don't include stdio.h, errno.h, stdlib.h,
5766 string.h or alloca.h.
5767 (perror_with_name): Delete.
5768 (remote_open): Use xstrdup instead of strdup.
5769 (main): Rename to ...
5770 (captured_main): ... this.
5771 (main): New.
5772
8dcc53b3
TT
57732018-06-08 Tom Tromey <tom@tromey.com>
5774
5775 * linux-low.c (linux_low_read_btrace): Update.
5776
c12a5089
SC
57772018-06-04 Stan Cox <scox@redhat.com>
5778
5779 * server.h (struct client_state): New.
5780 * server.c (cont_thread, general_thread, multi_process)
5781 (report_fork_events, report_vfork_events, report_exec_events)
5782 (report_thread_events, swbreak_feature, hwbreak_feature)
5783 (vCont_supported, disable_randomization, pass_signals)
5784 (program_signals, program_signals_p, last_status, last_ptid, own_buf):
5785 Moved to client_state.
5786 * remote-utils.c (remote_debug, noack_mode)
5787 (transport_is_reliable): Moved to client_state.
5788 * tracepoint.c (current_traceframe): Moved to client_state.
5789
5790 Update all callers.
5791 * server.c, remote-utils.c, tracepoint.c, fork-child.c,
5792 linux-low.c, remote-utils.h, target.c: Use client_state.
5793
122394f1
AH
57942018-05-31 Alan Hayward <alan.hayward@arm.com>
5795
5796 * configure.srv: Add new c/h file.
5797
95228a0d
AH
57982018-05-31 Alan Hayward <alan.hayward@arm.com>
5799
5800 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add
5801 null VQ.
5802
d8dab6c3
MR
58032018-05-25 Maciej W. Rozycki <macro@mips.com>
5804
5805 * gdb.arch/mips-fpregset-core.exp: New test.
5806 * gdb.arch/mips-fpregset-core.c: New test source.
5807
81e25b7c
EK
58082018-05-23 Erik Kurzinger <ekurzinger@nvidia.com>
5809
5810 PR server/23198
5811 * hostio.c (require_int): Do not report overflow for integers
5812 between 0xfffffff and 0x7fffffff.
5813
7e947ad3
MR
58142018-05-22 Maciej W. Rozycki <macro@mips.com>
5815
5816 * linux-mips-low.c [HAVE_PTRACE_GETREGS] (mips_collect_register)
5817 (mips_supply_register): Move outside HAVE_PTRACE_GETREGS.
5818 (mips_collect_ptrace_register, mips_supply_ptrace_register): New
5819 functions.
5820 (the_low_target): Wire them.
5821
1d75a658
PFC
58222018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5823
5824 * linux-ppc-low.c (ppc_fill_vrregset): Add vscr_offset variable.
5825 Set vscr_offset to 0 in little-endian mode and 12 in big-endian
5826 mode. Call collect_register_by_name with vscr using
5827 vscr_offset. Zero-pad vscr and vrsave fields in collector buffer.
5828 (ppc_store_vrregset): Add and set vscr_offset variable as in
5829 ppc_fill_vrregset. Call supply_register_by_name with vscr using
5830 vscr_offset.
5831
d078308a
PFC
58322018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5833
5834 * linux-ppc-low.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
5835 (ppc_arch_setup): Change SIZEOF_VRREGS and SIZEOF_VSXREGS to
5836 PPC_LINUX_SIZEOF_VRREGSET and PPC_LINUX_SIZEOF_VSXREGSET.
5837
7273b5fc
PFC
58382018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5839
5840 * linux-ppc-low.c (ppc_fill_vsxregset): Remove ppc_hwcap check.
5841 (ppc_store_vsxregset): Likewise.
5842 (ppc_fill_vrregset): Likewise.
5843 (ppc_store_vrregset): Likewise.
5844 (ppc_fill_evrregset): Likewise.
5845 (ppc_store_evrregset): Likewise.
5846 (ppc_regsets): Set VSX/VR/EVR regset sizes to 0.
5847 (ppc_arch_setup): Iterate through ppc_regsets and set sizes when
5848 needed.
5849
2e077f5e
PFC
58502018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5851
5852 * linux-ppc-low.c (ppc_arch_setup): Remove code for getting the
5853 wordsize of the inferior. Call ppc_linux_target_wordsize.
5854
bd64614e
PFC
58552018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5856
5857 * configure.srv (srv_tgtobj): Add arch/ppc-linux-common.o.
5858 * Makefile.in (SFILES): Add arch/ppc-linux-common.c.
5859 * linux-ppc-tdesc.h: Rename to linux-ppc-tdesc-init.h.
5860 * linux-ppc-tdesc-init.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
5861 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
5862 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
5863 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
5864 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
5865 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
5866 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
5867 (tdesc_powerpc_e500l): Remove.
5868 * linux-ppc-ipa.c: Include arch/ppc-linux-tdesc.h and
5869 linux-ppc-tdesc-init.h. Don't include linux-ppc-tdesc.h.
5870 * linux-ppc-low.c: Include arch/ppc-linux-common.h,
5871 arch/ppc-linux-tdesc.h, and linux-ppc-tdesc-init.h. Don't include
5872 linux-ppc-tdesc.h.
5873 (ppc_arch_setup): Remove target description matching code. Fill a
5874 ppc_linux_features struct and call ppc_linux_match_description
5875 with it.
5876
75d74cca
MR
58772018-05-22 Maciej W. Rozycki <macro@mips.com>
5878
5879 * linux-mips-low.c (mips_cannot_fetch_register): Return 1 if the
5880 width of the requested register exceeds the width of the
5881 `ptrace' data type.
5882 (mips_cannot_store_register): Likewise.
5883
e4439e43
MR
58842018-05-21 Maciej W. Rozycki <macro@mips.com>
5885
5886 * linux-mips-low.c (mips_fetch_register): New function. Update
5887 preceding comment.
5888 (mips_store_gregset): Supply 0 rather than $restart for $zero.
5889 (the_low_target): Wire `mips_fetch_register'.
5890
55271bf9
JB
58912018-05-10 Joel Brobecker <brobecker@adacore.com>
5892
5893 * lynx-i386-low.c (LYNXOS_178): New macro.
5894 [LYNXOS_178] (usr_fcontext_t): Provide a definition that matches
5895 the layout on LynxOS-178.
5896 (lynx_i386_fill_fpregset, lynx_i386_store_fpregset): Do not
5897 handle floating point registers that are not supported by
5898 LynxOS-178.
5899
1a34f210
TT
59002018-05-10 Tom Tromey <tom@tromey.com>
5901
5902 * configure: Rebuild.
5903
190852c8
JB
59042018-05-10 Joel Brobecker <brobecker@adacore.com>
5905
5906 PR server/23158:
5907 * tdesc.h (init_target_desc) <expedite_regs>: New parameter.
5908 * tdesc.c (init_target_desc) <expedite_regs>: New parameter.
5909 Use it to set the expedite_regs field in the given tdesc.
5910 * x86-tdesc.h: New file.
5911 * linux-aarch64-tdesc.c (aarch64_linux_read_description):
5912 Adjust following the addition of the new expedite_regs parameter
5913 to init_target_desc.
5914 * linux-tic6x-low.c (tic6x_read_description): Likewise.
5915 * linux-x86-tdesc.c: #include "x86-tdesc.h".
5916 (i386_linux_read_description, amd64_linux_read_description):
5917 Adjust following the addition of the new expedite_regs parameter
5918 to init_target_desc.
5919 * lynx-i386-low.c: #include "x86-tdesc.h".
5920 (lynx_i386_arch_setup): Adjust following the addition of the new
5921 expedite_regs parameter to init_target_desc.
5922 * nto-x86-low.c: #include "x86-tdesc.h".
5923 (nto_x86_arch_setup): Adjust following the addition of the new
5924 expedite_regs parameter to init_target_desc.
5925 * win32-i386-low.c: #include "x86-tdesc.h".
5926 (i386_arch_setup): Adjust following the addition of the new
5927 expedite_regs parameter to init_target_desc.
5928
7dbac825
JB
59292018-05-10 Joel Brobecker <brobecker@adacore.com>
5930
5931 PR server/23158:
5932 * win32-low.c (win32_create_inferior): Add call to my_wait
5933 setting last_status global.
5934
906994d9
JB
59352018-05-10 Joel Brobecker <brobecker@adacore.com>
5936
5937 PR server/23158:
5938 * win32-low.c (create_process): Only call gdb_tilde_expand if
5939 inferior_cwd is not NULL.
5940
8ee22052
AB
59412018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
5942
5943 * i387-fp.c (i387_cache_to_xsave): Only write x87 control
5944 registers to the cache if their values have changed.
5945 (i387_xsave_to_cache): Provide default values for x87 control
5946 registers when these features are available, but disabled.
5947 * regcache.c (supply_register_by_name_zeroed): New function.
5948 * regcache.h (supply_register_by_name_zeroed): Declare new
5949 function.
5950
aff689d3
TT
59512018-05-07 Tom Tromey <tom@tromey.com>
5952
5953 * configure: Rebuild.
5954
85e26832
TT
59552018-05-04 Tom Tromey <tom@tromey.com>
5956
5957 * configure: Rebuild.
5958
a3b60e45
JK
59592018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
5960 Pedro Alves <palves@redhat.com>
5961
5962 * linux-aarch64-low.c (aarch64_stopped_data_address):
5963 Likewise.
5964
632e107b
TT
59652018-04-27 Tom Tromey <tom@tromey.com>
5966
5967 * configure: Rebuild.
5968
458412c3
TT
59692018-04-23 Tom Tromey <tom@tromey.com>
5970
5971 * configure: Rebuild.
5972
f31c089e
SM
59732018-04-19 Simon Marchi <simon.marchi@ericsson.com>
5974
5975 * Makefile.in (depcomp): Add "..".
5976 (all_deps_files): New and use it.
5977
b319b098
AH
59782018-04-18 Alan Hayward <alan.hayward@arm.com>
5979
5980 * configure.srv (aarch64*-*-linux*): Don't include xml.
5981 (i[34567]86-*-cygwin*): Likewise.
5982 (i[34567]86-*-linux*): Likewise.
5983 (i[34567]86-*-lynxos*): Likewise.
5984 (i[34567]86-*-mingw32ce*): Likewise.
5985 (i[34567]86-*-mingw*): Likewise.
5986 (i[34567]86-*-nto*): Likewise.
5987 (tic6x-*-uclinux): Likewise.
5988 (x86_64-*-linux*): Likewise.
5989 (x86_64-*-mingw*): Likewise.
5990 (x86_64-*-cygwin*): Likewise.
5991
3b74854b
AH
59922018-04-18 Alan Hayward <alan.hayward@arm.com>
5993
5994 * tdesc.c: Remove xml parameter.
5995
e98577a9
AH
59962018-04-18 Alan Hayward <alan.hayward@arm.com>
5997
5998 * server.c (get_features_xml): Remove cast.
5999 * tdesc.c (void target_desc::accept): Fill in function.
6000 (tdesc_get_features_xml): Remove old xml creation.
6001 (print_xml_feature::visit_pre): Add xml vistor.
6002 * tdesc.h (struct target_desc): Make xmltarget mutable.
6003 (tdesc_get_features_xml): Remove declaration.
6004
d278f585
AH
60052018-04-18 Alan Hayward <alan.hayward@arm.com>
6006
6007 * tdesc.c (tdesc_architecture_name): Add new function.
6008 (tdesc_osabi_name): Likewise.
6009 (tdesc_get_features_xml): Use new functions.
6010
eee8a18d
AH
60112018-04-18 Alan Hayward <alan.hayward@arm.com>
6012
6013 * tdesc.c (tdesc_create_flags): Remove.
6014 (tdesc_add_flag): Likewise.
6015 (tdesc_named_type): Likewise.
6016 (tdesc_create_union): Likewise.
6017 (tdesc_create_struct): Likewise.
6018 (tdesc_create_vector): Likewise.
6019 (tdesc_add_bitfield): Likewise.
6020 (tdesc_add_field): Likewise.
6021 (tdesc_set_struct_size): Likewise.
6022
82ec9bc7
AH
60232018-04-18 Alan Hayward <alan.hayward@arm.com>
6024
6025 * tdesc.c (~target_desc): Remove implictly deleted items.
6026 (init_target_desc): Iterate all features.
6027 (tdesc_get_features_xml): Use vector.
6028 (tdesc_create_feature): Create feature.
6029 * tdesc.h (tdesc_feature) Remove
6030 (target_desc): Add features.
6031
ea3e7d71
AH
60322018-04-18 Alan Hayward <alan.hayward@arm.com>
6033
6034 * Makefile.in: Add common/tdesc.c
6035 * tdesc.c (init_target_desc): init all reg_defs from register
6036 vector.
6037 (tdesc_create_reg): Create tdesc_reg.
6038 * tdesc.h (tdesc_feature): Add register vector.
6039
17d08cd4
SM
60402018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
6041
6042 * tdesc.h (struct target_desc) <features>: Change type to
6043 std::vector<std::string>.
6044 * tdesc.c (target_desc::~target_desc): Adjust to std::vector
6045 changes.
6046 (tdesc_get_features_xml): Likewise.
6047 (tdesc_create_feature): Likewise.
6048
5cd3e386
AH
60492018-03-26 Alan Hayward <alan.hayward@arm.com>
6050
6051 * regcache.c (find_register_by_number): Return a ref.
6052 (find_regno): Use references.
6053 (register_size): Likewise.
6054 (register_data): Likewise.
6055 * tdesc.c (target_desc::~target_desc): Remove free calls.
6056 (target_desc::operator==): Use std::vector compare.
6057 (init_target_desc): Use reference.
6058 (tdesc_create_reg): Use reg constructors.
6059 * tdesc.h (struct target_desc): Replace pointer with object.
6060
dff7492c
AH
60612018-03-23 Alan Hayward <alan.hayward@arm.com>
6062
6063 * regcache.c (find_register_by_number): Make static.
6064 (find_regno): Use find_register_by_number
6065 * regcache.h (struct reg): Remove declaration.
6066
d80e5242
AH
60672018-03-23 Alan Hayward <alan.hayward@arm.com>
6068
6069 * tdesc.c (target_desc::~target_desc): Move to here.
6070 (target_desc::operator==): Likewise.
6071 * tdesc.h (target_desc::~target_desc): Move from here.
6072 (target_desc::operator==): Likewise.
6073
f69c5afb
AA
60742018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
6075
6076 * linux-s390-low.c (s390_get_wordsize): Correct brace style.
6077
ce29f843
AA
60782018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
6079
6080 * linux-s390-ipa.c (get_ipa_tdesc): Add handling for
6081 S390_TDESC_GS.
6082 * linux-s390-low.c (s390_get_ipa_tdesc_idx): Likewise.
6083 (initialize_low_tracepoint): Call init_registers_s390x_gs_linux64
6084 and init_registers_s390_gs_linux64.
6085
c49bd90b
AA
60862018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
6087
6088 * linux-s390-low.c (s390_fill_gs): Remove function.
6089 (s390_fill_gsbc): Remove function.
6090 (s390_regsets): Set fill functions for the guarded storage regsets
6091 to NULL.
6092
7edb9bd3
AA
60932018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
6094
6095 * linux-s390-low.c (s390_get_hwcap): Replace tdesc parameter by
6096 the word size. Add comment.
6097 (s390_get_wordsize): New function.
6098 (s390_arch_setup): No longer select a temporary tdesc to fetch the
6099 pswm with it. Instead, use s390_get_wordsize to determine the
6100 word size first and derive the correct tdesc from that directly.
6101
39be3c7e
SM
61022018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
6103
6104 * Makefile.in: Include silent-rules.mk.
6105 (srcdir, abs_top_srcdir, abs_srcdir, VPATH): Move up.
6106 (COMPILE): Add ECHO_CXX.
6107 (gdbserver$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
6108 (gdbreplay$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
6109 ($(IPA_LIB)): Add SILENCE and ECHO_CXXLD.
6110 (version-generated.c): Add ECHO_GEN.
6111 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN_GENERATED.
6112 (IPAGENT_COMPILE): Add ECHO_CXX.
6113 (%-generated.c): Add ECHO_REGDAT.
6114
3ae9ce5d
TT
61152018-03-14 Tom Tromey <tom@tromey.com>
6116
6117 PR cli/14977:
6118 * ax.c (ax_printf): Special case for NULL.
6119
e6a58aa8
SM
61202018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
6121
6122 * linux-low.c (linux_qxfer_libraries_svr4): Use
6123 xml_escape_text_append.
6124
f6e8a41e
SM
61252018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
6126
6127 * linux-low.c (linux_qxfer_libraries_svr4): Use std::string.
6128
b9671caf
SM
61292018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
6130
6131 * server.c (handle_general_set): Remove unnecessary xstrdup.
6132
e80aaf61
SM
61332018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
6134
6135 * server.c (parse_debug_format_options): Adjust to
6136 delim_string_to_char_ptr_vec changes.
6137 * thread-db.c (thread_db_load_search): Adjust to
6138 dirnames_to_char_ptr_vec changes.
6139
b1223e78
MM
61402018-03-01 Markus Metzger <markus.t.metzger@intel.com>
6141
6142 * target.h (target_enable_btrace, target_disable_btrace)
6143 (target_read_btrace, target_read_btrace_conf): Turn macro into
6144 inline function. Throw error if target method is not defined.
6145 * server.c (handle_qxfer_btrace handle_qxfer_btrace_conf): Remove
6146 check for btrace target method. Be prepared to handle exceptions
6147 from btrace target methods.
6148
81561546
SDJ
61492018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
6150
6151 * server.c (captured_main): Change order of error message printed
6152 when the current working directory cannot be found.
6153
25e3c82c
SDJ
61542018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
6155
6156 * server.c: Include "filenames.h" and "pathstuff.h".
6157 (program_name): Delete variable.
6158 (program_path): New anonymous class.
6159 (get_exec_wrapper): Use "program_path" instead of
6160 "program_name".
6161 (handle_v_run): Likewise.
6162 (captured_main): Likewise.
6163 (process_serial_event): Likewise.
6164
b4987c95
SDJ
61652018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
6166
6167 * Makefile.in (SFILES): Add "$(srcdir)/common/pathstuff.c".
6168 (OBJS): Add "pathstuff.o".
6169 * server.c (current_directory): New global variable.
6170 (captured_main): Initialize "current_directory".
6171
f46cd62a
AH
61722018-02-26 Alan Hayward <alan.hayward@arm.com>
6173
6174 * tdesc.c: Use common/tdesc.h.
6175 * tdesc.h: Likewise.
6176
a543c5ca
AH
61772018-02-20 Alan Hayward <alan.hayward@arm.com>
6178 Simon Marchi <simon.marchi@ericsson.com>
6179
6180 * Makefile.in: Switch order of make rules.
6181
b5884fa7
AH
61822018-02-19 Alan Hayward <alan.hayward@arm.com>
6183
6184 * Makefile.in: Add common directory in build.
6185 * configure.ac: Add common reference.
6186 * configure: Regenerate.
6187
de6242d3
MM
61882018-02-09 Markus Metzger <markus.t.metzger@intel.com>
6189
6190 * linux-low.c (linux_target_ops): Remove linux_supports_btrace.
6191 * nto-low.c (nto_target_ops): Remove NULL for supports_btrace.
6192 * spu-low.c (spu_target_ops): Likewise.
6193 * win32-low.c (win32_target_ops): Likewise.
6194 * server.c (supported_btrace_packets): Report packets unconditionally.
6195 * target.h (target_ops) <supports_btrace>: Remove.
6196 (target_supports_btrace): Remove.
6197
9ee23a85
MM
61982018-02-09 Markus Metzger <markus.t.metzger@intel.com>
6199
6200 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt)
6201 (handle_btrace_disable): Change return type to void. Use exceptions
6202 to report errors.
6203 (handle_btrace_general_set): Catch exception and copy message to
6204 return message.
6205
8ce47547
TT
62062018-02-08 Tom Tromey <tom@tromey.com>
6207
6208 * linux-low.c (install_software_single_step_breakpoints): Use
6209 make_scoped_restore.
6210 * inferiors.c (make_cleanup_restore_current_thread): Remove.
6211 (do_restore_current_thread_cleanup): Remove.
6212 * gdbthread.h (make_cleanup_restore_current_thread): Don't
6213 declare.
6214
45dd3607
TT
62152018-02-08 Tom Tromey <tom@tromey.com>
6216
6217 * mem-break.c (set_raw_breakpoint_at): Use
6218 gdb::unique_xmalloc_ptr.
6219
e671cd59
PA
62202018-01-30 Pedro Alves <palves@redhat.com>
6221
6222 PR gdb/13211
6223 * target.c (target_terminal::terminal_state): Rename to ...
6224 (target_terminal::m_terminal_state): ... this.
6225
a0aad537
JC
62262018-01-19 James Clarke <jrtc27@jrtc27.com>
6227
6228 * linux-low.c (handle_extended_wait): Surround call to
6229 thread_db_notice_clone with #ifdef USE_THREAD_DB.
6230
4d9b86e1
SM
62312018-01-17 Simon Marchi <simon.marchi@ericsson.com>
6232
6233 * linux-low.c (attach_proc_task_lwp_callback): Adjust to
6234 linux_ptrace_attach_fail_reason_string now returning an
6235 std::string.
6236 (linux_attach): Likewise.
6237 * thread-db.c (attach_thread): Likewise.
6238
f517c180
EA
62392018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
6240
6241 PR gdb/21559
6242 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
6243 checking for fs_base/gs_base fields in struct user_regs_struct.
6244 * configure: Regenerate.
6245
9a70f35c
YQ
62462018-01-16 Yao Qi <yao.qi@linaro.org>
6247
6248 PR gdb/18749
6249 * linux-low.c (fetch_register): Call supply_register instead of
6250 error.
6251
605fd3c6
YQ
62522018-01-08 Yao Qi <yao.qi@linaro.org>
6253 Simon Marchi <simon.marchi@ericsson.com>
6254
6255 * Makefile.in (OBS): Remove selftest.o.
6256 * configure.ac: Set srv_selftest_objs if $development is true.
6257 (GDBSERVER_DEPFILES): Append $srv_selftest_objs.
6258 * configure: Re-generated.
6259 * server.c (captured_main): Wrap variable selftest_filter with
6260 GDB_SELF_TEST.
6261
2cc05030
SM
62622018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
6263
6264 * server.c (parse_debug_format_options): Return std::string.
6265 (handle_monitor_command, captured_main): Adjust.
6266
e379cee6
PA
62672018-01-05 Pedro Alves <palves@redhat.com>
6268
6269 PR gdb/18653
6270 * server.c (captured_main): Pass quiet=false to
6271 save_original_signals_state.
6272
82e1e79a
JB
62732018-01-01 Joel Brobecker <brobecker@adacore.com>
6274
6275 * gdbreplay.c (gdbreplay_version): Update copyright year in
6276 version message.
6277 * server.c (gdbserver_version): Likewise.
6278
8e481c3b
TT
62792017-12-08 Tom Tromey <tom@tromey.com>
6280
6281 * ax.c (ax_printf): Update.
6282
a8806230
YQ
62832017-12-07 Yao Qi <yao.qi@linaro.org>
6284
6285 * linux-aarch64-ipa.c (initialize_low_tracepoint): Call
6286 aarch64_linux_read_description.
6287 * linux-amd64-ipa.c (idx2mask): New array.
6288 (get_ipa_tdesc): Move idx2mask out.
6289 (initialize_low_tracepoint): Initialize target descriptions.
6290 * linux-i386-ipa.c (idx2mask): New array.
6291 (get_ipa_tdesc): Move idx2mask out.
6292 (initialize_low_tracepoint): Initialize target descriptions.
6293
d4a0e8b5
SM
62942017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
6295
6296 * tdesc.c (struct tdesc_type): Change return type.
6297 (tdesc_add_flag): Change parameter type.
6298 (tdesc_add_bitfield): Likewise.
6299 (tdesc_add_field): Likewise.
6300 (tdesc_set_struct_size): Likewise.
6301
798a7429
SM
63022017-12-05 Simon Marchi <simon.marchi@ericsson.com>
6303
6304 * regcache.c (registers_to_string): Remove unused variable.
6305
c0e15c9b
SM
63062017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6307
6308 * inferiors.c (for_each_inferior_with_data): Remove.
6309 * inferiors.h (for_each_inferior_with_data): Remove.
6310 * server.c (handle_qxfer_threads_worker): Change parameter type.
6311 (handle_qxfer_threads_proper): Use for_each_thread.
6312
f0045347
SM
63132017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6314
6315 * inferiors.c (for_each_inferior): Remove.
6316 (clear_inferiors): Use for_each_thread.
6317 * inferiors.h (for_each_inferior): Remove.
6318 * linux-low.c (linux_wait_for_event_filtered): Use
6319 for_each_thread.
6320 (linux_stabilize_threads): Likewise.
6321 * regcache.c (regcache_release): Likewise.
6322 * server.c (gdb_wants_all_threads_stopped): Likewise.
6323 (clear_pending_status_callback): Remove.
6324 (handle_status): Use for_each_thread.
6325 (captured_main): Likewise.
6326 * win32-low.c (child_init_thread_list): Likewise.
6327 (win32_clear_inferiors): Likewise.
6328 (fake_breakpoint_event): Likewise.
6329
9521758b
SM
63302017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6331
6332 * inferiors.h (find_inferior): Remove.
6333 * inferiors.c (find_inferior): Remove.
6334
8f86d7aa
SM
63352017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6336
6337 * linux-low.c (resume_status_pending_p): Update comment.
6338 (need_step_over_p): Update comment.
6339
e2b44075
SM
63402017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6341
6342 * linux-low.c (proceed_one_lwp): Return void, change parameter
6343 type.
6344 (unsuspend_and_proceed_one_lwp): Likewise.
6345 (proceed_all_lwps): Use for_each_thread.
6346 (unstop_all_lwps): Likewise.
6347
c80825ff
SM
63482017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6349
6350 * linux-low.c (linux_resume_one_thread): Return void, take
6351 parameter directly.
6352 (linux_resume): Use for_each_thread.
6353
df3e4dbe
SM
63542017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6355
6356 * linux-low.c (send_sigstop_callback): Return void, change
6357 parameter type. Rename to...
6358 (send_sigstop): ... this.
6359 (suspend_and_send_sigstop_callback): Return void, change parameter
6360 type. Rename to...
6361 (suspend_and_send_sigstop): ... this.
6362 (stop_all_lwps): Use for_each_thread.
6363
5a6b0a41
SM
63642017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6365
6366 * linux-low.c (lwp_running): Return bool, remove unused
6367 argument.
6368 (linux_stabilize_threads): Use find_thread.
6369
39a64da5
SM
63702017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6371
6372 * linux-low.c (select_singlestep_lwp_callback): Remove.
6373 (count_events_callback): Remove.
6374 (select_event_lwp_callback): Remove.
6375 (select_event_lwp): Use find_thread/for_each_thread.
6376
a1385b7b
SM
63772017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6378
6379 * linux-low.c (not_stopped_callback): Return bool, take filter
6380 argument directly.
6381 (linux_wait_for_event_filtered): Use find_thread.
6382 (linux_wait_1): Likewise.
6383
454296a2
SM
63842017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6385
6386 * linux-low.c (same_lwp): Remove.
6387 (find_lwp_pid): Use find_thread.
6388
6b2a85da
SM
63892017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6390
6391 * linux-low.c (delete_lwp_callback): Remove.
6392 (linux_mourn): Use for_each_thread.
6393
798a38e8
SM
63942017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6395
6396 * linux-low.c (linux_detach_lwp_callback): Return void, remove
6397 args parameter, don't check for pid.
6398 (linux_detach): Use for_each_thread.
6399
e4eb0dec
SM
64002017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6401
6402 * linux-low.c (struct counter): Remove.
6403 (second_thread_of_pid_p): Remove.
6404 (last_thread_of_process_p): Use find_thread.
6405
83e1b6c1
SM
64062017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6407
6408 * inferiors.c (find_inferior_in_random): Remove.
6409 * inferiors.h (find_inferior_in_random): Remove.
6410 * linux-low.c (status_pending_p_callback): Return bool, accept
6411 parameter ptid directly.
6412 (linux_wait_for_event_filtered): Use find_thread_in_random.
6413 (linux_wait_1): Likewise.
6414
8dc7b443
SM
64152017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6416
6417 * inferiors.c (find_inferior_id): Remove.
6418 (find_thread_ptid): Move implemention from find_inferior_id to
6419 here.
6420 * inferiors.h (find_inferior_id): Remove.
6421 * server.c (handle_status): Use find_thread_ptid.
6422 (process_serial_event): Likewise.
6423 * thread-db.c (find_one_thread): Likewise.
6424 (thread_db_thread_handle): Likewise.
6425 * win32-low.c (thread_rec): Likewise.
6426 (child_delete_thread): Likewise.
6427 (win32_thread_alive): Likewise.
6428 (get_child_debug_event): Likewise.
6429
da25033c
SM
64302017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6431
6432 * linux-mips-low.c (update_watch_registers_callback): Return
6433 void, remove pid_p parameter, don't check for pid.
6434 (mips_insert_point, mips_remove_point): Use for_each_thread.
6435
c91bb56b
SM
64362017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6437
6438 * lynx.low (lynx_delete_thread_callback): Remove.
6439 (lynx_mourn): Use for_each_thread.
6440
634a3254
SM
64412017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6442
6443 * regcache.c (regcache_invalidate_one): Remove.
6444 (regcache_invalidate_pid): use for_each_thread.
6445
41272101
TT
64462017-11-26 Tom Tromey <tom@tromey.com>
6447
6448 * linux-low.c (linux_create_inferior): Update.
6449
f5291a6f
UW
64502017-11-24 Ulrich Weigand <uweigand@de.ibm.com>
6451
6452 * spu-low.c (spu_create_inferior): Fix typo in argument name.
6453
6654d750
AH
64542017-11-24 Alan Hayward <alan.hayward@arm.com>
6455
6456 * configure.srv: Add linux-aarch64-tdesc-selftest.o.
6457 * linux-aarch64-low.c (initialize_low_arch): Call init func.
6458 * linux-aarch64-tdesc-selftest.c: New file.
6459 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
6460
64612017-11-24 Alan Hayward <alan.hayward@arm.com>
6462
6463 * configure.srv: Add new file.
6464 * linux-aarch64-low.c (initialize_low_arch): Call init func.
6465 * linux-aarch64-tdesc-selftest.c: New file.
6466 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
6467
49bdb7ee
AH
64682017-11-24 Alan Hayward <alan.hayward@arm.com>
6469
6470 * linux-aarch64-ipa.c (initialize_low_tracepoint): Remove init.
6471 * linux-aarch64-low.c (initialize_low_arch): Remove init.
6472 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add init.
6473
d6d7ce56
AH
64742017-11-24 Alan Hayward <alan.hayward@arm.com>
6475
6476 * configure.srv: Add new files.
6477 * linux-aarch64-ipa.c (get_ipa_tdesc): Call
6478 aarch64_linux_read_description.
6479 * linux-aarch64-low.c (aarch64_linux_read_description):
6480 Merge with aarch64_arch_setup.
6481 (aarch64_arch_setup): Call aarch64_linux_read_description.
6482 * linux-aarch64-tdesc.c: New file.
6483 * linux-aarch64-tdesc.h: New file.
6484
506fe5f4
YQ
64852017-11-24 Yao Qi <yao.qi@linaro.org>
6486
6487 * configure.srv: Set $srv_regobj for tic6x-linux.
6488 * linux-tic6x-low.c: Include "arch/tic6x.h" and "tdesc.h".
6489 (tic6x_read_description): Move some code to tic6x_arch_setup.
6490 (tic6x_tdesc_test): New function.
6491 (initialize_low_arch): Call selftests::register_test.
6492
29f9a567
YQ
64932017-11-22 Yao Qi <yao.qi@linaro.org>
6494
6495 * remote-utils.c (prepare_resume_reply): Use memcpy.
6496
578290ec
SM
64972017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6498
6499 * linux-low.c (kill_one_lwp_callback): Return void, take
6500 argument directly, don't filter on pid.
6501 (linux_kill): Use for_each_thread.
6502
eca55aec
SM
65032017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6504
6505 * linux-low.c (need_step_over_p): Return bool, remove dummy
6506 argument.
6507 (linux_resume, proceed_all_lwps): Use find_thread.
6508
25c28b4d
SM
65092017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6510
6511 * linux-low.c (resume_status_pending_p): Return bool, remove
6512 flag_p argument.
6513 (linux_resume): Use find_thread.
6514
5fdda392
SM
65152017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6516
6517 * linux-low.c (struct thread_resume_array): Remove.
6518 (linux_set_resume_request): Return void, take arguments
6519 directly.
6520 (linux_resume): Use for_each_thread.
6521
fcb056a5
SM
65222017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6523
6524 * linux-low.c (stuck_in_jump_pad_callback): Change prototype,
6525 return bool, remove data argument.
6526 (linux_stabilize_threads): Use find_thread.
6527
139720c5
SM
65282017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6529
6530 * linux-low.c (unsuspend_one_lwp): Remove.
6531 (unsuspend_all_lwps): Use for_each_thread, inline code from
6532 unsuspend_one_lwp.
6533
6d1e5673
SM
65342017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6535
6536 * gdbthread.h (find_thread): Add overload with ptid_t filter.
6537 * linux-low.c (struct iterate_over_lwps_args): Remove.
6538 (iterate_over_lwps_filter): Remove.
6539 (iterate_over_lwps): Use find_thread.
6540
bbf550d5
SM
65412017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6542
6543 * linux-low.c (reset_lwp_ptrace_options_callback): Remove.
6544 (linux_handle_new_gdb_connection): Use for_each_thread, inline
6545 code from reset_lwp_ptrace_options_callback.
6546
00192f77
SM
65472017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6548
6549 * linux-arm-low.c (struct update_registers_data): Remove.
6550 (update_registers_callback): Return void, take arguments
6551 directly, don't check thread's pid.
6552 (arm_insert_point, arm_remove_point): Use for_each_thread.
6553
2bee2b6c
SM
65542017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6555
6556 * win32-low.c (continue_one_thread): Return void, take argument
6557 directly.
6558 (child_continue): Use for_each_thread.
6559
0b360f19
SM
65602017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6561
6562 * win32-i386-low.c (update_debug_registers_callback): Rename
6563 to ...
6564 (update_debug_registers): ... this, return void, remove pid_p arg.
6565 (x86_dr_low_set_addr, x86_dr_low_set_control): Use for_each_thread.
6566
f27866ba
SM
65672017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
6568
6569 * inferiors.h (struct process_info): Add constructor, initialize
6570 fields..
6571 <syscalls_to_catch>: Change type to std::vector<int>.
6572 * inferiors.c (add_process): Allocate process_info with new.
6573 (remove_process): Free process_info with delete.
6574 * linux-low.c (handle_extended_wait): Adjust.
6575 (gdb_catching_syscalls_p, gdb_catch_this_syscall_p): Adjust.
6576 * server.c (handle_general_set): Adjust.
6577
e849ea89
PA
65782017-11-16 Pedro Alves <palves@redhat.com>
6579
6580 * remote-utils.c (remote_close): Block SIGIO signals instead of
6581 uninstalling the SIGIO handler.
6582
1d0aa65c
AH
65832017-11-16 Alan Hayward <alan.hayward@arm.com>
6584
6585 * tdesc.c (tdesc_get_features_xml): Allow null osabi.
6586
3491a34c
YQ
65872017-11-16 Yao Qi <yao.qi@linaro.org>
6588
6589 * linux-tic6x-low.c (tic6x_fill_gregset): Cast buf.
6590 (tic6x_store_gregset): Likewise.
6591 (tic6x_usrregs_info): Move it up.
6592
a602f924
AH
65932017-11-15 Alan Hayward <alan.hayward@arm.com>
6594
6595 * Makefile.in: Update arch rules.
6596 * configure.srv: Explicitly mark arch/ files.
6597
5616b6c3
AS
65982017-11-13 Andreas Schwab <schwab@suse.de>
6599
6600 * linux-m68k-low.c (m68k_supports_hardware_single_step): New
6601 function.
6602 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6603
d1928160
PA
66042017-11-06 Pedro Alves <palves@redhat.com>
6605
6606 * config.in, configure: Regenerate.
6607
bac608e7
SM
66082017-10-27 Simon Marchi <simon.marchi@ericsson.com>
6609
6610 * target.c (struct thread_search): Remove.
6611 (thread_search_callback): Remove.
6612 (prepare_to_access_memory): Use for_each_thread instead of
6613 find_inferior. Inline code from thread_search_callback.
6614
eaddb425
SM
66152017-10-27 Simon Marchi <simon.marchi@ericsson.com>
6616
6617 * server.c (struct visit_actioned_threads_data): Remove.
6618 (visit_actioned_threads): Change prototype to take arguments
6619 directly.
6620 (resume): Use find_thread instead of find_inferior.
6621
99078d34
SM
66222017-10-27 Simon Marchi <simon.marchi@ericsson.com>
6623
6624 * server.c (queue_stop_reply_callback): Change prototype, return
6625 void.
6626 (find_status_pending_thread_callback): Remove.
6627 (handle_status): Replace find_inferior with find_thread and
6628 for_each_thread.
6629
cc628f3d
AH
66302017-10-25 Alan Hayward <alan.hayward@arm.com>
6631
6632 * linux-aarch64-low.c (aarch64_fill_gregset): Replace defines
6633 with REGNO.
6634 (aarch64_store_gregset): Likewise.
6635 (aarch64_fill_fpregset): Likewise.
6636 (aarch64_store_fpregset): Likewise.
6637
4d3bb80e
SM
66382017-10-21 Simon Marchi <simon.marchi@ericsson.com>
6639
6640 * gdbthread.h (find_thread, for_each_thread): New functions.
6641 * inferiors.c (thread_of_pid): Remove.
6642 (find_any_thread_of_pid): Use find_thread.
6643 * linux-low.c (num_lwps): Use for_each_thread.
6644
7a7cdfa0
YQ
66452017-10-17 Yao Qi <yao.qi@linaro.org>
6646
6647 * Makefile.in: Remove one rule.
6648 * configure.srv: Rename aarch64-insn.o with arch/aarch64-insn.o.
6649
e675d170
YQ
66502017-10-17 Yao Qi <yao.qi@linaro.org>
6651
6652 * configure.srv: Rename arm-linux.o with arch/arm-linux.o.
6653 Rename arm-get-next-pcs.o with arch/arm-get-next-pcs.o.
6654
7eb4e0f9
YQ
66552017-10-17 Yao Qi <yao.qi@linaro.org>
6656
6657 * configure.srv: Rename arm.o with arch/arm.o.
6658
60d6cfc9
YQ
66592017-10-17 Yao Qi <yao.qi@linaro.org>
6660
6661 * Makefile.in (CONFIG_SRC_SUBDIR): New variable.
6662 (clean): Remove .o files in CONFIG_SRC_SUBDIR.
6663 (distclean): Remove DEPDIR in CONFIG_SRC_SUBDIR.
6664 (arch-i386.o, arch-amd64.o): Remove rules.
6665 (arch/%.o): New rule.
6666 Update POSTCOMPILE and COMPILE.pre.
6667 * configure.ac: Invoke AC_CONFIG_COMMANDS.
6668 * configure: Re-generated.
6669 * configure.srv: Replace arch-i386.o with arch/i386.o.
6670 Replace arch-amd64.o with arch/amd64.o.
6671
5bfda255
YQ
66722017-10-16 Yao Qi <yao.qi@linaro.org>
6673
6674 * configure: Regenerated.
6675
9c80ecd6
SM
66762017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
6677
6678 * inferiors.h: (struct inferior_list): Remove.
6679 (struct inferior_list_entry); Remove.
6680 (add_inferior_to_list, clear_inferior_list, one_inferior_p,
6681 A_I_NEXT, ALL_INFERIORS_TYPE, ALL_INFERIORS, remove_inferior,
6682 get_first_inferior): Remove.
6683 (for_each_inferior, for_each_inferior_with_data, find_inferior,
6684 find_inferior_id, find_inferior_in_random): Change signature.
6685 * inferiors.c (all_threads): Change type to
6686 std::list<thread_info *>.
6687 (get_thread): Remove macro.
6688 (find_inferior, find_inferior_id): Change signature, implement
6689 using find_thread.
6690 (find_inferior_in_random): Change signature, implement using
6691 find_thread_in_random.
6692 (for_each_inferior, for_each_inferior_with_data): Change
6693 signature, implement using for_each_thread.
6694 (add_inferior_to_list, remove_inferior): Remove.
6695 (add_thread, get_first_thread, thread_of_pid,
6696 find_any_thread_of_pid, free_one_thread, remove_thread): Update.
6697 (get_first_inferior, one_inferior_p, clear_inferior_list):
6698 Remove.
6699 (clear_inferiors, get_thread_process): Update.
6700 * gdbthread.h: Include <list>.
6701 (struct thread_info) <entry>: Remove field.
6702 <id>: New field.
6703 (all_threads): Change type to std::list<thread_info *>.
6704 (get_first_inferior): Add doc.
6705 (find_thread, for_each_thread, find_thread_in_random): New
6706 functions.
6707 (current_ptid, pid_of, ptid_of, lwpid_of): Update.
6708 * linux-arm-low.c (update_registers_callback): Update.
6709 * linux-low.c (second_thread_of_pid_p): Update.
6710 (kill_one_lwp_callback, linux_detach_lwp_callback,
6711 delete_lwp_callback, status_pending_p_callback, same_lwp,
6712 find_lwp_pid, num_lwps, iterate_over_lwps_filter,
6713 iterate_over_lwps, not_stopped_callback,
6714 resume_stopped_resumed_lwps, count_events_callback,
6715 select_singlestep_lwp_callback, select_event_lwp_callback,
6716 unsuspend_one_lwp, linux_wait_1, send_sigstop_callback,
6717 suspend_and_send_sigstop_callback, wait_for_sigstop,
6718 stuck_in_jump_pad_callback, move_out_of_jump_pad_callback,
6719 lwp_running, linux_set_resume_request, resume_status_pending_p,
6720 need_step_over_p, start_step_over, linux_resume_one_thread,
6721 proceed_one_lwp, unsuspend_and_proceed_one_lwp,
6722 reset_lwp_ptrace_options_callback): Update.
6723 * linux-mips-low.c (update_watch_registers_callback): Update.
6724 * regcache.c (regcache_invalidate_one, regcache_invalidate):
6725 Update.
6726 (free_register_cache_thread_one): Remove.
6727 (regcache_release): Update.
6728 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt,
6729 handle_qxfer_threads_worker): Update.
6730 (handle_query): Update, use list iterator.
6731 (visit_actioned_threads, handle_pending_status,
6732 queue_stop_reply_callback, gdb_wants_all_threads_stopped,
6733 clear_pending_status_callback, set_pending_status_callback,
6734 find_status_pending_thread_callback, handle_status,
6735 process_serial_event): Update.
6736 * target.c (thread_search_callback): Update.
6737 * thread-db.c (thread_db_get_tls_address): Update.
6738 * tracepoint.c (tracepoint_finished_step, tracepoint_was_hit):
6739 Update.
6740 * win32-i386-low.c (update_debug_registers_callback): Update.
6741 * win32-low.c (delete_thread_info, child_delete_thread,
6742 continue_one_thread, suspend_one_thread,
6743 get_child_debug_event): Adjust.
6744
9179355e
SM
67452017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
6746
6747 * gdbthread.h (ptid_of, pid_of, lwpid_of): New functions.
6748 * inferiors.h: Include <list>.
6749 (struct process_info) <entry>: Remove field.
6750 <pid>: New field.
6751 (pid_of): Change macro to function.
6752 (ptid_of, lwpid_of): Remove macro.
6753 (all_processes): Change type to std::list<process_info *>.
6754 (ALL_PROCESSES): Remove macro.
6755 (for_each_process, find_process): New function.
6756 * inferiors.c (all_processes): Change type to
6757 std::list<process_info *>.
6758 (find_thread_process): Adjust.
6759 (add_process): Likewise.
6760 (remove_process): Likewise.
6761 (find_process_pid): Likewise.
6762 (get_first_process): Likewise.
6763 (started_inferior_callback): Remove.
6764 (have_started_inferiors_p): Adjust.
6765 (attached_inferior_callback): Remove.
6766 (have_attached_inferiors_p): Adjust.
6767 * linux-low.c (check_zombie_leaders): Likewise.
6768 * linux-x86-low.c (x86_arch_setup_process_callback): Remove.
6769 (x86_linux_update_xmltarget): Adjust.
6770 * server.c (handle_query): Likewise.
6771 (gdb_reattached_process): Remove.
6772 (handle_status): Adjust.
6773 (kill_inferior_callback): Likewise.
6774 (detach_or_kill_inferior): Remove.
6775 (print_started_pid): Likewise.
6776 (print_attached_pid): Likewise.
6777 (detach_or_kill_for_exit): Update.
6778 (process_serial_event): Likewise.
6779 * linux-arm-low.c (arm_new_fork): Likewise.
6780
c9cb8905
SM
67812017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
6782
6783 * dll.h: Include <list>.
6784 (struct dll_info): Add constructor.
6785 <entry>: Remove field.
6786 (all_dlls): Change type to std::list<dll_info>.
6787 * dll.c: Include <algorithm>.
6788 (get_dll): Remove macro.
6789 (all_dlls): Change type to std::list<dll_info *>.
6790 (free_one_dll): Remove.
6791 (match_dll): Likewise.
6792 (loaded_dll): Adjust.
6793 (unloaded_dll): Adjust to all_dlls type change, use
6794 std::find_if. Inline code from match_dll.
6795 (clear_dlls): Adjust to all_dlls type change.
6796 * server.c (emit_dll_description): Remove.
6797 (handle_qxfer_libraries): Adjust to all_dlls type change,
6798 integrate emit_dll_description's functionality.
6799
04ec7890
SM
68002017-10-12 Simon Marchi <simon.marchi@ericsson.com>
6801
6802 * linux-low.h (struct linux_target_ops) <delete_process>: New
6803 field.
6804 * linux-low.c (linux_mourn): Call the_low_target.delete_process.
6805 * linux-aarch64-low.c (aarch64_linux_delete_process): New.
6806 (struct linux_target_ops): Add delete_process callback.
6807 * linux-arm-low.c (arm_delete_process): New.
6808 (struct linux_target_ops): Add delete_process callback.
6809 * linux-bfin-low.c (struct linux_target_ops): Likewise.
6810 * linux-crisv32-low.c (struct linux_target_ops): Likewise.
6811 * linux-m32r-low.c (struct linux_target_ops): Likewise.
6812 * linux-mips-low.c (mips_linux_delete_process): New.
6813 (struct linux_target_ops): Add delete_process callback.
6814 * linux-ppc-low.c (struct linux_target_ops): Likewise.
6815 * linux-s390-low.c (struct linux_target_ops): Likewise.
6816 * linux-sh-low.c (struct linux_target_ops): Likewise.
6817 * linux-tic6x-low.c (struct linux_target_ops): Likewise.
6818 * linux-tile-low.c (struct linux_target_ops): Likewise.
6819 * linux-x86-low.c (x86_linux_delete_process): New.
6820 (struct linux_target_ops): Add delete_process callback.
6821 * linux-xtensa-low.c (struct linux_target_ops): Likewise.
6822
466eecee
SM
68232017-10-12 Simon Marchi <simon.marchi@ericsson.com>
6824
6825 * linux-aarch64-low.c (the_low_target): Add thread delete
6826 callback.
6827 * linux-arm-low.c (arm_delete_thread): New function.
6828 (the_low_target): Add thread delete callback.
6829 * linux-bfin-low.c (the_low_target): Likewise.
6830 * linux-crisv32-low.c (the_low_target): Likewise.
6831 * linux-low.c (delete_lwp): Invoke delete_thread callback if
6832 set.
6833 * linux-low.h (struct linux_target_ops) <delete_thread>: New
6834 field.
6835 * linux-m32r-low.c (the_low_target): Add thread delete callback.
6836 * linux-mips-low.c (mips_linux_delete_thread): New function.
6837 (the_low_target): Add thread delete callback.
6838 * linux-ppc-low.c (the_low_target): Likewise.
6839 * linux-s390-low.c (the_low_target): Likewise.
6840 * linux-sh-low.c (the_low_target): Likewise.
6841 * linux-tic6x-low.c (the_low_target): Likewise.
6842 * linux-tile-low.c (the_low_target): Likewise.
6843 * linux-x86-low.c (the_low_target): Likewise.
6844 * linux-xtensa-low.c (the_low_target): Likewise.
6845
b79f7801
YZ
68462017-10-06 Yuanhui Zhang <asmwarrior@gmail.com>
6847
6848 * win32-low.c: Include "common-inferior.h".
6849
bc3b087d
SDJ
68502017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
6851
6852 * inferiors.c (set_inferior_cwd): New function.
6853 * server.c (handle_general_set): Handle QSetWorkingDir packet.
6854 (handle_query): Inform that QSetWorkingDir is supported.
6855 * win32-low.c (create_process): Pass the inferior's cwd to
6856 CreateProcess.
6857
d092c5a2
SDJ
68582017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
6859
6860 * inferiors.c (current_inferior_cwd): New global variable.
6861 (get_inferior_cwd): New function.
6862 * inferiors.h (struct process_info) <cwd>: New field.
6863
7da0a886
SDJ
68642017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
6865
6866 * Makefile.in (SFILES): Add $(srcdir)/common/gdb_tilde_expand.c.
6867 (OBS): Add gdb_tilde_expand.o.
6868
289a6840
SM
68692017-10-02 Simon Marchi <simon.marchi@ericsson.com>
6870
6871 * lynx-i386-low.c (lynx_i386_arch_setup): Call init_target_desc.
6872 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
6873
256642e8
PA
68742017-09-29 Pedro Alves <palves@redhat.com>
6875
6876 * ax.c (gdb_parse_agent_expr): Constify.
6877 * ax.h (gdb_parse_agent_expr): Constify.
6878 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
6879 Constify.
6880 * mem-break.h (add_breakpoint_condition, add_breakpoint_commands): Constify.
6881 * remote-utils.c (hex_or_minus_one, read_ptid): Constify.
6882 * remote-utils.h (read_ptid): Constify.
6883 * server.c (handle_qxfer_exec_file, handle_query, handle_v_cont)
6884 (process_point_options, process_serial_event): Constify.
6885 * tracepoint.c (add_tracepoint_action, cmd_qtdp, cmd_qtdpsrc)
6886 (cmd_qtdv, cmd_qtenable_disable, cmd_qtro, cmd_qtframe, cmd_qtp)
6887 (cmd_qtbuffer): Constify.
6888
5b9ca4d4
PA
68892017-09-29 Pedro Alves <palves@redhat.com>
6890
6891 * proc-service.c (ps_pdread): Return PS_ERR if reading memory
6892 fails.
6893
94c207e0
PA
68942017-09-29 Pedro Alves <palves@redhat.com>
6895
6896 * linux-low.c (handle_extended_wait): Pass parent thread instead
6897 of process to thread_db_notice_clone.
6898 * linux-low.h (thread_db_notice_clone): Replace parent process
6899 parameter with parent thread parameter.
6900 * thread-db.c (find_one_thread): Add comment.
6901 (thread_db_notice_clone): Replace parent process parameter with
6902 parent thread parameter. Temporarily switch to the parent thread.
6903
75352e28
SDJ
69042017-09-26 Sergio Durigan Junior <sergiodj@redhat.com>
6905
6906 * gdbthread.h: Include "common-gdbthread.h".
6907 * inferiors.c (switch_to_thread): Use "gdb_assert" instead of
6908 "if" when validating the ptid.
6909 * remote-utils.c: Include "gdbthread.h".
6910 (prepare_resume_reply): Use "switch_to_thread".
6911 * target.c (done_accessing_memory): Likewise.
6912
ad339634
AA
69132017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
6914
6915 * configure.srv (s390*-*-linux*): Add s390-gs-linux64.o and
6916 s390x-gs-linux64.o to srv_regobj. Add s390-gs-linux64.xml,
6917 s390x-gs-linux64.xml, s390-gs.xml, and s390-gsbc.xml to
6918 srv_xmlfiles. Add s390-gs-linux64-ipa.o and
6919 s390x-gs-linux64-ipa.o to ipa_obj.
6920 * linux-s390-low.c (HWCAP_S390_GS): New define.
6921 (s390_fill_gs, s390_store_gs, s390_fill_gsbc, s390_store_gsbc):
6922 New functions.
6923 (s390_regsets): Add regsets for NT_S390_GS_CB and NT_S390_GS_BC.
6924 (s390_arch_setup): Check for guarded-storage support and choose
6925 appropriate tdesc.
6926 (initialize_low_arch): Invoke init_registers_s390_gs_linux64 and
6927 init_registers_s390x_gs_linux64.
6928 * linux-s390-tdesc.h (enum s390_linux_tdesc) <S390_TDESC_GS>: New
6929 enum value.
6930 (init_registers_s390x_gs_linux64, tdesc_s390x_gs_linux64)
6931 (init_registers_s390_gs_linux64, tdesc_s390_gs_linux64): Declare.
6932
cc4d742f
SM
69332017-09-22 Simon Marchi <simon.marchi@ericsson.com>
6934
6935 * win32-i386-low.c (i386_arch_setup): Call init_target_desc.
6936
f6327dcb
KB
69372017-09-21 Kevin Buettner <kevinb@redhat.com>
6938
6939 * linux-low.h (struct lwp_info): Add new field, thread_handle.
6940 (thread_db_thread_handle): Declare.
6941 * linux-low.c (linux_target_ops): Initialize thread_handle.
6942 * server.c (handle_qxfer_threads_worker): Add support for
6943 "handle" attribute.
6944 * target.h (struct target_ops): Add new function pointer,
6945 thread_handle.
6946 (target_thread_handle): Define.
6947 * thread-db.c (find_one_thread, attach_thread): Set thread_handle
6948 field in lwp.
6949 (thread_db_thread_handle): New function.
6950
86299109
KB
69512017-09-21 Kevin Buettner <kevinb@redhat.com>
6952
6953 * linux-low.c (handle_extended_wait): Call thread_db_notice_clone().
6954 * linux-low.h (thread_db_notice_clone): Declare.
6955 * thread-db.c (thread_db_notice_clone): New function.
6956
f557a88a
PA
69572017-09-21 Pedro Alves <palves@redhat.com>
6958
6959 * server.c (gdb_read_memory, handle_status, process_serial_event)
6960 (handle_serial_event, handle_target_event): Adjust to
6961 set_desired_thread prototype change.
6962 * target.c (set_desired_thread): Remove 'use_general' parameter
6963 and adjust.
6964 * target.h (set_desired_thread): Remove 'use_general' parameter.
6965
223ffa71
TT
69662017-09-20 Tom Tromey <tom@tromey.com>
6967
6968 * target.c (target_terminal::terminal_state): Define.
6969 (target_terminal::init): Rename from target_terminal_init.
6970 (target_terminal::inferior): Rename from
6971 target_terminal_inferior.
6972 (target_terminal::ours): Rename from target_terminal_ours.
6973 (target_terminal::ours_for_output, target_terminal::info): New.
6974
04fd3ba9
SM
69752017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6976
6977 * server.c (accumulate_file_name_length): Remove.
6978 (emit_dll_description): Adjust to std::string change.
6979 (handle_qxfer_libraries): Use std::string to hold document.
6980
5e187554
SM
69812017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6982
6983 * linux-low.c (linux_qxfer_libraries_svr4): Adjust to change of
6984 return type of xml_escape_text.
6985 * server.c (emit_dll_description): Likewise.
6986
1526853e
SM
69872017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6988
6989 * server.c (captured_main): Accept argument for --selftest.
6990 Update run_tests call.
6991 * linux-x86-tdesc-selftest.c (initialize_low_tdesc): Add names
6992 when registering selftests.
6993
c4dfafab
SDJ
69942017-09-16 Sergio Durigan Junior <sergiodj@redhat.com>
6995
6996 * regcache.c (get_thread_regcache): Update code to use "std::vector"
6997 instead of "VEC" for "target_desc.reg_defs".
6998 (regcache_cpy): Likewise.
6999 (registers_to_string): Likewise.
7000 (registers_from_string): Likewise.
7001 (find_regno): Likewise.
7002 (supply_regblock): Likewise.
7003 (regcache_raw_read_unsigned): Likewise.
7004 * tdesc.c (init_target_desc): Likewise.
7005 (tdesc_create_reg): Likewise.
7006 * tdesc.h: Remove declaration of "tdesc_reg_p". Include <vector>.
7007 (struct target_desc) <reg_defs>: Convert to "std::vector".
7008 (target_desc): Do not initialize "reg_defs".
7009 (~target_desc): Update code to use "std::vector" instead of "VEC"
7010 for "target_desc.reg_defs".
7011 (operator==): Likewise.
7012
124aceb4
SM
70132017-09-15 Simon Marchi <simon.marchi@ericsson.com>
7014
7015 * inferiors.h (thread_to_gdb_id): Remove.
7016 * inferiors.c (thread_to_gdb_id): Remove.
7017 * server.c (handle_qxfer_threads_worker, handle_query): Adjust.
7018 * lynx-low.c (lynx_resume, lynx_wait_1, lynx_fetch_registers,
7019 lynx_store_registers, lynx_read_memory, lynx_write_memory):
7020 Likewise.
7021 * nto-low.c (nto_fetch_registers, nto_store_registers,
7022 nto_stopped_by_watchpoint, nto_stopped_data_address): Likewise.
7023
96cde54f
SM
70242017-09-15 Simon Marchi <simon.marchi@ericsson.com>
7025
7026 * inferiors.h (gdb_id_to_thread_id): Remove.
7027 * inferiors.c (gdb_id_to_thread_id): Remove.
7028 * server.c (process_serial_event): Adjust to gdb_id_to_thread_id
7029 removal. Move pid declaration closer to where it's used.
7030
e8ca139e
SM
70312017-09-15 Simon Marchi <simon.marchi@ericsson.com>
7032
7033 * server.c (handle_detach): New function.
7034 (process_serial_event): Move code out, call handle_detach.
7035
f8a4e119
SM
70362017-09-15 Simon Marchi <simon.marchi@ericsson.com>
7037
7038 * server.c (require_running): Rename to ...
7039 (require_running_or_return): ... this ...
7040 (require_running_or_break): ... and this.
7041 (handle_query, process_serial_event): Adjust.
7042
0eb0a407
SM
70432017-09-15 Simon Marchi <simon.marchi@ericsson.com>
7044
7045 * linux-low.c (linux_set_resume_request): Remove unused
7046 variables.
7047
785922a5
SM
70482017-09-15 Simon Marchi <simon.marchi@ericsson.com>
7049
7050 * server.c (first_thread_of): Remove.
7051 (process_serial_event): Replace usage of first_thread_of with
7052 find_any_thread_of_pid.
7053 * tracepoint.c (same_process_p): Remove.
7054 (gdb_agent_about_to_close): Replace usage of same_process_p with
7055 find_any_thread_of_pid.
7056 * linux-x86-low.c (same_process_callback): Remove.
7057 (x86_arch_setup_process_callback): Replace usage of
7058 same_process_callback with find_any_thread_of_pid.
7059 * thread-db.c (any_thread_of): Remove.
7060 (switch_to_process): Replace usage of any_thread_of with
7061 find_any_thread_of_pid.
7062 * inferiors.c (thread_pid_matches_callback): Remove.
7063 (find_thread_process): Adjust to use find_any_thread_of_pid.
7064
a059f00c
SDJ
70652017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
7066
7067 * regcache.c (get_thread_regcache): Guard calls to "memset"
e79be6e5 7068 with "!VEC_empty".
a059f00c 7069
cc397f3a
SDJ
70702017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
7071
7072 * linux-low.c (handle_extended_wait): Use
7073 "allocate_target_description" instead of "XNEW".
7074 * linux-x86-low.c (initialize_low_arch): Likewise.
7075
22916b07
YQ
70762017-09-05 Yao Qi <yao.qi@linaro.org>
7077
7078 * configure.srv (srv_i386_regobj): Remove.
7079 (srv_amd64_regobj): Remove.
7080 (srv_regobj): Set it to "" for x86 non-linux targets.
7081 * linux-x86-tdesc.c (i386_linux_read_description):
7082 * lynx-i386-low.c: Include x86-xstate.h and arch/i386.h.
7083 (init_registers_i386): Remove the declaration.
7084 (tdesc_i386): Remove the declaration.
7085 (lynx_i386_arch_setup): Call i386_create_target_description.
7086 * nto-x86-low.c: Likewise.
7087 * win32-i386-low.c [__x86_64__]: include arch/amd64.h.
7088 [!__x86_64__]: include arch/i386.h.
7089 (i386_arch_setup) [__x86_64__]: Call amd64_create_target_description.
7090
38602d55
YQ
70912017-09-05 Yao Qi <yao.qi@linaro.org>
7092
7093 * configure.srv (srv_amd64_linux_xmlfiles): Remove
7094 i386/amd64-XXX-linux from it.
7095
44b886ff
YQ
70962017-09-05 Yao Qi <yao.qi@linaro.org>
7097
7098 * configure.srv: Empty srv_amd64_linux_regobj if $development is
7099 false.
7100 (ipa_amd64_linux_regobj): Remove.
7101 (ipa_x32_linux_regobj): Remove.
7102
b4570e4b
YQ
71032017-09-05 Yao Qi <yao.qi@linaro.org>
7104
7105 * Makefile.in (arch-amd64.o): New rule.
7106 * configure.srv: Append arch-amd64.o.
7107 * linux-amd64-ipa.c: Include common/x86-xstate.h.
7108 (get_ipa_tdesc): Call amd64_linux_read_description.
7109 (initialize_low_tracepoint): Don't call init_registers_x32_XXX
7110 and init_registers_amd64_XXX.
7111 * linux-x86-low.c (x86_linux_read_description): Call
7112 amd64_linux_read_description.
7113 (x86_get_ipa_tdesc_idx): Call amd64_get_ipa_tdesc_idx.
7114 (initialize_low_arch): Don't call init_registers_x32_XXX and
7115 init_registers_amd64_XXX.
7116 * linux-x86-tdesc-selftest.c: Declare init_registers_amd64_XXX
7117 and tdesc_amd64_XXX.
7118 [__x86_64__] (amd64_tdesc_test): New function.
7119 (initialize_low_tdesc) [__x86_64__]: Call init_registers_x32_XXX
7120 and init_registers_amd64_XXX.
7121 * linux-x86-tdesc.c: Include arch/amd64.h.
7122 (xcr0_to_tdesc_idx): New function.
7123 (i386_linux_read_description): New function.
7124 (amd64_get_ipa_tdesc_idx): New function.
7125 * linux-x86-tdesc.h (amd64_get_ipa_tdesc_idx): Declare.
7126 (amd64_get_ipa_tdesc): Declare.
7127
d1f28ea2
YQ
71282017-09-05 Yao Qi <yao.qi@linaro.org>
7129
7130 * configure.srv (srv_i386_linux_xmlfiles): Remove
7131 i386/i386-XXX-linux.xml from it.
7132
25a93583
YQ
71332017-09-05 Yao Qi <yao.qi@linaro.org>
7134
7135 * configure.srv: Set srv_i386_linux_regobj empty if $development
7136 is false.
7137 * linux-i386-ipa.c (initialize_low_tracepoint): Don't call
7138 initialize_low_tdesc.
7139 * linux-x86-low.c (initialize_low_arch): Wrap initialize_low_tdesc
7140 with #if initialize_low_tdesc.
7141 * linux-x86-tdesc-selftest.c: New file.
7142 * linux-x86-tdesc.c: Move code to linux-x86-tdesc-selftest.c.
7143
5f035c07
YQ
71442017-09-05 Yao Qi <yao.qi@linaro.org>
7145
7146 * Makefile.in (arch-i386.o): New rule.
7147 * configure.srv (i[34567]86-*-linux*): Add arch-i386.o.
7148 (x86_64-*-linux*): Likewise.
7149 * linux-x86-tdesc.c: Don't include ../features/i386/32bit-XXX.c,
7150 include arch/i386.h.
7151 (i386_linux_read_description): Remove code and call
7152 i386_create_target_description.
7153 * tdesc.c (allocate_target_description): New function.
7154 * tdesc.h (set_tdesc_architecture): Remove declaration.
7155 (set_tdesc_osabi): Likewise.
7156
0abe8a89
YQ
71572017-09-05 Yao Qi <yao.qi@linaro.org>
7158
7159 * linux-x86-tdesc.c: Don't include <inttypes.h>.
7160 (i386_linux_read_description) [!IN_PROCESS_AGENT]: Call
7161 set_tdesc_architecture and set_tdesc_osabi. Remove code setting
7162 .xmltarget.
7163 * server.c (get_features_xml): Call tdesc_get_features_xml.
7164 * tdesc.c (set_tdesc_architecture): New function.
7165 (set_tdesc_osabi): New function.
7166 (tdesc_get_features_xml): New function.
7167 (tdesc_create_feature): Add an argument.
7168 * tdesc.h (struct target_desc) <features>: New field.
7169 <arch, osabi>: New field.
7170 (~target_desc): xfree features, arch, and osabi.
7171 (target_desc::oerator==): Don't compare .xmltarget.
7172 [!IN_PROCESS_AGENT] (set_tdesc_architecture): Declare.
7173 (set_tdesc_osabi): Likewise.
7174 (tdesc_get_features_xml): Likewise.
7175
0a188386
YQ
71762017-09-05 Yao Qi <yao.qi@linaro.org>
7177
7178 * linux-x86-tdesc.c: Include selftest.h.
7179 (i386_tdesc_test): New function.
7180 (initialize_low_tdesc): Call selftests::register_test.
7181 * tdesc.h: Include regdef.h.
7182 (target_desc): Override operator == and !=.
7183
f49ff000
YQ
71842017-09-05 Yao Qi <yao.qi@linaro.org>
7185
7186 * configure.srv (srv_tgtobj): Append linux-x86-tdesc.o.
7187 (ipa_obj): Likewise.
7188 * linux-i386-ipa.c: Include common/x86-xstate.h
7189 (get_ipa_tdesc): Call i386_linux_read_description.
7190 (initialize_low_tracepoint): Don't call init_registers_XXX
7191 functions, call initialize_low_tdesc instead.
7192 * linux-x86-low.c (x86_linux_read_description): Call
7193 i386_linux_read_description.
7194 (initialize_low_arch): Don't call init_registers_i386_XXX
7195 functions, call initialize_low_tdesc.
7196 * linux-x86-tdesc.c: New file.
7197 * linux-x86-tdesc.h (x86_linux_tdesc): New X86_TDESC_LAST.
7198 (i386_get_ipa_tdesc_idx): Declare.
7199 (i386_get_ipa_tdesc): Declare.
7200 (initialize_low_tdesc): Declare.
7201
2b68ef2f
YQ
72022017-09-05 Yao Qi <yao.qi@linaro.org>
7203
7204 * linux-x86-low.c (x86_get_ipa_tdesc_idx): Use X86_TDESC_MMX
7205 instead of 0.
7206
f7000548
YQ
72072017-09-05 Yao Qi <yao.qi@linaro.org>
7208
7209 * Makefile.in (IPA_OBJS): Add vec-ipa.o
7210 * regcache.c (get_thread_regcache): Use VEC_length.
7211 (init_register_cache): Likewise.
7212 (regcache_cpy): Likewise.
7213 (registers_to_string): Iterate reg_defs via VEC_iterate.
7214 (find_regno): Likewise.
7215 (find_register_by_number): Use VEC_index.
7216 (register_size): Call find_register_by_number.
7217 (register_data): Call find_register_by_number.
7218 (supply_regblock): Use VEC_length.
7219 (regcache_raw_read_unsigned): Likewise.
7220 * tdesc.c (init_target_desc): Iterate reg_defs via
7221 VEC_iterate.
7222 (default_description): Update initializer.
7223 (copy_target_description): Don't update field num_registers.
7224 * tdesc.h (struct target_desc) <reg_defs>: Change it to VEC.
7225 <num_registers>: Remove.
7226
50a421ac
SM
72272017-09-04 Simon Marchi <simon.marchi@ericsson.com>
7228
7229 * Makefile.in (.SECONDARY): Define target.
7230
23fdd69e
SM
72312017-09-03 Simon Marchi <simon.marchi@ericsson.com>
7232
7233 * linux-low.c (linux_wait_1): Adjust.
7234 * server.c (queue_stop_reply_callback): Adjust.
7235
0a2dde4a
SDJ
72362017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
7237
7238 * server.c (handle_general_set): Handle QEnvironmentHexEncoded,
7239 QEnvironmentUnset and QEnvironmentReset packets.
7240 (handle_query): Inform remote that QEnvironmentHexEncoded,
7241 QEnvironmentUnset and QEnvironmentReset are supported.
7242
6afd337d
SM
72432017-08-25 Simon Marchi <simon.marchi@ericsson.com>
7244
7245 * inferiors.h (inferior_target_data): Rename to ...
7246 (thread_target_data): ... this.
7247 (inferior_regcache_data): Rename to ...
7248 (thread_regcache_data): ... this.
7249 (set_inferior_regcache_data): Rename to ...
7250 (set_thread_regcache_data): ... this.
7251 * inferiors.c (inferior_target_data): Rename to ...
7252 (thread_target_data): ... this.
7253 (inferior_regcache_data): Rename to ...
7254 (thread_regcache_data): ... this.
7255 (set_inferior_regcache_data): Rename to ...
7256 (set_thread_regcache_data): ... this.
7257 (free_one_thread): Update.
7258 * linux-low.h (get_thread_lwp): Update.
7259 * regcache.c (get_thread_regcache): Update.
7260 (regcache_invalidate_thread): Update.
7261 (free_register_cache_thread): Update.
7262 * win32-i386-low.c (update_debug_registers_callback): Update.
7263 (win32_get_current_dr): Update.
7264 * win32-low.c (thread_rec): Update.
7265 (delete_thread_info): Update.
7266 (continue_one_thread): Update.
7267 (suspend_one_thread): Update.
7268
a160cc46
SM
72692017-08-24 Simon Marchi <simon.marchi@ericsson.com>
7270
7271 * inferiors.c (set_inferior_target_data): Remove.
7272 * inferiors.h (set_inferior_target_data): Remove.
7273
6d580b63
YQ
72742017-08-18 Yao Qi <yao.qi@linaro.org>
7275
7276 * Makefile.in (OBS): Add selftest.o.
7277 * configure.ac: AC_DEFINE GDB_SELF_TEST if $development.
7278 * configure, config.in: Re-generated.
7279 * server.c: Include common/sefltest.h.
7280 (captured_main): Handle option --selftest.
7281
f5a29eb0
YQ
72822017-08-09 Yao Qi <yao.qi@linaro.org>
7283
7284 * configure.srv (srv_i386_regobj): Remove i386-avx.o,
7285 i386-avx-avx512.o, i386-avx-mpx-avx512-pku.o, i386-mpx.o,
7286 i386-avx-mpx.o and i386-mmx.o.
7287 (srv_amd64_regobj): Remove amd64-avx.o, amd64-avx-avx512.o,
7288 amd64-avx-mpx-avx512-pku.o, amd64-mpx.o and amd64-avx-mpx.o.
7289 (srv_i386_xmlfiles): Remove i386/i386-avx.xml,
7290 i386/i386-avx-avx512.xml, i386/i386-avx-mpx-avx512-pku.xml,
7291 i386/i386-mpx.xml, i386/i386-avx-mpx.xml and i386/i386-mmx.xml.
7292 (srv_amd64_xmlfile):i386/amd64-avx.xml, i386/amd64-avx-avx512.xml,
7293 i386/amd64-avx-mpx-avx512-pku.xml, i386/amd64-mpx.xml,
7294 i386/amd64-avx-mpx.xml.
7295
57757c2f
YQ
72962017-08-09 Yao Qi <yao.qi@linaro.org>
7297
7298 * configure.srv (srv_amd64_regobj): Remove x32.o, x32-avx.o
7299 and x32-avx-avx512.o.
7300 (srv_amd64_xmlfiles): Remove i386/x32.xml, i386/x32-avx.xml
7301 i386/x32-avx-avx512.xml.
7302
229d26fc
SM
73032017-07-26 Simon Marchi <simon.marchi@ericsson.com>
7304
7305 * tracepoint.h (enum class fast_tpoint_collect_result): New
7306 enumeration.
7307 (fast_tracepoint_collecting): Change return type to
7308 fast_tpoint_collect_result.
7309 * tracepoint.c (fast_tracepoint_collecting): Likewise.
7310 * linux-low.h: Include tracepoint.h.
7311 (struct lwp_info) <collecting_fast_tracepoint>: Change type to
7312 fast_tpoint_collect_result.
7313 * linux-low.c (handle_tracepoints): Adjust.
7314 (linux_fast_tracepoint_collecting): Change return type to
7315 fast_tpoint_collect_result.
7316 (maybe_move_out_of_jump_pad, linux_wait_for_event_filtered,
7317 linux_wait_1, stuck_in_jump_pad_callback,
7318 lwp_signal_can_be_delivered, linux_resume_one_lwp_throw,
7319 proceed_one_lwp): Adjust to type change.
7320
2e1e43e1
YQ
73212017-07-10 Yao Qi <yao.qi@linaro.org>
7322
7323 * linux-x86-low.c (x86_linux_read_description): Re-indent the code.
7324
adc764e7
YQ
73252017-06-29 Yao Qi <yao.qi@linaro.org>
7326
7327 * tdesc.h (struct target_desc) [IN_PROCESS_AGENT] <expedite_regs>:
7328 Remove.
7329 [IN_PROCESS_AGENT] <xmltarget>: Likewise.
7330
a206891a
SM
73312017-06-20 Simon Marchi <simon.marchi@ericsson.com>
7332
7333 * Makefile.in (IPA_OBJS): Sort and format one item per line.
7334
9a6c7d9c
SDJ
73352017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
7336
7337 * linux-low.c (linux_create_inferior): Adjust code to access the
7338 environment information via 'gdb_environ' class.
7339 * lynx-low.c (lynx_create_inferior): Likewise.
7340 * server.c (our_environ): Make it an instance of 'gdb_environ'.
7341 (get_environ): Return a pointer to 'our_environ'.
7342 (captured_main): Initialize 'our_environ'.
7343 * server.h (get_environ): Adjust prototype.
7344 * spu-low.c (spu_create_inferior): Adjust code to access the
7345 environment information via 'gdb_environ' class.
7346
ae3e2ccf
SM
73472017-06-17 Simon Marchi <simon.marchi@ericsson.com>
7348
7349 * linux-low.c (linux_read_memory, linux_write_memory): Remove
7350 usage of "register" keyword.
7351
3e019bdc
SM
73522017-06-17 Simon Marchi <simon.marchi@ericsson.com>
7353
7354 * configure: Re-generate.
7355
8465943a
SM
73562017-06-17 Simon Marchi <simon.marchi@ericsson.com>
7357
7358 * configure: Re-generate.
7359
cf0dd6f0
SM
73602017-06-17 Simon Marchi <simon.marchi@ericsson.com>
7361
7362 * Makefile.in (COMPILE.pre): Add "-x c++".
7363
9845682b
SDJ
73642017-06-09 Sergio Durigan Junior <sergiodj@redhat.com>
7365
7366 * fork-child.c: Conditionally include <signal.h>.
7367
aefd8b33
SDJ
73682017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
7369
7370 * server.c (handle_general_set): Handle new packet
7371 "QStartupWithShell".
7372 (handle_query): Add "QStartupWithShell" to the list of supported
7373 packets.
7374 (gdbserver_usage): Add help text explaining the
7375 new "--startup-with-shell" and "--no-startup-with-shell" CLI
7376 options.
7377 (captured_main): Recognize and act upon the presence of the new
7378 CLI options.
7379
2090129c
SDJ
73802017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
7381 Pedro Alves <palves@redhat.com>
7382
7383 * Makefile.in (SFILES): Add "nat/fork-inferior.o".
7384 * configure: Regenerate.
7385 * configure.srv (srv_linux_obj): Add "fork-child.o" and
7386 "fork-inferior.o".
7387 (i[34567]86-*-lynxos*): Likewise.
7388 (spu*-*-*): Likewise.
7389 * fork-child.c: New file.
7390 * linux-low.c: Include "common-inferior.h", "nat/fork-inferior.h"
7391 and "environ.h".
7392 (linux_ptrace_fun): New function.
7393 (linux_create_inferior): Adjust function prototype to reflect
7394 change on "target.h". Adjust function code to use
7395 "fork_inferior".
7396 (linux_request_interrupt): Delete "signal_pid".
7397 * lynx-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
7398 (lynx_ptrace_fun): New function.
7399 (lynx_create_inferior): Adjust function prototype to reflect
7400 change on "target.h". Adjust function code to use
7401 "fork_inferior".
7402 * nto-low.c (nto_create_inferior): Adjust function prototype and
7403 code to reflect change on "target.h". Update comments.
7404 * server.c: Include "common-inferior.h", "nat/fork-inferior.h",
7405 "common-terminal.h" and "environ.h".
7406 (terminal_fd): Moved to fork-child.c.
7407 (old_foreground_pgrp): Likewise.
7408 (restore_old_foreground_pgrp): Likewise.
7409 (last_status): Make it global.
7410 (last_ptid): Likewise.
7411 (our_environ): New variable.
7412 (startup_with_shell): Likewise.
7413 (program_name): Likewise.
7414 (program_argv): Rename to...
7415 (program_args): ...this.
7416 (wrapper_argv): New variable.
7417 (start_inferior): Delete function.
7418 (get_exec_wrapper): New function.
7419 (get_exec_file): Likewise.
7420 (get_environ): Likewise.
7421 (prefork_hook): Likewise.
7422 (post_fork_inferior): Likewise.
7423 (postfork_hook): Likewise.
7424 (postfork_child_hook): Likewise.
7425 (handle_v_run): Update code to deal with arguments coming from the
7426 remote host. Update calls from "start_inferior" to
7427 "create_inferior".
7428 (captured_main): Likewise. Initialize environment variable. Call
7429 "have_job_control".
7430 * server.h (post_fork_inferior): New prototype.
7431 (get_environ): Likewise.
7432 (last_status): Declare.
7433 (last_ptid): Likewise.
7434 (signal_pid): Likewise.
7435 * spu-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
7436 (spu_ptrace_fun): New function.
7437 (spu_create_inferior): Adjust function prototype to reflect change
7438 on "target.h". Adjust function code to use "fork_inferior".
7439 * target.c (target_terminal_init): New function.
7440 (target_terminal_inferior): Likewise.
7441 (target_terminal_ours): Likewise.
7442 * target.h: Include <vector>.
7443 (struct target_ops) <create_inferior>: Update prototype.
7444 (create_inferior): Update macro.
7445 * utils.c (gdb_flush_out_err): New function.
7446 * win32-low.c (win32_create_inferior): Adjust function prototype
7447 and code to reflect change on "target.h".
7448
043a4934
SDJ
74492017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
7450
7451 * inferiors.c (switch_to_thread): New function.
7452
15652511
SDJ
74532017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
7454
7455 * Makefile.in (SFILE): Add "common/job-control.c".
7456 (OBS): Add "job-control.o".
7457
21ea5acd
SDJ
74582017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
7459
7460 * Makefile: Remove "@host_makefile_frag@".
7461
e13cb306
PA
74622017-05-05 Pedro Alves <palves@redhat.com>
7463
7464 * configure: Regenerate.
7465
c94fee56
SDJ
74662017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
7467
7468 * configure: Regenerate.
7469
a0ff9e1a
SM
74702017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
7471
7472 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Adjust to
7473 software_single_step change of return type to
7474 std::vector<CORE_ADDR>.
7475 * linux-low.c (install_software_single_step_breakpoints):
7476 Likewise.
7477 * linux-low.h (install_software_single_step_breakpoints):
7478 Likewise.
7479
be628ab8
SDJ
74802017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
7481
7482 * remote-utils.c: Include "gdb_termios.h" instead of
7483 "terminal.h".
7484 * terminal.h: Delete file.
7485
7c5ded6a
SDJ
74862017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
7487
7488 * server.c: Include <vector>.
7489 <program_argv, wrapper_argv>: Convert to std::vector.
7490 (start_inferior): Rewrite function to use C++.
7491 (handle_v_run): Likewise. Update code that calculates the argv
7492 based on the vRun packet; use C++.
7493 (captured_main): Likewise.
7494
436252de
SM
74952017-04-06 Simon Marchi <simon.marchi@ericsson.com>
7496
7497 * server.c (handle_v_cont): Initialize thread_resume::thread
7498 with null_ptid.
7499
9bf2a700
PA
75002017-04-05 Pedro Alves <palves@redhat.com>
7501
7502 * configure: Regenerate.
7503
a121b7c1
PA
75042017-04-05 Pedro Alves <palves@redhat.com>
7505
7506 * gdbreplay.c (sync_error): Constify.
7507 * linux-x86-low.c (push_opcode): Constify.
7508
21c8a587
PA
75092017-04-05 Pedro Alves <palves@redhat.com>
7510
7511 * win32-low.c (get_child_debug_event)
7512 <CREATE_PROCESS_DEBUG_EVENT>: Don't report TARGET_WAITKIND_EXECD.
7513 Report TARGET_WAITKIND_SPURIOUS instead.
7514
fb32b4f7
PA
75152017-04-05 Pedro Alves <palves@redhat.com>
7516
e79be6e5
SM
7517 * remote-utils.c (remote_prepare, remote_open): Constify.
7518 * remote-utils.h (remote_prepare, remote_open): Constify.
7519 * server.c (captured_main): Constify 'port' handling.
fb32b4f7 7520
65dd1e59
SM
75212017-04-04 Simon Marchi <simon.marchi@ericsson.com>
7522
7523 * Makefile.in (clean): Clear .deps.
7524
8fa5b777
SM
75252017-03-31 Simon Marchi <simon.marchi@polymtl.ca>
7526
7527 * .gitignore: Remove generated files, replace with wildcard.
7528 * (clean): Replace removal of generated files with wildcard.
7529 (version.c): Replace with...
7530 (version-generated.c): ...this.
7531 (xml-builtin.c): Replace with...
7532 (xml-builtin-generated.c): ...this.
7533 (%-ipa.o: %-generated.c, %.o: %-generated.c): New rules.
7534 (%.c: *regformats*): Replace with...
7535 (%-generated.c: *regformats*): ...this.
7536
a12e714b
MF
75372017-03-27 Max Filippov <jcmvbkbc@gmail.com>
7538
7539 * linux-xtensa-low.c (regnum::R_THREADPTR): New enum member.
7540 (xtensa_fill_gregset): Call collect_register_by_name for
7541 threadptr register.
7542 (xtensa_store_gregset): Call supply_register_by_name for
7543 threadptr register.
7544
1a09b50a
MF
75452017-03-27 Max Filippov <jcmvbkbc@gmail.com>
7546
7547 * linux-xtensa-low.c (xtensa_fill_gregset): Call collect_register
7548 for all registers in a0_regnum..a0_regnum + C0_NREGS range.
7549 (xtensa_store_gregset): Call supply_register for all registers in
7550 a0_regnum..a0_regnum + C0_NREGS range.
7551
1a01e7c6
SM
75522017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7553
7554 * Makefile.in (%-ipa.o: %-ipa.c): New rule.
7555 (ax-ipa.o: ax.c): Remove.
7556 (linux-i386-ipa.o: linux-i386-ipa.c): Remove.
7557 (linux-amd64-ipa.o: linux-amd64-ipa.c): Remove.
7558 (linux-aarch64-ipa.o: linux-aarch64-ipa.c): Remove.
7559 (linux-s390-ipa.o: linux-s390-ipa.c): Remove.
7560 (linux-ppc-ipa.o: linux-ppc-ipa.c): Remove.
7561
36bc18a8
SM
75622017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7563
7564 * Makefile.in (%-ipa.o: ../common/%.c): New rule.
7565 (print-utils-ipa.o: ../common/print-utils.c): Remove.
7566 (rsp-low-ipa.o: ../common/rsp-low.c): Remove.
7567 (errors-ipa.o: ../common/errors.c): Remove.
7568 (format-ipa.o: ../common/format.c): Remove.
7569 (common-utils-ipa.o: ../common/common-utils.c): Remove.
7570
a8ebe3d5
SM
75712017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7572
7573 * Makefile.in (%-ipa.o: %.c): New rule.
7574 (tracepoint-ipa.o: tracepoint.c): Remove.
7575 (utils-ipa.o: utils.c): Remove.
7576 (remote-utils-ipa.o: remote-utils.c): Remove.
7577 (regcache-ipa.o: regcache.c): Remove.
7578 (i386-linux-ipa.o: i386-linux.c): Remove.
7579 (i386-mmx-linux-ipa.o: i386-mmx-linux.c): Remove.
7580 (i386-avx-linux-ipa.o: i386-avx-linux.c): Remove.
7581 (i386-mpx-linux-ipa.o: i386-mpx-linux.c): Remove.
7582 (i386-avx-mpx-linux-ipa.o: i386-avx-mpx-linux.c): Remove.
7583 (i386-avx-avx512-linux-ipa.o: i386-avx-avx512-linux.c): Remove.
7584 (i386-avx-mpx-avx512-pku-linux-ipa.o: i386-avx-mpx-avx512-pku-linux.c): Remove.
7585 (amd64-linux-ipa.o: amd64-linux.c): Remove.
7586 (amd64-avx-linux-ipa.o: amd64-avx-linux.c): Remove.
7587 (amd64-mpx-linux-ipa.o: amd64-mpx-linux.c): Remove.
7588 (amd64-avx-mpx-linux-ipa.o: amd64-avx-mpx-linux.c): Remove.
7589 (amd64-avx-avx512-linux-ipa.o: amd64-avx-avx512-linux.c): Remove.
7590 (amd64-avx-mpx-avx512-pku-linux-ipa.o: amd64-avx-mpx-avx512-pku-linux.c): Remove.
7591 (aarch64-ipa.o: aarch64.c): Remove.
7592 (s390-linux32-ipa.o: s390-linux32.c): Remove.
7593 (s390-linux32v1-ipa.o: s390-linux32v1.c): Remove.
7594 (s390-linux32v2-ipa.o: s390-linux32v2.c): Remove.
7595 (s390-linux64-ipa.o: s390-linux64.c): Remove.
7596 (s390-linux64v1-ipa.o: s390-linux64v1.c): Remove.
7597 (s390-linux64v2-ipa.o: s390-linux64v2.c): Remove.
7598 (s390-te-linux64-ipa.o: s390-te-linux64.c): Remove.
7599 (s390-vx-linux64-ipa.o: s390-vx-linux64.c): Remove.
7600 (s390-tevx-linux64-ipa.o: s390-tevx-linux64.c): Remove.
7601 (s390x-linux64-ipa.o: s390x-linux64.c): Remove.
7602 (s390x-linux64v1-ipa.o: s390x-linux64v1.c): Remove.
7603 (s390x-linux64v2-ipa.o: s390x-linux64v2.c): Remove.
7604 (s390x-te-linux64-ipa.o: s390x-te-linux64.c): Remove.
7605 (s390x-vx-linux64-ipa.o: s390x-vx-linux64.c): Remove.
7606 (s390x-tevx-linux64-ipa.o: s390x-tevx-linux64.c): Remove.
7607 (powerpc-32l-ipa.o: powerpc-32l.c): Remove.
7608 (powerpc-altivec32l-ipa.o: powerpc-altivec32l.c): Remove.
7609 (powerpc-cell32l-ipa.o: powerpc-cell32l.c): Remove.
7610 (powerpc-vsx32l-ipa.o: powerpc-vsx32l.c): Remove.
7611 (powerpc-isa205-32l-ipa.o: powerpc-isa205-32l.c): Remove.
7612 (powerpc-isa205-altivec32l-ipa.o: powerpc-isa205-altivec32l.c): Remove.
7613 (powerpc-isa205-vsx32l-ipa.o: powerpc-isa205-vsx32l.c): Remove.
7614 (powerpc-e500l-ipa.o: powerpc-e500l.c): Remove.
7615 (powerpc-64l-ipa.o: powerpc-64l.c): Remove.
7616 (powerpc-altivec64l-ipa.o: powerpc-altivec64l.c): Remove.
7617 (powerpc-cell64l-ipa.o: powerpc-cell64l.c): Remove.
7618 (powerpc-vsx64l-ipa.o: powerpc-vsx64l.c): Remove.
7619 (powerpc-isa205-64l-ipa.o: powerpc-isa205-64l.c): Remove.
7620 (powerpc-isa205-altivec64l-ipa.o: powerpc-isa205-altivec64l.c): Remove.
7621 (powerpc-isa205-vsx64l-ipa.o: powerpc-isa205-vsx64l.c): Remove.
7622 (tdesc-ipa.o: tdesc.c): Remove.
7623 (x32-linux-ipa.o: x32-linux.c): Remove.
7624 (x32-avx-linux-ipa.o: x32-avx-linux.c): Remove.
7625 (x32-avx512-linux-ipa.o: x32-avx512-linux.c): Remove.
7626
50cfacb7
SM
76272017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7628
7629 * Makefile.in (%.o: ../arch/%.c): New rule.
7630 (arm.o: ../arch/arm.c): Remove.
7631 (arm-linux.o: ../arch/arm-linux.c): Remove.
7632 (arm-get-next-pcs.o: ../arch/arm-get-next-pcs.c): Remove.
7633 (aarch64-insn.o: ../arch/aarch64-insn.c): Remove.
7634
c5a22423
SM
76352017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7636
7637 * Makefile.in (%.o: ../nat/%.c): New rule.
7638 (x86-dregs.o: ../nat/x86-dregs.c): Remove.
7639 (amd64-linux-siginfo.o: ../nat/amd64-linux-siginfo.c): Remove.
7640 (linux-btrace.o: ../nat/linux-btrace.c): Remove.
7641 (linux-osdata.o: ../nat/linux-osdata.c): Remove.
7642 (linux-procfs.o: ../nat/linux-procfs.c): Remove.
7643 (linux-ptrace.o: ../nat/linux-ptrace.c): Remove.
7644 (linux-waitpid.o: ../nat/linux-waitpid.c): Remove.
7645 (mips-linux-watch.o: ../nat/mips-linux-watch.c): Remove.
7646 (ppc-linux.o: ../nat/ppc-linux.c): Remove.
7647 (linux-personality.o: ../nat/linux-personality.c): Remove.
7648 (aarch64-linux-hw-point.o: ../nat/aarch64-linux-hw-point.c): Remove.
7649 (aarch64-linux.o: ../nat/aarch64-linux.c): Remove.
7650 (x86-linux.o: ../nat/x86-linux.c): Remove.
7651 (x86-linux-dregs.o: ../nat/x86-linux-dregs.c): Remove.
7652 (linux-namespaces.o: ../nat/linux-namespaces.c): Remove.
7653
6bda016b
SM
76542017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7655
7656 * Makefile.in (%.o: ../common/%.c): New rule.
7657 (signals.o: ../common/signals.c): Remove.
7658 (print-utils.o: ../common/print-utils.c): Remove.
7659 (rsp-low.o: ../common/rsp-low.c): Remove.
7660 (common-utils.o: ../common/common-utils.c): Remove.
7661 (posix-strerror.o: ../common/posix-strerror.c): Remove.
7662 (mingw-strerror.o: ../common/mingw-strerror.c): Remove.
7663 (vec.o: ../common/vec.c): Remove.
7664 (gdb_vecs.o: ../common/gdb_vecs.c): Remove.
7665 (xml-utils.o: ../common/xml-utils.c): Remove.
7666 (ptid.o: ../common/ptid.c): Remove.
7667 (buffer.o: ../common/buffer.c): Remove.
7668 (format.o: ../common/format.c): Remove.
7669 (filestuff.o: ../common/filestuff.c): Remove.
7670 (agent.o: ../common/agent.c): Remove.
7671 (errors.o: ../common/errors.c): Remove.
7672 (environ.o: ../common/environ.c): Remove.
7673 (common-debug.o: ../common/common-debug.c): Remove.
7674 (cleanups.o: ../common/cleanups.c): Remove.
7675 (common-exceptions.o: ../common/common-exceptions.c): Remove.
7676 (fileio.o: ../common/fileio.c): Remove.
7677 (common-regcache.o: ../common/common-regcache.c): Remove.
7678 (signals-state-save-restore.o: ../common/signals-state-save-restore.c): Remove.
7679 (new-op.o: ../common/new-op.c): Remove.
7680 (btrace-common.o: ../common/btrace-common.c): Remove.
7681
21122961
SM
76822017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7683
7684 * Makefile.in (%.o: ../target/%.c): New rule.
7685 (waitstatus.o: ../target/waitstatus.c): Remove.
7686
c362e621
SM
76872017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7688
7689 * Makefile.in
7690 (%.c: ../regformats/%.dat,
7691 (%.c: ../regformats/arm/%.dat,
7692 (%.c: ../regformats/i386/%.dat,
7693 (%.c: ../regformats/rs6000/%.dat): New rules.
7694 (aarch64.c): Remove.
7695 (reg-arm.c): Remove.
7696 (arm-with-iwmmxt.c): Remove.
7697 (arm-with-vfpv2.c): Remove.
7698 (arm-with-vfpv3.c): Remove.
7699 (arm-with-neon.c): Remove.
7700 (reg-bfin.c): Remove.
7701 (reg-cris.c): Remove.
7702 (reg-crisv32.c): Remove.
7703 (i386.c): Remove.
7704 (i386-linux.c): Remove.
7705 (i386-avx.c): Remove.
7706 (i386-avx-linux.c): Remove.
7707 (i386-avx-avx512.c): Remove.
7708 (i386-avx-avx512-linux.c): Remove.
7709 (i386-mpx.c): Remove.
7710 (i386-mpx-linux.c): Remove.
7711 (i386-avx-mpx-avx512-pku.c): Remove.
7712 (i386-avx-mpx-avx512-pku-linux.c): Remove.
7713 (i386-avx-mpx.c): Remove.
7714 (i386-avx-mpx-linux.c): Remove.
7715 (i386-mmx.c): Remove.
7716 (i386-mmx-linux.c): Remove.
7717 (reg-ia64.c): Remove.
7718 (reg-m32r.c): Remove.
7719 (reg-m68k.c): Remove.
7720 (reg-cf.c): Remove.
7721 (mips-linux.c): Remove.
7722 (mips-dsp-linux.c): Remove.
7723 (mips64-linux.c): Remove.
7724 (mips64-dsp-linux.c): Remove.
7725 (nios2-linux.c): Remove.
7726 (powerpc-32.c): Remove.
7727 (powerpc-32l.c): Remove.
7728 (powerpc-altivec32l.c): Remove.
7729 (powerpc-cell32l.c): Remove.
7730 (powerpc-vsx32l.c): Remove.
7731 (powerpc-isa205-32l.c): Remove.
7732 (powerpc-isa205-altivec32l.c): Remove.
7733 (powerpc-isa205-vsx32l.c): Remove.
7734 (powerpc-e500l.c): Remove.
7735 (powerpc-64l.c): Remove.
7736 (powerpc-altivec64l.c): Remove.
7737 (powerpc-cell64l.c): Remove.
7738 (powerpc-vsx64l.c): Remove.
7739 (powerpc-isa205-64l.c): Remove.
7740 (powerpc-isa205-altivec64l.c): Remove.
7741 (powerpc-isa205-vsx64l.c): Remove.
7742 (s390-linux32.c): Remove.
7743 (s390-linux32v1.c): Remove.
7744 (s390-linux32v2.c): Remove.
7745 (s390-linux64.c): Remove.
7746 (s390-linux64v1.c): Remove.
7747 (s390-linux64v2.c): Remove.
7748 (s390-te-linux64.c): Remove.
7749 (s390-vx-linux64.c): Remove.
7750 (s390-tevx-linux64.c): Remove.
7751 (s390x-linux64.c): Remove.
7752 (s390x-linux64v1.c): Remove.
7753 (s390x-linux64v2.c): Remove.
7754 (s390x-te-linux64.c): Remove.
7755 (s390x-vx-linux64.c): Remove.
7756 (s390x-tevx-linux64.c): Remove.
7757 (tic6x-c64xp-linux.c): Remove.
7758 (tic6x-c64x-linux.c): Remove.
7759 (tic6x-c62x-linux.c): Remove.
7760 (reg-sh.c): Remove.
7761 (reg-sparc64.c): Remove.
7762 (reg-spu.c): Remove.
7763 (amd64.c): Remove.
7764 (amd64-linux.c): Remove.
7765 (amd64-avx.c): Remove.
7766 (amd64-avx-linux.c): Remove.
7767 (amd64-avx-avx512.c): Remove.
7768 (amd64-avx-avx512-linux.c): Remove.
7769 (amd64-mpx.c): Remove.
7770 (amd64-mpx-linux.c): Remove.
7771 (amd64-avx-mpx-avx512-pku.c): Remove.
7772 (amd64-avx-mpx-avx512-pku-linux.c): Remove.
7773 (amd64-avx-mpx.c): Remove.
7774 (amd64-avx-mpx-linux.c): Remove.
7775 (x32.c): Remove.
7776 (x32-linux.c): Remove.
7777 (x32-avx.c): Remove.
7778 (x32-avx-linux.c): Remove.
7779 (x32-avx-avx512.c): Remove.
7780 (x32-avx-avx512-linux.c): Remove.
7781 (reg-xtensa.c): Remove.
7782 (reg-tilegx.c): Remove.
7783 (reg-tilegx32.c): Remove.
7784
1672e0d9
SDJ
77852017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
7786
7787 * Makefile.in (SFILES): Add "common/environ.c".
7788 (OBJS): Add "common/environ.h".
7789
239b6d10
WT
77902017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
7791
7792 * configure.ac: Check if the fs_base and gs_base members of
7793 `struct user_regs_struct' exist.
7794 * config.in: Regenerated.
7795 * configure: Likewise.
7796
694b382c
AT
77972017-01-09 Antoine Tremblay <antoine.tremblay@ericsson.com>
7798
7799 * linux-aarch32-low.c (arm_breakpoint_kind_from_pc): Use
7800 target_read_memory.
7801 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer): Likewise.
7802 (get_next_pcs_syscall_next_pc): Likewise.
7803
7dc53023
LM
78042016-12-23 Luis Machado <lgustavo@codesourcery.com>
7805
7806 * win32-i386-low.c: Fix incorrect reference to a couple source files.
7807 * nto-x86-low.c: Likewise.
7808
ad02e4fe
SM
78092016-11-30 Simon Marchi <simon.marchi@polymtl.ca>
7810
7811 * Makefile.in: Include disable-implicit-rules.mk.
7812
dcb07cfa
PA
78132016-11-23 Pedro Alves <palves@redhat.com>
7814
7815 * debug.c: Include <chrono> instead of "gdb_sys_time.h".
7816 (debug_vprintf): Use std::chrono::steady_clock instead of
7817 gettimeofday. Use '.' instead of ':'.
7818 * tracepoint.c: Include <chrono> instead of "gdb_sys_time.h".
7819 (get_timestamp): Use std::chrono::steady_clock instead of
7820 gettimeofday.
7821
8629c02c
SM
78222016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
7823
7824 * Makefile.in: Fix whitespace formatting.
7825
b593ecca
SM
78262016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
7827
7828 * Makefile.in (SFILES, OBS): Flatten list and order
7829 alphabetically.
7830
9986ba08
PA
78312016-11-23 Pedro Alves <palves@redhat.com>
7832
7833 * event-loop.c (handle_file_event): Use warning.
7834 * linux-low.c (linux_resume_one_lwp_throw): Use warning.
7835 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
7836 Use warning.
7837
4eefa7bc
PA
78382016-11-23 Pedro Alves <palves@redhat.com>
7839
7840 * linux-low.c (check_zombie_leaders): Use debug_printf for debug
7841 output.
7842 * notif.c (handle_notif_ack, notif_event_enque): Likewise.
7843 * remote-utils.c (putpkt_binary_1, readchar, getpkt): Use
7844 debug_printf and debug_flush for debug output.
7845 * server.c (handle_general_set): Likewise.
7846 * thread-db.c (try_thread_db_load): Use debug_printf for debug
7847 output.
7848
5443506e
SM
78492016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
7850
7851 * Makefile.in (.c.o): Replace rule with ...
7852 (%.o: %.c): ... this one.
7853
3b165252
SM
78542016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
7855
7856 * Makefile.in: Remove @GMAKE_TRUE@ prefixes and removes lines
7857 prefixed with @GMAKE_FALSE@. Update comment related to non-GNU
7858 make.
7859 * configure.ac: Remove checks for the make program.
7860 * configure: Re-generate.
7861
0bcda685
PA
78622016-10-28 Pedro Alves <palves@redhat.com>
7863
7864 * Makefile.in (CXX_DIALECT): Get from configure.
7865 (COMPILE.pre, CC_LD): Append $(CXX_DIALECT).
7866 * acinclude.m4: Include ../ax_cxx_compile_stdcxx.m4.
7867 * configure.ac: Call AX_CXX_COMPILE_STDCXX.
7868 * config.in: Regenerate.
7869 * configure: Regenerate.
7870
c3805894
YQ
78712016-10-27 Yao Qi <yao.qi@linaro.org>
7872
7873 * linux-low.c (linux_supports_range_stepping): Return true if
7874 can_software_single_step return true.
7875
89342618
YQ
78762016-10-27 Yao Qi <yao.qi@linaro.org>
7877
7878 * inferiors.c (find_inferior_in_random): New function.
7879 * inferiors.h (find_inferior_in_random): Declare.
7880 * linux-low.c (linux_wait_for_event_filtered): Call
7881 find_inferior_in_random instead of find_inferior.
7882
e3652c84
YQ
78832016-10-27 Yao Qi <yao.qi@linaro.org>
7884
7885 * linux-low.c (linux_wait_1): If single-step breakpoints are
7886 inserted, remove them.
7887
5a04c4cf
PA
78882016-10-26 Pedro Alves <palves@redhat.com>
7889
7890 * linux-low.c (handle_extended_wait): Link parent/child fork
7891 threads.
7892 (linux_wait_1): Unlink them.
7893 (linux_set_resume_request): Ignore resume requests for
7894 already-resumed and unhandled fork child threads.
7895 * linux-low.h (struct lwp_info) <fork_relative>: New field.
7896 * server.c (in_queued_stop_replies_ptid, in_queued_stop_replies):
7897 New functions.
7898 (handle_v_requests) <vCont>: Don't call require_running.
7899 * server.h (in_queued_stop_replies): New declaration.
7900
cb93dc7f
YQ
79012016-10-24 Yao Qi <yao.qi@linaro.org>
7902
7903 PR server/20733
7904 * linux-aarch64-low.c (append_insns): Cast the return value to
7905 'uint32_t *'.
7906
a1078bea
YQ
79072016-10-10 Yao Qi <yao.qi@linaro.org>
7908
7909 * linux-aarch32-low.c (enum arm_breakpoint_kinds): Remove.
7910
1fb77080
SDJ
79112016-10-06 Sergio Durigan Junior <sergiodj@redhat.com>
7912
7913 * target.c (target_supports_multi_process): New function, moved
7914 from...
7915 * target.h (target_supports_multi_process): ... here. Remove
7916 macro.
7917
39b5a3b9
TT
79182016-10-05 Tom Tromey <tom@tromey.com>
7919
7920 PR remote/20655:
7921 * tracepoint.c (handle_tracepoint_bkpts): Check
7922 ipa_error_tracepoint, not ipa_stopping_tracepoint.
7923
c1d0b70a
YQ
79242016-10-05 Yao Qi <yao.qi@linaro.org>
7925
7926 * configure.srv: Update the path of arm-*.xml files.
7927
0a69eedb
YQ
79282016-10-05 Terry Guo <terry.guo@arm.com>
7929 Yao Qi <yao.qi@linaro.org>
7930
7931 * Makefile.in: Adjust the path of rules.
7932 * configure.srv: Update the path of xml files.
7933 * regformats/arm-with-iwmmxt.dat: Regenerated.
7934 * regformats/arm-with-neon.dat: Likewise.
7935 * regformats/arm-with-vfpv2.dat: Likewise.
7936 * regformats/arm-with-vfpv3.dat Likewise.
7937
17e16485
YQ
79382016-09-30 Yao Qi <yao.qi@linaro.org>
7939
7940 PR gdbserver/20627
7941 * target.c (target_stop_and_wait): Don't call
7942 target_continue_no_signal, use resume_stop instead.
7943
edeeb602
YQ
79442016-09-26 Yao Qi <yao.qi@linaro.org>
7945
7946 * linux-low.c (linux_wait_1): Call debug_exit.
7947
503b1c39
PA
79482016-09-23 Pedro Alves <palves@redhat.com>
7949
7950 * Makefile.in (SFILES): Add common/new-op.c.
7951 (OBS): Add common/new-op.o.
7952 (new-op.o): New rule.
7953
74172ecf
SM
79542016-09-21 Simon Marchi <simon.marchi@ericsson.com>
7955
7956 * .gitinore: Ignore more files.
7957
fc6cda2e
YQ
79582016-09-21 Yao Qi <yao.qi@linaro.org>
7959
7960 * linux-aarch32-low.c (arm_fill_gregset): Keep bits 20 to
7961 23.
7962
bc1e6c81
SDJ
79632016-09-19 Sergio Durigan Junior <sergiodj@redhat.com>
7964
7965 * server.c (start_inferior): Call target_mourn_inferior instead of
7966 mourn_inferior; pass ptid_t argument to it.
7967 (resume): Likewise.
7968 (handle_target_event): Likewise.
7969 * target.c (target_mourn_inferior): New function.
7970 * target.h (mourn_inferior): Delete macro.
7971
0e00e962
AA
79722016-09-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
7973
7974 * linux-low.c (lwp_is_stepping): New function.
7975
1d8cb77d
CL
79762016-09-06 Carl Love <cel@us.ibm.com>
7977
7978 * server.c (start_inferior): Fixed comment, requested comment change
7979 didn't get updated correctly. Removed reference to ptrace () call as
7980 it is only true on Linux systems.
7981
7313bced
CL
79822016-09-06 Carl Love <cel@us.ibm.com>
7983
7984 * server.c (start_inferior): Do not call
7985 function target_post_create_inferior () if the
7986 inferior process has already exited.
7987
cf6de44d
PA
79882016-09-05 Pedro Alves <palves@redhat.com>
7989
7990 * Makefile.in (COMPILER, COMPILER_CFLAGS): Remove.
7991 (COMPILE.pre, CC_LD): Use CXX directly.
7992 (INTERNAL_CFLAGS_BASE): Use CXXFLAGS directly.
7993 * acinclude.m4: Don't include build-with-cxx.m4.
7994 * configure.ac: Remove GDB_AC_BUILD_WITH_CXX call.
7995 * configure: Regenerate.
7996
c1da6748
AT
79972016-09-02 Akash Trehan <akash.trehan123@gmail.com>
7998
7999 PR gdb/19495
8000 * remote-utils.c (relocate_instruction): Remove redundant strcpy()
8001 call writing data to own_buf.
8002
f2b9e3df
SDJ
80032016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
8004
8005 * target.c (mywait): Call target_wait instead of
8006 the_target->wait.
8007 (target_wait): New function.
8008
049a8570
SDJ
80092016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
8010
8011 * server.c (start_inferior): New variable 'ptid'. Replace calls
8012 to the_target->resume by target_continue{,_no_signal}, depending
8013 on the case.
8014 * target.c (target_stop_and_wait): Call target_continue_no_signal
8015 instead of the_target->resume.
8016 (target_continue): New function.
8017
3aa5cfa0
AT
80182016-08-31 Antoine Tremblay <antoine.tremblay@ericsson.com>
8019
8020 * linux-low.c (linux_wait_1): Move event switch after unsuspend_lwps.
8021
754653a7
AZ
80222016-08-25 Adhemerval Zanella <adhemerval.zanella@linaro.org>
8023
8024 PR server/20491
8025 * gdb_proc_service.h (ps_get_thread_area): Remove const from struct
8026 ps_prochandle.
8027 * linux-aarch64-low.c (ps_get_thread_area): Likewise.
8028 * linux-arm-low.c (ps_get_thread_area): Likewise.
8029 * linux-crisv32-low.c (ps_get_thread_area): Likewise.
8030 * linux-m68k-low.c (ps_get_thread_area): Likewise.
8031 * linux-mips-low.c (ps_get_thread_area): Likewise.
8032 * linux-nios2-low.c (ps_get_thread_area): Likewise.
8033 * linux-tic6x-low.c (ps_get_thread_area): Likewise.
8034 * linux-x86-low.c (ps_get_thread_area): Likewise.
8035 * linux-xtensa-low.c (ps_get_thread_area): Likewise.
8036
ed036b40
PA
80372016-08-19 Pedro Alves <palves@redhat.com>
8038
8039 * linux-x86-low.c (amd64_emit_call): Emit missing call opcode.
8040
c8ef42ee
PA
80412016-08-19 Pedro Alves <palves@redhat.com>
8042
8043 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Fix
8044 comment. Use memcpy instead of casting through unsigned long.
8045
9c235a72
PA
80462016-08-19 Pedro Alves <palves@redhat.com>
8047
8048 * linux-amd64-ipa.c (alloc_jump_pad_buffer) [__ILP32__]: Try
8049 allocating around 0x80000000.
8050
201506da
PA
80512016-08-19 Pedro Alves <palves@redhat.com>
8052
8053 PR gdb/20415
8054 * Makefile.in (x32-linux-ipa.o, x32-avx-linux-ipa.o)
8055 (x32-avx512-linux-ipa.o): New rules.
8056 * configure.ac (x86_64-*-linux*): New x32 check.
8057 * configure.srv (ipa_x32_linux_regobj): New.
8058 (x86_64-*-linux*): Use $ipa_x32_linux_regobj if building for x32.
8059 * linux-amd64-ipa.c (get_ipa_tdesc) [__ILP32__]: Return x32
8060 descriptions.
8061 (initialize_low_tracepoint) [__ILP32__]: Initialize x32
8062 descriptions.
8063 * configure: Regenerate.
8064
f348d89a
PA
80652016-08-09 Pedro Alves <palves@redhat.com>
8066
8067 PR gdb/18653
8068 * Makefile.in (OBS): Add signals-state-save-restore.o.
8069 (signals-state-save-restore.o): New rule.
8070 * config.in: Regenerate.
8071 * configure: Regenerate.
8072 * linux-low.c: Include "signals-state-save-restore.h".
8073 (linux_create_inferior): Call
8074 restore_original_signals_state.
8075 * server.c: Include "dispositions-save-restore.h".
8076 (captured_main): Call save_original_signals_state.
8077
1baf5149
PA
80782016-08-05 Pedro Alves <palves@redhat.com>
8079
8080 * configure: Regenerate.
8081
fcd4a73d
YQ
80822016-08-04 Yao Qi <yao.qi@linaro.org>
8083
8084 * linux-low.c (regsets_fetch_inferior_registers): Check
8085 errno is ESRCH or not.
8086
979659d0
YQ
80872016-08-02 Yao Qi <yao.qi@linaro.org>
8088
8089 * thread-db.c (struct thread_db) <td_ta_event_getmsg_p>: Remove.
8090 <td_ta_set_event_p, td_ta_event_addr_p>: Remove.
8091 (thread_db_load_search): Update.
8092 (try_thread_db_load_1): Don't look for td_ta_event_addr,
8093 td_ta_set_event and td_ta_event_getmsg.
8094
6598661d
PA
80952016-07-26 Pedro Alves <palves@redhat.com>
8096
8097 PR server/20414
8098 * linux-x86-low.c (x86_get_pc, x86_set_pc): Use uint64_t instead
8099 of unsigned long for 64-bit registers and use uint32_t instead of
8100 unsigned int for 32-bit registers.
8101
9cf12d57
PA
81022016-07-26 Pedro Alves <palves@redhat.com>
8103
8104 * linux-x86-low.c (x86_siginfo_fixup): Rename 'native' parameter
8105 to 'ptrace'.
8106
305450ed
TT
81072016-07-21 Tom Tromey <tom@tromey.com>
8108
8109 * configure: Rebuild.
8110
2583da7c
YQ
81112016-07-21 Yao Qi <yao.qi@linaro.org>
8112
8113 * mem-break.c (find_gdb_breakpoint): Cast bp to
8114 'struct gdb_breakpoint *' rather than 'gdb_breakpoint *'.
8115
21536b36
YQ
81162016-07-21 Yao Qi <yao.qi@linaro.org>
8117
8118 * server.c (handle_v_requests): Support s and S actions
8119 if target_supports_software_single_step return true.
8120
8901d193
YQ
81212016-07-21 Yao Qi <yao.qi@linaro.org>
8122
8123 * linux-low.c (resume_stopped_resumed_lwps): If resume request
8124 is resume_step, call maybe_hw_step.
8125 (linux_wait_1): Stop all threads, remove reinsert breakpoints,
8126 and unstop them.
8127 (linux_resume_one_lwp_throw): Don't assert the thread has reinsert
8128 breakpoints or not.
8129 (proceed_one_lwp): If resume request is resume_step, install
8130 reinsert breakpoints and call maybe_hw_step.
8131
0e9a339e
YQ
81322016-07-21 Yao Qi <yao.qi@linaro.org>
8133
8134 * linux-low.c (proceed_one_lwp): Declare.
8135 (linux_resume_one_thread): Remove local variable 'step'.
8136 Lift code enqueue signal. Call proceed_one_lwp instead of
8137 linux_resume_one_lwp.
8138
4281b351
YQ
81392016-07-21 Yao Qi <yao.qi@linaro.org>
8140
8141 * linux-low.c (linux_resume_one_thread): Call
8142 enqueue_pending_signal.
8143
984a2c04
YQ
81442016-07-21 Yao Qi <yao.qi@linaro.org>
8145
8146 * gdbthread.h (make_cleanup_restore_current_thread): Declare.
8147 * inferiors.c (do_restore_current_thread_cleanup): New function.
8148 (make_cleanup_restore_current_thread): Likewise.
8149 * linux-low.c (install_software_single_step_breakpoints): Call
8150 make_cleanup_restore_current_thread. Switch current_thread to
8151 thread.
8152
bec903c9
YQ
81532016-07-21 Yao Qi <yao.qi@linaro.org>
8154
8155 * mem-break.c (struct reinsert_breakpoint) <ptid>: New field.
8156 (set_reinsert_breakpoint): New parameter ptid. Callers updated.
8157 (clone_one_breakpoint): Likewise.
8158 (delete_reinsert_breakpoints): Change parameter to thread.
8159 Callers updated.
8160 (has_reinsert_breakpoints): Likewise.
8161 (uninsert_reinsert_breakpoints): Likewise.
8162 (reinsert_reinsert_breakpoints): Likewise.
8163 * mem-break.h (set_reinsert_breakpoint): Update declaration.
8164 (delete_reinsert_breakpoints): Likewise.
8165 (reinsert_reinsert_breakpoints): Likewise.
8166 (uninsert_reinsert_breakpoints): Likewise.
8167 (has_reinsert_breakpoints): Likewise.
8168
63c40ec7
YQ
81692016-07-21 Yao Qi <yao.qi@linaro.org>
8170
8171 * inferiors.c (get_thread_process): Make parameter const.
8172 * inferiors.h (get_thread_process): Update declaration.
8173 * mem-break.c (clone_all_breakpoints): Remove all parameters.
8174 Add new parameters child_thread and parent_thread. Callers
8175 updated.
8176 * mem-break.h (clone_all_breakpoints): Update declaration.
8177
9aa76cd0
YQ
81782016-07-21 Yao Qi <yao.qi@linaro.org>
8179
8180 * mem-break.c (struct breakpoint) <cond_list>: Remove.
8181 <command_list, handler>: Remove.
8182 (struct gdb_breakpoint): New.
8183 (struct other_breakpoint): New.
8184 (struct reinsert_breakpoint): New.
8185 (is_gdb_breakpoint): New function.
8186 (any_persistent_commands): Update command_list if
8187 is_gdb_breakpoint returns true.
8188 (set_breakpoint): Create breakpoints according to their types.
8189 (find_gdb_breakpoint): Return 'struct gdb_breakpoint *'.
8190 (set_gdb_breakpoint_1): Likewise.
8191 (set_gdb_breakpoint): Likewise.
8192 (clear_breakpoint_conditions): Change parameter type to
8193 'struct gdb_breakpoint *'.
8194 (clear_breakpoint_commands): Likewise.
8195 (clear_breakpoint_conditions_and_commands): Likewise.
8196 (add_condition_to_breakpoint): Likewise.
8197 (add_breakpoint_condition): Likewise.
8198 (add_commands_to_breakpoint): Likewise.
8199 (check_breakpoints): Check other_breakpoint.
8200 (clone_one_breakpoint): Clone breakpopint according to its type.
8201 * mem-break.h (struct gdb_breakpoint): Declare.
8202 (set_gdb_breakpoint): Update declaration.
8203 (clear_breakpoint_conditions_and_commands): Likewise.
8204 (add_breakpoint_condition): Likewise.
8205 (add_breakpoint_commands): Likewise.
8206 * server.c (process_point_options): Change parameter type to
8207 'struct gdb_breakpoint *'.
8208
811f8301
YQ
82092016-07-21 Yao Qi <yao.qi@linaro.org>
8210
8211 * mem-break.c (set_breakpoint_at): Rename it to ...
8212 (set_breakpoint_type_at): ... it.
8213 (set_breakpoint_at): Call set_breakpoint_type_at.
8214 (set_reinsert_breakpoint): Call set_breakpoint_type_at.
8215 * mem-break.h (set_breakpoint_at): Update comments.
8216
b1c51e36
CLT
82172016-07-12 Chung-Lin Tang <cltang@codesourcery.com>
8218
8219 * linux-nios2-low.c (nios2_fill_gregset): Add type cast
8220 to buf parameter.
8221 (nios2_store_gregset): Likewise.
8222
ced2dffb
PA
82232016-07-01 Pedro Alves <palves@redhat.com>
8224 Antoine Tremblay <antoine.tremblay@ericsson.com>
8225
8226 * linux-low.c: Change interface to take the target lwp_info
8227 pointer directly and return void. Handle detaching from a zombie
8228 thread.
8229 (linux_detach_lwp_callback): New function.
8230 (linux_detach): Detach from the leader thread after detaching from
8231 the clone threads.
8232
2ac09a5b
YQ
82332016-06-28 Yao Qi <yao.qi@linaro.org>
8234
8235 * linux-aarch64-low.c (aarch64_ftrace_insn_reloc_b): Use int64_t
8236 for variable new_offset.
8237 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
8238 (aarch64_ftrace_insn_reloc_cb): Likewise.
8239 (aarch64_ftrace_insn_reloc_tb): Likewise.
8240 (aarch64_install_fast_tracepoint_jump_pad): Likewise. Use
8241 PRIx64 instead of PRIx32.
8242
79e7fd4f
YQ
82432016-06-28 Yao Qi <yao.qi@linaro.org>
8244
8245 * linux-arm-low.c (arm_get_syscall_trapinfo): New function.
8246 (the_low_target): Install arm_get_syscall_trapinfo.
8247
061fc021
YQ
82482016-06-28 Yao Qi <yao.qi@linaro.org>
8249
8250 * linux-aarch64-low.c (aarch64_get_syscall_trapinfo): New
8251 function.
8252 (the_low_target): Install aarch64_get_syscall_trapinfo.
8253
4cc32bec
YQ
82542016-06-28 Yao Qi <yao.qi@linaro.org>
8255
8256 * linux-low.c (get_syscall_trapinfo): Remove parameter sysret.
8257 Callers updated.
8258 * linux-low.h (struct linux_target_ops) <get_syscall_trapinfo>:
8259 Remove parameter sysno.
8260 * linux-x86-low.c (x86_get_syscall_trapinfo): Remove parameter
8261 sysret.
8262
782c1122
AA
82632016-06-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
8264
8265 * linux-s390-low.c (s390_emit_eq_goto): Mark function static.
8266 (s390_emit_ne_goto): Likewise.
8267 (s390_emit_lt_goto): Likewise.
8268 (s390_emit_le_goto): Likewise.
8269 (s390_emit_gt_goto): Likewise.
8270 (s390_emit_ge_goto): Likewise.
8271 (s390x_emit_eq_goto): Likewise.
8272 (s390x_emit_ne_goto): Likewise.
8273 (s390x_emit_lt_goto): Likewise.
8274 (s390x_emit_le_goto): Likewise.
8275 (s390x_emit_gt_goto): Likewise.
8276 (s390x_emit_ge_goto): Likewise.
8277 (s390_emit_ops_impl): Mark variable static.
8278 (s390x_emit_ops): Likewise.
8279
2e7b624b
YQ
82802016-06-17 Yao Qi <yao.qi@linaro.org>
8281
8282 * linux-low.c (handle_extended_wait): Call
8283 uninsert_reinsert_breakpoints for the parent process. Remove
8284 reinsert breakpoints from the child process. Reinsert them to
8285 the parent process when vfork is done.
8286 * mem-break.c (uninsert_reinsert_breakpoints): New function.
8287 (reinsert_reinsert_breakpoints): New function.
8288 * mem-break.h (uninsert_reinsert_breakpoints): Declare
8289 (reinsert_reinsert_breakpoints): Declare.
8290
8a81c5d7
YQ
82912016-06-17 Yao Qi <yao.qi@linaro.org>
8292
8293 * linux-low.c (handle_extended_wait): If the parent is doing
8294 step-over, remove the reinsert breakpoints from the forked child.
8295
f50bf8e5
YQ
82962016-06-17 Yao Qi <yao.qi@linaro.org>
8297
8298 * linux-low.c (unsuspend_all_lwps): Declare.
8299 (linux_low_filter_event): If thread exited, call finish_step_over.
8300 If step-over is finished, unsuspend other threads.
8301
8376a3cb
YQ
83022016-06-17 Yao Qi <yao.qi@linaro.org>
8303
8304 * linux-low.c (linux_resume_one_lwp_throw): Assert
8305 has_reinsert_breakpoints returns false.
8306 * mem-break.c (delete_disabled_breakpoints): Assert
8307 bp type isn't reinsert_breakpoint.
8308
f79b145d
YQ
83092016-06-17 Yao Qi <yao.qi@linaro.org>
8310
8311 * linux-low.c (maybe_hw_step): New function.
8312 (linux_resume_one_lwp_throw): Call maybe_hw_step.
8313 (finish_step_over): Switch current_thread to lwp temporarily,
8314 and assert has_reinsert_breakpoints returns true.
8315 (proceed_one_lwp): Call maybe_hw_step.
8316 * mem-break.c (has_reinsert_breakpoints): New function.
8317 * mem-break.h (has_reinsert_breakpoints): Declare.
8318
0ae534d2
JT
83192016-06-02 Jon Turney <jon.turney@dronecode.org.uk>
8320
8321 * win32-low.c (win32_create_inferior): Add pointer casts for C++.
8322
fcdad592
YQ
83232016-05-17 Yao Qi <yao.qi@linaro.org>
8324
8325 * linux-low.c (linux_stabilize_threads): Call unsuspend_all_lwps
8326 instead of find_inferior.
8327
9e784964
YQ
83282016-05-05 Yao Qi <yao.qi@linaro.org>
8329
8330 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer):
8331 Initialize res to zero.
8332
cf2ebb6e
YQ
83332016-05-05 Yao Qi <yao.qi@linaro.org>
8334
8335 * linux-arm-low.c (arm_sigreturn_next_pc): Change type of cpsr
8336 to uint32_t.
8337
c1aebf87
UW
83382016-05-04 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
8339
8340 * spu-low.c (fetch_ppc_register): Cast PowerPC-Linux-specific value
8341 used as first ptrace argument to PTRACE_TYPE_ARG1 for C++.
8342 (fetch_ppc_memory_1, store_ppc_memory_1): Likewise.
8343
35fd2deb 83442016-04-28 Par Olsson <par.olsson@windriver.com>
cbe14bcf 8345 Simon Marchi <simon.marchi@ericsson.com>
35fd2deb
PO
8346
8347 * tracepoint.c (write_inferior_int8): New function.
8348 (cmd_qtenable_disable): Write enable flag using
8349 write_inferior_int8.
8350
484b3c32
YQ
83512016-04-25 Yao Qi <yao.qi@linaro.org>
8352
8353 * linux-low.c (lwp_signal_can_be_delivered): Adjust.
8354 (need_step_over_p): Return zero if the LWP has pending signals
8355 can be delivered on software single step target.
8356
85ba7d86
YQ
83572016-04-25 Yao Qi <yao.qi@linaro.org>
8358
8359 * linux-low.c (reinsert_raw_breakpoint): If bp->inserted is true
8360 return instead of error.
8361
3539aa13
YQ
83622016-04-22 Yao Qi <yao.qi@linaro.org>
8363
8364 * linux-aarch32-low.c (arm_store_gregset): Clear CPSR bits 20
8365 to 23.
8366
5b061e98
YQ
83672016-04-22 Yao Qi <yao.qi@linaro.org>
8368
8369 * linux-low.c (lwp_signal_can_be_delivered): Don't deliver
8370 signal when stepping over breakpoint with software single
8371 step.
8372
3451269c
PA
83732016-04-21 Pedro Alves <palves@redhat.com>
8374
8375 * linux-s390-low.c (s390_collect_ptrace_register)
8376 (s390_supply_ptrace_register, s390_get_hwcap): Use gdb_byte * and
8377 add casts.
8378 (s390_check_regset): Use void * instead of gdb_byte *.
8379
a2358508
PA
83802016-04-20 Pedro Alves <palves@redhat.com>
8381
8382 * configure: Renegerate.
8383
6885166d
YQ
83842016-04-20 Yao Qi <yao.qi@linaro.org>
8385
8386 * linux-aarch32-low.c: Include "arch/arm-linux.h".
8387 (arm_fill_gregset): Use ARM_CPSR_GREGNUM rather than magic
8388 number 16.
8389 (arm_store_gregset): Likewise.
8390
2b863f51
WT
83912016-04-16 Walfred Tedeschi <walfred.tedeschi@intel.com>
8392
8393 * Makefile.in (clean): Add removal for i386-avx-mpx.c,
8394 i386-avx-mpx-linux.c, amd64-avx-mpx.c and amd64-avx-mpx-linux.c.
8395 (i386-avx-mpx.c, i386-avx-mpx-linux.c, amd64-avx-mpx.c)
8396 (amd64-avx-mpx-linux.c): New rules.
8397 (amd64-avx-mpx-linux-ipa.o, i386-avx-mpx-linux-ipa.o): New rule.
8398 * configure.srv (srv_i386_regobj): Add i386-avx-mpx.o.
8399 (srv_i386_linux_regobj): Add i386-avx-mpx-linux.o.
8400 (srv_amd64_regobj): Add amd64-avx-mpx.o.
8401 (srv_amd64_linux_regobj): Add amd64-avx-mpx-linux.o.
8402 (srv_i386_xmlfiles): Add i386/i386-avx-mpx.xml.
8403 (srv_amd64_xmlfiles): Add i386/amd64-avx-mpx.xml.
8404 (srv_i386_linux_xmlfiles): Add i386/i386-avx-mpx-linux.xml.
8405 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-mpx-linux.xml.
8406 (ipa_i386_linux_regobj): Add i386-avx-mpx-linux-ipa.o.
8407 (ipa_amd64_linux_regobj): Add amd64-avx-mpx-linux-ipa.o.
8408 * linux-x86-low.c (x86_linux_read_description): Add case for
8409 X86_XSTATE_AVX_MPX_MASK.
8410 (x86_get_ipa_tdesc_idx): Add cases for avx_mpx.
8411 (initialize_low_arch): Call init_registers_amd64_avx_mpx_linux and
8412 init_registers_i386_avx_mpx_linux.
8413 * linux-i386-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
8414 (initialize_low_tracepoint): Call
8415 init_registers_i386_avx_mpx_linux.
8416 * linux-amd64-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
8417 (initialize_low_tracepoint): Call
8418 init_registers_amd64_avx_mpx_linux.
8419 * linux-x86-tdesc.h (X86_TDESC_AVX_MPX): New enum value.
8420 (init_registers_amd64_avx_mpx_linux, tdesc_amd64_avx_mpx_linux)
8421 (init_registers_i386_avx_mpx_linux, tdesc_i386_avx_mpx_linux): New
8422 declarations.
8423
9b30624b
PA
84242016-04-18 Pedro Alves <palves@redhat.com>
8425
8426 * configure: Regenerate.
8427
45e3745e
AT
84282016-04-13 Antoine Tremblay <antoine.tremblay@ericsson.com>
8429
8430 * linux-aarch64-low.c (aarch64_emit_add): Switch x1 and x0.
8431 (aarch64_emit_sub): Likewise.
8432
2afc13ff
PA
84332016-04-12 Pedro Alves <palves@redhat.com>
8434
8435 * utils.c (prepare_to_throw_exception): Delete.
8436
6e774b13
SM
84372016-04-05 Simon Marchi <simon.marchi@ericsson.com>
8438
8439 * Makefile.in ($(IPA_LIB)): Set SONAME of the IPA lib.
8440
4dca19f8
MK
84412016-04-05 Marcin Kościelnicki <koriakin@0x04.net>
8442
8443 * tracepoint.c (getauxval): Move to #ifdef IN_PROCESS_AGENT.
8444
d0a9981f
MK
84452016-04-03 Marcin Kościelnicki <koriakin@0x04.net>
8446
8447 * linux-aarch64-ipa.c: Add <elf.h> include.
8448 * linux-ppc-ipa.c: Add <elf.h> include.
8449 * linux-s390-ipa.c: Add <elf.h> include.
8450
252db07e
MK
84512016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
8452
8453 * tracepoint.c (gdb_collect_ptr): Remove const qualifier.
8454 (get_raw_reg_ptr): Likewise.
8455 (get_trace_state_variable_value_ptr): Likewise.
8456 (set_trace_state_variable_value_ptr): Likewise.
8457 (initialize_tracepoint): Cast alloc_jump_pad_buffer result to
8458 char *.
8459
14e2b6d9
MK
84602016-03-31 Wei-cheng Wang <cole945@gmail.com>
8461 Marcin Kościelnicki <koriakin@0x04.net>
8462
8463 PR/17221
8464 * linux-ppc-low.c (emit_insns): New function.
8465 (__EMIT_ASM, _EMIT_ASM, EMIT_ASM): New macros.
8466 (ppc_emit_prologue): New function.
8467 (ppc_emit_epilogue): New function.
8468 (ppc_emit_add): New function.
8469 (ppc_emit_sub): New function.
8470 (ppc_emit_mul): New function.
8471 (ppc_emit_lsh): New function.
8472 (ppc_emit_rsh_signed): New function.
8473 (ppc_emit_rsh_unsigned): New function.
8474 (ppc_emit_ext): New function.
8475 (ppc_emit_zero_ext): New function.
8476 (ppc_emit_log_not): New function.
8477 (ppc_emit_bit_and): New function.
8478 (ppc_emit_bit_or): New function.
8479 (ppc_emit_bit_xor): New function.
8480 (ppc_emit_bit_not): New function.
8481 (ppc_emit_equal): New function.
8482 (ppc_emit_less_signed): New function.
8483 (ppc_emit_less_unsigned): New function.
8484 (ppc_emit_ref): New function.
8485 (ppc_emit_const): New function.
8486 (ppc_emit_reg): New function.
8487 (ppc_emit_pop): New function.
8488 (ppc_emit_stack_flush): New function.
8489 (ppc_emit_swap): New function.
8490 (ppc_emit_stack_adjust): New function.
8491 (ppc_emit_call): New function.
8492 (ppc_emit_int_call_1): New function.
8493 (ppc_emit_void_call_2): New function.
8494 (ppc_emit_if_goto): New function.
8495 (ppc_emit_goto): New function.
8496 (ppc_emit_eq_goto): New function.
8497 (ppc_emit_ne_goto): New function.
8498 (ppc_emit_lt_goto): New function.
8499 (ppc_emit_le_goto): New function.
8500 (ppc_emit_gt_goto): New function.
8501 (ppc_emit_ge_goto): New function.
8502 (ppc_write_goto_address): New function.
8503 (ppc_emit_ops_impl): New static variable.
8504 (ppc64v1_emit_prologue): New function.
8505 (ppc64v2_emit_prologue): New function.
8506 (ppc64_emit_epilogue): New function.
8507 (ppc64_emit_add): New function.
8508 (ppc64_emit_sub): New function.
8509 (ppc64_emit_mul): New function.
8510 (ppc64_emit_lsh): New function.
8511 (ppc64_emit_rsh_signed): New function.
8512 (ppc64_emit_rsh_unsigned): New function.
8513 (ppc64_emit_ext): New function.
8514 (ppc64_emit_zero_ext): New function.
8515 (ppc64_emit_log_not): New function.
8516 (ppc64_emit_bit_and): New function.
8517 (ppc64_emit_bit_or): New function.
8518 (ppc64_emit_bit_xor): New function.
8519 (ppc64_emit_bit_not): New function.
8520 (ppc64_emit_equal): New function.
8521 (ppc64_emit_less_signed): New function.
8522 (ppc64_emit_less_unsigned): New function.
8523 (ppc64_emit_ref): New function.
8524 (ppc64_emit_const): New function.
8525 (ppc64v1_emit_reg): New function.
8526 (ppc64v2_emit_reg): New function.
8527 (ppc64_emit_pop): New function.
8528 (ppc64_emit_stack_flush): New function.
8529 (ppc64_emit_swap): New function.
8530 (ppc64v1_emit_call): New function.
8531 (ppc64v2_emit_call): New function.
8532 (ppc64v1_emit_int_call_1): New function.
8533 (ppc64v2_emit_int_call_1): New function.
8534 (ppc64v1_emit_void_call_2): New function.
8535 (ppc64v2_emit_void_call_2): New function.
8536 (ppc64_emit_if_goto): New function.
8537 (ppc64_emit_eq_goto): New function.
8538 (ppc64_emit_ne_goto): New function.
8539 (ppc64_emit_lt_goto): New function.
8540 (ppc64_emit_le_goto): New function.
8541 (ppc64_emit_gt_goto): New function.
8542 (ppc64_emit_ge_goto): New function.
8543 (ppc64v1_emit_ops_impl): New static variable.
8544 (ppc64v2_emit_ops_impl): New static variable.
8545 (ppc_emit_ops): New function.
8546 (linux_low_target): Wire in ppc_emit_ops.
8547
a2174ba4
MK
85482016-03-31 Wei-cheng Wang <cole945@gmail.com>
8549 Marcin Kościelnicki <koriakin@0x04.net>
8550
8551 PR/17221
8552 * Makefile.in: Add powerpc-*-ipa.o
8553 * configure.srv: Add ipa_obj for powerpc*-linux.
8554 * linux-ppc-ipa.c: New file.
8555 * linux-ppc-low.c: Added linux-ppc-tdesc.h, ax.h, tracepoint.h
8556 includes.
8557 (PPC_FIELD): New macro.
8558 (PPC_SEXT): New macro.
8559 (PPC_OP6): New macro.
8560 (PPC_BO): New macro.
8561 (PPC_LI): New macro.
8562 (PPC_BD): New macro.
8563 (init_registers_*): Move prototype to linux-ppc-tdesc.h.
8564 (tdesc_*): Move declaration to linux-ppc-tdesc.h.
8565 (ppc_get_hwcap): Rename to ppc_get_auxv and add type parameter.
8566 (ppc_get_thread_area): New function.
8567 (is_elfv2_inferior): New function.
8568 (gen_ds_form): New function.
8569 (GEN_STD): New macro.
8570 (GEN_STDU): New macro.
8571 (GEN_LD): New macro.
8572 (GEN_LDU): New macro.
8573 (gen_d_form): New function.
8574 (GEN_ADDI): New macro.
8575 (GEN_ADDIS): New macro.
8576 (GEN_LI): New macro.
8577 (GEN_LIS): New macro.
8578 (GEN_ORI): New macro.
8579 (GEN_ORIS): New macro.
8580 (GEN_LWZ): New macro.
8581 (GEN_STW): New macro.
8582 (GEN_STWU): New macro.
8583 (gen_xfx_form): New function.
8584 (GEN_MFSPR): New macro.
8585 (GEN_MTSPR): New macro.
8586 (GEN_MFCR): New macro.
8587 (GEN_MTCR): New macro.
8588 (GEN_SYNC): New macro.
8589 (GEN_LWSYNC): New macro.
8590 (gen_x_form): New function.
8591 (GEN_OR): New macro.
8592 (GEN_MR): New macro.
8593 (GEN_LWARX): New macro.
8594 (GEN_STWCX): New macro.
8595 (GEN_CMPW): New macro.
8596 (gen_md_form): New function.
8597 (GEN_RLDICL): New macro.
8598 (GEN_RLDICR): New macro.
8599 (gen_i_form): New function.
8600 (GEN_B): New macro.
8601 (GEN_BL): New macro.
8602 (gen_b_form): New function.
8603 (GEN_BNE): New macro.
8604 (GEN_LOAD): New macro.
8605 (GEN_STORE): New macro.
8606 (gen_limm): New function.
8607 (gen_atomic_xchg): New function.
8608 (gen_call): New function.
8609 (ppc_relocate_instruction): New function.
8610 (ppc_install_fast_tracepoint_jump_pad): New function.
8611 (ppc_get_min_fast_tracepoint_insn_len): New function.
8612 (ppc_get_ipa_tdesc_idx): New function.
8613 (the_low_target): Wire in the new functions.
8614 (initialize_low_arch) [!__powerpc64__]: Don'it initialize 64-bit
8615 tdescs.
8616 * linux-ppc-tdesc.h: New file.
8617
a13c4696
MK
86182016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
8619
8620 * linux-aarch64-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
8621 (alloc_jump_pad_buffer): New function.
8622 * linux-amd64-ipa.c: Add <sys/mman.h> include.
8623 (alloc_jump_pad_buffer): New function.
8624 * linux-i386-ipa.c (alloc_jump_pad_buffer): New function.
8625 * linux-s390-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
8626 (alloc_jump_pad_buffer): New function.
8627 * tracepoint.c (getauxval) [!HAVE_GETAUXVAL]: New function.
8628 (initialize_tracepoint): Delegate to alloc_jump_pad_buffer.
8629 * tracepoint.h (alloc_jump_pad_buffer): New prototype.
8630 (getauxval) [!HAVE_GETAUXVAL]: New prototype.
8631
1cda1512
MK
86322016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
8633
8634 * linux-aarch64-ipa.c: Rename gdb_agent_get_raw_reg to get_raw_reg.
8635 * linux-amd64-ipa.c: Likewise.
8636 * linux-i386-ipa.c: Likewise.
8637 * linux-s390-ipa.c: Likewise.
8638 * tracepoint.c: IPA-export gdb_collect_ptr instead of gdb_collect,
8639 ditto for get_raw_reg_ptr, get_trace_state_variable_value_ptr,
8640 set_trace_state_variable_value_ptr.
8641 (struct ipa_sym_addresses): Likewise.
8642 (symbol_list): Likewise.
8643 (install_fast_tracepoint): Dereference gdb_collect_ptr instead of
8644 accessing gdb_collect directly.
8645 (gdb_collect_ptr_type): New typedef.
8646 (get_raw_reg_ptr_type): New typedef.
8647 (get_trace_state_variable_value_ptr_type): New typedef.
8648 (set_trace_state_variable_value_ptr_type): New typedef.
8649 (gdb_collect_ptr): New global.
8650 (get_raw_reg_ptr): New global.
8651 (get_trace_state_variable_value_ptr): New global.
8652 (set_trace_state_variable_value_ptr): New global.
8653 (get_raw_reg_func_addr): Dereference get_raw_reg_ptr instead of
8654 accessing get_raw_reg directly.
8655 (get_get_tsv_func_addr): Likewise for
8656 get_trace_state_variable_value_ptr.
8657 (get_set_tsv_func_addr): Likewise for
8658 set_trace_state_variable_value_ptr.
8659 * tracepoint.h: Rename gdb_agent_get_raw_reg to get_raw_reg.
8660
72fb5488
SM
86612016-03-30 Simon Marchi <simon.marchi@ericsson.com>
8662
8663 * tracepoint.c (cmd_qtenable_disable): Remove whitespace.
8664
28170b88
MK
86652016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
8666
8667 * remote-utils.c (look_up_one_symbol): Remove own_buf, handle 'v'
8668 packets.
8669 (relocate_instruction): Remove own_buf.
8670 * server.c (own_buf): Make global.
8671 (handle_v_requests): Make global.
8672 * server.h (own_buf): New declaration.
8673 (handle_v_requests): New prototype.
8674
f39e8743
MK
86752016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
8676
8677 PR 18377
8678 * linux-s390-low.c (add_insns): New function.
8679 (s390_emit_prologue): New function.
8680 (s390_emit_epilogue): New function.
8681 (s390_emit_add): New function.
8682 (s390_emit_sub): New function.
8683 (s390_emit_mul): New function.
8684 (s390_emit_lsh): New function.
8685 (s390_emit_rsh_signed): New function.
8686 (s390_emit_rsh_unsigned): New function.
8687 (s390_emit_ext): New function.
8688 (s390_emit_log_not): New function.
8689 (s390_emit_bit_and): New function.
8690 (s390_emit_bit_or): New function.
8691 (s390_emit_bit_xor): New function.
8692 (s390_emit_bit_not): New function.
8693 (s390_emit_equal): New function.
8694 (s390_emit_less_signed): New function.
8695 (s390_emit_less_unsigned): New function.
8696 (s390_emit_ref): New function.
8697 (s390_emit_if_goto): New function.
8698 (s390_emit_goto): New function.
8699 (s390_write_goto_address): New function.
8700 (s390_emit_litpool): New function.
8701 (s390_emit_const): New function.
8702 (s390_emit_call): New function.
8703 (s390_emit_reg): New function.
8704 (s390_emit_pop): New function.
8705 (s390_emit_stack_flush): New function.
8706 (s390_emit_zero_ext): New function.
8707 (s390_emit_swap): New function.
8708 (s390_emit_stack_adjust): New function.
8709 (s390_emit_set_r2): New function.
8710 (s390_emit_int_call_1): New function.
8711 (s390_emit_void_call_2): New function.
8712 (s390_emit_eq_goto): New function.
8713 (s390_emit_ne_goto): New function.
8714 (s390_emit_lt_goto): New function.
8715 (s390_emit_le_goto): New function.
8716 (s390_emit_gt_goto): New function.
8717 (s390_emit_ge_goto): New function.
8718 (s390x_emit_prologue): New function.
8719 (s390x_emit_epilogue): New function.
8720 (s390x_emit_add): New function.
8721 (s390x_emit_sub): New function.
8722 (s390x_emit_mul): New function.
8723 (s390x_emit_lsh): New function.
8724 (s390x_emit_rsh_signed): New function.
8725 (s390x_emit_rsh_unsigned): New function.
8726 (s390x_emit_ext): New function.
8727 (s390x_emit_log_not): New function.
8728 (s390x_emit_bit_and): New function.
8729 (s390x_emit_bit_or): New function.
8730 (s390x_emit_bit_xor): New function.
8731 (s390x_emit_bit_not): New function.
8732 (s390x_emit_equal): New function.
8733 (s390x_emit_less_signed): New function.
8734 (s390x_emit_less_unsigned): New function.
8735 (s390x_emit_ref): New function.
8736 (s390x_emit_if_goto): New function.
8737 (s390x_emit_const): New function.
8738 (s390x_emit_call): New function.
8739 (s390x_emit_reg): New function.
8740 (s390x_emit_pop): New function.
8741 (s390x_emit_stack_flush): New function.
8742 (s390x_emit_zero_ext): New function.
8743 (s390x_emit_swap): New function.
8744 (s390x_emit_stack_adjust): New function.
8745 (s390x_emit_int_call_1): New function.
8746 (s390x_emit_void_call_2): New function.
8747 (s390x_emit_eq_goto): New function.
8748 (s390x_emit_ne_goto): New function.
8749 (s390x_emit_lt_goto): New function.
8750 (s390x_emit_le_goto): New function.
8751 (s390x_emit_gt_goto): New function.
8752 (s390x_emit_ge_goto): New function.
8753 (s390_emit_ops): New function.
8754 (struct linux_target_ops): Fill in emit_ops hook.
8755
abd9baf9
MK
87562016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
8757
8758 PR 18377
8759 * Makefile.in: Add s390 IPA files.
8760 * configure.srv: Build IPA for s390.
8761 * linux-s390-ipa.c: New file.
8762 * linux-s390-low.c: New includes - inttypes.h and linux-s390-tdesc.h.
8763 (init_registers_s390_linux32): Move declaration to linux-s390-tdesc.h.
8764 (tdesc_s390_linux32): Likewise.
8765 (init_registers_s390_linux32v1): Likewise.
8766 (tdesc_s390_linux32v1): Likewise.
8767 (init_registers_s390_linux32v2): Likewise.
8768 (tdesc_s390_linux32v2): Likewise.
8769 (init_registers_s390_linux64): Likewise.
8770 (tdesc_s390_linux64): Likewise.
8771 (init_registers_s390_linux64v1): Likewise.
8772 (tdesc_s390_linux64v1): Likewise.
8773 (init_registers_s390_linux64v2): Likewise.
8774 (tdesc_s390_linux64v2): Likewise.
8775 (init_registers_s390_te_linux64): Likewise.
8776 (tdesc_s390_te_linux64): Likewise.
8777 (init_registers_s390_vx_linux64): Likewise.
8778 (tdesc_s390_vx_linux64): Likewise.
8779 (init_registers_s390_tevx_linux64): Likewise.
8780 (tdesc_s390_tevx_linux64): Likewise.
8781 (init_registers_s390x_linux64): Likewise.
8782 (tdesc_s390x_linux64): Likewise.
8783 (init_registers_s390x_linux64v1): Likewise.
8784 (tdesc_s390x_linux64v1): Likewise.
8785 (init_registers_s390x_linux64v2): Likewise.
8786 (tdesc_s390x_linux64v2): Likewise.
8787 (init_registers_s390x_te_linux64): Likewise.
8788 (tdesc_s390x_te_linux64): Likewise.
8789 (init_registers_s390x_vx_linux64): Likewise.
8790 (tdesc_s390x_vx_linux64): Likewise.
8791 (init_registers_s390x_tevx_linux64): Likewise.
8792 (tdesc_s390x_tevx_linux64): Likewise.
8793 (have_hwcap_s390_vx): New static variable.
8794 (s390_arch_setup): Fill have_hwcap_s390_vx.
8795 (s390_get_thread_area): New function.
8796 (s390_ft_entry_gpr_esa): New const.
8797 (s390_ft_entry_gpr_zarch): New const.
8798 (s390_ft_entry_misc): New const.
8799 (s390_ft_entry_fr): New const.
8800 (s390_ft_entry_vr): New const.
8801 (s390_ft_main_31): New const.
8802 (s390_ft_main_64): New const.
8803 (s390_ft_exit_fr): New const.
8804 (s390_ft_exit_vr): New const.
8805 (s390_ft_exit_misc): New const.
8806 (s390_ft_exit_gpr_esa): New const.
8807 (s390_ft_exit_gpr_zarch): New const.
8808 (append_insns): New function.
8809 (s390_relocate_instruction): New function.
8810 (s390_install_fast_tracepoint_jump_pad): New function.
8811 (s390_get_min_fast_tracepoint_insn_len): New function.
8812 (s390_get_ipa_tdesc_idx): New function.
8813 (struct linux_target_ops): Wire in the above functions.
8814 (initialize_low_arch) [!__s390x__]: Don't initialize s390x tdescs.
8815 * linux-s390-tdesc.h: New file.
8816
a4105d04
MK
88172016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
8818
8819 * linux-s390-low.c (s390_supports_tracepoints): New function.
8820 (struct linux_target_ops): Fill supports_tracepoints hook.
8821
35ac8b3e
YQ
88222016-03-18 Yao Qi <yao.qi@linaro.org>
8823
8824 * linux-low.c (lwp_signal_can_be_delivered): New function.
8825 (linux_resume_one_lwp_throw): Use lwp_signal_can_be_delivered.
8826
94610ec4
YQ
88272016-03-18 Yao Qi <yao.qi@linaro.org>
8828
8829 * linux-low.c (linux_resume_one_lwp_throw): Set 'signal' to
8830 0 if signal is enqueued. Remove 'signal' from one debugging
8831 message. Move one debugging message to some lines below.
8832 Remove code setting 'signal' to 0.
8833
80aea927
YQ
88342016-03-18 Yao Qi <yao.qi@linaro.org>
8835
8836 * linux-low.c (linux_low_filter_event): Remove redundant
8837 WIFSTOPPED check together with linux_wstatus_maybe_breakpoint.
8838
b04fd3be
MK
88392016-03-09 Marcin Kościelnicki <koriakin@0x04.net>
8840
8841 * linux-ppc-low.c (ppc_supports_tracepoints): New function.
8842 (struct linux_target_ops): Wire in the above.
8843
c40c8d4b
YQ
88442016-03-03 Yao Qi <yao.qi@linaro.org>
8845
8846 * linux-low.c: Update comments to start_step_over.
8847
0f8288ae
YQ
88482016-03-03 Yao Qi <yao.qi@linaro.org>
8849
8850 PR server/19736
8851 * linux-low.c (handle_extended_wait): Set child suspended
8852 if event_lwp->bp_reinsert isn't zero.
8853
fdbd04a8
YQ
88542016-03-02 Yao Qi <yao.qi@linaro.org>
8855
8856 * linux-low.c (linux_resume_one_lwp_throw): Replace code with
8857 enqueue_pending_signal.
8858
6896a8fa
MK
88592016-03-02 Marcin Kościelnicki <koriakin@0x04.net>
8860
8861 * tracepoint.c (cmd_qtstart): Only set ipa_tdesc_idx if agent
8862 is actually loaded.
8863
ab503087
MK
88642016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
8865
8866 * linux-s390-low.c (s390_num_regs_3264): Define on 31-bit too.
8867 (s390_regmap_3264) [!__s390x__]: New global.
8868 (s390_collect_ptrace_register): Skip map entries containing -1.
8869 (s390_supply_ptrace_register): Ditto.
8870 (s390_fill_gprs_high): New function.
8871 (s390_store_gprs_high): New function.
8872 (s390_regsets): Add NT_S390_HIGH_GPRS.
8873 (s390_get_hwcap): Enable on 31-bit.
8874 (have_hwcap_s390_high_gprs): Enable on 31-bit.
8875 (s390_arch_setup): Enable detection of high GPRs, TDB, VX on 31-bit.
8876 Detect NT_S390_HIGH_GPRS.
8877 (s390_usrregs_info_3264): Enable on 31-bit.
8878 (s390_regs_info): Enable regs_info_3264 on 31-bit.
8879 (initialize_low_arch): Initialize s390_regsets_info_3264 on 31-bit.
8880
ae91f625
MK
88812016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
8882
8883 PR gdb/13808
8884 * Makefile.in: Add i386-*-linux-ipa.o and amd64-*-linux-ipa.o.
8885 * configure.srv: Ditto.
8886 * linux-aarch64-ipa.c (get_ipa_tdesc): New function.
8887 (initialize_low_tracepoint): Remove ipa_tdesc assignment.
8888 * linux-amd64-ipa.c: Add "linux-x86-tdesc.h" include.
8889 (init_registers_amd64_linux): Remove prototype.
8890 (tdesc_amd64_linux): Remove declaration.
8891 (get_ipa_tdesc): New function.
8892 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
8893 initialize remaining tdescs.
8894 * linux-i386-ipa.c: Add "linux-x86-tdesc.h" include.
8895 (init_registers_i386_linux): Remove prototype.
8896 (tdesc_i386_linux): Remove declaration.
8897 (get_ipa_tdesc): New function.
8898 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
8899 initialize remaining tdescs.
8900 * linux-low.c (linux_get_ipa_tdesc_idx): New function.
8901 (linux_target_ops): wire in linux_get_ipa_tdesc_idx.
8902 * linux-low.h (struct linux_target_ops): Add get_ipa_tdesc_idx.
8903 * linux-x86-low.c: Move tdesc declarations to linux-x86-tdesc.h.
8904 (x86_get_ipa_tdesc_idx): New function.
8905 (the_low_target): Wire in x86_get_ipa_tdesc_idx.
8906 * linux-x86-tdesc.h: New file.
8907 * target.h (struct target_ops): Add get_ipa_tdesc_idx.
8908 (target_get_ipa_tdesc_idx): New macro.
8909 * tracepoint.c (ipa_tdesc_idx): New macro.
8910 (struct ipa_sym_addresses): Add addr_ipa_tdesc_idx.
8911 (symbol_list): Add ipa_tdesc_idx.
8912 (cmd_qtstart): Write ipa_tdesc_idx in the target.
8913 (ipa_tdesc): Remove.
8914 (ipa_tdesc_idx): New variable.
8915 (get_context_regcache): Use get_ipa_tdesc.
8916 (gdb_collect): Ditto.
8917 (gdb_probe): Ditto.
8918 * tracepoint.h (get_ipa_tdesc): New prototype.
8919 (ipa_tdesc): Remove.
8920
e7ad2f14
PA
89212016-02-24 Pedro Alves <palves@redhat.com>
8922
8923 * linux-low.c (check_stopped_by_breakpoint): Rename to ...
8924 (save_stop_reason): ... this. Use GDB_ARCH_IS_TRAP_HWBKPT and
8925 handle ambiguous GDB_ARCH_IS_TRAP_BRKPT / GDB_ARCH_IS_TRAP_HWBKPT.
8926 Factor out common code between the USE_SIGTRAP_SIGINFO and
8927 !USE_SIGTRAP_SIGINFO blocks.
8928 (linux_low_filter_event): Call save_stop_reason instead of
8929 check_stopped_by_breakpoint and check_stopped_by_watchpoint.
8930 Update comments.
8931 (linux_wait_1): Update comments.
8932
657f9cde
WW
89332016-02-24 Wei-cheng Wang <cole945@gmail.com>
8934
8935 * linux-ppc-low.c (ppc_supports_z_point_type): New function:
8936 (ppc_insert_point, ppc_remove_point): Insert/remove z-packet breakpoints.
8937 (ppc64_emit_ops_vector): Add target ops - ppc_supports_z_point_type,
8938 ppc_insert_point, ppc_remove_point.
8939
b00b61e1
MK
89402016-02-17 Marcin Kościelnicki <koriakin@0x04.net>
8941
8942 * linux-s390-low.c (s390_supports_z_point_type): New function.
8943 (struct linux_target_ops): Wire s390_supports_z_point_type in.
8944
553cb527
YQ
89452016-02-16 Yao Qi <yao.qi@linaro.org>
8946
8947 * linux-arm-low.c (get_next_pcs_syscall_next_pc): Remove argument
8948 PC. Get pc from regcache_read_pc.
8949
a5652c21
YQ
89502016-02-12 Yao Qi <yao.qi@linaro.org>
8951
8952 * linux-aarch64-low.c (aarch64_get_pc): Call linux_get_pc_64bit
8953 or linux_get_pc_32bit.
8954 (aarch64_set_pc): Call linux_set_pc_64bit or linux_set_pc_32bit.
8955
ed443b61
YQ
89562016-02-12 Yao Qi <yao.qi@linaro.org>
8957
8958 * linux-arm-low.c (get_next_pcs_ops): Initialize it with
8959 arm_linux_get_next_pcs_fixup.
8960
020ecd38
MK
89612016-02-12 Marcin Kościelnicki <koriakin@0x04.net>
8962
8963 * tracepoint.c (x_tracepoint_action_download): Change
8964 write_inferior_data_ptr to write_inferior_data_pointer.
8965 (cmd_qtstart): Likewise.
8966 (write_inferior_data_ptr): Remove.
8967 (download_agent_expr): Change write_inferior_data_ptr to
8968 write_inferior_data_pointer.
8969 (download_tracepoint_1): Likewise.
8970 (download_tracepoint): Likewise.
8971 (download_trace_state_variables): Likewise.
8972
7cae9051
WW
89732016-02-11 Wei-cheng Wang <cole945@gmail.com>
8974 Marcin Kościelnicki <koriakin@0x04.net>
8975
8976 * tracepoint.c (struct tracepoint_action_ops): Remove.
8977 (struct tracepoint_action): Remove ops.
8978 (m_tracepoint_action_download, r_tracepoint_action_download)
8979 (x_tracepoint_action_download, l_tracepoint_action_download): Adjust
8980 size and offset accordingly.
8981 (m_tracepoint_action_ops, r_tracepoint_action_ops)
8982 (x_tracepoint_action_ops, l_tracepoint_action_ops): Remove.
8983 (tracepoint_action_send, tracepoint_action_download): New functions.
8984 Helpers for trace action handlers.
8985 (add_tracepoint_action): Remove setup actions ops.
8986 (download_tracepoint_1, tracepoint_send_agent): Call helper functions.
8987
9f6a71b4
YQ
89882016-02-10 Yao Qi <yao.qi@linaro.org>
8989
8990 * regcache.c (regcache_raw_read_unsigned): Clear *VAL.
8991
1e94266c
SM
89922016-02-09 Simon Marchi <simon.marchi@ericsson.com>
8993
8994 * configure.ac: Use AC_CONFIG_FILES instead of passing arguments
8995 to AC_OUTPUT.
8996 * configure: Regenerate.
8997
8adce034
SM
89982016-02-09 Simon Marchi <simon.marchi@ericsson.com>
8999
9000 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): Change
9001 void * to gdb_byte *.
9002 * linux-low.c (siginfo_fixup): Likewise.
9003 (linux_xfer_siginfo): Likewise.
9004 * linux-low.h (struct linux_target_ops) <siginfo_fixup>:
9005 Likewise.
9006 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
9007
93813b37
WT
90082016-02-02 Walfred Tedeschi <walfred.tedeschi@intel.com>
9009
9010 * configure.srv (x86_64-*-linux*): Add amd64-linux-siginfo.o
9011 to srv_tgtobj.
9012 (i[34567]86-*-linux*): Add amd64-linux-siginfo.o
9013 to srv_tgtobj.
9014 * linux-x86-low.c [__x86_64__]: Include
9015 "nat/amd64-linux-siginfo.h".
9016 (compat_siginfo_from_siginfo, siginfo_from_compat_siginfo)
9017 (compat_x32_siginfo_from_siginfo, siginfo_from_compat_x32_siginfo)
9018 (compat_timeval, compat_sigval, compat_x32_clock, cpt_si_pid)
9019 (cpt_si_uid, cpt_si_timerid, cpt_si_overrun, cpt_si_status)
9020 (cpt_si_utime, cpt_si_stime, cpt_si_ptr, cpt_si_addr, cpt_si_band)
9021 (cpt_si_fd, si_timerid, si_overrun): Move from
9022 nat/amd64-linux-siginfo.c.
9023 * Makefile.in (amd64-linux-siginfo.o:): New rule.
9024
8424cc97
SM
90252016-01-28 Simon Marchi <simon.marchi@ericsson.com>
9026
9027 * server.c (skip_to_semicolon): Remove.
9028 (process_point_options): Use strchrnul instead of
9029 skip_to_semicolon.
9030
4d18591b
YQ
90312016-01-26 Yao Qi <yao.qi@linaro.org>
9032
9033 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Remove argument pc.
9034 * linux-low.c (install_software_single_step_breakpoints): Don't
9035 call regcache_read_pc.
9036 * linux-low.h (struct linux_target_ops) <get_next_pcs>: Remove
9037 argument pc.
9038
d8020970
YQ
90392016-01-26 Yao Qi <yao.qi@linaro.org>
9040
9041 * linux-low.c (install_software_single_step_breakpoints): Call
9042 regcache_read_pc instead of get_pc.
9043
8b207339
YQ
90442016-01-26 Yao Qi <yao.qi@linaro.org>
9045
9046 * remote-utils.c (remote_close) [!USE_WIN32API]: Ignore SIGIO.
9047 (unblock_async_io): Rename to ...
9048 (block_unblock_async_io): ... it. New function.
9049 (enable_async_io): Don't install SIGIO handler. Unblock it
9050 instead.
9051 (disable_async_io): Don't ignore SIGIO. Block it instead.
9052 (initialize_async_io): Install SIGIO handler. Don't call
9053 unblock_async_io.
9054
18879fef
YQ
90552016-01-26 Yao Qi <yao.qi@linaro.org>
9056
9057 * remote-utils.c (getpkt): If the buffer isn't empty, and the
9058 first character is '\003', call *the_target->request_interrupt.
9059
a0f8e08a
YQ
90602016-01-25 Yao Qi <yao.qi@linaro.org>
9061
9062 * remote-utils.c (new_thread_notify): Remove.
9063 (dead_thread_notify): Likewise.
9064 * remote-utils.h (new_thread_notify): Remove declaration.
9065 (dead_thread_notify): Likewise.
9066
cc5fd9ab
MK
90672016-01-23 Marcin Kościelnicki <koriakin@0x04.net>
9068
9069 * gdb.trace/pending.exp: Fix expected message on continue.
9070
99e8eb11
MK
90712016-01-22 Marcin Kościelnicki <koriakin@0x04.net>
9072
9073 * tracepoint.c (write_inferior_data_ptr): Cast to uintptr_t, so that
9074 it works properly on big-endian machines where sizeof (CORE_ADDR)
9075 != sizeof (void *).
9076
a994041d
PA
90772016-01-21 Pedro Alves <palves@redhat.com>
9078
9079 * Makefile.in (COMPILER_CFLAGS, CXXFLAGS): New.
9080 (INTERNAL_CFLAGS_BASE): Use COMPILER_CFLAGS instead of CFLAGS.
9081 * configure: Regenerate.
9082
f7a6a40d
YQ
90832016-01-21 Yao Qi <yao.qi@linaro.org>
9084
9085 * linux-arm-low.c (arm_sigreturn_next_pc): Add parameter
9086 is_thumb and set it according to CPSR saved on the stack.
9087 (get_next_pcs_syscall_next_pc): Pass is_thumb to
9088 arm_sigreturn_next_pc.
9089
6f69e520
YQ
90902016-01-18 Yao Qi <yao.qi@linaro.org>
9091
9092 * linux-low.c (linux_set_pc_64bit): New function.
9093 (linux_get_pc_64bit): New function.
9094 * linux-low.h (linux_set_pc_64bit, linux_get_pc_64bit):
9095 Declare.
9096 * linux-sparc-low.c (debug_threads): Remove declaration.
9097 (sparc_get_pc): Remove.
9098 (the_low_target): Use linux_get_pc_64bit instead of
9099 sparc_get_pc.
9100 * linux-tile-low.c (tile_get_pc, tile_set_pc): Remove.
9101 (the_low_target): Use linux_get_pc_64bit and
9102 linux_set_pc_64bit.
9103
276d4552
YQ
91042016-01-18 Yao Qi <yao.qi@linaro.org>
9105
9106 * linux-arm-low.c (debug_threads): Remove declaration.
9107 (arm_get_pc, arm_set_pc): Remove.
9108 (the_low_target): Use linux_get_pc_32bit and
9109 linux_set_pc_32bit.
9110 * linux-bfin-low.c (bfin_get_pc, bfin_set_pc): Remove.
9111 (the_low_target): Use linux_get_pc_32bit and
9112 linux_set_pc_32bit.
9113 * linux-cris-low.c (debug_threads): Remove declaration.
9114 (cris_get_pc, cris_set_pc,): Remove.
9115 (the_low_target): Use linux_get_pc_32bit and
9116 linux_set_pc_32bit.
9117 * linux-crisv32-low.c (debug_threads): Remove declaration.
9118 (cris_get_pc, cris_set_pc): Remove.
9119 (the_low_target): Use linux_get_pc_32bit and
9120 linux_set_pc_32bit.
9121 * linux-low.c: Include inttypes.h.
9122 (linux_get_pc_32bit, linux_set_pc_32bit): New functions.
9123 * linux-low.h (linux_get_pc_32bit, linux_set_pc_32bit): Declare.
9124 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Remove.
9125 (the_low_target): Use linux_get_pc_32bit and
9126 linux_set_pc_32bit.
9127 * linux-m68k-low.c (m68k_get_pc, m68k_set_pc): Remove.
9128 (the_low_target): Use linux_get_pc_32bit and
9129 linux_set_pc_32bit.
9130 * linux-nios2-low.c (nios2_get_pc, nios2_set_pc): Remove.
9131 (the_low_target): Use linux_get_pc_32bit and
9132 linux_set_pc_32bit.
9133 * linux-sh-low.c (sh_get_pc, sh_set_pc): Remove.
9134 (the_low_target): Use linux_get_pc_32bit and
9135 linux_set_pc_32bit.
9136 * linux-xtensa-low.c (xtensa_get_pc, xtensa_set_pc): Remove.
9137 (the_low_target): Use linux_get_pc_32bit and
9138 linux_set_pc_32bit.
9139
eb0edac8
GB
91402016-01-18 Gary Benson <gbenson@redhat.com>
9141
9142 * configure.ac (AC_FUNC_FORK): New check.
9143 * config.in: Regenerate.
9144 * configure: Likewise.
9145
1b451dda
YQ
91462016-01-14 Yao Qi <yao.qi@linaro.org>
9147
9148 * linux-aarch32-low.c (thumb2_breakpoint): Make it static.
9149 * linux-aarch32-low.h (thumb2_breakpoint): Remove declaration.
9150 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Pass 1 to
9151 arm_get_next_pcs_ctor.
9152
82075af2
JS
91532016-01-12 Josh Stone <jistone@redhat.com>
9154 Philippe Waroquiers <philippe.waroquiers@skynet.be>
9155
9156 * inferiors.h: Include "gdb_vecs.h".
9157 (struct process_info): Add syscalls_to_catch.
9158 * inferiors.c (remove_process): Free syscalls_to_catch.
9159 * remote-utils.c (prepare_resume_reply): Report syscall_entry and
9160 syscall_return stops.
9161 * server.h (UNKNOWN_SYSCALL, ANY_SYSCALL): Define.
9162 * server.c (handle_general_set): Handle QCatchSyscalls.
9163 (handle_query): Report support for QCatchSyscalls.
9164 * target.h (struct target_ops): Add supports_catch_syscall.
9165 (target_supports_catch_syscall): New macro.
9166 * linux-low.h (struct linux_target_ops): Add get_syscall_trapinfo.
9167 (struct lwp_info): Add syscall_state.
9168 * linux-low.c (handle_extended_wait): Mark syscall_state as an entry.
9169 Maintain syscall_state and syscalls_to_catch across exec.
9170 (get_syscall_trapinfo): New function, proxy to the_low_target.
9171 (linux_low_ptrace_options): Enable PTRACE_O_TRACESYSGOOD.
9172 (linux_low_filter_event): Toggle syscall_state entry/return for
9173 syscall traps, and set it ignored for all others.
9174 (gdb_catching_syscalls_p): New function.
9175 (gdb_catch_this_syscall_p): New function.
9176 (linux_wait_1): Handle SYSCALL_SIGTRAP.
9177 (linux_resume_one_lwp_throw): Add PTRACE_SYSCALL possibility.
9178 (linux_supports_catch_syscall): New function.
9179 (linux_target_ops): Install it.
9180 * linux-x86-low.c (x86_get_syscall_trapinfo): New function.
9181 (the_low_target): Install it.
9182
8f13a3ce
MF
91832016-01-12 Mike Frysinger <vapier@gentoo.org>
9184
9185 * acinclude.m4: Include new ../warning.m4 file.
9186 * configure: Regenerated.
9187 * configure.ac: Replace all warning logic with AM_GDB_WARNINGS.
9188
5b3da067
MF
91892016-01-12 Mike Frysinger <vapier@gentoo.org>
9190
9191 * ax.c (is_goto_target): Mark static.
9192 * linux-low.c (register_addr): Likewise.
9193 (linux_fetch_registers, linux_store_registers): Likewise.
9194 * mem-break.c (any_persistent_commands): Fix old prototype.
9195 (add_commands_to_breakpoint): Mark static.
9196 * regcache.c (find_register_by_name): Delete unused func.
9197 * remote-utils.c (hex_or_minus_one): Mark static.
9198 * server.c (monitor_show_help): Mark static.
9199 (handle_query, handle_v_cont, handle_v_attach, handle_v_kill,
9200 handle_v_requests): Likewise.
9201
bc504a31
PA
92022016-01-12 Pedro Alves <palves@redhat.com>
9203
9204 Remove use of the registered trademark symbol throughout.
9205
5a0dd67a
YQ
92062016-01-08 Yao Qi <yao.qi@linaro.org>
9207
9208 * remote-utils.c (getpkt): If c is '\003', call target hook
9209 request_interrupt.
9210
b2ca446f
YQ
92112016-01-06 Yao Qi <yao.qi@linaro.org>
9212
9213 * linux-aarch32-low.h (arm_abi_breakpoint): Move to
9214 linux-aarch32-low.c.
9215 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
9216 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
9217 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
9218 (thumb2_breakpoint): Declare.
9219 * linux-aarch32-low.c (arm_abi_breakpoint): Moved from
9220 linux-aarch32-low.h.
9221 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
9222 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
9223 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
9224
edd88788
JB
92252016-01-01 Joel Brobecker <brobecker@adacore.com>
9226
9227 * gdbreplay.c (gdbreplay_version): Change copyright year in
9228 version message.
9229 * server.c (gdbserver_version): Likewise.
9230
65da7f14
PP
92312015-12-28 Patrick Palka <patrick@parcs.ath.cx>
9232
9233 * server.c (crc32_table): Delete.
9234 (crc32): Use libiberty's xcrc32 function.
9235
4abd5ed2
JB
92362015-12-22 Joel Brobecker <brobecker@adacore.com>
9237
9238 * lynx-low.c (lynx_delete_thread_callback): New function.
9239 (lynx_mourn): Properly delete our process and all of its
9240 threads. Remove call to clear_inferiors.
9241
0e50fe5c
JB
92422015-12-22 Joel Brobecker <brobecker@adacore.com>
9243
9244 * target.c (thread_search_callback): Add check that
9245 the thread_stopped target callback is not NULL before
9246 calling it.
9247
35adc03f
YQ
92482015-12-21 Yao Qi <yao.qi@linaro.org>
9249
9250 * linux-aarch32-low.h [__aarch64__]: Use arm_abi_breakpoint
9251 arm breakpoint.
9252
bd2b2909
AT
92532015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
9254
9255 * server.c (handle_query): Call target_supports_software_single_step.
9256
7fe5e27e
AT
92572015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
9258
9259 * linux-low.c (single_step): New function.
9260 (linux_resume_one_lwp_throw): Call single_step.
9261 (start_step_over): Likewise.
9262
d9311bfa
AT
92632015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
9264
9265 * Makefile.in (SFILES): Append arch/arm-linux.c,
9266 arch/arm-get-next-pcs.c.
9267 (arm-linux.o): New rule.
9268 (arm-get-next-pcs.o): New rule.
9269 * configure.srv (arm*-*-linux*): Add arm-get-next-pcs.o,
9270 arm-linux.o.
9271 * linux-aarch32-low.c (arm_abi_breakpoint): Remove macro. Moved
9272 to linux-aarch32-low.c.
9273 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
9274 (arm_breakpoint_len, thumb_breakpoint): Likewise.
9275 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
9276 (thumb2_breakpoint_len): Likewise.
9277 (arm_is_thumb_mode): Make non-static.
9278 * linux-aarch32-low.h (arm_abi_breakpoint): New macro. Moved
9279 from linux-aarch32-low.c.
9280 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
9281 (arm_breakpoint_len, thumb_breakpoint): Likewise.
9282 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
9283 (thumb2_breakpoint_len): Likewise.
9284 (arm_is_thumb_mode): New declaration.
9285 * linux-arm-low.c: Include arch/arm-linux.h
9286 aarch/arm-get-next-pcs.h, sys/syscall.h.
9287 (get_next_pcs_ops): New struct.
9288 (get_next_pcs_addr_bits_remove): New function.
9289 (get_next_pcs_is_thumb): New function.
9290 (get_next_pcs_read_memory_unsigned_integer): Likewise.
9291 (arm_sigreturn_next_pc): Likewise.
9292 (get_next_pcs_syscall_next_pc): Likewise.
9293 (arm_gdbserver_get_next_pcs): Likewise.
9294 (struct linux_target_ops) <arm_gdbserver_get_next_pcs>:
9295 Initialize.
9296 * linux-low.h: Move CORE_ADDR vector definition to gdb_vecs.h.
9297 * server.h: Include gdb_vecs.h.
9298
68ce2059
AT
92992015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
9300
9301 * Makefile.in (SFILES): Append common/common-regcache.c.
9302 (OBS): Append common-regcache.o.
9303 (common-regcache.o): New rule.
9304 * regcache.c (init_register_cache): Initialize cache to
9305 REG_UNAVAILABLE.
9306 (regcache_raw_read_unsigned): New function.
9307 * regcache.h (REG_UNAVAILABLE, REG_VALID): Replaced by shared
9308 register_status enum.
9309
fa5308bd
AT
93102015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
9311
9312 * linux-aarch64-low.c (the_low_targets): Rename
9313 breakpoint_reinsert_addr to get_next_pcs.
9314 * linux-arm-low.c (the_low_targets): Likewise.
9315 * linux-bfin-low.c (the_low_targets): Likewise.
9316 * linux-cris-low.c (the_low_targets): Likewise.
9317 * linux-crisv32-low.c (the_low_targets): Likewise.
9318 * linux-low.c (can_software_single_step): Likewise.
9319 (install_software_single_step_breakpoints): New function.
9320 (start_step_over): Use install_software_single_step_breakpoints.
9321 * linux-low.h: New CORE_ADDR vector.
9322 (struct linux_target_ops) Rename breakpoint_reinsert_addr to
9323 get_next_pcs.
9324 * linux-mips-low.c (the_low_targets): Likewise.
9325 * linux-nios2-low.c (the_low_targets): Likewise.
9326 * linux-sparc-low.c (the_low_targets): Likewise.
9327
4a6ed09b
PA
93282015-12-17 Pedro Alves <palves@redhat.com>
9329
9330 * linux-low.c (linux_kill_one_lwp): Remove references to
9331 LinuxThreads.
9332 (kill_lwp): Remove HAVE_TKILL_SYSCALL check. No longer fall back
9333 to 'kill'.
9334 (linux_init_signals): Delete.
9335 (initialize_low): Adjust.
9336 * thread-db.c (thread_db_init): Remove LinuxThreads reference.
9337
7544db95
PA
93382015-12-16 Pedro Alves <palves@redhat.com>
9339
9340 * configure.ac (compiler warning flags): When testing a
9341 -Wno-foo option, check whether -Wfoo works instead.
9342 * configure: Regenerate.
9343
8020350c
DB
93442015-12-11 Don Breazeal <donb@codesourcery.com>
9345
9346 * server.c (process_serial_event): Don't exit from gdbserver
9347 in remote mode if there are still active inferiors.
9348
db91f502
YQ
93492015-12-11 Yao Qi <yao.qi@linaro.org>
9350
9351 * linux-aarch64-low.c (aarch64_breakpoint_at): Call
9352 arm_breakpoint_at if the process is 32-bit.
9353
b37a6290
YQ
93542015-12-11 Yao Qi <yao.qi@linaro.org>
9355
9356 * linux-aarch32-low.c [__aarch64__]: Use arm_abi_breakpoint
9357 arm breakpoint.
9358
17b1509a
YQ
93592015-12-07 Yao Qi <yao.qi@linaro.org>
9360
9361 * configure.srv: Append arm.o to srv_tgtobj for
9362 aarch64*-*-linux* target.
9363 * linux-aarch32-low.c (arm_abi_breakpoint): New macro. Moved
9364 from linux-arm-low.c.
9365 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
9366 (arm_breakpoint_len, thumb_breakpoint): Likewise.
9367 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
9368 (thumb2_breakpoint_len): Likewise.
9369 (arm_is_thumb_mode, arm_breakpoint_at): Likewise.
9370 (arm_breakpoint_kinds): Likewise.
9371 (arm_breakpoint_kind_from_pc): Likewise.
9372 (arm_sw_breakpoint_from_kind): Likewise.
9373 (arm_breakpoint_kind_from_current_state): Likewise.
9374 * linux-aarch32-low.h (arm_breakpoint_kind_from_pc): Declare.
9375 (arm_sw_breakpoint_from_kind): Declare.
9376 (arm_breakpoint_kind_from_current_state): Declare.
9377 (arm_breakpoint_at): Declare.
9378 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): Call
9379 arm_sw_breakpoint_from_kind if process is 32-bit.
9380 (aarch64_breakpoint_kind_from_pc): New function.
9381 (aarch64_breakpoint_kind_from_current_state): New function.
9382 (the_low_target): Initialize fields breakpoint_kind_from_pc
9383 and breakpoint_kind_from_current_state.
9384 * linux-arm-low.c (arm_breakpoint_kinds): Move to
9385 linux-aarch32-low.c.
9386 (arm_abi_breakpoint, arm_eabi_breakpoint): Likewise.
9387 (arm_breakpoint, arm_breakpoint_len): Likewise.
9388 (thumb_breakpoint, thumb_breakpoint_len): Likewise.
9389 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
9390 (arm_is_thumb_mode): Likewise.
9391 (arm_breakpoint_at): Likewise.
9392 (arm_breakpoint_kind_from_pc): Likewise.
9393 (arm_sw_breakpoint_from_kind): Likewise.
9394 (arm_breakpoint_kind_from_current_state): Likewise.
9395
9396 Revert:
9397 2015-08-04 Yao Qi <yao.qi@linaro.org>
9398
9399 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
9400 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
9401 * server.c (extended_protocol): Remove "static".
9402 * server.h (extended_protocol): Declare it.
9403
ece66d65
JS
94042015-12-04 Josh Stone <jistone@redhat.com>
9405
9406 * target.h (struct target_ops) <arch_setup>: Rename to ...
9407 (struct target_ops) <post_create_inferior>: ... this.
9408 (target_arch_setup): Rename to ...
9409 (target_post_create_inferior): ... this, calling post_create_inferior.
9410 * server.c (start_inferior): Update target_arch_setup calls to
9411 target_post_create_inferior.
9412 * linux-low.c (linux_low_ptrace_options): Forward declare.
9413 (linux_arch_setup): Update its comment for general use.
9414 (linux_post_create_inferior): New, run arch_setup and setup ptrace.
9415 (struct linux_target_ops): Use linux_post_create_inferior.
9416 * lynx-low.c (struct lynx_target_ops): Update arch_setup stub comment
9417 to post_create_inferior.
9418 * nto-low.c (struct nto_target_ops): Likewise.
9419 * spu-low.c (struct spu_target_ops): Likewise.
9420 * win32-low.c (struct win32_target_ops): Likewise.
9421
e58c48b4
AT
94222015-12-03 Antoine Tremblay <antoine.tremblay@ericsson.com>
9423
9424 * linux-arm-low.c: Remove duplicate arch/arm.h include.
9425
fbec8956
AT
94262015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
9427
9428 * linux-arm-low.c (arm_reinsert_addr): Remove function.
9429 (struct linux_target_ops <breakpoint_reinsert_addr>: Set to NULL.
9430 * linux-cris-low.c (cris_reinsert_addr> Remove function.
9431 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
9432 * linux-crisv32-low.c (cris_reinsert_addr): Remove function.
9433 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
9434 * linux-mips-low.c (mips_reinsert_addr): Remove function.
9435 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
9436 * linux-nios2-low.c (nios2_reinsert_addr): Remove function.
9437 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
9438 * linux-sparc-low.c (sparc_reinsert_addr): Remove function.
9439 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
9440
9b4c5f87
AT
94412015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
9442
9443 * linux-low.c (linux_look_up_symbols): Don't call
9444 linux_supports_traceclone.
9445 * linux-low.h (thread_db_init): Remove use_events argument.
9446 * thread-db.c (thread_db_use_event): Remove global variable.
9447 (struct thread_db) <td_thr_event_enable_p>: Remove field.
9448 (struct thread_db) <td_create_bp>: Remove field.
9449 (thread_db_create_event): Remove function.
9450 (thread_db_enable_reporting): Likewise.
9451 (find_one_thread): Don't check for thread_db_use_events.
9452 (attach_thread): Likewise.
9453 (thread_db_load_search): Remove td_thr_event_enable_p initialization.
9454 (try_thread_db_load_1): Don't check for thread_db_use_events.
9455 (thread_db_init): Remove use_events argument and thread events
9456 handling.
9457 (remove_thread_event_breakpoints): Remove function.
9458 (thread_db_detach): Remove call to remove_thred_event_breakpoints.
9459
7d00775e
AT
94602015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
9461
9462 * linux-aarch64-low.c (aarch64_supports_hardware_single_step):
9463 New function.
9464 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9465 * linux-arm-low.c (arm_supports_hardware_single_step): New function.
9466 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9467 * linux-bfin-low.c (bfin_supports_hardware_single_step): New function.
9468 (struct linux_target_ops) <bfin_supports_hardware_single_step>:
9469 Initialize.
9470 * linux-crisv32-low.c (cris_supports_hardware_single_step):
9471 New function.
9472 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9473 * linux-low.c (can_hardware_single_step): Use
9474 supports_hardware_single_step.
9475 (can_software_single_step): New function.
9476 (start_step_over): Call can_software_single_step.
9477 (linux_supports_hardware_single_step): New function.
9478 (struct target_ops) <supports_software_single_step>: Initialize.
9479 * linux-low.h (struct linux_target_ops)
9480 <supports_hardware_single_step>: Initialize.
9481 * linux-m32r-low.c (m32r_supports_hardware_single_step): New function.
9482 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9483 * linux-ppc-low.c (ppc_supports_hardware_single_step): New function.
9484 (struct linux_target_ops) <supports_hardware_single_step> Initialize.
9485 * linux-s390-low.c (s390_supports_hardware_single_step): New function.
9486 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9487 * linux-sh-low.c (sh_supports_hardware_single_step): New function.
9488 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9489 * linux-tic6x-low.c (tic6x_supports_hardware_single_step): New function.
9490 (struct linux_target_ops) <tic6x_supports_hardware_single_step>:
9491 Initialize.
9492 * linux-tile-low.c (tile_supports_hardware_single_step): New function.
9493 (struct linux_target_ops) <tile_supports_hardware_single_step>:
9494 Initialize.
9495 * linux-x86-low.c (x86_supports_hardware_single_step) New function.
9496 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9497 * linux-xtensa-low.c (xtensa_supports_hardware_single_step):
9498 New function.
9499 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9500 * target.h (struct target_ops): <supports_software_single_step>:
9501 New field.
9502 (target_supports_software_single_step): New macro.
9503
2d97cd35
AT
95042015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
9505
9506 * linux-low.c (linux_wait_1): Fix pc advance condition.
9507 * mem-break.c (reinsert_breakpoint_inserted_here): New function.
9508 * mem-break.h (reinsert_breakpoint_inserted_here): New declaration.
9509
769ef81f
AT
95102015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
9511
9512 * linux-arm-low.c (arm_is_thumb_mode): New function.
9513 (arm_breakpoint_at): Use arm_is_thumb_mode.
9514 (arm_breakpoint_kind_from_current_state): New function.
9515 (struct linux_target_ops) <breakpoint_kind_from_current_state>:
9516 Initialize.
9517 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_current_state.
9518 (linux_breakpoint_kind_from_current_state): New function.
9519 (struct target_ops <breakpoint_kind_from_current_state>: Initialize.
9520 * linux-low.h (struct linux_target_ops)
9521 <breakpoint_kind_from_current_state>: New field.
9522 * target.h (struct target_ops): Likewise.
9523 (target_breakpoint_kind_from_current_state): New macro.
9524
1bebeeca
PA
95252015-11-30 Pedro Alves <palves@redhat.com>
9526
9527 * linux-low.c (linux_resume): Wake up the event loop before
9528 returning.
9529
a67a9fae
PA
95302015-11-30 Pedro Alves <palves@redhat.com>
9531
9532 * mem-break.c (check_gdb_bp_preconditions): Remove current_thread
9533 check.
9534 (set_gdb_breakpoint): If prepare_to_access_memory fails, set *ERR
9535 to -1.
9536 * target.c (struct thread_search): New structure.
9537 (thread_search_callback): New function.
9538 (prev_general_thread): New global.
9539 (prepare_to_access_memory, done_accessing_memory): New functions.
9540 * target.h (prepare_to_access_memory, done_accessing_memory):
9541 Replace macros with function declarations.
9542
f2faf941
PA
95432015-11-30 Pedro Alves <palves@redhat.com>
9544
9545 PR 14618
9546 * linux-low.c (linux_wait_1): If the last resumed thread is gone,
9547 report TARGET_WAITKIND_NO_RESUMED.
9548 * remote-utils.c (prepare_resume_reply): Handle
9549 TARGET_WAITKIND_NO_RESUMED.
9550 * server.c (report_no_resumed): New global.
9551 (handle_query) <qSupported>: Handle "no-resumed+". Report
9552 "no-resumed+" support.
9553 (resume): When the target reports TARGET_WAITKIND_NO_RESUMED, only
9554 return error if the client doesn't support no-resumed events.
9555 (push_stop_notification): New function.
9556 (handle_target_event): Use it. Report TARGET_WAITKIND_NO_RESUMED
9557 events if the client supports them.
9558
a681f9c9
PA
95592015-11-30 Pedro Alves <palves@redhat.com>
9560
9561 * linux-low.c (thread_still_has_status_pending_p): Don't check
9562 vCont;t here.
9563 (lwp_resumed): New function.
9564 (status_pending_p_callback): Return early if the LWP is not
9565 supposed to be resumed.
9566
65706a29
PA
95672015-11-30 Pedro Alves <palves@redhat.com>
9568
9569 * linux-low.c (handle_extended_wait): Assert that the LWP's
9570 waitstatus is TARGET_WAITKIND_IGNORE. If GDB wants to hear about
9571 thread create events, leave the new child's status pending.
9572 (linux_low_filter_event): If GDB wants to hear about thread exit
9573 events, leave the LWP marked dead and don't delete it.
9574 (linux_wait_for_event_filtered): Don't check for thread exit.
9575 (filter_exit_event): New function.
9576 (linux_wait_1): Use it, when returning an exit event.
9577 (linux_resume_one_lwp_throw): Assert that the LWP's
9578 waitstatus is TARGET_WAITKIND_IGNORE.
9579 * remote-utils.c (prepare_resume_reply): Handle
9580 TARGET_WAITKIND_THREAD_CREATED and TARGET_WAITKIND_THREAD_EXITED.
9581 * server.c (report_thread_events): New global.
9582 (handle_general_set): Handle QThreadEvents.
9583 (handle_query) <qSupported>: Handle and report QThreadEvents+;
9584 (handle_target_event): Handle TARGET_WAITKIND_THREAD_CREATED and
9585 TARGET_WAITKIND_THREAD_EXITED.
9586 * server.h (report_thread_events): Declare.
9587
56cf4bed
PA
95882015-11-30 Pedro Alves <palves@redhat.com>
9589
9590 * linux-low.c (resume_stopped_resumed_lwps): Don't check whether
9591 the thread's last_resume_kind was resume_stop.
9592
500c1d85
PA
95932015-11-30 Pedro Alves <palves@redhat.com>
9594
9595 * linux-low.c (linux_attach): In non-stop mode, wait for one stop
9596 before returning.
9597
de979965
PA
95982015-11-30 Pedro Alves <palves@redhat.com>
9599
9600 * server.c (handle_v_requests): Handle vCtrlC.
9601
34c65914
PA
96022015-11-30 Pedro Alves <palves@redhat.com>
9603
9604 * gdbthread.h (find_any_thread_of_pid): Declare.
9605 * inferiors.c (thread_of_pid, find_any_thread_of_pid): New
9606 functions.
9607 * server.c (handle_query): If current_thread is NULL, look for
9608 another thread of the selected process.
9609
79efa585 96102015-11-26 Daniel Colascione <dancol@dancol.org>
01a49af8 9611 Simon Marchi <simon.marchi@ericsson.com>
79efa585
SM
9612
9613 * linux-low.c (linux_target_ops): Use linux_proc_tid_get_name.
9614 * server.c (handle_qxfer_threads_worker): Refactor to include thread
9615 name in reply.
9616 * target.h (struct target_ops) <thread_name>: New field.
9617 (target_thread_name): New macro.
9618
80d82c19
JB
96192015-11-23 Joel Brobecker <brobecker@adacore.com>
9620
9621 * regcache.h (regcache_invalidate_pid): Add declaration.
9622 * regcache.c (regcache_invalidate_pid): New function, extracted
9623 from regcache_invalidate.
9624 (regcache_invalidate): Reimplement using regcache_invalidate_pid.
9625 Add trivial documentation comment.
9626 * lynx-low.c: Use regcache_invalidate_pid instead of
9627 regcache_invalidate.
9628
64da5dd5
JB
96292015-11-23 Joel Brobecker <brobecker@adacore.com>
9630
9631 * configure.ac: Do not call AC_CHECK_TYPES for Elf32_auxv_t
9632 and Elf64_auxv_t if the target is Android.
9633
37ce4055
DE
96342015-11-22 Doug Evans <xdje42@gmail.com>
9635
9636 * target.h: #include <sys/types.h>.
9637
06e03fff
PA
96382015-11-19 Pedro Alves <palves@redhat.com>
9639
9640 * linux-low.c (linux_process_qsupported): Change prototype.
9641 Adjust.
9642 * linux-low.h (struct linux_target_ops) <process_qsupported>:
9643 Change prototype.
9644 * linux-x86-low.c (x86_linux_process_qsupported): Change prototype
9645 and adjust to loop over all features.
9646 * server.c (handle_query) <qSupported>: Adjust to call
9647 target_process_qsupported once, passing it a vector of unprocessed
9648 features.
9649 * target.h (struct target_ops) <process_qsupported>: Change
9650 prototype.
9651 (target_process_qsupported): Adjust.
9652
9a084706
PA
96532015-11-19 Pedro Alves <palves@redhat.com>
9654
9655 * configure.ac (ERROR_ON_WARNING): Don't check whether in C++
9656 mode.
9657 * configure: Regenerate.
9658
dad44a1f
PA
96592015-11-19 Pedro Alves <palves@redhat.com>
9660
9661 * configure: Regenerate.
9662
231c0592
YQ
96632015-11-19 Yao Qi <yao.qi@linaro.org>
9664
9665 * linux-aarch64-low.c (emit_data_processing_reg): Change opcode
9666 type to uint32_t.
9667
6c1c9a8b
YQ
96682015-11-19 Yao Qi <yao.qi@linaro.org>
9669
9670 * linux-aarch64-low.c (enum aarch64_operand_type): New.
9671 (struct aarch64_operand): Move enum out.
9672
9caa3311
YQ
96732015-11-19 Yao Qi <yao.qi@linaro.org>
9674
9675 * linux-aarch64-low.c (aarch64_fill_fpregset): Cast buf to
9676 struct user_fpsimd_state *.
9677 (aarch64_store_fpregset): Likewise.
9678
6a69a054
YQ
96792015-11-19 Yao Qi <yao.qi@linaro.org>
9680
9681 * linux-aarch64-low.c (aarch64_fill_gregset): Cast buf to
9682 struct user_pt_regs *.
9683 (aarch64_store_gregset): Likewise.
9684
1798301e
PA
96852015-11-18 Pedro Alves <palves@redhat.com>
9686
9687 * Makefile.in (all_object_files): Add $IPA_OBJS.
9688
ce7715e2
PA
96892015-11-17 Pedro Alves <palves@redhat.com>
9690
9691 * win32-low.c (win32_resume): Use gdb_signal_from_host,
9692 GDB_SIGNAL_0 and gdb_signal_to_string.
9693
c0879059
PA
96942015-11-17 Pedro Alves <palves@redhat.com>
9695
9696 * win32-low.c (handle_output_debug_string): Remove parameter.
9697 (win32_kill): Remove our_status local and adjust call to
9698 handle_output_debug_string.
9699 (get_child_debug_event): Adjust call to
9700 handle_output_debug_string.
9701
1996e237
SM
97022015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9703
9704 * linux-mips-low.c (mips_fill_gregset): Add cast.
9705 (mips_store_gregset): Likewise.
9706 (mips_fill_fpregset): Likewise.
9707 (mips_store_fpregset): Likewise.
9708
cbec665b
SM
97092015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9710
9711 * linux-mips-low.c (mips_add_watchpoint): Rename private to
9712 priv.
9713
eb3e3c67
SM
97142015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9715
9716 * linux-mips-low.c (mips_linux_new_thread): Change type of
9717 watch_type to enum target_hw_bp_type.
9718
171de4b8
SM
97192015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9720
9721 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type):
9722 Change return type to arm_hwbp_type.
9723
04248ead
SM
97242015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9725
9726 * linux-aarch32-low.c (arm_fill_gregset): Add cast.
9727 (arm_store_gregset): Likewise.
9728 * linux-arm-low.c (arm_get_hwcap): Likewise.
9729 (arm_read_description): Likewise.
9730
04b3479c
SM
97312015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9732
9733 * linux-aarch32-low.c (aarch32_regsets): Use NULL_REGSET.
9734
2bc84e8a
SM
97352015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9736
9737 * linux-ppc-low.c (ppc_get_hwcap): Add cast.
9738 (ppc_fill_vsxregset): Likewise.
9739 (ppc_store_vsxregset): Likewise.
9740 (ppc_fill_vrregset): Likewise.
9741 (ppc_store_vrregset): Likewise.
9742 (ppc_fill_evrregset): Likewise.
9743 (ppc_store_evrregset): Likewise.
9744
e6c5bb05
SM
97452015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9746
9747 * linux-ppc-low.c (ppc_usrregs_info): Remove
9748 forward-declaration.
9749 (ppc_arch_setup): Move lower in file.
9750
7ea45d72
SM
97512015-10-30 Simon Marchi <simon.marchi@ericsson.com>
9752
9753 * proc-service.c (ps_pdread): Change CORE_ADDR cast to uintptr_t.
9754 (ps_pdwrite): Likewise.
9755
69291610
HW
97562015-10-29 Henrik Wallin <henrik.wallin@windriver.com>
9757
9758 * linux-arm-low.c (arm_new_thread): Move pointer dereference
9759 to after assert checks.
9760
b42945fd
SM
97612015-10-29 Simon Marchi <simon.marchi@ericsson.com>
9762
9763 * proc-service.c (ps_pdread): Add/adjust casts.
9764 (ps_pdwrite): Add/adjust casts.
9765
d6f85c84
SM
97662015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
9767
9768 * server.c (handle_search_memory_1): Cast return value of
9769 memmem.
9770
f98cd059
SM
97712015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
9772
9773 * server.c (write_qxfer_response): Change type of data to
9774 gdb_byte *.
9775
d2412fa5
PA
97762015-10-29 Pedro Alves <palves@redhat.com>
9777
9778 * mem-break.c (Z_packet_to_bkpt_type): Add cast.
9779
c17414a2
PA
97802015-10-29 Pedro Alves <palves@redhat.com>
9781
9782 * tracepoint.c (clear_installed_tracepoints): Add casts.
9783
e053fbc4
PA
97842015-10-29 Pedro Alves <palves@redhat.com>
9785
9786 * server.c (handle_v_cont, process_serial_event): Add enum
9787 gdb_signal casts to signal parsing code.
9788
add67df8
PA
97892015-10-29 Pedro Alves <palves@redhat.com>
9790
9791 * linux-low.h (NULL_REGSET): Define.
9792 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
9793 * linux-arm-low.c (arm_regsets): Likewise.
9794 * linux-crisv32-low.c (cris_regsets): Likewise.
9795 * linux-m68k-low.c (m68k_regsets): Likewise.
9796 * linux-mips-low.c (mips_regsets): Likewise.
9797 * linux-nios2-low.c (nios2_regsets): Likewise.
9798 * linux-ppc-low.c (ppc_regsets): Likewise.
9799 * linux-s390-low.c (s390_regsets): Likewise.
9800 * linux-sh-low.c (sh_regsets): Likewise.
9801 * linux-sparc-low.c (sparc_regsets): Likewise.
9802 * linux-tic6x-low.c (tic6x_regsets): Likewise.
9803 * linux-tile-low.c (tile_regsets): Likewise.
9804 * linux-x86-low.c (x86_regsets): Likewise.
9805 * linux-xtensa-low.c (xtensa_regsets): Likewise.
9806
50bc912a
PA
98072015-10-29 Pedro Alves <palves@redhat.com>
9808
9809 * linux-low.h (NULL_REGSET): Define.
9810 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
9811 * linux-arm-low.c (arm_regsets): Likewise.
9812 * linux-crisv32-low.c (cris_regsets): Likewise.
9813 * linux-m68k-low.c (m68k_regsets): Likewise.
9814 * linux-mips-low.c (mips_regsets): Likewise.
9815 * linux-nios2-low.c (nios2_regsets): Likewise.
9816 * linux-ppc-low.c (ppc_regsets): Likewise.
9817 * linux-s390-low.c (s390_regsets): Likewise.
9818 * linux-sh-low.c (sh_regsets): Likewise.
9819 * linux-sparc-low.c (sparc_regsets): Likewise.
9820 * linux-tic6x-low.c (tic6x_regsets): Likewise.
9821 * linux-tile-low.c (tile_regsets): Likewise.
9822 * linux-x86-low.c (x86_regsets): Likewise.
9823 * linux-xtensa-low.c (xtensa_regsets): Likewise.
9824
682b2546
DE
98252015-10-26 Doug Evans <dje@google.com>
9826
9827 * linux-low.c (__SIGRTMIN): Move to nat/linux-nat.h.
9828
963843d4
DE
98292015-10-26 Doug Evans <dje@google.com>
9830
9831 * linux-low.c (W_STOPCODE): Moved to common/gdb_wait.h.
9832
d41401ac
DE
98332015-10-26 Doug Evans <dje@google.com>
9834
9835 * thread-db.c (find_one_thread): Cast ti.ti_tid to unsigned long
9836 for debug_printf.
9837 (attach_thread, find_new_threads_callback): Ditto.
9838
3db28855
AT
98392015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
9840
9841 * mem-break.h (set_breakpoint_data): Remove.
9842
fb78e89c
AT
98432015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
9844
9845 * nto-low.c (nto_sw_breakpoint_from_kind): New function.
9846 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
9847 (initialize_low): Remove set_breakpoint_data call.
9848 * spu-low.c (spu_sw_breakpoint_from_kind): New function.
9849 (struct target_ops) <sw_breakpoint_from_kind>: Iniitalize.
9850 (initialize_low): Remove set_breakpoint_data call.
9851 * win32-low.c (win32_sw_breakpoint_from_kind): New function.
9852 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
9853 (initialize_low): Remove set_breakpoint_data call.
9854
2e6ee069
AT
98552015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
9856
9857 * linux-low.c (default_breakpoint_kind_from_pc): Move to target.c.
9858 * mem-break.c (set_breakpoint_at): Use target_breakpoint_kind_from_pc.
9859 * target.c (default_breakpoint_kind_from_pc): Moved from linux-low.c
9860 * target.h (target_breakpoint_kind_from_pc): New macro.
9861
1652a986
AT
98622015-10-22 Antoine Tremblay <antoine.tremblay@ericsson.com>
9863
9864 * linux-low.c (default_breakpoint_kind_from_pc): New function.
9865 (linux_breakpoint_kind_from_pc): Use default_breakpoint_kind_from_pc for
9866 the default breakpoint kind.
9867
abeead09
AT
98682015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9869
9870 * linux-arm-low.c (arm_supports_z_point_type): Add software
9871 breakpoint support.
9872
b0b4b501
AT
98732015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9874
9875 * linux-arm-low.c: Refactor breakpoint definitions.
9876 (arm_breakpoint_at): Adjust for arm_abi_breakpoint.
9877 (arm_sw_breakpoint_from_kind): Adjust for arm_breakpoint.
9878
8689682c
AT
98792015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9880
9881 * Makefile.in: Add arm.c/o.
9882 * configure.srv: Likewise.
9883 * linux-arm-low.c (arm_breakpoint_kinds): New enum.
9884 (arm_breakpoint_kind_from_pc): New function.
9885 (arm_sw_breakpoint_from_kind): Return proper kind.
9886 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize.
9887
27165294
AT
98882015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9889
9890 * linux-low.c (initialize_low): Ajdust for breakpoint global variables
9891 removal.
9892 * mem-break.c : Remove breakpoint_data/breakpoint_len global variables.
9893 (struct raw_breakpoint) <size>: Remove.
9894 (struct raw_breakpoint) <kind>: Add.
9895 (bp_size): New function.
9896 (bp_opcode): Likewise.
9897 (find_raw_breakpoint_at): Adjust for kind.
9898 (insert_memory_breakpoint): Adjust for kind call bp_size,bp_opcode.
9899 (remove_memory_breakpoint): Adjust for kind call bp_size.
9900 (set_raw_breakpoint_at): Adjust for kind.
9901 (set_breakpoint): Likewise.
9902 (set_breakpoint_at): Call breakpoint_kind_from_pc.
9903 (delete_raw_breakpoint): Adjust for kind.
9904 (delete_breakpoint): Likewise.
9905 (find_gdb_breakpoint): Likewise.
9906 (set_gdb_breakpoint_1): Likewise.
9907 (set_gdb_breakpoint): Likewise.
9908 (delete_gdb_breakpoint_1): Likewise.
9909 (delete_gdb_breakpoint): Likewise.
9910 (uninsert_raw_breakpoint): Likewise.
9911 (reinsert_raw_breakpoint): Likewise.
9912 (set_breakpoint_data): Remove.
9913 (validate_inserted_breakpoint): Adjust for kind call bp_size,bp_opcode.
9914 (check_mem_read): Adjust for kind call bp_size.
9915 (check_mem_write): Adjust for kind call bp_size,bp_opcode.
9916 (clone_one_breakpoint): Adjust for kind.
9917 * mem-break.h (set_gdb_breakpoint): Likewise.
9918 (delete_gdb_breakpoint): Likewise.
9919 * server.c (process_serial_event): Likewise.
9920
dd373349
AT
99212015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9922
9923 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): New function.
9924 (struct linux_target_ops) <breakpoint>: Remove.
9925 (struct linux_target_ops) <breakpoint_len>: Remove.
9926 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9927 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9928 * linux-arm-low.c (arm_breakpoint_kind_from_pc): New function.
9929 (arm_sw_breakpoint_from_kind): New function.
9930 * linux-bfin-low.c (bfin_sw_breakpoint_from_kind): New function.
9931 (struct linux_target_ops) <breakpoint>: Remove.
9932 (struct linux_target_ops) <breakpoint_len>: Remove.
9933 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9934 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9935 * linux-cris-low.c (cris_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-crisv32-low.c (cris_sw_breakpoint_from_kind): New function.
9941 (struct linux_target_ops) <breakpoint>: Remove.
9942 (struct linux_target_ops) <breakpoint_len>: Remove.
9943 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9944 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9945 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_pc
9946 and sw_breakpoint_from_kind to increment the pc.
9947 (linux_breakpoint_kind_from_pc): New function.
9948 (linux_sw_breakpoint_from_kind): New function.
9949 (struct target_ops) <sw_breakpoint_from_kind>: Initialize field.
9950 (initialize_low): Call breakpoint_kind_from_pc and
9951 sw_breakpoint_from_kind to replace breakpoint_data/len.
9952 * linux-low.h (struct linux_target_ops) <breakpoint_kind_from_pc>:
9953 New field.
9954 (struct linux_target_ops) <sw_breakpoint_from_kind>: Likewise.
9955 * linux-m32r-low.c (m32r_sw_breakpoint_from_kind): New function.
9956 (struct linux_target_ops) <breakpoint>: Remove.
9957 (struct linux_target_ops) <breakpoint_len>: Remove.
9958 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9959 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9960 * linux-m68k-low.c (m68k_sw_breakpoint_from_kind): New function.
9961 (struct linux_target_ops) <breakpoint>: Remove.
9962 (struct linux_target_ops) <breakpoint_len>: Remove.
9963 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9964 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9965 * linux-mips-low.c (mips_sw_breakpoint_from_kind): New function.
9966 (struct linux_target_ops) <breakpoint>: Remove.
9967 (struct linux_target_ops) <breakpoint_len>: Remove.
9968 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9969 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9970 * linux-nios2-low.c (nios2_sw_breakpoint_from_kind): New function.
9971 (struct linux_target_ops) <breakpoint>: Remove.
9972 (struct linux_target_ops) <breakpoint_len>: Remove.
9973 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9974 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9975 * linux-ppc-low.c (ppc_sw_breakpoint_from_kind): New function.
9976 (struct linux_target_ops) <breakpoint>: Remove.
9977 (struct linux_target_ops) <breakpoint_len>: Remove.
9978 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9979 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9980 * linux-s390-low.c (s390_sw_breakpoint_from_kind): New function.
9981 (struct linux_target_ops) <breakpoint>: Remove.
9982 (struct linux_target_ops) <breakpoint_len>: Remove.
9983 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9984 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9985 * linux-sh-low.c (sh_sw_breakpoint_from_kind): New function.
9986 (struct linux_target_ops) <breakpoint>: Remove.
9987 (struct linux_target_ops) <breakpoint_len>: Remove.
9988 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9989 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9990 * linux-sparc-low.c (sparc_sw_breakpoint_from_kind): New function.
9991 (struct linux_target_ops) <breakpoint>: Remove.
9992 (struct linux_target_ops) <breakpoint_len>: Remove.
9993 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9994 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9995 * linux-tic6x-low.c (tic6x_sw_breakpoint_from_kind): New function.
9996 (struct linux_target_ops) <breakpoint>: Remove.
9997 (struct linux_target_ops) <breakpoint_len>: Remove.
9998 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9999 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
10000 * linux-tile-low.c (tile_sw_breakpoint_from_kind): New function.
10001 * linux-x86-low.c (x86_sw_breakpoint_from_kind): New function.
10002 (struct linux_target_ops) <breakpoint>: Remove.
10003 (struct linux_target_ops) <breakpoint_len>: Remove.
10004 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
10005 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
10006 * linux-xtensa-low.c (xtensa_sw_breakpoint_from_kind) New function.
10007 (struct linux_target_ops) <breakpoint>: Remove.
10008 (struct linux_target_ops) <breakpoint_len>: Remove.
10009 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
10010 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
10011
4cd98a19
AT
100122015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
10013
10014 * linux-cris-low.c (cris_get_pc): Remove void arg.
10015
774ee6d2
AR
100162015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
10017
10018 * gdbserver/nto-low.c (nto_insert_point, nto_remove_point): Fix
10019 variable name.
10020
833dcd29
AR
100212015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
10022
10023 * inferiors.c (thread_pid_matches_callback): New function.
10024 (find_thread_process): New function.
10025 (remove_thread): Reset current_thread.
10026 (remove_process): Assert threads have been removed first.
10027
8d689ee5
YQ
100282015-10-15 Yao Qi <yao.qi@linaro.org>
10029
10030 * linux-aarch64-low.c (aarch64_insert_point): Set len to 2
10031 if it is 3.
10032 (aarch64_remove_point): Likewise.
10033 * regcache.c (regcache_register_size): New function.
10034
1c2e1515
YQ
100352015-10-12 Yao Qi <yao.qi@linaro.org>
10036
10037 * linux-aarch64-low.c: Update all callers as emit_load_store
10038 is renamed to aarch64_emit_load_store.
10039
e1c587c3
YQ
100402015-10-12 Yao Qi <yao.qi@linaro.org>
10041
10042 * linux-aarch64-low.c: Update all callers of function renaming
10043 from emit_insn to aarch64_emit_insn.
10044
b6542f81
YQ
100452015-10-12 Yao Qi <yao.qi@linaro.org>
10046
10047 * linux-aarch64-low.c (enum aarch64_opcodes): Move to
10048 arch/aarch64-insn.h.
10049 (struct aarch64_memory_operand): Likewise.
10050 (ENCODE): Likewise.
10051 (emit_insn): Move to arch/aarch64-insn.c.
10052 (emit_b, emit_bcond, emit_cb, emit_tb): Remove.
10053 (emit_load_store): Move to arch/aarch64-insn.c.
10054 (emit_ldr, emit_ldrb, emit_ldrsw, emit_nop): Remove.
10055 (can_encode_int32): Remove.
10056
246994ce
YQ
100572015-10-12 Yao Qi <yao.qi@linaro.org>
10058
10059 * linux-aarch64-low.c (extract_signed_bitfield): Remove.
10060 (aarch64_decode_ldr_literal): Move to gdb/arch/aarch64-insn.c.
10061 (aarch64_relocate_instruction): Likewise.
10062 (struct aarch64_insn_data): Move to gdb/arch/aarch64-insn.h.
10063 (struct aarch64_insn_visitor): Likewise.
10064
0badd99f
YQ
100652015-10-12 Yao Qi <yao.qi@linaro.org>
10066
10067 * linux-aarch64-low.c (struct aarch64_insn_data): New.
10068 (struct aarch64_insn_visitor): New.
10069 (struct aarch64_insn_relocation_data): New.
10070 (aarch64_ftrace_insn_reloc_b): New function.
10071 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
10072 (aarch64_ftrace_insn_reloc_cb): Likewise.
10073 (aarch64_ftrace_insn_reloc_tb): Likewise.
10074 (aarch64_ftrace_insn_reloc_adr): Likewise.
10075 (aarch64_ftrace_insn_reloc_ldr_literal): Likewise.
10076 (aarch64_ftrace_insn_reloc_others): Likewise.
10077 (visitor): New.
10078 (aarch64_relocate_instruction): Use visitor.
10079
dfaffe9d
YQ
100802015-10-12 Yao Qi <yao.qi@linaro.org>
10081
10082 * linux-aarch64-low.c (aarch64_relocate_instruction): Return
10083 int. Add argument buf.
10084 (aarch64_install_fast_tracepoint_jump_pad): Pass buf to
10085 aarch64_relocate_instruction.
10086
70b439f0
YQ
100872015-10-12 Yao Qi <yao.qi@linaro.org>
10088
10089 * linux-aarch64-low.c (aarch64_relocate_instruction): Add
10090 argument insn. Remove local variable insn. Don't call
10091 target_read_uint32.
10092 (aarch64_install_fast_tracepoint_jump_pad): Call
10093 target_read_uint32.
10094
7781c06f
YQ
100952015-09-30 Yao Qi <yao.qi@linaro.org>
10096
10097 * linux-aarch64-low.c (emit_movk): Shorten a long line.
10098 (emit_load_store_pair): Likewise.
10099
9a3c8263
SM
101002015-09-25 Simon Marchi <simon.marchi@ericsson.com>
10101
10102 * dll.c (match_dll): Add cast(s).
10103 (unloaded_dll): Likewise.
10104 * linux-low.c (second_thread_of_pid_p): Likewise.
10105 (delete_lwp_callback): Likewise.
10106 (count_events_callback): Likewise.
10107 (select_event_lwp_callback): Likewise.
10108 (linux_set_resume_request): Likewise.
10109 * server.c (accumulate_file_name_length): Likewise.
10110 (emit_dll_description): Likewise.
10111 (handle_qxfer_threads_worker): Likewise.
10112 (visit_actioned_threads): Likewise.
10113 * thread-db.c (any_thread_of): Likewise.
10114 * tracepoint.c (same_process_p): Likewise.
10115 (match_blocktype): Likewise.
10116 (build_traceframe_info_xml): Likewise.
10117
224c3ddb
SM
101182015-09-25 Simon Marchi <simon.marchi@ericsson.com>
10119
10120 * ax.c (gdb_parse_agent_expr): Add cast to allocation result
10121 assignment.
10122 (gdb_unparse_agent_expr): Likewise.
10123 * hostio.c (require_data): Likewise.
10124 (handle_pread): Likewise.
10125 * linux-low.c (disable_regset): Likewise.
10126 (fetch_register): Likewise.
10127 (store_register): Likewise.
10128 (get_dynamic): Likewise.
10129 (linux_qxfer_libraries_svr4): Likewise.
10130 * mem-break.c (delete_fast_tracepoint_jump): Likewise.
10131 (set_fast_tracepoint_jump): Likewise.
10132 (uninsert_fast_tracepoint_jumps_at): Likewise.
10133 (reinsert_fast_tracepoint_jumps_at): Likewise.
10134 (validate_inserted_breakpoint): Likewise.
10135 (clone_agent_expr): Likewise.
10136 * regcache.c (init_register_cache): Likewise.
10137 * remote-utils.c (putpkt_binary_1): Likewise.
10138 (decode_M_packet): Likewise.
10139 (decode_X_packet): Likewise.
10140 (look_up_one_symbol): Likewise.
10141 (relocate_instruction): Likewise.
10142 (monitor_output): Likewise.
10143 * server.c (handle_search_memory): Likewise.
10144 (handle_qxfer_exec_file): Likewise.
10145 (handle_qxfer_libraries): Likewise.
10146 (handle_qxfer): Likewise.
10147 (handle_query): Likewise.
10148 (handle_v_cont): Likewise.
10149 (handle_v_run): Likewise.
10150 (captured_main): Likewise.
10151 * target.c (write_inferior_memory): Likewise.
10152 * thread-db.c (try_thread_db_load_from_dir): Likewise.
10153 * tracepoint.c (init_trace_buffer): Likewise.
10154 (add_tracepoint_action): Likewise.
10155 (add_traceframe): Likewise.
10156 (add_traceframe_block): Likewise.
10157 (cmd_qtdpsrc): Likewise.
10158 (cmd_qtdv): Likewise.
10159 (cmd_qtstatus): Likewise.
10160 (response_source): Likewise.
10161 (response_tsv): Likewise.
10162 (cmd_qtnotes): Likewise.
10163 (gdb_collect): Likewise.
10164 (initialize_tracepoint): Likewise.
10165
afbe19f8
PL
101662015-09-21 Pierre Langlois <pierre.langlois@arm.com>
10167
10168 * linux-aarch64-low-.c: Include ax.h and tracepoint.h.
10169 (enum aarch64_opcodes) <RET>, <SUBS>, <AND>, <ORR>, <ORN>,
10170 <EOR>, <LSLV>, <LSRV>, <ASRV>, <SBFM>, <UBFM>, <CSINC>, <MUL>,
10171 <NOP>: New.
10172 (enum aarch64_condition_codes): New enum.
10173 (w0): New static global.
10174 (fp): Likewise.
10175 (lr): Likewise.
10176 (struct aarch64_memory_operand) <type>: New
10177 MEMORY_OPERAND_POSTINDEX type.
10178 (postindex_memory_operand): New helper function.
10179 (emit_ret): New function.
10180 (emit_load_store_pair): New function, factored out of emit_stp
10181 with support for MEMORY_OPERAND_POSTINDEX.
10182 (emit_stp): Rewrite using emit_load_store_pair.
10183 (emit_ldp): New function.
10184 (emit_load_store): Likewise.
10185 (emit_ldr): Mention post-index instruction in comment.
10186 (emit_ldrh): New function.
10187 (emit_ldrb): New function.
10188 (emit_ldrsw): Mention post-index instruction in comment.
10189 (emit_str): Likewise.
10190 (emit_subs): New function.
10191 (emit_cmp): Likewise.
10192 (emit_and): Likewise.
10193 (emit_orr): Likewise.
10194 (emit_orn): Likewise.
10195 (emit_eor): Likewise.
10196 (emit_mvn): Likewise.
10197 (emit_lslv): Likewise.
10198 (emit_lsrv): Likewise.
10199 (emit_asrv): Likewise.
10200 (emit_mul): Likewise.
10201 (emit_sbfm): Likewise.
10202 (emit_sbfx): Likewise.
10203 (emit_ubfm): Likewise.
10204 (emit_ubfx): Likewise.
10205 (emit_csinc): Likewise.
10206 (emit_cset): Likewise.
10207 (emit_nop): Likewise.
10208 (emit_ops_insns): New helper function.
10209 (emit_pop): Likewise.
10210 (emit_push): Likewise.
10211 (aarch64_emit_prologue): New function.
10212 (aarch64_emit_epilogue): Likewise.
10213 (aarch64_emit_add): Likewise.
10214 (aarch64_emit_sub): Likewise.
10215 (aarch64_emit_mul): Likewise.
10216 (aarch64_emit_lsh): Likewise.
10217 (aarch64_emit_rsh_signed): Likewise.
10218 (aarch64_emit_rsh_unsigned): Likewise.
10219 (aarch64_emit_ext): Likewise.
10220 (aarch64_emit_log_not): Likewise.
10221 (aarch64_emit_bit_and): Likewise.
10222 (aarch64_emit_bit_or): Likewise.
10223 (aarch64_emit_bit_xor): Likewise.
10224 (aarch64_emit_bit_not): Likewise.
10225 (aarch64_emit_equal): Likewise.
10226 (aarch64_emit_less_signed): Likewise.
10227 (aarch64_emit_less_unsigned): Likewise.
10228 (aarch64_emit_ref): Likewise.
10229 (aarch64_emit_if_goto): Likewise.
10230 (aarch64_emit_goto): Likewise.
10231 (aarch64_write_goto_address): Likewise.
10232 (aarch64_emit_const): Likewise.
10233 (aarch64_emit_call): Likewise.
10234 (aarch64_emit_reg): Likewise.
10235 (aarch64_emit_pop): Likewise.
10236 (aarch64_emit_stack_flush): Likewise.
10237 (aarch64_emit_zero_ext): Likewise.
10238 (aarch64_emit_swap): Likewise.
10239 (aarch64_emit_stack_adjust): Likewise.
10240 (aarch64_emit_int_call_1): Likewise.
10241 (aarch64_emit_void_call_2): Likewise.
10242 (aarch64_emit_eq_goto): Likewise.
10243 (aarch64_emit_ne_goto): Likewise.
10244 (aarch64_emit_lt_goto): Likewise.
10245 (aarch64_emit_le_goto): Likewise.
10246 (aarch64_emit_gt_goto): Likewise.
10247 (aarch64_emit_ge_got): Likewise.
10248 (aarch64_emit_ops_impl): New static global variable.
10249 (aarch64_emit_ops): New target function, return
10250 &aarch64_emit_ops_impl.
10251 (struct linux_target_ops): Install it.
10252
bb903df0
PL
102532015-09-21 Pierre Langlois <pierre.langlois@arm.com>
10254
10255 * Makefile.in (linux-aarch64-ipa.o, aarch64-ipa.o): New rules.
10256 * configure.srv (aarch64*-*-linux*): Add linux-aarch64-ipa.o and
10257 aarch64-ipa.o.
10258 * linux-aarch64-ipa.c: New file.
10259 * linux-aarch64-low.c: Include arch/aarch64-insn.h, inttypes.h
10260 and endian.h.
10261 (aarch64_get_thread_area): New target method.
10262 (extract_signed_bitfield): New helper function.
10263 (aarch64_decode_ldr_literal): New function.
10264 (enum aarch64_opcodes): New enum.
10265 (struct aarch64_register): New struct.
10266 (struct aarch64_operand): New struct.
10267 (x0): New static global.
10268 (x1): Likewise.
10269 (x2): Likewise.
10270 (x3): Likewise.
10271 (x4): Likewise.
10272 (w2): Likewise.
10273 (ip0): Likewise.
10274 (sp): Likewise.
10275 (xzr): Likewise.
10276 (aarch64_register): New helper function.
10277 (register_operand): Likewise.
10278 (immediate_operand): Likewise.
10279 (struct aarch64_memory_operand): New struct.
10280 (offset_memory_operand): New helper function.
10281 (preindex_memory_operand): Likewise.
10282 (enum aarch64_system_control_registers): New enum.
10283 (ENCODE): New macro.
10284 (emit_insn): New helper function.
10285 (emit_b): New function.
10286 (emit_bcond): Likewise.
10287 (emit_cb): Likewise.
10288 (emit_tb): Likewise.
10289 (emit_blr): Likewise.
10290 (emit_stp): Likewise.
10291 (emit_ldp_q_offset): Likewise.
10292 (emit_stp_q_offset): Likewise.
10293 (emit_load_store): Likewise.
10294 (emit_ldr): Likewise.
10295 (emit_ldrsw): Likewise.
10296 (emit_str): Likewise.
10297 (emit_ldaxr): Likewise.
10298 (emit_stxr): Likewise.
10299 (emit_stlr): Likewise.
10300 (emit_data_processing_reg): Likewise.
10301 (emit_data_processing): Likewise.
10302 (emit_add): Likewise.
10303 (emit_sub): Likewise.
10304 (emit_mov): Likewise.
10305 (emit_movk): Likewise.
10306 (emit_mov_addr): Likewise.
10307 (emit_mrs): Likewise.
10308 (emit_msr): Likewise.
10309 (emit_sevl): Likewise.
10310 (emit_wfe): Likewise.
10311 (append_insns): Likewise.
10312 (can_encode_int32_in): New helper function.
10313 (aarch64_relocate_instruction): New function.
10314 (aarch64_install_fast_tracepoint_jump_pad): Likewise.
10315 (aarch64_get_min_fast_tracepoint_insn_len): Likewise.
10316 (struct linux_target_ops): Install aarch64_get_thread_area,
10317 aarch64_install_fast_tracepoint_jump_pad and
10318 aarch64_get_min_fast_tracepoint_insn_len.
10319
787749ea
PL
103202015-09-21 Pierre Langlois <pierre.langlois@arm.com>
10321
10322 * Makefile.in (aarch64-insn.o): New rule.
10323 * configure.srv (aarch64*-*-linux*): Add aarch64-insn.o.
10324
9812b2e6
YQ
103252015-09-21 Yao Qi <yao.qi@linaro.org>
10326
10327 * ax.c [!IN_PROCESS_AGENT] (gdb_agent_op_sizes): Define it.
10328
18fe412b
YQ
103292015-09-21 Yao Qi <yao.qi@linaro.org>
10330
10331 * tracepoint.c (max_jump_pad_size): Remove.
10332
a0cc84cd
YQ
103332015-09-18 Yao Qi <yao.qi@linaro.org>
10334
10335 * linux-aarch64-low.c: Don't include sys/uio.h.
10336 (ps_get_thread_area): Call aarch64_ps_get_thread_area.
10337
d78908cf
WW
103382015-09-16 Wei-cheng Wang <cole945@gmail.com>
10339
10340 * tracepoint.c (eval_result_type): Change prototype.
10341 (condition_true_at_tracepoint): Fix argument to compiled_cond.
10342
d57e0d50
PA
103432015-09-15 Pedro Alves <palves@redhat.com>
10344
10345 * remote-utils.c (prepare_resume_reply) <TARGET_WAITKIND_EXECD>:
10346 Check whether to report exec events instead of checking whether
10347 multiprocess is enabled.
10348
5a676acc
PA
103492015-09-15 Pedro Alves <palves@redhat.com>
10350
10351 PR remote/18965
10352 * remote-utils.c (prepare_resume_reply): Merge
10353 TARGET_WAITKIND_VFORK_DONE switch case with the
10354 TARGET_WAITKIND_FORKED case.
10355
7c5d0fad
YQ
103562015-09-15 Yao Qi <yao.qi@linaro.org>
10357
10358 * server.c (handle_query): Check string comparison using
10359 "else if" instead of "if".
10360
750ce8d1
YQ
103612015-09-15 Yao Qi <yao.qi@linaro.org>
10362
10363 * server.c (vCont_supported): New global variable.
10364 (handle_query): Set vCont_supported to 1 if "vContSupported+"
10365 matches. Append ";vContSupported+" to own_buf.
10366 (handle_v_requests): Append ";s;S" to own_buf if target supports
10367 hardware single step or vCont_supported is false.
10368 (capture_main): Set vCont_supported to zero.
10369
70b90b91
YQ
103702015-09-15 Yao Qi <yao.qi@linaro.org>
10371
10372 * linux-low.c (linux_supports_conditional_breakpoints): Rename
10373 it to ...
10374 (linux_supports_hardware_single_step): ... New function.
10375 (linux_target_ops): Update.
10376 * lynx-low.c (lynx_target_ops): Set field
10377 supports_hardware_single_step to target_can_do_hardware_single_step.
10378 * nto-low.c (nto_target_ops): Likewise.
10379 * spu-low.c (spu_target_ops): Likewise.
10380 * win32-low.c (win32_target_ops): Likewise.
10381 * target.c (target_can_do_hardware_single_step): New function.
10382 * target.h (struct target_ops) <supports_conditional_breakpoints>:
10383 Remove. <supports_hardware_single_step>: New field.
10384 (target_supports_conditional_breakpoints): Remove.
10385 (target_supports_hardware_single_step): New macro.
10386 (target_can_do_hardware_single_step): Declare.
10387 * server.c (handle_query): Use target_supports_hardware_single_step
10388 instead of target_supports_conditional_breakpoints.
10389
ade90bde
YQ
103902015-09-15 Yao Qi <yao.qi@linaro.org>
10391
10392 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): New
10393 function.
10394 (struct linux_target_ops the_low_target): Install
10395 aarch64_linux_siginfo_fixup.
10396
94585166
DB
103972015-09-11 Don Breazeal <donb@codesourcery.com>
10398 Luis Machado <lgustavo@codesourcery.com>
10399
10400 * linux-low.c (linux_mourn): Static declaration.
10401 (linux_arch_setup): Move in front of
10402 handle_extended_wait.
10403 (linux_arch_setup_thread): New function.
10404 (handle_extended_wait): Handle exec events. Call
10405 linux_arch_setup_thread. Make event_lwp argument a
10406 pointer-to-a-pointer.
10407 (check_zombie_leaders): Do not check stopped threads.
10408 (linux_low_ptrace_options): Add PTRACE_O_TRACEEXEC.
10409 (linux_low_filter_event): Add lwp and thread for exec'ing
10410 non-leader thread if leader thread has been deleted.
10411 Refactor code into linux_arch_setup_thread and call it.
10412 Pass child lwp pointer by reference to handle_extended_wait.
10413 (linux_wait_for_event_filtered): Update comment.
10414 (linux_wait_1): Prevent clobbering exec event status.
10415 (linux_supports_exec_events): New function.
10416 (linux_target_ops) <supports_exec_events>: Initialize new member.
10417 * lynx-low.c (lynx_target_ops) <supports_exec_events>: Initialize
10418 new member.
10419 * remote-utils.c (prepare_resume_reply): New stop reason 'exec'.
10420 * server.c (report_exec_events): New global variable.
10421 (handle_query): Handle qSupported query for exec-events feature.
10422 (captured_main): Initialize report_exec_events.
10423 * server.h (report_exec_events): Declare new global variable.
10424 * target.h (struct target_ops) <supports_exec_events>: New
10425 member.
10426 (target_supports_exec_events): New macro.
10427 * win32-low.c (win32_target_ops) <supports_exec_events>:
10428 Initialize new member.
10429
0568462b
MM
104302015-09-09 Markus Metzger <markus.t.metzger@intel.com>
10431
10432 * linux-low.c (linux_low_enable_btrace): Remove.
10433 (linux_target_ops): Replace linux_low_enable_btrace with
10434 linux_enable_btrace.
10435
39edd165
YQ
104362015-09-03 Yao Qi <yao.qi@linaro.org>
10437
10438 * linux-aarch64-low.c (aarch64_insert_point): Call
10439 aarch64_handle_watchpoint if aarch64_linux_region_ok_for_watchpoint
10440 returns true.
10441
1db33b5a
UW
104422015-08-27 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
10443
10444 * linux-low.c (check_stopped_by_breakpoint): Use
10445 GDB_ARCH_IS_TRAP_BRKPT instead of GDB_ARCH_TRAP_BRKPT.
10446
ab290430
PA
104472015-08-27 Pedro Alves <palves@redhat.com>
10448
10449 * proc-service.c (ps_pdwrite): Return PS_ERR/PS_OK explicily.
10450
8d749320
SM
104512015-08-26 Simon Marchi <simon.marchi@ericsson.com>
10452
6711b7f8
SM
10453 * ax.c (gdb_parse_agent_expr): Replace xmalloc-family function with
10454 the XNEW-family equivalent.
8d749320
SM
10455 (compile_bytecodes): Likewise.
10456 * dll.c (loaded_dll): Likewise.
10457 * event-loop.c (append_callback_event): Likewise.
10458 (create_file_handler): Likewise.
10459 (create_file_event): Likewise.
10460 * hostio.c (handle_open): Likewise.
10461 * inferiors.c (add_thread): Likewise.
10462 (add_process): Likewise.
10463 * linux-aarch64-low.c (aarch64_linux_new_process): Likewise.
10464 * linux-arm-low.c (arm_new_process): Likewise.
10465 (arm_new_thread): Likewise.
10466 * linux-low.c (add_to_pid_list): Likewise.
10467 (linux_add_process): Likewise.
10468 (handle_extended_wait): Likewise.
10469 (add_lwp): Likewise.
10470 (enqueue_one_deferred_signal): Likewise.
10471 (enqueue_pending_signal): Likewise.
10472 (linux_resume_one_lwp_throw): Likewise.
10473 (linux_resume_one_thread): Likewise.
10474 (linux_read_memory): Likewise.
10475 (linux_write_memory): Likewise.
10476 * linux-mips-low.c (mips_linux_new_process): Likewise.
10477 (mips_linux_new_thread): Likewise.
10478 (mips_add_watchpoint): Likewise.
10479 * linux-x86-low.c (initialize_low_arch): Likewise.
10480 * lynx-low.c (lynx_add_process): Likewise.
10481 * mem-break.c (set_raw_breakpoint_at): Likewise.
10482 (set_breakpoint): Likewise.
10483 (add_condition_to_breakpoint): Likewise.
10484 (add_commands_to_breakpoint): Likewise.
10485 (clone_agent_expr): Likewise.
10486 (clone_one_breakpoint): Likewise.
10487 * regcache.c (new_register_cache): Likewise.
10488 * remote-utils.c (look_up_one_symbol): Likewise.
10489 * server.c (queue_stop_reply): Likewise.
10490 (start_inferior): Likewise.
10491 (queue_stop_reply_callback): Likewise.
10492 (handle_target_event): Likewise.
10493 * spu-low.c (fetch_ppc_memory): Likewise.
10494 (store_ppc_memory): Likewise.
10495 * target.c (set_target_ops): Likewise.
10496 * thread-db.c (thread_db_load_search): Likewise.
10497 (try_thread_db_load_1): Likewise.
10498 * tracepoint.c (add_tracepoint): Likewise.
10499 (add_tracepoint_action): Likewise.
10500 (create_trace_state_variable): Likewise.
10501 (cmd_qtdpsrc): Likewise.
10502 (cmd_qtro): Likewise.
10503 (add_while_stepping_state): Likewise.
10504 * win32-low.c (child_add_thread): Likewise.
10505 (get_image_name): Likewise.
10506
ed8b7b42
YQ
105072015-08-25 Yao Qi <yao.qi@linaro.org>
10508
10509 * linux-aarch64-low.c (aarch64_linux_new_thread): Remove.
10510
db3cb7cb
YQ
105112015-08-25 Yao Qi <yao.qi@linaro.org>
10512
10513 * Makefile.in (aarch64-linux.o): New rule.
10514 * configure.srv (aarch64*-*-linux*): Append aarch64-linux.o to
10515 srv_tgtobj.
10516 * linux-aarch64-low.c: Include nat/aarch64-linux.h.
10517 (aarch64_init_debug_reg_state): Make it extern.
10518 (aarch64_linux_prepare_to_resume): Remove.
10519
f6011a1c
YQ
105202015-08-25 Yao Qi <yao.qi@linaro.org>
10521
10522 * linux-aarch64-low.c (aarch64_linux_prepare_to_resume): Use
10523 lwp_arch_private_info and ptid_of_lwp.
10524
88e2cf7e
YQ
105252015-08-25 Yao Qi <yao.qi@linaro.org>
10526
10527 * linux-aarch64-low.c (aarch64_get_debug_reg_state): Add argument pid.
10528 Find proc_info by find_process_pid. All callers updated.
10529
5e35436e
YQ
105302015-08-25 Yao Qi <yao.qi@linaro.org>
10531
10532 * linux-aarch64-low.c (struct arch64_dr_update_callback_param):
10533 Remove.
10534 (debug_reg_change_callback): Remove.
10535 (aarch64_notify_debug_reg_change): Remove.
10536
4a8a7965
YQ
105372015-08-25 Yao Qi <yao.qi@linaro.org>
10538
10539 * linux-aarch64-low.c (aarch64_notify_debug_reg_change):
10540 Call current_lwp_ptid.
10541
32a271ee
YQ
105422015-08-25 Yao Qi <yao.qi@linaro.org>
10543
10544 * linux-aarch64-low.c (debug_reg_change_callback): Use
10545 debug_printf.
10546
0d51c8d7
YQ
105472015-08-25 Yao Qi <yao.qi@linaro.org>
10548
10549 * linux-aarch64-low.c (debug_reg_change_callback): Use phex.
10550
31a43dd5
YQ
105512015-08-25 Yao Qi <yao.qi@linaro.org>
10552
10553 * linux-aarch64-low.c (debug_reg_change_callback): Remove comments.
10554
8ee52567
YQ
105552015-08-25 Yao Qi <yao.qi@linaro.org>
10556
10557 * linux-aarch64-low.c (debug_reg_change_callback): Re-indent
10558 the code.
10559
ff3f0f45
YQ
105602015-08-25 Yao Qi <yao.qi@linaro.org>
10561
10562 * linux-aarch64-low.c (aarch64_dr_update_callback_param) <pid>:
10563 Remove.
10564 (debug_reg_change_callback): Remove argument entry and add argument
10565 lwp. Remove local variable thread. Don't print thread id in the
10566 debugging output. Don't check whether pid of thread equals to pid.
10567 (aarch64_notify_debug_reg_change): Don't set param.pid. Call
10568 iterate_over_lwps instead find_inferior.
10569
3d40fbb5
PA
105702015-08-24 Pedro Alves <palves@redhat.com>
10571
10572 * inferiors.c (get_first_process): New function.
10573 * inferiors.h (get_first_process): New declaration.
10574 * remote-utils.c (read_ptid): Default to the first process in the
10575 list, instead of to the current thread's process.
10576
438e1e42
PA
105772015-08-24 Pedro Alves <palves@redhat.com>
10578
10579 * debug.c: Include gdb_sys_time.h instead of sys/time.h.
10580 * event-loop.c: Likewise.
10581 * remote-utils.c: Likewise.
10582 * tracepoint.c: Likewise.
10583
a8c6d4fc
PA
105842015-08-24 Pedro Alves <palves@redhat.com>
10585
10586 * spu-low.c (spu_request_interrupt): Use lwpid_of instead of
10587 ptid_get_lwp.
10588
99b0bb12
PA
105892015-08-21 Pedro Alves <palves@redhat.com>
10590
10591 * ax.c (gdb_eval_agent_expr): Return expr_eval_unhandled_opcode
10592 instead of literal 1.
10593
f8904751
PA
105942015-08-21 Pedro Alves <palves@redhat.com>
10595
10596 * tdesc.c (default_description): Explicitly zero-initialize.
10597
465a859e
PA
105982015-08-21 Pedro Alves <palves@redhat.com>
10599
10600 PR gdb/18749
10601 * inferiors.c (remove_thread): Discard any pending stop reply for
10602 this thread.
10603 * server.c (remove_all_on_match_pid): Rename to ...
10604 (remove_all_on_match_ptid): ... this. Work with a filter ptid
10605 instead of a pid.
10606 (discard_queued_stop_replies): Change parameter to a ptid. Now
10607 extern.
10608 (handle_v_kill, kill_inferior_callback, captured_main)
10609 (process_serial_event): Adjust.
10610 * server.h (discard_queued_stop_replies): Declare.
10611
f0db101d
PA
106122015-08-21 Pedro Alves <palves@redhat.com>
10613
10614 * linux-low.c (wait_for_sigstop): Always switch to no thread
10615 selected if the previously current thread dies.
10616 * lynx-low.c (lynx_request_interrupt): Use the first thread's
10617 process instead of the current thread's.
10618 * remote-utils.c (input_interrupt): Don't check if there's no
10619 current thread.
10620 * server.c (gdb_read_memory, gdb_write_memory): If setting the
10621 current thread to the general thread fails, error out.
10622 (handle_qxfer_auxv, handle_qxfer_libraries)
10623 (handle_qxfer_libraries_svr4, handle_qxfer_siginfo)
10624 (handle_qxfer_spu, handle_qxfer_statictrace, handle_qxfer_fdpic)
10625 (handle_query): Check if there's a thread selected instead of
10626 checking whether there's any thread in the thread list.
10627 (handle_qxfer_threads, handle_qxfer_btrace)
10628 (handle_qxfer_btrace_conf): Don't error out early if there's no
10629 thread in the thread list.
10630 (handle_v_cont, myresume): Don't set the current thread to the
10631 continue thread.
10632 (process_serial_event) <Hg handling>: Also set thread_id if the
10633 previous general thread is still alive.
10634 (process_serial_event) <g/G handling>: If setting the current
10635 thread to the general thread fails, error out.
10636 * spu-low.c (spu_resume, spu_request_interrupt): Use the first
10637 thread's lwp instead of the current thread's.
10638 * target.c (set_desired_thread): If the desired thread was not
10639 found, leave the current thread pointing to NULL. Return an int
10640 (boolean) indicating success.
10641 * target.h (set_desired_thread): Change return type to int.
10642
40045d91
MF
106432015-08-20 Max Filippov <jcmvbkbc@gmail.com>
10644
10645 * configure.srv (xtensa*-*-linux*): Add srv_linux_thread_db=yes.
10646 * linux-xtensa-low.c (arch/xtensa.h gdb_proc_service.h): New
10647 #includes.
10648 (ps_get_thread_area): New function.
10649
45face3b
GB
106502015-08-19 Gary Benson <gbenson@redhat.com>
10651
10652 * hostio.c (handle_pread): Do not attempt to read more data
10653 than hostio_reply_with_data can fit in a packet.
10654
16d5f642
JB
106552015-08-18 Joel Brobecker <brobecker@adacore.com>
10656
10657 * linux-aarch32-low.c (NT_ARM_VFP): Define if not already defined.
10658
a738da3a
MF
106592015-08-14 Matthew Fortune <matthew.fortune@imgtec.com>
10660
10661 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP_REL.
10662
33ebda9d
PA
106632015-08-06 Pedro Alves <palves@redhat.com>
10664
10665 * tracepoint.c (expr_eval_result): Now an int.
10666
a44892be
PA
106672015-08-06 Pedro Alves <palves@redhat.com>
10668
10669 * gdbthread.h (struct regcache): Forward declare.
10670 (struct thread_info) <regcache_data>: Now a struct regcache
10671 pointer.
10672 * inferiors.c (inferior_regcache_data)
10673 (set_inferior_regcache_data): Now work with struct regcache
10674 pointers.
10675 * inferiors.h (struct regcache): Forward declare.
10676 (inferior_regcache_data, set_inferior_regcache_data): Now work
10677 with struct regcache pointers.
10678 * regcache.c (get_thread_regcache, regcache_invalidate_thread)
10679 (free_register_cache_thread): Remove struct regcache pointer
10680 casts.
10681
608a1e46
PA
106822015-08-06 Pedro Alves <palves@redhat.com>
10683
10684 * server.c (captured_main): On error, print the exception message
10685 to stderr, and if run_once is set, throw a quit.
10686
f0ce0d3a
PA
106872015-08-06 Pedro Alves <palves@redhat.com>
10688
10689 * linux-low.c (move_out_of_jump_pad_callback): Temporarily switch
10690 the current thread.
10691
bf47e248
PA
106922015-08-06 Pedro Alves <palves@redhat.com>
10693
10694 * linux-low.c (linux_write_memory): Rewrite debug output to avoid
10695 reading beyond the passed in buffer length.
10696
b6b9ffcc
PL
106972015-08-06 Pierre Langlois <pierre.langlois@arm.com>
10698
10699 * tracepoint.c (symbol_list) <required>: Remove.
10700
863d01bd
PA
107012015-08-06 Pedro Alves <palves@redhat.com>
10702
10703 * linux-low.c (handle_extended_wait): Set the fork child's suspend
10704 count if stopping and suspending threads.
10705 (check_stopped_by_breakpoint): If stopped by trace, set the LWP's
10706 stop reason to TARGET_STOPPED_BY_SINGLE_STEP.
10707 (linux_detach): Complete an ongoing step-over.
10708 (lwp_suspended_inc, lwp_suspended_decr): New functions. Use
10709 throughout.
10710 (resume_stopped_resumed_lwps): Don't resume a suspended thread.
10711 (linux_wait_1): If passing a signal to the inferior after
10712 finishing a step-over, unsuspend and re-resume all lwps. If we
10713 see a single-step event but the thread should be continuing, don't
10714 pass the trap to gdb.
10715 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback): Use
10716 internal_error instead of gdb_assert.
10717 (enqueue_pending_signal): New function.
10718 (check_ptrace_stopped_lwp_gone): Add debug output.
10719 (start_step_over): Use internal_error instead of gdb_assert.
10720 (complete_ongoing_step_over): New function.
10721 (linux_resume_one_thread): Don't resume a suspended thread.
10722 (proceed_one_lwp): If the LWP is stepping over a breakpoint, reset
10723 it stepping.
10724
00db26fa
PA
107252015-08-06 Pedro Alves <palves@redhat.com>
10726
10727 * linux-low.c (add_lwp): Set waitstatus to TARGET_WAITKIND_IGNORE.
10728 (linux_thread_alive): Use lwp_is_marked_dead.
10729 (extended_event_reported): Delete.
10730 (linux_wait_1): Check if waitstatus is TARGET_WAITKIND_IGNORE
10731 instead of extended_event_reported.
10732 (mark_lwp_dead): Don't set the 'dead' flag. Store the waitstatus
10733 as well.
10734 (lwp_is_marked_dead): New function.
10735 (lwp_running): Use lwp_is_marked_dead.
10736 * linux-low.h: Delete 'dead' field, and update 'waitstatus's
10737 comment.
10738
ad071a30
PA
107392015-08-06 Pedro Alves <palves@redhat.com>
10740
10741 * linux-low.c (linux_wait_1): Move fork event output out of the
10742 !report_to_gdb check. Pass event_child->waitstatus to
10743 target_waitstatus_to_string instead of ourstatus.
10744
524b57e6
YQ
107452015-08-04 Yao Qi <yao.qi@linaro.org>
10746
10747 * linux-aarch64-low.c (aarch64_supports_tracepoints): Return 0
10748 if current_thread is 32 bit.
10749
6085d6f6
YQ
107502015-08-04 Yao Qi <yao.qi@linaro.org>
10751
10752 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
10753 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
10754 * server.c (extended_protocol): Remove "static".
10755 * server.h (extended_protocol): Declare it.
10756
8a7e4587
YQ
107572015-08-04 Yao Qi <yao.qi@linaro.org>
10758
10759 * linux-aarch64-low.c (aarch64_get_pc): Get PC register on
10760 both aarch64 and aarch32.
10761 (aarch64_set_pc): Likewise.
10762
3b53ae99
YQ
107632015-08-04 Yao Qi <yao.qi@linaro.org>
10764
10765 * configure.srv (case aarch64*-*-linux*): Append arm-with-neon.o
10766 to srv_regobj and append arm-core.xml arm-vfpv3.xml and
10767 arm-with-neon.xml to srv_xmlfiles.
10768 * linux-aarch64-low.c: Include linux-aarch32-low.h.
10769 (is_64bit_tdesc): New function.
10770 (aarch64_linux_read_description): New function.
10771 (aarch64_arch_setup): Call aarch64_linux_read_description.
10772 (regs_info): Rename to regs_info_aarch64.
10773 (aarch64_regs_info): Return right regs_info.
10774 (initialize_low_arch): Call initialize_low_arch_aarch32.
10775
bd9e6534
YQ
107762015-08-04 Yao Qi <yao.qi@linaro.org>
10777
10778 * configure.srv (srv_tgtobj): Add linux-aarch32-low.o.
10779 * linux-aarch32-low.c: New file.
10780 * linux-aarch32-low.h: New file.
10781 * linux-arm-low.c (arm_fill_gregset): Move it to
10782 linux-aarch32-low.c.
10783 (arm_store_gregset): Likewise.
10784 (arm_fill_vfpregset): Call arm_fill_vfpregset_num
10785 (arm_store_vfpregset): Call arm_store_vfpregset_num.
10786 (arm_arch_setup): Check if PTRACE_GETREGSET works.
10787 (regs_info): Rename to regs_info_arm.
10788 (arm_regs_info): Return regs_info_aarch32 if
10789 have_ptrace_getregset is 1 and target description is
10790 arm_with_neon or arm_with_vfpv3.
10791 (initialize_low_arch): Don't call init_registers_arm_with_neon.
10792 Call initialize_low_arch_aarch32 instead.
10793
ded48a5e
YQ
107942015-08-04 Yao Qi <yao.qi@linaro.org>
10795
10796 * linux-x86-low.c (have_ptrace_getregset): Move it to ...
10797 * linux-low.c: ... here.
10798 * linux-low.h (have_ptrace_getregset): Declare it.
10799
96e9210f
PA
108002015-08-04 Pedro Alves <palves@redhat.com>
10801
10802 * thread-db.c (struct thread_db): Use new typedefs.
10803 (try_thread_db_load_1): Define local TDB_DLSYM macro and use it in
10804 CHK calls.
10805 (disable_thread_event_reporting): Cast result of dlsym to
10806 destination function pointer type.
10807 (thread_db_mourn): Use td_ta_delete_ftype.
10808
af60a1ef
SL
108092015-08-03 Sandra Loosemore <sandra@codesourcery.com>
10810
10811 * linux-nios2-low.c (NIOS2_BREAKPOINT): Conditionalize for
10812 arch variant.
10813 (CDX_BREAKPOINT): Define for R2.
10814 (nios2_breakpoint_at): Check for CDX_BREAKPOINT when R2.
10815 (the_low_target): Add comments.
10816
e8b41681
YQ
108172015-07-30 Yao Qi <yao.qi@linaro.org>
10818
10819 * linux-arm-low.c (arm_hwcap): Remove it.
10820 (arm_read_description): New local variable arm_hwcap. Don't
10821 set arm_hwcap to zero.
10822
89abb039
YQ
108232015-07-30 Yao Qi <yao.qi@linaro.org>
10824
10825 * linux-arm-low.c (arm_fill_wmmxregset): Don't use arm_hwcap.
10826 Use regcache->tdesc instead.
10827 (arm_store_wmmxregset): Likewise.
10828 (arm_fill_vfpregset): Likewise.
10829 (arm_store_vfpregset): Likewise.
10830
deca266c
YQ
108312015-07-30 Yao Qi <yao.qi@linaro.org>
10832
10833 * linux-arm-low.c: Include arch/arm.h.
10834 (arm_fill_gregset): Don't use arm_num_regs and arm_regmap.
10835 (arm_store_gregset): Likewise.
10836
aa58a496
SM
108372015-07-29 Simon Marchi <simon.marchi@ericsson.com>
10838
10839 * linux-mips-low.c (mips_linux_prepare_to_resume): Add NULL as
10840 ptrace's 4th parameter.
10841
50904b25
YQ
108422015-07-27 Yao Qi <yao.qi@linaro.org>
10843
10844 * configure.srv (case aarch64*-*-linux*): Don't set
10845 srv_linux_usrregs.
10846
5826e159
PA
108472015-07-24 Pedro Alves <palves@redhat.c: Likewise.om>
10848
10849 * linux-aarch64-low.c: Include nat/gdb_ptrace.h instead of
10850 sys/ptrace.h.
10851 * linux-arm-low.c: Likewise.
10852 * linux-cris-low.c: Likewise.
10853 * linux-crisv32-low.c: Likewise.
10854 * linux-low.c: Likewise.
10855 * linux-m68k-low.c: Likewise.
10856 * linux-mips-low.c: Likewise.
10857 * linux-nios2-low.c: Likewise.
10858 * linux-s390-low.c: Likewise.
10859 * linux-sparc-low.c: Likewise.
10860 * linux-tic6x-low.c: Likewise.
10861 * linux-tile-low.c: Likewise.
10862 * linux-x86-low.c: Likewise.
10863
54019719
PA
108642015-07-24 Pedro Alves <palves@redhat.com>
10865
10866 * config.in: Regenerate.
10867 * configure: Regenerate.
10868
eb7aa561
PA
108692015-07-24 Pedro Alves <palves@redhat.com>
10870
10871 * acinclude.m4: Include ../ptrace.m4.
10872 * configure.ac: Call GDB_AC_PTRACE.
10873 * config.in, configure: Regenerate.
10874
55d7b841
YQ
108752015-07-24 Yao Qi <yao.qi@linaro.org>
10876
10877 * linux-low.c (linux_create_inferior): Remove setting to
10878 proc->priv->new_inferior.
10879 (linux_attach): Likewise.
10880 (linux_low_filter_event): Likewise.
10881 * linux-low.h (struct process_info_private) <new_inferior>: Remove.
10882
c06cbd92
YQ
108832015-07-24 Yao Qi <yao.qi@linaro.org>
10884
10885 * linux-low.c (linux_arch_setup): New function.
10886 (linux_low_filter_event): If proc->tdesc is NULL and
10887 proc->attached is true, call the_low_target.arch_setup.
10888 Otherwise, keep status pending, and return.
10889 (linux_resume_one_lwp_throw): Don't call get_pc if
10890 thread->while_stepping isn't NULL. Don't call
10891 get_thread_regcache if proc->tdesc is NULL.
10892 (need_step_over_p): Return 0 if proc->tdesc is NULL.
10893 (linux_target_ops): Install arch_setup.
10894 * server.c (start_inferior): Call the_target->arch_setup.
10895 * target.h (struct target_ops) <arch_setup>: New field.
10896 (target_arch_setup): New marco.
10897 * lynx-low.c (lynx_target_ops): Update.
10898 * nto-low.c (nto_target_ops): Update.
10899 * spu-low.c (spu_target_ops): Update.
10900 * win32-low.c (win32_target_ops): Update.
10901
5ae3ebba
YQ
109022015-07-24 Yao Qi <yao.qi@linaro.org>
10903
10904 * linux-low.c (linux_add_process): Don't set
10905 proc->priv->new_inferior.
10906 (linux_create_inferior): Set proc->priv->new_inferior to 1.
10907 (linux_attach): Likewise.
10908
eb97750b
YQ
109092015-07-24 Yao Qi <yao.qi@linaro.org>
10910
10911 * server.c (start_inferior): Code refactor.
10912
51aee833
YQ
109132015-07-24 Yao Qi <yao.qi@linaro.org>
10914
10915 * server.c (process_serial_event): Set general_thread.
10916
af1b22f3
YQ
109172015-07-21 Yao Qi <yao.qi@linaro.org>
10918
10919 * linux-aarch64-low.c (aarch64_arch_setup): Remove code and call
10920 aarch64_linux_get_debug_reg_capacity.
10921
554717a3
YQ
109222015-07-17 Yao Qi <yao.qi@linaro.org>
10923
10924 * Makefile.in (aarch64-linux-hw-point.o): New rule.
10925 * configure.srv (srv_tgtobj): Append aarch64-linux-hw-point.o.
10926 * linux-aarch64-low.c: Include nat/aarch64-linux-hw-point.h.
10927 (AARCH64_HBP_MAX_NUM): Move to nat/aarch64-linux-hw-point.h.
10928 (AARCH64_HWP_MAX_NUM, AARCH64_HBP_ALIGNMENT): Likewise.
10929 (AARCH64_HWP_ALIGNMENT): Likewise.
10930 (AARCH64_HWP_MAX_LEN_PER_REG): Likewise.
10931 (AARCH64_DEBUG_NUM_SLOTS, AARCH64_DEBUG_ARCH): Likewise.
10932 (aarch64_num_bp_regs, aarch64_num_wp_regs): Likewise.
10933 (AARCH64_DEBUG_ARCH_V8, DR_MARK_ALL_CHANGED): Likewise.
10934 (DR_MARK_N_CHANGED, DR_CLEAR_CHANGED): Likewise.
10935 (DR_HAS_CHANGED, DR_N_HAS_CHANGE): Likewise.
10936 (struct aarch64_debug_reg_state): Likewise.
10937 (struct arch_lwp_info): Likewise.
10938 (aarch64_align_watchpoint): Likewise.
10939 (DR_CONTROL_ENABLED, DR_CONTROL_LENGTH): Likewise.
10940 (aarch64_watchpoint_length): Likewise.
10941 (aarch64_point_encode_ctrl_reg): Likewise
10942 (aarch64_point_is_aligned): Likewise.
10943 (aarch64_align_watchpoint): Likewise.
10944 (aarch64_linux_set_debug_regs):
10945 (aarch64_dr_state_insert_one_point): Likewise.
10946 (aarch64_dr_state_remove_one_point): Likewise.
10947 (aarch64_handle_breakpoint): Likewise.
10948 (aarch64_handle_aligned_watchpoint): Likewise.
10949 (aarch64_handle_unaligned_watchpoint): Likewise.
10950 (aarch64_handle_watchpoint): Likewise.
10951
c67ca4de
YQ
109522015-07-17 Yao Qi <yao.qi@linaro.org>
10953
10954 * linux-aarch64-low.c (aarch64_handle_breakpoint): Add argument state
10955 and don't aarch64_get_debug_reg_state. All callers update.
10956 (aarch64_handle_aligned_watchpoint): Likewise.
10957 (aarch64_handle_unaligned_watchpoint): Likewise.
10958 (aarch64_handle_watchpoint): Likewise.
10959 (aarch64_insert_point): Call aarch64_get_debug_reg_state earlier.
10960 (aarch64_remove_point): Likewise.
10961
25abf979
YQ
109622015-07-17 Yao Qi <yao.qi@linaro.org>
10963
10964 * linux-aarch64-low.c (aarch64_show_debug_reg_state): Use
10965 debug_printf.
10966 (aarch64_handle_unaligned_watchpoint): Likewise.
10967
db1ff28b
JK
109682015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
10969
10970 Revert the previous 3 commits:
10971 Move gdb_regex* to common/
10972 Move linux_find_memory_regions_full & co.
10973 gdbserver build-id attribute generator
10974
700ca40f
JK
109752015-07-15 Aleksandar Ristovski <aristovski@qnx.com
10976 Jan Kratochvil <jan.kratochvil@redhat.com>
10977
10978 gdbserver build-id attribute generator.
10979 * linux-low.c (nat/linux-maps.h, search.h, rsp-low.h): Include.
10980 (ElfXX_Ehdr, ElfXX_Phdr, ElfXX_Nhdr): New.
10981 (ELFXX_FLD, ELFXX_SIZEOF, ELFXX_ROUNDUP, BUILD_ID_INVALID): New.
10982 (find_phdr): New.
10983 (get_dynamic): Use find_pdhr to traverse program headers.
10984 (struct mapping_entry, mapping_entry_s, free_mapping_entry_vec)
10985 (compare_mapping_entry_range, struct find_memory_region_callback_data)
10986 (read_build_id, find_memory_region_callback, lrfind_mapping_entry)
10987 (get_hex_build_id): New.
10988 (linux_qxfer_libraries_svr4): Add optional build-id attribute
10989 to reply XML document.
10990
9904185c
JK
109912015-07-15 Aleksandar Ristovski <aristovski@qnx.com
10992 Jan Kratochvil <jan.kratochvil@redhat.com>
10993
10994 * target.c: Include target/target-utils.h and fcntl.h.
10995 (target_fileio_read_stralloc_1_pread, target_fileio_read_stralloc_1)
10996 (target_fileio_read_stralloc): New functions.
10997
6e5b4429
JK
109982015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
10999
11000 * Makefile.in (OBS): Add gdb_regex.o.
11001 (gdb_regex.o): New.
11002 * config.in: Rebuilt.
11003 * configure: Rebuilt.
11004
ddc98fbf
JK
110052015-07-15 Aleksandar Ristovski <aristovski@qnx.com
11006 Jan Kratochvil <jan.kratochvil@redhat.com>
11007
11008 Create empty nat/linux-maps.[ch] and common/target-utils.[ch].
11009 * Makefile.in (OBS): Add target-utils.o.
11010 (linux-maps.o, target-utils.o): New.
11011 * configure.srv (srv_linux_obj): Add linux-maps.o.
11012
e57bb7a0
PL
110132015-07-15 Pierre Langlois <pierre.langlois@arm.com>
11014
11015 * linux-aarch64-low.c (aarch64_supports_range_stepping): New
11016 function, return 1.
11017 (the_low_target): Install it.
11018
586b02a9
PA
110192015-07-14 Pedro Alves <palves@redhat.com>
11020
11021 * linux-low.c (kill_wait_lwp): Don't assert if waitpid fails.
11022 Instead, ignore ECHILD, and throw an error for other errnos.
11023
58c1b36c
PA
110242015-07-10 Pedro Alves <palves@redhat.com>
11025
11026 * event-loop.c (struct callback_event) <data>: Change type to
11027 gdb_client_data instance instead of gdb_client_data pointer.
11028 (append_callback_event): Adjust.
11029
421530db
PL
110302015-07-10 Pierre Langlois <pierre.langlois@arm.com>
11031
11032 * linux-aarch64-low.c: Add comments for each linux_target_ops
11033 method. Remove comments already covered in target_ops and
11034 linux_target_ops definitions.
11035 (the_low_target): Add comments for each unimplemented method.
11036
c2d65f38
YQ
110372015-07-09 Yao Qi <yao.qi@linaro.org>
11038
11039 * linux-aarch64-low.c (aarch64_regmap): Remove.
11040 (aarch64_usrregs_info): Remove.
11041 (regs_info): Set field usrregs to NULL.
11042
b20a6524
MM
110432015-07-02 Markus Metzger <markus.t.metzger@intel.com>
11044
11045 * linux-low.c: Include "rsp-low.h"
11046 (linux_low_encode_pt_config, linux_low_encode_raw): New.
11047 (linux_low_read_btrace): Support BTRACE_FORMAT_PT.
11048 (linux_low_btrace_conf): Support BTRACE_FORMAT_PT.
11049 (handle_btrace_enable_pt): New.
11050 (handle_btrace_general_set): Support "pt".
11051 (handle_btrace_conf_general_set): Support "pt:size".
11052
96c97461
PL
110532015-06-29 Pierre Langlois <pierre.langlois@arm.com>
11054
11055 * linux-aarch64-low.c (aarch64_supports_z_point_type): Enable for
11056 Z_PACKET_SW_BP.
11057
37d66942
PL
110582015-06-29 Pierre Langlois <pierre.langlois@arm.com>
11059
11060 * linux-aarch64-low.c: Remove comment about endianness.
11061 (aarch64_breakpoint): Change type to gdb_byte[]. Set to "brk #0".
11062 (aarch64_breakpoint_at): Change type of insn to gdb_byte[]. Use
11063 memcmp.
11064
dc06243f
GB
110652015-06-24 Gary Benson <gbenson@redhat.com>
11066
11067 * linux-i386-ipa.c (stdint.h): Do not include.
11068 * lynx-i386-low.c (stdint.h): Likewise.
11069 * lynx-ppc-low.c (stdint.h): Likewise.
11070 * mem-break.c (stdint.h): Likewise.
11071 * thread-db.c (stdint.h): Likewise.
11072 * tracepoint.c (stdint.h): Likewise.
11073 * win32-low.c (stdint.h): Likewise.
11074
124e13d9
SM
110752015-06-18 Simon Marchi <simon.marchi@ericsson.com>
11076
11077 * server.c (write_qxfer_response): Update call to
11078 remote_escape_output.
11079
909c2cda
JK
110802015-06-15 Aleksandar Ristovski <aristovski@qnx.com
11081 Jan Kratochvil <jan.kratochvil@redhat.com>
11082
11083 Merge multiple hex conversions.
11084 * gdbreplay.c (tohex): Rename to 'fromhex'.
11085 (logchar): Use fromhex.
11086
24c05f46
JK
110872015-06-10 Jan Kratochvil <jan.kratochvil@redhat.com>
11088
11089 * server.c (handle_qxfer_libraries): Set `version' attribute for
11090 <library-list>.
11091
14d2069a
GB
110922015-06-10 Gary Benson <gbenson@redhat.com>
11093
11094 * target.h (struct target_ops) <multifs_open>: New field.
11095 <multifs_unlink>: Likewise.
11096 <multifs_readlink>: Likewise.
11097 * linux-low.c (nat/linux-namespaces.h): New include.
11098 (linux_target_ops): Initialize the_target->multifs_open,
11099 the_target->multifs_unlink and the_target->multifs_readlink.
11100 * hostio.h (hostio_handle_new_gdb_connection): New declaration.
11101 * hostio.c (hostio_fs_pid): New static variable.
11102 (hostio_handle_new_gdb_connection): New function.
11103 (handle_setfs): Likewise.
11104 (handle_open): Use the_target->multifs_open as appropriate.
11105 (handle_unlink): Use the_target->multifs_unlink as appropriate.
11106 (handle_readlink): Use the_target->multifs_readlink as
11107 appropriate.
11108 (handle_vFile): Handle vFile:setfs packets.
11109 * server.c (handle_query): Call hostio_handle_new_gdb_connection
11110 after target_handle_new_gdb_connection.
11111
4b8b5e72
GB
111122015-06-10 Gary Benson <gbenson@redhat.com>
11113
11114 * configure.ac (AC_CHECK_FUNCS): Add setns.
11115 * config.in: Regenerate.
11116 * configure: Likewise.
11117 * Makefile.in (SFILES): Add nat/linux-namespaces.c.
11118 (linux-namespaces.o): New rule.
11119 * configure.srv (srv_linux_obj): Add linux-namespaces.o.
11120
3ac2e371
GB
111212015-06-09 Gary Benson <gbenson@redhat.com>
11122
11123 * hostio.c (handle_open): Process mode argument with
11124 fileio_to_host_mode.
11125
ca9b78ce
YQ
111262015-06-01 Yao Qi <yao.qi@linaro.org>
11127
11128 * linux-s390-low.c (PTRACE_GETREGSET, PTRACE_SETREGSET): Remove.
11129 * linux-x86-low.c: Likewise.
11130
bfacd19d
DB
111312015-05-28 Don Breazeal <donb@codesourcery.com>
11132
11133 * linux-low.c (handle_extended_wait): Initialize
11134 thread_info.last_resume_kind for new fork children.
11135
452003ef
PA
111362015-05-15 Pedro Alves <palves@redhat.com>
11137
11138 * target.h (target_handle_new_gdb_connection): Rewrite using if
11139 wrapped in do/while.
11140
1041a03c
JB
111412015-05-14 Joel Brobecker <brobecker@adacore.com>
11142
11143 * configure.ac: Add prfpregset_t BFD_HAVE_SYS_PROCFS_TYPE check.
11144 * configure, config.in: Regenerate.
11145 * gdb_proc_service.h [HAVE_PRFPREGSET_T] (prfpregset_t):
11146 Declare typedef.
11147
c269dbdb
DB
111482015-05-12 Don Breazeal <donb@codesourcery.com>
11149
11150 * linux-low.c (handle_extended_wait): Handle PTRACE_EVENT_FORK and
11151 PTRACE_EVENT_VFORK_DONE.
11152 (linux_low_ptrace_options, extended_event_reported): Add vfork
11153 events.
11154 * remote-utils.c (prepare_resume_reply): New stop reasons "vfork"
11155 and "vforkdone" for RSP 'T' Stop Reply Packet.
11156 * server.h (report_vfork_events): Declare
11157 global variable.
11158
3a8a0396
DB
111592015-05-12 Don Breazeal <donb@codesourcery.com>
11160
11161 * linux-aarch64-low.c (aarch64_linux_new_fork): New function.
11162 (the_low_target) <new_fork>: Initialize new member.
11163 * linux-arm-low.c (arm_new_fork): New function.
11164 (the_low_target) <new_fork>: Initialize new member.
11165 * linux-low.c (handle_extended_wait): Call new target function
11166 new_fork.
11167 * linux-low.h (struct linux_target_ops) <new_fork>: New member.
11168 * linux-mips-low.c (mips_add_watchpoint): New function
11169 extracted from mips_insert_point.
11170 (the_low_target) <new_fork>: Initialize new member.
11171 (mips_linux_new_fork): New function.
11172 (mips_insert_point): Call mips_add_watchpoint.
11173 * linux-x86-low.c (x86_linux_new_fork): New function.
11174 (the_low_target) <new_fork>: Initialize new member.
11175
de0d863e
DB
111762015-05-12 Don Breazeal <donb@codesourcery.com>
11177
11178 * linux-low.c (handle_extended_wait): Implement return value,
11179 rename argument 'event_child' to 'event_lwp', handle
11180 PTRACE_EVENT_FORK, call internal_error for unrecognized event.
11181 (linux_low_ptrace_options): New function.
11182 (linux_low_filter_event): Call linux_low_ptrace_options,
11183 use different argument fo linux_enable_event_reporting,
11184 use return value from handle_extended_wait.
11185 (extended_event_reported): New function.
11186 (linux_wait_1): Call extended_event_reported and set
11187 status to report fork events.
11188 (linux_write_memory): Add pid to debug message.
11189 (reset_lwp_ptrace_options_callback): New function.
11190 (linux_handle_new_gdb_connection): New function.
11191 (linux_target_ops): Initialize new structure member.
11192 * linux-low.h (struct lwp_info) <waitstatus>: New member.
11193 * lynx-low.c: Initialize new structure member.
11194 * remote-utils.c (prepare_resume_reply): Implement stop reason
11195 "fork" for "T" stop message.
11196 * server.c (handle_query): Call handle_new_gdb_connection.
11197 * server.h (report_fork_events): Declare global flag.
11198 * target.h (struct target_ops) <handle_new_gdb_connection>:
11199 New member.
11200 (target_handle_new_gdb_connection): New macro.
11201 * win32-low.c: Initialize new structure member.
11202
ddcbc397
DB
112032015-05-12 Don Breazeal <donb@codesourcery.com>
11204
11205 * mem-break.c (APPEND_TO_LIST): Define macro.
11206 (clone_agent_expr): New function.
11207 (clone_one_breakpoint): New function.
11208 (clone_all_breakpoints): New function.
11209 * mem-break.h: Declare new functions.
11210
89245bc0
DB
112112015-05-12 Don Breazeal <donb@codesourcery.com>
11212
11213 * linux-low.c (linux_supports_fork_events): New function.
11214 (linux_supports_vfork_events): New function.
11215 (linux_target_ops): Initialize new structure members.
11216 (initialize_low): Call linux_check_ptrace_features.
11217 * lynx-low.c (lynx_target_ops): Initialize new structure
11218 members.
11219 * server.c (report_fork_events, report_vfork_events):
11220 New global flags.
11221 (handle_query): Add new features to qSupported packet and
11222 response.
11223 (captured_main): Initialize new global variables.
11224 * target.h (struct target_ops) <supports_fork_events>:
11225 New member.
11226 <supports_vfork_events>: New member.
11227 (target_supports_fork_events): New macro.
11228 (target_supports_vfork_events): New macro.
11229 * win32-low.c (win32_target_ops): Initialize new structure
11230 members.
11231
835205d0
GB
112322015-05-12 Gary Benson <gbenson@redhat.com>
11233
11234 * server.c (handle_qxfer_exec_file): Use current process
11235 if annex is empty.
11236
21e94bd9
SL
112372015-05-08 Sandra Loosemore <sandra@codesourcery.com>
11238
11239 * linux-nios2-low.c: Include elf/common.h. Adjust comments.
11240 Remove HAVE_PTRACE_GETREGS conditionals.
11241 (nios2_regsets): Use PTRACE_GETREGSET and PTRACE_SETREGSET
11242 instead of PTRACE_GETREGS and PTRACE_SETREGS.
11243
45614f15
YQ
112442015-05-08 Yao Qi <yao.qi@linaro.org>
11245
11246 * linux-low.c (linux_supports_conditional_breakpoints): New
11247 function.
11248 (linux_target_ops): Install new target method.
11249 * lynx-low.c (lynx_target_ops): Install NULL hook for
11250 supports_conditional_breakpoints.
11251 * nto-low.c (nto_target_ops): Likewise.
11252 * spu-low.c (spu_target_ops): Likewise.
11253 * win32-low.c (win32_target_ops): Likewise.
11254 * server.c (handle_query): Check
11255 target_supports_conditional_breakpoints.
11256 * target.h (struct target_ops) <supports_conditional_breakpoints>:
11257 New field.
11258 (target_supports_conditional_breakpoints): New macro.
11259
80ad801e
PA
112602015-05-06 Pedro Alves <palves@redhat.com>
11261
11262 PR server/18081
11263 * server.c (start_inferior): If the process exits, mourn it.
11264
819843c7
GB
112652015-04-21 Gary Benson <gbenson@redhat.com>
11266
11267 * hostio.c (fileio_open_flags_to_host): Factored out to
11268 fileio_to_host_openflags in common/fileio.c. Single use
11269 updated.
11270
a2d5a9d7
MF
112712015-04-17 Max Filippov <jcmvbkbc@gmail.com>
11272
11273 * linux-xtensa-low.c (xtensa_fill_gregset)
11274 (xtensa_store_gregset): Check XCHAL_HAVE_LOOPS instead of
11275 XCHAL_HAVE_LOOP.
11276
deb44829
MF
112772015-04-17 Max Filippov <jcmvbkbc@gmail.com>
11278
11279 * linux-xtensa-low.c (xtensa_usrregs_info): Remove.
11280 (regs_info): Replace usrregs pointer with NULL.
11281
e57f1de3
GB
112822015-04-17 Gary Benson <gbenson@redhat.com>
11283
11284 * target.h (struct target_ops) <pid_to_exec_file>: New field.
11285 * linux-low.c (linux_target_ops): Initialize pid_to_exec_file.
11286 * server.c (handle_qxfer_exec_file): New function.
11287 (qxfer_packets): Add exec-file entry.
11288 (handle_query): Report qXfer:exec-file:read as supported packet.
11289
62828379
RN
112902015-04-14 Romain Naour <romain.naour@openwide.fr> (tiny change)
11291
11292 * linux-low.c (linux_read_offsets): Remove get_thread_lwp.
11293
b88bb450
GB
112942015-04-09 Gary Benson <gbenson@redhat.com>
11295
11296 * hostio-errno.c (errno_to_fileio_error): Remove function.
11297 Update caller to use remote_fileio_to_fio_error.
11298
c8f4bfdd
YQ
112992015-04-09 Yao Qi <yao.qi@linaro.org>
11300
11301 * linux-low.c (linux_insert_point): Call
11302 insert_memory_breakpoint if TYPE is raw_bkpt_type_sw.
11303 (linux_remove_point): Call remove_memory_breakpoint if type is
11304 raw_bkpt_type_sw.
11305 * linux-x86-low.c (x86_insert_point): Don't call
11306 insert_memory_breakpoint.
11307 (x86_remove_point): Don't call remove_memory_breakpoint.
11308
41f98f02
PA
113092015-04-01 Pedro Alves <palves@redhat.com>
11310 Cleber Rosa <crosa@redhat.com>
11311
11312 * server.c (gdbserver_usage): Reorganize and extend the usage
11313 message.
11314
2bf6fb9d
PA
113152015-03-24 Pedro Alves <palves@redhat.com>
11316
11317 * linux-low.c (check_stopped_by_breakpoint): Tweak debug log
11318 output. Also dump TRAP_TRACE.
11319 (linux_low_filter_event): In debug output, distinguish a
11320 resume_stop SIGSTOP from a delayed SIGSTOP.
11321
369f6daa
GB
113222015-03-24 Gary Benson <gbenson@redhat.com>
11323
11324 * linux-x86-low.c (x86_linux_new_thread): Moved to
11325 nat/x86-linux.c.
11326 (x86_linux_prepare_to_resume): Likewise.
11327
8e5d4070
GB
113282015-03-24 Gary Benson <gbenson@redhat.com>
11329
11330 * Makefile.in (x86-linux-dregs.o): New rule.
11331 * configure.srv: Add x86-linux-dregs.o to relevant targets.
11332 * linux-x86-low.c: Include nat/x86-linux-dregs.h.
11333 (u_debugreg_offset): Moved to nat/x86-linux-dregs.c.
11334 (x86_linux_dr_get): Likewise.
11335 (x86_linux_dr_set): Likewise.
11336 (update_debug_registers_callback): Likewise.
11337 (x86_linux_dr_set_addr): Likewise.
11338 (x86_linux_dr_get_addr): Likewise.
11339 (x86_linux_dr_set_control): Likewise.
11340 (x86_linux_dr_get_control): Likewise.
11341 (x86_linux_dr_get_status): Likewise.
11342 (x86_linux_update_debug_registers): Likewise.
11343
2b95d440
GB
113442015-03-24 Gary Benson <gbenson@redhat.com>
11345
11346 * linux-x86-low.c (x86_linux_update_debug_registers):
11347 New function, factored out from...
11348 (x86_linux_prepare_to_resume): ...this.
11349
14b0bc68
GB
113502015-03-24 Gary Benson <gbenson@redhat.com>
11351
11352 * linux-x86-low.c (x86_linux_dr_get): Update comments.
11353 (x86_linux_dr_set): Likewise.
11354 (update_debug_registers_callback): Likewise.
11355 (x86_linux_dr_set_addr): Likewise.
11356 (x86_linux_dr_get_addr): Likewise.
11357 (x86_linux_dr_set_control): Likewise.
11358 (x86_linux_dr_get_control): Likewise.
11359 (x86_linux_dr_get_status): Likewise.
11360 (x86_linux_prepare_to_resume): Likewise.
11361
5dfe6ca8
GB
113622015-03-24 Gary Benson <gbenson@redhat.com>
11363
11364 * linux-x86-low.c (x86_linux_dr_get): Add assertion.
11365 Use perror_with_name. Pass string through gettext.
11366 (x86_linux_dr_set): Likewise.
11367
d33472ad
GB
113682015-03-24 Gary Benson <gbenson@redhat.com>
11369
11370 * linux-x86-low.c (x86_dr_low_set_addr): Rename to...
11371 (x86_linux_dr_set_addr): ...this.
11372 (x86_dr_low_get_addr): Rename to...
11373 (x86_linux_dr_get_addr): ...this.
11374 (x86_dr_low_set_control): Rename to...
11375 (x86_linux_dr_set_control): ...this.
11376 (x86_dr_low_get_control): Rename to...
11377 (x86_linux_dr_get_control): ...this.
11378 (x86_dr_low_get_status): Rename to...
11379 (x86_linux_dr_get_status): ...this.
11380 (x86_dr_low): Update with new function names.
11381
4b134ca1
GB
113822015-03-24 Gary Benson <gbenson@redhat.com>
11383
11384 * Makefile.in (x86-linux.o): New rule.
11385 * configure.srv: Add x86-linux.o to relevant targets.
11386 * linux-low.c (lwp_set_arch_private_info): New function.
11387 (lwp_arch_private_info): Likewise.
11388 * linux-x86-low.c: Include nat/x86-linux.h.
11389 (arch_lwp_info): Removed structure.
11390 (update_debug_registers_callback):
11391 Use lwp_set_debug_registers_changed.
11392 (x86_linux_prepare_to_resume): Use lwp_debug_registers_changed
11393 and lwp_set_debug_registers_changed.
11394 (x86_linux_new_thread): Use lwp_set_debug_registers_changed.
11395
34c703da
GB
113962015-03-24 Gary Benson <gbenson@redhat.com>
11397
11398 * linux-low.h (linux_target_ops) <new_thread>: Changed signature.
11399 * linux-arm-low.c (arm_new_thread): Likewise.
11400 * linux-aarch64-low.c (aarch64_linux_new_thread): Likewise.
11401 * linux-mips-low.c (mips_linux_new_thread): Likewise.
11402 * linux-x86-low.c (x86_linux_new_thread): Likewise.
11403 * linux-low.c (add_lwp): Update the_low_target.new_thread call.
11404
cff068da
GB
114052015-03-24 Gary Benson <gbenson@redhat.com>
11406
11407 * linux-low.c (ptid_of_lwp): New function.
11408 (lwp_is_stopped): Likewise.
11409 (lwp_stop_reason): Likewise.
11410 * linux-x86-low.c (update_debug_registers_callback):
11411 Use lwp_is_stopped.
11412 (x86_linux_prepare_to_resume): Use ptid_of_lwp and
11413 lwp_stop_reason.
11414
b2f7c7e8
GB
114152015-03-24 Gary Benson <gbenson@redhat.com>
11416
11417 * linux-low.h (linux_stop_lwp): Remove declaration.
11418
6d4ee8c6
GB
114192015-03-24 Gary Benson <gbenson@redhat.com>
11420
11421 * linux-low.h: Include nat/linux-nat.h.
11422 * linux-low.c (iterate_over_lwps_args): New structure.
11423 (iterate_over_lwps_filter): New function.
11424 (iterate_over_lwps): Likewise.
11425 * linux-x86-low.c (update_debug_registers_callback):
11426 Update signature to what iterate_over_lwps expects.
11427 Remove PID check that iterate_over_lwps now performs.
11428 (x86_dr_low_set_addr): Use iterate_over_lwps.
11429 (x86_dr_low_set_control): Likewise.
11430
70a0bb6b
GB
114312015-03-24 Gary Benson <gbenson@redhat.com>
11432
11433 * linux-x86-low.c (x86_debug_reg_state): New function.
11434 (x86_linux_prepare_to_resume): Use the above.
11435
7b669087
GB
114362015-03-24 Gary Benson <gbenson@redhat.com>
11437
11438 * linux-low.c (current_lwp_ptid): New function.
11439 * linux-x86-low.c: Include nat/linux-nat.h.
11440 (x86_dr_low_get_addr): Use current_lwp_ptid.
11441 (x86_dr_low_get_control): Likewise.
11442 (x86_dr_low_get_status): Likewise.
11443
eef49a3d
PA
114442015-03-20 Pedro Alves <palves@redhat.com>
11445
11446 * tracepoint.c (cmd_qtstatus): Make "str" const.
11447
b2333d22
PA
114482015-03-20 Pedro Alves <palves@redhat.com>
11449
11450 * server.c (handle_general_set): Make "req_str" const.
11451
23f238d3
PA
114522015-03-19 Pedro Alves <palves@redhat.com>
11453
11454 * linux-low.c (linux_resume_one_lwp): Rename to ...
11455 (linux_resume_one_lwp_throw): ... this. Don't handle ESRCH here,
11456 instead call perror_with_name.
11457 (check_ptrace_stopped_lwp_gone): New function.
11458 (linux_resume_one_lwp): Reimplement as wrapper around
11459 linux_resume_one_lwp_throw that swallows errors if the LWP is
11460 gone.
11461
91baf43f
PA
114622015-03-19 Pedro Alves <palves@redhat.com>
11463
11464 * linux-low.c (count_events_callback, select_event_lwp_callback):
11465 No longer check whether the thread has resume_stop as last resume
11466 kind.
11467
8bf3b159
PA
114682015-03-19 Pedro Alves <palves@redhat.com>
11469
11470 * linux-low.c (count_events_callback, select_event_lwp_callback):
11471 Use the lwp's status_pending_p field, not the thread's.
11472
b90fc188
PA
114732015-03-19 Pedro Alves <palves@redhat.com>
11474
11475 * linux-low.c (select_event_lwp_callback): Update comments to
11476 no longer mention SIGTRAP.
11477
464b0089
GB
114782015-03-18 Gary Benson <gbenson@redhat.com>
11479
11480 * server.c (handle_query): Do not report vFile:fstat as supported.
11481
aa9e327f
GB
114822015-03-11 Gary Benson <gbenson@redhat.com>
11483
11484 * hostio.c (sys/types.h): New include.
11485 (sys/stat.h): Likewise.
11486 (common-remote-fileio.h): Likewise.
11487 (handle_fstat): New function.
11488 (handle_vFile): Handle vFile:fstat packets.
aa9e327f 11489
791c0056
GB
114902015-03-11 Gary Benson <gbenson@redhat.com>
11491
11492 * configure.ac (AC_CHECK_MEMBERS): Add checks for
11493 struct stat.st_blocks and struct stat.st_blksize.
11494 * configure: Regenerate.
11495 * config.in: Likewise.
11496 * Makefile.in (SFILES): Add common/common-remote-fileio.c.
11497 (OBS): Add common-remote-fileio.o.
11498 (common-remote-fileio.o): New rule.
11499
9a9df970
PA
115002015-03-09 Pedro Alves <palves@redhat.com>
11501
11502 * tracepoint.c (gdb_agent_helper_thread): Cast '&sockaddr' to
11503 'struct sockaddr' pointer in 'accept' call.
11504
9eb1356e
PA
115052015-03-09 Pedro Alves <palves@redhat.com>
11506
11507 Revert:
11508 2015-03-07 Pedro Alves <palves@redhat.com>
11509 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
11510 or <winsock2.h> here. Instead include "gdb_socket.h".
11511 (remote_open): Use union gdb_sockaddr_u.
11512 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
11513 or <winsock2.h> here. Instead include "gdb_socket.h".
11514 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
11515 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
11516 or <sys/un.h>.
11517 (init_named_socket, gdb_agent_helper_thread): Use union
11518 gdb_sockaddr_u.
11519
aac331e4
PA
115202015-03-07 Pedro Alves <palves@redhat.com>
11521
11522 * configure.ac (build_warnings): Move
11523 -Wdeclaration-after-statement to the C-specific set.
11524 * configure: Regenerate.
11525
366c75fc
PA
115262015-03-07 Pedro Alves <palves@redhat.com>
11527
11528 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
11529 or <winsock2.h> here. Instead include "gdb_socket.h".
11530 (remote_open): Use union gdb_sockaddr_u.
11531 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
11532 or <winsock2.h> here. Instead include "gdb_socket.h".
11533 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
11534 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
11535 or <sys/un.h>.
11536 (init_named_socket, gdb_agent_helper_thread): Use union
11537 gdb_sockaddr_u.
11538
492d29ea
PA
115392015-03-07 Pedro Alves <palves@redhat.com>
11540
11541 Adjust all callers of TRY_CATCH to use TRY/CATCH/END_CATCH
11542 instead.
11543
60a191ed
YQ
115442015-03-06 Yao Qi <yao.qi@linaro.org>
11545
11546 * linux-aarch64-low.c (aarch64_insert_point): Use
11547 show_debug_regs as a boolean.
11548 (aarch64_remove_point): Likewise.
11549
f5771b1d
PA
115502015-03-05 Pedro Alves <palves@redhat.com>
11551
11552 * lynx-low.c (lynx_target_ops): Install NULL hooks for
11553 stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
11554 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint.
11555 * nto-low.c (nto_target_ops): Likewise.
11556 * spu-low.c (spu_target_ops): Likewise.
11557 * win32-low.c (win32_target_ops): Likewise.
11558
3e572f71
PA
115592015-03-04 Pedro Alves <palves@redhat.com>
11560
72f4393d 11561 * linux-low.c (check_stopped_by_breakpoint) [USE_SIGTRAP_SIGINFO]:
3e572f71
PA
11562 Decide whether a breakpoint triggered based on the SIGTRAP's
11563 siginfo.si_code.
72f4393d
L
11564 (thread_still_has_status_pending_p) [USE_SIGTRAP_SIGINFO]: Don't check whether a
11565 breakpoint is inserted if relying on SIGTRAP's siginfo.si_code.
3e572f71
PA
11566 (linux_low_filter_event): Check for breakpoints before checking
11567 watchpoints.
11568 (linux_wait_1): Don't re-increment the PC if relying on SIGTRAP's
11569 siginfo.si_code.
72f4393d
L
11570 (linux_stopped_by_sw_breakpoint)
11571 (linux_supports_stopped_by_sw_breakpoint)
11572 (linux_stopped_by_hw_breakpoint)
11573 (linux_supports_stopped_by_hw_breakpoint): New functions.
11574 (linux_target_ops): Install new target methods.
3e572f71 11575
1ec68e26
PA
115762015-03-04 Pedro Alves <palves@redhat.com>
11577
11578 * remote-utils.c (prepare_resume_reply): Report swbreak/hbreak.
11579 * server.c (swbreak_feature, hwbreak_feature): New globals.
11580 (handle_query) <qSupported>: Handle "swbreak+" and "hwbreak+".
11581 (captured_main): Clear swbreak_feature and hwbreak_feature.
11582 * server.h (swbreak_feature, hwbreak_feature): Declare.
11583 * target.h (struct target_ops) <stopped_by_sw_breakpoint,
11584 supports_stopped_by_sw_breakpoint, stopped_by_hw_breakpoint,
11585 supports_stopped_by_hw_breakpoint>: New fields.
11586 (target_supports_stopped_by_sw_breakpoint)
11587 (target_stopped_by_sw_breakpoint)
11588 (target_supports_stopped_by_hw_breakpoint)
11589 (target_stopped_by_hw_breakpoint): Declare.
11590
15c66dd6
PA
115912015-03-04 Pedro Alves <palves@redhat.com>
11592
11593 enum lwp_stop_reason -> enum target_stop_reason
11594 * linux-low.c (check_stopped_by_breakpoint): Adjust.
11595 (thread_still_has_status_pending_p, check_stopped_by_watchpoint)
11596 (linux_wait_1, stuck_in_jump_pad_callback)
11597 (move_out_of_jump_pad_callback, linux_resume_one_lwp)
11598 (linux_stopped_by_watchpoint):
11599 * linux-low.h (enum lwp_stop_reason): Delete.
11600 (struct lwp_info) <stop_reason>: Now an enum target_stop_reason.
11601 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
11602
98fc70d6
YQ
116032015-03-04 Yao Qi <yao.qi@linaro.org>
11604
11605 * Makefile.in (SFILES): Add linux-aarch64-low.c.
11606
dd2ac174
GB
116072015-03-03 Gary Benson <gbenson@redhat.com>
11608
11609 * hostio.c (handle_vFile): Fix prefix lengths.
11610
d68e53f4
MM
116112015-03-03 Markus Metzger <markus.t.metzger@intel.com>
11612
11613 * linux-low.c (linux_low_enable_btrace): Do not overwrite non-zero
11614 ptr_bits.
11615
bf2d68ab
AA
116162015-03-02 Andreas Arnez <arnez@linux.vnet.ibm.com>
11617
11618 * Makefile.in (s390-vx-linux64.c, s390-tevx-linux64.c)
11619 (s390x-vx-linux64.c, s390x-tevx-linux64.c): New rules.
11620 (clean): Add "rm -f" for above C files.
11621 * configure.srv (srv_regobj): Add s390-vx-linux64.o,
11622 s390-tevx-linux64.o, s390x-vx-linux64.o, and s390x-tevx-linux64.o.
11623 (srv_xmlfiles): Add s390-vx-linux64.xml, s390-tevx-linux64.xml,
11624 s390x-vx-linux64.xml, s390x-tevx-linux64.xml, and s390-vx.xml.
11625 * linux-s390-low.c (HWCAP_S390_VX): New macro.
11626 (init_registers_s390_vx_linux64, init_registers_s390_tevx_linux64)
11627 (init_registers_s390x_vx_linux64)
11628 (init_registers_s390x_tevx_linux64)
11629 (tdesc_s390_vx_linux64, tdesc_s390_tevx_linux64)
11630 (tdesc_s390x_vx_linux64, tdesc_s390x_tevx_linux64): New extern
11631 declarations.
11632 (s390_fill_vxrs_low, s390_store_vxrs_low, s390_fill_vxrs_high)
11633 (s390_store_vxrs_high): New functions.
11634 (s390_regsets): Add entries for NT_S390_VXRS_LOW and
11635 NT_S390_VXRS_HIGH.
11636 (s390_arch_setup): Add logic for selecting one of the new target
11637 descriptions. Activate the new vector regsets if applicable.
11638 (initialize_low_arch): Also invoke init_registers_s390_vx_linux64,
11639 init_registers_s390_tevx_linux64, init_registers_s390x_vx_linux64,
11640 and init_registers_s390x_tevx_linux64.
11641
c966a859
PA
116422015-03-01 Pedro Alves <palves@redhat.com>
11643
11644 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Constify 'raw_regs'
11645 parameter.
11646
4180215b
PA
116472015-02-27 Pedro Alves <palves@redhat.com>
11648
11649 * linux-x86-low.c (u_debugreg_offset): New function.
11650 (x86_linux_dr_get, x86_linux_dr_set): Use it.
11651
749bab01
PA
116522015-02-27 Pedro Alves <palves@redhat.com>
11653
11654 * gdb_proc_service.h: Wrap with EXTERN_C_PUSH/EXTERN_C_POP.
11655 [!HAVE_PROC_SERVICE_H] (struct ps_prochandle): Forward declare.
11656 [!HAVE_PROC_SERVICE_H] (ps_pdread, ps_pdwrite, ps_ptread)
11657 ps_ptwrite, ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
11658 (ps_lsetfpregs, ps_getpid)
11659 (ps_get_thread_area, ps_pglobal_lookup, ps_pstop, ps_pcontinue)
11660 (ps_lstop, ps_lcontinue, ps_lgetxregsize, ps_lgetxregs)
11661 (ps_lsetxregs, ps_plog): Declare.
11662
3c14e5a3
PA
116632015-02-27 Pedro Alves <palves@redhat.com>
11664
11665 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Use
11666 IP_AGENT_EXPORT_FUNC.
11667 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Use
11668 IP_AGENT_EXPORT_FUNC.
11669 * tracepoint.c (ATTR_USED, ATTR_NOINLINE, ATTR_CONSTRUCTOR)
11670 (IP_AGENT_EXPORT): Delete.
11671 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
11672 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
11673 (gdb_trampoline_buffer_error, collecting, gdb_collect)
11674 (stop_tracing, flush_trace_buffer, about_to_request_buffer_space)
11675 (trace_buffer_is_full, stopping_tracepoint, expr_eval_result)
11676 (error_tracepoint, tracepoints, tracing, trace_buffer_ctrl)
11677 (trace_buffer_ctrl_curr, trace_buffer_lo, trace_buffer_hi)
11678 (traceframe_read_count, traceframe_write_count)
11679 (traceframes_created, trace_state_variables, get_raw_reg)
11680 (get_trace_state_variable_value, set_trace_state_variable_value)
11681 (ust_loaded, helper_thread_id, cmd_buf): Use
11682 IPA_SYM_EXPORTED_NAME.
11683 (stop_tracing, flush_trace_buffer): Use IP_AGENT_EXPORT_FUNC.
11684 (tracepoints) Use IP_AGENT_EXPORT_VAR.
11685 (stopping_tracepoint, trace_buffer_is_full, expr_eval_result): Use
11686 IP_AGENT_EXPORT_VAR and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
11687 (last_tracepoint): Move into !IN_PROCESS_AGENT block.
11688 (error_tracepoint): Use IP_AGENT_EXPORT_VAR and wrap in
11689 EXTERN_C_PUSH/EXTERN_C_POP.
11690 (trace_state_variables): Use IP_AGENT_EXPORT_VAR.
11691 (trace_buffer_lo, trace_buffer_hi): Use IP_AGENT_EXPORT_VAR and
11692 wrap in EXTERN_C_PUSH/EXTERN_C_POP.
11693 (trace_buffer_ctrl, trace_buffer_ctrl_curr)
11694 (traceframe_write_count, traceframe_read_count)
11695 (traceframes_created, tracing): Use IP_AGENT_EXPORT_VAR.
11696 (about_to_request_buffer_space, get_trace_state_variable_value)
11697 (set_trace_state_variable_value): Use IP_AGENT_EXPORT_FUNC.
11698 (collecting): Use IP_AGENT_EXPORT_VAR and wrap in
11699 EXTERN_C_PUSH/EXTERN_C_POP.
11700 (gdb_collect): Use IP_AGENT_EXPORT_FUNC.
11701 (ust_loaded, cmd_buf): Use IP_AGENT_EXPORT_VAR.
11702 (helper_thread_id, gdb_agent_capability): Use IP_AGENT_EXPORT_VAR
11703 and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
11704 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
11705 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
11706 (gdb_trampoline_buffer_error): Use IP_AGENT_EXPORT_VAR.
11707 * tracepoint.h (ATTR_USED, ATTR_NOINLINE, EXPORTED_SYMBOL):
11708 Define.
11709 (IP_AGENT_EXPORT_FUNC, IP_AGENT_EXPORT_VAR)
11710 (IP_AGENT_EXPORT_VAR_DECL): Define.
11711 (tracing): Declare.
11712 (gdb_agent_get_raw_reg): Declare.
11713
fe978cb0
PA
117142015-02-27 Tom Tromey <tromey@redhat.com>
11715 Pedro Alves <palves@redhat.com>
11716
11717 Rename symbols whose names are reserved C++ keywords throughout.
11718
3bc3d82a
PA
117192015-02-27 Pedro Alves <palves@redhat.com>
11720
11721 * Makefile.in (COMPILER): New, get it from autoconf.
11722 (CXX): Get from autoconf instead.
11723 (COMPILE.pre): Use COMPILER.
11724 (CC-LD): Rename to ...
11725 (CC_LD): ... this. Use COMPILER.
11726 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT), $(IPA_LIB)): Adjust.
11727 (CXX_FOR_TARGET): Default to g++ instead of gcc.
11728 * acinclude.m4: Include build-with-cxx.m4.
11729 * configure.ac: Call AC_PROG_CXX and GDB_AC_BUILD_WITH_CXX.
11730 Disable -Werror by default if building in C++ mode.
11731 (build_warnings): Add -Wno-sign-compare, -Wno-write-strings and
11732 -Wno-narrowing in C++ mode. Run supported-warning-flags tests with
11733 the C++ compiler. Save/restore CXXFLAGS too.
11734 * configure: Regenerate.
11735
07697489
PA
117362015-02-27 Pedro Alves <palves@redhat.com>
11737
11738 * acinclude.m4: Include libiberty.m4.
11739 * configure.ac: Call libiberty_INIT.
11740 * config.in, configure: Regenerate.
11741
9beb7c4e
PA
117422015-02-26 Pedro Alves <palves@redhat.com>
11743
11744 * linux-low.c (linux_wait_1): When incrementing the PC past a
11745 program breakpoint always use the_low_target.breakpoint_len as
11746 increment, rather than the maximum between that and
11747 the_low_target.decr_pc_after_break.
11748
8090aef2
PA
117492015-02-23 Pedro Alves <palves@redhat.com>
11750
11751 * linux-low.c (check_stopped_by_breakpoint): Don't check if the
11752 thread was doing a step-over; always adjust the PC if
11753 we stepped over a permanent breakpoint.
11754 (linux_wait_1): If we stepped over breakpoint that was on top of a
11755 permanent breakpoint, manually advance the PC past it.
11756
bc9540e8
PA
117572015-02-23 Pedro Alves <palves@redhat.com>
11758
11759 * linux-x86-low.c (REGSIZE): Define in both 32-bit and 64-bit
11760 modes.
11761 (x86_fill_gregset, x86_store_gregset): Use it when handling
11762 $orig_eax.
11763
2db9a427
PA
117642015-02-20 Pedro Alves <palves@redhat.com>
11765
11766 * thread-db.c: Include "nat/linux-procfs.h".
11767 (thread_db_init): Skip listing new threads if the kernel supports
11768 PTRACE_EVENT_CLONE and /proc/PID/task/ is accessible.
11769
afa8d396
PA
117702015-02-20 Pedro Alves <palves@redhat.com>
11771
11772 * linux-low.c (status_pending_p_callback): Use ptid_match.
11773
c9587f88
AT
117742015-02-19 Antoine Tremblay <antoine.tremblay@ericsson.com>
11775
11776 PR breakpoints/16812
11777 * linux-low.c (wstatus_maybe_breakpoint): Remove.
11778 (linux_low_filter_event): Update wstatus_maybe_breakpoint name.
11779 (linux_wait_1): Report SIGTRAP,SIGILL,SIGSEGV.
11780
b05ec7a5
AT
117812015-02-10 Antoine Tremblay <antoine.tremblay@ericsson.com>
11782
11783 PR breakpoints/15956
11784 * tracepoint.c (cmd_qtinit): Add check for current_thread.
11785
d33501a5
MM
117862015-02-09 Markus Metzger <markus.t.metzger@intel.com>
11787
11788 * linux-low.c (linux_low_btrace_conf): Print size.
11789 * server.c (handle_btrace_conf_general_set): New.
11790 (hanle_general_set): Call handle_btrace_conf_general_set.
11791 (handle_query): Report Qbtrace-conf:bts:size as supported.
11792
f4abbc16
MM
117932015-02-09 Markus Metzger <markus.t.metzger@intel.com>
11794
11795 * linux-low.c (linux_low_enable_btrace): Update parameters.
11796 (linux_low_btrace_conf): New.
11797 (linux_target_ops)<to_btrace_conf>: Initialize.
11798 * server.c (current_btrace_conf): New.
11799 (handle_btrace_enable): Rename to ...
11800 (handle_btrace_enable_bts): ... this. Pass &current_btrace_conf
11801 to target_enable_btrace. Update comment. Update users.
11802 (handle_qxfer_btrace_conf): New.
11803 (qxfer_packets): Add btrace-conf entry.
11804 (handle_query): Report qXfer:btrace-conf:read as supported packet.
11805 * target.h (target_ops)<enable_btrace>: Update parameters and comment.
11806 (target_ops)<read_btrace_conf>: New.
11807 (target_enable_btrace): Update parameters.
11808 (target_read_btrace_conf): New.
11809
043c3577
MM
118102015-02-09 Markus Metzger <markus.t.metzger@intel.com>
11811
11812 * server.c (handle_btrace_general_set): Remove call to
11813 target_supports_btrace.
11814 (supported_btrace_packets): New.
11815 (handle_query): Call supported_btrace_packets.
11816 * target.h: include btrace-common.h.
11817 (btrace_target_info): Removed.
11818 (supports_btrace, target_supports_btrace): Update parameters.
11819
734b0e4b
MM
118202015-02-09 Markus Metzger <markus.t.metzger@intel.com>
11821
11822 * Makefile.in (SFILES): Add common/btrace-common.c.
11823 (OBS): Add common/btrace-common.o.
11824 (btrace-common.o): Add build rules.
11825 * linux-low: Include btrace-common.h.
11826 (linux_low_read_btrace): Use struct btrace_data. Call
11827 btrace_data_init and btrace_data_fini.
11828
d6c146e9
PA
118292015-02-06 Pedro Alves <palves@redhat.com>
11830
11831 * thread-db.c (find_new_threads_callback): Add debug output.
11832
20ba1ce6
PA
118332015-02-04 Pedro Alves <palves@redhat.com>
11834
11835 * linux-low.c (handle_extended_wait): Don't resume LWPs here.
11836 (resume_stopped_resumed_lwps): New function.
11837 (linux_wait_for_event_filtered): Use it.
11838
8cc73a39
SDJ
118392015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
11840
11841 * Makefile.in (SFILES): Add linux-personality.c.
11842 (linux-personality.o): New rule.
11843 * configure.srv (srv_linux_obj): Add linux-personality.o to the
11844 list of objects to be built.
11845 * linux-low.c: Include nat/linux-personality.h.
11846 (linux_create_inferior): Remove code to disable address space
11847 randomization (moved to ../nat/linux-personality.c). Create
11848 cleanup to disable address space randomization.
11849
fb23d554
SDJ
118502015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
11851
11852 * Makefile.in (posix-strerror.o): New rule.
11853 (mingw-strerror.o): Likewise.
11854 * configure: Regenerated.
11855 * configure.ac: Source file ../common/common.host. Initialize new
11856 variable srv_host_obs. Add srv_host_obs to GDBSERVER_DEPFILES.
11857
cdf43629
YQ
118582015-01-14 Yao Qi <yao@codesourcery.com>
11859
11860 * Makefile.in (SFILES): Add nat/ppc-linux.c.
11861 (ppc-linux.o): New rule.
11862 * configure.srv (powerpc*-*-linux*): Add ppc-linux.o.
11863 * configure.ac: AC_CHECK_FUNCS(getauxval).
11864 * config.in: Re-generated.
11865 * configure: Re-generated.
11866 * linux-ppc-low.c (ppc_arch_setup) [__powerpc64__]: Call
11867 ppc64_64bit_inferior_p
11868
514c5338
YQ
118692015-01-14 Yao Qi <yao@codesourcery.com>
11870
11871 * linux-ppc-low.c: Include "nat/ppc-linux.h".
11872 (PPC_FEATURE_HAS_VSX): Move to nat/ppc-linux.h.
11873 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Likewise.
11874 (PT_ORIG_R3, PT_TRAP): Likewise.
11875 (PTRACE_GETVSXREGS, PTRACE_SETVSXREGS): Likewise.
11876 (PTRACE_GETVRREGS, PTRACE_SETVRREGS): Likewise.
11877 (PTRACE_GETEVRREGS, PTRACE_SETEVRREGS): Likewise.
11878
3368c1e5
JB
118792015-01-10 Joel Brobecker <brobecker@adacore.com>
11880
11881 * i387-fp.c (i387_cache_to_xsave): In look over
11882 num_avx512_zmmh_high_registers, replace use of struct i387_xsave
11883 zmmh_low_space field by use of zmmh_high_space.
11884
582511be
PA
118852015-01-09 Pedro Alves <palves@redhat.com>
11886
11887 * linux-low.c (step_over_bkpt): Move higher up in the file.
11888 (handle_extended_wait): Don't store the stop_pc here.
11889 (get_stop_pc): Adjust comments and rename to ...
11890 (check_stopped_by_breakpoint): ... this. Record whether the LWP
11891 stopped for a software breakpoint or hardware breakpoint.
11892 (thread_still_has_status_pending_p): New function.
11893 (status_pending_p_callback): Use
11894 thread_still_has_status_pending_p. If the event is no longer
11895 interesting, resume the LWP.
11896 (handle_tracepoints): Add assert.
11897 (maybe_move_out_of_jump_pad): Remove cancel_breakpoints call.
11898 (wstatus_maybe_breakpoint): New function.
11899 (cancel_breakpoint): Delete function.
11900 (check_stopped_by_watchpoint): New function, factored out from
11901 linux_low_filter_event.
11902 (lp_status_maybe_breakpoint): Delete function.
11903 (linux_low_filter_event): Remove filter_ptid argument.
11904 Leave thread group exits pending here. Store the LWP's stop PC.
11905 Always leave events pending.
11906 (linux_wait_for_event_filtered): Pull all events out of the
11907 kernel, and leave them all pending.
11908 (count_events_callback, select_event_lwp_callback): Consider all
11909 events.
11910 (cancel_breakpoints_callback, linux_cancel_breakpoints): Delete.
11911 (select_event_lwp): Only give preference to the stepping LWP in
11912 all-stop mode. Adjust comments.
11913 (ignore_event): New function.
11914 (linux_wait_1): Delete 'retry' label. Use ignore_event. Remove
11915 references to cancel_breakpoints. Adjust to renames. Also give
11916 equal priority to all LWPs that have had events in non-stop mode.
11917 If reporting a software breakpoint event, unadjust the LWP's PC.
11918 (linux_wait): If linux_wait_1 returned an ignored event, retry.
11919 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback):
11920 Adjust.
11921 (linux_resume_one_lwp): Store the LWP's PC. Adjust.
11922 (resume_status_pending_p): Use thread_still_has_status_pending_p.
11923 (linux_stopped_by_watchpoint): Adjust.
11924 (linux_target_ops): Remove reference to linux_cancel_breakpoints.
11925 * linux-low.h (enum lwp_stop_reason): New.
11926 (struct lwp_info) <stop_pc>: Adjust comment.
11927 <stopped_by_watchpoint>: Delete field.
11928 <stop_reason>: New field.
11929 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
11930 * mem-break.c (software_breakpoint_inserted_here)
11931 (hardware_breakpoint_inserted_here): New function.
11932 * mem-break.h (software_breakpoint_inserted_here)
11933 (hardware_breakpoint_inserted_here): Declare.
11934 * target.h (struct target_ops) <cancel_breakpoints>: Remove field.
11935 (cancel_breakpoints): Delete.
11936 * tracepoint.c (clear_installed_tracepoints, stop_tracing)
11937 (upload_fast_traceframes): Remove references to
11938 cancel_breakpoints.
11939
a33e3959
PA
119402015-01-09 Pedro Alves <palves@redhat.com>
11941
11942 * thread-db.c (find_new_threads_callback): Ignore thread if the
11943 kernel thread ID is -1.
11944
8784d563
PA
119452015-01-09 Pedro Alves <palves@redhat.com>
11946
11947 * linux-low.c (linux_attach_fail_reason_string): Move to
11948 nat/linux-ptrace.c, and rename.
11949 (linux_attach_lwp): Update comment.
11950 (attach_proc_task_lwp_callback): New function.
11951 (linux_attach): Adjust to rename and use
11952 linux_proc_attach_tgid_threads.
11953 (linux_attach_fail_reason_string): Delete declaration.
11954
76f2b779
JB
119552015-01-01 Joel Brobecker <brobecker@adacore.com>
11956
11957 * gdbreplay.c (gdbreplay_version): Update copyright year to 2015.
11958 * server.c (gdbserver_version): Likewise.
11959
fafcc06a
SDJ
119602014-12-29 Sergio Durigan Junior <sergiodj@redhat.com>
11961
11962 * remote-utils.c: Include ctype.h.
11963 (input_interrupt): Explicitly handle the case when the char
11964 received is the NUL byte. Improve the printing of non-ASCII
11965 characters.
11966
beed38b8
JB
119672014-12-16 Joel Brobecker <brobecker@adacore.com>
11968
11969 * linux-low.c (linux_low_filter_event): Update call to
11970 linux_enable_event_reporting following the addition of
11971 a new parameter to that function.
11972
bf330350
CU
119732014-12-16 Catalin Udma <catalin.udma@freescale.com>
11974
11975 PR server/17457
11976 * linux-aarch64-low.c (AARCH64_FPSR_REGNO): New define.
11977 (AARCH64_FPCR_REGNO): Likewise.
11978 (AARCH64_NUM_REGS): Update to include fpsr/fpcr registers.
11979 (aarch64_fill_fpregset): Add missing fpsr/fpcr registers.
11980 (aarch64_store_fpregset): Likewise.
11981
5227d625
JB
119822014-12-15 Joel Brobecker <brobecker@adacore.com>
11983
11984 * lynx-low.c (lynx_resume): Use PTRACE_SINGLESTEP_ONE if N == 1.
11985 Remove FIXME comment about assumption about N.
11986
f93b65a0
JB
119872014-12-13 Joel Brobecker <brobecker@adacore.com>
11988
11989 * configure.ac: If large-file support is disabled in GDBserver,
11990 pass --disable-largefile to ACX_CONFIGURE_DIR call for "gnulib".
11991 * configure: Regenerate.
11992
e5a9158d
AA
119932014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
11994
11995 * linux-low.c (regsets_fetch_inferior_registers): Suppress the
11996 warning upon ENODATA from ptrace.
11997 * linux-s390-low.c (s390_store_tdb): New.
11998 (s390_regsets): Add regset for NT_S390_TDB.
11999
feea5f36
AA
120002014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
12001
12002 * linux-low.c (regsets_store_inferior_registers): Skip regsets
12003 without a fill_function.
12004 * linux-s390-low.c (s390_fill_last_break): Remove.
12005 (s390_regsets): Set fill_function to NULL for NT_S390_LAST_BREAK.
12006 (s390_arch_setup): Use regset's size instead of fill_function for
12007 loop end condition.
12008
098dbe61
AA
120092014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
12010
12011 * linux-low.c (regsets_fetch_inferior_registers): Do not invoke
12012 the regset's store function when ptrace returned an error.
12013 * regcache.c (get_thread_regcache): Invalidate register cache
12014 before fetching inferior's registers.
12015
28eef672
AA
120162014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
12017
12018 * linux-low.c (regsets_fetch_inferior_registers): Rephrase
12019 while-loop as for-loop.
12020 (regsets_store_inferior_registers): Likewise.
12021
bdca27a2
YQ
120222014-11-28 Yao Qi <yao@codesourcery.com>
12023
12024 * configure.ac(AC_CHECK_FUNCS): Remove readlink.
12025 * config.in, configure: Re-generate.
12026 * hostio.c (handle_unlink): Remove code checking HAVE_READLINK
12027 is defined.
12028
9c232dda
YQ
120292014-11-21 Yao Qi <yao@codesourcery.com>
12030
12031 * configure.ac: Don't invoke AC_FUNC_ALLOCA.
12032 (AC_CHECK_HEADERS): Remove malloc.h.
12033 * configure: Re-generated.
12034 * config.in: Re-generated.
12035 * server.h: Don't include alloca.h and malloc.h.
12036 * gdbreplay.c: Don't check HAVE_ALLOCA_H is defined.
12037 Don't include malloc.h.
12038
43968415
JB
120392014-11-17 Joel Brobecker <brobecker@adacore.com>
12040
12041 * lynx-low.c (lynx_write_memory): Put lynx_read_memory and
12042 corresponding ERRNO check in same block.
12043
40e91bc7
PA
120442014-11-12 Pedro Alves <palves@redhat.com>
12045
12046 * server.c (cont_thread): Update comment.
12047 (start_inferior, attach_inferior): No longer clear cont_thread.
12048 (handle_v_cont): No longer set cont_thread.
12049 (captured_main): Clear cont_thread each time a GDB connects.
12050
c2c118cf
PA
120512014-11-12 Pedro Alves <palves@redhat.com>
12052
12053 * linux-low.c (linux_wait_1): Don't force a wait for the Hc
12054 thread, and don't resume all threads if the Hc thread has exited.
12055
78708b7c
PA
120562014-11-12 Pedro Alves <palves@redhat.com>
12057
12058 * linux-low.c (linux_request_interrupt): Always send a SIGINT to
12059 the process group instead of to a specific LWP.
12060
a2abc7de
PA
120612014-10-15 Pedro Alves <palves@redhat.com>
12062
12063 PR server/17487
12064 * win32-arm-low.c (arm_set_thread_context): Remove current_event
12065 parameter.
12066 (arm_set_thread_context): Delete.
12067 (the_low_target): Adjust.
12068 * win32-i386-low.c (debug_registers_changed)
12069 (debug_registers_used): Delete.
12070 (update_debug_registers_callback): New function.
12071 (x86_dr_low_set_addr, x86_dr_low_set_control): Mark all threads as
12072 needing to update their debug registers.
12073 (win32_get_current_dr): New function.
12074 (x86_dr_low_get_addr, x86_dr_low_get_control)
12075 (x86_dr_low_get_status): Fetch the debug register from the thread
12076 record's context.
12077 (i386_initial_stuff): Adjust.
12078 (i386_get_thread_context): Remove current_event parameter. Don't
12079 clear debug_registers_changed nor copy DR values to
12080 debug_reg_state.
12081 (i386_set_thread_context): Delete.
12082 (i386_prepare_to_resume): New function.
12083 (i386_thread_added): Mark the thread as needing to update irs
12084 debug registers.
12085 (the_low_target): Remove i386_set_thread_context and install
12086 i386_prepare_to_resume.
12087 * win32-low.c (win32_get_thread_context): Adjust.
12088 (win32_set_thread_context): Use SetThreadContext
12089 directly.
12090 (win32_prepare_to_resume): New function.
12091 (win32_require_context): New function, factored out from ...
12092 (thread_rec): ... this.
12093 (continue_one_thread): Call win32_prepare_to_resume on each thread
12094 we're about to continue.
12095 (win32_resume): Call win32_prepare_to_resume on the event thread.
12096 * win32-low.h (struct win32_thread_info)
12097 <debug_registers_changed>: New field.
12098 (struct win32_target_ops): Change prototype of set_thread_context,
12099 delete set_thread_context and add prepare_to_resume.
12100 (win32_require_context): New declaration.
12101
a442d071
GB
121022014-10-08 Gary Benson <gbenson@redhat.com>
12103
12104 * server.h: Do not include common-exceptions.h.
12105
6f1947e8
GB
121062014-10-08 Gary Benson <gbenson@redhat.com>
12107
12108 * server.h: Do not include cleanups.h.
12109
63b434a4
JH
121102014-09-30 James Hogan <james.hogan@imgtec.com>
12111
12112 * Makefile.in (clean): Add rm -f commands for mips-dsp-linux.c and
12113 mips64-dsp-linux.c.
12114
c4d9ceb6
YQ
121152014-09-23 Yao Qi <yao@codesourcery.com>
12116
12117 * linux-low.c (lp_status_maybe_breakpoint): New function.
12118 (linux_low_filter_event): Call lp_status_maybe_breakpoint.
12119 (count_events_callback): Likewise.
12120 (select_event_lwp_callback): Likewise.
12121 (cancel_breakpoints_callback): Likewise.
12122
89a5711c
DB
121232014-09-19 Don Breazeal <donb@codesourcery.com>
12124
12125 * linux-low.c (handle_extended_wait): Call
12126 linux_ptrace_get_extended_event.
12127 (get_stop_pc, get_detach_signal, linux_low_filter_event): Call
12128 linux_is_extended_waitstatus.
12129
bffc0964
JB
121302014-09-16 Joel Brobecker <brobecker@adacore.com>
12131
12132 * Makefile.in (CPPFLAGS): Define.
12133 (INTERNAL_CFLAGS_BASE): Add ${CPPFLAGS}.
12134 (IPAGENT_CFLAGS): Remove ${CPPFLAGS}.
12135
0bfdf32f
GB
121362014-09-16 Gary Benson <gbenson@redhat.com>
12137
12138 * inferiors.h (current_inferior): Renamed as...
12139 (current_thread): New variable. All uses updated.
12140 * linux-low.c (get_pc): Renamed saved_inferior as saved_thread.
12141 (maybe_move_out_of_jump_pad): Likewise.
12142 (cancel_breakpoint): Likewise.
12143 (linux_low_filter_event): Likewise.
12144 (wait_for_sigstop): Likewise.
12145 (linux_resume_one_lwp): Likewise.
12146 (need_step_over_p): Likewise.
12147 (start_step_over): Likewise.
12148 (linux_stabilize_threads): Renamed save_inferior as saved_thread.
12149 * linux-x86-low.c (x86_linux_update_xmltarget): Likewise.
12150 * proc-service.c (ps_lgetregs): Renamed reg_inferior as reg_thread
12151 and save_inferior as saved_thread.
12152 * regcache.c (get_thread_regcache): Renamed saved_inferior as
12153 saved_thread.
12154 (regcache_invalidate_thread): Likewise.
12155 * remote-utils.c (prepare_resume_reply): Likewise.
12156 * thread-db.c (thread_db_get_tls_address): Likewise.
12157 (disable_thread_event_reporting): Likewise.
12158 (remove_thread_event_breakpoints): Likewise.
12159 * tracepoint.c (gdb_agent_about_to_close): Renamed save_inferior
12160 as saved_thread.
12161 * target.h (set_desired_inferior): Renamed as...
12162 (set_desired_thread): New declaration. All uses updated.
12163 * server.c (myresume): Updated comment to reference thread instead
12164 of inferior.
12165 (handle_serial_event): Likewise.
12166 (handle_target_event): Likewise.
12167
361c8ade
GB
121682014-09-12 Tom Tromey <tromey@redhat.com>
12169 Gary Benson <gbenson@redhat.com>
12170
12171 * regcache.h: Include common-regcache.h.
12172 (regcache_read_pc): Don't declare.
12173 * regcache.c (get_thread_regcache_for_ptid): New function.
12174
bd9269f7
GB
121752014-09-11 Tom Tromey <tromey@redhat.com>
12176 Gary Benson <gbenson@redhat.com>
12177
12178 * symbol.c: New file.
12179 * Makefile.in (SFILES): Add symbol.c.
12180 (OBS): Add symbol.o.
12181
f8c1d06b
GB
121822014-09-11 Gary Benson <gbenson@redhat.com>
12183
12184 * target.c (target_stop_ptid, target_continue_ptid): New
12185 functions.
12186
721ec300
GB
121872014-09-11 Tom Tromey <tromey@redhat.com>
12188 Gary Benson <gbenson@redhat.com>
12189
12190 * target.h: Include target/target.h.
12191 * target.c (target_read_memory, target_read_uint32)
12192 (target_write_memory): New functions.
12193
c5e92cca
GB
121942014-09-11 Gary Benson <gbenson@redhat.com>
12195
12196 * server.h (debug_hw_points): Don't declare.
12197 * server.c (debug_hw_points): Don't define. Replace all uses
12198 with show_debug_regs.
12199 * linux-aarch64-low.c (debug_hw_points): Don't define. Replace
12200 all uses with show_debug_regs.
12201
2e4bb98a
EBM
122022014-09-08 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
12203
12204 * linux-ppc-low.c (ppc_collect_ptrace_register): Adjust routine to take
12205 endianness into account.
12206 (ppc_supply_ptrace_register): Likewise.
12207
ac740bc7
JH
122082014-09-03 James Hogan <james.hogan@imgtec.com>
12209
12210 * linux-mips-low.c (mips_read_description): Reset errno to 0 prior
12211 to reading DSP_CONTROL with PTRACE_PEEKUSER ptrace call.
12212
97ea6506
GB
122132014-09-03 Gary Benson <gbenson@redhat.com>
12214
12215 * linux-x86-low.c (x86_linux_prepare_to_resume): Use
12216 ALL_DEBUG_ADDRESS_REGISTERS.
12217
df7e5265
GB
122182014-09-02 Gary Benson <gbenson@redhat.com>
12219
12220 * i386-low.h: Renamed as...
12221 * x86-low.h: New file. All type, function and variable name
12222 prefixes changed from "i386_" to "x86_". All references updated.
12223 * i386-low.c: Renamed as...
12224 * x86-low.c: New file. All type, function and variable name
12225 prefixes changed from "i386_" to "x86_". All references updated.
12226
ed859da7
GB
122272014-09-02 Gary Benson <gbenson@redhat.com>
12228
12229 * linux-x86-low.c (x86_linux_new_process): Use XCNEW.
12230 (x86_linux_new_thread): Likewise.
12231
860789c7
GB
122322014-08-29 Gary Benson <gbenson@redhat.com>
12233
12234 * server.h (setjmp.h): Do not include.
12235 (toplevel): Do not declare.
12236 (common-exceptions.h): Include.
12237 (cleanups.h): Likewise.
12238 * server.c (toplevel): Do not define.
12239 (exit_code): New static global.
12240 (detach_or_kill_for_exit_cleanup): New function.
12241 (main): New function. Original main renamed to...
12242 (captured_main): New function.
12243 * utils.c (verror) [!IN_PROCESS_AGENT]: Use throw_verror.
12244
ff55e1b5
GB
122452014-08-29 Gary Benson <gbenson@redhat.com>
12246
12247 * Makefile.in (SFILES): Add common/common-exceptions.c.
12248 (OBS): Add common-exceptions.o.
12249 (common-exceptions.o): New rule.
12250 * utils.c (prepare_to_throw_exception): New function.
12251
e9bcb658
GB
122522014-08-29 Gary Benson <gbenson@redhat.com>
12253
12254 * config.in: Regenerate.
12255 * configure: Likewise.
12256
e3180625
GB
122572014-08-29 Gary Benson <gbenson@redhat.com>
12258
12259 * Makefile.in (SFILES): Add common/cleanups.c.
12260 (OBS): cleanups.o.
12261 (cleanups.o): New rule.
12262
e3d6ba5d
GB
122632014-08-29 Gary Benson <gbenson@redhat.com>
12264
12265 * utils.c (internal_vwarning): New function.
12266
7096e886
GB
122672014-08-28 Gary Benson <gbenson@redhat.com>
12268
12269 * utils.h (fatal): Remove declaration.
12270 * utils.c (fatal): Remove function.
12271
14ce3192
GB
122722014-08-28 Gary Benson <gbenson@redhat.com>
12273
12274 * tracepoint.c (gdb_agent_init): Replace fatal with
12275 perror_with_name.
12276 (initialize_tracepoint): Likewise.
12277
50278d59
GB
122782014-08-28 Gary Benson <gbenson@redhat.com>
12279
12280 * remote-utils.c (remote_prepare): Replace fatal with error.
12281
aa96c426
GB
122822014-08-28 Gary Benson <gbenson@redhat.com>
12283
12284 * linux-low.c (linux_async): Replace fatal with warning.
12285 Tidy up and return.
12286 (linux_start_non_stop): Return -1 if linux_async failed.
12287
f7160e97
GB
122882014-08-28 Gary Benson <gbenson@redhat.com>
12289
12290 * linux-x86-low.c (i386_dr_low_set_addr): Replace check with
12291 gdb_assert.
12292 (i386_dr_low_get_addr): Remove vague comment.
12293 * win32-i386-low.c (i386_dr_low_set_addr): Replace check with
12294 gdb_assert.
12295
38e08fca
GB
122962014-08-28 Gary Benson <gbenson@redhat.com>
12297
12298 * inferiors.c (get_thread_process): Replace check with gdb_assert.
12299 * linux-low.c (linux_wait_for_event_filtered): Replace fatal with
12300 internal_error.
12301 (linux_resume_one_lwp): Likewise.
12302 * linux-x86-low.c (x86_siginfo_fixup): Replace checks with
12303 gdb_assert.
12304 * mem-break.c (raw_bkpt_type_to_target_hw_bp_type): Replace fatal
12305 with internal_error.
12306 * regcache.c (get_thread_regcache): Replace check with gdb_assert.
12307 (init_register_cache): Replace fatal with gdb_assert_not_reached.
12308 (find_register_by_name): Replace fatal with internal_error.
12309 (find_regno): Likewise.
12310 * tdesc.c (init_target_desc): Replace check with gdb_assert.
12311 * thread-db.c (thread_db_create_event): Likewise.
12312 (thread_db_load_search): Likewise.
12313 (try_thread_db_load_1): Likewise.
12314 * tracepoint.c (get_jump_space_head): Replace fatal with
12315 internal_error.
12316 (claim_trampoline_space): Likewise.
12317 (have_fast_tracepoint_trampoline_buffer): Likewise.
12318 (cmd_qtstart): Likewise.
12319 (stop_tracing): Likewise.
12320 (fast_tracepoint_collecting): Likewise.
12321 (target_malloc): Likewise.
12322 (download_tracepoint): Likewise.
12323 (download_trace_state_variables): Replace check with gdb_assert.
12324 (upload_fast_traceframes): Replace fatal with internal_error.
12325
34abf635
GB
123262014-08-19 Tom Tromey <tromey@redhat.com>
12327 Gary Benson <gbenson@redhat.com>
12328
12329 * Makefile.in (SFILES): Add common/common-debug.c.
12330 (OBS): Add common-debug.o.
12331 (common-debug.o): New rule.
12332 * debug.h (debug_printf): Don't declare.
12333 * debug.c (debug_printf): Renamed and rewritten as...
12334 (debug_vprintf): New function.
12335
f6e94d78
GB
123362014-08-19 Gary Benson <gbenson@redhat.com>
12337
12338 * utils.h: Do not include print-utils.h.
12339
9239eeab
GB
123402014-08-19 Tom Tromey <tromey@redhat.com>
12341 Gary Benson <gbenson@redhat.com>
12342
12343 * server.h: Add static assertion.
12344 (gdb_byte, CORE_ADDR, LONGEST, ULONGEST): Remove.
12345
ef87c8bb
GB
123462014-08-19 Tom Tromey <tromey@redhat.com>
12347 Gary Benson <gbenson@redhat.com>
12348
12349 * Makefile.in (SFILES): Add common/errors.c.
12350 (OBS): Add errors.o.
12351 (IPA_OBS): Add errors-ipa.o.
12352 (errors.o): New rule.
12353 (errors-ipa.o): Likewise.
12354 * utils.h (perror_with_name, error, warning): Don't declare.
12355 * utils.c (warning): Renamed and rewritten as...
12356 (vwarning): New function.
12357 (error): Renamed and rewritten as...
12358 (verror): New function.
12359 (internal_error): Renamed and rewritten as...
12360 (internal_verror): New function.
12361
bb974a24
GB
123622014-08-07 Gary Benson <gbenson@redhat.com>
12363
12364 * configure.ac (AC_CHECK_HEADERS): Remove errno.h.
12365 * configure: Regenerate.
12366 * config.in: Likewise.
12367 * server.h: Do not include errno.h.
12368 * event-loop.c: Likewise.
12369 * hostio-errno.c: Likewise.
12370 * linux-low.c: Likewise.
12371 * remote-utils.c: Likewise.
12372 * spu-low.c: Likewise.
12373 * utils.c: Likewise.
12374 * gdbreplay.c: Unconditionally include errno.h.
12375
6d3d12eb
GB
123762014-08-07 Gary Benson <gbenson@redhat.com>
12377
12378 * server.h: Do not include string.h.
12379 * event-loop.c: Likewise.
12380 * linux-low.c: Likewise.
12381 * regcache.c: Likewise.
12382 * remote-utils.c: Likewise.
12383 * spu-low.c: Likewise.
12384 * utils.c: Likewise.
12385
dccbb609
GB
123862014-08-07 Gary Benson <gbenson@redhat.com>
12387
12388 * server.h: Do not include gdb_assert.h.
12389
e76df0d0
GB
123902014-08-07 Gary Benson <gbenson@redhat.com>
12391
12392 * server.h: Do not include common-utils.h.
12393
4cb9c816
GB
123942014-08-07 Gary Benson <gbenson@redhat.com>
12395
12396 * server.h: Do not include ptid.h.
12397 * notif.h: Likewise.
12398
3995eeee
GB
123992014-08-07 Gary Benson <gbenson@redhat.com>
12400
12401 * server.h: Do not include gdb_locale.h.
12402
cb9f1a9b
GB
124032014-08-07 Gary Benson <gbenson@redhat.com>
12404
12405 * server.h: Do not include gdb/signals.h.
12406 * win32-low.c: Likewise.
12407
a5fceff8
GB
124082014-08-07 Gary Benson <gbenson@redhat.com>
12409
12410 * server.h: Do not include pathmax.h.
12411
b9391142
GB
124122014-08-07 Gary Benson <gbenson@redhat.com>
12413
12414 * server.h: Do not include libiberty.h.
12415 * linux-bfin-low.c: Likewise.
12416
0e443c87
GB
124172014-08-07 Gary Benson <gbenson@redhat.com>
12418
12419 * server.h: Do not include ansidecl.h.
12420
8ebb3f56
GB
124212014-08-07 Gary Benson <gbenson@redhat.com>
12422
12423 * linux-x86-low.c: Do not include stddef.h.
12424 * lynx-ppc-low.c: Likewise.
12425 * tracepoint.c: Likewise.
12426
8980bdf6
GB
124272014-08-07 Gary Benson <gbenson@redhat.com>
12428
12429 * server.h: Do not include stdarg.h.
12430 * nto-low.c: Likewise.
12431
d7096f71
GB
124322014-08-07 Gary Benson <gbenson@redhat.com>
12433
12434 * server.h: Do not include stdlib.h.
12435 * inferiors.c: Likewise.
12436 * linux-low.c: Likewise.
12437 * regcache.c: Likewise.
12438 * spu-low.c: Likewise.
12439 * tracepoint.c: Likewise.
12440 * utils.c: Likewise.
12441
d02f550d
GB
124422014-08-07 Gary Benson <gbenson@redhat.com>
12443
12444 * server.h: Do not include stdio.h.
12445 * linux-low.c: Likewise.
12446 * remote-utils.c: Likewise.
12447 * spu-low.c: Likewise.
12448 * utils.c: Likewise.
12449 * wincecompat.c: Likewise.
12450
87f6c4e3
GB
124512014-08-06 Gary Benson <gbenson@redhat.com>
12452
12453 * regcache.c (init_register_cache): Move conditionals inside if.
12454
7089dca4
GB
124552014-08-06 Gary Benson <gbenson@redhat.com>
12456
12457 * linux-low.c (linux_supports_non_stop): Use target_is_async_p.
12458
462f517e
GB
124592014-07-31 Gary Benson <gbenson@redhat.com>
12460
12461 * ax.h: Do not include server.h.
12462 * gdbthread.h: Likewise.
12463 * lynx-low.h: Likewise.
12464 * notif.h: Likewise.
12465
976411d6
GB
124662014-07-30 Gary Benson <gbenson@redhat.com>
12467
12468 * server.h: Include common-defs.h.
12469 Do not include config.h or build-gnulib-gdbserver/config.h.
12470
d41f6d8e
GB
124712014-07-30 Gary Benson <gbenson@redhat.com>
12472
12473 * hostio-errno.c: Move server.h to top of includes list.
12474 * inferiors.c: Likewise.
12475 * linux-x86-low.c: Likewise.
12476 * notif.c: Include server.h.
12477
314c6a35
TT
124782014-07-24 Tom Tromey <tromey@redhat.com>
12479 Gary Benson <gbenson@redhat.com>
12480
12481 * server.h (CORE_ADDR): Now unsigned.
12482
69ff6be5
PA
124832014-07-16 Pedro Alves <palves@redhat.com>
12484
12485 * linux-low.c (linux_kill_one_lwp): Use kill_lwp, not kill.
12486
ce9e3fe7
PA
124872014-07-15 Pedro Alves <palves@redhat.com>
12488
12489 * linux-low.c (linux_kill_one_lwp): Save errno and work with saved
12490 copy.
12491
e76126e8
PA
124922014-07-11 Pedro Alves <palves@redhat.com>
12493
12494 * linux-low.c (kill_wait_lwp): New function, based on
12495 kill_one_lwp_callback, but use my_waitpid directly.
12496 (kill_one_lwp_callback, linux_kill): Use it.
12497
8e9db26e
PA
124982014-06-23 Pedro Alves <palves@redhat.com>
12499
12500 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR_CONTROL
12501 before setting DR0..DR3.
12502
698b3e08
GB
125032014-06-20 Gary Benson <gbenson@redhat.com>
12504
12505 * configure.ac (AC_REPLACE_FUNCS) <vasprintf, vsnprintf>: Removed.
12506 * configure: Regenerated.
12507 * config.in: Likewise.
12508
125f8a3d
GB
125092014-06-20 Gary Benson <gbenson@redhat.com>
12510
12511 * Makefile.in (SFILES): Update locations for files moved
12512 from common to nat.
12513 (object file files): Reordered.
12514
42995dbd
GB
125152014-06-20 Gary Benson <gbenson@redhat.com>
12516
12517 * i386-low.h (i386_dr_low_can_set_addr): Removed.
12518 (i386_dr_low_set_addr): Likewise.
12519 (i386_dr_low_get_addr): Likewise.
12520 (i386_dr_low_can_set_control): Likewise.
12521 (i386_dr_low_set_control): Likewise.
12522 (i386_dr_low_get_control): Likewise.
12523 (i386_dr_low_get_status): Likewise.
12524 (i386_get_debug_register_length): Likewise.
12525 * linux-x86-low.c (i386_dr_low_set_addr):
12526 Changed signature. Made static.
12527 (i386_dr_low_get_addr): Likewise.
12528 (i386_dr_low_set_control): Likewise.
12529 (i386_dr_low_get_control): Likewise.
12530 (i386_dr_low_get_status): Likewise.
12531 (i386_dr_low): New global variable.
12532 * win32-i386-low.c (i386_dr_low_set_addr):
12533 Changed signature. Made static.
12534 (i386_dr_low_get_addr): Likewise.
12535 (i386_dr_low_set_control): Likewise.
12536 (i386_dr_low_get_control): Likewise.
12537 (i386_dr_low_get_status): Likewise.
12538 (i386_dr_low): New global variable.
12539
e1d2394b
MS
125402014-06-20 Marcus Shawcroft <marcus.shawcroft@arm.com>
12541
12542 * configure.ac: Invoke. AC_CHECK_TOOL(AR, ar).
12543 * Makefile.in (AR, AR_FLAGS): Define.
12544 * configure: Regenerate.
12545
3a8ee006
GB
125462014-06-19 Gary Benson <gbenson@redhat.com>
12547
12548 * Makefile.in (i386-dregs.o): New rule.
12549 * configure.srv: Add i386-dregs.o to all targets using i386-low.o.
12550 * i386-low.c (target.h): Remove include.
12551 (TARGET_HAS_DR_LEN_8): Now in i386-dregs.c.
12552 (DR_CONTROL_SHIFT): Likewise.
12553 (DR_CONTROL_SIZE): Likewise.
12554 (DR_RW_EXECUTE): Likewise.
12555 (DR_RW_WRITE): Likewise.
12556 (DR_RW_READ): Likewise.
12557 (DR_RW_IORW): Likewise.
12558 (DR_LEN_1): Likewise.
12559 (DR_LEN_2): Likewise.
12560 (DR_LEN_4): Likewise.
12561 (DR_LEN_8): Likewise.
12562 (DR_LOCAL_ENABLE_SHIFT): Likewise.
12563 (DR_GLOBAL_ENABLE_SHIFT): Likewise.
12564 (DR_ENABLE_SIZE): Likewise.
12565 (DR_LOCAL_SLOWDOWN): Likewise.
12566 (DR_GLOBAL_SLOWDOWN): Likewise.
12567 (DR_CONTROL_RESERVED): Likewise.
12568 (I386_DR_CONTROL_MASK): Likewise.
12569 (I386_DR_VACANT): Likewise.
12570 (I386_DR_LOCAL_ENABLE): Likewise.
12571 (I386_DR_GLOBAL_ENABLE): Likewise.
12572 (I386_DR_DISABLE): Likewise.
12573 (I386_DR_SET_RW_LEN): Likewise.
12574 (I386_DR_GET_RW_LEN): Likewise.
12575 (I386_DR_WATCH_HIT): Likewise.
12576 (i386_wp_op_t): Likewise.
12577 (i386_show_dr): Likewise.
12578 (i386_length_and_rw_bits): Likewise.
12579 (i386_insert_aligned_watchpoint): Likewise.
12580 (i386_remove_aligned_watchpoint): Likewise.
12581 (i386_handle_nonaligned_watchpoint): Likewise.
12582 i386_update_inferior_debug_regs(): Likewise.
12583 (i386_dr_insert_watchpoint): Likewise.
12584 (i386_dr_remove_watchpoint): Likewise.
12585 (i386_dr_region_ok_for_watchpoint): Likewise.
12586 (i386_dr_stopped_data_address): Likewise.
12587 (i386_dr_stopped_by_watchpoint): Likewise.
12588
8f26655c
GB
125892014-06-19 Gary Benson <gbenson@redhat.com>
12590
12591 * i386-low.c (i386_dr_show): Renamed to
12592 i386_show_dr and made static. All uses updated.
12593 (i386_dr_length_and_rw_bits): Renamed to
12594 i386_length_and_rw_bits and made static.
12595 All uses updated.
12596 (i386_dr_insert_aligned_watchpoint): Renamed to
12597 i386_insert_aligned_watchpoint and made static.
12598 All uses updated.
12599 (i386_dr_remove_aligned_watchpoint): Renamed to
12600 i386_remove_aligned_watchpoint and made static.
12601 All uses updated.
12602 (i386_dr_update_inferior_debug_regs): Renamed to
12603 i386_update_inferior_debug_regs and made static.
12604 All uses updated.
12605
b9228891
GB
126062014-06-18 Gary Benson <gbenson@redhat.com>
12607
5171def3
GB
12608 * i386-low.h (i386_dr_low_can_set_addr): New macro.
12609 (i386_dr_low_can_set_control): Likewise.
12610 (i386_get_debug_register_length): Likewise.
12611 * i386-low.c (i386_dr_low_can_set_addr): Now in i386-low.h.
12612 (i386_dr_low_can_set_control): Likewise.
12613 (i386_get_debug_register_length): Likewise.
12614
126152014-06-17 Gary Benson <gbenson@redhat.com>
12616
b9228891
GB
12617 * i386-low.h (i386-dregs.h): New include.
12618 (DR_FIRSTADDR): Now in i386-dregs.h.
12619 (DR_LASTADDR): Likewise.
12620 (DR_NADDR): Likewise.
12621 (DR_STATUS): Likewise.
12622 (DR_CONTROL): Likewise.
12623 (i386_debug_reg_state): Likewise.
12624 (i386_dr_insert_watchpoint): Likewise.
12625 (i386_dr_remove_watchpoint): Likewise.
12626 (i386_dr_region_ok_for_watchpoint): Likewise.
12627 (i386_dr_stopped_data_address): Likewise.
12628 (i386_dr_stopped_by_watchpoint): Likewise.
12629 * i386-low.c (ALL_DEBUG_REGISTERS): Likewise.
12630
4be83cc2
GB
126312014-06-18 Gary Benson <gbenson@redhat.com>
12632
12633 * i386-low.h (i386_low_insert_watchpoint): Renamed to
12634 i386_dr_insert_watchpoint.
12635 (i386_low_remove_watchpoint): Renamed to
12636 i386_dr_remove_watchpoint.
12637 (i386_low_region_ok_for_watchpoint): Renamed to
12638 i386_dr_region_ok_for_watchpoint.
12639 (i386_low_stopped_data_address): Renamed to
12640 i386_dr_stopped_data_address.
12641 (i386_low_stopped_by_watchpoint): Renamed to
12642 i386_dr_stopped_by_watchpoint.
12643 * i386-low.c (i386_show_dr): Renamed to
12644 i386_dr_show and made nonstatic. All uses updated.
12645 (i386_length_and_rw_bits): Renamed to
12646 i386_dr_length_and_rw_bits and made nonstatic.
12647 All uses updated.
12648 (i386_insert_aligned_watchpoint): Renamed to
12649 i386_dr_insert_aligned_watchpoint and made nonstatic.
12650 All uses updated.
12651 (i386_remove_aligned_watchpoint): Renamed to
12652 i386_dr_remove_aligned_watchpoint and made nonstatic.
12653 All uses updated.
12654 (i386_update_inferior_debug_regs): Renamed to
12655 i386_dr_update_inferior_debug_regs and made nonstatic.
12656 All uses updated.
12657 (i386_low_insert_watchpoint): Renamed to
12658 i386_dr_insert_watchpoint. All uses updated.
12659 (i386_low_remove_watchpoint): Renamed to
12660 i386_dr_remove_watchpoint. All uses updated.
12661 (i386_low_region_ok_for_watchpoint): Renamed to
12662 i386_dr_region_ok_for_watchpoint. All uses updated.
12663 (i386_low_stopped_data_address): Renamed to
12664 i386_dr_stopped_data_address. All uses updated.
12665 (i386_low_stopped_by_watchpoint): Renamed to
12666 i386_dr_stopped_by_watchpoint. All uses updated.
12667
131aa0d4
GB
126682014-06-18 Gary Benson <gbenson@redhat.com>
12669
12670 * i386-low.c (i386_dr_low_can_set_addr): New macro.
12671 (i386_dr_low_can_set_control): Likewise.
12672 (i386_insert_aligned_watchpoint): New check.
12673
d9305f7f
GB
126742014-06-18 Gary Benson <gbenson@redhat.com>
12675
12676 * i386-low.c (i386_update_inferior_debug_regs) <inf_state>:
12677 Renamed to state.
12678
e927c9fc
GB
126792014-06-18 Gary Benson <gbenson@redhat.com>
12680
12681 * i386-low.c (i386_length_and_rw_bits): Use internal_error
12682 instead of fatal and error.
12683 (i386_handle_nonaligned_watchpoint): Likewise.
12684
1b6d4134
GB
126852014-06-18 Gary Benson <gbenson@redhat.com>
12686
12687 * i386-low.c (i386_get_debug_register_length): New macro.
12688 (TARGET_HAS_DR_LEN_8): Remove conditional. Use above macro.
12689 (i386_show_dr): Use debug_printf instead of fprintf. Use
12690 phex to format values.
12691
6e62758f
GB
126922014-06-18 Gary Benson <gbenson@redhat.com>
12693
12694 * i386-low.h: Comment changes.
12695 * i386-low.c: Likewise.
12696
fc6e2f03
GB
126972014-06-18 Gary Benson <gbenson@redhat.com>
12698
12699 * i386-low.c: Whitespace changes.
12700
f9d1eeed
TT
127012014-06-12 Tom Tromey <tromey@redhat.com>
12702
12703 * utils.c (freeargv): Remove.
12704
0b04e523
TT
127052014-06-12 Tom Tromey <tromey@redhat.com>
12706
12707 * debug.c (debug_printf): Remove HAVE_GETTIMEOFDAY checks.
12708 * server.c (monitor_show_help): Remove HAVE_GETTIMEOFDAY check.
12709 (parse_debug_format_options): Likewise.
12710 (gdbserver_usage): Likewise.
12711 * Makefile.in (LIBIBERTY_BUILDDIR, LIBIBERTY): New variables.
12712 (SUBDIRS, REQUIRED_SUBDIRS): Add libiberty.
12713 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Depend on and link
12714 against libiberty.
12715 ($(LIBGNU)): Depend on libiberty.
12716 (all-lib): Recurse into all subdirs.
12717 (install-only): Invoke "install" target in subdirs.
12718 (vasprintf.o, vsnprintf.o, safe-ctype.o, lbasename.o): Remove
12719 targets.
12720 * configure: Rebuild.
12721 * configure.ac: Add ACX_CONFIGURE_DIR for libiberty. Don't check
12722 for vasprintf, vsnprintf, or gettimeofday.
12723 * configure.srv: Don't add safe-ctype.o or lbasename.o to
12724 srv_tgtobj.
12725
270c9937
JB
127262014-06-05 Joel Brobecker <brobecker@adacore.com>
12727
12728 * development.sh: Delete.
12729 * Makefile.in (config.status): Adjust dependency on development.sh.
12730 * configure.ac: Adjust development.sh source call.
12731 * configure: Regenerate.
12732
0a261ed8
PA
127332014-06-02 Pedro Alves <palves@redhat.com>
12734
12735 * ax.c (gdb_free_agent_expr): New function.
12736 * ax.h (gdb_free_agent_expr): New declaration.
12737 * mem-break.c (delete_gdb_breakpoint_1): Also clear the commands
12738 list.
12739 (clear_breakpoint_conditions, clear_breakpoint_commands): Make
12740 static.
12741 (clear_breakpoint_conditions_and_commands): New function.
12742 * mem-break.h (clear_breakpoint_conditions): Delete declaration.
12743 (clear_breakpoint_conditions_and_commands): New declaration.
12744
e9dae05e
RR
127452014-05-23 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
12746
12747 * linux-aarch64-low.c (asm/ptrace.h): Include.
12748
5876f503
JK
127492014-05-21 Jan Kratochvil <jan.kratochvil@redhat.com>
12750
12751 Fix TLS access for -static -pthread.
12752 * gdbserver/thread-db.c (struct thread_db): Add td_thr_tlsbase_p.
12753 (thread_db_get_tls_address): Call it if LOAD_MODULE is zero.
12754 (thread_db_load_search, try_thread_db_load_1): Initialize it.
12755
802e8e6d
PA
127562014-05-20 Pedro Alves <palves@redhat.com>
12757
12758 * linux-aarch64-low.c (aarch64_insert_point)
12759 (aarch64_remove_point): No longer check whether the type is
12760 supported here. Adjust to new interface.
12761 (the_low_target): Install aarch64_supports_z_point_type as
12762 supports_z_point_type method.
12763 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type): New function.
12764 (arm_linux_hw_point_initialize): Take an enum raw_bkpt_type
12765 instead of a Z packet char. Adjust.
12766 (arm_supports_z_point_type): New function.
12767 (arm_insert_point, arm_remove_point): Adjust to new interface.
12768 (the_low_target): Install arm_supports_z_point_type.
12769 * linux-crisv32-low.c (cris_supports_z_point_type): New function.
12770 (cris_insert_point, cris_remove_point): Adjust to new interface.
12771 Don't check whether the type is supported here.
12772 (the_low_target): Install cris_supports_z_point_type.
12773 * linux-low.c (linux_supports_z_point_type): New function.
12774 (linux_insert_point, linux_remove_point): Adjust to new interface.
12775 * linux-low.h (struct linux_target_ops) <insert_point,
12776 remove_point>: Take an enum raw_bkpt_type instead of a char. Add
12777 raw_breakpoint pointer parameter.
12778 <supports_z_point_type>: New method.
12779 * linux-mips-low.c (mips_supports_z_point_type): New function.
12780 (mips_insert_point, mips_remove_point): Adjust to new interface.
12781 Use mips_supports_z_point_type.
12782 (the_low_target): Install mips_supports_z_point_type.
12783 * linux-ppc-low.c (the_low_target): Install NULL as
12784 supports_z_point_type method.
12785 * linux-s390-low.c (the_low_target): Install NULL as
12786 supports_z_point_type method.
12787 * linux-sparc-low.c (the_low_target): Install NULL as
12788 supports_z_point_type method.
12789 * linux-x86-low.c (x86_supports_z_point_type): New function.
12790 (x86_insert_point): Adjust to new insert_point interface. Use
12791 insert_memory_breakpoint. Adjust to new
12792 i386_low_insert_watchpoint interface.
12793 (x86_remove_point): Adjust to remove_point interface. Use
12794 remove_memory_breakpoint. Adjust to new
12795 i386_low_remove_watchpoint interface.
12796 (the_low_target): Install x86_supports_z_point_type.
12797 * lynx-low.c (lynx_target_ops): Install NULL as
12798 supports_z_point_type callback.
12799 * nto-low.c (nto_supports_z_point_type): New.
12800 (nto_insert_point, nto_remove_point): Adjust to new interface.
12801 (nto_target_ops): Install nto_supports_z_point_type.
12802 * mem-break.c: Adjust intro comment.
12803 (struct raw_breakpoint) <raw_type, size>: New fields.
12804 <inserted>: Update comment.
12805 <shlib_disabled>: Delete field.
12806 (enum bkpt_type) <gdb_breakpoint>: Delete value.
12807 <gdb_breakpoint_Z0, gdb_breakpoint_Z1, gdb_breakpoint_Z2,
12808 gdb_breakpoint_Z3, gdb_breakpoint_Z4>: New values.
12809 (raw_bkpt_type_to_target_hw_bp_type): New function.
12810 (find_enabled_raw_code_breakpoint_at): New function.
12811 (find_raw_breakpoint_at): New type and size parameters. Use them.
12812 (insert_memory_breakpoint): New function, based off
12813 set_raw_breakpoint_at.
12814 (remove_memory_breakpoint): New function.
12815 (set_raw_breakpoint_at): Reimplement.
12816 (set_breakpoint): New, based on set_breakpoint_at.
12817 (set_breakpoint_at): Reimplement.
12818 (delete_raw_breakpoint): Go through the_target->remove_point
12819 instead of assuming memory breakpoints.
12820 (find_gdb_breakpoint_at): Delete.
12821 (Z_packet_to_bkpt_type, Z_packet_to_raw_bkpt_type): New functions.
12822 (find_gdb_breakpoint): New function.
12823 (set_gdb_breakpoint_at): Delete.
12824 (z_type_supported): New function.
12825 (set_gdb_breakpoint_1): New function, loosely based off
12826 set_gdb_breakpoint_at.
12827 (check_gdb_bp_preconditions, set_gdb_breakpoint): New functions.
12828 (delete_gdb_breakpoint_at): Delete.
12829 (delete_gdb_breakpoint_1): New function, loosely based off
12830 delete_gdb_breakpoint_at.
12831 (delete_gdb_breakpoint): New function.
12832 (clear_gdb_breakpoint_conditions): Rename to ...
12833 (clear_breakpoint_conditions): ... this. Don't handle a NULL
12834 breakpoint.
12835 (add_condition_to_breakpoint): Make static.
12836 (add_breakpoint_condition): Take a struct breakpoint pointer
12837 instead of an address. Adjust.
12838 (gdb_condition_true_at_breakpoint): Rename to ...
12839 (gdb_condition_true_at_breakpoint_z_type): ... this, and add
12840 z_type parameter.
12841 (gdb_condition_true_at_breakpoint): Reimplement.
12842 (add_breakpoint_commands): Take a struct breakpoint pointer
12843 instead of an address. Adjust.
12844 (gdb_no_commands_at_breakpoint): Rename to ...
12845 (gdb_no_commands_at_breakpoint_z_type): ... this. Add z_type
12846 parameter. Return true if no breakpoint was found. Change debug
12847 output.
12848 (gdb_no_commands_at_breakpoint): Reimplement.
12849 (run_breakpoint_commands): Rename to ...
12850 (run_breakpoint_commands_z_type): ... this. Add z_type parameter,
12851 and change return type to boolean.
12852 (run_breakpoint_commands): New function.
12853 (gdb_breakpoint_here): Also check for Z1 breakpoints.
12854 (uninsert_raw_breakpoint): Don't try to reinsert a disabled
12855 breakpoint. Go through the_target->remove_point instead of
12856 assuming memory breakpoint.
12857 (uninsert_breakpoints_at, uninsert_all_breakpoints): Uninsert
12858 software and hardware breakpoints.
12859 (reinsert_raw_breakpoint): Go through the_target->insert_point
12860 instead of assuming memory breakpoint.
12861 (reinsert_breakpoints_at, reinsert_all_breakpoints): Reinsert
12862 software and hardware breakpoints.
12863 (check_breakpoints, breakpoint_here, breakpoint_inserted_here):
12864 Check both software and hardware breakpoints.
12865 (validate_inserted_breakpoint): Assert the breakpoint is a
12866 software breakpoint. Set the inserted flag to -1 instead of
12867 setting shlib_disabled.
12868 (delete_disabled_breakpoints): Adjust.
12869 (validate_breakpoints): Only validate software breakpoints.
12870 Adjust to inserted flag change.
12871 (check_mem_read, check_mem_write): Skip breakpoint types other
12872 than software breakpoints. Adjust to inserted flag change.
12873 * mem-break.h (enum raw_bkpt_type): New enum.
12874 (raw_breakpoint, struct process_info): Forward declare.
12875 (Z_packet_to_target_hw_bp_type): Delete declaration.
12876 (raw_bkpt_type_to_target_hw_bp_type, Z_packet_to_raw_bkpt_type)
12877 (set_gdb_breakpoint, delete_gdb_breakpoint)
12878 (clear_breakpoint_conditions): New declarations.
12879 (set_gdb_breakpoint_at, clear_gdb_breakpoint_conditions): Delete.
12880 (breakpoint_inserted_here): Update comment.
12881 (add_breakpoint_condition, add_breakpoint_commands): Replace
12882 address parameter with a breakpoint pointer parameter.
12883 (gdb_breakpoint_here): Update comment.
12884 (delete_gdb_breakpoint_at): Delete.
12885 (insert_memory_breakpoint, remove_memory_breakpoint): Declare.
12886 * server.c (process_point_options): Take a struct breakpoint
12887 pointer instead of an address. Adjust.
12888 (process_serial_event) <Z/z packets>: Use set_gdb_breakpoint and
12889 delete_gdb_breakpoint.
12890 * spu-low.c (spu_target_ops): Install NULL as
12891 supports_z_point_type method.
12892 * target.h: Include mem-break.h.
12893 (struct target_ops) <prepare_to_access_memory>: Update comment.
12894 <supports_z_point_type>: New field.
12895 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
12896 instead of a char. Also take a raw breakpoint pointer.
12897 * win32-arm-low.c (the_low_target): Install NULL as
12898 supports_z_point_type.
12899 * win32-i386-low.c (i386_supports_z_point_type): New function.
12900 (i386_insert_point, i386_remove_point): Adjust to new interface.
12901 (the_low_target): Install i386_supports_z_point_type.
12902 * win32-low.c (win32_supports_z_point_type): New function.
12903 (win32_insert_point, win32_remove_point): Adjust to new interface.
12904 (win32_target_ops): Install win32_supports_z_point_type.
12905 * win32-low.h (struct win32_target_ops):
12906 <supports_z_point_type>: New method.
12907 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
12908 instead of a char. Also take a raw breakpoint pointer.
12909
932539e3
PA
129102014-05-20 Pedro Alves <palves@redhat.com>
12911
12912 * mem-break.h: Include break-common.h.
12913 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
12914 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): New defines.
12915 (Z_packet_to_target_hw_bp_type): New declaration.
12916 * mem-break.c (Z_packet_to_target_hw_bp_type): New function.
12917 * i386-low.c (Z_PACKET_HW_BP, Z_PACKET_WRITE_WP, Z_PACKET_READ_WP)
12918 (Z_PACKET_ACCESS_WP): Delete macros.
12919 (Z_packet_to_hw_type): Delete function.
12920 * i386-low.h: Don't include break-common.h here.
12921 (Z_packet_to_hw_type): Delete declaration.
12922 * linux-x86-low.c (x86_insert_point, x86_insert_point): Call
12923 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
12924 * win32-i386-low.c (i386_insert_point, i386_remove_point): Call
12925 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
12926 * linux-aarch64-low.c: Don't include break-common.h here.
12927 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
12928 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): Delete macros.
12929 (Z_packet_to_target_hw_bp_type): Delete function.
12930 * linux-mips-low.c (rsp_bp_type_to_target_hw_bp_type): Delete
12931 function.
12932 (mips_insert_point, mips_remove_point): Use
12933 Z_packet_to_target_hw_bp_type.
12934
4ff0d3d8
PA
129352014-05-20 Pedro Alves <palves@redhat.com>
12936
12937 * linux-aarch64-low.c: Include break-common.h.
12938 (enum target_point_type): Delete.
12939 (Z_packet_to_point_type): Rename to ...
12940 (Z_packet_to_target_hw_bp_type): ... this, and return a
12941 target_hw_bp_type instead.
12942 (aarch64_show_debug_reg_state): Take an enum target_hw_bp_type
12943 instead of an enum target_point_type.
12944 (aarch64_point_encode_ctrl_reg): Likewise. Compute type mask from
12945 breakpoint type.
12946 (aarch64_dr_state_insert_one_point)
12947 (aarch64_dr_state_remove_one_point, aarch64_handle_breakpoint)
12948 (aarch64_handle_aligned_watchpoint)
12949 (aarch64_handle_unaligned_watchpoint, aarch64_handle_watchpoint):
12950 Take an enum target_hw_bp_type instead of an enum
12951 target_point_type.
12952 (aarch64_supports_z_point_type): New function.
12953 (aarch64_insert_point, aarch64_remove_point): Use it. Adjust to
12954 use Z_packet_to_target_hw_bp_type.
12955
786dc519
JB
129562014-05-20 Joel Brobecker <brobecker@adacore.com>
12957
12958 * configure.ac: Only use -Werror by default when DEVELOPMENT
12959 is true.
12960 * configure: Regenerate.
12961
9e0aa64f
JK
129622014-05-19 Jan Kratochvil <jan.kratochvil@redhat.com>
12963
12964 Fix gdbserver qGetTLSAddr for x86_64 -m32.
12965 * linux-x86-low.c (X86_64_USER_REGS): New.
12966 (x86_fill_gregset): Call memset for BUF first in x86_64 -m32 case.
12967
2b577b92
YQ
129682014-04-28 Yao Qi <yao@codesourcery.com>
12969
12970 * Makefile.in (i386-avx512.c): Fix the typo of generated file
12971 name.
12972
94611da2
PA
129732014-04-25 Pedro Alves <palves@redhat.com>
12974
12975 PR server/16255
12976 * linux-low.c (linux_attach_fail_reason_string): New function.
12977 (linux_attach_lwp): Delete.
12978 (linux_attach_lwp_1): Rename to ...
12979 (linux_attach_lwp): ... this. Take a ptid instead of a pid as
12980 argument. Remove "initial" parameter. Return int instead of
12981 void. Don't error or warn here.
12982 (linux_attach): Adjust to call linux_attach_lwp. Call error on
12983 failure to attach to the tgid. Call warning when failing to
12984 attach to an lwp.
12985 * linux-low.h (linux_attach_lwp): Take a ptid instead of a pid as
12986 argument. Remove "initial" parameter. Return int instead of
12987 void. Don't error or warn here.
12988 (linux_attach_fail_reason_string): New declaration.
12989 * thread-db.c (attach_thread): Adjust to linux_attach_lwp's
12990 interface change. Use linux_attach_fail_reason_string.
12991
01f9f808
MS
129922014-04-24 Michael Sturm <michael.sturm@mintel.com>
12993 Walfred Tedeschi <walfred.tedeschi@intel.com>
12994
12995 * Makefile.in: Added rules to handle new files
12996 i386-avx512.c i386-avx512-linux.c amd64-avx512.c
12997 amd64-avx512-linux.c x32-avx512.c x32-avx512-linux.c.
12998 * configure.srv (srv_i386_regobj): Add i386-avx512.o.
12999 (srv_i386_linux_regobj): Add i386-avx512-linux.o.
13000 (srv_amd64_regobj): Add amd64-avx512.o and x32-avx512.o.
13001 (srv_amd64_linux_regobj): Add amd64-avx512-linux.o and
13002 x32-avx512-linux.o.
13003 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx512.xml.
13004 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx512.xml.
13005 (srv_amd64_xmlfiles): Add i386/amd64-avx512.xml and
13006 i386/x32-avx512.xml.
13007 (srv_i386_linux_xmlfiles): Add i386/i386-avx512-linux.xml.
13008 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx512-linux.xml and
13009 i386/x32-avx512-linux.xml.
13010 * i387-fp.c (num_avx512_k_registers): New constant for number
13011 of K registers.
13012 (num_avx512_zmmh_low_registers): New constant for number of
13013 lower ZMM registers (0-15).
13014 (num_avx512_zmmh_high_registers): New constant for number of
13015 higher ZMM registers (16-31).
13016 (num_avx512_ymmh_registers): New contant for number of higher
13017 YMM registers (ymm16-31 added by avx521 on x86_64).
13018 (num_avx512_xmm_registers): New constant for number of higher
13019 XMM registers (xmm16-31 added by AVX512 on x86_64).
13020 (struct i387_xsave): Add space for AVX512 registers.
13021 (i387_cache_to_xsave): Change raw buffer size to 64 characters.
13022 Add code to handle AVX512 registers.
13023 (i387_xsave_to_cache): Add code to handle AVX512 registers.
13024 * linux-x86-low.c (init_registers_amd64_avx512_linux): New
13025 prototypei from generated file.
13026 (tdesc_amd64_avx512_linux): Likewise.
13027 (init_registers_x32_avx512_linux): Likewise.
13028 (tdesc_x32_avx512_linux): Likewise.
13029 (init_registers_i386_avx512_linux): Likewise.
13030 (tdesc_i386_avx512_linux): Likewise.
13031 (x86_64_regmap): Add AVX512 registers.
13032 (x86_linux_read_description): Add code to handle AVX512 XSTATE
13033 mask.
13034 (initialize_low_arch): Add code to initialize AVX512 registers.
13035
51aa91f9
PA
130362014-04-23 Pedro Alves <palves@redhat.com>
13037
13038 * mem-break.c (find_gdb_breakpoint_at): Make static.
13039 * mem-break.h (find_gdb_breakpoint_at): Delete declaration.
13040
a4165e94
PA
130412014-04-23 Pedro Alves <palves@redhat.com>
13042
13043 * i386-low.c: Don't include break-common.h here.
13044 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
13045 prototype to take target_hw_bp_type as argument instead of a Z
13046 packet char.
13047 * i386-low.h: Include break-common.h here.
13048 (Z_packet_to_hw_type): Declare.
13049 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
13050 prototypes.
13051 * linux-x86-low.c (x86_insert_point): Convert the packet number to
13052 a target_hw_bp_type before calling i386_low_insert_watchpoint.
13053 (x86_remove_point): Convert the packet number to a
13054 target_hw_bp_type before calling i386_low_remove_watchpoint.
13055 * win32-i386-low.c (i386_insert_point): Convert the packet number
13056 to a target_hw_bp_type before calling i386_low_insert_watchpoint.
13057 (i386_remove_point): Convert the packet number to a
13058 target_hw_bp_type before calling i386_low_remove_watchpoint.
13059
b8acf843
PA
130602014-04-23 Pedro Alves <palves@redhat.com>
13061
13062 * utils.h (perror_with_name): Add ATTRIBUTE_NORETURN.
13063
d708bcd1
PA
130642014-04-10 Pedro Alves <palves@redhat.com>
13065
13066 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
13067 Check if the condition or command is NULL before checking if the
13068 breakpoint is known. On success, return true.
13069 * mem-break.h (add_breakpoint_condition): Document return.
13070 (add_breakpoint_commands): Add describing comment.
13071 * server.c (skip_to_semicolon): New function.
13072 (process_point_options): Use it.
13073
2eec7d5b
PA
130742014-04-09 Pedro Alves <palves@redhat.com>
13075
13076 * linux-low.c (linux_read_loadmap): Pass current_inferior directly
13077 to lwpid_of.
13078
fa96cb38
PA
130792014-02-27 Pedro Alves <palves@redhat.com>
13080
13081 PR 12702
13082 * inferiors.h (A_I_NEXT, ALL_INFERIORS_TYPE, ALL_PROCESSES): New
13083 macros.
13084 * linux-low.c (delete_lwp, handle_extended_wait): Add debug
13085 output.
13086 (last_thread_of_process_p): Take a PID argument instead of a
13087 thread pointer.
13088 (linux_wait_for_lwp): Delete.
13089 (num_lwps, check_zombie_leaders, not_stopped_callback): New
13090 functions.
13091 (linux_low_filter_event): New function, party factored out from
13092 linux_wait_for_event.
13093 (linux_wait_for_event): Rename to ...
13094 (linux_wait_for_event_filtered): ... this. Add new filter ptid
13095 argument. Partly rewrite. Always use waitpid(-1, WNOHANG) and
13096 sigsuspend. Check for zombie leaders.
13097 (linux_wait_for_event): Reimplement as wrapper around
13098 linux_wait_for_event_filtered.
13099 (linux_wait_1): Handle TARGET_WAITKIND_NO_RESUMED. Assume that if
13100 a normal or signal exit is seen, it's the whole process exiting.
13101 (wait_for_sigstop): No longer a for_each_inferior callback.
13102 Rewrite on top of linux_wait_for_event_filtered.
13103 (stop_all_lwps): Call wait_for_sigstop directly.
13104 * server.c (resume, handle_target_event): Handle
13105 TARGET_WAITKIND_NO_RESUMED.
13106
d763de10
JB
131072014-02-26 Joel Brobecker <brobecker@adacore.com>
13108
13109 * win32-low.c (psapi_get_dll_name,
13110 * win32_CreateToolhelp32Snapshot): Delete.
13111 (win32_CreateToolhelp32Snapshot, win32_Module32First)
13112 (win32_Module32Next, load_toolhelp, toolhelp_get_dll_name):
13113 Delete.
13114 (handle_load_dll): Add function description.
13115 Remove code using psapi_get_dll_name and toolhelp_get_dll_name.
13116
850a0f76
JB
131172014-02-26 Joel Brobecker <brobecker@adacore.com>
13118
13119 * win32-low.c (win32_add_one_solib): Add 0x1000 to load_addr.
13120 Add comment.
13121 (win32_add_all_dlls): Remove 0x1000 offset applied to DLL
13122 base address when calling win32_add_one_solib.
13123 (handle_load_dll): Delete local variable load_addr.
13124 Remove 0x1000 offset applied to DLL base address when calling
13125 win32_add_one_solib.
13126 (handle_unload_dll): Add comment.
13127
f25b3fc3
JB
131282014-02-26 Joel Brobecker <brobecker@adacore.com>
13129
13130 * win32-low.c (win32_add_all_dlls): Renames
13131 win32_ensure_ntdll_loaded. Rewrite function documentation.
13132 Adjust implementation to always load all DLLs.
13133 Add 0x1000 offset to DLL base address when calling
13134 win32_add_one_solib.
13135 (child_initialization_done): New static global.
13136 (do_initial_child_stuff): Set child_initialization_done to
13137 zero during child initialization, and 1 after. Replace call
13138 to win32_ensure_ntdll_loaded by call to win32_add_all_dlls.
13139 Add comment.
13140 (match_dll_by_basename, dll_is_loaded_by_basename): Delete.
13141 (handle_unload_dll): Add function documentation.
13142 (get_child_debug_event): Ignore load and unload DLL events
13143 during child initialization.
13144
d86d4aaf
DE
131452014-02-20 Doug Evans <dje@google.com>
13146
3bc32da3 13147 Remove global all_lwps.
d86d4aaf
DE
13148 * inferiors.h (ptid_of): Move here from linux-low.h.
13149 (pid_of, lwpid_of): Ditto.
13150 * linux-aarch64-low.c (debug_reg_change_callback): Update, "entry"
13151 parameter is a struct thread_info * now.
13152 (aarch64_notify_debug_reg_change): Fetch pid from current_inferior
13153 directly. Pass &all_threads to find_inferior instead of &all_lwps.
13154 (aarch64_stopped_data_address): Fetch lwpid from current_inferior
13155 directly.
13156 (aarch64_linux_prepare_to_resume): Fetch ptid from thread.
13157 (aarch64_arch_setup): Fetch lwpid from current_inferior directly.
13158 * linux-arm-low.c (update_registers_callback): Update, "entry"
13159 parameter is a struct thread_info * now.
13160 Fetch lwpid from current_inferior directly.
13161 (arm_insert_point): Pass &all_threads to find_inferior instead of
13162 &all_lwps.
13163 (arm_remove_point): Ditto.
13164 (arm_stopped_by_watchpoint): Fetch lwp from current_inferior.
13165 (arm_prepare_to_resume): Fetch pid from thread.
13166 (arm_read_description): Fetch lwpid from current_inferior directly.
13167 * linux-low.c (all_lwps): Delete.
13168 (delete_lwp): Delete call to remove_inferior.
13169 (handle_extended_wait): Fetch lwpid from thread.
13170 (add_lwp): Don't set lwp->entry.id. Remove call to
13171 add_inferior_to_list.
13172 (linux_attach_lwp_1): Fetch pid from current_inferior directly.
13173 (linux_kill_one_lwp): Fetch ptid,lwpid from thread.
13174 (kill_one_lwp_callback): Ditto.
13175 (linux_kill): Don't dereference NULL pointer.
13176 Fetch ptid,lwpid from thread.
13177 (get_detach_signal): Fetch ptid from thread.
13178 (linux_detach_one_lwp): Fetch ptid,lwpid from thread.
13179 Simplify call to regcache_invalidate_thread.
13180 (delete_lwp_callback): Update, "entry" parameter is a
13181 struct thread_info * now. Fetch pid from thread.
13182 (linux_mourn): Pass &all_threads to find_inferior instead of &all_lwps.
13183 (status_pending_p_callback): Update, "entry" parameter is a
13184 struct thread_info * now. Fetch ptid from thread.
13185 (find_lwp_pid): Update, "entry" parameter is a
13186 struct thread_info * now.
13187 (linux_wait_for_lwp): Fetch pid from thread.
13188 (linux_fast_tracepoint_collecting): Fetch lwpid from thread.
13189 (maybe_move_out_of_jump_pad): Fetch lwpid from current_inferior.
13190 (enqueue_one_deferred_signal): Fetch lwpid from thread.
13191 (dequeue_one_deferred_signal): Ditto.
13192 (cancel_breakpoint): Fetch ptid from current_inferior.
13193 (linux_wait_for_event): Pass &all_threads to find_inferior,
13194 not &all_lwps. Fetch ptid, lwpid from thread.
13195 (count_events_callback): Update, "entry" parameter is a
13196 struct thread_info * now.
13197 (select_singlestep_lwp_callback): Ditto.
13198 (select_event_lwp_callback): Ditto.
13199 (cancel_breakpoints_callback): Ditto.
13200 (linux_cancel_breakpoints): Pass &all_threads to find_inferior,
13201 not &all_lwps.
13202 (select_event_lwp): Ditto. Fetch ptid from event_thread.
13203 (unsuspend_one_lwp): Update, "entry" parameter is a
13204 struct thread_info * now.
13205 (unsuspend_all_lwps): Pass &all_threads to find_inferior,
13206 not &all_lwps.
13207 (linux_stabilize_threads): Ditto. And for for_each_inferior.
13208 Fetch lwpid from thread, not lwp.
13209 (linux_wait_1): Fetch ptid, lwpid from current_inferior.
13210 Pass &all_threads to find_inferior, not &all_lwps.
13211 (send_sigstop): Fetch lwpid from thread, not lwp.
13212 (send_sigstop_callback): Update, "entry" parameter is a
13213 struct thread_info * now.
13214 (suspend_and_send_sigstop_callback): Ditto.
13215 (wait_for_sigstop): Ditto. Fetch ptid, lwpid from thread, lwp.
13216 (stuck_in_jump_pad_callback): Update, "entry" parameter is a
13217 struct thread_info * now.
13218 (move_out_of_jump_pad_callback): Ditto. Fetch ptid, lwpid
13219 from thread, lwp.
13220 (lwp_running): Update, "entry" parameter is a
13221 struct thread_info * now.
13222 (stop_all_lwps): Fetch ptid from thread.
13223 Pass &all_threads to find_inferior, for_each_inferior, not &all_lwps.
13224 (linux_resume_one_lwp): Fetch lwpid from thread.
13225 (linux_set_resume_request): Update, "entry" parameter is a
13226 struct thread_info * now. Fetch pid, lwpid from thread.
13227 (resume_status_pending_p): Update, "entry" parameter is a
13228 struct thread_info * now.
13229 (need_step_over_p): Ditto. Fetch lwpid from thread.
13230 (start_step_over): Fetch lwpid from thread.
13231 (linux_resume_one_thread): Update, "entry" parameter is a
13232 struct thread_info * now. Fetch lwpid from thread.
13233 (linux_resume): Pass &all_threads to find_inferior, not &all_lwps.
13234 (proceed_one_lwp): Update, "entry" parameter is a
13235 struct thread_info * now. Fetch lwpid from thread.
13236 (unsuspend_and_proceed_one_lwp): Update, "entry" parameter is a
13237 struct thread_info * now.
13238 (proceed_all_lwps): Pass &all_threads to find_inferior, not &all_lwps.
13239 (unstop_all_lwps): Ditto. Fetch lwpid from thread.
13240 (regsets_fetch_inferior_registers): Fetch lwpid from current_inferior
13241 directly.
13242 (regsets_store_inferior_registers): Ditto.
13243 (fetch_register, store_register): Ditto.
13244 (linux_read_memory, linux_write_memory): Ditto.
13245 (linux_request_interrupt): Ditto.
13246 (linux_read_auxv): Ditto.
13247 (linux_xfer_siginfo): Ditto.
13248 (linux_qxfer_spu): Ditto.
13249 (linux_qxfer_libraries_svr4): Ditto.
13250 * linux-low.h (ptid_of, pid_of, lwpid_of): Delete,
13251 moved to inferiors.h.
13252 (get_lwp): Delete.
13253 (get_thread_lwp): Update.
13254 (struct lwp_info): Delete member "entry". Simplify comment for
13255 member "thread".
13256 (all_lwps): Delete.
13257 * linux-mips-low.c (mips_read_description): Fetch lwpid from
13258 current_inferior directly.
13259 (update_watch_registers_callback): Update, "entry" parameter is a
13260 struct thread_info * now. Fetch pid from thread.
13261 (mips_linux_prepare_to_resume): Fetch ptid from thread.
13262 (mips_insert_point): Fetch lwpid from current_inferior.
13263 Pass &all_threads to find_inferior, not &all_lwps.
13264 (mips_remove_point): Pass &all_threads to find_inferior, not &all_lwps.
13265 (mips_stopped_by_watchpoint): Fetch lwpid from current_inferior
13266 directly.
13267 (mips_stopped_data_address): Ditto.
13268 * linux-s390-low.c (s390_arch_setup): Fetch pid from current_inferior
13269 directly.
13270 * linux-tile-low.c (tile_arch_setup): Ditto.
13271 * linux-x86-low.c (x86_get_thread_area): Fetch lwpid from thread.
13272 (update_debug_registers_callback): Update, "entry" parameter is a
13273 struct thread_info * now. Fetch pid from thread.
13274 (i386_dr_low_set_addr): Fetch pid from current_inferior directly.
13275 Pass &all_threads to find_inferior, not &all_lwps.
13276 (i386_dr_low_get_addr): Fetch ptid from current_inferior directly.
13277 (i386_dr_low_set_control): Fetch pid from current_inferior directly.
13278 Pass &all_threads to find_inferior, not &all_lwps.
13279 (i386_dr_low_get_control): Fetch ptid from current_inferior directly.
13280 (i386_dr_low_get_status): Ditto.
13281 (x86_linux_prepare_to_resume): Fetch ptid from thread.
13282 (x86_siginfo_fixup): Fetch lwpid from current_inferior directly.
13283 (x86_linux_read_description): Ditto.
13284 * proc-service.c (ps_getpid): Fetch pid from current_inferior directly.
13285
3b8361aa
DE
132862014-02-20 Doug Evans <dje@google.com>
13287
13288 * inferiors.c (get_first_inferior): Fix buglet.
13289
f7667f0d
DE
132902014-02-19 Doug Evans <dje@google.com>
13291
13292 * gdbthread.h (add_thread): Change result type to struct thread_info *.
13293 * inferiors.c (add_thread): Change result type to struct thread_info *.
13294 All callers updated.
13295 (add_lwp): Call add_thread here instead of in callers.
13296 All callers updated.
13297 * linux-low.h (get_lwp_thread): Rewrite.
13298 (struct lwp_info): New member "thread".
13299
b3312d80
DE
133002014-02-19 Doug Evans <dje@google.com>
13301
13302 * linux-low.c (add_lwp): Change result to struct lwp_info *.
13303 All callers updated.
13304
ecc6f45c
DE
133052014-02-19 Doug Evans <dje@google.com>
13306
13307 * inferiors.c (add_thread): Fix whitespace.
13308
649ebbca
DE
133092014-02-19 Doug Evans <dje@google.com>
13310
13311 * dll.c (clear_dlls): Replace accessing list implemention details
13312 with API function.
13313 * gdbthread.h (get_first_thread): Declare.
13314 * inferiors.c (for_each_inferior_with_data): New function.
13315 (get_first_thread): New function.
13316 (find_thread_ptid): Simplify.
13317 (get_first_inferior): New function.
13318 (clear_list): Delete.
13319 (one_inferior_p): New function.
13320 (clear_inferior_list): New function.
13321 (clear_inferiors): Update.
13322 * inferiors.h (for_each_inferior_with_data): Declare.
13323 (clear_inferior_list): Declare.
13324 (one_inferior_p): Declare.
13325 (get_first_inferior): Declare.
13326 * linux-low.c (linux_wait_for_event): Replace accessing list
13327 implemention details with API function.
13328 * server.c (target_running): Ditto.
13329 (accumulate_file_name_length): New function.
13330 (emit_dll_description): New function.
13331 (handle_qxfer_libraries): Replace accessing list implemention
13332 details with API function.
13333 (handle_qxfer_threads_worker): New function.
13334 (handle_qxfer_threads_proper): Replace accessing list implemention
13335 details with API function.
13336 (handle_query): Ditto.
13337 (visit_actioned_threads_callback_ftype): New typedef.
13338 (visit_actioned_threads_data): New struct.
13339 (visit_actioned_threads): Rewrite to be find_inferior callback.
13340 (resume): Call find_inferior.
13341 (handle_status): Replace accessing list implemention
13342 details with API function.
13343 (process_serial_event): Replace accessing list implemention details
13344 with API function.
13345 * target.c (set_desired_inferior): Replace accessing list implemention
13346 details with API function.
13347 * tracepoint.c (same_process_p): New function.
13348 (gdb_agent_about_to_close): Replace accessing list implemention
13349 details with API function.
13350 * win32-low.c (child_delete_thread): Replace accessing list
13351 implemention details with API function.
13352 (match_dll_by_basename): New function.
13353 (dll_is_loaded_by_basename): New function.
13354 (win32_ensure_ntdll_loaded): Replace accessing list implemention
13355 details call to dll_is_loaded_by_basename.
13356
80894984
DE
133572014-02-19 Doug Evans <dje@google.com>
13358
13359 * dll.h (struct dll_info): Add comment.
13360 * gdbthread.h (struct thread_info): Add comment.
13361 (current_ptid): Simplify.
13362 * inferiors.c (add_process): Update.
13363 (remove_process): Update.
13364 * inferiors.h (struct process_info): Rename member "head" to "entry".
13365 * linux-low.c (delete_lwp): Update.
13366 (add_lwp): Update.
13367 (last_thread_of_process_p): Update.
13368 (kill_one_lwp_callback, linux_kill): Update.
13369 (status_pending_p_callback): Update.
13370 (wait_for_sigstop): Update. Simplify read of ptid.
13371 (start_step_over): Update.
13372 * linux-low.h (ptid_of, pid_of, lwpid_of): Update.
13373 (get_lwp_thread): Update.
13374 (struct lwp_info): Rename member "head" to "entry".
13375 * regcache.h (inferior_list_entry): Delete.
13376 * server.c (kill_inferior_callback): Update.
13377 (detach_or_kill_inferior_callback): Update.
13378 (print_started_pid): Update.
13379 (print_attached_pid): Update.
13380 (process_serial_event): Simplify read of ptid.
13381 * thread-db.c (thread_db_create_event): Update.
13382 (thread_db_get_tls_address): Update.
13383 * win32-low.c (current_inferior_ptid): Simplify.
13384
46917d26
TT
133852014-02-19 Tom Tromey <tromey@redhat.com>
13386
13387 * target.h (struct target_ops) <supports_btrace>: Add target_ops
13388 argument.
13389 (target_supports_btrace): Update.
13390
0759a81e
YQ
133912014-02-14 Yao Qi <yao@codesourcery.com>
13392
13393 * Makefile.in (IPA_OBJS): Append rsp-low-ipa.o.
13394 (rsp-low-ipa.o): New target.
13395
a7191e8b
TT
133962014-02-12 Tom Tromey <tromey@redhat.com>
13397
13398 * ax.c (gdb_parse_agent_expr): Use hex2bin, not
13399 convert_ascii_to_int.
13400 * regcache.c (registers_to_string): Likewise.
13401 * remote-utils.c (decode_M_packet): Likewise.
13402 * server.c (process_serial_event): Likewise.
13403
ff0e980e
TT
134042014-02-12 Tom Tromey <tromey@redhat.com>
13405
13406 * server.c (handle_query, handle_v_run): Use hex2bin, not
13407 unhexify.
13408 * tracepoint.c (cmd_qtdpsrc, cmd_qtdv, cmd_qtnotes): Likewise.
13409
e9371aff
TT
134102014-02-12 Tom Tromey <tromey@redhat.com>
13411
13412 * ax.c (gdb_unparse_agent_expr): Use bin2hex, not
13413 convert_int_to_ascii.
13414 * regcache.c (registers_to_string, collect_register_as_string):
13415 Likewise.
13416 * remote-utils.c (look_up_one_symbol, relocate_instruction):
13417 Likewise.
13418 * server.c (process_serial_event): Likewise.
13419 * tracepoint.c (cmd_qtstatus, response_source, response_tsv)
13420 (cmd_qtbuffer, cstr_to_hexstr): Likewise.
13421
971dc0b8
TT
134222014-02-12 Tom Tromey <tromey@redhat.com>
13423
13424 * remote-utils.c (look_up_one_symbol, monitor_output): Use
13425 bin2hex, not hexify.
13426 * tracepoint.c (cmd_qtstatus): Likewise.
13427
0a822afb
TT
134282014-02-12 Tom Tromey <tromey@redhat.com>
13429
13430 * remote-utils.c (monitor_output): Pass explicit length to
13431 hexify.
13432
9c3d6531
TT
134332014-02-12 Tom Tromey <tromey@redhat.com>
13434
13435 * tracepoint.c: Include rsp-low.h.
13436 * server.c: Include rsp-low.h.
13437 * remote-utils.h (convert_ascii_to_int, convert_int_to_ascii)
13438 (unhexify, hexify, remote_escape_output, unpack_varlen_hex): Don't
13439 declare.
13440 * remote-utils.c: Include rsp-low.h.
13441 (fromhex, hexchars, ishex, unhexify, tohex, hexify)
13442 (remote_escape_output, remote_unescape_input, unpack_varlen_hex)
13443 (convert_int_to_ascii, convert_ascii_to_int): Move to
13444 common/rsp-low.c.
13445 * regcache.c: Include rsp-low.h.
13446 * ax.c: Include rsp-low.h.
13447 * Makefile.in (SFILES): Add common/rsp-low.c.
13448 (OBS): Add rsp-low.o.
13449 (rsp-low.o): New target.
13450
01fd3ea5
TT
134512014-02-12 Tom Tromey <tromey@redhat.com>
13452
13453 * utils.h (pulongest, plongest, phex_nz): Don't declare.
13454 Include print-utils.h.
13455 * utils.c (NUMCELLS, CELLSIZE, get_cell, decimal2str, pulongest)
13456 (plongest, thirty_two, phex_nz): Remove.
13457 * Makefile.in (SFILES): Add common/print-utils.c.
13458 (OBS): Add print-utils.o.
13459 (print-utils-ipa.o): New target.
13460 (print-utils.o): New target.
13461 (IPA_OBJS): Add print-utils-ipa.o.
13462
e99dc820
TT
134632014-02-06 Tom Tromey <tromey@redhat.com>
13464
13465 * Makefile.in (SFILES): Fix indentation.
13466
ee1e2d4f
DE
134672014-02-05 Doug Evans <dje@google.com>
13468
13469 * linux-low.c (linux_wait_for_event): Improve comment.
13470 (linux_wait_1): Keep current_inferior in sync with event_child.
13471
f5a02773
DE
134722014-01-22 Doug Evans <dje@google.com>
13473
13474 * gdbthread.h (gdb_id_to_thread): Delete, unused.
13475
87ce2a04
DE
134762014-01-22 Doug Evans <dje@google.com>
13477
13478 * configure.ac (AC_CHECK_FUNCS): Add test for gettimeofday.
13479 * configure: Regenerate.
13480 * config.in: Regenerate.
13481 * Makefile.in (SFILES): Add debug.c.
13482 (OBS): Add debug.o.
13483 * debug.c: New file.
13484 * debug.h: New file.
13485 * linux-aarch64-low.c (*): Update all debugging printfs to use
13486 debug_printf instead of fprintf.
13487 * linux-arm-low.c (*): Ditto.
13488 * linux-cris-low.c (*): Ditto.
13489 * linux-crisv32-low.c (*): Ditto.
13490 * linux-m32r-low.c (*): Ditto.
13491 * linux-sparc-low.c (*): Ditto.
13492 * linux-x86.c (*): Ditto.
13493 * linux-low.c (*): Ditto.
13494 (linux_wait_1): Add calls to debug_enter, debug_exit.
13495 (linux_wait): Remove redundant debugging printf.
13496 (stop_all_lwps): Add calls to debug_enter, debug_exit.
13497 (linux_resume, unstop_all_lwps): Ditto.
13498 * mem-break.c (*): Update all debugging printfs to use
13499 debug_printf instead of fprintf.
13500 * remote-utils.c (*): Ditto.
13501 * thread-db.c (*): Ditto.
13502 * server.c #include <ctype.h>, "gdb_vecs.h".
13503 (debug_threads): Moved to debug.c.
13504 (*): Update all debugging printfs to use debug_printf instead of
13505 fprintf.
13506 (start_inferior): Replace call to fflush with call to debug_flush.
13507 (monitor_show_help): Mention set debug-format.
13508 (parse_debug_format_options): New function.
13509 (handle_monitor_command): Handle "monitor set debug-format".
13510 (gdbserver_usage): Mention --debug-format.
13511 (main): Parse --debug-format.
13512 * server.h (debug_threads): Declaration moved to debug.h.
13513 #include "debug.h".
13514 * tracepoint.c (trace_debug_1) [!IN_PROCESS_AGENT]: Add version of
13515 trace_debug_1 that uses debug_printf.
13516 (tracepoint_look_up_symbols): Update all debugging printfs to use
13517 debug_printf instead of fprintf.
13518
e671835b
BS
135192014-01-20 Baruch Siach <baruch@tkos.co.il>
13520
13521 * linux-xtensa-low.c: Include asm/ptrace.h instead of
13522 sys/ptrace.h.
13523
b5737fa9
PA
135242014-01-17 Pedro Alves <palves@redhat.com>
13525
ea38d2a9 13526 PR build/16445
c7faa97a
PA
13527 * linux-x86-low.c: Don't include elf/common.h if ELFMAG0 is
13528 defined after including gdb_proc_service.h.
b5737fa9 13529
40ed484e
DE
135302014-01-16 Doug Evans <dje@google.com>
13531
13532 * dll.c (UNSPECIFIED_CORE_ADDR): New macro.
13533 (match_dll): Use it.
13534
969c39fb
MM
135352014-01-16 Markus Metzger <markus.t.metzger@intel.com>
13536
13537 * target.h (target_ops) <read_btrace>: Change parameters and
13538 return type to allow error reporting.
13539 * server.c (handle_qxfer_btrace): Support delta reads. Pass
13540 trace reading errors on.
13541 * linux-low.c (linux_low_read_btrace): Pass trace reading
13542 errors on.
13543 (linux_low_disable_btrace): New.
13544
ab7f45ba
DE
135452014-01-15 Doug Evans <dje@google.com>
13546
13547 * inferiors.c (thread_id_to_gdb_id): Delete.
13548 * inferiors.h (thread_id_to_gdb_id): Delete.
13549
66af0f44
EZ
135502014-01-13 Eli Zaretskii <eliz@gnu.org>
13551
13552 * Makefile.in (INCLUDE_CFLAGS): Remove trailing slash from
13553 "-I$(srcdir)/../". Fixes MinGW compilation errors with old GCC
13554 versions.
13555
9939e131
PA
135562014-01-08 Pedro Alves <palves@redhat.com>
13557
13558 * server.c (handle_status): Don't discard previous queued stop
13559 replies or thread's pending status here.
13560 (main) <disconnection>: Do it here instead.
13561
b7ea362b
PA
135622014-01-08 Pedro Alves <palves@redhat.com>
13563
13564 * gdbthread.h (struct thread_info) <status_pending_p>: New field.
13565 * server.c (visit_actioned_threads, handle_pending_status): New
13566 function.
13567 (handle_v_cont): Factor out parts to ...
13568 (resume): ... this new function. If in all-stop, and a thread
13569 being resumed has a pending status, report it without actually
13570 resuming.
13571 (myresume): Adjust to use the new 'resume' function.
13572 (clear_pending_status_callback, set_pending_status_callback)
13573 (find_status_pending_thread_callback): New functions.
13574 (handle_status): Handle the case of multiple threads having
13575 interesting statuses to report. Report threads' real last signal
13576 instead of always reporting GDB_SIGNAL_TRAP. Look for a thread
13577 with an interesting thread to report the status for, instead of
13578 always reporting the status of the first thread.
13579
28498c42
JB
135802014-01-01 Joel Brobecker <brobecker@adacore.com>
13581
13582 * gdbserver.c (gdbserver_version): Set copyright year to 2014.
13583 * gdbreplay.c (gdbreplay_version): Likewise.
13584
f45c82da
YZ
135852013-12-18 Yufeng Zhang <yufeng.zhang@arm.com>
13586
13587 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Set
13588 iov.iov_len with the real length in use.
13589
379a5e2d
JB
135902013-12-13 Joel Brobecker <brobecker@adacore.com>
13591
13592 * Makefile.in (safe-ctype.o, lbasename.o): New rules.
13593 * configure.srv: Add safe-ctype.o and lbasename.o to srv_tgtobj
13594 for all targets that use win32-low.c.
13595 * win32-low.c (win32_ensure_ntdll_loaded): New function.
13596 (do_initial_child_stuff): Add call to win32_ensure_ntdll_loaded.
13597
4210d83e
PA
135982013-12-13 Pedro Alves <palves@redhat.com>
13599
13600 * target.c (mywait): Set OURSTATUS->KIND to TARGET_WAITKIND_STOPPED
13601 if equal to TARGET_WAITKIND_LOADED.
13602 * win32-low.c (cached_status): New static global.
13603 (win32_wait): Add declaration.
13604 (do_initial_child_stuff): Flush all initial pending debug events
13605 up to the initial breakpoint.
13606 (win32_wait): If CACHED_STATUS was set, return that instead
13607 of doing a real wait. Remove the code resuming the execution
13608 of the inferior after receiving a TARGET_WAITKIND_LOADED event
13609 during the initial phase. Also remove the code changing
13610 OURSTATUS->KIND from TARGET_WAITKIND_LOADED to
13611 TARGET_WAITKIND_STOPPED.
13612
e7f0d979
YQ
136132013-12-11 Yao Qi <yao@codesourcery.com>
13614
13615 * notif.c (handle_notif_ack): Return 0 if no notification
13616 matches.
13617
ebcf782c
DE
136182013-11-20 Doug Evans <dje@google.com>
13619
13620 * linux-low.c (linux_set_resume_request): Fix comment.
13621
20ad9378
DE
136222013-11-20 Doug Evans <dje@google.com>
13623
13624 * linux-low.c (resume_status_pending_p): Tweak comment.
13625
a196ebeb
WT
136262013-11-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
13627
13628 * Makefile.in: Add i386-mpx.c, i386-mpx-linux.c, amd64-mpx.c,
13629 amd64-mpx-linux.c, x32-mpx.c and x32-mpx-linux.c generation.
13630 * configure.srv (srv_i386_regobj): Add i386-mpx.o.
13631 (srv_i386_linux_regobj): Add i386-mpx-linux.o.
13632 (srv_amd64_regobj): Add amd64-mpx.o.
13633 (srv_amd64_linux_regobj): Add amd64-mpx-linux.o.
13634 (srv_i386_32bit_xmlfiles): Add i386/32bit-mpx.xml.
13635 (srv_i386_64bit_xmlfiles): Add i386/64bit-mpx.xml.
13636 * i387-fp.c (num_pl_bnd_register) Added constant.
13637 (num_pl_bnd_cfg_registers) Added constant.
13638 (struct i387_xsave) Added reserved area and MPX fields.
13639 (i387_cache_to_xsave, i387_xsave_to_cache) Add MPX.
13640 * linux-x86-low.c (init_registers_i386_mpx_linux): Declare new
13641 function.
13642 (tdesc_i386_mpx_linux): Add MPX amd64 target.
13643 (init_registers_amd64_mpx_linux): Declare new function.
13644 (tdesc_amd64_mpx_linux): Add MPX amd64 target.
13645 (x86_64_regmap): Add MPX registers.
13646 (x86_linux_read_description): Add MPX case.
13647 (initialize_low_arch): Initialize MPX targets.
13648
0080a2f6
TT
136492013-11-18 Tom Tromey <tromey@redhat.com>
13650
13651 * configure: Rebuild.
13652 * configure.ac: Don't check for stdlib.h.
13653 * gdbreplay.c: Unconditionally include stdlib.h.
13654
2978b111
TT
136552013-11-18 Tom Tromey <tromey@redhat.com>
13656
13657 * config.in: Rebuild.
13658 * configure: Rebuild.
13659 * configure.ac: Don't use AC_HEADER_DIRENT.
13660
a3d08894
TT
136612013-11-18 Tom Tromey <tromey@redhat.com>
13662
13663 * server.h: Don't check HAVE_STRING_H.
13664 * gdbreplay.c: Don't check HAVE_STRING_H.
13665 * configure: Rebuild.
13666
0a5dd17d
TT
136672013-11-18 Tom Tromey <tromey@redhat.com>
13668
13669 * Makefile.in (gdbreplay$(EXEEXT)): Depend on and link against
13670 LIBGNU.
13671
1bd2f0ba
TT
136722013-11-08 Tom Tromey <tromey@redhat.com>
13673
13674 * configure, config.in: Rebuild.
13675 * configure.ac: Remove unused configury.
13676
3266f10b
TT
136772013-11-08 Tom Tromey <tromey@redhat.com>
13678
13679 * acinclude.m4: Include common.m4, codeset.m4.
13680 * configure, config.in: Rebuild.
13681 * configure.ac: Use GDB_AC_COMMON.
13682
6682d959
AA
136832013-11-06 Andreas Arnez <arnez@linux.vnet.ibm.com>
13684
13685 * linux-s390-low.c (HWCAP_S390_TE): New define.
13686 (s390_arch_setup): Consider the TE field in the HWCAP for
13687 determining 'have_regset_tdb'.
13688
fd0a4d76
SDJ
136892013-10-16 Sergio Durigan Junior <sergiodj@redhat.com>
13690
13691 PR gdb/16014
13692 * tracepoint.c (download_tracepoint_1): Remove unnecessary double
13693 call to sizeof.
13694
1a3d890b
PA
136952013-10-02 Pedro Alves <palves@redhat.com>
13696
13697 * server.c (process_serial_event): Don't output "GDBserver
13698 exiting" if GDB is connected through stdio.
13699 * target.c (mywait): Likewise, be silent if GDB is connected
13700 through stdio.
13701
97ad4581
JB
137022013-10-01 Joel Brobecker <brobecker@adacore.com>
13703
13704 * lynx-low.c (lynx_add_threads_after_attach): New function.
13705 (lynx_attach): Remove call to add_thread. Add call to
13706 lynx_add_threads_after_attach instead.
13707
5b4e221c
MF
137082013-09-28 Mike Frysinger <vapier@gentoo.org>
13709
13710 * configure.ac (AC_CHECK_HEADERS): Add sys/syscall.h
13711 * config.in, configure: Regenerated.
13712
ee47b2f8
YQ
137132013-09-18 Yao Qi <yao@codesourcery.com>
13714
13715 PR server/15959
13716 * server.c (start_inferior): Clear 'resume_info'.
13717
d6707650 137182013-09-16 Jiong Wang <jiwang@tilera.com>
0f63d4db 13719
d6707650
JW
13720 * linux-tile-low.c (tile_regsets): Modify the size field to 64-bit
13721 for each register.
13722
9243dd0e 137232013-09-16 Jiong Wang <jiwang@tilera.com>
0f63d4db 13724
9243dd0e
JW
13725 * configure.srv <tilegx*-*-linux*>: Remove linux-osdata.o from and add
13726 linux-tile-low.o to srv_tgtobj.
13727
c623a6ef
WN
137282013-09-16 Will Newton <will.newton@linaro.org>
13729
13730 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Zero
13731 out regs.
13732
fb71d39e
PA
137332013-09-06 Pedro Alves <palves@redhat.com>
13734
13735 * Makefile.in (gdb_proc_service_h, regdef_h, regcache_h)
13736 (signals_def, signals_h, ptid_h, ax_h, agent_h, linux_btrace_h)
13737 (linux_osdata_h, vec_h, gdb_vecs_h, host_defs_h, libiberty_h)
13738 (server_h, gdbthread_h, linux_low_h, linux_ptrace_h)
13739 (gdb_thread_db_h, linux_procfs_h, lynx_low_h, nto_low_h)
13740 (mips_linux_watch_h, i386_low_h, win32_low_h): Delete.
13741
8e7e9910
PA
137422013-09-06 Pedro Alves <palves@redhat.com>
13743
13744 * Makefile.in (linux-btrace.o, mips-linux-watch.o): Remove
13745 explicit header dependencies and use $COMPILE/$POSTCOMPILE.
13746
7c3a12ca
PA
137472013-09-06 Pedro Alves <palves@redhat.com>
13748
13749 * linux-amd64-ipa.c: Include tracepoint.h.
13750 * linux-i386-ipa.c: Include tracepoint.h.
13751
8eb3d7b6
RW
137522013-09-06 Ricard Wanderlof <ricardw@axis.com>
13753
13754 * linux-crisv32-low.c (PTRACE_GET_THREAD_AREA): New macro.
13755 (ps_get_thread_area): New function.
13756
eddddb9d
RW
137572013-09-06 Ricard Wanderlof <ricardw@axis.com>
13758
13759 * linux-crisv32-low.c (elf_gregset_t): Delete typedef.
13760 (initialize_low_arch): Call init_registers_crisv32 rather than
13761 init_register_crisv32.
13762
533b0600
PA
137632013-09-05 Pedro Alves <palves@redhat.com>
13764
13765 * server.h (handle_vFile, hostio_last_error_from_errno): Move
13766 to ...
13767 * hostio.h: ... this new file.
13768 * hostio.c, server.c, linux-low.c, nto-low.c, spu-low,
13769 win32-low.c: Include hostio.h.
13770
0ce3d3b5
PA
137712013-09-05 Pedro Alves <palves@redhat.com>
13772
13773 * server.h (gdb_client_data, handler_func, callback_handler_func)
13774 (delete_file_handler, add_file_handler, append_callback_event)
13775 (delete_callback_event, start_event_loop, initialize_event_loop):
13776 Move to event-loop.h and include it.
13777 * event-loop.h: New file.
13778
799cdc37
PA
137792013-09-05 Pedro Alves <palves@redhat.com>
13780
13781 * dll.c, inferiors.c, remote-utils.c, server.c: Include "dll.h".
13782 * server.h (struct dll_info, all_dlls, dlls_changed, clear_dlls)
13783 (loaded_dll, unloaded_dll): Move to ...
13784 * dll.h: ... this new file.
13785 * inferiors.c, remote-utils.c, win32-low.c: Include "dll.h".
13786
6a6bbd9d
PA
137872013-09-05 Pedro Alves <palves@redhat.com>
13788
13789 * server.h (current_process, get_thread_process, all_processes)
13790 (add_inferior_to_list, for_each_inferior, current_inferior)
13791 (remove_inferior, add_process, remove_process, find_process_pid)
13792 (have_started_inferiors_p, have_attached_inferiors_p)
13793 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id)
13794 (clear_inferiors, find_inferior, find_inferior_id)
13795 (inferior_target_data, set_inferior_target_data)
13796 (inferior_regcache_data, set_inferior_regcache_data): Move to
13797 inferiors.h, and include it.
13798 * inferiors.h: New file.
13799
f699aaba
PA
138002013-09-05 Pedro Alves <palves@redhat.com>
13801
13802 * server.h (struct emit_ops, current_insn_ptr, emit_error):
13803 Move ...
72f4393d 13804 * ax.h: ... here.
f699aaba 13805
c144c7a0
PA
138062013-09-05 Pedro Alves <palves@redhat.com>
13807
13808 * ax.c, linux-low.c, linux-x86-low.c, server.c: Include
13809 tracepoint.h.
13810 * server.h (IPA_BUFSIZ, initialize_tracepoint, tracing)
13811 (disconnected_tracing, tracepoint_look_up_symbols, stop_tracing
13812 (handle_tracepoint_general_set, handle_tracepoint_query)
13813 (tracepoint_finished_step, tracepoint_was_hit)
13814 (release_while_stepping_state_list, current_traceframe)
13815 (in_readonly_region, traceframe_read_mem)
13816 (fetch_traceframe_registers, traceframe_read_sdata)
13817 (traceframe_read_info, struct fast_tpoint_collect_status)
13818 (fast_tracepoint_collecting, force_unlock_trace_buffer)
13819 (handle_tracepoit_bkpts, initialize_low_tracepoint)
13820 (supply_fast_tracepoint_registers)
13821 (supply_static_tracepoint_registers, set_trampoline_buffer_space)
13822 (ipa_tdesc, claim_trampoline_space)
13823 (have_fast_tracepoint_trampoline_buffer, gdb_agent_about_to_close)
13824 (agent_mem_read, agent_get_trace_state_variable_value)
13825 (agent_set_trace_state_variable_value, agent_tsv_read)
13826 (agent_mem_read_string, get_raw_reg_func_addr)
13827 (get_get_tsv_func_addr, get_set_tsv_func_addr): Move to ...
13828 * tracepoint.h: ... this new file.
13829
ff42e6ab
PA
138302013-09-05 Pedro Alves <palves@redhat.com>
13831
13832 * server.h (perror_with_name, error, fatal, warning, paddress)
13833 (pulongest, plongest, phex_nz, pfildes): Move to utils.h, and
13834 include it.
13835 * utils.h: New file.
13836
541af0f4
PA
138372013-09-05 Pedro Alves <palves@redhat.com>
13838
13839 * server.h (remote_debug, noack_mode, transport_is_reliable)
13840 (gdb_connected, STDIO_CONNECTION_NAME, remote_connection_is_stdio)
13841 (read_ptid, write_ptid, putpkt, putpkt_binary, putpkt_notif)
13842 (getpkt, remote_prepare, remote_open, remote_close, write_ok)
13843 (write_enn, initialize_async_io, enable_async_io)
13844 (disable_async_io, check_remote_input_interrupt_request)
13845 (convert_ascii_to_int, convert_int_to_ascii, new_thread_notify)
13846 (dead_thread_notify, prepare_resume_reply)
13847 (decode_address_to_semicolon, decode_address, decode_m_packet)
13848 (decode_M_packet, decode_X_packet, decode_xfer_write)
13849 (decode_search_memory_packet, unhexify, hexify)
13850 (remote_escape_output, unpack_varlen_hex, clear_symbol_cache)
13851 (look_up_one_symbol, relocate_instruction)
13852 (monitor_output): Move to remote-utils.h, and include it.
13853 * remote-utils.h: New file.
13854
eebdf26b
PA
138552013-09-05 Pedro Alves <palves@redhat.com>
13856
13857 * server.h (_): Delete.
13858
3aafd2ff
PA
138592013-09-02 Pedro Alves <palves@redhat.com>
13860
13861 * tracepoint.c (TRACEFRAME_EOB_MARKER_SIZE): New macro.
13862 (init_trace_buffer): Ensure at least TRACEFRAME_EOB_MARKER_SIZE is
13863 allocated.
13864 (trace_buffer_alloc): Use TRACEFRAME_EOB_MARKER_SIZE.
13865
cee83bcb
PM
138662013-09-02 Pierre Muller <muller@sourceware.org>
13867
13868 * win32-low.c (child_xfer_memory): Check if ReadProcessMemory
13869 or WriteProcessMemory complete successfully and handle
13870 ERROR_PARTIAL_COPY error.
13871
9a13b2fa
PA
138722013-09-02 Pedro Alves <palves@redhat.com>
13873
13874 * server.c (gdb_read_memory): Return -1 on traceframe memory read
13875 error instead of EIO.
13876
602e3198
JK
138772013-08-28 Jan Kratochvil <jan.kratochvil@redhat.com>
13878
13879 PR server/15604
13880 * linux-low.c: Include filestuff.h.
13881 (linux_create_inferior) <pid == 0>: Call close_most_fds.
13882 * lynx-low.c: Include filestuff.h.
13883 (lynx_create_inferior) <pid == 0>: Call close_most_fds.
13884 * server.c: Include filestuff.h.
13885 (main): Call notice_open_fds.
13886 * spu-low.c: Include filestuff.h.
13887 (spu_create_inferior) <pid == 0>: Call close_most_fds.
13888
96d7229d
LM
138892013-08-22 Luis Machado <lgustavo@codesourcery.com>
13890
13891 * Makefile.in: Explain why ../target and ../nat are not
13892 listed as include file search paths.
13893 (linux-waitpid.o): New object file rule.
13894 * configure.srv (srv_native_linux_obj): New variable.
13895 Replace all occurrences of linux native object files with
13896 $srv_native_linux_obj.
13897 * linux-low.c: Include nat/linux-nat.h and nat/linux-waitpid.h.
13898 (HAS_NOMMU): Move defining logic to common/linux-ptrace.c.
13899 (linux_enable_event_reporting): Remove declaration.
13900 (my_waitpid): Moved to common/linux-waitpid.c.
13901 (linux_wait_for_event): Pass ptid when calling
13902 linux_enable_event_reporting.
13903 (linux_supports_tracefork_flag): Remove.
13904 (linux_enable_event_reporting): Likewise.
13905 (linux_tracefork_grandchild): Remove.
13906 (STACK_SIZE): Moved to common/linux-ptrace.c.
13907 (linux_tracefork_child): Remove.
13908 (linux_test_for_tracefork): Remove.
13909 (linux_look_up_symbols): Call linux_supports_traceclone.
13910 (initialize_low): Remove call to linux_test_for_tracefork.
13911 * linux-low.h (PTRACE_TYPE_ARG3): Move to
13912 common/linux-ptrace.h.
13913 (PTRACE_TYPE_ARG4): Likewise.
13914 Include linux-ptrace.h.
13915
32940073
PA
139162013-08-21 Pedro Alves <palves@redhat.com>
13917
13918 * config.in: Renegerate.
13919
33b60d58 139202013-08-19 Luis Machado <lgustavo@codesourcery.com>
a261b8f5 13921
33b60d58
LM
13922 * Makefile.in (INCLUDE_CFLAGS): Include -I$(srcdir)/../.
13923 (SFILES): Remove $(srcdir)/common/target-common.c and
13924 add $(srcdir)/target/waitstatus.c.
13925 (OBS): Remove target-common.o and add waitstatus.o.
13926 (server_h): Remove $(srcdir)/../common/target-common.h and
13927 add $(srcdir)/../target/resume.h, $(srcdir)/../target/wait.h
13928 and $(srcdir)/../target/waitstatus.h.
13929 (target-common.o): Remove.
13930 (waitstatus.o): New target object file.
13931 * target.h: Do not include target-common.h and
13932 include target/resume.h, target/wait.h and
13933 target/waitstatus.h.
13934
b8e1b30e
LM
139352013-08-13 Luis Machado <lgustavo@codesourcery.com>
13936
13937 * linux-arm-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
13938 to PTRACE_TYPE_ARG3.
13939 * linux-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
13940 to PTRACE_TYPE_ARG3 and PTRACE_ARG4_TYPE to
13941 PTRACE_TYPE_ARG4.
13942 * linux-low.h (PTRACE_ARG3_TYPE): Rename to PTRACE_TYPE_ARG3.
13943 (PTRACE_ARG4_TYPE): Rename to PTRACE_TYPE_ARG4.
13944
7a60ad40
YQ
139452013-07-27 Jie Zhang <jie@codesourcery.com>
13946 Daniel Jacobowitz <dan@codesourcery.com>
13947 Yao Qi <yao@codesourcery.com>
13948
13949 * Makefile.in (SFILES): Add common/mips-linux-watch.c.
13950 (mips-linux-watch.o): New rule.
13951 (mips_linux_watch_h): New variable.
13952 * configure.srv <mips*-*-linux*>: Add mips-linux-watch.o to
13953 srv_tgtobj.
13954 * linux-mips-low.c: Include mips-linux-watch.h.
13955 (struct arch_process_info, struct arch_lwp_info): New.
13956 (update_watch_registers_callback): New function.
13957 (mips_linux_new_process, mips_linux_new_thread) New functions.
13958 (mips_linux_prepare_to_resume, mips_insert_point): New
13959 functions.
13960 (mips_remove_point, mips_stopped_by_watchpoint): New
13961 functions.
13962 (rsp_bp_type_to_target_hw_bp_type): New function.
13963 (mips_stopped_data_address): New function.
13964 (the_low_target): Add watchpoint support functions.
13965
de6f69ad
YQ
139662013-07-27 Yao Qi <yao@codesourcery.com>
13967
13968 * i386-low.c: Include break-common.h.
13969 (enum target_hw_bp_type): Remove.
13970
3360c0bf
LM
139712013-07-24 Luis Machado <lgustavo@codesourcery.com>
13972
13973 * Makefile.in (SFILES): /common/target-common.c.
13974 (OBS): Add target-common.o.
13975 (server_h): Add $(srcdir)/../common/target-common.h.
13976 (target-common.o): New target.
13977 * server.c (queue_stop_reply_callback): Free
13978 status string after use.
13979 * target.c (target_waitstatus_to_string): Remove.
13980 * target.h: Include target-common.h.
13981 (resume_kind): Likewise.
13982 (target_waitkind): Likewise.
13983 (target_waitstatus): Likewise.
13984 (TARGET_WNOHANG): Likewise.
13985
bd885420
YQ
139862013-07-04 Yao Qi <yao@codesourcery.com>
13987
13988 * Makefile.in (host_alias): Use @host_noncanonical@.
13989 (target_alias): Use @target_noncanonical@.
13990 * configure.ac: Use ACX_NONCANONICAL_TARGET and
13991 ACX_NONCANONICAL_HOST.
13992 * configure: Regenerated.
13993
13994 Revert:
13995 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
13996
13997 * configure.ac (version_host, version_target): Set and AC_SUBST them.
13998 * configure: Rebuild.
13999 * Makefile.in (version_host, version_target): Get from configure.
14000 (version.c): Use $(version_host) and $(version_target).
14001
17ef446e
PA
140022013-07-03 Pedro Alves <palves@redhat.com>
14003
14004 * Makefile.in (config.status): Depend on development.sh.
14005 * acinclude.m4: Include libmcheck.m4.
14006 * configure: Regenerate.
14007
7a9a7487
MG
140082013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
14009
14010 * win32-low.c (winapi_DebugActiveProcessStop): Move the WINAPI
14011 attribute inside the parentheses.
14012 (winapi_DebugSetProcessKillOnExit): Ditto.
14013 (winapi_DebugBreakProcess): Ditto.
14014 (winapi_GenerateConsoleCtrlEvent): Ditto.
a261b8f5 14015
49b64de6
MG
140162013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
14017
14018 * notif.h (notif_event): Add a dummy member to avoid compiler
14019 errors.
14020
d5749ee7
PA
140212013-07-01 Pedro Alves <palves@redhat.com>
14022
14023 * hostio.c (HOSTIO_PATH_MAX): Define.
14024 (require_filename, handle_open, handle_unlink, handle_readlink):
14025 Use it.
14026
d8d2a3ee
PA
140272013-07-01 Pedro Alves <palves@redhat.com>
14028
14029 * server.h: Include "pathmax.h".
14030 * linux-low.c: Don't include sys/param.h.
14031 (linux_pid_exe_is_elf_64_file): Use PATH_MAX instead of
14032 MAXPATHLEN.
14033 * win32-low.c: Don't include sys/param.h.
14034 (win32_create_inferior): Use PATH_MAX instead of MAXPATHLEN.
14035
bc7dea8d
PA
140362013-07-01 Pedro Alves <palves@redhat.com>
14037
14038 * event-loop.c: Don't check HAVE_UNISTD_H before including
14039 <unistd.h>.
14040 * gdbreplay.c: Likewise.
14041 * remote-utils.c: Likewise.
14042 * server.c: Likewise.
14043 * configure.ac: Don't check for unistd.h.
14044 * configure: Regenerate.
14045
d6c2da54
TT
140462013-06-28 Tom Tromey <tromey@redhat.com>
14047
14048 * Makefile.in (version.c): Use version.in, not
14049 common/version.in.
14050
257b6bec
MG
140512013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
14052
14053 * configure.ac (version_host, version_target): Set and AC_SUBST them.
14054 * configure: Rebuild.
14055 * Makefile.in (version_host, version_target): Get from configure.
14056 (version.c): Use $(version_host) and $(version_target).
14057
86ebe149
DK
140582013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
14059
14060 Fix trace-status to output user name without trailing colon.
14061 * tracepoint.c (cmd_qtstatus): Remove unnecessary colon from user name.
14062
f30aa5af
DK
140632013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
14064
14065 Fix trace-status to output proper start-time and stop-time.
14066 * tracepoint.c (cmd_qtstatus): Modify trace-status output to
14067 output start time and stop time in hex as gdb expects.
14068
28a93511
YQ
140692013-06-26 Pedro Alves <pedro@codesourcery.com>
14070
14071 * tracepoint.c (build_traceframe_info_xml): Output trace state
14072 variables present in the trace buffer.
14073
01208463
TT
140742013-06-24 Tom Tromey <tromey@redhat.com>
14075
14076 * Makefile.in (version.c): Use bfd/version.h, common/version.in,
14077 create-version.sh.
14078 (version.o): Remove.
14079 * gdbreplay.c: Include version.h.
14080 (version, host_name): Don't declare.
14081 * server.h: Include version.h.
14082 (version, host_name): Don't declare.
14083
760256f9
PA
140842013-06-12 Pedro Alves <palves@redhat.com>
14085
14086 * linux-x86-low.c (linux_is_elf64): Delete global.
14087 (x86_siginfo_fixup): Replace reference to `linux_is_elf64' global
14088 with local linux_pid_exe_is_elf_64_file use.
14089
030031ee
PA
140902013-06-11 Pedro Alves <palves@redhat.com>
14091
14092 * linux-low.c (regset_disabled, disable_regset): New functions.
14093 (regsets_fetch_inferior_registers)
14094 (regsets_store_inferior_registers): Use them.
14095 (initialize_regsets_info); Don't allocate the disabled_regsets
14096 array here.
14097 * linux-low.h (struct regsets_info) <disabled_regsets>: Extend
14098 comment.
14099
5da6eb0a
PA
141002013-06-11 Pedro Alves <palves@redhat.com>
14101
14102 * linux-low.c (initialize_regsets_info): Use xcalloc instead of
14103 xmalloc.
14104
7e5aaa09
PA
141052013-06-11 Pedro Alves <palves@redhat.com>
14106
14107 * linux-x86-low.c (initialize_low_arch): Call
14108 init_registers_x32_avx_linux.
14109
d878444c
JK
141102013-06-09 Jan Kratochvil <jan.kratochvil@redhat.com>
14111
14112 Fix compatibility with Android Bionic.
14113 * linux-low.c (linux_qxfer_libraries_svr4): Ignore first entry even if
14114 it is not empty.
14115
3aee8918
PA
141162013-06-07 Pedro Alves <palves@redhat.com>
14117
5f2b57b5 14118 PR server/14823
3aee8918
PA
14119 * Makefile.in (OBS): Add tdesc.o.
14120 (IPA_OBJS): Add tdesc-ipa.o.
14121 (tdesc-ipa.o): New rule.
14122 * ax.c (gdb_eval_agent_expr): Adjust register_size call to new
14123 interface.
14124 * linux-low.c (new_inferior): Delete.
14125 (disabled_regsets, num_regsets): Delete.
14126 (linux_add_process): Adjust to set the new per-process
14127 new_inferior flag.
14128 (linux_detach_one_lwp): Adjust to call regcache_invalidate_thread.
14129 (linux_wait_for_lwp): Adjust. Only call arch_setup if the event
14130 was a stop. When calling arch_setup, switch the current inferior
14131 to the thread that got an event.
14132 (linux_resume_one_lwp): Adjust to call regcache_invalidate_thread.
14133 (regsets_fetch_inferior_registers)
14134 (regsets_store_inferior_registers): New regsets_info parameter.
14135 Adjust to use it.
14136 (linux_register_in_regsets): New regs_info parameter. Adjust to
14137 use it.
14138 (register_addr, fetch_register, store_register): New usrregs_info
14139 parameter. Adjust to use it.
14140 (usr_fetch_inferior_registers, usr_store_inferior_registers): New
14141 parameter regs_info. Adjust to use it.
14142 (linux_fetch_registers): Get the current inferior's regs_info, and
14143 adjust to use it.
14144 (linux_store_registers): Ditto.
14145 [HAVE_LINUX_REGSETS] (initialize_regsets_info): New.
14146 (initialize_low): Don't initialize the target_regsets here. Call
14147 initialize_low_arch.
14148 * linux-low.h (target_regsets): Delete declaration.
14149 (struct regsets_info): New.
14150 (struct usrregs_info): New.
14151 (struct regs_info): New.
14152 (struct process_info_private) <new_inferior>: New field.
14153 (struct linux_target_ops): Delete the num_regs, regmap, and
14154 regset_bitmap fields. New field regs_info.
14155 [HAVE_LINUX_REGSETS] (initialize_regsets_info): Declare.
14156 * i387-fp.c (num_xmm_registers): Delete.
14157 (i387_cache_to_fsave, i387_fsave_to_cache): Adjust find_regno
14158 calls to new interface.
14159 (i387_cache_to_fxsave, i387_cache_to_xsave, i387_fxsave_to_cache)
14160 (i387_xsave_to_cache): Adjust find_regno calls to new interface.
14161 Infer the number of xmm registers from the regcache's target
14162 description.
14163 * i387-fp.h (num_xmm_registers): Delete.
14164 * inferiors.c (add_thread): Don't install the thread's regcache
14165 here.
14166 * proc-service.c (gregset_info): Fetch the current inferior's
14167 regs_info. Adjust to use it.
14168 * regcache.c: Include tdesc.h.
14169 (register_bytes, reg_defs, num_registers)
14170 (gdbserver_expedite_regs): Delete.
14171 (get_thread_regcache): If the thread doesn't have a regcache yet,
14172 create one, instead of aborting gdbserver.
14173 (regcache_invalidate_one): Rename to ...
14174 (regcache_invalidate_thread): ... this.
14175 (regcache_invalidate_one): New.
14176 (regcache_invalidate): Only invalidate registers of the current
14177 process.
14178 (init_register_cache): Add target_desc parameter, and use it.
14179 (new_register_cache): Ditto. Assert the target description has a
14180 non zero registers_size.
14181 (regcache_cpy): Add assertions. Adjust.
14182 (realloc_register_cache, set_register_cache): Delete.
14183 (registers_to_string, registers_from_string): Adjust.
14184 (find_register_by_name, find_regno, find_register_by_number)
14185 (register_cache_size): Add target_desc parameter, and use it.
14186 (free_register_cache_thread, free_register_cache_thread_one)
14187 (regcache_release, register_cache_size): New.
14188 (register_size): Add target_desc parameter, and use it.
14189 (register_data, supply_register, supply_register_zeroed)
14190 (supply_regblock, supply_register_by_name, collect_register)
14191 (collect_register_as_string, collect_register_by_name): Adjust.
14192 * regcache.h (struct target_desc): Forward declare.
14193 (struct regcache) <tdesc>: New field.
14194 (init_register_cache, new_register_cache): Add target_desc
14195 parameter.
14196 (regcache_invalidate_thread): Declare.
14197 (regcache_invalidate_one): Delete declaration.
14198 (regcache_release): Declare.
14199 (find_register_by_number, register_cache_size, register_size)
14200 (find_regno): Add target_desc parameter.
14201 (gdbserver_expedite_regs, gdbserver_xmltarget): Delete
14202 declarations.
14203 * remote-utils.c: Include tdesc.h.
14204 (outreg, prepare_resume_reply): Adjust.
14205 * server.c: Include tdesc.h.
14206 (gdbserver_xmltarget): Delete declaration.
14207 (get_features_xml, process_serial_event): Adjust.
14208 * server.h [IN_PROCESS_AGENT] (struct target_desc): Forward
14209 declare.
14210 (struct process_info) <tdesc>: New field.
14211 (ipa_tdesc): Declare.
14212 * tdesc.c: New file.
14213 * tdesc.h: New file.
14214 * tracepoint.c: Include tdesc.h.
14215 [IN_PROCESS_AGENT] (ipa_tdesc): Define.
14216 (get_context_regcache): Adjust to pass ipa_tdesc down.
14217 (do_action_at_tracepoint): Adjust to get the register cache size
14218 from the context regcache's description.
14219 (traceframe_walk_blocks): Adjust to get the register cache size
14220 from the current trace frame's description.
14221 (traceframe_get_pc): Adjust to get current trace frame's
14222 description and pass it down.
14223 (gdb_collect): Adjust to get the register cache size from the
14224 IPA's description.
14225 * linux-amd64-ipa.c (tdesc_amd64_linux): Declare.
14226 (gdbserver_xmltarget): Delete.
14227 (initialize_low_tracepoint): Set the ipa's target description.
14228 * linux-i386-ipa.c (tdesc_i386_linux): Declare.
14229 (initialize_low_tracepoint): Set the ipa's target description.
14230 * linux-x86-low.c: Include tdesc.h.
14231 [__x86_64__] (is_64bit_tdesc): New.
14232 (ps_get_thread_area, x86_get_thread_area): Use it.
14233 (i386_cannot_store_register): Rename to ...
14234 (x86_cannot_store_register): ... this. Use is_64bit_tdesc.
14235 (i386_cannot_fetch_register): Rename to ...
14236 (x86_cannot_fetch_register): ... this. Use is_64bit_tdesc.
14237 (x86_fill_gregset, x86_store_gregset): Adjust register_size calls
14238 to new interface.
14239 (target_regsets): Rename to ...
14240 (x86_regsets): ... this.
14241 (x86_get_pc, x86_set_pc): Adjust register_size calls to new
14242 interface.
14243 (x86_siginfo_fixup): Use is_64bit_tdesc.
14244 [__x86_64__] (tdesc_amd64_linux, tdesc_amd64_avx_linux)
14245 (tdesc_x32_avx_linux, tdesc_x32_linux)
14246 (tdesc_i386_linux, tdesc_i386_mmx_linux, tdesc_i386_avx_linux):
14247 Declare.
14248 (x86_linux_update_xmltarget): Delete.
14249 (I386_LINUX_XSAVE_XCR0_OFFSET): Define.
14250 (have_ptrace_getfpxregs, have_ptrace_getregset): New.
14251 (AMD64_LINUX_USER64_CS): New.
14252 (x86_linux_read_description): New, based on
14253 x86_linux_update_xmltarget.
14254 (same_process_callback): New.
14255 (x86_arch_setup_process_callback): New.
14256 (x86_linux_update_xmltarget): New.
14257 (x86_regsets_info): New.
14258 (amd64_linux_regs_info): New.
14259 (i386_linux_usrregs_info): New.
14260 (i386_linux_regs_info): New.
14261 (x86_linux_regs_info): New.
14262 (x86_arch_setup): Reimplement.
14263 (x86_install_fast_tracepoint_jump_pad): Use is_64bit_tdesc.
14264 (x86_emit_ops): Ditto.
14265 (the_low_target): Adjust. Install x86_linux_regs_info,
14266 x86_cannot_fetch_register, and x86_cannot_store_register.
14267 (initialize_low_arch): New.
14268 * linux-ia64-low.c (tdesc_ia64): Declare.
14269 (ia64_fetch_register): Adjust.
14270 (ia64_usrregs_info, regs_info): New globals.
14271 (ia64_regs_info): New function.
14272 (the_low_target): Adjust.
14273 (initialize_low_arch): New function.
14274 * linux-sparc-low.c (tdesc_sparc64): Declare.
14275 (sparc_fill_gregset_to_stack, sparc_store_gregset_from_stack):
14276 Adjust.
14277 (sparc_arch_setup): New function.
14278 (sparc_regsets_info, sparc_usrregs_info, regs_info): New globals.
14279 (the_low_target): Adjust.
14280 (initialize_low_arch): New function.
14281 * linux-ppc-low.c (tdesc_powerpc_32l, tdesc_powerpc_altivec32l)
14282 (tdesc_powerpc_cell32l, tdesc_powerpc_vsx32l)
14283 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_altivec32l)
14284 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_e500l)
14285 (tdesc_powerpc_64l, tdesc_powerpc_altivec64l)
14286 (tdesc_powerpc_cell64l, tdesc_powerpc_vsx64l)
14287 (tdesc_powerpc_isa205_64l, tdesc_powerpc_isa205_altivec64l)
14288 (tdesc_powerpc_isa205_vsx64l): Declare.
14289 (ppc_cannot_store_register, ppc_collect_ptrace_register)
14290 (ppc_supply_ptrace_register, parse_spufs_run, ppc_get_pc)
14291 (ppc_set_pc, ppc_get_hwcap): Adjust.
14292 (ppc_usrregs_info): Forward declare.
14293 (!__powerpc64__) ppc_regmap_adjusted: New global.
14294 (ppc_arch_setup): Adjust to the current process'es target
14295 description.
14296 (ppc_fill_vsxregset, ppc_store_vsxregset, ppc_fill_vrregset)
14297 (ppc_store_vrregset, ppc_fill_evrregset, ppc_store_evrregse)
14298 (ppc_store_evrregset): Adjust.
14299 (target_regsets): Rename to ...
14300 (ppc_regsets): ... this, and make static.
14301 (ppc_usrregs_info, ppc_regsets_info, regs_info): New globals.
14302 (ppc_regs_info): New function.
14303 (the_low_target): Adjust.
14304 (initialize_low_arch): New function.
14305 * linux-s390-low.c (tdesc_s390_linux32, tdesc_s390_linux32v1)
14306 (tdesc_s390_linux32v2, tdesc_s390_linux64, tdesc_s390_linux64v1)
14307 (tdesc_s390_linux64v2, tdesc_s390x_linux64, tdesc_s390x_linux64v1)
14308 (tdesc_s390x_linux64v2): Declare.
14309 (s390_collect_ptrace_register, s390_supply_ptrace_register)
14310 (s390_fill_gregset, s390_store_last_break): Adjust.
14311 (target_regsets): Rename to ...
14312 (s390_regsets): ... this, and make static.
14313 (s390_get_pc, s390_set_pc): Adjust.
14314 (s390_get_hwcap): New target_desc parameter, and use it.
14315 [__s390x__] (have_hwcap_s390_high_gprs): New global.
14316 (s390_arch_setup): Adjust to set the current process'es target
14317 description. Don't adjust the regmap.
14318 (s390_usrregs_info, s390_regsets_info, regs_info): New globals.
14319 [__s390x__] (s390_usrregs_info_3264, s390_regsets_info_3264)
14320 (regs_info_3264): New globals.
14321 (s390_regs_info): New function.
14322 (the_low_target): Adjust.
14323 (initialize_low_arch): New function.
14324 * linux-mips-low.c (tdesc_mips_linux, tdesc_mips_dsp_linux)
14325 (tdesc_mips64_linux, tdesc_mips64_dsp_linux): Declare.
14326 [__mips64] (init_registers_mips_linux)
14327 (init_registers_mips_dsp_linux): Delete defines.
14328 [__mips64] (tdesc_mips_linux, tdesc_mips_dsp_linux): New defines.
14329 (have_dsp): New global.
14330 (mips_read_description): New, based on mips_arch_setup.
14331 (mips_arch_setup): Reimplement.
14332 (get_usrregs_info): New function.
14333 (mips_cannot_fetch_register, mips_cannot_store_register)
14334 (mips_get_pc, mips_set_pc, mips_fill_gregset, mips_store_gregset)
14335 (mips_fill_fpregset, mips_store_fpregset): Adjust.
14336 (target_regsets): Rename to ...
14337 (mips_regsets): ... this, and make static.
14338 (mips_regsets_info, mips_dsp_usrregs_info, mips_usrregs_info)
14339 (dsp_regs_info, regs_info): New globals.
14340 (mips_regs_info): New function.
14341 (the_low_target): Adjust.
14342 (initialize_low_arch): New function.
14343 * linux-arm-low.c (tdesc_arm, tdesc_arm_with_iwmmxt)
14344 (tdesc_arm_with_vfpv2, tdesc_arm_with_vfpv3, tdesc_arm_with_neon):
14345 Declare.
14346 (arm_fill_vfpregset, arm_store_vfpregset): Adjust.
14347 (arm_read_description): New, with bits factored from
14348 arm_arch_setup.
14349 (arm_arch_setup): Reimplement.
14350 (target_regsets): Rename to ...
14351 (arm_regsets): ... this, and make static.
14352 (arm_regsets_info, arm_usrregs_info, regs_info): New globals.
14353 (arm_regs_info): New function.
14354 (the_low_target): Adjust.
14355 (initialize_low_arch): New function.
14356 * linux-m68k-low.c (tdesc_m68k): Declare.
14357 (target_regsets): Rename to ...
14358 (m68k_regsets): ... this, and make static.
14359 (m68k_regsets_info, m68k_usrregs_info, regs_info): New globals.
14360 (m68k_regs_info): New function.
14361 (m68k_arch_setup): New function.
14362 (the_low_target): Adjust.
14363 (initialize_low_arch): New function.
14364 * linux-sh-low.c (tdesc_sharch): Declare.
14365 (target_regsets): Rename to ...
14366 (sh_regsets): ... this, and make static.
14367 (sh_regsets_info, sh_usrregs_info, regs_info): New globals.
14368 (sh_regs_info, sh_arch_setup): New functions.
14369 (the_low_target): Adjust.
14370 (initialize_low_arch): New function.
14371 * linux-bfin-low.c (tdesc_bfin): Declare.
14372 (bfin_arch_setup): New function.
14373 (bfin_usrregs_info, regs_info): New globals.
14374 (bfin_regs_info): New function.
14375 (the_low_target): Adjust.
14376 (initialize_low_arch): New function.
14377 * linux-cris-low.c (tdesc_cris): Declare.
14378 (cris_arch_setup): New function.
14379 (cris_usrregs_info, regs_info): New globals.
14380 (cris_regs_info): New function.
14381 (the_low_target): Adjust.
14382 (initialize_low_arch): New function.
14383 * linux-cris-low.c (tdesc_crisv32): Declare.
14384 (cris_arch_setup): New function.
14385 (cris_regsets_info, cris_usrregs_info, regs_info): New globals.
14386 (cris_regs_info): New function.
14387 (the_low_target): Adjust.
14388 (initialize_low_arch): New function.
14389 * linux-m32r-low.c (tdesc_m32r): Declare.
14390 (m32r_arch_setup): New function.
14391 (m32r_usrregs_info, regs_info): New globals.
14392 (m32r_regs_info): Adjust.
14393 (initialize_low_arch): New function.
14394 * linux-tic6x-low.c (tdesc_tic6x_c64xp_linux)
14395 (tdesc_tic6x_c64x_linux, tdesc_tic6x_c62x_linux): Declare.
14396 (tic6x_usrregs_info): Forward declare.
14397 (tic6x_read_description): New function, based on ...
14398 (tic6x_arch_setup): ... this. Reimplement.
14399 (target_regsets): Rename to ...
14400 (tic6x_regsets): ... this, and make static.
14401 (tic6x_regsets_info, tic6x_usrregs_info, regs_info): New globals.
14402 (tic6x_regs_info): New function.
14403 (the_low_target): Adjust.
14404 (initialize_low_arch): New function.
14405 * linux-xtensa-low.c (tdesc_xtensa): Declare.
14406 (xtensa_fill_gregset, xtensa_store_gregset): Adjust.
14407 (target_regsets): Rename to ...
14408 (xtensa_regsets): ... this, and make static.
14409 (xtensa_regsets_info, xtensa_usrregs_info, regs_info): New
14410 globals.
14411 (xtensa_arch_setup, xtensa_regs_info): New functions.
14412 (the_low_target): Adjust.
14413 (initialize_low_arch): New function.
14414 * linux-nios2-low.c (tdesc_nios2_linux): Declare.
14415 (nios2_arch_setup): Set the current process'es tdesc.
14416 (target_regsets): Rename to ...
14417 (nios2_regsets): ... this.
14418 (nios2_regsets_info, nios2_usrregs_info, regs_info): New globals.
14419 (nios2_regs_info): New function.
14420 (the_low_target): Adjust.
14421 (initialize_low_arch): New function.
a261b8f5
PA
14422 * linux-aarch64-low.c (tdesc_aarch64): Declare.
14423 (aarch64_arch_setup): Set the current process'es tdesc.
14424 (target_regsets): Rename to ...
14425 (aarch64_regsets): ... this.
14426 (aarch64_regsets_info, aarch64_usrregs_info, regs_info): New globals.
14427 (aarch64_regs_info): New function.
14428 (the_low_target): Adjust.
14429 (initialize_low_arch): New function.
3aee8918
PA
14430 * linux-tile-low.c (tdesc_tilegx, tdesc_tilegx32): Declare
14431 globals.
14432 (target_regsets): Rename to ...
14433 (tile_regsets): ... this.
14434 (tile_regsets_info, tile_usrregs_info, regs_info): New globals.
14435 (tile_regs_info): New function.
14436 (tile_arch_setup): Set the current process'es tdesc.
14437 (the_low_target): Adjust.
14438 (initialize_low_arch): New function.
14439 * spu-low.c (tdesc_spu): Declare.
14440 (spu_create_inferior, spu_attach): Set the new process'es tdesc.
14441 * win32-arm-low.c (tdesc_arm): Declare.
14442 (arm_arch_setup): New function.
14443 (the_low_target): Install arm_arch_setup instead of
14444 init_registers_arm.
14445 * win32-i386-low.c (tdesc_i386, tdesc_amd64): Declare.
14446 (init_windows_x86): Rename to ...
14447 (i386_arch_setup): ... this. Set `win32_tdesc'.
14448 (the_low_target): Adjust.
14449 * win32-low.c (win32_tdesc): New global.
14450 (child_add_thread): Don't create the thread cache here.
14451 (do_initial_child_stuff): Set the new process'es tdesc.
14452 * win32-low.h (struct target_desc): Forward declare.
14453 (win32_tdesc): Declare.
14454 * lynx-i386-low.c (tdesc_i386): Declare global.
14455 (lynx_i386_arch_setup): Set `lynx_tdesc'.
14456 * lynx-low.c (lynx_tdesc): New global.
14457 (lynx_add_process): Set the new process'es tdesc.
14458 * lynx-low.h (struct target_desc): Forward declare.
14459 (lynx_tdesc): Declare global.
14460 * lynx-ppc-low.c (tdesc_powerpc_32): Declare global.
14461 (lynx_ppc_arch_setup): Set `lynx_tdesc'.
14462 * nto-low.c (nto_tdesc): New global.
14463 (do_attach): Set the new process'es tdesc.
14464 * nto-low.h (struct target_desc): Forward declare.
14465 (nto_tdesc): Declare.
14466 * nto-x86-low.c (tdesc_i386): Declare.
14467 (nto_x86_arch_setup): Set `nto_tdesc'.
14468
b1fbec62
GB
144692013-06-04 Gary Benson <gbenson@redhat.com>
14470
14471 * server.c (handle_query): Add "augmented-libraries-svr4-read+"
14472 to qSupported response when appropriate.
14473 (handle_qxfer_libraries_svr4): Allow qXfer:libraries-svr4:read
14474 with nonzero-length annex.
14475 * linux-low.c (linux_qxfer_libraries_svr4): Parse and handle
14476 arguments supplied in annex.
14477
d1ec4ce7
DE
144782013-05-31 Doug Evans <dje@google.com>
14479
ac44adcb 14480 PR server/15594
d1ec4ce7
DE
14481 * linux-x86-low.c (ps_get_thread_area): Properly extend address to
14482 64 bits in 64-cross-32 environment.
14483
9b25f2d3
PA
144842013-05-28 Pedro Alves <palves@redhat.com>
14485
14486 * Makefile.in (clean): Remove reference to aarch64-without-fpu.c.
14487 (aarch64-without-fpu.c): Delete rule.
14488 * configure.srv (aarch64*-*-linux*): Remove references to
14489 aarch64-without-fpu.o and aarch64-without-fpu.xml.
14490 * linux-aarch64-low.c (init_registers_aarch64_without_fpu): Remove
14491 declaration.
14492
6740dc9c
PA
144932013-05-24 Pedro Alves <palves@redhat.com>
14494
14495 * server.c (handle_v_cont) <vCont;r>: Use unpack_varlen_hex
14496 instead of strchr/decode_address. Error if the range isn't split
14497 with a ','. Don't assume there's be a ':' in the action.
14498
c2d6af84
PA
144992013-05-23 Yao Qi <yao@codesourcery.com>
14500 Pedro Alves <palves@redhat.com>
14501
14502 * linux-low.c (lwp_in_step_range): New function.
14503 (linux_wait_1): If the thread was range stepping and stopped
14504 outside the stepping range, report the stop to GDB. Otherwise,
14505 continue stepping. Add range stepping debug output.
14506 (linux_set_resume_request): Copy the step range from the resume
14507 request to the lwp.
14508 (linux_supports_range_stepping): New.
14509 (linux_target_ops) <supports_range_stepping>: Set to
14510 linux_supports_range_stepping.
14511 * linux-low.h (struct linux_target_ops)
14512 <supports_range_stepping>: New field.
14513 (struct lwp_info) <step_range_start, step_range_end>: New fields.
14514 * linux-x86-low.c (x86_supports_range_stepping): New.
14515 (the_low_target) <supports_range_stepping>: Set to
14516 x86_supports_range_stepping.
14517 * server.c (handle_v_cont): Handle 'r' action.
14518 (handle_v_requests): Append ";r" if the target supports range
14519 stepping.
14520 * target.h (struct thread_resume) <step_range_start,
14521 step_range_end>: New fields.
14522 (struct target_ops) <supports_range_stepping>:
14523 New field.
14524 (target_supports_range_stepping): New macro.
14525
58794e1a
JB
145262013-05-17 Joel Brobecker <brobecker@adacore.com>
14527
14528 * lynx-low.c (lynx_resume): Fix null_ptid/minus_one_ptid
14529 confusion in comment.
14530
d631c5a7
JB
145312013-05-17 Joel Brobecker <brobecker@adacore.com>
14532
14533 * lynx-low.c (struct process_info_private): New type.
14534 (lynx_add_process): New function.
14535 (lynx_create_inferior, lynx_attach): Replace calls to
14536 add_process by calls to lynx_add_process.
14537 (lynx_resume): If PTID is null, then try using
14538 current_process()->private->last_wait_event_ptid.
14539 Add comments.
14540 (lynx_clear_inferiors): Delete. The contents of that function
14541 has been inlined in lynx_mourn;
14542 (lynx_wait_1): Save the ptid in the process's private data.
14543 (lynx_mourn): Free the process' private data. Replace call
14544 to lynx_clear_inferiors by call to clear_inferiors.
14545
96f7a20f
YQ
145462013-05-17 Yao Qi <yao@codesourcery.com>
14547
14548 * i386-low.c (i386_length_and_rw_bits): Move the comment to
14549 the right place.
14550
db0dfaa0
LM
145512013-05-16 Luis Machado <lgustavo@codesourcery.com>
14552
14553 * linux-low.c: Move definition checks upwards for PT_TEXT_ADDR,
14554 PT_DATA_ADDR and PT_TEXT_END_ADDR. Update comments.
14555 (linux_read_offsets): Remove PT_TEXT_ADDR, PT_DATA_ADDR and
14556 PT_TEXT_END_ADDR guards. Update comments.
14557 (linux_target_op) <read_offsets>: Conditionally define to
14558 linux_read_offsets if the target is UCLIBC and if it defines
14559 PT_TEXT_ADDR, PT_DATA_ADDR and PT_TEXT_END_ADDR.
14560
68f5f838
SL
145612013-05-06 Sandra Loosemore <sandra@codesourcery.com>
14562 Andrew Jenner <andrew@codesourcery.com>
14563
14564 * Makefile.in (SFILES): Add linux-nios2-low.c.
14565 (clean): Add action to delete nios2-linux.c.
14566 (nios2-linux.c): New rule.
14567 * configure.srv: Add nios2*-*-linux*.
14568 * linux-nios2-low.c: New.
14569
1ebff1fd
HAQ
145702013-05-03 Hafiz Abid Qadeer <abidh@codesourcery.com>
14571
14572 * tracepoint.c (cmd_qtinit): Call 'stop_tracing'.
14573
f6150862
HZ
145742013-04-25 Hui Zhu <hui@codesourcery.com>
14575
14576 PR gdb/15186
f6150862
HZ
14577 * ax.c (ax_printf): Add fflush.
14578
614c279d
TT
145792013-04-22 Tom Tromey <tromey@redhat.com>
14580
14581 * Makefile.in (SFILES): Add filestuff.c.
14582 (OBS): Add filestuff.o.
14583 (filestuff.o): New target.
14584 * config.in, configure: Rebuild.
14585 * configure.ac: Check for fdwalk, pipe2.
14586
7d4e5717
PA
145872013-04-17 Pedro Alves <palves@redhat.com>
14588
14589 * configure.ac (USE_THREAD_DB): Delete variable.
14590 (if test "$srv_linux_thread_db" = "yes"): AC_DEFINE USE_THREAD_DB.
14591 Don't AC_SUBST USE_THREAD_DB.
14592 * Makefile.in (INTERNAL_CFLAGS): Remove @USE_THREAD_DB@.
14593 * config.in, configure: Regenerate.
14594
d5c93e41
PA
145952013-04-16 Pedro Alves <palves@redhat.com>
14596
14597 * linux-low.h (struct lwp_info) <thread_known>: Move under
14598 the USE_THREAD_DB #ifdef.
14599
04f5fe89
PA
146002013-04-16 Pedro Alves <palves@redhat.com>
14601
14602 * Makefile.in (INTERNAL_CFLAGS): Add @USE_THREAD_DB@.
14603 (linux-low.o): Delete rule.
14604 * linux-low.h: Always include "gdb_thread_db.h" instead of
14605 conditionally including thread_db.h.
14606 (struct lwp_info) <th>: Guard with #ifdef USE_THREAD_DB instead of
14607 HAVE_THREAD_DB_H.
14608
480b27bf
JK
146092013-04-07 Jan Kratochvil <jan.kratochvil@redhat.com>
14610
14611 * Makefile.in (install-only): Fix make install regression.
14612
43662968
JK
146132013-04-05 Jan Kratochvil <jan.kratochvil@redhat.com>
14614
14615 Convert man pages to texinfo, new gdbinit.5 texinfo page.
14616 * Makefile.in (install-only): Remove $(man1dir) and gdbserver.1
14617 installation.
14618 * gdbserver.1: Remove.
14619
3e74e146
PA
146202013-03-22 Pedro Alves <palves@redhat.com>
14621
14622 * linux-low.c (handle_extended_wait): Don't call
14623 linux_enable_event_reporting.
14624
a8347a2a
TT
146252013-03-15 Tony Theodore <tonyt@logyst.com>
14626
14627 PR build/9098:
14628 * Makefile.in (SHELL): Use @SHELL@.
14629
eeb56fa7
SDJ
146302013-03-14 Sergio Durigan Junior <sergiodj@redhat.com>
14631
14632 * tracepoint.c (cmd_qtv): Initialize `val' with zero, silencing
14633 compiler warning.
14634
4fa7e2ff
JB
146352013-03-13 Joel Brobecker <brobecker@adacore.com>
14636
14637 * linux-low.c (linux_target_ops) [!HAVE_LINUX_BTRACE]:
14638 Remove extraneous NULL element.
14639
8ddb1965
YQ
146402013-03-13 Yao Qi <yao@codesourcery.com>
14641
14642 * tracepoint.c (traceframe_read_tsv): Look for the last matched
14643 'V' block in trace frame.
14644
9accd112
MM
146452013-03-11 Markus Metzger <markus.t.metzger@intel.com>
14646
14647 * target.h (struct target_ops): Add btrace ops.
14648 (target_supports_btrace): New macro.
14649 (target_enable_btrace): New macro.
14650 (target_disable_btrace): New macro.
14651 (target_read_btrace): New macro.
14652 * gdbthread.h (struct thread_info): Add btrace field.
14653 * server.c: Include btrace-common.h.
14654 (handle_btrace_general_set): New function.
14655 (handle_btrace_enable): New function.
14656 (handle_btrace_disable): New function.
14657 (handle_general_set): Call handle_btrace_general_set.
14658 (handle_qxfer_btrace): New function.
14659 (struct qxfer qxfer_packets[]): Add btrace entry.
14660 * inferiors.c (remove_thread): Disable btrace.
14661 * linux-low: Include linux-btrace.h.
14662 (linux_low_enable_btrace): New function.
14663 (linux_low_read_btrace): New function.
14664 (linux_target_ops): Add btrace ops.
14665 * configure.srv (i[34567]86-*-linux*): Add linux-btrace.o.
14666 Add srv_linux_btrace=yes.
14667 (x86_64-*-linux*): Add linux-btrace.o.
14668 Add srv_linux_btrace=yes.
14669 * configure.ac: Define HAVE_LINUX_BTRACE.
14670 * config.in: Regenerated.
14671 * configure: Regenerated.
14672
5cc22e4c
MM
146732013-03-11 Markus Metzger <markus.t.metzger@intel.com>
14674
14675 * server.c (handle_qxfer): Preserve error message if -3 is
14676 returned.
14677 (qxfer): Document the -3 return value.
14678
7c97f91e
MM
146792013-03-11 Markus Metzger <markus.t.metzger@intel.com>
14680
14681 * Makefile.in (SFILES): Add $(srcdir)/common/linux-btrace.c.
14682 (linux_btrace_h): New variable.
14683 (linux-btrace.o): New rule.
14684
be9a119c 146852013-03-08 Stan Shebs <stan@codesourcery.com>
f6f899bf
HAQ
14686 Hafiz Abid Qadeer <abidh@codesourcery.com>
14687
14688 * tracepoint.c (trace_buffer_size): New global.
14689 (DEFAULT_TRACE_BUFFER_SIZE): New define.
14690 (init_trace_buffer): Change to one-argument function. Allocate
14691 trace buffer memory.
14692 (handle_tracepoint_general_set): Call cmd_bigqtbuffer_size to
14693 handle QTBuffer:size packet.
14694 (cmd_bigqtbuffer_size): New function.
14695 (initialize_tracepoint): Call init_trace_buffer with
14696 DEFAULT_TRACE_BUFFER_SIZE.
14697 * server.c (handle_query): Add QTBuffer:size in the
14698 supported packets.
14699
e64f7499
YQ
147002013-03-07 Yao Qi <yao@codesourcery.com>
14701
14702 * tracepoint.c (cur_action, cur_step_action): Make them unsigned.
14703 (cmd_qtfp): Initialize cur_action and cur_step_action 0 instead
14704 of -1.
14705 (cmd_qtsp): Adjust condition. Do post increment.
14706 Set cur_action and cur_step_action back to 0.
14707
f0ae6fc3
PA
147082013-03-07 Jeremy Bennett <jeremy.bennett@embecosm.com>
14709
14710 PR server/15236
14711 * linux-low.c (linux_write_memory): Return early success if LEN is
14712 zero.
14713
b5b0b0af
CV
147142013-03-05 Corinna Vinschen <vinschen@redhat.de>
14715
334ad4a8 14716 * configure.srv: Add x86_64-*-cygwin* as target.
b5b0b0af 14717
589bc927
TT
147182013-02-28 Tom Tromey <tromey@redhat.com>
14719
14720 * configure.ac: Invoke AC_SYS_LARGEFILE.
14721 * configure, config.in: Rebuild.
14722
dfe07582
CV
147232013-02-28 Corinna Vinschen <vinschen@redhat.com>
14724
14725 * win32-low.c: Throughout, fix format strings and casts of
14726 printf-like functions to avoid type related warnings on all
14727 platforms.
14728 (get_child_debug_event): Print dwDebugEventCode as hex since
14729 that's how it's usually documented.
14730
736cd585
YQ
147312013-02-28 Yao Qi <yao@codesourcery.com>
14732
14733 * tracepoint.c (cmd_qtbuffer): Call phex_nz instead of
14734 pulongest.
14735
e1f58301
JW
147362013-02-27 Jiong Wang <jiwang@tilera.com>
14737
14738 * Makefile.in (clean): Remove reg-tilegx.c, reg-tilegx32.c.
14739 (reg-tilegx32.c): New rule.
14740 * configure.srv (tilegx-*-linux*): Add reg-tilegx32.o to srv_regobj.
14741 * linux-tile-low.c (tile_arch_setup): New function. Invoke
14742 different register info initializer according to elf class.
14743 (init_registers_tilgx32): New function. The tilegx32 register info
14744 initializer.
14745 (tile_fill_gregset): Use "uint_reg_t" to represent register size.
14746 (tile_store_gregset): Likewise.
14747
d171ca78
YQ
147482013-02-27 Yao Qi <yao@codesourcery.com>
14749
14750 * server.c (process_point_options): Print debug message when
14751 debug_threads is true.
14752
282bbdf3
YQ
147532013-02-26 Yao Qi <yao@codesourcery.com>
14754
14755 * tracepoint.c (cmd_qtbuffer): Don't set '\0' in OWN_BUF.
14756
aca22551
PA
147572013-02-19 Pedro Alves <palves@redhat.com>
14758 Kai Tietz <ktietz@redhat.com>
14759
14760 PR gdb/15161
14761
14762 * server.c (handle_query) <CRC check>: Use unpack_varlen_hex
14763 instead of strtoul to extract address from packet.
14764 (process_serial_event) <'z'>: Likewise.
14765
4f3cee1c
YQ
147662013-02-18 Yao Qi <yao@codesourcery.com>
14767
14768 * linux-bfin-low.c (the_low_target): Use NULL instead of 0.
14769
8e1d55a3
PA
147702013-02-14 Pedro Alves <palves@redhat.com>
14771
14772 Plug memory leak.
14773
14774 * tracepoint.c (cmd_qtnotes): Free TRACING_USER_NAME,
14775 TRACING_NOTES and TRACING_STOP_NOTE before clobbering.
14776
458820da
PA
147772013-02-14 Pedro Alves <palves@redhat.com>
14778
14779 * tracepoint.c (cmd_qtdpsrc): Use savestring.
14780
baea0dae
PA
147812013-02-14 Pedro Alves <palves@redhat.com>
14782
14783 * tracepoint.c (save_string): Delete.
14784 (add_tracepoint_action): Use savestring instead of save_string.
14785
0b1afbb3
PA
147862013-02-12 Pedro Alves <palves@redhat.com>
14787
14788 * linux-xtensa-low.c: Ditto.
14789 * xtensa-xtregs.c: Ditto.
14790
8a4ac37e
PA
147912013-02-12 Sanimir Agovic <sanimir.agovic@intel.com>
14792
14793 * thread-db.c (thread_db_get_tls_address): NULL pointer check
14794 thread_db.
14795
148de6bb
MS
147962013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
14797
14798 * linux-aarch64-low.c (aarch64_arch_setup): Clamp
14799 aarch64_num_wp_regs and aarch64_num_bp_regs to
14800 AARCH64_HWP_MAX_NUM and AARCH64_HBP_MAX_NUM respectively.
14801
55fac6e0
MS
148022013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
14803
14804 * linux-aarch64-low.c (ps_get_thread_area): Replace
14805 PTRACE_GET_THREAD_AREA with PTRACE_GETREGSET.
14806
176eb98c
MS
148072013-02-04 Jim MacArthur <jim.macarthur@arm.com>
14808 Marcus Shawcroft <marcus.shawcroft@arm.com>
14809 Nigel Stephens <nigel.stephens@arm.com>
14810 Yufeng Zhang <yufeng.zhang@arm.com>
14811
14812 * Makefile.in (clean): Remove aarch64.c and aarch64-without-fpu.c.
14813 (aarch64.c, aarch64-without-fpu.c): New targets.
14814 * configure.srv (aarch64*-*-linux*): New.
14815 * linux-aarch64-low.c: New file.
14816
56f7af9c
MS
148172013-02-04 Marcus Shawcroft <marcus.shawcroft@arm.com>
14818
43aaf8b6 14819 * linux-low.c (handle_extended_wait, linux_create_inferior)
56f7af9c
MS
14820 (linux_attach_lwp_1, linux_kill_one_lwp, linux_attach_one_lwp)
14821 (dequeue_one_deferred_signal, linux_resume_one_thread)
14822 (fetch_register, linux_write_memory, linux_enable_event_reporting)
14823 (linux_tracefork_grandchild, linux_test_for_tracefork)
14824 (linux_read_offsets, linux_xfer_siginfo, linux_xfer_siginfo): Add
14825 PTRACE_ARG3_TYPE and PTRACE_ARG4_TYPE cast to ptrace arguments
14826 where the argument is 0.
14827
60f662b0
YQ
148282013-01-25 Yao Qi <yao@codesourcery.com>
14829
14830 * event-loop.c: Include "queue.h".
14831 (gdb_event_p): New typedef.
14832 (struct gdb_event) <next_event>: Remove.
14833 (event_queue): Change to QUEUE(gdb_event_p).
14834 (async_queue_event): Remove.
14835 (gdb_event_xfree): New.
14836 (initialize_event_loop): New.
14837 (process_event): Use API from QUEUE.
14838 (wait_for_event): Likewise.
14839 * server.c (main): Call initialize_event_loop.
14840 * server.h (initialize_event_loop): Declare.
14841
5ae4861a
YQ
148422013-01-18 Yao Qi <yao@codesourcery.com>
14843
14844 * ax.h (struct eval_agent_expr_context): New.
14845 (gdb_eval_agent_expr): Update declaration.
14846 * ax.c (gdb_eval_agent_expr): Remove argument REGCACHE and
14847 TFRAME. Add new argument CTX.
14848 * server.h (struct eval_agent_expr_context): Declare.
14849 (agent_mem_read, agent_tsv_read): Update declaration.
14850 (agent_mem_read_string): Likewise.
14851 * tracepoint.c (eval_tracepoint_agent_expr): Remove.
14852 (add_traceframe_block): Add new argument TPOINT.
14853 Increase TPOINT->traceframe_usage.
14854 (do_action_at_tracepoint): Call gdb_eval_agent_expr instead of
14855 eval_tracepoint_agent_expr.
14856 (condition_true_at_tracepoint): Likewise.
14857 (agent_mem_read): Remove argument TFRAME. Add argument CTX.
14858 (agent_mem_read_string, agent_tsv_read): Likewise.
14859
85e00e85
YQ
148602013-01-16 Yao Qi <yao@codesourcery.com>
14861
14862 * linux-low.c (linux_resume_one_lwp): Don't check
14863 'lwp->bp_reinsert != 0'.
14864
4039cf45
JB
148652013-01-07 Joel Brobecker <brobecker@adacore.com>
14866 Pedro Alves <palves@redhat.com>
14867
14868 * lynx-low.c (ptrace_request_to_str): Define a temporary
14869 macro and use it to simplify this function's implementation.
14870
9044dee2
JB
148712013-01-07 Joel Brobecker <brobecker@adacore.com>
14872
14873 * lynx-low.c (lynx_resume): Call perror_with_name if lynx_ptrace
14874 sets errno.
14875
e6352c8f
JB
148762013-01-07 Joel Brobecker <brobecker@adacore.com>
14877
14878 * configure.srv (i[34567]86-*-lynxos*): Set srv_xmlfiles.
14879
50681a27
JB
148802013-01-07 Joel Brobecker <brobecker@adacore.com>
14881
14882 * configure.srv (powerpc-*-lynxos*): Set srv_xmlfiles.
14883
3f6e77ef
JB
148842013-01-07 Joel Brobecker <brobecker@adacore.com>
14885
14886 * lynx-low.c (lynx_resume): Use the resume_info parameter
14887 to determine the ptid for the lynx_ptrace call, unless
14888 it is equal to minus_one_ptid, in which case we use the
14889 ptid of the current_inferior.
14890 (lynx_wait_1): After having received a thread create/exit
14891 event, resume the inferior's execution using the signaling
14892 thread's ptid, rather than the old ptid.
14893
7fda33ae
JB
148942013-01-07 Joel Brobecker <brobecker@adacore.com>
14895
14896 * lynx-low.c (lynx_resume): Delete variable ret.
14897
b9786c74
JB
148982013-01-01 Joel Brobecker <brobecker@adacore.com>
14899
14900 * gdbreplay.c (gdbreplay_version): Update copyright year.
14901 * server.c (gdbserver_version): Likewise.
14902
8b93d60f
JB
149032012-12-17 Joel Brobecker <brobecker@adacore.com>
14904
14905 * lynx-low.c (lynx_wait_1): Add debug trace before adding
14906 new thread.
14907
037335a7
JB
149082012-12-17 Joel Brobecker <brobecker@adacore.com>
14909
14910 * lynx-low.c (ptrace_request_to_str): Add handling for
14911 PTRACE_GETTRACESIG.
14912
52d4cbd8
JB
149132012-12-17 Joel Brobecker <brobecker@adacore.com>
14914
14915 * lynx-low.c (lynx_attach): Delete variable new_process.
14916
ab8f6ca9
JB
149172012-12-17 Joel Brobecker <brobecker@adacore.com>
14918
14919 * lynx-low.c (lynx_create_inferior): Delete variable
14920 new_process.
14921
78cbc024
JB
149222012-12-17 Joel Brobecker <brobecker@adacore.com>
14923
14924 * lynx-low.c (ptrace_request_to_str): Do not handle
14925 PTRACE_GETTHREADLIST if this macro does not exist.
14926
14a00470
YQ
149272012-12-15 Yao Qi <yao@codesourcery.com>
14928
14929 * Makefile.in (OBS): Add notif.o.
14930 * notif.c, notif.h: New.
14931 * server.c: Include "notif.h".
14932 (struct vstop_notif) <next>: Remove.
14933 <base>: New field.
14934 (queue_stop_reply): Update.
14935 (push_event, send_next_stop_reply): Remove.
14936 (discard_queued_stop_replies): Update.
14937 (notif_stop): New variable.
14938 (handle_v_stopped): Remove.
14939 (handle_v_requests): Don't call handle_v_stopped. Call
14940 handle_ack_notif instead.
14941 (queue_stop_reply_callback): Call notif_event_enque instead
14942 of queue_stop_reply.
14943 (handle_status): Don't call send_next_stop_reply, call
14944 notif_write_event instead.
14945 (kill_inferior_callback): Likewise.
14946 (detach_or_kill_inferior_callback): Likewise.
14947 (main): Call initialize_notif.
14948 (process_serial_event): Call QUEUE_is_empty.
14949 (handle_target_event): Call notif_push instead of push event.
14950 * server.h (push_event): Remove declaration.
14951
61c125b9
TT
149522012-12-10 Tom Tromey <tromey@redhat.com>
14953
14954 * Makefile.in (DEPMODE, DEPDIR, depcomp, COMPILE.pre)
14955 (COMPILE.post, COMPILE, POSTCOMPILE, IPAGENT_COMPILE): New
14956 macros.
14957 (.c.o): Rewrite.
14958 (ax-ipa.o, tracepoint-ipa.o, utils-ipa.o, format-ipa.o)
14959 (common-utils-ipa.o, remote-utils-ipa.o, regcache-ipa.o)
14960 (i386-linux-ipa.o, linux-i386-ipa.o, linux-amd64-ipa.o)
14961 (amd64-linux-ipa.o, ax.o): Rewrite.
14962 (event-loop.o, hostio.o, hostio-errno.o, inferiors.o, mem-break.o)
14963 (proc-service.o, regcache.o, remote-utils.o, server.o, target.o)
14964 (thread-db.o, tracepoint.o, utils.o, gdbreplay.o, dll.o): Remove.
14965 (signals.o, linux-procfs.o, linux-ptrace.o, common-utils.o, vec.o)
14966 (gdb_vecs.o, xml-utils.o, linux-osdata.o, ptid.o, buffer.o)
14967 (format.o, agent.o, vasprintf.o, vsnprintf.o): Rewrite.
14968 (i386-low.o, i387-fp.o, linux-low.o, linux-arm-low.o)
14969 (linux-bfin-low.o, linux-cris-low.o, linux-crisv32-low.o)
14970 (linux-ia64-low.o, linux-m32r-low.o, linux-mips-low.o)
14971 (linux-ppc-low.o, linux-s390-low.o, linux-sh-low.o)
14972 (linux-tic6x-low.o, linux-x86-low.o, linux-xtensa-low.o)
14973 (linux-tile-low.o, lynx-low.o, lynx-ppc-low.o, nto-low.o)
14974 (nto-x86-low.o, linux-low.o, win32-low.o, win32-arm-low.o)
14975 (win32-i386-low.o, spu-low.o, reg-arm.o, arm-with-iwmmxt.o)
14976 (arm-with-vfpv2.o, arm-with-vfpv3.o, arm-with-neon.o, reg-bfin.o)
14977 (reg-cris.o, reg-crisv32.o, i386.o, i386-linux.o, i386-avx.o)
14978 (i386-avx-linux.o, i386-mmx.o, i386-mmx-linux.o, reg-ia64.o)
14979 (reg-m32r.o, reg-m68k.o, reg-cf.o, mips-linux.o, mips-dsp-linux.o)
14980 (mips64-linux.o, mips64-dsp-linux.o, powerpc-32.o, powerpc-32l.o)
14981 (powerpc-altivec32l.o, powerpc-cell32l.o, powerpc-vsx32l.o)
14982 (powerpc-isa205-32l.o, powerpc-isa205-altivec32l.o)
14983 (powerpc-isa205-vsx32l.o, powerpc-e500l.o, powerpc-64l.o)
14984 (powerpc-altivec64l.o, powerpc-cell64l.o, powerpc-vsx64l.o)
14985 (powerpc-isa205-64l.o, powerpc-isa205-altivec64l.o)
14986 (powerpc-isa205-vsx64l.o, s390-linux32.o, s390-linux32v1.o)
14987 (s390-linux32v2.o, s390-linux64.o, s390-linux64v1.o)
14988 (s390-linux64v2.o, s390x-linux64.o, s390x-linux64v1.o)
14989 (s390x-linux64v2.o, tic6x-c64xp-linux.o, tic6x-c64x-linux.o)
14990 (tic6x-c62x-linux.o, reg-sh.o, reg-sparc64.o, reg-spu.o, amd64.o)
14991 (amd64-linux.o, amd64-avx.o, amd64-avx-linux.o, x32.o)
14992 (x32-linux.o, x32-avx.o, x32-avx-linux.o, reg-xtensa.o)
14993 (reg-tilegx.o): Remove.
14994 (all_object_files): New macro.
14995 Include .deps files.
14996 * aclocal.m4, configure: Rebuild.
14997 * acinclude.m4: Include depstand.m4, lead-dot.m4.
14998 * configure.ac: Invoke ZW_CREATE_DEPDIR,
14999 ZW_PROG_COMPILER_DEPENDENCIES. Compute GMAKE condition.
15000
e90e9ad9
TT
150012012-12-05 Tom Tromey <tromey@redhat.com>
15002
15003 PR gdb/14917:
15004 * server.h (current_insn_ptr, emit_error): Declare 'extern'.
15005
02d403bf 150062012-11-28 Markus Metzger <markus.t.metzger@intel.com>
945bf713
MM
15007
15008 * configure.ac: Check for linux/perf_event.h.
15009 * config.in: Regenerated.
15010 * configure: Regenerated.
15011
0270a750
PA
150122012-11-26 Maxime Villard <rustyBSD@gmx.fr>
15013
15014 * hostio.c (handle_readlink): Decrease buffer size
15015 parameter passed to readlink by one byte.
15016
8c29b58e
YQ
150172012-11-26 Yao Qi <yao@codesourcery.com>
15018
15019 * configure.ac (build_warnings): Append '-Wempty-body'.
15020 * configure: Regenerated.
15021 * linux-low.c (linux_create_inferior): Use braces for empty 'if'
15022 body.
15023
8bdce1ff
PM
150242012-11-15 Pierre Muller <muller@sourceware.org>
15025
15026 * configure.ac (AC_CHECK_HEADERS): Add wait.h header.
15027 * config.in: Regenerate.
15028 * configure: Regenerate.
15029 * linux-low.c: Use "gdb_stat.h" header instead of <sys/stat.h> header.
15030 Use "gdb_wait.h" header instead of <sys/wait.h> header.
15031 * lynx-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
15032 * remote-utils.c: Use "gdb_stat.h" header instead of <sys/stat.h>
15033 header.
15034 * server.c: Remove HAVE_WAIT_H conditional. Use "gdb_wait.h" header
15035 instead of <sys/wait.h> header.
15036 * spu-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
15037
02d403bf 150382012-11-13 Markus Metzger <markus.t.metzger@intel.com>
3ba6ad0f
MM
15039
15040 * Makefile.in: (INTERNAL_CFLAGS): Add -DGDBSERVER
15041 (various make rules): Remove -DGDBSERVER
15042
fbd5db48
YQ
150432012-11-09 Yao Qi <yao@codesourcery.com>
15044
15045 * spu-low.c (current_ptid): Move it to ..
15046 * gdbthread.h: ... here. New.
15047 * remote-utils.c (read_ptid): Use macro 'current_ptid'.
15048 * server.c (myresume, process_serial_event): Likewise.
15049 * thread-db.c (thread_db_find_new_threads): Likewise.
15050 * tracepoint.c (run_inferior_command): Likewise.
15051
b3dc46ff
AB
150522012-10-01 Andrew Burgess <aburgess@broadcom.com>
15053
15054 * server.c (handle_search_memory_1): Include access length in
15055 warning message.
15056
07c04788
HPN
150572012-09-05 Michael Brandt <michael.brandt@axis.com>
15058
15059 * linux-crisv32-low.c: Fix compile errors.
15060
918d227b
YQ
150612012-09-04 Yao Qi <yao@codesourcery.com>
15062
15063 * tracepoint.c (cmd_qtsv): Adjust debug message.
15064 Don't check CUR_TPOINT.
15065
18c1b81a
YQ
150662012-08-28 Yao Qi <yao@codesourcery.com>
15067
15068 * ax.c, tracepoint.c: Replace ATTR_FORMAT with ATTRIBUTE_PRINTF.
15069 * server.h: Include 'libiberty.h' and 'ansidecl.h'.
15070 (ATTR_NORETURN, ATTR_FORMAT, ATTR_MALLOC): Remove.
15071 Remove declarations of xmalloc, xreallloc, xstrdup and
15072 freeargv.
15073 * Makefile.in (libiberty_h): New.
15074 (server_h): Append dependencies 'libiberty.h' and 'ansidecl.h'.
15075 (linux-bfin-low.o): Append dependency 'libiberty.h'.
15076
dc82f37b
YQ
150772012-08-23 Yao Qi <yao@codesourcery.com>
15078
15079 * server.h: Remove declaration of 'xsnprintf'.
15080
406b1477
KS
150812012-08-22 Keith Seitz <keiths@redhat.com>
15082
15083 * server.h: Include build-gnulib-gbserver/config.h.
15084 * gdbreplay.c: Likewise.
15085
e6712ff1
DE
150862012-08-08 Doug Evans <dje@google.com>
15087
15088 * Makefile.in (SFILES): Add gdb_vecs.c.
15089 (OBS): Add gdb_vecs.o.
15090 (gdb_vecs_h, host_defs_h): New variables.
15091 (thread-db.o): Add $(gdb_vecs_h) dependency.
15092 (gdb_vecs.o): New rule.
15093 * thread-db.c: #include "gdb_vecs.h".
15094 (thread_db_load_search): Use a vector to iterate over path elements.
15095 Handle text appearing after "$pdir".
15096
15097 * configure.ac: Add check for strstr.
15098 * config.in: Regenerate.
15099 * configure: Regenerate.
15100
7c3270ae
UW
151012012-08-02 Ulrich Weigand <ulrich.weigand@linaro.org>
15102
15103 * hostio.c (handle_pread): If pread fails, fall back to attempting
15104 lseek/read.
15105 (handle_pwrite): Likewise for pwrite.
15106
b62e2b27
UW
151072012-08-01 Ulrich Weigand <ulrich.weigand@linaro.org>
15108
15109 * linux-arm-low.c (arm_linux_hw_point_initialize): Distinguish
15110 between unsupported TYPE and unimplementable ADDR/LEN combination.
15111 (arm_insert_point): Act on new return value.
15112
78a99e91
PA
151132012-07-31 Pedro Alves <palves@redhat.com>
15114
15115 * server.c (process_point_options): Only skip tokens if we find
15116 one that is unrecognized. Don't treat 'X' specially while
15117 skipping unrecognized tokens.
15118
fcf303ab
UW
151192012-07-30 Ulrich Weigand <ulrich.weigand@linaro.org>
15120
15121 * linux-arm-low.c (arm_linux_hw_point_initialize): Do not attempt
15122 to 4-byte-align HW breakpoint addresses for Thumb.
15123
7255706c
YQ
151242012-07-27 Yao Qi <yao@codesourcery.com>
15125
15126 PR remote/14161.
15127
15128 * server.h: Declare gdb_agent_about_to_close.
15129 * target.c (kill_inferior): Include "agent.h".
15130 New. Send command 'kill'.
15131 * target.h (kill_inferior): Removed macro.
15132 * tracepoint.c (gdb_agent_about_to_close): New.
15133 (gdb_agent_helper_thread): Handle command 'close'.
15134 Wait endlessly until the inferior stops.
15135 Install gdb_agent_remove_socket to atexit hook.
15136 (agent_socket_name): New static variable.
15137 (gdb_agent_socket_init): Replace local variable 'name' with
15138 'agent_socket_name'.
15139 (gdb_agent_remove_socket): New.
15140
5a3f286f
YQ
151412012-07-27 Yao Qi <yao@codesourcery.com>
15142
15143 * server.c (process_point_options): Stop at 'X' when parsing.
15144
961bd387
ME
151452012-07-19 Michael Eager <eager@eagercon.com>
15146
a261b8f5 15147 * i386-low.c (Z_packet_to_hw_type): Add Z_PACKET_HW_BP, translate
961bd387
ME
15148 to hw_execute.
15149 * linux-x86-low.c (x86_insert_point, x86_remove_point):
15150 Call i386_low_insert_watchpoint, i386_low_remove_watchpoint to add/del
15151 hardware breakpoint.
15152
aa7c7447
JK
151532012-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
15154
15155 * gdbserver/linux-low.c (initialize_low): Call
15156 linux_ptrace_init_warnings.
15157
7f216e7c
DE
151582012-07-02 Doug Evans <dje@google.com>
15159
15160 * mem-break.c (gdb_no_commands_at_breakpoint): Fix cast from
15161 pointer to int.
15162
d3ce09f5
SS
151632012-07-02 Stan Shebs <stan@codesourcery.com>
15164
15165 * Makefile.in (WARN_CFLAGS_NO_FORMAT): Define.
15166 (ax.o): Add it to build rule.
15167 (ax-ipa.o): Ditto.
15168 (OBS): Add format.o.
15169 (IPA_OBS): Add format.o.
15170 * server.c (handle_query): Claim support for breakpoint commands.
15171 (process_point_options): Add command case.
15172 (process_serial_event): Leave running if there are printfs in
15173 effect.
15174 * mem-break.h (any_persistent_commands): Declare.
15175 (add_breakpoint_commands): Declare.
15176 (gdb_no_commands_at_breakpoint): Declare.
15177 (run_breakpoint_commands): Declare.
15178 * mem-break.c (struct point_command_list): New struct.
15179 (struct breakpoint): New field command_list.
15180 (any_persistent_commands): New function.
15181 (add_commands_to_breakpoint): New function.
15182 (add_breakpoint_commands): New function.
15183 (gdb_no_commands_at_breakpoint): New function.
15184 (run_breakpoint_commands): New function.
15185 * linux-low.c (linux_wait_1): Test for and run breakpoint commands
15186 locally.
15187 * ax.c: Include format.h.
15188 (ax_printf): New function.
15189 (gdb_eval_agent_expr): Add printf opcode.
15190
2f8f6aed
YQ
151912012-06-13 Yao Qi <yao@codesourcery.com>
15192
15193 * server.c (start_inferior): Remove duplicated writes to fields
15194 'last_resume_kind' and 'last_status' of 'current_inferior'.
15195
0c9070b3
YQ
151962012-06-12 Yao Qi <yao@codesourcery.com>
15197 Pedro Alves <palves@redhat.com>
15198
15199 * linux-low.c (linux_set_resume_request): Simplify predicate. Add
15200 comment.
15201 * server.c (handle_v_cont): Extend comment.
15202
c52daf70
YQ
152032012-06-11 Yao Qi <yao@codesourcery.com>
15204
15205 * linux-low.c (linux_attach): Add 'static'.
15206
d38bbb0a
YQ
152072012-06-06 Yao Qi <yao@codesourcery.com>
15208
15209 * ax.c (gdb_eval_agent_expr): Print `top' in hex.
15210
89dc0afd
JK
152112012-06-01 Jan Kratochvil <jan.kratochvil@redhat.com>
15212
15213 Fix gcc -flto compilation warning.
15214 * server.c (main): Make variable multi_mode and attach volatile.
15215
75f62ce7
TJB
152162012-05-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
15217
15218 * linux-low.c (get_r_debug): Disable code using DT_MIPS_RLD_MAP
15219 if the platform doesn't know about it.
15220
65f479b6
PA
152212012-05-30 Jeff Kenton <jkenton@tilera.com>
15222
15223 * Makefile.in (SFILES): Add linux-tile-low.c.
15224 (linux-tile-low.o, reg-tilegx.o, reg-tilegx.c): New rules.
15225 * configure.srv: Handle tilegx-*-linux*.
15226 * linux-tile-low.c: New file.
15227
0c5bf5a9
JK
152282012-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
15229
15230 * linux-low.c (linux_qxfer_libraries_svr4): Return -1 if R_DEBUG is -1.
15231
a493e3e2
PA
152322012-05-24 Pedro Alves <palves@redhat.com>
15233
15234 PR gdb/7205
15235
43aaf8b6 15236 Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.
a493e3e2 15237
2ea28649
PA
152382012-05-24 Pedro Alves <palves@redhat.com>
15239
15240 PR gdb/7205
15241
15242 Replace target_signal with gdb_signal throughout.
15243
8d409d16
MR
152442012-05-22 Maciej W. Rozycki <macro@codesourcery.com>
15245
15246 * linux-low.c (linux_store_registers): Avoid the copying sequence
15247 when no data has been retrieved by ptrace.
15248
23512c01
MGD
152492012-05-22 Will Deacon <will.deacon@arm.com>
15250
15251 * linux-low (__UCLIBC__ && !(__UCLIBC_HAS_MMU__ || __ARCH_HAS_MMU__)):
15252 Include asm/ptrace.h.
15253 (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define only if not
15254 already defined.
15255
4934b29e
MR
152562012-05-21 Maciej W. Rozycki <macro@codesourcery.com>
15257
15258 * linux-low.c (linux_store_registers): Don't re-retrieve data
15259 with ptrace that has already been obtained from /proc. Always
15260 copy any data retrieved with ptrace to the buffer supplied.
15261
bde24c0a
PA
152622012-05-11 Yao Qi <yao@codesourcery.com>
15263 Pedro Alves <palves@redhat.com>
15264
15265 * linux-low.c (enum stopping_threads_kind): New.
15266 (stopping_threads): Change type to `enum stopping_threads_kind'.
15267 (handle_extended_wait): If stopping and suspending threads, leave
15268 the new_lwp suspended too.
15269 (linux_wait_for_event): Adjust.
15270 (stop_all_lwps): Set `stopping_threads' to
15271 STOPPING_AND_SUSPENDING_THREADS or STOPPING_THREADS depending on
15272 whether we're suspending threads or just stopping them. Assert no
15273 recursion happens.
15274
623b6bdf
YQ
152752012-04-29 Yao Qi <yao@codesourcery.com>
15276
15277 * server.h: Move some code to ...
15278 * gdbthread.h: ... here. New.
15279 * Makefile.in (inferiors.o, regcache.o): Depends on gdbthread.h
15280 (remote-utils.o, server.o, target.o tracepoint.o): Likewise.
15281 (nto-low.o, win32-low.o): Likewise.
15282 * inferiors.c, linux-low.h, nto-low.c: Include gdbthread.h.
15283 * regcache.c, remote-utils.c, server.c: Likewise.
15284 * target.c, tracepoint.c, win32-low.c: Likewise.
15285
f15f9948
TJB
152862012-04-24 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
15287
15288 * linux-low.h (PTRACE_ARG3_TYPE): Move macro from linux-low.c.
15289 (PTRACE_ARG4_TYPE): Likewise.
15290 (PTRACE_XFER_TYPE): Likewise.
15291 * linux-arm-low.c (arm_prepare_to_resume): Cast third argument of
15292 ptrace to PTRACE_ARG3_TYPE.
15293 * linux-low.c (PTRACE_ARG3_TYPE): Move macro to linux-low.h.
15294 (PTRACE_ARG4_TYPE): Likewise.
15295 (PTRACE_XFER_TYPE): Likewise.
15296 (linux_detach_one_lwp): Cast fourth argument of
15297 ptrace to long then PTRACE_ARG4_TYPE.
15298 (regsets_fetch_inferior_registers): Cast third argument of
15299 ptrace to long then PTRACE_ARG3_TYPE.
15300 (regsets_store_inferior_registers): Likewise.
15301
38ea300a
PA
153022012-04-20 Pedro Alves <palves@redhat.com>
15303
15304 * configure: Regenerate.
15305
c971b7fa
PA
153062012-04-19 Pedro Alves <palves@redhat.com>
15307
43aaf8b6 15308 * Makefile.in (GNULIB_BUILDDIR): New.
c971b7fa 15309 (LIBGNU, INCGNU, GNULIB_H): Adjust.
43aaf8b6
PA
15310 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): New.
15311 (all, install-only, uninstall, clean-info, all-lib, clean): No
15312 longer pass GNULIB_FLAGS_TO_PASS. Use subdir_do.
15313 (maintainer-clean realclean distclean): Use subdir_do.
15314 (subdir_do): New.
15315 (gnulib/import/Makefile): Adjust. Replace gnulib/import with
c971b7fa 15316 $(GNULIB_BUILDDIR). Don't pass argument to config.status.
43aaf8b6
PA
15317 * acinclude.m4: Include acx_configure_dir.m4.
15318 * configure.ac: Remove gl_EARLY, gl_INIT, and AM_INIT_AUTOMAKE
15319 calls. Call AC_PROG_RANLIB. Configure gnulib using
15320 ACX_CONFIGURE_DIR.
15321 (GNULIB): New.
15322 (GNULIB_STDINT_H): Adjust.
15323 (AC_OUTPUT): Don't output gnulib/Makefile anymore.
15324 * gdbreplay.c: Include build-gnulib/config.h.
15325 * server.h: Likewise.
15326 * aclocal.m4: Regenerate.
15327 * config.in: Regenerate.
15328 * configure: Regenerate.
c971b7fa 15329
809277f8
PA
153302012-04-19 Pedro Alves <palves@redhat.com>
15331
15332 * Makefile.in (LIBGNU, INCGNU): Adjust.
15333 (GNULIB_FLAGS_TO_PASS, GNULIB_H): Adjust.
15334 (all, install-only, uninstall, clean-info, all-lib, clean)
15335 (maintainer-clean, Makefile, gnulib/Makefile): Adjust.
15336 * configure.ac: Adjust AC_OUTPUT output.
15337 * aclocal.m4: Regenerate.
15338 * configure: Regenerate.
15339
fd9bb8b8
PA
153402012-04-19 Pedro Alves <palves@redhat.com>
15341
15342 * Makefile.in (generated_files): New.
15343 (server_h): Remove the explicit dependency on config.h, and depend
15344 on $generated_files.
15345
1c298c66
PA
153462012-04-19 Pedro Alves <palves@redhat.com>
15347
15348 * Makefile.in (INCGNU): Add -Ignulib.
15349
57c4b50b
PA
153502012-04-19 Pedro Alves <palves@redhat.com>
15351
15352 * Makefile.in (GNULIB_INCLUDE_DIR): Rename to ...
15353 (INCGNU): ... this, and spell out -I here.
15354 (GNULIB_LIB): Rename to ...
15355 (LIBGNU): ... this.
15356 (INCLUDE_CFLAGS, gdbserver$(EXEEXT), $(GNULIB_LIB) rule): Adjust.
15357
1030e047
PA
153582012-04-19 Pedro Alves <palves@redhat.com>
15359
15360 * config.in: Regenerate.
15361
447d4319
PA
153622012-04-19 Pedro Alves <palves@redhat.com>
15363
15364 * configure.ac: Remove AC_CHECK_DECLS check for memmem.
15365 * server.h (memmem): Remove declaration.
15366 * config.in: Regenerate.
15367 * configure: Regenerate.
15368
aad9eab9
YQ
153692012-04-19 Yao Qi <yao@codesourcery.com>
15370
15371 * Makefile.in (SFILES): Add common/vec.c.
15372 (OBS): Add vec.o.
15373 (vec.o): New rule.
15374
3e10640f
YQ
153752012-04-19 Yao Qi <yao@codesourcery.com>
15376
15377 * remote-utils.c (prepare_resume_reply): Replace with macro
15378 target_core_of_thread.
15379 * server.c (handle_qxfer_threads_proper): Likewise.
15380 * target.h (traget_core_of_thread): New macro.
15381
71622373
PA
153822012-04-18 Pedro Alves <palves@redhat.com>
15383
15384 * aclocal.m4: Regenerate.
15385 * configure: Regenerate.
15386
80d26939
YQ
153872012-04-16 Yao Qi <yao@codesourcery.com>
15388
15389 * tracepoint.c (cmd_qtstart): Download tracepoints even when they are
15390 duplicated on address.
15391
42476b70
YQ
153922012-04-16 Yao Qi <yao@codesourcery.com>
15393
15394 * tracepoint.c (COPY_FIELD_TO_BUF): New macro.
15395 (struct tracepoint_action_ops) <send>: New field.
15396 (m_tracepoint_action_send, r_tracepoint_action_send): New.
15397 (agent_expr_send, x_tracepoint_action_send): New.
15398 (l_tracepoint_action_send): New.
15399 (cmd_qtdp): Download and install tracepoint
15400 according to `use_agent'.
15401 (run_inferior_command): Add one more parameter `len'.
15402 Update callers.
15403 (tracepoint_send_agent): New.
15404 (cmd_qtdp, cmd_qtstart): Call tracepoint_send_agent.
15405
7bc83639
YQ
154062012-04-16 Yao Qi <yao@codesourcery.com>
15407
15408 * tracepoint.c (download_tracepoints): Moved to ...
15409 (cmd_qtstart): ... here.
15410
5f18041e
YQ
154112012-04-14 Yao Qi <yao@codesourcery.com>
15412
15413 * tracepoint.c: Include inttypes.h.
15414 (struct collect_memory_action): Use sized types.
15415 (struct tracepoint): Likewise.
15416 (cmd_qtdp, stop_tracing): Update print specifiers.
15417 (cmd_qtp, response_tracepoint): Likewise.
15418 (collect_data_at_tracepoint): Likewise.
15419 (collect_data_at_step): Likewise.
15420
55a8c076
YQ
154212012-04-14 Yao Qi <yao@codesourcery.com>
15422
15423 Import gnulib module inttypes.
15424 * aclocal.m4, config.in, configure: Regenerated.
15425
dc750257
YQ
154262012-04-14 Yao Qi <yao@codesourcery.com>
15427
15428 * Makefile.in (maintainer-clean, realclean, distclean): Remove
15429 Makefile and config.status at last.
15430
0ab5faf9
YQ
154312012-04-13 Yao Qi <yao@codesourcery.com>
15432
15433 * tracepoint.c: Include stdint.h unconditionally.
15434
18f5fd81
TJB
154352012-04-13 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
15436
15437 * acinclude.m4 (GDBSERVER_HAVE_THREAD_DB_TYPE): New macro based
15438 on BFD_HAVE_SYS_PROCFS_TYPE.
15439 * configure.ac: Look for lwpid_t and psaddr_t in libthread_db.h.
15440 * configure: Regenerate.
15441 * config.in: Likewise.
15442
4d47af5c
L
154432012-04-13 H.J. Lu <hongjiu.lu@intel.com>
15444
15445 * Makefile.in (clean): Also remove x32.c x32-linux.c
15446 x32-avx.c x32-avx-linux.c.
15447 (x32.o): New target.
15448 (x32.c): Likewise.
15449 (x32-linux.o): Likewise.
15450 (x32-linux.c): Likewise.
15451 (x32-avx.o): Likewise.
15452 (x32-avx.c): Likewise.
15453 (x32-avx-linux.o): Likewise.
15454 (x32-avx-linux.c): Likewise.
15455
15456 * configure.srv (srv_amd64_regobj): Add x32.o x32-avx.o.
15457 (srv_amd64_linux_regobj): Add x32-linux.o x32-avx-linux.o.
15458 (srv_i386_64bit_xmlfiles): Add i386/x32-core.xml.
15459 (srv_amd64_xmlfiles): Add i386/x32.xml i386/x32-avx.xml.
15460 (srv_amd64_linux_xmlfiles): Add i386/x32-linux.xml
15461 i386/x32-avx-linux.xml.
15462
15463 * linux-x86-low.c (init_registers_x32_linux): New prototype.
15464 (init_registers_x32_avx_linux): Likwise.
15465 (x86_linux_update_xmltarget): Call init_registers_x32_linux
15466 or init_registers_x32_avx_linux if linux_is_elf64 is false.
15467
ecedbe58
PA
154682012-04-13 Pedro Alves <palves@redhat.com>
15469
15470 * Makefile.in (GNULIB_FLAGS_TO_PASS): New.
15471 (FLAGS_TO_PASS): Don't change or set $top_srcdir, $srcdir and VPATH.
15472 (all, uninstall, clean-info, all-lib, clean, maintainer-clean)
15473 (realclean, distclean): Explicitly pass $GNULIB_FLAGS_TO_PASS to
15474 the sub-make.
15475
c92b5177
L
154762012-04-12 H.J. Lu <hongjiu.lu@intel.com>
15477
15478 * linux-x86-low.c (compat_x32_clock_t): New.
15479 (compat_x32_siginfo_t): Likewise.
15480 (compat_x32_siginfo_from_siginfo): Likewise.
15481 (siginfo_from_compat_x32_siginfo): Likewise.
15482 (linux_is_elf64): Likewise.
15483 (x86_siginfo_fixup): Call compat_x32_siginfo_from_siginfo
15484 and siginfo_from_compat_x32_siginfo for x32.
15485 (x86_arch_setup): Set linux_is_elf64.
15486
214d508e
L
154872012-04-12 H.J. Lu <hongjiu.lu@intel.com>
15488
15489 PR gdb/13969
15490 * linux-low.c (linux_pid_exe_is_elf_64_file): Also return the
15491 e_machine field.
15492 (linux_qxfer_libraries_svr4): Update call to elf_64_file_p.
15493 * linux-low.h (linux_pid_exe_is_elf_64_file): Updated.
15494 * linux-x86-low.c (x86_arch_setup): Check if GDBserver is
15495 compatible with process.
15496
c9a1864a
YQ
154972012-04-12 Yao Qi <yao@codesourcery.com>
15498
15499 * Makefile.in: Define abs_top_srcdir and abs_srcdir.
15500 (INCLUDE_CFLAGS): Append GNULIB_INCLUDE_DIR.
15501 (install-only, install-info, clean): Handle sub dir gnulib.
15502 (all-lib, am--refresh): New targets.
15503 (memmem.o): Remove target.
15504 * configure.ac: Remove AC_CONFIG_LIBOBJ_DIR.
15505 Invoke gl_EARLY. Invoke AC_CHECK_PROGS for make.
15506 (AC_REPLACE_FUNCS): Remove memmem.
15507 Invoke gl_INIT and AM_INIT_AUTOMAKE.
15508 (AC_OUTPUT): Generate Makefile in gnulib/.
15509 * aclocal.m4, config.in, configure: Regenerated.
15510
367ba2c2
MR
155112012-04-10 Maciej W. Rozycki <macro@codesourcery.com>
15512
15513 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP.
15514
9d236627
PA
155152012-04-05 Pedro Alves <palves@redhat.com>
15516
15517 -Werror=strict-aliasing
15518
15519 * spu-low.c (parse_spufs_run): Avoid dereferencing type-punned
15520 pointer.
15521
111217b3
PA
155222012-04-04 Pedro Alves <palves@redhat.com>
15523
15524 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
15525 (sparc_store_gregset_from_stack, sparc_store_gregset)
15526 (sparc_breakpoint_at): Fix formatting.
15527
8365dcf5
TJB
155282012-03-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
15529
15530 * configure.ac: Check whether Elf32_auxv_t and Elf64_auxv_t
15531 are available.
15532 * linux-low.c [HAVE_ELF32_AUXV_T] (Elf32_auxv_t): Add typedef.
15533 [HAVE_ELF64_AUXV_T] (Elf64_auxv_t): Likewise.
15534 * config.in: Regenerate.
15535 * configure: Likewise.
15536
689cc2ae
PA
155372012-03-29 Pedro Alves <palves@redhat.com>
15538
15539 * linux-low.c (regsets_store_inferior_registers) [__sparc__]:
15540 Correct ptrace arguments.
15541
c14dfd32
PA
155422012-03-28 Pedro Alves <palves@redhat.com>
15543
15544 * linux-ia64-low.c (ia64_regmap): Map IA64_EC_REGNUM to PT_AR_EC.
15545 (IA64_GR0_REGNUM, IA64_FR0_REGNUM)
15546 (IA64_FR1_REGNUM): New defines.
15547 (ia64_fetch_register): New.
15548 (the_low_target): Install it.
15549 * linux-low.h (struct linux_target_ops) <fetch_register>: New
15550 field.
15551 * linux-low.c (linux_fetch_registers): Try the
15552 the_low_target.fetch_register hook first.
15553
15554 * linux-arm-low.c (the_low_target): Adjust.
15555 * linux-bfin-low.c (the_low_target): Adjust.
15556 * linux-cris-low.c (the_low_target): Adjust.
15557 * linux-crisv32-low.c (the_low_target): Adjust.
15558 * linux-m32r-low.c (the_low_target): Adjust.
15559 * linux-m68k-low.c (the_low_target): Adjust.
15560 * linux-mips-low.c (the_low_target): Adjust.
15561 * linux-ppc-low.c (the_low_target): Adjust.
15562 * linux-s390-low.c (the_low_target): Adjust.
15563 * linux-sh-low.c (the_low_target): Adjust.
15564 * linux-sparc-low.c (the_low_target): Adjust.
15565 * linux-tic6x-low.c (the_low_target): Adjust.
15566 * linux-x86-low.c (the_low_target): Adjust.
15567 * linux-xtensa-low.c (the_low_target): Adjust.
15568
63c88e13
PA
155692012-03-26 Pedro Alves <palves@redhat.com>
15570
15571 * server.c (handle_qxfer_libraries): Don't bail early if
15572 the_target->qxfer_libraries_svr4 is not NULL.
15573
fb723180
PA
155742012-03-26 Pedro Alves <palves@redhat.com>
15575
15576 * linux-low.c (linux_qxfer_libraries_svr4): Fix pasto in comment.
15577
0afae3cf
PA
155782012-03-23 Pedro Alves <palves@redhat.com>
15579
15580 * linux-low.c (linux_qxfer_libraries_svr4): Terminate the
15581 "library-list-svr4" element's start tag when the the DSO list is
15582 empty.
15583
485f1ee4
PA
155842012-03-23 Pedro Alves <palves@redhat.com>
15585
15586 * linux-low.c (read_one_ptr): Read the inferior's pointer through
15587 a variable whose type size is the same as the inferior's pointer
15588 size.
15589
a5362b9a
TS
155902012-03-21 Thomas Schwinge <thomas@codesourcery.com>
15591
15592 * linux-arm-low.c (arm_stopped_by_watchpoint): Use siginfo_t instead of
15593 struct siginfo.
15594 * linux-low.c (siginfo_fixup, linux_xfer_siginfo): Likewise.
15595 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
15596 * linux-low.h: Include <signal.h>.
15597 (struct siginfo): Remove forward declaration.
15598 (struct linux_target_ops) <siginfo_fixup>: Use siginfo_t instead of
15599 struct siginfo.
15600
d226c142
MF
156012012-03-21 Mike Frysinger <vapier@gentoo.org>
15602
15603 * .gitignore: Ignore more files.
15604
122f36ef
PA
156052012-03-19 Pedro Alves <palves@redhat.com>
15606 Jan Kratochvil <jan.kratochvil@redhat.com>
15607
15608 * server.c (cont_thread, general_thread): Add describing comments.
15609 (start_inferior): Clear `cont_thread'.
15610 (handle_v_cont): Don't set `cont_thread' if resuming all threads
15611 of a process.
15612
fc3e5175
YQ
156132012-03-15 Yao Qi <yao@codesourcery.com>
15614
15615 * tracepoint.c (install_tracepoint): Move duplicated tracepoint
15616 handling to ...
15617 (cmd_qtdp): ... here.
15618
8d0d92cd
YQ
156192012-03-15 Yao Qi <yao@codesourcery.com>
15620
15621 * tracepoint.c (struct tracepoint_action_ops): New.
15622 (struct tracepoint_action) [!IN_PROCESS_AGENT] <ops>: New field.
15623 (m_tracepoint_action_download): New.
15624 (r_tracepoint_action_download): New.
15625 (x_tracepoint_action_download): New.
15626 (l_tracepoint_action_download): New.
15627 (add_tracepoint_action): Install `action->ops' according type.
15628 (download_tracepoint_1): Move code `download' function pointer
15629 of various tracepoint_action_ops.
15630
87b0bb13
JK
156312012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
15632
15633 * linux-low.c (linux_attach_lwp_1): New variable buffer. Call
15634 linux_ptrace_attach_warnings.
15635
5f572dec
JK
156362012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
15637
15638 * Makefile.in (linux-ptrace.o): New.
15639 * configure.srv (arm*-*-linux*, bfin-*-*linux*, crisv32-*-linux*)
15640 (cris-*-linux*, i[34567]86-*-linux*, ia64-*-linux*, m32r*-*-linux*)
15641 (m68*-*-linux*, m68*-*-uclinux*, mips*-*-linux*, powerpc*-*-linux*)
15642 (s390*-*-linux*, sh*-*-linux*, sparc*-*-linux*, tic6x-*-uclinux)
15643 (x86_64-*-linux*, xtensa*-*-linux*): Add linux-ptrace.o to SRV_TGTOBJ
15644 of these targets.
15645 * linux-low.c (linux_attach_lwp_1): Remove redundent else clause.
15646
f4647387
YQ
156472012-03-08 Yao Qi <yao@codesourcery.com>
15648 Pedro Alves <palves@redhat.com>
15649
15650 Fix PR server/13392.
15651 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Check
15652 offset of JMP insn.
15653 * tracepoint.c (remove_tracepoint): New.
15654 (cmd_qtdp): Call remove_tracepoint when failed to install.
15655
9b224c5e
PA
156562012-03-07 Pedro Alves <palves@redhat.com>
15657
15658 * linux-low.c (get_detach_signal): New.
15659 (linux_detach_one_lwp): Get rid of a pending SIGSTOP with SIGCONT.
15660 Pass on pending signals to PTRACE_DETACH. Check the result of the
15661 ptrace call.
15662 * server.c (program_signals, program_signals_p): New.
15663 (handle_general_set): Handle QProgramSignals.
15664 * server.h (program_signals, program_signals_p): Declare.
15665
e237a7e2
JK
156662012-03-05 Pedro Alves <palves@redhat.com>
15667 Jan Kratochvil <jan.kratochvil@redhat.com>
15668
15669 * linux-low.c (get_dynamic): Don't warn when PT_PHDR isn't found.
15670 New comment why.
15671
5808517f
YQ
156722012-03-03 Yao Qi <yao@codesourcery.com>
15673
15674 * tracepoint.c (tracepoint_look_up_symbols): Update call to
15675 agent_look_up_symbols.
15676
58b4daa5
YQ
156772012-03-03 Yao Qi <yao@codesourcery.com>
15678
15679 * Makefile.in (linux-low.o): Keep dependence on agent.h.
15680 (linux-x86-low.o): Likewise.
15681 * server.h: Remove in_process_agent_loaded.
15682 * tracepoint.c (in_process_agent_loaded): Removed. Moved it
15683 common/agent.c.
15684 Update callers.
15685
8ffcbaaf
YQ
156862012-03-03 Yao Qi <yao@codesourcery.com>
15687
15688 * tracepoint.c (gdb_agent_capability): New global.
15689 (in_process_agent_loaded_ust): Renamed to
15690 `in_process_agent_supports_ust'.
15691 Update callers.
15692 (in_process_agent_supports_ust): Call agent_capability_check.
15693 (clear_installed_tracepoints): Assert that agent supports
15694 agent.
15695
d1feda86
YQ
156962012-03-03 Yao Qi <yao@codesourcery.com>
15697
15698 * linux-low.c (linux_supports_agent): New.
15699 (linux_target_ops): Initialize field `supports_agent' with
15700 linux_supports_agent.
15701 * target.h (struct target_ops) <supports_agent>: New.
15702 (target_supports_agent): New macro.
15703 * server.c (handle_general_set): Handle packet 'QAgent'.
15704 (handle_query): Send `QAgent+'.
15705 * Makefile.in (server.o): Depends on agent.h.
15706
2fa291ac
YQ
157072012-03-03 Yao Qi <yao@codesourcery.com>
15708
15709 * Makefile.in (OBS): Add agent.o.
15710 Add new rule for agent.o.
15711 Track dependence of tracepoint.c on agent.h.
15712 * tracepoint.c (run_inferior_command_1):
15713 (run_inferior_command): Call agent_run_command.
15714 (gdb_ust_connect_sync_socket): Deleted. Move it to
15715 common/agent.c.
15716 (resume_thread, stop_thread): Likewise.
15717 (gdb_ust_socket_init): Renamed to ...
15718 (gdb_agent_socket_init): ... New.
15719 (gdb_ust_thread): Renamed to ...
15720 (gdb_agent_helper_thread): ... New.
15721 (gdb_ust_init): Move some code to ...
15722 (gdb_agent_init): ... here. New.
15723 [HAVE_UST]: Call gdb_ust_init.
15724 (initialize_tracepoint_ftlib): Call gdb_agent_init.
15725 * configure.ac: Add `sys/un.h' to AC_CHECK_HEADERS.
15726 * config.in, configure: Regenerated.
15727
05044653
PA
157282012-03-02 Pedro Alves <palves@redhat.com>
15729
15730 * inferiors.c (add_pid_to_list, pull_pid_from_list): Delete.
15731 * linux-low.c (struct simple_pid_list): New.
15732 (stopped_pids): New a struct simple_pid_list pointer.
15733 (add_to_pid_list, pull_pid_from_list): New.
15734 (handle_extended_wait): Don't assume the first signal new children
15735 report is SIGSTOP. Adjust call to pull_pid_from_list.
15736 (linux_wait_for_lwp): Adjust.
15737
8d00225b
YQ
157382012-03-02 Yao Qi <yao@codesourcery.com>
15739
15740 * tracepoint.c (do_action_at_tracepoint): Write `stop_pc' in
15741 debug log.
15742
19560ba5
YQ
157432012-03-02 Yao Qi <yao@codesourcery.com>
15744
15745 * tracepoint.c (collect_ust_data_at_tracepoint): Remove parameters
15746 `stop_pc' and `tpoint'. Update caller.
15747
1faeff08
MR
157482012-03-01 Maciej W. Rozycki <macro@codesourcery.com>
15749
15750 * linux-low.h (linux_target_ops): Add regset_bitmap member.
15751 * linux-low.c (use_linux_regsets): New macro.
15752 [!HAVE_LINUX_REGSETS] (regsets_fetch_inferior_registers): Likewise.
15753 [!HAVE_LINUX_REGSETS] (regsets_store_inferior_registers): Likewise.
15754 (linux_register_in_regsets): New function.
15755 (usr_fetch_inferior_registers): Skip registers covered by
15756 regsets.
15757 (usr_store_inferior_registers): Likewise.
15758 (usr_fetch_inferior_registers): New macro.
15759 (usr_store_inferior_registers): Likewise.
15760 (linux_fetch_registers): Handle mixed regset/non-regset targets.
15761 (linux_store_registers): Likewise.
15762 * linux-mips-low.c (init_registers_mips_dsp_linux): New
15763 prototype.
15764 (init_registers_mips64_dsp_linux): Likewise.
15765 (init_registers_mips_linux): New macro.
15766 (init_registers_mips_dsp_linux): Likewise.
15767 (mips_dsp_num_regs): Likewise.
15768 (DSP_BASE, DSP_CONTROL): New fallback macros.
15769 (mips_base_regs): New macro.
15770 (mips_regmap): Use it. Fix the size.
15771 (mips_dsp_regmap): New variable.
15772 (mips_dsp_regset_bitmap): Likewise.
15773 (mips_arch_setup): New function.
15774 (mips_cannot_fetch_register): Use the_low_target.regmap rather
15775 than mips_regmap.
15776 (mips_cannot_store_register): Likewise.
15777 (the_low_target): Update .arch_setup, .num_regs and .regmap
15778 initializers. Add .regset_bitmap initializer.
15779 * linux-arm-low.c (the_low_target): Add .regset_bitmap
15780 initializer.
15781 * linux-bfin-low.c (the_low_target): Likewise.
15782 * linux-cris-low.c (the_low_target): Likewise.
15783 * linux-crisv32-low.c (the_low_target): Likewise.
15784 * linux-ia64-low.c (the_low_target): Likewise.
15785 * linux-m32r-low.c (the_low_target): Likewise.
15786 * linux-m68k-low.c (the_low_target): Likewise.
15787 * linux-ppc-low.c (the_low_target): Likewise.
15788 * linux-s390-low.c (the_low_target): Likewise.
15789 * linux-sh-low.c (the_low_target): Likewise.
15790 * linux-sparc-low.c (the_low_target): Likewise.
15791 * linux-tic6x-low.c (the_low_target): Likewise.
15792 * linux-x86-low.c (the_low_target): Likewise.
15793 * linux-xtensa-low.c (the_low_target): Likewise.
15794 * configure.srv <mips*-*-linux*>: Add mips-dsp-linux.o and
15795 mips64-dsp-linux.o to srv_regobj. Add mips-dsp-linux.xml,
15796 mips64-dsp-linux.xml, mips-dsp.xml and mips64-dsp.xml to
15797 srv_xmlfiles.
15798 * Makefile.in (mips-dsp-linux.o, mips-dsp-linux.c): New targets.
15799 (mips64-dsp-linux.o, mips64-dsp-linux.c): Likewise.
15800
c03e6ccc
YQ
158012012-02-29 Yao Qi <yao@codesourcery.com>
15802 Pedro Alves <palves@redhat.com>
15803
15804 * linux-low.c: (linux_wait_1): Call unsuspend_all_lwps when
15805 `step_over_finished' is true.
15806
644cebc9
PA
158072012-02-27 Pedro Alves <palves@redhat.com>
15808
15809 * linux-low.c (pid_is_stopped): Delete, moved to common/.
15810 (linux_attach_lwp_1): Adjust to use linux_proc_pid_is_stopped.
15811
c14d7ab2
PA
158122012-02-27 Pedro Alves <palves@redhat.com>
15813
15814 PR server/9684
15815 * linux-low.c (pid_is_stopped): New.
15816 (linux_attach_lwp_1): Handle attaching to 'T (stopped)' processes.
15817
412c89dd
LM
158182012-02-25 Luis Machado <lgustavo@codesourcery.com>
15819
15820 * mem-break.c (clear_gdb_breakpoint_conditions): Fix de-allocation
15821 of conditions.
15822
b745defe
MR
158232012-02-24 Maciej W. Rozycki <macro@codesourcery.com>
15824
15825 * linux-mips-low.c (mips_regmap): Correct the index of $f9.
15826
9f3a5c85
LM
158272012-02-24 Luis Machado <lgustavo@codesourcery>
15828
15829 * server.c (handle_query): Advertise support for target-side
15830 breakpoint condition evaluation.
15831 (process_point_options): New function.
15832 (process_serial_event): When inserting a breakpoint, check for
15833 a target-side condition that should be evaluated.
15834
15835 * mem-break.c: Include regcache.h and ax.h.
15836 (point_cond_list_t): New data structure.
15837 (breakpoint) <cond_list>: New field.
15838 (find_gdb_breakpoint_at): Make non-static.
15839 (delete_gdb_breakpoint_at): Clear any target-side
15840 conditions.
15841 (clear_gdb_breakpoint_conditions): New function.
15842 (add_condition_to_breakpoint): Likewise.
15843 (add_breakpoint_condition): Likewise.
15844 (gdb_condition_true_at_breakpoint): Likewise.
15845 (gdb_breakpoint_here): Return result directly instead
15846 of going through a local variable.
15847
15848 * mem-break.h (find_gdb_breakpoint_at): New prototype.
15849 (clear_gdb_breakpoint_conditions): Likewise.
15850 (add_breakpoint_condition): Likewise.
15851 (gdb_condition_true_at_breakpoint): Likewise.
15852
15853 * linux-low.c (linux_wait_1): Evaluate target-side breakpoint condition.
15854 (need_step_over_p): Take target-side breakpoint condition into
15855 consideration.
15856
5e1dc496
LM
158572012-02-24 Luis Machado <lgustavo@codesourcery>
15858
15859 * server.h: Include tracepoint.h.
15860 (agent_mem_read, agent_get_trace_state_variable_value,
15861 agent_set_trace_state_variable_value,
15862 agent_tsv_read, agent_mem_read_string, get_get_tsv_func_addr,
15863 get_set_tsv_func_addr): New prototypes.
15864
15865 * ax.h: New include file.
15866 * ax.c: New source file.
15867
15868 * tracepoint.c: Include ax.h.
15869 (gdb_agent_op, gdb_agent_op_names, gdb_agent_op_sizes,
15870 agent_expr, eval_result_type): Move to ax.h.
15871 (parse_agent_expr): Rename to ...
15872 (gdb_parse_agent_expr): ... this, make it non-static and move
15873 to ax.h.
15874 (unparse_agent_expr) Rename to ...
15875 (gdb_unparse_agent_expr): ... this, make it non-static and move
15876 to ax.h.
15877 (eval_agent_expr): Rename to ...
15878 (eval_tracepoint_agent_expr): ... this.
15879 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Remove
15880 forward declarations.
15881 (add_tracepoint_action): Call gdb_parse_agent_expr (...).
15882 (agent_get_trace_state_variable_value): New function.
15883 (agent_set_trace_state_variable_value): New function.
15884 (cmd_qtdp): Call gdb_parse_agent_expr (...).
15885 (response_tracepoint): Call gdb_unparse_agent_expr (...).
15886 (do_action_at_tracepoint): Call eval_tracepoint_agent_expr (...).
15887 (condition_true_at_tracepoint): Likewise.
15888 (parse_agent_expr): Rename to ...
15889 (gdb_parse_agent_expr): ... this and move to ax.c.
15890 (unparse_agent_expr): Rename to ...
15891 (gdb_unparse_agent_expr): ... this and move to ax.c.
15892 (gdb_agent_op_name): Move to ax.c.
15893 (eval_agent_expr): Rename to ...
15894 (gdb_eval_agent_expr): ... this, use regcache passed as parameter
15895 and move to ax.c.
15896 (eval_tracepoint_agent_expr): New function.
15897 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Make
43aaf8b6 15898 non-static.
5e1dc496
LM
15899 (current_insn_ptr, emit_error, struct bytecode_address): Move to
15900 ax.c.
15901 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul, emit_lsh,
15902 emit_rsh_signed, emit_rsh_unsigned, emit_ext, emit_log_not,
15903 emit_bit_and, emit_bit_or, emit_bit_xor, emit_bit_not, emit_equal,
15904 emit_less_signed, emit_less_unsigned, emit_ref, emit_if_goto,
15905 emit_goto, write_goto_address, emit_const, emit_reg, emit_pop,
15906 emit_stack, emit_zero_ext, emit_swap, emit_stack_adjust,
15907 emit_int_call_1, emit_void_call_2, emit_eq_goto, emit_ne_goto,
15908 emit_lt_goto, emit_ge_goto, emit_gt_goto, emit_le_goto): Move to ax.c.
15909 (get_get_tsv_func_addr, get_set_tsv_func_addr): New functions.
15910 (compile_bytecodes): Remove forward declaration.
15911 (is_goto_target): Move to ax.c.
15912 (compile_bytecodes): Move to ax.c and call
15913 agent_get_trace_state_variable_value (...) and
15914 agent_set_trace_state_variable_value (...).
15915
15916 * Makefile.in: Update ax.c and IPA dependencies.
15917
277e4e52
PA
159182012-02-24 Pedro Alves <palves@redhat.com>
15919
15920 * tracepoint.c (cmd_bigqtbuffer): Rename as ...
15921 (cmd_bigqtbuffer_circular): ... this. Only handle
15922 'QTBuffer:circular:'.
15923 (handle_tracepoint_general_set): Adjust.
15924
bf4c19f7
YQ
159252012-02-16 Yao Qi <yao@codesourcery.com>
15926
15927 * inferiors.c: Move code to ...
15928 * dll.c: .... here. New.
15929 * server.h: Declare clear_dlls.
15930 * Makefile.in (SFILES): Add dll.c.
15931 (OBS): Add dll.o
15932 (dll.o): New rule.
15933
d73f2619
YQ
159342012-02-11 Yao Qi <yao@codesourcery.com>
15935
15936 * server.c: (handle_monitor_command): Add a new parameter
15937 `own_buf'.
15938 (handle_query): Update caller.
15939
f8255c2a
JB
159402012-02-09 Joel Brobecker <brobecker@adacore.com>
15941
15942 * configure.ac: Add readlink to AC_CHECK_FUNCS list.
15943 * configure, config.in: Regenerate.
15944 * hostio.c: Provide an alternate implementation if HAVE_READLINK
15945 is not defined.
15946
da84f473
PA
159472012-02-02 Pedro Alves <palves@redhat.com>
15948
15949 Try SIGKILL first, then PTRACE_KILL.
15950 * linux-low.c (linux_kill_one_lwp): New.
15951 (linux_kill_one_lwp): Rename to ...
15952 (kill_one_lwp_callback): ... this. Use the new
15953 linux_kill_one_lwp.
15954
e886a173
PA
159552012-02-02 Pedro Alves <palves@redhat.com>
15956
15957 * tracepoint.c (cmd_qtminftpilen): Return 0 if there's no current
15958 inferior.
15959
be07f1a2
PA
159602012-01-27 Pedro Alves <palves@redhat.com>
15961
15962 * linux-low.c (linux_child_pid_to_exec_file): Delete.
15963 (elf_64_file_p): Make static.
15964 (linux_pid_exe_is_elf_64_file): New.
15965 * linux-low.h (linux_child_pid_to_exec_file, elf_64_file_p):
15966 Delete declarations.
15967 (linux_pid_exe_is_elf_64_file): Declare.
15968 * linux-x86-low.c (x86_arch_setup): Use
15969 linux_pid_exe_is_elf_64_file.
15970
d8301ad1
JK
159712012-01-25 Jan Kratochvil <jan.kratochvil@redhat.com>
15972
15973 * linux-low.c (linux_wait_for_event_1): Rename to ...
15974 (linux_wait_for_event): ... here and merge it with former
15975 linux_wait_for_event - new variable wait_ptid, use it.
15976 (linux_wait_for_event): Remove - merge it to linux_wait_for_event_1.
15977
01b17894
PA
159782012-01-23 Pedro Alves <palves@redhat.com>
15979
15980 * server.c (main): Avoid yet another case of infinite loop while
15981 detaching/killing after a longjmp.
15982
e825046f
JK
159832012-01-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15984
15985 Code cleanup.
15986 * linux-low.c (linux_wait_for_event_1): Use ptid_is_pid.
15987
b9e7b9c3
UW
159882012-01-20 Ulrich Weigand <ulrich.weigand@linaro.org>
15989
15990 * hostio.c (handle_readlink): New function.
15991 (handle_vFile): Call it to handle "vFile:readlink" packets.
15992
901f9912
UW
159932012-01-20 Pedro Alves <palves@redhat.com>
15994 Ulrich Weigand <ulrich.weigand@linaro.org>
15995
15996 * server.c (handle_v_requests): Only support vAttach and vRun to
15997 start multiple processes when in extended protocol mode.
15998
fc1ab1a0
PA
159992012-01-17 Pedro Alves <palves@redhat.com>
16000
16001 * tracepoint.c (initialize_tracepoint): Use mmap instead of
16002 memalign plus mprotect to allocate the scratch buffer.
16003
7d5d4e98
PA
160042012-01-13 Pedro Alves <palves@redhat.com>
16005
16006 * server.c (attach_inferior): Clear `cont_thread'.
16007
f128d5e9
PA
160082012-01-13 Pedro Alves <palves@redhat.com>
16009
16010 * server.c (main): Avoid infinite loop while detaching/killing
16011 after a longjmp.
16012
06db92f0
DE
160132012-01-09 Doug Evans <dje@google.com>
16014
16015 * server.c (start_inferior): Set last_ptid in --wrapper case.
16016
32d92999
YQ
160172012-01-06 Yao Qi <yao@codesourcery.com>
16018
16019 * tracepoint.c [IN_PROCESS_AGENT] (debug_threads): Macro
16020 defined.
16021 [IN_PROCESS_AGENT] (debug_agent): New global variable.
16022
5e0a92a9
YQ
160232012-01-04 Yao Qi <yao@codesourcery.com>
16024
16025 * tracepoint.c (cmd_qtdp): Print debug message
16026 for static tracepoint.
16027
ae639e8c
YQ
160282012-01-04 Yao Qi <yao@codesourcery.com>
16029
16030 * tracepoint.c (trace_vdebug): Differentiate debug message
16031 between gdbserver and IPA.
16032
f72429c5
YQ
160332012-01-03 Yao Qi <yao@codesourcery.com>
16034
16035 * tracepoint.c (tracepoint_was_hit): Don't collect for
16036 static tracepoint.
16037
12c3e59c
JB
160382012-01-02 Joel Brobecker <brobecker@adacore.com>
16039
16040 * terminal.h: Reformat copyright header.
16041
67827812
JB
160422012-01-02 Joel Brobecker <brobecker@adacore.com>
16043
16044 * server.c (gdbserver_version): Update copyright year.
16045 * gdbreplay.c (gdbreplay_version): Likewise.
16046
3e52c33d
JK
160472011-12-18 Jan Kratochvil <jan.kratochvil@redhat.com>
16048
16049 * linux-low.c (linux_create_inferior): Put empty if clause for write.
16050
16051 Revert:
16052 2011-12-18 Hui Zhu <teawater@gmail.com>
16053 * linux-low.c (linux_create_inferior): Save return value to ret.
16054
66f1260e
HZ
160552011-12-18 Hui Zhu <teawater@gmail.com>
16056
16057 * linux-low.c (linux_create_inferior): Save return value to ret.
16058
e77616d7
DE
160592011-12-16 Doug Evans <dje@google.com>
16060
e7b06c57
DE
16061 * linux-low.c (linux_create_inferior): If stdio connection,
16062 redirect stdin from /dev/null, stdout to stderr.
16063 * remote-utils.c (remote_is_stdio): New static global.
16064 (remote_connection_is_stdio): New function.
16065 (remote_prepare): Handle stdio connection.
16066 (remote_open): Ditto.
16067 (remote_close): Don't close stdin for stdio connections.
16068 (read_prim,write_prim): New functions. Replace all calls to
16069 read/write to these.
16070 * server.c (main): Watch for "-" argument. Move call to
16071 remote_prepare before start_inferior.
16072 * server.h (STDIO_CONNECTION_NAME): New macro.
16073 (remote_connection_is_stdio): Declare.
16074
e77616d7
DE
16075 * remote-utils.c (prepare_resume_reply): Remove extraneous \n
16076 in debugging output.
16077
82067193
YQ
160782011-12-15 Yao Qi <yao@codesourcery.com>
16079
16080 * tracepoint.c: Include sys/syscall.h.
16081 (gdb_ust_thread): Remove preprocessor conditional.
16082
82bfbe7e
PA
160832011-12-14 Pedro Alves <pedro@codesourcery.com>
16084
16085 * linux-low.c (linux_detach_one_lwp): Call
16086 the_low_target.prepare_to_resume before detaching.
16087
712c6575
YQ
160882011-12-14 Yao Qi <yao@codesourcery.com>
16089
16090 * tracepoint.c (gdb_ust_thread): Don't ignore return value
16091 of write.
16092
d54d1edf
YQ
160932011-12-14 Yao Qi <yao@codesourcery.com>
16094
16095 * i386-low.c (i386_low_stopped_data_address): Initialize local
16096 variable `control'.
16097
6210a125
PA
160982011-12-13 Pedro Alves <pedro@codesourcery.com>
16099
16100 PR remote/13492
16101
16102 * i386-low.c (i386_low_stopped_data_address): Avoid fetching
16103 DR_CONTROL unless necessary. Extend comments.
16104 * linux-x86-low.c (x86_linux_prepare_to_resume): Don't write to
16105 DR0-3 if not used. If any watchpoint was set, clear DR_STATUS.
16106
2ece8244
YQ
161072011-12-13 Yao Qi <yao@codesourcery.com>
16108
16109 * tracepoint.c (trace_buffer_alloc): Replace magic numbers with
16110 macros.
16111 (upload_fast_traceframes, upload_fast_traceframes): Likewise.
16112
784867a5
JK
161132011-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
16114
16115 * linux-low.c (linux_kill): Skip PTRACE_KILL if LWP does not exist.
16116 Print new debug message for such case.
16117
6bf36717
JK
161182011-12-06 Jan Kratochvil <jan.kratochvil@redhat.com>
16119
16120 Fix overlapping memcpy.
16121 * mem-break.c (set_raw_breakpoint_at): New variable buf. Use it for
16122 the read_inferior_memory transfer.
16123 (delete_fast_tracepoint_jump): New variable buf. Use it for the
16124 write_inferior_memory transfer.
16125 (set_fast_tracepoint_jump): New variable buf. Use it for the
16126 read_inferior_memory and write_inferior_memory transfers.
16127 (uninsert_fast_tracepoint_jumps_at, reinsert_fast_tracepoint_jumps_at)
16128 (delete_raw_breakpoint, uninsert_raw_breakpoint): New variable buf.
16129 Use it for the write_inferior_memory transfer.
16130 (check_mem_read, check_mem_write): New gdb_asserts for overlapping
16131 buffers.
16132
50275556
MR
161332011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
16134
16135 * linux-low.c (fetch_register, store_register): Make code
16136 consistent, fix formatting.
16137
7325beb4
MR
161382011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
16139
16140 * linux-low.c (usr_store_inferior_registers): Factor out code
16141 to handle individual registers into...
16142 (store_register): ... this new function.
16143
c642a434
UW
161442011-12-06 Ulrich Weigand <uweigand@de.ibm.com>
16145
16146 * Makefile.in (s390-linux32v1.o, s390-linux32v1.c): New rules.
16147 (s390-linux32v2.o, s390-linux32v2.c): Likewise.
16148 (s390-linux64v1.o, s390-linux64v1.c): Likewise.
16149 (s390-linux64v2.o, s390-linux64v2.c): Likewise.
16150 (s390x-linux64v1.o, s390x-linux64v1.c): Likewise.
16151 (s390x-linux64v2.o, s390x-linux64v2.c): Likewise.
16152 * configure.srv [s390*-*-linux*] (srv_regobj): Add new objects.
16153 (srv_xmlfiles): Add new XML files.
16154
16155 * linux-s390-low.c: Include "elf/common.h", <sys/ptrace.h>,
16156 and <sys/uio.h>.
16157 (PTRACE_GETREGSET, PTRACE_SETREGSET): Define if undefined.
16158 (init_registers_s390_linux32v1): Add prototype.
16159 (init_registers_s390_linux32v2): Likewise.
16160 (init_registers_s390_linux64v1): Likewise.
16161 (init_registers_s390_linux64v2): Likewise.
16162 (init_registers_s390x_linux64v1): Likewise.
16163 (init_registers_s390x_linux64v2): Likewise.
16164 (s390_num_regs): Increment to 52.
16165 (s390_regmap): Add orig_r2 register.
16166 (s390_num_regs_3264): Increment to 68.
16167 (s390_regmap_3264): Add orig_r2 register.
16168 (s390_collect_ptrace_register): Handle orig_r2 register.
16169 (s390_supply_ptrace_register): Likewise.
16170 (s390_fill_last_break): New function.
16171 (s390_store_last_break): Likewise.
16172 (s390_fill_system_call): New function.
16173 (s390_store_system_call): Likewise.
16174 (target_regsets): Handle NT_S390_LAST_BREAK and NT_S390_SYSTEM_CALL
16175 register sets.
16176 (s390_check_regset): New function.
16177 (s390_arch_setup): Check for presence of NT_S390_LAST_BREAK and
16178 NT_S390_SYSTEM_CALL regsets and use appropriate description.
16179 Update target_regsets for available register sets.
16180
2268b414
JK
161812011-12-02 Paul Pluzhnikov <ppluzhnikov@google.com>
16182 Jan Kratochvil <jan.kratochvil@redhat.com>
16183
16184 * linux-low.c (get_phdr_phnum_from_proc_auxv, get_dynamic, get_r_debug)
16185 (read_one_ptr, struct link_map_offsets, linux_qxfer_libraries_svr4):
16186 New.
16187 (struct linux_target_ops): Install linux_qxfer_libraries_svr4.
16188 * linux-low.h (struct process_info_private): New member r_debug.
16189 * server.c (handle_qxfer_libraries): Call
16190 the_target->qxfer_libraries_svr4.
16191 (handle_qxfer_libraries_svr4): New function.
16192 (qxfer_packets): New entry "libraries-svr4".
16193 (handle_query): Check QXFER_LIBRARIES_SVR4 and report libraries-svr4.
16194 * target.h (struct target_ops): New member qxfer_libraries_svr4.
16195 * remote.c (remote_xfer_partial): Call add_packet_config_cmd for
16196 PACKET_qXfer_libraries_svr4.
16197
d6db1fab
UW
161982011-11-30 Ulrich Weigand <uweigand@de.ibm.com>
16199
16200 * linux-s390-low.c (s390_collect_ptrace_register): Fully convert
16201 PSW address/mask between 8-byte and 16-byte formats.
16202 (s390_supply_ptrace_register): Likewise.
16203 (s390_get_pc, s390_set_pc): 4-byte PSW address always includes
16204 basic addressing mode bit.
16205
242f5f1c
SS
162062011-11-24 Stan Shebs <stan@codesourcery.com>
16207
16208 * tracepoint.c (cmd_qtstatus): Use plongest instead of %llx.
16209
f196051f
SS
162102011-11-17 Stan Shebs <stan@codesourcery.com>
16211
16212 * tracepoint.c (struct tracepoint): New field traceframe_usage.
16213 (tracing_start_time): New global.
16214 (tracing_stop_time): New global.
16215 (tracing_user_name): New global.
16216 (tracing_notes): New global.
16217 (tracing_stop_note): New global.
16218 (cmd_qtstart): Set traceframe_usage, start_time.
16219 (stop_tracing): Set stop_time.
16220 (cmd_qtstatus): Report additional status.
16221 (cmd_qtp): New function.
16222 (handle_tracepoint_query): Call it.
16223 (cmd_qtnotes): New function.
16224 (handle_tracepoint_general_set): Call it.
16225 (get_timestamp): Rename from tsv_get_timestamp.
16226
405f8e94
SS
162272011-11-14 Stan Shebs <stan@codesourcery.com>
16228 Kwok Cheung Yeung <kcy@codesourcery.com>
16229
16230 * linux-x86-low.c (small_jump_insn): New.
16231 (i386_install_fast_tracepoint_jump_pad): Add arguments for
16232 trampoline and error message, build a trampoline and issue a small
16233 jump instruction to it.
16234 (x86_install_fast_tracepoint_jump_pad): Add arguments for
16235 trampoline and error message.
16236 (x86_get_min_fast_tracepoint_insn_len): New.
16237 (the_low_target): Add call to x86_get_min_fast_tracepoint_insn_len.
16238 * linux-low.h (struct linux_target_ops): Add arguments to
16239 install_fast_tracepoint_jump_pad operation, add new operation.
16240 * linux-low.c (linux_install_fast_tracepoint_jump_pad): Add
16241 arguments.
16242 (linux_get_min_fast_tracepoint_insn_len): New function.
16243 (linux_target_op): Add new operation.
16244 * tracepoint.c (gdb_trampoline_buffer): New IPA variable.
16245 (gdb_trampoline_buffer_end): Ditto.
16246 (gdb_trampoline_buffer_error): Ditto.
16247 (struct ipa_sym_addresses): Add fields for new IPA variables.
16248 (symbol_list): Add entries for new IPA variables.
16249 (struct tracepoint): Add fields to hold the address range of the
16250 trampoline used by the tracepoint.
16251 (trampoline_buffer_head): New static variable.
16252 (trampoline_buffer_tail): Ditto.
16253 (claim_trampoline_space): New function.
16254 (have_fast_tracepoint_trampoline_buffer): New function.
16255 (clone_fast_tracepoint): Fill in trampoline fields of tracepoint
16256 structure.
16257 (install_fast_tracepoint): Ditto, also add error buffer argument.
16258 (cmd_qtminftpilen): New function.
16259 (handle_tracepoint_query): Add response to qTMinFTPILen packet.
16260 (fast_tracepoint_from_trampoline_address): New function.
16261 (fast_tracepoint_collecting): Handle trampoline as part of jump
16262 pad space.
16263 (set_trampoline_buffer_space): New function.
16264 (initialize_tracepoint): Initialize new IPA variables.
16265 * target.h (struct target_ops): Add arguments to
16266 install_fast_tracepoint_jump_pad operation, add new
16267 get_min_fast_tracepoint_insn_len operation.
16268 (target_get_min_fast_tracepoint_insn_len): New.
16269 (install_fast_tracepoint_jump_pad): Add arguments.
16270 * server.h (IPA_BUFSIZ): Define.
16271 * linux-i386-ipa.c: Include extra header files.
16272 (initialize_fast_tracepoint_trampoline_buffer): New function.
16273 (initialize_low_tracepoint): Call it.
16274 * server.h (set_trampoline_buffer_space): Declare.
16275 (claim_trampoline_space): Ditto.
16276 (have_fast_tracepoint_trampoline_buffer): Ditto.
16277
1e4d1764
YQ
162782011-11-14 Yao Qi <yao@codesourcery.com>
16279
16280 * server.c (handle_query): Handle InstallInTrace for qSupported.
16281 * tracepoint.c (add_tracepoint): Sort list.
16282 (install_tracepoint, download_tracepoint): New.
16283 (cmd_qtdp): Call them to install and download tracepoints.
16284 (sort_tracepoints): Removed.
16285 (cmd_qtstart): Update.
16286
5c73ff4e
YQ
162872011-11-14 Yao Qi <yao@codesourcery.com>
16288
16289 * mem-break.c (inc_ref_fast_tracepoint_jump): New.
16290 * mem-break.h: Declare.
16291 * tracepoint.c (cmd_qtstart): Move some code to ...
16292 (clone_fast_tracepoint, install_fast_tracepoint): ... here.
16293 New.
16294 (download_tracepoints): Move some code to ...
16295 (download_tracepoint_1): ... here. New.
16296
86a30030
YQ
162972011-11-08 Yao Qi <yao@codesourcery.com>
16298
16299 * remote-utils.c (relocate_instruction): A comment fix.
16300
8d26e50c
JB
163012011-11-07 Joel Brobecker <brobecker@adacore.com>
16302
16303 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): Delete.
16304 (i386_dr_low_get_control, i386_dr_low_get_status): Use
16305 dr_status_mirror and dr_control_mirror from debug_reg_state.
16306 (i386_dr_low_get_status): Use debug_reg_state.dr_status_mirror
16307 (i386_initial_stuff): Remove use of deleted globals.
16308 (i386_get_thread_context, i386_set_thread_context,
16309 i386_thread_added): Use dr_status_mirror and dr_control_mirror
16310 from debug_reg_state.
16311
a59306a3
YQ
163122011-11-05 Yao Qi <yao@codesourcery.com>
16313
16314 * tracepoint.c (gdb_collect): Loop over tracepoints of same
16315 address as TPOINT's.
16316
3065dfb6
SS
163172011-11-02 Stan Shebs <stan@codesourcery.com>
16318
16319 * tracepoint.c (agent_mem_read_string): New function.
16320 (eval_agent_expr): Call it for tracenz.
16321 * server.c (handle_query): Report support for tracenz.
16322
fd0d8c7c
YQ
163232011-11-02 Yao Qi <yao@codesourcery.com>
16324
16325 * tracepoint.c (cmd_qtstart): Remove unused local variables.
16326
609086b1
YQ
163272011-11-02 Yao Qi <yao@codesourcery.com>
16328
16329 * target.h: Fix a typo in comment.
16330
b9fd1791
PA
163312011-10-31 Pedro Alves <pedro@codesourcery.com>
16332
16333 * mem-break.c (check_mem_write): Add `myaddr' parameter. Don't
16334 clobber the breakpoints' shadows with fast tracepoint jumps.
16335 * mem-break.h (check_mem_write): Add `myaddr' parameter.
16336 * target.c (write_inferior_memory): Also pass MYADDR down to
16337 check_mem_write.
16338
03583c20
UW
163392011-10-07 Ulrich Weigand <ulrich.weigand@linaro.org>
16340
16341 * configure.ac: Check support for personality routine.
16342 * configure: Regenerate.
16343 * config.in: Likewise.
16344 * linux-low.c: Include <sys/personality.h>.
16345 Define ADDR_NO_RANDOMIZE if necessary.
16346 (linux_create_inferior): Disable address space randomization when
16347 forking inferior, if requested.
16348 (linux_supports_disable_randomization): New function.
16349 (linux_target_ops): Install it.
16350 * server.h (disable_randomization): Declare.
16351 * server.c (disable_randomization): New global variable.
16352 (handle_general_set): Handle QDisableRandomization.
16353 (handle_query): Likewise for qSupported.
16354 (main): Support --disable-randomization and --no-disable-randomization
16355 command line arguments.
16356 * target.h (struct target_ops): Add supports_disable_randomization.
16357 (target_supports_disable_randomization): New macro.
16358
723b724b
MF
163592011-09-29 Mike Frysinger <vapier@gentoo.org>
16360
16361 * linux-low.c (target_loadseg): Add defined PTRACE_GETFDPIC to the
16362 ifdef check.
16363 [PT_GETDSBT] (target_loadmap): Wrap in a defined PT_GETDSBT check.
16364 [!PT_GETDSBT] (target_loadmap): New definition.
16365 (LINUX_LOADMAP, LINUX_LOADMAP_EXEC, LINUX_LOADMAP_INTERP): Define.
16366 (linux_read_loadmap): Change PTRACE_GETDSBT_EXEC to
16367 LINUX_LOADMAP_EXEC, PTRACE_GETDSBT_INTERP to LINUX_LOADMAP_INTERP,
16368 and PT_GETDSBT to LINUX_LOADMAP.
16369 [!PT_GETDSBT] (linux_read_loadmap): Define to NULL.
16370 (linux_target_ops): Delete unnecessary ifdef PT_GETDSBT check.
16371
55329a5c 163722011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
71487fd7
UW
16373
16374 * linux-arm-low.c (struct arm_linux_hwbp_cap): Remove.
16375 (arm_linux_hwbp_cap): New static variable.
16376 (arm_linux_get_hwbp_cap): Replace by ...
16377 (arm_linux_init_hwbp_cap): ... this new function.
16378 (arm_linux_get_hw_breakpoint_count): Use arm_linux_hwbp_cap.
16379 (arm_linux_get_hw_watchpoint_count): Likewise.
16380 (arm_linux_get_hw_watchpoint_max_length): Likewise.
16381 (arm_arch_setup): Call arm_linux_init_hwbp_cap.
16382 (arm_prepare_to_resume): Use perror_with_name instead of error.
16383
55329a5c 163842011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
09b4ad9f
UW
16385
16386 * linux-arm-low.c: Include <signal.h>.
16387 (PTRACE_GETHBPREGS, PTRACE_SETHBPREGS): Define if necessary.
16388 (struct arm_linux_hwbp_cap): New data type.
16389 (arm_hwbp_type, arm_hwbp_control_t): New typedefs.
16390 (struct arm_linux_hw_breakpoint): New data type.
16391 (MAX_BPTS, MAX_WPTS): Define.
16392 (struct arch_process_info, struct arch_lwp_info): New data types.
16393 (arm_linux_get_hwbp_cap): New function.
16394 (arm_linux_get_hw_breakpoint_count): Likewise.
16395 (arm_linux_get_hw_watchpoint_count): Likewise.
16396 (arm_linux_get_hw_watchpoint_max_length): Likewise.
16397 (arm_hwbp_control_initialize): Likewise.
16398 (arm_hwbp_control_is_enabled): Likewise.
16399 (arm_hwbp_control_is_initialized): Likewise.
16400 (arm_hwbp_control_disable): Likewise.
16401 (arm_linux_hw_breakpoint_equal): Likewise.
16402 (arm_linux_hw_point_initialize): Likewise.
16403 (struct update_registers_data): New data structure.
16404 (update_registers_callback: New function.
16405 (arm_insert_point): Likewise.
16406 (arm_remove_point): Likewise.
16407 (arm_stopped_by_watchpoint): Likewise.
16408 (arm_stopped_data_address): Likewise.
16409 (arm_new_process): Likewise.
16410 (arm_new_thread): Likewise.
16411 (arm_prepare_to_resume): Likewise.
16412 (the_low_target): Register arm_insert_point, arm_remove_point,
16413 arm_stopped_by_watchpoint, arm_stopped_data_address, arm_new_process,
16414 arm_new_thread, and arm_prepare_to_resume.
16415
6b9801d4
SS
164162011-09-15 Stan Shebs <stan@codesourcery.com>
16417
16418 * server.h (struct emit_ops): Add compare-goto fields.
16419 * tracepoint.c (gdb_agent_op_sizes): New table.
16420 (emit_eq_goto): New function.
16421 (emit_ne_goto): New function.
16422 (emit_lt_goto): New function.
16423 (emit_le_goto): New function.
16424 (emit_gt_goto): New function.
16425 (emit_ge_goto): New function.
16426 (is_goto_target): New function.
16427 (compile_bytecodes): Recognize special cases of compare-goto
16428 combinations and call specialized emitters for them.
16429 * linux-x86-low.c (amd64_emit_eq_goto): New function.
16430 (amd64_emit_ne_goto): New function.
16431 (amd64_emit_lt_goto): New function.
16432 (amd64_emit_le_goto): New function.
16433 (amd64_emit_gt_goto): New function.
16434 (amd64_emit_ge_goto): New function.
16435 (amd64_emit_ops): Add the new functions.
16436 (i386_emit_eq_goto): New function.
16437 (i386_emit_ne_goto): New function.
16438 (i386_emit_lt_goto): New function.
16439 (i386_emit_le_goto): New function.
16440 (i386_emit_gt_goto): New function.
16441 (i386_emit_ge_goto): New function.
16442 (i386_emit_ops): Add the new functions.
16443
bf15cbda
SS
164442011-09-08 Stan Shebs <stan@codesourcery.com>
16445
16446 * linux-x86-low.c (i386_emit_prologue): Save %ebx.
16447 (i386_emit_epilogue): Restore %ebx.
16448
943ca1dd
JZ
164492011-08-31 Jie Zhang <jzhang918@gmail.com>
16450
16451 * server.c (step_thread): Remove definition.
16452 (process_serial_event): Don't handle Hs.
16453 * server.h (step_thread): Remove declaration.
16454 * target.c (set_desired_inferior): Remove use of step_thread.
16455
e3deef73
LM
164562011-08-24 Luis Machado <lgustavo@codesourcery.com>
16457
16458 * linux-low.c: Include linux-procfs.h.
16459 (linux_attach_lwp_1): Update comments.
16460 (linux_attach): Scan for existing threads when attaching to a
16461 process that is the tgid.
16462 * Makefile.in: Update dependencies.
16463
13da1c97
LM
164642011-08-24 Luis Machado <lgustavo@codesourcery.com>
16465
16466 * configure.srv: Add linux-procfs.o dependencies.
16467
881127c9
YQ
164682011-08-14 Yao Qi <yao@codesourcery.com>
16469
16470 * target.h (struct target_ops): Fix indent.
16471 * win32-low.c (win32_target_ops): Fix comment.
16472
58dbd541
YQ
164732011-08-14 Andrew Jenner <andrew@codesourcery.com>
16474 Yao Qi <yao@codesourcery.com>
16475
16476 * Makefile.in (clean): Remove tic6x-*.c files.
16477 (linux-tic6x-low.o, tic6x-c62x-linux.o, tic6x-c64x-linux.o): New rules.
16478 (tic6x-c64xp-linux.o, tic6x-c62x-linux.c, tic6x-c64x-linux.c): Likewise.
16479 (tic6x-c64xp-linux.c): Likewise.
16480 * configure.srv: Add support for tic6x-*-uclinux.
16481 * linux-tic6x-low.c: New.
16482 * linux-low.c (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define.
16483
78d85199
YQ
164842011-08-14 Andrew Stubbs <ams@codesourcery.com>
16485 Yao Qi <yao@codesourcery.com>
16486
16487 * target.h (struct target_ops): Add read_loadmap.
16488 * linux-low.c (struct target_loadseg): New type.
16489 (struct target_loadmap): New type.
16490 (linux_read_loadmap): New function.
16491 (linux_target_ops): Add linux_read_loadmap.
16492 * server.c (handle_query): Support qXfer:fdpic:read packet.
43aaf8b6
PA
16493 * win32-low.c (win32_target_ops): Initialize field `read_loadmap'
16494 to NULL.
78d85199 16495
a959a88d
EZ
164962011-08-05 Eli Zaretskii <eliz@gnu.org>
16497
16498 * win32-low.c: Include <stdint.h>.
16499
1ced966e
PA
165002011-07-22 Pedro Alves <pedro@codesourcery.com>
16501
16502 * i386-low.c (i386_insert_aligned_watchpoint): Don't pass the info
16503 to the inferior here.
16504 (i386_remove_aligned_watchpoint): Ditto.
16505 (i386_handle_nonaligned_watchpoint): Return immediate on fail to
16506 fit part of the watchpoint in the debug registers.
16507 (i386_update_inferior_debug_regs): New.
16508 (i386_low_insert_watchpoint): Work on a local mirror of the debug
16509 registers, and only update the inferior on success.
16510 (i386_low_remove_watchpoint): Ditto.
16511
d26e3629
KY
165122011-07-22 Kwok Cheung Yeung <kcy@codesourcery.com>
16513
16514 * linux-low.c (compare_ints, unique, list_threads, show_process,
16515 linux_core_of_thread): Delete.
16516 (linux_target_ops): Change linux_core_of_thread to
16517 linux_common_core_of_thread.
16518 (linux_qxfer_osdata): Defer to linux_common_xfer_osdata.
16519 * utils.c (malloc_failure): Change type of argument.
16520 (xmalloc, xrealloc, xcalloc, xsnprintf): Delete.
16521 * Makefile.in (SFILES): Add common/common-utils.c, common/xml-utils.c,
16522 common/linux-osdata.c, common/ptid.c and common/buffer.c.
16523 (OBS): Add xml-utils.o, common-utils.o, ptid.o and buffer.o.
16524 (IPA_OBJS): Add common-utils-ipa.o.
16525 (ptid_h, linux_osdata_h): New macros.
16526 (server_h): Add common/common-utils.h, common/xml-utils.h,
16527 common/buffer.h, common/gdb_assert.h, common/gdb_locale.h and
16528 common/ptid.h.
16529 (common-utils-ipa.o, common-utils.o, xml-utils.o, linux-osdata.o,
16530 ptid.o, buffer.o): New rules.
16531 (linux-low.o): Add common/linux-osdata.h as a dependency.
16532 * configure.srv (srv_tgtobj): Add linux-osdata.o to Linux targets.
16533 * configure.ac: Add AC_HEADER_DIRENT check.
16534 * config.in: Regenerate.
16535 * configure: Regenerate.
16536 * remote-utils.c (xml_escape_text): Delete.
16537 (buffer_grow, buffer_free, buffer_init, buffer_finish,
16538 buffer_xml_printf): Move to common/buffer.c.
16539 * server.c (main): Remove call to initialize_inferiors.
16540 * server.h (struct ptid, ptid_t, minus_one_ptid, null_ptid,
16541 ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp, ptid_get_tid,
16542 ptid_equal, ptid_is_pid, initialize_inferiors, xml_escape_text,
16543 internal_error, gdb_assert, gdb_assert_fail): Delete.
16544 (struct buffer, buffer_grow, buffer_free, buffer_init, buffer_finish,
16545 buffer_xml_printf, buffer_grow_str, buffer_grow_str0): Move to
16546 common/buffer.h.
16547 * inferiors.c (null_ptid, minus_one_ptid, ptid_build, pid_to_ptid,
16548 ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal, ptid_is_pid,
16549 initialize_inferiors): Delete.
16550
2275a1a7
PA
165512011-07-20 Pedro Alves <pedro@codesourcery.com>
16552
16553 * tracepoint.c (tracepoint_look_up_symbols): Return upon the first
16554 symbol error.
16555
0a5b1e09
PA
165562011-05-31 Pedro Alves <pedro@codesourcery.com>
16557
16558 * linux-x86-low.c (i386_dr_low_get_addr): Fix off by one in
16559 assertion.
16560 * win32-i386-low.c (i386_dr_low_get_addr): Ditto.
16561
6938fd34
YQ
165622011-05-26 Yao Qi <yao@codesourcery.com>
16563
16564 * Makefile.in (thread-db.o): Track dependence to
16565 common/gdb_thread_db.h.
16566 * thread-db.c: include gdb_thread_db.h from right place.
16567
b481f9e0
TT
165682011-05-16 Adrian Cornish <gnu@bluedreamer.com>
16569
16570 * linux-i386-ipa.c (supply_static_tracepoint_registers): Pass
16571 __FILE__ and __LINE__ to internal_error.
16572
98a5dd13
DE
165732011-05-13 Doug Evans <dje@google.com>
16574
16575 * thread-db.c (try_thread_db_load_from_sdir): New function.
16576 (try_thread_db_load_from_dir): New function.
16577 (thread_db_load_search): Handle $sdir, ignore $pdir.
16578 Remove trying of system directories if search of
16579 libthread-db-search-path fails, that is now done via $sdir.
16580
d248b706
KY
165812011-05-12 Kwok Cheung Yeung <kcy@codesourcery.com>
16582
16583 * server.c (handle_query): Add EnableDisableTracepoints to the list
16584 of supported features.
43aaf8b6 16585 * tracepoint.c (clear_installed_tracepoints): Uninstall disabled
d248b706 16586 tracepoints.
43aaf8b6
PA
16587 (cmd_qtenable_disable): New.
16588 (cmd_qtstart): Install tracepoints even if disabled.
16589 (handle_tracepoint_general_set): Add call to cmd_qtenable_disable on
16590 receiving a QTEnable or QTDisable packet.
16591 (gdb_collect): Skip data collection if fast tracepoint is disabled.
16592 (ust_marker_to_static_tracepoint): Do not ignore disabled static
16593 tracepoints.
16594 (gdb_probe): Skip data collection if static tracepoint is disabled.
d248b706 16595
84e578fb
DE
165962011-05-10 Doug Evans <dje@google.com>
16597
16598 * thread-db.c (thread_db_handle_monitor_command): Handle elided path.
16599
71f55dd8
DE
166002011-05-04 Doug Evans <dje@google.com>
16601
16602 * linux-low.c (linux_join): Skip process lookup.
16603 * spu-low.c (spu_join): Ditto.
16604 * server.c (join_inferiors_callback): Delete.
16605 (process_serial_event): For 'D' packet (detach) call join_inferior
16606 directly.
16607
4d393d60
JM
166082011-05-04 Joseph Myers <joseph@codesourcery.com>
16609
16610 * README: Don't mention xscale*-*-linux*.
16611 * configure.srv (xscale*-*-linux*): Don't handle target.
16612
b00ad6ff
NF
166132011-04-27 Nathan Froyd <froydnj@codesourcery.com>
16614
16615 * linux-x86-low.c (amd64_emit_const): Call memcpy instead of
16616 casting pointers.
16617 (amd64_emit_reg, amd64_emit_int_call_1, amd64_emit_void_call_2):
16618 (i386_emit_const, i386_emit_reg, i386_emit_int_call_1):
16619 (i386_emit_void_call_2): Likewise.
16620
af96c192
YQ
166212011-04-26 Yao Qi <yao@codesourcery.com>
16622
43aaf8b6
PA
16623 * linux-low.c: Move common macros to linux-ptrace.h.
16624 Include linux-ptrace.h.
af96c192
YQ
16625 * Makefile.in (linux_ptrace_h): New.
16626 (linux-low.o): Depends on linux-ptrace.h.
16627
03f2bd59
JK
166282011-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
16629
16630 * remote-utils.c (handle_accept_event): Close LISTEN_DESC only if
16631 RUN_ONCE. Comment for the LISTEN_DESC delete_file_handler call.
16632 (remote_prepare): New function with most of the TCP code from ...
16633 (remote_open): ... here. Detect PORT here unconditionally. Move also
16634 setting transport_is_reliable.
16635 * server.c (run_once): New variable.
16636 (gdbserver_usage): Document it.
16637 (main): Set run_once for `--once'. Call remote_prepare. Exit after
16638 the first run if RUN_ONCE.
16639 * server.h (run_once, remote_prepare): New declarations.
16640
7a9dd1b2
TT
166412011-04-19 Tom Tromey <tromey@redhat.com>
16642
16643 * win32-low.c (handle_load_dll): Remove duplicate "the".
16644
81239425
PM
166452011-04-07 Pierre Muller <muller@ics.u-strasbg.fr>
16646
16647 Remove support for old Cygwin 1.5 versions.
16648 * win32-low.c (win32_create_inferior): Use new cygwin_path_list
16649 function to avoid warning.
16650 (win32_add_one_solib): Use cygwin_conv_path function to avoid
16651 warning.
16652
9e0627f1
PM
166532011-03-18 Pierre Muller <muller@ics.u-strasbg.fr>
16654
16655 * gdbserver/server.h (Macro _): Define it if not available.
16656
588eebee
MS
166572011-03-14 Michael Snyder <msnyder@vmware.com>
16658
348af9f7 16659 * hostio.c (handle_close): Remove unnecessary null test.
588eebee 16660
43f70d4c
JB
166612011-03-10 Joel Brobecker <brobecker@adacore.com>
16662
16663 * Makefile.in (maintainer-clean realclean distclean): Remove
16664 "make ... subdir_do" command.
16665
348af9f7
MS
166662011-03-10 Michael Snyder <msnyder@vmware.com>
16667
16668 * tracepoint.c (tracepoint_finish_step): Fix loop variable.
16669
16670 * server.c (handle_v_run): Free alloced buffer on early return.
16671
e637a4f5
YQ
166722011-03-09 Yao Qi <yao@codesourcery.com>
16673
16674 Revert:
16675 2011-03-04 Yao Qi <yao@codesourcery.com>
16676
16677 * Makefile.in: Remove GNU make feature --directory.
16678
16679 2011-03-05 Yao Qi <yao@codesourcery.com>
16680
16681 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
16682 (subdir_do): New make target. Copied from gdb/Makefile.
16683 (maintainer-clean, realclean, distclean, clean): Call corresponding
16684 make targets in common/Makefile.
16685
16686 2011-02-11 Yao Qi <yao@codesourcery.com>
16687
16688 * configure.ac: Call AC_PROG_RANLIB.
16689 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
16690 * configure: Regenerate.
16691
e6edda56
JK
166922011-03-07 Jan Kratochvil <jan.kratochvil@redhat.com>
16693
16694 * remote-utils.c (putpkt_binary_1): Calculate BUF2 size dynamically.
16695
e5141119
JB
166962011-03-06 Yao Qi <yao@codesourcery.com>
16697
16698 * Makefile.in (REQUIRED_SUBDIRS): Remove $(LIBCOMMON_DIR).
16699
64794aa4
JB
167002011-03-05 Yao Qi <yao@codesourcery.com>
16701
16702 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
16703 (subdir_do): New make target. Copied from gdb/Makefile.
16704 (maintainer-clean, realclean, distclean, clean): Call corresponding
16705 make targets in common/Makefile.
16706
7a762829
YQ
167072011-03-04 Yao Qi <yao@codesourcery.com>
16708
16709 * Makefile.in: Remove GNU make feature --directory.
16710
348af9f7
MS
167112011-03-04 Michael Snyder <msnyder@vmware.com>
16712
16713 * server.c (queue_stop_reply): Call xmalloc not malloc.
16714
167152011-03-02 Michael Snyder <msnyder@vmware.com>
16716
16717 * linux-arm-low.c (arm_arch_setup): Replace malloc with xmalloc.
16718
9f72fee2
MS
167192011-02-28 Michael Snyder <msnyder@vmware.com>
16720
588eebee
MS
16721 * tracepoint.c (cmd_qtv): Discard unused value 'packet'.
16722 (cmd_qtframe): Ditto.
16723 (cmd_qtbuffer): Ditto.
16724 (cmd_bigqtbuffer): Ditto.
16725
9f72fee2
MS
16726 * utils.c (decimal2str): Initialize 'width' to nine, then
16727 don't mess with it.
16728
8040bd49
UW
167292011-02-28 Ulrich Weigand <uweigand@de.ibm.com>
16730
16731 * hostio.c (require_data): Free *data, not data.
16732
7e52cbd0
JK
167332011-02-28 Jan Kratochvil <jan.kratochvil@redhat.com>
16734
16735 * hostio.c (require_data): Use free, not xfree.
16736
9130f83e
MS
167372011-02-27 Michael Snyder <msnyder@vmware.com>
16738
4b812f4e
MS
16739 * server.c (handle_query): Discard unused value.
16740
9130f83e
MS
16741 * hostio.c (require_data): Free malloc memory before returning
16742 error.
16743
69d37113
MS
167442011-02-26 Michael Snyder <msnyder@vmware.com>
16745
16746 * linux-low.c (list_threads): Call closedir for dirent.
16747
35f5825a
MS
167482011-02-27 Michael Snyder <msnyder@vmware.com>
16749
2a589cef
MS
16750 * i386-low.c (i386-length_and_rw_bits): Comment the fact that
16751 a case statement falls through.
16752
0adea5f7
MS
16753 * linux-low.c (linux_xfer_siginfo): Fix fencepost error.
16754
35f5825a
MS
16755 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Fix fencepost error
16756 in comparison.
16757
238f1c74
MS
167582011-02-26 Michael Snyder <msnyder@vmware.com>
16759
16760 * utils.c (decimal2str): Eliminate dead code and dead param.
16761 (pulongest): Drop dead param from call to decimal2str.
16762 (plongest): Ditto.
16763
633ff500
JB
167642011-02-24 Joel Brobecker <brobecker@adacore.com>
16765
16766 Revert the following patch (not approved yet):
16767 2011-02-21 Hui Zhu <teawater@gmail.com>
16768 * tracepoint.c (tp_printf): New function.
16769 (eval_agent_expr): Handle gdb_agent_op_printf.
16770
f9c6ff72
HZ
167712011-02-21 Hui Zhu <teawater@gmail.com>
16772
16773 * tracepoint.c (tp_printf): New function.
16774 (eval_agent_expr): Handle gdb_agent_op_printf.
16775
94d5e490
TT
167762011-02-18 Tom Tromey <tromey@redhat.com>
16777
16778 * Makefile.in (tracepoint-ipa.o): Depend on ax.def.
16779 (tracepoint.o): Likewise.
16780 * tracepoint.c (enum gdb_agent_op): Use ax.def.
16781 (gdb_agent_op_names): Likewise.
16782
c7f96d2b
TT
167832011-02-18 Tom Tromey <tromey@redhat.com>
16784
16785 * tracepoint.c (enum gdb_agent_op) <gdb_agent_op_pick,
16786 gdb_agent_op_rot>: New constants.
16787 (gdb_agent_op_names): Add pick and roll.
16788 (eval_agent_expr) <gdb_agent_op_pick, gdb_agent_op_rot>: New
16789 cases.
16790
0feedb2c
JK
167912011-02-15 Jan Kratochvil <jan.kratochvil@redhat.com>
16792
16793 * aclocal.m4: Regenerated with aclocal-1.11.1.
16794
b3b9301e
PA
167952011-02-14 Pedro Alves <pedro@codesourcery.com>
16796
16797 * server.c (handle_qxfer_traceframe_info): New.
16798 (qxfer_packets): Register "traceframe-info".
16799 (handle_query): Report support for qXfer:traceframe-info:read+.
16800 * tracepoint.c (match_blocktype): New.
16801 (traceframe_find_block_type): Rename to ...
16802 (traceframe_walk_blocks): ... this. Add callback filter argument,
16803 and use it.
16804 (traceframe_find_block_type): New, reimplemented on top of
16805 traceframe_walk_blocks.
16806 (build_traceframe_info_xml): New.
16807 (traceframe_read_info): New.
16808 * server.h (traceframe_read_info): Declare.
16809
4f3e6fb7
YQ
168102011-02-11 Yao Qi <yao@codesourcery.com>
16811
16812 * configure.ac: Call AC_PROG_RANLIB.
16813 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
16814 * configure: Regenerate.
16815
764880b7
PA
168162011-02-07 Pedro Alves <pedro@codesourcery.com>
16817
16818 * server.c (gdb_read_memory): Change return semantics to allow
16819 partial transfers.
16820 (handle_search_memory_1): Adjust.
16821 (process_serial_event) <'m' packet>: Handle partial transfers.
16822 * tracepoint.c (traceframe_read_mem): Handle partial transfers.
16823
1c79eb8a
PA
168242011-01-28 Pedro Alves <pedro@codesourcery.com>
16825
16826 * regcache.c (init_register_cache): Initialize
16827 regcache->register_status.
16828 (free_register_cache): Release regcache->register_status.
16829 (regcache_cpy): Copy register_status.
16830 (registers_to_string): Print 'x's for unavailable registers.
16831 (supply_register): Mark the register's status valid or
16832 unavailable, depending on whether a buffer was passed in or not.
16833 (supply_register_zeroed): New.
16834 (supply_regblock): Mark the registers' status valid or
16835 unavailable, depending on whether a buffer was passed in or not.
16836 * regcache.h (REG_UNAVAILABLE, REG_VALID): New defines.
16837 (struct regcache): New `register_status' field.
16838 (supply_register_zeroed): Declare.
16839 * i387-fp.c (i387_xsave_to_cache): Zero out registers using
16840 supply_register_zeroed, rather than passing a NULL buffer to
16841 supply_register.
16842 * tracepoint.c (fetch_traceframe_registers): Update comment.
16843
85724a0e
PA
168442011-01-28 Pedro Alves <pedro@codesourcery.com>
16845
16846 * i387-fp.c (i387_xsave_to_cache): Make passing NULL as register
16847 buffer explicit.
16848
d08aafef
PA
168492011-01-25 Pedro Alves <pedro@codesourcery.com>
16850
16851 * server.h (decode_xfer_write): Change prototype.
16852 * remote-utils.c (decode_xfer_write): Remove `annex' parameter,
16853 and don't extract the annex here.
16854 * server.c (decode_xfer_read): Remove `annex' parameter,
16855 and don't extract the annex here.
16856 (decode_xfer): New.
16857 (struct qxfer): New.
16858 (handle_qxfer_auxv, handle_qxfer_features, handle_qxfer_libraries)
16859 (handle_qxfer_osdata, handle_qxfer_siginfo, handle_qxfer_spu)
16860 (handle_qxfer_statictrace): New functions, abstracted out from
16861 handle_query, and made to use the struct qxfer interface.
16862 (handle_threads_qxfer_proper): Rename to ...
16863 (handle_qxfer_threads_proper): ... this.
16864 (handle_threads_qxfer): Rename to ...
16865 (handle_qxfer_threads): ... this. Adjust.
16866 (qxfer_packets): New array.
16867 (handle_qxfer): New function.
16868 (handle_query): Use handle_qxfer.
16869
493e2a69
MS
168702011-01-05 Michael Snyder <msnyder@msnyder-server.eng.vmware.com>
16871
16872 * gdbreplay.c: Shorten lines of >= 80 columns.
16873 * linux-low.c: Ditto.
16874 * linux-ppc-low.c: Ditto.
16875 * linux-s390-low.c: Ditto.
16876 * linux-sparc-low.c: Ditto.
16877 * linux-x86-low.c: Ditto.
16878 * linux-xtensa-low.c: Ditto.
16879 * mem-break.c: Ditto.
16880 * nto-low.c: Ditto.
16881 * regcache.h: Ditto.
16882 * remote-utils.c: Ditto.
16883 * server.c: Ditto.
16884 * server.h: Ditto.
16885 * thread-db.c: Ditto.
16886 * tracepoint.c: Ditto.
16887 * utils.c: Ditto.
16888 * win32-low.h: Ditto.
16889
44944448
JB
168902011-01-05 Joel Brobecker <brobecker@adacore.com>
16891
16892 * gdbserver/configure.ac, gdbserver/gdbserver.1: Copyright year
16893 update.
16894
71ce852c
JB
168952011-01-01 Joel Brobecker <brobecker@adacore.com>
16896
16897 * server.c (gdbserver_version): Update copyright year in version
16898 output.
16899 * gdbreplay.c (gdbreplay_version): Ditto.
16900
eb826dc6
MF
169012010-12-29 Jie Zhang <jie.zhang@analog.com>
16902
16903 * configure.srv (bfin-*-*linux*): Handle Blackfin/Linux targets.
16904 * linux-bfin-low.c: New file.
16905 * linux-low.c: Define PT_TEXT_ADDR, PT_TEXT_END_ADDR, and
16906 PT_DATA_ADDR for BFIN targets.
16907 * Makefile.in (SFILES): Add linux-bfin-low.c.
16908 (clean): Remove reg-bfin.c.
16909 (linux-bfin-low.o, reg-bfin.o, reg-bfin.c): New targets.
16910 * README: Mention supported Blackfin targets.
16911
39ab222a
MF
169122010-12-23 Mike Frysinger <vapier@gentoo.org>
16913
16914 * .gitignore: New file.
16915
a1f2ce7d
MF
169162010-11-16 Mike Frysinger <vapier@gentoo.org>
16917
16918 * linux-low.c (linux_tracefork_child): Add char* cast to arg.
16919
f474844c
JZ
169202010-10-22 Jie Zhang <jie@codesourcery.com>
16921
16922 * Makefile.in: Add FLAGS_TO_PASS variable.
16923 (install): Remove dependency of install-only and recursively
16924 invoke make for install-only.
16925
f1048712
DE
169262010-10-04 Doug Evans <dje@google.com>
16927
16928 * Makefile.in (uninstall): Use $(DESTDIR).
16929
b53a1623
PA
169302010-09-24 Pedro Alves <pedro@codesourcery.com>
16931
e6ee044d
PA
16932 PR gdb/11842
16933
b53a1623
PA
16934 * linux-x86-low.c (compat_siginfo_from_siginfo)
16935 (siginfo_from_compat_siginfo): Also copy si_pid and si_uid when
16936 si_code is < 0. Check for si_code == SI_TIMER before checking for
16937 si_code < 0.
16938
fa1bd1e4
JB
169392010-09-13 Joel Brobecker <brobecker@adacore.com>
16940
16941 * lynx-i386-low.c: New file.
16942 * configure.srv: Add handling of i[34567]86-*-lynxos* targets.
16943
47fac8f8
JB
169442010-09-13 Joel Brobecker <brobecker@adacore.com>
16945
16946 * lynx-low.c (ptrace_request_to_str): Remove handling for
16947 request values that have been removed in LynxOS 5.x.
16948
1adfc54d
JB
169492010-09-13 Joel Brobecker <brobecker@adacore.com>
16950
16951 * lynx-low.c, lynx-ppc-loc.c: Include <sys/ptrace.h> instead of
16952 <ptrace.h>
16953
c2a66c29
NS
169542010-09-09 Nathan Sidwell <nathan@codesourcery.com>
16955
16956 * configure.ac: Add --enable-inprocess-agent option.
16957 * configure: Rebuilt.
16958
32fcada3
YQ
169592010-09-06 Yao Qi <yao@codesourcery.com>
16960
16961 * linux-low.c (linux_kill): Remove unused variable.
16962 (linux_stabilize_threads): Likewise.
16963 * server.c (start_inferior): Likewise.
16964 (queue_stop_reply_callback): Likewise.
16965 * tracepoint.c (do_action_at_tracepoint): Likewise.
16966
0cccb683
YQ
169672010-09-06 Yao Qi <yao@codesourcery.com>
16968
16969 * linux-low.c (maybe_move_out_of_jump_pad): Restore current_inferior
16970 on return.
16971
423ec54c
JK
169722010-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
16973
16974 * target.c (mywait) <TARGET_WAITKIND_EXITED>: Fix to use INTEGER.
16975
12ac6819
PA
169762010-09-06 Pedro Alves <pedro@codesourcery.com>
16977
16978 * Makefile.in (install-only): Replace $IPA_DEPFILES with
16979 "$(IPA_DEPFILES)".
16980
8ed54b31
JB
169812010-09-01 Joel Brobecker <brobecker@adacore.com>
16982
16983 * gdbserver/lynx-low.c, gdbserver/lynx-low.h,
16984 gdbserver/lynx-ppc-low.c: New files.
16985 * Makefile.in (lynx_low_h): New variable.
16986 (lynx-low.o, lynx-ppc-low.o): New rules.
16987 * configure.ac: On LynxOS, link with -lnetinet.
16988 * configure.srv: Add handling of powerpc-*-lynxos* targets.
16989 * configure: regenerate.
16990
bb0116a4
JB
169912010-09-01 Joel Brobecker <brobecker@adacore.com>
16992
16993 * Makefile.in (vasprintf.o, vsnprintf.o): New rules.
16994 * configure.ac: Add check for vasprintf and vsnprintf.
16995 * configure, config.in: Regenerate.
16996 * server.h (vasprintf, vsnprintf): Add conditional declarations.
16997
a778ab81 169982010-09-01 Joel Brobecker <brobecker@adacore.com>
16999
17000 * gdbreplay.c: Move include of alloca.h up, next to include of
17001 malloc.h.
17002 * server.h: Add include of malloc.h.
17003 * mem-break.c: Remove include of malloc.h.
17004 * server.c, tracepoint.c, utils.c, win32-low.c: Likewise.
17005
8b034a19 170062010-09-01 Joel Brobecker <brobecker@adacore.com>
17007
17008 * Makefile.in (memmem.o): Build with -Wno-error.
17009
170102010-09-01 Joel Brobecker <brobecker@adacore.com>
17011
17012 * utils.c (xsnprintf): Make non-static.
17013 * server.h: Add xsnprintf declaration.
17014 * linux-low.c, nto-low.c, target.c, thread-db.c, tracepoint.c:
17015 replace calls to snprintf by calls to xsnprintf throughout.
17016
170172010-09-01 Joel Brobecker <brobecker@adacore.com>
17018
17019 * configure.ac: Add configure check for alloca.
17020 * configure, config.in: Regenerate.
17021 * server.h: Include alloca.h if it exists.
17022 * gdbreplay.c: Include alloca.h if it exists.
17023
1a981360
PA
170242010-08-28 Pedro Alves <pedro@codesourcery.com>
17025
17026 * linux-low.c (__SIGRTMIN): Define if not already defined.
17027 (linux_create_inferior): Check for __ANDROID__ rather than
17028 __SIGRTMIN.
17029 (enqueue_one_deferred_signal): Don't requeue non-RT signals that
17030 are already deferred.
17031 (linux_wait_1): Check for __ANDROID__ rather than __SIGRTMIN.
17032 (linux_resume_one_thread): Don't queue a SIGSTOP if the lwp is
17033 stopped and already has a pending signal to report.
17034 (proceed_one_lwp): : Don't queue a SIGSTOP if the lwp already has
17035 a pending signal to report or is moving out of a jump pad.
17036 (linux_init_signals): Check for __ANDROID__ rather than
17037 __SIGRTMIN.
17038
b4d51a55
PA
170392010-08-28 Pedro Alves <pedro@codesourcery.com>
17040
17041 * linux-low.c (linux_stabilize_threads): Wrap debug output in a
17042 debug_threads check. Avoid a linear search when not doing debug
17043 output.
17044
ec48365d
PA
170452010-08-27 Pedro Alves <pedro@codesourcery.com>
17046
17047 * event-loop.c (event_handle_func): Adjust to use gdb_fildes_t.
17048 (struct gdb_event) <fd>: Change type to gdb_fildes_t.
17049 (struct file_handler) <fd>: Change type to gdb_fildes_t.
17050 (process_event): Change local fd's type to gdb_fildes_t.
17051 (create_file_handler): Adjust prototype.
17052 (delete_file_handler): Adjust prototype.
17053 (handle_file_event): Adjust prototype. Use pfildes.
17054 (create_file_event): Adjsut prototype.
17055 * remote-utils.c (remote_desc, listen_desc): Change type to
17056 gdb_fildes_t.
17057 * server.h: New gdb_fildes_t typedef.
17058 [USE_WIN32API]: Include winsock2.h.
17059 (delete_file_handler, add_file_handler): Adjust prototypes.
17060 (pfildes): Declare.
17061 * utils.c (pfildes): New.
17062
854d88f0
PA
170632010-08-27 Pedro Alves <pedro@codesourcery.com>
17064
17065 * configure.ac (build_warnings): Add -Wno-char-subscripts.
17066 * configure: Regenerate.
17067
0146f85b
PA
170682010-08-27 Pedro Alves <pedro@codesourcery.com>
17069
17070 * linux-low.c (linux_unprepare_to_access_memory): Rename to ...
17071 (linux_done_accessing_memory): ... this.
17072 (linux_target_ops): Adjust.
17073 * linux-x86-low.c (x86_insert_point, x86_remove_point): Adjust.
17074 * nto-low.c (nto_target_ops): Adjust comment.
17075 * server.c (gdb_read_memory, gdb_write_memory): Adjust.
17076 * spu-low.c (spu_target_ops): Adjust comment.
17077 * target.h (target_ops): Rename unprepare_to_access_memory field
17078 to done_accessing_memory.
17079 (unprepare_to_access_memory): Rename to ...
17080 (done_accessing_memory): ... this.
17081
90d74c30
PA
170822010-08-26 Pedro Alves <pedro@codesourcery.com>
17083
17084 * linux-low.c (linux_prepare_to_access_memory): New.
17085 (linux_unprepare_to_access_memory): New.
17086 (linux_target_ops): Install them.
17087 * server.c (read_memory): Rename to ...
17088 (gdb_read_memory): ... this. Use
17089 prepare_to_access_memory/prepare_to_access_memory.
17090 (write_memory): Rename to ...
17091 (gdb_write_memory): ... this. Use
17092 prepare_to_access_memory/prepare_to_access_memory.
17093 (handle_search_memory_1): Adjust.
17094 (process_serial_event): Adjust.
17095 * target.h (struct target_ops): New fields
17096 prepare_to_access_memory and unprepare_to_access_memory.
17097 (prepare_to_access_memory, unprepare_to_access_memory): New.
17098 * linux-x86-low.c (x86_insert_point, x86_remove_point): Use
17099 prepare_to_access_memory/prepare_to_access_memory.
17100 * nto-low.c (nto_target_ops): Adjust.
17101 * spu-low.c (spu_target_ops): Adjust.
17102 * win32-low.c (win32_target_ops): Adjust.
17103
fd467969
PA
171042010-08-26 Pedro Alves <pedro@codesourcery.com>
17105
17106 * Makefile.in (WARN_CFLAGS): Get it from configure.
17107 (WERROR_CFLAGS): New.
17108 (INTERNAL_CFLAGS): Add WERROR_CFLAGS.
17109 * configure.ac: Introduce --enable-werror, which adds -Werror to
17110 the compiler command line. Enabled by default. Disable with
17111 --disable-werror. Add -Wdeclaration-after-statement
17112 Wpointer-arith and -Wformat-nonliteral to warning flags.
17113 * configure: Regenerate.
17114
331e2f5f
PA
171152010-08-26 Pedro Alves <pedro@codesourcery.com>
17116
17117 * mem-break.c [HAVE_MALLOC_H]: Include malloc.h.
17118
e581f2b4
PA
171192010-08-26 Pedro Alves <pedro@codesourcery.com>
17120
17121 * gdbreplay.c (remote_error): New.
17122 (gdbchar): New.
17123 (expect): Use gdbchar. Check for error reading from GDB.
17124 Clarify sync error output.
17125 (play): Check for errors writing to GDB.
17126 * linux-low.c (sigchld_handler): Really ignore `write' errors.
17127 * remote-utils.c (getpkt): Check for errors writing to the remote
17128 descriptor.
17129
3c11dd79
PA
171302010-08-25 Pedro Alves <pedro@codesourcery.com>
17131
17132 * linux-low.c (linux_wait_1): Move non-debugging code out of
17133 `debug_threads' control.
17134
d20a8ad9
PA
171352010-08-25 Pedro Alves <pedro@codesourcery.com>
17136
17137 * linux-low.c (linux_wait_1): Don't set last_status here.
17138 * server.c (push_event, queue_stop_reply_callback): Assert we're
17139 not pushing a TARGET_WAITKIND_IGNORE event.
17140 (start_inferior, start_inferior, attach_inferior, handle_v_cont)
17141 (myresume, handle_target_event): Set the thread's last_resume_kind
17142 and last_status from the target returned status.
17143
964e4306
PA
171442010-08-25 Pedro Alves <pedro@codesourcery.com>
17145
17146 PR threads/10729
17147
17148 * linux-x86-low.c (update_debug_registers_callback): New.
17149 (i386_dr_low_set_addr): Use it.
17150 (i386_dr_low_get_addr): New.
17151 (i386_dr_low_set_control): Use update_debug_registers_callback.
17152 (i386_dr_low_get_control): New.
17153 (i386_dr_low_get_status): Adjust.
17154 * linux-low.c (linux_stop_lwp): New.
17155 * linux-low.h (linux_stop_lwp): Declare.
17156
17157 * i386-low.c (I386_DR_GET_RW_LEN): Take the dr7 contents as
17158 argument instead of a i386_debug_reg_state.
17159 (I386_DR_WATCH_HIT): Take the dr6 contents as argument instead of
17160 a i386_debug_reg_state.
17161 (i386_insert_aligned_watchpoint): Adjust.
17162 (i386_remove_aligned_watchpoint): Adjust.
17163 (i386_low_stopped_data_address): Read the debug registers from the
17164 inferior instead of from the mirrors.
17165 * i386-low.h (struct i386_debug_reg_state): Extend comment.
17166 (i386_dr_low_get_addr): Declare.
17167 (i386_dr_low_get_control): Declare.
17168 (i386_dr_low_get_status): Change prototype.
17169
17170 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): New globals.
17171 (i386_dr_low_get_addr): New.
17172 (i386_dr_low_get_control): New.
17173 (i386_dr_low_get_status): Adjust prototype. Return
17174 dr_status_mirror.
17175 (i386_initial_stuff): Clear dr_status_mirror and
17176 dr_control_mirror.
17177 (i386_get_thread_context): Adjust.
17178 (i386_set_thread_context): Adjust.
17179 (i386_thread_added): Adjust.
17180
5f21a75b
PA
171812010-08-24 Pedro Alves <pedro@codesourcery.com>
17182
17183 * linux-low.h (linux_thread_area): Delete declaration.
17184
3e4c1235
TS
171852010-08-11 Thomas Schwinge <thomas@codesourcery.com>
17186
17187 * linux-low.c (linux_wait_1): Correctly return the ptid of the child
17188 after its termination.
17189
1971b033
PA
171902010-08-09 Pedro Alves <pedro@codesourcery.com>
17191
17192 * linux-low.c (gdb_wants_lwp_stopped): Delete.
17193 (gdb_wants_all_stopped): Delete.
17194 (linux_wait_1): Don't call them.
17195 * server.c (handle_v_cont): Tag all threads as want-stopped.
17196 (gdb_wants_thread_stopped): Fix comments. Tag the thread that
17197 stopped as "client-wants-stopped".
17198
310444ac
PA
171992010-07-31 Pedro Alves <pedro@codesourcery.com>
17200
17201 * Makefile.in (signals_h): New.
17202 (server_h): Depend on it.
17203 (server.o): Don't depend on $(signals_def).
17204 (signals.o): Depend on $(signals_def).
17205
a19cae16
JK
172062010-07-31 Jan Kratochvil <jan.kratochvil@redhat.com>
17207
17208 * Makefile.in (signals_def): New.
17209 (server_h): Append include/gdb/signals.h and signals_def.
17210 (server.o): Append signals_def.
17211
30d50328
JK
172122010-07-25 Jan Kratochvil <jan.kratochvil@redhat.com>
17213
17214 * server.c (handle_target_event): Use target_signal_to_host for
17215 resume_info.sig initialization.
17216 * target.h (struct thread_resume) <sig>: New comment.
17217
5c3216e2
OS
172182010-07-20 Ozkan Sezer <sezeroz@gmail.com>
17219
c6f46ca0
OS
17220 * server.c (handle_query): strcpy() the returned string from paddress()
17221 instead of sprintf().
5c3216e2
OS
17222 * utils.c (paddress): Return phex_nz().
17223
6bd31874
JB
172242010-07-07 Joel Brobecker <brobecker@adacore.com>
17225
17226 * server.c (handle_v_cont): Call mourn_inferior if process
17227 just exited.
17228 (myresume): Likewise.
17229
0fb4aa4b
PA
172302010-07-01 Pedro Alves <pedro@codesourcery.com>
17231
17232 Static tracepoints, and integration with UST.
17233
17234 * configure.ac: Handle --with-ust. substitute ustlibs and ustinc.
17235 * mem-break.c (uninsert_all_breakpoints)
17236 (reinsert_all_breakpoints): New.
17237 * mem-break.h (reinsert_all_breakpoints, uninsert_all_breakpoints):
17238 * tracepoint.c (ust_loaded, helper_thread_id, cmd_buf): New.
17239 (gdb_agent_ust_loaded, helper_thread_id)
17240 (gdb_agent_helper_thread_id): New macros.
17241 (struct ipa_sym_addresses): Add addr_ust_loaded,
17242 addr_helper_thread_id, addr_cmd_buf.
17243 (symbol_list): Add ust_loaded, helper_thread_id, cmd_buf.
17244 (in_process_agent_loaded_ust): New.
17245 (write_e_ust_not_loaded): New.
17246 (maybe_write_ipa_ust_not_loaded): New.
17247 (struct collect_static_trace_data_action): New.
17248 (enum tracepoint_type) <static_tracepoint>: New.
17249 (struct tracepoint) <handle>: Mention static tracepoints.
17250 (struct static_tracepoint_ctx): New.
17251 (CMD_BUF_SIZE): New.
17252 (add_tracepoint_action): Handle static tracepoint actions.
17253 (unprobe_marker_at): New.
17254 (clear_installed_tracepoints): Handle static tracepoints.
17255 (cmd_qtdp): Handle static tracepoints.
17256 (probe_marker_at): New.
17257 (cmd_qtstart): Handle static tracepoints.
17258 (response_tracepoint): Handle static tracepoints.
17259 (cmd_qtfstm, cmd_qtsstm, cmd_qtstmat): New.
17260 (handle_tracepoint_query): Handle qTfSTM, qTsSTM and qTSTMat.
17261 (get_context_regcache): Handle static tracepoints.
17262 (do_action_at_tracepoint): Handle static tracepoint actions.
17263 (traceframe_find_block_type): Handle static trace data blocks.
17264 (traceframe_read_sdata): New.
17265 (download_tracepoints): Download static tracepoint actions.
17266 [HAVE_UST] Include ust/ust.h, dlfcn.h, sys/socket.h, and sys/un.h.
17267 (GDB_PROBE_NAME): New.
17268 (ust_ops): New.
17269 (GET_UST_SYM): New.
17270 (USTF): New.
17271 (dlsym_ust): New.
17272 (ust_marker_to_static_tracepoint): New.
17273 (gdb_probe): New.
17274 (collect_ust_data_at_tracepoint): New.
17275 (gdb_ust_probe): New.
17276 (UNIX_PATH_MAX, SOCK_DIR): New.
17277 (gdb_ust_connect_sync_socket): New.
17278 (resume_thread, stop_thread): New.
17279 (run_inferior_command): New.
17280 (init_named_socket): New.
17281 (gdb_ust_socket_init): New.
17282 (cstr_to_hexstr): New.
17283 (next_st): New.
17284 (first_marker, next_marker): New.
17285 (response_ust_marker): New.
17286 (cmd_qtfstm, cmd_qtsstm): New.
17287 (unprobe_marker_at, probe_marker_at): New.
17288 (cmd_qtstmat, gdb_ust_thread): New.
17289 (gdb_ust_init): New.
17290 (initialize_tracepoint_ftlib): Call gdb_ust_init.
17291 * linux-amd64-ipa.c [HAVE_UST]: Include ust/processor.h
17292 (ST_REGENTRY): New.
17293 (x86_64_st_collect_regmap): New.
17294 (X86_64_NUM_ST_COLLECT_GREGS): New.
17295 (AMD64_RIP_REGNUM): New.
17296 (supply_static_tracepoint_registers): New.
17297 * linux-i386-ipa.c [HAVE_UST]: Include ust/processor.h
17298 (ST_REGENTRY): New.
17299 (i386_st_collect_regmap): New.
17300 (i386_NUM_ST_COLLECT_GREGS): New.
17301 (supply_static_tracepoint_registers): New.
17302 * server.c (handle_query): Handle qXfer:statictrace:read.
17303 <qSupported>: Report support for StaticTracepoints, and
17304 qXfer:statictrace:read features.
17305 * server.h (traceframe_read_sdata)
17306 (supply_static_tracepoint_registers): Declare.
17307 * remote-utils.c (convert_int_to_ascii, hexchars, ishex, tohex)
17308 (unpack_varlen_hex): Include in IPA build.
17309 * Makefile.in (ustlibs, ustinc): New.
17310 (IPA_OBJS): Add remote-utils-ipa.o.
17311 ($(IPA_LIB)): Link -ldl and -lpthread.
17312 (UST_CFLAGS): New.
17313 (IPAGENT_CFLAGS): Add UST_CFLAGS.
17314 * config.in, configure: Regenerate.
17315
9e4344e5
PA
173162010-06-20 Ian Lance Taylor <iant@google.com>
17317 Pedro Alves <pedro@codesourcery.com>
17318
17319 * linux-x86-low.c (always_true): Delete.
17320 (EMIT_ASM, EMIT_ASM32): Use an uncondition asm jmp instead of
17321 trying to fool the compiler with always_true.
17322
c6beb2cb
PA
173232010-06-20 Pedro Alves <pedro@codesourcery.com>
17324
17325 * tracepoint.c (condition_true_at_tracepoint): Don't run compiled
17326 conditions in gdbserver.
17327
d2ed6730
UW
173282010-06-19 Ulrich Weigand <uweigand@de.ibm.com>
17329
17330 * spu-low.c (spu_read_memory): Wrap around local store limit.
17331 (spu_write_memory): Likewise.
17332
4e29fb54
PA
173332010-06-15 Pedro Alves <pedro@codesourcery.com>
17334
17335 * linux-x86-low.c (amd64_emit_const, amd64_emit_void_call_2)
17336 (i386_emit_const, i386_emit_void_call_2): Replace int64_t uses with
17337 LONGEST uses.
17338 * server.h (struct emit_ops): Replace int64_t uses with LONGEST
17339 uses.
17340 * tracepoint.c (emit_const, emit_void_call_2): Replace int64_t
17341 uses with LONGEST uses.
17342
6a271cae
PA
173432010-06-14 Stan Shebs <stan@codesourcery.com>
17344 Pedro Alves <pedro@codesourcery.com>
17345
17346 Bytecode compiler.
17347
17348 * linux-x86-low.c: Include limits.h.
17349 (add_insns): New.
17350 (always_true): New.
17351 (EMIT_ASM): New.
17352 (EMIT_ASM32): New.
17353 (amd64_emit_prologue, amd64_emit_epilogue, amd64_emit_add)
17354 (amd64_emit_sub, amd64_emit_mul, amd64_emit_lsh)
17355 (amd64_emit_rsh_signed, amd64_emit_rsh_unsigned, amd64_emit_ext,
17356 (amd64_emit_log_not, amd64_emit_bit_and, amd64_emit_bit_or)
17357 (amd64_emit_bit_xor, amd64_emit_bit_not, amd64_emit_equal,
17358 (amd64_emit_less_signed, amd64_emit_less_unsigned, amd64_emit_ref,
17359 (amd64_emit_if_goto, amd64_emit_goto, amd64_write_goto_address)
17360 (amd64_emit_const, amd64_emit_call, amd64_emit_reg)
17361 (amd64_emit_pop, amd64_emit_stack_flush, amd64_emit_zero_ext)
17362 (amd64_emit_swap, amd64_emit_stack_adjust, amd64_emit_int_call_1)
17363 (amd64_emit_void_call_2): New.
17364 (amd64_emit_ops): New.
17365 (i386_emit_prologue, i386_emit_epilogue, i386_emit_add)
17366 (i386_emit_sub,i386_emit_mul, i386_emit_lsh, i386_emit_rsh_signed)
17367 (i386_emit_rsh_unsigned, i386_emit_ext, i386_emit_log_not)
17368 (i386_emit_bit_and, i386_emit_bit_or, i386_emit_bit_xor)
17369 (i386_emit_bit_not, i386_emit_equal, i386_emit_less_signed)
17370 (i386_emit_less_unsigned, i386_emit_ref, i386_emit_if_goto)
17371 (i386_emit_goto, i386_write_goto_address, i386_emit_const)
17372 (i386_emit_call, i386_emit_reg, i386_emit_pop)
17373 (i386_emit_stack_flush, i386_emit_zero_ext, i386_emit_swap)
17374 (i386_emit_stack_adjust, i386_emit_int_call_1)
17375 (i386_emit_void_call_2): New.
17376 (i386_emit_ops): New.
17377 (x86_emit_ops): New.
17378 (the_low_target): Install x86_emit_ops.
17379 * server.h (struct emit_ops): New.
17380 (get_raw_reg_func_addr): Declare.
17381 (current_insn_ptr, emit_error): Declare.
17382 * tracepoint.c (get_raw_reg, get_trace_state_variable_value)
17383 (set_trace_state_variable_value): New defines.
17384 (struct ipa_sym_addresses): New fields addr_get_raw_reg,
17385 addr_get_trace_state_variable_value and
17386 addr_set_trace_state_variable_value.
17387 (symbol_list): New fields for get_raw_reg,
17388 get_trace_state_variable_value and set_trace_state_variable_value.
17389 (condfn): New typedef.
17390 (struct tracepoint): New field `compiled_cond'.
17391 (do_action_at_tracepoint): Clear compiled_cond.
17392 (get_trace_state_variable_value, set_trace_state_variable_value):
17393 Export in the IPA.
17394 (condition_true_at_tracepoint): If there's a compiled condition,
17395 run that.
17396 (current_insn_ptr, emit_error): New globals.
17397 (struct bytecode_address): New.
17398 (get_raw_reg_func_addr): New.
17399 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul)
17400 (emit_lsh, emit_rsh_signed, emit_rsh_unsigned, emit_ext)
17401 (emit_log_not, emit_bit_and, emit_bit_or, emit_bit_xor)
17402 (emit_bit_not, emit_equal, emit_less_signed, emit_less_unsigned)
17403 (emit_ref, emit_if_goto, emit_goto, write_goto_address, emit_const)
17404 (emit_reg, emit_pop, emit_stack_flush, emit_zero_ext, emit_swap)
17405 (emit_stack_adjust, emit_int_call_1, emit_void_call_2): New.
17406 (compile_tracepoint_condition, compile_bytecodes): New.
17407 * target.h (emit_ops): Forward declare.
17408 (struct target_ops): New field emit_ops.
17409 (target_emit_ops): New.
17410 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): New.
17411 * linux-i386-ipa.c (gdb_agent_get_raw_reg): New.
17412 * linux-low.c (linux_emit_ops): New.
17413 (linux_target_ops): Install it.
17414 * linux-low.h (struct linux_target_ops): New field emit_ops.
17415
92b72907
UW
174162010-06-14 Ulrich Weigand <uweigand@de.ibm.com>
17417
17418 * linux-ppc-low.c (ppc_arch_setup): Use private regcache to test MSR.
17419 * linux-s390-low.c (ppc_arch_setup): Use private regcache to test PSW.
17420
fa593d66
PA
174212010-06-01 Pedro Alves <pedro@codesourcery.com>
17422 Stan Shebs <stan@codesourcery.com>
17423
17424 * Makefile.in (IPA_DEPFILES, extra_libraries): New.
17425 (all): Depend on $(extra_libraries).
17426 (install-only): Install the IPA.
17427 (IPA_OBJS, IPA_LIB): New.
17428 (clean): Remove the IPA lib.
17429 (IPAGENT_CFLAGS): New.
17430 (tracepoint-ipa.o, utils-ipa.o, remote-utils-ipa.o)
17431 (regcache-ipa.o, i386-linux-ipa.o, linux-i386-ipa.o)
17432 (linux-amd64-ipa.o, amd64-linux-ipa.o): New rules.
17433 * linux-amd64-ipa.c, linux-i386-ipa.c: New files.
17434 * configure.ac: Check for atomic builtins support in the compiler.
17435 (IPA_DEPFILES, extra_libraries): Define.
17436 * configure.srv (ipa_obj): Add description.
17437 (ipa_i386_linux_regobj, ipa_amd64_linux_regobj): Define.
17438 (i[34567]86-*-linux*): Set ipa_obj.
17439 (x86_64-*-linux*): Set ipa_obj.
17440 * linux-low.c (stabilizing_threads): New.
17441 (supports_fast_tracepoints): New.
17442 (linux_detach): Stabilize threads before detaching.
17443 (handle_tracepoints): Handle internal tracing breakpoints. Assert
17444 the lwp is either not stabilizing, or is moving out of a jump pad.
17445 (linux_fast_tracepoint_collecting): New.
17446 (maybe_move_out_of_jump_pad): New.
17447 (enqueue_one_deferred_signal): New.
17448 (dequeue_one_deferred_signal): New.
17449 (linux_wait_for_event_1): If moving out of a jump pad, defer
17450 pending signals to later.
17451 (linux_stabilize_threads): New.
17452 (linux_wait_1): Check if threads need moving out of jump pads, and
17453 do it if so.
17454 (stuck_in_jump_pad_callback): New.
17455 (move_out_of_jump_pad_callback): New.
17456 (lwp_running): New.
17457 (linux_resume_one_lwp): Handle moving out of jump pads.
17458 (linux_set_resume_request): Dequeue deferred signals.
17459 (need_step_over_p): Also step over fast tracepoint jumps.
17460 (start_step_over): Also uninsert fast tracepoint jumps.
17461 (finish_step_over): Also reinsert fast tracepoint jumps.
17462 (linux_install_fast_tracepoint_jump): New.
17463 (linux_target_ops): Install linux_stabilize_threads and
17464 linux_install_fast_tracepoint_jump_pad.
17465 * linux-low.h (linux_target_ops) <get_thread_area,
17466 install_fast_tracepoint_jump_pad>: New fields.
17467 (struct lwp_info) <collecting_fast_tracepoint,
17468 pending_signals_to_report, exit_jump_pad_bkpt>: New fields.
17469 (linux_get_thread_area): Declare.
17470 * linux-x86-low.c (jump_insn): New.
17471 (x86_get_thread_area): New.
17472 (append_insns): New.
17473 (push_opcode): New.
17474 (amd64_install_fast_tracepoint_jump_pad): New.
17475 (i386_install_fast_tracepoint_jump_pad): New.
17476 (x86_install_fast_tracepoint_jump_pad): New.
17477 (the_low_target): Install x86_get_thread_area and
17478 x86_install_fast_tracepoint_jump_pad.
17479 * mem-break.c (set_raw_breakpoint_at): Use read_inferior_memory.
17480 (struct fast_tracepoint_jump): New.
17481 (fast_tracepoint_jump_insn): New.
17482 (fast_tracepoint_jump_shadow): New.
17483 (find_fast_tracepoint_jump_at): New.
17484 (fast_tracepoint_jump_here): New.
17485 (delete_fast_tracepoint_jump): New.
17486 (set_fast_tracepoint_jump): New.
17487 (uninsert_fast_tracepoint_jumps_at): New.
17488 (reinsert_fast_tracepoint_jumps_at): New.
17489 (set_breakpoint_at): Use write_inferior_memory.
17490 (uninsert_raw_breakpoint): Use write_inferior_memory.
17491 (check_mem_read): Mask out fast tracepoint jumps.
17492 (check_mem_write): Mask out fast tracepoint jumps.
17493 * mem-break.h (struct fast_tracepoint_jump): Forward declare.
17494 (set_fast_tracepoint_jump): Declare.
17495 (delete_fast_tracepoint_jump)
17496 (fast_tracepoint_jump_here, uninsert_fast_tracepoint_jumps_at)
17497 (reinsert_fast_tracepoint_jumps_at): Declare.
17498 * regcache.c: Don't compile many functions when building the
17499 in-process agent library.
17500 (init_register_cache) [IN_PROCESS_AGENT]: Don't allow allocating
17501 the register buffer in the heap.
17502 (free_register_cache): If the register buffer isn't owned by the
17503 regcache, don't free it.
17504 (set_register_cache) [IN_PROCESS_AGENT]: Don't re-alocate
17505 pre-existing register caches.
17506 * remote-utils.c (convert_int_to_ascii): Constify `from' parameter
17507 type.
17508 (convert_ascii_to_int): : Constify `from' parameter type.
17509 (decode_M_packet, decode_X_packet): Replace the `to' parameter by
17510 a `to_p' pointer to pointer parameter. If TO_P is NULL, malloc
17511 the needed buffer in-place.
17512 (relocate_instruction): New.
17513 * server.c (handle_query) <qSymbols>: If the target supports
17514 tracepoints, give it a chance of looking up symbols. Report
17515 support for fast tracepoints.
17516 (handle_status): Stabilize threads.
17517 (process_serial_event): Adjust.
17518 * server.h (struct fast_tracepoint_jump): Forward declare.
17519 (struct process_info) <fast_tracepoint_jumps>: New field.
17520 (convert_ascii_to_int, convert_int_to_ascii): Adjust.
17521 (decode_X_packet, decode_M_packet): Adjust.
17522 (relocate_instruction): Declare.
17523 (in_process_agent_loaded): Declare.
17524 (tracepoint_look_up_symbols): Declare.
17525 (struct fast_tpoint_collect_status): Declare.
17526 (fast_tracepoint_collecting): Declare.
17527 (force_unlock_trace_buffer): Declare.
17528 (handle_tracepoint_bkpts): Declare.
17529 (initialize_low_tracepoint)
17530 (supply_fast_tracepoint_registers) [IN_PROCESS_AGENT]: Declare.
17531 * target.h (struct target_ops) <stabilize_threads,
17532 install_fast_tracepoint_jump_pad>: New fields.
17533 (stabilize_threads, install_fast_tracepoint_jump_pad): New.
17534 * tracepoint.c [HAVE_MALLOC_H]: Include malloc.h.
17535 [HAVE_STDINT_H]: Include stdint.h.
17536 (trace_debug_1): Rename to ...
17537 (trace_vdebug): ... this.
17538 (trace_debug): Rename to ...
17539 (trace_debug_1): ... this. Add `level' parameter.
17540 (trace_debug): New.
17541 (ATTR_USED, ATTR_NOINLINE): New.
17542 (IP_AGENT_EXPORT): New.
17543 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
17544 (collecting, gdb_collect, stop_tracing, flush_trace_buffer)
17545 (about_to_request_buffer_space, trace_buffer_is_full)
17546 (stopping_tracepoint, expr_eval_result, error_tracepoint)
17547 (tracepoints, tracing, trace_buffer_ctrl, trace_buffer_ctrl_curr)
17548 (trace_buffer_lo, trace_buffer_hi, traceframe_read_count)
17549 (traceframe_write_count, traceframes_created)
17550 (trace_state_variables)
17551 New renaming defines.
17552 (struct ipa_sym_addresses): New.
17553 (STRINGIZE_1, STRINGIZE, IPA_SYM): New.
17554 (symbol_list): New.
17555 (ipa_sym_addrs): New.
17556 (all_tracepoint_symbols_looked_up): New.
17557 (in_process_agent_loaded): New.
17558 (write_e_ipa_not_loaded): New.
17559 (maybe_write_ipa_not_loaded): New.
17560 (tracepoint_look_up_symbols): New.
17561 (debug_threads) [IN_PROCESS_AGENT]: New.
17562 (read_inferior_memory) [IN_PROCESS_AGENT]: New.
17563 (UNKNOWN_SIDE_EFFECTS): New.
17564 (stop_tracing): New.
17565 (flush_trace_buffer): New.
17566 (stop_tracing_bkpt): New.
17567 (flush_trace_buffer_bkpt): New.
17568 (read_inferior_integer): New.
17569 (read_inferior_uinteger): New.
17570 (read_inferior_data_pointer): New.
17571 (write_inferior_data_pointer): New.
17572 (write_inferior_integer): New.
17573 (write_inferior_uinteger): New.
17574 (struct collect_static_trace_data_action): Delete.
17575 (enum tracepoint_type): New.
17576 (struct tracepoint) <type>: New field `type'.
43aaf8b6
PA
17577 <actions_str, step_actions, step_actions_str>: Only include in
17578 GDBserver.
fa593d66
PA
17579 <orig_size, obj_addr_on_target, adjusted_insn_addr>
17580 <adjusted_insn_addr_end, jump_pad, jump_pad_end>: New fields.
17581 (tracepoints): Use IP_AGENT_EXPORT.
17582 (last_tracepoint): Don't include in the IPA.
17583 (stopping_tracepoint): Use IP_AGENT_EXPORT.
17584 (trace_buffer_is_full): Use IP_AGENT_EXPORT.
17585 (alloced_trace_state_variables): New.
17586 (trace_state_variables): Use IP_AGENT_EXPORT.
17587 (traceframe_t): Delete unused variable.
17588 (circular_trace_buffer): Don't include in the IPA.
17589 (trace_buffer_start): Delete.
17590 (struct trace_buffer_control): New.
17591 (trace_buffer_free): Delete.
17592 (struct ipa_trace_buffer_control): New.
17593 (GDBSERVER_FLUSH_COUNT_MASK, GDBSERVER_FLUSH_COUNT_MASK_PREV)
17594 (GDBSERVER_FLUSH_COUNT_MASK_CURR, GDBSERVER_UPDATED_FLUSH_COUNT_BIT):
17595 New.
17596 (trace_buffer_ctrl): New.
17597 (TRACE_BUFFER_CTRL_CURR): New.
17598 (trace_buffer_start, trace_buffer_free, trace_buffer_end_free):
17599 Reimplement as macros.
17600 (trace_buffer_wrap): Delete.
17601 (traceframe_write_count, traceframe_read_count)
17602 (traceframes_created, tracing): Use IP_AGENT_EXPORT.
17603 (struct tracepoint_hit_ctx) <type>: New field.
17604 (struct fast_tracepoint_ctx): New.
17605 (memory_barrier): New.
17606 (cmpxchg): New.
17607 (record_tracepoint_error): Update atomically in the IPA.
17608 (clear_inferior_trace_buffer): New.
17609 (about_to_request_buffer_space): New.
17610 (trace_buffer_alloc): Handle GDBserver and inferior simulatenous
17611 updating the same buffer.
17612 (add_tracepoint): Default the tracepoint's type to trap
17613 tracepoint, and orig_size to -1.
17614 (get_trace_state_variable) [IN_PROCESS_AGENT]: Handle allocated
17615 internal variables.
17616 (create_trace_state_variable): New parameter `gdb'. Handle it.
17617 (clear_installed_tracepoints): Clear fast tracepoint jumps.
17618 (cmd_qtdp): Handle fast tracepoints.
17619 (cmd_qtdv): Adjust.
17620 (max_jump_pad_size): New.
17621 (gdb_jump_pad_head): New.
17622 (get_jump_space_head): New.
17623 (claim_jump_space): New.
17624 (sort_tracepoints): New.
17625 (MAX_JUMP_SIZE): New.
17626 (cmd_qtstart): Handle fast tracepoints. Sync tracepoints with the
17627 IPA.
17628 (stop_tracing) [IN_PROCESS_AGENT]: Don't include the tdisconnected
17629 support. Upload fast traceframes, and delete internal IPA
17630 breakpoints.
17631 (stop_tracing_handler): New.
17632 (flush_trace_buffer_handler): New.
17633 (cmd_qtstop): Upload fast tracepoints.
17634 (response_tracepoint): Handle fast tracepoints.
17635 (tracepoint_finished_step): Upload fast traceframes. Set the
17636 tracepoint hit context's tracepoint type.
17637 (handle_tracepoint_bkpts): New.
17638 (tracepoint_was_hit): Set the tracepoint hit context's tracepoint
17639 type. Add comment about fast tracepoints.
17640 (collect_data_at_tracepoint) [IN_PROCESS_AGENT]: Don't access the
17641 non-existing action_str field.
17642 (get_context_regcache): Handle fast tracepoints.
17643 (do_action_at_tracepoint) [!IN_PROCESS_AGENT]: Don't write the PC
17644 to the regcache.
17645 (fast_tracepoint_from_jump_pad_address): New.
17646 (fast_tracepoint_from_ipa_tpoint_address): New.
17647 (collecting_t): New.
17648 (force_unlock_trace_buffer): New.
17649 (fast_tracepoint_collecting): New.
17650 (collecting): New.
17651 (gdb_collect): New.
17652 (write_inferior_data_ptr): New.
17653 (target_tp_heap): New.
17654 (target_malloc): New.
17655 (download_agent_expr): New.
17656 (UALIGN): New.
17657 (download_tracepoints): New.
17658 (download_trace_state_variables): New.
17659 (upload_fast_traceframes): New.
17660 (IPA_FIRST_TRACEFRAME): New.
17661 (IPA_NEXT_TRACEFRAME_1): New.
17662 (IPA_NEXT_TRACEFRAME): New.
17663 [IN_PROCESS_AGENT]: Include sys/mman.h and fcntl.h.
17664 [IN_PROCESS_AGENT] (gdb_tp_heap_buffer, gdb_jump_pad_buffer)
17665 (gdb_jump_pad_buffer_end): New.
17666 [IN_PROCESS_AGENT] (initialize_tracepoint_ftlib): New.
17667 (initialize_tracepoint): Adjust.
17668 [IN_PROCESS_AGENT]: Allocate the IPA heap, and jump pad scratch
17669 buffer. Initialize the low module.
17670 * utils.c (PREFIX, TOOLNAME): New.
17671 (malloc_failure): Use PREFIX.
17672 (error): In the IPA, an error causes an exit.
17673 (fatal, warning): Use PREFIX.
17674 (internal_error): Use TOOLNAME.
17675 (NUMCELLS): Increase to 10.
17676 * configure, config.in: Regenerate.
17677
d149dd1d
PA
176782010-06-01 Pedro Alves <pedro@codesourcery.com>
17679
17680 * server.c (handle_query) <qSupported>: Do two passes over the
17681 qSupported string to avoid nesting strtok.
17682
f6528abd
JK
176832010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
17684
17685 * Makefile.in (SFILES): Add $(srcdir)/proc-service.list.
17686 (CDEPS): New.
17687 * configure.ac (RDYNAMIC): New AC_MSG_CHECKING wrapping. Test also
17688 -Wl,--dynamic-list.
17689 * configure: Regenerate.
17690 * proc-service.list: New.
17691
ca2a87a0
JK
176922010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
17693
17694 * linux-low.c (linux_core_of_thread): Fix crash on invalid CONTENT.
17695 New comment.
17696
363a6e9f
OS
176972010-05-26 Ozkan Sezer <sezeroz@gmail.com>
17698
17699 * gdbreplay.c (remote_open): Check error return from socket() call by
17700 its equality to -1 not by it being negative.
17701 * remote-utils.c (remote_open): Likewise.
17702
d23b6cb1
PA
177032010-05-23 Pedro Alves <pedro@codesourcery.com>
17704
17705 * config.h: Regenerate.
17706
28d3cf85
MK
177072010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
17708
17709 * linux-m68k-low.c (ps_get_thread_area): Don't define if kernel
17710 doesn't provide PTRACE_GET_THREAD_AREA.
17711
fea36a59
MK
177122010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
17713
17714 * linux-m68k-low.c: Include <asm/ptrace.h>
17715 (ps_get_thread_area): Implement.
17716
24b066ba
DE
177172010-05-03 Doug Evans <dje@google.com>
17718
17719 * event-loop.c (struct callback_event): New struct.
17720 (callback_list): New global.
17721 (append_callback_event, delete_callback_event): New functions.
17722 (process_callback): New function.
17723 (start_event_loop): Call it.
17724 * remote-utils.c (NOT_SCHEDULED): Define.
17725 (readchar_buf, readchar_bufcnt, readchar_bufp): New static globals,
17726 moved out of readchar.
17727 (readchar): Rewrite. Call reschedule before returning.
17728 (reset_readchar): New function.
17729 (remote_close): Call it.
17730 (process_remaining, reschedule): New functions.
17731 * server.h (callback_handler_func): New typedef.
17732 (append_callback_event, delete_callback_event): Declare.
17733
9836d6ea
PA
177342010-05-03 Pedro Alves <pedro@codesourcery.com>
17735
17736 * proc-service.c (ps_pglobal_lookup): Use
17737 thread_db_look_up_one_symbol.
17738 * remote-utils.c (look_up_one_symbol): Add new `may_ask_gdb'
17739 parameter. Use it instead of all_symbols_looked_up.
17740 * server.h (struct process_info) <all_symbols_looked_up>: Delete
17741 field.
17742 (all_symbols_looked_up): Don't declare.
17743 (look_up_one_symbol): Add new `may_ask_gdb' parameter.
17744 * thread-db.c (struct thread_db) <all_symbols_looked_up>: New
17745 field.
17746 (thread_db_look_up_symbols): Adjust call to look_up_one_symbol.
17747 Set all_symbols_looked_up here.
17748 (thread_db_look_up_one_symbol): New.
17749 (thread_db_get_tls_address): Adjust.
17750 (thread_db_load_search, try_thread_db_load_1): Always allocate the
17751 thread_db object on the heap, and tentatively set it in the
17752 process structure.
17753 (thread_db_init): Don't set all_symbols_looked_up here.
17754 * linux-low.h (thread_db_look_up_one_symbol): Declare.
17755
7984d532
PA
177562010-05-03 Pedro Alves <pedro@codesourcery.com>
17757
17758 * linux-low.c (linux_kill, linux_detach): Adjust.
17759 (status_pending_p_callback): Remove redundant statement. Check
17760 for !TARGET_WAITIKIND_IGNORE, instead of
17761 TARGET_WAITKIND_STOPPED.
17762 (handle_tracepoints): Make sure LWP is locked. Adjust.
17763 (linux_wait_for_event_1): Adjust.
17764 (linux_cancel_breakpoints): New.
17765 (unsuspend_one_lwp): New.
17766 (unsuspend_all_lwps): New.
17767 (linux_wait_1): If finishing a step-over, unsuspend all lwps.
17768 (send_sigstop_callback): Change return type to int, add new
17769 `except' parameter and handle it.
17770 (suspend_and_send_sigstop_callback): New.
17771 (stop_all_lwps): Add new `suspend' and `expect' parameters, and
17772 pass them down. If SUSPEND, also increment the lwp's suspend
17773 count.
17774 (linux_resume_one_lwp): Add notice about resuming a suspended LWP.
17775 (need_step_over_p): Don't consider suspended LWPs.
17776 (start_step_over): Adjust.
17777 (proceed_one_lwp): Change return type to int, add new `except'
17778 parameter and handle it.
17779 (unsuspend_and_proceed_one_lwp): New.
17780 (proceed_all_lwps): Use find_inferior instead of
17781 for_each_inferior.
17782 (unstop_all_lwps): Add `unsuspend' parameter. If UNSUSPEND, them
17783 also decrement the suspend count of LWPs. Pass `except' down,
17784 instead of hacking its suspend count.
17785 (linux_pause_all): Add `freeze' parameter. Adjust.
17786 (linux_unpause_all): New.
17787 (linux_target_ops): Install linux_unpause_all.
17788 * server.c (handle_status): Adjust.
17789 * target.h (struct target_ops): New fields `unpause_all' and
17790 `cancel_breakpoints'. Add new parameter to `pause_all'.
17791 (pause_all): Add new `freeze' parameter.
17792 (unpause_all): New.
17793 (cancel_breakpoints): New.
17794 * tracepoint.c (clear_installed_tracepoints): Pause threads, and
17795 cancel breakpoints.
17796 (cmd_qtstart): Pause threads.
17797 (stop_tracing): Pause threads, and cancel breakpoints.
17798 * win32-low.c (win32_target_ops): Adjust.
17799
e471f25b
PA
178002010-05-03 Pedro Alves <pedro@codesourcery.com>
17801
17802 * linux-low.c (linux_wait_for_event_1): Move passing the signal to
17803 the inferior right away from here...
17804 (linux_wait_1): ... to here, and adjust to check the thread's
17805 last_resume_kind instead of the lwp's step or stop_expected flags.
17806
1915ef4f
PA
178072010-05-02 Pedro Alves <pedro@codesourcery.com>
17808
17809 * README: Use consistent `GDB' and `GDBserver' spellings.
17810
f9e39928
PA
178112010-05-02 Pedro Alves <pedro@codesourcery.com>
17812
17813 * linux-low.c (linux_kill_one_lwp): Assume the lwp is stopped.
17814 (linux_kill): Stop all lwps here. Don't delete the main lwp here.
17815 (linux_detach_one_lwp): Assume the lwp is stopped.
17816 (any_thread_of): Delete.
17817 (linux_detach): Stop all lwps here. Don't blindly delete all
17818 breakpoints.
17819 (delete_lwp_callback): New.
17820 (linux_mourn): Delete all lwps of the process that is gone.
17821 (linux_wait_1): Don't delete the last lwp of the process here.
17822 * mem-break.h (mark_breakpoints_out): Declare.
17823 * mem-break.c (mark_breakpoints_out): New.
17824 (free_all_breakpoints): Use it.
17825 * server.c (handle_target_event): If the process is gone, mark
17826 breakpoints out.
17827 * thread-db.c (struct thread_db) <create_bp>: New field.
17828 (thread_db_enable_reporting): Fix prototype. Store a thread event
17829 breakpoint reference in the thread_db struct.
17830 (thread_db_load_search): Clear the thread_db object.
17831 (try_thread_db_load_1): Ditto.
17832 (switch_to_process): New.
17833 (disable_thread_event_reporting): Use it.
17834 (remove_thread_event_breakpoints): New.
17835 (thread_db_detach, thread_db_mourn): Use it.
17836
1e7fc18c
PA
178372010-05-01 Pedro Alves <pedro@codesourcery.com>
17838
17839 * linux-low.c (linux_enable_event_reporting): New.
17840 (linux_wait_for_event_1, handle_extended_wait): Use it.
17841
02fc4de7
PA
178422010-04-30 Pedro Alves <pedro@codesourcery.com>
17843
17844 * linux-low.c (linux_kill_one_lwp, linux_kill)
17845 (linux_detach_one_lwp): Adjust to send_sigstop interface change.
17846 (send_sigstop): Take an lwp_info as parameter instead. Queue a
17847 SIGSTOP even if the LWP is stopped.
17848 (send_sigstop_callback): New.
17849 (stop_all_lwps): Use send_sigstop_callback instead.
17850 (linux_resume_one_thread): Adjust.
17851 (proceed_one_lwp): Still proceed an LWP that the client has
17852 requested to stop, if we haven't reported it as stopped yet. Make
17853 sure that LWPs the client want stopped, have a pending SIGSTOP.
17854
bc3b5632
DE
178552010-04-26 Doug Evans <dje@google.com>
17856
ae1ada35
DE
17857 * server.c (handle_general_set): Make static.
17858
bc3b5632
DE
17859 * remote-utils.c (putpkt_binary_1): Call readchar instead of read.
17860 Print received char after testing for error/eof instead of before.
17861 (input_interrupt): Tweak comment.
17862
65730243
DE
178632010-04-23 Doug Evans <dje@google.com>
17864
17865 * server.c (start_inferior): Print inferior argv if --debug.
17866
a8ae7dc0
AR
178672010-04-21 Aleksandar Ristovski <aristovski@qnx.com>
17868
17869 * Makefile.in (nto_low_h nto-low.o nto-x86-low.o): New dependency lists.
17870 * nto-x86-low.c: Include server.h
17871
1c07cc19
PM
178722010-04-20 Pierre Muller <muller@ics.u-strasbg.fr>
17873
17874 * win32-i386-low.c: Use __x86_64__ macro instead of __x86_64 to
17875 be consistent with other sources of this directory.
17876 (init_registers_amd64): Correct name of source file of this function
17877 in the comment.
17878
e0a61e09
PM
178792010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
17880
17881 * configure.srv (x86_64-*-mingw*): New configuration for Windows
17882 64-bit executables.
17883
54709339
PM
178842010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
17885
17886 * win32-i386-low.c: Add 64-bit support.
17887 (CONTEXT_EXTENDED_REGISTERS): Set macro to zero if not exisiting.
17888 (init_registers_amd64): Declare.
17889 (mappings): Add 64-bit version of array.
17890 (init_windows_x86): New function.
17891 (the_low_target): Change init_arch field to init_windows_x86.
17892
e8f0053d
PM
178932010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
17894
17895 * win32-low.c: Adapt to support also 64-bit architecture.
17896 (child_xfer_memory): Use uintptr_t type for local variable `addr'.
17897 (get_image_name): Use SIZE_T type for local variable `done'.
17898 (psapi_get_dll_name): Use LPVOID type for parameter `BaseAddress'.
17899 (toolhelp_get_dll_name): Idem.
17900 (handle_load_dll): Use CORE_ADDR type for local variable `load_addr'.
17901 Use uintptr_t typecast to avoid warning.
17902 (handle_unload_dll): Use uintptr_t typecast to avoid warning.
17903 (handle_exception): Use phex_nz to avoid warning.
17904 (win32_wait): Remove unused local variable `process'.
17905
c481e77e
PM
179062010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
17907
17908 * configure.srv (srv_amd64_regobj): Replace `x86-64-avx.o' by
17909 `amd64-avx.o'.
17910
12ea4b69
PM
179112010-04-17 Pierre Muller <muller@ics.u-strasbg.fr>
17912
17913 * configure.ac: Use `ws2_32' library for srv_mingw.
17914 * configure: Regenerate.
17915 * gdbreplay.c: Include winsock2.h instead of winsock.h.
17916 * remote-utils.c: Likewise.
17917
f6d1620c
L
179182010-04-17 H.J. Lu <hongjiu.lu@intel.com>
17919
17920 * linux-x86-low.c (xmltarget_amd64_linux_no_xml): Define only
17921 if __x86_64__ is defined.
17922
8e642873
PM
179232010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
17924
17925 * configure: Regenerate.
17926
711e434b
PM
179272010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
17928
17929 * server.c (handle_query): Handle 'qGetTIBAddr' query.
17930 * target.h (target_ops): New get_tib_address field.
17931 * win32-low.h (win32_thread_info): Add thread_local_base field.
17932 * win32-low.c (child_add_thread): Add tlb argument.
17933 Set thread_local_base field to TLB.
17934 (get_child_debug_event): Adapt to child_add_thread change.
17935 (win32_get_tib_address): New function.
17936 (win32_target_ops): Set get_tib_address field to
17937 win32_get_tib_address.
17938 * linux-low.c (linux_target_ops): Set get_tib_address field to NULL.
17939
505106cd
PA
179402010-04-12 Pedro Alves <pedro@codesourcery.com>
17941
505106cd
PA
17942 * linux-low.c (linux_mourn): Also remove the process.
17943 * server.c (handle_target_event): Don't remove the process here.
17944 * nto-low.c (nto_mourn): New.
17945 (nto_target_ops): Install it.
17946 * spu-low.c (spu_mourn): New.
17947 (spu_target_ops): Install it.
17948 * win32-low.c (win32_mourn): New.
17949 (win32_target_ops): Install it.
17950
e8470a06
PA
179512010-04-12 Pedro Alves <pedro@codesourcery.com>
17952
17953 * server.h (buffer_xml_printf): Remove redundant `;'.
17954
45ba0d02
PA
179552010-04-12 Pedro Alves <pedro@codesourcery.com>
17956
17957 * regcache.c (set_register_cache): Invalidate regcaches before
17958 changing the register cache layout.
17959 (regcache_invalidate_one): Allow a NULL regcache.
17960 * linux-x86-low.c (x86_linux_update_xmltarget): Invalidate
17961 regcaches before changing the register cache layout or the target
17962 regsets.
17963
59e04013
L
179642010-04-12 H.J. Lu <hongjiu.lu@intel.com>
17965
17966 * linux-x86-low.c (x86_linux_update_xmltarget): Avoid unused
17967 variable warning on Linux/x86-64.
17968
8336d594
PA
179692010-04-11 Pedro Alves <pedro@codesourcery.com>
17970
17971 GDBserver disconnected tracing support.
17972
17973 * linux-low.c (linux_remove_process): Delete.
17974 (add_lwp): Don't set last_resume_kind here.
17975 (linux_kill): Use `mourn'.
17976 (linux_detach): Use `thread_db_detach', and `mourn'.
17977 (linux_mourn): New.
17978 (linux_attach_lwp_1): Adjust comment.
17979 (linux_attach): last_resume_kind moved the thread_info; adjust.
17980 (status_pending_p_callback): Adjust.
17981 (linux_wait_for_event_1): Adjust.
17982 (count_events_callback, select_singlestep_lwp_callback)
17983 (select_event_lwp_callback, cancel_breakpoints_callback)
17984 (db_wants_lwp_stopped, linux_wait_1, need_step_over_p)
17985 (proceed_one_lwp): Adjust.
17986 (linux_async): Add debug output.
17987 (linux_thread_stopped): New.
17988 (linux_pause_all): New.
17989 (linux_target_ops): Install linux_mourn, linux_thread_stopped and
17990 linux_pause_all.
17991 * linux-low.h (struct lwp_info): Delete last_resume_kind field.
17992 (thread_db_free): Delete declaration.
17993 (thread_db_detach, thread_db_mourn): Declare.
17994 * thread-db.c (thread_db_init): Use thread_db_mourn.
17995 (thread_db_free): Delete, split in two.
17996 (disable_thread_event_reporting): New.
17997 (thread_db_detach): New.
17998 (thread_db_mourn): New.
17999
18000 * server.h (struct thread_info) <last_resume_kind>: New field.
18001 <attached>: Add comment.
18002 <gdb_detached>: New field.
18003 (handler_func): Change return type to int.
18004 (handle_serial_event, handle_target_event): Ditto.
18005 (gdb_connected): Declare.
18006 (tracing): Delete.
18007 (disconnected_tracing): Declare.
18008 (stop_tracing): Declare.
18009
18010 * server.c (handle_query) <qSupported>: Report support for
18011 disconnected tracing.
18012 (queue_stop_reply_callback): Account for running threads.
18013 (gdb_wants_thread_stopped): New.
18014 (gdb_wants_all_threads_stopped): New.
18015 (gdb_reattached_process): New.
18016 (handle_status): Clear the `gdb_detached' flag of all processes.
18017 In all-stop, stop all threads.
18018 (main): Be sure to leave tfind mode. Handle disconnected tracing.
18019 (process_serial_event): If the remote connection breaks, or if an
18020 exit was forced with "monitor exit", force an event loop exit.
18021 Handle disconnected tracing on detach.
18022 (handle_serial_event): Adjust.
18023 (handle_target_event): If GDB isn't connected, forward events back
18024 to the inferior, unless the last process exited, in which case,
18025 exit gdbserver. Adjust interface.
18026
18027 * remote-utils.c (remote_open): Don't block in accept. Instead
18028 register an event loop source on the listen socket file
18029 descriptor. Refactor bits into ...
18030 (listen_desc): ... this new global.
18031 (gdb_connected): ... this new function.
18032 (enable_async_notification): ... this new function.
18033 (handle_accept_event): ... this new function.
18034 (remote_close): Clear remote_desc.
18035
18036 * inferiors.c (add_thread): Set the new thread's last_resume_kind.
18037
18038 * target.h (struct target_ops) <mourn, thread_stopped, pause_all>:
18039 New fields.
18040 (mourn_inferior): Define.
18041 (target_process_qsupported): Avoid the dangling else problem.
18042 (thread_stopped): Define.
18043 (pause_all): Define.
18044 (target_waitstatus_to_string): Declare.
18045 * target.c (target_waitstatus_to_string): New.
18046
18047 * tracepoint.c (tracing): Make extern.
18048 (disconnected_tracing): New.
18049 (stop_tracing): Make extern. Handle tracing stops due to GDB
18050 disconnecting.
18051 (cmd_qtdisconnected): New.
18052 (cmd_qtstatus): Report disconnected tracing status in trace reply.
18053 (handle_tracepoint_general_set): Handle QTDisconnected.
18054
18055 * event-loop.c (event_handler_func): Change return type to int.
18056 (process_event): Bail out if the event handler wants the event
18057 loop to stop.
18058 (handle_file_event): Ditto.
18059 (start_event_loop): Bail out if the event handler wants the event
18060 loop to stop.
18061
18062 * nto-low.c (nto_target_ops): Adjust.
18063 * spu-low.c (spu_wait): Don't remove the process here.
18064 (spu_target_ops): Adjust.
18065 * win32-low.c (win32_wait): Don't remove the process here.
18066 (win32_target_ops): Adjust.
18067
5d267c4c
PA
180682010-04-11 Pedro Alves <pedro@codesourcery.com>
18069
18070 * regcache.c (realloc_register_cache): Invalidate inferior's
18071 regcache before recreating it.
18072
623ccd72
PA
180732010-04-09 Pedro Alves <pedro@codesourcery.com>
18074
18075 * tracepoint.c (cmd_qtstatus): Report trace buffer circularity.
18076
219f2f23
PA
180772010-04-09 Stan Shebs <stan@codesourcery.com>
18078 Pedro Alves <pedro@codesourcery.com>
18079
18080 * server.h (LONGEST): New.
18081 (struct thread_info) <while_stepping>: New field.
18082 (unpack_varlen_hex, xrealloc, pulongest, plongest, phex_nz):
18083 Declare.
18084 (initialize_tracepoint, handle_tracepoint_general_set)
18085 (handle_tracepoint_query, tracepoint_finished_step)
18086 (tracepoint_was_hit, release_while_stepping_state_list):
18087 (current_traceframe): Declare.
18088 * server.c (handle_general_set): Handle tracepoint packets.
18089 (read_memory): New.
18090 (write_memory): New.
18091 (handle_search_memory_1): Use read_memory.
18092 (handle_query): Report support for conditional tracepoints, trace
18093 state variables, and tracepoint sources. Handle tracepoint
18094 queries.
18095 (main): Initialize the tracepoints module.
18096 (process_serial_event): Handle traceframe reads/writes.
18097
18098 * linux-low.c (handle_tracepoints): New.
18099 (linux_wait_1): Call it.
18100 (linux_resume_one_lwp): Handle while-stepping.
18101 (linux_supports_tracepoints, linux_read_pc, linux_write_pc): New.
18102 (linux_target_ops): Install them.
18103 * linux-low.h (struct linux_target_ops) <supports_tracepoints>:
18104 New field.
18105 * linux-x86-low.c (x86_supports_tracepoints): New.
18106 (the_low_target). Install it.
18107
18108 * mem-break.h (delete_breakpoint): Declare.
18109 * mem-break.c (delete_breakpoint): Make external.
18110
18111 * target.h (struct target_ops): Add `supports_tracepoints',
18112 `read_pc', and `write_pc' fields.
18113 (target_supports_tracepoints): Define.
18114 * utils.c (xrealloc, decimal2str, pulongest, plongest, thirty_two)
18115 (phex_nz): New.
18116
18117 * regcache.h (struct regcache) <registers_owned>: New field.
18118 (init_register_cache, regcache_cpy): Declare.
18119 (regcache_read_pc, regcache_write_pc): Declare.
18120 (register_cache_size): Declare.
18121 (supply_regblock): Declare.
18122 * regcache.c (init_register_cache): New.
18123 (new_register_cache): Use it.
18124 (regcache_cpy): New.
18125 (register_cache_size): New.
18126 (supply_regblock): New.
18127 (regcache_read_pc, regcache_write_pc): New.
889bf7c5 18128
219f2f23
PA
18129 * tracepoint.c: New.
18130
18131 * Makefile.in (OBS): Add tracepoint.o.
18132 (tracepoint.o): New rule.
18133
3a13a53b
L
181342010-04-08 H.J. Lu <hongjiu.lu@intel.com>
18135
18136 * Makefile.in (clean): Also remove i386-mmx.c i386-mmx-linux.c.
18137 (i386-mmx.o): New.
18138 (i386-mmx.c): Likewise.
18139 (i386-mmx-linux.o): Likewise.
18140 (i386-mmx-linux.c): Likewise.
18141
18142 * configure.srv (srv_i386_regobj): Add i386-mmx.o.
18143 (srv_i386_linux_regobj): Add i386-mmx-linux.o.
18144 (srv_i386_xmlfiles): Add i386/i386-mmx.xml.
18145 (srv_i386_linux_xmlfiles): Add i386/i386-mmx-linux.xml.
18146
18147 * linux-x86-low.c (init_registers_i386_mmx_linux): New.
18148 (x86_linux_update_xmltarget): Call init_registers_i386_mmx_linux
18149 and return if ptrace PTRACE_GETFPXREGS failed in 32bit.
18150
1570b33e
L
181512010-04-07 H.J. Lu <hongjiu.lu@intel.com>
18152
18153 * Makefile.in (clean): Updated.
18154 (i386-avx.o): New.
18155 (i386-avx.c): Likewise.
18156 (i386-avx-linux.o): Likewise.
18157 (i386-avx-linux.c): Likewise.
18158 (amd64-avx.o): Likewise.
18159 (amd64-avx.c): Likewise.
18160 (amd64-avx-linux.o): Likewise.
18161 (amd64-avx-linux.c): Likewise.
18162
18163 * configure.srv (srv_i386_regobj): Add i386-avx.o.
18164 (srv_i386_linux_regobj): Add i386-avx-linux.o.
18165 (srv_amd64_regobj): Add amd64-avx.o.
18166 (srv_amd64_linux_regobj): Add amd64-avx-linux.o.
18167 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx.xml.
18168 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx.xml.
18169 (srv_i386_xmlfiles): Add i386/i386-avx.xml.
18170 (srv_amd64_xmlfiles): Add i386/amd64-avx.xml.
18171 (srv_i386_linux_xmlfiles): Add i386/i386-avx-linux.xml.
18172 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-linux.xml.
18173
18174 * i387-fp.c: Include "i386-xstate.h".
18175 (i387_xsave): New.
18176 (i387_cache_to_xsave): Likewise.
18177 (i387_xsave_to_cache): Likewise.
18178 (x86_xcr0): Likewise.
18179
18180 * i387-fp.h (i387_cache_to_xsave): Likewise.
18181 (i387_xsave_to_cache): Likewise.
18182 (x86_xcr0): Likewise.
18183
18184 * linux-arm-low.c (target_regsets): Initialize nt_type to 0.
18185 * linux-crisv32-low.c (target_regsets): Likewise.
18186 * linux-m68k-low.c (target_regsets): Likewise.
18187 * linux-mips-low.c (target_regsets): Likewise.
18188 * linux-ppc-low.c (target_regsets): Likewise.
18189 * linux-s390-low.c (target_regsets): Likewise.
18190 * linux-sh-low.c (target_regsets): Likewise.
18191 * linux-sparc-low.c (target_regsets): Likewise.
18192 * linux-xtensa-low.c (target_regsets): Likewise.
18193
18194 * linux-low.c: Include <sys/uio.h>.
18195 (regsets_fetch_inferior_registers): Support nt_type.
18196 (regsets_store_inferior_registers): Likewise.
18197 (linux_process_qsupported): New.
18198 (linux_target_ops): Add linux_process_qsupported.
18199
18200 * linux-low.h (regset_info): Add nt_type.
18201 (linux_target_ops): Add process_qsupported.
18202
18203 * linux-x86-low.c: Include "i386-xstate.h", "elf/common.h"
18204 and <sys/uio.h>.
18205 (init_registers_i386_avx_linux): New.
18206 (init_registers_amd64_avx_linux): Likewise.
18207 (xmltarget_i386_linux_no_xml): Likewise.
18208 (xmltarget_amd64_linux_no_xml): Likewise.
18209 (PTRACE_GETREGSET): Likewise.
18210 (PTRACE_SETREGSET): Likewise.
18211 (x86_fill_xstateregset): Likewise.
18212 (x86_store_xstateregset): Likewise.
18213 (use_xml): Likewise.
18214 (x86_linux_update_xmltarget): Likewise.
18215 (x86_linux_process_qsupported): Likewise.
18216 (target_regsets): Add NT_X86_XSTATE entry and Initialize nt_type.
18217 (x86_arch_setup): Don't call init_registers_amd64_linux nor
18218 init_registers_i386_linux here. Call
18219 x86_linux_update_xmltarget.
18220 (the_low_target): Add x86_linux_process_qsupported.
18221
18222 * server.c (handle_query): Call target_process_qsupported.
18223
18224 * target.h (target_ops): Add process_qsupported.
18225 (target_process_qsupported): New.
18226
fc7238bb
PA
182272010-04-03 Pedro Alves <pedro@codesourcery.com>
18228
18229 * inferiors.c (add_thread): Set last_status kind to
18230 TARGET_WAITKIND_IGNORE.
18231 * linux-low.c (cancel_breakpoint): Remove unnecessary regcache
18232 fetch. Use ptid_of. Avoid unnecessary get_lwp_thread calls.
18233 (linux_wait_1): Move `thread' local definition to block that uses
18234 it. Don't NULL initialize `event_child'.
18235 (linux_resume_one_thread): Avoid unnecessary get_lwp_thread calls.
18236 Alway set the thread's last_status to TARGET_WAITKIND_IGNORE.
18237 * linux-x86-low.c (x86_breakpoint_at): Read raw memory.
18238
bdabb078
PA
182392010-04-01 Pedro Alves <pedro@codesourcery.com>
18240
18241 * linux-low.c (get_stop_pc): Don't adjust the PC if stopped with
18242 an extended waitstatus, or by a watchpoint.
18243 (cancel_breakpoints_callback): Don't cancel a breakpoint if the
18244 thread was stepping or has been stopped by a watchpoint.
18245
d3bbe7a0
PA
182462010-04-01 Pedro Alves <pedro@codesourcery.com>
18247
18248 * mem-break.c (struct raw_breakpoint): New field shlib_disabled.
18249 (set_gdb_breakpoint_at): If GDB is inserting a breakpoint on top
18250 of another, then delete the previous, and validate all
18251 breakpoints.
18252 (validate_inserted_breakpoint): New.
18253 (delete_disabled_breakpoints): New.
18254 (validate_breakpoints): New.
18255 (check_mem_read): Validate breakpoints before trusting their
18256 shadow. Delete disabled breakpoints.
18257 (check_mem_write): Validate breakpoints before trusting they
18258 should be inserted. Delete disabled breakpoints.
18259 * mem-break.h (validate_breakpoints):
18260 * server.c (handle_query): Validate breakpoints when we see a
18261 qSymbol query.
18262
8b07ae33
PA
182632010-04-01 Pedro Alves <pedro@codesourcery.com>
18264
18265 * linux-low.c (linux_wait_1): Avoid setting need_step_over is
18266 there's a GDB breakpoint at stop_pc. Always report a trap to GDB
18267 if we could tell there's a GDB breakpoint at stop_pc.
18268 (need_step_over_p): Don't do a step over if we find a GDB
18269 breakpoint at the resume PC.
18270
18271 * mem-break.c (struct raw_breakpoint): New.
18272 (enum bkpt_type): New type `gdb_breakpoint'.
18273 (struct breakpoint): Delete the `PC', `old_data' and `inserted'
18274 fields. New field `raw'.
18275 (find_raw_breakpoint_at): New.
18276 (set_raw_breakpoint_at): Handle refcounting. Create a raw
18277 breakpoint instead.
18278 (set_breakpoint_at): Adjust.
18279 (delete_raw_breakpoint): New.
18280 (release_breakpoint): New.
18281 (delete_breakpoint): Rename to...
18282 (delete_breakpoint_1): ... this. Add proc parameter. Use
18283 release_breakpoint. Return ENOENT.
18284 (delete_breakpoint): Reimplement.
18285 (find_breakpoint_at): Delete.
18286 (find_gdb_breakpoint_at): New.
18287 (delete_breakpoint_at): Delete.
18288 (set_gdb_breakpoint_at): New.
18289 (delete_gdb_breakpoint_at): New.
18290 (gdb_breakpoint_here): New.
18291 (set_reinsert_breakpoint): Use release_breakpoint.
18292 (uninsert_breakpoint): Rename to ...
18293 (uninsert_raw_breakpoint): ... this.
18294 (uninsert_breakpoints_at): Adjust to handle raw breakpoints.
18295 (reinsert_raw_breakpoint): Change parameter type to
18296 raw_breakpoint.
18297 (reinsert_breakpoints_at): Adjust to handle raw breakpoints
18298 instead.
18299 (check_breakpoints): Adjust. Use release_breakpoint.
18300 (breakpoint_here): Rewrite using find_raw_breakpoint_at.
18301 (breakpoint_inserted_here): Ditto.
18302 (check_mem_read): Adjust to iterate over raw breakpoints instead.
18303 Don't trust the breakpoint's shadow if it is not inserted.
18304 (check_mem_write): Adjust to iterate over raw breakpoints instead.
18305 (delete_all_breakpoints): Adjust.
18306 (free_all_breakpoints): Mark all breakpoints as uninserted, and
18307 use delete_breakpoint_1.
18308
18309 * mem-break.h (breakpoints_supported): Delete declaration.
18310 (set_gdb_breakpoint_at): Declare.
18311 (gdb_breakpoint_here): Declare.
18312 (delete_breakpoint_at): Delete.
18313 (delete_gdb_breakpoint_at): Declare.
18314
18315 * server.h (struct raw_breakpoint): Forward declare.
18316 (struct process_info): New field `raw_breakpoints'.
18317
18318 * linux-x86-low.c (x86_insert_point, x86_remote_point): Handle Z0
18319 breakpoints.
18320
6bf5e0ba
PA
183212010-03-24 Pedro Alves <pedro@codesourcery.com>
18322
18323 * linux-low.c (status_pending_p_callback): Fix comment.
18324 (linux_wait_for_event_1): Move most of the internal breakpoint
18325 handling from here...
18326 (linux_wait_1): ... to here.
18327 (count_events_callback): New.
18328 (select_singlestep_lwp_callback): New.
18329 (select_event_lwp_callback): New.
18330 (cancel_breakpoints_callback): New.
18331 (select_event_lwp): New.
18332 (linux_wait_1): Simplify internal breakpoint handling. Give equal
18333 priority to all LWPs that have had events that should be reported
18334 to the client. Cancel breakpoints when about to reporting the
18335 event to the client, not while stopping lwps. No longer cancel
18336 finished single-steps here.
18337 (cancel_finished_single_step): Delete.
18338 (cancel_finished_single_steps): Delete.
18339
414a389f
PA
183402010-03-24 Pedro Alves <pedro@codesourcery.com>
18341
18342 * mem-break.c (enum bkpt_type): New.
18343 (struct breakpoint): New field `type'.
18344 (set_breakpoint_at): Change return type to struct breakpoint
18345 pointer. Set type to `other_breakpoint' by default.
18346 (delete_breakpoint): Rewrite, supporting more than one breakpoint
18347 in the breakpoint list.
18348 (delete_reinsert_breakpoints): Only delete reinsert breakpoints.
18349 (reinsert_breakpoint): Rename to ...
18350 (reinsert_raw_breakpoint): ... this.
18351 (reinsert_breakpoints_at): Adjust.
18352 * mem-break.h (struct breakpoint): Declare.
18353 (set_breakpoint_at): Change return type to struct breakpoint
18354 pointer.
18355
2280c721
PA
183562010-03-24 Pedro Alves <pedro@codesourcery.com>
18357
18358 * server.c (handle_query): Assign, not compare.
18359
d50171e4
PA
183602010-03-24 Pedro Alves <pedro@codesourcery.com>
18361
18362 Teach linux gdbserver to step-over-breakpoints.
18363
18364 * linux-low.c (can_hardware_single_step): New.
18365 (supports_breakpoints): New.
18366 (handle_extended_wait): If stopping threads, read the stop pc of
18367 the new cloned LWP.
18368 (get_pc): New.
18369 (get_stop_pc): Add `lwp' parameter. Handle it. Bail out if the
18370 low target doesn't support retrieving the PC.
18371 (add_lwp): Set last_resume_kind to resume_continue.
18372 (linux_attach_lwp_1): Adjust comments. Always set stop_expected.
18373 (linux_attach): Don't clear stop_expected. Set the lwp's
18374 last_resume_kind to resume_stop.
18375 (linux_detach_one_lwp): Don't check for removed breakpoints.
18376 (check_removed_breakpoint): Delete.
18377 (status_pending_p): Rename to ...
18378 (status_pending_p_callback): ... this. Don't check for removed
18379 breakpoints. Don't consider threads that are stopped from GDB's
18380 perspective.
18381 (linux_wait_for_lwp): Always read the stop_pc here.
18382 (cancel_breakpoint): New.
18383 (step_over_bkpt): New global.
18384 (linux_wait_for_event_1): Implement stepping over breakpoints.
18385 (gdb_wants_lwp_stopped): New.
18386 (gdb_wants_all_stopped): New.
18387 (linux_wait_1): Tag threads as gdb-wants-stopped. Cancel finished
18388 single-step traps here. Store the thread's last reported target
18389 wait status.
18390 (send_sigstop): Don't clear stop_expected. Always set it,
18391 instead.
18392 (mark_lwp_dead): Remove reference to pending_is_breakpoint.
18393 (cancel_finished_single_step): New.
18394 (cancel_finished_single_steps): New.
18395 (wait_for_sigstop): Don't cancel finished single-step traps here.
18396 (linux_resume_one_lwp): Don't check for removed breakpoints.
18397 Don't set `step' on non-hardware step archs.
18398 (linux_set_resume_request): Ignore resume_stop requests if already
18399 stopping or stopped. Set the lwp's last_resume_kind.
18400 (resume_status_pending_p): Don't check for removed breakpoints.
18401 (need_step_over_p): New.
18402 (start_step_over): New.
18403 (finish_step_over): New.
18404 (linux_resume_one_thread): Always queue a sigstop for resume_stop
18405 requests. Clear the thread's last reported target waitstatus.
18406 Don't use the `suspended' flag. Don't consider pending breakpoints.
18407 (linux_resume): Start a step-over if necessary.
18408 (proceed_one_lwp): New.
18409 (proceed_all_lwps): New.
18410 (unstop_all_lwps): New.
18411 * linux-low.h (struct lwp_info): Rewrite comment for the
18412 `suspended' flag. Add the `stop_pc' field. Delete the
18413 `pending_stop_pc' field. Tweak the `stepping' flag's comment.
18414 Add `'last_resume_kind' and `need_step_over' fields.
18415 * inferiors.c (struct thread_info): Delete, moved elsewhere.
18416 * mem-break.c (struct breakpoint): Delete `reinserting' flag.
18417 Delete `breakpoint_to_reinsert' field. New flag `inserted'.
18418 (set_raw_breakpoint_at): New.
18419 (set_breakpoint_at): Rewrite to use it.
18420 (reinsert_breakpoint_handler): Delete.
18421 (set_reinsert_breakpoint): New.
18422 (reinsert_breakpoint_by_bp): Delete.
18423 (delete_reinsert_breakpoints): New.
18424 (uninsert_breakpoint): Rewrite.
18425 (uninsert_breakpoints_at): New.
18426 (reinsert_breakpoint): Rewrite.
18427 (reinsert_breakpoints_at): New.
18428 (check_breakpoints): Rewrite.
18429 (breakpoint_here): New.
18430 (breakpoint_inserted_here): New.
18431 (check_mem_read): Adjust.
18432 * mem-break.h (breakpoints_supported, breakpoint_here)
18433 (breakpoint_inserted_here, set_reinsert_breakpoint): Declare.
18434 (reinsert_breakpoint_by_bp): Delete declaration.
18435 (delete_reinsert_breakpoints): Declare.
18436 (reinsert_breakpoint): Delete declaration.
18437 (reinsert_breakpoints_at): Declare.
18438 (uninsert_breakpoint): Delete declaration.
18439 (uninsert_breakpoints_at): Declare.
18440 (check_breakpoints): Adjust prototype.
18441 * server.h: Adjust include order.
18442 (struct thread_info): Declare here. Add a `last_status' field.
18443
30ba68cb
MS
184442010-03-23 Michael Snyder <msnyder@vmware.com>
18445
18446 * server.c (crc32): New function.
18447 (handle_query): Add handling for 'qCRC:' request.
18448
b9a881c2
PA
184492010-03-23 Pedro Alves <pedro@codesourcery.com>
18450
18451 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR6 if the
18452 lwp had been stopped by a watchpoint.
18453
e92d13d5
PA
184542010-03-16 Pedro Alves <pedro@codesourcery.com>
18455
18456 * server.h (internal_error): Declare.
18457 (gdb_assert, ASSERT_FUNCTION, gdb_assert_fail): Define.
18458 * utils.c (internal_error): New function.
18459
64daa791
AS
184602010-03-15 Andreas Schwab <schwab@redhat.com>
18461
18462 * configure.srv: Fix typo setting srv_regobj.
18463
f52cd8cd
PA
184642010-03-15 Pedro Alves <pedro@codesourcery.com>
18465
18466 * linux-low.c (fetch_register): Avoid passing a non string literal
18467 format to `error'.
18468 (usr_store_inferior_registers): Ditto.
18469
93ae6fdc
PA
184702010-03-14 Pedro Alves <pedro@codesourcery.com>
18471
18472 * linux-low.c (linux_write_memory): Bail out early if peeking
18473 memory failed.
18474
c3adc08c
PA
184752010-03-14 Pedro Alves <pedro@codesourcery.com>
18476
18477 * linux-low.h (struct lwp_info): New fields
18478 `stopped_by_watchpoint' and `stopped_data_address'.
18479 * linux-low.c (linux_wait_for_lwp): Check for watchpoint triggers
18480 here, and cache them in the lwp object.
18481 (wait_for_sigstop): Check stopped_by_watchpoint lwp field
18482 directly.
18483 (linux_resume_one_lwp): Clear the lwp's stopped_by_watchpoint
18484 field.
18485 (linux_stopped_by_watchpoint): Rewrite.
18486 (linux_stopped_data_address): Rewrite.
18487
bce522a2
PA
184882010-03-06 Simo Melenius <simo.melenius@iki.fi>
18489
18490 * linux-low.c (linux_wait_for_lwp): Fetch the regcache after
18491 switching the current inferior, not before.
18492
90884b2b
L
184932010-03-01 H.J. Lu <hongjiu.lu@intel.com>
18494
18495 * Makefile.in (clean): Replace reg-i386.c, reg-x86-64.c,
18496 reg-i386-linux.c and reg-x86-64-linux.c with i386.c, amd64.c,
18497 i386-linux.c and amd64-linux.c.
18498 (reg-i386.o): Removed.
18499 (reg-i386.c): Likewise.
18500 (reg-i386-linux.o): Likewise.
18501 (reg-i386-linux.c): Likewise.
18502 (reg-x86-64.o): Likewise.
18503 (reg-x86-64.c): Likewise.
18504 (reg-x86-64-linux.o): Likewise.
18505 (reg-x86-64-linux.c): Likewise.
18506 (i386.o): New.
18507 (i386.c): Likewise.
18508 (i386-linux.o): Likewise.
18509 (i386-linux.c): Likewise.
18510 (amd64.o): Likewise.
18511 (amd64.c): Likewise.
18512 (amd64-linux.o): Likewise.
18513 (amd64-linux.c): Likewise.
18514
18515 * configure.srv (srv_i386_regobj): New.
18516 (srv_i386_linux_regobj): Likewise.
18517 (srv_amd64_regobj): Likewise.
18518 (srv_amd64_linux_regobj): Likewise.
18519 (srv_i386_32bit_xmlfiles): Likewise.
18520 (srv_i386_64bit_xmlfiles): Likewise.
18521 (srv_i386_xmlfiles): Likewise.
18522 (srv_amd64_xmlfiles): Likewise.
18523 (srv_i386_linux_xmlfiles): Likewise.
18524 (srv_amd64_linux_xmlfiles): Likewise.
18525 (i[34567]86-*-cygwin*): Set srv_regobj to $srv_i386_regobj. Set
18526 srv_xmlfiles to $srv_i386_xmlfiles.
18527 (i[34567]86-*-mingw32ce*): Likewise.
18528 (i[34567]86-*-mingw*): Likewise.
18529 (i[34567]86-*-nto*): Likewise.
18530 (i[34567]86-*-linux*): Set srv_regobj to $srv_i386_linux_regobj
18531 and $srv_amd64_linux_regobj. Set srv_xmlfiles to
18532 $srv_i386_linux_xmlfiles and $srv_amd64_linux_xmlfiles.
18533 (x86_64-*-linux*): Likewise.
18534
18535 * linux-x86-low.c (init_registers_x86_64_linux): Removed.
18536 (init_registers_amd64_linux): New.
18537 (x86_arch_setup): Replace init_registers_x86_64_linux with
18538 init_registers_amd64_linux.
18539
193f13e6
MK
185402010-02-23 Maxim Kuvyrkov <maxim@codesourcery.com>
18541
18542 * configure.ac: Check for libdl. If it is not available link against
18543 static libthread_db.
18544 * configure: Regenerate.
18545
85d721b8
PA
185462010-02-22 Pedro Alves <pedro@codesourcery.com>
18547
18548 PR9605
18549
18550 * i386-low.c (i386_length_and_rw_bits): Throw a fatal error if
18551 handing a read watchpoint.
18552 (i386_low_insert_watchpoint): Read watchpoints aren't supported.
18553
6076632b
DE
185542010-02-12 Doug Evans <dje@google.com>
18555
18556 * linux-low.c (linux_supports_tracefork_flag): Document.
18557 (linux_look_up_symbols): Add comment.
18558
3327ccf7
L
185592010-02-03 H.J. Lu <hongjiu.lu@intel.com>
18560
18561 * regcache.c (supply_register): Clear regcache if buf is NULL.
18562
0718675c 185632010-02-02 Nicolas Roche <roche@sourceware.org>
3327ccf7 18564 Joel Brobecker <brobecker@adacore.com>
0718675c
JB
18565
18566 * inferiors.c (find_inferior): Add function documentation.
18567 (unloaded_dll): Handle the case where the unloaded dll has not
18568 been previously registered in the dll list.
18569
177321bd
DJ
185702010-02-01 Daniel Jacobowitz <dan@codesourcery.com>
18571
18572 * linux-arm-low.c (thumb_breakpoint_len): Delete.
18573 (thumb2_breakpoint): New.
18574 (arm_breakpoint_at): Check for Thumb-2 breakpoints.
18575
2b009048
DJ
185762010-01-29 Daniel Jacobowitz <dan@codesourcery.com>
18577
18578 * linux-low.c (get_stop_pc): Check for SIGTRAP.
18579 (linux_wait_for_event_1): Handle SIGILL and SIGSEGV as possible
18580 breakpoints.
18581
3be029c7
PA
185822010-01-21 Pedro Alves <pedro@codesourcery.com>
18583
18584 * linux-ppc-low.c (ppc_arch_setup): Adjust to regcache changes.
18585
18f5de3b
JK
185862010-01-21 Jan Kratochvil <jan.kratochvil@redhat.com>
18587
18588 * linux-s390-low.c (s390_collect_ptrace_register)
18589 (s390_supply_ptrace_register): Adjust it for the new regcache parameter.
18590
3743bb4f
DE
185912010-01-21 Doug Evans <dje@google.com>
18592
14ce3065
DE
18593 * linux-low.c (PTRACE_ARG3_TYPE): Change from long to void*.
18594 (PTRACE_ARG4_TYPE): New macro.
18595 (handle_extended_wait): Cast ptrace arg4 to PTRACE_ARG4_TYPE.
18596 (linux_wait_for_event_1, linux_resume_one_lwp): Ditto.
18597 (fetch_register): Cast to uintptr_t before casting to PTRACE_ARG3_TYPE.
18598 (usr_store_inferior_registers): Ditto.
18599 (linux_read_memory, linux_write_memory): Ditto.
18600 (linux_test_for_tracefork): Ditto.
18601
3743bb4f
DE
18602 * linux-arm-low.c: Remove redundant include of gdb_proc_service.h.
18603 Only include elf.h if gdb_proc_service.h didn't include linux/elf.h.
18604
8b315be5
PA
186052010-01-21 Pedro Alves <pedro@codesourcery.com>
18606
18607 * proc-service.c (ps_lgetregs): Don't refetch registers from the
18608 target.
18609
85492558
PA
186102010-01-21 Pedro Alves <pedro@codesourcery.com>
18611
18612 * spu-low.c (spu_fetch_registers, spu_store_registers): Change
18613 prototype to take a regcache. Adjust.
18614
442ea881
PA
186152010-01-20 Pedro Alves <pedro@codesourcery.com>
18616
18617 * regcache.h (struct thread_info): Forward declare.
18618 (struct regcache): New.
18619 (new_register_cache): Adjust prototype.
18620 (get_thread_regcache): Declare.
18621 (free_register_cache): Adjust prototype.
18622 (registers_to_string, registers_from_string): Ditto.
18623 (supply_register, supply_register_by_name, collect_register)
18624 (collect_register_as_string, collect_register_by_name): Ditto.
18625 * regcache.c (struct inferior_regcache_data): Delete.
18626 (get_regcache): Rename to ...
18627 (get_thread_regcache): ... this. Adjust. Switch inferior before
18628 fetching registers.
18629 (regcache_invalidate_one): Adjust.
18630 (regcache_invalidate): Fix prototype.
18631 (new_register_cache): Return the new register cache.
18632 (free_register_cache): Change prototype.
18633 (realloc_register_cache): Adjust.
18634 (registers_to_string): Change prototype to take a regcache. Adjust.
18635 (registers_from_string): Ditto.
18636 (register_data): Ditto.
18637 (supply_register): Ditto.
18638 (supply_register_by_name): Ditto.
18639 (collect_register): Ditto.
18640 (collect_register_as_string): Ditto.
18641 (collect_register_by_name): Ditto.
18642 * server.c (process_serial_event): Adjust.
18643 * linux-low.h (regset_fill_func, regset_store_func): Change
18644 prototype.
18645 (get_pc, set_pc, collect_ptrace_register, supply_ptrace_register):
18646 Change prototype.
18647 * linux-low.c (get_stop_pc): Adjust.
18648 (check_removed_breakpoint): Adjust.
18649 (linux_wait_for_event): Adjust.
18650 (linux_resume_one_lwp): Adjust.
18651 (fetch_register): Add regcache parameter. Adjust.
18652 (usr_store_inferior_registers): Ditto.
18653 (regsets_fetch_inferior_registers): Ditto.
18654 (regsets_store_inferior_registers): Ditto.
18655 (linux_fetch_registers, linux_store_registers): Ditto.
18656 * i387-fp.c (i387_cache_to_fsave): Change prototype to take a
18657 regcache. Adjust.
43aaf8b6
PA
18658 (i387_fsave_to_cache, i387_cache_to_fxsave, i387_fxsave_to_cache):
18659 Ditto.
442ea881
PA
18660 * i387-fp.h (i387_cache_to_fsave, i387_fsave_to_cache): Change
18661 prototype to take a regcache.
18662 (i387_cache_to_fxsave, i387_fxsave_to_cache): Ditto.
18663 * remote-utils.c (convert_ascii_to_int, outreg)
18664 (prepare_resume_reply): Change prototype to take a regcache.
18665 Adjust.
18666 * target.h (struct target_ops) <fetch_registers, store_registers>:
18667 Change prototype to take a regcache.
18668 (fetch_inferior_registers, store_inferior_registers): Change
18669 prototype to take a regcache. Adjust.
18670 * proc-service.c (ps_lgetregs): Adjust.
18671 * linux-x86-low.c (x86_fill_gregset, x86_store_gregset)
18672 (x86_fill_fpregset, x86_store_fpregset, x86_fill_fpxregset)
18673 (x86_store_fpxregset, x86_get_pc, x86_set_pc): Change prototype to
18674 take a regcache. Adjust.
18675 * linux-arm-low.c (arm_fill_gregset, arm_store_gregset)
18676 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
18677 (arm_store_vfpregset, arm_get_pc, arm_set_pc):
18678 (arm_breakpoint_at): Change prototype to take a regcache. Adjust.
18679 * linux-cris-low.c (cris_get_pc, cris_set_pc)
18680 (cris_cannot_fetch_register):
18681 (cris_breakpoint_at): Change prototype to take a regcache.
18682 Adjust.
18683 * linux-crisv32-low.c (cris_get_pc, cris_set_pc,
18684 cris_reinsert_addr, cris_write_data_breakpoint): Change prototype
18685 to take a regcache. Adjust.
18686 (cris_breakpoint_at, cris_insert_point, cris_remove_point):
18687 Adjust.
18688 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Change prototype to
18689 take a regcache. Adjust.
18690 * linux-m68k-low.c (m68k_fill_gregset, m68k_store_gregset)
18691 (m68k_fill_fpregset, m68k_store_fpregset, m68k_get_pc,
18692 (m68k_set_pc): Change prototype to take a regcache. Adjust.
18693 * linux-mips-low.c (mips_get_pc):
18694 (mips_set_pc): Change prototype to take a regcache. Adjust.
18695 (mips_reinsert_addr): Adjust.
18696 (mips_collect_register): Change prototype to take a regcache.
18697 Adjust.
18698 (mips_supply_register):
18699 (mips_collect_register_32bit, mips_supply_register_32bit)
18700 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
18701 (mips_store_fpregset): Ditto.
43aaf8b6
PA
18702 * linux-ppc-low.c (ppc_supply_ptrace_register)
18703 (ppc_supply_ptrace_register): Ditto.
442ea881
PA
18704 (parse_spufs_run): Adjust.
18705 (ppc_get_pc, ppc_set_pc, ppc_fill_gregset, ppc_fill_vsxregset)
18706 (ppc_store_vsxregset, ppc_fill_vrregset, ppc_store_vrregset)
18707 (ppc_fill_evrregset, ppc_store_evrregset): Change prototype to
18708 take a regcache. Adjust.
18709 * linux-s390-low.c (s390_collect_ptrace_register)
18710 (s390_supply_ptrace_register, s390_fill_gregset, s390_get_pc)
18711 (s390_set_pc): Change prototype to take a regcache. Adjust.
18712 (s390_arch_setup): Adjust.
18713 * linux-sh-low.c (sh_get_pc, sh_breakpoint_at)
18714 (sh_fill_gregset): Change prototype to take a regcache. Adjust.
18715 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
18716 (sparc_fill_gregset, sparc_store_gregset_from_stack)
18717 (sparc_store_gregset, sparc_get_pc): Change prototype to take a
18718 regcache. Adjust.
18719 (sparc_breakpoint_at): Adjust.
18720 * linux-xtensa-low.c (xtensa_fill_gregset):
18721 (xtensa_store_gregset):
18722 (xtensa_fill_xtregset, xtensa_store_xtregset, xtensa_get_pc)
18723 (xtensa_set_pc): Change prototype to take a regcache. Adjust.
18724 * nto-low.c (nto_fetch_registers, nto_store_registers): Change
18725 prototype to take a regcache. Adjust.
18726 * win32-arm-low.c (arm_fetch_inferior_register)
18727 (arm_store_inferior_register): Change prototype to take a
18728 regcache. Adjust.
18729 * win32-i386-low.c (i386_fetch_inferior_register)
18730 (i386_store_inferior_register): Change prototype to take a
18731 regcache. Adjust.
18732 * win32-low.c (child_fetch_inferior_registers)
18733 (child_store_inferior_registers): Change prototype to take a
18734 regcache. Adjust.
18735 (win32_wait): Adjust.
18736 (win32_fetch_inferior_registers): Change prototype to take a
18737 regcache. Adjust.
18738 (win32_store_inferior_registers): Adjust.
18739 * win32-low.h (struct win32_target_ops) <fetch_inferior_register,
18740 store_inferior_register>: Change prototype to take a regcache.
18741
60c3d7b0
DE
187422010-01-20 Doug Evans <dje@google.com>
18743
18744 * linux-low.c (linux_create_inferior): Wrap use of __SIGRTMIN in
18745 #ifdef.
18746 (linux_wait_for_event1, linux_init_signals): Ditto.
ec8ebe72 18747 (W_STOPCODE): Provide definition if missing.
60c3d7b0 18748
dc146f7c
VP
187492010-01-13 Vladimir Prus <vladimir@codesourcery.com>
18750
18751 * linux-low.c (linux_core_of_thread): New.
18752 (compare_ints, show_process, list_threads): New.
18753 (linux_qxfer_osdata): Report threads and cores.
18754 (linux_target_op): Register linux_core_of_thread.
18755 * remote-utils.c (prepare_resume_reply): Report the core.
18756 (buffer_xml_printf): Support %d specifier.
18757 * server.c (handle_threads_qxfer_proper, handle_threads_qxfer):
18758 New.
18759 (handle_query): Handle qXfer:threads. Announce availability
18760 thereof.
18761 * target.h (struct target_ops): New field core_of_thread.
18762
7803799a
UW
187632010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
18764
18765 * Makefile.in (clean): Remove new generated files.
18766 (reg-s390.o, reg-s390.c): Remove rules.
18767 (reg-s390x.o, reg-s390x.c): Likewise.
18768 (s390-linux32.o, s390-linux32.c): Add rules.
18769 (s390-linux64.o, s390-linux64.c): Likewise.
18770 (s390x-linux64.o, s390x-linux64.c): Likewise.
18771 * configure.srv (s390*-*-linux*): Update srv_regobj and srv_xmlfiles.
18772 * linux-s390-low.c: Include <elf.h>.
18773 (HWCAP_S390_HIGH_GPRS): Define if undefined.
18774 (init_registers_s390): Remove prototype.
18775 (init_registers_s390x): Likewise.
18776 (init_registers_s390_linux32): Add prototype.
18777 (init_registers_s390_linux64): Likewise.
18778 (init_registers_s390x_linux64): Likewise.
18779 (s390_num_regs_3264): New define.
18780 (s390_regmap_3264): New global variable.
18781 (s390_cannot_fetch_register): Remove obsolete check.
18782 (s390_cannot_store_register): Likewise.
18783 (s390_collect_ptrace_register): Handle upper/lower register halves.
18784 (s390_supply_ptrace_register): Likewise.
18785 (s390_fill_gregset): Update to register number changes.
18786 (s390_get_hwcap): New routine.
18787 (s390_arch_setup): Detect 32-bit process running on 64-bit system.
18788 Install appropriate regmap and register set.
18789
6e7ffa39
JB
187902010-01-01 Joel Brobecker <brobecker@adacore.com>
18791
18792 * server.c (gdbserver_version): Update copyright year to 2010.
18793 * gdbreplay.c (gdbreplay_version): Likewise.
18794
957f3f49
DE
187952009-12-28 Doug Evans <dje@google.com>
18796
18797 * linux-low.c: Delete inclusion of ansidecl.h, elf/common.h,
18798 elf/external.h. Include <elf.h> instead but only if necessary.
18799
ca5c370d
PA
188002009-12-28 Pedro Alves <pedro@codesourcery.com>
18801
18802 * linux-low.c (linux_remove_process): Remove `detaching'
18803 parameter. Don't release/detach from thread_db here.
18804 (linux_kill): Release/detach from thread_db here, ...
18805 (linux_detach): ... and here, before actually detaching.
18806 (linux_wait_1): ... and here, when a process exits.
18807 * thread-db.c (any_thread_of): New.
18808 (thread_db_free): Switch the current inferior to a thread of the
18809 passed in process.
18810
4ee62156
DE
188112009-12-21 Doug Evans <dje@google.com>
18812
d90e6a88
DE
18813 * linux-x86-low.c: Delete outdated comment about Elf32_Phdr.
18814
c5f62d5f
DE
18815 * linux-low.c (kill_lwp): Use __NR_tkill instead of SYS_tkill.
18816 Move definition of tkill_failed to ifdef __NR_tkill to avoid gcc
18817 warning ifndef __NR_tkill. Move setting of errno there too.
18818 Delete unnecessary resetting of errno after syscall.
18819 Minor comment changes to match gdb/linux-nat.c:kill_lwp.
18820
10e86dd7
DE
18821 * configure.ac: Check for dladdr.
18822 * config.in: Regenerate.
18823 * configure: Regenerate.
18824 * thread-db.c (dladdr_to_soname): Only define ifdef HAVE_DLADDR.
18825 (try_thread_db_load): Update.
18826
4ee62156
DE
18827 * linux-low.c (my_waitpid): Delete unnecessary prototype.
18828
00f515da
DE
188292009-12-18 Doug Evans <dje@google.com>
18830
e9464885
DE
18831 * event-loop.c: Include unistd.h if it exists.
18832
07d4f67e
DE
18833 * linux-low.c (my_waitpid): Move definition away from being in
18834 between linux_tracefork_child/linux_test_for_tracefork.
18835
00f515da
DE
18836 * gdb_proc_service.h (psaddr_t): Fix type.
18837 * thread-db.c (thread_db_info.td_thr_tls_get_addr_p): Fix
18838 signature to match glibc.
18839
1de1badb
DE
188402009-12-16 Doug Evans <dje@google.com>
18841
18842 * linux-low.c (linux_read_memory): Fix argument to read.
18843
aeeb81d1
PA
188442009-11-26 Pedro Alves <pedro@codesourcery.com>
18845
18846 * win32-low.c (get_child_debug_event): On EXIT_THREAD_DEBUG_EVENT
18847 events, don't leave current_inferior pointing at null.
18848
10357975
PA
188492009-11-26 Pedro Alves <pedro@codesourcery.com>
18850
18851 * win32-low.c (LOG): Delete.
18852 (OUTMSG): Output to stderr.
18853 (OUTMSG2): Conditionalize on `debug_threads' variable, instead of
18854 on compile time LOG macro.
18855 (win32_wait): Fix debug output.
18856
cf6e3471
PA
188572009-11-26 Pedro Alves <pedro@codesourcery.com>
18858
18859 * win32-low.c (win32_add_one_solib): If the dll name is
18860 "ntdll.dll", prepend the system directory to the dll path.
18861
0c85e18e
MK
188622009-11-17 Daniel Jacobowitz <dan@codesourcery.com>
18863
18864 * m68k-tdep.c (m68k_gdbarch_init): Reuse previous initialization.
18865
9ac544ce 188662009-11-17 Nathan Sidwell <nathan@codesourcery.com>
889bf7c5 18867 Vladimir Prus <vladimir@codesourcery.com>
9ac544ce
MK
18868
18869 * Makefile.in (reg-cf.o, reg-cf.c): New targets.
18870 * configure.ac: Check for __mcoldfire__ and set
18871 gdb_cv_m68k_is_coldfire.
18872 * configure.srv: Use gdb_cv_m68k_is_coldfire to select between
18873 reg-cf.o and reg-m68k.o.
18874 * configure: Regenerated.
18875
fd7dd3e6
PA
188762009-11-16 Pedro Alves <pedro@codesourcery.com>
18877
18878 * linux-low.c (linux_remove_process): Add `detaching' parameter.
18879 Pass it to thread_db_free.
18880 (linux_kill, linux_detach, linux_wait_1): Adjust to pass the
18881 proper `detaching' argument to linux_remove_process.
18882 * linux-low.h (thread_db_free): Add `detaching' parameter.
18883 * thread-db.c (thread_db_init): Pass false as `detaching' argument
18884 to thread_db_free.
18885 (thread_db_free): Add `detaching' parameter. Only
18886 call td_ta_clear_event if detaching from process.
18887
75aa492e
MK
188882009-11-12 Maxim Kuvyrkov <maxim@codesourcery.com>
18889
18890 * thread-db.c (thread_db_free): Fix typo.
18891
21e1bee4
PP
188922009-11-11 Paul Pluzhnikov <ppluzhnikov@google.com>
18893
18894 PR gdb/10838
18895 * thread-db.c (thread_db_free): Call td_ta_clear_event.
18896
8838b45e
NS
188972009-11-03 Nathan Sidwell <nathan@codesourcery.com>
18898
18899 * configure.ac (i[34567]86-*): Check if we're targetting x86-64
18900 with an i686 compiler.
18901 * configure.srv (i[34567]86-*-linux*): Pull in x86-64 handling if
18902 needed.
18903 * configure: Rebuilt.
18904
8a35fb51
SL
189052009-10-29 Sandra Loosemore <sandra@codesourcery.com>
18906
18907 PR gdb/10783
18908
18909 * server.c (handle_search_memory_1): Correct read_addr initialization
18910 in loop for searching subsequent chunks.
18911
96f15937
PP
189122009-10-29 Paul Pluzhnikov <ppluzhnikov@google.com>
18913
18914 * configure.ac: New --with-libthread-db option.
18915 * thread-db.c: Allow direct dependence on libthread_db.
18916 (thread_db_free): Adjust.
18917 * config.in: Regenerate.
18918 * configure: Likewise.
889bf7c5 18919
5f7d1694
PP
189202009-10-28 Paul Pluzhnikov <ppluzhnikov@google.com>
18921
18922 PR gdb/10757
18923 * thread-db.c (attach_thread): New function.
18924 (maybe_attach_thread): Return success/failure.
18925 (find_new_threads_callback): Adjust.
889bf7c5
PA
18926 (thread_db_find_new_threads): Loop until no new threads.
18927
88e3b899
PA
189282009-10-13 Pedro Alves <pedro@codesourcery.com>
18929
18930 * proc-service.c (ps_lgetregs): Formatting.
18931
cdbfd419
PP
189322009-10-08 Paul Pluzhnikov <ppluzhnikov@google.com>
18933
18934 * acinclude.m4: (SRV_CHECK_THREAD_DB, SRV_CHECK_TLS_GET_ADDR): Remove.
18935 * configure.ac: Adjust.
18936 * linux-low.h (struct process_info_private): Move members to struct
18937 thread_db.
18938 (thread_db_free, thread_db_handle_monitor_command): New prototype.
18939 * linux-low.c (linux_remove_process): Adjust.
18940 (linux_wait_for_event_1, linux_look_up_symbols): Likewise.
18941 * server.c (handle_query): Move code ...
18942 (handle_monitor_command): ... here. New function.
18943 * target.h (struct target_ops): New member.
18944 * thread-db.c (struct thread_db): New.
18945 (libthread_db_search_path): New variable.
18946 (thread_db_create_event, thread_db_enable_reporting)
18947 (find_one_thread, maybe_attach_thread, find_new_threads_callback)
18948 (thread_db_find_new_threads, (thread_db_get_tls_address): Adjust.
18949 (try_thread_db_load_1, dladdr_to_soname): New functions.
18950 (try_thread_db_load, thread_db_load_search): New functions.
18951 (thread_db_init): Search for libthread_db.
18952 (thread_db_free): New function.
18953 (thread_db_handle_monitor_command): Likewise.
18954 * config.in: Regenerate.
18955 * configure: Regenerate.
889bf7c5 18956
4168d2d6
UW
189572009-09-27 Ulrich Weigand <uweigand@de.ibm.com>
18958
18959 * spu-low.c (spu_kill): Wait for inferior to terminate.
18960 Call clear_inferiors.
18961 (spu_detach): Call clear_inferiors.
18962
81ecdfbb
RW
189632009-08-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
18964
18965 * aclocal.m4: Regenerate.
18966 * config.in: Likewise.
18967 * configure: Likewise.
18968
0b9ff2c0
UW
189692009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
18970
18971 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Define.
18972 (parse_spufs_run): New function.
18973 (ppc_get_pc, ppc_set_pc): Detect and handle SPU PC.
18974 (ppc_breakpoint_at): Handle SPU breakpoints.
18975
efcbbd14
UW
189762009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
18977
18978 * linux-low.c: Include <sys/stat.h> and <sys/vfs.h>.
18979 (SPUFS_MAGIC): Define.
18980 (spu_enumerate_spu_ids): New function.
18981 (linux_qxfer_spu): New function.
18982 (linux_target_ops): Install linux_qxfer_spu.
18983
f4d9bade
UW
189842009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
18985
18986 * configure.srv (powerpc*-*-linux*): Add powerpc-cell32l.o
18987 and powerpc-cell64l.o to srv_regobj. Add rs6000/powerpc-cell32l.xml
18988 and rs6000/powerpc-cell64l.xml to srv_xmlfiles.
18989 * Makefile.in (powerpc-cell32l.o, powerpc-cell32l.c): New rules.
18990 (powerpc-cell64l.o, powerpc-cell64l.c): Likewise.
18991 (clean): Handle powerpc-cell32l.c and powerpc-cell64l.c.
18992 * linux-ppc-low.c (PPC_FEATURE_CELL): Define.
18993 (init_registers_powerpc_cell32l): Add prototype.
18994 (init_registers_powerpc_cell64l): Likewise.
18995 (ppc_arch_setup): Detect Cell/B.E. architecture.
18996
96e946ca
RW
189972009-07-30 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
18998
18999 * Makefile.in (datarootdir): New variable.
19000
58d6951d
DJ
190012009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
19002
19003 * linux-low.c (linux_write_memory): Update debugging output.
19004 * Makefile.in (clean): Add new descriptions.
19005 (arm-with-vfpv2.o, arm-with-vfpv2.c, arm-with-vfpv3.o)
19006 (arm-with-vfpv3.c, arm-with-neon.o, arm-with-neon.c): New rules.
19007 * configure.srv: Add new files for arm*-*-linux*.
19008 * linux-arm-low.c: Add new declarations.
19009 (PTRACE_GETVFPREGS, PTRACE_SETVFPREGS): Define if undefined.
19010 (arm_hwcap, HWCAP_VFP, HWCAP_IWMMXT, HWCAP_NEON, HWCAP_VFPv3)
19011 (HWCAP_VFPv3D16): New.
19012 (arm_fill_wmmxregset, arm_store_wmmxregset): Check HWCAP_IWMMXT
19013 instead of __IWMMXT__.
19014 (arm_fill_vfpregset, arm_store_vfpregset, arm_get_hwcap)
19015 (arm_arch_setup): New.
19016 (target_regsets): Remove #ifdef. Add VFP regset.
19017 (the_low_target): Use arm_arch_setup.
19018
12b42a12
DJ
190192009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
19020
19021 * linux-low.c (linux_kill_one_lwp): Adjust kernel workaround to skip
19022 the main thread again.
19023
ac8c974e
AR
190242009-07-06 Aleksandar Ristovski <aristovski@qnx.com>
19025
19026 Adding Neutrino gdbserver.
19027 * configure: Regenerated.
19028 * configure.ac: Add case for srv_qnx and set LIBS accordingly.
19029 * configure.srv (i[34567]86-*-nto*): New target.
19030 * nto-low.c, nto-low.h, nto-x86-low.c: New files.
19031 * remote-utils.c [__QNX__]: Include sys/iomgr.h
19032 (nto_comctrl) [__QNX__]: New function.
19033 (enable_async_io, disable_async_io) [__QNX__]: Call nto_comctrl.
19034
4424e0c3 190352009-07-05 Danny Backx <dannybackx@users.sourceforge.net>
7437790a
PA
19036
19037 * configure.srv (i[34567]86-*-mingw32ce*): Add i386-low.o to
19038 srv_tgtobj.
19039
912cf4ba
PA
190402009-07-04 Danny Backx <dannybackx@users.sourceforge.net>
19041 Pedro Alves <pedro@codesourcery.com>
19042
19043 * win32-i386-low.c (i386_get_thread_context): Handle systems that
19044 don't support CONTEXT_EXTENDED_REGISTERS.
19045 (i386_win32_breakpoint, i386_win32_breakpoint_len): New.
19046 (the_low_target): Install them.
19047 * win32-low.c (get_child_debug_event): Handle WaitForDebugEvent
19048 failing with ERROR_PIPE_NOT_CONNECTED.
19049
aa5ca48f
DE
190502009-06-30 Doug Evans <dje@google.com>
19051 Pierre Muller <muller@ics.u-strasbg.fr>
19052
19053 Add h/w watchpoint support to x86-linux, win32-i386.
19054 * Makefile.in (SFILES): Add i386-low.c
19055 (i386_low_h): Define.
19056 (i386-low.o): Add dependencies.
19057 (linux-x86-low.o): Add i386-low.h dependency.
19058 (win32-i386-low.o): Ditto.
19059 * i386-low.c: New file.
19060 * i386-low.h: New file.
19061 * configure.srv (i[34567]86-*-cygwin*): Add i386-low.o to srv_tgtobj.
19062 (i[34567]86-*-linux*, i[34567]86-*-mingw*, x86_64-*-linux*): Ditto.
19063 * linux-low.c (linux_add_process): Initialize arch_private.
19064 (linux_remove_process): Free arch_private.
19065 (add_lwp): Initialize arch_private.
19066 (delete_lwp): Free arch_private.
19067 (linux_resume_one_lwp): Call the_low_target.prepare_to_resume if
19068 provided.
19069 * linux-low.h (process_info_private): New member arch_private.
19070 (lwp_info): New member arch_private.
19071 (linux_target_ops): New members new_process, new_thread,
19072 prepare_to_resume.
19073 (ptid_of): New macro.
19074 * linux-x86-low.c: Include stddef.h, i386-low.h.
19075 (arch_process_info): New struct.
19076 (arch_lwp_info): New struct.
19077 (x86_linux_dr_get, x86_linux_dr_set): New functions.
19078 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
19079 (i386_dr_low_get_status): New function.
19080 (x86_insert_point, x86_remove_point): New functions.
19081 (x86_stopped_by_watchpoint): New function.
19082 (x86_stopped_data_address): New function.
19083 (x86_linux_new_process, x86_linux_new_thread): New functions.
19084 (x86_linux_prepare_to_resume): New function.
19085 (the_low_target): Add entries for insert_point, remove_point,
19086 stopped_by_watchpoint, stopped_data_address, new_process, new_thread,
19087 prepare_to_resume.
19088 * server.c (debug_hw_points): New global.
19089 (monitor_show_help): Document set debug-hw-points.
19090 (handle_query): Process "set debug-hw-points".
19091 * server.h (debug_hw_points): Declare.
19092 (paddress): Declare.
19093 * utils.c (NUMCELLS, CELLSIZE): New macros.
19094 (get_sell, xsnprintf, paddress): New functions.
19095 * win32-arm-low.c (the_low_target): Add entries for insert_point,
19096 remove_point, stopped_by_watchpoint, stopped_data_address.
19097 * win32-i386-low.c: Include i386-low.h.
19098 (debug_reg_state): Replaces dr.
19099 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
19100 (i386_dr_low_get_status): New function.
19101 (i386_insert_point, i386_remove_point): New functions.
19102 (i386_stopped_by_watchpoint): New function.
19103 (i386_stopped_data_address): New function.
19104 (i386_initial_stuff): Update.
19105 (get_thread_context,set_thread_context,i386_thread_added): Update.
19106 (the_low_target): Add entries for insert_point,
19107 remove_point, stopped_by_watchpoint, stopped_data_address.
19108 * win32-low.c (win32_insert_watchpoint): New function.
19109 (win32_remove_watchpoint): New function.
19110 (win32_stopped_by_watchpoint): New function.
19111 (win32_stopped_data_address): New function.
19112 (win32_target_ops): Add entries for insert_watchpoint,
19113 remove_watchpoint, stopped_by_watchpoint, stopped_data_address.
19114 * win32-low.h (win32_target_ops): New members insert_point,
19115 remove_point, stopped_by_watchpoint, stopped_data_address.
19116
d993e290
PA
191172009-06-25 Pedro Alves <pedro@codesourcery.com>
19118
19119 * server.c (process_serial_event): Re-return unsupported, not
19120 error, if the type isn't recognized. Re-allow supporting only
19121 insert or remove packets. Also call require_running for
19122 breakpoints. Add missing break statement to default case. Tidy.
19123 * target.h (struct target_ops): Rename insert_watchpoint to
19124 insert_point, and remove_watchpoint to remove_point.
19125
19126 * linux-low.h (struct linux_target_ops): Likewise.
19127 * linux-low.c (linux_insert_watchpoint): Rename to ...
19128 (linux_insert_point): ... this. Adjust.
19129 (linux_remove_watchpoint): Rename to ...
19130 (linux_remove_point): ... this. Adjust.
19131 (linux_target_ops): Adjust.
19132 * linux-crisv32-low.c (cris_insert_watchpoint): Rename to ...
19133 (cris_insert_point): ... this.
19134 (cris_remove_watchpoint): Rename to ...
19135 (cris_remove_point): ... this.
19136 (the_low_target): Adjust.
19137
0f54c268
PM
191382009-06-24 Pierre Muller <muller@ics.u-strasbg.fr>
19139
19140 * server.c (handle_v_kill): Pass signal_pid to
19141 kill_inferior if multi_process is zero.
19142
c6314022
AR
191432009-06-23 Aleksandar Ristovski <aristovski@qnx.com>
19144
19145 * server.c (process_serial_event): Add support for Z0 and Z1 packet.
19146 * target.h (target_ops): Comment for *_watchpoint to make it clear
19147 the functions can get types '0' and '1'.
19148
4463ce24
AR
191492009-06-22 Aleksandar Ristovski <aristovski@qnx.com>
19150
19151 * linux-low.c (usr_fetch_inferior_registers): Remove check for regno 0.
19152 * proc-service.c (ps_lgetregs): Pass -1 to fetch all registers.
19153 * regcache.c (get_regcache): Likewise.
19154 * spu-low.c (spu_fetch_registers): Remove 0 to -1 conversion.
19155 * win32-low.c (child_fetch_inferior_registers): Remove check for
19156 regno 0.
19157
cf8fd78b
PA
191582009-06-19 Aleksandar Ristovski <aristovski@qnx.com>
19159 Pedro Alves <pedro@codesourcery.com>
19160
19161 * target.h (struct target_ops) <supports_multi_process>: New
19162 callback.
19163 (target_supports_multi_process): New.
19164 * server.c (handle_query): Even if GDB reports support, only
19165 enable multi-process if the target also supports it. Report
19166 multi-process support only if the target backend supports it.
19167 * linux-low.c (linux_supports_multi_process): New function.
19168 (linux_target_ops): Install it as target_supports_multi_process
19169 callback.
19170
47c0c975
DE
191712009-05-24 Doug Evans <dje@google.com>
19172
e09875d4
DE
19173 Global renaming of find_thread_pid to find_thread_ptid.
19174 * server.h (find_thread_ptid): Renamed from find_thread_pid.
19175 * inferiors.c (find_thread_ptid): Renamed from find_thread_pid.
19176 All callers updated.
19177
e27d73f6
DE
19178 * linux-low.c (handle_extended_wait): Use linux_resume_one_lwp
19179 to resume the newly created thread, don't call ptrace (PTRACE_CONT)
19180 directly.
19181
47c0c975
DE
19182 * linux-low.c (get_stop_pc): Print pc if debug_threads.
19183 (check_removed_breakpoint, linux_wait_for_lwp): Ditto.
19184 (linux_resume_one_lwp): Ditto.
19185
2acc282a
DE
191862009-05-23 Doug Evans <dje@google.com>
19187
19188 * linux-low.c (linux_resume_one_lwp): Change type of first arg
19189 from struct inferior_list_entry * to struct lwp_info *.
19190 All callers updated.
19191
9f1036c1
DE
191922009-05-13 Doug Evans <dje@google.com>
19193
19194 * linux-x86-low.c: Don't include assert.h.
19195 (x86_siginfo_fixup): Use fatal, not assert.
19196 (x86_arch_setup): Fix comment.
19197
d0722149
DE
191982009-05-12 Doug Evans <dje@google.com>
19199
19200 Biarch support for i386/amd64 gdbserver.
19201 * Makefile.in (SFILES): Remove linux-i386-low.c, linux-x86-64-low.c.
19202 Add linux-x86-low.c.
19203 (linux-i386-low.o, linux-x86-64-low.o): Delete.
19204 (linux-x86-low.o): Add.
19205 * linux-x86-64-low.c: Delete.
19206 * linux-i386-low.c: Delete.
19207 * linux-x86-low.c: New file.
19208 * configure.srv (i?86-linux srv_tgtobj): Replace linux-i386-low.o with
19209 linux-x86-low.o.
19210 (x86_64-linux srv_tgtobj): Replace linux-x86-64-low.o with
19211 linux-x86-low.o.
19212 (x86_64-linux srv_regobj): Add reg-i386-linux.o.
19213 * linux-low.c: Include ansidecl.h, elf/common.h, elf/external.h.
19214 (linux_child_pid_to_exec_file): New function.
19215 (elf_64_header_p, elf_64_file_p): New functions.
19216 (siginfo_fixup): New function.
19217 (linux_xfer_siginfo): New local inf_siginfo. Call siginfo_fixup to
19218 give target a chance to convert layout.
19219 * linux-low.h (linux_target_ops): New member siginfo_fixup.
19220 (linux_child_pid_to_exec_file, elf_64_file_p): Declare.
19221
fdeb2a12
DE
192222009-05-07 Doug Evans <dje@google.com>
19223
19224 * linux-low.c (regsets_fetch_inferior_registers): Fix memory leak.
19225 (regsets_store_inferior_registers): Ditto.
19226
a6dbe5df
PA
192272009-05-06 Pedro Alves <pedro@codesourcery.com>
19228
19229 PR server/10048
19230
19231 * linux-low.c (must_set_ptrace_flags): Delete.
19232 (linux_create_inferior): Set `lwp->must_set_ptrace_flags' instead
19233 of the global.
19234 (linux_attach_lwp_1): Don't set PTRACE_SETOPTIONS here. Set
19235 `lwp->must_set_ptrace_flags' instead.
ba42693b 19236 (linux_wait_for_event_1): Set ptrace options here.
a6dbe5df
PA
19237 (linux_wait_1): ... not here.
19238
5091eb23
DE
192392009-04-30 Doug Evans <dje@google.com>
19240
9f767825
DE
19241 * inferiors.c (started_inferior_callback): New function.
19242 (attached_inferior_callback): New function.
19243 (have_started_inferiors_p, have_attached_inferiors_p): New functions.
19244 * server.c (print_started_pid, print_attached_pid): New functions.
19245 (detach_or_kill_for_exit): New function.
19246 (main): Call it instead of for_each_inferior (kill_inferior_callback).
19247 * server.h (have_started_inferiors_p): Declare.
19248 (have_attached_inferiors_p): Declare.
19249
5091eb23
DE
19250 * inferiors.c (remove_process): Fix memory leak, free process.
19251 * linux-low.c (linux_remove_process): New function.
19252 (linux_kill): Call it instead of remove_process.
19253 (linux_detach, linux_wait_1): Ditto.
19254
155c8968
PA
192552009-04-19 Danny Backx <dannybackx@users.sourceforge.net>
19256
19257 * configure.srv: Add x86 Windows CE target.
19258
7fe519cb
UW
192592009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
19260
19261 * inferiors.c (get_thread_process): Make global.
19262 * server.h (get_thread_process): Add prototype.
19263 * thread-db.c (find_one_thread): Use get_thread_process
19264 instead of current_process.
19265 (thread_db_get_tls_address): Do not crash if called when
19266 thread layer is not yet initialized.
19267
5472f405
UW
192682009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
19269
19270 * remote-utils.c (prepare_resume_reply): Null-terminate packet.
19271 * spu-low.c (current_tid): Rename to ...
19272 (current_ptid): ... this.
19273 (fetch_ppc_register, fetch_ppc_memory, store_ppc_memory,
19274 spu_proc_xfer_spu, spu_resume, spu_request_interrupt): Use
19275 ptid_get_lwp (current_ptid) instead of current_tid.
19276 (spu_kill, spu_detach, spu_join, spu_wait): Use pid argument
19277 instead of current_tid. Use find_process_pid to verify pid
19278 argument is valid. Pass proper argument to remove_process.
19279 (spu_thread_alive): Compare current_ptid instead of current_tid.
19280 (spu_resume): Likewise.
19281
55ac2b99
PA
192822009-04-02 Pedro Alves <pedro@codesourcery.com>
19283
19284 * linux-low.c (usr_store_inferior_registers): Declare local `pid'
19285 variable.
19286
95954743
PA
192872009-04-01 Pedro Alves <pedro@codesourcery.com>
19288
19289 Implement the multiprocess extensions, and add linux multiprocess
19290 support.
19291
19292 * server.h (ULONGEST): Declare.
19293 (struct ptid, ptid_t): New.
19294 (minus_one_ptid, null_ptid): Declare.
19295 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
19296 (ptid_get_tid, ptid_equal, ptid_is_pid): Declare.
19297 (struct inferior_list_entry): Change `id' type from unsigned from
19298 to ptid_t.
19299 (struct sym_cache, struct breakpoint, struct
19300 process_info_private): Forward declare.
19301 (struct process_info): Declare.
19302 (current_process): Declare.
19303 (all_processes): Declare.
19304 (initialize_inferiors): Declare.
19305 (add_thread): Adjust to use ptid_t.
19306 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): Ditto.
19307 (add_process, remove_process, find_thread_pid): Declare.
19308 (find_inferior_id): Adjust to use ptid_t.
19309 (cont_thread, general_thread, step_thread): Change type to ptid_t.
19310 (multi_process): Declare.
19311 (push_event): Adjust to use ptid_t.
19312 (read_ptid, write_ptid): Declare.
19313 (prepare_resume_reply): Adjust to use ptid_t.
19314 (clear_symbol_cache): Declare.
19315 * inferiors.c (all_processes): New.
19316 (null_ptid, minus_one_ptid): New.
19317 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
19318 (ptid_get_tid, ptid_equal, ptid_is_pid): New.
19319 (add_thread): Change unsigned long to ptid. Remove gdb_id
19320 parameter. Adjust.
19321 (thread_id_to_gdb_id, thread_to_gdb_id): Change unsigned long to ptid.
19322 (gdb_id_to_thread): Rename to ...
19323 (find_thread_pid): ... this. Change unsigned long to ptid.
19324 (gdb_id_to_thread_id, find_inferior_id): Change unsigned long to ptid.
19325 (loaded_dll, pull_pid_from_list): Adjust.
19326 (add_process, remove_process, find_process_pid)
19327 (get_thread_process, current_process, initialize_inferiors): New.
19328 * target.h (struct thread_resume) <thread>: Change type to ptid_t.
19329 (struct target_waitstatus) <related_pid>: Ditto.
19330 (struct target_ops) <kill, detach>: Add `pid' argument. Change
19331 return type to int.
19332 (struct target_ops) <join>: Add `pid' argument.
19333 (struct target_ops) <thread_alive>: Change pid's type to ptid_t.
19334 (struct target_ops) <wait>: Add `ptid' field. Change return type
19335 to ptid.
19336 (kill_inferior, detach_inferior, join_inferior): Add `pid' argument.
19337 (mywait): Add `ptid' argument. Change return type to ptid_t.
19338 (target_pid_to_str): Declare.
19339 * target.c (set_desired_inferior): Adjust to use ptids.
19340 (mywait): Add new `ptid' argument. Adjust.
19341 (target_pid_to_str): New.
19342 * mem-break.h (free_all_breakpoints): Declare.
19343 * mem-break.c (breakpoints): Delelete.
19344 (set_breakpoint_at, delete_breakpoint, find_breakpoint_at)
19345 (check_mem_read, check_mem_write, delete_all_breakpoints): Adjust
19346 to use per-process breakpoint list.
19347 (free_all_breakpoints): New.
19348 * remote-utils.c (struct sym_cache) <name>: Drop `const'.
19349 (symbol_cache, all_symbols_looked_up): Delete.
19350 (hexchars): New.
19351 (ishex, unpack_varlen_hex, write_ptid, hex_or_minus_one,
19352 read_ptid): New.
19353 (prepare_resume_reply): Change ptid argument's type from unsigned
19354 long to ptid_t. Adjust. Implement W;process and X;process.
19355 (free_sym_cache, clear_symbol_cache): New.
19356 (look_up_one_symbol): Adjust to per-process symbol cache. *
19357 * server.c (cont_thread, general_thread, step_thread): Change type
19358 to ptid_t.
19359 (attached): Delete.
19360 (multi_process): New.
19361 (last_ptid): Change type to ptid_t.
19362 (struct vstop_notif) <ptid>: Change type to ptid_t.
19363 (queue_stop_reply, push_event): Change `ptid' argument's type to
19364 ptid_t.
19365 (discard_queued_stop_replies): Add `pid' argument.
19366 (start_inferior): Adjust to use ptids. Adjust to mywait interface
19367 changes. Don't reference the `attached' global.
19368 (attach_inferior): Adjust to mywait interface changes.
19369 (handle_query): Adjust to use ptids. Parse GDB's qSupported
19370 features. Handle and report "multiprocess+". Handle
19371 "qAttached:PID".
19372 (handle_v_cont): Adjust to use ptids. Adjust to mywait interface
19373 changes.
19374 (handle_v_kill): New.
19375 (handle_v_stopped): Adjust to use target_pid_to_str.
19376 (handle_v_requests): Allow multiple attaches and runs when
19377 multiprocess extensions are in effect. Handle "vKill".
19378 (myresume): Adjust to use ptids.
19379 (queue_stop_reply_callback): Add `arg' parameter. Handle it.
19380 (handle_status): Adjust to discard_queued_stop_replies interface
19381 change.
19382 (first_thread_of, kill_inferior_callback)
19383 (detach_or_kill_inferior_callback, join_inferiors_callback): New.
19384 (main): Call initialize_inferiors. Adjust to use ptids, killing
19385 and detaching from all inferiors. Handle multiprocess packet
19386 variants.
19387 * linux-low.h: Include gdb_proc_service.h.
19388 (struct process_info_private): New.
19389 (struct linux_target_ops) <pid_of>: Use ptid_get_pid.
19390 <lwpid_of>: Use ptid_get_lwp.
19391 (get_lwp_thread): Adjust.
19392 (struct lwp_info): Add `dead' member.
19393 (find_lwp_pid): Declare.
19394 * linux-low.c (thread_db_active): Delete.
19395 (new_inferior): Adjust comment.
19396 (inferior_pid): Delete.
19397 (linux_add_process): New.
19398 (handle_extended_wait): Adjust.
19399 (add_lwp): Change unsigned long to ptid.
19400 (linux_create_inferior): Add process to processes table. Adjust
19401 to use ptids. Don't set new_inferior here.
19402 (linux_attach_lwp): Rename to ...
19403 (linux_attach_lwp_1): ... this. Add `initial' argument. Handle
19404 it. Adjust to use ptids.
19405 (linux_attach_lwp): New.
19406 (linux_attach): Add process to processes table. Don't set
19407 new_inferior here.
19408 (struct counter): New.
19409 (second_thread_of_pid_p, last_thread_of_process_p): New.
19410 (linux_kill_one_lwp): Add `args' parameter. Handle it. Adjust to
19411 multiple processes.
19412 (linux_kill): Add `pid' argument. Handle it. Adjust to multiple
19413 processes. Remove process from process table.
19414 (linux_detach_one_lwp): Add `args' parameter. Handle it. Adjust
19415 to multiple processes.
19416 (any_thread_of): New.
19417 (linux_detach): Add `pid' argument, and handle it. Remove process
19418 from processes table.
19419 (linux_join): Add `pid' argument. Handle it.
19420 (linux_thread_alive): Change unsighed long argument to ptid_t.
19421 Consider dead lwps as not being alive.
19422 (status_pending_p): Rename `dummy' argument to `arg'. Filter out
19423 threads we're not interested in.
19424 (same_lwp, find_lwp_pid): New.
19425 (linux_wait_for_lwp): Change `pid' argument's type from int to
19426 ptid_t. Adjust.
19427 (linux_wait_for_event): Rename to ...
19428 (linux_wait_for_event_1): ... this. Change `pid' argument's type
19429 from int to ptid_t. Adjust.
19430 (linux_wait_for_event): New.
19431 (linux_wait_1): Add `ptid' argument. Change return type to
19432 ptid_t. Adjust. Use last_thread_of_process_p. Remove processes
19433 that exit from the process table.
19434 (linux_wait): Add `ptid' argument. Change return type to ptid_t.
19435 Adjust.
19436 (mark_lwp_dead): New.
19437 (wait_for_sigstop): Adjust to use ptids. If a process exits while
19438 stopping all threads, mark its main lwp as dead.
19439 (linux_set_resume_request, linux_resume_one_thread): Adjust to use
19440 ptids.
19441 (fetch_register, usr_store_inferior_registers)
19442 (regsets_fetch_inferior_registers)
19443 (regsets_store_inferior_registers, linux_read_memory)
19444 (linux_write_memory): Inline `inferior_pid'.
19445 (linux_look_up_symbols): Adjust to use per-process
19446 `thread_db_active'.
19447 (linux_request_interrupt): Adjust to use ptids.
19448 (linux_read_auxv): Inline `inferior_pid'.
19449 (initialize_low): Don't reference thread_db_active.
19450 * gdb_proc_service.h (struct ps_prochandle) <pid>: Remove.
19451 * proc-service.c (ps_lgetregs): Use find_lwp_pid.
19452 (ps_getpid): Return the pid of the current inferior.
19453 * thread-db.c (proc_handle, thread_agent): Delete.
19454 (thread_db_create_event, thread_db_enable_reporting): Adjust to
19455 per-process data.
19456 (find_one_thread): Change argument type to ptid_t. Adjust to
19457 per-process data.
19458 (maybe_attach_thread): Adjust to per-process data and ptids.
19459 (thread_db_find_new_threads): Ditto.
19460 (thread_db_init): Ditto.
19461 * spu-low.c (spu_create_inferior, spu_attach): Add process to
19462 processes table. Adjust to use ptids.
19463 (spu_kill, spu_detach): Adjust interface. Remove process from
19464 processes table.
19465 (spu_join, spu_thread_alive): Adjust interface.
19466 (spu_wait): Adjust interface. Remove process from processes
19467 table. Adjust to use ptids.
19468 * win32-low.c (current_inferior_tid): Delete.
19469 (current_inferior_ptid): New.
19470 (debug_event_ptid): New.
19471 (thread_rec): Take a ptid. Adjust.
19472 (child_add_thread): Add `pid' argument. Adjust to use ptids.
19473 (child_delete_thread): Ditto.
19474 (do_initial_child_stuff): Add `attached' argument. Add process to
19475 processes table.
19476 (child_fetch_inferior_registers, child_store_inferior_registers):
19477 Adjust.
19478 (win32_create_inferior): Pass 0 to do_initial_child_stuff.
19479 (win32_attach): Pass 1 to do_initial_child_stuff.
19480 (win32_kill): Adjust interface. Remove process from processes
19481 table.
19482 (win32_detach): Ditto.
19483 (win32_join): Adjust interface.
19484 (win32_thread_alive): Take a ptid.
19485 (win32_resume): Adjust to use ptids.
19486 (get_child_debug_event): Ditto.
19487 (win32_wait): Adjust interface. Remove exiting process from
19488 processes table.
19489
bd99dc85
PA
194902009-04-01 Pedro Alves <pedro@codesourcery.com>
19491
19492 Non-stop mode support.
19493
19494 * server.h (non_stop): Declare.
19495 (gdb_client_data, handler_func): Declare.
19496 (delete_file_handler, add_file_handler, start_event_loop):
19497 Declare.
19498 (handle_serial_event, handle_target_event, push_event)
19499 (putpkt_notif): Declare.
19500 * target.h (enum resume_kind): New.
19501 (struct thread_resume): Replace `step' field by `kind' field.
19502 (TARGET_WNOHANG): Define.
19503 (struct target_ops) <wait>: Add `options' argument.
19504 <supports_non_stop, async, start_non_stop>: New fields.
19505 (target_supports_non_stop, target_async): New.
19506 (start_non_stop): Declare.
19507 (mywait): Add `options' argument.
19508 * target.c (mywait): Add `options' argument. Print child exit
19509 notifications here.
19510 (start_non_stop): New.
19511 * server.c (non_stop, own_buf, mem_buf): New globals.
19512 (struct vstop_notif): New.
19513 (notif_queue): New global.
19514 (queue_stop_reply, push_event, discard_queued_stop_replies)
19515 (send_next_stop_reply): New.
19516 (start_inferior): Adjust to use resume_kind. Adjust to mywait
19517 interface changes.
19518 (attach_inferior): In non-stop mode, don't wait for the target
19519 here.
19520 (handle_general_set): Handle QNonStop.
19521 (handle_query): When handling qC, return the current general
19522 thread, instead of the first thread of the list.
19523 (handle_query): If the backend supports non-stop mode, include
19524 QNonStop+ in the qSupported query response.
19525 (handle_v_cont): Adjust to use resume_kind. Handle resume_stop
19526 and non-stop mode.
19527 (handle_v_attach, handle_v_run): Handle non-stop mode.
19528 (handle_v_stopped): New.
19529 (handle_v_requests): Report support for vCont;t. Handle vStopped.
19530 (myresume): Adjust to use resume_kind. Handle non-stop.
19531 (queue_stop_reply_callback): New.
19532 (handle_status): Handle non-stop mode.
19533 (main): Clear non_stop flag on reconnection. Use the event-loop.
19534 Refactor serial protocol handling from here ...
19535 (process_serial_event): ... to this new function. When GDB
19536 selects any thread, select one here. In non-stop mode, wait until
19537 GDB acks all pending events before exiting.
19538 (handle_serial_event, handle_target_event): New.
19539 * remote-utils.c (remote_open): Install remote_desc in the event
19540 loop.
19541 (remote_close): Remove remote_desc from the event loop.
19542 (putpkt_binary): Rename to...
19543 (putpkt_binary_1): ... this. Add `is_notic' argument. Handle it.
19544 (putpkt_binary): New as wrapper around putpkt_binary_1.
19545 (putpkt_notif): New.
19546 (prepare_resume_reply): In non-stop mode, don't change the
19547 general_thread.
19548 * event-loop.c: New.
19549 * Makefile.in (OBJ): Add event-loop.o.
19550 (event-loop.o): New rule.
19551
19552 * linux-low.h (pid_of): Moved here.
19553 (lwpid_of): New.
19554 (get_lwp_thread): Use lwpid_of.
19555 (struct lwp_info): Delete `lwpid' field. Add `suspended' field.
19556 * linux-low.c (pid_of): Delete.
19557 (inferior_pid): Use lwpid_of.
19558 (linux_event_pipe): New.
19559 (target_is_async_p): New.
19560 (delete_lwp): New.
19561 (handle_extended_wait): Use lwpid_of.
19562 (add_lwp): Don't set lwpid field.
19563 (linux_attach_lwp): Adjust debug output. Use lwpid_of.
19564 (linux_kill_one_lwp): If killing a running lwp, stop it first.
19565 Use lwpid_of. Adjust to linux_wait_for_event interface changes.
19566 (linux_detach_one_lwp): If detaching from a running lwp, stop it
19567 first. Adjust to linux_wait_for_event interface changes. Use
19568 lwpid_of.
19569 (linux_detach): Don't delete the main lwp here.
19570 (linux_join): Use my_waitpid. Avoid signal_pid. Use lwpid_of.
19571 (status_pending_p): Don't consider explicitly suspended lwps.
19572 (linux_wait_for_lwp): Take an integer pid instead of a lwp_info
19573 pointer. Add OPTIONS argument. Change return type to int. Use
19574 my_waitpid instead of sleeping. Handle WNOHANG. Use lwpid_of.
19575 (linux_wait_for_event): Take an integer pid instead of a lwp_info
19576 pointer. Add status pointer argument. Return a pid instead of a
19577 status. Use lwpid_of. Adjust to linux_wait_for_lwp interface
19578 changes. In non-stop mode, don't switch to a random thread.
19579 (linux_wait): Rename to...
19580 (linux_wait_1): ... this. Add target_options argument, and handle
19581 it. Adjust to use resume_kind. Use lwpid_of. In non-stop mode,
19582 don't handle the continue thread. Handle TARGET_WNOHANG. Merge
19583 clean exit and signal exit code. Don't stop all threads in
19584 non-stop mode. In all-stop mode, only stop all threads when
19585 reporting a stop to GDB. Handle explicit thread stop requests.
19586 (async_file_flush, async_file_mark): New.
19587 (linux_wait): New.
19588 (send_sigstop): Use lwpid_of.
19589 (wait_for_sigstop): Use lwpid_of. Adjust to linux_wait_for_event
19590 interface changes. In non-stop mode, don't switch to a random
19591 thread.
19592 (linux_resume_one_lwp): Use lwpid_of.
19593 (linux_continue_one_thread, linux_queue_one_thread): Merge into ...
19594 (linux_resume_one_thread): ... this. Handle resume_stop. In
19595 non-stop mode, don't look for pending flag in all threads.
19596 (resume_status_pending_p): Don't consider explicitly suspended
19597 threads.
19598 (my_waitpid): Reimplement. Emulate __WALL.
19599 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
19600 Use lwpid_of.
19601 (sigchld_handler, linux_supports_non_stop, linux_async)
19602 (linux_start_non_stop): New.
19603 (linux_target_ops): Register linux_supports_non_stop, linux_async
19604 and linux_start_non_stop.
19605 (initialize_low): Install SIGCHLD handler.
19606 * thread-db.c (thread_db_create_event, find_one_thread)
19607 (thread_db_get_tls_address): Use lwpid_of.
19608 * win32-low.c (win32_detach): Adjust to use resume_kind.
19609 (win32_wait): Add `options' argument.
19610 * spu-low.c (spu_resume): Adjust to use resume_kind.
19611 (spu_wait): Add `options' argument.
19612
5b1c542e
PA
196132009-04-01 Pedro Alves <pedro@codesourcery.com>
19614
19615 Decouple target code from remote protocol.
19616
19617 * target.h (enum target_waitkind): New.
19618 (struct target_waitstatus): New.
19619 (struct target_ops) <wait>: Return an unsigned long. Take a
19620 target_waitstatus pointer instead of a char pointer.
19621 (mywait): Likewise.
19622 * target.c (mywait): Change prototype to return an unsigned long.
19623 Take a target_waitstatus pointer instead of a char pointer. Adjust.
19624 * server.h (thread_from_wait, old_thread_from_wait): Delete
19625 declarations.
19626 (prepare_resume_reply): Change prototype to take a
19627 target_waitstatus.
19628 * server.c (thread_from_wait, old_thread_from_wait): Delete.
19629 (last_status, last_ptid): New.
19630 (start_inferior): Remove "statusptr" argument. Adjust. Return a
19631 pid instead of a signal.
19632 (attach_inferior): Remove "status" and "signal" parameters.
19633 Adjust.
19634 (handle_query): For qGetTLSAddr, parse the thread id with strtol,
19635 not as an address.
19636 (handle_v_cont, handle_v_attach, handle_v_run, handle_v_kill)
19637 (handle_v_requests, myresume): Remove "status" and "signal"
19638 parameters. Adjust.
19639 (handle_status): New.
19640 (main): Delete local `status'. Adjust.
19641 * remote-utils.c: Include target.h.
19642 (prepare_resume_reply): Change prototype to take a
19643 target_waitstatus. Adjust.
19644
19645 * linux-low.c (linux_wait): Adjust to new target_ops->wait
19646 interface.
19647 * spu-low.c (spu_wait): Adjust.
19648 * win32-low.c (enum target_waitkind, struct target_waitstatus):
19649 Delete.
19650 (win32_wait): Adjust.
19651
2bd7c093
PA
196522009-04-01 Pedro Alves <pedro@codesourcery.com>
19653
19654 * target.h (struct thread_resume): Delete leave_stopped member.
19655 (struct target_ops): Add a `n' argument to the `resume' callback.
19656 * server.c (start_inferior): Adjust.
19657 (handle_v_cont, myresume): Adjust.
19658 * linux-low.c (check_removed_breakpoint): Adjust to resume
19659 interface change, and to removed leave_stopped field.
19660 (resume_ptr): Delete.
19661 (struct thread_resume_array): New.
19662 (linux_set_resume_request): Add new `arg' parameter. Adjust to
19663 resume interface change.
19664 (linux_continue_one_thread, linux_queue_one_thread)
19665 (resume_status_pending_p): Check if the resume field is NULL
19666 instead of checking the leave_stopped member.
19667 (linux_resume): Adjust to the target resume interface change.
19668 * spu-low.c (spu_resume): Adjust to the target resume interface
19669 change.
19670 * win32-low.c (win32_detach, win32_resume): Ditto.
19671
c35fafde
PA
196722009-04-01 Pedro Alves <pedro@codesourcery.com>
19673
19674 * linux-low.c (linux_wait_for_event): Don't clear the `stepping'
19675 flag.
19676 (wait_for_sigstop): Don't leave a finished single-step SIGTRAP
19677 pending.
19678 (linux_continue_one_thread): Only preserve the stepping flag if
19679 there's a pending breakpoint.
19680
0a59d50b
PA
196812009-03-31 Pedro Alves <pedro@codesourcery.com>
19682
19683 * server.c (main): After the inferior having exited, call
19684 remote_close before exiting gdbserver.
19685
f04c6d38
TJB
196862009-03-25 Thiago Jung Bauermann <bauerman@br.ibm.com>
19687
19688 Fix size of FPSCR in Power 7 processors.
19689 * linux-ppc-low.c (PPC_FEATURE_ARCH_2_05): Remove #define.
19690 (PPC_FEATURE_HAS_DFP): New #define.
19691 (ppc_arch_setup): Check for DFP feature instead of ISA 2.05 to decide on
19692 size of the FPSCR.
19693
78e5cee6
PA
196942009-03-23 Pedro Alves <pedro@codesourcery.com>
19695
19696 * server.c (handle_query) Whitespace and formatting.
19697
1b3f6016
PA
196982009-03-22 Pedro Alves <pedro@codesourcery.com>
19699
19700 * i387-fp.c, linux-arm-low.c, linux-cris-low.c,
19701 linux-crisv32-low.c, linux-i386-low.c, linux-low.c,
19702 linux-mips-low.c, linux-s390-low.c, linux-sparc-low.c,
19703 linux-x86-64-low.c, linux-xtensa-low.c, proc-service.c,
19704 regcache.c, remote-utils.c, server.c, spu-low.c, target.h,
19705 thread-db.c, win32-low.c, xtensa-xtregs.c, gdbreplay.c,
19706 Makefile.in, configure.ac: Fix whitespace throughout.
19707 * configure: Regenerate.
19708
a07b2135
PA
197092009-03-22 Pedro Alves <pedro@codesourcery.com>
19710
19711 * inferiors.c (find_inferior): Make it safe for the callback
19712 function to delete the currently iterated inferior.
19713
67cc2626
PA
197142009-03-22 Pedro Alves <pedro@codesourcery.com>
19715
19716 * Makefile.in (linuw_low_h): Move higher.
19717 (thread-db.o): Depend on $(linux_low_h).
19718
54a0b537
PA
197192009-03-17 Pedro Alves <pedro@codesourcery.com>
19720
19721 Rename "process" to "lwp" throughout.
19722
19723 * linux-low.c (all_processes): Rename to...
19724 (all_lwps): ... this.
19725 (inferior_pid, handle_extended_wait, get_stop_pc): Adjust.
19726 (add_process): Rename to ...
19727 (add_lwp): ... this. Adjust.
19728 (linux_create_inferior): Adjust.
19729 (linux_attach_lwp): Adjust.
19730 (linux_attach): Adjust.
19731 (linux_kill_one_process): Rename to ...
19732 (linux_kill_one_lwp): ... this. Adjust.
19733 (linux_kill): Adjust.
19734 (linux_detach_one_process): Rename to ...
19735 (linux_detach_one_lwp): ... this. Adjust.
19736 (linux_detach): Adjust.
19737 (check_removed_breakpoint): Adjust.
19738 (status_pending_p): Adjust.
19739 (linux_wait_for_process): Rename to ...
19740 (linux_wait_for_lwp): ... this. Adjust.
19741 (linux_wait_for_event): Adjust.
19742 (send_sigstop): Adjust.
19743 (wait_for_sigstop): Adjust.
19744 (stop_all_processes): Rename to ...
19745 (stop_all_lwps): ... this.
19746 (linux_resume_one_process): Rename to ...
19747 (linux_resume_one_lwp): ... this. Adjust.
19748 (linux_set_resume_request, linux_continue_one_thread)
19749 (linux_queue_one_thread, resume_status_pending_p)
19750 (usr_store_inferior_registers, regsets_store_inferior_registers)
19751 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
19752 Adjust.
19753 * linux-low.h (get_process): Rename to ...
19754 (get_lwp): ... this. Adjust.
19755 (get_thread_process): Rename to ...
19756 (get_thread_lwp): ... this. Adjust.
19757 (get_process_thread): Rename to ...
19758 (get_lwp_thread): ... this. Adjust.
19759 (struct process_info): Rename to ...
19760 (struct lwp_info): ... this.
19761 (all_processes): Rename to ...
19762 (all_lwps): ... this.
19763 * proc-service.c (ps_lgetregs): Adjust.
19764 * thread-db.c (thread_db_create_event, find_one_thread)
19765 (maybe_attach_thread, thread_db_get_tls_address): Adjust.
19766
0b16c5cf
PA
197672009-03-14 Pedro Alves <pedro@codesourcery.com>
19768
19769 * server.c (handle_query): Handle "qAttached".
19770
32de4b9d
NS
197712009-03-13 Nathan Sidwell <nathan@codesourcery.com>
19772
19773 * Makefile.in, hostio-errno.c, errno.c, xtensa-xtregs.c: Change to
19774 GPLv3, update license URL.
19775
2aecd87f
DE
197762009-03-01 Doug Evans <dje@google.com>
19777
93efd302 19778 * Makefile.in (INCLUDE_CFLAGS): Add -I$(srcdir)/../common.
2aecd87f
DE
19779 (server_h): Add gdb_signals.h.
19780 (signals.o): Update.
19781 * server.h (target_signal_from_host,target_signal_to_host_p)
19782 (target_signal_to_host,target_signal_to_name): Moved to gdb_signals.h.
19783
86b1f9c5
PM
197842009-02-14 Pierre Muller <muller@ics.u-strasbg.fr>
19785
19786 * remote-utils.c (getpkt): Also generate remote-debug
19787 information if noack_mode is set.
19788
4aa995e1
PA
197892009-02-06 Pedro Alves <pedro@codesourcery.com>
19790
19791 * server.c (handle_query): Report qXfer:siginfo:read and
19792 qXfer:siginfo:write as supported and handle them.
19793 * target.h (struct target_ops) <qxfer_siginfo>: New field.
19794 * linux-low.c (linux_xfer_siginfo): New.
19795 (linux_target_ops): Set it.
19796
62709adf
PA
197972009-01-26 Pedro Alves <pedro@codesourcery.com>
19798
19799 * server.c (gdbserver_usage): Mention --remote-debug.
19800 (main): Accept '--remote-debug' switch.
19801
aef93bd7
DE
198022009-01-18 Doug Evans <dje@google.com>
19803
19804 * regcache.c (new_register_cache): No need to check result of xcalloc.
19805 * server.c (handle_search_memory): Back out calls to xmalloc,
19806 result is checked and error is returned to user upon failure.
19807 (handle_query): Ditto. Add more checks for result of malloc.
19808 (handle_v_cont): Check result of malloc, report error back to
19809 user upon failure.
19810 (handle_v_run): Ditto. Call freeargv.
19811 * server.h (freeargv): Declare.
19812 * utils.c (freeargv): New fn.
19813
54363045
DE
198142009-01-15 Doug Evans <dje@google.com>
19815
f626972c
DE
19816 * gdbreplay.c (perror_with_name): Make arg const char *.
19817 * server.h (target_signal_to_name): Make return type const char *.
0842e787 19818 * thread-db.c (thread_db_err_str): Make return type const char *.
f626972c 19819 * utils.c (perror_with_name): Make arg const char *.
54363045 19820
18aae699
PA
198212009-01-14 Pedro Alves <pedro@codesourcery.com>
19822
19823 * win32-low.c (get_child_debug_event): Issue a final DBG_CONTINUE
19824 when handling a EXIT_PROCESS_DEBUG_EVENT.
19825
ff703abe
JB
198262009-01-06 Joel Brobecker <brobecker@adacore.com>
19827
19828 * gdbreplay.c (gdbreplay_version): Update copyright year.
19829 * server.c (gdbserver_version): Likewise.
19830
f21cc1a2 198312009-01-05 Doug Evans <dje@google.com>
0e21c1ec
DE
19832
19833 * linux-low.c (linux_attach_lwp): Add some comments/fixmes.
f21cc1a2 19834 (handle_extended_wait): Improve comment.
0e21c1ec 19835
bca929d3
DE
198362008-12-13 Doug Evans <dje@google.com>
19837
19838 * utils.c (xmalloc,xcalloc,xstrdup): New fns.
19839 * server.h (ATTR_MALLOC): New macro.
19840 (xmalloc,xcalloc,xstrdup): Declare.
19841 * hostio.c: Replace malloc,calloc,strdup with xmalloc,xcalloc,xstrdup.
19842 * inferiors.c: Ditto.
19843 * linux-low.c: Ditto.
19844 * mem-break.c: Ditto.
19845 * regcache.c: Ditto.
19846 * remote-utils.c: Ditto.
19847 * server.c: Ditto.
19848 * target.c: Ditto.
19849 * win32-low.c: Ditto.
19850
97438e3f
DE
198512008-12-12 Doug Evans <dje@google.com>
19852
896c7fbb
DE
19853 * linux-low.c (linux_wait_for_process): Don't clobber current_inferior
19854 in debugging printf.
19855
97438e3f
DE
19856 * linux-low.c (handle_extended_wait): Simplify, use my_waitpid.
19857
e3b886f8
DE
198582008-12-09 Doug Evans <dje@google.com>
19859
19860 * linux-low.h (struct process_info): Delete member tid, unused.
19861 * thread-db.c (find_one_thread): Update.
19862 (maybe_attach_thread): Update.
19863
07e059b5
VP
198642008-12-02 Pedro Alves <pedro@codesourcery.com>
19865
889bf7c5
PA
19866 * target.h (struct target_ops): Add qxfer_osdata member.
19867 * linux-low.c: Include ctype.h and pwd.h and sys/types.h
19868 and dirent.h.
19869 (linux_qxfer_osdata): New functions.
19870 (linux_target_ops): Register linux_qxfer_osdata as qxfer_osdata
19871 callback.
19872 * server.c (handle_query): Handle "qXfer:osdata:read:".
19873 * remote-utils.c (buffer_grow, buffer_free, buffer_init, buffer_finish)
19874 (buffer_xml_printf): New functions.
19875 * server.h (struct buffer): New.
19876 (buffer_grow_str, buffer_grow_str0): New macros.
19877 (buffer_grow, buffer_free, buffer_init, buffer_finish)
19878 (buffer_xml_printf): Declare.
07e059b5 19879
4cab47ab
DE
198802008-11-24 Doug Evans <dje@google.com>
19881
19882 * Makefile.in (VERSION,DIST,LINT,LINTFLAGS): Delete, unused.
19883
f142445f
DJ
198842008-11-24 Daniel Jacobowitz <dan@codesourcery.com>
19885
19886 * server.c (handle_v_run): Always use the supplied argument list.
19887
d0107bb6 198882008-11-19 Bob Wilson <bob.wilson@acm.org>
889bf7c5 19889
d0107bb6
BW
19890 * xtensa-xtregs.c (XTENSA_ELF_XTREG_SIZE): Change to 4.
19891 (xtensa_regmap_table): Add entry for scompare1.
889bf7c5 19892
2c4ad781
TJB
198932008-11-18 Thiago Jung Bauermann <bauerman@br.ibm.com>
19894
19895 * Makefile.in (powerpc-isa205-32l.o, powerpc-isa205-32l.c,
19896 powerpc-isa205-altivec32l.o, powerpc-isa205-altivec32l.c,
19897 powerpc-isa205-vsx32l.o, powerpc-isa205-vsx32l.c,
19898 powerpc-isa205-64l.o, powerpc-isa205-64l.c,
19899 powerpc-isa205-altivec64l.o, powerpc-isa205-altivec64l.c,
19900 powerpc-isa205-vsx64l.o, powerpc-isa205-vsx64l.c): New targets.
19901 * configure.srv (powerpc*-*-linux*): Add ISA 2.05 object files and
19902 XML target descriptions.
19903 * linux-ppc-low.c (ppc_arch_setup): Init registers with 64-bit FPSCR
19904 when inferior is running on an ISA 2.05 or later processor. Add
19905 special case to return offset for full 64-bit slot of FPSCR when
19906 in 32-bits.
19907
dfb64f85
DJ
199082008-11-14 Daniel Gutson <dgutson@codesourcery.com>
19909
19910 * Makefile.in (SFILES, clean): Added sparc64 files.
19911 (reg-sparc64.o, reg-sparc64.c): New.
19912 * configure.srv (sparc*-*-linux*): New configuration.
19913 * linux-low.c (regsets_fetch_inferior_registers): Swap ptrace
19914 syscall arguments for SPARC.
19915 (regsets_store_inferior_registers): Likewise.
19916 * linux-sparc-low.c: New file.
19917
66b6e1dd
DE
199182008-10-21 Doug Evans <dje@google.com>
19919
19920 * Makefile.in (BFD_DIR,BFD,BFD_SRC,BFD_CFLAGS): Delete.
19921 (READLINE_DIR,READLINE_DEP): Delete.
19922 (INTERNAL_CFLAGS): Update.
19923 (LINTFLAGS): Update.
19924
9b710a42
PA
199252008-10-10 Pedro Alves <pedro@codesourcery.com>
19926
19927 * server.c (handle_v_run): If GDB didn't specify an argv, use the
19928 whole argv from the last run, not just argv[0].
19929
5822d809
PA
199302008-09-08 Pedro Alves <pedro@codesourcery.com>
19931
19932 * regcache.c (new_register_cache): Return NULL if the register
19933 cache size isn't known yet.
19934 (free_register_cache): Avoid dereferencing a NULL regcache.
19935
74aac56f
DJ
199362008-09-04 Daniel Jacobowitz <dan@codesourcery.com>
19937
19938 * configure.srv: Merge MIPS and MIPS64.
19939
400b20f5
MR
199402008-08-24 Maciej W. Rozycki <macro@linux-mips.org>
19941
19942 * Makefile.in (uninstall): Apply $(EXEEXT) too.
19943
677c5bb1
LM
199442008-08-18 Luis Machado <luisgpm@br.ibm.com>
19945
19946 * Makefile.in: Add required vsx dependencies.
19947
19948 * linux-ppc-low: Define PPC_FEATURE_HAS_VSX.
19949 Declare init_registers_powerpc_vsx32l.
19950 Declare init_registers_powerpc_vsx64l.
19951 Define PTRACE_GETVSXREGS and PTRACE_SETVSXREGS.
19952 (ppc_arch_setup): Check for VSX in hwcap.
19953 (ppc_fill_vsxregset): New function.
19954 (ppc_store_vsxregset): New function.
19955 Add new VSX entry in regset_info target_regsets.
19956
19957 * configure.srv: Add new VSX dependencies.
19958
a6f3e723
SL
199592008-08-12 Pedro Alves <pedro@codesourcery.com>
19960
19961 * remote-utils.c (noack_mode, transport_is_reliable): New globals.
19962 (remote_open): Set or clear transport_is_reliable.
19963 (putpkt_binary): Don't expect acks in noack mode.
19964 (getpkt): Don't send ack/nac in noack mode.
19965 * server.c (handle_general_set): Handle QStartNoAckMode.
19966 (handle_query): If connected by tcp pass QStartNoAckMode+ in
19967 qSupported.
19968 (main): Reset noack_mode on every connection.
19969 * server.h (noack_mode): Declare.
19970
a417dc56
RW
199712008-08-07 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
19972
19973 * Makefile.in (GDBREPLAY_OBS): New variable.
19974 (gdbreplay$(EXEEXT)): Use it to avoid unportable $^.
19975
3221518c
UW
199762008-08-05 Ulrich Weigand <uweigand@de.ibm.com>
19977 Daniel Jacobowitz <dan@codesourcery.com>
19978
19979 * linux-low.c (linux_resume_one_process): Ignore ESRCH.
19980 (usr_store_inferior_registers): Likewise.
19981 (regsets_store_inferior_registers): Likewise.
19982
ec56be1b
PA
199832008-07-31 Rolf Jansen <rj@surtec.com>
19984 Pedro Alves <pedro@codesourcery.com>
19985
19986 * configure.ac: Check for memmem declaration.
19987 * server.c [HAVE_MALLOC_H]: Include malloc.h.
19988 (disable_packet_vCont, disable_packet_Tthread, disable_packet_qC)
19989 (disable_packet_qfThreadInfo): Unconditionally compile.
19990 * server.h [!HAVE_DECL_MEMMEM]: Declare memmem.
19991 * configure, config.in: Regenerate.
19992
2fe5e3ff
DE
199932008-07-28 Doug Kwan <dougkwan@google.com>
19994
19995 * linux-low.c (sys/dir.h, sys/user.h): Remove includes.
19996 (linux_write_memory): Remove declaration of errno.
19997
836acd6d
UW
199982008-07-12 Ulrich Weigand <uweigand@de.ibm.com>
19999
20000 * linux-low.c (handle_extended_wait): Do not use "status"
20001 variable uninitialized.
20002
aeba519e
PA
200032008-07-07 Pedro Alves <pedro@codesourcery.com>
20004
20005 * server.c (handle_v_attach): Inhibit reporting dll changes.
20006
db42f210
PA
200072008-06-27 Pedro Alves <pedro@codesourcery.com>
20008
20009 * remote-utils.c (prepare_resume_reply): If requested, don't
20010 output "thread:TID" in the T stop reply.
20011
20012 * server.c (disable_packet_vCont, disable_packet_Tthread)
20013 (disable_packet_qC, disable_packet_qfThreadInfo): New globals.
20014 (handle_query): If requested, disable support for qC, qfThreadInfo
20015 and qsThreadInfo.
20016 (handle_v_requests): If requested, disable support for vCont.
20017 (gdbserver_show_disableable): New.
20018 (main): Handle --disable-packet and --disable-packet=LIST.
20019
20020 * server.h (disable_packet_vCont, disable_packet_Tthread)
20021 (disable_packet_qC, disable_packet_qfThreadInfo): Declare.
20022
8e4c5421
CD
200232008-06-20 Carlos O'Donell <carlos@codesourcery.com>
20024
20025 * server.c (gdbserver_usage): Mention --version.
20026
6e23a804
DJ
200272008-06-06 Daniel Jacobowitz <dan@codesourcery.com>
20028
20029 * Makefile.in (gdbreplay.o): New rule.
20030
90aa6a40
JM
200312008-06-06 Joseph Myers <joseph@codesourcery.com>
20032
20033 * gdbreplay.c (gdbreplay_version): Say gdbreplay in version
20034 message, not gdbserver.
20035
c16158bc 200362008-06-05 Vladimir Prus <vladimir@codesourcery.com>
889bf7c5
PA
20037 Nathan Sidwell <nathan@codesourcery.com>
20038 Joseph Myers <joseph@codesourcery.com>
c16158bc
JM
20039
20040 * acinclude.m4: Include ../../config/acx.m4.
20041 * configure.ac: Use ACX_PKGVERSION and ACX_BUGURL.
20042 * configure, config.in: Regenerate.
20043 * Makefile.in (gdbreplay$(EXEEXT)): Add version.o.
20044 * server.c (gdbserver_version): Print PKGVERSION.
20045 (gdbsrever_usage): Add stream parameter. Print REPORT_BUGS_TO.
20046 (main): Adjust gdbserver_usage calls.
20047 * gdbreplay.c (version, host_name): Add declarations.
20048 (gdbreplay_version, gdbreplay_usage): New.
20049 (main): Accept --version and --help options.
20050
aeb75bf5
DJ
200512008-06-04 Daniel Jacobowitz <dan@codesourcery.com>
20052
20053 * linux-arm-low.c (thumb_breakpoint, thumb_breakpoint_len): New.
20054 (arm_breakpoint_at): Handle Thumb.
20055 (the_low_target): Add comment.
20056
76b233dd
UW
200572008-05-29 Ulrich Weigand <uweigand@de.ibm.com>
20058
20059 * linux-ppc-low.c (ppc_collect_ptrace_register): Clear buffer.
20060
08388c79
DE
200612008-05-09 Doug Evans <dje@google.com>
20062
a3c83fae
DE
20063 * server.h (decode_search_memory_packet): Declare.
20064 * remote-utils.c (decode_search_memory_packet): New fn.
20065 * server.c (handle_search_memory_1): New fn.
08388c79
DE
20066 (handle_search_memory): New fn.
20067 (handle_query): Process qSearch:memory packets.
20068
bb9c3d36
UW
200692008-05-08 Ulrich Weigand <uweigand@de.ibm.com>
20070
20071 * regcache.c (registers_length): Remove.
20072 (set_register_cache): Verify that PBUFSIZ is large enough to hold a
20073 full register packet.
20074 * regcache.h (registers_length): Remove prototype.
20075 * server.h (PBUFSIZ): Define to 16384.
20076
7284e1be
UW
200772008-05-03 Ulrich Weigand <uweigand@de.ibm.com>
20078
20079 * configure.srv (powerpc*-*-linux*): Set srv_regobj to
20080 powerpc-32l.o, powerpc-altivec32l.o, powerpc-e500l.o,
20081 powerpc-64l.o, and powerpc-altivec64l.o.
20082 Remove rs6000/powerpc-32.xml, rs6000/powerpc-64.xml, and
20083 rs6000/powerpc-e500.xml; add rs6000/powerpc-32l.xml,
20084 rs6000/powerpc-altivec32l.xml, rs6000/powerpc-e500l.xml,
20085 rs6000/powerpc-64l.xml, rs6000/powerpc-altivec64l.xml,
20086 rs6000/power-linux.xml, and rs6000/power64-linux.xml
20087 to srv_xmlfiles.
20088
20089 * Makefile.in (reg-ppc.o, reg-ppc.c): Remove, replace by ...
20090 (powerpc-32l.o, powerpc-32l.c): ... these new rules.
20091 (powerpc-32.o, powerpc-32.c): Remove, replace by ...
20092 (powerpc-altivec32l.o, powerpc-altivec32l.c): ... these new rules.
20093 (powerpc-e500.o, powerpc-e500.c): Remove, replace by ...
20094 (powerpc-e500l.o, powerpc-e500l.c): ... these new rules.
20095 (reg-ppc64.o, reg-ppc64.c): Remove, replace by ...
20096 (powerpc-64l.o, powerpc-64l.c): ... these new rules.
20097 (powerpc-64.o, powerpc-64.c): Remove, replace by ...
20098 (powerpc-altivec64l.o, powerpc-altivec64l.c): ... these new rules.
20099 (clean): Update.
20100
20101 * linux-ppc-low.c (init_registers_ppc): Remove, replace by ...
20102 (init_registers_powerpc_32l): ... this new prototype.
20103 (init_registers_powerpc_32): Remove, replace by ...
20104 (init_registers_powerpc_altivec32l): ... this new prototype.
20105 (init_registers_powerpc_e500): Remove, replace by ...
20106 (init_registers_powerpc_e500l): ... this new prototype.
20107 (init_registers_ppc64): Remove, replace by ...
20108 (init_registers_powerpc_64l): ... this new prototype.
20109 (init_registers_powerpc_64): Remove, replace by ...
20110 (init_registers_powerpc_altivec64l): ... this new prototype.
20111 (ppc_num_regs): Set to 73.
20112 (PT_ORIG_R3, PT_TRAP): Define if necessary.
20113 (ppc_regmap, ppc_regmap_e500): Add values for orig_r3 and trap.
20114 (ppc_cannot_store_register): Handle orig_r3 and trap.
20115 (ppc_arch_setup): Update init_registers_... calls.
20116 (ppc_fill_gregset): Handle orig_r3 and trap.
20117
20118 * inferiors.c (clear_inferiors): Reset current_inferior.
20119
fdc59709
PB
201202008-04-23 Paolo Bonzini <bonzini@gnu.org>
20121
889bf7c5
PA
20122 * acinclude.m4: Add override.m4.
20123 * configure: Regenerate.
fdc59709 20124
c9b2f845
UW
201252008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
20126
20127 * linux-ppc-low.c (ppc_arch_setup): Reset ppc_hwcap after the
20128 initial call to init_register_ppc64.
20129
550512b8
UW
201302008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
20131
43aaf8b6
PA
20132 * configure.srv (powerpc64-*-linux*, powerpc-*-linux*): Merge into
20133 single powerpc*-*-linux* case.
550512b8
UW
20134 (s390-*-linux*, s390x-*-linux*): Merge into single s390*-*-linux* case.
20135
b6430ec3
UW
201362008-04-17 Ulrich Weigand <uweigand@de.ibm.com>
20137
20138 * configure.srv [powerpc64-*-linux*]: Remove powerpc-e500.o from
889bf7c5 20139 srv_regobj. Remove rs6000/powerpc-e500.xml and rs6000/power-spe.xml
b6430ec3
UW
20140 from reg_xmlfiles.
20141 * linux-ppc-low.c: Include <elf.h>.
20142 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Define.
20143 (ppc_hwcap): New global variable.
20144 (ppc_regmap): Remove __SPE__ #ifdef sections.
20145 (ppc_regmap_e500): New global variable.
20146 (ppc_cannot_store_register): Update __SPE__ special case.
20147 (ppc_get_hwcap): New function.
20148 (ppc_arch_setup): Use it to determine whether inferior supports
20149 AltiVec or SPE registers. Set the_low_target.regmap if appropriate.
20150 (ppc_fill_vrregset, ppc_store_vrregset): Define unconditionally.
20151 Do not access registers if target does not support AltiVec.
20152 (ppc_fill_evrregset, ppc_store_evrregset): Define unconditionally.
20153 Do not access registers if target does not support SPE.
20154 (target_regsets): Unconditionally include AltiVec and SPE regsets.
20155
52fa2412
UW
201562008-04-17 Daniel Jacobowitz <dan@codesourcery.com>
20157
20158 * linux-low.c (disabled_regsets, num_regsets): New.
20159 (use_regsets_p): Delete.
20160 (linux_wait_for_process): Clear disabled_regsets.
20161 (regsets_fetch_inferior_registers): Check and set it.
20162 (regsets_store_inferior_registers): Likewise.
20163 (linux_fetch_registers, linux_store_registers): Do not use
20164 use_regsets_p.
20165 (initialize_low): Allocate disabled_regsets.
20166
e28b3332
DJ
201672008-04-14 Daniel Jacobowitz <dan@codesourcery.com>
20168
20169 * Makefile.in (LIBOBJS): New.
20170 (OBS): Use LIBOBJS.
20171 (memmem.o): New rule.
20172 * configure.ac: Use AC_CONFIG_LIBOBJ_DIR and check for memmem.
20173 * configure: Regenerated.
20174
4536995d
UW
201752008-04-04 Ulrich Weigand <uweigand@de.ibm.com>
20176
20177 * server.c (handle_query): Never return "unsupported" for
20178 qXfer:features:read queries.
20179
221c031f
UW
201802008-03-27 Ulrich Weigand <uweigand@de.ibm.com>
20181
20182 * server.c (get_features_xml): Fix inverted condition.
20183 (handle_query): Always support qXfer:feature:read.
20184
ccd213ac
DJ
201852008-03-10 Daniel Jacobowitz <dan@codesourcery.com>
20186
20187 * server.c (wrapper_argv): New.
20188 (start_inferior): Handle wrapper_argv. If set, expect an extra
20189 trap.
20190 (gdbserver_usage): Document --wrapper.
20191 (main): Parse --wrapper.
20192
6fe305f7
UW
201932008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
20194
20195 * configure.srv [powerpc64-*-linux*]: Add all files mentioned for
20196 powerpc-*-linux* to srv_regobj and reg_xmlfiles.
20197 * linux-ppc-low.c (ppc_get_pc): Support bi-arch operation.
20198 (ppc_set_pc): Likewise.
20199 (ppc_arch_setup): New function.
20200 (ppc_fill_gregset): Call ppc_collect_ptrace_register instead
20201 of collect_register.
889bf7c5 20202 (the_low_target): Use ppc_arch_setup as arch_setup initializer.
6fe305f7 20203
5b0a002e
UW
202042008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
20205
20206 * configure.srv [powerpc64-*-linux*]: Use linux-ppc-low.o
20207 instead of linux-ppc64-low.o.
20208 * linux-ppc64-low.c: Remove file.
20209 * Makefile.in (SFILES): Remove linux-ppc64-low.c.
20210 (linux-ppc64-low.o): Remove rule.
20211
20212 * linux-ppc-low.c (init_registers_ppc64): Add prototype.
20213 (init_registers_powerpc_64): Likewise.
20214 (ppc_regmap): Conditionally define depending on __powerpc64__.
20215 (ppc_cannot_store_register): Do not special-case "fpscr" when
20216 compiled on __powerpc64__.
20217 (ppc_collect_ptrace_register): New function.
20218 (ppc_supply_ptrace_register): New function.
20219 (ppc_breakpoint): Change type to "unsigned int".
20220 (ppc_breakpoint_at): Change type of "insn" to "unsigned int".
20221 (the_low_target): Conditionally provide initializers for the
889bf7c5 20222 arch_setup member depending on __powerpc64__. Install
5b0a002e
UW
20223 collect_ptrace_register and supply_ptrace_register members.
20224
9b4b61c8
UW
202252008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
20226
20227 * regcache.h (gdbserver_xmltarget): Add extern declaration.
20228 * server.c (gdbserver_xmltarget): Define.
20229 (get_features_xml): Use it to replace "target.xml" and arch_string.
20230
20231 * configure.srv: Remove srv_xmltarget. Add XML files that were
20232 mentioned there to srv_xmlfiles instead. Remove conditional tests
20233 on gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe; set
20234 srv_xmlfiles and srv_regobj to include all possible choices.
20235 * configure.ac (srv_xmltarget): Remove.
20236 (srv_xmlfiles): Do not add "target.xml".
20237 (gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe): Remove
20238 checks for supplementary target information.
20239 * configure: Regenerate.
20240 * Makefile.in (XML_TARGET): Remove.
20241 (target.xml): Remove rule.
20242 (clean): Do not clean up target.xml.
20243 (.PRECIOUS): Do not mention target.xml.
20244
20245 * target.h (struct target_ops): Remove arch_string member.
20246 * linux-low.c (linux_arch_string): Remove.
20247 (linux_target_ops): Remove arch_string initializer.
20248 * linux-low.h (struct linux_target_ops): Remove arch_string member.
20249 * linux-i386-low.c (the_low_target): Remove arch_string initializer.
20250 * linux-x86-64-low.c (the_low_target): Remove arch_string initializer.
20251 * spu-low.c (spu_arch_string): Remove.
20252 (spu_target_ops): Remove arch_string initializer.
20253 * win32-low.c (win32_arch_string): Remove.
20254 (win32_target_ops): Remove arch_string initializer.
20255 * win32-low.h (struct win32_target_ops): Remove arch_string member.
20256 * win32-arm-low.c (the_low_target): Remove arch_string initializer.
20257 * win32-i368-low.c (the_low_target): Remove arch_string initializer.
20258
ee1a7ae4
UW
202592008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
20260
20261 * linux-low.h (struct linux_target_ops): Replace left_pad_xfer field
20262 by collect_ptrace_register and supply_ptrace_register hooks.
20263 * linux-low.c (fetch_register): Use supply_ptrace_register callback
20264 instead of checking for the_low_target.left_pad_xfer.
20265 (usr_store_inferior_registers): Use collect_ptrace_register callback
20266 instead of checking for the_low_target.left_pad_xfer.
20267
20268 * linux-s390-low.c (s390_collect_ptrace_register): New function.
20269 (s390_supply_ptrace_register): Likewise.
20270 (s390_fill_gregset): Call s390_collect_ptrace_register.
20271 (the_low_target): Update.
20272
20273 * linux-ppc64-low.c (ppc_collect_ptrace_register): New function.
20274 (ppc_supply_ptrace_register): Likewise.
20275 (the_low_target): Update.
20276
20277 * linux-i386-low.c (the_low_target): Update.
20278 * linux-x86-64-low.c (the_low_target): Update.
20279
d61ddec4
UW
202802008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
20281
20282 * configure.srv [s390x-*-linux*]: Set srv_regobj to include both
20283 reg-s390.o and reg-s390x.o.
20284
20285 * linux-low.c (new_inferior): New global variable.
20286 (linux_create_inferior, linux_attach): Set it.
20287 (linux_wait_for_process): Call the_low_target.arch_setup after the
20288 target has stopped for the first time.
20289 (initialize_low): Do not call the_low_target.arch_setup.
20290
20291 * linux-s390-low.c (s390_get_pc): Support bi-arch operation.
20292 (s390_set_pc): Likewise.
20293 (s390_arch_setup): New function.
20294 (the_low_target): Use s390_arch_setup as arch_setup routine.
20295
20296 * regcache.c (realloc_register_cache): New function.
20297 (set_register_cache): Call it for each existing regcache.
20298
d05b4ac3
UW
202992008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
20300
20301 * server.h (init_registers): Remove prototype.
20302
20303 * linux-low.h (struct linux_target_ops): Add arch_setup field.
20304 * linux-low.c (initialize_low): Call the_low_target.arch_setup ()
20305 instead of init_registers ().
20306 * linux-arm-low.c (init_registers_arm): Add prototype.
20307 (init_registers_arm_with_iwmmxt): Likewise.
20308 (the_low_target): Add initializer for arch_setup field.
20309 * linux-cris-low.c (init_registers_cris): Add prototype.
20310 (the_low_target): Add initializer for arch_setup field.
20311 * linux-crisv32-low.c (init_registers_crisv32): Add prototype.
20312 (the_low_target): Add initializer for arch_setup field.
20313 * linux-i386-low.c (init_registers_i386_linux): Add prototype.
20314 (the_low_target): Add initializer for arch_setup field.
20315 * linux-ia64-low.c (init_registers_ia64): Add prototype.
20316 (the_low_target): Add initializer for arch_setup field.
20317 * linux-m32r-low.c (init_registers_m32r): Add prototype.
20318 (the_low_target): Add initializer for arch_setup field.
20319 * linux-m68k-low.c (init_registers_m68k): Add prototype.
20320 (the_low_target): Add initializer for arch_setup field.
20321 * linux-mips-low.c (init_registers_mips_linux): Add prototype.
20322 (init_registers_mips64_linux): Likewise.
20323 (the_low_target): Add initializer for arch_setup field.
20324 * linux-ppc-low.c (init_registers_ppc): Add prototype.
20325 (init_registers_powerpc_32, init_registers_powerpc_e500): Likewise.
20326 (the_low_target): Add initializer for arch_setup field.
20327 * linux-ppc64-low.c (init_registers_ppc64): Add prototype.
20328 (init_registers_powerpc_64): Likewise.
20329 (the_low_target): Add initializer for arch_setup field.
20330 * linux-s390-low.c (init_registers_s390): Add prototype.
20331 (init_registers_s390x): Likewise.
20332 (the_low_target): Add initializer for arch_setup field.
20333 * linux-sh-low.c (init_registers_sh): Add prototype.
20334 (the_low_target): Add initializer for arch_setup field.
20335 * linux-x86-64-low.c (init_registers_x86_64_linux): Add prototype.
20336 (the_low_target): Add initializer for arch_setup field.
20337 * linux-xtensa-low.c (init_registers_xtensa): Add prototype.
20338 (the_low_target): Add initializer for arch_setup field.
20339
20340 * win32-low.h (struct win32_target_ops): Add arch_setup field.
20341 * win32-low.c (initialize_low): Call the_low_target.arch_setup ()
20342 instead of init_registers ().
20343 * win32-arm-low.c (init_registers_arm): Add prototype.
20344 (the_low_target): Add initializer for arch_setup field.
20345 * win32-i386-low.c (init_registers_i386): Add prototype.
20346 (the_low_target): Add initializer for arch_setup field.
20347
20348 * spu-low.c (init_registers_spu): Add prototype.
20349 (initialize_low): Call initialie_registers_spu () instead of
20350 initialize_registers ().
20351
fd96d250
PA
203522008-02-19 Pedro Alves <pedro@codesourcery.com>
20353
20354 * server.c (handle_v_requests): When handling the vRun and vAttach
20355 packets, if already debugging a process, don't kill it. Return an
20356 error instead.
20357
d41b6bb4
DJ
203582008-02-17 Daniel Jacobowitz <dan@codesourcery.com>
20359
20360 * server.c (handle_query): Correct length check.
20361
5ac588cf
PA
203622008-02-14 Pedro Alves <pedro_alves@portugalmail.pt>
20363
20364 * win32-low.c (do_initial_child_stuff): Add process handle
20365 parameter. Set current_process_handle and current_process_id from the
20366 parameters. Clear globals.
20367 (win32_create_inferior): Don't set current_process_handle and
20368 current_process_id here. Instead pass them on the call to
20369 do_initial_child_stuff.
20370 (win32_attach): Likewise.
20371 (win32_clear_inferiors): New.
20372 (win32_kill): Don't close the current process handle or the
20373 current thread handle here. Instead call win32_clear_inferiors.
20374 (win32_detach): Don't open a new handle to the process. Call
20375 win32_clear_inferiors.
20376 (win32_join): Don't rely on current_process_handle; open a new
20377 handle using the process id.
20378 (win32_wait): Call win32_clear_inferiors when the inferior process
20379 has exited.
20380
ecd7ecbc
DJ
203812008-02-14 Daniel Jacobowitz <dan@codesourcery.com>
20382
20383 * server.c (monitor_show_help): Add "exit".
20384
1525d545
MG
203852008-02-11 Maxim Grigoriev <maxim2405@gmail.com>
20386
ecd7ecbc 20387 * Makefile.in (SFILES): Add linux-xtensa-low.c.
1525d545
MG
20388 (clean): Add reg-xtensa.c.
20389 (linux-xtensa-low.o, reg-xtensa.o, reg-xtensa.c): New dependencies.
ecd7ecbc
DJ
20390 * configure.srv (xtensa*-*-linux*) New target.
20391 * linux-xtensa-low.c: New.
20392 * xtensa-xtregs.c: New.
1525d545 20393
59a016f0
PA
203942008-02-01 Pedro Alves <pedro_alves@portugalmail.pt>
20395
20396 * hostio.c: Don't include errno.h.
20397 (errno_to_fileio_errno): Move to hostio-errno.
20398 * hostio.c: (hostio_error): Remove the error parameter. Defer the
20399 error number outputting to the target->hostio_last_error callback.
20400 (hostio_packet_error): Use FILEIO_EINVAL directly.
20401 (handle_open, handle_pread, hostio_error, handle_unlink): Update
20402 calls to hostio_error.
20403 * hostio-errno.c: New.
20404 * server.h (hostio_last_error_from_errno): Declare.
20405 * target.h (target_ops): Add hostio_last_error member.
20406 * linux-low.c (linux_target_op): Register hostio_last_error_from_errno
20407 as hostio_last_error handler.
889bf7c5 20408 * spu-low.c (spu_target_ops): Likewise.
59a016f0
PA
20409 * win32-low.c [_WIN32_WCE] (win32_error_to_fileio_error)
20410 (wince_hostio_last_error): New functions.
20411 (win32_target_ops) [_WIN32_WCE]: Register wince_hostio_last_error
20412 as hostio_last_error handler.
20413 (win32_target_ops) [!_WIN32_WCE]: Register
20414 hostio_last_error_from_errno as hostio_last_error handler.
20415 * Makefile.in (SFILES): Add hostio.c and hostio-errno.c.
20416 (hostio-errno.o): New rule.
20417 * configure.ac (GDBSERVER_DEPFILES): Add $srv_hostio_err_objs.
20418 * configure.srv (srv_hostio_err_objs): New variable. Default to
20419 hostio-errno.o.
20420 (arm*-*-mingw32ce*): Set srv_hostio_err_objs to "".
20421 * configure: Regenerate.
20422
2d717e4f
DJ
204232008-01-29 Daniel Jacobowitz <dan@codesourcery.com>
20424
20425 * linux-low.c (linux_attach_lwp): Do not _exit after errors.
20426 (linux_kill, linux_detach): Clean up the process list.
20427 * remote-utils.c (remote_open): Improve port number parsing.
20428 (putpkt_binary, input_interrupt): Only send interrupts if the target
20429 is running.
20430 * server.c (extended_protocol): Make static.
20431 (attached): Define earlier.
20432 (exit_requested, response_needed, program_argv): New variables.
20433 (target_running): New.
20434 (start_inferior): Clear attached here.
20435 (attach_inferior): Set attached here.
20436 (require_running): Define.
20437 (handle_query): Use require_running and target_running. Implement
20438 "monitor exit".
20439 (handle_v_attach, handle_v_run): New.
20440 (handle_v_requests): Use require_running. Handle vAttach and vRun.
20441 (gdbserver_usage): Update.
20442 (main): Redo argument parsing. Handle --debug and --multi. Handle
20443 --attach along with other options or after the port. Save
20444 program_argv. Support no initial program. Resynchronize
20445 communication with GDB after an error. Handle "monitor exit".
20446 Use require_running and target_running. Always allow the extended
20447 protocol. Do not error out for Hc0 or Hc-1. Do not automatically
20448 restart in extended mode.
20449 * README: Refer to the GDB manual. Update --attach usage.
20450
7407e2de
AS
204512007-12-20 Andreas Schwab <schwab@suse.de>
20452
20453 * linux-low.c (STACK_SIZE): Define.
20454 (linux_tracefork_child): Use it. Use __clone2 on ia64.
20455 (linux_test_for_tracefork): Likewise.
20456
b65d95c5
DJ
204572007-12-18 Daniel Jacobowitz <dan@codesourcery.com>
20458
20459 * linux-low.c (linux_wait_for_event): Update messages. Do not
20460 reinsert auto-delete breakpoints.
20461 * mem-break.c (struct breakpoint): Change return type of handler to
20462 int.
20463 (set_breakpoint_at): Update handler type.
20464 (reinsert_breakpoint_handler): Return 1 instead of calling
20465 delete_breakpoint.
20466 (reinsert_breakpoint_by_bp): Check for the original breakpoint before
20467 setting a new one.
20468 (check_breakpoints): Delete auto-delete breakpoints and return 2.
20469 * mem-break.h (set_breakpoint_at): Update handler type.
20470 * thread-db.c (thread_db_create_event, thread_db_create_event): Update.
20471 * win32-low.c (auto_delete_breakpoint): New.
20472 (get_child_debug_event): Use it.
20473
4e799345
DJ
204742007-12-16 Daniel Jacobowitz <dan@codesourcery.com>
20475
20476 * configure.ac: Check for pread and pwrite.
20477 * hostio.c (handle_pread): Fall back to lseek and read.
20478 (handle_pwrite): Fall back to lseek and write.
20479 * config.in, configure: Regenerated.
20480
27524b67
DJ
204812007-12-07 Daniel Jacobowitz <dan@codesourcery.com>
20482
20483 * server.c (myresume): Add own_buf argument.
20484 (main): Update calls.
20485
a20d5e98
DJ
204862007-12-06 Daniel Jacobowitz <dan@codesourcery.com>
20487
20488 * linux-low.c (linux_wait, linux_resume): Do not handle async I/O.
20489 * remote-utils.c (remote_open): Do not call disable_async_io.
20490 (block_async_io): Delete.
20491 (unblock_async_io): Make static.
20492 (initialize_async_io): New.
20493 * server.c (handle_v_cont): Handle async I/O here.
20494 (myresume): Likewise. Move other common resume tasks here...
20495 (main): ... from here. Call initialize_async_io. Disable async
20496 I/O before the main loop.
20497 * server.h (initialize_async_io): Declare.
20498 (block_async_io, unblock_async_io): Delete prototypes.
20499 * spu-low.c (spu_resume, spu_wait): Do not handle async I/O here.
20500
b79d787e
DJ
205012007-12-06 Mick Davis <mickd@goanna.iinet.net.au>
20502
20503 * remote-utils.c (readchar): Allow binary data in received messages.
20504
d97903b2
PA
205052007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
20506
20507 * win32-low.c (attaching): New global.
20508 (win32_create_inferior): Clear the `attaching' global.
20509 (win32_attach): Set the `attaching' global.
20510 (get_child_debug_event) [_WIN32_WCE]: Stop the inferior when
20511 attaching. Only set a breakpoint at the entry point if not
20512 attaching.
20513
311de423
PA
205142007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
20515
20516 * server.c (main): Don't report dll events on the initial
20517 connection on attaches.
20518
6c2d16d2
PA
205192007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
20520
20521 * server.c (main): Relax numerical bases supported for the pid of
20522 the --attach command line argument.
20523
5ca906e6
PA
205242007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
20525
20526 * win32-low.c (win32_attach): Call OpenProcess before
20527 DebugActiveProcess, not after. Add last error output to error
20528 call.
20529
9c6c8194
PA
205302007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
20531
20532 * win32-low.c (win32_get_thread_context)
20533 (win32_set_thread_context): New functions.
20534 (thread_rec): Use win32_get_thread_context.
20535 (continue_one_thread, win32_resume): Use win32_set_thread_context.
20536 * win32-low.h (win32_thread_info) [_WIN32_WCE]: Add `base_context'
20537 field.
20538
4d5d1aaa
PA
205392007-12-03 Leo Zayas
20540 Pedro Alves <pedro_alves@portugalmail.pt>
20541
20542 * win32-low.c (soft_interrupt_requested, faked_breakpoint): New
20543 global variables.
20544 (child_add_thread): Minor cleanup.
20545 (child_continue): Resume artificially suspended threads before
20546 calling ContinueDebugEvent.
20547 (suspend_one_thread): New.
20548 (fake_breakpoint_event): New.
20549 (get_child_debug_event): Change return type to int. Check here if
20550 gdb sent an interrupt request. If a soft interrupt was requested,
20551 fake a breakpoint event. Return 0 if there is no event to handle,
20552 and 1 otherwise.
20553 (win32_wait): Don't check here if gdb sent an interrupt request.
20554 Ensure there is a valid event to handle.
20555 (win32_request_interrupt): Add soft interruption method as last
20556 resort.
20557
c436e841
PA
205582007-12-03 Leo Zayas
20559 Pedro Alves <pedro_alves@portugalmail.pt>
20560
20561 * win32-low.h (win32_thread_info): Add descriptions to the
20562 structure members. Replace `suspend_count' counter by a
20563 `suspended' flag.
20564 * win32-low.c (thread_rec): Update condition of when to get the
20565 context from the inferior. Rely on ContextFlags being set if it
20566 has already been retrieved. Only suspend the inferior thread if
20567 we haven't already. Warn if that fails.
20568 (continue_one_thread): s/suspend_count/suspended/. Only call
20569 ResumeThread once. Warn if that fails.
20570
e7b5fa67
PA
205712007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
20572
20573 * win32-low.c (win32_wait): Don't read from the inferior when it
20574 has already exited.
20575
a385171d
PA
205762007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
20577
20578 * Makefile.in (win32_low_h): New variable.
20579 (win32-low.o): Add dependency on $(win32_low_h).
20580 (win32-arm-low.o, win32-i386-low.o): New rules.
20581
f80c84b3
DJ
205822007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
20583
20584 * hostio.c: Correct copyright year.
20585
a6b151f1
DJ
205862007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
20587
20588 * Makefile.in (OBS): Add hostio.o.
20589 (hostio.o): New rule.
20590 * server.h (handle_vFile): Declare.
20591 * hostio.c: New file.
20592 * server.c (handle_v_requests): Take packet_len and new_packet_len
20593 for binary packets. Call handle_vFile.
20594 (main): Update call to handle_v_requests.
20595
f9387fc3
DJ
205962007-11-05 Daniel Jacobowitz <dan@codesourcery.com>
20597
20598 * linux-low.c: Include <sched.h>.
20599
51c2684e
DJ
206002007-11-01 Daniel Jacobowitz <dan@codesourcery.com>
20601
20602 * linux-low.c (linux_tracefork_grandchild): New.
20603 (linux_tracefork_child): Use clone.
20604 (linux_test_for_tracefork): Use clone; allocate and free a stack.
20605
75f83163
JB
206062007-10-31 Joel Brobecker <brobecker@adacore.com>
20607
20608 * Makefile.in: Use $(SHELL) instead of "sh" to call regdat.sh.
20609
da5898ce
DJ
206102007-10-24 Daniel Jacobowitz <dan@codesourcery.com>
20611
20612 * linux-low.c (handle_extended_wait): Handle unexpected signals.
20613
24a09b5f
DJ
206142007-10-23 Daniel Jacobowitz <dan@codesourcery.com>
20615
20616 * inferiors.c (change_inferior_id): Delete.
20617 (add_pid_to_list, pull_pid_from_list): New.
20618 * linux-low.c (PTRACE_SETOPTIONS, PTRACE_GETEVENTMSG)
20619 (PTRACE_O_TRACESYSGOOD, PTRACE_O_TRACEFORK, PTRACE_O_TRACEVFORK)
20620 (PTRACE_O_TRACECLONE, PTRACE_O_TRACEEXEC, PTRACE_O_TRACEVFORKDONE)
20621 (PTRACE_O_TRACEEXIT, PTRACE_EVENT_FORK, PTRACE_EVENT_VFORK)
20622 (PTRACE_EVENT_CLONE, PTRACE_EVENT_EXEC, PTRACE_EVENT_VFORK_DONE)
20623 (PTRACE_EVENT_EXIT, __WALL): Provide default definitions.
20624 (stopped_pids, thread_db_active, must_set_ptrace_flags): New variables.
20625 (using_threads): Always set to 1.
20626 (handle_extended_wait): New.
20627 (add_process): Do not set TID.
20628 (linux_create_inferior): Set must_set_ptrace_flags.
20629 (linux_attach_lwp): Remove TID argument. Do not check using_threads.
20630 Use PTRACE_SETOPTIONS. Call new_thread_notify. Update all callers.
20631 (linux_thread_alive): Rename TID argument to LWPID.
20632 (linux_wait_for_process): Handle unknown processes. Do not use TID.
20633 (linux_wait_for_event): Do not use TID or check using_threads. Update
20634 call to dead_thread_notify. Call handle_extended_wait.
20635 (linux_create_inferior): Use PTRACE_SETOPTIONS.
20636 (send_sigstop): Delete sigstop_sent.
20637 (wait_for_sigstop): Avoid TID.
20638 (linux_supports_tracefork_flag, linux_tracefork_child, my_waitpid)
20639 (linux_test_for_tracefork): New.
20640 (linux_lookup_signals): Use thread_db_active and
20641 linux_supports_tracefork_flag.
20642 (initialize_low): Use thread_db_active and linux_test_for_tracefork.
20643 * linux-low.h (get_process_thread): Avoid TID.
20644 (struct process_ifo): Move thread_known and tid to the end. Remove
20645 sigstop_sent.
20646 (linux_attach_lwp, thread_db_init): Update prototypes.
20647 * server.h (change_inferior_id): Delete prototype.
20648 (add_pid_to_list, pull_pid_from_list): New prototypes.
20649 * thread-db.c (thread_db_use_events): New.
20650 (find_first_thread): Rename to...
20651 (find_one_thread): ...this. Update callers and messages. Do not
20652 call fatal. Check thread_db_use_events. Do not call
20653 change_inferior_id or new_thread_notify.
20654 (maybe_attach_thread): Update. Do not call new_thread_notify.
20655 (thread_db_init): Set thread_db_use_events. Check use_events.
20656 * utils.c (fatal, warning): Correct message prefix.
20657
30ed0a8f
DJ
206582007-10-15 Daniel Jacobowitz <dan@codesourcery.com>
20659
20660 * Makefile.in (clean): Remove new files.
20661 (powerpc-32.o, powerpc-32.c, powerpc-e500.o, powerpc-e500.c)
20662 (powerpc-64.o, powerpc-64.c): New rules.
20663 * configure.srv: Use alternate register sets for powerpc64-*-linux*
20664 with AltiVec, powerpc-*-linux* with AltiVec, and powerpc-*-linux*
20665 with SPE.
20666 * linux-ppc-low.c (ppc_regmap): Do not fetch the FP registers for
20667 SPE targets.
20668 (ppc_cannot_store_register): Do not check for FPSCR for SPE targets.
20669 (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS, ppc_fill_vrregset)
20670 (ppc_store_vrregset, PTRACE_GETEVRREGS, PTRACE_SETEVRREGS)
20671 (struct gdb_evrregset_t, ppc_fill_evrregset, ppc_store_evrregset): New.
20672 (target_regsets): Add AltiVec and SPE register sets.
20673 * configure.ac: Check for AltiVec and SPE.
20674 * linux-ppc64-low.c (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS)
20675 (ppc_fill_vrregset, ppc_store_vrregset): New.
20676 (target_regsets): Add AltiVec register set.
20677 * configure: Regenerated.
20678
fd462a61
DJ
206792007-09-19 Daniel Jacobowitz <dan@codesourcery.com>
20680
20681 * linux-low.c (O_LARGEFILE): Define.
20682 (linux_read_memory): Use /proc/PID/mem.
20683 * configure.ac: Use AC_GNU_SOURCE. Check for pread64.
20684 * configure, config.in: Regenerated.
20685
69f223ed
DJ
206862007-09-04 Daniel Jacobowitz <dan@codesourcery.com>
20687
20688 * linux-low.c (linux_wait_for_event): Do not pass signals while
20689 single-stepping.
20690
aec18585
PA
206912007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
20692
20693 * win32-low.c (create_process): New.
20694 (win32_create_inferior): Use create_process instead of
20695 CreateProcess. If create_process failed retry appending an ".exe"
20696 suffix. Store the GetLastError result immediatelly after
20697 create_process calls and use it on the call to error.
20698
34d86ddd
PA
206992007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
20700
20701 * win32-low.c (handle_load_dll): Don't use toolhelp when waiting.
20702
5a0e3bd0
JB
207032007-08-23 Joel Brobecker <brobecker@adacore.com>
20704
20705 * configure.ac: Switch license to GPLv3.
20706
f88c79e6
MS
207072007-08-01 Michael Snyder <msnyder@access-company.com>
20708
20709 * remote-utils.c (putpkt_binary): Memory leak, free buf2.
20710
6b3d9b83
PA
207112007-07-31 Pedro Alves <pedro_alves@portugalmail.pt>
20712
20713 * win32-low.c (winapi_CloseToolhelp32Snapshot) [_WIN32_WCE]: New
20714 typedef.
20715 (win32_CloseToolhelp32Snapshot) [_WIN32_WCE]: New global var.
20716 (load_toolhelp) [_WIN32_WCE]: Load TOOLHELP.DLL. Get
20717 CloseToolhelp32Snapshot.
20718 (toolhelp_get_dll_name) [_WIN32_WCE]: Close the snapshot with
20719 CloseToolhelp32Snapshot.
20720
c588c53c
MS
207212007-07-27 Michael Snyder <michael.snyder@access-company.com>
20722
20723 * server.c (main): Check for inferior exit before main loop.
20724
aa0403d9
PA
207252007-07-18 Pedro Alves <pedro_alves@portugalmail.pt>
20726
20727 * remote-utils.c (remote_open): Set SO_KEEPALIVE on remote_desc
20728 instead of on tmp_desc.
20729
255e7678
DJ
207302007-07-17 Pedro Alves <pedro_alves@portugalmail.pt>
20731 Daniel Jacobowitz <dan@codesourcery.com>
20732
20733 * inferiors.c (all_dlls, dlls_changed, get_dll): New.
20734 (add_thread): Minor cleanups.
20735 (clear_inferiors): Move lower in the file. Clear the DLL
20736 list.
20737 (free_one_dll, match_dll, loaded_dll, unloaded_dll, clear_list): New.
20738 * remote-utils.c (prepare_resume_reply): Check dlls_changed.
20739 (xml_escape_text): New.
20740 * server.c (handle_query): Handle qXfer:libraries:read. Report it
20741 for qSupported.
20742 (handle_v_cont): Report errors.
20743 (gdbserver_version): Update.
20744 (main): Correct size of own_buf. Do not report initial DLL events.
20745 * server.h (struct dll_info, all_dlls, dlls_changed, loaded_dll)
20746 (unloaded_dll, xml_escape_text): New.
20747 * win32-low.c (enum target_waitkind): Update comments.
20748 (win32_add_one_solib, get_image_name, winapi_EnumProcessModules)
20749 (winapi_GetModuleInformation, winapi_GetModuleFileNameExA)
20750 (win32_EnumProcessModules, win32_GetModuleInformation)
20751 (win32_GetModuleFileNameExA, load_psapi, psapi_get_dll_name)
20752 (winapi_CreateToolhelp32Snapshot, winapi_Module32First)
20753 (winapi_Module32Next, win32_CreateToolhelp32Snapshot)
20754 (win32_Module32First, win32_Module32Next, load_toolhelp)
20755 (toolhelp_get_dll_name, handle_load_dll, handle_unload_dll): New.
20756 (get_child_debug_event): Handle DLL events.
20757 (win32_wait): Likewise.
20758
0d37add9
DJ
207592007-07-12 Daniel Jacobowitz <dan@codesourcery.com>
20760
20761 * configure.srv: Set srv_linux_regsets for sh*-*-linux*.
20762 * linux-sh-low.c (sh_fill_gregset, target_regsets): New.
20763
45e2715e
PA
207642007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
20765
20766 * win32-low.c (handle_output_debug_string): Ignore event if not
20767 waiting.
20768
c5674cf1
PA
207692007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
20770
20771 * win32-arm-low.c (arm_wince_breakpoint): Fix typo.
20772
2bbe3cc1
DJ
207732007-07-03 Daniel Jacobowitz <dan@codesourcery.com>
20774
20775 * remote-utils.c (look_up_one_symbol): Handle 'm' packets.
20776
ae13219e
DJ
207772007-07-02 Daniel Jacobowitz <dan@codesourcery.com>
20778
20779 * inferiors.c (change_inferior_id): Add comment.
20780 * linux-low.c (check_removed_breakpoint): Add an early
20781 prototype. Improve debug output.
20782 (linux_attach): Doc update.
20783 (linux_detach_one_process, linux_detach): Clean up before releasing
20784 each process.
20785 (send_sigstop, wait_for_sigstop): Improve comments and debug output.
20786 * linux-low.h (struct process_info): Doc improvement.
20787 * mem-break.c (delete_all_breakpoints): New.
20788 * mem-break.h (delete_all_breakpoints): New prototype.
20789 * thread-db.c (find_first_thread): New.
20790 (thread_db_create_event): Call it instead of
20791 thread_db_find_new_threads. Clean up unused variables.
20792 (maybe_attach_thread): Remove first thread handling.
20793 (thread_db_find_new_threads): Use find_first_thread.
20794 (thread_db_get_tls_address): Likewise.
20795
4105de34
DJ
207962007-06-27 Daniel Jacobowitz <dan@codesourcery.com>
20797
20798 * thread-db.c (thread_db_find_new_threads): Add prototype.
20799 (thread_db_create_event): Check for the main thread before adding
20800 a new thread.
20801 (maybe_attach_thread): Only enable event reporting if TID == 0.
20802 (thread_db_get_tls_address): Check for new threads.
20803
2b876972
DJ
208042007-06-20 Daniel Jacobowitz <dan@codesourcery.com>
20805
20806 * linux-low.c (linux_create_inferior): Try execv before execvp.
20807 * spu-low.c (spu_create_inferior): Likewise.
20808
7a245884
DJ
208092007-06-13 Mike Frysinger <vapier@gentoo.org>
20810
20811 * linux-low.c (linux_create_inferior): Change execv to execvp.
20812 * spu-low.c (spu_create_inferior): Likewies.
20813
117ce543
DJ
208142007-06-13 Daniel Jacobowitz <dan@codesourcery.com>
20815
20816 * Makefile.in (clean): Clean new files instead of deleted ones.
20817 (reg-mips.o, reg-mips.c, reg-mips64.o, reg-mips64.c): Delete.
20818 (mips-linux.o, mips-linux.c, mips64-linux.o, mips64-linux.c): New
20819 rules.
20820 * configure.srv: Specify XML files and new regformats for MIPS and
20821 MIPS64 GNU/Linux.
20822 * linux-mips-low.c (mips_num_regs): Set to only used registers.
20823 (mips_regmap): Do not fetch $0. Remove unused registers. Add
20824 an entry for the restart register.
20825 (mips_cannot_fetch_register, mips_cannot_store_register)
20826 (mips_reinsert_addr, mips_fill_fpregset, mips_store_fpregset): Update
20827 register names to match the XML descriptions.
20828 (mips_fill_gregset, mips_store_gregset): Likewise. Handle the
20829 restart register instead of $0.
20830
0e7f50da
UW
208312007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
20832 Markus Deuling <deuling@de.ibm.com>
20833
20834 * remote-utils.c (decode_xfer_write): New function.
20835 * server.h (decode_xfer_write): Add prototype.
20836 * server.c (handle_query): Add PACKET_LEN argument. Support
20837 qXfer:spu:read and qXfer:spu:write packets.
20838 (main): Pass packet_len to handle_query.
20839 * spu-low.c (spu_target_ops): Add spu_proc_xfer_spu.
20840 * target.h (target_ops): Add qxfer_spu.
20841
374c1d38
UW
208422007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
20843
20844 * spu-low.c (spu_proc_xfer_spu): Do not return failure when
20845 accessing non-seekable spufs files.
20846
bb63802a
UW
208472007-05-16 Markus Deuling <deuling@de.ibm.com>
20848
889bf7c5 20849 * server.c (handle_query): Add reply for qC packet.
bb63802a 20850
7390519e
PA
208512007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20852 Leo Zayas <lerele@champenstudios@com>
20853
20854 * server.h (check_remote_input_interrupt_request): New function.
20855 * remote_utils.c (INVALID_DESCRIPTOR): New define.
20856 (remote_desc): Initialize with INVALID_DESCRIPTOR.
20857 (input_interrupt): Expose on USE_WIN32API too. Fix whitespace.
20858 (check_remote_input_interrupt_request): New function.
20859 * server.h (check_remote_input_interrupt_request): Declare.
3ecf0694 20860 * win32-low.c (winapi_DebugBreakProcess,
7390519e
PA
20861 winapi_GenerateConsoleCtrlEvent): New typedefs.
20862 (get_child_debug_event): Lower Win32 debug event polling from 1 sec
20863 to 250 ms.
20864 (win32_wait): Check for remote interrupt request
20865 with check_remote_input_interrupt_request.
20866 (win32_request_interrupt): New function.
20867 (win32_target_op): Set request_interrupt to win32_request_interrupt.
20868
34b34921
PA
208692007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20870
20871 * win32-low.c (debug_registers_changed,
20872 debug_registers_used, CONTEXT_EXTENDED_REGISTERS,
20873 CONTEXT_FLOATING_POINT, CONTEXT_DEBUG_REGISTERS,
20874 CONTEXT_DEBUGGER, CONTEXT_DEBUGGER_DR): Delete.
20875 (thread_rec): Get context using the low target.
20876 (child_add_thread): Call thread_added on the low target,
20877 which does the same thing.
20878 (regptr): Delete.
20879 (do_initial_child_stuff): Remove debug registers references.
20880 Set context using the low target. Resume threads after
20881 setting the contexts.
20882 (child_continue): Remove dead variable. Remove debug
20883 registers references.
20884 (child_fetch_inferior_registers): Go through the low target.
20885 (do_child_store_inferior_registers): Remove.
20886 (child_store_inferior_registers): Go through the low target.
20887 (win32_resume): Remove debug registers references.
20888 Set context using the low target.
20889 (handle_exception): Change return type to void. Don't record
20890 context here. Set status to TARGET_WAITKIND_SPURIOUS on a
20891 first chance exception.
889bf7c5 20892 (get_child_debug_event): Change return type to void. Remove
34b34921
PA
20893 goto loop. Always return after waiting for debug event.
20894 (win32_wait): Convert to switch statement. Handle spurious
20895 events.
20896
20897 * win32-i386-low.c (debug_registers_changed,
20898 debug_registers_used): New.
20899 (initial_stuff): Rename to ...
20900 (i386_initial_stuff): ... this. Clear debug registers
20901 state variables.
20902 (store_debug_registers): Delete.
20903 (i386_get_thread_context): New.
20904 (load_debug_registers): Delete.
20905 (i386_set_thread_context): New.
20906 (i386_thread_added): New.
20907 (single_step): Rename to ...
20908 (i386_single_step): ... this.
20909 (do_fetch_inferior_registers): Rename to ...
20910 (i386_fetch_inferior_register): ... this.
20911 (i386_store_inferior_register): New.
20912 (the_low_target): Adapt to new interface.
20913
20914 * win32-arm-low.c (CONTEXT_FLOATING_POINT): Define.
20915 (arm_get_thread_context): New.
20916 (arm_set_thread_context): New.
20917 (regptr): New.
20918 (do_fetch_inferior_registers): Rename to ...
20919 (arm_fetch_inferior_register): ... this.
20920 (arm_store_inferior_register): New.
20921 (arm_wince_breakpoint): Reimplement as unsigned long.
20922 (arm_wince_breakpoint_len): Define.
20923 (the_low_target): Adapt to new interface.
20924
20925 * win32-low.h (target_ops): Remove regmap, store_debug_registers and
20926 load_debug_registers. Add get_thread_context, set_thread_context,
20927 thread_added and store_inferior_register. Rename
20928 fetch_inferior_registers to fetch_inferior_register.
20929 (regptr): Remove declaration.
20930
dd6953e1
PA
209312007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20932
20933 * linux-low.c (linux_detach): Change return type to int. Return 0.
20934 * spu-low.c (spu_detach): Likewise.
20935
444d6139
PA
209362007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20937
20938 * target.h (target_ops): Change return type of detach to int.
20939 Add join.
20940 (join_inferior): New.
20941 * server.c (main): Don't skip detach support on mingw32.
20942 If the inferior doesn't support detaching return error.
20943 Call join_inferior instead of using waitpid.
20944 * linux-low.c (linux_join): New.
20945 (linux_target_op): Add linux_join.
20946 * spu-low.c (spu_join): New.
20947 (spu_target_ops): Add spu_join.
20948 * win32-low.c (win32_detach): Adapt to new interface.
20949 Reopen current_process_handle before detaching. Issue a child
20950 resume before detaching.
20951 (win32_join): New.
20952 (win32_target_op): Add win32_join.
20953
1d5315fe
PA
209542007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20955
20956 * win32-low.c (win32-attach): Fix return value.
20957 * target.h (target_ops): Describe ATTACH return values.
20958
bf914831
PA
209592007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20960
20961 * win32-low.c (GETPROCADDRESS): Define.
20962 (winapi_DebugActiveProcessStop): Add WINAPI. typedef as pointer.
20963 (winapi_DebugSetProcessKillOnExit): Likewise.
20964 (win32_create_inferior): Force usage of ansi CreateProcessA.
20965 (win32_attach): Use GETPROCADDRESS.
20966 (win32_detach): Likewise.
20967
f72f3e60
PA
209682007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20969
20970 * win32-low.c (win32_wait): Don't use WSTOPSIG.
20971
ed50f18f
PA
209722007-03-30 Pedro Alves <pedro_alves@portugalmail.pt>
20973
20974 * win32-low.c: Commit leftover changes from 2007-03-29.
20975
0c2ead7e
DJ
209762007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
20977
20978 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Make 16-bit
20979 fields short instead of int. Add explicit padding.
20980 (i387_cache_to_fsave): Remove unnecessary casts.
20981 (i387_fsave_to_cache): Doc fix.
20982 (i387_cache_to_fxsave): Remove unnecessary casts and masking.
20983
73725ff3
DJ
209842007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
20985
20986 * i387-fp.c (i387_cache_to_fxsave): Reinitialize val2 before use.
20987 (i387_fxsave_to_cache): Check fp->ftag while building ftag value.
20988
d99f33d8
PA
209892007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
20990
20991 * configure.srv (arm*-*-mingw32ce*): Move near the other
20992 arm targets.
20993
68070c10
PA
209942007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
20995
2482afc6 20996 * configure.ac: Add errno checking.
68070c10
PA
20997 (AC_CHECK_HEADERS): Add errno.h, fcntl.h, signal.h,
20998 sys/file.h and malloc.h.
20999 (AC_CHECK_DECLS): Add perror.
21000 (srv_mingwce): Handle.
2482afc6 21001 * configure.srv (i[34567]86-*-cygwin*): Add
68070c10
PA
21002 win32-i386-low.o to srv_tgtobj.
21003 (i[34567]86-*-mingw*): Likewise.
21004 (arm*-*-mingw32ce*): Add case.
21005 * gdbreplay.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
21006 HAVE_FCNTL_H, HAVE_ERRNO_H, HAVE_MALLOC_H]: Check.
21007 [__MINGW32CE__] (strerror): New function.
21008 [__MINGW32CE__] (errno): Define to GetLastError.
21009 [__MINGW32CE__] (COUNTOF): New macro.
21010 (remote_open): Remove extra close call.
21011 * mem-break.c (delete_breakpoint_at): New function.
21012 * mem-break.h (delete_breakpoint_at): Declare.
21013 * remote-utils.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
21014 HAVE_FCNTL_H, HAVE_UNISTD_H, HAVE_ERRNO_H]: Check.
21015 [USE_WIN32API] (read, write): Add char* casts.
21016 * server.c [HAVE_UNISTD_H, HAVE_SIGNAL_H]: Check.
21017 * server.h: Include wincecompat.h on Windows CE.
21018 [HAVE_ERRNO_H]: Check.
21019 (perror): Declare if not declared.
21020 * utils.c: Add stdlib.h, errno.h and malloc.h includes.
21021 (perror_with_name): Remove errno declaration.
21022 * wincecompat.h: New.
21023 * wincecompat.c: New.
21024 * win32-low.h: New.
21025 * win32-arm-low.c: New.
21026 * win32-i386-low.c: New.
21027 (win32-low.c): Include mem-break.h and win32-low.h, and winnt.h.
21028 (OUTMSG2): Make it safe.
21029 (_T): New macro.
21030 (COUNTOF): New macro.
21031 (NUM_REGS): Get it from the low target.
21032 (CONTEXT_EXTENDED_REGISTERS, CONTEXT_FLOATING_POINT,
21033 CONTEXT_DEBUG_REGISTERS): Add fallbacks to 0.
21034 (thread_rec): Let low target handle debug registers.
21035 (child_add_thread): Likewise.
21036 (child_init_thread_list): Likewise.
21037 (continue_one_thread): Likewise.
21038 (regptr): New.
21039 (do_child_fetch_inferior_registers): Move to ...
21040 * win32-i386-low.c: ... here, and rename to ...
21041 (do_fetch_inferior_registers): ... this.
889bf7c5 21042 * win32-low.c (child_fetch_inferior_registers):
68070c10
PA
21043 Go through the low target.
21044 (do_child_store_inferior_registers): Use regptr.
21045 (strwinerror): New function.
21046 (win32_create_inferior): Handle Windows CE.
21047 Use strwinerror instead of strerror on Windows error
21048 codes. Add program to the error output.
21049 Don't close the main thread handle on Windows CE.
21050 (win32_attach): Use coredll.dll on Windows CE.
21051 (win32_kill): Close current process and current
21052 thread handles.
21053 (win32_detach): Use coredll.dll on Windows CE.
21054 (win32_resume): Let low target handle debug registers, and
21055 step request.
21056 (handle_exception): Add/Remove initial breakpoint. Avoid
21057 non-existant WSTOPSIG on Windows CE.
21058 (win32_read_inferior_memory): Cast to remove warning.
21059 (win32_arch_string): Go through the low target.
21060 (initialize_low): Call set_breakpoint_data with the low
21061 target's breakpoint.
21062 * win32-low.c (dr, FLAG_TRACE_BIT, FCS_REGNUM,
21063 FOP_REGNUM, mappings): Move to ...
21064 * win32-i386-low.c: ... here.
21065 * win32-low.c (win32_thread_info): Move to ...
21066 * win32-low.h: ... here.
21067 * Makefile.in (SFILES): Add win32-low.c, win32-i386-low.c,
21068 win32-arm-low.c and wincecompat.c.
21069 (all:): Add $EXEEXT.
21070 (install-only:): Likewise.
21071 (gdbserver:): Likewise.
21072 (gdbreplay:): Likewise.
21073 * config.in: Regenerate.
21074 * configure: Regenerate.
21075
41093d81
PA
210762007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
21077
21078 * win32-low.c: Rename typedef thread_info to
21079 win32_thread_info throughout.
21080
544afa54
PA
210812007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
21082
21083 * win32-i386-low.c: Rename to ...
21084 * win32-low.c: ... this.
21085 * configure.srv: Replace win32-i386-low.o with win32-low.o.
21086 * Makefile.in: Likewise.
21087
bce7165d
PA
210882007-03-27 Pedro Alves <pedro_alves@portugalmail.pt>
21089
21090 * remote-utils.c (monitor_output): Constify msg parameter.
21091 * server.h (monitor_output): Likewise.
21092 * win32-i386-low.c (handle_output_debug_string): New.
21093 (win32_kill): Handle OUTPUT_DEBUG_STRING_EVENT events using
21094 handle_output_debug_string.
21095 (get_child_debug_event): Likewise.
21096
506c7aa0
DJ
210972007-03-27 Mat Hostetter <mat@lcs.mit.edu>
21098
21099 * server.c (main): Correct strtoul check.
21100
42c81e2a
DJ
211012007-03-27 Jon Ringle <jon@ringle.org>
21102
21103 * linux-low.c: Check __ARCH_HAS_MMU__ also.
21104
9453113a
DJ
211052007-03-27 Brooks Moses <brooks.moses@codesourcery.com>
21106
21107 * Makefile.in: Add dummy "pdf" and "install-pdf" targets.
21108
64a69107
DJ
211092007-02-27 Daniel Jacobowitz <dan@codesourcery.com>
21110
21111 * terminal.h: Check HAVE_SGTTY_H.
21112
211132007-02-27 Mat Hostetter <mat@lcs.mit.edu>
6f8486da
DJ
21114
21115 * remote-utils.c (remote_open): Print out the assigned port number.
21116
c74d0ad8
DJ
211172007-02-26 Daniel Jacobowitz <dan@codesourcery.com>
21118
21119 * remote-utils.c (monitor_output): New function.
21120 * server.c (debug_threads): Define here.
21121 (monitor_show_help): New function.
21122 (handle_query): Handle qRcmd.
21123 (main): Do not handle 'd' packet.
21124 * server.h (debug_threads, remote_debug, monitor_output): Declare.
21125 * linux-low.c, spu-low.c, win32-i386-low.c: Remove definitions
21126 of debug_threads.
21127
de7c3b4a
PA
211282007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
21129
21130 * Makefile.in (EXEEXT): New.
21131 (clean): Use $(EXEEXT).
21132
ef57601b
PA
211332007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
21134
21135 * target.h (target_ops): Rename send_signal to request_interrupt,
21136 and remove enum target_signal parameter.
21137 * linux-low.c (linux_request_interrupt): Rename from
21138 linux_send_signal, and always send SIGINT.
21139 * spu-low.c (spu_request_interrupt): Rename from spu_send_signal,
21140 and always send SIGINT.
21141 * remote-utils.c (putpkt_binary): Call request_interrupt, instead
21142 of send_signal.
21143 (input_interrupt): Likewise.
21144
820f2bda
PA
211452007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
21146
21147 * server.c (get_features_xml): Check if target implemented
21148 arch_string.
21149 * win32-i386-low.c (win32_arch_string): New.
21150 (win32_target_ops): Add win32_arch_string as arch_string member.
21151
ab39bf24
UW
211522007-02-22 Markus Deuling <deuling@de.ibm.com>
21153
21154 * spu-low.c (spu_arch_string): New.
21155 (spu_target_ops): Add spu_arch_string.
21156
61ff6e04
DJ
211572007-02-16 Daniel Jacobowitz <dan@codesourcery.com>
21158
21159 * remote-utils.c: Remove HAVE_TERMINAL_H check.
21160 * configure.ac: Do not check for terminal.h.
21161 * configure, config.in: Regenerated.
21162
fb1e4ffc
DJ
211632007-02-08 Daniel Jacobowitz <dan@codesourcery.com>
21164
21165 * Makefile.in (OBS): Add $(XML_BUILTIN).
21166 (XML_DIR, XML_TARGET, XML_FILES, XML_BUILTIN): New.
21167 (clean): Update.
21168 (target.xml, xml-builtin.c, stamp-xml, arm-with-iwmmxt.o)
21169 (arm-with-iwmmxt.c): New.
21170 * config.in, configure: Regenerate.
21171 * configure.ac: Check for iWMMXt. Handle srv_xmltarget,
21172 srv_xmlbuiltin, and srv_xmlfiles. Define USE_XML.
21173 * configure.srv: Mention srv_xmltarget and srv_xmlfiles.
21174 (arm*-*-linux*): Add iWMMXt and regset support.
21175 * linux-arm-low.c (PTRACE_GETWMMXREGS, PTRACE_SETWMMXREGS): Define.
21176 (arm_fill_gregset, arm_store_gregset, arm_fill_wmmxregset)
21177 (arm_store_wmmxregset, target_regsets): New.
21178 * server.c (get_features_xml): Take annex argument. Check builtin
21179 XML documents.
21180 (handle_query): Handle multiple annexes.
21181
0f48aa01
DJ
211822007-01-29 Daniel Jacobowitz <dan@codesourcery.com>
21183
21184 * remote-utils.c [USE_WIN32API] (read, write): Define.
21185 (putpkt_binary, input_interrupt, readchar, getpkt): Use read and
21186 write.
21187
23181151
DJ
211882007-01-09 Daniel Jacobowitz <dan@codesourcery.com>
21189
21190 * linux-i386-low.c (the_low_target): Set arch_string.
21191 * linux-x86-64-low.c (the_low_target): Likewise.
21192 * linux-low.c (linux_arch_string): New.
21193 (linux_target_ops): Add it.
21194 * linux-low.h (struct linux_target_ops): Add arch_string.
21195 * server.c (write_qxfer_response): Use const void * for DATA.
21196 (get_features_xml): New.
21197 (handle_query): Handle qXfer:features:read. Report it for qSupported.
21198 * target.h (struct target_ops): Add arch_string method.
21199
9d606399
DJ
212002007-01-03 Denis Pilat <denis.pilat@st.com>
21201 Daniel Jacobowitz <dan@codesourcery.com>
21202
21203 * linux-low.c (linux_kill): Handle being called with no threads.
21204 * win32-i386-low.c (win32_kill): Likewise.
21205 (get_child_debug_event): Clear current_process_handle.
21206
212072006-12-30 Denis PILAT <denis.pilat@st.com>
8264bb58
DJ
21208 Daniel Jacobowitz <dan@codesourcery.com>
21209
21210 * remote-utils.c (remote_open): Check the type of specified
21211 serial port devices before opening them.
21212 * server.c (main): Kill the inferior if an error occurs during
21213 the first remote_open.
21214
a5e13d24
DJ
212152006-12-05 Markus Deuling <deuling@de.ibm.com>
21216
21217 * README: Update supported targets.
21218
186947f7
DJ
212192006-11-28 Daniel Jacobowitz <dan@codesourcery.com>
21220
21221 * Makefile.in (clean): Remove reg-mips64.c.
21222 (reg-mips64.c, reg-mips64.o): New rules.
21223 * configure.srv: Handle mips64. Include regset support for mips.
21224 * linux-mips-low.c (union mips_register): New.
21225 (mips_get_pc, mips_set_pc, mips_reinsert_addr): Use it.
21226 (mips_breakpoint, mips_breakpoint_at): Use int.
21227 (mips_collect_register, mips_supply_register)
21228 (mips_collect_register_32bit, mips_supply_register_32bit)
21229 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
21230 (mips_store_fpregset, target_regsets): New.
21231 * thread-db.c (thread_db_get_tls_address): Use uintptr_t.
21232
a13e2c95
UW
212332006-11-22 Ulrich Weigand <uweigand@de.ibm.com>
21234
21235 * configure.srv: Add target "spu*-*-*".
21236 * Makefile.in (clean): Remove reg-spu.c.
21237 (reg-spu.c, reg-spu.o, spu-low.o): Add dependencies.
21238 * spu-low.c: New file.
21239
cb7283db
DJ
212402006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
21241
21242 * configure.ac: Correct td_thr_tls_get_addr test.
21243 * configure: Regenerated.
21244
89be2091
DJ
212452006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
21246
21247 * linux-low.c (linux_wait_for_event): Reformat. Use the
21248 pass_signals array.
21249 * remote-utils.c (decode_address_to_semicolon): New.
21250 * server.c (pass_signals, handle_general_set): New.
21251 (handle_query): Mention QPassSignals for qSupported.
21252 (main): Call handle_general_set.
21253 * server.h (pass_signals, decode_address_to_semicolon): New.
21254
000ef4f0
DJ
212552006-11-06 Daniel Jacobowitz <dan@codesourcery.com>
21256
21257 * server.c (handle_query): Correct error handling for read_auxv.
21258
b7149293
UW
212592005-10-19 Ulrich Weigand <uweigand@de.ibm.com>
21260
21261 * configure.srv [s390-*-linux*, s390x-*-linux*]: Set srv_linux_regsets
21262 and srv_linux_thread_db to yes.
21263 * linux-s390-low.c (s390_fill_gregset): New function.
21264 (target_regsets): Define data structure.
21265
dae5f5cf
DJ
212662006-10-17 Daniel Jacobowitz <dan@codesourcery.com>
21267
21268 * acinclude.m4 (SRV_CHECK_TLS_GET_ADDR): New.
21269 * configure.ac: Use it. Define HAVE_TD_THR_TLS_GET_ADDR.
21270 * config.in, configure: Regenerated.
21271 * inferiors.c (gdb_id_to_thread): New function.
21272 (gdb_id_to_thread_id): Use it.
21273 * linux-low.c (linux_target_ops): Use thread_db_get_tls_address.
21274 * linux-low.h (struct process_info): Add th member.
21275 (thread_db_get_tls_address): New prototype.
21276 * remote-utils.c (decode_address): Make non-static.
21277 * server.c (handle_query): Handle qGetTLSAddr.
21278 * server.h (gdb_id_to_thread, decode_address): New prototypes.
21279 * target.h (struct target_ops): Add get_tls_address.
21280 * thread-db.c (maybe_attach_thread): Save the thread handle.
21281 (thread_db_get_tls_address): New.
21282
32ca6d61
DJ
212832006-09-28 Daniel Jacobowitz <dan@codesourcery.com>
21284
21285 * linux-low.c (PTRACE_GETSIGINFO, PTRACE_SETSIGINFO): Define.
21286 (linux_resume_one_process): Take a siginfo_t *. Update all
21287 callers. Queue it if necessary. Use PTRACE_SETSIGINFO.
21288 (struct pending_signals): Add a siginfo_t.
21289 (linux_wait_for_process): Always set last_status.
21290 (linux_wait_for_event): Use PTRACE_GETSIGINFO.
21291 (linux_queue_one_thread): Use PTRACE_GETSIGINFO.
21292 * linux-low.h (struct process_info): Add last_status.
21293
5ffff7c1
DJ
212942006-09-21 Daniel Jacobowitz <dan@codesourcery.com>
21295
21296 * remote-utils.c (try_rle): New function.
21297 (putpkt_binary): Use it.
21298
8695c747
DJ
212992006-08-19 Daniel Jacobowitz <dan@codesourcery.com>
21300
21301 * Makefile.in (clean): Clean reg-x86-64-linux.c.
21302 (reg-x86-64-linux.o, reg-x86-64-linux.c): New.
21303 * configure.srv (x86_64-*-linux*): Use reg-x86-64-linux.o.
21304 * linux-x86-64-low.c (x86_64_regmap): Include ORIG_RAX.
21305 (x86_64_fill_gregset, x86_64_store_gregset): Skip floating
21306 point registers.
21307
290fadea
RS
213082006-08-08 Richard Sandiford <richard@codesourcery.com>
21309
21310 * server.c (terminal_fd): New variable.
21311 (old_foreground_pgrp): Likewise.
21312 (restore_old_foreground_pgrp): New function.
21313 (start_inferior): Record the terminal file descriptor in terminal_fd
21314 and its original foreground group in old_foreground_pgrp. Register
21315 restore_old_foreground_pgrp with atexit().
21316
9f2e1e63
DJ
213172006-07-26 Daniel Jacobowitz <dan@codesourcery.com>
21318
21319 * server.c (handle_query): Correct qPart to qXfer.
21320
b80864fb
DJ
213212006-07-22 Daniel Jacobowitz <dan@codesourcery.com>
21322
21323 * configure.ac: Check for more headers which are missing on
21324 Windows. Automatically supply -lwsock32 and USE_WIN32API.
21325 * configure.srv: Add Cygwin and mingw32.
21326 * remote-utils.c: Don't include headers unconditionally which
21327 are missing on mingw32. Include <winsock.h> for mingw32.
21328 (remote_open): Adjust for mingw32 support. Flush
21329 standard error after writing to it.
21330 (remote_close, putpkt_binary, input_interrupt, block_async_io)
21331 (unblock_async_io, enable_async_io, disable_async_io)
21332 (readchar, getpkt): Update for Winsock support.
21333 (prepare_resume_reply): Expect a protocol signal number.
21334 * server.c: Disable <sys/wait.h> on mingw32.
21335 (start_inferior): Adjust for mingw32 support. Flush
21336 standard error after writing to it.
21337 (attach_inferior): Likewise. Use protocol signal
21338 numbers.
21339 (main): Skip 'D' packet on mingw32. Use protocol signal numbers
21340 and names.
21341 * win32-i386-low.c: New file.
21342 * Makefile.in (XM_CLIBS): Set.
21343 (gdbserver, gdbreplay): Use $(INTERNAL_CFLAGS).
21344 (win32-i386-low.o): New dependency rule.
21345 * linux-low.c (linux_wait): Use target signal numbers.
21346 * target.h (struct target_ops): Doc fix.
21347 * server.h (target_signal_to_name): New prototype.
21348 * gdbreplay.c: Don't include headers unconditionally which
21349 are missing on mingw32. Include <winsock.h> for mingw32.
21350 (remote_close, remote_open): Adjust for Winsock support.
21351 * configure, config.in: Regenerated.
21352
0876f84a
DJ
213532006-07-12 Daniel Jacobowitz <dan@codesourcery.com>
21354
21355 * server.c (decode_xfer_read, write_qxfer_response): New.
21356 (handle_query): Take a packet length argument. Handle
21357 qXfer:auxv:read instead of qPart:auxv:read. Mention it in
21358 the qSupported response.
21359 (main): Update call to handle_query.
21360
01f9e8fa
DJ
213612006-06-22 Daniel Jacobowitz <dan@codesourcery.com>
21362
21363 * remote-utils.c (remote_escape_output, remote_unescape_input): New.
21364 (putpkt_binary): Renamed from putpkt and adjusted for binary
21365 data.
21366 (putpkt): New wrapper for putpkt_binary.
21367 (readchar): Don't mask off the high bit.
21368 (decode_X_packet): New function.
21369 * server.c (main): Call putpkt_binary if a handler sets the packet
21370 length. Save the length of the incoming packet. Handle 'X'.
21371 * server.h (gdb_byte, remote_escape_output, decode_X_packet): New.
21372
be2a5f71
DJ
213732006-06-21 Daniel Jacobowitz <dan@codesourcery.com>
21374
21375 * server.c (handle_query): Handle qSupported.
21376
ea025f5f
DJ
213772006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
21378
21379 * remote-utils.c (all_symbols_looked_up): New variable.
21380 (look_up_one_symbol): Check it.
21381 * server.h (look_up_one_symbol): New declaration.
21382 * thread-db.c (thread_db_init): Set all_symbols_looked_up.
21383
9308fc88
DJ
213842006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
21385
21386 * Makefile.in (linux-arm-low.o): Update dependencies.
66f338c7 21387 * linux-arm-low.c: Include "gdb_proc_service.h".
9308fc88
DJ
21388 (PTRACE_GET_THREAD_AREA): Define.
21389 (ps_get_thread_area): New function.
21390
52fb6437
NS
213912006-05-09 Nathan Sidwell <nathan@codesourcery.com>
21392
21393 * configure.srv (m68k*-*-uclinux*): New target.
21394 * linux-low.c (linux_create_inferior): Use vfork on mmuless systems.
21395 (linux_resume_one_process): Remove extraneous cast.
21396 (linux_read_offsets): New.
21397 (linux_target_op): Add linux_read_offsets on mmuless systems.
21398 * server.c (handle_query): Add qOffsets logic.
21399 * target.h (struct target_ops): Add read_offsets.
21400
21b0f40c
DJ
214012006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
21402
21403 * linux-mips-low.c: Include <sys/ptrace.h> and "gdb_proc_service.h".
21404 (PTRACE_GET_THREAD_AREA): Define.
21405 (ps_get_thread_area): New function.
21406 * Makefile.in (linux-i386-low.o, linux-mips-low.o)
21407 (linux-x86-64-low.o): Update.
21408
0050a760
DJ
214092006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
21410
21411 * configure.ac: Remove checks for prfpregset_t.
21412 * gdb_proc_service.h: New file.
21413 * linux-i386-low.c, linux-x86-64-low.c, thread-db.c: Use the
21414 new "gdb_proc_service.h".
21415 * proc-service.c: Likewise.
21416 (ps_pglobal_lookup, ps_pdread, ps_pdwrite): Use psaddr_t.
21417 (ps_lgetfpregs, ps_lsetfpregs): Use a void* argument.
21418 * Makefile.in (gdb_proc_service_h): Updated.
21419 * configure, config.in: Regenerated.
21420
b92a518e
DJ
214212006-03-03 Daniel Jacobowitz <dan@codesourcery.com>
21422
21423 * remote-utils.c (prepare_resume_reply): Move declaration
21424 of gdb_id_from_wait to the top of the block.
21425
545587ee
DJ
214262006-02-15 Daniel Jacobowitz <dan@codesourcery.com>
21427
21428 * linux-low.c (regsets_store_inferior_registers): Read the regset
21429 from the target before filling it.
21430
9db87ebd
DJ
214312006-02-08 Daniel Jacobowitz <dan@codesourcery.com>
21432
21433 * server.c (attach_inferior): Return SIGTRAP for a successful
21434 attach.
21435
dd24457d
DJ
214362006-02-01 Daniel Jacobowitz <dan@codesourcery.com>
21437
21438 * Makefile.in (OBS): Add version.o.
21439 (STAGESTUFF): Delete.
21440 (version.o): Add dependencies.
21441 (version.c): Replace rule.
21442 (clean): Remove version.c.
21443 * server.c (gdbserver_version): New.
21444 (gdbserver_usage): Use printf.
21445 (main): Handle --version and --help.
21446 * server.h (version, host_name): Add declarations.
21447
6f0f660e
EZ
214482005-12-23 Eli Zaretskii <eliz@gnu.org>
21449
889bf7c5
PA
21450 * linux-arm-low.c:
21451 * linux-arm-low.c:
21452 * inferiors.c:
21453 * i387-fp.h:
21454 * i387-fp.c:
21455 * gdbreplay.c:
21456 * regcache.c:
21457 * proc-service.c:
21458 * mem-break.h:
21459 * mem-break.c:
21460 * linux-x86-64-low.c:
21461 * linux-sh-low.c:
21462 * linux-s390-low.c:
21463 * linux-ppc64-low.c:
21464 * linux-ppc-low.c:
21465 * linux-mips-low.c:
21466 * linux-m68k-low.c:
21467 * linux-m32r-low.c:
21468 * linux-low.h:
21469 * linux-low.c:
21470 * linux-ia64-low.c:
21471 * linux-i386-low.c:
21472 * linux-crisv32-low.c:
21473 * thread-db.c:
21474 * terminal.h:
21475 * target.h:
21476 * target.c:
21477 * server.h:
21478 * server.c:
21479 * remote-utils.c:
21480 * regcache.h:
21481 * utils.c:
21482 * Makefile.in:
21483 * configure.ac:
6f0f660e
EZ
21484 * gdbserver.1: Add (C) after Copyright. Update the FSF
21485 address.
21486
9d1fb177
DJ
214872005-11-13 Daniel Jacobowitz <dan@codesourcery.com>
21488
21489 * linux-arm-low.c (arm_eabi_breakpoint): New variable.
21490 (arm_breakpoint_at): Recognize both breakpoints.
21491 (the_low_target): Use the correct breakpoint instruction.
21492
011a70c2
DJ
214932005-11-02 Daniel Jacobowitz <dan@codesourcery.com>
21494
21495 * configure.srv (x86_64-*-linux*): Turn on thread_db support.
21496 * linux-x86-64-low.c (x86_64_breakpoint, x86_64_breakpoint_len)
21497 (x86_64_get_pc, x86_64_set_pc, x86_64_breakpoint_at): New.
21498 (the_low_target): Update.
21499
7fb85e41
AS
215002005-10-25 Andreas Schwab <schwab@suse.de>
21501
21502 * server.c (main): Allocate mem_buf with PBUFSIZ bytes.
21503
21504 * linux-ia64-low.c (ia64_regmap): Remove NAT registers.
21505 (ia64_num_regs): Reduce to 462.
21506
3db0444b
DJ
215072005-09-17 Daniel Jacobowitz <dan@codesourcery.com>
21508
21509 * acinclude.m4: Correct quoting.
21510 * aclocal.m4: Regenerated.
21511
21512 Suggested by SZOKOVACS Robert <szo@ies.hu>:
21513 * thread-db.c (thread_db_err_str): Handle TD_VERSION.
21514 (thread_db_init): Call thread_db_err_str.
21515 * configure.ac: Check for TD_VERSION.
21516 * config.in, configure: Regenerated.
21517
bee0189a
DJ
215182005-07-31 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
21519
21520 * server.h (error, fatal, warning): Add ATTR_FORMAT.
21521
e9d25b98
DJ
215222005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
21523
21524 * configure.ac: Define HAVE_LINUX_REGSETS even if PTRACE_GETREGS
21525 is not available. Define HAVE_PTRACE_GETREGS if it is.
21526 * config.in, configure: Regenerated.
21527 * configure.srv: Set srv_linux_regsets for PowerPC and PowerPC64.
21528 * linux-i386-low.c, linux-m68k-low.c: Update to use
21529 HAVE_PTRACE_GETREGS.
21530 * linux-low.c (regsets_fetch_inferior_registers)
21531 (regsets_store_inferior_registers): Only return 0 if we processed
21532 GENERAL_REGS.
21533 * linux-ppc-low.c (ppc_fill_gregset, target_regsets): New.
21534 * linux-ppc64-low.c (ppc_fill_gregset, target_regsets): New.
21535
a06660f7
DJ
215362005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
21537
21538 * inferiors.c (struct thread_info): Add gdb_id.
21539 (add_thread): Add gdb_id argument.
21540 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New.
21541 * linux-low.c (linux_create_inferior, linux_attach_lwp): Update
21542 calls to add_thread.
21543 * remote-utils.c (prepare_resume_reply: Use thread_to_gdb_id.
21544 * server.c (handle_query): Use thread_to_gdb_id.
21545 (handle_v_cont, main): Use gdb_id_to_thread_id.
21546 * server.h (add_thread): Update prototype.
21547 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New
21548 prototypes.
21549
5a1f5858
DJ
215502005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
21551
21552 * linux-low.c (fetch_register, usr_store_inferior_registers): Handle
21553 left-padded registers.
21554 * linux-low.h (struct linux_target_ops): Add left_pad_xfer.
21555 * linux-ppc64-low.c (the_low_target): Set left_pad_xfer.
21556
e122f1f5
SE
215572005-07-01 Steve Ellcey <sje@cup.hp.com>
21558
21559 * configure.ac (BFD_NEED_DECLARATION): Replace with AC_CHECK_DECLS.
21560 * configure: Regenerate.
21561 * config.in: Regenerate.
21562 * server.h (NEED_DECLARATION_STRERROR):
21563 Replace with !HAVE_DECL_STRERROR.
21564
d592fa2f
DJ
215652005-06-16 Daniel Jacobowitz <dan@codesourcery.com>
21566
21567 * linux-low.c (linux_wait, linux_send_signal): Don't test
21568 an unsigned long variable for > 0 if it could be MAX_ULONG.
21569 * server.c (myresume): Likewise.
21570 * target.c (set_desired_inferior): Likewise.
21571
ccbd4912
MK
215722005-06-13 Mark Kettenis <kettenis@gnu.org>
21573
21574 * configure.ac: Simplify and improve check for socklen_t.
21575 * configure, config.in: Regenerate.
21576
f450004a
DJ
215772005-06-12 Daniel Jacobowitz <dan@codesourcery.com>
21578
21579 * acconfig.h: Remove.
21580 * configure.ac: Add a test for socklen_t. Use three-argument
21581 AC_DEFINE throughout.
21582 * config.in: Regenerated using autoheader 2.59.
21583 * configure: Regenerated.
21584
21585 * gdbreplay.c (socklen_t): Provide a default.
21586 (remote_open): Use socklen_t.
21587 * remote-utils.c (socklen_t): Provide a default.
21588 (remote_open): Use socklen_t.
21589 (convert_int_to_ascii, convert_ascii_to_int, decode_M_packet): Use
21590 unsigned char.
21591
21592 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Use unsigned
21593 char for buffers.
21594 * linux-low.c (linux_read_memory, linux_write_memory)
21595 (linux_read_auxv): Likewise.
21596 * mem-break.c (breakpoint_data, set_breakpoint_data, check_mem_read)
21597 (check_mem_write): Likewise.
21598 * mem-break.h (set_breakpoint_data, check_mem_read, check_mem_write):
21599 Likewise.
21600 * regcache.c (struct inferior_rgcache_data, registers_to_string)
21601 (registers_from_string, register_data): Likewise.
21602 * server.c (handle_query, main): Likewise.
21603 * server.h (convert_ascii_to_int, convert_int_to_ascii)
21604 (decode_M_packet): Likewise.
21605 * target.c (read_inferior_memory, write_inferior_memory): Likewise.
21606 * target.h (struct target_ops): Update read_memory, write_memory,
21607 and read_auxv.
21608 (read_inferior_memory, write_inferior_memory): Update.
21609 * linux-low.h (struct linux_target_ops): Change type of breakpoint
21610 to unsigned char *.
21611 * linux-arm-low.c, linux-cris-low.c, linux-crisv32-low.c,
21612 linux-i386-low.c, linux-m32r-low.c, linux-m68k-low.c,
21613 linux-mips-low.c, linux-ppc-low.c, linux-ppc64-low.c,
21614 linux-s390-low.c, linux-sh-low.c: Update for changes in
21615 read_inferior_memory and the_low_target->breakpoint.
21616
eee84df1
DJ
216172005-05-28 Daniel Jacobowitz <dan@codesourcery.com>
21618
21619 * Makefile.in (SFILES): Add linux-ppc64-low.c.
21620 (linux-ppc64-low.o, reg-ppc64.c, reg-ppc64.o): New targets.
21621 * configure.srv: Add powerpc64-*-linux*.
21622 * linux-ppc64-low.c: New file.
21623
45b134e5
OF
216242005-05-23 Orjan Friberg <orjanf@axis.com>
21625
21626 * linux-cris-low.c: New file with support for CRIS.
21627 * linux-crisv32-low.c: Ditto for CRISv32.
21628 * Makefile.in (SFILES): Add linux-cris-low.c, linux-crisv32-low.c.
21629 (clean): Add reg-cris.c and reg-crisv32.c.
889bf7c5 21630 Add linux-cris-low.o, linux-crisv32-low.o, reg-cris.o, reg-cris.c,
45b134e5
OF
21631 reg-crisv32.o, and reg-crisv32.c to make rules.
21632 * configure.srv: Add cris-*-linux* and crisv32-*-linux* to list of
21633 recognized targets.
21634
48d93c75
UW
216352005-05-16 Ulrich Weigand <uweigand@de.ibm.com>
21636
21637 * linux-low.c (fetch_register): Ensure buffer size is a multiple
21638 of sizeof (PTRACE_XFER_TYPE).
21639 (usr_store_inferior_registers): Likewise. Zero out excess bytes.
21640
e013ee27
OF
216412005-05-12 Orjan Friberg <orjanf@axis.com>
21642
889bf7c5 21643 * target.h (struct target_ops): Add insert_watchpoint,
e013ee27
OF
21644 remove_watchpoint, stopped_by_watchpoint, stopped_data_address function
21645 pointers for hardware watchpoint support.
21646 * linux-low.h (struct linux_target_ops): Ditto.
21647 * linux-low.c (linux_insert_watchpoint, linux_remove_watchpoint)
21648 (linux_stopped_by_watchpoint, linux_stopped_data_address): New. Add
21649 to linux_target_ops.
21650 * remote-utils.c (prepare_resume_reply): Add watchpoint information to
21651 reply packet.
21652 * server.c (main): Recognize 'Z' and 'z' packets.
21653
b0ded00b
UW
216542005-05-10 Ulrich Weigand <uweigand@de.ibm.com>
21655
21656 * linux-s390-low.c (s390_breakpoint, s390_breakpoint_len): Define.
21657 (s390_get_pc, s390_set_pc, s390_breakpoint_at): New functions.
21658 (the_low_target): Add new members.
21659
8643e2ad
DJ
216602005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
21661
21662 * proc-service.c (ps_lgetregs): Search all_processes instead of
21663 all_threads.
21664
fc620387
DJ
216652005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
21666
21667 * server.c (start_inferior): Change return type to int.
21668 (attach_inferior): Change sigptr to int *.
21669 (handle_v_cont, handle_v_requests): Change signal to int *.
21670 (main): Change signal to int.
21671
216722005-04-15 Kei Sakamoto <sakamoto.kei@renesas.com>
7cfbc4a0
KI
21673
21674 * Makefile.in: Add linux-m32r-low.o, reg-m32r.c and reg-m32r.o.
21675 * configure.srv: Add m32r*-*-linux*.
21676 * linux-m32r-low.c: New file.
21677
e0e76420
DJ
216782005-03-04 Daniel Jacobowitz <dan@codesourcery.com>
21679
21680 * Makefile.in (stamp-h): Set CONFIG_HEADERS explicitly.
21681
a1928bad
DJ
216822005-03-03 Daniel Jacobowitz <dan@codesourcery.com>
21683
21684 * inferiors.c (change_inferior_id, add_thread, find_inferior_id):
21685 Take unsigned long arguments for PIDs.
21686 * linux-low.c (add_process, linux_attach_lwp, linux_attach)
21687 (linux_thread_alive, linux_wait_for_event, kill_lwp, send_sigstop)
21688 (wait_for_sigstop, linux_resume_one_process)
21689 (regsets_fetch_inferior_registers, linux_send_signal)
21690 (linux_read_auxv): Likewise. Update the types of variables holding
21691 PIDs. Update format string specifiers.
21692 * linux-low.h (struct process_info, linux_attach_lwp): Likewise.
21693 * remote-utils.c (prepare_resume_reply): Likewise.
21694 * server.c (cont_thread, general_thread, step_thread)
21695 (thread_from_wait, old_thread_from_wait, signal_pid): Change type to
21696 unsigned long.
21697 (handle_query): Update format specifiers.
21698 (handle_v_cont, main): Use strtoul for thread IDs.
21699 * server.h (struct inferior_list_entry): Use unsigned long for ID.
21700 (add_thread, find_inferior_id, change_inferior_id, cont_thread)
21701 (general_thread, step_thread, thread_from_wait)
21702 (old_thread_from_wait): Update.
21703 * target.h (struct thread_resume): Use unsigned long for THREAD.
21704 (struct target_ops): Use unsigned long for arguments to attach and
21705 thread_alive.
21706
dcdb98d2
DJ
217072005-02-24 Daniel Jacobowitz <dan@codesourcery.com>
21708
21709 * acinclude.m4: Include bfd/bfd.m4 directly.
21710 * configure.ac: Use AC_ARG_PROGRAM. Suggested by Aron Griffis
21711 <agriffis@toolchain.org>.
21712 * aclocal.m4, configure: Regenerated.
21713
bec39cab
AC
217142005-01-07 Andrew Cagney <cagney@gnu.org>
21715
21716 * configure.ac: Rename configure.in, require autoconf 2.59.
21717 * configure: Re-generate.
21718
434c4c77
DJ
217192004-12-08 Daniel Jacobowitz <dan@debian.org>
21720
21721 * acinclude.m4 (SRV_CHECK_THREAD_DB): Add ps_get_thread_area. Reset
21722 LIBS when finished.
21723 * aclocal.m4: Regenerated.
21724 * configure: Regenerated.
21725
db1d3e1b
AS
217262004-11-21 Andreas Schwab <schwab@suse.de>
21727
21728 * linux-m68k-low.c (m68k_num_gregs): Define.
21729 (m68k_fill_gregset, m68k_store_gregset, m68k_fill_fpregset)
21730 (m68k_store_fpregset, target_regsets) [HAVE_LINUX_REGSETS]: New.
21731 (m68k_breakpoint, m68k_breakpoint_len, m68k_get_pc, m68k_set_pc)
21732 (m68k_breakpoint_at): New. Add to the_low_target.
21733
21734 * configure.srv (m68*-*-linux*): Set srv_linux_regsets and
21735 srv_linux_thread_db to yes.
21736
43360365
JB
217372004-10-20 Joel Brobecker <brobecker@gnat.com>
21738
21739 * linux-x86-64-low.c (ARCH_SET_GS): Add definition if missing.
21740 (ARCH_SET_FS): Likewise.
21741 (ARCH_GET_FS): Likewise.
21742 (ARCH_GET_GS): Likewise.
21743
fd500816
DJ
217442004-10-16 Daniel Jacobowitz <dan@debian.org>
21745
21746 * linux-i386-low.c (ps_get_thread_area): New.
21747 * linux-x86-64-low.c (ps_get_thread_area): New.
21748 * linux-low.c: Include <sys/syscall.h>.
21749 (linux_kill_one_process): Don't kill the first thread here.
21750 (linux_kill): Kill the first thread here.
21751 (kill_lwp): New function.
21752 (send_sigstop, linux_send_signal): Use it.
21753 * proc-service.c: Clean up #ifdefs.
21754 (fpregset_info): Delete.
21755 (ps_lgetregs): Update and enable implementation.
21756 (ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs): Remove disabled
21757 implementations.
21758 * remote-utils.c (struct sym_cache, symbol_cache): New.
21759 (input_interrupt): Print a clearer message.
21760 (async_io_enabled): New variable.
21761 (enable_async_io, disable_async_io): Use it. Update comments.
21762 (look_up_one_symbol): Use the symbol cache.
21763 * thread-db.c (thread_db_look_up_symbols): New function.
21764 (thread_db_init): Update comments. Call thread_db_look_up_symbols.
21765
f6de3c42
DJ
217662004-10-16 Daniel Jacobowitz <dan@debian.org>
21767
21768 * configure.in: Test for -rdynamic.
21769 * configure: Regenerated.
21770 * Makefile (INTERNAL_LDFLAGS): New.
21771 (gdbserver, gdbreplay): Use it.
21772
2c0fc042
AC
217732004-09-02 Andrew Cagney <cagney@gnu.org>
21774
21775 * Makefile.in (TAGS): Replace TM_FILE with DEPRECATED_TM_FILE.
21776
075b3282
DJ
217772004-03-23 Daniel Jacobowitz <drow@mvista.com>
21778
21779 * linux-low.c (linux_wait): Clear all_processes list also.
21780
fa6a77dc
DJ
217812004-03-12 Daniel Jacobowitz <drow@mvista.com>
21782
21783 * linux-low.c: Include <errno.h>. Remove extern declaration of
21784 errno.
21785
6d782a97
DJ
217862004-03-12 Daniel Jacobowitz <drow@mvista.com>
21787
21788 * gdbreplay.c, server.h, utils.c: Update copyright years.
21789
3a7fb99b
DJ
217902004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
21791
21792 * server.c (main): Print child status or termination signal from
21793 variable 'signal', not 'sig'.
21794
c3e735a6
DJ
217952004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
21796
21797 * linux-low.c (linux_read_memory): Change return type to
21798 int. Check for and return error from ptrace().
21799 * target.c (read_inferior_memory): Change return type to int. Pass
21800 back return status from the_target->read_memory().
21801 * target.h (struct target_ops): Adapt *read_memory() prototype.
21802 Update comment.
21803 (read_inferior_memory): Adapt prototype.
21804 * server.c (main): Return an error packet if
21805 read_inferior_memory() returns an error.
21806
a59d1c82
DJ
218072004-03-04 Daniel Jacobowitz <drow@mvista.com>
21808
21809 * Makefile.in (distclean): Remove config.h, stamp-h, and config.log.
21810 Unify with other clean targets.
21811
dc3f8883
DJ
218122004-02-29 Daniel Jacobowitz <drow@mvista.com>
21813
21814 * server.c (handle_v_cont): Call set_desired_inferior.
21815
89a208da
DJ
218162004-02-29 Daniel Jacobowitz <drow@mvista.com>
21817
21818 * remote-utils.c (prepare_resume_reply): Always supply "thread:".
21819
62ea82f5
DJ
218202004-02-29 Daniel Jacobowitz <drow@mvista.com>
21821
21822 * linux-low.c (linux_wait): Unblock async I/O.
21823 (linux_resume): Block and enable async I/O.
21824 * remote-utils.c (block_async_io, unblock_async_io): New functions.
21825 * server.h (block_async_io, unblock_async_io): Add prototypes.
21826
6910d122
DJ
218272004-02-29 Daniel Jacobowitz <drow@mvista.com>
21828
21829 * remote-utils.c (remote_open): Print a status notice after
21830 opening a TCP port.
21831 * server.c (attach_inferior): Print a status notice after
21832 attaching.
21833
218342004-02-29 Daniel Jacobowitz <drow@mvista.com>
d677d77d
DJ
21835
21836 * linux-arm-low.c (arm_get_pc): Print out stop PC in debug mode.
21837
c89dc5d4
DJ
218382004-02-26 Daniel Jacobowitz <drow@mvista.com>
21839
21840 * remote-utils.c (write_enn): Use "E01" instead of "ENN" for the
21841 error packet.
21842 * server.c, target.h: Update copyright years.
21843
4b8dad4a
RM
218442004-02-25 Roland McGrath <roland@redhat.com>
21845
21846 * target.h (struct target_ops): New member `read_auxv'.
21847 * server.c (handle_query): Handle qPart:auxv:read: query using that.
21848 * linux-low.c (linux_read_auxv): New function.
21849 (linux_target_ops): Initialize `read_auxv' member to that.
21850
d7446758
JB
218512004-02-17 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
21852
21853 Committed by Jim Blandy <jimb@redhat.com>.
21854
21855 * linux-s390-low.c (s390_num_regs): Update.
4b8dad4a 21856 (s390_regmap): Remove control registers. Use __s390x__ predefine
d7446758
JB
21857 instead of GPR_SIZE to distiguish s390 and s390x targets.
21858
5544ad89
DJ
218592004-01-31 Daniel Jacobowitz <drow@mvista.com>
21860
21861 * linux-low.c: Update copyright year.
21862 (check_removed_breakpoint): Clear pending_is_breakpoint.
21863 (linux_set_resume_request, linux_queue_one_thread)
21864 (resume_status_pending_p): New functions.
21865 (linux_continue_one_thread): Use process->resume.
21866 (linux_resume): Only resume threads if there are no pending events.
21867 * linux-low.h (struct process_info): Add resume request
21868 pointer.
21869
2a68b70e
DJ
218702004-01-30 Daniel Jacobowitz <drow@mvista.com>
21871
21872 * regcache.c (new_register_cache): Clear the allocated register
21873 buffer. Suggested by Atsushi Nemoto <anemo@mba.ocn.ne.jp>.
21874
64386c31
DJ
218752003-10-13 Daniel Jacobowitz <drow@mvista.com>
21876
21877 * linux-low.c (linux_resume): Take a struct thread_resume *
21878 argument.
21879 (linux_wait): Update call.
21880 (resume_ptr): New static variable.
21881 (linux_continue_one_thread): Renamed from
21882 linux_continue_one_process. Use resume_ptr.
21883 (linux_resume): Use linux_continue_one_thread.
21884 * server.c (handle_v_cont, handle_v_requests): New functions.
21885 (myresume): New function.
21886 (main): Handle 'v' case.
21887 * target.h (struct thread_resume): New type.
21888 (struct target_ops): Change argument of "resume" to struct
21889 thread_resume *.
21890 (myresume): Delete macro.
21891
c938e9b0
L
218922003-08-08 H.J. Lu <hongjiu.lu@intel.com>
21893
21894 * Makefile.in (install-only): Create dest dir. Support DESTDIR.
21895 (uninstall): Support DESTDIR.
21896
7f313d07
BC
21897Mon Jul 21 20:09:34 UTC 2003 Brendan Conoboy <blc@redhat.com>
21898
21899 * configure.srv: Add xscale*linux copy of arm*linux entry.
21900
3b2fc2ea
DJ
219012003-07-24 Daniel Jacobowitz <drow@mvista.com>
21902
21903 * linux-arm-low.c (arm_reinsert_addr): New function.
21904 (the_low_target): Add arm_reinsert_addr.
21905
1c0a559e
MK
219062003-07-08 Mark Kettenis <kettenis@gnu.org>
21907
21908 * mem-break.c: Remove whitespace at end of file.
21909
43d5792c
DJ
219102003-06-28 Daniel Jacobowitz <drow@mvista.com>
21911
21912 * configure.in: Check whether we need to prototype strerror.
21913 * server.h: Optionally prototype strerror.
21914 * gdbreplay.c (perror_with_name): Use strerror.
21915 * linux-low.c (linux_attach_lwp): Use strerror.
21916 * utils.c (perror_with_name): Use strerror.
21917 * config.in, configure: Regenerated.
21918
c8a86edf
DJ
219192003-06-28 Daniel Jacobowitz <drow@mvista.com>
21920
21921 * linux-sh-low.c (sh_regmap): Fix FP register offsets, reported by
21922 SUGIOKA Toshinobu <sugioka@itonet.co.jp>.
21923
73d37363
DJ
219242003-06-20 Daniel Jacobowitz <drow@mvista.com>
21925
21926 * Makefile.in (SFILES): Update.
21927 * low-hppabsd.c, low-lynx.c, low-nbsd.c, low-sim.c, low-sparc.c,
21928 low-sun3.c: Remove files.
21929
6ad8ae5c
DJ
219302003-06-17 Daniel Jacobowitz <drow@mvista.com>
21931
21932 * linux-low.c: Move comment to linux_thread_alive where it belonged.
21933 (linux_detach_one_process, linux_detach): New functions.
21934 (linux_target_ops): Add linux_detach.
21935 * server.c (main): Handle 'D' packet.
21936 * target.h (struct target_ops): Add "detach" member.
21937 (detach_inferior): Define.
21938
1581182a
MK
219392003-06-13 Mark Kettenis <kettenis@gnu.org>
21940
21941 From Kelley Cook <kelleycook@wideopenwest.com>:
21942 * configure.srv: Accept i[34567]86 variants.
21943
e5379b03
DJ
219442003-06-05 Daniel Jacobowitz <drow@mvista.com>
21945
21946 * linux-low.c (linux_wait_for_event): Correct comment typos.
21947 (linux_resume_one_process): Call check_removed_breakpoint.
21948 (linux_send_signal): New function.
21949 (linux_target_ops): Add linux_send_signal.
21950 * remote-utils.c (putpkt, input_interrupt): Use send_signal instead
21951 of kill.
21952 * target.h (struct target_ops): Add send_signal.
21953
2ff29de4
JB
219542003-05-29 Jim Blandy <jimb@redhat.com>
21955
21956 * linux-low.c (usr_store_inferior_registers): Transfer buf in
21957 PTRACE_XFER_TYPE-sized chunks, not int-sized chunks. Otherwise,
21958 if 'int' is smaller than PTRACE_XFER_TYPE, you end up throwing
21959 away part of the register's value.
21960
254787d4
DJ
219612003-03-26 Daniel Jacobowitz <drow@mvista.com>
21962
21963 * linux-low.c (linux_create_inferior): Use __SIGRTMIN.
21964 (linux_wait_for_event, linux_init_signals): Likewise.
21965
94e10508
DJ
219662003-03-17 Daniel Jacobowitz <drow@mvista.com>
21967
21968 * configure.in: Check for stdlib.h.
21969 * configure: Regenerated.
21970 * config.in: Regenerated.
21971
4c0711e0
DJ
219722003-01-04 Andreas Schwab <schwab@suse.de>
21973
21974 * linux-m68k-low.c (m68k_num_regs): Define to 29 instead of 31.
21975
ef66e766
AC
219762003-01-02 Andrew Cagney <ac131313@redhat.com>
21977
21978 * Makefile.in: Remove obsolete code.
21979
a1358604
DJ
219802002-11-20 Daniel Jacobowitz <drow@mvista.com>
21981
21982 * linux-s390-low.c (s390_regmap): Check GPR_SIZE instead of
21983 defined(PT_FPR0_HI).
21984
23ce3b1c
DJ
219852002-11-17 Stuart Hughes <seh@zee2.com>
21986
21987 * linux-arm-low.c (arm_num_regs): Increase.
21988 (arm_regmap): Include status register.
21989
219902002-11-17 Daniel Jacobowitz <drow@mvista.com>
21991
21992 * linux-low.c (register_addr): Remove incorrect -1 check.
21993
a9fa9f7d
DJ
219942002-08-29 Daniel Jacobowitz <drow@mvista.com>
21995
21996 * linux-low.c (linux_create_inferior): Call setpgid. Return
21997 the new PID.
21998 (unstopped_p, linux_signal_pid): Remove.
21999 (linux_target_ops): Remove linux_signal_pid.
22000 * remote-utils.c (putpkt, input_interrupt): Use signal_pid
22001 global instead of target method.
22002 * target.h (struct target_ops): Remove signal_pid. Update comment
22003 for create_inferior.
22004 * server.c (signal_pid): New variable.
22005 (create_inferior): Set signal_pid. Block SIGTTOU and SIGTTIN in
4b8dad4a 22006 gdbserver. Set the child to be the foreground process group.
a9fa9f7d
DJ
22007 (attach_inferior): Set signal_pid.
22008
17574093
DJ
220092002-08-23 Daniel Jacobowitz <drow@mvista.com>
22010
22011 * ChangeLog: New file, with entries from gdb/ChangeLog after GDB 5.2.
22012
220132002-08-20 Jim Blandy <jimb@redhat.com>
22014
22015 * Makefile.in (LDFLAGS): Allow the configure script to establish a
22016 default for this.
22017
220182002-08-01 Andrew Cagney <cagney@redhat.com>
22019
22020 * Makefile.in: Make chill references obsolete.
22021
220222002-07-24 Kevin Buettner <kevinb@redhat.com>
22023
22024 * configure.in (unistd.h): Add to AC_CHECK_HEADERS list.
22025 * configure: Regenerate.
22026 * config.in: Regenerate.
22027
220282002-07-09 David O'Brien <obrien@FreeBSD.org>
22029
22030 * gdbreplay.c (stdlib.h, unistd.h): Conditionaly include.
22031 (perror_with_name, remote_close, remote_open, expect, play): Static.
22032
220332002-07-04 Michal Ludvig <mludvig@suse.cz>
22034
4b8dad4a 22035 * linux-x86-64-low.c (x86_64_regmap): Make it an array of
17574093
DJ
22036 byte offsets instead of an array of indexes.
22037 (x86_64_store_gregset, x86_64_store_fpregset): Parameter made const.
22038
220392002-06-13 Daniel Jacobowitz <drow@mvista.com>
22040
22041 * regcache.c: Add comment.
22042
220432002-06-11 Daniel Jacobowitz <drow@mvista.com>
22044
22045 * thread-db.c: New file.
22046 * proc-service.c: New file.
22047 * acinclude.m4: New file.
22048 * Makefile.in: Add GDBSERVER_LIBS, gdb_proc_service_h,
22049 proc-service.o, and thread-db.o.
22050 (linux-low.o): Add USE_THREAD_DB.
22051 * acconfig.h: Add HAVE_PRGREGSET_T, HAVE_PRFPREGSET_T,
22052 HAVE_LWPID_T, HAVE_PSADDR_T, and PRFPREGSET_T_BROKEN.
22053 * aclocal.m4: Regenerated.
22054 * config.in: Regenerated.
22055 * configure: Regenerated.
22056 * configure.in: Check for proc_service.h, sys/procfs.h,
22057 thread_db.h, and linux/elf.h headrs.
22058 Check for lwpid_t, psaddr_t, prgregset_t, prfpregset_t, and
22059 PRFPREGSET_T_BROKEN. Introduce srv_thread_depfiles and USE_THREAD_DB.
22060 Check for -lthread_db and thread support.
22061 * configure.srv: Enable thread_db support for ARM, i386, MIPS,
22062 PowerPC, and SuperH.
22063 * i387-fp.c: Constify arguments.
22064 * i387-fp.h: Likewise.
22065 * inferiors.c: (struct thread_info): Renamed from
22066 `struct inferior_info'. Remove PID member. Use generic inferior
22067 list header. All uses updated.
22068 (inferiors, signal_pid): Removed.
22069 (all_threads): New variable.
22070 (get_thread): Define.
22071 (add_inferior_to_list): New function.
22072 (for_each_inferior): New function.
22073 (change_inferior_id): New function.
22074 (add_inferior): Removed.
22075 (remove_inferior): New function.
22076 (add_thread): New function.
22077 (free_one_thread): New function.
22078 (remove_thread): New function.
22079 (clear_inferiors): Use for_each_inferior and free_one_thread.
22080 (find_inferior): New function.
22081 (find_inferior_id): New function.
22082 (inferior_target_data): Update argument type.
22083 (set_inferior_target_data): Likewise.
22084 (inferior_regcache_data): Likewise.
22085 (set_inferior_regcache_data): Likewise.
22086 * linux-low.c (linux_bp_reinsert): Remove.
22087 (all_processes, stopping_threads, using_thrads)
22088 (struct pending_signals, debug_threads, pid_of): New.
22089 (inferior_pid): Replace with macro.
22090 (struct inferior_linux_data): Remove.
22091 (get_stop_pc, add_process): New functions.
22092 (linux_create_inferior): Restore SIGRTMIN+1 before calling exec.
22093 Use add_process and add_thread.
22094 (linux_attach_lwp): New function, based on old linux_attach. Use
22095 add_process and add_thread. Set stop_expected for new threads.
22096 (linux_attach): New function.
22097 (linux_kill_one_process): New function.
22098 (linux_kill): Kill all LWPs.
22099 (linux_thread_alive): Use find_inferior_id.
22100 (check_removed_breakpoints, status_pending_p): New functions.
22101 (linux_wait_for_process): Renamed from linux_wait_for_one_inferior.
22102 Update. Use WNOHANG. Wait for cloned processes also. Update process
22103 struct for the found process.
22104 (linux_wait_for_event): New function.
22105 (linux_wait): Use it. Support LWPs.
22106 (send_sigstop, wait_for_sigstop, stop_all_processes)
22107 (linux_resume_one_process, linux_continue_one_process): New functions.
22108 (linux_resume): Support LWPs.
22109 (REGISTER_RAW_SIZE): Remove.
22110 (fetch_register): Use register_size instead. Call supply_register.
22111 (usr_store_inferior_registers): Likewise. Call collect_register.
22112 Fix recursive case.
22113 (regsets_fetch_inferior_registers): Improve error message.
22114 (regsets_store_inferior_registers): Add debugging.
22115 (linux_look_up_symbols): Call thread_db_init if USE_THREAD_DB.
22116 (unstopped_p, linux_signal_pid): New functions.
22117 (linux_target_ops): Add linux_signal_pid.
22118 (linux_init_signals): New function.
22119 (initialize_low): Call it. Initialize using_threads.
22120 * regcache.c (inferior_regcache_data): Add valid
22121 flag.
22122 (get_regcache): Fetch registers lazily. Add fetch argument
22123 and update all callers.
22124 (regcache_invalidate_one, regcache_invalidate): New
22125 functions.
22126 (new_register_cache): Renamed from create_register_cache.
22127 Return the new regcache.
22128 (free_register_cache): Change argument to a void *.
22129 (registers_to_string, registers_from_string): Call get_regcache
22130 with fetch flag set.
22131 (register_data): Make static. Pass fetch flag to get_regcache.
22132 (supply_register): Call get_regcache with fetch flag clear.
22133 (collect_register): Call get_regcache with fetch flag set.
22134 (collect_register_as_string): New function.
22135 * regcache.h: Update.
22136 * remote-utils.c (putpkt): Flush after debug output and use
22137 stderr.
22138 Handle input interrupts while waiting for an ACK.
22139 (input_interrupt): Use signal_pid method.
22140 (getpkt): Flush after debug output and use stderr.
22141 (outreg): Use collect_register_as_string.
22142 (new_thread_notify, dead_thread_notify): New functions.
22143 (prepare_resume_reply): Check using_threads. Set thread_from_wait
22144 and general_thread.
22145 (look_up_one_symbol): Flush after debug output.
22146 * server.c (step_thread, server_waiting): New variables.
22147 (start_inferior): Don't use signal_pid. Update call to mywait.
22148 (attach_inferior): Update call to mywait.
22149 (handle_query): Handle qfThreadInfo and qsThreadInfo.
22150 (main): Don't fetch/store registers explicitly. Use
22151 set_desired_inferior. Support proposed ``Hs'' packet. Update
22152 calls to mywait.
22153 * server.h: Update.
22154 (struct inferior_list, struct_inferior_list_entry): New.
22155 * target.c (set_desired_inferior): New.
22156 (write_inferior_memory): Constify.
22157 (mywait): New function.
22158 * target.h: Update.
22159 (struct target_ops): New signal_pid method.
22160 (mywait): Removed macro, added prototype.
22161
22162 * linux-low.h (regset_func): Removed.
22163 (regset_fill_func, regset_store_func): New.
22164 (enum regset_type): New.
22165 (struct regset_info): Add type field. Use new operation types.
22166 (struct linux_target_ops): stop_pc renamed to get_pc.
22167 Add decr_pc_after_break and breakpoint_at.
22168 (get_process, get_thread_proess, get_process_thread)
22169 (strut process_info, all_processes, linux_attach_lwp)
22170 (thread_db_init): New.
22171
22172 * linux-arm-low.c (arm_get_pc, arm_set_pc,
22173 arm_breakpoint, arm_breakpoint_len, arm_breakpoint_at): New.
22174 (the_low_target): Add new members.
22175 * linux-i386-low.c (i386_store_gregset, i386_store_fpregset)
22176 (i386_store_fpxregset): Constify.
22177 (target_regsets): Add new kind identifier.
22178 (i386_get_pc): Renamed from i386_stop_pc. Simplify.
22179 (i386_set_pc): Add debugging.
22180 (i386_breakpoint_at): New function.
22181 (the_low_target): Add new members.
22182 * linux-mips-low.c (mips_get_pc, mips_set_pc)
22183 (mips_breakpoint, mips_breakpoint_len, mips_reinsert_addr)
22184 (mips_breakpoint_at): New.
22185 (the_low_target): Add new members.
22186 * linux-ppc-low.c (ppc_get_pc, ppc_set_pc)
22187 (ppc_breakpoint, ppc_breakpoint_len, ppc_breakpoint_at): New.
22188 (the_low_target): Add new members.
22189 * linux-sh-low.c (sh_get_pc, sh_set_pc)
22190 (sh_breakpoint, sh_breakpoint_len, sh_breakpoint_at): New.
22191 (the_low_target): Add new members.
22192 * linux-x86-64-low.c (target_regsets): Add new kind
22193 identifier.
22194
221952002-05-15 Daniel Jacobowitz <drow@mvista.com>
22196
22197 From Martin Pool <mbp@samba.org>:
22198 * server.c (gdbserver_usage): New function.
22199 (main): Call it.
22200
222012002-05-14 Daniel Jacobowitz <drow@mvista.com>
22202
22203 * mem-break.c (reinsert_breakpoint_by_bp): Correct typo
22204 stop_at -> stop_pc.
22205
222062002-05-04 Andrew Cagney <ac131313@redhat.com>
22207
22208 * Makefile.in: Remove obsolete code.
22209
222102002-04-24 Michal Ludvig <mludvig@suse.cz>
22211
22212 * linux-low.c (regsets_fetch_inferior_registers),
22213 (regsets_store_inferior_registers): Removed cast to int from
22214 ptrace() calls.
22215 * regcache.h: Added declaration of struct inferior_info.
22216
222172002-04-20 Daniel Jacobowitz <drow@mvista.com>
22218
22219 * inferiors.c (struct inferior_info): Add regcache_data.
22220 (add_inferior): Call create_register_cache.
22221 (clear_inferiors): Call free_register_cache.
22222 (inferior_regcache_data, set_inferior_regcache_data): New functions.
22223 * regcache.c (struct inferior_regcache_data): New.
22224 (registers): Remove.
22225 (get_regcache): New function.
22226 (create_register_cache, free_register_cache): New functions.
22227 (set_register_cache): Don't initialize the register cache here.
22228 (registers_to_string, registers_from_string, register_data): Call
22229 get_regcache.
22230 * regcache.h: Add prototypes.
22231 * server.h: Likewise.
22232
222332002-04-20 Daniel Jacobowitz <drow@mvista.com>
22234
22235 * mem-break.c: New file.
22236 * mem-break.h: New file.
22237 * Makefile.in: Add mem-break.o rule; update server.h
22238 dependencies.
22239 * inferiors.c (struct inferior_info): Add target_data
22240 member.
22241 (clear_inferiors): Free target_data member if set.
22242 (inferior_target_data, set_inferior_target_data): New functions.
22243 * linux-i386-low.c (i386_breakpoint, i386_breakpoint_len)
22244 (i386_stop_pc, i386_set_pc): New. Add to the_low_target.
22245 * linux-low.c (linux_bp_reinsert): New variable.
22246 (struct inferior_linux_data): New.
22247 (linux_create_inferior): Use set_inferior_target_data.
22248 (linux_attach): Likewise. Call add_inferior.
22249 (linux_wait_for_one_inferior): New function.
22250 (linux_wait): Call it.
22251 (linux_write_memory): Add const.
22252 (initialize_low): Call set_breakpoint_data.
22253 * linux-low.h (struct linux_target_ops): Add breakpoint
22254 handling members.
22255 * server.c (attach_inferior): Remove extra add_inferior
22256 call.
22257 * server.h: Include mem-break.h. Update inferior.c
22258 prototypes.
22259 * target.c (read_inferior_memory)
22260 (write_inferior_memory): New functions.
22261 * target.h (read_inferior_memory)
22262 (write_inferior_memory): Change macros to prototypes.
22263 (struct target_ops): Update comments. Add const to write_memory
22264 definition.
22265
222662002-04-11 Daniel Jacobowitz <drow@mvista.com>
22267
22268 * linux-low.c (usr_store_inferior_registers): Support
22269 registers which are allowed to fail to store.
22270 * linux-low.h (linux_target_ops): Likewise.
22271 * linux-ppc-low.c (ppc_regmap): Support FPSCR.
22272 (ppc_cannot_store_register): FPSCR may not be storable.
22273
222742002-04-09 Daniel Jacobowitz <drow@mvista.com>
22275
22276 * server.h: Include <string.h> if HAVE_STRING_H.
22277 * ChangeLog: Correct paths in last ChangeLog entry.
22278
222792002-04-09 Daniel Jacobowitz <drow@mvista.com>
22280
22281 * linux-low.h: Remove obsolete prototypes.
22282 (struct linux_target_ops): New.
22283 (extern the_low_target): New.
22284 * linux-low.c (num_regs, regmap): Remove declarations.
22285 (register_addr): Use the_low_target explicitly.
22286 (fetch_register): Likewise.
22287 (usr_fetch_inferior_registers): Likewise.
22288 (usr_store_inferior_registers): Likewise.
22289 * linux-arm-low.c (num_regs): Remove.
22290 (arm_num_regs): Define.
22291 (arm_regmap): Renamed from regmap, made static.
22292 (arm_cannot_fetch_register): Renamed from cannot_fetch_register,
22293 made static.
22294 (arm_cannot_store_register): Renamed from cannot_store_register,
22295 made static.
22296 (the_low_target): New.
22297 * linux-i386-low.c (num_regs): Remove.
22298 (i386_num_regs): Define.
22299 (i386_regmap): Renamed from regmap, made static.
22300 (i386_cannot_fetch_register): Renamed from cannot_fetch_register,
22301 made static.
22302 (i386_cannot_store_register): Renamed from cannot_store_register,
22303 made static.
22304 (the_low_target): New.
22305 * linux-ia64-low.c (num_regs): Remove.
22306 (ia64_num_regs): Define.
22307 (ia64_regmap): Renamed from regmap, made static.
22308 (ia64_cannot_fetch_register): Renamed from cannot_fetch_register,
22309 made static.
22310 (ia64_cannot_store_register): Renamed from cannot_store_register,
22311 made static.
22312 (the_low_target): New.
22313 * linux-m68k-low.c (num_regs): Remove.
22314 (m68k_num_regs): Define.
22315 (m68k_regmap): Renamed from regmap, made static.
22316 (m68k_cannot_fetch_register): Renamed from cannot_fetch_register,
22317 made static.
22318 (m68k_cannot_store_register): Renamed from cannot_store_register,
22319 made static.
22320 (the_low_target): New.
22321 * linux-mips-low.c (num_regs): Remove.
22322 (mips_num_regs): Define.
22323 (mips_regmap): Renamed from regmap, made static.
22324 (mips_cannot_fetch_register): Renamed from cannot_fetch_register,
22325 made static.
22326 (mips_cannot_store_register): Renamed from cannot_store_register,
22327 made static.
22328 (the_low_target): New.
22329 * linux-ppc-low.c (num_regs): Remove.
22330 (ppc_num_regs): Define.
22331 (ppc_regmap): Renamed from regmap, made static.
22332 (ppc_cannot_fetch_register): Renamed from cannot_fetch_register,
22333 made static.
22334 (ppc_cannot_store_register): Renamed from cannot_store_register,
22335 made static.
22336 (the_low_target): New.
22337 * linux-s390-low.c (num_regs): Remove.
22338 (s390_num_regs): Define.
22339 (s390_regmap): Renamed from regmap, made static.
22340 (s390_cannot_fetch_register): Renamed from cannot_fetch_register,
22341 made static.
22342 (s390_cannot_store_register): Renamed from cannot_store_register,
22343 made static.
22344 (the_low_target): New.
22345 * linux-sh-low.c (num_regs): Remove.
22346 (sh_num_regs): Define.
22347 (sh_regmap): Renamed from regmap, made static.
22348 (sh_cannot_fetch_register): Renamed from cannot_fetch_register,
22349 made static.
22350 (sh_cannot_store_register): Renamed from cannot_store_register,
22351 made static.
22352 (the_low_target): New.
22353 * linux-x86-64-low.c (x86_64_regmap): Renamed from regmap.
22354 (the_low_target): New.
22355
223562002-04-09 Daniel Jacobowitz <drow@mvista.com>
22357
22358 * Makefile.in: Add stamp-h target.
22359 * configure.in: Create stamp-h.
22360 * configure: Regenerated.
22361
223622002-04-09 Daniel Jacobowitz <drow@mvista.com>
22363
22364 * inferiors.c: New file.
22365 * target.c: New file.
22366 * target.h: New file.
22367 * Makefile.in: Add target.o and inferiors.o. Update
22368 dependencies.
22369 * linux-low.c (inferior_pid): New static variable,
22370 moved from server.c.
22371 (linux_create_inferior): Renamed from create_inferior.
22372 Call add_inferior. Return 0 on success instead of a PID.
22373 (linux_attach): Renamed from myattach.
22374 (linux_kill): Renamed from kill_inferior. Call clear_inferiors ().
22375 (linux_thread_alive): Renamed from mythread_alive.
22376 (linux_wait): Renamed from mywait. Call clear_inferiors () if the
22377 child dies.
22378 (linux_resume): Renamed from myresume. Add missing ``return 0''.
22379 (regsets_store_inferior_registers): Correct error message.
22380 Add missing ``return 0''.
22381 (linux_fetch_registers): Renamed from fetch_inferior_registers.
22382 (linux_store_registers): Renamed from store_inferior_registers.
22383 (linux_read_memory): Renamed from read_inferior_memory.
22384 (linux_write_memory): Renamed from write_inferior_memory.
22385 (linux_target_ops): New structure.
22386 (initialize_low): Call set_target_ops ().
22387 * remote-utils.c (unhexify): New function.
22388 (hexify): New function.
22389 (input_interrupt): Send signals to ``signal_pid''.
22390 * server.c (inferior_pid): Remove.
22391 (start_inferior): Update create_inferior call.
22392 (attach_inferior): Call add_inferior.
22393 (handle_query): New function.
22394 (main): Call handle_query for `q' packets.
22395 * server.h: Include "target.h". Remove obsolete prototypes.
22396 Add prototypes for "inferiors.c", "target.c", hexify, and unhexify.
22397
223982002-04-09 Daniel Jacobowitz <drow@mvista.com>
22399
22400 * Makefile.in: Add WARN_CFLAGS. Update configury
22401 dependencies.
22402 * configure.in: Check for <string.h>
22403 * configure: Regenerate.
22404 * config.in: Regenerate.
22405 * gdbreplay.c: Include needed system headers.
22406 (remote_open): Remove strchr prototype.
22407 * linux-low.h: Correct #ifdef to HAVE_LINUX_USRREGS.
22408 * regcache.c (supply_register): Change buf argument to const void *.
22409 (supply_register_by_name): Likewise.
22410 (collect_register): Change buf argument to void *.
22411 (collect_register_by_name): Likewise.
22412 * regcache.h: Add missing prototypes.
22413 * remote-utils.c: Include <arpa/inet.h> for inet_ntoa.
22414 * server.c (handle_query): New function.
22415 (attached): New static variable, moved out of main.
22416 (main): Quiet longjmp clobber warnings.
22417 * server.h: Add ATTR_NORETURN and ATTR_FORMAT. Update prototypes.
22418 * utils.c (error): Remove NORETURN.
22419 (fatal): Likewise.
This page took 3.159666 seconds and 4 git commands to generate.