]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blame - gdbserver/ChangeLog
gdbserver: small cleanup of README file
[thirdparty/binutils-gdb.git] / gdbserver / ChangeLog
CommitLineData
c00094dc
SM
12020-06-12 Simon Marchi <simon.marchi@efficios.com>
2
3 * README: Fix a few outdated or incoherent things.
4
6479bf85
HD
52020-05-27 Hannes Domani <ssbssa@yahoo.de>
6
7 * win32-low.cc (do_initial_child_stuff): Set open_process_used.
8 (win32_clear_inferiors): Use open_process_used.
9 (get_child_debug_event): Likewise.
10
bea571eb
MW
112020-05-25 Michael Weghorn <m.weghorn@posteo.de>
12
13 PR gdbserver/25893
14 * linux-low.cc (linux_process_target::create_inferior),
15 lynx-low.cc (lynx_process_target::create_inferior),
16 win32-low.cc (win32_process_target::create_inferior): Use
17 construct_inferior_arguments instead of stringify_argv
18 to get string representation which properly escapes
19 special characters.
20 * server.cc (handle_v_run): Just pass empty program arg
21 as such, since any further processing is now handled via
22 construct_inferior_arguments.
23
ace6b919
MW
242020-05-25 Michael Weghorn <m.weghorn@posteo.de>
25
26 * nto-low.cc (nto_process_target::create_inferior): Pass
27 argv to spawnp function as char **.
28
b69ca137
MW
292020-05-25 Michael Weghorn <m.weghorn@posteo.de>
30
31 * server.cc (captured_main), (handle_v_run): No longer
32 insert extra NULL element to args vector.
33
51e2cfa2
PA
342020-05-23 Pedro Alves <palves@redhat.com>
35
36 * gdb-safe-ctype.h: New.
37
8bbf0394
TBA
382020-05-16 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
39
40 * linux-ia64-low.cc (ia64_target::sw_breakpoint_from_kind):
41 Fix incorrect 'gdb_assert_no_reached' to 'gdb_assert_not_reached'.
42 (ia64_target::low_breakpoint_at): Ditto.
43
01370779
HD
442020-05-15 Hannes Domani <ssbssa@yahoo.de>
45
46 * win32-i386-low.cc (i386_supports_z_point_type): Handle
47 Z_PACKET_HW_BP z_type.
48 (i386_insert_point): Handle raw_bkpt_type type.
49 (i386_remove_point): Likewise.
50
7d186bc0
HD
512020-04-30 Hannes Domani <ssbssa@yahoo.de>
52
53 * configure.srv <x86_64-*-mingw*, x86_64-*-cygwin*> (srv_tgtobj):
54 Add arch/i386.o.
55 * win32-arm-low.cc (arm_num_regs): New function.
56 (struct win32_target_ops): Use arm_num_regs.
57 * win32-i386-low.cc (win32_get_current_dr): Adapt for WOW64
58 processes.
59 (i386_get_thread_context): Likewise.
60 (i386_prepare_to_resume): Likewise.
61 (i386_thread_added): Likewise.
62 (i386_single_step): Likewise.
63 (i386_fetch_inferior_register): Likewise.
64 (i386_store_inferior_register): Likewise.
65 (i386_arch_setup): Likewise.
66 (i386_win32_num_regs): New function.
67 (struct win32_target_ops): Use i386_win32_num_regs.
68 * win32-low.cc (win32_get_thread_context): Adapt for WOW64
69 processes.
70 (win32_require_context): Likewise.
71 (child_add_thread): Likewise.
72 (do_initial_child_stuff): Likewise.
73 (continue_one_thread): Likewise.
74 (win32_process_target::resume): Likewise.
75 (load_psapi): Likewise.
76 (win32_add_all_dlls): Likewise.
77 (maybe_adjust_pc): Likewise.
78 (win32_process_target::qxfer_siginfo): Likewise.
79 (initialize_low): Likewise.
80 * win32-low.h (struct win32_target_ops): Change num_regs to
81 callback function.
82
1eb39914
SM
832020-04-27 Simon Marchi <simon.marchi@efficios.com>
84
85 * configure.ac: Remove check for fs_base/gs_base in
86 user_regs_struct.
87 * configure: Re-generate.
88 * config.in: Re-generate.
89 * linux-x86-low.cc (x86_64_regmap, x86_fill_gregset,
90 x86_store_gregset): Adjust.
91
51ac8e22
HD
922020-04-22 Hannes Domani <ssbssa@yahoo.de>
93
94 * server.cc (handle_search_memory_1): Fix gdb_read_memory return value
95 comparison.
96
a010605f
TT
972020-04-16 Tom Tromey <tromey@adacore.com>
98
99 * win32-low.cc (windows_nat::handle_access_violation): New
100 function.
101
e2275c6e
SM
1022020-04-15 Simon Marchi <simon.marchi@polymtl.ca>
103
104 * win32-low.cc (get_child_debug_event): Fix format string warning.
105
73944e9f
TT
1062020-04-13 Tom Tromey <tom@tromey.com>
107
108 * server.h (gdb_fildes_t): Remove typedef.
109 * remote-utils.c (remote_desc, list_desc): Now int.
110 (INVALID_DESCRIPTOR): Remove.
111 (gdb_connected, remote_close)
112 (check_remote_input_interrupt_request): Update.
113 * utils.h (pfildes): Don't declare.
114 * utils.c (pfildes): Remove.
115
55d7aec8
TT
1162020-04-13 Tom Tromey <tom@tromey.com>
117
118 * server.h (handle_serial_event, handle_target_event): Update.
119 * server.c: Don't call initialize_event_loop.
120 (keep_processing_events): New global.
121 (handle_serial_event): Return void. Set keep_processing_events.
122 (handle_target_event): Return void.
123 (start_event_loop): Move from event-loop.c. Rewrite.
124 * remote-utils.c (handle_accept_event): Return void.
125 (reset_readchar): Use delete_timer.
126 (process_remaining): Return void.
127 (reschedule): Use create_timer.
128 * event-loop.h: Remove.
129 * event-loop.cc: Remove.
130 * Makefile.in (OBS): Use gdbsupport/event-loop.o, not event-loop.o.
131
e487f994
TT
1322020-04-13 Tom Tromey <tom@tromey.com>
133
134 * server.c (invoke_async_signal_handlers)
135 (check_async_event_handlers, flush_streams, gdb_select): New
136 functions.
137
8ae8e197
TT
1382020-04-13 Tom Tromey <tom@tromey.com>
139
140 * configure: Rebuild.
141 * config.in: Rebuild.
142
360ad8b3
TT
1432020-04-08 Tom Tromey <tromey@adacore.com>
144
145 PR gdb/22992
146 * win32-low.c (child_continue): Call matching_pending_stop.
147 (get_child_debug_event): Call fetch_pending_stop. Push pending
148 stop when needed.
149
523d4f80
TT
1502020-04-08 Tom Tromey <tromey@adacore.com>
151
152 * win32-low.h (win32_process_target::stopped_by_sw_breakpoint)
153 (win32_process_target::supports_stopped_by_sw_breakpoint):
154 Declare.
155 * win32-low.c (win32_supports_z_point_type): Always handle
156 Z_PACKET_SW_BP.
157 (win32_insert_point): Call insert_memory_breakpoint when needed.
158 (win32_remove_point): Call remove_memory_breakpoint when needed.
159 (win32_process_target::stopped_by_sw_breakpoint)
160 (win32_process_target::supports_stopped_by_sw_breakpoint): New
161 methods.
162 (win32_target_ops): Update.
163 (maybe_adjust_pc): New function.
164 (win32_wait): Call maybe_adjust_pc.
165
e54e5929
TT
1662020-04-08 Tom Tromey <tromey@adacore.com>
167
168 * win32-low.h (struct win32_target_ops) <decr_pc_after_break>: New
169 field.
170 * win32-i386-low.c (the_low_target): Update.
171 * win32-arm-low.c (the_low_target): Update.
172
d6225aff
TT
1732020-04-08 Tom Tromey <tromey@adacore.com>
174
175 * win32-low.h (win32_process_target::read_pc)
176 (win32_process_target::write_pc): Declare.
177 * win32-low.c (win32_process_target::read_pc)
178 (win32_process_target::write_pc): New methods.
179 * win32-i386-low.c (i386_win32_get_pc, i386_win32_set_pc): New
180 functions.
181 (the_low_target): Update.
182 * win32-arm-low.c (arm_win32_get_pc, arm_win32_set_pc): New
183 functions.
184 (the_low_target): Update.
185
2c1d95e8
TT
1862020-04-08 Tom Tromey <tromey@adacore.com>
187
188 * win32-low.c (win32_kill, get_child_debug_event): Use
189 wait_for_debug_event.
190
e758e19c
TT
1912020-04-08 Tom Tromey <tromey@adacore.com>
192
193 * win32-low.c (child_continue): Call continue_last_debug_event.
194
8d30e395
TT
1952020-04-08 Tom Tromey <tromey@adacore.com>
196
197 * win32-low.c (handle_exception): Remove.
198 (windows_nat::handle_ms_vc_exception): New function.
199 (get_child_debug_event): Add "continue_status" parameter.
200 Update.
201 (win32_wait): Update.
202
a816ba18
TT
2032020-04-08 Tom Tromey <tromey@adacore.com>
204
205 * win32-low.c (windows_nat::handle_load_dll): Rename from
206 handle_load_dll. No longer static.
207 (windows_nat::handle_unload_dll): Rename from handle_unload_dll.
208 No longer static.
209
d41b524f
TT
2102020-04-08 Tom Tromey <tromey@adacore.com>
211
212 * win32-low.c (handle_output_debug_string): Add parameter. Change
213 return type.
214 (win32_kill, get_child_debug_event): Update.
215
3c76026d
TT
2162020-04-08 Tom Tromey <tromey@adacore.com>
217
218 * win32-low.c (current_process_handle, current_process_id)
219 (main_thread_id, last_sig, current_event, siginfo_er): Move to
220 nat/windows-nat.c.
221
9d8679cc
TT
2222020-04-08 Tom Tromey <tromey@adacore.com>
223
224 * win32-low.c (get_image_name): Remove.
225 (handle_load_dll): Update.
226
28688adf
TT
2272020-04-08 Tom Tromey <tromey@adacore.com>
228
229 * win32-low.c (windows_nat::thread_rec): Rename from thread_rec.
230 No longer static. Change parameters.
231 (child_add_thread, child_fetch_inferior_registers)
232 (child_store_inferior_registers, win32_resume)
233 (win32_get_tib_address): Update.
234
4834dad0
TT
2352020-04-08 Tom Tromey <tromey@adacore.com>
236
237 * win32-low.h (struct win32_target_ops): Use qualified names where
238 needed.
239 * win32-i386-low.c: Add "using namespace".
240 * win32-low.c: Add "using namespace".
241 * win32-arm-low.c: Add "using namespace".
242
65bafd5b
TT
2432020-04-08 Tom Tromey <tromey@adacore.com>
244
245 * win32-low.c (delete_thread_info): Don't call CloseHandle.
246
98a03287
TT
2472020-04-08 Tom Tromey <tromey@adacore.com>
248
249 * win32-low.c (win32_require_context, suspend_one_thread): Use
250 windows_thread_info::suspend.
251 (continue_one_thread): Use windows_thread_info::resume.
252 * configure.srv (srv_tgtobj): Add windows-nat.o when needed.
253
62fe396b
TT
2542020-04-08 Tom Tromey <tromey@adacore.com>
255
256 * win32-i386-low.c (update_debug_registers)
257 (i386_prepare_to_resume, i386_thread_added): Update.
258
e9534bd2
TT
2592020-04-08 Tom Tromey <tromey@adacore.com>
260
261 * win32-low.c (child_add_thread): Use new.
262 (delete_thread_info): Use delete.
263
ae1f8880
TT
2642020-04-08 Tom Tromey <tromey@adacore.com>
265
266 * win32-low.h (struct windows_thread_info): Remove.
267
e56f8ccb
TT
2682020-04-08 Tom Tromey <tromey@adacore.com>
269
270 * win32-low.h (struct windows_thread_info): Rename from
271 win32_thread_info. Remove typedef.
272 (struct win32_target_ops, win32_require_context): Update.
273 * win32-low.c (win32_get_thread_context)
274 (win32_set_thread_context, win32_prepare_to_resume)
275 (win32_require_context, thread_rec, child_add_thread)
276 (delete_thread_info, continue_one_thread)
277 (child_fetch_inferior_registers, child_store_inferior_registers)
278 (win32_resume, suspend_one_thread, win32_get_tib_address):
279 Update.
280 * win32-i386-low.c (update_debug_registers)
281 (win32_get_current_dr, i386_get_thread_context)
282 (i386_prepare_to_resume, i386_thread_added, i386_single_step)
283 (i386_fetch_inferior_register, i386_store_inferior_register):
284 Update.
285 * win32-arm-low.c (arm_get_thread_context)
286 (arm_fetch_inferior_register, arm_store_inferior_register):
287 Update.
288
0dd7b52e
TBA
2892020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
290
291 * linux-low.h (struct linux_target_ops): Remove.
292 (the_low_target): Remove.
293 * linux-x86-low.cc (the_low_target): Remove.
294 * linux-aarch64-low.cc (the_low_target): Ditto.
295 * linux-arm-low.cc (the_low_target): Ditto.
296 * linux-bfin-low.cc (the_low_target): Ditto.
297 * linux-cris-low.cc (the_low_target): Ditto.
298 * linux-crisv32-low.cc (the_low_target): Ditto.
299 * linux-ia64-low.cc (the_low_target): Ditto.
300 * linux-m32r-low.cc (the_low_target): Ditto.
301 * linux-m68k-low.cc (the_low_target): Ditto.
302 * linux-mips-low.cc (the_low_target): Ditto.
303 * linux-nios2-low.cc (the_low_target): Ditto.
304 * linux-ppc-low.cc (the_low_target): Ditto.
305 * linux-riscv-low.cc (the_low_target): Ditto.
306 * linux-s390-low.cc (the_low_target): Ditto.
307 * linux-sh-low.cc (the_low_target): Ditto.
308 * linux-sparc-low.cc (the_low_target): Ditto.
309 * linux-tic6x-low.cc (the_low_target): Ditto.
310 * linux-tile-low.cc (the_low_target): Ditto.
311 * linux-xtensa-low.cc (the_low_target): Ditto.
312
fc5ecdb6
TBA
3132020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
314
315 Remove the 'get_ipa_tdesc_idx' linux target op and let a concrete
316 linux target define the op by overriding the declaration in
317 process_stratum_target.
318
319 * linux-low.h (struct linux_target_ops): Remove the op.
320 (class linux_process_target) <get_ipa_tdesc_idx>: Remove.
321 * linux-low.cc (linux_process_target::get_ipa_tdesc_idx): Remove.
322 * linux-x86-low.cc (class x86_target) <get_ipa_tdesc_idx>: Declare.
323 (x86_get_ipa_tdesc_idx): Turn into...
324 (x86_target::get_ipa_tdesc_idx): ...this.
325 (the_low_target): Remove the op field.
326 * linux-ppc-low.cc (class ppc_target) <get_ipa_tdesc_idx>: Declare.
327 (ppc_get_ipa_tdesc_idx): Turn into...
328 (ppc_target::get_ipa_tdesc_idx): ...this.
329 (the_low_target): Remove the op field.
330 * linux-s390-low.cc (class s390_target) <get_ipa_tdesc_idx>: Declare.
331 (s390_get_ipa_tdesc_idx): Turn into...
332 (s390_target::get_ipa_tdesc_idx): ...this.
333 (the_low_target): Remove the op field.
334
9eedd27d
TBA
3352020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
336
337 Turn the 'get_syscall_trapinfo' linux target op into a method
338 of process_stratum_target.
339
340 * linux-low.h (struct linux_target_ops): Remove the op.
341 (class linux_process_target) <get_syscall_trapinfo>
342 <gdb_catch_this_syscall>
343 <low_supports_catch_syscall>
344 <low_get_syscall_trapinfo>: Declare.
345 * linux-low.cc (get_syscall_trapinfo): Turn into...
346 (linux_process_target::get_syscall_trapinfo): ...this.
347 (linux_process_target::low_get_syscall_trapinfo): Define.
348 (gdb_catch_this_syscall_p): Turn into...
349 (linux_process_target::gdb_catch_this_syscall): ...this.
350 (linux_process_target::low_supports_catch_syscall): Define.
351
352 Update the callers below.
353
354 (linux_process_target::wait_1)
355 (linux_process_target::supports_catch_syscall)
356
357 * linux-x86-low.cc (class x86_target) <low_supports_catch_syscall>
358 <low_get_syscall_trapinfo>: Declare.
359 (x86_target::low_supports_catch_syscall): Define.
360 (x86_get_syscall_trapinfo): Turn into...
361 (x86_target::low_get_syscall_trapinfo): ...this.
362 (the_low_target): Remove the op field.
363 * linux-aarch64-low.cc (class aarch64_target)
364 <low_supports_catch_syscall>
365 <low_get_syscall_trapinfo>: Declare.
366 (aarch64_target::low_supports_catch_syscall): Define.
367 (aarch64_get_syscall_trapinfo): Turn into...
368 (aarch64_target::low_get_syscall_trapinfo): ...this.
369 (the_low_target): Remove the op field.
370 * linux-arm-low.cc (class arm_target) <low_supports_catch_syscall>
371 <low_get_syscall_trapinfo>: Declare.
372 (arm_target::low_supports_catch_syscall): Define.
373 (arm_get_syscall_trapinfo): Turn into...
374 (arm_target::low_get_syscall_trapinfo): ...this.
375 (the_low_target): Remove the op field.
376 * linux-ppc-low.cc (the_low_target): Remove the op field.
377 * linux-s390-low.cc (the_low_target): Remove the op field.
378
b31cdfa6
TBA
3792020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
380
381 Remove the 'supports_hardware_single_step' linux target op and
382 override the process_stratum_target's op definition in
383 linux_process_target to return true.
384
385 * linux-low.h (struct linux_target_ops): Remove the op.
386 (class linux_process_target) <finish_step_over>
387 <maybe_hw_step>: Declare.
388 * linux-low.cc (can_hardware_single_step): Remove.
389 (maybe_hw_step): Turn into...
390 (linux_process_target::maybe_hw_step): ...this.
391 (finish_step_over): Turn into...
392 (linux_process_target::finish_step_over): ...this.
393 (linux_process_target::supports_hardware_single_step): Update
394 to return true.
395
396 Update the callers below.
397
398 (linux_process_target::single_step)
399 (linux_process_target::resume_one_lwp_throw)
400
401 * linux-arm-low.cc (class arm_target)
402 <supports_hardware_single_step>: Declare.
403 (arm_supports_hardware_single_step): Turn into...
404 (arm_target::supports_hardware_single_step): ...this.
405 (the_low_target): Remove the op field.
406 * linux-x86-low.cc (x86_supports_hardware_single_step): Remove.
407 (the_low_target): Remove the op field.
408 * linux-aarch64-low.cc (aarch64_supports_hardware_single_step):
409 Remove.
410 (the_low_target): Remove the op field.
411 * linux-bfin-low.cc (bfin_supports_hardware_single_step): Remove.
412 (the_low_target): Remove the op field.
413 * linux-crisv32-low.cc (cris_supports_hardware_single_step): Remove.
414 (the_low_target): Remove the op field.
415 * linux-m32r-low.cc (m32r_supports_hardware_single_step): Remove.
416 (the_low_target): Remove the op field.
417 * linux-m68k-low.cc (m68k_supports_hardware_single_step): Remove.
418 (the_low_target): Remove the op field.
419 * linux-ppc-low.cc (ppc_supports_hardware_single_step): Remove.
420 (the_low_target): Remove the op field.
421 * linux-s390-low.cc (s390_supports_hardware_single_step): Remove.
422 (the_low_target): Remove the op field.
423 * linux-sh-low.cc (sh_supports_hardware_single_step): Remove.
424 (the_low_target): Remove the op field.
425 * linux-tic6x-low.cc (tic6x_supports_hardware_single_step): Remove.
426 (the_low_target): Remove the op field.
427 * linux-tile-low.cc (tile_supports_hardware_single_step): Remove.
428 (the_low_target): Remove the op field.
429 * linux-xtensa-low.cc (xtensa_supports_hardware_single_step):
430 Remove.
431 (the_low_target): Remove the op field.
432
9cfd8715
TBA
4332020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
434
435 Turn the 'supports_range_stepping' linux target op into a method
436 of linux_process_target.
437
438 * linux-low.h (struct linux_target_ops): Remove the op.
439 (class linux_process_target) <low_supports_range_stepping>: Declare.
440 * linux-low.cc (linux_process_target::low_supports_range_stepping):
441 Define.
442 (linux_process_target::supports_range_stepping): Update the call
443 site.
444 * linux-x86-low.cc (class x86_target)
445 <low_supports_range_stepping>: Declare.
446 (x86_supports_range_stepping): Turn into...
447 (x86_target::low_supports_range_stepping): ...this.
448 (the_low_target): Remove the op field.
449 * linux-aarch64-low.cc (class aarch64_target)
450 <low_supports_range_stepping>: Declare.
451 (aarch64_supports_range_stepping): Turn into...
452 (aarch64_target::low_supports_range_stepping): ...this.
453 (the_low_target): Remove the op field.
454 * linux-arm-low.cc (the_low_target): Remove the op field.
455 * linux-bfin-low.cc (the_low_target): Ditto.
456 * linux-crisv32-low.cc (the_low_target): Ditto.
457 * linux-m32r-low.cc (the_low_target): Ditto.
458 * linux-m68k-low.cc (the_low_target): Ditto.
459 * linux-ppc-low.cc (the_low_target): Ditto.
460 * linux-s390-low.cc (the_low_target): Ditto.
461 * linux-sh-low.cc (the_low_target): Ditto.
462 * linux-tic6x-low.cc (the_low_target): Ditto.
463 * linux-tile-low.cc (the_low_target): Ditto.
464 * linux-xtensa-low.cc (the_low_target): Ditto.
465
ab64c999
TBA
4662020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
467
468 Remove the 'emit_ops' linux target ops and let the concrete
469 linux target define the op by overriding the declaration of
470 process_stratum_target.
471
472 * linux-low.h (struct linux_target_ops): Remove the op.
473 (class linux_process_target) <emit_ops>: Remove.
474 * linux-low.cc (linux_process_target::emit_ops): Remove.
475 * linux-x86-low.cc (class x86_target) <emit_ops>: Declare.
476 (x86_emit_ops): Turn into...
477 (x86_target::emit_ops): ...this.
478 (the_low_target): Remove the op field.
479 * linux-aarch64-low.cc (class aarch64_target) <emit_ops>: Declare.
480 (aarch64_emit_ops): Turn into...
481 (aarch64_target::emit_ops): ...this.
482 (the_low_target): Remove the op field.
483 * linux-ppc-low.cc (class ppc_target) <emit_ops>: Declare.
484 (ppc_emit_ops): Turn into...
485 (ppc_target::emit_ops): ...this.
486 (the_low_target): Remove the op field.
487 * linux-s390-low.cc (class s390_target) <emit_ops>: Declare.
488 (s390_emit_ops): Turn into...
489 (s390_target::emit_ops): ...this.
490 (the_low_target): Remove the op field.
491 * linux-arm-low.cc (the_low_target): Remove the op field.
492 * linux-bfin-low.cc (the_low_target): Ditto.
493 * linux-crisv32-low.cc (the_low_target): Ditto.
494 * linux-m32r-low.cc (the_low_target): Ditto.
495 * linux-m68k-low.cc (the_low_target): Ditto.
496 * linux-sh-low.cc (the_low_target): Ditto.
497 * linux-tic6x-low.cc (the_low_target): Ditto.
498 * linux-tile-low.cc (the_low_target): Ditto.
499 * linux-xtensa-low.cc (the_low_target): Ditto.
500
809a0c35
TBA
5012020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
502
503 Remove the 'install_fast_tracepoint_jump_pad' and
504 'get_min_fast_tracepoint_insn_len' linux target ops to let the
505 concrete linux target define the ops by overriding the declarations
506 of process_stratum_target.
507
508 * linux-low.h (struct linux_target_ops): Remove the ops.
509 (class linux_process_target) <supports_fast_tracepoints>
510 <install_fast_tracepoint_jump_pad>
511 <get_min_fast_tracepoint_insn_len>: Remove.
512 * linux-low.cc (linux_process_target::supports_fast_tracepoints)
513 (linux_process_target::install_fast_tracepoint_jump_pad)
514 (linux_process_target::get_min_fast_tracepoint_insn_len): Remove.
515 * linux-x86-low.cc (class x86_target) <supports_fast_tracepoints>
516 <install_fast_tracepoint_jump_pad>
517 <get_min_fast_tracepoint_insn_len>: Declare.
518 (x86_target::supports_fast_tracepoints): Define.
519 (x86_install_fast_tracepoint_jump_pad): Turn into...
520 (x86_target::install_fast_tracepoint_jump_pad): ...this.
521 (x86_get_min_fast_tracepoint_insn_len): Turn into...
522 (x86_target::get_min_fast_tracepoint_insn_len): ...this.
523 (the_low_target): Remove the op fields.
524 * linux-aarch64-low.cc (class aarch64_target)
525 <supports_fast_tracepoints>
526 <install_fast_tracepoint_jump_pad>
527 <get_min_fast_tracepoint_insn_len>: Declare.
528 (aarch64_target::supports_fast_tracepoints): Define.
529 (aarch64_install_fast_tracepoint_jump_pad): Turn into...
530 (aarch64_target::install_fast_tracepoint_jump_pad): ...this.
531 (aarch64_get_min_fast_tracepoint_insn_len): Turn into...
532 (aarch64_target::get_min_fast_tracepoint_insn_len): ...this.
533 (the_low_target): Remove the op fields.
534 * linux-ppc-low.cc (class ppc_target) <supports_fast_tracepoints>
535 <install_fast_tracepoint_jump_pad>
536 <get_min_fast_tracepoint_insn_len>: Declare.
537 (ppc_target::supports_fast_tracepoints): Define.
538 (ppc_install_fast_tracepoint_jump_pad): Turn into...
539 (ppc_target::install_fast_tracepoint_jump_pad): ...this.
540 (ppc_get_min_fast_tracepoint_insn_len): Turn into...
541 (ppc_target::get_min_fast_tracepoint_insn_len): ...this.
542 (the_low_target): Remove the op fields.
543 * linux-s390-low.cc (class s390_target) <supports_fast_tracepoints>
544 <install_fast_tracepoint_jump_pad>
545 <get_min_fast_tracepoint_insn_len>: Declare.
546 (s390_target::supports_fast_tracepoints): Define.
547 (s390_install_fast_tracepoint_jump_pad): Turn into...
548 (s390_target::install_fast_tracepoint_jump_pad): ...this.
549 (s390_get_min_fast_tracepoint_insn_len): Turn into...
550 (s390_target::get_min_fast_tracepoint_insn_len): ...this.
551 (the_low_target): Remove the op fields.
552 * linux-arm-low.cc (the_low_target): Remove the op fields.
553 * linux-bfin-low.cc (the_low_target): Ditto.
554 * linux-crisv32-low.cc (the_low_target): Ditto.
555 * linux-m32r-low.cc (the_low_target): Ditto.
556 * linux-m68k-low.cc (the_low_target): Ditto.
557 * linux-sh-low.cc (the_low_target): Ditto.
558 * linux-tic6x-low.cc (the_low_target): Ditto.
559 * linux-tile-low.cc (the_low_target): Ditto.
560 * linux-xtensa-low.cc (the_low_target): Ditto.
561
13e567af
TBA
5622020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
563
564 Turn the 'get_thread_area' linux target op into a method of
565 process_stratum_target.
566
567 * linux-low.h (struct linux_target_ops): Remove the op.
568 (class linux_process_target) <stuck_in_jump_pad>
569 <linux_fast_tracepoint_collecting>
570 <low_get_thread_area>: Declare.
571 * linux-low.cc (supports_fast_tracepoints): Remove.
572 (linux_fast_tracepoint_collecting): Turn into...
573 (linux_process_target::linux_fast_tracepoint_collecting): ...this.
574 (linux_process_target::low_get_thread_area): Define.
575 (stuck_in_jump_pad_callback): Turn into...
576 (linux_process_target::stuck_in_jump_pad): ...this.
577
578 Update the caller below.
579
580 (linux_process_target::stabilize_threads)
581
582 * linux-x86-low.cc (class x86_target) <low_get_thread_area>:
583 Declare.
584 (x86_get_thread_area): Turn into...
585 (x86_target::low_get_thread_area): ...this.
586 (the_low_target): Remove the op field.
587 * linux-aarch64-low.cc (class aarch64_target) <low_get_thread_area>:
588 Declare.
589 (aarch64_get_thread_area): Turn into...
590 (aarch64_target::low_get_thread_area): ...this.
591 (the_low_target): Remove the op field.
592 * linux-ppc-low.cc (class ppc_target) <low_get_thread_area>:
593 Declare.
594 (ppc_get_thread_area): Turn into...
595 (ppc_target::low_get_thread_area): ...this.
596 (the_low_target): Remove the op field.
597 * linux-s390-low.cc (class s390_target) <low_get_thread_area>:
598 Declare.
599 (s390_get_thread_area): Turn into...
600 (s390_target::low_get_thread_area): ...this.
601 (the_low_target): Remove the op field.
602 * linux-arm-low.cc (the_low_target): Remove the op field.
603 * linux-bfin-low.cc (the_low_target): Ditto.
604 * linux-crisv32-low.cc (the_low_target): Ditto.
605 * linux-m32r-low.cc (the_low_target): Ditto.
606 * linux-m68k-low.cc (the_low_target): Ditto.
607 * linux-sh-low.cc (the_low_target): Ditto.
608 * linux-tic6x-low.cc (the_low_target): Ditto.
609 * linux-tile-low.cc (the_low_target): Ditto.
610 * linux-xtensa-low.cc (the_low_target): Ditto.
611
47f70aa7
TBA
6122020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
613
614 Remote the 'supports_tracepoints' linux target op and let the
615 concrete linux target define it by overriding the op declared in
616 process_stratum_target.
617
618 * linux-low.h (struct linux_target_ops): Remove the op.
619 (class linux_process_target) <supports_tracepoints>: Remove.
620 * linux-low.cc (linux_process_target::supports_tracepoints): Remove.
621 * linux-x86-low.cc (class x86_target) <supports_tracepoints>:
622 Declare.
623 (x86_supports_tracepoints): Turn into...
624 (x86_target::supports_tracepoints): ...this.
625 (the_low_target): Remove the op field.
626 * linux-aarch64-low.cc (class aarch64_target)
627 <supports_tracepoints>: Declare.
628 (aarch64_supports_tracepoints): Turn into...
629 (aarch64_target::supports_tracepoints): ...this.
630 (the_low_target): Remove the op field.
631 * linux-ppc-low.cc (class ppc_target) <supports_tracepoints>:
632 Declare.
633 (ppc_supports_tracepoints): Turn into...
634 (ppc_target::supports_tracepoints): ...this.
635 (the_low_target): Remove the op field.
636 * linux-s390-low.cc (class s390_target) <supports_tracepoints>:
637 Declare.
638 (s390_supports_tracepoints): Turn into...
639 (s390_target::supports_tracepoints): ...this.
640 (the_low_target): Remove the op field.
641 * linux-arm-low.cc (the_low_target): Remove the op field.
642 * linux-bfin-low.cc (the_low_target): Ditto.
643 * linux-crisv32-low.cc (the_low_target): Ditto.
644 * linux-m32r-low.cc (the_low_target): Ditto.
645 * linux-m68k-low.cc (the_low_target): Ditto.
646 * linux-sh-low.cc (the_low_target): Ditto.
647 * linux-tic6x-low.cc (the_low_target): Ditto.
648 * linux-tile-low.cc (the_low_target): Ditto.
649 * linux-xtensa-low.cc (the_low_target): Ditto.
650
a5b5da92
TBA
6512020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
652
653 Remove the 'process_qsupported' linux target op and let a concrete
654 linux target define the op by overriding the op declaration in
655 process_stratum_target.
656
657 * linux-low.h (struct linux_target_ops): Remove the op.
658 (class linux_process_target) <process_qsupported>: Remove.
659 * linux-low.cc (linux_process_target::process_qsupported): Remove.
660 * linux-x86-low.cc (class x86_target) <process_qsupported>: Declare.
661 (x86_linux_process_qsupported): Turn into...
662 (x86_target::process_qsupported): ...this.
663 (the_low_target): Remove the op field.
664 * linux-aarch64-low.cc (the_low_target): Remove the op
665 field.
666 * linux-arm-low.cc (the_low_target): Ditto.
667 * linux-bfin-low.cc (the_low_target): Ditto.
668 * linux-crisv32-low.cc (the_low_target): Ditto.
669 * linux-m32r-low.cc (the_low_target): Ditto.
670 * linux-m68k-low.cc (the_low_target): Ditto.
671 * linux-ppc-low.cc (the_low_target): Ditto.
672 * linux-s390-low.cc (the_low_target): Ditto.
673 * linux-sh-low.cc (the_low_target): Ditto.
674 * linux-tic6x-low.cc (the_low_target): Ditto.
675 * linux-tile-low.cc (the_low_target): Ditto.
676 * linux-xtensa-low.cc (the_low_target): Ditto.
677
d7599cc0
TBA
6782020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
679
680 Turn the 'prepare_to_resume' linux target op into a method of
681 linux_process_target.
682
683 * linux-low.h (struct linux_target_ops): Remove the op.
684 (class linux_process_target) <low_prepare_to_resume>: Declare.
685 * linux-low.cc (linux_process_target::low_prepare_to_resume):
686 Define.
687
688 Update the callers below:
689
690 (linux_process_target::resume_one_lwp_throw)
691 (linux_process_target::low_prepare_to_resume)
692
693 * linux-x86-low.cc (class x86_target) <low_prepare_to_resume>:
694 Declare.
695 (x86_target::low_prepare_to_resume): Define.
696 (the_low_target): Remove the op field.
697 * linux-aarch64-low.cc (class aarch64_target)
698 <low_prepare_to_resume>: Declare.
699 (aarch64_target::low_prepare_to_resume): Define.
700 (the_low_target): Remove the op field.
701 * linux-arm-low.cc (class arm_target) <low_prepare_to_resume>:
702 Declare.
703 (arm_prepare_to_resume): Turn into...
704 (arm_target::low_prepare_to_resume): ...this.
705 (the_low_target): Remove the op field.
706 * linux-mips-low.cc (class mips_target) <low_prepare_to_resume>:
707 Declare.
708 (mips_linux_prepare_to_resume): Turn into...
709 (mips_target::low_prepare_to_resume): ...this.
710 (the_low_target): Remove the op field.
711 * linux-bfin-low.cc (the_low_target): Remove the op field.
712 * linux-crisv32-low.cc (the_low_target): Ditto.
713 * linux-m32r-low.cc (the_low_target): Ditto.
714 * linux-m68k-low.cc (the_low_target): Ditto.
715 * linux-ppc-low.cc (the_low_target): Ditto.
716 * linux-s390-low.cc (the_low_target): Ditto.
717 * linux-sh-low.cc (the_low_target): Ditto.
718 * linux-tic6x-low.cc (the_low_target): Ditto.
719 * linux-tile-low.cc (the_low_target): Ditto.
720 * linux-xtensa-low.cc (the_low_target): Ditto.
721
fd000fb3
TBA
7222020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
723
724 Turn the 'new_process', 'delete_process', 'new_thread',
725 'delete_thread', and 'new_fork' linux target ops into methods
726 of linux_process_target.
727
728 * linux-low.h (struct linux_target_ops): Remove the ops.
729 (class linux_process_target) <add_linux_process>
730 <add_lwp>
731 <delete_lwp>
732 <attach_lwp>
733 <detach_one_lwp>
734 <check_zombie_leaders>
735 <filter_exit_event>
736 <low_new_process>
737 <low_delete_process>
738 <low_new_thread>
739 <low_delete_thread>
740 <low_new_fork>: Declare.
741 * linux-low.cc (delete_lwp): Turn into...
742 (linux_process_target::delete_lwp): ...this.
743 (linux_process_target::low_delete_thread): Define.
744 (linux_add_process): Turn into...
745 (linux_process_target::add_linux_process): ...this.
746 (linux_process_target::low_new_process): Define.
747 (linux_process_target::low_delete_process): Define.
748 (linux_process_target::low_new_fork): Define.
749 (add_lwp): Turn into...
750 (linux_process_target::add_lwp): ...this.
751 (linux_process_target::low_new_thread): Define.
752 (linux_attach_lwp): Turn into...
753 (linux_process_target::attach_lwp): ...this.
754 (linux_detach_one_lwp): Turn into...
755 (linux_process_target::detach_one_lwp): ...this.
756 (linux_detach_lwp_callback): Remove and inline...
757 (linux_process_target::detach): ...here.
758 (check_zombie_leaders): Turn into...
759 (linux_process_target::check_zombie_leaders): ...this.
760 (filter_exit_event): Turn into...
761 (linux_process_target::filter_exit_event): ...this.
762
763 Update the callers below.
764
765 (linux_process_target::handle_extended_wait)
766 (linux_process_target::create_inferior)
767 (attach_proc_task_lwp_callback)
768 (linux_process_target::attach)
769 (linux_process_target::detach)
770 (linux_process_target::mourn)
771 * thread-db.cc (attach_thread)
772
773 * linux-x86-low.cc (class x86_target) <low_new_process>
774 <low_delete_process>
775 <low_new_thread>
776 <low_delete_thread>
777 <low_new_fork>: Declare.
778 (x86_linux_new_process): Turn into...
779 (x86_target::low_new_process): ...this.
780 (x86_linux_delete_process): Turn into...
781 (x86_target::low_delete_process): ...this.
782 (x86_target::low_new_thread): Define.
783 (x86_target::low_delete_thread): Define.
784 (x86_linux_new_fork): Turn into...
785 (x86_target::low_new_fork): ...this.
786 (the_low_target): Remove the op fields.
787 * linux-aarch64-low.cc (class aarch64_target) <low_new_process>
788 <low_delete_process>
789 <low_new_thread>
790 <low_delete_thread>
791 <low_new_fork>: Declare.
792 (aarch64_linux_new_process): Turn into...
793 (aarch64_target::low_new_process): ...this.
794 (aarch64_linux_delete_process): Turn into...
795 (aarch64_target::low_delete_process): ...this.
796 (aarch64_target::low_new_thread): Define.
797 (aarch64_target::low_delete_thread): Define.
798 (aarch64_linux_new_fork): Turn into...
799 (aarch64_target::low_new_fork): ...this.
800 (the_low_target): Remove the op fields.
801 * linux-arm-low.cc (class arm_target) <low_new_process>
802 <low_delete_process>
803 <low_new_thread>
804 <low_delete_thread>
805 <low_new_fork>: Declare.
806 (arm_new_process): Turn into...
807 (arm_target::low_new_process): ...this.
808 (arm_delete_process): Turn into...
809 (arm_target::low_delete_process): ...this.
810 (arm_new_thread): Turn into...
811 (arm_target::low_new_thread): ...this.
812 (arm_delete_thread): Turn into...
813 (arm_target::low_delete_thread): ...this.
814 (arm_new_fork): Turn into...
815 (arm_target::low_new_fork): ...this.
816 (the_low_target): Remove the op fields.
817 * linux-mips-low.cc (class mips_target) <low_new_process>
818 <low_delete_process>
819 <low_new_thread>
820 <low_delete_thread>
821 <low_new_fork>: Declare.
822 (mips_linux_new_process): Turn into...
823 (mips_target::low_new_process): ...this.
824 (mips_linux_delete_process): Turn into...
825 (mips_target::low_delete_process): ...this.
826 (mips_linux_new_thread): Turn into...
827 (mips_target::low_new_thread): ...this.
828 (mips_linux_delete_thread): Turn into...
829 (mips_target::low_delete_thread): ...this.
830 (mips_linux_new_fork): Turn into...
831 (mips_target::low_new_fork): ...this.
832 (the_low_target): Remove the op fields.
833 * linux-bfin-low.cc (the_low_target): Remove the op fields.
834 * linux-crisv32-low.cc (the_low_target): Ditto.
835 * linux-m32r-low.cc (the_low_target): Ditto.
836 * linux-m68k-low.cc (the_low_target): Ditto.
837 * linux-ppc-low.cc (the_low_target): Ditto.
838 * linux-s390-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
cb63de7c
TBA
8442020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
845
846 Turn the 'siginfo_fixup' linux target op into a method of
847 linux_process_target.
848
849 * linux-low.h (struct linux_target_ops): Remove the op.
850 (class linux_process_target) <siginfo_fixup>
851 <low_siginfo_fixup>: Declare.
852 * linux-low.cc (siginfo_fixup): Turn into...
853 (linux_process_target::siginfo_fixup): ...this.
854 (linux_process_target::low_siginfo_fixup): Define.
855 * linux-x86-low.cc (class x86_target) <low_siginfo_fixup>: Declare.
856 (x86_siginfo_fixup): Turn into...
857 (x86_target::low_siginfo_fixup): ...this.
858 (the_low_target): Remove the op field.
859 * linux-aarch64-low.cc (class aarch64_target):
860 <low_siginfo_fixup>: Declare.
861 (aarch64_linux_siginfo_fixup): Turn into...
862 (aarch64_target::low_siginfo_fixup): ...this.
863 (the_low_target): Remove the op field.
864 * linux-arm-low.cc (the_low_target): Remove the op field.
865 * linux-bfin-low.cc (the_low_target): Ditto.
866 * linux-crisv32-low.cc (the_low_target): Ditto.
867 * linux-m32r-low.cc (the_low_target): Ditto.
868 * linux-m68k-low.cc (the_low_target): Ditto.
869 * linux-mips-low.cc (the_low_target): Ditto.
870 * linux-ppc-low.cc (the_low_target): Ditto.
871 * linux-s390-low.cc (the_low_target): Ditto.
872 * linux-sh-low.cc (the_low_target): Ditto.
873 * linux-tic6x-low.cc (the_low_target): Ditto.
874 * linux-tile-low.cc (the_low_target): Ditto.
875 * linux-xtensa-low.cc (the_low_target): Ditto.
876
b35db733
TBA
8772020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
878
879 Turn the 'collect_ptrace_register' and 'supply_ptrace_register'
880 linux target ops into methods of linux_process_target.
881
882 * linux-low.h (struct linux_target_ops): Remove the ops.
883 (class linux_process_target) <low_collect_ptrace_register>
884 <low_store_ptrace_register>: Declare.
885 * linux-low.cc (linux_process_target::low_collect_ptrace_register)
886 (linux_process_target::low_supply_ptrace_register): Define.
887
888 Update the callers below.
889
890 (linux_process_target::fetch_register)
891 (linux_process_target::store_register)
892
893 * linux-x86-low.cc (the_low_target): Remove the op fields.
894 * linux-aarch64-low.cc (the_low_target): Ditto.
895 * linux-arm-low.cc (the_low_target): Ditto.
896 * linux-bfin-low.cc (the_low_target): Ditto.
897 * linux-crisv32-low.cc (the_low_target): Ditto.
898 * linux-m32r-low.cc (the_low_target): Ditto.
899 * linux-m68k-low.cc (the_low_target): Ditto.
900 * linux-sh-low.cc (the_low_target): Ditto.
901 * linux-sparc-low.cc (the_low_target): Ditto.
902 * linux-tic6x-low.cc (the_low_target): Ditto.
903 * linux-tile-low.cc (the_low_target): Ditto.
904 * linux-xtensa-low.cc (the_low_target): Ditto.
905 * linux-mips-low.cc (class mips_target)
906 <low_collect_ptrace_register>
907 <low_supply_ptrace_register>: Declare.
908 (mips_collect_ptrace_register): Turn into ...
909 (mips_target::low_collect_ptrace_register): ...this.
910 (mips_supply_ptrace_register): Turn into...
911 (mips_target::low_supply_ptrace_register): ...this.
912 (the_low_target): Remove the op fields.
913 * linux-ppc-low.cc (class ppc_target)
914 <low_collect_ptrace_register>
915 <low_supply_ptrace_register>: Declare.
916 (ppc_collect_ptrace_register): Turn into ...
917 (ppc_target::low_collect_ptrace_register): ...this.
918 (ppc_supply_ptrace_register): Turn into ...
919 (ppc_target::low_supply_ptrace_register): ...this.
920 (ppc_fill_gregset): Update for the calls to
921 low_collect_ptrace_register.
922 (the_low_target): Remove the op fields.
923 * linux-s390-low.cc (class s390_target)
924 <low_collect_ptrace_register>
925 <low_supply_ptrace_register>: Declare.
926 (s390_collect_ptrace_register): Turn into ...
927 (s390_target::low_collect_ptrace_register): ...this.
928 (s390_supply_ptrace_register): Turn into ...
929 (s390_target::low_supply_ptrace_register): ...this.
930 (s390_fill_gregset): Update for the calls to
931 low_collect_ptrace_register.
932 (the_low_target): Remove the op fields.
933
ac1bbaca
TBA
9342020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
935
936 Turn the 'stopped_by_watchpoint' and 'stopped_data_address' linux
937 target ops into methods of linux_process_target.
938
939 * linux-low.h (struct linux_target_ops): Remove the ops.
940 (class linux_process_target) <check_stopped_by_watchpoint>
941 <low_stopped_by_watchpoint>
942 <low_stopped_data_address>: Declare.
943 * linux-low.cc (check_stopped_by_watchpoint): Turn into...
944 (linux_process_target::check_stopped_by_watchpoint): ...this.
945 (linux_process_target::low_stopped_by_watchpoint): Define.
946 (linux_process_target::low_stopped_data_address): Define.
947 * linux-x86-low.cc (class x86_target) <low_stopped_by_watchpoint>
948 <low_stopped_data_address>: Declare.
949 (x86_stopped_by_watchpoint): Turn into...
950 (x86_target::low_stopped_by_watchpoint): ...this.
951 (x86_stopped_data_address): Turn into...
952 (x86_target::low_stopped_data_address): ...this.
953 (the_low_target): Remove the op fields.
954 * linux-aarch64-low.cc (class aarch64_target)
955 <low_stopped_by_watchpoint>
956 <low_stopped_data_address>: Declare.
957 (aarch64_stopped_by_watchpoint): Turn into...
958 (aarch64_target::low_stopped_by_watchpoint): ...this.
959 (aarch64_stopped_data_address): Turn into...
960 (aarch64_target::low_stopped_data_address): ...this.
961 (the_low_target): Remove the op fields.
962 * linux-arm-low.cc (class arm_target) <low_stopped_by_watchpoint>
963 <low_stopped_data_address>: Declare.
964 (arm_stopped_by_watchpoint): Turn into...
965 (arm_target::low_stopped_by_watchpoint): ...this.
966 (arm_stopped_data_address): Turn into...
967 (arm_target::low_stopped_data_address): ...this.
968 (the_low_target): Remove the op fields.
969 * linux-crisv32-low.cc (class crisv32_target)
970 <low_stopped_by_watchpoint>
971 <low_stopped_data_address>: Declare.
972 (cris_stopped_by_watchpoint): Turn into...
973 (crisv32_target::low_stopped_by_watchpoint): ...this.
974 (cris_stopped_data_address): Turn into...
975 (crisv32_target::low_stopped_data_address): ...this.
976 (the_low_target): Remove the op fields.
977 * linux-mips-low.cc (class mips_target) <low_stopped_by_watchpoint>
978 <low_stopped_data_address>: Declare.
979 (mips_stopped_by_watchpoint): Turn into...
980 (mips_target::low_stopped_by_watchpoint): ...this.
981 (mips_stopped_data_address): Turn into...
982 (mips_target::low_stopped_data_address): ...this.
983 (the_low_target): Remove the op fields.
984 * linux-bfin-low.cc (the_low_target): Remove the op fields.
985 * linux-m32r-low.cc (the_low_target): Ditto.
986 * linux-m68k-low.cc (the_low_target): Ditto.
987 * linux-ppc-low.cc (the_low_target): Ditto.
988 * linux-s390-low.cc (the_low_target): Ditto.
989 * linux-sh-low.cc (the_low_target): Ditto.
990 * linux-sparc-low.cc (the_low_target): Ditto.
991 * linux-tic6x-low.cc (the_low_target): Ditto.
992 * linux-tile-low.cc (the_low_target): Ditto.
993 * linux-xtensa-low.cc (the_low_target): Ditto.
994
9db9aa23
TBA
9952020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
996
997 Turn the 'insert_point' and 'remove_point' linux target ops into
998 methods of linux_process_target.
999
1000 * linux-low.h (struct linux_target_ops): Remove the ops.
1001 (class linux_process_target) <low_insert_point>
1002 <low_remove_point>: Declare.
1003 * linux-low.cc (linux_process_target::low_insert_point)
1004 (linux_process_target::low_remove_point): Define.
1005 (linux_process_target::insert_point)
1006 (linux_process_target::remove_point): Update for calls to
1007 low_insert_point and low_remove_point.
1008 * linux-x86-low.cc (class x86_target) <low_insert_point>
1009 <low_remove_point>: Declare.
1010 (x86_insert_point): Turn into...
1011 (x86_target::low_insert_point): ...this.
1012 (x86_remove_point): Turn into...
1013 (x86_target::low_remove_point): ...this.
1014 (the_low_target): Remove the op fields.
1015 * linux-aarch64-low.cc (class aarch64_target) <low_insert_point>
1016 <low_remove_point>: Declare.
1017 (aarch64_insert_point): Turn into...
1018 (aarch64_target::low_insert_point): ...this.
1019 (aarch64_remove_point): Turn into...
1020 (aarch64_target::low_remove_point): ...this.
1021 (the_low_target): Remove the op fields.
1022 * linux-arm-low.cc (class arm_target) <low_insert_point>
1023 <low_remove_point>: Declare.
1024 (arm_insert_point): Turn into...
1025 (arm_target::low_insert_point): ...this.
1026 (arm_remove_point): Turn into...
1027 (arm_target::low_remove_point): ...this.
1028 (the_low_target): Remove the op fields.
1029 * linux-crisv32-low.cc (class crisv32_target) <low_insert_point>
1030 <low_remove_point>: Declare.
1031 (crisv32_insert_point): Turn into...
1032 (crisv32_target::low_insert_point): ...this.
1033 (crisv32_remove_point): Turn into...
1034 (crisv32_target::low_remove_point): ...this.
1035 (the_low_target): Remove the op fields.
1036 * linux-mips-low.cc (class mips_target) <low_insert_point>
1037 <low_remove_point>: Declare.
1038 (mips_insert_point): Turn into...
1039 (mips_target::low_insert_point): ...this.
1040 (mips_remove_point): Turn into...
1041 (mips_target::low_remove_point): ...this.
1042 (the_low_target): Remove the op fields.
1043 * linux-ppc-low.cc (class ppc_target) <low_insert_point>
1044 <low_remove_point>: Declare.
1045 (ppc_insert_point): Turn into...
1046 (ppc_target::low_insert_point): ...this.
1047 (ppc_remove_point): Turn into...
1048 (ppc_target::low_remove_point): ...this.
1049 (the_low_target): Remove the op fields.
1050 * linux-bfin-low.cc (the_low_target): Remove the op fields.
1051 * linux-m32r-low.cc (the_low_target): Ditto.
1052 * linux-m68k-low.cc (the_low_target): Ditto.
1053 * linux-s390-low.cc (the_low_target): Ditto.
1054 * linux-sh-low.cc (the_low_target): Ditto.
1055 * linux-sparc-low.cc (the_low_target): Ditto.
1056 * linux-tic6x-low.cc (the_low_target): Ditto.
1057 * linux-tile-low.cc (the_low_target): Ditto.
1058 * linux-xtensa-low.cc (the_low_target): Ditto.
1059
007c9b97
TBA
10602020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1061
1062 Remove the 'supports_z_point_type' linux target op and let the
1063 concrete linux target define it by overriding the op declared in
1064 process_stratum_target.
1065
1066 * linux-low.cc (linux_process_target::supports_z_point_type):
1067 Remove.
1068 * linux-low.h (struct linux_target_ops): Remove the op.
1069 (class linux_process_target) <supports_z_point_type>: Remove.
1070 * linux-x86-low.cc (class x86_target) <supports_z_point_type>:
1071 Declare.
1072 (x86_supports_z_point_type): Turn into...
1073 (x86_target::supports_z_point_type): ...this.
1074 (the_low_target): Remove the op field.
1075 * linux-aarch64-low.cc (class aarch64_target)
1076 <supports_z_point_type>: Declare.
1077 (aarch64_supports_z_point_type): Turn into...
1078 (aarch64_target::supports_z_point_type): ...this.
1079 (the_low_target): Remove the op field.
1080 * linux-arm-low.cc (class arm_target) <supports_z_point_type>:
1081 Declare.
1082 (arm_supports_z_point_type): Turn into...
1083 (arm_target::supports_z_point_type): ...this.
1084 (the_low_target): Remove the op field.
1085 * linux-crisv32-low.cc (class crisv32_target)
1086 <supports_z_point_type>: Declare.
1087 (cris_supports_z_point_type): Turn into...
1088 (crisv32_target::supports_z_point_type): ...this.
1089 (the_low_target): Remove the op field.
1090 * linux-mips-low.cc (class mips_target) <supports_z_point_type>:
1091 Declare.
1092 (mips_supports_z_point_type): Turn into...
1093 (mips_target::supports_z_point_type): ...this.
1094 (the_low_target): Remove the op field.
1095 * linux-ppc-low.cc (class ppc_target) <supports_z_point_type>:
1096 Declare.
1097 (ppc_supports_z_point_type): Turn into...
1098 (ppc_target::supports_z_point_type): ...this.
1099 (the_low_target): Remove the op field.
1100 * linux-s390-low.cc (class s390_target) <supports_z_point_type>:
1101 Declare.
1102 (s390_supports_z_point_type): Turn into...
1103 (s390_target::supports_z_point_type): ...this.
1104 (the_low_target): Remove the op field.
1105 * linux-bfin-low.cc (the_low_target): Remove the op field.
1106 * linux-m32r-low.cc (the_low_target): Ditto.
1107 * linux-m68k-low.cc (the_low_target): Ditto.
1108 * linux-sh-low.cc (the_low_target): Ditto.
1109 * linux-sparc-low.cc (the_low_target): Ditto.
1110 * linux-tic6x-low.cc (the_low_target): Ditto.
1111 * linux-tile-low.cc (the_low_target): Ditto.
1112 * linux-xtensa-low.cc (the_low_target): Ditto.
1113
d7146cda
TBA
11142020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1115
1116 Turn the 'breakpoint_at' linux target op into a method of
1117 linux_process_target.
1118
1119 * linux-low.h (struct linux_target_ops): Remove the op.
1120 (class linux_process_target) <low_breakpoint_at>: Declare.
1121
1122 Update the callers below:
1123
1124 * linux-low.cc (linux_process_target::save_stop_reason)
1125 (linux_process_target::thread_still_has_status_pending)
1126 (linux_process_target::wait_1)
1127
1128 * linux-x86-low.cc (class x86_target)
1129 <low_breakpoint_at>: Declare.
1130 (x86_breakpoint_at): Turn into...
1131 (x86_target::low_breakpoint_at): ...this.
1132 (the_low_target): Remove the op field.
1133 * linux-aarch64-low.cc (class aarch64_target)
1134 <low_breakpoint_at>: Declare.
1135 (aarch64_breakpoint_at): Turn into...
1136 (aarch64_target::low_breakpoint_at): ...this.
1137 (the_low_target): Remove the op field.
1138 * linux-arm-low.cc (class arm_target)
1139 <low_breakpoint_at>: Declare.
1140 (arm_target::low_breakpoint_at): Define.
1141 (the_low_target): Remove the op field.
1142 * linux-bfin-low.cc (class bfin_target)
1143 <low_breakpoint_at>: Declare.
1144 (bfin_breakpoint_at): Turn into...
1145 (bfin_target::low_breakpoint_at): ...this.
1146 (the_low_target): Remove the op field.
1147 * linux-cris-low.cc (class cris_target)
1148 <low_breakpoint_at>: Declare.
1149 (cris_breakpoint_at): Turn into...
1150 (cris_target::low_breakpoint_at): ...this.
1151 (the_low_target): Remove the op field.
1152 * linux-crisv32-low.cc (class crisv32_target)
1153 <low_breakpoint_at>: Declare.
1154 (crisv32_breakpoint_at): Turn into...
1155 (crisv32_target::low_breakpoint_at): ...this.
1156 (the_low_target): Remove the op field.
1157 * linux-ia64-low.cc (class ia64_target)
1158 <low_breakpoint_at>: Declare.
1159 (ia64_target::low_breakpoint_at): Define.
1160 * linux-m32r-low.cc (class m32r_target)
1161 <low_breakpoint_at>: Declare.
1162 (m32r_breakpoint_at): Turn into...
1163 (m32r_target::low_breakpoint_at): ...this.
1164 (the_low_target): Remove the op field.
1165 * linux-m68k-low.cc (class m68k_target)
1166 <low_breakpoint_at>: Declare.
1167 (m68k_breakpoint_at): Turn into...
1168 (m68k_target::low_breakpoint_at): ...this.
1169 (the_low_target): Remove the op field.
1170 * linux-mips-low.cc (class mips_target)
1171 <low_breakpoint_at>: Declare.
1172 (mips_breakpoint_at): Turn into...
1173 (mips_target::low_breakpoint_at): ...this.
1174 (the_low_target): Remove the op field.
1175 * linux-nios2-low.cc (class nios2_target)
1176 <low_breakpoint_at>: Declare.
1177 (nios2_breakpoint_at): Turn into...
1178 (nios2_target::low_breakpoint_at): ...this.
1179 (the_low_target): Remove the op field.
1180 * linux-ppc-low.cc (class ppc_target)
1181 <low_breakpoint_at>: Declare.
1182 (ppc_breakpoint_at): Turn into...
1183 (ppc_target::low_breakpoint_at): ...this.
1184 (the_low_target): Remove the op field.
1185 * linux-riscv-low.cc (class riscv_target)
1186 <low_breakpoint_at>: Declare.
1187 (riscv_breakpoint_at): Turn into...
1188 (riscv_target::low_breakpoint_at): ...this.
1189 (the_low_target): Remove the op field.
1190 * linux-s390-low.cc (class s390_target)
1191 <low_breakpoint_at>: Declare.
1192 (s390_breakpoint_at): Turn into...
1193 (s390_target::low_breakpoint_at): ...this.
1194 (the_low_target): Remove the op field.
1195 * linux-sh-low.cc (class sh_target)
1196 <low_breakpoint_at>: Declare.
1197 (sh_breakpoint_at): Turn into...
1198 (sh_target::low_breakpoint_at): ...this.
1199 (the_low_target): Remove the op field.
1200 * linux-sparc-low.cc (class sparc_target)
1201 <low_breakpoint_at>: Declare.
1202 (sparc_breakpoint_at): Turn into...
1203 (sparc_target::low_breakpoint_at): ...this.
1204 (the_low_target): Remove the op field.
1205 * linux-tic6x-low.cc (class tic6x_target)
1206 <low_breakpoint_at>: Declare.
1207 (tic6x_breakpoint_at): Turn into...
1208 (tic6x_target::low_breakpoint_at): ...this.
1209 (the_low_target): Remove the op field.
1210 * linux-tile-low.cc (class tile_target)
1211 <low_breakpoint_at>: Declare.
1212 (tile_breakpoint_at): Turn into...
1213 (tile_target::low_breakpoint_at): ...this.
1214 (the_low_target): Remove the op field.
1215 * linux-xtensa-low.cc (class xtensa_target)
1216 <low_breakpoint_at>: Declare.
1217 (xtensa_breakpoint_at): Turn into...
1218 (xtensa_target::low_breakpoint_at): ...this.
1219 (the_low_target): Remove the op field.
1220
d4807ea2
TBA
12212020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1222
1223 Turn the 'decr_pc_after_break' linux_target_ops field into
1224 a method of linux_process_target.
1225
1226 * linux-low.h (struct linux_target_ops)
1227 <decr_pc_after_break>: Remove.
1228 (class linux_process_target) <low_decr_pc_after_break>: New method
1229 declaration.
1230 * linux-low.cc (linux_process_target::low_decr_pc_after_break):
1231 New method implementation.
1232
1233 Update the users below.
1234
1235 (linux_process_target::save_stop_reason)
1236 (linux_process_target::wait_1)
1237 * linux-x86-low.cc (class x86_target) <low_decr_pc_after_break>:
1238 New declaration.
1239 (x86_target::low_decr_pc_after_break): New method implementation.
1240 (the_low_target): Remove the field.
1241 * linux-bfin-low.cc (class bfin_target) <low_decr_pc_after_break>:
1242 New declaration.
1243 (bfin_target::low_decr_pc_after_break): New method implementation.
1244 (the_low_target): Remove the field.
1245 * linux-m68k-low.cc (class m68k_target) <low_decr_pc_after_break>:
1246 New declaration.
1247 (m68k_target::low_decr_pc_after_break): New method implementation.
1248 (the_low_target): Remove the field.
1249 * linux-s390-low.cc (class s390_target) <low_decr_pc_after_break>:
1250 New declaration.
1251 (s390_target::low_decr_pc_after_break): New method implementation.
1252 (the_low_target): Remove the field.
1253 * linux-aarch64-low.cc (the_low_target): Remove the field.
1254 * linux-arm-low.cc (the_low_target): Remove the field.
1255 * linux-cris-low.cc (the_low_target): Remove the field.
1256 * linux-crisv32-low.cc (the_low_target): Remove the field.
1257 * linux-m32r-low.cc (the_low_target): Remove the field.
1258 * linux-mips-low.cc (the_low_target): Remove the field.
1259 * linux-nios2-low.cc (the_low_target): Remove the field.
1260 * linux-ppc-low.cc (the_low_target): Remove the field.
1261 * linux-riscv-low.cc (the_low_target): Remove the field.
1262 * linux-sh-low.cc (the_low_target): Remove the field.
1263 * linux-sparc-low.cc (the_low_target): Remove the field.
1264 * linux-tic6x-low.cc (the_low_target): Remove the field.
1265 * linux-tile-low.cc (the_low_target): Remove the field.
1266 * linux-xtensa-low.cc (the_low_target): Remove the field.
1267
7582c77c
TBA
12682020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1269
1270 Remove the 'supports_software_single_step' linux target op and let
1271 the concrete linux target define it by overriding the op in
1272 process_stratum_target.
1273 Turn the 'get_next_pcs' linux target op into a method of
1274 linux_process_target.
1275
1276 * linux-low.h (struct linux_target_ops): Remove the ops.
1277 (class linux_process_target) <supports_software_single_step>:
1278 Remove.
1279 <low_get_next_pcs>: Declare.
1280 * linux-low.cc (can_software_single_step): Remove.
1281 (linux_process_target::low_get_next_pcs): Define.
1282 (linux_process_target::supports_software_single_step): Remove.
1283
1284 Update the callers below.
1285
1286 (linux_process_target::handle_extended_wait)
1287 (linux_process_target::wait_1)
1288 (linux_process_target::install_software_single_step_breakpoints)
1289 (linux_process_target::single_step)
1290 (linux_process_target::thread_needs_step_over)
1291 (linux_process_target::proceed_one_lwp)
1292 (linux_process_target::supports_range_stepping)
1293
1294 * linux-x86-low.cc (the_low_target): Remove the op field.
1295 * linux-aarch64-low.cc (the_low_target): Ditto.
1296 * linux-bfin-low.cc (the_low_target): Ditto.
1297 * linux-cris-low.cc (the_low_target): Ditto.
1298 * linux-crisv32-low.cc (the_low_target): Ditto.
1299 * linux-m32r-low.cc (the_low_target): Ditto.
1300 * linux-m68k-low.cc (the_low_target): Ditto.
1301 * linux-mips-low.cc (the_low_target): Ditto.
1302 * linux-nios2-low.cc (the_low_target): Ditto.
1303 * linux-ppc-low.cc (the_low_target): Ditto.
1304 * linux-riscv-low.cc (the_low_target): Ditto.
1305 * linux-s390-low.cc (the_low_target): Ditto.
1306 * linux-sh-low.cc (the_low_target): Ditto.
1307 * linux-sparc-low.cc (the_low_target): Ditto.
1308 * linux-tic6x-low.cc (the_low_target): Ditto.
1309 * linux-tile-low.cc (the_low_target): Ditto.
1310 * linux-xtensa-low.cc (the_low_target): Ditto.
1311 * linux-arm-low.cc (class arm_target) <low_get_next_pcs>
1312 <supports_software_single_step>: Declare.
1313 (arm_target::supports_software_single_step): Define.
1314 (arm_gdbserver_get_next_pcs): Turn into...
1315 (arm_target::low_get_next_pcs): ...this.
1316 (the_low_target): Remove the op field.
1317
3ca4edb6
TBA
13182020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1319
1320 Remove the 'sw_breakpoint_from_kind' linux target op, and let
1321 the concrete linux target define it by overriding the op
1322 in process_stratum_target.
1323
1324 * linux-low.cc (linux_process_target::sw_breakpoint_from_kind):
1325 Remove.
1326 * linux-low.h (struct linux_target_ops): Remove the op.
1327 (class linux_process_target) <sw_breakpoint_from_kind>: Remove.
1328 * linux-x86-low.cc (class x86_target) <sw_breakpoint_from_kind>:
1329 Declare.
1330 (x86_sw_breakpoint_from_kind): Turn into...
1331 (x86_target::sw_breakpoint_from_kind): ...this.
1332 (the_low_target): Remove the op field.
1333 * linux-aarch64-low.cc (class aarch64_target)
1334 <sw_breakpoint_from_kind>: Declare.
1335 (aarch64_sw_breakpoint_from_kind): Turn into...
1336 (aarch64_target::sw_breakpoint_from_kind): ...this.
1337 (the_low_target): Remove the op field.
1338 * linux-arm-low.cc (class arm_target) <sw_breakpoint_from_kind>:
1339 Declare.
1340 (arm_target::sw_breakpoint_from_kind): Define.
1341 (the_low_target): Remove the op field.
1342 * linux-bfin-low.cc (class bfin_target) <sw_breakpoint_from_kind>:
1343 Declare.
1344 (bfin_sw_breakpoint_from_kind): Turn into...
1345 (bfin_target::sw_breakpoint_from_kind): ...this.
1346 (the_low_target): Remove the op field.
1347 * linux-cris-low.cc (class cris_target) <sw_breakpoint_from_kind>:
1348 Declare.
1349 (cris_sw_breakpoint_from_kind): Turn into...
1350 (cris_target::sw_breakpoint_from_kind): ...this.
1351 (the_low_target): Remove the op field.
1352 * linux-crisv32-low.cc (class crisv32_target)
1353 <sw_breakpoint_from_kind>: Declare.
1354 (cris_sw_breakpoint_from_kind): Turn into...
1355 (crisv32_target::sw_breakpoint_from_kind): ...this.
1356 (the_low_target): Remove the op field.
1357 * linux-ia64-low.cc (class ia64_target) <sw_breakpoint_from_kind>:
1358 Declare.
1359 (ia64_target::sw_breakpoint_from_kind): Define.
1360 * linux-m32r-low.cc (class m32r_target) <sw_breakpoint_from_kind>:
1361 Declare.
1362 (m32r_sw_breakpoint_from_kind): Turn into...
1363 (m32r_target::sw_breakpoint_from_kind): ...this.
1364 (the_low_target): Remove the op field.
1365 * linux-m68k-low.cc (class m68k_target) <sw_breakpoint_from_kind>:
1366 Declare.
1367 (m68k_sw_breakpoint_from_kind): Turn into...
1368 (m68k_target::sw_breakpoint_from_kind): ...this.
1369 (the_low_target): Remove the op field.
1370 * linux-mips-low.cc (class mips_target) <sw_breakpoint_from_kind>:
1371 Declare.
1372 (mips_sw_breakpoint_from_kind): Turn into...
1373 (mips_target::sw_breakpoint_from_kind): ...this.
1374 (the_low_target): Remove the op field.
1375 * linux-nios2-low.cc (class nios2_target) <sw_breakpoint_from_kind>:
1376 Declare.
1377 (nios2_sw_breakpoint_from_kind): Turn into...
1378 (nios2_target::sw_breakpoint_from_kind): ...this.
1379 (the_low_target): Remove the op field.
1380 * linux-ppc-low.cc (class ppc_target) <sw_breakpoint_from_kind>:
1381 Declare.
1382 (ppc_sw_breakpoint_from_kind): Turn into...
1383 (ppc_target::sw_breakpoint_from_kind): ...this.
1384 (the_low_target): Remove the op field.
1385 * linux-riscv-low.cc (class riscv_target) <sw_breakpoint_from_kind>:
1386 Declare.
1387 (riscv_sw_breakpoint_from_kind): Turn into...
1388 (riscv_target::sw_breakpoint_from_kind): ...this.
1389 (the_low_target): Remove the op field.
1390 * linux-s390-low.cc (class s390_target) <sw_breakpoint_from_kind>:
1391 Declare.
1392 (s390_sw_breakpoint_from_kind): Turn into...
1393 (s390_target::sw_breakpoint_from_kind): ...this.
1394 (the_low_target): Remove the op field.
1395 * linux-sh-low.cc (class sh_target) <sw_breakpoint_from_kind>:
1396 Declare.
1397 (sh_sw_breakpoint_from_kind): Turn into...
1398 (sh_target::sw_breakpoint_from_kind): ...this.
1399 (the_low_target): Remove the op field.
1400 * linux-sparc-low.cc (class sparc_target) <sw_breakpoint_from_kind>:
1401 Declare.
1402 (sparc_sw_breakpoint_from_kind): Turn into...
1403 (sparc_target::sw_breakpoint_from_kind): ...this.
1404 (the_low_target): Remove the op field.
1405 * linux-tic6x-low.cc (class tic6x_target) <sw_breakpoint_from_kind>:
1406 Declare.
1407 (tic6x_sw_breakpoint_from_kind): Turn into...
1408 (tic6x_target::sw_breakpoint_from_kind): ...this.
1409 (the_low_target): Remove the op field.
1410 * linux-tile-low.cc (class tile_target) <sw_breakpoint_from_kind>:
1411 Declare.
1412 (tile_sw_breakpoint_from_kind): Turn into...
1413 (tile_target::sw_breakpoint_from_kind): ...this.
1414 (the_low_target): Remove the op field.
1415 * linux-xtensa-low.cc (class xtensa_target)
1416 <sw_breakpoint_from_kind>: Declare.
1417 (xtensa_sw_breakpoint_from_kind): Turn into...
1418 (xtensa_target::sw_breakpoint_from_kind): ...this.
1419 (the_low_target): Remove the op field.
1420
06250e4e
TBA
14212020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1422
1423 Remove the 'breakpoint_kind_from_pc' and
1424 'breakpoint_kind_from_current_state' linux target ops, and let the
1425 concrete linux target define them by overriding the ops of
1426 process_stratum_target.
1427
1428 * linux-low.cc (linux_process_target::breakpoint_kind_from_pc):
1429 Remove.
1430 (linux_process_target::breakpoint_kind_from_current_state): Remove.
1431 * linux-low.h (struct linux_target_ops): Remove ops.
1432 (class linux_process_target) <breakpoint_kind_from_pc>: Remove.
1433 <breakpoint_kind_from_current_state>: Remove.
1434 * linux-x86-low.cc (the_low_target): Remove the op fields.
1435 * linux-bfin-low.cc (the_low_target): Ditto.
1436 * linux-cris-low.cc (the_low_target): Ditto.
1437 * linux-crisv32-low.cc (the_low_target): Ditto.
1438 * linux-m32r-low.cc (the_low_target): Ditto.
1439 * linux-m68k-low.cc (the_low_target): Ditto.
1440 * linux-mips-low.cc (the_low_target): Ditto.
1441 * linux-nios2-low.cc (the_low_target): Ditto.
1442 * linux-ppc-low.cc (the_low_target): Ditto.
1443 * linux-s390-low.cc (the_low_target): Ditto.
1444 * linux-sh-low.cc (the_low_target): Ditto.
1445 * linux-sparc-low.cc (the_low_target): Ditto.
1446 * linux-tic6x-low.cc (the_low_target): Ditto.
1447 * linux-tile-low.cc (the_low_target): Ditto.
1448 * linux-xtensa-low.cc (the_low_target): Ditto.
1449 * linux-aarch64-low.cc (class aarch64_target)
1450 <breakpoint_kind_from_pc>
1451 <breakpoint_kind_from_current_state>: Declare.
1452 (aarch64_breakpoint_kind_from_pc): Turn into...
1453 (aarch64_target::breakpoint_kind_from_pc): ...this.
1454 (aarch64_breakpoint_kind_from_current_state): Turn into...
1455 (aarch64_target::breakpoint_kind_from_current_state): ...this.
1456 (the_low_target): Remove the op fields.
1457 * linux-arm-low.cc (class arm_target):
1458 <breakpoint_kind_from_pc>
1459 <breakpoint_kind_from_current_state>: Declare.
1460 (arm_target::breakpoint_kind_from_pc): Define.
1461 (arm_target::breakpoint_kind_from_current_state): Define.
1462 (the_low_target): Remove the op fields.
1463 * linux-riscv-low.cc (class riscv_target):
1464 <breakpoint_kind_from_pc>: Declare.
1465 (riscv_breakpoint_kind_from_pc): Turn into...
1466 (riscv_target::breakpoint_kind_from_pc): ...this.
1467 (the_low_target): Remove the op fields.
1468
bf9ae9d8
TBA
14692020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1470
1471 Turn the 'get_pc' and 'set_pc' linux target ops into methods
1472 of linux_process_target.
1473
1474 * linux-low.h (struct linux_target_ops): Remove the ops.
1475 (class linux_process_target) <low_supports_breakpoints>
1476 <low_get_pc>
1477 <low_set_pc>: Declare.
1478 * linux-low.cc (supports_breakpoints): Turn into...
1479 (linux_process_target::low_supports_breakpoints): ...this.
1480 (linux_process_target::low_get_pc): Define.
1481 (linux_process_target::low_set_pc): Define.
1482
1483 Update the callers below.
1484
1485 (linux_process_target::get_pc)
1486 (linux_process_target::save_stop_reason)
1487 (linux_process_target::maybe_move_out_of_jump_pad)
1488 (linux_process_target::wait_1)
1489 (linux_process_target::resume_one_lwp_throw)
1490 (linux_process_target::resume)
1491 (linux_process_target::proceed_all_lwps)
1492 (linux_process_target::read_pc)
1493 (linux_process_target::write_pc)
1494
1495 * linux-x86-low.cc (class linux_process_target)
1496 <low_supports_breakpoints>
1497 <low_get_pc>
1498 <low_set_pc>: Declare.
1499 (x86_target::low_supports_breakpoints): Define.
1500 (x86_get_pc): Turn into...
1501 (x86_target::low_get_pc): ...this.
1502 (x86_set_pc): Turn into...
1503 (x86_target::low_set_pc): ...this.
1504 (the_low_target): Remove the op fields.
1505 * linux-arm-low.cc (class arm_target)
1506 <low_supports_breakpoints>
1507 <low_get_pc>
1508 <low_set_pc>: Declare.
1509 (arm_target::low_supports_breakpoints)
1510 (arm_target::low_get_pc)
1511 (arm_target::low_set_pc): Define.
1512 (the_low_target): Remove the op fields.
1513 * linux-bfin-low.cc (class bfin_target)
1514 <low_supports_breakpoints>
1515 <low_get_pc>
1516 <low_set_pc>: Declare.
1517 (bfin_target::low_supports_breakpoints)
1518 (bfin_target::low_get_pc)
1519 (bfin_target::low_set_pc): Define.
1520 (the_low_target): Remove the op fields.
1521 * linux-cris-low.cc (class cris_target)
1522 <low_supports_breakpoints>
1523 <low_get_pc>
1524 <low_set_pc>: Declare.
1525 (cris_target::low_supports_breakpoints)
1526 (cris_target::low_get_pc)
1527 (cris_target::low_set_pc): Define.
1528 (the_low_target): Remove the op fields.
1529 * linux-crisv32-low.cc (class crisv32_target)
1530 <low_supports_breakpoints>
1531 <low_get_pc>
1532 <low_set_pc>: Declare.
1533 (crisv32_target::low_supports_breakpoints)
1534 (crisv32_target::low_get_pc)
1535 (crisv32_target::low_set_pc): Define.
1536 (the_low_target): Remove the op fields.
1537 * linux-m32r-low.cc (class m32r_target)
1538 <low_supports_breakpoints>
1539 <low_get_pc>
1540 <low_set_pc>: Declare.
1541 (m32r_target::low_supports_breakpoints)
1542 (m32r_target::low_get_pc)
1543 (m32r_target::low_set_pc): Define.
1544 (the_low_target): Remove the op fields.
1545 * linux-m68k-low.cc (class m68k_target)
1546 <low_supports_breakpoints>
1547 <low_get_pc>
1548 <low_set_pc>: Declare.
1549 (m68k_target::low_supports_breakpoints)
1550 (m68k_target::low_get_pc)
1551 (m68k_target::low_set_pc): Define.
1552 (the_low_target): Remove the op fields.
1553 * linux-nios2-low.cc (class nios2_target)
1554 <low_supports_breakpoints>
1555 <low_get_pc>
1556 <low_set_pc>: Declare.
1557 (nios2_target::low_supports_breakpoints)
1558 (nios2_target::low_get_pc)
1559 (nios2_target::low_set_pc): Define.
1560 (the_low_target): Remove the op fields.
1561 * linux-sh-low.cc (class sh_target)
1562 <low_supports_breakpoints>
1563 <low_get_pc>
1564 <low_set_pc>: Declare.
1565 (sh_target::low_supports_breakpoints)
1566 (sh_target::low_get_pc)
1567 (sh_target::low_set_pc): Define.
1568 (the_low_target): Remove the op fields.
1569 * linux-xtensa-low.cc (class xtensa_target)
1570 <low_supports_breakpoints>
1571 <low_get_pc>
1572 <low_set_pc>: Declare.
1573 (xtensa_target::low_supports_breakpoints)
1574 (xtensa_target::low_get_pc)
1575 (xtensa_target::low_set_pc): Define.
1576 (the_low_target): Remove the op fields.
1577 * linux-sparc-low.cc (class sparc_target)
1578 <low_supports_breakpoints>
1579 <low_get_pc>: Declare.
1580 (sparc_target::low_supports_breakpoints)
1581 (sparc_target::low_get_pc): Define.
1582 (the_low_target): Remove the op fields.
1583 * linux-tile-low.cc (class tile_target)
1584 <low_supports_breakpoints>
1585 <low_get_pc>
1586 <low_set_pc>: Declare.
1587 (tile_target::low_supports_breakpoints)
1588 (tile_target::low_get_pc)
1589 (tile_target::low_set_pc): Define.
1590 (the_low_target): Remove the op fields.
1591 * linux-aarch64-low.cc (class aarch64_target)
1592 <low_supports_breakpoints>
1593 <low_get_pc>
1594 <low_set_pc>: Declare.
1595 (aarch64_target::low_supports_breakpoints): Define.
1596 (aarch64_get_pc): Turn into...
1597 (aarch64_target::low_get_pc): ...this.
1598 (aarch64_set_pc): Turn into...
1599 (aarch64_target::low_set_pc): ...this.
1600 (the_low_target): Remove the op fields.
1601 * linux-mips-low.cc (class mips_target)
1602 <low_supports_breakpoints>
1603 <low_get_pc>
1604 <low_set_pc>: Declare.
1605 (mips_target::low_supports_breakpoints): Define.
1606 (mips_get_pc): Turn into...
1607 (mips_target::low_get_pc): ...this.
1608 (mips_set_pc): Turn into...
1609 (mips_target::low_set_pc): ...this.
1610 (the_low_target): Remove the op fields.
1611 * linux-ppc-low.cc (class ppc_target)
1612 <low_supports_breakpoints>
1613 <low_get_pc>
1614 <low_set_pc>: Declare.
1615 (ppc_target::low_supports_breakpoints): Define.
1616 (ppc_get_pc): Turn into...
1617 (ppc_target::low_get_pc): ...this.
1618 (ppc_set_pc): Turn into...
1619 (ppc_target::low_set_pc): ...this.
1620 (the_low_target): Remove the op fields.
1621 * linux-riscv-low.cc (class riscv_target)
1622 <low_supports_breakpoints>
1623 <low_get_pc>
1624 <low_set_pc>: Declare.
1625 (riscv_target::low_supports_breakpoints): Define.
1626 (riscv_get_pc): Turn into...
1627 (riscv_target::low_get_pc): ...this.
1628 (riscv_set_pc): Turn into...
1629 (riscv_target::low_set_pc): ...this.
1630 (the_low_target): Remove the op fields.
1631 * linux-s390-low.cc (class s390_target)
1632 <low_supports_breakpoints>
1633 <low_get_pc>
1634 <low_set_pc>: Declare.
1635 (s390_target::low_supports_breakpoints): Define.
1636 (s390_get_pc): Turn into...
1637 (s390_target::low_get_pc): ...this.
1638 (s390_set_pc): Turn into...
1639 (s390_target::low_set_pc): ...this.
1640 (the_low_target): Remove the op fields.
1641 * linux-tic6x-low.cc (class tic6x_target)
1642 <low_supports_breakpoints>
1643 <low_get_pc>
1644 <low_set_pc>: Declare.
1645 (tic6x_target::low_supports_breakpoints): Define.
1646 (tic6x_get_pc): Turn into...
1647 (tic6x_target::low_get_pc): ...this.
1648 (tic6x_set_pc): Turn into...
1649 (tic6x_target::low_set_pc): ...this.
1650 (the_low_target): Remove the op fields.
1651
df95181f
TBA
16522020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1653
1654 Turn some more static methods in linux-low into private methods
1655 of linux_process_target.
1656
1657 * linux-low.cc (get_pc): Turn into...
1658 (linux_process_target::get_pc): ...this.
1659 (save_stop_reason): Turn into...
1660 (linux_process_target::save_stop_reason): ...this.
1661 (thread_still_has_status_pending_p): Turn into...
1662 (linux_process_target::thread_still_has_status_pending): ...this.
1663 (status_pending_p_callback): Turn into...
1664 (linux_process_target::status_pending_p_callback): ...this.
1665 (resume_stopped_resumed_lwps): Turn into...
1666 (linux_process_target::resume_stopped_resumed_lwps): ...this.
1667 (install_software_single_step_breakpoints): Turn into...
1668 (linux_process_target::install_software_single_step_breakpoints):
1669 ...this.
1670 (single_step): Turn into...
1671 (linux_process_target::single_step): ...this.
1672 (linux_resume_one_lwp_throw): Turn into...
1673 (linux_process_target::resume_one_lwp_throw): ...this.
1674 (linux_resume_one_lwp): Turn into...
1675 (linux_process_target::resume_one_lwp): ...this.
1676 (resume_status_pending_p): Turn into...
1677 (linux_process_target::resume_status_pending): ...this.
1678 (need_step_over_p): Turn into...
1679 (linux_process_target::thread_needs_step_over): ...this.
1680 (linux_resume_one_thread): Turn into...
1681 (linux_process_target::resume_one_thread): ...this.
1682 (proceed_one_lwp): Turn into...
1683 (linux_process_target::proceed_one_lwp): ...this.
1684 (unsuspend_and_proceed_one_lwp): Turn into...
1685 (linux_process_target::unsuspend_and_proceed_one_lwp): ...this.
1686
1687 Update the calls/references to the above functions below.
1688
1689 (linux_process_target::handle_extended_wait)
1690 (linux_process_target::filter_event)
1691 (linux_process_target::wait_for_event_filtered)
1692 (linux_process_target::wait_1)
1693 (linux_process_target::move_out_of_jump_pad)
1694 (linux_process_target::start_step_over)
1695 (linux_process_target::resume)
1696 (linux_process_target::proceed_all_lwps)
1697 (regsets_store_inferior_registers)
1698 (linux_process_target::store_register)
1699
1700 * linux-low.h (class linux_process_target)
1701 <get_pc>
1702 <save_stop_reason>
1703 <thread_still_has_status_pending>
1704 <status_pending_p_callback>
1705 <resume_stopped_resumed_lwps>
1706 <install_software_single_step_breakpoints>
1707 <single_step>
1708 <resume_one_lwp_throw>
1709 <resume_one_lwp>
1710 <resume_status_pending>
1711 <thread_needs_step_over>
1712 <resume_one_thread>
1713 <proceed_one_lwp>
1714 <unsuspend_and_proceed_one_lwp>: Declare.
1715
bd70b1f2
TBA
17162020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1717
1718 Turn the 'fetch_register' linux target op into a method of
1719 linux_process_target.
1720
1721 * linux-low.h (struct linux_target_ops) <fetch_register>: Remove.
1722 (class linux_process_target) <low_fetch_register>: Declare.
1723 * linux-x86-low.cc (the_low_target)
1724 * linux-aarch64-low.cc (the_low_target)
1725 * linux-arm-low.cc (the_low_target)
1726 * linux-bfin-low.cc (the_low_target)
1727 * linux-cris-low.cc (the_low_target)
1728 * linux-crisv32-low.cc (the_low_target)
1729 * linux-m32r-low.cc (the_low_target)
1730 * linux-m68k-low.cc (the_low_target)
1731 * linux-nios2-low.cc (the_low_target)
1732 * linux-ppc-low.cc (the_low_target)
1733 * linux-s390-low.cc (the_low_target)
1734 * linux-sh-low.cc (the_low_target)
1735 * linux-sparc-low.cc (the_low_target)
1736 * linux-tic6x-low.cc (the_low_target)
1737 * linux-tile-low.cc (the_low_target)
1738 * linux-xtensa-low.cc (the_low_target): Remove the op field.
1739 * linux-ia64-low.cc (class ia64_target) <low_fetch_register>:
1740 Declare.
1741 (ia64_fetch_register): Turn into...
1742 (ia64_target::low_fetch_register): ...this.
1743 (the_low_target): Remove the op field.
1744 * linux-mips-low.cc (class mips_target) <low_fetch_register>:
1745 Declare.
1746 (mips_fetch_register): Turn into...
1747 (mips_target::low_fetch_register): ...this.
1748 (the_low_target): Remove the op field.
1749 * linux-riscv-low.cc (class riscv_target) <low_fetch_register>:
1750 Declare.
1751 (riscv_fetch_register): Turn into...
1752 (riscv_target::low_fetch_register): ...this.
1753 (the_low_target): Remove the op field.
1754
1755 Update the callers below.
1756
1757 * linux-low.cc (linux_process_target::fetch_registers)
1758 (linux_process_target::low_fetch_register)
1759
daca57a7
TBA
17602020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1761
1762 Turn the 'cannot_fetch_register' and 'cannot_store_register'
1763 linux target ops into methods of linux_process_target.
1764
1765 * linux-low.h (struct linux_target_ops): Remove the low target ops.
1766 (class linux_process_target) <fetch_register>
1767 <store_register>
1768 <usr_fetch_inferior_registers>
1769 <usr_store_inferior_registers>
1770 <low_cannot_fetch_register>
1771 <low_cannot_fetch_register> Declare.
1772 * linux-low.cc (fetch_register): Turn into...
1773 (linux_process_target::fetch_register): ...this.
1774 (store_register): Turn into ...
1775 (linux_process_target::store_register): ...this.
1776 (usr_fetch_inferior_registers): Turn into...
1777 (linux_process_target::usr_fetch_inferior_registers): ...this.
1778 (usr_store_inferior_registers): Turn into...
1779 (linux_process_target::usr_store_inferior_registers): ...this.
1780 * linux-x86-low.cc (class x86_target)
1781 <low_cannot_fetch_register>
1782 <low_cannot_store_register>: Declare.
1783 (x86_cannot_store_register): Turn into...
1784 (x86_target::low_cannot_store_register): ...this.
1785 (x86_cannot_fetch_register): Turn into...
1786 (x86_target::low_cannot_fetch_register): ...this.
1787 (the_low_target): Remove the target op fields.
1788 * linux-aarch64-low.cc (class aarch64_target)
1789 <low_cannot_fetch_register>
1790 <low_cannot_store_register>: Declare.
1791 (aarch64_target::low_cannot_fetch_register)
1792 (aarch64_target::low_cannot_store_register): Define.
1793 (the_low_target): Remove the op fields.
1794 * linux-arm-low.cc (class arm_target)
1795 <low_cannot_fetch_register>
1796 <low_cannot_store_register>: Declare.
1797 (arm_cannot_fetch_register): Turn into...
1798 (arm_target::low_cannot_fetch_register): ...this.
1799 (arm_cannot_store_register): Turn into...
1800 (arm_target::low_cannot_store_register): ...this.
1801 (the_low_target): Remove the op fields.
1802 * linux-bfin-low.cc (class bfin_target)
1803 <low_cannot_fetch_register>
1804 <low_cannot_store_register>: Declare.
1805 (bfin_cannot_fetch_register): Turn into...
1806 (bfin_target::low_cannot_fetch_register): ...this.
1807 (bfin_cannot_store_register): Turn into...
1808 (bfin_target::low_cannot_store_register): ...this.
1809 (the_low_target): Remove the op fields.
1810 * linux-cris-low.cc (class cris_target)
1811 <low_cannot_fetch_register>
1812 <low_cannot_store_register>: Declare.
1813 (cris_cannot_fetch_register): Turn into...
1814 (cris_target::low_cannot_fetch_register): ...this.
1815 (cris_cannot_store_register): Turn into...
1816 (cris_target::low_cannot_store_register): ...this.
1817 (the_low_target): Remove the op fields.
1818 * linux-crisv32-low.cc (class crisv32_target)
1819 <low_cannot_fetch_register>
1820 <low_cannot_store_register>: Declare.
1821 (crisv32_target::low_cannot_fetch_register)
1822 (crisv32_target::low_cannot_store_register): Define.
1823 (the_low_target): Remove the op fields.
1824 * linux-ia64-low.cc (class ia64_target)
1825 <low_cannot_fetch_register>
1826 <low_cannot_store_register>: Declare.
1827 (ia64_cannot_fetch_register): Turn into...
1828 (ia64_target::low_cannot_fetch_register): ...this.
1829 (ia64_cannot_store_register): Turn into...
1830 (ia64_target::low_cannot_store_register): ...this.
1831 (the_low_target): Remove the op fields.
1832 * linux-m32r-low.cc (class m32r_target)
1833 <low_cannot_fetch_register>
1834 <low_cannot_store_register>: Declare.
1835 (m32r_cannot_fetch_register): Turn into...
1836 (m32r_target::low_cannot_fetch_register): ...this.
1837 (m32r_cannot_store_register): Turn into...
1838 (m32r_target::low_cannot_store_register): ...this.
1839 (the_low_target): Remove the op fields.
1840 * linux-m68k-low.cc (class m68k_target)
1841 <low_cannot_fetch_register>
1842 <low_cannot_store_register>: Declare.
1843 (m68k_cannot_fetch_register): Turn into...
1844 (m68k_target::low_cannot_fetch_register): ...this.
1845 (m68k_cannot_store_register): Turn into...
1846 (m68k_target::low_cannot_store_register): ...this.
1847 (the_low_target): Remove the op fields.
1848 * linux-mips-low.cc (class mips_target)
1849 <low_cannot_fetch_register>
1850 <low_cannot_store_register>: Declare.
1851 (mips_cannot_fetch_register): Turn into...
1852 (mips_target::low_cannot_fetch_register): ...this.
1853 (mips_cannot_store_register): Turn into...
1854 (mips_target::low_cannot_store_register): ...this.
1855 (get_usrregs_info): Inline at the call sites in
1856 low_cannot_fetch_register and low_cannot_store_register,
1857 and remove.
1858 (the_low_target): Remove the op fields.
1859 * linux-nios2-low.cc (class nios2_target)
1860 <low_cannot_fetch_register>
1861 <low_cannot_store_register>: Declare.
1862 (nios2_cannot_fetch_register): Turn into...
1863 (nios2_target::low_cannot_fetch_register): ...this.
1864 (nios2_cannot_store_register): Turn into...
1865 (nios2_target::low_cannot_store_register): ...this.
1866 (the_low_target): Remove the op fields.
1867 * linux-ppc-low.cc (class ppc_target)
1868 <low_cannot_fetch_register>
1869 <low_cannot_store_register>: Declare.
1870 (ppc_cannot_fetch_register): Turn into...
1871 (ppc_target::low_cannot_fetch_register): ...this.
1872 (ppc_cannot_store_register): Turn into...
1873 (ppc_target::low_cannot_store_register): ...this.
1874 (the_low_target): Remove the op fields.
1875 * linux-riscv-low.cc (class riscv_target)
1876 <low_cannot_fetch_register>
1877 <low_cannot_store_register>: Declare.
1878 (riscv_target::low_cannot_fetch_register)
1879 (riscv_target::low_cannot_store_register): Define.
1880 (the_low_target): Remove the op fields.
1881 * linux-s390-low.cc (class s390_target)
1882 <low_cannot_fetch_register>
1883 <low_cannot_store_register>: Declare.
1884 (s390_cannot_fetch_register): Turn into...
1885 (s390_target::low_cannot_fetch_register): ...this.
1886 (s390_cannot_store_register): Turn into...
1887 (s390_target::low_cannot_store_register): ...this.
1888 (the_low_target): Remove the op fields.
1889 * linux-sh-low.cc (class sh_target)
1890 <low_cannot_fetch_register>
1891 <low_cannot_store_register>: Declare.
1892 (sh_cannot_fetch_register): Turn into...
1893 (sh_target::low_cannot_fetch_register): ...this.
1894 (sh_cannot_store_register): Turn into...
1895 (sh_target::low_cannot_store_register): ...this.
1896 (the_low_target): Remove the op fields.
1897 * linux-sparc-low.cc (class sparc_target)
1898 <low_cannot_fetch_register>
1899 <low_cannot_store_register>: Declare.
1900 (sparc_cannot_fetch_register): Turn into...
1901 (sparc_target::low_cannot_fetch_register): ...this.
1902 (sparc_cannot_store_register): Turn into...
1903 (sparc_target::low_cannot_store_register): ...this.
1904 (the_low_target): Remove the op fields.
1905 * linux-tic6x-low.cc (class tic6x_target)
1906 <low_cannot_fetch_register>
1907 <low_cannot_store_register>: Declare.
1908 (tic6x_cannot_fetch_register): Turn into...
1909 (tic6x_target::low_cannot_fetch_register): ...this.
1910 (tic6x_cannot_store_register): Turn into...
1911 (tic6x_target::low_cannot_store_register): ...this.
1912 (the_low_target): Remove the op fields.
1913 * linux-tile-low.cc (class tile_target)
1914 <low_cannot_fetch_register>
1915 <low_cannot_store_register>: Declare.
1916 (tile_cannot_fetch_register): Turn into...
1917 (tile_target::low_cannot_fetch_register): ...this.
1918 (tile_cannot_store_register): Turn into...
1919 (tile_target::low_cannot_store_register): ...this.
1920 (the_low_target): Remove the op fields.
1921 * linux-xtensa-low.cc (class xtensa_target)
1922 <low_cannot_fetch_register>
1923 <low_cannot_store_register>: Declare.
1924 (xtensa_target::low_cannot_fetch_register)
1925 (xtensa_target::low_cannot_store_register): Define.
1926 (the_low_target): Remove the op fields.
1927
aa8d21c9
TBA
19282020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1929
1930 Turn the 'regs_info' linux target op into a method of
1931 linux_process_target.
1932
1933 * linux-low.h (struct linux_target_ops) <regs_info>: Remove.
1934 (class linux_process_target) <get_regs_info>: Define.
1935
1936 Update the callers below.
1937
1938 * linux-low.cc (linux_process_target::fetch_registers)
1939 (linux_process_target::store_registers)
1940 * proc-service.cc (gregset_info)
1941
1942 * linux-x86-low.cc (class x86_target) <get_regs_info>: Declare.
1943 (x86_linux_regs_info): Turn into ...
1944 (x86_target::get_regs_info): ...this.
1945 (the_low_target): Remove the op field.
1946 * linux-aarch64-low.cc (class aarch64_target) <get_regs_info>:
1947 Declare.
1948 (aarch64_regs_info): Turn into ...
1949 (aarch64_target::get_regs_info): ...this.
1950 (the_low_target): Remove the op field.
1951 * linux-arm-low.cc (class arm_target) <get_regs_info>: Declare.
1952 (arm_regs_info): Turn into ...
1953 (arm_target::get_regs_info): ...this.
1954 (the_low_target): Remove the op field.
1955 * linux-bfin-low.cc (class bfin_target) <get_regs_info>: Declare.
1956 (bfin_regs_info): Turn into ...
1957 (bfin_target::get_regs_info): ...this.
1958 (the_low_target): Remove the op field.
1959 * linux-cris-low.cc (class cris_target) <get_regs_info>: Declare.
1960 (cris_regs_info): Turn into ...
1961 (cris_target::get_regs_info): ...this.
1962 (the_low_target): Remove the op field.
1963 * linux-crisv32-low.cc (class crisv32_target) <get_regs_info>:
1964 Declare.
1965 (crisv32_regs_info): Turn into ...
1966 (crisv32_target::get_regs_info): ...this.
1967 (the_low_target): Remove the op field.
1968 * linux-ia64-low.cc (class ia64_target) <get_regs_info>: Declare.
1969 (ia64_regs_info): Turn into ...
1970 (ia64_target::get_regs_info): ...this.
1971 (the_low_target): Remove the op field.
1972 * linux-m32r-low.cc (class m32r_target) <get_regs_info>: Declare.
1973 (m32r_regs_info): Turn into ...
1974 (m32r_target::get_regs_info): ...this.
1975 (the_low_target): Remove the op field.
1976 * linux-m68k-low.cc (class m68k_target) <get_regs_info>: Declare.
1977 (m68k_regs_info): Turn into ...
1978 (m68k_target::get_regs_info): ...this.
1979 (the_low_target): Remove the op field.
1980 * linux-mips-low.cc (class mips_target) <get_regs_info>: Declare.
1981 (mips_regs_info): Turn into ...
1982 (mips_target::get_regs_info): ...this.
1983 (the_low_target): Remove the op field.
1984 (get_usrregs_info): Update the call to the op.
1985 * linux-nios2-low.cc (class nios2_target) <get_regs_info>: Declare.
1986 (nios2_regs_info): Turn into ...
1987 (nios2_target::get_regs_info): ...this.
1988 (the_low_target): Remove the op field.
1989 * linux-ppc-low.cc (class ppc_target) <get_regs_info>: Declare.
1990 (ppc_regs_info): Turn into ...
1991 (ppc_target::get_regs_info): ...this.
1992 (the_low_target): Remove the op field.
1993 * linux-riscv-low.cc (class riscv_target) <get_regs_info>: Declare.
1994 (riscv_regs_info): Turn into ...
1995 (riscv_target::get_regs_info): ...this.
1996 (the_low_target): Remove the op field.
1997 * linux-s390-low.cc (class s390_target) <get_regs_info>: Declare.
1998 (s390_regs_info): Turn into ...
1999 (s390_target::get_regs_info): ...this.
2000 (the_low_target): Remove the op field.
2001 (s390_collect_ptrace_register)
2002 (s390_supply_ptrace_register)
2003 (s390_fill_gregset): Update the call to the op.
2004 * linux-sh-low.cc (class sh_target) <get_regs_info>: Declare.
2005 (sh_regs_info): Turn into ...
2006 (sh_target::get_regs_info): ...this.
2007 (the_low_target): Remove the op field.
2008 * linux-sparc-low.cc (class sparc_target) <get_regs_info>: Declare.
2009 (sparc_regs_info): Turn into ...
2010 (sparc_target::get_regs_info): ...this.
2011 (the_low_target): Remove the op field.
2012 * linux-tic6x-low.cc (class tic6x_target) <get_regs_info>: Declare.
2013 (tic6x_regs_info): Turn into ...
2014 (tic6x_target::get_regs_info): ...this.
2015 (the_low_target): Remove the op field.
2016 * linux-tile-low.cc (class tile_target) <get_regs_info>: Declare.
2017 (tile_regs_info): Turn into ...
2018 (tile_target::get_regs_info): ...this.
2019 (the_low_target): Remove the op field.
2020 * linux-xtensa-low.cc (class xtensa_target) <get_regs_info>:
2021 Declare.
2022 (xtensa_regs_info): Turn into ...
2023 (xtensa_target::get_regs_info): ...this.
2024 (the_low_target): Remove the op field.
2025
797bcff5
TBA
20262020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2027
2028 Turn the 'arch_setup' linux target op into a method of
2029 linux_process_target.
2030
2031 * linux-low.h (struct linux_target_ops) <arch_setup>: Delete.
2032 (class linux_process_target) <arch_setup_thread>
2033 <low_arch_setup>: New declarations.
2034 * linux-low.cc (linux_arch_setup): Delete.
2035 (linux_arch_setup_thread): Turn into...
2036 (linux_process_target::arch_setup_thread): ... this.
2037
2038 Update the callers below.
2039
2040 (linux_process_target::handle_extended_wait)
2041 (linux_process_target::post_create_inferior)
2042 (linux_process_target::filter_event)
2043
2044 * linux-x86-low.cc (class x86_target) <low_arch_setup>: New
2045 declaration.
2046 (x86_linux_update_xmltarget): Turn into...
2047 (x86_target::update_xmltarget): ...this.
2048 (x86_linux_process_qsupported): Update the call to
2049 x86_linux_update_xmltarget.
2050 (x86_arch_setup): Turn into ...
2051 (x86_target::low_arch_setup): ...this.
2052 (the_low_target): Remove the op field.
2053 * linux-aarch64-low.cc (class aarch64_target) <low_arch_setup>: New
2054 declaration.
2055 (aarch64_arch_setup): Turn into ...
2056 (aarch64_target::low_arch_setup): ...this.
2057 (the_low_target): Remove the op field.
2058 * linux-arm-low.cc (class arm_target) <low_arch_setup>: New
2059 declaration.
2060 (arm_arch_setup): Turn into ...
2061 (arm_target::low_arch_setup): ...this.
2062 (the_low_target): Remove the op field.
2063 * linux-bfin-low.cc (class bfin_target) <low_arch_setup>: New
2064 declaration.
2065 (bfin_arch_setup): Turn into ...
2066 (bfin_target::low_arch_setup): ...this.
2067 (the_low_target): Remove the op field.
2068 * linux-cris-low.cc (class cris_target) <low_arch_setup>: New
2069 declaration.
2070 (cris_arch_setup): Turn into ...
2071 (cris_target::low_arch_setup): ...this.
2072 (the_low_target): Remove the op field.
2073 * linux-crisv32-low.cc (class crisv32_target) <low_arch_setup>: New
2074 declaration.
2075 (crisv32_arch_setup): Turn into ...
2076 (crisv32_target::low_arch_setup): ...this.
2077 (the_low_target): Remove the op field.
2078 * linux-ia64-low.cc (class ia64_target) <low_arch_setup>: New
2079 declaration.
2080 (ia64_arch_setup): Turn into ...
2081 (ia64_target::low_arch_setup): ...this.
2082 (the_low_target): Remove the op field.
2083 * linux-m32r-low.cc (class m32r_target) <low_arch_setup>: New
2084 declaration.
2085 (m32r_arch_setup): Turn into ...
2086 (m32r_target::low_arch_setup): ...this.
2087 (the_low_target): Remove the op field.
2088 * linux-m68k-low.cc (class m68k_target) <low_arch_setup>: New
2089 declaration.
2090 (m68k_arch_setup): Turn into ...
2091 (m68k_target::low_arch_setup): ...this.
2092 (the_low_target): Remove the op field.
2093 * linux-mips-low.cc (class mips_target) <low_arch_setup>: New
2094 declaration.
2095 (mips_arch_setup): Turn into ...
2096 (mips_target::low_arch_setup): ...this.
2097 (the_low_target): Remove the op field.
2098 * linux-nios2-low.cc (class nios2_target) <low_arch_setup>: New
2099 declaration.
2100 (nios2_arch_setup): Turn into ...
2101 (nios2_target::low_arch_setup): ...this.
2102 (the_low_target): Remove the op field.
2103 * linux-ppc-low.cc (class ppc_target) <low_arch_setup>: New
2104 declaration.
2105 (ppc_arch_setup): Turn into ...
2106 (ppc_target::low_arch_setup): ...this.
2107 (the_low_target): Remove the op field.
2108 * linux-riscv-low.cc (class riscv_target) <low_arch_setup>: New
2109 declaration.
2110 (riscv_arch_setup): Turn into ...
2111 (riscv_target::low_arch_setup): ...this.
2112 (the_low_target): Remove the op field.
2113 * linux-s390-low.cc (class s390_target) <low_arch_setup>: New
2114 declaration.
2115 (s390_arch_setup): Turn into ...
2116 (s390_target::low_arch_setup): ...this.
2117 (the_low_target): Remove the op field.
2118 * linux-sh-low.cc (class sh_target) <low_arch_setup>: New
2119 declaration.
2120 (sh_arch_setup): Turn into ...
2121 (sh_target::low_arch_setup): ...this.
2122 (the_low_target): Remove the op field.
2123 * linux-sparc-low.cc (class sparc_target) <low_arch_setup>: New
2124 declaration.
2125 (sparc_arch_setup): Turn into ...
2126 (sparc_target::low_arch_setup): ...this.
2127 (the_low_target): Remove the op field.
2128 * linux-tic6x-low.cc (class tic6x_target) <low_arch_setup>: New
2129 declaration.
2130 (tic6x_arch_setup): Turn into ...
2131 (tic6x_target::low_arch_setup): ...this.
2132 (the_low_target): Remove the op field.
2133 * linux-tile-low.cc (class tile_target) <low_arch_setup>: New
2134 declaration.
2135 (tile_arch_setup): Turn into ...
2136 (tile_target::low_arch_setup): ...this.
2137 (the_low_target): Remove the op field.
2138 * linux-xtensa-low.cc (class xtensa_target) <low_arch_setup>: New
2139 declaration.
2140 (xtensa_arch_setup): Turn into ...
2141 (xtensa_target::low_arch_setup): ...this.
2142 (the_low_target): Remove the op field.
2143
ef0478f6
TBA
21442020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2145
2146 * linux-low.h (the_linux_target): New extern declaration.
2147 * linux-low.cc (initialize_low): Use 'the_linux_target' to set
2148 'the_target'.
2149 (the_linux_target): Remove.
2150 * linux-x86-low.cc (class x86_target): New class.
2151 (the_x86_target): New static object.
2152 (the_linux_target): Define as pointer to the_x86_target.
2153 * linux-aarch64-low.cc (class aarch64_target): New class.
2154 (the_aarch64_target): New static object.
2155 (the_linux_target): Define as pointer to the_aarch64_target.
2156 * linux-arm-low.cc (class arm_target): New class.
2157 (the_arm_target): New static object.
2158 (the_linux_target): Define as pointer to the_arm_target.
2159 * linux-bfin-low.cc (class bfin_target): New class.
2160 (the_bfin_target): New static object.
2161 (the_linux_target): Define as pointer to the_bfin_target.
2162 * linux-cris-low.cc (class cris_target): New class.
2163 (the_cris_target): New static object.
2164 (the_linux_target): Define as pointer to the_cris_target.
2165 * linux-crisv32-low.cc (class crisv32_target): New class.
2166 (the_crisv32_target): New static object.
2167 (the_linux_target): Define as pointer to the_crisv32_target.
2168 * linux-ia64-low.cc (class ia64_target): New class.
2169 (the_ia64_target): New static object.
2170 (the_linux_target): Define as pointer to the_ia64_target.
2171 * linux-m32r-low.cc (class m32r_target): New class.
2172 (the_m32r_target): New static object.
2173 (the_linux_target): Define as pointer to the_m32r_target.
2174 * linux-m68k-low.cc (class m68k_target): New class.
2175 (the_m68k_target): New static object.
2176 (the_linux_target): Define as pointer to the_m68k_target.
2177 * linux-mips-low.cc (class mips_target): New class.
2178 (the_mips_target): New static object.
2179 (the_linux_target): Define as pointer to the_mips_target.
2180 * linux-nios2-low.cc (class nios2_target): New class.
2181 (the_nios2_target): New static object.
2182 (the_linux_target): Define as pointer to the_nios2_target.
2183 * linux-ppc-low.cc (class ppc_target): New class.
2184 (the_ppc_target): New static object.
2185 (the_linux_target): Define as pointer to the_ppc_target.
2186 * linux-riscv-low.cc (class riscv_target): New class.
2187 (the_riscv_target): New static object.
2188 (the_linux_target): Define as pointer to the_riscv_target.
2189 * linux-s390-low.cc (class s390_target): New class.
2190 (the_s390_target): New static object.
2191 (the_linux_target): Define as pointer to the_s390_target.
2192 * linux-sh-low.cc (class sh_target): New class.
2193 (the_sh_target): New static object.
2194 (the_linux_target): Define as pointer to the_sh_target.
2195 * linux-sparc-low.cc (class sparc_target): New class.
2196 (the_sparc_target): New static object.
2197 (the_linux_target): Define as pointer to the_sparc_target.
2198 * linux-tic6x-low.cc (class tic6x_target): New class.
2199 (the_tic6x_target): New static object.
2200 (the_linux_target): Define as pointer to the_tic6x_target.
2201 * linux-tile-low.cc (class tile_target): New class.
2202 (the_tile_target): New static object.
2203 (the_linux_target): Define as pointer to the_tile_target.
2204 * linux-xtensa-low.cc (class xtensa_target): New class.
2205 (the_xtensa_target): New static object.
2206 (the_linux_target): Define as pointer to the_xtensa_target.
2207
d16f3f6c
TBA
22082020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2209
2210 Turn some static functions in linux-low.cc into private methods of
2211 linux_process_target.
2212
2213 * linux-low.cc (handle_extended_wait): Turn into ...
2214 (linux_process_target::handle_extended_wait): ...this. Call
2215 'mourn' on 'this' object instead of 'the_target'.
2216 (maybe_move_out_of_jump_pad): Turn into...
2217 (linux_process_target::maybe_move_out_of_jump_pad): ...this.
2218 (linux_low_filter_event): Turn into...
2219 (linux_process_target::filter_event): ...this.
2220 (linux_wait_for_event_filtered): Turn into...
2221 (linux_process_target::wait_for_event_filtered): ...this.
2222 (linux_wait_for_event): Turn into...
2223 (linux_process_target::wait_for_event): ...this.
2224 (linux_wait_1): Turn into...
2225 (linux_process_target::wait_1): ...this.
2226 (wait_for_sigstop): Turn into...
2227 (linux_process_target::wait_for_sigstop): ...this.
2228 (move_out_of_jump_pad_callback): Turn into...
2229 (linux_process_target::move_out_of_jump_pad): ...this.
2230 (stop_all_lwps): Turn into...
2231 (linux_process_target::stop_all_lwps): ...this.
2232 (start_step_over): Turn into...
2233 (linux_process_target::start_step_over): ...this.
2234 (complete_ongoing_step_over): Turn into...
2235 (linux_process_target::complete_ongoing_step_over): ...this.
2236 (proceed_all_lwps): Turn into...
2237 (linux_process_target::proceed_all_lwps): ...this.
2238 (unstop_all_lwps): Turn into...
2239 (linux_process_target::unstop_all_lwps): ...this.
2240
2241 * linux-low.h (class linux_process_target)
2242 <handle_extended_wait>
2243 <maybe_move_out_of_jump_pad>
2244 filter_event>
2245 <wait_for_event_filtered>
2246 <wait_for_event>
2247 <wait_1>
2248 <wait_for_sigstop>
2249 <move_out_of_jump_pad>
2250 <stop_all_lwps>
2251 <start_step_over>
2252 <complete_ongoing_step_over>
2253 <proceed_all_lwps>
2254 <unstop_all_lwps>: Declare.
2255
2256 Update the callers below.
2257
2258 * linux-low.cc (linux_process_target::attach): Update.
2259 (linux_process_target::stabilize_threads): Ditto.
2260 (linux_process_target::wait): Ditto.
2261
a5863204
TBA
22622020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2263
2264 * linux-low.h (struct linux_target_ops): Update the comment for
2265 'cannot_store_register' to return 0 or 1.
2266 * linux-ppc-low.cc (ppc_cannot_store_register): Return 1 instead
2267 of 2.
2268
c884cc46
SM
22692020-03-20 Simon Marchi <simon.marchi@efficios.com>
2270
2271 * config.in: Re-generate.
2272 * configure: Re-generate.
2273
5a82b8a1
KR
22742020-03-17 Kamil Rytarowski <n54@gmx.com>
2275
2276 * regcache.cc (find_register_by_number): Update.
2277 * tdesc.cc (init_target_desc): Likewise.
2278 * tdesc.h (target_desc::reg_defs): Likewise.
2279
4635ff97
TT
22802020-03-12 Tom Tromey <tom@tromey.com>
2281
2282 * configure: Rebuild.
2283 * configure.ac (GDBSERVER_DEPFILES): Remove srv_selftest_objs.
2284 (WIN32APILIBS): New subst.
2285 * Makefile.in (SFILES, OBS, TAGS, GDBREPLAY_OBS): Remove
2286 gdbsupport files.
2287 (gdbsupport/%.o): Remove target.
2288 (GDBSUPPORT_BUILDDIR, GDBSUPPORT): New variables.
2289 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Add GDBSUPPORT.
2290 (WIN32APILIBS): New variable.
2291 (gdbserver$(EXEEXT)): Add WIN32APILIBS.
2292 (gdbreplay$(EXEEXT)): Likewise.
2293
9a665d62
TT
22942020-03-12 Tom Tromey <tom@tromey.com>
2295
2296 * config.in, configure: Rebuild.
2297 * configure.ac: Call ZW_GNU_GETTEXT_SISTER_DIR.
2298 * acinclude.m4: Include gettext-sister.m4.
2299 * Makefile.in (top_builddir, INTL, INTL_DEPS, INTL_CFLAGS): New
2300 variables.
2301 (INCLUDE_CFLAGS): Add INTL_CFLAGS.
2302 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Use INTL_DEPS, INTL.
2303
272cd5a3
SM
23042020-03-12 Simon Marchi <simon.marchi@efficios.com>
2305
2306 * acinclude.m4: Update path to selftest.m4.
2307
db6878ac
SM
23082020-03-12 Simon Marchi <simon.marchi@efficios.com>
2309
2310 * configure.ac: Don't source bfd/development.sh, move
2311 GDB_AC_COMMON higher.
2312 * configure: Re-generate.
2313
4d696a5c
SM
23142020-03-12 Simon Marchi <simon.marchi@efficios.com>
2315
2316 * configure: Re-generate.
2317
a0761e34
SM
23182020-03-11 Simon Marchi <simon.marchi@efficios.com>
2319
2320 * configure: Re-generate.
2321
20ea4a60
AB
23222020-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
2323
2324 * .dir-locals.el: New file.
2325
842806cb
TBA
23262020-03-05 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2327
2328 * .gitattributes: New file.
2329
442131c1
AB
23302020-03-02 Andrew Burgess <andrew.burgess@embecosm.com>
2331
2332 * remote-utils.cc (prepare_resume_reply): Add ability to convert T
2333 reply into an S reply.
2334 * server.cc (disable_packet_T): New global.
2335 (captured_main): Set new global when appropriate.
2336 * server.h (disable_packet_T): Declare.
2337
dda42c0b
TT
23382020-02-21 Tom Tromey <tom@tromey.com>
2339
2340 * Makefile.in (mostlyclean): New target.
2341
52405d85
TBA
23422020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2343
2344 * target.h (struct process_stratum_target): Remove.
2345 (class process_target): Rename to ...
2346 (class process_stratum_target): ... this.
2347 * linux-low.h (class linux_process_target): Derive from
2348 'process_stratum_target'.
2349 * linux-low.cc (linux_target_ops): Remove.
2350 (initialize_low): Set the_target to the singleton instance of
2351 linux_process_target.
2352 * lynx-low.h (class lynx_process_target): Derive from
2353 'process_stratum_target'.
2354 * lynx-low.cc (lynx_target_ops): Remove.
2355 (initialize_low): Set the_target to the singleton instance of
2356 lynx_process_target.
2357 * nto-low.h (class nto_process_target): Derive from
2358 'process_stratum_target'.
2359 * nto-low.cc (nto_target_ops): Remove.
2360 (initialize_low): Set the_target to the singleton instance of
2361 nto_process_target.
2362 * win32-low.h (class win32_process_target): Derive from
2363 'process_stratum_target'.
2364 * win32-low.cc (win32_target_ops): Remove.
2365 (initialize_low): Set the_target to the singleton instance of
2366 win32_process_target.
2367
2368 Replace 'the_target->pt' with 'the_target' in the uses below.
2369
2370 * hostio.cc (hostio_error)
2371 (handle_setfs)
2372 (handle_open)
2373 (handle_unlink)
2374 (handle_readlink)
2375 * linux-aarch32-low.cc (arm_breakpoint_at)
2376 * linux-aarch64-low.cc (aarch64_breakpoint_at)
2377 * linux-arm-low.cc (arm_sigreturn_next_pc)
2378 (arm_get_hwcap)
2379 (arm_get_syscall_trapinfo)
2380 * linux-cris-low.cc (cris_breakpoint_at)
2381 * linux-crisv32-low.cc (cris_breakpoint_at)
2382 * linux-low.cc (handle_extended_wait)
2383 (linux_wait_1)
2384 (linux_read_memory)
2385 (linux_process_target::breakpoint_kind_from_pc)
2386 (linux_get_auxv)
2387 * linux-m32r-low.cc (m32r_breakpoint_at)
2388 * linux-mips-low.cc (mips_breakpoint_at)
2389 * linux-nios2-low.cc (nios2_breakpoint_at)
2390 * linux-ppc-low.cc (ppc_breakpoint_at)
2391 * linux-s390-low.cc (s390_get_hwcap)
2392 * linux-sh-low.cc (sh_breakpoint_at)
2393 * linux-sparc-low.cc (sparc_fill_gregset_to_stack)
2394 (sparc_store_gregset_from_stack)
2395 (sparc_breakpoint_at)
2396 * linux-tic6x-low.cc (tic6x_breakpoint_at)
2397 * linux-tile-low.cc (tile_breakpoint_at)
2398 * linux-x86-low.cc (x86_breakpoint_at)
2399 * linux-xtensa-low.cc (xtensa_breakpoint_at)
2400 * mem-break.cc (bp_size)
2401 (bp_opcode)
2402 (insert_memory_breakpoint)
2403 (set_raw_breakpoint_at)
2404 (delete_raw_breakpoint)
2405 (z_type_supported)
2406 (uninsert_raw_breakpoint)
2407 (reinsert_raw_breakpoint)
2408 (validate_inserted_breakpoint)
2409 * regcache.cc (regcache_read_pc)
2410 (regcache_write_pc)
2411 * remote-utils.cc (putpkt_binary_1)
2412 (input_interrupt)
2413 (getpkt)
2414 (prepare_resume_reply)
2415 * server.cc (handle_general_set)
2416 (handle_detach)
2417 (handle_qxfer_auxv)
2418 (handle_qxfer_exec_file)
2419 (handle_qxfer_libraries_svr4)
2420 (handle_qxfer_osdata)
2421 (handle_qxfer_siginfo)
2422 (handle_qxfer_fdpic)
2423 (handle_query)
2424 (resume)
2425 (handle_v_requests)
2426 (queue_stop_reply_callback)
2427 (captured_main)
2428 * target.cc (prepare_to_access_memory)
2429 (done_accessing_memory)
2430 (read_inferior_memory)
2431 (target_write_memory)
2432 (target_stop_and_wait)
2433 (target_wait)
2434 (target_mourn_inferior)
2435 (target_continue_no_signal)
2436 (target_continue)
2437 (target_supports_multi_process)
2438 (kill_inferior)
2439 * target.h
2440 (target_create_inferior)
2441 (target_post_create_inferior)
2442 (myattach)
2443 (target_supports_fork_events)
2444 (target_supports_vfork_events)
2445 (target_supports_exec_events)
2446 (target_handle_new_gdb_connection)
2447 (detach_inferior)
2448 (mythread_alive)
2449 (fetch_inferior_registers)
2450 (store_inferior_registers)
2451 (join_inferior)
2452 (target_supports_non_stop)
2453 (target_async)
2454 (target_process_qsupported)
2455 (target_supports_catch_syscall)
2456 (target_get_ipa_tdesc_idx)
2457 (target_supports_tracepoints)
2458 (target_supports_fast_tracepoints)
2459 (target_get_min_fast_tracepoint_insn_len)
2460 (target_thread_stopped)
2461 (target_pause_all)
2462 (target_unpause_all)
2463 (target_stabilize_threads)
2464 (target_install_fast_tracepoint_jump_pad)
2465 (target_emit_ops)
2466 (target_supports_disable_randomization)
2467 (target_supports_agent)
2468 (target_enable_btrace)
2469 (target_disable_btrace)
2470 (target_read_btrace)
2471 (target_read_btrace_conf)
2472 (target_supports_range_stepping)
2473 (target_supports_stopped_by_sw_breakpoint)
2474 (target_stopped_by_sw_breakpoint)
2475 (target_supports_stopped_by_hw_breakpoint)
2476 (target_supports_hardware_single_step)
2477 (target_stopped_by_hw_breakpoint)
2478 (target_breakpoint_kind_from_pc)
2479 (target_breakpoint_kind_from_current_state)
2480 (target_supports_software_single_step)
2481 (target_core_of_thread)
2482 (target_thread_name)
2483 (target_thread_handle)
2484 * win32-low.cc (do_initial_child_stuff)
2485
2486 Rename target op default definitions listed below.
2487
2488 * target.cc (process_target::post_create_inferior): Rename as ...
2489 (process_stratum_target::post_create_inferior): ... this.
2490 (process_target::prepare_to_access_memory): Rename as ...
2491 (process_stratum_target::prepare_to_access_memory): ... this.
2492 (process_target::done_accessing_memory): Rename as ...
2493 (process_stratum_target::done_accessing_memory): ... this.
2494 (process_target::look_up_symbols): Rename as ...
2495 (process_stratum_target::look_up_symbols): ... this.
2496 (process_target::supports_read_auxv): Rename as ...
2497 (process_stratum_target::supports_read_auxv): ... this.
2498 (process_target::read_auxv): Rename as ...
2499 (process_stratum_target::read_auxv): ... this.
2500 (process_target::supports_z_point_type): Rename as ...
2501 (process_stratum_target::supports_z_point_type): ... this.
2502 (process_target::insert_point): Rename as ...
2503 (process_stratum_target::insert_point): ... this.
2504 (process_target::remove_point): Rename as ...
2505 (process_stratum_target::remove_point): ... this.
2506 (process_target::stopped_by_sw_breakpoint): Rename as ...
2507 (process_stratum_target::stopped_by_sw_breakpoint): ... this.
2508 (process_target::supports_stopped_by_sw_breakpoint): Rename as ...
2509 (process_stratum_target::supports_stopped_by_sw_breakpoint): ... this.
2510 (process_target::stopped_by_hw_breakpoint): Rename as ...
2511 (process_stratum_target::stopped_by_hw_breakpoint): ... this.
2512 (process_target::supports_stopped_by_hw_breakpoint): Rename as ...
2513 (process_stratum_target::supports_stopped_by_hw_breakpoint): ... this.
2514 (process_target::supports_hardware_single_step): Rename as ...
2515 (process_stratum_target::supports_hardware_single_step): ... this.
2516 (process_target::stopped_by_watchpoint): Rename as ...
2517 (process_stratum_target::stopped_by_watchpoint): ... this.
2518 (process_target::stopped_data_address): Rename as ...
2519 (process_stratum_target::stopped_data_address): ... this.
2520 (process_target::supports_read_offsets): Rename as ...
2521 (process_stratum_target::supports_read_offsets): ... this.
2522 (process_target::read_offsets): Rename as ...
2523 (process_stratum_target::read_offsets): ... this.
2524 (process_target::supports_get_tls_address): Rename as ...
2525 (process_stratum_target::supports_get_tls_address): ... this.
2526 (process_target::get_tls_address): Rename as ...
2527 (process_stratum_target::get_tls_address): ... this.
2528 (process_target::hostio_last_error): Rename as ...
2529 (process_stratum_target::hostio_last_error): ... this.
2530 (process_target::supports_qxfer_osdata): Rename as ...
2531 (process_stratum_target::supports_qxfer_osdata): ... this.
2532 (process_target::qxfer_osdata): Rename as ...
2533 (process_stratum_target::qxfer_osdata): ... this.
2534 (process_target::supports_qxfer_siginfo): Rename as ...
2535 (process_stratum_target::supports_qxfer_siginfo): ... this.
2536 (process_target::qxfer_siginfo): Rename as ...
2537 (process_stratum_target::qxfer_siginfo): ... this.
2538 (process_target::supports_non_stop): Rename as ...
2539 (process_stratum_target::supports_non_stop): ... this.
2540 (process_target::async): Rename as ...
2541 (process_stratum_target::async): ... this.
2542 (process_target::start_non_stop): Rename as ...
2543 (process_stratum_target::start_non_stop): ... this.
2544 (process_target::supports_multi_process): Rename as ...
2545 (process_stratum_target::supports_multi_process): ... this.
2546 (process_target::supports_fork_events): Rename as ...
2547 (process_stratum_target::supports_fork_events): ... this.
2548 (process_target::supports_vfork_events): Rename as ...
2549 (process_stratum_target::supports_vfork_events): ... this.
2550 (process_target::supports_exec_events): Rename as ...
2551 (process_stratum_target::supports_exec_events): ... this.
2552 (process_target::handle_new_gdb_connection): Rename as ...
2553 (process_stratum_target::handle_new_gdb_connection): ... this.
2554 (process_target::handle_monitor_command): Rename as ...
2555 (process_stratum_target::handle_monitor_command): ... this.
2556 (process_target::core_of_thread): Rename as ...
2557 (process_stratum_target::core_of_thread): ... this.
2558 (process_target::supports_read_loadmap): Rename as ...
2559 (process_stratum_target::supports_read_loadmap): ... this.
2560 (process_target::read_loadmap): Rename as ...
2561 (process_stratum_target::read_loadmap): ... this.
2562 (process_target::process_qsupported): Rename as ...
2563 (process_stratum_target::process_qsupported): ... this.
2564 (process_target::supports_tracepoints): Rename as ...
2565 (process_stratum_target::supports_tracepoints): ... this.
2566 (process_target::read_pc): Rename as ...
2567 (process_stratum_target::read_pc): ... this.
2568 (process_target::write_pc): Rename as ...
2569 (process_stratum_target::write_pc): ... this.
2570 (process_target::supports_thread_stopped): Rename as ...
2571 (process_stratum_target::supports_thread_stopped): ... this.
2572 (process_target::thread_stopped): Rename as ...
2573 (process_stratum_target::thread_stopped): ... this.
2574 (process_target::supports_get_tib_address): Rename as ...
2575 (process_stratum_target::supports_get_tib_address): ... this.
2576 (process_target::get_tib_address): Rename as ...
2577 (process_stratum_target::get_tib_address): ... this.
2578 (process_target::pause_all): Rename as ...
2579 (process_stratum_target::pause_all): ... this.
2580 (process_target::unpause_all): Rename as ...
2581 (process_stratum_target::unpause_all): ... this.
2582 (process_target::stabilize_threads): Rename as ...
2583 (process_stratum_target::stabilize_threads): ... this.
2584 (process_target::supports_fast_tracepoints): Rename as ...
2585 (process_stratum_target::supports_fast_tracepoints): ... this.
2586 (process_target::get_min_fast_tracepoint_insn_len): Rename as ...
2587 (process_stratum_target::get_min_fast_tracepoint_insn_len): ... this.
2588 (process_target::emit_ops): Rename as ...
2589 (process_stratum_target::emit_ops): ... this.
2590 (process_target::supports_disable_randomization): Rename as ...
2591 (process_stratum_target::supports_disable_randomization): ... this.
2592 (process_target::supports_qxfer_libraries_svr4): Rename as ...
2593 (process_stratum_target::supports_qxfer_libraries_svr4): ... this.
2594 (process_target::qxfer_libraries_svr4): Rename as ...
2595 (process_stratum_target::qxfer_libraries_svr4): ... this.
2596 (process_target::supports_agent): Rename as ...
2597 (process_stratum_target::supports_agent): ... this.
2598 (process_target::enable_btrace): Rename as ...
2599 (process_stratum_target::enable_btrace): ... this.
2600 (process_target::disable_btrace): Rename as ...
2601 (process_stratum_target::disable_btrace): ... this.
2602 (process_target::read_btrace): Rename as ...
2603 (process_stratum_target::read_btrace): ... this.
2604 (process_target::read_btrace_conf): Rename as ...
2605 (process_stratum_target::read_btrace_conf): ... this.
2606 (process_target::supports_range_stepping): Rename as ...
2607 (process_stratum_target::supports_range_stepping): ... this.
2608 (process_target::supports_pid_to_exec_file): Rename as ...
2609 (process_stratum_target::supports_pid_to_exec_file): ... this.
2610 (process_target::pid_to_exec_file): Rename as ...
2611 (process_stratum_target::pid_to_exec_file): ... this.
2612 (process_target::supports_multifs): Rename as ...
2613 (process_stratum_target::supports_multifs): ... this.
2614 (process_target::multifs_open): Rename as ...
2615 (process_stratum_target::multifs_open): ... this.
2616 (process_target::multifs_unlink): Rename as ...
2617 (process_stratum_target::multifs_unlink): ... this.
2618 (process_target::multifs_readlink): Rename as ...
2619 (process_stratum_target::multifs_readlink): ... this.
2620 (process_target::breakpoint_kind_from_pc): Rename as ...
2621 (process_stratum_target::breakpoint_kind_from_pc): ... this.
2622 (process_target::breakpoint_kind_from_current_state): Rename as ...
2623 (process_stratum_target::breakpoint_kind_from_current_state): ... this.
2624 (process_target::thread_name): Rename as ...
2625 (process_stratum_target::thread_name): ... this.
2626 (process_target::thread_handle): Rename as ...
2627 (process_stratum_target::thread_handle): ... this.
2628 (process_target::supports_software_single_step): Rename as ...
2629 (process_stratum_target::supports_software_single_step): ... this.
2630 (process_target::supports_catch_syscall): Rename as ...
2631 (process_stratum_target::supports_catch_syscall): ... this.
2632 (process_target::get_ipa_tdesc_idx): Rename as ...
2633 (process_stratum_target::get_ipa_tdesc_idx): ... this.
2634
478f9adf
PA
26352020-02-20 Pedro Alves <palves@redhat.com>
2636
2637 * target.cc (set_target_ops): Simply copy the given target pointer
2638 instead of creating a copy of the pointed object.
2639
d633e831
TBA
26402020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2641
2642 Turn process_stratum_target's get_ipa_tdesc_idx op into a method
2643 of process_target.
2644
2645 * target.h (struct process_stratum_target): Remove the target op.
2646 (class process_target): Add the target op.
2647 (target_get_ipa_tdesc_idx): Update the macro.
2648 * target.cc (process_target::get_ipa_tdesc_idx): Define.
2649
2650 Update the derived classes and callers below.
2651
2652 * linux-low.cc (linux_target_ops): Update.
2653 (linux_get_ipa_tdesc_idx): Turn into ...
2654 (linux_process_target::get_ipa_tdesc_idx): ... this.
2655 * linux-low.h (class linux_process_target): Update.
2656 * lynx-low.cc (lynx_target_ops): Update.
2657 * nto-low.cc (nto_target_ops): Update.
2658 * win32-low.cc (win32_target_ops): Update.
2659
bc8d3ae4
TBA
26602020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2661
2662 Turn process_stratum_target's supports_catch_syscall op into a
2663 method of process_target.
2664
2665 * target.h (struct process_stratum_target): Remove the target op.
2666 (class process_target): Add the target op.
2667 (target_supports_catch_syscall): Update the macro.
2668 * target.cc (process_target::supports_catch_syscall): Define.
2669
2670 Update the derived classes and callers below.
2671
2672 * linux-low.cc (linux_target_ops): Update.
2673 (linux_supports_catch_syscall): Turn into ...
2674 (linux_process_target::supports_catch_syscall): ... this.
2675 * linux-low.h (class linux_process_target): Update.
2676 * lynx-low.cc (lynx_target_ops): Update.
2677 * nto-low.cc (nto_target_ops): Update.
2678 * win32-low.cc (win32_target_ops): Update.
2679
5303a34f
TBA
26802020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2681
2682 Turn process_stratum_target's supports_software_single_step op
2683 into a method of process_target.
2684
2685 * target.h (struct process_stratum_target): Remove the target op.
2686 (class process_target): Add the target op.
2687 (target_supports_software_single_step): Update the macro.
2688 * target.cc (process_target::supports_software_single_step): Define.
2689
2690 Update the derived classes and callers below.
2691
2692 * linux-low.cc (linux_target_ops): Update.
2693 (linux_supports_software_single_step): Turn into ...
2694 (linux_process_target::supports_software_single_step): ... this.
2695 * linux-low.h (class linux_process_target): Update.
2696 * lynx-low.cc (lynx_target_ops): Update.
2697 * nto-low.cc (nto_target_ops): Update.
2698 * win32-low.cc (win32_target_ops): Update.
2699
7f63b89b
TBA
27002020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2701
2702 Turn process_stratum_target's thread_name and thread_handle ops
2703 into methods of process_target.
2704
2705 * target.h (struct process_stratum_target): Remove the target ops.
2706 (class process_target): Add the target ops.
2707 (target_thread_name): Update the macro.
2708 (target_thread_handle): Update the macro.
2709 * target.cc (process_target::thread_name): Define.
2710 (process_target::thread_handle): Define.
2711
2712 Update the derived classes and callers below.
2713
2714 * linux-low.cc (linux_target_ops): Update.
2715 (linux_process_target::thread_name): Define.
2716 (linux_process_target::thread_handle): Define.
2717 * linux-low.h (class linux_process_target): Update.
2718 * lynx-low.cc (lynx_target_ops): Update.
2719 * nto-low.cc (nto_target_ops): Update.
2720 * win32-low.cc (win32_target_ops): Update.
2721
d367006f
TBA
27222020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2723
2724 Turn process_stratum_target's breakpoint_kind_from_pc,
2725 sw_breakpoint_from_kind, and breakpoint_kind_from_current_state
2726 ops into methods of process_target.
2727
2728 * target.h (struct process_stratum_target): Remove the target op.
2729 (class process_target): Add the target op.
2730 (target_breakpoint_kind_from_pc): Update the macro.
2731 (target_breakpoint_kind_from_current_state): Update the macro.
2732 (default_breakpoint_kind_from_pc): Remove declaration.
2733 * target.cc (default_breakpoint_kind_from_pc): Turn into ...
2734 (process_target::breakpoint_kind_from_pc): ... this.
2735 (process_target::breakpoint_kind_from_current_state): Define.
2736
2737 Update the derived classes and callers below.
2738
2739 * mem-break.cc (bp_size): Update.
2740 (bp_opcode): Update.
2741 * linux-low.cc (linux_target_ops): Update.
2742 (linux_wait_1): Update.
2743 (linux_breakpoint_kind_from_pc): Turn into ...
2744 (linux_process_target::breakpoint_kind_from_pc): ... this.
2745 (linux_sw_breakpoint_from_kind): Turn into ...
2746 (linux_process_target::sw_breakpoint_from_kind): ... this.
2747 (linux_breakpoint_kind_from_current_state): Turn into ...
2748 (linux_process_target::breakpoint_kind_from_current_state): ... this.
2749 * linux-low.h (class linux_process_target): Update.
2750 * lynx-low.cc (lynx_target_ops): Update.
2751 (lynx_process_target::sw_breakpoint_from_kind): Define.
2752 * lynx-low.h (class lynx_process_target): Update.
2753 * nto-low.cc (nto_target_ops): Update.
2754 (nto_sw_breakpoint_from_kind): Turn into ...
2755 (nto_process_target::sw_breakpoint_from_kind): ... this.
2756 * nto-low.h (class nto_process_target): Update.
2757 * win32-low.cc (win32_target_ops): Update.
2758 (win32_sw_breakpoint_from_kind): Turn into ...
2759 (win32_process_target::sw_breakpoint_from_kind): ... this.
2760 * win32-low.h (class win32_process_target): Update.
2761
c9b7b804
TBA
27622020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2763
2764 Turn process_stratum_target's multifs_open, multifs_readlink,
2765 multifs_unlink ops into methods of process_target.
2766
2767 * target.h (struct process_stratum_target): Remove the target ops.
2768 (class process_target): Add the target ops. Also add
2769 'supports_multifs'.
2770 * target.cc: Include "fcntl.h", "unistd.h", "sys/types.h", and
2771 "sys/stat.h".
2772 (process_target::supports_multifs): Define.
2773 (process_target::multifs_open): Define.
2774 (process_target::multifs_readlink): Define.
2775 (process_target::multifs_unlink): Define.
2776
2777 Update the derived classes and callers below.
2778
2779 * hostio.cc (handle_setfs): Update.
2780 (handle_open): Update.
2781 (handle_unlink): Update.
2782 (handle_readlink): Update.
2783 * linux-low.cc (linux_target_ops): Update.
2784 (linux_process_target::supports_multifs): Define.
2785 (linux_process_target::multifs_open): Define.
2786 (linux_process_target::multifs_readlink): Define.
2787 (linux_process_target::multifs_unlink): Define.
2788 * linux-low.h (class linux_process_target): Update.
2789 * lynx-low.cc (lynx_target_ops): Update.
2790 * nto-low.cc (nto_target_ops): Update.
2791 * win32-low.cc (win32_target_ops): Update.
2792
8247b823
TBA
27932020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2794
2795 Turn process_stratum_target's pid_to_exec_file op into a method
2796 of process_target.
2797
2798 * target.h (struct process_stratum_target): Remove the target op.
2799 (class process_target): Add the target op. Also add
2800 'supports_pid_to_exec_file'.
2801 * target.cc (process_target::pid_to_exec_file): Define.
2802 (process_target::supports_pid_to_exec_file): Define.
2803
2804 Update the derived classes and callers below.
2805
2806 * server.cc (handle_qxfer_exec_file): Update.
2807 (handle_query): Update.
2808 * linux-low.cc (linux_target_ops): Update.
2809 (linux_process_target::supports_pid_to_exec_file): Define.
2810 (linux_process_target::pid_to_exec_file): Define.
2811 * linux-low.h (class linux_process_target): Update.
2812 * lynx-low.cc (lynx_target_ops): Update.
2813 * nto-low.cc (nto_target_ops): Update.
2814 * win32-low.cc (win32_target_ops): Update.
2815
2526e0cd
TBA
28162020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2817
2818 Turn process_stratum_target's supports_range_stepping op into a
2819 method of process_target.
2820
2821 * target.h (struct process_stratum_target): Remove the target op.
2822 (class process_target): Add the target op.
2823 (target_supports_range_stepping): Update the macro.
2824 * target.cc (process_target::supports_range_stepping): Define.
2825
2826 Update the derived classes and callers below.
2827
2828 * linux-low.cc (linux_target_ops): Update.
2829 (linux_supports_range_stepping): Turn into ...
2830 (linux_process_target::supports_range_stepping): ... this.
2831 * linux-low.h (class linux_process_target): Update.
2832 * lynx-low.cc (lynx_target_ops): Update.
2833 * nto-low.cc (nto_target_ops): Update.
2834 * win32-low.cc (win32_target_ops): Update.
2835
79597bdd
TBA
28362020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2837
2838 Turn process_stratum_target's btrace-related ops (enable_btrace,
2839 disable_btrace, read_btrace, read_btrace_conf) into methods of
2840 process_target.
2841
2842 * target.h (struct process_stratum_target): Remove the target ops.
2843 (class process_target): Add the target ops.
2844 (target_enable_btrace): Update.
2845 (target_disable_btrace): Update.
2846 (target_read_btrace): Update.
2847 (target_read_btrace_conf): Update.
2848 * target.cc (process_target::enable_btrace): Define.
2849 (process_target::disable_btrace): Define.
2850 (process_target::read_btrace): Define.
2851 (process_target::read_btrace_conf): Define.
2852
2853 Update the derived classes and callers below.
2854
2855 * linux-low.cc (linux_target_ops): Update.
2856 (linux_process_target:enable_btrace): Define as a wrapper around
2857 linux_enable_btrace.
2858 (linux_low_disable_btrace): Turn into ...
2859 (linux_process_target::disable_btrace): ... this.
2860 (linux_low_read_btrace): Turn into ...
2861 (linux_process_target::read_btrace): ... this.
2862 (linux_low_btrace_conf): Turn into ...
2863 (linux_process_target::read_btrace_conf): ... this.
2864 * linux-low.h (class linux_process_target): Update.
2865 * lynx-low.cc (lynx_target_ops): Update.
2866 * nto-low.cc (nto_target_ops): Update.
2867 * win32-low.cc (win32_target_ops): Update.
2868
c0245cb9
TBA
28692020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2870
2871 Turn process_stratum_target's supports_agent op into a method of
2872 process_target.
2873
2874 * target.h (struct process_stratum_target): Remove the target op.
2875 (class process_target): Add the target op.
2876 (target_supports_agent): Update the macro.
2877 * target.cc (process_target::supports_agent): Define.
2878
2879 Update the derived classes and callers below.
2880
2881 * linux-low.cc (linux_target_ops): Update.
2882 (linux_supports_agent): Turn into ...
2883 (linux_process_target::supports_agent): ... this.
2884 * linux-low.h (class linux_process_target): Update.
2885 * lynx-low.cc (lynx_target_ops): Update.
2886 * nto-low.cc (nto_target_ops): Update.
2887 * win32-low.cc (win32_target_ops): Update.
2888
974387bb
TBA
28892020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2890
2891 Turn process_stratum_target's qxfer_libraries_svr4 op into a
2892 method of process_target.
2893
2894 * target.h (struct process_stratum_target): Remove the target op.
2895 (class process_target): Add the target op. Also add
2896 'supports_qxfer_libraries_svr4'.
2897 * target.cc (process_target::qxfer_libraries_svr4): Define.
2898 (process_target::supports_qxfer_libraries_svr4): Define.
2899
2900 Update the derived classes and callers below.
2901
2902 * server.cc (handle_qxfer_libraries_svr4): Update.
2903 (handle_query): Update.
2904 * linux-low.cc (linux_target_ops): Update.
2905 (linux_process_target::supports_qxfer_libraries_svr4): Define.
2906 (linux_qxfer_libraries_svr4): Turn into ...
2907 (linux_process_target::qxfer_libraries_svr4): ... this.
2908 * linux-low.h (class linux_process_target): Update.
2909 * lynx-low.cc (lynx_target_ops): Update.
2910 * nto-low.cc (nto_target_ops): Update.
2911 * win32-low.cc (win32_target_ops): Update.
2912
c756403b
TBA
29132020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2914
2915 Turn process_stratum_target's supports_disable_randomization op
2916 into a method of process_target.
2917
2918 * target.h (struct process_stratum_target): Remove the target op.
2919 (class process_target): Add the target op.
2920 (target_supports_disable_randomization): Update the macro.
2921 * target.cc (process_target::supports_disable_randomization): Define.
2922
2923 Update the derived classes and callers below.
2924
2925 * linux-low.cc (linux_target_ops): Update.
2926 (linux_supports_disable_randomization): Turn into ...
2927 (linux_process_target::supports_disable_randomization): ... this.
2928 * linux-low.h (class linux_process_target): Update.
2929 * lynx-low.cc (lynx_target_ops): Update.
2930 * nto-low.cc (nto_target_ops): Update.
2931 * win32-low.cc (win32_target_ops): Update.
2932
345dafad
TBA
29332020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2934
2935 Turn process_stratum_target's emit_ops op into a method of
2936 process_target.
2937
2938 * target.h (struct process_stratum_target): Remove the target op.
2939 (class process_target): Add the target op.
2940 (target_emit_ops): Update the macro.
2941 * target.cc (process_target::emit_ops): Define.
2942
2943 Update the derived classes and callers below.
2944
2945 * linux-low.cc (linux_target_ops): Update.
2946 (linux_emit_ops): Turn into ...
2947 (linux_process_target::emit_ops): ... this.
2948 * linux-low.h (class linux_process_target): Update.
2949 * lynx-low.cc (lynx_target_ops): Update.
2950 * nto-low.cc (nto_target_ops): Update.
2951 * win32-low.cc (win32_target_ops): Update.
2952
c23c9391
TBA
29532020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2954
2955 Turn process_stratum_target's install_fast_tracepoint_jump_pad
2956 and get_min_fast_tracepoint_insn_len ops into methods of
2957 process_target.
2958
2959 * target.h (struct process_stratum_target): Remove the target ops.
2960 (class process_target): Add the target ops. Also add
2961 'supports_fast_tracepoints'.
2962 (target_supports_fast_tracepoints): Update the macro.
2963 (target_get_min_fast_tracepoint_insn_len): Update the macro.
2964 (install_fast_tracepoint_jump_pad): Update and rename the macro
2965 to ...
2966 (target_install_fast_tracepoint_jump_pad): ... this.
2967 * target.cc (process_target::supports_fast_tracepoints): Define.
2968 (process_target::install_fast_tracepoint_jump_pad): Define.
2969 (process_target::get_min_fast_tracepoint_insn_len): Define.
2970
2971 Update the derived classes and callers below.
2972
2973 * tracepoint.cc (install_fast_tracepoint): Update.
2974 * linux-low.cc (linux_target_ops): Update.
2975 (linux_process_target::supports_fast_tracepoints): Define.
2976 (linux_install_fast_tracepoint_jump_pad): Turn into ...
2977 (linux_process_target::install_fast_tracepoint_jump_pad): ... this.
2978 (linux_get_min_fast_tracepoint_insn_len): Turn into ...
2979 (linux_process_target::get_min_fast_tracepoint_insn_len): ... this.
2980 * linux-low.h (class linux_process_target): Update.
2981 * lynx-low.cc (lynx_target_ops): Update.
2982 * nto-low.cc (nto_target_ops): Update.
2983 * win32-low.cc (win32_target_ops): Update.
2984
5c9eb2f2
TBA
29852020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2986
2987 Turn process_stratum_target's stabilize_threads op into a
2988 method of process_target.
2989
2990 * target.h (struct process_stratum_target): Remove the target op.
2991 (class process_target): Add the target op.
2992 (target_stabilize_threads): Update the macro.
2993 * target.cc (process_target::stabilize_threads): Define.
2994
2995 Update the derived classes and callers below.
2996
2997 * server.cc (handle_status): Update.
2998 * tracepoint.cc (cmd_qtdp): Update.
2999 (cmd_qtstart): Update.
3000 * linux-low.cc (linux_target_ops): Update.
3001 (linux_stabilize_threads): Turn into ...
3002 (linux_process_target::stabilize_threads): ... this.
3003 (linux_wait_1): Update.
3004 * linux-low.h (class linux_process_target): Update.
3005 * lynx-low.cc (lynx_target_ops): Update.
3006 * nto-low.cc (nto_target_ops): Update.
3007 * win32-low.cc (win32_target_ops): Update.
3008
29e8dc09
TBA
30092020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3010
3011 Turn process_stratum_target's pause_all and unpause_all ops
3012 into methods of process_target.
3013
3014 * target.h (struct process_stratum_target): Remove the target ops.
3015 (class process_target): Add the target ops.
3016 (pause_all): Update the macro and rename to...
3017 (target_pause_all): ... this.
3018 (unpause_all): Update the macro and rename to...
3019 (target_unpause_all): ... this.
3020 * target.cc (process_target::pause_all): Define.
3021 (process_target::unpause_all): Define.
3022
3023 Update the derived classes and callers below.
3024
3025 * server.cc (handle_status): Update.
3026 * tracepoint.cc (clear_installed_tracepoints): Update.
3027 (cmd_qtdp): Update.
3028 (cmd_qtstart): Update.
3029 (stop_tracing): Update.
3030 (cmd_qtstatus): Update.
3031 (upload_fast_traceframes): Update.
3032 (run_inferior_command): Update.
3033 * linux-low.cc (linux_target_ops): Update.
3034 (linux_pause_all): Turn into ...
3035 (linux_process_target::pause_all): ... this.
3036 (linux_unpause_all): Turn into ...
3037 (linux_process_target::unpause_all): ... this.
3038 (linux_process_target::prepare_to_access_memory): Update.
3039 (linux_process_target::done_accessing_memory): Update.
3040 * linux-low.h (class linux_process_target): Update.
3041 * lynx-low.cc (lynx_target_ops): Update.
3042 * nto-low.cc (nto_target_ops): Update.
3043 * win32-low.cc (win32_target_ops): Update.
3044
4e2e869c
TBA
30452020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3046
3047 Turn process_stratum_target's get_tib_address op into a method of
3048 process_target.
3049
3050 * target.h (struct process_stratum_target): Remove the target op.
3051 (class process_target): Add the target op. Also add
3052 'supports_get_tib_address'.
3053 * target.cc (process_target::get_tib_address): Define.
3054 (process_target::supports_get_tib_address): Define.
3055
3056 Update the derived classes and callers below.
3057
3058 * server.cc (handle_query): Update.
3059 * linux-low.cc (win32_target_ops): Update.
3060 * lynx-low.cc (lynx_target_ops): Update.
3061 * nto-low.cc (nto_target_ops): Update.
3062 * win32-low.cc (win32_target_ops): Update.
3063 (win32_process_target::supports_get_tib_address): Define.
3064 (win32_get_tib_address): Turn into ...
3065 (win32_process_target::get_tib_address): ... this.
3066 * win32-low.h (class win32_process_target): Update.
3067
68119632
TBA
30682020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3069
3070 Turn process_stratum_target's thread_stopped op into a method of
3071 process_target.
3072
3073 * target.h (struct process_stratum_target): Remove the target op.
3074 (class process_target): Add the target op. Also add
3075 'supports_thread_stopped'.
3076 (target_thread_stopped): Update the macro.
3077 * target.cc (process_target::thread_stopped): Define.
3078 (process_target::supports_thread_stopped): Define.
3079 (prepare_to_access_memory): Update.
3080
3081 Update the derived classes and callers below.
3082
3083 * server.cc (queue_stop_reply_callback): Update.
3084 * linux-low.cc (linux_target_ops): Update.
3085 (linux_process_target::supports_thread_stopped): Define.
3086 (linux_thread_stopped): Turn into ...
3087 (linux_process_target::thread_stopped): ... this.
3088 * linux-low.h (class linux_process_target): Update.
3089 * lynx-low.cc (lynx_target_ops): Update.
3090 * nto-low.cc (nto_target_ops): Update.
3091 * win32-low.cc (win32_target_ops): Update.
3092
770d8f6a
TBA
30932020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3094
3095 Turn process_stratum_target's read_pc and write_pc ops into
3096 methods of process_target.
3097
3098 * target.h (struct process_stratum_target): Remove the target ops.
3099 (class process_target): Add the target ops.
3100 * target.cc (process_target::read_pc): Define.
3101 (process_target::write_pc): Define.
3102
3103 Update the derived classes and callers below.
3104
3105 * regcache.cc (regcache_read_pc): Update.
3106 (regcache_write_pc): Update.
3107 * linux-low.cc (linux_target_ops): Update.
3108 (linux_read_pc): Turn into ...
3109 (linux_process_target::read_pc): ... this.
3110 (linux_write_pc): Turn into ...
3111 (linux_process_target::write_pc): ... this.
3112 * linux-low.h (class linux_process_target): Update.
3113 * lynx-low.cc (lynx_target_ops): Update.
3114 * nto-low.cc (nto_target_ops): Update.
3115 * win32-low.cc (win32_target_ops): Update.
3116
290732bf
TBA
31172020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3118
3119 Turn process_stratum_target's supports_tracepoints op into a
3120 method of process_target.
3121
3122 * target.h (struct process_stratum_target): Remove the target op.
3123 (class process_target): Add the target op.
3124 (target_supports_tracepoints): Update the macro.
3125 * target.cc (process_target::supports_tracepoints): Define.
3126
3127 Update the derived classes and callers below.
3128
3129 * linux-low.cc (linux_target_ops): Update.
3130 (linux_supports_tracepoints): Turn into ...
3131 (linux_process_target::supports_tracepoints): ... this.
3132 * linux-low.h (class linux_process_target): Update.
3133 * lynx-low.cc (lynx_target_ops): Update.
3134 * nto-low.cc (nto_target_ops): Update.
3135 * win32-low.cc (win32_target_ops): Update.
3136
0df28b1b
TBA
31372020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3138
3139 Turn process_stratum_target's process_qsupported op into a method
3140 of process_target.
3141
3142 * target.h (struct process_stratum_target): Remove the target op.
3143 (class process_target): Add the target op.
3144 (target_process_qsupported): Update the macro.
3145 * target.cc (process_target::process_qsupported): Define.
3146
3147 Update the derived classes and callers below.
3148
3149 * linux-low.cc (linux_target_ops): Update.
3150 (linux_process_qsupported): Turn into ...
3151 (linux_process_target::process_qsupported): ... this.
3152 * linux-low.h (class linux_process_target): Update.
3153 * lynx-low.cc (lynx_target_ops): Update.
3154 * nto-low.cc (nto_target_ops): Update.
3155 * win32-low.cc (win32_target_ops): Update.
3156
9da41fda
TBA
31572020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3158
3159 Turn process_stratum_target's read_loadmap op into a method of
3160 process_target.
3161
3162 * target.h (struct process_stratum_target): Remove the target op.
3163 (class process_target): Add the target op. Also add
3164 'supports_read_loadmap'.
3165 * target.cc (process_target::read_loadmap): Define.
3166 (process_target::supports_read_loadmap): Define.
3167
3168 Update the derived classes and callers below.
3169
3170 * server.cc (handle_qxfer_fdpic): Update.
3171 (handle_query): Update.
3172 * linux-low.cc (linux_target_ops): Update.
3173 (linux_process_target::supports_read_loadmap): Define.
3174 (linux_read_loadmap): Turn into ...
3175 (linux_process_target::read_loadmap): ... this.
3176 * linux-low.h (class linux_process_target): Update.
3177 * lynx-low.cc (lynx_target_ops): Update.
3178 * nto-low.cc (nto_target_ops): Update.
3179 * win32-low.cc (win32_target_ops): Update.
3180
95a45fc1
TBA
31812020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3182
3183 Turn process_stratum_target's core_of_thread op into a method of
3184 process_target.
3185
3186 * target.h (struct process_stratum_target): Remove the target op.
3187 (class process_target): Add the target op.
3188 (target_core_of_thread): Update the macro.
3189 * target.cc (process_target::core_of_thread): Define.
3190
3191 Update the derived classes and callers below.
3192
3193 * linux-low.cc (linux_target_ops): Update.
3194 (linux_process_target::core_of_thread): Define.
3195 * linux-low.h (class linux_process_target): Update.
3196 * lynx-low.cc (lynx_target_ops): Update.
3197 * nto-low.cc (nto_target_ops): Update.
3198 * win32-low.cc (win32_target_ops): Update.
3199
55cf3021
TBA
32002020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3201
3202 Turn process_stratum_target's handle_monitor_command op into a
3203 method of process_target.
3204
3205 * target.h (struct process_stratum_target): Remove the target op.
3206 (class process_target): Add the target op.
3207 (target_handle_monitor_command): Update the macro.
3208 * target.cc (process_target::handle_monitor_command): Define.
3209
3210 Update the derived classes and callers below.
3211
3212 * server.cc (handle_query): Update.
3213 * linux-low.cc (linux_target_ops): Update.
3214 (linux_process_target::handle_monitor_command): Define.
3215 * linux-low.h (class linux_process_target): Update.
3216 * lynx-low.cc (lynx_target_ops): Update.
3217 * nto-low.cc (nto_target_ops): Update.
3218 * win32-low.cc (win32_target_ops): Update.
3219
fb00dfce
TBA
32202020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3221
3222 Turn process_stratum_target's handle_new_gdb_connection op into a
3223 method of process_target.
3224
3225 * target.h (struct process_stratum_target): Remove the target op.
3226 (class process_target): Add the target op.
3227 (target_handle_new_gdb_connection): Update the macro.
3228 * target.cc (process_target::handle_new_gdb_connection): Define.
3229
3230 Update the derived classes and callers below.
3231
3232 * linux-low.cc (linux_target_ops): Update.
3233 (linux_handle_new_gdb_connection): Turn into ...
3234 (linux_process_target::handle_new_gdb_connection): ... this.
3235 * linux-low.h (class linux_process_target): Update.
3236 * lynx-low.cc (lynx_target_ops): Update.
3237 * nto-low.cc (nto_target_ops): Update.
3238 * win32-low.cc (win32_target_ops): Update.
3239
9690a72a
TBA
32402020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3241
3242 Turn process_stratum_target's supports_fork_events,
3243 supports_vfork_events, and supports_exec_events ops into methods
3244 of process_target.
3245
3246 * target.h (struct process_stratum_target): Remove the target ops.
3247 (class process_target): Add the target ops.
3248 (target_supports_fork_events): Update the macro.
3249 (target_supports_vfork_events): Update the macro.
3250 (target_supports_exec_events): Update the macro.
3251 * target.cc (process_target::supports_fork_events): Define.
3252 (process_target::supports_vfork_events): Define.
3253 (process_target::supports_exec_events): Define.
3254
3255 Update the derived classes and callers below.
3256
3257 * linux-low.cc (linux_target_ops): Update.
3258 (linux_supports_fork_events): Turn into ...
3259 (linux_process_target::supports_fork_events): ... this.
3260 (linux_supports_vfork_events): Turn into ...
3261 (linux_process_target::supports_vfork_events): ... this.
3262 (linux_supports_exec_events): Turn into ...
3263 (linux_process_target::supports_exec_events): ... this.
3264 * linux-low.h (class linux_process_target): Update.
3265 * lynx-low.cc (lynx_target_ops): Update.
3266 * nto-low.cc (nto_target_ops): Update.
3267 * win32-low.cc (win32_target_ops): Update.
3268
652aef77
TBA
32692020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3270
3271 Turn process_stratum_target's supports_multi_process op into a
3272 method of process_target.
3273
3274 * target.h (struct process_stratum_target): Remove the target op.
3275 (class process_target): Add the target op.
3276 * target.cc (process_target::supports_multi_process): Define.
3277 (target_supports_multi_process): Update.
3278
3279 Update the derived classes and callers below.
3280
3281 * linux-low.cc (linux_target_ops): Update.
3282 (linux_supports_multi_process): Turn into ...
3283 (linux_process_target::supports_multi_process): ... this.
3284 * linux-low.h (class linux_process_target): Update.
3285 * lynx-low.cc (lynx_target_ops): Update.
3286 * nto-low.cc (nto_target_ops): Update.
3287 * win32-low.cc (win32_target_ops): Update.
3288
0dc587d4
TBA
32892020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3290
3291 Turn process_stratum_target's supports_non_stop, async, and
3292 start_non_stop ops into methods of process_target.
3293
3294 * target.h (struct process_stratum_target): Remove the target ops.
3295 (class process_target): Add the target ops.
3296 (target_supports_non_stop): Update the macro.
3297 (target_async): Update the macro.
3298 (start_non_stop): Remove declaration.
3299 * target.cc (process_target::supports_non_stop): Define.
3300 (process_target::async): Define.
3301 (process_target::start_non_stop): Define.
3302 (start_non_stop): Remove.
3303
3304 Update the derived classes and callers below.
3305
3306 * server.cc (handle_qxfer_siginfo): Update.
3307 (handle_query): Update.
3308 * linux-low.cc (linux_target_ops): Update.
3309 (linux_supports_non_stop): Turn into ...
3310 (linux_process_target::supports_non_stop): ... this.
3311 (linux_async): Turn into ...
3312 (linux_process_target::async): ... this.
3313 (linux_start_non_stop): Turn into ...
3314 (linux_process_target::start_non_stop): ... this.
3315 * linux-low.h (class linux_process_target): Update.
3316 * lynx-low.cc (lynx_target_ops): Update.
3317 * nto-low.cc (nto_target_ops): Update.
3318 (nto_supports_non_stop): Remove; rely on the default behavior
3319 instead.
3320 * win32-low.cc (win32_target_ops): Update.
3321
d7abedf7
TBA
33222020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3323
3324 Turn process_stratum_target's qxfer_siginfo op into a method of
3325 process_target.
3326
3327 * target.h (struct process_stratum_target): Remove the target op.
3328 (class process_target): Add the target op. Also add
3329 'supports_qxfer_siginfo'.
3330 * target.cc (process_target::qxfer_siginfo): Define.
3331 (process_target::supports_qxfer_siginfo): Define.
3332
3333 Update the derived classes and callers below.
3334
3335 * server.cc (handle_qxfer_siginfo): Update.
3336 (handle_query): Update.
3337 * linux-low.cc (linux_target_ops): Update.
3338 (linux_process_target::supports_qxfer_siginfo): Define.
3339 (linux_xfer_siginfo): Turn into ...
3340 (linux_process_target::qxfer_siginfo): ... this.
3341 * linux-low.h (class linux_process_target): Update.
3342 * lynx-low.cc (lynx_target_ops): Update.
3343 * nto-low.cc (nto_target_ops): Update.
3344 * win32-low.cc (win32_target_ops): Update.
3345
2d0795ee
TBA
33462020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3347
3348 Turn process_stratum_target's qxfer_osdata op into a method of
3349 process_target.
3350
3351 * target.h (struct process_stratum_target): Remove the target op.
3352 (class process_target): Add the target op. Also add
3353 'supports_qxfer_osdata'.
3354 * target.cc (process_target::qxfer_osdata): Define.
3355 (process_target::supports_qxfer_osdata): Define.
3356
3357 Update the derived classes and callers below.
3358
3359 * server.cc (handle_qxfer_osdata): Update.
3360 (handle_query): Update.
3361 * linux-low.cc (linux_target_ops): Update.
3362 (linux_process_target::supports_qxfer_osdata): Define.
3363 (linux_qxfer_osdata): Turn into ...
3364 (linux_process_target::qxfer_osdata): ... this.
3365 * linux-low.h (class linux_process_target): Update.
3366 * lynx-low.cc (lynx_target_ops): Update.
3367 * nto-low.cc (nto_target_ops): Update.
3368 * win32-low.cc (win32_target_ops): Update.
3369
ea06bbaa
TBA
33702020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3371
3372 Turn process_stratum_target's hostio_last_error op into a
3373 method of process_target.
3374
3375 * target.h (struct process_stratum_target): Remove the target op.
3376 (class process_target): Add the target op.
3377 * target.cc: Add "hostio.h" to includes.
3378 (process_target::hostio_last_error): Define.
3379
3380 Update the derived classes and callers below.
3381
3382 * hostio.cc (hostio_error): Update.
3383 * linux-low.cc: Remove "hostio.h" from includes.
3384 (linux_target_ops): Update.
3385 * lynx-low.cc (lynx_target_ops): Update.
3386 * nto-low.cc (nto_target_ops): Update.
3387 * win32-low.h (class win32_process_target): Update.
3388 * win32-low.cc (win32_target_ops): Update.
3389 (wince_hostio_last_error): Turn into ...
3390 (win32_process_target::hostio_last_error): ... this.
3391
6e3fd7e9
TBA
33922020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3393
3394 Turn process_stratum_target's get_tls_address op into a method of
3395 process_target.
3396
3397 * target.h (struct process_stratum_target): Remove the target op.
3398 (class process_target): Add the target op. Also add
3399 'supports_get_tls_address'.
3400 * target.cc (process_target::get_tls_address): Define.
3401 (process_target::supports_get_tls_address): Define.
3402
3403 Update the derived classes and callers below.
3404
3405 * server.cc (handle_query): Update.
3406 * linux-low.cc (linux_target_ops): Update.
3407 (linux_process_target::supports_get_tls_address): Define.
3408 (linux_process_target::get_tls_address): Define.
3409 * linux-low.h (class linux_process_target): Update.
3410 * lynx-low.cc (lynx_target_ops): Update.
3411 * nto-low.cc (nto_target_ops): Update.
3412 * win32-low.cc (win32_target_ops): Update.
3413
5203ae1e
TBA
34142020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3415
3416 Turn process_stratum_target's read_offsets op into a method of
3417 process_target.
3418
3419 * target.h (struct process_stratum_target): Remove the target op.
3420 (class process_target): Add the target op. Also add
3421 'supports_read_offsets'.
3422 * target.cc (process_target::read_offsets): Define.
3423 (process_target::supports_read_offsets): Define.
3424
3425 Update the derived classes and callers below.
3426
3427 * server.cc (handle_query): Update.
3428 * linux-low.cc (SUPPORTS_READ_OFFSETS): New #define directive.
3429 (linux_target_ops): Update.
3430 (linux_process_target::supports_read_offsets): Define.
3431 (linux_read_offsets): Turn into ...
3432 (linux_process_target::read_offsets): ... this.
3433 * linux-low.h (class linux_process_target): Update.
3434 * lynx-low.cc (lynx_target_ops): Update.
3435 * nto-low.cc (nto_target_ops): Update.
3436 * win32-low.cc (win32_target_ops): Update.
3437
6eeb5c55
TBA
34382020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3439
3440 Turn process_stratum_target's stopped_by_watchpoint and
3441 stopped_data_address ops into methods of process_target.
3442
3443 * target.h (struct process_stratum_target): Remove the target ops.
3444 (class process_target): Add the target ops.
3445 * target.cc (process_target::stopped_by_watchpoint): Define.
3446 (process_target::stopped_data_address): Define.
3447
3448 Update the derived classes and callers below.
3449
3450 * remote-utils.cc (prepare_resume_reply): Update.
3451 * linux-low.cc (linux_target_ops): Update.
3452 (linux_stopped_by_watchpoint): Turn into ...
3453 (linux_process_target::stopped_by_watchpoint): ... this.
3454 (linux_stopped_data_address): Turn into ...
3455 (linux_process_target::stopped_data_address): ... this.
3456 * linux-low.h (class linux_process_target): Update.
3457 * lynx-low.cc (lynx_target_ops): Update.
3458 * nto-low.cc (nto_target_ops): Update.
3459 (nto_stopped_by_watchpoint): Turn into ...
3460 (nto_process_target::stopped_by_watchpoint): ... this.
3461 (nto_stopped_data_address): Turn into ...
3462 (nto_process_target::stopped_data_address): ... this.
3463 * nto-low.h (class nto_process_target): Update.
3464 * win32-low.cc (win32_target_ops): Update.
3465 (win32_stopped_by_watchpoint): Turn into ...
3466 (win32_process_target::stopped_by_watchpoint): ... this.
3467 (win32_stopped_data_address): Turn into ...
3468 (win32_process_target::stopped_data_address): ... this.
3469 * win32-low.h (class win32_process_target): Update.
3470
22aa6223
TBA
34712020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3472
3473 Turn process_stratum_target's supports_hardware_single_step op into
3474 a method of process_target.
3475
3476 * target.h (struct process_stratum_target): Remove the target op.
3477 (class process_target): Add the target op.
3478 (target_supports_hardware_single_step): Update the macro.
3479 (target_can_do_hardware_single_step): Remove declaration.
3480 * target.cc (process_target::supports_hardware_single_step): Define.
3481 (target_can_do_hardware_single_step): Remove.
3482
3483 Update the derived classes and callers below.
3484
3485 * linux-low.h (class linux_process_target): Update.
3486 * linux-low.cc (linux_target_ops): Update.
3487 (linux_supports_hardware_single_step): Turn into ...
3488 (linux_process_target::supports_hardware_single_step): ... this.
3489 * lynx-low.h (class lynx_process_target): Update.
3490 * lynx-low.cc (lynx_target_ops): Update.
3491 (lynx_process_target::supports_hardware_single_step): Define.
3492 * nto-low.h (class nto_process_target): Update.
3493 * nto-low.cc (nto_target_ops): Update.
3494 (nto_process_target::supports_hardware_single_step): Define.
3495 * win32-low.h (class win32_process_target): Update.
3496 * win32-low.cc (win32_target_ops): Update.
3497 (win32_process_target::supports_hardware_single_step): Define.
3498
93fe88b2
TBA
34992020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3500
3501 Turn process_stratum_target's {supports_}stopped_by_hw_breakpoint
3502 ops into methods of process_target.
3503
3504 * target.h (struct process_stratum_target): Remove the target ops.
3505 (class process_target): Add the target ops.
3506 (target_stopped_by_hw_breakpoint): Update the macro.
3507 (target_supports_stopped_by_hw_breakpoint): Update the macro.
3508 * target.cc (process_target::stopped_by_hw_breakpoint): Define.
3509 (process_target::supports_stopped_by_hw_breakpoint): Define.
3510
3511 Update the derived classes and callers below.
3512
3513 * linux-low.cc (linux_target_ops): Update.
3514 (linux_stopped_by_hw_breakpoint): Turn into ...
3515 (linux_process_target::stopped_by_hw_breakpoint): ... this.
3516 (linux_supports_stopped_by_hw_breakpoint): Turn into ...
3517 (linux_process_target::supports_stopped_by_hw_breakpoint): ... this.
3518 * linux-low.h (class linux_process_target): Update.
3519 * lynx-low.cc (lynx_target_ops): Update.
3520 * nto-low.cc (nto_target_ops): Update.
3521 * win32-low.cc (win32_target_ops): Update.
3522
84320c4e
TBA
35232020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3524
3525 Turn process_stratum_target's {supports_}stopped_by_sw_breakpoint
3526 ops into methods of process_target.
3527
3528 * target.h (struct process_stratum_target): Remove the target ops.
3529 (class process_target): Add the target ops.
3530 (target_stopped_by_sw_breakpoint): Update the macro.
3531 (target_supports_stopped_by_sw_breakpoint): Update the macro.
3532 * target.cc (process_target::stopped_by_sw_breakpoint): Define.
3533 (process_target::supports_stopped_by_sw_breakpoint): Define.
3534
3535 Update the derived classes and callers below.
3536
3537 * linux-low.cc (linux_target_ops): Update.
3538 (linux_stopped_by_sw_breakpoint): Turn into ...
3539 (linux_process_target::stopped_by_sw_breakpoint): ... this.
3540 (linux_supports_stopped_by_sw_breakpoint): Turn into ...
3541 (linux_process_target::supports_stopped_by_sw_breakpoint): ... this.
3542 * linux-low.h (class linux_process_target): Update.
3543 * lynx-low.cc (lynx_target_ops): Update.
3544 * nto-low.cc (nto_target_ops): Update.
3545 * win32-low.cc (win32_target_ops): Update.
3546
7e0bde70
TBA
35472020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3548
3549 Turn process_stratum_target's insert_point and remove_point ops
3550 into methods of process_target.
3551
3552 * target.h (struct process_stratum_target): Remove the target ops.
3553 (class process_target): Add the target ops.
3554 * target.cc (process_target::insert_point): Define.
3555 (process_target::remove_point): Define.
3556
3557 Update the derived classes and callers below.
3558
3559 * mem-break.cc (set_raw_breakpoint_at): Update.
3560 (delete_raw_breakpoint): Update.
3561 (uninsert_raw_breakpoint): Update.
3562 (reinsert_raw_breakpoint): Update.
3563 * linux-low.cc (linux_target_ops): Update.
3564 (linux_insert_point): Turn into ...
3565 (linux_process_target::insert_point): ... this.
3566 (linux_remove_point): Turn into ...
3567 (linux_process_target::remove_point): ... this.
3568 * linux-low.h (class linux_process_target): Update.
3569 * lynx-low.cc (lynx_target_ops): Update.
3570 * nto-low.cc (nto_target_ops): Update.
3571 (nto_insert_point): Turn into ...
3572 (nto_process_target::insert_point): ... this.
3573 (nto_remove_point): Turn into ...
3574 (nto_process_target::remove_point): ... this.
3575 * nto-low.h (class nto_process_target): Update.
3576 * win32-low.cc (win32_target_ops): Update.
3577 (win32_insert_point): Turn into ...
3578 (win32_process_target::insert_point): ... this.
3579 (win32_remove_point): Turn into ...
3580 (win32_process_target::remove_point): ... this.
3581 * win32-low.h (class win32_process_target): Update.
3582
a2b2297a
TBA
35832020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3584
3585 Turn process_stratum_target's supports_z_point_type op into a
3586 method of process_target.
3587
3588 * target.h (struct process_stratum_target): Remove the target op.
3589 (class process_target): Add the target op.
3590 * target.cc (process_target::supports_z_point_type): Define.
3591
3592 Update the derived classes and callers below.
3593
3594 * mem-break.cc (z_type_supported): Update.
3595 * linux-low.cc (linux_target_ops): Update.
3596 (linux_supports_z_point_type): Turn into ...
3597 (linux_process_target::supports_z_point_type): ... this.
3598 * linux-low.h (class linux_process_target): Update.
3599 * lynx-low.cc (lynx_target_ops): Update.
3600 * nto-low.cc (nto_target_ops): Update.
3601 (nto_supports_z_point_type): Turn into ...
3602 (nto_process_target::supports_z_point_type): ... this.
3603 * nto-low.h (class nto_process_target): Update.
3604 * win32-low.cc (win32_target_ops): Update.
3605 (win32_supports_z_point_type): Turn into ...
3606 (win32_process_target::supports_z_point_type): ... this.
3607 * win32-low.h (class win32_process_target): Update.
3608
eac215cc
TBA
36092020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3610
3611 Turn process_stratum_target's read_auxv op into a method of
3612 process_target.
3613
3614 * target.h (class process_stratum_target): Remove the target op.
3615 (struct process_target): Add the target op. Also add
3616 'supports_read_auxv'.
3617 * target.cc (process_target::read_auxv): Define.
3618 (process_target::supports_read_auxv): Define.
3619
3620 Update the derived classes and callers below.
3621
3622 * server.cc (handle_qxfer_auxv): Update.
3623 (handle_query): Update.
3624 * linux-low.cc (linux_target_ops): Update.
3625 (linux_process_target::supports_read_auxv): Define.
3626 (linux_read_auxv): Turn into ...
3627 (linux_process_target::read_auxv): ... this.
3628 * linux-low.h (class linux_process_target): Update.
3629 * lynx-low.cc (lynx_target_ops): Update.
3630 * nto-low.cc (nto_target_ops): Update.
3631 (nto_process_target::supports_read_auxv): Define.
3632 (nto_read_auxv): Turn into ...
3633 (nto_process_target::read_auxv): ... this.
3634 * nto-low.h (class nto_process_target): Update.
3635 * win32-low.cc (win32_target_ops): Update.
3636
eb497a2a
TBA
36372020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3638
3639 Turn process_stratum_target's request_interrupt op into a method of
3640 process_target.
3641
3642 * target.h (struct process_stratum_target): Remove the target op.
3643 (class process_target): Add the target op.
3644
3645 Update the derived classes and callers below.
3646
3647 * remote-utils.cc (putpkt_binary_1): Update.
3648 (input_interrupt): Update.
3649 (getpkt): Update.
3650 * server.cc (handle_v_requests): Update.
3651 * linux-low.cc (linux_target_ops): Update.
3652 (linux_request_interrupt): Turn into ...
3653 (linux_process_target::request_interrupt): ... this.
3654 * linux-low.h (class linux_process_target): Update.
3655 * lynx-low.cc (lynx_target_ops): Update.
3656 (lynx_request_interrupt): Turn into ...
3657 (lynx_process_target::request_interrupt): ... this.
3658 * lynx-low.h (class lynx_process_target): Update.
3659 * nto-low.cc (nto_target_ops): Update.
3660 (nto_request_interrupt): Turn into ...
3661 (nto_process_target::request_interrupt): ... this.
3662 * nto-low.h (class nto_process_target): Update.
3663 * win32-low.cc (win32_target_ops): Update.
3664 (win32_request_interrupt): Turn into ...
3665 (win32_process_target::request_interrupt): ... this.
3666 * win32-low.h (class win32_process_target): Update.
3667
2a31c7aa
TBA
36682020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3669
3670 Turn process_stratum_target's look_up_symbols op into a method of
3671 process_target.
3672
3673 * target.h (struct process_stratum_target): Remove the target op.
3674 (class process_target): Add the target op.
3675 * target.cc (process_target::look_up_symbols): Define.
3676
3677 Update the derived classes and callers below.
3678
3679 * server.cc (handle_query): Update.
3680 * linux-low.cc (linux_target_ops): Update.
3681 (linux_look_up_symbols): Turn into ...
3682 (linux_process_target::look_up_symbols): ... this.
3683 * linux-low.h (class linux_process_target): Update.
3684 * lynx-low.cc (lynx_target_ops): Update.
3685 * nto-low.cc (nto_target_ops): Update.
3686 * win32-low.cc (win32_target_ops): Update.
3687
e2558df3
TBA
36882020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3689
3690 Turn process_stratum_target's read_memory and write_memory
3691 ops into methods of process_target.
3692
3693 * target.h (struct process_stratum_target): Remove the target ops.
3694 (class process_target): Add the target ops.
3695
3696 Update the derived classes and callers below.
3697
3698 * linux-aarch32-low.cc (arm_breakpoint_at): Update.
3699 * linux-aarch64-low.cc (aarch64_breakpoint_at): Update.
3700 * linux-arm-low.cc (arm_sigreturn_next_pc): Update.
3701 (arm_get_syscall_trapinfo): Update.
3702 * linux-cris-low.cc (cris_breakpoint_at): Update.
3703 * linux-crisv32-low.cc (cris_breakpoint_at): Update.
3704 * linux-m32r-low.cc (m32r_breakpoint_at): Update.
3705 * linux-mips-low.cc (mips_breakpoint_at): Update.
3706 * linux-nios2-low.cc (nios2_breakpoint_at): Update.
3707 * linux-ppc-low.cc (ppc_breakpoint_at): Update.
3708 * linux-sh-low.cc (sh_breakpoint_at): Update.
3709 * linux-sparc-low.cc (sparc_fill_gregset_to_stack): Update.
3710 (sparc_store_gregset_from_stack): Update.
3711 (sparc_breakpoint_at): Update.
3712 * linux-tic6x-low.cc (tic6x_breakpoint_at): Update.
3713 * linux-tile-low.cc (tile_breakpoint_at): Update.
3714 * linux-x86-low.cc (x86_breakpoint_at): Update.
3715 * linux-xtensa-low.cc (xtensa_breakpoint_at): Update.
3716 * mem-brea.cc (insert_memory_breakpoint): Update.
3717 (validate_inserted_breakpoint): Update.
3718 * target.cc (read_inferior_memory): Update.
3719 (target_write_memory): Update.
3720 * linux-low.cc (linux_target_ops): Update.
3721 (linux_read_memory): Make a wrapper around the read_memory target
3722 op call.
3723 (linux_process_target::read_memory): Rename from linux_read_memory.
3724 (linux_write_memory): Turn into ...
3725 (linux_process_target::write_memory): ... this.
3726 * linux-low.h (class linux_process_target): Update.
3727 * lynx-low.cc (lynx_target_ops): Update.
3728 (lynx_read_memory): Turn into ...
3729 (lynx_process_target::read_memory): ... this.
3730 (lynx_write_memory): Turn into ...
3731 (lynx_process_target::write_memory): ... this.
3732 * lynx-low.h (class lynx_process_target): Update.
3733 * nto-low.cc (nto_target_ops): Update.
3734 (nto_read_memory): Turn into ...
3735 (nto_process_target::read_memory): ... this.
3736 (nto_write_memory): Turn into ...
3737 (nto_process_target::write_memory): ... this.
3738 * nto-low.h (class nto_process_target): Update.
3739 * win32-low.cc (win32_target_ops): Update.
3740 (win32_read_inferior_memory): Turn into ...
3741 (win32_process_target::read_memory): ... this.
3742 (win32_write_inferior_memory): Turn into ...
3743 (win32_process_target::write_memory): ... this.
3744 * win32-low.h (class win32_process_target): Update.
3745
79b44087
TBA
37462020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3747
3748 Turn process_stratum_target's prepare_to_access_memory and
3749 done_accessing_memory ops into methods of process_target.
3750
3751 * target.h (struct process_stratum_target): Remove the target ops.
3752 (class process_target): Add the target ops.
3753 * target.cc (process_target::prepare_to_access_memory): Define.
3754 (process_target::done_accessing_memory): Define.
3755 (prepare_to_access_memory): Update.
3756 (done_accessing_memory): Update.
3757
3758 Update the derived classes and callers below.
3759
3760 * linux-low.cc (linux_target_ops): Update.
3761 (linux_prepare_to_access_memory): Turn into ...
3762 (linux_process_target::prepare_to_access_memory): ... this.
3763 (linux_done_accessing_memory): Turn into ...
3764 (linux_process_target::done_accessing_memory): ... this.
3765 * linux-low.h (class linux_process_target): Update.
3766 * lynx-low.cc (lynx_target_ops): Update.
3767 * nto-low.cc (nto_target_ops): Update.
3768 * win32-low.cc (win32_target_ops): Update.
3769
a5a4d4cd
TBA
37702020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3771
3772 Turn process_stratum_target's fetch_registers and store_registers
3773 ops into methods of process_target.
3774
3775 * target.h (struct process_stratum_target): Remove the target ops.
3776 (class process_target): Add the target ops.
3777 (fetch_inferior_registers): Update the macro.
3778 (store_inferior_registers): Update the macro.
3779
3780 Update the derived classes and callers below.
3781
3782 * linux-low.cc (linux_target_ops): Update.
3783 (linux_fetch_registers): Turn into ...
3784 (linux_process_target::fetch_registers): ... this.
3785 (linux_store_registers): Turn into ...
3786 (linux_process_target::store_registers): ... this.
3787 * linux-low.h (class linux_process_target): Update.
3788 * lynx-low.cc (lynx_target_ops): Update.
3789 (lynx_fetch_registers): Turn into ...
3790 (lynx_process_target::fetch_registers): ... this.
3791 (lynx_store_registers): Turn into ...
3792 (lynx_process_target::store_registers): ... this.
3793 * lynx-low.h (class lynx_process_target): Update.
3794 * nto-low.cc (nto_target_ops): Update.
3795 (nto_fetch_registers): Turn into ...
3796 (nto_process_target::fetch_registers): ... this.
3797 (nto_store_registers): Turn into ...
3798 (nto_process_target::store_registers): ... this.
3799 * nto-low.h (class nto_process_target): Update.
3800 * win32-low.cc (win32_target_ops): Update.
3801 (win32_fetch_inferior_registers): Turn into ...
3802 (win32_process_target::fetch_registers): ... this.
3803 (win32_store_inferior_registers): Turn into ...
3804 (win32_process_target::store_registers): ... this.
3805 * win32-low.h (class win32_process_target): Update.
3806
6532e7e3
TBA
38072020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3808
3809 Turn process_stratum_target's wait op into a method of
3810 process_target.
3811
3812 * target.h (struct process_stratum_target): Remove the target op.
3813 (class process_target): Add the target op.
3814
3815 Update the derived classes and callers below.
3816
3817 * target.cc (target_wait): Update.
3818 * linux-low.cc (linux_target_ops): Update.
3819 (linux_wait): Turn into ...
3820 (linux_process_target::wait): ... this.
3821 * linux-low.h (class linux_process_target): Update.
3822 * lynx-low.cc (lynx_target_ops): Update.
3823 (lynx_wait): Turn into ...
3824 (lynx_process_target::wait): ... this.
3825 * lynx-low.h (class lynx_process_target): Update.
3826 * nto-low.cc (nto_target_ops): Update.
3827 (nto_wait): Turn into ...
3828 (nto_process_target::wait): ... this.
3829 * nto-low.h (class nto_process_target): Update.
3830 * win32-low.cc (win32_target_ops): Update.
3831 (win32_wait): Turn into ...
3832 (win32_process_target::wait): ... this.
3833 (do_initial_child_stuff): Update.
3834 * win32-low.h (class win32_process_target): Update.
3835
0e4d7e35
TBA
38362020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3837
3838 Turn process_stratum_target's resume op into a method of
3839 process_target.
3840
3841 * target.h (struct process_stratum_target): Remove the target op.
3842 (class process_target): Add the target op.
3843
3844 Update the derived classes and callers below.
3845
3846 * server.cc (resume): Update.
3847 * target.cc (target_stop_and_wait): Update.
3848 (target_continue_no_signal): Update.
3849 (target_continue): Update.
3850 * linux-low.cc (linux_target_ops): Update.
3851 (linux_resume): Turn into ...
3852 (linux_process_target::resume): ... this.
3853 * linux-low.h (class linux_process_target): Update.
3854 * lynx-low.cc (lynx_target_ops): Update.
3855 (lynx_resume): Turn into ...
3856 (lynx_process_target::resume): ... this.
3857 * lynx-low.h (class lynx_process_target): Update.
3858 * nto-low.cc (nto_target_ops): Update.
3859 (nto_resume): Turn into ...
3860 (nto_process_target::resume): ... this.
3861 * nto-low.h (class nto_process_target): Update.
3862 * win32-low.cc (win32_target_ops): Update.
3863 (win32_resume): Turn into ...
3864 (win32_process_target::resume): ... this.
3865 (win32_process_target::detach): Update.
3866 (do_initial_child_stuff): Update.
3867 * win32-low.h (class win32_process_target): Update.
3868
13d3d99b
TBA
38692020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3870
3871 Turn process_stratum_target's thread_alive 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 (mythread_alive): Update the macro.
3877
3878 Update the derived classes and callers below.
3879
3880 * linux-low.cc (linux_target_ops): Update.
3881 (linux_thread_alive): Turn into ...
3882 (linux_process_target::thread_alive): ... this.
3883 (wait_for_sigstop): Update.
3884 * linux-low.h (class linux_process_target): Update.
3885 * lynx-low.cc (lynx_target_ops): Update.
3886 (lynx_thread_alive): Turn into ...
3887 (lynx_process_target::thread_alive): ... this.
3888 * lynx-low.h (class lynx_process_target): Update.
3889 * nto-low.cc (nto_target_ops): Update.
3890 (nto_thread_alive): Turn into ...
3891 (nto_process_target::thread_alive): ... this.
3892 * nto-low.h (class nto_process_target): Update.
3893 * win32-low.cc (win32_target_ops): Update.
3894 (win32_thread_alive): Turn into ...
3895 (win32_process_target::thread_alive): ... this.
3896 * win32-low.h (class win32_process_target): Update.
3897
95a49a39
TBA
38982020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3899
3900 Turn process_stratum_target's join op into a method of
3901 process_target.
3902
3903 * target.h (struct process_stratum_target): Remove the target op.
3904 (class process_target): Add the target op.
3905 (join_inferior): Update the macro.
3906
3907 Update the derived classes and callers below.
3908
3909 * linux-low.cc (linux_target_ops): Update.
3910 (linux_join): Turn into ...
3911 (linux_process_target::join): ... this.
3912 * linux-low.h (class linux_process_target): Update.
3913 * lynx-low.cc (lynx_target_ops): Update.
3914 (lynx_join): Turn into ...
3915 (lynx_process_target::join): ... this.
3916 * lynx-low.h (class lynx_process_target): Update.
3917 * nto-low.cc (nto_target_ops): Update.
3918 (nto_process_target::join): Define.
3919 * nto-low.h (class nto_process_target): Update.
3920 * win32-low.cc (win32_target_ops): Update.
3921 (win32_join): Turn into ...
3922 (win32_process_target::join): ... this.
3923 * win32-low.h (class win32_process_target): Update.
3924
8adb37b9
TBA
39252020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3926
3927 Turn process_stratum_target's mourn op into a method of
3928 process_target.
3929
3930 * target.h (struct process_stratum_target): Remove the target op.
3931 (class process_target): Add the target op.
3932
3933 Update the derived classes and callers below.
3934
3935 * target.cc (target_mourn_inferior): Update.
3936 * linux-low.cc (linux_target_ops): Update.
3937 (linux_mourn): Turn into ...
3938 (linux_process_target::mourn): ... this.
3939 (handle_extended_wait): Update.
3940 (linux_process_target::kill): Update.
3941 (linux_process_target::detach): Update.
3942 * linux-low.h (class linux_process_target): Update.
3943 * lynx-low.cc (lynx_target_ops): Update.
3944 (lynx_mourn): Turn into ...
3945 (lynx_process_target::mourn): ... this.
3946 * lynx-low.h (class lynx_process_target): Update.
3947 * nto-low.cc (nto_target_ops): Update.
3948 (nto_mourn): Turn into ...
3949 (nto_process_target::mourn): ... this.
3950 * nto-low.h (class nto_process_target): Update.
3951 * win32-low.cc (win32_target_ops): Update.
3952 (win32_mourn): Turn into ...
3953 (win32_process_target::mourn): ... this.
3954 * win32-low.h (class win32_process_target): Update.
3955
9061c9cf
TBA
39562020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3957
3958 Turn process_stratum_target's detach op into a method of
3959 process_target.
3960
3961 * target.h (struct process_stratum_target): Remove the target op.
3962 (class process_target): Add the target op.
3963 (detach_inferior): Update the macro.
3964
3965 Update the derived classes and callers below.
3966
3967 * linux-low.cc (linux_target_ops): Update.
3968 (linux_detach): Turn into ...
3969 (linux_process_target::detach): ... this.
3970 * linux-low.h (class linux_process_target): Update.
3971 * lynx-low.cc (lynx_target_ops): Update.
3972 (lynx_detach): Turn into ...
3973 (lynx_process_target::detach): ... this.
3974 * lynx-low.h (class lynx_process_target): Update.
3975 * nto-low.cc (nto_target_ops): Update.
3976 (nto_detach): Turn into ...
3977 (nto_process_target::detach): ... this.
3978 * nto-low.h (class nto_process_target): Update.
3979 * win32-low.cc (win32_target_ops): Update.
3980 (win32_detach): Turn into ...
3981 (win32_process_target::detach): ... this.
3982 * win32-low.h (class win32_process_target): Update.
3983
c6885a57
TBA
39842020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3985
3986 Turn process_stratum_target's kill op into a method of
3987 process_target.
3988
3989 * target.h (struct process_stratum_target): Remove the target op.
3990 (class process_target): Add the target op.
3991
3992 Update the derived classes and callers below.
3993
3994 * target.cc (kill_inferior): Update.
3995 * linux-low.cc (linux_target_ops): Update.
3996 (linux_kill): Turn into ...
3997 (linux_process_target::kill): ... this.
3998 * linux-low.h (class linux_process_target): Update.
3999 * lynx-low.cc (lynx_target_ops): Update.
4000 (lynx_kill): Turn into ...
4001 (lynx_process_target::kill): ... this.
4002 * lynx-low.h (class lynx_process_target): Update.
4003 * nto-low.cc (nto_target_ops): Update.
4004 (nto_kill): Turn into ...
4005 (nto_process_target::kill): ... this.
4006 * nto-low.h (class nto_process_target): Update.
4007 * win32-low.cc (win32_target_ops): Update.
4008 (win32_kill): Turn into ...
4009 (win32_process_target::kill): ... this.
4010 * win32-low.h (class win32_process_target): Update.
4011
ef03dad8
TBA
40122020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4013
4014 Turn process_stratum_target's attach op into a method of
4015 process_target.
4016
4017 * target.h (struct process_stratum_target): Remove the target op.
4018 (class process_target): Add the target op.
4019 (myattach): Update the macro.
4020
4021 Update the derived classes and callers below.
4022
4023 * linux-low.cc (linux_target_ops): Update.
4024 (linux_attach): Turn into ...
4025 (linux_process_target::attach): ... this.
4026 * linux-low.h (class linux_process_target): Update.
4027 * lynx-low.cc (lynx_target_ops): Update.
4028 (lynx_attach): Turn into ...
4029 (lynx_process_target::attach): ... this.
4030 * lynx-low.h (class lynx_process_target): Update.
4031 * nto-low.cc (nto_target_ops): Update.
4032 (nto_attach): Turn into ...
4033 (nto_process_target::attach): ... this.
4034 * nto-low.h (class nto_process_target): Update.
4035 * win32-low.cc (win32_target_ops): Update.
4036 (win32_attach): Turn into ...
4037 (win32_process_target::attach): ... this.
4038 * win32-low.h (class win32_process_target): Update.
4039
6dee9afb
TBA
40402020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4041
4042 Turn process_stratum_target's post_create_inferior op into a method
4043 of process_target.
4044
4045 * target.h (struct process_stratum_target): Remove the target op.
4046 (class process_target): Add the target op.
4047 (target_post_create_inferior): Update the macro.
4048 * target.cc (process_target::post_create_inferior): Define.
4049
4050 Update the derived classes and callers below.
4051
4052 * linux-low.cc (linux_target_ops): Update.
4053 (linux_post_create_inferior): Turn into ...
4054 (linux_process_target::post_create_inferior): ... this.
4055 * linux-low.h (class linux_process_target): Update.
4056 * lynx-low.cc (lynx_target_ops): Update.
4057 * nto-low.cc (nto_target_ops): Update.
4058 * win32-low.cc (win32_target_ops): Update.
4059
15295543
TBA
40602020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4061
4062 Turn process_stratum_target's create_inferior op into a method of
4063 process_target.
4064
4065 * target.h (struct process_stratum_target): Remove the target op.
4066 (class process_target): Add the target op.
4067 (create_inferior): Rename the macro to ...
4068 (target_create_inferior): ... this.
4069
4070 Update the derived classes and callers below.
4071
4072 * server.cc (handle_v_run): Update.
4073 (captured_main): Update.
4074 (process_serial_event): Update.
4075 * linux-low.cc (linux_target_ops): Update.
4076 (linux_create_inferior): Turn into ...
4077 (linux_process_target::create_inferior): ... this.
4078 * linux-low.h (class linux_process_target): Update.
4079 * lynx-low.cc (lynx_target_ops): Update.
4080 (lynx_create_inferior): Turn into ...
4081 (lynx_process_target::create_inferior): ... this.
4082 * lynx-low.h (class lynx_process_target): Update.
4083 * nto-low.cc (nto_target_ops): Update.
4084 (nto_create_inferior): Turn into ...
4085 (nto_process_target::create_inferior): ... this.
4086 * nto-low.h (class nto_process_target): Update.
4087 * win32-low.cc (win32_target_ops): Update.
4088 (win32_create_inferior): Turn into ...
4089 (win32_process_target::create_inferior): ... this.
4090 * win32-low.h (class win32_process_target): Update.
4091
5ef9273d
TBA
40922020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4093
4094 * target.h (class process_target): New class definition.
4095 (struct process_stratum_target) <pt>: New field with type
4096 'process_target*'.
4097 * linux-low.h (class linux_process_target): Define as a derived
4098 class of 'process_target'.
4099 * linux-low.cc (linux_target_ops): Add a linux_process_target*
4100 as the 'pt' field.
4101 * lynx-low.h (class lynx_process_target): Define as a derived
4102 class of 'process_target'.
4103 * lynx-low.cc (lynx_target_ops): Add a lynx_process_target*
4104 as the 'pt' field.
4105 * nto-low.h (class nto_process_target): Define as a derived
4106 class of 'process_target'.
4107 * nto-low.cc (nto_target_ops): Add an nto_process_target*
4108 as the 'pt' field.
4109 * win32-low.h (class win32_process_target): Define as a derived
4110 class of 'process_target'.
4111 * win32-low.cc (win32_target_ops): Add a win32_process_target*
4112 as the 'pt' field.
4113
9f1528a1
AB
41142020-02-19 Andrew Burgess <andrew.burgess@embecosm.com>
4115
4116 * configure: Regenerate.
4117
bf84f706
MR
41182020-02-19 Maciej W. Rozycki <macro@wdc.com>
4119 Andrew Burgess <andrew.burgess@embecosm.com>
4120
4121 * linux-riscv-low.cc: New file.
4122 * Makefile.in (SFILES): Add linux-riscv-low.cc, arch/riscv.c,
4123 and nat/riscv-linux-tdesc.c.
4124 * configure.srv <riscv*-*-linux*> (srv_tgtobj)
4125 (srv_linux_regsets, srv_linux_usrregs, srv_linux_thread_db):
4126 Define.
4127
1a627e7e
TT
41282020-02-14 Tom Tromey <tom@tromey.com>
4129
4130 * acinclude.m4: Don't include acx_configure_dir.m4.
4131 * Makefile.in (LIBIBERTY_BUILDDIR, GNULIB_BUILDDIR): Update.
4132 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): Remove.
4133 (all, install-only, uninstall, clean-info, clean)
4134 (maintainer-clean): Don't recurse.
4135 (subdir_do, all-lib): Remove.
4136 ($(LIBGNU) $(LIBIBERTY) $(GNULIB_H)): Remove rule.
4137 (GNULIB_H): Remove.
4138 (generated_files): Update.
4139 ($(GNULIB_BUILDDIR)/Makefile): Remove rule.
4140 * configure: Rebuild.
4141 * configure.ac: Don't configure gnulib or libiberty.
4142 (GNULIB): Update.
4143
a9b34532
EZ
41442020-02-14 Eli Zaretskii <eliz@gnu.org>
4145
4146 * win32-low.c (create_process): Prepend PROGRAM to ARGS when
4147 preparing the command line for CreateProcess.
4148 (win32_create_inferior): Reflect the program name in debugging
4149 output that shows the process and its command line.
4150
feacfcac
SM
41512020-02-13 Simon Marchi <simon.marchi@efficios.com>
4152
4153 * Makefile.in: Rename source files from .c to .cc.
4154 * %.c: Rename to %.cc.
4155 * configure.ac: Rename server.c to server.cc.
4156 * configure: Re-generate.
4157
06b3c5bd
SM
41582020-02-13 Simon Marchi <simon.marchi@efficios.com>
4159
4160 * Makefile.in: Rename gdbsupport source files from .c to .cc.
4161
052793ad
HD
41622020-02-12 Hannes Domani <ssbssa@yahoo.de>
4163
4164 * win32-low.c (win32_create_inferior): Set signal_pid.
4165
f20e3e82
MR
41662020-02-12 Maciej W. Rozycki <macro@wdc.com>
4167 Pedro Alves <palves@redhat.com>
4168
4169 Skip building gdbserver in a cross-configuration.
4170 * configure.srv: Set $gdbserver_host depending on whether $target
4171 is $host. Use $gdbserver_host instead of $host.
4172
8ddd8e0e
SM
41732020-02-11 Simon Marchi <simon.marchi@efficios.com>
4174
4175 * configure: Re-generate.
4176
898e7f60
SM
41772020-02-11 Simon Marchi <simon.marchi@efficios.com>
4178
4179 * configure: Re-generate.
4180
58df732b
SM
41812020-02-11 Simon Marchi <simon.marchi@efficios.com>
4182
4183 * acinclude.m4: Update warning.m4 path.
4184
7928d571
HD
41852020-02-09 Hannes Domani <ssbssa@yahoo.de>
4186
4187 * win32-low.c (win32_clear_inferiors): Reset siginfo_er.
4188 (handle_exception): Set siginfo_er.
4189 (win32_xfer_siginfo): New function.
4190
919adfe8
TT
41912020-02-07 Tom Tromey <tom@tromey.com>
4192 Pedro Alves <palves@redhat.com>
4193
4194 * README: Update build documentation.
4195 * configure.srv: Set UNSUPPORTED if host is unsupported. Check
4196 host, not target.
4197 * configure.ac: Update paths.
4198 * configure: Rebuild.
4199 * acinclude.m4: Update paths.
4200 * Makefile.in: Update include paths.
4201 (depcomp, INCLUDE_DIR, INCGNU, INCSUPPORT, INCLUDE_CFLAGS)
4202 (SFILES, XML_DIR, n, $(GNULIB_BUILDDIR)/Makefile, config.status)
4203 (version-generated.c, stamp-xml, regdat_sh, arch/%-ipa.o)
4204 (gdbsupport/%-ipa.o, %-ipa.o, arch/%.o, gdbsupport/%.o, %.o)
4205 (%-generated.c): Update paths.
4206 * Move entire directory from ../gdb/gdbserver.
4207
287c844a
MR
42082020-01-29 Maciej W. Rozycki <macro@wdc.com>
4209
4210 * configure.srv <i[34567]86-*-mingw*>: Fix whitespace damage.
4211
548a204f
PFC
42122020-01-29 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4213
4214 * configure.srv (powerpc*-*-linux*): Use srv_tgtobj in second
4215 assignment instead of srv_linux_obj.
4216
a2236a08
HD
42172020-01-28 Hannes Domani <ssbssa@yahoo.de>
4218
4219 * server.c (handle_qxfer_libraries): Write segment-address with
4220 paddress.
4221
bdaed379
HD
42222020-01-24 Hannes Domani <ssbssa@yahoo.de>
4223
4224 * Makefile.in (install-strip): New target.
4225 (install_sh, INSTALL_STRIP_PROGRAM, STRIP): New variables.
4226 * aclocal.m4: Regenerate.
4227 * configure: Regenerate.
4228 * configure.ac: Add AM_PROG_INSTALL_STRIP.
4229
42cd72aa
MR
42302020-01-24 Maciej W. Rozycki <macro@wdc.com>
4231
4232 * Makefile.in (SFILES): Adjust paths to point to real files.
4233 (OBS): Move waitstatus.o to target/waitstatus.o.
4234 (TAGS): Transform paths appropriately.
4235 (%.o): Rename to...
4236 (nat/%.o): ... this pattern rule.
4237 (%.o): Rename to...
4238 (target/%.o): ... this pattern rule.
4239 * configure.srv: Adjust paths throughout to include nat/ prefix
4240 with the revant files.
4241 * configure.ac: Add `nat' and `target' to CONFIG_SRC_SUBDIR.
4242 * configure: Regenerate.
4243
42ba50ec
MR
42442020-01-24 Maciej W. Rozycki <macro@wdc.com>
4245
4246 * Makefile.in (TAGS): Remove config files from the recipe.
4247
05ea2a05
TT
42482020-01-14 Tom Tromey <tom@tromey.com>
4249
4250 * configure: Rebuild.
4251 * configure.ac: Remove any checks that were added to common.m4.
4252 * acinclude.m4: Include lib-ld.m4, lib-prefix.m4, and
4253 lib-link.m4.
4254
01027315
TT
42552020-01-14 Tom Tromey <tom@tromey.com>
4256
4257 * server.h: Include config.h.
4258 * gdbreplay.c: Include config.h.
4259 * configure: Rebuild.
4260 * configure.ac: Don't source common.host.
4261 * acinclude.m4: Update path.
4262 * Makefile.in (INCSUPPORT): New variable.
4263 (INCLUDE_CFLAGS): Add INCSUPPORT.
4264 (SFILES): Update paths.
4265 (version-generated.c): Update path to create-version.sh.
4266 (gdbsupport/%-ipa.o, gdbsupport/%.o): Update paths.
4267
b2ceabe8
TT
42682020-01-14 Tom Tromey <tom@tromey.com>
4269
4270 * configure.ac (LIBS): Use WIN32APILIBS.
4271 (USE_WIN32API): Don't define.
4272 * configure: Rebuild.
4273
25c51f71
TT
42742020-01-14 Tom Tromey <tom@tromey.com>
4275
4276 * configure: Rebuild.
4277
c0bd321d
SM
42782020-01-13 Simon Marchi <simon.marchi@efficios.com>
4279
4280 * Makefile.in (%-generated.c): Remove rule for files from
4281 regformats/i386.
4282
bb564c58
SM
42832020-01-13 Simon Marchi <simon.marchi@efficios.com>
4284
4285 * configure: Re-generate.
4286
6e37c371
SM
42872020-01-13 Simon Marchi <simon.marchi@efficios.com>
4288
4289 * tracepoint.h (IP_AGENT_EXPORT_FUNC) [!IN_PROCESS_AGENT]:
4290 Define to static.
4291 * tracepoint.c (stop_tracing, flush_trace_buffer,
4292 about_to_request_buffer_space, get_trace_state_variable_value,
4293 set_trace_state_variable_value, gdb_collect): Add declaration.
4294
df4a0200
SM
42952020-01-13 Simon Marchi <simon.marchi@efficios.com>
4296
4297 * linux-x86-low.c (x86_linux_regs_info, amd64_emit_eq_goto,
4298 amd64_emit_ne_goto, amd64_emit_lt_goto, amd64_emit_le_goto,
4299 amd64_emit_gt_goto, amd64_emit_ge_goto, amd64_emit_ge_goto,
4300 i386_emit_eq_goto, i386_emit_ne_goto, i386_emit_lt_goto,
4301 i386_emit_le_goto, i386_emit_gt_goto, i386_emit_ge_goto): Make
4302 static.
4303
89e94ec9
SM
43042020-01-13 Simon Marchi <simon.marchi@efficios.com>
4305
4306 * inferiors.c: Include gdbsupport/common-inferior.h.
4307
2552728a
SM
43082020-01-13 Simon Marchi <simon.marchi@efficios.com>
4309
4310 * hostio-errno.c: Include hostio.h.
4311
4025fa09
SM
43122020-01-13 Simon Marchi <simon.marchi@efficios.com>
4313
4314 * Makefile.in (%-generated.c): Make $(regdat_sh) a regular
4315 prerequisite.
4316
c0b0a142
SM
43172020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
4318
4319 * linux-arm-tdesc.c: Include linux-arm-tdesc.h.
4320 * linux-arm-tdesc.h: Include arch/arm.h.
4321
bb1183e2
SM
43222020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
4323
4324 * linux-aarch64-low.c (aarch64_write_goto_address): Make static.
4325
f5df0b5f
SM
43262020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
4327
4328 * linux-aarch32-tdesc.c: Include linux-aarch32-tdesc.h.
4329 * linux-aarch64-tdesc.c: Include linux-aarch64-tdesc.h.
4330
5b6d1e4f
PA
43312020-01-10 Pedro Alves <palves@redhat.com>
4332
4333 * fork-child.c (post_fork_inferior): Pass target down to
4334 startup_inferior.
4335 * inferiors.c (switch_to_thread): Add process_stratum_target
4336 parameter.
4337 * lynx-low.c (lynx_target_ops): Now a process_stratum_target.
4338 * nto-low.c (nto_target_ops): Now a process_stratum_target.
4339 * linux-low.c (linux_target_ops): Now a process_stratum_target.
4340 * remote-utils.c (prepare_resume_reply): Pass the target to
4341 switch_to_thread.
4342 * target.c (the_target): Now a process_stratum_target.
4343 (done_accessing_memory): Pass the target to switch_to_thread.
4344 (set_target_ops): Ajust to use process_stratum_target.
4345 * target.h (struct target_ops): Rename to ...
4346 (struct process_stratum_target): ... this.
4347 (the_target, set_target_ops): Adjust.
4348 (prepare_to_access_memory): Adjust comment.
4349 * win32-low.c (child_xfer_memory): Adjust to use
4350 process_stratum_target.
4351 (win32_target_ops): Now a process_stratum_target.
4352
559e7e50
EZ
43532020-01-06 Eli Zaretskii <eliz@gnu.org>
4354 Pedro Alves <palves@redhat.com>
4355
4356 * win32-low.c (get_child_debug_event): Extract the fatal exception
4357 from the exit status and convert to the equivalent Posix signal
4358 number.
4359 (win32_wait): Allow TARGET_WAITKIND_SIGNALLED status as well.
4360 * Makefile.in (OBS, SFILES): Add gdb_wait.[co].
4361
48189bec
HD
43622020-01-01 Hannes Domani <ssbssa@yahoo.de>
4363
4364 * Makefile.in: Use INSTALL_PROGRAM_ENV.
4365
5dd8bf88
JB
43662020-01-01 Joel Brobecker <brobecker@adacore.com>
4367
4368 * server.c (gdbserver_version): Change copyright year to 2020.
4369 * gdbreplay.c (gdbreplay_version): Likewise.
4370
0ad6b8ee
CB
43712019-12-19 Christian Biesinger <cbiesinger@google.com>
4372
4373 * configure: Regenerate.
4374 * configure.ac: Quote variable arguments of test.
4375
1ee7b812
BE
43762019-12-16 Bernd Edlinger <bernd.edlinger@hotmail.de>
4377
4378 * Makefile.in: Fix build with GNU Make 3.81
4379
d9fa87f4
TT
43802019-12-16 Tom Tromey <tromey@adacore.com>
4381
4382 * server.c (get_exec_file): Constify result.
4383
ab7d13f0
CB
43842019-12-10 Christian Biesinger <cbiesinger@google.com>
4385
4386 * Makefile.in: Add safe-strerror.c to gdbreplay and IPA, and change
4387 UNDO_GNULIB_CFLAGS to undo strerror_r instead of strerror.
4388 * config.in: Regenerate.
4389 * configure: Regenerate.
4390 * configure.ac: Don't check for strerror.
4391 * linux-i386-ipa.c (initialize_fast_tracepoint_trampoline_buffer):
4392 Call safe_strerror instead of strerror.
4393 * server.h (strerror): Remove this now-unnecessary declaration.
4394 * tracepoint.c (init_named_socket): Call safe_strerror instead of
4395 strerror.
4396 (gdb_agent_helper_thread): Likewise.
4397 * utils.c (perror_with_name): Likewise.
4398
4da8c3a8
TT
43992019-11-26 Tom Tromey <tom@tromey.com>
4400
4401 * configure, config.in: Rebuild.
4402
21987b9c
TT
44032019-11-26 Tom Tromey <tom@tromey.com>
4404
4405 * remote-utils.c (block_unblock_async_io): Use gdb_sigmask.
4406 * linux-low.c (linux_wait_for_event_filtered, linux_async): Use
4407 gdb_sigmask.
4408 * configure, config.in: Rebuild.
4409
5e030278
TT
44102019-11-26 Tom Tromey <tom@tromey.com>
4411
4412 * Makefile.in (PTHREAD_CFLAGS, PTHREAD_LIBS): New variables.
4413 (INTERNAL_CFLAGS_BASE): Use PTHREAD_CFLAGS.
4414 (GDBSERVER_LIBS): Use PTHREAD_LIBS.
4415 * acinclude.m4: Include ax_pthread.m4.
4416 * config.in, configure: Rebuild.
4417
6d91ce9a
CB
44182019-11-26 Christian Biesinger <cbiesinger@google.com>
4419
4420 * debug.c (debug_set_output): Call safe_strerror instead of
4421 strerror.
4422 * linux-low.c (attach_proc_task_lwp_callback): Likewise.
4423 (linux_kill_one_lwp): Likewise.
4424 (linux_detach_one_lwp): Likewise.
4425 (linux_wait_for_event_filtered): Likewise.
4426 (store_register): Likewise.
4427 * lynx-low.c (lynx_attach): Likewise.
4428 * mem-break.c (insert_memory_breakpoint): Likewise.
4429 (remove_memory_breakpoint): Likewise.
4430 (delete_fast_tracepoint_jump): Likewise.
4431 (set_fast_tracepoint_jump): Likewise.
4432 (uninsert_fast_tracepoint_jumps_at): Likewise.
4433 (reinsert_fast_tracepoint_jumps_at): Likewise.
4434 * nto-low.c (nto_xfer_memory): Likewise.
4435 (nto_resume): Likewise.
4436
6cdd651f
LM
44372019-11-20 Luis Machado <luis.machado@linaro.org>
4438
4439 * linux-aarch64-low.c (is_sve_tdesc): Check against target feature
4440 instead of register count.
4441 * tdesc.c (tdesc_contains_feature): New function.
4442 * tdesc.h (tdesc_contains_feature): New prototype.
4443
cd850b40
CB
44442019-11-15 Christian Biesinger <cbiesinger@google.com>
4445
4446 * Makefile.in: Add safe-strerror.c.
4447 * configure: Regenerate.
4448 * configure.ac: Don't source common.host.
4449
5abebf3c
CB
44502019-11-15 Christian Biesinger <cbiesinger@google.com>
4451
4452 * config.in: Regenerate.
4453 * configure: Regenerate.
4454
e06f3d6e
AB
44552019-11-12 Andrew Burgess <andrew.burgess@embecosm.com>
4456
4457 * ax.c (ax_printf): Handle size_t_arg.
4458
ca3a04f6
CB
44592019-11-06 Christian Biesinger <cbiesinger@google.com>
4460
4461 * linux-tdep.c (linux_info_proc): Use strtok_r instead of strtok.
4462 * mi/mi-main.c (output_cores): Likewise.
4463 * nat/linux-osdata.c (linux_xfer_osdata_cpus): Likewise.
4464 (linux_xfer_osdata_modules): Likewise.
4465 * remote.c (register_remote_support_xml): Likewise.
4466 * sparc64-tdep.c (adi_is_addr_mapped): Likewise.
4467 * xml-syscall.c (syscall_create_syscall_desc): Likewise.
4468
e48f6033
CB
44692019-11-01 Christian Biesinger <cbiesinger@google.com>
4470
4471 * configure: Regenerate.
4472 * configure.ac: Remove check for strerror_r.
4473
e7e97a2e
CB
44742019-10-31 Christian Biesinger <cbiesinger@google.com>
4475
4476 * config.in: Regenerate.
4477 * configure: Regenerate.
4478 * configure.ac: Also check for strerror_r.
4479
75cafaa6
CB
44802019-10-31 Christian Biesinger <cbiesinger@google.com>
4481
4482 * ax.h (debug_agent): Remove duplicate declaration.
4483
30baf67b
TV
44842019-10-26 Tom de Vries <tdevries@suse.de>
4485
4486 * linux-aarch64-low.c: Fix typos in comments.
4487 * linux-arm-low.c: Same.
4488 * linux-low.c: Same.
4489 * linux-ppc-low.c: Same.
4490 * proc-service.c: Same.
4491 * regcache.h: Same.
4492 * server.c: Same.
4493 * tracepoint.c: Same.
4494 * win32-low.c: Same.
4495
52c64cf7
TT
44962019-10-25 Tom Tromey <tromey@adacore.com>
4497
4498 * utils.c (xstrdup): Remove.
4499
c12d372d
TT
45002019-10-23 Tom Tromey <tom@tromey.com>
4501
4502 * configure, config.in: Rebuild.
4503
4d0b984b
TT
45042019-10-23 Tom Tromey <tom@tromey.com>
4505
4506 * configure: Rebuild.
4507 * acinclude.m4: Use m4_include, not sinclude.
4508
c5adaa19
TT
45092019-10-17 Tom Tromey <tromey@adacore.com>
4510
4511 * configure: Rebuild.
4512 * configure.ac: Use AC_CONFIG_HEADERS. Create stamp-h there, not
4513 in AC_CONFIG_FILES invocation.
4514 * Makefile.in (stamp-h, Makefile): Use new-style config.status
4515 invocation.
4516
fec4e896
CB
45172019-10-16 Christian Biesinger <cbiesinger@google.com>
4518
4519 * server.c: Include xml-builtin.h.
4520 (get_xml_features): Don't declare xml_builtins here.
4521
00975ff6
AB
45222019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
4523
4524 * Makefile.in: Remove references to vec-ipa.o.
4525
0dc32745
AB
45262019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
4527
4528 * Makefile.in: Remove references to vec.c.
4529
3e6ec53a
CB
45302019-10-02 Christian Biesinger <cbiesinger@google.com>
4531
4532 * server.c (server_waiting): Change to bool.
4533 (extended_protocol): Likewise.
4534 (response_needed): Likewise.
4535 (exit_requested): Likewise.
4536 (run_once): Likewise.
4537 (report_no_resumed): Likewise.
4538 (non_stop): Likewise.
4539 (disable_packet_vCont): Likewise.
4540 (disable_packet_Tthread): Likewise.
4541 (disable_packet_qC): Likewise.
4542 (disable_packet_qfThreadInfo): Likewise.
4543 (handle_general_set): Update.
4544 (handle_detach): Update.
4545 (handle_monitor_command): Update.
4546 (handle_query): Update.
4547 (captured_main): Update.
4548 (process_serial_event): Update.
4549 * server.h (server_waiting): Change to bool.
4550 (disable_packet_vCont): Likewise.
4551 (disable_packet_Tthread): Likewise.
4552 (disable_packet_qC): Likewise.
4553 (disable_packet_qfThreadInfo): Likewise.
4554 (run_once): Likewise.
4555 (non_stop): Likewise.
4556 * target.c (target_stop_and_wait): Update.
4557
80fd2826
TT
45582019-10-02 Tom Tromey <tromey@adacore.com>
4559
4560 * Makefile.in (SFILES): Add common-inferior.c.
4561 (OBS): Add common-inferior.o.
4562 * server.c (startup_with_shell): Don't define.
4563
46f29a9a
AB
45642019-10-02 Andrew Burgess <andrew.burgess@embecosm.com>
4565
4566 * linux-low.c (linux_low_read_btrace): Update for change to
4567 std::vector.
4568
f9d949fb
CB
45692019-09-20 Christian Biesinger <cbiesinger@google.com>
4570
4571 * debug.c (debug_threads): Remove comment in favor of the header.
4572 * debug.h (using_threads): Add declaration.
4573 (debug_threads): Add comment.
4574 * linux-aarch64-low.c: Include debug.h and remove declaration of
4575 debug_threads.
4576 * nto-low.c: Likewise.
4577 * remote-utils.c: Likewise.
4578 * thread-db.c: Likewise.
4579
abf516c6
UW
45802019-09-20 Ulrich Weigand <uweigand@de.ibm.com>
4581
4582 * configure.srv (ipa_ppc_linux_regobj): Remove powerpc-cell32l-ipa.o
4583 and powerpc-cell64l-ipa.o.
4584 (powerpc*-*-linux*): Remove powerpc-cell32l.o and powerpc-cell64l.o
4585 from srv_regobj. Remove rs6000/powerpc-cell32l.xml and
4586 rs6000/powerpc-cell64l.xml from srv_xmlfiles.
4587 (spu*-*-*): Remove.
4588
4589 * spu-low.c: Remove file.
4590
4591 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Remove.
4592 (parse_spufs_run): Remove.
4593 (ppc_get_pc): Remove Cell/B.E. support.
4594 (ppc_set_pc): Likewise.
4595 (ppc_breakpoint_at): Likewise.
4596 (ppc_arch_setup): Likewise.
4597 (ppc_get_ipa_tdesc_idx): Do not handle tdesc_powerpc_cell64l or
4598 tdesc_powerpc_cell32l.
4599 (initialize_low_arch): Do not call init_registers_powerpc_cell64l
4600 or init_registers_powerpc_cell32l.
4601 * linux-ppc-ipa.c (get_ipa_tdesc): Do not handle PPC_TDESC_CELL.
4602 (initialize_low_tracepoint): Do not call init_registers_powerpc_cell64l
4603 or init_registers_powerpc_cell32l.
4604 * linux-ppc-tdesc-init.h (PPC_TDESC_CELL): Mark as unused.
4605 (init_registers_powerpc_cell32l): Remove prototype.
4606 (init_registers_powerpc_cell64l): Likewise.
4607
4608 * target.h (struct target_ops): Remove qxfer_spu member.
4609 * server.c (handle_qxfer_spu): Remove.
4610 (qxfer_packets): Remove entry for "spu".
4611 (handle_query): No longer support qXfer:spu:read or qXfer:spu:write.
4612 * linux-low.c (SPUFS_MAGIC): Remove.
4613 (spu_enumerate_spu_ids): Remove.
4614 (linux_qxfer_spu): Remove.
4615 (linux_target_ops): Remove qxfer_spu member.
4616 * lynx-low.c (lynx_target_ops): Remove qxfer_spu member.
4617 * nto-low.c (nto_target_ops): Remove qxfer_spu member.
4618 * win32-low.c (win32_target_ops): Remove qxfer_spu member.
4619
2d41fa11
SDJ
46202019-08-23 Sergio Durigan Junior <sergiodj@redhat.com>
4621
4622 * Makefile.in (SFILES): Add 'gdbsupport/gdb-dlfcn.c'.
4623 (OBS): Add 'gdbsupport/gdb-dlfcn.o'.
4624 * config.in: Regenerate.
4625 * configure: Regenerate.
4626
d59b55f0
TT
46272019-08-15 Tom Tromey <tromey@adacore.com>
4628
4629 * target.c (target_write_memory): Use gdb::byte_vector.
4630
4196ab2a
TT
46312019-08-15 Tom Tromey <tromey@adacore.com>
4632
4633 * tracepoint.c (write_inferior_data_pointer)
4634 (write_inferior_integer, write_inferior_int8)
4635 (write_inferior_uinteger, m_tracepoint_action_download)
4636 (r_tracepoint_action_download, x_tracepoint_action_download)
4637 (l_tracepoint_action_download, clear_inferior_trace_buffer)
4638 (download_agent_expr, download_tracepoint_1)
4639 (download_trace_state_variables, upload_fast_traceframes): Update.
4640 * server.c (gdb_write_memory): Update.
4641 * remote-utils.c (relocate_instruction): Update.
4642 * proc-service.c (ps_pdwrite): Update.
4643 * mem-break.c (remove_memory_breakpoint)
4644 (delete_fast_tracepoint_jump, set_fast_tracepoint_jump)
4645 (uninsert_fast_tracepoint_jumps_at)
4646 (reinsert_fast_tracepoint_jumps_at): Update.
4647 * linux-x86-low.c (append_insns)
4648 (i386_install_fast_tracepoint_jump_pad)
4649 (amd64_write_goto_address, i386_write_goto_address): Update.
4650 * linux-s390-low.c (append_insns, s390_write_goto_address):
4651 Update.
4652 * linux-ppc-low.c (ppc_relocate_instruction)
4653 (ppc_install_fast_tracepoint_jump_pad, emit_insns)
4654 (ppc_write_goto_address): Update.
4655 * linux-aarch64-low.c (append_insns): Update.
4656 * target.h (struct target_ops): Update.
4657 (write_inferior_memory): Don't declare.
4658 * target.c (target_write_memory): Rename from
4659 write_inferior_memory. Remove old target_write_memory.
4660
c6778d00
TT
46612019-08-15 Tom Tromey <tromey@adacore.com>
4662
4663 * target.c (write_inferior_memory): Use std::vector.
4664
404f2902
FCE
46652019-08-06 Frank Ch. Eigler <fche@redhat.com>
4666
4667 PR build/24886
4668 * configure.ac: Drop enable-libmcheck support.
4669 * configure, config.in: Rebuild.
4670 * acinclude.m4: Don't include it.
4671
4c5aa8e0
AH
46722019-07-19 Alan Hayward <alan.hayward@arm.com>
4673
4674 * configure.srv: Remove Arm xml files.
4675
7cc17433
AH
46762019-07-19 Alan Hayward <alan.hayward@arm.com>
4677
4678 * configure.srv: Add new files. Remove xml generated files.
4679 * linux-aarch32-low.c (initialize_low_arch_aarch32): Don't init
4680 registers.
4681 * linux-aarch32-low.h (tdesc_arm_with_neon): Remove.
4682 * linux-aarch32-tdesc.c: New file.
4683 * linux-aarch32-tdesc.h: New file.
4684 * linux-aarch64-low.c (aarch64_arch_setup): Call aarch32_linux_read_description.
4685 * linux-arm-low.c (init_registers_arm, tdesc_arm)
4686 (init_registers_arm_with_iwmmxt, tdesc_arm_with_iwmmxt)
4687 (init_registers_arm_with_vfpv2, tdesc_arm_with_vfpv2)
4688 (init_registers_arm_with_vfpv3, tdesc_arm_with_vfpv3): Remove.
4689 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
4690 (arm_store_vfpregset): Call arm_linux_get_tdesc_fp_type.
4691 (arm_read_description): Call arm_linux_read_description.
4692 (initialize_low_arch): Don't init registers.
4693 * linux-arm-tdesc.c: New file.
4694 * linux-arm-tdesc.h: New file.
4695
166a82be
AH
46962019-07-10 Alan Hayward <alan.hayward@arm.com>
4697
4698 * linux-arm-low.c (arm_fill_wmmxregset, arm_store_wmmxregset):
4699 Move counter inside for.
4700 (arm_read_description): Check ptrace earlier.
4701 (arm_arch_setup): Call arm_linux_init_hwbp_cap here.
4702
268a13a5
TT
47032019-07-09 Tom Tromey <tom@tromey.com>
4704
4705 * configure: Rebuild.
4706 * configure.ac: Change common to gdbsupport.
4707 * acinclude.m4: Change common to gdbsupport.
4708 * Makefile.in (SFILES, OBS, GDBREPLAY_OBS, IPA_OBJS)
4709 (version-generated.c, gdbsupport/%-ipa.o, gdbsupport/%.o): Change
4710 common to gdbsupport.
4711 * ax.c, event-loop.c, fork-child.c, gdb_proc_service.h,
4712 gdbreplay.c, gdbthread.h, hostio-errno.c, hostio.c, i387-fp.c,
4713 inferiors.c, inferiors.h, linux-aarch64-tdesc-selftest.c,
4714 linux-amd64-ipa.c, linux-i386-ipa.c, linux-low.c,
4715 linux-tic6x-low.c, linux-x86-low.c, linux-x86-tdesc-selftest.c,
4716 linux-x86-tdesc.c, lynx-i386-low.c, lynx-low.c, mem-break.h,
4717 nto-x86-low.c, regcache.c, regcache.h, remote-utils.c, server.c,
4718 server.h, spu-low.c, symbol.c, target.h, tdesc.c, tdesc.h,
4719 thread-db.c, tracepoint.c, win32-i386-low.c, win32-low.c: Change
4720 common to gdbsupport.
4721
350fab54
AH
47222019-07-04 Alan Hayward <alan.hayward@arm.com>
4723
4724 * linux-aarch32-low.c (arm_read_description, arm_regsets): Use new
4725 defines.
4726 * linux-arm-low.c (arm_read_description, arm_regsets): Likewise.
4727
2b40fda7
AH
47282019-07-04 Alan Hayward <alan.hayward@arm.com>
4729
4730 * configure.srv: Remove legacy xml.
4731 * linux-aarch64-low.c (initialize_low_arch): Remove
4732 initialize_low_tdesc call.
4733 * linux-aarch64-tdesc-selftest.c: Remove file.
4734 * linux-aarch64-tdesc.h (initialize_low_tdesc): Remove.
4735 * linux-x86-low.c (initialize_low_arch): Remove
4736 initialize_low_tdesc call.
4737 * linux-x86-tdesc-selftest.c: Remove file.
4738 * linux-x86-tdesc.h (initialize_low_tdesc): Remove.
4739
7d10623d
TV
47402019-06-20 Tom de Vries <tdevries@suse.de>
4741
4742 * linux-s390-ipa.c (get_ipa_tdesc)[!__s390x__]: Use
4743 s390_te_linux64_ft_collect_regmap for S390_TDESC_GS.
4744
8d6a48df
TV
47452019-06-19 Tom de Vries <tdevries@suse.de>
4746
4747 * debug.h (debug_write): Change return type to ssize_t.
4748 * debug.c (debug_write): Same.
4749
73cc7272
TT
47502019-06-14 Tom Tromey <tom@tromey.com>
4751
4752 * configure.ac: Use new path to gnulib.
4753 * configure: Rebuild.
4754 * Makefile.in (INCGNU, $(GNULIB_BUILDDIR)/Makefile): Use new path
4755 to gnulib.
4756
08f10e02
TT
47572019-06-11 Tom Tromey <tom@tromey.com>
4758
4759 * Makefile.in (SFILES): Add alloc.c.
4760 (OBS): Add alloc.o.
4761 (IPA_OBJS): Add alloc-ipa.o.
4762 (alloc-ipa.o): New target.
4763 (%.o: ../%.c): New pattern rule.
4764
422186a9
TT
47652019-06-10 Tom Tromey <tromey@adacore.com>
4766
4767 * remote-utils.c (look_up_one_symbol, relocate_instruction): Don't
4768 end warning with a newline.
4769 * linux-s390-low.c (s390_get_wordsize): Don't end warning with a
4770 newline.
4771 * thread-db.c (attach_thread): Don't end warning with a newline.
4772 (thread_db_notice_clone): Likewise.
4773 * tracepoint.c (gdb_agent_helper_thread): Don't end warning with a
4774 newline.
4775 * linux-x86-low.c (x86_get_min_fast_tracepoint_insn_len): Don't
4776 end warning with a newline.
4777
b02f78f9
PA
47782019-06-04 Pedro Alves <palves@redhat.com>
4779
4780 * server.c (captured_main): Use make_unique_xstrdup.
4781
88ed7edb
TT
47822019-06-02 Tom Tromey <tom@tromey.com>
4783
4784 * gdbreplay.c (fromhex): Remove.
4785 * Makefile.in (GDBREPLAY_OBS): Add rsp-low.o.
4786
33a6bc35
TT
47872019-05-29 Tom Tromey <tromey@adacore.com>
4788
4789 * configure: Rebuild.
4790
e90a813d
KB
47912019-05-06 Kevin Buettner <kevinb@redhat.com>
4792
4793 * linux-x86-low.c (x86_fill_gregset): Don't compile 64-bit
4794 sign extension code on 32-bit builds.
4795
353ea2d1
EZ
47962019-05-03 Eli Zaretskii <eliz@gnu.org>
4797
4798 * remote-utils.c:
4799 * gdbreplay.c [USE_WIN32API]: Remove the _WIN32_WINNT override.
4800
b494cdff
TT
48012019-04-19 Tom Tromey <tom@tromey.com>
4802
4803 * server.c (struct vstop_notif): Derive from notif_event.
4804 <base>: Remove.
4805 (queue_stop_reply): Update.
4806 (remove_all_on_match_ptid): Change type. Rewrite.
4807 (discard_queued_stop_replies): Rewrite.
4808 (in_queued_stop_replies_ptid): Change type.
4809 (in_queued_stop_replies): Rewrite.
4810 (notif_stop): Update.
4811 (queue_stop_reply_callback): Update.
4812 (captured_main): Don't call initialize_notif.
4813 (push_stop_notification): Update.
4814 * notif.c (notif_write_event, handle_notif_ack)
4815 (notif_event_enque, notif_push): Update.
4816 (notif_event_xfree, initialize_notif): Remove.
4817 * notif.h (struct notif_event): Include <list>, not
4818 "common/queue.h".
4819 (struct notif_server) <queue>: Now a std::list.
4820 (notif_event_p): Remove typedef.
4821 (initialize_notif): Don't declare.
4822 (struct notif_event): Add virtual destructor.
4823
a7e559cc
AH
48242019-04-17 Alan Hayward <alan.hayward@arm.com>
4825
4826 * ax.c (ax_vdebug): Call debug_printf.
4827 * debug.c (debug_write): New function.
4828 * debug.h (debug_write): New declaration.
4829 * linux-low.c (sigchld_handler): Call debug_write.
4830
aeb2e706
AH
48312019-04-17 Alan Hayward <alan.hayward@arm.com>
4832
4833 * debug.c (debug_set_output): New function.
4834 (debug_vprintf): Send output to debug_file.
4835 (debug_flush): Likewise.
4836 * debug.h (debug_set_output): New declaration.
4837 * server.c (handle_monitor_command): Add debug-file option.
4838 (captured_main): Likewise.
4839
c1bc0935
AH
48402019-04-17 Alan Hayward <alan.hayward@arm.com>
4841
4842 * debug.c (remote_debug): Add definition.
4843 * debug.h (remote_debug): Add declaration.
4844 * hostio.c (remote_debug): Remove declaration.
4845 * remote-utils.c (struct ui_file): Likewise.
4846 (remote_debug): Likewise.
4847 * remote-utils.h (remote_debug): Likewise,
4848 * server.c (remote_debug): Remove definition.
4849
3f52fdbc
KB
48502019-04-10 Kevin Buettner <kevinb@redhat.com>
4851
4852 * linux-x86-low.c (x86_fill_gregset): Sign extend EAX value
4853 when using a 64-bit gdbserver.
4854
b0319eaa
TT
48552019-04-09 Tom Tromey <tromey@adacore.com>
4856
4857 * linux-low.c (select_event_lwp): Use find_thread_in_random.
4858
eedc3f4f
TT
48592019-04-08 Tom Tromey <tom@tromey.com>
4860
4861 * linux-low.c (linux_detach_one_lwp): Replace throw_exception with
4862 throw.
4863 (linux_resume_one_lwp): Likewise.
4864
230d2906
TT
48652019-04-08 Tom Tromey <tom@tromey.com>
4866
4867 * gdbreplay.c: Update.
4868 * linux-low.c: Update.
4869 * server.c: Update.
4870
a70b8144
TT
48712019-04-08 Tom Tromey <tom@tromey.com>
4872
4873 * server.c: Use C++ exception handling.
4874 * linux-low.c: Use C++ exception handling.
4875 * gdbreplay.c: Use C++ exception handling.
4876
3d6e9d23
TT
48772019-04-08 Tom Tromey <tom@tromey.com>
4878
4879 * server.c (handle_btrace_general_set, handle_qxfer_btrace)
4880 (handle_qxfer_btrace_conf, detach_or_kill_for_exit_cleanup)
4881 (captured_main, main): Update.
4882 * gdbreplay.c (main): Update.
4883
0570503d
PFC
48842019-04-05 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4885
4886 * linux-low.c (linux_get_auxv): Remove static. Return auxv entry
4887 value in argument pointer, return 1 if the entry is found and 0
4888 otherwise. Move comment.
4889 (linux_get_hwcap, linux_get_hwcap2): Use modified linux_get_auxv.
4890 * linux-low.h (linux_get_auxv): Declare.
4891 * linux-ppc-low.c (is_elfv2_inferior): Use linux_get_auxv.
4892
227a9e65
TT
48932019-04-05 Tom Tromey <tromey@adacore.com>
4894
4895 * server.c (gdbserver_usage): Use upper-case for metasyntactic
4896 variables.
4897
69f4c9cc
AH
48982019-03-28 Alan Hayward <alan.hayward@arm.com>
4899
4900 * linux-low.c (AT_HWCAP2): Add define if not already included.
4901
974c89e0
AH
49022019-03-26 Alan Hayward <alan.hayward@arm.com>
4903
4904 * linux-aarch64-low.c (aarch64_get_hwcap): Remove function.
4905 (aarch64_arch_setup): Call linux_get_hwcap.
4906 * linux-arm-low.c (arm_get_hwcap): Remove function.
4907 (arm_read_description): Call linux_get_hwcap.
4908 * linux-low.c (linux_get_auxv): New function.
4909 (linux_get_hwcap): Likewise.
4910 (linux_get_hwcap2): Likewise.
4911 * linux-low.h (linux_get_hwcap): New declaration.
4912 (linux_get_hwcap2): Likewise.
4913 * linux-ppc-low.c (ppc_get_auxv): Remove function.
4914 (ppc_arch_setup): Call linux_get_hwcap.
4915 * linux-s390-low.c (s390_get_hwcap): Remove function.
4916 (s390_arch_setup): Call linux_get_hwcap.
4917
1ef53e6b
AH
49182019-03-22 Alan Hayward <alan.hayward@arm.com>
4919 Jiong Wang <jiong.wang@arm.com>
4920
4921 * linux-aarch64-low.c (aarch64_store_pauthregset): New function.
4922 * linux-low.c (regsets_store_inferior_registers): Allow optional reads
4923 to fail.
4924 * linux-low.h (enum regset_type): Add OPTIONAL_REGS.
4925
ee4fbcfa
AH
49262019-03-22 Alan Hayward <alan.hayward@arm.com>
4927 Jiong Wang <jiong.wang@arm.com>
4928
4929 * linux-aarch64-low.c (AARCH64_HWCAP_PACA): New define.
4930 (aarch64_get_hwcap): New function.
4931 (aarch64_arch_setup): Read APIA hwcap.
4932
6dc0ebde
AH
49332019-03-22 Alan Hayward <alan.hayward@arm.com>
4934 Jiong Wang <jiong.wang@arm.com>
4935
4936 * linux-aarch64-ipa.c (get_ipa_tdesc): Add pauth param.
4937 (initialize_low_tracepoint): Likewise.
4938 * linux-aarch64-low.c (aarch64_arch_setup): Likewise.
4939 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Likewise.
4940 * linux-aarch64-tdesc.c (struct target_desc): Likewise.
4941 (aarch64_linux_read_description): Likewise.
4942 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Likewise.
4943
1163a4b7
JB
49442019-03-12 John Baldwin <jhb@FreeBSD.org>
4945
4946 * linux-x86-tdesc.c (i386_linux_read_description): Update call to
4947 i386_create_target_description for 'segments' parameter.
4948 * lynx-i386-low.c (lynx_i386_arch_setup): Likewise.
4949 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
4950 * win32-i386-low.c (i386_arch_setup): Likewise.
4951
d3a70e03
TT
49522019-03-12 Tom Tromey <tromey@adacore.com>
4953
4954 * linux-low.c (iterate_over_lwps): Update.
4955
37991b4f
TT
49562019-03-06 Tom Tromey <tom@tromey.com>
4957
4958 * server.c (detach_or_kill_for_exit_cleanup): Remove parameter.
4959 (captured_main): Use SCOPE_EXIT.
4960
45950eb6
SDJ
49612019-03-04 Sergio Durigan Junior <sergiodj@redhat.com>
4962
4963 * configure.srv: Use '$enable_unittest' instead of '$development'
4964 when checking whether to fill 'srv_regobj' on 'aarch64*-*-linux*'
4965 case.
4966
43ac54fc
TT
49672019-02-27 Tom Tromey <tromey@adacore.com>
4968
4969 * gdbreplay.c (logchar): Handle \r\n.
4970
df0da8a2
AH
49712019-02-07 Alan Hayward <alan.hayward@arm.com>
4972
4973 * linux-low.c (linux_attach): Add process before lwp.
4974 * server.c (attach_inferior): Check if already attached.
4975
1a5c2598
TT
49762019-02-07 Tom Tromey <tom@tromey.com>
4977
4978 * x86-tdesc.h: Rename include guard.
4979 * x86-low.h: Add include guard.
4980 * wincecompat.h: Rename include guard.
4981 * win32-low.h: Add include guard.
4982 * utils.h: Rename include guard.
4983 * tracepoint.h: Rename include guard.
4984 * tdesc.h: Rename include guard.
4985 * target.h: Rename include guard.
4986 * server.h: Rename include guard.
4987 * remote-utils.h: Rename include guard.
4988 * regcache.h: Rename include guard.
4989 * nto-low.h: Rename include guard.
4990 * notif.h: Add include guard.
4991 * mem-break.h: Rename include guard.
4992 * lynx-low.h: Add include guard.
4993 * linux-x86-tdesc.h: Add include guard.
4994 * linux-s390-tdesc.h: Add include guard.
4995 * linux-ppc-tdesc-init.h: Add include guard.
4996 * linux-low.h: Add include guard.
4997 * linux-aarch64-tdesc.h: Add include guard.
4998 * linux-aarch32-low.h: Add include guard.
4999 * inferiors.h: Rename include guard.
5000 * i387-fp.h: Rename include guard.
5001 * hostio.h: Rename include guard.
5002 * gdbthread.h: Rename include guard.
5003 * gdb_proc_service.h: Rename include guard.
5004 * event-loop.h: Rename include guard.
5005 * dll.h: Rename include guard.
5006 * debug.h: Rename include guard.
5007 * ax.h: Rename include guard.
5008
956cc47c
SN
50092018-01-30 Szabolcs Nagy <szabolcs.nagy@arm.com>
5010
5011 PR gdb/23985
5012 * Makefile.in (IPAGENT_CFLAGS): Add UNDO_GNULIB_CFLAGS.
5013 (UNDO_GNULIB_CFLAGS): Undo gnulib replacements.
5014
a0707f3c
TT
50152019-01-25 Tom Tromey <tom@tromey.com>
5016
5017 * Makefile.in (INCLUDE_CFLAGS): Don't add -I for common.
5018
0747795c
TT
50192019-01-25 Tom Tromey <tom@tromey.com>
5020
5021 * win32-low.c: Fix common/ includes.
5022 * win32-i386-low.c: Fix common/ includes.
5023 * tracepoint.c: Fix common/ includes.
5024 * thread-db.c: Fix common/ includes.
5025 * target.h: Fix common/ includes.
5026 * symbol.c: Fix common/ includes.
5027 * spu-low.c: Fix common/ includes.
5028 * server.h: Fix common/ includes.
5029 * server.c: Fix common/ includes.
5030 * remote-utils.c: Fix common/ includes.
5031 * regcache.h: Fix common/ includes.
5032 * regcache.c: Fix common/ includes.
5033 * nto-x86-low.c: Fix common/ includes.
5034 * notif.h: Fix common/ includes.
5035 * mem-break.h: Fix common/ includes.
5036 * lynx-low.c: Fix common/ includes.
5037 * lynx-i386-low.c: Fix common/ includes.
5038 * linux-x86-tdesc-selftest.c: Fix common/ includes.
5039 * linux-x86-low.c: Fix common/ includes.
5040 * linux-low.c: Fix common/ includes.
5041 * inferiors.h: Fix common/ includes.
5042 * i387-fp.c: Fix common/ includes.
5043 * hostio.c: Fix common/ includes.
5044 * hostio-errno.c: Fix common/ includes.
5045 * gdbthread.h: Fix common/ includes.
5046 * gdbreplay.c: Fix common/ includes.
5047 * fork-child.c: Fix common/ includes.
5048 * event-loop.c: Fix common/ includes.
5049 * ax.c:
5050 (enum gdb_agent_op): Fix common/ includes.
5051
be6d4f74
TT
50522019-01-21 Tom Tromey <tom@tromey.com>
5053
5054 * tracepoint.c: Fix includes.
5055 * remote-utils.c: Fix includes.
5056 * linux-x86-low.c: Fix includes.
5057
66d91b39
JB
50582019-01-01 Joel Brobecker <brobecker@adacore.com>
5059
5060 * gdbreplay.c (gdbreplay_version): Update copyright year in
5061 version message.
5062 * server.c (gdbserver_version): Likewise.
5063
754e3168
AH
50642018-12-05 Alan Hayward <alan.hayward@arm.com>
5065
5066 * linux-low.c (add_lwp): Switch ordering.
5067
d105de22
TT
50682018-11-29 Tom Tromey <tom@tromey.com>
5069
5070 * win32-low.c (win32_join): Take pid, not process.
5071 * target.h (struct target_ops) <join>: Change argument type.
5072 (join_inferior): Change argument name.
5073 * spu-low.c (spu_join): Take pid, not process.
5074 * server.c (handle_detach): Preserve pid before destroying
5075 process.
5076 * lynx-low.c (lynx_join): Take pid, not process.
5077 * linux-low.c (linux_join): Take pid, not process.
5078
50138245
AH
50792018-11-23 Alan Hayward <alan.hayward@arm.com>
5080
5081 * linux-aarch64-low.c (aarch64_cannot_store_register): Remove.
5082 (aarch64_cannot_fetch_register): Likewise.
5083 (struct linux_target_ops): Update references.
5084
64f57f3d
PFC
50852018-10-31 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5086
5087 * linux-ppc-low.c: Include nat/linux-ptrace.h.
5088
8d619c01
EBM
50892018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5090
5091 * configure.srv (ipa_ppc_linux_regobj): Add
5092 powerpc-isa207-htm-vsx32l-ipa.o and
5093 powerpc-isa207-htm-vsx64l-ipa.o.
5094 (powerpc*-*-linux*): Add powerpc-isa207-htm-vsx32l.o and
5095 powerpc-isa207-htm-vsx64l.o to srv_regobj. Add
5096 rs6000/power-htm-spr.xml, rs6000/power-htm-core.xml,
5097 rs6000/power64-htm-core.xml, rs6000/power-htm-fpu.xml,
5098 rs6000/power-htm-altivec.xml, rs6000/power-htm-vsx.xml,
5099 rs6000/power-htm-ppr.xml, rs6000/power-htm-dscr.xml,
5100 rs6000/power-htm-tar.xml, rs6000/powerpc-isa207-htm-vsx32l.xml,
5101 and rs6000/powerpc-isa207-htm-vsx64l.xml to srv_xmlfiles.
5102 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
5103 <PPC_TDESC_ISA207_HTM_VSX>: New enum value.
5104 (init_registers_powerpc_isa207_htm_vsx32l)
5105 (init_registers_powerpc_isa207_htm_vsx64l): Declare.
5106 * linux-ppc-low.c (ppc_fill_tm_sprregset, ppc_store_tm_sprregset)
5107 (ppc_store_tm_cgprregset, ppc_store_tm_cfprregset)
5108 (ppc_store_tm_cvrregset, ppc_store_tm_cvsxregset)
5109 (ppc_store_tm_cpprregset, ppc_store_tm_cdscrregset)
5110 (ppc_store_tm_ctarregset): New functions.
5111 (ppc_regsets): Add entries for HTM regsets.
5112 (ppc_arch_setup): Set htm in features struct when needed. Set
5113 sizes for the HTM regsets.
5114 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_HTM_VSX.
5115 (initialize_low_arch): Call
5116 init_registers_powerpc_isa207_htm_vsx32l and
5117 init_registers_powerpc_isa207_htm_vsx64l.
5118 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
5119 PPC_TDESC_ISA207_HTM_VSX.
5120 (initialize_low_tracepoint): Call
5121 init_registers_powerpc_isa207_htm_vsx32l and
5122 init_registers_powerpc_isa207_htm_vsx64l.
5123
232bfb86
EBM
51242018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5125
5126 * configure.srv (powerpc*-*-linux*): Add rs6000/power-ebb.xml and
5127 rs6000/power-linux-pmu.xml to srv_xmlfiles.
5128 * linux-ppc-low.c (ppc_store_ebbregset, ppc_fill_pmuregset)
5129 (ppc_store_pmuregset): New functions.
5130 (ppc_regsets): Add entries for ebb and pmu regsets.
5131 (ppc_arch_setup): Set isa207 in features struct if the ebb and
5132 pmu regsets are available. Set sizes for these regsets.
5133
f2cf6173
EBM
51342018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5135
5136 * configure.srv (ipa_ppc_linux_regobj): Add
5137 powerpc-isa207-vsx64l-ipa.o and powerpc-isa207-vsx32l-ipa.o.
5138 (powerpc*-*-linux*): Add powerpc-isa207-vsx32l.o and
5139 powerpc-isa207-vsx64l.o to srv_regobj, add rs6000/power-tar.xml,
5140 rs6000/powerpc-isa207-vsx32l.xml, and
5141 rs6000/powerpc-isa207-vsx64l.xml to srv_xmlfiles.
5142 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
5143 <PPC_TDESC_ISA207_VSX>: New enum value.
5144 (init_registers_powerpc_isa207_vsx32l): Declare.
5145 (init_registers_powerpc_isa207_vsx64l): Declare.
5146 * linux-ppc-low.c (ppc_fill_tarregset): New function.
5147 (ppc_store_tarregset): New function.
5148 (ppc_regsets): Add entry for the TAR regset.
5149 (ppc_arch_setup): Set isa207 in features struct when needed. Set
5150 size for the TAR regsets.
5151 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_VSX.
5152 (initialize_low_arch): Call init_registers_powerpc_isa207_vsx32l
5153 and init_registers_powerpc_isa207_vsx64l.
5154 * linux-ppc-ipa.c (get_ipa_tdesc): Handle PPC_TDESC_ISA207_VSX.
5155 (initialize_low_tracepoint): Call
5156 init_registers_powerpc_isa207_vsx32l and
5157 init_registers_powerpc_isa207_vsx64l.
5158
7ca18ed6
EBM
51592018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
5160 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5161
5162 * configure.srv (ipa_ppc_linux_regobj): Add
5163 powerpc-isa205-ppr-dscr-vsx32l-ipa.o and
5164 powerpc-isa205-ppr-dscr-vsx64l-ipa.o.
5165 (powerpc*-*-linux*): Add powerpc-isa205-ppr-dscr-vsx32l.o and
5166 powerpc-isa205-ppr-dscr-vsx64l.o to srv_regobj, add
5167 rs6000/power-dscr.xml, rs6000/power-ppr.xml,
5168 rs6000/powerpc-isa205-ppr-dscr-vsx32l.xml and
5169 rs6000/powerpc-isa205-ppr-dscr-vsx64l.xml to srv_xmlfiles.
5170 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
5171 <PPC_TDESC_ISA205_PPR_DSCR_VSX>: New enum value.
5172 (init_registers_powerpc_isa205_ppr_dscr_vsx32l)
5173 (init_registers_powerpc_isa205_ppr_dscr_vsx64l): Declare.
5174 * linux-ppc-low.c: Include "elf/common.h" and <sys/uio.h>.
5175 (ppc_hwcap): Add comment.
5176 (ppc_hwcap2): New global.
5177 (ppc_check_regset, ppc_fill_pprregset, ppc_store_pprregset)
5178 (ppc_fill_dscrregset, ppc_store_dscrregset): New functions.
5179 (ppc_regsets): Add entries for the DSCR and PPR regsets.
5180 (ppc_arch_setup): Get AT_HWCAP2. Set ppr_dscr in features struct
5181 when needed. Set sizes for the the DSCR and PPR regsets.
5182 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA205_PPR_DSCR_VSX.
5183 (initialize_low_arch): Call
5184 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
5185 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
5186 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
5187 PPC_TDESC_ISA205_PPR_DSCR_VSX.
5188 (initialize_low_tracepoint): Call
5189 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
5190 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
5191
5c849b22
PFC
51922018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5193
5194 * linux-ppc-low.c (ppc_fill_vrregset): Remove memset calls.
5195
8ecfd7bd
SDJ
51962018-10-10 Sergio Durigan Junior <sergiodj@redhat.com>
5197 Simon Marchi <simark@simark.ca>
5198
5199 * acinclude.m4: Include "../selftest.m4".
5200 * configure: Regenerate.
5201 * configure.ac: Use "GDB_AC_SELFTEST".
5202 * configure.srv: Use "$enable_unittests" instead of
5203 "$development" when checking whether unit tests have been
5204 enabled.
5205 * server.c (captured_main): Update message informing that
5206 selftests have been disabled.
5207
96643e35
TT
52082018-10-04 Tom Tromey <tom@tromey.com>
5209
5210 * configure: Rebuild.
5211
da4ae14a
TT
52122018-10-04 Tom Tromey <tom@tromey.com>
5213
5214 * server.c (handle_status): Rename inner "thread".
5215 (process_serial_event): Declare "res" in 'm' case.
5216 * linux-low.c (last_thread_of_process_p, find_lwp_pid)
5217 (iterate_over_lwps): Rename inner "thread".
5218 (linux_qxfer_libraries_svr4): Rename inner "len".
5219 * gdbthread.h (find_thread_in_random): Rename inner "thread".
5220
7c619dbd
GB
52212018-10-01 Gary Benson <gbenson@redhat.com>
5222
5223 * gdb_proc_service.h: Moved common code to
5224 common/gdb_proc_service.h.
5225
3795e814
GB
52262018-10-01 Gary Benson <gbenson@redhat.com>
5227
5228 * gdb_proc_service.h: Synchronize comments and whitespace with
5229 GDB's version of this file.
5230
49b036f1
TT
52312018-09-25 Tom Tromey <tom@tromey.com>
5232
5233 * configure: Rebuild.
5234 * configure.ac (WARN_CFLAGS): Don't remove -Wmissing-prototypes.
5235
8ff03f0b
SM
52362018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
5237
5238 * Makefile.in (gdbserver$(EXEEXT)): Sort OBS.
5239 (gdbreplay$(EXEEXT)): Sort GDBREPLAY_OBS.
5240 ($(IPA_LIB)): Sort IPA_OBJS.
5241
a1cd91dc
SM
52422018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
5243
5244 * Makefile.in: Remove references to $(ADD_DEPS).
5245
752312ba
TT
52462018-09-16 Tom Tromey <tom@tromey.com>
5247
5248 * remote-utils.c (remote_open): Use GNU style for metasyntactic
5249 variables.
5250 * gdbreplay.c (gdbreplay_usage): Use GNU style for metasyntactic
5251 variables.
5252
f1628857
TT
52532018-09-05 Tom Tromey <tom@tromey.com>
5254
5255 * configure: Rebuild.
5256
ad202fcc
SM
52572018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
5258
5259 PR build/23399
5260 * tracepoint.c (IPA_SYM_STRUCT_NAME): Define.
5261
d3d8724a
TT
52622018-08-27 Tom Tromey <tom@tromey.com>
5263
5264 PR build/23087:
5265 * configure: Rebuild.
5266
b4f183d2
TT
52672018-08-27 Tom Tromey <tom@tromey.com>
5268
5269 * linux-s390-low.c (s390_emit_ext, s390_emit_litpool)
5270 (s390_emit_const, s390_emit_reg, s390_emit_zero_ext)
5271 (s390_emit_stack_adjust, s390_emit_set_r2, s390x_emit_ext)
5272 (s390x_emit_const, s390x_emit_reg, s390x_emit_zero_ext)
5273 (s390x_emit_stack_adjust): Add casts to unsigned char.
5274
4e2aa472
SM
52752018-08-22 Simon Marchi <simon.marchi@ericsson.com>
5276
5277 PR gdb/23374
5278 PR gdb/23375
5279 * server.h (struct client_state) <disable_randomization>:
5280 Initialize to 1.
5281
cf4088a9
SM
52822018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
5283
5284 * linux-mips-low.c (mips_collect_ptrace_register): Remove unused
5285 variable.
5286 (mips_supply_ptrace_register): Likewise.
5287
a0de763e
TT
52882018-07-22 Tom Tromey <tom@tromey.com>
5289
5290 * configure: Rebuild.
5291
b0a7723d
TT
52922018-07-22 Tom Tromey <tom@tromey.com>
5293
5294 * win32-low.c (win32_create_inferior): Remove unused variables.
5295 * gdbreplay.c (remote_open): Remove unused variable.
5296 * remote-utils.c (remote_prepare): Remove unused variable.
5297 * x86-tdesc.h (X86_TDESC_H): Define.
5298 (amd64_expedite_regs): Define conditionally.
5299 (i386_expedite_regs): Mark ATTRIBUTE_UNUSED.
5300 * linux-x86-tdesc.c (i386_tdescs): Move inside #if.
5301 * remote-utils.c (readchar): Remove unused variable.
5302
a780ef4f
PA
53032018-07-13 Pedro Alves <palves@redhat.com>
5304
5305 * linux-low.c (linux_kill): Change parameter to process_info
5306 pointer instead of pid. Adjust.
5307 * lynx-low.c (lynx_kill): Likewise.
5308 * nto-low.c (nto_kill): Likewise.
5309 * spu-low.c (spu_kill): Likewise.
5310 * win32-low.c (win32_kill): Likewise.
5311 * server.c (handle_v_kill, kill_inferior_callback)
5312 (detach_or_kill_for_exit): Adjust.
5313 * target.c (kill_inferior): Change parameter to process_info
5314 pointer instead of pid. Adjust.
5315 * target.h (struct target_ops) <kill>: Change parameter to
5316 process_info pointer instead of pid. Adjust all implementations
5317 and callers.
5318 (kill_inferior): Likewise.
5319
ef2ddb33
PA
53202018-07-13 Pedro Alves <palves@redhat.com>
5321
5322 * linux-low.c (linux_detach, linux_join): Change parameter to
5323 process_info pointer instead of pid. Adjust.
5324 * lynx-low.c (lynx_detach, lynx_join): Likewise.
5325 * nto-low.c (nto_detach): Likewise.
5326 * spu-low.c (spu_detach, spu_join): Likewise.
5327 * win32-low.c (win32_detach, win32_join): Likewise.
5328 * server.c (handle_detach, detach_or_kill_for_exit): Adjust.
5329 * target.h (struct target_ops) <detach, join>: Change parameter to
5330 process_info pointer instead of pid. Adjust all implementations
5331 and callers.
5332 (detach_inferior, join_inferior): Rename 'pid' parameter to
5333 'proc'.
5334
c7ab0aef
SDJ
53352018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
5336 Jan Kratochvil <jan.kratochvil@redhat.com>
5337 Paul Fertser <fercerpav@gmail.com>
5338 Tsutomu Seki <sekiriki@gmail.com>
5339
5340 * Makefile.in (SFILES): Add '$(srcdir)/common/netstuff.c'.
5341 (OBS): Add 'common/netstuff.o'.
5342 (GDBREPLAY_OBS): Likewise.
5343 * gdbreplay.c: Include 'wspiapi.h' and 'netstuff.h'.
5344 (remote_open): Implement support for IPv6
5345 connections.
5346 * remote-utils.c: Include 'netstuff.h', 'filestuff.h'
5347 and 'wspiapi.h'.
5348 (handle_accept_event): Accept connections from IPv6 sources.
5349 (remote_prepare): Handle IPv6-style hostnames; implement
5350 support for IPv6 connections.
5351 (remote_open): Implement support for printing connections from
5352 IPv6 sources.
5353
31445d10
PA
53542018-07-11 Pedro Alves <palves@redhat.com>
5355
5356 PR gdb/23377
5357 * mem-break.c (any_persistent_commands): Add process_info
5358 parameter and use it instead of relying on the current process.
5359 Change return type to bool.
5360 * mem-break.h (any_persistent_commands): Add process_info
5361 parameter and change return type to bool.
5362 * server.c (handle_detach): Remove require_running_or_return call.
5363 Look up the process_info for the process we're about to detach.
5364 If not found, return back error to GDB. Adjust
5365 any_persistent_commands call to pass down a process pointer.
5366
cb197132
PA
53672018-07-11 Pedro Alves <palves@redhat.com>
5368
5369 * i387-fp.c (i387_cache_to_fsave, cache_to_fxsave)
5370 (i387_cache_to_xsave): Use regcache_raw_get_unsigned_by_name
5371 instead of collect_register_by_name.
5372 * regcache.c (regcache_raw_get_unsigned_by_name): New.
5373 * regcache.h (regcache_raw_get_unsigned_by_name): New.
5374
1b919490
VB
53752018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
5376 Pedro Alves <palves@redhat.com>
5377
5378 * linux-low.c (initialize_low): Call linux_proc_init_warnings.
5379
d7e15655
TT
53802018-07-03 Tom Tromey <tom@tromey.com>
5381
5382 * linux-low.c: Update.
5383 * lynx-low.c: Update.
5384 * mem-break.c: Update.
5385 * nto-low.c: Update.
5386 * remote-utils.c: Update.
5387 * server.c: Update.
5388 * spu-low.c: Update.
5389 * target.c: Update.
5390 * win32-low.c: Update.
5391
26a57c92
TT
53922018-07-03 Tom Tromey <tom@tromey.com>
5393
5394 * server.c: Update.
5395
0e998d96
TT
53962018-07-03 Tom Tromey <tom@tromey.com>
5397
5398 * linux-low.c: Update.
5399
cc6bcb54
TT
54002018-07-03 Tom Tromey <tom@tromey.com>
5401
5402 * target.c: Update.
5403
e38504b3
TT
54042018-07-03 Tom Tromey <tom@tromey.com>
5405
5406 * linux-low.c: Update.
5407 * linux-mips-low.c: Update.
5408 * lynx-low.c: Update.
5409 * nto-low.c: Update.
5410 * remote-utils.c: Update.
5411 * server.c: Update.
5412 * spu-low.c: Update.
5413 * target.c: Update.
5414 * thread-db.c: Update.
5415
e99b03dc
TT
54162018-07-03 Tom Tromey <tom@tromey.com>
5417
5418 * linux-low.c: Update.
5419 * linux-mips-low.c: Update.
5420 * lynx-low.c: Update.
5421 * mem-break.c: Update.
5422 * nto-low.c: Update.
5423 * remote-utils.c: Update.
5424 * server.c: Update.
5425 * spu-low.c: Update.
5426 * target.c: Update.
5427 * tracepoint.c: Update.
5428
f2907e49
TT
54292018-07-03 Tom Tromey <tom@tromey.com>
5430
5431 * linux-low.c: Update.
5432 * linux-ppc-low.c: Update.
5433 * linux-x86-low.c: Update.
5434 * proc-service.c: Update.
5435 * server.c: Update.
5436 * spu-low.c: Update.
5437 * thread-db.c: Update.
5438 * win32-low.c: Update.
5439
fd79271b
TT
54402018-07-03 Tom Tromey <tom@tromey.com>
5441
5442 * linux-low.c: Update.
5443 * lynx-low.c: Update.
5444 * nto-low.c: Update.
5445 * remote-utils.c: Update.
5446 * spu-low.c: Update.
5447 * thread-db.c: Update.
5448 * win32-low.c: Update.
5449
c0867626
SDJ
54502018-06-29 Joel Brobecker <brobecker@adacore.com>
5451
5452 * linux-x86-tdesc.c (amd64_linux_read_description): Add missing
5453 parameter in call to 'amd64_create_target_description'.
5454
2512d7ef
JK
54552018-06-28 Jan Kratochvil <jan.kratochvil@redhat.com>
5456
5457 * x86-tdesc.h: Remove executable permission flag.
5458
d0ac1c44
SM
54592018-06-19 Simon Marchi <simon.marchi@ericsson.com>
5460
5461 * configure.ac: Remove AC_PREREQ, add missing quoting.
5462 * configure: Re-generate.
5463 * config.in: Re-generate.
5464 * aclocal.m4: Re-generate.
5465
c4eb05ff
SM
54662018-06-18 Simon Marchi <simon.marchi@ericsson.com>
5467
5468 * tracepoint.h (current_traceframe): Remove declaration.
5469
02895270
AH
54702018-06-18 Alan Hayward <alan.hayward@arm.com>
5471
5472 * linux-aarch64-low.c (is_sve_tdesc): New function.
5473 (aarch64_sve_regs_copy_to_regcache): Likewise.
5474 (aarch64_sve_regs_copy_from_regcache): Likewise.
5475 (aarch64_regs_info): Add SVE checks.
5476 (initialize_low_arch): Initialize SVE.
5477
e9902bfc
AH
54782018-06-18 Alan Hayward <alan.hayward@arm.com>
5479
5480 * Makefile.in: Add aarch64-sve-linux-ptrace.c.
5481
fefa175e
AH
54822018-06-11 Alan Hayward <alan.hayward@arm.com>
5483
5484 * linux-aarch64-ipa.c (get_ipa_tdesc): Add null VQ param.
5485 (initialize_low_tracepoint): Likewise
5486 * linux-aarch64-low.c (aarch64_arch_setup): Get VQ.
5487 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Add null VQ
5488 param.
5489 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add VQ
5490 checks.
5491 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Add VQ.
5492
b91ad3ff
AH
54932018-06-11 Alan Hayward <alan.hayward@arm.com>
5494
5495 * server.h (PBUFSIZ): Increase size
5496
f868386e
AH
54972018-06-11 Alan Hayward <alan.hayward@arm.com>
5498
5499 * regcache.c (regcache::raw_compare): New function.
5500 * regcache.h (regcache::raw_compare): New declaration.
5501
9c861883
AH
55022018-06-11 Alan Hayward <alan.hayward@arm.com>
5503
5504 * regcache.c (new_register_cache): Use new.
5505 (free_register_cache): Use delete.
5506 (register_data): Use const.
5507 (supply_register): Move body inside regcache.
5508 (regcache::raw_supply): New override function.
5509 (collect_register): Move body inside regcache.
5510 (regcache::raw_collect): New override function.
5511 (regcache::get_register_status): New override function.
5512 * regcache.h (struct regcache): Inherit from reg_buffer_common.
5513
40591844
TT
55142018-06-09 Tom Tromey <tom@tromey.com>
5515
5516 * event-loop.c (gdb_event, gdb_event_p): Remove typedefs. Don't
5517 declare queue.
5518 (event_queue): Use std::queue.
5519 (gdb_event_xfree): Remove.
5520 (initialize_event_loop, process_event, wait_for_event): Update.
5521
6341380d
SC
55222018-06-08 Stan Cox <scox@redhat.com>
5523
5524 * win32-low.c (win32_create_inferior): last_ptid and last_status
5525 moved to client_state.
5526
03349c93
PA
55272018-06-08 Pedro Alves <palves@redhat.com>
5528
5529 * Makefile.in (GDBREPLAY_OBS): Add common/cleanups.o,
5530 common/common-exceptions.o, common/common-utils.o,
5531 common/errors.o, common/print-utils.o and utils.o.
5532 * gdbreplay.c: Include "common-defs.h" instead of the two
5533 'config.h's here. Don't include stdio.h, errno.h, stdlib.h,
5534 string.h or alloca.h.
5535 (perror_with_name): Delete.
5536 (remote_open): Use xstrdup instead of strdup.
5537 (main): Rename to ...
5538 (captured_main): ... this.
5539 (main): New.
5540
8dcc53b3
TT
55412018-06-08 Tom Tromey <tom@tromey.com>
5542
5543 * linux-low.c (linux_low_read_btrace): Update.
5544
c12a5089
SC
55452018-06-04 Stan Cox <scox@redhat.com>
5546
5547 * server.h (struct client_state): New.
5548 * server.c (cont_thread, general_thread, multi_process)
5549 (report_fork_events, report_vfork_events, report_exec_events)
5550 (report_thread_events, swbreak_feature, hwbreak_feature)
5551 (vCont_supported, disable_randomization, pass_signals)
5552 (program_signals, program_signals_p, last_status, last_ptid, own_buf):
5553 Moved to client_state.
5554 * remote-utils.c (remote_debug, noack_mode)
5555 (transport_is_reliable): Moved to client_state.
5556 * tracepoint.c (current_traceframe): Moved to client_state.
5557
5558 Update all callers.
5559 * server.c, remote-utils.c, tracepoint.c, fork-child.c,
5560 linux-low.c, remote-utils.h, target.c: Use client_state.
5561
122394f1
AH
55622018-05-31 Alan Hayward <alan.hayward@arm.com>
5563
5564 * configure.srv: Add new c/h file.
5565
95228a0d
AH
55662018-05-31 Alan Hayward <alan.hayward@arm.com>
5567
5568 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add
5569 null VQ.
5570
d8dab6c3
MR
55712018-05-25 Maciej W. Rozycki <macro@mips.com>
5572
5573 * gdb.arch/mips-fpregset-core.exp: New test.
5574 * gdb.arch/mips-fpregset-core.c: New test source.
5575
81e25b7c
EK
55762018-05-23 Erik Kurzinger <ekurzinger@nvidia.com>
5577
5578 PR server/23198
5579 * hostio.c (require_int): Do not report overflow for integers
5580 between 0xfffffff and 0x7fffffff.
5581
7e947ad3
MR
55822018-05-22 Maciej W. Rozycki <macro@mips.com>
5583
5584 * linux-mips-low.c [HAVE_PTRACE_GETREGS] (mips_collect_register)
5585 (mips_supply_register): Move outside HAVE_PTRACE_GETREGS.
5586 (mips_collect_ptrace_register, mips_supply_ptrace_register): New
5587 functions.
5588 (the_low_target): Wire them.
5589
1d75a658
PFC
55902018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5591
5592 * linux-ppc-low.c (ppc_fill_vrregset): Add vscr_offset variable.
5593 Set vscr_offset to 0 in little-endian mode and 12 in big-endian
5594 mode. Call collect_register_by_name with vscr using
5595 vscr_offset. Zero-pad vscr and vrsave fields in collector buffer.
5596 (ppc_store_vrregset): Add and set vscr_offset variable as in
5597 ppc_fill_vrregset. Call supply_register_by_name with vscr using
5598 vscr_offset.
5599
d078308a
PFC
56002018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5601
5602 * linux-ppc-low.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
5603 (ppc_arch_setup): Change SIZEOF_VRREGS and SIZEOF_VSXREGS to
5604 PPC_LINUX_SIZEOF_VRREGSET and PPC_LINUX_SIZEOF_VSXREGSET.
5605
7273b5fc
PFC
56062018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5607
5608 * linux-ppc-low.c (ppc_fill_vsxregset): Remove ppc_hwcap check.
5609 (ppc_store_vsxregset): Likewise.
5610 (ppc_fill_vrregset): Likewise.
5611 (ppc_store_vrregset): Likewise.
5612 (ppc_fill_evrregset): Likewise.
5613 (ppc_store_evrregset): Likewise.
5614 (ppc_regsets): Set VSX/VR/EVR regset sizes to 0.
5615 (ppc_arch_setup): Iterate through ppc_regsets and set sizes when
5616 needed.
5617
2e077f5e
PFC
56182018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5619
5620 * linux-ppc-low.c (ppc_arch_setup): Remove code for getting the
5621 wordsize of the inferior. Call ppc_linux_target_wordsize.
5622
bd64614e
PFC
56232018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5624
5625 * configure.srv (srv_tgtobj): Add arch/ppc-linux-common.o.
5626 * Makefile.in (SFILES): Add arch/ppc-linux-common.c.
5627 * linux-ppc-tdesc.h: Rename to linux-ppc-tdesc-init.h.
5628 * linux-ppc-tdesc-init.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
5629 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
5630 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
5631 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
5632 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
5633 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
5634 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
5635 (tdesc_powerpc_e500l): Remove.
5636 * linux-ppc-ipa.c: Include arch/ppc-linux-tdesc.h and
5637 linux-ppc-tdesc-init.h. Don't include linux-ppc-tdesc.h.
5638 * linux-ppc-low.c: Include arch/ppc-linux-common.h,
5639 arch/ppc-linux-tdesc.h, and linux-ppc-tdesc-init.h. Don't include
5640 linux-ppc-tdesc.h.
5641 (ppc_arch_setup): Remove target description matching code. Fill a
5642 ppc_linux_features struct and call ppc_linux_match_description
5643 with it.
5644
75d74cca
MR
56452018-05-22 Maciej W. Rozycki <macro@mips.com>
5646
5647 * linux-mips-low.c (mips_cannot_fetch_register): Return 1 if the
5648 width of the requested register exceeds the width of the
5649 `ptrace' data type.
5650 (mips_cannot_store_register): Likewise.
5651
e4439e43
MR
56522018-05-21 Maciej W. Rozycki <macro@mips.com>
5653
5654 * linux-mips-low.c (mips_fetch_register): New function. Update
5655 preceding comment.
5656 (mips_store_gregset): Supply 0 rather than $restart for $zero.
5657 (the_low_target): Wire `mips_fetch_register'.
5658
55271bf9
JB
56592018-05-10 Joel Brobecker <brobecker@adacore.com>
5660
5661 * lynx-i386-low.c (LYNXOS_178): New macro.
5662 [LYNXOS_178] (usr_fcontext_t): Provide a definition that matches
5663 the layout on LynxOS-178.
5664 (lynx_i386_fill_fpregset, lynx_i386_store_fpregset): Do not
5665 handle floating point registers that are not supported by
5666 LynxOS-178.
5667
1a34f210
TT
56682018-05-10 Tom Tromey <tom@tromey.com>
5669
5670 * configure: Rebuild.
5671
190852c8
JB
56722018-05-10 Joel Brobecker <brobecker@adacore.com>
5673
5674 PR server/23158:
5675 * tdesc.h (init_target_desc) <expedite_regs>: New parameter.
5676 * tdesc.c (init_target_desc) <expedite_regs>: New parameter.
5677 Use it to set the expedite_regs field in the given tdesc.
5678 * x86-tdesc.h: New file.
5679 * linux-aarch64-tdesc.c (aarch64_linux_read_description):
5680 Adjust following the addition of the new expedite_regs parameter
5681 to init_target_desc.
5682 * linux-tic6x-low.c (tic6x_read_description): Likewise.
5683 * linux-x86-tdesc.c: #include "x86-tdesc.h".
5684 (i386_linux_read_description, amd64_linux_read_description):
5685 Adjust following the addition of the new expedite_regs parameter
5686 to init_target_desc.
5687 * lynx-i386-low.c: #include "x86-tdesc.h".
5688 (lynx_i386_arch_setup): Adjust following the addition of the new
5689 expedite_regs parameter to init_target_desc.
5690 * nto-x86-low.c: #include "x86-tdesc.h".
5691 (nto_x86_arch_setup): Adjust following the addition of the new
5692 expedite_regs parameter to init_target_desc.
5693 * win32-i386-low.c: #include "x86-tdesc.h".
5694 (i386_arch_setup): Adjust following the addition of the new
5695 expedite_regs parameter to init_target_desc.
5696
7dbac825
JB
56972018-05-10 Joel Brobecker <brobecker@adacore.com>
5698
5699 PR server/23158:
5700 * win32-low.c (win32_create_inferior): Add call to my_wait
5701 setting last_status global.
5702
906994d9
JB
57032018-05-10 Joel Brobecker <brobecker@adacore.com>
5704
5705 PR server/23158:
5706 * win32-low.c (create_process): Only call gdb_tilde_expand if
5707 inferior_cwd is not NULL.
5708
8ee22052
AB
57092018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
5710
5711 * i387-fp.c (i387_cache_to_xsave): Only write x87 control
5712 registers to the cache if their values have changed.
5713 (i387_xsave_to_cache): Provide default values for x87 control
5714 registers when these features are available, but disabled.
5715 * regcache.c (supply_register_by_name_zeroed): New function.
5716 * regcache.h (supply_register_by_name_zeroed): Declare new
5717 function.
5718
aff689d3
TT
57192018-05-07 Tom Tromey <tom@tromey.com>
5720
5721 * configure: Rebuild.
5722
85e26832
TT
57232018-05-04 Tom Tromey <tom@tromey.com>
5724
5725 * configure: Rebuild.
5726
a3b60e45
JK
57272018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
5728 Pedro Alves <palves@redhat.com>
5729
5730 * linux-aarch64-low.c (aarch64_stopped_data_address):
5731 Likewise.
5732
632e107b
TT
57332018-04-27 Tom Tromey <tom@tromey.com>
5734
5735 * configure: Rebuild.
5736
458412c3
TT
57372018-04-23 Tom Tromey <tom@tromey.com>
5738
5739 * configure: Rebuild.
5740
f31c089e
SM
57412018-04-19 Simon Marchi <simon.marchi@ericsson.com>
5742
5743 * Makefile.in (depcomp): Add "..".
5744 (all_deps_files): New and use it.
5745
b319b098
AH
57462018-04-18 Alan Hayward <alan.hayward@arm.com>
5747
5748 * configure.srv (aarch64*-*-linux*): Don't include xml.
5749 (i[34567]86-*-cygwin*): Likewise.
5750 (i[34567]86-*-linux*): Likewise.
5751 (i[34567]86-*-lynxos*): Likewise.
5752 (i[34567]86-*-mingw32ce*): Likewise.
5753 (i[34567]86-*-mingw*): Likewise.
5754 (i[34567]86-*-nto*): Likewise.
5755 (tic6x-*-uclinux): Likewise.
5756 (x86_64-*-linux*): Likewise.
5757 (x86_64-*-mingw*): Likewise.
5758 (x86_64-*-cygwin*): Likewise.
5759
3b74854b
AH
57602018-04-18 Alan Hayward <alan.hayward@arm.com>
5761
5762 * tdesc.c: Remove xml parameter.
5763
e98577a9
AH
57642018-04-18 Alan Hayward <alan.hayward@arm.com>
5765
5766 * server.c (get_features_xml): Remove cast.
5767 * tdesc.c (void target_desc::accept): Fill in function.
5768 (tdesc_get_features_xml): Remove old xml creation.
5769 (print_xml_feature::visit_pre): Add xml vistor.
5770 * tdesc.h (struct target_desc): Make xmltarget mutable.
5771 (tdesc_get_features_xml): Remove declaration.
5772
d278f585
AH
57732018-04-18 Alan Hayward <alan.hayward@arm.com>
5774
5775 * tdesc.c (tdesc_architecture_name): Add new function.
5776 (tdesc_osabi_name): Likewise.
5777 (tdesc_get_features_xml): Use new functions.
5778
eee8a18d
AH
57792018-04-18 Alan Hayward <alan.hayward@arm.com>
5780
5781 * tdesc.c (tdesc_create_flags): Remove.
5782 (tdesc_add_flag): Likewise.
5783 (tdesc_named_type): Likewise.
5784 (tdesc_create_union): Likewise.
5785 (tdesc_create_struct): Likewise.
5786 (tdesc_create_vector): Likewise.
5787 (tdesc_add_bitfield): Likewise.
5788 (tdesc_add_field): Likewise.
5789 (tdesc_set_struct_size): Likewise.
5790
82ec9bc7
AH
57912018-04-18 Alan Hayward <alan.hayward@arm.com>
5792
5793 * tdesc.c (~target_desc): Remove implictly deleted items.
5794 (init_target_desc): Iterate all features.
5795 (tdesc_get_features_xml): Use vector.
5796 (tdesc_create_feature): Create feature.
5797 * tdesc.h (tdesc_feature) Remove
5798 (target_desc): Add features.
5799
ea3e7d71
AH
58002018-04-18 Alan Hayward <alan.hayward@arm.com>
5801
5802 * Makefile.in: Add common/tdesc.c
5803 * tdesc.c (init_target_desc): init all reg_defs from register
5804 vector.
5805 (tdesc_create_reg): Create tdesc_reg.
5806 * tdesc.h (tdesc_feature): Add register vector.
5807
17d08cd4
SM
58082018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
5809
5810 * tdesc.h (struct target_desc) <features>: Change type to
5811 std::vector<std::string>.
5812 * tdesc.c (target_desc::~target_desc): Adjust to std::vector
5813 changes.
5814 (tdesc_get_features_xml): Likewise.
5815 (tdesc_create_feature): Likewise.
5816
5cd3e386
AH
58172018-03-26 Alan Hayward <alan.hayward@arm.com>
5818
5819 * regcache.c (find_register_by_number): Return a ref.
5820 (find_regno): Use references.
5821 (register_size): Likewise.
5822 (register_data): Likewise.
5823 * tdesc.c (target_desc::~target_desc): Remove free calls.
5824 (target_desc::operator==): Use std::vector compare.
5825 (init_target_desc): Use reference.
5826 (tdesc_create_reg): Use reg constructors.
5827 * tdesc.h (struct target_desc): Replace pointer with object.
5828
dff7492c
AH
58292018-03-23 Alan Hayward <alan.hayward@arm.com>
5830
5831 * regcache.c (find_register_by_number): Make static.
5832 (find_regno): Use find_register_by_number
5833 * regcache.h (struct reg): Remove declaration.
5834
d80e5242
AH
58352018-03-23 Alan Hayward <alan.hayward@arm.com>
5836
5837 * tdesc.c (target_desc::~target_desc): Move to here.
5838 (target_desc::operator==): Likewise.
5839 * tdesc.h (target_desc::~target_desc): Move from here.
5840 (target_desc::operator==): Likewise.
5841
f69c5afb
AA
58422018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
5843
5844 * linux-s390-low.c (s390_get_wordsize): Correct brace style.
5845
ce29f843
AA
58462018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
5847
5848 * linux-s390-ipa.c (get_ipa_tdesc): Add handling for
5849 S390_TDESC_GS.
5850 * linux-s390-low.c (s390_get_ipa_tdesc_idx): Likewise.
5851 (initialize_low_tracepoint): Call init_registers_s390x_gs_linux64
5852 and init_registers_s390_gs_linux64.
5853
c49bd90b
AA
58542018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
5855
5856 * linux-s390-low.c (s390_fill_gs): Remove function.
5857 (s390_fill_gsbc): Remove function.
5858 (s390_regsets): Set fill functions for the guarded storage regsets
5859 to NULL.
5860
7edb9bd3
AA
58612018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
5862
5863 * linux-s390-low.c (s390_get_hwcap): Replace tdesc parameter by
5864 the word size. Add comment.
5865 (s390_get_wordsize): New function.
5866 (s390_arch_setup): No longer select a temporary tdesc to fetch the
5867 pswm with it. Instead, use s390_get_wordsize to determine the
5868 word size first and derive the correct tdesc from that directly.
5869
39be3c7e
SM
58702018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
5871
5872 * Makefile.in: Include silent-rules.mk.
5873 (srcdir, abs_top_srcdir, abs_srcdir, VPATH): Move up.
5874 (COMPILE): Add ECHO_CXX.
5875 (gdbserver$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
5876 (gdbreplay$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
5877 ($(IPA_LIB)): Add SILENCE and ECHO_CXXLD.
5878 (version-generated.c): Add ECHO_GEN.
5879 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN_GENERATED.
5880 (IPAGENT_COMPILE): Add ECHO_CXX.
5881 (%-generated.c): Add ECHO_REGDAT.
5882
3ae9ce5d
TT
58832018-03-14 Tom Tromey <tom@tromey.com>
5884
5885 PR cli/14977:
5886 * ax.c (ax_printf): Special case for NULL.
5887
e6a58aa8
SM
58882018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
5889
5890 * linux-low.c (linux_qxfer_libraries_svr4): Use
5891 xml_escape_text_append.
5892
f6e8a41e
SM
58932018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
5894
5895 * linux-low.c (linux_qxfer_libraries_svr4): Use std::string.
5896
b9671caf
SM
58972018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
5898
5899 * server.c (handle_general_set): Remove unnecessary xstrdup.
5900
e80aaf61
SM
59012018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
5902
5903 * server.c (parse_debug_format_options): Adjust to
5904 delim_string_to_char_ptr_vec changes.
5905 * thread-db.c (thread_db_load_search): Adjust to
5906 dirnames_to_char_ptr_vec changes.
5907
b1223e78
MM
59082018-03-01 Markus Metzger <markus.t.metzger@intel.com>
5909
5910 * target.h (target_enable_btrace, target_disable_btrace)
5911 (target_read_btrace, target_read_btrace_conf): Turn macro into
5912 inline function. Throw error if target method is not defined.
5913 * server.c (handle_qxfer_btrace handle_qxfer_btrace_conf): Remove
5914 check for btrace target method. Be prepared to handle exceptions
5915 from btrace target methods.
5916
81561546
SDJ
59172018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
5918
5919 * server.c (captured_main): Change order of error message printed
5920 when the current working directory cannot be found.
5921
25e3c82c
SDJ
59222018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
5923
5924 * server.c: Include "filenames.h" and "pathstuff.h".
5925 (program_name): Delete variable.
5926 (program_path): New anonymous class.
5927 (get_exec_wrapper): Use "program_path" instead of
5928 "program_name".
5929 (handle_v_run): Likewise.
5930 (captured_main): Likewise.
5931 (process_serial_event): Likewise.
5932
b4987c95
SDJ
59332018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
5934
5935 * Makefile.in (SFILES): Add "$(srcdir)/common/pathstuff.c".
5936 (OBJS): Add "pathstuff.o".
5937 * server.c (current_directory): New global variable.
5938 (captured_main): Initialize "current_directory".
5939
f46cd62a
AH
59402018-02-26 Alan Hayward <alan.hayward@arm.com>
5941
5942 * tdesc.c: Use common/tdesc.h.
5943 * tdesc.h: Likewise.
5944
a543c5ca
AH
59452018-02-20 Alan Hayward <alan.hayward@arm.com>
5946 Simon Marchi <simon.marchi@ericsson.com>
5947
5948 * Makefile.in: Switch order of make rules.
5949
b5884fa7
AH
59502018-02-19 Alan Hayward <alan.hayward@arm.com>
5951
5952 * Makefile.in: Add common directory in build.
5953 * configure.ac: Add common reference.
5954 * configure: Regenerate.
5955
de6242d3
MM
59562018-02-09 Markus Metzger <markus.t.metzger@intel.com>
5957
5958 * linux-low.c (linux_target_ops): Remove linux_supports_btrace.
5959 * nto-low.c (nto_target_ops): Remove NULL for supports_btrace.
5960 * spu-low.c (spu_target_ops): Likewise.
5961 * win32-low.c (win32_target_ops): Likewise.
5962 * server.c (supported_btrace_packets): Report packets unconditionally.
5963 * target.h (target_ops) <supports_btrace>: Remove.
5964 (target_supports_btrace): Remove.
5965
9ee23a85
MM
59662018-02-09 Markus Metzger <markus.t.metzger@intel.com>
5967
5968 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt)
5969 (handle_btrace_disable): Change return type to void. Use exceptions
5970 to report errors.
5971 (handle_btrace_general_set): Catch exception and copy message to
5972 return message.
5973
8ce47547
TT
59742018-02-08 Tom Tromey <tom@tromey.com>
5975
5976 * linux-low.c (install_software_single_step_breakpoints): Use
5977 make_scoped_restore.
5978 * inferiors.c (make_cleanup_restore_current_thread): Remove.
5979 (do_restore_current_thread_cleanup): Remove.
5980 * gdbthread.h (make_cleanup_restore_current_thread): Don't
5981 declare.
5982
45dd3607
TT
59832018-02-08 Tom Tromey <tom@tromey.com>
5984
5985 * mem-break.c (set_raw_breakpoint_at): Use
5986 gdb::unique_xmalloc_ptr.
5987
e671cd59
PA
59882018-01-30 Pedro Alves <palves@redhat.com>
5989
5990 PR gdb/13211
5991 * target.c (target_terminal::terminal_state): Rename to ...
5992 (target_terminal::m_terminal_state): ... this.
5993
a0aad537
JC
59942018-01-19 James Clarke <jrtc27@jrtc27.com>
5995
5996 * linux-low.c (handle_extended_wait): Surround call to
5997 thread_db_notice_clone with #ifdef USE_THREAD_DB.
5998
4d9b86e1
SM
59992018-01-17 Simon Marchi <simon.marchi@ericsson.com>
6000
6001 * linux-low.c (attach_proc_task_lwp_callback): Adjust to
6002 linux_ptrace_attach_fail_reason_string now returning an
6003 std::string.
6004 (linux_attach): Likewise.
6005 * thread-db.c (attach_thread): Likewise.
6006
f517c180
EA
60072018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
6008
6009 PR gdb/21559
6010 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
6011 checking for fs_base/gs_base fields in struct user_regs_struct.
6012 * configure: Regenerate.
6013
9a70f35c
YQ
60142018-01-16 Yao Qi <yao.qi@linaro.org>
6015
6016 PR gdb/18749
6017 * linux-low.c (fetch_register): Call supply_register instead of
6018 error.
6019
605fd3c6
YQ
60202018-01-08 Yao Qi <yao.qi@linaro.org>
6021 Simon Marchi <simon.marchi@ericsson.com>
6022
6023 * Makefile.in (OBS): Remove selftest.o.
6024 * configure.ac: Set srv_selftest_objs if $development is true.
6025 (GDBSERVER_DEPFILES): Append $srv_selftest_objs.
6026 * configure: Re-generated.
6027 * server.c (captured_main): Wrap variable selftest_filter with
6028 GDB_SELF_TEST.
6029
2cc05030
SM
60302018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
6031
6032 * server.c (parse_debug_format_options): Return std::string.
6033 (handle_monitor_command, captured_main): Adjust.
6034
e379cee6
PA
60352018-01-05 Pedro Alves <palves@redhat.com>
6036
6037 PR gdb/18653
6038 * server.c (captured_main): Pass quiet=false to
6039 save_original_signals_state.
6040
82e1e79a
JB
60412018-01-01 Joel Brobecker <brobecker@adacore.com>
6042
6043 * gdbreplay.c (gdbreplay_version): Update copyright year in
6044 version message.
6045 * server.c (gdbserver_version): Likewise.
6046
8e481c3b
TT
60472017-12-08 Tom Tromey <tom@tromey.com>
6048
6049 * ax.c (ax_printf): Update.
6050
a8806230
YQ
60512017-12-07 Yao Qi <yao.qi@linaro.org>
6052
6053 * linux-aarch64-ipa.c (initialize_low_tracepoint): Call
6054 aarch64_linux_read_description.
6055 * linux-amd64-ipa.c (idx2mask): New array.
6056 (get_ipa_tdesc): Move idx2mask out.
6057 (initialize_low_tracepoint): Initialize target descriptions.
6058 * linux-i386-ipa.c (idx2mask): New array.
6059 (get_ipa_tdesc): Move idx2mask out.
6060 (initialize_low_tracepoint): Initialize target descriptions.
6061
d4a0e8b5
SM
60622017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
6063
6064 * tdesc.c (struct tdesc_type): Change return type.
6065 (tdesc_add_flag): Change parameter type.
6066 (tdesc_add_bitfield): Likewise.
6067 (tdesc_add_field): Likewise.
6068 (tdesc_set_struct_size): Likewise.
6069
798a7429
SM
60702017-12-05 Simon Marchi <simon.marchi@ericsson.com>
6071
6072 * regcache.c (registers_to_string): Remove unused variable.
6073
c0e15c9b
SM
60742017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6075
6076 * inferiors.c (for_each_inferior_with_data): Remove.
6077 * inferiors.h (for_each_inferior_with_data): Remove.
6078 * server.c (handle_qxfer_threads_worker): Change parameter type.
6079 (handle_qxfer_threads_proper): Use for_each_thread.
6080
f0045347
SM
60812017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6082
6083 * inferiors.c (for_each_inferior): Remove.
6084 (clear_inferiors): Use for_each_thread.
6085 * inferiors.h (for_each_inferior): Remove.
6086 * linux-low.c (linux_wait_for_event_filtered): Use
6087 for_each_thread.
6088 (linux_stabilize_threads): Likewise.
6089 * regcache.c (regcache_release): Likewise.
6090 * server.c (gdb_wants_all_threads_stopped): Likewise.
6091 (clear_pending_status_callback): Remove.
6092 (handle_status): Use for_each_thread.
6093 (captured_main): Likewise.
6094 * win32-low.c (child_init_thread_list): Likewise.
6095 (win32_clear_inferiors): Likewise.
6096 (fake_breakpoint_event): Likewise.
6097
9521758b
SM
60982017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6099
6100 * inferiors.h (find_inferior): Remove.
6101 * inferiors.c (find_inferior): Remove.
6102
8f86d7aa
SM
61032017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6104
6105 * linux-low.c (resume_status_pending_p): Update comment.
6106 (need_step_over_p): Update comment.
6107
e2b44075
SM
61082017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6109
6110 * linux-low.c (proceed_one_lwp): Return void, change parameter
6111 type.
6112 (unsuspend_and_proceed_one_lwp): Likewise.
6113 (proceed_all_lwps): Use for_each_thread.
6114 (unstop_all_lwps): Likewise.
6115
c80825ff
SM
61162017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6117
6118 * linux-low.c (linux_resume_one_thread): Return void, take
6119 parameter directly.
6120 (linux_resume): Use for_each_thread.
6121
df3e4dbe
SM
61222017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6123
6124 * linux-low.c (send_sigstop_callback): Return void, change
6125 parameter type. Rename to...
6126 (send_sigstop): ... this.
6127 (suspend_and_send_sigstop_callback): Return void, change parameter
6128 type. Rename to...
6129 (suspend_and_send_sigstop): ... this.
6130 (stop_all_lwps): Use for_each_thread.
6131
5a6b0a41
SM
61322017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6133
6134 * linux-low.c (lwp_running): Return bool, remove unused
6135 argument.
6136 (linux_stabilize_threads): Use find_thread.
6137
39a64da5
SM
61382017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6139
6140 * linux-low.c (select_singlestep_lwp_callback): Remove.
6141 (count_events_callback): Remove.
6142 (select_event_lwp_callback): Remove.
6143 (select_event_lwp): Use find_thread/for_each_thread.
6144
a1385b7b
SM
61452017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6146
6147 * linux-low.c (not_stopped_callback): Return bool, take filter
6148 argument directly.
6149 (linux_wait_for_event_filtered): Use find_thread.
6150 (linux_wait_1): Likewise.
6151
454296a2
SM
61522017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6153
6154 * linux-low.c (same_lwp): Remove.
6155 (find_lwp_pid): Use find_thread.
6156
6b2a85da
SM
61572017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6158
6159 * linux-low.c (delete_lwp_callback): Remove.
6160 (linux_mourn): Use for_each_thread.
6161
798a38e8
SM
61622017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6163
6164 * linux-low.c (linux_detach_lwp_callback): Return void, remove
6165 args parameter, don't check for pid.
6166 (linux_detach): Use for_each_thread.
6167
e4eb0dec
SM
61682017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6169
6170 * linux-low.c (struct counter): Remove.
6171 (second_thread_of_pid_p): Remove.
6172 (last_thread_of_process_p): Use find_thread.
6173
83e1b6c1
SM
61742017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6175
6176 * inferiors.c (find_inferior_in_random): Remove.
6177 * inferiors.h (find_inferior_in_random): Remove.
6178 * linux-low.c (status_pending_p_callback): Return bool, accept
6179 parameter ptid directly.
6180 (linux_wait_for_event_filtered): Use find_thread_in_random.
6181 (linux_wait_1): Likewise.
6182
8dc7b443
SM
61832017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6184
6185 * inferiors.c (find_inferior_id): Remove.
6186 (find_thread_ptid): Move implemention from find_inferior_id to
6187 here.
6188 * inferiors.h (find_inferior_id): Remove.
6189 * server.c (handle_status): Use find_thread_ptid.
6190 (process_serial_event): Likewise.
6191 * thread-db.c (find_one_thread): Likewise.
6192 (thread_db_thread_handle): Likewise.
6193 * win32-low.c (thread_rec): Likewise.
6194 (child_delete_thread): Likewise.
6195 (win32_thread_alive): Likewise.
6196 (get_child_debug_event): Likewise.
6197
da25033c
SM
61982017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6199
6200 * linux-mips-low.c (update_watch_registers_callback): Return
6201 void, remove pid_p parameter, don't check for pid.
6202 (mips_insert_point, mips_remove_point): Use for_each_thread.
6203
c91bb56b
SM
62042017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6205
6206 * lynx.low (lynx_delete_thread_callback): Remove.
6207 (lynx_mourn): Use for_each_thread.
6208
634a3254
SM
62092017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6210
6211 * regcache.c (regcache_invalidate_one): Remove.
6212 (regcache_invalidate_pid): use for_each_thread.
6213
41272101
TT
62142017-11-26 Tom Tromey <tom@tromey.com>
6215
6216 * linux-low.c (linux_create_inferior): Update.
6217
f5291a6f
UW
62182017-11-24 Ulrich Weigand <uweigand@de.ibm.com>
6219
6220 * spu-low.c (spu_create_inferior): Fix typo in argument name.
6221
6654d750
AH
62222017-11-24 Alan Hayward <alan.hayward@arm.com>
6223
6224 * configure.srv: Add linux-aarch64-tdesc-selftest.o.
6225 * linux-aarch64-low.c (initialize_low_arch): Call init func.
6226 * linux-aarch64-tdesc-selftest.c: New file.
6227 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
6228
62292017-11-24 Alan Hayward <alan.hayward@arm.com>
6230
6231 * configure.srv: Add new file.
6232 * linux-aarch64-low.c (initialize_low_arch): Call init func.
6233 * linux-aarch64-tdesc-selftest.c: New file.
6234 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
6235
49bdb7ee
AH
62362017-11-24 Alan Hayward <alan.hayward@arm.com>
6237
6238 * linux-aarch64-ipa.c (initialize_low_tracepoint): Remove init.
6239 * linux-aarch64-low.c (initialize_low_arch): Remove init.
6240 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add init.
6241
d6d7ce56
AH
62422017-11-24 Alan Hayward <alan.hayward@arm.com>
6243
6244 * configure.srv: Add new files.
6245 * linux-aarch64-ipa.c (get_ipa_tdesc): Call
6246 aarch64_linux_read_description.
6247 * linux-aarch64-low.c (aarch64_linux_read_description):
6248 Merge with aarch64_arch_setup.
6249 (aarch64_arch_setup): Call aarch64_linux_read_description.
6250 * linux-aarch64-tdesc.c: New file.
6251 * linux-aarch64-tdesc.h: New file.
6252
506fe5f4
YQ
62532017-11-24 Yao Qi <yao.qi@linaro.org>
6254
6255 * configure.srv: Set $srv_regobj for tic6x-linux.
6256 * linux-tic6x-low.c: Include "arch/tic6x.h" and "tdesc.h".
6257 (tic6x_read_description): Move some code to tic6x_arch_setup.
6258 (tic6x_tdesc_test): New function.
6259 (initialize_low_arch): Call selftests::register_test.
6260
29f9a567
YQ
62612017-11-22 Yao Qi <yao.qi@linaro.org>
6262
6263 * remote-utils.c (prepare_resume_reply): Use memcpy.
6264
578290ec
SM
62652017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6266
6267 * linux-low.c (kill_one_lwp_callback): Return void, take
6268 argument directly, don't filter on pid.
6269 (linux_kill): Use for_each_thread.
6270
eca55aec
SM
62712017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6272
6273 * linux-low.c (need_step_over_p): Return bool, remove dummy
6274 argument.
6275 (linux_resume, proceed_all_lwps): Use find_thread.
6276
25c28b4d
SM
62772017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6278
6279 * linux-low.c (resume_status_pending_p): Return bool, remove
6280 flag_p argument.
6281 (linux_resume): Use find_thread.
6282
5fdda392
SM
62832017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6284
6285 * linux-low.c (struct thread_resume_array): Remove.
6286 (linux_set_resume_request): Return void, take arguments
6287 directly.
6288 (linux_resume): Use for_each_thread.
6289
fcb056a5
SM
62902017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6291
6292 * linux-low.c (stuck_in_jump_pad_callback): Change prototype,
6293 return bool, remove data argument.
6294 (linux_stabilize_threads): Use find_thread.
6295
139720c5
SM
62962017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6297
6298 * linux-low.c (unsuspend_one_lwp): Remove.
6299 (unsuspend_all_lwps): Use for_each_thread, inline code from
6300 unsuspend_one_lwp.
6301
6d1e5673
SM
63022017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6303
6304 * gdbthread.h (find_thread): Add overload with ptid_t filter.
6305 * linux-low.c (struct iterate_over_lwps_args): Remove.
6306 (iterate_over_lwps_filter): Remove.
6307 (iterate_over_lwps): Use find_thread.
6308
bbf550d5
SM
63092017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6310
6311 * linux-low.c (reset_lwp_ptrace_options_callback): Remove.
6312 (linux_handle_new_gdb_connection): Use for_each_thread, inline
6313 code from reset_lwp_ptrace_options_callback.
6314
00192f77
SM
63152017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6316
6317 * linux-arm-low.c (struct update_registers_data): Remove.
6318 (update_registers_callback): Return void, take arguments
6319 directly, don't check thread's pid.
6320 (arm_insert_point, arm_remove_point): Use for_each_thread.
6321
2bee2b6c
SM
63222017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6323
6324 * win32-low.c (continue_one_thread): Return void, take argument
6325 directly.
6326 (child_continue): Use for_each_thread.
6327
0b360f19
SM
63282017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6329
6330 * win32-i386-low.c (update_debug_registers_callback): Rename
6331 to ...
6332 (update_debug_registers): ... this, return void, remove pid_p arg.
6333 (x86_dr_low_set_addr, x86_dr_low_set_control): Use for_each_thread.
6334
f27866ba
SM
63352017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
6336
6337 * inferiors.h (struct process_info): Add constructor, initialize
6338 fields..
6339 <syscalls_to_catch>: Change type to std::vector<int>.
6340 * inferiors.c (add_process): Allocate process_info with new.
6341 (remove_process): Free process_info with delete.
6342 * linux-low.c (handle_extended_wait): Adjust.
6343 (gdb_catching_syscalls_p, gdb_catch_this_syscall_p): Adjust.
6344 * server.c (handle_general_set): Adjust.
6345
e849ea89
PA
63462017-11-16 Pedro Alves <palves@redhat.com>
6347
6348 * remote-utils.c (remote_close): Block SIGIO signals instead of
6349 uninstalling the SIGIO handler.
6350
1d0aa65c
AH
63512017-11-16 Alan Hayward <alan.hayward@arm.com>
6352
6353 * tdesc.c (tdesc_get_features_xml): Allow null osabi.
6354
3491a34c
YQ
63552017-11-16 Yao Qi <yao.qi@linaro.org>
6356
6357 * linux-tic6x-low.c (tic6x_fill_gregset): Cast buf.
6358 (tic6x_store_gregset): Likewise.
6359 (tic6x_usrregs_info): Move it up.
6360
a602f924
AH
63612017-11-15 Alan Hayward <alan.hayward@arm.com>
6362
6363 * Makefile.in: Update arch rules.
6364 * configure.srv: Explicitly mark arch/ files.
6365
5616b6c3
AS
63662017-11-13 Andreas Schwab <schwab@suse.de>
6367
6368 * linux-m68k-low.c (m68k_supports_hardware_single_step): New
6369 function.
6370 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6371
d1928160
PA
63722017-11-06 Pedro Alves <palves@redhat.com>
6373
6374 * config.in, configure: Regenerate.
6375
bac608e7
SM
63762017-10-27 Simon Marchi <simon.marchi@ericsson.com>
6377
6378 * target.c (struct thread_search): Remove.
6379 (thread_search_callback): Remove.
6380 (prepare_to_access_memory): Use for_each_thread instead of
6381 find_inferior. Inline code from thread_search_callback.
6382
eaddb425
SM
63832017-10-27 Simon Marchi <simon.marchi@ericsson.com>
6384
6385 * server.c (struct visit_actioned_threads_data): Remove.
6386 (visit_actioned_threads): Change prototype to take arguments
6387 directly.
6388 (resume): Use find_thread instead of find_inferior.
6389
99078d34
SM
63902017-10-27 Simon Marchi <simon.marchi@ericsson.com>
6391
6392 * server.c (queue_stop_reply_callback): Change prototype, return
6393 void.
6394 (find_status_pending_thread_callback): Remove.
6395 (handle_status): Replace find_inferior with find_thread and
6396 for_each_thread.
6397
cc628f3d
AH
63982017-10-25 Alan Hayward <alan.hayward@arm.com>
6399
6400 * linux-aarch64-low.c (aarch64_fill_gregset): Replace defines
6401 with REGNO.
6402 (aarch64_store_gregset): Likewise.
6403 (aarch64_fill_fpregset): Likewise.
6404 (aarch64_store_fpregset): Likewise.
6405
4d3bb80e
SM
64062017-10-21 Simon Marchi <simon.marchi@ericsson.com>
6407
6408 * gdbthread.h (find_thread, for_each_thread): New functions.
6409 * inferiors.c (thread_of_pid): Remove.
6410 (find_any_thread_of_pid): Use find_thread.
6411 * linux-low.c (num_lwps): Use for_each_thread.
6412
7a7cdfa0
YQ
64132017-10-17 Yao Qi <yao.qi@linaro.org>
6414
6415 * Makefile.in: Remove one rule.
6416 * configure.srv: Rename aarch64-insn.o with arch/aarch64-insn.o.
6417
e675d170
YQ
64182017-10-17 Yao Qi <yao.qi@linaro.org>
6419
6420 * configure.srv: Rename arm-linux.o with arch/arm-linux.o.
6421 Rename arm-get-next-pcs.o with arch/arm-get-next-pcs.o.
6422
7eb4e0f9
YQ
64232017-10-17 Yao Qi <yao.qi@linaro.org>
6424
6425 * configure.srv: Rename arm.o with arch/arm.o.
6426
60d6cfc9
YQ
64272017-10-17 Yao Qi <yao.qi@linaro.org>
6428
6429 * Makefile.in (CONFIG_SRC_SUBDIR): New variable.
6430 (clean): Remove .o files in CONFIG_SRC_SUBDIR.
6431 (distclean): Remove DEPDIR in CONFIG_SRC_SUBDIR.
6432 (arch-i386.o, arch-amd64.o): Remove rules.
6433 (arch/%.o): New rule.
6434 Update POSTCOMPILE and COMPILE.pre.
6435 * configure.ac: Invoke AC_CONFIG_COMMANDS.
6436 * configure: Re-generated.
6437 * configure.srv: Replace arch-i386.o with arch/i386.o.
6438 Replace arch-amd64.o with arch/amd64.o.
6439
5bfda255
YQ
64402017-10-16 Yao Qi <yao.qi@linaro.org>
6441
6442 * configure: Regenerated.
6443
9c80ecd6
SM
64442017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
6445
6446 * inferiors.h: (struct inferior_list): Remove.
6447 (struct inferior_list_entry); Remove.
6448 (add_inferior_to_list, clear_inferior_list, one_inferior_p,
6449 A_I_NEXT, ALL_INFERIORS_TYPE, ALL_INFERIORS, remove_inferior,
6450 get_first_inferior): Remove.
6451 (for_each_inferior, for_each_inferior_with_data, find_inferior,
6452 find_inferior_id, find_inferior_in_random): Change signature.
6453 * inferiors.c (all_threads): Change type to
6454 std::list<thread_info *>.
6455 (get_thread): Remove macro.
6456 (find_inferior, find_inferior_id): Change signature, implement
6457 using find_thread.
6458 (find_inferior_in_random): Change signature, implement using
6459 find_thread_in_random.
6460 (for_each_inferior, for_each_inferior_with_data): Change
6461 signature, implement using for_each_thread.
6462 (add_inferior_to_list, remove_inferior): Remove.
6463 (add_thread, get_first_thread, thread_of_pid,
6464 find_any_thread_of_pid, free_one_thread, remove_thread): Update.
6465 (get_first_inferior, one_inferior_p, clear_inferior_list):
6466 Remove.
6467 (clear_inferiors, get_thread_process): Update.
6468 * gdbthread.h: Include <list>.
6469 (struct thread_info) <entry>: Remove field.
6470 <id>: New field.
6471 (all_threads): Change type to std::list<thread_info *>.
6472 (get_first_inferior): Add doc.
6473 (find_thread, for_each_thread, find_thread_in_random): New
6474 functions.
6475 (current_ptid, pid_of, ptid_of, lwpid_of): Update.
6476 * linux-arm-low.c (update_registers_callback): Update.
6477 * linux-low.c (second_thread_of_pid_p): Update.
6478 (kill_one_lwp_callback, linux_detach_lwp_callback,
6479 delete_lwp_callback, status_pending_p_callback, same_lwp,
6480 find_lwp_pid, num_lwps, iterate_over_lwps_filter,
6481 iterate_over_lwps, not_stopped_callback,
6482 resume_stopped_resumed_lwps, count_events_callback,
6483 select_singlestep_lwp_callback, select_event_lwp_callback,
6484 unsuspend_one_lwp, linux_wait_1, send_sigstop_callback,
6485 suspend_and_send_sigstop_callback, wait_for_sigstop,
6486 stuck_in_jump_pad_callback, move_out_of_jump_pad_callback,
6487 lwp_running, linux_set_resume_request, resume_status_pending_p,
6488 need_step_over_p, start_step_over, linux_resume_one_thread,
6489 proceed_one_lwp, unsuspend_and_proceed_one_lwp,
6490 reset_lwp_ptrace_options_callback): Update.
6491 * linux-mips-low.c (update_watch_registers_callback): Update.
6492 * regcache.c (regcache_invalidate_one, regcache_invalidate):
6493 Update.
6494 (free_register_cache_thread_one): Remove.
6495 (regcache_release): Update.
6496 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt,
6497 handle_qxfer_threads_worker): Update.
6498 (handle_query): Update, use list iterator.
6499 (visit_actioned_threads, handle_pending_status,
6500 queue_stop_reply_callback, gdb_wants_all_threads_stopped,
6501 clear_pending_status_callback, set_pending_status_callback,
6502 find_status_pending_thread_callback, handle_status,
6503 process_serial_event): Update.
6504 * target.c (thread_search_callback): Update.
6505 * thread-db.c (thread_db_get_tls_address): Update.
6506 * tracepoint.c (tracepoint_finished_step, tracepoint_was_hit):
6507 Update.
6508 * win32-i386-low.c (update_debug_registers_callback): Update.
6509 * win32-low.c (delete_thread_info, child_delete_thread,
6510 continue_one_thread, suspend_one_thread,
6511 get_child_debug_event): Adjust.
6512
9179355e
SM
65132017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
6514
6515 * gdbthread.h (ptid_of, pid_of, lwpid_of): New functions.
6516 * inferiors.h: Include <list>.
6517 (struct process_info) <entry>: Remove field.
6518 <pid>: New field.
6519 (pid_of): Change macro to function.
6520 (ptid_of, lwpid_of): Remove macro.
6521 (all_processes): Change type to std::list<process_info *>.
6522 (ALL_PROCESSES): Remove macro.
6523 (for_each_process, find_process): New function.
6524 * inferiors.c (all_processes): Change type to
6525 std::list<process_info *>.
6526 (find_thread_process): Adjust.
6527 (add_process): Likewise.
6528 (remove_process): Likewise.
6529 (find_process_pid): Likewise.
6530 (get_first_process): Likewise.
6531 (started_inferior_callback): Remove.
6532 (have_started_inferiors_p): Adjust.
6533 (attached_inferior_callback): Remove.
6534 (have_attached_inferiors_p): Adjust.
6535 * linux-low.c (check_zombie_leaders): Likewise.
6536 * linux-x86-low.c (x86_arch_setup_process_callback): Remove.
6537 (x86_linux_update_xmltarget): Adjust.
6538 * server.c (handle_query): Likewise.
6539 (gdb_reattached_process): Remove.
6540 (handle_status): Adjust.
6541 (kill_inferior_callback): Likewise.
6542 (detach_or_kill_inferior): Remove.
6543 (print_started_pid): Likewise.
6544 (print_attached_pid): Likewise.
6545 (detach_or_kill_for_exit): Update.
6546 (process_serial_event): Likewise.
6547 * linux-arm-low.c (arm_new_fork): Likewise.
6548
c9cb8905
SM
65492017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
6550
6551 * dll.h: Include <list>.
6552 (struct dll_info): Add constructor.
6553 <entry>: Remove field.
6554 (all_dlls): Change type to std::list<dll_info>.
6555 * dll.c: Include <algorithm>.
6556 (get_dll): Remove macro.
6557 (all_dlls): Change type to std::list<dll_info *>.
6558 (free_one_dll): Remove.
6559 (match_dll): Likewise.
6560 (loaded_dll): Adjust.
6561 (unloaded_dll): Adjust to all_dlls type change, use
6562 std::find_if. Inline code from match_dll.
6563 (clear_dlls): Adjust to all_dlls type change.
6564 * server.c (emit_dll_description): Remove.
6565 (handle_qxfer_libraries): Adjust to all_dlls type change,
6566 integrate emit_dll_description's functionality.
6567
04ec7890
SM
65682017-10-12 Simon Marchi <simon.marchi@ericsson.com>
6569
6570 * linux-low.h (struct linux_target_ops) <delete_process>: New
6571 field.
6572 * linux-low.c (linux_mourn): Call the_low_target.delete_process.
6573 * linux-aarch64-low.c (aarch64_linux_delete_process): New.
6574 (struct linux_target_ops): Add delete_process callback.
6575 * linux-arm-low.c (arm_delete_process): New.
6576 (struct linux_target_ops): Add delete_process callback.
6577 * linux-bfin-low.c (struct linux_target_ops): Likewise.
6578 * linux-crisv32-low.c (struct linux_target_ops): Likewise.
6579 * linux-m32r-low.c (struct linux_target_ops): Likewise.
6580 * linux-mips-low.c (mips_linux_delete_process): New.
6581 (struct linux_target_ops): Add delete_process callback.
6582 * linux-ppc-low.c (struct linux_target_ops): Likewise.
6583 * linux-s390-low.c (struct linux_target_ops): Likewise.
6584 * linux-sh-low.c (struct linux_target_ops): Likewise.
6585 * linux-tic6x-low.c (struct linux_target_ops): Likewise.
6586 * linux-tile-low.c (struct linux_target_ops): Likewise.
6587 * linux-x86-low.c (x86_linux_delete_process): New.
6588 (struct linux_target_ops): Add delete_process callback.
6589 * linux-xtensa-low.c (struct linux_target_ops): Likewise.
6590
466eecee
SM
65912017-10-12 Simon Marchi <simon.marchi@ericsson.com>
6592
6593 * linux-aarch64-low.c (the_low_target): Add thread delete
6594 callback.
6595 * linux-arm-low.c (arm_delete_thread): New function.
6596 (the_low_target): Add thread delete callback.
6597 * linux-bfin-low.c (the_low_target): Likewise.
6598 * linux-crisv32-low.c (the_low_target): Likewise.
6599 * linux-low.c (delete_lwp): Invoke delete_thread callback if
6600 set.
6601 * linux-low.h (struct linux_target_ops) <delete_thread>: New
6602 field.
6603 * linux-m32r-low.c (the_low_target): Add thread delete callback.
6604 * linux-mips-low.c (mips_linux_delete_thread): New function.
6605 (the_low_target): Add thread delete callback.
6606 * linux-ppc-low.c (the_low_target): Likewise.
6607 * linux-s390-low.c (the_low_target): Likewise.
6608 * linux-sh-low.c (the_low_target): Likewise.
6609 * linux-tic6x-low.c (the_low_target): Likewise.
6610 * linux-tile-low.c (the_low_target): Likewise.
6611 * linux-x86-low.c (the_low_target): Likewise.
6612 * linux-xtensa-low.c (the_low_target): Likewise.
6613
b79f7801
YZ
66142017-10-06 Yuanhui Zhang <asmwarrior@gmail.com>
6615
6616 * win32-low.c: Include "common-inferior.h".
6617
bc3b087d
SDJ
66182017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
6619
6620 * inferiors.c (set_inferior_cwd): New function.
6621 * server.c (handle_general_set): Handle QSetWorkingDir packet.
6622 (handle_query): Inform that QSetWorkingDir is supported.
6623 * win32-low.c (create_process): Pass the inferior's cwd to
6624 CreateProcess.
6625
d092c5a2
SDJ
66262017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
6627
6628 * inferiors.c (current_inferior_cwd): New global variable.
6629 (get_inferior_cwd): New function.
6630 * inferiors.h (struct process_info) <cwd>: New field.
6631
7da0a886
SDJ
66322017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
6633
6634 * Makefile.in (SFILES): Add $(srcdir)/common/gdb_tilde_expand.c.
6635 (OBS): Add gdb_tilde_expand.o.
6636
289a6840
SM
66372017-10-02 Simon Marchi <simon.marchi@ericsson.com>
6638
6639 * lynx-i386-low.c (lynx_i386_arch_setup): Call init_target_desc.
6640 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
6641
256642e8
PA
66422017-09-29 Pedro Alves <palves@redhat.com>
6643
6644 * ax.c (gdb_parse_agent_expr): Constify.
6645 * ax.h (gdb_parse_agent_expr): Constify.
6646 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
6647 Constify.
6648 * mem-break.h (add_breakpoint_condition, add_breakpoint_commands): Constify.
6649 * remote-utils.c (hex_or_minus_one, read_ptid): Constify.
6650 * remote-utils.h (read_ptid): Constify.
6651 * server.c (handle_qxfer_exec_file, handle_query, handle_v_cont)
6652 (process_point_options, process_serial_event): Constify.
6653 * tracepoint.c (add_tracepoint_action, cmd_qtdp, cmd_qtdpsrc)
6654 (cmd_qtdv, cmd_qtenable_disable, cmd_qtro, cmd_qtframe, cmd_qtp)
6655 (cmd_qtbuffer): Constify.
6656
5b9ca4d4
PA
66572017-09-29 Pedro Alves <palves@redhat.com>
6658
6659 * proc-service.c (ps_pdread): Return PS_ERR if reading memory
6660 fails.
6661
94c207e0
PA
66622017-09-29 Pedro Alves <palves@redhat.com>
6663
6664 * linux-low.c (handle_extended_wait): Pass parent thread instead
6665 of process to thread_db_notice_clone.
6666 * linux-low.h (thread_db_notice_clone): Replace parent process
6667 parameter with parent thread parameter.
6668 * thread-db.c (find_one_thread): Add comment.
6669 (thread_db_notice_clone): Replace parent process parameter with
6670 parent thread parameter. Temporarily switch to the parent thread.
6671
75352e28
SDJ
66722017-09-26 Sergio Durigan Junior <sergiodj@redhat.com>
6673
6674 * gdbthread.h: Include "common-gdbthread.h".
6675 * inferiors.c (switch_to_thread): Use "gdb_assert" instead of
6676 "if" when validating the ptid.
6677 * remote-utils.c: Include "gdbthread.h".
6678 (prepare_resume_reply): Use "switch_to_thread".
6679 * target.c (done_accessing_memory): Likewise.
6680
ad339634
AA
66812017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
6682
6683 * configure.srv (s390*-*-linux*): Add s390-gs-linux64.o and
6684 s390x-gs-linux64.o to srv_regobj. Add s390-gs-linux64.xml,
6685 s390x-gs-linux64.xml, s390-gs.xml, and s390-gsbc.xml to
6686 srv_xmlfiles. Add s390-gs-linux64-ipa.o and
6687 s390x-gs-linux64-ipa.o to ipa_obj.
6688 * linux-s390-low.c (HWCAP_S390_GS): New define.
6689 (s390_fill_gs, s390_store_gs, s390_fill_gsbc, s390_store_gsbc):
6690 New functions.
6691 (s390_regsets): Add regsets for NT_S390_GS_CB and NT_S390_GS_BC.
6692 (s390_arch_setup): Check for guarded-storage support and choose
6693 appropriate tdesc.
6694 (initialize_low_arch): Invoke init_registers_s390_gs_linux64 and
6695 init_registers_s390x_gs_linux64.
6696 * linux-s390-tdesc.h (enum s390_linux_tdesc) <S390_TDESC_GS>: New
6697 enum value.
6698 (init_registers_s390x_gs_linux64, tdesc_s390x_gs_linux64)
6699 (init_registers_s390_gs_linux64, tdesc_s390_gs_linux64): Declare.
6700
cc4d742f
SM
67012017-09-22 Simon Marchi <simon.marchi@ericsson.com>
6702
6703 * win32-i386-low.c (i386_arch_setup): Call init_target_desc.
6704
f6327dcb
KB
67052017-09-21 Kevin Buettner <kevinb@redhat.com>
6706
6707 * linux-low.h (struct lwp_info): Add new field, thread_handle.
6708 (thread_db_thread_handle): Declare.
6709 * linux-low.c (linux_target_ops): Initialize thread_handle.
6710 * server.c (handle_qxfer_threads_worker): Add support for
6711 "handle" attribute.
6712 * target.h (struct target_ops): Add new function pointer,
6713 thread_handle.
6714 (target_thread_handle): Define.
6715 * thread-db.c (find_one_thread, attach_thread): Set thread_handle
6716 field in lwp.
6717 (thread_db_thread_handle): New function.
6718
86299109
KB
67192017-09-21 Kevin Buettner <kevinb@redhat.com>
6720
6721 * linux-low.c (handle_extended_wait): Call thread_db_notice_clone().
6722 * linux-low.h (thread_db_notice_clone): Declare.
6723 * thread-db.c (thread_db_notice_clone): New function.
6724
f557a88a
PA
67252017-09-21 Pedro Alves <palves@redhat.com>
6726
6727 * server.c (gdb_read_memory, handle_status, process_serial_event)
6728 (handle_serial_event, handle_target_event): Adjust to
6729 set_desired_thread prototype change.
6730 * target.c (set_desired_thread): Remove 'use_general' parameter
6731 and adjust.
6732 * target.h (set_desired_thread): Remove 'use_general' parameter.
6733
223ffa71
TT
67342017-09-20 Tom Tromey <tom@tromey.com>
6735
6736 * target.c (target_terminal::terminal_state): Define.
6737 (target_terminal::init): Rename from target_terminal_init.
6738 (target_terminal::inferior): Rename from
6739 target_terminal_inferior.
6740 (target_terminal::ours): Rename from target_terminal_ours.
6741 (target_terminal::ours_for_output, target_terminal::info): New.
6742
04fd3ba9
SM
67432017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6744
6745 * server.c (accumulate_file_name_length): Remove.
6746 (emit_dll_description): Adjust to std::string change.
6747 (handle_qxfer_libraries): Use std::string to hold document.
6748
5e187554
SM
67492017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6750
6751 * linux-low.c (linux_qxfer_libraries_svr4): Adjust to change of
6752 return type of xml_escape_text.
6753 * server.c (emit_dll_description): Likewise.
6754
1526853e
SM
67552017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6756
6757 * server.c (captured_main): Accept argument for --selftest.
6758 Update run_tests call.
6759 * linux-x86-tdesc-selftest.c (initialize_low_tdesc): Add names
6760 when registering selftests.
6761
c4dfafab
SDJ
67622017-09-16 Sergio Durigan Junior <sergiodj@redhat.com>
6763
6764 * regcache.c (get_thread_regcache): Update code to use "std::vector"
6765 instead of "VEC" for "target_desc.reg_defs".
6766 (regcache_cpy): Likewise.
6767 (registers_to_string): Likewise.
6768 (registers_from_string): Likewise.
6769 (find_regno): Likewise.
6770 (supply_regblock): Likewise.
6771 (regcache_raw_read_unsigned): Likewise.
6772 * tdesc.c (init_target_desc): Likewise.
6773 (tdesc_create_reg): Likewise.
6774 * tdesc.h: Remove declaration of "tdesc_reg_p". Include <vector>.
6775 (struct target_desc) <reg_defs>: Convert to "std::vector".
6776 (target_desc): Do not initialize "reg_defs".
6777 (~target_desc): Update code to use "std::vector" instead of "VEC"
6778 for "target_desc.reg_defs".
6779 (operator==): Likewise.
6780
124aceb4
SM
67812017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6782
6783 * inferiors.h (thread_to_gdb_id): Remove.
6784 * inferiors.c (thread_to_gdb_id): Remove.
6785 * server.c (handle_qxfer_threads_worker, handle_query): Adjust.
6786 * lynx-low.c (lynx_resume, lynx_wait_1, lynx_fetch_registers,
6787 lynx_store_registers, lynx_read_memory, lynx_write_memory):
6788 Likewise.
6789 * nto-low.c (nto_fetch_registers, nto_store_registers,
6790 nto_stopped_by_watchpoint, nto_stopped_data_address): Likewise.
6791
96cde54f
SM
67922017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6793
6794 * inferiors.h (gdb_id_to_thread_id): Remove.
6795 * inferiors.c (gdb_id_to_thread_id): Remove.
6796 * server.c (process_serial_event): Adjust to gdb_id_to_thread_id
6797 removal. Move pid declaration closer to where it's used.
6798
e8ca139e
SM
67992017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6800
6801 * server.c (handle_detach): New function.
6802 (process_serial_event): Move code out, call handle_detach.
6803
f8a4e119
SM
68042017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6805
6806 * server.c (require_running): Rename to ...
6807 (require_running_or_return): ... this ...
6808 (require_running_or_break): ... and this.
6809 (handle_query, process_serial_event): Adjust.
6810
0eb0a407
SM
68112017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6812
6813 * linux-low.c (linux_set_resume_request): Remove unused
6814 variables.
6815
785922a5
SM
68162017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6817
6818 * server.c (first_thread_of): Remove.
6819 (process_serial_event): Replace usage of first_thread_of with
6820 find_any_thread_of_pid.
6821 * tracepoint.c (same_process_p): Remove.
6822 (gdb_agent_about_to_close): Replace usage of same_process_p with
6823 find_any_thread_of_pid.
6824 * linux-x86-low.c (same_process_callback): Remove.
6825 (x86_arch_setup_process_callback): Replace usage of
6826 same_process_callback with find_any_thread_of_pid.
6827 * thread-db.c (any_thread_of): Remove.
6828 (switch_to_process): Replace usage of any_thread_of with
6829 find_any_thread_of_pid.
6830 * inferiors.c (thread_pid_matches_callback): Remove.
6831 (find_thread_process): Adjust to use find_any_thread_of_pid.
6832
a059f00c
SDJ
68332017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
6834
6835 * regcache.c (get_thread_regcache): Guard calls to "memset"
e79be6e5 6836 with "!VEC_empty".
a059f00c 6837
cc397f3a
SDJ
68382017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
6839
6840 * linux-low.c (handle_extended_wait): Use
6841 "allocate_target_description" instead of "XNEW".
6842 * linux-x86-low.c (initialize_low_arch): Likewise.
6843
22916b07
YQ
68442017-09-05 Yao Qi <yao.qi@linaro.org>
6845
6846 * configure.srv (srv_i386_regobj): Remove.
6847 (srv_amd64_regobj): Remove.
6848 (srv_regobj): Set it to "" for x86 non-linux targets.
6849 * linux-x86-tdesc.c (i386_linux_read_description):
6850 * lynx-i386-low.c: Include x86-xstate.h and arch/i386.h.
6851 (init_registers_i386): Remove the declaration.
6852 (tdesc_i386): Remove the declaration.
6853 (lynx_i386_arch_setup): Call i386_create_target_description.
6854 * nto-x86-low.c: Likewise.
6855 * win32-i386-low.c [__x86_64__]: include arch/amd64.h.
6856 [!__x86_64__]: include arch/i386.h.
6857 (i386_arch_setup) [__x86_64__]: Call amd64_create_target_description.
6858
38602d55
YQ
68592017-09-05 Yao Qi <yao.qi@linaro.org>
6860
6861 * configure.srv (srv_amd64_linux_xmlfiles): Remove
6862 i386/amd64-XXX-linux from it.
6863
44b886ff
YQ
68642017-09-05 Yao Qi <yao.qi@linaro.org>
6865
6866 * configure.srv: Empty srv_amd64_linux_regobj if $development is
6867 false.
6868 (ipa_amd64_linux_regobj): Remove.
6869 (ipa_x32_linux_regobj): Remove.
6870
b4570e4b
YQ
68712017-09-05 Yao Qi <yao.qi@linaro.org>
6872
6873 * Makefile.in (arch-amd64.o): New rule.
6874 * configure.srv: Append arch-amd64.o.
6875 * linux-amd64-ipa.c: Include common/x86-xstate.h.
6876 (get_ipa_tdesc): Call amd64_linux_read_description.
6877 (initialize_low_tracepoint): Don't call init_registers_x32_XXX
6878 and init_registers_amd64_XXX.
6879 * linux-x86-low.c (x86_linux_read_description): Call
6880 amd64_linux_read_description.
6881 (x86_get_ipa_tdesc_idx): Call amd64_get_ipa_tdesc_idx.
6882 (initialize_low_arch): Don't call init_registers_x32_XXX and
6883 init_registers_amd64_XXX.
6884 * linux-x86-tdesc-selftest.c: Declare init_registers_amd64_XXX
6885 and tdesc_amd64_XXX.
6886 [__x86_64__] (amd64_tdesc_test): New function.
6887 (initialize_low_tdesc) [__x86_64__]: Call init_registers_x32_XXX
6888 and init_registers_amd64_XXX.
6889 * linux-x86-tdesc.c: Include arch/amd64.h.
6890 (xcr0_to_tdesc_idx): New function.
6891 (i386_linux_read_description): New function.
6892 (amd64_get_ipa_tdesc_idx): New function.
6893 * linux-x86-tdesc.h (amd64_get_ipa_tdesc_idx): Declare.
6894 (amd64_get_ipa_tdesc): Declare.
6895
d1f28ea2
YQ
68962017-09-05 Yao Qi <yao.qi@linaro.org>
6897
6898 * configure.srv (srv_i386_linux_xmlfiles): Remove
6899 i386/i386-XXX-linux.xml from it.
6900
25a93583
YQ
69012017-09-05 Yao Qi <yao.qi@linaro.org>
6902
6903 * configure.srv: Set srv_i386_linux_regobj empty if $development
6904 is false.
6905 * linux-i386-ipa.c (initialize_low_tracepoint): Don't call
6906 initialize_low_tdesc.
6907 * linux-x86-low.c (initialize_low_arch): Wrap initialize_low_tdesc
6908 with #if initialize_low_tdesc.
6909 * linux-x86-tdesc-selftest.c: New file.
6910 * linux-x86-tdesc.c: Move code to linux-x86-tdesc-selftest.c.
6911
5f035c07
YQ
69122017-09-05 Yao Qi <yao.qi@linaro.org>
6913
6914 * Makefile.in (arch-i386.o): New rule.
6915 * configure.srv (i[34567]86-*-linux*): Add arch-i386.o.
6916 (x86_64-*-linux*): Likewise.
6917 * linux-x86-tdesc.c: Don't include ../features/i386/32bit-XXX.c,
6918 include arch/i386.h.
6919 (i386_linux_read_description): Remove code and call
6920 i386_create_target_description.
6921 * tdesc.c (allocate_target_description): New function.
6922 * tdesc.h (set_tdesc_architecture): Remove declaration.
6923 (set_tdesc_osabi): Likewise.
6924
0abe8a89
YQ
69252017-09-05 Yao Qi <yao.qi@linaro.org>
6926
6927 * linux-x86-tdesc.c: Don't include <inttypes.h>.
6928 (i386_linux_read_description) [!IN_PROCESS_AGENT]: Call
6929 set_tdesc_architecture and set_tdesc_osabi. Remove code setting
6930 .xmltarget.
6931 * server.c (get_features_xml): Call tdesc_get_features_xml.
6932 * tdesc.c (set_tdesc_architecture): New function.
6933 (set_tdesc_osabi): New function.
6934 (tdesc_get_features_xml): New function.
6935 (tdesc_create_feature): Add an argument.
6936 * tdesc.h (struct target_desc) <features>: New field.
6937 <arch, osabi>: New field.
6938 (~target_desc): xfree features, arch, and osabi.
6939 (target_desc::oerator==): Don't compare .xmltarget.
6940 [!IN_PROCESS_AGENT] (set_tdesc_architecture): Declare.
6941 (set_tdesc_osabi): Likewise.
6942 (tdesc_get_features_xml): Likewise.
6943
0a188386
YQ
69442017-09-05 Yao Qi <yao.qi@linaro.org>
6945
6946 * linux-x86-tdesc.c: Include selftest.h.
6947 (i386_tdesc_test): New function.
6948 (initialize_low_tdesc): Call selftests::register_test.
6949 * tdesc.h: Include regdef.h.
6950 (target_desc): Override operator == and !=.
6951
f49ff000
YQ
69522017-09-05 Yao Qi <yao.qi@linaro.org>
6953
6954 * configure.srv (srv_tgtobj): Append linux-x86-tdesc.o.
6955 (ipa_obj): Likewise.
6956 * linux-i386-ipa.c: Include common/x86-xstate.h
6957 (get_ipa_tdesc): Call i386_linux_read_description.
6958 (initialize_low_tracepoint): Don't call init_registers_XXX
6959 functions, call initialize_low_tdesc instead.
6960 * linux-x86-low.c (x86_linux_read_description): Call
6961 i386_linux_read_description.
6962 (initialize_low_arch): Don't call init_registers_i386_XXX
6963 functions, call initialize_low_tdesc.
6964 * linux-x86-tdesc.c: New file.
6965 * linux-x86-tdesc.h (x86_linux_tdesc): New X86_TDESC_LAST.
6966 (i386_get_ipa_tdesc_idx): Declare.
6967 (i386_get_ipa_tdesc): Declare.
6968 (initialize_low_tdesc): Declare.
6969
2b68ef2f
YQ
69702017-09-05 Yao Qi <yao.qi@linaro.org>
6971
6972 * linux-x86-low.c (x86_get_ipa_tdesc_idx): Use X86_TDESC_MMX
6973 instead of 0.
6974
f7000548
YQ
69752017-09-05 Yao Qi <yao.qi@linaro.org>
6976
6977 * Makefile.in (IPA_OBJS): Add vec-ipa.o
6978 * regcache.c (get_thread_regcache): Use VEC_length.
6979 (init_register_cache): Likewise.
6980 (regcache_cpy): Likewise.
6981 (registers_to_string): Iterate reg_defs via VEC_iterate.
6982 (find_regno): Likewise.
6983 (find_register_by_number): Use VEC_index.
6984 (register_size): Call find_register_by_number.
6985 (register_data): Call find_register_by_number.
6986 (supply_regblock): Use VEC_length.
6987 (regcache_raw_read_unsigned): Likewise.
6988 * tdesc.c (init_target_desc): Iterate reg_defs via
6989 VEC_iterate.
6990 (default_description): Update initializer.
6991 (copy_target_description): Don't update field num_registers.
6992 * tdesc.h (struct target_desc) <reg_defs>: Change it to VEC.
6993 <num_registers>: Remove.
6994
50a421ac
SM
69952017-09-04 Simon Marchi <simon.marchi@ericsson.com>
6996
6997 * Makefile.in (.SECONDARY): Define target.
6998
23fdd69e
SM
69992017-09-03 Simon Marchi <simon.marchi@ericsson.com>
7000
7001 * linux-low.c (linux_wait_1): Adjust.
7002 * server.c (queue_stop_reply_callback): Adjust.
7003
0a2dde4a
SDJ
70042017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
7005
7006 * server.c (handle_general_set): Handle QEnvironmentHexEncoded,
7007 QEnvironmentUnset and QEnvironmentReset packets.
7008 (handle_query): Inform remote that QEnvironmentHexEncoded,
7009 QEnvironmentUnset and QEnvironmentReset are supported.
7010
6afd337d
SM
70112017-08-25 Simon Marchi <simon.marchi@ericsson.com>
7012
7013 * inferiors.h (inferior_target_data): Rename to ...
7014 (thread_target_data): ... this.
7015 (inferior_regcache_data): Rename to ...
7016 (thread_regcache_data): ... this.
7017 (set_inferior_regcache_data): Rename to ...
7018 (set_thread_regcache_data): ... this.
7019 * inferiors.c (inferior_target_data): Rename to ...
7020 (thread_target_data): ... this.
7021 (inferior_regcache_data): Rename to ...
7022 (thread_regcache_data): ... this.
7023 (set_inferior_regcache_data): Rename to ...
7024 (set_thread_regcache_data): ... this.
7025 (free_one_thread): Update.
7026 * linux-low.h (get_thread_lwp): Update.
7027 * regcache.c (get_thread_regcache): Update.
7028 (regcache_invalidate_thread): Update.
7029 (free_register_cache_thread): Update.
7030 * win32-i386-low.c (update_debug_registers_callback): Update.
7031 (win32_get_current_dr): Update.
7032 * win32-low.c (thread_rec): Update.
7033 (delete_thread_info): Update.
7034 (continue_one_thread): Update.
7035 (suspend_one_thread): Update.
7036
a160cc46
SM
70372017-08-24 Simon Marchi <simon.marchi@ericsson.com>
7038
7039 * inferiors.c (set_inferior_target_data): Remove.
7040 * inferiors.h (set_inferior_target_data): Remove.
7041
6d580b63
YQ
70422017-08-18 Yao Qi <yao.qi@linaro.org>
7043
7044 * Makefile.in (OBS): Add selftest.o.
7045 * configure.ac: AC_DEFINE GDB_SELF_TEST if $development.
7046 * configure, config.in: Re-generated.
7047 * server.c: Include common/sefltest.h.
7048 (captured_main): Handle option --selftest.
7049
f5a29eb0
YQ
70502017-08-09 Yao Qi <yao.qi@linaro.org>
7051
7052 * configure.srv (srv_i386_regobj): Remove i386-avx.o,
7053 i386-avx-avx512.o, i386-avx-mpx-avx512-pku.o, i386-mpx.o,
7054 i386-avx-mpx.o and i386-mmx.o.
7055 (srv_amd64_regobj): Remove amd64-avx.o, amd64-avx-avx512.o,
7056 amd64-avx-mpx-avx512-pku.o, amd64-mpx.o and amd64-avx-mpx.o.
7057 (srv_i386_xmlfiles): Remove i386/i386-avx.xml,
7058 i386/i386-avx-avx512.xml, i386/i386-avx-mpx-avx512-pku.xml,
7059 i386/i386-mpx.xml, i386/i386-avx-mpx.xml and i386/i386-mmx.xml.
7060 (srv_amd64_xmlfile):i386/amd64-avx.xml, i386/amd64-avx-avx512.xml,
7061 i386/amd64-avx-mpx-avx512-pku.xml, i386/amd64-mpx.xml,
7062 i386/amd64-avx-mpx.xml.
7063
57757c2f
YQ
70642017-08-09 Yao Qi <yao.qi@linaro.org>
7065
7066 * configure.srv (srv_amd64_regobj): Remove x32.o, x32-avx.o
7067 and x32-avx-avx512.o.
7068 (srv_amd64_xmlfiles): Remove i386/x32.xml, i386/x32-avx.xml
7069 i386/x32-avx-avx512.xml.
7070
229d26fc
SM
70712017-07-26 Simon Marchi <simon.marchi@ericsson.com>
7072
7073 * tracepoint.h (enum class fast_tpoint_collect_result): New
7074 enumeration.
7075 (fast_tracepoint_collecting): Change return type to
7076 fast_tpoint_collect_result.
7077 * tracepoint.c (fast_tracepoint_collecting): Likewise.
7078 * linux-low.h: Include tracepoint.h.
7079 (struct lwp_info) <collecting_fast_tracepoint>: Change type to
7080 fast_tpoint_collect_result.
7081 * linux-low.c (handle_tracepoints): Adjust.
7082 (linux_fast_tracepoint_collecting): Change return type to
7083 fast_tpoint_collect_result.
7084 (maybe_move_out_of_jump_pad, linux_wait_for_event_filtered,
7085 linux_wait_1, stuck_in_jump_pad_callback,
7086 lwp_signal_can_be_delivered, linux_resume_one_lwp_throw,
7087 proceed_one_lwp): Adjust to type change.
7088
2e1e43e1
YQ
70892017-07-10 Yao Qi <yao.qi@linaro.org>
7090
7091 * linux-x86-low.c (x86_linux_read_description): Re-indent the code.
7092
adc764e7
YQ
70932017-06-29 Yao Qi <yao.qi@linaro.org>
7094
7095 * tdesc.h (struct target_desc) [IN_PROCESS_AGENT] <expedite_regs>:
7096 Remove.
7097 [IN_PROCESS_AGENT] <xmltarget>: Likewise.
7098
a206891a
SM
70992017-06-20 Simon Marchi <simon.marchi@ericsson.com>
7100
7101 * Makefile.in (IPA_OBJS): Sort and format one item per line.
7102
9a6c7d9c
SDJ
71032017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
7104
7105 * linux-low.c (linux_create_inferior): Adjust code to access the
7106 environment information via 'gdb_environ' class.
7107 * lynx-low.c (lynx_create_inferior): Likewise.
7108 * server.c (our_environ): Make it an instance of 'gdb_environ'.
7109 (get_environ): Return a pointer to 'our_environ'.
7110 (captured_main): Initialize 'our_environ'.
7111 * server.h (get_environ): Adjust prototype.
7112 * spu-low.c (spu_create_inferior): Adjust code to access the
7113 environment information via 'gdb_environ' class.
7114
ae3e2ccf
SM
71152017-06-17 Simon Marchi <simon.marchi@ericsson.com>
7116
7117 * linux-low.c (linux_read_memory, linux_write_memory): Remove
7118 usage of "register" keyword.
7119
3e019bdc
SM
71202017-06-17 Simon Marchi <simon.marchi@ericsson.com>
7121
7122 * configure: Re-generate.
7123
8465943a
SM
71242017-06-17 Simon Marchi <simon.marchi@ericsson.com>
7125
7126 * configure: Re-generate.
7127
cf0dd6f0
SM
71282017-06-17 Simon Marchi <simon.marchi@ericsson.com>
7129
7130 * Makefile.in (COMPILE.pre): Add "-x c++".
7131
9845682b
SDJ
71322017-06-09 Sergio Durigan Junior <sergiodj@redhat.com>
7133
7134 * fork-child.c: Conditionally include <signal.h>.
7135
aefd8b33
SDJ
71362017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
7137
7138 * server.c (handle_general_set): Handle new packet
7139 "QStartupWithShell".
7140 (handle_query): Add "QStartupWithShell" to the list of supported
7141 packets.
7142 (gdbserver_usage): Add help text explaining the
7143 new "--startup-with-shell" and "--no-startup-with-shell" CLI
7144 options.
7145 (captured_main): Recognize and act upon the presence of the new
7146 CLI options.
7147
2090129c
SDJ
71482017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
7149 Pedro Alves <palves@redhat.com>
7150
7151 * Makefile.in (SFILES): Add "nat/fork-inferior.o".
7152 * configure: Regenerate.
7153 * configure.srv (srv_linux_obj): Add "fork-child.o" and
7154 "fork-inferior.o".
7155 (i[34567]86-*-lynxos*): Likewise.
7156 (spu*-*-*): Likewise.
7157 * fork-child.c: New file.
7158 * linux-low.c: Include "common-inferior.h", "nat/fork-inferior.h"
7159 and "environ.h".
7160 (linux_ptrace_fun): New function.
7161 (linux_create_inferior): Adjust function prototype to reflect
7162 change on "target.h". Adjust function code to use
7163 "fork_inferior".
7164 (linux_request_interrupt): Delete "signal_pid".
7165 * lynx-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
7166 (lynx_ptrace_fun): New function.
7167 (lynx_create_inferior): Adjust function prototype to reflect
7168 change on "target.h". Adjust function code to use
7169 "fork_inferior".
7170 * nto-low.c (nto_create_inferior): Adjust function prototype and
7171 code to reflect change on "target.h". Update comments.
7172 * server.c: Include "common-inferior.h", "nat/fork-inferior.h",
7173 "common-terminal.h" and "environ.h".
7174 (terminal_fd): Moved to fork-child.c.
7175 (old_foreground_pgrp): Likewise.
7176 (restore_old_foreground_pgrp): Likewise.
7177 (last_status): Make it global.
7178 (last_ptid): Likewise.
7179 (our_environ): New variable.
7180 (startup_with_shell): Likewise.
7181 (program_name): Likewise.
7182 (program_argv): Rename to...
7183 (program_args): ...this.
7184 (wrapper_argv): New variable.
7185 (start_inferior): Delete function.
7186 (get_exec_wrapper): New function.
7187 (get_exec_file): Likewise.
7188 (get_environ): Likewise.
7189 (prefork_hook): Likewise.
7190 (post_fork_inferior): Likewise.
7191 (postfork_hook): Likewise.
7192 (postfork_child_hook): Likewise.
7193 (handle_v_run): Update code to deal with arguments coming from the
7194 remote host. Update calls from "start_inferior" to
7195 "create_inferior".
7196 (captured_main): Likewise. Initialize environment variable. Call
7197 "have_job_control".
7198 * server.h (post_fork_inferior): New prototype.
7199 (get_environ): Likewise.
7200 (last_status): Declare.
7201 (last_ptid): Likewise.
7202 (signal_pid): Likewise.
7203 * spu-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
7204 (spu_ptrace_fun): New function.
7205 (spu_create_inferior): Adjust function prototype to reflect change
7206 on "target.h". Adjust function code to use "fork_inferior".
7207 * target.c (target_terminal_init): New function.
7208 (target_terminal_inferior): Likewise.
7209 (target_terminal_ours): Likewise.
7210 * target.h: Include <vector>.
7211 (struct target_ops) <create_inferior>: Update prototype.
7212 (create_inferior): Update macro.
7213 * utils.c (gdb_flush_out_err): New function.
7214 * win32-low.c (win32_create_inferior): Adjust function prototype
7215 and code to reflect change on "target.h".
7216
043a4934
SDJ
72172017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
7218
7219 * inferiors.c (switch_to_thread): New function.
7220
15652511
SDJ
72212017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
7222
7223 * Makefile.in (SFILE): Add "common/job-control.c".
7224 (OBS): Add "job-control.o".
7225
21ea5acd
SDJ
72262017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
7227
7228 * Makefile: Remove "@host_makefile_frag@".
7229
e13cb306
PA
72302017-05-05 Pedro Alves <palves@redhat.com>
7231
7232 * configure: Regenerate.
7233
c94fee56
SDJ
72342017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
7235
7236 * configure: Regenerate.
7237
a0ff9e1a
SM
72382017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
7239
7240 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Adjust to
7241 software_single_step change of return type to
7242 std::vector<CORE_ADDR>.
7243 * linux-low.c (install_software_single_step_breakpoints):
7244 Likewise.
7245 * linux-low.h (install_software_single_step_breakpoints):
7246 Likewise.
7247
be628ab8
SDJ
72482017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
7249
7250 * remote-utils.c: Include "gdb_termios.h" instead of
7251 "terminal.h".
7252 * terminal.h: Delete file.
7253
7c5ded6a
SDJ
72542017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
7255
7256 * server.c: Include <vector>.
7257 <program_argv, wrapper_argv>: Convert to std::vector.
7258 (start_inferior): Rewrite function to use C++.
7259 (handle_v_run): Likewise. Update code that calculates the argv
7260 based on the vRun packet; use C++.
7261 (captured_main): Likewise.
7262
436252de
SM
72632017-04-06 Simon Marchi <simon.marchi@ericsson.com>
7264
7265 * server.c (handle_v_cont): Initialize thread_resume::thread
7266 with null_ptid.
7267
9bf2a700
PA
72682017-04-05 Pedro Alves <palves@redhat.com>
7269
7270 * configure: Regenerate.
7271
a121b7c1
PA
72722017-04-05 Pedro Alves <palves@redhat.com>
7273
7274 * gdbreplay.c (sync_error): Constify.
7275 * linux-x86-low.c (push_opcode): Constify.
7276
21c8a587
PA
72772017-04-05 Pedro Alves <palves@redhat.com>
7278
7279 * win32-low.c (get_child_debug_event)
7280 <CREATE_PROCESS_DEBUG_EVENT>: Don't report TARGET_WAITKIND_EXECD.
7281 Report TARGET_WAITKIND_SPURIOUS instead.
7282
fb32b4f7
PA
72832017-04-05 Pedro Alves <palves@redhat.com>
7284
e79be6e5
SM
7285 * remote-utils.c (remote_prepare, remote_open): Constify.
7286 * remote-utils.h (remote_prepare, remote_open): Constify.
7287 * server.c (captured_main): Constify 'port' handling.
fb32b4f7 7288
65dd1e59
SM
72892017-04-04 Simon Marchi <simon.marchi@ericsson.com>
7290
7291 * Makefile.in (clean): Clear .deps.
7292
8fa5b777
SM
72932017-03-31 Simon Marchi <simon.marchi@polymtl.ca>
7294
7295 * .gitignore: Remove generated files, replace with wildcard.
7296 * (clean): Replace removal of generated files with wildcard.
7297 (version.c): Replace with...
7298 (version-generated.c): ...this.
7299 (xml-builtin.c): Replace with...
7300 (xml-builtin-generated.c): ...this.
7301 (%-ipa.o: %-generated.c, %.o: %-generated.c): New rules.
7302 (%.c: *regformats*): Replace with...
7303 (%-generated.c: *regformats*): ...this.
7304
a12e714b
MF
73052017-03-27 Max Filippov <jcmvbkbc@gmail.com>
7306
7307 * linux-xtensa-low.c (regnum::R_THREADPTR): New enum member.
7308 (xtensa_fill_gregset): Call collect_register_by_name for
7309 threadptr register.
7310 (xtensa_store_gregset): Call supply_register_by_name for
7311 threadptr register.
7312
1a09b50a
MF
73132017-03-27 Max Filippov <jcmvbkbc@gmail.com>
7314
7315 * linux-xtensa-low.c (xtensa_fill_gregset): Call collect_register
7316 for all registers in a0_regnum..a0_regnum + C0_NREGS range.
7317 (xtensa_store_gregset): Call supply_register for all registers in
7318 a0_regnum..a0_regnum + C0_NREGS range.
7319
1a01e7c6
SM
73202017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7321
7322 * Makefile.in (%-ipa.o: %-ipa.c): New rule.
7323 (ax-ipa.o: ax.c): Remove.
7324 (linux-i386-ipa.o: linux-i386-ipa.c): Remove.
7325 (linux-amd64-ipa.o: linux-amd64-ipa.c): Remove.
7326 (linux-aarch64-ipa.o: linux-aarch64-ipa.c): Remove.
7327 (linux-s390-ipa.o: linux-s390-ipa.c): Remove.
7328 (linux-ppc-ipa.o: linux-ppc-ipa.c): Remove.
7329
36bc18a8
SM
73302017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7331
7332 * Makefile.in (%-ipa.o: ../common/%.c): New rule.
7333 (print-utils-ipa.o: ../common/print-utils.c): Remove.
7334 (rsp-low-ipa.o: ../common/rsp-low.c): Remove.
7335 (errors-ipa.o: ../common/errors.c): Remove.
7336 (format-ipa.o: ../common/format.c): Remove.
7337 (common-utils-ipa.o: ../common/common-utils.c): Remove.
7338
a8ebe3d5
SM
73392017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7340
7341 * Makefile.in (%-ipa.o: %.c): New rule.
7342 (tracepoint-ipa.o: tracepoint.c): Remove.
7343 (utils-ipa.o: utils.c): Remove.
7344 (remote-utils-ipa.o: remote-utils.c): Remove.
7345 (regcache-ipa.o: regcache.c): Remove.
7346 (i386-linux-ipa.o: i386-linux.c): Remove.
7347 (i386-mmx-linux-ipa.o: i386-mmx-linux.c): Remove.
7348 (i386-avx-linux-ipa.o: i386-avx-linux.c): Remove.
7349 (i386-mpx-linux-ipa.o: i386-mpx-linux.c): Remove.
7350 (i386-avx-mpx-linux-ipa.o: i386-avx-mpx-linux.c): Remove.
7351 (i386-avx-avx512-linux-ipa.o: i386-avx-avx512-linux.c): Remove.
7352 (i386-avx-mpx-avx512-pku-linux-ipa.o: i386-avx-mpx-avx512-pku-linux.c): Remove.
7353 (amd64-linux-ipa.o: amd64-linux.c): Remove.
7354 (amd64-avx-linux-ipa.o: amd64-avx-linux.c): Remove.
7355 (amd64-mpx-linux-ipa.o: amd64-mpx-linux.c): Remove.
7356 (amd64-avx-mpx-linux-ipa.o: amd64-avx-mpx-linux.c): Remove.
7357 (amd64-avx-avx512-linux-ipa.o: amd64-avx-avx512-linux.c): Remove.
7358 (amd64-avx-mpx-avx512-pku-linux-ipa.o: amd64-avx-mpx-avx512-pku-linux.c): Remove.
7359 (aarch64-ipa.o: aarch64.c): Remove.
7360 (s390-linux32-ipa.o: s390-linux32.c): Remove.
7361 (s390-linux32v1-ipa.o: s390-linux32v1.c): Remove.
7362 (s390-linux32v2-ipa.o: s390-linux32v2.c): Remove.
7363 (s390-linux64-ipa.o: s390-linux64.c): Remove.
7364 (s390-linux64v1-ipa.o: s390-linux64v1.c): Remove.
7365 (s390-linux64v2-ipa.o: s390-linux64v2.c): Remove.
7366 (s390-te-linux64-ipa.o: s390-te-linux64.c): Remove.
7367 (s390-vx-linux64-ipa.o: s390-vx-linux64.c): Remove.
7368 (s390-tevx-linux64-ipa.o: s390-tevx-linux64.c): Remove.
7369 (s390x-linux64-ipa.o: s390x-linux64.c): Remove.
7370 (s390x-linux64v1-ipa.o: s390x-linux64v1.c): Remove.
7371 (s390x-linux64v2-ipa.o: s390x-linux64v2.c): Remove.
7372 (s390x-te-linux64-ipa.o: s390x-te-linux64.c): Remove.
7373 (s390x-vx-linux64-ipa.o: s390x-vx-linux64.c): Remove.
7374 (s390x-tevx-linux64-ipa.o: s390x-tevx-linux64.c): Remove.
7375 (powerpc-32l-ipa.o: powerpc-32l.c): Remove.
7376 (powerpc-altivec32l-ipa.o: powerpc-altivec32l.c): Remove.
7377 (powerpc-cell32l-ipa.o: powerpc-cell32l.c): Remove.
7378 (powerpc-vsx32l-ipa.o: powerpc-vsx32l.c): Remove.
7379 (powerpc-isa205-32l-ipa.o: powerpc-isa205-32l.c): Remove.
7380 (powerpc-isa205-altivec32l-ipa.o: powerpc-isa205-altivec32l.c): Remove.
7381 (powerpc-isa205-vsx32l-ipa.o: powerpc-isa205-vsx32l.c): Remove.
7382 (powerpc-e500l-ipa.o: powerpc-e500l.c): Remove.
7383 (powerpc-64l-ipa.o: powerpc-64l.c): Remove.
7384 (powerpc-altivec64l-ipa.o: powerpc-altivec64l.c): Remove.
7385 (powerpc-cell64l-ipa.o: powerpc-cell64l.c): Remove.
7386 (powerpc-vsx64l-ipa.o: powerpc-vsx64l.c): Remove.
7387 (powerpc-isa205-64l-ipa.o: powerpc-isa205-64l.c): Remove.
7388 (powerpc-isa205-altivec64l-ipa.o: powerpc-isa205-altivec64l.c): Remove.
7389 (powerpc-isa205-vsx64l-ipa.o: powerpc-isa205-vsx64l.c): Remove.
7390 (tdesc-ipa.o: tdesc.c): Remove.
7391 (x32-linux-ipa.o: x32-linux.c): Remove.
7392 (x32-avx-linux-ipa.o: x32-avx-linux.c): Remove.
7393 (x32-avx512-linux-ipa.o: x32-avx512-linux.c): Remove.
7394
50cfacb7
SM
73952017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7396
7397 * Makefile.in (%.o: ../arch/%.c): New rule.
7398 (arm.o: ../arch/arm.c): Remove.
7399 (arm-linux.o: ../arch/arm-linux.c): Remove.
7400 (arm-get-next-pcs.o: ../arch/arm-get-next-pcs.c): Remove.
7401 (aarch64-insn.o: ../arch/aarch64-insn.c): Remove.
7402
c5a22423
SM
74032017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7404
7405 * Makefile.in (%.o: ../nat/%.c): New rule.
7406 (x86-dregs.o: ../nat/x86-dregs.c): Remove.
7407 (amd64-linux-siginfo.o: ../nat/amd64-linux-siginfo.c): Remove.
7408 (linux-btrace.o: ../nat/linux-btrace.c): Remove.
7409 (linux-osdata.o: ../nat/linux-osdata.c): Remove.
7410 (linux-procfs.o: ../nat/linux-procfs.c): Remove.
7411 (linux-ptrace.o: ../nat/linux-ptrace.c): Remove.
7412 (linux-waitpid.o: ../nat/linux-waitpid.c): Remove.
7413 (mips-linux-watch.o: ../nat/mips-linux-watch.c): Remove.
7414 (ppc-linux.o: ../nat/ppc-linux.c): Remove.
7415 (linux-personality.o: ../nat/linux-personality.c): Remove.
7416 (aarch64-linux-hw-point.o: ../nat/aarch64-linux-hw-point.c): Remove.
7417 (aarch64-linux.o: ../nat/aarch64-linux.c): Remove.
7418 (x86-linux.o: ../nat/x86-linux.c): Remove.
7419 (x86-linux-dregs.o: ../nat/x86-linux-dregs.c): Remove.
7420 (linux-namespaces.o: ../nat/linux-namespaces.c): Remove.
7421
6bda016b
SM
74222017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7423
7424 * Makefile.in (%.o: ../common/%.c): New rule.
7425 (signals.o: ../common/signals.c): Remove.
7426 (print-utils.o: ../common/print-utils.c): Remove.
7427 (rsp-low.o: ../common/rsp-low.c): Remove.
7428 (common-utils.o: ../common/common-utils.c): Remove.
7429 (posix-strerror.o: ../common/posix-strerror.c): Remove.
7430 (mingw-strerror.o: ../common/mingw-strerror.c): Remove.
7431 (vec.o: ../common/vec.c): Remove.
7432 (gdb_vecs.o: ../common/gdb_vecs.c): Remove.
7433 (xml-utils.o: ../common/xml-utils.c): Remove.
7434 (ptid.o: ../common/ptid.c): Remove.
7435 (buffer.o: ../common/buffer.c): Remove.
7436 (format.o: ../common/format.c): Remove.
7437 (filestuff.o: ../common/filestuff.c): Remove.
7438 (agent.o: ../common/agent.c): Remove.
7439 (errors.o: ../common/errors.c): Remove.
7440 (environ.o: ../common/environ.c): Remove.
7441 (common-debug.o: ../common/common-debug.c): Remove.
7442 (cleanups.o: ../common/cleanups.c): Remove.
7443 (common-exceptions.o: ../common/common-exceptions.c): Remove.
7444 (fileio.o: ../common/fileio.c): Remove.
7445 (common-regcache.o: ../common/common-regcache.c): Remove.
7446 (signals-state-save-restore.o: ../common/signals-state-save-restore.c): Remove.
7447 (new-op.o: ../common/new-op.c): Remove.
7448 (btrace-common.o: ../common/btrace-common.c): Remove.
7449
21122961
SM
74502017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7451
7452 * Makefile.in (%.o: ../target/%.c): New rule.
7453 (waitstatus.o: ../target/waitstatus.c): Remove.
7454
c362e621
SM
74552017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7456
7457 * Makefile.in
7458 (%.c: ../regformats/%.dat,
7459 (%.c: ../regformats/arm/%.dat,
7460 (%.c: ../regformats/i386/%.dat,
7461 (%.c: ../regformats/rs6000/%.dat): New rules.
7462 (aarch64.c): Remove.
7463 (reg-arm.c): Remove.
7464 (arm-with-iwmmxt.c): Remove.
7465 (arm-with-vfpv2.c): Remove.
7466 (arm-with-vfpv3.c): Remove.
7467 (arm-with-neon.c): Remove.
7468 (reg-bfin.c): Remove.
7469 (reg-cris.c): Remove.
7470 (reg-crisv32.c): Remove.
7471 (i386.c): Remove.
7472 (i386-linux.c): Remove.
7473 (i386-avx.c): Remove.
7474 (i386-avx-linux.c): Remove.
7475 (i386-avx-avx512.c): Remove.
7476 (i386-avx-avx512-linux.c): Remove.
7477 (i386-mpx.c): Remove.
7478 (i386-mpx-linux.c): Remove.
7479 (i386-avx-mpx-avx512-pku.c): Remove.
7480 (i386-avx-mpx-avx512-pku-linux.c): Remove.
7481 (i386-avx-mpx.c): Remove.
7482 (i386-avx-mpx-linux.c): Remove.
7483 (i386-mmx.c): Remove.
7484 (i386-mmx-linux.c): Remove.
7485 (reg-ia64.c): Remove.
7486 (reg-m32r.c): Remove.
7487 (reg-m68k.c): Remove.
7488 (reg-cf.c): Remove.
7489 (mips-linux.c): Remove.
7490 (mips-dsp-linux.c): Remove.
7491 (mips64-linux.c): Remove.
7492 (mips64-dsp-linux.c): Remove.
7493 (nios2-linux.c): Remove.
7494 (powerpc-32.c): Remove.
7495 (powerpc-32l.c): Remove.
7496 (powerpc-altivec32l.c): Remove.
7497 (powerpc-cell32l.c): Remove.
7498 (powerpc-vsx32l.c): Remove.
7499 (powerpc-isa205-32l.c): Remove.
7500 (powerpc-isa205-altivec32l.c): Remove.
7501 (powerpc-isa205-vsx32l.c): Remove.
7502 (powerpc-e500l.c): Remove.
7503 (powerpc-64l.c): Remove.
7504 (powerpc-altivec64l.c): Remove.
7505 (powerpc-cell64l.c): Remove.
7506 (powerpc-vsx64l.c): Remove.
7507 (powerpc-isa205-64l.c): Remove.
7508 (powerpc-isa205-altivec64l.c): Remove.
7509 (powerpc-isa205-vsx64l.c): Remove.
7510 (s390-linux32.c): Remove.
7511 (s390-linux32v1.c): Remove.
7512 (s390-linux32v2.c): Remove.
7513 (s390-linux64.c): Remove.
7514 (s390-linux64v1.c): Remove.
7515 (s390-linux64v2.c): Remove.
7516 (s390-te-linux64.c): Remove.
7517 (s390-vx-linux64.c): Remove.
7518 (s390-tevx-linux64.c): Remove.
7519 (s390x-linux64.c): Remove.
7520 (s390x-linux64v1.c): Remove.
7521 (s390x-linux64v2.c): Remove.
7522 (s390x-te-linux64.c): Remove.
7523 (s390x-vx-linux64.c): Remove.
7524 (s390x-tevx-linux64.c): Remove.
7525 (tic6x-c64xp-linux.c): Remove.
7526 (tic6x-c64x-linux.c): Remove.
7527 (tic6x-c62x-linux.c): Remove.
7528 (reg-sh.c): Remove.
7529 (reg-sparc64.c): Remove.
7530 (reg-spu.c): Remove.
7531 (amd64.c): Remove.
7532 (amd64-linux.c): Remove.
7533 (amd64-avx.c): Remove.
7534 (amd64-avx-linux.c): Remove.
7535 (amd64-avx-avx512.c): Remove.
7536 (amd64-avx-avx512-linux.c): Remove.
7537 (amd64-mpx.c): Remove.
7538 (amd64-mpx-linux.c): Remove.
7539 (amd64-avx-mpx-avx512-pku.c): Remove.
7540 (amd64-avx-mpx-avx512-pku-linux.c): Remove.
7541 (amd64-avx-mpx.c): Remove.
7542 (amd64-avx-mpx-linux.c): Remove.
7543 (x32.c): Remove.
7544 (x32-linux.c): Remove.
7545 (x32-avx.c): Remove.
7546 (x32-avx-linux.c): Remove.
7547 (x32-avx-avx512.c): Remove.
7548 (x32-avx-avx512-linux.c): Remove.
7549 (reg-xtensa.c): Remove.
7550 (reg-tilegx.c): Remove.
7551 (reg-tilegx32.c): Remove.
7552
1672e0d9
SDJ
75532017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
7554
7555 * Makefile.in (SFILES): Add "common/environ.c".
7556 (OBJS): Add "common/environ.h".
7557
239b6d10
WT
75582017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
7559
7560 * configure.ac: Check if the fs_base and gs_base members of
7561 `struct user_regs_struct' exist.
7562 * config.in: Regenerated.
7563 * configure: Likewise.
7564
694b382c
AT
75652017-01-09 Antoine Tremblay <antoine.tremblay@ericsson.com>
7566
7567 * linux-aarch32-low.c (arm_breakpoint_kind_from_pc): Use
7568 target_read_memory.
7569 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer): Likewise.
7570 (get_next_pcs_syscall_next_pc): Likewise.
7571
7dc53023
LM
75722016-12-23 Luis Machado <lgustavo@codesourcery.com>
7573
7574 * win32-i386-low.c: Fix incorrect reference to a couple source files.
7575 * nto-x86-low.c: Likewise.
7576
ad02e4fe
SM
75772016-11-30 Simon Marchi <simon.marchi@polymtl.ca>
7578
7579 * Makefile.in: Include disable-implicit-rules.mk.
7580
dcb07cfa
PA
75812016-11-23 Pedro Alves <palves@redhat.com>
7582
7583 * debug.c: Include <chrono> instead of "gdb_sys_time.h".
7584 (debug_vprintf): Use std::chrono::steady_clock instead of
7585 gettimeofday. Use '.' instead of ':'.
7586 * tracepoint.c: Include <chrono> instead of "gdb_sys_time.h".
7587 (get_timestamp): Use std::chrono::steady_clock instead of
7588 gettimeofday.
7589
8629c02c
SM
75902016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
7591
7592 * Makefile.in: Fix whitespace formatting.
7593
b593ecca
SM
75942016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
7595
7596 * Makefile.in (SFILES, OBS): Flatten list and order
7597 alphabetically.
7598
9986ba08
PA
75992016-11-23 Pedro Alves <palves@redhat.com>
7600
7601 * event-loop.c (handle_file_event): Use warning.
7602 * linux-low.c (linux_resume_one_lwp_throw): Use warning.
7603 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
7604 Use warning.
7605
4eefa7bc
PA
76062016-11-23 Pedro Alves <palves@redhat.com>
7607
7608 * linux-low.c (check_zombie_leaders): Use debug_printf for debug
7609 output.
7610 * notif.c (handle_notif_ack, notif_event_enque): Likewise.
7611 * remote-utils.c (putpkt_binary_1, readchar, getpkt): Use
7612 debug_printf and debug_flush for debug output.
7613 * server.c (handle_general_set): Likewise.
7614 * thread-db.c (try_thread_db_load): Use debug_printf for debug
7615 output.
7616
5443506e
SM
76172016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
7618
7619 * Makefile.in (.c.o): Replace rule with ...
7620 (%.o: %.c): ... this one.
7621
3b165252
SM
76222016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
7623
7624 * Makefile.in: Remove @GMAKE_TRUE@ prefixes and removes lines
7625 prefixed with @GMAKE_FALSE@. Update comment related to non-GNU
7626 make.
7627 * configure.ac: Remove checks for the make program.
7628 * configure: Re-generate.
7629
0bcda685
PA
76302016-10-28 Pedro Alves <palves@redhat.com>
7631
7632 * Makefile.in (CXX_DIALECT): Get from configure.
7633 (COMPILE.pre, CC_LD): Append $(CXX_DIALECT).
7634 * acinclude.m4: Include ../ax_cxx_compile_stdcxx.m4.
7635 * configure.ac: Call AX_CXX_COMPILE_STDCXX.
7636 * config.in: Regenerate.
7637 * configure: Regenerate.
7638
c3805894
YQ
76392016-10-27 Yao Qi <yao.qi@linaro.org>
7640
7641 * linux-low.c (linux_supports_range_stepping): Return true if
7642 can_software_single_step return true.
7643
89342618
YQ
76442016-10-27 Yao Qi <yao.qi@linaro.org>
7645
7646 * inferiors.c (find_inferior_in_random): New function.
7647 * inferiors.h (find_inferior_in_random): Declare.
7648 * linux-low.c (linux_wait_for_event_filtered): Call
7649 find_inferior_in_random instead of find_inferior.
7650
e3652c84
YQ
76512016-10-27 Yao Qi <yao.qi@linaro.org>
7652
7653 * linux-low.c (linux_wait_1): If single-step breakpoints are
7654 inserted, remove them.
7655
5a04c4cf
PA
76562016-10-26 Pedro Alves <palves@redhat.com>
7657
7658 * linux-low.c (handle_extended_wait): Link parent/child fork
7659 threads.
7660 (linux_wait_1): Unlink them.
7661 (linux_set_resume_request): Ignore resume requests for
7662 already-resumed and unhandled fork child threads.
7663 * linux-low.h (struct lwp_info) <fork_relative>: New field.
7664 * server.c (in_queued_stop_replies_ptid, in_queued_stop_replies):
7665 New functions.
7666 (handle_v_requests) <vCont>: Don't call require_running.
7667 * server.h (in_queued_stop_replies): New declaration.
7668
cb93dc7f
YQ
76692016-10-24 Yao Qi <yao.qi@linaro.org>
7670
7671 PR server/20733
7672 * linux-aarch64-low.c (append_insns): Cast the return value to
7673 'uint32_t *'.
7674
a1078bea
YQ
76752016-10-10 Yao Qi <yao.qi@linaro.org>
7676
7677 * linux-aarch32-low.c (enum arm_breakpoint_kinds): Remove.
7678
1fb77080
SDJ
76792016-10-06 Sergio Durigan Junior <sergiodj@redhat.com>
7680
7681 * target.c (target_supports_multi_process): New function, moved
7682 from...
7683 * target.h (target_supports_multi_process): ... here. Remove
7684 macro.
7685
39b5a3b9
TT
76862016-10-05 Tom Tromey <tom@tromey.com>
7687
7688 PR remote/20655:
7689 * tracepoint.c (handle_tracepoint_bkpts): Check
7690 ipa_error_tracepoint, not ipa_stopping_tracepoint.
7691
c1d0b70a
YQ
76922016-10-05 Yao Qi <yao.qi@linaro.org>
7693
7694 * configure.srv: Update the path of arm-*.xml files.
7695
0a69eedb
YQ
76962016-10-05 Terry Guo <terry.guo@arm.com>
7697 Yao Qi <yao.qi@linaro.org>
7698
7699 * Makefile.in: Adjust the path of rules.
7700 * configure.srv: Update the path of xml files.
7701 * regformats/arm-with-iwmmxt.dat: Regenerated.
7702 * regformats/arm-with-neon.dat: Likewise.
7703 * regformats/arm-with-vfpv2.dat: Likewise.
7704 * regformats/arm-with-vfpv3.dat Likewise.
7705
17e16485
YQ
77062016-09-30 Yao Qi <yao.qi@linaro.org>
7707
7708 PR gdbserver/20627
7709 * target.c (target_stop_and_wait): Don't call
7710 target_continue_no_signal, use resume_stop instead.
7711
edeeb602
YQ
77122016-09-26 Yao Qi <yao.qi@linaro.org>
7713
7714 * linux-low.c (linux_wait_1): Call debug_exit.
7715
503b1c39
PA
77162016-09-23 Pedro Alves <palves@redhat.com>
7717
7718 * Makefile.in (SFILES): Add common/new-op.c.
7719 (OBS): Add common/new-op.o.
7720 (new-op.o): New rule.
7721
74172ecf
SM
77222016-09-21 Simon Marchi <simon.marchi@ericsson.com>
7723
7724 * .gitinore: Ignore more files.
7725
fc6cda2e
YQ
77262016-09-21 Yao Qi <yao.qi@linaro.org>
7727
7728 * linux-aarch32-low.c (arm_fill_gregset): Keep bits 20 to
7729 23.
7730
bc1e6c81
SDJ
77312016-09-19 Sergio Durigan Junior <sergiodj@redhat.com>
7732
7733 * server.c (start_inferior): Call target_mourn_inferior instead of
7734 mourn_inferior; pass ptid_t argument to it.
7735 (resume): Likewise.
7736 (handle_target_event): Likewise.
7737 * target.c (target_mourn_inferior): New function.
7738 * target.h (mourn_inferior): Delete macro.
7739
0e00e962
AA
77402016-09-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
7741
7742 * linux-low.c (lwp_is_stepping): New function.
7743
1d8cb77d
CL
77442016-09-06 Carl Love <cel@us.ibm.com>
7745
7746 * server.c (start_inferior): Fixed comment, requested comment change
7747 didn't get updated correctly. Removed reference to ptrace () call as
7748 it is only true on Linux systems.
7749
7313bced
CL
77502016-09-06 Carl Love <cel@us.ibm.com>
7751
7752 * server.c (start_inferior): Do not call
7753 function target_post_create_inferior () if the
7754 inferior process has already exited.
7755
cf6de44d
PA
77562016-09-05 Pedro Alves <palves@redhat.com>
7757
7758 * Makefile.in (COMPILER, COMPILER_CFLAGS): Remove.
7759 (COMPILE.pre, CC_LD): Use CXX directly.
7760 (INTERNAL_CFLAGS_BASE): Use CXXFLAGS directly.
7761 * acinclude.m4: Don't include build-with-cxx.m4.
7762 * configure.ac: Remove GDB_AC_BUILD_WITH_CXX call.
7763 * configure: Regenerate.
7764
c1da6748
AT
77652016-09-02 Akash Trehan <akash.trehan123@gmail.com>
7766
7767 PR gdb/19495
7768 * remote-utils.c (relocate_instruction): Remove redundant strcpy()
7769 call writing data to own_buf.
7770
f2b9e3df
SDJ
77712016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
7772
7773 * target.c (mywait): Call target_wait instead of
7774 the_target->wait.
7775 (target_wait): New function.
7776
049a8570
SDJ
77772016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
7778
7779 * server.c (start_inferior): New variable 'ptid'. Replace calls
7780 to the_target->resume by target_continue{,_no_signal}, depending
7781 on the case.
7782 * target.c (target_stop_and_wait): Call target_continue_no_signal
7783 instead of the_target->resume.
7784 (target_continue): New function.
7785
3aa5cfa0
AT
77862016-08-31 Antoine Tremblay <antoine.tremblay@ericsson.com>
7787
7788 * linux-low.c (linux_wait_1): Move event switch after unsuspend_lwps.
7789
754653a7
AZ
77902016-08-25 Adhemerval Zanella <adhemerval.zanella@linaro.org>
7791
7792 PR server/20491
7793 * gdb_proc_service.h (ps_get_thread_area): Remove const from struct
7794 ps_prochandle.
7795 * linux-aarch64-low.c (ps_get_thread_area): Likewise.
7796 * linux-arm-low.c (ps_get_thread_area): Likewise.
7797 * linux-crisv32-low.c (ps_get_thread_area): Likewise.
7798 * linux-m68k-low.c (ps_get_thread_area): Likewise.
7799 * linux-mips-low.c (ps_get_thread_area): Likewise.
7800 * linux-nios2-low.c (ps_get_thread_area): Likewise.
7801 * linux-tic6x-low.c (ps_get_thread_area): Likewise.
7802 * linux-x86-low.c (ps_get_thread_area): Likewise.
7803 * linux-xtensa-low.c (ps_get_thread_area): Likewise.
7804
ed036b40
PA
78052016-08-19 Pedro Alves <palves@redhat.com>
7806
7807 * linux-x86-low.c (amd64_emit_call): Emit missing call opcode.
7808
c8ef42ee
PA
78092016-08-19 Pedro Alves <palves@redhat.com>
7810
7811 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Fix
7812 comment. Use memcpy instead of casting through unsigned long.
7813
9c235a72
PA
78142016-08-19 Pedro Alves <palves@redhat.com>
7815
7816 * linux-amd64-ipa.c (alloc_jump_pad_buffer) [__ILP32__]: Try
7817 allocating around 0x80000000.
7818
201506da
PA
78192016-08-19 Pedro Alves <palves@redhat.com>
7820
7821 PR gdb/20415
7822 * Makefile.in (x32-linux-ipa.o, x32-avx-linux-ipa.o)
7823 (x32-avx512-linux-ipa.o): New rules.
7824 * configure.ac (x86_64-*-linux*): New x32 check.
7825 * configure.srv (ipa_x32_linux_regobj): New.
7826 (x86_64-*-linux*): Use $ipa_x32_linux_regobj if building for x32.
7827 * linux-amd64-ipa.c (get_ipa_tdesc) [__ILP32__]: Return x32
7828 descriptions.
7829 (initialize_low_tracepoint) [__ILP32__]: Initialize x32
7830 descriptions.
7831 * configure: Regenerate.
7832
f348d89a
PA
78332016-08-09 Pedro Alves <palves@redhat.com>
7834
7835 PR gdb/18653
7836 * Makefile.in (OBS): Add signals-state-save-restore.o.
7837 (signals-state-save-restore.o): New rule.
7838 * config.in: Regenerate.
7839 * configure: Regenerate.
7840 * linux-low.c: Include "signals-state-save-restore.h".
7841 (linux_create_inferior): Call
7842 restore_original_signals_state.
7843 * server.c: Include "dispositions-save-restore.h".
7844 (captured_main): Call save_original_signals_state.
7845
1baf5149
PA
78462016-08-05 Pedro Alves <palves@redhat.com>
7847
7848 * configure: Regenerate.
7849
fcd4a73d
YQ
78502016-08-04 Yao Qi <yao.qi@linaro.org>
7851
7852 * linux-low.c (regsets_fetch_inferior_registers): Check
7853 errno is ESRCH or not.
7854
979659d0
YQ
78552016-08-02 Yao Qi <yao.qi@linaro.org>
7856
7857 * thread-db.c (struct thread_db) <td_ta_event_getmsg_p>: Remove.
7858 <td_ta_set_event_p, td_ta_event_addr_p>: Remove.
7859 (thread_db_load_search): Update.
7860 (try_thread_db_load_1): Don't look for td_ta_event_addr,
7861 td_ta_set_event and td_ta_event_getmsg.
7862
6598661d
PA
78632016-07-26 Pedro Alves <palves@redhat.com>
7864
7865 PR server/20414
7866 * linux-x86-low.c (x86_get_pc, x86_set_pc): Use uint64_t instead
7867 of unsigned long for 64-bit registers and use uint32_t instead of
7868 unsigned int for 32-bit registers.
7869
9cf12d57
PA
78702016-07-26 Pedro Alves <palves@redhat.com>
7871
7872 * linux-x86-low.c (x86_siginfo_fixup): Rename 'native' parameter
7873 to 'ptrace'.
7874
305450ed
TT
78752016-07-21 Tom Tromey <tom@tromey.com>
7876
7877 * configure: Rebuild.
7878
2583da7c
YQ
78792016-07-21 Yao Qi <yao.qi@linaro.org>
7880
7881 * mem-break.c (find_gdb_breakpoint): Cast bp to
7882 'struct gdb_breakpoint *' rather than 'gdb_breakpoint *'.
7883
21536b36
YQ
78842016-07-21 Yao Qi <yao.qi@linaro.org>
7885
7886 * server.c (handle_v_requests): Support s and S actions
7887 if target_supports_software_single_step return true.
7888
8901d193
YQ
78892016-07-21 Yao Qi <yao.qi@linaro.org>
7890
7891 * linux-low.c (resume_stopped_resumed_lwps): If resume request
7892 is resume_step, call maybe_hw_step.
7893 (linux_wait_1): Stop all threads, remove reinsert breakpoints,
7894 and unstop them.
7895 (linux_resume_one_lwp_throw): Don't assert the thread has reinsert
7896 breakpoints or not.
7897 (proceed_one_lwp): If resume request is resume_step, install
7898 reinsert breakpoints and call maybe_hw_step.
7899
0e9a339e
YQ
79002016-07-21 Yao Qi <yao.qi@linaro.org>
7901
7902 * linux-low.c (proceed_one_lwp): Declare.
7903 (linux_resume_one_thread): Remove local variable 'step'.
7904 Lift code enqueue signal. Call proceed_one_lwp instead of
7905 linux_resume_one_lwp.
7906
4281b351
YQ
79072016-07-21 Yao Qi <yao.qi@linaro.org>
7908
7909 * linux-low.c (linux_resume_one_thread): Call
7910 enqueue_pending_signal.
7911
984a2c04
YQ
79122016-07-21 Yao Qi <yao.qi@linaro.org>
7913
7914 * gdbthread.h (make_cleanup_restore_current_thread): Declare.
7915 * inferiors.c (do_restore_current_thread_cleanup): New function.
7916 (make_cleanup_restore_current_thread): Likewise.
7917 * linux-low.c (install_software_single_step_breakpoints): Call
7918 make_cleanup_restore_current_thread. Switch current_thread to
7919 thread.
7920
bec903c9
YQ
79212016-07-21 Yao Qi <yao.qi@linaro.org>
7922
7923 * mem-break.c (struct reinsert_breakpoint) <ptid>: New field.
7924 (set_reinsert_breakpoint): New parameter ptid. Callers updated.
7925 (clone_one_breakpoint): Likewise.
7926 (delete_reinsert_breakpoints): Change parameter to thread.
7927 Callers updated.
7928 (has_reinsert_breakpoints): Likewise.
7929 (uninsert_reinsert_breakpoints): Likewise.
7930 (reinsert_reinsert_breakpoints): Likewise.
7931 * mem-break.h (set_reinsert_breakpoint): Update declaration.
7932 (delete_reinsert_breakpoints): Likewise.
7933 (reinsert_reinsert_breakpoints): Likewise.
7934 (uninsert_reinsert_breakpoints): Likewise.
7935 (has_reinsert_breakpoints): Likewise.
7936
63c40ec7
YQ
79372016-07-21 Yao Qi <yao.qi@linaro.org>
7938
7939 * inferiors.c (get_thread_process): Make parameter const.
7940 * inferiors.h (get_thread_process): Update declaration.
7941 * mem-break.c (clone_all_breakpoints): Remove all parameters.
7942 Add new parameters child_thread and parent_thread. Callers
7943 updated.
7944 * mem-break.h (clone_all_breakpoints): Update declaration.
7945
9aa76cd0
YQ
79462016-07-21 Yao Qi <yao.qi@linaro.org>
7947
7948 * mem-break.c (struct breakpoint) <cond_list>: Remove.
7949 <command_list, handler>: Remove.
7950 (struct gdb_breakpoint): New.
7951 (struct other_breakpoint): New.
7952 (struct reinsert_breakpoint): New.
7953 (is_gdb_breakpoint): New function.
7954 (any_persistent_commands): Update command_list if
7955 is_gdb_breakpoint returns true.
7956 (set_breakpoint): Create breakpoints according to their types.
7957 (find_gdb_breakpoint): Return 'struct gdb_breakpoint *'.
7958 (set_gdb_breakpoint_1): Likewise.
7959 (set_gdb_breakpoint): Likewise.
7960 (clear_breakpoint_conditions): Change parameter type to
7961 'struct gdb_breakpoint *'.
7962 (clear_breakpoint_commands): Likewise.
7963 (clear_breakpoint_conditions_and_commands): Likewise.
7964 (add_condition_to_breakpoint): Likewise.
7965 (add_breakpoint_condition): Likewise.
7966 (add_commands_to_breakpoint): Likewise.
7967 (check_breakpoints): Check other_breakpoint.
7968 (clone_one_breakpoint): Clone breakpopint according to its type.
7969 * mem-break.h (struct gdb_breakpoint): Declare.
7970 (set_gdb_breakpoint): Update declaration.
7971 (clear_breakpoint_conditions_and_commands): Likewise.
7972 (add_breakpoint_condition): Likewise.
7973 (add_breakpoint_commands): Likewise.
7974 * server.c (process_point_options): Change parameter type to
7975 'struct gdb_breakpoint *'.
7976
811f8301
YQ
79772016-07-21 Yao Qi <yao.qi@linaro.org>
7978
7979 * mem-break.c (set_breakpoint_at): Rename it to ...
7980 (set_breakpoint_type_at): ... it.
7981 (set_breakpoint_at): Call set_breakpoint_type_at.
7982 (set_reinsert_breakpoint): Call set_breakpoint_type_at.
7983 * mem-break.h (set_breakpoint_at): Update comments.
7984
b1c51e36
CLT
79852016-07-12 Chung-Lin Tang <cltang@codesourcery.com>
7986
7987 * linux-nios2-low.c (nios2_fill_gregset): Add type cast
7988 to buf parameter.
7989 (nios2_store_gregset): Likewise.
7990
ced2dffb
PA
79912016-07-01 Pedro Alves <palves@redhat.com>
7992 Antoine Tremblay <antoine.tremblay@ericsson.com>
7993
7994 * linux-low.c: Change interface to take the target lwp_info
7995 pointer directly and return void. Handle detaching from a zombie
7996 thread.
7997 (linux_detach_lwp_callback): New function.
7998 (linux_detach): Detach from the leader thread after detaching from
7999 the clone threads.
8000
2ac09a5b
YQ
80012016-06-28 Yao Qi <yao.qi@linaro.org>
8002
8003 * linux-aarch64-low.c (aarch64_ftrace_insn_reloc_b): Use int64_t
8004 for variable new_offset.
8005 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
8006 (aarch64_ftrace_insn_reloc_cb): Likewise.
8007 (aarch64_ftrace_insn_reloc_tb): Likewise.
8008 (aarch64_install_fast_tracepoint_jump_pad): Likewise. Use
8009 PRIx64 instead of PRIx32.
8010
79e7fd4f
YQ
80112016-06-28 Yao Qi <yao.qi@linaro.org>
8012
8013 * linux-arm-low.c (arm_get_syscall_trapinfo): New function.
8014 (the_low_target): Install arm_get_syscall_trapinfo.
8015
061fc021
YQ
80162016-06-28 Yao Qi <yao.qi@linaro.org>
8017
8018 * linux-aarch64-low.c (aarch64_get_syscall_trapinfo): New
8019 function.
8020 (the_low_target): Install aarch64_get_syscall_trapinfo.
8021
4cc32bec
YQ
80222016-06-28 Yao Qi <yao.qi@linaro.org>
8023
8024 * linux-low.c (get_syscall_trapinfo): Remove parameter sysret.
8025 Callers updated.
8026 * linux-low.h (struct linux_target_ops) <get_syscall_trapinfo>:
8027 Remove parameter sysno.
8028 * linux-x86-low.c (x86_get_syscall_trapinfo): Remove parameter
8029 sysret.
8030
782c1122
AA
80312016-06-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
8032
8033 * linux-s390-low.c (s390_emit_eq_goto): Mark function static.
8034 (s390_emit_ne_goto): Likewise.
8035 (s390_emit_lt_goto): Likewise.
8036 (s390_emit_le_goto): Likewise.
8037 (s390_emit_gt_goto): Likewise.
8038 (s390_emit_ge_goto): Likewise.
8039 (s390x_emit_eq_goto): Likewise.
8040 (s390x_emit_ne_goto): Likewise.
8041 (s390x_emit_lt_goto): Likewise.
8042 (s390x_emit_le_goto): Likewise.
8043 (s390x_emit_gt_goto): Likewise.
8044 (s390x_emit_ge_goto): Likewise.
8045 (s390_emit_ops_impl): Mark variable static.
8046 (s390x_emit_ops): Likewise.
8047
2e7b624b
YQ
80482016-06-17 Yao Qi <yao.qi@linaro.org>
8049
8050 * linux-low.c (handle_extended_wait): Call
8051 uninsert_reinsert_breakpoints for the parent process. Remove
8052 reinsert breakpoints from the child process. Reinsert them to
8053 the parent process when vfork is done.
8054 * mem-break.c (uninsert_reinsert_breakpoints): New function.
8055 (reinsert_reinsert_breakpoints): New function.
8056 * mem-break.h (uninsert_reinsert_breakpoints): Declare
8057 (reinsert_reinsert_breakpoints): Declare.
8058
8a81c5d7
YQ
80592016-06-17 Yao Qi <yao.qi@linaro.org>
8060
8061 * linux-low.c (handle_extended_wait): If the parent is doing
8062 step-over, remove the reinsert breakpoints from the forked child.
8063
f50bf8e5
YQ
80642016-06-17 Yao Qi <yao.qi@linaro.org>
8065
8066 * linux-low.c (unsuspend_all_lwps): Declare.
8067 (linux_low_filter_event): If thread exited, call finish_step_over.
8068 If step-over is finished, unsuspend other threads.
8069
8376a3cb
YQ
80702016-06-17 Yao Qi <yao.qi@linaro.org>
8071
8072 * linux-low.c (linux_resume_one_lwp_throw): Assert
8073 has_reinsert_breakpoints returns false.
8074 * mem-break.c (delete_disabled_breakpoints): Assert
8075 bp type isn't reinsert_breakpoint.
8076
f79b145d
YQ
80772016-06-17 Yao Qi <yao.qi@linaro.org>
8078
8079 * linux-low.c (maybe_hw_step): New function.
8080 (linux_resume_one_lwp_throw): Call maybe_hw_step.
8081 (finish_step_over): Switch current_thread to lwp temporarily,
8082 and assert has_reinsert_breakpoints returns true.
8083 (proceed_one_lwp): Call maybe_hw_step.
8084 * mem-break.c (has_reinsert_breakpoints): New function.
8085 * mem-break.h (has_reinsert_breakpoints): Declare.
8086
0ae534d2
JT
80872016-06-02 Jon Turney <jon.turney@dronecode.org.uk>
8088
8089 * win32-low.c (win32_create_inferior): Add pointer casts for C++.
8090
fcdad592
YQ
80912016-05-17 Yao Qi <yao.qi@linaro.org>
8092
8093 * linux-low.c (linux_stabilize_threads): Call unsuspend_all_lwps
8094 instead of find_inferior.
8095
9e784964
YQ
80962016-05-05 Yao Qi <yao.qi@linaro.org>
8097
8098 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer):
8099 Initialize res to zero.
8100
cf2ebb6e
YQ
81012016-05-05 Yao Qi <yao.qi@linaro.org>
8102
8103 * linux-arm-low.c (arm_sigreturn_next_pc): Change type of cpsr
8104 to uint32_t.
8105
c1aebf87
UW
81062016-05-04 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
8107
8108 * spu-low.c (fetch_ppc_register): Cast PowerPC-Linux-specific value
8109 used as first ptrace argument to PTRACE_TYPE_ARG1 for C++.
8110 (fetch_ppc_memory_1, store_ppc_memory_1): Likewise.
8111
35fd2deb 81122016-04-28 Par Olsson <par.olsson@windriver.com>
cbe14bcf 8113 Simon Marchi <simon.marchi@ericsson.com>
35fd2deb
PO
8114
8115 * tracepoint.c (write_inferior_int8): New function.
8116 (cmd_qtenable_disable): Write enable flag using
8117 write_inferior_int8.
8118
484b3c32
YQ
81192016-04-25 Yao Qi <yao.qi@linaro.org>
8120
8121 * linux-low.c (lwp_signal_can_be_delivered): Adjust.
8122 (need_step_over_p): Return zero if the LWP has pending signals
8123 can be delivered on software single step target.
8124
85ba7d86
YQ
81252016-04-25 Yao Qi <yao.qi@linaro.org>
8126
8127 * linux-low.c (reinsert_raw_breakpoint): If bp->inserted is true
8128 return instead of error.
8129
3539aa13
YQ
81302016-04-22 Yao Qi <yao.qi@linaro.org>
8131
8132 * linux-aarch32-low.c (arm_store_gregset): Clear CPSR bits 20
8133 to 23.
8134
5b061e98
YQ
81352016-04-22 Yao Qi <yao.qi@linaro.org>
8136
8137 * linux-low.c (lwp_signal_can_be_delivered): Don't deliver
8138 signal when stepping over breakpoint with software single
8139 step.
8140
3451269c
PA
81412016-04-21 Pedro Alves <palves@redhat.com>
8142
8143 * linux-s390-low.c (s390_collect_ptrace_register)
8144 (s390_supply_ptrace_register, s390_get_hwcap): Use gdb_byte * and
8145 add casts.
8146 (s390_check_regset): Use void * instead of gdb_byte *.
8147
a2358508
PA
81482016-04-20 Pedro Alves <palves@redhat.com>
8149
8150 * configure: Renegerate.
8151
6885166d
YQ
81522016-04-20 Yao Qi <yao.qi@linaro.org>
8153
8154 * linux-aarch32-low.c: Include "arch/arm-linux.h".
8155 (arm_fill_gregset): Use ARM_CPSR_GREGNUM rather than magic
8156 number 16.
8157 (arm_store_gregset): Likewise.
8158
2b863f51
WT
81592016-04-16 Walfred Tedeschi <walfred.tedeschi@intel.com>
8160
8161 * Makefile.in (clean): Add removal for i386-avx-mpx.c,
8162 i386-avx-mpx-linux.c, amd64-avx-mpx.c and amd64-avx-mpx-linux.c.
8163 (i386-avx-mpx.c, i386-avx-mpx-linux.c, amd64-avx-mpx.c)
8164 (amd64-avx-mpx-linux.c): New rules.
8165 (amd64-avx-mpx-linux-ipa.o, i386-avx-mpx-linux-ipa.o): New rule.
8166 * configure.srv (srv_i386_regobj): Add i386-avx-mpx.o.
8167 (srv_i386_linux_regobj): Add i386-avx-mpx-linux.o.
8168 (srv_amd64_regobj): Add amd64-avx-mpx.o.
8169 (srv_amd64_linux_regobj): Add amd64-avx-mpx-linux.o.
8170 (srv_i386_xmlfiles): Add i386/i386-avx-mpx.xml.
8171 (srv_amd64_xmlfiles): Add i386/amd64-avx-mpx.xml.
8172 (srv_i386_linux_xmlfiles): Add i386/i386-avx-mpx-linux.xml.
8173 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-mpx-linux.xml.
8174 (ipa_i386_linux_regobj): Add i386-avx-mpx-linux-ipa.o.
8175 (ipa_amd64_linux_regobj): Add amd64-avx-mpx-linux-ipa.o.
8176 * linux-x86-low.c (x86_linux_read_description): Add case for
8177 X86_XSTATE_AVX_MPX_MASK.
8178 (x86_get_ipa_tdesc_idx): Add cases for avx_mpx.
8179 (initialize_low_arch): Call init_registers_amd64_avx_mpx_linux and
8180 init_registers_i386_avx_mpx_linux.
8181 * linux-i386-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
8182 (initialize_low_tracepoint): Call
8183 init_registers_i386_avx_mpx_linux.
8184 * linux-amd64-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
8185 (initialize_low_tracepoint): Call
8186 init_registers_amd64_avx_mpx_linux.
8187 * linux-x86-tdesc.h (X86_TDESC_AVX_MPX): New enum value.
8188 (init_registers_amd64_avx_mpx_linux, tdesc_amd64_avx_mpx_linux)
8189 (init_registers_i386_avx_mpx_linux, tdesc_i386_avx_mpx_linux): New
8190 declarations.
8191
9b30624b
PA
81922016-04-18 Pedro Alves <palves@redhat.com>
8193
8194 * configure: Regenerate.
8195
45e3745e
AT
81962016-04-13 Antoine Tremblay <antoine.tremblay@ericsson.com>
8197
8198 * linux-aarch64-low.c (aarch64_emit_add): Switch x1 and x0.
8199 (aarch64_emit_sub): Likewise.
8200
2afc13ff
PA
82012016-04-12 Pedro Alves <palves@redhat.com>
8202
8203 * utils.c (prepare_to_throw_exception): Delete.
8204
6e774b13
SM
82052016-04-05 Simon Marchi <simon.marchi@ericsson.com>
8206
8207 * Makefile.in ($(IPA_LIB)): Set SONAME of the IPA lib.
8208
4dca19f8
MK
82092016-04-05 Marcin Kościelnicki <koriakin@0x04.net>
8210
8211 * tracepoint.c (getauxval): Move to #ifdef IN_PROCESS_AGENT.
8212
d0a9981f
MK
82132016-04-03 Marcin Kościelnicki <koriakin@0x04.net>
8214
8215 * linux-aarch64-ipa.c: Add <elf.h> include.
8216 * linux-ppc-ipa.c: Add <elf.h> include.
8217 * linux-s390-ipa.c: Add <elf.h> include.
8218
252db07e
MK
82192016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
8220
8221 * tracepoint.c (gdb_collect_ptr): Remove const qualifier.
8222 (get_raw_reg_ptr): Likewise.
8223 (get_trace_state_variable_value_ptr): Likewise.
8224 (set_trace_state_variable_value_ptr): Likewise.
8225 (initialize_tracepoint): Cast alloc_jump_pad_buffer result to
8226 char *.
8227
14e2b6d9
MK
82282016-03-31 Wei-cheng Wang <cole945@gmail.com>
8229 Marcin Kościelnicki <koriakin@0x04.net>
8230
8231 PR/17221
8232 * linux-ppc-low.c (emit_insns): New function.
8233 (__EMIT_ASM, _EMIT_ASM, EMIT_ASM): New macros.
8234 (ppc_emit_prologue): New function.
8235 (ppc_emit_epilogue): New function.
8236 (ppc_emit_add): New function.
8237 (ppc_emit_sub): New function.
8238 (ppc_emit_mul): New function.
8239 (ppc_emit_lsh): New function.
8240 (ppc_emit_rsh_signed): New function.
8241 (ppc_emit_rsh_unsigned): New function.
8242 (ppc_emit_ext): New function.
8243 (ppc_emit_zero_ext): New function.
8244 (ppc_emit_log_not): New function.
8245 (ppc_emit_bit_and): New function.
8246 (ppc_emit_bit_or): New function.
8247 (ppc_emit_bit_xor): New function.
8248 (ppc_emit_bit_not): New function.
8249 (ppc_emit_equal): New function.
8250 (ppc_emit_less_signed): New function.
8251 (ppc_emit_less_unsigned): New function.
8252 (ppc_emit_ref): New function.
8253 (ppc_emit_const): New function.
8254 (ppc_emit_reg): New function.
8255 (ppc_emit_pop): New function.
8256 (ppc_emit_stack_flush): New function.
8257 (ppc_emit_swap): New function.
8258 (ppc_emit_stack_adjust): New function.
8259 (ppc_emit_call): New function.
8260 (ppc_emit_int_call_1): New function.
8261 (ppc_emit_void_call_2): New function.
8262 (ppc_emit_if_goto): New function.
8263 (ppc_emit_goto): New function.
8264 (ppc_emit_eq_goto): New function.
8265 (ppc_emit_ne_goto): New function.
8266 (ppc_emit_lt_goto): New function.
8267 (ppc_emit_le_goto): New function.
8268 (ppc_emit_gt_goto): New function.
8269 (ppc_emit_ge_goto): New function.
8270 (ppc_write_goto_address): New function.
8271 (ppc_emit_ops_impl): New static variable.
8272 (ppc64v1_emit_prologue): New function.
8273 (ppc64v2_emit_prologue): New function.
8274 (ppc64_emit_epilogue): New function.
8275 (ppc64_emit_add): New function.
8276 (ppc64_emit_sub): New function.
8277 (ppc64_emit_mul): New function.
8278 (ppc64_emit_lsh): New function.
8279 (ppc64_emit_rsh_signed): New function.
8280 (ppc64_emit_rsh_unsigned): New function.
8281 (ppc64_emit_ext): New function.
8282 (ppc64_emit_zero_ext): New function.
8283 (ppc64_emit_log_not): New function.
8284 (ppc64_emit_bit_and): New function.
8285 (ppc64_emit_bit_or): New function.
8286 (ppc64_emit_bit_xor): New function.
8287 (ppc64_emit_bit_not): New function.
8288 (ppc64_emit_equal): New function.
8289 (ppc64_emit_less_signed): New function.
8290 (ppc64_emit_less_unsigned): New function.
8291 (ppc64_emit_ref): New function.
8292 (ppc64_emit_const): New function.
8293 (ppc64v1_emit_reg): New function.
8294 (ppc64v2_emit_reg): New function.
8295 (ppc64_emit_pop): New function.
8296 (ppc64_emit_stack_flush): New function.
8297 (ppc64_emit_swap): New function.
8298 (ppc64v1_emit_call): New function.
8299 (ppc64v2_emit_call): New function.
8300 (ppc64v1_emit_int_call_1): New function.
8301 (ppc64v2_emit_int_call_1): New function.
8302 (ppc64v1_emit_void_call_2): New function.
8303 (ppc64v2_emit_void_call_2): New function.
8304 (ppc64_emit_if_goto): New function.
8305 (ppc64_emit_eq_goto): New function.
8306 (ppc64_emit_ne_goto): New function.
8307 (ppc64_emit_lt_goto): New function.
8308 (ppc64_emit_le_goto): New function.
8309 (ppc64_emit_gt_goto): New function.
8310 (ppc64_emit_ge_goto): New function.
8311 (ppc64v1_emit_ops_impl): New static variable.
8312 (ppc64v2_emit_ops_impl): New static variable.
8313 (ppc_emit_ops): New function.
8314 (linux_low_target): Wire in ppc_emit_ops.
8315
a2174ba4
MK
83162016-03-31 Wei-cheng Wang <cole945@gmail.com>
8317 Marcin Kościelnicki <koriakin@0x04.net>
8318
8319 PR/17221
8320 * Makefile.in: Add powerpc-*-ipa.o
8321 * configure.srv: Add ipa_obj for powerpc*-linux.
8322 * linux-ppc-ipa.c: New file.
8323 * linux-ppc-low.c: Added linux-ppc-tdesc.h, ax.h, tracepoint.h
8324 includes.
8325 (PPC_FIELD): New macro.
8326 (PPC_SEXT): New macro.
8327 (PPC_OP6): New macro.
8328 (PPC_BO): New macro.
8329 (PPC_LI): New macro.
8330 (PPC_BD): New macro.
8331 (init_registers_*): Move prototype to linux-ppc-tdesc.h.
8332 (tdesc_*): Move declaration to linux-ppc-tdesc.h.
8333 (ppc_get_hwcap): Rename to ppc_get_auxv and add type parameter.
8334 (ppc_get_thread_area): New function.
8335 (is_elfv2_inferior): New function.
8336 (gen_ds_form): New function.
8337 (GEN_STD): New macro.
8338 (GEN_STDU): New macro.
8339 (GEN_LD): New macro.
8340 (GEN_LDU): New macro.
8341 (gen_d_form): New function.
8342 (GEN_ADDI): New macro.
8343 (GEN_ADDIS): New macro.
8344 (GEN_LI): New macro.
8345 (GEN_LIS): New macro.
8346 (GEN_ORI): New macro.
8347 (GEN_ORIS): New macro.
8348 (GEN_LWZ): New macro.
8349 (GEN_STW): New macro.
8350 (GEN_STWU): New macro.
8351 (gen_xfx_form): New function.
8352 (GEN_MFSPR): New macro.
8353 (GEN_MTSPR): New macro.
8354 (GEN_MFCR): New macro.
8355 (GEN_MTCR): New macro.
8356 (GEN_SYNC): New macro.
8357 (GEN_LWSYNC): New macro.
8358 (gen_x_form): New function.
8359 (GEN_OR): New macro.
8360 (GEN_MR): New macro.
8361 (GEN_LWARX): New macro.
8362 (GEN_STWCX): New macro.
8363 (GEN_CMPW): New macro.
8364 (gen_md_form): New function.
8365 (GEN_RLDICL): New macro.
8366 (GEN_RLDICR): New macro.
8367 (gen_i_form): New function.
8368 (GEN_B): New macro.
8369 (GEN_BL): New macro.
8370 (gen_b_form): New function.
8371 (GEN_BNE): New macro.
8372 (GEN_LOAD): New macro.
8373 (GEN_STORE): New macro.
8374 (gen_limm): New function.
8375 (gen_atomic_xchg): New function.
8376 (gen_call): New function.
8377 (ppc_relocate_instruction): New function.
8378 (ppc_install_fast_tracepoint_jump_pad): New function.
8379 (ppc_get_min_fast_tracepoint_insn_len): New function.
8380 (ppc_get_ipa_tdesc_idx): New function.
8381 (the_low_target): Wire in the new functions.
8382 (initialize_low_arch) [!__powerpc64__]: Don'it initialize 64-bit
8383 tdescs.
8384 * linux-ppc-tdesc.h: New file.
8385
a13c4696
MK
83862016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
8387
8388 * linux-aarch64-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
8389 (alloc_jump_pad_buffer): New function.
8390 * linux-amd64-ipa.c: Add <sys/mman.h> include.
8391 (alloc_jump_pad_buffer): New function.
8392 * linux-i386-ipa.c (alloc_jump_pad_buffer): New function.
8393 * linux-s390-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
8394 (alloc_jump_pad_buffer): New function.
8395 * tracepoint.c (getauxval) [!HAVE_GETAUXVAL]: New function.
8396 (initialize_tracepoint): Delegate to alloc_jump_pad_buffer.
8397 * tracepoint.h (alloc_jump_pad_buffer): New prototype.
8398 (getauxval) [!HAVE_GETAUXVAL]: New prototype.
8399
1cda1512
MK
84002016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
8401
8402 * linux-aarch64-ipa.c: Rename gdb_agent_get_raw_reg to get_raw_reg.
8403 * linux-amd64-ipa.c: Likewise.
8404 * linux-i386-ipa.c: Likewise.
8405 * linux-s390-ipa.c: Likewise.
8406 * tracepoint.c: IPA-export gdb_collect_ptr instead of gdb_collect,
8407 ditto for get_raw_reg_ptr, get_trace_state_variable_value_ptr,
8408 set_trace_state_variable_value_ptr.
8409 (struct ipa_sym_addresses): Likewise.
8410 (symbol_list): Likewise.
8411 (install_fast_tracepoint): Dereference gdb_collect_ptr instead of
8412 accessing gdb_collect directly.
8413 (gdb_collect_ptr_type): New typedef.
8414 (get_raw_reg_ptr_type): New typedef.
8415 (get_trace_state_variable_value_ptr_type): New typedef.
8416 (set_trace_state_variable_value_ptr_type): New typedef.
8417 (gdb_collect_ptr): New global.
8418 (get_raw_reg_ptr): New global.
8419 (get_trace_state_variable_value_ptr): New global.
8420 (set_trace_state_variable_value_ptr): New global.
8421 (get_raw_reg_func_addr): Dereference get_raw_reg_ptr instead of
8422 accessing get_raw_reg directly.
8423 (get_get_tsv_func_addr): Likewise for
8424 get_trace_state_variable_value_ptr.
8425 (get_set_tsv_func_addr): Likewise for
8426 set_trace_state_variable_value_ptr.
8427 * tracepoint.h: Rename gdb_agent_get_raw_reg to get_raw_reg.
8428
72fb5488
SM
84292016-03-30 Simon Marchi <simon.marchi@ericsson.com>
8430
8431 * tracepoint.c (cmd_qtenable_disable): Remove whitespace.
8432
28170b88
MK
84332016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
8434
8435 * remote-utils.c (look_up_one_symbol): Remove own_buf, handle 'v'
8436 packets.
8437 (relocate_instruction): Remove own_buf.
8438 * server.c (own_buf): Make global.
8439 (handle_v_requests): Make global.
8440 * server.h (own_buf): New declaration.
8441 (handle_v_requests): New prototype.
8442
f39e8743
MK
84432016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
8444
8445 PR 18377
8446 * linux-s390-low.c (add_insns): New function.
8447 (s390_emit_prologue): New function.
8448 (s390_emit_epilogue): New function.
8449 (s390_emit_add): New function.
8450 (s390_emit_sub): New function.
8451 (s390_emit_mul): New function.
8452 (s390_emit_lsh): New function.
8453 (s390_emit_rsh_signed): New function.
8454 (s390_emit_rsh_unsigned): New function.
8455 (s390_emit_ext): New function.
8456 (s390_emit_log_not): New function.
8457 (s390_emit_bit_and): New function.
8458 (s390_emit_bit_or): New function.
8459 (s390_emit_bit_xor): New function.
8460 (s390_emit_bit_not): New function.
8461 (s390_emit_equal): New function.
8462 (s390_emit_less_signed): New function.
8463 (s390_emit_less_unsigned): New function.
8464 (s390_emit_ref): New function.
8465 (s390_emit_if_goto): New function.
8466 (s390_emit_goto): New function.
8467 (s390_write_goto_address): New function.
8468 (s390_emit_litpool): New function.
8469 (s390_emit_const): New function.
8470 (s390_emit_call): New function.
8471 (s390_emit_reg): New function.
8472 (s390_emit_pop): New function.
8473 (s390_emit_stack_flush): New function.
8474 (s390_emit_zero_ext): New function.
8475 (s390_emit_swap): New function.
8476 (s390_emit_stack_adjust): New function.
8477 (s390_emit_set_r2): New function.
8478 (s390_emit_int_call_1): New function.
8479 (s390_emit_void_call_2): New function.
8480 (s390_emit_eq_goto): New function.
8481 (s390_emit_ne_goto): New function.
8482 (s390_emit_lt_goto): New function.
8483 (s390_emit_le_goto): New function.
8484 (s390_emit_gt_goto): New function.
8485 (s390_emit_ge_goto): New function.
8486 (s390x_emit_prologue): New function.
8487 (s390x_emit_epilogue): New function.
8488 (s390x_emit_add): New function.
8489 (s390x_emit_sub): New function.
8490 (s390x_emit_mul): New function.
8491 (s390x_emit_lsh): New function.
8492 (s390x_emit_rsh_signed): New function.
8493 (s390x_emit_rsh_unsigned): New function.
8494 (s390x_emit_ext): New function.
8495 (s390x_emit_log_not): New function.
8496 (s390x_emit_bit_and): New function.
8497 (s390x_emit_bit_or): New function.
8498 (s390x_emit_bit_xor): New function.
8499 (s390x_emit_bit_not): New function.
8500 (s390x_emit_equal): New function.
8501 (s390x_emit_less_signed): New function.
8502 (s390x_emit_less_unsigned): New function.
8503 (s390x_emit_ref): New function.
8504 (s390x_emit_if_goto): New function.
8505 (s390x_emit_const): New function.
8506 (s390x_emit_call): New function.
8507 (s390x_emit_reg): New function.
8508 (s390x_emit_pop): New function.
8509 (s390x_emit_stack_flush): New function.
8510 (s390x_emit_zero_ext): New function.
8511 (s390x_emit_swap): New function.
8512 (s390x_emit_stack_adjust): New function.
8513 (s390x_emit_int_call_1): New function.
8514 (s390x_emit_void_call_2): New function.
8515 (s390x_emit_eq_goto): New function.
8516 (s390x_emit_ne_goto): New function.
8517 (s390x_emit_lt_goto): New function.
8518 (s390x_emit_le_goto): New function.
8519 (s390x_emit_gt_goto): New function.
8520 (s390x_emit_ge_goto): New function.
8521 (s390_emit_ops): New function.
8522 (struct linux_target_ops): Fill in emit_ops hook.
8523
abd9baf9
MK
85242016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
8525
8526 PR 18377
8527 * Makefile.in: Add s390 IPA files.
8528 * configure.srv: Build IPA for s390.
8529 * linux-s390-ipa.c: New file.
8530 * linux-s390-low.c: New includes - inttypes.h and linux-s390-tdesc.h.
8531 (init_registers_s390_linux32): Move declaration to linux-s390-tdesc.h.
8532 (tdesc_s390_linux32): Likewise.
8533 (init_registers_s390_linux32v1): Likewise.
8534 (tdesc_s390_linux32v1): Likewise.
8535 (init_registers_s390_linux32v2): Likewise.
8536 (tdesc_s390_linux32v2): Likewise.
8537 (init_registers_s390_linux64): Likewise.
8538 (tdesc_s390_linux64): Likewise.
8539 (init_registers_s390_linux64v1): Likewise.
8540 (tdesc_s390_linux64v1): Likewise.
8541 (init_registers_s390_linux64v2): Likewise.
8542 (tdesc_s390_linux64v2): Likewise.
8543 (init_registers_s390_te_linux64): Likewise.
8544 (tdesc_s390_te_linux64): Likewise.
8545 (init_registers_s390_vx_linux64): Likewise.
8546 (tdesc_s390_vx_linux64): Likewise.
8547 (init_registers_s390_tevx_linux64): Likewise.
8548 (tdesc_s390_tevx_linux64): Likewise.
8549 (init_registers_s390x_linux64): Likewise.
8550 (tdesc_s390x_linux64): Likewise.
8551 (init_registers_s390x_linux64v1): Likewise.
8552 (tdesc_s390x_linux64v1): Likewise.
8553 (init_registers_s390x_linux64v2): Likewise.
8554 (tdesc_s390x_linux64v2): Likewise.
8555 (init_registers_s390x_te_linux64): Likewise.
8556 (tdesc_s390x_te_linux64): Likewise.
8557 (init_registers_s390x_vx_linux64): Likewise.
8558 (tdesc_s390x_vx_linux64): Likewise.
8559 (init_registers_s390x_tevx_linux64): Likewise.
8560 (tdesc_s390x_tevx_linux64): Likewise.
8561 (have_hwcap_s390_vx): New static variable.
8562 (s390_arch_setup): Fill have_hwcap_s390_vx.
8563 (s390_get_thread_area): New function.
8564 (s390_ft_entry_gpr_esa): New const.
8565 (s390_ft_entry_gpr_zarch): New const.
8566 (s390_ft_entry_misc): New const.
8567 (s390_ft_entry_fr): New const.
8568 (s390_ft_entry_vr): New const.
8569 (s390_ft_main_31): New const.
8570 (s390_ft_main_64): New const.
8571 (s390_ft_exit_fr): New const.
8572 (s390_ft_exit_vr): New const.
8573 (s390_ft_exit_misc): New const.
8574 (s390_ft_exit_gpr_esa): New const.
8575 (s390_ft_exit_gpr_zarch): New const.
8576 (append_insns): New function.
8577 (s390_relocate_instruction): New function.
8578 (s390_install_fast_tracepoint_jump_pad): New function.
8579 (s390_get_min_fast_tracepoint_insn_len): New function.
8580 (s390_get_ipa_tdesc_idx): New function.
8581 (struct linux_target_ops): Wire in the above functions.
8582 (initialize_low_arch) [!__s390x__]: Don't initialize s390x tdescs.
8583 * linux-s390-tdesc.h: New file.
8584
a4105d04
MK
85852016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
8586
8587 * linux-s390-low.c (s390_supports_tracepoints): New function.
8588 (struct linux_target_ops): Fill supports_tracepoints hook.
8589
35ac8b3e
YQ
85902016-03-18 Yao Qi <yao.qi@linaro.org>
8591
8592 * linux-low.c (lwp_signal_can_be_delivered): New function.
8593 (linux_resume_one_lwp_throw): Use lwp_signal_can_be_delivered.
8594
94610ec4
YQ
85952016-03-18 Yao Qi <yao.qi@linaro.org>
8596
8597 * linux-low.c (linux_resume_one_lwp_throw): Set 'signal' to
8598 0 if signal is enqueued. Remove 'signal' from one debugging
8599 message. Move one debugging message to some lines below.
8600 Remove code setting 'signal' to 0.
8601
80aea927
YQ
86022016-03-18 Yao Qi <yao.qi@linaro.org>
8603
8604 * linux-low.c (linux_low_filter_event): Remove redundant
8605 WIFSTOPPED check together with linux_wstatus_maybe_breakpoint.
8606
b04fd3be
MK
86072016-03-09 Marcin Kościelnicki <koriakin@0x04.net>
8608
8609 * linux-ppc-low.c (ppc_supports_tracepoints): New function.
8610 (struct linux_target_ops): Wire in the above.
8611
c40c8d4b
YQ
86122016-03-03 Yao Qi <yao.qi@linaro.org>
8613
8614 * linux-low.c: Update comments to start_step_over.
8615
0f8288ae
YQ
86162016-03-03 Yao Qi <yao.qi@linaro.org>
8617
8618 PR server/19736
8619 * linux-low.c (handle_extended_wait): Set child suspended
8620 if event_lwp->bp_reinsert isn't zero.
8621
fdbd04a8
YQ
86222016-03-02 Yao Qi <yao.qi@linaro.org>
8623
8624 * linux-low.c (linux_resume_one_lwp_throw): Replace code with
8625 enqueue_pending_signal.
8626
6896a8fa
MK
86272016-03-02 Marcin Kościelnicki <koriakin@0x04.net>
8628
8629 * tracepoint.c (cmd_qtstart): Only set ipa_tdesc_idx if agent
8630 is actually loaded.
8631
ab503087
MK
86322016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
8633
8634 * linux-s390-low.c (s390_num_regs_3264): Define on 31-bit too.
8635 (s390_regmap_3264) [!__s390x__]: New global.
8636 (s390_collect_ptrace_register): Skip map entries containing -1.
8637 (s390_supply_ptrace_register): Ditto.
8638 (s390_fill_gprs_high): New function.
8639 (s390_store_gprs_high): New function.
8640 (s390_regsets): Add NT_S390_HIGH_GPRS.
8641 (s390_get_hwcap): Enable on 31-bit.
8642 (have_hwcap_s390_high_gprs): Enable on 31-bit.
8643 (s390_arch_setup): Enable detection of high GPRs, TDB, VX on 31-bit.
8644 Detect NT_S390_HIGH_GPRS.
8645 (s390_usrregs_info_3264): Enable on 31-bit.
8646 (s390_regs_info): Enable regs_info_3264 on 31-bit.
8647 (initialize_low_arch): Initialize s390_regsets_info_3264 on 31-bit.
8648
ae91f625
MK
86492016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
8650
8651 PR gdb/13808
8652 * Makefile.in: Add i386-*-linux-ipa.o and amd64-*-linux-ipa.o.
8653 * configure.srv: Ditto.
8654 * linux-aarch64-ipa.c (get_ipa_tdesc): New function.
8655 (initialize_low_tracepoint): Remove ipa_tdesc assignment.
8656 * linux-amd64-ipa.c: Add "linux-x86-tdesc.h" include.
8657 (init_registers_amd64_linux): Remove prototype.
8658 (tdesc_amd64_linux): Remove declaration.
8659 (get_ipa_tdesc): New function.
8660 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
8661 initialize remaining tdescs.
8662 * linux-i386-ipa.c: Add "linux-x86-tdesc.h" include.
8663 (init_registers_i386_linux): Remove prototype.
8664 (tdesc_i386_linux): Remove declaration.
8665 (get_ipa_tdesc): New function.
8666 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
8667 initialize remaining tdescs.
8668 * linux-low.c (linux_get_ipa_tdesc_idx): New function.
8669 (linux_target_ops): wire in linux_get_ipa_tdesc_idx.
8670 * linux-low.h (struct linux_target_ops): Add get_ipa_tdesc_idx.
8671 * linux-x86-low.c: Move tdesc declarations to linux-x86-tdesc.h.
8672 (x86_get_ipa_tdesc_idx): New function.
8673 (the_low_target): Wire in x86_get_ipa_tdesc_idx.
8674 * linux-x86-tdesc.h: New file.
8675 * target.h (struct target_ops): Add get_ipa_tdesc_idx.
8676 (target_get_ipa_tdesc_idx): New macro.
8677 * tracepoint.c (ipa_tdesc_idx): New macro.
8678 (struct ipa_sym_addresses): Add addr_ipa_tdesc_idx.
8679 (symbol_list): Add ipa_tdesc_idx.
8680 (cmd_qtstart): Write ipa_tdesc_idx in the target.
8681 (ipa_tdesc): Remove.
8682 (ipa_tdesc_idx): New variable.
8683 (get_context_regcache): Use get_ipa_tdesc.
8684 (gdb_collect): Ditto.
8685 (gdb_probe): Ditto.
8686 * tracepoint.h (get_ipa_tdesc): New prototype.
8687 (ipa_tdesc): Remove.
8688
e7ad2f14
PA
86892016-02-24 Pedro Alves <palves@redhat.com>
8690
8691 * linux-low.c (check_stopped_by_breakpoint): Rename to ...
8692 (save_stop_reason): ... this. Use GDB_ARCH_IS_TRAP_HWBKPT and
8693 handle ambiguous GDB_ARCH_IS_TRAP_BRKPT / GDB_ARCH_IS_TRAP_HWBKPT.
8694 Factor out common code between the USE_SIGTRAP_SIGINFO and
8695 !USE_SIGTRAP_SIGINFO blocks.
8696 (linux_low_filter_event): Call save_stop_reason instead of
8697 check_stopped_by_breakpoint and check_stopped_by_watchpoint.
8698 Update comments.
8699 (linux_wait_1): Update comments.
8700
657f9cde
WW
87012016-02-24 Wei-cheng Wang <cole945@gmail.com>
8702
8703 * linux-ppc-low.c (ppc_supports_z_point_type): New function:
8704 (ppc_insert_point, ppc_remove_point): Insert/remove z-packet breakpoints.
8705 (ppc64_emit_ops_vector): Add target ops - ppc_supports_z_point_type,
8706 ppc_insert_point, ppc_remove_point.
8707
b00b61e1
MK
87082016-02-17 Marcin Kościelnicki <koriakin@0x04.net>
8709
8710 * linux-s390-low.c (s390_supports_z_point_type): New function.
8711 (struct linux_target_ops): Wire s390_supports_z_point_type in.
8712
553cb527
YQ
87132016-02-16 Yao Qi <yao.qi@linaro.org>
8714
8715 * linux-arm-low.c (get_next_pcs_syscall_next_pc): Remove argument
8716 PC. Get pc from regcache_read_pc.
8717
a5652c21
YQ
87182016-02-12 Yao Qi <yao.qi@linaro.org>
8719
8720 * linux-aarch64-low.c (aarch64_get_pc): Call linux_get_pc_64bit
8721 or linux_get_pc_32bit.
8722 (aarch64_set_pc): Call linux_set_pc_64bit or linux_set_pc_32bit.
8723
ed443b61
YQ
87242016-02-12 Yao Qi <yao.qi@linaro.org>
8725
8726 * linux-arm-low.c (get_next_pcs_ops): Initialize it with
8727 arm_linux_get_next_pcs_fixup.
8728
020ecd38
MK
87292016-02-12 Marcin Kościelnicki <koriakin@0x04.net>
8730
8731 * tracepoint.c (x_tracepoint_action_download): Change
8732 write_inferior_data_ptr to write_inferior_data_pointer.
8733 (cmd_qtstart): Likewise.
8734 (write_inferior_data_ptr): Remove.
8735 (download_agent_expr): Change write_inferior_data_ptr to
8736 write_inferior_data_pointer.
8737 (download_tracepoint_1): Likewise.
8738 (download_tracepoint): Likewise.
8739 (download_trace_state_variables): Likewise.
8740
7cae9051
WW
87412016-02-11 Wei-cheng Wang <cole945@gmail.com>
8742 Marcin Kościelnicki <koriakin@0x04.net>
8743
8744 * tracepoint.c (struct tracepoint_action_ops): Remove.
8745 (struct tracepoint_action): Remove ops.
8746 (m_tracepoint_action_download, r_tracepoint_action_download)
8747 (x_tracepoint_action_download, l_tracepoint_action_download): Adjust
8748 size and offset accordingly.
8749 (m_tracepoint_action_ops, r_tracepoint_action_ops)
8750 (x_tracepoint_action_ops, l_tracepoint_action_ops): Remove.
8751 (tracepoint_action_send, tracepoint_action_download): New functions.
8752 Helpers for trace action handlers.
8753 (add_tracepoint_action): Remove setup actions ops.
8754 (download_tracepoint_1, tracepoint_send_agent): Call helper functions.
8755
9f6a71b4
YQ
87562016-02-10 Yao Qi <yao.qi@linaro.org>
8757
8758 * regcache.c (regcache_raw_read_unsigned): Clear *VAL.
8759
1e94266c
SM
87602016-02-09 Simon Marchi <simon.marchi@ericsson.com>
8761
8762 * configure.ac: Use AC_CONFIG_FILES instead of passing arguments
8763 to AC_OUTPUT.
8764 * configure: Regenerate.
8765
8adce034
SM
87662016-02-09 Simon Marchi <simon.marchi@ericsson.com>
8767
8768 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): Change
8769 void * to gdb_byte *.
8770 * linux-low.c (siginfo_fixup): Likewise.
8771 (linux_xfer_siginfo): Likewise.
8772 * linux-low.h (struct linux_target_ops) <siginfo_fixup>:
8773 Likewise.
8774 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
8775
93813b37
WT
87762016-02-02 Walfred Tedeschi <walfred.tedeschi@intel.com>
8777
8778 * configure.srv (x86_64-*-linux*): Add amd64-linux-siginfo.o
8779 to srv_tgtobj.
8780 (i[34567]86-*-linux*): Add amd64-linux-siginfo.o
8781 to srv_tgtobj.
8782 * linux-x86-low.c [__x86_64__]: Include
8783 "nat/amd64-linux-siginfo.h".
8784 (compat_siginfo_from_siginfo, siginfo_from_compat_siginfo)
8785 (compat_x32_siginfo_from_siginfo, siginfo_from_compat_x32_siginfo)
8786 (compat_timeval, compat_sigval, compat_x32_clock, cpt_si_pid)
8787 (cpt_si_uid, cpt_si_timerid, cpt_si_overrun, cpt_si_status)
8788 (cpt_si_utime, cpt_si_stime, cpt_si_ptr, cpt_si_addr, cpt_si_band)
8789 (cpt_si_fd, si_timerid, si_overrun): Move from
8790 nat/amd64-linux-siginfo.c.
8791 * Makefile.in (amd64-linux-siginfo.o:): New rule.
8792
8424cc97
SM
87932016-01-28 Simon Marchi <simon.marchi@ericsson.com>
8794
8795 * server.c (skip_to_semicolon): Remove.
8796 (process_point_options): Use strchrnul instead of
8797 skip_to_semicolon.
8798
4d18591b
YQ
87992016-01-26 Yao Qi <yao.qi@linaro.org>
8800
8801 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Remove argument pc.
8802 * linux-low.c (install_software_single_step_breakpoints): Don't
8803 call regcache_read_pc.
8804 * linux-low.h (struct linux_target_ops) <get_next_pcs>: Remove
8805 argument pc.
8806
d8020970
YQ
88072016-01-26 Yao Qi <yao.qi@linaro.org>
8808
8809 * linux-low.c (install_software_single_step_breakpoints): Call
8810 regcache_read_pc instead of get_pc.
8811
8b207339
YQ
88122016-01-26 Yao Qi <yao.qi@linaro.org>
8813
8814 * remote-utils.c (remote_close) [!USE_WIN32API]: Ignore SIGIO.
8815 (unblock_async_io): Rename to ...
8816 (block_unblock_async_io): ... it. New function.
8817 (enable_async_io): Don't install SIGIO handler. Unblock it
8818 instead.
8819 (disable_async_io): Don't ignore SIGIO. Block it instead.
8820 (initialize_async_io): Install SIGIO handler. Don't call
8821 unblock_async_io.
8822
18879fef
YQ
88232016-01-26 Yao Qi <yao.qi@linaro.org>
8824
8825 * remote-utils.c (getpkt): If the buffer isn't empty, and the
8826 first character is '\003', call *the_target->request_interrupt.
8827
a0f8e08a
YQ
88282016-01-25 Yao Qi <yao.qi@linaro.org>
8829
8830 * remote-utils.c (new_thread_notify): Remove.
8831 (dead_thread_notify): Likewise.
8832 * remote-utils.h (new_thread_notify): Remove declaration.
8833 (dead_thread_notify): Likewise.
8834
cc5fd9ab
MK
88352016-01-23 Marcin Kościelnicki <koriakin@0x04.net>
8836
8837 * gdb.trace/pending.exp: Fix expected message on continue.
8838
99e8eb11
MK
88392016-01-22 Marcin Kościelnicki <koriakin@0x04.net>
8840
8841 * tracepoint.c (write_inferior_data_ptr): Cast to uintptr_t, so that
8842 it works properly on big-endian machines where sizeof (CORE_ADDR)
8843 != sizeof (void *).
8844
a994041d
PA
88452016-01-21 Pedro Alves <palves@redhat.com>
8846
8847 * Makefile.in (COMPILER_CFLAGS, CXXFLAGS): New.
8848 (INTERNAL_CFLAGS_BASE): Use COMPILER_CFLAGS instead of CFLAGS.
8849 * configure: Regenerate.
8850
f7a6a40d
YQ
88512016-01-21 Yao Qi <yao.qi@linaro.org>
8852
8853 * linux-arm-low.c (arm_sigreturn_next_pc): Add parameter
8854 is_thumb and set it according to CPSR saved on the stack.
8855 (get_next_pcs_syscall_next_pc): Pass is_thumb to
8856 arm_sigreturn_next_pc.
8857
6f69e520
YQ
88582016-01-18 Yao Qi <yao.qi@linaro.org>
8859
8860 * linux-low.c (linux_set_pc_64bit): New function.
8861 (linux_get_pc_64bit): New function.
8862 * linux-low.h (linux_set_pc_64bit, linux_get_pc_64bit):
8863 Declare.
8864 * linux-sparc-low.c (debug_threads): Remove declaration.
8865 (sparc_get_pc): Remove.
8866 (the_low_target): Use linux_get_pc_64bit instead of
8867 sparc_get_pc.
8868 * linux-tile-low.c (tile_get_pc, tile_set_pc): Remove.
8869 (the_low_target): Use linux_get_pc_64bit and
8870 linux_set_pc_64bit.
8871
276d4552
YQ
88722016-01-18 Yao Qi <yao.qi@linaro.org>
8873
8874 * linux-arm-low.c (debug_threads): Remove declaration.
8875 (arm_get_pc, arm_set_pc): Remove.
8876 (the_low_target): Use linux_get_pc_32bit and
8877 linux_set_pc_32bit.
8878 * linux-bfin-low.c (bfin_get_pc, bfin_set_pc): Remove.
8879 (the_low_target): Use linux_get_pc_32bit and
8880 linux_set_pc_32bit.
8881 * linux-cris-low.c (debug_threads): Remove declaration.
8882 (cris_get_pc, cris_set_pc,): Remove.
8883 (the_low_target): Use linux_get_pc_32bit and
8884 linux_set_pc_32bit.
8885 * linux-crisv32-low.c (debug_threads): Remove declaration.
8886 (cris_get_pc, cris_set_pc): Remove.
8887 (the_low_target): Use linux_get_pc_32bit and
8888 linux_set_pc_32bit.
8889 * linux-low.c: Include inttypes.h.
8890 (linux_get_pc_32bit, linux_set_pc_32bit): New functions.
8891 * linux-low.h (linux_get_pc_32bit, linux_set_pc_32bit): Declare.
8892 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Remove.
8893 (the_low_target): Use linux_get_pc_32bit and
8894 linux_set_pc_32bit.
8895 * linux-m68k-low.c (m68k_get_pc, m68k_set_pc): Remove.
8896 (the_low_target): Use linux_get_pc_32bit and
8897 linux_set_pc_32bit.
8898 * linux-nios2-low.c (nios2_get_pc, nios2_set_pc): Remove.
8899 (the_low_target): Use linux_get_pc_32bit and
8900 linux_set_pc_32bit.
8901 * linux-sh-low.c (sh_get_pc, sh_set_pc): Remove.
8902 (the_low_target): Use linux_get_pc_32bit and
8903 linux_set_pc_32bit.
8904 * linux-xtensa-low.c (xtensa_get_pc, xtensa_set_pc): Remove.
8905 (the_low_target): Use linux_get_pc_32bit and
8906 linux_set_pc_32bit.
8907
eb0edac8
GB
89082016-01-18 Gary Benson <gbenson@redhat.com>
8909
8910 * configure.ac (AC_FUNC_FORK): New check.
8911 * config.in: Regenerate.
8912 * configure: Likewise.
8913
1b451dda
YQ
89142016-01-14 Yao Qi <yao.qi@linaro.org>
8915
8916 * linux-aarch32-low.c (thumb2_breakpoint): Make it static.
8917 * linux-aarch32-low.h (thumb2_breakpoint): Remove declaration.
8918 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Pass 1 to
8919 arm_get_next_pcs_ctor.
8920
82075af2
JS
89212016-01-12 Josh Stone <jistone@redhat.com>
8922 Philippe Waroquiers <philippe.waroquiers@skynet.be>
8923
8924 * inferiors.h: Include "gdb_vecs.h".
8925 (struct process_info): Add syscalls_to_catch.
8926 * inferiors.c (remove_process): Free syscalls_to_catch.
8927 * remote-utils.c (prepare_resume_reply): Report syscall_entry and
8928 syscall_return stops.
8929 * server.h (UNKNOWN_SYSCALL, ANY_SYSCALL): Define.
8930 * server.c (handle_general_set): Handle QCatchSyscalls.
8931 (handle_query): Report support for QCatchSyscalls.
8932 * target.h (struct target_ops): Add supports_catch_syscall.
8933 (target_supports_catch_syscall): New macro.
8934 * linux-low.h (struct linux_target_ops): Add get_syscall_trapinfo.
8935 (struct lwp_info): Add syscall_state.
8936 * linux-low.c (handle_extended_wait): Mark syscall_state as an entry.
8937 Maintain syscall_state and syscalls_to_catch across exec.
8938 (get_syscall_trapinfo): New function, proxy to the_low_target.
8939 (linux_low_ptrace_options): Enable PTRACE_O_TRACESYSGOOD.
8940 (linux_low_filter_event): Toggle syscall_state entry/return for
8941 syscall traps, and set it ignored for all others.
8942 (gdb_catching_syscalls_p): New function.
8943 (gdb_catch_this_syscall_p): New function.
8944 (linux_wait_1): Handle SYSCALL_SIGTRAP.
8945 (linux_resume_one_lwp_throw): Add PTRACE_SYSCALL possibility.
8946 (linux_supports_catch_syscall): New function.
8947 (linux_target_ops): Install it.
8948 * linux-x86-low.c (x86_get_syscall_trapinfo): New function.
8949 (the_low_target): Install it.
8950
8f13a3ce
MF
89512016-01-12 Mike Frysinger <vapier@gentoo.org>
8952
8953 * acinclude.m4: Include new ../warning.m4 file.
8954 * configure: Regenerated.
8955 * configure.ac: Replace all warning logic with AM_GDB_WARNINGS.
8956
5b3da067
MF
89572016-01-12 Mike Frysinger <vapier@gentoo.org>
8958
8959 * ax.c (is_goto_target): Mark static.
8960 * linux-low.c (register_addr): Likewise.
8961 (linux_fetch_registers, linux_store_registers): Likewise.
8962 * mem-break.c (any_persistent_commands): Fix old prototype.
8963 (add_commands_to_breakpoint): Mark static.
8964 * regcache.c (find_register_by_name): Delete unused func.
8965 * remote-utils.c (hex_or_minus_one): Mark static.
8966 * server.c (monitor_show_help): Mark static.
8967 (handle_query, handle_v_cont, handle_v_attach, handle_v_kill,
8968 handle_v_requests): Likewise.
8969
bc504a31
PA
89702016-01-12 Pedro Alves <palves@redhat.com>
8971
8972 Remove use of the registered trademark symbol throughout.
8973
5a0dd67a
YQ
89742016-01-08 Yao Qi <yao.qi@linaro.org>
8975
8976 * remote-utils.c (getpkt): If c is '\003', call target hook
8977 request_interrupt.
8978
b2ca446f
YQ
89792016-01-06 Yao Qi <yao.qi@linaro.org>
8980
8981 * linux-aarch32-low.h (arm_abi_breakpoint): Move to
8982 linux-aarch32-low.c.
8983 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
8984 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
8985 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
8986 (thumb2_breakpoint): Declare.
8987 * linux-aarch32-low.c (arm_abi_breakpoint): Moved from
8988 linux-aarch32-low.h.
8989 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
8990 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
8991 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
8992
edd88788
JB
89932016-01-01 Joel Brobecker <brobecker@adacore.com>
8994
8995 * gdbreplay.c (gdbreplay_version): Change copyright year in
8996 version message.
8997 * server.c (gdbserver_version): Likewise.
8998
65da7f14
PP
89992015-12-28 Patrick Palka <patrick@parcs.ath.cx>
9000
9001 * server.c (crc32_table): Delete.
9002 (crc32): Use libiberty's xcrc32 function.
9003
4abd5ed2
JB
90042015-12-22 Joel Brobecker <brobecker@adacore.com>
9005
9006 * lynx-low.c (lynx_delete_thread_callback): New function.
9007 (lynx_mourn): Properly delete our process and all of its
9008 threads. Remove call to clear_inferiors.
9009
0e50fe5c
JB
90102015-12-22 Joel Brobecker <brobecker@adacore.com>
9011
9012 * target.c (thread_search_callback): Add check that
9013 the thread_stopped target callback is not NULL before
9014 calling it.
9015
35adc03f
YQ
90162015-12-21 Yao Qi <yao.qi@linaro.org>
9017
9018 * linux-aarch32-low.h [__aarch64__]: Use arm_abi_breakpoint
9019 arm breakpoint.
9020
bd2b2909
AT
90212015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
9022
9023 * server.c (handle_query): Call target_supports_software_single_step.
9024
7fe5e27e
AT
90252015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
9026
9027 * linux-low.c (single_step): New function.
9028 (linux_resume_one_lwp_throw): Call single_step.
9029 (start_step_over): Likewise.
9030
d9311bfa
AT
90312015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
9032
9033 * Makefile.in (SFILES): Append arch/arm-linux.c,
9034 arch/arm-get-next-pcs.c.
9035 (arm-linux.o): New rule.
9036 (arm-get-next-pcs.o): New rule.
9037 * configure.srv (arm*-*-linux*): Add arm-get-next-pcs.o,
9038 arm-linux.o.
9039 * linux-aarch32-low.c (arm_abi_breakpoint): Remove macro. Moved
9040 to linux-aarch32-low.c.
9041 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
9042 (arm_breakpoint_len, thumb_breakpoint): Likewise.
9043 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
9044 (thumb2_breakpoint_len): Likewise.
9045 (arm_is_thumb_mode): Make non-static.
9046 * linux-aarch32-low.h (arm_abi_breakpoint): New macro. Moved
9047 from linux-aarch32-low.c.
9048 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
9049 (arm_breakpoint_len, thumb_breakpoint): Likewise.
9050 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
9051 (thumb2_breakpoint_len): Likewise.
9052 (arm_is_thumb_mode): New declaration.
9053 * linux-arm-low.c: Include arch/arm-linux.h
9054 aarch/arm-get-next-pcs.h, sys/syscall.h.
9055 (get_next_pcs_ops): New struct.
9056 (get_next_pcs_addr_bits_remove): New function.
9057 (get_next_pcs_is_thumb): New function.
9058 (get_next_pcs_read_memory_unsigned_integer): Likewise.
9059 (arm_sigreturn_next_pc): Likewise.
9060 (get_next_pcs_syscall_next_pc): Likewise.
9061 (arm_gdbserver_get_next_pcs): Likewise.
9062 (struct linux_target_ops) <arm_gdbserver_get_next_pcs>:
9063 Initialize.
9064 * linux-low.h: Move CORE_ADDR vector definition to gdb_vecs.h.
9065 * server.h: Include gdb_vecs.h.
9066
68ce2059
AT
90672015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
9068
9069 * Makefile.in (SFILES): Append common/common-regcache.c.
9070 (OBS): Append common-regcache.o.
9071 (common-regcache.o): New rule.
9072 * regcache.c (init_register_cache): Initialize cache to
9073 REG_UNAVAILABLE.
9074 (regcache_raw_read_unsigned): New function.
9075 * regcache.h (REG_UNAVAILABLE, REG_VALID): Replaced by shared
9076 register_status enum.
9077
fa5308bd
AT
90782015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
9079
9080 * linux-aarch64-low.c (the_low_targets): Rename
9081 breakpoint_reinsert_addr to get_next_pcs.
9082 * linux-arm-low.c (the_low_targets): Likewise.
9083 * linux-bfin-low.c (the_low_targets): Likewise.
9084 * linux-cris-low.c (the_low_targets): Likewise.
9085 * linux-crisv32-low.c (the_low_targets): Likewise.
9086 * linux-low.c (can_software_single_step): Likewise.
9087 (install_software_single_step_breakpoints): New function.
9088 (start_step_over): Use install_software_single_step_breakpoints.
9089 * linux-low.h: New CORE_ADDR vector.
9090 (struct linux_target_ops) Rename breakpoint_reinsert_addr to
9091 get_next_pcs.
9092 * linux-mips-low.c (the_low_targets): Likewise.
9093 * linux-nios2-low.c (the_low_targets): Likewise.
9094 * linux-sparc-low.c (the_low_targets): Likewise.
9095
4a6ed09b
PA
90962015-12-17 Pedro Alves <palves@redhat.com>
9097
9098 * linux-low.c (linux_kill_one_lwp): Remove references to
9099 LinuxThreads.
9100 (kill_lwp): Remove HAVE_TKILL_SYSCALL check. No longer fall back
9101 to 'kill'.
9102 (linux_init_signals): Delete.
9103 (initialize_low): Adjust.
9104 * thread-db.c (thread_db_init): Remove LinuxThreads reference.
9105
7544db95
PA
91062015-12-16 Pedro Alves <palves@redhat.com>
9107
9108 * configure.ac (compiler warning flags): When testing a
9109 -Wno-foo option, check whether -Wfoo works instead.
9110 * configure: Regenerate.
9111
8020350c
DB
91122015-12-11 Don Breazeal <donb@codesourcery.com>
9113
9114 * server.c (process_serial_event): Don't exit from gdbserver
9115 in remote mode if there are still active inferiors.
9116
db91f502
YQ
91172015-12-11 Yao Qi <yao.qi@linaro.org>
9118
9119 * linux-aarch64-low.c (aarch64_breakpoint_at): Call
9120 arm_breakpoint_at if the process is 32-bit.
9121
b37a6290
YQ
91222015-12-11 Yao Qi <yao.qi@linaro.org>
9123
9124 * linux-aarch32-low.c [__aarch64__]: Use arm_abi_breakpoint
9125 arm breakpoint.
9126
17b1509a
YQ
91272015-12-07 Yao Qi <yao.qi@linaro.org>
9128
9129 * configure.srv: Append arm.o to srv_tgtobj for
9130 aarch64*-*-linux* target.
9131 * linux-aarch32-low.c (arm_abi_breakpoint): New macro. Moved
9132 from linux-arm-low.c.
9133 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
9134 (arm_breakpoint_len, thumb_breakpoint): Likewise.
9135 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
9136 (thumb2_breakpoint_len): Likewise.
9137 (arm_is_thumb_mode, arm_breakpoint_at): Likewise.
9138 (arm_breakpoint_kinds): Likewise.
9139 (arm_breakpoint_kind_from_pc): Likewise.
9140 (arm_sw_breakpoint_from_kind): Likewise.
9141 (arm_breakpoint_kind_from_current_state): Likewise.
9142 * linux-aarch32-low.h (arm_breakpoint_kind_from_pc): Declare.
9143 (arm_sw_breakpoint_from_kind): Declare.
9144 (arm_breakpoint_kind_from_current_state): Declare.
9145 (arm_breakpoint_at): Declare.
9146 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): Call
9147 arm_sw_breakpoint_from_kind if process is 32-bit.
9148 (aarch64_breakpoint_kind_from_pc): New function.
9149 (aarch64_breakpoint_kind_from_current_state): New function.
9150 (the_low_target): Initialize fields breakpoint_kind_from_pc
9151 and breakpoint_kind_from_current_state.
9152 * linux-arm-low.c (arm_breakpoint_kinds): Move to
9153 linux-aarch32-low.c.
9154 (arm_abi_breakpoint, arm_eabi_breakpoint): Likewise.
9155 (arm_breakpoint, arm_breakpoint_len): Likewise.
9156 (thumb_breakpoint, thumb_breakpoint_len): Likewise.
9157 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
9158 (arm_is_thumb_mode): Likewise.
9159 (arm_breakpoint_at): Likewise.
9160 (arm_breakpoint_kind_from_pc): Likewise.
9161 (arm_sw_breakpoint_from_kind): Likewise.
9162 (arm_breakpoint_kind_from_current_state): Likewise.
9163
9164 Revert:
9165 2015-08-04 Yao Qi <yao.qi@linaro.org>
9166
9167 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
9168 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
9169 * server.c (extended_protocol): Remove "static".
9170 * server.h (extended_protocol): Declare it.
9171
ece66d65
JS
91722015-12-04 Josh Stone <jistone@redhat.com>
9173
9174 * target.h (struct target_ops) <arch_setup>: Rename to ...
9175 (struct target_ops) <post_create_inferior>: ... this.
9176 (target_arch_setup): Rename to ...
9177 (target_post_create_inferior): ... this, calling post_create_inferior.
9178 * server.c (start_inferior): Update target_arch_setup calls to
9179 target_post_create_inferior.
9180 * linux-low.c (linux_low_ptrace_options): Forward declare.
9181 (linux_arch_setup): Update its comment for general use.
9182 (linux_post_create_inferior): New, run arch_setup and setup ptrace.
9183 (struct linux_target_ops): Use linux_post_create_inferior.
9184 * lynx-low.c (struct lynx_target_ops): Update arch_setup stub comment
9185 to post_create_inferior.
9186 * nto-low.c (struct nto_target_ops): Likewise.
9187 * spu-low.c (struct spu_target_ops): Likewise.
9188 * win32-low.c (struct win32_target_ops): Likewise.
9189
e58c48b4
AT
91902015-12-03 Antoine Tremblay <antoine.tremblay@ericsson.com>
9191
9192 * linux-arm-low.c: Remove duplicate arch/arm.h include.
9193
fbec8956
AT
91942015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
9195
9196 * linux-arm-low.c (arm_reinsert_addr): Remove function.
9197 (struct linux_target_ops <breakpoint_reinsert_addr>: Set to NULL.
9198 * linux-cris-low.c (cris_reinsert_addr> Remove function.
9199 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
9200 * linux-crisv32-low.c (cris_reinsert_addr): Remove function.
9201 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
9202 * linux-mips-low.c (mips_reinsert_addr): Remove function.
9203 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
9204 * linux-nios2-low.c (nios2_reinsert_addr): Remove function.
9205 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
9206 * linux-sparc-low.c (sparc_reinsert_addr): Remove function.
9207 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
9208
9b4c5f87
AT
92092015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
9210
9211 * linux-low.c (linux_look_up_symbols): Don't call
9212 linux_supports_traceclone.
9213 * linux-low.h (thread_db_init): Remove use_events argument.
9214 * thread-db.c (thread_db_use_event): Remove global variable.
9215 (struct thread_db) <td_thr_event_enable_p>: Remove field.
9216 (struct thread_db) <td_create_bp>: Remove field.
9217 (thread_db_create_event): Remove function.
9218 (thread_db_enable_reporting): Likewise.
9219 (find_one_thread): Don't check for thread_db_use_events.
9220 (attach_thread): Likewise.
9221 (thread_db_load_search): Remove td_thr_event_enable_p initialization.
9222 (try_thread_db_load_1): Don't check for thread_db_use_events.
9223 (thread_db_init): Remove use_events argument and thread events
9224 handling.
9225 (remove_thread_event_breakpoints): Remove function.
9226 (thread_db_detach): Remove call to remove_thred_event_breakpoints.
9227
7d00775e
AT
92282015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
9229
9230 * linux-aarch64-low.c (aarch64_supports_hardware_single_step):
9231 New function.
9232 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9233 * linux-arm-low.c (arm_supports_hardware_single_step): New function.
9234 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9235 * linux-bfin-low.c (bfin_supports_hardware_single_step): New function.
9236 (struct linux_target_ops) <bfin_supports_hardware_single_step>:
9237 Initialize.
9238 * linux-crisv32-low.c (cris_supports_hardware_single_step):
9239 New function.
9240 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9241 * linux-low.c (can_hardware_single_step): Use
9242 supports_hardware_single_step.
9243 (can_software_single_step): New function.
9244 (start_step_over): Call can_software_single_step.
9245 (linux_supports_hardware_single_step): New function.
9246 (struct target_ops) <supports_software_single_step>: Initialize.
9247 * linux-low.h (struct linux_target_ops)
9248 <supports_hardware_single_step>: Initialize.
9249 * linux-m32r-low.c (m32r_supports_hardware_single_step): New function.
9250 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9251 * linux-ppc-low.c (ppc_supports_hardware_single_step): New function.
9252 (struct linux_target_ops) <supports_hardware_single_step> Initialize.
9253 * linux-s390-low.c (s390_supports_hardware_single_step): New function.
9254 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9255 * linux-sh-low.c (sh_supports_hardware_single_step): New function.
9256 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9257 * linux-tic6x-low.c (tic6x_supports_hardware_single_step): New function.
9258 (struct linux_target_ops) <tic6x_supports_hardware_single_step>:
9259 Initialize.
9260 * linux-tile-low.c (tile_supports_hardware_single_step): New function.
9261 (struct linux_target_ops) <tile_supports_hardware_single_step>:
9262 Initialize.
9263 * linux-x86-low.c (x86_supports_hardware_single_step) New function.
9264 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9265 * linux-xtensa-low.c (xtensa_supports_hardware_single_step):
9266 New function.
9267 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9268 * target.h (struct target_ops): <supports_software_single_step>:
9269 New field.
9270 (target_supports_software_single_step): New macro.
9271
2d97cd35
AT
92722015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
9273
9274 * linux-low.c (linux_wait_1): Fix pc advance condition.
9275 * mem-break.c (reinsert_breakpoint_inserted_here): New function.
9276 * mem-break.h (reinsert_breakpoint_inserted_here): New declaration.
9277
769ef81f
AT
92782015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
9279
9280 * linux-arm-low.c (arm_is_thumb_mode): New function.
9281 (arm_breakpoint_at): Use arm_is_thumb_mode.
9282 (arm_breakpoint_kind_from_current_state): New function.
9283 (struct linux_target_ops) <breakpoint_kind_from_current_state>:
9284 Initialize.
9285 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_current_state.
9286 (linux_breakpoint_kind_from_current_state): New function.
9287 (struct target_ops <breakpoint_kind_from_current_state>: Initialize.
9288 * linux-low.h (struct linux_target_ops)
9289 <breakpoint_kind_from_current_state>: New field.
9290 * target.h (struct target_ops): Likewise.
9291 (target_breakpoint_kind_from_current_state): New macro.
9292
1bebeeca
PA
92932015-11-30 Pedro Alves <palves@redhat.com>
9294
9295 * linux-low.c (linux_resume): Wake up the event loop before
9296 returning.
9297
a67a9fae
PA
92982015-11-30 Pedro Alves <palves@redhat.com>
9299
9300 * mem-break.c (check_gdb_bp_preconditions): Remove current_thread
9301 check.
9302 (set_gdb_breakpoint): If prepare_to_access_memory fails, set *ERR
9303 to -1.
9304 * target.c (struct thread_search): New structure.
9305 (thread_search_callback): New function.
9306 (prev_general_thread): New global.
9307 (prepare_to_access_memory, done_accessing_memory): New functions.
9308 * target.h (prepare_to_access_memory, done_accessing_memory):
9309 Replace macros with function declarations.
9310
f2faf941
PA
93112015-11-30 Pedro Alves <palves@redhat.com>
9312
9313 PR 14618
9314 * linux-low.c (linux_wait_1): If the last resumed thread is gone,
9315 report TARGET_WAITKIND_NO_RESUMED.
9316 * remote-utils.c (prepare_resume_reply): Handle
9317 TARGET_WAITKIND_NO_RESUMED.
9318 * server.c (report_no_resumed): New global.
9319 (handle_query) <qSupported>: Handle "no-resumed+". Report
9320 "no-resumed+" support.
9321 (resume): When the target reports TARGET_WAITKIND_NO_RESUMED, only
9322 return error if the client doesn't support no-resumed events.
9323 (push_stop_notification): New function.
9324 (handle_target_event): Use it. Report TARGET_WAITKIND_NO_RESUMED
9325 events if the client supports them.
9326
a681f9c9
PA
93272015-11-30 Pedro Alves <palves@redhat.com>
9328
9329 * linux-low.c (thread_still_has_status_pending_p): Don't check
9330 vCont;t here.
9331 (lwp_resumed): New function.
9332 (status_pending_p_callback): Return early if the LWP is not
9333 supposed to be resumed.
9334
65706a29
PA
93352015-11-30 Pedro Alves <palves@redhat.com>
9336
9337 * linux-low.c (handle_extended_wait): Assert that the LWP's
9338 waitstatus is TARGET_WAITKIND_IGNORE. If GDB wants to hear about
9339 thread create events, leave the new child's status pending.
9340 (linux_low_filter_event): If GDB wants to hear about thread exit
9341 events, leave the LWP marked dead and don't delete it.
9342 (linux_wait_for_event_filtered): Don't check for thread exit.
9343 (filter_exit_event): New function.
9344 (linux_wait_1): Use it, when returning an exit event.
9345 (linux_resume_one_lwp_throw): Assert that the LWP's
9346 waitstatus is TARGET_WAITKIND_IGNORE.
9347 * remote-utils.c (prepare_resume_reply): Handle
9348 TARGET_WAITKIND_THREAD_CREATED and TARGET_WAITKIND_THREAD_EXITED.
9349 * server.c (report_thread_events): New global.
9350 (handle_general_set): Handle QThreadEvents.
9351 (handle_query) <qSupported>: Handle and report QThreadEvents+;
9352 (handle_target_event): Handle TARGET_WAITKIND_THREAD_CREATED and
9353 TARGET_WAITKIND_THREAD_EXITED.
9354 * server.h (report_thread_events): Declare.
9355
56cf4bed
PA
93562015-11-30 Pedro Alves <palves@redhat.com>
9357
9358 * linux-low.c (resume_stopped_resumed_lwps): Don't check whether
9359 the thread's last_resume_kind was resume_stop.
9360
500c1d85
PA
93612015-11-30 Pedro Alves <palves@redhat.com>
9362
9363 * linux-low.c (linux_attach): In non-stop mode, wait for one stop
9364 before returning.
9365
de979965
PA
93662015-11-30 Pedro Alves <palves@redhat.com>
9367
9368 * server.c (handle_v_requests): Handle vCtrlC.
9369
34c65914
PA
93702015-11-30 Pedro Alves <palves@redhat.com>
9371
9372 * gdbthread.h (find_any_thread_of_pid): Declare.
9373 * inferiors.c (thread_of_pid, find_any_thread_of_pid): New
9374 functions.
9375 * server.c (handle_query): If current_thread is NULL, look for
9376 another thread of the selected process.
9377
79efa585 93782015-11-26 Daniel Colascione <dancol@dancol.org>
01a49af8 9379 Simon Marchi <simon.marchi@ericsson.com>
79efa585
SM
9380
9381 * linux-low.c (linux_target_ops): Use linux_proc_tid_get_name.
9382 * server.c (handle_qxfer_threads_worker): Refactor to include thread
9383 name in reply.
9384 * target.h (struct target_ops) <thread_name>: New field.
9385 (target_thread_name): New macro.
9386
80d82c19
JB
93872015-11-23 Joel Brobecker <brobecker@adacore.com>
9388
9389 * regcache.h (regcache_invalidate_pid): Add declaration.
9390 * regcache.c (regcache_invalidate_pid): New function, extracted
9391 from regcache_invalidate.
9392 (regcache_invalidate): Reimplement using regcache_invalidate_pid.
9393 Add trivial documentation comment.
9394 * lynx-low.c: Use regcache_invalidate_pid instead of
9395 regcache_invalidate.
9396
64da5dd5
JB
93972015-11-23 Joel Brobecker <brobecker@adacore.com>
9398
9399 * configure.ac: Do not call AC_CHECK_TYPES for Elf32_auxv_t
9400 and Elf64_auxv_t if the target is Android.
9401
37ce4055
DE
94022015-11-22 Doug Evans <xdje42@gmail.com>
9403
9404 * target.h: #include <sys/types.h>.
9405
06e03fff
PA
94062015-11-19 Pedro Alves <palves@redhat.com>
9407
9408 * linux-low.c (linux_process_qsupported): Change prototype.
9409 Adjust.
9410 * linux-low.h (struct linux_target_ops) <process_qsupported>:
9411 Change prototype.
9412 * linux-x86-low.c (x86_linux_process_qsupported): Change prototype
9413 and adjust to loop over all features.
9414 * server.c (handle_query) <qSupported>: Adjust to call
9415 target_process_qsupported once, passing it a vector of unprocessed
9416 features.
9417 * target.h (struct target_ops) <process_qsupported>: Change
9418 prototype.
9419 (target_process_qsupported): Adjust.
9420
9a084706
PA
94212015-11-19 Pedro Alves <palves@redhat.com>
9422
9423 * configure.ac (ERROR_ON_WARNING): Don't check whether in C++
9424 mode.
9425 * configure: Regenerate.
9426
dad44a1f
PA
94272015-11-19 Pedro Alves <palves@redhat.com>
9428
9429 * configure: Regenerate.
9430
231c0592
YQ
94312015-11-19 Yao Qi <yao.qi@linaro.org>
9432
9433 * linux-aarch64-low.c (emit_data_processing_reg): Change opcode
9434 type to uint32_t.
9435
6c1c9a8b
YQ
94362015-11-19 Yao Qi <yao.qi@linaro.org>
9437
9438 * linux-aarch64-low.c (enum aarch64_operand_type): New.
9439 (struct aarch64_operand): Move enum out.
9440
9caa3311
YQ
94412015-11-19 Yao Qi <yao.qi@linaro.org>
9442
9443 * linux-aarch64-low.c (aarch64_fill_fpregset): Cast buf to
9444 struct user_fpsimd_state *.
9445 (aarch64_store_fpregset): Likewise.
9446
6a69a054
YQ
94472015-11-19 Yao Qi <yao.qi@linaro.org>
9448
9449 * linux-aarch64-low.c (aarch64_fill_gregset): Cast buf to
9450 struct user_pt_regs *.
9451 (aarch64_store_gregset): Likewise.
9452
1798301e
PA
94532015-11-18 Pedro Alves <palves@redhat.com>
9454
9455 * Makefile.in (all_object_files): Add $IPA_OBJS.
9456
ce7715e2
PA
94572015-11-17 Pedro Alves <palves@redhat.com>
9458
9459 * win32-low.c (win32_resume): Use gdb_signal_from_host,
9460 GDB_SIGNAL_0 and gdb_signal_to_string.
9461
c0879059
PA
94622015-11-17 Pedro Alves <palves@redhat.com>
9463
9464 * win32-low.c (handle_output_debug_string): Remove parameter.
9465 (win32_kill): Remove our_status local and adjust call to
9466 handle_output_debug_string.
9467 (get_child_debug_event): Adjust call to
9468 handle_output_debug_string.
9469
1996e237
SM
94702015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9471
9472 * linux-mips-low.c (mips_fill_gregset): Add cast.
9473 (mips_store_gregset): Likewise.
9474 (mips_fill_fpregset): Likewise.
9475 (mips_store_fpregset): Likewise.
9476
cbec665b
SM
94772015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9478
9479 * linux-mips-low.c (mips_add_watchpoint): Rename private to
9480 priv.
9481
eb3e3c67
SM
94822015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9483
9484 * linux-mips-low.c (mips_linux_new_thread): Change type of
9485 watch_type to enum target_hw_bp_type.
9486
171de4b8
SM
94872015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9488
9489 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type):
9490 Change return type to arm_hwbp_type.
9491
04248ead
SM
94922015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9493
9494 * linux-aarch32-low.c (arm_fill_gregset): Add cast.
9495 (arm_store_gregset): Likewise.
9496 * linux-arm-low.c (arm_get_hwcap): Likewise.
9497 (arm_read_description): Likewise.
9498
04b3479c
SM
94992015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9500
9501 * linux-aarch32-low.c (aarch32_regsets): Use NULL_REGSET.
9502
2bc84e8a
SM
95032015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9504
9505 * linux-ppc-low.c (ppc_get_hwcap): Add cast.
9506 (ppc_fill_vsxregset): Likewise.
9507 (ppc_store_vsxregset): Likewise.
9508 (ppc_fill_vrregset): Likewise.
9509 (ppc_store_vrregset): Likewise.
9510 (ppc_fill_evrregset): Likewise.
9511 (ppc_store_evrregset): Likewise.
9512
e6c5bb05
SM
95132015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9514
9515 * linux-ppc-low.c (ppc_usrregs_info): Remove
9516 forward-declaration.
9517 (ppc_arch_setup): Move lower in file.
9518
7ea45d72
SM
95192015-10-30 Simon Marchi <simon.marchi@ericsson.com>
9520
9521 * proc-service.c (ps_pdread): Change CORE_ADDR cast to uintptr_t.
9522 (ps_pdwrite): Likewise.
9523
69291610
HW
95242015-10-29 Henrik Wallin <henrik.wallin@windriver.com>
9525
9526 * linux-arm-low.c (arm_new_thread): Move pointer dereference
9527 to after assert checks.
9528
b42945fd
SM
95292015-10-29 Simon Marchi <simon.marchi@ericsson.com>
9530
9531 * proc-service.c (ps_pdread): Add/adjust casts.
9532 (ps_pdwrite): Add/adjust casts.
9533
d6f85c84
SM
95342015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
9535
9536 * server.c (handle_search_memory_1): Cast return value of
9537 memmem.
9538
f98cd059
SM
95392015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
9540
9541 * server.c (write_qxfer_response): Change type of data to
9542 gdb_byte *.
9543
d2412fa5
PA
95442015-10-29 Pedro Alves <palves@redhat.com>
9545
9546 * mem-break.c (Z_packet_to_bkpt_type): Add cast.
9547
c17414a2
PA
95482015-10-29 Pedro Alves <palves@redhat.com>
9549
9550 * tracepoint.c (clear_installed_tracepoints): Add casts.
9551
e053fbc4
PA
95522015-10-29 Pedro Alves <palves@redhat.com>
9553
9554 * server.c (handle_v_cont, process_serial_event): Add enum
9555 gdb_signal casts to signal parsing code.
9556
add67df8
PA
95572015-10-29 Pedro Alves <palves@redhat.com>
9558
9559 * linux-low.h (NULL_REGSET): Define.
9560 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
9561 * linux-arm-low.c (arm_regsets): Likewise.
9562 * linux-crisv32-low.c (cris_regsets): Likewise.
9563 * linux-m68k-low.c (m68k_regsets): Likewise.
9564 * linux-mips-low.c (mips_regsets): Likewise.
9565 * linux-nios2-low.c (nios2_regsets): Likewise.
9566 * linux-ppc-low.c (ppc_regsets): Likewise.
9567 * linux-s390-low.c (s390_regsets): Likewise.
9568 * linux-sh-low.c (sh_regsets): Likewise.
9569 * linux-sparc-low.c (sparc_regsets): Likewise.
9570 * linux-tic6x-low.c (tic6x_regsets): Likewise.
9571 * linux-tile-low.c (tile_regsets): Likewise.
9572 * linux-x86-low.c (x86_regsets): Likewise.
9573 * linux-xtensa-low.c (xtensa_regsets): Likewise.
9574
50bc912a
PA
95752015-10-29 Pedro Alves <palves@redhat.com>
9576
9577 * linux-low.h (NULL_REGSET): Define.
9578 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
9579 * linux-arm-low.c (arm_regsets): Likewise.
9580 * linux-crisv32-low.c (cris_regsets): Likewise.
9581 * linux-m68k-low.c (m68k_regsets): Likewise.
9582 * linux-mips-low.c (mips_regsets): Likewise.
9583 * linux-nios2-low.c (nios2_regsets): Likewise.
9584 * linux-ppc-low.c (ppc_regsets): Likewise.
9585 * linux-s390-low.c (s390_regsets): Likewise.
9586 * linux-sh-low.c (sh_regsets): Likewise.
9587 * linux-sparc-low.c (sparc_regsets): Likewise.
9588 * linux-tic6x-low.c (tic6x_regsets): Likewise.
9589 * linux-tile-low.c (tile_regsets): Likewise.
9590 * linux-x86-low.c (x86_regsets): Likewise.
9591 * linux-xtensa-low.c (xtensa_regsets): Likewise.
9592
682b2546
DE
95932015-10-26 Doug Evans <dje@google.com>
9594
9595 * linux-low.c (__SIGRTMIN): Move to nat/linux-nat.h.
9596
963843d4
DE
95972015-10-26 Doug Evans <dje@google.com>
9598
9599 * linux-low.c (W_STOPCODE): Moved to common/gdb_wait.h.
9600
d41401ac
DE
96012015-10-26 Doug Evans <dje@google.com>
9602
9603 * thread-db.c (find_one_thread): Cast ti.ti_tid to unsigned long
9604 for debug_printf.
9605 (attach_thread, find_new_threads_callback): Ditto.
9606
3db28855
AT
96072015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
9608
9609 * mem-break.h (set_breakpoint_data): Remove.
9610
fb78e89c
AT
96112015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
9612
9613 * nto-low.c (nto_sw_breakpoint_from_kind): New function.
9614 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
9615 (initialize_low): Remove set_breakpoint_data call.
9616 * spu-low.c (spu_sw_breakpoint_from_kind): New function.
9617 (struct target_ops) <sw_breakpoint_from_kind>: Iniitalize.
9618 (initialize_low): Remove set_breakpoint_data call.
9619 * win32-low.c (win32_sw_breakpoint_from_kind): New function.
9620 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
9621 (initialize_low): Remove set_breakpoint_data call.
9622
2e6ee069
AT
96232015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
9624
9625 * linux-low.c (default_breakpoint_kind_from_pc): Move to target.c.
9626 * mem-break.c (set_breakpoint_at): Use target_breakpoint_kind_from_pc.
9627 * target.c (default_breakpoint_kind_from_pc): Moved from linux-low.c
9628 * target.h (target_breakpoint_kind_from_pc): New macro.
9629
1652a986
AT
96302015-10-22 Antoine Tremblay <antoine.tremblay@ericsson.com>
9631
9632 * linux-low.c (default_breakpoint_kind_from_pc): New function.
9633 (linux_breakpoint_kind_from_pc): Use default_breakpoint_kind_from_pc for
9634 the default breakpoint kind.
9635
abeead09
AT
96362015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9637
9638 * linux-arm-low.c (arm_supports_z_point_type): Add software
9639 breakpoint support.
9640
b0b4b501
AT
96412015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9642
9643 * linux-arm-low.c: Refactor breakpoint definitions.
9644 (arm_breakpoint_at): Adjust for arm_abi_breakpoint.
9645 (arm_sw_breakpoint_from_kind): Adjust for arm_breakpoint.
9646
8689682c
AT
96472015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9648
9649 * Makefile.in: Add arm.c/o.
9650 * configure.srv: Likewise.
9651 * linux-arm-low.c (arm_breakpoint_kinds): New enum.
9652 (arm_breakpoint_kind_from_pc): New function.
9653 (arm_sw_breakpoint_from_kind): Return proper kind.
9654 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize.
9655
27165294
AT
96562015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9657
9658 * linux-low.c (initialize_low): Ajdust for breakpoint global variables
9659 removal.
9660 * mem-break.c : Remove breakpoint_data/breakpoint_len global variables.
9661 (struct raw_breakpoint) <size>: Remove.
9662 (struct raw_breakpoint) <kind>: Add.
9663 (bp_size): New function.
9664 (bp_opcode): Likewise.
9665 (find_raw_breakpoint_at): Adjust for kind.
9666 (insert_memory_breakpoint): Adjust for kind call bp_size,bp_opcode.
9667 (remove_memory_breakpoint): Adjust for kind call bp_size.
9668 (set_raw_breakpoint_at): Adjust for kind.
9669 (set_breakpoint): Likewise.
9670 (set_breakpoint_at): Call breakpoint_kind_from_pc.
9671 (delete_raw_breakpoint): Adjust for kind.
9672 (delete_breakpoint): Likewise.
9673 (find_gdb_breakpoint): Likewise.
9674 (set_gdb_breakpoint_1): Likewise.
9675 (set_gdb_breakpoint): Likewise.
9676 (delete_gdb_breakpoint_1): Likewise.
9677 (delete_gdb_breakpoint): Likewise.
9678 (uninsert_raw_breakpoint): Likewise.
9679 (reinsert_raw_breakpoint): Likewise.
9680 (set_breakpoint_data): Remove.
9681 (validate_inserted_breakpoint): Adjust for kind call bp_size,bp_opcode.
9682 (check_mem_read): Adjust for kind call bp_size.
9683 (check_mem_write): Adjust for kind call bp_size,bp_opcode.
9684 (clone_one_breakpoint): Adjust for kind.
9685 * mem-break.h (set_gdb_breakpoint): Likewise.
9686 (delete_gdb_breakpoint): Likewise.
9687 * server.c (process_serial_event): Likewise.
9688
dd373349
AT
96892015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9690
9691 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): New function.
9692 (struct linux_target_ops) <breakpoint>: Remove.
9693 (struct linux_target_ops) <breakpoint_len>: Remove.
9694 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9695 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9696 * linux-arm-low.c (arm_breakpoint_kind_from_pc): New function.
9697 (arm_sw_breakpoint_from_kind): New function.
9698 * linux-bfin-low.c (bfin_sw_breakpoint_from_kind): New function.
9699 (struct linux_target_ops) <breakpoint>: Remove.
9700 (struct linux_target_ops) <breakpoint_len>: Remove.
9701 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9702 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9703 * linux-cris-low.c (cris_sw_breakpoint_from_kind): New function.
9704 (struct linux_target_ops) <breakpoint>: Remove.
9705 (struct linux_target_ops) <breakpoint_len>: Remove.
9706 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9707 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9708 * linux-crisv32-low.c (cris_sw_breakpoint_from_kind): New function.
9709 (struct linux_target_ops) <breakpoint>: Remove.
9710 (struct linux_target_ops) <breakpoint_len>: Remove.
9711 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9712 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9713 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_pc
9714 and sw_breakpoint_from_kind to increment the pc.
9715 (linux_breakpoint_kind_from_pc): New function.
9716 (linux_sw_breakpoint_from_kind): New function.
9717 (struct target_ops) <sw_breakpoint_from_kind>: Initialize field.
9718 (initialize_low): Call breakpoint_kind_from_pc and
9719 sw_breakpoint_from_kind to replace breakpoint_data/len.
9720 * linux-low.h (struct linux_target_ops) <breakpoint_kind_from_pc>:
9721 New field.
9722 (struct linux_target_ops) <sw_breakpoint_from_kind>: Likewise.
9723 * linux-m32r-low.c (m32r_sw_breakpoint_from_kind): New function.
9724 (struct linux_target_ops) <breakpoint>: Remove.
9725 (struct linux_target_ops) <breakpoint_len>: Remove.
9726 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9727 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9728 * linux-m68k-low.c (m68k_sw_breakpoint_from_kind): New function.
9729 (struct linux_target_ops) <breakpoint>: Remove.
9730 (struct linux_target_ops) <breakpoint_len>: Remove.
9731 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9732 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9733 * linux-mips-low.c (mips_sw_breakpoint_from_kind): New function.
9734 (struct linux_target_ops) <breakpoint>: Remove.
9735 (struct linux_target_ops) <breakpoint_len>: Remove.
9736 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9737 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9738 * linux-nios2-low.c (nios2_sw_breakpoint_from_kind): New function.
9739 (struct linux_target_ops) <breakpoint>: Remove.
9740 (struct linux_target_ops) <breakpoint_len>: Remove.
9741 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9742 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9743 * linux-ppc-low.c (ppc_sw_breakpoint_from_kind): New function.
9744 (struct linux_target_ops) <breakpoint>: Remove.
9745 (struct linux_target_ops) <breakpoint_len>: Remove.
9746 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9747 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9748 * linux-s390-low.c (s390_sw_breakpoint_from_kind): New function.
9749 (struct linux_target_ops) <breakpoint>: Remove.
9750 (struct linux_target_ops) <breakpoint_len>: Remove.
9751 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9752 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9753 * linux-sh-low.c (sh_sw_breakpoint_from_kind): New function.
9754 (struct linux_target_ops) <breakpoint>: Remove.
9755 (struct linux_target_ops) <breakpoint_len>: Remove.
9756 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9757 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9758 * linux-sparc-low.c (sparc_sw_breakpoint_from_kind): New function.
9759 (struct linux_target_ops) <breakpoint>: Remove.
9760 (struct linux_target_ops) <breakpoint_len>: Remove.
9761 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9762 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9763 * linux-tic6x-low.c (tic6x_sw_breakpoint_from_kind): New function.
9764 (struct linux_target_ops) <breakpoint>: Remove.
9765 (struct linux_target_ops) <breakpoint_len>: Remove.
9766 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9767 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9768 * linux-tile-low.c (tile_sw_breakpoint_from_kind): New function.
9769 * linux-x86-low.c (x86_sw_breakpoint_from_kind): New function.
9770 (struct linux_target_ops) <breakpoint>: Remove.
9771 (struct linux_target_ops) <breakpoint_len>: Remove.
9772 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9773 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9774 * linux-xtensa-low.c (xtensa_sw_breakpoint_from_kind) New function.
9775 (struct linux_target_ops) <breakpoint>: Remove.
9776 (struct linux_target_ops) <breakpoint_len>: Remove.
9777 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9778 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9779
4cd98a19
AT
97802015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9781
9782 * linux-cris-low.c (cris_get_pc): Remove void arg.
9783
774ee6d2
AR
97842015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
9785
9786 * gdbserver/nto-low.c (nto_insert_point, nto_remove_point): Fix
9787 variable name.
9788
833dcd29
AR
97892015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
9790
9791 * inferiors.c (thread_pid_matches_callback): New function.
9792 (find_thread_process): New function.
9793 (remove_thread): Reset current_thread.
9794 (remove_process): Assert threads have been removed first.
9795
8d689ee5
YQ
97962015-10-15 Yao Qi <yao.qi@linaro.org>
9797
9798 * linux-aarch64-low.c (aarch64_insert_point): Set len to 2
9799 if it is 3.
9800 (aarch64_remove_point): Likewise.
9801 * regcache.c (regcache_register_size): New function.
9802
1c2e1515
YQ
98032015-10-12 Yao Qi <yao.qi@linaro.org>
9804
9805 * linux-aarch64-low.c: Update all callers as emit_load_store
9806 is renamed to aarch64_emit_load_store.
9807
e1c587c3
YQ
98082015-10-12 Yao Qi <yao.qi@linaro.org>
9809
9810 * linux-aarch64-low.c: Update all callers of function renaming
9811 from emit_insn to aarch64_emit_insn.
9812
b6542f81
YQ
98132015-10-12 Yao Qi <yao.qi@linaro.org>
9814
9815 * linux-aarch64-low.c (enum aarch64_opcodes): Move to
9816 arch/aarch64-insn.h.
9817 (struct aarch64_memory_operand): Likewise.
9818 (ENCODE): Likewise.
9819 (emit_insn): Move to arch/aarch64-insn.c.
9820 (emit_b, emit_bcond, emit_cb, emit_tb): Remove.
9821 (emit_load_store): Move to arch/aarch64-insn.c.
9822 (emit_ldr, emit_ldrb, emit_ldrsw, emit_nop): Remove.
9823 (can_encode_int32): Remove.
9824
246994ce
YQ
98252015-10-12 Yao Qi <yao.qi@linaro.org>
9826
9827 * linux-aarch64-low.c (extract_signed_bitfield): Remove.
9828 (aarch64_decode_ldr_literal): Move to gdb/arch/aarch64-insn.c.
9829 (aarch64_relocate_instruction): Likewise.
9830 (struct aarch64_insn_data): Move to gdb/arch/aarch64-insn.h.
9831 (struct aarch64_insn_visitor): Likewise.
9832
0badd99f
YQ
98332015-10-12 Yao Qi <yao.qi@linaro.org>
9834
9835 * linux-aarch64-low.c (struct aarch64_insn_data): New.
9836 (struct aarch64_insn_visitor): New.
9837 (struct aarch64_insn_relocation_data): New.
9838 (aarch64_ftrace_insn_reloc_b): New function.
9839 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
9840 (aarch64_ftrace_insn_reloc_cb): Likewise.
9841 (aarch64_ftrace_insn_reloc_tb): Likewise.
9842 (aarch64_ftrace_insn_reloc_adr): Likewise.
9843 (aarch64_ftrace_insn_reloc_ldr_literal): Likewise.
9844 (aarch64_ftrace_insn_reloc_others): Likewise.
9845 (visitor): New.
9846 (aarch64_relocate_instruction): Use visitor.
9847
dfaffe9d
YQ
98482015-10-12 Yao Qi <yao.qi@linaro.org>
9849
9850 * linux-aarch64-low.c (aarch64_relocate_instruction): Return
9851 int. Add argument buf.
9852 (aarch64_install_fast_tracepoint_jump_pad): Pass buf to
9853 aarch64_relocate_instruction.
9854
70b439f0
YQ
98552015-10-12 Yao Qi <yao.qi@linaro.org>
9856
9857 * linux-aarch64-low.c (aarch64_relocate_instruction): Add
9858 argument insn. Remove local variable insn. Don't call
9859 target_read_uint32.
9860 (aarch64_install_fast_tracepoint_jump_pad): Call
9861 target_read_uint32.
9862
7781c06f
YQ
98632015-09-30 Yao Qi <yao.qi@linaro.org>
9864
9865 * linux-aarch64-low.c (emit_movk): Shorten a long line.
9866 (emit_load_store_pair): Likewise.
9867
9a3c8263
SM
98682015-09-25 Simon Marchi <simon.marchi@ericsson.com>
9869
9870 * dll.c (match_dll): Add cast(s).
9871 (unloaded_dll): Likewise.
9872 * linux-low.c (second_thread_of_pid_p): Likewise.
9873 (delete_lwp_callback): Likewise.
9874 (count_events_callback): Likewise.
9875 (select_event_lwp_callback): Likewise.
9876 (linux_set_resume_request): Likewise.
9877 * server.c (accumulate_file_name_length): Likewise.
9878 (emit_dll_description): Likewise.
9879 (handle_qxfer_threads_worker): Likewise.
9880 (visit_actioned_threads): Likewise.
9881 * thread-db.c (any_thread_of): Likewise.
9882 * tracepoint.c (same_process_p): Likewise.
9883 (match_blocktype): Likewise.
9884 (build_traceframe_info_xml): Likewise.
9885
224c3ddb
SM
98862015-09-25 Simon Marchi <simon.marchi@ericsson.com>
9887
9888 * ax.c (gdb_parse_agent_expr): Add cast to allocation result
9889 assignment.
9890 (gdb_unparse_agent_expr): Likewise.
9891 * hostio.c (require_data): Likewise.
9892 (handle_pread): Likewise.
9893 * linux-low.c (disable_regset): Likewise.
9894 (fetch_register): Likewise.
9895 (store_register): Likewise.
9896 (get_dynamic): Likewise.
9897 (linux_qxfer_libraries_svr4): Likewise.
9898 * mem-break.c (delete_fast_tracepoint_jump): Likewise.
9899 (set_fast_tracepoint_jump): Likewise.
9900 (uninsert_fast_tracepoint_jumps_at): Likewise.
9901 (reinsert_fast_tracepoint_jumps_at): Likewise.
9902 (validate_inserted_breakpoint): Likewise.
9903 (clone_agent_expr): Likewise.
9904 * regcache.c (init_register_cache): Likewise.
9905 * remote-utils.c (putpkt_binary_1): Likewise.
9906 (decode_M_packet): Likewise.
9907 (decode_X_packet): Likewise.
9908 (look_up_one_symbol): Likewise.
9909 (relocate_instruction): Likewise.
9910 (monitor_output): Likewise.
9911 * server.c (handle_search_memory): Likewise.
9912 (handle_qxfer_exec_file): Likewise.
9913 (handle_qxfer_libraries): Likewise.
9914 (handle_qxfer): Likewise.
9915 (handle_query): Likewise.
9916 (handle_v_cont): Likewise.
9917 (handle_v_run): Likewise.
9918 (captured_main): Likewise.
9919 * target.c (write_inferior_memory): Likewise.
9920 * thread-db.c (try_thread_db_load_from_dir): Likewise.
9921 * tracepoint.c (init_trace_buffer): Likewise.
9922 (add_tracepoint_action): Likewise.
9923 (add_traceframe): Likewise.
9924 (add_traceframe_block): Likewise.
9925 (cmd_qtdpsrc): Likewise.
9926 (cmd_qtdv): Likewise.
9927 (cmd_qtstatus): Likewise.
9928 (response_source): Likewise.
9929 (response_tsv): Likewise.
9930 (cmd_qtnotes): Likewise.
9931 (gdb_collect): Likewise.
9932 (initialize_tracepoint): Likewise.
9933
afbe19f8
PL
99342015-09-21 Pierre Langlois <pierre.langlois@arm.com>
9935
9936 * linux-aarch64-low-.c: Include ax.h and tracepoint.h.
9937 (enum aarch64_opcodes) <RET>, <SUBS>, <AND>, <ORR>, <ORN>,
9938 <EOR>, <LSLV>, <LSRV>, <ASRV>, <SBFM>, <UBFM>, <CSINC>, <MUL>,
9939 <NOP>: New.
9940 (enum aarch64_condition_codes): New enum.
9941 (w0): New static global.
9942 (fp): Likewise.
9943 (lr): Likewise.
9944 (struct aarch64_memory_operand) <type>: New
9945 MEMORY_OPERAND_POSTINDEX type.
9946 (postindex_memory_operand): New helper function.
9947 (emit_ret): New function.
9948 (emit_load_store_pair): New function, factored out of emit_stp
9949 with support for MEMORY_OPERAND_POSTINDEX.
9950 (emit_stp): Rewrite using emit_load_store_pair.
9951 (emit_ldp): New function.
9952 (emit_load_store): Likewise.
9953 (emit_ldr): Mention post-index instruction in comment.
9954 (emit_ldrh): New function.
9955 (emit_ldrb): New function.
9956 (emit_ldrsw): Mention post-index instruction in comment.
9957 (emit_str): Likewise.
9958 (emit_subs): New function.
9959 (emit_cmp): Likewise.
9960 (emit_and): Likewise.
9961 (emit_orr): Likewise.
9962 (emit_orn): Likewise.
9963 (emit_eor): Likewise.
9964 (emit_mvn): Likewise.
9965 (emit_lslv): Likewise.
9966 (emit_lsrv): Likewise.
9967 (emit_asrv): Likewise.
9968 (emit_mul): Likewise.
9969 (emit_sbfm): Likewise.
9970 (emit_sbfx): Likewise.
9971 (emit_ubfm): Likewise.
9972 (emit_ubfx): Likewise.
9973 (emit_csinc): Likewise.
9974 (emit_cset): Likewise.
9975 (emit_nop): Likewise.
9976 (emit_ops_insns): New helper function.
9977 (emit_pop): Likewise.
9978 (emit_push): Likewise.
9979 (aarch64_emit_prologue): New function.
9980 (aarch64_emit_epilogue): Likewise.
9981 (aarch64_emit_add): Likewise.
9982 (aarch64_emit_sub): Likewise.
9983 (aarch64_emit_mul): Likewise.
9984 (aarch64_emit_lsh): Likewise.
9985 (aarch64_emit_rsh_signed): Likewise.
9986 (aarch64_emit_rsh_unsigned): Likewise.
9987 (aarch64_emit_ext): Likewise.
9988 (aarch64_emit_log_not): Likewise.
9989 (aarch64_emit_bit_and): Likewise.
9990 (aarch64_emit_bit_or): Likewise.
9991 (aarch64_emit_bit_xor): Likewise.
9992 (aarch64_emit_bit_not): Likewise.
9993 (aarch64_emit_equal): Likewise.
9994 (aarch64_emit_less_signed): Likewise.
9995 (aarch64_emit_less_unsigned): Likewise.
9996 (aarch64_emit_ref): Likewise.
9997 (aarch64_emit_if_goto): Likewise.
9998 (aarch64_emit_goto): Likewise.
9999 (aarch64_write_goto_address): Likewise.
10000 (aarch64_emit_const): Likewise.
10001 (aarch64_emit_call): Likewise.
10002 (aarch64_emit_reg): Likewise.
10003 (aarch64_emit_pop): Likewise.
10004 (aarch64_emit_stack_flush): Likewise.
10005 (aarch64_emit_zero_ext): Likewise.
10006 (aarch64_emit_swap): Likewise.
10007 (aarch64_emit_stack_adjust): Likewise.
10008 (aarch64_emit_int_call_1): Likewise.
10009 (aarch64_emit_void_call_2): Likewise.
10010 (aarch64_emit_eq_goto): Likewise.
10011 (aarch64_emit_ne_goto): Likewise.
10012 (aarch64_emit_lt_goto): Likewise.
10013 (aarch64_emit_le_goto): Likewise.
10014 (aarch64_emit_gt_goto): Likewise.
10015 (aarch64_emit_ge_got): Likewise.
10016 (aarch64_emit_ops_impl): New static global variable.
10017 (aarch64_emit_ops): New target function, return
10018 &aarch64_emit_ops_impl.
10019 (struct linux_target_ops): Install it.
10020
bb903df0
PL
100212015-09-21 Pierre Langlois <pierre.langlois@arm.com>
10022
10023 * Makefile.in (linux-aarch64-ipa.o, aarch64-ipa.o): New rules.
10024 * configure.srv (aarch64*-*-linux*): Add linux-aarch64-ipa.o and
10025 aarch64-ipa.o.
10026 * linux-aarch64-ipa.c: New file.
10027 * linux-aarch64-low.c: Include arch/aarch64-insn.h, inttypes.h
10028 and endian.h.
10029 (aarch64_get_thread_area): New target method.
10030 (extract_signed_bitfield): New helper function.
10031 (aarch64_decode_ldr_literal): New function.
10032 (enum aarch64_opcodes): New enum.
10033 (struct aarch64_register): New struct.
10034 (struct aarch64_operand): New struct.
10035 (x0): New static global.
10036 (x1): Likewise.
10037 (x2): Likewise.
10038 (x3): Likewise.
10039 (x4): Likewise.
10040 (w2): Likewise.
10041 (ip0): Likewise.
10042 (sp): Likewise.
10043 (xzr): Likewise.
10044 (aarch64_register): New helper function.
10045 (register_operand): Likewise.
10046 (immediate_operand): Likewise.
10047 (struct aarch64_memory_operand): New struct.
10048 (offset_memory_operand): New helper function.
10049 (preindex_memory_operand): Likewise.
10050 (enum aarch64_system_control_registers): New enum.
10051 (ENCODE): New macro.
10052 (emit_insn): New helper function.
10053 (emit_b): New function.
10054 (emit_bcond): Likewise.
10055 (emit_cb): Likewise.
10056 (emit_tb): Likewise.
10057 (emit_blr): Likewise.
10058 (emit_stp): Likewise.
10059 (emit_ldp_q_offset): Likewise.
10060 (emit_stp_q_offset): Likewise.
10061 (emit_load_store): Likewise.
10062 (emit_ldr): Likewise.
10063 (emit_ldrsw): Likewise.
10064 (emit_str): Likewise.
10065 (emit_ldaxr): Likewise.
10066 (emit_stxr): Likewise.
10067 (emit_stlr): Likewise.
10068 (emit_data_processing_reg): Likewise.
10069 (emit_data_processing): Likewise.
10070 (emit_add): Likewise.
10071 (emit_sub): Likewise.
10072 (emit_mov): Likewise.
10073 (emit_movk): Likewise.
10074 (emit_mov_addr): Likewise.
10075 (emit_mrs): Likewise.
10076 (emit_msr): Likewise.
10077 (emit_sevl): Likewise.
10078 (emit_wfe): Likewise.
10079 (append_insns): Likewise.
10080 (can_encode_int32_in): New helper function.
10081 (aarch64_relocate_instruction): New function.
10082 (aarch64_install_fast_tracepoint_jump_pad): Likewise.
10083 (aarch64_get_min_fast_tracepoint_insn_len): Likewise.
10084 (struct linux_target_ops): Install aarch64_get_thread_area,
10085 aarch64_install_fast_tracepoint_jump_pad and
10086 aarch64_get_min_fast_tracepoint_insn_len.
10087
787749ea
PL
100882015-09-21 Pierre Langlois <pierre.langlois@arm.com>
10089
10090 * Makefile.in (aarch64-insn.o): New rule.
10091 * configure.srv (aarch64*-*-linux*): Add aarch64-insn.o.
10092
9812b2e6
YQ
100932015-09-21 Yao Qi <yao.qi@linaro.org>
10094
10095 * ax.c [!IN_PROCESS_AGENT] (gdb_agent_op_sizes): Define it.
10096
18fe412b
YQ
100972015-09-21 Yao Qi <yao.qi@linaro.org>
10098
10099 * tracepoint.c (max_jump_pad_size): Remove.
10100
a0cc84cd
YQ
101012015-09-18 Yao Qi <yao.qi@linaro.org>
10102
10103 * linux-aarch64-low.c: Don't include sys/uio.h.
10104 (ps_get_thread_area): Call aarch64_ps_get_thread_area.
10105
d78908cf
WW
101062015-09-16 Wei-cheng Wang <cole945@gmail.com>
10107
10108 * tracepoint.c (eval_result_type): Change prototype.
10109 (condition_true_at_tracepoint): Fix argument to compiled_cond.
10110
d57e0d50
PA
101112015-09-15 Pedro Alves <palves@redhat.com>
10112
10113 * remote-utils.c (prepare_resume_reply) <TARGET_WAITKIND_EXECD>:
10114 Check whether to report exec events instead of checking whether
10115 multiprocess is enabled.
10116
5a676acc
PA
101172015-09-15 Pedro Alves <palves@redhat.com>
10118
10119 PR remote/18965
10120 * remote-utils.c (prepare_resume_reply): Merge
10121 TARGET_WAITKIND_VFORK_DONE switch case with the
10122 TARGET_WAITKIND_FORKED case.
10123
7c5d0fad
YQ
101242015-09-15 Yao Qi <yao.qi@linaro.org>
10125
10126 * server.c (handle_query): Check string comparison using
10127 "else if" instead of "if".
10128
750ce8d1
YQ
101292015-09-15 Yao Qi <yao.qi@linaro.org>
10130
10131 * server.c (vCont_supported): New global variable.
10132 (handle_query): Set vCont_supported to 1 if "vContSupported+"
10133 matches. Append ";vContSupported+" to own_buf.
10134 (handle_v_requests): Append ";s;S" to own_buf if target supports
10135 hardware single step or vCont_supported is false.
10136 (capture_main): Set vCont_supported to zero.
10137
70b90b91
YQ
101382015-09-15 Yao Qi <yao.qi@linaro.org>
10139
10140 * linux-low.c (linux_supports_conditional_breakpoints): Rename
10141 it to ...
10142 (linux_supports_hardware_single_step): ... New function.
10143 (linux_target_ops): Update.
10144 * lynx-low.c (lynx_target_ops): Set field
10145 supports_hardware_single_step to target_can_do_hardware_single_step.
10146 * nto-low.c (nto_target_ops): Likewise.
10147 * spu-low.c (spu_target_ops): Likewise.
10148 * win32-low.c (win32_target_ops): Likewise.
10149 * target.c (target_can_do_hardware_single_step): New function.
10150 * target.h (struct target_ops) <supports_conditional_breakpoints>:
10151 Remove. <supports_hardware_single_step>: New field.
10152 (target_supports_conditional_breakpoints): Remove.
10153 (target_supports_hardware_single_step): New macro.
10154 (target_can_do_hardware_single_step): Declare.
10155 * server.c (handle_query): Use target_supports_hardware_single_step
10156 instead of target_supports_conditional_breakpoints.
10157
ade90bde
YQ
101582015-09-15 Yao Qi <yao.qi@linaro.org>
10159
10160 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): New
10161 function.
10162 (struct linux_target_ops the_low_target): Install
10163 aarch64_linux_siginfo_fixup.
10164
94585166
DB
101652015-09-11 Don Breazeal <donb@codesourcery.com>
10166 Luis Machado <lgustavo@codesourcery.com>
10167
10168 * linux-low.c (linux_mourn): Static declaration.
10169 (linux_arch_setup): Move in front of
10170 handle_extended_wait.
10171 (linux_arch_setup_thread): New function.
10172 (handle_extended_wait): Handle exec events. Call
10173 linux_arch_setup_thread. Make event_lwp argument a
10174 pointer-to-a-pointer.
10175 (check_zombie_leaders): Do not check stopped threads.
10176 (linux_low_ptrace_options): Add PTRACE_O_TRACEEXEC.
10177 (linux_low_filter_event): Add lwp and thread for exec'ing
10178 non-leader thread if leader thread has been deleted.
10179 Refactor code into linux_arch_setup_thread and call it.
10180 Pass child lwp pointer by reference to handle_extended_wait.
10181 (linux_wait_for_event_filtered): Update comment.
10182 (linux_wait_1): Prevent clobbering exec event status.
10183 (linux_supports_exec_events): New function.
10184 (linux_target_ops) <supports_exec_events>: Initialize new member.
10185 * lynx-low.c (lynx_target_ops) <supports_exec_events>: Initialize
10186 new member.
10187 * remote-utils.c (prepare_resume_reply): New stop reason 'exec'.
10188 * server.c (report_exec_events): New global variable.
10189 (handle_query): Handle qSupported query for exec-events feature.
10190 (captured_main): Initialize report_exec_events.
10191 * server.h (report_exec_events): Declare new global variable.
10192 * target.h (struct target_ops) <supports_exec_events>: New
10193 member.
10194 (target_supports_exec_events): New macro.
10195 * win32-low.c (win32_target_ops) <supports_exec_events>:
10196 Initialize new member.
10197
0568462b
MM
101982015-09-09 Markus Metzger <markus.t.metzger@intel.com>
10199
10200 * linux-low.c (linux_low_enable_btrace): Remove.
10201 (linux_target_ops): Replace linux_low_enable_btrace with
10202 linux_enable_btrace.
10203
39edd165
YQ
102042015-09-03 Yao Qi <yao.qi@linaro.org>
10205
10206 * linux-aarch64-low.c (aarch64_insert_point): Call
10207 aarch64_handle_watchpoint if aarch64_linux_region_ok_for_watchpoint
10208 returns true.
10209
1db33b5a
UW
102102015-08-27 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
10211
10212 * linux-low.c (check_stopped_by_breakpoint): Use
10213 GDB_ARCH_IS_TRAP_BRKPT instead of GDB_ARCH_TRAP_BRKPT.
10214
ab290430
PA
102152015-08-27 Pedro Alves <palves@redhat.com>
10216
10217 * proc-service.c (ps_pdwrite): Return PS_ERR/PS_OK explicily.
10218
8d749320
SM
102192015-08-26 Simon Marchi <simon.marchi@ericsson.com>
10220
6711b7f8
SM
10221 * ax.c (gdb_parse_agent_expr): Replace xmalloc-family function with
10222 the XNEW-family equivalent.
8d749320
SM
10223 (compile_bytecodes): Likewise.
10224 * dll.c (loaded_dll): Likewise.
10225 * event-loop.c (append_callback_event): Likewise.
10226 (create_file_handler): Likewise.
10227 (create_file_event): Likewise.
10228 * hostio.c (handle_open): Likewise.
10229 * inferiors.c (add_thread): Likewise.
10230 (add_process): Likewise.
10231 * linux-aarch64-low.c (aarch64_linux_new_process): Likewise.
10232 * linux-arm-low.c (arm_new_process): Likewise.
10233 (arm_new_thread): Likewise.
10234 * linux-low.c (add_to_pid_list): Likewise.
10235 (linux_add_process): Likewise.
10236 (handle_extended_wait): Likewise.
10237 (add_lwp): Likewise.
10238 (enqueue_one_deferred_signal): Likewise.
10239 (enqueue_pending_signal): Likewise.
10240 (linux_resume_one_lwp_throw): Likewise.
10241 (linux_resume_one_thread): Likewise.
10242 (linux_read_memory): Likewise.
10243 (linux_write_memory): Likewise.
10244 * linux-mips-low.c (mips_linux_new_process): Likewise.
10245 (mips_linux_new_thread): Likewise.
10246 (mips_add_watchpoint): Likewise.
10247 * linux-x86-low.c (initialize_low_arch): Likewise.
10248 * lynx-low.c (lynx_add_process): Likewise.
10249 * mem-break.c (set_raw_breakpoint_at): Likewise.
10250 (set_breakpoint): Likewise.
10251 (add_condition_to_breakpoint): Likewise.
10252 (add_commands_to_breakpoint): Likewise.
10253 (clone_agent_expr): Likewise.
10254 (clone_one_breakpoint): Likewise.
10255 * regcache.c (new_register_cache): Likewise.
10256 * remote-utils.c (look_up_one_symbol): Likewise.
10257 * server.c (queue_stop_reply): Likewise.
10258 (start_inferior): Likewise.
10259 (queue_stop_reply_callback): Likewise.
10260 (handle_target_event): Likewise.
10261 * spu-low.c (fetch_ppc_memory): Likewise.
10262 (store_ppc_memory): Likewise.
10263 * target.c (set_target_ops): Likewise.
10264 * thread-db.c (thread_db_load_search): Likewise.
10265 (try_thread_db_load_1): Likewise.
10266 * tracepoint.c (add_tracepoint): Likewise.
10267 (add_tracepoint_action): Likewise.
10268 (create_trace_state_variable): Likewise.
10269 (cmd_qtdpsrc): Likewise.
10270 (cmd_qtro): Likewise.
10271 (add_while_stepping_state): Likewise.
10272 * win32-low.c (child_add_thread): Likewise.
10273 (get_image_name): Likewise.
10274
ed8b7b42
YQ
102752015-08-25 Yao Qi <yao.qi@linaro.org>
10276
10277 * linux-aarch64-low.c (aarch64_linux_new_thread): Remove.
10278
db3cb7cb
YQ
102792015-08-25 Yao Qi <yao.qi@linaro.org>
10280
10281 * Makefile.in (aarch64-linux.o): New rule.
10282 * configure.srv (aarch64*-*-linux*): Append aarch64-linux.o to
10283 srv_tgtobj.
10284 * linux-aarch64-low.c: Include nat/aarch64-linux.h.
10285 (aarch64_init_debug_reg_state): Make it extern.
10286 (aarch64_linux_prepare_to_resume): Remove.
10287
f6011a1c
YQ
102882015-08-25 Yao Qi <yao.qi@linaro.org>
10289
10290 * linux-aarch64-low.c (aarch64_linux_prepare_to_resume): Use
10291 lwp_arch_private_info and ptid_of_lwp.
10292
88e2cf7e
YQ
102932015-08-25 Yao Qi <yao.qi@linaro.org>
10294
10295 * linux-aarch64-low.c (aarch64_get_debug_reg_state): Add argument pid.
10296 Find proc_info by find_process_pid. All callers updated.
10297
5e35436e
YQ
102982015-08-25 Yao Qi <yao.qi@linaro.org>
10299
10300 * linux-aarch64-low.c (struct arch64_dr_update_callback_param):
10301 Remove.
10302 (debug_reg_change_callback): Remove.
10303 (aarch64_notify_debug_reg_change): Remove.
10304
4a8a7965
YQ
103052015-08-25 Yao Qi <yao.qi@linaro.org>
10306
10307 * linux-aarch64-low.c (aarch64_notify_debug_reg_change):
10308 Call current_lwp_ptid.
10309
32a271ee
YQ
103102015-08-25 Yao Qi <yao.qi@linaro.org>
10311
10312 * linux-aarch64-low.c (debug_reg_change_callback): Use
10313 debug_printf.
10314
0d51c8d7
YQ
103152015-08-25 Yao Qi <yao.qi@linaro.org>
10316
10317 * linux-aarch64-low.c (debug_reg_change_callback): Use phex.
10318
31a43dd5
YQ
103192015-08-25 Yao Qi <yao.qi@linaro.org>
10320
10321 * linux-aarch64-low.c (debug_reg_change_callback): Remove comments.
10322
8ee52567
YQ
103232015-08-25 Yao Qi <yao.qi@linaro.org>
10324
10325 * linux-aarch64-low.c (debug_reg_change_callback): Re-indent
10326 the code.
10327
ff3f0f45
YQ
103282015-08-25 Yao Qi <yao.qi@linaro.org>
10329
10330 * linux-aarch64-low.c (aarch64_dr_update_callback_param) <pid>:
10331 Remove.
10332 (debug_reg_change_callback): Remove argument entry and add argument
10333 lwp. Remove local variable thread. Don't print thread id in the
10334 debugging output. Don't check whether pid of thread equals to pid.
10335 (aarch64_notify_debug_reg_change): Don't set param.pid. Call
10336 iterate_over_lwps instead find_inferior.
10337
3d40fbb5
PA
103382015-08-24 Pedro Alves <palves@redhat.com>
10339
10340 * inferiors.c (get_first_process): New function.
10341 * inferiors.h (get_first_process): New declaration.
10342 * remote-utils.c (read_ptid): Default to the first process in the
10343 list, instead of to the current thread's process.
10344
438e1e42
PA
103452015-08-24 Pedro Alves <palves@redhat.com>
10346
10347 * debug.c: Include gdb_sys_time.h instead of sys/time.h.
10348 * event-loop.c: Likewise.
10349 * remote-utils.c: Likewise.
10350 * tracepoint.c: Likewise.
10351
a8c6d4fc
PA
103522015-08-24 Pedro Alves <palves@redhat.com>
10353
10354 * spu-low.c (spu_request_interrupt): Use lwpid_of instead of
10355 ptid_get_lwp.
10356
99b0bb12
PA
103572015-08-21 Pedro Alves <palves@redhat.com>
10358
10359 * ax.c (gdb_eval_agent_expr): Return expr_eval_unhandled_opcode
10360 instead of literal 1.
10361
f8904751
PA
103622015-08-21 Pedro Alves <palves@redhat.com>
10363
10364 * tdesc.c (default_description): Explicitly zero-initialize.
10365
465a859e
PA
103662015-08-21 Pedro Alves <palves@redhat.com>
10367
10368 PR gdb/18749
10369 * inferiors.c (remove_thread): Discard any pending stop reply for
10370 this thread.
10371 * server.c (remove_all_on_match_pid): Rename to ...
10372 (remove_all_on_match_ptid): ... this. Work with a filter ptid
10373 instead of a pid.
10374 (discard_queued_stop_replies): Change parameter to a ptid. Now
10375 extern.
10376 (handle_v_kill, kill_inferior_callback, captured_main)
10377 (process_serial_event): Adjust.
10378 * server.h (discard_queued_stop_replies): Declare.
10379
f0db101d
PA
103802015-08-21 Pedro Alves <palves@redhat.com>
10381
10382 * linux-low.c (wait_for_sigstop): Always switch to no thread
10383 selected if the previously current thread dies.
10384 * lynx-low.c (lynx_request_interrupt): Use the first thread's
10385 process instead of the current thread's.
10386 * remote-utils.c (input_interrupt): Don't check if there's no
10387 current thread.
10388 * server.c (gdb_read_memory, gdb_write_memory): If setting the
10389 current thread to the general thread fails, error out.
10390 (handle_qxfer_auxv, handle_qxfer_libraries)
10391 (handle_qxfer_libraries_svr4, handle_qxfer_siginfo)
10392 (handle_qxfer_spu, handle_qxfer_statictrace, handle_qxfer_fdpic)
10393 (handle_query): Check if there's a thread selected instead of
10394 checking whether there's any thread in the thread list.
10395 (handle_qxfer_threads, handle_qxfer_btrace)
10396 (handle_qxfer_btrace_conf): Don't error out early if there's no
10397 thread in the thread list.
10398 (handle_v_cont, myresume): Don't set the current thread to the
10399 continue thread.
10400 (process_serial_event) <Hg handling>: Also set thread_id if the
10401 previous general thread is still alive.
10402 (process_serial_event) <g/G handling>: If setting the current
10403 thread to the general thread fails, error out.
10404 * spu-low.c (spu_resume, spu_request_interrupt): Use the first
10405 thread's lwp instead of the current thread's.
10406 * target.c (set_desired_thread): If the desired thread was not
10407 found, leave the current thread pointing to NULL. Return an int
10408 (boolean) indicating success.
10409 * target.h (set_desired_thread): Change return type to int.
10410
40045d91
MF
104112015-08-20 Max Filippov <jcmvbkbc@gmail.com>
10412
10413 * configure.srv (xtensa*-*-linux*): Add srv_linux_thread_db=yes.
10414 * linux-xtensa-low.c (arch/xtensa.h gdb_proc_service.h): New
10415 #includes.
10416 (ps_get_thread_area): New function.
10417
45face3b
GB
104182015-08-19 Gary Benson <gbenson@redhat.com>
10419
10420 * hostio.c (handle_pread): Do not attempt to read more data
10421 than hostio_reply_with_data can fit in a packet.
10422
16d5f642
JB
104232015-08-18 Joel Brobecker <brobecker@adacore.com>
10424
10425 * linux-aarch32-low.c (NT_ARM_VFP): Define if not already defined.
10426
a738da3a
MF
104272015-08-14 Matthew Fortune <matthew.fortune@imgtec.com>
10428
10429 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP_REL.
10430
33ebda9d
PA
104312015-08-06 Pedro Alves <palves@redhat.com>
10432
10433 * tracepoint.c (expr_eval_result): Now an int.
10434
a44892be
PA
104352015-08-06 Pedro Alves <palves@redhat.com>
10436
10437 * gdbthread.h (struct regcache): Forward declare.
10438 (struct thread_info) <regcache_data>: Now a struct regcache
10439 pointer.
10440 * inferiors.c (inferior_regcache_data)
10441 (set_inferior_regcache_data): Now work with struct regcache
10442 pointers.
10443 * inferiors.h (struct regcache): Forward declare.
10444 (inferior_regcache_data, set_inferior_regcache_data): Now work
10445 with struct regcache pointers.
10446 * regcache.c (get_thread_regcache, regcache_invalidate_thread)
10447 (free_register_cache_thread): Remove struct regcache pointer
10448 casts.
10449
608a1e46
PA
104502015-08-06 Pedro Alves <palves@redhat.com>
10451
10452 * server.c (captured_main): On error, print the exception message
10453 to stderr, and if run_once is set, throw a quit.
10454
f0ce0d3a
PA
104552015-08-06 Pedro Alves <palves@redhat.com>
10456
10457 * linux-low.c (move_out_of_jump_pad_callback): Temporarily switch
10458 the current thread.
10459
bf47e248
PA
104602015-08-06 Pedro Alves <palves@redhat.com>
10461
10462 * linux-low.c (linux_write_memory): Rewrite debug output to avoid
10463 reading beyond the passed in buffer length.
10464
b6b9ffcc
PL
104652015-08-06 Pierre Langlois <pierre.langlois@arm.com>
10466
10467 * tracepoint.c (symbol_list) <required>: Remove.
10468
863d01bd
PA
104692015-08-06 Pedro Alves <palves@redhat.com>
10470
10471 * linux-low.c (handle_extended_wait): Set the fork child's suspend
10472 count if stopping and suspending threads.
10473 (check_stopped_by_breakpoint): If stopped by trace, set the LWP's
10474 stop reason to TARGET_STOPPED_BY_SINGLE_STEP.
10475 (linux_detach): Complete an ongoing step-over.
10476 (lwp_suspended_inc, lwp_suspended_decr): New functions. Use
10477 throughout.
10478 (resume_stopped_resumed_lwps): Don't resume a suspended thread.
10479 (linux_wait_1): If passing a signal to the inferior after
10480 finishing a step-over, unsuspend and re-resume all lwps. If we
10481 see a single-step event but the thread should be continuing, don't
10482 pass the trap to gdb.
10483 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback): Use
10484 internal_error instead of gdb_assert.
10485 (enqueue_pending_signal): New function.
10486 (check_ptrace_stopped_lwp_gone): Add debug output.
10487 (start_step_over): Use internal_error instead of gdb_assert.
10488 (complete_ongoing_step_over): New function.
10489 (linux_resume_one_thread): Don't resume a suspended thread.
10490 (proceed_one_lwp): If the LWP is stepping over a breakpoint, reset
10491 it stepping.
10492
00db26fa
PA
104932015-08-06 Pedro Alves <palves@redhat.com>
10494
10495 * linux-low.c (add_lwp): Set waitstatus to TARGET_WAITKIND_IGNORE.
10496 (linux_thread_alive): Use lwp_is_marked_dead.
10497 (extended_event_reported): Delete.
10498 (linux_wait_1): Check if waitstatus is TARGET_WAITKIND_IGNORE
10499 instead of extended_event_reported.
10500 (mark_lwp_dead): Don't set the 'dead' flag. Store the waitstatus
10501 as well.
10502 (lwp_is_marked_dead): New function.
10503 (lwp_running): Use lwp_is_marked_dead.
10504 * linux-low.h: Delete 'dead' field, and update 'waitstatus's
10505 comment.
10506
ad071a30
PA
105072015-08-06 Pedro Alves <palves@redhat.com>
10508
10509 * linux-low.c (linux_wait_1): Move fork event output out of the
10510 !report_to_gdb check. Pass event_child->waitstatus to
10511 target_waitstatus_to_string instead of ourstatus.
10512
524b57e6
YQ
105132015-08-04 Yao Qi <yao.qi@linaro.org>
10514
10515 * linux-aarch64-low.c (aarch64_supports_tracepoints): Return 0
10516 if current_thread is 32 bit.
10517
6085d6f6
YQ
105182015-08-04 Yao Qi <yao.qi@linaro.org>
10519
10520 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
10521 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
10522 * server.c (extended_protocol): Remove "static".
10523 * server.h (extended_protocol): Declare it.
10524
8a7e4587
YQ
105252015-08-04 Yao Qi <yao.qi@linaro.org>
10526
10527 * linux-aarch64-low.c (aarch64_get_pc): Get PC register on
10528 both aarch64 and aarch32.
10529 (aarch64_set_pc): Likewise.
10530
3b53ae99
YQ
105312015-08-04 Yao Qi <yao.qi@linaro.org>
10532
10533 * configure.srv (case aarch64*-*-linux*): Append arm-with-neon.o
10534 to srv_regobj and append arm-core.xml arm-vfpv3.xml and
10535 arm-with-neon.xml to srv_xmlfiles.
10536 * linux-aarch64-low.c: Include linux-aarch32-low.h.
10537 (is_64bit_tdesc): New function.
10538 (aarch64_linux_read_description): New function.
10539 (aarch64_arch_setup): Call aarch64_linux_read_description.
10540 (regs_info): Rename to regs_info_aarch64.
10541 (aarch64_regs_info): Return right regs_info.
10542 (initialize_low_arch): Call initialize_low_arch_aarch32.
10543
bd9e6534
YQ
105442015-08-04 Yao Qi <yao.qi@linaro.org>
10545
10546 * configure.srv (srv_tgtobj): Add linux-aarch32-low.o.
10547 * linux-aarch32-low.c: New file.
10548 * linux-aarch32-low.h: New file.
10549 * linux-arm-low.c (arm_fill_gregset): Move it to
10550 linux-aarch32-low.c.
10551 (arm_store_gregset): Likewise.
10552 (arm_fill_vfpregset): Call arm_fill_vfpregset_num
10553 (arm_store_vfpregset): Call arm_store_vfpregset_num.
10554 (arm_arch_setup): Check if PTRACE_GETREGSET works.
10555 (regs_info): Rename to regs_info_arm.
10556 (arm_regs_info): Return regs_info_aarch32 if
10557 have_ptrace_getregset is 1 and target description is
10558 arm_with_neon or arm_with_vfpv3.
10559 (initialize_low_arch): Don't call init_registers_arm_with_neon.
10560 Call initialize_low_arch_aarch32 instead.
10561
ded48a5e
YQ
105622015-08-04 Yao Qi <yao.qi@linaro.org>
10563
10564 * linux-x86-low.c (have_ptrace_getregset): Move it to ...
10565 * linux-low.c: ... here.
10566 * linux-low.h (have_ptrace_getregset): Declare it.
10567
96e9210f
PA
105682015-08-04 Pedro Alves <palves@redhat.com>
10569
10570 * thread-db.c (struct thread_db): Use new typedefs.
10571 (try_thread_db_load_1): Define local TDB_DLSYM macro and use it in
10572 CHK calls.
10573 (disable_thread_event_reporting): Cast result of dlsym to
10574 destination function pointer type.
10575 (thread_db_mourn): Use td_ta_delete_ftype.
10576
af60a1ef
SL
105772015-08-03 Sandra Loosemore <sandra@codesourcery.com>
10578
10579 * linux-nios2-low.c (NIOS2_BREAKPOINT): Conditionalize for
10580 arch variant.
10581 (CDX_BREAKPOINT): Define for R2.
10582 (nios2_breakpoint_at): Check for CDX_BREAKPOINT when R2.
10583 (the_low_target): Add comments.
10584
e8b41681
YQ
105852015-07-30 Yao Qi <yao.qi@linaro.org>
10586
10587 * linux-arm-low.c (arm_hwcap): Remove it.
10588 (arm_read_description): New local variable arm_hwcap. Don't
10589 set arm_hwcap to zero.
10590
89abb039
YQ
105912015-07-30 Yao Qi <yao.qi@linaro.org>
10592
10593 * linux-arm-low.c (arm_fill_wmmxregset): Don't use arm_hwcap.
10594 Use regcache->tdesc instead.
10595 (arm_store_wmmxregset): Likewise.
10596 (arm_fill_vfpregset): Likewise.
10597 (arm_store_vfpregset): Likewise.
10598
deca266c
YQ
105992015-07-30 Yao Qi <yao.qi@linaro.org>
10600
10601 * linux-arm-low.c: Include arch/arm.h.
10602 (arm_fill_gregset): Don't use arm_num_regs and arm_regmap.
10603 (arm_store_gregset): Likewise.
10604
aa58a496
SM
106052015-07-29 Simon Marchi <simon.marchi@ericsson.com>
10606
10607 * linux-mips-low.c (mips_linux_prepare_to_resume): Add NULL as
10608 ptrace's 4th parameter.
10609
50904b25
YQ
106102015-07-27 Yao Qi <yao.qi@linaro.org>
10611
10612 * configure.srv (case aarch64*-*-linux*): Don't set
10613 srv_linux_usrregs.
10614
5826e159
PA
106152015-07-24 Pedro Alves <palves@redhat.c: Likewise.om>
10616
10617 * linux-aarch64-low.c: Include nat/gdb_ptrace.h instead of
10618 sys/ptrace.h.
10619 * linux-arm-low.c: Likewise.
10620 * linux-cris-low.c: Likewise.
10621 * linux-crisv32-low.c: Likewise.
10622 * linux-low.c: Likewise.
10623 * linux-m68k-low.c: Likewise.
10624 * linux-mips-low.c: Likewise.
10625 * linux-nios2-low.c: Likewise.
10626 * linux-s390-low.c: Likewise.
10627 * linux-sparc-low.c: Likewise.
10628 * linux-tic6x-low.c: Likewise.
10629 * linux-tile-low.c: Likewise.
10630 * linux-x86-low.c: Likewise.
10631
54019719
PA
106322015-07-24 Pedro Alves <palves@redhat.com>
10633
10634 * config.in: Regenerate.
10635 * configure: Regenerate.
10636
eb7aa561
PA
106372015-07-24 Pedro Alves <palves@redhat.com>
10638
10639 * acinclude.m4: Include ../ptrace.m4.
10640 * configure.ac: Call GDB_AC_PTRACE.
10641 * config.in, configure: Regenerate.
10642
55d7b841
YQ
106432015-07-24 Yao Qi <yao.qi@linaro.org>
10644
10645 * linux-low.c (linux_create_inferior): Remove setting to
10646 proc->priv->new_inferior.
10647 (linux_attach): Likewise.
10648 (linux_low_filter_event): Likewise.
10649 * linux-low.h (struct process_info_private) <new_inferior>: Remove.
10650
c06cbd92
YQ
106512015-07-24 Yao Qi <yao.qi@linaro.org>
10652
10653 * linux-low.c (linux_arch_setup): New function.
10654 (linux_low_filter_event): If proc->tdesc is NULL and
10655 proc->attached is true, call the_low_target.arch_setup.
10656 Otherwise, keep status pending, and return.
10657 (linux_resume_one_lwp_throw): Don't call get_pc if
10658 thread->while_stepping isn't NULL. Don't call
10659 get_thread_regcache if proc->tdesc is NULL.
10660 (need_step_over_p): Return 0 if proc->tdesc is NULL.
10661 (linux_target_ops): Install arch_setup.
10662 * server.c (start_inferior): Call the_target->arch_setup.
10663 * target.h (struct target_ops) <arch_setup>: New field.
10664 (target_arch_setup): New marco.
10665 * lynx-low.c (lynx_target_ops): Update.
10666 * nto-low.c (nto_target_ops): Update.
10667 * spu-low.c (spu_target_ops): Update.
10668 * win32-low.c (win32_target_ops): Update.
10669
5ae3ebba
YQ
106702015-07-24 Yao Qi <yao.qi@linaro.org>
10671
10672 * linux-low.c (linux_add_process): Don't set
10673 proc->priv->new_inferior.
10674 (linux_create_inferior): Set proc->priv->new_inferior to 1.
10675 (linux_attach): Likewise.
10676
eb97750b
YQ
106772015-07-24 Yao Qi <yao.qi@linaro.org>
10678
10679 * server.c (start_inferior): Code refactor.
10680
51aee833
YQ
106812015-07-24 Yao Qi <yao.qi@linaro.org>
10682
10683 * server.c (process_serial_event): Set general_thread.
10684
af1b22f3
YQ
106852015-07-21 Yao Qi <yao.qi@linaro.org>
10686
10687 * linux-aarch64-low.c (aarch64_arch_setup): Remove code and call
10688 aarch64_linux_get_debug_reg_capacity.
10689
554717a3
YQ
106902015-07-17 Yao Qi <yao.qi@linaro.org>
10691
10692 * Makefile.in (aarch64-linux-hw-point.o): New rule.
10693 * configure.srv (srv_tgtobj): Append aarch64-linux-hw-point.o.
10694 * linux-aarch64-low.c: Include nat/aarch64-linux-hw-point.h.
10695 (AARCH64_HBP_MAX_NUM): Move to nat/aarch64-linux-hw-point.h.
10696 (AARCH64_HWP_MAX_NUM, AARCH64_HBP_ALIGNMENT): Likewise.
10697 (AARCH64_HWP_ALIGNMENT): Likewise.
10698 (AARCH64_HWP_MAX_LEN_PER_REG): Likewise.
10699 (AARCH64_DEBUG_NUM_SLOTS, AARCH64_DEBUG_ARCH): Likewise.
10700 (aarch64_num_bp_regs, aarch64_num_wp_regs): Likewise.
10701 (AARCH64_DEBUG_ARCH_V8, DR_MARK_ALL_CHANGED): Likewise.
10702 (DR_MARK_N_CHANGED, DR_CLEAR_CHANGED): Likewise.
10703 (DR_HAS_CHANGED, DR_N_HAS_CHANGE): Likewise.
10704 (struct aarch64_debug_reg_state): Likewise.
10705 (struct arch_lwp_info): Likewise.
10706 (aarch64_align_watchpoint): Likewise.
10707 (DR_CONTROL_ENABLED, DR_CONTROL_LENGTH): Likewise.
10708 (aarch64_watchpoint_length): Likewise.
10709 (aarch64_point_encode_ctrl_reg): Likewise
10710 (aarch64_point_is_aligned): Likewise.
10711 (aarch64_align_watchpoint): Likewise.
10712 (aarch64_linux_set_debug_regs):
10713 (aarch64_dr_state_insert_one_point): Likewise.
10714 (aarch64_dr_state_remove_one_point): Likewise.
10715 (aarch64_handle_breakpoint): Likewise.
10716 (aarch64_handle_aligned_watchpoint): Likewise.
10717 (aarch64_handle_unaligned_watchpoint): Likewise.
10718 (aarch64_handle_watchpoint): Likewise.
10719
c67ca4de
YQ
107202015-07-17 Yao Qi <yao.qi@linaro.org>
10721
10722 * linux-aarch64-low.c (aarch64_handle_breakpoint): Add argument state
10723 and don't aarch64_get_debug_reg_state. All callers update.
10724 (aarch64_handle_aligned_watchpoint): Likewise.
10725 (aarch64_handle_unaligned_watchpoint): Likewise.
10726 (aarch64_handle_watchpoint): Likewise.
10727 (aarch64_insert_point): Call aarch64_get_debug_reg_state earlier.
10728 (aarch64_remove_point): Likewise.
10729
25abf979
YQ
107302015-07-17 Yao Qi <yao.qi@linaro.org>
10731
10732 * linux-aarch64-low.c (aarch64_show_debug_reg_state): Use
10733 debug_printf.
10734 (aarch64_handle_unaligned_watchpoint): Likewise.
10735
db1ff28b
JK
107362015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
10737
10738 Revert the previous 3 commits:
10739 Move gdb_regex* to common/
10740 Move linux_find_memory_regions_full & co.
10741 gdbserver build-id attribute generator
10742
700ca40f
JK
107432015-07-15 Aleksandar Ristovski <aristovski@qnx.com
10744 Jan Kratochvil <jan.kratochvil@redhat.com>
10745
10746 gdbserver build-id attribute generator.
10747 * linux-low.c (nat/linux-maps.h, search.h, rsp-low.h): Include.
10748 (ElfXX_Ehdr, ElfXX_Phdr, ElfXX_Nhdr): New.
10749 (ELFXX_FLD, ELFXX_SIZEOF, ELFXX_ROUNDUP, BUILD_ID_INVALID): New.
10750 (find_phdr): New.
10751 (get_dynamic): Use find_pdhr to traverse program headers.
10752 (struct mapping_entry, mapping_entry_s, free_mapping_entry_vec)
10753 (compare_mapping_entry_range, struct find_memory_region_callback_data)
10754 (read_build_id, find_memory_region_callback, lrfind_mapping_entry)
10755 (get_hex_build_id): New.
10756 (linux_qxfer_libraries_svr4): Add optional build-id attribute
10757 to reply XML document.
10758
9904185c
JK
107592015-07-15 Aleksandar Ristovski <aristovski@qnx.com
10760 Jan Kratochvil <jan.kratochvil@redhat.com>
10761
10762 * target.c: Include target/target-utils.h and fcntl.h.
10763 (target_fileio_read_stralloc_1_pread, target_fileio_read_stralloc_1)
10764 (target_fileio_read_stralloc): New functions.
10765
6e5b4429
JK
107662015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
10767
10768 * Makefile.in (OBS): Add gdb_regex.o.
10769 (gdb_regex.o): New.
10770 * config.in: Rebuilt.
10771 * configure: Rebuilt.
10772
ddc98fbf
JK
107732015-07-15 Aleksandar Ristovski <aristovski@qnx.com
10774 Jan Kratochvil <jan.kratochvil@redhat.com>
10775
10776 Create empty nat/linux-maps.[ch] and common/target-utils.[ch].
10777 * Makefile.in (OBS): Add target-utils.o.
10778 (linux-maps.o, target-utils.o): New.
10779 * configure.srv (srv_linux_obj): Add linux-maps.o.
10780
e57bb7a0
PL
107812015-07-15 Pierre Langlois <pierre.langlois@arm.com>
10782
10783 * linux-aarch64-low.c (aarch64_supports_range_stepping): New
10784 function, return 1.
10785 (the_low_target): Install it.
10786
586b02a9
PA
107872015-07-14 Pedro Alves <palves@redhat.com>
10788
10789 * linux-low.c (kill_wait_lwp): Don't assert if waitpid fails.
10790 Instead, ignore ECHILD, and throw an error for other errnos.
10791
58c1b36c
PA
107922015-07-10 Pedro Alves <palves@redhat.com>
10793
10794 * event-loop.c (struct callback_event) <data>: Change type to
10795 gdb_client_data instance instead of gdb_client_data pointer.
10796 (append_callback_event): Adjust.
10797
421530db
PL
107982015-07-10 Pierre Langlois <pierre.langlois@arm.com>
10799
10800 * linux-aarch64-low.c: Add comments for each linux_target_ops
10801 method. Remove comments already covered in target_ops and
10802 linux_target_ops definitions.
10803 (the_low_target): Add comments for each unimplemented method.
10804
c2d65f38
YQ
108052015-07-09 Yao Qi <yao.qi@linaro.org>
10806
10807 * linux-aarch64-low.c (aarch64_regmap): Remove.
10808 (aarch64_usrregs_info): Remove.
10809 (regs_info): Set field usrregs to NULL.
10810
b20a6524
MM
108112015-07-02 Markus Metzger <markus.t.metzger@intel.com>
10812
10813 * linux-low.c: Include "rsp-low.h"
10814 (linux_low_encode_pt_config, linux_low_encode_raw): New.
10815 (linux_low_read_btrace): Support BTRACE_FORMAT_PT.
10816 (linux_low_btrace_conf): Support BTRACE_FORMAT_PT.
10817 (handle_btrace_enable_pt): New.
10818 (handle_btrace_general_set): Support "pt".
10819 (handle_btrace_conf_general_set): Support "pt:size".
10820
96c97461
PL
108212015-06-29 Pierre Langlois <pierre.langlois@arm.com>
10822
10823 * linux-aarch64-low.c (aarch64_supports_z_point_type): Enable for
10824 Z_PACKET_SW_BP.
10825
37d66942
PL
108262015-06-29 Pierre Langlois <pierre.langlois@arm.com>
10827
10828 * linux-aarch64-low.c: Remove comment about endianness.
10829 (aarch64_breakpoint): Change type to gdb_byte[]. Set to "brk #0".
10830 (aarch64_breakpoint_at): Change type of insn to gdb_byte[]. Use
10831 memcmp.
10832
dc06243f
GB
108332015-06-24 Gary Benson <gbenson@redhat.com>
10834
10835 * linux-i386-ipa.c (stdint.h): Do not include.
10836 * lynx-i386-low.c (stdint.h): Likewise.
10837 * lynx-ppc-low.c (stdint.h): Likewise.
10838 * mem-break.c (stdint.h): Likewise.
10839 * thread-db.c (stdint.h): Likewise.
10840 * tracepoint.c (stdint.h): Likewise.
10841 * win32-low.c (stdint.h): Likewise.
10842
124e13d9
SM
108432015-06-18 Simon Marchi <simon.marchi@ericsson.com>
10844
10845 * server.c (write_qxfer_response): Update call to
10846 remote_escape_output.
10847
909c2cda
JK
108482015-06-15 Aleksandar Ristovski <aristovski@qnx.com
10849 Jan Kratochvil <jan.kratochvil@redhat.com>
10850
10851 Merge multiple hex conversions.
10852 * gdbreplay.c (tohex): Rename to 'fromhex'.
10853 (logchar): Use fromhex.
10854
24c05f46
JK
108552015-06-10 Jan Kratochvil <jan.kratochvil@redhat.com>
10856
10857 * server.c (handle_qxfer_libraries): Set `version' attribute for
10858 <library-list>.
10859
14d2069a
GB
108602015-06-10 Gary Benson <gbenson@redhat.com>
10861
10862 * target.h (struct target_ops) <multifs_open>: New field.
10863 <multifs_unlink>: Likewise.
10864 <multifs_readlink>: Likewise.
10865 * linux-low.c (nat/linux-namespaces.h): New include.
10866 (linux_target_ops): Initialize the_target->multifs_open,
10867 the_target->multifs_unlink and the_target->multifs_readlink.
10868 * hostio.h (hostio_handle_new_gdb_connection): New declaration.
10869 * hostio.c (hostio_fs_pid): New static variable.
10870 (hostio_handle_new_gdb_connection): New function.
10871 (handle_setfs): Likewise.
10872 (handle_open): Use the_target->multifs_open as appropriate.
10873 (handle_unlink): Use the_target->multifs_unlink as appropriate.
10874 (handle_readlink): Use the_target->multifs_readlink as
10875 appropriate.
10876 (handle_vFile): Handle vFile:setfs packets.
10877 * server.c (handle_query): Call hostio_handle_new_gdb_connection
10878 after target_handle_new_gdb_connection.
10879
4b8b5e72
GB
108802015-06-10 Gary Benson <gbenson@redhat.com>
10881
10882 * configure.ac (AC_CHECK_FUNCS): Add setns.
10883 * config.in: Regenerate.
10884 * configure: Likewise.
10885 * Makefile.in (SFILES): Add nat/linux-namespaces.c.
10886 (linux-namespaces.o): New rule.
10887 * configure.srv (srv_linux_obj): Add linux-namespaces.o.
10888
3ac2e371
GB
108892015-06-09 Gary Benson <gbenson@redhat.com>
10890
10891 * hostio.c (handle_open): Process mode argument with
10892 fileio_to_host_mode.
10893
ca9b78ce
YQ
108942015-06-01 Yao Qi <yao.qi@linaro.org>
10895
10896 * linux-s390-low.c (PTRACE_GETREGSET, PTRACE_SETREGSET): Remove.
10897 * linux-x86-low.c: Likewise.
10898
bfacd19d
DB
108992015-05-28 Don Breazeal <donb@codesourcery.com>
10900
10901 * linux-low.c (handle_extended_wait): Initialize
10902 thread_info.last_resume_kind for new fork children.
10903
452003ef
PA
109042015-05-15 Pedro Alves <palves@redhat.com>
10905
10906 * target.h (target_handle_new_gdb_connection): Rewrite using if
10907 wrapped in do/while.
10908
1041a03c
JB
109092015-05-14 Joel Brobecker <brobecker@adacore.com>
10910
10911 * configure.ac: Add prfpregset_t BFD_HAVE_SYS_PROCFS_TYPE check.
10912 * configure, config.in: Regenerate.
10913 * gdb_proc_service.h [HAVE_PRFPREGSET_T] (prfpregset_t):
10914 Declare typedef.
10915
c269dbdb
DB
109162015-05-12 Don Breazeal <donb@codesourcery.com>
10917
10918 * linux-low.c (handle_extended_wait): Handle PTRACE_EVENT_FORK and
10919 PTRACE_EVENT_VFORK_DONE.
10920 (linux_low_ptrace_options, extended_event_reported): Add vfork
10921 events.
10922 * remote-utils.c (prepare_resume_reply): New stop reasons "vfork"
10923 and "vforkdone" for RSP 'T' Stop Reply Packet.
10924 * server.h (report_vfork_events): Declare
10925 global variable.
10926
3a8a0396
DB
109272015-05-12 Don Breazeal <donb@codesourcery.com>
10928
10929 * linux-aarch64-low.c (aarch64_linux_new_fork): New function.
10930 (the_low_target) <new_fork>: Initialize new member.
10931 * linux-arm-low.c (arm_new_fork): New function.
10932 (the_low_target) <new_fork>: Initialize new member.
10933 * linux-low.c (handle_extended_wait): Call new target function
10934 new_fork.
10935 * linux-low.h (struct linux_target_ops) <new_fork>: New member.
10936 * linux-mips-low.c (mips_add_watchpoint): New function
10937 extracted from mips_insert_point.
10938 (the_low_target) <new_fork>: Initialize new member.
10939 (mips_linux_new_fork): New function.
10940 (mips_insert_point): Call mips_add_watchpoint.
10941 * linux-x86-low.c (x86_linux_new_fork): New function.
10942 (the_low_target) <new_fork>: Initialize new member.
10943
de0d863e
DB
109442015-05-12 Don Breazeal <donb@codesourcery.com>
10945
10946 * linux-low.c (handle_extended_wait): Implement return value,
10947 rename argument 'event_child' to 'event_lwp', handle
10948 PTRACE_EVENT_FORK, call internal_error for unrecognized event.
10949 (linux_low_ptrace_options): New function.
10950 (linux_low_filter_event): Call linux_low_ptrace_options,
10951 use different argument fo linux_enable_event_reporting,
10952 use return value from handle_extended_wait.
10953 (extended_event_reported): New function.
10954 (linux_wait_1): Call extended_event_reported and set
10955 status to report fork events.
10956 (linux_write_memory): Add pid to debug message.
10957 (reset_lwp_ptrace_options_callback): New function.
10958 (linux_handle_new_gdb_connection): New function.
10959 (linux_target_ops): Initialize new structure member.
10960 * linux-low.h (struct lwp_info) <waitstatus>: New member.
10961 * lynx-low.c: Initialize new structure member.
10962 * remote-utils.c (prepare_resume_reply): Implement stop reason
10963 "fork" for "T" stop message.
10964 * server.c (handle_query): Call handle_new_gdb_connection.
10965 * server.h (report_fork_events): Declare global flag.
10966 * target.h (struct target_ops) <handle_new_gdb_connection>:
10967 New member.
10968 (target_handle_new_gdb_connection): New macro.
10969 * win32-low.c: Initialize new structure member.
10970
ddcbc397
DB
109712015-05-12 Don Breazeal <donb@codesourcery.com>
10972
10973 * mem-break.c (APPEND_TO_LIST): Define macro.
10974 (clone_agent_expr): New function.
10975 (clone_one_breakpoint): New function.
10976 (clone_all_breakpoints): New function.
10977 * mem-break.h: Declare new functions.
10978
89245bc0
DB
109792015-05-12 Don Breazeal <donb@codesourcery.com>
10980
10981 * linux-low.c (linux_supports_fork_events): New function.
10982 (linux_supports_vfork_events): New function.
10983 (linux_target_ops): Initialize new structure members.
10984 (initialize_low): Call linux_check_ptrace_features.
10985 * lynx-low.c (lynx_target_ops): Initialize new structure
10986 members.
10987 * server.c (report_fork_events, report_vfork_events):
10988 New global flags.
10989 (handle_query): Add new features to qSupported packet and
10990 response.
10991 (captured_main): Initialize new global variables.
10992 * target.h (struct target_ops) <supports_fork_events>:
10993 New member.
10994 <supports_vfork_events>: New member.
10995 (target_supports_fork_events): New macro.
10996 (target_supports_vfork_events): New macro.
10997 * win32-low.c (win32_target_ops): Initialize new structure
10998 members.
10999
835205d0
GB
110002015-05-12 Gary Benson <gbenson@redhat.com>
11001
11002 * server.c (handle_qxfer_exec_file): Use current process
11003 if annex is empty.
11004
21e94bd9
SL
110052015-05-08 Sandra Loosemore <sandra@codesourcery.com>
11006
11007 * linux-nios2-low.c: Include elf/common.h. Adjust comments.
11008 Remove HAVE_PTRACE_GETREGS conditionals.
11009 (nios2_regsets): Use PTRACE_GETREGSET and PTRACE_SETREGSET
11010 instead of PTRACE_GETREGS and PTRACE_SETREGS.
11011
45614f15
YQ
110122015-05-08 Yao Qi <yao.qi@linaro.org>
11013
11014 * linux-low.c (linux_supports_conditional_breakpoints): New
11015 function.
11016 (linux_target_ops): Install new target method.
11017 * lynx-low.c (lynx_target_ops): Install NULL hook for
11018 supports_conditional_breakpoints.
11019 * nto-low.c (nto_target_ops): Likewise.
11020 * spu-low.c (spu_target_ops): Likewise.
11021 * win32-low.c (win32_target_ops): Likewise.
11022 * server.c (handle_query): Check
11023 target_supports_conditional_breakpoints.
11024 * target.h (struct target_ops) <supports_conditional_breakpoints>:
11025 New field.
11026 (target_supports_conditional_breakpoints): New macro.
11027
80ad801e
PA
110282015-05-06 Pedro Alves <palves@redhat.com>
11029
11030 PR server/18081
11031 * server.c (start_inferior): If the process exits, mourn it.
11032
819843c7
GB
110332015-04-21 Gary Benson <gbenson@redhat.com>
11034
11035 * hostio.c (fileio_open_flags_to_host): Factored out to
11036 fileio_to_host_openflags in common/fileio.c. Single use
11037 updated.
11038
a2d5a9d7
MF
110392015-04-17 Max Filippov <jcmvbkbc@gmail.com>
11040
11041 * linux-xtensa-low.c (xtensa_fill_gregset)
11042 (xtensa_store_gregset): Check XCHAL_HAVE_LOOPS instead of
11043 XCHAL_HAVE_LOOP.
11044
deb44829
MF
110452015-04-17 Max Filippov <jcmvbkbc@gmail.com>
11046
11047 * linux-xtensa-low.c (xtensa_usrregs_info): Remove.
11048 (regs_info): Replace usrregs pointer with NULL.
11049
e57f1de3
GB
110502015-04-17 Gary Benson <gbenson@redhat.com>
11051
11052 * target.h (struct target_ops) <pid_to_exec_file>: New field.
11053 * linux-low.c (linux_target_ops): Initialize pid_to_exec_file.
11054 * server.c (handle_qxfer_exec_file): New function.
11055 (qxfer_packets): Add exec-file entry.
11056 (handle_query): Report qXfer:exec-file:read as supported packet.
11057
62828379
RN
110582015-04-14 Romain Naour <romain.naour@openwide.fr> (tiny change)
11059
11060 * linux-low.c (linux_read_offsets): Remove get_thread_lwp.
11061
b88bb450
GB
110622015-04-09 Gary Benson <gbenson@redhat.com>
11063
11064 * hostio-errno.c (errno_to_fileio_error): Remove function.
11065 Update caller to use remote_fileio_to_fio_error.
11066
c8f4bfdd
YQ
110672015-04-09 Yao Qi <yao.qi@linaro.org>
11068
11069 * linux-low.c (linux_insert_point): Call
11070 insert_memory_breakpoint if TYPE is raw_bkpt_type_sw.
11071 (linux_remove_point): Call remove_memory_breakpoint if type is
11072 raw_bkpt_type_sw.
11073 * linux-x86-low.c (x86_insert_point): Don't call
11074 insert_memory_breakpoint.
11075 (x86_remove_point): Don't call remove_memory_breakpoint.
11076
41f98f02
PA
110772015-04-01 Pedro Alves <palves@redhat.com>
11078 Cleber Rosa <crosa@redhat.com>
11079
11080 * server.c (gdbserver_usage): Reorganize and extend the usage
11081 message.
11082
2bf6fb9d
PA
110832015-03-24 Pedro Alves <palves@redhat.com>
11084
11085 * linux-low.c (check_stopped_by_breakpoint): Tweak debug log
11086 output. Also dump TRAP_TRACE.
11087 (linux_low_filter_event): In debug output, distinguish a
11088 resume_stop SIGSTOP from a delayed SIGSTOP.
11089
369f6daa
GB
110902015-03-24 Gary Benson <gbenson@redhat.com>
11091
11092 * linux-x86-low.c (x86_linux_new_thread): Moved to
11093 nat/x86-linux.c.
11094 (x86_linux_prepare_to_resume): Likewise.
11095
8e5d4070
GB
110962015-03-24 Gary Benson <gbenson@redhat.com>
11097
11098 * Makefile.in (x86-linux-dregs.o): New rule.
11099 * configure.srv: Add x86-linux-dregs.o to relevant targets.
11100 * linux-x86-low.c: Include nat/x86-linux-dregs.h.
11101 (u_debugreg_offset): Moved to nat/x86-linux-dregs.c.
11102 (x86_linux_dr_get): Likewise.
11103 (x86_linux_dr_set): Likewise.
11104 (update_debug_registers_callback): Likewise.
11105 (x86_linux_dr_set_addr): Likewise.
11106 (x86_linux_dr_get_addr): Likewise.
11107 (x86_linux_dr_set_control): Likewise.
11108 (x86_linux_dr_get_control): Likewise.
11109 (x86_linux_dr_get_status): Likewise.
11110 (x86_linux_update_debug_registers): Likewise.
11111
2b95d440
GB
111122015-03-24 Gary Benson <gbenson@redhat.com>
11113
11114 * linux-x86-low.c (x86_linux_update_debug_registers):
11115 New function, factored out from...
11116 (x86_linux_prepare_to_resume): ...this.
11117
14b0bc68
GB
111182015-03-24 Gary Benson <gbenson@redhat.com>
11119
11120 * linux-x86-low.c (x86_linux_dr_get): Update comments.
11121 (x86_linux_dr_set): Likewise.
11122 (update_debug_registers_callback): Likewise.
11123 (x86_linux_dr_set_addr): Likewise.
11124 (x86_linux_dr_get_addr): Likewise.
11125 (x86_linux_dr_set_control): Likewise.
11126 (x86_linux_dr_get_control): Likewise.
11127 (x86_linux_dr_get_status): Likewise.
11128 (x86_linux_prepare_to_resume): Likewise.
11129
5dfe6ca8
GB
111302015-03-24 Gary Benson <gbenson@redhat.com>
11131
11132 * linux-x86-low.c (x86_linux_dr_get): Add assertion.
11133 Use perror_with_name. Pass string through gettext.
11134 (x86_linux_dr_set): Likewise.
11135
d33472ad
GB
111362015-03-24 Gary Benson <gbenson@redhat.com>
11137
11138 * linux-x86-low.c (x86_dr_low_set_addr): Rename to...
11139 (x86_linux_dr_set_addr): ...this.
11140 (x86_dr_low_get_addr): Rename to...
11141 (x86_linux_dr_get_addr): ...this.
11142 (x86_dr_low_set_control): Rename to...
11143 (x86_linux_dr_set_control): ...this.
11144 (x86_dr_low_get_control): Rename to...
11145 (x86_linux_dr_get_control): ...this.
11146 (x86_dr_low_get_status): Rename to...
11147 (x86_linux_dr_get_status): ...this.
11148 (x86_dr_low): Update with new function names.
11149
4b134ca1
GB
111502015-03-24 Gary Benson <gbenson@redhat.com>
11151
11152 * Makefile.in (x86-linux.o): New rule.
11153 * configure.srv: Add x86-linux.o to relevant targets.
11154 * linux-low.c (lwp_set_arch_private_info): New function.
11155 (lwp_arch_private_info): Likewise.
11156 * linux-x86-low.c: Include nat/x86-linux.h.
11157 (arch_lwp_info): Removed structure.
11158 (update_debug_registers_callback):
11159 Use lwp_set_debug_registers_changed.
11160 (x86_linux_prepare_to_resume): Use lwp_debug_registers_changed
11161 and lwp_set_debug_registers_changed.
11162 (x86_linux_new_thread): Use lwp_set_debug_registers_changed.
11163
34c703da
GB
111642015-03-24 Gary Benson <gbenson@redhat.com>
11165
11166 * linux-low.h (linux_target_ops) <new_thread>: Changed signature.
11167 * linux-arm-low.c (arm_new_thread): Likewise.
11168 * linux-aarch64-low.c (aarch64_linux_new_thread): Likewise.
11169 * linux-mips-low.c (mips_linux_new_thread): Likewise.
11170 * linux-x86-low.c (x86_linux_new_thread): Likewise.
11171 * linux-low.c (add_lwp): Update the_low_target.new_thread call.
11172
cff068da
GB
111732015-03-24 Gary Benson <gbenson@redhat.com>
11174
11175 * linux-low.c (ptid_of_lwp): New function.
11176 (lwp_is_stopped): Likewise.
11177 (lwp_stop_reason): Likewise.
11178 * linux-x86-low.c (update_debug_registers_callback):
11179 Use lwp_is_stopped.
11180 (x86_linux_prepare_to_resume): Use ptid_of_lwp and
11181 lwp_stop_reason.
11182
b2f7c7e8
GB
111832015-03-24 Gary Benson <gbenson@redhat.com>
11184
11185 * linux-low.h (linux_stop_lwp): Remove declaration.
11186
6d4ee8c6
GB
111872015-03-24 Gary Benson <gbenson@redhat.com>
11188
11189 * linux-low.h: Include nat/linux-nat.h.
11190 * linux-low.c (iterate_over_lwps_args): New structure.
11191 (iterate_over_lwps_filter): New function.
11192 (iterate_over_lwps): Likewise.
11193 * linux-x86-low.c (update_debug_registers_callback):
11194 Update signature to what iterate_over_lwps expects.
11195 Remove PID check that iterate_over_lwps now performs.
11196 (x86_dr_low_set_addr): Use iterate_over_lwps.
11197 (x86_dr_low_set_control): Likewise.
11198
70a0bb6b
GB
111992015-03-24 Gary Benson <gbenson@redhat.com>
11200
11201 * linux-x86-low.c (x86_debug_reg_state): New function.
11202 (x86_linux_prepare_to_resume): Use the above.
11203
7b669087
GB
112042015-03-24 Gary Benson <gbenson@redhat.com>
11205
11206 * linux-low.c (current_lwp_ptid): New function.
11207 * linux-x86-low.c: Include nat/linux-nat.h.
11208 (x86_dr_low_get_addr): Use current_lwp_ptid.
11209 (x86_dr_low_get_control): Likewise.
11210 (x86_dr_low_get_status): Likewise.
11211
eef49a3d
PA
112122015-03-20 Pedro Alves <palves@redhat.com>
11213
11214 * tracepoint.c (cmd_qtstatus): Make "str" const.
11215
b2333d22
PA
112162015-03-20 Pedro Alves <palves@redhat.com>
11217
11218 * server.c (handle_general_set): Make "req_str" const.
11219
23f238d3
PA
112202015-03-19 Pedro Alves <palves@redhat.com>
11221
11222 * linux-low.c (linux_resume_one_lwp): Rename to ...
11223 (linux_resume_one_lwp_throw): ... this. Don't handle ESRCH here,
11224 instead call perror_with_name.
11225 (check_ptrace_stopped_lwp_gone): New function.
11226 (linux_resume_one_lwp): Reimplement as wrapper around
11227 linux_resume_one_lwp_throw that swallows errors if the LWP is
11228 gone.
11229
91baf43f
PA
112302015-03-19 Pedro Alves <palves@redhat.com>
11231
11232 * linux-low.c (count_events_callback, select_event_lwp_callback):
11233 No longer check whether the thread has resume_stop as last resume
11234 kind.
11235
8bf3b159
PA
112362015-03-19 Pedro Alves <palves@redhat.com>
11237
11238 * linux-low.c (count_events_callback, select_event_lwp_callback):
11239 Use the lwp's status_pending_p field, not the thread's.
11240
b90fc188
PA
112412015-03-19 Pedro Alves <palves@redhat.com>
11242
11243 * linux-low.c (select_event_lwp_callback): Update comments to
11244 no longer mention SIGTRAP.
11245
464b0089
GB
112462015-03-18 Gary Benson <gbenson@redhat.com>
11247
11248 * server.c (handle_query): Do not report vFile:fstat as supported.
11249
aa9e327f
GB
112502015-03-11 Gary Benson <gbenson@redhat.com>
11251
11252 * hostio.c (sys/types.h): New include.
11253 (sys/stat.h): Likewise.
11254 (common-remote-fileio.h): Likewise.
11255 (handle_fstat): New function.
11256 (handle_vFile): Handle vFile:fstat packets.
aa9e327f 11257
791c0056
GB
112582015-03-11 Gary Benson <gbenson@redhat.com>
11259
11260 * configure.ac (AC_CHECK_MEMBERS): Add checks for
11261 struct stat.st_blocks and struct stat.st_blksize.
11262 * configure: Regenerate.
11263 * config.in: Likewise.
11264 * Makefile.in (SFILES): Add common/common-remote-fileio.c.
11265 (OBS): Add common-remote-fileio.o.
11266 (common-remote-fileio.o): New rule.
11267
9a9df970
PA
112682015-03-09 Pedro Alves <palves@redhat.com>
11269
11270 * tracepoint.c (gdb_agent_helper_thread): Cast '&sockaddr' to
11271 'struct sockaddr' pointer in 'accept' call.
11272
9eb1356e
PA
112732015-03-09 Pedro Alves <palves@redhat.com>
11274
11275 Revert:
11276 2015-03-07 Pedro Alves <palves@redhat.com>
11277 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
11278 or <winsock2.h> here. Instead include "gdb_socket.h".
11279 (remote_open): Use union gdb_sockaddr_u.
11280 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
11281 or <winsock2.h> here. Instead include "gdb_socket.h".
11282 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
11283 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
11284 or <sys/un.h>.
11285 (init_named_socket, gdb_agent_helper_thread): Use union
11286 gdb_sockaddr_u.
11287
aac331e4
PA
112882015-03-07 Pedro Alves <palves@redhat.com>
11289
11290 * configure.ac (build_warnings): Move
11291 -Wdeclaration-after-statement to the C-specific set.
11292 * configure: Regenerate.
11293
366c75fc
PA
112942015-03-07 Pedro Alves <palves@redhat.com>
11295
11296 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
11297 or <winsock2.h> here. Instead include "gdb_socket.h".
11298 (remote_open): Use union gdb_sockaddr_u.
11299 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
11300 or <winsock2.h> here. Instead include "gdb_socket.h".
11301 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
11302 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
11303 or <sys/un.h>.
11304 (init_named_socket, gdb_agent_helper_thread): Use union
11305 gdb_sockaddr_u.
11306
492d29ea
PA
113072015-03-07 Pedro Alves <palves@redhat.com>
11308
11309 Adjust all callers of TRY_CATCH to use TRY/CATCH/END_CATCH
11310 instead.
11311
60a191ed
YQ
113122015-03-06 Yao Qi <yao.qi@linaro.org>
11313
11314 * linux-aarch64-low.c (aarch64_insert_point): Use
11315 show_debug_regs as a boolean.
11316 (aarch64_remove_point): Likewise.
11317
f5771b1d
PA
113182015-03-05 Pedro Alves <palves@redhat.com>
11319
11320 * lynx-low.c (lynx_target_ops): Install NULL hooks for
11321 stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
11322 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint.
11323 * nto-low.c (nto_target_ops): Likewise.
11324 * spu-low.c (spu_target_ops): Likewise.
11325 * win32-low.c (win32_target_ops): Likewise.
11326
3e572f71
PA
113272015-03-04 Pedro Alves <palves@redhat.com>
11328
72f4393d 11329 * linux-low.c (check_stopped_by_breakpoint) [USE_SIGTRAP_SIGINFO]:
3e572f71
PA
11330 Decide whether a breakpoint triggered based on the SIGTRAP's
11331 siginfo.si_code.
72f4393d
L
11332 (thread_still_has_status_pending_p) [USE_SIGTRAP_SIGINFO]: Don't check whether a
11333 breakpoint is inserted if relying on SIGTRAP's siginfo.si_code.
3e572f71
PA
11334 (linux_low_filter_event): Check for breakpoints before checking
11335 watchpoints.
11336 (linux_wait_1): Don't re-increment the PC if relying on SIGTRAP's
11337 siginfo.si_code.
72f4393d
L
11338 (linux_stopped_by_sw_breakpoint)
11339 (linux_supports_stopped_by_sw_breakpoint)
11340 (linux_stopped_by_hw_breakpoint)
11341 (linux_supports_stopped_by_hw_breakpoint): New functions.
11342 (linux_target_ops): Install new target methods.
3e572f71 11343
1ec68e26
PA
113442015-03-04 Pedro Alves <palves@redhat.com>
11345
11346 * remote-utils.c (prepare_resume_reply): Report swbreak/hbreak.
11347 * server.c (swbreak_feature, hwbreak_feature): New globals.
11348 (handle_query) <qSupported>: Handle "swbreak+" and "hwbreak+".
11349 (captured_main): Clear swbreak_feature and hwbreak_feature.
11350 * server.h (swbreak_feature, hwbreak_feature): Declare.
11351 * target.h (struct target_ops) <stopped_by_sw_breakpoint,
11352 supports_stopped_by_sw_breakpoint, stopped_by_hw_breakpoint,
11353 supports_stopped_by_hw_breakpoint>: New fields.
11354 (target_supports_stopped_by_sw_breakpoint)
11355 (target_stopped_by_sw_breakpoint)
11356 (target_supports_stopped_by_hw_breakpoint)
11357 (target_stopped_by_hw_breakpoint): Declare.
11358
15c66dd6
PA
113592015-03-04 Pedro Alves <palves@redhat.com>
11360
11361 enum lwp_stop_reason -> enum target_stop_reason
11362 * linux-low.c (check_stopped_by_breakpoint): Adjust.
11363 (thread_still_has_status_pending_p, check_stopped_by_watchpoint)
11364 (linux_wait_1, stuck_in_jump_pad_callback)
11365 (move_out_of_jump_pad_callback, linux_resume_one_lwp)
11366 (linux_stopped_by_watchpoint):
11367 * linux-low.h (enum lwp_stop_reason): Delete.
11368 (struct lwp_info) <stop_reason>: Now an enum target_stop_reason.
11369 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
11370
98fc70d6
YQ
113712015-03-04 Yao Qi <yao.qi@linaro.org>
11372
11373 * Makefile.in (SFILES): Add linux-aarch64-low.c.
11374
dd2ac174
GB
113752015-03-03 Gary Benson <gbenson@redhat.com>
11376
11377 * hostio.c (handle_vFile): Fix prefix lengths.
11378
d68e53f4
MM
113792015-03-03 Markus Metzger <markus.t.metzger@intel.com>
11380
11381 * linux-low.c (linux_low_enable_btrace): Do not overwrite non-zero
11382 ptr_bits.
11383
bf2d68ab
AA
113842015-03-02 Andreas Arnez <arnez@linux.vnet.ibm.com>
11385
11386 * Makefile.in (s390-vx-linux64.c, s390-tevx-linux64.c)
11387 (s390x-vx-linux64.c, s390x-tevx-linux64.c): New rules.
11388 (clean): Add "rm -f" for above C files.
11389 * configure.srv (srv_regobj): Add s390-vx-linux64.o,
11390 s390-tevx-linux64.o, s390x-vx-linux64.o, and s390x-tevx-linux64.o.
11391 (srv_xmlfiles): Add s390-vx-linux64.xml, s390-tevx-linux64.xml,
11392 s390x-vx-linux64.xml, s390x-tevx-linux64.xml, and s390-vx.xml.
11393 * linux-s390-low.c (HWCAP_S390_VX): New macro.
11394 (init_registers_s390_vx_linux64, init_registers_s390_tevx_linux64)
11395 (init_registers_s390x_vx_linux64)
11396 (init_registers_s390x_tevx_linux64)
11397 (tdesc_s390_vx_linux64, tdesc_s390_tevx_linux64)
11398 (tdesc_s390x_vx_linux64, tdesc_s390x_tevx_linux64): New extern
11399 declarations.
11400 (s390_fill_vxrs_low, s390_store_vxrs_low, s390_fill_vxrs_high)
11401 (s390_store_vxrs_high): New functions.
11402 (s390_regsets): Add entries for NT_S390_VXRS_LOW and
11403 NT_S390_VXRS_HIGH.
11404 (s390_arch_setup): Add logic for selecting one of the new target
11405 descriptions. Activate the new vector regsets if applicable.
11406 (initialize_low_arch): Also invoke init_registers_s390_vx_linux64,
11407 init_registers_s390_tevx_linux64, init_registers_s390x_vx_linux64,
11408 and init_registers_s390x_tevx_linux64.
11409
c966a859
PA
114102015-03-01 Pedro Alves <palves@redhat.com>
11411
11412 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Constify 'raw_regs'
11413 parameter.
11414
4180215b
PA
114152015-02-27 Pedro Alves <palves@redhat.com>
11416
11417 * linux-x86-low.c (u_debugreg_offset): New function.
11418 (x86_linux_dr_get, x86_linux_dr_set): Use it.
11419
749bab01
PA
114202015-02-27 Pedro Alves <palves@redhat.com>
11421
11422 * gdb_proc_service.h: Wrap with EXTERN_C_PUSH/EXTERN_C_POP.
11423 [!HAVE_PROC_SERVICE_H] (struct ps_prochandle): Forward declare.
11424 [!HAVE_PROC_SERVICE_H] (ps_pdread, ps_pdwrite, ps_ptread)
11425 ps_ptwrite, ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
11426 (ps_lsetfpregs, ps_getpid)
11427 (ps_get_thread_area, ps_pglobal_lookup, ps_pstop, ps_pcontinue)
11428 (ps_lstop, ps_lcontinue, ps_lgetxregsize, ps_lgetxregs)
11429 (ps_lsetxregs, ps_plog): Declare.
11430
3c14e5a3
PA
114312015-02-27 Pedro Alves <palves@redhat.com>
11432
11433 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Use
11434 IP_AGENT_EXPORT_FUNC.
11435 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Use
11436 IP_AGENT_EXPORT_FUNC.
11437 * tracepoint.c (ATTR_USED, ATTR_NOINLINE, ATTR_CONSTRUCTOR)
11438 (IP_AGENT_EXPORT): Delete.
11439 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
11440 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
11441 (gdb_trampoline_buffer_error, collecting, gdb_collect)
11442 (stop_tracing, flush_trace_buffer, about_to_request_buffer_space)
11443 (trace_buffer_is_full, stopping_tracepoint, expr_eval_result)
11444 (error_tracepoint, tracepoints, tracing, trace_buffer_ctrl)
11445 (trace_buffer_ctrl_curr, trace_buffer_lo, trace_buffer_hi)
11446 (traceframe_read_count, traceframe_write_count)
11447 (traceframes_created, trace_state_variables, get_raw_reg)
11448 (get_trace_state_variable_value, set_trace_state_variable_value)
11449 (ust_loaded, helper_thread_id, cmd_buf): Use
11450 IPA_SYM_EXPORTED_NAME.
11451 (stop_tracing, flush_trace_buffer): Use IP_AGENT_EXPORT_FUNC.
11452 (tracepoints) Use IP_AGENT_EXPORT_VAR.
11453 (stopping_tracepoint, trace_buffer_is_full, expr_eval_result): Use
11454 IP_AGENT_EXPORT_VAR and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
11455 (last_tracepoint): Move into !IN_PROCESS_AGENT block.
11456 (error_tracepoint): Use IP_AGENT_EXPORT_VAR and wrap in
11457 EXTERN_C_PUSH/EXTERN_C_POP.
11458 (trace_state_variables): Use IP_AGENT_EXPORT_VAR.
11459 (trace_buffer_lo, trace_buffer_hi): Use IP_AGENT_EXPORT_VAR and
11460 wrap in EXTERN_C_PUSH/EXTERN_C_POP.
11461 (trace_buffer_ctrl, trace_buffer_ctrl_curr)
11462 (traceframe_write_count, traceframe_read_count)
11463 (traceframes_created, tracing): Use IP_AGENT_EXPORT_VAR.
11464 (about_to_request_buffer_space, get_trace_state_variable_value)
11465 (set_trace_state_variable_value): Use IP_AGENT_EXPORT_FUNC.
11466 (collecting): Use IP_AGENT_EXPORT_VAR and wrap in
11467 EXTERN_C_PUSH/EXTERN_C_POP.
11468 (gdb_collect): Use IP_AGENT_EXPORT_FUNC.
11469 (ust_loaded, cmd_buf): Use IP_AGENT_EXPORT_VAR.
11470 (helper_thread_id, gdb_agent_capability): Use IP_AGENT_EXPORT_VAR
11471 and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
11472 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
11473 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
11474 (gdb_trampoline_buffer_error): Use IP_AGENT_EXPORT_VAR.
11475 * tracepoint.h (ATTR_USED, ATTR_NOINLINE, EXPORTED_SYMBOL):
11476 Define.
11477 (IP_AGENT_EXPORT_FUNC, IP_AGENT_EXPORT_VAR)
11478 (IP_AGENT_EXPORT_VAR_DECL): Define.
11479 (tracing): Declare.
11480 (gdb_agent_get_raw_reg): Declare.
11481
fe978cb0
PA
114822015-02-27 Tom Tromey <tromey@redhat.com>
11483 Pedro Alves <palves@redhat.com>
11484
11485 Rename symbols whose names are reserved C++ keywords throughout.
11486
3bc3d82a
PA
114872015-02-27 Pedro Alves <palves@redhat.com>
11488
11489 * Makefile.in (COMPILER): New, get it from autoconf.
11490 (CXX): Get from autoconf instead.
11491 (COMPILE.pre): Use COMPILER.
11492 (CC-LD): Rename to ...
11493 (CC_LD): ... this. Use COMPILER.
11494 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT), $(IPA_LIB)): Adjust.
11495 (CXX_FOR_TARGET): Default to g++ instead of gcc.
11496 * acinclude.m4: Include build-with-cxx.m4.
11497 * configure.ac: Call AC_PROG_CXX and GDB_AC_BUILD_WITH_CXX.
11498 Disable -Werror by default if building in C++ mode.
11499 (build_warnings): Add -Wno-sign-compare, -Wno-write-strings and
11500 -Wno-narrowing in C++ mode. Run supported-warning-flags tests with
11501 the C++ compiler. Save/restore CXXFLAGS too.
11502 * configure: Regenerate.
11503
07697489
PA
115042015-02-27 Pedro Alves <palves@redhat.com>
11505
11506 * acinclude.m4: Include libiberty.m4.
11507 * configure.ac: Call libiberty_INIT.
11508 * config.in, configure: Regenerate.
11509
9beb7c4e
PA
115102015-02-26 Pedro Alves <palves@redhat.com>
11511
11512 * linux-low.c (linux_wait_1): When incrementing the PC past a
11513 program breakpoint always use the_low_target.breakpoint_len as
11514 increment, rather than the maximum between that and
11515 the_low_target.decr_pc_after_break.
11516
8090aef2
PA
115172015-02-23 Pedro Alves <palves@redhat.com>
11518
11519 * linux-low.c (check_stopped_by_breakpoint): Don't check if the
11520 thread was doing a step-over; always adjust the PC if
11521 we stepped over a permanent breakpoint.
11522 (linux_wait_1): If we stepped over breakpoint that was on top of a
11523 permanent breakpoint, manually advance the PC past it.
11524
bc9540e8
PA
115252015-02-23 Pedro Alves <palves@redhat.com>
11526
11527 * linux-x86-low.c (REGSIZE): Define in both 32-bit and 64-bit
11528 modes.
11529 (x86_fill_gregset, x86_store_gregset): Use it when handling
11530 $orig_eax.
11531
2db9a427
PA
115322015-02-20 Pedro Alves <palves@redhat.com>
11533
11534 * thread-db.c: Include "nat/linux-procfs.h".
11535 (thread_db_init): Skip listing new threads if the kernel supports
11536 PTRACE_EVENT_CLONE and /proc/PID/task/ is accessible.
11537
afa8d396
PA
115382015-02-20 Pedro Alves <palves@redhat.com>
11539
11540 * linux-low.c (status_pending_p_callback): Use ptid_match.
11541
c9587f88
AT
115422015-02-19 Antoine Tremblay <antoine.tremblay@ericsson.com>
11543
11544 PR breakpoints/16812
11545 * linux-low.c (wstatus_maybe_breakpoint): Remove.
11546 (linux_low_filter_event): Update wstatus_maybe_breakpoint name.
11547 (linux_wait_1): Report SIGTRAP,SIGILL,SIGSEGV.
11548
b05ec7a5
AT
115492015-02-10 Antoine Tremblay <antoine.tremblay@ericsson.com>
11550
11551 PR breakpoints/15956
11552 * tracepoint.c (cmd_qtinit): Add check for current_thread.
11553
d33501a5
MM
115542015-02-09 Markus Metzger <markus.t.metzger@intel.com>
11555
11556 * linux-low.c (linux_low_btrace_conf): Print size.
11557 * server.c (handle_btrace_conf_general_set): New.
11558 (hanle_general_set): Call handle_btrace_conf_general_set.
11559 (handle_query): Report Qbtrace-conf:bts:size as supported.
11560
f4abbc16
MM
115612015-02-09 Markus Metzger <markus.t.metzger@intel.com>
11562
11563 * linux-low.c (linux_low_enable_btrace): Update parameters.
11564 (linux_low_btrace_conf): New.
11565 (linux_target_ops)<to_btrace_conf>: Initialize.
11566 * server.c (current_btrace_conf): New.
11567 (handle_btrace_enable): Rename to ...
11568 (handle_btrace_enable_bts): ... this. Pass &current_btrace_conf
11569 to target_enable_btrace. Update comment. Update users.
11570 (handle_qxfer_btrace_conf): New.
11571 (qxfer_packets): Add btrace-conf entry.
11572 (handle_query): Report qXfer:btrace-conf:read as supported packet.
11573 * target.h (target_ops)<enable_btrace>: Update parameters and comment.
11574 (target_ops)<read_btrace_conf>: New.
11575 (target_enable_btrace): Update parameters.
11576 (target_read_btrace_conf): New.
11577
043c3577
MM
115782015-02-09 Markus Metzger <markus.t.metzger@intel.com>
11579
11580 * server.c (handle_btrace_general_set): Remove call to
11581 target_supports_btrace.
11582 (supported_btrace_packets): New.
11583 (handle_query): Call supported_btrace_packets.
11584 * target.h: include btrace-common.h.
11585 (btrace_target_info): Removed.
11586 (supports_btrace, target_supports_btrace): Update parameters.
11587
734b0e4b
MM
115882015-02-09 Markus Metzger <markus.t.metzger@intel.com>
11589
11590 * Makefile.in (SFILES): Add common/btrace-common.c.
11591 (OBS): Add common/btrace-common.o.
11592 (btrace-common.o): Add build rules.
11593 * linux-low: Include btrace-common.h.
11594 (linux_low_read_btrace): Use struct btrace_data. Call
11595 btrace_data_init and btrace_data_fini.
11596
d6c146e9
PA
115972015-02-06 Pedro Alves <palves@redhat.com>
11598
11599 * thread-db.c (find_new_threads_callback): Add debug output.
11600
20ba1ce6
PA
116012015-02-04 Pedro Alves <palves@redhat.com>
11602
11603 * linux-low.c (handle_extended_wait): Don't resume LWPs here.
11604 (resume_stopped_resumed_lwps): New function.
11605 (linux_wait_for_event_filtered): Use it.
11606
8cc73a39
SDJ
116072015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
11608
11609 * Makefile.in (SFILES): Add linux-personality.c.
11610 (linux-personality.o): New rule.
11611 * configure.srv (srv_linux_obj): Add linux-personality.o to the
11612 list of objects to be built.
11613 * linux-low.c: Include nat/linux-personality.h.
11614 (linux_create_inferior): Remove code to disable address space
11615 randomization (moved to ../nat/linux-personality.c). Create
11616 cleanup to disable address space randomization.
11617
fb23d554
SDJ
116182015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
11619
11620 * Makefile.in (posix-strerror.o): New rule.
11621 (mingw-strerror.o): Likewise.
11622 * configure: Regenerated.
11623 * configure.ac: Source file ../common/common.host. Initialize new
11624 variable srv_host_obs. Add srv_host_obs to GDBSERVER_DEPFILES.
11625
cdf43629
YQ
116262015-01-14 Yao Qi <yao@codesourcery.com>
11627
11628 * Makefile.in (SFILES): Add nat/ppc-linux.c.
11629 (ppc-linux.o): New rule.
11630 * configure.srv (powerpc*-*-linux*): Add ppc-linux.o.
11631 * configure.ac: AC_CHECK_FUNCS(getauxval).
11632 * config.in: Re-generated.
11633 * configure: Re-generated.
11634 * linux-ppc-low.c (ppc_arch_setup) [__powerpc64__]: Call
11635 ppc64_64bit_inferior_p
11636
514c5338
YQ
116372015-01-14 Yao Qi <yao@codesourcery.com>
11638
11639 * linux-ppc-low.c: Include "nat/ppc-linux.h".
11640 (PPC_FEATURE_HAS_VSX): Move to nat/ppc-linux.h.
11641 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Likewise.
11642 (PT_ORIG_R3, PT_TRAP): Likewise.
11643 (PTRACE_GETVSXREGS, PTRACE_SETVSXREGS): Likewise.
11644 (PTRACE_GETVRREGS, PTRACE_SETVRREGS): Likewise.
11645 (PTRACE_GETEVRREGS, PTRACE_SETEVRREGS): Likewise.
11646
3368c1e5
JB
116472015-01-10 Joel Brobecker <brobecker@adacore.com>
11648
11649 * i387-fp.c (i387_cache_to_xsave): In look over
11650 num_avx512_zmmh_high_registers, replace use of struct i387_xsave
11651 zmmh_low_space field by use of zmmh_high_space.
11652
582511be
PA
116532015-01-09 Pedro Alves <palves@redhat.com>
11654
11655 * linux-low.c (step_over_bkpt): Move higher up in the file.
11656 (handle_extended_wait): Don't store the stop_pc here.
11657 (get_stop_pc): Adjust comments and rename to ...
11658 (check_stopped_by_breakpoint): ... this. Record whether the LWP
11659 stopped for a software breakpoint or hardware breakpoint.
11660 (thread_still_has_status_pending_p): New function.
11661 (status_pending_p_callback): Use
11662 thread_still_has_status_pending_p. If the event is no longer
11663 interesting, resume the LWP.
11664 (handle_tracepoints): Add assert.
11665 (maybe_move_out_of_jump_pad): Remove cancel_breakpoints call.
11666 (wstatus_maybe_breakpoint): New function.
11667 (cancel_breakpoint): Delete function.
11668 (check_stopped_by_watchpoint): New function, factored out from
11669 linux_low_filter_event.
11670 (lp_status_maybe_breakpoint): Delete function.
11671 (linux_low_filter_event): Remove filter_ptid argument.
11672 Leave thread group exits pending here. Store the LWP's stop PC.
11673 Always leave events pending.
11674 (linux_wait_for_event_filtered): Pull all events out of the
11675 kernel, and leave them all pending.
11676 (count_events_callback, select_event_lwp_callback): Consider all
11677 events.
11678 (cancel_breakpoints_callback, linux_cancel_breakpoints): Delete.
11679 (select_event_lwp): Only give preference to the stepping LWP in
11680 all-stop mode. Adjust comments.
11681 (ignore_event): New function.
11682 (linux_wait_1): Delete 'retry' label. Use ignore_event. Remove
11683 references to cancel_breakpoints. Adjust to renames. Also give
11684 equal priority to all LWPs that have had events in non-stop mode.
11685 If reporting a software breakpoint event, unadjust the LWP's PC.
11686 (linux_wait): If linux_wait_1 returned an ignored event, retry.
11687 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback):
11688 Adjust.
11689 (linux_resume_one_lwp): Store the LWP's PC. Adjust.
11690 (resume_status_pending_p): Use thread_still_has_status_pending_p.
11691 (linux_stopped_by_watchpoint): Adjust.
11692 (linux_target_ops): Remove reference to linux_cancel_breakpoints.
11693 * linux-low.h (enum lwp_stop_reason): New.
11694 (struct lwp_info) <stop_pc>: Adjust comment.
11695 <stopped_by_watchpoint>: Delete field.
11696 <stop_reason>: New field.
11697 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
11698 * mem-break.c (software_breakpoint_inserted_here)
11699 (hardware_breakpoint_inserted_here): New function.
11700 * mem-break.h (software_breakpoint_inserted_here)
11701 (hardware_breakpoint_inserted_here): Declare.
11702 * target.h (struct target_ops) <cancel_breakpoints>: Remove field.
11703 (cancel_breakpoints): Delete.
11704 * tracepoint.c (clear_installed_tracepoints, stop_tracing)
11705 (upload_fast_traceframes): Remove references to
11706 cancel_breakpoints.
11707
a33e3959
PA
117082015-01-09 Pedro Alves <palves@redhat.com>
11709
11710 * thread-db.c (find_new_threads_callback): Ignore thread if the
11711 kernel thread ID is -1.
11712
8784d563
PA
117132015-01-09 Pedro Alves <palves@redhat.com>
11714
11715 * linux-low.c (linux_attach_fail_reason_string): Move to
11716 nat/linux-ptrace.c, and rename.
11717 (linux_attach_lwp): Update comment.
11718 (attach_proc_task_lwp_callback): New function.
11719 (linux_attach): Adjust to rename and use
11720 linux_proc_attach_tgid_threads.
11721 (linux_attach_fail_reason_string): Delete declaration.
11722
76f2b779
JB
117232015-01-01 Joel Brobecker <brobecker@adacore.com>
11724
11725 * gdbreplay.c (gdbreplay_version): Update copyright year to 2015.
11726 * server.c (gdbserver_version): Likewise.
11727
fafcc06a
SDJ
117282014-12-29 Sergio Durigan Junior <sergiodj@redhat.com>
11729
11730 * remote-utils.c: Include ctype.h.
11731 (input_interrupt): Explicitly handle the case when the char
11732 received is the NUL byte. Improve the printing of non-ASCII
11733 characters.
11734
beed38b8
JB
117352014-12-16 Joel Brobecker <brobecker@adacore.com>
11736
11737 * linux-low.c (linux_low_filter_event): Update call to
11738 linux_enable_event_reporting following the addition of
11739 a new parameter to that function.
11740
bf330350
CU
117412014-12-16 Catalin Udma <catalin.udma@freescale.com>
11742
11743 PR server/17457
11744 * linux-aarch64-low.c (AARCH64_FPSR_REGNO): New define.
11745 (AARCH64_FPCR_REGNO): Likewise.
11746 (AARCH64_NUM_REGS): Update to include fpsr/fpcr registers.
11747 (aarch64_fill_fpregset): Add missing fpsr/fpcr registers.
11748 (aarch64_store_fpregset): Likewise.
11749
5227d625
JB
117502014-12-15 Joel Brobecker <brobecker@adacore.com>
11751
11752 * lynx-low.c (lynx_resume): Use PTRACE_SINGLESTEP_ONE if N == 1.
11753 Remove FIXME comment about assumption about N.
11754
f93b65a0
JB
117552014-12-13 Joel Brobecker <brobecker@adacore.com>
11756
11757 * configure.ac: If large-file support is disabled in GDBserver,
11758 pass --disable-largefile to ACX_CONFIGURE_DIR call for "gnulib".
11759 * configure: Regenerate.
11760
e5a9158d
AA
117612014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
11762
11763 * linux-low.c (regsets_fetch_inferior_registers): Suppress the
11764 warning upon ENODATA from ptrace.
11765 * linux-s390-low.c (s390_store_tdb): New.
11766 (s390_regsets): Add regset for NT_S390_TDB.
11767
feea5f36
AA
117682014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
11769
11770 * linux-low.c (regsets_store_inferior_registers): Skip regsets
11771 without a fill_function.
11772 * linux-s390-low.c (s390_fill_last_break): Remove.
11773 (s390_regsets): Set fill_function to NULL for NT_S390_LAST_BREAK.
11774 (s390_arch_setup): Use regset's size instead of fill_function for
11775 loop end condition.
11776
098dbe61
AA
117772014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
11778
11779 * linux-low.c (regsets_fetch_inferior_registers): Do not invoke
11780 the regset's store function when ptrace returned an error.
11781 * regcache.c (get_thread_regcache): Invalidate register cache
11782 before fetching inferior's registers.
11783
28eef672
AA
117842014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
11785
11786 * linux-low.c (regsets_fetch_inferior_registers): Rephrase
11787 while-loop as for-loop.
11788 (regsets_store_inferior_registers): Likewise.
11789
bdca27a2
YQ
117902014-11-28 Yao Qi <yao@codesourcery.com>
11791
11792 * configure.ac(AC_CHECK_FUNCS): Remove readlink.
11793 * config.in, configure: Re-generate.
11794 * hostio.c (handle_unlink): Remove code checking HAVE_READLINK
11795 is defined.
11796
9c232dda
YQ
117972014-11-21 Yao Qi <yao@codesourcery.com>
11798
11799 * configure.ac: Don't invoke AC_FUNC_ALLOCA.
11800 (AC_CHECK_HEADERS): Remove malloc.h.
11801 * configure: Re-generated.
11802 * config.in: Re-generated.
11803 * server.h: Don't include alloca.h and malloc.h.
11804 * gdbreplay.c: Don't check HAVE_ALLOCA_H is defined.
11805 Don't include malloc.h.
11806
43968415
JB
118072014-11-17 Joel Brobecker <brobecker@adacore.com>
11808
11809 * lynx-low.c (lynx_write_memory): Put lynx_read_memory and
11810 corresponding ERRNO check in same block.
11811
40e91bc7
PA
118122014-11-12 Pedro Alves <palves@redhat.com>
11813
11814 * server.c (cont_thread): Update comment.
11815 (start_inferior, attach_inferior): No longer clear cont_thread.
11816 (handle_v_cont): No longer set cont_thread.
11817 (captured_main): Clear cont_thread each time a GDB connects.
11818
c2c118cf
PA
118192014-11-12 Pedro Alves <palves@redhat.com>
11820
11821 * linux-low.c (linux_wait_1): Don't force a wait for the Hc
11822 thread, and don't resume all threads if the Hc thread has exited.
11823
78708b7c
PA
118242014-11-12 Pedro Alves <palves@redhat.com>
11825
11826 * linux-low.c (linux_request_interrupt): Always send a SIGINT to
11827 the process group instead of to a specific LWP.
11828
a2abc7de
PA
118292014-10-15 Pedro Alves <palves@redhat.com>
11830
11831 PR server/17487
11832 * win32-arm-low.c (arm_set_thread_context): Remove current_event
11833 parameter.
11834 (arm_set_thread_context): Delete.
11835 (the_low_target): Adjust.
11836 * win32-i386-low.c (debug_registers_changed)
11837 (debug_registers_used): Delete.
11838 (update_debug_registers_callback): New function.
11839 (x86_dr_low_set_addr, x86_dr_low_set_control): Mark all threads as
11840 needing to update their debug registers.
11841 (win32_get_current_dr): New function.
11842 (x86_dr_low_get_addr, x86_dr_low_get_control)
11843 (x86_dr_low_get_status): Fetch the debug register from the thread
11844 record's context.
11845 (i386_initial_stuff): Adjust.
11846 (i386_get_thread_context): Remove current_event parameter. Don't
11847 clear debug_registers_changed nor copy DR values to
11848 debug_reg_state.
11849 (i386_set_thread_context): Delete.
11850 (i386_prepare_to_resume): New function.
11851 (i386_thread_added): Mark the thread as needing to update irs
11852 debug registers.
11853 (the_low_target): Remove i386_set_thread_context and install
11854 i386_prepare_to_resume.
11855 * win32-low.c (win32_get_thread_context): Adjust.
11856 (win32_set_thread_context): Use SetThreadContext
11857 directly.
11858 (win32_prepare_to_resume): New function.
11859 (win32_require_context): New function, factored out from ...
11860 (thread_rec): ... this.
11861 (continue_one_thread): Call win32_prepare_to_resume on each thread
11862 we're about to continue.
11863 (win32_resume): Call win32_prepare_to_resume on the event thread.
11864 * win32-low.h (struct win32_thread_info)
11865 <debug_registers_changed>: New field.
11866 (struct win32_target_ops): Change prototype of set_thread_context,
11867 delete set_thread_context and add prepare_to_resume.
11868 (win32_require_context): New declaration.
11869
a442d071
GB
118702014-10-08 Gary Benson <gbenson@redhat.com>
11871
11872 * server.h: Do not include common-exceptions.h.
11873
6f1947e8
GB
118742014-10-08 Gary Benson <gbenson@redhat.com>
11875
11876 * server.h: Do not include cleanups.h.
11877
63b434a4
JH
118782014-09-30 James Hogan <james.hogan@imgtec.com>
11879
11880 * Makefile.in (clean): Add rm -f commands for mips-dsp-linux.c and
11881 mips64-dsp-linux.c.
11882
c4d9ceb6
YQ
118832014-09-23 Yao Qi <yao@codesourcery.com>
11884
11885 * linux-low.c (lp_status_maybe_breakpoint): New function.
11886 (linux_low_filter_event): Call lp_status_maybe_breakpoint.
11887 (count_events_callback): Likewise.
11888 (select_event_lwp_callback): Likewise.
11889 (cancel_breakpoints_callback): Likewise.
11890
89a5711c
DB
118912014-09-19 Don Breazeal <donb@codesourcery.com>
11892
11893 * linux-low.c (handle_extended_wait): Call
11894 linux_ptrace_get_extended_event.
11895 (get_stop_pc, get_detach_signal, linux_low_filter_event): Call
11896 linux_is_extended_waitstatus.
11897
bffc0964
JB
118982014-09-16 Joel Brobecker <brobecker@adacore.com>
11899
11900 * Makefile.in (CPPFLAGS): Define.
11901 (INTERNAL_CFLAGS_BASE): Add ${CPPFLAGS}.
11902 (IPAGENT_CFLAGS): Remove ${CPPFLAGS}.
11903
0bfdf32f
GB
119042014-09-16 Gary Benson <gbenson@redhat.com>
11905
11906 * inferiors.h (current_inferior): Renamed as...
11907 (current_thread): New variable. All uses updated.
11908 * linux-low.c (get_pc): Renamed saved_inferior as saved_thread.
11909 (maybe_move_out_of_jump_pad): Likewise.
11910 (cancel_breakpoint): Likewise.
11911 (linux_low_filter_event): Likewise.
11912 (wait_for_sigstop): Likewise.
11913 (linux_resume_one_lwp): Likewise.
11914 (need_step_over_p): Likewise.
11915 (start_step_over): Likewise.
11916 (linux_stabilize_threads): Renamed save_inferior as saved_thread.
11917 * linux-x86-low.c (x86_linux_update_xmltarget): Likewise.
11918 * proc-service.c (ps_lgetregs): Renamed reg_inferior as reg_thread
11919 and save_inferior as saved_thread.
11920 * regcache.c (get_thread_regcache): Renamed saved_inferior as
11921 saved_thread.
11922 (regcache_invalidate_thread): Likewise.
11923 * remote-utils.c (prepare_resume_reply): Likewise.
11924 * thread-db.c (thread_db_get_tls_address): Likewise.
11925 (disable_thread_event_reporting): Likewise.
11926 (remove_thread_event_breakpoints): Likewise.
11927 * tracepoint.c (gdb_agent_about_to_close): Renamed save_inferior
11928 as saved_thread.
11929 * target.h (set_desired_inferior): Renamed as...
11930 (set_desired_thread): New declaration. All uses updated.
11931 * server.c (myresume): Updated comment to reference thread instead
11932 of inferior.
11933 (handle_serial_event): Likewise.
11934 (handle_target_event): Likewise.
11935
361c8ade
GB
119362014-09-12 Tom Tromey <tromey@redhat.com>
11937 Gary Benson <gbenson@redhat.com>
11938
11939 * regcache.h: Include common-regcache.h.
11940 (regcache_read_pc): Don't declare.
11941 * regcache.c (get_thread_regcache_for_ptid): New function.
11942
bd9269f7
GB
119432014-09-11 Tom Tromey <tromey@redhat.com>
11944 Gary Benson <gbenson@redhat.com>
11945
11946 * symbol.c: New file.
11947 * Makefile.in (SFILES): Add symbol.c.
11948 (OBS): Add symbol.o.
11949
f8c1d06b
GB
119502014-09-11 Gary Benson <gbenson@redhat.com>
11951
11952 * target.c (target_stop_ptid, target_continue_ptid): New
11953 functions.
11954
721ec300
GB
119552014-09-11 Tom Tromey <tromey@redhat.com>
11956 Gary Benson <gbenson@redhat.com>
11957
11958 * target.h: Include target/target.h.
11959 * target.c (target_read_memory, target_read_uint32)
11960 (target_write_memory): New functions.
11961
c5e92cca
GB
119622014-09-11 Gary Benson <gbenson@redhat.com>
11963
11964 * server.h (debug_hw_points): Don't declare.
11965 * server.c (debug_hw_points): Don't define. Replace all uses
11966 with show_debug_regs.
11967 * linux-aarch64-low.c (debug_hw_points): Don't define. Replace
11968 all uses with show_debug_regs.
11969
2e4bb98a
EBM
119702014-09-08 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
11971
11972 * linux-ppc-low.c (ppc_collect_ptrace_register): Adjust routine to take
11973 endianness into account.
11974 (ppc_supply_ptrace_register): Likewise.
11975
ac740bc7
JH
119762014-09-03 James Hogan <james.hogan@imgtec.com>
11977
11978 * linux-mips-low.c (mips_read_description): Reset errno to 0 prior
11979 to reading DSP_CONTROL with PTRACE_PEEKUSER ptrace call.
11980
97ea6506
GB
119812014-09-03 Gary Benson <gbenson@redhat.com>
11982
11983 * linux-x86-low.c (x86_linux_prepare_to_resume): Use
11984 ALL_DEBUG_ADDRESS_REGISTERS.
11985
df7e5265
GB
119862014-09-02 Gary Benson <gbenson@redhat.com>
11987
11988 * i386-low.h: Renamed as...
11989 * x86-low.h: New file. All type, function and variable name
11990 prefixes changed from "i386_" to "x86_". All references updated.
11991 * i386-low.c: Renamed as...
11992 * x86-low.c: New file. All type, function and variable name
11993 prefixes changed from "i386_" to "x86_". All references updated.
11994
ed859da7
GB
119952014-09-02 Gary Benson <gbenson@redhat.com>
11996
11997 * linux-x86-low.c (x86_linux_new_process): Use XCNEW.
11998 (x86_linux_new_thread): Likewise.
11999
860789c7
GB
120002014-08-29 Gary Benson <gbenson@redhat.com>
12001
12002 * server.h (setjmp.h): Do not include.
12003 (toplevel): Do not declare.
12004 (common-exceptions.h): Include.
12005 (cleanups.h): Likewise.
12006 * server.c (toplevel): Do not define.
12007 (exit_code): New static global.
12008 (detach_or_kill_for_exit_cleanup): New function.
12009 (main): New function. Original main renamed to...
12010 (captured_main): New function.
12011 * utils.c (verror) [!IN_PROCESS_AGENT]: Use throw_verror.
12012
ff55e1b5
GB
120132014-08-29 Gary Benson <gbenson@redhat.com>
12014
12015 * Makefile.in (SFILES): Add common/common-exceptions.c.
12016 (OBS): Add common-exceptions.o.
12017 (common-exceptions.o): New rule.
12018 * utils.c (prepare_to_throw_exception): New function.
12019
e9bcb658
GB
120202014-08-29 Gary Benson <gbenson@redhat.com>
12021
12022 * config.in: Regenerate.
12023 * configure: Likewise.
12024
e3180625
GB
120252014-08-29 Gary Benson <gbenson@redhat.com>
12026
12027 * Makefile.in (SFILES): Add common/cleanups.c.
12028 (OBS): cleanups.o.
12029 (cleanups.o): New rule.
12030
e3d6ba5d
GB
120312014-08-29 Gary Benson <gbenson@redhat.com>
12032
12033 * utils.c (internal_vwarning): New function.
12034
7096e886
GB
120352014-08-28 Gary Benson <gbenson@redhat.com>
12036
12037 * utils.h (fatal): Remove declaration.
12038 * utils.c (fatal): Remove function.
12039
14ce3192
GB
120402014-08-28 Gary Benson <gbenson@redhat.com>
12041
12042 * tracepoint.c (gdb_agent_init): Replace fatal with
12043 perror_with_name.
12044 (initialize_tracepoint): Likewise.
12045
50278d59
GB
120462014-08-28 Gary Benson <gbenson@redhat.com>
12047
12048 * remote-utils.c (remote_prepare): Replace fatal with error.
12049
aa96c426
GB
120502014-08-28 Gary Benson <gbenson@redhat.com>
12051
12052 * linux-low.c (linux_async): Replace fatal with warning.
12053 Tidy up and return.
12054 (linux_start_non_stop): Return -1 if linux_async failed.
12055
f7160e97
GB
120562014-08-28 Gary Benson <gbenson@redhat.com>
12057
12058 * linux-x86-low.c (i386_dr_low_set_addr): Replace check with
12059 gdb_assert.
12060 (i386_dr_low_get_addr): Remove vague comment.
12061 * win32-i386-low.c (i386_dr_low_set_addr): Replace check with
12062 gdb_assert.
12063
38e08fca
GB
120642014-08-28 Gary Benson <gbenson@redhat.com>
12065
12066 * inferiors.c (get_thread_process): Replace check with gdb_assert.
12067 * linux-low.c (linux_wait_for_event_filtered): Replace fatal with
12068 internal_error.
12069 (linux_resume_one_lwp): Likewise.
12070 * linux-x86-low.c (x86_siginfo_fixup): Replace checks with
12071 gdb_assert.
12072 * mem-break.c (raw_bkpt_type_to_target_hw_bp_type): Replace fatal
12073 with internal_error.
12074 * regcache.c (get_thread_regcache): Replace check with gdb_assert.
12075 (init_register_cache): Replace fatal with gdb_assert_not_reached.
12076 (find_register_by_name): Replace fatal with internal_error.
12077 (find_regno): Likewise.
12078 * tdesc.c (init_target_desc): Replace check with gdb_assert.
12079 * thread-db.c (thread_db_create_event): Likewise.
12080 (thread_db_load_search): Likewise.
12081 (try_thread_db_load_1): Likewise.
12082 * tracepoint.c (get_jump_space_head): Replace fatal with
12083 internal_error.
12084 (claim_trampoline_space): Likewise.
12085 (have_fast_tracepoint_trampoline_buffer): Likewise.
12086 (cmd_qtstart): Likewise.
12087 (stop_tracing): Likewise.
12088 (fast_tracepoint_collecting): Likewise.
12089 (target_malloc): Likewise.
12090 (download_tracepoint): Likewise.
12091 (download_trace_state_variables): Replace check with gdb_assert.
12092 (upload_fast_traceframes): Replace fatal with internal_error.
12093
34abf635
GB
120942014-08-19 Tom Tromey <tromey@redhat.com>
12095 Gary Benson <gbenson@redhat.com>
12096
12097 * Makefile.in (SFILES): Add common/common-debug.c.
12098 (OBS): Add common-debug.o.
12099 (common-debug.o): New rule.
12100 * debug.h (debug_printf): Don't declare.
12101 * debug.c (debug_printf): Renamed and rewritten as...
12102 (debug_vprintf): New function.
12103
f6e94d78
GB
121042014-08-19 Gary Benson <gbenson@redhat.com>
12105
12106 * utils.h: Do not include print-utils.h.
12107
9239eeab
GB
121082014-08-19 Tom Tromey <tromey@redhat.com>
12109 Gary Benson <gbenson@redhat.com>
12110
12111 * server.h: Add static assertion.
12112 (gdb_byte, CORE_ADDR, LONGEST, ULONGEST): Remove.
12113
ef87c8bb
GB
121142014-08-19 Tom Tromey <tromey@redhat.com>
12115 Gary Benson <gbenson@redhat.com>
12116
12117 * Makefile.in (SFILES): Add common/errors.c.
12118 (OBS): Add errors.o.
12119 (IPA_OBS): Add errors-ipa.o.
12120 (errors.o): New rule.
12121 (errors-ipa.o): Likewise.
12122 * utils.h (perror_with_name, error, warning): Don't declare.
12123 * utils.c (warning): Renamed and rewritten as...
12124 (vwarning): New function.
12125 (error): Renamed and rewritten as...
12126 (verror): New function.
12127 (internal_error): Renamed and rewritten as...
12128 (internal_verror): New function.
12129
bb974a24
GB
121302014-08-07 Gary Benson <gbenson@redhat.com>
12131
12132 * configure.ac (AC_CHECK_HEADERS): Remove errno.h.
12133 * configure: Regenerate.
12134 * config.in: Likewise.
12135 * server.h: Do not include errno.h.
12136 * event-loop.c: Likewise.
12137 * hostio-errno.c: Likewise.
12138 * linux-low.c: Likewise.
12139 * remote-utils.c: Likewise.
12140 * spu-low.c: Likewise.
12141 * utils.c: Likewise.
12142 * gdbreplay.c: Unconditionally include errno.h.
12143
6d3d12eb
GB
121442014-08-07 Gary Benson <gbenson@redhat.com>
12145
12146 * server.h: Do not include string.h.
12147 * event-loop.c: Likewise.
12148 * linux-low.c: Likewise.
12149 * regcache.c: Likewise.
12150 * remote-utils.c: Likewise.
12151 * spu-low.c: Likewise.
12152 * utils.c: Likewise.
12153
dccbb609
GB
121542014-08-07 Gary Benson <gbenson@redhat.com>
12155
12156 * server.h: Do not include gdb_assert.h.
12157
e76df0d0
GB
121582014-08-07 Gary Benson <gbenson@redhat.com>
12159
12160 * server.h: Do not include common-utils.h.
12161
4cb9c816
GB
121622014-08-07 Gary Benson <gbenson@redhat.com>
12163
12164 * server.h: Do not include ptid.h.
12165 * notif.h: Likewise.
12166
3995eeee
GB
121672014-08-07 Gary Benson <gbenson@redhat.com>
12168
12169 * server.h: Do not include gdb_locale.h.
12170
cb9f1a9b
GB
121712014-08-07 Gary Benson <gbenson@redhat.com>
12172
12173 * server.h: Do not include gdb/signals.h.
12174 * win32-low.c: Likewise.
12175
a5fceff8
GB
121762014-08-07 Gary Benson <gbenson@redhat.com>
12177
12178 * server.h: Do not include pathmax.h.
12179
b9391142
GB
121802014-08-07 Gary Benson <gbenson@redhat.com>
12181
12182 * server.h: Do not include libiberty.h.
12183 * linux-bfin-low.c: Likewise.
12184
0e443c87
GB
121852014-08-07 Gary Benson <gbenson@redhat.com>
12186
12187 * server.h: Do not include ansidecl.h.
12188
8ebb3f56
GB
121892014-08-07 Gary Benson <gbenson@redhat.com>
12190
12191 * linux-x86-low.c: Do not include stddef.h.
12192 * lynx-ppc-low.c: Likewise.
12193 * tracepoint.c: Likewise.
12194
8980bdf6
GB
121952014-08-07 Gary Benson <gbenson@redhat.com>
12196
12197 * server.h: Do not include stdarg.h.
12198 * nto-low.c: Likewise.
12199
d7096f71
GB
122002014-08-07 Gary Benson <gbenson@redhat.com>
12201
12202 * server.h: Do not include stdlib.h.
12203 * inferiors.c: Likewise.
12204 * linux-low.c: Likewise.
12205 * regcache.c: Likewise.
12206 * spu-low.c: Likewise.
12207 * tracepoint.c: Likewise.
12208 * utils.c: Likewise.
12209
d02f550d
GB
122102014-08-07 Gary Benson <gbenson@redhat.com>
12211
12212 * server.h: Do not include stdio.h.
12213 * linux-low.c: Likewise.
12214 * remote-utils.c: Likewise.
12215 * spu-low.c: Likewise.
12216 * utils.c: Likewise.
12217 * wincecompat.c: Likewise.
12218
87f6c4e3
GB
122192014-08-06 Gary Benson <gbenson@redhat.com>
12220
12221 * regcache.c (init_register_cache): Move conditionals inside if.
12222
7089dca4
GB
122232014-08-06 Gary Benson <gbenson@redhat.com>
12224
12225 * linux-low.c (linux_supports_non_stop): Use target_is_async_p.
12226
462f517e
GB
122272014-07-31 Gary Benson <gbenson@redhat.com>
12228
12229 * ax.h: Do not include server.h.
12230 * gdbthread.h: Likewise.
12231 * lynx-low.h: Likewise.
12232 * notif.h: Likewise.
12233
976411d6
GB
122342014-07-30 Gary Benson <gbenson@redhat.com>
12235
12236 * server.h: Include common-defs.h.
12237 Do not include config.h or build-gnulib-gdbserver/config.h.
12238
d41f6d8e
GB
122392014-07-30 Gary Benson <gbenson@redhat.com>
12240
12241 * hostio-errno.c: Move server.h to top of includes list.
12242 * inferiors.c: Likewise.
12243 * linux-x86-low.c: Likewise.
12244 * notif.c: Include server.h.
12245
314c6a35
TT
122462014-07-24 Tom Tromey <tromey@redhat.com>
12247 Gary Benson <gbenson@redhat.com>
12248
12249 * server.h (CORE_ADDR): Now unsigned.
12250
69ff6be5
PA
122512014-07-16 Pedro Alves <palves@redhat.com>
12252
12253 * linux-low.c (linux_kill_one_lwp): Use kill_lwp, not kill.
12254
ce9e3fe7
PA
122552014-07-15 Pedro Alves <palves@redhat.com>
12256
12257 * linux-low.c (linux_kill_one_lwp): Save errno and work with saved
12258 copy.
12259
e76126e8
PA
122602014-07-11 Pedro Alves <palves@redhat.com>
12261
12262 * linux-low.c (kill_wait_lwp): New function, based on
12263 kill_one_lwp_callback, but use my_waitpid directly.
12264 (kill_one_lwp_callback, linux_kill): Use it.
12265
8e9db26e
PA
122662014-06-23 Pedro Alves <palves@redhat.com>
12267
12268 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR_CONTROL
12269 before setting DR0..DR3.
12270
698b3e08
GB
122712014-06-20 Gary Benson <gbenson@redhat.com>
12272
12273 * configure.ac (AC_REPLACE_FUNCS) <vasprintf, vsnprintf>: Removed.
12274 * configure: Regenerated.
12275 * config.in: Likewise.
12276
125f8a3d
GB
122772014-06-20 Gary Benson <gbenson@redhat.com>
12278
12279 * Makefile.in (SFILES): Update locations for files moved
12280 from common to nat.
12281 (object file files): Reordered.
12282
42995dbd
GB
122832014-06-20 Gary Benson <gbenson@redhat.com>
12284
12285 * i386-low.h (i386_dr_low_can_set_addr): Removed.
12286 (i386_dr_low_set_addr): Likewise.
12287 (i386_dr_low_get_addr): Likewise.
12288 (i386_dr_low_can_set_control): Likewise.
12289 (i386_dr_low_set_control): Likewise.
12290 (i386_dr_low_get_control): Likewise.
12291 (i386_dr_low_get_status): Likewise.
12292 (i386_get_debug_register_length): Likewise.
12293 * linux-x86-low.c (i386_dr_low_set_addr):
12294 Changed signature. Made static.
12295 (i386_dr_low_get_addr): Likewise.
12296 (i386_dr_low_set_control): Likewise.
12297 (i386_dr_low_get_control): Likewise.
12298 (i386_dr_low_get_status): Likewise.
12299 (i386_dr_low): New global variable.
12300 * win32-i386-low.c (i386_dr_low_set_addr):
12301 Changed signature. Made static.
12302 (i386_dr_low_get_addr): Likewise.
12303 (i386_dr_low_set_control): Likewise.
12304 (i386_dr_low_get_control): Likewise.
12305 (i386_dr_low_get_status): Likewise.
12306 (i386_dr_low): New global variable.
12307
e1d2394b
MS
123082014-06-20 Marcus Shawcroft <marcus.shawcroft@arm.com>
12309
12310 * configure.ac: Invoke. AC_CHECK_TOOL(AR, ar).
12311 * Makefile.in (AR, AR_FLAGS): Define.
12312 * configure: Regenerate.
12313
3a8ee006
GB
123142014-06-19 Gary Benson <gbenson@redhat.com>
12315
12316 * Makefile.in (i386-dregs.o): New rule.
12317 * configure.srv: Add i386-dregs.o to all targets using i386-low.o.
12318 * i386-low.c (target.h): Remove include.
12319 (TARGET_HAS_DR_LEN_8): Now in i386-dregs.c.
12320 (DR_CONTROL_SHIFT): Likewise.
12321 (DR_CONTROL_SIZE): Likewise.
12322 (DR_RW_EXECUTE): Likewise.
12323 (DR_RW_WRITE): Likewise.
12324 (DR_RW_READ): Likewise.
12325 (DR_RW_IORW): Likewise.
12326 (DR_LEN_1): Likewise.
12327 (DR_LEN_2): Likewise.
12328 (DR_LEN_4): Likewise.
12329 (DR_LEN_8): Likewise.
12330 (DR_LOCAL_ENABLE_SHIFT): Likewise.
12331 (DR_GLOBAL_ENABLE_SHIFT): Likewise.
12332 (DR_ENABLE_SIZE): Likewise.
12333 (DR_LOCAL_SLOWDOWN): Likewise.
12334 (DR_GLOBAL_SLOWDOWN): Likewise.
12335 (DR_CONTROL_RESERVED): Likewise.
12336 (I386_DR_CONTROL_MASK): Likewise.
12337 (I386_DR_VACANT): Likewise.
12338 (I386_DR_LOCAL_ENABLE): Likewise.
12339 (I386_DR_GLOBAL_ENABLE): Likewise.
12340 (I386_DR_DISABLE): Likewise.
12341 (I386_DR_SET_RW_LEN): Likewise.
12342 (I386_DR_GET_RW_LEN): Likewise.
12343 (I386_DR_WATCH_HIT): Likewise.
12344 (i386_wp_op_t): Likewise.
12345 (i386_show_dr): Likewise.
12346 (i386_length_and_rw_bits): Likewise.
12347 (i386_insert_aligned_watchpoint): Likewise.
12348 (i386_remove_aligned_watchpoint): Likewise.
12349 (i386_handle_nonaligned_watchpoint): Likewise.
12350 i386_update_inferior_debug_regs(): Likewise.
12351 (i386_dr_insert_watchpoint): Likewise.
12352 (i386_dr_remove_watchpoint): Likewise.
12353 (i386_dr_region_ok_for_watchpoint): Likewise.
12354 (i386_dr_stopped_data_address): Likewise.
12355 (i386_dr_stopped_by_watchpoint): Likewise.
12356
8f26655c
GB
123572014-06-19 Gary Benson <gbenson@redhat.com>
12358
12359 * i386-low.c (i386_dr_show): Renamed to
12360 i386_show_dr and made static. All uses updated.
12361 (i386_dr_length_and_rw_bits): Renamed to
12362 i386_length_and_rw_bits and made static.
12363 All uses updated.
12364 (i386_dr_insert_aligned_watchpoint): Renamed to
12365 i386_insert_aligned_watchpoint and made static.
12366 All uses updated.
12367 (i386_dr_remove_aligned_watchpoint): Renamed to
12368 i386_remove_aligned_watchpoint and made static.
12369 All uses updated.
12370 (i386_dr_update_inferior_debug_regs): Renamed to
12371 i386_update_inferior_debug_regs and made static.
12372 All uses updated.
12373
b9228891
GB
123742014-06-18 Gary Benson <gbenson@redhat.com>
12375
5171def3
GB
12376 * i386-low.h (i386_dr_low_can_set_addr): New macro.
12377 (i386_dr_low_can_set_control): Likewise.
12378 (i386_get_debug_register_length): Likewise.
12379 * i386-low.c (i386_dr_low_can_set_addr): Now in i386-low.h.
12380 (i386_dr_low_can_set_control): Likewise.
12381 (i386_get_debug_register_length): Likewise.
12382
123832014-06-17 Gary Benson <gbenson@redhat.com>
12384
b9228891
GB
12385 * i386-low.h (i386-dregs.h): New include.
12386 (DR_FIRSTADDR): Now in i386-dregs.h.
12387 (DR_LASTADDR): Likewise.
12388 (DR_NADDR): Likewise.
12389 (DR_STATUS): Likewise.
12390 (DR_CONTROL): Likewise.
12391 (i386_debug_reg_state): Likewise.
12392 (i386_dr_insert_watchpoint): Likewise.
12393 (i386_dr_remove_watchpoint): Likewise.
12394 (i386_dr_region_ok_for_watchpoint): Likewise.
12395 (i386_dr_stopped_data_address): Likewise.
12396 (i386_dr_stopped_by_watchpoint): Likewise.
12397 * i386-low.c (ALL_DEBUG_REGISTERS): Likewise.
12398
4be83cc2
GB
123992014-06-18 Gary Benson <gbenson@redhat.com>
12400
12401 * i386-low.h (i386_low_insert_watchpoint): Renamed to
12402 i386_dr_insert_watchpoint.
12403 (i386_low_remove_watchpoint): Renamed to
12404 i386_dr_remove_watchpoint.
12405 (i386_low_region_ok_for_watchpoint): Renamed to
12406 i386_dr_region_ok_for_watchpoint.
12407 (i386_low_stopped_data_address): Renamed to
12408 i386_dr_stopped_data_address.
12409 (i386_low_stopped_by_watchpoint): Renamed to
12410 i386_dr_stopped_by_watchpoint.
12411 * i386-low.c (i386_show_dr): Renamed to
12412 i386_dr_show and made nonstatic. All uses updated.
12413 (i386_length_and_rw_bits): Renamed to
12414 i386_dr_length_and_rw_bits and made nonstatic.
12415 All uses updated.
12416 (i386_insert_aligned_watchpoint): Renamed to
12417 i386_dr_insert_aligned_watchpoint and made nonstatic.
12418 All uses updated.
12419 (i386_remove_aligned_watchpoint): Renamed to
12420 i386_dr_remove_aligned_watchpoint and made nonstatic.
12421 All uses updated.
12422 (i386_update_inferior_debug_regs): Renamed to
12423 i386_dr_update_inferior_debug_regs and made nonstatic.
12424 All uses updated.
12425 (i386_low_insert_watchpoint): Renamed to
12426 i386_dr_insert_watchpoint. All uses updated.
12427 (i386_low_remove_watchpoint): Renamed to
12428 i386_dr_remove_watchpoint. All uses updated.
12429 (i386_low_region_ok_for_watchpoint): Renamed to
12430 i386_dr_region_ok_for_watchpoint. All uses updated.
12431 (i386_low_stopped_data_address): Renamed to
12432 i386_dr_stopped_data_address. All uses updated.
12433 (i386_low_stopped_by_watchpoint): Renamed to
12434 i386_dr_stopped_by_watchpoint. All uses updated.
12435
131aa0d4
GB
124362014-06-18 Gary Benson <gbenson@redhat.com>
12437
12438 * i386-low.c (i386_dr_low_can_set_addr): New macro.
12439 (i386_dr_low_can_set_control): Likewise.
12440 (i386_insert_aligned_watchpoint): New check.
12441
d9305f7f
GB
124422014-06-18 Gary Benson <gbenson@redhat.com>
12443
12444 * i386-low.c (i386_update_inferior_debug_regs) <inf_state>:
12445 Renamed to state.
12446
e927c9fc
GB
124472014-06-18 Gary Benson <gbenson@redhat.com>
12448
12449 * i386-low.c (i386_length_and_rw_bits): Use internal_error
12450 instead of fatal and error.
12451 (i386_handle_nonaligned_watchpoint): Likewise.
12452
1b6d4134
GB
124532014-06-18 Gary Benson <gbenson@redhat.com>
12454
12455 * i386-low.c (i386_get_debug_register_length): New macro.
12456 (TARGET_HAS_DR_LEN_8): Remove conditional. Use above macro.
12457 (i386_show_dr): Use debug_printf instead of fprintf. Use
12458 phex to format values.
12459
6e62758f
GB
124602014-06-18 Gary Benson <gbenson@redhat.com>
12461
12462 * i386-low.h: Comment changes.
12463 * i386-low.c: Likewise.
12464
fc6e2f03
GB
124652014-06-18 Gary Benson <gbenson@redhat.com>
12466
12467 * i386-low.c: Whitespace changes.
12468
f9d1eeed
TT
124692014-06-12 Tom Tromey <tromey@redhat.com>
12470
12471 * utils.c (freeargv): Remove.
12472
0b04e523
TT
124732014-06-12 Tom Tromey <tromey@redhat.com>
12474
12475 * debug.c (debug_printf): Remove HAVE_GETTIMEOFDAY checks.
12476 * server.c (monitor_show_help): Remove HAVE_GETTIMEOFDAY check.
12477 (parse_debug_format_options): Likewise.
12478 (gdbserver_usage): Likewise.
12479 * Makefile.in (LIBIBERTY_BUILDDIR, LIBIBERTY): New variables.
12480 (SUBDIRS, REQUIRED_SUBDIRS): Add libiberty.
12481 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Depend on and link
12482 against libiberty.
12483 ($(LIBGNU)): Depend on libiberty.
12484 (all-lib): Recurse into all subdirs.
12485 (install-only): Invoke "install" target in subdirs.
12486 (vasprintf.o, vsnprintf.o, safe-ctype.o, lbasename.o): Remove
12487 targets.
12488 * configure: Rebuild.
12489 * configure.ac: Add ACX_CONFIGURE_DIR for libiberty. Don't check
12490 for vasprintf, vsnprintf, or gettimeofday.
12491 * configure.srv: Don't add safe-ctype.o or lbasename.o to
12492 srv_tgtobj.
12493
270c9937
JB
124942014-06-05 Joel Brobecker <brobecker@adacore.com>
12495
12496 * development.sh: Delete.
12497 * Makefile.in (config.status): Adjust dependency on development.sh.
12498 * configure.ac: Adjust development.sh source call.
12499 * configure: Regenerate.
12500
0a261ed8
PA
125012014-06-02 Pedro Alves <palves@redhat.com>
12502
12503 * ax.c (gdb_free_agent_expr): New function.
12504 * ax.h (gdb_free_agent_expr): New declaration.
12505 * mem-break.c (delete_gdb_breakpoint_1): Also clear the commands
12506 list.
12507 (clear_breakpoint_conditions, clear_breakpoint_commands): Make
12508 static.
12509 (clear_breakpoint_conditions_and_commands): New function.
12510 * mem-break.h (clear_breakpoint_conditions): Delete declaration.
12511 (clear_breakpoint_conditions_and_commands): New declaration.
12512
e9dae05e
RR
125132014-05-23 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
12514
12515 * linux-aarch64-low.c (asm/ptrace.h): Include.
12516
5876f503
JK
125172014-05-21 Jan Kratochvil <jan.kratochvil@redhat.com>
12518
12519 Fix TLS access for -static -pthread.
12520 * gdbserver/thread-db.c (struct thread_db): Add td_thr_tlsbase_p.
12521 (thread_db_get_tls_address): Call it if LOAD_MODULE is zero.
12522 (thread_db_load_search, try_thread_db_load_1): Initialize it.
12523
802e8e6d
PA
125242014-05-20 Pedro Alves <palves@redhat.com>
12525
12526 * linux-aarch64-low.c (aarch64_insert_point)
12527 (aarch64_remove_point): No longer check whether the type is
12528 supported here. Adjust to new interface.
12529 (the_low_target): Install aarch64_supports_z_point_type as
12530 supports_z_point_type method.
12531 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type): New function.
12532 (arm_linux_hw_point_initialize): Take an enum raw_bkpt_type
12533 instead of a Z packet char. Adjust.
12534 (arm_supports_z_point_type): New function.
12535 (arm_insert_point, arm_remove_point): Adjust to new interface.
12536 (the_low_target): Install arm_supports_z_point_type.
12537 * linux-crisv32-low.c (cris_supports_z_point_type): New function.
12538 (cris_insert_point, cris_remove_point): Adjust to new interface.
12539 Don't check whether the type is supported here.
12540 (the_low_target): Install cris_supports_z_point_type.
12541 * linux-low.c (linux_supports_z_point_type): New function.
12542 (linux_insert_point, linux_remove_point): Adjust to new interface.
12543 * linux-low.h (struct linux_target_ops) <insert_point,
12544 remove_point>: Take an enum raw_bkpt_type instead of a char. Add
12545 raw_breakpoint pointer parameter.
12546 <supports_z_point_type>: New method.
12547 * linux-mips-low.c (mips_supports_z_point_type): New function.
12548 (mips_insert_point, mips_remove_point): Adjust to new interface.
12549 Use mips_supports_z_point_type.
12550 (the_low_target): Install mips_supports_z_point_type.
12551 * linux-ppc-low.c (the_low_target): Install NULL as
12552 supports_z_point_type method.
12553 * linux-s390-low.c (the_low_target): Install NULL as
12554 supports_z_point_type method.
12555 * linux-sparc-low.c (the_low_target): Install NULL as
12556 supports_z_point_type method.
12557 * linux-x86-low.c (x86_supports_z_point_type): New function.
12558 (x86_insert_point): Adjust to new insert_point interface. Use
12559 insert_memory_breakpoint. Adjust to new
12560 i386_low_insert_watchpoint interface.
12561 (x86_remove_point): Adjust to remove_point interface. Use
12562 remove_memory_breakpoint. Adjust to new
12563 i386_low_remove_watchpoint interface.
12564 (the_low_target): Install x86_supports_z_point_type.
12565 * lynx-low.c (lynx_target_ops): Install NULL as
12566 supports_z_point_type callback.
12567 * nto-low.c (nto_supports_z_point_type): New.
12568 (nto_insert_point, nto_remove_point): Adjust to new interface.
12569 (nto_target_ops): Install nto_supports_z_point_type.
12570 * mem-break.c: Adjust intro comment.
12571 (struct raw_breakpoint) <raw_type, size>: New fields.
12572 <inserted>: Update comment.
12573 <shlib_disabled>: Delete field.
12574 (enum bkpt_type) <gdb_breakpoint>: Delete value.
12575 <gdb_breakpoint_Z0, gdb_breakpoint_Z1, gdb_breakpoint_Z2,
12576 gdb_breakpoint_Z3, gdb_breakpoint_Z4>: New values.
12577 (raw_bkpt_type_to_target_hw_bp_type): New function.
12578 (find_enabled_raw_code_breakpoint_at): New function.
12579 (find_raw_breakpoint_at): New type and size parameters. Use them.
12580 (insert_memory_breakpoint): New function, based off
12581 set_raw_breakpoint_at.
12582 (remove_memory_breakpoint): New function.
12583 (set_raw_breakpoint_at): Reimplement.
12584 (set_breakpoint): New, based on set_breakpoint_at.
12585 (set_breakpoint_at): Reimplement.
12586 (delete_raw_breakpoint): Go through the_target->remove_point
12587 instead of assuming memory breakpoints.
12588 (find_gdb_breakpoint_at): Delete.
12589 (Z_packet_to_bkpt_type, Z_packet_to_raw_bkpt_type): New functions.
12590 (find_gdb_breakpoint): New function.
12591 (set_gdb_breakpoint_at): Delete.
12592 (z_type_supported): New function.
12593 (set_gdb_breakpoint_1): New function, loosely based off
12594 set_gdb_breakpoint_at.
12595 (check_gdb_bp_preconditions, set_gdb_breakpoint): New functions.
12596 (delete_gdb_breakpoint_at): Delete.
12597 (delete_gdb_breakpoint_1): New function, loosely based off
12598 delete_gdb_breakpoint_at.
12599 (delete_gdb_breakpoint): New function.
12600 (clear_gdb_breakpoint_conditions): Rename to ...
12601 (clear_breakpoint_conditions): ... this. Don't handle a NULL
12602 breakpoint.
12603 (add_condition_to_breakpoint): Make static.
12604 (add_breakpoint_condition): Take a struct breakpoint pointer
12605 instead of an address. Adjust.
12606 (gdb_condition_true_at_breakpoint): Rename to ...
12607 (gdb_condition_true_at_breakpoint_z_type): ... this, and add
12608 z_type parameter.
12609 (gdb_condition_true_at_breakpoint): Reimplement.
12610 (add_breakpoint_commands): Take a struct breakpoint pointer
12611 instead of an address. Adjust.
12612 (gdb_no_commands_at_breakpoint): Rename to ...
12613 (gdb_no_commands_at_breakpoint_z_type): ... this. Add z_type
12614 parameter. Return true if no breakpoint was found. Change debug
12615 output.
12616 (gdb_no_commands_at_breakpoint): Reimplement.
12617 (run_breakpoint_commands): Rename to ...
12618 (run_breakpoint_commands_z_type): ... this. Add z_type parameter,
12619 and change return type to boolean.
12620 (run_breakpoint_commands): New function.
12621 (gdb_breakpoint_here): Also check for Z1 breakpoints.
12622 (uninsert_raw_breakpoint): Don't try to reinsert a disabled
12623 breakpoint. Go through the_target->remove_point instead of
12624 assuming memory breakpoint.
12625 (uninsert_breakpoints_at, uninsert_all_breakpoints): Uninsert
12626 software and hardware breakpoints.
12627 (reinsert_raw_breakpoint): Go through the_target->insert_point
12628 instead of assuming memory breakpoint.
12629 (reinsert_breakpoints_at, reinsert_all_breakpoints): Reinsert
12630 software and hardware breakpoints.
12631 (check_breakpoints, breakpoint_here, breakpoint_inserted_here):
12632 Check both software and hardware breakpoints.
12633 (validate_inserted_breakpoint): Assert the breakpoint is a
12634 software breakpoint. Set the inserted flag to -1 instead of
12635 setting shlib_disabled.
12636 (delete_disabled_breakpoints): Adjust.
12637 (validate_breakpoints): Only validate software breakpoints.
12638 Adjust to inserted flag change.
12639 (check_mem_read, check_mem_write): Skip breakpoint types other
12640 than software breakpoints. Adjust to inserted flag change.
12641 * mem-break.h (enum raw_bkpt_type): New enum.
12642 (raw_breakpoint, struct process_info): Forward declare.
12643 (Z_packet_to_target_hw_bp_type): Delete declaration.
12644 (raw_bkpt_type_to_target_hw_bp_type, Z_packet_to_raw_bkpt_type)
12645 (set_gdb_breakpoint, delete_gdb_breakpoint)
12646 (clear_breakpoint_conditions): New declarations.
12647 (set_gdb_breakpoint_at, clear_gdb_breakpoint_conditions): Delete.
12648 (breakpoint_inserted_here): Update comment.
12649 (add_breakpoint_condition, add_breakpoint_commands): Replace
12650 address parameter with a breakpoint pointer parameter.
12651 (gdb_breakpoint_here): Update comment.
12652 (delete_gdb_breakpoint_at): Delete.
12653 (insert_memory_breakpoint, remove_memory_breakpoint): Declare.
12654 * server.c (process_point_options): Take a struct breakpoint
12655 pointer instead of an address. Adjust.
12656 (process_serial_event) <Z/z packets>: Use set_gdb_breakpoint and
12657 delete_gdb_breakpoint.
12658 * spu-low.c (spu_target_ops): Install NULL as
12659 supports_z_point_type method.
12660 * target.h: Include mem-break.h.
12661 (struct target_ops) <prepare_to_access_memory>: Update comment.
12662 <supports_z_point_type>: New field.
12663 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
12664 instead of a char. Also take a raw breakpoint pointer.
12665 * win32-arm-low.c (the_low_target): Install NULL as
12666 supports_z_point_type.
12667 * win32-i386-low.c (i386_supports_z_point_type): New function.
12668 (i386_insert_point, i386_remove_point): Adjust to new interface.
12669 (the_low_target): Install i386_supports_z_point_type.
12670 * win32-low.c (win32_supports_z_point_type): New function.
12671 (win32_insert_point, win32_remove_point): Adjust to new interface.
12672 (win32_target_ops): Install win32_supports_z_point_type.
12673 * win32-low.h (struct win32_target_ops):
12674 <supports_z_point_type>: New method.
12675 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
12676 instead of a char. Also take a raw breakpoint pointer.
12677
932539e3
PA
126782014-05-20 Pedro Alves <palves@redhat.com>
12679
12680 * mem-break.h: Include break-common.h.
12681 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
12682 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): New defines.
12683 (Z_packet_to_target_hw_bp_type): New declaration.
12684 * mem-break.c (Z_packet_to_target_hw_bp_type): New function.
12685 * i386-low.c (Z_PACKET_HW_BP, Z_PACKET_WRITE_WP, Z_PACKET_READ_WP)
12686 (Z_PACKET_ACCESS_WP): Delete macros.
12687 (Z_packet_to_hw_type): Delete function.
12688 * i386-low.h: Don't include break-common.h here.
12689 (Z_packet_to_hw_type): Delete declaration.
12690 * linux-x86-low.c (x86_insert_point, x86_insert_point): Call
12691 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
12692 * win32-i386-low.c (i386_insert_point, i386_remove_point): Call
12693 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
12694 * linux-aarch64-low.c: Don't include break-common.h here.
12695 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
12696 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): Delete macros.
12697 (Z_packet_to_target_hw_bp_type): Delete function.
12698 * linux-mips-low.c (rsp_bp_type_to_target_hw_bp_type): Delete
12699 function.
12700 (mips_insert_point, mips_remove_point): Use
12701 Z_packet_to_target_hw_bp_type.
12702
4ff0d3d8
PA
127032014-05-20 Pedro Alves <palves@redhat.com>
12704
12705 * linux-aarch64-low.c: Include break-common.h.
12706 (enum target_point_type): Delete.
12707 (Z_packet_to_point_type): Rename to ...
12708 (Z_packet_to_target_hw_bp_type): ... this, and return a
12709 target_hw_bp_type instead.
12710 (aarch64_show_debug_reg_state): Take an enum target_hw_bp_type
12711 instead of an enum target_point_type.
12712 (aarch64_point_encode_ctrl_reg): Likewise. Compute type mask from
12713 breakpoint type.
12714 (aarch64_dr_state_insert_one_point)
12715 (aarch64_dr_state_remove_one_point, aarch64_handle_breakpoint)
12716 (aarch64_handle_aligned_watchpoint)
12717 (aarch64_handle_unaligned_watchpoint, aarch64_handle_watchpoint):
12718 Take an enum target_hw_bp_type instead of an enum
12719 target_point_type.
12720 (aarch64_supports_z_point_type): New function.
12721 (aarch64_insert_point, aarch64_remove_point): Use it. Adjust to
12722 use Z_packet_to_target_hw_bp_type.
12723
786dc519
JB
127242014-05-20 Joel Brobecker <brobecker@adacore.com>
12725
12726 * configure.ac: Only use -Werror by default when DEVELOPMENT
12727 is true.
12728 * configure: Regenerate.
12729
9e0aa64f
JK
127302014-05-19 Jan Kratochvil <jan.kratochvil@redhat.com>
12731
12732 Fix gdbserver qGetTLSAddr for x86_64 -m32.
12733 * linux-x86-low.c (X86_64_USER_REGS): New.
12734 (x86_fill_gregset): Call memset for BUF first in x86_64 -m32 case.
12735
2b577b92
YQ
127362014-04-28 Yao Qi <yao@codesourcery.com>
12737
12738 * Makefile.in (i386-avx512.c): Fix the typo of generated file
12739 name.
12740
94611da2
PA
127412014-04-25 Pedro Alves <palves@redhat.com>
12742
12743 PR server/16255
12744 * linux-low.c (linux_attach_fail_reason_string): New function.
12745 (linux_attach_lwp): Delete.
12746 (linux_attach_lwp_1): Rename to ...
12747 (linux_attach_lwp): ... this. Take a ptid instead of a pid as
12748 argument. Remove "initial" parameter. Return int instead of
12749 void. Don't error or warn here.
12750 (linux_attach): Adjust to call linux_attach_lwp. Call error on
12751 failure to attach to the tgid. Call warning when failing to
12752 attach to an lwp.
12753 * linux-low.h (linux_attach_lwp): Take a ptid instead of a pid as
12754 argument. Remove "initial" parameter. Return int instead of
12755 void. Don't error or warn here.
12756 (linux_attach_fail_reason_string): New declaration.
12757 * thread-db.c (attach_thread): Adjust to linux_attach_lwp's
12758 interface change. Use linux_attach_fail_reason_string.
12759
01f9f808
MS
127602014-04-24 Michael Sturm <michael.sturm@mintel.com>
12761 Walfred Tedeschi <walfred.tedeschi@intel.com>
12762
12763 * Makefile.in: Added rules to handle new files
12764 i386-avx512.c i386-avx512-linux.c amd64-avx512.c
12765 amd64-avx512-linux.c x32-avx512.c x32-avx512-linux.c.
12766 * configure.srv (srv_i386_regobj): Add i386-avx512.o.
12767 (srv_i386_linux_regobj): Add i386-avx512-linux.o.
12768 (srv_amd64_regobj): Add amd64-avx512.o and x32-avx512.o.
12769 (srv_amd64_linux_regobj): Add amd64-avx512-linux.o and
12770 x32-avx512-linux.o.
12771 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx512.xml.
12772 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx512.xml.
12773 (srv_amd64_xmlfiles): Add i386/amd64-avx512.xml and
12774 i386/x32-avx512.xml.
12775 (srv_i386_linux_xmlfiles): Add i386/i386-avx512-linux.xml.
12776 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx512-linux.xml and
12777 i386/x32-avx512-linux.xml.
12778 * i387-fp.c (num_avx512_k_registers): New constant for number
12779 of K registers.
12780 (num_avx512_zmmh_low_registers): New constant for number of
12781 lower ZMM registers (0-15).
12782 (num_avx512_zmmh_high_registers): New constant for number of
12783 higher ZMM registers (16-31).
12784 (num_avx512_ymmh_registers): New contant for number of higher
12785 YMM registers (ymm16-31 added by avx521 on x86_64).
12786 (num_avx512_xmm_registers): New constant for number of higher
12787 XMM registers (xmm16-31 added by AVX512 on x86_64).
12788 (struct i387_xsave): Add space for AVX512 registers.
12789 (i387_cache_to_xsave): Change raw buffer size to 64 characters.
12790 Add code to handle AVX512 registers.
12791 (i387_xsave_to_cache): Add code to handle AVX512 registers.
12792 * linux-x86-low.c (init_registers_amd64_avx512_linux): New
12793 prototypei from generated file.
12794 (tdesc_amd64_avx512_linux): Likewise.
12795 (init_registers_x32_avx512_linux): Likewise.
12796 (tdesc_x32_avx512_linux): Likewise.
12797 (init_registers_i386_avx512_linux): Likewise.
12798 (tdesc_i386_avx512_linux): Likewise.
12799 (x86_64_regmap): Add AVX512 registers.
12800 (x86_linux_read_description): Add code to handle AVX512 XSTATE
12801 mask.
12802 (initialize_low_arch): Add code to initialize AVX512 registers.
12803
51aa91f9
PA
128042014-04-23 Pedro Alves <palves@redhat.com>
12805
12806 * mem-break.c (find_gdb_breakpoint_at): Make static.
12807 * mem-break.h (find_gdb_breakpoint_at): Delete declaration.
12808
a4165e94
PA
128092014-04-23 Pedro Alves <palves@redhat.com>
12810
12811 * i386-low.c: Don't include break-common.h here.
12812 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
12813 prototype to take target_hw_bp_type as argument instead of a Z
12814 packet char.
12815 * i386-low.h: Include break-common.h here.
12816 (Z_packet_to_hw_type): Declare.
12817 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
12818 prototypes.
12819 * linux-x86-low.c (x86_insert_point): Convert the packet number to
12820 a target_hw_bp_type before calling i386_low_insert_watchpoint.
12821 (x86_remove_point): Convert the packet number to a
12822 target_hw_bp_type before calling i386_low_remove_watchpoint.
12823 * win32-i386-low.c (i386_insert_point): Convert the packet number
12824 to a target_hw_bp_type before calling i386_low_insert_watchpoint.
12825 (i386_remove_point): Convert the packet number to a
12826 target_hw_bp_type before calling i386_low_remove_watchpoint.
12827
b8acf843
PA
128282014-04-23 Pedro Alves <palves@redhat.com>
12829
12830 * utils.h (perror_with_name): Add ATTRIBUTE_NORETURN.
12831
d708bcd1
PA
128322014-04-10 Pedro Alves <palves@redhat.com>
12833
12834 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
12835 Check if the condition or command is NULL before checking if the
12836 breakpoint is known. On success, return true.
12837 * mem-break.h (add_breakpoint_condition): Document return.
12838 (add_breakpoint_commands): Add describing comment.
12839 * server.c (skip_to_semicolon): New function.
12840 (process_point_options): Use it.
12841
2eec7d5b
PA
128422014-04-09 Pedro Alves <palves@redhat.com>
12843
12844 * linux-low.c (linux_read_loadmap): Pass current_inferior directly
12845 to lwpid_of.
12846
fa96cb38
PA
128472014-02-27 Pedro Alves <palves@redhat.com>
12848
12849 PR 12702
12850 * inferiors.h (A_I_NEXT, ALL_INFERIORS_TYPE, ALL_PROCESSES): New
12851 macros.
12852 * linux-low.c (delete_lwp, handle_extended_wait): Add debug
12853 output.
12854 (last_thread_of_process_p): Take a PID argument instead of a
12855 thread pointer.
12856 (linux_wait_for_lwp): Delete.
12857 (num_lwps, check_zombie_leaders, not_stopped_callback): New
12858 functions.
12859 (linux_low_filter_event): New function, party factored out from
12860 linux_wait_for_event.
12861 (linux_wait_for_event): Rename to ...
12862 (linux_wait_for_event_filtered): ... this. Add new filter ptid
12863 argument. Partly rewrite. Always use waitpid(-1, WNOHANG) and
12864 sigsuspend. Check for zombie leaders.
12865 (linux_wait_for_event): Reimplement as wrapper around
12866 linux_wait_for_event_filtered.
12867 (linux_wait_1): Handle TARGET_WAITKIND_NO_RESUMED. Assume that if
12868 a normal or signal exit is seen, it's the whole process exiting.
12869 (wait_for_sigstop): No longer a for_each_inferior callback.
12870 Rewrite on top of linux_wait_for_event_filtered.
12871 (stop_all_lwps): Call wait_for_sigstop directly.
12872 * server.c (resume, handle_target_event): Handle
12873 TARGET_WAITKIND_NO_RESUMED.
12874
d763de10
JB
128752014-02-26 Joel Brobecker <brobecker@adacore.com>
12876
12877 * win32-low.c (psapi_get_dll_name,
12878 * win32_CreateToolhelp32Snapshot): Delete.
12879 (win32_CreateToolhelp32Snapshot, win32_Module32First)
12880 (win32_Module32Next, load_toolhelp, toolhelp_get_dll_name):
12881 Delete.
12882 (handle_load_dll): Add function description.
12883 Remove code using psapi_get_dll_name and toolhelp_get_dll_name.
12884
850a0f76
JB
128852014-02-26 Joel Brobecker <brobecker@adacore.com>
12886
12887 * win32-low.c (win32_add_one_solib): Add 0x1000 to load_addr.
12888 Add comment.
12889 (win32_add_all_dlls): Remove 0x1000 offset applied to DLL
12890 base address when calling win32_add_one_solib.
12891 (handle_load_dll): Delete local variable load_addr.
12892 Remove 0x1000 offset applied to DLL base address when calling
12893 win32_add_one_solib.
12894 (handle_unload_dll): Add comment.
12895
f25b3fc3
JB
128962014-02-26 Joel Brobecker <brobecker@adacore.com>
12897
12898 * win32-low.c (win32_add_all_dlls): Renames
12899 win32_ensure_ntdll_loaded. Rewrite function documentation.
12900 Adjust implementation to always load all DLLs.
12901 Add 0x1000 offset to DLL base address when calling
12902 win32_add_one_solib.
12903 (child_initialization_done): New static global.
12904 (do_initial_child_stuff): Set child_initialization_done to
12905 zero during child initialization, and 1 after. Replace call
12906 to win32_ensure_ntdll_loaded by call to win32_add_all_dlls.
12907 Add comment.
12908 (match_dll_by_basename, dll_is_loaded_by_basename): Delete.
12909 (handle_unload_dll): Add function documentation.
12910 (get_child_debug_event): Ignore load and unload DLL events
12911 during child initialization.
12912
d86d4aaf
DE
129132014-02-20 Doug Evans <dje@google.com>
12914
3bc32da3 12915 Remove global all_lwps.
d86d4aaf
DE
12916 * inferiors.h (ptid_of): Move here from linux-low.h.
12917 (pid_of, lwpid_of): Ditto.
12918 * linux-aarch64-low.c (debug_reg_change_callback): Update, "entry"
12919 parameter is a struct thread_info * now.
12920 (aarch64_notify_debug_reg_change): Fetch pid from current_inferior
12921 directly. Pass &all_threads to find_inferior instead of &all_lwps.
12922 (aarch64_stopped_data_address): Fetch lwpid from current_inferior
12923 directly.
12924 (aarch64_linux_prepare_to_resume): Fetch ptid from thread.
12925 (aarch64_arch_setup): Fetch lwpid from current_inferior directly.
12926 * linux-arm-low.c (update_registers_callback): Update, "entry"
12927 parameter is a struct thread_info * now.
12928 Fetch lwpid from current_inferior directly.
12929 (arm_insert_point): Pass &all_threads to find_inferior instead of
12930 &all_lwps.
12931 (arm_remove_point): Ditto.
12932 (arm_stopped_by_watchpoint): Fetch lwp from current_inferior.
12933 (arm_prepare_to_resume): Fetch pid from thread.
12934 (arm_read_description): Fetch lwpid from current_inferior directly.
12935 * linux-low.c (all_lwps): Delete.
12936 (delete_lwp): Delete call to remove_inferior.
12937 (handle_extended_wait): Fetch lwpid from thread.
12938 (add_lwp): Don't set lwp->entry.id. Remove call to
12939 add_inferior_to_list.
12940 (linux_attach_lwp_1): Fetch pid from current_inferior directly.
12941 (linux_kill_one_lwp): Fetch ptid,lwpid from thread.
12942 (kill_one_lwp_callback): Ditto.
12943 (linux_kill): Don't dereference NULL pointer.
12944 Fetch ptid,lwpid from thread.
12945 (get_detach_signal): Fetch ptid from thread.
12946 (linux_detach_one_lwp): Fetch ptid,lwpid from thread.
12947 Simplify call to regcache_invalidate_thread.
12948 (delete_lwp_callback): Update, "entry" parameter is a
12949 struct thread_info * now. Fetch pid from thread.
12950 (linux_mourn): Pass &all_threads to find_inferior instead of &all_lwps.
12951 (status_pending_p_callback): Update, "entry" parameter is a
12952 struct thread_info * now. Fetch ptid from thread.
12953 (find_lwp_pid): Update, "entry" parameter is a
12954 struct thread_info * now.
12955 (linux_wait_for_lwp): Fetch pid from thread.
12956 (linux_fast_tracepoint_collecting): Fetch lwpid from thread.
12957 (maybe_move_out_of_jump_pad): Fetch lwpid from current_inferior.
12958 (enqueue_one_deferred_signal): Fetch lwpid from thread.
12959 (dequeue_one_deferred_signal): Ditto.
12960 (cancel_breakpoint): Fetch ptid from current_inferior.
12961 (linux_wait_for_event): Pass &all_threads to find_inferior,
12962 not &all_lwps. Fetch ptid, lwpid from thread.
12963 (count_events_callback): Update, "entry" parameter is a
12964 struct thread_info * now.
12965 (select_singlestep_lwp_callback): Ditto.
12966 (select_event_lwp_callback): Ditto.
12967 (cancel_breakpoints_callback): Ditto.
12968 (linux_cancel_breakpoints): Pass &all_threads to find_inferior,
12969 not &all_lwps.
12970 (select_event_lwp): Ditto. Fetch ptid from event_thread.
12971 (unsuspend_one_lwp): Update, "entry" parameter is a
12972 struct thread_info * now.
12973 (unsuspend_all_lwps): Pass &all_threads to find_inferior,
12974 not &all_lwps.
12975 (linux_stabilize_threads): Ditto. And for for_each_inferior.
12976 Fetch lwpid from thread, not lwp.
12977 (linux_wait_1): Fetch ptid, lwpid from current_inferior.
12978 Pass &all_threads to find_inferior, not &all_lwps.
12979 (send_sigstop): Fetch lwpid from thread, not lwp.
12980 (send_sigstop_callback): Update, "entry" parameter is a
12981 struct thread_info * now.
12982 (suspend_and_send_sigstop_callback): Ditto.
12983 (wait_for_sigstop): Ditto. Fetch ptid, lwpid from thread, lwp.
12984 (stuck_in_jump_pad_callback): Update, "entry" parameter is a
12985 struct thread_info * now.
12986 (move_out_of_jump_pad_callback): Ditto. Fetch ptid, lwpid
12987 from thread, lwp.
12988 (lwp_running): Update, "entry" parameter is a
12989 struct thread_info * now.
12990 (stop_all_lwps): Fetch ptid from thread.
12991 Pass &all_threads to find_inferior, for_each_inferior, not &all_lwps.
12992 (linux_resume_one_lwp): Fetch lwpid from thread.
12993 (linux_set_resume_request): Update, "entry" parameter is a
12994 struct thread_info * now. Fetch pid, lwpid from thread.
12995 (resume_status_pending_p): Update, "entry" parameter is a
12996 struct thread_info * now.
12997 (need_step_over_p): Ditto. Fetch lwpid from thread.
12998 (start_step_over): Fetch lwpid from thread.
12999 (linux_resume_one_thread): Update, "entry" parameter is a
13000 struct thread_info * now. Fetch lwpid from thread.
13001 (linux_resume): Pass &all_threads to find_inferior, not &all_lwps.
13002 (proceed_one_lwp): Update, "entry" parameter is a
13003 struct thread_info * now. Fetch lwpid from thread.
13004 (unsuspend_and_proceed_one_lwp): Update, "entry" parameter is a
13005 struct thread_info * now.
13006 (proceed_all_lwps): Pass &all_threads to find_inferior, not &all_lwps.
13007 (unstop_all_lwps): Ditto. Fetch lwpid from thread.
13008 (regsets_fetch_inferior_registers): Fetch lwpid from current_inferior
13009 directly.
13010 (regsets_store_inferior_registers): Ditto.
13011 (fetch_register, store_register): Ditto.
13012 (linux_read_memory, linux_write_memory): Ditto.
13013 (linux_request_interrupt): Ditto.
13014 (linux_read_auxv): Ditto.
13015 (linux_xfer_siginfo): Ditto.
13016 (linux_qxfer_spu): Ditto.
13017 (linux_qxfer_libraries_svr4): Ditto.
13018 * linux-low.h (ptid_of, pid_of, lwpid_of): Delete,
13019 moved to inferiors.h.
13020 (get_lwp): Delete.
13021 (get_thread_lwp): Update.
13022 (struct lwp_info): Delete member "entry". Simplify comment for
13023 member "thread".
13024 (all_lwps): Delete.
13025 * linux-mips-low.c (mips_read_description): Fetch lwpid from
13026 current_inferior directly.
13027 (update_watch_registers_callback): Update, "entry" parameter is a
13028 struct thread_info * now. Fetch pid from thread.
13029 (mips_linux_prepare_to_resume): Fetch ptid from thread.
13030 (mips_insert_point): Fetch lwpid from current_inferior.
13031 Pass &all_threads to find_inferior, not &all_lwps.
13032 (mips_remove_point): Pass &all_threads to find_inferior, not &all_lwps.
13033 (mips_stopped_by_watchpoint): Fetch lwpid from current_inferior
13034 directly.
13035 (mips_stopped_data_address): Ditto.
13036 * linux-s390-low.c (s390_arch_setup): Fetch pid from current_inferior
13037 directly.
13038 * linux-tile-low.c (tile_arch_setup): Ditto.
13039 * linux-x86-low.c (x86_get_thread_area): Fetch lwpid from thread.
13040 (update_debug_registers_callback): Update, "entry" parameter is a
13041 struct thread_info * now. Fetch pid from thread.
13042 (i386_dr_low_set_addr): Fetch pid from current_inferior directly.
13043 Pass &all_threads to find_inferior, not &all_lwps.
13044 (i386_dr_low_get_addr): Fetch ptid from current_inferior directly.
13045 (i386_dr_low_set_control): Fetch pid from current_inferior directly.
13046 Pass &all_threads to find_inferior, not &all_lwps.
13047 (i386_dr_low_get_control): Fetch ptid from current_inferior directly.
13048 (i386_dr_low_get_status): Ditto.
13049 (x86_linux_prepare_to_resume): Fetch ptid from thread.
13050 (x86_siginfo_fixup): Fetch lwpid from current_inferior directly.
13051 (x86_linux_read_description): Ditto.
13052 * proc-service.c (ps_getpid): Fetch pid from current_inferior directly.
13053
3b8361aa
DE
130542014-02-20 Doug Evans <dje@google.com>
13055
13056 * inferiors.c (get_first_inferior): Fix buglet.
13057
f7667f0d
DE
130582014-02-19 Doug Evans <dje@google.com>
13059
13060 * gdbthread.h (add_thread): Change result type to struct thread_info *.
13061 * inferiors.c (add_thread): Change result type to struct thread_info *.
13062 All callers updated.
13063 (add_lwp): Call add_thread here instead of in callers.
13064 All callers updated.
13065 * linux-low.h (get_lwp_thread): Rewrite.
13066 (struct lwp_info): New member "thread".
13067
b3312d80
DE
130682014-02-19 Doug Evans <dje@google.com>
13069
13070 * linux-low.c (add_lwp): Change result to struct lwp_info *.
13071 All callers updated.
13072
ecc6f45c
DE
130732014-02-19 Doug Evans <dje@google.com>
13074
13075 * inferiors.c (add_thread): Fix whitespace.
13076
649ebbca
DE
130772014-02-19 Doug Evans <dje@google.com>
13078
13079 * dll.c (clear_dlls): Replace accessing list implemention details
13080 with API function.
13081 * gdbthread.h (get_first_thread): Declare.
13082 * inferiors.c (for_each_inferior_with_data): New function.
13083 (get_first_thread): New function.
13084 (find_thread_ptid): Simplify.
13085 (get_first_inferior): New function.
13086 (clear_list): Delete.
13087 (one_inferior_p): New function.
13088 (clear_inferior_list): New function.
13089 (clear_inferiors): Update.
13090 * inferiors.h (for_each_inferior_with_data): Declare.
13091 (clear_inferior_list): Declare.
13092 (one_inferior_p): Declare.
13093 (get_first_inferior): Declare.
13094 * linux-low.c (linux_wait_for_event): Replace accessing list
13095 implemention details with API function.
13096 * server.c (target_running): Ditto.
13097 (accumulate_file_name_length): New function.
13098 (emit_dll_description): New function.
13099 (handle_qxfer_libraries): Replace accessing list implemention
13100 details with API function.
13101 (handle_qxfer_threads_worker): New function.
13102 (handle_qxfer_threads_proper): Replace accessing list implemention
13103 details with API function.
13104 (handle_query): Ditto.
13105 (visit_actioned_threads_callback_ftype): New typedef.
13106 (visit_actioned_threads_data): New struct.
13107 (visit_actioned_threads): Rewrite to be find_inferior callback.
13108 (resume): Call find_inferior.
13109 (handle_status): Replace accessing list implemention
13110 details with API function.
13111 (process_serial_event): Replace accessing list implemention details
13112 with API function.
13113 * target.c (set_desired_inferior): Replace accessing list implemention
13114 details with API function.
13115 * tracepoint.c (same_process_p): New function.
13116 (gdb_agent_about_to_close): Replace accessing list implemention
13117 details with API function.
13118 * win32-low.c (child_delete_thread): Replace accessing list
13119 implemention details with API function.
13120 (match_dll_by_basename): New function.
13121 (dll_is_loaded_by_basename): New function.
13122 (win32_ensure_ntdll_loaded): Replace accessing list implemention
13123 details call to dll_is_loaded_by_basename.
13124
80894984
DE
131252014-02-19 Doug Evans <dje@google.com>
13126
13127 * dll.h (struct dll_info): Add comment.
13128 * gdbthread.h (struct thread_info): Add comment.
13129 (current_ptid): Simplify.
13130 * inferiors.c (add_process): Update.
13131 (remove_process): Update.
13132 * inferiors.h (struct process_info): Rename member "head" to "entry".
13133 * linux-low.c (delete_lwp): Update.
13134 (add_lwp): Update.
13135 (last_thread_of_process_p): Update.
13136 (kill_one_lwp_callback, linux_kill): Update.
13137 (status_pending_p_callback): Update.
13138 (wait_for_sigstop): Update. Simplify read of ptid.
13139 (start_step_over): Update.
13140 * linux-low.h (ptid_of, pid_of, lwpid_of): Update.
13141 (get_lwp_thread): Update.
13142 (struct lwp_info): Rename member "head" to "entry".
13143 * regcache.h (inferior_list_entry): Delete.
13144 * server.c (kill_inferior_callback): Update.
13145 (detach_or_kill_inferior_callback): Update.
13146 (print_started_pid): Update.
13147 (print_attached_pid): Update.
13148 (process_serial_event): Simplify read of ptid.
13149 * thread-db.c (thread_db_create_event): Update.
13150 (thread_db_get_tls_address): Update.
13151 * win32-low.c (current_inferior_ptid): Simplify.
13152
46917d26
TT
131532014-02-19 Tom Tromey <tromey@redhat.com>
13154
13155 * target.h (struct target_ops) <supports_btrace>: Add target_ops
13156 argument.
13157 (target_supports_btrace): Update.
13158
0759a81e
YQ
131592014-02-14 Yao Qi <yao@codesourcery.com>
13160
13161 * Makefile.in (IPA_OBJS): Append rsp-low-ipa.o.
13162 (rsp-low-ipa.o): New target.
13163
a7191e8b
TT
131642014-02-12 Tom Tromey <tromey@redhat.com>
13165
13166 * ax.c (gdb_parse_agent_expr): Use hex2bin, not
13167 convert_ascii_to_int.
13168 * regcache.c (registers_to_string): Likewise.
13169 * remote-utils.c (decode_M_packet): Likewise.
13170 * server.c (process_serial_event): Likewise.
13171
ff0e980e
TT
131722014-02-12 Tom Tromey <tromey@redhat.com>
13173
13174 * server.c (handle_query, handle_v_run): Use hex2bin, not
13175 unhexify.
13176 * tracepoint.c (cmd_qtdpsrc, cmd_qtdv, cmd_qtnotes): Likewise.
13177
e9371aff
TT
131782014-02-12 Tom Tromey <tromey@redhat.com>
13179
13180 * ax.c (gdb_unparse_agent_expr): Use bin2hex, not
13181 convert_int_to_ascii.
13182 * regcache.c (registers_to_string, collect_register_as_string):
13183 Likewise.
13184 * remote-utils.c (look_up_one_symbol, relocate_instruction):
13185 Likewise.
13186 * server.c (process_serial_event): Likewise.
13187 * tracepoint.c (cmd_qtstatus, response_source, response_tsv)
13188 (cmd_qtbuffer, cstr_to_hexstr): Likewise.
13189
971dc0b8
TT
131902014-02-12 Tom Tromey <tromey@redhat.com>
13191
13192 * remote-utils.c (look_up_one_symbol, monitor_output): Use
13193 bin2hex, not hexify.
13194 * tracepoint.c (cmd_qtstatus): Likewise.
13195
0a822afb
TT
131962014-02-12 Tom Tromey <tromey@redhat.com>
13197
13198 * remote-utils.c (monitor_output): Pass explicit length to
13199 hexify.
13200
9c3d6531
TT
132012014-02-12 Tom Tromey <tromey@redhat.com>
13202
13203 * tracepoint.c: Include rsp-low.h.
13204 * server.c: Include rsp-low.h.
13205 * remote-utils.h (convert_ascii_to_int, convert_int_to_ascii)
13206 (unhexify, hexify, remote_escape_output, unpack_varlen_hex): Don't
13207 declare.
13208 * remote-utils.c: Include rsp-low.h.
13209 (fromhex, hexchars, ishex, unhexify, tohex, hexify)
13210 (remote_escape_output, remote_unescape_input, unpack_varlen_hex)
13211 (convert_int_to_ascii, convert_ascii_to_int): Move to
13212 common/rsp-low.c.
13213 * regcache.c: Include rsp-low.h.
13214 * ax.c: Include rsp-low.h.
13215 * Makefile.in (SFILES): Add common/rsp-low.c.
13216 (OBS): Add rsp-low.o.
13217 (rsp-low.o): New target.
13218
01fd3ea5
TT
132192014-02-12 Tom Tromey <tromey@redhat.com>
13220
13221 * utils.h (pulongest, plongest, phex_nz): Don't declare.
13222 Include print-utils.h.
13223 * utils.c (NUMCELLS, CELLSIZE, get_cell, decimal2str, pulongest)
13224 (plongest, thirty_two, phex_nz): Remove.
13225 * Makefile.in (SFILES): Add common/print-utils.c.
13226 (OBS): Add print-utils.o.
13227 (print-utils-ipa.o): New target.
13228 (print-utils.o): New target.
13229 (IPA_OBJS): Add print-utils-ipa.o.
13230
e99dc820
TT
132312014-02-06 Tom Tromey <tromey@redhat.com>
13232
13233 * Makefile.in (SFILES): Fix indentation.
13234
ee1e2d4f
DE
132352014-02-05 Doug Evans <dje@google.com>
13236
13237 * linux-low.c (linux_wait_for_event): Improve comment.
13238 (linux_wait_1): Keep current_inferior in sync with event_child.
13239
f5a02773
DE
132402014-01-22 Doug Evans <dje@google.com>
13241
13242 * gdbthread.h (gdb_id_to_thread): Delete, unused.
13243
87ce2a04
DE
132442014-01-22 Doug Evans <dje@google.com>
13245
13246 * configure.ac (AC_CHECK_FUNCS): Add test for gettimeofday.
13247 * configure: Regenerate.
13248 * config.in: Regenerate.
13249 * Makefile.in (SFILES): Add debug.c.
13250 (OBS): Add debug.o.
13251 * debug.c: New file.
13252 * debug.h: New file.
13253 * linux-aarch64-low.c (*): Update all debugging printfs to use
13254 debug_printf instead of fprintf.
13255 * linux-arm-low.c (*): Ditto.
13256 * linux-cris-low.c (*): Ditto.
13257 * linux-crisv32-low.c (*): Ditto.
13258 * linux-m32r-low.c (*): Ditto.
13259 * linux-sparc-low.c (*): Ditto.
13260 * linux-x86.c (*): Ditto.
13261 * linux-low.c (*): Ditto.
13262 (linux_wait_1): Add calls to debug_enter, debug_exit.
13263 (linux_wait): Remove redundant debugging printf.
13264 (stop_all_lwps): Add calls to debug_enter, debug_exit.
13265 (linux_resume, unstop_all_lwps): Ditto.
13266 * mem-break.c (*): Update all debugging printfs to use
13267 debug_printf instead of fprintf.
13268 * remote-utils.c (*): Ditto.
13269 * thread-db.c (*): Ditto.
13270 * server.c #include <ctype.h>, "gdb_vecs.h".
13271 (debug_threads): Moved to debug.c.
13272 (*): Update all debugging printfs to use debug_printf instead of
13273 fprintf.
13274 (start_inferior): Replace call to fflush with call to debug_flush.
13275 (monitor_show_help): Mention set debug-format.
13276 (parse_debug_format_options): New function.
13277 (handle_monitor_command): Handle "monitor set debug-format".
13278 (gdbserver_usage): Mention --debug-format.
13279 (main): Parse --debug-format.
13280 * server.h (debug_threads): Declaration moved to debug.h.
13281 #include "debug.h".
13282 * tracepoint.c (trace_debug_1) [!IN_PROCESS_AGENT]: Add version of
13283 trace_debug_1 that uses debug_printf.
13284 (tracepoint_look_up_symbols): Update all debugging printfs to use
13285 debug_printf instead of fprintf.
13286
e671835b
BS
132872014-01-20 Baruch Siach <baruch@tkos.co.il>
13288
13289 * linux-xtensa-low.c: Include asm/ptrace.h instead of
13290 sys/ptrace.h.
13291
b5737fa9
PA
132922014-01-17 Pedro Alves <palves@redhat.com>
13293
ea38d2a9 13294 PR build/16445
c7faa97a
PA
13295 * linux-x86-low.c: Don't include elf/common.h if ELFMAG0 is
13296 defined after including gdb_proc_service.h.
b5737fa9 13297
40ed484e
DE
132982014-01-16 Doug Evans <dje@google.com>
13299
13300 * dll.c (UNSPECIFIED_CORE_ADDR): New macro.
13301 (match_dll): Use it.
13302
969c39fb
MM
133032014-01-16 Markus Metzger <markus.t.metzger@intel.com>
13304
13305 * target.h (target_ops) <read_btrace>: Change parameters and
13306 return type to allow error reporting.
13307 * server.c (handle_qxfer_btrace): Support delta reads. Pass
13308 trace reading errors on.
13309 * linux-low.c (linux_low_read_btrace): Pass trace reading
13310 errors on.
13311 (linux_low_disable_btrace): New.
13312
ab7f45ba
DE
133132014-01-15 Doug Evans <dje@google.com>
13314
13315 * inferiors.c (thread_id_to_gdb_id): Delete.
13316 * inferiors.h (thread_id_to_gdb_id): Delete.
13317
66af0f44
EZ
133182014-01-13 Eli Zaretskii <eliz@gnu.org>
13319
13320 * Makefile.in (INCLUDE_CFLAGS): Remove trailing slash from
13321 "-I$(srcdir)/../". Fixes MinGW compilation errors with old GCC
13322 versions.
13323
9939e131
PA
133242014-01-08 Pedro Alves <palves@redhat.com>
13325
13326 * server.c (handle_status): Don't discard previous queued stop
13327 replies or thread's pending status here.
13328 (main) <disconnection>: Do it here instead.
13329
b7ea362b
PA
133302014-01-08 Pedro Alves <palves@redhat.com>
13331
13332 * gdbthread.h (struct thread_info) <status_pending_p>: New field.
13333 * server.c (visit_actioned_threads, handle_pending_status): New
13334 function.
13335 (handle_v_cont): Factor out parts to ...
13336 (resume): ... this new function. If in all-stop, and a thread
13337 being resumed has a pending status, report it without actually
13338 resuming.
13339 (myresume): Adjust to use the new 'resume' function.
13340 (clear_pending_status_callback, set_pending_status_callback)
13341 (find_status_pending_thread_callback): New functions.
13342 (handle_status): Handle the case of multiple threads having
13343 interesting statuses to report. Report threads' real last signal
13344 instead of always reporting GDB_SIGNAL_TRAP. Look for a thread
13345 with an interesting thread to report the status for, instead of
13346 always reporting the status of the first thread.
13347
28498c42
JB
133482014-01-01 Joel Brobecker <brobecker@adacore.com>
13349
13350 * gdbserver.c (gdbserver_version): Set copyright year to 2014.
13351 * gdbreplay.c (gdbreplay_version): Likewise.
13352
f45c82da
YZ
133532013-12-18 Yufeng Zhang <yufeng.zhang@arm.com>
13354
13355 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Set
13356 iov.iov_len with the real length in use.
13357
379a5e2d
JB
133582013-12-13 Joel Brobecker <brobecker@adacore.com>
13359
13360 * Makefile.in (safe-ctype.o, lbasename.o): New rules.
13361 * configure.srv: Add safe-ctype.o and lbasename.o to srv_tgtobj
13362 for all targets that use win32-low.c.
13363 * win32-low.c (win32_ensure_ntdll_loaded): New function.
13364 (do_initial_child_stuff): Add call to win32_ensure_ntdll_loaded.
13365
4210d83e
PA
133662013-12-13 Pedro Alves <palves@redhat.com>
13367
13368 * target.c (mywait): Set OURSTATUS->KIND to TARGET_WAITKIND_STOPPED
13369 if equal to TARGET_WAITKIND_LOADED.
13370 * win32-low.c (cached_status): New static global.
13371 (win32_wait): Add declaration.
13372 (do_initial_child_stuff): Flush all initial pending debug events
13373 up to the initial breakpoint.
13374 (win32_wait): If CACHED_STATUS was set, return that instead
13375 of doing a real wait. Remove the code resuming the execution
13376 of the inferior after receiving a TARGET_WAITKIND_LOADED event
13377 during the initial phase. Also remove the code changing
13378 OURSTATUS->KIND from TARGET_WAITKIND_LOADED to
13379 TARGET_WAITKIND_STOPPED.
13380
e7f0d979
YQ
133812013-12-11 Yao Qi <yao@codesourcery.com>
13382
13383 * notif.c (handle_notif_ack): Return 0 if no notification
13384 matches.
13385
ebcf782c
DE
133862013-11-20 Doug Evans <dje@google.com>
13387
13388 * linux-low.c (linux_set_resume_request): Fix comment.
13389
20ad9378
DE
133902013-11-20 Doug Evans <dje@google.com>
13391
13392 * linux-low.c (resume_status_pending_p): Tweak comment.
13393
a196ebeb
WT
133942013-11-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
13395
13396 * Makefile.in: Add i386-mpx.c, i386-mpx-linux.c, amd64-mpx.c,
13397 amd64-mpx-linux.c, x32-mpx.c and x32-mpx-linux.c generation.
13398 * configure.srv (srv_i386_regobj): Add i386-mpx.o.
13399 (srv_i386_linux_regobj): Add i386-mpx-linux.o.
13400 (srv_amd64_regobj): Add amd64-mpx.o.
13401 (srv_amd64_linux_regobj): Add amd64-mpx-linux.o.
13402 (srv_i386_32bit_xmlfiles): Add i386/32bit-mpx.xml.
13403 (srv_i386_64bit_xmlfiles): Add i386/64bit-mpx.xml.
13404 * i387-fp.c (num_pl_bnd_register) Added constant.
13405 (num_pl_bnd_cfg_registers) Added constant.
13406 (struct i387_xsave) Added reserved area and MPX fields.
13407 (i387_cache_to_xsave, i387_xsave_to_cache) Add MPX.
13408 * linux-x86-low.c (init_registers_i386_mpx_linux): Declare new
13409 function.
13410 (tdesc_i386_mpx_linux): Add MPX amd64 target.
13411 (init_registers_amd64_mpx_linux): Declare new function.
13412 (tdesc_amd64_mpx_linux): Add MPX amd64 target.
13413 (x86_64_regmap): Add MPX registers.
13414 (x86_linux_read_description): Add MPX case.
13415 (initialize_low_arch): Initialize MPX targets.
13416
0080a2f6
TT
134172013-11-18 Tom Tromey <tromey@redhat.com>
13418
13419 * configure: Rebuild.
13420 * configure.ac: Don't check for stdlib.h.
13421 * gdbreplay.c: Unconditionally include stdlib.h.
13422
2978b111
TT
134232013-11-18 Tom Tromey <tromey@redhat.com>
13424
13425 * config.in: Rebuild.
13426 * configure: Rebuild.
13427 * configure.ac: Don't use AC_HEADER_DIRENT.
13428
a3d08894
TT
134292013-11-18 Tom Tromey <tromey@redhat.com>
13430
13431 * server.h: Don't check HAVE_STRING_H.
13432 * gdbreplay.c: Don't check HAVE_STRING_H.
13433 * configure: Rebuild.
13434
0a5dd17d
TT
134352013-11-18 Tom Tromey <tromey@redhat.com>
13436
13437 * Makefile.in (gdbreplay$(EXEEXT)): Depend on and link against
13438 LIBGNU.
13439
1bd2f0ba
TT
134402013-11-08 Tom Tromey <tromey@redhat.com>
13441
13442 * configure, config.in: Rebuild.
13443 * configure.ac: Remove unused configury.
13444
3266f10b
TT
134452013-11-08 Tom Tromey <tromey@redhat.com>
13446
13447 * acinclude.m4: Include common.m4, codeset.m4.
13448 * configure, config.in: Rebuild.
13449 * configure.ac: Use GDB_AC_COMMON.
13450
6682d959
AA
134512013-11-06 Andreas Arnez <arnez@linux.vnet.ibm.com>
13452
13453 * linux-s390-low.c (HWCAP_S390_TE): New define.
13454 (s390_arch_setup): Consider the TE field in the HWCAP for
13455 determining 'have_regset_tdb'.
13456
fd0a4d76
SDJ
134572013-10-16 Sergio Durigan Junior <sergiodj@redhat.com>
13458
13459 PR gdb/16014
13460 * tracepoint.c (download_tracepoint_1): Remove unnecessary double
13461 call to sizeof.
13462
1a3d890b
PA
134632013-10-02 Pedro Alves <palves@redhat.com>
13464
13465 * server.c (process_serial_event): Don't output "GDBserver
13466 exiting" if GDB is connected through stdio.
13467 * target.c (mywait): Likewise, be silent if GDB is connected
13468 through stdio.
13469
97ad4581
JB
134702013-10-01 Joel Brobecker <brobecker@adacore.com>
13471
13472 * lynx-low.c (lynx_add_threads_after_attach): New function.
13473 (lynx_attach): Remove call to add_thread. Add call to
13474 lynx_add_threads_after_attach instead.
13475
5b4e221c
MF
134762013-09-28 Mike Frysinger <vapier@gentoo.org>
13477
13478 * configure.ac (AC_CHECK_HEADERS): Add sys/syscall.h
13479 * config.in, configure: Regenerated.
13480
ee47b2f8
YQ
134812013-09-18 Yao Qi <yao@codesourcery.com>
13482
13483 PR server/15959
13484 * server.c (start_inferior): Clear 'resume_info'.
13485
d6707650 134862013-09-16 Jiong Wang <jiwang@tilera.com>
0f63d4db 13487
d6707650
JW
13488 * linux-tile-low.c (tile_regsets): Modify the size field to 64-bit
13489 for each register.
13490
9243dd0e 134912013-09-16 Jiong Wang <jiwang@tilera.com>
0f63d4db 13492
9243dd0e
JW
13493 * configure.srv <tilegx*-*-linux*>: Remove linux-osdata.o from and add
13494 linux-tile-low.o to srv_tgtobj.
13495
c623a6ef
WN
134962013-09-16 Will Newton <will.newton@linaro.org>
13497
13498 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Zero
13499 out regs.
13500
fb71d39e
PA
135012013-09-06 Pedro Alves <palves@redhat.com>
13502
13503 * Makefile.in (gdb_proc_service_h, regdef_h, regcache_h)
13504 (signals_def, signals_h, ptid_h, ax_h, agent_h, linux_btrace_h)
13505 (linux_osdata_h, vec_h, gdb_vecs_h, host_defs_h, libiberty_h)
13506 (server_h, gdbthread_h, linux_low_h, linux_ptrace_h)
13507 (gdb_thread_db_h, linux_procfs_h, lynx_low_h, nto_low_h)
13508 (mips_linux_watch_h, i386_low_h, win32_low_h): Delete.
13509
8e7e9910
PA
135102013-09-06 Pedro Alves <palves@redhat.com>
13511
13512 * Makefile.in (linux-btrace.o, mips-linux-watch.o): Remove
13513 explicit header dependencies and use $COMPILE/$POSTCOMPILE.
13514
7c3a12ca
PA
135152013-09-06 Pedro Alves <palves@redhat.com>
13516
13517 * linux-amd64-ipa.c: Include tracepoint.h.
13518 * linux-i386-ipa.c: Include tracepoint.h.
13519
8eb3d7b6
RW
135202013-09-06 Ricard Wanderlof <ricardw@axis.com>
13521
13522 * linux-crisv32-low.c (PTRACE_GET_THREAD_AREA): New macro.
13523 (ps_get_thread_area): New function.
13524
eddddb9d
RW
135252013-09-06 Ricard Wanderlof <ricardw@axis.com>
13526
13527 * linux-crisv32-low.c (elf_gregset_t): Delete typedef.
13528 (initialize_low_arch): Call init_registers_crisv32 rather than
13529 init_register_crisv32.
13530
533b0600
PA
135312013-09-05 Pedro Alves <palves@redhat.com>
13532
13533 * server.h (handle_vFile, hostio_last_error_from_errno): Move
13534 to ...
13535 * hostio.h: ... this new file.
13536 * hostio.c, server.c, linux-low.c, nto-low.c, spu-low,
13537 win32-low.c: Include hostio.h.
13538
0ce3d3b5
PA
135392013-09-05 Pedro Alves <palves@redhat.com>
13540
13541 * server.h (gdb_client_data, handler_func, callback_handler_func)
13542 (delete_file_handler, add_file_handler, append_callback_event)
13543 (delete_callback_event, start_event_loop, initialize_event_loop):
13544 Move to event-loop.h and include it.
13545 * event-loop.h: New file.
13546
799cdc37
PA
135472013-09-05 Pedro Alves <palves@redhat.com>
13548
13549 * dll.c, inferiors.c, remote-utils.c, server.c: Include "dll.h".
13550 * server.h (struct dll_info, all_dlls, dlls_changed, clear_dlls)
13551 (loaded_dll, unloaded_dll): Move to ...
13552 * dll.h: ... this new file.
13553 * inferiors.c, remote-utils.c, win32-low.c: Include "dll.h".
13554
6a6bbd9d
PA
135552013-09-05 Pedro Alves <palves@redhat.com>
13556
13557 * server.h (current_process, get_thread_process, all_processes)
13558 (add_inferior_to_list, for_each_inferior, current_inferior)
13559 (remove_inferior, add_process, remove_process, find_process_pid)
13560 (have_started_inferiors_p, have_attached_inferiors_p)
13561 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id)
13562 (clear_inferiors, find_inferior, find_inferior_id)
13563 (inferior_target_data, set_inferior_target_data)
13564 (inferior_regcache_data, set_inferior_regcache_data): Move to
13565 inferiors.h, and include it.
13566 * inferiors.h: New file.
13567
f699aaba
PA
135682013-09-05 Pedro Alves <palves@redhat.com>
13569
13570 * server.h (struct emit_ops, current_insn_ptr, emit_error):
13571 Move ...
72f4393d 13572 * ax.h: ... here.
f699aaba 13573
c144c7a0
PA
135742013-09-05 Pedro Alves <palves@redhat.com>
13575
13576 * ax.c, linux-low.c, linux-x86-low.c, server.c: Include
13577 tracepoint.h.
13578 * server.h (IPA_BUFSIZ, initialize_tracepoint, tracing)
13579 (disconnected_tracing, tracepoint_look_up_symbols, stop_tracing
13580 (handle_tracepoint_general_set, handle_tracepoint_query)
13581 (tracepoint_finished_step, tracepoint_was_hit)
13582 (release_while_stepping_state_list, current_traceframe)
13583 (in_readonly_region, traceframe_read_mem)
13584 (fetch_traceframe_registers, traceframe_read_sdata)
13585 (traceframe_read_info, struct fast_tpoint_collect_status)
13586 (fast_tracepoint_collecting, force_unlock_trace_buffer)
13587 (handle_tracepoit_bkpts, initialize_low_tracepoint)
13588 (supply_fast_tracepoint_registers)
13589 (supply_static_tracepoint_registers, set_trampoline_buffer_space)
13590 (ipa_tdesc, claim_trampoline_space)
13591 (have_fast_tracepoint_trampoline_buffer, gdb_agent_about_to_close)
13592 (agent_mem_read, agent_get_trace_state_variable_value)
13593 (agent_set_trace_state_variable_value, agent_tsv_read)
13594 (agent_mem_read_string, get_raw_reg_func_addr)
13595 (get_get_tsv_func_addr, get_set_tsv_func_addr): Move to ...
13596 * tracepoint.h: ... this new file.
13597
ff42e6ab
PA
135982013-09-05 Pedro Alves <palves@redhat.com>
13599
13600 * server.h (perror_with_name, error, fatal, warning, paddress)
13601 (pulongest, plongest, phex_nz, pfildes): Move to utils.h, and
13602 include it.
13603 * utils.h: New file.
13604
541af0f4
PA
136052013-09-05 Pedro Alves <palves@redhat.com>
13606
13607 * server.h (remote_debug, noack_mode, transport_is_reliable)
13608 (gdb_connected, STDIO_CONNECTION_NAME, remote_connection_is_stdio)
13609 (read_ptid, write_ptid, putpkt, putpkt_binary, putpkt_notif)
13610 (getpkt, remote_prepare, remote_open, remote_close, write_ok)
13611 (write_enn, initialize_async_io, enable_async_io)
13612 (disable_async_io, check_remote_input_interrupt_request)
13613 (convert_ascii_to_int, convert_int_to_ascii, new_thread_notify)
13614 (dead_thread_notify, prepare_resume_reply)
13615 (decode_address_to_semicolon, decode_address, decode_m_packet)
13616 (decode_M_packet, decode_X_packet, decode_xfer_write)
13617 (decode_search_memory_packet, unhexify, hexify)
13618 (remote_escape_output, unpack_varlen_hex, clear_symbol_cache)
13619 (look_up_one_symbol, relocate_instruction)
13620 (monitor_output): Move to remote-utils.h, and include it.
13621 * remote-utils.h: New file.
13622
eebdf26b
PA
136232013-09-05 Pedro Alves <palves@redhat.com>
13624
13625 * server.h (_): Delete.
13626
3aafd2ff
PA
136272013-09-02 Pedro Alves <palves@redhat.com>
13628
13629 * tracepoint.c (TRACEFRAME_EOB_MARKER_SIZE): New macro.
13630 (init_trace_buffer): Ensure at least TRACEFRAME_EOB_MARKER_SIZE is
13631 allocated.
13632 (trace_buffer_alloc): Use TRACEFRAME_EOB_MARKER_SIZE.
13633
cee83bcb
PM
136342013-09-02 Pierre Muller <muller@sourceware.org>
13635
13636 * win32-low.c (child_xfer_memory): Check if ReadProcessMemory
13637 or WriteProcessMemory complete successfully and handle
13638 ERROR_PARTIAL_COPY error.
13639
9a13b2fa
PA
136402013-09-02 Pedro Alves <palves@redhat.com>
13641
13642 * server.c (gdb_read_memory): Return -1 on traceframe memory read
13643 error instead of EIO.
13644
602e3198
JK
136452013-08-28 Jan Kratochvil <jan.kratochvil@redhat.com>
13646
13647 PR server/15604
13648 * linux-low.c: Include filestuff.h.
13649 (linux_create_inferior) <pid == 0>: Call close_most_fds.
13650 * lynx-low.c: Include filestuff.h.
13651 (lynx_create_inferior) <pid == 0>: Call close_most_fds.
13652 * server.c: Include filestuff.h.
13653 (main): Call notice_open_fds.
13654 * spu-low.c: Include filestuff.h.
13655 (spu_create_inferior) <pid == 0>: Call close_most_fds.
13656
96d7229d
LM
136572013-08-22 Luis Machado <lgustavo@codesourcery.com>
13658
13659 * Makefile.in: Explain why ../target and ../nat are not
13660 listed as include file search paths.
13661 (linux-waitpid.o): New object file rule.
13662 * configure.srv (srv_native_linux_obj): New variable.
13663 Replace all occurrences of linux native object files with
13664 $srv_native_linux_obj.
13665 * linux-low.c: Include nat/linux-nat.h and nat/linux-waitpid.h.
13666 (HAS_NOMMU): Move defining logic to common/linux-ptrace.c.
13667 (linux_enable_event_reporting): Remove declaration.
13668 (my_waitpid): Moved to common/linux-waitpid.c.
13669 (linux_wait_for_event): Pass ptid when calling
13670 linux_enable_event_reporting.
13671 (linux_supports_tracefork_flag): Remove.
13672 (linux_enable_event_reporting): Likewise.
13673 (linux_tracefork_grandchild): Remove.
13674 (STACK_SIZE): Moved to common/linux-ptrace.c.
13675 (linux_tracefork_child): Remove.
13676 (linux_test_for_tracefork): Remove.
13677 (linux_look_up_symbols): Call linux_supports_traceclone.
13678 (initialize_low): Remove call to linux_test_for_tracefork.
13679 * linux-low.h (PTRACE_TYPE_ARG3): Move to
13680 common/linux-ptrace.h.
13681 (PTRACE_TYPE_ARG4): Likewise.
13682 Include linux-ptrace.h.
13683
32940073
PA
136842013-08-21 Pedro Alves <palves@redhat.com>
13685
13686 * config.in: Renegerate.
13687
33b60d58 136882013-08-19 Luis Machado <lgustavo@codesourcery.com>
a261b8f5 13689
33b60d58
LM
13690 * Makefile.in (INCLUDE_CFLAGS): Include -I$(srcdir)/../.
13691 (SFILES): Remove $(srcdir)/common/target-common.c and
13692 add $(srcdir)/target/waitstatus.c.
13693 (OBS): Remove target-common.o and add waitstatus.o.
13694 (server_h): Remove $(srcdir)/../common/target-common.h and
13695 add $(srcdir)/../target/resume.h, $(srcdir)/../target/wait.h
13696 and $(srcdir)/../target/waitstatus.h.
13697 (target-common.o): Remove.
13698 (waitstatus.o): New target object file.
13699 * target.h: Do not include target-common.h and
13700 include target/resume.h, target/wait.h and
13701 target/waitstatus.h.
13702
b8e1b30e
LM
137032013-08-13 Luis Machado <lgustavo@codesourcery.com>
13704
13705 * linux-arm-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
13706 to PTRACE_TYPE_ARG3.
13707 * linux-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
13708 to PTRACE_TYPE_ARG3 and PTRACE_ARG4_TYPE to
13709 PTRACE_TYPE_ARG4.
13710 * linux-low.h (PTRACE_ARG3_TYPE): Rename to PTRACE_TYPE_ARG3.
13711 (PTRACE_ARG4_TYPE): Rename to PTRACE_TYPE_ARG4.
13712
7a60ad40
YQ
137132013-07-27 Jie Zhang <jie@codesourcery.com>
13714 Daniel Jacobowitz <dan@codesourcery.com>
13715 Yao Qi <yao@codesourcery.com>
13716
13717 * Makefile.in (SFILES): Add common/mips-linux-watch.c.
13718 (mips-linux-watch.o): New rule.
13719 (mips_linux_watch_h): New variable.
13720 * configure.srv <mips*-*-linux*>: Add mips-linux-watch.o to
13721 srv_tgtobj.
13722 * linux-mips-low.c: Include mips-linux-watch.h.
13723 (struct arch_process_info, struct arch_lwp_info): New.
13724 (update_watch_registers_callback): New function.
13725 (mips_linux_new_process, mips_linux_new_thread) New functions.
13726 (mips_linux_prepare_to_resume, mips_insert_point): New
13727 functions.
13728 (mips_remove_point, mips_stopped_by_watchpoint): New
13729 functions.
13730 (rsp_bp_type_to_target_hw_bp_type): New function.
13731 (mips_stopped_data_address): New function.
13732 (the_low_target): Add watchpoint support functions.
13733
de6f69ad
YQ
137342013-07-27 Yao Qi <yao@codesourcery.com>
13735
13736 * i386-low.c: Include break-common.h.
13737 (enum target_hw_bp_type): Remove.
13738
3360c0bf
LM
137392013-07-24 Luis Machado <lgustavo@codesourcery.com>
13740
13741 * Makefile.in (SFILES): /common/target-common.c.
13742 (OBS): Add target-common.o.
13743 (server_h): Add $(srcdir)/../common/target-common.h.
13744 (target-common.o): New target.
13745 * server.c (queue_stop_reply_callback): Free
13746 status string after use.
13747 * target.c (target_waitstatus_to_string): Remove.
13748 * target.h: Include target-common.h.
13749 (resume_kind): Likewise.
13750 (target_waitkind): Likewise.
13751 (target_waitstatus): Likewise.
13752 (TARGET_WNOHANG): Likewise.
13753
bd885420
YQ
137542013-07-04 Yao Qi <yao@codesourcery.com>
13755
13756 * Makefile.in (host_alias): Use @host_noncanonical@.
13757 (target_alias): Use @target_noncanonical@.
13758 * configure.ac: Use ACX_NONCANONICAL_TARGET and
13759 ACX_NONCANONICAL_HOST.
13760 * configure: Regenerated.
13761
13762 Revert:
13763 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
13764
13765 * configure.ac (version_host, version_target): Set and AC_SUBST them.
13766 * configure: Rebuild.
13767 * Makefile.in (version_host, version_target): Get from configure.
13768 (version.c): Use $(version_host) and $(version_target).
13769
17ef446e
PA
137702013-07-03 Pedro Alves <palves@redhat.com>
13771
13772 * Makefile.in (config.status): Depend on development.sh.
13773 * acinclude.m4: Include libmcheck.m4.
13774 * configure: Regenerate.
13775
7a9a7487
MG
137762013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
13777
13778 * win32-low.c (winapi_DebugActiveProcessStop): Move the WINAPI
13779 attribute inside the parentheses.
13780 (winapi_DebugSetProcessKillOnExit): Ditto.
13781 (winapi_DebugBreakProcess): Ditto.
13782 (winapi_GenerateConsoleCtrlEvent): Ditto.
a261b8f5 13783
49b64de6
MG
137842013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
13785
13786 * notif.h (notif_event): Add a dummy member to avoid compiler
13787 errors.
13788
d5749ee7
PA
137892013-07-01 Pedro Alves <palves@redhat.com>
13790
13791 * hostio.c (HOSTIO_PATH_MAX): Define.
13792 (require_filename, handle_open, handle_unlink, handle_readlink):
13793 Use it.
13794
d8d2a3ee
PA
137952013-07-01 Pedro Alves <palves@redhat.com>
13796
13797 * server.h: Include "pathmax.h".
13798 * linux-low.c: Don't include sys/param.h.
13799 (linux_pid_exe_is_elf_64_file): Use PATH_MAX instead of
13800 MAXPATHLEN.
13801 * win32-low.c: Don't include sys/param.h.
13802 (win32_create_inferior): Use PATH_MAX instead of MAXPATHLEN.
13803
bc7dea8d
PA
138042013-07-01 Pedro Alves <palves@redhat.com>
13805
13806 * event-loop.c: Don't check HAVE_UNISTD_H before including
13807 <unistd.h>.
13808 * gdbreplay.c: Likewise.
13809 * remote-utils.c: Likewise.
13810 * server.c: Likewise.
13811 * configure.ac: Don't check for unistd.h.
13812 * configure: Regenerate.
13813
d6c2da54
TT
138142013-06-28 Tom Tromey <tromey@redhat.com>
13815
13816 * Makefile.in (version.c): Use version.in, not
13817 common/version.in.
13818
257b6bec
MG
138192013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
13820
13821 * configure.ac (version_host, version_target): Set and AC_SUBST them.
13822 * configure: Rebuild.
13823 * Makefile.in (version_host, version_target): Get from configure.
13824 (version.c): Use $(version_host) and $(version_target).
13825
86ebe149
DK
138262013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
13827
13828 Fix trace-status to output user name without trailing colon.
13829 * tracepoint.c (cmd_qtstatus): Remove unnecessary colon from user name.
13830
f30aa5af
DK
138312013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
13832
13833 Fix trace-status to output proper start-time and stop-time.
13834 * tracepoint.c (cmd_qtstatus): Modify trace-status output to
13835 output start time and stop time in hex as gdb expects.
13836
28a93511
YQ
138372013-06-26 Pedro Alves <pedro@codesourcery.com>
13838
13839 * tracepoint.c (build_traceframe_info_xml): Output trace state
13840 variables present in the trace buffer.
13841
01208463
TT
138422013-06-24 Tom Tromey <tromey@redhat.com>
13843
13844 * Makefile.in (version.c): Use bfd/version.h, common/version.in,
13845 create-version.sh.
13846 (version.o): Remove.
13847 * gdbreplay.c: Include version.h.
13848 (version, host_name): Don't declare.
13849 * server.h: Include version.h.
13850 (version, host_name): Don't declare.
13851
760256f9
PA
138522013-06-12 Pedro Alves <palves@redhat.com>
13853
13854 * linux-x86-low.c (linux_is_elf64): Delete global.
13855 (x86_siginfo_fixup): Replace reference to `linux_is_elf64' global
13856 with local linux_pid_exe_is_elf_64_file use.
13857
030031ee
PA
138582013-06-11 Pedro Alves <palves@redhat.com>
13859
13860 * linux-low.c (regset_disabled, disable_regset): New functions.
13861 (regsets_fetch_inferior_registers)
13862 (regsets_store_inferior_registers): Use them.
13863 (initialize_regsets_info); Don't allocate the disabled_regsets
13864 array here.
13865 * linux-low.h (struct regsets_info) <disabled_regsets>: Extend
13866 comment.
13867
5da6eb0a
PA
138682013-06-11 Pedro Alves <palves@redhat.com>
13869
13870 * linux-low.c (initialize_regsets_info): Use xcalloc instead of
13871 xmalloc.
13872
7e5aaa09
PA
138732013-06-11 Pedro Alves <palves@redhat.com>
13874
13875 * linux-x86-low.c (initialize_low_arch): Call
13876 init_registers_x32_avx_linux.
13877
d878444c
JK
138782013-06-09 Jan Kratochvil <jan.kratochvil@redhat.com>
13879
13880 Fix compatibility with Android Bionic.
13881 * linux-low.c (linux_qxfer_libraries_svr4): Ignore first entry even if
13882 it is not empty.
13883
3aee8918
PA
138842013-06-07 Pedro Alves <palves@redhat.com>
13885
5f2b57b5 13886 PR server/14823
3aee8918
PA
13887 * Makefile.in (OBS): Add tdesc.o.
13888 (IPA_OBJS): Add tdesc-ipa.o.
13889 (tdesc-ipa.o): New rule.
13890 * ax.c (gdb_eval_agent_expr): Adjust register_size call to new
13891 interface.
13892 * linux-low.c (new_inferior): Delete.
13893 (disabled_regsets, num_regsets): Delete.
13894 (linux_add_process): Adjust to set the new per-process
13895 new_inferior flag.
13896 (linux_detach_one_lwp): Adjust to call regcache_invalidate_thread.
13897 (linux_wait_for_lwp): Adjust. Only call arch_setup if the event
13898 was a stop. When calling arch_setup, switch the current inferior
13899 to the thread that got an event.
13900 (linux_resume_one_lwp): Adjust to call regcache_invalidate_thread.
13901 (regsets_fetch_inferior_registers)
13902 (regsets_store_inferior_registers): New regsets_info parameter.
13903 Adjust to use it.
13904 (linux_register_in_regsets): New regs_info parameter. Adjust to
13905 use it.
13906 (register_addr, fetch_register, store_register): New usrregs_info
13907 parameter. Adjust to use it.
13908 (usr_fetch_inferior_registers, usr_store_inferior_registers): New
13909 parameter regs_info. Adjust to use it.
13910 (linux_fetch_registers): Get the current inferior's regs_info, and
13911 adjust to use it.
13912 (linux_store_registers): Ditto.
13913 [HAVE_LINUX_REGSETS] (initialize_regsets_info): New.
13914 (initialize_low): Don't initialize the target_regsets here. Call
13915 initialize_low_arch.
13916 * linux-low.h (target_regsets): Delete declaration.
13917 (struct regsets_info): New.
13918 (struct usrregs_info): New.
13919 (struct regs_info): New.
13920 (struct process_info_private) <new_inferior>: New field.
13921 (struct linux_target_ops): Delete the num_regs, regmap, and
13922 regset_bitmap fields. New field regs_info.
13923 [HAVE_LINUX_REGSETS] (initialize_regsets_info): Declare.
13924 * i387-fp.c (num_xmm_registers): Delete.
13925 (i387_cache_to_fsave, i387_fsave_to_cache): Adjust find_regno
13926 calls to new interface.
13927 (i387_cache_to_fxsave, i387_cache_to_xsave, i387_fxsave_to_cache)
13928 (i387_xsave_to_cache): Adjust find_regno calls to new interface.
13929 Infer the number of xmm registers from the regcache's target
13930 description.
13931 * i387-fp.h (num_xmm_registers): Delete.
13932 * inferiors.c (add_thread): Don't install the thread's regcache
13933 here.
13934 * proc-service.c (gregset_info): Fetch the current inferior's
13935 regs_info. Adjust to use it.
13936 * regcache.c: Include tdesc.h.
13937 (register_bytes, reg_defs, num_registers)
13938 (gdbserver_expedite_regs): Delete.
13939 (get_thread_regcache): If the thread doesn't have a regcache yet,
13940 create one, instead of aborting gdbserver.
13941 (regcache_invalidate_one): Rename to ...
13942 (regcache_invalidate_thread): ... this.
13943 (regcache_invalidate_one): New.
13944 (regcache_invalidate): Only invalidate registers of the current
13945 process.
13946 (init_register_cache): Add target_desc parameter, and use it.
13947 (new_register_cache): Ditto. Assert the target description has a
13948 non zero registers_size.
13949 (regcache_cpy): Add assertions. Adjust.
13950 (realloc_register_cache, set_register_cache): Delete.
13951 (registers_to_string, registers_from_string): Adjust.
13952 (find_register_by_name, find_regno, find_register_by_number)
13953 (register_cache_size): Add target_desc parameter, and use it.
13954 (free_register_cache_thread, free_register_cache_thread_one)
13955 (regcache_release, register_cache_size): New.
13956 (register_size): Add target_desc parameter, and use it.
13957 (register_data, supply_register, supply_register_zeroed)
13958 (supply_regblock, supply_register_by_name, collect_register)
13959 (collect_register_as_string, collect_register_by_name): Adjust.
13960 * regcache.h (struct target_desc): Forward declare.
13961 (struct regcache) <tdesc>: New field.
13962 (init_register_cache, new_register_cache): Add target_desc
13963 parameter.
13964 (regcache_invalidate_thread): Declare.
13965 (regcache_invalidate_one): Delete declaration.
13966 (regcache_release): Declare.
13967 (find_register_by_number, register_cache_size, register_size)
13968 (find_regno): Add target_desc parameter.
13969 (gdbserver_expedite_regs, gdbserver_xmltarget): Delete
13970 declarations.
13971 * remote-utils.c: Include tdesc.h.
13972 (outreg, prepare_resume_reply): Adjust.
13973 * server.c: Include tdesc.h.
13974 (gdbserver_xmltarget): Delete declaration.
13975 (get_features_xml, process_serial_event): Adjust.
13976 * server.h [IN_PROCESS_AGENT] (struct target_desc): Forward
13977 declare.
13978 (struct process_info) <tdesc>: New field.
13979 (ipa_tdesc): Declare.
13980 * tdesc.c: New file.
13981 * tdesc.h: New file.
13982 * tracepoint.c: Include tdesc.h.
13983 [IN_PROCESS_AGENT] (ipa_tdesc): Define.
13984 (get_context_regcache): Adjust to pass ipa_tdesc down.
13985 (do_action_at_tracepoint): Adjust to get the register cache size
13986 from the context regcache's description.
13987 (traceframe_walk_blocks): Adjust to get the register cache size
13988 from the current trace frame's description.
13989 (traceframe_get_pc): Adjust to get current trace frame's
13990 description and pass it down.
13991 (gdb_collect): Adjust to get the register cache size from the
13992 IPA's description.
13993 * linux-amd64-ipa.c (tdesc_amd64_linux): Declare.
13994 (gdbserver_xmltarget): Delete.
13995 (initialize_low_tracepoint): Set the ipa's target description.
13996 * linux-i386-ipa.c (tdesc_i386_linux): Declare.
13997 (initialize_low_tracepoint): Set the ipa's target description.
13998 * linux-x86-low.c: Include tdesc.h.
13999 [__x86_64__] (is_64bit_tdesc): New.
14000 (ps_get_thread_area, x86_get_thread_area): Use it.
14001 (i386_cannot_store_register): Rename to ...
14002 (x86_cannot_store_register): ... this. Use is_64bit_tdesc.
14003 (i386_cannot_fetch_register): Rename to ...
14004 (x86_cannot_fetch_register): ... this. Use is_64bit_tdesc.
14005 (x86_fill_gregset, x86_store_gregset): Adjust register_size calls
14006 to new interface.
14007 (target_regsets): Rename to ...
14008 (x86_regsets): ... this.
14009 (x86_get_pc, x86_set_pc): Adjust register_size calls to new
14010 interface.
14011 (x86_siginfo_fixup): Use is_64bit_tdesc.
14012 [__x86_64__] (tdesc_amd64_linux, tdesc_amd64_avx_linux)
14013 (tdesc_x32_avx_linux, tdesc_x32_linux)
14014 (tdesc_i386_linux, tdesc_i386_mmx_linux, tdesc_i386_avx_linux):
14015 Declare.
14016 (x86_linux_update_xmltarget): Delete.
14017 (I386_LINUX_XSAVE_XCR0_OFFSET): Define.
14018 (have_ptrace_getfpxregs, have_ptrace_getregset): New.
14019 (AMD64_LINUX_USER64_CS): New.
14020 (x86_linux_read_description): New, based on
14021 x86_linux_update_xmltarget.
14022 (same_process_callback): New.
14023 (x86_arch_setup_process_callback): New.
14024 (x86_linux_update_xmltarget): New.
14025 (x86_regsets_info): New.
14026 (amd64_linux_regs_info): New.
14027 (i386_linux_usrregs_info): New.
14028 (i386_linux_regs_info): New.
14029 (x86_linux_regs_info): New.
14030 (x86_arch_setup): Reimplement.
14031 (x86_install_fast_tracepoint_jump_pad): Use is_64bit_tdesc.
14032 (x86_emit_ops): Ditto.
14033 (the_low_target): Adjust. Install x86_linux_regs_info,
14034 x86_cannot_fetch_register, and x86_cannot_store_register.
14035 (initialize_low_arch): New.
14036 * linux-ia64-low.c (tdesc_ia64): Declare.
14037 (ia64_fetch_register): Adjust.
14038 (ia64_usrregs_info, regs_info): New globals.
14039 (ia64_regs_info): New function.
14040 (the_low_target): Adjust.
14041 (initialize_low_arch): New function.
14042 * linux-sparc-low.c (tdesc_sparc64): Declare.
14043 (sparc_fill_gregset_to_stack, sparc_store_gregset_from_stack):
14044 Adjust.
14045 (sparc_arch_setup): New function.
14046 (sparc_regsets_info, sparc_usrregs_info, regs_info): New globals.
14047 (the_low_target): Adjust.
14048 (initialize_low_arch): New function.
14049 * linux-ppc-low.c (tdesc_powerpc_32l, tdesc_powerpc_altivec32l)
14050 (tdesc_powerpc_cell32l, tdesc_powerpc_vsx32l)
14051 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_altivec32l)
14052 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_e500l)
14053 (tdesc_powerpc_64l, tdesc_powerpc_altivec64l)
14054 (tdesc_powerpc_cell64l, tdesc_powerpc_vsx64l)
14055 (tdesc_powerpc_isa205_64l, tdesc_powerpc_isa205_altivec64l)
14056 (tdesc_powerpc_isa205_vsx64l): Declare.
14057 (ppc_cannot_store_register, ppc_collect_ptrace_register)
14058 (ppc_supply_ptrace_register, parse_spufs_run, ppc_get_pc)
14059 (ppc_set_pc, ppc_get_hwcap): Adjust.
14060 (ppc_usrregs_info): Forward declare.
14061 (!__powerpc64__) ppc_regmap_adjusted: New global.
14062 (ppc_arch_setup): Adjust to the current process'es target
14063 description.
14064 (ppc_fill_vsxregset, ppc_store_vsxregset, ppc_fill_vrregset)
14065 (ppc_store_vrregset, ppc_fill_evrregset, ppc_store_evrregse)
14066 (ppc_store_evrregset): Adjust.
14067 (target_regsets): Rename to ...
14068 (ppc_regsets): ... this, and make static.
14069 (ppc_usrregs_info, ppc_regsets_info, regs_info): New globals.
14070 (ppc_regs_info): New function.
14071 (the_low_target): Adjust.
14072 (initialize_low_arch): New function.
14073 * linux-s390-low.c (tdesc_s390_linux32, tdesc_s390_linux32v1)
14074 (tdesc_s390_linux32v2, tdesc_s390_linux64, tdesc_s390_linux64v1)
14075 (tdesc_s390_linux64v2, tdesc_s390x_linux64, tdesc_s390x_linux64v1)
14076 (tdesc_s390x_linux64v2): Declare.
14077 (s390_collect_ptrace_register, s390_supply_ptrace_register)
14078 (s390_fill_gregset, s390_store_last_break): Adjust.
14079 (target_regsets): Rename to ...
14080 (s390_regsets): ... this, and make static.
14081 (s390_get_pc, s390_set_pc): Adjust.
14082 (s390_get_hwcap): New target_desc parameter, and use it.
14083 [__s390x__] (have_hwcap_s390_high_gprs): New global.
14084 (s390_arch_setup): Adjust to set the current process'es target
14085 description. Don't adjust the regmap.
14086 (s390_usrregs_info, s390_regsets_info, regs_info): New globals.
14087 [__s390x__] (s390_usrregs_info_3264, s390_regsets_info_3264)
14088 (regs_info_3264): New globals.
14089 (s390_regs_info): New function.
14090 (the_low_target): Adjust.
14091 (initialize_low_arch): New function.
14092 * linux-mips-low.c (tdesc_mips_linux, tdesc_mips_dsp_linux)
14093 (tdesc_mips64_linux, tdesc_mips64_dsp_linux): Declare.
14094 [__mips64] (init_registers_mips_linux)
14095 (init_registers_mips_dsp_linux): Delete defines.
14096 [__mips64] (tdesc_mips_linux, tdesc_mips_dsp_linux): New defines.
14097 (have_dsp): New global.
14098 (mips_read_description): New, based on mips_arch_setup.
14099 (mips_arch_setup): Reimplement.
14100 (get_usrregs_info): New function.
14101 (mips_cannot_fetch_register, mips_cannot_store_register)
14102 (mips_get_pc, mips_set_pc, mips_fill_gregset, mips_store_gregset)
14103 (mips_fill_fpregset, mips_store_fpregset): Adjust.
14104 (target_regsets): Rename to ...
14105 (mips_regsets): ... this, and make static.
14106 (mips_regsets_info, mips_dsp_usrregs_info, mips_usrregs_info)
14107 (dsp_regs_info, regs_info): New globals.
14108 (mips_regs_info): New function.
14109 (the_low_target): Adjust.
14110 (initialize_low_arch): New function.
14111 * linux-arm-low.c (tdesc_arm, tdesc_arm_with_iwmmxt)
14112 (tdesc_arm_with_vfpv2, tdesc_arm_with_vfpv3, tdesc_arm_with_neon):
14113 Declare.
14114 (arm_fill_vfpregset, arm_store_vfpregset): Adjust.
14115 (arm_read_description): New, with bits factored from
14116 arm_arch_setup.
14117 (arm_arch_setup): Reimplement.
14118 (target_regsets): Rename to ...
14119 (arm_regsets): ... this, and make static.
14120 (arm_regsets_info, arm_usrregs_info, regs_info): New globals.
14121 (arm_regs_info): New function.
14122 (the_low_target): Adjust.
14123 (initialize_low_arch): New function.
14124 * linux-m68k-low.c (tdesc_m68k): Declare.
14125 (target_regsets): Rename to ...
14126 (m68k_regsets): ... this, and make static.
14127 (m68k_regsets_info, m68k_usrregs_info, regs_info): New globals.
14128 (m68k_regs_info): New function.
14129 (m68k_arch_setup): New function.
14130 (the_low_target): Adjust.
14131 (initialize_low_arch): New function.
14132 * linux-sh-low.c (tdesc_sharch): Declare.
14133 (target_regsets): Rename to ...
14134 (sh_regsets): ... this, and make static.
14135 (sh_regsets_info, sh_usrregs_info, regs_info): New globals.
14136 (sh_regs_info, sh_arch_setup): New functions.
14137 (the_low_target): Adjust.
14138 (initialize_low_arch): New function.
14139 * linux-bfin-low.c (tdesc_bfin): Declare.
14140 (bfin_arch_setup): New function.
14141 (bfin_usrregs_info, regs_info): New globals.
14142 (bfin_regs_info): New function.
14143 (the_low_target): Adjust.
14144 (initialize_low_arch): New function.
14145 * linux-cris-low.c (tdesc_cris): Declare.
14146 (cris_arch_setup): New function.
14147 (cris_usrregs_info, regs_info): New globals.
14148 (cris_regs_info): New function.
14149 (the_low_target): Adjust.
14150 (initialize_low_arch): New function.
14151 * linux-cris-low.c (tdesc_crisv32): Declare.
14152 (cris_arch_setup): New function.
14153 (cris_regsets_info, cris_usrregs_info, regs_info): New globals.
14154 (cris_regs_info): New function.
14155 (the_low_target): Adjust.
14156 (initialize_low_arch): New function.
14157 * linux-m32r-low.c (tdesc_m32r): Declare.
14158 (m32r_arch_setup): New function.
14159 (m32r_usrregs_info, regs_info): New globals.
14160 (m32r_regs_info): Adjust.
14161 (initialize_low_arch): New function.
14162 * linux-tic6x-low.c (tdesc_tic6x_c64xp_linux)
14163 (tdesc_tic6x_c64x_linux, tdesc_tic6x_c62x_linux): Declare.
14164 (tic6x_usrregs_info): Forward declare.
14165 (tic6x_read_description): New function, based on ...
14166 (tic6x_arch_setup): ... this. Reimplement.
14167 (target_regsets): Rename to ...
14168 (tic6x_regsets): ... this, and make static.
14169 (tic6x_regsets_info, tic6x_usrregs_info, regs_info): New globals.
14170 (tic6x_regs_info): New function.
14171 (the_low_target): Adjust.
14172 (initialize_low_arch): New function.
14173 * linux-xtensa-low.c (tdesc_xtensa): Declare.
14174 (xtensa_fill_gregset, xtensa_store_gregset): Adjust.
14175 (target_regsets): Rename to ...
14176 (xtensa_regsets): ... this, and make static.
14177 (xtensa_regsets_info, xtensa_usrregs_info, regs_info): New
14178 globals.
14179 (xtensa_arch_setup, xtensa_regs_info): New functions.
14180 (the_low_target): Adjust.
14181 (initialize_low_arch): New function.
14182 * linux-nios2-low.c (tdesc_nios2_linux): Declare.
14183 (nios2_arch_setup): Set the current process'es tdesc.
14184 (target_regsets): Rename to ...
14185 (nios2_regsets): ... this.
14186 (nios2_regsets_info, nios2_usrregs_info, regs_info): New globals.
14187 (nios2_regs_info): New function.
14188 (the_low_target): Adjust.
14189 (initialize_low_arch): New function.
a261b8f5
PA
14190 * linux-aarch64-low.c (tdesc_aarch64): Declare.
14191 (aarch64_arch_setup): Set the current process'es tdesc.
14192 (target_regsets): Rename to ...
14193 (aarch64_regsets): ... this.
14194 (aarch64_regsets_info, aarch64_usrregs_info, regs_info): New globals.
14195 (aarch64_regs_info): New function.
14196 (the_low_target): Adjust.
14197 (initialize_low_arch): New function.
3aee8918
PA
14198 * linux-tile-low.c (tdesc_tilegx, tdesc_tilegx32): Declare
14199 globals.
14200 (target_regsets): Rename to ...
14201 (tile_regsets): ... this.
14202 (tile_regsets_info, tile_usrregs_info, regs_info): New globals.
14203 (tile_regs_info): New function.
14204 (tile_arch_setup): Set the current process'es tdesc.
14205 (the_low_target): Adjust.
14206 (initialize_low_arch): New function.
14207 * spu-low.c (tdesc_spu): Declare.
14208 (spu_create_inferior, spu_attach): Set the new process'es tdesc.
14209 * win32-arm-low.c (tdesc_arm): Declare.
14210 (arm_arch_setup): New function.
14211 (the_low_target): Install arm_arch_setup instead of
14212 init_registers_arm.
14213 * win32-i386-low.c (tdesc_i386, tdesc_amd64): Declare.
14214 (init_windows_x86): Rename to ...
14215 (i386_arch_setup): ... this. Set `win32_tdesc'.
14216 (the_low_target): Adjust.
14217 * win32-low.c (win32_tdesc): New global.
14218 (child_add_thread): Don't create the thread cache here.
14219 (do_initial_child_stuff): Set the new process'es tdesc.
14220 * win32-low.h (struct target_desc): Forward declare.
14221 (win32_tdesc): Declare.
14222 * lynx-i386-low.c (tdesc_i386): Declare global.
14223 (lynx_i386_arch_setup): Set `lynx_tdesc'.
14224 * lynx-low.c (lynx_tdesc): New global.
14225 (lynx_add_process): Set the new process'es tdesc.
14226 * lynx-low.h (struct target_desc): Forward declare.
14227 (lynx_tdesc): Declare global.
14228 * lynx-ppc-low.c (tdesc_powerpc_32): Declare global.
14229 (lynx_ppc_arch_setup): Set `lynx_tdesc'.
14230 * nto-low.c (nto_tdesc): New global.
14231 (do_attach): Set the new process'es tdesc.
14232 * nto-low.h (struct target_desc): Forward declare.
14233 (nto_tdesc): Declare.
14234 * nto-x86-low.c (tdesc_i386): Declare.
14235 (nto_x86_arch_setup): Set `nto_tdesc'.
14236
b1fbec62
GB
142372013-06-04 Gary Benson <gbenson@redhat.com>
14238
14239 * server.c (handle_query): Add "augmented-libraries-svr4-read+"
14240 to qSupported response when appropriate.
14241 (handle_qxfer_libraries_svr4): Allow qXfer:libraries-svr4:read
14242 with nonzero-length annex.
14243 * linux-low.c (linux_qxfer_libraries_svr4): Parse and handle
14244 arguments supplied in annex.
14245
d1ec4ce7
DE
142462013-05-31 Doug Evans <dje@google.com>
14247
ac44adcb 14248 PR server/15594
d1ec4ce7
DE
14249 * linux-x86-low.c (ps_get_thread_area): Properly extend address to
14250 64 bits in 64-cross-32 environment.
14251
9b25f2d3
PA
142522013-05-28 Pedro Alves <palves@redhat.com>
14253
14254 * Makefile.in (clean): Remove reference to aarch64-without-fpu.c.
14255 (aarch64-without-fpu.c): Delete rule.
14256 * configure.srv (aarch64*-*-linux*): Remove references to
14257 aarch64-without-fpu.o and aarch64-without-fpu.xml.
14258 * linux-aarch64-low.c (init_registers_aarch64_without_fpu): Remove
14259 declaration.
14260
6740dc9c
PA
142612013-05-24 Pedro Alves <palves@redhat.com>
14262
14263 * server.c (handle_v_cont) <vCont;r>: Use unpack_varlen_hex
14264 instead of strchr/decode_address. Error if the range isn't split
14265 with a ','. Don't assume there's be a ':' in the action.
14266
c2d6af84
PA
142672013-05-23 Yao Qi <yao@codesourcery.com>
14268 Pedro Alves <palves@redhat.com>
14269
14270 * linux-low.c (lwp_in_step_range): New function.
14271 (linux_wait_1): If the thread was range stepping and stopped
14272 outside the stepping range, report the stop to GDB. Otherwise,
14273 continue stepping. Add range stepping debug output.
14274 (linux_set_resume_request): Copy the step range from the resume
14275 request to the lwp.
14276 (linux_supports_range_stepping): New.
14277 (linux_target_ops) <supports_range_stepping>: Set to
14278 linux_supports_range_stepping.
14279 * linux-low.h (struct linux_target_ops)
14280 <supports_range_stepping>: New field.
14281 (struct lwp_info) <step_range_start, step_range_end>: New fields.
14282 * linux-x86-low.c (x86_supports_range_stepping): New.
14283 (the_low_target) <supports_range_stepping>: Set to
14284 x86_supports_range_stepping.
14285 * server.c (handle_v_cont): Handle 'r' action.
14286 (handle_v_requests): Append ";r" if the target supports range
14287 stepping.
14288 * target.h (struct thread_resume) <step_range_start,
14289 step_range_end>: New fields.
14290 (struct target_ops) <supports_range_stepping>:
14291 New field.
14292 (target_supports_range_stepping): New macro.
14293
58794e1a
JB
142942013-05-17 Joel Brobecker <brobecker@adacore.com>
14295
14296 * lynx-low.c (lynx_resume): Fix null_ptid/minus_one_ptid
14297 confusion in comment.
14298
d631c5a7
JB
142992013-05-17 Joel Brobecker <brobecker@adacore.com>
14300
14301 * lynx-low.c (struct process_info_private): New type.
14302 (lynx_add_process): New function.
14303 (lynx_create_inferior, lynx_attach): Replace calls to
14304 add_process by calls to lynx_add_process.
14305 (lynx_resume): If PTID is null, then try using
14306 current_process()->private->last_wait_event_ptid.
14307 Add comments.
14308 (lynx_clear_inferiors): Delete. The contents of that function
14309 has been inlined in lynx_mourn;
14310 (lynx_wait_1): Save the ptid in the process's private data.
14311 (lynx_mourn): Free the process' private data. Replace call
14312 to lynx_clear_inferiors by call to clear_inferiors.
14313
96f7a20f
YQ
143142013-05-17 Yao Qi <yao@codesourcery.com>
14315
14316 * i386-low.c (i386_length_and_rw_bits): Move the comment to
14317 the right place.
14318
db0dfaa0
LM
143192013-05-16 Luis Machado <lgustavo@codesourcery.com>
14320
14321 * linux-low.c: Move definition checks upwards for PT_TEXT_ADDR,
14322 PT_DATA_ADDR and PT_TEXT_END_ADDR. Update comments.
14323 (linux_read_offsets): Remove PT_TEXT_ADDR, PT_DATA_ADDR and
14324 PT_TEXT_END_ADDR guards. Update comments.
14325 (linux_target_op) <read_offsets>: Conditionally define to
14326 linux_read_offsets if the target is UCLIBC and if it defines
14327 PT_TEXT_ADDR, PT_DATA_ADDR and PT_TEXT_END_ADDR.
14328
68f5f838
SL
143292013-05-06 Sandra Loosemore <sandra@codesourcery.com>
14330 Andrew Jenner <andrew@codesourcery.com>
14331
14332 * Makefile.in (SFILES): Add linux-nios2-low.c.
14333 (clean): Add action to delete nios2-linux.c.
14334 (nios2-linux.c): New rule.
14335 * configure.srv: Add nios2*-*-linux*.
14336 * linux-nios2-low.c: New.
14337
1ebff1fd
HAQ
143382013-05-03 Hafiz Abid Qadeer <abidh@codesourcery.com>
14339
14340 * tracepoint.c (cmd_qtinit): Call 'stop_tracing'.
14341
f6150862
HZ
143422013-04-25 Hui Zhu <hui@codesourcery.com>
14343
14344 PR gdb/15186
f6150862
HZ
14345 * ax.c (ax_printf): Add fflush.
14346
614c279d
TT
143472013-04-22 Tom Tromey <tromey@redhat.com>
14348
14349 * Makefile.in (SFILES): Add filestuff.c.
14350 (OBS): Add filestuff.o.
14351 (filestuff.o): New target.
14352 * config.in, configure: Rebuild.
14353 * configure.ac: Check for fdwalk, pipe2.
14354
7d4e5717
PA
143552013-04-17 Pedro Alves <palves@redhat.com>
14356
14357 * configure.ac (USE_THREAD_DB): Delete variable.
14358 (if test "$srv_linux_thread_db" = "yes"): AC_DEFINE USE_THREAD_DB.
14359 Don't AC_SUBST USE_THREAD_DB.
14360 * Makefile.in (INTERNAL_CFLAGS): Remove @USE_THREAD_DB@.
14361 * config.in, configure: Regenerate.
14362
d5c93e41
PA
143632013-04-16 Pedro Alves <palves@redhat.com>
14364
14365 * linux-low.h (struct lwp_info) <thread_known>: Move under
14366 the USE_THREAD_DB #ifdef.
14367
04f5fe89
PA
143682013-04-16 Pedro Alves <palves@redhat.com>
14369
14370 * Makefile.in (INTERNAL_CFLAGS): Add @USE_THREAD_DB@.
14371 (linux-low.o): Delete rule.
14372 * linux-low.h: Always include "gdb_thread_db.h" instead of
14373 conditionally including thread_db.h.
14374 (struct lwp_info) <th>: Guard with #ifdef USE_THREAD_DB instead of
14375 HAVE_THREAD_DB_H.
14376
480b27bf
JK
143772013-04-07 Jan Kratochvil <jan.kratochvil@redhat.com>
14378
14379 * Makefile.in (install-only): Fix make install regression.
14380
43662968
JK
143812013-04-05 Jan Kratochvil <jan.kratochvil@redhat.com>
14382
14383 Convert man pages to texinfo, new gdbinit.5 texinfo page.
14384 * Makefile.in (install-only): Remove $(man1dir) and gdbserver.1
14385 installation.
14386 * gdbserver.1: Remove.
14387
3e74e146
PA
143882013-03-22 Pedro Alves <palves@redhat.com>
14389
14390 * linux-low.c (handle_extended_wait): Don't call
14391 linux_enable_event_reporting.
14392
a8347a2a
TT
143932013-03-15 Tony Theodore <tonyt@logyst.com>
14394
14395 PR build/9098:
14396 * Makefile.in (SHELL): Use @SHELL@.
14397
eeb56fa7
SDJ
143982013-03-14 Sergio Durigan Junior <sergiodj@redhat.com>
14399
14400 * tracepoint.c (cmd_qtv): Initialize `val' with zero, silencing
14401 compiler warning.
14402
4fa7e2ff
JB
144032013-03-13 Joel Brobecker <brobecker@adacore.com>
14404
14405 * linux-low.c (linux_target_ops) [!HAVE_LINUX_BTRACE]:
14406 Remove extraneous NULL element.
14407
8ddb1965
YQ
144082013-03-13 Yao Qi <yao@codesourcery.com>
14409
14410 * tracepoint.c (traceframe_read_tsv): Look for the last matched
14411 'V' block in trace frame.
14412
9accd112
MM
144132013-03-11 Markus Metzger <markus.t.metzger@intel.com>
14414
14415 * target.h (struct target_ops): Add btrace ops.
14416 (target_supports_btrace): New macro.
14417 (target_enable_btrace): New macro.
14418 (target_disable_btrace): New macro.
14419 (target_read_btrace): New macro.
14420 * gdbthread.h (struct thread_info): Add btrace field.
14421 * server.c: Include btrace-common.h.
14422 (handle_btrace_general_set): New function.
14423 (handle_btrace_enable): New function.
14424 (handle_btrace_disable): New function.
14425 (handle_general_set): Call handle_btrace_general_set.
14426 (handle_qxfer_btrace): New function.
14427 (struct qxfer qxfer_packets[]): Add btrace entry.
14428 * inferiors.c (remove_thread): Disable btrace.
14429 * linux-low: Include linux-btrace.h.
14430 (linux_low_enable_btrace): New function.
14431 (linux_low_read_btrace): New function.
14432 (linux_target_ops): Add btrace ops.
14433 * configure.srv (i[34567]86-*-linux*): Add linux-btrace.o.
14434 Add srv_linux_btrace=yes.
14435 (x86_64-*-linux*): Add linux-btrace.o.
14436 Add srv_linux_btrace=yes.
14437 * configure.ac: Define HAVE_LINUX_BTRACE.
14438 * config.in: Regenerated.
14439 * configure: Regenerated.
14440
5cc22e4c
MM
144412013-03-11 Markus Metzger <markus.t.metzger@intel.com>
14442
14443 * server.c (handle_qxfer): Preserve error message if -3 is
14444 returned.
14445 (qxfer): Document the -3 return value.
14446
7c97f91e
MM
144472013-03-11 Markus Metzger <markus.t.metzger@intel.com>
14448
14449 * Makefile.in (SFILES): Add $(srcdir)/common/linux-btrace.c.
14450 (linux_btrace_h): New variable.
14451 (linux-btrace.o): New rule.
14452
be9a119c 144532013-03-08 Stan Shebs <stan@codesourcery.com>
f6f899bf
HAQ
14454 Hafiz Abid Qadeer <abidh@codesourcery.com>
14455
14456 * tracepoint.c (trace_buffer_size): New global.
14457 (DEFAULT_TRACE_BUFFER_SIZE): New define.
14458 (init_trace_buffer): Change to one-argument function. Allocate
14459 trace buffer memory.
14460 (handle_tracepoint_general_set): Call cmd_bigqtbuffer_size to
14461 handle QTBuffer:size packet.
14462 (cmd_bigqtbuffer_size): New function.
14463 (initialize_tracepoint): Call init_trace_buffer with
14464 DEFAULT_TRACE_BUFFER_SIZE.
14465 * server.c (handle_query): Add QTBuffer:size in the
14466 supported packets.
14467
e64f7499
YQ
144682013-03-07 Yao Qi <yao@codesourcery.com>
14469
14470 * tracepoint.c (cur_action, cur_step_action): Make them unsigned.
14471 (cmd_qtfp): Initialize cur_action and cur_step_action 0 instead
14472 of -1.
14473 (cmd_qtsp): Adjust condition. Do post increment.
14474 Set cur_action and cur_step_action back to 0.
14475
f0ae6fc3
PA
144762013-03-07 Jeremy Bennett <jeremy.bennett@embecosm.com>
14477
14478 PR server/15236
14479 * linux-low.c (linux_write_memory): Return early success if LEN is
14480 zero.
14481
b5b0b0af
CV
144822013-03-05 Corinna Vinschen <vinschen@redhat.de>
14483
334ad4a8 14484 * configure.srv: Add x86_64-*-cygwin* as target.
b5b0b0af 14485
589bc927
TT
144862013-02-28 Tom Tromey <tromey@redhat.com>
14487
14488 * configure.ac: Invoke AC_SYS_LARGEFILE.
14489 * configure, config.in: Rebuild.
14490
dfe07582
CV
144912013-02-28 Corinna Vinschen <vinschen@redhat.com>
14492
14493 * win32-low.c: Throughout, fix format strings and casts of
14494 printf-like functions to avoid type related warnings on all
14495 platforms.
14496 (get_child_debug_event): Print dwDebugEventCode as hex since
14497 that's how it's usually documented.
14498
736cd585
YQ
144992013-02-28 Yao Qi <yao@codesourcery.com>
14500
14501 * tracepoint.c (cmd_qtbuffer): Call phex_nz instead of
14502 pulongest.
14503
e1f58301
JW
145042013-02-27 Jiong Wang <jiwang@tilera.com>
14505
14506 * Makefile.in (clean): Remove reg-tilegx.c, reg-tilegx32.c.
14507 (reg-tilegx32.c): New rule.
14508 * configure.srv (tilegx-*-linux*): Add reg-tilegx32.o to srv_regobj.
14509 * linux-tile-low.c (tile_arch_setup): New function. Invoke
14510 different register info initializer according to elf class.
14511 (init_registers_tilgx32): New function. The tilegx32 register info
14512 initializer.
14513 (tile_fill_gregset): Use "uint_reg_t" to represent register size.
14514 (tile_store_gregset): Likewise.
14515
d171ca78
YQ
145162013-02-27 Yao Qi <yao@codesourcery.com>
14517
14518 * server.c (process_point_options): Print debug message when
14519 debug_threads is true.
14520
282bbdf3
YQ
145212013-02-26 Yao Qi <yao@codesourcery.com>
14522
14523 * tracepoint.c (cmd_qtbuffer): Don't set '\0' in OWN_BUF.
14524
aca22551
PA
145252013-02-19 Pedro Alves <palves@redhat.com>
14526 Kai Tietz <ktietz@redhat.com>
14527
14528 PR gdb/15161
14529
14530 * server.c (handle_query) <CRC check>: Use unpack_varlen_hex
14531 instead of strtoul to extract address from packet.
14532 (process_serial_event) <'z'>: Likewise.
14533
4f3cee1c
YQ
145342013-02-18 Yao Qi <yao@codesourcery.com>
14535
14536 * linux-bfin-low.c (the_low_target): Use NULL instead of 0.
14537
8e1d55a3
PA
145382013-02-14 Pedro Alves <palves@redhat.com>
14539
14540 Plug memory leak.
14541
14542 * tracepoint.c (cmd_qtnotes): Free TRACING_USER_NAME,
14543 TRACING_NOTES and TRACING_STOP_NOTE before clobbering.
14544
458820da
PA
145452013-02-14 Pedro Alves <palves@redhat.com>
14546
14547 * tracepoint.c (cmd_qtdpsrc): Use savestring.
14548
baea0dae
PA
145492013-02-14 Pedro Alves <palves@redhat.com>
14550
14551 * tracepoint.c (save_string): Delete.
14552 (add_tracepoint_action): Use savestring instead of save_string.
14553
0b1afbb3
PA
145542013-02-12 Pedro Alves <palves@redhat.com>
14555
14556 * linux-xtensa-low.c: Ditto.
14557 * xtensa-xtregs.c: Ditto.
14558
8a4ac37e
PA
145592013-02-12 Sanimir Agovic <sanimir.agovic@intel.com>
14560
14561 * thread-db.c (thread_db_get_tls_address): NULL pointer check
14562 thread_db.
14563
148de6bb
MS
145642013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
14565
14566 * linux-aarch64-low.c (aarch64_arch_setup): Clamp
14567 aarch64_num_wp_regs and aarch64_num_bp_regs to
14568 AARCH64_HWP_MAX_NUM and AARCH64_HBP_MAX_NUM respectively.
14569
55fac6e0
MS
145702013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
14571
14572 * linux-aarch64-low.c (ps_get_thread_area): Replace
14573 PTRACE_GET_THREAD_AREA with PTRACE_GETREGSET.
14574
176eb98c
MS
145752013-02-04 Jim MacArthur <jim.macarthur@arm.com>
14576 Marcus Shawcroft <marcus.shawcroft@arm.com>
14577 Nigel Stephens <nigel.stephens@arm.com>
14578 Yufeng Zhang <yufeng.zhang@arm.com>
14579
14580 * Makefile.in (clean): Remove aarch64.c and aarch64-without-fpu.c.
14581 (aarch64.c, aarch64-without-fpu.c): New targets.
14582 * configure.srv (aarch64*-*-linux*): New.
14583 * linux-aarch64-low.c: New file.
14584
56f7af9c
MS
145852013-02-04 Marcus Shawcroft <marcus.shawcroft@arm.com>
14586
43aaf8b6 14587 * linux-low.c (handle_extended_wait, linux_create_inferior)
56f7af9c
MS
14588 (linux_attach_lwp_1, linux_kill_one_lwp, linux_attach_one_lwp)
14589 (dequeue_one_deferred_signal, linux_resume_one_thread)
14590 (fetch_register, linux_write_memory, linux_enable_event_reporting)
14591 (linux_tracefork_grandchild, linux_test_for_tracefork)
14592 (linux_read_offsets, linux_xfer_siginfo, linux_xfer_siginfo): Add
14593 PTRACE_ARG3_TYPE and PTRACE_ARG4_TYPE cast to ptrace arguments
14594 where the argument is 0.
14595
60f662b0
YQ
145962013-01-25 Yao Qi <yao@codesourcery.com>
14597
14598 * event-loop.c: Include "queue.h".
14599 (gdb_event_p): New typedef.
14600 (struct gdb_event) <next_event>: Remove.
14601 (event_queue): Change to QUEUE(gdb_event_p).
14602 (async_queue_event): Remove.
14603 (gdb_event_xfree): New.
14604 (initialize_event_loop): New.
14605 (process_event): Use API from QUEUE.
14606 (wait_for_event): Likewise.
14607 * server.c (main): Call initialize_event_loop.
14608 * server.h (initialize_event_loop): Declare.
14609
5ae4861a
YQ
146102013-01-18 Yao Qi <yao@codesourcery.com>
14611
14612 * ax.h (struct eval_agent_expr_context): New.
14613 (gdb_eval_agent_expr): Update declaration.
14614 * ax.c (gdb_eval_agent_expr): Remove argument REGCACHE and
14615 TFRAME. Add new argument CTX.
14616 * server.h (struct eval_agent_expr_context): Declare.
14617 (agent_mem_read, agent_tsv_read): Update declaration.
14618 (agent_mem_read_string): Likewise.
14619 * tracepoint.c (eval_tracepoint_agent_expr): Remove.
14620 (add_traceframe_block): Add new argument TPOINT.
14621 Increase TPOINT->traceframe_usage.
14622 (do_action_at_tracepoint): Call gdb_eval_agent_expr instead of
14623 eval_tracepoint_agent_expr.
14624 (condition_true_at_tracepoint): Likewise.
14625 (agent_mem_read): Remove argument TFRAME. Add argument CTX.
14626 (agent_mem_read_string, agent_tsv_read): Likewise.
14627
85e00e85
YQ
146282013-01-16 Yao Qi <yao@codesourcery.com>
14629
14630 * linux-low.c (linux_resume_one_lwp): Don't check
14631 'lwp->bp_reinsert != 0'.
14632
4039cf45
JB
146332013-01-07 Joel Brobecker <brobecker@adacore.com>
14634 Pedro Alves <palves@redhat.com>
14635
14636 * lynx-low.c (ptrace_request_to_str): Define a temporary
14637 macro and use it to simplify this function's implementation.
14638
9044dee2
JB
146392013-01-07 Joel Brobecker <brobecker@adacore.com>
14640
14641 * lynx-low.c (lynx_resume): Call perror_with_name if lynx_ptrace
14642 sets errno.
14643
e6352c8f
JB
146442013-01-07 Joel Brobecker <brobecker@adacore.com>
14645
14646 * configure.srv (i[34567]86-*-lynxos*): Set srv_xmlfiles.
14647
50681a27
JB
146482013-01-07 Joel Brobecker <brobecker@adacore.com>
14649
14650 * configure.srv (powerpc-*-lynxos*): Set srv_xmlfiles.
14651
3f6e77ef
JB
146522013-01-07 Joel Brobecker <brobecker@adacore.com>
14653
14654 * lynx-low.c (lynx_resume): Use the resume_info parameter
14655 to determine the ptid for the lynx_ptrace call, unless
14656 it is equal to minus_one_ptid, in which case we use the
14657 ptid of the current_inferior.
14658 (lynx_wait_1): After having received a thread create/exit
14659 event, resume the inferior's execution using the signaling
14660 thread's ptid, rather than the old ptid.
14661
7fda33ae
JB
146622013-01-07 Joel Brobecker <brobecker@adacore.com>
14663
14664 * lynx-low.c (lynx_resume): Delete variable ret.
14665
b9786c74
JB
146662013-01-01 Joel Brobecker <brobecker@adacore.com>
14667
14668 * gdbreplay.c (gdbreplay_version): Update copyright year.
14669 * server.c (gdbserver_version): Likewise.
14670
8b93d60f
JB
146712012-12-17 Joel Brobecker <brobecker@adacore.com>
14672
14673 * lynx-low.c (lynx_wait_1): Add debug trace before adding
14674 new thread.
14675
037335a7
JB
146762012-12-17 Joel Brobecker <brobecker@adacore.com>
14677
14678 * lynx-low.c (ptrace_request_to_str): Add handling for
14679 PTRACE_GETTRACESIG.
14680
52d4cbd8
JB
146812012-12-17 Joel Brobecker <brobecker@adacore.com>
14682
14683 * lynx-low.c (lynx_attach): Delete variable new_process.
14684
ab8f6ca9
JB
146852012-12-17 Joel Brobecker <brobecker@adacore.com>
14686
14687 * lynx-low.c (lynx_create_inferior): Delete variable
14688 new_process.
14689
78cbc024
JB
146902012-12-17 Joel Brobecker <brobecker@adacore.com>
14691
14692 * lynx-low.c (ptrace_request_to_str): Do not handle
14693 PTRACE_GETTHREADLIST if this macro does not exist.
14694
14a00470
YQ
146952012-12-15 Yao Qi <yao@codesourcery.com>
14696
14697 * Makefile.in (OBS): Add notif.o.
14698 * notif.c, notif.h: New.
14699 * server.c: Include "notif.h".
14700 (struct vstop_notif) <next>: Remove.
14701 <base>: New field.
14702 (queue_stop_reply): Update.
14703 (push_event, send_next_stop_reply): Remove.
14704 (discard_queued_stop_replies): Update.
14705 (notif_stop): New variable.
14706 (handle_v_stopped): Remove.
14707 (handle_v_requests): Don't call handle_v_stopped. Call
14708 handle_ack_notif instead.
14709 (queue_stop_reply_callback): Call notif_event_enque instead
14710 of queue_stop_reply.
14711 (handle_status): Don't call send_next_stop_reply, call
14712 notif_write_event instead.
14713 (kill_inferior_callback): Likewise.
14714 (detach_or_kill_inferior_callback): Likewise.
14715 (main): Call initialize_notif.
14716 (process_serial_event): Call QUEUE_is_empty.
14717 (handle_target_event): Call notif_push instead of push event.
14718 * server.h (push_event): Remove declaration.
14719
61c125b9
TT
147202012-12-10 Tom Tromey <tromey@redhat.com>
14721
14722 * Makefile.in (DEPMODE, DEPDIR, depcomp, COMPILE.pre)
14723 (COMPILE.post, COMPILE, POSTCOMPILE, IPAGENT_COMPILE): New
14724 macros.
14725 (.c.o): Rewrite.
14726 (ax-ipa.o, tracepoint-ipa.o, utils-ipa.o, format-ipa.o)
14727 (common-utils-ipa.o, remote-utils-ipa.o, regcache-ipa.o)
14728 (i386-linux-ipa.o, linux-i386-ipa.o, linux-amd64-ipa.o)
14729 (amd64-linux-ipa.o, ax.o): Rewrite.
14730 (event-loop.o, hostio.o, hostio-errno.o, inferiors.o, mem-break.o)
14731 (proc-service.o, regcache.o, remote-utils.o, server.o, target.o)
14732 (thread-db.o, tracepoint.o, utils.o, gdbreplay.o, dll.o): Remove.
14733 (signals.o, linux-procfs.o, linux-ptrace.o, common-utils.o, vec.o)
14734 (gdb_vecs.o, xml-utils.o, linux-osdata.o, ptid.o, buffer.o)
14735 (format.o, agent.o, vasprintf.o, vsnprintf.o): Rewrite.
14736 (i386-low.o, i387-fp.o, linux-low.o, linux-arm-low.o)
14737 (linux-bfin-low.o, linux-cris-low.o, linux-crisv32-low.o)
14738 (linux-ia64-low.o, linux-m32r-low.o, linux-mips-low.o)
14739 (linux-ppc-low.o, linux-s390-low.o, linux-sh-low.o)
14740 (linux-tic6x-low.o, linux-x86-low.o, linux-xtensa-low.o)
14741 (linux-tile-low.o, lynx-low.o, lynx-ppc-low.o, nto-low.o)
14742 (nto-x86-low.o, linux-low.o, win32-low.o, win32-arm-low.o)
14743 (win32-i386-low.o, spu-low.o, reg-arm.o, arm-with-iwmmxt.o)
14744 (arm-with-vfpv2.o, arm-with-vfpv3.o, arm-with-neon.o, reg-bfin.o)
14745 (reg-cris.o, reg-crisv32.o, i386.o, i386-linux.o, i386-avx.o)
14746 (i386-avx-linux.o, i386-mmx.o, i386-mmx-linux.o, reg-ia64.o)
14747 (reg-m32r.o, reg-m68k.o, reg-cf.o, mips-linux.o, mips-dsp-linux.o)
14748 (mips64-linux.o, mips64-dsp-linux.o, powerpc-32.o, powerpc-32l.o)
14749 (powerpc-altivec32l.o, powerpc-cell32l.o, powerpc-vsx32l.o)
14750 (powerpc-isa205-32l.o, powerpc-isa205-altivec32l.o)
14751 (powerpc-isa205-vsx32l.o, powerpc-e500l.o, powerpc-64l.o)
14752 (powerpc-altivec64l.o, powerpc-cell64l.o, powerpc-vsx64l.o)
14753 (powerpc-isa205-64l.o, powerpc-isa205-altivec64l.o)
14754 (powerpc-isa205-vsx64l.o, s390-linux32.o, s390-linux32v1.o)
14755 (s390-linux32v2.o, s390-linux64.o, s390-linux64v1.o)
14756 (s390-linux64v2.o, s390x-linux64.o, s390x-linux64v1.o)
14757 (s390x-linux64v2.o, tic6x-c64xp-linux.o, tic6x-c64x-linux.o)
14758 (tic6x-c62x-linux.o, reg-sh.o, reg-sparc64.o, reg-spu.o, amd64.o)
14759 (amd64-linux.o, amd64-avx.o, amd64-avx-linux.o, x32.o)
14760 (x32-linux.o, x32-avx.o, x32-avx-linux.o, reg-xtensa.o)
14761 (reg-tilegx.o): Remove.
14762 (all_object_files): New macro.
14763 Include .deps files.
14764 * aclocal.m4, configure: Rebuild.
14765 * acinclude.m4: Include depstand.m4, lead-dot.m4.
14766 * configure.ac: Invoke ZW_CREATE_DEPDIR,
14767 ZW_PROG_COMPILER_DEPENDENCIES. Compute GMAKE condition.
14768
e90e9ad9
TT
147692012-12-05 Tom Tromey <tromey@redhat.com>
14770
14771 PR gdb/14917:
14772 * server.h (current_insn_ptr, emit_error): Declare 'extern'.
14773
02d403bf 147742012-11-28 Markus Metzger <markus.t.metzger@intel.com>
945bf713
MM
14775
14776 * configure.ac: Check for linux/perf_event.h.
14777 * config.in: Regenerated.
14778 * configure: Regenerated.
14779
0270a750
PA
147802012-11-26 Maxime Villard <rustyBSD@gmx.fr>
14781
14782 * hostio.c (handle_readlink): Decrease buffer size
14783 parameter passed to readlink by one byte.
14784
8c29b58e
YQ
147852012-11-26 Yao Qi <yao@codesourcery.com>
14786
14787 * configure.ac (build_warnings): Append '-Wempty-body'.
14788 * configure: Regenerated.
14789 * linux-low.c (linux_create_inferior): Use braces for empty 'if'
14790 body.
14791
8bdce1ff
PM
147922012-11-15 Pierre Muller <muller@sourceware.org>
14793
14794 * configure.ac (AC_CHECK_HEADERS): Add wait.h header.
14795 * config.in: Regenerate.
14796 * configure: Regenerate.
14797 * linux-low.c: Use "gdb_stat.h" header instead of <sys/stat.h> header.
14798 Use "gdb_wait.h" header instead of <sys/wait.h> header.
14799 * lynx-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
14800 * remote-utils.c: Use "gdb_stat.h" header instead of <sys/stat.h>
14801 header.
14802 * server.c: Remove HAVE_WAIT_H conditional. Use "gdb_wait.h" header
14803 instead of <sys/wait.h> header.
14804 * spu-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
14805
02d403bf 148062012-11-13 Markus Metzger <markus.t.metzger@intel.com>
3ba6ad0f
MM
14807
14808 * Makefile.in: (INTERNAL_CFLAGS): Add -DGDBSERVER
14809 (various make rules): Remove -DGDBSERVER
14810
fbd5db48
YQ
148112012-11-09 Yao Qi <yao@codesourcery.com>
14812
14813 * spu-low.c (current_ptid): Move it to ..
14814 * gdbthread.h: ... here. New.
14815 * remote-utils.c (read_ptid): Use macro 'current_ptid'.
14816 * server.c (myresume, process_serial_event): Likewise.
14817 * thread-db.c (thread_db_find_new_threads): Likewise.
14818 * tracepoint.c (run_inferior_command): Likewise.
14819
b3dc46ff
AB
148202012-10-01 Andrew Burgess <aburgess@broadcom.com>
14821
14822 * server.c (handle_search_memory_1): Include access length in
14823 warning message.
14824
07c04788
HPN
148252012-09-05 Michael Brandt <michael.brandt@axis.com>
14826
14827 * linux-crisv32-low.c: Fix compile errors.
14828
918d227b
YQ
148292012-09-04 Yao Qi <yao@codesourcery.com>
14830
14831 * tracepoint.c (cmd_qtsv): Adjust debug message.
14832 Don't check CUR_TPOINT.
14833
18c1b81a
YQ
148342012-08-28 Yao Qi <yao@codesourcery.com>
14835
14836 * ax.c, tracepoint.c: Replace ATTR_FORMAT with ATTRIBUTE_PRINTF.
14837 * server.h: Include 'libiberty.h' and 'ansidecl.h'.
14838 (ATTR_NORETURN, ATTR_FORMAT, ATTR_MALLOC): Remove.
14839 Remove declarations of xmalloc, xreallloc, xstrdup and
14840 freeargv.
14841 * Makefile.in (libiberty_h): New.
14842 (server_h): Append dependencies 'libiberty.h' and 'ansidecl.h'.
14843 (linux-bfin-low.o): Append dependency 'libiberty.h'.
14844
dc82f37b
YQ
148452012-08-23 Yao Qi <yao@codesourcery.com>
14846
14847 * server.h: Remove declaration of 'xsnprintf'.
14848
406b1477
KS
148492012-08-22 Keith Seitz <keiths@redhat.com>
14850
14851 * server.h: Include build-gnulib-gbserver/config.h.
14852 * gdbreplay.c: Likewise.
14853
e6712ff1
DE
148542012-08-08 Doug Evans <dje@google.com>
14855
14856 * Makefile.in (SFILES): Add gdb_vecs.c.
14857 (OBS): Add gdb_vecs.o.
14858 (gdb_vecs_h, host_defs_h): New variables.
14859 (thread-db.o): Add $(gdb_vecs_h) dependency.
14860 (gdb_vecs.o): New rule.
14861 * thread-db.c: #include "gdb_vecs.h".
14862 (thread_db_load_search): Use a vector to iterate over path elements.
14863 Handle text appearing after "$pdir".
14864
14865 * configure.ac: Add check for strstr.
14866 * config.in: Regenerate.
14867 * configure: Regenerate.
14868
7c3270ae
UW
148692012-08-02 Ulrich Weigand <ulrich.weigand@linaro.org>
14870
14871 * hostio.c (handle_pread): If pread fails, fall back to attempting
14872 lseek/read.
14873 (handle_pwrite): Likewise for pwrite.
14874
b62e2b27
UW
148752012-08-01 Ulrich Weigand <ulrich.weigand@linaro.org>
14876
14877 * linux-arm-low.c (arm_linux_hw_point_initialize): Distinguish
14878 between unsupported TYPE and unimplementable ADDR/LEN combination.
14879 (arm_insert_point): Act on new return value.
14880
78a99e91
PA
148812012-07-31 Pedro Alves <palves@redhat.com>
14882
14883 * server.c (process_point_options): Only skip tokens if we find
14884 one that is unrecognized. Don't treat 'X' specially while
14885 skipping unrecognized tokens.
14886
fcf303ab
UW
148872012-07-30 Ulrich Weigand <ulrich.weigand@linaro.org>
14888
14889 * linux-arm-low.c (arm_linux_hw_point_initialize): Do not attempt
14890 to 4-byte-align HW breakpoint addresses for Thumb.
14891
7255706c
YQ
148922012-07-27 Yao Qi <yao@codesourcery.com>
14893
14894 PR remote/14161.
14895
14896 * server.h: Declare gdb_agent_about_to_close.
14897 * target.c (kill_inferior): Include "agent.h".
14898 New. Send command 'kill'.
14899 * target.h (kill_inferior): Removed macro.
14900 * tracepoint.c (gdb_agent_about_to_close): New.
14901 (gdb_agent_helper_thread): Handle command 'close'.
14902 Wait endlessly until the inferior stops.
14903 Install gdb_agent_remove_socket to atexit hook.
14904 (agent_socket_name): New static variable.
14905 (gdb_agent_socket_init): Replace local variable 'name' with
14906 'agent_socket_name'.
14907 (gdb_agent_remove_socket): New.
14908
5a3f286f
YQ
149092012-07-27 Yao Qi <yao@codesourcery.com>
14910
14911 * server.c (process_point_options): Stop at 'X' when parsing.
14912
961bd387
ME
149132012-07-19 Michael Eager <eager@eagercon.com>
14914
a261b8f5 14915 * i386-low.c (Z_packet_to_hw_type): Add Z_PACKET_HW_BP, translate
961bd387
ME
14916 to hw_execute.
14917 * linux-x86-low.c (x86_insert_point, x86_remove_point):
14918 Call i386_low_insert_watchpoint, i386_low_remove_watchpoint to add/del
14919 hardware breakpoint.
14920
aa7c7447
JK
149212012-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
14922
14923 * gdbserver/linux-low.c (initialize_low): Call
14924 linux_ptrace_init_warnings.
14925
7f216e7c
DE
149262012-07-02 Doug Evans <dje@google.com>
14927
14928 * mem-break.c (gdb_no_commands_at_breakpoint): Fix cast from
14929 pointer to int.
14930
d3ce09f5
SS
149312012-07-02 Stan Shebs <stan@codesourcery.com>
14932
14933 * Makefile.in (WARN_CFLAGS_NO_FORMAT): Define.
14934 (ax.o): Add it to build rule.
14935 (ax-ipa.o): Ditto.
14936 (OBS): Add format.o.
14937 (IPA_OBS): Add format.o.
14938 * server.c (handle_query): Claim support for breakpoint commands.
14939 (process_point_options): Add command case.
14940 (process_serial_event): Leave running if there are printfs in
14941 effect.
14942 * mem-break.h (any_persistent_commands): Declare.
14943 (add_breakpoint_commands): Declare.
14944 (gdb_no_commands_at_breakpoint): Declare.
14945 (run_breakpoint_commands): Declare.
14946 * mem-break.c (struct point_command_list): New struct.
14947 (struct breakpoint): New field command_list.
14948 (any_persistent_commands): New function.
14949 (add_commands_to_breakpoint): New function.
14950 (add_breakpoint_commands): New function.
14951 (gdb_no_commands_at_breakpoint): New function.
14952 (run_breakpoint_commands): New function.
14953 * linux-low.c (linux_wait_1): Test for and run breakpoint commands
14954 locally.
14955 * ax.c: Include format.h.
14956 (ax_printf): New function.
14957 (gdb_eval_agent_expr): Add printf opcode.
14958
2f8f6aed
YQ
149592012-06-13 Yao Qi <yao@codesourcery.com>
14960
14961 * server.c (start_inferior): Remove duplicated writes to fields
14962 'last_resume_kind' and 'last_status' of 'current_inferior'.
14963
0c9070b3
YQ
149642012-06-12 Yao Qi <yao@codesourcery.com>
14965 Pedro Alves <palves@redhat.com>
14966
14967 * linux-low.c (linux_set_resume_request): Simplify predicate. Add
14968 comment.
14969 * server.c (handle_v_cont): Extend comment.
14970
c52daf70
YQ
149712012-06-11 Yao Qi <yao@codesourcery.com>
14972
14973 * linux-low.c (linux_attach): Add 'static'.
14974
d38bbb0a
YQ
149752012-06-06 Yao Qi <yao@codesourcery.com>
14976
14977 * ax.c (gdb_eval_agent_expr): Print `top' in hex.
14978
89dc0afd
JK
149792012-06-01 Jan Kratochvil <jan.kratochvil@redhat.com>
14980
14981 Fix gcc -flto compilation warning.
14982 * server.c (main): Make variable multi_mode and attach volatile.
14983
75f62ce7
TJB
149842012-05-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
14985
14986 * linux-low.c (get_r_debug): Disable code using DT_MIPS_RLD_MAP
14987 if the platform doesn't know about it.
14988
65f479b6
PA
149892012-05-30 Jeff Kenton <jkenton@tilera.com>
14990
14991 * Makefile.in (SFILES): Add linux-tile-low.c.
14992 (linux-tile-low.o, reg-tilegx.o, reg-tilegx.c): New rules.
14993 * configure.srv: Handle tilegx-*-linux*.
14994 * linux-tile-low.c: New file.
14995
0c5bf5a9
JK
149962012-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
14997
14998 * linux-low.c (linux_qxfer_libraries_svr4): Return -1 if R_DEBUG is -1.
14999
a493e3e2
PA
150002012-05-24 Pedro Alves <palves@redhat.com>
15001
15002 PR gdb/7205
15003
43aaf8b6 15004 Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.
a493e3e2 15005
2ea28649
PA
150062012-05-24 Pedro Alves <palves@redhat.com>
15007
15008 PR gdb/7205
15009
15010 Replace target_signal with gdb_signal throughout.
15011
8d409d16
MR
150122012-05-22 Maciej W. Rozycki <macro@codesourcery.com>
15013
15014 * linux-low.c (linux_store_registers): Avoid the copying sequence
15015 when no data has been retrieved by ptrace.
15016
23512c01
MGD
150172012-05-22 Will Deacon <will.deacon@arm.com>
15018
15019 * linux-low (__UCLIBC__ && !(__UCLIBC_HAS_MMU__ || __ARCH_HAS_MMU__)):
15020 Include asm/ptrace.h.
15021 (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define only if not
15022 already defined.
15023
4934b29e
MR
150242012-05-21 Maciej W. Rozycki <macro@codesourcery.com>
15025
15026 * linux-low.c (linux_store_registers): Don't re-retrieve data
15027 with ptrace that has already been obtained from /proc. Always
15028 copy any data retrieved with ptrace to the buffer supplied.
15029
bde24c0a
PA
150302012-05-11 Yao Qi <yao@codesourcery.com>
15031 Pedro Alves <palves@redhat.com>
15032
15033 * linux-low.c (enum stopping_threads_kind): New.
15034 (stopping_threads): Change type to `enum stopping_threads_kind'.
15035 (handle_extended_wait): If stopping and suspending threads, leave
15036 the new_lwp suspended too.
15037 (linux_wait_for_event): Adjust.
15038 (stop_all_lwps): Set `stopping_threads' to
15039 STOPPING_AND_SUSPENDING_THREADS or STOPPING_THREADS depending on
15040 whether we're suspending threads or just stopping them. Assert no
15041 recursion happens.
15042
623b6bdf
YQ
150432012-04-29 Yao Qi <yao@codesourcery.com>
15044
15045 * server.h: Move some code to ...
15046 * gdbthread.h: ... here. New.
15047 * Makefile.in (inferiors.o, regcache.o): Depends on gdbthread.h
15048 (remote-utils.o, server.o, target.o tracepoint.o): Likewise.
15049 (nto-low.o, win32-low.o): Likewise.
15050 * inferiors.c, linux-low.h, nto-low.c: Include gdbthread.h.
15051 * regcache.c, remote-utils.c, server.c: Likewise.
15052 * target.c, tracepoint.c, win32-low.c: Likewise.
15053
f15f9948
TJB
150542012-04-24 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
15055
15056 * linux-low.h (PTRACE_ARG3_TYPE): Move macro from linux-low.c.
15057 (PTRACE_ARG4_TYPE): Likewise.
15058 (PTRACE_XFER_TYPE): Likewise.
15059 * linux-arm-low.c (arm_prepare_to_resume): Cast third argument of
15060 ptrace to PTRACE_ARG3_TYPE.
15061 * linux-low.c (PTRACE_ARG3_TYPE): Move macro to linux-low.h.
15062 (PTRACE_ARG4_TYPE): Likewise.
15063 (PTRACE_XFER_TYPE): Likewise.
15064 (linux_detach_one_lwp): Cast fourth argument of
15065 ptrace to long then PTRACE_ARG4_TYPE.
15066 (regsets_fetch_inferior_registers): Cast third argument of
15067 ptrace to long then PTRACE_ARG3_TYPE.
15068 (regsets_store_inferior_registers): Likewise.
15069
38ea300a
PA
150702012-04-20 Pedro Alves <palves@redhat.com>
15071
15072 * configure: Regenerate.
15073
c971b7fa
PA
150742012-04-19 Pedro Alves <palves@redhat.com>
15075
43aaf8b6 15076 * Makefile.in (GNULIB_BUILDDIR): New.
c971b7fa 15077 (LIBGNU, INCGNU, GNULIB_H): Adjust.
43aaf8b6
PA
15078 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): New.
15079 (all, install-only, uninstall, clean-info, all-lib, clean): No
15080 longer pass GNULIB_FLAGS_TO_PASS. Use subdir_do.
15081 (maintainer-clean realclean distclean): Use subdir_do.
15082 (subdir_do): New.
15083 (gnulib/import/Makefile): Adjust. Replace gnulib/import with
c971b7fa 15084 $(GNULIB_BUILDDIR). Don't pass argument to config.status.
43aaf8b6
PA
15085 * acinclude.m4: Include acx_configure_dir.m4.
15086 * configure.ac: Remove gl_EARLY, gl_INIT, and AM_INIT_AUTOMAKE
15087 calls. Call AC_PROG_RANLIB. Configure gnulib using
15088 ACX_CONFIGURE_DIR.
15089 (GNULIB): New.
15090 (GNULIB_STDINT_H): Adjust.
15091 (AC_OUTPUT): Don't output gnulib/Makefile anymore.
15092 * gdbreplay.c: Include build-gnulib/config.h.
15093 * server.h: Likewise.
15094 * aclocal.m4: Regenerate.
15095 * config.in: Regenerate.
15096 * configure: Regenerate.
c971b7fa 15097
809277f8
PA
150982012-04-19 Pedro Alves <palves@redhat.com>
15099
15100 * Makefile.in (LIBGNU, INCGNU): Adjust.
15101 (GNULIB_FLAGS_TO_PASS, GNULIB_H): Adjust.
15102 (all, install-only, uninstall, clean-info, all-lib, clean)
15103 (maintainer-clean, Makefile, gnulib/Makefile): Adjust.
15104 * configure.ac: Adjust AC_OUTPUT output.
15105 * aclocal.m4: Regenerate.
15106 * configure: Regenerate.
15107
fd9bb8b8
PA
151082012-04-19 Pedro Alves <palves@redhat.com>
15109
15110 * Makefile.in (generated_files): New.
15111 (server_h): Remove the explicit dependency on config.h, and depend
15112 on $generated_files.
15113
1c298c66
PA
151142012-04-19 Pedro Alves <palves@redhat.com>
15115
15116 * Makefile.in (INCGNU): Add -Ignulib.
15117
57c4b50b
PA
151182012-04-19 Pedro Alves <palves@redhat.com>
15119
15120 * Makefile.in (GNULIB_INCLUDE_DIR): Rename to ...
15121 (INCGNU): ... this, and spell out -I here.
15122 (GNULIB_LIB): Rename to ...
15123 (LIBGNU): ... this.
15124 (INCLUDE_CFLAGS, gdbserver$(EXEEXT), $(GNULIB_LIB) rule): Adjust.
15125
1030e047
PA
151262012-04-19 Pedro Alves <palves@redhat.com>
15127
15128 * config.in: Regenerate.
15129
447d4319
PA
151302012-04-19 Pedro Alves <palves@redhat.com>
15131
15132 * configure.ac: Remove AC_CHECK_DECLS check for memmem.
15133 * server.h (memmem): Remove declaration.
15134 * config.in: Regenerate.
15135 * configure: Regenerate.
15136
aad9eab9
YQ
151372012-04-19 Yao Qi <yao@codesourcery.com>
15138
15139 * Makefile.in (SFILES): Add common/vec.c.
15140 (OBS): Add vec.o.
15141 (vec.o): New rule.
15142
3e10640f
YQ
151432012-04-19 Yao Qi <yao@codesourcery.com>
15144
15145 * remote-utils.c (prepare_resume_reply): Replace with macro
15146 target_core_of_thread.
15147 * server.c (handle_qxfer_threads_proper): Likewise.
15148 * target.h (traget_core_of_thread): New macro.
15149
71622373
PA
151502012-04-18 Pedro Alves <palves@redhat.com>
15151
15152 * aclocal.m4: Regenerate.
15153 * configure: Regenerate.
15154
80d26939
YQ
151552012-04-16 Yao Qi <yao@codesourcery.com>
15156
15157 * tracepoint.c (cmd_qtstart): Download tracepoints even when they are
15158 duplicated on address.
15159
42476b70
YQ
151602012-04-16 Yao Qi <yao@codesourcery.com>
15161
15162 * tracepoint.c (COPY_FIELD_TO_BUF): New macro.
15163 (struct tracepoint_action_ops) <send>: New field.
15164 (m_tracepoint_action_send, r_tracepoint_action_send): New.
15165 (agent_expr_send, x_tracepoint_action_send): New.
15166 (l_tracepoint_action_send): New.
15167 (cmd_qtdp): Download and install tracepoint
15168 according to `use_agent'.
15169 (run_inferior_command): Add one more parameter `len'.
15170 Update callers.
15171 (tracepoint_send_agent): New.
15172 (cmd_qtdp, cmd_qtstart): Call tracepoint_send_agent.
15173
7bc83639
YQ
151742012-04-16 Yao Qi <yao@codesourcery.com>
15175
15176 * tracepoint.c (download_tracepoints): Moved to ...
15177 (cmd_qtstart): ... here.
15178
5f18041e
YQ
151792012-04-14 Yao Qi <yao@codesourcery.com>
15180
15181 * tracepoint.c: Include inttypes.h.
15182 (struct collect_memory_action): Use sized types.
15183 (struct tracepoint): Likewise.
15184 (cmd_qtdp, stop_tracing): Update print specifiers.
15185 (cmd_qtp, response_tracepoint): Likewise.
15186 (collect_data_at_tracepoint): Likewise.
15187 (collect_data_at_step): Likewise.
15188
55a8c076
YQ
151892012-04-14 Yao Qi <yao@codesourcery.com>
15190
15191 Import gnulib module inttypes.
15192 * aclocal.m4, config.in, configure: Regenerated.
15193
dc750257
YQ
151942012-04-14 Yao Qi <yao@codesourcery.com>
15195
15196 * Makefile.in (maintainer-clean, realclean, distclean): Remove
15197 Makefile and config.status at last.
15198
0ab5faf9
YQ
151992012-04-13 Yao Qi <yao@codesourcery.com>
15200
15201 * tracepoint.c: Include stdint.h unconditionally.
15202
18f5fd81
TJB
152032012-04-13 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
15204
15205 * acinclude.m4 (GDBSERVER_HAVE_THREAD_DB_TYPE): New macro based
15206 on BFD_HAVE_SYS_PROCFS_TYPE.
15207 * configure.ac: Look for lwpid_t and psaddr_t in libthread_db.h.
15208 * configure: Regenerate.
15209 * config.in: Likewise.
15210
4d47af5c
L
152112012-04-13 H.J. Lu <hongjiu.lu@intel.com>
15212
15213 * Makefile.in (clean): Also remove x32.c x32-linux.c
15214 x32-avx.c x32-avx-linux.c.
15215 (x32.o): New target.
15216 (x32.c): Likewise.
15217 (x32-linux.o): Likewise.
15218 (x32-linux.c): Likewise.
15219 (x32-avx.o): Likewise.
15220 (x32-avx.c): Likewise.
15221 (x32-avx-linux.o): Likewise.
15222 (x32-avx-linux.c): Likewise.
15223
15224 * configure.srv (srv_amd64_regobj): Add x32.o x32-avx.o.
15225 (srv_amd64_linux_regobj): Add x32-linux.o x32-avx-linux.o.
15226 (srv_i386_64bit_xmlfiles): Add i386/x32-core.xml.
15227 (srv_amd64_xmlfiles): Add i386/x32.xml i386/x32-avx.xml.
15228 (srv_amd64_linux_xmlfiles): Add i386/x32-linux.xml
15229 i386/x32-avx-linux.xml.
15230
15231 * linux-x86-low.c (init_registers_x32_linux): New prototype.
15232 (init_registers_x32_avx_linux): Likwise.
15233 (x86_linux_update_xmltarget): Call init_registers_x32_linux
15234 or init_registers_x32_avx_linux if linux_is_elf64 is false.
15235
ecedbe58
PA
152362012-04-13 Pedro Alves <palves@redhat.com>
15237
15238 * Makefile.in (GNULIB_FLAGS_TO_PASS): New.
15239 (FLAGS_TO_PASS): Don't change or set $top_srcdir, $srcdir and VPATH.
15240 (all, uninstall, clean-info, all-lib, clean, maintainer-clean)
15241 (realclean, distclean): Explicitly pass $GNULIB_FLAGS_TO_PASS to
15242 the sub-make.
15243
c92b5177
L
152442012-04-12 H.J. Lu <hongjiu.lu@intel.com>
15245
15246 * linux-x86-low.c (compat_x32_clock_t): New.
15247 (compat_x32_siginfo_t): Likewise.
15248 (compat_x32_siginfo_from_siginfo): Likewise.
15249 (siginfo_from_compat_x32_siginfo): Likewise.
15250 (linux_is_elf64): Likewise.
15251 (x86_siginfo_fixup): Call compat_x32_siginfo_from_siginfo
15252 and siginfo_from_compat_x32_siginfo for x32.
15253 (x86_arch_setup): Set linux_is_elf64.
15254
214d508e
L
152552012-04-12 H.J. Lu <hongjiu.lu@intel.com>
15256
15257 PR gdb/13969
15258 * linux-low.c (linux_pid_exe_is_elf_64_file): Also return the
15259 e_machine field.
15260 (linux_qxfer_libraries_svr4): Update call to elf_64_file_p.
15261 * linux-low.h (linux_pid_exe_is_elf_64_file): Updated.
15262 * linux-x86-low.c (x86_arch_setup): Check if GDBserver is
15263 compatible with process.
15264
c9a1864a
YQ
152652012-04-12 Yao Qi <yao@codesourcery.com>
15266
15267 * Makefile.in: Define abs_top_srcdir and abs_srcdir.
15268 (INCLUDE_CFLAGS): Append GNULIB_INCLUDE_DIR.
15269 (install-only, install-info, clean): Handle sub dir gnulib.
15270 (all-lib, am--refresh): New targets.
15271 (memmem.o): Remove target.
15272 * configure.ac: Remove AC_CONFIG_LIBOBJ_DIR.
15273 Invoke gl_EARLY. Invoke AC_CHECK_PROGS for make.
15274 (AC_REPLACE_FUNCS): Remove memmem.
15275 Invoke gl_INIT and AM_INIT_AUTOMAKE.
15276 (AC_OUTPUT): Generate Makefile in gnulib/.
15277 * aclocal.m4, config.in, configure: Regenerated.
15278
367ba2c2
MR
152792012-04-10 Maciej W. Rozycki <macro@codesourcery.com>
15280
15281 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP.
15282
9d236627
PA
152832012-04-05 Pedro Alves <palves@redhat.com>
15284
15285 -Werror=strict-aliasing
15286
15287 * spu-low.c (parse_spufs_run): Avoid dereferencing type-punned
15288 pointer.
15289
111217b3
PA
152902012-04-04 Pedro Alves <palves@redhat.com>
15291
15292 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
15293 (sparc_store_gregset_from_stack, sparc_store_gregset)
15294 (sparc_breakpoint_at): Fix formatting.
15295
8365dcf5
TJB
152962012-03-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
15297
15298 * configure.ac: Check whether Elf32_auxv_t and Elf64_auxv_t
15299 are available.
15300 * linux-low.c [HAVE_ELF32_AUXV_T] (Elf32_auxv_t): Add typedef.
15301 [HAVE_ELF64_AUXV_T] (Elf64_auxv_t): Likewise.
15302 * config.in: Regenerate.
15303 * configure: Likewise.
15304
689cc2ae
PA
153052012-03-29 Pedro Alves <palves@redhat.com>
15306
15307 * linux-low.c (regsets_store_inferior_registers) [__sparc__]:
15308 Correct ptrace arguments.
15309
c14dfd32
PA
153102012-03-28 Pedro Alves <palves@redhat.com>
15311
15312 * linux-ia64-low.c (ia64_regmap): Map IA64_EC_REGNUM to PT_AR_EC.
15313 (IA64_GR0_REGNUM, IA64_FR0_REGNUM)
15314 (IA64_FR1_REGNUM): New defines.
15315 (ia64_fetch_register): New.
15316 (the_low_target): Install it.
15317 * linux-low.h (struct linux_target_ops) <fetch_register>: New
15318 field.
15319 * linux-low.c (linux_fetch_registers): Try the
15320 the_low_target.fetch_register hook first.
15321
15322 * linux-arm-low.c (the_low_target): Adjust.
15323 * linux-bfin-low.c (the_low_target): Adjust.
15324 * linux-cris-low.c (the_low_target): Adjust.
15325 * linux-crisv32-low.c (the_low_target): Adjust.
15326 * linux-m32r-low.c (the_low_target): Adjust.
15327 * linux-m68k-low.c (the_low_target): Adjust.
15328 * linux-mips-low.c (the_low_target): Adjust.
15329 * linux-ppc-low.c (the_low_target): Adjust.
15330 * linux-s390-low.c (the_low_target): Adjust.
15331 * linux-sh-low.c (the_low_target): Adjust.
15332 * linux-sparc-low.c (the_low_target): Adjust.
15333 * linux-tic6x-low.c (the_low_target): Adjust.
15334 * linux-x86-low.c (the_low_target): Adjust.
15335 * linux-xtensa-low.c (the_low_target): Adjust.
15336
63c88e13
PA
153372012-03-26 Pedro Alves <palves@redhat.com>
15338
15339 * server.c (handle_qxfer_libraries): Don't bail early if
15340 the_target->qxfer_libraries_svr4 is not NULL.
15341
fb723180
PA
153422012-03-26 Pedro Alves <palves@redhat.com>
15343
15344 * linux-low.c (linux_qxfer_libraries_svr4): Fix pasto in comment.
15345
0afae3cf
PA
153462012-03-23 Pedro Alves <palves@redhat.com>
15347
15348 * linux-low.c (linux_qxfer_libraries_svr4): Terminate the
15349 "library-list-svr4" element's start tag when the the DSO list is
15350 empty.
15351
485f1ee4
PA
153522012-03-23 Pedro Alves <palves@redhat.com>
15353
15354 * linux-low.c (read_one_ptr): Read the inferior's pointer through
15355 a variable whose type size is the same as the inferior's pointer
15356 size.
15357
a5362b9a
TS
153582012-03-21 Thomas Schwinge <thomas@codesourcery.com>
15359
15360 * linux-arm-low.c (arm_stopped_by_watchpoint): Use siginfo_t instead of
15361 struct siginfo.
15362 * linux-low.c (siginfo_fixup, linux_xfer_siginfo): Likewise.
15363 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
15364 * linux-low.h: Include <signal.h>.
15365 (struct siginfo): Remove forward declaration.
15366 (struct linux_target_ops) <siginfo_fixup>: Use siginfo_t instead of
15367 struct siginfo.
15368
d226c142
MF
153692012-03-21 Mike Frysinger <vapier@gentoo.org>
15370
15371 * .gitignore: Ignore more files.
15372
122f36ef
PA
153732012-03-19 Pedro Alves <palves@redhat.com>
15374 Jan Kratochvil <jan.kratochvil@redhat.com>
15375
15376 * server.c (cont_thread, general_thread): Add describing comments.
15377 (start_inferior): Clear `cont_thread'.
15378 (handle_v_cont): Don't set `cont_thread' if resuming all threads
15379 of a process.
15380
fc3e5175
YQ
153812012-03-15 Yao Qi <yao@codesourcery.com>
15382
15383 * tracepoint.c (install_tracepoint): Move duplicated tracepoint
15384 handling to ...
15385 (cmd_qtdp): ... here.
15386
8d0d92cd
YQ
153872012-03-15 Yao Qi <yao@codesourcery.com>
15388
15389 * tracepoint.c (struct tracepoint_action_ops): New.
15390 (struct tracepoint_action) [!IN_PROCESS_AGENT] <ops>: New field.
15391 (m_tracepoint_action_download): New.
15392 (r_tracepoint_action_download): New.
15393 (x_tracepoint_action_download): New.
15394 (l_tracepoint_action_download): New.
15395 (add_tracepoint_action): Install `action->ops' according type.
15396 (download_tracepoint_1): Move code `download' function pointer
15397 of various tracepoint_action_ops.
15398
87b0bb13
JK
153992012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
15400
15401 * linux-low.c (linux_attach_lwp_1): New variable buffer. Call
15402 linux_ptrace_attach_warnings.
15403
5f572dec
JK
154042012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
15405
15406 * Makefile.in (linux-ptrace.o): New.
15407 * configure.srv (arm*-*-linux*, bfin-*-*linux*, crisv32-*-linux*)
15408 (cris-*-linux*, i[34567]86-*-linux*, ia64-*-linux*, m32r*-*-linux*)
15409 (m68*-*-linux*, m68*-*-uclinux*, mips*-*-linux*, powerpc*-*-linux*)
15410 (s390*-*-linux*, sh*-*-linux*, sparc*-*-linux*, tic6x-*-uclinux)
15411 (x86_64-*-linux*, xtensa*-*-linux*): Add linux-ptrace.o to SRV_TGTOBJ
15412 of these targets.
15413 * linux-low.c (linux_attach_lwp_1): Remove redundent else clause.
15414
f4647387
YQ
154152012-03-08 Yao Qi <yao@codesourcery.com>
15416 Pedro Alves <palves@redhat.com>
15417
15418 Fix PR server/13392.
15419 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Check
15420 offset of JMP insn.
15421 * tracepoint.c (remove_tracepoint): New.
15422 (cmd_qtdp): Call remove_tracepoint when failed to install.
15423
9b224c5e
PA
154242012-03-07 Pedro Alves <palves@redhat.com>
15425
15426 * linux-low.c (get_detach_signal): New.
15427 (linux_detach_one_lwp): Get rid of a pending SIGSTOP with SIGCONT.
15428 Pass on pending signals to PTRACE_DETACH. Check the result of the
15429 ptrace call.
15430 * server.c (program_signals, program_signals_p): New.
15431 (handle_general_set): Handle QProgramSignals.
15432 * server.h (program_signals, program_signals_p): Declare.
15433
e237a7e2
JK
154342012-03-05 Pedro Alves <palves@redhat.com>
15435 Jan Kratochvil <jan.kratochvil@redhat.com>
15436
15437 * linux-low.c (get_dynamic): Don't warn when PT_PHDR isn't found.
15438 New comment why.
15439
5808517f
YQ
154402012-03-03 Yao Qi <yao@codesourcery.com>
15441
15442 * tracepoint.c (tracepoint_look_up_symbols): Update call to
15443 agent_look_up_symbols.
15444
58b4daa5
YQ
154452012-03-03 Yao Qi <yao@codesourcery.com>
15446
15447 * Makefile.in (linux-low.o): Keep dependence on agent.h.
15448 (linux-x86-low.o): Likewise.
15449 * server.h: Remove in_process_agent_loaded.
15450 * tracepoint.c (in_process_agent_loaded): Removed. Moved it
15451 common/agent.c.
15452 Update callers.
15453
8ffcbaaf
YQ
154542012-03-03 Yao Qi <yao@codesourcery.com>
15455
15456 * tracepoint.c (gdb_agent_capability): New global.
15457 (in_process_agent_loaded_ust): Renamed to
15458 `in_process_agent_supports_ust'.
15459 Update callers.
15460 (in_process_agent_supports_ust): Call agent_capability_check.
15461 (clear_installed_tracepoints): Assert that agent supports
15462 agent.
15463
d1feda86
YQ
154642012-03-03 Yao Qi <yao@codesourcery.com>
15465
15466 * linux-low.c (linux_supports_agent): New.
15467 (linux_target_ops): Initialize field `supports_agent' with
15468 linux_supports_agent.
15469 * target.h (struct target_ops) <supports_agent>: New.
15470 (target_supports_agent): New macro.
15471 * server.c (handle_general_set): Handle packet 'QAgent'.
15472 (handle_query): Send `QAgent+'.
15473 * Makefile.in (server.o): Depends on agent.h.
15474
2fa291ac
YQ
154752012-03-03 Yao Qi <yao@codesourcery.com>
15476
15477 * Makefile.in (OBS): Add agent.o.
15478 Add new rule for agent.o.
15479 Track dependence of tracepoint.c on agent.h.
15480 * tracepoint.c (run_inferior_command_1):
15481 (run_inferior_command): Call agent_run_command.
15482 (gdb_ust_connect_sync_socket): Deleted. Move it to
15483 common/agent.c.
15484 (resume_thread, stop_thread): Likewise.
15485 (gdb_ust_socket_init): Renamed to ...
15486 (gdb_agent_socket_init): ... New.
15487 (gdb_ust_thread): Renamed to ...
15488 (gdb_agent_helper_thread): ... New.
15489 (gdb_ust_init): Move some code to ...
15490 (gdb_agent_init): ... here. New.
15491 [HAVE_UST]: Call gdb_ust_init.
15492 (initialize_tracepoint_ftlib): Call gdb_agent_init.
15493 * configure.ac: Add `sys/un.h' to AC_CHECK_HEADERS.
15494 * config.in, configure: Regenerated.
15495
05044653
PA
154962012-03-02 Pedro Alves <palves@redhat.com>
15497
15498 * inferiors.c (add_pid_to_list, pull_pid_from_list): Delete.
15499 * linux-low.c (struct simple_pid_list): New.
15500 (stopped_pids): New a struct simple_pid_list pointer.
15501 (add_to_pid_list, pull_pid_from_list): New.
15502 (handle_extended_wait): Don't assume the first signal new children
15503 report is SIGSTOP. Adjust call to pull_pid_from_list.
15504 (linux_wait_for_lwp): Adjust.
15505
8d00225b
YQ
155062012-03-02 Yao Qi <yao@codesourcery.com>
15507
15508 * tracepoint.c (do_action_at_tracepoint): Write `stop_pc' in
15509 debug log.
15510
19560ba5
YQ
155112012-03-02 Yao Qi <yao@codesourcery.com>
15512
15513 * tracepoint.c (collect_ust_data_at_tracepoint): Remove parameters
15514 `stop_pc' and `tpoint'. Update caller.
15515
1faeff08
MR
155162012-03-01 Maciej W. Rozycki <macro@codesourcery.com>
15517
15518 * linux-low.h (linux_target_ops): Add regset_bitmap member.
15519 * linux-low.c (use_linux_regsets): New macro.
15520 [!HAVE_LINUX_REGSETS] (regsets_fetch_inferior_registers): Likewise.
15521 [!HAVE_LINUX_REGSETS] (regsets_store_inferior_registers): Likewise.
15522 (linux_register_in_regsets): New function.
15523 (usr_fetch_inferior_registers): Skip registers covered by
15524 regsets.
15525 (usr_store_inferior_registers): Likewise.
15526 (usr_fetch_inferior_registers): New macro.
15527 (usr_store_inferior_registers): Likewise.
15528 (linux_fetch_registers): Handle mixed regset/non-regset targets.
15529 (linux_store_registers): Likewise.
15530 * linux-mips-low.c (init_registers_mips_dsp_linux): New
15531 prototype.
15532 (init_registers_mips64_dsp_linux): Likewise.
15533 (init_registers_mips_linux): New macro.
15534 (init_registers_mips_dsp_linux): Likewise.
15535 (mips_dsp_num_regs): Likewise.
15536 (DSP_BASE, DSP_CONTROL): New fallback macros.
15537 (mips_base_regs): New macro.
15538 (mips_regmap): Use it. Fix the size.
15539 (mips_dsp_regmap): New variable.
15540 (mips_dsp_regset_bitmap): Likewise.
15541 (mips_arch_setup): New function.
15542 (mips_cannot_fetch_register): Use the_low_target.regmap rather
15543 than mips_regmap.
15544 (mips_cannot_store_register): Likewise.
15545 (the_low_target): Update .arch_setup, .num_regs and .regmap
15546 initializers. Add .regset_bitmap initializer.
15547 * linux-arm-low.c (the_low_target): Add .regset_bitmap
15548 initializer.
15549 * linux-bfin-low.c (the_low_target): Likewise.
15550 * linux-cris-low.c (the_low_target): Likewise.
15551 * linux-crisv32-low.c (the_low_target): Likewise.
15552 * linux-ia64-low.c (the_low_target): Likewise.
15553 * linux-m32r-low.c (the_low_target): Likewise.
15554 * linux-m68k-low.c (the_low_target): Likewise.
15555 * linux-ppc-low.c (the_low_target): Likewise.
15556 * linux-s390-low.c (the_low_target): Likewise.
15557 * linux-sh-low.c (the_low_target): Likewise.
15558 * linux-sparc-low.c (the_low_target): Likewise.
15559 * linux-tic6x-low.c (the_low_target): Likewise.
15560 * linux-x86-low.c (the_low_target): Likewise.
15561 * linux-xtensa-low.c (the_low_target): Likewise.
15562 * configure.srv <mips*-*-linux*>: Add mips-dsp-linux.o and
15563 mips64-dsp-linux.o to srv_regobj. Add mips-dsp-linux.xml,
15564 mips64-dsp-linux.xml, mips-dsp.xml and mips64-dsp.xml to
15565 srv_xmlfiles.
15566 * Makefile.in (mips-dsp-linux.o, mips-dsp-linux.c): New targets.
15567 (mips64-dsp-linux.o, mips64-dsp-linux.c): Likewise.
15568
c03e6ccc
YQ
155692012-02-29 Yao Qi <yao@codesourcery.com>
15570 Pedro Alves <palves@redhat.com>
15571
15572 * linux-low.c: (linux_wait_1): Call unsuspend_all_lwps when
15573 `step_over_finished' is true.
15574
644cebc9
PA
155752012-02-27 Pedro Alves <palves@redhat.com>
15576
15577 * linux-low.c (pid_is_stopped): Delete, moved to common/.
15578 (linux_attach_lwp_1): Adjust to use linux_proc_pid_is_stopped.
15579
c14d7ab2
PA
155802012-02-27 Pedro Alves <palves@redhat.com>
15581
15582 PR server/9684
15583 * linux-low.c (pid_is_stopped): New.
15584 (linux_attach_lwp_1): Handle attaching to 'T (stopped)' processes.
15585
412c89dd
LM
155862012-02-25 Luis Machado <lgustavo@codesourcery.com>
15587
15588 * mem-break.c (clear_gdb_breakpoint_conditions): Fix de-allocation
15589 of conditions.
15590
b745defe
MR
155912012-02-24 Maciej W. Rozycki <macro@codesourcery.com>
15592
15593 * linux-mips-low.c (mips_regmap): Correct the index of $f9.
15594
9f3a5c85
LM
155952012-02-24 Luis Machado <lgustavo@codesourcery>
15596
15597 * server.c (handle_query): Advertise support for target-side
15598 breakpoint condition evaluation.
15599 (process_point_options): New function.
15600 (process_serial_event): When inserting a breakpoint, check for
15601 a target-side condition that should be evaluated.
15602
15603 * mem-break.c: Include regcache.h and ax.h.
15604 (point_cond_list_t): New data structure.
15605 (breakpoint) <cond_list>: New field.
15606 (find_gdb_breakpoint_at): Make non-static.
15607 (delete_gdb_breakpoint_at): Clear any target-side
15608 conditions.
15609 (clear_gdb_breakpoint_conditions): New function.
15610 (add_condition_to_breakpoint): Likewise.
15611 (add_breakpoint_condition): Likewise.
15612 (gdb_condition_true_at_breakpoint): Likewise.
15613 (gdb_breakpoint_here): Return result directly instead
15614 of going through a local variable.
15615
15616 * mem-break.h (find_gdb_breakpoint_at): New prototype.
15617 (clear_gdb_breakpoint_conditions): Likewise.
15618 (add_breakpoint_condition): Likewise.
15619 (gdb_condition_true_at_breakpoint): Likewise.
15620
15621 * linux-low.c (linux_wait_1): Evaluate target-side breakpoint condition.
15622 (need_step_over_p): Take target-side breakpoint condition into
15623 consideration.
15624
5e1dc496
LM
156252012-02-24 Luis Machado <lgustavo@codesourcery>
15626
15627 * server.h: Include tracepoint.h.
15628 (agent_mem_read, agent_get_trace_state_variable_value,
15629 agent_set_trace_state_variable_value,
15630 agent_tsv_read, agent_mem_read_string, get_get_tsv_func_addr,
15631 get_set_tsv_func_addr): New prototypes.
15632
15633 * ax.h: New include file.
15634 * ax.c: New source file.
15635
15636 * tracepoint.c: Include ax.h.
15637 (gdb_agent_op, gdb_agent_op_names, gdb_agent_op_sizes,
15638 agent_expr, eval_result_type): Move to ax.h.
15639 (parse_agent_expr): Rename to ...
15640 (gdb_parse_agent_expr): ... this, make it non-static and move
15641 to ax.h.
15642 (unparse_agent_expr) Rename to ...
15643 (gdb_unparse_agent_expr): ... this, make it non-static and move
15644 to ax.h.
15645 (eval_agent_expr): Rename to ...
15646 (eval_tracepoint_agent_expr): ... this.
15647 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Remove
15648 forward declarations.
15649 (add_tracepoint_action): Call gdb_parse_agent_expr (...).
15650 (agent_get_trace_state_variable_value): New function.
15651 (agent_set_trace_state_variable_value): New function.
15652 (cmd_qtdp): Call gdb_parse_agent_expr (...).
15653 (response_tracepoint): Call gdb_unparse_agent_expr (...).
15654 (do_action_at_tracepoint): Call eval_tracepoint_agent_expr (...).
15655 (condition_true_at_tracepoint): Likewise.
15656 (parse_agent_expr): Rename to ...
15657 (gdb_parse_agent_expr): ... this and move to ax.c.
15658 (unparse_agent_expr): Rename to ...
15659 (gdb_unparse_agent_expr): ... this and move to ax.c.
15660 (gdb_agent_op_name): Move to ax.c.
15661 (eval_agent_expr): Rename to ...
15662 (gdb_eval_agent_expr): ... this, use regcache passed as parameter
15663 and move to ax.c.
15664 (eval_tracepoint_agent_expr): New function.
15665 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Make
43aaf8b6 15666 non-static.
5e1dc496
LM
15667 (current_insn_ptr, emit_error, struct bytecode_address): Move to
15668 ax.c.
15669 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul, emit_lsh,
15670 emit_rsh_signed, emit_rsh_unsigned, emit_ext, emit_log_not,
15671 emit_bit_and, emit_bit_or, emit_bit_xor, emit_bit_not, emit_equal,
15672 emit_less_signed, emit_less_unsigned, emit_ref, emit_if_goto,
15673 emit_goto, write_goto_address, emit_const, emit_reg, emit_pop,
15674 emit_stack, emit_zero_ext, emit_swap, emit_stack_adjust,
15675 emit_int_call_1, emit_void_call_2, emit_eq_goto, emit_ne_goto,
15676 emit_lt_goto, emit_ge_goto, emit_gt_goto, emit_le_goto): Move to ax.c.
15677 (get_get_tsv_func_addr, get_set_tsv_func_addr): New functions.
15678 (compile_bytecodes): Remove forward declaration.
15679 (is_goto_target): Move to ax.c.
15680 (compile_bytecodes): Move to ax.c and call
15681 agent_get_trace_state_variable_value (...) and
15682 agent_set_trace_state_variable_value (...).
15683
15684 * Makefile.in: Update ax.c and IPA dependencies.
15685
277e4e52
PA
156862012-02-24 Pedro Alves <palves@redhat.com>
15687
15688 * tracepoint.c (cmd_bigqtbuffer): Rename as ...
15689 (cmd_bigqtbuffer_circular): ... this. Only handle
15690 'QTBuffer:circular:'.
15691 (handle_tracepoint_general_set): Adjust.
15692
bf4c19f7
YQ
156932012-02-16 Yao Qi <yao@codesourcery.com>
15694
15695 * inferiors.c: Move code to ...
15696 * dll.c: .... here. New.
15697 * server.h: Declare clear_dlls.
15698 * Makefile.in (SFILES): Add dll.c.
15699 (OBS): Add dll.o
15700 (dll.o): New rule.
15701
d73f2619
YQ
157022012-02-11 Yao Qi <yao@codesourcery.com>
15703
15704 * server.c: (handle_monitor_command): Add a new parameter
15705 `own_buf'.
15706 (handle_query): Update caller.
15707
f8255c2a
JB
157082012-02-09 Joel Brobecker <brobecker@adacore.com>
15709
15710 * configure.ac: Add readlink to AC_CHECK_FUNCS list.
15711 * configure, config.in: Regenerate.
15712 * hostio.c: Provide an alternate implementation if HAVE_READLINK
15713 is not defined.
15714
da84f473
PA
157152012-02-02 Pedro Alves <palves@redhat.com>
15716
15717 Try SIGKILL first, then PTRACE_KILL.
15718 * linux-low.c (linux_kill_one_lwp): New.
15719 (linux_kill_one_lwp): Rename to ...
15720 (kill_one_lwp_callback): ... this. Use the new
15721 linux_kill_one_lwp.
15722
e886a173
PA
157232012-02-02 Pedro Alves <palves@redhat.com>
15724
15725 * tracepoint.c (cmd_qtminftpilen): Return 0 if there's no current
15726 inferior.
15727
be07f1a2
PA
157282012-01-27 Pedro Alves <palves@redhat.com>
15729
15730 * linux-low.c (linux_child_pid_to_exec_file): Delete.
15731 (elf_64_file_p): Make static.
15732 (linux_pid_exe_is_elf_64_file): New.
15733 * linux-low.h (linux_child_pid_to_exec_file, elf_64_file_p):
15734 Delete declarations.
15735 (linux_pid_exe_is_elf_64_file): Declare.
15736 * linux-x86-low.c (x86_arch_setup): Use
15737 linux_pid_exe_is_elf_64_file.
15738
d8301ad1
JK
157392012-01-25 Jan Kratochvil <jan.kratochvil@redhat.com>
15740
15741 * linux-low.c (linux_wait_for_event_1): Rename to ...
15742 (linux_wait_for_event): ... here and merge it with former
15743 linux_wait_for_event - new variable wait_ptid, use it.
15744 (linux_wait_for_event): Remove - merge it to linux_wait_for_event_1.
15745
01b17894
PA
157462012-01-23 Pedro Alves <palves@redhat.com>
15747
15748 * server.c (main): Avoid yet another case of infinite loop while
15749 detaching/killing after a longjmp.
15750
e825046f
JK
157512012-01-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15752
15753 Code cleanup.
15754 * linux-low.c (linux_wait_for_event_1): Use ptid_is_pid.
15755
b9e7b9c3
UW
157562012-01-20 Ulrich Weigand <ulrich.weigand@linaro.org>
15757
15758 * hostio.c (handle_readlink): New function.
15759 (handle_vFile): Call it to handle "vFile:readlink" packets.
15760
901f9912
UW
157612012-01-20 Pedro Alves <palves@redhat.com>
15762 Ulrich Weigand <ulrich.weigand@linaro.org>
15763
15764 * server.c (handle_v_requests): Only support vAttach and vRun to
15765 start multiple processes when in extended protocol mode.
15766
fc1ab1a0
PA
157672012-01-17 Pedro Alves <palves@redhat.com>
15768
15769 * tracepoint.c (initialize_tracepoint): Use mmap instead of
15770 memalign plus mprotect to allocate the scratch buffer.
15771
7d5d4e98
PA
157722012-01-13 Pedro Alves <palves@redhat.com>
15773
15774 * server.c (attach_inferior): Clear `cont_thread'.
15775
f128d5e9
PA
157762012-01-13 Pedro Alves <palves@redhat.com>
15777
15778 * server.c (main): Avoid infinite loop while detaching/killing
15779 after a longjmp.
15780
06db92f0
DE
157812012-01-09 Doug Evans <dje@google.com>
15782
15783 * server.c (start_inferior): Set last_ptid in --wrapper case.
15784
32d92999
YQ
157852012-01-06 Yao Qi <yao@codesourcery.com>
15786
15787 * tracepoint.c [IN_PROCESS_AGENT] (debug_threads): Macro
15788 defined.
15789 [IN_PROCESS_AGENT] (debug_agent): New global variable.
15790
5e0a92a9
YQ
157912012-01-04 Yao Qi <yao@codesourcery.com>
15792
15793 * tracepoint.c (cmd_qtdp): Print debug message
15794 for static tracepoint.
15795
ae639e8c
YQ
157962012-01-04 Yao Qi <yao@codesourcery.com>
15797
15798 * tracepoint.c (trace_vdebug): Differentiate debug message
15799 between gdbserver and IPA.
15800
f72429c5
YQ
158012012-01-03 Yao Qi <yao@codesourcery.com>
15802
15803 * tracepoint.c (tracepoint_was_hit): Don't collect for
15804 static tracepoint.
15805
12c3e59c
JB
158062012-01-02 Joel Brobecker <brobecker@adacore.com>
15807
15808 * terminal.h: Reformat copyright header.
15809
67827812
JB
158102012-01-02 Joel Brobecker <brobecker@adacore.com>
15811
15812 * server.c (gdbserver_version): Update copyright year.
15813 * gdbreplay.c (gdbreplay_version): Likewise.
15814
3e52c33d
JK
158152011-12-18 Jan Kratochvil <jan.kratochvil@redhat.com>
15816
15817 * linux-low.c (linux_create_inferior): Put empty if clause for write.
15818
15819 Revert:
15820 2011-12-18 Hui Zhu <teawater@gmail.com>
15821 * linux-low.c (linux_create_inferior): Save return value to ret.
15822
66f1260e
HZ
158232011-12-18 Hui Zhu <teawater@gmail.com>
15824
15825 * linux-low.c (linux_create_inferior): Save return value to ret.
15826
e77616d7
DE
158272011-12-16 Doug Evans <dje@google.com>
15828
e7b06c57
DE
15829 * linux-low.c (linux_create_inferior): If stdio connection,
15830 redirect stdin from /dev/null, stdout to stderr.
15831 * remote-utils.c (remote_is_stdio): New static global.
15832 (remote_connection_is_stdio): New function.
15833 (remote_prepare): Handle stdio connection.
15834 (remote_open): Ditto.
15835 (remote_close): Don't close stdin for stdio connections.
15836 (read_prim,write_prim): New functions. Replace all calls to
15837 read/write to these.
15838 * server.c (main): Watch for "-" argument. Move call to
15839 remote_prepare before start_inferior.
15840 * server.h (STDIO_CONNECTION_NAME): New macro.
15841 (remote_connection_is_stdio): Declare.
15842
e77616d7
DE
15843 * remote-utils.c (prepare_resume_reply): Remove extraneous \n
15844 in debugging output.
15845
82067193
YQ
158462011-12-15 Yao Qi <yao@codesourcery.com>
15847
15848 * tracepoint.c: Include sys/syscall.h.
15849 (gdb_ust_thread): Remove preprocessor conditional.
15850
82bfbe7e
PA
158512011-12-14 Pedro Alves <pedro@codesourcery.com>
15852
15853 * linux-low.c (linux_detach_one_lwp): Call
15854 the_low_target.prepare_to_resume before detaching.
15855
712c6575
YQ
158562011-12-14 Yao Qi <yao@codesourcery.com>
15857
15858 * tracepoint.c (gdb_ust_thread): Don't ignore return value
15859 of write.
15860
d54d1edf
YQ
158612011-12-14 Yao Qi <yao@codesourcery.com>
15862
15863 * i386-low.c (i386_low_stopped_data_address): Initialize local
15864 variable `control'.
15865
6210a125
PA
158662011-12-13 Pedro Alves <pedro@codesourcery.com>
15867
15868 PR remote/13492
15869
15870 * i386-low.c (i386_low_stopped_data_address): Avoid fetching
15871 DR_CONTROL unless necessary. Extend comments.
15872 * linux-x86-low.c (x86_linux_prepare_to_resume): Don't write to
15873 DR0-3 if not used. If any watchpoint was set, clear DR_STATUS.
15874
2ece8244
YQ
158752011-12-13 Yao Qi <yao@codesourcery.com>
15876
15877 * tracepoint.c (trace_buffer_alloc): Replace magic numbers with
15878 macros.
15879 (upload_fast_traceframes, upload_fast_traceframes): Likewise.
15880
784867a5
JK
158812011-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
15882
15883 * linux-low.c (linux_kill): Skip PTRACE_KILL if LWP does not exist.
15884 Print new debug message for such case.
15885
6bf36717
JK
158862011-12-06 Jan Kratochvil <jan.kratochvil@redhat.com>
15887
15888 Fix overlapping memcpy.
15889 * mem-break.c (set_raw_breakpoint_at): New variable buf. Use it for
15890 the read_inferior_memory transfer.
15891 (delete_fast_tracepoint_jump): New variable buf. Use it for the
15892 write_inferior_memory transfer.
15893 (set_fast_tracepoint_jump): New variable buf. Use it for the
15894 read_inferior_memory and write_inferior_memory transfers.
15895 (uninsert_fast_tracepoint_jumps_at, reinsert_fast_tracepoint_jumps_at)
15896 (delete_raw_breakpoint, uninsert_raw_breakpoint): New variable buf.
15897 Use it for the write_inferior_memory transfer.
15898 (check_mem_read, check_mem_write): New gdb_asserts for overlapping
15899 buffers.
15900
50275556
MR
159012011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
15902
15903 * linux-low.c (fetch_register, store_register): Make code
15904 consistent, fix formatting.
15905
7325beb4
MR
159062011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
15907
15908 * linux-low.c (usr_store_inferior_registers): Factor out code
15909 to handle individual registers into...
15910 (store_register): ... this new function.
15911
c642a434
UW
159122011-12-06 Ulrich Weigand <uweigand@de.ibm.com>
15913
15914 * Makefile.in (s390-linux32v1.o, s390-linux32v1.c): New rules.
15915 (s390-linux32v2.o, s390-linux32v2.c): Likewise.
15916 (s390-linux64v1.o, s390-linux64v1.c): Likewise.
15917 (s390-linux64v2.o, s390-linux64v2.c): Likewise.
15918 (s390x-linux64v1.o, s390x-linux64v1.c): Likewise.
15919 (s390x-linux64v2.o, s390x-linux64v2.c): Likewise.
15920 * configure.srv [s390*-*-linux*] (srv_regobj): Add new objects.
15921 (srv_xmlfiles): Add new XML files.
15922
15923 * linux-s390-low.c: Include "elf/common.h", <sys/ptrace.h>,
15924 and <sys/uio.h>.
15925 (PTRACE_GETREGSET, PTRACE_SETREGSET): Define if undefined.
15926 (init_registers_s390_linux32v1): Add prototype.
15927 (init_registers_s390_linux32v2): Likewise.
15928 (init_registers_s390_linux64v1): Likewise.
15929 (init_registers_s390_linux64v2): Likewise.
15930 (init_registers_s390x_linux64v1): Likewise.
15931 (init_registers_s390x_linux64v2): Likewise.
15932 (s390_num_regs): Increment to 52.
15933 (s390_regmap): Add orig_r2 register.
15934 (s390_num_regs_3264): Increment to 68.
15935 (s390_regmap_3264): Add orig_r2 register.
15936 (s390_collect_ptrace_register): Handle orig_r2 register.
15937 (s390_supply_ptrace_register): Likewise.
15938 (s390_fill_last_break): New function.
15939 (s390_store_last_break): Likewise.
15940 (s390_fill_system_call): New function.
15941 (s390_store_system_call): Likewise.
15942 (target_regsets): Handle NT_S390_LAST_BREAK and NT_S390_SYSTEM_CALL
15943 register sets.
15944 (s390_check_regset): New function.
15945 (s390_arch_setup): Check for presence of NT_S390_LAST_BREAK and
15946 NT_S390_SYSTEM_CALL regsets and use appropriate description.
15947 Update target_regsets for available register sets.
15948
2268b414
JK
159492011-12-02 Paul Pluzhnikov <ppluzhnikov@google.com>
15950 Jan Kratochvil <jan.kratochvil@redhat.com>
15951
15952 * linux-low.c (get_phdr_phnum_from_proc_auxv, get_dynamic, get_r_debug)
15953 (read_one_ptr, struct link_map_offsets, linux_qxfer_libraries_svr4):
15954 New.
15955 (struct linux_target_ops): Install linux_qxfer_libraries_svr4.
15956 * linux-low.h (struct process_info_private): New member r_debug.
15957 * server.c (handle_qxfer_libraries): Call
15958 the_target->qxfer_libraries_svr4.
15959 (handle_qxfer_libraries_svr4): New function.
15960 (qxfer_packets): New entry "libraries-svr4".
15961 (handle_query): Check QXFER_LIBRARIES_SVR4 and report libraries-svr4.
15962 * target.h (struct target_ops): New member qxfer_libraries_svr4.
15963 * remote.c (remote_xfer_partial): Call add_packet_config_cmd for
15964 PACKET_qXfer_libraries_svr4.
15965
d6db1fab
UW
159662011-11-30 Ulrich Weigand <uweigand@de.ibm.com>
15967
15968 * linux-s390-low.c (s390_collect_ptrace_register): Fully convert
15969 PSW address/mask between 8-byte and 16-byte formats.
15970 (s390_supply_ptrace_register): Likewise.
15971 (s390_get_pc, s390_set_pc): 4-byte PSW address always includes
15972 basic addressing mode bit.
15973
242f5f1c
SS
159742011-11-24 Stan Shebs <stan@codesourcery.com>
15975
15976 * tracepoint.c (cmd_qtstatus): Use plongest instead of %llx.
15977
f196051f
SS
159782011-11-17 Stan Shebs <stan@codesourcery.com>
15979
15980 * tracepoint.c (struct tracepoint): New field traceframe_usage.
15981 (tracing_start_time): New global.
15982 (tracing_stop_time): New global.
15983 (tracing_user_name): New global.
15984 (tracing_notes): New global.
15985 (tracing_stop_note): New global.
15986 (cmd_qtstart): Set traceframe_usage, start_time.
15987 (stop_tracing): Set stop_time.
15988 (cmd_qtstatus): Report additional status.
15989 (cmd_qtp): New function.
15990 (handle_tracepoint_query): Call it.
15991 (cmd_qtnotes): New function.
15992 (handle_tracepoint_general_set): Call it.
15993 (get_timestamp): Rename from tsv_get_timestamp.
15994
405f8e94
SS
159952011-11-14 Stan Shebs <stan@codesourcery.com>
15996 Kwok Cheung Yeung <kcy@codesourcery.com>
15997
15998 * linux-x86-low.c (small_jump_insn): New.
15999 (i386_install_fast_tracepoint_jump_pad): Add arguments for
16000 trampoline and error message, build a trampoline and issue a small
16001 jump instruction to it.
16002 (x86_install_fast_tracepoint_jump_pad): Add arguments for
16003 trampoline and error message.
16004 (x86_get_min_fast_tracepoint_insn_len): New.
16005 (the_low_target): Add call to x86_get_min_fast_tracepoint_insn_len.
16006 * linux-low.h (struct linux_target_ops): Add arguments to
16007 install_fast_tracepoint_jump_pad operation, add new operation.
16008 * linux-low.c (linux_install_fast_tracepoint_jump_pad): Add
16009 arguments.
16010 (linux_get_min_fast_tracepoint_insn_len): New function.
16011 (linux_target_op): Add new operation.
16012 * tracepoint.c (gdb_trampoline_buffer): New IPA variable.
16013 (gdb_trampoline_buffer_end): Ditto.
16014 (gdb_trampoline_buffer_error): Ditto.
16015 (struct ipa_sym_addresses): Add fields for new IPA variables.
16016 (symbol_list): Add entries for new IPA variables.
16017 (struct tracepoint): Add fields to hold the address range of the
16018 trampoline used by the tracepoint.
16019 (trampoline_buffer_head): New static variable.
16020 (trampoline_buffer_tail): Ditto.
16021 (claim_trampoline_space): New function.
16022 (have_fast_tracepoint_trampoline_buffer): New function.
16023 (clone_fast_tracepoint): Fill in trampoline fields of tracepoint
16024 structure.
16025 (install_fast_tracepoint): Ditto, also add error buffer argument.
16026 (cmd_qtminftpilen): New function.
16027 (handle_tracepoint_query): Add response to qTMinFTPILen packet.
16028 (fast_tracepoint_from_trampoline_address): New function.
16029 (fast_tracepoint_collecting): Handle trampoline as part of jump
16030 pad space.
16031 (set_trampoline_buffer_space): New function.
16032 (initialize_tracepoint): Initialize new IPA variables.
16033 * target.h (struct target_ops): Add arguments to
16034 install_fast_tracepoint_jump_pad operation, add new
16035 get_min_fast_tracepoint_insn_len operation.
16036 (target_get_min_fast_tracepoint_insn_len): New.
16037 (install_fast_tracepoint_jump_pad): Add arguments.
16038 * server.h (IPA_BUFSIZ): Define.
16039 * linux-i386-ipa.c: Include extra header files.
16040 (initialize_fast_tracepoint_trampoline_buffer): New function.
16041 (initialize_low_tracepoint): Call it.
16042 * server.h (set_trampoline_buffer_space): Declare.
16043 (claim_trampoline_space): Ditto.
16044 (have_fast_tracepoint_trampoline_buffer): Ditto.
16045
1e4d1764
YQ
160462011-11-14 Yao Qi <yao@codesourcery.com>
16047
16048 * server.c (handle_query): Handle InstallInTrace for qSupported.
16049 * tracepoint.c (add_tracepoint): Sort list.
16050 (install_tracepoint, download_tracepoint): New.
16051 (cmd_qtdp): Call them to install and download tracepoints.
16052 (sort_tracepoints): Removed.
16053 (cmd_qtstart): Update.
16054
5c73ff4e
YQ
160552011-11-14 Yao Qi <yao@codesourcery.com>
16056
16057 * mem-break.c (inc_ref_fast_tracepoint_jump): New.
16058 * mem-break.h: Declare.
16059 * tracepoint.c (cmd_qtstart): Move some code to ...
16060 (clone_fast_tracepoint, install_fast_tracepoint): ... here.
16061 New.
16062 (download_tracepoints): Move some code to ...
16063 (download_tracepoint_1): ... here. New.
16064
86a30030
YQ
160652011-11-08 Yao Qi <yao@codesourcery.com>
16066
16067 * remote-utils.c (relocate_instruction): A comment fix.
16068
8d26e50c
JB
160692011-11-07 Joel Brobecker <brobecker@adacore.com>
16070
16071 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): Delete.
16072 (i386_dr_low_get_control, i386_dr_low_get_status): Use
16073 dr_status_mirror and dr_control_mirror from debug_reg_state.
16074 (i386_dr_low_get_status): Use debug_reg_state.dr_status_mirror
16075 (i386_initial_stuff): Remove use of deleted globals.
16076 (i386_get_thread_context, i386_set_thread_context,
16077 i386_thread_added): Use dr_status_mirror and dr_control_mirror
16078 from debug_reg_state.
16079
a59306a3
YQ
160802011-11-05 Yao Qi <yao@codesourcery.com>
16081
16082 * tracepoint.c (gdb_collect): Loop over tracepoints of same
16083 address as TPOINT's.
16084
3065dfb6
SS
160852011-11-02 Stan Shebs <stan@codesourcery.com>
16086
16087 * tracepoint.c (agent_mem_read_string): New function.
16088 (eval_agent_expr): Call it for tracenz.
16089 * server.c (handle_query): Report support for tracenz.
16090
fd0d8c7c
YQ
160912011-11-02 Yao Qi <yao@codesourcery.com>
16092
16093 * tracepoint.c (cmd_qtstart): Remove unused local variables.
16094
609086b1
YQ
160952011-11-02 Yao Qi <yao@codesourcery.com>
16096
16097 * target.h: Fix a typo in comment.
16098
b9fd1791
PA
160992011-10-31 Pedro Alves <pedro@codesourcery.com>
16100
16101 * mem-break.c (check_mem_write): Add `myaddr' parameter. Don't
16102 clobber the breakpoints' shadows with fast tracepoint jumps.
16103 * mem-break.h (check_mem_write): Add `myaddr' parameter.
16104 * target.c (write_inferior_memory): Also pass MYADDR down to
16105 check_mem_write.
16106
03583c20
UW
161072011-10-07 Ulrich Weigand <ulrich.weigand@linaro.org>
16108
16109 * configure.ac: Check support for personality routine.
16110 * configure: Regenerate.
16111 * config.in: Likewise.
16112 * linux-low.c: Include <sys/personality.h>.
16113 Define ADDR_NO_RANDOMIZE if necessary.
16114 (linux_create_inferior): Disable address space randomization when
16115 forking inferior, if requested.
16116 (linux_supports_disable_randomization): New function.
16117 (linux_target_ops): Install it.
16118 * server.h (disable_randomization): Declare.
16119 * server.c (disable_randomization): New global variable.
16120 (handle_general_set): Handle QDisableRandomization.
16121 (handle_query): Likewise for qSupported.
16122 (main): Support --disable-randomization and --no-disable-randomization
16123 command line arguments.
16124 * target.h (struct target_ops): Add supports_disable_randomization.
16125 (target_supports_disable_randomization): New macro.
16126
723b724b
MF
161272011-09-29 Mike Frysinger <vapier@gentoo.org>
16128
16129 * linux-low.c (target_loadseg): Add defined PTRACE_GETFDPIC to the
16130 ifdef check.
16131 [PT_GETDSBT] (target_loadmap): Wrap in a defined PT_GETDSBT check.
16132 [!PT_GETDSBT] (target_loadmap): New definition.
16133 (LINUX_LOADMAP, LINUX_LOADMAP_EXEC, LINUX_LOADMAP_INTERP): Define.
16134 (linux_read_loadmap): Change PTRACE_GETDSBT_EXEC to
16135 LINUX_LOADMAP_EXEC, PTRACE_GETDSBT_INTERP to LINUX_LOADMAP_INTERP,
16136 and PT_GETDSBT to LINUX_LOADMAP.
16137 [!PT_GETDSBT] (linux_read_loadmap): Define to NULL.
16138 (linux_target_ops): Delete unnecessary ifdef PT_GETDSBT check.
16139
55329a5c 161402011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
71487fd7
UW
16141
16142 * linux-arm-low.c (struct arm_linux_hwbp_cap): Remove.
16143 (arm_linux_hwbp_cap): New static variable.
16144 (arm_linux_get_hwbp_cap): Replace by ...
16145 (arm_linux_init_hwbp_cap): ... this new function.
16146 (arm_linux_get_hw_breakpoint_count): Use arm_linux_hwbp_cap.
16147 (arm_linux_get_hw_watchpoint_count): Likewise.
16148 (arm_linux_get_hw_watchpoint_max_length): Likewise.
16149 (arm_arch_setup): Call arm_linux_init_hwbp_cap.
16150 (arm_prepare_to_resume): Use perror_with_name instead of error.
16151
55329a5c 161522011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
09b4ad9f
UW
16153
16154 * linux-arm-low.c: Include <signal.h>.
16155 (PTRACE_GETHBPREGS, PTRACE_SETHBPREGS): Define if necessary.
16156 (struct arm_linux_hwbp_cap): New data type.
16157 (arm_hwbp_type, arm_hwbp_control_t): New typedefs.
16158 (struct arm_linux_hw_breakpoint): New data type.
16159 (MAX_BPTS, MAX_WPTS): Define.
16160 (struct arch_process_info, struct arch_lwp_info): New data types.
16161 (arm_linux_get_hwbp_cap): New function.
16162 (arm_linux_get_hw_breakpoint_count): Likewise.
16163 (arm_linux_get_hw_watchpoint_count): Likewise.
16164 (arm_linux_get_hw_watchpoint_max_length): Likewise.
16165 (arm_hwbp_control_initialize): Likewise.
16166 (arm_hwbp_control_is_enabled): Likewise.
16167 (arm_hwbp_control_is_initialized): Likewise.
16168 (arm_hwbp_control_disable): Likewise.
16169 (arm_linux_hw_breakpoint_equal): Likewise.
16170 (arm_linux_hw_point_initialize): Likewise.
16171 (struct update_registers_data): New data structure.
16172 (update_registers_callback: New function.
16173 (arm_insert_point): Likewise.
16174 (arm_remove_point): Likewise.
16175 (arm_stopped_by_watchpoint): Likewise.
16176 (arm_stopped_data_address): Likewise.
16177 (arm_new_process): Likewise.
16178 (arm_new_thread): Likewise.
16179 (arm_prepare_to_resume): Likewise.
16180 (the_low_target): Register arm_insert_point, arm_remove_point,
16181 arm_stopped_by_watchpoint, arm_stopped_data_address, arm_new_process,
16182 arm_new_thread, and arm_prepare_to_resume.
16183
6b9801d4
SS
161842011-09-15 Stan Shebs <stan@codesourcery.com>
16185
16186 * server.h (struct emit_ops): Add compare-goto fields.
16187 * tracepoint.c (gdb_agent_op_sizes): New table.
16188 (emit_eq_goto): New function.
16189 (emit_ne_goto): New function.
16190 (emit_lt_goto): New function.
16191 (emit_le_goto): New function.
16192 (emit_gt_goto): New function.
16193 (emit_ge_goto): New function.
16194 (is_goto_target): New function.
16195 (compile_bytecodes): Recognize special cases of compare-goto
16196 combinations and call specialized emitters for them.
16197 * linux-x86-low.c (amd64_emit_eq_goto): New function.
16198 (amd64_emit_ne_goto): New function.
16199 (amd64_emit_lt_goto): New function.
16200 (amd64_emit_le_goto): New function.
16201 (amd64_emit_gt_goto): New function.
16202 (amd64_emit_ge_goto): New function.
16203 (amd64_emit_ops): Add the new functions.
16204 (i386_emit_eq_goto): New function.
16205 (i386_emit_ne_goto): New function.
16206 (i386_emit_lt_goto): New function.
16207 (i386_emit_le_goto): New function.
16208 (i386_emit_gt_goto): New function.
16209 (i386_emit_ge_goto): New function.
16210 (i386_emit_ops): Add the new functions.
16211
bf15cbda
SS
162122011-09-08 Stan Shebs <stan@codesourcery.com>
16213
16214 * linux-x86-low.c (i386_emit_prologue): Save %ebx.
16215 (i386_emit_epilogue): Restore %ebx.
16216
943ca1dd
JZ
162172011-08-31 Jie Zhang <jzhang918@gmail.com>
16218
16219 * server.c (step_thread): Remove definition.
16220 (process_serial_event): Don't handle Hs.
16221 * server.h (step_thread): Remove declaration.
16222 * target.c (set_desired_inferior): Remove use of step_thread.
16223
e3deef73
LM
162242011-08-24 Luis Machado <lgustavo@codesourcery.com>
16225
16226 * linux-low.c: Include linux-procfs.h.
16227 (linux_attach_lwp_1): Update comments.
16228 (linux_attach): Scan for existing threads when attaching to a
16229 process that is the tgid.
16230 * Makefile.in: Update dependencies.
16231
13da1c97
LM
162322011-08-24 Luis Machado <lgustavo@codesourcery.com>
16233
16234 * configure.srv: Add linux-procfs.o dependencies.
16235
881127c9
YQ
162362011-08-14 Yao Qi <yao@codesourcery.com>
16237
16238 * target.h (struct target_ops): Fix indent.
16239 * win32-low.c (win32_target_ops): Fix comment.
16240
58dbd541
YQ
162412011-08-14 Andrew Jenner <andrew@codesourcery.com>
16242 Yao Qi <yao@codesourcery.com>
16243
16244 * Makefile.in (clean): Remove tic6x-*.c files.
16245 (linux-tic6x-low.o, tic6x-c62x-linux.o, tic6x-c64x-linux.o): New rules.
16246 (tic6x-c64xp-linux.o, tic6x-c62x-linux.c, tic6x-c64x-linux.c): Likewise.
16247 (tic6x-c64xp-linux.c): Likewise.
16248 * configure.srv: Add support for tic6x-*-uclinux.
16249 * linux-tic6x-low.c: New.
16250 * linux-low.c (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define.
16251
78d85199
YQ
162522011-08-14 Andrew Stubbs <ams@codesourcery.com>
16253 Yao Qi <yao@codesourcery.com>
16254
16255 * target.h (struct target_ops): Add read_loadmap.
16256 * linux-low.c (struct target_loadseg): New type.
16257 (struct target_loadmap): New type.
16258 (linux_read_loadmap): New function.
16259 (linux_target_ops): Add linux_read_loadmap.
16260 * server.c (handle_query): Support qXfer:fdpic:read packet.
43aaf8b6
PA
16261 * win32-low.c (win32_target_ops): Initialize field `read_loadmap'
16262 to NULL.
78d85199 16263
a959a88d
EZ
162642011-08-05 Eli Zaretskii <eliz@gnu.org>
16265
16266 * win32-low.c: Include <stdint.h>.
16267
1ced966e
PA
162682011-07-22 Pedro Alves <pedro@codesourcery.com>
16269
16270 * i386-low.c (i386_insert_aligned_watchpoint): Don't pass the info
16271 to the inferior here.
16272 (i386_remove_aligned_watchpoint): Ditto.
16273 (i386_handle_nonaligned_watchpoint): Return immediate on fail to
16274 fit part of the watchpoint in the debug registers.
16275 (i386_update_inferior_debug_regs): New.
16276 (i386_low_insert_watchpoint): Work on a local mirror of the debug
16277 registers, and only update the inferior on success.
16278 (i386_low_remove_watchpoint): Ditto.
16279
d26e3629
KY
162802011-07-22 Kwok Cheung Yeung <kcy@codesourcery.com>
16281
16282 * linux-low.c (compare_ints, unique, list_threads, show_process,
16283 linux_core_of_thread): Delete.
16284 (linux_target_ops): Change linux_core_of_thread to
16285 linux_common_core_of_thread.
16286 (linux_qxfer_osdata): Defer to linux_common_xfer_osdata.
16287 * utils.c (malloc_failure): Change type of argument.
16288 (xmalloc, xrealloc, xcalloc, xsnprintf): Delete.
16289 * Makefile.in (SFILES): Add common/common-utils.c, common/xml-utils.c,
16290 common/linux-osdata.c, common/ptid.c and common/buffer.c.
16291 (OBS): Add xml-utils.o, common-utils.o, ptid.o and buffer.o.
16292 (IPA_OBJS): Add common-utils-ipa.o.
16293 (ptid_h, linux_osdata_h): New macros.
16294 (server_h): Add common/common-utils.h, common/xml-utils.h,
16295 common/buffer.h, common/gdb_assert.h, common/gdb_locale.h and
16296 common/ptid.h.
16297 (common-utils-ipa.o, common-utils.o, xml-utils.o, linux-osdata.o,
16298 ptid.o, buffer.o): New rules.
16299 (linux-low.o): Add common/linux-osdata.h as a dependency.
16300 * configure.srv (srv_tgtobj): Add linux-osdata.o to Linux targets.
16301 * configure.ac: Add AC_HEADER_DIRENT check.
16302 * config.in: Regenerate.
16303 * configure: Regenerate.
16304 * remote-utils.c (xml_escape_text): Delete.
16305 (buffer_grow, buffer_free, buffer_init, buffer_finish,
16306 buffer_xml_printf): Move to common/buffer.c.
16307 * server.c (main): Remove call to initialize_inferiors.
16308 * server.h (struct ptid, ptid_t, minus_one_ptid, null_ptid,
16309 ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp, ptid_get_tid,
16310 ptid_equal, ptid_is_pid, initialize_inferiors, xml_escape_text,
16311 internal_error, gdb_assert, gdb_assert_fail): Delete.
16312 (struct buffer, buffer_grow, buffer_free, buffer_init, buffer_finish,
16313 buffer_xml_printf, buffer_grow_str, buffer_grow_str0): Move to
16314 common/buffer.h.
16315 * inferiors.c (null_ptid, minus_one_ptid, ptid_build, pid_to_ptid,
16316 ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal, ptid_is_pid,
16317 initialize_inferiors): Delete.
16318
2275a1a7
PA
163192011-07-20 Pedro Alves <pedro@codesourcery.com>
16320
16321 * tracepoint.c (tracepoint_look_up_symbols): Return upon the first
16322 symbol error.
16323
0a5b1e09
PA
163242011-05-31 Pedro Alves <pedro@codesourcery.com>
16325
16326 * linux-x86-low.c (i386_dr_low_get_addr): Fix off by one in
16327 assertion.
16328 * win32-i386-low.c (i386_dr_low_get_addr): Ditto.
16329
6938fd34
YQ
163302011-05-26 Yao Qi <yao@codesourcery.com>
16331
16332 * Makefile.in (thread-db.o): Track dependence to
16333 common/gdb_thread_db.h.
16334 * thread-db.c: include gdb_thread_db.h from right place.
16335
b481f9e0
TT
163362011-05-16 Adrian Cornish <gnu@bluedreamer.com>
16337
16338 * linux-i386-ipa.c (supply_static_tracepoint_registers): Pass
16339 __FILE__ and __LINE__ to internal_error.
16340
98a5dd13
DE
163412011-05-13 Doug Evans <dje@google.com>
16342
16343 * thread-db.c (try_thread_db_load_from_sdir): New function.
16344 (try_thread_db_load_from_dir): New function.
16345 (thread_db_load_search): Handle $sdir, ignore $pdir.
16346 Remove trying of system directories if search of
16347 libthread-db-search-path fails, that is now done via $sdir.
16348
d248b706
KY
163492011-05-12 Kwok Cheung Yeung <kcy@codesourcery.com>
16350
16351 * server.c (handle_query): Add EnableDisableTracepoints to the list
16352 of supported features.
43aaf8b6 16353 * tracepoint.c (clear_installed_tracepoints): Uninstall disabled
d248b706 16354 tracepoints.
43aaf8b6
PA
16355 (cmd_qtenable_disable): New.
16356 (cmd_qtstart): Install tracepoints even if disabled.
16357 (handle_tracepoint_general_set): Add call to cmd_qtenable_disable on
16358 receiving a QTEnable or QTDisable packet.
16359 (gdb_collect): Skip data collection if fast tracepoint is disabled.
16360 (ust_marker_to_static_tracepoint): Do not ignore disabled static
16361 tracepoints.
16362 (gdb_probe): Skip data collection if static tracepoint is disabled.
d248b706 16363
84e578fb
DE
163642011-05-10 Doug Evans <dje@google.com>
16365
16366 * thread-db.c (thread_db_handle_monitor_command): Handle elided path.
16367
71f55dd8
DE
163682011-05-04 Doug Evans <dje@google.com>
16369
16370 * linux-low.c (linux_join): Skip process lookup.
16371 * spu-low.c (spu_join): Ditto.
16372 * server.c (join_inferiors_callback): Delete.
16373 (process_serial_event): For 'D' packet (detach) call join_inferior
16374 directly.
16375
4d393d60
JM
163762011-05-04 Joseph Myers <joseph@codesourcery.com>
16377
16378 * README: Don't mention xscale*-*-linux*.
16379 * configure.srv (xscale*-*-linux*): Don't handle target.
16380
b00ad6ff
NF
163812011-04-27 Nathan Froyd <froydnj@codesourcery.com>
16382
16383 * linux-x86-low.c (amd64_emit_const): Call memcpy instead of
16384 casting pointers.
16385 (amd64_emit_reg, amd64_emit_int_call_1, amd64_emit_void_call_2):
16386 (i386_emit_const, i386_emit_reg, i386_emit_int_call_1):
16387 (i386_emit_void_call_2): Likewise.
16388
af96c192
YQ
163892011-04-26 Yao Qi <yao@codesourcery.com>
16390
43aaf8b6
PA
16391 * linux-low.c: Move common macros to linux-ptrace.h.
16392 Include linux-ptrace.h.
af96c192
YQ
16393 * Makefile.in (linux_ptrace_h): New.
16394 (linux-low.o): Depends on linux-ptrace.h.
16395
03f2bd59
JK
163962011-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
16397
16398 * remote-utils.c (handle_accept_event): Close LISTEN_DESC only if
16399 RUN_ONCE. Comment for the LISTEN_DESC delete_file_handler call.
16400 (remote_prepare): New function with most of the TCP code from ...
16401 (remote_open): ... here. Detect PORT here unconditionally. Move also
16402 setting transport_is_reliable.
16403 * server.c (run_once): New variable.
16404 (gdbserver_usage): Document it.
16405 (main): Set run_once for `--once'. Call remote_prepare. Exit after
16406 the first run if RUN_ONCE.
16407 * server.h (run_once, remote_prepare): New declarations.
16408
7a9dd1b2
TT
164092011-04-19 Tom Tromey <tromey@redhat.com>
16410
16411 * win32-low.c (handle_load_dll): Remove duplicate "the".
16412
81239425
PM
164132011-04-07 Pierre Muller <muller@ics.u-strasbg.fr>
16414
16415 Remove support for old Cygwin 1.5 versions.
16416 * win32-low.c (win32_create_inferior): Use new cygwin_path_list
16417 function to avoid warning.
16418 (win32_add_one_solib): Use cygwin_conv_path function to avoid
16419 warning.
16420
9e0627f1
PM
164212011-03-18 Pierre Muller <muller@ics.u-strasbg.fr>
16422
16423 * gdbserver/server.h (Macro _): Define it if not available.
16424
588eebee
MS
164252011-03-14 Michael Snyder <msnyder@vmware.com>
16426
348af9f7 16427 * hostio.c (handle_close): Remove unnecessary null test.
588eebee 16428
43f70d4c
JB
164292011-03-10 Joel Brobecker <brobecker@adacore.com>
16430
16431 * Makefile.in (maintainer-clean realclean distclean): Remove
16432 "make ... subdir_do" command.
16433
348af9f7
MS
164342011-03-10 Michael Snyder <msnyder@vmware.com>
16435
16436 * tracepoint.c (tracepoint_finish_step): Fix loop variable.
16437
16438 * server.c (handle_v_run): Free alloced buffer on early return.
16439
e637a4f5
YQ
164402011-03-09 Yao Qi <yao@codesourcery.com>
16441
16442 Revert:
16443 2011-03-04 Yao Qi <yao@codesourcery.com>
16444
16445 * Makefile.in: Remove GNU make feature --directory.
16446
16447 2011-03-05 Yao Qi <yao@codesourcery.com>
16448
16449 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
16450 (subdir_do): New make target. Copied from gdb/Makefile.
16451 (maintainer-clean, realclean, distclean, clean): Call corresponding
16452 make targets in common/Makefile.
16453
16454 2011-02-11 Yao Qi <yao@codesourcery.com>
16455
16456 * configure.ac: Call AC_PROG_RANLIB.
16457 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
16458 * configure: Regenerate.
16459
e6edda56
JK
164602011-03-07 Jan Kratochvil <jan.kratochvil@redhat.com>
16461
16462 * remote-utils.c (putpkt_binary_1): Calculate BUF2 size dynamically.
16463
e5141119
JB
164642011-03-06 Yao Qi <yao@codesourcery.com>
16465
16466 * Makefile.in (REQUIRED_SUBDIRS): Remove $(LIBCOMMON_DIR).
16467
64794aa4
JB
164682011-03-05 Yao Qi <yao@codesourcery.com>
16469
16470 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
16471 (subdir_do): New make target. Copied from gdb/Makefile.
16472 (maintainer-clean, realclean, distclean, clean): Call corresponding
16473 make targets in common/Makefile.
16474
7a762829
YQ
164752011-03-04 Yao Qi <yao@codesourcery.com>
16476
16477 * Makefile.in: Remove GNU make feature --directory.
16478
348af9f7
MS
164792011-03-04 Michael Snyder <msnyder@vmware.com>
16480
16481 * server.c (queue_stop_reply): Call xmalloc not malloc.
16482
164832011-03-02 Michael Snyder <msnyder@vmware.com>
16484
16485 * linux-arm-low.c (arm_arch_setup): Replace malloc with xmalloc.
16486
9f72fee2
MS
164872011-02-28 Michael Snyder <msnyder@vmware.com>
16488
588eebee
MS
16489 * tracepoint.c (cmd_qtv): Discard unused value 'packet'.
16490 (cmd_qtframe): Ditto.
16491 (cmd_qtbuffer): Ditto.
16492 (cmd_bigqtbuffer): Ditto.
16493
9f72fee2
MS
16494 * utils.c (decimal2str): Initialize 'width' to nine, then
16495 don't mess with it.
16496
8040bd49
UW
164972011-02-28 Ulrich Weigand <uweigand@de.ibm.com>
16498
16499 * hostio.c (require_data): Free *data, not data.
16500
7e52cbd0
JK
165012011-02-28 Jan Kratochvil <jan.kratochvil@redhat.com>
16502
16503 * hostio.c (require_data): Use free, not xfree.
16504
9130f83e
MS
165052011-02-27 Michael Snyder <msnyder@vmware.com>
16506
4b812f4e
MS
16507 * server.c (handle_query): Discard unused value.
16508
9130f83e
MS
16509 * hostio.c (require_data): Free malloc memory before returning
16510 error.
16511
69d37113
MS
165122011-02-26 Michael Snyder <msnyder@vmware.com>
16513
16514 * linux-low.c (list_threads): Call closedir for dirent.
16515
35f5825a
MS
165162011-02-27 Michael Snyder <msnyder@vmware.com>
16517
2a589cef
MS
16518 * i386-low.c (i386-length_and_rw_bits): Comment the fact that
16519 a case statement falls through.
16520
0adea5f7
MS
16521 * linux-low.c (linux_xfer_siginfo): Fix fencepost error.
16522
35f5825a
MS
16523 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Fix fencepost error
16524 in comparison.
16525
238f1c74
MS
165262011-02-26 Michael Snyder <msnyder@vmware.com>
16527
16528 * utils.c (decimal2str): Eliminate dead code and dead param.
16529 (pulongest): Drop dead param from call to decimal2str.
16530 (plongest): Ditto.
16531
633ff500
JB
165322011-02-24 Joel Brobecker <brobecker@adacore.com>
16533
16534 Revert the following patch (not approved yet):
16535 2011-02-21 Hui Zhu <teawater@gmail.com>
16536 * tracepoint.c (tp_printf): New function.
16537 (eval_agent_expr): Handle gdb_agent_op_printf.
16538
f9c6ff72
HZ
165392011-02-21 Hui Zhu <teawater@gmail.com>
16540
16541 * tracepoint.c (tp_printf): New function.
16542 (eval_agent_expr): Handle gdb_agent_op_printf.
16543
94d5e490
TT
165442011-02-18 Tom Tromey <tromey@redhat.com>
16545
16546 * Makefile.in (tracepoint-ipa.o): Depend on ax.def.
16547 (tracepoint.o): Likewise.
16548 * tracepoint.c (enum gdb_agent_op): Use ax.def.
16549 (gdb_agent_op_names): Likewise.
16550
c7f96d2b
TT
165512011-02-18 Tom Tromey <tromey@redhat.com>
16552
16553 * tracepoint.c (enum gdb_agent_op) <gdb_agent_op_pick,
16554 gdb_agent_op_rot>: New constants.
16555 (gdb_agent_op_names): Add pick and roll.
16556 (eval_agent_expr) <gdb_agent_op_pick, gdb_agent_op_rot>: New
16557 cases.
16558
0feedb2c
JK
165592011-02-15 Jan Kratochvil <jan.kratochvil@redhat.com>
16560
16561 * aclocal.m4: Regenerated with aclocal-1.11.1.
16562
b3b9301e
PA
165632011-02-14 Pedro Alves <pedro@codesourcery.com>
16564
16565 * server.c (handle_qxfer_traceframe_info): New.
16566 (qxfer_packets): Register "traceframe-info".
16567 (handle_query): Report support for qXfer:traceframe-info:read+.
16568 * tracepoint.c (match_blocktype): New.
16569 (traceframe_find_block_type): Rename to ...
16570 (traceframe_walk_blocks): ... this. Add callback filter argument,
16571 and use it.
16572 (traceframe_find_block_type): New, reimplemented on top of
16573 traceframe_walk_blocks.
16574 (build_traceframe_info_xml): New.
16575 (traceframe_read_info): New.
16576 * server.h (traceframe_read_info): Declare.
16577
4f3e6fb7
YQ
165782011-02-11 Yao Qi <yao@codesourcery.com>
16579
16580 * configure.ac: Call AC_PROG_RANLIB.
16581 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
16582 * configure: Regenerate.
16583
764880b7
PA
165842011-02-07 Pedro Alves <pedro@codesourcery.com>
16585
16586 * server.c (gdb_read_memory): Change return semantics to allow
16587 partial transfers.
16588 (handle_search_memory_1): Adjust.
16589 (process_serial_event) <'m' packet>: Handle partial transfers.
16590 * tracepoint.c (traceframe_read_mem): Handle partial transfers.
16591
1c79eb8a
PA
165922011-01-28 Pedro Alves <pedro@codesourcery.com>
16593
16594 * regcache.c (init_register_cache): Initialize
16595 regcache->register_status.
16596 (free_register_cache): Release regcache->register_status.
16597 (regcache_cpy): Copy register_status.
16598 (registers_to_string): Print 'x's for unavailable registers.
16599 (supply_register): Mark the register's status valid or
16600 unavailable, depending on whether a buffer was passed in or not.
16601 (supply_register_zeroed): New.
16602 (supply_regblock): Mark the registers' status valid or
16603 unavailable, depending on whether a buffer was passed in or not.
16604 * regcache.h (REG_UNAVAILABLE, REG_VALID): New defines.
16605 (struct regcache): New `register_status' field.
16606 (supply_register_zeroed): Declare.
16607 * i387-fp.c (i387_xsave_to_cache): Zero out registers using
16608 supply_register_zeroed, rather than passing a NULL buffer to
16609 supply_register.
16610 * tracepoint.c (fetch_traceframe_registers): Update comment.
16611
85724a0e
PA
166122011-01-28 Pedro Alves <pedro@codesourcery.com>
16613
16614 * i387-fp.c (i387_xsave_to_cache): Make passing NULL as register
16615 buffer explicit.
16616
d08aafef
PA
166172011-01-25 Pedro Alves <pedro@codesourcery.com>
16618
16619 * server.h (decode_xfer_write): Change prototype.
16620 * remote-utils.c (decode_xfer_write): Remove `annex' parameter,
16621 and don't extract the annex here.
16622 * server.c (decode_xfer_read): Remove `annex' parameter,
16623 and don't extract the annex here.
16624 (decode_xfer): New.
16625 (struct qxfer): New.
16626 (handle_qxfer_auxv, handle_qxfer_features, handle_qxfer_libraries)
16627 (handle_qxfer_osdata, handle_qxfer_siginfo, handle_qxfer_spu)
16628 (handle_qxfer_statictrace): New functions, abstracted out from
16629 handle_query, and made to use the struct qxfer interface.
16630 (handle_threads_qxfer_proper): Rename to ...
16631 (handle_qxfer_threads_proper): ... this.
16632 (handle_threads_qxfer): Rename to ...
16633 (handle_qxfer_threads): ... this. Adjust.
16634 (qxfer_packets): New array.
16635 (handle_qxfer): New function.
16636 (handle_query): Use handle_qxfer.
16637
493e2a69
MS
166382011-01-05 Michael Snyder <msnyder@msnyder-server.eng.vmware.com>
16639
16640 * gdbreplay.c: Shorten lines of >= 80 columns.
16641 * linux-low.c: Ditto.
16642 * linux-ppc-low.c: Ditto.
16643 * linux-s390-low.c: Ditto.
16644 * linux-sparc-low.c: Ditto.
16645 * linux-x86-low.c: Ditto.
16646 * linux-xtensa-low.c: Ditto.
16647 * mem-break.c: Ditto.
16648 * nto-low.c: Ditto.
16649 * regcache.h: Ditto.
16650 * remote-utils.c: Ditto.
16651 * server.c: Ditto.
16652 * server.h: Ditto.
16653 * thread-db.c: Ditto.
16654 * tracepoint.c: Ditto.
16655 * utils.c: Ditto.
16656 * win32-low.h: Ditto.
16657
44944448
JB
166582011-01-05 Joel Brobecker <brobecker@adacore.com>
16659
16660 * gdbserver/configure.ac, gdbserver/gdbserver.1: Copyright year
16661 update.
16662
71ce852c
JB
166632011-01-01 Joel Brobecker <brobecker@adacore.com>
16664
16665 * server.c (gdbserver_version): Update copyright year in version
16666 output.
16667 * gdbreplay.c (gdbreplay_version): Ditto.
16668
eb826dc6
MF
166692010-12-29 Jie Zhang <jie.zhang@analog.com>
16670
16671 * configure.srv (bfin-*-*linux*): Handle Blackfin/Linux targets.
16672 * linux-bfin-low.c: New file.
16673 * linux-low.c: Define PT_TEXT_ADDR, PT_TEXT_END_ADDR, and
16674 PT_DATA_ADDR for BFIN targets.
16675 * Makefile.in (SFILES): Add linux-bfin-low.c.
16676 (clean): Remove reg-bfin.c.
16677 (linux-bfin-low.o, reg-bfin.o, reg-bfin.c): New targets.
16678 * README: Mention supported Blackfin targets.
16679
39ab222a
MF
166802010-12-23 Mike Frysinger <vapier@gentoo.org>
16681
16682 * .gitignore: New file.
16683
a1f2ce7d
MF
166842010-11-16 Mike Frysinger <vapier@gentoo.org>
16685
16686 * linux-low.c (linux_tracefork_child): Add char* cast to arg.
16687
f474844c
JZ
166882010-10-22 Jie Zhang <jie@codesourcery.com>
16689
16690 * Makefile.in: Add FLAGS_TO_PASS variable.
16691 (install): Remove dependency of install-only and recursively
16692 invoke make for install-only.
16693
f1048712
DE
166942010-10-04 Doug Evans <dje@google.com>
16695
16696 * Makefile.in (uninstall): Use $(DESTDIR).
16697
b53a1623
PA
166982010-09-24 Pedro Alves <pedro@codesourcery.com>
16699
e6ee044d
PA
16700 PR gdb/11842
16701
b53a1623
PA
16702 * linux-x86-low.c (compat_siginfo_from_siginfo)
16703 (siginfo_from_compat_siginfo): Also copy si_pid and si_uid when
16704 si_code is < 0. Check for si_code == SI_TIMER before checking for
16705 si_code < 0.
16706
fa1bd1e4
JB
167072010-09-13 Joel Brobecker <brobecker@adacore.com>
16708
16709 * lynx-i386-low.c: New file.
16710 * configure.srv: Add handling of i[34567]86-*-lynxos* targets.
16711
47fac8f8
JB
167122010-09-13 Joel Brobecker <brobecker@adacore.com>
16713
16714 * lynx-low.c (ptrace_request_to_str): Remove handling for
16715 request values that have been removed in LynxOS 5.x.
16716
1adfc54d
JB
167172010-09-13 Joel Brobecker <brobecker@adacore.com>
16718
16719 * lynx-low.c, lynx-ppc-loc.c: Include <sys/ptrace.h> instead of
16720 <ptrace.h>
16721
c2a66c29
NS
167222010-09-09 Nathan Sidwell <nathan@codesourcery.com>
16723
16724 * configure.ac: Add --enable-inprocess-agent option.
16725 * configure: Rebuilt.
16726
32fcada3
YQ
167272010-09-06 Yao Qi <yao@codesourcery.com>
16728
16729 * linux-low.c (linux_kill): Remove unused variable.
16730 (linux_stabilize_threads): Likewise.
16731 * server.c (start_inferior): Likewise.
16732 (queue_stop_reply_callback): Likewise.
16733 * tracepoint.c (do_action_at_tracepoint): Likewise.
16734
0cccb683
YQ
167352010-09-06 Yao Qi <yao@codesourcery.com>
16736
16737 * linux-low.c (maybe_move_out_of_jump_pad): Restore current_inferior
16738 on return.
16739
423ec54c
JK
167402010-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
16741
16742 * target.c (mywait) <TARGET_WAITKIND_EXITED>: Fix to use INTEGER.
16743
12ac6819
PA
167442010-09-06 Pedro Alves <pedro@codesourcery.com>
16745
16746 * Makefile.in (install-only): Replace $IPA_DEPFILES with
16747 "$(IPA_DEPFILES)".
16748
8ed54b31
JB
167492010-09-01 Joel Brobecker <brobecker@adacore.com>
16750
16751 * gdbserver/lynx-low.c, gdbserver/lynx-low.h,
16752 gdbserver/lynx-ppc-low.c: New files.
16753 * Makefile.in (lynx_low_h): New variable.
16754 (lynx-low.o, lynx-ppc-low.o): New rules.
16755 * configure.ac: On LynxOS, link with -lnetinet.
16756 * configure.srv: Add handling of powerpc-*-lynxos* targets.
16757 * configure: regenerate.
16758
bb0116a4
JB
167592010-09-01 Joel Brobecker <brobecker@adacore.com>
16760
16761 * Makefile.in (vasprintf.o, vsnprintf.o): New rules.
16762 * configure.ac: Add check for vasprintf and vsnprintf.
16763 * configure, config.in: Regenerate.
16764 * server.h (vasprintf, vsnprintf): Add conditional declarations.
16765
a778ab81 167662010-09-01 Joel Brobecker <brobecker@adacore.com>
16767
16768 * gdbreplay.c: Move include of alloca.h up, next to include of
16769 malloc.h.
16770 * server.h: Add include of malloc.h.
16771 * mem-break.c: Remove include of malloc.h.
16772 * server.c, tracepoint.c, utils.c, win32-low.c: Likewise.
16773
8b034a19 167742010-09-01 Joel Brobecker <brobecker@adacore.com>
16775
16776 * Makefile.in (memmem.o): Build with -Wno-error.
16777
167782010-09-01 Joel Brobecker <brobecker@adacore.com>
16779
16780 * utils.c (xsnprintf): Make non-static.
16781 * server.h: Add xsnprintf declaration.
16782 * linux-low.c, nto-low.c, target.c, thread-db.c, tracepoint.c:
16783 replace calls to snprintf by calls to xsnprintf throughout.
16784
167852010-09-01 Joel Brobecker <brobecker@adacore.com>
16786
16787 * configure.ac: Add configure check for alloca.
16788 * configure, config.in: Regenerate.
16789 * server.h: Include alloca.h if it exists.
16790 * gdbreplay.c: Include alloca.h if it exists.
16791
1a981360
PA
167922010-08-28 Pedro Alves <pedro@codesourcery.com>
16793
16794 * linux-low.c (__SIGRTMIN): Define if not already defined.
16795 (linux_create_inferior): Check for __ANDROID__ rather than
16796 __SIGRTMIN.
16797 (enqueue_one_deferred_signal): Don't requeue non-RT signals that
16798 are already deferred.
16799 (linux_wait_1): Check for __ANDROID__ rather than __SIGRTMIN.
16800 (linux_resume_one_thread): Don't queue a SIGSTOP if the lwp is
16801 stopped and already has a pending signal to report.
16802 (proceed_one_lwp): : Don't queue a SIGSTOP if the lwp already has
16803 a pending signal to report or is moving out of a jump pad.
16804 (linux_init_signals): Check for __ANDROID__ rather than
16805 __SIGRTMIN.
16806
b4d51a55
PA
168072010-08-28 Pedro Alves <pedro@codesourcery.com>
16808
16809 * linux-low.c (linux_stabilize_threads): Wrap debug output in a
16810 debug_threads check. Avoid a linear search when not doing debug
16811 output.
16812
ec48365d
PA
168132010-08-27 Pedro Alves <pedro@codesourcery.com>
16814
16815 * event-loop.c (event_handle_func): Adjust to use gdb_fildes_t.
16816 (struct gdb_event) <fd>: Change type to gdb_fildes_t.
16817 (struct file_handler) <fd>: Change type to gdb_fildes_t.
16818 (process_event): Change local fd's type to gdb_fildes_t.
16819 (create_file_handler): Adjust prototype.
16820 (delete_file_handler): Adjust prototype.
16821 (handle_file_event): Adjust prototype. Use pfildes.
16822 (create_file_event): Adjsut prototype.
16823 * remote-utils.c (remote_desc, listen_desc): Change type to
16824 gdb_fildes_t.
16825 * server.h: New gdb_fildes_t typedef.
16826 [USE_WIN32API]: Include winsock2.h.
16827 (delete_file_handler, add_file_handler): Adjust prototypes.
16828 (pfildes): Declare.
16829 * utils.c (pfildes): New.
16830
854d88f0
PA
168312010-08-27 Pedro Alves <pedro@codesourcery.com>
16832
16833 * configure.ac (build_warnings): Add -Wno-char-subscripts.
16834 * configure: Regenerate.
16835
0146f85b
PA
168362010-08-27 Pedro Alves <pedro@codesourcery.com>
16837
16838 * linux-low.c (linux_unprepare_to_access_memory): Rename to ...
16839 (linux_done_accessing_memory): ... this.
16840 (linux_target_ops): Adjust.
16841 * linux-x86-low.c (x86_insert_point, x86_remove_point): Adjust.
16842 * nto-low.c (nto_target_ops): Adjust comment.
16843 * server.c (gdb_read_memory, gdb_write_memory): Adjust.
16844 * spu-low.c (spu_target_ops): Adjust comment.
16845 * target.h (target_ops): Rename unprepare_to_access_memory field
16846 to done_accessing_memory.
16847 (unprepare_to_access_memory): Rename to ...
16848 (done_accessing_memory): ... this.
16849
90d74c30
PA
168502010-08-26 Pedro Alves <pedro@codesourcery.com>
16851
16852 * linux-low.c (linux_prepare_to_access_memory): New.
16853 (linux_unprepare_to_access_memory): New.
16854 (linux_target_ops): Install them.
16855 * server.c (read_memory): Rename to ...
16856 (gdb_read_memory): ... this. Use
16857 prepare_to_access_memory/prepare_to_access_memory.
16858 (write_memory): Rename to ...
16859 (gdb_write_memory): ... this. Use
16860 prepare_to_access_memory/prepare_to_access_memory.
16861 (handle_search_memory_1): Adjust.
16862 (process_serial_event): Adjust.
16863 * target.h (struct target_ops): New fields
16864 prepare_to_access_memory and unprepare_to_access_memory.
16865 (prepare_to_access_memory, unprepare_to_access_memory): New.
16866 * linux-x86-low.c (x86_insert_point, x86_remove_point): Use
16867 prepare_to_access_memory/prepare_to_access_memory.
16868 * nto-low.c (nto_target_ops): Adjust.
16869 * spu-low.c (spu_target_ops): Adjust.
16870 * win32-low.c (win32_target_ops): Adjust.
16871
fd467969
PA
168722010-08-26 Pedro Alves <pedro@codesourcery.com>
16873
16874 * Makefile.in (WARN_CFLAGS): Get it from configure.
16875 (WERROR_CFLAGS): New.
16876 (INTERNAL_CFLAGS): Add WERROR_CFLAGS.
16877 * configure.ac: Introduce --enable-werror, which adds -Werror to
16878 the compiler command line. Enabled by default. Disable with
16879 --disable-werror. Add -Wdeclaration-after-statement
16880 Wpointer-arith and -Wformat-nonliteral to warning flags.
16881 * configure: Regenerate.
16882
331e2f5f
PA
168832010-08-26 Pedro Alves <pedro@codesourcery.com>
16884
16885 * mem-break.c [HAVE_MALLOC_H]: Include malloc.h.
16886
e581f2b4
PA
168872010-08-26 Pedro Alves <pedro@codesourcery.com>
16888
16889 * gdbreplay.c (remote_error): New.
16890 (gdbchar): New.
16891 (expect): Use gdbchar. Check for error reading from GDB.
16892 Clarify sync error output.
16893 (play): Check for errors writing to GDB.
16894 * linux-low.c (sigchld_handler): Really ignore `write' errors.
16895 * remote-utils.c (getpkt): Check for errors writing to the remote
16896 descriptor.
16897
3c11dd79
PA
168982010-08-25 Pedro Alves <pedro@codesourcery.com>
16899
16900 * linux-low.c (linux_wait_1): Move non-debugging code out of
16901 `debug_threads' control.
16902
d20a8ad9
PA
169032010-08-25 Pedro Alves <pedro@codesourcery.com>
16904
16905 * linux-low.c (linux_wait_1): Don't set last_status here.
16906 * server.c (push_event, queue_stop_reply_callback): Assert we're
16907 not pushing a TARGET_WAITKIND_IGNORE event.
16908 (start_inferior, start_inferior, attach_inferior, handle_v_cont)
16909 (myresume, handle_target_event): Set the thread's last_resume_kind
16910 and last_status from the target returned status.
16911
964e4306
PA
169122010-08-25 Pedro Alves <pedro@codesourcery.com>
16913
16914 PR threads/10729
16915
16916 * linux-x86-low.c (update_debug_registers_callback): New.
16917 (i386_dr_low_set_addr): Use it.
16918 (i386_dr_low_get_addr): New.
16919 (i386_dr_low_set_control): Use update_debug_registers_callback.
16920 (i386_dr_low_get_control): New.
16921 (i386_dr_low_get_status): Adjust.
16922 * linux-low.c (linux_stop_lwp): New.
16923 * linux-low.h (linux_stop_lwp): Declare.
16924
16925 * i386-low.c (I386_DR_GET_RW_LEN): Take the dr7 contents as
16926 argument instead of a i386_debug_reg_state.
16927 (I386_DR_WATCH_HIT): Take the dr6 contents as argument instead of
16928 a i386_debug_reg_state.
16929 (i386_insert_aligned_watchpoint): Adjust.
16930 (i386_remove_aligned_watchpoint): Adjust.
16931 (i386_low_stopped_data_address): Read the debug registers from the
16932 inferior instead of from the mirrors.
16933 * i386-low.h (struct i386_debug_reg_state): Extend comment.
16934 (i386_dr_low_get_addr): Declare.
16935 (i386_dr_low_get_control): Declare.
16936 (i386_dr_low_get_status): Change prototype.
16937
16938 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): New globals.
16939 (i386_dr_low_get_addr): New.
16940 (i386_dr_low_get_control): New.
16941 (i386_dr_low_get_status): Adjust prototype. Return
16942 dr_status_mirror.
16943 (i386_initial_stuff): Clear dr_status_mirror and
16944 dr_control_mirror.
16945 (i386_get_thread_context): Adjust.
16946 (i386_set_thread_context): Adjust.
16947 (i386_thread_added): Adjust.
16948
5f21a75b
PA
169492010-08-24 Pedro Alves <pedro@codesourcery.com>
16950
16951 * linux-low.h (linux_thread_area): Delete declaration.
16952
3e4c1235
TS
169532010-08-11 Thomas Schwinge <thomas@codesourcery.com>
16954
16955 * linux-low.c (linux_wait_1): Correctly return the ptid of the child
16956 after its termination.
16957
1971b033
PA
169582010-08-09 Pedro Alves <pedro@codesourcery.com>
16959
16960 * linux-low.c (gdb_wants_lwp_stopped): Delete.
16961 (gdb_wants_all_stopped): Delete.
16962 (linux_wait_1): Don't call them.
16963 * server.c (handle_v_cont): Tag all threads as want-stopped.
16964 (gdb_wants_thread_stopped): Fix comments. Tag the thread that
16965 stopped as "client-wants-stopped".
16966
310444ac
PA
169672010-07-31 Pedro Alves <pedro@codesourcery.com>
16968
16969 * Makefile.in (signals_h): New.
16970 (server_h): Depend on it.
16971 (server.o): Don't depend on $(signals_def).
16972 (signals.o): Depend on $(signals_def).
16973
a19cae16
JK
169742010-07-31 Jan Kratochvil <jan.kratochvil@redhat.com>
16975
16976 * Makefile.in (signals_def): New.
16977 (server_h): Append include/gdb/signals.h and signals_def.
16978 (server.o): Append signals_def.
16979
30d50328
JK
169802010-07-25 Jan Kratochvil <jan.kratochvil@redhat.com>
16981
16982 * server.c (handle_target_event): Use target_signal_to_host for
16983 resume_info.sig initialization.
16984 * target.h (struct thread_resume) <sig>: New comment.
16985
5c3216e2
OS
169862010-07-20 Ozkan Sezer <sezeroz@gmail.com>
16987
c6f46ca0
OS
16988 * server.c (handle_query): strcpy() the returned string from paddress()
16989 instead of sprintf().
5c3216e2
OS
16990 * utils.c (paddress): Return phex_nz().
16991
6bd31874
JB
169922010-07-07 Joel Brobecker <brobecker@adacore.com>
16993
16994 * server.c (handle_v_cont): Call mourn_inferior if process
16995 just exited.
16996 (myresume): Likewise.
16997
0fb4aa4b
PA
169982010-07-01 Pedro Alves <pedro@codesourcery.com>
16999
17000 Static tracepoints, and integration with UST.
17001
17002 * configure.ac: Handle --with-ust. substitute ustlibs and ustinc.
17003 * mem-break.c (uninsert_all_breakpoints)
17004 (reinsert_all_breakpoints): New.
17005 * mem-break.h (reinsert_all_breakpoints, uninsert_all_breakpoints):
17006 * tracepoint.c (ust_loaded, helper_thread_id, cmd_buf): New.
17007 (gdb_agent_ust_loaded, helper_thread_id)
17008 (gdb_agent_helper_thread_id): New macros.
17009 (struct ipa_sym_addresses): Add addr_ust_loaded,
17010 addr_helper_thread_id, addr_cmd_buf.
17011 (symbol_list): Add ust_loaded, helper_thread_id, cmd_buf.
17012 (in_process_agent_loaded_ust): New.
17013 (write_e_ust_not_loaded): New.
17014 (maybe_write_ipa_ust_not_loaded): New.
17015 (struct collect_static_trace_data_action): New.
17016 (enum tracepoint_type) <static_tracepoint>: New.
17017 (struct tracepoint) <handle>: Mention static tracepoints.
17018 (struct static_tracepoint_ctx): New.
17019 (CMD_BUF_SIZE): New.
17020 (add_tracepoint_action): Handle static tracepoint actions.
17021 (unprobe_marker_at): New.
17022 (clear_installed_tracepoints): Handle static tracepoints.
17023 (cmd_qtdp): Handle static tracepoints.
17024 (probe_marker_at): New.
17025 (cmd_qtstart): Handle static tracepoints.
17026 (response_tracepoint): Handle static tracepoints.
17027 (cmd_qtfstm, cmd_qtsstm, cmd_qtstmat): New.
17028 (handle_tracepoint_query): Handle qTfSTM, qTsSTM and qTSTMat.
17029 (get_context_regcache): Handle static tracepoints.
17030 (do_action_at_tracepoint): Handle static tracepoint actions.
17031 (traceframe_find_block_type): Handle static trace data blocks.
17032 (traceframe_read_sdata): New.
17033 (download_tracepoints): Download static tracepoint actions.
17034 [HAVE_UST] Include ust/ust.h, dlfcn.h, sys/socket.h, and sys/un.h.
17035 (GDB_PROBE_NAME): New.
17036 (ust_ops): New.
17037 (GET_UST_SYM): New.
17038 (USTF): New.
17039 (dlsym_ust): New.
17040 (ust_marker_to_static_tracepoint): New.
17041 (gdb_probe): New.
17042 (collect_ust_data_at_tracepoint): New.
17043 (gdb_ust_probe): New.
17044 (UNIX_PATH_MAX, SOCK_DIR): New.
17045 (gdb_ust_connect_sync_socket): New.
17046 (resume_thread, stop_thread): New.
17047 (run_inferior_command): New.
17048 (init_named_socket): New.
17049 (gdb_ust_socket_init): New.
17050 (cstr_to_hexstr): New.
17051 (next_st): New.
17052 (first_marker, next_marker): New.
17053 (response_ust_marker): New.
17054 (cmd_qtfstm, cmd_qtsstm): New.
17055 (unprobe_marker_at, probe_marker_at): New.
17056 (cmd_qtstmat, gdb_ust_thread): New.
17057 (gdb_ust_init): New.
17058 (initialize_tracepoint_ftlib): Call gdb_ust_init.
17059 * linux-amd64-ipa.c [HAVE_UST]: Include ust/processor.h
17060 (ST_REGENTRY): New.
17061 (x86_64_st_collect_regmap): New.
17062 (X86_64_NUM_ST_COLLECT_GREGS): New.
17063 (AMD64_RIP_REGNUM): New.
17064 (supply_static_tracepoint_registers): New.
17065 * linux-i386-ipa.c [HAVE_UST]: Include ust/processor.h
17066 (ST_REGENTRY): New.
17067 (i386_st_collect_regmap): New.
17068 (i386_NUM_ST_COLLECT_GREGS): New.
17069 (supply_static_tracepoint_registers): New.
17070 * server.c (handle_query): Handle qXfer:statictrace:read.
17071 <qSupported>: Report support for StaticTracepoints, and
17072 qXfer:statictrace:read features.
17073 * server.h (traceframe_read_sdata)
17074 (supply_static_tracepoint_registers): Declare.
17075 * remote-utils.c (convert_int_to_ascii, hexchars, ishex, tohex)
17076 (unpack_varlen_hex): Include in IPA build.
17077 * Makefile.in (ustlibs, ustinc): New.
17078 (IPA_OBJS): Add remote-utils-ipa.o.
17079 ($(IPA_LIB)): Link -ldl and -lpthread.
17080 (UST_CFLAGS): New.
17081 (IPAGENT_CFLAGS): Add UST_CFLAGS.
17082 * config.in, configure: Regenerate.
17083
9e4344e5
PA
170842010-06-20 Ian Lance Taylor <iant@google.com>
17085 Pedro Alves <pedro@codesourcery.com>
17086
17087 * linux-x86-low.c (always_true): Delete.
17088 (EMIT_ASM, EMIT_ASM32): Use an uncondition asm jmp instead of
17089 trying to fool the compiler with always_true.
17090
c6beb2cb
PA
170912010-06-20 Pedro Alves <pedro@codesourcery.com>
17092
17093 * tracepoint.c (condition_true_at_tracepoint): Don't run compiled
17094 conditions in gdbserver.
17095
d2ed6730
UW
170962010-06-19 Ulrich Weigand <uweigand@de.ibm.com>
17097
17098 * spu-low.c (spu_read_memory): Wrap around local store limit.
17099 (spu_write_memory): Likewise.
17100
4e29fb54
PA
171012010-06-15 Pedro Alves <pedro@codesourcery.com>
17102
17103 * linux-x86-low.c (amd64_emit_const, amd64_emit_void_call_2)
17104 (i386_emit_const, i386_emit_void_call_2): Replace int64_t uses with
17105 LONGEST uses.
17106 * server.h (struct emit_ops): Replace int64_t uses with LONGEST
17107 uses.
17108 * tracepoint.c (emit_const, emit_void_call_2): Replace int64_t
17109 uses with LONGEST uses.
17110
6a271cae
PA
171112010-06-14 Stan Shebs <stan@codesourcery.com>
17112 Pedro Alves <pedro@codesourcery.com>
17113
17114 Bytecode compiler.
17115
17116 * linux-x86-low.c: Include limits.h.
17117 (add_insns): New.
17118 (always_true): New.
17119 (EMIT_ASM): New.
17120 (EMIT_ASM32): New.
17121 (amd64_emit_prologue, amd64_emit_epilogue, amd64_emit_add)
17122 (amd64_emit_sub, amd64_emit_mul, amd64_emit_lsh)
17123 (amd64_emit_rsh_signed, amd64_emit_rsh_unsigned, amd64_emit_ext,
17124 (amd64_emit_log_not, amd64_emit_bit_and, amd64_emit_bit_or)
17125 (amd64_emit_bit_xor, amd64_emit_bit_not, amd64_emit_equal,
17126 (amd64_emit_less_signed, amd64_emit_less_unsigned, amd64_emit_ref,
17127 (amd64_emit_if_goto, amd64_emit_goto, amd64_write_goto_address)
17128 (amd64_emit_const, amd64_emit_call, amd64_emit_reg)
17129 (amd64_emit_pop, amd64_emit_stack_flush, amd64_emit_zero_ext)
17130 (amd64_emit_swap, amd64_emit_stack_adjust, amd64_emit_int_call_1)
17131 (amd64_emit_void_call_2): New.
17132 (amd64_emit_ops): New.
17133 (i386_emit_prologue, i386_emit_epilogue, i386_emit_add)
17134 (i386_emit_sub,i386_emit_mul, i386_emit_lsh, i386_emit_rsh_signed)
17135 (i386_emit_rsh_unsigned, i386_emit_ext, i386_emit_log_not)
17136 (i386_emit_bit_and, i386_emit_bit_or, i386_emit_bit_xor)
17137 (i386_emit_bit_not, i386_emit_equal, i386_emit_less_signed)
17138 (i386_emit_less_unsigned, i386_emit_ref, i386_emit_if_goto)
17139 (i386_emit_goto, i386_write_goto_address, i386_emit_const)
17140 (i386_emit_call, i386_emit_reg, i386_emit_pop)
17141 (i386_emit_stack_flush, i386_emit_zero_ext, i386_emit_swap)
17142 (i386_emit_stack_adjust, i386_emit_int_call_1)
17143 (i386_emit_void_call_2): New.
17144 (i386_emit_ops): New.
17145 (x86_emit_ops): New.
17146 (the_low_target): Install x86_emit_ops.
17147 * server.h (struct emit_ops): New.
17148 (get_raw_reg_func_addr): Declare.
17149 (current_insn_ptr, emit_error): Declare.
17150 * tracepoint.c (get_raw_reg, get_trace_state_variable_value)
17151 (set_trace_state_variable_value): New defines.
17152 (struct ipa_sym_addresses): New fields addr_get_raw_reg,
17153 addr_get_trace_state_variable_value and
17154 addr_set_trace_state_variable_value.
17155 (symbol_list): New fields for get_raw_reg,
17156 get_trace_state_variable_value and set_trace_state_variable_value.
17157 (condfn): New typedef.
17158 (struct tracepoint): New field `compiled_cond'.
17159 (do_action_at_tracepoint): Clear compiled_cond.
17160 (get_trace_state_variable_value, set_trace_state_variable_value):
17161 Export in the IPA.
17162 (condition_true_at_tracepoint): If there's a compiled condition,
17163 run that.
17164 (current_insn_ptr, emit_error): New globals.
17165 (struct bytecode_address): New.
17166 (get_raw_reg_func_addr): New.
17167 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul)
17168 (emit_lsh, emit_rsh_signed, emit_rsh_unsigned, emit_ext)
17169 (emit_log_not, emit_bit_and, emit_bit_or, emit_bit_xor)
17170 (emit_bit_not, emit_equal, emit_less_signed, emit_less_unsigned)
17171 (emit_ref, emit_if_goto, emit_goto, write_goto_address, emit_const)
17172 (emit_reg, emit_pop, emit_stack_flush, emit_zero_ext, emit_swap)
17173 (emit_stack_adjust, emit_int_call_1, emit_void_call_2): New.
17174 (compile_tracepoint_condition, compile_bytecodes): New.
17175 * target.h (emit_ops): Forward declare.
17176 (struct target_ops): New field emit_ops.
17177 (target_emit_ops): New.
17178 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): New.
17179 * linux-i386-ipa.c (gdb_agent_get_raw_reg): New.
17180 * linux-low.c (linux_emit_ops): New.
17181 (linux_target_ops): Install it.
17182 * linux-low.h (struct linux_target_ops): New field emit_ops.
17183
92b72907
UW
171842010-06-14 Ulrich Weigand <uweigand@de.ibm.com>
17185
17186 * linux-ppc-low.c (ppc_arch_setup): Use private regcache to test MSR.
17187 * linux-s390-low.c (ppc_arch_setup): Use private regcache to test PSW.
17188
fa593d66
PA
171892010-06-01 Pedro Alves <pedro@codesourcery.com>
17190 Stan Shebs <stan@codesourcery.com>
17191
17192 * Makefile.in (IPA_DEPFILES, extra_libraries): New.
17193 (all): Depend on $(extra_libraries).
17194 (install-only): Install the IPA.
17195 (IPA_OBJS, IPA_LIB): New.
17196 (clean): Remove the IPA lib.
17197 (IPAGENT_CFLAGS): New.
17198 (tracepoint-ipa.o, utils-ipa.o, remote-utils-ipa.o)
17199 (regcache-ipa.o, i386-linux-ipa.o, linux-i386-ipa.o)
17200 (linux-amd64-ipa.o, amd64-linux-ipa.o): New rules.
17201 * linux-amd64-ipa.c, linux-i386-ipa.c: New files.
17202 * configure.ac: Check for atomic builtins support in the compiler.
17203 (IPA_DEPFILES, extra_libraries): Define.
17204 * configure.srv (ipa_obj): Add description.
17205 (ipa_i386_linux_regobj, ipa_amd64_linux_regobj): Define.
17206 (i[34567]86-*-linux*): Set ipa_obj.
17207 (x86_64-*-linux*): Set ipa_obj.
17208 * linux-low.c (stabilizing_threads): New.
17209 (supports_fast_tracepoints): New.
17210 (linux_detach): Stabilize threads before detaching.
17211 (handle_tracepoints): Handle internal tracing breakpoints. Assert
17212 the lwp is either not stabilizing, or is moving out of a jump pad.
17213 (linux_fast_tracepoint_collecting): New.
17214 (maybe_move_out_of_jump_pad): New.
17215 (enqueue_one_deferred_signal): New.
17216 (dequeue_one_deferred_signal): New.
17217 (linux_wait_for_event_1): If moving out of a jump pad, defer
17218 pending signals to later.
17219 (linux_stabilize_threads): New.
17220 (linux_wait_1): Check if threads need moving out of jump pads, and
17221 do it if so.
17222 (stuck_in_jump_pad_callback): New.
17223 (move_out_of_jump_pad_callback): New.
17224 (lwp_running): New.
17225 (linux_resume_one_lwp): Handle moving out of jump pads.
17226 (linux_set_resume_request): Dequeue deferred signals.
17227 (need_step_over_p): Also step over fast tracepoint jumps.
17228 (start_step_over): Also uninsert fast tracepoint jumps.
17229 (finish_step_over): Also reinsert fast tracepoint jumps.
17230 (linux_install_fast_tracepoint_jump): New.
17231 (linux_target_ops): Install linux_stabilize_threads and
17232 linux_install_fast_tracepoint_jump_pad.
17233 * linux-low.h (linux_target_ops) <get_thread_area,
17234 install_fast_tracepoint_jump_pad>: New fields.
17235 (struct lwp_info) <collecting_fast_tracepoint,
17236 pending_signals_to_report, exit_jump_pad_bkpt>: New fields.
17237 (linux_get_thread_area): Declare.
17238 * linux-x86-low.c (jump_insn): New.
17239 (x86_get_thread_area): New.
17240 (append_insns): New.
17241 (push_opcode): New.
17242 (amd64_install_fast_tracepoint_jump_pad): New.
17243 (i386_install_fast_tracepoint_jump_pad): New.
17244 (x86_install_fast_tracepoint_jump_pad): New.
17245 (the_low_target): Install x86_get_thread_area and
17246 x86_install_fast_tracepoint_jump_pad.
17247 * mem-break.c (set_raw_breakpoint_at): Use read_inferior_memory.
17248 (struct fast_tracepoint_jump): New.
17249 (fast_tracepoint_jump_insn): New.
17250 (fast_tracepoint_jump_shadow): New.
17251 (find_fast_tracepoint_jump_at): New.
17252 (fast_tracepoint_jump_here): New.
17253 (delete_fast_tracepoint_jump): New.
17254 (set_fast_tracepoint_jump): New.
17255 (uninsert_fast_tracepoint_jumps_at): New.
17256 (reinsert_fast_tracepoint_jumps_at): New.
17257 (set_breakpoint_at): Use write_inferior_memory.
17258 (uninsert_raw_breakpoint): Use write_inferior_memory.
17259 (check_mem_read): Mask out fast tracepoint jumps.
17260 (check_mem_write): Mask out fast tracepoint jumps.
17261 * mem-break.h (struct fast_tracepoint_jump): Forward declare.
17262 (set_fast_tracepoint_jump): Declare.
17263 (delete_fast_tracepoint_jump)
17264 (fast_tracepoint_jump_here, uninsert_fast_tracepoint_jumps_at)
17265 (reinsert_fast_tracepoint_jumps_at): Declare.
17266 * regcache.c: Don't compile many functions when building the
17267 in-process agent library.
17268 (init_register_cache) [IN_PROCESS_AGENT]: Don't allow allocating
17269 the register buffer in the heap.
17270 (free_register_cache): If the register buffer isn't owned by the
17271 regcache, don't free it.
17272 (set_register_cache) [IN_PROCESS_AGENT]: Don't re-alocate
17273 pre-existing register caches.
17274 * remote-utils.c (convert_int_to_ascii): Constify `from' parameter
17275 type.
17276 (convert_ascii_to_int): : Constify `from' parameter type.
17277 (decode_M_packet, decode_X_packet): Replace the `to' parameter by
17278 a `to_p' pointer to pointer parameter. If TO_P is NULL, malloc
17279 the needed buffer in-place.
17280 (relocate_instruction): New.
17281 * server.c (handle_query) <qSymbols>: If the target supports
17282 tracepoints, give it a chance of looking up symbols. Report
17283 support for fast tracepoints.
17284 (handle_status): Stabilize threads.
17285 (process_serial_event): Adjust.
17286 * server.h (struct fast_tracepoint_jump): Forward declare.
17287 (struct process_info) <fast_tracepoint_jumps>: New field.
17288 (convert_ascii_to_int, convert_int_to_ascii): Adjust.
17289 (decode_X_packet, decode_M_packet): Adjust.
17290 (relocate_instruction): Declare.
17291 (in_process_agent_loaded): Declare.
17292 (tracepoint_look_up_symbols): Declare.
17293 (struct fast_tpoint_collect_status): Declare.
17294 (fast_tracepoint_collecting): Declare.
17295 (force_unlock_trace_buffer): Declare.
17296 (handle_tracepoint_bkpts): Declare.
17297 (initialize_low_tracepoint)
17298 (supply_fast_tracepoint_registers) [IN_PROCESS_AGENT]: Declare.
17299 * target.h (struct target_ops) <stabilize_threads,
17300 install_fast_tracepoint_jump_pad>: New fields.
17301 (stabilize_threads, install_fast_tracepoint_jump_pad): New.
17302 * tracepoint.c [HAVE_MALLOC_H]: Include malloc.h.
17303 [HAVE_STDINT_H]: Include stdint.h.
17304 (trace_debug_1): Rename to ...
17305 (trace_vdebug): ... this.
17306 (trace_debug): Rename to ...
17307 (trace_debug_1): ... this. Add `level' parameter.
17308 (trace_debug): New.
17309 (ATTR_USED, ATTR_NOINLINE): New.
17310 (IP_AGENT_EXPORT): New.
17311 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
17312 (collecting, gdb_collect, stop_tracing, flush_trace_buffer)
17313 (about_to_request_buffer_space, trace_buffer_is_full)
17314 (stopping_tracepoint, expr_eval_result, error_tracepoint)
17315 (tracepoints, tracing, trace_buffer_ctrl, trace_buffer_ctrl_curr)
17316 (trace_buffer_lo, trace_buffer_hi, traceframe_read_count)
17317 (traceframe_write_count, traceframes_created)
17318 (trace_state_variables)
17319 New renaming defines.
17320 (struct ipa_sym_addresses): New.
17321 (STRINGIZE_1, STRINGIZE, IPA_SYM): New.
17322 (symbol_list): New.
17323 (ipa_sym_addrs): New.
17324 (all_tracepoint_symbols_looked_up): New.
17325 (in_process_agent_loaded): New.
17326 (write_e_ipa_not_loaded): New.
17327 (maybe_write_ipa_not_loaded): New.
17328 (tracepoint_look_up_symbols): New.
17329 (debug_threads) [IN_PROCESS_AGENT]: New.
17330 (read_inferior_memory) [IN_PROCESS_AGENT]: New.
17331 (UNKNOWN_SIDE_EFFECTS): New.
17332 (stop_tracing): New.
17333 (flush_trace_buffer): New.
17334 (stop_tracing_bkpt): New.
17335 (flush_trace_buffer_bkpt): New.
17336 (read_inferior_integer): New.
17337 (read_inferior_uinteger): New.
17338 (read_inferior_data_pointer): New.
17339 (write_inferior_data_pointer): New.
17340 (write_inferior_integer): New.
17341 (write_inferior_uinteger): New.
17342 (struct collect_static_trace_data_action): Delete.
17343 (enum tracepoint_type): New.
17344 (struct tracepoint) <type>: New field `type'.
43aaf8b6
PA
17345 <actions_str, step_actions, step_actions_str>: Only include in
17346 GDBserver.
fa593d66
PA
17347 <orig_size, obj_addr_on_target, adjusted_insn_addr>
17348 <adjusted_insn_addr_end, jump_pad, jump_pad_end>: New fields.
17349 (tracepoints): Use IP_AGENT_EXPORT.
17350 (last_tracepoint): Don't include in the IPA.
17351 (stopping_tracepoint): Use IP_AGENT_EXPORT.
17352 (trace_buffer_is_full): Use IP_AGENT_EXPORT.
17353 (alloced_trace_state_variables): New.
17354 (trace_state_variables): Use IP_AGENT_EXPORT.
17355 (traceframe_t): Delete unused variable.
17356 (circular_trace_buffer): Don't include in the IPA.
17357 (trace_buffer_start): Delete.
17358 (struct trace_buffer_control): New.
17359 (trace_buffer_free): Delete.
17360 (struct ipa_trace_buffer_control): New.
17361 (GDBSERVER_FLUSH_COUNT_MASK, GDBSERVER_FLUSH_COUNT_MASK_PREV)
17362 (GDBSERVER_FLUSH_COUNT_MASK_CURR, GDBSERVER_UPDATED_FLUSH_COUNT_BIT):
17363 New.
17364 (trace_buffer_ctrl): New.
17365 (TRACE_BUFFER_CTRL_CURR): New.
17366 (trace_buffer_start, trace_buffer_free, trace_buffer_end_free):
17367 Reimplement as macros.
17368 (trace_buffer_wrap): Delete.
17369 (traceframe_write_count, traceframe_read_count)
17370 (traceframes_created, tracing): Use IP_AGENT_EXPORT.
17371 (struct tracepoint_hit_ctx) <type>: New field.
17372 (struct fast_tracepoint_ctx): New.
17373 (memory_barrier): New.
17374 (cmpxchg): New.
17375 (record_tracepoint_error): Update atomically in the IPA.
17376 (clear_inferior_trace_buffer): New.
17377 (about_to_request_buffer_space): New.
17378 (trace_buffer_alloc): Handle GDBserver and inferior simulatenous
17379 updating the same buffer.
17380 (add_tracepoint): Default the tracepoint's type to trap
17381 tracepoint, and orig_size to -1.
17382 (get_trace_state_variable) [IN_PROCESS_AGENT]: Handle allocated
17383 internal variables.
17384 (create_trace_state_variable): New parameter `gdb'. Handle it.
17385 (clear_installed_tracepoints): Clear fast tracepoint jumps.
17386 (cmd_qtdp): Handle fast tracepoints.
17387 (cmd_qtdv): Adjust.
17388 (max_jump_pad_size): New.
17389 (gdb_jump_pad_head): New.
17390 (get_jump_space_head): New.
17391 (claim_jump_space): New.
17392 (sort_tracepoints): New.
17393 (MAX_JUMP_SIZE): New.
17394 (cmd_qtstart): Handle fast tracepoints. Sync tracepoints with the
17395 IPA.
17396 (stop_tracing) [IN_PROCESS_AGENT]: Don't include the tdisconnected
17397 support. Upload fast traceframes, and delete internal IPA
17398 breakpoints.
17399 (stop_tracing_handler): New.
17400 (flush_trace_buffer_handler): New.
17401 (cmd_qtstop): Upload fast tracepoints.
17402 (response_tracepoint): Handle fast tracepoints.
17403 (tracepoint_finished_step): Upload fast traceframes. Set the
17404 tracepoint hit context's tracepoint type.
17405 (handle_tracepoint_bkpts): New.
17406 (tracepoint_was_hit): Set the tracepoint hit context's tracepoint
17407 type. Add comment about fast tracepoints.
17408 (collect_data_at_tracepoint) [IN_PROCESS_AGENT]: Don't access the
17409 non-existing action_str field.
17410 (get_context_regcache): Handle fast tracepoints.
17411 (do_action_at_tracepoint) [!IN_PROCESS_AGENT]: Don't write the PC
17412 to the regcache.
17413 (fast_tracepoint_from_jump_pad_address): New.
17414 (fast_tracepoint_from_ipa_tpoint_address): New.
17415 (collecting_t): New.
17416 (force_unlock_trace_buffer): New.
17417 (fast_tracepoint_collecting): New.
17418 (collecting): New.
17419 (gdb_collect): New.
17420 (write_inferior_data_ptr): New.
17421 (target_tp_heap): New.
17422 (target_malloc): New.
17423 (download_agent_expr): New.
17424 (UALIGN): New.
17425 (download_tracepoints): New.
17426 (download_trace_state_variables): New.
17427 (upload_fast_traceframes): New.
17428 (IPA_FIRST_TRACEFRAME): New.
17429 (IPA_NEXT_TRACEFRAME_1): New.
17430 (IPA_NEXT_TRACEFRAME): New.
17431 [IN_PROCESS_AGENT]: Include sys/mman.h and fcntl.h.
17432 [IN_PROCESS_AGENT] (gdb_tp_heap_buffer, gdb_jump_pad_buffer)
17433 (gdb_jump_pad_buffer_end): New.
17434 [IN_PROCESS_AGENT] (initialize_tracepoint_ftlib): New.
17435 (initialize_tracepoint): Adjust.
17436 [IN_PROCESS_AGENT]: Allocate the IPA heap, and jump pad scratch
17437 buffer. Initialize the low module.
17438 * utils.c (PREFIX, TOOLNAME): New.
17439 (malloc_failure): Use PREFIX.
17440 (error): In the IPA, an error causes an exit.
17441 (fatal, warning): Use PREFIX.
17442 (internal_error): Use TOOLNAME.
17443 (NUMCELLS): Increase to 10.
17444 * configure, config.in: Regenerate.
17445
d149dd1d
PA
174462010-06-01 Pedro Alves <pedro@codesourcery.com>
17447
17448 * server.c (handle_query) <qSupported>: Do two passes over the
17449 qSupported string to avoid nesting strtok.
17450
f6528abd
JK
174512010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
17452
17453 * Makefile.in (SFILES): Add $(srcdir)/proc-service.list.
17454 (CDEPS): New.
17455 * configure.ac (RDYNAMIC): New AC_MSG_CHECKING wrapping. Test also
17456 -Wl,--dynamic-list.
17457 * configure: Regenerate.
17458 * proc-service.list: New.
17459
ca2a87a0
JK
174602010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
17461
17462 * linux-low.c (linux_core_of_thread): Fix crash on invalid CONTENT.
17463 New comment.
17464
363a6e9f
OS
174652010-05-26 Ozkan Sezer <sezeroz@gmail.com>
17466
17467 * gdbreplay.c (remote_open): Check error return from socket() call by
17468 its equality to -1 not by it being negative.
17469 * remote-utils.c (remote_open): Likewise.
17470
d23b6cb1
PA
174712010-05-23 Pedro Alves <pedro@codesourcery.com>
17472
17473 * config.h: Regenerate.
17474
28d3cf85
MK
174752010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
17476
17477 * linux-m68k-low.c (ps_get_thread_area): Don't define if kernel
17478 doesn't provide PTRACE_GET_THREAD_AREA.
17479
fea36a59
MK
174802010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
17481
17482 * linux-m68k-low.c: Include <asm/ptrace.h>
17483 (ps_get_thread_area): Implement.
17484
24b066ba
DE
174852010-05-03 Doug Evans <dje@google.com>
17486
17487 * event-loop.c (struct callback_event): New struct.
17488 (callback_list): New global.
17489 (append_callback_event, delete_callback_event): New functions.
17490 (process_callback): New function.
17491 (start_event_loop): Call it.
17492 * remote-utils.c (NOT_SCHEDULED): Define.
17493 (readchar_buf, readchar_bufcnt, readchar_bufp): New static globals,
17494 moved out of readchar.
17495 (readchar): Rewrite. Call reschedule before returning.
17496 (reset_readchar): New function.
17497 (remote_close): Call it.
17498 (process_remaining, reschedule): New functions.
17499 * server.h (callback_handler_func): New typedef.
17500 (append_callback_event, delete_callback_event): Declare.
17501
9836d6ea
PA
175022010-05-03 Pedro Alves <pedro@codesourcery.com>
17503
17504 * proc-service.c (ps_pglobal_lookup): Use
17505 thread_db_look_up_one_symbol.
17506 * remote-utils.c (look_up_one_symbol): Add new `may_ask_gdb'
17507 parameter. Use it instead of all_symbols_looked_up.
17508 * server.h (struct process_info) <all_symbols_looked_up>: Delete
17509 field.
17510 (all_symbols_looked_up): Don't declare.
17511 (look_up_one_symbol): Add new `may_ask_gdb' parameter.
17512 * thread-db.c (struct thread_db) <all_symbols_looked_up>: New
17513 field.
17514 (thread_db_look_up_symbols): Adjust call to look_up_one_symbol.
17515 Set all_symbols_looked_up here.
17516 (thread_db_look_up_one_symbol): New.
17517 (thread_db_get_tls_address): Adjust.
17518 (thread_db_load_search, try_thread_db_load_1): Always allocate the
17519 thread_db object on the heap, and tentatively set it in the
17520 process structure.
17521 (thread_db_init): Don't set all_symbols_looked_up here.
17522 * linux-low.h (thread_db_look_up_one_symbol): Declare.
17523
7984d532
PA
175242010-05-03 Pedro Alves <pedro@codesourcery.com>
17525
17526 * linux-low.c (linux_kill, linux_detach): Adjust.
17527 (status_pending_p_callback): Remove redundant statement. Check
17528 for !TARGET_WAITIKIND_IGNORE, instead of
17529 TARGET_WAITKIND_STOPPED.
17530 (handle_tracepoints): Make sure LWP is locked. Adjust.
17531 (linux_wait_for_event_1): Adjust.
17532 (linux_cancel_breakpoints): New.
17533 (unsuspend_one_lwp): New.
17534 (unsuspend_all_lwps): New.
17535 (linux_wait_1): If finishing a step-over, unsuspend all lwps.
17536 (send_sigstop_callback): Change return type to int, add new
17537 `except' parameter and handle it.
17538 (suspend_and_send_sigstop_callback): New.
17539 (stop_all_lwps): Add new `suspend' and `expect' parameters, and
17540 pass them down. If SUSPEND, also increment the lwp's suspend
17541 count.
17542 (linux_resume_one_lwp): Add notice about resuming a suspended LWP.
17543 (need_step_over_p): Don't consider suspended LWPs.
17544 (start_step_over): Adjust.
17545 (proceed_one_lwp): Change return type to int, add new `except'
17546 parameter and handle it.
17547 (unsuspend_and_proceed_one_lwp): New.
17548 (proceed_all_lwps): Use find_inferior instead of
17549 for_each_inferior.
17550 (unstop_all_lwps): Add `unsuspend' parameter. If UNSUSPEND, them
17551 also decrement the suspend count of LWPs. Pass `except' down,
17552 instead of hacking its suspend count.
17553 (linux_pause_all): Add `freeze' parameter. Adjust.
17554 (linux_unpause_all): New.
17555 (linux_target_ops): Install linux_unpause_all.
17556 * server.c (handle_status): Adjust.
17557 * target.h (struct target_ops): New fields `unpause_all' and
17558 `cancel_breakpoints'. Add new parameter to `pause_all'.
17559 (pause_all): Add new `freeze' parameter.
17560 (unpause_all): New.
17561 (cancel_breakpoints): New.
17562 * tracepoint.c (clear_installed_tracepoints): Pause threads, and
17563 cancel breakpoints.
17564 (cmd_qtstart): Pause threads.
17565 (stop_tracing): Pause threads, and cancel breakpoints.
17566 * win32-low.c (win32_target_ops): Adjust.
17567
e471f25b
PA
175682010-05-03 Pedro Alves <pedro@codesourcery.com>
17569
17570 * linux-low.c (linux_wait_for_event_1): Move passing the signal to
17571 the inferior right away from here...
17572 (linux_wait_1): ... to here, and adjust to check the thread's
17573 last_resume_kind instead of the lwp's step or stop_expected flags.
17574
1915ef4f
PA
175752010-05-02 Pedro Alves <pedro@codesourcery.com>
17576
17577 * README: Use consistent `GDB' and `GDBserver' spellings.
17578
f9e39928
PA
175792010-05-02 Pedro Alves <pedro@codesourcery.com>
17580
17581 * linux-low.c (linux_kill_one_lwp): Assume the lwp is stopped.
17582 (linux_kill): Stop all lwps here. Don't delete the main lwp here.
17583 (linux_detach_one_lwp): Assume the lwp is stopped.
17584 (any_thread_of): Delete.
17585 (linux_detach): Stop all lwps here. Don't blindly delete all
17586 breakpoints.
17587 (delete_lwp_callback): New.
17588 (linux_mourn): Delete all lwps of the process that is gone.
17589 (linux_wait_1): Don't delete the last lwp of the process here.
17590 * mem-break.h (mark_breakpoints_out): Declare.
17591 * mem-break.c (mark_breakpoints_out): New.
17592 (free_all_breakpoints): Use it.
17593 * server.c (handle_target_event): If the process is gone, mark
17594 breakpoints out.
17595 * thread-db.c (struct thread_db) <create_bp>: New field.
17596 (thread_db_enable_reporting): Fix prototype. Store a thread event
17597 breakpoint reference in the thread_db struct.
17598 (thread_db_load_search): Clear the thread_db object.
17599 (try_thread_db_load_1): Ditto.
17600 (switch_to_process): New.
17601 (disable_thread_event_reporting): Use it.
17602 (remove_thread_event_breakpoints): New.
17603 (thread_db_detach, thread_db_mourn): Use it.
17604
1e7fc18c
PA
176052010-05-01 Pedro Alves <pedro@codesourcery.com>
17606
17607 * linux-low.c (linux_enable_event_reporting): New.
17608 (linux_wait_for_event_1, handle_extended_wait): Use it.
17609
02fc4de7
PA
176102010-04-30 Pedro Alves <pedro@codesourcery.com>
17611
17612 * linux-low.c (linux_kill_one_lwp, linux_kill)
17613 (linux_detach_one_lwp): Adjust to send_sigstop interface change.
17614 (send_sigstop): Take an lwp_info as parameter instead. Queue a
17615 SIGSTOP even if the LWP is stopped.
17616 (send_sigstop_callback): New.
17617 (stop_all_lwps): Use send_sigstop_callback instead.
17618 (linux_resume_one_thread): Adjust.
17619 (proceed_one_lwp): Still proceed an LWP that the client has
17620 requested to stop, if we haven't reported it as stopped yet. Make
17621 sure that LWPs the client want stopped, have a pending SIGSTOP.
17622
bc3b5632
DE
176232010-04-26 Doug Evans <dje@google.com>
17624
ae1ada35
DE
17625 * server.c (handle_general_set): Make static.
17626
bc3b5632
DE
17627 * remote-utils.c (putpkt_binary_1): Call readchar instead of read.
17628 Print received char after testing for error/eof instead of before.
17629 (input_interrupt): Tweak comment.
17630
65730243
DE
176312010-04-23 Doug Evans <dje@google.com>
17632
17633 * server.c (start_inferior): Print inferior argv if --debug.
17634
a8ae7dc0
AR
176352010-04-21 Aleksandar Ristovski <aristovski@qnx.com>
17636
17637 * Makefile.in (nto_low_h nto-low.o nto-x86-low.o): New dependency lists.
17638 * nto-x86-low.c: Include server.h
17639
1c07cc19
PM
176402010-04-20 Pierre Muller <muller@ics.u-strasbg.fr>
17641
17642 * win32-i386-low.c: Use __x86_64__ macro instead of __x86_64 to
17643 be consistent with other sources of this directory.
17644 (init_registers_amd64): Correct name of source file of this function
17645 in the comment.
17646
e0a61e09
PM
176472010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
17648
17649 * configure.srv (x86_64-*-mingw*): New configuration for Windows
17650 64-bit executables.
17651
54709339
PM
176522010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
17653
17654 * win32-i386-low.c: Add 64-bit support.
17655 (CONTEXT_EXTENDED_REGISTERS): Set macro to zero if not exisiting.
17656 (init_registers_amd64): Declare.
17657 (mappings): Add 64-bit version of array.
17658 (init_windows_x86): New function.
17659 (the_low_target): Change init_arch field to init_windows_x86.
17660
e8f0053d
PM
176612010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
17662
17663 * win32-low.c: Adapt to support also 64-bit architecture.
17664 (child_xfer_memory): Use uintptr_t type for local variable `addr'.
17665 (get_image_name): Use SIZE_T type for local variable `done'.
17666 (psapi_get_dll_name): Use LPVOID type for parameter `BaseAddress'.
17667 (toolhelp_get_dll_name): Idem.
17668 (handle_load_dll): Use CORE_ADDR type for local variable `load_addr'.
17669 Use uintptr_t typecast to avoid warning.
17670 (handle_unload_dll): Use uintptr_t typecast to avoid warning.
17671 (handle_exception): Use phex_nz to avoid warning.
17672 (win32_wait): Remove unused local variable `process'.
17673
c481e77e
PM
176742010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
17675
17676 * configure.srv (srv_amd64_regobj): Replace `x86-64-avx.o' by
17677 `amd64-avx.o'.
17678
12ea4b69
PM
176792010-04-17 Pierre Muller <muller@ics.u-strasbg.fr>
17680
17681 * configure.ac: Use `ws2_32' library for srv_mingw.
17682 * configure: Regenerate.
17683 * gdbreplay.c: Include winsock2.h instead of winsock.h.
17684 * remote-utils.c: Likewise.
17685
f6d1620c
L
176862010-04-17 H.J. Lu <hongjiu.lu@intel.com>
17687
17688 * linux-x86-low.c (xmltarget_amd64_linux_no_xml): Define only
17689 if __x86_64__ is defined.
17690
8e642873
PM
176912010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
17692
17693 * configure: Regenerate.
17694
711e434b
PM
176952010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
17696
17697 * server.c (handle_query): Handle 'qGetTIBAddr' query.
17698 * target.h (target_ops): New get_tib_address field.
17699 * win32-low.h (win32_thread_info): Add thread_local_base field.
17700 * win32-low.c (child_add_thread): Add tlb argument.
17701 Set thread_local_base field to TLB.
17702 (get_child_debug_event): Adapt to child_add_thread change.
17703 (win32_get_tib_address): New function.
17704 (win32_target_ops): Set get_tib_address field to
17705 win32_get_tib_address.
17706 * linux-low.c (linux_target_ops): Set get_tib_address field to NULL.
17707
505106cd
PA
177082010-04-12 Pedro Alves <pedro@codesourcery.com>
17709
505106cd
PA
17710 * linux-low.c (linux_mourn): Also remove the process.
17711 * server.c (handle_target_event): Don't remove the process here.
17712 * nto-low.c (nto_mourn): New.
17713 (nto_target_ops): Install it.
17714 * spu-low.c (spu_mourn): New.
17715 (spu_target_ops): Install it.
17716 * win32-low.c (win32_mourn): New.
17717 (win32_target_ops): Install it.
17718
e8470a06
PA
177192010-04-12 Pedro Alves <pedro@codesourcery.com>
17720
17721 * server.h (buffer_xml_printf): Remove redundant `;'.
17722
45ba0d02
PA
177232010-04-12 Pedro Alves <pedro@codesourcery.com>
17724
17725 * regcache.c (set_register_cache): Invalidate regcaches before
17726 changing the register cache layout.
17727 (regcache_invalidate_one): Allow a NULL regcache.
17728 * linux-x86-low.c (x86_linux_update_xmltarget): Invalidate
17729 regcaches before changing the register cache layout or the target
17730 regsets.
17731
59e04013
L
177322010-04-12 H.J. Lu <hongjiu.lu@intel.com>
17733
17734 * linux-x86-low.c (x86_linux_update_xmltarget): Avoid unused
17735 variable warning on Linux/x86-64.
17736
8336d594
PA
177372010-04-11 Pedro Alves <pedro@codesourcery.com>
17738
17739 GDBserver disconnected tracing support.
17740
17741 * linux-low.c (linux_remove_process): Delete.
17742 (add_lwp): Don't set last_resume_kind here.
17743 (linux_kill): Use `mourn'.
17744 (linux_detach): Use `thread_db_detach', and `mourn'.
17745 (linux_mourn): New.
17746 (linux_attach_lwp_1): Adjust comment.
17747 (linux_attach): last_resume_kind moved the thread_info; adjust.
17748 (status_pending_p_callback): Adjust.
17749 (linux_wait_for_event_1): Adjust.
17750 (count_events_callback, select_singlestep_lwp_callback)
17751 (select_event_lwp_callback, cancel_breakpoints_callback)
17752 (db_wants_lwp_stopped, linux_wait_1, need_step_over_p)
17753 (proceed_one_lwp): Adjust.
17754 (linux_async): Add debug output.
17755 (linux_thread_stopped): New.
17756 (linux_pause_all): New.
17757 (linux_target_ops): Install linux_mourn, linux_thread_stopped and
17758 linux_pause_all.
17759 * linux-low.h (struct lwp_info): Delete last_resume_kind field.
17760 (thread_db_free): Delete declaration.
17761 (thread_db_detach, thread_db_mourn): Declare.
17762 * thread-db.c (thread_db_init): Use thread_db_mourn.
17763 (thread_db_free): Delete, split in two.
17764 (disable_thread_event_reporting): New.
17765 (thread_db_detach): New.
17766 (thread_db_mourn): New.
17767
17768 * server.h (struct thread_info) <last_resume_kind>: New field.
17769 <attached>: Add comment.
17770 <gdb_detached>: New field.
17771 (handler_func): Change return type to int.
17772 (handle_serial_event, handle_target_event): Ditto.
17773 (gdb_connected): Declare.
17774 (tracing): Delete.
17775 (disconnected_tracing): Declare.
17776 (stop_tracing): Declare.
17777
17778 * server.c (handle_query) <qSupported>: Report support for
17779 disconnected tracing.
17780 (queue_stop_reply_callback): Account for running threads.
17781 (gdb_wants_thread_stopped): New.
17782 (gdb_wants_all_threads_stopped): New.
17783 (gdb_reattached_process): New.
17784 (handle_status): Clear the `gdb_detached' flag of all processes.
17785 In all-stop, stop all threads.
17786 (main): Be sure to leave tfind mode. Handle disconnected tracing.
17787 (process_serial_event): If the remote connection breaks, or if an
17788 exit was forced with "monitor exit", force an event loop exit.
17789 Handle disconnected tracing on detach.
17790 (handle_serial_event): Adjust.
17791 (handle_target_event): If GDB isn't connected, forward events back
17792 to the inferior, unless the last process exited, in which case,
17793 exit gdbserver. Adjust interface.
17794
17795 * remote-utils.c (remote_open): Don't block in accept. Instead
17796 register an event loop source on the listen socket file
17797 descriptor. Refactor bits into ...
17798 (listen_desc): ... this new global.
17799 (gdb_connected): ... this new function.
17800 (enable_async_notification): ... this new function.
17801 (handle_accept_event): ... this new function.
17802 (remote_close): Clear remote_desc.
17803
17804 * inferiors.c (add_thread): Set the new thread's last_resume_kind.
17805
17806 * target.h (struct target_ops) <mourn, thread_stopped, pause_all>:
17807 New fields.
17808 (mourn_inferior): Define.
17809 (target_process_qsupported): Avoid the dangling else problem.
17810 (thread_stopped): Define.
17811 (pause_all): Define.
17812 (target_waitstatus_to_string): Declare.
17813 * target.c (target_waitstatus_to_string): New.
17814
17815 * tracepoint.c (tracing): Make extern.
17816 (disconnected_tracing): New.
17817 (stop_tracing): Make extern. Handle tracing stops due to GDB
17818 disconnecting.
17819 (cmd_qtdisconnected): New.
17820 (cmd_qtstatus): Report disconnected tracing status in trace reply.
17821 (handle_tracepoint_general_set): Handle QTDisconnected.
17822
17823 * event-loop.c (event_handler_func): Change return type to int.
17824 (process_event): Bail out if the event handler wants the event
17825 loop to stop.
17826 (handle_file_event): Ditto.
17827 (start_event_loop): Bail out if the event handler wants the event
17828 loop to stop.
17829
17830 * nto-low.c (nto_target_ops): Adjust.
17831 * spu-low.c (spu_wait): Don't remove the process here.
17832 (spu_target_ops): Adjust.
17833 * win32-low.c (win32_wait): Don't remove the process here.
17834 (win32_target_ops): Adjust.
17835
5d267c4c
PA
178362010-04-11 Pedro Alves <pedro@codesourcery.com>
17837
17838 * regcache.c (realloc_register_cache): Invalidate inferior's
17839 regcache before recreating it.
17840
623ccd72
PA
178412010-04-09 Pedro Alves <pedro@codesourcery.com>
17842
17843 * tracepoint.c (cmd_qtstatus): Report trace buffer circularity.
17844
219f2f23
PA
178452010-04-09 Stan Shebs <stan@codesourcery.com>
17846 Pedro Alves <pedro@codesourcery.com>
17847
17848 * server.h (LONGEST): New.
17849 (struct thread_info) <while_stepping>: New field.
17850 (unpack_varlen_hex, xrealloc, pulongest, plongest, phex_nz):
17851 Declare.
17852 (initialize_tracepoint, handle_tracepoint_general_set)
17853 (handle_tracepoint_query, tracepoint_finished_step)
17854 (tracepoint_was_hit, release_while_stepping_state_list):
17855 (current_traceframe): Declare.
17856 * server.c (handle_general_set): Handle tracepoint packets.
17857 (read_memory): New.
17858 (write_memory): New.
17859 (handle_search_memory_1): Use read_memory.
17860 (handle_query): Report support for conditional tracepoints, trace
17861 state variables, and tracepoint sources. Handle tracepoint
17862 queries.
17863 (main): Initialize the tracepoints module.
17864 (process_serial_event): Handle traceframe reads/writes.
17865
17866 * linux-low.c (handle_tracepoints): New.
17867 (linux_wait_1): Call it.
17868 (linux_resume_one_lwp): Handle while-stepping.
17869 (linux_supports_tracepoints, linux_read_pc, linux_write_pc): New.
17870 (linux_target_ops): Install them.
17871 * linux-low.h (struct linux_target_ops) <supports_tracepoints>:
17872 New field.
17873 * linux-x86-low.c (x86_supports_tracepoints): New.
17874 (the_low_target). Install it.
17875
17876 * mem-break.h (delete_breakpoint): Declare.
17877 * mem-break.c (delete_breakpoint): Make external.
17878
17879 * target.h (struct target_ops): Add `supports_tracepoints',
17880 `read_pc', and `write_pc' fields.
17881 (target_supports_tracepoints): Define.
17882 * utils.c (xrealloc, decimal2str, pulongest, plongest, thirty_two)
17883 (phex_nz): New.
17884
17885 * regcache.h (struct regcache) <registers_owned>: New field.
17886 (init_register_cache, regcache_cpy): Declare.
17887 (regcache_read_pc, regcache_write_pc): Declare.
17888 (register_cache_size): Declare.
17889 (supply_regblock): Declare.
17890 * regcache.c (init_register_cache): New.
17891 (new_register_cache): Use it.
17892 (regcache_cpy): New.
17893 (register_cache_size): New.
17894 (supply_regblock): New.
17895 (regcache_read_pc, regcache_write_pc): New.
889bf7c5 17896
219f2f23
PA
17897 * tracepoint.c: New.
17898
17899 * Makefile.in (OBS): Add tracepoint.o.
17900 (tracepoint.o): New rule.
17901
3a13a53b
L
179022010-04-08 H.J. Lu <hongjiu.lu@intel.com>
17903
17904 * Makefile.in (clean): Also remove i386-mmx.c i386-mmx-linux.c.
17905 (i386-mmx.o): New.
17906 (i386-mmx.c): Likewise.
17907 (i386-mmx-linux.o): Likewise.
17908 (i386-mmx-linux.c): Likewise.
17909
17910 * configure.srv (srv_i386_regobj): Add i386-mmx.o.
17911 (srv_i386_linux_regobj): Add i386-mmx-linux.o.
17912 (srv_i386_xmlfiles): Add i386/i386-mmx.xml.
17913 (srv_i386_linux_xmlfiles): Add i386/i386-mmx-linux.xml.
17914
17915 * linux-x86-low.c (init_registers_i386_mmx_linux): New.
17916 (x86_linux_update_xmltarget): Call init_registers_i386_mmx_linux
17917 and return if ptrace PTRACE_GETFPXREGS failed in 32bit.
17918
1570b33e
L
179192010-04-07 H.J. Lu <hongjiu.lu@intel.com>
17920
17921 * Makefile.in (clean): Updated.
17922 (i386-avx.o): New.
17923 (i386-avx.c): Likewise.
17924 (i386-avx-linux.o): Likewise.
17925 (i386-avx-linux.c): Likewise.
17926 (amd64-avx.o): Likewise.
17927 (amd64-avx.c): Likewise.
17928 (amd64-avx-linux.o): Likewise.
17929 (amd64-avx-linux.c): Likewise.
17930
17931 * configure.srv (srv_i386_regobj): Add i386-avx.o.
17932 (srv_i386_linux_regobj): Add i386-avx-linux.o.
17933 (srv_amd64_regobj): Add amd64-avx.o.
17934 (srv_amd64_linux_regobj): Add amd64-avx-linux.o.
17935 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx.xml.
17936 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx.xml.
17937 (srv_i386_xmlfiles): Add i386/i386-avx.xml.
17938 (srv_amd64_xmlfiles): Add i386/amd64-avx.xml.
17939 (srv_i386_linux_xmlfiles): Add i386/i386-avx-linux.xml.
17940 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-linux.xml.
17941
17942 * i387-fp.c: Include "i386-xstate.h".
17943 (i387_xsave): New.
17944 (i387_cache_to_xsave): Likewise.
17945 (i387_xsave_to_cache): Likewise.
17946 (x86_xcr0): Likewise.
17947
17948 * i387-fp.h (i387_cache_to_xsave): Likewise.
17949 (i387_xsave_to_cache): Likewise.
17950 (x86_xcr0): Likewise.
17951
17952 * linux-arm-low.c (target_regsets): Initialize nt_type to 0.
17953 * linux-crisv32-low.c (target_regsets): Likewise.
17954 * linux-m68k-low.c (target_regsets): Likewise.
17955 * linux-mips-low.c (target_regsets): Likewise.
17956 * linux-ppc-low.c (target_regsets): Likewise.
17957 * linux-s390-low.c (target_regsets): Likewise.
17958 * linux-sh-low.c (target_regsets): Likewise.
17959 * linux-sparc-low.c (target_regsets): Likewise.
17960 * linux-xtensa-low.c (target_regsets): Likewise.
17961
17962 * linux-low.c: Include <sys/uio.h>.
17963 (regsets_fetch_inferior_registers): Support nt_type.
17964 (regsets_store_inferior_registers): Likewise.
17965 (linux_process_qsupported): New.
17966 (linux_target_ops): Add linux_process_qsupported.
17967
17968 * linux-low.h (regset_info): Add nt_type.
17969 (linux_target_ops): Add process_qsupported.
17970
17971 * linux-x86-low.c: Include "i386-xstate.h", "elf/common.h"
17972 and <sys/uio.h>.
17973 (init_registers_i386_avx_linux): New.
17974 (init_registers_amd64_avx_linux): Likewise.
17975 (xmltarget_i386_linux_no_xml): Likewise.
17976 (xmltarget_amd64_linux_no_xml): Likewise.
17977 (PTRACE_GETREGSET): Likewise.
17978 (PTRACE_SETREGSET): Likewise.
17979 (x86_fill_xstateregset): Likewise.
17980 (x86_store_xstateregset): Likewise.
17981 (use_xml): Likewise.
17982 (x86_linux_update_xmltarget): Likewise.
17983 (x86_linux_process_qsupported): Likewise.
17984 (target_regsets): Add NT_X86_XSTATE entry and Initialize nt_type.
17985 (x86_arch_setup): Don't call init_registers_amd64_linux nor
17986 init_registers_i386_linux here. Call
17987 x86_linux_update_xmltarget.
17988 (the_low_target): Add x86_linux_process_qsupported.
17989
17990 * server.c (handle_query): Call target_process_qsupported.
17991
17992 * target.h (target_ops): Add process_qsupported.
17993 (target_process_qsupported): New.
17994
fc7238bb
PA
179952010-04-03 Pedro Alves <pedro@codesourcery.com>
17996
17997 * inferiors.c (add_thread): Set last_status kind to
17998 TARGET_WAITKIND_IGNORE.
17999 * linux-low.c (cancel_breakpoint): Remove unnecessary regcache
18000 fetch. Use ptid_of. Avoid unnecessary get_lwp_thread calls.
18001 (linux_wait_1): Move `thread' local definition to block that uses
18002 it. Don't NULL initialize `event_child'.
18003 (linux_resume_one_thread): Avoid unnecessary get_lwp_thread calls.
18004 Alway set the thread's last_status to TARGET_WAITKIND_IGNORE.
18005 * linux-x86-low.c (x86_breakpoint_at): Read raw memory.
18006
bdabb078
PA
180072010-04-01 Pedro Alves <pedro@codesourcery.com>
18008
18009 * linux-low.c (get_stop_pc): Don't adjust the PC if stopped with
18010 an extended waitstatus, or by a watchpoint.
18011 (cancel_breakpoints_callback): Don't cancel a breakpoint if the
18012 thread was stepping or has been stopped by a watchpoint.
18013
d3bbe7a0
PA
180142010-04-01 Pedro Alves <pedro@codesourcery.com>
18015
18016 * mem-break.c (struct raw_breakpoint): New field shlib_disabled.
18017 (set_gdb_breakpoint_at): If GDB is inserting a breakpoint on top
18018 of another, then delete the previous, and validate all
18019 breakpoints.
18020 (validate_inserted_breakpoint): New.
18021 (delete_disabled_breakpoints): New.
18022 (validate_breakpoints): New.
18023 (check_mem_read): Validate breakpoints before trusting their
18024 shadow. Delete disabled breakpoints.
18025 (check_mem_write): Validate breakpoints before trusting they
18026 should be inserted. Delete disabled breakpoints.
18027 * mem-break.h (validate_breakpoints):
18028 * server.c (handle_query): Validate breakpoints when we see a
18029 qSymbol query.
18030
8b07ae33
PA
180312010-04-01 Pedro Alves <pedro@codesourcery.com>
18032
18033 * linux-low.c (linux_wait_1): Avoid setting need_step_over is
18034 there's a GDB breakpoint at stop_pc. Always report a trap to GDB
18035 if we could tell there's a GDB breakpoint at stop_pc.
18036 (need_step_over_p): Don't do a step over if we find a GDB
18037 breakpoint at the resume PC.
18038
18039 * mem-break.c (struct raw_breakpoint): New.
18040 (enum bkpt_type): New type `gdb_breakpoint'.
18041 (struct breakpoint): Delete the `PC', `old_data' and `inserted'
18042 fields. New field `raw'.
18043 (find_raw_breakpoint_at): New.
18044 (set_raw_breakpoint_at): Handle refcounting. Create a raw
18045 breakpoint instead.
18046 (set_breakpoint_at): Adjust.
18047 (delete_raw_breakpoint): New.
18048 (release_breakpoint): New.
18049 (delete_breakpoint): Rename to...
18050 (delete_breakpoint_1): ... this. Add proc parameter. Use
18051 release_breakpoint. Return ENOENT.
18052 (delete_breakpoint): Reimplement.
18053 (find_breakpoint_at): Delete.
18054 (find_gdb_breakpoint_at): New.
18055 (delete_breakpoint_at): Delete.
18056 (set_gdb_breakpoint_at): New.
18057 (delete_gdb_breakpoint_at): New.
18058 (gdb_breakpoint_here): New.
18059 (set_reinsert_breakpoint): Use release_breakpoint.
18060 (uninsert_breakpoint): Rename to ...
18061 (uninsert_raw_breakpoint): ... this.
18062 (uninsert_breakpoints_at): Adjust to handle raw breakpoints.
18063 (reinsert_raw_breakpoint): Change parameter type to
18064 raw_breakpoint.
18065 (reinsert_breakpoints_at): Adjust to handle raw breakpoints
18066 instead.
18067 (check_breakpoints): Adjust. Use release_breakpoint.
18068 (breakpoint_here): Rewrite using find_raw_breakpoint_at.
18069 (breakpoint_inserted_here): Ditto.
18070 (check_mem_read): Adjust to iterate over raw breakpoints instead.
18071 Don't trust the breakpoint's shadow if it is not inserted.
18072 (check_mem_write): Adjust to iterate over raw breakpoints instead.
18073 (delete_all_breakpoints): Adjust.
18074 (free_all_breakpoints): Mark all breakpoints as uninserted, and
18075 use delete_breakpoint_1.
18076
18077 * mem-break.h (breakpoints_supported): Delete declaration.
18078 (set_gdb_breakpoint_at): Declare.
18079 (gdb_breakpoint_here): Declare.
18080 (delete_breakpoint_at): Delete.
18081 (delete_gdb_breakpoint_at): Declare.
18082
18083 * server.h (struct raw_breakpoint): Forward declare.
18084 (struct process_info): New field `raw_breakpoints'.
18085
18086 * linux-x86-low.c (x86_insert_point, x86_remote_point): Handle Z0
18087 breakpoints.
18088
6bf5e0ba
PA
180892010-03-24 Pedro Alves <pedro@codesourcery.com>
18090
18091 * linux-low.c (status_pending_p_callback): Fix comment.
18092 (linux_wait_for_event_1): Move most of the internal breakpoint
18093 handling from here...
18094 (linux_wait_1): ... to here.
18095 (count_events_callback): New.
18096 (select_singlestep_lwp_callback): New.
18097 (select_event_lwp_callback): New.
18098 (cancel_breakpoints_callback): New.
18099 (select_event_lwp): New.
18100 (linux_wait_1): Simplify internal breakpoint handling. Give equal
18101 priority to all LWPs that have had events that should be reported
18102 to the client. Cancel breakpoints when about to reporting the
18103 event to the client, not while stopping lwps. No longer cancel
18104 finished single-steps here.
18105 (cancel_finished_single_step): Delete.
18106 (cancel_finished_single_steps): Delete.
18107
414a389f
PA
181082010-03-24 Pedro Alves <pedro@codesourcery.com>
18109
18110 * mem-break.c (enum bkpt_type): New.
18111 (struct breakpoint): New field `type'.
18112 (set_breakpoint_at): Change return type to struct breakpoint
18113 pointer. Set type to `other_breakpoint' by default.
18114 (delete_breakpoint): Rewrite, supporting more than one breakpoint
18115 in the breakpoint list.
18116 (delete_reinsert_breakpoints): Only delete reinsert breakpoints.
18117 (reinsert_breakpoint): Rename to ...
18118 (reinsert_raw_breakpoint): ... this.
18119 (reinsert_breakpoints_at): Adjust.
18120 * mem-break.h (struct breakpoint): Declare.
18121 (set_breakpoint_at): Change return type to struct breakpoint
18122 pointer.
18123
2280c721
PA
181242010-03-24 Pedro Alves <pedro@codesourcery.com>
18125
18126 * server.c (handle_query): Assign, not compare.
18127
d50171e4
PA
181282010-03-24 Pedro Alves <pedro@codesourcery.com>
18129
18130 Teach linux gdbserver to step-over-breakpoints.
18131
18132 * linux-low.c (can_hardware_single_step): New.
18133 (supports_breakpoints): New.
18134 (handle_extended_wait): If stopping threads, read the stop pc of
18135 the new cloned LWP.
18136 (get_pc): New.
18137 (get_stop_pc): Add `lwp' parameter. Handle it. Bail out if the
18138 low target doesn't support retrieving the PC.
18139 (add_lwp): Set last_resume_kind to resume_continue.
18140 (linux_attach_lwp_1): Adjust comments. Always set stop_expected.
18141 (linux_attach): Don't clear stop_expected. Set the lwp's
18142 last_resume_kind to resume_stop.
18143 (linux_detach_one_lwp): Don't check for removed breakpoints.
18144 (check_removed_breakpoint): Delete.
18145 (status_pending_p): Rename to ...
18146 (status_pending_p_callback): ... this. Don't check for removed
18147 breakpoints. Don't consider threads that are stopped from GDB's
18148 perspective.
18149 (linux_wait_for_lwp): Always read the stop_pc here.
18150 (cancel_breakpoint): New.
18151 (step_over_bkpt): New global.
18152 (linux_wait_for_event_1): Implement stepping over breakpoints.
18153 (gdb_wants_lwp_stopped): New.
18154 (gdb_wants_all_stopped): New.
18155 (linux_wait_1): Tag threads as gdb-wants-stopped. Cancel finished
18156 single-step traps here. Store the thread's last reported target
18157 wait status.
18158 (send_sigstop): Don't clear stop_expected. Always set it,
18159 instead.
18160 (mark_lwp_dead): Remove reference to pending_is_breakpoint.
18161 (cancel_finished_single_step): New.
18162 (cancel_finished_single_steps): New.
18163 (wait_for_sigstop): Don't cancel finished single-step traps here.
18164 (linux_resume_one_lwp): Don't check for removed breakpoints.
18165 Don't set `step' on non-hardware step archs.
18166 (linux_set_resume_request): Ignore resume_stop requests if already
18167 stopping or stopped. Set the lwp's last_resume_kind.
18168 (resume_status_pending_p): Don't check for removed breakpoints.
18169 (need_step_over_p): New.
18170 (start_step_over): New.
18171 (finish_step_over): New.
18172 (linux_resume_one_thread): Always queue a sigstop for resume_stop
18173 requests. Clear the thread's last reported target waitstatus.
18174 Don't use the `suspended' flag. Don't consider pending breakpoints.
18175 (linux_resume): Start a step-over if necessary.
18176 (proceed_one_lwp): New.
18177 (proceed_all_lwps): New.
18178 (unstop_all_lwps): New.
18179 * linux-low.h (struct lwp_info): Rewrite comment for the
18180 `suspended' flag. Add the `stop_pc' field. Delete the
18181 `pending_stop_pc' field. Tweak the `stepping' flag's comment.
18182 Add `'last_resume_kind' and `need_step_over' fields.
18183 * inferiors.c (struct thread_info): Delete, moved elsewhere.
18184 * mem-break.c (struct breakpoint): Delete `reinserting' flag.
18185 Delete `breakpoint_to_reinsert' field. New flag `inserted'.
18186 (set_raw_breakpoint_at): New.
18187 (set_breakpoint_at): Rewrite to use it.
18188 (reinsert_breakpoint_handler): Delete.
18189 (set_reinsert_breakpoint): New.
18190 (reinsert_breakpoint_by_bp): Delete.
18191 (delete_reinsert_breakpoints): New.
18192 (uninsert_breakpoint): Rewrite.
18193 (uninsert_breakpoints_at): New.
18194 (reinsert_breakpoint): Rewrite.
18195 (reinsert_breakpoints_at): New.
18196 (check_breakpoints): Rewrite.
18197 (breakpoint_here): New.
18198 (breakpoint_inserted_here): New.
18199 (check_mem_read): Adjust.
18200 * mem-break.h (breakpoints_supported, breakpoint_here)
18201 (breakpoint_inserted_here, set_reinsert_breakpoint): Declare.
18202 (reinsert_breakpoint_by_bp): Delete declaration.
18203 (delete_reinsert_breakpoints): Declare.
18204 (reinsert_breakpoint): Delete declaration.
18205 (reinsert_breakpoints_at): Declare.
18206 (uninsert_breakpoint): Delete declaration.
18207 (uninsert_breakpoints_at): Declare.
18208 (check_breakpoints): Adjust prototype.
18209 * server.h: Adjust include order.
18210 (struct thread_info): Declare here. Add a `last_status' field.
18211
30ba68cb
MS
182122010-03-23 Michael Snyder <msnyder@vmware.com>
18213
18214 * server.c (crc32): New function.
18215 (handle_query): Add handling for 'qCRC:' request.
18216
b9a881c2
PA
182172010-03-23 Pedro Alves <pedro@codesourcery.com>
18218
18219 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR6 if the
18220 lwp had been stopped by a watchpoint.
18221
e92d13d5
PA
182222010-03-16 Pedro Alves <pedro@codesourcery.com>
18223
18224 * server.h (internal_error): Declare.
18225 (gdb_assert, ASSERT_FUNCTION, gdb_assert_fail): Define.
18226 * utils.c (internal_error): New function.
18227
64daa791
AS
182282010-03-15 Andreas Schwab <schwab@redhat.com>
18229
18230 * configure.srv: Fix typo setting srv_regobj.
18231
f52cd8cd
PA
182322010-03-15 Pedro Alves <pedro@codesourcery.com>
18233
18234 * linux-low.c (fetch_register): Avoid passing a non string literal
18235 format to `error'.
18236 (usr_store_inferior_registers): Ditto.
18237
93ae6fdc
PA
182382010-03-14 Pedro Alves <pedro@codesourcery.com>
18239
18240 * linux-low.c (linux_write_memory): Bail out early if peeking
18241 memory failed.
18242
c3adc08c
PA
182432010-03-14 Pedro Alves <pedro@codesourcery.com>
18244
18245 * linux-low.h (struct lwp_info): New fields
18246 `stopped_by_watchpoint' and `stopped_data_address'.
18247 * linux-low.c (linux_wait_for_lwp): Check for watchpoint triggers
18248 here, and cache them in the lwp object.
18249 (wait_for_sigstop): Check stopped_by_watchpoint lwp field
18250 directly.
18251 (linux_resume_one_lwp): Clear the lwp's stopped_by_watchpoint
18252 field.
18253 (linux_stopped_by_watchpoint): Rewrite.
18254 (linux_stopped_data_address): Rewrite.
18255
bce522a2
PA
182562010-03-06 Simo Melenius <simo.melenius@iki.fi>
18257
18258 * linux-low.c (linux_wait_for_lwp): Fetch the regcache after
18259 switching the current inferior, not before.
18260
90884b2b
L
182612010-03-01 H.J. Lu <hongjiu.lu@intel.com>
18262
18263 * Makefile.in (clean): Replace reg-i386.c, reg-x86-64.c,
18264 reg-i386-linux.c and reg-x86-64-linux.c with i386.c, amd64.c,
18265 i386-linux.c and amd64-linux.c.
18266 (reg-i386.o): Removed.
18267 (reg-i386.c): Likewise.
18268 (reg-i386-linux.o): Likewise.
18269 (reg-i386-linux.c): Likewise.
18270 (reg-x86-64.o): Likewise.
18271 (reg-x86-64.c): Likewise.
18272 (reg-x86-64-linux.o): Likewise.
18273 (reg-x86-64-linux.c): Likewise.
18274 (i386.o): New.
18275 (i386.c): Likewise.
18276 (i386-linux.o): Likewise.
18277 (i386-linux.c): Likewise.
18278 (amd64.o): Likewise.
18279 (amd64.c): Likewise.
18280 (amd64-linux.o): Likewise.
18281 (amd64-linux.c): Likewise.
18282
18283 * configure.srv (srv_i386_regobj): New.
18284 (srv_i386_linux_regobj): Likewise.
18285 (srv_amd64_regobj): Likewise.
18286 (srv_amd64_linux_regobj): Likewise.
18287 (srv_i386_32bit_xmlfiles): Likewise.
18288 (srv_i386_64bit_xmlfiles): Likewise.
18289 (srv_i386_xmlfiles): Likewise.
18290 (srv_amd64_xmlfiles): Likewise.
18291 (srv_i386_linux_xmlfiles): Likewise.
18292 (srv_amd64_linux_xmlfiles): Likewise.
18293 (i[34567]86-*-cygwin*): Set srv_regobj to $srv_i386_regobj. Set
18294 srv_xmlfiles to $srv_i386_xmlfiles.
18295 (i[34567]86-*-mingw32ce*): Likewise.
18296 (i[34567]86-*-mingw*): Likewise.
18297 (i[34567]86-*-nto*): Likewise.
18298 (i[34567]86-*-linux*): Set srv_regobj to $srv_i386_linux_regobj
18299 and $srv_amd64_linux_regobj. Set srv_xmlfiles to
18300 $srv_i386_linux_xmlfiles and $srv_amd64_linux_xmlfiles.
18301 (x86_64-*-linux*): Likewise.
18302
18303 * linux-x86-low.c (init_registers_x86_64_linux): Removed.
18304 (init_registers_amd64_linux): New.
18305 (x86_arch_setup): Replace init_registers_x86_64_linux with
18306 init_registers_amd64_linux.
18307
193f13e6
MK
183082010-02-23 Maxim Kuvyrkov <maxim@codesourcery.com>
18309
18310 * configure.ac: Check for libdl. If it is not available link against
18311 static libthread_db.
18312 * configure: Regenerate.
18313
85d721b8
PA
183142010-02-22 Pedro Alves <pedro@codesourcery.com>
18315
18316 PR9605
18317
18318 * i386-low.c (i386_length_and_rw_bits): Throw a fatal error if
18319 handing a read watchpoint.
18320 (i386_low_insert_watchpoint): Read watchpoints aren't supported.
18321
6076632b
DE
183222010-02-12 Doug Evans <dje@google.com>
18323
18324 * linux-low.c (linux_supports_tracefork_flag): Document.
18325 (linux_look_up_symbols): Add comment.
18326
3327ccf7
L
183272010-02-03 H.J. Lu <hongjiu.lu@intel.com>
18328
18329 * regcache.c (supply_register): Clear regcache if buf is NULL.
18330
0718675c 183312010-02-02 Nicolas Roche <roche@sourceware.org>
3327ccf7 18332 Joel Brobecker <brobecker@adacore.com>
0718675c
JB
18333
18334 * inferiors.c (find_inferior): Add function documentation.
18335 (unloaded_dll): Handle the case where the unloaded dll has not
18336 been previously registered in the dll list.
18337
177321bd
DJ
183382010-02-01 Daniel Jacobowitz <dan@codesourcery.com>
18339
18340 * linux-arm-low.c (thumb_breakpoint_len): Delete.
18341 (thumb2_breakpoint): New.
18342 (arm_breakpoint_at): Check for Thumb-2 breakpoints.
18343
2b009048
DJ
183442010-01-29 Daniel Jacobowitz <dan@codesourcery.com>
18345
18346 * linux-low.c (get_stop_pc): Check for SIGTRAP.
18347 (linux_wait_for_event_1): Handle SIGILL and SIGSEGV as possible
18348 breakpoints.
18349
3be029c7
PA
183502010-01-21 Pedro Alves <pedro@codesourcery.com>
18351
18352 * linux-ppc-low.c (ppc_arch_setup): Adjust to regcache changes.
18353
18f5de3b
JK
183542010-01-21 Jan Kratochvil <jan.kratochvil@redhat.com>
18355
18356 * linux-s390-low.c (s390_collect_ptrace_register)
18357 (s390_supply_ptrace_register): Adjust it for the new regcache parameter.
18358
3743bb4f
DE
183592010-01-21 Doug Evans <dje@google.com>
18360
14ce3065
DE
18361 * linux-low.c (PTRACE_ARG3_TYPE): Change from long to void*.
18362 (PTRACE_ARG4_TYPE): New macro.
18363 (handle_extended_wait): Cast ptrace arg4 to PTRACE_ARG4_TYPE.
18364 (linux_wait_for_event_1, linux_resume_one_lwp): Ditto.
18365 (fetch_register): Cast to uintptr_t before casting to PTRACE_ARG3_TYPE.
18366 (usr_store_inferior_registers): Ditto.
18367 (linux_read_memory, linux_write_memory): Ditto.
18368 (linux_test_for_tracefork): Ditto.
18369
3743bb4f
DE
18370 * linux-arm-low.c: Remove redundant include of gdb_proc_service.h.
18371 Only include elf.h if gdb_proc_service.h didn't include linux/elf.h.
18372
8b315be5
PA
183732010-01-21 Pedro Alves <pedro@codesourcery.com>
18374
18375 * proc-service.c (ps_lgetregs): Don't refetch registers from the
18376 target.
18377
85492558
PA
183782010-01-21 Pedro Alves <pedro@codesourcery.com>
18379
18380 * spu-low.c (spu_fetch_registers, spu_store_registers): Change
18381 prototype to take a regcache. Adjust.
18382
442ea881
PA
183832010-01-20 Pedro Alves <pedro@codesourcery.com>
18384
18385 * regcache.h (struct thread_info): Forward declare.
18386 (struct regcache): New.
18387 (new_register_cache): Adjust prototype.
18388 (get_thread_regcache): Declare.
18389 (free_register_cache): Adjust prototype.
18390 (registers_to_string, registers_from_string): Ditto.
18391 (supply_register, supply_register_by_name, collect_register)
18392 (collect_register_as_string, collect_register_by_name): Ditto.
18393 * regcache.c (struct inferior_regcache_data): Delete.
18394 (get_regcache): Rename to ...
18395 (get_thread_regcache): ... this. Adjust. Switch inferior before
18396 fetching registers.
18397 (regcache_invalidate_one): Adjust.
18398 (regcache_invalidate): Fix prototype.
18399 (new_register_cache): Return the new register cache.
18400 (free_register_cache): Change prototype.
18401 (realloc_register_cache): Adjust.
18402 (registers_to_string): Change prototype to take a regcache. Adjust.
18403 (registers_from_string): Ditto.
18404 (register_data): Ditto.
18405 (supply_register): Ditto.
18406 (supply_register_by_name): Ditto.
18407 (collect_register): Ditto.
18408 (collect_register_as_string): Ditto.
18409 (collect_register_by_name): Ditto.
18410 * server.c (process_serial_event): Adjust.
18411 * linux-low.h (regset_fill_func, regset_store_func): Change
18412 prototype.
18413 (get_pc, set_pc, collect_ptrace_register, supply_ptrace_register):
18414 Change prototype.
18415 * linux-low.c (get_stop_pc): Adjust.
18416 (check_removed_breakpoint): Adjust.
18417 (linux_wait_for_event): Adjust.
18418 (linux_resume_one_lwp): Adjust.
18419 (fetch_register): Add regcache parameter. Adjust.
18420 (usr_store_inferior_registers): Ditto.
18421 (regsets_fetch_inferior_registers): Ditto.
18422 (regsets_store_inferior_registers): Ditto.
18423 (linux_fetch_registers, linux_store_registers): Ditto.
18424 * i387-fp.c (i387_cache_to_fsave): Change prototype to take a
18425 regcache. Adjust.
43aaf8b6
PA
18426 (i387_fsave_to_cache, i387_cache_to_fxsave, i387_fxsave_to_cache):
18427 Ditto.
442ea881
PA
18428 * i387-fp.h (i387_cache_to_fsave, i387_fsave_to_cache): Change
18429 prototype to take a regcache.
18430 (i387_cache_to_fxsave, i387_fxsave_to_cache): Ditto.
18431 * remote-utils.c (convert_ascii_to_int, outreg)
18432 (prepare_resume_reply): Change prototype to take a regcache.
18433 Adjust.
18434 * target.h (struct target_ops) <fetch_registers, store_registers>:
18435 Change prototype to take a regcache.
18436 (fetch_inferior_registers, store_inferior_registers): Change
18437 prototype to take a regcache. Adjust.
18438 * proc-service.c (ps_lgetregs): Adjust.
18439 * linux-x86-low.c (x86_fill_gregset, x86_store_gregset)
18440 (x86_fill_fpregset, x86_store_fpregset, x86_fill_fpxregset)
18441 (x86_store_fpxregset, x86_get_pc, x86_set_pc): Change prototype to
18442 take a regcache. Adjust.
18443 * linux-arm-low.c (arm_fill_gregset, arm_store_gregset)
18444 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
18445 (arm_store_vfpregset, arm_get_pc, arm_set_pc):
18446 (arm_breakpoint_at): Change prototype to take a regcache. Adjust.
18447 * linux-cris-low.c (cris_get_pc, cris_set_pc)
18448 (cris_cannot_fetch_register):
18449 (cris_breakpoint_at): Change prototype to take a regcache.
18450 Adjust.
18451 * linux-crisv32-low.c (cris_get_pc, cris_set_pc,
18452 cris_reinsert_addr, cris_write_data_breakpoint): Change prototype
18453 to take a regcache. Adjust.
18454 (cris_breakpoint_at, cris_insert_point, cris_remove_point):
18455 Adjust.
18456 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Change prototype to
18457 take a regcache. Adjust.
18458 * linux-m68k-low.c (m68k_fill_gregset, m68k_store_gregset)
18459 (m68k_fill_fpregset, m68k_store_fpregset, m68k_get_pc,
18460 (m68k_set_pc): Change prototype to take a regcache. Adjust.
18461 * linux-mips-low.c (mips_get_pc):
18462 (mips_set_pc): Change prototype to take a regcache. Adjust.
18463 (mips_reinsert_addr): Adjust.
18464 (mips_collect_register): Change prototype to take a regcache.
18465 Adjust.
18466 (mips_supply_register):
18467 (mips_collect_register_32bit, mips_supply_register_32bit)
18468 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
18469 (mips_store_fpregset): Ditto.
43aaf8b6
PA
18470 * linux-ppc-low.c (ppc_supply_ptrace_register)
18471 (ppc_supply_ptrace_register): Ditto.
442ea881
PA
18472 (parse_spufs_run): Adjust.
18473 (ppc_get_pc, ppc_set_pc, ppc_fill_gregset, ppc_fill_vsxregset)
18474 (ppc_store_vsxregset, ppc_fill_vrregset, ppc_store_vrregset)
18475 (ppc_fill_evrregset, ppc_store_evrregset): Change prototype to
18476 take a regcache. Adjust.
18477 * linux-s390-low.c (s390_collect_ptrace_register)
18478 (s390_supply_ptrace_register, s390_fill_gregset, s390_get_pc)
18479 (s390_set_pc): Change prototype to take a regcache. Adjust.
18480 (s390_arch_setup): Adjust.
18481 * linux-sh-low.c (sh_get_pc, sh_breakpoint_at)
18482 (sh_fill_gregset): Change prototype to take a regcache. Adjust.
18483 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
18484 (sparc_fill_gregset, sparc_store_gregset_from_stack)
18485 (sparc_store_gregset, sparc_get_pc): Change prototype to take a
18486 regcache. Adjust.
18487 (sparc_breakpoint_at): Adjust.
18488 * linux-xtensa-low.c (xtensa_fill_gregset):
18489 (xtensa_store_gregset):
18490 (xtensa_fill_xtregset, xtensa_store_xtregset, xtensa_get_pc)
18491 (xtensa_set_pc): Change prototype to take a regcache. Adjust.
18492 * nto-low.c (nto_fetch_registers, nto_store_registers): Change
18493 prototype to take a regcache. Adjust.
18494 * win32-arm-low.c (arm_fetch_inferior_register)
18495 (arm_store_inferior_register): Change prototype to take a
18496 regcache. Adjust.
18497 * win32-i386-low.c (i386_fetch_inferior_register)
18498 (i386_store_inferior_register): Change prototype to take a
18499 regcache. Adjust.
18500 * win32-low.c (child_fetch_inferior_registers)
18501 (child_store_inferior_registers): Change prototype to take a
18502 regcache. Adjust.
18503 (win32_wait): Adjust.
18504 (win32_fetch_inferior_registers): Change prototype to take a
18505 regcache. Adjust.
18506 (win32_store_inferior_registers): Adjust.
18507 * win32-low.h (struct win32_target_ops) <fetch_inferior_register,
18508 store_inferior_register>: Change prototype to take a regcache.
18509
60c3d7b0
DE
185102010-01-20 Doug Evans <dje@google.com>
18511
18512 * linux-low.c (linux_create_inferior): Wrap use of __SIGRTMIN in
18513 #ifdef.
18514 (linux_wait_for_event1, linux_init_signals): Ditto.
ec8ebe72 18515 (W_STOPCODE): Provide definition if missing.
60c3d7b0 18516
dc146f7c
VP
185172010-01-13 Vladimir Prus <vladimir@codesourcery.com>
18518
18519 * linux-low.c (linux_core_of_thread): New.
18520 (compare_ints, show_process, list_threads): New.
18521 (linux_qxfer_osdata): Report threads and cores.
18522 (linux_target_op): Register linux_core_of_thread.
18523 * remote-utils.c (prepare_resume_reply): Report the core.
18524 (buffer_xml_printf): Support %d specifier.
18525 * server.c (handle_threads_qxfer_proper, handle_threads_qxfer):
18526 New.
18527 (handle_query): Handle qXfer:threads. Announce availability
18528 thereof.
18529 * target.h (struct target_ops): New field core_of_thread.
18530
7803799a
UW
185312010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
18532
18533 * Makefile.in (clean): Remove new generated files.
18534 (reg-s390.o, reg-s390.c): Remove rules.
18535 (reg-s390x.o, reg-s390x.c): Likewise.
18536 (s390-linux32.o, s390-linux32.c): Add rules.
18537 (s390-linux64.o, s390-linux64.c): Likewise.
18538 (s390x-linux64.o, s390x-linux64.c): Likewise.
18539 * configure.srv (s390*-*-linux*): Update srv_regobj and srv_xmlfiles.
18540 * linux-s390-low.c: Include <elf.h>.
18541 (HWCAP_S390_HIGH_GPRS): Define if undefined.
18542 (init_registers_s390): Remove prototype.
18543 (init_registers_s390x): Likewise.
18544 (init_registers_s390_linux32): Add prototype.
18545 (init_registers_s390_linux64): Likewise.
18546 (init_registers_s390x_linux64): Likewise.
18547 (s390_num_regs_3264): New define.
18548 (s390_regmap_3264): New global variable.
18549 (s390_cannot_fetch_register): Remove obsolete check.
18550 (s390_cannot_store_register): Likewise.
18551 (s390_collect_ptrace_register): Handle upper/lower register halves.
18552 (s390_supply_ptrace_register): Likewise.
18553 (s390_fill_gregset): Update to register number changes.
18554 (s390_get_hwcap): New routine.
18555 (s390_arch_setup): Detect 32-bit process running on 64-bit system.
18556 Install appropriate regmap and register set.
18557
6e7ffa39
JB
185582010-01-01 Joel Brobecker <brobecker@adacore.com>
18559
18560 * server.c (gdbserver_version): Update copyright year to 2010.
18561 * gdbreplay.c (gdbreplay_version): Likewise.
18562
957f3f49
DE
185632009-12-28 Doug Evans <dje@google.com>
18564
18565 * linux-low.c: Delete inclusion of ansidecl.h, elf/common.h,
18566 elf/external.h. Include <elf.h> instead but only if necessary.
18567
ca5c370d
PA
185682009-12-28 Pedro Alves <pedro@codesourcery.com>
18569
18570 * linux-low.c (linux_remove_process): Remove `detaching'
18571 parameter. Don't release/detach from thread_db here.
18572 (linux_kill): Release/detach from thread_db here, ...
18573 (linux_detach): ... and here, before actually detaching.
18574 (linux_wait_1): ... and here, when a process exits.
18575 * thread-db.c (any_thread_of): New.
18576 (thread_db_free): Switch the current inferior to a thread of the
18577 passed in process.
18578
4ee62156
DE
185792009-12-21 Doug Evans <dje@google.com>
18580
d90e6a88
DE
18581 * linux-x86-low.c: Delete outdated comment about Elf32_Phdr.
18582
c5f62d5f
DE
18583 * linux-low.c (kill_lwp): Use __NR_tkill instead of SYS_tkill.
18584 Move definition of tkill_failed to ifdef __NR_tkill to avoid gcc
18585 warning ifndef __NR_tkill. Move setting of errno there too.
18586 Delete unnecessary resetting of errno after syscall.
18587 Minor comment changes to match gdb/linux-nat.c:kill_lwp.
18588
10e86dd7
DE
18589 * configure.ac: Check for dladdr.
18590 * config.in: Regenerate.
18591 * configure: Regenerate.
18592 * thread-db.c (dladdr_to_soname): Only define ifdef HAVE_DLADDR.
18593 (try_thread_db_load): Update.
18594
4ee62156
DE
18595 * linux-low.c (my_waitpid): Delete unnecessary prototype.
18596
00f515da
DE
185972009-12-18 Doug Evans <dje@google.com>
18598
e9464885
DE
18599 * event-loop.c: Include unistd.h if it exists.
18600
07d4f67e
DE
18601 * linux-low.c (my_waitpid): Move definition away from being in
18602 between linux_tracefork_child/linux_test_for_tracefork.
18603
00f515da
DE
18604 * gdb_proc_service.h (psaddr_t): Fix type.
18605 * thread-db.c (thread_db_info.td_thr_tls_get_addr_p): Fix
18606 signature to match glibc.
18607
1de1badb
DE
186082009-12-16 Doug Evans <dje@google.com>
18609
18610 * linux-low.c (linux_read_memory): Fix argument to read.
18611
aeeb81d1
PA
186122009-11-26 Pedro Alves <pedro@codesourcery.com>
18613
18614 * win32-low.c (get_child_debug_event): On EXIT_THREAD_DEBUG_EVENT
18615 events, don't leave current_inferior pointing at null.
18616
10357975
PA
186172009-11-26 Pedro Alves <pedro@codesourcery.com>
18618
18619 * win32-low.c (LOG): Delete.
18620 (OUTMSG): Output to stderr.
18621 (OUTMSG2): Conditionalize on `debug_threads' variable, instead of
18622 on compile time LOG macro.
18623 (win32_wait): Fix debug output.
18624
cf6e3471
PA
186252009-11-26 Pedro Alves <pedro@codesourcery.com>
18626
18627 * win32-low.c (win32_add_one_solib): If the dll name is
18628 "ntdll.dll", prepend the system directory to the dll path.
18629
0c85e18e
MK
186302009-11-17 Daniel Jacobowitz <dan@codesourcery.com>
18631
18632 * m68k-tdep.c (m68k_gdbarch_init): Reuse previous initialization.
18633
9ac544ce 186342009-11-17 Nathan Sidwell <nathan@codesourcery.com>
889bf7c5 18635 Vladimir Prus <vladimir@codesourcery.com>
9ac544ce
MK
18636
18637 * Makefile.in (reg-cf.o, reg-cf.c): New targets.
18638 * configure.ac: Check for __mcoldfire__ and set
18639 gdb_cv_m68k_is_coldfire.
18640 * configure.srv: Use gdb_cv_m68k_is_coldfire to select between
18641 reg-cf.o and reg-m68k.o.
18642 * configure: Regenerated.
18643
fd7dd3e6
PA
186442009-11-16 Pedro Alves <pedro@codesourcery.com>
18645
18646 * linux-low.c (linux_remove_process): Add `detaching' parameter.
18647 Pass it to thread_db_free.
18648 (linux_kill, linux_detach, linux_wait_1): Adjust to pass the
18649 proper `detaching' argument to linux_remove_process.
18650 * linux-low.h (thread_db_free): Add `detaching' parameter.
18651 * thread-db.c (thread_db_init): Pass false as `detaching' argument
18652 to thread_db_free.
18653 (thread_db_free): Add `detaching' parameter. Only
18654 call td_ta_clear_event if detaching from process.
18655
75aa492e
MK
186562009-11-12 Maxim Kuvyrkov <maxim@codesourcery.com>
18657
18658 * thread-db.c (thread_db_free): Fix typo.
18659
21e1bee4
PP
186602009-11-11 Paul Pluzhnikov <ppluzhnikov@google.com>
18661
18662 PR gdb/10838
18663 * thread-db.c (thread_db_free): Call td_ta_clear_event.
18664
8838b45e
NS
186652009-11-03 Nathan Sidwell <nathan@codesourcery.com>
18666
18667 * configure.ac (i[34567]86-*): Check if we're targetting x86-64
18668 with an i686 compiler.
18669 * configure.srv (i[34567]86-*-linux*): Pull in x86-64 handling if
18670 needed.
18671 * configure: Rebuilt.
18672
8a35fb51
SL
186732009-10-29 Sandra Loosemore <sandra@codesourcery.com>
18674
18675 PR gdb/10783
18676
18677 * server.c (handle_search_memory_1): Correct read_addr initialization
18678 in loop for searching subsequent chunks.
18679
96f15937
PP
186802009-10-29 Paul Pluzhnikov <ppluzhnikov@google.com>
18681
18682 * configure.ac: New --with-libthread-db option.
18683 * thread-db.c: Allow direct dependence on libthread_db.
18684 (thread_db_free): Adjust.
18685 * config.in: Regenerate.
18686 * configure: Likewise.
889bf7c5 18687
5f7d1694
PP
186882009-10-28 Paul Pluzhnikov <ppluzhnikov@google.com>
18689
18690 PR gdb/10757
18691 * thread-db.c (attach_thread): New function.
18692 (maybe_attach_thread): Return success/failure.
18693 (find_new_threads_callback): Adjust.
889bf7c5
PA
18694 (thread_db_find_new_threads): Loop until no new threads.
18695
88e3b899
PA
186962009-10-13 Pedro Alves <pedro@codesourcery.com>
18697
18698 * proc-service.c (ps_lgetregs): Formatting.
18699
cdbfd419
PP
187002009-10-08 Paul Pluzhnikov <ppluzhnikov@google.com>
18701
18702 * acinclude.m4: (SRV_CHECK_THREAD_DB, SRV_CHECK_TLS_GET_ADDR): Remove.
18703 * configure.ac: Adjust.
18704 * linux-low.h (struct process_info_private): Move members to struct
18705 thread_db.
18706 (thread_db_free, thread_db_handle_monitor_command): New prototype.
18707 * linux-low.c (linux_remove_process): Adjust.
18708 (linux_wait_for_event_1, linux_look_up_symbols): Likewise.
18709 * server.c (handle_query): Move code ...
18710 (handle_monitor_command): ... here. New function.
18711 * target.h (struct target_ops): New member.
18712 * thread-db.c (struct thread_db): New.
18713 (libthread_db_search_path): New variable.
18714 (thread_db_create_event, thread_db_enable_reporting)
18715 (find_one_thread, maybe_attach_thread, find_new_threads_callback)
18716 (thread_db_find_new_threads, (thread_db_get_tls_address): Adjust.
18717 (try_thread_db_load_1, dladdr_to_soname): New functions.
18718 (try_thread_db_load, thread_db_load_search): New functions.
18719 (thread_db_init): Search for libthread_db.
18720 (thread_db_free): New function.
18721 (thread_db_handle_monitor_command): Likewise.
18722 * config.in: Regenerate.
18723 * configure: Regenerate.
889bf7c5 18724
4168d2d6
UW
187252009-09-27 Ulrich Weigand <uweigand@de.ibm.com>
18726
18727 * spu-low.c (spu_kill): Wait for inferior to terminate.
18728 Call clear_inferiors.
18729 (spu_detach): Call clear_inferiors.
18730
81ecdfbb
RW
187312009-08-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
18732
18733 * aclocal.m4: Regenerate.
18734 * config.in: Likewise.
18735 * configure: Likewise.
18736
0b9ff2c0
UW
187372009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
18738
18739 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Define.
18740 (parse_spufs_run): New function.
18741 (ppc_get_pc, ppc_set_pc): Detect and handle SPU PC.
18742 (ppc_breakpoint_at): Handle SPU breakpoints.
18743
efcbbd14
UW
187442009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
18745
18746 * linux-low.c: Include <sys/stat.h> and <sys/vfs.h>.
18747 (SPUFS_MAGIC): Define.
18748 (spu_enumerate_spu_ids): New function.
18749 (linux_qxfer_spu): New function.
18750 (linux_target_ops): Install linux_qxfer_spu.
18751
f4d9bade
UW
187522009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
18753
18754 * configure.srv (powerpc*-*-linux*): Add powerpc-cell32l.o
18755 and powerpc-cell64l.o to srv_regobj. Add rs6000/powerpc-cell32l.xml
18756 and rs6000/powerpc-cell64l.xml to srv_xmlfiles.
18757 * Makefile.in (powerpc-cell32l.o, powerpc-cell32l.c): New rules.
18758 (powerpc-cell64l.o, powerpc-cell64l.c): Likewise.
18759 (clean): Handle powerpc-cell32l.c and powerpc-cell64l.c.
18760 * linux-ppc-low.c (PPC_FEATURE_CELL): Define.
18761 (init_registers_powerpc_cell32l): Add prototype.
18762 (init_registers_powerpc_cell64l): Likewise.
18763 (ppc_arch_setup): Detect Cell/B.E. architecture.
18764
96e946ca
RW
187652009-07-30 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
18766
18767 * Makefile.in (datarootdir): New variable.
18768
58d6951d
DJ
187692009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
18770
18771 * linux-low.c (linux_write_memory): Update debugging output.
18772 * Makefile.in (clean): Add new descriptions.
18773 (arm-with-vfpv2.o, arm-with-vfpv2.c, arm-with-vfpv3.o)
18774 (arm-with-vfpv3.c, arm-with-neon.o, arm-with-neon.c): New rules.
18775 * configure.srv: Add new files for arm*-*-linux*.
18776 * linux-arm-low.c: Add new declarations.
18777 (PTRACE_GETVFPREGS, PTRACE_SETVFPREGS): Define if undefined.
18778 (arm_hwcap, HWCAP_VFP, HWCAP_IWMMXT, HWCAP_NEON, HWCAP_VFPv3)
18779 (HWCAP_VFPv3D16): New.
18780 (arm_fill_wmmxregset, arm_store_wmmxregset): Check HWCAP_IWMMXT
18781 instead of __IWMMXT__.
18782 (arm_fill_vfpregset, arm_store_vfpregset, arm_get_hwcap)
18783 (arm_arch_setup): New.
18784 (target_regsets): Remove #ifdef. Add VFP regset.
18785 (the_low_target): Use arm_arch_setup.
18786
12b42a12
DJ
187872009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
18788
18789 * linux-low.c (linux_kill_one_lwp): Adjust kernel workaround to skip
18790 the main thread again.
18791
ac8c974e
AR
187922009-07-06 Aleksandar Ristovski <aristovski@qnx.com>
18793
18794 Adding Neutrino gdbserver.
18795 * configure: Regenerated.
18796 * configure.ac: Add case for srv_qnx and set LIBS accordingly.
18797 * configure.srv (i[34567]86-*-nto*): New target.
18798 * nto-low.c, nto-low.h, nto-x86-low.c: New files.
18799 * remote-utils.c [__QNX__]: Include sys/iomgr.h
18800 (nto_comctrl) [__QNX__]: New function.
18801 (enable_async_io, disable_async_io) [__QNX__]: Call nto_comctrl.
18802
4424e0c3 188032009-07-05 Danny Backx <dannybackx@users.sourceforge.net>
7437790a
PA
18804
18805 * configure.srv (i[34567]86-*-mingw32ce*): Add i386-low.o to
18806 srv_tgtobj.
18807
912cf4ba
PA
188082009-07-04 Danny Backx <dannybackx@users.sourceforge.net>
18809 Pedro Alves <pedro@codesourcery.com>
18810
18811 * win32-i386-low.c (i386_get_thread_context): Handle systems that
18812 don't support CONTEXT_EXTENDED_REGISTERS.
18813 (i386_win32_breakpoint, i386_win32_breakpoint_len): New.
18814 (the_low_target): Install them.
18815 * win32-low.c (get_child_debug_event): Handle WaitForDebugEvent
18816 failing with ERROR_PIPE_NOT_CONNECTED.
18817
aa5ca48f
DE
188182009-06-30 Doug Evans <dje@google.com>
18819 Pierre Muller <muller@ics.u-strasbg.fr>
18820
18821 Add h/w watchpoint support to x86-linux, win32-i386.
18822 * Makefile.in (SFILES): Add i386-low.c
18823 (i386_low_h): Define.
18824 (i386-low.o): Add dependencies.
18825 (linux-x86-low.o): Add i386-low.h dependency.
18826 (win32-i386-low.o): Ditto.
18827 * i386-low.c: New file.
18828 * i386-low.h: New file.
18829 * configure.srv (i[34567]86-*-cygwin*): Add i386-low.o to srv_tgtobj.
18830 (i[34567]86-*-linux*, i[34567]86-*-mingw*, x86_64-*-linux*): Ditto.
18831 * linux-low.c (linux_add_process): Initialize arch_private.
18832 (linux_remove_process): Free arch_private.
18833 (add_lwp): Initialize arch_private.
18834 (delete_lwp): Free arch_private.
18835 (linux_resume_one_lwp): Call the_low_target.prepare_to_resume if
18836 provided.
18837 * linux-low.h (process_info_private): New member arch_private.
18838 (lwp_info): New member arch_private.
18839 (linux_target_ops): New members new_process, new_thread,
18840 prepare_to_resume.
18841 (ptid_of): New macro.
18842 * linux-x86-low.c: Include stddef.h, i386-low.h.
18843 (arch_process_info): New struct.
18844 (arch_lwp_info): New struct.
18845 (x86_linux_dr_get, x86_linux_dr_set): New functions.
18846 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
18847 (i386_dr_low_get_status): New function.
18848 (x86_insert_point, x86_remove_point): New functions.
18849 (x86_stopped_by_watchpoint): New function.
18850 (x86_stopped_data_address): New function.
18851 (x86_linux_new_process, x86_linux_new_thread): New functions.
18852 (x86_linux_prepare_to_resume): New function.
18853 (the_low_target): Add entries for insert_point, remove_point,
18854 stopped_by_watchpoint, stopped_data_address, new_process, new_thread,
18855 prepare_to_resume.
18856 * server.c (debug_hw_points): New global.
18857 (monitor_show_help): Document set debug-hw-points.
18858 (handle_query): Process "set debug-hw-points".
18859 * server.h (debug_hw_points): Declare.
18860 (paddress): Declare.
18861 * utils.c (NUMCELLS, CELLSIZE): New macros.
18862 (get_sell, xsnprintf, paddress): New functions.
18863 * win32-arm-low.c (the_low_target): Add entries for insert_point,
18864 remove_point, stopped_by_watchpoint, stopped_data_address.
18865 * win32-i386-low.c: Include i386-low.h.
18866 (debug_reg_state): Replaces dr.
18867 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
18868 (i386_dr_low_get_status): New function.
18869 (i386_insert_point, i386_remove_point): New functions.
18870 (i386_stopped_by_watchpoint): New function.
18871 (i386_stopped_data_address): New function.
18872 (i386_initial_stuff): Update.
18873 (get_thread_context,set_thread_context,i386_thread_added): Update.
18874 (the_low_target): Add entries for insert_point,
18875 remove_point, stopped_by_watchpoint, stopped_data_address.
18876 * win32-low.c (win32_insert_watchpoint): New function.
18877 (win32_remove_watchpoint): New function.
18878 (win32_stopped_by_watchpoint): New function.
18879 (win32_stopped_data_address): New function.
18880 (win32_target_ops): Add entries for insert_watchpoint,
18881 remove_watchpoint, stopped_by_watchpoint, stopped_data_address.
18882 * win32-low.h (win32_target_ops): New members insert_point,
18883 remove_point, stopped_by_watchpoint, stopped_data_address.
18884
d993e290
PA
188852009-06-25 Pedro Alves <pedro@codesourcery.com>
18886
18887 * server.c (process_serial_event): Re-return unsupported, not
18888 error, if the type isn't recognized. Re-allow supporting only
18889 insert or remove packets. Also call require_running for
18890 breakpoints. Add missing break statement to default case. Tidy.
18891 * target.h (struct target_ops): Rename insert_watchpoint to
18892 insert_point, and remove_watchpoint to remove_point.
18893
18894 * linux-low.h (struct linux_target_ops): Likewise.
18895 * linux-low.c (linux_insert_watchpoint): Rename to ...
18896 (linux_insert_point): ... this. Adjust.
18897 (linux_remove_watchpoint): Rename to ...
18898 (linux_remove_point): ... this. Adjust.
18899 (linux_target_ops): Adjust.
18900 * linux-crisv32-low.c (cris_insert_watchpoint): Rename to ...
18901 (cris_insert_point): ... this.
18902 (cris_remove_watchpoint): Rename to ...
18903 (cris_remove_point): ... this.
18904 (the_low_target): Adjust.
18905
0f54c268
PM
189062009-06-24 Pierre Muller <muller@ics.u-strasbg.fr>
18907
18908 * server.c (handle_v_kill): Pass signal_pid to
18909 kill_inferior if multi_process is zero.
18910
c6314022
AR
189112009-06-23 Aleksandar Ristovski <aristovski@qnx.com>
18912
18913 * server.c (process_serial_event): Add support for Z0 and Z1 packet.
18914 * target.h (target_ops): Comment for *_watchpoint to make it clear
18915 the functions can get types '0' and '1'.
18916
4463ce24
AR
189172009-06-22 Aleksandar Ristovski <aristovski@qnx.com>
18918
18919 * linux-low.c (usr_fetch_inferior_registers): Remove check for regno 0.
18920 * proc-service.c (ps_lgetregs): Pass -1 to fetch all registers.
18921 * regcache.c (get_regcache): Likewise.
18922 * spu-low.c (spu_fetch_registers): Remove 0 to -1 conversion.
18923 * win32-low.c (child_fetch_inferior_registers): Remove check for
18924 regno 0.
18925
cf8fd78b
PA
189262009-06-19 Aleksandar Ristovski <aristovski@qnx.com>
18927 Pedro Alves <pedro@codesourcery.com>
18928
18929 * target.h (struct target_ops) <supports_multi_process>: New
18930 callback.
18931 (target_supports_multi_process): New.
18932 * server.c (handle_query): Even if GDB reports support, only
18933 enable multi-process if the target also supports it. Report
18934 multi-process support only if the target backend supports it.
18935 * linux-low.c (linux_supports_multi_process): New function.
18936 (linux_target_ops): Install it as target_supports_multi_process
18937 callback.
18938
47c0c975
DE
189392009-05-24 Doug Evans <dje@google.com>
18940
e09875d4
DE
18941 Global renaming of find_thread_pid to find_thread_ptid.
18942 * server.h (find_thread_ptid): Renamed from find_thread_pid.
18943 * inferiors.c (find_thread_ptid): Renamed from find_thread_pid.
18944 All callers updated.
18945
e27d73f6
DE
18946 * linux-low.c (handle_extended_wait): Use linux_resume_one_lwp
18947 to resume the newly created thread, don't call ptrace (PTRACE_CONT)
18948 directly.
18949
47c0c975
DE
18950 * linux-low.c (get_stop_pc): Print pc if debug_threads.
18951 (check_removed_breakpoint, linux_wait_for_lwp): Ditto.
18952 (linux_resume_one_lwp): Ditto.
18953
2acc282a
DE
189542009-05-23 Doug Evans <dje@google.com>
18955
18956 * linux-low.c (linux_resume_one_lwp): Change type of first arg
18957 from struct inferior_list_entry * to struct lwp_info *.
18958 All callers updated.
18959
9f1036c1
DE
189602009-05-13 Doug Evans <dje@google.com>
18961
18962 * linux-x86-low.c: Don't include assert.h.
18963 (x86_siginfo_fixup): Use fatal, not assert.
18964 (x86_arch_setup): Fix comment.
18965
d0722149
DE
189662009-05-12 Doug Evans <dje@google.com>
18967
18968 Biarch support for i386/amd64 gdbserver.
18969 * Makefile.in (SFILES): Remove linux-i386-low.c, linux-x86-64-low.c.
18970 Add linux-x86-low.c.
18971 (linux-i386-low.o, linux-x86-64-low.o): Delete.
18972 (linux-x86-low.o): Add.
18973 * linux-x86-64-low.c: Delete.
18974 * linux-i386-low.c: Delete.
18975 * linux-x86-low.c: New file.
18976 * configure.srv (i?86-linux srv_tgtobj): Replace linux-i386-low.o with
18977 linux-x86-low.o.
18978 (x86_64-linux srv_tgtobj): Replace linux-x86-64-low.o with
18979 linux-x86-low.o.
18980 (x86_64-linux srv_regobj): Add reg-i386-linux.o.
18981 * linux-low.c: Include ansidecl.h, elf/common.h, elf/external.h.
18982 (linux_child_pid_to_exec_file): New function.
18983 (elf_64_header_p, elf_64_file_p): New functions.
18984 (siginfo_fixup): New function.
18985 (linux_xfer_siginfo): New local inf_siginfo. Call siginfo_fixup to
18986 give target a chance to convert layout.
18987 * linux-low.h (linux_target_ops): New member siginfo_fixup.
18988 (linux_child_pid_to_exec_file, elf_64_file_p): Declare.
18989
fdeb2a12
DE
189902009-05-07 Doug Evans <dje@google.com>
18991
18992 * linux-low.c (regsets_fetch_inferior_registers): Fix memory leak.
18993 (regsets_store_inferior_registers): Ditto.
18994
a6dbe5df
PA
189952009-05-06 Pedro Alves <pedro@codesourcery.com>
18996
18997 PR server/10048
18998
18999 * linux-low.c (must_set_ptrace_flags): Delete.
19000 (linux_create_inferior): Set `lwp->must_set_ptrace_flags' instead
19001 of the global.
19002 (linux_attach_lwp_1): Don't set PTRACE_SETOPTIONS here. Set
19003 `lwp->must_set_ptrace_flags' instead.
ba42693b 19004 (linux_wait_for_event_1): Set ptrace options here.
a6dbe5df
PA
19005 (linux_wait_1): ... not here.
19006
5091eb23
DE
190072009-04-30 Doug Evans <dje@google.com>
19008
9f767825
DE
19009 * inferiors.c (started_inferior_callback): New function.
19010 (attached_inferior_callback): New function.
19011 (have_started_inferiors_p, have_attached_inferiors_p): New functions.
19012 * server.c (print_started_pid, print_attached_pid): New functions.
19013 (detach_or_kill_for_exit): New function.
19014 (main): Call it instead of for_each_inferior (kill_inferior_callback).
19015 * server.h (have_started_inferiors_p): Declare.
19016 (have_attached_inferiors_p): Declare.
19017
5091eb23
DE
19018 * inferiors.c (remove_process): Fix memory leak, free process.
19019 * linux-low.c (linux_remove_process): New function.
19020 (linux_kill): Call it instead of remove_process.
19021 (linux_detach, linux_wait_1): Ditto.
19022
155c8968
PA
190232009-04-19 Danny Backx <dannybackx@users.sourceforge.net>
19024
19025 * configure.srv: Add x86 Windows CE target.
19026
7fe519cb
UW
190272009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
19028
19029 * inferiors.c (get_thread_process): Make global.
19030 * server.h (get_thread_process): Add prototype.
19031 * thread-db.c (find_one_thread): Use get_thread_process
19032 instead of current_process.
19033 (thread_db_get_tls_address): Do not crash if called when
19034 thread layer is not yet initialized.
19035
5472f405
UW
190362009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
19037
19038 * remote-utils.c (prepare_resume_reply): Null-terminate packet.
19039 * spu-low.c (current_tid): Rename to ...
19040 (current_ptid): ... this.
19041 (fetch_ppc_register, fetch_ppc_memory, store_ppc_memory,
19042 spu_proc_xfer_spu, spu_resume, spu_request_interrupt): Use
19043 ptid_get_lwp (current_ptid) instead of current_tid.
19044 (spu_kill, spu_detach, spu_join, spu_wait): Use pid argument
19045 instead of current_tid. Use find_process_pid to verify pid
19046 argument is valid. Pass proper argument to remove_process.
19047 (spu_thread_alive): Compare current_ptid instead of current_tid.
19048 (spu_resume): Likewise.
19049
55ac2b99
PA
190502009-04-02 Pedro Alves <pedro@codesourcery.com>
19051
19052 * linux-low.c (usr_store_inferior_registers): Declare local `pid'
19053 variable.
19054
95954743
PA
190552009-04-01 Pedro Alves <pedro@codesourcery.com>
19056
19057 Implement the multiprocess extensions, and add linux multiprocess
19058 support.
19059
19060 * server.h (ULONGEST): Declare.
19061 (struct ptid, ptid_t): New.
19062 (minus_one_ptid, null_ptid): Declare.
19063 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
19064 (ptid_get_tid, ptid_equal, ptid_is_pid): Declare.
19065 (struct inferior_list_entry): Change `id' type from unsigned from
19066 to ptid_t.
19067 (struct sym_cache, struct breakpoint, struct
19068 process_info_private): Forward declare.
19069 (struct process_info): Declare.
19070 (current_process): Declare.
19071 (all_processes): Declare.
19072 (initialize_inferiors): Declare.
19073 (add_thread): Adjust to use ptid_t.
19074 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): Ditto.
19075 (add_process, remove_process, find_thread_pid): Declare.
19076 (find_inferior_id): Adjust to use ptid_t.
19077 (cont_thread, general_thread, step_thread): Change type to ptid_t.
19078 (multi_process): Declare.
19079 (push_event): Adjust to use ptid_t.
19080 (read_ptid, write_ptid): Declare.
19081 (prepare_resume_reply): Adjust to use ptid_t.
19082 (clear_symbol_cache): Declare.
19083 * inferiors.c (all_processes): New.
19084 (null_ptid, minus_one_ptid): New.
19085 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
19086 (ptid_get_tid, ptid_equal, ptid_is_pid): New.
19087 (add_thread): Change unsigned long to ptid. Remove gdb_id
19088 parameter. Adjust.
19089 (thread_id_to_gdb_id, thread_to_gdb_id): Change unsigned long to ptid.
19090 (gdb_id_to_thread): Rename to ...
19091 (find_thread_pid): ... this. Change unsigned long to ptid.
19092 (gdb_id_to_thread_id, find_inferior_id): Change unsigned long to ptid.
19093 (loaded_dll, pull_pid_from_list): Adjust.
19094 (add_process, remove_process, find_process_pid)
19095 (get_thread_process, current_process, initialize_inferiors): New.
19096 * target.h (struct thread_resume) <thread>: Change type to ptid_t.
19097 (struct target_waitstatus) <related_pid>: Ditto.
19098 (struct target_ops) <kill, detach>: Add `pid' argument. Change
19099 return type to int.
19100 (struct target_ops) <join>: Add `pid' argument.
19101 (struct target_ops) <thread_alive>: Change pid's type to ptid_t.
19102 (struct target_ops) <wait>: Add `ptid' field. Change return type
19103 to ptid.
19104 (kill_inferior, detach_inferior, join_inferior): Add `pid' argument.
19105 (mywait): Add `ptid' argument. Change return type to ptid_t.
19106 (target_pid_to_str): Declare.
19107 * target.c (set_desired_inferior): Adjust to use ptids.
19108 (mywait): Add new `ptid' argument. Adjust.
19109 (target_pid_to_str): New.
19110 * mem-break.h (free_all_breakpoints): Declare.
19111 * mem-break.c (breakpoints): Delelete.
19112 (set_breakpoint_at, delete_breakpoint, find_breakpoint_at)
19113 (check_mem_read, check_mem_write, delete_all_breakpoints): Adjust
19114 to use per-process breakpoint list.
19115 (free_all_breakpoints): New.
19116 * remote-utils.c (struct sym_cache) <name>: Drop `const'.
19117 (symbol_cache, all_symbols_looked_up): Delete.
19118 (hexchars): New.
19119 (ishex, unpack_varlen_hex, write_ptid, hex_or_minus_one,
19120 read_ptid): New.
19121 (prepare_resume_reply): Change ptid argument's type from unsigned
19122 long to ptid_t. Adjust. Implement W;process and X;process.
19123 (free_sym_cache, clear_symbol_cache): New.
19124 (look_up_one_symbol): Adjust to per-process symbol cache. *
19125 * server.c (cont_thread, general_thread, step_thread): Change type
19126 to ptid_t.
19127 (attached): Delete.
19128 (multi_process): New.
19129 (last_ptid): Change type to ptid_t.
19130 (struct vstop_notif) <ptid>: Change type to ptid_t.
19131 (queue_stop_reply, push_event): Change `ptid' argument's type to
19132 ptid_t.
19133 (discard_queued_stop_replies): Add `pid' argument.
19134 (start_inferior): Adjust to use ptids. Adjust to mywait interface
19135 changes. Don't reference the `attached' global.
19136 (attach_inferior): Adjust to mywait interface changes.
19137 (handle_query): Adjust to use ptids. Parse GDB's qSupported
19138 features. Handle and report "multiprocess+". Handle
19139 "qAttached:PID".
19140 (handle_v_cont): Adjust to use ptids. Adjust to mywait interface
19141 changes.
19142 (handle_v_kill): New.
19143 (handle_v_stopped): Adjust to use target_pid_to_str.
19144 (handle_v_requests): Allow multiple attaches and runs when
19145 multiprocess extensions are in effect. Handle "vKill".
19146 (myresume): Adjust to use ptids.
19147 (queue_stop_reply_callback): Add `arg' parameter. Handle it.
19148 (handle_status): Adjust to discard_queued_stop_replies interface
19149 change.
19150 (first_thread_of, kill_inferior_callback)
19151 (detach_or_kill_inferior_callback, join_inferiors_callback): New.
19152 (main): Call initialize_inferiors. Adjust to use ptids, killing
19153 and detaching from all inferiors. Handle multiprocess packet
19154 variants.
19155 * linux-low.h: Include gdb_proc_service.h.
19156 (struct process_info_private): New.
19157 (struct linux_target_ops) <pid_of>: Use ptid_get_pid.
19158 <lwpid_of>: Use ptid_get_lwp.
19159 (get_lwp_thread): Adjust.
19160 (struct lwp_info): Add `dead' member.
19161 (find_lwp_pid): Declare.
19162 * linux-low.c (thread_db_active): Delete.
19163 (new_inferior): Adjust comment.
19164 (inferior_pid): Delete.
19165 (linux_add_process): New.
19166 (handle_extended_wait): Adjust.
19167 (add_lwp): Change unsigned long to ptid.
19168 (linux_create_inferior): Add process to processes table. Adjust
19169 to use ptids. Don't set new_inferior here.
19170 (linux_attach_lwp): Rename to ...
19171 (linux_attach_lwp_1): ... this. Add `initial' argument. Handle
19172 it. Adjust to use ptids.
19173 (linux_attach_lwp): New.
19174 (linux_attach): Add process to processes table. Don't set
19175 new_inferior here.
19176 (struct counter): New.
19177 (second_thread_of_pid_p, last_thread_of_process_p): New.
19178 (linux_kill_one_lwp): Add `args' parameter. Handle it. Adjust to
19179 multiple processes.
19180 (linux_kill): Add `pid' argument. Handle it. Adjust to multiple
19181 processes. Remove process from process table.
19182 (linux_detach_one_lwp): Add `args' parameter. Handle it. Adjust
19183 to multiple processes.
19184 (any_thread_of): New.
19185 (linux_detach): Add `pid' argument, and handle it. Remove process
19186 from processes table.
19187 (linux_join): Add `pid' argument. Handle it.
19188 (linux_thread_alive): Change unsighed long argument to ptid_t.
19189 Consider dead lwps as not being alive.
19190 (status_pending_p): Rename `dummy' argument to `arg'. Filter out
19191 threads we're not interested in.
19192 (same_lwp, find_lwp_pid): New.
19193 (linux_wait_for_lwp): Change `pid' argument's type from int to
19194 ptid_t. Adjust.
19195 (linux_wait_for_event): Rename to ...
19196 (linux_wait_for_event_1): ... this. Change `pid' argument's type
19197 from int to ptid_t. Adjust.
19198 (linux_wait_for_event): New.
19199 (linux_wait_1): Add `ptid' argument. Change return type to
19200 ptid_t. Adjust. Use last_thread_of_process_p. Remove processes
19201 that exit from the process table.
19202 (linux_wait): Add `ptid' argument. Change return type to ptid_t.
19203 Adjust.
19204 (mark_lwp_dead): New.
19205 (wait_for_sigstop): Adjust to use ptids. If a process exits while
19206 stopping all threads, mark its main lwp as dead.
19207 (linux_set_resume_request, linux_resume_one_thread): Adjust to use
19208 ptids.
19209 (fetch_register, usr_store_inferior_registers)
19210 (regsets_fetch_inferior_registers)
19211 (regsets_store_inferior_registers, linux_read_memory)
19212 (linux_write_memory): Inline `inferior_pid'.
19213 (linux_look_up_symbols): Adjust to use per-process
19214 `thread_db_active'.
19215 (linux_request_interrupt): Adjust to use ptids.
19216 (linux_read_auxv): Inline `inferior_pid'.
19217 (initialize_low): Don't reference thread_db_active.
19218 * gdb_proc_service.h (struct ps_prochandle) <pid>: Remove.
19219 * proc-service.c (ps_lgetregs): Use find_lwp_pid.
19220 (ps_getpid): Return the pid of the current inferior.
19221 * thread-db.c (proc_handle, thread_agent): Delete.
19222 (thread_db_create_event, thread_db_enable_reporting): Adjust to
19223 per-process data.
19224 (find_one_thread): Change argument type to ptid_t. Adjust to
19225 per-process data.
19226 (maybe_attach_thread): Adjust to per-process data and ptids.
19227 (thread_db_find_new_threads): Ditto.
19228 (thread_db_init): Ditto.
19229 * spu-low.c (spu_create_inferior, spu_attach): Add process to
19230 processes table. Adjust to use ptids.
19231 (spu_kill, spu_detach): Adjust interface. Remove process from
19232 processes table.
19233 (spu_join, spu_thread_alive): Adjust interface.
19234 (spu_wait): Adjust interface. Remove process from processes
19235 table. Adjust to use ptids.
19236 * win32-low.c (current_inferior_tid): Delete.
19237 (current_inferior_ptid): New.
19238 (debug_event_ptid): New.
19239 (thread_rec): Take a ptid. Adjust.
19240 (child_add_thread): Add `pid' argument. Adjust to use ptids.
19241 (child_delete_thread): Ditto.
19242 (do_initial_child_stuff): Add `attached' argument. Add process to
19243 processes table.
19244 (child_fetch_inferior_registers, child_store_inferior_registers):
19245 Adjust.
19246 (win32_create_inferior): Pass 0 to do_initial_child_stuff.
19247 (win32_attach): Pass 1 to do_initial_child_stuff.
19248 (win32_kill): Adjust interface. Remove process from processes
19249 table.
19250 (win32_detach): Ditto.
19251 (win32_join): Adjust interface.
19252 (win32_thread_alive): Take a ptid.
19253 (win32_resume): Adjust to use ptids.
19254 (get_child_debug_event): Ditto.
19255 (win32_wait): Adjust interface. Remove exiting process from
19256 processes table.
19257
bd99dc85
PA
192582009-04-01 Pedro Alves <pedro@codesourcery.com>
19259
19260 Non-stop mode support.
19261
19262 * server.h (non_stop): Declare.
19263 (gdb_client_data, handler_func): Declare.
19264 (delete_file_handler, add_file_handler, start_event_loop):
19265 Declare.
19266 (handle_serial_event, handle_target_event, push_event)
19267 (putpkt_notif): Declare.
19268 * target.h (enum resume_kind): New.
19269 (struct thread_resume): Replace `step' field by `kind' field.
19270 (TARGET_WNOHANG): Define.
19271 (struct target_ops) <wait>: Add `options' argument.
19272 <supports_non_stop, async, start_non_stop>: New fields.
19273 (target_supports_non_stop, target_async): New.
19274 (start_non_stop): Declare.
19275 (mywait): Add `options' argument.
19276 * target.c (mywait): Add `options' argument. Print child exit
19277 notifications here.
19278 (start_non_stop): New.
19279 * server.c (non_stop, own_buf, mem_buf): New globals.
19280 (struct vstop_notif): New.
19281 (notif_queue): New global.
19282 (queue_stop_reply, push_event, discard_queued_stop_replies)
19283 (send_next_stop_reply): New.
19284 (start_inferior): Adjust to use resume_kind. Adjust to mywait
19285 interface changes.
19286 (attach_inferior): In non-stop mode, don't wait for the target
19287 here.
19288 (handle_general_set): Handle QNonStop.
19289 (handle_query): When handling qC, return the current general
19290 thread, instead of the first thread of the list.
19291 (handle_query): If the backend supports non-stop mode, include
19292 QNonStop+ in the qSupported query response.
19293 (handle_v_cont): Adjust to use resume_kind. Handle resume_stop
19294 and non-stop mode.
19295 (handle_v_attach, handle_v_run): Handle non-stop mode.
19296 (handle_v_stopped): New.
19297 (handle_v_requests): Report support for vCont;t. Handle vStopped.
19298 (myresume): Adjust to use resume_kind. Handle non-stop.
19299 (queue_stop_reply_callback): New.
19300 (handle_status): Handle non-stop mode.
19301 (main): Clear non_stop flag on reconnection. Use the event-loop.
19302 Refactor serial protocol handling from here ...
19303 (process_serial_event): ... to this new function. When GDB
19304 selects any thread, select one here. In non-stop mode, wait until
19305 GDB acks all pending events before exiting.
19306 (handle_serial_event, handle_target_event): New.
19307 * remote-utils.c (remote_open): Install remote_desc in the event
19308 loop.
19309 (remote_close): Remove remote_desc from the event loop.
19310 (putpkt_binary): Rename to...
19311 (putpkt_binary_1): ... this. Add `is_notic' argument. Handle it.
19312 (putpkt_binary): New as wrapper around putpkt_binary_1.
19313 (putpkt_notif): New.
19314 (prepare_resume_reply): In non-stop mode, don't change the
19315 general_thread.
19316 * event-loop.c: New.
19317 * Makefile.in (OBJ): Add event-loop.o.
19318 (event-loop.o): New rule.
19319
19320 * linux-low.h (pid_of): Moved here.
19321 (lwpid_of): New.
19322 (get_lwp_thread): Use lwpid_of.
19323 (struct lwp_info): Delete `lwpid' field. Add `suspended' field.
19324 * linux-low.c (pid_of): Delete.
19325 (inferior_pid): Use lwpid_of.
19326 (linux_event_pipe): New.
19327 (target_is_async_p): New.
19328 (delete_lwp): New.
19329 (handle_extended_wait): Use lwpid_of.
19330 (add_lwp): Don't set lwpid field.
19331 (linux_attach_lwp): Adjust debug output. Use lwpid_of.
19332 (linux_kill_one_lwp): If killing a running lwp, stop it first.
19333 Use lwpid_of. Adjust to linux_wait_for_event interface changes.
19334 (linux_detach_one_lwp): If detaching from a running lwp, stop it
19335 first. Adjust to linux_wait_for_event interface changes. Use
19336 lwpid_of.
19337 (linux_detach): Don't delete the main lwp here.
19338 (linux_join): Use my_waitpid. Avoid signal_pid. Use lwpid_of.
19339 (status_pending_p): Don't consider explicitly suspended lwps.
19340 (linux_wait_for_lwp): Take an integer pid instead of a lwp_info
19341 pointer. Add OPTIONS argument. Change return type to int. Use
19342 my_waitpid instead of sleeping. Handle WNOHANG. Use lwpid_of.
19343 (linux_wait_for_event): Take an integer pid instead of a lwp_info
19344 pointer. Add status pointer argument. Return a pid instead of a
19345 status. Use lwpid_of. Adjust to linux_wait_for_lwp interface
19346 changes. In non-stop mode, don't switch to a random thread.
19347 (linux_wait): Rename to...
19348 (linux_wait_1): ... this. Add target_options argument, and handle
19349 it. Adjust to use resume_kind. Use lwpid_of. In non-stop mode,
19350 don't handle the continue thread. Handle TARGET_WNOHANG. Merge
19351 clean exit and signal exit code. Don't stop all threads in
19352 non-stop mode. In all-stop mode, only stop all threads when
19353 reporting a stop to GDB. Handle explicit thread stop requests.
19354 (async_file_flush, async_file_mark): New.
19355 (linux_wait): New.
19356 (send_sigstop): Use lwpid_of.
19357 (wait_for_sigstop): Use lwpid_of. Adjust to linux_wait_for_event
19358 interface changes. In non-stop mode, don't switch to a random
19359 thread.
19360 (linux_resume_one_lwp): Use lwpid_of.
19361 (linux_continue_one_thread, linux_queue_one_thread): Merge into ...
19362 (linux_resume_one_thread): ... this. Handle resume_stop. In
19363 non-stop mode, don't look for pending flag in all threads.
19364 (resume_status_pending_p): Don't consider explicitly suspended
19365 threads.
19366 (my_waitpid): Reimplement. Emulate __WALL.
19367 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
19368 Use lwpid_of.
19369 (sigchld_handler, linux_supports_non_stop, linux_async)
19370 (linux_start_non_stop): New.
19371 (linux_target_ops): Register linux_supports_non_stop, linux_async
19372 and linux_start_non_stop.
19373 (initialize_low): Install SIGCHLD handler.
19374 * thread-db.c (thread_db_create_event, find_one_thread)
19375 (thread_db_get_tls_address): Use lwpid_of.
19376 * win32-low.c (win32_detach): Adjust to use resume_kind.
19377 (win32_wait): Add `options' argument.
19378 * spu-low.c (spu_resume): Adjust to use resume_kind.
19379 (spu_wait): Add `options' argument.
19380
5b1c542e
PA
193812009-04-01 Pedro Alves <pedro@codesourcery.com>
19382
19383 Decouple target code from remote protocol.
19384
19385 * target.h (enum target_waitkind): New.
19386 (struct target_waitstatus): New.
19387 (struct target_ops) <wait>: Return an unsigned long. Take a
19388 target_waitstatus pointer instead of a char pointer.
19389 (mywait): Likewise.
19390 * target.c (mywait): Change prototype to return an unsigned long.
19391 Take a target_waitstatus pointer instead of a char pointer. Adjust.
19392 * server.h (thread_from_wait, old_thread_from_wait): Delete
19393 declarations.
19394 (prepare_resume_reply): Change prototype to take a
19395 target_waitstatus.
19396 * server.c (thread_from_wait, old_thread_from_wait): Delete.
19397 (last_status, last_ptid): New.
19398 (start_inferior): Remove "statusptr" argument. Adjust. Return a
19399 pid instead of a signal.
19400 (attach_inferior): Remove "status" and "signal" parameters.
19401 Adjust.
19402 (handle_query): For qGetTLSAddr, parse the thread id with strtol,
19403 not as an address.
19404 (handle_v_cont, handle_v_attach, handle_v_run, handle_v_kill)
19405 (handle_v_requests, myresume): Remove "status" and "signal"
19406 parameters. Adjust.
19407 (handle_status): New.
19408 (main): Delete local `status'. Adjust.
19409 * remote-utils.c: Include target.h.
19410 (prepare_resume_reply): Change prototype to take a
19411 target_waitstatus. Adjust.
19412
19413 * linux-low.c (linux_wait): Adjust to new target_ops->wait
19414 interface.
19415 * spu-low.c (spu_wait): Adjust.
19416 * win32-low.c (enum target_waitkind, struct target_waitstatus):
19417 Delete.
19418 (win32_wait): Adjust.
19419
2bd7c093
PA
194202009-04-01 Pedro Alves <pedro@codesourcery.com>
19421
19422 * target.h (struct thread_resume): Delete leave_stopped member.
19423 (struct target_ops): Add a `n' argument to the `resume' callback.
19424 * server.c (start_inferior): Adjust.
19425 (handle_v_cont, myresume): Adjust.
19426 * linux-low.c (check_removed_breakpoint): Adjust to resume
19427 interface change, and to removed leave_stopped field.
19428 (resume_ptr): Delete.
19429 (struct thread_resume_array): New.
19430 (linux_set_resume_request): Add new `arg' parameter. Adjust to
19431 resume interface change.
19432 (linux_continue_one_thread, linux_queue_one_thread)
19433 (resume_status_pending_p): Check if the resume field is NULL
19434 instead of checking the leave_stopped member.
19435 (linux_resume): Adjust to the target resume interface change.
19436 * spu-low.c (spu_resume): Adjust to the target resume interface
19437 change.
19438 * win32-low.c (win32_detach, win32_resume): Ditto.
19439
c35fafde
PA
194402009-04-01 Pedro Alves <pedro@codesourcery.com>
19441
19442 * linux-low.c (linux_wait_for_event): Don't clear the `stepping'
19443 flag.
19444 (wait_for_sigstop): Don't leave a finished single-step SIGTRAP
19445 pending.
19446 (linux_continue_one_thread): Only preserve the stepping flag if
19447 there's a pending breakpoint.
19448
0a59d50b
PA
194492009-03-31 Pedro Alves <pedro@codesourcery.com>
19450
19451 * server.c (main): After the inferior having exited, call
19452 remote_close before exiting gdbserver.
19453
f04c6d38
TJB
194542009-03-25 Thiago Jung Bauermann <bauerman@br.ibm.com>
19455
19456 Fix size of FPSCR in Power 7 processors.
19457 * linux-ppc-low.c (PPC_FEATURE_ARCH_2_05): Remove #define.
19458 (PPC_FEATURE_HAS_DFP): New #define.
19459 (ppc_arch_setup): Check for DFP feature instead of ISA 2.05 to decide on
19460 size of the FPSCR.
19461
78e5cee6
PA
194622009-03-23 Pedro Alves <pedro@codesourcery.com>
19463
19464 * server.c (handle_query) Whitespace and formatting.
19465
1b3f6016
PA
194662009-03-22 Pedro Alves <pedro@codesourcery.com>
19467
19468 * i387-fp.c, linux-arm-low.c, linux-cris-low.c,
19469 linux-crisv32-low.c, linux-i386-low.c, linux-low.c,
19470 linux-mips-low.c, linux-s390-low.c, linux-sparc-low.c,
19471 linux-x86-64-low.c, linux-xtensa-low.c, proc-service.c,
19472 regcache.c, remote-utils.c, server.c, spu-low.c, target.h,
19473 thread-db.c, win32-low.c, xtensa-xtregs.c, gdbreplay.c,
19474 Makefile.in, configure.ac: Fix whitespace throughout.
19475 * configure: Regenerate.
19476
a07b2135
PA
194772009-03-22 Pedro Alves <pedro@codesourcery.com>
19478
19479 * inferiors.c (find_inferior): Make it safe for the callback
19480 function to delete the currently iterated inferior.
19481
67cc2626
PA
194822009-03-22 Pedro Alves <pedro@codesourcery.com>
19483
19484 * Makefile.in (linuw_low_h): Move higher.
19485 (thread-db.o): Depend on $(linux_low_h).
19486
54a0b537
PA
194872009-03-17 Pedro Alves <pedro@codesourcery.com>
19488
19489 Rename "process" to "lwp" throughout.
19490
19491 * linux-low.c (all_processes): Rename to...
19492 (all_lwps): ... this.
19493 (inferior_pid, handle_extended_wait, get_stop_pc): Adjust.
19494 (add_process): Rename to ...
19495 (add_lwp): ... this. Adjust.
19496 (linux_create_inferior): Adjust.
19497 (linux_attach_lwp): Adjust.
19498 (linux_attach): Adjust.
19499 (linux_kill_one_process): Rename to ...
19500 (linux_kill_one_lwp): ... this. Adjust.
19501 (linux_kill): Adjust.
19502 (linux_detach_one_process): Rename to ...
19503 (linux_detach_one_lwp): ... this. Adjust.
19504 (linux_detach): Adjust.
19505 (check_removed_breakpoint): Adjust.
19506 (status_pending_p): Adjust.
19507 (linux_wait_for_process): Rename to ...
19508 (linux_wait_for_lwp): ... this. Adjust.
19509 (linux_wait_for_event): Adjust.
19510 (send_sigstop): Adjust.
19511 (wait_for_sigstop): Adjust.
19512 (stop_all_processes): Rename to ...
19513 (stop_all_lwps): ... this.
19514 (linux_resume_one_process): Rename to ...
19515 (linux_resume_one_lwp): ... this. Adjust.
19516 (linux_set_resume_request, linux_continue_one_thread)
19517 (linux_queue_one_thread, resume_status_pending_p)
19518 (usr_store_inferior_registers, regsets_store_inferior_registers)
19519 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
19520 Adjust.
19521 * linux-low.h (get_process): Rename to ...
19522 (get_lwp): ... this. Adjust.
19523 (get_thread_process): Rename to ...
19524 (get_thread_lwp): ... this. Adjust.
19525 (get_process_thread): Rename to ...
19526 (get_lwp_thread): ... this. Adjust.
19527 (struct process_info): Rename to ...
19528 (struct lwp_info): ... this.
19529 (all_processes): Rename to ...
19530 (all_lwps): ... this.
19531 * proc-service.c (ps_lgetregs): Adjust.
19532 * thread-db.c (thread_db_create_event, find_one_thread)
19533 (maybe_attach_thread, thread_db_get_tls_address): Adjust.
19534
0b16c5cf
PA
195352009-03-14 Pedro Alves <pedro@codesourcery.com>
19536
19537 * server.c (handle_query): Handle "qAttached".
19538
32de4b9d
NS
195392009-03-13 Nathan Sidwell <nathan@codesourcery.com>
19540
19541 * Makefile.in, hostio-errno.c, errno.c, xtensa-xtregs.c: Change to
19542 GPLv3, update license URL.
19543
2aecd87f
DE
195442009-03-01 Doug Evans <dje@google.com>
19545
93efd302 19546 * Makefile.in (INCLUDE_CFLAGS): Add -I$(srcdir)/../common.
2aecd87f
DE
19547 (server_h): Add gdb_signals.h.
19548 (signals.o): Update.
19549 * server.h (target_signal_from_host,target_signal_to_host_p)
19550 (target_signal_to_host,target_signal_to_name): Moved to gdb_signals.h.
19551
86b1f9c5
PM
195522009-02-14 Pierre Muller <muller@ics.u-strasbg.fr>
19553
19554 * remote-utils.c (getpkt): Also generate remote-debug
19555 information if noack_mode is set.
19556
4aa995e1
PA
195572009-02-06 Pedro Alves <pedro@codesourcery.com>
19558
19559 * server.c (handle_query): Report qXfer:siginfo:read and
19560 qXfer:siginfo:write as supported and handle them.
19561 * target.h (struct target_ops) <qxfer_siginfo>: New field.
19562 * linux-low.c (linux_xfer_siginfo): New.
19563 (linux_target_ops): Set it.
19564
62709adf
PA
195652009-01-26 Pedro Alves <pedro@codesourcery.com>
19566
19567 * server.c (gdbserver_usage): Mention --remote-debug.
19568 (main): Accept '--remote-debug' switch.
19569
aef93bd7
DE
195702009-01-18 Doug Evans <dje@google.com>
19571
19572 * regcache.c (new_register_cache): No need to check result of xcalloc.
19573 * server.c (handle_search_memory): Back out calls to xmalloc,
19574 result is checked and error is returned to user upon failure.
19575 (handle_query): Ditto. Add more checks for result of malloc.
19576 (handle_v_cont): Check result of malloc, report error back to
19577 user upon failure.
19578 (handle_v_run): Ditto. Call freeargv.
19579 * server.h (freeargv): Declare.
19580 * utils.c (freeargv): New fn.
19581
54363045
DE
195822009-01-15 Doug Evans <dje@google.com>
19583
f626972c
DE
19584 * gdbreplay.c (perror_with_name): Make arg const char *.
19585 * server.h (target_signal_to_name): Make return type const char *.
0842e787 19586 * thread-db.c (thread_db_err_str): Make return type const char *.
f626972c 19587 * utils.c (perror_with_name): Make arg const char *.
54363045 19588
18aae699
PA
195892009-01-14 Pedro Alves <pedro@codesourcery.com>
19590
19591 * win32-low.c (get_child_debug_event): Issue a final DBG_CONTINUE
19592 when handling a EXIT_PROCESS_DEBUG_EVENT.
19593
ff703abe
JB
195942009-01-06 Joel Brobecker <brobecker@adacore.com>
19595
19596 * gdbreplay.c (gdbreplay_version): Update copyright year.
19597 * server.c (gdbserver_version): Likewise.
19598
f21cc1a2 195992009-01-05 Doug Evans <dje@google.com>
0e21c1ec
DE
19600
19601 * linux-low.c (linux_attach_lwp): Add some comments/fixmes.
f21cc1a2 19602 (handle_extended_wait): Improve comment.
0e21c1ec 19603
bca929d3
DE
196042008-12-13 Doug Evans <dje@google.com>
19605
19606 * utils.c (xmalloc,xcalloc,xstrdup): New fns.
19607 * server.h (ATTR_MALLOC): New macro.
19608 (xmalloc,xcalloc,xstrdup): Declare.
19609 * hostio.c: Replace malloc,calloc,strdup with xmalloc,xcalloc,xstrdup.
19610 * inferiors.c: Ditto.
19611 * linux-low.c: Ditto.
19612 * mem-break.c: Ditto.
19613 * regcache.c: Ditto.
19614 * remote-utils.c: Ditto.
19615 * server.c: Ditto.
19616 * target.c: Ditto.
19617 * win32-low.c: Ditto.
19618
97438e3f
DE
196192008-12-12 Doug Evans <dje@google.com>
19620
896c7fbb
DE
19621 * linux-low.c (linux_wait_for_process): Don't clobber current_inferior
19622 in debugging printf.
19623
97438e3f
DE
19624 * linux-low.c (handle_extended_wait): Simplify, use my_waitpid.
19625
e3b886f8
DE
196262008-12-09 Doug Evans <dje@google.com>
19627
19628 * linux-low.h (struct process_info): Delete member tid, unused.
19629 * thread-db.c (find_one_thread): Update.
19630 (maybe_attach_thread): Update.
19631
07e059b5
VP
196322008-12-02 Pedro Alves <pedro@codesourcery.com>
19633
889bf7c5
PA
19634 * target.h (struct target_ops): Add qxfer_osdata member.
19635 * linux-low.c: Include ctype.h and pwd.h and sys/types.h
19636 and dirent.h.
19637 (linux_qxfer_osdata): New functions.
19638 (linux_target_ops): Register linux_qxfer_osdata as qxfer_osdata
19639 callback.
19640 * server.c (handle_query): Handle "qXfer:osdata:read:".
19641 * remote-utils.c (buffer_grow, buffer_free, buffer_init, buffer_finish)
19642 (buffer_xml_printf): New functions.
19643 * server.h (struct buffer): New.
19644 (buffer_grow_str, buffer_grow_str0): New macros.
19645 (buffer_grow, buffer_free, buffer_init, buffer_finish)
19646 (buffer_xml_printf): Declare.
07e059b5 19647
4cab47ab
DE
196482008-11-24 Doug Evans <dje@google.com>
19649
19650 * Makefile.in (VERSION,DIST,LINT,LINTFLAGS): Delete, unused.
19651
f142445f
DJ
196522008-11-24 Daniel Jacobowitz <dan@codesourcery.com>
19653
19654 * server.c (handle_v_run): Always use the supplied argument list.
19655
d0107bb6 196562008-11-19 Bob Wilson <bob.wilson@acm.org>
889bf7c5 19657
d0107bb6
BW
19658 * xtensa-xtregs.c (XTENSA_ELF_XTREG_SIZE): Change to 4.
19659 (xtensa_regmap_table): Add entry for scompare1.
889bf7c5 19660
2c4ad781
TJB
196612008-11-18 Thiago Jung Bauermann <bauerman@br.ibm.com>
19662
19663 * Makefile.in (powerpc-isa205-32l.o, powerpc-isa205-32l.c,
19664 powerpc-isa205-altivec32l.o, powerpc-isa205-altivec32l.c,
19665 powerpc-isa205-vsx32l.o, powerpc-isa205-vsx32l.c,
19666 powerpc-isa205-64l.o, powerpc-isa205-64l.c,
19667 powerpc-isa205-altivec64l.o, powerpc-isa205-altivec64l.c,
19668 powerpc-isa205-vsx64l.o, powerpc-isa205-vsx64l.c): New targets.
19669 * configure.srv (powerpc*-*-linux*): Add ISA 2.05 object files and
19670 XML target descriptions.
19671 * linux-ppc-low.c (ppc_arch_setup): Init registers with 64-bit FPSCR
19672 when inferior is running on an ISA 2.05 or later processor. Add
19673 special case to return offset for full 64-bit slot of FPSCR when
19674 in 32-bits.
19675
dfb64f85
DJ
196762008-11-14 Daniel Gutson <dgutson@codesourcery.com>
19677
19678 * Makefile.in (SFILES, clean): Added sparc64 files.
19679 (reg-sparc64.o, reg-sparc64.c): New.
19680 * configure.srv (sparc*-*-linux*): New configuration.
19681 * linux-low.c (regsets_fetch_inferior_registers): Swap ptrace
19682 syscall arguments for SPARC.
19683 (regsets_store_inferior_registers): Likewise.
19684 * linux-sparc-low.c: New file.
19685
66b6e1dd
DE
196862008-10-21 Doug Evans <dje@google.com>
19687
19688 * Makefile.in (BFD_DIR,BFD,BFD_SRC,BFD_CFLAGS): Delete.
19689 (READLINE_DIR,READLINE_DEP): Delete.
19690 (INTERNAL_CFLAGS): Update.
19691 (LINTFLAGS): Update.
19692
9b710a42
PA
196932008-10-10 Pedro Alves <pedro@codesourcery.com>
19694
19695 * server.c (handle_v_run): If GDB didn't specify an argv, use the
19696 whole argv from the last run, not just argv[0].
19697
5822d809
PA
196982008-09-08 Pedro Alves <pedro@codesourcery.com>
19699
19700 * regcache.c (new_register_cache): Return NULL if the register
19701 cache size isn't known yet.
19702 (free_register_cache): Avoid dereferencing a NULL regcache.
19703
74aac56f
DJ
197042008-09-04 Daniel Jacobowitz <dan@codesourcery.com>
19705
19706 * configure.srv: Merge MIPS and MIPS64.
19707
400b20f5
MR
197082008-08-24 Maciej W. Rozycki <macro@linux-mips.org>
19709
19710 * Makefile.in (uninstall): Apply $(EXEEXT) too.
19711
677c5bb1
LM
197122008-08-18 Luis Machado <luisgpm@br.ibm.com>
19713
19714 * Makefile.in: Add required vsx dependencies.
19715
19716 * linux-ppc-low: Define PPC_FEATURE_HAS_VSX.
19717 Declare init_registers_powerpc_vsx32l.
19718 Declare init_registers_powerpc_vsx64l.
19719 Define PTRACE_GETVSXREGS and PTRACE_SETVSXREGS.
19720 (ppc_arch_setup): Check for VSX in hwcap.
19721 (ppc_fill_vsxregset): New function.
19722 (ppc_store_vsxregset): New function.
19723 Add new VSX entry in regset_info target_regsets.
19724
19725 * configure.srv: Add new VSX dependencies.
19726
a6f3e723
SL
197272008-08-12 Pedro Alves <pedro@codesourcery.com>
19728
19729 * remote-utils.c (noack_mode, transport_is_reliable): New globals.
19730 (remote_open): Set or clear transport_is_reliable.
19731 (putpkt_binary): Don't expect acks in noack mode.
19732 (getpkt): Don't send ack/nac in noack mode.
19733 * server.c (handle_general_set): Handle QStartNoAckMode.
19734 (handle_query): If connected by tcp pass QStartNoAckMode+ in
19735 qSupported.
19736 (main): Reset noack_mode on every connection.
19737 * server.h (noack_mode): Declare.
19738
a417dc56
RW
197392008-08-07 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
19740
19741 * Makefile.in (GDBREPLAY_OBS): New variable.
19742 (gdbreplay$(EXEEXT)): Use it to avoid unportable $^.
19743
3221518c
UW
197442008-08-05 Ulrich Weigand <uweigand@de.ibm.com>
19745 Daniel Jacobowitz <dan@codesourcery.com>
19746
19747 * linux-low.c (linux_resume_one_process): Ignore ESRCH.
19748 (usr_store_inferior_registers): Likewise.
19749 (regsets_store_inferior_registers): Likewise.
19750
ec56be1b
PA
197512008-07-31 Rolf Jansen <rj@surtec.com>
19752 Pedro Alves <pedro@codesourcery.com>
19753
19754 * configure.ac: Check for memmem declaration.
19755 * server.c [HAVE_MALLOC_H]: Include malloc.h.
19756 (disable_packet_vCont, disable_packet_Tthread, disable_packet_qC)
19757 (disable_packet_qfThreadInfo): Unconditionally compile.
19758 * server.h [!HAVE_DECL_MEMMEM]: Declare memmem.
19759 * configure, config.in: Regenerate.
19760
2fe5e3ff
DE
197612008-07-28 Doug Kwan <dougkwan@google.com>
19762
19763 * linux-low.c (sys/dir.h, sys/user.h): Remove includes.
19764 (linux_write_memory): Remove declaration of errno.
19765
836acd6d
UW
197662008-07-12 Ulrich Weigand <uweigand@de.ibm.com>
19767
19768 * linux-low.c (handle_extended_wait): Do not use "status"
19769 variable uninitialized.
19770
aeba519e
PA
197712008-07-07 Pedro Alves <pedro@codesourcery.com>
19772
19773 * server.c (handle_v_attach): Inhibit reporting dll changes.
19774
db42f210
PA
197752008-06-27 Pedro Alves <pedro@codesourcery.com>
19776
19777 * remote-utils.c (prepare_resume_reply): If requested, don't
19778 output "thread:TID" in the T stop reply.
19779
19780 * server.c (disable_packet_vCont, disable_packet_Tthread)
19781 (disable_packet_qC, disable_packet_qfThreadInfo): New globals.
19782 (handle_query): If requested, disable support for qC, qfThreadInfo
19783 and qsThreadInfo.
19784 (handle_v_requests): If requested, disable support for vCont.
19785 (gdbserver_show_disableable): New.
19786 (main): Handle --disable-packet and --disable-packet=LIST.
19787
19788 * server.h (disable_packet_vCont, disable_packet_Tthread)
19789 (disable_packet_qC, disable_packet_qfThreadInfo): Declare.
19790
8e4c5421
CD
197912008-06-20 Carlos O'Donell <carlos@codesourcery.com>
19792
19793 * server.c (gdbserver_usage): Mention --version.
19794
6e23a804
DJ
197952008-06-06 Daniel Jacobowitz <dan@codesourcery.com>
19796
19797 * Makefile.in (gdbreplay.o): New rule.
19798
90aa6a40
JM
197992008-06-06 Joseph Myers <joseph@codesourcery.com>
19800
19801 * gdbreplay.c (gdbreplay_version): Say gdbreplay in version
19802 message, not gdbserver.
19803
c16158bc 198042008-06-05 Vladimir Prus <vladimir@codesourcery.com>
889bf7c5
PA
19805 Nathan Sidwell <nathan@codesourcery.com>
19806 Joseph Myers <joseph@codesourcery.com>
c16158bc
JM
19807
19808 * acinclude.m4: Include ../../config/acx.m4.
19809 * configure.ac: Use ACX_PKGVERSION and ACX_BUGURL.
19810 * configure, config.in: Regenerate.
19811 * Makefile.in (gdbreplay$(EXEEXT)): Add version.o.
19812 * server.c (gdbserver_version): Print PKGVERSION.
19813 (gdbsrever_usage): Add stream parameter. Print REPORT_BUGS_TO.
19814 (main): Adjust gdbserver_usage calls.
19815 * gdbreplay.c (version, host_name): Add declarations.
19816 (gdbreplay_version, gdbreplay_usage): New.
19817 (main): Accept --version and --help options.
19818
aeb75bf5
DJ
198192008-06-04 Daniel Jacobowitz <dan@codesourcery.com>
19820
19821 * linux-arm-low.c (thumb_breakpoint, thumb_breakpoint_len): New.
19822 (arm_breakpoint_at): Handle Thumb.
19823 (the_low_target): Add comment.
19824
76b233dd
UW
198252008-05-29 Ulrich Weigand <uweigand@de.ibm.com>
19826
19827 * linux-ppc-low.c (ppc_collect_ptrace_register): Clear buffer.
19828
08388c79
DE
198292008-05-09 Doug Evans <dje@google.com>
19830
a3c83fae
DE
19831 * server.h (decode_search_memory_packet): Declare.
19832 * remote-utils.c (decode_search_memory_packet): New fn.
19833 * server.c (handle_search_memory_1): New fn.
08388c79
DE
19834 (handle_search_memory): New fn.
19835 (handle_query): Process qSearch:memory packets.
19836
bb9c3d36
UW
198372008-05-08 Ulrich Weigand <uweigand@de.ibm.com>
19838
19839 * regcache.c (registers_length): Remove.
19840 (set_register_cache): Verify that PBUFSIZ is large enough to hold a
19841 full register packet.
19842 * regcache.h (registers_length): Remove prototype.
19843 * server.h (PBUFSIZ): Define to 16384.
19844
7284e1be
UW
198452008-05-03 Ulrich Weigand <uweigand@de.ibm.com>
19846
19847 * configure.srv (powerpc*-*-linux*): Set srv_regobj to
19848 powerpc-32l.o, powerpc-altivec32l.o, powerpc-e500l.o,
19849 powerpc-64l.o, and powerpc-altivec64l.o.
19850 Remove rs6000/powerpc-32.xml, rs6000/powerpc-64.xml, and
19851 rs6000/powerpc-e500.xml; add rs6000/powerpc-32l.xml,
19852 rs6000/powerpc-altivec32l.xml, rs6000/powerpc-e500l.xml,
19853 rs6000/powerpc-64l.xml, rs6000/powerpc-altivec64l.xml,
19854 rs6000/power-linux.xml, and rs6000/power64-linux.xml
19855 to srv_xmlfiles.
19856
19857 * Makefile.in (reg-ppc.o, reg-ppc.c): Remove, replace by ...
19858 (powerpc-32l.o, powerpc-32l.c): ... these new rules.
19859 (powerpc-32.o, powerpc-32.c): Remove, replace by ...
19860 (powerpc-altivec32l.o, powerpc-altivec32l.c): ... these new rules.
19861 (powerpc-e500.o, powerpc-e500.c): Remove, replace by ...
19862 (powerpc-e500l.o, powerpc-e500l.c): ... these new rules.
19863 (reg-ppc64.o, reg-ppc64.c): Remove, replace by ...
19864 (powerpc-64l.o, powerpc-64l.c): ... these new rules.
19865 (powerpc-64.o, powerpc-64.c): Remove, replace by ...
19866 (powerpc-altivec64l.o, powerpc-altivec64l.c): ... these new rules.
19867 (clean): Update.
19868
19869 * linux-ppc-low.c (init_registers_ppc): Remove, replace by ...
19870 (init_registers_powerpc_32l): ... this new prototype.
19871 (init_registers_powerpc_32): Remove, replace by ...
19872 (init_registers_powerpc_altivec32l): ... this new prototype.
19873 (init_registers_powerpc_e500): Remove, replace by ...
19874 (init_registers_powerpc_e500l): ... this new prototype.
19875 (init_registers_ppc64): Remove, replace by ...
19876 (init_registers_powerpc_64l): ... this new prototype.
19877 (init_registers_powerpc_64): Remove, replace by ...
19878 (init_registers_powerpc_altivec64l): ... this new prototype.
19879 (ppc_num_regs): Set to 73.
19880 (PT_ORIG_R3, PT_TRAP): Define if necessary.
19881 (ppc_regmap, ppc_regmap_e500): Add values for orig_r3 and trap.
19882 (ppc_cannot_store_register): Handle orig_r3 and trap.
19883 (ppc_arch_setup): Update init_registers_... calls.
19884 (ppc_fill_gregset): Handle orig_r3 and trap.
19885
19886 * inferiors.c (clear_inferiors): Reset current_inferior.
19887
fdc59709
PB
198882008-04-23 Paolo Bonzini <bonzini@gnu.org>
19889
889bf7c5
PA
19890 * acinclude.m4: Add override.m4.
19891 * configure: Regenerate.
fdc59709 19892
c9b2f845
UW
198932008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
19894
19895 * linux-ppc-low.c (ppc_arch_setup): Reset ppc_hwcap after the
19896 initial call to init_register_ppc64.
19897
550512b8
UW
198982008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
19899
43aaf8b6
PA
19900 * configure.srv (powerpc64-*-linux*, powerpc-*-linux*): Merge into
19901 single powerpc*-*-linux* case.
550512b8
UW
19902 (s390-*-linux*, s390x-*-linux*): Merge into single s390*-*-linux* case.
19903
b6430ec3
UW
199042008-04-17 Ulrich Weigand <uweigand@de.ibm.com>
19905
19906 * configure.srv [powerpc64-*-linux*]: Remove powerpc-e500.o from
889bf7c5 19907 srv_regobj. Remove rs6000/powerpc-e500.xml and rs6000/power-spe.xml
b6430ec3
UW
19908 from reg_xmlfiles.
19909 * linux-ppc-low.c: Include <elf.h>.
19910 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Define.
19911 (ppc_hwcap): New global variable.
19912 (ppc_regmap): Remove __SPE__ #ifdef sections.
19913 (ppc_regmap_e500): New global variable.
19914 (ppc_cannot_store_register): Update __SPE__ special case.
19915 (ppc_get_hwcap): New function.
19916 (ppc_arch_setup): Use it to determine whether inferior supports
19917 AltiVec or SPE registers. Set the_low_target.regmap if appropriate.
19918 (ppc_fill_vrregset, ppc_store_vrregset): Define unconditionally.
19919 Do not access registers if target does not support AltiVec.
19920 (ppc_fill_evrregset, ppc_store_evrregset): Define unconditionally.
19921 Do not access registers if target does not support SPE.
19922 (target_regsets): Unconditionally include AltiVec and SPE regsets.
19923
52fa2412
UW
199242008-04-17 Daniel Jacobowitz <dan@codesourcery.com>
19925
19926 * linux-low.c (disabled_regsets, num_regsets): New.
19927 (use_regsets_p): Delete.
19928 (linux_wait_for_process): Clear disabled_regsets.
19929 (regsets_fetch_inferior_registers): Check and set it.
19930 (regsets_store_inferior_registers): Likewise.
19931 (linux_fetch_registers, linux_store_registers): Do not use
19932 use_regsets_p.
19933 (initialize_low): Allocate disabled_regsets.
19934
e28b3332
DJ
199352008-04-14 Daniel Jacobowitz <dan@codesourcery.com>
19936
19937 * Makefile.in (LIBOBJS): New.
19938 (OBS): Use LIBOBJS.
19939 (memmem.o): New rule.
19940 * configure.ac: Use AC_CONFIG_LIBOBJ_DIR and check for memmem.
19941 * configure: Regenerated.
19942
4536995d
UW
199432008-04-04 Ulrich Weigand <uweigand@de.ibm.com>
19944
19945 * server.c (handle_query): Never return "unsupported" for
19946 qXfer:features:read queries.
19947
221c031f
UW
199482008-03-27 Ulrich Weigand <uweigand@de.ibm.com>
19949
19950 * server.c (get_features_xml): Fix inverted condition.
19951 (handle_query): Always support qXfer:feature:read.
19952
ccd213ac
DJ
199532008-03-10 Daniel Jacobowitz <dan@codesourcery.com>
19954
19955 * server.c (wrapper_argv): New.
19956 (start_inferior): Handle wrapper_argv. If set, expect an extra
19957 trap.
19958 (gdbserver_usage): Document --wrapper.
19959 (main): Parse --wrapper.
19960
6fe305f7
UW
199612008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
19962
19963 * configure.srv [powerpc64-*-linux*]: Add all files mentioned for
19964 powerpc-*-linux* to srv_regobj and reg_xmlfiles.
19965 * linux-ppc-low.c (ppc_get_pc): Support bi-arch operation.
19966 (ppc_set_pc): Likewise.
19967 (ppc_arch_setup): New function.
19968 (ppc_fill_gregset): Call ppc_collect_ptrace_register instead
19969 of collect_register.
889bf7c5 19970 (the_low_target): Use ppc_arch_setup as arch_setup initializer.
6fe305f7 19971
5b0a002e
UW
199722008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
19973
19974 * configure.srv [powerpc64-*-linux*]: Use linux-ppc-low.o
19975 instead of linux-ppc64-low.o.
19976 * linux-ppc64-low.c: Remove file.
19977 * Makefile.in (SFILES): Remove linux-ppc64-low.c.
19978 (linux-ppc64-low.o): Remove rule.
19979
19980 * linux-ppc-low.c (init_registers_ppc64): Add prototype.
19981 (init_registers_powerpc_64): Likewise.
19982 (ppc_regmap): Conditionally define depending on __powerpc64__.
19983 (ppc_cannot_store_register): Do not special-case "fpscr" when
19984 compiled on __powerpc64__.
19985 (ppc_collect_ptrace_register): New function.
19986 (ppc_supply_ptrace_register): New function.
19987 (ppc_breakpoint): Change type to "unsigned int".
19988 (ppc_breakpoint_at): Change type of "insn" to "unsigned int".
19989 (the_low_target): Conditionally provide initializers for the
889bf7c5 19990 arch_setup member depending on __powerpc64__. Install
5b0a002e
UW
19991 collect_ptrace_register and supply_ptrace_register members.
19992
9b4b61c8
UW
199932008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
19994
19995 * regcache.h (gdbserver_xmltarget): Add extern declaration.
19996 * server.c (gdbserver_xmltarget): Define.
19997 (get_features_xml): Use it to replace "target.xml" and arch_string.
19998
19999 * configure.srv: Remove srv_xmltarget. Add XML files that were
20000 mentioned there to srv_xmlfiles instead. Remove conditional tests
20001 on gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe; set
20002 srv_xmlfiles and srv_regobj to include all possible choices.
20003 * configure.ac (srv_xmltarget): Remove.
20004 (srv_xmlfiles): Do not add "target.xml".
20005 (gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe): Remove
20006 checks for supplementary target information.
20007 * configure: Regenerate.
20008 * Makefile.in (XML_TARGET): Remove.
20009 (target.xml): Remove rule.
20010 (clean): Do not clean up target.xml.
20011 (.PRECIOUS): Do not mention target.xml.
20012
20013 * target.h (struct target_ops): Remove arch_string member.
20014 * linux-low.c (linux_arch_string): Remove.
20015 (linux_target_ops): Remove arch_string initializer.
20016 * linux-low.h (struct linux_target_ops): Remove arch_string member.
20017 * linux-i386-low.c (the_low_target): Remove arch_string initializer.
20018 * linux-x86-64-low.c (the_low_target): Remove arch_string initializer.
20019 * spu-low.c (spu_arch_string): Remove.
20020 (spu_target_ops): Remove arch_string initializer.
20021 * win32-low.c (win32_arch_string): Remove.
20022 (win32_target_ops): Remove arch_string initializer.
20023 * win32-low.h (struct win32_target_ops): Remove arch_string member.
20024 * win32-arm-low.c (the_low_target): Remove arch_string initializer.
20025 * win32-i368-low.c (the_low_target): Remove arch_string initializer.
20026
ee1a7ae4
UW
200272008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
20028
20029 * linux-low.h (struct linux_target_ops): Replace left_pad_xfer field
20030 by collect_ptrace_register and supply_ptrace_register hooks.
20031 * linux-low.c (fetch_register): Use supply_ptrace_register callback
20032 instead of checking for the_low_target.left_pad_xfer.
20033 (usr_store_inferior_registers): Use collect_ptrace_register callback
20034 instead of checking for the_low_target.left_pad_xfer.
20035
20036 * linux-s390-low.c (s390_collect_ptrace_register): New function.
20037 (s390_supply_ptrace_register): Likewise.
20038 (s390_fill_gregset): Call s390_collect_ptrace_register.
20039 (the_low_target): Update.
20040
20041 * linux-ppc64-low.c (ppc_collect_ptrace_register): New function.
20042 (ppc_supply_ptrace_register): Likewise.
20043 (the_low_target): Update.
20044
20045 * linux-i386-low.c (the_low_target): Update.
20046 * linux-x86-64-low.c (the_low_target): Update.
20047
d61ddec4
UW
200482008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
20049
20050 * configure.srv [s390x-*-linux*]: Set srv_regobj to include both
20051 reg-s390.o and reg-s390x.o.
20052
20053 * linux-low.c (new_inferior): New global variable.
20054 (linux_create_inferior, linux_attach): Set it.
20055 (linux_wait_for_process): Call the_low_target.arch_setup after the
20056 target has stopped for the first time.
20057 (initialize_low): Do not call the_low_target.arch_setup.
20058
20059 * linux-s390-low.c (s390_get_pc): Support bi-arch operation.
20060 (s390_set_pc): Likewise.
20061 (s390_arch_setup): New function.
20062 (the_low_target): Use s390_arch_setup as arch_setup routine.
20063
20064 * regcache.c (realloc_register_cache): New function.
20065 (set_register_cache): Call it for each existing regcache.
20066
d05b4ac3
UW
200672008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
20068
20069 * server.h (init_registers): Remove prototype.
20070
20071 * linux-low.h (struct linux_target_ops): Add arch_setup field.
20072 * linux-low.c (initialize_low): Call the_low_target.arch_setup ()
20073 instead of init_registers ().
20074 * linux-arm-low.c (init_registers_arm): Add prototype.
20075 (init_registers_arm_with_iwmmxt): Likewise.
20076 (the_low_target): Add initializer for arch_setup field.
20077 * linux-cris-low.c (init_registers_cris): Add prototype.
20078 (the_low_target): Add initializer for arch_setup field.
20079 * linux-crisv32-low.c (init_registers_crisv32): Add prototype.
20080 (the_low_target): Add initializer for arch_setup field.
20081 * linux-i386-low.c (init_registers_i386_linux): Add prototype.
20082 (the_low_target): Add initializer for arch_setup field.
20083 * linux-ia64-low.c (init_registers_ia64): Add prototype.
20084 (the_low_target): Add initializer for arch_setup field.
20085 * linux-m32r-low.c (init_registers_m32r): Add prototype.
20086 (the_low_target): Add initializer for arch_setup field.
20087 * linux-m68k-low.c (init_registers_m68k): Add prototype.
20088 (the_low_target): Add initializer for arch_setup field.
20089 * linux-mips-low.c (init_registers_mips_linux): Add prototype.
20090 (init_registers_mips64_linux): Likewise.
20091 (the_low_target): Add initializer for arch_setup field.
20092 * linux-ppc-low.c (init_registers_ppc): Add prototype.
20093 (init_registers_powerpc_32, init_registers_powerpc_e500): Likewise.
20094 (the_low_target): Add initializer for arch_setup field.
20095 * linux-ppc64-low.c (init_registers_ppc64): Add prototype.
20096 (init_registers_powerpc_64): Likewise.
20097 (the_low_target): Add initializer for arch_setup field.
20098 * linux-s390-low.c (init_registers_s390): Add prototype.
20099 (init_registers_s390x): Likewise.
20100 (the_low_target): Add initializer for arch_setup field.
20101 * linux-sh-low.c (init_registers_sh): Add prototype.
20102 (the_low_target): Add initializer for arch_setup field.
20103 * linux-x86-64-low.c (init_registers_x86_64_linux): Add prototype.
20104 (the_low_target): Add initializer for arch_setup field.
20105 * linux-xtensa-low.c (init_registers_xtensa): Add prototype.
20106 (the_low_target): Add initializer for arch_setup field.
20107
20108 * win32-low.h (struct win32_target_ops): Add arch_setup field.
20109 * win32-low.c (initialize_low): Call the_low_target.arch_setup ()
20110 instead of init_registers ().
20111 * win32-arm-low.c (init_registers_arm): Add prototype.
20112 (the_low_target): Add initializer for arch_setup field.
20113 * win32-i386-low.c (init_registers_i386): Add prototype.
20114 (the_low_target): Add initializer for arch_setup field.
20115
20116 * spu-low.c (init_registers_spu): Add prototype.
20117 (initialize_low): Call initialie_registers_spu () instead of
20118 initialize_registers ().
20119
fd96d250
PA
201202008-02-19 Pedro Alves <pedro@codesourcery.com>
20121
20122 * server.c (handle_v_requests): When handling the vRun and vAttach
20123 packets, if already debugging a process, don't kill it. Return an
20124 error instead.
20125
d41b6bb4
DJ
201262008-02-17 Daniel Jacobowitz <dan@codesourcery.com>
20127
20128 * server.c (handle_query): Correct length check.
20129
5ac588cf
PA
201302008-02-14 Pedro Alves <pedro_alves@portugalmail.pt>
20131
20132 * win32-low.c (do_initial_child_stuff): Add process handle
20133 parameter. Set current_process_handle and current_process_id from the
20134 parameters. Clear globals.
20135 (win32_create_inferior): Don't set current_process_handle and
20136 current_process_id here. Instead pass them on the call to
20137 do_initial_child_stuff.
20138 (win32_attach): Likewise.
20139 (win32_clear_inferiors): New.
20140 (win32_kill): Don't close the current process handle or the
20141 current thread handle here. Instead call win32_clear_inferiors.
20142 (win32_detach): Don't open a new handle to the process. Call
20143 win32_clear_inferiors.
20144 (win32_join): Don't rely on current_process_handle; open a new
20145 handle using the process id.
20146 (win32_wait): Call win32_clear_inferiors when the inferior process
20147 has exited.
20148
ecd7ecbc
DJ
201492008-02-14 Daniel Jacobowitz <dan@codesourcery.com>
20150
20151 * server.c (monitor_show_help): Add "exit".
20152
1525d545
MG
201532008-02-11 Maxim Grigoriev <maxim2405@gmail.com>
20154
ecd7ecbc 20155 * Makefile.in (SFILES): Add linux-xtensa-low.c.
1525d545
MG
20156 (clean): Add reg-xtensa.c.
20157 (linux-xtensa-low.o, reg-xtensa.o, reg-xtensa.c): New dependencies.
ecd7ecbc
DJ
20158 * configure.srv (xtensa*-*-linux*) New target.
20159 * linux-xtensa-low.c: New.
20160 * xtensa-xtregs.c: New.
1525d545 20161
59a016f0
PA
201622008-02-01 Pedro Alves <pedro_alves@portugalmail.pt>
20163
20164 * hostio.c: Don't include errno.h.
20165 (errno_to_fileio_errno): Move to hostio-errno.
20166 * hostio.c: (hostio_error): Remove the error parameter. Defer the
20167 error number outputting to the target->hostio_last_error callback.
20168 (hostio_packet_error): Use FILEIO_EINVAL directly.
20169 (handle_open, handle_pread, hostio_error, handle_unlink): Update
20170 calls to hostio_error.
20171 * hostio-errno.c: New.
20172 * server.h (hostio_last_error_from_errno): Declare.
20173 * target.h (target_ops): Add hostio_last_error member.
20174 * linux-low.c (linux_target_op): Register hostio_last_error_from_errno
20175 as hostio_last_error handler.
889bf7c5 20176 * spu-low.c (spu_target_ops): Likewise.
59a016f0
PA
20177 * win32-low.c [_WIN32_WCE] (win32_error_to_fileio_error)
20178 (wince_hostio_last_error): New functions.
20179 (win32_target_ops) [_WIN32_WCE]: Register wince_hostio_last_error
20180 as hostio_last_error handler.
20181 (win32_target_ops) [!_WIN32_WCE]: Register
20182 hostio_last_error_from_errno as hostio_last_error handler.
20183 * Makefile.in (SFILES): Add hostio.c and hostio-errno.c.
20184 (hostio-errno.o): New rule.
20185 * configure.ac (GDBSERVER_DEPFILES): Add $srv_hostio_err_objs.
20186 * configure.srv (srv_hostio_err_objs): New variable. Default to
20187 hostio-errno.o.
20188 (arm*-*-mingw32ce*): Set srv_hostio_err_objs to "".
20189 * configure: Regenerate.
20190
2d717e4f
DJ
201912008-01-29 Daniel Jacobowitz <dan@codesourcery.com>
20192
20193 * linux-low.c (linux_attach_lwp): Do not _exit after errors.
20194 (linux_kill, linux_detach): Clean up the process list.
20195 * remote-utils.c (remote_open): Improve port number parsing.
20196 (putpkt_binary, input_interrupt): Only send interrupts if the target
20197 is running.
20198 * server.c (extended_protocol): Make static.
20199 (attached): Define earlier.
20200 (exit_requested, response_needed, program_argv): New variables.
20201 (target_running): New.
20202 (start_inferior): Clear attached here.
20203 (attach_inferior): Set attached here.
20204 (require_running): Define.
20205 (handle_query): Use require_running and target_running. Implement
20206 "monitor exit".
20207 (handle_v_attach, handle_v_run): New.
20208 (handle_v_requests): Use require_running. Handle vAttach and vRun.
20209 (gdbserver_usage): Update.
20210 (main): Redo argument parsing. Handle --debug and --multi. Handle
20211 --attach along with other options or after the port. Save
20212 program_argv. Support no initial program. Resynchronize
20213 communication with GDB after an error. Handle "monitor exit".
20214 Use require_running and target_running. Always allow the extended
20215 protocol. Do not error out for Hc0 or Hc-1. Do not automatically
20216 restart in extended mode.
20217 * README: Refer to the GDB manual. Update --attach usage.
20218
7407e2de
AS
202192007-12-20 Andreas Schwab <schwab@suse.de>
20220
20221 * linux-low.c (STACK_SIZE): Define.
20222 (linux_tracefork_child): Use it. Use __clone2 on ia64.
20223 (linux_test_for_tracefork): Likewise.
20224
b65d95c5
DJ
202252007-12-18 Daniel Jacobowitz <dan@codesourcery.com>
20226
20227 * linux-low.c (linux_wait_for_event): Update messages. Do not
20228 reinsert auto-delete breakpoints.
20229 * mem-break.c (struct breakpoint): Change return type of handler to
20230 int.
20231 (set_breakpoint_at): Update handler type.
20232 (reinsert_breakpoint_handler): Return 1 instead of calling
20233 delete_breakpoint.
20234 (reinsert_breakpoint_by_bp): Check for the original breakpoint before
20235 setting a new one.
20236 (check_breakpoints): Delete auto-delete breakpoints and return 2.
20237 * mem-break.h (set_breakpoint_at): Update handler type.
20238 * thread-db.c (thread_db_create_event, thread_db_create_event): Update.
20239 * win32-low.c (auto_delete_breakpoint): New.
20240 (get_child_debug_event): Use it.
20241
4e799345
DJ
202422007-12-16 Daniel Jacobowitz <dan@codesourcery.com>
20243
20244 * configure.ac: Check for pread and pwrite.
20245 * hostio.c (handle_pread): Fall back to lseek and read.
20246 (handle_pwrite): Fall back to lseek and write.
20247 * config.in, configure: Regenerated.
20248
27524b67
DJ
202492007-12-07 Daniel Jacobowitz <dan@codesourcery.com>
20250
20251 * server.c (myresume): Add own_buf argument.
20252 (main): Update calls.
20253
a20d5e98
DJ
202542007-12-06 Daniel Jacobowitz <dan@codesourcery.com>
20255
20256 * linux-low.c (linux_wait, linux_resume): Do not handle async I/O.
20257 * remote-utils.c (remote_open): Do not call disable_async_io.
20258 (block_async_io): Delete.
20259 (unblock_async_io): Make static.
20260 (initialize_async_io): New.
20261 * server.c (handle_v_cont): Handle async I/O here.
20262 (myresume): Likewise. Move other common resume tasks here...
20263 (main): ... from here. Call initialize_async_io. Disable async
20264 I/O before the main loop.
20265 * server.h (initialize_async_io): Declare.
20266 (block_async_io, unblock_async_io): Delete prototypes.
20267 * spu-low.c (spu_resume, spu_wait): Do not handle async I/O here.
20268
b79d787e
DJ
202692007-12-06 Mick Davis <mickd@goanna.iinet.net.au>
20270
20271 * remote-utils.c (readchar): Allow binary data in received messages.
20272
d97903b2
PA
202732007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
20274
20275 * win32-low.c (attaching): New global.
20276 (win32_create_inferior): Clear the `attaching' global.
20277 (win32_attach): Set the `attaching' global.
20278 (get_child_debug_event) [_WIN32_WCE]: Stop the inferior when
20279 attaching. Only set a breakpoint at the entry point if not
20280 attaching.
20281
311de423
PA
202822007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
20283
20284 * server.c (main): Don't report dll events on the initial
20285 connection on attaches.
20286
6c2d16d2
PA
202872007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
20288
20289 * server.c (main): Relax numerical bases supported for the pid of
20290 the --attach command line argument.
20291
5ca906e6
PA
202922007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
20293
20294 * win32-low.c (win32_attach): Call OpenProcess before
20295 DebugActiveProcess, not after. Add last error output to error
20296 call.
20297
9c6c8194
PA
202982007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
20299
20300 * win32-low.c (win32_get_thread_context)
20301 (win32_set_thread_context): New functions.
20302 (thread_rec): Use win32_get_thread_context.
20303 (continue_one_thread, win32_resume): Use win32_set_thread_context.
20304 * win32-low.h (win32_thread_info) [_WIN32_WCE]: Add `base_context'
20305 field.
20306
4d5d1aaa
PA
203072007-12-03 Leo Zayas
20308 Pedro Alves <pedro_alves@portugalmail.pt>
20309
20310 * win32-low.c (soft_interrupt_requested, faked_breakpoint): New
20311 global variables.
20312 (child_add_thread): Minor cleanup.
20313 (child_continue): Resume artificially suspended threads before
20314 calling ContinueDebugEvent.
20315 (suspend_one_thread): New.
20316 (fake_breakpoint_event): New.
20317 (get_child_debug_event): Change return type to int. Check here if
20318 gdb sent an interrupt request. If a soft interrupt was requested,
20319 fake a breakpoint event. Return 0 if there is no event to handle,
20320 and 1 otherwise.
20321 (win32_wait): Don't check here if gdb sent an interrupt request.
20322 Ensure there is a valid event to handle.
20323 (win32_request_interrupt): Add soft interruption method as last
20324 resort.
20325
c436e841
PA
203262007-12-03 Leo Zayas
20327 Pedro Alves <pedro_alves@portugalmail.pt>
20328
20329 * win32-low.h (win32_thread_info): Add descriptions to the
20330 structure members. Replace `suspend_count' counter by a
20331 `suspended' flag.
20332 * win32-low.c (thread_rec): Update condition of when to get the
20333 context from the inferior. Rely on ContextFlags being set if it
20334 has already been retrieved. Only suspend the inferior thread if
20335 we haven't already. Warn if that fails.
20336 (continue_one_thread): s/suspend_count/suspended/. Only call
20337 ResumeThread once. Warn if that fails.
20338
e7b5fa67
PA
203392007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
20340
20341 * win32-low.c (win32_wait): Don't read from the inferior when it
20342 has already exited.
20343
a385171d
PA
203442007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
20345
20346 * Makefile.in (win32_low_h): New variable.
20347 (win32-low.o): Add dependency on $(win32_low_h).
20348 (win32-arm-low.o, win32-i386-low.o): New rules.
20349
f80c84b3
DJ
203502007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
20351
20352 * hostio.c: Correct copyright year.
20353
a6b151f1
DJ
203542007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
20355
20356 * Makefile.in (OBS): Add hostio.o.
20357 (hostio.o): New rule.
20358 * server.h (handle_vFile): Declare.
20359 * hostio.c: New file.
20360 * server.c (handle_v_requests): Take packet_len and new_packet_len
20361 for binary packets. Call handle_vFile.
20362 (main): Update call to handle_v_requests.
20363
f9387fc3
DJ
203642007-11-05 Daniel Jacobowitz <dan@codesourcery.com>
20365
20366 * linux-low.c: Include <sched.h>.
20367
51c2684e
DJ
203682007-11-01 Daniel Jacobowitz <dan@codesourcery.com>
20369
20370 * linux-low.c (linux_tracefork_grandchild): New.
20371 (linux_tracefork_child): Use clone.
20372 (linux_test_for_tracefork): Use clone; allocate and free a stack.
20373
75f83163
JB
203742007-10-31 Joel Brobecker <brobecker@adacore.com>
20375
20376 * Makefile.in: Use $(SHELL) instead of "sh" to call regdat.sh.
20377
da5898ce
DJ
203782007-10-24 Daniel Jacobowitz <dan@codesourcery.com>
20379
20380 * linux-low.c (handle_extended_wait): Handle unexpected signals.
20381
24a09b5f
DJ
203822007-10-23 Daniel Jacobowitz <dan@codesourcery.com>
20383
20384 * inferiors.c (change_inferior_id): Delete.
20385 (add_pid_to_list, pull_pid_from_list): New.
20386 * linux-low.c (PTRACE_SETOPTIONS, PTRACE_GETEVENTMSG)
20387 (PTRACE_O_TRACESYSGOOD, PTRACE_O_TRACEFORK, PTRACE_O_TRACEVFORK)
20388 (PTRACE_O_TRACECLONE, PTRACE_O_TRACEEXEC, PTRACE_O_TRACEVFORKDONE)
20389 (PTRACE_O_TRACEEXIT, PTRACE_EVENT_FORK, PTRACE_EVENT_VFORK)
20390 (PTRACE_EVENT_CLONE, PTRACE_EVENT_EXEC, PTRACE_EVENT_VFORK_DONE)
20391 (PTRACE_EVENT_EXIT, __WALL): Provide default definitions.
20392 (stopped_pids, thread_db_active, must_set_ptrace_flags): New variables.
20393 (using_threads): Always set to 1.
20394 (handle_extended_wait): New.
20395 (add_process): Do not set TID.
20396 (linux_create_inferior): Set must_set_ptrace_flags.
20397 (linux_attach_lwp): Remove TID argument. Do not check using_threads.
20398 Use PTRACE_SETOPTIONS. Call new_thread_notify. Update all callers.
20399 (linux_thread_alive): Rename TID argument to LWPID.
20400 (linux_wait_for_process): Handle unknown processes. Do not use TID.
20401 (linux_wait_for_event): Do not use TID or check using_threads. Update
20402 call to dead_thread_notify. Call handle_extended_wait.
20403 (linux_create_inferior): Use PTRACE_SETOPTIONS.
20404 (send_sigstop): Delete sigstop_sent.
20405 (wait_for_sigstop): Avoid TID.
20406 (linux_supports_tracefork_flag, linux_tracefork_child, my_waitpid)
20407 (linux_test_for_tracefork): New.
20408 (linux_lookup_signals): Use thread_db_active and
20409 linux_supports_tracefork_flag.
20410 (initialize_low): Use thread_db_active and linux_test_for_tracefork.
20411 * linux-low.h (get_process_thread): Avoid TID.
20412 (struct process_ifo): Move thread_known and tid to the end. Remove
20413 sigstop_sent.
20414 (linux_attach_lwp, thread_db_init): Update prototypes.
20415 * server.h (change_inferior_id): Delete prototype.
20416 (add_pid_to_list, pull_pid_from_list): New prototypes.
20417 * thread-db.c (thread_db_use_events): New.
20418 (find_first_thread): Rename to...
20419 (find_one_thread): ...this. Update callers and messages. Do not
20420 call fatal. Check thread_db_use_events. Do not call
20421 change_inferior_id or new_thread_notify.
20422 (maybe_attach_thread): Update. Do not call new_thread_notify.
20423 (thread_db_init): Set thread_db_use_events. Check use_events.
20424 * utils.c (fatal, warning): Correct message prefix.
20425
30ed0a8f
DJ
204262007-10-15 Daniel Jacobowitz <dan@codesourcery.com>
20427
20428 * Makefile.in (clean): Remove new files.
20429 (powerpc-32.o, powerpc-32.c, powerpc-e500.o, powerpc-e500.c)
20430 (powerpc-64.o, powerpc-64.c): New rules.
20431 * configure.srv: Use alternate register sets for powerpc64-*-linux*
20432 with AltiVec, powerpc-*-linux* with AltiVec, and powerpc-*-linux*
20433 with SPE.
20434 * linux-ppc-low.c (ppc_regmap): Do not fetch the FP registers for
20435 SPE targets.
20436 (ppc_cannot_store_register): Do not check for FPSCR for SPE targets.
20437 (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS, ppc_fill_vrregset)
20438 (ppc_store_vrregset, PTRACE_GETEVRREGS, PTRACE_SETEVRREGS)
20439 (struct gdb_evrregset_t, ppc_fill_evrregset, ppc_store_evrregset): New.
20440 (target_regsets): Add AltiVec and SPE register sets.
20441 * configure.ac: Check for AltiVec and SPE.
20442 * linux-ppc64-low.c (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS)
20443 (ppc_fill_vrregset, ppc_store_vrregset): New.
20444 (target_regsets): Add AltiVec register set.
20445 * configure: Regenerated.
20446
fd462a61
DJ
204472007-09-19 Daniel Jacobowitz <dan@codesourcery.com>
20448
20449 * linux-low.c (O_LARGEFILE): Define.
20450 (linux_read_memory): Use /proc/PID/mem.
20451 * configure.ac: Use AC_GNU_SOURCE. Check for pread64.
20452 * configure, config.in: Regenerated.
20453
69f223ed
DJ
204542007-09-04 Daniel Jacobowitz <dan@codesourcery.com>
20455
20456 * linux-low.c (linux_wait_for_event): Do not pass signals while
20457 single-stepping.
20458
aec18585
PA
204592007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
20460
20461 * win32-low.c (create_process): New.
20462 (win32_create_inferior): Use create_process instead of
20463 CreateProcess. If create_process failed retry appending an ".exe"
20464 suffix. Store the GetLastError result immediatelly after
20465 create_process calls and use it on the call to error.
20466
34d86ddd
PA
204672007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
20468
20469 * win32-low.c (handle_load_dll): Don't use toolhelp when waiting.
20470
5a0e3bd0
JB
204712007-08-23 Joel Brobecker <brobecker@adacore.com>
20472
20473 * configure.ac: Switch license to GPLv3.
20474
f88c79e6
MS
204752007-08-01 Michael Snyder <msnyder@access-company.com>
20476
20477 * remote-utils.c (putpkt_binary): Memory leak, free buf2.
20478
6b3d9b83
PA
204792007-07-31 Pedro Alves <pedro_alves@portugalmail.pt>
20480
20481 * win32-low.c (winapi_CloseToolhelp32Snapshot) [_WIN32_WCE]: New
20482 typedef.
20483 (win32_CloseToolhelp32Snapshot) [_WIN32_WCE]: New global var.
20484 (load_toolhelp) [_WIN32_WCE]: Load TOOLHELP.DLL. Get
20485 CloseToolhelp32Snapshot.
20486 (toolhelp_get_dll_name) [_WIN32_WCE]: Close the snapshot with
20487 CloseToolhelp32Snapshot.
20488
c588c53c
MS
204892007-07-27 Michael Snyder <michael.snyder@access-company.com>
20490
20491 * server.c (main): Check for inferior exit before main loop.
20492
aa0403d9
PA
204932007-07-18 Pedro Alves <pedro_alves@portugalmail.pt>
20494
20495 * remote-utils.c (remote_open): Set SO_KEEPALIVE on remote_desc
20496 instead of on tmp_desc.
20497
255e7678
DJ
204982007-07-17 Pedro Alves <pedro_alves@portugalmail.pt>
20499 Daniel Jacobowitz <dan@codesourcery.com>
20500
20501 * inferiors.c (all_dlls, dlls_changed, get_dll): New.
20502 (add_thread): Minor cleanups.
20503 (clear_inferiors): Move lower in the file. Clear the DLL
20504 list.
20505 (free_one_dll, match_dll, loaded_dll, unloaded_dll, clear_list): New.
20506 * remote-utils.c (prepare_resume_reply): Check dlls_changed.
20507 (xml_escape_text): New.
20508 * server.c (handle_query): Handle qXfer:libraries:read. Report it
20509 for qSupported.
20510 (handle_v_cont): Report errors.
20511 (gdbserver_version): Update.
20512 (main): Correct size of own_buf. Do not report initial DLL events.
20513 * server.h (struct dll_info, all_dlls, dlls_changed, loaded_dll)
20514 (unloaded_dll, xml_escape_text): New.
20515 * win32-low.c (enum target_waitkind): Update comments.
20516 (win32_add_one_solib, get_image_name, winapi_EnumProcessModules)
20517 (winapi_GetModuleInformation, winapi_GetModuleFileNameExA)
20518 (win32_EnumProcessModules, win32_GetModuleInformation)
20519 (win32_GetModuleFileNameExA, load_psapi, psapi_get_dll_name)
20520 (winapi_CreateToolhelp32Snapshot, winapi_Module32First)
20521 (winapi_Module32Next, win32_CreateToolhelp32Snapshot)
20522 (win32_Module32First, win32_Module32Next, load_toolhelp)
20523 (toolhelp_get_dll_name, handle_load_dll, handle_unload_dll): New.
20524 (get_child_debug_event): Handle DLL events.
20525 (win32_wait): Likewise.
20526
0d37add9
DJ
205272007-07-12 Daniel Jacobowitz <dan@codesourcery.com>
20528
20529 * configure.srv: Set srv_linux_regsets for sh*-*-linux*.
20530 * linux-sh-low.c (sh_fill_gregset, target_regsets): New.
20531
45e2715e
PA
205322007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
20533
20534 * win32-low.c (handle_output_debug_string): Ignore event if not
20535 waiting.
20536
c5674cf1
PA
205372007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
20538
20539 * win32-arm-low.c (arm_wince_breakpoint): Fix typo.
20540
2bbe3cc1
DJ
205412007-07-03 Daniel Jacobowitz <dan@codesourcery.com>
20542
20543 * remote-utils.c (look_up_one_symbol): Handle 'm' packets.
20544
ae13219e
DJ
205452007-07-02 Daniel Jacobowitz <dan@codesourcery.com>
20546
20547 * inferiors.c (change_inferior_id): Add comment.
20548 * linux-low.c (check_removed_breakpoint): Add an early
20549 prototype. Improve debug output.
20550 (linux_attach): Doc update.
20551 (linux_detach_one_process, linux_detach): Clean up before releasing
20552 each process.
20553 (send_sigstop, wait_for_sigstop): Improve comments and debug output.
20554 * linux-low.h (struct process_info): Doc improvement.
20555 * mem-break.c (delete_all_breakpoints): New.
20556 * mem-break.h (delete_all_breakpoints): New prototype.
20557 * thread-db.c (find_first_thread): New.
20558 (thread_db_create_event): Call it instead of
20559 thread_db_find_new_threads. Clean up unused variables.
20560 (maybe_attach_thread): Remove first thread handling.
20561 (thread_db_find_new_threads): Use find_first_thread.
20562 (thread_db_get_tls_address): Likewise.
20563
4105de34
DJ
205642007-06-27 Daniel Jacobowitz <dan@codesourcery.com>
20565
20566 * thread-db.c (thread_db_find_new_threads): Add prototype.
20567 (thread_db_create_event): Check for the main thread before adding
20568 a new thread.
20569 (maybe_attach_thread): Only enable event reporting if TID == 0.
20570 (thread_db_get_tls_address): Check for new threads.
20571
2b876972
DJ
205722007-06-20 Daniel Jacobowitz <dan@codesourcery.com>
20573
20574 * linux-low.c (linux_create_inferior): Try execv before execvp.
20575 * spu-low.c (spu_create_inferior): Likewise.
20576
7a245884
DJ
205772007-06-13 Mike Frysinger <vapier@gentoo.org>
20578
20579 * linux-low.c (linux_create_inferior): Change execv to execvp.
20580 * spu-low.c (spu_create_inferior): Likewies.
20581
117ce543
DJ
205822007-06-13 Daniel Jacobowitz <dan@codesourcery.com>
20583
20584 * Makefile.in (clean): Clean new files instead of deleted ones.
20585 (reg-mips.o, reg-mips.c, reg-mips64.o, reg-mips64.c): Delete.
20586 (mips-linux.o, mips-linux.c, mips64-linux.o, mips64-linux.c): New
20587 rules.
20588 * configure.srv: Specify XML files and new regformats for MIPS and
20589 MIPS64 GNU/Linux.
20590 * linux-mips-low.c (mips_num_regs): Set to only used registers.
20591 (mips_regmap): Do not fetch $0. Remove unused registers. Add
20592 an entry for the restart register.
20593 (mips_cannot_fetch_register, mips_cannot_store_register)
20594 (mips_reinsert_addr, mips_fill_fpregset, mips_store_fpregset): Update
20595 register names to match the XML descriptions.
20596 (mips_fill_gregset, mips_store_gregset): Likewise. Handle the
20597 restart register instead of $0.
20598
0e7f50da
UW
205992007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
20600 Markus Deuling <deuling@de.ibm.com>
20601
20602 * remote-utils.c (decode_xfer_write): New function.
20603 * server.h (decode_xfer_write): Add prototype.
20604 * server.c (handle_query): Add PACKET_LEN argument. Support
20605 qXfer:spu:read and qXfer:spu:write packets.
20606 (main): Pass packet_len to handle_query.
20607 * spu-low.c (spu_target_ops): Add spu_proc_xfer_spu.
20608 * target.h (target_ops): Add qxfer_spu.
20609
374c1d38
UW
206102007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
20611
20612 * spu-low.c (spu_proc_xfer_spu): Do not return failure when
20613 accessing non-seekable spufs files.
20614
bb63802a
UW
206152007-05-16 Markus Deuling <deuling@de.ibm.com>
20616
889bf7c5 20617 * server.c (handle_query): Add reply for qC packet.
bb63802a 20618
7390519e
PA
206192007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20620 Leo Zayas <lerele@champenstudios@com>
20621
20622 * server.h (check_remote_input_interrupt_request): New function.
20623 * remote_utils.c (INVALID_DESCRIPTOR): New define.
20624 (remote_desc): Initialize with INVALID_DESCRIPTOR.
20625 (input_interrupt): Expose on USE_WIN32API too. Fix whitespace.
20626 (check_remote_input_interrupt_request): New function.
20627 * server.h (check_remote_input_interrupt_request): Declare.
3ecf0694 20628 * win32-low.c (winapi_DebugBreakProcess,
7390519e
PA
20629 winapi_GenerateConsoleCtrlEvent): New typedefs.
20630 (get_child_debug_event): Lower Win32 debug event polling from 1 sec
20631 to 250 ms.
20632 (win32_wait): Check for remote interrupt request
20633 with check_remote_input_interrupt_request.
20634 (win32_request_interrupt): New function.
20635 (win32_target_op): Set request_interrupt to win32_request_interrupt.
20636
34b34921
PA
206372007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20638
20639 * win32-low.c (debug_registers_changed,
20640 debug_registers_used, CONTEXT_EXTENDED_REGISTERS,
20641 CONTEXT_FLOATING_POINT, CONTEXT_DEBUG_REGISTERS,
20642 CONTEXT_DEBUGGER, CONTEXT_DEBUGGER_DR): Delete.
20643 (thread_rec): Get context using the low target.
20644 (child_add_thread): Call thread_added on the low target,
20645 which does the same thing.
20646 (regptr): Delete.
20647 (do_initial_child_stuff): Remove debug registers references.
20648 Set context using the low target. Resume threads after
20649 setting the contexts.
20650 (child_continue): Remove dead variable. Remove debug
20651 registers references.
20652 (child_fetch_inferior_registers): Go through the low target.
20653 (do_child_store_inferior_registers): Remove.
20654 (child_store_inferior_registers): Go through the low target.
20655 (win32_resume): Remove debug registers references.
20656 Set context using the low target.
20657 (handle_exception): Change return type to void. Don't record
20658 context here. Set status to TARGET_WAITKIND_SPURIOUS on a
20659 first chance exception.
889bf7c5 20660 (get_child_debug_event): Change return type to void. Remove
34b34921
PA
20661 goto loop. Always return after waiting for debug event.
20662 (win32_wait): Convert to switch statement. Handle spurious
20663 events.
20664
20665 * win32-i386-low.c (debug_registers_changed,
20666 debug_registers_used): New.
20667 (initial_stuff): Rename to ...
20668 (i386_initial_stuff): ... this. Clear debug registers
20669 state variables.
20670 (store_debug_registers): Delete.
20671 (i386_get_thread_context): New.
20672 (load_debug_registers): Delete.
20673 (i386_set_thread_context): New.
20674 (i386_thread_added): New.
20675 (single_step): Rename to ...
20676 (i386_single_step): ... this.
20677 (do_fetch_inferior_registers): Rename to ...
20678 (i386_fetch_inferior_register): ... this.
20679 (i386_store_inferior_register): New.
20680 (the_low_target): Adapt to new interface.
20681
20682 * win32-arm-low.c (CONTEXT_FLOATING_POINT): Define.
20683 (arm_get_thread_context): New.
20684 (arm_set_thread_context): New.
20685 (regptr): New.
20686 (do_fetch_inferior_registers): Rename to ...
20687 (arm_fetch_inferior_register): ... this.
20688 (arm_store_inferior_register): New.
20689 (arm_wince_breakpoint): Reimplement as unsigned long.
20690 (arm_wince_breakpoint_len): Define.
20691 (the_low_target): Adapt to new interface.
20692
20693 * win32-low.h (target_ops): Remove regmap, store_debug_registers and
20694 load_debug_registers. Add get_thread_context, set_thread_context,
20695 thread_added and store_inferior_register. Rename
20696 fetch_inferior_registers to fetch_inferior_register.
20697 (regptr): Remove declaration.
20698
dd6953e1
PA
206992007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20700
20701 * linux-low.c (linux_detach): Change return type to int. Return 0.
20702 * spu-low.c (spu_detach): Likewise.
20703
444d6139
PA
207042007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20705
20706 * target.h (target_ops): Change return type of detach to int.
20707 Add join.
20708 (join_inferior): New.
20709 * server.c (main): Don't skip detach support on mingw32.
20710 If the inferior doesn't support detaching return error.
20711 Call join_inferior instead of using waitpid.
20712 * linux-low.c (linux_join): New.
20713 (linux_target_op): Add linux_join.
20714 * spu-low.c (spu_join): New.
20715 (spu_target_ops): Add spu_join.
20716 * win32-low.c (win32_detach): Adapt to new interface.
20717 Reopen current_process_handle before detaching. Issue a child
20718 resume before detaching.
20719 (win32_join): New.
20720 (win32_target_op): Add win32_join.
20721
1d5315fe
PA
207222007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20723
20724 * win32-low.c (win32-attach): Fix return value.
20725 * target.h (target_ops): Describe ATTACH return values.
20726
bf914831
PA
207272007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20728
20729 * win32-low.c (GETPROCADDRESS): Define.
20730 (winapi_DebugActiveProcessStop): Add WINAPI. typedef as pointer.
20731 (winapi_DebugSetProcessKillOnExit): Likewise.
20732 (win32_create_inferior): Force usage of ansi CreateProcessA.
20733 (win32_attach): Use GETPROCADDRESS.
20734 (win32_detach): Likewise.
20735
f72f3e60
PA
207362007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20737
20738 * win32-low.c (win32_wait): Don't use WSTOPSIG.
20739
ed50f18f
PA
207402007-03-30 Pedro Alves <pedro_alves@portugalmail.pt>
20741
20742 * win32-low.c: Commit leftover changes from 2007-03-29.
20743
0c2ead7e
DJ
207442007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
20745
20746 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Make 16-bit
20747 fields short instead of int. Add explicit padding.
20748 (i387_cache_to_fsave): Remove unnecessary casts.
20749 (i387_fsave_to_cache): Doc fix.
20750 (i387_cache_to_fxsave): Remove unnecessary casts and masking.
20751
73725ff3
DJ
207522007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
20753
20754 * i387-fp.c (i387_cache_to_fxsave): Reinitialize val2 before use.
20755 (i387_fxsave_to_cache): Check fp->ftag while building ftag value.
20756
d99f33d8
PA
207572007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
20758
20759 * configure.srv (arm*-*-mingw32ce*): Move near the other
20760 arm targets.
20761
68070c10
PA
207622007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
20763
2482afc6 20764 * configure.ac: Add errno checking.
68070c10
PA
20765 (AC_CHECK_HEADERS): Add errno.h, fcntl.h, signal.h,
20766 sys/file.h and malloc.h.
20767 (AC_CHECK_DECLS): Add perror.
20768 (srv_mingwce): Handle.
2482afc6 20769 * configure.srv (i[34567]86-*-cygwin*): Add
68070c10
PA
20770 win32-i386-low.o to srv_tgtobj.
20771 (i[34567]86-*-mingw*): Likewise.
20772 (arm*-*-mingw32ce*): Add case.
20773 * gdbreplay.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
20774 HAVE_FCNTL_H, HAVE_ERRNO_H, HAVE_MALLOC_H]: Check.
20775 [__MINGW32CE__] (strerror): New function.
20776 [__MINGW32CE__] (errno): Define to GetLastError.
20777 [__MINGW32CE__] (COUNTOF): New macro.
20778 (remote_open): Remove extra close call.
20779 * mem-break.c (delete_breakpoint_at): New function.
20780 * mem-break.h (delete_breakpoint_at): Declare.
20781 * remote-utils.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
20782 HAVE_FCNTL_H, HAVE_UNISTD_H, HAVE_ERRNO_H]: Check.
20783 [USE_WIN32API] (read, write): Add char* casts.
20784 * server.c [HAVE_UNISTD_H, HAVE_SIGNAL_H]: Check.
20785 * server.h: Include wincecompat.h on Windows CE.
20786 [HAVE_ERRNO_H]: Check.
20787 (perror): Declare if not declared.
20788 * utils.c: Add stdlib.h, errno.h and malloc.h includes.
20789 (perror_with_name): Remove errno declaration.
20790 * wincecompat.h: New.
20791 * wincecompat.c: New.
20792 * win32-low.h: New.
20793 * win32-arm-low.c: New.
20794 * win32-i386-low.c: New.
20795 (win32-low.c): Include mem-break.h and win32-low.h, and winnt.h.
20796 (OUTMSG2): Make it safe.
20797 (_T): New macro.
20798 (COUNTOF): New macro.
20799 (NUM_REGS): Get it from the low target.
20800 (CONTEXT_EXTENDED_REGISTERS, CONTEXT_FLOATING_POINT,
20801 CONTEXT_DEBUG_REGISTERS): Add fallbacks to 0.
20802 (thread_rec): Let low target handle debug registers.
20803 (child_add_thread): Likewise.
20804 (child_init_thread_list): Likewise.
20805 (continue_one_thread): Likewise.
20806 (regptr): New.
20807 (do_child_fetch_inferior_registers): Move to ...
20808 * win32-i386-low.c: ... here, and rename to ...
20809 (do_fetch_inferior_registers): ... this.
889bf7c5 20810 * win32-low.c (child_fetch_inferior_registers):
68070c10
PA
20811 Go through the low target.
20812 (do_child_store_inferior_registers): Use regptr.
20813 (strwinerror): New function.
20814 (win32_create_inferior): Handle Windows CE.
20815 Use strwinerror instead of strerror on Windows error
20816 codes. Add program to the error output.
20817 Don't close the main thread handle on Windows CE.
20818 (win32_attach): Use coredll.dll on Windows CE.
20819 (win32_kill): Close current process and current
20820 thread handles.
20821 (win32_detach): Use coredll.dll on Windows CE.
20822 (win32_resume): Let low target handle debug registers, and
20823 step request.
20824 (handle_exception): Add/Remove initial breakpoint. Avoid
20825 non-existant WSTOPSIG on Windows CE.
20826 (win32_read_inferior_memory): Cast to remove warning.
20827 (win32_arch_string): Go through the low target.
20828 (initialize_low): Call set_breakpoint_data with the low
20829 target's breakpoint.
20830 * win32-low.c (dr, FLAG_TRACE_BIT, FCS_REGNUM,
20831 FOP_REGNUM, mappings): Move to ...
20832 * win32-i386-low.c: ... here.
20833 * win32-low.c (win32_thread_info): Move to ...
20834 * win32-low.h: ... here.
20835 * Makefile.in (SFILES): Add win32-low.c, win32-i386-low.c,
20836 win32-arm-low.c and wincecompat.c.
20837 (all:): Add $EXEEXT.
20838 (install-only:): Likewise.
20839 (gdbserver:): Likewise.
20840 (gdbreplay:): Likewise.
20841 * config.in: Regenerate.
20842 * configure: Regenerate.
20843
41093d81
PA
208442007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
20845
20846 * win32-low.c: Rename typedef thread_info to
20847 win32_thread_info throughout.
20848
544afa54
PA
208492007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
20850
20851 * win32-i386-low.c: Rename to ...
20852 * win32-low.c: ... this.
20853 * configure.srv: Replace win32-i386-low.o with win32-low.o.
20854 * Makefile.in: Likewise.
20855
bce7165d
PA
208562007-03-27 Pedro Alves <pedro_alves@portugalmail.pt>
20857
20858 * remote-utils.c (monitor_output): Constify msg parameter.
20859 * server.h (monitor_output): Likewise.
20860 * win32-i386-low.c (handle_output_debug_string): New.
20861 (win32_kill): Handle OUTPUT_DEBUG_STRING_EVENT events using
20862 handle_output_debug_string.
20863 (get_child_debug_event): Likewise.
20864
506c7aa0
DJ
208652007-03-27 Mat Hostetter <mat@lcs.mit.edu>
20866
20867 * server.c (main): Correct strtoul check.
20868
42c81e2a
DJ
208692007-03-27 Jon Ringle <jon@ringle.org>
20870
20871 * linux-low.c: Check __ARCH_HAS_MMU__ also.
20872
9453113a
DJ
208732007-03-27 Brooks Moses <brooks.moses@codesourcery.com>
20874
20875 * Makefile.in: Add dummy "pdf" and "install-pdf" targets.
20876
64a69107
DJ
208772007-02-27 Daniel Jacobowitz <dan@codesourcery.com>
20878
20879 * terminal.h: Check HAVE_SGTTY_H.
20880
208812007-02-27 Mat Hostetter <mat@lcs.mit.edu>
6f8486da
DJ
20882
20883 * remote-utils.c (remote_open): Print out the assigned port number.
20884
c74d0ad8
DJ
208852007-02-26 Daniel Jacobowitz <dan@codesourcery.com>
20886
20887 * remote-utils.c (monitor_output): New function.
20888 * server.c (debug_threads): Define here.
20889 (monitor_show_help): New function.
20890 (handle_query): Handle qRcmd.
20891 (main): Do not handle 'd' packet.
20892 * server.h (debug_threads, remote_debug, monitor_output): Declare.
20893 * linux-low.c, spu-low.c, win32-i386-low.c: Remove definitions
20894 of debug_threads.
20895
de7c3b4a
PA
208962007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
20897
20898 * Makefile.in (EXEEXT): New.
20899 (clean): Use $(EXEEXT).
20900
ef57601b
PA
209012007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
20902
20903 * target.h (target_ops): Rename send_signal to request_interrupt,
20904 and remove enum target_signal parameter.
20905 * linux-low.c (linux_request_interrupt): Rename from
20906 linux_send_signal, and always send SIGINT.
20907 * spu-low.c (spu_request_interrupt): Rename from spu_send_signal,
20908 and always send SIGINT.
20909 * remote-utils.c (putpkt_binary): Call request_interrupt, instead
20910 of send_signal.
20911 (input_interrupt): Likewise.
20912
820f2bda
PA
209132007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
20914
20915 * server.c (get_features_xml): Check if target implemented
20916 arch_string.
20917 * win32-i386-low.c (win32_arch_string): New.
20918 (win32_target_ops): Add win32_arch_string as arch_string member.
20919
ab39bf24
UW
209202007-02-22 Markus Deuling <deuling@de.ibm.com>
20921
20922 * spu-low.c (spu_arch_string): New.
20923 (spu_target_ops): Add spu_arch_string.
20924
61ff6e04
DJ
209252007-02-16 Daniel Jacobowitz <dan@codesourcery.com>
20926
20927 * remote-utils.c: Remove HAVE_TERMINAL_H check.
20928 * configure.ac: Do not check for terminal.h.
20929 * configure, config.in: Regenerated.
20930
fb1e4ffc
DJ
209312007-02-08 Daniel Jacobowitz <dan@codesourcery.com>
20932
20933 * Makefile.in (OBS): Add $(XML_BUILTIN).
20934 (XML_DIR, XML_TARGET, XML_FILES, XML_BUILTIN): New.
20935 (clean): Update.
20936 (target.xml, xml-builtin.c, stamp-xml, arm-with-iwmmxt.o)
20937 (arm-with-iwmmxt.c): New.
20938 * config.in, configure: Regenerate.
20939 * configure.ac: Check for iWMMXt. Handle srv_xmltarget,
20940 srv_xmlbuiltin, and srv_xmlfiles. Define USE_XML.
20941 * configure.srv: Mention srv_xmltarget and srv_xmlfiles.
20942 (arm*-*-linux*): Add iWMMXt and regset support.
20943 * linux-arm-low.c (PTRACE_GETWMMXREGS, PTRACE_SETWMMXREGS): Define.
20944 (arm_fill_gregset, arm_store_gregset, arm_fill_wmmxregset)
20945 (arm_store_wmmxregset, target_regsets): New.
20946 * server.c (get_features_xml): Take annex argument. Check builtin
20947 XML documents.
20948 (handle_query): Handle multiple annexes.
20949
0f48aa01
DJ
209502007-01-29 Daniel Jacobowitz <dan@codesourcery.com>
20951
20952 * remote-utils.c [USE_WIN32API] (read, write): Define.
20953 (putpkt_binary, input_interrupt, readchar, getpkt): Use read and
20954 write.
20955
23181151
DJ
209562007-01-09 Daniel Jacobowitz <dan@codesourcery.com>
20957
20958 * linux-i386-low.c (the_low_target): Set arch_string.
20959 * linux-x86-64-low.c (the_low_target): Likewise.
20960 * linux-low.c (linux_arch_string): New.
20961 (linux_target_ops): Add it.
20962 * linux-low.h (struct linux_target_ops): Add arch_string.
20963 * server.c (write_qxfer_response): Use const void * for DATA.
20964 (get_features_xml): New.
20965 (handle_query): Handle qXfer:features:read. Report it for qSupported.
20966 * target.h (struct target_ops): Add arch_string method.
20967
9d606399
DJ
209682007-01-03 Denis Pilat <denis.pilat@st.com>
20969 Daniel Jacobowitz <dan@codesourcery.com>
20970
20971 * linux-low.c (linux_kill): Handle being called with no threads.
20972 * win32-i386-low.c (win32_kill): Likewise.
20973 (get_child_debug_event): Clear current_process_handle.
20974
209752006-12-30 Denis PILAT <denis.pilat@st.com>
8264bb58
DJ
20976 Daniel Jacobowitz <dan@codesourcery.com>
20977
20978 * remote-utils.c (remote_open): Check the type of specified
20979 serial port devices before opening them.
20980 * server.c (main): Kill the inferior if an error occurs during
20981 the first remote_open.
20982
a5e13d24
DJ
209832006-12-05 Markus Deuling <deuling@de.ibm.com>
20984
20985 * README: Update supported targets.
20986
186947f7
DJ
209872006-11-28 Daniel Jacobowitz <dan@codesourcery.com>
20988
20989 * Makefile.in (clean): Remove reg-mips64.c.
20990 (reg-mips64.c, reg-mips64.o): New rules.
20991 * configure.srv: Handle mips64. Include regset support for mips.
20992 * linux-mips-low.c (union mips_register): New.
20993 (mips_get_pc, mips_set_pc, mips_reinsert_addr): Use it.
20994 (mips_breakpoint, mips_breakpoint_at): Use int.
20995 (mips_collect_register, mips_supply_register)
20996 (mips_collect_register_32bit, mips_supply_register_32bit)
20997 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
20998 (mips_store_fpregset, target_regsets): New.
20999 * thread-db.c (thread_db_get_tls_address): Use uintptr_t.
21000
a13e2c95
UW
210012006-11-22 Ulrich Weigand <uweigand@de.ibm.com>
21002
21003 * configure.srv: Add target "spu*-*-*".
21004 * Makefile.in (clean): Remove reg-spu.c.
21005 (reg-spu.c, reg-spu.o, spu-low.o): Add dependencies.
21006 * spu-low.c: New file.
21007
cb7283db
DJ
210082006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
21009
21010 * configure.ac: Correct td_thr_tls_get_addr test.
21011 * configure: Regenerated.
21012
89be2091
DJ
210132006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
21014
21015 * linux-low.c (linux_wait_for_event): Reformat. Use the
21016 pass_signals array.
21017 * remote-utils.c (decode_address_to_semicolon): New.
21018 * server.c (pass_signals, handle_general_set): New.
21019 (handle_query): Mention QPassSignals for qSupported.
21020 (main): Call handle_general_set.
21021 * server.h (pass_signals, decode_address_to_semicolon): New.
21022
000ef4f0
DJ
210232006-11-06 Daniel Jacobowitz <dan@codesourcery.com>
21024
21025 * server.c (handle_query): Correct error handling for read_auxv.
21026
b7149293
UW
210272005-10-19 Ulrich Weigand <uweigand@de.ibm.com>
21028
21029 * configure.srv [s390-*-linux*, s390x-*-linux*]: Set srv_linux_regsets
21030 and srv_linux_thread_db to yes.
21031 * linux-s390-low.c (s390_fill_gregset): New function.
21032 (target_regsets): Define data structure.
21033
dae5f5cf
DJ
210342006-10-17 Daniel Jacobowitz <dan@codesourcery.com>
21035
21036 * acinclude.m4 (SRV_CHECK_TLS_GET_ADDR): New.
21037 * configure.ac: Use it. Define HAVE_TD_THR_TLS_GET_ADDR.
21038 * config.in, configure: Regenerated.
21039 * inferiors.c (gdb_id_to_thread): New function.
21040 (gdb_id_to_thread_id): Use it.
21041 * linux-low.c (linux_target_ops): Use thread_db_get_tls_address.
21042 * linux-low.h (struct process_info): Add th member.
21043 (thread_db_get_tls_address): New prototype.
21044 * remote-utils.c (decode_address): Make non-static.
21045 * server.c (handle_query): Handle qGetTLSAddr.
21046 * server.h (gdb_id_to_thread, decode_address): New prototypes.
21047 * target.h (struct target_ops): Add get_tls_address.
21048 * thread-db.c (maybe_attach_thread): Save the thread handle.
21049 (thread_db_get_tls_address): New.
21050
32ca6d61
DJ
210512006-09-28 Daniel Jacobowitz <dan@codesourcery.com>
21052
21053 * linux-low.c (PTRACE_GETSIGINFO, PTRACE_SETSIGINFO): Define.
21054 (linux_resume_one_process): Take a siginfo_t *. Update all
21055 callers. Queue it if necessary. Use PTRACE_SETSIGINFO.
21056 (struct pending_signals): Add a siginfo_t.
21057 (linux_wait_for_process): Always set last_status.
21058 (linux_wait_for_event): Use PTRACE_GETSIGINFO.
21059 (linux_queue_one_thread): Use PTRACE_GETSIGINFO.
21060 * linux-low.h (struct process_info): Add last_status.
21061
5ffff7c1
DJ
210622006-09-21 Daniel Jacobowitz <dan@codesourcery.com>
21063
21064 * remote-utils.c (try_rle): New function.
21065 (putpkt_binary): Use it.
21066
8695c747
DJ
210672006-08-19 Daniel Jacobowitz <dan@codesourcery.com>
21068
21069 * Makefile.in (clean): Clean reg-x86-64-linux.c.
21070 (reg-x86-64-linux.o, reg-x86-64-linux.c): New.
21071 * configure.srv (x86_64-*-linux*): Use reg-x86-64-linux.o.
21072 * linux-x86-64-low.c (x86_64_regmap): Include ORIG_RAX.
21073 (x86_64_fill_gregset, x86_64_store_gregset): Skip floating
21074 point registers.
21075
290fadea
RS
210762006-08-08 Richard Sandiford <richard@codesourcery.com>
21077
21078 * server.c (terminal_fd): New variable.
21079 (old_foreground_pgrp): Likewise.
21080 (restore_old_foreground_pgrp): New function.
21081 (start_inferior): Record the terminal file descriptor in terminal_fd
21082 and its original foreground group in old_foreground_pgrp. Register
21083 restore_old_foreground_pgrp with atexit().
21084
9f2e1e63
DJ
210852006-07-26 Daniel Jacobowitz <dan@codesourcery.com>
21086
21087 * server.c (handle_query): Correct qPart to qXfer.
21088
b80864fb
DJ
210892006-07-22 Daniel Jacobowitz <dan@codesourcery.com>
21090
21091 * configure.ac: Check for more headers which are missing on
21092 Windows. Automatically supply -lwsock32 and USE_WIN32API.
21093 * configure.srv: Add Cygwin and mingw32.
21094 * remote-utils.c: Don't include headers unconditionally which
21095 are missing on mingw32. Include <winsock.h> for mingw32.
21096 (remote_open): Adjust for mingw32 support. Flush
21097 standard error after writing to it.
21098 (remote_close, putpkt_binary, input_interrupt, block_async_io)
21099 (unblock_async_io, enable_async_io, disable_async_io)
21100 (readchar, getpkt): Update for Winsock support.
21101 (prepare_resume_reply): Expect a protocol signal number.
21102 * server.c: Disable <sys/wait.h> on mingw32.
21103 (start_inferior): Adjust for mingw32 support. Flush
21104 standard error after writing to it.
21105 (attach_inferior): Likewise. Use protocol signal
21106 numbers.
21107 (main): Skip 'D' packet on mingw32. Use protocol signal numbers
21108 and names.
21109 * win32-i386-low.c: New file.
21110 * Makefile.in (XM_CLIBS): Set.
21111 (gdbserver, gdbreplay): Use $(INTERNAL_CFLAGS).
21112 (win32-i386-low.o): New dependency rule.
21113 * linux-low.c (linux_wait): Use target signal numbers.
21114 * target.h (struct target_ops): Doc fix.
21115 * server.h (target_signal_to_name): New prototype.
21116 * gdbreplay.c: Don't include headers unconditionally which
21117 are missing on mingw32. Include <winsock.h> for mingw32.
21118 (remote_close, remote_open): Adjust for Winsock support.
21119 * configure, config.in: Regenerated.
21120
0876f84a
DJ
211212006-07-12 Daniel Jacobowitz <dan@codesourcery.com>
21122
21123 * server.c (decode_xfer_read, write_qxfer_response): New.
21124 (handle_query): Take a packet length argument. Handle
21125 qXfer:auxv:read instead of qPart:auxv:read. Mention it in
21126 the qSupported response.
21127 (main): Update call to handle_query.
21128
01f9e8fa
DJ
211292006-06-22 Daniel Jacobowitz <dan@codesourcery.com>
21130
21131 * remote-utils.c (remote_escape_output, remote_unescape_input): New.
21132 (putpkt_binary): Renamed from putpkt and adjusted for binary
21133 data.
21134 (putpkt): New wrapper for putpkt_binary.
21135 (readchar): Don't mask off the high bit.
21136 (decode_X_packet): New function.
21137 * server.c (main): Call putpkt_binary if a handler sets the packet
21138 length. Save the length of the incoming packet. Handle 'X'.
21139 * server.h (gdb_byte, remote_escape_output, decode_X_packet): New.
21140
be2a5f71
DJ
211412006-06-21 Daniel Jacobowitz <dan@codesourcery.com>
21142
21143 * server.c (handle_query): Handle qSupported.
21144
ea025f5f
DJ
211452006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
21146
21147 * remote-utils.c (all_symbols_looked_up): New variable.
21148 (look_up_one_symbol): Check it.
21149 * server.h (look_up_one_symbol): New declaration.
21150 * thread-db.c (thread_db_init): Set all_symbols_looked_up.
21151
9308fc88
DJ
211522006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
21153
21154 * Makefile.in (linux-arm-low.o): Update dependencies.
66f338c7 21155 * linux-arm-low.c: Include "gdb_proc_service.h".
9308fc88
DJ
21156 (PTRACE_GET_THREAD_AREA): Define.
21157 (ps_get_thread_area): New function.
21158
52fb6437
NS
211592006-05-09 Nathan Sidwell <nathan@codesourcery.com>
21160
21161 * configure.srv (m68k*-*-uclinux*): New target.
21162 * linux-low.c (linux_create_inferior): Use vfork on mmuless systems.
21163 (linux_resume_one_process): Remove extraneous cast.
21164 (linux_read_offsets): New.
21165 (linux_target_op): Add linux_read_offsets on mmuless systems.
21166 * server.c (handle_query): Add qOffsets logic.
21167 * target.h (struct target_ops): Add read_offsets.
21168
21b0f40c
DJ
211692006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
21170
21171 * linux-mips-low.c: Include <sys/ptrace.h> and "gdb_proc_service.h".
21172 (PTRACE_GET_THREAD_AREA): Define.
21173 (ps_get_thread_area): New function.
21174 * Makefile.in (linux-i386-low.o, linux-mips-low.o)
21175 (linux-x86-64-low.o): Update.
21176
0050a760
DJ
211772006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
21178
21179 * configure.ac: Remove checks for prfpregset_t.
21180 * gdb_proc_service.h: New file.
21181 * linux-i386-low.c, linux-x86-64-low.c, thread-db.c: Use the
21182 new "gdb_proc_service.h".
21183 * proc-service.c: Likewise.
21184 (ps_pglobal_lookup, ps_pdread, ps_pdwrite): Use psaddr_t.
21185 (ps_lgetfpregs, ps_lsetfpregs): Use a void* argument.
21186 * Makefile.in (gdb_proc_service_h): Updated.
21187 * configure, config.in: Regenerated.
21188
b92a518e
DJ
211892006-03-03 Daniel Jacobowitz <dan@codesourcery.com>
21190
21191 * remote-utils.c (prepare_resume_reply): Move declaration
21192 of gdb_id_from_wait to the top of the block.
21193
545587ee
DJ
211942006-02-15 Daniel Jacobowitz <dan@codesourcery.com>
21195
21196 * linux-low.c (regsets_store_inferior_registers): Read the regset
21197 from the target before filling it.
21198
9db87ebd
DJ
211992006-02-08 Daniel Jacobowitz <dan@codesourcery.com>
21200
21201 * server.c (attach_inferior): Return SIGTRAP for a successful
21202 attach.
21203
dd24457d
DJ
212042006-02-01 Daniel Jacobowitz <dan@codesourcery.com>
21205
21206 * Makefile.in (OBS): Add version.o.
21207 (STAGESTUFF): Delete.
21208 (version.o): Add dependencies.
21209 (version.c): Replace rule.
21210 (clean): Remove version.c.
21211 * server.c (gdbserver_version): New.
21212 (gdbserver_usage): Use printf.
21213 (main): Handle --version and --help.
21214 * server.h (version, host_name): Add declarations.
21215
6f0f660e
EZ
212162005-12-23 Eli Zaretskii <eliz@gnu.org>
21217
889bf7c5
PA
21218 * linux-arm-low.c:
21219 * linux-arm-low.c:
21220 * inferiors.c:
21221 * i387-fp.h:
21222 * i387-fp.c:
21223 * gdbreplay.c:
21224 * regcache.c:
21225 * proc-service.c:
21226 * mem-break.h:
21227 * mem-break.c:
21228 * linux-x86-64-low.c:
21229 * linux-sh-low.c:
21230 * linux-s390-low.c:
21231 * linux-ppc64-low.c:
21232 * linux-ppc-low.c:
21233 * linux-mips-low.c:
21234 * linux-m68k-low.c:
21235 * linux-m32r-low.c:
21236 * linux-low.h:
21237 * linux-low.c:
21238 * linux-ia64-low.c:
21239 * linux-i386-low.c:
21240 * linux-crisv32-low.c:
21241 * thread-db.c:
21242 * terminal.h:
21243 * target.h:
21244 * target.c:
21245 * server.h:
21246 * server.c:
21247 * remote-utils.c:
21248 * regcache.h:
21249 * utils.c:
21250 * Makefile.in:
21251 * configure.ac:
6f0f660e
EZ
21252 * gdbserver.1: Add (C) after Copyright. Update the FSF
21253 address.
21254
9d1fb177
DJ
212552005-11-13 Daniel Jacobowitz <dan@codesourcery.com>
21256
21257 * linux-arm-low.c (arm_eabi_breakpoint): New variable.
21258 (arm_breakpoint_at): Recognize both breakpoints.
21259 (the_low_target): Use the correct breakpoint instruction.
21260
011a70c2
DJ
212612005-11-02 Daniel Jacobowitz <dan@codesourcery.com>
21262
21263 * configure.srv (x86_64-*-linux*): Turn on thread_db support.
21264 * linux-x86-64-low.c (x86_64_breakpoint, x86_64_breakpoint_len)
21265 (x86_64_get_pc, x86_64_set_pc, x86_64_breakpoint_at): New.
21266 (the_low_target): Update.
21267
7fb85e41
AS
212682005-10-25 Andreas Schwab <schwab@suse.de>
21269
21270 * server.c (main): Allocate mem_buf with PBUFSIZ bytes.
21271
21272 * linux-ia64-low.c (ia64_regmap): Remove NAT registers.
21273 (ia64_num_regs): Reduce to 462.
21274
3db0444b
DJ
212752005-09-17 Daniel Jacobowitz <dan@codesourcery.com>
21276
21277 * acinclude.m4: Correct quoting.
21278 * aclocal.m4: Regenerated.
21279
21280 Suggested by SZOKOVACS Robert <szo@ies.hu>:
21281 * thread-db.c (thread_db_err_str): Handle TD_VERSION.
21282 (thread_db_init): Call thread_db_err_str.
21283 * configure.ac: Check for TD_VERSION.
21284 * config.in, configure: Regenerated.
21285
bee0189a
DJ
212862005-07-31 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
21287
21288 * server.h (error, fatal, warning): Add ATTR_FORMAT.
21289
e9d25b98
DJ
212902005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
21291
21292 * configure.ac: Define HAVE_LINUX_REGSETS even if PTRACE_GETREGS
21293 is not available. Define HAVE_PTRACE_GETREGS if it is.
21294 * config.in, configure: Regenerated.
21295 * configure.srv: Set srv_linux_regsets for PowerPC and PowerPC64.
21296 * linux-i386-low.c, linux-m68k-low.c: Update to use
21297 HAVE_PTRACE_GETREGS.
21298 * linux-low.c (regsets_fetch_inferior_registers)
21299 (regsets_store_inferior_registers): Only return 0 if we processed
21300 GENERAL_REGS.
21301 * linux-ppc-low.c (ppc_fill_gregset, target_regsets): New.
21302 * linux-ppc64-low.c (ppc_fill_gregset, target_regsets): New.
21303
a06660f7
DJ
213042005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
21305
21306 * inferiors.c (struct thread_info): Add gdb_id.
21307 (add_thread): Add gdb_id argument.
21308 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New.
21309 * linux-low.c (linux_create_inferior, linux_attach_lwp): Update
21310 calls to add_thread.
21311 * remote-utils.c (prepare_resume_reply: Use thread_to_gdb_id.
21312 * server.c (handle_query): Use thread_to_gdb_id.
21313 (handle_v_cont, main): Use gdb_id_to_thread_id.
21314 * server.h (add_thread): Update prototype.
21315 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New
21316 prototypes.
21317
5a1f5858
DJ
213182005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
21319
21320 * linux-low.c (fetch_register, usr_store_inferior_registers): Handle
21321 left-padded registers.
21322 * linux-low.h (struct linux_target_ops): Add left_pad_xfer.
21323 * linux-ppc64-low.c (the_low_target): Set left_pad_xfer.
21324
e122f1f5
SE
213252005-07-01 Steve Ellcey <sje@cup.hp.com>
21326
21327 * configure.ac (BFD_NEED_DECLARATION): Replace with AC_CHECK_DECLS.
21328 * configure: Regenerate.
21329 * config.in: Regenerate.
21330 * server.h (NEED_DECLARATION_STRERROR):
21331 Replace with !HAVE_DECL_STRERROR.
21332
d592fa2f
DJ
213332005-06-16 Daniel Jacobowitz <dan@codesourcery.com>
21334
21335 * linux-low.c (linux_wait, linux_send_signal): Don't test
21336 an unsigned long variable for > 0 if it could be MAX_ULONG.
21337 * server.c (myresume): Likewise.
21338 * target.c (set_desired_inferior): Likewise.
21339
ccbd4912
MK
213402005-06-13 Mark Kettenis <kettenis@gnu.org>
21341
21342 * configure.ac: Simplify and improve check for socklen_t.
21343 * configure, config.in: Regenerate.
21344
f450004a
DJ
213452005-06-12 Daniel Jacobowitz <dan@codesourcery.com>
21346
21347 * acconfig.h: Remove.
21348 * configure.ac: Add a test for socklen_t. Use three-argument
21349 AC_DEFINE throughout.
21350 * config.in: Regenerated using autoheader 2.59.
21351 * configure: Regenerated.
21352
21353 * gdbreplay.c (socklen_t): Provide a default.
21354 (remote_open): Use socklen_t.
21355 * remote-utils.c (socklen_t): Provide a default.
21356 (remote_open): Use socklen_t.
21357 (convert_int_to_ascii, convert_ascii_to_int, decode_M_packet): Use
21358 unsigned char.
21359
21360 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Use unsigned
21361 char for buffers.
21362 * linux-low.c (linux_read_memory, linux_write_memory)
21363 (linux_read_auxv): Likewise.
21364 * mem-break.c (breakpoint_data, set_breakpoint_data, check_mem_read)
21365 (check_mem_write): Likewise.
21366 * mem-break.h (set_breakpoint_data, check_mem_read, check_mem_write):
21367 Likewise.
21368 * regcache.c (struct inferior_rgcache_data, registers_to_string)
21369 (registers_from_string, register_data): Likewise.
21370 * server.c (handle_query, main): Likewise.
21371 * server.h (convert_ascii_to_int, convert_int_to_ascii)
21372 (decode_M_packet): Likewise.
21373 * target.c (read_inferior_memory, write_inferior_memory): Likewise.
21374 * target.h (struct target_ops): Update read_memory, write_memory,
21375 and read_auxv.
21376 (read_inferior_memory, write_inferior_memory): Update.
21377 * linux-low.h (struct linux_target_ops): Change type of breakpoint
21378 to unsigned char *.
21379 * linux-arm-low.c, linux-cris-low.c, linux-crisv32-low.c,
21380 linux-i386-low.c, linux-m32r-low.c, linux-m68k-low.c,
21381 linux-mips-low.c, linux-ppc-low.c, linux-ppc64-low.c,
21382 linux-s390-low.c, linux-sh-low.c: Update for changes in
21383 read_inferior_memory and the_low_target->breakpoint.
21384
eee84df1
DJ
213852005-05-28 Daniel Jacobowitz <dan@codesourcery.com>
21386
21387 * Makefile.in (SFILES): Add linux-ppc64-low.c.
21388 (linux-ppc64-low.o, reg-ppc64.c, reg-ppc64.o): New targets.
21389 * configure.srv: Add powerpc64-*-linux*.
21390 * linux-ppc64-low.c: New file.
21391
45b134e5
OF
213922005-05-23 Orjan Friberg <orjanf@axis.com>
21393
21394 * linux-cris-low.c: New file with support for CRIS.
21395 * linux-crisv32-low.c: Ditto for CRISv32.
21396 * Makefile.in (SFILES): Add linux-cris-low.c, linux-crisv32-low.c.
21397 (clean): Add reg-cris.c and reg-crisv32.c.
889bf7c5 21398 Add linux-cris-low.o, linux-crisv32-low.o, reg-cris.o, reg-cris.c,
45b134e5
OF
21399 reg-crisv32.o, and reg-crisv32.c to make rules.
21400 * configure.srv: Add cris-*-linux* and crisv32-*-linux* to list of
21401 recognized targets.
21402
48d93c75
UW
214032005-05-16 Ulrich Weigand <uweigand@de.ibm.com>
21404
21405 * linux-low.c (fetch_register): Ensure buffer size is a multiple
21406 of sizeof (PTRACE_XFER_TYPE).
21407 (usr_store_inferior_registers): Likewise. Zero out excess bytes.
21408
e013ee27
OF
214092005-05-12 Orjan Friberg <orjanf@axis.com>
21410
889bf7c5 21411 * target.h (struct target_ops): Add insert_watchpoint,
e013ee27
OF
21412 remove_watchpoint, stopped_by_watchpoint, stopped_data_address function
21413 pointers for hardware watchpoint support.
21414 * linux-low.h (struct linux_target_ops): Ditto.
21415 * linux-low.c (linux_insert_watchpoint, linux_remove_watchpoint)
21416 (linux_stopped_by_watchpoint, linux_stopped_data_address): New. Add
21417 to linux_target_ops.
21418 * remote-utils.c (prepare_resume_reply): Add watchpoint information to
21419 reply packet.
21420 * server.c (main): Recognize 'Z' and 'z' packets.
21421
b0ded00b
UW
214222005-05-10 Ulrich Weigand <uweigand@de.ibm.com>
21423
21424 * linux-s390-low.c (s390_breakpoint, s390_breakpoint_len): Define.
21425 (s390_get_pc, s390_set_pc, s390_breakpoint_at): New functions.
21426 (the_low_target): Add new members.
21427
8643e2ad
DJ
214282005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
21429
21430 * proc-service.c (ps_lgetregs): Search all_processes instead of
21431 all_threads.
21432
fc620387
DJ
214332005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
21434
21435 * server.c (start_inferior): Change return type to int.
21436 (attach_inferior): Change sigptr to int *.
21437 (handle_v_cont, handle_v_requests): Change signal to int *.
21438 (main): Change signal to int.
21439
214402005-04-15 Kei Sakamoto <sakamoto.kei@renesas.com>
7cfbc4a0
KI
21441
21442 * Makefile.in: Add linux-m32r-low.o, reg-m32r.c and reg-m32r.o.
21443 * configure.srv: Add m32r*-*-linux*.
21444 * linux-m32r-low.c: New file.
21445
e0e76420
DJ
214462005-03-04 Daniel Jacobowitz <dan@codesourcery.com>
21447
21448 * Makefile.in (stamp-h): Set CONFIG_HEADERS explicitly.
21449
a1928bad
DJ
214502005-03-03 Daniel Jacobowitz <dan@codesourcery.com>
21451
21452 * inferiors.c (change_inferior_id, add_thread, find_inferior_id):
21453 Take unsigned long arguments for PIDs.
21454 * linux-low.c (add_process, linux_attach_lwp, linux_attach)
21455 (linux_thread_alive, linux_wait_for_event, kill_lwp, send_sigstop)
21456 (wait_for_sigstop, linux_resume_one_process)
21457 (regsets_fetch_inferior_registers, linux_send_signal)
21458 (linux_read_auxv): Likewise. Update the types of variables holding
21459 PIDs. Update format string specifiers.
21460 * linux-low.h (struct process_info, linux_attach_lwp): Likewise.
21461 * remote-utils.c (prepare_resume_reply): Likewise.
21462 * server.c (cont_thread, general_thread, step_thread)
21463 (thread_from_wait, old_thread_from_wait, signal_pid): Change type to
21464 unsigned long.
21465 (handle_query): Update format specifiers.
21466 (handle_v_cont, main): Use strtoul for thread IDs.
21467 * server.h (struct inferior_list_entry): Use unsigned long for ID.
21468 (add_thread, find_inferior_id, change_inferior_id, cont_thread)
21469 (general_thread, step_thread, thread_from_wait)
21470 (old_thread_from_wait): Update.
21471 * target.h (struct thread_resume): Use unsigned long for THREAD.
21472 (struct target_ops): Use unsigned long for arguments to attach and
21473 thread_alive.
21474
dcdb98d2
DJ
214752005-02-24 Daniel Jacobowitz <dan@codesourcery.com>
21476
21477 * acinclude.m4: Include bfd/bfd.m4 directly.
21478 * configure.ac: Use AC_ARG_PROGRAM. Suggested by Aron Griffis
21479 <agriffis@toolchain.org>.
21480 * aclocal.m4, configure: Regenerated.
21481
bec39cab
AC
214822005-01-07 Andrew Cagney <cagney@gnu.org>
21483
21484 * configure.ac: Rename configure.in, require autoconf 2.59.
21485 * configure: Re-generate.
21486
434c4c77
DJ
214872004-12-08 Daniel Jacobowitz <dan@debian.org>
21488
21489 * acinclude.m4 (SRV_CHECK_THREAD_DB): Add ps_get_thread_area. Reset
21490 LIBS when finished.
21491 * aclocal.m4: Regenerated.
21492 * configure: Regenerated.
21493
db1d3e1b
AS
214942004-11-21 Andreas Schwab <schwab@suse.de>
21495
21496 * linux-m68k-low.c (m68k_num_gregs): Define.
21497 (m68k_fill_gregset, m68k_store_gregset, m68k_fill_fpregset)
21498 (m68k_store_fpregset, target_regsets) [HAVE_LINUX_REGSETS]: New.
21499 (m68k_breakpoint, m68k_breakpoint_len, m68k_get_pc, m68k_set_pc)
21500 (m68k_breakpoint_at): New. Add to the_low_target.
21501
21502 * configure.srv (m68*-*-linux*): Set srv_linux_regsets and
21503 srv_linux_thread_db to yes.
21504
43360365
JB
215052004-10-20 Joel Brobecker <brobecker@gnat.com>
21506
21507 * linux-x86-64-low.c (ARCH_SET_GS): Add definition if missing.
21508 (ARCH_SET_FS): Likewise.
21509 (ARCH_GET_FS): Likewise.
21510 (ARCH_GET_GS): Likewise.
21511
fd500816
DJ
215122004-10-16 Daniel Jacobowitz <dan@debian.org>
21513
21514 * linux-i386-low.c (ps_get_thread_area): New.
21515 * linux-x86-64-low.c (ps_get_thread_area): New.
21516 * linux-low.c: Include <sys/syscall.h>.
21517 (linux_kill_one_process): Don't kill the first thread here.
21518 (linux_kill): Kill the first thread here.
21519 (kill_lwp): New function.
21520 (send_sigstop, linux_send_signal): Use it.
21521 * proc-service.c: Clean up #ifdefs.
21522 (fpregset_info): Delete.
21523 (ps_lgetregs): Update and enable implementation.
21524 (ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs): Remove disabled
21525 implementations.
21526 * remote-utils.c (struct sym_cache, symbol_cache): New.
21527 (input_interrupt): Print a clearer message.
21528 (async_io_enabled): New variable.
21529 (enable_async_io, disable_async_io): Use it. Update comments.
21530 (look_up_one_symbol): Use the symbol cache.
21531 * thread-db.c (thread_db_look_up_symbols): New function.
21532 (thread_db_init): Update comments. Call thread_db_look_up_symbols.
21533
f6de3c42
DJ
215342004-10-16 Daniel Jacobowitz <dan@debian.org>
21535
21536 * configure.in: Test for -rdynamic.
21537 * configure: Regenerated.
21538 * Makefile (INTERNAL_LDFLAGS): New.
21539 (gdbserver, gdbreplay): Use it.
21540
2c0fc042
AC
215412004-09-02 Andrew Cagney <cagney@gnu.org>
21542
21543 * Makefile.in (TAGS): Replace TM_FILE with DEPRECATED_TM_FILE.
21544
075b3282
DJ
215452004-03-23 Daniel Jacobowitz <drow@mvista.com>
21546
21547 * linux-low.c (linux_wait): Clear all_processes list also.
21548
fa6a77dc
DJ
215492004-03-12 Daniel Jacobowitz <drow@mvista.com>
21550
21551 * linux-low.c: Include <errno.h>. Remove extern declaration of
21552 errno.
21553
6d782a97
DJ
215542004-03-12 Daniel Jacobowitz <drow@mvista.com>
21555
21556 * gdbreplay.c, server.h, utils.c: Update copyright years.
21557
3a7fb99b
DJ
215582004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
21559
21560 * server.c (main): Print child status or termination signal from
21561 variable 'signal', not 'sig'.
21562
c3e735a6
DJ
215632004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
21564
21565 * linux-low.c (linux_read_memory): Change return type to
21566 int. Check for and return error from ptrace().
21567 * target.c (read_inferior_memory): Change return type to int. Pass
21568 back return status from the_target->read_memory().
21569 * target.h (struct target_ops): Adapt *read_memory() prototype.
21570 Update comment.
21571 (read_inferior_memory): Adapt prototype.
21572 * server.c (main): Return an error packet if
21573 read_inferior_memory() returns an error.
21574
a59d1c82
DJ
215752004-03-04 Daniel Jacobowitz <drow@mvista.com>
21576
21577 * Makefile.in (distclean): Remove config.h, stamp-h, and config.log.
21578 Unify with other clean targets.
21579
dc3f8883
DJ
215802004-02-29 Daniel Jacobowitz <drow@mvista.com>
21581
21582 * server.c (handle_v_cont): Call set_desired_inferior.
21583
89a208da
DJ
215842004-02-29 Daniel Jacobowitz <drow@mvista.com>
21585
21586 * remote-utils.c (prepare_resume_reply): Always supply "thread:".
21587
62ea82f5
DJ
215882004-02-29 Daniel Jacobowitz <drow@mvista.com>
21589
21590 * linux-low.c (linux_wait): Unblock async I/O.
21591 (linux_resume): Block and enable async I/O.
21592 * remote-utils.c (block_async_io, unblock_async_io): New functions.
21593 * server.h (block_async_io, unblock_async_io): Add prototypes.
21594
6910d122
DJ
215952004-02-29 Daniel Jacobowitz <drow@mvista.com>
21596
21597 * remote-utils.c (remote_open): Print a status notice after
21598 opening a TCP port.
21599 * server.c (attach_inferior): Print a status notice after
21600 attaching.
21601
216022004-02-29 Daniel Jacobowitz <drow@mvista.com>
d677d77d
DJ
21603
21604 * linux-arm-low.c (arm_get_pc): Print out stop PC in debug mode.
21605
c89dc5d4
DJ
216062004-02-26 Daniel Jacobowitz <drow@mvista.com>
21607
21608 * remote-utils.c (write_enn): Use "E01" instead of "ENN" for the
21609 error packet.
21610 * server.c, target.h: Update copyright years.
21611
4b8dad4a
RM
216122004-02-25 Roland McGrath <roland@redhat.com>
21613
21614 * target.h (struct target_ops): New member `read_auxv'.
21615 * server.c (handle_query): Handle qPart:auxv:read: query using that.
21616 * linux-low.c (linux_read_auxv): New function.
21617 (linux_target_ops): Initialize `read_auxv' member to that.
21618
d7446758
JB
216192004-02-17 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
21620
21621 Committed by Jim Blandy <jimb@redhat.com>.
21622
21623 * linux-s390-low.c (s390_num_regs): Update.
4b8dad4a 21624 (s390_regmap): Remove control registers. Use __s390x__ predefine
d7446758
JB
21625 instead of GPR_SIZE to distiguish s390 and s390x targets.
21626
5544ad89
DJ
216272004-01-31 Daniel Jacobowitz <drow@mvista.com>
21628
21629 * linux-low.c: Update copyright year.
21630 (check_removed_breakpoint): Clear pending_is_breakpoint.
21631 (linux_set_resume_request, linux_queue_one_thread)
21632 (resume_status_pending_p): New functions.
21633 (linux_continue_one_thread): Use process->resume.
21634 (linux_resume): Only resume threads if there are no pending events.
21635 * linux-low.h (struct process_info): Add resume request
21636 pointer.
21637
2a68b70e
DJ
216382004-01-30 Daniel Jacobowitz <drow@mvista.com>
21639
21640 * regcache.c (new_register_cache): Clear the allocated register
21641 buffer. Suggested by Atsushi Nemoto <anemo@mba.ocn.ne.jp>.
21642
64386c31
DJ
216432003-10-13 Daniel Jacobowitz <drow@mvista.com>
21644
21645 * linux-low.c (linux_resume): Take a struct thread_resume *
21646 argument.
21647 (linux_wait): Update call.
21648 (resume_ptr): New static variable.
21649 (linux_continue_one_thread): Renamed from
21650 linux_continue_one_process. Use resume_ptr.
21651 (linux_resume): Use linux_continue_one_thread.
21652 * server.c (handle_v_cont, handle_v_requests): New functions.
21653 (myresume): New function.
21654 (main): Handle 'v' case.
21655 * target.h (struct thread_resume): New type.
21656 (struct target_ops): Change argument of "resume" to struct
21657 thread_resume *.
21658 (myresume): Delete macro.
21659
c938e9b0
L
216602003-08-08 H.J. Lu <hongjiu.lu@intel.com>
21661
21662 * Makefile.in (install-only): Create dest dir. Support DESTDIR.
21663 (uninstall): Support DESTDIR.
21664
7f313d07
BC
21665Mon Jul 21 20:09:34 UTC 2003 Brendan Conoboy <blc@redhat.com>
21666
21667 * configure.srv: Add xscale*linux copy of arm*linux entry.
21668
3b2fc2ea
DJ
216692003-07-24 Daniel Jacobowitz <drow@mvista.com>
21670
21671 * linux-arm-low.c (arm_reinsert_addr): New function.
21672 (the_low_target): Add arm_reinsert_addr.
21673
1c0a559e
MK
216742003-07-08 Mark Kettenis <kettenis@gnu.org>
21675
21676 * mem-break.c: Remove whitespace at end of file.
21677
43d5792c
DJ
216782003-06-28 Daniel Jacobowitz <drow@mvista.com>
21679
21680 * configure.in: Check whether we need to prototype strerror.
21681 * server.h: Optionally prototype strerror.
21682 * gdbreplay.c (perror_with_name): Use strerror.
21683 * linux-low.c (linux_attach_lwp): Use strerror.
21684 * utils.c (perror_with_name): Use strerror.
21685 * config.in, configure: Regenerated.
21686
c8a86edf
DJ
216872003-06-28 Daniel Jacobowitz <drow@mvista.com>
21688
21689 * linux-sh-low.c (sh_regmap): Fix FP register offsets, reported by
21690 SUGIOKA Toshinobu <sugioka@itonet.co.jp>.
21691
73d37363
DJ
216922003-06-20 Daniel Jacobowitz <drow@mvista.com>
21693
21694 * Makefile.in (SFILES): Update.
21695 * low-hppabsd.c, low-lynx.c, low-nbsd.c, low-sim.c, low-sparc.c,
21696 low-sun3.c: Remove files.
21697
6ad8ae5c
DJ
216982003-06-17 Daniel Jacobowitz <drow@mvista.com>
21699
21700 * linux-low.c: Move comment to linux_thread_alive where it belonged.
21701 (linux_detach_one_process, linux_detach): New functions.
21702 (linux_target_ops): Add linux_detach.
21703 * server.c (main): Handle 'D' packet.
21704 * target.h (struct target_ops): Add "detach" member.
21705 (detach_inferior): Define.
21706
1581182a
MK
217072003-06-13 Mark Kettenis <kettenis@gnu.org>
21708
21709 From Kelley Cook <kelleycook@wideopenwest.com>:
21710 * configure.srv: Accept i[34567]86 variants.
21711
e5379b03
DJ
217122003-06-05 Daniel Jacobowitz <drow@mvista.com>
21713
21714 * linux-low.c (linux_wait_for_event): Correct comment typos.
21715 (linux_resume_one_process): Call check_removed_breakpoint.
21716 (linux_send_signal): New function.
21717 (linux_target_ops): Add linux_send_signal.
21718 * remote-utils.c (putpkt, input_interrupt): Use send_signal instead
21719 of kill.
21720 * target.h (struct target_ops): Add send_signal.
21721
2ff29de4
JB
217222003-05-29 Jim Blandy <jimb@redhat.com>
21723
21724 * linux-low.c (usr_store_inferior_registers): Transfer buf in
21725 PTRACE_XFER_TYPE-sized chunks, not int-sized chunks. Otherwise,
21726 if 'int' is smaller than PTRACE_XFER_TYPE, you end up throwing
21727 away part of the register's value.
21728
254787d4
DJ
217292003-03-26 Daniel Jacobowitz <drow@mvista.com>
21730
21731 * linux-low.c (linux_create_inferior): Use __SIGRTMIN.
21732 (linux_wait_for_event, linux_init_signals): Likewise.
21733
94e10508
DJ
217342003-03-17 Daniel Jacobowitz <drow@mvista.com>
21735
21736 * configure.in: Check for stdlib.h.
21737 * configure: Regenerated.
21738 * config.in: Regenerated.
21739
4c0711e0
DJ
217402003-01-04 Andreas Schwab <schwab@suse.de>
21741
21742 * linux-m68k-low.c (m68k_num_regs): Define to 29 instead of 31.
21743
ef66e766
AC
217442003-01-02 Andrew Cagney <ac131313@redhat.com>
21745
21746 * Makefile.in: Remove obsolete code.
21747
a1358604
DJ
217482002-11-20 Daniel Jacobowitz <drow@mvista.com>
21749
21750 * linux-s390-low.c (s390_regmap): Check GPR_SIZE instead of
21751 defined(PT_FPR0_HI).
21752
23ce3b1c
DJ
217532002-11-17 Stuart Hughes <seh@zee2.com>
21754
21755 * linux-arm-low.c (arm_num_regs): Increase.
21756 (arm_regmap): Include status register.
21757
217582002-11-17 Daniel Jacobowitz <drow@mvista.com>
21759
21760 * linux-low.c (register_addr): Remove incorrect -1 check.
21761
a9fa9f7d
DJ
217622002-08-29 Daniel Jacobowitz <drow@mvista.com>
21763
21764 * linux-low.c (linux_create_inferior): Call setpgid. Return
21765 the new PID.
21766 (unstopped_p, linux_signal_pid): Remove.
21767 (linux_target_ops): Remove linux_signal_pid.
21768 * remote-utils.c (putpkt, input_interrupt): Use signal_pid
21769 global instead of target method.
21770 * target.h (struct target_ops): Remove signal_pid. Update comment
21771 for create_inferior.
21772 * server.c (signal_pid): New variable.
21773 (create_inferior): Set signal_pid. Block SIGTTOU and SIGTTIN in
4b8dad4a 21774 gdbserver. Set the child to be the foreground process group.
a9fa9f7d
DJ
21775 (attach_inferior): Set signal_pid.
21776
17574093
DJ
217772002-08-23 Daniel Jacobowitz <drow@mvista.com>
21778
21779 * ChangeLog: New file, with entries from gdb/ChangeLog after GDB 5.2.
21780
217812002-08-20 Jim Blandy <jimb@redhat.com>
21782
21783 * Makefile.in (LDFLAGS): Allow the configure script to establish a
21784 default for this.
21785
217862002-08-01 Andrew Cagney <cagney@redhat.com>
21787
21788 * Makefile.in: Make chill references obsolete.
21789
217902002-07-24 Kevin Buettner <kevinb@redhat.com>
21791
21792 * configure.in (unistd.h): Add to AC_CHECK_HEADERS list.
21793 * configure: Regenerate.
21794 * config.in: Regenerate.
21795
217962002-07-09 David O'Brien <obrien@FreeBSD.org>
21797
21798 * gdbreplay.c (stdlib.h, unistd.h): Conditionaly include.
21799 (perror_with_name, remote_close, remote_open, expect, play): Static.
21800
218012002-07-04 Michal Ludvig <mludvig@suse.cz>
21802
4b8dad4a 21803 * linux-x86-64-low.c (x86_64_regmap): Make it an array of
17574093
DJ
21804 byte offsets instead of an array of indexes.
21805 (x86_64_store_gregset, x86_64_store_fpregset): Parameter made const.
21806
218072002-06-13 Daniel Jacobowitz <drow@mvista.com>
21808
21809 * regcache.c: Add comment.
21810
218112002-06-11 Daniel Jacobowitz <drow@mvista.com>
21812
21813 * thread-db.c: New file.
21814 * proc-service.c: New file.
21815 * acinclude.m4: New file.
21816 * Makefile.in: Add GDBSERVER_LIBS, gdb_proc_service_h,
21817 proc-service.o, and thread-db.o.
21818 (linux-low.o): Add USE_THREAD_DB.
21819 * acconfig.h: Add HAVE_PRGREGSET_T, HAVE_PRFPREGSET_T,
21820 HAVE_LWPID_T, HAVE_PSADDR_T, and PRFPREGSET_T_BROKEN.
21821 * aclocal.m4: Regenerated.
21822 * config.in: Regenerated.
21823 * configure: Regenerated.
21824 * configure.in: Check for proc_service.h, sys/procfs.h,
21825 thread_db.h, and linux/elf.h headrs.
21826 Check for lwpid_t, psaddr_t, prgregset_t, prfpregset_t, and
21827 PRFPREGSET_T_BROKEN. Introduce srv_thread_depfiles and USE_THREAD_DB.
21828 Check for -lthread_db and thread support.
21829 * configure.srv: Enable thread_db support for ARM, i386, MIPS,
21830 PowerPC, and SuperH.
21831 * i387-fp.c: Constify arguments.
21832 * i387-fp.h: Likewise.
21833 * inferiors.c: (struct thread_info): Renamed from
21834 `struct inferior_info'. Remove PID member. Use generic inferior
21835 list header. All uses updated.
21836 (inferiors, signal_pid): Removed.
21837 (all_threads): New variable.
21838 (get_thread): Define.
21839 (add_inferior_to_list): New function.
21840 (for_each_inferior): New function.
21841 (change_inferior_id): New function.
21842 (add_inferior): Removed.
21843 (remove_inferior): New function.
21844 (add_thread): New function.
21845 (free_one_thread): New function.
21846 (remove_thread): New function.
21847 (clear_inferiors): Use for_each_inferior and free_one_thread.
21848 (find_inferior): New function.
21849 (find_inferior_id): New function.
21850 (inferior_target_data): Update argument type.
21851 (set_inferior_target_data): Likewise.
21852 (inferior_regcache_data): Likewise.
21853 (set_inferior_regcache_data): Likewise.
21854 * linux-low.c (linux_bp_reinsert): Remove.
21855 (all_processes, stopping_threads, using_thrads)
21856 (struct pending_signals, debug_threads, pid_of): New.
21857 (inferior_pid): Replace with macro.
21858 (struct inferior_linux_data): Remove.
21859 (get_stop_pc, add_process): New functions.
21860 (linux_create_inferior): Restore SIGRTMIN+1 before calling exec.
21861 Use add_process and add_thread.
21862 (linux_attach_lwp): New function, based on old linux_attach. Use
21863 add_process and add_thread. Set stop_expected for new threads.
21864 (linux_attach): New function.
21865 (linux_kill_one_process): New function.
21866 (linux_kill): Kill all LWPs.
21867 (linux_thread_alive): Use find_inferior_id.
21868 (check_removed_breakpoints, status_pending_p): New functions.
21869 (linux_wait_for_process): Renamed from linux_wait_for_one_inferior.
21870 Update. Use WNOHANG. Wait for cloned processes also. Update process
21871 struct for the found process.
21872 (linux_wait_for_event): New function.
21873 (linux_wait): Use it. Support LWPs.
21874 (send_sigstop, wait_for_sigstop, stop_all_processes)
21875 (linux_resume_one_process, linux_continue_one_process): New functions.
21876 (linux_resume): Support LWPs.
21877 (REGISTER_RAW_SIZE): Remove.
21878 (fetch_register): Use register_size instead. Call supply_register.
21879 (usr_store_inferior_registers): Likewise. Call collect_register.
21880 Fix recursive case.
21881 (regsets_fetch_inferior_registers): Improve error message.
21882 (regsets_store_inferior_registers): Add debugging.
21883 (linux_look_up_symbols): Call thread_db_init if USE_THREAD_DB.
21884 (unstopped_p, linux_signal_pid): New functions.
21885 (linux_target_ops): Add linux_signal_pid.
21886 (linux_init_signals): New function.
21887 (initialize_low): Call it. Initialize using_threads.
21888 * regcache.c (inferior_regcache_data): Add valid
21889 flag.
21890 (get_regcache): Fetch registers lazily. Add fetch argument
21891 and update all callers.
21892 (regcache_invalidate_one, regcache_invalidate): New
21893 functions.
21894 (new_register_cache): Renamed from create_register_cache.
21895 Return the new regcache.
21896 (free_register_cache): Change argument to a void *.
21897 (registers_to_string, registers_from_string): Call get_regcache
21898 with fetch flag set.
21899 (register_data): Make static. Pass fetch flag to get_regcache.
21900 (supply_register): Call get_regcache with fetch flag clear.
21901 (collect_register): Call get_regcache with fetch flag set.
21902 (collect_register_as_string): New function.
21903 * regcache.h: Update.
21904 * remote-utils.c (putpkt): Flush after debug output and use
21905 stderr.
21906 Handle input interrupts while waiting for an ACK.
21907 (input_interrupt): Use signal_pid method.
21908 (getpkt): Flush after debug output and use stderr.
21909 (outreg): Use collect_register_as_string.
21910 (new_thread_notify, dead_thread_notify): New functions.
21911 (prepare_resume_reply): Check using_threads. Set thread_from_wait
21912 and general_thread.
21913 (look_up_one_symbol): Flush after debug output.
21914 * server.c (step_thread, server_waiting): New variables.
21915 (start_inferior): Don't use signal_pid. Update call to mywait.
21916 (attach_inferior): Update call to mywait.
21917 (handle_query): Handle qfThreadInfo and qsThreadInfo.
21918 (main): Don't fetch/store registers explicitly. Use
21919 set_desired_inferior. Support proposed ``Hs'' packet. Update
21920 calls to mywait.
21921 * server.h: Update.
21922 (struct inferior_list, struct_inferior_list_entry): New.
21923 * target.c (set_desired_inferior): New.
21924 (write_inferior_memory): Constify.
21925 (mywait): New function.
21926 * target.h: Update.
21927 (struct target_ops): New signal_pid method.
21928 (mywait): Removed macro, added prototype.
21929
21930 * linux-low.h (regset_func): Removed.
21931 (regset_fill_func, regset_store_func): New.
21932 (enum regset_type): New.
21933 (struct regset_info): Add type field. Use new operation types.
21934 (struct linux_target_ops): stop_pc renamed to get_pc.
21935 Add decr_pc_after_break and breakpoint_at.
21936 (get_process, get_thread_proess, get_process_thread)
21937 (strut process_info, all_processes, linux_attach_lwp)
21938 (thread_db_init): New.
21939
21940 * linux-arm-low.c (arm_get_pc, arm_set_pc,
21941 arm_breakpoint, arm_breakpoint_len, arm_breakpoint_at): New.
21942 (the_low_target): Add new members.
21943 * linux-i386-low.c (i386_store_gregset, i386_store_fpregset)
21944 (i386_store_fpxregset): Constify.
21945 (target_regsets): Add new kind identifier.
21946 (i386_get_pc): Renamed from i386_stop_pc. Simplify.
21947 (i386_set_pc): Add debugging.
21948 (i386_breakpoint_at): New function.
21949 (the_low_target): Add new members.
21950 * linux-mips-low.c (mips_get_pc, mips_set_pc)
21951 (mips_breakpoint, mips_breakpoint_len, mips_reinsert_addr)
21952 (mips_breakpoint_at): New.
21953 (the_low_target): Add new members.
21954 * linux-ppc-low.c (ppc_get_pc, ppc_set_pc)
21955 (ppc_breakpoint, ppc_breakpoint_len, ppc_breakpoint_at): New.
21956 (the_low_target): Add new members.
21957 * linux-sh-low.c (sh_get_pc, sh_set_pc)
21958 (sh_breakpoint, sh_breakpoint_len, sh_breakpoint_at): New.
21959 (the_low_target): Add new members.
21960 * linux-x86-64-low.c (target_regsets): Add new kind
21961 identifier.
21962
219632002-05-15 Daniel Jacobowitz <drow@mvista.com>
21964
21965 From Martin Pool <mbp@samba.org>:
21966 * server.c (gdbserver_usage): New function.
21967 (main): Call it.
21968
219692002-05-14 Daniel Jacobowitz <drow@mvista.com>
21970
21971 * mem-break.c (reinsert_breakpoint_by_bp): Correct typo
21972 stop_at -> stop_pc.
21973
219742002-05-04 Andrew Cagney <ac131313@redhat.com>
21975
21976 * Makefile.in: Remove obsolete code.
21977
219782002-04-24 Michal Ludvig <mludvig@suse.cz>
21979
21980 * linux-low.c (regsets_fetch_inferior_registers),
21981 (regsets_store_inferior_registers): Removed cast to int from
21982 ptrace() calls.
21983 * regcache.h: Added declaration of struct inferior_info.
21984
219852002-04-20 Daniel Jacobowitz <drow@mvista.com>
21986
21987 * inferiors.c (struct inferior_info): Add regcache_data.
21988 (add_inferior): Call create_register_cache.
21989 (clear_inferiors): Call free_register_cache.
21990 (inferior_regcache_data, set_inferior_regcache_data): New functions.
21991 * regcache.c (struct inferior_regcache_data): New.
21992 (registers): Remove.
21993 (get_regcache): New function.
21994 (create_register_cache, free_register_cache): New functions.
21995 (set_register_cache): Don't initialize the register cache here.
21996 (registers_to_string, registers_from_string, register_data): Call
21997 get_regcache.
21998 * regcache.h: Add prototypes.
21999 * server.h: Likewise.
22000
220012002-04-20 Daniel Jacobowitz <drow@mvista.com>
22002
22003 * mem-break.c: New file.
22004 * mem-break.h: New file.
22005 * Makefile.in: Add mem-break.o rule; update server.h
22006 dependencies.
22007 * inferiors.c (struct inferior_info): Add target_data
22008 member.
22009 (clear_inferiors): Free target_data member if set.
22010 (inferior_target_data, set_inferior_target_data): New functions.
22011 * linux-i386-low.c (i386_breakpoint, i386_breakpoint_len)
22012 (i386_stop_pc, i386_set_pc): New. Add to the_low_target.
22013 * linux-low.c (linux_bp_reinsert): New variable.
22014 (struct inferior_linux_data): New.
22015 (linux_create_inferior): Use set_inferior_target_data.
22016 (linux_attach): Likewise. Call add_inferior.
22017 (linux_wait_for_one_inferior): New function.
22018 (linux_wait): Call it.
22019 (linux_write_memory): Add const.
22020 (initialize_low): Call set_breakpoint_data.
22021 * linux-low.h (struct linux_target_ops): Add breakpoint
22022 handling members.
22023 * server.c (attach_inferior): Remove extra add_inferior
22024 call.
22025 * server.h: Include mem-break.h. Update inferior.c
22026 prototypes.
22027 * target.c (read_inferior_memory)
22028 (write_inferior_memory): New functions.
22029 * target.h (read_inferior_memory)
22030 (write_inferior_memory): Change macros to prototypes.
22031 (struct target_ops): Update comments. Add const to write_memory
22032 definition.
22033
220342002-04-11 Daniel Jacobowitz <drow@mvista.com>
22035
22036 * linux-low.c (usr_store_inferior_registers): Support
22037 registers which are allowed to fail to store.
22038 * linux-low.h (linux_target_ops): Likewise.
22039 * linux-ppc-low.c (ppc_regmap): Support FPSCR.
22040 (ppc_cannot_store_register): FPSCR may not be storable.
22041
220422002-04-09 Daniel Jacobowitz <drow@mvista.com>
22043
22044 * server.h: Include <string.h> if HAVE_STRING_H.
22045 * ChangeLog: Correct paths in last ChangeLog entry.
22046
220472002-04-09 Daniel Jacobowitz <drow@mvista.com>
22048
22049 * linux-low.h: Remove obsolete prototypes.
22050 (struct linux_target_ops): New.
22051 (extern the_low_target): New.
22052 * linux-low.c (num_regs, regmap): Remove declarations.
22053 (register_addr): Use the_low_target explicitly.
22054 (fetch_register): Likewise.
22055 (usr_fetch_inferior_registers): Likewise.
22056 (usr_store_inferior_registers): Likewise.
22057 * linux-arm-low.c (num_regs): Remove.
22058 (arm_num_regs): Define.
22059 (arm_regmap): Renamed from regmap, made static.
22060 (arm_cannot_fetch_register): Renamed from cannot_fetch_register,
22061 made static.
22062 (arm_cannot_store_register): Renamed from cannot_store_register,
22063 made static.
22064 (the_low_target): New.
22065 * linux-i386-low.c (num_regs): Remove.
22066 (i386_num_regs): Define.
22067 (i386_regmap): Renamed from regmap, made static.
22068 (i386_cannot_fetch_register): Renamed from cannot_fetch_register,
22069 made static.
22070 (i386_cannot_store_register): Renamed from cannot_store_register,
22071 made static.
22072 (the_low_target): New.
22073 * linux-ia64-low.c (num_regs): Remove.
22074 (ia64_num_regs): Define.
22075 (ia64_regmap): Renamed from regmap, made static.
22076 (ia64_cannot_fetch_register): Renamed from cannot_fetch_register,
22077 made static.
22078 (ia64_cannot_store_register): Renamed from cannot_store_register,
22079 made static.
22080 (the_low_target): New.
22081 * linux-m68k-low.c (num_regs): Remove.
22082 (m68k_num_regs): Define.
22083 (m68k_regmap): Renamed from regmap, made static.
22084 (m68k_cannot_fetch_register): Renamed from cannot_fetch_register,
22085 made static.
22086 (m68k_cannot_store_register): Renamed from cannot_store_register,
22087 made static.
22088 (the_low_target): New.
22089 * linux-mips-low.c (num_regs): Remove.
22090 (mips_num_regs): Define.
22091 (mips_regmap): Renamed from regmap, made static.
22092 (mips_cannot_fetch_register): Renamed from cannot_fetch_register,
22093 made static.
22094 (mips_cannot_store_register): Renamed from cannot_store_register,
22095 made static.
22096 (the_low_target): New.
22097 * linux-ppc-low.c (num_regs): Remove.
22098 (ppc_num_regs): Define.
22099 (ppc_regmap): Renamed from regmap, made static.
22100 (ppc_cannot_fetch_register): Renamed from cannot_fetch_register,
22101 made static.
22102 (ppc_cannot_store_register): Renamed from cannot_store_register,
22103 made static.
22104 (the_low_target): New.
22105 * linux-s390-low.c (num_regs): Remove.
22106 (s390_num_regs): Define.
22107 (s390_regmap): Renamed from regmap, made static.
22108 (s390_cannot_fetch_register): Renamed from cannot_fetch_register,
22109 made static.
22110 (s390_cannot_store_register): Renamed from cannot_store_register,
22111 made static.
22112 (the_low_target): New.
22113 * linux-sh-low.c (num_regs): Remove.
22114 (sh_num_regs): Define.
22115 (sh_regmap): Renamed from regmap, made static.
22116 (sh_cannot_fetch_register): Renamed from cannot_fetch_register,
22117 made static.
22118 (sh_cannot_store_register): Renamed from cannot_store_register,
22119 made static.
22120 (the_low_target): New.
22121 * linux-x86-64-low.c (x86_64_regmap): Renamed from regmap.
22122 (the_low_target): New.
22123
221242002-04-09 Daniel Jacobowitz <drow@mvista.com>
22125
22126 * Makefile.in: Add stamp-h target.
22127 * configure.in: Create stamp-h.
22128 * configure: Regenerated.
22129
221302002-04-09 Daniel Jacobowitz <drow@mvista.com>
22131
22132 * inferiors.c: New file.
22133 * target.c: New file.
22134 * target.h: New file.
22135 * Makefile.in: Add target.o and inferiors.o. Update
22136 dependencies.
22137 * linux-low.c (inferior_pid): New static variable,
22138 moved from server.c.
22139 (linux_create_inferior): Renamed from create_inferior.
22140 Call add_inferior. Return 0 on success instead of a PID.
22141 (linux_attach): Renamed from myattach.
22142 (linux_kill): Renamed from kill_inferior. Call clear_inferiors ().
22143 (linux_thread_alive): Renamed from mythread_alive.
22144 (linux_wait): Renamed from mywait. Call clear_inferiors () if the
22145 child dies.
22146 (linux_resume): Renamed from myresume. Add missing ``return 0''.
22147 (regsets_store_inferior_registers): Correct error message.
22148 Add missing ``return 0''.
22149 (linux_fetch_registers): Renamed from fetch_inferior_registers.
22150 (linux_store_registers): Renamed from store_inferior_registers.
22151 (linux_read_memory): Renamed from read_inferior_memory.
22152 (linux_write_memory): Renamed from write_inferior_memory.
22153 (linux_target_ops): New structure.
22154 (initialize_low): Call set_target_ops ().
22155 * remote-utils.c (unhexify): New function.
22156 (hexify): New function.
22157 (input_interrupt): Send signals to ``signal_pid''.
22158 * server.c (inferior_pid): Remove.
22159 (start_inferior): Update create_inferior call.
22160 (attach_inferior): Call add_inferior.
22161 (handle_query): New function.
22162 (main): Call handle_query for `q' packets.
22163 * server.h: Include "target.h". Remove obsolete prototypes.
22164 Add prototypes for "inferiors.c", "target.c", hexify, and unhexify.
22165
221662002-04-09 Daniel Jacobowitz <drow@mvista.com>
22167
22168 * Makefile.in: Add WARN_CFLAGS. Update configury
22169 dependencies.
22170 * configure.in: Check for <string.h>
22171 * configure: Regenerate.
22172 * config.in: Regenerate.
22173 * gdbreplay.c: Include needed system headers.
22174 (remote_open): Remove strchr prototype.
22175 * linux-low.h: Correct #ifdef to HAVE_LINUX_USRREGS.
22176 * regcache.c (supply_register): Change buf argument to const void *.
22177 (supply_register_by_name): Likewise.
22178 (collect_register): Change buf argument to void *.
22179 (collect_register_by_name): Likewise.
22180 * regcache.h: Add missing prototypes.
22181 * remote-utils.c: Include <arpa/inet.h> for inet_ntoa.
22182 * server.c (handle_query): New function.
22183 (attached): New static variable, moved out of main.
22184 (main): Quiet longjmp clobber warnings.
22185 * server.h: Add ATTR_NORETURN and ATTR_FORMAT. Update prototypes.
22186 * utils.c (error): Remove NORETURN.
22187 (fatal): Likewise.