]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blob - gdbserver/ChangeLog
4853463d05d30a28e53d407f1e16595d8d1bfe91
[thirdparty/binutils-gdb.git] / gdbserver / ChangeLog
1 2020-04-30 Hannes Domani <ssbssa@yahoo.de>
2
3 * configure.srv <x86_64-*-mingw*, x86_64-*-cygwin*> (srv_tgtobj):
4 Add arch/i386.o.
5 * win32-arm-low.cc (arm_num_regs): New function.
6 (struct win32_target_ops): Use arm_num_regs.
7 * win32-i386-low.cc (win32_get_current_dr): Adapt for WOW64
8 processes.
9 (i386_get_thread_context): Likewise.
10 (i386_prepare_to_resume): Likewise.
11 (i386_thread_added): Likewise.
12 (i386_single_step): Likewise.
13 (i386_fetch_inferior_register): Likewise.
14 (i386_store_inferior_register): Likewise.
15 (i386_arch_setup): Likewise.
16 (i386_win32_num_regs): New function.
17 (struct win32_target_ops): Use i386_win32_num_regs.
18 * win32-low.cc (win32_get_thread_context): Adapt for WOW64
19 processes.
20 (win32_require_context): Likewise.
21 (child_add_thread): Likewise.
22 (do_initial_child_stuff): Likewise.
23 (continue_one_thread): Likewise.
24 (win32_process_target::resume): Likewise.
25 (load_psapi): Likewise.
26 (win32_add_all_dlls): Likewise.
27 (maybe_adjust_pc): Likewise.
28 (win32_process_target::qxfer_siginfo): Likewise.
29 (initialize_low): Likewise.
30 * win32-low.h (struct win32_target_ops): Change num_regs to
31 callback function.
32
33 2020-04-27 Simon Marchi <simon.marchi@efficios.com>
34
35 * configure.ac: Remove check for fs_base/gs_base in
36 user_regs_struct.
37 * configure: Re-generate.
38 * config.in: Re-generate.
39 * linux-x86-low.cc (x86_64_regmap, x86_fill_gregset,
40 x86_store_gregset): Adjust.
41
42 2020-04-22 Hannes Domani <ssbssa@yahoo.de>
43
44 * server.cc (handle_search_memory_1): Fix gdb_read_memory return value
45 comparison.
46
47 2020-04-16 Tom Tromey <tromey@adacore.com>
48
49 * win32-low.cc (windows_nat::handle_access_violation): New
50 function.
51
52 2020-04-15 Simon Marchi <simon.marchi@polymtl.ca>
53
54 * win32-low.cc (get_child_debug_event): Fix format string warning.
55
56 2020-04-13 Tom Tromey <tom@tromey.com>
57
58 * server.h (gdb_fildes_t): Remove typedef.
59 * remote-utils.c (remote_desc, list_desc): Now int.
60 (INVALID_DESCRIPTOR): Remove.
61 (gdb_connected, remote_close)
62 (check_remote_input_interrupt_request): Update.
63 * utils.h (pfildes): Don't declare.
64 * utils.c (pfildes): Remove.
65
66 2020-04-13 Tom Tromey <tom@tromey.com>
67
68 * server.h (handle_serial_event, handle_target_event): Update.
69 * server.c: Don't call initialize_event_loop.
70 (keep_processing_events): New global.
71 (handle_serial_event): Return void. Set keep_processing_events.
72 (handle_target_event): Return void.
73 (start_event_loop): Move from event-loop.c. Rewrite.
74 * remote-utils.c (handle_accept_event): Return void.
75 (reset_readchar): Use delete_timer.
76 (process_remaining): Return void.
77 (reschedule): Use create_timer.
78 * event-loop.h: Remove.
79 * event-loop.cc: Remove.
80 * Makefile.in (OBS): Use gdbsupport/event-loop.o, not event-loop.o.
81
82 2020-04-13 Tom Tromey <tom@tromey.com>
83
84 * server.c (invoke_async_signal_handlers)
85 (check_async_event_handlers, flush_streams, gdb_select): New
86 functions.
87
88 2020-04-13 Tom Tromey <tom@tromey.com>
89
90 * configure: Rebuild.
91 * config.in: Rebuild.
92
93 2020-04-08 Tom Tromey <tromey@adacore.com>
94
95 PR gdb/22992
96 * win32-low.c (child_continue): Call matching_pending_stop.
97 (get_child_debug_event): Call fetch_pending_stop. Push pending
98 stop when needed.
99
100 2020-04-08 Tom Tromey <tromey@adacore.com>
101
102 * win32-low.h (win32_process_target::stopped_by_sw_breakpoint)
103 (win32_process_target::supports_stopped_by_sw_breakpoint):
104 Declare.
105 * win32-low.c (win32_supports_z_point_type): Always handle
106 Z_PACKET_SW_BP.
107 (win32_insert_point): Call insert_memory_breakpoint when needed.
108 (win32_remove_point): Call remove_memory_breakpoint when needed.
109 (win32_process_target::stopped_by_sw_breakpoint)
110 (win32_process_target::supports_stopped_by_sw_breakpoint): New
111 methods.
112 (win32_target_ops): Update.
113 (maybe_adjust_pc): New function.
114 (win32_wait): Call maybe_adjust_pc.
115
116 2020-04-08 Tom Tromey <tromey@adacore.com>
117
118 * win32-low.h (struct win32_target_ops) <decr_pc_after_break>: New
119 field.
120 * win32-i386-low.c (the_low_target): Update.
121 * win32-arm-low.c (the_low_target): Update.
122
123 2020-04-08 Tom Tromey <tromey@adacore.com>
124
125 * win32-low.h (win32_process_target::read_pc)
126 (win32_process_target::write_pc): Declare.
127 * win32-low.c (win32_process_target::read_pc)
128 (win32_process_target::write_pc): New methods.
129 * win32-i386-low.c (i386_win32_get_pc, i386_win32_set_pc): New
130 functions.
131 (the_low_target): Update.
132 * win32-arm-low.c (arm_win32_get_pc, arm_win32_set_pc): New
133 functions.
134 (the_low_target): Update.
135
136 2020-04-08 Tom Tromey <tromey@adacore.com>
137
138 * win32-low.c (win32_kill, get_child_debug_event): Use
139 wait_for_debug_event.
140
141 2020-04-08 Tom Tromey <tromey@adacore.com>
142
143 * win32-low.c (child_continue): Call continue_last_debug_event.
144
145 2020-04-08 Tom Tromey <tromey@adacore.com>
146
147 * win32-low.c (handle_exception): Remove.
148 (windows_nat::handle_ms_vc_exception): New function.
149 (get_child_debug_event): Add "continue_status" parameter.
150 Update.
151 (win32_wait): Update.
152
153 2020-04-08 Tom Tromey <tromey@adacore.com>
154
155 * win32-low.c (windows_nat::handle_load_dll): Rename from
156 handle_load_dll. No longer static.
157 (windows_nat::handle_unload_dll): Rename from handle_unload_dll.
158 No longer static.
159
160 2020-04-08 Tom Tromey <tromey@adacore.com>
161
162 * win32-low.c (handle_output_debug_string): Add parameter. Change
163 return type.
164 (win32_kill, get_child_debug_event): Update.
165
166 2020-04-08 Tom Tromey <tromey@adacore.com>
167
168 * win32-low.c (current_process_handle, current_process_id)
169 (main_thread_id, last_sig, current_event, siginfo_er): Move to
170 nat/windows-nat.c.
171
172 2020-04-08 Tom Tromey <tromey@adacore.com>
173
174 * win32-low.c (get_image_name): Remove.
175 (handle_load_dll): Update.
176
177 2020-04-08 Tom Tromey <tromey@adacore.com>
178
179 * win32-low.c (windows_nat::thread_rec): Rename from thread_rec.
180 No longer static. Change parameters.
181 (child_add_thread, child_fetch_inferior_registers)
182 (child_store_inferior_registers, win32_resume)
183 (win32_get_tib_address): Update.
184
185 2020-04-08 Tom Tromey <tromey@adacore.com>
186
187 * win32-low.h (struct win32_target_ops): Use qualified names where
188 needed.
189 * win32-i386-low.c: Add "using namespace".
190 * win32-low.c: Add "using namespace".
191 * win32-arm-low.c: Add "using namespace".
192
193 2020-04-08 Tom Tromey <tromey@adacore.com>
194
195 * win32-low.c (delete_thread_info): Don't call CloseHandle.
196
197 2020-04-08 Tom Tromey <tromey@adacore.com>
198
199 * win32-low.c (win32_require_context, suspend_one_thread): Use
200 windows_thread_info::suspend.
201 (continue_one_thread): Use windows_thread_info::resume.
202 * configure.srv (srv_tgtobj): Add windows-nat.o when needed.
203
204 2020-04-08 Tom Tromey <tromey@adacore.com>
205
206 * win32-i386-low.c (update_debug_registers)
207 (i386_prepare_to_resume, i386_thread_added): Update.
208
209 2020-04-08 Tom Tromey <tromey@adacore.com>
210
211 * win32-low.c (child_add_thread): Use new.
212 (delete_thread_info): Use delete.
213
214 2020-04-08 Tom Tromey <tromey@adacore.com>
215
216 * win32-low.h (struct windows_thread_info): Remove.
217
218 2020-04-08 Tom Tromey <tromey@adacore.com>
219
220 * win32-low.h (struct windows_thread_info): Rename from
221 win32_thread_info. Remove typedef.
222 (struct win32_target_ops, win32_require_context): Update.
223 * win32-low.c (win32_get_thread_context)
224 (win32_set_thread_context, win32_prepare_to_resume)
225 (win32_require_context, thread_rec, child_add_thread)
226 (delete_thread_info, continue_one_thread)
227 (child_fetch_inferior_registers, child_store_inferior_registers)
228 (win32_resume, suspend_one_thread, win32_get_tib_address):
229 Update.
230 * win32-i386-low.c (update_debug_registers)
231 (win32_get_current_dr, i386_get_thread_context)
232 (i386_prepare_to_resume, i386_thread_added, i386_single_step)
233 (i386_fetch_inferior_register, i386_store_inferior_register):
234 Update.
235 * win32-arm-low.c (arm_get_thread_context)
236 (arm_fetch_inferior_register, arm_store_inferior_register):
237 Update.
238
239 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
240
241 * linux-low.h (struct linux_target_ops): Remove.
242 (the_low_target): Remove.
243 * linux-x86-low.cc (the_low_target): Remove.
244 * linux-aarch64-low.cc (the_low_target): Ditto.
245 * linux-arm-low.cc (the_low_target): Ditto.
246 * linux-bfin-low.cc (the_low_target): Ditto.
247 * linux-cris-low.cc (the_low_target): Ditto.
248 * linux-crisv32-low.cc (the_low_target): Ditto.
249 * linux-ia64-low.cc (the_low_target): Ditto.
250 * linux-m32r-low.cc (the_low_target): Ditto.
251 * linux-m68k-low.cc (the_low_target): Ditto.
252 * linux-mips-low.cc (the_low_target): Ditto.
253 * linux-nios2-low.cc (the_low_target): Ditto.
254 * linux-ppc-low.cc (the_low_target): Ditto.
255 * linux-riscv-low.cc (the_low_target): Ditto.
256 * linux-s390-low.cc (the_low_target): Ditto.
257 * linux-sh-low.cc (the_low_target): Ditto.
258 * linux-sparc-low.cc (the_low_target): Ditto.
259 * linux-tic6x-low.cc (the_low_target): Ditto.
260 * linux-tile-low.cc (the_low_target): Ditto.
261 * linux-xtensa-low.cc (the_low_target): Ditto.
262
263 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
264
265 Remove the 'get_ipa_tdesc_idx' linux target op and let a concrete
266 linux target define the op by overriding the declaration in
267 process_stratum_target.
268
269 * linux-low.h (struct linux_target_ops): Remove the op.
270 (class linux_process_target) <get_ipa_tdesc_idx>: Remove.
271 * linux-low.cc (linux_process_target::get_ipa_tdesc_idx): Remove.
272 * linux-x86-low.cc (class x86_target) <get_ipa_tdesc_idx>: Declare.
273 (x86_get_ipa_tdesc_idx): Turn into...
274 (x86_target::get_ipa_tdesc_idx): ...this.
275 (the_low_target): Remove the op field.
276 * linux-ppc-low.cc (class ppc_target) <get_ipa_tdesc_idx>: Declare.
277 (ppc_get_ipa_tdesc_idx): Turn into...
278 (ppc_target::get_ipa_tdesc_idx): ...this.
279 (the_low_target): Remove the op field.
280 * linux-s390-low.cc (class s390_target) <get_ipa_tdesc_idx>: Declare.
281 (s390_get_ipa_tdesc_idx): Turn into...
282 (s390_target::get_ipa_tdesc_idx): ...this.
283 (the_low_target): Remove the op field.
284
285 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
286
287 Turn the 'get_syscall_trapinfo' linux target op into a method
288 of process_stratum_target.
289
290 * linux-low.h (struct linux_target_ops): Remove the op.
291 (class linux_process_target) <get_syscall_trapinfo>
292 <gdb_catch_this_syscall>
293 <low_supports_catch_syscall>
294 <low_get_syscall_trapinfo>: Declare.
295 * linux-low.cc (get_syscall_trapinfo): Turn into...
296 (linux_process_target::get_syscall_trapinfo): ...this.
297 (linux_process_target::low_get_syscall_trapinfo): Define.
298 (gdb_catch_this_syscall_p): Turn into...
299 (linux_process_target::gdb_catch_this_syscall): ...this.
300 (linux_process_target::low_supports_catch_syscall): Define.
301
302 Update the callers below.
303
304 (linux_process_target::wait_1)
305 (linux_process_target::supports_catch_syscall)
306
307 * linux-x86-low.cc (class x86_target) <low_supports_catch_syscall>
308 <low_get_syscall_trapinfo>: Declare.
309 (x86_target::low_supports_catch_syscall): Define.
310 (x86_get_syscall_trapinfo): Turn into...
311 (x86_target::low_get_syscall_trapinfo): ...this.
312 (the_low_target): Remove the op field.
313 * linux-aarch64-low.cc (class aarch64_target)
314 <low_supports_catch_syscall>
315 <low_get_syscall_trapinfo>: Declare.
316 (aarch64_target::low_supports_catch_syscall): Define.
317 (aarch64_get_syscall_trapinfo): Turn into...
318 (aarch64_target::low_get_syscall_trapinfo): ...this.
319 (the_low_target): Remove the op field.
320 * linux-arm-low.cc (class arm_target) <low_supports_catch_syscall>
321 <low_get_syscall_trapinfo>: Declare.
322 (arm_target::low_supports_catch_syscall): Define.
323 (arm_get_syscall_trapinfo): Turn into...
324 (arm_target::low_get_syscall_trapinfo): ...this.
325 (the_low_target): Remove the op field.
326 * linux-ppc-low.cc (the_low_target): Remove the op field.
327 * linux-s390-low.cc (the_low_target): Remove the op field.
328
329 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
330
331 Remove the 'supports_hardware_single_step' linux target op and
332 override the process_stratum_target's op definition in
333 linux_process_target to return true.
334
335 * linux-low.h (struct linux_target_ops): Remove the op.
336 (class linux_process_target) <finish_step_over>
337 <maybe_hw_step>: Declare.
338 * linux-low.cc (can_hardware_single_step): Remove.
339 (maybe_hw_step): Turn into...
340 (linux_process_target::maybe_hw_step): ...this.
341 (finish_step_over): Turn into...
342 (linux_process_target::finish_step_over): ...this.
343 (linux_process_target::supports_hardware_single_step): Update
344 to return true.
345
346 Update the callers below.
347
348 (linux_process_target::single_step)
349 (linux_process_target::resume_one_lwp_throw)
350
351 * linux-arm-low.cc (class arm_target)
352 <supports_hardware_single_step>: Declare.
353 (arm_supports_hardware_single_step): Turn into...
354 (arm_target::supports_hardware_single_step): ...this.
355 (the_low_target): Remove the op field.
356 * linux-x86-low.cc (x86_supports_hardware_single_step): Remove.
357 (the_low_target): Remove the op field.
358 * linux-aarch64-low.cc (aarch64_supports_hardware_single_step):
359 Remove.
360 (the_low_target): Remove the op field.
361 * linux-bfin-low.cc (bfin_supports_hardware_single_step): Remove.
362 (the_low_target): Remove the op field.
363 * linux-crisv32-low.cc (cris_supports_hardware_single_step): Remove.
364 (the_low_target): Remove the op field.
365 * linux-m32r-low.cc (m32r_supports_hardware_single_step): Remove.
366 (the_low_target): Remove the op field.
367 * linux-m68k-low.cc (m68k_supports_hardware_single_step): Remove.
368 (the_low_target): Remove the op field.
369 * linux-ppc-low.cc (ppc_supports_hardware_single_step): Remove.
370 (the_low_target): Remove the op field.
371 * linux-s390-low.cc (s390_supports_hardware_single_step): Remove.
372 (the_low_target): Remove the op field.
373 * linux-sh-low.cc (sh_supports_hardware_single_step): Remove.
374 (the_low_target): Remove the op field.
375 * linux-tic6x-low.cc (tic6x_supports_hardware_single_step): Remove.
376 (the_low_target): Remove the op field.
377 * linux-tile-low.cc (tile_supports_hardware_single_step): Remove.
378 (the_low_target): Remove the op field.
379 * linux-xtensa-low.cc (xtensa_supports_hardware_single_step):
380 Remove.
381 (the_low_target): Remove the op field.
382
383 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
384
385 Turn the 'supports_range_stepping' linux target op into a method
386 of linux_process_target.
387
388 * linux-low.h (struct linux_target_ops): Remove the op.
389 (class linux_process_target) <low_supports_range_stepping>: Declare.
390 * linux-low.cc (linux_process_target::low_supports_range_stepping):
391 Define.
392 (linux_process_target::supports_range_stepping): Update the call
393 site.
394 * linux-x86-low.cc (class x86_target)
395 <low_supports_range_stepping>: Declare.
396 (x86_supports_range_stepping): Turn into...
397 (x86_target::low_supports_range_stepping): ...this.
398 (the_low_target): Remove the op field.
399 * linux-aarch64-low.cc (class aarch64_target)
400 <low_supports_range_stepping>: Declare.
401 (aarch64_supports_range_stepping): Turn into...
402 (aarch64_target::low_supports_range_stepping): ...this.
403 (the_low_target): Remove the op field.
404 * linux-arm-low.cc (the_low_target): Remove the op field.
405 * linux-bfin-low.cc (the_low_target): Ditto.
406 * linux-crisv32-low.cc (the_low_target): Ditto.
407 * linux-m32r-low.cc (the_low_target): Ditto.
408 * linux-m68k-low.cc (the_low_target): Ditto.
409 * linux-ppc-low.cc (the_low_target): Ditto.
410 * linux-s390-low.cc (the_low_target): Ditto.
411 * linux-sh-low.cc (the_low_target): Ditto.
412 * linux-tic6x-low.cc (the_low_target): Ditto.
413 * linux-tile-low.cc (the_low_target): Ditto.
414 * linux-xtensa-low.cc (the_low_target): Ditto.
415
416 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
417
418 Remove the 'emit_ops' linux target ops and let the concrete
419 linux target define the op by overriding the declaration of
420 process_stratum_target.
421
422 * linux-low.h (struct linux_target_ops): Remove the op.
423 (class linux_process_target) <emit_ops>: Remove.
424 * linux-low.cc (linux_process_target::emit_ops): Remove.
425 * linux-x86-low.cc (class x86_target) <emit_ops>: Declare.
426 (x86_emit_ops): Turn into...
427 (x86_target::emit_ops): ...this.
428 (the_low_target): Remove the op field.
429 * linux-aarch64-low.cc (class aarch64_target) <emit_ops>: Declare.
430 (aarch64_emit_ops): Turn into...
431 (aarch64_target::emit_ops): ...this.
432 (the_low_target): Remove the op field.
433 * linux-ppc-low.cc (class ppc_target) <emit_ops>: Declare.
434 (ppc_emit_ops): Turn into...
435 (ppc_target::emit_ops): ...this.
436 (the_low_target): Remove the op field.
437 * linux-s390-low.cc (class s390_target) <emit_ops>: Declare.
438 (s390_emit_ops): Turn into...
439 (s390_target::emit_ops): ...this.
440 (the_low_target): Remove the op field.
441 * linux-arm-low.cc (the_low_target): Remove the op field.
442 * linux-bfin-low.cc (the_low_target): Ditto.
443 * linux-crisv32-low.cc (the_low_target): Ditto.
444 * linux-m32r-low.cc (the_low_target): Ditto.
445 * linux-m68k-low.cc (the_low_target): Ditto.
446 * linux-sh-low.cc (the_low_target): Ditto.
447 * linux-tic6x-low.cc (the_low_target): Ditto.
448 * linux-tile-low.cc (the_low_target): Ditto.
449 * linux-xtensa-low.cc (the_low_target): Ditto.
450
451 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
452
453 Remove the 'install_fast_tracepoint_jump_pad' and
454 'get_min_fast_tracepoint_insn_len' linux target ops to let the
455 concrete linux target define the ops by overriding the declarations
456 of process_stratum_target.
457
458 * linux-low.h (struct linux_target_ops): Remove the ops.
459 (class linux_process_target) <supports_fast_tracepoints>
460 <install_fast_tracepoint_jump_pad>
461 <get_min_fast_tracepoint_insn_len>: Remove.
462 * linux-low.cc (linux_process_target::supports_fast_tracepoints)
463 (linux_process_target::install_fast_tracepoint_jump_pad)
464 (linux_process_target::get_min_fast_tracepoint_insn_len): Remove.
465 * linux-x86-low.cc (class x86_target) <supports_fast_tracepoints>
466 <install_fast_tracepoint_jump_pad>
467 <get_min_fast_tracepoint_insn_len>: Declare.
468 (x86_target::supports_fast_tracepoints): Define.
469 (x86_install_fast_tracepoint_jump_pad): Turn into...
470 (x86_target::install_fast_tracepoint_jump_pad): ...this.
471 (x86_get_min_fast_tracepoint_insn_len): Turn into...
472 (x86_target::get_min_fast_tracepoint_insn_len): ...this.
473 (the_low_target): Remove the op fields.
474 * linux-aarch64-low.cc (class aarch64_target)
475 <supports_fast_tracepoints>
476 <install_fast_tracepoint_jump_pad>
477 <get_min_fast_tracepoint_insn_len>: Declare.
478 (aarch64_target::supports_fast_tracepoints): Define.
479 (aarch64_install_fast_tracepoint_jump_pad): Turn into...
480 (aarch64_target::install_fast_tracepoint_jump_pad): ...this.
481 (aarch64_get_min_fast_tracepoint_insn_len): Turn into...
482 (aarch64_target::get_min_fast_tracepoint_insn_len): ...this.
483 (the_low_target): Remove the op fields.
484 * linux-ppc-low.cc (class ppc_target) <supports_fast_tracepoints>
485 <install_fast_tracepoint_jump_pad>
486 <get_min_fast_tracepoint_insn_len>: Declare.
487 (ppc_target::supports_fast_tracepoints): Define.
488 (ppc_install_fast_tracepoint_jump_pad): Turn into...
489 (ppc_target::install_fast_tracepoint_jump_pad): ...this.
490 (ppc_get_min_fast_tracepoint_insn_len): Turn into...
491 (ppc_target::get_min_fast_tracepoint_insn_len): ...this.
492 (the_low_target): Remove the op fields.
493 * linux-s390-low.cc (class s390_target) <supports_fast_tracepoints>
494 <install_fast_tracepoint_jump_pad>
495 <get_min_fast_tracepoint_insn_len>: Declare.
496 (s390_target::supports_fast_tracepoints): Define.
497 (s390_install_fast_tracepoint_jump_pad): Turn into...
498 (s390_target::install_fast_tracepoint_jump_pad): ...this.
499 (s390_get_min_fast_tracepoint_insn_len): Turn into...
500 (s390_target::get_min_fast_tracepoint_insn_len): ...this.
501 (the_low_target): Remove the op fields.
502 * linux-arm-low.cc (the_low_target): Remove the op fields.
503 * linux-bfin-low.cc (the_low_target): Ditto.
504 * linux-crisv32-low.cc (the_low_target): Ditto.
505 * linux-m32r-low.cc (the_low_target): Ditto.
506 * linux-m68k-low.cc (the_low_target): Ditto.
507 * linux-sh-low.cc (the_low_target): Ditto.
508 * linux-tic6x-low.cc (the_low_target): Ditto.
509 * linux-tile-low.cc (the_low_target): Ditto.
510 * linux-xtensa-low.cc (the_low_target): Ditto.
511
512 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
513
514 Turn the 'get_thread_area' linux target op into a method of
515 process_stratum_target.
516
517 * linux-low.h (struct linux_target_ops): Remove the op.
518 (class linux_process_target) <stuck_in_jump_pad>
519 <linux_fast_tracepoint_collecting>
520 <low_get_thread_area>: Declare.
521 * linux-low.cc (supports_fast_tracepoints): Remove.
522 (linux_fast_tracepoint_collecting): Turn into...
523 (linux_process_target::linux_fast_tracepoint_collecting): ...this.
524 (linux_process_target::low_get_thread_area): Define.
525 (stuck_in_jump_pad_callback): Turn into...
526 (linux_process_target::stuck_in_jump_pad): ...this.
527
528 Update the caller below.
529
530 (linux_process_target::stabilize_threads)
531
532 * linux-x86-low.cc (class x86_target) <low_get_thread_area>:
533 Declare.
534 (x86_get_thread_area): Turn into...
535 (x86_target::low_get_thread_area): ...this.
536 (the_low_target): Remove the op field.
537 * linux-aarch64-low.cc (class aarch64_target) <low_get_thread_area>:
538 Declare.
539 (aarch64_get_thread_area): Turn into...
540 (aarch64_target::low_get_thread_area): ...this.
541 (the_low_target): Remove the op field.
542 * linux-ppc-low.cc (class ppc_target) <low_get_thread_area>:
543 Declare.
544 (ppc_get_thread_area): Turn into...
545 (ppc_target::low_get_thread_area): ...this.
546 (the_low_target): Remove the op field.
547 * linux-s390-low.cc (class s390_target) <low_get_thread_area>:
548 Declare.
549 (s390_get_thread_area): Turn into...
550 (s390_target::low_get_thread_area): ...this.
551 (the_low_target): Remove the op field.
552 * linux-arm-low.cc (the_low_target): Remove the op field.
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
562 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
563
564 Remote the 'supports_tracepoints' linux target op and let the
565 concrete linux target define it by overriding the op declared in
566 process_stratum_target.
567
568 * linux-low.h (struct linux_target_ops): Remove the op.
569 (class linux_process_target) <supports_tracepoints>: Remove.
570 * linux-low.cc (linux_process_target::supports_tracepoints): Remove.
571 * linux-x86-low.cc (class x86_target) <supports_tracepoints>:
572 Declare.
573 (x86_supports_tracepoints): Turn into...
574 (x86_target::supports_tracepoints): ...this.
575 (the_low_target): Remove the op field.
576 * linux-aarch64-low.cc (class aarch64_target)
577 <supports_tracepoints>: Declare.
578 (aarch64_supports_tracepoints): Turn into...
579 (aarch64_target::supports_tracepoints): ...this.
580 (the_low_target): Remove the op field.
581 * linux-ppc-low.cc (class ppc_target) <supports_tracepoints>:
582 Declare.
583 (ppc_supports_tracepoints): Turn into...
584 (ppc_target::supports_tracepoints): ...this.
585 (the_low_target): Remove the op field.
586 * linux-s390-low.cc (class s390_target) <supports_tracepoints>:
587 Declare.
588 (s390_supports_tracepoints): Turn into...
589 (s390_target::supports_tracepoints): ...this.
590 (the_low_target): Remove the op field.
591 * linux-arm-low.cc (the_low_target): Remove the op field.
592 * linux-bfin-low.cc (the_low_target): Ditto.
593 * linux-crisv32-low.cc (the_low_target): Ditto.
594 * linux-m32r-low.cc (the_low_target): Ditto.
595 * linux-m68k-low.cc (the_low_target): Ditto.
596 * linux-sh-low.cc (the_low_target): Ditto.
597 * linux-tic6x-low.cc (the_low_target): Ditto.
598 * linux-tile-low.cc (the_low_target): Ditto.
599 * linux-xtensa-low.cc (the_low_target): Ditto.
600
601 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
602
603 Remove the 'process_qsupported' linux target op and let a concrete
604 linux target define the op by overriding the op declaration in
605 process_stratum_target.
606
607 * linux-low.h (struct linux_target_ops): Remove the op.
608 (class linux_process_target) <process_qsupported>: Remove.
609 * linux-low.cc (linux_process_target::process_qsupported): Remove.
610 * linux-x86-low.cc (class x86_target) <process_qsupported>: Declare.
611 (x86_linux_process_qsupported): Turn into...
612 (x86_target::process_qsupported): ...this.
613 (the_low_target): Remove the op field.
614 * linux-aarch64-low.cc (the_low_target): Remove the op
615 field.
616 * linux-arm-low.cc (the_low_target): Ditto.
617 * linux-bfin-low.cc (the_low_target): Ditto.
618 * linux-crisv32-low.cc (the_low_target): Ditto.
619 * linux-m32r-low.cc (the_low_target): Ditto.
620 * linux-m68k-low.cc (the_low_target): Ditto.
621 * linux-ppc-low.cc (the_low_target): Ditto.
622 * linux-s390-low.cc (the_low_target): Ditto.
623 * linux-sh-low.cc (the_low_target): Ditto.
624 * linux-tic6x-low.cc (the_low_target): Ditto.
625 * linux-tile-low.cc (the_low_target): Ditto.
626 * linux-xtensa-low.cc (the_low_target): Ditto.
627
628 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
629
630 Turn the 'prepare_to_resume' linux target op into a method of
631 linux_process_target.
632
633 * linux-low.h (struct linux_target_ops): Remove the op.
634 (class linux_process_target) <low_prepare_to_resume>: Declare.
635 * linux-low.cc (linux_process_target::low_prepare_to_resume):
636 Define.
637
638 Update the callers below:
639
640 (linux_process_target::resume_one_lwp_throw)
641 (linux_process_target::low_prepare_to_resume)
642
643 * linux-x86-low.cc (class x86_target) <low_prepare_to_resume>:
644 Declare.
645 (x86_target::low_prepare_to_resume): Define.
646 (the_low_target): Remove the op field.
647 * linux-aarch64-low.cc (class aarch64_target)
648 <low_prepare_to_resume>: Declare.
649 (aarch64_target::low_prepare_to_resume): Define.
650 (the_low_target): Remove the op field.
651 * linux-arm-low.cc (class arm_target) <low_prepare_to_resume>:
652 Declare.
653 (arm_prepare_to_resume): Turn into...
654 (arm_target::low_prepare_to_resume): ...this.
655 (the_low_target): Remove the op field.
656 * linux-mips-low.cc (class mips_target) <low_prepare_to_resume>:
657 Declare.
658 (mips_linux_prepare_to_resume): Turn into...
659 (mips_target::low_prepare_to_resume): ...this.
660 (the_low_target): Remove the op field.
661 * linux-bfin-low.cc (the_low_target): Remove the op field.
662 * linux-crisv32-low.cc (the_low_target): Ditto.
663 * linux-m32r-low.cc (the_low_target): Ditto.
664 * linux-m68k-low.cc (the_low_target): Ditto.
665 * linux-ppc-low.cc (the_low_target): Ditto.
666 * linux-s390-low.cc (the_low_target): Ditto.
667 * linux-sh-low.cc (the_low_target): Ditto.
668 * linux-tic6x-low.cc (the_low_target): Ditto.
669 * linux-tile-low.cc (the_low_target): Ditto.
670 * linux-xtensa-low.cc (the_low_target): Ditto.
671
672 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
673
674 Turn the 'new_process', 'delete_process', 'new_thread',
675 'delete_thread', and 'new_fork' linux target ops into methods
676 of linux_process_target.
677
678 * linux-low.h (struct linux_target_ops): Remove the ops.
679 (class linux_process_target) <add_linux_process>
680 <add_lwp>
681 <delete_lwp>
682 <attach_lwp>
683 <detach_one_lwp>
684 <check_zombie_leaders>
685 <filter_exit_event>
686 <low_new_process>
687 <low_delete_process>
688 <low_new_thread>
689 <low_delete_thread>
690 <low_new_fork>: Declare.
691 * linux-low.cc (delete_lwp): Turn into...
692 (linux_process_target::delete_lwp): ...this.
693 (linux_process_target::low_delete_thread): Define.
694 (linux_add_process): Turn into...
695 (linux_process_target::add_linux_process): ...this.
696 (linux_process_target::low_new_process): Define.
697 (linux_process_target::low_delete_process): Define.
698 (linux_process_target::low_new_fork): Define.
699 (add_lwp): Turn into...
700 (linux_process_target::add_lwp): ...this.
701 (linux_process_target::low_new_thread): Define.
702 (linux_attach_lwp): Turn into...
703 (linux_process_target::attach_lwp): ...this.
704 (linux_detach_one_lwp): Turn into...
705 (linux_process_target::detach_one_lwp): ...this.
706 (linux_detach_lwp_callback): Remove and inline...
707 (linux_process_target::detach): ...here.
708 (check_zombie_leaders): Turn into...
709 (linux_process_target::check_zombie_leaders): ...this.
710 (filter_exit_event): Turn into...
711 (linux_process_target::filter_exit_event): ...this.
712
713 Update the callers below.
714
715 (linux_process_target::handle_extended_wait)
716 (linux_process_target::create_inferior)
717 (attach_proc_task_lwp_callback)
718 (linux_process_target::attach)
719 (linux_process_target::detach)
720 (linux_process_target::mourn)
721 * thread-db.cc (attach_thread)
722
723 * linux-x86-low.cc (class x86_target) <low_new_process>
724 <low_delete_process>
725 <low_new_thread>
726 <low_delete_thread>
727 <low_new_fork>: Declare.
728 (x86_linux_new_process): Turn into...
729 (x86_target::low_new_process): ...this.
730 (x86_linux_delete_process): Turn into...
731 (x86_target::low_delete_process): ...this.
732 (x86_target::low_new_thread): Define.
733 (x86_target::low_delete_thread): Define.
734 (x86_linux_new_fork): Turn into...
735 (x86_target::low_new_fork): ...this.
736 (the_low_target): Remove the op fields.
737 * linux-aarch64-low.cc (class aarch64_target) <low_new_process>
738 <low_delete_process>
739 <low_new_thread>
740 <low_delete_thread>
741 <low_new_fork>: Declare.
742 (aarch64_linux_new_process): Turn into...
743 (aarch64_target::low_new_process): ...this.
744 (aarch64_linux_delete_process): Turn into...
745 (aarch64_target::low_delete_process): ...this.
746 (aarch64_target::low_new_thread): Define.
747 (aarch64_target::low_delete_thread): Define.
748 (aarch64_linux_new_fork): Turn into...
749 (aarch64_target::low_new_fork): ...this.
750 (the_low_target): Remove the op fields.
751 * linux-arm-low.cc (class arm_target) <low_new_process>
752 <low_delete_process>
753 <low_new_thread>
754 <low_delete_thread>
755 <low_new_fork>: Declare.
756 (arm_new_process): Turn into...
757 (arm_target::low_new_process): ...this.
758 (arm_delete_process): Turn into...
759 (arm_target::low_delete_process): ...this.
760 (arm_new_thread): Turn into...
761 (arm_target::low_new_thread): ...this.
762 (arm_delete_thread): Turn into...
763 (arm_target::low_delete_thread): ...this.
764 (arm_new_fork): Turn into...
765 (arm_target::low_new_fork): ...this.
766 (the_low_target): Remove the op fields.
767 * linux-mips-low.cc (class mips_target) <low_new_process>
768 <low_delete_process>
769 <low_new_thread>
770 <low_delete_thread>
771 <low_new_fork>: Declare.
772 (mips_linux_new_process): Turn into...
773 (mips_target::low_new_process): ...this.
774 (mips_linux_delete_process): Turn into...
775 (mips_target::low_delete_process): ...this.
776 (mips_linux_new_thread): Turn into...
777 (mips_target::low_new_thread): ...this.
778 (mips_linux_delete_thread): Turn into...
779 (mips_target::low_delete_thread): ...this.
780 (mips_linux_new_fork): Turn into...
781 (mips_target::low_new_fork): ...this.
782 (the_low_target): Remove the op fields.
783 * linux-bfin-low.cc (the_low_target): Remove the op fields.
784 * linux-crisv32-low.cc (the_low_target): Ditto.
785 * linux-m32r-low.cc (the_low_target): Ditto.
786 * linux-m68k-low.cc (the_low_target): Ditto.
787 * linux-ppc-low.cc (the_low_target): Ditto.
788 * linux-s390-low.cc (the_low_target): Ditto.
789 * linux-sh-low.cc (the_low_target): Ditto.
790 * linux-tic6x-low.cc (the_low_target): Ditto.
791 * linux-tile-low.cc (the_low_target): Ditto.
792 * linux-xtensa-low.cc (the_low_target): Ditto.
793
794 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
795
796 Turn the 'siginfo_fixup' linux target op into a method of
797 linux_process_target.
798
799 * linux-low.h (struct linux_target_ops): Remove the op.
800 (class linux_process_target) <siginfo_fixup>
801 <low_siginfo_fixup>: Declare.
802 * linux-low.cc (siginfo_fixup): Turn into...
803 (linux_process_target::siginfo_fixup): ...this.
804 (linux_process_target::low_siginfo_fixup): Define.
805 * linux-x86-low.cc (class x86_target) <low_siginfo_fixup>: Declare.
806 (x86_siginfo_fixup): Turn into...
807 (x86_target::low_siginfo_fixup): ...this.
808 (the_low_target): Remove the op field.
809 * linux-aarch64-low.cc (class aarch64_target):
810 <low_siginfo_fixup>: Declare.
811 (aarch64_linux_siginfo_fixup): Turn into...
812 (aarch64_target::low_siginfo_fixup): ...this.
813 (the_low_target): Remove the op field.
814 * linux-arm-low.cc (the_low_target): Remove the op field.
815 * linux-bfin-low.cc (the_low_target): Ditto.
816 * linux-crisv32-low.cc (the_low_target): Ditto.
817 * linux-m32r-low.cc (the_low_target): Ditto.
818 * linux-m68k-low.cc (the_low_target): Ditto.
819 * linux-mips-low.cc (the_low_target): Ditto.
820 * linux-ppc-low.cc (the_low_target): Ditto.
821 * linux-s390-low.cc (the_low_target): Ditto.
822 * linux-sh-low.cc (the_low_target): Ditto.
823 * linux-tic6x-low.cc (the_low_target): Ditto.
824 * linux-tile-low.cc (the_low_target): Ditto.
825 * linux-xtensa-low.cc (the_low_target): Ditto.
826
827 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
828
829 Turn the 'collect_ptrace_register' and 'supply_ptrace_register'
830 linux target ops into methods of linux_process_target.
831
832 * linux-low.h (struct linux_target_ops): Remove the ops.
833 (class linux_process_target) <low_collect_ptrace_register>
834 <low_store_ptrace_register>: Declare.
835 * linux-low.cc (linux_process_target::low_collect_ptrace_register)
836 (linux_process_target::low_supply_ptrace_register): Define.
837
838 Update the callers below.
839
840 (linux_process_target::fetch_register)
841 (linux_process_target::store_register)
842
843 * linux-x86-low.cc (the_low_target): Remove the op fields.
844 * linux-aarch64-low.cc (the_low_target): Ditto.
845 * linux-arm-low.cc (the_low_target): Ditto.
846 * linux-bfin-low.cc (the_low_target): Ditto.
847 * linux-crisv32-low.cc (the_low_target): Ditto.
848 * linux-m32r-low.cc (the_low_target): Ditto.
849 * linux-m68k-low.cc (the_low_target): Ditto.
850 * linux-sh-low.cc (the_low_target): Ditto.
851 * linux-sparc-low.cc (the_low_target): Ditto.
852 * linux-tic6x-low.cc (the_low_target): Ditto.
853 * linux-tile-low.cc (the_low_target): Ditto.
854 * linux-xtensa-low.cc (the_low_target): Ditto.
855 * linux-mips-low.cc (class mips_target)
856 <low_collect_ptrace_register>
857 <low_supply_ptrace_register>: Declare.
858 (mips_collect_ptrace_register): Turn into ...
859 (mips_target::low_collect_ptrace_register): ...this.
860 (mips_supply_ptrace_register): Turn into...
861 (mips_target::low_supply_ptrace_register): ...this.
862 (the_low_target): Remove the op fields.
863 * linux-ppc-low.cc (class ppc_target)
864 <low_collect_ptrace_register>
865 <low_supply_ptrace_register>: Declare.
866 (ppc_collect_ptrace_register): Turn into ...
867 (ppc_target::low_collect_ptrace_register): ...this.
868 (ppc_supply_ptrace_register): Turn into ...
869 (ppc_target::low_supply_ptrace_register): ...this.
870 (ppc_fill_gregset): Update for the calls to
871 low_collect_ptrace_register.
872 (the_low_target): Remove the op fields.
873 * linux-s390-low.cc (class s390_target)
874 <low_collect_ptrace_register>
875 <low_supply_ptrace_register>: Declare.
876 (s390_collect_ptrace_register): Turn into ...
877 (s390_target::low_collect_ptrace_register): ...this.
878 (s390_supply_ptrace_register): Turn into ...
879 (s390_target::low_supply_ptrace_register): ...this.
880 (s390_fill_gregset): Update for the calls to
881 low_collect_ptrace_register.
882 (the_low_target): Remove the op fields.
883
884 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
885
886 Turn the 'stopped_by_watchpoint' and 'stopped_data_address' linux
887 target ops into methods of linux_process_target.
888
889 * linux-low.h (struct linux_target_ops): Remove the ops.
890 (class linux_process_target) <check_stopped_by_watchpoint>
891 <low_stopped_by_watchpoint>
892 <low_stopped_data_address>: Declare.
893 * linux-low.cc (check_stopped_by_watchpoint): Turn into...
894 (linux_process_target::check_stopped_by_watchpoint): ...this.
895 (linux_process_target::low_stopped_by_watchpoint): Define.
896 (linux_process_target::low_stopped_data_address): Define.
897 * linux-x86-low.cc (class x86_target) <low_stopped_by_watchpoint>
898 <low_stopped_data_address>: Declare.
899 (x86_stopped_by_watchpoint): Turn into...
900 (x86_target::low_stopped_by_watchpoint): ...this.
901 (x86_stopped_data_address): Turn into...
902 (x86_target::low_stopped_data_address): ...this.
903 (the_low_target): Remove the op fields.
904 * linux-aarch64-low.cc (class aarch64_target)
905 <low_stopped_by_watchpoint>
906 <low_stopped_data_address>: Declare.
907 (aarch64_stopped_by_watchpoint): Turn into...
908 (aarch64_target::low_stopped_by_watchpoint): ...this.
909 (aarch64_stopped_data_address): Turn into...
910 (aarch64_target::low_stopped_data_address): ...this.
911 (the_low_target): Remove the op fields.
912 * linux-arm-low.cc (class arm_target) <low_stopped_by_watchpoint>
913 <low_stopped_data_address>: Declare.
914 (arm_stopped_by_watchpoint): Turn into...
915 (arm_target::low_stopped_by_watchpoint): ...this.
916 (arm_stopped_data_address): Turn into...
917 (arm_target::low_stopped_data_address): ...this.
918 (the_low_target): Remove the op fields.
919 * linux-crisv32-low.cc (class crisv32_target)
920 <low_stopped_by_watchpoint>
921 <low_stopped_data_address>: Declare.
922 (cris_stopped_by_watchpoint): Turn into...
923 (crisv32_target::low_stopped_by_watchpoint): ...this.
924 (cris_stopped_data_address): Turn into...
925 (crisv32_target::low_stopped_data_address): ...this.
926 (the_low_target): Remove the op fields.
927 * linux-mips-low.cc (class mips_target) <low_stopped_by_watchpoint>
928 <low_stopped_data_address>: Declare.
929 (mips_stopped_by_watchpoint): Turn into...
930 (mips_target::low_stopped_by_watchpoint): ...this.
931 (mips_stopped_data_address): Turn into...
932 (mips_target::low_stopped_data_address): ...this.
933 (the_low_target): Remove the op fields.
934 * linux-bfin-low.cc (the_low_target): Remove the op fields.
935 * linux-m32r-low.cc (the_low_target): Ditto.
936 * linux-m68k-low.cc (the_low_target): Ditto.
937 * linux-ppc-low.cc (the_low_target): Ditto.
938 * linux-s390-low.cc (the_low_target): Ditto.
939 * linux-sh-low.cc (the_low_target): Ditto.
940 * linux-sparc-low.cc (the_low_target): Ditto.
941 * linux-tic6x-low.cc (the_low_target): Ditto.
942 * linux-tile-low.cc (the_low_target): Ditto.
943 * linux-xtensa-low.cc (the_low_target): Ditto.
944
945 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
946
947 Turn the 'insert_point' and 'remove_point' linux target ops into
948 methods of linux_process_target.
949
950 * linux-low.h (struct linux_target_ops): Remove the ops.
951 (class linux_process_target) <low_insert_point>
952 <low_remove_point>: Declare.
953 * linux-low.cc (linux_process_target::low_insert_point)
954 (linux_process_target::low_remove_point): Define.
955 (linux_process_target::insert_point)
956 (linux_process_target::remove_point): Update for calls to
957 low_insert_point and low_remove_point.
958 * linux-x86-low.cc (class x86_target) <low_insert_point>
959 <low_remove_point>: Declare.
960 (x86_insert_point): Turn into...
961 (x86_target::low_insert_point): ...this.
962 (x86_remove_point): Turn into...
963 (x86_target::low_remove_point): ...this.
964 (the_low_target): Remove the op fields.
965 * linux-aarch64-low.cc (class aarch64_target) <low_insert_point>
966 <low_remove_point>: Declare.
967 (aarch64_insert_point): Turn into...
968 (aarch64_target::low_insert_point): ...this.
969 (aarch64_remove_point): Turn into...
970 (aarch64_target::low_remove_point): ...this.
971 (the_low_target): Remove the op fields.
972 * linux-arm-low.cc (class arm_target) <low_insert_point>
973 <low_remove_point>: Declare.
974 (arm_insert_point): Turn into...
975 (arm_target::low_insert_point): ...this.
976 (arm_remove_point): Turn into...
977 (arm_target::low_remove_point): ...this.
978 (the_low_target): Remove the op fields.
979 * linux-crisv32-low.cc (class crisv32_target) <low_insert_point>
980 <low_remove_point>: Declare.
981 (crisv32_insert_point): Turn into...
982 (crisv32_target::low_insert_point): ...this.
983 (crisv32_remove_point): Turn into...
984 (crisv32_target::low_remove_point): ...this.
985 (the_low_target): Remove the op fields.
986 * linux-mips-low.cc (class mips_target) <low_insert_point>
987 <low_remove_point>: Declare.
988 (mips_insert_point): Turn into...
989 (mips_target::low_insert_point): ...this.
990 (mips_remove_point): Turn into...
991 (mips_target::low_remove_point): ...this.
992 (the_low_target): Remove the op fields.
993 * linux-ppc-low.cc (class ppc_target) <low_insert_point>
994 <low_remove_point>: Declare.
995 (ppc_insert_point): Turn into...
996 (ppc_target::low_insert_point): ...this.
997 (ppc_remove_point): Turn into...
998 (ppc_target::low_remove_point): ...this.
999 (the_low_target): Remove the op fields.
1000 * linux-bfin-low.cc (the_low_target): Remove the op fields.
1001 * linux-m32r-low.cc (the_low_target): Ditto.
1002 * linux-m68k-low.cc (the_low_target): Ditto.
1003 * linux-s390-low.cc (the_low_target): Ditto.
1004 * linux-sh-low.cc (the_low_target): Ditto.
1005 * linux-sparc-low.cc (the_low_target): Ditto.
1006 * linux-tic6x-low.cc (the_low_target): Ditto.
1007 * linux-tile-low.cc (the_low_target): Ditto.
1008 * linux-xtensa-low.cc (the_low_target): Ditto.
1009
1010 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1011
1012 Remove the 'supports_z_point_type' linux target op and let the
1013 concrete linux target define it by overriding the op declared in
1014 process_stratum_target.
1015
1016 * linux-low.cc (linux_process_target::supports_z_point_type):
1017 Remove.
1018 * linux-low.h (struct linux_target_ops): Remove the op.
1019 (class linux_process_target) <supports_z_point_type>: Remove.
1020 * linux-x86-low.cc (class x86_target) <supports_z_point_type>:
1021 Declare.
1022 (x86_supports_z_point_type): Turn into...
1023 (x86_target::supports_z_point_type): ...this.
1024 (the_low_target): Remove the op field.
1025 * linux-aarch64-low.cc (class aarch64_target)
1026 <supports_z_point_type>: Declare.
1027 (aarch64_supports_z_point_type): Turn into...
1028 (aarch64_target::supports_z_point_type): ...this.
1029 (the_low_target): Remove the op field.
1030 * linux-arm-low.cc (class arm_target) <supports_z_point_type>:
1031 Declare.
1032 (arm_supports_z_point_type): Turn into...
1033 (arm_target::supports_z_point_type): ...this.
1034 (the_low_target): Remove the op field.
1035 * linux-crisv32-low.cc (class crisv32_target)
1036 <supports_z_point_type>: Declare.
1037 (cris_supports_z_point_type): Turn into...
1038 (crisv32_target::supports_z_point_type): ...this.
1039 (the_low_target): Remove the op field.
1040 * linux-mips-low.cc (class mips_target) <supports_z_point_type>:
1041 Declare.
1042 (mips_supports_z_point_type): Turn into...
1043 (mips_target::supports_z_point_type): ...this.
1044 (the_low_target): Remove the op field.
1045 * linux-ppc-low.cc (class ppc_target) <supports_z_point_type>:
1046 Declare.
1047 (ppc_supports_z_point_type): Turn into...
1048 (ppc_target::supports_z_point_type): ...this.
1049 (the_low_target): Remove the op field.
1050 * linux-s390-low.cc (class s390_target) <supports_z_point_type>:
1051 Declare.
1052 (s390_supports_z_point_type): Turn into...
1053 (s390_target::supports_z_point_type): ...this.
1054 (the_low_target): Remove the op field.
1055 * linux-bfin-low.cc (the_low_target): Remove the op field.
1056 * linux-m32r-low.cc (the_low_target): Ditto.
1057 * linux-m68k-low.cc (the_low_target): Ditto.
1058 * linux-sh-low.cc (the_low_target): Ditto.
1059 * linux-sparc-low.cc (the_low_target): Ditto.
1060 * linux-tic6x-low.cc (the_low_target): Ditto.
1061 * linux-tile-low.cc (the_low_target): Ditto.
1062 * linux-xtensa-low.cc (the_low_target): Ditto.
1063
1064 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1065
1066 Turn the 'breakpoint_at' linux target op into a method of
1067 linux_process_target.
1068
1069 * linux-low.h (struct linux_target_ops): Remove the op.
1070 (class linux_process_target) <low_breakpoint_at>: Declare.
1071
1072 Update the callers below:
1073
1074 * linux-low.cc (linux_process_target::save_stop_reason)
1075 (linux_process_target::thread_still_has_status_pending)
1076 (linux_process_target::wait_1)
1077
1078 * linux-x86-low.cc (class x86_target)
1079 <low_breakpoint_at>: Declare.
1080 (x86_breakpoint_at): Turn into...
1081 (x86_target::low_breakpoint_at): ...this.
1082 (the_low_target): Remove the op field.
1083 * linux-aarch64-low.cc (class aarch64_target)
1084 <low_breakpoint_at>: Declare.
1085 (aarch64_breakpoint_at): Turn into...
1086 (aarch64_target::low_breakpoint_at): ...this.
1087 (the_low_target): Remove the op field.
1088 * linux-arm-low.cc (class arm_target)
1089 <low_breakpoint_at>: Declare.
1090 (arm_target::low_breakpoint_at): Define.
1091 (the_low_target): Remove the op field.
1092 * linux-bfin-low.cc (class bfin_target)
1093 <low_breakpoint_at>: Declare.
1094 (bfin_breakpoint_at): Turn into...
1095 (bfin_target::low_breakpoint_at): ...this.
1096 (the_low_target): Remove the op field.
1097 * linux-cris-low.cc (class cris_target)
1098 <low_breakpoint_at>: Declare.
1099 (cris_breakpoint_at): Turn into...
1100 (cris_target::low_breakpoint_at): ...this.
1101 (the_low_target): Remove the op field.
1102 * linux-crisv32-low.cc (class crisv32_target)
1103 <low_breakpoint_at>: Declare.
1104 (crisv32_breakpoint_at): Turn into...
1105 (crisv32_target::low_breakpoint_at): ...this.
1106 (the_low_target): Remove the op field.
1107 * linux-ia64-low.cc (class ia64_target)
1108 <low_breakpoint_at>: Declare.
1109 (ia64_target::low_breakpoint_at): Define.
1110 * linux-m32r-low.cc (class m32r_target)
1111 <low_breakpoint_at>: Declare.
1112 (m32r_breakpoint_at): Turn into...
1113 (m32r_target::low_breakpoint_at): ...this.
1114 (the_low_target): Remove the op field.
1115 * linux-m68k-low.cc (class m68k_target)
1116 <low_breakpoint_at>: Declare.
1117 (m68k_breakpoint_at): Turn into...
1118 (m68k_target::low_breakpoint_at): ...this.
1119 (the_low_target): Remove the op field.
1120 * linux-mips-low.cc (class mips_target)
1121 <low_breakpoint_at>: Declare.
1122 (mips_breakpoint_at): Turn into...
1123 (mips_target::low_breakpoint_at): ...this.
1124 (the_low_target): Remove the op field.
1125 * linux-nios2-low.cc (class nios2_target)
1126 <low_breakpoint_at>: Declare.
1127 (nios2_breakpoint_at): Turn into...
1128 (nios2_target::low_breakpoint_at): ...this.
1129 (the_low_target): Remove the op field.
1130 * linux-ppc-low.cc (class ppc_target)
1131 <low_breakpoint_at>: Declare.
1132 (ppc_breakpoint_at): Turn into...
1133 (ppc_target::low_breakpoint_at): ...this.
1134 (the_low_target): Remove the op field.
1135 * linux-riscv-low.cc (class riscv_target)
1136 <low_breakpoint_at>: Declare.
1137 (riscv_breakpoint_at): Turn into...
1138 (riscv_target::low_breakpoint_at): ...this.
1139 (the_low_target): Remove the op field.
1140 * linux-s390-low.cc (class s390_target)
1141 <low_breakpoint_at>: Declare.
1142 (s390_breakpoint_at): Turn into...
1143 (s390_target::low_breakpoint_at): ...this.
1144 (the_low_target): Remove the op field.
1145 * linux-sh-low.cc (class sh_target)
1146 <low_breakpoint_at>: Declare.
1147 (sh_breakpoint_at): Turn into...
1148 (sh_target::low_breakpoint_at): ...this.
1149 (the_low_target): Remove the op field.
1150 * linux-sparc-low.cc (class sparc_target)
1151 <low_breakpoint_at>: Declare.
1152 (sparc_breakpoint_at): Turn into...
1153 (sparc_target::low_breakpoint_at): ...this.
1154 (the_low_target): Remove the op field.
1155 * linux-tic6x-low.cc (class tic6x_target)
1156 <low_breakpoint_at>: Declare.
1157 (tic6x_breakpoint_at): Turn into...
1158 (tic6x_target::low_breakpoint_at): ...this.
1159 (the_low_target): Remove the op field.
1160 * linux-tile-low.cc (class tile_target)
1161 <low_breakpoint_at>: Declare.
1162 (tile_breakpoint_at): Turn into...
1163 (tile_target::low_breakpoint_at): ...this.
1164 (the_low_target): Remove the op field.
1165 * linux-xtensa-low.cc (class xtensa_target)
1166 <low_breakpoint_at>: Declare.
1167 (xtensa_breakpoint_at): Turn into...
1168 (xtensa_target::low_breakpoint_at): ...this.
1169 (the_low_target): Remove the op field.
1170
1171 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1172
1173 Turn the 'decr_pc_after_break' linux_target_ops field into
1174 a method of linux_process_target.
1175
1176 * linux-low.h (struct linux_target_ops)
1177 <decr_pc_after_break>: Remove.
1178 (class linux_process_target) <low_decr_pc_after_break>: New method
1179 declaration.
1180 * linux-low.cc (linux_process_target::low_decr_pc_after_break):
1181 New method implementation.
1182
1183 Update the users below.
1184
1185 (linux_process_target::save_stop_reason)
1186 (linux_process_target::wait_1)
1187 * linux-x86-low.cc (class x86_target) <low_decr_pc_after_break>:
1188 New declaration.
1189 (x86_target::low_decr_pc_after_break): New method implementation.
1190 (the_low_target): Remove the field.
1191 * linux-bfin-low.cc (class bfin_target) <low_decr_pc_after_break>:
1192 New declaration.
1193 (bfin_target::low_decr_pc_after_break): New method implementation.
1194 (the_low_target): Remove the field.
1195 * linux-m68k-low.cc (class m68k_target) <low_decr_pc_after_break>:
1196 New declaration.
1197 (m68k_target::low_decr_pc_after_break): New method implementation.
1198 (the_low_target): Remove the field.
1199 * linux-s390-low.cc (class s390_target) <low_decr_pc_after_break>:
1200 New declaration.
1201 (s390_target::low_decr_pc_after_break): New method implementation.
1202 (the_low_target): Remove the field.
1203 * linux-aarch64-low.cc (the_low_target): Remove the field.
1204 * linux-arm-low.cc (the_low_target): Remove the field.
1205 * linux-cris-low.cc (the_low_target): Remove the field.
1206 * linux-crisv32-low.cc (the_low_target): Remove the field.
1207 * linux-m32r-low.cc (the_low_target): Remove the field.
1208 * linux-mips-low.cc (the_low_target): Remove the field.
1209 * linux-nios2-low.cc (the_low_target): Remove the field.
1210 * linux-ppc-low.cc (the_low_target): Remove the field.
1211 * linux-riscv-low.cc (the_low_target): Remove the field.
1212 * linux-sh-low.cc (the_low_target): Remove the field.
1213 * linux-sparc-low.cc (the_low_target): Remove the field.
1214 * linux-tic6x-low.cc (the_low_target): Remove the field.
1215 * linux-tile-low.cc (the_low_target): Remove the field.
1216 * linux-xtensa-low.cc (the_low_target): Remove the field.
1217
1218 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1219
1220 Remove the 'supports_software_single_step' linux target op and let
1221 the concrete linux target define it by overriding the op in
1222 process_stratum_target.
1223 Turn the 'get_next_pcs' linux target op into a method of
1224 linux_process_target.
1225
1226 * linux-low.h (struct linux_target_ops): Remove the ops.
1227 (class linux_process_target) <supports_software_single_step>:
1228 Remove.
1229 <low_get_next_pcs>: Declare.
1230 * linux-low.cc (can_software_single_step): Remove.
1231 (linux_process_target::low_get_next_pcs): Define.
1232 (linux_process_target::supports_software_single_step): Remove.
1233
1234 Update the callers below.
1235
1236 (linux_process_target::handle_extended_wait)
1237 (linux_process_target::wait_1)
1238 (linux_process_target::install_software_single_step_breakpoints)
1239 (linux_process_target::single_step)
1240 (linux_process_target::thread_needs_step_over)
1241 (linux_process_target::proceed_one_lwp)
1242 (linux_process_target::supports_range_stepping)
1243
1244 * linux-x86-low.cc (the_low_target): Remove the op field.
1245 * linux-aarch64-low.cc (the_low_target): Ditto.
1246 * linux-bfin-low.cc (the_low_target): Ditto.
1247 * linux-cris-low.cc (the_low_target): Ditto.
1248 * linux-crisv32-low.cc (the_low_target): Ditto.
1249 * linux-m32r-low.cc (the_low_target): Ditto.
1250 * linux-m68k-low.cc (the_low_target): Ditto.
1251 * linux-mips-low.cc (the_low_target): Ditto.
1252 * linux-nios2-low.cc (the_low_target): Ditto.
1253 * linux-ppc-low.cc (the_low_target): Ditto.
1254 * linux-riscv-low.cc (the_low_target): Ditto.
1255 * linux-s390-low.cc (the_low_target): Ditto.
1256 * linux-sh-low.cc (the_low_target): Ditto.
1257 * linux-sparc-low.cc (the_low_target): Ditto.
1258 * linux-tic6x-low.cc (the_low_target): Ditto.
1259 * linux-tile-low.cc (the_low_target): Ditto.
1260 * linux-xtensa-low.cc (the_low_target): Ditto.
1261 * linux-arm-low.cc (class arm_target) <low_get_next_pcs>
1262 <supports_software_single_step>: Declare.
1263 (arm_target::supports_software_single_step): Define.
1264 (arm_gdbserver_get_next_pcs): Turn into...
1265 (arm_target::low_get_next_pcs): ...this.
1266 (the_low_target): Remove the op field.
1267
1268 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1269
1270 Remove the 'sw_breakpoint_from_kind' linux target op, and let
1271 the concrete linux target define it by overriding the op
1272 in process_stratum_target.
1273
1274 * linux-low.cc (linux_process_target::sw_breakpoint_from_kind):
1275 Remove.
1276 * linux-low.h (struct linux_target_ops): Remove the op.
1277 (class linux_process_target) <sw_breakpoint_from_kind>: Remove.
1278 * linux-x86-low.cc (class x86_target) <sw_breakpoint_from_kind>:
1279 Declare.
1280 (x86_sw_breakpoint_from_kind): Turn into...
1281 (x86_target::sw_breakpoint_from_kind): ...this.
1282 (the_low_target): Remove the op field.
1283 * linux-aarch64-low.cc (class aarch64_target)
1284 <sw_breakpoint_from_kind>: Declare.
1285 (aarch64_sw_breakpoint_from_kind): Turn into...
1286 (aarch64_target::sw_breakpoint_from_kind): ...this.
1287 (the_low_target): Remove the op field.
1288 * linux-arm-low.cc (class arm_target) <sw_breakpoint_from_kind>:
1289 Declare.
1290 (arm_target::sw_breakpoint_from_kind): Define.
1291 (the_low_target): Remove the op field.
1292 * linux-bfin-low.cc (class bfin_target) <sw_breakpoint_from_kind>:
1293 Declare.
1294 (bfin_sw_breakpoint_from_kind): Turn into...
1295 (bfin_target::sw_breakpoint_from_kind): ...this.
1296 (the_low_target): Remove the op field.
1297 * linux-cris-low.cc (class cris_target) <sw_breakpoint_from_kind>:
1298 Declare.
1299 (cris_sw_breakpoint_from_kind): Turn into...
1300 (cris_target::sw_breakpoint_from_kind): ...this.
1301 (the_low_target): Remove the op field.
1302 * linux-crisv32-low.cc (class crisv32_target)
1303 <sw_breakpoint_from_kind>: Declare.
1304 (cris_sw_breakpoint_from_kind): Turn into...
1305 (crisv32_target::sw_breakpoint_from_kind): ...this.
1306 (the_low_target): Remove the op field.
1307 * linux-ia64-low.cc (class ia64_target) <sw_breakpoint_from_kind>:
1308 Declare.
1309 (ia64_target::sw_breakpoint_from_kind): Define.
1310 * linux-m32r-low.cc (class m32r_target) <sw_breakpoint_from_kind>:
1311 Declare.
1312 (m32r_sw_breakpoint_from_kind): Turn into...
1313 (m32r_target::sw_breakpoint_from_kind): ...this.
1314 (the_low_target): Remove the op field.
1315 * linux-m68k-low.cc (class m68k_target) <sw_breakpoint_from_kind>:
1316 Declare.
1317 (m68k_sw_breakpoint_from_kind): Turn into...
1318 (m68k_target::sw_breakpoint_from_kind): ...this.
1319 (the_low_target): Remove the op field.
1320 * linux-mips-low.cc (class mips_target) <sw_breakpoint_from_kind>:
1321 Declare.
1322 (mips_sw_breakpoint_from_kind): Turn into...
1323 (mips_target::sw_breakpoint_from_kind): ...this.
1324 (the_low_target): Remove the op field.
1325 * linux-nios2-low.cc (class nios2_target) <sw_breakpoint_from_kind>:
1326 Declare.
1327 (nios2_sw_breakpoint_from_kind): Turn into...
1328 (nios2_target::sw_breakpoint_from_kind): ...this.
1329 (the_low_target): Remove the op field.
1330 * linux-ppc-low.cc (class ppc_target) <sw_breakpoint_from_kind>:
1331 Declare.
1332 (ppc_sw_breakpoint_from_kind): Turn into...
1333 (ppc_target::sw_breakpoint_from_kind): ...this.
1334 (the_low_target): Remove the op field.
1335 * linux-riscv-low.cc (class riscv_target) <sw_breakpoint_from_kind>:
1336 Declare.
1337 (riscv_sw_breakpoint_from_kind): Turn into...
1338 (riscv_target::sw_breakpoint_from_kind): ...this.
1339 (the_low_target): Remove the op field.
1340 * linux-s390-low.cc (class s390_target) <sw_breakpoint_from_kind>:
1341 Declare.
1342 (s390_sw_breakpoint_from_kind): Turn into...
1343 (s390_target::sw_breakpoint_from_kind): ...this.
1344 (the_low_target): Remove the op field.
1345 * linux-sh-low.cc (class sh_target) <sw_breakpoint_from_kind>:
1346 Declare.
1347 (sh_sw_breakpoint_from_kind): Turn into...
1348 (sh_target::sw_breakpoint_from_kind): ...this.
1349 (the_low_target): Remove the op field.
1350 * linux-sparc-low.cc (class sparc_target) <sw_breakpoint_from_kind>:
1351 Declare.
1352 (sparc_sw_breakpoint_from_kind): Turn into...
1353 (sparc_target::sw_breakpoint_from_kind): ...this.
1354 (the_low_target): Remove the op field.
1355 * linux-tic6x-low.cc (class tic6x_target) <sw_breakpoint_from_kind>:
1356 Declare.
1357 (tic6x_sw_breakpoint_from_kind): Turn into...
1358 (tic6x_target::sw_breakpoint_from_kind): ...this.
1359 (the_low_target): Remove the op field.
1360 * linux-tile-low.cc (class tile_target) <sw_breakpoint_from_kind>:
1361 Declare.
1362 (tile_sw_breakpoint_from_kind): Turn into...
1363 (tile_target::sw_breakpoint_from_kind): ...this.
1364 (the_low_target): Remove the op field.
1365 * linux-xtensa-low.cc (class xtensa_target)
1366 <sw_breakpoint_from_kind>: Declare.
1367 (xtensa_sw_breakpoint_from_kind): Turn into...
1368 (xtensa_target::sw_breakpoint_from_kind): ...this.
1369 (the_low_target): Remove the op field.
1370
1371 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1372
1373 Remove the 'breakpoint_kind_from_pc' and
1374 'breakpoint_kind_from_current_state' linux target ops, and let the
1375 concrete linux target define them by overriding the ops of
1376 process_stratum_target.
1377
1378 * linux-low.cc (linux_process_target::breakpoint_kind_from_pc):
1379 Remove.
1380 (linux_process_target::breakpoint_kind_from_current_state): Remove.
1381 * linux-low.h (struct linux_target_ops): Remove ops.
1382 (class linux_process_target) <breakpoint_kind_from_pc>: Remove.
1383 <breakpoint_kind_from_current_state>: Remove.
1384 * linux-x86-low.cc (the_low_target): Remove the op fields.
1385 * linux-bfin-low.cc (the_low_target): Ditto.
1386 * linux-cris-low.cc (the_low_target): Ditto.
1387 * linux-crisv32-low.cc (the_low_target): Ditto.
1388 * linux-m32r-low.cc (the_low_target): Ditto.
1389 * linux-m68k-low.cc (the_low_target): Ditto.
1390 * linux-mips-low.cc (the_low_target): Ditto.
1391 * linux-nios2-low.cc (the_low_target): Ditto.
1392 * linux-ppc-low.cc (the_low_target): Ditto.
1393 * linux-s390-low.cc (the_low_target): Ditto.
1394 * linux-sh-low.cc (the_low_target): Ditto.
1395 * linux-sparc-low.cc (the_low_target): Ditto.
1396 * linux-tic6x-low.cc (the_low_target): Ditto.
1397 * linux-tile-low.cc (the_low_target): Ditto.
1398 * linux-xtensa-low.cc (the_low_target): Ditto.
1399 * linux-aarch64-low.cc (class aarch64_target)
1400 <breakpoint_kind_from_pc>
1401 <breakpoint_kind_from_current_state>: Declare.
1402 (aarch64_breakpoint_kind_from_pc): Turn into...
1403 (aarch64_target::breakpoint_kind_from_pc): ...this.
1404 (aarch64_breakpoint_kind_from_current_state): Turn into...
1405 (aarch64_target::breakpoint_kind_from_current_state): ...this.
1406 (the_low_target): Remove the op fields.
1407 * linux-arm-low.cc (class arm_target):
1408 <breakpoint_kind_from_pc>
1409 <breakpoint_kind_from_current_state>: Declare.
1410 (arm_target::breakpoint_kind_from_pc): Define.
1411 (arm_target::breakpoint_kind_from_current_state): Define.
1412 (the_low_target): Remove the op fields.
1413 * linux-riscv-low.cc (class riscv_target):
1414 <breakpoint_kind_from_pc>: Declare.
1415 (riscv_breakpoint_kind_from_pc): Turn into...
1416 (riscv_target::breakpoint_kind_from_pc): ...this.
1417 (the_low_target): Remove the op fields.
1418
1419 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1420
1421 Turn the 'get_pc' and 'set_pc' linux target ops into methods
1422 of linux_process_target.
1423
1424 * linux-low.h (struct linux_target_ops): Remove the ops.
1425 (class linux_process_target) <low_supports_breakpoints>
1426 <low_get_pc>
1427 <low_set_pc>: Declare.
1428 * linux-low.cc (supports_breakpoints): Turn into...
1429 (linux_process_target::low_supports_breakpoints): ...this.
1430 (linux_process_target::low_get_pc): Define.
1431 (linux_process_target::low_set_pc): Define.
1432
1433 Update the callers below.
1434
1435 (linux_process_target::get_pc)
1436 (linux_process_target::save_stop_reason)
1437 (linux_process_target::maybe_move_out_of_jump_pad)
1438 (linux_process_target::wait_1)
1439 (linux_process_target::resume_one_lwp_throw)
1440 (linux_process_target::resume)
1441 (linux_process_target::proceed_all_lwps)
1442 (linux_process_target::read_pc)
1443 (linux_process_target::write_pc)
1444
1445 * linux-x86-low.cc (class linux_process_target)
1446 <low_supports_breakpoints>
1447 <low_get_pc>
1448 <low_set_pc>: Declare.
1449 (x86_target::low_supports_breakpoints): Define.
1450 (x86_get_pc): Turn into...
1451 (x86_target::low_get_pc): ...this.
1452 (x86_set_pc): Turn into...
1453 (x86_target::low_set_pc): ...this.
1454 (the_low_target): Remove the op fields.
1455 * linux-arm-low.cc (class arm_target)
1456 <low_supports_breakpoints>
1457 <low_get_pc>
1458 <low_set_pc>: Declare.
1459 (arm_target::low_supports_breakpoints)
1460 (arm_target::low_get_pc)
1461 (arm_target::low_set_pc): Define.
1462 (the_low_target): Remove the op fields.
1463 * linux-bfin-low.cc (class bfin_target)
1464 <low_supports_breakpoints>
1465 <low_get_pc>
1466 <low_set_pc>: Declare.
1467 (bfin_target::low_supports_breakpoints)
1468 (bfin_target::low_get_pc)
1469 (bfin_target::low_set_pc): Define.
1470 (the_low_target): Remove the op fields.
1471 * linux-cris-low.cc (class cris_target)
1472 <low_supports_breakpoints>
1473 <low_get_pc>
1474 <low_set_pc>: Declare.
1475 (cris_target::low_supports_breakpoints)
1476 (cris_target::low_get_pc)
1477 (cris_target::low_set_pc): Define.
1478 (the_low_target): Remove the op fields.
1479 * linux-crisv32-low.cc (class crisv32_target)
1480 <low_supports_breakpoints>
1481 <low_get_pc>
1482 <low_set_pc>: Declare.
1483 (crisv32_target::low_supports_breakpoints)
1484 (crisv32_target::low_get_pc)
1485 (crisv32_target::low_set_pc): Define.
1486 (the_low_target): Remove the op fields.
1487 * linux-m32r-low.cc (class m32r_target)
1488 <low_supports_breakpoints>
1489 <low_get_pc>
1490 <low_set_pc>: Declare.
1491 (m32r_target::low_supports_breakpoints)
1492 (m32r_target::low_get_pc)
1493 (m32r_target::low_set_pc): Define.
1494 (the_low_target): Remove the op fields.
1495 * linux-m68k-low.cc (class m68k_target)
1496 <low_supports_breakpoints>
1497 <low_get_pc>
1498 <low_set_pc>: Declare.
1499 (m68k_target::low_supports_breakpoints)
1500 (m68k_target::low_get_pc)
1501 (m68k_target::low_set_pc): Define.
1502 (the_low_target): Remove the op fields.
1503 * linux-nios2-low.cc (class nios2_target)
1504 <low_supports_breakpoints>
1505 <low_get_pc>
1506 <low_set_pc>: Declare.
1507 (nios2_target::low_supports_breakpoints)
1508 (nios2_target::low_get_pc)
1509 (nios2_target::low_set_pc): Define.
1510 (the_low_target): Remove the op fields.
1511 * linux-sh-low.cc (class sh_target)
1512 <low_supports_breakpoints>
1513 <low_get_pc>
1514 <low_set_pc>: Declare.
1515 (sh_target::low_supports_breakpoints)
1516 (sh_target::low_get_pc)
1517 (sh_target::low_set_pc): Define.
1518 (the_low_target): Remove the op fields.
1519 * linux-xtensa-low.cc (class xtensa_target)
1520 <low_supports_breakpoints>
1521 <low_get_pc>
1522 <low_set_pc>: Declare.
1523 (xtensa_target::low_supports_breakpoints)
1524 (xtensa_target::low_get_pc)
1525 (xtensa_target::low_set_pc): Define.
1526 (the_low_target): Remove the op fields.
1527 * linux-sparc-low.cc (class sparc_target)
1528 <low_supports_breakpoints>
1529 <low_get_pc>: Declare.
1530 (sparc_target::low_supports_breakpoints)
1531 (sparc_target::low_get_pc): Define.
1532 (the_low_target): Remove the op fields.
1533 * linux-tile-low.cc (class tile_target)
1534 <low_supports_breakpoints>
1535 <low_get_pc>
1536 <low_set_pc>: Declare.
1537 (tile_target::low_supports_breakpoints)
1538 (tile_target::low_get_pc)
1539 (tile_target::low_set_pc): Define.
1540 (the_low_target): Remove the op fields.
1541 * linux-aarch64-low.cc (class aarch64_target)
1542 <low_supports_breakpoints>
1543 <low_get_pc>
1544 <low_set_pc>: Declare.
1545 (aarch64_target::low_supports_breakpoints): Define.
1546 (aarch64_get_pc): Turn into...
1547 (aarch64_target::low_get_pc): ...this.
1548 (aarch64_set_pc): Turn into...
1549 (aarch64_target::low_set_pc): ...this.
1550 (the_low_target): Remove the op fields.
1551 * linux-mips-low.cc (class mips_target)
1552 <low_supports_breakpoints>
1553 <low_get_pc>
1554 <low_set_pc>: Declare.
1555 (mips_target::low_supports_breakpoints): Define.
1556 (mips_get_pc): Turn into...
1557 (mips_target::low_get_pc): ...this.
1558 (mips_set_pc): Turn into...
1559 (mips_target::low_set_pc): ...this.
1560 (the_low_target): Remove the op fields.
1561 * linux-ppc-low.cc (class ppc_target)
1562 <low_supports_breakpoints>
1563 <low_get_pc>
1564 <low_set_pc>: Declare.
1565 (ppc_target::low_supports_breakpoints): Define.
1566 (ppc_get_pc): Turn into...
1567 (ppc_target::low_get_pc): ...this.
1568 (ppc_set_pc): Turn into...
1569 (ppc_target::low_set_pc): ...this.
1570 (the_low_target): Remove the op fields.
1571 * linux-riscv-low.cc (class riscv_target)
1572 <low_supports_breakpoints>
1573 <low_get_pc>
1574 <low_set_pc>: Declare.
1575 (riscv_target::low_supports_breakpoints): Define.
1576 (riscv_get_pc): Turn into...
1577 (riscv_target::low_get_pc): ...this.
1578 (riscv_set_pc): Turn into...
1579 (riscv_target::low_set_pc): ...this.
1580 (the_low_target): Remove the op fields.
1581 * linux-s390-low.cc (class s390_target)
1582 <low_supports_breakpoints>
1583 <low_get_pc>
1584 <low_set_pc>: Declare.
1585 (s390_target::low_supports_breakpoints): Define.
1586 (s390_get_pc): Turn into...
1587 (s390_target::low_get_pc): ...this.
1588 (s390_set_pc): Turn into...
1589 (s390_target::low_set_pc): ...this.
1590 (the_low_target): Remove the op fields.
1591 * linux-tic6x-low.cc (class tic6x_target)
1592 <low_supports_breakpoints>
1593 <low_get_pc>
1594 <low_set_pc>: Declare.
1595 (tic6x_target::low_supports_breakpoints): Define.
1596 (tic6x_get_pc): Turn into...
1597 (tic6x_target::low_get_pc): ...this.
1598 (tic6x_set_pc): Turn into...
1599 (tic6x_target::low_set_pc): ...this.
1600 (the_low_target): Remove the op fields.
1601
1602 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1603
1604 Turn some more static methods in linux-low into private methods
1605 of linux_process_target.
1606
1607 * linux-low.cc (get_pc): Turn into...
1608 (linux_process_target::get_pc): ...this.
1609 (save_stop_reason): Turn into...
1610 (linux_process_target::save_stop_reason): ...this.
1611 (thread_still_has_status_pending_p): Turn into...
1612 (linux_process_target::thread_still_has_status_pending): ...this.
1613 (status_pending_p_callback): Turn into...
1614 (linux_process_target::status_pending_p_callback): ...this.
1615 (resume_stopped_resumed_lwps): Turn into...
1616 (linux_process_target::resume_stopped_resumed_lwps): ...this.
1617 (install_software_single_step_breakpoints): Turn into...
1618 (linux_process_target::install_software_single_step_breakpoints):
1619 ...this.
1620 (single_step): Turn into...
1621 (linux_process_target::single_step): ...this.
1622 (linux_resume_one_lwp_throw): Turn into...
1623 (linux_process_target::resume_one_lwp_throw): ...this.
1624 (linux_resume_one_lwp): Turn into...
1625 (linux_process_target::resume_one_lwp): ...this.
1626 (resume_status_pending_p): Turn into...
1627 (linux_process_target::resume_status_pending): ...this.
1628 (need_step_over_p): Turn into...
1629 (linux_process_target::thread_needs_step_over): ...this.
1630 (linux_resume_one_thread): Turn into...
1631 (linux_process_target::resume_one_thread): ...this.
1632 (proceed_one_lwp): Turn into...
1633 (linux_process_target::proceed_one_lwp): ...this.
1634 (unsuspend_and_proceed_one_lwp): Turn into...
1635 (linux_process_target::unsuspend_and_proceed_one_lwp): ...this.
1636
1637 Update the calls/references to the above functions below.
1638
1639 (linux_process_target::handle_extended_wait)
1640 (linux_process_target::filter_event)
1641 (linux_process_target::wait_for_event_filtered)
1642 (linux_process_target::wait_1)
1643 (linux_process_target::move_out_of_jump_pad)
1644 (linux_process_target::start_step_over)
1645 (linux_process_target::resume)
1646 (linux_process_target::proceed_all_lwps)
1647 (regsets_store_inferior_registers)
1648 (linux_process_target::store_register)
1649
1650 * linux-low.h (class linux_process_target)
1651 <get_pc>
1652 <save_stop_reason>
1653 <thread_still_has_status_pending>
1654 <status_pending_p_callback>
1655 <resume_stopped_resumed_lwps>
1656 <install_software_single_step_breakpoints>
1657 <single_step>
1658 <resume_one_lwp_throw>
1659 <resume_one_lwp>
1660 <resume_status_pending>
1661 <thread_needs_step_over>
1662 <resume_one_thread>
1663 <proceed_one_lwp>
1664 <unsuspend_and_proceed_one_lwp>: Declare.
1665
1666 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1667
1668 Turn the 'fetch_register' linux target op into a method of
1669 linux_process_target.
1670
1671 * linux-low.h (struct linux_target_ops) <fetch_register>: Remove.
1672 (class linux_process_target) <low_fetch_register>: Declare.
1673 * linux-x86-low.cc (the_low_target)
1674 * linux-aarch64-low.cc (the_low_target)
1675 * linux-arm-low.cc (the_low_target)
1676 * linux-bfin-low.cc (the_low_target)
1677 * linux-cris-low.cc (the_low_target)
1678 * linux-crisv32-low.cc (the_low_target)
1679 * linux-m32r-low.cc (the_low_target)
1680 * linux-m68k-low.cc (the_low_target)
1681 * linux-nios2-low.cc (the_low_target)
1682 * linux-ppc-low.cc (the_low_target)
1683 * linux-s390-low.cc (the_low_target)
1684 * linux-sh-low.cc (the_low_target)
1685 * linux-sparc-low.cc (the_low_target)
1686 * linux-tic6x-low.cc (the_low_target)
1687 * linux-tile-low.cc (the_low_target)
1688 * linux-xtensa-low.cc (the_low_target): Remove the op field.
1689 * linux-ia64-low.cc (class ia64_target) <low_fetch_register>:
1690 Declare.
1691 (ia64_fetch_register): Turn into...
1692 (ia64_target::low_fetch_register): ...this.
1693 (the_low_target): Remove the op field.
1694 * linux-mips-low.cc (class mips_target) <low_fetch_register>:
1695 Declare.
1696 (mips_fetch_register): Turn into...
1697 (mips_target::low_fetch_register): ...this.
1698 (the_low_target): Remove the op field.
1699 * linux-riscv-low.cc (class riscv_target) <low_fetch_register>:
1700 Declare.
1701 (riscv_fetch_register): Turn into...
1702 (riscv_target::low_fetch_register): ...this.
1703 (the_low_target): Remove the op field.
1704
1705 Update the callers below.
1706
1707 * linux-low.cc (linux_process_target::fetch_registers)
1708 (linux_process_target::low_fetch_register)
1709
1710 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1711
1712 Turn the 'cannot_fetch_register' and 'cannot_store_register'
1713 linux target ops into methods of linux_process_target.
1714
1715 * linux-low.h (struct linux_target_ops): Remove the low target ops.
1716 (class linux_process_target) <fetch_register>
1717 <store_register>
1718 <usr_fetch_inferior_registers>
1719 <usr_store_inferior_registers>
1720 <low_cannot_fetch_register>
1721 <low_cannot_fetch_register> Declare.
1722 * linux-low.cc (fetch_register): Turn into...
1723 (linux_process_target::fetch_register): ...this.
1724 (store_register): Turn into ...
1725 (linux_process_target::store_register): ...this.
1726 (usr_fetch_inferior_registers): Turn into...
1727 (linux_process_target::usr_fetch_inferior_registers): ...this.
1728 (usr_store_inferior_registers): Turn into...
1729 (linux_process_target::usr_store_inferior_registers): ...this.
1730 * linux-x86-low.cc (class x86_target)
1731 <low_cannot_fetch_register>
1732 <low_cannot_store_register>: Declare.
1733 (x86_cannot_store_register): Turn into...
1734 (x86_target::low_cannot_store_register): ...this.
1735 (x86_cannot_fetch_register): Turn into...
1736 (x86_target::low_cannot_fetch_register): ...this.
1737 (the_low_target): Remove the target op fields.
1738 * linux-aarch64-low.cc (class aarch64_target)
1739 <low_cannot_fetch_register>
1740 <low_cannot_store_register>: Declare.
1741 (aarch64_target::low_cannot_fetch_register)
1742 (aarch64_target::low_cannot_store_register): Define.
1743 (the_low_target): Remove the op fields.
1744 * linux-arm-low.cc (class arm_target)
1745 <low_cannot_fetch_register>
1746 <low_cannot_store_register>: Declare.
1747 (arm_cannot_fetch_register): Turn into...
1748 (arm_target::low_cannot_fetch_register): ...this.
1749 (arm_cannot_store_register): Turn into...
1750 (arm_target::low_cannot_store_register): ...this.
1751 (the_low_target): Remove the op fields.
1752 * linux-bfin-low.cc (class bfin_target)
1753 <low_cannot_fetch_register>
1754 <low_cannot_store_register>: Declare.
1755 (bfin_cannot_fetch_register): Turn into...
1756 (bfin_target::low_cannot_fetch_register): ...this.
1757 (bfin_cannot_store_register): Turn into...
1758 (bfin_target::low_cannot_store_register): ...this.
1759 (the_low_target): Remove the op fields.
1760 * linux-cris-low.cc (class cris_target)
1761 <low_cannot_fetch_register>
1762 <low_cannot_store_register>: Declare.
1763 (cris_cannot_fetch_register): Turn into...
1764 (cris_target::low_cannot_fetch_register): ...this.
1765 (cris_cannot_store_register): Turn into...
1766 (cris_target::low_cannot_store_register): ...this.
1767 (the_low_target): Remove the op fields.
1768 * linux-crisv32-low.cc (class crisv32_target)
1769 <low_cannot_fetch_register>
1770 <low_cannot_store_register>: Declare.
1771 (crisv32_target::low_cannot_fetch_register)
1772 (crisv32_target::low_cannot_store_register): Define.
1773 (the_low_target): Remove the op fields.
1774 * linux-ia64-low.cc (class ia64_target)
1775 <low_cannot_fetch_register>
1776 <low_cannot_store_register>: Declare.
1777 (ia64_cannot_fetch_register): Turn into...
1778 (ia64_target::low_cannot_fetch_register): ...this.
1779 (ia64_cannot_store_register): Turn into...
1780 (ia64_target::low_cannot_store_register): ...this.
1781 (the_low_target): Remove the op fields.
1782 * linux-m32r-low.cc (class m32r_target)
1783 <low_cannot_fetch_register>
1784 <low_cannot_store_register>: Declare.
1785 (m32r_cannot_fetch_register): Turn into...
1786 (m32r_target::low_cannot_fetch_register): ...this.
1787 (m32r_cannot_store_register): Turn into...
1788 (m32r_target::low_cannot_store_register): ...this.
1789 (the_low_target): Remove the op fields.
1790 * linux-m68k-low.cc (class m68k_target)
1791 <low_cannot_fetch_register>
1792 <low_cannot_store_register>: Declare.
1793 (m68k_cannot_fetch_register): Turn into...
1794 (m68k_target::low_cannot_fetch_register): ...this.
1795 (m68k_cannot_store_register): Turn into...
1796 (m68k_target::low_cannot_store_register): ...this.
1797 (the_low_target): Remove the op fields.
1798 * linux-mips-low.cc (class mips_target)
1799 <low_cannot_fetch_register>
1800 <low_cannot_store_register>: Declare.
1801 (mips_cannot_fetch_register): Turn into...
1802 (mips_target::low_cannot_fetch_register): ...this.
1803 (mips_cannot_store_register): Turn into...
1804 (mips_target::low_cannot_store_register): ...this.
1805 (get_usrregs_info): Inline at the call sites in
1806 low_cannot_fetch_register and low_cannot_store_register,
1807 and remove.
1808 (the_low_target): Remove the op fields.
1809 * linux-nios2-low.cc (class nios2_target)
1810 <low_cannot_fetch_register>
1811 <low_cannot_store_register>: Declare.
1812 (nios2_cannot_fetch_register): Turn into...
1813 (nios2_target::low_cannot_fetch_register): ...this.
1814 (nios2_cannot_store_register): Turn into...
1815 (nios2_target::low_cannot_store_register): ...this.
1816 (the_low_target): Remove the op fields.
1817 * linux-ppc-low.cc (class ppc_target)
1818 <low_cannot_fetch_register>
1819 <low_cannot_store_register>: Declare.
1820 (ppc_cannot_fetch_register): Turn into...
1821 (ppc_target::low_cannot_fetch_register): ...this.
1822 (ppc_cannot_store_register): Turn into...
1823 (ppc_target::low_cannot_store_register): ...this.
1824 (the_low_target): Remove the op fields.
1825 * linux-riscv-low.cc (class riscv_target)
1826 <low_cannot_fetch_register>
1827 <low_cannot_store_register>: Declare.
1828 (riscv_target::low_cannot_fetch_register)
1829 (riscv_target::low_cannot_store_register): Define.
1830 (the_low_target): Remove the op fields.
1831 * linux-s390-low.cc (class s390_target)
1832 <low_cannot_fetch_register>
1833 <low_cannot_store_register>: Declare.
1834 (s390_cannot_fetch_register): Turn into...
1835 (s390_target::low_cannot_fetch_register): ...this.
1836 (s390_cannot_store_register): Turn into...
1837 (s390_target::low_cannot_store_register): ...this.
1838 (the_low_target): Remove the op fields.
1839 * linux-sh-low.cc (class sh_target)
1840 <low_cannot_fetch_register>
1841 <low_cannot_store_register>: Declare.
1842 (sh_cannot_fetch_register): Turn into...
1843 (sh_target::low_cannot_fetch_register): ...this.
1844 (sh_cannot_store_register): Turn into...
1845 (sh_target::low_cannot_store_register): ...this.
1846 (the_low_target): Remove the op fields.
1847 * linux-sparc-low.cc (class sparc_target)
1848 <low_cannot_fetch_register>
1849 <low_cannot_store_register>: Declare.
1850 (sparc_cannot_fetch_register): Turn into...
1851 (sparc_target::low_cannot_fetch_register): ...this.
1852 (sparc_cannot_store_register): Turn into...
1853 (sparc_target::low_cannot_store_register): ...this.
1854 (the_low_target): Remove the op fields.
1855 * linux-tic6x-low.cc (class tic6x_target)
1856 <low_cannot_fetch_register>
1857 <low_cannot_store_register>: Declare.
1858 (tic6x_cannot_fetch_register): Turn into...
1859 (tic6x_target::low_cannot_fetch_register): ...this.
1860 (tic6x_cannot_store_register): Turn into...
1861 (tic6x_target::low_cannot_store_register): ...this.
1862 (the_low_target): Remove the op fields.
1863 * linux-tile-low.cc (class tile_target)
1864 <low_cannot_fetch_register>
1865 <low_cannot_store_register>: Declare.
1866 (tile_cannot_fetch_register): Turn into...
1867 (tile_target::low_cannot_fetch_register): ...this.
1868 (tile_cannot_store_register): Turn into...
1869 (tile_target::low_cannot_store_register): ...this.
1870 (the_low_target): Remove the op fields.
1871 * linux-xtensa-low.cc (class xtensa_target)
1872 <low_cannot_fetch_register>
1873 <low_cannot_store_register>: Declare.
1874 (xtensa_target::low_cannot_fetch_register)
1875 (xtensa_target::low_cannot_store_register): Define.
1876 (the_low_target): Remove the op fields.
1877
1878 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1879
1880 Turn the 'regs_info' linux target op into a method of
1881 linux_process_target.
1882
1883 * linux-low.h (struct linux_target_ops) <regs_info>: Remove.
1884 (class linux_process_target) <get_regs_info>: Define.
1885
1886 Update the callers below.
1887
1888 * linux-low.cc (linux_process_target::fetch_registers)
1889 (linux_process_target::store_registers)
1890 * proc-service.cc (gregset_info)
1891
1892 * linux-x86-low.cc (class x86_target) <get_regs_info>: Declare.
1893 (x86_linux_regs_info): Turn into ...
1894 (x86_target::get_regs_info): ...this.
1895 (the_low_target): Remove the op field.
1896 * linux-aarch64-low.cc (class aarch64_target) <get_regs_info>:
1897 Declare.
1898 (aarch64_regs_info): Turn into ...
1899 (aarch64_target::get_regs_info): ...this.
1900 (the_low_target): Remove the op field.
1901 * linux-arm-low.cc (class arm_target) <get_regs_info>: Declare.
1902 (arm_regs_info): Turn into ...
1903 (arm_target::get_regs_info): ...this.
1904 (the_low_target): Remove the op field.
1905 * linux-bfin-low.cc (class bfin_target) <get_regs_info>: Declare.
1906 (bfin_regs_info): Turn into ...
1907 (bfin_target::get_regs_info): ...this.
1908 (the_low_target): Remove the op field.
1909 * linux-cris-low.cc (class cris_target) <get_regs_info>: Declare.
1910 (cris_regs_info): Turn into ...
1911 (cris_target::get_regs_info): ...this.
1912 (the_low_target): Remove the op field.
1913 * linux-crisv32-low.cc (class crisv32_target) <get_regs_info>:
1914 Declare.
1915 (crisv32_regs_info): Turn into ...
1916 (crisv32_target::get_regs_info): ...this.
1917 (the_low_target): Remove the op field.
1918 * linux-ia64-low.cc (class ia64_target) <get_regs_info>: Declare.
1919 (ia64_regs_info): Turn into ...
1920 (ia64_target::get_regs_info): ...this.
1921 (the_low_target): Remove the op field.
1922 * linux-m32r-low.cc (class m32r_target) <get_regs_info>: Declare.
1923 (m32r_regs_info): Turn into ...
1924 (m32r_target::get_regs_info): ...this.
1925 (the_low_target): Remove the op field.
1926 * linux-m68k-low.cc (class m68k_target) <get_regs_info>: Declare.
1927 (m68k_regs_info): Turn into ...
1928 (m68k_target::get_regs_info): ...this.
1929 (the_low_target): Remove the op field.
1930 * linux-mips-low.cc (class mips_target) <get_regs_info>: Declare.
1931 (mips_regs_info): Turn into ...
1932 (mips_target::get_regs_info): ...this.
1933 (the_low_target): Remove the op field.
1934 (get_usrregs_info): Update the call to the op.
1935 * linux-nios2-low.cc (class nios2_target) <get_regs_info>: Declare.
1936 (nios2_regs_info): Turn into ...
1937 (nios2_target::get_regs_info): ...this.
1938 (the_low_target): Remove the op field.
1939 * linux-ppc-low.cc (class ppc_target) <get_regs_info>: Declare.
1940 (ppc_regs_info): Turn into ...
1941 (ppc_target::get_regs_info): ...this.
1942 (the_low_target): Remove the op field.
1943 * linux-riscv-low.cc (class riscv_target) <get_regs_info>: Declare.
1944 (riscv_regs_info): Turn into ...
1945 (riscv_target::get_regs_info): ...this.
1946 (the_low_target): Remove the op field.
1947 * linux-s390-low.cc (class s390_target) <get_regs_info>: Declare.
1948 (s390_regs_info): Turn into ...
1949 (s390_target::get_regs_info): ...this.
1950 (the_low_target): Remove the op field.
1951 (s390_collect_ptrace_register)
1952 (s390_supply_ptrace_register)
1953 (s390_fill_gregset): Update the call to the op.
1954 * linux-sh-low.cc (class sh_target) <get_regs_info>: Declare.
1955 (sh_regs_info): Turn into ...
1956 (sh_target::get_regs_info): ...this.
1957 (the_low_target): Remove the op field.
1958 * linux-sparc-low.cc (class sparc_target) <get_regs_info>: Declare.
1959 (sparc_regs_info): Turn into ...
1960 (sparc_target::get_regs_info): ...this.
1961 (the_low_target): Remove the op field.
1962 * linux-tic6x-low.cc (class tic6x_target) <get_regs_info>: Declare.
1963 (tic6x_regs_info): Turn into ...
1964 (tic6x_target::get_regs_info): ...this.
1965 (the_low_target): Remove the op field.
1966 * linux-tile-low.cc (class tile_target) <get_regs_info>: Declare.
1967 (tile_regs_info): Turn into ...
1968 (tile_target::get_regs_info): ...this.
1969 (the_low_target): Remove the op field.
1970 * linux-xtensa-low.cc (class xtensa_target) <get_regs_info>:
1971 Declare.
1972 (xtensa_regs_info): Turn into ...
1973 (xtensa_target::get_regs_info): ...this.
1974 (the_low_target): Remove the op field.
1975
1976 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1977
1978 Turn the 'arch_setup' linux target op into a method of
1979 linux_process_target.
1980
1981 * linux-low.h (struct linux_target_ops) <arch_setup>: Delete.
1982 (class linux_process_target) <arch_setup_thread>
1983 <low_arch_setup>: New declarations.
1984 * linux-low.cc (linux_arch_setup): Delete.
1985 (linux_arch_setup_thread): Turn into...
1986 (linux_process_target::arch_setup_thread): ... this.
1987
1988 Update the callers below.
1989
1990 (linux_process_target::handle_extended_wait)
1991 (linux_process_target::post_create_inferior)
1992 (linux_process_target::filter_event)
1993
1994 * linux-x86-low.cc (class x86_target) <low_arch_setup>: New
1995 declaration.
1996 (x86_linux_update_xmltarget): Turn into...
1997 (x86_target::update_xmltarget): ...this.
1998 (x86_linux_process_qsupported): Update the call to
1999 x86_linux_update_xmltarget.
2000 (x86_arch_setup): Turn into ...
2001 (x86_target::low_arch_setup): ...this.
2002 (the_low_target): Remove the op field.
2003 * linux-aarch64-low.cc (class aarch64_target) <low_arch_setup>: New
2004 declaration.
2005 (aarch64_arch_setup): Turn into ...
2006 (aarch64_target::low_arch_setup): ...this.
2007 (the_low_target): Remove the op field.
2008 * linux-arm-low.cc (class arm_target) <low_arch_setup>: New
2009 declaration.
2010 (arm_arch_setup): Turn into ...
2011 (arm_target::low_arch_setup): ...this.
2012 (the_low_target): Remove the op field.
2013 * linux-bfin-low.cc (class bfin_target) <low_arch_setup>: New
2014 declaration.
2015 (bfin_arch_setup): Turn into ...
2016 (bfin_target::low_arch_setup): ...this.
2017 (the_low_target): Remove the op field.
2018 * linux-cris-low.cc (class cris_target) <low_arch_setup>: New
2019 declaration.
2020 (cris_arch_setup): Turn into ...
2021 (cris_target::low_arch_setup): ...this.
2022 (the_low_target): Remove the op field.
2023 * linux-crisv32-low.cc (class crisv32_target) <low_arch_setup>: New
2024 declaration.
2025 (crisv32_arch_setup): Turn into ...
2026 (crisv32_target::low_arch_setup): ...this.
2027 (the_low_target): Remove the op field.
2028 * linux-ia64-low.cc (class ia64_target) <low_arch_setup>: New
2029 declaration.
2030 (ia64_arch_setup): Turn into ...
2031 (ia64_target::low_arch_setup): ...this.
2032 (the_low_target): Remove the op field.
2033 * linux-m32r-low.cc (class m32r_target) <low_arch_setup>: New
2034 declaration.
2035 (m32r_arch_setup): Turn into ...
2036 (m32r_target::low_arch_setup): ...this.
2037 (the_low_target): Remove the op field.
2038 * linux-m68k-low.cc (class m68k_target) <low_arch_setup>: New
2039 declaration.
2040 (m68k_arch_setup): Turn into ...
2041 (m68k_target::low_arch_setup): ...this.
2042 (the_low_target): Remove the op field.
2043 * linux-mips-low.cc (class mips_target) <low_arch_setup>: New
2044 declaration.
2045 (mips_arch_setup): Turn into ...
2046 (mips_target::low_arch_setup): ...this.
2047 (the_low_target): Remove the op field.
2048 * linux-nios2-low.cc (class nios2_target) <low_arch_setup>: New
2049 declaration.
2050 (nios2_arch_setup): Turn into ...
2051 (nios2_target::low_arch_setup): ...this.
2052 (the_low_target): Remove the op field.
2053 * linux-ppc-low.cc (class ppc_target) <low_arch_setup>: New
2054 declaration.
2055 (ppc_arch_setup): Turn into ...
2056 (ppc_target::low_arch_setup): ...this.
2057 (the_low_target): Remove the op field.
2058 * linux-riscv-low.cc (class riscv_target) <low_arch_setup>: New
2059 declaration.
2060 (riscv_arch_setup): Turn into ...
2061 (riscv_target::low_arch_setup): ...this.
2062 (the_low_target): Remove the op field.
2063 * linux-s390-low.cc (class s390_target) <low_arch_setup>: New
2064 declaration.
2065 (s390_arch_setup): Turn into ...
2066 (s390_target::low_arch_setup): ...this.
2067 (the_low_target): Remove the op field.
2068 * linux-sh-low.cc (class sh_target) <low_arch_setup>: New
2069 declaration.
2070 (sh_arch_setup): Turn into ...
2071 (sh_target::low_arch_setup): ...this.
2072 (the_low_target): Remove the op field.
2073 * linux-sparc-low.cc (class sparc_target) <low_arch_setup>: New
2074 declaration.
2075 (sparc_arch_setup): Turn into ...
2076 (sparc_target::low_arch_setup): ...this.
2077 (the_low_target): Remove the op field.
2078 * linux-tic6x-low.cc (class tic6x_target) <low_arch_setup>: New
2079 declaration.
2080 (tic6x_arch_setup): Turn into ...
2081 (tic6x_target::low_arch_setup): ...this.
2082 (the_low_target): Remove the op field.
2083 * linux-tile-low.cc (class tile_target) <low_arch_setup>: New
2084 declaration.
2085 (tile_arch_setup): Turn into ...
2086 (tile_target::low_arch_setup): ...this.
2087 (the_low_target): Remove the op field.
2088 * linux-xtensa-low.cc (class xtensa_target) <low_arch_setup>: New
2089 declaration.
2090 (xtensa_arch_setup): Turn into ...
2091 (xtensa_target::low_arch_setup): ...this.
2092 (the_low_target): Remove the op field.
2093
2094 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2095
2096 * linux-low.h (the_linux_target): New extern declaration.
2097 * linux-low.cc (initialize_low): Use 'the_linux_target' to set
2098 'the_target'.
2099 (the_linux_target): Remove.
2100 * linux-x86-low.cc (class x86_target): New class.
2101 (the_x86_target): New static object.
2102 (the_linux_target): Define as pointer to the_x86_target.
2103 * linux-aarch64-low.cc (class aarch64_target): New class.
2104 (the_aarch64_target): New static object.
2105 (the_linux_target): Define as pointer to the_aarch64_target.
2106 * linux-arm-low.cc (class arm_target): New class.
2107 (the_arm_target): New static object.
2108 (the_linux_target): Define as pointer to the_arm_target.
2109 * linux-bfin-low.cc (class bfin_target): New class.
2110 (the_bfin_target): New static object.
2111 (the_linux_target): Define as pointer to the_bfin_target.
2112 * linux-cris-low.cc (class cris_target): New class.
2113 (the_cris_target): New static object.
2114 (the_linux_target): Define as pointer to the_cris_target.
2115 * linux-crisv32-low.cc (class crisv32_target): New class.
2116 (the_crisv32_target): New static object.
2117 (the_linux_target): Define as pointer to the_crisv32_target.
2118 * linux-ia64-low.cc (class ia64_target): New class.
2119 (the_ia64_target): New static object.
2120 (the_linux_target): Define as pointer to the_ia64_target.
2121 * linux-m32r-low.cc (class m32r_target): New class.
2122 (the_m32r_target): New static object.
2123 (the_linux_target): Define as pointer to the_m32r_target.
2124 * linux-m68k-low.cc (class m68k_target): New class.
2125 (the_m68k_target): New static object.
2126 (the_linux_target): Define as pointer to the_m68k_target.
2127 * linux-mips-low.cc (class mips_target): New class.
2128 (the_mips_target): New static object.
2129 (the_linux_target): Define as pointer to the_mips_target.
2130 * linux-nios2-low.cc (class nios2_target): New class.
2131 (the_nios2_target): New static object.
2132 (the_linux_target): Define as pointer to the_nios2_target.
2133 * linux-ppc-low.cc (class ppc_target): New class.
2134 (the_ppc_target): New static object.
2135 (the_linux_target): Define as pointer to the_ppc_target.
2136 * linux-riscv-low.cc (class riscv_target): New class.
2137 (the_riscv_target): New static object.
2138 (the_linux_target): Define as pointer to the_riscv_target.
2139 * linux-s390-low.cc (class s390_target): New class.
2140 (the_s390_target): New static object.
2141 (the_linux_target): Define as pointer to the_s390_target.
2142 * linux-sh-low.cc (class sh_target): New class.
2143 (the_sh_target): New static object.
2144 (the_linux_target): Define as pointer to the_sh_target.
2145 * linux-sparc-low.cc (class sparc_target): New class.
2146 (the_sparc_target): New static object.
2147 (the_linux_target): Define as pointer to the_sparc_target.
2148 * linux-tic6x-low.cc (class tic6x_target): New class.
2149 (the_tic6x_target): New static object.
2150 (the_linux_target): Define as pointer to the_tic6x_target.
2151 * linux-tile-low.cc (class tile_target): New class.
2152 (the_tile_target): New static object.
2153 (the_linux_target): Define as pointer to the_tile_target.
2154 * linux-xtensa-low.cc (class xtensa_target): New class.
2155 (the_xtensa_target): New static object.
2156 (the_linux_target): Define as pointer to the_xtensa_target.
2157
2158 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2159
2160 Turn some static functions in linux-low.cc into private methods of
2161 linux_process_target.
2162
2163 * linux-low.cc (handle_extended_wait): Turn into ...
2164 (linux_process_target::handle_extended_wait): ...this. Call
2165 'mourn' on 'this' object instead of 'the_target'.
2166 (maybe_move_out_of_jump_pad): Turn into...
2167 (linux_process_target::maybe_move_out_of_jump_pad): ...this.
2168 (linux_low_filter_event): Turn into...
2169 (linux_process_target::filter_event): ...this.
2170 (linux_wait_for_event_filtered): Turn into...
2171 (linux_process_target::wait_for_event_filtered): ...this.
2172 (linux_wait_for_event): Turn into...
2173 (linux_process_target::wait_for_event): ...this.
2174 (linux_wait_1): Turn into...
2175 (linux_process_target::wait_1): ...this.
2176 (wait_for_sigstop): Turn into...
2177 (linux_process_target::wait_for_sigstop): ...this.
2178 (move_out_of_jump_pad_callback): Turn into...
2179 (linux_process_target::move_out_of_jump_pad): ...this.
2180 (stop_all_lwps): Turn into...
2181 (linux_process_target::stop_all_lwps): ...this.
2182 (start_step_over): Turn into...
2183 (linux_process_target::start_step_over): ...this.
2184 (complete_ongoing_step_over): Turn into...
2185 (linux_process_target::complete_ongoing_step_over): ...this.
2186 (proceed_all_lwps): Turn into...
2187 (linux_process_target::proceed_all_lwps): ...this.
2188 (unstop_all_lwps): Turn into...
2189 (linux_process_target::unstop_all_lwps): ...this.
2190
2191 * linux-low.h (class linux_process_target)
2192 <handle_extended_wait>
2193 <maybe_move_out_of_jump_pad>
2194 filter_event>
2195 <wait_for_event_filtered>
2196 <wait_for_event>
2197 <wait_1>
2198 <wait_for_sigstop>
2199 <move_out_of_jump_pad>
2200 <stop_all_lwps>
2201 <start_step_over>
2202 <complete_ongoing_step_over>
2203 <proceed_all_lwps>
2204 <unstop_all_lwps>: Declare.
2205
2206 Update the callers below.
2207
2208 * linux-low.cc (linux_process_target::attach): Update.
2209 (linux_process_target::stabilize_threads): Ditto.
2210 (linux_process_target::wait): Ditto.
2211
2212 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2213
2214 * linux-low.h (struct linux_target_ops): Update the comment for
2215 'cannot_store_register' to return 0 or 1.
2216 * linux-ppc-low.cc (ppc_cannot_store_register): Return 1 instead
2217 of 2.
2218
2219 2020-03-20 Simon Marchi <simon.marchi@efficios.com>
2220
2221 * config.in: Re-generate.
2222 * configure: Re-generate.
2223
2224 2020-03-17 Kamil Rytarowski <n54@gmx.com>
2225
2226 * regcache.cc (find_register_by_number): Update.
2227 * tdesc.cc (init_target_desc): Likewise.
2228 * tdesc.h (target_desc::reg_defs): Likewise.
2229
2230 2020-03-12 Tom Tromey <tom@tromey.com>
2231
2232 * configure: Rebuild.
2233 * configure.ac (GDBSERVER_DEPFILES): Remove srv_selftest_objs.
2234 (WIN32APILIBS): New subst.
2235 * Makefile.in (SFILES, OBS, TAGS, GDBREPLAY_OBS): Remove
2236 gdbsupport files.
2237 (gdbsupport/%.o): Remove target.
2238 (GDBSUPPORT_BUILDDIR, GDBSUPPORT): New variables.
2239 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Add GDBSUPPORT.
2240 (WIN32APILIBS): New variable.
2241 (gdbserver$(EXEEXT)): Add WIN32APILIBS.
2242 (gdbreplay$(EXEEXT)): Likewise.
2243
2244 2020-03-12 Tom Tromey <tom@tromey.com>
2245
2246 * config.in, configure: Rebuild.
2247 * configure.ac: Call ZW_GNU_GETTEXT_SISTER_DIR.
2248 * acinclude.m4: Include gettext-sister.m4.
2249 * Makefile.in (top_builddir, INTL, INTL_DEPS, INTL_CFLAGS): New
2250 variables.
2251 (INCLUDE_CFLAGS): Add INTL_CFLAGS.
2252 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Use INTL_DEPS, INTL.
2253
2254 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
2255
2256 * acinclude.m4: Update path to selftest.m4.
2257
2258 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
2259
2260 * configure.ac: Don't source bfd/development.sh, move
2261 GDB_AC_COMMON higher.
2262 * configure: Re-generate.
2263
2264 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
2265
2266 * configure: Re-generate.
2267
2268 2020-03-11 Simon Marchi <simon.marchi@efficios.com>
2269
2270 * configure: Re-generate.
2271
2272 2020-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
2273
2274 * .dir-locals.el: New file.
2275
2276 2020-03-05 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2277
2278 * .gitattributes: New file.
2279
2280 2020-03-02 Andrew Burgess <andrew.burgess@embecosm.com>
2281
2282 * remote-utils.cc (prepare_resume_reply): Add ability to convert T
2283 reply into an S reply.
2284 * server.cc (disable_packet_T): New global.
2285 (captured_main): Set new global when appropriate.
2286 * server.h (disable_packet_T): Declare.
2287
2288 2020-02-21 Tom Tromey <tom@tromey.com>
2289
2290 * Makefile.in (mostlyclean): New target.
2291
2292 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2293
2294 * target.h (struct process_stratum_target): Remove.
2295 (class process_target): Rename to ...
2296 (class process_stratum_target): ... this.
2297 * linux-low.h (class linux_process_target): Derive from
2298 'process_stratum_target'.
2299 * linux-low.cc (linux_target_ops): Remove.
2300 (initialize_low): Set the_target to the singleton instance of
2301 linux_process_target.
2302 * lynx-low.h (class lynx_process_target): Derive from
2303 'process_stratum_target'.
2304 * lynx-low.cc (lynx_target_ops): Remove.
2305 (initialize_low): Set the_target to the singleton instance of
2306 lynx_process_target.
2307 * nto-low.h (class nto_process_target): Derive from
2308 'process_stratum_target'.
2309 * nto-low.cc (nto_target_ops): Remove.
2310 (initialize_low): Set the_target to the singleton instance of
2311 nto_process_target.
2312 * win32-low.h (class win32_process_target): Derive from
2313 'process_stratum_target'.
2314 * win32-low.cc (win32_target_ops): Remove.
2315 (initialize_low): Set the_target to the singleton instance of
2316 win32_process_target.
2317
2318 Replace 'the_target->pt' with 'the_target' in the uses below.
2319
2320 * hostio.cc (hostio_error)
2321 (handle_setfs)
2322 (handle_open)
2323 (handle_unlink)
2324 (handle_readlink)
2325 * linux-aarch32-low.cc (arm_breakpoint_at)
2326 * linux-aarch64-low.cc (aarch64_breakpoint_at)
2327 * linux-arm-low.cc (arm_sigreturn_next_pc)
2328 (arm_get_hwcap)
2329 (arm_get_syscall_trapinfo)
2330 * linux-cris-low.cc (cris_breakpoint_at)
2331 * linux-crisv32-low.cc (cris_breakpoint_at)
2332 * linux-low.cc (handle_extended_wait)
2333 (linux_wait_1)
2334 (linux_read_memory)
2335 (linux_process_target::breakpoint_kind_from_pc)
2336 (linux_get_auxv)
2337 * linux-m32r-low.cc (m32r_breakpoint_at)
2338 * linux-mips-low.cc (mips_breakpoint_at)
2339 * linux-nios2-low.cc (nios2_breakpoint_at)
2340 * linux-ppc-low.cc (ppc_breakpoint_at)
2341 * linux-s390-low.cc (s390_get_hwcap)
2342 * linux-sh-low.cc (sh_breakpoint_at)
2343 * linux-sparc-low.cc (sparc_fill_gregset_to_stack)
2344 (sparc_store_gregset_from_stack)
2345 (sparc_breakpoint_at)
2346 * linux-tic6x-low.cc (tic6x_breakpoint_at)
2347 * linux-tile-low.cc (tile_breakpoint_at)
2348 * linux-x86-low.cc (x86_breakpoint_at)
2349 * linux-xtensa-low.cc (xtensa_breakpoint_at)
2350 * mem-break.cc (bp_size)
2351 (bp_opcode)
2352 (insert_memory_breakpoint)
2353 (set_raw_breakpoint_at)
2354 (delete_raw_breakpoint)
2355 (z_type_supported)
2356 (uninsert_raw_breakpoint)
2357 (reinsert_raw_breakpoint)
2358 (validate_inserted_breakpoint)
2359 * regcache.cc (regcache_read_pc)
2360 (regcache_write_pc)
2361 * remote-utils.cc (putpkt_binary_1)
2362 (input_interrupt)
2363 (getpkt)
2364 (prepare_resume_reply)
2365 * server.cc (handle_general_set)
2366 (handle_detach)
2367 (handle_qxfer_auxv)
2368 (handle_qxfer_exec_file)
2369 (handle_qxfer_libraries_svr4)
2370 (handle_qxfer_osdata)
2371 (handle_qxfer_siginfo)
2372 (handle_qxfer_fdpic)
2373 (handle_query)
2374 (resume)
2375 (handle_v_requests)
2376 (queue_stop_reply_callback)
2377 (captured_main)
2378 * target.cc (prepare_to_access_memory)
2379 (done_accessing_memory)
2380 (read_inferior_memory)
2381 (target_write_memory)
2382 (target_stop_and_wait)
2383 (target_wait)
2384 (target_mourn_inferior)
2385 (target_continue_no_signal)
2386 (target_continue)
2387 (target_supports_multi_process)
2388 (kill_inferior)
2389 * target.h
2390 (target_create_inferior)
2391 (target_post_create_inferior)
2392 (myattach)
2393 (target_supports_fork_events)
2394 (target_supports_vfork_events)
2395 (target_supports_exec_events)
2396 (target_handle_new_gdb_connection)
2397 (detach_inferior)
2398 (mythread_alive)
2399 (fetch_inferior_registers)
2400 (store_inferior_registers)
2401 (join_inferior)
2402 (target_supports_non_stop)
2403 (target_async)
2404 (target_process_qsupported)
2405 (target_supports_catch_syscall)
2406 (target_get_ipa_tdesc_idx)
2407 (target_supports_tracepoints)
2408 (target_supports_fast_tracepoints)
2409 (target_get_min_fast_tracepoint_insn_len)
2410 (target_thread_stopped)
2411 (target_pause_all)
2412 (target_unpause_all)
2413 (target_stabilize_threads)
2414 (target_install_fast_tracepoint_jump_pad)
2415 (target_emit_ops)
2416 (target_supports_disable_randomization)
2417 (target_supports_agent)
2418 (target_enable_btrace)
2419 (target_disable_btrace)
2420 (target_read_btrace)
2421 (target_read_btrace_conf)
2422 (target_supports_range_stepping)
2423 (target_supports_stopped_by_sw_breakpoint)
2424 (target_stopped_by_sw_breakpoint)
2425 (target_supports_stopped_by_hw_breakpoint)
2426 (target_supports_hardware_single_step)
2427 (target_stopped_by_hw_breakpoint)
2428 (target_breakpoint_kind_from_pc)
2429 (target_breakpoint_kind_from_current_state)
2430 (target_supports_software_single_step)
2431 (target_core_of_thread)
2432 (target_thread_name)
2433 (target_thread_handle)
2434 * win32-low.cc (do_initial_child_stuff)
2435
2436 Rename target op default definitions listed below.
2437
2438 * target.cc (process_target::post_create_inferior): Rename as ...
2439 (process_stratum_target::post_create_inferior): ... this.
2440 (process_target::prepare_to_access_memory): Rename as ...
2441 (process_stratum_target::prepare_to_access_memory): ... this.
2442 (process_target::done_accessing_memory): Rename as ...
2443 (process_stratum_target::done_accessing_memory): ... this.
2444 (process_target::look_up_symbols): Rename as ...
2445 (process_stratum_target::look_up_symbols): ... this.
2446 (process_target::supports_read_auxv): Rename as ...
2447 (process_stratum_target::supports_read_auxv): ... this.
2448 (process_target::read_auxv): Rename as ...
2449 (process_stratum_target::read_auxv): ... this.
2450 (process_target::supports_z_point_type): Rename as ...
2451 (process_stratum_target::supports_z_point_type): ... this.
2452 (process_target::insert_point): Rename as ...
2453 (process_stratum_target::insert_point): ... this.
2454 (process_target::remove_point): Rename as ...
2455 (process_stratum_target::remove_point): ... this.
2456 (process_target::stopped_by_sw_breakpoint): Rename as ...
2457 (process_stratum_target::stopped_by_sw_breakpoint): ... this.
2458 (process_target::supports_stopped_by_sw_breakpoint): Rename as ...
2459 (process_stratum_target::supports_stopped_by_sw_breakpoint): ... this.
2460 (process_target::stopped_by_hw_breakpoint): Rename as ...
2461 (process_stratum_target::stopped_by_hw_breakpoint): ... this.
2462 (process_target::supports_stopped_by_hw_breakpoint): Rename as ...
2463 (process_stratum_target::supports_stopped_by_hw_breakpoint): ... this.
2464 (process_target::supports_hardware_single_step): Rename as ...
2465 (process_stratum_target::supports_hardware_single_step): ... this.
2466 (process_target::stopped_by_watchpoint): Rename as ...
2467 (process_stratum_target::stopped_by_watchpoint): ... this.
2468 (process_target::stopped_data_address): Rename as ...
2469 (process_stratum_target::stopped_data_address): ... this.
2470 (process_target::supports_read_offsets): Rename as ...
2471 (process_stratum_target::supports_read_offsets): ... this.
2472 (process_target::read_offsets): Rename as ...
2473 (process_stratum_target::read_offsets): ... this.
2474 (process_target::supports_get_tls_address): Rename as ...
2475 (process_stratum_target::supports_get_tls_address): ... this.
2476 (process_target::get_tls_address): Rename as ...
2477 (process_stratum_target::get_tls_address): ... this.
2478 (process_target::hostio_last_error): Rename as ...
2479 (process_stratum_target::hostio_last_error): ... this.
2480 (process_target::supports_qxfer_osdata): Rename as ...
2481 (process_stratum_target::supports_qxfer_osdata): ... this.
2482 (process_target::qxfer_osdata): Rename as ...
2483 (process_stratum_target::qxfer_osdata): ... this.
2484 (process_target::supports_qxfer_siginfo): Rename as ...
2485 (process_stratum_target::supports_qxfer_siginfo): ... this.
2486 (process_target::qxfer_siginfo): Rename as ...
2487 (process_stratum_target::qxfer_siginfo): ... this.
2488 (process_target::supports_non_stop): Rename as ...
2489 (process_stratum_target::supports_non_stop): ... this.
2490 (process_target::async): Rename as ...
2491 (process_stratum_target::async): ... this.
2492 (process_target::start_non_stop): Rename as ...
2493 (process_stratum_target::start_non_stop): ... this.
2494 (process_target::supports_multi_process): Rename as ...
2495 (process_stratum_target::supports_multi_process): ... this.
2496 (process_target::supports_fork_events): Rename as ...
2497 (process_stratum_target::supports_fork_events): ... this.
2498 (process_target::supports_vfork_events): Rename as ...
2499 (process_stratum_target::supports_vfork_events): ... this.
2500 (process_target::supports_exec_events): Rename as ...
2501 (process_stratum_target::supports_exec_events): ... this.
2502 (process_target::handle_new_gdb_connection): Rename as ...
2503 (process_stratum_target::handle_new_gdb_connection): ... this.
2504 (process_target::handle_monitor_command): Rename as ...
2505 (process_stratum_target::handle_monitor_command): ... this.
2506 (process_target::core_of_thread): Rename as ...
2507 (process_stratum_target::core_of_thread): ... this.
2508 (process_target::supports_read_loadmap): Rename as ...
2509 (process_stratum_target::supports_read_loadmap): ... this.
2510 (process_target::read_loadmap): Rename as ...
2511 (process_stratum_target::read_loadmap): ... this.
2512 (process_target::process_qsupported): Rename as ...
2513 (process_stratum_target::process_qsupported): ... this.
2514 (process_target::supports_tracepoints): Rename as ...
2515 (process_stratum_target::supports_tracepoints): ... this.
2516 (process_target::read_pc): Rename as ...
2517 (process_stratum_target::read_pc): ... this.
2518 (process_target::write_pc): Rename as ...
2519 (process_stratum_target::write_pc): ... this.
2520 (process_target::supports_thread_stopped): Rename as ...
2521 (process_stratum_target::supports_thread_stopped): ... this.
2522 (process_target::thread_stopped): Rename as ...
2523 (process_stratum_target::thread_stopped): ... this.
2524 (process_target::supports_get_tib_address): Rename as ...
2525 (process_stratum_target::supports_get_tib_address): ... this.
2526 (process_target::get_tib_address): Rename as ...
2527 (process_stratum_target::get_tib_address): ... this.
2528 (process_target::pause_all): Rename as ...
2529 (process_stratum_target::pause_all): ... this.
2530 (process_target::unpause_all): Rename as ...
2531 (process_stratum_target::unpause_all): ... this.
2532 (process_target::stabilize_threads): Rename as ...
2533 (process_stratum_target::stabilize_threads): ... this.
2534 (process_target::supports_fast_tracepoints): Rename as ...
2535 (process_stratum_target::supports_fast_tracepoints): ... this.
2536 (process_target::get_min_fast_tracepoint_insn_len): Rename as ...
2537 (process_stratum_target::get_min_fast_tracepoint_insn_len): ... this.
2538 (process_target::emit_ops): Rename as ...
2539 (process_stratum_target::emit_ops): ... this.
2540 (process_target::supports_disable_randomization): Rename as ...
2541 (process_stratum_target::supports_disable_randomization): ... this.
2542 (process_target::supports_qxfer_libraries_svr4): Rename as ...
2543 (process_stratum_target::supports_qxfer_libraries_svr4): ... this.
2544 (process_target::qxfer_libraries_svr4): Rename as ...
2545 (process_stratum_target::qxfer_libraries_svr4): ... this.
2546 (process_target::supports_agent): Rename as ...
2547 (process_stratum_target::supports_agent): ... this.
2548 (process_target::enable_btrace): Rename as ...
2549 (process_stratum_target::enable_btrace): ... this.
2550 (process_target::disable_btrace): Rename as ...
2551 (process_stratum_target::disable_btrace): ... this.
2552 (process_target::read_btrace): Rename as ...
2553 (process_stratum_target::read_btrace): ... this.
2554 (process_target::read_btrace_conf): Rename as ...
2555 (process_stratum_target::read_btrace_conf): ... this.
2556 (process_target::supports_range_stepping): Rename as ...
2557 (process_stratum_target::supports_range_stepping): ... this.
2558 (process_target::supports_pid_to_exec_file): Rename as ...
2559 (process_stratum_target::supports_pid_to_exec_file): ... this.
2560 (process_target::pid_to_exec_file): Rename as ...
2561 (process_stratum_target::pid_to_exec_file): ... this.
2562 (process_target::supports_multifs): Rename as ...
2563 (process_stratum_target::supports_multifs): ... this.
2564 (process_target::multifs_open): Rename as ...
2565 (process_stratum_target::multifs_open): ... this.
2566 (process_target::multifs_unlink): Rename as ...
2567 (process_stratum_target::multifs_unlink): ... this.
2568 (process_target::multifs_readlink): Rename as ...
2569 (process_stratum_target::multifs_readlink): ... this.
2570 (process_target::breakpoint_kind_from_pc): Rename as ...
2571 (process_stratum_target::breakpoint_kind_from_pc): ... this.
2572 (process_target::breakpoint_kind_from_current_state): Rename as ...
2573 (process_stratum_target::breakpoint_kind_from_current_state): ... this.
2574 (process_target::thread_name): Rename as ...
2575 (process_stratum_target::thread_name): ... this.
2576 (process_target::thread_handle): Rename as ...
2577 (process_stratum_target::thread_handle): ... this.
2578 (process_target::supports_software_single_step): Rename as ...
2579 (process_stratum_target::supports_software_single_step): ... this.
2580 (process_target::supports_catch_syscall): Rename as ...
2581 (process_stratum_target::supports_catch_syscall): ... this.
2582 (process_target::get_ipa_tdesc_idx): Rename as ...
2583 (process_stratum_target::get_ipa_tdesc_idx): ... this.
2584
2585 2020-02-20 Pedro Alves <palves@redhat.com>
2586
2587 * target.cc (set_target_ops): Simply copy the given target pointer
2588 instead of creating a copy of the pointed object.
2589
2590 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2591
2592 Turn process_stratum_target's get_ipa_tdesc_idx op into a method
2593 of process_target.
2594
2595 * target.h (struct process_stratum_target): Remove the target op.
2596 (class process_target): Add the target op.
2597 (target_get_ipa_tdesc_idx): Update the macro.
2598 * target.cc (process_target::get_ipa_tdesc_idx): Define.
2599
2600 Update the derived classes and callers below.
2601
2602 * linux-low.cc (linux_target_ops): Update.
2603 (linux_get_ipa_tdesc_idx): Turn into ...
2604 (linux_process_target::get_ipa_tdesc_idx): ... this.
2605 * linux-low.h (class linux_process_target): Update.
2606 * lynx-low.cc (lynx_target_ops): Update.
2607 * nto-low.cc (nto_target_ops): Update.
2608 * win32-low.cc (win32_target_ops): Update.
2609
2610 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2611
2612 Turn process_stratum_target's supports_catch_syscall op into a
2613 method of process_target.
2614
2615 * target.h (struct process_stratum_target): Remove the target op.
2616 (class process_target): Add the target op.
2617 (target_supports_catch_syscall): Update the macro.
2618 * target.cc (process_target::supports_catch_syscall): Define.
2619
2620 Update the derived classes and callers below.
2621
2622 * linux-low.cc (linux_target_ops): Update.
2623 (linux_supports_catch_syscall): Turn into ...
2624 (linux_process_target::supports_catch_syscall): ... this.
2625 * linux-low.h (class linux_process_target): Update.
2626 * lynx-low.cc (lynx_target_ops): Update.
2627 * nto-low.cc (nto_target_ops): Update.
2628 * win32-low.cc (win32_target_ops): Update.
2629
2630 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2631
2632 Turn process_stratum_target's supports_software_single_step op
2633 into a method of process_target.
2634
2635 * target.h (struct process_stratum_target): Remove the target op.
2636 (class process_target): Add the target op.
2637 (target_supports_software_single_step): Update the macro.
2638 * target.cc (process_target::supports_software_single_step): Define.
2639
2640 Update the derived classes and callers below.
2641
2642 * linux-low.cc (linux_target_ops): Update.
2643 (linux_supports_software_single_step): Turn into ...
2644 (linux_process_target::supports_software_single_step): ... this.
2645 * linux-low.h (class linux_process_target): Update.
2646 * lynx-low.cc (lynx_target_ops): Update.
2647 * nto-low.cc (nto_target_ops): Update.
2648 * win32-low.cc (win32_target_ops): Update.
2649
2650 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2651
2652 Turn process_stratum_target's thread_name and thread_handle ops
2653 into methods of process_target.
2654
2655 * target.h (struct process_stratum_target): Remove the target ops.
2656 (class process_target): Add the target ops.
2657 (target_thread_name): Update the macro.
2658 (target_thread_handle): Update the macro.
2659 * target.cc (process_target::thread_name): Define.
2660 (process_target::thread_handle): Define.
2661
2662 Update the derived classes and callers below.
2663
2664 * linux-low.cc (linux_target_ops): Update.
2665 (linux_process_target::thread_name): Define.
2666 (linux_process_target::thread_handle): Define.
2667 * linux-low.h (class linux_process_target): Update.
2668 * lynx-low.cc (lynx_target_ops): Update.
2669 * nto-low.cc (nto_target_ops): Update.
2670 * win32-low.cc (win32_target_ops): Update.
2671
2672 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2673
2674 Turn process_stratum_target's breakpoint_kind_from_pc,
2675 sw_breakpoint_from_kind, and breakpoint_kind_from_current_state
2676 ops into methods of process_target.
2677
2678 * target.h (struct process_stratum_target): Remove the target op.
2679 (class process_target): Add the target op.
2680 (target_breakpoint_kind_from_pc): Update the macro.
2681 (target_breakpoint_kind_from_current_state): Update the macro.
2682 (default_breakpoint_kind_from_pc): Remove declaration.
2683 * target.cc (default_breakpoint_kind_from_pc): Turn into ...
2684 (process_target::breakpoint_kind_from_pc): ... this.
2685 (process_target::breakpoint_kind_from_current_state): Define.
2686
2687 Update the derived classes and callers below.
2688
2689 * mem-break.cc (bp_size): Update.
2690 (bp_opcode): Update.
2691 * linux-low.cc (linux_target_ops): Update.
2692 (linux_wait_1): Update.
2693 (linux_breakpoint_kind_from_pc): Turn into ...
2694 (linux_process_target::breakpoint_kind_from_pc): ... this.
2695 (linux_sw_breakpoint_from_kind): Turn into ...
2696 (linux_process_target::sw_breakpoint_from_kind): ... this.
2697 (linux_breakpoint_kind_from_current_state): Turn into ...
2698 (linux_process_target::breakpoint_kind_from_current_state): ... this.
2699 * linux-low.h (class linux_process_target): Update.
2700 * lynx-low.cc (lynx_target_ops): Update.
2701 (lynx_process_target::sw_breakpoint_from_kind): Define.
2702 * lynx-low.h (class lynx_process_target): Update.
2703 * nto-low.cc (nto_target_ops): Update.
2704 (nto_sw_breakpoint_from_kind): Turn into ...
2705 (nto_process_target::sw_breakpoint_from_kind): ... this.
2706 * nto-low.h (class nto_process_target): Update.
2707 * win32-low.cc (win32_target_ops): Update.
2708 (win32_sw_breakpoint_from_kind): Turn into ...
2709 (win32_process_target::sw_breakpoint_from_kind): ... this.
2710 * win32-low.h (class win32_process_target): Update.
2711
2712 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2713
2714 Turn process_stratum_target's multifs_open, multifs_readlink,
2715 multifs_unlink ops into methods of process_target.
2716
2717 * target.h (struct process_stratum_target): Remove the target ops.
2718 (class process_target): Add the target ops. Also add
2719 'supports_multifs'.
2720 * target.cc: Include "fcntl.h", "unistd.h", "sys/types.h", and
2721 "sys/stat.h".
2722 (process_target::supports_multifs): Define.
2723 (process_target::multifs_open): Define.
2724 (process_target::multifs_readlink): Define.
2725 (process_target::multifs_unlink): Define.
2726
2727 Update the derived classes and callers below.
2728
2729 * hostio.cc (handle_setfs): Update.
2730 (handle_open): Update.
2731 (handle_unlink): Update.
2732 (handle_readlink): Update.
2733 * linux-low.cc (linux_target_ops): Update.
2734 (linux_process_target::supports_multifs): Define.
2735 (linux_process_target::multifs_open): Define.
2736 (linux_process_target::multifs_readlink): Define.
2737 (linux_process_target::multifs_unlink): Define.
2738 * linux-low.h (class linux_process_target): Update.
2739 * lynx-low.cc (lynx_target_ops): Update.
2740 * nto-low.cc (nto_target_ops): Update.
2741 * win32-low.cc (win32_target_ops): Update.
2742
2743 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2744
2745 Turn process_stratum_target's pid_to_exec_file op into a method
2746 of process_target.
2747
2748 * target.h (struct process_stratum_target): Remove the target op.
2749 (class process_target): Add the target op. Also add
2750 'supports_pid_to_exec_file'.
2751 * target.cc (process_target::pid_to_exec_file): Define.
2752 (process_target::supports_pid_to_exec_file): Define.
2753
2754 Update the derived classes and callers below.
2755
2756 * server.cc (handle_qxfer_exec_file): Update.
2757 (handle_query): Update.
2758 * linux-low.cc (linux_target_ops): Update.
2759 (linux_process_target::supports_pid_to_exec_file): Define.
2760 (linux_process_target::pid_to_exec_file): Define.
2761 * linux-low.h (class linux_process_target): Update.
2762 * lynx-low.cc (lynx_target_ops): Update.
2763 * nto-low.cc (nto_target_ops): Update.
2764 * win32-low.cc (win32_target_ops): Update.
2765
2766 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2767
2768 Turn process_stratum_target's supports_range_stepping op into a
2769 method of process_target.
2770
2771 * target.h (struct process_stratum_target): Remove the target op.
2772 (class process_target): Add the target op.
2773 (target_supports_range_stepping): Update the macro.
2774 * target.cc (process_target::supports_range_stepping): Define.
2775
2776 Update the derived classes and callers below.
2777
2778 * linux-low.cc (linux_target_ops): Update.
2779 (linux_supports_range_stepping): Turn into ...
2780 (linux_process_target::supports_range_stepping): ... this.
2781 * linux-low.h (class linux_process_target): Update.
2782 * lynx-low.cc (lynx_target_ops): Update.
2783 * nto-low.cc (nto_target_ops): Update.
2784 * win32-low.cc (win32_target_ops): Update.
2785
2786 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2787
2788 Turn process_stratum_target's btrace-related ops (enable_btrace,
2789 disable_btrace, read_btrace, read_btrace_conf) into methods of
2790 process_target.
2791
2792 * target.h (struct process_stratum_target): Remove the target ops.
2793 (class process_target): Add the target ops.
2794 (target_enable_btrace): Update.
2795 (target_disable_btrace): Update.
2796 (target_read_btrace): Update.
2797 (target_read_btrace_conf): Update.
2798 * target.cc (process_target::enable_btrace): Define.
2799 (process_target::disable_btrace): Define.
2800 (process_target::read_btrace): Define.
2801 (process_target::read_btrace_conf): Define.
2802
2803 Update the derived classes and callers below.
2804
2805 * linux-low.cc (linux_target_ops): Update.
2806 (linux_process_target:enable_btrace): Define as a wrapper around
2807 linux_enable_btrace.
2808 (linux_low_disable_btrace): Turn into ...
2809 (linux_process_target::disable_btrace): ... this.
2810 (linux_low_read_btrace): Turn into ...
2811 (linux_process_target::read_btrace): ... this.
2812 (linux_low_btrace_conf): Turn into ...
2813 (linux_process_target::read_btrace_conf): ... this.
2814 * linux-low.h (class linux_process_target): Update.
2815 * lynx-low.cc (lynx_target_ops): Update.
2816 * nto-low.cc (nto_target_ops): Update.
2817 * win32-low.cc (win32_target_ops): Update.
2818
2819 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2820
2821 Turn process_stratum_target's supports_agent op into a method of
2822 process_target.
2823
2824 * target.h (struct process_stratum_target): Remove the target op.
2825 (class process_target): Add the target op.
2826 (target_supports_agent): Update the macro.
2827 * target.cc (process_target::supports_agent): Define.
2828
2829 Update the derived classes and callers below.
2830
2831 * linux-low.cc (linux_target_ops): Update.
2832 (linux_supports_agent): Turn into ...
2833 (linux_process_target::supports_agent): ... this.
2834 * linux-low.h (class linux_process_target): Update.
2835 * lynx-low.cc (lynx_target_ops): Update.
2836 * nto-low.cc (nto_target_ops): Update.
2837 * win32-low.cc (win32_target_ops): Update.
2838
2839 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2840
2841 Turn process_stratum_target's qxfer_libraries_svr4 op into a
2842 method of process_target.
2843
2844 * target.h (struct process_stratum_target): Remove the target op.
2845 (class process_target): Add the target op. Also add
2846 'supports_qxfer_libraries_svr4'.
2847 * target.cc (process_target::qxfer_libraries_svr4): Define.
2848 (process_target::supports_qxfer_libraries_svr4): Define.
2849
2850 Update the derived classes and callers below.
2851
2852 * server.cc (handle_qxfer_libraries_svr4): Update.
2853 (handle_query): Update.
2854 * linux-low.cc (linux_target_ops): Update.
2855 (linux_process_target::supports_qxfer_libraries_svr4): Define.
2856 (linux_qxfer_libraries_svr4): Turn into ...
2857 (linux_process_target::qxfer_libraries_svr4): ... this.
2858 * linux-low.h (class linux_process_target): Update.
2859 * lynx-low.cc (lynx_target_ops): Update.
2860 * nto-low.cc (nto_target_ops): Update.
2861 * win32-low.cc (win32_target_ops): Update.
2862
2863 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2864
2865 Turn process_stratum_target's supports_disable_randomization op
2866 into a method of process_target.
2867
2868 * target.h (struct process_stratum_target): Remove the target op.
2869 (class process_target): Add the target op.
2870 (target_supports_disable_randomization): Update the macro.
2871 * target.cc (process_target::supports_disable_randomization): Define.
2872
2873 Update the derived classes and callers below.
2874
2875 * linux-low.cc (linux_target_ops): Update.
2876 (linux_supports_disable_randomization): Turn into ...
2877 (linux_process_target::supports_disable_randomization): ... this.
2878 * linux-low.h (class linux_process_target): Update.
2879 * lynx-low.cc (lynx_target_ops): Update.
2880 * nto-low.cc (nto_target_ops): Update.
2881 * win32-low.cc (win32_target_ops): Update.
2882
2883 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2884
2885 Turn process_stratum_target's emit_ops op into a method of
2886 process_target.
2887
2888 * target.h (struct process_stratum_target): Remove the target op.
2889 (class process_target): Add the target op.
2890 (target_emit_ops): Update the macro.
2891 * target.cc (process_target::emit_ops): Define.
2892
2893 Update the derived classes and callers below.
2894
2895 * linux-low.cc (linux_target_ops): Update.
2896 (linux_emit_ops): Turn into ...
2897 (linux_process_target::emit_ops): ... this.
2898 * linux-low.h (class linux_process_target): Update.
2899 * lynx-low.cc (lynx_target_ops): Update.
2900 * nto-low.cc (nto_target_ops): Update.
2901 * win32-low.cc (win32_target_ops): Update.
2902
2903 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2904
2905 Turn process_stratum_target's install_fast_tracepoint_jump_pad
2906 and get_min_fast_tracepoint_insn_len ops into methods of
2907 process_target.
2908
2909 * target.h (struct process_stratum_target): Remove the target ops.
2910 (class process_target): Add the target ops. Also add
2911 'supports_fast_tracepoints'.
2912 (target_supports_fast_tracepoints): Update the macro.
2913 (target_get_min_fast_tracepoint_insn_len): Update the macro.
2914 (install_fast_tracepoint_jump_pad): Update and rename the macro
2915 to ...
2916 (target_install_fast_tracepoint_jump_pad): ... this.
2917 * target.cc (process_target::supports_fast_tracepoints): Define.
2918 (process_target::install_fast_tracepoint_jump_pad): Define.
2919 (process_target::get_min_fast_tracepoint_insn_len): Define.
2920
2921 Update the derived classes and callers below.
2922
2923 * tracepoint.cc (install_fast_tracepoint): Update.
2924 * linux-low.cc (linux_target_ops): Update.
2925 (linux_process_target::supports_fast_tracepoints): Define.
2926 (linux_install_fast_tracepoint_jump_pad): Turn into ...
2927 (linux_process_target::install_fast_tracepoint_jump_pad): ... this.
2928 (linux_get_min_fast_tracepoint_insn_len): Turn into ...
2929 (linux_process_target::get_min_fast_tracepoint_insn_len): ... this.
2930 * linux-low.h (class linux_process_target): Update.
2931 * lynx-low.cc (lynx_target_ops): Update.
2932 * nto-low.cc (nto_target_ops): Update.
2933 * win32-low.cc (win32_target_ops): Update.
2934
2935 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2936
2937 Turn process_stratum_target's stabilize_threads op into a
2938 method of process_target.
2939
2940 * target.h (struct process_stratum_target): Remove the target op.
2941 (class process_target): Add the target op.
2942 (target_stabilize_threads): Update the macro.
2943 * target.cc (process_target::stabilize_threads): Define.
2944
2945 Update the derived classes and callers below.
2946
2947 * server.cc (handle_status): Update.
2948 * tracepoint.cc (cmd_qtdp): Update.
2949 (cmd_qtstart): Update.
2950 * linux-low.cc (linux_target_ops): Update.
2951 (linux_stabilize_threads): Turn into ...
2952 (linux_process_target::stabilize_threads): ... this.
2953 (linux_wait_1): Update.
2954 * linux-low.h (class linux_process_target): Update.
2955 * lynx-low.cc (lynx_target_ops): Update.
2956 * nto-low.cc (nto_target_ops): Update.
2957 * win32-low.cc (win32_target_ops): Update.
2958
2959 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2960
2961 Turn process_stratum_target's pause_all and unpause_all ops
2962 into methods of process_target.
2963
2964 * target.h (struct process_stratum_target): Remove the target ops.
2965 (class process_target): Add the target ops.
2966 (pause_all): Update the macro and rename to...
2967 (target_pause_all): ... this.
2968 (unpause_all): Update the macro and rename to...
2969 (target_unpause_all): ... this.
2970 * target.cc (process_target::pause_all): Define.
2971 (process_target::unpause_all): Define.
2972
2973 Update the derived classes and callers below.
2974
2975 * server.cc (handle_status): Update.
2976 * tracepoint.cc (clear_installed_tracepoints): Update.
2977 (cmd_qtdp): Update.
2978 (cmd_qtstart): Update.
2979 (stop_tracing): Update.
2980 (cmd_qtstatus): Update.
2981 (upload_fast_traceframes): Update.
2982 (run_inferior_command): Update.
2983 * linux-low.cc (linux_target_ops): Update.
2984 (linux_pause_all): Turn into ...
2985 (linux_process_target::pause_all): ... this.
2986 (linux_unpause_all): Turn into ...
2987 (linux_process_target::unpause_all): ... this.
2988 (linux_process_target::prepare_to_access_memory): Update.
2989 (linux_process_target::done_accessing_memory): Update.
2990 * linux-low.h (class linux_process_target): Update.
2991 * lynx-low.cc (lynx_target_ops): Update.
2992 * nto-low.cc (nto_target_ops): Update.
2993 * win32-low.cc (win32_target_ops): Update.
2994
2995 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2996
2997 Turn process_stratum_target's get_tib_address op into a method of
2998 process_target.
2999
3000 * target.h (struct process_stratum_target): Remove the target op.
3001 (class process_target): Add the target op. Also add
3002 'supports_get_tib_address'.
3003 * target.cc (process_target::get_tib_address): Define.
3004 (process_target::supports_get_tib_address): Define.
3005
3006 Update the derived classes and callers below.
3007
3008 * server.cc (handle_query): Update.
3009 * linux-low.cc (win32_target_ops): Update.
3010 * lynx-low.cc (lynx_target_ops): Update.
3011 * nto-low.cc (nto_target_ops): Update.
3012 * win32-low.cc (win32_target_ops): Update.
3013 (win32_process_target::supports_get_tib_address): Define.
3014 (win32_get_tib_address): Turn into ...
3015 (win32_process_target::get_tib_address): ... this.
3016 * win32-low.h (class win32_process_target): Update.
3017
3018 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3019
3020 Turn process_stratum_target's thread_stopped op into a method of
3021 process_target.
3022
3023 * target.h (struct process_stratum_target): Remove the target op.
3024 (class process_target): Add the target op. Also add
3025 'supports_thread_stopped'.
3026 (target_thread_stopped): Update the macro.
3027 * target.cc (process_target::thread_stopped): Define.
3028 (process_target::supports_thread_stopped): Define.
3029 (prepare_to_access_memory): Update.
3030
3031 Update the derived classes and callers below.
3032
3033 * server.cc (queue_stop_reply_callback): Update.
3034 * linux-low.cc (linux_target_ops): Update.
3035 (linux_process_target::supports_thread_stopped): Define.
3036 (linux_thread_stopped): Turn into ...
3037 (linux_process_target::thread_stopped): ... this.
3038 * linux-low.h (class linux_process_target): Update.
3039 * lynx-low.cc (lynx_target_ops): Update.
3040 * nto-low.cc (nto_target_ops): Update.
3041 * win32-low.cc (win32_target_ops): Update.
3042
3043 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3044
3045 Turn process_stratum_target's read_pc and write_pc ops into
3046 methods of process_target.
3047
3048 * target.h (struct process_stratum_target): Remove the target ops.
3049 (class process_target): Add the target ops.
3050 * target.cc (process_target::read_pc): Define.
3051 (process_target::write_pc): Define.
3052
3053 Update the derived classes and callers below.
3054
3055 * regcache.cc (regcache_read_pc): Update.
3056 (regcache_write_pc): Update.
3057 * linux-low.cc (linux_target_ops): Update.
3058 (linux_read_pc): Turn into ...
3059 (linux_process_target::read_pc): ... this.
3060 (linux_write_pc): Turn into ...
3061 (linux_process_target::write_pc): ... this.
3062 * linux-low.h (class linux_process_target): Update.
3063 * lynx-low.cc (lynx_target_ops): Update.
3064 * nto-low.cc (nto_target_ops): Update.
3065 * win32-low.cc (win32_target_ops): Update.
3066
3067 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3068
3069 Turn process_stratum_target's supports_tracepoints op into a
3070 method of process_target.
3071
3072 * target.h (struct process_stratum_target): Remove the target op.
3073 (class process_target): Add the target op.
3074 (target_supports_tracepoints): Update the macro.
3075 * target.cc (process_target::supports_tracepoints): Define.
3076
3077 Update the derived classes and callers below.
3078
3079 * linux-low.cc (linux_target_ops): Update.
3080 (linux_supports_tracepoints): Turn into ...
3081 (linux_process_target::supports_tracepoints): ... this.
3082 * linux-low.h (class linux_process_target): Update.
3083 * lynx-low.cc (lynx_target_ops): Update.
3084 * nto-low.cc (nto_target_ops): Update.
3085 * win32-low.cc (win32_target_ops): Update.
3086
3087 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3088
3089 Turn process_stratum_target's process_qsupported op into a method
3090 of process_target.
3091
3092 * target.h (struct process_stratum_target): Remove the target op.
3093 (class process_target): Add the target op.
3094 (target_process_qsupported): Update the macro.
3095 * target.cc (process_target::process_qsupported): Define.
3096
3097 Update the derived classes and callers below.
3098
3099 * linux-low.cc (linux_target_ops): Update.
3100 (linux_process_qsupported): Turn into ...
3101 (linux_process_target::process_qsupported): ... this.
3102 * linux-low.h (class linux_process_target): Update.
3103 * lynx-low.cc (lynx_target_ops): Update.
3104 * nto-low.cc (nto_target_ops): Update.
3105 * win32-low.cc (win32_target_ops): Update.
3106
3107 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3108
3109 Turn process_stratum_target's read_loadmap op into a method of
3110 process_target.
3111
3112 * target.h (struct process_stratum_target): Remove the target op.
3113 (class process_target): Add the target op. Also add
3114 'supports_read_loadmap'.
3115 * target.cc (process_target::read_loadmap): Define.
3116 (process_target::supports_read_loadmap): Define.
3117
3118 Update the derived classes and callers below.
3119
3120 * server.cc (handle_qxfer_fdpic): Update.
3121 (handle_query): Update.
3122 * linux-low.cc (linux_target_ops): Update.
3123 (linux_process_target::supports_read_loadmap): Define.
3124 (linux_read_loadmap): Turn into ...
3125 (linux_process_target::read_loadmap): ... this.
3126 * linux-low.h (class linux_process_target): Update.
3127 * lynx-low.cc (lynx_target_ops): Update.
3128 * nto-low.cc (nto_target_ops): Update.
3129 * win32-low.cc (win32_target_ops): Update.
3130
3131 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3132
3133 Turn process_stratum_target's core_of_thread op into a method of
3134 process_target.
3135
3136 * target.h (struct process_stratum_target): Remove the target op.
3137 (class process_target): Add the target op.
3138 (target_core_of_thread): Update the macro.
3139 * target.cc (process_target::core_of_thread): Define.
3140
3141 Update the derived classes and callers below.
3142
3143 * linux-low.cc (linux_target_ops): Update.
3144 (linux_process_target::core_of_thread): Define.
3145 * linux-low.h (class linux_process_target): Update.
3146 * lynx-low.cc (lynx_target_ops): Update.
3147 * nto-low.cc (nto_target_ops): Update.
3148 * win32-low.cc (win32_target_ops): Update.
3149
3150 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3151
3152 Turn process_stratum_target's handle_monitor_command op into a
3153 method of process_target.
3154
3155 * target.h (struct process_stratum_target): Remove the target op.
3156 (class process_target): Add the target op.
3157 (target_handle_monitor_command): Update the macro.
3158 * target.cc (process_target::handle_monitor_command): Define.
3159
3160 Update the derived classes and callers below.
3161
3162 * server.cc (handle_query): Update.
3163 * linux-low.cc (linux_target_ops): Update.
3164 (linux_process_target::handle_monitor_command): Define.
3165 * linux-low.h (class linux_process_target): Update.
3166 * lynx-low.cc (lynx_target_ops): Update.
3167 * nto-low.cc (nto_target_ops): Update.
3168 * win32-low.cc (win32_target_ops): Update.
3169
3170 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3171
3172 Turn process_stratum_target's handle_new_gdb_connection op into a
3173 method of process_target.
3174
3175 * target.h (struct process_stratum_target): Remove the target op.
3176 (class process_target): Add the target op.
3177 (target_handle_new_gdb_connection): Update the macro.
3178 * target.cc (process_target::handle_new_gdb_connection): Define.
3179
3180 Update the derived classes and callers below.
3181
3182 * linux-low.cc (linux_target_ops): Update.
3183 (linux_handle_new_gdb_connection): Turn into ...
3184 (linux_process_target::handle_new_gdb_connection): ... this.
3185 * linux-low.h (class linux_process_target): Update.
3186 * lynx-low.cc (lynx_target_ops): Update.
3187 * nto-low.cc (nto_target_ops): Update.
3188 * win32-low.cc (win32_target_ops): Update.
3189
3190 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3191
3192 Turn process_stratum_target's supports_fork_events,
3193 supports_vfork_events, and supports_exec_events ops into methods
3194 of process_target.
3195
3196 * target.h (struct process_stratum_target): Remove the target ops.
3197 (class process_target): Add the target ops.
3198 (target_supports_fork_events): Update the macro.
3199 (target_supports_vfork_events): Update the macro.
3200 (target_supports_exec_events): Update the macro.
3201 * target.cc (process_target::supports_fork_events): Define.
3202 (process_target::supports_vfork_events): Define.
3203 (process_target::supports_exec_events): Define.
3204
3205 Update the derived classes and callers below.
3206
3207 * linux-low.cc (linux_target_ops): Update.
3208 (linux_supports_fork_events): Turn into ...
3209 (linux_process_target::supports_fork_events): ... this.
3210 (linux_supports_vfork_events): Turn into ...
3211 (linux_process_target::supports_vfork_events): ... this.
3212 (linux_supports_exec_events): Turn into ...
3213 (linux_process_target::supports_exec_events): ... this.
3214 * linux-low.h (class linux_process_target): Update.
3215 * lynx-low.cc (lynx_target_ops): Update.
3216 * nto-low.cc (nto_target_ops): Update.
3217 * win32-low.cc (win32_target_ops): Update.
3218
3219 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3220
3221 Turn process_stratum_target's supports_multi_process op into a
3222 method of process_target.
3223
3224 * target.h (struct process_stratum_target): Remove the target op.
3225 (class process_target): Add the target op.
3226 * target.cc (process_target::supports_multi_process): Define.
3227 (target_supports_multi_process): Update.
3228
3229 Update the derived classes and callers below.
3230
3231 * linux-low.cc (linux_target_ops): Update.
3232 (linux_supports_multi_process): Turn into ...
3233 (linux_process_target::supports_multi_process): ... this.
3234 * linux-low.h (class linux_process_target): Update.
3235 * lynx-low.cc (lynx_target_ops): Update.
3236 * nto-low.cc (nto_target_ops): Update.
3237 * win32-low.cc (win32_target_ops): Update.
3238
3239 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3240
3241 Turn process_stratum_target's supports_non_stop, async, and
3242 start_non_stop ops into methods of process_target.
3243
3244 * target.h (struct process_stratum_target): Remove the target ops.
3245 (class process_target): Add the target ops.
3246 (target_supports_non_stop): Update the macro.
3247 (target_async): Update the macro.
3248 (start_non_stop): Remove declaration.
3249 * target.cc (process_target::supports_non_stop): Define.
3250 (process_target::async): Define.
3251 (process_target::start_non_stop): Define.
3252 (start_non_stop): Remove.
3253
3254 Update the derived classes and callers below.
3255
3256 * server.cc (handle_qxfer_siginfo): Update.
3257 (handle_query): Update.
3258 * linux-low.cc (linux_target_ops): Update.
3259 (linux_supports_non_stop): Turn into ...
3260 (linux_process_target::supports_non_stop): ... this.
3261 (linux_async): Turn into ...
3262 (linux_process_target::async): ... this.
3263 (linux_start_non_stop): Turn into ...
3264 (linux_process_target::start_non_stop): ... this.
3265 * linux-low.h (class linux_process_target): Update.
3266 * lynx-low.cc (lynx_target_ops): Update.
3267 * nto-low.cc (nto_target_ops): Update.
3268 (nto_supports_non_stop): Remove; rely on the default behavior
3269 instead.
3270 * win32-low.cc (win32_target_ops): Update.
3271
3272 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3273
3274 Turn process_stratum_target's qxfer_siginfo op into a method of
3275 process_target.
3276
3277 * target.h (struct process_stratum_target): Remove the target op.
3278 (class process_target): Add the target op. Also add
3279 'supports_qxfer_siginfo'.
3280 * target.cc (process_target::qxfer_siginfo): Define.
3281 (process_target::supports_qxfer_siginfo): Define.
3282
3283 Update the derived classes and callers below.
3284
3285 * server.cc (handle_qxfer_siginfo): Update.
3286 (handle_query): Update.
3287 * linux-low.cc (linux_target_ops): Update.
3288 (linux_process_target::supports_qxfer_siginfo): Define.
3289 (linux_xfer_siginfo): Turn into ...
3290 (linux_process_target::qxfer_siginfo): ... this.
3291 * linux-low.h (class linux_process_target): Update.
3292 * lynx-low.cc (lynx_target_ops): Update.
3293 * nto-low.cc (nto_target_ops): Update.
3294 * win32-low.cc (win32_target_ops): Update.
3295
3296 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3297
3298 Turn process_stratum_target's qxfer_osdata op into a method of
3299 process_target.
3300
3301 * target.h (struct process_stratum_target): Remove the target op.
3302 (class process_target): Add the target op. Also add
3303 'supports_qxfer_osdata'.
3304 * target.cc (process_target::qxfer_osdata): Define.
3305 (process_target::supports_qxfer_osdata): Define.
3306
3307 Update the derived classes and callers below.
3308
3309 * server.cc (handle_qxfer_osdata): Update.
3310 (handle_query): Update.
3311 * linux-low.cc (linux_target_ops): Update.
3312 (linux_process_target::supports_qxfer_osdata): Define.
3313 (linux_qxfer_osdata): Turn into ...
3314 (linux_process_target::qxfer_osdata): ... 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 * win32-low.cc (win32_target_ops): Update.
3319
3320 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3321
3322 Turn process_stratum_target's hostio_last_error op into a
3323 method of process_target.
3324
3325 * target.h (struct process_stratum_target): Remove the target op.
3326 (class process_target): Add the target op.
3327 * target.cc: Add "hostio.h" to includes.
3328 (process_target::hostio_last_error): Define.
3329
3330 Update the derived classes and callers below.
3331
3332 * hostio.cc (hostio_error): Update.
3333 * linux-low.cc: Remove "hostio.h" from includes.
3334 (linux_target_ops): Update.
3335 * lynx-low.cc (lynx_target_ops): Update.
3336 * nto-low.cc (nto_target_ops): Update.
3337 * win32-low.h (class win32_process_target): Update.
3338 * win32-low.cc (win32_target_ops): Update.
3339 (wince_hostio_last_error): Turn into ...
3340 (win32_process_target::hostio_last_error): ... this.
3341
3342 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3343
3344 Turn process_stratum_target's get_tls_address op into a method of
3345 process_target.
3346
3347 * target.h (struct process_stratum_target): Remove the target op.
3348 (class process_target): Add the target op. Also add
3349 'supports_get_tls_address'.
3350 * target.cc (process_target::get_tls_address): Define.
3351 (process_target::supports_get_tls_address): Define.
3352
3353 Update the derived classes and callers below.
3354
3355 * server.cc (handle_query): Update.
3356 * linux-low.cc (linux_target_ops): Update.
3357 (linux_process_target::supports_get_tls_address): Define.
3358 (linux_process_target::get_tls_address): Define.
3359 * linux-low.h (class linux_process_target): Update.
3360 * lynx-low.cc (lynx_target_ops): Update.
3361 * nto-low.cc (nto_target_ops): Update.
3362 * win32-low.cc (win32_target_ops): Update.
3363
3364 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3365
3366 Turn process_stratum_target's read_offsets op into a method of
3367 process_target.
3368
3369 * target.h (struct process_stratum_target): Remove the target op.
3370 (class process_target): Add the target op. Also add
3371 'supports_read_offsets'.
3372 * target.cc (process_target::read_offsets): Define.
3373 (process_target::supports_read_offsets): Define.
3374
3375 Update the derived classes and callers below.
3376
3377 * server.cc (handle_query): Update.
3378 * linux-low.cc (SUPPORTS_READ_OFFSETS): New #define directive.
3379 (linux_target_ops): Update.
3380 (linux_process_target::supports_read_offsets): Define.
3381 (linux_read_offsets): Turn into ...
3382 (linux_process_target::read_offsets): ... this.
3383 * linux-low.h (class linux_process_target): Update.
3384 * lynx-low.cc (lynx_target_ops): Update.
3385 * nto-low.cc (nto_target_ops): Update.
3386 * win32-low.cc (win32_target_ops): Update.
3387
3388 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3389
3390 Turn process_stratum_target's stopped_by_watchpoint and
3391 stopped_data_address ops into methods of process_target.
3392
3393 * target.h (struct process_stratum_target): Remove the target ops.
3394 (class process_target): Add the target ops.
3395 * target.cc (process_target::stopped_by_watchpoint): Define.
3396 (process_target::stopped_data_address): Define.
3397
3398 Update the derived classes and callers below.
3399
3400 * remote-utils.cc (prepare_resume_reply): Update.
3401 * linux-low.cc (linux_target_ops): Update.
3402 (linux_stopped_by_watchpoint): Turn into ...
3403 (linux_process_target::stopped_by_watchpoint): ... this.
3404 (linux_stopped_data_address): Turn into ...
3405 (linux_process_target::stopped_data_address): ... this.
3406 * linux-low.h (class linux_process_target): Update.
3407 * lynx-low.cc (lynx_target_ops): Update.
3408 * nto-low.cc (nto_target_ops): Update.
3409 (nto_stopped_by_watchpoint): Turn into ...
3410 (nto_process_target::stopped_by_watchpoint): ... this.
3411 (nto_stopped_data_address): Turn into ...
3412 (nto_process_target::stopped_data_address): ... this.
3413 * nto-low.h (class nto_process_target): Update.
3414 * win32-low.cc (win32_target_ops): Update.
3415 (win32_stopped_by_watchpoint): Turn into ...
3416 (win32_process_target::stopped_by_watchpoint): ... this.
3417 (win32_stopped_data_address): Turn into ...
3418 (win32_process_target::stopped_data_address): ... this.
3419 * win32-low.h (class win32_process_target): Update.
3420
3421 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3422
3423 Turn process_stratum_target's supports_hardware_single_step op into
3424 a method of process_target.
3425
3426 * target.h (struct process_stratum_target): Remove the target op.
3427 (class process_target): Add the target op.
3428 (target_supports_hardware_single_step): Update the macro.
3429 (target_can_do_hardware_single_step): Remove declaration.
3430 * target.cc (process_target::supports_hardware_single_step): Define.
3431 (target_can_do_hardware_single_step): Remove.
3432
3433 Update the derived classes and callers below.
3434
3435 * linux-low.h (class linux_process_target): Update.
3436 * linux-low.cc (linux_target_ops): Update.
3437 (linux_supports_hardware_single_step): Turn into ...
3438 (linux_process_target::supports_hardware_single_step): ... this.
3439 * lynx-low.h (class lynx_process_target): Update.
3440 * lynx-low.cc (lynx_target_ops): Update.
3441 (lynx_process_target::supports_hardware_single_step): Define.
3442 * nto-low.h (class nto_process_target): Update.
3443 * nto-low.cc (nto_target_ops): Update.
3444 (nto_process_target::supports_hardware_single_step): Define.
3445 * win32-low.h (class win32_process_target): Update.
3446 * win32-low.cc (win32_target_ops): Update.
3447 (win32_process_target::supports_hardware_single_step): Define.
3448
3449 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3450
3451 Turn process_stratum_target's {supports_}stopped_by_hw_breakpoint
3452 ops into methods of process_target.
3453
3454 * target.h (struct process_stratum_target): Remove the target ops.
3455 (class process_target): Add the target ops.
3456 (target_stopped_by_hw_breakpoint): Update the macro.
3457 (target_supports_stopped_by_hw_breakpoint): Update the macro.
3458 * target.cc (process_target::stopped_by_hw_breakpoint): Define.
3459 (process_target::supports_stopped_by_hw_breakpoint): Define.
3460
3461 Update the derived classes and callers below.
3462
3463 * linux-low.cc (linux_target_ops): Update.
3464 (linux_stopped_by_hw_breakpoint): Turn into ...
3465 (linux_process_target::stopped_by_hw_breakpoint): ... this.
3466 (linux_supports_stopped_by_hw_breakpoint): Turn into ...
3467 (linux_process_target::supports_stopped_by_hw_breakpoint): ... this.
3468 * linux-low.h (class linux_process_target): Update.
3469 * lynx-low.cc (lynx_target_ops): Update.
3470 * nto-low.cc (nto_target_ops): Update.
3471 * win32-low.cc (win32_target_ops): Update.
3472
3473 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3474
3475 Turn process_stratum_target's {supports_}stopped_by_sw_breakpoint
3476 ops into methods of process_target.
3477
3478 * target.h (struct process_stratum_target): Remove the target ops.
3479 (class process_target): Add the target ops.
3480 (target_stopped_by_sw_breakpoint): Update the macro.
3481 (target_supports_stopped_by_sw_breakpoint): Update the macro.
3482 * target.cc (process_target::stopped_by_sw_breakpoint): Define.
3483 (process_target::supports_stopped_by_sw_breakpoint): Define.
3484
3485 Update the derived classes and callers below.
3486
3487 * linux-low.cc (linux_target_ops): Update.
3488 (linux_stopped_by_sw_breakpoint): Turn into ...
3489 (linux_process_target::stopped_by_sw_breakpoint): ... this.
3490 (linux_supports_stopped_by_sw_breakpoint): Turn into ...
3491 (linux_process_target::supports_stopped_by_sw_breakpoint): ... this.
3492 * linux-low.h (class linux_process_target): Update.
3493 * lynx-low.cc (lynx_target_ops): Update.
3494 * nto-low.cc (nto_target_ops): Update.
3495 * win32-low.cc (win32_target_ops): Update.
3496
3497 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3498
3499 Turn process_stratum_target's insert_point and remove_point ops
3500 into methods of process_target.
3501
3502 * target.h (struct process_stratum_target): Remove the target ops.
3503 (class process_target): Add the target ops.
3504 * target.cc (process_target::insert_point): Define.
3505 (process_target::remove_point): Define.
3506
3507 Update the derived classes and callers below.
3508
3509 * mem-break.cc (set_raw_breakpoint_at): Update.
3510 (delete_raw_breakpoint): Update.
3511 (uninsert_raw_breakpoint): Update.
3512 (reinsert_raw_breakpoint): Update.
3513 * linux-low.cc (linux_target_ops): Update.
3514 (linux_insert_point): Turn into ...
3515 (linux_process_target::insert_point): ... this.
3516 (linux_remove_point): Turn into ...
3517 (linux_process_target::remove_point): ... 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 (nto_insert_point): Turn into ...
3522 (nto_process_target::insert_point): ... this.
3523 (nto_remove_point): Turn into ...
3524 (nto_process_target::remove_point): ... this.
3525 * nto-low.h (class nto_process_target): Update.
3526 * win32-low.cc (win32_target_ops): Update.
3527 (win32_insert_point): Turn into ...
3528 (win32_process_target::insert_point): ... this.
3529 (win32_remove_point): Turn into ...
3530 (win32_process_target::remove_point): ... this.
3531 * win32-low.h (class win32_process_target): Update.
3532
3533 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3534
3535 Turn process_stratum_target's supports_z_point_type op into a
3536 method of process_target.
3537
3538 * target.h (struct process_stratum_target): Remove the target op.
3539 (class process_target): Add the target op.
3540 * target.cc (process_target::supports_z_point_type): Define.
3541
3542 Update the derived classes and callers below.
3543
3544 * mem-break.cc (z_type_supported): Update.
3545 * linux-low.cc (linux_target_ops): Update.
3546 (linux_supports_z_point_type): Turn into ...
3547 (linux_process_target::supports_z_point_type): ... this.
3548 * linux-low.h (class linux_process_target): Update.
3549 * lynx-low.cc (lynx_target_ops): Update.
3550 * nto-low.cc (nto_target_ops): Update.
3551 (nto_supports_z_point_type): Turn into ...
3552 (nto_process_target::supports_z_point_type): ... this.
3553 * nto-low.h (class nto_process_target): Update.
3554 * win32-low.cc (win32_target_ops): Update.
3555 (win32_supports_z_point_type): Turn into ...
3556 (win32_process_target::supports_z_point_type): ... this.
3557 * win32-low.h (class win32_process_target): Update.
3558
3559 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3560
3561 Turn process_stratum_target's read_auxv op into a method of
3562 process_target.
3563
3564 * target.h (class process_stratum_target): Remove the target op.
3565 (struct process_target): Add the target op. Also add
3566 'supports_read_auxv'.
3567 * target.cc (process_target::read_auxv): Define.
3568 (process_target::supports_read_auxv): Define.
3569
3570 Update the derived classes and callers below.
3571
3572 * server.cc (handle_qxfer_auxv): Update.
3573 (handle_query): Update.
3574 * linux-low.cc (linux_target_ops): Update.
3575 (linux_process_target::supports_read_auxv): Define.
3576 (linux_read_auxv): Turn into ...
3577 (linux_process_target::read_auxv): ... this.
3578 * linux-low.h (class linux_process_target): Update.
3579 * lynx-low.cc (lynx_target_ops): Update.
3580 * nto-low.cc (nto_target_ops): Update.
3581 (nto_process_target::supports_read_auxv): Define.
3582 (nto_read_auxv): Turn into ...
3583 (nto_process_target::read_auxv): ... this.
3584 * nto-low.h (class nto_process_target): Update.
3585 * win32-low.cc (win32_target_ops): Update.
3586
3587 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3588
3589 Turn process_stratum_target's request_interrupt op into a method of
3590 process_target.
3591
3592 * target.h (struct process_stratum_target): Remove the target op.
3593 (class process_target): Add the target op.
3594
3595 Update the derived classes and callers below.
3596
3597 * remote-utils.cc (putpkt_binary_1): Update.
3598 (input_interrupt): Update.
3599 (getpkt): Update.
3600 * server.cc (handle_v_requests): Update.
3601 * linux-low.cc (linux_target_ops): Update.
3602 (linux_request_interrupt): Turn into ...
3603 (linux_process_target::request_interrupt): ... this.
3604 * linux-low.h (class linux_process_target): Update.
3605 * lynx-low.cc (lynx_target_ops): Update.
3606 (lynx_request_interrupt): Turn into ...
3607 (lynx_process_target::request_interrupt): ... this.
3608 * lynx-low.h (class lynx_process_target): Update.
3609 * nto-low.cc (nto_target_ops): Update.
3610 (nto_request_interrupt): Turn into ...
3611 (nto_process_target::request_interrupt): ... this.
3612 * nto-low.h (class nto_process_target): Update.
3613 * win32-low.cc (win32_target_ops): Update.
3614 (win32_request_interrupt): Turn into ...
3615 (win32_process_target::request_interrupt): ... this.
3616 * win32-low.h (class win32_process_target): Update.
3617
3618 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3619
3620 Turn process_stratum_target's look_up_symbols op into a method of
3621 process_target.
3622
3623 * target.h (struct process_stratum_target): Remove the target op.
3624 (class process_target): Add the target op.
3625 * target.cc (process_target::look_up_symbols): Define.
3626
3627 Update the derived classes and callers below.
3628
3629 * server.cc (handle_query): Update.
3630 * linux-low.cc (linux_target_ops): Update.
3631 (linux_look_up_symbols): Turn into ...
3632 (linux_process_target::look_up_symbols): ... this.
3633 * linux-low.h (class linux_process_target): Update.
3634 * lynx-low.cc (lynx_target_ops): Update.
3635 * nto-low.cc (nto_target_ops): Update.
3636 * win32-low.cc (win32_target_ops): Update.
3637
3638 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3639
3640 Turn process_stratum_target's read_memory and write_memory
3641 ops into methods of process_target.
3642
3643 * target.h (struct process_stratum_target): Remove the target ops.
3644 (class process_target): Add the target ops.
3645
3646 Update the derived classes and callers below.
3647
3648 * linux-aarch32-low.cc (arm_breakpoint_at): Update.
3649 * linux-aarch64-low.cc (aarch64_breakpoint_at): Update.
3650 * linux-arm-low.cc (arm_sigreturn_next_pc): Update.
3651 (arm_get_syscall_trapinfo): Update.
3652 * linux-cris-low.cc (cris_breakpoint_at): Update.
3653 * linux-crisv32-low.cc (cris_breakpoint_at): Update.
3654 * linux-m32r-low.cc (m32r_breakpoint_at): Update.
3655 * linux-mips-low.cc (mips_breakpoint_at): Update.
3656 * linux-nios2-low.cc (nios2_breakpoint_at): Update.
3657 * linux-ppc-low.cc (ppc_breakpoint_at): Update.
3658 * linux-sh-low.cc (sh_breakpoint_at): Update.
3659 * linux-sparc-low.cc (sparc_fill_gregset_to_stack): Update.
3660 (sparc_store_gregset_from_stack): Update.
3661 (sparc_breakpoint_at): Update.
3662 * linux-tic6x-low.cc (tic6x_breakpoint_at): Update.
3663 * linux-tile-low.cc (tile_breakpoint_at): Update.
3664 * linux-x86-low.cc (x86_breakpoint_at): Update.
3665 * linux-xtensa-low.cc (xtensa_breakpoint_at): Update.
3666 * mem-brea.cc (insert_memory_breakpoint): Update.
3667 (validate_inserted_breakpoint): Update.
3668 * target.cc (read_inferior_memory): Update.
3669 (target_write_memory): Update.
3670 * linux-low.cc (linux_target_ops): Update.
3671 (linux_read_memory): Make a wrapper around the read_memory target
3672 op call.
3673 (linux_process_target::read_memory): Rename from linux_read_memory.
3674 (linux_write_memory): Turn into ...
3675 (linux_process_target::write_memory): ... this.
3676 * linux-low.h (class linux_process_target): Update.
3677 * lynx-low.cc (lynx_target_ops): Update.
3678 (lynx_read_memory): Turn into ...
3679 (lynx_process_target::read_memory): ... this.
3680 (lynx_write_memory): Turn into ...
3681 (lynx_process_target::write_memory): ... this.
3682 * lynx-low.h (class lynx_process_target): Update.
3683 * nto-low.cc (nto_target_ops): Update.
3684 (nto_read_memory): Turn into ...
3685 (nto_process_target::read_memory): ... this.
3686 (nto_write_memory): Turn into ...
3687 (nto_process_target::write_memory): ... this.
3688 * nto-low.h (class nto_process_target): Update.
3689 * win32-low.cc (win32_target_ops): Update.
3690 (win32_read_inferior_memory): Turn into ...
3691 (win32_process_target::read_memory): ... this.
3692 (win32_write_inferior_memory): Turn into ...
3693 (win32_process_target::write_memory): ... this.
3694 * win32-low.h (class win32_process_target): Update.
3695
3696 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3697
3698 Turn process_stratum_target's prepare_to_access_memory and
3699 done_accessing_memory ops into methods of process_target.
3700
3701 * target.h (struct process_stratum_target): Remove the target ops.
3702 (class process_target): Add the target ops.
3703 * target.cc (process_target::prepare_to_access_memory): Define.
3704 (process_target::done_accessing_memory): Define.
3705 (prepare_to_access_memory): Update.
3706 (done_accessing_memory): Update.
3707
3708 Update the derived classes and callers below.
3709
3710 * linux-low.cc (linux_target_ops): Update.
3711 (linux_prepare_to_access_memory): Turn into ...
3712 (linux_process_target::prepare_to_access_memory): ... this.
3713 (linux_done_accessing_memory): Turn into ...
3714 (linux_process_target::done_accessing_memory): ... this.
3715 * linux-low.h (class linux_process_target): Update.
3716 * lynx-low.cc (lynx_target_ops): Update.
3717 * nto-low.cc (nto_target_ops): Update.
3718 * win32-low.cc (win32_target_ops): Update.
3719
3720 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3721
3722 Turn process_stratum_target's fetch_registers and store_registers
3723 ops into methods of process_target.
3724
3725 * target.h (struct process_stratum_target): Remove the target ops.
3726 (class process_target): Add the target ops.
3727 (fetch_inferior_registers): Update the macro.
3728 (store_inferior_registers): Update the macro.
3729
3730 Update the derived classes and callers below.
3731
3732 * linux-low.cc (linux_target_ops): Update.
3733 (linux_fetch_registers): Turn into ...
3734 (linux_process_target::fetch_registers): ... this.
3735 (linux_store_registers): Turn into ...
3736 (linux_process_target::store_registers): ... this.
3737 * linux-low.h (class linux_process_target): Update.
3738 * lynx-low.cc (lynx_target_ops): Update.
3739 (lynx_fetch_registers): Turn into ...
3740 (lynx_process_target::fetch_registers): ... this.
3741 (lynx_store_registers): Turn into ...
3742 (lynx_process_target::store_registers): ... this.
3743 * lynx-low.h (class lynx_process_target): Update.
3744 * nto-low.cc (nto_target_ops): Update.
3745 (nto_fetch_registers): Turn into ...
3746 (nto_process_target::fetch_registers): ... this.
3747 (nto_store_registers): Turn into ...
3748 (nto_process_target::store_registers): ... this.
3749 * nto-low.h (class nto_process_target): Update.
3750 * win32-low.cc (win32_target_ops): Update.
3751 (win32_fetch_inferior_registers): Turn into ...
3752 (win32_process_target::fetch_registers): ... this.
3753 (win32_store_inferior_registers): Turn into ...
3754 (win32_process_target::store_registers): ... this.
3755 * win32-low.h (class win32_process_target): Update.
3756
3757 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3758
3759 Turn process_stratum_target's wait op into a method of
3760 process_target.
3761
3762 * target.h (struct process_stratum_target): Remove the target op.
3763 (class process_target): Add the target op.
3764
3765 Update the derived classes and callers below.
3766
3767 * target.cc (target_wait): Update.
3768 * linux-low.cc (linux_target_ops): Update.
3769 (linux_wait): Turn into ...
3770 (linux_process_target::wait): ... this.
3771 * linux-low.h (class linux_process_target): Update.
3772 * lynx-low.cc (lynx_target_ops): Update.
3773 (lynx_wait): Turn into ...
3774 (lynx_process_target::wait): ... this.
3775 * lynx-low.h (class lynx_process_target): Update.
3776 * nto-low.cc (nto_target_ops): Update.
3777 (nto_wait): Turn into ...
3778 (nto_process_target::wait): ... this.
3779 * nto-low.h (class nto_process_target): Update.
3780 * win32-low.cc (win32_target_ops): Update.
3781 (win32_wait): Turn into ...
3782 (win32_process_target::wait): ... this.
3783 (do_initial_child_stuff): Update.
3784 * win32-low.h (class win32_process_target): Update.
3785
3786 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3787
3788 Turn process_stratum_target's resume op into a method of
3789 process_target.
3790
3791 * target.h (struct process_stratum_target): Remove the target op.
3792 (class process_target): Add the target op.
3793
3794 Update the derived classes and callers below.
3795
3796 * server.cc (resume): Update.
3797 * target.cc (target_stop_and_wait): Update.
3798 (target_continue_no_signal): Update.
3799 (target_continue): Update.
3800 * linux-low.cc (linux_target_ops): Update.
3801 (linux_resume): Turn into ...
3802 (linux_process_target::resume): ... this.
3803 * linux-low.h (class linux_process_target): Update.
3804 * lynx-low.cc (lynx_target_ops): Update.
3805 (lynx_resume): Turn into ...
3806 (lynx_process_target::resume): ... this.
3807 * lynx-low.h (class lynx_process_target): Update.
3808 * nto-low.cc (nto_target_ops): Update.
3809 (nto_resume): Turn into ...
3810 (nto_process_target::resume): ... this.
3811 * nto-low.h (class nto_process_target): Update.
3812 * win32-low.cc (win32_target_ops): Update.
3813 (win32_resume): Turn into ...
3814 (win32_process_target::resume): ... this.
3815 (win32_process_target::detach): Update.
3816 (do_initial_child_stuff): Update.
3817 * win32-low.h (class win32_process_target): Update.
3818
3819 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3820
3821 Turn process_stratum_target's thread_alive op into a method of
3822 process_target.
3823
3824 * target.h (struct process_stratum_target): Remove the target op.
3825 (class process_target): Add the target op.
3826 (mythread_alive): Update the macro.
3827
3828 Update the derived classes and callers below.
3829
3830 * linux-low.cc (linux_target_ops): Update.
3831 (linux_thread_alive): Turn into ...
3832 (linux_process_target::thread_alive): ... this.
3833 (wait_for_sigstop): Update.
3834 * linux-low.h (class linux_process_target): Update.
3835 * lynx-low.cc (lynx_target_ops): Update.
3836 (lynx_thread_alive): Turn into ...
3837 (lynx_process_target::thread_alive): ... this.
3838 * lynx-low.h (class lynx_process_target): Update.
3839 * nto-low.cc (nto_target_ops): Update.
3840 (nto_thread_alive): Turn into ...
3841 (nto_process_target::thread_alive): ... this.
3842 * nto-low.h (class nto_process_target): Update.
3843 * win32-low.cc (win32_target_ops): Update.
3844 (win32_thread_alive): Turn into ...
3845 (win32_process_target::thread_alive): ... this.
3846 * win32-low.h (class win32_process_target): Update.
3847
3848 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3849
3850 Turn process_stratum_target's join op into a method of
3851 process_target.
3852
3853 * target.h (struct process_stratum_target): Remove the target op.
3854 (class process_target): Add the target op.
3855 (join_inferior): Update the macro.
3856
3857 Update the derived classes and callers below.
3858
3859 * linux-low.cc (linux_target_ops): Update.
3860 (linux_join): Turn into ...
3861 (linux_process_target::join): ... this.
3862 * linux-low.h (class linux_process_target): Update.
3863 * lynx-low.cc (lynx_target_ops): Update.
3864 (lynx_join): Turn into ...
3865 (lynx_process_target::join): ... this.
3866 * lynx-low.h (class lynx_process_target): Update.
3867 * nto-low.cc (nto_target_ops): Update.
3868 (nto_process_target::join): Define.
3869 * nto-low.h (class nto_process_target): Update.
3870 * win32-low.cc (win32_target_ops): Update.
3871 (win32_join): Turn into ...
3872 (win32_process_target::join): ... this.
3873 * win32-low.h (class win32_process_target): Update.
3874
3875 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3876
3877 Turn process_stratum_target's mourn op into a method of
3878 process_target.
3879
3880 * target.h (struct process_stratum_target): Remove the target op.
3881 (class process_target): Add the target op.
3882
3883 Update the derived classes and callers below.
3884
3885 * target.cc (target_mourn_inferior): Update.
3886 * linux-low.cc (linux_target_ops): Update.
3887 (linux_mourn): Turn into ...
3888 (linux_process_target::mourn): ... this.
3889 (handle_extended_wait): Update.
3890 (linux_process_target::kill): Update.
3891 (linux_process_target::detach): Update.
3892 * linux-low.h (class linux_process_target): Update.
3893 * lynx-low.cc (lynx_target_ops): Update.
3894 (lynx_mourn): Turn into ...
3895 (lynx_process_target::mourn): ... this.
3896 * lynx-low.h (class lynx_process_target): Update.
3897 * nto-low.cc (nto_target_ops): Update.
3898 (nto_mourn): Turn into ...
3899 (nto_process_target::mourn): ... this.
3900 * nto-low.h (class nto_process_target): Update.
3901 * win32-low.cc (win32_target_ops): Update.
3902 (win32_mourn): Turn into ...
3903 (win32_process_target::mourn): ... this.
3904 * win32-low.h (class win32_process_target): Update.
3905
3906 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3907
3908 Turn process_stratum_target's detach op into a method of
3909 process_target.
3910
3911 * target.h (struct process_stratum_target): Remove the target op.
3912 (class process_target): Add the target op.
3913 (detach_inferior): Update the macro.
3914
3915 Update the derived classes and callers below.
3916
3917 * linux-low.cc (linux_target_ops): Update.
3918 (linux_detach): Turn into ...
3919 (linux_process_target::detach): ... this.
3920 * linux-low.h (class linux_process_target): Update.
3921 * lynx-low.cc (lynx_target_ops): Update.
3922 (lynx_detach): Turn into ...
3923 (lynx_process_target::detach): ... this.
3924 * lynx-low.h (class lynx_process_target): Update.
3925 * nto-low.cc (nto_target_ops): Update.
3926 (nto_detach): Turn into ...
3927 (nto_process_target::detach): ... this.
3928 * nto-low.h (class nto_process_target): Update.
3929 * win32-low.cc (win32_target_ops): Update.
3930 (win32_detach): Turn into ...
3931 (win32_process_target::detach): ... this.
3932 * win32-low.h (class win32_process_target): Update.
3933
3934 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3935
3936 Turn process_stratum_target's kill op into a method of
3937 process_target.
3938
3939 * target.h (struct process_stratum_target): Remove the target op.
3940 (class process_target): Add the target op.
3941
3942 Update the derived classes and callers below.
3943
3944 * target.cc (kill_inferior): Update.
3945 * linux-low.cc (linux_target_ops): Update.
3946 (linux_kill): Turn into ...
3947 (linux_process_target::kill): ... this.
3948 * linux-low.h (class linux_process_target): Update.
3949 * lynx-low.cc (lynx_target_ops): Update.
3950 (lynx_kill): Turn into ...
3951 (lynx_process_target::kill): ... this.
3952 * lynx-low.h (class lynx_process_target): Update.
3953 * nto-low.cc (nto_target_ops): Update.
3954 (nto_kill): Turn into ...
3955 (nto_process_target::kill): ... this.
3956 * nto-low.h (class nto_process_target): Update.
3957 * win32-low.cc (win32_target_ops): Update.
3958 (win32_kill): Turn into ...
3959 (win32_process_target::kill): ... this.
3960 * win32-low.h (class win32_process_target): Update.
3961
3962 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3963
3964 Turn process_stratum_target's attach op into a method of
3965 process_target.
3966
3967 * target.h (struct process_stratum_target): Remove the target op.
3968 (class process_target): Add the target op.
3969 (myattach): Update the macro.
3970
3971 Update the derived classes and callers below.
3972
3973 * linux-low.cc (linux_target_ops): Update.
3974 (linux_attach): Turn into ...
3975 (linux_process_target::attach): ... this.
3976 * linux-low.h (class linux_process_target): Update.
3977 * lynx-low.cc (lynx_target_ops): Update.
3978 (lynx_attach): Turn into ...
3979 (lynx_process_target::attach): ... this.
3980 * lynx-low.h (class lynx_process_target): Update.
3981 * nto-low.cc (nto_target_ops): Update.
3982 (nto_attach): Turn into ...
3983 (nto_process_target::attach): ... this.
3984 * nto-low.h (class nto_process_target): Update.
3985 * win32-low.cc (win32_target_ops): Update.
3986 (win32_attach): Turn into ...
3987 (win32_process_target::attach): ... this.
3988 * win32-low.h (class win32_process_target): Update.
3989
3990 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3991
3992 Turn process_stratum_target's post_create_inferior op into a method
3993 of process_target.
3994
3995 * target.h (struct process_stratum_target): Remove the target op.
3996 (class process_target): Add the target op.
3997 (target_post_create_inferior): Update the macro.
3998 * target.cc (process_target::post_create_inferior): Define.
3999
4000 Update the derived classes and callers below.
4001
4002 * linux-low.cc (linux_target_ops): Update.
4003 (linux_post_create_inferior): Turn into ...
4004 (linux_process_target::post_create_inferior): ... this.
4005 * linux-low.h (class linux_process_target): Update.
4006 * lynx-low.cc (lynx_target_ops): Update.
4007 * nto-low.cc (nto_target_ops): Update.
4008 * win32-low.cc (win32_target_ops): Update.
4009
4010 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4011
4012 Turn process_stratum_target's create_inferior op into a method of
4013 process_target.
4014
4015 * target.h (struct process_stratum_target): Remove the target op.
4016 (class process_target): Add the target op.
4017 (create_inferior): Rename the macro to ...
4018 (target_create_inferior): ... this.
4019
4020 Update the derived classes and callers below.
4021
4022 * server.cc (handle_v_run): Update.
4023 (captured_main): Update.
4024 (process_serial_event): Update.
4025 * linux-low.cc (linux_target_ops): Update.
4026 (linux_create_inferior): Turn into ...
4027 (linux_process_target::create_inferior): ... this.
4028 * linux-low.h (class linux_process_target): Update.
4029 * lynx-low.cc (lynx_target_ops): Update.
4030 (lynx_create_inferior): Turn into ...
4031 (lynx_process_target::create_inferior): ... this.
4032 * lynx-low.h (class lynx_process_target): Update.
4033 * nto-low.cc (nto_target_ops): Update.
4034 (nto_create_inferior): Turn into ...
4035 (nto_process_target::create_inferior): ... this.
4036 * nto-low.h (class nto_process_target): Update.
4037 * win32-low.cc (win32_target_ops): Update.
4038 (win32_create_inferior): Turn into ...
4039 (win32_process_target::create_inferior): ... this.
4040 * win32-low.h (class win32_process_target): Update.
4041
4042 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4043
4044 * target.h (class process_target): New class definition.
4045 (struct process_stratum_target) <pt>: New field with type
4046 'process_target*'.
4047 * linux-low.h (class linux_process_target): Define as a derived
4048 class of 'process_target'.
4049 * linux-low.cc (linux_target_ops): Add a linux_process_target*
4050 as the 'pt' field.
4051 * lynx-low.h (class lynx_process_target): Define as a derived
4052 class of 'process_target'.
4053 * lynx-low.cc (lynx_target_ops): Add a lynx_process_target*
4054 as the 'pt' field.
4055 * nto-low.h (class nto_process_target): Define as a derived
4056 class of 'process_target'.
4057 * nto-low.cc (nto_target_ops): Add an nto_process_target*
4058 as the 'pt' field.
4059 * win32-low.h (class win32_process_target): Define as a derived
4060 class of 'process_target'.
4061 * win32-low.cc (win32_target_ops): Add a win32_process_target*
4062 as the 'pt' field.
4063
4064 2020-02-19 Andrew Burgess <andrew.burgess@embecosm.com>
4065
4066 * configure: Regenerate.
4067
4068 2020-02-19 Maciej W. Rozycki <macro@wdc.com>
4069 Andrew Burgess <andrew.burgess@embecosm.com>
4070
4071 * linux-riscv-low.cc: New file.
4072 * Makefile.in (SFILES): Add linux-riscv-low.cc, arch/riscv.c,
4073 and nat/riscv-linux-tdesc.c.
4074 * configure.srv <riscv*-*-linux*> (srv_tgtobj)
4075 (srv_linux_regsets, srv_linux_usrregs, srv_linux_thread_db):
4076 Define.
4077
4078 2020-02-14 Tom Tromey <tom@tromey.com>
4079
4080 * acinclude.m4: Don't include acx_configure_dir.m4.
4081 * Makefile.in (LIBIBERTY_BUILDDIR, GNULIB_BUILDDIR): Update.
4082 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): Remove.
4083 (all, install-only, uninstall, clean-info, clean)
4084 (maintainer-clean): Don't recurse.
4085 (subdir_do, all-lib): Remove.
4086 ($(LIBGNU) $(LIBIBERTY) $(GNULIB_H)): Remove rule.
4087 (GNULIB_H): Remove.
4088 (generated_files): Update.
4089 ($(GNULIB_BUILDDIR)/Makefile): Remove rule.
4090 * configure: Rebuild.
4091 * configure.ac: Don't configure gnulib or libiberty.
4092 (GNULIB): Update.
4093
4094 2020-02-14 Eli Zaretskii <eliz@gnu.org>
4095
4096 * win32-low.c (create_process): Prepend PROGRAM to ARGS when
4097 preparing the command line for CreateProcess.
4098 (win32_create_inferior): Reflect the program name in debugging
4099 output that shows the process and its command line.
4100
4101 2020-02-13 Simon Marchi <simon.marchi@efficios.com>
4102
4103 * Makefile.in: Rename source files from .c to .cc.
4104 * %.c: Rename to %.cc.
4105 * configure.ac: Rename server.c to server.cc.
4106 * configure: Re-generate.
4107
4108 2020-02-13 Simon Marchi <simon.marchi@efficios.com>
4109
4110 * Makefile.in: Rename gdbsupport source files from .c to .cc.
4111
4112 2020-02-12 Hannes Domani <ssbssa@yahoo.de>
4113
4114 * win32-low.c (win32_create_inferior): Set signal_pid.
4115
4116 2020-02-12 Maciej W. Rozycki <macro@wdc.com>
4117 Pedro Alves <palves@redhat.com>
4118
4119 Skip building gdbserver in a cross-configuration.
4120 * configure.srv: Set $gdbserver_host depending on whether $target
4121 is $host. Use $gdbserver_host instead of $host.
4122
4123 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
4124
4125 * configure: Re-generate.
4126
4127 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
4128
4129 * configure: Re-generate.
4130
4131 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
4132
4133 * acinclude.m4: Update warning.m4 path.
4134
4135 2020-02-09 Hannes Domani <ssbssa@yahoo.de>
4136
4137 * win32-low.c (win32_clear_inferiors): Reset siginfo_er.
4138 (handle_exception): Set siginfo_er.
4139 (win32_xfer_siginfo): New function.
4140
4141 2020-02-07 Tom Tromey <tom@tromey.com>
4142 Pedro Alves <palves@redhat.com>
4143
4144 * README: Update build documentation.
4145 * configure.srv: Set UNSUPPORTED if host is unsupported. Check
4146 host, not target.
4147 * configure.ac: Update paths.
4148 * configure: Rebuild.
4149 * acinclude.m4: Update paths.
4150 * Makefile.in: Update include paths.
4151 (depcomp, INCLUDE_DIR, INCGNU, INCSUPPORT, INCLUDE_CFLAGS)
4152 (SFILES, XML_DIR, n, $(GNULIB_BUILDDIR)/Makefile, config.status)
4153 (version-generated.c, stamp-xml, regdat_sh, arch/%-ipa.o)
4154 (gdbsupport/%-ipa.o, %-ipa.o, arch/%.o, gdbsupport/%.o, %.o)
4155 (%-generated.c): Update paths.
4156 * Move entire directory from ../gdb/gdbserver.
4157
4158 2020-01-29 Maciej W. Rozycki <macro@wdc.com>
4159
4160 * configure.srv <i[34567]86-*-mingw*>: Fix whitespace damage.
4161
4162 2020-01-29 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4163
4164 * configure.srv (powerpc*-*-linux*): Use srv_tgtobj in second
4165 assignment instead of srv_linux_obj.
4166
4167 2020-01-28 Hannes Domani <ssbssa@yahoo.de>
4168
4169 * server.c (handle_qxfer_libraries): Write segment-address with
4170 paddress.
4171
4172 2020-01-24 Hannes Domani <ssbssa@yahoo.de>
4173
4174 * Makefile.in (install-strip): New target.
4175 (install_sh, INSTALL_STRIP_PROGRAM, STRIP): New variables.
4176 * aclocal.m4: Regenerate.
4177 * configure: Regenerate.
4178 * configure.ac: Add AM_PROG_INSTALL_STRIP.
4179
4180 2020-01-24 Maciej W. Rozycki <macro@wdc.com>
4181
4182 * Makefile.in (SFILES): Adjust paths to point to real files.
4183 (OBS): Move waitstatus.o to target/waitstatus.o.
4184 (TAGS): Transform paths appropriately.
4185 (%.o): Rename to...
4186 (nat/%.o): ... this pattern rule.
4187 (%.o): Rename to...
4188 (target/%.o): ... this pattern rule.
4189 * configure.srv: Adjust paths throughout to include nat/ prefix
4190 with the revant files.
4191 * configure.ac: Add `nat' and `target' to CONFIG_SRC_SUBDIR.
4192 * configure: Regenerate.
4193
4194 2020-01-24 Maciej W. Rozycki <macro@wdc.com>
4195
4196 * Makefile.in (TAGS): Remove config files from the recipe.
4197
4198 2020-01-14 Tom Tromey <tom@tromey.com>
4199
4200 * configure: Rebuild.
4201 * configure.ac: Remove any checks that were added to common.m4.
4202 * acinclude.m4: Include lib-ld.m4, lib-prefix.m4, and
4203 lib-link.m4.
4204
4205 2020-01-14 Tom Tromey <tom@tromey.com>
4206
4207 * server.h: Include config.h.
4208 * gdbreplay.c: Include config.h.
4209 * configure: Rebuild.
4210 * configure.ac: Don't source common.host.
4211 * acinclude.m4: Update path.
4212 * Makefile.in (INCSUPPORT): New variable.
4213 (INCLUDE_CFLAGS): Add INCSUPPORT.
4214 (SFILES): Update paths.
4215 (version-generated.c): Update path to create-version.sh.
4216 (gdbsupport/%-ipa.o, gdbsupport/%.o): Update paths.
4217
4218 2020-01-14 Tom Tromey <tom@tromey.com>
4219
4220 * configure.ac (LIBS): Use WIN32APILIBS.
4221 (USE_WIN32API): Don't define.
4222 * configure: Rebuild.
4223
4224 2020-01-14 Tom Tromey <tom@tromey.com>
4225
4226 * configure: Rebuild.
4227
4228 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
4229
4230 * Makefile.in (%-generated.c): Remove rule for files from
4231 regformats/i386.
4232
4233 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
4234
4235 * configure: Re-generate.
4236
4237 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
4238
4239 * tracepoint.h (IP_AGENT_EXPORT_FUNC) [!IN_PROCESS_AGENT]:
4240 Define to static.
4241 * tracepoint.c (stop_tracing, flush_trace_buffer,
4242 about_to_request_buffer_space, get_trace_state_variable_value,
4243 set_trace_state_variable_value, gdb_collect): Add declaration.
4244
4245 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
4246
4247 * linux-x86-low.c (x86_linux_regs_info, amd64_emit_eq_goto,
4248 amd64_emit_ne_goto, amd64_emit_lt_goto, amd64_emit_le_goto,
4249 amd64_emit_gt_goto, amd64_emit_ge_goto, amd64_emit_ge_goto,
4250 i386_emit_eq_goto, i386_emit_ne_goto, i386_emit_lt_goto,
4251 i386_emit_le_goto, i386_emit_gt_goto, i386_emit_ge_goto): Make
4252 static.
4253
4254 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
4255
4256 * inferiors.c: Include gdbsupport/common-inferior.h.
4257
4258 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
4259
4260 * hostio-errno.c: Include hostio.h.
4261
4262 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
4263
4264 * Makefile.in (%-generated.c): Make $(regdat_sh) a regular
4265 prerequisite.
4266
4267 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
4268
4269 * linux-arm-tdesc.c: Include linux-arm-tdesc.h.
4270 * linux-arm-tdesc.h: Include arch/arm.h.
4271
4272 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
4273
4274 * linux-aarch64-low.c (aarch64_write_goto_address): Make static.
4275
4276 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
4277
4278 * linux-aarch32-tdesc.c: Include linux-aarch32-tdesc.h.
4279 * linux-aarch64-tdesc.c: Include linux-aarch64-tdesc.h.
4280
4281 2020-01-10 Pedro Alves <palves@redhat.com>
4282
4283 * fork-child.c (post_fork_inferior): Pass target down to
4284 startup_inferior.
4285 * inferiors.c (switch_to_thread): Add process_stratum_target
4286 parameter.
4287 * lynx-low.c (lynx_target_ops): Now a process_stratum_target.
4288 * nto-low.c (nto_target_ops): Now a process_stratum_target.
4289 * linux-low.c (linux_target_ops): Now a process_stratum_target.
4290 * remote-utils.c (prepare_resume_reply): Pass the target to
4291 switch_to_thread.
4292 * target.c (the_target): Now a process_stratum_target.
4293 (done_accessing_memory): Pass the target to switch_to_thread.
4294 (set_target_ops): Ajust to use process_stratum_target.
4295 * target.h (struct target_ops): Rename to ...
4296 (struct process_stratum_target): ... this.
4297 (the_target, set_target_ops): Adjust.
4298 (prepare_to_access_memory): Adjust comment.
4299 * win32-low.c (child_xfer_memory): Adjust to use
4300 process_stratum_target.
4301 (win32_target_ops): Now a process_stratum_target.
4302
4303 2020-01-06 Eli Zaretskii <eliz@gnu.org>
4304 Pedro Alves <palves@redhat.com>
4305
4306 * win32-low.c (get_child_debug_event): Extract the fatal exception
4307 from the exit status and convert to the equivalent Posix signal
4308 number.
4309 (win32_wait): Allow TARGET_WAITKIND_SIGNALLED status as well.
4310 * Makefile.in (OBS, SFILES): Add gdb_wait.[co].
4311
4312 2020-01-01 Hannes Domani <ssbssa@yahoo.de>
4313
4314 * Makefile.in: Use INSTALL_PROGRAM_ENV.
4315
4316 2020-01-01 Joel Brobecker <brobecker@adacore.com>
4317
4318 * server.c (gdbserver_version): Change copyright year to 2020.
4319 * gdbreplay.c (gdbreplay_version): Likewise.
4320
4321 2019-12-19 Christian Biesinger <cbiesinger@google.com>
4322
4323 * configure: Regenerate.
4324 * configure.ac: Quote variable arguments of test.
4325
4326 2019-12-16 Bernd Edlinger <bernd.edlinger@hotmail.de>
4327
4328 * Makefile.in: Fix build with GNU Make 3.81
4329
4330 2019-12-16 Tom Tromey <tromey@adacore.com>
4331
4332 * server.c (get_exec_file): Constify result.
4333
4334 2019-12-10 Christian Biesinger <cbiesinger@google.com>
4335
4336 * Makefile.in: Add safe-strerror.c to gdbreplay and IPA, and change
4337 UNDO_GNULIB_CFLAGS to undo strerror_r instead of strerror.
4338 * config.in: Regenerate.
4339 * configure: Regenerate.
4340 * configure.ac: Don't check for strerror.
4341 * linux-i386-ipa.c (initialize_fast_tracepoint_trampoline_buffer):
4342 Call safe_strerror instead of strerror.
4343 * server.h (strerror): Remove this now-unnecessary declaration.
4344 * tracepoint.c (init_named_socket): Call safe_strerror instead of
4345 strerror.
4346 (gdb_agent_helper_thread): Likewise.
4347 * utils.c (perror_with_name): Likewise.
4348
4349 2019-11-26 Tom Tromey <tom@tromey.com>
4350
4351 * configure, config.in: Rebuild.
4352
4353 2019-11-26 Tom Tromey <tom@tromey.com>
4354
4355 * remote-utils.c (block_unblock_async_io): Use gdb_sigmask.
4356 * linux-low.c (linux_wait_for_event_filtered, linux_async): Use
4357 gdb_sigmask.
4358 * configure, config.in: Rebuild.
4359
4360 2019-11-26 Tom Tromey <tom@tromey.com>
4361
4362 * Makefile.in (PTHREAD_CFLAGS, PTHREAD_LIBS): New variables.
4363 (INTERNAL_CFLAGS_BASE): Use PTHREAD_CFLAGS.
4364 (GDBSERVER_LIBS): Use PTHREAD_LIBS.
4365 * acinclude.m4: Include ax_pthread.m4.
4366 * config.in, configure: Rebuild.
4367
4368 2019-11-26 Christian Biesinger <cbiesinger@google.com>
4369
4370 * debug.c (debug_set_output): Call safe_strerror instead of
4371 strerror.
4372 * linux-low.c (attach_proc_task_lwp_callback): Likewise.
4373 (linux_kill_one_lwp): Likewise.
4374 (linux_detach_one_lwp): Likewise.
4375 (linux_wait_for_event_filtered): Likewise.
4376 (store_register): Likewise.
4377 * lynx-low.c (lynx_attach): Likewise.
4378 * mem-break.c (insert_memory_breakpoint): Likewise.
4379 (remove_memory_breakpoint): Likewise.
4380 (delete_fast_tracepoint_jump): Likewise.
4381 (set_fast_tracepoint_jump): Likewise.
4382 (uninsert_fast_tracepoint_jumps_at): Likewise.
4383 (reinsert_fast_tracepoint_jumps_at): Likewise.
4384 * nto-low.c (nto_xfer_memory): Likewise.
4385 (nto_resume): Likewise.
4386
4387 2019-11-20 Luis Machado <luis.machado@linaro.org>
4388
4389 * linux-aarch64-low.c (is_sve_tdesc): Check against target feature
4390 instead of register count.
4391 * tdesc.c (tdesc_contains_feature): New function.
4392 * tdesc.h (tdesc_contains_feature): New prototype.
4393
4394 2019-11-15 Christian Biesinger <cbiesinger@google.com>
4395
4396 * Makefile.in: Add safe-strerror.c.
4397 * configure: Regenerate.
4398 * configure.ac: Don't source common.host.
4399
4400 2019-11-15 Christian Biesinger <cbiesinger@google.com>
4401
4402 * config.in: Regenerate.
4403 * configure: Regenerate.
4404
4405 2019-11-12 Andrew Burgess <andrew.burgess@embecosm.com>
4406
4407 * ax.c (ax_printf): Handle size_t_arg.
4408
4409 2019-11-06 Christian Biesinger <cbiesinger@google.com>
4410
4411 * linux-tdep.c (linux_info_proc): Use strtok_r instead of strtok.
4412 * mi/mi-main.c (output_cores): Likewise.
4413 * nat/linux-osdata.c (linux_xfer_osdata_cpus): Likewise.
4414 (linux_xfer_osdata_modules): Likewise.
4415 * remote.c (register_remote_support_xml): Likewise.
4416 * sparc64-tdep.c (adi_is_addr_mapped): Likewise.
4417 * xml-syscall.c (syscall_create_syscall_desc): Likewise.
4418
4419 2019-11-01 Christian Biesinger <cbiesinger@google.com>
4420
4421 * configure: Regenerate.
4422 * configure.ac: Remove check for strerror_r.
4423
4424 2019-10-31 Christian Biesinger <cbiesinger@google.com>
4425
4426 * config.in: Regenerate.
4427 * configure: Regenerate.
4428 * configure.ac: Also check for strerror_r.
4429
4430 2019-10-31 Christian Biesinger <cbiesinger@google.com>
4431
4432 * ax.h (debug_agent): Remove duplicate declaration.
4433
4434 2019-10-26 Tom de Vries <tdevries@suse.de>
4435
4436 * linux-aarch64-low.c: Fix typos in comments.
4437 * linux-arm-low.c: Same.
4438 * linux-low.c: Same.
4439 * linux-ppc-low.c: Same.
4440 * proc-service.c: Same.
4441 * regcache.h: Same.
4442 * server.c: Same.
4443 * tracepoint.c: Same.
4444 * win32-low.c: Same.
4445
4446 2019-10-25 Tom Tromey <tromey@adacore.com>
4447
4448 * utils.c (xstrdup): Remove.
4449
4450 2019-10-23 Tom Tromey <tom@tromey.com>
4451
4452 * configure, config.in: Rebuild.
4453
4454 2019-10-23 Tom Tromey <tom@tromey.com>
4455
4456 * configure: Rebuild.
4457 * acinclude.m4: Use m4_include, not sinclude.
4458
4459 2019-10-17 Tom Tromey <tromey@adacore.com>
4460
4461 * configure: Rebuild.
4462 * configure.ac: Use AC_CONFIG_HEADERS. Create stamp-h there, not
4463 in AC_CONFIG_FILES invocation.
4464 * Makefile.in (stamp-h, Makefile): Use new-style config.status
4465 invocation.
4466
4467 2019-10-16 Christian Biesinger <cbiesinger@google.com>
4468
4469 * server.c: Include xml-builtin.h.
4470 (get_xml_features): Don't declare xml_builtins here.
4471
4472 2019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
4473
4474 * Makefile.in: Remove references to vec-ipa.o.
4475
4476 2019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
4477
4478 * Makefile.in: Remove references to vec.c.
4479
4480 2019-10-02 Christian Biesinger <cbiesinger@google.com>
4481
4482 * server.c (server_waiting): Change to bool.
4483 (extended_protocol): Likewise.
4484 (response_needed): Likewise.
4485 (exit_requested): Likewise.
4486 (run_once): Likewise.
4487 (report_no_resumed): Likewise.
4488 (non_stop): Likewise.
4489 (disable_packet_vCont): Likewise.
4490 (disable_packet_Tthread): Likewise.
4491 (disable_packet_qC): Likewise.
4492 (disable_packet_qfThreadInfo): Likewise.
4493 (handle_general_set): Update.
4494 (handle_detach): Update.
4495 (handle_monitor_command): Update.
4496 (handle_query): Update.
4497 (captured_main): Update.
4498 (process_serial_event): Update.
4499 * server.h (server_waiting): Change to bool.
4500 (disable_packet_vCont): Likewise.
4501 (disable_packet_Tthread): Likewise.
4502 (disable_packet_qC): Likewise.
4503 (disable_packet_qfThreadInfo): Likewise.
4504 (run_once): Likewise.
4505 (non_stop): Likewise.
4506 * target.c (target_stop_and_wait): Update.
4507
4508 2019-10-02 Tom Tromey <tromey@adacore.com>
4509
4510 * Makefile.in (SFILES): Add common-inferior.c.
4511 (OBS): Add common-inferior.o.
4512 * server.c (startup_with_shell): Don't define.
4513
4514 2019-10-02 Andrew Burgess <andrew.burgess@embecosm.com>
4515
4516 * linux-low.c (linux_low_read_btrace): Update for change to
4517 std::vector.
4518
4519 2019-09-20 Christian Biesinger <cbiesinger@google.com>
4520
4521 * debug.c (debug_threads): Remove comment in favor of the header.
4522 * debug.h (using_threads): Add declaration.
4523 (debug_threads): Add comment.
4524 * linux-aarch64-low.c: Include debug.h and remove declaration of
4525 debug_threads.
4526 * nto-low.c: Likewise.
4527 * remote-utils.c: Likewise.
4528 * thread-db.c: Likewise.
4529
4530 2019-09-20 Ulrich Weigand <uweigand@de.ibm.com>
4531
4532 * configure.srv (ipa_ppc_linux_regobj): Remove powerpc-cell32l-ipa.o
4533 and powerpc-cell64l-ipa.o.
4534 (powerpc*-*-linux*): Remove powerpc-cell32l.o and powerpc-cell64l.o
4535 from srv_regobj. Remove rs6000/powerpc-cell32l.xml and
4536 rs6000/powerpc-cell64l.xml from srv_xmlfiles.
4537 (spu*-*-*): Remove.
4538
4539 * spu-low.c: Remove file.
4540
4541 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Remove.
4542 (parse_spufs_run): Remove.
4543 (ppc_get_pc): Remove Cell/B.E. support.
4544 (ppc_set_pc): Likewise.
4545 (ppc_breakpoint_at): Likewise.
4546 (ppc_arch_setup): Likewise.
4547 (ppc_get_ipa_tdesc_idx): Do not handle tdesc_powerpc_cell64l or
4548 tdesc_powerpc_cell32l.
4549 (initialize_low_arch): Do not call init_registers_powerpc_cell64l
4550 or init_registers_powerpc_cell32l.
4551 * linux-ppc-ipa.c (get_ipa_tdesc): Do not handle PPC_TDESC_CELL.
4552 (initialize_low_tracepoint): Do not call init_registers_powerpc_cell64l
4553 or init_registers_powerpc_cell32l.
4554 * linux-ppc-tdesc-init.h (PPC_TDESC_CELL): Mark as unused.
4555 (init_registers_powerpc_cell32l): Remove prototype.
4556 (init_registers_powerpc_cell64l): Likewise.
4557
4558 * target.h (struct target_ops): Remove qxfer_spu member.
4559 * server.c (handle_qxfer_spu): Remove.
4560 (qxfer_packets): Remove entry for "spu".
4561 (handle_query): No longer support qXfer:spu:read or qXfer:spu:write.
4562 * linux-low.c (SPUFS_MAGIC): Remove.
4563 (spu_enumerate_spu_ids): Remove.
4564 (linux_qxfer_spu): Remove.
4565 (linux_target_ops): Remove qxfer_spu member.
4566 * lynx-low.c (lynx_target_ops): Remove qxfer_spu member.
4567 * nto-low.c (nto_target_ops): Remove qxfer_spu member.
4568 * win32-low.c (win32_target_ops): Remove qxfer_spu member.
4569
4570 2019-08-23 Sergio Durigan Junior <sergiodj@redhat.com>
4571
4572 * Makefile.in (SFILES): Add 'gdbsupport/gdb-dlfcn.c'.
4573 (OBS): Add 'gdbsupport/gdb-dlfcn.o'.
4574 * config.in: Regenerate.
4575 * configure: Regenerate.
4576
4577 2019-08-15 Tom Tromey <tromey@adacore.com>
4578
4579 * target.c (target_write_memory): Use gdb::byte_vector.
4580
4581 2019-08-15 Tom Tromey <tromey@adacore.com>
4582
4583 * tracepoint.c (write_inferior_data_pointer)
4584 (write_inferior_integer, write_inferior_int8)
4585 (write_inferior_uinteger, m_tracepoint_action_download)
4586 (r_tracepoint_action_download, x_tracepoint_action_download)
4587 (l_tracepoint_action_download, clear_inferior_trace_buffer)
4588 (download_agent_expr, download_tracepoint_1)
4589 (download_trace_state_variables, upload_fast_traceframes): Update.
4590 * server.c (gdb_write_memory): Update.
4591 * remote-utils.c (relocate_instruction): Update.
4592 * proc-service.c (ps_pdwrite): Update.
4593 * mem-break.c (remove_memory_breakpoint)
4594 (delete_fast_tracepoint_jump, set_fast_tracepoint_jump)
4595 (uninsert_fast_tracepoint_jumps_at)
4596 (reinsert_fast_tracepoint_jumps_at): Update.
4597 * linux-x86-low.c (append_insns)
4598 (i386_install_fast_tracepoint_jump_pad)
4599 (amd64_write_goto_address, i386_write_goto_address): Update.
4600 * linux-s390-low.c (append_insns, s390_write_goto_address):
4601 Update.
4602 * linux-ppc-low.c (ppc_relocate_instruction)
4603 (ppc_install_fast_tracepoint_jump_pad, emit_insns)
4604 (ppc_write_goto_address): Update.
4605 * linux-aarch64-low.c (append_insns): Update.
4606 * target.h (struct target_ops): Update.
4607 (write_inferior_memory): Don't declare.
4608 * target.c (target_write_memory): Rename from
4609 write_inferior_memory. Remove old target_write_memory.
4610
4611 2019-08-15 Tom Tromey <tromey@adacore.com>
4612
4613 * target.c (write_inferior_memory): Use std::vector.
4614
4615 2019-08-06 Frank Ch. Eigler <fche@redhat.com>
4616
4617 PR build/24886
4618 * configure.ac: Drop enable-libmcheck support.
4619 * configure, config.in: Rebuild.
4620 * acinclude.m4: Don't include it.
4621
4622 2019-07-19 Alan Hayward <alan.hayward@arm.com>
4623
4624 * configure.srv: Remove Arm xml files.
4625
4626 2019-07-19 Alan Hayward <alan.hayward@arm.com>
4627
4628 * configure.srv: Add new files. Remove xml generated files.
4629 * linux-aarch32-low.c (initialize_low_arch_aarch32): Don't init
4630 registers.
4631 * linux-aarch32-low.h (tdesc_arm_with_neon): Remove.
4632 * linux-aarch32-tdesc.c: New file.
4633 * linux-aarch32-tdesc.h: New file.
4634 * linux-aarch64-low.c (aarch64_arch_setup): Call aarch32_linux_read_description.
4635 * linux-arm-low.c (init_registers_arm, tdesc_arm)
4636 (init_registers_arm_with_iwmmxt, tdesc_arm_with_iwmmxt)
4637 (init_registers_arm_with_vfpv2, tdesc_arm_with_vfpv2)
4638 (init_registers_arm_with_vfpv3, tdesc_arm_with_vfpv3): Remove.
4639 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
4640 (arm_store_vfpregset): Call arm_linux_get_tdesc_fp_type.
4641 (arm_read_description): Call arm_linux_read_description.
4642 (initialize_low_arch): Don't init registers.
4643 * linux-arm-tdesc.c: New file.
4644 * linux-arm-tdesc.h: New file.
4645
4646 2019-07-10 Alan Hayward <alan.hayward@arm.com>
4647
4648 * linux-arm-low.c (arm_fill_wmmxregset, arm_store_wmmxregset):
4649 Move counter inside for.
4650 (arm_read_description): Check ptrace earlier.
4651 (arm_arch_setup): Call arm_linux_init_hwbp_cap here.
4652
4653 2019-07-09 Tom Tromey <tom@tromey.com>
4654
4655 * configure: Rebuild.
4656 * configure.ac: Change common to gdbsupport.
4657 * acinclude.m4: Change common to gdbsupport.
4658 * Makefile.in (SFILES, OBS, GDBREPLAY_OBS, IPA_OBJS)
4659 (version-generated.c, gdbsupport/%-ipa.o, gdbsupport/%.o): Change
4660 common to gdbsupport.
4661 * ax.c, event-loop.c, fork-child.c, gdb_proc_service.h,
4662 gdbreplay.c, gdbthread.h, hostio-errno.c, hostio.c, i387-fp.c,
4663 inferiors.c, inferiors.h, linux-aarch64-tdesc-selftest.c,
4664 linux-amd64-ipa.c, linux-i386-ipa.c, linux-low.c,
4665 linux-tic6x-low.c, linux-x86-low.c, linux-x86-tdesc-selftest.c,
4666 linux-x86-tdesc.c, lynx-i386-low.c, lynx-low.c, mem-break.h,
4667 nto-x86-low.c, regcache.c, regcache.h, remote-utils.c, server.c,
4668 server.h, spu-low.c, symbol.c, target.h, tdesc.c, tdesc.h,
4669 thread-db.c, tracepoint.c, win32-i386-low.c, win32-low.c: Change
4670 common to gdbsupport.
4671
4672 2019-07-04 Alan Hayward <alan.hayward@arm.com>
4673
4674 * linux-aarch32-low.c (arm_read_description, arm_regsets): Use new
4675 defines.
4676 * linux-arm-low.c (arm_read_description, arm_regsets): Likewise.
4677
4678 2019-07-04 Alan Hayward <alan.hayward@arm.com>
4679
4680 * configure.srv: Remove legacy xml.
4681 * linux-aarch64-low.c (initialize_low_arch): Remove
4682 initialize_low_tdesc call.
4683 * linux-aarch64-tdesc-selftest.c: Remove file.
4684 * linux-aarch64-tdesc.h (initialize_low_tdesc): Remove.
4685 * linux-x86-low.c (initialize_low_arch): Remove
4686 initialize_low_tdesc call.
4687 * linux-x86-tdesc-selftest.c: Remove file.
4688 * linux-x86-tdesc.h (initialize_low_tdesc): Remove.
4689
4690 2019-06-20 Tom de Vries <tdevries@suse.de>
4691
4692 * linux-s390-ipa.c (get_ipa_tdesc)[!__s390x__]: Use
4693 s390_te_linux64_ft_collect_regmap for S390_TDESC_GS.
4694
4695 2019-06-19 Tom de Vries <tdevries@suse.de>
4696
4697 * debug.h (debug_write): Change return type to ssize_t.
4698 * debug.c (debug_write): Same.
4699
4700 2019-06-14 Tom Tromey <tom@tromey.com>
4701
4702 * configure.ac: Use new path to gnulib.
4703 * configure: Rebuild.
4704 * Makefile.in (INCGNU, $(GNULIB_BUILDDIR)/Makefile): Use new path
4705 to gnulib.
4706
4707 2019-06-11 Tom Tromey <tom@tromey.com>
4708
4709 * Makefile.in (SFILES): Add alloc.c.
4710 (OBS): Add alloc.o.
4711 (IPA_OBJS): Add alloc-ipa.o.
4712 (alloc-ipa.o): New target.
4713 (%.o: ../%.c): New pattern rule.
4714
4715 2019-06-10 Tom Tromey <tromey@adacore.com>
4716
4717 * remote-utils.c (look_up_one_symbol, relocate_instruction): Don't
4718 end warning with a newline.
4719 * linux-s390-low.c (s390_get_wordsize): Don't end warning with a
4720 newline.
4721 * thread-db.c (attach_thread): Don't end warning with a newline.
4722 (thread_db_notice_clone): Likewise.
4723 * tracepoint.c (gdb_agent_helper_thread): Don't end warning with a
4724 newline.
4725 * linux-x86-low.c (x86_get_min_fast_tracepoint_insn_len): Don't
4726 end warning with a newline.
4727
4728 2019-06-04 Pedro Alves <palves@redhat.com>
4729
4730 * server.c (captured_main): Use make_unique_xstrdup.
4731
4732 2019-06-02 Tom Tromey <tom@tromey.com>
4733
4734 * gdbreplay.c (fromhex): Remove.
4735 * Makefile.in (GDBREPLAY_OBS): Add rsp-low.o.
4736
4737 2019-05-29 Tom Tromey <tromey@adacore.com>
4738
4739 * configure: Rebuild.
4740
4741 2019-05-06 Kevin Buettner <kevinb@redhat.com>
4742
4743 * linux-x86-low.c (x86_fill_gregset): Don't compile 64-bit
4744 sign extension code on 32-bit builds.
4745
4746 2019-05-03 Eli Zaretskii <eliz@gnu.org>
4747
4748 * remote-utils.c:
4749 * gdbreplay.c [USE_WIN32API]: Remove the _WIN32_WINNT override.
4750
4751 2019-04-19 Tom Tromey <tom@tromey.com>
4752
4753 * server.c (struct vstop_notif): Derive from notif_event.
4754 <base>: Remove.
4755 (queue_stop_reply): Update.
4756 (remove_all_on_match_ptid): Change type. Rewrite.
4757 (discard_queued_stop_replies): Rewrite.
4758 (in_queued_stop_replies_ptid): Change type.
4759 (in_queued_stop_replies): Rewrite.
4760 (notif_stop): Update.
4761 (queue_stop_reply_callback): Update.
4762 (captured_main): Don't call initialize_notif.
4763 (push_stop_notification): Update.
4764 * notif.c (notif_write_event, handle_notif_ack)
4765 (notif_event_enque, notif_push): Update.
4766 (notif_event_xfree, initialize_notif): Remove.
4767 * notif.h (struct notif_event): Include <list>, not
4768 "common/queue.h".
4769 (struct notif_server) <queue>: Now a std::list.
4770 (notif_event_p): Remove typedef.
4771 (initialize_notif): Don't declare.
4772 (struct notif_event): Add virtual destructor.
4773
4774 2019-04-17 Alan Hayward <alan.hayward@arm.com>
4775
4776 * ax.c (ax_vdebug): Call debug_printf.
4777 * debug.c (debug_write): New function.
4778 * debug.h (debug_write): New declaration.
4779 * linux-low.c (sigchld_handler): Call debug_write.
4780
4781 2019-04-17 Alan Hayward <alan.hayward@arm.com>
4782
4783 * debug.c (debug_set_output): New function.
4784 (debug_vprintf): Send output to debug_file.
4785 (debug_flush): Likewise.
4786 * debug.h (debug_set_output): New declaration.
4787 * server.c (handle_monitor_command): Add debug-file option.
4788 (captured_main): Likewise.
4789
4790 2019-04-17 Alan Hayward <alan.hayward@arm.com>
4791
4792 * debug.c (remote_debug): Add definition.
4793 * debug.h (remote_debug): Add declaration.
4794 * hostio.c (remote_debug): Remove declaration.
4795 * remote-utils.c (struct ui_file): Likewise.
4796 (remote_debug): Likewise.
4797 * remote-utils.h (remote_debug): Likewise,
4798 * server.c (remote_debug): Remove definition.
4799
4800 2019-04-10 Kevin Buettner <kevinb@redhat.com>
4801
4802 * linux-x86-low.c (x86_fill_gregset): Sign extend EAX value
4803 when using a 64-bit gdbserver.
4804
4805 2019-04-09 Tom Tromey <tromey@adacore.com>
4806
4807 * linux-low.c (select_event_lwp): Use find_thread_in_random.
4808
4809 2019-04-08 Tom Tromey <tom@tromey.com>
4810
4811 * linux-low.c (linux_detach_one_lwp): Replace throw_exception with
4812 throw.
4813 (linux_resume_one_lwp): Likewise.
4814
4815 2019-04-08 Tom Tromey <tom@tromey.com>
4816
4817 * gdbreplay.c: Update.
4818 * linux-low.c: Update.
4819 * server.c: Update.
4820
4821 2019-04-08 Tom Tromey <tom@tromey.com>
4822
4823 * server.c: Use C++ exception handling.
4824 * linux-low.c: Use C++ exception handling.
4825 * gdbreplay.c: Use C++ exception handling.
4826
4827 2019-04-08 Tom Tromey <tom@tromey.com>
4828
4829 * server.c (handle_btrace_general_set, handle_qxfer_btrace)
4830 (handle_qxfer_btrace_conf, detach_or_kill_for_exit_cleanup)
4831 (captured_main, main): Update.
4832 * gdbreplay.c (main): Update.
4833
4834 2019-04-05 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4835
4836 * linux-low.c (linux_get_auxv): Remove static. Return auxv entry
4837 value in argument pointer, return 1 if the entry is found and 0
4838 otherwise. Move comment.
4839 (linux_get_hwcap, linux_get_hwcap2): Use modified linux_get_auxv.
4840 * linux-low.h (linux_get_auxv): Declare.
4841 * linux-ppc-low.c (is_elfv2_inferior): Use linux_get_auxv.
4842
4843 2019-04-05 Tom Tromey <tromey@adacore.com>
4844
4845 * server.c (gdbserver_usage): Use upper-case for metasyntactic
4846 variables.
4847
4848 2019-03-28 Alan Hayward <alan.hayward@arm.com>
4849
4850 * linux-low.c (AT_HWCAP2): Add define if not already included.
4851
4852 2019-03-26 Alan Hayward <alan.hayward@arm.com>
4853
4854 * linux-aarch64-low.c (aarch64_get_hwcap): Remove function.
4855 (aarch64_arch_setup): Call linux_get_hwcap.
4856 * linux-arm-low.c (arm_get_hwcap): Remove function.
4857 (arm_read_description): Call linux_get_hwcap.
4858 * linux-low.c (linux_get_auxv): New function.
4859 (linux_get_hwcap): Likewise.
4860 (linux_get_hwcap2): Likewise.
4861 * linux-low.h (linux_get_hwcap): New declaration.
4862 (linux_get_hwcap2): Likewise.
4863 * linux-ppc-low.c (ppc_get_auxv): Remove function.
4864 (ppc_arch_setup): Call linux_get_hwcap.
4865 * linux-s390-low.c (s390_get_hwcap): Remove function.
4866 (s390_arch_setup): Call linux_get_hwcap.
4867
4868 2019-03-22 Alan Hayward <alan.hayward@arm.com>
4869 Jiong Wang <jiong.wang@arm.com>
4870
4871 * linux-aarch64-low.c (aarch64_store_pauthregset): New function.
4872 * linux-low.c (regsets_store_inferior_registers): Allow optional reads
4873 to fail.
4874 * linux-low.h (enum regset_type): Add OPTIONAL_REGS.
4875
4876 2019-03-22 Alan Hayward <alan.hayward@arm.com>
4877 Jiong Wang <jiong.wang@arm.com>
4878
4879 * linux-aarch64-low.c (AARCH64_HWCAP_PACA): New define.
4880 (aarch64_get_hwcap): New function.
4881 (aarch64_arch_setup): Read APIA hwcap.
4882
4883 2019-03-22 Alan Hayward <alan.hayward@arm.com>
4884 Jiong Wang <jiong.wang@arm.com>
4885
4886 * linux-aarch64-ipa.c (get_ipa_tdesc): Add pauth param.
4887 (initialize_low_tracepoint): Likewise.
4888 * linux-aarch64-low.c (aarch64_arch_setup): Likewise.
4889 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Likewise.
4890 * linux-aarch64-tdesc.c (struct target_desc): Likewise.
4891 (aarch64_linux_read_description): Likewise.
4892 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Likewise.
4893
4894 2019-03-12 John Baldwin <jhb@FreeBSD.org>
4895
4896 * linux-x86-tdesc.c (i386_linux_read_description): Update call to
4897 i386_create_target_description for 'segments' parameter.
4898 * lynx-i386-low.c (lynx_i386_arch_setup): Likewise.
4899 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
4900 * win32-i386-low.c (i386_arch_setup): Likewise.
4901
4902 2019-03-12 Tom Tromey <tromey@adacore.com>
4903
4904 * linux-low.c (iterate_over_lwps): Update.
4905
4906 2019-03-06 Tom Tromey <tom@tromey.com>
4907
4908 * server.c (detach_or_kill_for_exit_cleanup): Remove parameter.
4909 (captured_main): Use SCOPE_EXIT.
4910
4911 2019-03-04 Sergio Durigan Junior <sergiodj@redhat.com>
4912
4913 * configure.srv: Use '$enable_unittest' instead of '$development'
4914 when checking whether to fill 'srv_regobj' on 'aarch64*-*-linux*'
4915 case.
4916
4917 2019-02-27 Tom Tromey <tromey@adacore.com>
4918
4919 * gdbreplay.c (logchar): Handle \r\n.
4920
4921 2019-02-07 Alan Hayward <alan.hayward@arm.com>
4922
4923 * linux-low.c (linux_attach): Add process before lwp.
4924 * server.c (attach_inferior): Check if already attached.
4925
4926 2019-02-07 Tom Tromey <tom@tromey.com>
4927
4928 * x86-tdesc.h: Rename include guard.
4929 * x86-low.h: Add include guard.
4930 * wincecompat.h: Rename include guard.
4931 * win32-low.h: Add include guard.
4932 * utils.h: Rename include guard.
4933 * tracepoint.h: Rename include guard.
4934 * tdesc.h: Rename include guard.
4935 * target.h: Rename include guard.
4936 * server.h: Rename include guard.
4937 * remote-utils.h: Rename include guard.
4938 * regcache.h: Rename include guard.
4939 * nto-low.h: Rename include guard.
4940 * notif.h: Add include guard.
4941 * mem-break.h: Rename include guard.
4942 * lynx-low.h: Add include guard.
4943 * linux-x86-tdesc.h: Add include guard.
4944 * linux-s390-tdesc.h: Add include guard.
4945 * linux-ppc-tdesc-init.h: Add include guard.
4946 * linux-low.h: Add include guard.
4947 * linux-aarch64-tdesc.h: Add include guard.
4948 * linux-aarch32-low.h: Add include guard.
4949 * inferiors.h: Rename include guard.
4950 * i387-fp.h: Rename include guard.
4951 * hostio.h: Rename include guard.
4952 * gdbthread.h: Rename include guard.
4953 * gdb_proc_service.h: Rename include guard.
4954 * event-loop.h: Rename include guard.
4955 * dll.h: Rename include guard.
4956 * debug.h: Rename include guard.
4957 * ax.h: Rename include guard.
4958
4959 2018-01-30 Szabolcs Nagy <szabolcs.nagy@arm.com>
4960
4961 PR gdb/23985
4962 * Makefile.in (IPAGENT_CFLAGS): Add UNDO_GNULIB_CFLAGS.
4963 (UNDO_GNULIB_CFLAGS): Undo gnulib replacements.
4964
4965 2019-01-25 Tom Tromey <tom@tromey.com>
4966
4967 * Makefile.in (INCLUDE_CFLAGS): Don't add -I for common.
4968
4969 2019-01-25 Tom Tromey <tom@tromey.com>
4970
4971 * win32-low.c: Fix common/ includes.
4972 * win32-i386-low.c: Fix common/ includes.
4973 * tracepoint.c: Fix common/ includes.
4974 * thread-db.c: Fix common/ includes.
4975 * target.h: Fix common/ includes.
4976 * symbol.c: Fix common/ includes.
4977 * spu-low.c: Fix common/ includes.
4978 * server.h: Fix common/ includes.
4979 * server.c: Fix common/ includes.
4980 * remote-utils.c: Fix common/ includes.
4981 * regcache.h: Fix common/ includes.
4982 * regcache.c: Fix common/ includes.
4983 * nto-x86-low.c: Fix common/ includes.
4984 * notif.h: Fix common/ includes.
4985 * mem-break.h: Fix common/ includes.
4986 * lynx-low.c: Fix common/ includes.
4987 * lynx-i386-low.c: Fix common/ includes.
4988 * linux-x86-tdesc-selftest.c: Fix common/ includes.
4989 * linux-x86-low.c: Fix common/ includes.
4990 * linux-low.c: Fix common/ includes.
4991 * inferiors.h: Fix common/ includes.
4992 * i387-fp.c: Fix common/ includes.
4993 * hostio.c: Fix common/ includes.
4994 * hostio-errno.c: Fix common/ includes.
4995 * gdbthread.h: Fix common/ includes.
4996 * gdbreplay.c: Fix common/ includes.
4997 * fork-child.c: Fix common/ includes.
4998 * event-loop.c: Fix common/ includes.
4999 * ax.c:
5000 (enum gdb_agent_op): Fix common/ includes.
5001
5002 2019-01-21 Tom Tromey <tom@tromey.com>
5003
5004 * tracepoint.c: Fix includes.
5005 * remote-utils.c: Fix includes.
5006 * linux-x86-low.c: Fix includes.
5007
5008 2019-01-01 Joel Brobecker <brobecker@adacore.com>
5009
5010 * gdbreplay.c (gdbreplay_version): Update copyright year in
5011 version message.
5012 * server.c (gdbserver_version): Likewise.
5013
5014 2018-12-05 Alan Hayward <alan.hayward@arm.com>
5015
5016 * linux-low.c (add_lwp): Switch ordering.
5017
5018 2018-11-29 Tom Tromey <tom@tromey.com>
5019
5020 * win32-low.c (win32_join): Take pid, not process.
5021 * target.h (struct target_ops) <join>: Change argument type.
5022 (join_inferior): Change argument name.
5023 * spu-low.c (spu_join): Take pid, not process.
5024 * server.c (handle_detach): Preserve pid before destroying
5025 process.
5026 * lynx-low.c (lynx_join): Take pid, not process.
5027 * linux-low.c (linux_join): Take pid, not process.
5028
5029 2018-11-23 Alan Hayward <alan.hayward@arm.com>
5030
5031 * linux-aarch64-low.c (aarch64_cannot_store_register): Remove.
5032 (aarch64_cannot_fetch_register): Likewise.
5033 (struct linux_target_ops): Update references.
5034
5035 2018-10-31 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5036
5037 * linux-ppc-low.c: Include nat/linux-ptrace.h.
5038
5039 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5040
5041 * configure.srv (ipa_ppc_linux_regobj): Add
5042 powerpc-isa207-htm-vsx32l-ipa.o and
5043 powerpc-isa207-htm-vsx64l-ipa.o.
5044 (powerpc*-*-linux*): Add powerpc-isa207-htm-vsx32l.o and
5045 powerpc-isa207-htm-vsx64l.o to srv_regobj. Add
5046 rs6000/power-htm-spr.xml, rs6000/power-htm-core.xml,
5047 rs6000/power64-htm-core.xml, rs6000/power-htm-fpu.xml,
5048 rs6000/power-htm-altivec.xml, rs6000/power-htm-vsx.xml,
5049 rs6000/power-htm-ppr.xml, rs6000/power-htm-dscr.xml,
5050 rs6000/power-htm-tar.xml, rs6000/powerpc-isa207-htm-vsx32l.xml,
5051 and rs6000/powerpc-isa207-htm-vsx64l.xml to srv_xmlfiles.
5052 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
5053 <PPC_TDESC_ISA207_HTM_VSX>: New enum value.
5054 (init_registers_powerpc_isa207_htm_vsx32l)
5055 (init_registers_powerpc_isa207_htm_vsx64l): Declare.
5056 * linux-ppc-low.c (ppc_fill_tm_sprregset, ppc_store_tm_sprregset)
5057 (ppc_store_tm_cgprregset, ppc_store_tm_cfprregset)
5058 (ppc_store_tm_cvrregset, ppc_store_tm_cvsxregset)
5059 (ppc_store_tm_cpprregset, ppc_store_tm_cdscrregset)
5060 (ppc_store_tm_ctarregset): New functions.
5061 (ppc_regsets): Add entries for HTM regsets.
5062 (ppc_arch_setup): Set htm in features struct when needed. Set
5063 sizes for the HTM regsets.
5064 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_HTM_VSX.
5065 (initialize_low_arch): Call
5066 init_registers_powerpc_isa207_htm_vsx32l and
5067 init_registers_powerpc_isa207_htm_vsx64l.
5068 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
5069 PPC_TDESC_ISA207_HTM_VSX.
5070 (initialize_low_tracepoint): Call
5071 init_registers_powerpc_isa207_htm_vsx32l and
5072 init_registers_powerpc_isa207_htm_vsx64l.
5073
5074 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5075
5076 * configure.srv (powerpc*-*-linux*): Add rs6000/power-ebb.xml and
5077 rs6000/power-linux-pmu.xml to srv_xmlfiles.
5078 * linux-ppc-low.c (ppc_store_ebbregset, ppc_fill_pmuregset)
5079 (ppc_store_pmuregset): New functions.
5080 (ppc_regsets): Add entries for ebb and pmu regsets.
5081 (ppc_arch_setup): Set isa207 in features struct if the ebb and
5082 pmu regsets are available. Set sizes for these regsets.
5083
5084 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5085
5086 * configure.srv (ipa_ppc_linux_regobj): Add
5087 powerpc-isa207-vsx64l-ipa.o and powerpc-isa207-vsx32l-ipa.o.
5088 (powerpc*-*-linux*): Add powerpc-isa207-vsx32l.o and
5089 powerpc-isa207-vsx64l.o to srv_regobj, add rs6000/power-tar.xml,
5090 rs6000/powerpc-isa207-vsx32l.xml, and
5091 rs6000/powerpc-isa207-vsx64l.xml to srv_xmlfiles.
5092 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
5093 <PPC_TDESC_ISA207_VSX>: New enum value.
5094 (init_registers_powerpc_isa207_vsx32l): Declare.
5095 (init_registers_powerpc_isa207_vsx64l): Declare.
5096 * linux-ppc-low.c (ppc_fill_tarregset): New function.
5097 (ppc_store_tarregset): New function.
5098 (ppc_regsets): Add entry for the TAR regset.
5099 (ppc_arch_setup): Set isa207 in features struct when needed. Set
5100 size for the TAR regsets.
5101 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_VSX.
5102 (initialize_low_arch): Call init_registers_powerpc_isa207_vsx32l
5103 and init_registers_powerpc_isa207_vsx64l.
5104 * linux-ppc-ipa.c (get_ipa_tdesc): Handle PPC_TDESC_ISA207_VSX.
5105 (initialize_low_tracepoint): Call
5106 init_registers_powerpc_isa207_vsx32l and
5107 init_registers_powerpc_isa207_vsx64l.
5108
5109 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
5110 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5111
5112 * configure.srv (ipa_ppc_linux_regobj): Add
5113 powerpc-isa205-ppr-dscr-vsx32l-ipa.o and
5114 powerpc-isa205-ppr-dscr-vsx64l-ipa.o.
5115 (powerpc*-*-linux*): Add powerpc-isa205-ppr-dscr-vsx32l.o and
5116 powerpc-isa205-ppr-dscr-vsx64l.o to srv_regobj, add
5117 rs6000/power-dscr.xml, rs6000/power-ppr.xml,
5118 rs6000/powerpc-isa205-ppr-dscr-vsx32l.xml and
5119 rs6000/powerpc-isa205-ppr-dscr-vsx64l.xml to srv_xmlfiles.
5120 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
5121 <PPC_TDESC_ISA205_PPR_DSCR_VSX>: New enum value.
5122 (init_registers_powerpc_isa205_ppr_dscr_vsx32l)
5123 (init_registers_powerpc_isa205_ppr_dscr_vsx64l): Declare.
5124 * linux-ppc-low.c: Include "elf/common.h" and <sys/uio.h>.
5125 (ppc_hwcap): Add comment.
5126 (ppc_hwcap2): New global.
5127 (ppc_check_regset, ppc_fill_pprregset, ppc_store_pprregset)
5128 (ppc_fill_dscrregset, ppc_store_dscrregset): New functions.
5129 (ppc_regsets): Add entries for the DSCR and PPR regsets.
5130 (ppc_arch_setup): Get AT_HWCAP2. Set ppr_dscr in features struct
5131 when needed. Set sizes for the the DSCR and PPR regsets.
5132 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA205_PPR_DSCR_VSX.
5133 (initialize_low_arch): Call
5134 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
5135 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
5136 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
5137 PPC_TDESC_ISA205_PPR_DSCR_VSX.
5138 (initialize_low_tracepoint): Call
5139 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
5140 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
5141
5142 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5143
5144 * linux-ppc-low.c (ppc_fill_vrregset): Remove memset calls.
5145
5146 2018-10-10 Sergio Durigan Junior <sergiodj@redhat.com>
5147 Simon Marchi <simark@simark.ca>
5148
5149 * acinclude.m4: Include "../selftest.m4".
5150 * configure: Regenerate.
5151 * configure.ac: Use "GDB_AC_SELFTEST".
5152 * configure.srv: Use "$enable_unittests" instead of
5153 "$development" when checking whether unit tests have been
5154 enabled.
5155 * server.c (captured_main): Update message informing that
5156 selftests have been disabled.
5157
5158 2018-10-04 Tom Tromey <tom@tromey.com>
5159
5160 * configure: Rebuild.
5161
5162 2018-10-04 Tom Tromey <tom@tromey.com>
5163
5164 * server.c (handle_status): Rename inner "thread".
5165 (process_serial_event): Declare "res" in 'm' case.
5166 * linux-low.c (last_thread_of_process_p, find_lwp_pid)
5167 (iterate_over_lwps): Rename inner "thread".
5168 (linux_qxfer_libraries_svr4): Rename inner "len".
5169 * gdbthread.h (find_thread_in_random): Rename inner "thread".
5170
5171 2018-10-01 Gary Benson <gbenson@redhat.com>
5172
5173 * gdb_proc_service.h: Moved common code to
5174 common/gdb_proc_service.h.
5175
5176 2018-10-01 Gary Benson <gbenson@redhat.com>
5177
5178 * gdb_proc_service.h: Synchronize comments and whitespace with
5179 GDB's version of this file.
5180
5181 2018-09-25 Tom Tromey <tom@tromey.com>
5182
5183 * configure: Rebuild.
5184 * configure.ac (WARN_CFLAGS): Don't remove -Wmissing-prototypes.
5185
5186 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
5187
5188 * Makefile.in (gdbserver$(EXEEXT)): Sort OBS.
5189 (gdbreplay$(EXEEXT)): Sort GDBREPLAY_OBS.
5190 ($(IPA_LIB)): Sort IPA_OBJS.
5191
5192 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
5193
5194 * Makefile.in: Remove references to $(ADD_DEPS).
5195
5196 2018-09-16 Tom Tromey <tom@tromey.com>
5197
5198 * remote-utils.c (remote_open): Use GNU style for metasyntactic
5199 variables.
5200 * gdbreplay.c (gdbreplay_usage): Use GNU style for metasyntactic
5201 variables.
5202
5203 2018-09-05 Tom Tromey <tom@tromey.com>
5204
5205 * configure: Rebuild.
5206
5207 2018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
5208
5209 PR build/23399
5210 * tracepoint.c (IPA_SYM_STRUCT_NAME): Define.
5211
5212 2018-08-27 Tom Tromey <tom@tromey.com>
5213
5214 PR build/23087:
5215 * configure: Rebuild.
5216
5217 2018-08-27 Tom Tromey <tom@tromey.com>
5218
5219 * linux-s390-low.c (s390_emit_ext, s390_emit_litpool)
5220 (s390_emit_const, s390_emit_reg, s390_emit_zero_ext)
5221 (s390_emit_stack_adjust, s390_emit_set_r2, s390x_emit_ext)
5222 (s390x_emit_const, s390x_emit_reg, s390x_emit_zero_ext)
5223 (s390x_emit_stack_adjust): Add casts to unsigned char.
5224
5225 2018-08-22 Simon Marchi <simon.marchi@ericsson.com>
5226
5227 PR gdb/23374
5228 PR gdb/23375
5229 * server.h (struct client_state) <disable_randomization>:
5230 Initialize to 1.
5231
5232 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
5233
5234 * linux-mips-low.c (mips_collect_ptrace_register): Remove unused
5235 variable.
5236 (mips_supply_ptrace_register): Likewise.
5237
5238 2018-07-22 Tom Tromey <tom@tromey.com>
5239
5240 * configure: Rebuild.
5241
5242 2018-07-22 Tom Tromey <tom@tromey.com>
5243
5244 * win32-low.c (win32_create_inferior): Remove unused variables.
5245 * gdbreplay.c (remote_open): Remove unused variable.
5246 * remote-utils.c (remote_prepare): Remove unused variable.
5247 * x86-tdesc.h (X86_TDESC_H): Define.
5248 (amd64_expedite_regs): Define conditionally.
5249 (i386_expedite_regs): Mark ATTRIBUTE_UNUSED.
5250 * linux-x86-tdesc.c (i386_tdescs): Move inside #if.
5251 * remote-utils.c (readchar): Remove unused variable.
5252
5253 2018-07-13 Pedro Alves <palves@redhat.com>
5254
5255 * linux-low.c (linux_kill): Change parameter to process_info
5256 pointer instead of pid. Adjust.
5257 * lynx-low.c (lynx_kill): Likewise.
5258 * nto-low.c (nto_kill): Likewise.
5259 * spu-low.c (spu_kill): Likewise.
5260 * win32-low.c (win32_kill): Likewise.
5261 * server.c (handle_v_kill, kill_inferior_callback)
5262 (detach_or_kill_for_exit): Adjust.
5263 * target.c (kill_inferior): Change parameter to process_info
5264 pointer instead of pid. Adjust.
5265 * target.h (struct target_ops) <kill>: Change parameter to
5266 process_info pointer instead of pid. Adjust all implementations
5267 and callers.
5268 (kill_inferior): Likewise.
5269
5270 2018-07-13 Pedro Alves <palves@redhat.com>
5271
5272 * linux-low.c (linux_detach, linux_join): Change parameter to
5273 process_info pointer instead of pid. Adjust.
5274 * lynx-low.c (lynx_detach, lynx_join): Likewise.
5275 * nto-low.c (nto_detach): Likewise.
5276 * spu-low.c (spu_detach, spu_join): Likewise.
5277 * win32-low.c (win32_detach, win32_join): Likewise.
5278 * server.c (handle_detach, detach_or_kill_for_exit): Adjust.
5279 * target.h (struct target_ops) <detach, join>: Change parameter to
5280 process_info pointer instead of pid. Adjust all implementations
5281 and callers.
5282 (detach_inferior, join_inferior): Rename 'pid' parameter to
5283 'proc'.
5284
5285 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
5286 Jan Kratochvil <jan.kratochvil@redhat.com>
5287 Paul Fertser <fercerpav@gmail.com>
5288 Tsutomu Seki <sekiriki@gmail.com>
5289
5290 * Makefile.in (SFILES): Add '$(srcdir)/common/netstuff.c'.
5291 (OBS): Add 'common/netstuff.o'.
5292 (GDBREPLAY_OBS): Likewise.
5293 * gdbreplay.c: Include 'wspiapi.h' and 'netstuff.h'.
5294 (remote_open): Implement support for IPv6
5295 connections.
5296 * remote-utils.c: Include 'netstuff.h', 'filestuff.h'
5297 and 'wspiapi.h'.
5298 (handle_accept_event): Accept connections from IPv6 sources.
5299 (remote_prepare): Handle IPv6-style hostnames; implement
5300 support for IPv6 connections.
5301 (remote_open): Implement support for printing connections from
5302 IPv6 sources.
5303
5304 2018-07-11 Pedro Alves <palves@redhat.com>
5305
5306 PR gdb/23377
5307 * mem-break.c (any_persistent_commands): Add process_info
5308 parameter and use it instead of relying on the current process.
5309 Change return type to bool.
5310 * mem-break.h (any_persistent_commands): Add process_info
5311 parameter and change return type to bool.
5312 * server.c (handle_detach): Remove require_running_or_return call.
5313 Look up the process_info for the process we're about to detach.
5314 If not found, return back error to GDB. Adjust
5315 any_persistent_commands call to pass down a process pointer.
5316
5317 2018-07-11 Pedro Alves <palves@redhat.com>
5318
5319 * i387-fp.c (i387_cache_to_fsave, cache_to_fxsave)
5320 (i387_cache_to_xsave): Use regcache_raw_get_unsigned_by_name
5321 instead of collect_register_by_name.
5322 * regcache.c (regcache_raw_get_unsigned_by_name): New.
5323 * regcache.h (regcache_raw_get_unsigned_by_name): New.
5324
5325 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
5326 Pedro Alves <palves@redhat.com>
5327
5328 * linux-low.c (initialize_low): Call linux_proc_init_warnings.
5329
5330 2018-07-03 Tom Tromey <tom@tromey.com>
5331
5332 * linux-low.c: Update.
5333 * lynx-low.c: Update.
5334 * mem-break.c: Update.
5335 * nto-low.c: Update.
5336 * remote-utils.c: Update.
5337 * server.c: Update.
5338 * spu-low.c: Update.
5339 * target.c: Update.
5340 * win32-low.c: Update.
5341
5342 2018-07-03 Tom Tromey <tom@tromey.com>
5343
5344 * server.c: Update.
5345
5346 2018-07-03 Tom Tromey <tom@tromey.com>
5347
5348 * linux-low.c: Update.
5349
5350 2018-07-03 Tom Tromey <tom@tromey.com>
5351
5352 * target.c: Update.
5353
5354 2018-07-03 Tom Tromey <tom@tromey.com>
5355
5356 * linux-low.c: Update.
5357 * linux-mips-low.c: Update.
5358 * lynx-low.c: Update.
5359 * nto-low.c: Update.
5360 * remote-utils.c: Update.
5361 * server.c: Update.
5362 * spu-low.c: Update.
5363 * target.c: Update.
5364 * thread-db.c: Update.
5365
5366 2018-07-03 Tom Tromey <tom@tromey.com>
5367
5368 * linux-low.c: Update.
5369 * linux-mips-low.c: Update.
5370 * lynx-low.c: Update.
5371 * mem-break.c: Update.
5372 * nto-low.c: Update.
5373 * remote-utils.c: Update.
5374 * server.c: Update.
5375 * spu-low.c: Update.
5376 * target.c: Update.
5377 * tracepoint.c: Update.
5378
5379 2018-07-03 Tom Tromey <tom@tromey.com>
5380
5381 * linux-low.c: Update.
5382 * linux-ppc-low.c: Update.
5383 * linux-x86-low.c: Update.
5384 * proc-service.c: Update.
5385 * server.c: Update.
5386 * spu-low.c: Update.
5387 * thread-db.c: Update.
5388 * win32-low.c: Update.
5389
5390 2018-07-03 Tom Tromey <tom@tromey.com>
5391
5392 * linux-low.c: Update.
5393 * lynx-low.c: Update.
5394 * nto-low.c: Update.
5395 * remote-utils.c: Update.
5396 * spu-low.c: Update.
5397 * thread-db.c: Update.
5398 * win32-low.c: Update.
5399
5400 2018-06-29 Joel Brobecker <brobecker@adacore.com>
5401
5402 * linux-x86-tdesc.c (amd64_linux_read_description): Add missing
5403 parameter in call to 'amd64_create_target_description'.
5404
5405 2018-06-28 Jan Kratochvil <jan.kratochvil@redhat.com>
5406
5407 * x86-tdesc.h: Remove executable permission flag.
5408
5409 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
5410
5411 * configure.ac: Remove AC_PREREQ, add missing quoting.
5412 * configure: Re-generate.
5413 * config.in: Re-generate.
5414 * aclocal.m4: Re-generate.
5415
5416 2018-06-18 Simon Marchi <simon.marchi@ericsson.com>
5417
5418 * tracepoint.h (current_traceframe): Remove declaration.
5419
5420 2018-06-18 Alan Hayward <alan.hayward@arm.com>
5421
5422 * linux-aarch64-low.c (is_sve_tdesc): New function.
5423 (aarch64_sve_regs_copy_to_regcache): Likewise.
5424 (aarch64_sve_regs_copy_from_regcache): Likewise.
5425 (aarch64_regs_info): Add SVE checks.
5426 (initialize_low_arch): Initialize SVE.
5427
5428 2018-06-18 Alan Hayward <alan.hayward@arm.com>
5429
5430 * Makefile.in: Add aarch64-sve-linux-ptrace.c.
5431
5432 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5433
5434 * linux-aarch64-ipa.c (get_ipa_tdesc): Add null VQ param.
5435 (initialize_low_tracepoint): Likewise
5436 * linux-aarch64-low.c (aarch64_arch_setup): Get VQ.
5437 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Add null VQ
5438 param.
5439 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add VQ
5440 checks.
5441 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Add VQ.
5442
5443 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5444
5445 * server.h (PBUFSIZ): Increase size
5446
5447 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5448
5449 * regcache.c (regcache::raw_compare): New function.
5450 * regcache.h (regcache::raw_compare): New declaration.
5451
5452 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5453
5454 * regcache.c (new_register_cache): Use new.
5455 (free_register_cache): Use delete.
5456 (register_data): Use const.
5457 (supply_register): Move body inside regcache.
5458 (regcache::raw_supply): New override function.
5459 (collect_register): Move body inside regcache.
5460 (regcache::raw_collect): New override function.
5461 (regcache::get_register_status): New override function.
5462 * regcache.h (struct regcache): Inherit from reg_buffer_common.
5463
5464 2018-06-09 Tom Tromey <tom@tromey.com>
5465
5466 * event-loop.c (gdb_event, gdb_event_p): Remove typedefs. Don't
5467 declare queue.
5468 (event_queue): Use std::queue.
5469 (gdb_event_xfree): Remove.
5470 (initialize_event_loop, process_event, wait_for_event): Update.
5471
5472 2018-06-08 Stan Cox <scox@redhat.com>
5473
5474 * win32-low.c (win32_create_inferior): last_ptid and last_status
5475 moved to client_state.
5476
5477 2018-06-08 Pedro Alves <palves@redhat.com>
5478
5479 * Makefile.in (GDBREPLAY_OBS): Add common/cleanups.o,
5480 common/common-exceptions.o, common/common-utils.o,
5481 common/errors.o, common/print-utils.o and utils.o.
5482 * gdbreplay.c: Include "common-defs.h" instead of the two
5483 'config.h's here. Don't include stdio.h, errno.h, stdlib.h,
5484 string.h or alloca.h.
5485 (perror_with_name): Delete.
5486 (remote_open): Use xstrdup instead of strdup.
5487 (main): Rename to ...
5488 (captured_main): ... this.
5489 (main): New.
5490
5491 2018-06-08 Tom Tromey <tom@tromey.com>
5492
5493 * linux-low.c (linux_low_read_btrace): Update.
5494
5495 2018-06-04 Stan Cox <scox@redhat.com>
5496
5497 * server.h (struct client_state): New.
5498 * server.c (cont_thread, general_thread, multi_process)
5499 (report_fork_events, report_vfork_events, report_exec_events)
5500 (report_thread_events, swbreak_feature, hwbreak_feature)
5501 (vCont_supported, disable_randomization, pass_signals)
5502 (program_signals, program_signals_p, last_status, last_ptid, own_buf):
5503 Moved to client_state.
5504 * remote-utils.c (remote_debug, noack_mode)
5505 (transport_is_reliable): Moved to client_state.
5506 * tracepoint.c (current_traceframe): Moved to client_state.
5507
5508 Update all callers.
5509 * server.c, remote-utils.c, tracepoint.c, fork-child.c,
5510 linux-low.c, remote-utils.h, target.c: Use client_state.
5511
5512 2018-05-31 Alan Hayward <alan.hayward@arm.com>
5513
5514 * configure.srv: Add new c/h file.
5515
5516 2018-05-31 Alan Hayward <alan.hayward@arm.com>
5517
5518 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add
5519 null VQ.
5520
5521 2018-05-25 Maciej W. Rozycki <macro@mips.com>
5522
5523 * gdb.arch/mips-fpregset-core.exp: New test.
5524 * gdb.arch/mips-fpregset-core.c: New test source.
5525
5526 2018-05-23 Erik Kurzinger <ekurzinger@nvidia.com>
5527
5528 PR server/23198
5529 * hostio.c (require_int): Do not report overflow for integers
5530 between 0xfffffff and 0x7fffffff.
5531
5532 2018-05-22 Maciej W. Rozycki <macro@mips.com>
5533
5534 * linux-mips-low.c [HAVE_PTRACE_GETREGS] (mips_collect_register)
5535 (mips_supply_register): Move outside HAVE_PTRACE_GETREGS.
5536 (mips_collect_ptrace_register, mips_supply_ptrace_register): New
5537 functions.
5538 (the_low_target): Wire them.
5539
5540 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5541
5542 * linux-ppc-low.c (ppc_fill_vrregset): Add vscr_offset variable.
5543 Set vscr_offset to 0 in little-endian mode and 12 in big-endian
5544 mode. Call collect_register_by_name with vscr using
5545 vscr_offset. Zero-pad vscr and vrsave fields in collector buffer.
5546 (ppc_store_vrregset): Add and set vscr_offset variable as in
5547 ppc_fill_vrregset. Call supply_register_by_name with vscr using
5548 vscr_offset.
5549
5550 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5551
5552 * linux-ppc-low.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
5553 (ppc_arch_setup): Change SIZEOF_VRREGS and SIZEOF_VSXREGS to
5554 PPC_LINUX_SIZEOF_VRREGSET and PPC_LINUX_SIZEOF_VSXREGSET.
5555
5556 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5557
5558 * linux-ppc-low.c (ppc_fill_vsxregset): Remove ppc_hwcap check.
5559 (ppc_store_vsxregset): Likewise.
5560 (ppc_fill_vrregset): Likewise.
5561 (ppc_store_vrregset): Likewise.
5562 (ppc_fill_evrregset): Likewise.
5563 (ppc_store_evrregset): Likewise.
5564 (ppc_regsets): Set VSX/VR/EVR regset sizes to 0.
5565 (ppc_arch_setup): Iterate through ppc_regsets and set sizes when
5566 needed.
5567
5568 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5569
5570 * linux-ppc-low.c (ppc_arch_setup): Remove code for getting the
5571 wordsize of the inferior. Call ppc_linux_target_wordsize.
5572
5573 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5574
5575 * configure.srv (srv_tgtobj): Add arch/ppc-linux-common.o.
5576 * Makefile.in (SFILES): Add arch/ppc-linux-common.c.
5577 * linux-ppc-tdesc.h: Rename to linux-ppc-tdesc-init.h.
5578 * linux-ppc-tdesc-init.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
5579 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
5580 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
5581 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
5582 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
5583 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
5584 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
5585 (tdesc_powerpc_e500l): Remove.
5586 * linux-ppc-ipa.c: Include arch/ppc-linux-tdesc.h and
5587 linux-ppc-tdesc-init.h. Don't include linux-ppc-tdesc.h.
5588 * linux-ppc-low.c: Include arch/ppc-linux-common.h,
5589 arch/ppc-linux-tdesc.h, and linux-ppc-tdesc-init.h. Don't include
5590 linux-ppc-tdesc.h.
5591 (ppc_arch_setup): Remove target description matching code. Fill a
5592 ppc_linux_features struct and call ppc_linux_match_description
5593 with it.
5594
5595 2018-05-22 Maciej W. Rozycki <macro@mips.com>
5596
5597 * linux-mips-low.c (mips_cannot_fetch_register): Return 1 if the
5598 width of the requested register exceeds the width of the
5599 `ptrace' data type.
5600 (mips_cannot_store_register): Likewise.
5601
5602 2018-05-21 Maciej W. Rozycki <macro@mips.com>
5603
5604 * linux-mips-low.c (mips_fetch_register): New function. Update
5605 preceding comment.
5606 (mips_store_gregset): Supply 0 rather than $restart for $zero.
5607 (the_low_target): Wire `mips_fetch_register'.
5608
5609 2018-05-10 Joel Brobecker <brobecker@adacore.com>
5610
5611 * lynx-i386-low.c (LYNXOS_178): New macro.
5612 [LYNXOS_178] (usr_fcontext_t): Provide a definition that matches
5613 the layout on LynxOS-178.
5614 (lynx_i386_fill_fpregset, lynx_i386_store_fpregset): Do not
5615 handle floating point registers that are not supported by
5616 LynxOS-178.
5617
5618 2018-05-10 Tom Tromey <tom@tromey.com>
5619
5620 * configure: Rebuild.
5621
5622 2018-05-10 Joel Brobecker <brobecker@adacore.com>
5623
5624 PR server/23158:
5625 * tdesc.h (init_target_desc) <expedite_regs>: New parameter.
5626 * tdesc.c (init_target_desc) <expedite_regs>: New parameter.
5627 Use it to set the expedite_regs field in the given tdesc.
5628 * x86-tdesc.h: New file.
5629 * linux-aarch64-tdesc.c (aarch64_linux_read_description):
5630 Adjust following the addition of the new expedite_regs parameter
5631 to init_target_desc.
5632 * linux-tic6x-low.c (tic6x_read_description): Likewise.
5633 * linux-x86-tdesc.c: #include "x86-tdesc.h".
5634 (i386_linux_read_description, amd64_linux_read_description):
5635 Adjust following the addition of the new expedite_regs parameter
5636 to init_target_desc.
5637 * lynx-i386-low.c: #include "x86-tdesc.h".
5638 (lynx_i386_arch_setup): Adjust following the addition of the new
5639 expedite_regs parameter to init_target_desc.
5640 * nto-x86-low.c: #include "x86-tdesc.h".
5641 (nto_x86_arch_setup): Adjust following the addition of the new
5642 expedite_regs parameter to init_target_desc.
5643 * win32-i386-low.c: #include "x86-tdesc.h".
5644 (i386_arch_setup): Adjust following the addition of the new
5645 expedite_regs parameter to init_target_desc.
5646
5647 2018-05-10 Joel Brobecker <brobecker@adacore.com>
5648
5649 PR server/23158:
5650 * win32-low.c (win32_create_inferior): Add call to my_wait
5651 setting last_status global.
5652
5653 2018-05-10 Joel Brobecker <brobecker@adacore.com>
5654
5655 PR server/23158:
5656 * win32-low.c (create_process): Only call gdb_tilde_expand if
5657 inferior_cwd is not NULL.
5658
5659 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
5660
5661 * i387-fp.c (i387_cache_to_xsave): Only write x87 control
5662 registers to the cache if their values have changed.
5663 (i387_xsave_to_cache): Provide default values for x87 control
5664 registers when these features are available, but disabled.
5665 * regcache.c (supply_register_by_name_zeroed): New function.
5666 * regcache.h (supply_register_by_name_zeroed): Declare new
5667 function.
5668
5669 2018-05-07 Tom Tromey <tom@tromey.com>
5670
5671 * configure: Rebuild.
5672
5673 2018-05-04 Tom Tromey <tom@tromey.com>
5674
5675 * configure: Rebuild.
5676
5677 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
5678 Pedro Alves <palves@redhat.com>
5679
5680 * linux-aarch64-low.c (aarch64_stopped_data_address):
5681 Likewise.
5682
5683 2018-04-27 Tom Tromey <tom@tromey.com>
5684
5685 * configure: Rebuild.
5686
5687 2018-04-23 Tom Tromey <tom@tromey.com>
5688
5689 * configure: Rebuild.
5690
5691 2018-04-19 Simon Marchi <simon.marchi@ericsson.com>
5692
5693 * Makefile.in (depcomp): Add "..".
5694 (all_deps_files): New and use it.
5695
5696 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5697
5698 * configure.srv (aarch64*-*-linux*): Don't include xml.
5699 (i[34567]86-*-cygwin*): Likewise.
5700 (i[34567]86-*-linux*): Likewise.
5701 (i[34567]86-*-lynxos*): Likewise.
5702 (i[34567]86-*-mingw32ce*): Likewise.
5703 (i[34567]86-*-mingw*): Likewise.
5704 (i[34567]86-*-nto*): Likewise.
5705 (tic6x-*-uclinux): Likewise.
5706 (x86_64-*-linux*): Likewise.
5707 (x86_64-*-mingw*): Likewise.
5708 (x86_64-*-cygwin*): Likewise.
5709
5710 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5711
5712 * tdesc.c: Remove xml parameter.
5713
5714 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5715
5716 * server.c (get_features_xml): Remove cast.
5717 * tdesc.c (void target_desc::accept): Fill in function.
5718 (tdesc_get_features_xml): Remove old xml creation.
5719 (print_xml_feature::visit_pre): Add xml vistor.
5720 * tdesc.h (struct target_desc): Make xmltarget mutable.
5721 (tdesc_get_features_xml): Remove declaration.
5722
5723 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5724
5725 * tdesc.c (tdesc_architecture_name): Add new function.
5726 (tdesc_osabi_name): Likewise.
5727 (tdesc_get_features_xml): Use new functions.
5728
5729 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5730
5731 * tdesc.c (tdesc_create_flags): Remove.
5732 (tdesc_add_flag): Likewise.
5733 (tdesc_named_type): Likewise.
5734 (tdesc_create_union): Likewise.
5735 (tdesc_create_struct): Likewise.
5736 (tdesc_create_vector): Likewise.
5737 (tdesc_add_bitfield): Likewise.
5738 (tdesc_add_field): Likewise.
5739 (tdesc_set_struct_size): Likewise.
5740
5741 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5742
5743 * tdesc.c (~target_desc): Remove implictly deleted items.
5744 (init_target_desc): Iterate all features.
5745 (tdesc_get_features_xml): Use vector.
5746 (tdesc_create_feature): Create feature.
5747 * tdesc.h (tdesc_feature) Remove
5748 (target_desc): Add features.
5749
5750 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5751
5752 * Makefile.in: Add common/tdesc.c
5753 * tdesc.c (init_target_desc): init all reg_defs from register
5754 vector.
5755 (tdesc_create_reg): Create tdesc_reg.
5756 * tdesc.h (tdesc_feature): Add register vector.
5757
5758 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
5759
5760 * tdesc.h (struct target_desc) <features>: Change type to
5761 std::vector<std::string>.
5762 * tdesc.c (target_desc::~target_desc): Adjust to std::vector
5763 changes.
5764 (tdesc_get_features_xml): Likewise.
5765 (tdesc_create_feature): Likewise.
5766
5767 2018-03-26 Alan Hayward <alan.hayward@arm.com>
5768
5769 * regcache.c (find_register_by_number): Return a ref.
5770 (find_regno): Use references.
5771 (register_size): Likewise.
5772 (register_data): Likewise.
5773 * tdesc.c (target_desc::~target_desc): Remove free calls.
5774 (target_desc::operator==): Use std::vector compare.
5775 (init_target_desc): Use reference.
5776 (tdesc_create_reg): Use reg constructors.
5777 * tdesc.h (struct target_desc): Replace pointer with object.
5778
5779 2018-03-23 Alan Hayward <alan.hayward@arm.com>
5780
5781 * regcache.c (find_register_by_number): Make static.
5782 (find_regno): Use find_register_by_number
5783 * regcache.h (struct reg): Remove declaration.
5784
5785 2018-03-23 Alan Hayward <alan.hayward@arm.com>
5786
5787 * tdesc.c (target_desc::~target_desc): Move to here.
5788 (target_desc::operator==): Likewise.
5789 * tdesc.h (target_desc::~target_desc): Move from here.
5790 (target_desc::operator==): Likewise.
5791
5792 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
5793
5794 * linux-s390-low.c (s390_get_wordsize): Correct brace style.
5795
5796 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
5797
5798 * linux-s390-ipa.c (get_ipa_tdesc): Add handling for
5799 S390_TDESC_GS.
5800 * linux-s390-low.c (s390_get_ipa_tdesc_idx): Likewise.
5801 (initialize_low_tracepoint): Call init_registers_s390x_gs_linux64
5802 and init_registers_s390_gs_linux64.
5803
5804 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
5805
5806 * linux-s390-low.c (s390_fill_gs): Remove function.
5807 (s390_fill_gsbc): Remove function.
5808 (s390_regsets): Set fill functions for the guarded storage regsets
5809 to NULL.
5810
5811 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
5812
5813 * linux-s390-low.c (s390_get_hwcap): Replace tdesc parameter by
5814 the word size. Add comment.
5815 (s390_get_wordsize): New function.
5816 (s390_arch_setup): No longer select a temporary tdesc to fetch the
5817 pswm with it. Instead, use s390_get_wordsize to determine the
5818 word size first and derive the correct tdesc from that directly.
5819
5820 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
5821
5822 * Makefile.in: Include silent-rules.mk.
5823 (srcdir, abs_top_srcdir, abs_srcdir, VPATH): Move up.
5824 (COMPILE): Add ECHO_CXX.
5825 (gdbserver$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
5826 (gdbreplay$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
5827 ($(IPA_LIB)): Add SILENCE and ECHO_CXXLD.
5828 (version-generated.c): Add ECHO_GEN.
5829 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN_GENERATED.
5830 (IPAGENT_COMPILE): Add ECHO_CXX.
5831 (%-generated.c): Add ECHO_REGDAT.
5832
5833 2018-03-14 Tom Tromey <tom@tromey.com>
5834
5835 PR cli/14977:
5836 * ax.c (ax_printf): Special case for NULL.
5837
5838 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
5839
5840 * linux-low.c (linux_qxfer_libraries_svr4): Use
5841 xml_escape_text_append.
5842
5843 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
5844
5845 * linux-low.c (linux_qxfer_libraries_svr4): Use std::string.
5846
5847 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
5848
5849 * server.c (handle_general_set): Remove unnecessary xstrdup.
5850
5851 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
5852
5853 * server.c (parse_debug_format_options): Adjust to
5854 delim_string_to_char_ptr_vec changes.
5855 * thread-db.c (thread_db_load_search): Adjust to
5856 dirnames_to_char_ptr_vec changes.
5857
5858 2018-03-01 Markus Metzger <markus.t.metzger@intel.com>
5859
5860 * target.h (target_enable_btrace, target_disable_btrace)
5861 (target_read_btrace, target_read_btrace_conf): Turn macro into
5862 inline function. Throw error if target method is not defined.
5863 * server.c (handle_qxfer_btrace handle_qxfer_btrace_conf): Remove
5864 check for btrace target method. Be prepared to handle exceptions
5865 from btrace target methods.
5866
5867 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
5868
5869 * server.c (captured_main): Change order of error message printed
5870 when the current working directory cannot be found.
5871
5872 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
5873
5874 * server.c: Include "filenames.h" and "pathstuff.h".
5875 (program_name): Delete variable.
5876 (program_path): New anonymous class.
5877 (get_exec_wrapper): Use "program_path" instead of
5878 "program_name".
5879 (handle_v_run): Likewise.
5880 (captured_main): Likewise.
5881 (process_serial_event): Likewise.
5882
5883 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
5884
5885 * Makefile.in (SFILES): Add "$(srcdir)/common/pathstuff.c".
5886 (OBJS): Add "pathstuff.o".
5887 * server.c (current_directory): New global variable.
5888 (captured_main): Initialize "current_directory".
5889
5890 2018-02-26 Alan Hayward <alan.hayward@arm.com>
5891
5892 * tdesc.c: Use common/tdesc.h.
5893 * tdesc.h: Likewise.
5894
5895 2018-02-20 Alan Hayward <alan.hayward@arm.com>
5896 Simon Marchi <simon.marchi@ericsson.com>
5897
5898 * Makefile.in: Switch order of make rules.
5899
5900 2018-02-19 Alan Hayward <alan.hayward@arm.com>
5901
5902 * Makefile.in: Add common directory in build.
5903 * configure.ac: Add common reference.
5904 * configure: Regenerate.
5905
5906 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
5907
5908 * linux-low.c (linux_target_ops): Remove linux_supports_btrace.
5909 * nto-low.c (nto_target_ops): Remove NULL for supports_btrace.
5910 * spu-low.c (spu_target_ops): Likewise.
5911 * win32-low.c (win32_target_ops): Likewise.
5912 * server.c (supported_btrace_packets): Report packets unconditionally.
5913 * target.h (target_ops) <supports_btrace>: Remove.
5914 (target_supports_btrace): Remove.
5915
5916 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
5917
5918 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt)
5919 (handle_btrace_disable): Change return type to void. Use exceptions
5920 to report errors.
5921 (handle_btrace_general_set): Catch exception and copy message to
5922 return message.
5923
5924 2018-02-08 Tom Tromey <tom@tromey.com>
5925
5926 * linux-low.c (install_software_single_step_breakpoints): Use
5927 make_scoped_restore.
5928 * inferiors.c (make_cleanup_restore_current_thread): Remove.
5929 (do_restore_current_thread_cleanup): Remove.
5930 * gdbthread.h (make_cleanup_restore_current_thread): Don't
5931 declare.
5932
5933 2018-02-08 Tom Tromey <tom@tromey.com>
5934
5935 * mem-break.c (set_raw_breakpoint_at): Use
5936 gdb::unique_xmalloc_ptr.
5937
5938 2018-01-30 Pedro Alves <palves@redhat.com>
5939
5940 PR gdb/13211
5941 * target.c (target_terminal::terminal_state): Rename to ...
5942 (target_terminal::m_terminal_state): ... this.
5943
5944 2018-01-19 James Clarke <jrtc27@jrtc27.com>
5945
5946 * linux-low.c (handle_extended_wait): Surround call to
5947 thread_db_notice_clone with #ifdef USE_THREAD_DB.
5948
5949 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
5950
5951 * linux-low.c (attach_proc_task_lwp_callback): Adjust to
5952 linux_ptrace_attach_fail_reason_string now returning an
5953 std::string.
5954 (linux_attach): Likewise.
5955 * thread-db.c (attach_thread): Likewise.
5956
5957 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
5958
5959 PR gdb/21559
5960 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
5961 checking for fs_base/gs_base fields in struct user_regs_struct.
5962 * configure: Regenerate.
5963
5964 2018-01-16 Yao Qi <yao.qi@linaro.org>
5965
5966 PR gdb/18749
5967 * linux-low.c (fetch_register): Call supply_register instead of
5968 error.
5969
5970 2018-01-08 Yao Qi <yao.qi@linaro.org>
5971 Simon Marchi <simon.marchi@ericsson.com>
5972
5973 * Makefile.in (OBS): Remove selftest.o.
5974 * configure.ac: Set srv_selftest_objs if $development is true.
5975 (GDBSERVER_DEPFILES): Append $srv_selftest_objs.
5976 * configure: Re-generated.
5977 * server.c (captured_main): Wrap variable selftest_filter with
5978 GDB_SELF_TEST.
5979
5980 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
5981
5982 * server.c (parse_debug_format_options): Return std::string.
5983 (handle_monitor_command, captured_main): Adjust.
5984
5985 2018-01-05 Pedro Alves <palves@redhat.com>
5986
5987 PR gdb/18653
5988 * server.c (captured_main): Pass quiet=false to
5989 save_original_signals_state.
5990
5991 2018-01-01 Joel Brobecker <brobecker@adacore.com>
5992
5993 * gdbreplay.c (gdbreplay_version): Update copyright year in
5994 version message.
5995 * server.c (gdbserver_version): Likewise.
5996
5997 2017-12-08 Tom Tromey <tom@tromey.com>
5998
5999 * ax.c (ax_printf): Update.
6000
6001 2017-12-07 Yao Qi <yao.qi@linaro.org>
6002
6003 * linux-aarch64-ipa.c (initialize_low_tracepoint): Call
6004 aarch64_linux_read_description.
6005 * linux-amd64-ipa.c (idx2mask): New array.
6006 (get_ipa_tdesc): Move idx2mask out.
6007 (initialize_low_tracepoint): Initialize target descriptions.
6008 * linux-i386-ipa.c (idx2mask): New array.
6009 (get_ipa_tdesc): Move idx2mask out.
6010 (initialize_low_tracepoint): Initialize target descriptions.
6011
6012 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
6013
6014 * tdesc.c (struct tdesc_type): Change return type.
6015 (tdesc_add_flag): Change parameter type.
6016 (tdesc_add_bitfield): Likewise.
6017 (tdesc_add_field): Likewise.
6018 (tdesc_set_struct_size): Likewise.
6019
6020 2017-12-05 Simon Marchi <simon.marchi@ericsson.com>
6021
6022 * regcache.c (registers_to_string): Remove unused variable.
6023
6024 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6025
6026 * inferiors.c (for_each_inferior_with_data): Remove.
6027 * inferiors.h (for_each_inferior_with_data): Remove.
6028 * server.c (handle_qxfer_threads_worker): Change parameter type.
6029 (handle_qxfer_threads_proper): Use for_each_thread.
6030
6031 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6032
6033 * inferiors.c (for_each_inferior): Remove.
6034 (clear_inferiors): Use for_each_thread.
6035 * inferiors.h (for_each_inferior): Remove.
6036 * linux-low.c (linux_wait_for_event_filtered): Use
6037 for_each_thread.
6038 (linux_stabilize_threads): Likewise.
6039 * regcache.c (regcache_release): Likewise.
6040 * server.c (gdb_wants_all_threads_stopped): Likewise.
6041 (clear_pending_status_callback): Remove.
6042 (handle_status): Use for_each_thread.
6043 (captured_main): Likewise.
6044 * win32-low.c (child_init_thread_list): Likewise.
6045 (win32_clear_inferiors): Likewise.
6046 (fake_breakpoint_event): Likewise.
6047
6048 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6049
6050 * inferiors.h (find_inferior): Remove.
6051 * inferiors.c (find_inferior): Remove.
6052
6053 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6054
6055 * linux-low.c (resume_status_pending_p): Update comment.
6056 (need_step_over_p): Update comment.
6057
6058 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6059
6060 * linux-low.c (proceed_one_lwp): Return void, change parameter
6061 type.
6062 (unsuspend_and_proceed_one_lwp): Likewise.
6063 (proceed_all_lwps): Use for_each_thread.
6064 (unstop_all_lwps): Likewise.
6065
6066 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6067
6068 * linux-low.c (linux_resume_one_thread): Return void, take
6069 parameter directly.
6070 (linux_resume): Use for_each_thread.
6071
6072 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6073
6074 * linux-low.c (send_sigstop_callback): Return void, change
6075 parameter type. Rename to...
6076 (send_sigstop): ... this.
6077 (suspend_and_send_sigstop_callback): Return void, change parameter
6078 type. Rename to...
6079 (suspend_and_send_sigstop): ... this.
6080 (stop_all_lwps): Use for_each_thread.
6081
6082 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6083
6084 * linux-low.c (lwp_running): Return bool, remove unused
6085 argument.
6086 (linux_stabilize_threads): Use find_thread.
6087
6088 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6089
6090 * linux-low.c (select_singlestep_lwp_callback): Remove.
6091 (count_events_callback): Remove.
6092 (select_event_lwp_callback): Remove.
6093 (select_event_lwp): Use find_thread/for_each_thread.
6094
6095 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6096
6097 * linux-low.c (not_stopped_callback): Return bool, take filter
6098 argument directly.
6099 (linux_wait_for_event_filtered): Use find_thread.
6100 (linux_wait_1): Likewise.
6101
6102 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6103
6104 * linux-low.c (same_lwp): Remove.
6105 (find_lwp_pid): Use find_thread.
6106
6107 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6108
6109 * linux-low.c (delete_lwp_callback): Remove.
6110 (linux_mourn): Use for_each_thread.
6111
6112 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6113
6114 * linux-low.c (linux_detach_lwp_callback): Return void, remove
6115 args parameter, don't check for pid.
6116 (linux_detach): Use for_each_thread.
6117
6118 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6119
6120 * linux-low.c (struct counter): Remove.
6121 (second_thread_of_pid_p): Remove.
6122 (last_thread_of_process_p): Use find_thread.
6123
6124 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6125
6126 * inferiors.c (find_inferior_in_random): Remove.
6127 * inferiors.h (find_inferior_in_random): Remove.
6128 * linux-low.c (status_pending_p_callback): Return bool, accept
6129 parameter ptid directly.
6130 (linux_wait_for_event_filtered): Use find_thread_in_random.
6131 (linux_wait_1): Likewise.
6132
6133 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6134
6135 * inferiors.c (find_inferior_id): Remove.
6136 (find_thread_ptid): Move implemention from find_inferior_id to
6137 here.
6138 * inferiors.h (find_inferior_id): Remove.
6139 * server.c (handle_status): Use find_thread_ptid.
6140 (process_serial_event): Likewise.
6141 * thread-db.c (find_one_thread): Likewise.
6142 (thread_db_thread_handle): Likewise.
6143 * win32-low.c (thread_rec): Likewise.
6144 (child_delete_thread): Likewise.
6145 (win32_thread_alive): Likewise.
6146 (get_child_debug_event): Likewise.
6147
6148 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6149
6150 * linux-mips-low.c (update_watch_registers_callback): Return
6151 void, remove pid_p parameter, don't check for pid.
6152 (mips_insert_point, mips_remove_point): Use for_each_thread.
6153
6154 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6155
6156 * lynx.low (lynx_delete_thread_callback): Remove.
6157 (lynx_mourn): Use for_each_thread.
6158
6159 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6160
6161 * regcache.c (regcache_invalidate_one): Remove.
6162 (regcache_invalidate_pid): use for_each_thread.
6163
6164 2017-11-26 Tom Tromey <tom@tromey.com>
6165
6166 * linux-low.c (linux_create_inferior): Update.
6167
6168 2017-11-24 Ulrich Weigand <uweigand@de.ibm.com>
6169
6170 * spu-low.c (spu_create_inferior): Fix typo in argument name.
6171
6172 2017-11-24 Alan Hayward <alan.hayward@arm.com>
6173
6174 * configure.srv: Add linux-aarch64-tdesc-selftest.o.
6175 * linux-aarch64-low.c (initialize_low_arch): Call init func.
6176 * linux-aarch64-tdesc-selftest.c: New file.
6177 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
6178
6179 2017-11-24 Alan Hayward <alan.hayward@arm.com>
6180
6181 * configure.srv: Add new file.
6182 * linux-aarch64-low.c (initialize_low_arch): Call init func.
6183 * linux-aarch64-tdesc-selftest.c: New file.
6184 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
6185
6186 2017-11-24 Alan Hayward <alan.hayward@arm.com>
6187
6188 * linux-aarch64-ipa.c (initialize_low_tracepoint): Remove init.
6189 * linux-aarch64-low.c (initialize_low_arch): Remove init.
6190 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add init.
6191
6192 2017-11-24 Alan Hayward <alan.hayward@arm.com>
6193
6194 * configure.srv: Add new files.
6195 * linux-aarch64-ipa.c (get_ipa_tdesc): Call
6196 aarch64_linux_read_description.
6197 * linux-aarch64-low.c (aarch64_linux_read_description):
6198 Merge with aarch64_arch_setup.
6199 (aarch64_arch_setup): Call aarch64_linux_read_description.
6200 * linux-aarch64-tdesc.c: New file.
6201 * linux-aarch64-tdesc.h: New file.
6202
6203 2017-11-24 Yao Qi <yao.qi@linaro.org>
6204
6205 * configure.srv: Set $srv_regobj for tic6x-linux.
6206 * linux-tic6x-low.c: Include "arch/tic6x.h" and "tdesc.h".
6207 (tic6x_read_description): Move some code to tic6x_arch_setup.
6208 (tic6x_tdesc_test): New function.
6209 (initialize_low_arch): Call selftests::register_test.
6210
6211 2017-11-22 Yao Qi <yao.qi@linaro.org>
6212
6213 * remote-utils.c (prepare_resume_reply): Use memcpy.
6214
6215 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6216
6217 * linux-low.c (kill_one_lwp_callback): Return void, take
6218 argument directly, don't filter on pid.
6219 (linux_kill): Use for_each_thread.
6220
6221 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6222
6223 * linux-low.c (need_step_over_p): Return bool, remove dummy
6224 argument.
6225 (linux_resume, proceed_all_lwps): Use find_thread.
6226
6227 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6228
6229 * linux-low.c (resume_status_pending_p): Return bool, remove
6230 flag_p argument.
6231 (linux_resume): Use find_thread.
6232
6233 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6234
6235 * linux-low.c (struct thread_resume_array): Remove.
6236 (linux_set_resume_request): Return void, take arguments
6237 directly.
6238 (linux_resume): Use for_each_thread.
6239
6240 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6241
6242 * linux-low.c (stuck_in_jump_pad_callback): Change prototype,
6243 return bool, remove data argument.
6244 (linux_stabilize_threads): Use find_thread.
6245
6246 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6247
6248 * linux-low.c (unsuspend_one_lwp): Remove.
6249 (unsuspend_all_lwps): Use for_each_thread, inline code from
6250 unsuspend_one_lwp.
6251
6252 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6253
6254 * gdbthread.h (find_thread): Add overload with ptid_t filter.
6255 * linux-low.c (struct iterate_over_lwps_args): Remove.
6256 (iterate_over_lwps_filter): Remove.
6257 (iterate_over_lwps): Use find_thread.
6258
6259 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6260
6261 * linux-low.c (reset_lwp_ptrace_options_callback): Remove.
6262 (linux_handle_new_gdb_connection): Use for_each_thread, inline
6263 code from reset_lwp_ptrace_options_callback.
6264
6265 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6266
6267 * linux-arm-low.c (struct update_registers_data): Remove.
6268 (update_registers_callback): Return void, take arguments
6269 directly, don't check thread's pid.
6270 (arm_insert_point, arm_remove_point): Use for_each_thread.
6271
6272 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6273
6274 * win32-low.c (continue_one_thread): Return void, take argument
6275 directly.
6276 (child_continue): Use for_each_thread.
6277
6278 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6279
6280 * win32-i386-low.c (update_debug_registers_callback): Rename
6281 to ...
6282 (update_debug_registers): ... this, return void, remove pid_p arg.
6283 (x86_dr_low_set_addr, x86_dr_low_set_control): Use for_each_thread.
6284
6285 2017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
6286
6287 * inferiors.h (struct process_info): Add constructor, initialize
6288 fields..
6289 <syscalls_to_catch>: Change type to std::vector<int>.
6290 * inferiors.c (add_process): Allocate process_info with new.
6291 (remove_process): Free process_info with delete.
6292 * linux-low.c (handle_extended_wait): Adjust.
6293 (gdb_catching_syscalls_p, gdb_catch_this_syscall_p): Adjust.
6294 * server.c (handle_general_set): Adjust.
6295
6296 2017-11-16 Pedro Alves <palves@redhat.com>
6297
6298 * remote-utils.c (remote_close): Block SIGIO signals instead of
6299 uninstalling the SIGIO handler.
6300
6301 2017-11-16 Alan Hayward <alan.hayward@arm.com>
6302
6303 * tdesc.c (tdesc_get_features_xml): Allow null osabi.
6304
6305 2017-11-16 Yao Qi <yao.qi@linaro.org>
6306
6307 * linux-tic6x-low.c (tic6x_fill_gregset): Cast buf.
6308 (tic6x_store_gregset): Likewise.
6309 (tic6x_usrregs_info): Move it up.
6310
6311 2017-11-15 Alan Hayward <alan.hayward@arm.com>
6312
6313 * Makefile.in: Update arch rules.
6314 * configure.srv: Explicitly mark arch/ files.
6315
6316 2017-11-13 Andreas Schwab <schwab@suse.de>
6317
6318 * linux-m68k-low.c (m68k_supports_hardware_single_step): New
6319 function.
6320 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6321
6322 2017-11-06 Pedro Alves <palves@redhat.com>
6323
6324 * config.in, configure: Regenerate.
6325
6326 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
6327
6328 * target.c (struct thread_search): Remove.
6329 (thread_search_callback): Remove.
6330 (prepare_to_access_memory): Use for_each_thread instead of
6331 find_inferior. Inline code from thread_search_callback.
6332
6333 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
6334
6335 * server.c (struct visit_actioned_threads_data): Remove.
6336 (visit_actioned_threads): Change prototype to take arguments
6337 directly.
6338 (resume): Use find_thread instead of find_inferior.
6339
6340 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
6341
6342 * server.c (queue_stop_reply_callback): Change prototype, return
6343 void.
6344 (find_status_pending_thread_callback): Remove.
6345 (handle_status): Replace find_inferior with find_thread and
6346 for_each_thread.
6347
6348 2017-10-25 Alan Hayward <alan.hayward@arm.com>
6349
6350 * linux-aarch64-low.c (aarch64_fill_gregset): Replace defines
6351 with REGNO.
6352 (aarch64_store_gregset): Likewise.
6353 (aarch64_fill_fpregset): Likewise.
6354 (aarch64_store_fpregset): Likewise.
6355
6356 2017-10-21 Simon Marchi <simon.marchi@ericsson.com>
6357
6358 * gdbthread.h (find_thread, for_each_thread): New functions.
6359 * inferiors.c (thread_of_pid): Remove.
6360 (find_any_thread_of_pid): Use find_thread.
6361 * linux-low.c (num_lwps): Use for_each_thread.
6362
6363 2017-10-17 Yao Qi <yao.qi@linaro.org>
6364
6365 * Makefile.in: Remove one rule.
6366 * configure.srv: Rename aarch64-insn.o with arch/aarch64-insn.o.
6367
6368 2017-10-17 Yao Qi <yao.qi@linaro.org>
6369
6370 * configure.srv: Rename arm-linux.o with arch/arm-linux.o.
6371 Rename arm-get-next-pcs.o with arch/arm-get-next-pcs.o.
6372
6373 2017-10-17 Yao Qi <yao.qi@linaro.org>
6374
6375 * configure.srv: Rename arm.o with arch/arm.o.
6376
6377 2017-10-17 Yao Qi <yao.qi@linaro.org>
6378
6379 * Makefile.in (CONFIG_SRC_SUBDIR): New variable.
6380 (clean): Remove .o files in CONFIG_SRC_SUBDIR.
6381 (distclean): Remove DEPDIR in CONFIG_SRC_SUBDIR.
6382 (arch-i386.o, arch-amd64.o): Remove rules.
6383 (arch/%.o): New rule.
6384 Update POSTCOMPILE and COMPILE.pre.
6385 * configure.ac: Invoke AC_CONFIG_COMMANDS.
6386 * configure: Re-generated.
6387 * configure.srv: Replace arch-i386.o with arch/i386.o.
6388 Replace arch-amd64.o with arch/amd64.o.
6389
6390 2017-10-16 Yao Qi <yao.qi@linaro.org>
6391
6392 * configure: Regenerated.
6393
6394 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
6395
6396 * inferiors.h: (struct inferior_list): Remove.
6397 (struct inferior_list_entry); Remove.
6398 (add_inferior_to_list, clear_inferior_list, one_inferior_p,
6399 A_I_NEXT, ALL_INFERIORS_TYPE, ALL_INFERIORS, remove_inferior,
6400 get_first_inferior): Remove.
6401 (for_each_inferior, for_each_inferior_with_data, find_inferior,
6402 find_inferior_id, find_inferior_in_random): Change signature.
6403 * inferiors.c (all_threads): Change type to
6404 std::list<thread_info *>.
6405 (get_thread): Remove macro.
6406 (find_inferior, find_inferior_id): Change signature, implement
6407 using find_thread.
6408 (find_inferior_in_random): Change signature, implement using
6409 find_thread_in_random.
6410 (for_each_inferior, for_each_inferior_with_data): Change
6411 signature, implement using for_each_thread.
6412 (add_inferior_to_list, remove_inferior): Remove.
6413 (add_thread, get_first_thread, thread_of_pid,
6414 find_any_thread_of_pid, free_one_thread, remove_thread): Update.
6415 (get_first_inferior, one_inferior_p, clear_inferior_list):
6416 Remove.
6417 (clear_inferiors, get_thread_process): Update.
6418 * gdbthread.h: Include <list>.
6419 (struct thread_info) <entry>: Remove field.
6420 <id>: New field.
6421 (all_threads): Change type to std::list<thread_info *>.
6422 (get_first_inferior): Add doc.
6423 (find_thread, for_each_thread, find_thread_in_random): New
6424 functions.
6425 (current_ptid, pid_of, ptid_of, lwpid_of): Update.
6426 * linux-arm-low.c (update_registers_callback): Update.
6427 * linux-low.c (second_thread_of_pid_p): Update.
6428 (kill_one_lwp_callback, linux_detach_lwp_callback,
6429 delete_lwp_callback, status_pending_p_callback, same_lwp,
6430 find_lwp_pid, num_lwps, iterate_over_lwps_filter,
6431 iterate_over_lwps, not_stopped_callback,
6432 resume_stopped_resumed_lwps, count_events_callback,
6433 select_singlestep_lwp_callback, select_event_lwp_callback,
6434 unsuspend_one_lwp, linux_wait_1, send_sigstop_callback,
6435 suspend_and_send_sigstop_callback, wait_for_sigstop,
6436 stuck_in_jump_pad_callback, move_out_of_jump_pad_callback,
6437 lwp_running, linux_set_resume_request, resume_status_pending_p,
6438 need_step_over_p, start_step_over, linux_resume_one_thread,
6439 proceed_one_lwp, unsuspend_and_proceed_one_lwp,
6440 reset_lwp_ptrace_options_callback): Update.
6441 * linux-mips-low.c (update_watch_registers_callback): Update.
6442 * regcache.c (regcache_invalidate_one, regcache_invalidate):
6443 Update.
6444 (free_register_cache_thread_one): Remove.
6445 (regcache_release): Update.
6446 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt,
6447 handle_qxfer_threads_worker): Update.
6448 (handle_query): Update, use list iterator.
6449 (visit_actioned_threads, handle_pending_status,
6450 queue_stop_reply_callback, gdb_wants_all_threads_stopped,
6451 clear_pending_status_callback, set_pending_status_callback,
6452 find_status_pending_thread_callback, handle_status,
6453 process_serial_event): Update.
6454 * target.c (thread_search_callback): Update.
6455 * thread-db.c (thread_db_get_tls_address): Update.
6456 * tracepoint.c (tracepoint_finished_step, tracepoint_was_hit):
6457 Update.
6458 * win32-i386-low.c (update_debug_registers_callback): Update.
6459 * win32-low.c (delete_thread_info, child_delete_thread,
6460 continue_one_thread, suspend_one_thread,
6461 get_child_debug_event): Adjust.
6462
6463 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
6464
6465 * gdbthread.h (ptid_of, pid_of, lwpid_of): New functions.
6466 * inferiors.h: Include <list>.
6467 (struct process_info) <entry>: Remove field.
6468 <pid>: New field.
6469 (pid_of): Change macro to function.
6470 (ptid_of, lwpid_of): Remove macro.
6471 (all_processes): Change type to std::list<process_info *>.
6472 (ALL_PROCESSES): Remove macro.
6473 (for_each_process, find_process): New function.
6474 * inferiors.c (all_processes): Change type to
6475 std::list<process_info *>.
6476 (find_thread_process): Adjust.
6477 (add_process): Likewise.
6478 (remove_process): Likewise.
6479 (find_process_pid): Likewise.
6480 (get_first_process): Likewise.
6481 (started_inferior_callback): Remove.
6482 (have_started_inferiors_p): Adjust.
6483 (attached_inferior_callback): Remove.
6484 (have_attached_inferiors_p): Adjust.
6485 * linux-low.c (check_zombie_leaders): Likewise.
6486 * linux-x86-low.c (x86_arch_setup_process_callback): Remove.
6487 (x86_linux_update_xmltarget): Adjust.
6488 * server.c (handle_query): Likewise.
6489 (gdb_reattached_process): Remove.
6490 (handle_status): Adjust.
6491 (kill_inferior_callback): Likewise.
6492 (detach_or_kill_inferior): Remove.
6493 (print_started_pid): Likewise.
6494 (print_attached_pid): Likewise.
6495 (detach_or_kill_for_exit): Update.
6496 (process_serial_event): Likewise.
6497 * linux-arm-low.c (arm_new_fork): Likewise.
6498
6499 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
6500
6501 * dll.h: Include <list>.
6502 (struct dll_info): Add constructor.
6503 <entry>: Remove field.
6504 (all_dlls): Change type to std::list<dll_info>.
6505 * dll.c: Include <algorithm>.
6506 (get_dll): Remove macro.
6507 (all_dlls): Change type to std::list<dll_info *>.
6508 (free_one_dll): Remove.
6509 (match_dll): Likewise.
6510 (loaded_dll): Adjust.
6511 (unloaded_dll): Adjust to all_dlls type change, use
6512 std::find_if. Inline code from match_dll.
6513 (clear_dlls): Adjust to all_dlls type change.
6514 * server.c (emit_dll_description): Remove.
6515 (handle_qxfer_libraries): Adjust to all_dlls type change,
6516 integrate emit_dll_description's functionality.
6517
6518 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
6519
6520 * linux-low.h (struct linux_target_ops) <delete_process>: New
6521 field.
6522 * linux-low.c (linux_mourn): Call the_low_target.delete_process.
6523 * linux-aarch64-low.c (aarch64_linux_delete_process): New.
6524 (struct linux_target_ops): Add delete_process callback.
6525 * linux-arm-low.c (arm_delete_process): New.
6526 (struct linux_target_ops): Add delete_process callback.
6527 * linux-bfin-low.c (struct linux_target_ops): Likewise.
6528 * linux-crisv32-low.c (struct linux_target_ops): Likewise.
6529 * linux-m32r-low.c (struct linux_target_ops): Likewise.
6530 * linux-mips-low.c (mips_linux_delete_process): New.
6531 (struct linux_target_ops): Add delete_process callback.
6532 * linux-ppc-low.c (struct linux_target_ops): Likewise.
6533 * linux-s390-low.c (struct linux_target_ops): Likewise.
6534 * linux-sh-low.c (struct linux_target_ops): Likewise.
6535 * linux-tic6x-low.c (struct linux_target_ops): Likewise.
6536 * linux-tile-low.c (struct linux_target_ops): Likewise.
6537 * linux-x86-low.c (x86_linux_delete_process): New.
6538 (struct linux_target_ops): Add delete_process callback.
6539 * linux-xtensa-low.c (struct linux_target_ops): Likewise.
6540
6541 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
6542
6543 * linux-aarch64-low.c (the_low_target): Add thread delete
6544 callback.
6545 * linux-arm-low.c (arm_delete_thread): New function.
6546 (the_low_target): Add thread delete callback.
6547 * linux-bfin-low.c (the_low_target): Likewise.
6548 * linux-crisv32-low.c (the_low_target): Likewise.
6549 * linux-low.c (delete_lwp): Invoke delete_thread callback if
6550 set.
6551 * linux-low.h (struct linux_target_ops) <delete_thread>: New
6552 field.
6553 * linux-m32r-low.c (the_low_target): Add thread delete callback.
6554 * linux-mips-low.c (mips_linux_delete_thread): New function.
6555 (the_low_target): Add thread delete callback.
6556 * linux-ppc-low.c (the_low_target): Likewise.
6557 * linux-s390-low.c (the_low_target): Likewise.
6558 * linux-sh-low.c (the_low_target): Likewise.
6559 * linux-tic6x-low.c (the_low_target): Likewise.
6560 * linux-tile-low.c (the_low_target): Likewise.
6561 * linux-x86-low.c (the_low_target): Likewise.
6562 * linux-xtensa-low.c (the_low_target): Likewise.
6563
6564 2017-10-06 Yuanhui Zhang <asmwarrior@gmail.com>
6565
6566 * win32-low.c: Include "common-inferior.h".
6567
6568 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
6569
6570 * inferiors.c (set_inferior_cwd): New function.
6571 * server.c (handle_general_set): Handle QSetWorkingDir packet.
6572 (handle_query): Inform that QSetWorkingDir is supported.
6573 * win32-low.c (create_process): Pass the inferior's cwd to
6574 CreateProcess.
6575
6576 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
6577
6578 * inferiors.c (current_inferior_cwd): New global variable.
6579 (get_inferior_cwd): New function.
6580 * inferiors.h (struct process_info) <cwd>: New field.
6581
6582 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
6583
6584 * Makefile.in (SFILES): Add $(srcdir)/common/gdb_tilde_expand.c.
6585 (OBS): Add gdb_tilde_expand.o.
6586
6587 2017-10-02 Simon Marchi <simon.marchi@ericsson.com>
6588
6589 * lynx-i386-low.c (lynx_i386_arch_setup): Call init_target_desc.
6590 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
6591
6592 2017-09-29 Pedro Alves <palves@redhat.com>
6593
6594 * ax.c (gdb_parse_agent_expr): Constify.
6595 * ax.h (gdb_parse_agent_expr): Constify.
6596 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
6597 Constify.
6598 * mem-break.h (add_breakpoint_condition, add_breakpoint_commands): Constify.
6599 * remote-utils.c (hex_or_minus_one, read_ptid): Constify.
6600 * remote-utils.h (read_ptid): Constify.
6601 * server.c (handle_qxfer_exec_file, handle_query, handle_v_cont)
6602 (process_point_options, process_serial_event): Constify.
6603 * tracepoint.c (add_tracepoint_action, cmd_qtdp, cmd_qtdpsrc)
6604 (cmd_qtdv, cmd_qtenable_disable, cmd_qtro, cmd_qtframe, cmd_qtp)
6605 (cmd_qtbuffer): Constify.
6606
6607 2017-09-29 Pedro Alves <palves@redhat.com>
6608
6609 * proc-service.c (ps_pdread): Return PS_ERR if reading memory
6610 fails.
6611
6612 2017-09-29 Pedro Alves <palves@redhat.com>
6613
6614 * linux-low.c (handle_extended_wait): Pass parent thread instead
6615 of process to thread_db_notice_clone.
6616 * linux-low.h (thread_db_notice_clone): Replace parent process
6617 parameter with parent thread parameter.
6618 * thread-db.c (find_one_thread): Add comment.
6619 (thread_db_notice_clone): Replace parent process parameter with
6620 parent thread parameter. Temporarily switch to the parent thread.
6621
6622 2017-09-26 Sergio Durigan Junior <sergiodj@redhat.com>
6623
6624 * gdbthread.h: Include "common-gdbthread.h".
6625 * inferiors.c (switch_to_thread): Use "gdb_assert" instead of
6626 "if" when validating the ptid.
6627 * remote-utils.c: Include "gdbthread.h".
6628 (prepare_resume_reply): Use "switch_to_thread".
6629 * target.c (done_accessing_memory): Likewise.
6630
6631 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
6632
6633 * configure.srv (s390*-*-linux*): Add s390-gs-linux64.o and
6634 s390x-gs-linux64.o to srv_regobj. Add s390-gs-linux64.xml,
6635 s390x-gs-linux64.xml, s390-gs.xml, and s390-gsbc.xml to
6636 srv_xmlfiles. Add s390-gs-linux64-ipa.o and
6637 s390x-gs-linux64-ipa.o to ipa_obj.
6638 * linux-s390-low.c (HWCAP_S390_GS): New define.
6639 (s390_fill_gs, s390_store_gs, s390_fill_gsbc, s390_store_gsbc):
6640 New functions.
6641 (s390_regsets): Add regsets for NT_S390_GS_CB and NT_S390_GS_BC.
6642 (s390_arch_setup): Check for guarded-storage support and choose
6643 appropriate tdesc.
6644 (initialize_low_arch): Invoke init_registers_s390_gs_linux64 and
6645 init_registers_s390x_gs_linux64.
6646 * linux-s390-tdesc.h (enum s390_linux_tdesc) <S390_TDESC_GS>: New
6647 enum value.
6648 (init_registers_s390x_gs_linux64, tdesc_s390x_gs_linux64)
6649 (init_registers_s390_gs_linux64, tdesc_s390_gs_linux64): Declare.
6650
6651 2017-09-22 Simon Marchi <simon.marchi@ericsson.com>
6652
6653 * win32-i386-low.c (i386_arch_setup): Call init_target_desc.
6654
6655 2017-09-21 Kevin Buettner <kevinb@redhat.com>
6656
6657 * linux-low.h (struct lwp_info): Add new field, thread_handle.
6658 (thread_db_thread_handle): Declare.
6659 * linux-low.c (linux_target_ops): Initialize thread_handle.
6660 * server.c (handle_qxfer_threads_worker): Add support for
6661 "handle" attribute.
6662 * target.h (struct target_ops): Add new function pointer,
6663 thread_handle.
6664 (target_thread_handle): Define.
6665 * thread-db.c (find_one_thread, attach_thread): Set thread_handle
6666 field in lwp.
6667 (thread_db_thread_handle): New function.
6668
6669 2017-09-21 Kevin Buettner <kevinb@redhat.com>
6670
6671 * linux-low.c (handle_extended_wait): Call thread_db_notice_clone().
6672 * linux-low.h (thread_db_notice_clone): Declare.
6673 * thread-db.c (thread_db_notice_clone): New function.
6674
6675 2017-09-21 Pedro Alves <palves@redhat.com>
6676
6677 * server.c (gdb_read_memory, handle_status, process_serial_event)
6678 (handle_serial_event, handle_target_event): Adjust to
6679 set_desired_thread prototype change.
6680 * target.c (set_desired_thread): Remove 'use_general' parameter
6681 and adjust.
6682 * target.h (set_desired_thread): Remove 'use_general' parameter.
6683
6684 2017-09-20 Tom Tromey <tom@tromey.com>
6685
6686 * target.c (target_terminal::terminal_state): Define.
6687 (target_terminal::init): Rename from target_terminal_init.
6688 (target_terminal::inferior): Rename from
6689 target_terminal_inferior.
6690 (target_terminal::ours): Rename from target_terminal_ours.
6691 (target_terminal::ours_for_output, target_terminal::info): New.
6692
6693 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6694
6695 * server.c (accumulate_file_name_length): Remove.
6696 (emit_dll_description): Adjust to std::string change.
6697 (handle_qxfer_libraries): Use std::string to hold document.
6698
6699 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6700
6701 * linux-low.c (linux_qxfer_libraries_svr4): Adjust to change of
6702 return type of xml_escape_text.
6703 * server.c (emit_dll_description): Likewise.
6704
6705 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6706
6707 * server.c (captured_main): Accept argument for --selftest.
6708 Update run_tests call.
6709 * linux-x86-tdesc-selftest.c (initialize_low_tdesc): Add names
6710 when registering selftests.
6711
6712 2017-09-16 Sergio Durigan Junior <sergiodj@redhat.com>
6713
6714 * regcache.c (get_thread_regcache): Update code to use "std::vector"
6715 instead of "VEC" for "target_desc.reg_defs".
6716 (regcache_cpy): Likewise.
6717 (registers_to_string): Likewise.
6718 (registers_from_string): Likewise.
6719 (find_regno): Likewise.
6720 (supply_regblock): Likewise.
6721 (regcache_raw_read_unsigned): Likewise.
6722 * tdesc.c (init_target_desc): Likewise.
6723 (tdesc_create_reg): Likewise.
6724 * tdesc.h: Remove declaration of "tdesc_reg_p". Include <vector>.
6725 (struct target_desc) <reg_defs>: Convert to "std::vector".
6726 (target_desc): Do not initialize "reg_defs".
6727 (~target_desc): Update code to use "std::vector" instead of "VEC"
6728 for "target_desc.reg_defs".
6729 (operator==): Likewise.
6730
6731 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6732
6733 * inferiors.h (thread_to_gdb_id): Remove.
6734 * inferiors.c (thread_to_gdb_id): Remove.
6735 * server.c (handle_qxfer_threads_worker, handle_query): Adjust.
6736 * lynx-low.c (lynx_resume, lynx_wait_1, lynx_fetch_registers,
6737 lynx_store_registers, lynx_read_memory, lynx_write_memory):
6738 Likewise.
6739 * nto-low.c (nto_fetch_registers, nto_store_registers,
6740 nto_stopped_by_watchpoint, nto_stopped_data_address): Likewise.
6741
6742 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6743
6744 * inferiors.h (gdb_id_to_thread_id): Remove.
6745 * inferiors.c (gdb_id_to_thread_id): Remove.
6746 * server.c (process_serial_event): Adjust to gdb_id_to_thread_id
6747 removal. Move pid declaration closer to where it's used.
6748
6749 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6750
6751 * server.c (handle_detach): New function.
6752 (process_serial_event): Move code out, call handle_detach.
6753
6754 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6755
6756 * server.c (require_running): Rename to ...
6757 (require_running_or_return): ... this ...
6758 (require_running_or_break): ... and this.
6759 (handle_query, process_serial_event): Adjust.
6760
6761 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6762
6763 * linux-low.c (linux_set_resume_request): Remove unused
6764 variables.
6765
6766 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6767
6768 * server.c (first_thread_of): Remove.
6769 (process_serial_event): Replace usage of first_thread_of with
6770 find_any_thread_of_pid.
6771 * tracepoint.c (same_process_p): Remove.
6772 (gdb_agent_about_to_close): Replace usage of same_process_p with
6773 find_any_thread_of_pid.
6774 * linux-x86-low.c (same_process_callback): Remove.
6775 (x86_arch_setup_process_callback): Replace usage of
6776 same_process_callback with find_any_thread_of_pid.
6777 * thread-db.c (any_thread_of): Remove.
6778 (switch_to_process): Replace usage of any_thread_of with
6779 find_any_thread_of_pid.
6780 * inferiors.c (thread_pid_matches_callback): Remove.
6781 (find_thread_process): Adjust to use find_any_thread_of_pid.
6782
6783 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
6784
6785 * regcache.c (get_thread_regcache): Guard calls to "memset"
6786 with "!VEC_empty".
6787
6788 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
6789
6790 * linux-low.c (handle_extended_wait): Use
6791 "allocate_target_description" instead of "XNEW".
6792 * linux-x86-low.c (initialize_low_arch): Likewise.
6793
6794 2017-09-05 Yao Qi <yao.qi@linaro.org>
6795
6796 * configure.srv (srv_i386_regobj): Remove.
6797 (srv_amd64_regobj): Remove.
6798 (srv_regobj): Set it to "" for x86 non-linux targets.
6799 * linux-x86-tdesc.c (i386_linux_read_description):
6800 * lynx-i386-low.c: Include x86-xstate.h and arch/i386.h.
6801 (init_registers_i386): Remove the declaration.
6802 (tdesc_i386): Remove the declaration.
6803 (lynx_i386_arch_setup): Call i386_create_target_description.
6804 * nto-x86-low.c: Likewise.
6805 * win32-i386-low.c [__x86_64__]: include arch/amd64.h.
6806 [!__x86_64__]: include arch/i386.h.
6807 (i386_arch_setup) [__x86_64__]: Call amd64_create_target_description.
6808
6809 2017-09-05 Yao Qi <yao.qi@linaro.org>
6810
6811 * configure.srv (srv_amd64_linux_xmlfiles): Remove
6812 i386/amd64-XXX-linux from it.
6813
6814 2017-09-05 Yao Qi <yao.qi@linaro.org>
6815
6816 * configure.srv: Empty srv_amd64_linux_regobj if $development is
6817 false.
6818 (ipa_amd64_linux_regobj): Remove.
6819 (ipa_x32_linux_regobj): Remove.
6820
6821 2017-09-05 Yao Qi <yao.qi@linaro.org>
6822
6823 * Makefile.in (arch-amd64.o): New rule.
6824 * configure.srv: Append arch-amd64.o.
6825 * linux-amd64-ipa.c: Include common/x86-xstate.h.
6826 (get_ipa_tdesc): Call amd64_linux_read_description.
6827 (initialize_low_tracepoint): Don't call init_registers_x32_XXX
6828 and init_registers_amd64_XXX.
6829 * linux-x86-low.c (x86_linux_read_description): Call
6830 amd64_linux_read_description.
6831 (x86_get_ipa_tdesc_idx): Call amd64_get_ipa_tdesc_idx.
6832 (initialize_low_arch): Don't call init_registers_x32_XXX and
6833 init_registers_amd64_XXX.
6834 * linux-x86-tdesc-selftest.c: Declare init_registers_amd64_XXX
6835 and tdesc_amd64_XXX.
6836 [__x86_64__] (amd64_tdesc_test): New function.
6837 (initialize_low_tdesc) [__x86_64__]: Call init_registers_x32_XXX
6838 and init_registers_amd64_XXX.
6839 * linux-x86-tdesc.c: Include arch/amd64.h.
6840 (xcr0_to_tdesc_idx): New function.
6841 (i386_linux_read_description): New function.
6842 (amd64_get_ipa_tdesc_idx): New function.
6843 * linux-x86-tdesc.h (amd64_get_ipa_tdesc_idx): Declare.
6844 (amd64_get_ipa_tdesc): Declare.
6845
6846 2017-09-05 Yao Qi <yao.qi@linaro.org>
6847
6848 * configure.srv (srv_i386_linux_xmlfiles): Remove
6849 i386/i386-XXX-linux.xml from it.
6850
6851 2017-09-05 Yao Qi <yao.qi@linaro.org>
6852
6853 * configure.srv: Set srv_i386_linux_regobj empty if $development
6854 is false.
6855 * linux-i386-ipa.c (initialize_low_tracepoint): Don't call
6856 initialize_low_tdesc.
6857 * linux-x86-low.c (initialize_low_arch): Wrap initialize_low_tdesc
6858 with #if initialize_low_tdesc.
6859 * linux-x86-tdesc-selftest.c: New file.
6860 * linux-x86-tdesc.c: Move code to linux-x86-tdesc-selftest.c.
6861
6862 2017-09-05 Yao Qi <yao.qi@linaro.org>
6863
6864 * Makefile.in (arch-i386.o): New rule.
6865 * configure.srv (i[34567]86-*-linux*): Add arch-i386.o.
6866 (x86_64-*-linux*): Likewise.
6867 * linux-x86-tdesc.c: Don't include ../features/i386/32bit-XXX.c,
6868 include arch/i386.h.
6869 (i386_linux_read_description): Remove code and call
6870 i386_create_target_description.
6871 * tdesc.c (allocate_target_description): New function.
6872 * tdesc.h (set_tdesc_architecture): Remove declaration.
6873 (set_tdesc_osabi): Likewise.
6874
6875 2017-09-05 Yao Qi <yao.qi@linaro.org>
6876
6877 * linux-x86-tdesc.c: Don't include <inttypes.h>.
6878 (i386_linux_read_description) [!IN_PROCESS_AGENT]: Call
6879 set_tdesc_architecture and set_tdesc_osabi. Remove code setting
6880 .xmltarget.
6881 * server.c (get_features_xml): Call tdesc_get_features_xml.
6882 * tdesc.c (set_tdesc_architecture): New function.
6883 (set_tdesc_osabi): New function.
6884 (tdesc_get_features_xml): New function.
6885 (tdesc_create_feature): Add an argument.
6886 * tdesc.h (struct target_desc) <features>: New field.
6887 <arch, osabi>: New field.
6888 (~target_desc): xfree features, arch, and osabi.
6889 (target_desc::oerator==): Don't compare .xmltarget.
6890 [!IN_PROCESS_AGENT] (set_tdesc_architecture): Declare.
6891 (set_tdesc_osabi): Likewise.
6892 (tdesc_get_features_xml): Likewise.
6893
6894 2017-09-05 Yao Qi <yao.qi@linaro.org>
6895
6896 * linux-x86-tdesc.c: Include selftest.h.
6897 (i386_tdesc_test): New function.
6898 (initialize_low_tdesc): Call selftests::register_test.
6899 * tdesc.h: Include regdef.h.
6900 (target_desc): Override operator == and !=.
6901
6902 2017-09-05 Yao Qi <yao.qi@linaro.org>
6903
6904 * configure.srv (srv_tgtobj): Append linux-x86-tdesc.o.
6905 (ipa_obj): Likewise.
6906 * linux-i386-ipa.c: Include common/x86-xstate.h
6907 (get_ipa_tdesc): Call i386_linux_read_description.
6908 (initialize_low_tracepoint): Don't call init_registers_XXX
6909 functions, call initialize_low_tdesc instead.
6910 * linux-x86-low.c (x86_linux_read_description): Call
6911 i386_linux_read_description.
6912 (initialize_low_arch): Don't call init_registers_i386_XXX
6913 functions, call initialize_low_tdesc.
6914 * linux-x86-tdesc.c: New file.
6915 * linux-x86-tdesc.h (x86_linux_tdesc): New X86_TDESC_LAST.
6916 (i386_get_ipa_tdesc_idx): Declare.
6917 (i386_get_ipa_tdesc): Declare.
6918 (initialize_low_tdesc): Declare.
6919
6920 2017-09-05 Yao Qi <yao.qi@linaro.org>
6921
6922 * linux-x86-low.c (x86_get_ipa_tdesc_idx): Use X86_TDESC_MMX
6923 instead of 0.
6924
6925 2017-09-05 Yao Qi <yao.qi@linaro.org>
6926
6927 * Makefile.in (IPA_OBJS): Add vec-ipa.o
6928 * regcache.c (get_thread_regcache): Use VEC_length.
6929 (init_register_cache): Likewise.
6930 (regcache_cpy): Likewise.
6931 (registers_to_string): Iterate reg_defs via VEC_iterate.
6932 (find_regno): Likewise.
6933 (find_register_by_number): Use VEC_index.
6934 (register_size): Call find_register_by_number.
6935 (register_data): Call find_register_by_number.
6936 (supply_regblock): Use VEC_length.
6937 (regcache_raw_read_unsigned): Likewise.
6938 * tdesc.c (init_target_desc): Iterate reg_defs via
6939 VEC_iterate.
6940 (default_description): Update initializer.
6941 (copy_target_description): Don't update field num_registers.
6942 * tdesc.h (struct target_desc) <reg_defs>: Change it to VEC.
6943 <num_registers>: Remove.
6944
6945 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
6946
6947 * Makefile.in (.SECONDARY): Define target.
6948
6949 2017-09-03 Simon Marchi <simon.marchi@ericsson.com>
6950
6951 * linux-low.c (linux_wait_1): Adjust.
6952 * server.c (queue_stop_reply_callback): Adjust.
6953
6954 2017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
6955
6956 * server.c (handle_general_set): Handle QEnvironmentHexEncoded,
6957 QEnvironmentUnset and QEnvironmentReset packets.
6958 (handle_query): Inform remote that QEnvironmentHexEncoded,
6959 QEnvironmentUnset and QEnvironmentReset are supported.
6960
6961 2017-08-25 Simon Marchi <simon.marchi@ericsson.com>
6962
6963 * inferiors.h (inferior_target_data): Rename to ...
6964 (thread_target_data): ... this.
6965 (inferior_regcache_data): Rename to ...
6966 (thread_regcache_data): ... this.
6967 (set_inferior_regcache_data): Rename to ...
6968 (set_thread_regcache_data): ... this.
6969 * inferiors.c (inferior_target_data): Rename to ...
6970 (thread_target_data): ... this.
6971 (inferior_regcache_data): Rename to ...
6972 (thread_regcache_data): ... this.
6973 (set_inferior_regcache_data): Rename to ...
6974 (set_thread_regcache_data): ... this.
6975 (free_one_thread): Update.
6976 * linux-low.h (get_thread_lwp): Update.
6977 * regcache.c (get_thread_regcache): Update.
6978 (regcache_invalidate_thread): Update.
6979 (free_register_cache_thread): Update.
6980 * win32-i386-low.c (update_debug_registers_callback): Update.
6981 (win32_get_current_dr): Update.
6982 * win32-low.c (thread_rec): Update.
6983 (delete_thread_info): Update.
6984 (continue_one_thread): Update.
6985 (suspend_one_thread): Update.
6986
6987 2017-08-24 Simon Marchi <simon.marchi@ericsson.com>
6988
6989 * inferiors.c (set_inferior_target_data): Remove.
6990 * inferiors.h (set_inferior_target_data): Remove.
6991
6992 2017-08-18 Yao Qi <yao.qi@linaro.org>
6993
6994 * Makefile.in (OBS): Add selftest.o.
6995 * configure.ac: AC_DEFINE GDB_SELF_TEST if $development.
6996 * configure, config.in: Re-generated.
6997 * server.c: Include common/sefltest.h.
6998 (captured_main): Handle option --selftest.
6999
7000 2017-08-09 Yao Qi <yao.qi@linaro.org>
7001
7002 * configure.srv (srv_i386_regobj): Remove i386-avx.o,
7003 i386-avx-avx512.o, i386-avx-mpx-avx512-pku.o, i386-mpx.o,
7004 i386-avx-mpx.o and i386-mmx.o.
7005 (srv_amd64_regobj): Remove amd64-avx.o, amd64-avx-avx512.o,
7006 amd64-avx-mpx-avx512-pku.o, amd64-mpx.o and amd64-avx-mpx.o.
7007 (srv_i386_xmlfiles): Remove i386/i386-avx.xml,
7008 i386/i386-avx-avx512.xml, i386/i386-avx-mpx-avx512-pku.xml,
7009 i386/i386-mpx.xml, i386/i386-avx-mpx.xml and i386/i386-mmx.xml.
7010 (srv_amd64_xmlfile):i386/amd64-avx.xml, i386/amd64-avx-avx512.xml,
7011 i386/amd64-avx-mpx-avx512-pku.xml, i386/amd64-mpx.xml,
7012 i386/amd64-avx-mpx.xml.
7013
7014 2017-08-09 Yao Qi <yao.qi@linaro.org>
7015
7016 * configure.srv (srv_amd64_regobj): Remove x32.o, x32-avx.o
7017 and x32-avx-avx512.o.
7018 (srv_amd64_xmlfiles): Remove i386/x32.xml, i386/x32-avx.xml
7019 i386/x32-avx-avx512.xml.
7020
7021 2017-07-26 Simon Marchi <simon.marchi@ericsson.com>
7022
7023 * tracepoint.h (enum class fast_tpoint_collect_result): New
7024 enumeration.
7025 (fast_tracepoint_collecting): Change return type to
7026 fast_tpoint_collect_result.
7027 * tracepoint.c (fast_tracepoint_collecting): Likewise.
7028 * linux-low.h: Include tracepoint.h.
7029 (struct lwp_info) <collecting_fast_tracepoint>: Change type to
7030 fast_tpoint_collect_result.
7031 * linux-low.c (handle_tracepoints): Adjust.
7032 (linux_fast_tracepoint_collecting): Change return type to
7033 fast_tpoint_collect_result.
7034 (maybe_move_out_of_jump_pad, linux_wait_for_event_filtered,
7035 linux_wait_1, stuck_in_jump_pad_callback,
7036 lwp_signal_can_be_delivered, linux_resume_one_lwp_throw,
7037 proceed_one_lwp): Adjust to type change.
7038
7039 2017-07-10 Yao Qi <yao.qi@linaro.org>
7040
7041 * linux-x86-low.c (x86_linux_read_description): Re-indent the code.
7042
7043 2017-06-29 Yao Qi <yao.qi@linaro.org>
7044
7045 * tdesc.h (struct target_desc) [IN_PROCESS_AGENT] <expedite_regs>:
7046 Remove.
7047 [IN_PROCESS_AGENT] <xmltarget>: Likewise.
7048
7049 2017-06-20 Simon Marchi <simon.marchi@ericsson.com>
7050
7051 * Makefile.in (IPA_OBJS): Sort and format one item per line.
7052
7053 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
7054
7055 * linux-low.c (linux_create_inferior): Adjust code to access the
7056 environment information via 'gdb_environ' class.
7057 * lynx-low.c (lynx_create_inferior): Likewise.
7058 * server.c (our_environ): Make it an instance of 'gdb_environ'.
7059 (get_environ): Return a pointer to 'our_environ'.
7060 (captured_main): Initialize 'our_environ'.
7061 * server.h (get_environ): Adjust prototype.
7062 * spu-low.c (spu_create_inferior): Adjust code to access the
7063 environment information via 'gdb_environ' class.
7064
7065 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
7066
7067 * linux-low.c (linux_read_memory, linux_write_memory): Remove
7068 usage of "register" keyword.
7069
7070 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
7071
7072 * configure: Re-generate.
7073
7074 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
7075
7076 * configure: Re-generate.
7077
7078 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
7079
7080 * Makefile.in (COMPILE.pre): Add "-x c++".
7081
7082 2017-06-09 Sergio Durigan Junior <sergiodj@redhat.com>
7083
7084 * fork-child.c: Conditionally include <signal.h>.
7085
7086 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
7087
7088 * server.c (handle_general_set): Handle new packet
7089 "QStartupWithShell".
7090 (handle_query): Add "QStartupWithShell" to the list of supported
7091 packets.
7092 (gdbserver_usage): Add help text explaining the
7093 new "--startup-with-shell" and "--no-startup-with-shell" CLI
7094 options.
7095 (captured_main): Recognize and act upon the presence of the new
7096 CLI options.
7097
7098 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
7099 Pedro Alves <palves@redhat.com>
7100
7101 * Makefile.in (SFILES): Add "nat/fork-inferior.o".
7102 * configure: Regenerate.
7103 * configure.srv (srv_linux_obj): Add "fork-child.o" and
7104 "fork-inferior.o".
7105 (i[34567]86-*-lynxos*): Likewise.
7106 (spu*-*-*): Likewise.
7107 * fork-child.c: New file.
7108 * linux-low.c: Include "common-inferior.h", "nat/fork-inferior.h"
7109 and "environ.h".
7110 (linux_ptrace_fun): New function.
7111 (linux_create_inferior): Adjust function prototype to reflect
7112 change on "target.h". Adjust function code to use
7113 "fork_inferior".
7114 (linux_request_interrupt): Delete "signal_pid".
7115 * lynx-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
7116 (lynx_ptrace_fun): New function.
7117 (lynx_create_inferior): Adjust function prototype to reflect
7118 change on "target.h". Adjust function code to use
7119 "fork_inferior".
7120 * nto-low.c (nto_create_inferior): Adjust function prototype and
7121 code to reflect change on "target.h". Update comments.
7122 * server.c: Include "common-inferior.h", "nat/fork-inferior.h",
7123 "common-terminal.h" and "environ.h".
7124 (terminal_fd): Moved to fork-child.c.
7125 (old_foreground_pgrp): Likewise.
7126 (restore_old_foreground_pgrp): Likewise.
7127 (last_status): Make it global.
7128 (last_ptid): Likewise.
7129 (our_environ): New variable.
7130 (startup_with_shell): Likewise.
7131 (program_name): Likewise.
7132 (program_argv): Rename to...
7133 (program_args): ...this.
7134 (wrapper_argv): New variable.
7135 (start_inferior): Delete function.
7136 (get_exec_wrapper): New function.
7137 (get_exec_file): Likewise.
7138 (get_environ): Likewise.
7139 (prefork_hook): Likewise.
7140 (post_fork_inferior): Likewise.
7141 (postfork_hook): Likewise.
7142 (postfork_child_hook): Likewise.
7143 (handle_v_run): Update code to deal with arguments coming from the
7144 remote host. Update calls from "start_inferior" to
7145 "create_inferior".
7146 (captured_main): Likewise. Initialize environment variable. Call
7147 "have_job_control".
7148 * server.h (post_fork_inferior): New prototype.
7149 (get_environ): Likewise.
7150 (last_status): Declare.
7151 (last_ptid): Likewise.
7152 (signal_pid): Likewise.
7153 * spu-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
7154 (spu_ptrace_fun): New function.
7155 (spu_create_inferior): Adjust function prototype to reflect change
7156 on "target.h". Adjust function code to use "fork_inferior".
7157 * target.c (target_terminal_init): New function.
7158 (target_terminal_inferior): Likewise.
7159 (target_terminal_ours): Likewise.
7160 * target.h: Include <vector>.
7161 (struct target_ops) <create_inferior>: Update prototype.
7162 (create_inferior): Update macro.
7163 * utils.c (gdb_flush_out_err): New function.
7164 * win32-low.c (win32_create_inferior): Adjust function prototype
7165 and code to reflect change on "target.h".
7166
7167 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
7168
7169 * inferiors.c (switch_to_thread): New function.
7170
7171 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
7172
7173 * Makefile.in (SFILE): Add "common/job-control.c".
7174 (OBS): Add "job-control.o".
7175
7176 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
7177
7178 * Makefile: Remove "@host_makefile_frag@".
7179
7180 2017-05-05 Pedro Alves <palves@redhat.com>
7181
7182 * configure: Regenerate.
7183
7184 2017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
7185
7186 * configure: Regenerate.
7187
7188 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
7189
7190 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Adjust to
7191 software_single_step change of return type to
7192 std::vector<CORE_ADDR>.
7193 * linux-low.c (install_software_single_step_breakpoints):
7194 Likewise.
7195 * linux-low.h (install_software_single_step_breakpoints):
7196 Likewise.
7197
7198 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
7199
7200 * remote-utils.c: Include "gdb_termios.h" instead of
7201 "terminal.h".
7202 * terminal.h: Delete file.
7203
7204 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
7205
7206 * server.c: Include <vector>.
7207 <program_argv, wrapper_argv>: Convert to std::vector.
7208 (start_inferior): Rewrite function to use C++.
7209 (handle_v_run): Likewise. Update code that calculates the argv
7210 based on the vRun packet; use C++.
7211 (captured_main): Likewise.
7212
7213 2017-04-06 Simon Marchi <simon.marchi@ericsson.com>
7214
7215 * server.c (handle_v_cont): Initialize thread_resume::thread
7216 with null_ptid.
7217
7218 2017-04-05 Pedro Alves <palves@redhat.com>
7219
7220 * configure: Regenerate.
7221
7222 2017-04-05 Pedro Alves <palves@redhat.com>
7223
7224 * gdbreplay.c (sync_error): Constify.
7225 * linux-x86-low.c (push_opcode): Constify.
7226
7227 2017-04-05 Pedro Alves <palves@redhat.com>
7228
7229 * win32-low.c (get_child_debug_event)
7230 <CREATE_PROCESS_DEBUG_EVENT>: Don't report TARGET_WAITKIND_EXECD.
7231 Report TARGET_WAITKIND_SPURIOUS instead.
7232
7233 2017-04-05 Pedro Alves <palves@redhat.com>
7234
7235 * remote-utils.c (remote_prepare, remote_open): Constify.
7236 * remote-utils.h (remote_prepare, remote_open): Constify.
7237 * server.c (captured_main): Constify 'port' handling.
7238
7239 2017-04-04 Simon Marchi <simon.marchi@ericsson.com>
7240
7241 * Makefile.in (clean): Clear .deps.
7242
7243 2017-03-31 Simon Marchi <simon.marchi@polymtl.ca>
7244
7245 * .gitignore: Remove generated files, replace with wildcard.
7246 * (clean): Replace removal of generated files with wildcard.
7247 (version.c): Replace with...
7248 (version-generated.c): ...this.
7249 (xml-builtin.c): Replace with...
7250 (xml-builtin-generated.c): ...this.
7251 (%-ipa.o: %-generated.c, %.o: %-generated.c): New rules.
7252 (%.c: *regformats*): Replace with...
7253 (%-generated.c: *regformats*): ...this.
7254
7255 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
7256
7257 * linux-xtensa-low.c (regnum::R_THREADPTR): New enum member.
7258 (xtensa_fill_gregset): Call collect_register_by_name for
7259 threadptr register.
7260 (xtensa_store_gregset): Call supply_register_by_name for
7261 threadptr register.
7262
7263 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
7264
7265 * linux-xtensa-low.c (xtensa_fill_gregset): Call collect_register
7266 for all registers in a0_regnum..a0_regnum + C0_NREGS range.
7267 (xtensa_store_gregset): Call supply_register for all registers in
7268 a0_regnum..a0_regnum + C0_NREGS range.
7269
7270 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7271
7272 * Makefile.in (%-ipa.o: %-ipa.c): New rule.
7273 (ax-ipa.o: ax.c): Remove.
7274 (linux-i386-ipa.o: linux-i386-ipa.c): Remove.
7275 (linux-amd64-ipa.o: linux-amd64-ipa.c): Remove.
7276 (linux-aarch64-ipa.o: linux-aarch64-ipa.c): Remove.
7277 (linux-s390-ipa.o: linux-s390-ipa.c): Remove.
7278 (linux-ppc-ipa.o: linux-ppc-ipa.c): Remove.
7279
7280 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7281
7282 * Makefile.in (%-ipa.o: ../common/%.c): New rule.
7283 (print-utils-ipa.o: ../common/print-utils.c): Remove.
7284 (rsp-low-ipa.o: ../common/rsp-low.c): Remove.
7285 (errors-ipa.o: ../common/errors.c): Remove.
7286 (format-ipa.o: ../common/format.c): Remove.
7287 (common-utils-ipa.o: ../common/common-utils.c): Remove.
7288
7289 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7290
7291 * Makefile.in (%-ipa.o: %.c): New rule.
7292 (tracepoint-ipa.o: tracepoint.c): Remove.
7293 (utils-ipa.o: utils.c): Remove.
7294 (remote-utils-ipa.o: remote-utils.c): Remove.
7295 (regcache-ipa.o: regcache.c): Remove.
7296 (i386-linux-ipa.o: i386-linux.c): Remove.
7297 (i386-mmx-linux-ipa.o: i386-mmx-linux.c): Remove.
7298 (i386-avx-linux-ipa.o: i386-avx-linux.c): Remove.
7299 (i386-mpx-linux-ipa.o: i386-mpx-linux.c): Remove.
7300 (i386-avx-mpx-linux-ipa.o: i386-avx-mpx-linux.c): Remove.
7301 (i386-avx-avx512-linux-ipa.o: i386-avx-avx512-linux.c): Remove.
7302 (i386-avx-mpx-avx512-pku-linux-ipa.o: i386-avx-mpx-avx512-pku-linux.c): Remove.
7303 (amd64-linux-ipa.o: amd64-linux.c): Remove.
7304 (amd64-avx-linux-ipa.o: amd64-avx-linux.c): Remove.
7305 (amd64-mpx-linux-ipa.o: amd64-mpx-linux.c): Remove.
7306 (amd64-avx-mpx-linux-ipa.o: amd64-avx-mpx-linux.c): Remove.
7307 (amd64-avx-avx512-linux-ipa.o: amd64-avx-avx512-linux.c): Remove.
7308 (amd64-avx-mpx-avx512-pku-linux-ipa.o: amd64-avx-mpx-avx512-pku-linux.c): Remove.
7309 (aarch64-ipa.o: aarch64.c): Remove.
7310 (s390-linux32-ipa.o: s390-linux32.c): Remove.
7311 (s390-linux32v1-ipa.o: s390-linux32v1.c): Remove.
7312 (s390-linux32v2-ipa.o: s390-linux32v2.c): Remove.
7313 (s390-linux64-ipa.o: s390-linux64.c): Remove.
7314 (s390-linux64v1-ipa.o: s390-linux64v1.c): Remove.
7315 (s390-linux64v2-ipa.o: s390-linux64v2.c): Remove.
7316 (s390-te-linux64-ipa.o: s390-te-linux64.c): Remove.
7317 (s390-vx-linux64-ipa.o: s390-vx-linux64.c): Remove.
7318 (s390-tevx-linux64-ipa.o: s390-tevx-linux64.c): Remove.
7319 (s390x-linux64-ipa.o: s390x-linux64.c): Remove.
7320 (s390x-linux64v1-ipa.o: s390x-linux64v1.c): Remove.
7321 (s390x-linux64v2-ipa.o: s390x-linux64v2.c): Remove.
7322 (s390x-te-linux64-ipa.o: s390x-te-linux64.c): Remove.
7323 (s390x-vx-linux64-ipa.o: s390x-vx-linux64.c): Remove.
7324 (s390x-tevx-linux64-ipa.o: s390x-tevx-linux64.c): Remove.
7325 (powerpc-32l-ipa.o: powerpc-32l.c): Remove.
7326 (powerpc-altivec32l-ipa.o: powerpc-altivec32l.c): Remove.
7327 (powerpc-cell32l-ipa.o: powerpc-cell32l.c): Remove.
7328 (powerpc-vsx32l-ipa.o: powerpc-vsx32l.c): Remove.
7329 (powerpc-isa205-32l-ipa.o: powerpc-isa205-32l.c): Remove.
7330 (powerpc-isa205-altivec32l-ipa.o: powerpc-isa205-altivec32l.c): Remove.
7331 (powerpc-isa205-vsx32l-ipa.o: powerpc-isa205-vsx32l.c): Remove.
7332 (powerpc-e500l-ipa.o: powerpc-e500l.c): Remove.
7333 (powerpc-64l-ipa.o: powerpc-64l.c): Remove.
7334 (powerpc-altivec64l-ipa.o: powerpc-altivec64l.c): Remove.
7335 (powerpc-cell64l-ipa.o: powerpc-cell64l.c): Remove.
7336 (powerpc-vsx64l-ipa.o: powerpc-vsx64l.c): Remove.
7337 (powerpc-isa205-64l-ipa.o: powerpc-isa205-64l.c): Remove.
7338 (powerpc-isa205-altivec64l-ipa.o: powerpc-isa205-altivec64l.c): Remove.
7339 (powerpc-isa205-vsx64l-ipa.o: powerpc-isa205-vsx64l.c): Remove.
7340 (tdesc-ipa.o: tdesc.c): Remove.
7341 (x32-linux-ipa.o: x32-linux.c): Remove.
7342 (x32-avx-linux-ipa.o: x32-avx-linux.c): Remove.
7343 (x32-avx512-linux-ipa.o: x32-avx512-linux.c): Remove.
7344
7345 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7346
7347 * Makefile.in (%.o: ../arch/%.c): New rule.
7348 (arm.o: ../arch/arm.c): Remove.
7349 (arm-linux.o: ../arch/arm-linux.c): Remove.
7350 (arm-get-next-pcs.o: ../arch/arm-get-next-pcs.c): Remove.
7351 (aarch64-insn.o: ../arch/aarch64-insn.c): Remove.
7352
7353 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7354
7355 * Makefile.in (%.o: ../nat/%.c): New rule.
7356 (x86-dregs.o: ../nat/x86-dregs.c): Remove.
7357 (amd64-linux-siginfo.o: ../nat/amd64-linux-siginfo.c): Remove.
7358 (linux-btrace.o: ../nat/linux-btrace.c): Remove.
7359 (linux-osdata.o: ../nat/linux-osdata.c): Remove.
7360 (linux-procfs.o: ../nat/linux-procfs.c): Remove.
7361 (linux-ptrace.o: ../nat/linux-ptrace.c): Remove.
7362 (linux-waitpid.o: ../nat/linux-waitpid.c): Remove.
7363 (mips-linux-watch.o: ../nat/mips-linux-watch.c): Remove.
7364 (ppc-linux.o: ../nat/ppc-linux.c): Remove.
7365 (linux-personality.o: ../nat/linux-personality.c): Remove.
7366 (aarch64-linux-hw-point.o: ../nat/aarch64-linux-hw-point.c): Remove.
7367 (aarch64-linux.o: ../nat/aarch64-linux.c): Remove.
7368 (x86-linux.o: ../nat/x86-linux.c): Remove.
7369 (x86-linux-dregs.o: ../nat/x86-linux-dregs.c): Remove.
7370 (linux-namespaces.o: ../nat/linux-namespaces.c): Remove.
7371
7372 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7373
7374 * Makefile.in (%.o: ../common/%.c): New rule.
7375 (signals.o: ../common/signals.c): Remove.
7376 (print-utils.o: ../common/print-utils.c): Remove.
7377 (rsp-low.o: ../common/rsp-low.c): Remove.
7378 (common-utils.o: ../common/common-utils.c): Remove.
7379 (posix-strerror.o: ../common/posix-strerror.c): Remove.
7380 (mingw-strerror.o: ../common/mingw-strerror.c): Remove.
7381 (vec.o: ../common/vec.c): Remove.
7382 (gdb_vecs.o: ../common/gdb_vecs.c): Remove.
7383 (xml-utils.o: ../common/xml-utils.c): Remove.
7384 (ptid.o: ../common/ptid.c): Remove.
7385 (buffer.o: ../common/buffer.c): Remove.
7386 (format.o: ../common/format.c): Remove.
7387 (filestuff.o: ../common/filestuff.c): Remove.
7388 (agent.o: ../common/agent.c): Remove.
7389 (errors.o: ../common/errors.c): Remove.
7390 (environ.o: ../common/environ.c): Remove.
7391 (common-debug.o: ../common/common-debug.c): Remove.
7392 (cleanups.o: ../common/cleanups.c): Remove.
7393 (common-exceptions.o: ../common/common-exceptions.c): Remove.
7394 (fileio.o: ../common/fileio.c): Remove.
7395 (common-regcache.o: ../common/common-regcache.c): Remove.
7396 (signals-state-save-restore.o: ../common/signals-state-save-restore.c): Remove.
7397 (new-op.o: ../common/new-op.c): Remove.
7398 (btrace-common.o: ../common/btrace-common.c): Remove.
7399
7400 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7401
7402 * Makefile.in (%.o: ../target/%.c): New rule.
7403 (waitstatus.o: ../target/waitstatus.c): Remove.
7404
7405 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7406
7407 * Makefile.in
7408 (%.c: ../regformats/%.dat,
7409 (%.c: ../regformats/arm/%.dat,
7410 (%.c: ../regformats/i386/%.dat,
7411 (%.c: ../regformats/rs6000/%.dat): New rules.
7412 (aarch64.c): Remove.
7413 (reg-arm.c): Remove.
7414 (arm-with-iwmmxt.c): Remove.
7415 (arm-with-vfpv2.c): Remove.
7416 (arm-with-vfpv3.c): Remove.
7417 (arm-with-neon.c): Remove.
7418 (reg-bfin.c): Remove.
7419 (reg-cris.c): Remove.
7420 (reg-crisv32.c): Remove.
7421 (i386.c): Remove.
7422 (i386-linux.c): Remove.
7423 (i386-avx.c): Remove.
7424 (i386-avx-linux.c): Remove.
7425 (i386-avx-avx512.c): Remove.
7426 (i386-avx-avx512-linux.c): Remove.
7427 (i386-mpx.c): Remove.
7428 (i386-mpx-linux.c): Remove.
7429 (i386-avx-mpx-avx512-pku.c): Remove.
7430 (i386-avx-mpx-avx512-pku-linux.c): Remove.
7431 (i386-avx-mpx.c): Remove.
7432 (i386-avx-mpx-linux.c): Remove.
7433 (i386-mmx.c): Remove.
7434 (i386-mmx-linux.c): Remove.
7435 (reg-ia64.c): Remove.
7436 (reg-m32r.c): Remove.
7437 (reg-m68k.c): Remove.
7438 (reg-cf.c): Remove.
7439 (mips-linux.c): Remove.
7440 (mips-dsp-linux.c): Remove.
7441 (mips64-linux.c): Remove.
7442 (mips64-dsp-linux.c): Remove.
7443 (nios2-linux.c): Remove.
7444 (powerpc-32.c): Remove.
7445 (powerpc-32l.c): Remove.
7446 (powerpc-altivec32l.c): Remove.
7447 (powerpc-cell32l.c): Remove.
7448 (powerpc-vsx32l.c): Remove.
7449 (powerpc-isa205-32l.c): Remove.
7450 (powerpc-isa205-altivec32l.c): Remove.
7451 (powerpc-isa205-vsx32l.c): Remove.
7452 (powerpc-e500l.c): Remove.
7453 (powerpc-64l.c): Remove.
7454 (powerpc-altivec64l.c): Remove.
7455 (powerpc-cell64l.c): Remove.
7456 (powerpc-vsx64l.c): Remove.
7457 (powerpc-isa205-64l.c): Remove.
7458 (powerpc-isa205-altivec64l.c): Remove.
7459 (powerpc-isa205-vsx64l.c): Remove.
7460 (s390-linux32.c): Remove.
7461 (s390-linux32v1.c): Remove.
7462 (s390-linux32v2.c): Remove.
7463 (s390-linux64.c): Remove.
7464 (s390-linux64v1.c): Remove.
7465 (s390-linux64v2.c): Remove.
7466 (s390-te-linux64.c): Remove.
7467 (s390-vx-linux64.c): Remove.
7468 (s390-tevx-linux64.c): Remove.
7469 (s390x-linux64.c): Remove.
7470 (s390x-linux64v1.c): Remove.
7471 (s390x-linux64v2.c): Remove.
7472 (s390x-te-linux64.c): Remove.
7473 (s390x-vx-linux64.c): Remove.
7474 (s390x-tevx-linux64.c): Remove.
7475 (tic6x-c64xp-linux.c): Remove.
7476 (tic6x-c64x-linux.c): Remove.
7477 (tic6x-c62x-linux.c): Remove.
7478 (reg-sh.c): Remove.
7479 (reg-sparc64.c): Remove.
7480 (reg-spu.c): Remove.
7481 (amd64.c): Remove.
7482 (amd64-linux.c): Remove.
7483 (amd64-avx.c): Remove.
7484 (amd64-avx-linux.c): Remove.
7485 (amd64-avx-avx512.c): Remove.
7486 (amd64-avx-avx512-linux.c): Remove.
7487 (amd64-mpx.c): Remove.
7488 (amd64-mpx-linux.c): Remove.
7489 (amd64-avx-mpx-avx512-pku.c): Remove.
7490 (amd64-avx-mpx-avx512-pku-linux.c): Remove.
7491 (amd64-avx-mpx.c): Remove.
7492 (amd64-avx-mpx-linux.c): Remove.
7493 (x32.c): Remove.
7494 (x32-linux.c): Remove.
7495 (x32-avx.c): Remove.
7496 (x32-avx-linux.c): Remove.
7497 (x32-avx-avx512.c): Remove.
7498 (x32-avx-avx512-linux.c): Remove.
7499 (reg-xtensa.c): Remove.
7500 (reg-tilegx.c): Remove.
7501 (reg-tilegx32.c): Remove.
7502
7503 2017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
7504
7505 * Makefile.in (SFILES): Add "common/environ.c".
7506 (OBJS): Add "common/environ.h".
7507
7508 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
7509
7510 * configure.ac: Check if the fs_base and gs_base members of
7511 `struct user_regs_struct' exist.
7512 * config.in: Regenerated.
7513 * configure: Likewise.
7514
7515 2017-01-09 Antoine Tremblay <antoine.tremblay@ericsson.com>
7516
7517 * linux-aarch32-low.c (arm_breakpoint_kind_from_pc): Use
7518 target_read_memory.
7519 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer): Likewise.
7520 (get_next_pcs_syscall_next_pc): Likewise.
7521
7522 2016-12-23 Luis Machado <lgustavo@codesourcery.com>
7523
7524 * win32-i386-low.c: Fix incorrect reference to a couple source files.
7525 * nto-x86-low.c: Likewise.
7526
7527 2016-11-30 Simon Marchi <simon.marchi@polymtl.ca>
7528
7529 * Makefile.in: Include disable-implicit-rules.mk.
7530
7531 2016-11-23 Pedro Alves <palves@redhat.com>
7532
7533 * debug.c: Include <chrono> instead of "gdb_sys_time.h".
7534 (debug_vprintf): Use std::chrono::steady_clock instead of
7535 gettimeofday. Use '.' instead of ':'.
7536 * tracepoint.c: Include <chrono> instead of "gdb_sys_time.h".
7537 (get_timestamp): Use std::chrono::steady_clock instead of
7538 gettimeofday.
7539
7540 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
7541
7542 * Makefile.in: Fix whitespace formatting.
7543
7544 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
7545
7546 * Makefile.in (SFILES, OBS): Flatten list and order
7547 alphabetically.
7548
7549 2016-11-23 Pedro Alves <palves@redhat.com>
7550
7551 * event-loop.c (handle_file_event): Use warning.
7552 * linux-low.c (linux_resume_one_lwp_throw): Use warning.
7553 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
7554 Use warning.
7555
7556 2016-11-23 Pedro Alves <palves@redhat.com>
7557
7558 * linux-low.c (check_zombie_leaders): Use debug_printf for debug
7559 output.
7560 * notif.c (handle_notif_ack, notif_event_enque): Likewise.
7561 * remote-utils.c (putpkt_binary_1, readchar, getpkt): Use
7562 debug_printf and debug_flush for debug output.
7563 * server.c (handle_general_set): Likewise.
7564 * thread-db.c (try_thread_db_load): Use debug_printf for debug
7565 output.
7566
7567 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
7568
7569 * Makefile.in (.c.o): Replace rule with ...
7570 (%.o: %.c): ... this one.
7571
7572 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
7573
7574 * Makefile.in: Remove @GMAKE_TRUE@ prefixes and removes lines
7575 prefixed with @GMAKE_FALSE@. Update comment related to non-GNU
7576 make.
7577 * configure.ac: Remove checks for the make program.
7578 * configure: Re-generate.
7579
7580 2016-10-28 Pedro Alves <palves@redhat.com>
7581
7582 * Makefile.in (CXX_DIALECT): Get from configure.
7583 (COMPILE.pre, CC_LD): Append $(CXX_DIALECT).
7584 * acinclude.m4: Include ../ax_cxx_compile_stdcxx.m4.
7585 * configure.ac: Call AX_CXX_COMPILE_STDCXX.
7586 * config.in: Regenerate.
7587 * configure: Regenerate.
7588
7589 2016-10-27 Yao Qi <yao.qi@linaro.org>
7590
7591 * linux-low.c (linux_supports_range_stepping): Return true if
7592 can_software_single_step return true.
7593
7594 2016-10-27 Yao Qi <yao.qi@linaro.org>
7595
7596 * inferiors.c (find_inferior_in_random): New function.
7597 * inferiors.h (find_inferior_in_random): Declare.
7598 * linux-low.c (linux_wait_for_event_filtered): Call
7599 find_inferior_in_random instead of find_inferior.
7600
7601 2016-10-27 Yao Qi <yao.qi@linaro.org>
7602
7603 * linux-low.c (linux_wait_1): If single-step breakpoints are
7604 inserted, remove them.
7605
7606 2016-10-26 Pedro Alves <palves@redhat.com>
7607
7608 * linux-low.c (handle_extended_wait): Link parent/child fork
7609 threads.
7610 (linux_wait_1): Unlink them.
7611 (linux_set_resume_request): Ignore resume requests for
7612 already-resumed and unhandled fork child threads.
7613 * linux-low.h (struct lwp_info) <fork_relative>: New field.
7614 * server.c (in_queued_stop_replies_ptid, in_queued_stop_replies):
7615 New functions.
7616 (handle_v_requests) <vCont>: Don't call require_running.
7617 * server.h (in_queued_stop_replies): New declaration.
7618
7619 2016-10-24 Yao Qi <yao.qi@linaro.org>
7620
7621 PR server/20733
7622 * linux-aarch64-low.c (append_insns): Cast the return value to
7623 'uint32_t *'.
7624
7625 2016-10-10 Yao Qi <yao.qi@linaro.org>
7626
7627 * linux-aarch32-low.c (enum arm_breakpoint_kinds): Remove.
7628
7629 2016-10-06 Sergio Durigan Junior <sergiodj@redhat.com>
7630
7631 * target.c (target_supports_multi_process): New function, moved
7632 from...
7633 * target.h (target_supports_multi_process): ... here. Remove
7634 macro.
7635
7636 2016-10-05 Tom Tromey <tom@tromey.com>
7637
7638 PR remote/20655:
7639 * tracepoint.c (handle_tracepoint_bkpts): Check
7640 ipa_error_tracepoint, not ipa_stopping_tracepoint.
7641
7642 2016-10-05 Yao Qi <yao.qi@linaro.org>
7643
7644 * configure.srv: Update the path of arm-*.xml files.
7645
7646 2016-10-05 Terry Guo <terry.guo@arm.com>
7647 Yao Qi <yao.qi@linaro.org>
7648
7649 * Makefile.in: Adjust the path of rules.
7650 * configure.srv: Update the path of xml files.
7651 * regformats/arm-with-iwmmxt.dat: Regenerated.
7652 * regformats/arm-with-neon.dat: Likewise.
7653 * regformats/arm-with-vfpv2.dat: Likewise.
7654 * regformats/arm-with-vfpv3.dat Likewise.
7655
7656 2016-09-30 Yao Qi <yao.qi@linaro.org>
7657
7658 PR gdbserver/20627
7659 * target.c (target_stop_and_wait): Don't call
7660 target_continue_no_signal, use resume_stop instead.
7661
7662 2016-09-26 Yao Qi <yao.qi@linaro.org>
7663
7664 * linux-low.c (linux_wait_1): Call debug_exit.
7665
7666 2016-09-23 Pedro Alves <palves@redhat.com>
7667
7668 * Makefile.in (SFILES): Add common/new-op.c.
7669 (OBS): Add common/new-op.o.
7670 (new-op.o): New rule.
7671
7672 2016-09-21 Simon Marchi <simon.marchi@ericsson.com>
7673
7674 * .gitinore: Ignore more files.
7675
7676 2016-09-21 Yao Qi <yao.qi@linaro.org>
7677
7678 * linux-aarch32-low.c (arm_fill_gregset): Keep bits 20 to
7679 23.
7680
7681 2016-09-19 Sergio Durigan Junior <sergiodj@redhat.com>
7682
7683 * server.c (start_inferior): Call target_mourn_inferior instead of
7684 mourn_inferior; pass ptid_t argument to it.
7685 (resume): Likewise.
7686 (handle_target_event): Likewise.
7687 * target.c (target_mourn_inferior): New function.
7688 * target.h (mourn_inferior): Delete macro.
7689
7690 2016-09-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
7691
7692 * linux-low.c (lwp_is_stepping): New function.
7693
7694 2016-09-06 Carl Love <cel@us.ibm.com>
7695
7696 * server.c (start_inferior): Fixed comment, requested comment change
7697 didn't get updated correctly. Removed reference to ptrace () call as
7698 it is only true on Linux systems.
7699
7700 2016-09-06 Carl Love <cel@us.ibm.com>
7701
7702 * server.c (start_inferior): Do not call
7703 function target_post_create_inferior () if the
7704 inferior process has already exited.
7705
7706 2016-09-05 Pedro Alves <palves@redhat.com>
7707
7708 * Makefile.in (COMPILER, COMPILER_CFLAGS): Remove.
7709 (COMPILE.pre, CC_LD): Use CXX directly.
7710 (INTERNAL_CFLAGS_BASE): Use CXXFLAGS directly.
7711 * acinclude.m4: Don't include build-with-cxx.m4.
7712 * configure.ac: Remove GDB_AC_BUILD_WITH_CXX call.
7713 * configure: Regenerate.
7714
7715 2016-09-02 Akash Trehan <akash.trehan123@gmail.com>
7716
7717 PR gdb/19495
7718 * remote-utils.c (relocate_instruction): Remove redundant strcpy()
7719 call writing data to own_buf.
7720
7721 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
7722
7723 * target.c (mywait): Call target_wait instead of
7724 the_target->wait.
7725 (target_wait): New function.
7726
7727 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
7728
7729 * server.c (start_inferior): New variable 'ptid'. Replace calls
7730 to the_target->resume by target_continue{,_no_signal}, depending
7731 on the case.
7732 * target.c (target_stop_and_wait): Call target_continue_no_signal
7733 instead of the_target->resume.
7734 (target_continue): New function.
7735
7736 2016-08-31 Antoine Tremblay <antoine.tremblay@ericsson.com>
7737
7738 * linux-low.c (linux_wait_1): Move event switch after unsuspend_lwps.
7739
7740 2016-08-25 Adhemerval Zanella <adhemerval.zanella@linaro.org>
7741
7742 PR server/20491
7743 * gdb_proc_service.h (ps_get_thread_area): Remove const from struct
7744 ps_prochandle.
7745 * linux-aarch64-low.c (ps_get_thread_area): Likewise.
7746 * linux-arm-low.c (ps_get_thread_area): Likewise.
7747 * linux-crisv32-low.c (ps_get_thread_area): Likewise.
7748 * linux-m68k-low.c (ps_get_thread_area): Likewise.
7749 * linux-mips-low.c (ps_get_thread_area): Likewise.
7750 * linux-nios2-low.c (ps_get_thread_area): Likewise.
7751 * linux-tic6x-low.c (ps_get_thread_area): Likewise.
7752 * linux-x86-low.c (ps_get_thread_area): Likewise.
7753 * linux-xtensa-low.c (ps_get_thread_area): Likewise.
7754
7755 2016-08-19 Pedro Alves <palves@redhat.com>
7756
7757 * linux-x86-low.c (amd64_emit_call): Emit missing call opcode.
7758
7759 2016-08-19 Pedro Alves <palves@redhat.com>
7760
7761 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Fix
7762 comment. Use memcpy instead of casting through unsigned long.
7763
7764 2016-08-19 Pedro Alves <palves@redhat.com>
7765
7766 * linux-amd64-ipa.c (alloc_jump_pad_buffer) [__ILP32__]: Try
7767 allocating around 0x80000000.
7768
7769 2016-08-19 Pedro Alves <palves@redhat.com>
7770
7771 PR gdb/20415
7772 * Makefile.in (x32-linux-ipa.o, x32-avx-linux-ipa.o)
7773 (x32-avx512-linux-ipa.o): New rules.
7774 * configure.ac (x86_64-*-linux*): New x32 check.
7775 * configure.srv (ipa_x32_linux_regobj): New.
7776 (x86_64-*-linux*): Use $ipa_x32_linux_regobj if building for x32.
7777 * linux-amd64-ipa.c (get_ipa_tdesc) [__ILP32__]: Return x32
7778 descriptions.
7779 (initialize_low_tracepoint) [__ILP32__]: Initialize x32
7780 descriptions.
7781 * configure: Regenerate.
7782
7783 2016-08-09 Pedro Alves <palves@redhat.com>
7784
7785 PR gdb/18653
7786 * Makefile.in (OBS): Add signals-state-save-restore.o.
7787 (signals-state-save-restore.o): New rule.
7788 * config.in: Regenerate.
7789 * configure: Regenerate.
7790 * linux-low.c: Include "signals-state-save-restore.h".
7791 (linux_create_inferior): Call
7792 restore_original_signals_state.
7793 * server.c: Include "dispositions-save-restore.h".
7794 (captured_main): Call save_original_signals_state.
7795
7796 2016-08-05 Pedro Alves <palves@redhat.com>
7797
7798 * configure: Regenerate.
7799
7800 2016-08-04 Yao Qi <yao.qi@linaro.org>
7801
7802 * linux-low.c (regsets_fetch_inferior_registers): Check
7803 errno is ESRCH or not.
7804
7805 2016-08-02 Yao Qi <yao.qi@linaro.org>
7806
7807 * thread-db.c (struct thread_db) <td_ta_event_getmsg_p>: Remove.
7808 <td_ta_set_event_p, td_ta_event_addr_p>: Remove.
7809 (thread_db_load_search): Update.
7810 (try_thread_db_load_1): Don't look for td_ta_event_addr,
7811 td_ta_set_event and td_ta_event_getmsg.
7812
7813 2016-07-26 Pedro Alves <palves@redhat.com>
7814
7815 PR server/20414
7816 * linux-x86-low.c (x86_get_pc, x86_set_pc): Use uint64_t instead
7817 of unsigned long for 64-bit registers and use uint32_t instead of
7818 unsigned int for 32-bit registers.
7819
7820 2016-07-26 Pedro Alves <palves@redhat.com>
7821
7822 * linux-x86-low.c (x86_siginfo_fixup): Rename 'native' parameter
7823 to 'ptrace'.
7824
7825 2016-07-21 Tom Tromey <tom@tromey.com>
7826
7827 * configure: Rebuild.
7828
7829 2016-07-21 Yao Qi <yao.qi@linaro.org>
7830
7831 * mem-break.c (find_gdb_breakpoint): Cast bp to
7832 'struct gdb_breakpoint *' rather than 'gdb_breakpoint *'.
7833
7834 2016-07-21 Yao Qi <yao.qi@linaro.org>
7835
7836 * server.c (handle_v_requests): Support s and S actions
7837 if target_supports_software_single_step return true.
7838
7839 2016-07-21 Yao Qi <yao.qi@linaro.org>
7840
7841 * linux-low.c (resume_stopped_resumed_lwps): If resume request
7842 is resume_step, call maybe_hw_step.
7843 (linux_wait_1): Stop all threads, remove reinsert breakpoints,
7844 and unstop them.
7845 (linux_resume_one_lwp_throw): Don't assert the thread has reinsert
7846 breakpoints or not.
7847 (proceed_one_lwp): If resume request is resume_step, install
7848 reinsert breakpoints and call maybe_hw_step.
7849
7850 2016-07-21 Yao Qi <yao.qi@linaro.org>
7851
7852 * linux-low.c (proceed_one_lwp): Declare.
7853 (linux_resume_one_thread): Remove local variable 'step'.
7854 Lift code enqueue signal. Call proceed_one_lwp instead of
7855 linux_resume_one_lwp.
7856
7857 2016-07-21 Yao Qi <yao.qi@linaro.org>
7858
7859 * linux-low.c (linux_resume_one_thread): Call
7860 enqueue_pending_signal.
7861
7862 2016-07-21 Yao Qi <yao.qi@linaro.org>
7863
7864 * gdbthread.h (make_cleanup_restore_current_thread): Declare.
7865 * inferiors.c (do_restore_current_thread_cleanup): New function.
7866 (make_cleanup_restore_current_thread): Likewise.
7867 * linux-low.c (install_software_single_step_breakpoints): Call
7868 make_cleanup_restore_current_thread. Switch current_thread to
7869 thread.
7870
7871 2016-07-21 Yao Qi <yao.qi@linaro.org>
7872
7873 * mem-break.c (struct reinsert_breakpoint) <ptid>: New field.
7874 (set_reinsert_breakpoint): New parameter ptid. Callers updated.
7875 (clone_one_breakpoint): Likewise.
7876 (delete_reinsert_breakpoints): Change parameter to thread.
7877 Callers updated.
7878 (has_reinsert_breakpoints): Likewise.
7879 (uninsert_reinsert_breakpoints): Likewise.
7880 (reinsert_reinsert_breakpoints): Likewise.
7881 * mem-break.h (set_reinsert_breakpoint): Update declaration.
7882 (delete_reinsert_breakpoints): Likewise.
7883 (reinsert_reinsert_breakpoints): Likewise.
7884 (uninsert_reinsert_breakpoints): Likewise.
7885 (has_reinsert_breakpoints): Likewise.
7886
7887 2016-07-21 Yao Qi <yao.qi@linaro.org>
7888
7889 * inferiors.c (get_thread_process): Make parameter const.
7890 * inferiors.h (get_thread_process): Update declaration.
7891 * mem-break.c (clone_all_breakpoints): Remove all parameters.
7892 Add new parameters child_thread and parent_thread. Callers
7893 updated.
7894 * mem-break.h (clone_all_breakpoints): Update declaration.
7895
7896 2016-07-21 Yao Qi <yao.qi@linaro.org>
7897
7898 * mem-break.c (struct breakpoint) <cond_list>: Remove.
7899 <command_list, handler>: Remove.
7900 (struct gdb_breakpoint): New.
7901 (struct other_breakpoint): New.
7902 (struct reinsert_breakpoint): New.
7903 (is_gdb_breakpoint): New function.
7904 (any_persistent_commands): Update command_list if
7905 is_gdb_breakpoint returns true.
7906 (set_breakpoint): Create breakpoints according to their types.
7907 (find_gdb_breakpoint): Return 'struct gdb_breakpoint *'.
7908 (set_gdb_breakpoint_1): Likewise.
7909 (set_gdb_breakpoint): Likewise.
7910 (clear_breakpoint_conditions): Change parameter type to
7911 'struct gdb_breakpoint *'.
7912 (clear_breakpoint_commands): Likewise.
7913 (clear_breakpoint_conditions_and_commands): Likewise.
7914 (add_condition_to_breakpoint): Likewise.
7915 (add_breakpoint_condition): Likewise.
7916 (add_commands_to_breakpoint): Likewise.
7917 (check_breakpoints): Check other_breakpoint.
7918 (clone_one_breakpoint): Clone breakpopint according to its type.
7919 * mem-break.h (struct gdb_breakpoint): Declare.
7920 (set_gdb_breakpoint): Update declaration.
7921 (clear_breakpoint_conditions_and_commands): Likewise.
7922 (add_breakpoint_condition): Likewise.
7923 (add_breakpoint_commands): Likewise.
7924 * server.c (process_point_options): Change parameter type to
7925 'struct gdb_breakpoint *'.
7926
7927 2016-07-21 Yao Qi <yao.qi@linaro.org>
7928
7929 * mem-break.c (set_breakpoint_at): Rename it to ...
7930 (set_breakpoint_type_at): ... it.
7931 (set_breakpoint_at): Call set_breakpoint_type_at.
7932 (set_reinsert_breakpoint): Call set_breakpoint_type_at.
7933 * mem-break.h (set_breakpoint_at): Update comments.
7934
7935 2016-07-12 Chung-Lin Tang <cltang@codesourcery.com>
7936
7937 * linux-nios2-low.c (nios2_fill_gregset): Add type cast
7938 to buf parameter.
7939 (nios2_store_gregset): Likewise.
7940
7941 2016-07-01 Pedro Alves <palves@redhat.com>
7942 Antoine Tremblay <antoine.tremblay@ericsson.com>
7943
7944 * linux-low.c: Change interface to take the target lwp_info
7945 pointer directly and return void. Handle detaching from a zombie
7946 thread.
7947 (linux_detach_lwp_callback): New function.
7948 (linux_detach): Detach from the leader thread after detaching from
7949 the clone threads.
7950
7951 2016-06-28 Yao Qi <yao.qi@linaro.org>
7952
7953 * linux-aarch64-low.c (aarch64_ftrace_insn_reloc_b): Use int64_t
7954 for variable new_offset.
7955 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
7956 (aarch64_ftrace_insn_reloc_cb): Likewise.
7957 (aarch64_ftrace_insn_reloc_tb): Likewise.
7958 (aarch64_install_fast_tracepoint_jump_pad): Likewise. Use
7959 PRIx64 instead of PRIx32.
7960
7961 2016-06-28 Yao Qi <yao.qi@linaro.org>
7962
7963 * linux-arm-low.c (arm_get_syscall_trapinfo): New function.
7964 (the_low_target): Install arm_get_syscall_trapinfo.
7965
7966 2016-06-28 Yao Qi <yao.qi@linaro.org>
7967
7968 * linux-aarch64-low.c (aarch64_get_syscall_trapinfo): New
7969 function.
7970 (the_low_target): Install aarch64_get_syscall_trapinfo.
7971
7972 2016-06-28 Yao Qi <yao.qi@linaro.org>
7973
7974 * linux-low.c (get_syscall_trapinfo): Remove parameter sysret.
7975 Callers updated.
7976 * linux-low.h (struct linux_target_ops) <get_syscall_trapinfo>:
7977 Remove parameter sysno.
7978 * linux-x86-low.c (x86_get_syscall_trapinfo): Remove parameter
7979 sysret.
7980
7981 2016-06-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
7982
7983 * linux-s390-low.c (s390_emit_eq_goto): Mark function static.
7984 (s390_emit_ne_goto): Likewise.
7985 (s390_emit_lt_goto): Likewise.
7986 (s390_emit_le_goto): Likewise.
7987 (s390_emit_gt_goto): Likewise.
7988 (s390_emit_ge_goto): Likewise.
7989 (s390x_emit_eq_goto): Likewise.
7990 (s390x_emit_ne_goto): Likewise.
7991 (s390x_emit_lt_goto): Likewise.
7992 (s390x_emit_le_goto): Likewise.
7993 (s390x_emit_gt_goto): Likewise.
7994 (s390x_emit_ge_goto): Likewise.
7995 (s390_emit_ops_impl): Mark variable static.
7996 (s390x_emit_ops): Likewise.
7997
7998 2016-06-17 Yao Qi <yao.qi@linaro.org>
7999
8000 * linux-low.c (handle_extended_wait): Call
8001 uninsert_reinsert_breakpoints for the parent process. Remove
8002 reinsert breakpoints from the child process. Reinsert them to
8003 the parent process when vfork is done.
8004 * mem-break.c (uninsert_reinsert_breakpoints): New function.
8005 (reinsert_reinsert_breakpoints): New function.
8006 * mem-break.h (uninsert_reinsert_breakpoints): Declare
8007 (reinsert_reinsert_breakpoints): Declare.
8008
8009 2016-06-17 Yao Qi <yao.qi@linaro.org>
8010
8011 * linux-low.c (handle_extended_wait): If the parent is doing
8012 step-over, remove the reinsert breakpoints from the forked child.
8013
8014 2016-06-17 Yao Qi <yao.qi@linaro.org>
8015
8016 * linux-low.c (unsuspend_all_lwps): Declare.
8017 (linux_low_filter_event): If thread exited, call finish_step_over.
8018 If step-over is finished, unsuspend other threads.
8019
8020 2016-06-17 Yao Qi <yao.qi@linaro.org>
8021
8022 * linux-low.c (linux_resume_one_lwp_throw): Assert
8023 has_reinsert_breakpoints returns false.
8024 * mem-break.c (delete_disabled_breakpoints): Assert
8025 bp type isn't reinsert_breakpoint.
8026
8027 2016-06-17 Yao Qi <yao.qi@linaro.org>
8028
8029 * linux-low.c (maybe_hw_step): New function.
8030 (linux_resume_one_lwp_throw): Call maybe_hw_step.
8031 (finish_step_over): Switch current_thread to lwp temporarily,
8032 and assert has_reinsert_breakpoints returns true.
8033 (proceed_one_lwp): Call maybe_hw_step.
8034 * mem-break.c (has_reinsert_breakpoints): New function.
8035 * mem-break.h (has_reinsert_breakpoints): Declare.
8036
8037 2016-06-02 Jon Turney <jon.turney@dronecode.org.uk>
8038
8039 * win32-low.c (win32_create_inferior): Add pointer casts for C++.
8040
8041 2016-05-17 Yao Qi <yao.qi@linaro.org>
8042
8043 * linux-low.c (linux_stabilize_threads): Call unsuspend_all_lwps
8044 instead of find_inferior.
8045
8046 2016-05-05 Yao Qi <yao.qi@linaro.org>
8047
8048 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer):
8049 Initialize res to zero.
8050
8051 2016-05-05 Yao Qi <yao.qi@linaro.org>
8052
8053 * linux-arm-low.c (arm_sigreturn_next_pc): Change type of cpsr
8054 to uint32_t.
8055
8056 2016-05-04 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
8057
8058 * spu-low.c (fetch_ppc_register): Cast PowerPC-Linux-specific value
8059 used as first ptrace argument to PTRACE_TYPE_ARG1 for C++.
8060 (fetch_ppc_memory_1, store_ppc_memory_1): Likewise.
8061
8062 2016-04-28 Par Olsson <par.olsson@windriver.com>
8063 Simon Marchi <simon.marchi@ericsson.com>
8064
8065 * tracepoint.c (write_inferior_int8): New function.
8066 (cmd_qtenable_disable): Write enable flag using
8067 write_inferior_int8.
8068
8069 2016-04-25 Yao Qi <yao.qi@linaro.org>
8070
8071 * linux-low.c (lwp_signal_can_be_delivered): Adjust.
8072 (need_step_over_p): Return zero if the LWP has pending signals
8073 can be delivered on software single step target.
8074
8075 2016-04-25 Yao Qi <yao.qi@linaro.org>
8076
8077 * linux-low.c (reinsert_raw_breakpoint): If bp->inserted is true
8078 return instead of error.
8079
8080 2016-04-22 Yao Qi <yao.qi@linaro.org>
8081
8082 * linux-aarch32-low.c (arm_store_gregset): Clear CPSR bits 20
8083 to 23.
8084
8085 2016-04-22 Yao Qi <yao.qi@linaro.org>
8086
8087 * linux-low.c (lwp_signal_can_be_delivered): Don't deliver
8088 signal when stepping over breakpoint with software single
8089 step.
8090
8091 2016-04-21 Pedro Alves <palves@redhat.com>
8092
8093 * linux-s390-low.c (s390_collect_ptrace_register)
8094 (s390_supply_ptrace_register, s390_get_hwcap): Use gdb_byte * and
8095 add casts.
8096 (s390_check_regset): Use void * instead of gdb_byte *.
8097
8098 2016-04-20 Pedro Alves <palves@redhat.com>
8099
8100 * configure: Renegerate.
8101
8102 2016-04-20 Yao Qi <yao.qi@linaro.org>
8103
8104 * linux-aarch32-low.c: Include "arch/arm-linux.h".
8105 (arm_fill_gregset): Use ARM_CPSR_GREGNUM rather than magic
8106 number 16.
8107 (arm_store_gregset): Likewise.
8108
8109 2016-04-16 Walfred Tedeschi <walfred.tedeschi@intel.com>
8110
8111 * Makefile.in (clean): Add removal for i386-avx-mpx.c,
8112 i386-avx-mpx-linux.c, amd64-avx-mpx.c and amd64-avx-mpx-linux.c.
8113 (i386-avx-mpx.c, i386-avx-mpx-linux.c, amd64-avx-mpx.c)
8114 (amd64-avx-mpx-linux.c): New rules.
8115 (amd64-avx-mpx-linux-ipa.o, i386-avx-mpx-linux-ipa.o): New rule.
8116 * configure.srv (srv_i386_regobj): Add i386-avx-mpx.o.
8117 (srv_i386_linux_regobj): Add i386-avx-mpx-linux.o.
8118 (srv_amd64_regobj): Add amd64-avx-mpx.o.
8119 (srv_amd64_linux_regobj): Add amd64-avx-mpx-linux.o.
8120 (srv_i386_xmlfiles): Add i386/i386-avx-mpx.xml.
8121 (srv_amd64_xmlfiles): Add i386/amd64-avx-mpx.xml.
8122 (srv_i386_linux_xmlfiles): Add i386/i386-avx-mpx-linux.xml.
8123 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-mpx-linux.xml.
8124 (ipa_i386_linux_regobj): Add i386-avx-mpx-linux-ipa.o.
8125 (ipa_amd64_linux_regobj): Add amd64-avx-mpx-linux-ipa.o.
8126 * linux-x86-low.c (x86_linux_read_description): Add case for
8127 X86_XSTATE_AVX_MPX_MASK.
8128 (x86_get_ipa_tdesc_idx): Add cases for avx_mpx.
8129 (initialize_low_arch): Call init_registers_amd64_avx_mpx_linux and
8130 init_registers_i386_avx_mpx_linux.
8131 * linux-i386-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
8132 (initialize_low_tracepoint): Call
8133 init_registers_i386_avx_mpx_linux.
8134 * linux-amd64-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
8135 (initialize_low_tracepoint): Call
8136 init_registers_amd64_avx_mpx_linux.
8137 * linux-x86-tdesc.h (X86_TDESC_AVX_MPX): New enum value.
8138 (init_registers_amd64_avx_mpx_linux, tdesc_amd64_avx_mpx_linux)
8139 (init_registers_i386_avx_mpx_linux, tdesc_i386_avx_mpx_linux): New
8140 declarations.
8141
8142 2016-04-18 Pedro Alves <palves@redhat.com>
8143
8144 * configure: Regenerate.
8145
8146 2016-04-13 Antoine Tremblay <antoine.tremblay@ericsson.com>
8147
8148 * linux-aarch64-low.c (aarch64_emit_add): Switch x1 and x0.
8149 (aarch64_emit_sub): Likewise.
8150
8151 2016-04-12 Pedro Alves <palves@redhat.com>
8152
8153 * utils.c (prepare_to_throw_exception): Delete.
8154
8155 2016-04-05 Simon Marchi <simon.marchi@ericsson.com>
8156
8157 * Makefile.in ($(IPA_LIB)): Set SONAME of the IPA lib.
8158
8159 2016-04-05 Marcin Kościelnicki <koriakin@0x04.net>
8160
8161 * tracepoint.c (getauxval): Move to #ifdef IN_PROCESS_AGENT.
8162
8163 2016-04-03 Marcin Kościelnicki <koriakin@0x04.net>
8164
8165 * linux-aarch64-ipa.c: Add <elf.h> include.
8166 * linux-ppc-ipa.c: Add <elf.h> include.
8167 * linux-s390-ipa.c: Add <elf.h> include.
8168
8169 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
8170
8171 * tracepoint.c (gdb_collect_ptr): Remove const qualifier.
8172 (get_raw_reg_ptr): Likewise.
8173 (get_trace_state_variable_value_ptr): Likewise.
8174 (set_trace_state_variable_value_ptr): Likewise.
8175 (initialize_tracepoint): Cast alloc_jump_pad_buffer result to
8176 char *.
8177
8178 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
8179 Marcin Kościelnicki <koriakin@0x04.net>
8180
8181 PR/17221
8182 * linux-ppc-low.c (emit_insns): New function.
8183 (__EMIT_ASM, _EMIT_ASM, EMIT_ASM): New macros.
8184 (ppc_emit_prologue): New function.
8185 (ppc_emit_epilogue): New function.
8186 (ppc_emit_add): New function.
8187 (ppc_emit_sub): New function.
8188 (ppc_emit_mul): New function.
8189 (ppc_emit_lsh): New function.
8190 (ppc_emit_rsh_signed): New function.
8191 (ppc_emit_rsh_unsigned): New function.
8192 (ppc_emit_ext): New function.
8193 (ppc_emit_zero_ext): New function.
8194 (ppc_emit_log_not): New function.
8195 (ppc_emit_bit_and): New function.
8196 (ppc_emit_bit_or): New function.
8197 (ppc_emit_bit_xor): New function.
8198 (ppc_emit_bit_not): New function.
8199 (ppc_emit_equal): New function.
8200 (ppc_emit_less_signed): New function.
8201 (ppc_emit_less_unsigned): New function.
8202 (ppc_emit_ref): New function.
8203 (ppc_emit_const): New function.
8204 (ppc_emit_reg): New function.
8205 (ppc_emit_pop): New function.
8206 (ppc_emit_stack_flush): New function.
8207 (ppc_emit_swap): New function.
8208 (ppc_emit_stack_adjust): New function.
8209 (ppc_emit_call): New function.
8210 (ppc_emit_int_call_1): New function.
8211 (ppc_emit_void_call_2): New function.
8212 (ppc_emit_if_goto): New function.
8213 (ppc_emit_goto): New function.
8214 (ppc_emit_eq_goto): New function.
8215 (ppc_emit_ne_goto): New function.
8216 (ppc_emit_lt_goto): New function.
8217 (ppc_emit_le_goto): New function.
8218 (ppc_emit_gt_goto): New function.
8219 (ppc_emit_ge_goto): New function.
8220 (ppc_write_goto_address): New function.
8221 (ppc_emit_ops_impl): New static variable.
8222 (ppc64v1_emit_prologue): New function.
8223 (ppc64v2_emit_prologue): New function.
8224 (ppc64_emit_epilogue): New function.
8225 (ppc64_emit_add): New function.
8226 (ppc64_emit_sub): New function.
8227 (ppc64_emit_mul): New function.
8228 (ppc64_emit_lsh): New function.
8229 (ppc64_emit_rsh_signed): New function.
8230 (ppc64_emit_rsh_unsigned): New function.
8231 (ppc64_emit_ext): New function.
8232 (ppc64_emit_zero_ext): New function.
8233 (ppc64_emit_log_not): New function.
8234 (ppc64_emit_bit_and): New function.
8235 (ppc64_emit_bit_or): New function.
8236 (ppc64_emit_bit_xor): New function.
8237 (ppc64_emit_bit_not): New function.
8238 (ppc64_emit_equal): New function.
8239 (ppc64_emit_less_signed): New function.
8240 (ppc64_emit_less_unsigned): New function.
8241 (ppc64_emit_ref): New function.
8242 (ppc64_emit_const): New function.
8243 (ppc64v1_emit_reg): New function.
8244 (ppc64v2_emit_reg): New function.
8245 (ppc64_emit_pop): New function.
8246 (ppc64_emit_stack_flush): New function.
8247 (ppc64_emit_swap): New function.
8248 (ppc64v1_emit_call): New function.
8249 (ppc64v2_emit_call): New function.
8250 (ppc64v1_emit_int_call_1): New function.
8251 (ppc64v2_emit_int_call_1): New function.
8252 (ppc64v1_emit_void_call_2): New function.
8253 (ppc64v2_emit_void_call_2): New function.
8254 (ppc64_emit_if_goto): New function.
8255 (ppc64_emit_eq_goto): New function.
8256 (ppc64_emit_ne_goto): New function.
8257 (ppc64_emit_lt_goto): New function.
8258 (ppc64_emit_le_goto): New function.
8259 (ppc64_emit_gt_goto): New function.
8260 (ppc64_emit_ge_goto): New function.
8261 (ppc64v1_emit_ops_impl): New static variable.
8262 (ppc64v2_emit_ops_impl): New static variable.
8263 (ppc_emit_ops): New function.
8264 (linux_low_target): Wire in ppc_emit_ops.
8265
8266 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
8267 Marcin Kościelnicki <koriakin@0x04.net>
8268
8269 PR/17221
8270 * Makefile.in: Add powerpc-*-ipa.o
8271 * configure.srv: Add ipa_obj for powerpc*-linux.
8272 * linux-ppc-ipa.c: New file.
8273 * linux-ppc-low.c: Added linux-ppc-tdesc.h, ax.h, tracepoint.h
8274 includes.
8275 (PPC_FIELD): New macro.
8276 (PPC_SEXT): New macro.
8277 (PPC_OP6): New macro.
8278 (PPC_BO): New macro.
8279 (PPC_LI): New macro.
8280 (PPC_BD): New macro.
8281 (init_registers_*): Move prototype to linux-ppc-tdesc.h.
8282 (tdesc_*): Move declaration to linux-ppc-tdesc.h.
8283 (ppc_get_hwcap): Rename to ppc_get_auxv and add type parameter.
8284 (ppc_get_thread_area): New function.
8285 (is_elfv2_inferior): New function.
8286 (gen_ds_form): New function.
8287 (GEN_STD): New macro.
8288 (GEN_STDU): New macro.
8289 (GEN_LD): New macro.
8290 (GEN_LDU): New macro.
8291 (gen_d_form): New function.
8292 (GEN_ADDI): New macro.
8293 (GEN_ADDIS): New macro.
8294 (GEN_LI): New macro.
8295 (GEN_LIS): New macro.
8296 (GEN_ORI): New macro.
8297 (GEN_ORIS): New macro.
8298 (GEN_LWZ): New macro.
8299 (GEN_STW): New macro.
8300 (GEN_STWU): New macro.
8301 (gen_xfx_form): New function.
8302 (GEN_MFSPR): New macro.
8303 (GEN_MTSPR): New macro.
8304 (GEN_MFCR): New macro.
8305 (GEN_MTCR): New macro.
8306 (GEN_SYNC): New macro.
8307 (GEN_LWSYNC): New macro.
8308 (gen_x_form): New function.
8309 (GEN_OR): New macro.
8310 (GEN_MR): New macro.
8311 (GEN_LWARX): New macro.
8312 (GEN_STWCX): New macro.
8313 (GEN_CMPW): New macro.
8314 (gen_md_form): New function.
8315 (GEN_RLDICL): New macro.
8316 (GEN_RLDICR): New macro.
8317 (gen_i_form): New function.
8318 (GEN_B): New macro.
8319 (GEN_BL): New macro.
8320 (gen_b_form): New function.
8321 (GEN_BNE): New macro.
8322 (GEN_LOAD): New macro.
8323 (GEN_STORE): New macro.
8324 (gen_limm): New function.
8325 (gen_atomic_xchg): New function.
8326 (gen_call): New function.
8327 (ppc_relocate_instruction): New function.
8328 (ppc_install_fast_tracepoint_jump_pad): New function.
8329 (ppc_get_min_fast_tracepoint_insn_len): New function.
8330 (ppc_get_ipa_tdesc_idx): New function.
8331 (the_low_target): Wire in the new functions.
8332 (initialize_low_arch) [!__powerpc64__]: Don'it initialize 64-bit
8333 tdescs.
8334 * linux-ppc-tdesc.h: New file.
8335
8336 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
8337
8338 * linux-aarch64-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
8339 (alloc_jump_pad_buffer): New function.
8340 * linux-amd64-ipa.c: Add <sys/mman.h> include.
8341 (alloc_jump_pad_buffer): New function.
8342 * linux-i386-ipa.c (alloc_jump_pad_buffer): New function.
8343 * linux-s390-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
8344 (alloc_jump_pad_buffer): New function.
8345 * tracepoint.c (getauxval) [!HAVE_GETAUXVAL]: New function.
8346 (initialize_tracepoint): Delegate to alloc_jump_pad_buffer.
8347 * tracepoint.h (alloc_jump_pad_buffer): New prototype.
8348 (getauxval) [!HAVE_GETAUXVAL]: New prototype.
8349
8350 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
8351
8352 * linux-aarch64-ipa.c: Rename gdb_agent_get_raw_reg to get_raw_reg.
8353 * linux-amd64-ipa.c: Likewise.
8354 * linux-i386-ipa.c: Likewise.
8355 * linux-s390-ipa.c: Likewise.
8356 * tracepoint.c: IPA-export gdb_collect_ptr instead of gdb_collect,
8357 ditto for get_raw_reg_ptr, get_trace_state_variable_value_ptr,
8358 set_trace_state_variable_value_ptr.
8359 (struct ipa_sym_addresses): Likewise.
8360 (symbol_list): Likewise.
8361 (install_fast_tracepoint): Dereference gdb_collect_ptr instead of
8362 accessing gdb_collect directly.
8363 (gdb_collect_ptr_type): New typedef.
8364 (get_raw_reg_ptr_type): New typedef.
8365 (get_trace_state_variable_value_ptr_type): New typedef.
8366 (set_trace_state_variable_value_ptr_type): New typedef.
8367 (gdb_collect_ptr): New global.
8368 (get_raw_reg_ptr): New global.
8369 (get_trace_state_variable_value_ptr): New global.
8370 (set_trace_state_variable_value_ptr): New global.
8371 (get_raw_reg_func_addr): Dereference get_raw_reg_ptr instead of
8372 accessing get_raw_reg directly.
8373 (get_get_tsv_func_addr): Likewise for
8374 get_trace_state_variable_value_ptr.
8375 (get_set_tsv_func_addr): Likewise for
8376 set_trace_state_variable_value_ptr.
8377 * tracepoint.h: Rename gdb_agent_get_raw_reg to get_raw_reg.
8378
8379 2016-03-30 Simon Marchi <simon.marchi@ericsson.com>
8380
8381 * tracepoint.c (cmd_qtenable_disable): Remove whitespace.
8382
8383 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
8384
8385 * remote-utils.c (look_up_one_symbol): Remove own_buf, handle 'v'
8386 packets.
8387 (relocate_instruction): Remove own_buf.
8388 * server.c (own_buf): Make global.
8389 (handle_v_requests): Make global.
8390 * server.h (own_buf): New declaration.
8391 (handle_v_requests): New prototype.
8392
8393 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
8394
8395 PR 18377
8396 * linux-s390-low.c (add_insns): New function.
8397 (s390_emit_prologue): New function.
8398 (s390_emit_epilogue): New function.
8399 (s390_emit_add): New function.
8400 (s390_emit_sub): New function.
8401 (s390_emit_mul): New function.
8402 (s390_emit_lsh): New function.
8403 (s390_emit_rsh_signed): New function.
8404 (s390_emit_rsh_unsigned): New function.
8405 (s390_emit_ext): New function.
8406 (s390_emit_log_not): New function.
8407 (s390_emit_bit_and): New function.
8408 (s390_emit_bit_or): New function.
8409 (s390_emit_bit_xor): New function.
8410 (s390_emit_bit_not): New function.
8411 (s390_emit_equal): New function.
8412 (s390_emit_less_signed): New function.
8413 (s390_emit_less_unsigned): New function.
8414 (s390_emit_ref): New function.
8415 (s390_emit_if_goto): New function.
8416 (s390_emit_goto): New function.
8417 (s390_write_goto_address): New function.
8418 (s390_emit_litpool): New function.
8419 (s390_emit_const): New function.
8420 (s390_emit_call): New function.
8421 (s390_emit_reg): New function.
8422 (s390_emit_pop): New function.
8423 (s390_emit_stack_flush): New function.
8424 (s390_emit_zero_ext): New function.
8425 (s390_emit_swap): New function.
8426 (s390_emit_stack_adjust): New function.
8427 (s390_emit_set_r2): New function.
8428 (s390_emit_int_call_1): New function.
8429 (s390_emit_void_call_2): New function.
8430 (s390_emit_eq_goto): New function.
8431 (s390_emit_ne_goto): New function.
8432 (s390_emit_lt_goto): New function.
8433 (s390_emit_le_goto): New function.
8434 (s390_emit_gt_goto): New function.
8435 (s390_emit_ge_goto): New function.
8436 (s390x_emit_prologue): New function.
8437 (s390x_emit_epilogue): New function.
8438 (s390x_emit_add): New function.
8439 (s390x_emit_sub): New function.
8440 (s390x_emit_mul): New function.
8441 (s390x_emit_lsh): New function.
8442 (s390x_emit_rsh_signed): New function.
8443 (s390x_emit_rsh_unsigned): New function.
8444 (s390x_emit_ext): New function.
8445 (s390x_emit_log_not): New function.
8446 (s390x_emit_bit_and): New function.
8447 (s390x_emit_bit_or): New function.
8448 (s390x_emit_bit_xor): New function.
8449 (s390x_emit_bit_not): New function.
8450 (s390x_emit_equal): New function.
8451 (s390x_emit_less_signed): New function.
8452 (s390x_emit_less_unsigned): New function.
8453 (s390x_emit_ref): New function.
8454 (s390x_emit_if_goto): New function.
8455 (s390x_emit_const): New function.
8456 (s390x_emit_call): New function.
8457 (s390x_emit_reg): New function.
8458 (s390x_emit_pop): New function.
8459 (s390x_emit_stack_flush): New function.
8460 (s390x_emit_zero_ext): New function.
8461 (s390x_emit_swap): New function.
8462 (s390x_emit_stack_adjust): New function.
8463 (s390x_emit_int_call_1): New function.
8464 (s390x_emit_void_call_2): New function.
8465 (s390x_emit_eq_goto): New function.
8466 (s390x_emit_ne_goto): New function.
8467 (s390x_emit_lt_goto): New function.
8468 (s390x_emit_le_goto): New function.
8469 (s390x_emit_gt_goto): New function.
8470 (s390x_emit_ge_goto): New function.
8471 (s390_emit_ops): New function.
8472 (struct linux_target_ops): Fill in emit_ops hook.
8473
8474 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
8475
8476 PR 18377
8477 * Makefile.in: Add s390 IPA files.
8478 * configure.srv: Build IPA for s390.
8479 * linux-s390-ipa.c: New file.
8480 * linux-s390-low.c: New includes - inttypes.h and linux-s390-tdesc.h.
8481 (init_registers_s390_linux32): Move declaration to linux-s390-tdesc.h.
8482 (tdesc_s390_linux32): Likewise.
8483 (init_registers_s390_linux32v1): Likewise.
8484 (tdesc_s390_linux32v1): Likewise.
8485 (init_registers_s390_linux32v2): Likewise.
8486 (tdesc_s390_linux32v2): Likewise.
8487 (init_registers_s390_linux64): Likewise.
8488 (tdesc_s390_linux64): Likewise.
8489 (init_registers_s390_linux64v1): Likewise.
8490 (tdesc_s390_linux64v1): Likewise.
8491 (init_registers_s390_linux64v2): Likewise.
8492 (tdesc_s390_linux64v2): Likewise.
8493 (init_registers_s390_te_linux64): Likewise.
8494 (tdesc_s390_te_linux64): Likewise.
8495 (init_registers_s390_vx_linux64): Likewise.
8496 (tdesc_s390_vx_linux64): Likewise.
8497 (init_registers_s390_tevx_linux64): Likewise.
8498 (tdesc_s390_tevx_linux64): Likewise.
8499 (init_registers_s390x_linux64): Likewise.
8500 (tdesc_s390x_linux64): Likewise.
8501 (init_registers_s390x_linux64v1): Likewise.
8502 (tdesc_s390x_linux64v1): Likewise.
8503 (init_registers_s390x_linux64v2): Likewise.
8504 (tdesc_s390x_linux64v2): Likewise.
8505 (init_registers_s390x_te_linux64): Likewise.
8506 (tdesc_s390x_te_linux64): Likewise.
8507 (init_registers_s390x_vx_linux64): Likewise.
8508 (tdesc_s390x_vx_linux64): Likewise.
8509 (init_registers_s390x_tevx_linux64): Likewise.
8510 (tdesc_s390x_tevx_linux64): Likewise.
8511 (have_hwcap_s390_vx): New static variable.
8512 (s390_arch_setup): Fill have_hwcap_s390_vx.
8513 (s390_get_thread_area): New function.
8514 (s390_ft_entry_gpr_esa): New const.
8515 (s390_ft_entry_gpr_zarch): New const.
8516 (s390_ft_entry_misc): New const.
8517 (s390_ft_entry_fr): New const.
8518 (s390_ft_entry_vr): New const.
8519 (s390_ft_main_31): New const.
8520 (s390_ft_main_64): New const.
8521 (s390_ft_exit_fr): New const.
8522 (s390_ft_exit_vr): New const.
8523 (s390_ft_exit_misc): New const.
8524 (s390_ft_exit_gpr_esa): New const.
8525 (s390_ft_exit_gpr_zarch): New const.
8526 (append_insns): New function.
8527 (s390_relocate_instruction): New function.
8528 (s390_install_fast_tracepoint_jump_pad): New function.
8529 (s390_get_min_fast_tracepoint_insn_len): New function.
8530 (s390_get_ipa_tdesc_idx): New function.
8531 (struct linux_target_ops): Wire in the above functions.
8532 (initialize_low_arch) [!__s390x__]: Don't initialize s390x tdescs.
8533 * linux-s390-tdesc.h: New file.
8534
8535 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
8536
8537 * linux-s390-low.c (s390_supports_tracepoints): New function.
8538 (struct linux_target_ops): Fill supports_tracepoints hook.
8539
8540 2016-03-18 Yao Qi <yao.qi@linaro.org>
8541
8542 * linux-low.c (lwp_signal_can_be_delivered): New function.
8543 (linux_resume_one_lwp_throw): Use lwp_signal_can_be_delivered.
8544
8545 2016-03-18 Yao Qi <yao.qi@linaro.org>
8546
8547 * linux-low.c (linux_resume_one_lwp_throw): Set 'signal' to
8548 0 if signal is enqueued. Remove 'signal' from one debugging
8549 message. Move one debugging message to some lines below.
8550 Remove code setting 'signal' to 0.
8551
8552 2016-03-18 Yao Qi <yao.qi@linaro.org>
8553
8554 * linux-low.c (linux_low_filter_event): Remove redundant
8555 WIFSTOPPED check together with linux_wstatus_maybe_breakpoint.
8556
8557 2016-03-09 Marcin Kościelnicki <koriakin@0x04.net>
8558
8559 * linux-ppc-low.c (ppc_supports_tracepoints): New function.
8560 (struct linux_target_ops): Wire in the above.
8561
8562 2016-03-03 Yao Qi <yao.qi@linaro.org>
8563
8564 * linux-low.c: Update comments to start_step_over.
8565
8566 2016-03-03 Yao Qi <yao.qi@linaro.org>
8567
8568 PR server/19736
8569 * linux-low.c (handle_extended_wait): Set child suspended
8570 if event_lwp->bp_reinsert isn't zero.
8571
8572 2016-03-02 Yao Qi <yao.qi@linaro.org>
8573
8574 * linux-low.c (linux_resume_one_lwp_throw): Replace code with
8575 enqueue_pending_signal.
8576
8577 2016-03-02 Marcin Kościelnicki <koriakin@0x04.net>
8578
8579 * tracepoint.c (cmd_qtstart): Only set ipa_tdesc_idx if agent
8580 is actually loaded.
8581
8582 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
8583
8584 * linux-s390-low.c (s390_num_regs_3264): Define on 31-bit too.
8585 (s390_regmap_3264) [!__s390x__]: New global.
8586 (s390_collect_ptrace_register): Skip map entries containing -1.
8587 (s390_supply_ptrace_register): Ditto.
8588 (s390_fill_gprs_high): New function.
8589 (s390_store_gprs_high): New function.
8590 (s390_regsets): Add NT_S390_HIGH_GPRS.
8591 (s390_get_hwcap): Enable on 31-bit.
8592 (have_hwcap_s390_high_gprs): Enable on 31-bit.
8593 (s390_arch_setup): Enable detection of high GPRs, TDB, VX on 31-bit.
8594 Detect NT_S390_HIGH_GPRS.
8595 (s390_usrregs_info_3264): Enable on 31-bit.
8596 (s390_regs_info): Enable regs_info_3264 on 31-bit.
8597 (initialize_low_arch): Initialize s390_regsets_info_3264 on 31-bit.
8598
8599 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
8600
8601 PR gdb/13808
8602 * Makefile.in: Add i386-*-linux-ipa.o and amd64-*-linux-ipa.o.
8603 * configure.srv: Ditto.
8604 * linux-aarch64-ipa.c (get_ipa_tdesc): New function.
8605 (initialize_low_tracepoint): Remove ipa_tdesc assignment.
8606 * linux-amd64-ipa.c: Add "linux-x86-tdesc.h" include.
8607 (init_registers_amd64_linux): Remove prototype.
8608 (tdesc_amd64_linux): Remove declaration.
8609 (get_ipa_tdesc): New function.
8610 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
8611 initialize remaining tdescs.
8612 * linux-i386-ipa.c: Add "linux-x86-tdesc.h" include.
8613 (init_registers_i386_linux): Remove prototype.
8614 (tdesc_i386_linux): Remove declaration.
8615 (get_ipa_tdesc): New function.
8616 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
8617 initialize remaining tdescs.
8618 * linux-low.c (linux_get_ipa_tdesc_idx): New function.
8619 (linux_target_ops): wire in linux_get_ipa_tdesc_idx.
8620 * linux-low.h (struct linux_target_ops): Add get_ipa_tdesc_idx.
8621 * linux-x86-low.c: Move tdesc declarations to linux-x86-tdesc.h.
8622 (x86_get_ipa_tdesc_idx): New function.
8623 (the_low_target): Wire in x86_get_ipa_tdesc_idx.
8624 * linux-x86-tdesc.h: New file.
8625 * target.h (struct target_ops): Add get_ipa_tdesc_idx.
8626 (target_get_ipa_tdesc_idx): New macro.
8627 * tracepoint.c (ipa_tdesc_idx): New macro.
8628 (struct ipa_sym_addresses): Add addr_ipa_tdesc_idx.
8629 (symbol_list): Add ipa_tdesc_idx.
8630 (cmd_qtstart): Write ipa_tdesc_idx in the target.
8631 (ipa_tdesc): Remove.
8632 (ipa_tdesc_idx): New variable.
8633 (get_context_regcache): Use get_ipa_tdesc.
8634 (gdb_collect): Ditto.
8635 (gdb_probe): Ditto.
8636 * tracepoint.h (get_ipa_tdesc): New prototype.
8637 (ipa_tdesc): Remove.
8638
8639 2016-02-24 Pedro Alves <palves@redhat.com>
8640
8641 * linux-low.c (check_stopped_by_breakpoint): Rename to ...
8642 (save_stop_reason): ... this. Use GDB_ARCH_IS_TRAP_HWBKPT and
8643 handle ambiguous GDB_ARCH_IS_TRAP_BRKPT / GDB_ARCH_IS_TRAP_HWBKPT.
8644 Factor out common code between the USE_SIGTRAP_SIGINFO and
8645 !USE_SIGTRAP_SIGINFO blocks.
8646 (linux_low_filter_event): Call save_stop_reason instead of
8647 check_stopped_by_breakpoint and check_stopped_by_watchpoint.
8648 Update comments.
8649 (linux_wait_1): Update comments.
8650
8651 2016-02-24 Wei-cheng Wang <cole945@gmail.com>
8652
8653 * linux-ppc-low.c (ppc_supports_z_point_type): New function:
8654 (ppc_insert_point, ppc_remove_point): Insert/remove z-packet breakpoints.
8655 (ppc64_emit_ops_vector): Add target ops - ppc_supports_z_point_type,
8656 ppc_insert_point, ppc_remove_point.
8657
8658 2016-02-17 Marcin Kościelnicki <koriakin@0x04.net>
8659
8660 * linux-s390-low.c (s390_supports_z_point_type): New function.
8661 (struct linux_target_ops): Wire s390_supports_z_point_type in.
8662
8663 2016-02-16 Yao Qi <yao.qi@linaro.org>
8664
8665 * linux-arm-low.c (get_next_pcs_syscall_next_pc): Remove argument
8666 PC. Get pc from regcache_read_pc.
8667
8668 2016-02-12 Yao Qi <yao.qi@linaro.org>
8669
8670 * linux-aarch64-low.c (aarch64_get_pc): Call linux_get_pc_64bit
8671 or linux_get_pc_32bit.
8672 (aarch64_set_pc): Call linux_set_pc_64bit or linux_set_pc_32bit.
8673
8674 2016-02-12 Yao Qi <yao.qi@linaro.org>
8675
8676 * linux-arm-low.c (get_next_pcs_ops): Initialize it with
8677 arm_linux_get_next_pcs_fixup.
8678
8679 2016-02-12 Marcin Kościelnicki <koriakin@0x04.net>
8680
8681 * tracepoint.c (x_tracepoint_action_download): Change
8682 write_inferior_data_ptr to write_inferior_data_pointer.
8683 (cmd_qtstart): Likewise.
8684 (write_inferior_data_ptr): Remove.
8685 (download_agent_expr): Change write_inferior_data_ptr to
8686 write_inferior_data_pointer.
8687 (download_tracepoint_1): Likewise.
8688 (download_tracepoint): Likewise.
8689 (download_trace_state_variables): Likewise.
8690
8691 2016-02-11 Wei-cheng Wang <cole945@gmail.com>
8692 Marcin Kościelnicki <koriakin@0x04.net>
8693
8694 * tracepoint.c (struct tracepoint_action_ops): Remove.
8695 (struct tracepoint_action): Remove ops.
8696 (m_tracepoint_action_download, r_tracepoint_action_download)
8697 (x_tracepoint_action_download, l_tracepoint_action_download): Adjust
8698 size and offset accordingly.
8699 (m_tracepoint_action_ops, r_tracepoint_action_ops)
8700 (x_tracepoint_action_ops, l_tracepoint_action_ops): Remove.
8701 (tracepoint_action_send, tracepoint_action_download): New functions.
8702 Helpers for trace action handlers.
8703 (add_tracepoint_action): Remove setup actions ops.
8704 (download_tracepoint_1, tracepoint_send_agent): Call helper functions.
8705
8706 2016-02-10 Yao Qi <yao.qi@linaro.org>
8707
8708 * regcache.c (regcache_raw_read_unsigned): Clear *VAL.
8709
8710 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
8711
8712 * configure.ac: Use AC_CONFIG_FILES instead of passing arguments
8713 to AC_OUTPUT.
8714 * configure: Regenerate.
8715
8716 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
8717
8718 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): Change
8719 void * to gdb_byte *.
8720 * linux-low.c (siginfo_fixup): Likewise.
8721 (linux_xfer_siginfo): Likewise.
8722 * linux-low.h (struct linux_target_ops) <siginfo_fixup>:
8723 Likewise.
8724 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
8725
8726 2016-02-02 Walfred Tedeschi <walfred.tedeschi@intel.com>
8727
8728 * configure.srv (x86_64-*-linux*): Add amd64-linux-siginfo.o
8729 to srv_tgtobj.
8730 (i[34567]86-*-linux*): Add amd64-linux-siginfo.o
8731 to srv_tgtobj.
8732 * linux-x86-low.c [__x86_64__]: Include
8733 "nat/amd64-linux-siginfo.h".
8734 (compat_siginfo_from_siginfo, siginfo_from_compat_siginfo)
8735 (compat_x32_siginfo_from_siginfo, siginfo_from_compat_x32_siginfo)
8736 (compat_timeval, compat_sigval, compat_x32_clock, cpt_si_pid)
8737 (cpt_si_uid, cpt_si_timerid, cpt_si_overrun, cpt_si_status)
8738 (cpt_si_utime, cpt_si_stime, cpt_si_ptr, cpt_si_addr, cpt_si_band)
8739 (cpt_si_fd, si_timerid, si_overrun): Move from
8740 nat/amd64-linux-siginfo.c.
8741 * Makefile.in (amd64-linux-siginfo.o:): New rule.
8742
8743 2016-01-28 Simon Marchi <simon.marchi@ericsson.com>
8744
8745 * server.c (skip_to_semicolon): Remove.
8746 (process_point_options): Use strchrnul instead of
8747 skip_to_semicolon.
8748
8749 2016-01-26 Yao Qi <yao.qi@linaro.org>
8750
8751 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Remove argument pc.
8752 * linux-low.c (install_software_single_step_breakpoints): Don't
8753 call regcache_read_pc.
8754 * linux-low.h (struct linux_target_ops) <get_next_pcs>: Remove
8755 argument pc.
8756
8757 2016-01-26 Yao Qi <yao.qi@linaro.org>
8758
8759 * linux-low.c (install_software_single_step_breakpoints): Call
8760 regcache_read_pc instead of get_pc.
8761
8762 2016-01-26 Yao Qi <yao.qi@linaro.org>
8763
8764 * remote-utils.c (remote_close) [!USE_WIN32API]: Ignore SIGIO.
8765 (unblock_async_io): Rename to ...
8766 (block_unblock_async_io): ... it. New function.
8767 (enable_async_io): Don't install SIGIO handler. Unblock it
8768 instead.
8769 (disable_async_io): Don't ignore SIGIO. Block it instead.
8770 (initialize_async_io): Install SIGIO handler. Don't call
8771 unblock_async_io.
8772
8773 2016-01-26 Yao Qi <yao.qi@linaro.org>
8774
8775 * remote-utils.c (getpkt): If the buffer isn't empty, and the
8776 first character is '\003', call *the_target->request_interrupt.
8777
8778 2016-01-25 Yao Qi <yao.qi@linaro.org>
8779
8780 * remote-utils.c (new_thread_notify): Remove.
8781 (dead_thread_notify): Likewise.
8782 * remote-utils.h (new_thread_notify): Remove declaration.
8783 (dead_thread_notify): Likewise.
8784
8785 2016-01-23 Marcin Kościelnicki <koriakin@0x04.net>
8786
8787 * gdb.trace/pending.exp: Fix expected message on continue.
8788
8789 2016-01-22 Marcin Kościelnicki <koriakin@0x04.net>
8790
8791 * tracepoint.c (write_inferior_data_ptr): Cast to uintptr_t, so that
8792 it works properly on big-endian machines where sizeof (CORE_ADDR)
8793 != sizeof (void *).
8794
8795 2016-01-21 Pedro Alves <palves@redhat.com>
8796
8797 * Makefile.in (COMPILER_CFLAGS, CXXFLAGS): New.
8798 (INTERNAL_CFLAGS_BASE): Use COMPILER_CFLAGS instead of CFLAGS.
8799 * configure: Regenerate.
8800
8801 2016-01-21 Yao Qi <yao.qi@linaro.org>
8802
8803 * linux-arm-low.c (arm_sigreturn_next_pc): Add parameter
8804 is_thumb and set it according to CPSR saved on the stack.
8805 (get_next_pcs_syscall_next_pc): Pass is_thumb to
8806 arm_sigreturn_next_pc.
8807
8808 2016-01-18 Yao Qi <yao.qi@linaro.org>
8809
8810 * linux-low.c (linux_set_pc_64bit): New function.
8811 (linux_get_pc_64bit): New function.
8812 * linux-low.h (linux_set_pc_64bit, linux_get_pc_64bit):
8813 Declare.
8814 * linux-sparc-low.c (debug_threads): Remove declaration.
8815 (sparc_get_pc): Remove.
8816 (the_low_target): Use linux_get_pc_64bit instead of
8817 sparc_get_pc.
8818 * linux-tile-low.c (tile_get_pc, tile_set_pc): Remove.
8819 (the_low_target): Use linux_get_pc_64bit and
8820 linux_set_pc_64bit.
8821
8822 2016-01-18 Yao Qi <yao.qi@linaro.org>
8823
8824 * linux-arm-low.c (debug_threads): Remove declaration.
8825 (arm_get_pc, arm_set_pc): Remove.
8826 (the_low_target): Use linux_get_pc_32bit and
8827 linux_set_pc_32bit.
8828 * linux-bfin-low.c (bfin_get_pc, bfin_set_pc): Remove.
8829 (the_low_target): Use linux_get_pc_32bit and
8830 linux_set_pc_32bit.
8831 * linux-cris-low.c (debug_threads): Remove declaration.
8832 (cris_get_pc, cris_set_pc,): Remove.
8833 (the_low_target): Use linux_get_pc_32bit and
8834 linux_set_pc_32bit.
8835 * linux-crisv32-low.c (debug_threads): Remove declaration.
8836 (cris_get_pc, cris_set_pc): Remove.
8837 (the_low_target): Use linux_get_pc_32bit and
8838 linux_set_pc_32bit.
8839 * linux-low.c: Include inttypes.h.
8840 (linux_get_pc_32bit, linux_set_pc_32bit): New functions.
8841 * linux-low.h (linux_get_pc_32bit, linux_set_pc_32bit): Declare.
8842 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Remove.
8843 (the_low_target): Use linux_get_pc_32bit and
8844 linux_set_pc_32bit.
8845 * linux-m68k-low.c (m68k_get_pc, m68k_set_pc): Remove.
8846 (the_low_target): Use linux_get_pc_32bit and
8847 linux_set_pc_32bit.
8848 * linux-nios2-low.c (nios2_get_pc, nios2_set_pc): Remove.
8849 (the_low_target): Use linux_get_pc_32bit and
8850 linux_set_pc_32bit.
8851 * linux-sh-low.c (sh_get_pc, sh_set_pc): Remove.
8852 (the_low_target): Use linux_get_pc_32bit and
8853 linux_set_pc_32bit.
8854 * linux-xtensa-low.c (xtensa_get_pc, xtensa_set_pc): Remove.
8855 (the_low_target): Use linux_get_pc_32bit and
8856 linux_set_pc_32bit.
8857
8858 2016-01-18 Gary Benson <gbenson@redhat.com>
8859
8860 * configure.ac (AC_FUNC_FORK): New check.
8861 * config.in: Regenerate.
8862 * configure: Likewise.
8863
8864 2016-01-14 Yao Qi <yao.qi@linaro.org>
8865
8866 * linux-aarch32-low.c (thumb2_breakpoint): Make it static.
8867 * linux-aarch32-low.h (thumb2_breakpoint): Remove declaration.
8868 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Pass 1 to
8869 arm_get_next_pcs_ctor.
8870
8871 2016-01-12 Josh Stone <jistone@redhat.com>
8872 Philippe Waroquiers <philippe.waroquiers@skynet.be>
8873
8874 * inferiors.h: Include "gdb_vecs.h".
8875 (struct process_info): Add syscalls_to_catch.
8876 * inferiors.c (remove_process): Free syscalls_to_catch.
8877 * remote-utils.c (prepare_resume_reply): Report syscall_entry and
8878 syscall_return stops.
8879 * server.h (UNKNOWN_SYSCALL, ANY_SYSCALL): Define.
8880 * server.c (handle_general_set): Handle QCatchSyscalls.
8881 (handle_query): Report support for QCatchSyscalls.
8882 * target.h (struct target_ops): Add supports_catch_syscall.
8883 (target_supports_catch_syscall): New macro.
8884 * linux-low.h (struct linux_target_ops): Add get_syscall_trapinfo.
8885 (struct lwp_info): Add syscall_state.
8886 * linux-low.c (handle_extended_wait): Mark syscall_state as an entry.
8887 Maintain syscall_state and syscalls_to_catch across exec.
8888 (get_syscall_trapinfo): New function, proxy to the_low_target.
8889 (linux_low_ptrace_options): Enable PTRACE_O_TRACESYSGOOD.
8890 (linux_low_filter_event): Toggle syscall_state entry/return for
8891 syscall traps, and set it ignored for all others.
8892 (gdb_catching_syscalls_p): New function.
8893 (gdb_catch_this_syscall_p): New function.
8894 (linux_wait_1): Handle SYSCALL_SIGTRAP.
8895 (linux_resume_one_lwp_throw): Add PTRACE_SYSCALL possibility.
8896 (linux_supports_catch_syscall): New function.
8897 (linux_target_ops): Install it.
8898 * linux-x86-low.c (x86_get_syscall_trapinfo): New function.
8899 (the_low_target): Install it.
8900
8901 2016-01-12 Mike Frysinger <vapier@gentoo.org>
8902
8903 * acinclude.m4: Include new ../warning.m4 file.
8904 * configure: Regenerated.
8905 * configure.ac: Replace all warning logic with AM_GDB_WARNINGS.
8906
8907 2016-01-12 Mike Frysinger <vapier@gentoo.org>
8908
8909 * ax.c (is_goto_target): Mark static.
8910 * linux-low.c (register_addr): Likewise.
8911 (linux_fetch_registers, linux_store_registers): Likewise.
8912 * mem-break.c (any_persistent_commands): Fix old prototype.
8913 (add_commands_to_breakpoint): Mark static.
8914 * regcache.c (find_register_by_name): Delete unused func.
8915 * remote-utils.c (hex_or_minus_one): Mark static.
8916 * server.c (monitor_show_help): Mark static.
8917 (handle_query, handle_v_cont, handle_v_attach, handle_v_kill,
8918 handle_v_requests): Likewise.
8919
8920 2016-01-12 Pedro Alves <palves@redhat.com>
8921
8922 Remove use of the registered trademark symbol throughout.
8923
8924 2016-01-08 Yao Qi <yao.qi@linaro.org>
8925
8926 * remote-utils.c (getpkt): If c is '\003', call target hook
8927 request_interrupt.
8928
8929 2016-01-06 Yao Qi <yao.qi@linaro.org>
8930
8931 * linux-aarch32-low.h (arm_abi_breakpoint): Move to
8932 linux-aarch32-low.c.
8933 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
8934 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
8935 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
8936 (thumb2_breakpoint): Declare.
8937 * linux-aarch32-low.c (arm_abi_breakpoint): Moved from
8938 linux-aarch32-low.h.
8939 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
8940 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
8941 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
8942
8943 2016-01-01 Joel Brobecker <brobecker@adacore.com>
8944
8945 * gdbreplay.c (gdbreplay_version): Change copyright year in
8946 version message.
8947 * server.c (gdbserver_version): Likewise.
8948
8949 2015-12-28 Patrick Palka <patrick@parcs.ath.cx>
8950
8951 * server.c (crc32_table): Delete.
8952 (crc32): Use libiberty's xcrc32 function.
8953
8954 2015-12-22 Joel Brobecker <brobecker@adacore.com>
8955
8956 * lynx-low.c (lynx_delete_thread_callback): New function.
8957 (lynx_mourn): Properly delete our process and all of its
8958 threads. Remove call to clear_inferiors.
8959
8960 2015-12-22 Joel Brobecker <brobecker@adacore.com>
8961
8962 * target.c (thread_search_callback): Add check that
8963 the thread_stopped target callback is not NULL before
8964 calling it.
8965
8966 2015-12-21 Yao Qi <yao.qi@linaro.org>
8967
8968 * linux-aarch32-low.h [__aarch64__]: Use arm_abi_breakpoint
8969 arm breakpoint.
8970
8971 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
8972
8973 * server.c (handle_query): Call target_supports_software_single_step.
8974
8975 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
8976
8977 * linux-low.c (single_step): New function.
8978 (linux_resume_one_lwp_throw): Call single_step.
8979 (start_step_over): Likewise.
8980
8981 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
8982
8983 * Makefile.in (SFILES): Append arch/arm-linux.c,
8984 arch/arm-get-next-pcs.c.
8985 (arm-linux.o): New rule.
8986 (arm-get-next-pcs.o): New rule.
8987 * configure.srv (arm*-*-linux*): Add arm-get-next-pcs.o,
8988 arm-linux.o.
8989 * linux-aarch32-low.c (arm_abi_breakpoint): Remove macro. Moved
8990 to linux-aarch32-low.c.
8991 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
8992 (arm_breakpoint_len, thumb_breakpoint): Likewise.
8993 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
8994 (thumb2_breakpoint_len): Likewise.
8995 (arm_is_thumb_mode): Make non-static.
8996 * linux-aarch32-low.h (arm_abi_breakpoint): New macro. Moved
8997 from linux-aarch32-low.c.
8998 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
8999 (arm_breakpoint_len, thumb_breakpoint): Likewise.
9000 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
9001 (thumb2_breakpoint_len): Likewise.
9002 (arm_is_thumb_mode): New declaration.
9003 * linux-arm-low.c: Include arch/arm-linux.h
9004 aarch/arm-get-next-pcs.h, sys/syscall.h.
9005 (get_next_pcs_ops): New struct.
9006 (get_next_pcs_addr_bits_remove): New function.
9007 (get_next_pcs_is_thumb): New function.
9008 (get_next_pcs_read_memory_unsigned_integer): Likewise.
9009 (arm_sigreturn_next_pc): Likewise.
9010 (get_next_pcs_syscall_next_pc): Likewise.
9011 (arm_gdbserver_get_next_pcs): Likewise.
9012 (struct linux_target_ops) <arm_gdbserver_get_next_pcs>:
9013 Initialize.
9014 * linux-low.h: Move CORE_ADDR vector definition to gdb_vecs.h.
9015 * server.h: Include gdb_vecs.h.
9016
9017 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
9018
9019 * Makefile.in (SFILES): Append common/common-regcache.c.
9020 (OBS): Append common-regcache.o.
9021 (common-regcache.o): New rule.
9022 * regcache.c (init_register_cache): Initialize cache to
9023 REG_UNAVAILABLE.
9024 (regcache_raw_read_unsigned): New function.
9025 * regcache.h (REG_UNAVAILABLE, REG_VALID): Replaced by shared
9026 register_status enum.
9027
9028 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
9029
9030 * linux-aarch64-low.c (the_low_targets): Rename
9031 breakpoint_reinsert_addr to get_next_pcs.
9032 * linux-arm-low.c (the_low_targets): Likewise.
9033 * linux-bfin-low.c (the_low_targets): Likewise.
9034 * linux-cris-low.c (the_low_targets): Likewise.
9035 * linux-crisv32-low.c (the_low_targets): Likewise.
9036 * linux-low.c (can_software_single_step): Likewise.
9037 (install_software_single_step_breakpoints): New function.
9038 (start_step_over): Use install_software_single_step_breakpoints.
9039 * linux-low.h: New CORE_ADDR vector.
9040 (struct linux_target_ops) Rename breakpoint_reinsert_addr to
9041 get_next_pcs.
9042 * linux-mips-low.c (the_low_targets): Likewise.
9043 * linux-nios2-low.c (the_low_targets): Likewise.
9044 * linux-sparc-low.c (the_low_targets): Likewise.
9045
9046 2015-12-17 Pedro Alves <palves@redhat.com>
9047
9048 * linux-low.c (linux_kill_one_lwp): Remove references to
9049 LinuxThreads.
9050 (kill_lwp): Remove HAVE_TKILL_SYSCALL check. No longer fall back
9051 to 'kill'.
9052 (linux_init_signals): Delete.
9053 (initialize_low): Adjust.
9054 * thread-db.c (thread_db_init): Remove LinuxThreads reference.
9055
9056 2015-12-16 Pedro Alves <palves@redhat.com>
9057
9058 * configure.ac (compiler warning flags): When testing a
9059 -Wno-foo option, check whether -Wfoo works instead.
9060 * configure: Regenerate.
9061
9062 2015-12-11 Don Breazeal <donb@codesourcery.com>
9063
9064 * server.c (process_serial_event): Don't exit from gdbserver
9065 in remote mode if there are still active inferiors.
9066
9067 2015-12-11 Yao Qi <yao.qi@linaro.org>
9068
9069 * linux-aarch64-low.c (aarch64_breakpoint_at): Call
9070 arm_breakpoint_at if the process is 32-bit.
9071
9072 2015-12-11 Yao Qi <yao.qi@linaro.org>
9073
9074 * linux-aarch32-low.c [__aarch64__]: Use arm_abi_breakpoint
9075 arm breakpoint.
9076
9077 2015-12-07 Yao Qi <yao.qi@linaro.org>
9078
9079 * configure.srv: Append arm.o to srv_tgtobj for
9080 aarch64*-*-linux* target.
9081 * linux-aarch32-low.c (arm_abi_breakpoint): New macro. Moved
9082 from linux-arm-low.c.
9083 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
9084 (arm_breakpoint_len, thumb_breakpoint): Likewise.
9085 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
9086 (thumb2_breakpoint_len): Likewise.
9087 (arm_is_thumb_mode, arm_breakpoint_at): Likewise.
9088 (arm_breakpoint_kinds): Likewise.
9089 (arm_breakpoint_kind_from_pc): Likewise.
9090 (arm_sw_breakpoint_from_kind): Likewise.
9091 (arm_breakpoint_kind_from_current_state): Likewise.
9092 * linux-aarch32-low.h (arm_breakpoint_kind_from_pc): Declare.
9093 (arm_sw_breakpoint_from_kind): Declare.
9094 (arm_breakpoint_kind_from_current_state): Declare.
9095 (arm_breakpoint_at): Declare.
9096 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): Call
9097 arm_sw_breakpoint_from_kind if process is 32-bit.
9098 (aarch64_breakpoint_kind_from_pc): New function.
9099 (aarch64_breakpoint_kind_from_current_state): New function.
9100 (the_low_target): Initialize fields breakpoint_kind_from_pc
9101 and breakpoint_kind_from_current_state.
9102 * linux-arm-low.c (arm_breakpoint_kinds): Move to
9103 linux-aarch32-low.c.
9104 (arm_abi_breakpoint, arm_eabi_breakpoint): Likewise.
9105 (arm_breakpoint, arm_breakpoint_len): Likewise.
9106 (thumb_breakpoint, thumb_breakpoint_len): Likewise.
9107 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
9108 (arm_is_thumb_mode): Likewise.
9109 (arm_breakpoint_at): Likewise.
9110 (arm_breakpoint_kind_from_pc): Likewise.
9111 (arm_sw_breakpoint_from_kind): Likewise.
9112 (arm_breakpoint_kind_from_current_state): Likewise.
9113
9114 Revert:
9115 2015-08-04 Yao Qi <yao.qi@linaro.org>
9116
9117 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
9118 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
9119 * server.c (extended_protocol): Remove "static".
9120 * server.h (extended_protocol): Declare it.
9121
9122 2015-12-04 Josh Stone <jistone@redhat.com>
9123
9124 * target.h (struct target_ops) <arch_setup>: Rename to ...
9125 (struct target_ops) <post_create_inferior>: ... this.
9126 (target_arch_setup): Rename to ...
9127 (target_post_create_inferior): ... this, calling post_create_inferior.
9128 * server.c (start_inferior): Update target_arch_setup calls to
9129 target_post_create_inferior.
9130 * linux-low.c (linux_low_ptrace_options): Forward declare.
9131 (linux_arch_setup): Update its comment for general use.
9132 (linux_post_create_inferior): New, run arch_setup and setup ptrace.
9133 (struct linux_target_ops): Use linux_post_create_inferior.
9134 * lynx-low.c (struct lynx_target_ops): Update arch_setup stub comment
9135 to post_create_inferior.
9136 * nto-low.c (struct nto_target_ops): Likewise.
9137 * spu-low.c (struct spu_target_ops): Likewise.
9138 * win32-low.c (struct win32_target_ops): Likewise.
9139
9140 2015-12-03 Antoine Tremblay <antoine.tremblay@ericsson.com>
9141
9142 * linux-arm-low.c: Remove duplicate arch/arm.h include.
9143
9144 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
9145
9146 * linux-arm-low.c (arm_reinsert_addr): Remove function.
9147 (struct linux_target_ops <breakpoint_reinsert_addr>: Set to NULL.
9148 * linux-cris-low.c (cris_reinsert_addr> Remove function.
9149 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
9150 * linux-crisv32-low.c (cris_reinsert_addr): Remove function.
9151 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
9152 * linux-mips-low.c (mips_reinsert_addr): Remove function.
9153 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
9154 * linux-nios2-low.c (nios2_reinsert_addr): Remove function.
9155 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
9156 * linux-sparc-low.c (sparc_reinsert_addr): Remove function.
9157 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
9158
9159 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
9160
9161 * linux-low.c (linux_look_up_symbols): Don't call
9162 linux_supports_traceclone.
9163 * linux-low.h (thread_db_init): Remove use_events argument.
9164 * thread-db.c (thread_db_use_event): Remove global variable.
9165 (struct thread_db) <td_thr_event_enable_p>: Remove field.
9166 (struct thread_db) <td_create_bp>: Remove field.
9167 (thread_db_create_event): Remove function.
9168 (thread_db_enable_reporting): Likewise.
9169 (find_one_thread): Don't check for thread_db_use_events.
9170 (attach_thread): Likewise.
9171 (thread_db_load_search): Remove td_thr_event_enable_p initialization.
9172 (try_thread_db_load_1): Don't check for thread_db_use_events.
9173 (thread_db_init): Remove use_events argument and thread events
9174 handling.
9175 (remove_thread_event_breakpoints): Remove function.
9176 (thread_db_detach): Remove call to remove_thred_event_breakpoints.
9177
9178 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
9179
9180 * linux-aarch64-low.c (aarch64_supports_hardware_single_step):
9181 New function.
9182 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9183 * linux-arm-low.c (arm_supports_hardware_single_step): New function.
9184 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9185 * linux-bfin-low.c (bfin_supports_hardware_single_step): New function.
9186 (struct linux_target_ops) <bfin_supports_hardware_single_step>:
9187 Initialize.
9188 * linux-crisv32-low.c (cris_supports_hardware_single_step):
9189 New function.
9190 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9191 * linux-low.c (can_hardware_single_step): Use
9192 supports_hardware_single_step.
9193 (can_software_single_step): New function.
9194 (start_step_over): Call can_software_single_step.
9195 (linux_supports_hardware_single_step): New function.
9196 (struct target_ops) <supports_software_single_step>: Initialize.
9197 * linux-low.h (struct linux_target_ops)
9198 <supports_hardware_single_step>: Initialize.
9199 * linux-m32r-low.c (m32r_supports_hardware_single_step): New function.
9200 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9201 * linux-ppc-low.c (ppc_supports_hardware_single_step): New function.
9202 (struct linux_target_ops) <supports_hardware_single_step> Initialize.
9203 * linux-s390-low.c (s390_supports_hardware_single_step): New function.
9204 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9205 * linux-sh-low.c (sh_supports_hardware_single_step): New function.
9206 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9207 * linux-tic6x-low.c (tic6x_supports_hardware_single_step): New function.
9208 (struct linux_target_ops) <tic6x_supports_hardware_single_step>:
9209 Initialize.
9210 * linux-tile-low.c (tile_supports_hardware_single_step): New function.
9211 (struct linux_target_ops) <tile_supports_hardware_single_step>:
9212 Initialize.
9213 * linux-x86-low.c (x86_supports_hardware_single_step) New function.
9214 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9215 * linux-xtensa-low.c (xtensa_supports_hardware_single_step):
9216 New function.
9217 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9218 * target.h (struct target_ops): <supports_software_single_step>:
9219 New field.
9220 (target_supports_software_single_step): New macro.
9221
9222 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
9223
9224 * linux-low.c (linux_wait_1): Fix pc advance condition.
9225 * mem-break.c (reinsert_breakpoint_inserted_here): New function.
9226 * mem-break.h (reinsert_breakpoint_inserted_here): New declaration.
9227
9228 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
9229
9230 * linux-arm-low.c (arm_is_thumb_mode): New function.
9231 (arm_breakpoint_at): Use arm_is_thumb_mode.
9232 (arm_breakpoint_kind_from_current_state): New function.
9233 (struct linux_target_ops) <breakpoint_kind_from_current_state>:
9234 Initialize.
9235 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_current_state.
9236 (linux_breakpoint_kind_from_current_state): New function.
9237 (struct target_ops <breakpoint_kind_from_current_state>: Initialize.
9238 * linux-low.h (struct linux_target_ops)
9239 <breakpoint_kind_from_current_state>: New field.
9240 * target.h (struct target_ops): Likewise.
9241 (target_breakpoint_kind_from_current_state): New macro.
9242
9243 2015-11-30 Pedro Alves <palves@redhat.com>
9244
9245 * linux-low.c (linux_resume): Wake up the event loop before
9246 returning.
9247
9248 2015-11-30 Pedro Alves <palves@redhat.com>
9249
9250 * mem-break.c (check_gdb_bp_preconditions): Remove current_thread
9251 check.
9252 (set_gdb_breakpoint): If prepare_to_access_memory fails, set *ERR
9253 to -1.
9254 * target.c (struct thread_search): New structure.
9255 (thread_search_callback): New function.
9256 (prev_general_thread): New global.
9257 (prepare_to_access_memory, done_accessing_memory): New functions.
9258 * target.h (prepare_to_access_memory, done_accessing_memory):
9259 Replace macros with function declarations.
9260
9261 2015-11-30 Pedro Alves <palves@redhat.com>
9262
9263 PR 14618
9264 * linux-low.c (linux_wait_1): If the last resumed thread is gone,
9265 report TARGET_WAITKIND_NO_RESUMED.
9266 * remote-utils.c (prepare_resume_reply): Handle
9267 TARGET_WAITKIND_NO_RESUMED.
9268 * server.c (report_no_resumed): New global.
9269 (handle_query) <qSupported>: Handle "no-resumed+". Report
9270 "no-resumed+" support.
9271 (resume): When the target reports TARGET_WAITKIND_NO_RESUMED, only
9272 return error if the client doesn't support no-resumed events.
9273 (push_stop_notification): New function.
9274 (handle_target_event): Use it. Report TARGET_WAITKIND_NO_RESUMED
9275 events if the client supports them.
9276
9277 2015-11-30 Pedro Alves <palves@redhat.com>
9278
9279 * linux-low.c (thread_still_has_status_pending_p): Don't check
9280 vCont;t here.
9281 (lwp_resumed): New function.
9282 (status_pending_p_callback): Return early if the LWP is not
9283 supposed to be resumed.
9284
9285 2015-11-30 Pedro Alves <palves@redhat.com>
9286
9287 * linux-low.c (handle_extended_wait): Assert that the LWP's
9288 waitstatus is TARGET_WAITKIND_IGNORE. If GDB wants to hear about
9289 thread create events, leave the new child's status pending.
9290 (linux_low_filter_event): If GDB wants to hear about thread exit
9291 events, leave the LWP marked dead and don't delete it.
9292 (linux_wait_for_event_filtered): Don't check for thread exit.
9293 (filter_exit_event): New function.
9294 (linux_wait_1): Use it, when returning an exit event.
9295 (linux_resume_one_lwp_throw): Assert that the LWP's
9296 waitstatus is TARGET_WAITKIND_IGNORE.
9297 * remote-utils.c (prepare_resume_reply): Handle
9298 TARGET_WAITKIND_THREAD_CREATED and TARGET_WAITKIND_THREAD_EXITED.
9299 * server.c (report_thread_events): New global.
9300 (handle_general_set): Handle QThreadEvents.
9301 (handle_query) <qSupported>: Handle and report QThreadEvents+;
9302 (handle_target_event): Handle TARGET_WAITKIND_THREAD_CREATED and
9303 TARGET_WAITKIND_THREAD_EXITED.
9304 * server.h (report_thread_events): Declare.
9305
9306 2015-11-30 Pedro Alves <palves@redhat.com>
9307
9308 * linux-low.c (resume_stopped_resumed_lwps): Don't check whether
9309 the thread's last_resume_kind was resume_stop.
9310
9311 2015-11-30 Pedro Alves <palves@redhat.com>
9312
9313 * linux-low.c (linux_attach): In non-stop mode, wait for one stop
9314 before returning.
9315
9316 2015-11-30 Pedro Alves <palves@redhat.com>
9317
9318 * server.c (handle_v_requests): Handle vCtrlC.
9319
9320 2015-11-30 Pedro Alves <palves@redhat.com>
9321
9322 * gdbthread.h (find_any_thread_of_pid): Declare.
9323 * inferiors.c (thread_of_pid, find_any_thread_of_pid): New
9324 functions.
9325 * server.c (handle_query): If current_thread is NULL, look for
9326 another thread of the selected process.
9327
9328 2015-11-26 Daniel Colascione <dancol@dancol.org>
9329 Simon Marchi <simon.marchi@ericsson.com>
9330
9331 * linux-low.c (linux_target_ops): Use linux_proc_tid_get_name.
9332 * server.c (handle_qxfer_threads_worker): Refactor to include thread
9333 name in reply.
9334 * target.h (struct target_ops) <thread_name>: New field.
9335 (target_thread_name): New macro.
9336
9337 2015-11-23 Joel Brobecker <brobecker@adacore.com>
9338
9339 * regcache.h (regcache_invalidate_pid): Add declaration.
9340 * regcache.c (regcache_invalidate_pid): New function, extracted
9341 from regcache_invalidate.
9342 (regcache_invalidate): Reimplement using regcache_invalidate_pid.
9343 Add trivial documentation comment.
9344 * lynx-low.c: Use regcache_invalidate_pid instead of
9345 regcache_invalidate.
9346
9347 2015-11-23 Joel Brobecker <brobecker@adacore.com>
9348
9349 * configure.ac: Do not call AC_CHECK_TYPES for Elf32_auxv_t
9350 and Elf64_auxv_t if the target is Android.
9351
9352 2015-11-22 Doug Evans <xdje42@gmail.com>
9353
9354 * target.h: #include <sys/types.h>.
9355
9356 2015-11-19 Pedro Alves <palves@redhat.com>
9357
9358 * linux-low.c (linux_process_qsupported): Change prototype.
9359 Adjust.
9360 * linux-low.h (struct linux_target_ops) <process_qsupported>:
9361 Change prototype.
9362 * linux-x86-low.c (x86_linux_process_qsupported): Change prototype
9363 and adjust to loop over all features.
9364 * server.c (handle_query) <qSupported>: Adjust to call
9365 target_process_qsupported once, passing it a vector of unprocessed
9366 features.
9367 * target.h (struct target_ops) <process_qsupported>: Change
9368 prototype.
9369 (target_process_qsupported): Adjust.
9370
9371 2015-11-19 Pedro Alves <palves@redhat.com>
9372
9373 * configure.ac (ERROR_ON_WARNING): Don't check whether in C++
9374 mode.
9375 * configure: Regenerate.
9376
9377 2015-11-19 Pedro Alves <palves@redhat.com>
9378
9379 * configure: Regenerate.
9380
9381 2015-11-19 Yao Qi <yao.qi@linaro.org>
9382
9383 * linux-aarch64-low.c (emit_data_processing_reg): Change opcode
9384 type to uint32_t.
9385
9386 2015-11-19 Yao Qi <yao.qi@linaro.org>
9387
9388 * linux-aarch64-low.c (enum aarch64_operand_type): New.
9389 (struct aarch64_operand): Move enum out.
9390
9391 2015-11-19 Yao Qi <yao.qi@linaro.org>
9392
9393 * linux-aarch64-low.c (aarch64_fill_fpregset): Cast buf to
9394 struct user_fpsimd_state *.
9395 (aarch64_store_fpregset): Likewise.
9396
9397 2015-11-19 Yao Qi <yao.qi@linaro.org>
9398
9399 * linux-aarch64-low.c (aarch64_fill_gregset): Cast buf to
9400 struct user_pt_regs *.
9401 (aarch64_store_gregset): Likewise.
9402
9403 2015-11-18 Pedro Alves <palves@redhat.com>
9404
9405 * Makefile.in (all_object_files): Add $IPA_OBJS.
9406
9407 2015-11-17 Pedro Alves <palves@redhat.com>
9408
9409 * win32-low.c (win32_resume): Use gdb_signal_from_host,
9410 GDB_SIGNAL_0 and gdb_signal_to_string.
9411
9412 2015-11-17 Pedro Alves <palves@redhat.com>
9413
9414 * win32-low.c (handle_output_debug_string): Remove parameter.
9415 (win32_kill): Remove our_status local and adjust call to
9416 handle_output_debug_string.
9417 (get_child_debug_event): Adjust call to
9418 handle_output_debug_string.
9419
9420 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9421
9422 * linux-mips-low.c (mips_fill_gregset): Add cast.
9423 (mips_store_gregset): Likewise.
9424 (mips_fill_fpregset): Likewise.
9425 (mips_store_fpregset): Likewise.
9426
9427 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9428
9429 * linux-mips-low.c (mips_add_watchpoint): Rename private to
9430 priv.
9431
9432 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9433
9434 * linux-mips-low.c (mips_linux_new_thread): Change type of
9435 watch_type to enum target_hw_bp_type.
9436
9437 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9438
9439 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type):
9440 Change return type to arm_hwbp_type.
9441
9442 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9443
9444 * linux-aarch32-low.c (arm_fill_gregset): Add cast.
9445 (arm_store_gregset): Likewise.
9446 * linux-arm-low.c (arm_get_hwcap): Likewise.
9447 (arm_read_description): Likewise.
9448
9449 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9450
9451 * linux-aarch32-low.c (aarch32_regsets): Use NULL_REGSET.
9452
9453 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9454
9455 * linux-ppc-low.c (ppc_get_hwcap): Add cast.
9456 (ppc_fill_vsxregset): Likewise.
9457 (ppc_store_vsxregset): Likewise.
9458 (ppc_fill_vrregset): Likewise.
9459 (ppc_store_vrregset): Likewise.
9460 (ppc_fill_evrregset): Likewise.
9461 (ppc_store_evrregset): Likewise.
9462
9463 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9464
9465 * linux-ppc-low.c (ppc_usrregs_info): Remove
9466 forward-declaration.
9467 (ppc_arch_setup): Move lower in file.
9468
9469 2015-10-30 Simon Marchi <simon.marchi@ericsson.com>
9470
9471 * proc-service.c (ps_pdread): Change CORE_ADDR cast to uintptr_t.
9472 (ps_pdwrite): Likewise.
9473
9474 2015-10-29 Henrik Wallin <henrik.wallin@windriver.com>
9475
9476 * linux-arm-low.c (arm_new_thread): Move pointer dereference
9477 to after assert checks.
9478
9479 2015-10-29 Simon Marchi <simon.marchi@ericsson.com>
9480
9481 * proc-service.c (ps_pdread): Add/adjust casts.
9482 (ps_pdwrite): Add/adjust casts.
9483
9484 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
9485
9486 * server.c (handle_search_memory_1): Cast return value of
9487 memmem.
9488
9489 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
9490
9491 * server.c (write_qxfer_response): Change type of data to
9492 gdb_byte *.
9493
9494 2015-10-29 Pedro Alves <palves@redhat.com>
9495
9496 * mem-break.c (Z_packet_to_bkpt_type): Add cast.
9497
9498 2015-10-29 Pedro Alves <palves@redhat.com>
9499
9500 * tracepoint.c (clear_installed_tracepoints): Add casts.
9501
9502 2015-10-29 Pedro Alves <palves@redhat.com>
9503
9504 * server.c (handle_v_cont, process_serial_event): Add enum
9505 gdb_signal casts to signal parsing code.
9506
9507 2015-10-29 Pedro Alves <palves@redhat.com>
9508
9509 * linux-low.h (NULL_REGSET): Define.
9510 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
9511 * linux-arm-low.c (arm_regsets): Likewise.
9512 * linux-crisv32-low.c (cris_regsets): Likewise.
9513 * linux-m68k-low.c (m68k_regsets): Likewise.
9514 * linux-mips-low.c (mips_regsets): Likewise.
9515 * linux-nios2-low.c (nios2_regsets): Likewise.
9516 * linux-ppc-low.c (ppc_regsets): Likewise.
9517 * linux-s390-low.c (s390_regsets): Likewise.
9518 * linux-sh-low.c (sh_regsets): Likewise.
9519 * linux-sparc-low.c (sparc_regsets): Likewise.
9520 * linux-tic6x-low.c (tic6x_regsets): Likewise.
9521 * linux-tile-low.c (tile_regsets): Likewise.
9522 * linux-x86-low.c (x86_regsets): Likewise.
9523 * linux-xtensa-low.c (xtensa_regsets): Likewise.
9524
9525 2015-10-29 Pedro Alves <palves@redhat.com>
9526
9527 * linux-low.h (NULL_REGSET): Define.
9528 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
9529 * linux-arm-low.c (arm_regsets): Likewise.
9530 * linux-crisv32-low.c (cris_regsets): Likewise.
9531 * linux-m68k-low.c (m68k_regsets): Likewise.
9532 * linux-mips-low.c (mips_regsets): Likewise.
9533 * linux-nios2-low.c (nios2_regsets): Likewise.
9534 * linux-ppc-low.c (ppc_regsets): Likewise.
9535 * linux-s390-low.c (s390_regsets): Likewise.
9536 * linux-sh-low.c (sh_regsets): Likewise.
9537 * linux-sparc-low.c (sparc_regsets): Likewise.
9538 * linux-tic6x-low.c (tic6x_regsets): Likewise.
9539 * linux-tile-low.c (tile_regsets): Likewise.
9540 * linux-x86-low.c (x86_regsets): Likewise.
9541 * linux-xtensa-low.c (xtensa_regsets): Likewise.
9542
9543 2015-10-26 Doug Evans <dje@google.com>
9544
9545 * linux-low.c (__SIGRTMIN): Move to nat/linux-nat.h.
9546
9547 2015-10-26 Doug Evans <dje@google.com>
9548
9549 * linux-low.c (W_STOPCODE): Moved to common/gdb_wait.h.
9550
9551 2015-10-26 Doug Evans <dje@google.com>
9552
9553 * thread-db.c (find_one_thread): Cast ti.ti_tid to unsigned long
9554 for debug_printf.
9555 (attach_thread, find_new_threads_callback): Ditto.
9556
9557 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
9558
9559 * mem-break.h (set_breakpoint_data): Remove.
9560
9561 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
9562
9563 * nto-low.c (nto_sw_breakpoint_from_kind): New function.
9564 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
9565 (initialize_low): Remove set_breakpoint_data call.
9566 * spu-low.c (spu_sw_breakpoint_from_kind): New function.
9567 (struct target_ops) <sw_breakpoint_from_kind>: Iniitalize.
9568 (initialize_low): Remove set_breakpoint_data call.
9569 * win32-low.c (win32_sw_breakpoint_from_kind): New function.
9570 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
9571 (initialize_low): Remove set_breakpoint_data call.
9572
9573 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
9574
9575 * linux-low.c (default_breakpoint_kind_from_pc): Move to target.c.
9576 * mem-break.c (set_breakpoint_at): Use target_breakpoint_kind_from_pc.
9577 * target.c (default_breakpoint_kind_from_pc): Moved from linux-low.c
9578 * target.h (target_breakpoint_kind_from_pc): New macro.
9579
9580 2015-10-22 Antoine Tremblay <antoine.tremblay@ericsson.com>
9581
9582 * linux-low.c (default_breakpoint_kind_from_pc): New function.
9583 (linux_breakpoint_kind_from_pc): Use default_breakpoint_kind_from_pc for
9584 the default breakpoint kind.
9585
9586 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9587
9588 * linux-arm-low.c (arm_supports_z_point_type): Add software
9589 breakpoint support.
9590
9591 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9592
9593 * linux-arm-low.c: Refactor breakpoint definitions.
9594 (arm_breakpoint_at): Adjust for arm_abi_breakpoint.
9595 (arm_sw_breakpoint_from_kind): Adjust for arm_breakpoint.
9596
9597 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9598
9599 * Makefile.in: Add arm.c/o.
9600 * configure.srv: Likewise.
9601 * linux-arm-low.c (arm_breakpoint_kinds): New enum.
9602 (arm_breakpoint_kind_from_pc): New function.
9603 (arm_sw_breakpoint_from_kind): Return proper kind.
9604 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize.
9605
9606 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9607
9608 * linux-low.c (initialize_low): Ajdust for breakpoint global variables
9609 removal.
9610 * mem-break.c : Remove breakpoint_data/breakpoint_len global variables.
9611 (struct raw_breakpoint) <size>: Remove.
9612 (struct raw_breakpoint) <kind>: Add.
9613 (bp_size): New function.
9614 (bp_opcode): Likewise.
9615 (find_raw_breakpoint_at): Adjust for kind.
9616 (insert_memory_breakpoint): Adjust for kind call bp_size,bp_opcode.
9617 (remove_memory_breakpoint): Adjust for kind call bp_size.
9618 (set_raw_breakpoint_at): Adjust for kind.
9619 (set_breakpoint): Likewise.
9620 (set_breakpoint_at): Call breakpoint_kind_from_pc.
9621 (delete_raw_breakpoint): Adjust for kind.
9622 (delete_breakpoint): Likewise.
9623 (find_gdb_breakpoint): Likewise.
9624 (set_gdb_breakpoint_1): Likewise.
9625 (set_gdb_breakpoint): Likewise.
9626 (delete_gdb_breakpoint_1): Likewise.
9627 (delete_gdb_breakpoint): Likewise.
9628 (uninsert_raw_breakpoint): Likewise.
9629 (reinsert_raw_breakpoint): Likewise.
9630 (set_breakpoint_data): Remove.
9631 (validate_inserted_breakpoint): Adjust for kind call bp_size,bp_opcode.
9632 (check_mem_read): Adjust for kind call bp_size.
9633 (check_mem_write): Adjust for kind call bp_size,bp_opcode.
9634 (clone_one_breakpoint): Adjust for kind.
9635 * mem-break.h (set_gdb_breakpoint): Likewise.
9636 (delete_gdb_breakpoint): Likewise.
9637 * server.c (process_serial_event): Likewise.
9638
9639 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9640
9641 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): New function.
9642 (struct linux_target_ops) <breakpoint>: Remove.
9643 (struct linux_target_ops) <breakpoint_len>: Remove.
9644 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9645 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9646 * linux-arm-low.c (arm_breakpoint_kind_from_pc): New function.
9647 (arm_sw_breakpoint_from_kind): New function.
9648 * linux-bfin-low.c (bfin_sw_breakpoint_from_kind): New function.
9649 (struct linux_target_ops) <breakpoint>: Remove.
9650 (struct linux_target_ops) <breakpoint_len>: Remove.
9651 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9652 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9653 * linux-cris-low.c (cris_sw_breakpoint_from_kind): New function.
9654 (struct linux_target_ops) <breakpoint>: Remove.
9655 (struct linux_target_ops) <breakpoint_len>: Remove.
9656 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9657 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9658 * linux-crisv32-low.c (cris_sw_breakpoint_from_kind): New function.
9659 (struct linux_target_ops) <breakpoint>: Remove.
9660 (struct linux_target_ops) <breakpoint_len>: Remove.
9661 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9662 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9663 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_pc
9664 and sw_breakpoint_from_kind to increment the pc.
9665 (linux_breakpoint_kind_from_pc): New function.
9666 (linux_sw_breakpoint_from_kind): New function.
9667 (struct target_ops) <sw_breakpoint_from_kind>: Initialize field.
9668 (initialize_low): Call breakpoint_kind_from_pc and
9669 sw_breakpoint_from_kind to replace breakpoint_data/len.
9670 * linux-low.h (struct linux_target_ops) <breakpoint_kind_from_pc>:
9671 New field.
9672 (struct linux_target_ops) <sw_breakpoint_from_kind>: Likewise.
9673 * linux-m32r-low.c (m32r_sw_breakpoint_from_kind): New function.
9674 (struct linux_target_ops) <breakpoint>: Remove.
9675 (struct linux_target_ops) <breakpoint_len>: Remove.
9676 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9677 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9678 * linux-m68k-low.c (m68k_sw_breakpoint_from_kind): New function.
9679 (struct linux_target_ops) <breakpoint>: Remove.
9680 (struct linux_target_ops) <breakpoint_len>: Remove.
9681 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9682 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9683 * linux-mips-low.c (mips_sw_breakpoint_from_kind): New function.
9684 (struct linux_target_ops) <breakpoint>: Remove.
9685 (struct linux_target_ops) <breakpoint_len>: Remove.
9686 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9687 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9688 * linux-nios2-low.c (nios2_sw_breakpoint_from_kind): New function.
9689 (struct linux_target_ops) <breakpoint>: Remove.
9690 (struct linux_target_ops) <breakpoint_len>: Remove.
9691 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9692 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9693 * linux-ppc-low.c (ppc_sw_breakpoint_from_kind): New function.
9694 (struct linux_target_ops) <breakpoint>: Remove.
9695 (struct linux_target_ops) <breakpoint_len>: Remove.
9696 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9697 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9698 * linux-s390-low.c (s390_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-sh-low.c (sh_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-sparc-low.c (sparc_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-tic6x-low.c (tic6x_sw_breakpoint_from_kind): New function.
9714 (struct linux_target_ops) <breakpoint>: Remove.
9715 (struct linux_target_ops) <breakpoint_len>: Remove.
9716 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9717 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9718 * linux-tile-low.c (tile_sw_breakpoint_from_kind): New function.
9719 * linux-x86-low.c (x86_sw_breakpoint_from_kind): New function.
9720 (struct linux_target_ops) <breakpoint>: Remove.
9721 (struct linux_target_ops) <breakpoint_len>: Remove.
9722 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9723 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9724 * linux-xtensa-low.c (xtensa_sw_breakpoint_from_kind) New function.
9725 (struct linux_target_ops) <breakpoint>: Remove.
9726 (struct linux_target_ops) <breakpoint_len>: Remove.
9727 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9728 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9729
9730 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9731
9732 * linux-cris-low.c (cris_get_pc): Remove void arg.
9733
9734 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
9735
9736 * gdbserver/nto-low.c (nto_insert_point, nto_remove_point): Fix
9737 variable name.
9738
9739 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
9740
9741 * inferiors.c (thread_pid_matches_callback): New function.
9742 (find_thread_process): New function.
9743 (remove_thread): Reset current_thread.
9744 (remove_process): Assert threads have been removed first.
9745
9746 2015-10-15 Yao Qi <yao.qi@linaro.org>
9747
9748 * linux-aarch64-low.c (aarch64_insert_point): Set len to 2
9749 if it is 3.
9750 (aarch64_remove_point): Likewise.
9751 * regcache.c (regcache_register_size): New function.
9752
9753 2015-10-12 Yao Qi <yao.qi@linaro.org>
9754
9755 * linux-aarch64-low.c: Update all callers as emit_load_store
9756 is renamed to aarch64_emit_load_store.
9757
9758 2015-10-12 Yao Qi <yao.qi@linaro.org>
9759
9760 * linux-aarch64-low.c: Update all callers of function renaming
9761 from emit_insn to aarch64_emit_insn.
9762
9763 2015-10-12 Yao Qi <yao.qi@linaro.org>
9764
9765 * linux-aarch64-low.c (enum aarch64_opcodes): Move to
9766 arch/aarch64-insn.h.
9767 (struct aarch64_memory_operand): Likewise.
9768 (ENCODE): Likewise.
9769 (emit_insn): Move to arch/aarch64-insn.c.
9770 (emit_b, emit_bcond, emit_cb, emit_tb): Remove.
9771 (emit_load_store): Move to arch/aarch64-insn.c.
9772 (emit_ldr, emit_ldrb, emit_ldrsw, emit_nop): Remove.
9773 (can_encode_int32): Remove.
9774
9775 2015-10-12 Yao Qi <yao.qi@linaro.org>
9776
9777 * linux-aarch64-low.c (extract_signed_bitfield): Remove.
9778 (aarch64_decode_ldr_literal): Move to gdb/arch/aarch64-insn.c.
9779 (aarch64_relocate_instruction): Likewise.
9780 (struct aarch64_insn_data): Move to gdb/arch/aarch64-insn.h.
9781 (struct aarch64_insn_visitor): Likewise.
9782
9783 2015-10-12 Yao Qi <yao.qi@linaro.org>
9784
9785 * linux-aarch64-low.c (struct aarch64_insn_data): New.
9786 (struct aarch64_insn_visitor): New.
9787 (struct aarch64_insn_relocation_data): New.
9788 (aarch64_ftrace_insn_reloc_b): New function.
9789 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
9790 (aarch64_ftrace_insn_reloc_cb): Likewise.
9791 (aarch64_ftrace_insn_reloc_tb): Likewise.
9792 (aarch64_ftrace_insn_reloc_adr): Likewise.
9793 (aarch64_ftrace_insn_reloc_ldr_literal): Likewise.
9794 (aarch64_ftrace_insn_reloc_others): Likewise.
9795 (visitor): New.
9796 (aarch64_relocate_instruction): Use visitor.
9797
9798 2015-10-12 Yao Qi <yao.qi@linaro.org>
9799
9800 * linux-aarch64-low.c (aarch64_relocate_instruction): Return
9801 int. Add argument buf.
9802 (aarch64_install_fast_tracepoint_jump_pad): Pass buf to
9803 aarch64_relocate_instruction.
9804
9805 2015-10-12 Yao Qi <yao.qi@linaro.org>
9806
9807 * linux-aarch64-low.c (aarch64_relocate_instruction): Add
9808 argument insn. Remove local variable insn. Don't call
9809 target_read_uint32.
9810 (aarch64_install_fast_tracepoint_jump_pad): Call
9811 target_read_uint32.
9812
9813 2015-09-30 Yao Qi <yao.qi@linaro.org>
9814
9815 * linux-aarch64-low.c (emit_movk): Shorten a long line.
9816 (emit_load_store_pair): Likewise.
9817
9818 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
9819
9820 * dll.c (match_dll): Add cast(s).
9821 (unloaded_dll): Likewise.
9822 * linux-low.c (second_thread_of_pid_p): Likewise.
9823 (delete_lwp_callback): Likewise.
9824 (count_events_callback): Likewise.
9825 (select_event_lwp_callback): Likewise.
9826 (linux_set_resume_request): Likewise.
9827 * server.c (accumulate_file_name_length): Likewise.
9828 (emit_dll_description): Likewise.
9829 (handle_qxfer_threads_worker): Likewise.
9830 (visit_actioned_threads): Likewise.
9831 * thread-db.c (any_thread_of): Likewise.
9832 * tracepoint.c (same_process_p): Likewise.
9833 (match_blocktype): Likewise.
9834 (build_traceframe_info_xml): Likewise.
9835
9836 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
9837
9838 * ax.c (gdb_parse_agent_expr): Add cast to allocation result
9839 assignment.
9840 (gdb_unparse_agent_expr): Likewise.
9841 * hostio.c (require_data): Likewise.
9842 (handle_pread): Likewise.
9843 * linux-low.c (disable_regset): Likewise.
9844 (fetch_register): Likewise.
9845 (store_register): Likewise.
9846 (get_dynamic): Likewise.
9847 (linux_qxfer_libraries_svr4): Likewise.
9848 * mem-break.c (delete_fast_tracepoint_jump): Likewise.
9849 (set_fast_tracepoint_jump): Likewise.
9850 (uninsert_fast_tracepoint_jumps_at): Likewise.
9851 (reinsert_fast_tracepoint_jumps_at): Likewise.
9852 (validate_inserted_breakpoint): Likewise.
9853 (clone_agent_expr): Likewise.
9854 * regcache.c (init_register_cache): Likewise.
9855 * remote-utils.c (putpkt_binary_1): Likewise.
9856 (decode_M_packet): Likewise.
9857 (decode_X_packet): Likewise.
9858 (look_up_one_symbol): Likewise.
9859 (relocate_instruction): Likewise.
9860 (monitor_output): Likewise.
9861 * server.c (handle_search_memory): Likewise.
9862 (handle_qxfer_exec_file): Likewise.
9863 (handle_qxfer_libraries): Likewise.
9864 (handle_qxfer): Likewise.
9865 (handle_query): Likewise.
9866 (handle_v_cont): Likewise.
9867 (handle_v_run): Likewise.
9868 (captured_main): Likewise.
9869 * target.c (write_inferior_memory): Likewise.
9870 * thread-db.c (try_thread_db_load_from_dir): Likewise.
9871 * tracepoint.c (init_trace_buffer): Likewise.
9872 (add_tracepoint_action): Likewise.
9873 (add_traceframe): Likewise.
9874 (add_traceframe_block): Likewise.
9875 (cmd_qtdpsrc): Likewise.
9876 (cmd_qtdv): Likewise.
9877 (cmd_qtstatus): Likewise.
9878 (response_source): Likewise.
9879 (response_tsv): Likewise.
9880 (cmd_qtnotes): Likewise.
9881 (gdb_collect): Likewise.
9882 (initialize_tracepoint): Likewise.
9883
9884 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
9885
9886 * linux-aarch64-low-.c: Include ax.h and tracepoint.h.
9887 (enum aarch64_opcodes) <RET>, <SUBS>, <AND>, <ORR>, <ORN>,
9888 <EOR>, <LSLV>, <LSRV>, <ASRV>, <SBFM>, <UBFM>, <CSINC>, <MUL>,
9889 <NOP>: New.
9890 (enum aarch64_condition_codes): New enum.
9891 (w0): New static global.
9892 (fp): Likewise.
9893 (lr): Likewise.
9894 (struct aarch64_memory_operand) <type>: New
9895 MEMORY_OPERAND_POSTINDEX type.
9896 (postindex_memory_operand): New helper function.
9897 (emit_ret): New function.
9898 (emit_load_store_pair): New function, factored out of emit_stp
9899 with support for MEMORY_OPERAND_POSTINDEX.
9900 (emit_stp): Rewrite using emit_load_store_pair.
9901 (emit_ldp): New function.
9902 (emit_load_store): Likewise.
9903 (emit_ldr): Mention post-index instruction in comment.
9904 (emit_ldrh): New function.
9905 (emit_ldrb): New function.
9906 (emit_ldrsw): Mention post-index instruction in comment.
9907 (emit_str): Likewise.
9908 (emit_subs): New function.
9909 (emit_cmp): Likewise.
9910 (emit_and): Likewise.
9911 (emit_orr): Likewise.
9912 (emit_orn): Likewise.
9913 (emit_eor): Likewise.
9914 (emit_mvn): Likewise.
9915 (emit_lslv): Likewise.
9916 (emit_lsrv): Likewise.
9917 (emit_asrv): Likewise.
9918 (emit_mul): Likewise.
9919 (emit_sbfm): Likewise.
9920 (emit_sbfx): Likewise.
9921 (emit_ubfm): Likewise.
9922 (emit_ubfx): Likewise.
9923 (emit_csinc): Likewise.
9924 (emit_cset): Likewise.
9925 (emit_nop): Likewise.
9926 (emit_ops_insns): New helper function.
9927 (emit_pop): Likewise.
9928 (emit_push): Likewise.
9929 (aarch64_emit_prologue): New function.
9930 (aarch64_emit_epilogue): Likewise.
9931 (aarch64_emit_add): Likewise.
9932 (aarch64_emit_sub): Likewise.
9933 (aarch64_emit_mul): Likewise.
9934 (aarch64_emit_lsh): Likewise.
9935 (aarch64_emit_rsh_signed): Likewise.
9936 (aarch64_emit_rsh_unsigned): Likewise.
9937 (aarch64_emit_ext): Likewise.
9938 (aarch64_emit_log_not): Likewise.
9939 (aarch64_emit_bit_and): Likewise.
9940 (aarch64_emit_bit_or): Likewise.
9941 (aarch64_emit_bit_xor): Likewise.
9942 (aarch64_emit_bit_not): Likewise.
9943 (aarch64_emit_equal): Likewise.
9944 (aarch64_emit_less_signed): Likewise.
9945 (aarch64_emit_less_unsigned): Likewise.
9946 (aarch64_emit_ref): Likewise.
9947 (aarch64_emit_if_goto): Likewise.
9948 (aarch64_emit_goto): Likewise.
9949 (aarch64_write_goto_address): Likewise.
9950 (aarch64_emit_const): Likewise.
9951 (aarch64_emit_call): Likewise.
9952 (aarch64_emit_reg): Likewise.
9953 (aarch64_emit_pop): Likewise.
9954 (aarch64_emit_stack_flush): Likewise.
9955 (aarch64_emit_zero_ext): Likewise.
9956 (aarch64_emit_swap): Likewise.
9957 (aarch64_emit_stack_adjust): Likewise.
9958 (aarch64_emit_int_call_1): Likewise.
9959 (aarch64_emit_void_call_2): Likewise.
9960 (aarch64_emit_eq_goto): Likewise.
9961 (aarch64_emit_ne_goto): Likewise.
9962 (aarch64_emit_lt_goto): Likewise.
9963 (aarch64_emit_le_goto): Likewise.
9964 (aarch64_emit_gt_goto): Likewise.
9965 (aarch64_emit_ge_got): Likewise.
9966 (aarch64_emit_ops_impl): New static global variable.
9967 (aarch64_emit_ops): New target function, return
9968 &aarch64_emit_ops_impl.
9969 (struct linux_target_ops): Install it.
9970
9971 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
9972
9973 * Makefile.in (linux-aarch64-ipa.o, aarch64-ipa.o): New rules.
9974 * configure.srv (aarch64*-*-linux*): Add linux-aarch64-ipa.o and
9975 aarch64-ipa.o.
9976 * linux-aarch64-ipa.c: New file.
9977 * linux-aarch64-low.c: Include arch/aarch64-insn.h, inttypes.h
9978 and endian.h.
9979 (aarch64_get_thread_area): New target method.
9980 (extract_signed_bitfield): New helper function.
9981 (aarch64_decode_ldr_literal): New function.
9982 (enum aarch64_opcodes): New enum.
9983 (struct aarch64_register): New struct.
9984 (struct aarch64_operand): New struct.
9985 (x0): New static global.
9986 (x1): Likewise.
9987 (x2): Likewise.
9988 (x3): Likewise.
9989 (x4): Likewise.
9990 (w2): Likewise.
9991 (ip0): Likewise.
9992 (sp): Likewise.
9993 (xzr): Likewise.
9994 (aarch64_register): New helper function.
9995 (register_operand): Likewise.
9996 (immediate_operand): Likewise.
9997 (struct aarch64_memory_operand): New struct.
9998 (offset_memory_operand): New helper function.
9999 (preindex_memory_operand): Likewise.
10000 (enum aarch64_system_control_registers): New enum.
10001 (ENCODE): New macro.
10002 (emit_insn): New helper function.
10003 (emit_b): New function.
10004 (emit_bcond): Likewise.
10005 (emit_cb): Likewise.
10006 (emit_tb): Likewise.
10007 (emit_blr): Likewise.
10008 (emit_stp): Likewise.
10009 (emit_ldp_q_offset): Likewise.
10010 (emit_stp_q_offset): Likewise.
10011 (emit_load_store): Likewise.
10012 (emit_ldr): Likewise.
10013 (emit_ldrsw): Likewise.
10014 (emit_str): Likewise.
10015 (emit_ldaxr): Likewise.
10016 (emit_stxr): Likewise.
10017 (emit_stlr): Likewise.
10018 (emit_data_processing_reg): Likewise.
10019 (emit_data_processing): Likewise.
10020 (emit_add): Likewise.
10021 (emit_sub): Likewise.
10022 (emit_mov): Likewise.
10023 (emit_movk): Likewise.
10024 (emit_mov_addr): Likewise.
10025 (emit_mrs): Likewise.
10026 (emit_msr): Likewise.
10027 (emit_sevl): Likewise.
10028 (emit_wfe): Likewise.
10029 (append_insns): Likewise.
10030 (can_encode_int32_in): New helper function.
10031 (aarch64_relocate_instruction): New function.
10032 (aarch64_install_fast_tracepoint_jump_pad): Likewise.
10033 (aarch64_get_min_fast_tracepoint_insn_len): Likewise.
10034 (struct linux_target_ops): Install aarch64_get_thread_area,
10035 aarch64_install_fast_tracepoint_jump_pad and
10036 aarch64_get_min_fast_tracepoint_insn_len.
10037
10038 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
10039
10040 * Makefile.in (aarch64-insn.o): New rule.
10041 * configure.srv (aarch64*-*-linux*): Add aarch64-insn.o.
10042
10043 2015-09-21 Yao Qi <yao.qi@linaro.org>
10044
10045 * ax.c [!IN_PROCESS_AGENT] (gdb_agent_op_sizes): Define it.
10046
10047 2015-09-21 Yao Qi <yao.qi@linaro.org>
10048
10049 * tracepoint.c (max_jump_pad_size): Remove.
10050
10051 2015-09-18 Yao Qi <yao.qi@linaro.org>
10052
10053 * linux-aarch64-low.c: Don't include sys/uio.h.
10054 (ps_get_thread_area): Call aarch64_ps_get_thread_area.
10055
10056 2015-09-16 Wei-cheng Wang <cole945@gmail.com>
10057
10058 * tracepoint.c (eval_result_type): Change prototype.
10059 (condition_true_at_tracepoint): Fix argument to compiled_cond.
10060
10061 2015-09-15 Pedro Alves <palves@redhat.com>
10062
10063 * remote-utils.c (prepare_resume_reply) <TARGET_WAITKIND_EXECD>:
10064 Check whether to report exec events instead of checking whether
10065 multiprocess is enabled.
10066
10067 2015-09-15 Pedro Alves <palves@redhat.com>
10068
10069 PR remote/18965
10070 * remote-utils.c (prepare_resume_reply): Merge
10071 TARGET_WAITKIND_VFORK_DONE switch case with the
10072 TARGET_WAITKIND_FORKED case.
10073
10074 2015-09-15 Yao Qi <yao.qi@linaro.org>
10075
10076 * server.c (handle_query): Check string comparison using
10077 "else if" instead of "if".
10078
10079 2015-09-15 Yao Qi <yao.qi@linaro.org>
10080
10081 * server.c (vCont_supported): New global variable.
10082 (handle_query): Set vCont_supported to 1 if "vContSupported+"
10083 matches. Append ";vContSupported+" to own_buf.
10084 (handle_v_requests): Append ";s;S" to own_buf if target supports
10085 hardware single step or vCont_supported is false.
10086 (capture_main): Set vCont_supported to zero.
10087
10088 2015-09-15 Yao Qi <yao.qi@linaro.org>
10089
10090 * linux-low.c (linux_supports_conditional_breakpoints): Rename
10091 it to ...
10092 (linux_supports_hardware_single_step): ... New function.
10093 (linux_target_ops): Update.
10094 * lynx-low.c (lynx_target_ops): Set field
10095 supports_hardware_single_step to target_can_do_hardware_single_step.
10096 * nto-low.c (nto_target_ops): Likewise.
10097 * spu-low.c (spu_target_ops): Likewise.
10098 * win32-low.c (win32_target_ops): Likewise.
10099 * target.c (target_can_do_hardware_single_step): New function.
10100 * target.h (struct target_ops) <supports_conditional_breakpoints>:
10101 Remove. <supports_hardware_single_step>: New field.
10102 (target_supports_conditional_breakpoints): Remove.
10103 (target_supports_hardware_single_step): New macro.
10104 (target_can_do_hardware_single_step): Declare.
10105 * server.c (handle_query): Use target_supports_hardware_single_step
10106 instead of target_supports_conditional_breakpoints.
10107
10108 2015-09-15 Yao Qi <yao.qi@linaro.org>
10109
10110 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): New
10111 function.
10112 (struct linux_target_ops the_low_target): Install
10113 aarch64_linux_siginfo_fixup.
10114
10115 2015-09-11 Don Breazeal <donb@codesourcery.com>
10116 Luis Machado <lgustavo@codesourcery.com>
10117
10118 * linux-low.c (linux_mourn): Static declaration.
10119 (linux_arch_setup): Move in front of
10120 handle_extended_wait.
10121 (linux_arch_setup_thread): New function.
10122 (handle_extended_wait): Handle exec events. Call
10123 linux_arch_setup_thread. Make event_lwp argument a
10124 pointer-to-a-pointer.
10125 (check_zombie_leaders): Do not check stopped threads.
10126 (linux_low_ptrace_options): Add PTRACE_O_TRACEEXEC.
10127 (linux_low_filter_event): Add lwp and thread for exec'ing
10128 non-leader thread if leader thread has been deleted.
10129 Refactor code into linux_arch_setup_thread and call it.
10130 Pass child lwp pointer by reference to handle_extended_wait.
10131 (linux_wait_for_event_filtered): Update comment.
10132 (linux_wait_1): Prevent clobbering exec event status.
10133 (linux_supports_exec_events): New function.
10134 (linux_target_ops) <supports_exec_events>: Initialize new member.
10135 * lynx-low.c (lynx_target_ops) <supports_exec_events>: Initialize
10136 new member.
10137 * remote-utils.c (prepare_resume_reply): New stop reason 'exec'.
10138 * server.c (report_exec_events): New global variable.
10139 (handle_query): Handle qSupported query for exec-events feature.
10140 (captured_main): Initialize report_exec_events.
10141 * server.h (report_exec_events): Declare new global variable.
10142 * target.h (struct target_ops) <supports_exec_events>: New
10143 member.
10144 (target_supports_exec_events): New macro.
10145 * win32-low.c (win32_target_ops) <supports_exec_events>:
10146 Initialize new member.
10147
10148 2015-09-09 Markus Metzger <markus.t.metzger@intel.com>
10149
10150 * linux-low.c (linux_low_enable_btrace): Remove.
10151 (linux_target_ops): Replace linux_low_enable_btrace with
10152 linux_enable_btrace.
10153
10154 2015-09-03 Yao Qi <yao.qi@linaro.org>
10155
10156 * linux-aarch64-low.c (aarch64_insert_point): Call
10157 aarch64_handle_watchpoint if aarch64_linux_region_ok_for_watchpoint
10158 returns true.
10159
10160 2015-08-27 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
10161
10162 * linux-low.c (check_stopped_by_breakpoint): Use
10163 GDB_ARCH_IS_TRAP_BRKPT instead of GDB_ARCH_TRAP_BRKPT.
10164
10165 2015-08-27 Pedro Alves <palves@redhat.com>
10166
10167 * proc-service.c (ps_pdwrite): Return PS_ERR/PS_OK explicily.
10168
10169 2015-08-26 Simon Marchi <simon.marchi@ericsson.com>
10170
10171 * ax.c (gdb_parse_agent_expr): Replace xmalloc-family function with
10172 the XNEW-family equivalent.
10173 (compile_bytecodes): Likewise.
10174 * dll.c (loaded_dll): Likewise.
10175 * event-loop.c (append_callback_event): Likewise.
10176 (create_file_handler): Likewise.
10177 (create_file_event): Likewise.
10178 * hostio.c (handle_open): Likewise.
10179 * inferiors.c (add_thread): Likewise.
10180 (add_process): Likewise.
10181 * linux-aarch64-low.c (aarch64_linux_new_process): Likewise.
10182 * linux-arm-low.c (arm_new_process): Likewise.
10183 (arm_new_thread): Likewise.
10184 * linux-low.c (add_to_pid_list): Likewise.
10185 (linux_add_process): Likewise.
10186 (handle_extended_wait): Likewise.
10187 (add_lwp): Likewise.
10188 (enqueue_one_deferred_signal): Likewise.
10189 (enqueue_pending_signal): Likewise.
10190 (linux_resume_one_lwp_throw): Likewise.
10191 (linux_resume_one_thread): Likewise.
10192 (linux_read_memory): Likewise.
10193 (linux_write_memory): Likewise.
10194 * linux-mips-low.c (mips_linux_new_process): Likewise.
10195 (mips_linux_new_thread): Likewise.
10196 (mips_add_watchpoint): Likewise.
10197 * linux-x86-low.c (initialize_low_arch): Likewise.
10198 * lynx-low.c (lynx_add_process): Likewise.
10199 * mem-break.c (set_raw_breakpoint_at): Likewise.
10200 (set_breakpoint): Likewise.
10201 (add_condition_to_breakpoint): Likewise.
10202 (add_commands_to_breakpoint): Likewise.
10203 (clone_agent_expr): Likewise.
10204 (clone_one_breakpoint): Likewise.
10205 * regcache.c (new_register_cache): Likewise.
10206 * remote-utils.c (look_up_one_symbol): Likewise.
10207 * server.c (queue_stop_reply): Likewise.
10208 (start_inferior): Likewise.
10209 (queue_stop_reply_callback): Likewise.
10210 (handle_target_event): Likewise.
10211 * spu-low.c (fetch_ppc_memory): Likewise.
10212 (store_ppc_memory): Likewise.
10213 * target.c (set_target_ops): Likewise.
10214 * thread-db.c (thread_db_load_search): Likewise.
10215 (try_thread_db_load_1): Likewise.
10216 * tracepoint.c (add_tracepoint): Likewise.
10217 (add_tracepoint_action): Likewise.
10218 (create_trace_state_variable): Likewise.
10219 (cmd_qtdpsrc): Likewise.
10220 (cmd_qtro): Likewise.
10221 (add_while_stepping_state): Likewise.
10222 * win32-low.c (child_add_thread): Likewise.
10223 (get_image_name): Likewise.
10224
10225 2015-08-25 Yao Qi <yao.qi@linaro.org>
10226
10227 * linux-aarch64-low.c (aarch64_linux_new_thread): Remove.
10228
10229 2015-08-25 Yao Qi <yao.qi@linaro.org>
10230
10231 * Makefile.in (aarch64-linux.o): New rule.
10232 * configure.srv (aarch64*-*-linux*): Append aarch64-linux.o to
10233 srv_tgtobj.
10234 * linux-aarch64-low.c: Include nat/aarch64-linux.h.
10235 (aarch64_init_debug_reg_state): Make it extern.
10236 (aarch64_linux_prepare_to_resume): Remove.
10237
10238 2015-08-25 Yao Qi <yao.qi@linaro.org>
10239
10240 * linux-aarch64-low.c (aarch64_linux_prepare_to_resume): Use
10241 lwp_arch_private_info and ptid_of_lwp.
10242
10243 2015-08-25 Yao Qi <yao.qi@linaro.org>
10244
10245 * linux-aarch64-low.c (aarch64_get_debug_reg_state): Add argument pid.
10246 Find proc_info by find_process_pid. All callers updated.
10247
10248 2015-08-25 Yao Qi <yao.qi@linaro.org>
10249
10250 * linux-aarch64-low.c (struct arch64_dr_update_callback_param):
10251 Remove.
10252 (debug_reg_change_callback): Remove.
10253 (aarch64_notify_debug_reg_change): Remove.
10254
10255 2015-08-25 Yao Qi <yao.qi@linaro.org>
10256
10257 * linux-aarch64-low.c (aarch64_notify_debug_reg_change):
10258 Call current_lwp_ptid.
10259
10260 2015-08-25 Yao Qi <yao.qi@linaro.org>
10261
10262 * linux-aarch64-low.c (debug_reg_change_callback): Use
10263 debug_printf.
10264
10265 2015-08-25 Yao Qi <yao.qi@linaro.org>
10266
10267 * linux-aarch64-low.c (debug_reg_change_callback): Use phex.
10268
10269 2015-08-25 Yao Qi <yao.qi@linaro.org>
10270
10271 * linux-aarch64-low.c (debug_reg_change_callback): Remove comments.
10272
10273 2015-08-25 Yao Qi <yao.qi@linaro.org>
10274
10275 * linux-aarch64-low.c (debug_reg_change_callback): Re-indent
10276 the code.
10277
10278 2015-08-25 Yao Qi <yao.qi@linaro.org>
10279
10280 * linux-aarch64-low.c (aarch64_dr_update_callback_param) <pid>:
10281 Remove.
10282 (debug_reg_change_callback): Remove argument entry and add argument
10283 lwp. Remove local variable thread. Don't print thread id in the
10284 debugging output. Don't check whether pid of thread equals to pid.
10285 (aarch64_notify_debug_reg_change): Don't set param.pid. Call
10286 iterate_over_lwps instead find_inferior.
10287
10288 2015-08-24 Pedro Alves <palves@redhat.com>
10289
10290 * inferiors.c (get_first_process): New function.
10291 * inferiors.h (get_first_process): New declaration.
10292 * remote-utils.c (read_ptid): Default to the first process in the
10293 list, instead of to the current thread's process.
10294
10295 2015-08-24 Pedro Alves <palves@redhat.com>
10296
10297 * debug.c: Include gdb_sys_time.h instead of sys/time.h.
10298 * event-loop.c: Likewise.
10299 * remote-utils.c: Likewise.
10300 * tracepoint.c: Likewise.
10301
10302 2015-08-24 Pedro Alves <palves@redhat.com>
10303
10304 * spu-low.c (spu_request_interrupt): Use lwpid_of instead of
10305 ptid_get_lwp.
10306
10307 2015-08-21 Pedro Alves <palves@redhat.com>
10308
10309 * ax.c (gdb_eval_agent_expr): Return expr_eval_unhandled_opcode
10310 instead of literal 1.
10311
10312 2015-08-21 Pedro Alves <palves@redhat.com>
10313
10314 * tdesc.c (default_description): Explicitly zero-initialize.
10315
10316 2015-08-21 Pedro Alves <palves@redhat.com>
10317
10318 PR gdb/18749
10319 * inferiors.c (remove_thread): Discard any pending stop reply for
10320 this thread.
10321 * server.c (remove_all_on_match_pid): Rename to ...
10322 (remove_all_on_match_ptid): ... this. Work with a filter ptid
10323 instead of a pid.
10324 (discard_queued_stop_replies): Change parameter to a ptid. Now
10325 extern.
10326 (handle_v_kill, kill_inferior_callback, captured_main)
10327 (process_serial_event): Adjust.
10328 * server.h (discard_queued_stop_replies): Declare.
10329
10330 2015-08-21 Pedro Alves <palves@redhat.com>
10331
10332 * linux-low.c (wait_for_sigstop): Always switch to no thread
10333 selected if the previously current thread dies.
10334 * lynx-low.c (lynx_request_interrupt): Use the first thread's
10335 process instead of the current thread's.
10336 * remote-utils.c (input_interrupt): Don't check if there's no
10337 current thread.
10338 * server.c (gdb_read_memory, gdb_write_memory): If setting the
10339 current thread to the general thread fails, error out.
10340 (handle_qxfer_auxv, handle_qxfer_libraries)
10341 (handle_qxfer_libraries_svr4, handle_qxfer_siginfo)
10342 (handle_qxfer_spu, handle_qxfer_statictrace, handle_qxfer_fdpic)
10343 (handle_query): Check if there's a thread selected instead of
10344 checking whether there's any thread in the thread list.
10345 (handle_qxfer_threads, handle_qxfer_btrace)
10346 (handle_qxfer_btrace_conf): Don't error out early if there's no
10347 thread in the thread list.
10348 (handle_v_cont, myresume): Don't set the current thread to the
10349 continue thread.
10350 (process_serial_event) <Hg handling>: Also set thread_id if the
10351 previous general thread is still alive.
10352 (process_serial_event) <g/G handling>: If setting the current
10353 thread to the general thread fails, error out.
10354 * spu-low.c (spu_resume, spu_request_interrupt): Use the first
10355 thread's lwp instead of the current thread's.
10356 * target.c (set_desired_thread): If the desired thread was not
10357 found, leave the current thread pointing to NULL. Return an int
10358 (boolean) indicating success.
10359 * target.h (set_desired_thread): Change return type to int.
10360
10361 2015-08-20 Max Filippov <jcmvbkbc@gmail.com>
10362
10363 * configure.srv (xtensa*-*-linux*): Add srv_linux_thread_db=yes.
10364 * linux-xtensa-low.c (arch/xtensa.h gdb_proc_service.h): New
10365 #includes.
10366 (ps_get_thread_area): New function.
10367
10368 2015-08-19 Gary Benson <gbenson@redhat.com>
10369
10370 * hostio.c (handle_pread): Do not attempt to read more data
10371 than hostio_reply_with_data can fit in a packet.
10372
10373 2015-08-18 Joel Brobecker <brobecker@adacore.com>
10374
10375 * linux-aarch32-low.c (NT_ARM_VFP): Define if not already defined.
10376
10377 2015-08-14 Matthew Fortune <matthew.fortune@imgtec.com>
10378
10379 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP_REL.
10380
10381 2015-08-06 Pedro Alves <palves@redhat.com>
10382
10383 * tracepoint.c (expr_eval_result): Now an int.
10384
10385 2015-08-06 Pedro Alves <palves@redhat.com>
10386
10387 * gdbthread.h (struct regcache): Forward declare.
10388 (struct thread_info) <regcache_data>: Now a struct regcache
10389 pointer.
10390 * inferiors.c (inferior_regcache_data)
10391 (set_inferior_regcache_data): Now work with struct regcache
10392 pointers.
10393 * inferiors.h (struct regcache): Forward declare.
10394 (inferior_regcache_data, set_inferior_regcache_data): Now work
10395 with struct regcache pointers.
10396 * regcache.c (get_thread_regcache, regcache_invalidate_thread)
10397 (free_register_cache_thread): Remove struct regcache pointer
10398 casts.
10399
10400 2015-08-06 Pedro Alves <palves@redhat.com>
10401
10402 * server.c (captured_main): On error, print the exception message
10403 to stderr, and if run_once is set, throw a quit.
10404
10405 2015-08-06 Pedro Alves <palves@redhat.com>
10406
10407 * linux-low.c (move_out_of_jump_pad_callback): Temporarily switch
10408 the current thread.
10409
10410 2015-08-06 Pedro Alves <palves@redhat.com>
10411
10412 * linux-low.c (linux_write_memory): Rewrite debug output to avoid
10413 reading beyond the passed in buffer length.
10414
10415 2015-08-06 Pierre Langlois <pierre.langlois@arm.com>
10416
10417 * tracepoint.c (symbol_list) <required>: Remove.
10418
10419 2015-08-06 Pedro Alves <palves@redhat.com>
10420
10421 * linux-low.c (handle_extended_wait): Set the fork child's suspend
10422 count if stopping and suspending threads.
10423 (check_stopped_by_breakpoint): If stopped by trace, set the LWP's
10424 stop reason to TARGET_STOPPED_BY_SINGLE_STEP.
10425 (linux_detach): Complete an ongoing step-over.
10426 (lwp_suspended_inc, lwp_suspended_decr): New functions. Use
10427 throughout.
10428 (resume_stopped_resumed_lwps): Don't resume a suspended thread.
10429 (linux_wait_1): If passing a signal to the inferior after
10430 finishing a step-over, unsuspend and re-resume all lwps. If we
10431 see a single-step event but the thread should be continuing, don't
10432 pass the trap to gdb.
10433 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback): Use
10434 internal_error instead of gdb_assert.
10435 (enqueue_pending_signal): New function.
10436 (check_ptrace_stopped_lwp_gone): Add debug output.
10437 (start_step_over): Use internal_error instead of gdb_assert.
10438 (complete_ongoing_step_over): New function.
10439 (linux_resume_one_thread): Don't resume a suspended thread.
10440 (proceed_one_lwp): If the LWP is stepping over a breakpoint, reset
10441 it stepping.
10442
10443 2015-08-06 Pedro Alves <palves@redhat.com>
10444
10445 * linux-low.c (add_lwp): Set waitstatus to TARGET_WAITKIND_IGNORE.
10446 (linux_thread_alive): Use lwp_is_marked_dead.
10447 (extended_event_reported): Delete.
10448 (linux_wait_1): Check if waitstatus is TARGET_WAITKIND_IGNORE
10449 instead of extended_event_reported.
10450 (mark_lwp_dead): Don't set the 'dead' flag. Store the waitstatus
10451 as well.
10452 (lwp_is_marked_dead): New function.
10453 (lwp_running): Use lwp_is_marked_dead.
10454 * linux-low.h: Delete 'dead' field, and update 'waitstatus's
10455 comment.
10456
10457 2015-08-06 Pedro Alves <palves@redhat.com>
10458
10459 * linux-low.c (linux_wait_1): Move fork event output out of the
10460 !report_to_gdb check. Pass event_child->waitstatus to
10461 target_waitstatus_to_string instead of ourstatus.
10462
10463 2015-08-04 Yao Qi <yao.qi@linaro.org>
10464
10465 * linux-aarch64-low.c (aarch64_supports_tracepoints): Return 0
10466 if current_thread is 32 bit.
10467
10468 2015-08-04 Yao Qi <yao.qi@linaro.org>
10469
10470 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
10471 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
10472 * server.c (extended_protocol): Remove "static".
10473 * server.h (extended_protocol): Declare it.
10474
10475 2015-08-04 Yao Qi <yao.qi@linaro.org>
10476
10477 * linux-aarch64-low.c (aarch64_get_pc): Get PC register on
10478 both aarch64 and aarch32.
10479 (aarch64_set_pc): Likewise.
10480
10481 2015-08-04 Yao Qi <yao.qi@linaro.org>
10482
10483 * configure.srv (case aarch64*-*-linux*): Append arm-with-neon.o
10484 to srv_regobj and append arm-core.xml arm-vfpv3.xml and
10485 arm-with-neon.xml to srv_xmlfiles.
10486 * linux-aarch64-low.c: Include linux-aarch32-low.h.
10487 (is_64bit_tdesc): New function.
10488 (aarch64_linux_read_description): New function.
10489 (aarch64_arch_setup): Call aarch64_linux_read_description.
10490 (regs_info): Rename to regs_info_aarch64.
10491 (aarch64_regs_info): Return right regs_info.
10492 (initialize_low_arch): Call initialize_low_arch_aarch32.
10493
10494 2015-08-04 Yao Qi <yao.qi@linaro.org>
10495
10496 * configure.srv (srv_tgtobj): Add linux-aarch32-low.o.
10497 * linux-aarch32-low.c: New file.
10498 * linux-aarch32-low.h: New file.
10499 * linux-arm-low.c (arm_fill_gregset): Move it to
10500 linux-aarch32-low.c.
10501 (arm_store_gregset): Likewise.
10502 (arm_fill_vfpregset): Call arm_fill_vfpregset_num
10503 (arm_store_vfpregset): Call arm_store_vfpregset_num.
10504 (arm_arch_setup): Check if PTRACE_GETREGSET works.
10505 (regs_info): Rename to regs_info_arm.
10506 (arm_regs_info): Return regs_info_aarch32 if
10507 have_ptrace_getregset is 1 and target description is
10508 arm_with_neon or arm_with_vfpv3.
10509 (initialize_low_arch): Don't call init_registers_arm_with_neon.
10510 Call initialize_low_arch_aarch32 instead.
10511
10512 2015-08-04 Yao Qi <yao.qi@linaro.org>
10513
10514 * linux-x86-low.c (have_ptrace_getregset): Move it to ...
10515 * linux-low.c: ... here.
10516 * linux-low.h (have_ptrace_getregset): Declare it.
10517
10518 2015-08-04 Pedro Alves <palves@redhat.com>
10519
10520 * thread-db.c (struct thread_db): Use new typedefs.
10521 (try_thread_db_load_1): Define local TDB_DLSYM macro and use it in
10522 CHK calls.
10523 (disable_thread_event_reporting): Cast result of dlsym to
10524 destination function pointer type.
10525 (thread_db_mourn): Use td_ta_delete_ftype.
10526
10527 2015-08-03 Sandra Loosemore <sandra@codesourcery.com>
10528
10529 * linux-nios2-low.c (NIOS2_BREAKPOINT): Conditionalize for
10530 arch variant.
10531 (CDX_BREAKPOINT): Define for R2.
10532 (nios2_breakpoint_at): Check for CDX_BREAKPOINT when R2.
10533 (the_low_target): Add comments.
10534
10535 2015-07-30 Yao Qi <yao.qi@linaro.org>
10536
10537 * linux-arm-low.c (arm_hwcap): Remove it.
10538 (arm_read_description): New local variable arm_hwcap. Don't
10539 set arm_hwcap to zero.
10540
10541 2015-07-30 Yao Qi <yao.qi@linaro.org>
10542
10543 * linux-arm-low.c (arm_fill_wmmxregset): Don't use arm_hwcap.
10544 Use regcache->tdesc instead.
10545 (arm_store_wmmxregset): Likewise.
10546 (arm_fill_vfpregset): Likewise.
10547 (arm_store_vfpregset): Likewise.
10548
10549 2015-07-30 Yao Qi <yao.qi@linaro.org>
10550
10551 * linux-arm-low.c: Include arch/arm.h.
10552 (arm_fill_gregset): Don't use arm_num_regs and arm_regmap.
10553 (arm_store_gregset): Likewise.
10554
10555 2015-07-29 Simon Marchi <simon.marchi@ericsson.com>
10556
10557 * linux-mips-low.c (mips_linux_prepare_to_resume): Add NULL as
10558 ptrace's 4th parameter.
10559
10560 2015-07-27 Yao Qi <yao.qi@linaro.org>
10561
10562 * configure.srv (case aarch64*-*-linux*): Don't set
10563 srv_linux_usrregs.
10564
10565 2015-07-24 Pedro Alves <palves@redhat.c: Likewise.om>
10566
10567 * linux-aarch64-low.c: Include nat/gdb_ptrace.h instead of
10568 sys/ptrace.h.
10569 * linux-arm-low.c: Likewise.
10570 * linux-cris-low.c: Likewise.
10571 * linux-crisv32-low.c: Likewise.
10572 * linux-low.c: Likewise.
10573 * linux-m68k-low.c: Likewise.
10574 * linux-mips-low.c: Likewise.
10575 * linux-nios2-low.c: Likewise.
10576 * linux-s390-low.c: Likewise.
10577 * linux-sparc-low.c: Likewise.
10578 * linux-tic6x-low.c: Likewise.
10579 * linux-tile-low.c: Likewise.
10580 * linux-x86-low.c: Likewise.
10581
10582 2015-07-24 Pedro Alves <palves@redhat.com>
10583
10584 * config.in: Regenerate.
10585 * configure: Regenerate.
10586
10587 2015-07-24 Pedro Alves <palves@redhat.com>
10588
10589 * acinclude.m4: Include ../ptrace.m4.
10590 * configure.ac: Call GDB_AC_PTRACE.
10591 * config.in, configure: Regenerate.
10592
10593 2015-07-24 Yao Qi <yao.qi@linaro.org>
10594
10595 * linux-low.c (linux_create_inferior): Remove setting to
10596 proc->priv->new_inferior.
10597 (linux_attach): Likewise.
10598 (linux_low_filter_event): Likewise.
10599 * linux-low.h (struct process_info_private) <new_inferior>: Remove.
10600
10601 2015-07-24 Yao Qi <yao.qi@linaro.org>
10602
10603 * linux-low.c (linux_arch_setup): New function.
10604 (linux_low_filter_event): If proc->tdesc is NULL and
10605 proc->attached is true, call the_low_target.arch_setup.
10606 Otherwise, keep status pending, and return.
10607 (linux_resume_one_lwp_throw): Don't call get_pc if
10608 thread->while_stepping isn't NULL. Don't call
10609 get_thread_regcache if proc->tdesc is NULL.
10610 (need_step_over_p): Return 0 if proc->tdesc is NULL.
10611 (linux_target_ops): Install arch_setup.
10612 * server.c (start_inferior): Call the_target->arch_setup.
10613 * target.h (struct target_ops) <arch_setup>: New field.
10614 (target_arch_setup): New marco.
10615 * lynx-low.c (lynx_target_ops): Update.
10616 * nto-low.c (nto_target_ops): Update.
10617 * spu-low.c (spu_target_ops): Update.
10618 * win32-low.c (win32_target_ops): Update.
10619
10620 2015-07-24 Yao Qi <yao.qi@linaro.org>
10621
10622 * linux-low.c (linux_add_process): Don't set
10623 proc->priv->new_inferior.
10624 (linux_create_inferior): Set proc->priv->new_inferior to 1.
10625 (linux_attach): Likewise.
10626
10627 2015-07-24 Yao Qi <yao.qi@linaro.org>
10628
10629 * server.c (start_inferior): Code refactor.
10630
10631 2015-07-24 Yao Qi <yao.qi@linaro.org>
10632
10633 * server.c (process_serial_event): Set general_thread.
10634
10635 2015-07-21 Yao Qi <yao.qi@linaro.org>
10636
10637 * linux-aarch64-low.c (aarch64_arch_setup): Remove code and call
10638 aarch64_linux_get_debug_reg_capacity.
10639
10640 2015-07-17 Yao Qi <yao.qi@linaro.org>
10641
10642 * Makefile.in (aarch64-linux-hw-point.o): New rule.
10643 * configure.srv (srv_tgtobj): Append aarch64-linux-hw-point.o.
10644 * linux-aarch64-low.c: Include nat/aarch64-linux-hw-point.h.
10645 (AARCH64_HBP_MAX_NUM): Move to nat/aarch64-linux-hw-point.h.
10646 (AARCH64_HWP_MAX_NUM, AARCH64_HBP_ALIGNMENT): Likewise.
10647 (AARCH64_HWP_ALIGNMENT): Likewise.
10648 (AARCH64_HWP_MAX_LEN_PER_REG): Likewise.
10649 (AARCH64_DEBUG_NUM_SLOTS, AARCH64_DEBUG_ARCH): Likewise.
10650 (aarch64_num_bp_regs, aarch64_num_wp_regs): Likewise.
10651 (AARCH64_DEBUG_ARCH_V8, DR_MARK_ALL_CHANGED): Likewise.
10652 (DR_MARK_N_CHANGED, DR_CLEAR_CHANGED): Likewise.
10653 (DR_HAS_CHANGED, DR_N_HAS_CHANGE): Likewise.
10654 (struct aarch64_debug_reg_state): Likewise.
10655 (struct arch_lwp_info): Likewise.
10656 (aarch64_align_watchpoint): Likewise.
10657 (DR_CONTROL_ENABLED, DR_CONTROL_LENGTH): Likewise.
10658 (aarch64_watchpoint_length): Likewise.
10659 (aarch64_point_encode_ctrl_reg): Likewise
10660 (aarch64_point_is_aligned): Likewise.
10661 (aarch64_align_watchpoint): Likewise.
10662 (aarch64_linux_set_debug_regs):
10663 (aarch64_dr_state_insert_one_point): Likewise.
10664 (aarch64_dr_state_remove_one_point): Likewise.
10665 (aarch64_handle_breakpoint): Likewise.
10666 (aarch64_handle_aligned_watchpoint): Likewise.
10667 (aarch64_handle_unaligned_watchpoint): Likewise.
10668 (aarch64_handle_watchpoint): Likewise.
10669
10670 2015-07-17 Yao Qi <yao.qi@linaro.org>
10671
10672 * linux-aarch64-low.c (aarch64_handle_breakpoint): Add argument state
10673 and don't aarch64_get_debug_reg_state. All callers update.
10674 (aarch64_handle_aligned_watchpoint): Likewise.
10675 (aarch64_handle_unaligned_watchpoint): Likewise.
10676 (aarch64_handle_watchpoint): Likewise.
10677 (aarch64_insert_point): Call aarch64_get_debug_reg_state earlier.
10678 (aarch64_remove_point): Likewise.
10679
10680 2015-07-17 Yao Qi <yao.qi@linaro.org>
10681
10682 * linux-aarch64-low.c (aarch64_show_debug_reg_state): Use
10683 debug_printf.
10684 (aarch64_handle_unaligned_watchpoint): Likewise.
10685
10686 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
10687
10688 Revert the previous 3 commits:
10689 Move gdb_regex* to common/
10690 Move linux_find_memory_regions_full & co.
10691 gdbserver build-id attribute generator
10692
10693 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
10694 Jan Kratochvil <jan.kratochvil@redhat.com>
10695
10696 gdbserver build-id attribute generator.
10697 * linux-low.c (nat/linux-maps.h, search.h, rsp-low.h): Include.
10698 (ElfXX_Ehdr, ElfXX_Phdr, ElfXX_Nhdr): New.
10699 (ELFXX_FLD, ELFXX_SIZEOF, ELFXX_ROUNDUP, BUILD_ID_INVALID): New.
10700 (find_phdr): New.
10701 (get_dynamic): Use find_pdhr to traverse program headers.
10702 (struct mapping_entry, mapping_entry_s, free_mapping_entry_vec)
10703 (compare_mapping_entry_range, struct find_memory_region_callback_data)
10704 (read_build_id, find_memory_region_callback, lrfind_mapping_entry)
10705 (get_hex_build_id): New.
10706 (linux_qxfer_libraries_svr4): Add optional build-id attribute
10707 to reply XML document.
10708
10709 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
10710 Jan Kratochvil <jan.kratochvil@redhat.com>
10711
10712 * target.c: Include target/target-utils.h and fcntl.h.
10713 (target_fileio_read_stralloc_1_pread, target_fileio_read_stralloc_1)
10714 (target_fileio_read_stralloc): New functions.
10715
10716 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
10717
10718 * Makefile.in (OBS): Add gdb_regex.o.
10719 (gdb_regex.o): New.
10720 * config.in: Rebuilt.
10721 * configure: Rebuilt.
10722
10723 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
10724 Jan Kratochvil <jan.kratochvil@redhat.com>
10725
10726 Create empty nat/linux-maps.[ch] and common/target-utils.[ch].
10727 * Makefile.in (OBS): Add target-utils.o.
10728 (linux-maps.o, target-utils.o): New.
10729 * configure.srv (srv_linux_obj): Add linux-maps.o.
10730
10731 2015-07-15 Pierre Langlois <pierre.langlois@arm.com>
10732
10733 * linux-aarch64-low.c (aarch64_supports_range_stepping): New
10734 function, return 1.
10735 (the_low_target): Install it.
10736
10737 2015-07-14 Pedro Alves <palves@redhat.com>
10738
10739 * linux-low.c (kill_wait_lwp): Don't assert if waitpid fails.
10740 Instead, ignore ECHILD, and throw an error for other errnos.
10741
10742 2015-07-10 Pedro Alves <palves@redhat.com>
10743
10744 * event-loop.c (struct callback_event) <data>: Change type to
10745 gdb_client_data instance instead of gdb_client_data pointer.
10746 (append_callback_event): Adjust.
10747
10748 2015-07-10 Pierre Langlois <pierre.langlois@arm.com>
10749
10750 * linux-aarch64-low.c: Add comments for each linux_target_ops
10751 method. Remove comments already covered in target_ops and
10752 linux_target_ops definitions.
10753 (the_low_target): Add comments for each unimplemented method.
10754
10755 2015-07-09 Yao Qi <yao.qi@linaro.org>
10756
10757 * linux-aarch64-low.c (aarch64_regmap): Remove.
10758 (aarch64_usrregs_info): Remove.
10759 (regs_info): Set field usrregs to NULL.
10760
10761 2015-07-02 Markus Metzger <markus.t.metzger@intel.com>
10762
10763 * linux-low.c: Include "rsp-low.h"
10764 (linux_low_encode_pt_config, linux_low_encode_raw): New.
10765 (linux_low_read_btrace): Support BTRACE_FORMAT_PT.
10766 (linux_low_btrace_conf): Support BTRACE_FORMAT_PT.
10767 (handle_btrace_enable_pt): New.
10768 (handle_btrace_general_set): Support "pt".
10769 (handle_btrace_conf_general_set): Support "pt:size".
10770
10771 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
10772
10773 * linux-aarch64-low.c (aarch64_supports_z_point_type): Enable for
10774 Z_PACKET_SW_BP.
10775
10776 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
10777
10778 * linux-aarch64-low.c: Remove comment about endianness.
10779 (aarch64_breakpoint): Change type to gdb_byte[]. Set to "brk #0".
10780 (aarch64_breakpoint_at): Change type of insn to gdb_byte[]. Use
10781 memcmp.
10782
10783 2015-06-24 Gary Benson <gbenson@redhat.com>
10784
10785 * linux-i386-ipa.c (stdint.h): Do not include.
10786 * lynx-i386-low.c (stdint.h): Likewise.
10787 * lynx-ppc-low.c (stdint.h): Likewise.
10788 * mem-break.c (stdint.h): Likewise.
10789 * thread-db.c (stdint.h): Likewise.
10790 * tracepoint.c (stdint.h): Likewise.
10791 * win32-low.c (stdint.h): Likewise.
10792
10793 2015-06-18 Simon Marchi <simon.marchi@ericsson.com>
10794
10795 * server.c (write_qxfer_response): Update call to
10796 remote_escape_output.
10797
10798 2015-06-15 Aleksandar Ristovski <aristovski@qnx.com
10799 Jan Kratochvil <jan.kratochvil@redhat.com>
10800
10801 Merge multiple hex conversions.
10802 * gdbreplay.c (tohex): Rename to 'fromhex'.
10803 (logchar): Use fromhex.
10804
10805 2015-06-10 Jan Kratochvil <jan.kratochvil@redhat.com>
10806
10807 * server.c (handle_qxfer_libraries): Set `version' attribute for
10808 <library-list>.
10809
10810 2015-06-10 Gary Benson <gbenson@redhat.com>
10811
10812 * target.h (struct target_ops) <multifs_open>: New field.
10813 <multifs_unlink>: Likewise.
10814 <multifs_readlink>: Likewise.
10815 * linux-low.c (nat/linux-namespaces.h): New include.
10816 (linux_target_ops): Initialize the_target->multifs_open,
10817 the_target->multifs_unlink and the_target->multifs_readlink.
10818 * hostio.h (hostio_handle_new_gdb_connection): New declaration.
10819 * hostio.c (hostio_fs_pid): New static variable.
10820 (hostio_handle_new_gdb_connection): New function.
10821 (handle_setfs): Likewise.
10822 (handle_open): Use the_target->multifs_open as appropriate.
10823 (handle_unlink): Use the_target->multifs_unlink as appropriate.
10824 (handle_readlink): Use the_target->multifs_readlink as
10825 appropriate.
10826 (handle_vFile): Handle vFile:setfs packets.
10827 * server.c (handle_query): Call hostio_handle_new_gdb_connection
10828 after target_handle_new_gdb_connection.
10829
10830 2015-06-10 Gary Benson <gbenson@redhat.com>
10831
10832 * configure.ac (AC_CHECK_FUNCS): Add setns.
10833 * config.in: Regenerate.
10834 * configure: Likewise.
10835 * Makefile.in (SFILES): Add nat/linux-namespaces.c.
10836 (linux-namespaces.o): New rule.
10837 * configure.srv (srv_linux_obj): Add linux-namespaces.o.
10838
10839 2015-06-09 Gary Benson <gbenson@redhat.com>
10840
10841 * hostio.c (handle_open): Process mode argument with
10842 fileio_to_host_mode.
10843
10844 2015-06-01 Yao Qi <yao.qi@linaro.org>
10845
10846 * linux-s390-low.c (PTRACE_GETREGSET, PTRACE_SETREGSET): Remove.
10847 * linux-x86-low.c: Likewise.
10848
10849 2015-05-28 Don Breazeal <donb@codesourcery.com>
10850
10851 * linux-low.c (handle_extended_wait): Initialize
10852 thread_info.last_resume_kind for new fork children.
10853
10854 2015-05-15 Pedro Alves <palves@redhat.com>
10855
10856 * target.h (target_handle_new_gdb_connection): Rewrite using if
10857 wrapped in do/while.
10858
10859 2015-05-14 Joel Brobecker <brobecker@adacore.com>
10860
10861 * configure.ac: Add prfpregset_t BFD_HAVE_SYS_PROCFS_TYPE check.
10862 * configure, config.in: Regenerate.
10863 * gdb_proc_service.h [HAVE_PRFPREGSET_T] (prfpregset_t):
10864 Declare typedef.
10865
10866 2015-05-12 Don Breazeal <donb@codesourcery.com>
10867
10868 * linux-low.c (handle_extended_wait): Handle PTRACE_EVENT_FORK and
10869 PTRACE_EVENT_VFORK_DONE.
10870 (linux_low_ptrace_options, extended_event_reported): Add vfork
10871 events.
10872 * remote-utils.c (prepare_resume_reply): New stop reasons "vfork"
10873 and "vforkdone" for RSP 'T' Stop Reply Packet.
10874 * server.h (report_vfork_events): Declare
10875 global variable.
10876
10877 2015-05-12 Don Breazeal <donb@codesourcery.com>
10878
10879 * linux-aarch64-low.c (aarch64_linux_new_fork): New function.
10880 (the_low_target) <new_fork>: Initialize new member.
10881 * linux-arm-low.c (arm_new_fork): New function.
10882 (the_low_target) <new_fork>: Initialize new member.
10883 * linux-low.c (handle_extended_wait): Call new target function
10884 new_fork.
10885 * linux-low.h (struct linux_target_ops) <new_fork>: New member.
10886 * linux-mips-low.c (mips_add_watchpoint): New function
10887 extracted from mips_insert_point.
10888 (the_low_target) <new_fork>: Initialize new member.
10889 (mips_linux_new_fork): New function.
10890 (mips_insert_point): Call mips_add_watchpoint.
10891 * linux-x86-low.c (x86_linux_new_fork): New function.
10892 (the_low_target) <new_fork>: Initialize new member.
10893
10894 2015-05-12 Don Breazeal <donb@codesourcery.com>
10895
10896 * linux-low.c (handle_extended_wait): Implement return value,
10897 rename argument 'event_child' to 'event_lwp', handle
10898 PTRACE_EVENT_FORK, call internal_error for unrecognized event.
10899 (linux_low_ptrace_options): New function.
10900 (linux_low_filter_event): Call linux_low_ptrace_options,
10901 use different argument fo linux_enable_event_reporting,
10902 use return value from handle_extended_wait.
10903 (extended_event_reported): New function.
10904 (linux_wait_1): Call extended_event_reported and set
10905 status to report fork events.
10906 (linux_write_memory): Add pid to debug message.
10907 (reset_lwp_ptrace_options_callback): New function.
10908 (linux_handle_new_gdb_connection): New function.
10909 (linux_target_ops): Initialize new structure member.
10910 * linux-low.h (struct lwp_info) <waitstatus>: New member.
10911 * lynx-low.c: Initialize new structure member.
10912 * remote-utils.c (prepare_resume_reply): Implement stop reason
10913 "fork" for "T" stop message.
10914 * server.c (handle_query): Call handle_new_gdb_connection.
10915 * server.h (report_fork_events): Declare global flag.
10916 * target.h (struct target_ops) <handle_new_gdb_connection>:
10917 New member.
10918 (target_handle_new_gdb_connection): New macro.
10919 * win32-low.c: Initialize new structure member.
10920
10921 2015-05-12 Don Breazeal <donb@codesourcery.com>
10922
10923 * mem-break.c (APPEND_TO_LIST): Define macro.
10924 (clone_agent_expr): New function.
10925 (clone_one_breakpoint): New function.
10926 (clone_all_breakpoints): New function.
10927 * mem-break.h: Declare new functions.
10928
10929 2015-05-12 Don Breazeal <donb@codesourcery.com>
10930
10931 * linux-low.c (linux_supports_fork_events): New function.
10932 (linux_supports_vfork_events): New function.
10933 (linux_target_ops): Initialize new structure members.
10934 (initialize_low): Call linux_check_ptrace_features.
10935 * lynx-low.c (lynx_target_ops): Initialize new structure
10936 members.
10937 * server.c (report_fork_events, report_vfork_events):
10938 New global flags.
10939 (handle_query): Add new features to qSupported packet and
10940 response.
10941 (captured_main): Initialize new global variables.
10942 * target.h (struct target_ops) <supports_fork_events>:
10943 New member.
10944 <supports_vfork_events>: New member.
10945 (target_supports_fork_events): New macro.
10946 (target_supports_vfork_events): New macro.
10947 * win32-low.c (win32_target_ops): Initialize new structure
10948 members.
10949
10950 2015-05-12 Gary Benson <gbenson@redhat.com>
10951
10952 * server.c (handle_qxfer_exec_file): Use current process
10953 if annex is empty.
10954
10955 2015-05-08 Sandra Loosemore <sandra@codesourcery.com>
10956
10957 * linux-nios2-low.c: Include elf/common.h. Adjust comments.
10958 Remove HAVE_PTRACE_GETREGS conditionals.
10959 (nios2_regsets): Use PTRACE_GETREGSET and PTRACE_SETREGSET
10960 instead of PTRACE_GETREGS and PTRACE_SETREGS.
10961
10962 2015-05-08 Yao Qi <yao.qi@linaro.org>
10963
10964 * linux-low.c (linux_supports_conditional_breakpoints): New
10965 function.
10966 (linux_target_ops): Install new target method.
10967 * lynx-low.c (lynx_target_ops): Install NULL hook for
10968 supports_conditional_breakpoints.
10969 * nto-low.c (nto_target_ops): Likewise.
10970 * spu-low.c (spu_target_ops): Likewise.
10971 * win32-low.c (win32_target_ops): Likewise.
10972 * server.c (handle_query): Check
10973 target_supports_conditional_breakpoints.
10974 * target.h (struct target_ops) <supports_conditional_breakpoints>:
10975 New field.
10976 (target_supports_conditional_breakpoints): New macro.
10977
10978 2015-05-06 Pedro Alves <palves@redhat.com>
10979
10980 PR server/18081
10981 * server.c (start_inferior): If the process exits, mourn it.
10982
10983 2015-04-21 Gary Benson <gbenson@redhat.com>
10984
10985 * hostio.c (fileio_open_flags_to_host): Factored out to
10986 fileio_to_host_openflags in common/fileio.c. Single use
10987 updated.
10988
10989 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
10990
10991 * linux-xtensa-low.c (xtensa_fill_gregset)
10992 (xtensa_store_gregset): Check XCHAL_HAVE_LOOPS instead of
10993 XCHAL_HAVE_LOOP.
10994
10995 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
10996
10997 * linux-xtensa-low.c (xtensa_usrregs_info): Remove.
10998 (regs_info): Replace usrregs pointer with NULL.
10999
11000 2015-04-17 Gary Benson <gbenson@redhat.com>
11001
11002 * target.h (struct target_ops) <pid_to_exec_file>: New field.
11003 * linux-low.c (linux_target_ops): Initialize pid_to_exec_file.
11004 * server.c (handle_qxfer_exec_file): New function.
11005 (qxfer_packets): Add exec-file entry.
11006 (handle_query): Report qXfer:exec-file:read as supported packet.
11007
11008 2015-04-14 Romain Naour <romain.naour@openwide.fr> (tiny change)
11009
11010 * linux-low.c (linux_read_offsets): Remove get_thread_lwp.
11011
11012 2015-04-09 Gary Benson <gbenson@redhat.com>
11013
11014 * hostio-errno.c (errno_to_fileio_error): Remove function.
11015 Update caller to use remote_fileio_to_fio_error.
11016
11017 2015-04-09 Yao Qi <yao.qi@linaro.org>
11018
11019 * linux-low.c (linux_insert_point): Call
11020 insert_memory_breakpoint if TYPE is raw_bkpt_type_sw.
11021 (linux_remove_point): Call remove_memory_breakpoint if type is
11022 raw_bkpt_type_sw.
11023 * linux-x86-low.c (x86_insert_point): Don't call
11024 insert_memory_breakpoint.
11025 (x86_remove_point): Don't call remove_memory_breakpoint.
11026
11027 2015-04-01 Pedro Alves <palves@redhat.com>
11028 Cleber Rosa <crosa@redhat.com>
11029
11030 * server.c (gdbserver_usage): Reorganize and extend the usage
11031 message.
11032
11033 2015-03-24 Pedro Alves <palves@redhat.com>
11034
11035 * linux-low.c (check_stopped_by_breakpoint): Tweak debug log
11036 output. Also dump TRAP_TRACE.
11037 (linux_low_filter_event): In debug output, distinguish a
11038 resume_stop SIGSTOP from a delayed SIGSTOP.
11039
11040 2015-03-24 Gary Benson <gbenson@redhat.com>
11041
11042 * linux-x86-low.c (x86_linux_new_thread): Moved to
11043 nat/x86-linux.c.
11044 (x86_linux_prepare_to_resume): Likewise.
11045
11046 2015-03-24 Gary Benson <gbenson@redhat.com>
11047
11048 * Makefile.in (x86-linux-dregs.o): New rule.
11049 * configure.srv: Add x86-linux-dregs.o to relevant targets.
11050 * linux-x86-low.c: Include nat/x86-linux-dregs.h.
11051 (u_debugreg_offset): Moved to nat/x86-linux-dregs.c.
11052 (x86_linux_dr_get): Likewise.
11053 (x86_linux_dr_set): Likewise.
11054 (update_debug_registers_callback): Likewise.
11055 (x86_linux_dr_set_addr): Likewise.
11056 (x86_linux_dr_get_addr): Likewise.
11057 (x86_linux_dr_set_control): Likewise.
11058 (x86_linux_dr_get_control): Likewise.
11059 (x86_linux_dr_get_status): Likewise.
11060 (x86_linux_update_debug_registers): Likewise.
11061
11062 2015-03-24 Gary Benson <gbenson@redhat.com>
11063
11064 * linux-x86-low.c (x86_linux_update_debug_registers):
11065 New function, factored out from...
11066 (x86_linux_prepare_to_resume): ...this.
11067
11068 2015-03-24 Gary Benson <gbenson@redhat.com>
11069
11070 * linux-x86-low.c (x86_linux_dr_get): Update comments.
11071 (x86_linux_dr_set): Likewise.
11072 (update_debug_registers_callback): Likewise.
11073 (x86_linux_dr_set_addr): Likewise.
11074 (x86_linux_dr_get_addr): Likewise.
11075 (x86_linux_dr_set_control): Likewise.
11076 (x86_linux_dr_get_control): Likewise.
11077 (x86_linux_dr_get_status): Likewise.
11078 (x86_linux_prepare_to_resume): Likewise.
11079
11080 2015-03-24 Gary Benson <gbenson@redhat.com>
11081
11082 * linux-x86-low.c (x86_linux_dr_get): Add assertion.
11083 Use perror_with_name. Pass string through gettext.
11084 (x86_linux_dr_set): Likewise.
11085
11086 2015-03-24 Gary Benson <gbenson@redhat.com>
11087
11088 * linux-x86-low.c (x86_dr_low_set_addr): Rename to...
11089 (x86_linux_dr_set_addr): ...this.
11090 (x86_dr_low_get_addr): Rename to...
11091 (x86_linux_dr_get_addr): ...this.
11092 (x86_dr_low_set_control): Rename to...
11093 (x86_linux_dr_set_control): ...this.
11094 (x86_dr_low_get_control): Rename to...
11095 (x86_linux_dr_get_control): ...this.
11096 (x86_dr_low_get_status): Rename to...
11097 (x86_linux_dr_get_status): ...this.
11098 (x86_dr_low): Update with new function names.
11099
11100 2015-03-24 Gary Benson <gbenson@redhat.com>
11101
11102 * Makefile.in (x86-linux.o): New rule.
11103 * configure.srv: Add x86-linux.o to relevant targets.
11104 * linux-low.c (lwp_set_arch_private_info): New function.
11105 (lwp_arch_private_info): Likewise.
11106 * linux-x86-low.c: Include nat/x86-linux.h.
11107 (arch_lwp_info): Removed structure.
11108 (update_debug_registers_callback):
11109 Use lwp_set_debug_registers_changed.
11110 (x86_linux_prepare_to_resume): Use lwp_debug_registers_changed
11111 and lwp_set_debug_registers_changed.
11112 (x86_linux_new_thread): Use lwp_set_debug_registers_changed.
11113
11114 2015-03-24 Gary Benson <gbenson@redhat.com>
11115
11116 * linux-low.h (linux_target_ops) <new_thread>: Changed signature.
11117 * linux-arm-low.c (arm_new_thread): Likewise.
11118 * linux-aarch64-low.c (aarch64_linux_new_thread): Likewise.
11119 * linux-mips-low.c (mips_linux_new_thread): Likewise.
11120 * linux-x86-low.c (x86_linux_new_thread): Likewise.
11121 * linux-low.c (add_lwp): Update the_low_target.new_thread call.
11122
11123 2015-03-24 Gary Benson <gbenson@redhat.com>
11124
11125 * linux-low.c (ptid_of_lwp): New function.
11126 (lwp_is_stopped): Likewise.
11127 (lwp_stop_reason): Likewise.
11128 * linux-x86-low.c (update_debug_registers_callback):
11129 Use lwp_is_stopped.
11130 (x86_linux_prepare_to_resume): Use ptid_of_lwp and
11131 lwp_stop_reason.
11132
11133 2015-03-24 Gary Benson <gbenson@redhat.com>
11134
11135 * linux-low.h (linux_stop_lwp): Remove declaration.
11136
11137 2015-03-24 Gary Benson <gbenson@redhat.com>
11138
11139 * linux-low.h: Include nat/linux-nat.h.
11140 * linux-low.c (iterate_over_lwps_args): New structure.
11141 (iterate_over_lwps_filter): New function.
11142 (iterate_over_lwps): Likewise.
11143 * linux-x86-low.c (update_debug_registers_callback):
11144 Update signature to what iterate_over_lwps expects.
11145 Remove PID check that iterate_over_lwps now performs.
11146 (x86_dr_low_set_addr): Use iterate_over_lwps.
11147 (x86_dr_low_set_control): Likewise.
11148
11149 2015-03-24 Gary Benson <gbenson@redhat.com>
11150
11151 * linux-x86-low.c (x86_debug_reg_state): New function.
11152 (x86_linux_prepare_to_resume): Use the above.
11153
11154 2015-03-24 Gary Benson <gbenson@redhat.com>
11155
11156 * linux-low.c (current_lwp_ptid): New function.
11157 * linux-x86-low.c: Include nat/linux-nat.h.
11158 (x86_dr_low_get_addr): Use current_lwp_ptid.
11159 (x86_dr_low_get_control): Likewise.
11160 (x86_dr_low_get_status): Likewise.
11161
11162 2015-03-20 Pedro Alves <palves@redhat.com>
11163
11164 * tracepoint.c (cmd_qtstatus): Make "str" const.
11165
11166 2015-03-20 Pedro Alves <palves@redhat.com>
11167
11168 * server.c (handle_general_set): Make "req_str" const.
11169
11170 2015-03-19 Pedro Alves <palves@redhat.com>
11171
11172 * linux-low.c (linux_resume_one_lwp): Rename to ...
11173 (linux_resume_one_lwp_throw): ... this. Don't handle ESRCH here,
11174 instead call perror_with_name.
11175 (check_ptrace_stopped_lwp_gone): New function.
11176 (linux_resume_one_lwp): Reimplement as wrapper around
11177 linux_resume_one_lwp_throw that swallows errors if the LWP is
11178 gone.
11179
11180 2015-03-19 Pedro Alves <palves@redhat.com>
11181
11182 * linux-low.c (count_events_callback, select_event_lwp_callback):
11183 No longer check whether the thread has resume_stop as last resume
11184 kind.
11185
11186 2015-03-19 Pedro Alves <palves@redhat.com>
11187
11188 * linux-low.c (count_events_callback, select_event_lwp_callback):
11189 Use the lwp's status_pending_p field, not the thread's.
11190
11191 2015-03-19 Pedro Alves <palves@redhat.com>
11192
11193 * linux-low.c (select_event_lwp_callback): Update comments to
11194 no longer mention SIGTRAP.
11195
11196 2015-03-18 Gary Benson <gbenson@redhat.com>
11197
11198 * server.c (handle_query): Do not report vFile:fstat as supported.
11199
11200 2015-03-11 Gary Benson <gbenson@redhat.com>
11201
11202 * hostio.c (sys/types.h): New include.
11203 (sys/stat.h): Likewise.
11204 (common-remote-fileio.h): Likewise.
11205 (handle_fstat): New function.
11206 (handle_vFile): Handle vFile:fstat packets.
11207
11208 2015-03-11 Gary Benson <gbenson@redhat.com>
11209
11210 * configure.ac (AC_CHECK_MEMBERS): Add checks for
11211 struct stat.st_blocks and struct stat.st_blksize.
11212 * configure: Regenerate.
11213 * config.in: Likewise.
11214 * Makefile.in (SFILES): Add common/common-remote-fileio.c.
11215 (OBS): Add common-remote-fileio.o.
11216 (common-remote-fileio.o): New rule.
11217
11218 2015-03-09 Pedro Alves <palves@redhat.com>
11219
11220 * tracepoint.c (gdb_agent_helper_thread): Cast '&sockaddr' to
11221 'struct sockaddr' pointer in 'accept' call.
11222
11223 2015-03-09 Pedro Alves <palves@redhat.com>
11224
11225 Revert:
11226 2015-03-07 Pedro Alves <palves@redhat.com>
11227 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
11228 or <winsock2.h> here. Instead include "gdb_socket.h".
11229 (remote_open): Use union gdb_sockaddr_u.
11230 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
11231 or <winsock2.h> here. Instead include "gdb_socket.h".
11232 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
11233 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
11234 or <sys/un.h>.
11235 (init_named_socket, gdb_agent_helper_thread): Use union
11236 gdb_sockaddr_u.
11237
11238 2015-03-07 Pedro Alves <palves@redhat.com>
11239
11240 * configure.ac (build_warnings): Move
11241 -Wdeclaration-after-statement to the C-specific set.
11242 * configure: Regenerate.
11243
11244 2015-03-07 Pedro Alves <palves@redhat.com>
11245
11246 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
11247 or <winsock2.h> here. Instead include "gdb_socket.h".
11248 (remote_open): Use union gdb_sockaddr_u.
11249 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
11250 or <winsock2.h> here. Instead include "gdb_socket.h".
11251 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
11252 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
11253 or <sys/un.h>.
11254 (init_named_socket, gdb_agent_helper_thread): Use union
11255 gdb_sockaddr_u.
11256
11257 2015-03-07 Pedro Alves <palves@redhat.com>
11258
11259 Adjust all callers of TRY_CATCH to use TRY/CATCH/END_CATCH
11260 instead.
11261
11262 2015-03-06 Yao Qi <yao.qi@linaro.org>
11263
11264 * linux-aarch64-low.c (aarch64_insert_point): Use
11265 show_debug_regs as a boolean.
11266 (aarch64_remove_point): Likewise.
11267
11268 2015-03-05 Pedro Alves <palves@redhat.com>
11269
11270 * lynx-low.c (lynx_target_ops): Install NULL hooks for
11271 stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
11272 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint.
11273 * nto-low.c (nto_target_ops): Likewise.
11274 * spu-low.c (spu_target_ops): Likewise.
11275 * win32-low.c (win32_target_ops): Likewise.
11276
11277 2015-03-04 Pedro Alves <palves@redhat.com>
11278
11279 * linux-low.c (check_stopped_by_breakpoint) [USE_SIGTRAP_SIGINFO]:
11280 Decide whether a breakpoint triggered based on the SIGTRAP's
11281 siginfo.si_code.
11282 (thread_still_has_status_pending_p) [USE_SIGTRAP_SIGINFO]: Don't check whether a
11283 breakpoint is inserted if relying on SIGTRAP's siginfo.si_code.
11284 (linux_low_filter_event): Check for breakpoints before checking
11285 watchpoints.
11286 (linux_wait_1): Don't re-increment the PC if relying on SIGTRAP's
11287 siginfo.si_code.
11288 (linux_stopped_by_sw_breakpoint)
11289 (linux_supports_stopped_by_sw_breakpoint)
11290 (linux_stopped_by_hw_breakpoint)
11291 (linux_supports_stopped_by_hw_breakpoint): New functions.
11292 (linux_target_ops): Install new target methods.
11293
11294 2015-03-04 Pedro Alves <palves@redhat.com>
11295
11296 * remote-utils.c (prepare_resume_reply): Report swbreak/hbreak.
11297 * server.c (swbreak_feature, hwbreak_feature): New globals.
11298 (handle_query) <qSupported>: Handle "swbreak+" and "hwbreak+".
11299 (captured_main): Clear swbreak_feature and hwbreak_feature.
11300 * server.h (swbreak_feature, hwbreak_feature): Declare.
11301 * target.h (struct target_ops) <stopped_by_sw_breakpoint,
11302 supports_stopped_by_sw_breakpoint, stopped_by_hw_breakpoint,
11303 supports_stopped_by_hw_breakpoint>: New fields.
11304 (target_supports_stopped_by_sw_breakpoint)
11305 (target_stopped_by_sw_breakpoint)
11306 (target_supports_stopped_by_hw_breakpoint)
11307 (target_stopped_by_hw_breakpoint): Declare.
11308
11309 2015-03-04 Pedro Alves <palves@redhat.com>
11310
11311 enum lwp_stop_reason -> enum target_stop_reason
11312 * linux-low.c (check_stopped_by_breakpoint): Adjust.
11313 (thread_still_has_status_pending_p, check_stopped_by_watchpoint)
11314 (linux_wait_1, stuck_in_jump_pad_callback)
11315 (move_out_of_jump_pad_callback, linux_resume_one_lwp)
11316 (linux_stopped_by_watchpoint):
11317 * linux-low.h (enum lwp_stop_reason): Delete.
11318 (struct lwp_info) <stop_reason>: Now an enum target_stop_reason.
11319 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
11320
11321 2015-03-04 Yao Qi <yao.qi@linaro.org>
11322
11323 * Makefile.in (SFILES): Add linux-aarch64-low.c.
11324
11325 2015-03-03 Gary Benson <gbenson@redhat.com>
11326
11327 * hostio.c (handle_vFile): Fix prefix lengths.
11328
11329 2015-03-03 Markus Metzger <markus.t.metzger@intel.com>
11330
11331 * linux-low.c (linux_low_enable_btrace): Do not overwrite non-zero
11332 ptr_bits.
11333
11334 2015-03-02 Andreas Arnez <arnez@linux.vnet.ibm.com>
11335
11336 * Makefile.in (s390-vx-linux64.c, s390-tevx-linux64.c)
11337 (s390x-vx-linux64.c, s390x-tevx-linux64.c): New rules.
11338 (clean): Add "rm -f" for above C files.
11339 * configure.srv (srv_regobj): Add s390-vx-linux64.o,
11340 s390-tevx-linux64.o, s390x-vx-linux64.o, and s390x-tevx-linux64.o.
11341 (srv_xmlfiles): Add s390-vx-linux64.xml, s390-tevx-linux64.xml,
11342 s390x-vx-linux64.xml, s390x-tevx-linux64.xml, and s390-vx.xml.
11343 * linux-s390-low.c (HWCAP_S390_VX): New macro.
11344 (init_registers_s390_vx_linux64, init_registers_s390_tevx_linux64)
11345 (init_registers_s390x_vx_linux64)
11346 (init_registers_s390x_tevx_linux64)
11347 (tdesc_s390_vx_linux64, tdesc_s390_tevx_linux64)
11348 (tdesc_s390x_vx_linux64, tdesc_s390x_tevx_linux64): New extern
11349 declarations.
11350 (s390_fill_vxrs_low, s390_store_vxrs_low, s390_fill_vxrs_high)
11351 (s390_store_vxrs_high): New functions.
11352 (s390_regsets): Add entries for NT_S390_VXRS_LOW and
11353 NT_S390_VXRS_HIGH.
11354 (s390_arch_setup): Add logic for selecting one of the new target
11355 descriptions. Activate the new vector regsets if applicable.
11356 (initialize_low_arch): Also invoke init_registers_s390_vx_linux64,
11357 init_registers_s390_tevx_linux64, init_registers_s390x_vx_linux64,
11358 and init_registers_s390x_tevx_linux64.
11359
11360 2015-03-01 Pedro Alves <palves@redhat.com>
11361
11362 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Constify 'raw_regs'
11363 parameter.
11364
11365 2015-02-27 Pedro Alves <palves@redhat.com>
11366
11367 * linux-x86-low.c (u_debugreg_offset): New function.
11368 (x86_linux_dr_get, x86_linux_dr_set): Use it.
11369
11370 2015-02-27 Pedro Alves <palves@redhat.com>
11371
11372 * gdb_proc_service.h: Wrap with EXTERN_C_PUSH/EXTERN_C_POP.
11373 [!HAVE_PROC_SERVICE_H] (struct ps_prochandle): Forward declare.
11374 [!HAVE_PROC_SERVICE_H] (ps_pdread, ps_pdwrite, ps_ptread)
11375 ps_ptwrite, ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
11376 (ps_lsetfpregs, ps_getpid)
11377 (ps_get_thread_area, ps_pglobal_lookup, ps_pstop, ps_pcontinue)
11378 (ps_lstop, ps_lcontinue, ps_lgetxregsize, ps_lgetxregs)
11379 (ps_lsetxregs, ps_plog): Declare.
11380
11381 2015-02-27 Pedro Alves <palves@redhat.com>
11382
11383 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Use
11384 IP_AGENT_EXPORT_FUNC.
11385 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Use
11386 IP_AGENT_EXPORT_FUNC.
11387 * tracepoint.c (ATTR_USED, ATTR_NOINLINE, ATTR_CONSTRUCTOR)
11388 (IP_AGENT_EXPORT): Delete.
11389 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
11390 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
11391 (gdb_trampoline_buffer_error, collecting, gdb_collect)
11392 (stop_tracing, flush_trace_buffer, about_to_request_buffer_space)
11393 (trace_buffer_is_full, stopping_tracepoint, expr_eval_result)
11394 (error_tracepoint, tracepoints, tracing, trace_buffer_ctrl)
11395 (trace_buffer_ctrl_curr, trace_buffer_lo, trace_buffer_hi)
11396 (traceframe_read_count, traceframe_write_count)
11397 (traceframes_created, trace_state_variables, get_raw_reg)
11398 (get_trace_state_variable_value, set_trace_state_variable_value)
11399 (ust_loaded, helper_thread_id, cmd_buf): Use
11400 IPA_SYM_EXPORTED_NAME.
11401 (stop_tracing, flush_trace_buffer): Use IP_AGENT_EXPORT_FUNC.
11402 (tracepoints) Use IP_AGENT_EXPORT_VAR.
11403 (stopping_tracepoint, trace_buffer_is_full, expr_eval_result): Use
11404 IP_AGENT_EXPORT_VAR and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
11405 (last_tracepoint): Move into !IN_PROCESS_AGENT block.
11406 (error_tracepoint): Use IP_AGENT_EXPORT_VAR and wrap in
11407 EXTERN_C_PUSH/EXTERN_C_POP.
11408 (trace_state_variables): Use IP_AGENT_EXPORT_VAR.
11409 (trace_buffer_lo, trace_buffer_hi): Use IP_AGENT_EXPORT_VAR and
11410 wrap in EXTERN_C_PUSH/EXTERN_C_POP.
11411 (trace_buffer_ctrl, trace_buffer_ctrl_curr)
11412 (traceframe_write_count, traceframe_read_count)
11413 (traceframes_created, tracing): Use IP_AGENT_EXPORT_VAR.
11414 (about_to_request_buffer_space, get_trace_state_variable_value)
11415 (set_trace_state_variable_value): Use IP_AGENT_EXPORT_FUNC.
11416 (collecting): Use IP_AGENT_EXPORT_VAR and wrap in
11417 EXTERN_C_PUSH/EXTERN_C_POP.
11418 (gdb_collect): Use IP_AGENT_EXPORT_FUNC.
11419 (ust_loaded, cmd_buf): Use IP_AGENT_EXPORT_VAR.
11420 (helper_thread_id, gdb_agent_capability): Use IP_AGENT_EXPORT_VAR
11421 and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
11422 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
11423 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
11424 (gdb_trampoline_buffer_error): Use IP_AGENT_EXPORT_VAR.
11425 * tracepoint.h (ATTR_USED, ATTR_NOINLINE, EXPORTED_SYMBOL):
11426 Define.
11427 (IP_AGENT_EXPORT_FUNC, IP_AGENT_EXPORT_VAR)
11428 (IP_AGENT_EXPORT_VAR_DECL): Define.
11429 (tracing): Declare.
11430 (gdb_agent_get_raw_reg): Declare.
11431
11432 2015-02-27 Tom Tromey <tromey@redhat.com>
11433 Pedro Alves <palves@redhat.com>
11434
11435 Rename symbols whose names are reserved C++ keywords throughout.
11436
11437 2015-02-27 Pedro Alves <palves@redhat.com>
11438
11439 * Makefile.in (COMPILER): New, get it from autoconf.
11440 (CXX): Get from autoconf instead.
11441 (COMPILE.pre): Use COMPILER.
11442 (CC-LD): Rename to ...
11443 (CC_LD): ... this. Use COMPILER.
11444 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT), $(IPA_LIB)): Adjust.
11445 (CXX_FOR_TARGET): Default to g++ instead of gcc.
11446 * acinclude.m4: Include build-with-cxx.m4.
11447 * configure.ac: Call AC_PROG_CXX and GDB_AC_BUILD_WITH_CXX.
11448 Disable -Werror by default if building in C++ mode.
11449 (build_warnings): Add -Wno-sign-compare, -Wno-write-strings and
11450 -Wno-narrowing in C++ mode. Run supported-warning-flags tests with
11451 the C++ compiler. Save/restore CXXFLAGS too.
11452 * configure: Regenerate.
11453
11454 2015-02-27 Pedro Alves <palves@redhat.com>
11455
11456 * acinclude.m4: Include libiberty.m4.
11457 * configure.ac: Call libiberty_INIT.
11458 * config.in, configure: Regenerate.
11459
11460 2015-02-26 Pedro Alves <palves@redhat.com>
11461
11462 * linux-low.c (linux_wait_1): When incrementing the PC past a
11463 program breakpoint always use the_low_target.breakpoint_len as
11464 increment, rather than the maximum between that and
11465 the_low_target.decr_pc_after_break.
11466
11467 2015-02-23 Pedro Alves <palves@redhat.com>
11468
11469 * linux-low.c (check_stopped_by_breakpoint): Don't check if the
11470 thread was doing a step-over; always adjust the PC if
11471 we stepped over a permanent breakpoint.
11472 (linux_wait_1): If we stepped over breakpoint that was on top of a
11473 permanent breakpoint, manually advance the PC past it.
11474
11475 2015-02-23 Pedro Alves <palves@redhat.com>
11476
11477 * linux-x86-low.c (REGSIZE): Define in both 32-bit and 64-bit
11478 modes.
11479 (x86_fill_gregset, x86_store_gregset): Use it when handling
11480 $orig_eax.
11481
11482 2015-02-20 Pedro Alves <palves@redhat.com>
11483
11484 * thread-db.c: Include "nat/linux-procfs.h".
11485 (thread_db_init): Skip listing new threads if the kernel supports
11486 PTRACE_EVENT_CLONE and /proc/PID/task/ is accessible.
11487
11488 2015-02-20 Pedro Alves <palves@redhat.com>
11489
11490 * linux-low.c (status_pending_p_callback): Use ptid_match.
11491
11492 2015-02-19 Antoine Tremblay <antoine.tremblay@ericsson.com>
11493
11494 PR breakpoints/16812
11495 * linux-low.c (wstatus_maybe_breakpoint): Remove.
11496 (linux_low_filter_event): Update wstatus_maybe_breakpoint name.
11497 (linux_wait_1): Report SIGTRAP,SIGILL,SIGSEGV.
11498
11499 2015-02-10 Antoine Tremblay <antoine.tremblay@ericsson.com>
11500
11501 PR breakpoints/15956
11502 * tracepoint.c (cmd_qtinit): Add check for current_thread.
11503
11504 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
11505
11506 * linux-low.c (linux_low_btrace_conf): Print size.
11507 * server.c (handle_btrace_conf_general_set): New.
11508 (hanle_general_set): Call handle_btrace_conf_general_set.
11509 (handle_query): Report Qbtrace-conf:bts:size as supported.
11510
11511 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
11512
11513 * linux-low.c (linux_low_enable_btrace): Update parameters.
11514 (linux_low_btrace_conf): New.
11515 (linux_target_ops)<to_btrace_conf>: Initialize.
11516 * server.c (current_btrace_conf): New.
11517 (handle_btrace_enable): Rename to ...
11518 (handle_btrace_enable_bts): ... this. Pass &current_btrace_conf
11519 to target_enable_btrace. Update comment. Update users.
11520 (handle_qxfer_btrace_conf): New.
11521 (qxfer_packets): Add btrace-conf entry.
11522 (handle_query): Report qXfer:btrace-conf:read as supported packet.
11523 * target.h (target_ops)<enable_btrace>: Update parameters and comment.
11524 (target_ops)<read_btrace_conf>: New.
11525 (target_enable_btrace): Update parameters.
11526 (target_read_btrace_conf): New.
11527
11528 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
11529
11530 * server.c (handle_btrace_general_set): Remove call to
11531 target_supports_btrace.
11532 (supported_btrace_packets): New.
11533 (handle_query): Call supported_btrace_packets.
11534 * target.h: include btrace-common.h.
11535 (btrace_target_info): Removed.
11536 (supports_btrace, target_supports_btrace): Update parameters.
11537
11538 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
11539
11540 * Makefile.in (SFILES): Add common/btrace-common.c.
11541 (OBS): Add common/btrace-common.o.
11542 (btrace-common.o): Add build rules.
11543 * linux-low: Include btrace-common.h.
11544 (linux_low_read_btrace): Use struct btrace_data. Call
11545 btrace_data_init and btrace_data_fini.
11546
11547 2015-02-06 Pedro Alves <palves@redhat.com>
11548
11549 * thread-db.c (find_new_threads_callback): Add debug output.
11550
11551 2015-02-04 Pedro Alves <palves@redhat.com>
11552
11553 * linux-low.c (handle_extended_wait): Don't resume LWPs here.
11554 (resume_stopped_resumed_lwps): New function.
11555 (linux_wait_for_event_filtered): Use it.
11556
11557 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
11558
11559 * Makefile.in (SFILES): Add linux-personality.c.
11560 (linux-personality.o): New rule.
11561 * configure.srv (srv_linux_obj): Add linux-personality.o to the
11562 list of objects to be built.
11563 * linux-low.c: Include nat/linux-personality.h.
11564 (linux_create_inferior): Remove code to disable address space
11565 randomization (moved to ../nat/linux-personality.c). Create
11566 cleanup to disable address space randomization.
11567
11568 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
11569
11570 * Makefile.in (posix-strerror.o): New rule.
11571 (mingw-strerror.o): Likewise.
11572 * configure: Regenerated.
11573 * configure.ac: Source file ../common/common.host. Initialize new
11574 variable srv_host_obs. Add srv_host_obs to GDBSERVER_DEPFILES.
11575
11576 2015-01-14 Yao Qi <yao@codesourcery.com>
11577
11578 * Makefile.in (SFILES): Add nat/ppc-linux.c.
11579 (ppc-linux.o): New rule.
11580 * configure.srv (powerpc*-*-linux*): Add ppc-linux.o.
11581 * configure.ac: AC_CHECK_FUNCS(getauxval).
11582 * config.in: Re-generated.
11583 * configure: Re-generated.
11584 * linux-ppc-low.c (ppc_arch_setup) [__powerpc64__]: Call
11585 ppc64_64bit_inferior_p
11586
11587 2015-01-14 Yao Qi <yao@codesourcery.com>
11588
11589 * linux-ppc-low.c: Include "nat/ppc-linux.h".
11590 (PPC_FEATURE_HAS_VSX): Move to nat/ppc-linux.h.
11591 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Likewise.
11592 (PT_ORIG_R3, PT_TRAP): Likewise.
11593 (PTRACE_GETVSXREGS, PTRACE_SETVSXREGS): Likewise.
11594 (PTRACE_GETVRREGS, PTRACE_SETVRREGS): Likewise.
11595 (PTRACE_GETEVRREGS, PTRACE_SETEVRREGS): Likewise.
11596
11597 2015-01-10 Joel Brobecker <brobecker@adacore.com>
11598
11599 * i387-fp.c (i387_cache_to_xsave): In look over
11600 num_avx512_zmmh_high_registers, replace use of struct i387_xsave
11601 zmmh_low_space field by use of zmmh_high_space.
11602
11603 2015-01-09 Pedro Alves <palves@redhat.com>
11604
11605 * linux-low.c (step_over_bkpt): Move higher up in the file.
11606 (handle_extended_wait): Don't store the stop_pc here.
11607 (get_stop_pc): Adjust comments and rename to ...
11608 (check_stopped_by_breakpoint): ... this. Record whether the LWP
11609 stopped for a software breakpoint or hardware breakpoint.
11610 (thread_still_has_status_pending_p): New function.
11611 (status_pending_p_callback): Use
11612 thread_still_has_status_pending_p. If the event is no longer
11613 interesting, resume the LWP.
11614 (handle_tracepoints): Add assert.
11615 (maybe_move_out_of_jump_pad): Remove cancel_breakpoints call.
11616 (wstatus_maybe_breakpoint): New function.
11617 (cancel_breakpoint): Delete function.
11618 (check_stopped_by_watchpoint): New function, factored out from
11619 linux_low_filter_event.
11620 (lp_status_maybe_breakpoint): Delete function.
11621 (linux_low_filter_event): Remove filter_ptid argument.
11622 Leave thread group exits pending here. Store the LWP's stop PC.
11623 Always leave events pending.
11624 (linux_wait_for_event_filtered): Pull all events out of the
11625 kernel, and leave them all pending.
11626 (count_events_callback, select_event_lwp_callback): Consider all
11627 events.
11628 (cancel_breakpoints_callback, linux_cancel_breakpoints): Delete.
11629 (select_event_lwp): Only give preference to the stepping LWP in
11630 all-stop mode. Adjust comments.
11631 (ignore_event): New function.
11632 (linux_wait_1): Delete 'retry' label. Use ignore_event. Remove
11633 references to cancel_breakpoints. Adjust to renames. Also give
11634 equal priority to all LWPs that have had events in non-stop mode.
11635 If reporting a software breakpoint event, unadjust the LWP's PC.
11636 (linux_wait): If linux_wait_1 returned an ignored event, retry.
11637 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback):
11638 Adjust.
11639 (linux_resume_one_lwp): Store the LWP's PC. Adjust.
11640 (resume_status_pending_p): Use thread_still_has_status_pending_p.
11641 (linux_stopped_by_watchpoint): Adjust.
11642 (linux_target_ops): Remove reference to linux_cancel_breakpoints.
11643 * linux-low.h (enum lwp_stop_reason): New.
11644 (struct lwp_info) <stop_pc>: Adjust comment.
11645 <stopped_by_watchpoint>: Delete field.
11646 <stop_reason>: New field.
11647 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
11648 * mem-break.c (software_breakpoint_inserted_here)
11649 (hardware_breakpoint_inserted_here): New function.
11650 * mem-break.h (software_breakpoint_inserted_here)
11651 (hardware_breakpoint_inserted_here): Declare.
11652 * target.h (struct target_ops) <cancel_breakpoints>: Remove field.
11653 (cancel_breakpoints): Delete.
11654 * tracepoint.c (clear_installed_tracepoints, stop_tracing)
11655 (upload_fast_traceframes): Remove references to
11656 cancel_breakpoints.
11657
11658 2015-01-09 Pedro Alves <palves@redhat.com>
11659
11660 * thread-db.c (find_new_threads_callback): Ignore thread if the
11661 kernel thread ID is -1.
11662
11663 2015-01-09 Pedro Alves <palves@redhat.com>
11664
11665 * linux-low.c (linux_attach_fail_reason_string): Move to
11666 nat/linux-ptrace.c, and rename.
11667 (linux_attach_lwp): Update comment.
11668 (attach_proc_task_lwp_callback): New function.
11669 (linux_attach): Adjust to rename and use
11670 linux_proc_attach_tgid_threads.
11671 (linux_attach_fail_reason_string): Delete declaration.
11672
11673 2015-01-01 Joel Brobecker <brobecker@adacore.com>
11674
11675 * gdbreplay.c (gdbreplay_version): Update copyright year to 2015.
11676 * server.c (gdbserver_version): Likewise.
11677
11678 2014-12-29 Sergio Durigan Junior <sergiodj@redhat.com>
11679
11680 * remote-utils.c: Include ctype.h.
11681 (input_interrupt): Explicitly handle the case when the char
11682 received is the NUL byte. Improve the printing of non-ASCII
11683 characters.
11684
11685 2014-12-16 Joel Brobecker <brobecker@adacore.com>
11686
11687 * linux-low.c (linux_low_filter_event): Update call to
11688 linux_enable_event_reporting following the addition of
11689 a new parameter to that function.
11690
11691 2014-12-16 Catalin Udma <catalin.udma@freescale.com>
11692
11693 PR server/17457
11694 * linux-aarch64-low.c (AARCH64_FPSR_REGNO): New define.
11695 (AARCH64_FPCR_REGNO): Likewise.
11696 (AARCH64_NUM_REGS): Update to include fpsr/fpcr registers.
11697 (aarch64_fill_fpregset): Add missing fpsr/fpcr registers.
11698 (aarch64_store_fpregset): Likewise.
11699
11700 2014-12-15 Joel Brobecker <brobecker@adacore.com>
11701
11702 * lynx-low.c (lynx_resume): Use PTRACE_SINGLESTEP_ONE if N == 1.
11703 Remove FIXME comment about assumption about N.
11704
11705 2014-12-13 Joel Brobecker <brobecker@adacore.com>
11706
11707 * configure.ac: If large-file support is disabled in GDBserver,
11708 pass --disable-largefile to ACX_CONFIGURE_DIR call for "gnulib".
11709 * configure: Regenerate.
11710
11711 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
11712
11713 * linux-low.c (regsets_fetch_inferior_registers): Suppress the
11714 warning upon ENODATA from ptrace.
11715 * linux-s390-low.c (s390_store_tdb): New.
11716 (s390_regsets): Add regset for NT_S390_TDB.
11717
11718 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
11719
11720 * linux-low.c (regsets_store_inferior_registers): Skip regsets
11721 without a fill_function.
11722 * linux-s390-low.c (s390_fill_last_break): Remove.
11723 (s390_regsets): Set fill_function to NULL for NT_S390_LAST_BREAK.
11724 (s390_arch_setup): Use regset's size instead of fill_function for
11725 loop end condition.
11726
11727 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
11728
11729 * linux-low.c (regsets_fetch_inferior_registers): Do not invoke
11730 the regset's store function when ptrace returned an error.
11731 * regcache.c (get_thread_regcache): Invalidate register cache
11732 before fetching inferior's registers.
11733
11734 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
11735
11736 * linux-low.c (regsets_fetch_inferior_registers): Rephrase
11737 while-loop as for-loop.
11738 (regsets_store_inferior_registers): Likewise.
11739
11740 2014-11-28 Yao Qi <yao@codesourcery.com>
11741
11742 * configure.ac(AC_CHECK_FUNCS): Remove readlink.
11743 * config.in, configure: Re-generate.
11744 * hostio.c (handle_unlink): Remove code checking HAVE_READLINK
11745 is defined.
11746
11747 2014-11-21 Yao Qi <yao@codesourcery.com>
11748
11749 * configure.ac: Don't invoke AC_FUNC_ALLOCA.
11750 (AC_CHECK_HEADERS): Remove malloc.h.
11751 * configure: Re-generated.
11752 * config.in: Re-generated.
11753 * server.h: Don't include alloca.h and malloc.h.
11754 * gdbreplay.c: Don't check HAVE_ALLOCA_H is defined.
11755 Don't include malloc.h.
11756
11757 2014-11-17 Joel Brobecker <brobecker@adacore.com>
11758
11759 * lynx-low.c (lynx_write_memory): Put lynx_read_memory and
11760 corresponding ERRNO check in same block.
11761
11762 2014-11-12 Pedro Alves <palves@redhat.com>
11763
11764 * server.c (cont_thread): Update comment.
11765 (start_inferior, attach_inferior): No longer clear cont_thread.
11766 (handle_v_cont): No longer set cont_thread.
11767 (captured_main): Clear cont_thread each time a GDB connects.
11768
11769 2014-11-12 Pedro Alves <palves@redhat.com>
11770
11771 * linux-low.c (linux_wait_1): Don't force a wait for the Hc
11772 thread, and don't resume all threads if the Hc thread has exited.
11773
11774 2014-11-12 Pedro Alves <palves@redhat.com>
11775
11776 * linux-low.c (linux_request_interrupt): Always send a SIGINT to
11777 the process group instead of to a specific LWP.
11778
11779 2014-10-15 Pedro Alves <palves@redhat.com>
11780
11781 PR server/17487
11782 * win32-arm-low.c (arm_set_thread_context): Remove current_event
11783 parameter.
11784 (arm_set_thread_context): Delete.
11785 (the_low_target): Adjust.
11786 * win32-i386-low.c (debug_registers_changed)
11787 (debug_registers_used): Delete.
11788 (update_debug_registers_callback): New function.
11789 (x86_dr_low_set_addr, x86_dr_low_set_control): Mark all threads as
11790 needing to update their debug registers.
11791 (win32_get_current_dr): New function.
11792 (x86_dr_low_get_addr, x86_dr_low_get_control)
11793 (x86_dr_low_get_status): Fetch the debug register from the thread
11794 record's context.
11795 (i386_initial_stuff): Adjust.
11796 (i386_get_thread_context): Remove current_event parameter. Don't
11797 clear debug_registers_changed nor copy DR values to
11798 debug_reg_state.
11799 (i386_set_thread_context): Delete.
11800 (i386_prepare_to_resume): New function.
11801 (i386_thread_added): Mark the thread as needing to update irs
11802 debug registers.
11803 (the_low_target): Remove i386_set_thread_context and install
11804 i386_prepare_to_resume.
11805 * win32-low.c (win32_get_thread_context): Adjust.
11806 (win32_set_thread_context): Use SetThreadContext
11807 directly.
11808 (win32_prepare_to_resume): New function.
11809 (win32_require_context): New function, factored out from ...
11810 (thread_rec): ... this.
11811 (continue_one_thread): Call win32_prepare_to_resume on each thread
11812 we're about to continue.
11813 (win32_resume): Call win32_prepare_to_resume on the event thread.
11814 * win32-low.h (struct win32_thread_info)
11815 <debug_registers_changed>: New field.
11816 (struct win32_target_ops): Change prototype of set_thread_context,
11817 delete set_thread_context and add prepare_to_resume.
11818 (win32_require_context): New declaration.
11819
11820 2014-10-08 Gary Benson <gbenson@redhat.com>
11821
11822 * server.h: Do not include common-exceptions.h.
11823
11824 2014-10-08 Gary Benson <gbenson@redhat.com>
11825
11826 * server.h: Do not include cleanups.h.
11827
11828 2014-09-30 James Hogan <james.hogan@imgtec.com>
11829
11830 * Makefile.in (clean): Add rm -f commands for mips-dsp-linux.c and
11831 mips64-dsp-linux.c.
11832
11833 2014-09-23 Yao Qi <yao@codesourcery.com>
11834
11835 * linux-low.c (lp_status_maybe_breakpoint): New function.
11836 (linux_low_filter_event): Call lp_status_maybe_breakpoint.
11837 (count_events_callback): Likewise.
11838 (select_event_lwp_callback): Likewise.
11839 (cancel_breakpoints_callback): Likewise.
11840
11841 2014-09-19 Don Breazeal <donb@codesourcery.com>
11842
11843 * linux-low.c (handle_extended_wait): Call
11844 linux_ptrace_get_extended_event.
11845 (get_stop_pc, get_detach_signal, linux_low_filter_event): Call
11846 linux_is_extended_waitstatus.
11847
11848 2014-09-16 Joel Brobecker <brobecker@adacore.com>
11849
11850 * Makefile.in (CPPFLAGS): Define.
11851 (INTERNAL_CFLAGS_BASE): Add ${CPPFLAGS}.
11852 (IPAGENT_CFLAGS): Remove ${CPPFLAGS}.
11853
11854 2014-09-16 Gary Benson <gbenson@redhat.com>
11855
11856 * inferiors.h (current_inferior): Renamed as...
11857 (current_thread): New variable. All uses updated.
11858 * linux-low.c (get_pc): Renamed saved_inferior as saved_thread.
11859 (maybe_move_out_of_jump_pad): Likewise.
11860 (cancel_breakpoint): Likewise.
11861 (linux_low_filter_event): Likewise.
11862 (wait_for_sigstop): Likewise.
11863 (linux_resume_one_lwp): Likewise.
11864 (need_step_over_p): Likewise.
11865 (start_step_over): Likewise.
11866 (linux_stabilize_threads): Renamed save_inferior as saved_thread.
11867 * linux-x86-low.c (x86_linux_update_xmltarget): Likewise.
11868 * proc-service.c (ps_lgetregs): Renamed reg_inferior as reg_thread
11869 and save_inferior as saved_thread.
11870 * regcache.c (get_thread_regcache): Renamed saved_inferior as
11871 saved_thread.
11872 (regcache_invalidate_thread): Likewise.
11873 * remote-utils.c (prepare_resume_reply): Likewise.
11874 * thread-db.c (thread_db_get_tls_address): Likewise.
11875 (disable_thread_event_reporting): Likewise.
11876 (remove_thread_event_breakpoints): Likewise.
11877 * tracepoint.c (gdb_agent_about_to_close): Renamed save_inferior
11878 as saved_thread.
11879 * target.h (set_desired_inferior): Renamed as...
11880 (set_desired_thread): New declaration. All uses updated.
11881 * server.c (myresume): Updated comment to reference thread instead
11882 of inferior.
11883 (handle_serial_event): Likewise.
11884 (handle_target_event): Likewise.
11885
11886 2014-09-12 Tom Tromey <tromey@redhat.com>
11887 Gary Benson <gbenson@redhat.com>
11888
11889 * regcache.h: Include common-regcache.h.
11890 (regcache_read_pc): Don't declare.
11891 * regcache.c (get_thread_regcache_for_ptid): New function.
11892
11893 2014-09-11 Tom Tromey <tromey@redhat.com>
11894 Gary Benson <gbenson@redhat.com>
11895
11896 * symbol.c: New file.
11897 * Makefile.in (SFILES): Add symbol.c.
11898 (OBS): Add symbol.o.
11899
11900 2014-09-11 Gary Benson <gbenson@redhat.com>
11901
11902 * target.c (target_stop_ptid, target_continue_ptid): New
11903 functions.
11904
11905 2014-09-11 Tom Tromey <tromey@redhat.com>
11906 Gary Benson <gbenson@redhat.com>
11907
11908 * target.h: Include target/target.h.
11909 * target.c (target_read_memory, target_read_uint32)
11910 (target_write_memory): New functions.
11911
11912 2014-09-11 Gary Benson <gbenson@redhat.com>
11913
11914 * server.h (debug_hw_points): Don't declare.
11915 * server.c (debug_hw_points): Don't define. Replace all uses
11916 with show_debug_regs.
11917 * linux-aarch64-low.c (debug_hw_points): Don't define. Replace
11918 all uses with show_debug_regs.
11919
11920 2014-09-08 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
11921
11922 * linux-ppc-low.c (ppc_collect_ptrace_register): Adjust routine to take
11923 endianness into account.
11924 (ppc_supply_ptrace_register): Likewise.
11925
11926 2014-09-03 James Hogan <james.hogan@imgtec.com>
11927
11928 * linux-mips-low.c (mips_read_description): Reset errno to 0 prior
11929 to reading DSP_CONTROL with PTRACE_PEEKUSER ptrace call.
11930
11931 2014-09-03 Gary Benson <gbenson@redhat.com>
11932
11933 * linux-x86-low.c (x86_linux_prepare_to_resume): Use
11934 ALL_DEBUG_ADDRESS_REGISTERS.
11935
11936 2014-09-02 Gary Benson <gbenson@redhat.com>
11937
11938 * i386-low.h: Renamed as...
11939 * x86-low.h: New file. All type, function and variable name
11940 prefixes changed from "i386_" to "x86_". All references updated.
11941 * i386-low.c: Renamed as...
11942 * x86-low.c: New file. All type, function and variable name
11943 prefixes changed from "i386_" to "x86_". All references updated.
11944
11945 2014-09-02 Gary Benson <gbenson@redhat.com>
11946
11947 * linux-x86-low.c (x86_linux_new_process): Use XCNEW.
11948 (x86_linux_new_thread): Likewise.
11949
11950 2014-08-29 Gary Benson <gbenson@redhat.com>
11951
11952 * server.h (setjmp.h): Do not include.
11953 (toplevel): Do not declare.
11954 (common-exceptions.h): Include.
11955 (cleanups.h): Likewise.
11956 * server.c (toplevel): Do not define.
11957 (exit_code): New static global.
11958 (detach_or_kill_for_exit_cleanup): New function.
11959 (main): New function. Original main renamed to...
11960 (captured_main): New function.
11961 * utils.c (verror) [!IN_PROCESS_AGENT]: Use throw_verror.
11962
11963 2014-08-29 Gary Benson <gbenson@redhat.com>
11964
11965 * Makefile.in (SFILES): Add common/common-exceptions.c.
11966 (OBS): Add common-exceptions.o.
11967 (common-exceptions.o): New rule.
11968 * utils.c (prepare_to_throw_exception): New function.
11969
11970 2014-08-29 Gary Benson <gbenson@redhat.com>
11971
11972 * config.in: Regenerate.
11973 * configure: Likewise.
11974
11975 2014-08-29 Gary Benson <gbenson@redhat.com>
11976
11977 * Makefile.in (SFILES): Add common/cleanups.c.
11978 (OBS): cleanups.o.
11979 (cleanups.o): New rule.
11980
11981 2014-08-29 Gary Benson <gbenson@redhat.com>
11982
11983 * utils.c (internal_vwarning): New function.
11984
11985 2014-08-28 Gary Benson <gbenson@redhat.com>
11986
11987 * utils.h (fatal): Remove declaration.
11988 * utils.c (fatal): Remove function.
11989
11990 2014-08-28 Gary Benson <gbenson@redhat.com>
11991
11992 * tracepoint.c (gdb_agent_init): Replace fatal with
11993 perror_with_name.
11994 (initialize_tracepoint): Likewise.
11995
11996 2014-08-28 Gary Benson <gbenson@redhat.com>
11997
11998 * remote-utils.c (remote_prepare): Replace fatal with error.
11999
12000 2014-08-28 Gary Benson <gbenson@redhat.com>
12001
12002 * linux-low.c (linux_async): Replace fatal with warning.
12003 Tidy up and return.
12004 (linux_start_non_stop): Return -1 if linux_async failed.
12005
12006 2014-08-28 Gary Benson <gbenson@redhat.com>
12007
12008 * linux-x86-low.c (i386_dr_low_set_addr): Replace check with
12009 gdb_assert.
12010 (i386_dr_low_get_addr): Remove vague comment.
12011 * win32-i386-low.c (i386_dr_low_set_addr): Replace check with
12012 gdb_assert.
12013
12014 2014-08-28 Gary Benson <gbenson@redhat.com>
12015
12016 * inferiors.c (get_thread_process): Replace check with gdb_assert.
12017 * linux-low.c (linux_wait_for_event_filtered): Replace fatal with
12018 internal_error.
12019 (linux_resume_one_lwp): Likewise.
12020 * linux-x86-low.c (x86_siginfo_fixup): Replace checks with
12021 gdb_assert.
12022 * mem-break.c (raw_bkpt_type_to_target_hw_bp_type): Replace fatal
12023 with internal_error.
12024 * regcache.c (get_thread_regcache): Replace check with gdb_assert.
12025 (init_register_cache): Replace fatal with gdb_assert_not_reached.
12026 (find_register_by_name): Replace fatal with internal_error.
12027 (find_regno): Likewise.
12028 * tdesc.c (init_target_desc): Replace check with gdb_assert.
12029 * thread-db.c (thread_db_create_event): Likewise.
12030 (thread_db_load_search): Likewise.
12031 (try_thread_db_load_1): Likewise.
12032 * tracepoint.c (get_jump_space_head): Replace fatal with
12033 internal_error.
12034 (claim_trampoline_space): Likewise.
12035 (have_fast_tracepoint_trampoline_buffer): Likewise.
12036 (cmd_qtstart): Likewise.
12037 (stop_tracing): Likewise.
12038 (fast_tracepoint_collecting): Likewise.
12039 (target_malloc): Likewise.
12040 (download_tracepoint): Likewise.
12041 (download_trace_state_variables): Replace check with gdb_assert.
12042 (upload_fast_traceframes): Replace fatal with internal_error.
12043
12044 2014-08-19 Tom Tromey <tromey@redhat.com>
12045 Gary Benson <gbenson@redhat.com>
12046
12047 * Makefile.in (SFILES): Add common/common-debug.c.
12048 (OBS): Add common-debug.o.
12049 (common-debug.o): New rule.
12050 * debug.h (debug_printf): Don't declare.
12051 * debug.c (debug_printf): Renamed and rewritten as...
12052 (debug_vprintf): New function.
12053
12054 2014-08-19 Gary Benson <gbenson@redhat.com>
12055
12056 * utils.h: Do not include print-utils.h.
12057
12058 2014-08-19 Tom Tromey <tromey@redhat.com>
12059 Gary Benson <gbenson@redhat.com>
12060
12061 * server.h: Add static assertion.
12062 (gdb_byte, CORE_ADDR, LONGEST, ULONGEST): Remove.
12063
12064 2014-08-19 Tom Tromey <tromey@redhat.com>
12065 Gary Benson <gbenson@redhat.com>
12066
12067 * Makefile.in (SFILES): Add common/errors.c.
12068 (OBS): Add errors.o.
12069 (IPA_OBS): Add errors-ipa.o.
12070 (errors.o): New rule.
12071 (errors-ipa.o): Likewise.
12072 * utils.h (perror_with_name, error, warning): Don't declare.
12073 * utils.c (warning): Renamed and rewritten as...
12074 (vwarning): New function.
12075 (error): Renamed and rewritten as...
12076 (verror): New function.
12077 (internal_error): Renamed and rewritten as...
12078 (internal_verror): New function.
12079
12080 2014-08-07 Gary Benson <gbenson@redhat.com>
12081
12082 * configure.ac (AC_CHECK_HEADERS): Remove errno.h.
12083 * configure: Regenerate.
12084 * config.in: Likewise.
12085 * server.h: Do not include errno.h.
12086 * event-loop.c: Likewise.
12087 * hostio-errno.c: Likewise.
12088 * linux-low.c: Likewise.
12089 * remote-utils.c: Likewise.
12090 * spu-low.c: Likewise.
12091 * utils.c: Likewise.
12092 * gdbreplay.c: Unconditionally include errno.h.
12093
12094 2014-08-07 Gary Benson <gbenson@redhat.com>
12095
12096 * server.h: Do not include string.h.
12097 * event-loop.c: Likewise.
12098 * linux-low.c: Likewise.
12099 * regcache.c: Likewise.
12100 * remote-utils.c: Likewise.
12101 * spu-low.c: Likewise.
12102 * utils.c: Likewise.
12103
12104 2014-08-07 Gary Benson <gbenson@redhat.com>
12105
12106 * server.h: Do not include gdb_assert.h.
12107
12108 2014-08-07 Gary Benson <gbenson@redhat.com>
12109
12110 * server.h: Do not include common-utils.h.
12111
12112 2014-08-07 Gary Benson <gbenson@redhat.com>
12113
12114 * server.h: Do not include ptid.h.
12115 * notif.h: Likewise.
12116
12117 2014-08-07 Gary Benson <gbenson@redhat.com>
12118
12119 * server.h: Do not include gdb_locale.h.
12120
12121 2014-08-07 Gary Benson <gbenson@redhat.com>
12122
12123 * server.h: Do not include gdb/signals.h.
12124 * win32-low.c: Likewise.
12125
12126 2014-08-07 Gary Benson <gbenson@redhat.com>
12127
12128 * server.h: Do not include pathmax.h.
12129
12130 2014-08-07 Gary Benson <gbenson@redhat.com>
12131
12132 * server.h: Do not include libiberty.h.
12133 * linux-bfin-low.c: Likewise.
12134
12135 2014-08-07 Gary Benson <gbenson@redhat.com>
12136
12137 * server.h: Do not include ansidecl.h.
12138
12139 2014-08-07 Gary Benson <gbenson@redhat.com>
12140
12141 * linux-x86-low.c: Do not include stddef.h.
12142 * lynx-ppc-low.c: Likewise.
12143 * tracepoint.c: Likewise.
12144
12145 2014-08-07 Gary Benson <gbenson@redhat.com>
12146
12147 * server.h: Do not include stdarg.h.
12148 * nto-low.c: Likewise.
12149
12150 2014-08-07 Gary Benson <gbenson@redhat.com>
12151
12152 * server.h: Do not include stdlib.h.
12153 * inferiors.c: Likewise.
12154 * linux-low.c: Likewise.
12155 * regcache.c: Likewise.
12156 * spu-low.c: Likewise.
12157 * tracepoint.c: Likewise.
12158 * utils.c: Likewise.
12159
12160 2014-08-07 Gary Benson <gbenson@redhat.com>
12161
12162 * server.h: Do not include stdio.h.
12163 * linux-low.c: Likewise.
12164 * remote-utils.c: Likewise.
12165 * spu-low.c: Likewise.
12166 * utils.c: Likewise.
12167 * wincecompat.c: Likewise.
12168
12169 2014-08-06 Gary Benson <gbenson@redhat.com>
12170
12171 * regcache.c (init_register_cache): Move conditionals inside if.
12172
12173 2014-08-06 Gary Benson <gbenson@redhat.com>
12174
12175 * linux-low.c (linux_supports_non_stop): Use target_is_async_p.
12176
12177 2014-07-31 Gary Benson <gbenson@redhat.com>
12178
12179 * ax.h: Do not include server.h.
12180 * gdbthread.h: Likewise.
12181 * lynx-low.h: Likewise.
12182 * notif.h: Likewise.
12183
12184 2014-07-30 Gary Benson <gbenson@redhat.com>
12185
12186 * server.h: Include common-defs.h.
12187 Do not include config.h or build-gnulib-gdbserver/config.h.
12188
12189 2014-07-30 Gary Benson <gbenson@redhat.com>
12190
12191 * hostio-errno.c: Move server.h to top of includes list.
12192 * inferiors.c: Likewise.
12193 * linux-x86-low.c: Likewise.
12194 * notif.c: Include server.h.
12195
12196 2014-07-24 Tom Tromey <tromey@redhat.com>
12197 Gary Benson <gbenson@redhat.com>
12198
12199 * server.h (CORE_ADDR): Now unsigned.
12200
12201 2014-07-16 Pedro Alves <palves@redhat.com>
12202
12203 * linux-low.c (linux_kill_one_lwp): Use kill_lwp, not kill.
12204
12205 2014-07-15 Pedro Alves <palves@redhat.com>
12206
12207 * linux-low.c (linux_kill_one_lwp): Save errno and work with saved
12208 copy.
12209
12210 2014-07-11 Pedro Alves <palves@redhat.com>
12211
12212 * linux-low.c (kill_wait_lwp): New function, based on
12213 kill_one_lwp_callback, but use my_waitpid directly.
12214 (kill_one_lwp_callback, linux_kill): Use it.
12215
12216 2014-06-23 Pedro Alves <palves@redhat.com>
12217
12218 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR_CONTROL
12219 before setting DR0..DR3.
12220
12221 2014-06-20 Gary Benson <gbenson@redhat.com>
12222
12223 * configure.ac (AC_REPLACE_FUNCS) <vasprintf, vsnprintf>: Removed.
12224 * configure: Regenerated.
12225 * config.in: Likewise.
12226
12227 2014-06-20 Gary Benson <gbenson@redhat.com>
12228
12229 * Makefile.in (SFILES): Update locations for files moved
12230 from common to nat.
12231 (object file files): Reordered.
12232
12233 2014-06-20 Gary Benson <gbenson@redhat.com>
12234
12235 * i386-low.h (i386_dr_low_can_set_addr): Removed.
12236 (i386_dr_low_set_addr): Likewise.
12237 (i386_dr_low_get_addr): Likewise.
12238 (i386_dr_low_can_set_control): Likewise.
12239 (i386_dr_low_set_control): Likewise.
12240 (i386_dr_low_get_control): Likewise.
12241 (i386_dr_low_get_status): Likewise.
12242 (i386_get_debug_register_length): Likewise.
12243 * linux-x86-low.c (i386_dr_low_set_addr):
12244 Changed signature. Made static.
12245 (i386_dr_low_get_addr): Likewise.
12246 (i386_dr_low_set_control): Likewise.
12247 (i386_dr_low_get_control): Likewise.
12248 (i386_dr_low_get_status): Likewise.
12249 (i386_dr_low): New global variable.
12250 * win32-i386-low.c (i386_dr_low_set_addr):
12251 Changed signature. Made static.
12252 (i386_dr_low_get_addr): Likewise.
12253 (i386_dr_low_set_control): Likewise.
12254 (i386_dr_low_get_control): Likewise.
12255 (i386_dr_low_get_status): Likewise.
12256 (i386_dr_low): New global variable.
12257
12258 2014-06-20 Marcus Shawcroft <marcus.shawcroft@arm.com>
12259
12260 * configure.ac: Invoke. AC_CHECK_TOOL(AR, ar).
12261 * Makefile.in (AR, AR_FLAGS): Define.
12262 * configure: Regenerate.
12263
12264 2014-06-19 Gary Benson <gbenson@redhat.com>
12265
12266 * Makefile.in (i386-dregs.o): New rule.
12267 * configure.srv: Add i386-dregs.o to all targets using i386-low.o.
12268 * i386-low.c (target.h): Remove include.
12269 (TARGET_HAS_DR_LEN_8): Now in i386-dregs.c.
12270 (DR_CONTROL_SHIFT): Likewise.
12271 (DR_CONTROL_SIZE): Likewise.
12272 (DR_RW_EXECUTE): Likewise.
12273 (DR_RW_WRITE): Likewise.
12274 (DR_RW_READ): Likewise.
12275 (DR_RW_IORW): Likewise.
12276 (DR_LEN_1): Likewise.
12277 (DR_LEN_2): Likewise.
12278 (DR_LEN_4): Likewise.
12279 (DR_LEN_8): Likewise.
12280 (DR_LOCAL_ENABLE_SHIFT): Likewise.
12281 (DR_GLOBAL_ENABLE_SHIFT): Likewise.
12282 (DR_ENABLE_SIZE): Likewise.
12283 (DR_LOCAL_SLOWDOWN): Likewise.
12284 (DR_GLOBAL_SLOWDOWN): Likewise.
12285 (DR_CONTROL_RESERVED): Likewise.
12286 (I386_DR_CONTROL_MASK): Likewise.
12287 (I386_DR_VACANT): Likewise.
12288 (I386_DR_LOCAL_ENABLE): Likewise.
12289 (I386_DR_GLOBAL_ENABLE): Likewise.
12290 (I386_DR_DISABLE): Likewise.
12291 (I386_DR_SET_RW_LEN): Likewise.
12292 (I386_DR_GET_RW_LEN): Likewise.
12293 (I386_DR_WATCH_HIT): Likewise.
12294 (i386_wp_op_t): Likewise.
12295 (i386_show_dr): Likewise.
12296 (i386_length_and_rw_bits): Likewise.
12297 (i386_insert_aligned_watchpoint): Likewise.
12298 (i386_remove_aligned_watchpoint): Likewise.
12299 (i386_handle_nonaligned_watchpoint): Likewise.
12300 i386_update_inferior_debug_regs(): Likewise.
12301 (i386_dr_insert_watchpoint): Likewise.
12302 (i386_dr_remove_watchpoint): Likewise.
12303 (i386_dr_region_ok_for_watchpoint): Likewise.
12304 (i386_dr_stopped_data_address): Likewise.
12305 (i386_dr_stopped_by_watchpoint): Likewise.
12306
12307 2014-06-19 Gary Benson <gbenson@redhat.com>
12308
12309 * i386-low.c (i386_dr_show): Renamed to
12310 i386_show_dr and made static. All uses updated.
12311 (i386_dr_length_and_rw_bits): Renamed to
12312 i386_length_and_rw_bits and made static.
12313 All uses updated.
12314 (i386_dr_insert_aligned_watchpoint): Renamed to
12315 i386_insert_aligned_watchpoint and made static.
12316 All uses updated.
12317 (i386_dr_remove_aligned_watchpoint): Renamed to
12318 i386_remove_aligned_watchpoint and made static.
12319 All uses updated.
12320 (i386_dr_update_inferior_debug_regs): Renamed to
12321 i386_update_inferior_debug_regs and made static.
12322 All uses updated.
12323
12324 2014-06-18 Gary Benson <gbenson@redhat.com>
12325
12326 * i386-low.h (i386_dr_low_can_set_addr): New macro.
12327 (i386_dr_low_can_set_control): Likewise.
12328 (i386_get_debug_register_length): Likewise.
12329 * i386-low.c (i386_dr_low_can_set_addr): Now in i386-low.h.
12330 (i386_dr_low_can_set_control): Likewise.
12331 (i386_get_debug_register_length): Likewise.
12332
12333 2014-06-17 Gary Benson <gbenson@redhat.com>
12334
12335 * i386-low.h (i386-dregs.h): New include.
12336 (DR_FIRSTADDR): Now in i386-dregs.h.
12337 (DR_LASTADDR): Likewise.
12338 (DR_NADDR): Likewise.
12339 (DR_STATUS): Likewise.
12340 (DR_CONTROL): Likewise.
12341 (i386_debug_reg_state): Likewise.
12342 (i386_dr_insert_watchpoint): Likewise.
12343 (i386_dr_remove_watchpoint): Likewise.
12344 (i386_dr_region_ok_for_watchpoint): Likewise.
12345 (i386_dr_stopped_data_address): Likewise.
12346 (i386_dr_stopped_by_watchpoint): Likewise.
12347 * i386-low.c (ALL_DEBUG_REGISTERS): Likewise.
12348
12349 2014-06-18 Gary Benson <gbenson@redhat.com>
12350
12351 * i386-low.h (i386_low_insert_watchpoint): Renamed to
12352 i386_dr_insert_watchpoint.
12353 (i386_low_remove_watchpoint): Renamed to
12354 i386_dr_remove_watchpoint.
12355 (i386_low_region_ok_for_watchpoint): Renamed to
12356 i386_dr_region_ok_for_watchpoint.
12357 (i386_low_stopped_data_address): Renamed to
12358 i386_dr_stopped_data_address.
12359 (i386_low_stopped_by_watchpoint): Renamed to
12360 i386_dr_stopped_by_watchpoint.
12361 * i386-low.c (i386_show_dr): Renamed to
12362 i386_dr_show and made nonstatic. All uses updated.
12363 (i386_length_and_rw_bits): Renamed to
12364 i386_dr_length_and_rw_bits and made nonstatic.
12365 All uses updated.
12366 (i386_insert_aligned_watchpoint): Renamed to
12367 i386_dr_insert_aligned_watchpoint and made nonstatic.
12368 All uses updated.
12369 (i386_remove_aligned_watchpoint): Renamed to
12370 i386_dr_remove_aligned_watchpoint and made nonstatic.
12371 All uses updated.
12372 (i386_update_inferior_debug_regs): Renamed to
12373 i386_dr_update_inferior_debug_regs and made nonstatic.
12374 All uses updated.
12375 (i386_low_insert_watchpoint): Renamed to
12376 i386_dr_insert_watchpoint. All uses updated.
12377 (i386_low_remove_watchpoint): Renamed to
12378 i386_dr_remove_watchpoint. All uses updated.
12379 (i386_low_region_ok_for_watchpoint): Renamed to
12380 i386_dr_region_ok_for_watchpoint. All uses updated.
12381 (i386_low_stopped_data_address): Renamed to
12382 i386_dr_stopped_data_address. All uses updated.
12383 (i386_low_stopped_by_watchpoint): Renamed to
12384 i386_dr_stopped_by_watchpoint. All uses updated.
12385
12386 2014-06-18 Gary Benson <gbenson@redhat.com>
12387
12388 * i386-low.c (i386_dr_low_can_set_addr): New macro.
12389 (i386_dr_low_can_set_control): Likewise.
12390 (i386_insert_aligned_watchpoint): New check.
12391
12392 2014-06-18 Gary Benson <gbenson@redhat.com>
12393
12394 * i386-low.c (i386_update_inferior_debug_regs) <inf_state>:
12395 Renamed to state.
12396
12397 2014-06-18 Gary Benson <gbenson@redhat.com>
12398
12399 * i386-low.c (i386_length_and_rw_bits): Use internal_error
12400 instead of fatal and error.
12401 (i386_handle_nonaligned_watchpoint): Likewise.
12402
12403 2014-06-18 Gary Benson <gbenson@redhat.com>
12404
12405 * i386-low.c (i386_get_debug_register_length): New macro.
12406 (TARGET_HAS_DR_LEN_8): Remove conditional. Use above macro.
12407 (i386_show_dr): Use debug_printf instead of fprintf. Use
12408 phex to format values.
12409
12410 2014-06-18 Gary Benson <gbenson@redhat.com>
12411
12412 * i386-low.h: Comment changes.
12413 * i386-low.c: Likewise.
12414
12415 2014-06-18 Gary Benson <gbenson@redhat.com>
12416
12417 * i386-low.c: Whitespace changes.
12418
12419 2014-06-12 Tom Tromey <tromey@redhat.com>
12420
12421 * utils.c (freeargv): Remove.
12422
12423 2014-06-12 Tom Tromey <tromey@redhat.com>
12424
12425 * debug.c (debug_printf): Remove HAVE_GETTIMEOFDAY checks.
12426 * server.c (monitor_show_help): Remove HAVE_GETTIMEOFDAY check.
12427 (parse_debug_format_options): Likewise.
12428 (gdbserver_usage): Likewise.
12429 * Makefile.in (LIBIBERTY_BUILDDIR, LIBIBERTY): New variables.
12430 (SUBDIRS, REQUIRED_SUBDIRS): Add libiberty.
12431 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Depend on and link
12432 against libiberty.
12433 ($(LIBGNU)): Depend on libiberty.
12434 (all-lib): Recurse into all subdirs.
12435 (install-only): Invoke "install" target in subdirs.
12436 (vasprintf.o, vsnprintf.o, safe-ctype.o, lbasename.o): Remove
12437 targets.
12438 * configure: Rebuild.
12439 * configure.ac: Add ACX_CONFIGURE_DIR for libiberty. Don't check
12440 for vasprintf, vsnprintf, or gettimeofday.
12441 * configure.srv: Don't add safe-ctype.o or lbasename.o to
12442 srv_tgtobj.
12443
12444 2014-06-05 Joel Brobecker <brobecker@adacore.com>
12445
12446 * development.sh: Delete.
12447 * Makefile.in (config.status): Adjust dependency on development.sh.
12448 * configure.ac: Adjust development.sh source call.
12449 * configure: Regenerate.
12450
12451 2014-06-02 Pedro Alves <palves@redhat.com>
12452
12453 * ax.c (gdb_free_agent_expr): New function.
12454 * ax.h (gdb_free_agent_expr): New declaration.
12455 * mem-break.c (delete_gdb_breakpoint_1): Also clear the commands
12456 list.
12457 (clear_breakpoint_conditions, clear_breakpoint_commands): Make
12458 static.
12459 (clear_breakpoint_conditions_and_commands): New function.
12460 * mem-break.h (clear_breakpoint_conditions): Delete declaration.
12461 (clear_breakpoint_conditions_and_commands): New declaration.
12462
12463 2014-05-23 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
12464
12465 * linux-aarch64-low.c (asm/ptrace.h): Include.
12466
12467 2014-05-21 Jan Kratochvil <jan.kratochvil@redhat.com>
12468
12469 Fix TLS access for -static -pthread.
12470 * gdbserver/thread-db.c (struct thread_db): Add td_thr_tlsbase_p.
12471 (thread_db_get_tls_address): Call it if LOAD_MODULE is zero.
12472 (thread_db_load_search, try_thread_db_load_1): Initialize it.
12473
12474 2014-05-20 Pedro Alves <palves@redhat.com>
12475
12476 * linux-aarch64-low.c (aarch64_insert_point)
12477 (aarch64_remove_point): No longer check whether the type is
12478 supported here. Adjust to new interface.
12479 (the_low_target): Install aarch64_supports_z_point_type as
12480 supports_z_point_type method.
12481 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type): New function.
12482 (arm_linux_hw_point_initialize): Take an enum raw_bkpt_type
12483 instead of a Z packet char. Adjust.
12484 (arm_supports_z_point_type): New function.
12485 (arm_insert_point, arm_remove_point): Adjust to new interface.
12486 (the_low_target): Install arm_supports_z_point_type.
12487 * linux-crisv32-low.c (cris_supports_z_point_type): New function.
12488 (cris_insert_point, cris_remove_point): Adjust to new interface.
12489 Don't check whether the type is supported here.
12490 (the_low_target): Install cris_supports_z_point_type.
12491 * linux-low.c (linux_supports_z_point_type): New function.
12492 (linux_insert_point, linux_remove_point): Adjust to new interface.
12493 * linux-low.h (struct linux_target_ops) <insert_point,
12494 remove_point>: Take an enum raw_bkpt_type instead of a char. Add
12495 raw_breakpoint pointer parameter.
12496 <supports_z_point_type>: New method.
12497 * linux-mips-low.c (mips_supports_z_point_type): New function.
12498 (mips_insert_point, mips_remove_point): Adjust to new interface.
12499 Use mips_supports_z_point_type.
12500 (the_low_target): Install mips_supports_z_point_type.
12501 * linux-ppc-low.c (the_low_target): Install NULL as
12502 supports_z_point_type method.
12503 * linux-s390-low.c (the_low_target): Install NULL as
12504 supports_z_point_type method.
12505 * linux-sparc-low.c (the_low_target): Install NULL as
12506 supports_z_point_type method.
12507 * linux-x86-low.c (x86_supports_z_point_type): New function.
12508 (x86_insert_point): Adjust to new insert_point interface. Use
12509 insert_memory_breakpoint. Adjust to new
12510 i386_low_insert_watchpoint interface.
12511 (x86_remove_point): Adjust to remove_point interface. Use
12512 remove_memory_breakpoint. Adjust to new
12513 i386_low_remove_watchpoint interface.
12514 (the_low_target): Install x86_supports_z_point_type.
12515 * lynx-low.c (lynx_target_ops): Install NULL as
12516 supports_z_point_type callback.
12517 * nto-low.c (nto_supports_z_point_type): New.
12518 (nto_insert_point, nto_remove_point): Adjust to new interface.
12519 (nto_target_ops): Install nto_supports_z_point_type.
12520 * mem-break.c: Adjust intro comment.
12521 (struct raw_breakpoint) <raw_type, size>: New fields.
12522 <inserted>: Update comment.
12523 <shlib_disabled>: Delete field.
12524 (enum bkpt_type) <gdb_breakpoint>: Delete value.
12525 <gdb_breakpoint_Z0, gdb_breakpoint_Z1, gdb_breakpoint_Z2,
12526 gdb_breakpoint_Z3, gdb_breakpoint_Z4>: New values.
12527 (raw_bkpt_type_to_target_hw_bp_type): New function.
12528 (find_enabled_raw_code_breakpoint_at): New function.
12529 (find_raw_breakpoint_at): New type and size parameters. Use them.
12530 (insert_memory_breakpoint): New function, based off
12531 set_raw_breakpoint_at.
12532 (remove_memory_breakpoint): New function.
12533 (set_raw_breakpoint_at): Reimplement.
12534 (set_breakpoint): New, based on set_breakpoint_at.
12535 (set_breakpoint_at): Reimplement.
12536 (delete_raw_breakpoint): Go through the_target->remove_point
12537 instead of assuming memory breakpoints.
12538 (find_gdb_breakpoint_at): Delete.
12539 (Z_packet_to_bkpt_type, Z_packet_to_raw_bkpt_type): New functions.
12540 (find_gdb_breakpoint): New function.
12541 (set_gdb_breakpoint_at): Delete.
12542 (z_type_supported): New function.
12543 (set_gdb_breakpoint_1): New function, loosely based off
12544 set_gdb_breakpoint_at.
12545 (check_gdb_bp_preconditions, set_gdb_breakpoint): New functions.
12546 (delete_gdb_breakpoint_at): Delete.
12547 (delete_gdb_breakpoint_1): New function, loosely based off
12548 delete_gdb_breakpoint_at.
12549 (delete_gdb_breakpoint): New function.
12550 (clear_gdb_breakpoint_conditions): Rename to ...
12551 (clear_breakpoint_conditions): ... this. Don't handle a NULL
12552 breakpoint.
12553 (add_condition_to_breakpoint): Make static.
12554 (add_breakpoint_condition): Take a struct breakpoint pointer
12555 instead of an address. Adjust.
12556 (gdb_condition_true_at_breakpoint): Rename to ...
12557 (gdb_condition_true_at_breakpoint_z_type): ... this, and add
12558 z_type parameter.
12559 (gdb_condition_true_at_breakpoint): Reimplement.
12560 (add_breakpoint_commands): Take a struct breakpoint pointer
12561 instead of an address. Adjust.
12562 (gdb_no_commands_at_breakpoint): Rename to ...
12563 (gdb_no_commands_at_breakpoint_z_type): ... this. Add z_type
12564 parameter. Return true if no breakpoint was found. Change debug
12565 output.
12566 (gdb_no_commands_at_breakpoint): Reimplement.
12567 (run_breakpoint_commands): Rename to ...
12568 (run_breakpoint_commands_z_type): ... this. Add z_type parameter,
12569 and change return type to boolean.
12570 (run_breakpoint_commands): New function.
12571 (gdb_breakpoint_here): Also check for Z1 breakpoints.
12572 (uninsert_raw_breakpoint): Don't try to reinsert a disabled
12573 breakpoint. Go through the_target->remove_point instead of
12574 assuming memory breakpoint.
12575 (uninsert_breakpoints_at, uninsert_all_breakpoints): Uninsert
12576 software and hardware breakpoints.
12577 (reinsert_raw_breakpoint): Go through the_target->insert_point
12578 instead of assuming memory breakpoint.
12579 (reinsert_breakpoints_at, reinsert_all_breakpoints): Reinsert
12580 software and hardware breakpoints.
12581 (check_breakpoints, breakpoint_here, breakpoint_inserted_here):
12582 Check both software and hardware breakpoints.
12583 (validate_inserted_breakpoint): Assert the breakpoint is a
12584 software breakpoint. Set the inserted flag to -1 instead of
12585 setting shlib_disabled.
12586 (delete_disabled_breakpoints): Adjust.
12587 (validate_breakpoints): Only validate software breakpoints.
12588 Adjust to inserted flag change.
12589 (check_mem_read, check_mem_write): Skip breakpoint types other
12590 than software breakpoints. Adjust to inserted flag change.
12591 * mem-break.h (enum raw_bkpt_type): New enum.
12592 (raw_breakpoint, struct process_info): Forward declare.
12593 (Z_packet_to_target_hw_bp_type): Delete declaration.
12594 (raw_bkpt_type_to_target_hw_bp_type, Z_packet_to_raw_bkpt_type)
12595 (set_gdb_breakpoint, delete_gdb_breakpoint)
12596 (clear_breakpoint_conditions): New declarations.
12597 (set_gdb_breakpoint_at, clear_gdb_breakpoint_conditions): Delete.
12598 (breakpoint_inserted_here): Update comment.
12599 (add_breakpoint_condition, add_breakpoint_commands): Replace
12600 address parameter with a breakpoint pointer parameter.
12601 (gdb_breakpoint_here): Update comment.
12602 (delete_gdb_breakpoint_at): Delete.
12603 (insert_memory_breakpoint, remove_memory_breakpoint): Declare.
12604 * server.c (process_point_options): Take a struct breakpoint
12605 pointer instead of an address. Adjust.
12606 (process_serial_event) <Z/z packets>: Use set_gdb_breakpoint and
12607 delete_gdb_breakpoint.
12608 * spu-low.c (spu_target_ops): Install NULL as
12609 supports_z_point_type method.
12610 * target.h: Include mem-break.h.
12611 (struct target_ops) <prepare_to_access_memory>: Update comment.
12612 <supports_z_point_type>: New field.
12613 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
12614 instead of a char. Also take a raw breakpoint pointer.
12615 * win32-arm-low.c (the_low_target): Install NULL as
12616 supports_z_point_type.
12617 * win32-i386-low.c (i386_supports_z_point_type): New function.
12618 (i386_insert_point, i386_remove_point): Adjust to new interface.
12619 (the_low_target): Install i386_supports_z_point_type.
12620 * win32-low.c (win32_supports_z_point_type): New function.
12621 (win32_insert_point, win32_remove_point): Adjust to new interface.
12622 (win32_target_ops): Install win32_supports_z_point_type.
12623 * win32-low.h (struct win32_target_ops):
12624 <supports_z_point_type>: New method.
12625 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
12626 instead of a char. Also take a raw breakpoint pointer.
12627
12628 2014-05-20 Pedro Alves <palves@redhat.com>
12629
12630 * mem-break.h: Include break-common.h.
12631 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
12632 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): New defines.
12633 (Z_packet_to_target_hw_bp_type): New declaration.
12634 * mem-break.c (Z_packet_to_target_hw_bp_type): New function.
12635 * i386-low.c (Z_PACKET_HW_BP, Z_PACKET_WRITE_WP, Z_PACKET_READ_WP)
12636 (Z_PACKET_ACCESS_WP): Delete macros.
12637 (Z_packet_to_hw_type): Delete function.
12638 * i386-low.h: Don't include break-common.h here.
12639 (Z_packet_to_hw_type): Delete declaration.
12640 * linux-x86-low.c (x86_insert_point, x86_insert_point): Call
12641 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
12642 * win32-i386-low.c (i386_insert_point, i386_remove_point): Call
12643 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
12644 * linux-aarch64-low.c: Don't include break-common.h here.
12645 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
12646 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): Delete macros.
12647 (Z_packet_to_target_hw_bp_type): Delete function.
12648 * linux-mips-low.c (rsp_bp_type_to_target_hw_bp_type): Delete
12649 function.
12650 (mips_insert_point, mips_remove_point): Use
12651 Z_packet_to_target_hw_bp_type.
12652
12653 2014-05-20 Pedro Alves <palves@redhat.com>
12654
12655 * linux-aarch64-low.c: Include break-common.h.
12656 (enum target_point_type): Delete.
12657 (Z_packet_to_point_type): Rename to ...
12658 (Z_packet_to_target_hw_bp_type): ... this, and return a
12659 target_hw_bp_type instead.
12660 (aarch64_show_debug_reg_state): Take an enum target_hw_bp_type
12661 instead of an enum target_point_type.
12662 (aarch64_point_encode_ctrl_reg): Likewise. Compute type mask from
12663 breakpoint type.
12664 (aarch64_dr_state_insert_one_point)
12665 (aarch64_dr_state_remove_one_point, aarch64_handle_breakpoint)
12666 (aarch64_handle_aligned_watchpoint)
12667 (aarch64_handle_unaligned_watchpoint, aarch64_handle_watchpoint):
12668 Take an enum target_hw_bp_type instead of an enum
12669 target_point_type.
12670 (aarch64_supports_z_point_type): New function.
12671 (aarch64_insert_point, aarch64_remove_point): Use it. Adjust to
12672 use Z_packet_to_target_hw_bp_type.
12673
12674 2014-05-20 Joel Brobecker <brobecker@adacore.com>
12675
12676 * configure.ac: Only use -Werror by default when DEVELOPMENT
12677 is true.
12678 * configure: Regenerate.
12679
12680 2014-05-19 Jan Kratochvil <jan.kratochvil@redhat.com>
12681
12682 Fix gdbserver qGetTLSAddr for x86_64 -m32.
12683 * linux-x86-low.c (X86_64_USER_REGS): New.
12684 (x86_fill_gregset): Call memset for BUF first in x86_64 -m32 case.
12685
12686 2014-04-28 Yao Qi <yao@codesourcery.com>
12687
12688 * Makefile.in (i386-avx512.c): Fix the typo of generated file
12689 name.
12690
12691 2014-04-25 Pedro Alves <palves@redhat.com>
12692
12693 PR server/16255
12694 * linux-low.c (linux_attach_fail_reason_string): New function.
12695 (linux_attach_lwp): Delete.
12696 (linux_attach_lwp_1): Rename to ...
12697 (linux_attach_lwp): ... this. Take a ptid instead of a pid as
12698 argument. Remove "initial" parameter. Return int instead of
12699 void. Don't error or warn here.
12700 (linux_attach): Adjust to call linux_attach_lwp. Call error on
12701 failure to attach to the tgid. Call warning when failing to
12702 attach to an lwp.
12703 * linux-low.h (linux_attach_lwp): Take a ptid instead of a pid as
12704 argument. Remove "initial" parameter. Return int instead of
12705 void. Don't error or warn here.
12706 (linux_attach_fail_reason_string): New declaration.
12707 * thread-db.c (attach_thread): Adjust to linux_attach_lwp's
12708 interface change. Use linux_attach_fail_reason_string.
12709
12710 2014-04-24 Michael Sturm <michael.sturm@mintel.com>
12711 Walfred Tedeschi <walfred.tedeschi@intel.com>
12712
12713 * Makefile.in: Added rules to handle new files
12714 i386-avx512.c i386-avx512-linux.c amd64-avx512.c
12715 amd64-avx512-linux.c x32-avx512.c x32-avx512-linux.c.
12716 * configure.srv (srv_i386_regobj): Add i386-avx512.o.
12717 (srv_i386_linux_regobj): Add i386-avx512-linux.o.
12718 (srv_amd64_regobj): Add amd64-avx512.o and x32-avx512.o.
12719 (srv_amd64_linux_regobj): Add amd64-avx512-linux.o and
12720 x32-avx512-linux.o.
12721 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx512.xml.
12722 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx512.xml.
12723 (srv_amd64_xmlfiles): Add i386/amd64-avx512.xml and
12724 i386/x32-avx512.xml.
12725 (srv_i386_linux_xmlfiles): Add i386/i386-avx512-linux.xml.
12726 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx512-linux.xml and
12727 i386/x32-avx512-linux.xml.
12728 * i387-fp.c (num_avx512_k_registers): New constant for number
12729 of K registers.
12730 (num_avx512_zmmh_low_registers): New constant for number of
12731 lower ZMM registers (0-15).
12732 (num_avx512_zmmh_high_registers): New constant for number of
12733 higher ZMM registers (16-31).
12734 (num_avx512_ymmh_registers): New contant for number of higher
12735 YMM registers (ymm16-31 added by avx521 on x86_64).
12736 (num_avx512_xmm_registers): New constant for number of higher
12737 XMM registers (xmm16-31 added by AVX512 on x86_64).
12738 (struct i387_xsave): Add space for AVX512 registers.
12739 (i387_cache_to_xsave): Change raw buffer size to 64 characters.
12740 Add code to handle AVX512 registers.
12741 (i387_xsave_to_cache): Add code to handle AVX512 registers.
12742 * linux-x86-low.c (init_registers_amd64_avx512_linux): New
12743 prototypei from generated file.
12744 (tdesc_amd64_avx512_linux): Likewise.
12745 (init_registers_x32_avx512_linux): Likewise.
12746 (tdesc_x32_avx512_linux): Likewise.
12747 (init_registers_i386_avx512_linux): Likewise.
12748 (tdesc_i386_avx512_linux): Likewise.
12749 (x86_64_regmap): Add AVX512 registers.
12750 (x86_linux_read_description): Add code to handle AVX512 XSTATE
12751 mask.
12752 (initialize_low_arch): Add code to initialize AVX512 registers.
12753
12754 2014-04-23 Pedro Alves <palves@redhat.com>
12755
12756 * mem-break.c (find_gdb_breakpoint_at): Make static.
12757 * mem-break.h (find_gdb_breakpoint_at): Delete declaration.
12758
12759 2014-04-23 Pedro Alves <palves@redhat.com>
12760
12761 * i386-low.c: Don't include break-common.h here.
12762 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
12763 prototype to take target_hw_bp_type as argument instead of a Z
12764 packet char.
12765 * i386-low.h: Include break-common.h here.
12766 (Z_packet_to_hw_type): Declare.
12767 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
12768 prototypes.
12769 * linux-x86-low.c (x86_insert_point): Convert the packet number to
12770 a target_hw_bp_type before calling i386_low_insert_watchpoint.
12771 (x86_remove_point): Convert the packet number to a
12772 target_hw_bp_type before calling i386_low_remove_watchpoint.
12773 * win32-i386-low.c (i386_insert_point): Convert the packet number
12774 to a target_hw_bp_type before calling i386_low_insert_watchpoint.
12775 (i386_remove_point): Convert the packet number to a
12776 target_hw_bp_type before calling i386_low_remove_watchpoint.
12777
12778 2014-04-23 Pedro Alves <palves@redhat.com>
12779
12780 * utils.h (perror_with_name): Add ATTRIBUTE_NORETURN.
12781
12782 2014-04-10 Pedro Alves <palves@redhat.com>
12783
12784 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
12785 Check if the condition or command is NULL before checking if the
12786 breakpoint is known. On success, return true.
12787 * mem-break.h (add_breakpoint_condition): Document return.
12788 (add_breakpoint_commands): Add describing comment.
12789 * server.c (skip_to_semicolon): New function.
12790 (process_point_options): Use it.
12791
12792 2014-04-09 Pedro Alves <palves@redhat.com>
12793
12794 * linux-low.c (linux_read_loadmap): Pass current_inferior directly
12795 to lwpid_of.
12796
12797 2014-02-27 Pedro Alves <palves@redhat.com>
12798
12799 PR 12702
12800 * inferiors.h (A_I_NEXT, ALL_INFERIORS_TYPE, ALL_PROCESSES): New
12801 macros.
12802 * linux-low.c (delete_lwp, handle_extended_wait): Add debug
12803 output.
12804 (last_thread_of_process_p): Take a PID argument instead of a
12805 thread pointer.
12806 (linux_wait_for_lwp): Delete.
12807 (num_lwps, check_zombie_leaders, not_stopped_callback): New
12808 functions.
12809 (linux_low_filter_event): New function, party factored out from
12810 linux_wait_for_event.
12811 (linux_wait_for_event): Rename to ...
12812 (linux_wait_for_event_filtered): ... this. Add new filter ptid
12813 argument. Partly rewrite. Always use waitpid(-1, WNOHANG) and
12814 sigsuspend. Check for zombie leaders.
12815 (linux_wait_for_event): Reimplement as wrapper around
12816 linux_wait_for_event_filtered.
12817 (linux_wait_1): Handle TARGET_WAITKIND_NO_RESUMED. Assume that if
12818 a normal or signal exit is seen, it's the whole process exiting.
12819 (wait_for_sigstop): No longer a for_each_inferior callback.
12820 Rewrite on top of linux_wait_for_event_filtered.
12821 (stop_all_lwps): Call wait_for_sigstop directly.
12822 * server.c (resume, handle_target_event): Handle
12823 TARGET_WAITKIND_NO_RESUMED.
12824
12825 2014-02-26 Joel Brobecker <brobecker@adacore.com>
12826
12827 * win32-low.c (psapi_get_dll_name,
12828 * win32_CreateToolhelp32Snapshot): Delete.
12829 (win32_CreateToolhelp32Snapshot, win32_Module32First)
12830 (win32_Module32Next, load_toolhelp, toolhelp_get_dll_name):
12831 Delete.
12832 (handle_load_dll): Add function description.
12833 Remove code using psapi_get_dll_name and toolhelp_get_dll_name.
12834
12835 2014-02-26 Joel Brobecker <brobecker@adacore.com>
12836
12837 * win32-low.c (win32_add_one_solib): Add 0x1000 to load_addr.
12838 Add comment.
12839 (win32_add_all_dlls): Remove 0x1000 offset applied to DLL
12840 base address when calling win32_add_one_solib.
12841 (handle_load_dll): Delete local variable load_addr.
12842 Remove 0x1000 offset applied to DLL base address when calling
12843 win32_add_one_solib.
12844 (handle_unload_dll): Add comment.
12845
12846 2014-02-26 Joel Brobecker <brobecker@adacore.com>
12847
12848 * win32-low.c (win32_add_all_dlls): Renames
12849 win32_ensure_ntdll_loaded. Rewrite function documentation.
12850 Adjust implementation to always load all DLLs.
12851 Add 0x1000 offset to DLL base address when calling
12852 win32_add_one_solib.
12853 (child_initialization_done): New static global.
12854 (do_initial_child_stuff): Set child_initialization_done to
12855 zero during child initialization, and 1 after. Replace call
12856 to win32_ensure_ntdll_loaded by call to win32_add_all_dlls.
12857 Add comment.
12858 (match_dll_by_basename, dll_is_loaded_by_basename): Delete.
12859 (handle_unload_dll): Add function documentation.
12860 (get_child_debug_event): Ignore load and unload DLL events
12861 during child initialization.
12862
12863 2014-02-20 Doug Evans <dje@google.com>
12864
12865 Remove global all_lwps.
12866 * inferiors.h (ptid_of): Move here from linux-low.h.
12867 (pid_of, lwpid_of): Ditto.
12868 * linux-aarch64-low.c (debug_reg_change_callback): Update, "entry"
12869 parameter is a struct thread_info * now.
12870 (aarch64_notify_debug_reg_change): Fetch pid from current_inferior
12871 directly. Pass &all_threads to find_inferior instead of &all_lwps.
12872 (aarch64_stopped_data_address): Fetch lwpid from current_inferior
12873 directly.
12874 (aarch64_linux_prepare_to_resume): Fetch ptid from thread.
12875 (aarch64_arch_setup): Fetch lwpid from current_inferior directly.
12876 * linux-arm-low.c (update_registers_callback): Update, "entry"
12877 parameter is a struct thread_info * now.
12878 Fetch lwpid from current_inferior directly.
12879 (arm_insert_point): Pass &all_threads to find_inferior instead of
12880 &all_lwps.
12881 (arm_remove_point): Ditto.
12882 (arm_stopped_by_watchpoint): Fetch lwp from current_inferior.
12883 (arm_prepare_to_resume): Fetch pid from thread.
12884 (arm_read_description): Fetch lwpid from current_inferior directly.
12885 * linux-low.c (all_lwps): Delete.
12886 (delete_lwp): Delete call to remove_inferior.
12887 (handle_extended_wait): Fetch lwpid from thread.
12888 (add_lwp): Don't set lwp->entry.id. Remove call to
12889 add_inferior_to_list.
12890 (linux_attach_lwp_1): Fetch pid from current_inferior directly.
12891 (linux_kill_one_lwp): Fetch ptid,lwpid from thread.
12892 (kill_one_lwp_callback): Ditto.
12893 (linux_kill): Don't dereference NULL pointer.
12894 Fetch ptid,lwpid from thread.
12895 (get_detach_signal): Fetch ptid from thread.
12896 (linux_detach_one_lwp): Fetch ptid,lwpid from thread.
12897 Simplify call to regcache_invalidate_thread.
12898 (delete_lwp_callback): Update, "entry" parameter is a
12899 struct thread_info * now. Fetch pid from thread.
12900 (linux_mourn): Pass &all_threads to find_inferior instead of &all_lwps.
12901 (status_pending_p_callback): Update, "entry" parameter is a
12902 struct thread_info * now. Fetch ptid from thread.
12903 (find_lwp_pid): Update, "entry" parameter is a
12904 struct thread_info * now.
12905 (linux_wait_for_lwp): Fetch pid from thread.
12906 (linux_fast_tracepoint_collecting): Fetch lwpid from thread.
12907 (maybe_move_out_of_jump_pad): Fetch lwpid from current_inferior.
12908 (enqueue_one_deferred_signal): Fetch lwpid from thread.
12909 (dequeue_one_deferred_signal): Ditto.
12910 (cancel_breakpoint): Fetch ptid from current_inferior.
12911 (linux_wait_for_event): Pass &all_threads to find_inferior,
12912 not &all_lwps. Fetch ptid, lwpid from thread.
12913 (count_events_callback): Update, "entry" parameter is a
12914 struct thread_info * now.
12915 (select_singlestep_lwp_callback): Ditto.
12916 (select_event_lwp_callback): Ditto.
12917 (cancel_breakpoints_callback): Ditto.
12918 (linux_cancel_breakpoints): Pass &all_threads to find_inferior,
12919 not &all_lwps.
12920 (select_event_lwp): Ditto. Fetch ptid from event_thread.
12921 (unsuspend_one_lwp): Update, "entry" parameter is a
12922 struct thread_info * now.
12923 (unsuspend_all_lwps): Pass &all_threads to find_inferior,
12924 not &all_lwps.
12925 (linux_stabilize_threads): Ditto. And for for_each_inferior.
12926 Fetch lwpid from thread, not lwp.
12927 (linux_wait_1): Fetch ptid, lwpid from current_inferior.
12928 Pass &all_threads to find_inferior, not &all_lwps.
12929 (send_sigstop): Fetch lwpid from thread, not lwp.
12930 (send_sigstop_callback): Update, "entry" parameter is a
12931 struct thread_info * now.
12932 (suspend_and_send_sigstop_callback): Ditto.
12933 (wait_for_sigstop): Ditto. Fetch ptid, lwpid from thread, lwp.
12934 (stuck_in_jump_pad_callback): Update, "entry" parameter is a
12935 struct thread_info * now.
12936 (move_out_of_jump_pad_callback): Ditto. Fetch ptid, lwpid
12937 from thread, lwp.
12938 (lwp_running): Update, "entry" parameter is a
12939 struct thread_info * now.
12940 (stop_all_lwps): Fetch ptid from thread.
12941 Pass &all_threads to find_inferior, for_each_inferior, not &all_lwps.
12942 (linux_resume_one_lwp): Fetch lwpid from thread.
12943 (linux_set_resume_request): Update, "entry" parameter is a
12944 struct thread_info * now. Fetch pid, lwpid from thread.
12945 (resume_status_pending_p): Update, "entry" parameter is a
12946 struct thread_info * now.
12947 (need_step_over_p): Ditto. Fetch lwpid from thread.
12948 (start_step_over): Fetch lwpid from thread.
12949 (linux_resume_one_thread): Update, "entry" parameter is a
12950 struct thread_info * now. Fetch lwpid from thread.
12951 (linux_resume): Pass &all_threads to find_inferior, not &all_lwps.
12952 (proceed_one_lwp): Update, "entry" parameter is a
12953 struct thread_info * now. Fetch lwpid from thread.
12954 (unsuspend_and_proceed_one_lwp): Update, "entry" parameter is a
12955 struct thread_info * now.
12956 (proceed_all_lwps): Pass &all_threads to find_inferior, not &all_lwps.
12957 (unstop_all_lwps): Ditto. Fetch lwpid from thread.
12958 (regsets_fetch_inferior_registers): Fetch lwpid from current_inferior
12959 directly.
12960 (regsets_store_inferior_registers): Ditto.
12961 (fetch_register, store_register): Ditto.
12962 (linux_read_memory, linux_write_memory): Ditto.
12963 (linux_request_interrupt): Ditto.
12964 (linux_read_auxv): Ditto.
12965 (linux_xfer_siginfo): Ditto.
12966 (linux_qxfer_spu): Ditto.
12967 (linux_qxfer_libraries_svr4): Ditto.
12968 * linux-low.h (ptid_of, pid_of, lwpid_of): Delete,
12969 moved to inferiors.h.
12970 (get_lwp): Delete.
12971 (get_thread_lwp): Update.
12972 (struct lwp_info): Delete member "entry". Simplify comment for
12973 member "thread".
12974 (all_lwps): Delete.
12975 * linux-mips-low.c (mips_read_description): Fetch lwpid from
12976 current_inferior directly.
12977 (update_watch_registers_callback): Update, "entry" parameter is a
12978 struct thread_info * now. Fetch pid from thread.
12979 (mips_linux_prepare_to_resume): Fetch ptid from thread.
12980 (mips_insert_point): Fetch lwpid from current_inferior.
12981 Pass &all_threads to find_inferior, not &all_lwps.
12982 (mips_remove_point): Pass &all_threads to find_inferior, not &all_lwps.
12983 (mips_stopped_by_watchpoint): Fetch lwpid from current_inferior
12984 directly.
12985 (mips_stopped_data_address): Ditto.
12986 * linux-s390-low.c (s390_arch_setup): Fetch pid from current_inferior
12987 directly.
12988 * linux-tile-low.c (tile_arch_setup): Ditto.
12989 * linux-x86-low.c (x86_get_thread_area): Fetch lwpid from thread.
12990 (update_debug_registers_callback): Update, "entry" parameter is a
12991 struct thread_info * now. Fetch pid from thread.
12992 (i386_dr_low_set_addr): Fetch pid from current_inferior directly.
12993 Pass &all_threads to find_inferior, not &all_lwps.
12994 (i386_dr_low_get_addr): Fetch ptid from current_inferior directly.
12995 (i386_dr_low_set_control): Fetch pid from current_inferior directly.
12996 Pass &all_threads to find_inferior, not &all_lwps.
12997 (i386_dr_low_get_control): Fetch ptid from current_inferior directly.
12998 (i386_dr_low_get_status): Ditto.
12999 (x86_linux_prepare_to_resume): Fetch ptid from thread.
13000 (x86_siginfo_fixup): Fetch lwpid from current_inferior directly.
13001 (x86_linux_read_description): Ditto.
13002 * proc-service.c (ps_getpid): Fetch pid from current_inferior directly.
13003
13004 2014-02-20 Doug Evans <dje@google.com>
13005
13006 * inferiors.c (get_first_inferior): Fix buglet.
13007
13008 2014-02-19 Doug Evans <dje@google.com>
13009
13010 * gdbthread.h (add_thread): Change result type to struct thread_info *.
13011 * inferiors.c (add_thread): Change result type to struct thread_info *.
13012 All callers updated.
13013 (add_lwp): Call add_thread here instead of in callers.
13014 All callers updated.
13015 * linux-low.h (get_lwp_thread): Rewrite.
13016 (struct lwp_info): New member "thread".
13017
13018 2014-02-19 Doug Evans <dje@google.com>
13019
13020 * linux-low.c (add_lwp): Change result to struct lwp_info *.
13021 All callers updated.
13022
13023 2014-02-19 Doug Evans <dje@google.com>
13024
13025 * inferiors.c (add_thread): Fix whitespace.
13026
13027 2014-02-19 Doug Evans <dje@google.com>
13028
13029 * dll.c (clear_dlls): Replace accessing list implemention details
13030 with API function.
13031 * gdbthread.h (get_first_thread): Declare.
13032 * inferiors.c (for_each_inferior_with_data): New function.
13033 (get_first_thread): New function.
13034 (find_thread_ptid): Simplify.
13035 (get_first_inferior): New function.
13036 (clear_list): Delete.
13037 (one_inferior_p): New function.
13038 (clear_inferior_list): New function.
13039 (clear_inferiors): Update.
13040 * inferiors.h (for_each_inferior_with_data): Declare.
13041 (clear_inferior_list): Declare.
13042 (one_inferior_p): Declare.
13043 (get_first_inferior): Declare.
13044 * linux-low.c (linux_wait_for_event): Replace accessing list
13045 implemention details with API function.
13046 * server.c (target_running): Ditto.
13047 (accumulate_file_name_length): New function.
13048 (emit_dll_description): New function.
13049 (handle_qxfer_libraries): Replace accessing list implemention
13050 details with API function.
13051 (handle_qxfer_threads_worker): New function.
13052 (handle_qxfer_threads_proper): Replace accessing list implemention
13053 details with API function.
13054 (handle_query): Ditto.
13055 (visit_actioned_threads_callback_ftype): New typedef.
13056 (visit_actioned_threads_data): New struct.
13057 (visit_actioned_threads): Rewrite to be find_inferior callback.
13058 (resume): Call find_inferior.
13059 (handle_status): Replace accessing list implemention
13060 details with API function.
13061 (process_serial_event): Replace accessing list implemention details
13062 with API function.
13063 * target.c (set_desired_inferior): Replace accessing list implemention
13064 details with API function.
13065 * tracepoint.c (same_process_p): New function.
13066 (gdb_agent_about_to_close): Replace accessing list implemention
13067 details with API function.
13068 * win32-low.c (child_delete_thread): Replace accessing list
13069 implemention details with API function.
13070 (match_dll_by_basename): New function.
13071 (dll_is_loaded_by_basename): New function.
13072 (win32_ensure_ntdll_loaded): Replace accessing list implemention
13073 details call to dll_is_loaded_by_basename.
13074
13075 2014-02-19 Doug Evans <dje@google.com>
13076
13077 * dll.h (struct dll_info): Add comment.
13078 * gdbthread.h (struct thread_info): Add comment.
13079 (current_ptid): Simplify.
13080 * inferiors.c (add_process): Update.
13081 (remove_process): Update.
13082 * inferiors.h (struct process_info): Rename member "head" to "entry".
13083 * linux-low.c (delete_lwp): Update.
13084 (add_lwp): Update.
13085 (last_thread_of_process_p): Update.
13086 (kill_one_lwp_callback, linux_kill): Update.
13087 (status_pending_p_callback): Update.
13088 (wait_for_sigstop): Update. Simplify read of ptid.
13089 (start_step_over): Update.
13090 * linux-low.h (ptid_of, pid_of, lwpid_of): Update.
13091 (get_lwp_thread): Update.
13092 (struct lwp_info): Rename member "head" to "entry".
13093 * regcache.h (inferior_list_entry): Delete.
13094 * server.c (kill_inferior_callback): Update.
13095 (detach_or_kill_inferior_callback): Update.
13096 (print_started_pid): Update.
13097 (print_attached_pid): Update.
13098 (process_serial_event): Simplify read of ptid.
13099 * thread-db.c (thread_db_create_event): Update.
13100 (thread_db_get_tls_address): Update.
13101 * win32-low.c (current_inferior_ptid): Simplify.
13102
13103 2014-02-19 Tom Tromey <tromey@redhat.com>
13104
13105 * target.h (struct target_ops) <supports_btrace>: Add target_ops
13106 argument.
13107 (target_supports_btrace): Update.
13108
13109 2014-02-14 Yao Qi <yao@codesourcery.com>
13110
13111 * Makefile.in (IPA_OBJS): Append rsp-low-ipa.o.
13112 (rsp-low-ipa.o): New target.
13113
13114 2014-02-12 Tom Tromey <tromey@redhat.com>
13115
13116 * ax.c (gdb_parse_agent_expr): Use hex2bin, not
13117 convert_ascii_to_int.
13118 * regcache.c (registers_to_string): Likewise.
13119 * remote-utils.c (decode_M_packet): Likewise.
13120 * server.c (process_serial_event): Likewise.
13121
13122 2014-02-12 Tom Tromey <tromey@redhat.com>
13123
13124 * server.c (handle_query, handle_v_run): Use hex2bin, not
13125 unhexify.
13126 * tracepoint.c (cmd_qtdpsrc, cmd_qtdv, cmd_qtnotes): Likewise.
13127
13128 2014-02-12 Tom Tromey <tromey@redhat.com>
13129
13130 * ax.c (gdb_unparse_agent_expr): Use bin2hex, not
13131 convert_int_to_ascii.
13132 * regcache.c (registers_to_string, collect_register_as_string):
13133 Likewise.
13134 * remote-utils.c (look_up_one_symbol, relocate_instruction):
13135 Likewise.
13136 * server.c (process_serial_event): Likewise.
13137 * tracepoint.c (cmd_qtstatus, response_source, response_tsv)
13138 (cmd_qtbuffer, cstr_to_hexstr): Likewise.
13139
13140 2014-02-12 Tom Tromey <tromey@redhat.com>
13141
13142 * remote-utils.c (look_up_one_symbol, monitor_output): Use
13143 bin2hex, not hexify.
13144 * tracepoint.c (cmd_qtstatus): Likewise.
13145
13146 2014-02-12 Tom Tromey <tromey@redhat.com>
13147
13148 * remote-utils.c (monitor_output): Pass explicit length to
13149 hexify.
13150
13151 2014-02-12 Tom Tromey <tromey@redhat.com>
13152
13153 * tracepoint.c: Include rsp-low.h.
13154 * server.c: Include rsp-low.h.
13155 * remote-utils.h (convert_ascii_to_int, convert_int_to_ascii)
13156 (unhexify, hexify, remote_escape_output, unpack_varlen_hex): Don't
13157 declare.
13158 * remote-utils.c: Include rsp-low.h.
13159 (fromhex, hexchars, ishex, unhexify, tohex, hexify)
13160 (remote_escape_output, remote_unescape_input, unpack_varlen_hex)
13161 (convert_int_to_ascii, convert_ascii_to_int): Move to
13162 common/rsp-low.c.
13163 * regcache.c: Include rsp-low.h.
13164 * ax.c: Include rsp-low.h.
13165 * Makefile.in (SFILES): Add common/rsp-low.c.
13166 (OBS): Add rsp-low.o.
13167 (rsp-low.o): New target.
13168
13169 2014-02-12 Tom Tromey <tromey@redhat.com>
13170
13171 * utils.h (pulongest, plongest, phex_nz): Don't declare.
13172 Include print-utils.h.
13173 * utils.c (NUMCELLS, CELLSIZE, get_cell, decimal2str, pulongest)
13174 (plongest, thirty_two, phex_nz): Remove.
13175 * Makefile.in (SFILES): Add common/print-utils.c.
13176 (OBS): Add print-utils.o.
13177 (print-utils-ipa.o): New target.
13178 (print-utils.o): New target.
13179 (IPA_OBJS): Add print-utils-ipa.o.
13180
13181 2014-02-06 Tom Tromey <tromey@redhat.com>
13182
13183 * Makefile.in (SFILES): Fix indentation.
13184
13185 2014-02-05 Doug Evans <dje@google.com>
13186
13187 * linux-low.c (linux_wait_for_event): Improve comment.
13188 (linux_wait_1): Keep current_inferior in sync with event_child.
13189
13190 2014-01-22 Doug Evans <dje@google.com>
13191
13192 * gdbthread.h (gdb_id_to_thread): Delete, unused.
13193
13194 2014-01-22 Doug Evans <dje@google.com>
13195
13196 * configure.ac (AC_CHECK_FUNCS): Add test for gettimeofday.
13197 * configure: Regenerate.
13198 * config.in: Regenerate.
13199 * Makefile.in (SFILES): Add debug.c.
13200 (OBS): Add debug.o.
13201 * debug.c: New file.
13202 * debug.h: New file.
13203 * linux-aarch64-low.c (*): Update all debugging printfs to use
13204 debug_printf instead of fprintf.
13205 * linux-arm-low.c (*): Ditto.
13206 * linux-cris-low.c (*): Ditto.
13207 * linux-crisv32-low.c (*): Ditto.
13208 * linux-m32r-low.c (*): Ditto.
13209 * linux-sparc-low.c (*): Ditto.
13210 * linux-x86.c (*): Ditto.
13211 * linux-low.c (*): Ditto.
13212 (linux_wait_1): Add calls to debug_enter, debug_exit.
13213 (linux_wait): Remove redundant debugging printf.
13214 (stop_all_lwps): Add calls to debug_enter, debug_exit.
13215 (linux_resume, unstop_all_lwps): Ditto.
13216 * mem-break.c (*): Update all debugging printfs to use
13217 debug_printf instead of fprintf.
13218 * remote-utils.c (*): Ditto.
13219 * thread-db.c (*): Ditto.
13220 * server.c #include <ctype.h>, "gdb_vecs.h".
13221 (debug_threads): Moved to debug.c.
13222 (*): Update all debugging printfs to use debug_printf instead of
13223 fprintf.
13224 (start_inferior): Replace call to fflush with call to debug_flush.
13225 (monitor_show_help): Mention set debug-format.
13226 (parse_debug_format_options): New function.
13227 (handle_monitor_command): Handle "monitor set debug-format".
13228 (gdbserver_usage): Mention --debug-format.
13229 (main): Parse --debug-format.
13230 * server.h (debug_threads): Declaration moved to debug.h.
13231 #include "debug.h".
13232 * tracepoint.c (trace_debug_1) [!IN_PROCESS_AGENT]: Add version of
13233 trace_debug_1 that uses debug_printf.
13234 (tracepoint_look_up_symbols): Update all debugging printfs to use
13235 debug_printf instead of fprintf.
13236
13237 2014-01-20 Baruch Siach <baruch@tkos.co.il>
13238
13239 * linux-xtensa-low.c: Include asm/ptrace.h instead of
13240 sys/ptrace.h.
13241
13242 2014-01-17 Pedro Alves <palves@redhat.com>
13243
13244 PR build/16445
13245 * linux-x86-low.c: Don't include elf/common.h if ELFMAG0 is
13246 defined after including gdb_proc_service.h.
13247
13248 2014-01-16 Doug Evans <dje@google.com>
13249
13250 * dll.c (UNSPECIFIED_CORE_ADDR): New macro.
13251 (match_dll): Use it.
13252
13253 2014-01-16 Markus Metzger <markus.t.metzger@intel.com>
13254
13255 * target.h (target_ops) <read_btrace>: Change parameters and
13256 return type to allow error reporting.
13257 * server.c (handle_qxfer_btrace): Support delta reads. Pass
13258 trace reading errors on.
13259 * linux-low.c (linux_low_read_btrace): Pass trace reading
13260 errors on.
13261 (linux_low_disable_btrace): New.
13262
13263 2014-01-15 Doug Evans <dje@google.com>
13264
13265 * inferiors.c (thread_id_to_gdb_id): Delete.
13266 * inferiors.h (thread_id_to_gdb_id): Delete.
13267
13268 2014-01-13 Eli Zaretskii <eliz@gnu.org>
13269
13270 * Makefile.in (INCLUDE_CFLAGS): Remove trailing slash from
13271 "-I$(srcdir)/../". Fixes MinGW compilation errors with old GCC
13272 versions.
13273
13274 2014-01-08 Pedro Alves <palves@redhat.com>
13275
13276 * server.c (handle_status): Don't discard previous queued stop
13277 replies or thread's pending status here.
13278 (main) <disconnection>: Do it here instead.
13279
13280 2014-01-08 Pedro Alves <palves@redhat.com>
13281
13282 * gdbthread.h (struct thread_info) <status_pending_p>: New field.
13283 * server.c (visit_actioned_threads, handle_pending_status): New
13284 function.
13285 (handle_v_cont): Factor out parts to ...
13286 (resume): ... this new function. If in all-stop, and a thread
13287 being resumed has a pending status, report it without actually
13288 resuming.
13289 (myresume): Adjust to use the new 'resume' function.
13290 (clear_pending_status_callback, set_pending_status_callback)
13291 (find_status_pending_thread_callback): New functions.
13292 (handle_status): Handle the case of multiple threads having
13293 interesting statuses to report. Report threads' real last signal
13294 instead of always reporting GDB_SIGNAL_TRAP. Look for a thread
13295 with an interesting thread to report the status for, instead of
13296 always reporting the status of the first thread.
13297
13298 2014-01-01 Joel Brobecker <brobecker@adacore.com>
13299
13300 * gdbserver.c (gdbserver_version): Set copyright year to 2014.
13301 * gdbreplay.c (gdbreplay_version): Likewise.
13302
13303 2013-12-18 Yufeng Zhang <yufeng.zhang@arm.com>
13304
13305 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Set
13306 iov.iov_len with the real length in use.
13307
13308 2013-12-13 Joel Brobecker <brobecker@adacore.com>
13309
13310 * Makefile.in (safe-ctype.o, lbasename.o): New rules.
13311 * configure.srv: Add safe-ctype.o and lbasename.o to srv_tgtobj
13312 for all targets that use win32-low.c.
13313 * win32-low.c (win32_ensure_ntdll_loaded): New function.
13314 (do_initial_child_stuff): Add call to win32_ensure_ntdll_loaded.
13315
13316 2013-12-13 Pedro Alves <palves@redhat.com>
13317
13318 * target.c (mywait): Set OURSTATUS->KIND to TARGET_WAITKIND_STOPPED
13319 if equal to TARGET_WAITKIND_LOADED.
13320 * win32-low.c (cached_status): New static global.
13321 (win32_wait): Add declaration.
13322 (do_initial_child_stuff): Flush all initial pending debug events
13323 up to the initial breakpoint.
13324 (win32_wait): If CACHED_STATUS was set, return that instead
13325 of doing a real wait. Remove the code resuming the execution
13326 of the inferior after receiving a TARGET_WAITKIND_LOADED event
13327 during the initial phase. Also remove the code changing
13328 OURSTATUS->KIND from TARGET_WAITKIND_LOADED to
13329 TARGET_WAITKIND_STOPPED.
13330
13331 2013-12-11 Yao Qi <yao@codesourcery.com>
13332
13333 * notif.c (handle_notif_ack): Return 0 if no notification
13334 matches.
13335
13336 2013-11-20 Doug Evans <dje@google.com>
13337
13338 * linux-low.c (linux_set_resume_request): Fix comment.
13339
13340 2013-11-20 Doug Evans <dje@google.com>
13341
13342 * linux-low.c (resume_status_pending_p): Tweak comment.
13343
13344 2013-11-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
13345
13346 * Makefile.in: Add i386-mpx.c, i386-mpx-linux.c, amd64-mpx.c,
13347 amd64-mpx-linux.c, x32-mpx.c and x32-mpx-linux.c generation.
13348 * configure.srv (srv_i386_regobj): Add i386-mpx.o.
13349 (srv_i386_linux_regobj): Add i386-mpx-linux.o.
13350 (srv_amd64_regobj): Add amd64-mpx.o.
13351 (srv_amd64_linux_regobj): Add amd64-mpx-linux.o.
13352 (srv_i386_32bit_xmlfiles): Add i386/32bit-mpx.xml.
13353 (srv_i386_64bit_xmlfiles): Add i386/64bit-mpx.xml.
13354 * i387-fp.c (num_pl_bnd_register) Added constant.
13355 (num_pl_bnd_cfg_registers) Added constant.
13356 (struct i387_xsave) Added reserved area and MPX fields.
13357 (i387_cache_to_xsave, i387_xsave_to_cache) Add MPX.
13358 * linux-x86-low.c (init_registers_i386_mpx_linux): Declare new
13359 function.
13360 (tdesc_i386_mpx_linux): Add MPX amd64 target.
13361 (init_registers_amd64_mpx_linux): Declare new function.
13362 (tdesc_amd64_mpx_linux): Add MPX amd64 target.
13363 (x86_64_regmap): Add MPX registers.
13364 (x86_linux_read_description): Add MPX case.
13365 (initialize_low_arch): Initialize MPX targets.
13366
13367 2013-11-18 Tom Tromey <tromey@redhat.com>
13368
13369 * configure: Rebuild.
13370 * configure.ac: Don't check for stdlib.h.
13371 * gdbreplay.c: Unconditionally include stdlib.h.
13372
13373 2013-11-18 Tom Tromey <tromey@redhat.com>
13374
13375 * config.in: Rebuild.
13376 * configure: Rebuild.
13377 * configure.ac: Don't use AC_HEADER_DIRENT.
13378
13379 2013-11-18 Tom Tromey <tromey@redhat.com>
13380
13381 * server.h: Don't check HAVE_STRING_H.
13382 * gdbreplay.c: Don't check HAVE_STRING_H.
13383 * configure: Rebuild.
13384
13385 2013-11-18 Tom Tromey <tromey@redhat.com>
13386
13387 * Makefile.in (gdbreplay$(EXEEXT)): Depend on and link against
13388 LIBGNU.
13389
13390 2013-11-08 Tom Tromey <tromey@redhat.com>
13391
13392 * configure, config.in: Rebuild.
13393 * configure.ac: Remove unused configury.
13394
13395 2013-11-08 Tom Tromey <tromey@redhat.com>
13396
13397 * acinclude.m4: Include common.m4, codeset.m4.
13398 * configure, config.in: Rebuild.
13399 * configure.ac: Use GDB_AC_COMMON.
13400
13401 2013-11-06 Andreas Arnez <arnez@linux.vnet.ibm.com>
13402
13403 * linux-s390-low.c (HWCAP_S390_TE): New define.
13404 (s390_arch_setup): Consider the TE field in the HWCAP for
13405 determining 'have_regset_tdb'.
13406
13407 2013-10-16 Sergio Durigan Junior <sergiodj@redhat.com>
13408
13409 PR gdb/16014
13410 * tracepoint.c (download_tracepoint_1): Remove unnecessary double
13411 call to sizeof.
13412
13413 2013-10-02 Pedro Alves <palves@redhat.com>
13414
13415 * server.c (process_serial_event): Don't output "GDBserver
13416 exiting" if GDB is connected through stdio.
13417 * target.c (mywait): Likewise, be silent if GDB is connected
13418 through stdio.
13419
13420 2013-10-01 Joel Brobecker <brobecker@adacore.com>
13421
13422 * lynx-low.c (lynx_add_threads_after_attach): New function.
13423 (lynx_attach): Remove call to add_thread. Add call to
13424 lynx_add_threads_after_attach instead.
13425
13426 2013-09-28 Mike Frysinger <vapier@gentoo.org>
13427
13428 * configure.ac (AC_CHECK_HEADERS): Add sys/syscall.h
13429 * config.in, configure: Regenerated.
13430
13431 2013-09-18 Yao Qi <yao@codesourcery.com>
13432
13433 PR server/15959
13434 * server.c (start_inferior): Clear 'resume_info'.
13435
13436 2013-09-16 Jiong Wang <jiwang@tilera.com>
13437
13438 * linux-tile-low.c (tile_regsets): Modify the size field to 64-bit
13439 for each register.
13440
13441 2013-09-16 Jiong Wang <jiwang@tilera.com>
13442
13443 * configure.srv <tilegx*-*-linux*>: Remove linux-osdata.o from and add
13444 linux-tile-low.o to srv_tgtobj.
13445
13446 2013-09-16 Will Newton <will.newton@linaro.org>
13447
13448 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Zero
13449 out regs.
13450
13451 2013-09-06 Pedro Alves <palves@redhat.com>
13452
13453 * Makefile.in (gdb_proc_service_h, regdef_h, regcache_h)
13454 (signals_def, signals_h, ptid_h, ax_h, agent_h, linux_btrace_h)
13455 (linux_osdata_h, vec_h, gdb_vecs_h, host_defs_h, libiberty_h)
13456 (server_h, gdbthread_h, linux_low_h, linux_ptrace_h)
13457 (gdb_thread_db_h, linux_procfs_h, lynx_low_h, nto_low_h)
13458 (mips_linux_watch_h, i386_low_h, win32_low_h): Delete.
13459
13460 2013-09-06 Pedro Alves <palves@redhat.com>
13461
13462 * Makefile.in (linux-btrace.o, mips-linux-watch.o): Remove
13463 explicit header dependencies and use $COMPILE/$POSTCOMPILE.
13464
13465 2013-09-06 Pedro Alves <palves@redhat.com>
13466
13467 * linux-amd64-ipa.c: Include tracepoint.h.
13468 * linux-i386-ipa.c: Include tracepoint.h.
13469
13470 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
13471
13472 * linux-crisv32-low.c (PTRACE_GET_THREAD_AREA): New macro.
13473 (ps_get_thread_area): New function.
13474
13475 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
13476
13477 * linux-crisv32-low.c (elf_gregset_t): Delete typedef.
13478 (initialize_low_arch): Call init_registers_crisv32 rather than
13479 init_register_crisv32.
13480
13481 2013-09-05 Pedro Alves <palves@redhat.com>
13482
13483 * server.h (handle_vFile, hostio_last_error_from_errno): Move
13484 to ...
13485 * hostio.h: ... this new file.
13486 * hostio.c, server.c, linux-low.c, nto-low.c, spu-low,
13487 win32-low.c: Include hostio.h.
13488
13489 2013-09-05 Pedro Alves <palves@redhat.com>
13490
13491 * server.h (gdb_client_data, handler_func, callback_handler_func)
13492 (delete_file_handler, add_file_handler, append_callback_event)
13493 (delete_callback_event, start_event_loop, initialize_event_loop):
13494 Move to event-loop.h and include it.
13495 * event-loop.h: New file.
13496
13497 2013-09-05 Pedro Alves <palves@redhat.com>
13498
13499 * dll.c, inferiors.c, remote-utils.c, server.c: Include "dll.h".
13500 * server.h (struct dll_info, all_dlls, dlls_changed, clear_dlls)
13501 (loaded_dll, unloaded_dll): Move to ...
13502 * dll.h: ... this new file.
13503 * inferiors.c, remote-utils.c, win32-low.c: Include "dll.h".
13504
13505 2013-09-05 Pedro Alves <palves@redhat.com>
13506
13507 * server.h (current_process, get_thread_process, all_processes)
13508 (add_inferior_to_list, for_each_inferior, current_inferior)
13509 (remove_inferior, add_process, remove_process, find_process_pid)
13510 (have_started_inferiors_p, have_attached_inferiors_p)
13511 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id)
13512 (clear_inferiors, find_inferior, find_inferior_id)
13513 (inferior_target_data, set_inferior_target_data)
13514 (inferior_regcache_data, set_inferior_regcache_data): Move to
13515 inferiors.h, and include it.
13516 * inferiors.h: New file.
13517
13518 2013-09-05 Pedro Alves <palves@redhat.com>
13519
13520 * server.h (struct emit_ops, current_insn_ptr, emit_error):
13521 Move ...
13522 * ax.h: ... here.
13523
13524 2013-09-05 Pedro Alves <palves@redhat.com>
13525
13526 * ax.c, linux-low.c, linux-x86-low.c, server.c: Include
13527 tracepoint.h.
13528 * server.h (IPA_BUFSIZ, initialize_tracepoint, tracing)
13529 (disconnected_tracing, tracepoint_look_up_symbols, stop_tracing
13530 (handle_tracepoint_general_set, handle_tracepoint_query)
13531 (tracepoint_finished_step, tracepoint_was_hit)
13532 (release_while_stepping_state_list, current_traceframe)
13533 (in_readonly_region, traceframe_read_mem)
13534 (fetch_traceframe_registers, traceframe_read_sdata)
13535 (traceframe_read_info, struct fast_tpoint_collect_status)
13536 (fast_tracepoint_collecting, force_unlock_trace_buffer)
13537 (handle_tracepoit_bkpts, initialize_low_tracepoint)
13538 (supply_fast_tracepoint_registers)
13539 (supply_static_tracepoint_registers, set_trampoline_buffer_space)
13540 (ipa_tdesc, claim_trampoline_space)
13541 (have_fast_tracepoint_trampoline_buffer, gdb_agent_about_to_close)
13542 (agent_mem_read, agent_get_trace_state_variable_value)
13543 (agent_set_trace_state_variable_value, agent_tsv_read)
13544 (agent_mem_read_string, get_raw_reg_func_addr)
13545 (get_get_tsv_func_addr, get_set_tsv_func_addr): Move to ...
13546 * tracepoint.h: ... this new file.
13547
13548 2013-09-05 Pedro Alves <palves@redhat.com>
13549
13550 * server.h (perror_with_name, error, fatal, warning, paddress)
13551 (pulongest, plongest, phex_nz, pfildes): Move to utils.h, and
13552 include it.
13553 * utils.h: New file.
13554
13555 2013-09-05 Pedro Alves <palves@redhat.com>
13556
13557 * server.h (remote_debug, noack_mode, transport_is_reliable)
13558 (gdb_connected, STDIO_CONNECTION_NAME, remote_connection_is_stdio)
13559 (read_ptid, write_ptid, putpkt, putpkt_binary, putpkt_notif)
13560 (getpkt, remote_prepare, remote_open, remote_close, write_ok)
13561 (write_enn, initialize_async_io, enable_async_io)
13562 (disable_async_io, check_remote_input_interrupt_request)
13563 (convert_ascii_to_int, convert_int_to_ascii, new_thread_notify)
13564 (dead_thread_notify, prepare_resume_reply)
13565 (decode_address_to_semicolon, decode_address, decode_m_packet)
13566 (decode_M_packet, decode_X_packet, decode_xfer_write)
13567 (decode_search_memory_packet, unhexify, hexify)
13568 (remote_escape_output, unpack_varlen_hex, clear_symbol_cache)
13569 (look_up_one_symbol, relocate_instruction)
13570 (monitor_output): Move to remote-utils.h, and include it.
13571 * remote-utils.h: New file.
13572
13573 2013-09-05 Pedro Alves <palves@redhat.com>
13574
13575 * server.h (_): Delete.
13576
13577 2013-09-02 Pedro Alves <palves@redhat.com>
13578
13579 * tracepoint.c (TRACEFRAME_EOB_MARKER_SIZE): New macro.
13580 (init_trace_buffer): Ensure at least TRACEFRAME_EOB_MARKER_SIZE is
13581 allocated.
13582 (trace_buffer_alloc): Use TRACEFRAME_EOB_MARKER_SIZE.
13583
13584 2013-09-02 Pierre Muller <muller@sourceware.org>
13585
13586 * win32-low.c (child_xfer_memory): Check if ReadProcessMemory
13587 or WriteProcessMemory complete successfully and handle
13588 ERROR_PARTIAL_COPY error.
13589
13590 2013-09-02 Pedro Alves <palves@redhat.com>
13591
13592 * server.c (gdb_read_memory): Return -1 on traceframe memory read
13593 error instead of EIO.
13594
13595 2013-08-28 Jan Kratochvil <jan.kratochvil@redhat.com>
13596
13597 PR server/15604
13598 * linux-low.c: Include filestuff.h.
13599 (linux_create_inferior) <pid == 0>: Call close_most_fds.
13600 * lynx-low.c: Include filestuff.h.
13601 (lynx_create_inferior) <pid == 0>: Call close_most_fds.
13602 * server.c: Include filestuff.h.
13603 (main): Call notice_open_fds.
13604 * spu-low.c: Include filestuff.h.
13605 (spu_create_inferior) <pid == 0>: Call close_most_fds.
13606
13607 2013-08-22 Luis Machado <lgustavo@codesourcery.com>
13608
13609 * Makefile.in: Explain why ../target and ../nat are not
13610 listed as include file search paths.
13611 (linux-waitpid.o): New object file rule.
13612 * configure.srv (srv_native_linux_obj): New variable.
13613 Replace all occurrences of linux native object files with
13614 $srv_native_linux_obj.
13615 * linux-low.c: Include nat/linux-nat.h and nat/linux-waitpid.h.
13616 (HAS_NOMMU): Move defining logic to common/linux-ptrace.c.
13617 (linux_enable_event_reporting): Remove declaration.
13618 (my_waitpid): Moved to common/linux-waitpid.c.
13619 (linux_wait_for_event): Pass ptid when calling
13620 linux_enable_event_reporting.
13621 (linux_supports_tracefork_flag): Remove.
13622 (linux_enable_event_reporting): Likewise.
13623 (linux_tracefork_grandchild): Remove.
13624 (STACK_SIZE): Moved to common/linux-ptrace.c.
13625 (linux_tracefork_child): Remove.
13626 (linux_test_for_tracefork): Remove.
13627 (linux_look_up_symbols): Call linux_supports_traceclone.
13628 (initialize_low): Remove call to linux_test_for_tracefork.
13629 * linux-low.h (PTRACE_TYPE_ARG3): Move to
13630 common/linux-ptrace.h.
13631 (PTRACE_TYPE_ARG4): Likewise.
13632 Include linux-ptrace.h.
13633
13634 2013-08-21 Pedro Alves <palves@redhat.com>
13635
13636 * config.in: Renegerate.
13637
13638 2013-08-19 Luis Machado <lgustavo@codesourcery.com>
13639
13640 * Makefile.in (INCLUDE_CFLAGS): Include -I$(srcdir)/../.
13641 (SFILES): Remove $(srcdir)/common/target-common.c and
13642 add $(srcdir)/target/waitstatus.c.
13643 (OBS): Remove target-common.o and add waitstatus.o.
13644 (server_h): Remove $(srcdir)/../common/target-common.h and
13645 add $(srcdir)/../target/resume.h, $(srcdir)/../target/wait.h
13646 and $(srcdir)/../target/waitstatus.h.
13647 (target-common.o): Remove.
13648 (waitstatus.o): New target object file.
13649 * target.h: Do not include target-common.h and
13650 include target/resume.h, target/wait.h and
13651 target/waitstatus.h.
13652
13653 2013-08-13 Luis Machado <lgustavo@codesourcery.com>
13654
13655 * linux-arm-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
13656 to PTRACE_TYPE_ARG3.
13657 * linux-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
13658 to PTRACE_TYPE_ARG3 and PTRACE_ARG4_TYPE to
13659 PTRACE_TYPE_ARG4.
13660 * linux-low.h (PTRACE_ARG3_TYPE): Rename to PTRACE_TYPE_ARG3.
13661 (PTRACE_ARG4_TYPE): Rename to PTRACE_TYPE_ARG4.
13662
13663 2013-07-27 Jie Zhang <jie@codesourcery.com>
13664 Daniel Jacobowitz <dan@codesourcery.com>
13665 Yao Qi <yao@codesourcery.com>
13666
13667 * Makefile.in (SFILES): Add common/mips-linux-watch.c.
13668 (mips-linux-watch.o): New rule.
13669 (mips_linux_watch_h): New variable.
13670 * configure.srv <mips*-*-linux*>: Add mips-linux-watch.o to
13671 srv_tgtobj.
13672 * linux-mips-low.c: Include mips-linux-watch.h.
13673 (struct arch_process_info, struct arch_lwp_info): New.
13674 (update_watch_registers_callback): New function.
13675 (mips_linux_new_process, mips_linux_new_thread) New functions.
13676 (mips_linux_prepare_to_resume, mips_insert_point): New
13677 functions.
13678 (mips_remove_point, mips_stopped_by_watchpoint): New
13679 functions.
13680 (rsp_bp_type_to_target_hw_bp_type): New function.
13681 (mips_stopped_data_address): New function.
13682 (the_low_target): Add watchpoint support functions.
13683
13684 2013-07-27 Yao Qi <yao@codesourcery.com>
13685
13686 * i386-low.c: Include break-common.h.
13687 (enum target_hw_bp_type): Remove.
13688
13689 2013-07-24 Luis Machado <lgustavo@codesourcery.com>
13690
13691 * Makefile.in (SFILES): /common/target-common.c.
13692 (OBS): Add target-common.o.
13693 (server_h): Add $(srcdir)/../common/target-common.h.
13694 (target-common.o): New target.
13695 * server.c (queue_stop_reply_callback): Free
13696 status string after use.
13697 * target.c (target_waitstatus_to_string): Remove.
13698 * target.h: Include target-common.h.
13699 (resume_kind): Likewise.
13700 (target_waitkind): Likewise.
13701 (target_waitstatus): Likewise.
13702 (TARGET_WNOHANG): Likewise.
13703
13704 2013-07-04 Yao Qi <yao@codesourcery.com>
13705
13706 * Makefile.in (host_alias): Use @host_noncanonical@.
13707 (target_alias): Use @target_noncanonical@.
13708 * configure.ac: Use ACX_NONCANONICAL_TARGET and
13709 ACX_NONCANONICAL_HOST.
13710 * configure: Regenerated.
13711
13712 Revert:
13713 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
13714
13715 * configure.ac (version_host, version_target): Set and AC_SUBST them.
13716 * configure: Rebuild.
13717 * Makefile.in (version_host, version_target): Get from configure.
13718 (version.c): Use $(version_host) and $(version_target).
13719
13720 2013-07-03 Pedro Alves <palves@redhat.com>
13721
13722 * Makefile.in (config.status): Depend on development.sh.
13723 * acinclude.m4: Include libmcheck.m4.
13724 * configure: Regenerate.
13725
13726 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
13727
13728 * win32-low.c (winapi_DebugActiveProcessStop): Move the WINAPI
13729 attribute inside the parentheses.
13730 (winapi_DebugSetProcessKillOnExit): Ditto.
13731 (winapi_DebugBreakProcess): Ditto.
13732 (winapi_GenerateConsoleCtrlEvent): Ditto.
13733
13734 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
13735
13736 * notif.h (notif_event): Add a dummy member to avoid compiler
13737 errors.
13738
13739 2013-07-01 Pedro Alves <palves@redhat.com>
13740
13741 * hostio.c (HOSTIO_PATH_MAX): Define.
13742 (require_filename, handle_open, handle_unlink, handle_readlink):
13743 Use it.
13744
13745 2013-07-01 Pedro Alves <palves@redhat.com>
13746
13747 * server.h: Include "pathmax.h".
13748 * linux-low.c: Don't include sys/param.h.
13749 (linux_pid_exe_is_elf_64_file): Use PATH_MAX instead of
13750 MAXPATHLEN.
13751 * win32-low.c: Don't include sys/param.h.
13752 (win32_create_inferior): Use PATH_MAX instead of MAXPATHLEN.
13753
13754 2013-07-01 Pedro Alves <palves@redhat.com>
13755
13756 * event-loop.c: Don't check HAVE_UNISTD_H before including
13757 <unistd.h>.
13758 * gdbreplay.c: Likewise.
13759 * remote-utils.c: Likewise.
13760 * server.c: Likewise.
13761 * configure.ac: Don't check for unistd.h.
13762 * configure: Regenerate.
13763
13764 2013-06-28 Tom Tromey <tromey@redhat.com>
13765
13766 * Makefile.in (version.c): Use version.in, not
13767 common/version.in.
13768
13769 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
13770
13771 * configure.ac (version_host, version_target): Set and AC_SUBST them.
13772 * configure: Rebuild.
13773 * Makefile.in (version_host, version_target): Get from configure.
13774 (version.c): Use $(version_host) and $(version_target).
13775
13776 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
13777
13778 Fix trace-status to output user name without trailing colon.
13779 * tracepoint.c (cmd_qtstatus): Remove unnecessary colon from user name.
13780
13781 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
13782
13783 Fix trace-status to output proper start-time and stop-time.
13784 * tracepoint.c (cmd_qtstatus): Modify trace-status output to
13785 output start time and stop time in hex as gdb expects.
13786
13787 2013-06-26 Pedro Alves <pedro@codesourcery.com>
13788
13789 * tracepoint.c (build_traceframe_info_xml): Output trace state
13790 variables present in the trace buffer.
13791
13792 2013-06-24 Tom Tromey <tromey@redhat.com>
13793
13794 * Makefile.in (version.c): Use bfd/version.h, common/version.in,
13795 create-version.sh.
13796 (version.o): Remove.
13797 * gdbreplay.c: Include version.h.
13798 (version, host_name): Don't declare.
13799 * server.h: Include version.h.
13800 (version, host_name): Don't declare.
13801
13802 2013-06-12 Pedro Alves <palves@redhat.com>
13803
13804 * linux-x86-low.c (linux_is_elf64): Delete global.
13805 (x86_siginfo_fixup): Replace reference to `linux_is_elf64' global
13806 with local linux_pid_exe_is_elf_64_file use.
13807
13808 2013-06-11 Pedro Alves <palves@redhat.com>
13809
13810 * linux-low.c (regset_disabled, disable_regset): New functions.
13811 (regsets_fetch_inferior_registers)
13812 (regsets_store_inferior_registers): Use them.
13813 (initialize_regsets_info); Don't allocate the disabled_regsets
13814 array here.
13815 * linux-low.h (struct regsets_info) <disabled_regsets>: Extend
13816 comment.
13817
13818 2013-06-11 Pedro Alves <palves@redhat.com>
13819
13820 * linux-low.c (initialize_regsets_info): Use xcalloc instead of
13821 xmalloc.
13822
13823 2013-06-11 Pedro Alves <palves@redhat.com>
13824
13825 * linux-x86-low.c (initialize_low_arch): Call
13826 init_registers_x32_avx_linux.
13827
13828 2013-06-09 Jan Kratochvil <jan.kratochvil@redhat.com>
13829
13830 Fix compatibility with Android Bionic.
13831 * linux-low.c (linux_qxfer_libraries_svr4): Ignore first entry even if
13832 it is not empty.
13833
13834 2013-06-07 Pedro Alves <palves@redhat.com>
13835
13836 PR server/14823
13837 * Makefile.in (OBS): Add tdesc.o.
13838 (IPA_OBJS): Add tdesc-ipa.o.
13839 (tdesc-ipa.o): New rule.
13840 * ax.c (gdb_eval_agent_expr): Adjust register_size call to new
13841 interface.
13842 * linux-low.c (new_inferior): Delete.
13843 (disabled_regsets, num_regsets): Delete.
13844 (linux_add_process): Adjust to set the new per-process
13845 new_inferior flag.
13846 (linux_detach_one_lwp): Adjust to call regcache_invalidate_thread.
13847 (linux_wait_for_lwp): Adjust. Only call arch_setup if the event
13848 was a stop. When calling arch_setup, switch the current inferior
13849 to the thread that got an event.
13850 (linux_resume_one_lwp): Adjust to call regcache_invalidate_thread.
13851 (regsets_fetch_inferior_registers)
13852 (regsets_store_inferior_registers): New regsets_info parameter.
13853 Adjust to use it.
13854 (linux_register_in_regsets): New regs_info parameter. Adjust to
13855 use it.
13856 (register_addr, fetch_register, store_register): New usrregs_info
13857 parameter. Adjust to use it.
13858 (usr_fetch_inferior_registers, usr_store_inferior_registers): New
13859 parameter regs_info. Adjust to use it.
13860 (linux_fetch_registers): Get the current inferior's regs_info, and
13861 adjust to use it.
13862 (linux_store_registers): Ditto.
13863 [HAVE_LINUX_REGSETS] (initialize_regsets_info): New.
13864 (initialize_low): Don't initialize the target_regsets here. Call
13865 initialize_low_arch.
13866 * linux-low.h (target_regsets): Delete declaration.
13867 (struct regsets_info): New.
13868 (struct usrregs_info): New.
13869 (struct regs_info): New.
13870 (struct process_info_private) <new_inferior>: New field.
13871 (struct linux_target_ops): Delete the num_regs, regmap, and
13872 regset_bitmap fields. New field regs_info.
13873 [HAVE_LINUX_REGSETS] (initialize_regsets_info): Declare.
13874 * i387-fp.c (num_xmm_registers): Delete.
13875 (i387_cache_to_fsave, i387_fsave_to_cache): Adjust find_regno
13876 calls to new interface.
13877 (i387_cache_to_fxsave, i387_cache_to_xsave, i387_fxsave_to_cache)
13878 (i387_xsave_to_cache): Adjust find_regno calls to new interface.
13879 Infer the number of xmm registers from the regcache's target
13880 description.
13881 * i387-fp.h (num_xmm_registers): Delete.
13882 * inferiors.c (add_thread): Don't install the thread's regcache
13883 here.
13884 * proc-service.c (gregset_info): Fetch the current inferior's
13885 regs_info. Adjust to use it.
13886 * regcache.c: Include tdesc.h.
13887 (register_bytes, reg_defs, num_registers)
13888 (gdbserver_expedite_regs): Delete.
13889 (get_thread_regcache): If the thread doesn't have a regcache yet,
13890 create one, instead of aborting gdbserver.
13891 (regcache_invalidate_one): Rename to ...
13892 (regcache_invalidate_thread): ... this.
13893 (regcache_invalidate_one): New.
13894 (regcache_invalidate): Only invalidate registers of the current
13895 process.
13896 (init_register_cache): Add target_desc parameter, and use it.
13897 (new_register_cache): Ditto. Assert the target description has a
13898 non zero registers_size.
13899 (regcache_cpy): Add assertions. Adjust.
13900 (realloc_register_cache, set_register_cache): Delete.
13901 (registers_to_string, registers_from_string): Adjust.
13902 (find_register_by_name, find_regno, find_register_by_number)
13903 (register_cache_size): Add target_desc parameter, and use it.
13904 (free_register_cache_thread, free_register_cache_thread_one)
13905 (regcache_release, register_cache_size): New.
13906 (register_size): Add target_desc parameter, and use it.
13907 (register_data, supply_register, supply_register_zeroed)
13908 (supply_regblock, supply_register_by_name, collect_register)
13909 (collect_register_as_string, collect_register_by_name): Adjust.
13910 * regcache.h (struct target_desc): Forward declare.
13911 (struct regcache) <tdesc>: New field.
13912 (init_register_cache, new_register_cache): Add target_desc
13913 parameter.
13914 (regcache_invalidate_thread): Declare.
13915 (regcache_invalidate_one): Delete declaration.
13916 (regcache_release): Declare.
13917 (find_register_by_number, register_cache_size, register_size)
13918 (find_regno): Add target_desc parameter.
13919 (gdbserver_expedite_regs, gdbserver_xmltarget): Delete
13920 declarations.
13921 * remote-utils.c: Include tdesc.h.
13922 (outreg, prepare_resume_reply): Adjust.
13923 * server.c: Include tdesc.h.
13924 (gdbserver_xmltarget): Delete declaration.
13925 (get_features_xml, process_serial_event): Adjust.
13926 * server.h [IN_PROCESS_AGENT] (struct target_desc): Forward
13927 declare.
13928 (struct process_info) <tdesc>: New field.
13929 (ipa_tdesc): Declare.
13930 * tdesc.c: New file.
13931 * tdesc.h: New file.
13932 * tracepoint.c: Include tdesc.h.
13933 [IN_PROCESS_AGENT] (ipa_tdesc): Define.
13934 (get_context_regcache): Adjust to pass ipa_tdesc down.
13935 (do_action_at_tracepoint): Adjust to get the register cache size
13936 from the context regcache's description.
13937 (traceframe_walk_blocks): Adjust to get the register cache size
13938 from the current trace frame's description.
13939 (traceframe_get_pc): Adjust to get current trace frame's
13940 description and pass it down.
13941 (gdb_collect): Adjust to get the register cache size from the
13942 IPA's description.
13943 * linux-amd64-ipa.c (tdesc_amd64_linux): Declare.
13944 (gdbserver_xmltarget): Delete.
13945 (initialize_low_tracepoint): Set the ipa's target description.
13946 * linux-i386-ipa.c (tdesc_i386_linux): Declare.
13947 (initialize_low_tracepoint): Set the ipa's target description.
13948 * linux-x86-low.c: Include tdesc.h.
13949 [__x86_64__] (is_64bit_tdesc): New.
13950 (ps_get_thread_area, x86_get_thread_area): Use it.
13951 (i386_cannot_store_register): Rename to ...
13952 (x86_cannot_store_register): ... this. Use is_64bit_tdesc.
13953 (i386_cannot_fetch_register): Rename to ...
13954 (x86_cannot_fetch_register): ... this. Use is_64bit_tdesc.
13955 (x86_fill_gregset, x86_store_gregset): Adjust register_size calls
13956 to new interface.
13957 (target_regsets): Rename to ...
13958 (x86_regsets): ... this.
13959 (x86_get_pc, x86_set_pc): Adjust register_size calls to new
13960 interface.
13961 (x86_siginfo_fixup): Use is_64bit_tdesc.
13962 [__x86_64__] (tdesc_amd64_linux, tdesc_amd64_avx_linux)
13963 (tdesc_x32_avx_linux, tdesc_x32_linux)
13964 (tdesc_i386_linux, tdesc_i386_mmx_linux, tdesc_i386_avx_linux):
13965 Declare.
13966 (x86_linux_update_xmltarget): Delete.
13967 (I386_LINUX_XSAVE_XCR0_OFFSET): Define.
13968 (have_ptrace_getfpxregs, have_ptrace_getregset): New.
13969 (AMD64_LINUX_USER64_CS): New.
13970 (x86_linux_read_description): New, based on
13971 x86_linux_update_xmltarget.
13972 (same_process_callback): New.
13973 (x86_arch_setup_process_callback): New.
13974 (x86_linux_update_xmltarget): New.
13975 (x86_regsets_info): New.
13976 (amd64_linux_regs_info): New.
13977 (i386_linux_usrregs_info): New.
13978 (i386_linux_regs_info): New.
13979 (x86_linux_regs_info): New.
13980 (x86_arch_setup): Reimplement.
13981 (x86_install_fast_tracepoint_jump_pad): Use is_64bit_tdesc.
13982 (x86_emit_ops): Ditto.
13983 (the_low_target): Adjust. Install x86_linux_regs_info,
13984 x86_cannot_fetch_register, and x86_cannot_store_register.
13985 (initialize_low_arch): New.
13986 * linux-ia64-low.c (tdesc_ia64): Declare.
13987 (ia64_fetch_register): Adjust.
13988 (ia64_usrregs_info, regs_info): New globals.
13989 (ia64_regs_info): New function.
13990 (the_low_target): Adjust.
13991 (initialize_low_arch): New function.
13992 * linux-sparc-low.c (tdesc_sparc64): Declare.
13993 (sparc_fill_gregset_to_stack, sparc_store_gregset_from_stack):
13994 Adjust.
13995 (sparc_arch_setup): New function.
13996 (sparc_regsets_info, sparc_usrregs_info, regs_info): New globals.
13997 (the_low_target): Adjust.
13998 (initialize_low_arch): New function.
13999 * linux-ppc-low.c (tdesc_powerpc_32l, tdesc_powerpc_altivec32l)
14000 (tdesc_powerpc_cell32l, tdesc_powerpc_vsx32l)
14001 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_altivec32l)
14002 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_e500l)
14003 (tdesc_powerpc_64l, tdesc_powerpc_altivec64l)
14004 (tdesc_powerpc_cell64l, tdesc_powerpc_vsx64l)
14005 (tdesc_powerpc_isa205_64l, tdesc_powerpc_isa205_altivec64l)
14006 (tdesc_powerpc_isa205_vsx64l): Declare.
14007 (ppc_cannot_store_register, ppc_collect_ptrace_register)
14008 (ppc_supply_ptrace_register, parse_spufs_run, ppc_get_pc)
14009 (ppc_set_pc, ppc_get_hwcap): Adjust.
14010 (ppc_usrregs_info): Forward declare.
14011 (!__powerpc64__) ppc_regmap_adjusted: New global.
14012 (ppc_arch_setup): Adjust to the current process'es target
14013 description.
14014 (ppc_fill_vsxregset, ppc_store_vsxregset, ppc_fill_vrregset)
14015 (ppc_store_vrregset, ppc_fill_evrregset, ppc_store_evrregse)
14016 (ppc_store_evrregset): Adjust.
14017 (target_regsets): Rename to ...
14018 (ppc_regsets): ... this, and make static.
14019 (ppc_usrregs_info, ppc_regsets_info, regs_info): New globals.
14020 (ppc_regs_info): New function.
14021 (the_low_target): Adjust.
14022 (initialize_low_arch): New function.
14023 * linux-s390-low.c (tdesc_s390_linux32, tdesc_s390_linux32v1)
14024 (tdesc_s390_linux32v2, tdesc_s390_linux64, tdesc_s390_linux64v1)
14025 (tdesc_s390_linux64v2, tdesc_s390x_linux64, tdesc_s390x_linux64v1)
14026 (tdesc_s390x_linux64v2): Declare.
14027 (s390_collect_ptrace_register, s390_supply_ptrace_register)
14028 (s390_fill_gregset, s390_store_last_break): Adjust.
14029 (target_regsets): Rename to ...
14030 (s390_regsets): ... this, and make static.
14031 (s390_get_pc, s390_set_pc): Adjust.
14032 (s390_get_hwcap): New target_desc parameter, and use it.
14033 [__s390x__] (have_hwcap_s390_high_gprs): New global.
14034 (s390_arch_setup): Adjust to set the current process'es target
14035 description. Don't adjust the regmap.
14036 (s390_usrregs_info, s390_regsets_info, regs_info): New globals.
14037 [__s390x__] (s390_usrregs_info_3264, s390_regsets_info_3264)
14038 (regs_info_3264): New globals.
14039 (s390_regs_info): New function.
14040 (the_low_target): Adjust.
14041 (initialize_low_arch): New function.
14042 * linux-mips-low.c (tdesc_mips_linux, tdesc_mips_dsp_linux)
14043 (tdesc_mips64_linux, tdesc_mips64_dsp_linux): Declare.
14044 [__mips64] (init_registers_mips_linux)
14045 (init_registers_mips_dsp_linux): Delete defines.
14046 [__mips64] (tdesc_mips_linux, tdesc_mips_dsp_linux): New defines.
14047 (have_dsp): New global.
14048 (mips_read_description): New, based on mips_arch_setup.
14049 (mips_arch_setup): Reimplement.
14050 (get_usrregs_info): New function.
14051 (mips_cannot_fetch_register, mips_cannot_store_register)
14052 (mips_get_pc, mips_set_pc, mips_fill_gregset, mips_store_gregset)
14053 (mips_fill_fpregset, mips_store_fpregset): Adjust.
14054 (target_regsets): Rename to ...
14055 (mips_regsets): ... this, and make static.
14056 (mips_regsets_info, mips_dsp_usrregs_info, mips_usrregs_info)
14057 (dsp_regs_info, regs_info): New globals.
14058 (mips_regs_info): New function.
14059 (the_low_target): Adjust.
14060 (initialize_low_arch): New function.
14061 * linux-arm-low.c (tdesc_arm, tdesc_arm_with_iwmmxt)
14062 (tdesc_arm_with_vfpv2, tdesc_arm_with_vfpv3, tdesc_arm_with_neon):
14063 Declare.
14064 (arm_fill_vfpregset, arm_store_vfpregset): Adjust.
14065 (arm_read_description): New, with bits factored from
14066 arm_arch_setup.
14067 (arm_arch_setup): Reimplement.
14068 (target_regsets): Rename to ...
14069 (arm_regsets): ... this, and make static.
14070 (arm_regsets_info, arm_usrregs_info, regs_info): New globals.
14071 (arm_regs_info): New function.
14072 (the_low_target): Adjust.
14073 (initialize_low_arch): New function.
14074 * linux-m68k-low.c (tdesc_m68k): Declare.
14075 (target_regsets): Rename to ...
14076 (m68k_regsets): ... this, and make static.
14077 (m68k_regsets_info, m68k_usrregs_info, regs_info): New globals.
14078 (m68k_regs_info): New function.
14079 (m68k_arch_setup): New function.
14080 (the_low_target): Adjust.
14081 (initialize_low_arch): New function.
14082 * linux-sh-low.c (tdesc_sharch): Declare.
14083 (target_regsets): Rename to ...
14084 (sh_regsets): ... this, and make static.
14085 (sh_regsets_info, sh_usrregs_info, regs_info): New globals.
14086 (sh_regs_info, sh_arch_setup): New functions.
14087 (the_low_target): Adjust.
14088 (initialize_low_arch): New function.
14089 * linux-bfin-low.c (tdesc_bfin): Declare.
14090 (bfin_arch_setup): New function.
14091 (bfin_usrregs_info, regs_info): New globals.
14092 (bfin_regs_info): New function.
14093 (the_low_target): Adjust.
14094 (initialize_low_arch): New function.
14095 * linux-cris-low.c (tdesc_cris): Declare.
14096 (cris_arch_setup): New function.
14097 (cris_usrregs_info, regs_info): New globals.
14098 (cris_regs_info): New function.
14099 (the_low_target): Adjust.
14100 (initialize_low_arch): New function.
14101 * linux-cris-low.c (tdesc_crisv32): Declare.
14102 (cris_arch_setup): New function.
14103 (cris_regsets_info, cris_usrregs_info, regs_info): New globals.
14104 (cris_regs_info): New function.
14105 (the_low_target): Adjust.
14106 (initialize_low_arch): New function.
14107 * linux-m32r-low.c (tdesc_m32r): Declare.
14108 (m32r_arch_setup): New function.
14109 (m32r_usrregs_info, regs_info): New globals.
14110 (m32r_regs_info): Adjust.
14111 (initialize_low_arch): New function.
14112 * linux-tic6x-low.c (tdesc_tic6x_c64xp_linux)
14113 (tdesc_tic6x_c64x_linux, tdesc_tic6x_c62x_linux): Declare.
14114 (tic6x_usrregs_info): Forward declare.
14115 (tic6x_read_description): New function, based on ...
14116 (tic6x_arch_setup): ... this. Reimplement.
14117 (target_regsets): Rename to ...
14118 (tic6x_regsets): ... this, and make static.
14119 (tic6x_regsets_info, tic6x_usrregs_info, regs_info): New globals.
14120 (tic6x_regs_info): New function.
14121 (the_low_target): Adjust.
14122 (initialize_low_arch): New function.
14123 * linux-xtensa-low.c (tdesc_xtensa): Declare.
14124 (xtensa_fill_gregset, xtensa_store_gregset): Adjust.
14125 (target_regsets): Rename to ...
14126 (xtensa_regsets): ... this, and make static.
14127 (xtensa_regsets_info, xtensa_usrregs_info, regs_info): New
14128 globals.
14129 (xtensa_arch_setup, xtensa_regs_info): New functions.
14130 (the_low_target): Adjust.
14131 (initialize_low_arch): New function.
14132 * linux-nios2-low.c (tdesc_nios2_linux): Declare.
14133 (nios2_arch_setup): Set the current process'es tdesc.
14134 (target_regsets): Rename to ...
14135 (nios2_regsets): ... this.
14136 (nios2_regsets_info, nios2_usrregs_info, regs_info): New globals.
14137 (nios2_regs_info): New function.
14138 (the_low_target): Adjust.
14139 (initialize_low_arch): New function.
14140 * linux-aarch64-low.c (tdesc_aarch64): Declare.
14141 (aarch64_arch_setup): Set the current process'es tdesc.
14142 (target_regsets): Rename to ...
14143 (aarch64_regsets): ... this.
14144 (aarch64_regsets_info, aarch64_usrregs_info, regs_info): New globals.
14145 (aarch64_regs_info): New function.
14146 (the_low_target): Adjust.
14147 (initialize_low_arch): New function.
14148 * linux-tile-low.c (tdesc_tilegx, tdesc_tilegx32): Declare
14149 globals.
14150 (target_regsets): Rename to ...
14151 (tile_regsets): ... this.
14152 (tile_regsets_info, tile_usrregs_info, regs_info): New globals.
14153 (tile_regs_info): New function.
14154 (tile_arch_setup): Set the current process'es tdesc.
14155 (the_low_target): Adjust.
14156 (initialize_low_arch): New function.
14157 * spu-low.c (tdesc_spu): Declare.
14158 (spu_create_inferior, spu_attach): Set the new process'es tdesc.
14159 * win32-arm-low.c (tdesc_arm): Declare.
14160 (arm_arch_setup): New function.
14161 (the_low_target): Install arm_arch_setup instead of
14162 init_registers_arm.
14163 * win32-i386-low.c (tdesc_i386, tdesc_amd64): Declare.
14164 (init_windows_x86): Rename to ...
14165 (i386_arch_setup): ... this. Set `win32_tdesc'.
14166 (the_low_target): Adjust.
14167 * win32-low.c (win32_tdesc): New global.
14168 (child_add_thread): Don't create the thread cache here.
14169 (do_initial_child_stuff): Set the new process'es tdesc.
14170 * win32-low.h (struct target_desc): Forward declare.
14171 (win32_tdesc): Declare.
14172 * lynx-i386-low.c (tdesc_i386): Declare global.
14173 (lynx_i386_arch_setup): Set `lynx_tdesc'.
14174 * lynx-low.c (lynx_tdesc): New global.
14175 (lynx_add_process): Set the new process'es tdesc.
14176 * lynx-low.h (struct target_desc): Forward declare.
14177 (lynx_tdesc): Declare global.
14178 * lynx-ppc-low.c (tdesc_powerpc_32): Declare global.
14179 (lynx_ppc_arch_setup): Set `lynx_tdesc'.
14180 * nto-low.c (nto_tdesc): New global.
14181 (do_attach): Set the new process'es tdesc.
14182 * nto-low.h (struct target_desc): Forward declare.
14183 (nto_tdesc): Declare.
14184 * nto-x86-low.c (tdesc_i386): Declare.
14185 (nto_x86_arch_setup): Set `nto_tdesc'.
14186
14187 2013-06-04 Gary Benson <gbenson@redhat.com>
14188
14189 * server.c (handle_query): Add "augmented-libraries-svr4-read+"
14190 to qSupported response when appropriate.
14191 (handle_qxfer_libraries_svr4): Allow qXfer:libraries-svr4:read
14192 with nonzero-length annex.
14193 * linux-low.c (linux_qxfer_libraries_svr4): Parse and handle
14194 arguments supplied in annex.
14195
14196 2013-05-31 Doug Evans <dje@google.com>
14197
14198 PR server/15594
14199 * linux-x86-low.c (ps_get_thread_area): Properly extend address to
14200 64 bits in 64-cross-32 environment.
14201
14202 2013-05-28 Pedro Alves <palves@redhat.com>
14203
14204 * Makefile.in (clean): Remove reference to aarch64-without-fpu.c.
14205 (aarch64-without-fpu.c): Delete rule.
14206 * configure.srv (aarch64*-*-linux*): Remove references to
14207 aarch64-without-fpu.o and aarch64-without-fpu.xml.
14208 * linux-aarch64-low.c (init_registers_aarch64_without_fpu): Remove
14209 declaration.
14210
14211 2013-05-24 Pedro Alves <palves@redhat.com>
14212
14213 * server.c (handle_v_cont) <vCont;r>: Use unpack_varlen_hex
14214 instead of strchr/decode_address. Error if the range isn't split
14215 with a ','. Don't assume there's be a ':' in the action.
14216
14217 2013-05-23 Yao Qi <yao@codesourcery.com>
14218 Pedro Alves <palves@redhat.com>
14219
14220 * linux-low.c (lwp_in_step_range): New function.
14221 (linux_wait_1): If the thread was range stepping and stopped
14222 outside the stepping range, report the stop to GDB. Otherwise,
14223 continue stepping. Add range stepping debug output.
14224 (linux_set_resume_request): Copy the step range from the resume
14225 request to the lwp.
14226 (linux_supports_range_stepping): New.
14227 (linux_target_ops) <supports_range_stepping>: Set to
14228 linux_supports_range_stepping.
14229 * linux-low.h (struct linux_target_ops)
14230 <supports_range_stepping>: New field.
14231 (struct lwp_info) <step_range_start, step_range_end>: New fields.
14232 * linux-x86-low.c (x86_supports_range_stepping): New.
14233 (the_low_target) <supports_range_stepping>: Set to
14234 x86_supports_range_stepping.
14235 * server.c (handle_v_cont): Handle 'r' action.
14236 (handle_v_requests): Append ";r" if the target supports range
14237 stepping.
14238 * target.h (struct thread_resume) <step_range_start,
14239 step_range_end>: New fields.
14240 (struct target_ops) <supports_range_stepping>:
14241 New field.
14242 (target_supports_range_stepping): New macro.
14243
14244 2013-05-17 Joel Brobecker <brobecker@adacore.com>
14245
14246 * lynx-low.c (lynx_resume): Fix null_ptid/minus_one_ptid
14247 confusion in comment.
14248
14249 2013-05-17 Joel Brobecker <brobecker@adacore.com>
14250
14251 * lynx-low.c (struct process_info_private): New type.
14252 (lynx_add_process): New function.
14253 (lynx_create_inferior, lynx_attach): Replace calls to
14254 add_process by calls to lynx_add_process.
14255 (lynx_resume): If PTID is null, then try using
14256 current_process()->private->last_wait_event_ptid.
14257 Add comments.
14258 (lynx_clear_inferiors): Delete. The contents of that function
14259 has been inlined in lynx_mourn;
14260 (lynx_wait_1): Save the ptid in the process's private data.
14261 (lynx_mourn): Free the process' private data. Replace call
14262 to lynx_clear_inferiors by call to clear_inferiors.
14263
14264 2013-05-17 Yao Qi <yao@codesourcery.com>
14265
14266 * i386-low.c (i386_length_and_rw_bits): Move the comment to
14267 the right place.
14268
14269 2013-05-16 Luis Machado <lgustavo@codesourcery.com>
14270
14271 * linux-low.c: Move definition checks upwards for PT_TEXT_ADDR,
14272 PT_DATA_ADDR and PT_TEXT_END_ADDR. Update comments.
14273 (linux_read_offsets): Remove PT_TEXT_ADDR, PT_DATA_ADDR and
14274 PT_TEXT_END_ADDR guards. Update comments.
14275 (linux_target_op) <read_offsets>: Conditionally define to
14276 linux_read_offsets if the target is UCLIBC and if it defines
14277 PT_TEXT_ADDR, PT_DATA_ADDR and PT_TEXT_END_ADDR.
14278
14279 2013-05-06 Sandra Loosemore <sandra@codesourcery.com>
14280 Andrew Jenner <andrew@codesourcery.com>
14281
14282 * Makefile.in (SFILES): Add linux-nios2-low.c.
14283 (clean): Add action to delete nios2-linux.c.
14284 (nios2-linux.c): New rule.
14285 * configure.srv: Add nios2*-*-linux*.
14286 * linux-nios2-low.c: New.
14287
14288 2013-05-03 Hafiz Abid Qadeer <abidh@codesourcery.com>
14289
14290 * tracepoint.c (cmd_qtinit): Call 'stop_tracing'.
14291
14292 2013-04-25 Hui Zhu <hui@codesourcery.com>
14293
14294 PR gdb/15186
14295 * ax.c (ax_printf): Add fflush.
14296
14297 2013-04-22 Tom Tromey <tromey@redhat.com>
14298
14299 * Makefile.in (SFILES): Add filestuff.c.
14300 (OBS): Add filestuff.o.
14301 (filestuff.o): New target.
14302 * config.in, configure: Rebuild.
14303 * configure.ac: Check for fdwalk, pipe2.
14304
14305 2013-04-17 Pedro Alves <palves@redhat.com>
14306
14307 * configure.ac (USE_THREAD_DB): Delete variable.
14308 (if test "$srv_linux_thread_db" = "yes"): AC_DEFINE USE_THREAD_DB.
14309 Don't AC_SUBST USE_THREAD_DB.
14310 * Makefile.in (INTERNAL_CFLAGS): Remove @USE_THREAD_DB@.
14311 * config.in, configure: Regenerate.
14312
14313 2013-04-16 Pedro Alves <palves@redhat.com>
14314
14315 * linux-low.h (struct lwp_info) <thread_known>: Move under
14316 the USE_THREAD_DB #ifdef.
14317
14318 2013-04-16 Pedro Alves <palves@redhat.com>
14319
14320 * Makefile.in (INTERNAL_CFLAGS): Add @USE_THREAD_DB@.
14321 (linux-low.o): Delete rule.
14322 * linux-low.h: Always include "gdb_thread_db.h" instead of
14323 conditionally including thread_db.h.
14324 (struct lwp_info) <th>: Guard with #ifdef USE_THREAD_DB instead of
14325 HAVE_THREAD_DB_H.
14326
14327 2013-04-07 Jan Kratochvil <jan.kratochvil@redhat.com>
14328
14329 * Makefile.in (install-only): Fix make install regression.
14330
14331 2013-04-05 Jan Kratochvil <jan.kratochvil@redhat.com>
14332
14333 Convert man pages to texinfo, new gdbinit.5 texinfo page.
14334 * Makefile.in (install-only): Remove $(man1dir) and gdbserver.1
14335 installation.
14336 * gdbserver.1: Remove.
14337
14338 2013-03-22 Pedro Alves <palves@redhat.com>
14339
14340 * linux-low.c (handle_extended_wait): Don't call
14341 linux_enable_event_reporting.
14342
14343 2013-03-15 Tony Theodore <tonyt@logyst.com>
14344
14345 PR build/9098:
14346 * Makefile.in (SHELL): Use @SHELL@.
14347
14348 2013-03-14 Sergio Durigan Junior <sergiodj@redhat.com>
14349
14350 * tracepoint.c (cmd_qtv): Initialize `val' with zero, silencing
14351 compiler warning.
14352
14353 2013-03-13 Joel Brobecker <brobecker@adacore.com>
14354
14355 * linux-low.c (linux_target_ops) [!HAVE_LINUX_BTRACE]:
14356 Remove extraneous NULL element.
14357
14358 2013-03-13 Yao Qi <yao@codesourcery.com>
14359
14360 * tracepoint.c (traceframe_read_tsv): Look for the last matched
14361 'V' block in trace frame.
14362
14363 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
14364
14365 * target.h (struct target_ops): Add btrace ops.
14366 (target_supports_btrace): New macro.
14367 (target_enable_btrace): New macro.
14368 (target_disable_btrace): New macro.
14369 (target_read_btrace): New macro.
14370 * gdbthread.h (struct thread_info): Add btrace field.
14371 * server.c: Include btrace-common.h.
14372 (handle_btrace_general_set): New function.
14373 (handle_btrace_enable): New function.
14374 (handle_btrace_disable): New function.
14375 (handle_general_set): Call handle_btrace_general_set.
14376 (handle_qxfer_btrace): New function.
14377 (struct qxfer qxfer_packets[]): Add btrace entry.
14378 * inferiors.c (remove_thread): Disable btrace.
14379 * linux-low: Include linux-btrace.h.
14380 (linux_low_enable_btrace): New function.
14381 (linux_low_read_btrace): New function.
14382 (linux_target_ops): Add btrace ops.
14383 * configure.srv (i[34567]86-*-linux*): Add linux-btrace.o.
14384 Add srv_linux_btrace=yes.
14385 (x86_64-*-linux*): Add linux-btrace.o.
14386 Add srv_linux_btrace=yes.
14387 * configure.ac: Define HAVE_LINUX_BTRACE.
14388 * config.in: Regenerated.
14389 * configure: Regenerated.
14390
14391 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
14392
14393 * server.c (handle_qxfer): Preserve error message if -3 is
14394 returned.
14395 (qxfer): Document the -3 return value.
14396
14397 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
14398
14399 * Makefile.in (SFILES): Add $(srcdir)/common/linux-btrace.c.
14400 (linux_btrace_h): New variable.
14401 (linux-btrace.o): New rule.
14402
14403 2013-03-08 Stan Shebs <stan@codesourcery.com>
14404 Hafiz Abid Qadeer <abidh@codesourcery.com>
14405
14406 * tracepoint.c (trace_buffer_size): New global.
14407 (DEFAULT_TRACE_BUFFER_SIZE): New define.
14408 (init_trace_buffer): Change to one-argument function. Allocate
14409 trace buffer memory.
14410 (handle_tracepoint_general_set): Call cmd_bigqtbuffer_size to
14411 handle QTBuffer:size packet.
14412 (cmd_bigqtbuffer_size): New function.
14413 (initialize_tracepoint): Call init_trace_buffer with
14414 DEFAULT_TRACE_BUFFER_SIZE.
14415 * server.c (handle_query): Add QTBuffer:size in the
14416 supported packets.
14417
14418 2013-03-07 Yao Qi <yao@codesourcery.com>
14419
14420 * tracepoint.c (cur_action, cur_step_action): Make them unsigned.
14421 (cmd_qtfp): Initialize cur_action and cur_step_action 0 instead
14422 of -1.
14423 (cmd_qtsp): Adjust condition. Do post increment.
14424 Set cur_action and cur_step_action back to 0.
14425
14426 2013-03-07 Jeremy Bennett <jeremy.bennett@embecosm.com>
14427
14428 PR server/15236
14429 * linux-low.c (linux_write_memory): Return early success if LEN is
14430 zero.
14431
14432 2013-03-05 Corinna Vinschen <vinschen@redhat.de>
14433
14434 * configure.srv: Add x86_64-*-cygwin* as target.
14435
14436 2013-02-28 Tom Tromey <tromey@redhat.com>
14437
14438 * configure.ac: Invoke AC_SYS_LARGEFILE.
14439 * configure, config.in: Rebuild.
14440
14441 2013-02-28 Corinna Vinschen <vinschen@redhat.com>
14442
14443 * win32-low.c: Throughout, fix format strings and casts of
14444 printf-like functions to avoid type related warnings on all
14445 platforms.
14446 (get_child_debug_event): Print dwDebugEventCode as hex since
14447 that's how it's usually documented.
14448
14449 2013-02-28 Yao Qi <yao@codesourcery.com>
14450
14451 * tracepoint.c (cmd_qtbuffer): Call phex_nz instead of
14452 pulongest.
14453
14454 2013-02-27 Jiong Wang <jiwang@tilera.com>
14455
14456 * Makefile.in (clean): Remove reg-tilegx.c, reg-tilegx32.c.
14457 (reg-tilegx32.c): New rule.
14458 * configure.srv (tilegx-*-linux*): Add reg-tilegx32.o to srv_regobj.
14459 * linux-tile-low.c (tile_arch_setup): New function. Invoke
14460 different register info initializer according to elf class.
14461 (init_registers_tilgx32): New function. The tilegx32 register info
14462 initializer.
14463 (tile_fill_gregset): Use "uint_reg_t" to represent register size.
14464 (tile_store_gregset): Likewise.
14465
14466 2013-02-27 Yao Qi <yao@codesourcery.com>
14467
14468 * server.c (process_point_options): Print debug message when
14469 debug_threads is true.
14470
14471 2013-02-26 Yao Qi <yao@codesourcery.com>
14472
14473 * tracepoint.c (cmd_qtbuffer): Don't set '\0' in OWN_BUF.
14474
14475 2013-02-19 Pedro Alves <palves@redhat.com>
14476 Kai Tietz <ktietz@redhat.com>
14477
14478 PR gdb/15161
14479
14480 * server.c (handle_query) <CRC check>: Use unpack_varlen_hex
14481 instead of strtoul to extract address from packet.
14482 (process_serial_event) <'z'>: Likewise.
14483
14484 2013-02-18 Yao Qi <yao@codesourcery.com>
14485
14486 * linux-bfin-low.c (the_low_target): Use NULL instead of 0.
14487
14488 2013-02-14 Pedro Alves <palves@redhat.com>
14489
14490 Plug memory leak.
14491
14492 * tracepoint.c (cmd_qtnotes): Free TRACING_USER_NAME,
14493 TRACING_NOTES and TRACING_STOP_NOTE before clobbering.
14494
14495 2013-02-14 Pedro Alves <palves@redhat.com>
14496
14497 * tracepoint.c (cmd_qtdpsrc): Use savestring.
14498
14499 2013-02-14 Pedro Alves <palves@redhat.com>
14500
14501 * tracepoint.c (save_string): Delete.
14502 (add_tracepoint_action): Use savestring instead of save_string.
14503
14504 2013-02-12 Pedro Alves <palves@redhat.com>
14505
14506 * linux-xtensa-low.c: Ditto.
14507 * xtensa-xtregs.c: Ditto.
14508
14509 2013-02-12 Sanimir Agovic <sanimir.agovic@intel.com>
14510
14511 * thread-db.c (thread_db_get_tls_address): NULL pointer check
14512 thread_db.
14513
14514 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
14515
14516 * linux-aarch64-low.c (aarch64_arch_setup): Clamp
14517 aarch64_num_wp_regs and aarch64_num_bp_regs to
14518 AARCH64_HWP_MAX_NUM and AARCH64_HBP_MAX_NUM respectively.
14519
14520 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
14521
14522 * linux-aarch64-low.c (ps_get_thread_area): Replace
14523 PTRACE_GET_THREAD_AREA with PTRACE_GETREGSET.
14524
14525 2013-02-04 Jim MacArthur <jim.macarthur@arm.com>
14526 Marcus Shawcroft <marcus.shawcroft@arm.com>
14527 Nigel Stephens <nigel.stephens@arm.com>
14528 Yufeng Zhang <yufeng.zhang@arm.com>
14529
14530 * Makefile.in (clean): Remove aarch64.c and aarch64-without-fpu.c.
14531 (aarch64.c, aarch64-without-fpu.c): New targets.
14532 * configure.srv (aarch64*-*-linux*): New.
14533 * linux-aarch64-low.c: New file.
14534
14535 2013-02-04 Marcus Shawcroft <marcus.shawcroft@arm.com>
14536
14537 * linux-low.c (handle_extended_wait, linux_create_inferior)
14538 (linux_attach_lwp_1, linux_kill_one_lwp, linux_attach_one_lwp)
14539 (dequeue_one_deferred_signal, linux_resume_one_thread)
14540 (fetch_register, linux_write_memory, linux_enable_event_reporting)
14541 (linux_tracefork_grandchild, linux_test_for_tracefork)
14542 (linux_read_offsets, linux_xfer_siginfo, linux_xfer_siginfo): Add
14543 PTRACE_ARG3_TYPE and PTRACE_ARG4_TYPE cast to ptrace arguments
14544 where the argument is 0.
14545
14546 2013-01-25 Yao Qi <yao@codesourcery.com>
14547
14548 * event-loop.c: Include "queue.h".
14549 (gdb_event_p): New typedef.
14550 (struct gdb_event) <next_event>: Remove.
14551 (event_queue): Change to QUEUE(gdb_event_p).
14552 (async_queue_event): Remove.
14553 (gdb_event_xfree): New.
14554 (initialize_event_loop): New.
14555 (process_event): Use API from QUEUE.
14556 (wait_for_event): Likewise.
14557 * server.c (main): Call initialize_event_loop.
14558 * server.h (initialize_event_loop): Declare.
14559
14560 2013-01-18 Yao Qi <yao@codesourcery.com>
14561
14562 * ax.h (struct eval_agent_expr_context): New.
14563 (gdb_eval_agent_expr): Update declaration.
14564 * ax.c (gdb_eval_agent_expr): Remove argument REGCACHE and
14565 TFRAME. Add new argument CTX.
14566 * server.h (struct eval_agent_expr_context): Declare.
14567 (agent_mem_read, agent_tsv_read): Update declaration.
14568 (agent_mem_read_string): Likewise.
14569 * tracepoint.c (eval_tracepoint_agent_expr): Remove.
14570 (add_traceframe_block): Add new argument TPOINT.
14571 Increase TPOINT->traceframe_usage.
14572 (do_action_at_tracepoint): Call gdb_eval_agent_expr instead of
14573 eval_tracepoint_agent_expr.
14574 (condition_true_at_tracepoint): Likewise.
14575 (agent_mem_read): Remove argument TFRAME. Add argument CTX.
14576 (agent_mem_read_string, agent_tsv_read): Likewise.
14577
14578 2013-01-16 Yao Qi <yao@codesourcery.com>
14579
14580 * linux-low.c (linux_resume_one_lwp): Don't check
14581 'lwp->bp_reinsert != 0'.
14582
14583 2013-01-07 Joel Brobecker <brobecker@adacore.com>
14584 Pedro Alves <palves@redhat.com>
14585
14586 * lynx-low.c (ptrace_request_to_str): Define a temporary
14587 macro and use it to simplify this function's implementation.
14588
14589 2013-01-07 Joel Brobecker <brobecker@adacore.com>
14590
14591 * lynx-low.c (lynx_resume): Call perror_with_name if lynx_ptrace
14592 sets errno.
14593
14594 2013-01-07 Joel Brobecker <brobecker@adacore.com>
14595
14596 * configure.srv (i[34567]86-*-lynxos*): Set srv_xmlfiles.
14597
14598 2013-01-07 Joel Brobecker <brobecker@adacore.com>
14599
14600 * configure.srv (powerpc-*-lynxos*): Set srv_xmlfiles.
14601
14602 2013-01-07 Joel Brobecker <brobecker@adacore.com>
14603
14604 * lynx-low.c (lynx_resume): Use the resume_info parameter
14605 to determine the ptid for the lynx_ptrace call, unless
14606 it is equal to minus_one_ptid, in which case we use the
14607 ptid of the current_inferior.
14608 (lynx_wait_1): After having received a thread create/exit
14609 event, resume the inferior's execution using the signaling
14610 thread's ptid, rather than the old ptid.
14611
14612 2013-01-07 Joel Brobecker <brobecker@adacore.com>
14613
14614 * lynx-low.c (lynx_resume): Delete variable ret.
14615
14616 2013-01-01 Joel Brobecker <brobecker@adacore.com>
14617
14618 * gdbreplay.c (gdbreplay_version): Update copyright year.
14619 * server.c (gdbserver_version): Likewise.
14620
14621 2012-12-17 Joel Brobecker <brobecker@adacore.com>
14622
14623 * lynx-low.c (lynx_wait_1): Add debug trace before adding
14624 new thread.
14625
14626 2012-12-17 Joel Brobecker <brobecker@adacore.com>
14627
14628 * lynx-low.c (ptrace_request_to_str): Add handling for
14629 PTRACE_GETTRACESIG.
14630
14631 2012-12-17 Joel Brobecker <brobecker@adacore.com>
14632
14633 * lynx-low.c (lynx_attach): Delete variable new_process.
14634
14635 2012-12-17 Joel Brobecker <brobecker@adacore.com>
14636
14637 * lynx-low.c (lynx_create_inferior): Delete variable
14638 new_process.
14639
14640 2012-12-17 Joel Brobecker <brobecker@adacore.com>
14641
14642 * lynx-low.c (ptrace_request_to_str): Do not handle
14643 PTRACE_GETTHREADLIST if this macro does not exist.
14644
14645 2012-12-15 Yao Qi <yao@codesourcery.com>
14646
14647 * Makefile.in (OBS): Add notif.o.
14648 * notif.c, notif.h: New.
14649 * server.c: Include "notif.h".
14650 (struct vstop_notif) <next>: Remove.
14651 <base>: New field.
14652 (queue_stop_reply): Update.
14653 (push_event, send_next_stop_reply): Remove.
14654 (discard_queued_stop_replies): Update.
14655 (notif_stop): New variable.
14656 (handle_v_stopped): Remove.
14657 (handle_v_requests): Don't call handle_v_stopped. Call
14658 handle_ack_notif instead.
14659 (queue_stop_reply_callback): Call notif_event_enque instead
14660 of queue_stop_reply.
14661 (handle_status): Don't call send_next_stop_reply, call
14662 notif_write_event instead.
14663 (kill_inferior_callback): Likewise.
14664 (detach_or_kill_inferior_callback): Likewise.
14665 (main): Call initialize_notif.
14666 (process_serial_event): Call QUEUE_is_empty.
14667 (handle_target_event): Call notif_push instead of push event.
14668 * server.h (push_event): Remove declaration.
14669
14670 2012-12-10 Tom Tromey <tromey@redhat.com>
14671
14672 * Makefile.in (DEPMODE, DEPDIR, depcomp, COMPILE.pre)
14673 (COMPILE.post, COMPILE, POSTCOMPILE, IPAGENT_COMPILE): New
14674 macros.
14675 (.c.o): Rewrite.
14676 (ax-ipa.o, tracepoint-ipa.o, utils-ipa.o, format-ipa.o)
14677 (common-utils-ipa.o, remote-utils-ipa.o, regcache-ipa.o)
14678 (i386-linux-ipa.o, linux-i386-ipa.o, linux-amd64-ipa.o)
14679 (amd64-linux-ipa.o, ax.o): Rewrite.
14680 (event-loop.o, hostio.o, hostio-errno.o, inferiors.o, mem-break.o)
14681 (proc-service.o, regcache.o, remote-utils.o, server.o, target.o)
14682 (thread-db.o, tracepoint.o, utils.o, gdbreplay.o, dll.o): Remove.
14683 (signals.o, linux-procfs.o, linux-ptrace.o, common-utils.o, vec.o)
14684 (gdb_vecs.o, xml-utils.o, linux-osdata.o, ptid.o, buffer.o)
14685 (format.o, agent.o, vasprintf.o, vsnprintf.o): Rewrite.
14686 (i386-low.o, i387-fp.o, linux-low.o, linux-arm-low.o)
14687 (linux-bfin-low.o, linux-cris-low.o, linux-crisv32-low.o)
14688 (linux-ia64-low.o, linux-m32r-low.o, linux-mips-low.o)
14689 (linux-ppc-low.o, linux-s390-low.o, linux-sh-low.o)
14690 (linux-tic6x-low.o, linux-x86-low.o, linux-xtensa-low.o)
14691 (linux-tile-low.o, lynx-low.o, lynx-ppc-low.o, nto-low.o)
14692 (nto-x86-low.o, linux-low.o, win32-low.o, win32-arm-low.o)
14693 (win32-i386-low.o, spu-low.o, reg-arm.o, arm-with-iwmmxt.o)
14694 (arm-with-vfpv2.o, arm-with-vfpv3.o, arm-with-neon.o, reg-bfin.o)
14695 (reg-cris.o, reg-crisv32.o, i386.o, i386-linux.o, i386-avx.o)
14696 (i386-avx-linux.o, i386-mmx.o, i386-mmx-linux.o, reg-ia64.o)
14697 (reg-m32r.o, reg-m68k.o, reg-cf.o, mips-linux.o, mips-dsp-linux.o)
14698 (mips64-linux.o, mips64-dsp-linux.o, powerpc-32.o, powerpc-32l.o)
14699 (powerpc-altivec32l.o, powerpc-cell32l.o, powerpc-vsx32l.o)
14700 (powerpc-isa205-32l.o, powerpc-isa205-altivec32l.o)
14701 (powerpc-isa205-vsx32l.o, powerpc-e500l.o, powerpc-64l.o)
14702 (powerpc-altivec64l.o, powerpc-cell64l.o, powerpc-vsx64l.o)
14703 (powerpc-isa205-64l.o, powerpc-isa205-altivec64l.o)
14704 (powerpc-isa205-vsx64l.o, s390-linux32.o, s390-linux32v1.o)
14705 (s390-linux32v2.o, s390-linux64.o, s390-linux64v1.o)
14706 (s390-linux64v2.o, s390x-linux64.o, s390x-linux64v1.o)
14707 (s390x-linux64v2.o, tic6x-c64xp-linux.o, tic6x-c64x-linux.o)
14708 (tic6x-c62x-linux.o, reg-sh.o, reg-sparc64.o, reg-spu.o, amd64.o)
14709 (amd64-linux.o, amd64-avx.o, amd64-avx-linux.o, x32.o)
14710 (x32-linux.o, x32-avx.o, x32-avx-linux.o, reg-xtensa.o)
14711 (reg-tilegx.o): Remove.
14712 (all_object_files): New macro.
14713 Include .deps files.
14714 * aclocal.m4, configure: Rebuild.
14715 * acinclude.m4: Include depstand.m4, lead-dot.m4.
14716 * configure.ac: Invoke ZW_CREATE_DEPDIR,
14717 ZW_PROG_COMPILER_DEPENDENCIES. Compute GMAKE condition.
14718
14719 2012-12-05 Tom Tromey <tromey@redhat.com>
14720
14721 PR gdb/14917:
14722 * server.h (current_insn_ptr, emit_error): Declare 'extern'.
14723
14724 2012-11-28 Markus Metzger <markus.t.metzger@intel.com>
14725
14726 * configure.ac: Check for linux/perf_event.h.
14727 * config.in: Regenerated.
14728 * configure: Regenerated.
14729
14730 2012-11-26 Maxime Villard <rustyBSD@gmx.fr>
14731
14732 * hostio.c (handle_readlink): Decrease buffer size
14733 parameter passed to readlink by one byte.
14734
14735 2012-11-26 Yao Qi <yao@codesourcery.com>
14736
14737 * configure.ac (build_warnings): Append '-Wempty-body'.
14738 * configure: Regenerated.
14739 * linux-low.c (linux_create_inferior): Use braces for empty 'if'
14740 body.
14741
14742 2012-11-15 Pierre Muller <muller@sourceware.org>
14743
14744 * configure.ac (AC_CHECK_HEADERS): Add wait.h header.
14745 * config.in: Regenerate.
14746 * configure: Regenerate.
14747 * linux-low.c: Use "gdb_stat.h" header instead of <sys/stat.h> header.
14748 Use "gdb_wait.h" header instead of <sys/wait.h> header.
14749 * lynx-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
14750 * remote-utils.c: Use "gdb_stat.h" header instead of <sys/stat.h>
14751 header.
14752 * server.c: Remove HAVE_WAIT_H conditional. Use "gdb_wait.h" header
14753 instead of <sys/wait.h> header.
14754 * spu-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
14755
14756 2012-11-13 Markus Metzger <markus.t.metzger@intel.com>
14757
14758 * Makefile.in: (INTERNAL_CFLAGS): Add -DGDBSERVER
14759 (various make rules): Remove -DGDBSERVER
14760
14761 2012-11-09 Yao Qi <yao@codesourcery.com>
14762
14763 * spu-low.c (current_ptid): Move it to ..
14764 * gdbthread.h: ... here. New.
14765 * remote-utils.c (read_ptid): Use macro 'current_ptid'.
14766 * server.c (myresume, process_serial_event): Likewise.
14767 * thread-db.c (thread_db_find_new_threads): Likewise.
14768 * tracepoint.c (run_inferior_command): Likewise.
14769
14770 2012-10-01 Andrew Burgess <aburgess@broadcom.com>
14771
14772 * server.c (handle_search_memory_1): Include access length in
14773 warning message.
14774
14775 2012-09-05 Michael Brandt <michael.brandt@axis.com>
14776
14777 * linux-crisv32-low.c: Fix compile errors.
14778
14779 2012-09-04 Yao Qi <yao@codesourcery.com>
14780
14781 * tracepoint.c (cmd_qtsv): Adjust debug message.
14782 Don't check CUR_TPOINT.
14783
14784 2012-08-28 Yao Qi <yao@codesourcery.com>
14785
14786 * ax.c, tracepoint.c: Replace ATTR_FORMAT with ATTRIBUTE_PRINTF.
14787 * server.h: Include 'libiberty.h' and 'ansidecl.h'.
14788 (ATTR_NORETURN, ATTR_FORMAT, ATTR_MALLOC): Remove.
14789 Remove declarations of xmalloc, xreallloc, xstrdup and
14790 freeargv.
14791 * Makefile.in (libiberty_h): New.
14792 (server_h): Append dependencies 'libiberty.h' and 'ansidecl.h'.
14793 (linux-bfin-low.o): Append dependency 'libiberty.h'.
14794
14795 2012-08-23 Yao Qi <yao@codesourcery.com>
14796
14797 * server.h: Remove declaration of 'xsnprintf'.
14798
14799 2012-08-22 Keith Seitz <keiths@redhat.com>
14800
14801 * server.h: Include build-gnulib-gbserver/config.h.
14802 * gdbreplay.c: Likewise.
14803
14804 2012-08-08 Doug Evans <dje@google.com>
14805
14806 * Makefile.in (SFILES): Add gdb_vecs.c.
14807 (OBS): Add gdb_vecs.o.
14808 (gdb_vecs_h, host_defs_h): New variables.
14809 (thread-db.o): Add $(gdb_vecs_h) dependency.
14810 (gdb_vecs.o): New rule.
14811 * thread-db.c: #include "gdb_vecs.h".
14812 (thread_db_load_search): Use a vector to iterate over path elements.
14813 Handle text appearing after "$pdir".
14814
14815 * configure.ac: Add check for strstr.
14816 * config.in: Regenerate.
14817 * configure: Regenerate.
14818
14819 2012-08-02 Ulrich Weigand <ulrich.weigand@linaro.org>
14820
14821 * hostio.c (handle_pread): If pread fails, fall back to attempting
14822 lseek/read.
14823 (handle_pwrite): Likewise for pwrite.
14824
14825 2012-08-01 Ulrich Weigand <ulrich.weigand@linaro.org>
14826
14827 * linux-arm-low.c (arm_linux_hw_point_initialize): Distinguish
14828 between unsupported TYPE and unimplementable ADDR/LEN combination.
14829 (arm_insert_point): Act on new return value.
14830
14831 2012-07-31 Pedro Alves <palves@redhat.com>
14832
14833 * server.c (process_point_options): Only skip tokens if we find
14834 one that is unrecognized. Don't treat 'X' specially while
14835 skipping unrecognized tokens.
14836
14837 2012-07-30 Ulrich Weigand <ulrich.weigand@linaro.org>
14838
14839 * linux-arm-low.c (arm_linux_hw_point_initialize): Do not attempt
14840 to 4-byte-align HW breakpoint addresses for Thumb.
14841
14842 2012-07-27 Yao Qi <yao@codesourcery.com>
14843
14844 PR remote/14161.
14845
14846 * server.h: Declare gdb_agent_about_to_close.
14847 * target.c (kill_inferior): Include "agent.h".
14848 New. Send command 'kill'.
14849 * target.h (kill_inferior): Removed macro.
14850 * tracepoint.c (gdb_agent_about_to_close): New.
14851 (gdb_agent_helper_thread): Handle command 'close'.
14852 Wait endlessly until the inferior stops.
14853 Install gdb_agent_remove_socket to atexit hook.
14854 (agent_socket_name): New static variable.
14855 (gdb_agent_socket_init): Replace local variable 'name' with
14856 'agent_socket_name'.
14857 (gdb_agent_remove_socket): New.
14858
14859 2012-07-27 Yao Qi <yao@codesourcery.com>
14860
14861 * server.c (process_point_options): Stop at 'X' when parsing.
14862
14863 2012-07-19 Michael Eager <eager@eagercon.com>
14864
14865 * i386-low.c (Z_packet_to_hw_type): Add Z_PACKET_HW_BP, translate
14866 to hw_execute.
14867 * linux-x86-low.c (x86_insert_point, x86_remove_point):
14868 Call i386_low_insert_watchpoint, i386_low_remove_watchpoint to add/del
14869 hardware breakpoint.
14870
14871 2012-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
14872
14873 * gdbserver/linux-low.c (initialize_low): Call
14874 linux_ptrace_init_warnings.
14875
14876 2012-07-02 Doug Evans <dje@google.com>
14877
14878 * mem-break.c (gdb_no_commands_at_breakpoint): Fix cast from
14879 pointer to int.
14880
14881 2012-07-02 Stan Shebs <stan@codesourcery.com>
14882
14883 * Makefile.in (WARN_CFLAGS_NO_FORMAT): Define.
14884 (ax.o): Add it to build rule.
14885 (ax-ipa.o): Ditto.
14886 (OBS): Add format.o.
14887 (IPA_OBS): Add format.o.
14888 * server.c (handle_query): Claim support for breakpoint commands.
14889 (process_point_options): Add command case.
14890 (process_serial_event): Leave running if there are printfs in
14891 effect.
14892 * mem-break.h (any_persistent_commands): Declare.
14893 (add_breakpoint_commands): Declare.
14894 (gdb_no_commands_at_breakpoint): Declare.
14895 (run_breakpoint_commands): Declare.
14896 * mem-break.c (struct point_command_list): New struct.
14897 (struct breakpoint): New field command_list.
14898 (any_persistent_commands): New function.
14899 (add_commands_to_breakpoint): New function.
14900 (add_breakpoint_commands): New function.
14901 (gdb_no_commands_at_breakpoint): New function.
14902 (run_breakpoint_commands): New function.
14903 * linux-low.c (linux_wait_1): Test for and run breakpoint commands
14904 locally.
14905 * ax.c: Include format.h.
14906 (ax_printf): New function.
14907 (gdb_eval_agent_expr): Add printf opcode.
14908
14909 2012-06-13 Yao Qi <yao@codesourcery.com>
14910
14911 * server.c (start_inferior): Remove duplicated writes to fields
14912 'last_resume_kind' and 'last_status' of 'current_inferior'.
14913
14914 2012-06-12 Yao Qi <yao@codesourcery.com>
14915 Pedro Alves <palves@redhat.com>
14916
14917 * linux-low.c (linux_set_resume_request): Simplify predicate. Add
14918 comment.
14919 * server.c (handle_v_cont): Extend comment.
14920
14921 2012-06-11 Yao Qi <yao@codesourcery.com>
14922
14923 * linux-low.c (linux_attach): Add 'static'.
14924
14925 2012-06-06 Yao Qi <yao@codesourcery.com>
14926
14927 * ax.c (gdb_eval_agent_expr): Print `top' in hex.
14928
14929 2012-06-01 Jan Kratochvil <jan.kratochvil@redhat.com>
14930
14931 Fix gcc -flto compilation warning.
14932 * server.c (main): Make variable multi_mode and attach volatile.
14933
14934 2012-05-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
14935
14936 * linux-low.c (get_r_debug): Disable code using DT_MIPS_RLD_MAP
14937 if the platform doesn't know about it.
14938
14939 2012-05-30 Jeff Kenton <jkenton@tilera.com>
14940
14941 * Makefile.in (SFILES): Add linux-tile-low.c.
14942 (linux-tile-low.o, reg-tilegx.o, reg-tilegx.c): New rules.
14943 * configure.srv: Handle tilegx-*-linux*.
14944 * linux-tile-low.c: New file.
14945
14946 2012-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
14947
14948 * linux-low.c (linux_qxfer_libraries_svr4): Return -1 if R_DEBUG is -1.
14949
14950 2012-05-24 Pedro Alves <palves@redhat.com>
14951
14952 PR gdb/7205
14953
14954 Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.
14955
14956 2012-05-24 Pedro Alves <palves@redhat.com>
14957
14958 PR gdb/7205
14959
14960 Replace target_signal with gdb_signal throughout.
14961
14962 2012-05-22 Maciej W. Rozycki <macro@codesourcery.com>
14963
14964 * linux-low.c (linux_store_registers): Avoid the copying sequence
14965 when no data has been retrieved by ptrace.
14966
14967 2012-05-22 Will Deacon <will.deacon@arm.com>
14968
14969 * linux-low (__UCLIBC__ && !(__UCLIBC_HAS_MMU__ || __ARCH_HAS_MMU__)):
14970 Include asm/ptrace.h.
14971 (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define only if not
14972 already defined.
14973
14974 2012-05-21 Maciej W. Rozycki <macro@codesourcery.com>
14975
14976 * linux-low.c (linux_store_registers): Don't re-retrieve data
14977 with ptrace that has already been obtained from /proc. Always
14978 copy any data retrieved with ptrace to the buffer supplied.
14979
14980 2012-05-11 Yao Qi <yao@codesourcery.com>
14981 Pedro Alves <palves@redhat.com>
14982
14983 * linux-low.c (enum stopping_threads_kind): New.
14984 (stopping_threads): Change type to `enum stopping_threads_kind'.
14985 (handle_extended_wait): If stopping and suspending threads, leave
14986 the new_lwp suspended too.
14987 (linux_wait_for_event): Adjust.
14988 (stop_all_lwps): Set `stopping_threads' to
14989 STOPPING_AND_SUSPENDING_THREADS or STOPPING_THREADS depending on
14990 whether we're suspending threads or just stopping them. Assert no
14991 recursion happens.
14992
14993 2012-04-29 Yao Qi <yao@codesourcery.com>
14994
14995 * server.h: Move some code to ...
14996 * gdbthread.h: ... here. New.
14997 * Makefile.in (inferiors.o, regcache.o): Depends on gdbthread.h
14998 (remote-utils.o, server.o, target.o tracepoint.o): Likewise.
14999 (nto-low.o, win32-low.o): Likewise.
15000 * inferiors.c, linux-low.h, nto-low.c: Include gdbthread.h.
15001 * regcache.c, remote-utils.c, server.c: Likewise.
15002 * target.c, tracepoint.c, win32-low.c: Likewise.
15003
15004 2012-04-24 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
15005
15006 * linux-low.h (PTRACE_ARG3_TYPE): Move macro from linux-low.c.
15007 (PTRACE_ARG4_TYPE): Likewise.
15008 (PTRACE_XFER_TYPE): Likewise.
15009 * linux-arm-low.c (arm_prepare_to_resume): Cast third argument of
15010 ptrace to PTRACE_ARG3_TYPE.
15011 * linux-low.c (PTRACE_ARG3_TYPE): Move macro to linux-low.h.
15012 (PTRACE_ARG4_TYPE): Likewise.
15013 (PTRACE_XFER_TYPE): Likewise.
15014 (linux_detach_one_lwp): Cast fourth argument of
15015 ptrace to long then PTRACE_ARG4_TYPE.
15016 (regsets_fetch_inferior_registers): Cast third argument of
15017 ptrace to long then PTRACE_ARG3_TYPE.
15018 (regsets_store_inferior_registers): Likewise.
15019
15020 2012-04-20 Pedro Alves <palves@redhat.com>
15021
15022 * configure: Regenerate.
15023
15024 2012-04-19 Pedro Alves <palves@redhat.com>
15025
15026 * Makefile.in (GNULIB_BUILDDIR): New.
15027 (LIBGNU, INCGNU, GNULIB_H): Adjust.
15028 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): New.
15029 (all, install-only, uninstall, clean-info, all-lib, clean): No
15030 longer pass GNULIB_FLAGS_TO_PASS. Use subdir_do.
15031 (maintainer-clean realclean distclean): Use subdir_do.
15032 (subdir_do): New.
15033 (gnulib/import/Makefile): Adjust. Replace gnulib/import with
15034 $(GNULIB_BUILDDIR). Don't pass argument to config.status.
15035 * acinclude.m4: Include acx_configure_dir.m4.
15036 * configure.ac: Remove gl_EARLY, gl_INIT, and AM_INIT_AUTOMAKE
15037 calls. Call AC_PROG_RANLIB. Configure gnulib using
15038 ACX_CONFIGURE_DIR.
15039 (GNULIB): New.
15040 (GNULIB_STDINT_H): Adjust.
15041 (AC_OUTPUT): Don't output gnulib/Makefile anymore.
15042 * gdbreplay.c: Include build-gnulib/config.h.
15043 * server.h: Likewise.
15044 * aclocal.m4: Regenerate.
15045 * config.in: Regenerate.
15046 * configure: Regenerate.
15047
15048 2012-04-19 Pedro Alves <palves@redhat.com>
15049
15050 * Makefile.in (LIBGNU, INCGNU): Adjust.
15051 (GNULIB_FLAGS_TO_PASS, GNULIB_H): Adjust.
15052 (all, install-only, uninstall, clean-info, all-lib, clean)
15053 (maintainer-clean, Makefile, gnulib/Makefile): Adjust.
15054 * configure.ac: Adjust AC_OUTPUT output.
15055 * aclocal.m4: Regenerate.
15056 * configure: Regenerate.
15057
15058 2012-04-19 Pedro Alves <palves@redhat.com>
15059
15060 * Makefile.in (generated_files): New.
15061 (server_h): Remove the explicit dependency on config.h, and depend
15062 on $generated_files.
15063
15064 2012-04-19 Pedro Alves <palves@redhat.com>
15065
15066 * Makefile.in (INCGNU): Add -Ignulib.
15067
15068 2012-04-19 Pedro Alves <palves@redhat.com>
15069
15070 * Makefile.in (GNULIB_INCLUDE_DIR): Rename to ...
15071 (INCGNU): ... this, and spell out -I here.
15072 (GNULIB_LIB): Rename to ...
15073 (LIBGNU): ... this.
15074 (INCLUDE_CFLAGS, gdbserver$(EXEEXT), $(GNULIB_LIB) rule): Adjust.
15075
15076 2012-04-19 Pedro Alves <palves@redhat.com>
15077
15078 * config.in: Regenerate.
15079
15080 2012-04-19 Pedro Alves <palves@redhat.com>
15081
15082 * configure.ac: Remove AC_CHECK_DECLS check for memmem.
15083 * server.h (memmem): Remove declaration.
15084 * config.in: Regenerate.
15085 * configure: Regenerate.
15086
15087 2012-04-19 Yao Qi <yao@codesourcery.com>
15088
15089 * Makefile.in (SFILES): Add common/vec.c.
15090 (OBS): Add vec.o.
15091 (vec.o): New rule.
15092
15093 2012-04-19 Yao Qi <yao@codesourcery.com>
15094
15095 * remote-utils.c (prepare_resume_reply): Replace with macro
15096 target_core_of_thread.
15097 * server.c (handle_qxfer_threads_proper): Likewise.
15098 * target.h (traget_core_of_thread): New macro.
15099
15100 2012-04-18 Pedro Alves <palves@redhat.com>
15101
15102 * aclocal.m4: Regenerate.
15103 * configure: Regenerate.
15104
15105 2012-04-16 Yao Qi <yao@codesourcery.com>
15106
15107 * tracepoint.c (cmd_qtstart): Download tracepoints even when they are
15108 duplicated on address.
15109
15110 2012-04-16 Yao Qi <yao@codesourcery.com>
15111
15112 * tracepoint.c (COPY_FIELD_TO_BUF): New macro.
15113 (struct tracepoint_action_ops) <send>: New field.
15114 (m_tracepoint_action_send, r_tracepoint_action_send): New.
15115 (agent_expr_send, x_tracepoint_action_send): New.
15116 (l_tracepoint_action_send): New.
15117 (cmd_qtdp): Download and install tracepoint
15118 according to `use_agent'.
15119 (run_inferior_command): Add one more parameter `len'.
15120 Update callers.
15121 (tracepoint_send_agent): New.
15122 (cmd_qtdp, cmd_qtstart): Call tracepoint_send_agent.
15123
15124 2012-04-16 Yao Qi <yao@codesourcery.com>
15125
15126 * tracepoint.c (download_tracepoints): Moved to ...
15127 (cmd_qtstart): ... here.
15128
15129 2012-04-14 Yao Qi <yao@codesourcery.com>
15130
15131 * tracepoint.c: Include inttypes.h.
15132 (struct collect_memory_action): Use sized types.
15133 (struct tracepoint): Likewise.
15134 (cmd_qtdp, stop_tracing): Update print specifiers.
15135 (cmd_qtp, response_tracepoint): Likewise.
15136 (collect_data_at_tracepoint): Likewise.
15137 (collect_data_at_step): Likewise.
15138
15139 2012-04-14 Yao Qi <yao@codesourcery.com>
15140
15141 Import gnulib module inttypes.
15142 * aclocal.m4, config.in, configure: Regenerated.
15143
15144 2012-04-14 Yao Qi <yao@codesourcery.com>
15145
15146 * Makefile.in (maintainer-clean, realclean, distclean): Remove
15147 Makefile and config.status at last.
15148
15149 2012-04-13 Yao Qi <yao@codesourcery.com>
15150
15151 * tracepoint.c: Include stdint.h unconditionally.
15152
15153 2012-04-13 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
15154
15155 * acinclude.m4 (GDBSERVER_HAVE_THREAD_DB_TYPE): New macro based
15156 on BFD_HAVE_SYS_PROCFS_TYPE.
15157 * configure.ac: Look for lwpid_t and psaddr_t in libthread_db.h.
15158 * configure: Regenerate.
15159 * config.in: Likewise.
15160
15161 2012-04-13 H.J. Lu <hongjiu.lu@intel.com>
15162
15163 * Makefile.in (clean): Also remove x32.c x32-linux.c
15164 x32-avx.c x32-avx-linux.c.
15165 (x32.o): New target.
15166 (x32.c): Likewise.
15167 (x32-linux.o): Likewise.
15168 (x32-linux.c): Likewise.
15169 (x32-avx.o): Likewise.
15170 (x32-avx.c): Likewise.
15171 (x32-avx-linux.o): Likewise.
15172 (x32-avx-linux.c): Likewise.
15173
15174 * configure.srv (srv_amd64_regobj): Add x32.o x32-avx.o.
15175 (srv_amd64_linux_regobj): Add x32-linux.o x32-avx-linux.o.
15176 (srv_i386_64bit_xmlfiles): Add i386/x32-core.xml.
15177 (srv_amd64_xmlfiles): Add i386/x32.xml i386/x32-avx.xml.
15178 (srv_amd64_linux_xmlfiles): Add i386/x32-linux.xml
15179 i386/x32-avx-linux.xml.
15180
15181 * linux-x86-low.c (init_registers_x32_linux): New prototype.
15182 (init_registers_x32_avx_linux): Likwise.
15183 (x86_linux_update_xmltarget): Call init_registers_x32_linux
15184 or init_registers_x32_avx_linux if linux_is_elf64 is false.
15185
15186 2012-04-13 Pedro Alves <palves@redhat.com>
15187
15188 * Makefile.in (GNULIB_FLAGS_TO_PASS): New.
15189 (FLAGS_TO_PASS): Don't change or set $top_srcdir, $srcdir and VPATH.
15190 (all, uninstall, clean-info, all-lib, clean, maintainer-clean)
15191 (realclean, distclean): Explicitly pass $GNULIB_FLAGS_TO_PASS to
15192 the sub-make.
15193
15194 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
15195
15196 * linux-x86-low.c (compat_x32_clock_t): New.
15197 (compat_x32_siginfo_t): Likewise.
15198 (compat_x32_siginfo_from_siginfo): Likewise.
15199 (siginfo_from_compat_x32_siginfo): Likewise.
15200 (linux_is_elf64): Likewise.
15201 (x86_siginfo_fixup): Call compat_x32_siginfo_from_siginfo
15202 and siginfo_from_compat_x32_siginfo for x32.
15203 (x86_arch_setup): Set linux_is_elf64.
15204
15205 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
15206
15207 PR gdb/13969
15208 * linux-low.c (linux_pid_exe_is_elf_64_file): Also return the
15209 e_machine field.
15210 (linux_qxfer_libraries_svr4): Update call to elf_64_file_p.
15211 * linux-low.h (linux_pid_exe_is_elf_64_file): Updated.
15212 * linux-x86-low.c (x86_arch_setup): Check if GDBserver is
15213 compatible with process.
15214
15215 2012-04-12 Yao Qi <yao@codesourcery.com>
15216
15217 * Makefile.in: Define abs_top_srcdir and abs_srcdir.
15218 (INCLUDE_CFLAGS): Append GNULIB_INCLUDE_DIR.
15219 (install-only, install-info, clean): Handle sub dir gnulib.
15220 (all-lib, am--refresh): New targets.
15221 (memmem.o): Remove target.
15222 * configure.ac: Remove AC_CONFIG_LIBOBJ_DIR.
15223 Invoke gl_EARLY. Invoke AC_CHECK_PROGS for make.
15224 (AC_REPLACE_FUNCS): Remove memmem.
15225 Invoke gl_INIT and AM_INIT_AUTOMAKE.
15226 (AC_OUTPUT): Generate Makefile in gnulib/.
15227 * aclocal.m4, config.in, configure: Regenerated.
15228
15229 2012-04-10 Maciej W. Rozycki <macro@codesourcery.com>
15230
15231 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP.
15232
15233 2012-04-05 Pedro Alves <palves@redhat.com>
15234
15235 -Werror=strict-aliasing
15236
15237 * spu-low.c (parse_spufs_run): Avoid dereferencing type-punned
15238 pointer.
15239
15240 2012-04-04 Pedro Alves <palves@redhat.com>
15241
15242 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
15243 (sparc_store_gregset_from_stack, sparc_store_gregset)
15244 (sparc_breakpoint_at): Fix formatting.
15245
15246 2012-03-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
15247
15248 * configure.ac: Check whether Elf32_auxv_t and Elf64_auxv_t
15249 are available.
15250 * linux-low.c [HAVE_ELF32_AUXV_T] (Elf32_auxv_t): Add typedef.
15251 [HAVE_ELF64_AUXV_T] (Elf64_auxv_t): Likewise.
15252 * config.in: Regenerate.
15253 * configure: Likewise.
15254
15255 2012-03-29 Pedro Alves <palves@redhat.com>
15256
15257 * linux-low.c (regsets_store_inferior_registers) [__sparc__]:
15258 Correct ptrace arguments.
15259
15260 2012-03-28 Pedro Alves <palves@redhat.com>
15261
15262 * linux-ia64-low.c (ia64_regmap): Map IA64_EC_REGNUM to PT_AR_EC.
15263 (IA64_GR0_REGNUM, IA64_FR0_REGNUM)
15264 (IA64_FR1_REGNUM): New defines.
15265 (ia64_fetch_register): New.
15266 (the_low_target): Install it.
15267 * linux-low.h (struct linux_target_ops) <fetch_register>: New
15268 field.
15269 * linux-low.c (linux_fetch_registers): Try the
15270 the_low_target.fetch_register hook first.
15271
15272 * linux-arm-low.c (the_low_target): Adjust.
15273 * linux-bfin-low.c (the_low_target): Adjust.
15274 * linux-cris-low.c (the_low_target): Adjust.
15275 * linux-crisv32-low.c (the_low_target): Adjust.
15276 * linux-m32r-low.c (the_low_target): Adjust.
15277 * linux-m68k-low.c (the_low_target): Adjust.
15278 * linux-mips-low.c (the_low_target): Adjust.
15279 * linux-ppc-low.c (the_low_target): Adjust.
15280 * linux-s390-low.c (the_low_target): Adjust.
15281 * linux-sh-low.c (the_low_target): Adjust.
15282 * linux-sparc-low.c (the_low_target): Adjust.
15283 * linux-tic6x-low.c (the_low_target): Adjust.
15284 * linux-x86-low.c (the_low_target): Adjust.
15285 * linux-xtensa-low.c (the_low_target): Adjust.
15286
15287 2012-03-26 Pedro Alves <palves@redhat.com>
15288
15289 * server.c (handle_qxfer_libraries): Don't bail early if
15290 the_target->qxfer_libraries_svr4 is not NULL.
15291
15292 2012-03-26 Pedro Alves <palves@redhat.com>
15293
15294 * linux-low.c (linux_qxfer_libraries_svr4): Fix pasto in comment.
15295
15296 2012-03-23 Pedro Alves <palves@redhat.com>
15297
15298 * linux-low.c (linux_qxfer_libraries_svr4): Terminate the
15299 "library-list-svr4" element's start tag when the the DSO list is
15300 empty.
15301
15302 2012-03-23 Pedro Alves <palves@redhat.com>
15303
15304 * linux-low.c (read_one_ptr): Read the inferior's pointer through
15305 a variable whose type size is the same as the inferior's pointer
15306 size.
15307
15308 2012-03-21 Thomas Schwinge <thomas@codesourcery.com>
15309
15310 * linux-arm-low.c (arm_stopped_by_watchpoint): Use siginfo_t instead of
15311 struct siginfo.
15312 * linux-low.c (siginfo_fixup, linux_xfer_siginfo): Likewise.
15313 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
15314 * linux-low.h: Include <signal.h>.
15315 (struct siginfo): Remove forward declaration.
15316 (struct linux_target_ops) <siginfo_fixup>: Use siginfo_t instead of
15317 struct siginfo.
15318
15319 2012-03-21 Mike Frysinger <vapier@gentoo.org>
15320
15321 * .gitignore: Ignore more files.
15322
15323 2012-03-19 Pedro Alves <palves@redhat.com>
15324 Jan Kratochvil <jan.kratochvil@redhat.com>
15325
15326 * server.c (cont_thread, general_thread): Add describing comments.
15327 (start_inferior): Clear `cont_thread'.
15328 (handle_v_cont): Don't set `cont_thread' if resuming all threads
15329 of a process.
15330
15331 2012-03-15 Yao Qi <yao@codesourcery.com>
15332
15333 * tracepoint.c (install_tracepoint): Move duplicated tracepoint
15334 handling to ...
15335 (cmd_qtdp): ... here.
15336
15337 2012-03-15 Yao Qi <yao@codesourcery.com>
15338
15339 * tracepoint.c (struct tracepoint_action_ops): New.
15340 (struct tracepoint_action) [!IN_PROCESS_AGENT] <ops>: New field.
15341 (m_tracepoint_action_download): New.
15342 (r_tracepoint_action_download): New.
15343 (x_tracepoint_action_download): New.
15344 (l_tracepoint_action_download): New.
15345 (add_tracepoint_action): Install `action->ops' according type.
15346 (download_tracepoint_1): Move code `download' function pointer
15347 of various tracepoint_action_ops.
15348
15349 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
15350
15351 * linux-low.c (linux_attach_lwp_1): New variable buffer. Call
15352 linux_ptrace_attach_warnings.
15353
15354 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
15355
15356 * Makefile.in (linux-ptrace.o): New.
15357 * configure.srv (arm*-*-linux*, bfin-*-*linux*, crisv32-*-linux*)
15358 (cris-*-linux*, i[34567]86-*-linux*, ia64-*-linux*, m32r*-*-linux*)
15359 (m68*-*-linux*, m68*-*-uclinux*, mips*-*-linux*, powerpc*-*-linux*)
15360 (s390*-*-linux*, sh*-*-linux*, sparc*-*-linux*, tic6x-*-uclinux)
15361 (x86_64-*-linux*, xtensa*-*-linux*): Add linux-ptrace.o to SRV_TGTOBJ
15362 of these targets.
15363 * linux-low.c (linux_attach_lwp_1): Remove redundent else clause.
15364
15365 2012-03-08 Yao Qi <yao@codesourcery.com>
15366 Pedro Alves <palves@redhat.com>
15367
15368 Fix PR server/13392.
15369 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Check
15370 offset of JMP insn.
15371 * tracepoint.c (remove_tracepoint): New.
15372 (cmd_qtdp): Call remove_tracepoint when failed to install.
15373
15374 2012-03-07 Pedro Alves <palves@redhat.com>
15375
15376 * linux-low.c (get_detach_signal): New.
15377 (linux_detach_one_lwp): Get rid of a pending SIGSTOP with SIGCONT.
15378 Pass on pending signals to PTRACE_DETACH. Check the result of the
15379 ptrace call.
15380 * server.c (program_signals, program_signals_p): New.
15381 (handle_general_set): Handle QProgramSignals.
15382 * server.h (program_signals, program_signals_p): Declare.
15383
15384 2012-03-05 Pedro Alves <palves@redhat.com>
15385 Jan Kratochvil <jan.kratochvil@redhat.com>
15386
15387 * linux-low.c (get_dynamic): Don't warn when PT_PHDR isn't found.
15388 New comment why.
15389
15390 2012-03-03 Yao Qi <yao@codesourcery.com>
15391
15392 * tracepoint.c (tracepoint_look_up_symbols): Update call to
15393 agent_look_up_symbols.
15394
15395 2012-03-03 Yao Qi <yao@codesourcery.com>
15396
15397 * Makefile.in (linux-low.o): Keep dependence on agent.h.
15398 (linux-x86-low.o): Likewise.
15399 * server.h: Remove in_process_agent_loaded.
15400 * tracepoint.c (in_process_agent_loaded): Removed. Moved it
15401 common/agent.c.
15402 Update callers.
15403
15404 2012-03-03 Yao Qi <yao@codesourcery.com>
15405
15406 * tracepoint.c (gdb_agent_capability): New global.
15407 (in_process_agent_loaded_ust): Renamed to
15408 `in_process_agent_supports_ust'.
15409 Update callers.
15410 (in_process_agent_supports_ust): Call agent_capability_check.
15411 (clear_installed_tracepoints): Assert that agent supports
15412 agent.
15413
15414 2012-03-03 Yao Qi <yao@codesourcery.com>
15415
15416 * linux-low.c (linux_supports_agent): New.
15417 (linux_target_ops): Initialize field `supports_agent' with
15418 linux_supports_agent.
15419 * target.h (struct target_ops) <supports_agent>: New.
15420 (target_supports_agent): New macro.
15421 * server.c (handle_general_set): Handle packet 'QAgent'.
15422 (handle_query): Send `QAgent+'.
15423 * Makefile.in (server.o): Depends on agent.h.
15424
15425 2012-03-03 Yao Qi <yao@codesourcery.com>
15426
15427 * Makefile.in (OBS): Add agent.o.
15428 Add new rule for agent.o.
15429 Track dependence of tracepoint.c on agent.h.
15430 * tracepoint.c (run_inferior_command_1):
15431 (run_inferior_command): Call agent_run_command.
15432 (gdb_ust_connect_sync_socket): Deleted. Move it to
15433 common/agent.c.
15434 (resume_thread, stop_thread): Likewise.
15435 (gdb_ust_socket_init): Renamed to ...
15436 (gdb_agent_socket_init): ... New.
15437 (gdb_ust_thread): Renamed to ...
15438 (gdb_agent_helper_thread): ... New.
15439 (gdb_ust_init): Move some code to ...
15440 (gdb_agent_init): ... here. New.
15441 [HAVE_UST]: Call gdb_ust_init.
15442 (initialize_tracepoint_ftlib): Call gdb_agent_init.
15443 * configure.ac: Add `sys/un.h' to AC_CHECK_HEADERS.
15444 * config.in, configure: Regenerated.
15445
15446 2012-03-02 Pedro Alves <palves@redhat.com>
15447
15448 * inferiors.c (add_pid_to_list, pull_pid_from_list): Delete.
15449 * linux-low.c (struct simple_pid_list): New.
15450 (stopped_pids): New a struct simple_pid_list pointer.
15451 (add_to_pid_list, pull_pid_from_list): New.
15452 (handle_extended_wait): Don't assume the first signal new children
15453 report is SIGSTOP. Adjust call to pull_pid_from_list.
15454 (linux_wait_for_lwp): Adjust.
15455
15456 2012-03-02 Yao Qi <yao@codesourcery.com>
15457
15458 * tracepoint.c (do_action_at_tracepoint): Write `stop_pc' in
15459 debug log.
15460
15461 2012-03-02 Yao Qi <yao@codesourcery.com>
15462
15463 * tracepoint.c (collect_ust_data_at_tracepoint): Remove parameters
15464 `stop_pc' and `tpoint'. Update caller.
15465
15466 2012-03-01 Maciej W. Rozycki <macro@codesourcery.com>
15467
15468 * linux-low.h (linux_target_ops): Add regset_bitmap member.
15469 * linux-low.c (use_linux_regsets): New macro.
15470 [!HAVE_LINUX_REGSETS] (regsets_fetch_inferior_registers): Likewise.
15471 [!HAVE_LINUX_REGSETS] (regsets_store_inferior_registers): Likewise.
15472 (linux_register_in_regsets): New function.
15473 (usr_fetch_inferior_registers): Skip registers covered by
15474 regsets.
15475 (usr_store_inferior_registers): Likewise.
15476 (usr_fetch_inferior_registers): New macro.
15477 (usr_store_inferior_registers): Likewise.
15478 (linux_fetch_registers): Handle mixed regset/non-regset targets.
15479 (linux_store_registers): Likewise.
15480 * linux-mips-low.c (init_registers_mips_dsp_linux): New
15481 prototype.
15482 (init_registers_mips64_dsp_linux): Likewise.
15483 (init_registers_mips_linux): New macro.
15484 (init_registers_mips_dsp_linux): Likewise.
15485 (mips_dsp_num_regs): Likewise.
15486 (DSP_BASE, DSP_CONTROL): New fallback macros.
15487 (mips_base_regs): New macro.
15488 (mips_regmap): Use it. Fix the size.
15489 (mips_dsp_regmap): New variable.
15490 (mips_dsp_regset_bitmap): Likewise.
15491 (mips_arch_setup): New function.
15492 (mips_cannot_fetch_register): Use the_low_target.regmap rather
15493 than mips_regmap.
15494 (mips_cannot_store_register): Likewise.
15495 (the_low_target): Update .arch_setup, .num_regs and .regmap
15496 initializers. Add .regset_bitmap initializer.
15497 * linux-arm-low.c (the_low_target): Add .regset_bitmap
15498 initializer.
15499 * linux-bfin-low.c (the_low_target): Likewise.
15500 * linux-cris-low.c (the_low_target): Likewise.
15501 * linux-crisv32-low.c (the_low_target): Likewise.
15502 * linux-ia64-low.c (the_low_target): Likewise.
15503 * linux-m32r-low.c (the_low_target): Likewise.
15504 * linux-m68k-low.c (the_low_target): Likewise.
15505 * linux-ppc-low.c (the_low_target): Likewise.
15506 * linux-s390-low.c (the_low_target): Likewise.
15507 * linux-sh-low.c (the_low_target): Likewise.
15508 * linux-sparc-low.c (the_low_target): Likewise.
15509 * linux-tic6x-low.c (the_low_target): Likewise.
15510 * linux-x86-low.c (the_low_target): Likewise.
15511 * linux-xtensa-low.c (the_low_target): Likewise.
15512 * configure.srv <mips*-*-linux*>: Add mips-dsp-linux.o and
15513 mips64-dsp-linux.o to srv_regobj. Add mips-dsp-linux.xml,
15514 mips64-dsp-linux.xml, mips-dsp.xml and mips64-dsp.xml to
15515 srv_xmlfiles.
15516 * Makefile.in (mips-dsp-linux.o, mips-dsp-linux.c): New targets.
15517 (mips64-dsp-linux.o, mips64-dsp-linux.c): Likewise.
15518
15519 2012-02-29 Yao Qi <yao@codesourcery.com>
15520 Pedro Alves <palves@redhat.com>
15521
15522 * linux-low.c: (linux_wait_1): Call unsuspend_all_lwps when
15523 `step_over_finished' is true.
15524
15525 2012-02-27 Pedro Alves <palves@redhat.com>
15526
15527 * linux-low.c (pid_is_stopped): Delete, moved to common/.
15528 (linux_attach_lwp_1): Adjust to use linux_proc_pid_is_stopped.
15529
15530 2012-02-27 Pedro Alves <palves@redhat.com>
15531
15532 PR server/9684
15533 * linux-low.c (pid_is_stopped): New.
15534 (linux_attach_lwp_1): Handle attaching to 'T (stopped)' processes.
15535
15536 2012-02-25 Luis Machado <lgustavo@codesourcery.com>
15537
15538 * mem-break.c (clear_gdb_breakpoint_conditions): Fix de-allocation
15539 of conditions.
15540
15541 2012-02-24 Maciej W. Rozycki <macro@codesourcery.com>
15542
15543 * linux-mips-low.c (mips_regmap): Correct the index of $f9.
15544
15545 2012-02-24 Luis Machado <lgustavo@codesourcery>
15546
15547 * server.c (handle_query): Advertise support for target-side
15548 breakpoint condition evaluation.
15549 (process_point_options): New function.
15550 (process_serial_event): When inserting a breakpoint, check for
15551 a target-side condition that should be evaluated.
15552
15553 * mem-break.c: Include regcache.h and ax.h.
15554 (point_cond_list_t): New data structure.
15555 (breakpoint) <cond_list>: New field.
15556 (find_gdb_breakpoint_at): Make non-static.
15557 (delete_gdb_breakpoint_at): Clear any target-side
15558 conditions.
15559 (clear_gdb_breakpoint_conditions): New function.
15560 (add_condition_to_breakpoint): Likewise.
15561 (add_breakpoint_condition): Likewise.
15562 (gdb_condition_true_at_breakpoint): Likewise.
15563 (gdb_breakpoint_here): Return result directly instead
15564 of going through a local variable.
15565
15566 * mem-break.h (find_gdb_breakpoint_at): New prototype.
15567 (clear_gdb_breakpoint_conditions): Likewise.
15568 (add_breakpoint_condition): Likewise.
15569 (gdb_condition_true_at_breakpoint): Likewise.
15570
15571 * linux-low.c (linux_wait_1): Evaluate target-side breakpoint condition.
15572 (need_step_over_p): Take target-side breakpoint condition into
15573 consideration.
15574
15575 2012-02-24 Luis Machado <lgustavo@codesourcery>
15576
15577 * server.h: Include tracepoint.h.
15578 (agent_mem_read, agent_get_trace_state_variable_value,
15579 agent_set_trace_state_variable_value,
15580 agent_tsv_read, agent_mem_read_string, get_get_tsv_func_addr,
15581 get_set_tsv_func_addr): New prototypes.
15582
15583 * ax.h: New include file.
15584 * ax.c: New source file.
15585
15586 * tracepoint.c: Include ax.h.
15587 (gdb_agent_op, gdb_agent_op_names, gdb_agent_op_sizes,
15588 agent_expr, eval_result_type): Move to ax.h.
15589 (parse_agent_expr): Rename to ...
15590 (gdb_parse_agent_expr): ... this, make it non-static and move
15591 to ax.h.
15592 (unparse_agent_expr) Rename to ...
15593 (gdb_unparse_agent_expr): ... this, make it non-static and move
15594 to ax.h.
15595 (eval_agent_expr): Rename to ...
15596 (eval_tracepoint_agent_expr): ... this.
15597 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Remove
15598 forward declarations.
15599 (add_tracepoint_action): Call gdb_parse_agent_expr (...).
15600 (agent_get_trace_state_variable_value): New function.
15601 (agent_set_trace_state_variable_value): New function.
15602 (cmd_qtdp): Call gdb_parse_agent_expr (...).
15603 (response_tracepoint): Call gdb_unparse_agent_expr (...).
15604 (do_action_at_tracepoint): Call eval_tracepoint_agent_expr (...).
15605 (condition_true_at_tracepoint): Likewise.
15606 (parse_agent_expr): Rename to ...
15607 (gdb_parse_agent_expr): ... this and move to ax.c.
15608 (unparse_agent_expr): Rename to ...
15609 (gdb_unparse_agent_expr): ... this and move to ax.c.
15610 (gdb_agent_op_name): Move to ax.c.
15611 (eval_agent_expr): Rename to ...
15612 (gdb_eval_agent_expr): ... this, use regcache passed as parameter
15613 and move to ax.c.
15614 (eval_tracepoint_agent_expr): New function.
15615 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Make
15616 non-static.
15617 (current_insn_ptr, emit_error, struct bytecode_address): Move to
15618 ax.c.
15619 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul, emit_lsh,
15620 emit_rsh_signed, emit_rsh_unsigned, emit_ext, emit_log_not,
15621 emit_bit_and, emit_bit_or, emit_bit_xor, emit_bit_not, emit_equal,
15622 emit_less_signed, emit_less_unsigned, emit_ref, emit_if_goto,
15623 emit_goto, write_goto_address, emit_const, emit_reg, emit_pop,
15624 emit_stack, emit_zero_ext, emit_swap, emit_stack_adjust,
15625 emit_int_call_1, emit_void_call_2, emit_eq_goto, emit_ne_goto,
15626 emit_lt_goto, emit_ge_goto, emit_gt_goto, emit_le_goto): Move to ax.c.
15627 (get_get_tsv_func_addr, get_set_tsv_func_addr): New functions.
15628 (compile_bytecodes): Remove forward declaration.
15629 (is_goto_target): Move to ax.c.
15630 (compile_bytecodes): Move to ax.c and call
15631 agent_get_trace_state_variable_value (...) and
15632 agent_set_trace_state_variable_value (...).
15633
15634 * Makefile.in: Update ax.c and IPA dependencies.
15635
15636 2012-02-24 Pedro Alves <palves@redhat.com>
15637
15638 * tracepoint.c (cmd_bigqtbuffer): Rename as ...
15639 (cmd_bigqtbuffer_circular): ... this. Only handle
15640 'QTBuffer:circular:'.
15641 (handle_tracepoint_general_set): Adjust.
15642
15643 2012-02-16 Yao Qi <yao@codesourcery.com>
15644
15645 * inferiors.c: Move code to ...
15646 * dll.c: .... here. New.
15647 * server.h: Declare clear_dlls.
15648 * Makefile.in (SFILES): Add dll.c.
15649 (OBS): Add dll.o
15650 (dll.o): New rule.
15651
15652 2012-02-11 Yao Qi <yao@codesourcery.com>
15653
15654 * server.c: (handle_monitor_command): Add a new parameter
15655 `own_buf'.
15656 (handle_query): Update caller.
15657
15658 2012-02-09 Joel Brobecker <brobecker@adacore.com>
15659
15660 * configure.ac: Add readlink to AC_CHECK_FUNCS list.
15661 * configure, config.in: Regenerate.
15662 * hostio.c: Provide an alternate implementation if HAVE_READLINK
15663 is not defined.
15664
15665 2012-02-02 Pedro Alves <palves@redhat.com>
15666
15667 Try SIGKILL first, then PTRACE_KILL.
15668 * linux-low.c (linux_kill_one_lwp): New.
15669 (linux_kill_one_lwp): Rename to ...
15670 (kill_one_lwp_callback): ... this. Use the new
15671 linux_kill_one_lwp.
15672
15673 2012-02-02 Pedro Alves <palves@redhat.com>
15674
15675 * tracepoint.c (cmd_qtminftpilen): Return 0 if there's no current
15676 inferior.
15677
15678 2012-01-27 Pedro Alves <palves@redhat.com>
15679
15680 * linux-low.c (linux_child_pid_to_exec_file): Delete.
15681 (elf_64_file_p): Make static.
15682 (linux_pid_exe_is_elf_64_file): New.
15683 * linux-low.h (linux_child_pid_to_exec_file, elf_64_file_p):
15684 Delete declarations.
15685 (linux_pid_exe_is_elf_64_file): Declare.
15686 * linux-x86-low.c (x86_arch_setup): Use
15687 linux_pid_exe_is_elf_64_file.
15688
15689 2012-01-25 Jan Kratochvil <jan.kratochvil@redhat.com>
15690
15691 * linux-low.c (linux_wait_for_event_1): Rename to ...
15692 (linux_wait_for_event): ... here and merge it with former
15693 linux_wait_for_event - new variable wait_ptid, use it.
15694 (linux_wait_for_event): Remove - merge it to linux_wait_for_event_1.
15695
15696 2012-01-23 Pedro Alves <palves@redhat.com>
15697
15698 * server.c (main): Avoid yet another case of infinite loop while
15699 detaching/killing after a longjmp.
15700
15701 2012-01-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15702
15703 Code cleanup.
15704 * linux-low.c (linux_wait_for_event_1): Use ptid_is_pid.
15705
15706 2012-01-20 Ulrich Weigand <ulrich.weigand@linaro.org>
15707
15708 * hostio.c (handle_readlink): New function.
15709 (handle_vFile): Call it to handle "vFile:readlink" packets.
15710
15711 2012-01-20 Pedro Alves <palves@redhat.com>
15712 Ulrich Weigand <ulrich.weigand@linaro.org>
15713
15714 * server.c (handle_v_requests): Only support vAttach and vRun to
15715 start multiple processes when in extended protocol mode.
15716
15717 2012-01-17 Pedro Alves <palves@redhat.com>
15718
15719 * tracepoint.c (initialize_tracepoint): Use mmap instead of
15720 memalign plus mprotect to allocate the scratch buffer.
15721
15722 2012-01-13 Pedro Alves <palves@redhat.com>
15723
15724 * server.c (attach_inferior): Clear `cont_thread'.
15725
15726 2012-01-13 Pedro Alves <palves@redhat.com>
15727
15728 * server.c (main): Avoid infinite loop while detaching/killing
15729 after a longjmp.
15730
15731 2012-01-09 Doug Evans <dje@google.com>
15732
15733 * server.c (start_inferior): Set last_ptid in --wrapper case.
15734
15735 2012-01-06 Yao Qi <yao@codesourcery.com>
15736
15737 * tracepoint.c [IN_PROCESS_AGENT] (debug_threads): Macro
15738 defined.
15739 [IN_PROCESS_AGENT] (debug_agent): New global variable.
15740
15741 2012-01-04 Yao Qi <yao@codesourcery.com>
15742
15743 * tracepoint.c (cmd_qtdp): Print debug message
15744 for static tracepoint.
15745
15746 2012-01-04 Yao Qi <yao@codesourcery.com>
15747
15748 * tracepoint.c (trace_vdebug): Differentiate debug message
15749 between gdbserver and IPA.
15750
15751 2012-01-03 Yao Qi <yao@codesourcery.com>
15752
15753 * tracepoint.c (tracepoint_was_hit): Don't collect for
15754 static tracepoint.
15755
15756 2012-01-02 Joel Brobecker <brobecker@adacore.com>
15757
15758 * terminal.h: Reformat copyright header.
15759
15760 2012-01-02 Joel Brobecker <brobecker@adacore.com>
15761
15762 * server.c (gdbserver_version): Update copyright year.
15763 * gdbreplay.c (gdbreplay_version): Likewise.
15764
15765 2011-12-18 Jan Kratochvil <jan.kratochvil@redhat.com>
15766
15767 * linux-low.c (linux_create_inferior): Put empty if clause for write.
15768
15769 Revert:
15770 2011-12-18 Hui Zhu <teawater@gmail.com>
15771 * linux-low.c (linux_create_inferior): Save return value to ret.
15772
15773 2011-12-18 Hui Zhu <teawater@gmail.com>
15774
15775 * linux-low.c (linux_create_inferior): Save return value to ret.
15776
15777 2011-12-16 Doug Evans <dje@google.com>
15778
15779 * linux-low.c (linux_create_inferior): If stdio connection,
15780 redirect stdin from /dev/null, stdout to stderr.
15781 * remote-utils.c (remote_is_stdio): New static global.
15782 (remote_connection_is_stdio): New function.
15783 (remote_prepare): Handle stdio connection.
15784 (remote_open): Ditto.
15785 (remote_close): Don't close stdin for stdio connections.
15786 (read_prim,write_prim): New functions. Replace all calls to
15787 read/write to these.
15788 * server.c (main): Watch for "-" argument. Move call to
15789 remote_prepare before start_inferior.
15790 * server.h (STDIO_CONNECTION_NAME): New macro.
15791 (remote_connection_is_stdio): Declare.
15792
15793 * remote-utils.c (prepare_resume_reply): Remove extraneous \n
15794 in debugging output.
15795
15796 2011-12-15 Yao Qi <yao@codesourcery.com>
15797
15798 * tracepoint.c: Include sys/syscall.h.
15799 (gdb_ust_thread): Remove preprocessor conditional.
15800
15801 2011-12-14 Pedro Alves <pedro@codesourcery.com>
15802
15803 * linux-low.c (linux_detach_one_lwp): Call
15804 the_low_target.prepare_to_resume before detaching.
15805
15806 2011-12-14 Yao Qi <yao@codesourcery.com>
15807
15808 * tracepoint.c (gdb_ust_thread): Don't ignore return value
15809 of write.
15810
15811 2011-12-14 Yao Qi <yao@codesourcery.com>
15812
15813 * i386-low.c (i386_low_stopped_data_address): Initialize local
15814 variable `control'.
15815
15816 2011-12-13 Pedro Alves <pedro@codesourcery.com>
15817
15818 PR remote/13492
15819
15820 * i386-low.c (i386_low_stopped_data_address): Avoid fetching
15821 DR_CONTROL unless necessary. Extend comments.
15822 * linux-x86-low.c (x86_linux_prepare_to_resume): Don't write to
15823 DR0-3 if not used. If any watchpoint was set, clear DR_STATUS.
15824
15825 2011-12-13 Yao Qi <yao@codesourcery.com>
15826
15827 * tracepoint.c (trace_buffer_alloc): Replace magic numbers with
15828 macros.
15829 (upload_fast_traceframes, upload_fast_traceframes): Likewise.
15830
15831 2011-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
15832
15833 * linux-low.c (linux_kill): Skip PTRACE_KILL if LWP does not exist.
15834 Print new debug message for such case.
15835
15836 2011-12-06 Jan Kratochvil <jan.kratochvil@redhat.com>
15837
15838 Fix overlapping memcpy.
15839 * mem-break.c (set_raw_breakpoint_at): New variable buf. Use it for
15840 the read_inferior_memory transfer.
15841 (delete_fast_tracepoint_jump): New variable buf. Use it for the
15842 write_inferior_memory transfer.
15843 (set_fast_tracepoint_jump): New variable buf. Use it for the
15844 read_inferior_memory and write_inferior_memory transfers.
15845 (uninsert_fast_tracepoint_jumps_at, reinsert_fast_tracepoint_jumps_at)
15846 (delete_raw_breakpoint, uninsert_raw_breakpoint): New variable buf.
15847 Use it for the write_inferior_memory transfer.
15848 (check_mem_read, check_mem_write): New gdb_asserts for overlapping
15849 buffers.
15850
15851 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
15852
15853 * linux-low.c (fetch_register, store_register): Make code
15854 consistent, fix formatting.
15855
15856 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
15857
15858 * linux-low.c (usr_store_inferior_registers): Factor out code
15859 to handle individual registers into...
15860 (store_register): ... this new function.
15861
15862 2011-12-06 Ulrich Weigand <uweigand@de.ibm.com>
15863
15864 * Makefile.in (s390-linux32v1.o, s390-linux32v1.c): New rules.
15865 (s390-linux32v2.o, s390-linux32v2.c): Likewise.
15866 (s390-linux64v1.o, s390-linux64v1.c): Likewise.
15867 (s390-linux64v2.o, s390-linux64v2.c): Likewise.
15868 (s390x-linux64v1.o, s390x-linux64v1.c): Likewise.
15869 (s390x-linux64v2.o, s390x-linux64v2.c): Likewise.
15870 * configure.srv [s390*-*-linux*] (srv_regobj): Add new objects.
15871 (srv_xmlfiles): Add new XML files.
15872
15873 * linux-s390-low.c: Include "elf/common.h", <sys/ptrace.h>,
15874 and <sys/uio.h>.
15875 (PTRACE_GETREGSET, PTRACE_SETREGSET): Define if undefined.
15876 (init_registers_s390_linux32v1): Add prototype.
15877 (init_registers_s390_linux32v2): Likewise.
15878 (init_registers_s390_linux64v1): Likewise.
15879 (init_registers_s390_linux64v2): Likewise.
15880 (init_registers_s390x_linux64v1): Likewise.
15881 (init_registers_s390x_linux64v2): Likewise.
15882 (s390_num_regs): Increment to 52.
15883 (s390_regmap): Add orig_r2 register.
15884 (s390_num_regs_3264): Increment to 68.
15885 (s390_regmap_3264): Add orig_r2 register.
15886 (s390_collect_ptrace_register): Handle orig_r2 register.
15887 (s390_supply_ptrace_register): Likewise.
15888 (s390_fill_last_break): New function.
15889 (s390_store_last_break): Likewise.
15890 (s390_fill_system_call): New function.
15891 (s390_store_system_call): Likewise.
15892 (target_regsets): Handle NT_S390_LAST_BREAK and NT_S390_SYSTEM_CALL
15893 register sets.
15894 (s390_check_regset): New function.
15895 (s390_arch_setup): Check for presence of NT_S390_LAST_BREAK and
15896 NT_S390_SYSTEM_CALL regsets and use appropriate description.
15897 Update target_regsets for available register sets.
15898
15899 2011-12-02 Paul Pluzhnikov <ppluzhnikov@google.com>
15900 Jan Kratochvil <jan.kratochvil@redhat.com>
15901
15902 * linux-low.c (get_phdr_phnum_from_proc_auxv, get_dynamic, get_r_debug)
15903 (read_one_ptr, struct link_map_offsets, linux_qxfer_libraries_svr4):
15904 New.
15905 (struct linux_target_ops): Install linux_qxfer_libraries_svr4.
15906 * linux-low.h (struct process_info_private): New member r_debug.
15907 * server.c (handle_qxfer_libraries): Call
15908 the_target->qxfer_libraries_svr4.
15909 (handle_qxfer_libraries_svr4): New function.
15910 (qxfer_packets): New entry "libraries-svr4".
15911 (handle_query): Check QXFER_LIBRARIES_SVR4 and report libraries-svr4.
15912 * target.h (struct target_ops): New member qxfer_libraries_svr4.
15913 * remote.c (remote_xfer_partial): Call add_packet_config_cmd for
15914 PACKET_qXfer_libraries_svr4.
15915
15916 2011-11-30 Ulrich Weigand <uweigand@de.ibm.com>
15917
15918 * linux-s390-low.c (s390_collect_ptrace_register): Fully convert
15919 PSW address/mask between 8-byte and 16-byte formats.
15920 (s390_supply_ptrace_register): Likewise.
15921 (s390_get_pc, s390_set_pc): 4-byte PSW address always includes
15922 basic addressing mode bit.
15923
15924 2011-11-24 Stan Shebs <stan@codesourcery.com>
15925
15926 * tracepoint.c (cmd_qtstatus): Use plongest instead of %llx.
15927
15928 2011-11-17 Stan Shebs <stan@codesourcery.com>
15929
15930 * tracepoint.c (struct tracepoint): New field traceframe_usage.
15931 (tracing_start_time): New global.
15932 (tracing_stop_time): New global.
15933 (tracing_user_name): New global.
15934 (tracing_notes): New global.
15935 (tracing_stop_note): New global.
15936 (cmd_qtstart): Set traceframe_usage, start_time.
15937 (stop_tracing): Set stop_time.
15938 (cmd_qtstatus): Report additional status.
15939 (cmd_qtp): New function.
15940 (handle_tracepoint_query): Call it.
15941 (cmd_qtnotes): New function.
15942 (handle_tracepoint_general_set): Call it.
15943 (get_timestamp): Rename from tsv_get_timestamp.
15944
15945 2011-11-14 Stan Shebs <stan@codesourcery.com>
15946 Kwok Cheung Yeung <kcy@codesourcery.com>
15947
15948 * linux-x86-low.c (small_jump_insn): New.
15949 (i386_install_fast_tracepoint_jump_pad): Add arguments for
15950 trampoline and error message, build a trampoline and issue a small
15951 jump instruction to it.
15952 (x86_install_fast_tracepoint_jump_pad): Add arguments for
15953 trampoline and error message.
15954 (x86_get_min_fast_tracepoint_insn_len): New.
15955 (the_low_target): Add call to x86_get_min_fast_tracepoint_insn_len.
15956 * linux-low.h (struct linux_target_ops): Add arguments to
15957 install_fast_tracepoint_jump_pad operation, add new operation.
15958 * linux-low.c (linux_install_fast_tracepoint_jump_pad): Add
15959 arguments.
15960 (linux_get_min_fast_tracepoint_insn_len): New function.
15961 (linux_target_op): Add new operation.
15962 * tracepoint.c (gdb_trampoline_buffer): New IPA variable.
15963 (gdb_trampoline_buffer_end): Ditto.
15964 (gdb_trampoline_buffer_error): Ditto.
15965 (struct ipa_sym_addresses): Add fields for new IPA variables.
15966 (symbol_list): Add entries for new IPA variables.
15967 (struct tracepoint): Add fields to hold the address range of the
15968 trampoline used by the tracepoint.
15969 (trampoline_buffer_head): New static variable.
15970 (trampoline_buffer_tail): Ditto.
15971 (claim_trampoline_space): New function.
15972 (have_fast_tracepoint_trampoline_buffer): New function.
15973 (clone_fast_tracepoint): Fill in trampoline fields of tracepoint
15974 structure.
15975 (install_fast_tracepoint): Ditto, also add error buffer argument.
15976 (cmd_qtminftpilen): New function.
15977 (handle_tracepoint_query): Add response to qTMinFTPILen packet.
15978 (fast_tracepoint_from_trampoline_address): New function.
15979 (fast_tracepoint_collecting): Handle trampoline as part of jump
15980 pad space.
15981 (set_trampoline_buffer_space): New function.
15982 (initialize_tracepoint): Initialize new IPA variables.
15983 * target.h (struct target_ops): Add arguments to
15984 install_fast_tracepoint_jump_pad operation, add new
15985 get_min_fast_tracepoint_insn_len operation.
15986 (target_get_min_fast_tracepoint_insn_len): New.
15987 (install_fast_tracepoint_jump_pad): Add arguments.
15988 * server.h (IPA_BUFSIZ): Define.
15989 * linux-i386-ipa.c: Include extra header files.
15990 (initialize_fast_tracepoint_trampoline_buffer): New function.
15991 (initialize_low_tracepoint): Call it.
15992 * server.h (set_trampoline_buffer_space): Declare.
15993 (claim_trampoline_space): Ditto.
15994 (have_fast_tracepoint_trampoline_buffer): Ditto.
15995
15996 2011-11-14 Yao Qi <yao@codesourcery.com>
15997
15998 * server.c (handle_query): Handle InstallInTrace for qSupported.
15999 * tracepoint.c (add_tracepoint): Sort list.
16000 (install_tracepoint, download_tracepoint): New.
16001 (cmd_qtdp): Call them to install and download tracepoints.
16002 (sort_tracepoints): Removed.
16003 (cmd_qtstart): Update.
16004
16005 2011-11-14 Yao Qi <yao@codesourcery.com>
16006
16007 * mem-break.c (inc_ref_fast_tracepoint_jump): New.
16008 * mem-break.h: Declare.
16009 * tracepoint.c (cmd_qtstart): Move some code to ...
16010 (clone_fast_tracepoint, install_fast_tracepoint): ... here.
16011 New.
16012 (download_tracepoints): Move some code to ...
16013 (download_tracepoint_1): ... here. New.
16014
16015 2011-11-08 Yao Qi <yao@codesourcery.com>
16016
16017 * remote-utils.c (relocate_instruction): A comment fix.
16018
16019 2011-11-07 Joel Brobecker <brobecker@adacore.com>
16020
16021 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): Delete.
16022 (i386_dr_low_get_control, i386_dr_low_get_status): Use
16023 dr_status_mirror and dr_control_mirror from debug_reg_state.
16024 (i386_dr_low_get_status): Use debug_reg_state.dr_status_mirror
16025 (i386_initial_stuff): Remove use of deleted globals.
16026 (i386_get_thread_context, i386_set_thread_context,
16027 i386_thread_added): Use dr_status_mirror and dr_control_mirror
16028 from debug_reg_state.
16029
16030 2011-11-05 Yao Qi <yao@codesourcery.com>
16031
16032 * tracepoint.c (gdb_collect): Loop over tracepoints of same
16033 address as TPOINT's.
16034
16035 2011-11-02 Stan Shebs <stan@codesourcery.com>
16036
16037 * tracepoint.c (agent_mem_read_string): New function.
16038 (eval_agent_expr): Call it for tracenz.
16039 * server.c (handle_query): Report support for tracenz.
16040
16041 2011-11-02 Yao Qi <yao@codesourcery.com>
16042
16043 * tracepoint.c (cmd_qtstart): Remove unused local variables.
16044
16045 2011-11-02 Yao Qi <yao@codesourcery.com>
16046
16047 * target.h: Fix a typo in comment.
16048
16049 2011-10-31 Pedro Alves <pedro@codesourcery.com>
16050
16051 * mem-break.c (check_mem_write): Add `myaddr' parameter. Don't
16052 clobber the breakpoints' shadows with fast tracepoint jumps.
16053 * mem-break.h (check_mem_write): Add `myaddr' parameter.
16054 * target.c (write_inferior_memory): Also pass MYADDR down to
16055 check_mem_write.
16056
16057 2011-10-07 Ulrich Weigand <ulrich.weigand@linaro.org>
16058
16059 * configure.ac: Check support for personality routine.
16060 * configure: Regenerate.
16061 * config.in: Likewise.
16062 * linux-low.c: Include <sys/personality.h>.
16063 Define ADDR_NO_RANDOMIZE if necessary.
16064 (linux_create_inferior): Disable address space randomization when
16065 forking inferior, if requested.
16066 (linux_supports_disable_randomization): New function.
16067 (linux_target_ops): Install it.
16068 * server.h (disable_randomization): Declare.
16069 * server.c (disable_randomization): New global variable.
16070 (handle_general_set): Handle QDisableRandomization.
16071 (handle_query): Likewise for qSupported.
16072 (main): Support --disable-randomization and --no-disable-randomization
16073 command line arguments.
16074 * target.h (struct target_ops): Add supports_disable_randomization.
16075 (target_supports_disable_randomization): New macro.
16076
16077 2011-09-29 Mike Frysinger <vapier@gentoo.org>
16078
16079 * linux-low.c (target_loadseg): Add defined PTRACE_GETFDPIC to the
16080 ifdef check.
16081 [PT_GETDSBT] (target_loadmap): Wrap in a defined PT_GETDSBT check.
16082 [!PT_GETDSBT] (target_loadmap): New definition.
16083 (LINUX_LOADMAP, LINUX_LOADMAP_EXEC, LINUX_LOADMAP_INTERP): Define.
16084 (linux_read_loadmap): Change PTRACE_GETDSBT_EXEC to
16085 LINUX_LOADMAP_EXEC, PTRACE_GETDSBT_INTERP to LINUX_LOADMAP_INTERP,
16086 and PT_GETDSBT to LINUX_LOADMAP.
16087 [!PT_GETDSBT] (linux_read_loadmap): Define to NULL.
16088 (linux_target_ops): Delete unnecessary ifdef PT_GETDSBT check.
16089
16090 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
16091
16092 * linux-arm-low.c (struct arm_linux_hwbp_cap): Remove.
16093 (arm_linux_hwbp_cap): New static variable.
16094 (arm_linux_get_hwbp_cap): Replace by ...
16095 (arm_linux_init_hwbp_cap): ... this new function.
16096 (arm_linux_get_hw_breakpoint_count): Use arm_linux_hwbp_cap.
16097 (arm_linux_get_hw_watchpoint_count): Likewise.
16098 (arm_linux_get_hw_watchpoint_max_length): Likewise.
16099 (arm_arch_setup): Call arm_linux_init_hwbp_cap.
16100 (arm_prepare_to_resume): Use perror_with_name instead of error.
16101
16102 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
16103
16104 * linux-arm-low.c: Include <signal.h>.
16105 (PTRACE_GETHBPREGS, PTRACE_SETHBPREGS): Define if necessary.
16106 (struct arm_linux_hwbp_cap): New data type.
16107 (arm_hwbp_type, arm_hwbp_control_t): New typedefs.
16108 (struct arm_linux_hw_breakpoint): New data type.
16109 (MAX_BPTS, MAX_WPTS): Define.
16110 (struct arch_process_info, struct arch_lwp_info): New data types.
16111 (arm_linux_get_hwbp_cap): New function.
16112 (arm_linux_get_hw_breakpoint_count): Likewise.
16113 (arm_linux_get_hw_watchpoint_count): Likewise.
16114 (arm_linux_get_hw_watchpoint_max_length): Likewise.
16115 (arm_hwbp_control_initialize): Likewise.
16116 (arm_hwbp_control_is_enabled): Likewise.
16117 (arm_hwbp_control_is_initialized): Likewise.
16118 (arm_hwbp_control_disable): Likewise.
16119 (arm_linux_hw_breakpoint_equal): Likewise.
16120 (arm_linux_hw_point_initialize): Likewise.
16121 (struct update_registers_data): New data structure.
16122 (update_registers_callback: New function.
16123 (arm_insert_point): Likewise.
16124 (arm_remove_point): Likewise.
16125 (arm_stopped_by_watchpoint): Likewise.
16126 (arm_stopped_data_address): Likewise.
16127 (arm_new_process): Likewise.
16128 (arm_new_thread): Likewise.
16129 (arm_prepare_to_resume): Likewise.
16130 (the_low_target): Register arm_insert_point, arm_remove_point,
16131 arm_stopped_by_watchpoint, arm_stopped_data_address, arm_new_process,
16132 arm_new_thread, and arm_prepare_to_resume.
16133
16134 2011-09-15 Stan Shebs <stan@codesourcery.com>
16135
16136 * server.h (struct emit_ops): Add compare-goto fields.
16137 * tracepoint.c (gdb_agent_op_sizes): New table.
16138 (emit_eq_goto): New function.
16139 (emit_ne_goto): New function.
16140 (emit_lt_goto): New function.
16141 (emit_le_goto): New function.
16142 (emit_gt_goto): New function.
16143 (emit_ge_goto): New function.
16144 (is_goto_target): New function.
16145 (compile_bytecodes): Recognize special cases of compare-goto
16146 combinations and call specialized emitters for them.
16147 * linux-x86-low.c (amd64_emit_eq_goto): New function.
16148 (amd64_emit_ne_goto): New function.
16149 (amd64_emit_lt_goto): New function.
16150 (amd64_emit_le_goto): New function.
16151 (amd64_emit_gt_goto): New function.
16152 (amd64_emit_ge_goto): New function.
16153 (amd64_emit_ops): Add the new functions.
16154 (i386_emit_eq_goto): New function.
16155 (i386_emit_ne_goto): New function.
16156 (i386_emit_lt_goto): New function.
16157 (i386_emit_le_goto): New function.
16158 (i386_emit_gt_goto): New function.
16159 (i386_emit_ge_goto): New function.
16160 (i386_emit_ops): Add the new functions.
16161
16162 2011-09-08 Stan Shebs <stan@codesourcery.com>
16163
16164 * linux-x86-low.c (i386_emit_prologue): Save %ebx.
16165 (i386_emit_epilogue): Restore %ebx.
16166
16167 2011-08-31 Jie Zhang <jzhang918@gmail.com>
16168
16169 * server.c (step_thread): Remove definition.
16170 (process_serial_event): Don't handle Hs.
16171 * server.h (step_thread): Remove declaration.
16172 * target.c (set_desired_inferior): Remove use of step_thread.
16173
16174 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
16175
16176 * linux-low.c: Include linux-procfs.h.
16177 (linux_attach_lwp_1): Update comments.
16178 (linux_attach): Scan for existing threads when attaching to a
16179 process that is the tgid.
16180 * Makefile.in: Update dependencies.
16181
16182 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
16183
16184 * configure.srv: Add linux-procfs.o dependencies.
16185
16186 2011-08-14 Yao Qi <yao@codesourcery.com>
16187
16188 * target.h (struct target_ops): Fix indent.
16189 * win32-low.c (win32_target_ops): Fix comment.
16190
16191 2011-08-14 Andrew Jenner <andrew@codesourcery.com>
16192 Yao Qi <yao@codesourcery.com>
16193
16194 * Makefile.in (clean): Remove tic6x-*.c files.
16195 (linux-tic6x-low.o, tic6x-c62x-linux.o, tic6x-c64x-linux.o): New rules.
16196 (tic6x-c64xp-linux.o, tic6x-c62x-linux.c, tic6x-c64x-linux.c): Likewise.
16197 (tic6x-c64xp-linux.c): Likewise.
16198 * configure.srv: Add support for tic6x-*-uclinux.
16199 * linux-tic6x-low.c: New.
16200 * linux-low.c (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define.
16201
16202 2011-08-14 Andrew Stubbs <ams@codesourcery.com>
16203 Yao Qi <yao@codesourcery.com>
16204
16205 * target.h (struct target_ops): Add read_loadmap.
16206 * linux-low.c (struct target_loadseg): New type.
16207 (struct target_loadmap): New type.
16208 (linux_read_loadmap): New function.
16209 (linux_target_ops): Add linux_read_loadmap.
16210 * server.c (handle_query): Support qXfer:fdpic:read packet.
16211 * win32-low.c (win32_target_ops): Initialize field `read_loadmap'
16212 to NULL.
16213
16214 2011-08-05 Eli Zaretskii <eliz@gnu.org>
16215
16216 * win32-low.c: Include <stdint.h>.
16217
16218 2011-07-22 Pedro Alves <pedro@codesourcery.com>
16219
16220 * i386-low.c (i386_insert_aligned_watchpoint): Don't pass the info
16221 to the inferior here.
16222 (i386_remove_aligned_watchpoint): Ditto.
16223 (i386_handle_nonaligned_watchpoint): Return immediate on fail to
16224 fit part of the watchpoint in the debug registers.
16225 (i386_update_inferior_debug_regs): New.
16226 (i386_low_insert_watchpoint): Work on a local mirror of the debug
16227 registers, and only update the inferior on success.
16228 (i386_low_remove_watchpoint): Ditto.
16229
16230 2011-07-22 Kwok Cheung Yeung <kcy@codesourcery.com>
16231
16232 * linux-low.c (compare_ints, unique, list_threads, show_process,
16233 linux_core_of_thread): Delete.
16234 (linux_target_ops): Change linux_core_of_thread to
16235 linux_common_core_of_thread.
16236 (linux_qxfer_osdata): Defer to linux_common_xfer_osdata.
16237 * utils.c (malloc_failure): Change type of argument.
16238 (xmalloc, xrealloc, xcalloc, xsnprintf): Delete.
16239 * Makefile.in (SFILES): Add common/common-utils.c, common/xml-utils.c,
16240 common/linux-osdata.c, common/ptid.c and common/buffer.c.
16241 (OBS): Add xml-utils.o, common-utils.o, ptid.o and buffer.o.
16242 (IPA_OBJS): Add common-utils-ipa.o.
16243 (ptid_h, linux_osdata_h): New macros.
16244 (server_h): Add common/common-utils.h, common/xml-utils.h,
16245 common/buffer.h, common/gdb_assert.h, common/gdb_locale.h and
16246 common/ptid.h.
16247 (common-utils-ipa.o, common-utils.o, xml-utils.o, linux-osdata.o,
16248 ptid.o, buffer.o): New rules.
16249 (linux-low.o): Add common/linux-osdata.h as a dependency.
16250 * configure.srv (srv_tgtobj): Add linux-osdata.o to Linux targets.
16251 * configure.ac: Add AC_HEADER_DIRENT check.
16252 * config.in: Regenerate.
16253 * configure: Regenerate.
16254 * remote-utils.c (xml_escape_text): Delete.
16255 (buffer_grow, buffer_free, buffer_init, buffer_finish,
16256 buffer_xml_printf): Move to common/buffer.c.
16257 * server.c (main): Remove call to initialize_inferiors.
16258 * server.h (struct ptid, ptid_t, minus_one_ptid, null_ptid,
16259 ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp, ptid_get_tid,
16260 ptid_equal, ptid_is_pid, initialize_inferiors, xml_escape_text,
16261 internal_error, gdb_assert, gdb_assert_fail): Delete.
16262 (struct buffer, buffer_grow, buffer_free, buffer_init, buffer_finish,
16263 buffer_xml_printf, buffer_grow_str, buffer_grow_str0): Move to
16264 common/buffer.h.
16265 * inferiors.c (null_ptid, minus_one_ptid, ptid_build, pid_to_ptid,
16266 ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal, ptid_is_pid,
16267 initialize_inferiors): Delete.
16268
16269 2011-07-20 Pedro Alves <pedro@codesourcery.com>
16270
16271 * tracepoint.c (tracepoint_look_up_symbols): Return upon the first
16272 symbol error.
16273
16274 2011-05-31 Pedro Alves <pedro@codesourcery.com>
16275
16276 * linux-x86-low.c (i386_dr_low_get_addr): Fix off by one in
16277 assertion.
16278 * win32-i386-low.c (i386_dr_low_get_addr): Ditto.
16279
16280 2011-05-26 Yao Qi <yao@codesourcery.com>
16281
16282 * Makefile.in (thread-db.o): Track dependence to
16283 common/gdb_thread_db.h.
16284 * thread-db.c: include gdb_thread_db.h from right place.
16285
16286 2011-05-16 Adrian Cornish <gnu@bluedreamer.com>
16287
16288 * linux-i386-ipa.c (supply_static_tracepoint_registers): Pass
16289 __FILE__ and __LINE__ to internal_error.
16290
16291 2011-05-13 Doug Evans <dje@google.com>
16292
16293 * thread-db.c (try_thread_db_load_from_sdir): New function.
16294 (try_thread_db_load_from_dir): New function.
16295 (thread_db_load_search): Handle $sdir, ignore $pdir.
16296 Remove trying of system directories if search of
16297 libthread-db-search-path fails, that is now done via $sdir.
16298
16299 2011-05-12 Kwok Cheung Yeung <kcy@codesourcery.com>
16300
16301 * server.c (handle_query): Add EnableDisableTracepoints to the list
16302 of supported features.
16303 * tracepoint.c (clear_installed_tracepoints): Uninstall disabled
16304 tracepoints.
16305 (cmd_qtenable_disable): New.
16306 (cmd_qtstart): Install tracepoints even if disabled.
16307 (handle_tracepoint_general_set): Add call to cmd_qtenable_disable on
16308 receiving a QTEnable or QTDisable packet.
16309 (gdb_collect): Skip data collection if fast tracepoint is disabled.
16310 (ust_marker_to_static_tracepoint): Do not ignore disabled static
16311 tracepoints.
16312 (gdb_probe): Skip data collection if static tracepoint is disabled.
16313
16314 2011-05-10 Doug Evans <dje@google.com>
16315
16316 * thread-db.c (thread_db_handle_monitor_command): Handle elided path.
16317
16318 2011-05-04 Doug Evans <dje@google.com>
16319
16320 * linux-low.c (linux_join): Skip process lookup.
16321 * spu-low.c (spu_join): Ditto.
16322 * server.c (join_inferiors_callback): Delete.
16323 (process_serial_event): For 'D' packet (detach) call join_inferior
16324 directly.
16325
16326 2011-05-04 Joseph Myers <joseph@codesourcery.com>
16327
16328 * README: Don't mention xscale*-*-linux*.
16329 * configure.srv (xscale*-*-linux*): Don't handle target.
16330
16331 2011-04-27 Nathan Froyd <froydnj@codesourcery.com>
16332
16333 * linux-x86-low.c (amd64_emit_const): Call memcpy instead of
16334 casting pointers.
16335 (amd64_emit_reg, amd64_emit_int_call_1, amd64_emit_void_call_2):
16336 (i386_emit_const, i386_emit_reg, i386_emit_int_call_1):
16337 (i386_emit_void_call_2): Likewise.
16338
16339 2011-04-26 Yao Qi <yao@codesourcery.com>
16340
16341 * linux-low.c: Move common macros to linux-ptrace.h.
16342 Include linux-ptrace.h.
16343 * Makefile.in (linux_ptrace_h): New.
16344 (linux-low.o): Depends on linux-ptrace.h.
16345
16346 2011-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
16347
16348 * remote-utils.c (handle_accept_event): Close LISTEN_DESC only if
16349 RUN_ONCE. Comment for the LISTEN_DESC delete_file_handler call.
16350 (remote_prepare): New function with most of the TCP code from ...
16351 (remote_open): ... here. Detect PORT here unconditionally. Move also
16352 setting transport_is_reliable.
16353 * server.c (run_once): New variable.
16354 (gdbserver_usage): Document it.
16355 (main): Set run_once for `--once'. Call remote_prepare. Exit after
16356 the first run if RUN_ONCE.
16357 * server.h (run_once, remote_prepare): New declarations.
16358
16359 2011-04-19 Tom Tromey <tromey@redhat.com>
16360
16361 * win32-low.c (handle_load_dll): Remove duplicate "the".
16362
16363 2011-04-07 Pierre Muller <muller@ics.u-strasbg.fr>
16364
16365 Remove support for old Cygwin 1.5 versions.
16366 * win32-low.c (win32_create_inferior): Use new cygwin_path_list
16367 function to avoid warning.
16368 (win32_add_one_solib): Use cygwin_conv_path function to avoid
16369 warning.
16370
16371 2011-03-18 Pierre Muller <muller@ics.u-strasbg.fr>
16372
16373 * gdbserver/server.h (Macro _): Define it if not available.
16374
16375 2011-03-14 Michael Snyder <msnyder@vmware.com>
16376
16377 * hostio.c (handle_close): Remove unnecessary null test.
16378
16379 2011-03-10 Joel Brobecker <brobecker@adacore.com>
16380
16381 * Makefile.in (maintainer-clean realclean distclean): Remove
16382 "make ... subdir_do" command.
16383
16384 2011-03-10 Michael Snyder <msnyder@vmware.com>
16385
16386 * tracepoint.c (tracepoint_finish_step): Fix loop variable.
16387
16388 * server.c (handle_v_run): Free alloced buffer on early return.
16389
16390 2011-03-09 Yao Qi <yao@codesourcery.com>
16391
16392 Revert:
16393 2011-03-04 Yao Qi <yao@codesourcery.com>
16394
16395 * Makefile.in: Remove GNU make feature --directory.
16396
16397 2011-03-05 Yao Qi <yao@codesourcery.com>
16398
16399 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
16400 (subdir_do): New make target. Copied from gdb/Makefile.
16401 (maintainer-clean, realclean, distclean, clean): Call corresponding
16402 make targets in common/Makefile.
16403
16404 2011-02-11 Yao Qi <yao@codesourcery.com>
16405
16406 * configure.ac: Call AC_PROG_RANLIB.
16407 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
16408 * configure: Regenerate.
16409
16410 2011-03-07 Jan Kratochvil <jan.kratochvil@redhat.com>
16411
16412 * remote-utils.c (putpkt_binary_1): Calculate BUF2 size dynamically.
16413
16414 2011-03-06 Yao Qi <yao@codesourcery.com>
16415
16416 * Makefile.in (REQUIRED_SUBDIRS): Remove $(LIBCOMMON_DIR).
16417
16418 2011-03-05 Yao Qi <yao@codesourcery.com>
16419
16420 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
16421 (subdir_do): New make target. Copied from gdb/Makefile.
16422 (maintainer-clean, realclean, distclean, clean): Call corresponding
16423 make targets in common/Makefile.
16424
16425 2011-03-04 Yao Qi <yao@codesourcery.com>
16426
16427 * Makefile.in: Remove GNU make feature --directory.
16428
16429 2011-03-04 Michael Snyder <msnyder@vmware.com>
16430
16431 * server.c (queue_stop_reply): Call xmalloc not malloc.
16432
16433 2011-03-02 Michael Snyder <msnyder@vmware.com>
16434
16435 * linux-arm-low.c (arm_arch_setup): Replace malloc with xmalloc.
16436
16437 2011-02-28 Michael Snyder <msnyder@vmware.com>
16438
16439 * tracepoint.c (cmd_qtv): Discard unused value 'packet'.
16440 (cmd_qtframe): Ditto.
16441 (cmd_qtbuffer): Ditto.
16442 (cmd_bigqtbuffer): Ditto.
16443
16444 * utils.c (decimal2str): Initialize 'width' to nine, then
16445 don't mess with it.
16446
16447 2011-02-28 Ulrich Weigand <uweigand@de.ibm.com>
16448
16449 * hostio.c (require_data): Free *data, not data.
16450
16451 2011-02-28 Jan Kratochvil <jan.kratochvil@redhat.com>
16452
16453 * hostio.c (require_data): Use free, not xfree.
16454
16455 2011-02-27 Michael Snyder <msnyder@vmware.com>
16456
16457 * server.c (handle_query): Discard unused value.
16458
16459 * hostio.c (require_data): Free malloc memory before returning
16460 error.
16461
16462 2011-02-26 Michael Snyder <msnyder@vmware.com>
16463
16464 * linux-low.c (list_threads): Call closedir for dirent.
16465
16466 2011-02-27 Michael Snyder <msnyder@vmware.com>
16467
16468 * i386-low.c (i386-length_and_rw_bits): Comment the fact that
16469 a case statement falls through.
16470
16471 * linux-low.c (linux_xfer_siginfo): Fix fencepost error.
16472
16473 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Fix fencepost error
16474 in comparison.
16475
16476 2011-02-26 Michael Snyder <msnyder@vmware.com>
16477
16478 * utils.c (decimal2str): Eliminate dead code and dead param.
16479 (pulongest): Drop dead param from call to decimal2str.
16480 (plongest): Ditto.
16481
16482 2011-02-24 Joel Brobecker <brobecker@adacore.com>
16483
16484 Revert the following patch (not approved yet):
16485 2011-02-21 Hui Zhu <teawater@gmail.com>
16486 * tracepoint.c (tp_printf): New function.
16487 (eval_agent_expr): Handle gdb_agent_op_printf.
16488
16489 2011-02-21 Hui Zhu <teawater@gmail.com>
16490
16491 * tracepoint.c (tp_printf): New function.
16492 (eval_agent_expr): Handle gdb_agent_op_printf.
16493
16494 2011-02-18 Tom Tromey <tromey@redhat.com>
16495
16496 * Makefile.in (tracepoint-ipa.o): Depend on ax.def.
16497 (tracepoint.o): Likewise.
16498 * tracepoint.c (enum gdb_agent_op): Use ax.def.
16499 (gdb_agent_op_names): Likewise.
16500
16501 2011-02-18 Tom Tromey <tromey@redhat.com>
16502
16503 * tracepoint.c (enum gdb_agent_op) <gdb_agent_op_pick,
16504 gdb_agent_op_rot>: New constants.
16505 (gdb_agent_op_names): Add pick and roll.
16506 (eval_agent_expr) <gdb_agent_op_pick, gdb_agent_op_rot>: New
16507 cases.
16508
16509 2011-02-15 Jan Kratochvil <jan.kratochvil@redhat.com>
16510
16511 * aclocal.m4: Regenerated with aclocal-1.11.1.
16512
16513 2011-02-14 Pedro Alves <pedro@codesourcery.com>
16514
16515 * server.c (handle_qxfer_traceframe_info): New.
16516 (qxfer_packets): Register "traceframe-info".
16517 (handle_query): Report support for qXfer:traceframe-info:read+.
16518 * tracepoint.c (match_blocktype): New.
16519 (traceframe_find_block_type): Rename to ...
16520 (traceframe_walk_blocks): ... this. Add callback filter argument,
16521 and use it.
16522 (traceframe_find_block_type): New, reimplemented on top of
16523 traceframe_walk_blocks.
16524 (build_traceframe_info_xml): New.
16525 (traceframe_read_info): New.
16526 * server.h (traceframe_read_info): Declare.
16527
16528 2011-02-11 Yao Qi <yao@codesourcery.com>
16529
16530 * configure.ac: Call AC_PROG_RANLIB.
16531 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
16532 * configure: Regenerate.
16533
16534 2011-02-07 Pedro Alves <pedro@codesourcery.com>
16535
16536 * server.c (gdb_read_memory): Change return semantics to allow
16537 partial transfers.
16538 (handle_search_memory_1): Adjust.
16539 (process_serial_event) <'m' packet>: Handle partial transfers.
16540 * tracepoint.c (traceframe_read_mem): Handle partial transfers.
16541
16542 2011-01-28 Pedro Alves <pedro@codesourcery.com>
16543
16544 * regcache.c (init_register_cache): Initialize
16545 regcache->register_status.
16546 (free_register_cache): Release regcache->register_status.
16547 (regcache_cpy): Copy register_status.
16548 (registers_to_string): Print 'x's for unavailable registers.
16549 (supply_register): Mark the register's status valid or
16550 unavailable, depending on whether a buffer was passed in or not.
16551 (supply_register_zeroed): New.
16552 (supply_regblock): Mark the registers' status valid or
16553 unavailable, depending on whether a buffer was passed in or not.
16554 * regcache.h (REG_UNAVAILABLE, REG_VALID): New defines.
16555 (struct regcache): New `register_status' field.
16556 (supply_register_zeroed): Declare.
16557 * i387-fp.c (i387_xsave_to_cache): Zero out registers using
16558 supply_register_zeroed, rather than passing a NULL buffer to
16559 supply_register.
16560 * tracepoint.c (fetch_traceframe_registers): Update comment.
16561
16562 2011-01-28 Pedro Alves <pedro@codesourcery.com>
16563
16564 * i387-fp.c (i387_xsave_to_cache): Make passing NULL as register
16565 buffer explicit.
16566
16567 2011-01-25 Pedro Alves <pedro@codesourcery.com>
16568
16569 * server.h (decode_xfer_write): Change prototype.
16570 * remote-utils.c (decode_xfer_write): Remove `annex' parameter,
16571 and don't extract the annex here.
16572 * server.c (decode_xfer_read): Remove `annex' parameter,
16573 and don't extract the annex here.
16574 (decode_xfer): New.
16575 (struct qxfer): New.
16576 (handle_qxfer_auxv, handle_qxfer_features, handle_qxfer_libraries)
16577 (handle_qxfer_osdata, handle_qxfer_siginfo, handle_qxfer_spu)
16578 (handle_qxfer_statictrace): New functions, abstracted out from
16579 handle_query, and made to use the struct qxfer interface.
16580 (handle_threads_qxfer_proper): Rename to ...
16581 (handle_qxfer_threads_proper): ... this.
16582 (handle_threads_qxfer): Rename to ...
16583 (handle_qxfer_threads): ... this. Adjust.
16584 (qxfer_packets): New array.
16585 (handle_qxfer): New function.
16586 (handle_query): Use handle_qxfer.
16587
16588 2011-01-05 Michael Snyder <msnyder@msnyder-server.eng.vmware.com>
16589
16590 * gdbreplay.c: Shorten lines of >= 80 columns.
16591 * linux-low.c: Ditto.
16592 * linux-ppc-low.c: Ditto.
16593 * linux-s390-low.c: Ditto.
16594 * linux-sparc-low.c: Ditto.
16595 * linux-x86-low.c: Ditto.
16596 * linux-xtensa-low.c: Ditto.
16597 * mem-break.c: Ditto.
16598 * nto-low.c: Ditto.
16599 * regcache.h: Ditto.
16600 * remote-utils.c: Ditto.
16601 * server.c: Ditto.
16602 * server.h: Ditto.
16603 * thread-db.c: Ditto.
16604 * tracepoint.c: Ditto.
16605 * utils.c: Ditto.
16606 * win32-low.h: Ditto.
16607
16608 2011-01-05 Joel Brobecker <brobecker@adacore.com>
16609
16610 * gdbserver/configure.ac, gdbserver/gdbserver.1: Copyright year
16611 update.
16612
16613 2011-01-01 Joel Brobecker <brobecker@adacore.com>
16614
16615 * server.c (gdbserver_version): Update copyright year in version
16616 output.
16617 * gdbreplay.c (gdbreplay_version): Ditto.
16618
16619 2010-12-29 Jie Zhang <jie.zhang@analog.com>
16620
16621 * configure.srv (bfin-*-*linux*): Handle Blackfin/Linux targets.
16622 * linux-bfin-low.c: New file.
16623 * linux-low.c: Define PT_TEXT_ADDR, PT_TEXT_END_ADDR, and
16624 PT_DATA_ADDR for BFIN targets.
16625 * Makefile.in (SFILES): Add linux-bfin-low.c.
16626 (clean): Remove reg-bfin.c.
16627 (linux-bfin-low.o, reg-bfin.o, reg-bfin.c): New targets.
16628 * README: Mention supported Blackfin targets.
16629
16630 2010-12-23 Mike Frysinger <vapier@gentoo.org>
16631
16632 * .gitignore: New file.
16633
16634 2010-11-16 Mike Frysinger <vapier@gentoo.org>
16635
16636 * linux-low.c (linux_tracefork_child): Add char* cast to arg.
16637
16638 2010-10-22 Jie Zhang <jie@codesourcery.com>
16639
16640 * Makefile.in: Add FLAGS_TO_PASS variable.
16641 (install): Remove dependency of install-only and recursively
16642 invoke make for install-only.
16643
16644 2010-10-04 Doug Evans <dje@google.com>
16645
16646 * Makefile.in (uninstall): Use $(DESTDIR).
16647
16648 2010-09-24 Pedro Alves <pedro@codesourcery.com>
16649
16650 PR gdb/11842
16651
16652 * linux-x86-low.c (compat_siginfo_from_siginfo)
16653 (siginfo_from_compat_siginfo): Also copy si_pid and si_uid when
16654 si_code is < 0. Check for si_code == SI_TIMER before checking for
16655 si_code < 0.
16656
16657 2010-09-13 Joel Brobecker <brobecker@adacore.com>
16658
16659 * lynx-i386-low.c: New file.
16660 * configure.srv: Add handling of i[34567]86-*-lynxos* targets.
16661
16662 2010-09-13 Joel Brobecker <brobecker@adacore.com>
16663
16664 * lynx-low.c (ptrace_request_to_str): Remove handling for
16665 request values that have been removed in LynxOS 5.x.
16666
16667 2010-09-13 Joel Brobecker <brobecker@adacore.com>
16668
16669 * lynx-low.c, lynx-ppc-loc.c: Include <sys/ptrace.h> instead of
16670 <ptrace.h>
16671
16672 2010-09-09 Nathan Sidwell <nathan@codesourcery.com>
16673
16674 * configure.ac: Add --enable-inprocess-agent option.
16675 * configure: Rebuilt.
16676
16677 2010-09-06 Yao Qi <yao@codesourcery.com>
16678
16679 * linux-low.c (linux_kill): Remove unused variable.
16680 (linux_stabilize_threads): Likewise.
16681 * server.c (start_inferior): Likewise.
16682 (queue_stop_reply_callback): Likewise.
16683 * tracepoint.c (do_action_at_tracepoint): Likewise.
16684
16685 2010-09-06 Yao Qi <yao@codesourcery.com>
16686
16687 * linux-low.c (maybe_move_out_of_jump_pad): Restore current_inferior
16688 on return.
16689
16690 2010-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
16691
16692 * target.c (mywait) <TARGET_WAITKIND_EXITED>: Fix to use INTEGER.
16693
16694 2010-09-06 Pedro Alves <pedro@codesourcery.com>
16695
16696 * Makefile.in (install-only): Replace $IPA_DEPFILES with
16697 "$(IPA_DEPFILES)".
16698
16699 2010-09-01 Joel Brobecker <brobecker@adacore.com>
16700
16701 * gdbserver/lynx-low.c, gdbserver/lynx-low.h,
16702 gdbserver/lynx-ppc-low.c: New files.
16703 * Makefile.in (lynx_low_h): New variable.
16704 (lynx-low.o, lynx-ppc-low.o): New rules.
16705 * configure.ac: On LynxOS, link with -lnetinet.
16706 * configure.srv: Add handling of powerpc-*-lynxos* targets.
16707 * configure: regenerate.
16708
16709 2010-09-01 Joel Brobecker <brobecker@adacore.com>
16710
16711 * Makefile.in (vasprintf.o, vsnprintf.o): New rules.
16712 * configure.ac: Add check for vasprintf and vsnprintf.
16713 * configure, config.in: Regenerate.
16714 * server.h (vasprintf, vsnprintf): Add conditional declarations.
16715
16716 2010-09-01 Joel Brobecker <brobecker@adacore.com>
16717
16718 * gdbreplay.c: Move include of alloca.h up, next to include of
16719 malloc.h.
16720 * server.h: Add include of malloc.h.
16721 * mem-break.c: Remove include of malloc.h.
16722 * server.c, tracepoint.c, utils.c, win32-low.c: Likewise.
16723
16724 2010-09-01 Joel Brobecker <brobecker@adacore.com>
16725
16726 * Makefile.in (memmem.o): Build with -Wno-error.
16727
16728 2010-09-01 Joel Brobecker <brobecker@adacore.com>
16729
16730 * utils.c (xsnprintf): Make non-static.
16731 * server.h: Add xsnprintf declaration.
16732 * linux-low.c, nto-low.c, target.c, thread-db.c, tracepoint.c:
16733 replace calls to snprintf by calls to xsnprintf throughout.
16734
16735 2010-09-01 Joel Brobecker <brobecker@adacore.com>
16736
16737 * configure.ac: Add configure check for alloca.
16738 * configure, config.in: Regenerate.
16739 * server.h: Include alloca.h if it exists.
16740 * gdbreplay.c: Include alloca.h if it exists.
16741
16742 2010-08-28 Pedro Alves <pedro@codesourcery.com>
16743
16744 * linux-low.c (__SIGRTMIN): Define if not already defined.
16745 (linux_create_inferior): Check for __ANDROID__ rather than
16746 __SIGRTMIN.
16747 (enqueue_one_deferred_signal): Don't requeue non-RT signals that
16748 are already deferred.
16749 (linux_wait_1): Check for __ANDROID__ rather than __SIGRTMIN.
16750 (linux_resume_one_thread): Don't queue a SIGSTOP if the lwp is
16751 stopped and already has a pending signal to report.
16752 (proceed_one_lwp): : Don't queue a SIGSTOP if the lwp already has
16753 a pending signal to report or is moving out of a jump pad.
16754 (linux_init_signals): Check for __ANDROID__ rather than
16755 __SIGRTMIN.
16756
16757 2010-08-28 Pedro Alves <pedro@codesourcery.com>
16758
16759 * linux-low.c (linux_stabilize_threads): Wrap debug output in a
16760 debug_threads check. Avoid a linear search when not doing debug
16761 output.
16762
16763 2010-08-27 Pedro Alves <pedro@codesourcery.com>
16764
16765 * event-loop.c (event_handle_func): Adjust to use gdb_fildes_t.
16766 (struct gdb_event) <fd>: Change type to gdb_fildes_t.
16767 (struct file_handler) <fd>: Change type to gdb_fildes_t.
16768 (process_event): Change local fd's type to gdb_fildes_t.
16769 (create_file_handler): Adjust prototype.
16770 (delete_file_handler): Adjust prototype.
16771 (handle_file_event): Adjust prototype. Use pfildes.
16772 (create_file_event): Adjsut prototype.
16773 * remote-utils.c (remote_desc, listen_desc): Change type to
16774 gdb_fildes_t.
16775 * server.h: New gdb_fildes_t typedef.
16776 [USE_WIN32API]: Include winsock2.h.
16777 (delete_file_handler, add_file_handler): Adjust prototypes.
16778 (pfildes): Declare.
16779 * utils.c (pfildes): New.
16780
16781 2010-08-27 Pedro Alves <pedro@codesourcery.com>
16782
16783 * configure.ac (build_warnings): Add -Wno-char-subscripts.
16784 * configure: Regenerate.
16785
16786 2010-08-27 Pedro Alves <pedro@codesourcery.com>
16787
16788 * linux-low.c (linux_unprepare_to_access_memory): Rename to ...
16789 (linux_done_accessing_memory): ... this.
16790 (linux_target_ops): Adjust.
16791 * linux-x86-low.c (x86_insert_point, x86_remove_point): Adjust.
16792 * nto-low.c (nto_target_ops): Adjust comment.
16793 * server.c (gdb_read_memory, gdb_write_memory): Adjust.
16794 * spu-low.c (spu_target_ops): Adjust comment.
16795 * target.h (target_ops): Rename unprepare_to_access_memory field
16796 to done_accessing_memory.
16797 (unprepare_to_access_memory): Rename to ...
16798 (done_accessing_memory): ... this.
16799
16800 2010-08-26 Pedro Alves <pedro@codesourcery.com>
16801
16802 * linux-low.c (linux_prepare_to_access_memory): New.
16803 (linux_unprepare_to_access_memory): New.
16804 (linux_target_ops): Install them.
16805 * server.c (read_memory): Rename to ...
16806 (gdb_read_memory): ... this. Use
16807 prepare_to_access_memory/prepare_to_access_memory.
16808 (write_memory): Rename to ...
16809 (gdb_write_memory): ... this. Use
16810 prepare_to_access_memory/prepare_to_access_memory.
16811 (handle_search_memory_1): Adjust.
16812 (process_serial_event): Adjust.
16813 * target.h (struct target_ops): New fields
16814 prepare_to_access_memory and unprepare_to_access_memory.
16815 (prepare_to_access_memory, unprepare_to_access_memory): New.
16816 * linux-x86-low.c (x86_insert_point, x86_remove_point): Use
16817 prepare_to_access_memory/prepare_to_access_memory.
16818 * nto-low.c (nto_target_ops): Adjust.
16819 * spu-low.c (spu_target_ops): Adjust.
16820 * win32-low.c (win32_target_ops): Adjust.
16821
16822 2010-08-26 Pedro Alves <pedro@codesourcery.com>
16823
16824 * Makefile.in (WARN_CFLAGS): Get it from configure.
16825 (WERROR_CFLAGS): New.
16826 (INTERNAL_CFLAGS): Add WERROR_CFLAGS.
16827 * configure.ac: Introduce --enable-werror, which adds -Werror to
16828 the compiler command line. Enabled by default. Disable with
16829 --disable-werror. Add -Wdeclaration-after-statement
16830 Wpointer-arith and -Wformat-nonliteral to warning flags.
16831 * configure: Regenerate.
16832
16833 2010-08-26 Pedro Alves <pedro@codesourcery.com>
16834
16835 * mem-break.c [HAVE_MALLOC_H]: Include malloc.h.
16836
16837 2010-08-26 Pedro Alves <pedro@codesourcery.com>
16838
16839 * gdbreplay.c (remote_error): New.
16840 (gdbchar): New.
16841 (expect): Use gdbchar. Check for error reading from GDB.
16842 Clarify sync error output.
16843 (play): Check for errors writing to GDB.
16844 * linux-low.c (sigchld_handler): Really ignore `write' errors.
16845 * remote-utils.c (getpkt): Check for errors writing to the remote
16846 descriptor.
16847
16848 2010-08-25 Pedro Alves <pedro@codesourcery.com>
16849
16850 * linux-low.c (linux_wait_1): Move non-debugging code out of
16851 `debug_threads' control.
16852
16853 2010-08-25 Pedro Alves <pedro@codesourcery.com>
16854
16855 * linux-low.c (linux_wait_1): Don't set last_status here.
16856 * server.c (push_event, queue_stop_reply_callback): Assert we're
16857 not pushing a TARGET_WAITKIND_IGNORE event.
16858 (start_inferior, start_inferior, attach_inferior, handle_v_cont)
16859 (myresume, handle_target_event): Set the thread's last_resume_kind
16860 and last_status from the target returned status.
16861
16862 2010-08-25 Pedro Alves <pedro@codesourcery.com>
16863
16864 PR threads/10729
16865
16866 * linux-x86-low.c (update_debug_registers_callback): New.
16867 (i386_dr_low_set_addr): Use it.
16868 (i386_dr_low_get_addr): New.
16869 (i386_dr_low_set_control): Use update_debug_registers_callback.
16870 (i386_dr_low_get_control): New.
16871 (i386_dr_low_get_status): Adjust.
16872 * linux-low.c (linux_stop_lwp): New.
16873 * linux-low.h (linux_stop_lwp): Declare.
16874
16875 * i386-low.c (I386_DR_GET_RW_LEN): Take the dr7 contents as
16876 argument instead of a i386_debug_reg_state.
16877 (I386_DR_WATCH_HIT): Take the dr6 contents as argument instead of
16878 a i386_debug_reg_state.
16879 (i386_insert_aligned_watchpoint): Adjust.
16880 (i386_remove_aligned_watchpoint): Adjust.
16881 (i386_low_stopped_data_address): Read the debug registers from the
16882 inferior instead of from the mirrors.
16883 * i386-low.h (struct i386_debug_reg_state): Extend comment.
16884 (i386_dr_low_get_addr): Declare.
16885 (i386_dr_low_get_control): Declare.
16886 (i386_dr_low_get_status): Change prototype.
16887
16888 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): New globals.
16889 (i386_dr_low_get_addr): New.
16890 (i386_dr_low_get_control): New.
16891 (i386_dr_low_get_status): Adjust prototype. Return
16892 dr_status_mirror.
16893 (i386_initial_stuff): Clear dr_status_mirror and
16894 dr_control_mirror.
16895 (i386_get_thread_context): Adjust.
16896 (i386_set_thread_context): Adjust.
16897 (i386_thread_added): Adjust.
16898
16899 2010-08-24 Pedro Alves <pedro@codesourcery.com>
16900
16901 * linux-low.h (linux_thread_area): Delete declaration.
16902
16903 2010-08-11 Thomas Schwinge <thomas@codesourcery.com>
16904
16905 * linux-low.c (linux_wait_1): Correctly return the ptid of the child
16906 after its termination.
16907
16908 2010-08-09 Pedro Alves <pedro@codesourcery.com>
16909
16910 * linux-low.c (gdb_wants_lwp_stopped): Delete.
16911 (gdb_wants_all_stopped): Delete.
16912 (linux_wait_1): Don't call them.
16913 * server.c (handle_v_cont): Tag all threads as want-stopped.
16914 (gdb_wants_thread_stopped): Fix comments. Tag the thread that
16915 stopped as "client-wants-stopped".
16916
16917 2010-07-31 Pedro Alves <pedro@codesourcery.com>
16918
16919 * Makefile.in (signals_h): New.
16920 (server_h): Depend on it.
16921 (server.o): Don't depend on $(signals_def).
16922 (signals.o): Depend on $(signals_def).
16923
16924 2010-07-31 Jan Kratochvil <jan.kratochvil@redhat.com>
16925
16926 * Makefile.in (signals_def): New.
16927 (server_h): Append include/gdb/signals.h and signals_def.
16928 (server.o): Append signals_def.
16929
16930 2010-07-25 Jan Kratochvil <jan.kratochvil@redhat.com>
16931
16932 * server.c (handle_target_event): Use target_signal_to_host for
16933 resume_info.sig initialization.
16934 * target.h (struct thread_resume) <sig>: New comment.
16935
16936 2010-07-20 Ozkan Sezer <sezeroz@gmail.com>
16937
16938 * server.c (handle_query): strcpy() the returned string from paddress()
16939 instead of sprintf().
16940 * utils.c (paddress): Return phex_nz().
16941
16942 2010-07-07 Joel Brobecker <brobecker@adacore.com>
16943
16944 * server.c (handle_v_cont): Call mourn_inferior if process
16945 just exited.
16946 (myresume): Likewise.
16947
16948 2010-07-01 Pedro Alves <pedro@codesourcery.com>
16949
16950 Static tracepoints, and integration with UST.
16951
16952 * configure.ac: Handle --with-ust. substitute ustlibs and ustinc.
16953 * mem-break.c (uninsert_all_breakpoints)
16954 (reinsert_all_breakpoints): New.
16955 * mem-break.h (reinsert_all_breakpoints, uninsert_all_breakpoints):
16956 * tracepoint.c (ust_loaded, helper_thread_id, cmd_buf): New.
16957 (gdb_agent_ust_loaded, helper_thread_id)
16958 (gdb_agent_helper_thread_id): New macros.
16959 (struct ipa_sym_addresses): Add addr_ust_loaded,
16960 addr_helper_thread_id, addr_cmd_buf.
16961 (symbol_list): Add ust_loaded, helper_thread_id, cmd_buf.
16962 (in_process_agent_loaded_ust): New.
16963 (write_e_ust_not_loaded): New.
16964 (maybe_write_ipa_ust_not_loaded): New.
16965 (struct collect_static_trace_data_action): New.
16966 (enum tracepoint_type) <static_tracepoint>: New.
16967 (struct tracepoint) <handle>: Mention static tracepoints.
16968 (struct static_tracepoint_ctx): New.
16969 (CMD_BUF_SIZE): New.
16970 (add_tracepoint_action): Handle static tracepoint actions.
16971 (unprobe_marker_at): New.
16972 (clear_installed_tracepoints): Handle static tracepoints.
16973 (cmd_qtdp): Handle static tracepoints.
16974 (probe_marker_at): New.
16975 (cmd_qtstart): Handle static tracepoints.
16976 (response_tracepoint): Handle static tracepoints.
16977 (cmd_qtfstm, cmd_qtsstm, cmd_qtstmat): New.
16978 (handle_tracepoint_query): Handle qTfSTM, qTsSTM and qTSTMat.
16979 (get_context_regcache): Handle static tracepoints.
16980 (do_action_at_tracepoint): Handle static tracepoint actions.
16981 (traceframe_find_block_type): Handle static trace data blocks.
16982 (traceframe_read_sdata): New.
16983 (download_tracepoints): Download static tracepoint actions.
16984 [HAVE_UST] Include ust/ust.h, dlfcn.h, sys/socket.h, and sys/un.h.
16985 (GDB_PROBE_NAME): New.
16986 (ust_ops): New.
16987 (GET_UST_SYM): New.
16988 (USTF): New.
16989 (dlsym_ust): New.
16990 (ust_marker_to_static_tracepoint): New.
16991 (gdb_probe): New.
16992 (collect_ust_data_at_tracepoint): New.
16993 (gdb_ust_probe): New.
16994 (UNIX_PATH_MAX, SOCK_DIR): New.
16995 (gdb_ust_connect_sync_socket): New.
16996 (resume_thread, stop_thread): New.
16997 (run_inferior_command): New.
16998 (init_named_socket): New.
16999 (gdb_ust_socket_init): New.
17000 (cstr_to_hexstr): New.
17001 (next_st): New.
17002 (first_marker, next_marker): New.
17003 (response_ust_marker): New.
17004 (cmd_qtfstm, cmd_qtsstm): New.
17005 (unprobe_marker_at, probe_marker_at): New.
17006 (cmd_qtstmat, gdb_ust_thread): New.
17007 (gdb_ust_init): New.
17008 (initialize_tracepoint_ftlib): Call gdb_ust_init.
17009 * linux-amd64-ipa.c [HAVE_UST]: Include ust/processor.h
17010 (ST_REGENTRY): New.
17011 (x86_64_st_collect_regmap): New.
17012 (X86_64_NUM_ST_COLLECT_GREGS): New.
17013 (AMD64_RIP_REGNUM): New.
17014 (supply_static_tracepoint_registers): New.
17015 * linux-i386-ipa.c [HAVE_UST]: Include ust/processor.h
17016 (ST_REGENTRY): New.
17017 (i386_st_collect_regmap): New.
17018 (i386_NUM_ST_COLLECT_GREGS): New.
17019 (supply_static_tracepoint_registers): New.
17020 * server.c (handle_query): Handle qXfer:statictrace:read.
17021 <qSupported>: Report support for StaticTracepoints, and
17022 qXfer:statictrace:read features.
17023 * server.h (traceframe_read_sdata)
17024 (supply_static_tracepoint_registers): Declare.
17025 * remote-utils.c (convert_int_to_ascii, hexchars, ishex, tohex)
17026 (unpack_varlen_hex): Include in IPA build.
17027 * Makefile.in (ustlibs, ustinc): New.
17028 (IPA_OBJS): Add remote-utils-ipa.o.
17029 ($(IPA_LIB)): Link -ldl and -lpthread.
17030 (UST_CFLAGS): New.
17031 (IPAGENT_CFLAGS): Add UST_CFLAGS.
17032 * config.in, configure: Regenerate.
17033
17034 2010-06-20 Ian Lance Taylor <iant@google.com>
17035 Pedro Alves <pedro@codesourcery.com>
17036
17037 * linux-x86-low.c (always_true): Delete.
17038 (EMIT_ASM, EMIT_ASM32): Use an uncondition asm jmp instead of
17039 trying to fool the compiler with always_true.
17040
17041 2010-06-20 Pedro Alves <pedro@codesourcery.com>
17042
17043 * tracepoint.c (condition_true_at_tracepoint): Don't run compiled
17044 conditions in gdbserver.
17045
17046 2010-06-19 Ulrich Weigand <uweigand@de.ibm.com>
17047
17048 * spu-low.c (spu_read_memory): Wrap around local store limit.
17049 (spu_write_memory): Likewise.
17050
17051 2010-06-15 Pedro Alves <pedro@codesourcery.com>
17052
17053 * linux-x86-low.c (amd64_emit_const, amd64_emit_void_call_2)
17054 (i386_emit_const, i386_emit_void_call_2): Replace int64_t uses with
17055 LONGEST uses.
17056 * server.h (struct emit_ops): Replace int64_t uses with LONGEST
17057 uses.
17058 * tracepoint.c (emit_const, emit_void_call_2): Replace int64_t
17059 uses with LONGEST uses.
17060
17061 2010-06-14 Stan Shebs <stan@codesourcery.com>
17062 Pedro Alves <pedro@codesourcery.com>
17063
17064 Bytecode compiler.
17065
17066 * linux-x86-low.c: Include limits.h.
17067 (add_insns): New.
17068 (always_true): New.
17069 (EMIT_ASM): New.
17070 (EMIT_ASM32): New.
17071 (amd64_emit_prologue, amd64_emit_epilogue, amd64_emit_add)
17072 (amd64_emit_sub, amd64_emit_mul, amd64_emit_lsh)
17073 (amd64_emit_rsh_signed, amd64_emit_rsh_unsigned, amd64_emit_ext,
17074 (amd64_emit_log_not, amd64_emit_bit_and, amd64_emit_bit_or)
17075 (amd64_emit_bit_xor, amd64_emit_bit_not, amd64_emit_equal,
17076 (amd64_emit_less_signed, amd64_emit_less_unsigned, amd64_emit_ref,
17077 (amd64_emit_if_goto, amd64_emit_goto, amd64_write_goto_address)
17078 (amd64_emit_const, amd64_emit_call, amd64_emit_reg)
17079 (amd64_emit_pop, amd64_emit_stack_flush, amd64_emit_zero_ext)
17080 (amd64_emit_swap, amd64_emit_stack_adjust, amd64_emit_int_call_1)
17081 (amd64_emit_void_call_2): New.
17082 (amd64_emit_ops): New.
17083 (i386_emit_prologue, i386_emit_epilogue, i386_emit_add)
17084 (i386_emit_sub,i386_emit_mul, i386_emit_lsh, i386_emit_rsh_signed)
17085 (i386_emit_rsh_unsigned, i386_emit_ext, i386_emit_log_not)
17086 (i386_emit_bit_and, i386_emit_bit_or, i386_emit_bit_xor)
17087 (i386_emit_bit_not, i386_emit_equal, i386_emit_less_signed)
17088 (i386_emit_less_unsigned, i386_emit_ref, i386_emit_if_goto)
17089 (i386_emit_goto, i386_write_goto_address, i386_emit_const)
17090 (i386_emit_call, i386_emit_reg, i386_emit_pop)
17091 (i386_emit_stack_flush, i386_emit_zero_ext, i386_emit_swap)
17092 (i386_emit_stack_adjust, i386_emit_int_call_1)
17093 (i386_emit_void_call_2): New.
17094 (i386_emit_ops): New.
17095 (x86_emit_ops): New.
17096 (the_low_target): Install x86_emit_ops.
17097 * server.h (struct emit_ops): New.
17098 (get_raw_reg_func_addr): Declare.
17099 (current_insn_ptr, emit_error): Declare.
17100 * tracepoint.c (get_raw_reg, get_trace_state_variable_value)
17101 (set_trace_state_variable_value): New defines.
17102 (struct ipa_sym_addresses): New fields addr_get_raw_reg,
17103 addr_get_trace_state_variable_value and
17104 addr_set_trace_state_variable_value.
17105 (symbol_list): New fields for get_raw_reg,
17106 get_trace_state_variable_value and set_trace_state_variable_value.
17107 (condfn): New typedef.
17108 (struct tracepoint): New field `compiled_cond'.
17109 (do_action_at_tracepoint): Clear compiled_cond.
17110 (get_trace_state_variable_value, set_trace_state_variable_value):
17111 Export in the IPA.
17112 (condition_true_at_tracepoint): If there's a compiled condition,
17113 run that.
17114 (current_insn_ptr, emit_error): New globals.
17115 (struct bytecode_address): New.
17116 (get_raw_reg_func_addr): New.
17117 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul)
17118 (emit_lsh, emit_rsh_signed, emit_rsh_unsigned, emit_ext)
17119 (emit_log_not, emit_bit_and, emit_bit_or, emit_bit_xor)
17120 (emit_bit_not, emit_equal, emit_less_signed, emit_less_unsigned)
17121 (emit_ref, emit_if_goto, emit_goto, write_goto_address, emit_const)
17122 (emit_reg, emit_pop, emit_stack_flush, emit_zero_ext, emit_swap)
17123 (emit_stack_adjust, emit_int_call_1, emit_void_call_2): New.
17124 (compile_tracepoint_condition, compile_bytecodes): New.
17125 * target.h (emit_ops): Forward declare.
17126 (struct target_ops): New field emit_ops.
17127 (target_emit_ops): New.
17128 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): New.
17129 * linux-i386-ipa.c (gdb_agent_get_raw_reg): New.
17130 * linux-low.c (linux_emit_ops): New.
17131 (linux_target_ops): Install it.
17132 * linux-low.h (struct linux_target_ops): New field emit_ops.
17133
17134 2010-06-14 Ulrich Weigand <uweigand@de.ibm.com>
17135
17136 * linux-ppc-low.c (ppc_arch_setup): Use private regcache to test MSR.
17137 * linux-s390-low.c (ppc_arch_setup): Use private regcache to test PSW.
17138
17139 2010-06-01 Pedro Alves <pedro@codesourcery.com>
17140 Stan Shebs <stan@codesourcery.com>
17141
17142 * Makefile.in (IPA_DEPFILES, extra_libraries): New.
17143 (all): Depend on $(extra_libraries).
17144 (install-only): Install the IPA.
17145 (IPA_OBJS, IPA_LIB): New.
17146 (clean): Remove the IPA lib.
17147 (IPAGENT_CFLAGS): New.
17148 (tracepoint-ipa.o, utils-ipa.o, remote-utils-ipa.o)
17149 (regcache-ipa.o, i386-linux-ipa.o, linux-i386-ipa.o)
17150 (linux-amd64-ipa.o, amd64-linux-ipa.o): New rules.
17151 * linux-amd64-ipa.c, linux-i386-ipa.c: New files.
17152 * configure.ac: Check for atomic builtins support in the compiler.
17153 (IPA_DEPFILES, extra_libraries): Define.
17154 * configure.srv (ipa_obj): Add description.
17155 (ipa_i386_linux_regobj, ipa_amd64_linux_regobj): Define.
17156 (i[34567]86-*-linux*): Set ipa_obj.
17157 (x86_64-*-linux*): Set ipa_obj.
17158 * linux-low.c (stabilizing_threads): New.
17159 (supports_fast_tracepoints): New.
17160 (linux_detach): Stabilize threads before detaching.
17161 (handle_tracepoints): Handle internal tracing breakpoints. Assert
17162 the lwp is either not stabilizing, or is moving out of a jump pad.
17163 (linux_fast_tracepoint_collecting): New.
17164 (maybe_move_out_of_jump_pad): New.
17165 (enqueue_one_deferred_signal): New.
17166 (dequeue_one_deferred_signal): New.
17167 (linux_wait_for_event_1): If moving out of a jump pad, defer
17168 pending signals to later.
17169 (linux_stabilize_threads): New.
17170 (linux_wait_1): Check if threads need moving out of jump pads, and
17171 do it if so.
17172 (stuck_in_jump_pad_callback): New.
17173 (move_out_of_jump_pad_callback): New.
17174 (lwp_running): New.
17175 (linux_resume_one_lwp): Handle moving out of jump pads.
17176 (linux_set_resume_request): Dequeue deferred signals.
17177 (need_step_over_p): Also step over fast tracepoint jumps.
17178 (start_step_over): Also uninsert fast tracepoint jumps.
17179 (finish_step_over): Also reinsert fast tracepoint jumps.
17180 (linux_install_fast_tracepoint_jump): New.
17181 (linux_target_ops): Install linux_stabilize_threads and
17182 linux_install_fast_tracepoint_jump_pad.
17183 * linux-low.h (linux_target_ops) <get_thread_area,
17184 install_fast_tracepoint_jump_pad>: New fields.
17185 (struct lwp_info) <collecting_fast_tracepoint,
17186 pending_signals_to_report, exit_jump_pad_bkpt>: New fields.
17187 (linux_get_thread_area): Declare.
17188 * linux-x86-low.c (jump_insn): New.
17189 (x86_get_thread_area): New.
17190 (append_insns): New.
17191 (push_opcode): New.
17192 (amd64_install_fast_tracepoint_jump_pad): New.
17193 (i386_install_fast_tracepoint_jump_pad): New.
17194 (x86_install_fast_tracepoint_jump_pad): New.
17195 (the_low_target): Install x86_get_thread_area and
17196 x86_install_fast_tracepoint_jump_pad.
17197 * mem-break.c (set_raw_breakpoint_at): Use read_inferior_memory.
17198 (struct fast_tracepoint_jump): New.
17199 (fast_tracepoint_jump_insn): New.
17200 (fast_tracepoint_jump_shadow): New.
17201 (find_fast_tracepoint_jump_at): New.
17202 (fast_tracepoint_jump_here): New.
17203 (delete_fast_tracepoint_jump): New.
17204 (set_fast_tracepoint_jump): New.
17205 (uninsert_fast_tracepoint_jumps_at): New.
17206 (reinsert_fast_tracepoint_jumps_at): New.
17207 (set_breakpoint_at): Use write_inferior_memory.
17208 (uninsert_raw_breakpoint): Use write_inferior_memory.
17209 (check_mem_read): Mask out fast tracepoint jumps.
17210 (check_mem_write): Mask out fast tracepoint jumps.
17211 * mem-break.h (struct fast_tracepoint_jump): Forward declare.
17212 (set_fast_tracepoint_jump): Declare.
17213 (delete_fast_tracepoint_jump)
17214 (fast_tracepoint_jump_here, uninsert_fast_tracepoint_jumps_at)
17215 (reinsert_fast_tracepoint_jumps_at): Declare.
17216 * regcache.c: Don't compile many functions when building the
17217 in-process agent library.
17218 (init_register_cache) [IN_PROCESS_AGENT]: Don't allow allocating
17219 the register buffer in the heap.
17220 (free_register_cache): If the register buffer isn't owned by the
17221 regcache, don't free it.
17222 (set_register_cache) [IN_PROCESS_AGENT]: Don't re-alocate
17223 pre-existing register caches.
17224 * remote-utils.c (convert_int_to_ascii): Constify `from' parameter
17225 type.
17226 (convert_ascii_to_int): : Constify `from' parameter type.
17227 (decode_M_packet, decode_X_packet): Replace the `to' parameter by
17228 a `to_p' pointer to pointer parameter. If TO_P is NULL, malloc
17229 the needed buffer in-place.
17230 (relocate_instruction): New.
17231 * server.c (handle_query) <qSymbols>: If the target supports
17232 tracepoints, give it a chance of looking up symbols. Report
17233 support for fast tracepoints.
17234 (handle_status): Stabilize threads.
17235 (process_serial_event): Adjust.
17236 * server.h (struct fast_tracepoint_jump): Forward declare.
17237 (struct process_info) <fast_tracepoint_jumps>: New field.
17238 (convert_ascii_to_int, convert_int_to_ascii): Adjust.
17239 (decode_X_packet, decode_M_packet): Adjust.
17240 (relocate_instruction): Declare.
17241 (in_process_agent_loaded): Declare.
17242 (tracepoint_look_up_symbols): Declare.
17243 (struct fast_tpoint_collect_status): Declare.
17244 (fast_tracepoint_collecting): Declare.
17245 (force_unlock_trace_buffer): Declare.
17246 (handle_tracepoint_bkpts): Declare.
17247 (initialize_low_tracepoint)
17248 (supply_fast_tracepoint_registers) [IN_PROCESS_AGENT]: Declare.
17249 * target.h (struct target_ops) <stabilize_threads,
17250 install_fast_tracepoint_jump_pad>: New fields.
17251 (stabilize_threads, install_fast_tracepoint_jump_pad): New.
17252 * tracepoint.c [HAVE_MALLOC_H]: Include malloc.h.
17253 [HAVE_STDINT_H]: Include stdint.h.
17254 (trace_debug_1): Rename to ...
17255 (trace_vdebug): ... this.
17256 (trace_debug): Rename to ...
17257 (trace_debug_1): ... this. Add `level' parameter.
17258 (trace_debug): New.
17259 (ATTR_USED, ATTR_NOINLINE): New.
17260 (IP_AGENT_EXPORT): New.
17261 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
17262 (collecting, gdb_collect, stop_tracing, flush_trace_buffer)
17263 (about_to_request_buffer_space, trace_buffer_is_full)
17264 (stopping_tracepoint, expr_eval_result, error_tracepoint)
17265 (tracepoints, tracing, trace_buffer_ctrl, trace_buffer_ctrl_curr)
17266 (trace_buffer_lo, trace_buffer_hi, traceframe_read_count)
17267 (traceframe_write_count, traceframes_created)
17268 (trace_state_variables)
17269 New renaming defines.
17270 (struct ipa_sym_addresses): New.
17271 (STRINGIZE_1, STRINGIZE, IPA_SYM): New.
17272 (symbol_list): New.
17273 (ipa_sym_addrs): New.
17274 (all_tracepoint_symbols_looked_up): New.
17275 (in_process_agent_loaded): New.
17276 (write_e_ipa_not_loaded): New.
17277 (maybe_write_ipa_not_loaded): New.
17278 (tracepoint_look_up_symbols): New.
17279 (debug_threads) [IN_PROCESS_AGENT]: New.
17280 (read_inferior_memory) [IN_PROCESS_AGENT]: New.
17281 (UNKNOWN_SIDE_EFFECTS): New.
17282 (stop_tracing): New.
17283 (flush_trace_buffer): New.
17284 (stop_tracing_bkpt): New.
17285 (flush_trace_buffer_bkpt): New.
17286 (read_inferior_integer): New.
17287 (read_inferior_uinteger): New.
17288 (read_inferior_data_pointer): New.
17289 (write_inferior_data_pointer): New.
17290 (write_inferior_integer): New.
17291 (write_inferior_uinteger): New.
17292 (struct collect_static_trace_data_action): Delete.
17293 (enum tracepoint_type): New.
17294 (struct tracepoint) <type>: New field `type'.
17295 <actions_str, step_actions, step_actions_str>: Only include in
17296 GDBserver.
17297 <orig_size, obj_addr_on_target, adjusted_insn_addr>
17298 <adjusted_insn_addr_end, jump_pad, jump_pad_end>: New fields.
17299 (tracepoints): Use IP_AGENT_EXPORT.
17300 (last_tracepoint): Don't include in the IPA.
17301 (stopping_tracepoint): Use IP_AGENT_EXPORT.
17302 (trace_buffer_is_full): Use IP_AGENT_EXPORT.
17303 (alloced_trace_state_variables): New.
17304 (trace_state_variables): Use IP_AGENT_EXPORT.
17305 (traceframe_t): Delete unused variable.
17306 (circular_trace_buffer): Don't include in the IPA.
17307 (trace_buffer_start): Delete.
17308 (struct trace_buffer_control): New.
17309 (trace_buffer_free): Delete.
17310 (struct ipa_trace_buffer_control): New.
17311 (GDBSERVER_FLUSH_COUNT_MASK, GDBSERVER_FLUSH_COUNT_MASK_PREV)
17312 (GDBSERVER_FLUSH_COUNT_MASK_CURR, GDBSERVER_UPDATED_FLUSH_COUNT_BIT):
17313 New.
17314 (trace_buffer_ctrl): New.
17315 (TRACE_BUFFER_CTRL_CURR): New.
17316 (trace_buffer_start, trace_buffer_free, trace_buffer_end_free):
17317 Reimplement as macros.
17318 (trace_buffer_wrap): Delete.
17319 (traceframe_write_count, traceframe_read_count)
17320 (traceframes_created, tracing): Use IP_AGENT_EXPORT.
17321 (struct tracepoint_hit_ctx) <type>: New field.
17322 (struct fast_tracepoint_ctx): New.
17323 (memory_barrier): New.
17324 (cmpxchg): New.
17325 (record_tracepoint_error): Update atomically in the IPA.
17326 (clear_inferior_trace_buffer): New.
17327 (about_to_request_buffer_space): New.
17328 (trace_buffer_alloc): Handle GDBserver and inferior simulatenous
17329 updating the same buffer.
17330 (add_tracepoint): Default the tracepoint's type to trap
17331 tracepoint, and orig_size to -1.
17332 (get_trace_state_variable) [IN_PROCESS_AGENT]: Handle allocated
17333 internal variables.
17334 (create_trace_state_variable): New parameter `gdb'. Handle it.
17335 (clear_installed_tracepoints): Clear fast tracepoint jumps.
17336 (cmd_qtdp): Handle fast tracepoints.
17337 (cmd_qtdv): Adjust.
17338 (max_jump_pad_size): New.
17339 (gdb_jump_pad_head): New.
17340 (get_jump_space_head): New.
17341 (claim_jump_space): New.
17342 (sort_tracepoints): New.
17343 (MAX_JUMP_SIZE): New.
17344 (cmd_qtstart): Handle fast tracepoints. Sync tracepoints with the
17345 IPA.
17346 (stop_tracing) [IN_PROCESS_AGENT]: Don't include the tdisconnected
17347 support. Upload fast traceframes, and delete internal IPA
17348 breakpoints.
17349 (stop_tracing_handler): New.
17350 (flush_trace_buffer_handler): New.
17351 (cmd_qtstop): Upload fast tracepoints.
17352 (response_tracepoint): Handle fast tracepoints.
17353 (tracepoint_finished_step): Upload fast traceframes. Set the
17354 tracepoint hit context's tracepoint type.
17355 (handle_tracepoint_bkpts): New.
17356 (tracepoint_was_hit): Set the tracepoint hit context's tracepoint
17357 type. Add comment about fast tracepoints.
17358 (collect_data_at_tracepoint) [IN_PROCESS_AGENT]: Don't access the
17359 non-existing action_str field.
17360 (get_context_regcache): Handle fast tracepoints.
17361 (do_action_at_tracepoint) [!IN_PROCESS_AGENT]: Don't write the PC
17362 to the regcache.
17363 (fast_tracepoint_from_jump_pad_address): New.
17364 (fast_tracepoint_from_ipa_tpoint_address): New.
17365 (collecting_t): New.
17366 (force_unlock_trace_buffer): New.
17367 (fast_tracepoint_collecting): New.
17368 (collecting): New.
17369 (gdb_collect): New.
17370 (write_inferior_data_ptr): New.
17371 (target_tp_heap): New.
17372 (target_malloc): New.
17373 (download_agent_expr): New.
17374 (UALIGN): New.
17375 (download_tracepoints): New.
17376 (download_trace_state_variables): New.
17377 (upload_fast_traceframes): New.
17378 (IPA_FIRST_TRACEFRAME): New.
17379 (IPA_NEXT_TRACEFRAME_1): New.
17380 (IPA_NEXT_TRACEFRAME): New.
17381 [IN_PROCESS_AGENT]: Include sys/mman.h and fcntl.h.
17382 [IN_PROCESS_AGENT] (gdb_tp_heap_buffer, gdb_jump_pad_buffer)
17383 (gdb_jump_pad_buffer_end): New.
17384 [IN_PROCESS_AGENT] (initialize_tracepoint_ftlib): New.
17385 (initialize_tracepoint): Adjust.
17386 [IN_PROCESS_AGENT]: Allocate the IPA heap, and jump pad scratch
17387 buffer. Initialize the low module.
17388 * utils.c (PREFIX, TOOLNAME): New.
17389 (malloc_failure): Use PREFIX.
17390 (error): In the IPA, an error causes an exit.
17391 (fatal, warning): Use PREFIX.
17392 (internal_error): Use TOOLNAME.
17393 (NUMCELLS): Increase to 10.
17394 * configure, config.in: Regenerate.
17395
17396 2010-06-01 Pedro Alves <pedro@codesourcery.com>
17397
17398 * server.c (handle_query) <qSupported>: Do two passes over the
17399 qSupported string to avoid nesting strtok.
17400
17401 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
17402
17403 * Makefile.in (SFILES): Add $(srcdir)/proc-service.list.
17404 (CDEPS): New.
17405 * configure.ac (RDYNAMIC): New AC_MSG_CHECKING wrapping. Test also
17406 -Wl,--dynamic-list.
17407 * configure: Regenerate.
17408 * proc-service.list: New.
17409
17410 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
17411
17412 * linux-low.c (linux_core_of_thread): Fix crash on invalid CONTENT.
17413 New comment.
17414
17415 2010-05-26 Ozkan Sezer <sezeroz@gmail.com>
17416
17417 * gdbreplay.c (remote_open): Check error return from socket() call by
17418 its equality to -1 not by it being negative.
17419 * remote-utils.c (remote_open): Likewise.
17420
17421 2010-05-23 Pedro Alves <pedro@codesourcery.com>
17422
17423 * config.h: Regenerate.
17424
17425 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
17426
17427 * linux-m68k-low.c (ps_get_thread_area): Don't define if kernel
17428 doesn't provide PTRACE_GET_THREAD_AREA.
17429
17430 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
17431
17432 * linux-m68k-low.c: Include <asm/ptrace.h>
17433 (ps_get_thread_area): Implement.
17434
17435 2010-05-03 Doug Evans <dje@google.com>
17436
17437 * event-loop.c (struct callback_event): New struct.
17438 (callback_list): New global.
17439 (append_callback_event, delete_callback_event): New functions.
17440 (process_callback): New function.
17441 (start_event_loop): Call it.
17442 * remote-utils.c (NOT_SCHEDULED): Define.
17443 (readchar_buf, readchar_bufcnt, readchar_bufp): New static globals,
17444 moved out of readchar.
17445 (readchar): Rewrite. Call reschedule before returning.
17446 (reset_readchar): New function.
17447 (remote_close): Call it.
17448 (process_remaining, reschedule): New functions.
17449 * server.h (callback_handler_func): New typedef.
17450 (append_callback_event, delete_callback_event): Declare.
17451
17452 2010-05-03 Pedro Alves <pedro@codesourcery.com>
17453
17454 * proc-service.c (ps_pglobal_lookup): Use
17455 thread_db_look_up_one_symbol.
17456 * remote-utils.c (look_up_one_symbol): Add new `may_ask_gdb'
17457 parameter. Use it instead of all_symbols_looked_up.
17458 * server.h (struct process_info) <all_symbols_looked_up>: Delete
17459 field.
17460 (all_symbols_looked_up): Don't declare.
17461 (look_up_one_symbol): Add new `may_ask_gdb' parameter.
17462 * thread-db.c (struct thread_db) <all_symbols_looked_up>: New
17463 field.
17464 (thread_db_look_up_symbols): Adjust call to look_up_one_symbol.
17465 Set all_symbols_looked_up here.
17466 (thread_db_look_up_one_symbol): New.
17467 (thread_db_get_tls_address): Adjust.
17468 (thread_db_load_search, try_thread_db_load_1): Always allocate the
17469 thread_db object on the heap, and tentatively set it in the
17470 process structure.
17471 (thread_db_init): Don't set all_symbols_looked_up here.
17472 * linux-low.h (thread_db_look_up_one_symbol): Declare.
17473
17474 2010-05-03 Pedro Alves <pedro@codesourcery.com>
17475
17476 * linux-low.c (linux_kill, linux_detach): Adjust.
17477 (status_pending_p_callback): Remove redundant statement. Check
17478 for !TARGET_WAITIKIND_IGNORE, instead of
17479 TARGET_WAITKIND_STOPPED.
17480 (handle_tracepoints): Make sure LWP is locked. Adjust.
17481 (linux_wait_for_event_1): Adjust.
17482 (linux_cancel_breakpoints): New.
17483 (unsuspend_one_lwp): New.
17484 (unsuspend_all_lwps): New.
17485 (linux_wait_1): If finishing a step-over, unsuspend all lwps.
17486 (send_sigstop_callback): Change return type to int, add new
17487 `except' parameter and handle it.
17488 (suspend_and_send_sigstop_callback): New.
17489 (stop_all_lwps): Add new `suspend' and `expect' parameters, and
17490 pass them down. If SUSPEND, also increment the lwp's suspend
17491 count.
17492 (linux_resume_one_lwp): Add notice about resuming a suspended LWP.
17493 (need_step_over_p): Don't consider suspended LWPs.
17494 (start_step_over): Adjust.
17495 (proceed_one_lwp): Change return type to int, add new `except'
17496 parameter and handle it.
17497 (unsuspend_and_proceed_one_lwp): New.
17498 (proceed_all_lwps): Use find_inferior instead of
17499 for_each_inferior.
17500 (unstop_all_lwps): Add `unsuspend' parameter. If UNSUSPEND, them
17501 also decrement the suspend count of LWPs. Pass `except' down,
17502 instead of hacking its suspend count.
17503 (linux_pause_all): Add `freeze' parameter. Adjust.
17504 (linux_unpause_all): New.
17505 (linux_target_ops): Install linux_unpause_all.
17506 * server.c (handle_status): Adjust.
17507 * target.h (struct target_ops): New fields `unpause_all' and
17508 `cancel_breakpoints'. Add new parameter to `pause_all'.
17509 (pause_all): Add new `freeze' parameter.
17510 (unpause_all): New.
17511 (cancel_breakpoints): New.
17512 * tracepoint.c (clear_installed_tracepoints): Pause threads, and
17513 cancel breakpoints.
17514 (cmd_qtstart): Pause threads.
17515 (stop_tracing): Pause threads, and cancel breakpoints.
17516 * win32-low.c (win32_target_ops): Adjust.
17517
17518 2010-05-03 Pedro Alves <pedro@codesourcery.com>
17519
17520 * linux-low.c (linux_wait_for_event_1): Move passing the signal to
17521 the inferior right away from here...
17522 (linux_wait_1): ... to here, and adjust to check the thread's
17523 last_resume_kind instead of the lwp's step or stop_expected flags.
17524
17525 2010-05-02 Pedro Alves <pedro@codesourcery.com>
17526
17527 * README: Use consistent `GDB' and `GDBserver' spellings.
17528
17529 2010-05-02 Pedro Alves <pedro@codesourcery.com>
17530
17531 * linux-low.c (linux_kill_one_lwp): Assume the lwp is stopped.
17532 (linux_kill): Stop all lwps here. Don't delete the main lwp here.
17533 (linux_detach_one_lwp): Assume the lwp is stopped.
17534 (any_thread_of): Delete.
17535 (linux_detach): Stop all lwps here. Don't blindly delete all
17536 breakpoints.
17537 (delete_lwp_callback): New.
17538 (linux_mourn): Delete all lwps of the process that is gone.
17539 (linux_wait_1): Don't delete the last lwp of the process here.
17540 * mem-break.h (mark_breakpoints_out): Declare.
17541 * mem-break.c (mark_breakpoints_out): New.
17542 (free_all_breakpoints): Use it.
17543 * server.c (handle_target_event): If the process is gone, mark
17544 breakpoints out.
17545 * thread-db.c (struct thread_db) <create_bp>: New field.
17546 (thread_db_enable_reporting): Fix prototype. Store a thread event
17547 breakpoint reference in the thread_db struct.
17548 (thread_db_load_search): Clear the thread_db object.
17549 (try_thread_db_load_1): Ditto.
17550 (switch_to_process): New.
17551 (disable_thread_event_reporting): Use it.
17552 (remove_thread_event_breakpoints): New.
17553 (thread_db_detach, thread_db_mourn): Use it.
17554
17555 2010-05-01 Pedro Alves <pedro@codesourcery.com>
17556
17557 * linux-low.c (linux_enable_event_reporting): New.
17558 (linux_wait_for_event_1, handle_extended_wait): Use it.
17559
17560 2010-04-30 Pedro Alves <pedro@codesourcery.com>
17561
17562 * linux-low.c (linux_kill_one_lwp, linux_kill)
17563 (linux_detach_one_lwp): Adjust to send_sigstop interface change.
17564 (send_sigstop): Take an lwp_info as parameter instead. Queue a
17565 SIGSTOP even if the LWP is stopped.
17566 (send_sigstop_callback): New.
17567 (stop_all_lwps): Use send_sigstop_callback instead.
17568 (linux_resume_one_thread): Adjust.
17569 (proceed_one_lwp): Still proceed an LWP that the client has
17570 requested to stop, if we haven't reported it as stopped yet. Make
17571 sure that LWPs the client want stopped, have a pending SIGSTOP.
17572
17573 2010-04-26 Doug Evans <dje@google.com>
17574
17575 * server.c (handle_general_set): Make static.
17576
17577 * remote-utils.c (putpkt_binary_1): Call readchar instead of read.
17578 Print received char after testing for error/eof instead of before.
17579 (input_interrupt): Tweak comment.
17580
17581 2010-04-23 Doug Evans <dje@google.com>
17582
17583 * server.c (start_inferior): Print inferior argv if --debug.
17584
17585 2010-04-21 Aleksandar Ristovski <aristovski@qnx.com>
17586
17587 * Makefile.in (nto_low_h nto-low.o nto-x86-low.o): New dependency lists.
17588 * nto-x86-low.c: Include server.h
17589
17590 2010-04-20 Pierre Muller <muller@ics.u-strasbg.fr>
17591
17592 * win32-i386-low.c: Use __x86_64__ macro instead of __x86_64 to
17593 be consistent with other sources of this directory.
17594 (init_registers_amd64): Correct name of source file of this function
17595 in the comment.
17596
17597 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
17598
17599 * configure.srv (x86_64-*-mingw*): New configuration for Windows
17600 64-bit executables.
17601
17602 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
17603
17604 * win32-i386-low.c: Add 64-bit support.
17605 (CONTEXT_EXTENDED_REGISTERS): Set macro to zero if not exisiting.
17606 (init_registers_amd64): Declare.
17607 (mappings): Add 64-bit version of array.
17608 (init_windows_x86): New function.
17609 (the_low_target): Change init_arch field to init_windows_x86.
17610
17611 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
17612
17613 * win32-low.c: Adapt to support also 64-bit architecture.
17614 (child_xfer_memory): Use uintptr_t type for local variable `addr'.
17615 (get_image_name): Use SIZE_T type for local variable `done'.
17616 (psapi_get_dll_name): Use LPVOID type for parameter `BaseAddress'.
17617 (toolhelp_get_dll_name): Idem.
17618 (handle_load_dll): Use CORE_ADDR type for local variable `load_addr'.
17619 Use uintptr_t typecast to avoid warning.
17620 (handle_unload_dll): Use uintptr_t typecast to avoid warning.
17621 (handle_exception): Use phex_nz to avoid warning.
17622 (win32_wait): Remove unused local variable `process'.
17623
17624 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
17625
17626 * configure.srv (srv_amd64_regobj): Replace `x86-64-avx.o' by
17627 `amd64-avx.o'.
17628
17629 2010-04-17 Pierre Muller <muller@ics.u-strasbg.fr>
17630
17631 * configure.ac: Use `ws2_32' library for srv_mingw.
17632 * configure: Regenerate.
17633 * gdbreplay.c: Include winsock2.h instead of winsock.h.
17634 * remote-utils.c: Likewise.
17635
17636 2010-04-17 H.J. Lu <hongjiu.lu@intel.com>
17637
17638 * linux-x86-low.c (xmltarget_amd64_linux_no_xml): Define only
17639 if __x86_64__ is defined.
17640
17641 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
17642
17643 * configure: Regenerate.
17644
17645 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
17646
17647 * server.c (handle_query): Handle 'qGetTIBAddr' query.
17648 * target.h (target_ops): New get_tib_address field.
17649 * win32-low.h (win32_thread_info): Add thread_local_base field.
17650 * win32-low.c (child_add_thread): Add tlb argument.
17651 Set thread_local_base field to TLB.
17652 (get_child_debug_event): Adapt to child_add_thread change.
17653 (win32_get_tib_address): New function.
17654 (win32_target_ops): Set get_tib_address field to
17655 win32_get_tib_address.
17656 * linux-low.c (linux_target_ops): Set get_tib_address field to NULL.
17657
17658 2010-04-12 Pedro Alves <pedro@codesourcery.com>
17659
17660 * linux-low.c (linux_mourn): Also remove the process.
17661 * server.c (handle_target_event): Don't remove the process here.
17662 * nto-low.c (nto_mourn): New.
17663 (nto_target_ops): Install it.
17664 * spu-low.c (spu_mourn): New.
17665 (spu_target_ops): Install it.
17666 * win32-low.c (win32_mourn): New.
17667 (win32_target_ops): Install it.
17668
17669 2010-04-12 Pedro Alves <pedro@codesourcery.com>
17670
17671 * server.h (buffer_xml_printf): Remove redundant `;'.
17672
17673 2010-04-12 Pedro Alves <pedro@codesourcery.com>
17674
17675 * regcache.c (set_register_cache): Invalidate regcaches before
17676 changing the register cache layout.
17677 (regcache_invalidate_one): Allow a NULL regcache.
17678 * linux-x86-low.c (x86_linux_update_xmltarget): Invalidate
17679 regcaches before changing the register cache layout or the target
17680 regsets.
17681
17682 2010-04-12 H.J. Lu <hongjiu.lu@intel.com>
17683
17684 * linux-x86-low.c (x86_linux_update_xmltarget): Avoid unused
17685 variable warning on Linux/x86-64.
17686
17687 2010-04-11 Pedro Alves <pedro@codesourcery.com>
17688
17689 GDBserver disconnected tracing support.
17690
17691 * linux-low.c (linux_remove_process): Delete.
17692 (add_lwp): Don't set last_resume_kind here.
17693 (linux_kill): Use `mourn'.
17694 (linux_detach): Use `thread_db_detach', and `mourn'.
17695 (linux_mourn): New.
17696 (linux_attach_lwp_1): Adjust comment.
17697 (linux_attach): last_resume_kind moved the thread_info; adjust.
17698 (status_pending_p_callback): Adjust.
17699 (linux_wait_for_event_1): Adjust.
17700 (count_events_callback, select_singlestep_lwp_callback)
17701 (select_event_lwp_callback, cancel_breakpoints_callback)
17702 (db_wants_lwp_stopped, linux_wait_1, need_step_over_p)
17703 (proceed_one_lwp): Adjust.
17704 (linux_async): Add debug output.
17705 (linux_thread_stopped): New.
17706 (linux_pause_all): New.
17707 (linux_target_ops): Install linux_mourn, linux_thread_stopped and
17708 linux_pause_all.
17709 * linux-low.h (struct lwp_info): Delete last_resume_kind field.
17710 (thread_db_free): Delete declaration.
17711 (thread_db_detach, thread_db_mourn): Declare.
17712 * thread-db.c (thread_db_init): Use thread_db_mourn.
17713 (thread_db_free): Delete, split in two.
17714 (disable_thread_event_reporting): New.
17715 (thread_db_detach): New.
17716 (thread_db_mourn): New.
17717
17718 * server.h (struct thread_info) <last_resume_kind>: New field.
17719 <attached>: Add comment.
17720 <gdb_detached>: New field.
17721 (handler_func): Change return type to int.
17722 (handle_serial_event, handle_target_event): Ditto.
17723 (gdb_connected): Declare.
17724 (tracing): Delete.
17725 (disconnected_tracing): Declare.
17726 (stop_tracing): Declare.
17727
17728 * server.c (handle_query) <qSupported>: Report support for
17729 disconnected tracing.
17730 (queue_stop_reply_callback): Account for running threads.
17731 (gdb_wants_thread_stopped): New.
17732 (gdb_wants_all_threads_stopped): New.
17733 (gdb_reattached_process): New.
17734 (handle_status): Clear the `gdb_detached' flag of all processes.
17735 In all-stop, stop all threads.
17736 (main): Be sure to leave tfind mode. Handle disconnected tracing.
17737 (process_serial_event): If the remote connection breaks, or if an
17738 exit was forced with "monitor exit", force an event loop exit.
17739 Handle disconnected tracing on detach.
17740 (handle_serial_event): Adjust.
17741 (handle_target_event): If GDB isn't connected, forward events back
17742 to the inferior, unless the last process exited, in which case,
17743 exit gdbserver. Adjust interface.
17744
17745 * remote-utils.c (remote_open): Don't block in accept. Instead
17746 register an event loop source on the listen socket file
17747 descriptor. Refactor bits into ...
17748 (listen_desc): ... this new global.
17749 (gdb_connected): ... this new function.
17750 (enable_async_notification): ... this new function.
17751 (handle_accept_event): ... this new function.
17752 (remote_close): Clear remote_desc.
17753
17754 * inferiors.c (add_thread): Set the new thread's last_resume_kind.
17755
17756 * target.h (struct target_ops) <mourn, thread_stopped, pause_all>:
17757 New fields.
17758 (mourn_inferior): Define.
17759 (target_process_qsupported): Avoid the dangling else problem.
17760 (thread_stopped): Define.
17761 (pause_all): Define.
17762 (target_waitstatus_to_string): Declare.
17763 * target.c (target_waitstatus_to_string): New.
17764
17765 * tracepoint.c (tracing): Make extern.
17766 (disconnected_tracing): New.
17767 (stop_tracing): Make extern. Handle tracing stops due to GDB
17768 disconnecting.
17769 (cmd_qtdisconnected): New.
17770 (cmd_qtstatus): Report disconnected tracing status in trace reply.
17771 (handle_tracepoint_general_set): Handle QTDisconnected.
17772
17773 * event-loop.c (event_handler_func): Change return type to int.
17774 (process_event): Bail out if the event handler wants the event
17775 loop to stop.
17776 (handle_file_event): Ditto.
17777 (start_event_loop): Bail out if the event handler wants the event
17778 loop to stop.
17779
17780 * nto-low.c (nto_target_ops): Adjust.
17781 * spu-low.c (spu_wait): Don't remove the process here.
17782 (spu_target_ops): Adjust.
17783 * win32-low.c (win32_wait): Don't remove the process here.
17784 (win32_target_ops): Adjust.
17785
17786 2010-04-11 Pedro Alves <pedro@codesourcery.com>
17787
17788 * regcache.c (realloc_register_cache): Invalidate inferior's
17789 regcache before recreating it.
17790
17791 2010-04-09 Pedro Alves <pedro@codesourcery.com>
17792
17793 * tracepoint.c (cmd_qtstatus): Report trace buffer circularity.
17794
17795 2010-04-09 Stan Shebs <stan@codesourcery.com>
17796 Pedro Alves <pedro@codesourcery.com>
17797
17798 * server.h (LONGEST): New.
17799 (struct thread_info) <while_stepping>: New field.
17800 (unpack_varlen_hex, xrealloc, pulongest, plongest, phex_nz):
17801 Declare.
17802 (initialize_tracepoint, handle_tracepoint_general_set)
17803 (handle_tracepoint_query, tracepoint_finished_step)
17804 (tracepoint_was_hit, release_while_stepping_state_list):
17805 (current_traceframe): Declare.
17806 * server.c (handle_general_set): Handle tracepoint packets.
17807 (read_memory): New.
17808 (write_memory): New.
17809 (handle_search_memory_1): Use read_memory.
17810 (handle_query): Report support for conditional tracepoints, trace
17811 state variables, and tracepoint sources. Handle tracepoint
17812 queries.
17813 (main): Initialize the tracepoints module.
17814 (process_serial_event): Handle traceframe reads/writes.
17815
17816 * linux-low.c (handle_tracepoints): New.
17817 (linux_wait_1): Call it.
17818 (linux_resume_one_lwp): Handle while-stepping.
17819 (linux_supports_tracepoints, linux_read_pc, linux_write_pc): New.
17820 (linux_target_ops): Install them.
17821 * linux-low.h (struct linux_target_ops) <supports_tracepoints>:
17822 New field.
17823 * linux-x86-low.c (x86_supports_tracepoints): New.
17824 (the_low_target). Install it.
17825
17826 * mem-break.h (delete_breakpoint): Declare.
17827 * mem-break.c (delete_breakpoint): Make external.
17828
17829 * target.h (struct target_ops): Add `supports_tracepoints',
17830 `read_pc', and `write_pc' fields.
17831 (target_supports_tracepoints): Define.
17832 * utils.c (xrealloc, decimal2str, pulongest, plongest, thirty_two)
17833 (phex_nz): New.
17834
17835 * regcache.h (struct regcache) <registers_owned>: New field.
17836 (init_register_cache, regcache_cpy): Declare.
17837 (regcache_read_pc, regcache_write_pc): Declare.
17838 (register_cache_size): Declare.
17839 (supply_regblock): Declare.
17840 * regcache.c (init_register_cache): New.
17841 (new_register_cache): Use it.
17842 (regcache_cpy): New.
17843 (register_cache_size): New.
17844 (supply_regblock): New.
17845 (regcache_read_pc, regcache_write_pc): New.
17846
17847 * tracepoint.c: New.
17848
17849 * Makefile.in (OBS): Add tracepoint.o.
17850 (tracepoint.o): New rule.
17851
17852 2010-04-08 H.J. Lu <hongjiu.lu@intel.com>
17853
17854 * Makefile.in (clean): Also remove i386-mmx.c i386-mmx-linux.c.
17855 (i386-mmx.o): New.
17856 (i386-mmx.c): Likewise.
17857 (i386-mmx-linux.o): Likewise.
17858 (i386-mmx-linux.c): Likewise.
17859
17860 * configure.srv (srv_i386_regobj): Add i386-mmx.o.
17861 (srv_i386_linux_regobj): Add i386-mmx-linux.o.
17862 (srv_i386_xmlfiles): Add i386/i386-mmx.xml.
17863 (srv_i386_linux_xmlfiles): Add i386/i386-mmx-linux.xml.
17864
17865 * linux-x86-low.c (init_registers_i386_mmx_linux): New.
17866 (x86_linux_update_xmltarget): Call init_registers_i386_mmx_linux
17867 and return if ptrace PTRACE_GETFPXREGS failed in 32bit.
17868
17869 2010-04-07 H.J. Lu <hongjiu.lu@intel.com>
17870
17871 * Makefile.in (clean): Updated.
17872 (i386-avx.o): New.
17873 (i386-avx.c): Likewise.
17874 (i386-avx-linux.o): Likewise.
17875 (i386-avx-linux.c): Likewise.
17876 (amd64-avx.o): Likewise.
17877 (amd64-avx.c): Likewise.
17878 (amd64-avx-linux.o): Likewise.
17879 (amd64-avx-linux.c): Likewise.
17880
17881 * configure.srv (srv_i386_regobj): Add i386-avx.o.
17882 (srv_i386_linux_regobj): Add i386-avx-linux.o.
17883 (srv_amd64_regobj): Add amd64-avx.o.
17884 (srv_amd64_linux_regobj): Add amd64-avx-linux.o.
17885 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx.xml.
17886 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx.xml.
17887 (srv_i386_xmlfiles): Add i386/i386-avx.xml.
17888 (srv_amd64_xmlfiles): Add i386/amd64-avx.xml.
17889 (srv_i386_linux_xmlfiles): Add i386/i386-avx-linux.xml.
17890 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-linux.xml.
17891
17892 * i387-fp.c: Include "i386-xstate.h".
17893 (i387_xsave): New.
17894 (i387_cache_to_xsave): Likewise.
17895 (i387_xsave_to_cache): Likewise.
17896 (x86_xcr0): Likewise.
17897
17898 * i387-fp.h (i387_cache_to_xsave): Likewise.
17899 (i387_xsave_to_cache): Likewise.
17900 (x86_xcr0): Likewise.
17901
17902 * linux-arm-low.c (target_regsets): Initialize nt_type to 0.
17903 * linux-crisv32-low.c (target_regsets): Likewise.
17904 * linux-m68k-low.c (target_regsets): Likewise.
17905 * linux-mips-low.c (target_regsets): Likewise.
17906 * linux-ppc-low.c (target_regsets): Likewise.
17907 * linux-s390-low.c (target_regsets): Likewise.
17908 * linux-sh-low.c (target_regsets): Likewise.
17909 * linux-sparc-low.c (target_regsets): Likewise.
17910 * linux-xtensa-low.c (target_regsets): Likewise.
17911
17912 * linux-low.c: Include <sys/uio.h>.
17913 (regsets_fetch_inferior_registers): Support nt_type.
17914 (regsets_store_inferior_registers): Likewise.
17915 (linux_process_qsupported): New.
17916 (linux_target_ops): Add linux_process_qsupported.
17917
17918 * linux-low.h (regset_info): Add nt_type.
17919 (linux_target_ops): Add process_qsupported.
17920
17921 * linux-x86-low.c: Include "i386-xstate.h", "elf/common.h"
17922 and <sys/uio.h>.
17923 (init_registers_i386_avx_linux): New.
17924 (init_registers_amd64_avx_linux): Likewise.
17925 (xmltarget_i386_linux_no_xml): Likewise.
17926 (xmltarget_amd64_linux_no_xml): Likewise.
17927 (PTRACE_GETREGSET): Likewise.
17928 (PTRACE_SETREGSET): Likewise.
17929 (x86_fill_xstateregset): Likewise.
17930 (x86_store_xstateregset): Likewise.
17931 (use_xml): Likewise.
17932 (x86_linux_update_xmltarget): Likewise.
17933 (x86_linux_process_qsupported): Likewise.
17934 (target_regsets): Add NT_X86_XSTATE entry and Initialize nt_type.
17935 (x86_arch_setup): Don't call init_registers_amd64_linux nor
17936 init_registers_i386_linux here. Call
17937 x86_linux_update_xmltarget.
17938 (the_low_target): Add x86_linux_process_qsupported.
17939
17940 * server.c (handle_query): Call target_process_qsupported.
17941
17942 * target.h (target_ops): Add process_qsupported.
17943 (target_process_qsupported): New.
17944
17945 2010-04-03 Pedro Alves <pedro@codesourcery.com>
17946
17947 * inferiors.c (add_thread): Set last_status kind to
17948 TARGET_WAITKIND_IGNORE.
17949 * linux-low.c (cancel_breakpoint): Remove unnecessary regcache
17950 fetch. Use ptid_of. Avoid unnecessary get_lwp_thread calls.
17951 (linux_wait_1): Move `thread' local definition to block that uses
17952 it. Don't NULL initialize `event_child'.
17953 (linux_resume_one_thread): Avoid unnecessary get_lwp_thread calls.
17954 Alway set the thread's last_status to TARGET_WAITKIND_IGNORE.
17955 * linux-x86-low.c (x86_breakpoint_at): Read raw memory.
17956
17957 2010-04-01 Pedro Alves <pedro@codesourcery.com>
17958
17959 * linux-low.c (get_stop_pc): Don't adjust the PC if stopped with
17960 an extended waitstatus, or by a watchpoint.
17961 (cancel_breakpoints_callback): Don't cancel a breakpoint if the
17962 thread was stepping or has been stopped by a watchpoint.
17963
17964 2010-04-01 Pedro Alves <pedro@codesourcery.com>
17965
17966 * mem-break.c (struct raw_breakpoint): New field shlib_disabled.
17967 (set_gdb_breakpoint_at): If GDB is inserting a breakpoint on top
17968 of another, then delete the previous, and validate all
17969 breakpoints.
17970 (validate_inserted_breakpoint): New.
17971 (delete_disabled_breakpoints): New.
17972 (validate_breakpoints): New.
17973 (check_mem_read): Validate breakpoints before trusting their
17974 shadow. Delete disabled breakpoints.
17975 (check_mem_write): Validate breakpoints before trusting they
17976 should be inserted. Delete disabled breakpoints.
17977 * mem-break.h (validate_breakpoints):
17978 * server.c (handle_query): Validate breakpoints when we see a
17979 qSymbol query.
17980
17981 2010-04-01 Pedro Alves <pedro@codesourcery.com>
17982
17983 * linux-low.c (linux_wait_1): Avoid setting need_step_over is
17984 there's a GDB breakpoint at stop_pc. Always report a trap to GDB
17985 if we could tell there's a GDB breakpoint at stop_pc.
17986 (need_step_over_p): Don't do a step over if we find a GDB
17987 breakpoint at the resume PC.
17988
17989 * mem-break.c (struct raw_breakpoint): New.
17990 (enum bkpt_type): New type `gdb_breakpoint'.
17991 (struct breakpoint): Delete the `PC', `old_data' and `inserted'
17992 fields. New field `raw'.
17993 (find_raw_breakpoint_at): New.
17994 (set_raw_breakpoint_at): Handle refcounting. Create a raw
17995 breakpoint instead.
17996 (set_breakpoint_at): Adjust.
17997 (delete_raw_breakpoint): New.
17998 (release_breakpoint): New.
17999 (delete_breakpoint): Rename to...
18000 (delete_breakpoint_1): ... this. Add proc parameter. Use
18001 release_breakpoint. Return ENOENT.
18002 (delete_breakpoint): Reimplement.
18003 (find_breakpoint_at): Delete.
18004 (find_gdb_breakpoint_at): New.
18005 (delete_breakpoint_at): Delete.
18006 (set_gdb_breakpoint_at): New.
18007 (delete_gdb_breakpoint_at): New.
18008 (gdb_breakpoint_here): New.
18009 (set_reinsert_breakpoint): Use release_breakpoint.
18010 (uninsert_breakpoint): Rename to ...
18011 (uninsert_raw_breakpoint): ... this.
18012 (uninsert_breakpoints_at): Adjust to handle raw breakpoints.
18013 (reinsert_raw_breakpoint): Change parameter type to
18014 raw_breakpoint.
18015 (reinsert_breakpoints_at): Adjust to handle raw breakpoints
18016 instead.
18017 (check_breakpoints): Adjust. Use release_breakpoint.
18018 (breakpoint_here): Rewrite using find_raw_breakpoint_at.
18019 (breakpoint_inserted_here): Ditto.
18020 (check_mem_read): Adjust to iterate over raw breakpoints instead.
18021 Don't trust the breakpoint's shadow if it is not inserted.
18022 (check_mem_write): Adjust to iterate over raw breakpoints instead.
18023 (delete_all_breakpoints): Adjust.
18024 (free_all_breakpoints): Mark all breakpoints as uninserted, and
18025 use delete_breakpoint_1.
18026
18027 * mem-break.h (breakpoints_supported): Delete declaration.
18028 (set_gdb_breakpoint_at): Declare.
18029 (gdb_breakpoint_here): Declare.
18030 (delete_breakpoint_at): Delete.
18031 (delete_gdb_breakpoint_at): Declare.
18032
18033 * server.h (struct raw_breakpoint): Forward declare.
18034 (struct process_info): New field `raw_breakpoints'.
18035
18036 * linux-x86-low.c (x86_insert_point, x86_remote_point): Handle Z0
18037 breakpoints.
18038
18039 2010-03-24 Pedro Alves <pedro@codesourcery.com>
18040
18041 * linux-low.c (status_pending_p_callback): Fix comment.
18042 (linux_wait_for_event_1): Move most of the internal breakpoint
18043 handling from here...
18044 (linux_wait_1): ... to here.
18045 (count_events_callback): New.
18046 (select_singlestep_lwp_callback): New.
18047 (select_event_lwp_callback): New.
18048 (cancel_breakpoints_callback): New.
18049 (select_event_lwp): New.
18050 (linux_wait_1): Simplify internal breakpoint handling. Give equal
18051 priority to all LWPs that have had events that should be reported
18052 to the client. Cancel breakpoints when about to reporting the
18053 event to the client, not while stopping lwps. No longer cancel
18054 finished single-steps here.
18055 (cancel_finished_single_step): Delete.
18056 (cancel_finished_single_steps): Delete.
18057
18058 2010-03-24 Pedro Alves <pedro@codesourcery.com>
18059
18060 * mem-break.c (enum bkpt_type): New.
18061 (struct breakpoint): New field `type'.
18062 (set_breakpoint_at): Change return type to struct breakpoint
18063 pointer. Set type to `other_breakpoint' by default.
18064 (delete_breakpoint): Rewrite, supporting more than one breakpoint
18065 in the breakpoint list.
18066 (delete_reinsert_breakpoints): Only delete reinsert breakpoints.
18067 (reinsert_breakpoint): Rename to ...
18068 (reinsert_raw_breakpoint): ... this.
18069 (reinsert_breakpoints_at): Adjust.
18070 * mem-break.h (struct breakpoint): Declare.
18071 (set_breakpoint_at): Change return type to struct breakpoint
18072 pointer.
18073
18074 2010-03-24 Pedro Alves <pedro@codesourcery.com>
18075
18076 * server.c (handle_query): Assign, not compare.
18077
18078 2010-03-24 Pedro Alves <pedro@codesourcery.com>
18079
18080 Teach linux gdbserver to step-over-breakpoints.
18081
18082 * linux-low.c (can_hardware_single_step): New.
18083 (supports_breakpoints): New.
18084 (handle_extended_wait): If stopping threads, read the stop pc of
18085 the new cloned LWP.
18086 (get_pc): New.
18087 (get_stop_pc): Add `lwp' parameter. Handle it. Bail out if the
18088 low target doesn't support retrieving the PC.
18089 (add_lwp): Set last_resume_kind to resume_continue.
18090 (linux_attach_lwp_1): Adjust comments. Always set stop_expected.
18091 (linux_attach): Don't clear stop_expected. Set the lwp's
18092 last_resume_kind to resume_stop.
18093 (linux_detach_one_lwp): Don't check for removed breakpoints.
18094 (check_removed_breakpoint): Delete.
18095 (status_pending_p): Rename to ...
18096 (status_pending_p_callback): ... this. Don't check for removed
18097 breakpoints. Don't consider threads that are stopped from GDB's
18098 perspective.
18099 (linux_wait_for_lwp): Always read the stop_pc here.
18100 (cancel_breakpoint): New.
18101 (step_over_bkpt): New global.
18102 (linux_wait_for_event_1): Implement stepping over breakpoints.
18103 (gdb_wants_lwp_stopped): New.
18104 (gdb_wants_all_stopped): New.
18105 (linux_wait_1): Tag threads as gdb-wants-stopped. Cancel finished
18106 single-step traps here. Store the thread's last reported target
18107 wait status.
18108 (send_sigstop): Don't clear stop_expected. Always set it,
18109 instead.
18110 (mark_lwp_dead): Remove reference to pending_is_breakpoint.
18111 (cancel_finished_single_step): New.
18112 (cancel_finished_single_steps): New.
18113 (wait_for_sigstop): Don't cancel finished single-step traps here.
18114 (linux_resume_one_lwp): Don't check for removed breakpoints.
18115 Don't set `step' on non-hardware step archs.
18116 (linux_set_resume_request): Ignore resume_stop requests if already
18117 stopping or stopped. Set the lwp's last_resume_kind.
18118 (resume_status_pending_p): Don't check for removed breakpoints.
18119 (need_step_over_p): New.
18120 (start_step_over): New.
18121 (finish_step_over): New.
18122 (linux_resume_one_thread): Always queue a sigstop for resume_stop
18123 requests. Clear the thread's last reported target waitstatus.
18124 Don't use the `suspended' flag. Don't consider pending breakpoints.
18125 (linux_resume): Start a step-over if necessary.
18126 (proceed_one_lwp): New.
18127 (proceed_all_lwps): New.
18128 (unstop_all_lwps): New.
18129 * linux-low.h (struct lwp_info): Rewrite comment for the
18130 `suspended' flag. Add the `stop_pc' field. Delete the
18131 `pending_stop_pc' field. Tweak the `stepping' flag's comment.
18132 Add `'last_resume_kind' and `need_step_over' fields.
18133 * inferiors.c (struct thread_info): Delete, moved elsewhere.
18134 * mem-break.c (struct breakpoint): Delete `reinserting' flag.
18135 Delete `breakpoint_to_reinsert' field. New flag `inserted'.
18136 (set_raw_breakpoint_at): New.
18137 (set_breakpoint_at): Rewrite to use it.
18138 (reinsert_breakpoint_handler): Delete.
18139 (set_reinsert_breakpoint): New.
18140 (reinsert_breakpoint_by_bp): Delete.
18141 (delete_reinsert_breakpoints): New.
18142 (uninsert_breakpoint): Rewrite.
18143 (uninsert_breakpoints_at): New.
18144 (reinsert_breakpoint): Rewrite.
18145 (reinsert_breakpoints_at): New.
18146 (check_breakpoints): Rewrite.
18147 (breakpoint_here): New.
18148 (breakpoint_inserted_here): New.
18149 (check_mem_read): Adjust.
18150 * mem-break.h (breakpoints_supported, breakpoint_here)
18151 (breakpoint_inserted_here, set_reinsert_breakpoint): Declare.
18152 (reinsert_breakpoint_by_bp): Delete declaration.
18153 (delete_reinsert_breakpoints): Declare.
18154 (reinsert_breakpoint): Delete declaration.
18155 (reinsert_breakpoints_at): Declare.
18156 (uninsert_breakpoint): Delete declaration.
18157 (uninsert_breakpoints_at): Declare.
18158 (check_breakpoints): Adjust prototype.
18159 * server.h: Adjust include order.
18160 (struct thread_info): Declare here. Add a `last_status' field.
18161
18162 2010-03-23 Michael Snyder <msnyder@vmware.com>
18163
18164 * server.c (crc32): New function.
18165 (handle_query): Add handling for 'qCRC:' request.
18166
18167 2010-03-23 Pedro Alves <pedro@codesourcery.com>
18168
18169 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR6 if the
18170 lwp had been stopped by a watchpoint.
18171
18172 2010-03-16 Pedro Alves <pedro@codesourcery.com>
18173
18174 * server.h (internal_error): Declare.
18175 (gdb_assert, ASSERT_FUNCTION, gdb_assert_fail): Define.
18176 * utils.c (internal_error): New function.
18177
18178 2010-03-15 Andreas Schwab <schwab@redhat.com>
18179
18180 * configure.srv: Fix typo setting srv_regobj.
18181
18182 2010-03-15 Pedro Alves <pedro@codesourcery.com>
18183
18184 * linux-low.c (fetch_register): Avoid passing a non string literal
18185 format to `error'.
18186 (usr_store_inferior_registers): Ditto.
18187
18188 2010-03-14 Pedro Alves <pedro@codesourcery.com>
18189
18190 * linux-low.c (linux_write_memory): Bail out early if peeking
18191 memory failed.
18192
18193 2010-03-14 Pedro Alves <pedro@codesourcery.com>
18194
18195 * linux-low.h (struct lwp_info): New fields
18196 `stopped_by_watchpoint' and `stopped_data_address'.
18197 * linux-low.c (linux_wait_for_lwp): Check for watchpoint triggers
18198 here, and cache them in the lwp object.
18199 (wait_for_sigstop): Check stopped_by_watchpoint lwp field
18200 directly.
18201 (linux_resume_one_lwp): Clear the lwp's stopped_by_watchpoint
18202 field.
18203 (linux_stopped_by_watchpoint): Rewrite.
18204 (linux_stopped_data_address): Rewrite.
18205
18206 2010-03-06 Simo Melenius <simo.melenius@iki.fi>
18207
18208 * linux-low.c (linux_wait_for_lwp): Fetch the regcache after
18209 switching the current inferior, not before.
18210
18211 2010-03-01 H.J. Lu <hongjiu.lu@intel.com>
18212
18213 * Makefile.in (clean): Replace reg-i386.c, reg-x86-64.c,
18214 reg-i386-linux.c and reg-x86-64-linux.c with i386.c, amd64.c,
18215 i386-linux.c and amd64-linux.c.
18216 (reg-i386.o): Removed.
18217 (reg-i386.c): Likewise.
18218 (reg-i386-linux.o): Likewise.
18219 (reg-i386-linux.c): Likewise.
18220 (reg-x86-64.o): Likewise.
18221 (reg-x86-64.c): Likewise.
18222 (reg-x86-64-linux.o): Likewise.
18223 (reg-x86-64-linux.c): Likewise.
18224 (i386.o): New.
18225 (i386.c): Likewise.
18226 (i386-linux.o): Likewise.
18227 (i386-linux.c): Likewise.
18228 (amd64.o): Likewise.
18229 (amd64.c): Likewise.
18230 (amd64-linux.o): Likewise.
18231 (amd64-linux.c): Likewise.
18232
18233 * configure.srv (srv_i386_regobj): New.
18234 (srv_i386_linux_regobj): Likewise.
18235 (srv_amd64_regobj): Likewise.
18236 (srv_amd64_linux_regobj): Likewise.
18237 (srv_i386_32bit_xmlfiles): Likewise.
18238 (srv_i386_64bit_xmlfiles): Likewise.
18239 (srv_i386_xmlfiles): Likewise.
18240 (srv_amd64_xmlfiles): Likewise.
18241 (srv_i386_linux_xmlfiles): Likewise.
18242 (srv_amd64_linux_xmlfiles): Likewise.
18243 (i[34567]86-*-cygwin*): Set srv_regobj to $srv_i386_regobj. Set
18244 srv_xmlfiles to $srv_i386_xmlfiles.
18245 (i[34567]86-*-mingw32ce*): Likewise.
18246 (i[34567]86-*-mingw*): Likewise.
18247 (i[34567]86-*-nto*): Likewise.
18248 (i[34567]86-*-linux*): Set srv_regobj to $srv_i386_linux_regobj
18249 and $srv_amd64_linux_regobj. Set srv_xmlfiles to
18250 $srv_i386_linux_xmlfiles and $srv_amd64_linux_xmlfiles.
18251 (x86_64-*-linux*): Likewise.
18252
18253 * linux-x86-low.c (init_registers_x86_64_linux): Removed.
18254 (init_registers_amd64_linux): New.
18255 (x86_arch_setup): Replace init_registers_x86_64_linux with
18256 init_registers_amd64_linux.
18257
18258 2010-02-23 Maxim Kuvyrkov <maxim@codesourcery.com>
18259
18260 * configure.ac: Check for libdl. If it is not available link against
18261 static libthread_db.
18262 * configure: Regenerate.
18263
18264 2010-02-22 Pedro Alves <pedro@codesourcery.com>
18265
18266 PR9605
18267
18268 * i386-low.c (i386_length_and_rw_bits): Throw a fatal error if
18269 handing a read watchpoint.
18270 (i386_low_insert_watchpoint): Read watchpoints aren't supported.
18271
18272 2010-02-12 Doug Evans <dje@google.com>
18273
18274 * linux-low.c (linux_supports_tracefork_flag): Document.
18275 (linux_look_up_symbols): Add comment.
18276
18277 2010-02-03 H.J. Lu <hongjiu.lu@intel.com>
18278
18279 * regcache.c (supply_register): Clear regcache if buf is NULL.
18280
18281 2010-02-02 Nicolas Roche <roche@sourceware.org>
18282 Joel Brobecker <brobecker@adacore.com>
18283
18284 * inferiors.c (find_inferior): Add function documentation.
18285 (unloaded_dll): Handle the case where the unloaded dll has not
18286 been previously registered in the dll list.
18287
18288 2010-02-01 Daniel Jacobowitz <dan@codesourcery.com>
18289
18290 * linux-arm-low.c (thumb_breakpoint_len): Delete.
18291 (thumb2_breakpoint): New.
18292 (arm_breakpoint_at): Check for Thumb-2 breakpoints.
18293
18294 2010-01-29 Daniel Jacobowitz <dan@codesourcery.com>
18295
18296 * linux-low.c (get_stop_pc): Check for SIGTRAP.
18297 (linux_wait_for_event_1): Handle SIGILL and SIGSEGV as possible
18298 breakpoints.
18299
18300 2010-01-21 Pedro Alves <pedro@codesourcery.com>
18301
18302 * linux-ppc-low.c (ppc_arch_setup): Adjust to regcache changes.
18303
18304 2010-01-21 Jan Kratochvil <jan.kratochvil@redhat.com>
18305
18306 * linux-s390-low.c (s390_collect_ptrace_register)
18307 (s390_supply_ptrace_register): Adjust it for the new regcache parameter.
18308
18309 2010-01-21 Doug Evans <dje@google.com>
18310
18311 * linux-low.c (PTRACE_ARG3_TYPE): Change from long to void*.
18312 (PTRACE_ARG4_TYPE): New macro.
18313 (handle_extended_wait): Cast ptrace arg4 to PTRACE_ARG4_TYPE.
18314 (linux_wait_for_event_1, linux_resume_one_lwp): Ditto.
18315 (fetch_register): Cast to uintptr_t before casting to PTRACE_ARG3_TYPE.
18316 (usr_store_inferior_registers): Ditto.
18317 (linux_read_memory, linux_write_memory): Ditto.
18318 (linux_test_for_tracefork): Ditto.
18319
18320 * linux-arm-low.c: Remove redundant include of gdb_proc_service.h.
18321 Only include elf.h if gdb_proc_service.h didn't include linux/elf.h.
18322
18323 2010-01-21 Pedro Alves <pedro@codesourcery.com>
18324
18325 * proc-service.c (ps_lgetregs): Don't refetch registers from the
18326 target.
18327
18328 2010-01-21 Pedro Alves <pedro@codesourcery.com>
18329
18330 * spu-low.c (spu_fetch_registers, spu_store_registers): Change
18331 prototype to take a regcache. Adjust.
18332
18333 2010-01-20 Pedro Alves <pedro@codesourcery.com>
18334
18335 * regcache.h (struct thread_info): Forward declare.
18336 (struct regcache): New.
18337 (new_register_cache): Adjust prototype.
18338 (get_thread_regcache): Declare.
18339 (free_register_cache): Adjust prototype.
18340 (registers_to_string, registers_from_string): Ditto.
18341 (supply_register, supply_register_by_name, collect_register)
18342 (collect_register_as_string, collect_register_by_name): Ditto.
18343 * regcache.c (struct inferior_regcache_data): Delete.
18344 (get_regcache): Rename to ...
18345 (get_thread_regcache): ... this. Adjust. Switch inferior before
18346 fetching registers.
18347 (regcache_invalidate_one): Adjust.
18348 (regcache_invalidate): Fix prototype.
18349 (new_register_cache): Return the new register cache.
18350 (free_register_cache): Change prototype.
18351 (realloc_register_cache): Adjust.
18352 (registers_to_string): Change prototype to take a regcache. Adjust.
18353 (registers_from_string): Ditto.
18354 (register_data): Ditto.
18355 (supply_register): Ditto.
18356 (supply_register_by_name): Ditto.
18357 (collect_register): Ditto.
18358 (collect_register_as_string): Ditto.
18359 (collect_register_by_name): Ditto.
18360 * server.c (process_serial_event): Adjust.
18361 * linux-low.h (regset_fill_func, regset_store_func): Change
18362 prototype.
18363 (get_pc, set_pc, collect_ptrace_register, supply_ptrace_register):
18364 Change prototype.
18365 * linux-low.c (get_stop_pc): Adjust.
18366 (check_removed_breakpoint): Adjust.
18367 (linux_wait_for_event): Adjust.
18368 (linux_resume_one_lwp): Adjust.
18369 (fetch_register): Add regcache parameter. Adjust.
18370 (usr_store_inferior_registers): Ditto.
18371 (regsets_fetch_inferior_registers): Ditto.
18372 (regsets_store_inferior_registers): Ditto.
18373 (linux_fetch_registers, linux_store_registers): Ditto.
18374 * i387-fp.c (i387_cache_to_fsave): Change prototype to take a
18375 regcache. Adjust.
18376 (i387_fsave_to_cache, i387_cache_to_fxsave, i387_fxsave_to_cache):
18377 Ditto.
18378 * i387-fp.h (i387_cache_to_fsave, i387_fsave_to_cache): Change
18379 prototype to take a regcache.
18380 (i387_cache_to_fxsave, i387_fxsave_to_cache): Ditto.
18381 * remote-utils.c (convert_ascii_to_int, outreg)
18382 (prepare_resume_reply): Change prototype to take a regcache.
18383 Adjust.
18384 * target.h (struct target_ops) <fetch_registers, store_registers>:
18385 Change prototype to take a regcache.
18386 (fetch_inferior_registers, store_inferior_registers): Change
18387 prototype to take a regcache. Adjust.
18388 * proc-service.c (ps_lgetregs): Adjust.
18389 * linux-x86-low.c (x86_fill_gregset, x86_store_gregset)
18390 (x86_fill_fpregset, x86_store_fpregset, x86_fill_fpxregset)
18391 (x86_store_fpxregset, x86_get_pc, x86_set_pc): Change prototype to
18392 take a regcache. Adjust.
18393 * linux-arm-low.c (arm_fill_gregset, arm_store_gregset)
18394 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
18395 (arm_store_vfpregset, arm_get_pc, arm_set_pc):
18396 (arm_breakpoint_at): Change prototype to take a regcache. Adjust.
18397 * linux-cris-low.c (cris_get_pc, cris_set_pc)
18398 (cris_cannot_fetch_register):
18399 (cris_breakpoint_at): Change prototype to take a regcache.
18400 Adjust.
18401 * linux-crisv32-low.c (cris_get_pc, cris_set_pc,
18402 cris_reinsert_addr, cris_write_data_breakpoint): Change prototype
18403 to take a regcache. Adjust.
18404 (cris_breakpoint_at, cris_insert_point, cris_remove_point):
18405 Adjust.
18406 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Change prototype to
18407 take a regcache. Adjust.
18408 * linux-m68k-low.c (m68k_fill_gregset, m68k_store_gregset)
18409 (m68k_fill_fpregset, m68k_store_fpregset, m68k_get_pc,
18410 (m68k_set_pc): Change prototype to take a regcache. Adjust.
18411 * linux-mips-low.c (mips_get_pc):
18412 (mips_set_pc): Change prototype to take a regcache. Adjust.
18413 (mips_reinsert_addr): Adjust.
18414 (mips_collect_register): Change prototype to take a regcache.
18415 Adjust.
18416 (mips_supply_register):
18417 (mips_collect_register_32bit, mips_supply_register_32bit)
18418 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
18419 (mips_store_fpregset): Ditto.
18420 * linux-ppc-low.c (ppc_supply_ptrace_register)
18421 (ppc_supply_ptrace_register): Ditto.
18422 (parse_spufs_run): Adjust.
18423 (ppc_get_pc, ppc_set_pc, ppc_fill_gregset, ppc_fill_vsxregset)
18424 (ppc_store_vsxregset, ppc_fill_vrregset, ppc_store_vrregset)
18425 (ppc_fill_evrregset, ppc_store_evrregset): Change prototype to
18426 take a regcache. Adjust.
18427 * linux-s390-low.c (s390_collect_ptrace_register)
18428 (s390_supply_ptrace_register, s390_fill_gregset, s390_get_pc)
18429 (s390_set_pc): Change prototype to take a regcache. Adjust.
18430 (s390_arch_setup): Adjust.
18431 * linux-sh-low.c (sh_get_pc, sh_breakpoint_at)
18432 (sh_fill_gregset): Change prototype to take a regcache. Adjust.
18433 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
18434 (sparc_fill_gregset, sparc_store_gregset_from_stack)
18435 (sparc_store_gregset, sparc_get_pc): Change prototype to take a
18436 regcache. Adjust.
18437 (sparc_breakpoint_at): Adjust.
18438 * linux-xtensa-low.c (xtensa_fill_gregset):
18439 (xtensa_store_gregset):
18440 (xtensa_fill_xtregset, xtensa_store_xtregset, xtensa_get_pc)
18441 (xtensa_set_pc): Change prototype to take a regcache. Adjust.
18442 * nto-low.c (nto_fetch_registers, nto_store_registers): Change
18443 prototype to take a regcache. Adjust.
18444 * win32-arm-low.c (arm_fetch_inferior_register)
18445 (arm_store_inferior_register): Change prototype to take a
18446 regcache. Adjust.
18447 * win32-i386-low.c (i386_fetch_inferior_register)
18448 (i386_store_inferior_register): Change prototype to take a
18449 regcache. Adjust.
18450 * win32-low.c (child_fetch_inferior_registers)
18451 (child_store_inferior_registers): Change prototype to take a
18452 regcache. Adjust.
18453 (win32_wait): Adjust.
18454 (win32_fetch_inferior_registers): Change prototype to take a
18455 regcache. Adjust.
18456 (win32_store_inferior_registers): Adjust.
18457 * win32-low.h (struct win32_target_ops) <fetch_inferior_register,
18458 store_inferior_register>: Change prototype to take a regcache.
18459
18460 2010-01-20 Doug Evans <dje@google.com>
18461
18462 * linux-low.c (linux_create_inferior): Wrap use of __SIGRTMIN in
18463 #ifdef.
18464 (linux_wait_for_event1, linux_init_signals): Ditto.
18465 (W_STOPCODE): Provide definition if missing.
18466
18467 2010-01-13 Vladimir Prus <vladimir@codesourcery.com>
18468
18469 * linux-low.c (linux_core_of_thread): New.
18470 (compare_ints, show_process, list_threads): New.
18471 (linux_qxfer_osdata): Report threads and cores.
18472 (linux_target_op): Register linux_core_of_thread.
18473 * remote-utils.c (prepare_resume_reply): Report the core.
18474 (buffer_xml_printf): Support %d specifier.
18475 * server.c (handle_threads_qxfer_proper, handle_threads_qxfer):
18476 New.
18477 (handle_query): Handle qXfer:threads. Announce availability
18478 thereof.
18479 * target.h (struct target_ops): New field core_of_thread.
18480
18481 2010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
18482
18483 * Makefile.in (clean): Remove new generated files.
18484 (reg-s390.o, reg-s390.c): Remove rules.
18485 (reg-s390x.o, reg-s390x.c): Likewise.
18486 (s390-linux32.o, s390-linux32.c): Add rules.
18487 (s390-linux64.o, s390-linux64.c): Likewise.
18488 (s390x-linux64.o, s390x-linux64.c): Likewise.
18489 * configure.srv (s390*-*-linux*): Update srv_regobj and srv_xmlfiles.
18490 * linux-s390-low.c: Include <elf.h>.
18491 (HWCAP_S390_HIGH_GPRS): Define if undefined.
18492 (init_registers_s390): Remove prototype.
18493 (init_registers_s390x): Likewise.
18494 (init_registers_s390_linux32): Add prototype.
18495 (init_registers_s390_linux64): Likewise.
18496 (init_registers_s390x_linux64): Likewise.
18497 (s390_num_regs_3264): New define.
18498 (s390_regmap_3264): New global variable.
18499 (s390_cannot_fetch_register): Remove obsolete check.
18500 (s390_cannot_store_register): Likewise.
18501 (s390_collect_ptrace_register): Handle upper/lower register halves.
18502 (s390_supply_ptrace_register): Likewise.
18503 (s390_fill_gregset): Update to register number changes.
18504 (s390_get_hwcap): New routine.
18505 (s390_arch_setup): Detect 32-bit process running on 64-bit system.
18506 Install appropriate regmap and register set.
18507
18508 2010-01-01 Joel Brobecker <brobecker@adacore.com>
18509
18510 * server.c (gdbserver_version): Update copyright year to 2010.
18511 * gdbreplay.c (gdbreplay_version): Likewise.
18512
18513 2009-12-28 Doug Evans <dje@google.com>
18514
18515 * linux-low.c: Delete inclusion of ansidecl.h, elf/common.h,
18516 elf/external.h. Include <elf.h> instead but only if necessary.
18517
18518 2009-12-28 Pedro Alves <pedro@codesourcery.com>
18519
18520 * linux-low.c (linux_remove_process): Remove `detaching'
18521 parameter. Don't release/detach from thread_db here.
18522 (linux_kill): Release/detach from thread_db here, ...
18523 (linux_detach): ... and here, before actually detaching.
18524 (linux_wait_1): ... and here, when a process exits.
18525 * thread-db.c (any_thread_of): New.
18526 (thread_db_free): Switch the current inferior to a thread of the
18527 passed in process.
18528
18529 2009-12-21 Doug Evans <dje@google.com>
18530
18531 * linux-x86-low.c: Delete outdated comment about Elf32_Phdr.
18532
18533 * linux-low.c (kill_lwp): Use __NR_tkill instead of SYS_tkill.
18534 Move definition of tkill_failed to ifdef __NR_tkill to avoid gcc
18535 warning ifndef __NR_tkill. Move setting of errno there too.
18536 Delete unnecessary resetting of errno after syscall.
18537 Minor comment changes to match gdb/linux-nat.c:kill_lwp.
18538
18539 * configure.ac: Check for dladdr.
18540 * config.in: Regenerate.
18541 * configure: Regenerate.
18542 * thread-db.c (dladdr_to_soname): Only define ifdef HAVE_DLADDR.
18543 (try_thread_db_load): Update.
18544
18545 * linux-low.c (my_waitpid): Delete unnecessary prototype.
18546
18547 2009-12-18 Doug Evans <dje@google.com>
18548
18549 * event-loop.c: Include unistd.h if it exists.
18550
18551 * linux-low.c (my_waitpid): Move definition away from being in
18552 between linux_tracefork_child/linux_test_for_tracefork.
18553
18554 * gdb_proc_service.h (psaddr_t): Fix type.
18555 * thread-db.c (thread_db_info.td_thr_tls_get_addr_p): Fix
18556 signature to match glibc.
18557
18558 2009-12-16 Doug Evans <dje@google.com>
18559
18560 * linux-low.c (linux_read_memory): Fix argument to read.
18561
18562 2009-11-26 Pedro Alves <pedro@codesourcery.com>
18563
18564 * win32-low.c (get_child_debug_event): On EXIT_THREAD_DEBUG_EVENT
18565 events, don't leave current_inferior pointing at null.
18566
18567 2009-11-26 Pedro Alves <pedro@codesourcery.com>
18568
18569 * win32-low.c (LOG): Delete.
18570 (OUTMSG): Output to stderr.
18571 (OUTMSG2): Conditionalize on `debug_threads' variable, instead of
18572 on compile time LOG macro.
18573 (win32_wait): Fix debug output.
18574
18575 2009-11-26 Pedro Alves <pedro@codesourcery.com>
18576
18577 * win32-low.c (win32_add_one_solib): If the dll name is
18578 "ntdll.dll", prepend the system directory to the dll path.
18579
18580 2009-11-17 Daniel Jacobowitz <dan@codesourcery.com>
18581
18582 * m68k-tdep.c (m68k_gdbarch_init): Reuse previous initialization.
18583
18584 2009-11-17 Nathan Sidwell <nathan@codesourcery.com>
18585 Vladimir Prus <vladimir@codesourcery.com>
18586
18587 * Makefile.in (reg-cf.o, reg-cf.c): New targets.
18588 * configure.ac: Check for __mcoldfire__ and set
18589 gdb_cv_m68k_is_coldfire.
18590 * configure.srv: Use gdb_cv_m68k_is_coldfire to select between
18591 reg-cf.o and reg-m68k.o.
18592 * configure: Regenerated.
18593
18594 2009-11-16 Pedro Alves <pedro@codesourcery.com>
18595
18596 * linux-low.c (linux_remove_process): Add `detaching' parameter.
18597 Pass it to thread_db_free.
18598 (linux_kill, linux_detach, linux_wait_1): Adjust to pass the
18599 proper `detaching' argument to linux_remove_process.
18600 * linux-low.h (thread_db_free): Add `detaching' parameter.
18601 * thread-db.c (thread_db_init): Pass false as `detaching' argument
18602 to thread_db_free.
18603 (thread_db_free): Add `detaching' parameter. Only
18604 call td_ta_clear_event if detaching from process.
18605
18606 2009-11-12 Maxim Kuvyrkov <maxim@codesourcery.com>
18607
18608 * thread-db.c (thread_db_free): Fix typo.
18609
18610 2009-11-11 Paul Pluzhnikov <ppluzhnikov@google.com>
18611
18612 PR gdb/10838
18613 * thread-db.c (thread_db_free): Call td_ta_clear_event.
18614
18615 2009-11-03 Nathan Sidwell <nathan@codesourcery.com>
18616
18617 * configure.ac (i[34567]86-*): Check if we're targetting x86-64
18618 with an i686 compiler.
18619 * configure.srv (i[34567]86-*-linux*): Pull in x86-64 handling if
18620 needed.
18621 * configure: Rebuilt.
18622
18623 2009-10-29 Sandra Loosemore <sandra@codesourcery.com>
18624
18625 PR gdb/10783
18626
18627 * server.c (handle_search_memory_1): Correct read_addr initialization
18628 in loop for searching subsequent chunks.
18629
18630 2009-10-29 Paul Pluzhnikov <ppluzhnikov@google.com>
18631
18632 * configure.ac: New --with-libthread-db option.
18633 * thread-db.c: Allow direct dependence on libthread_db.
18634 (thread_db_free): Adjust.
18635 * config.in: Regenerate.
18636 * configure: Likewise.
18637
18638 2009-10-28 Paul Pluzhnikov <ppluzhnikov@google.com>
18639
18640 PR gdb/10757
18641 * thread-db.c (attach_thread): New function.
18642 (maybe_attach_thread): Return success/failure.
18643 (find_new_threads_callback): Adjust.
18644 (thread_db_find_new_threads): Loop until no new threads.
18645
18646 2009-10-13 Pedro Alves <pedro@codesourcery.com>
18647
18648 * proc-service.c (ps_lgetregs): Formatting.
18649
18650 2009-10-08 Paul Pluzhnikov <ppluzhnikov@google.com>
18651
18652 * acinclude.m4: (SRV_CHECK_THREAD_DB, SRV_CHECK_TLS_GET_ADDR): Remove.
18653 * configure.ac: Adjust.
18654 * linux-low.h (struct process_info_private): Move members to struct
18655 thread_db.
18656 (thread_db_free, thread_db_handle_monitor_command): New prototype.
18657 * linux-low.c (linux_remove_process): Adjust.
18658 (linux_wait_for_event_1, linux_look_up_symbols): Likewise.
18659 * server.c (handle_query): Move code ...
18660 (handle_monitor_command): ... here. New function.
18661 * target.h (struct target_ops): New member.
18662 * thread-db.c (struct thread_db): New.
18663 (libthread_db_search_path): New variable.
18664 (thread_db_create_event, thread_db_enable_reporting)
18665 (find_one_thread, maybe_attach_thread, find_new_threads_callback)
18666 (thread_db_find_new_threads, (thread_db_get_tls_address): Adjust.
18667 (try_thread_db_load_1, dladdr_to_soname): New functions.
18668 (try_thread_db_load, thread_db_load_search): New functions.
18669 (thread_db_init): Search for libthread_db.
18670 (thread_db_free): New function.
18671 (thread_db_handle_monitor_command): Likewise.
18672 * config.in: Regenerate.
18673 * configure: Regenerate.
18674
18675 2009-09-27 Ulrich Weigand <uweigand@de.ibm.com>
18676
18677 * spu-low.c (spu_kill): Wait for inferior to terminate.
18678 Call clear_inferiors.
18679 (spu_detach): Call clear_inferiors.
18680
18681 2009-08-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
18682
18683 * aclocal.m4: Regenerate.
18684 * config.in: Likewise.
18685 * configure: Likewise.
18686
18687 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
18688
18689 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Define.
18690 (parse_spufs_run): New function.
18691 (ppc_get_pc, ppc_set_pc): Detect and handle SPU PC.
18692 (ppc_breakpoint_at): Handle SPU breakpoints.
18693
18694 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
18695
18696 * linux-low.c: Include <sys/stat.h> and <sys/vfs.h>.
18697 (SPUFS_MAGIC): Define.
18698 (spu_enumerate_spu_ids): New function.
18699 (linux_qxfer_spu): New function.
18700 (linux_target_ops): Install linux_qxfer_spu.
18701
18702 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
18703
18704 * configure.srv (powerpc*-*-linux*): Add powerpc-cell32l.o
18705 and powerpc-cell64l.o to srv_regobj. Add rs6000/powerpc-cell32l.xml
18706 and rs6000/powerpc-cell64l.xml to srv_xmlfiles.
18707 * Makefile.in (powerpc-cell32l.o, powerpc-cell32l.c): New rules.
18708 (powerpc-cell64l.o, powerpc-cell64l.c): Likewise.
18709 (clean): Handle powerpc-cell32l.c and powerpc-cell64l.c.
18710 * linux-ppc-low.c (PPC_FEATURE_CELL): Define.
18711 (init_registers_powerpc_cell32l): Add prototype.
18712 (init_registers_powerpc_cell64l): Likewise.
18713 (ppc_arch_setup): Detect Cell/B.E. architecture.
18714
18715 2009-07-30 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
18716
18717 * Makefile.in (datarootdir): New variable.
18718
18719 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
18720
18721 * linux-low.c (linux_write_memory): Update debugging output.
18722 * Makefile.in (clean): Add new descriptions.
18723 (arm-with-vfpv2.o, arm-with-vfpv2.c, arm-with-vfpv3.o)
18724 (arm-with-vfpv3.c, arm-with-neon.o, arm-with-neon.c): New rules.
18725 * configure.srv: Add new files for arm*-*-linux*.
18726 * linux-arm-low.c: Add new declarations.
18727 (PTRACE_GETVFPREGS, PTRACE_SETVFPREGS): Define if undefined.
18728 (arm_hwcap, HWCAP_VFP, HWCAP_IWMMXT, HWCAP_NEON, HWCAP_VFPv3)
18729 (HWCAP_VFPv3D16): New.
18730 (arm_fill_wmmxregset, arm_store_wmmxregset): Check HWCAP_IWMMXT
18731 instead of __IWMMXT__.
18732 (arm_fill_vfpregset, arm_store_vfpregset, arm_get_hwcap)
18733 (arm_arch_setup): New.
18734 (target_regsets): Remove #ifdef. Add VFP regset.
18735 (the_low_target): Use arm_arch_setup.
18736
18737 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
18738
18739 * linux-low.c (linux_kill_one_lwp): Adjust kernel workaround to skip
18740 the main thread again.
18741
18742 2009-07-06 Aleksandar Ristovski <aristovski@qnx.com>
18743
18744 Adding Neutrino gdbserver.
18745 * configure: Regenerated.
18746 * configure.ac: Add case for srv_qnx and set LIBS accordingly.
18747 * configure.srv (i[34567]86-*-nto*): New target.
18748 * nto-low.c, nto-low.h, nto-x86-low.c: New files.
18749 * remote-utils.c [__QNX__]: Include sys/iomgr.h
18750 (nto_comctrl) [__QNX__]: New function.
18751 (enable_async_io, disable_async_io) [__QNX__]: Call nto_comctrl.
18752
18753 2009-07-05 Danny Backx <dannybackx@users.sourceforge.net>
18754
18755 * configure.srv (i[34567]86-*-mingw32ce*): Add i386-low.o to
18756 srv_tgtobj.
18757
18758 2009-07-04 Danny Backx <dannybackx@users.sourceforge.net>
18759 Pedro Alves <pedro@codesourcery.com>
18760
18761 * win32-i386-low.c (i386_get_thread_context): Handle systems that
18762 don't support CONTEXT_EXTENDED_REGISTERS.
18763 (i386_win32_breakpoint, i386_win32_breakpoint_len): New.
18764 (the_low_target): Install them.
18765 * win32-low.c (get_child_debug_event): Handle WaitForDebugEvent
18766 failing with ERROR_PIPE_NOT_CONNECTED.
18767
18768 2009-06-30 Doug Evans <dje@google.com>
18769 Pierre Muller <muller@ics.u-strasbg.fr>
18770
18771 Add h/w watchpoint support to x86-linux, win32-i386.
18772 * Makefile.in (SFILES): Add i386-low.c
18773 (i386_low_h): Define.
18774 (i386-low.o): Add dependencies.
18775 (linux-x86-low.o): Add i386-low.h dependency.
18776 (win32-i386-low.o): Ditto.
18777 * i386-low.c: New file.
18778 * i386-low.h: New file.
18779 * configure.srv (i[34567]86-*-cygwin*): Add i386-low.o to srv_tgtobj.
18780 (i[34567]86-*-linux*, i[34567]86-*-mingw*, x86_64-*-linux*): Ditto.
18781 * linux-low.c (linux_add_process): Initialize arch_private.
18782 (linux_remove_process): Free arch_private.
18783 (add_lwp): Initialize arch_private.
18784 (delete_lwp): Free arch_private.
18785 (linux_resume_one_lwp): Call the_low_target.prepare_to_resume if
18786 provided.
18787 * linux-low.h (process_info_private): New member arch_private.
18788 (lwp_info): New member arch_private.
18789 (linux_target_ops): New members new_process, new_thread,
18790 prepare_to_resume.
18791 (ptid_of): New macro.
18792 * linux-x86-low.c: Include stddef.h, i386-low.h.
18793 (arch_process_info): New struct.
18794 (arch_lwp_info): New struct.
18795 (x86_linux_dr_get, x86_linux_dr_set): New functions.
18796 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
18797 (i386_dr_low_get_status): New function.
18798 (x86_insert_point, x86_remove_point): New functions.
18799 (x86_stopped_by_watchpoint): New function.
18800 (x86_stopped_data_address): New function.
18801 (x86_linux_new_process, x86_linux_new_thread): New functions.
18802 (x86_linux_prepare_to_resume): New function.
18803 (the_low_target): Add entries for insert_point, remove_point,
18804 stopped_by_watchpoint, stopped_data_address, new_process, new_thread,
18805 prepare_to_resume.
18806 * server.c (debug_hw_points): New global.
18807 (monitor_show_help): Document set debug-hw-points.
18808 (handle_query): Process "set debug-hw-points".
18809 * server.h (debug_hw_points): Declare.
18810 (paddress): Declare.
18811 * utils.c (NUMCELLS, CELLSIZE): New macros.
18812 (get_sell, xsnprintf, paddress): New functions.
18813 * win32-arm-low.c (the_low_target): Add entries for insert_point,
18814 remove_point, stopped_by_watchpoint, stopped_data_address.
18815 * win32-i386-low.c: Include i386-low.h.
18816 (debug_reg_state): Replaces dr.
18817 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
18818 (i386_dr_low_get_status): New function.
18819 (i386_insert_point, i386_remove_point): New functions.
18820 (i386_stopped_by_watchpoint): New function.
18821 (i386_stopped_data_address): New function.
18822 (i386_initial_stuff): Update.
18823 (get_thread_context,set_thread_context,i386_thread_added): Update.
18824 (the_low_target): Add entries for insert_point,
18825 remove_point, stopped_by_watchpoint, stopped_data_address.
18826 * win32-low.c (win32_insert_watchpoint): New function.
18827 (win32_remove_watchpoint): New function.
18828 (win32_stopped_by_watchpoint): New function.
18829 (win32_stopped_data_address): New function.
18830 (win32_target_ops): Add entries for insert_watchpoint,
18831 remove_watchpoint, stopped_by_watchpoint, stopped_data_address.
18832 * win32-low.h (win32_target_ops): New members insert_point,
18833 remove_point, stopped_by_watchpoint, stopped_data_address.
18834
18835 2009-06-25 Pedro Alves <pedro@codesourcery.com>
18836
18837 * server.c (process_serial_event): Re-return unsupported, not
18838 error, if the type isn't recognized. Re-allow supporting only
18839 insert or remove packets. Also call require_running for
18840 breakpoints. Add missing break statement to default case. Tidy.
18841 * target.h (struct target_ops): Rename insert_watchpoint to
18842 insert_point, and remove_watchpoint to remove_point.
18843
18844 * linux-low.h (struct linux_target_ops): Likewise.
18845 * linux-low.c (linux_insert_watchpoint): Rename to ...
18846 (linux_insert_point): ... this. Adjust.
18847 (linux_remove_watchpoint): Rename to ...
18848 (linux_remove_point): ... this. Adjust.
18849 (linux_target_ops): Adjust.
18850 * linux-crisv32-low.c (cris_insert_watchpoint): Rename to ...
18851 (cris_insert_point): ... this.
18852 (cris_remove_watchpoint): Rename to ...
18853 (cris_remove_point): ... this.
18854 (the_low_target): Adjust.
18855
18856 2009-06-24 Pierre Muller <muller@ics.u-strasbg.fr>
18857
18858 * server.c (handle_v_kill): Pass signal_pid to
18859 kill_inferior if multi_process is zero.
18860
18861 2009-06-23 Aleksandar Ristovski <aristovski@qnx.com>
18862
18863 * server.c (process_serial_event): Add support for Z0 and Z1 packet.
18864 * target.h (target_ops): Comment for *_watchpoint to make it clear
18865 the functions can get types '0' and '1'.
18866
18867 2009-06-22 Aleksandar Ristovski <aristovski@qnx.com>
18868
18869 * linux-low.c (usr_fetch_inferior_registers): Remove check for regno 0.
18870 * proc-service.c (ps_lgetregs): Pass -1 to fetch all registers.
18871 * regcache.c (get_regcache): Likewise.
18872 * spu-low.c (spu_fetch_registers): Remove 0 to -1 conversion.
18873 * win32-low.c (child_fetch_inferior_registers): Remove check for
18874 regno 0.
18875
18876 2009-06-19 Aleksandar Ristovski <aristovski@qnx.com>
18877 Pedro Alves <pedro@codesourcery.com>
18878
18879 * target.h (struct target_ops) <supports_multi_process>: New
18880 callback.
18881 (target_supports_multi_process): New.
18882 * server.c (handle_query): Even if GDB reports support, only
18883 enable multi-process if the target also supports it. Report
18884 multi-process support only if the target backend supports it.
18885 * linux-low.c (linux_supports_multi_process): New function.
18886 (linux_target_ops): Install it as target_supports_multi_process
18887 callback.
18888
18889 2009-05-24 Doug Evans <dje@google.com>
18890
18891 Global renaming of find_thread_pid to find_thread_ptid.
18892 * server.h (find_thread_ptid): Renamed from find_thread_pid.
18893 * inferiors.c (find_thread_ptid): Renamed from find_thread_pid.
18894 All callers updated.
18895
18896 * linux-low.c (handle_extended_wait): Use linux_resume_one_lwp
18897 to resume the newly created thread, don't call ptrace (PTRACE_CONT)
18898 directly.
18899
18900 * linux-low.c (get_stop_pc): Print pc if debug_threads.
18901 (check_removed_breakpoint, linux_wait_for_lwp): Ditto.
18902 (linux_resume_one_lwp): Ditto.
18903
18904 2009-05-23 Doug Evans <dje@google.com>
18905
18906 * linux-low.c (linux_resume_one_lwp): Change type of first arg
18907 from struct inferior_list_entry * to struct lwp_info *.
18908 All callers updated.
18909
18910 2009-05-13 Doug Evans <dje@google.com>
18911
18912 * linux-x86-low.c: Don't include assert.h.
18913 (x86_siginfo_fixup): Use fatal, not assert.
18914 (x86_arch_setup): Fix comment.
18915
18916 2009-05-12 Doug Evans <dje@google.com>
18917
18918 Biarch support for i386/amd64 gdbserver.
18919 * Makefile.in (SFILES): Remove linux-i386-low.c, linux-x86-64-low.c.
18920 Add linux-x86-low.c.
18921 (linux-i386-low.o, linux-x86-64-low.o): Delete.
18922 (linux-x86-low.o): Add.
18923 * linux-x86-64-low.c: Delete.
18924 * linux-i386-low.c: Delete.
18925 * linux-x86-low.c: New file.
18926 * configure.srv (i?86-linux srv_tgtobj): Replace linux-i386-low.o with
18927 linux-x86-low.o.
18928 (x86_64-linux srv_tgtobj): Replace linux-x86-64-low.o with
18929 linux-x86-low.o.
18930 (x86_64-linux srv_regobj): Add reg-i386-linux.o.
18931 * linux-low.c: Include ansidecl.h, elf/common.h, elf/external.h.
18932 (linux_child_pid_to_exec_file): New function.
18933 (elf_64_header_p, elf_64_file_p): New functions.
18934 (siginfo_fixup): New function.
18935 (linux_xfer_siginfo): New local inf_siginfo. Call siginfo_fixup to
18936 give target a chance to convert layout.
18937 * linux-low.h (linux_target_ops): New member siginfo_fixup.
18938 (linux_child_pid_to_exec_file, elf_64_file_p): Declare.
18939
18940 2009-05-07 Doug Evans <dje@google.com>
18941
18942 * linux-low.c (regsets_fetch_inferior_registers): Fix memory leak.
18943 (regsets_store_inferior_registers): Ditto.
18944
18945 2009-05-06 Pedro Alves <pedro@codesourcery.com>
18946
18947 PR server/10048
18948
18949 * linux-low.c (must_set_ptrace_flags): Delete.
18950 (linux_create_inferior): Set `lwp->must_set_ptrace_flags' instead
18951 of the global.
18952 (linux_attach_lwp_1): Don't set PTRACE_SETOPTIONS here. Set
18953 `lwp->must_set_ptrace_flags' instead.
18954 (linux_wait_for_event_1): Set ptrace options here.
18955 (linux_wait_1): ... not here.
18956
18957 2009-04-30 Doug Evans <dje@google.com>
18958
18959 * inferiors.c (started_inferior_callback): New function.
18960 (attached_inferior_callback): New function.
18961 (have_started_inferiors_p, have_attached_inferiors_p): New functions.
18962 * server.c (print_started_pid, print_attached_pid): New functions.
18963 (detach_or_kill_for_exit): New function.
18964 (main): Call it instead of for_each_inferior (kill_inferior_callback).
18965 * server.h (have_started_inferiors_p): Declare.
18966 (have_attached_inferiors_p): Declare.
18967
18968 * inferiors.c (remove_process): Fix memory leak, free process.
18969 * linux-low.c (linux_remove_process): New function.
18970 (linux_kill): Call it instead of remove_process.
18971 (linux_detach, linux_wait_1): Ditto.
18972
18973 2009-04-19 Danny Backx <dannybackx@users.sourceforge.net>
18974
18975 * configure.srv: Add x86 Windows CE target.
18976
18977 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
18978
18979 * inferiors.c (get_thread_process): Make global.
18980 * server.h (get_thread_process): Add prototype.
18981 * thread-db.c (find_one_thread): Use get_thread_process
18982 instead of current_process.
18983 (thread_db_get_tls_address): Do not crash if called when
18984 thread layer is not yet initialized.
18985
18986 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
18987
18988 * remote-utils.c (prepare_resume_reply): Null-terminate packet.
18989 * spu-low.c (current_tid): Rename to ...
18990 (current_ptid): ... this.
18991 (fetch_ppc_register, fetch_ppc_memory, store_ppc_memory,
18992 spu_proc_xfer_spu, spu_resume, spu_request_interrupt): Use
18993 ptid_get_lwp (current_ptid) instead of current_tid.
18994 (spu_kill, spu_detach, spu_join, spu_wait): Use pid argument
18995 instead of current_tid. Use find_process_pid to verify pid
18996 argument is valid. Pass proper argument to remove_process.
18997 (spu_thread_alive): Compare current_ptid instead of current_tid.
18998 (spu_resume): Likewise.
18999
19000 2009-04-02 Pedro Alves <pedro@codesourcery.com>
19001
19002 * linux-low.c (usr_store_inferior_registers): Declare local `pid'
19003 variable.
19004
19005 2009-04-01 Pedro Alves <pedro@codesourcery.com>
19006
19007 Implement the multiprocess extensions, and add linux multiprocess
19008 support.
19009
19010 * server.h (ULONGEST): Declare.
19011 (struct ptid, ptid_t): New.
19012 (minus_one_ptid, null_ptid): Declare.
19013 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
19014 (ptid_get_tid, ptid_equal, ptid_is_pid): Declare.
19015 (struct inferior_list_entry): Change `id' type from unsigned from
19016 to ptid_t.
19017 (struct sym_cache, struct breakpoint, struct
19018 process_info_private): Forward declare.
19019 (struct process_info): Declare.
19020 (current_process): Declare.
19021 (all_processes): Declare.
19022 (initialize_inferiors): Declare.
19023 (add_thread): Adjust to use ptid_t.
19024 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): Ditto.
19025 (add_process, remove_process, find_thread_pid): Declare.
19026 (find_inferior_id): Adjust to use ptid_t.
19027 (cont_thread, general_thread, step_thread): Change type to ptid_t.
19028 (multi_process): Declare.
19029 (push_event): Adjust to use ptid_t.
19030 (read_ptid, write_ptid): Declare.
19031 (prepare_resume_reply): Adjust to use ptid_t.
19032 (clear_symbol_cache): Declare.
19033 * inferiors.c (all_processes): New.
19034 (null_ptid, minus_one_ptid): New.
19035 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
19036 (ptid_get_tid, ptid_equal, ptid_is_pid): New.
19037 (add_thread): Change unsigned long to ptid. Remove gdb_id
19038 parameter. Adjust.
19039 (thread_id_to_gdb_id, thread_to_gdb_id): Change unsigned long to ptid.
19040 (gdb_id_to_thread): Rename to ...
19041 (find_thread_pid): ... this. Change unsigned long to ptid.
19042 (gdb_id_to_thread_id, find_inferior_id): Change unsigned long to ptid.
19043 (loaded_dll, pull_pid_from_list): Adjust.
19044 (add_process, remove_process, find_process_pid)
19045 (get_thread_process, current_process, initialize_inferiors): New.
19046 * target.h (struct thread_resume) <thread>: Change type to ptid_t.
19047 (struct target_waitstatus) <related_pid>: Ditto.
19048 (struct target_ops) <kill, detach>: Add `pid' argument. Change
19049 return type to int.
19050 (struct target_ops) <join>: Add `pid' argument.
19051 (struct target_ops) <thread_alive>: Change pid's type to ptid_t.
19052 (struct target_ops) <wait>: Add `ptid' field. Change return type
19053 to ptid.
19054 (kill_inferior, detach_inferior, join_inferior): Add `pid' argument.
19055 (mywait): Add `ptid' argument. Change return type to ptid_t.
19056 (target_pid_to_str): Declare.
19057 * target.c (set_desired_inferior): Adjust to use ptids.
19058 (mywait): Add new `ptid' argument. Adjust.
19059 (target_pid_to_str): New.
19060 * mem-break.h (free_all_breakpoints): Declare.
19061 * mem-break.c (breakpoints): Delelete.
19062 (set_breakpoint_at, delete_breakpoint, find_breakpoint_at)
19063 (check_mem_read, check_mem_write, delete_all_breakpoints): Adjust
19064 to use per-process breakpoint list.
19065 (free_all_breakpoints): New.
19066 * remote-utils.c (struct sym_cache) <name>: Drop `const'.
19067 (symbol_cache, all_symbols_looked_up): Delete.
19068 (hexchars): New.
19069 (ishex, unpack_varlen_hex, write_ptid, hex_or_minus_one,
19070 read_ptid): New.
19071 (prepare_resume_reply): Change ptid argument's type from unsigned
19072 long to ptid_t. Adjust. Implement W;process and X;process.
19073 (free_sym_cache, clear_symbol_cache): New.
19074 (look_up_one_symbol): Adjust to per-process symbol cache. *
19075 * server.c (cont_thread, general_thread, step_thread): Change type
19076 to ptid_t.
19077 (attached): Delete.
19078 (multi_process): New.
19079 (last_ptid): Change type to ptid_t.
19080 (struct vstop_notif) <ptid>: Change type to ptid_t.
19081 (queue_stop_reply, push_event): Change `ptid' argument's type to
19082 ptid_t.
19083 (discard_queued_stop_replies): Add `pid' argument.
19084 (start_inferior): Adjust to use ptids. Adjust to mywait interface
19085 changes. Don't reference the `attached' global.
19086 (attach_inferior): Adjust to mywait interface changes.
19087 (handle_query): Adjust to use ptids. Parse GDB's qSupported
19088 features. Handle and report "multiprocess+". Handle
19089 "qAttached:PID".
19090 (handle_v_cont): Adjust to use ptids. Adjust to mywait interface
19091 changes.
19092 (handle_v_kill): New.
19093 (handle_v_stopped): Adjust to use target_pid_to_str.
19094 (handle_v_requests): Allow multiple attaches and runs when
19095 multiprocess extensions are in effect. Handle "vKill".
19096 (myresume): Adjust to use ptids.
19097 (queue_stop_reply_callback): Add `arg' parameter. Handle it.
19098 (handle_status): Adjust to discard_queued_stop_replies interface
19099 change.
19100 (first_thread_of, kill_inferior_callback)
19101 (detach_or_kill_inferior_callback, join_inferiors_callback): New.
19102 (main): Call initialize_inferiors. Adjust to use ptids, killing
19103 and detaching from all inferiors. Handle multiprocess packet
19104 variants.
19105 * linux-low.h: Include gdb_proc_service.h.
19106 (struct process_info_private): New.
19107 (struct linux_target_ops) <pid_of>: Use ptid_get_pid.
19108 <lwpid_of>: Use ptid_get_lwp.
19109 (get_lwp_thread): Adjust.
19110 (struct lwp_info): Add `dead' member.
19111 (find_lwp_pid): Declare.
19112 * linux-low.c (thread_db_active): Delete.
19113 (new_inferior): Adjust comment.
19114 (inferior_pid): Delete.
19115 (linux_add_process): New.
19116 (handle_extended_wait): Adjust.
19117 (add_lwp): Change unsigned long to ptid.
19118 (linux_create_inferior): Add process to processes table. Adjust
19119 to use ptids. Don't set new_inferior here.
19120 (linux_attach_lwp): Rename to ...
19121 (linux_attach_lwp_1): ... this. Add `initial' argument. Handle
19122 it. Adjust to use ptids.
19123 (linux_attach_lwp): New.
19124 (linux_attach): Add process to processes table. Don't set
19125 new_inferior here.
19126 (struct counter): New.
19127 (second_thread_of_pid_p, last_thread_of_process_p): New.
19128 (linux_kill_one_lwp): Add `args' parameter. Handle it. Adjust to
19129 multiple processes.
19130 (linux_kill): Add `pid' argument. Handle it. Adjust to multiple
19131 processes. Remove process from process table.
19132 (linux_detach_one_lwp): Add `args' parameter. Handle it. Adjust
19133 to multiple processes.
19134 (any_thread_of): New.
19135 (linux_detach): Add `pid' argument, and handle it. Remove process
19136 from processes table.
19137 (linux_join): Add `pid' argument. Handle it.
19138 (linux_thread_alive): Change unsighed long argument to ptid_t.
19139 Consider dead lwps as not being alive.
19140 (status_pending_p): Rename `dummy' argument to `arg'. Filter out
19141 threads we're not interested in.
19142 (same_lwp, find_lwp_pid): New.
19143 (linux_wait_for_lwp): Change `pid' argument's type from int to
19144 ptid_t. Adjust.
19145 (linux_wait_for_event): Rename to ...
19146 (linux_wait_for_event_1): ... this. Change `pid' argument's type
19147 from int to ptid_t. Adjust.
19148 (linux_wait_for_event): New.
19149 (linux_wait_1): Add `ptid' argument. Change return type to
19150 ptid_t. Adjust. Use last_thread_of_process_p. Remove processes
19151 that exit from the process table.
19152 (linux_wait): Add `ptid' argument. Change return type to ptid_t.
19153 Adjust.
19154 (mark_lwp_dead): New.
19155 (wait_for_sigstop): Adjust to use ptids. If a process exits while
19156 stopping all threads, mark its main lwp as dead.
19157 (linux_set_resume_request, linux_resume_one_thread): Adjust to use
19158 ptids.
19159 (fetch_register, usr_store_inferior_registers)
19160 (regsets_fetch_inferior_registers)
19161 (regsets_store_inferior_registers, linux_read_memory)
19162 (linux_write_memory): Inline `inferior_pid'.
19163 (linux_look_up_symbols): Adjust to use per-process
19164 `thread_db_active'.
19165 (linux_request_interrupt): Adjust to use ptids.
19166 (linux_read_auxv): Inline `inferior_pid'.
19167 (initialize_low): Don't reference thread_db_active.
19168 * gdb_proc_service.h (struct ps_prochandle) <pid>: Remove.
19169 * proc-service.c (ps_lgetregs): Use find_lwp_pid.
19170 (ps_getpid): Return the pid of the current inferior.
19171 * thread-db.c (proc_handle, thread_agent): Delete.
19172 (thread_db_create_event, thread_db_enable_reporting): Adjust to
19173 per-process data.
19174 (find_one_thread): Change argument type to ptid_t. Adjust to
19175 per-process data.
19176 (maybe_attach_thread): Adjust to per-process data and ptids.
19177 (thread_db_find_new_threads): Ditto.
19178 (thread_db_init): Ditto.
19179 * spu-low.c (spu_create_inferior, spu_attach): Add process to
19180 processes table. Adjust to use ptids.
19181 (spu_kill, spu_detach): Adjust interface. Remove process from
19182 processes table.
19183 (spu_join, spu_thread_alive): Adjust interface.
19184 (spu_wait): Adjust interface. Remove process from processes
19185 table. Adjust to use ptids.
19186 * win32-low.c (current_inferior_tid): Delete.
19187 (current_inferior_ptid): New.
19188 (debug_event_ptid): New.
19189 (thread_rec): Take a ptid. Adjust.
19190 (child_add_thread): Add `pid' argument. Adjust to use ptids.
19191 (child_delete_thread): Ditto.
19192 (do_initial_child_stuff): Add `attached' argument. Add process to
19193 processes table.
19194 (child_fetch_inferior_registers, child_store_inferior_registers):
19195 Adjust.
19196 (win32_create_inferior): Pass 0 to do_initial_child_stuff.
19197 (win32_attach): Pass 1 to do_initial_child_stuff.
19198 (win32_kill): Adjust interface. Remove process from processes
19199 table.
19200 (win32_detach): Ditto.
19201 (win32_join): Adjust interface.
19202 (win32_thread_alive): Take a ptid.
19203 (win32_resume): Adjust to use ptids.
19204 (get_child_debug_event): Ditto.
19205 (win32_wait): Adjust interface. Remove exiting process from
19206 processes table.
19207
19208 2009-04-01 Pedro Alves <pedro@codesourcery.com>
19209
19210 Non-stop mode support.
19211
19212 * server.h (non_stop): Declare.
19213 (gdb_client_data, handler_func): Declare.
19214 (delete_file_handler, add_file_handler, start_event_loop):
19215 Declare.
19216 (handle_serial_event, handle_target_event, push_event)
19217 (putpkt_notif): Declare.
19218 * target.h (enum resume_kind): New.
19219 (struct thread_resume): Replace `step' field by `kind' field.
19220 (TARGET_WNOHANG): Define.
19221 (struct target_ops) <wait>: Add `options' argument.
19222 <supports_non_stop, async, start_non_stop>: New fields.
19223 (target_supports_non_stop, target_async): New.
19224 (start_non_stop): Declare.
19225 (mywait): Add `options' argument.
19226 * target.c (mywait): Add `options' argument. Print child exit
19227 notifications here.
19228 (start_non_stop): New.
19229 * server.c (non_stop, own_buf, mem_buf): New globals.
19230 (struct vstop_notif): New.
19231 (notif_queue): New global.
19232 (queue_stop_reply, push_event, discard_queued_stop_replies)
19233 (send_next_stop_reply): New.
19234 (start_inferior): Adjust to use resume_kind. Adjust to mywait
19235 interface changes.
19236 (attach_inferior): In non-stop mode, don't wait for the target
19237 here.
19238 (handle_general_set): Handle QNonStop.
19239 (handle_query): When handling qC, return the current general
19240 thread, instead of the first thread of the list.
19241 (handle_query): If the backend supports non-stop mode, include
19242 QNonStop+ in the qSupported query response.
19243 (handle_v_cont): Adjust to use resume_kind. Handle resume_stop
19244 and non-stop mode.
19245 (handle_v_attach, handle_v_run): Handle non-stop mode.
19246 (handle_v_stopped): New.
19247 (handle_v_requests): Report support for vCont;t. Handle vStopped.
19248 (myresume): Adjust to use resume_kind. Handle non-stop.
19249 (queue_stop_reply_callback): New.
19250 (handle_status): Handle non-stop mode.
19251 (main): Clear non_stop flag on reconnection. Use the event-loop.
19252 Refactor serial protocol handling from here ...
19253 (process_serial_event): ... to this new function. When GDB
19254 selects any thread, select one here. In non-stop mode, wait until
19255 GDB acks all pending events before exiting.
19256 (handle_serial_event, handle_target_event): New.
19257 * remote-utils.c (remote_open): Install remote_desc in the event
19258 loop.
19259 (remote_close): Remove remote_desc from the event loop.
19260 (putpkt_binary): Rename to...
19261 (putpkt_binary_1): ... this. Add `is_notic' argument. Handle it.
19262 (putpkt_binary): New as wrapper around putpkt_binary_1.
19263 (putpkt_notif): New.
19264 (prepare_resume_reply): In non-stop mode, don't change the
19265 general_thread.
19266 * event-loop.c: New.
19267 * Makefile.in (OBJ): Add event-loop.o.
19268 (event-loop.o): New rule.
19269
19270 * linux-low.h (pid_of): Moved here.
19271 (lwpid_of): New.
19272 (get_lwp_thread): Use lwpid_of.
19273 (struct lwp_info): Delete `lwpid' field. Add `suspended' field.
19274 * linux-low.c (pid_of): Delete.
19275 (inferior_pid): Use lwpid_of.
19276 (linux_event_pipe): New.
19277 (target_is_async_p): New.
19278 (delete_lwp): New.
19279 (handle_extended_wait): Use lwpid_of.
19280 (add_lwp): Don't set lwpid field.
19281 (linux_attach_lwp): Adjust debug output. Use lwpid_of.
19282 (linux_kill_one_lwp): If killing a running lwp, stop it first.
19283 Use lwpid_of. Adjust to linux_wait_for_event interface changes.
19284 (linux_detach_one_lwp): If detaching from a running lwp, stop it
19285 first. Adjust to linux_wait_for_event interface changes. Use
19286 lwpid_of.
19287 (linux_detach): Don't delete the main lwp here.
19288 (linux_join): Use my_waitpid. Avoid signal_pid. Use lwpid_of.
19289 (status_pending_p): Don't consider explicitly suspended lwps.
19290 (linux_wait_for_lwp): Take an integer pid instead of a lwp_info
19291 pointer. Add OPTIONS argument. Change return type to int. Use
19292 my_waitpid instead of sleeping. Handle WNOHANG. Use lwpid_of.
19293 (linux_wait_for_event): Take an integer pid instead of a lwp_info
19294 pointer. Add status pointer argument. Return a pid instead of a
19295 status. Use lwpid_of. Adjust to linux_wait_for_lwp interface
19296 changes. In non-stop mode, don't switch to a random thread.
19297 (linux_wait): Rename to...
19298 (linux_wait_1): ... this. Add target_options argument, and handle
19299 it. Adjust to use resume_kind. Use lwpid_of. In non-stop mode,
19300 don't handle the continue thread. Handle TARGET_WNOHANG. Merge
19301 clean exit and signal exit code. Don't stop all threads in
19302 non-stop mode. In all-stop mode, only stop all threads when
19303 reporting a stop to GDB. Handle explicit thread stop requests.
19304 (async_file_flush, async_file_mark): New.
19305 (linux_wait): New.
19306 (send_sigstop): Use lwpid_of.
19307 (wait_for_sigstop): Use lwpid_of. Adjust to linux_wait_for_event
19308 interface changes. In non-stop mode, don't switch to a random
19309 thread.
19310 (linux_resume_one_lwp): Use lwpid_of.
19311 (linux_continue_one_thread, linux_queue_one_thread): Merge into ...
19312 (linux_resume_one_thread): ... this. Handle resume_stop. In
19313 non-stop mode, don't look for pending flag in all threads.
19314 (resume_status_pending_p): Don't consider explicitly suspended
19315 threads.
19316 (my_waitpid): Reimplement. Emulate __WALL.
19317 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
19318 Use lwpid_of.
19319 (sigchld_handler, linux_supports_non_stop, linux_async)
19320 (linux_start_non_stop): New.
19321 (linux_target_ops): Register linux_supports_non_stop, linux_async
19322 and linux_start_non_stop.
19323 (initialize_low): Install SIGCHLD handler.
19324 * thread-db.c (thread_db_create_event, find_one_thread)
19325 (thread_db_get_tls_address): Use lwpid_of.
19326 * win32-low.c (win32_detach): Adjust to use resume_kind.
19327 (win32_wait): Add `options' argument.
19328 * spu-low.c (spu_resume): Adjust to use resume_kind.
19329 (spu_wait): Add `options' argument.
19330
19331 2009-04-01 Pedro Alves <pedro@codesourcery.com>
19332
19333 Decouple target code from remote protocol.
19334
19335 * target.h (enum target_waitkind): New.
19336 (struct target_waitstatus): New.
19337 (struct target_ops) <wait>: Return an unsigned long. Take a
19338 target_waitstatus pointer instead of a char pointer.
19339 (mywait): Likewise.
19340 * target.c (mywait): Change prototype to return an unsigned long.
19341 Take a target_waitstatus pointer instead of a char pointer. Adjust.
19342 * server.h (thread_from_wait, old_thread_from_wait): Delete
19343 declarations.
19344 (prepare_resume_reply): Change prototype to take a
19345 target_waitstatus.
19346 * server.c (thread_from_wait, old_thread_from_wait): Delete.
19347 (last_status, last_ptid): New.
19348 (start_inferior): Remove "statusptr" argument. Adjust. Return a
19349 pid instead of a signal.
19350 (attach_inferior): Remove "status" and "signal" parameters.
19351 Adjust.
19352 (handle_query): For qGetTLSAddr, parse the thread id with strtol,
19353 not as an address.
19354 (handle_v_cont, handle_v_attach, handle_v_run, handle_v_kill)
19355 (handle_v_requests, myresume): Remove "status" and "signal"
19356 parameters. Adjust.
19357 (handle_status): New.
19358 (main): Delete local `status'. Adjust.
19359 * remote-utils.c: Include target.h.
19360 (prepare_resume_reply): Change prototype to take a
19361 target_waitstatus. Adjust.
19362
19363 * linux-low.c (linux_wait): Adjust to new target_ops->wait
19364 interface.
19365 * spu-low.c (spu_wait): Adjust.
19366 * win32-low.c (enum target_waitkind, struct target_waitstatus):
19367 Delete.
19368 (win32_wait): Adjust.
19369
19370 2009-04-01 Pedro Alves <pedro@codesourcery.com>
19371
19372 * target.h (struct thread_resume): Delete leave_stopped member.
19373 (struct target_ops): Add a `n' argument to the `resume' callback.
19374 * server.c (start_inferior): Adjust.
19375 (handle_v_cont, myresume): Adjust.
19376 * linux-low.c (check_removed_breakpoint): Adjust to resume
19377 interface change, and to removed leave_stopped field.
19378 (resume_ptr): Delete.
19379 (struct thread_resume_array): New.
19380 (linux_set_resume_request): Add new `arg' parameter. Adjust to
19381 resume interface change.
19382 (linux_continue_one_thread, linux_queue_one_thread)
19383 (resume_status_pending_p): Check if the resume field is NULL
19384 instead of checking the leave_stopped member.
19385 (linux_resume): Adjust to the target resume interface change.
19386 * spu-low.c (spu_resume): Adjust to the target resume interface
19387 change.
19388 * win32-low.c (win32_detach, win32_resume): Ditto.
19389
19390 2009-04-01 Pedro Alves <pedro@codesourcery.com>
19391
19392 * linux-low.c (linux_wait_for_event): Don't clear the `stepping'
19393 flag.
19394 (wait_for_sigstop): Don't leave a finished single-step SIGTRAP
19395 pending.
19396 (linux_continue_one_thread): Only preserve the stepping flag if
19397 there's a pending breakpoint.
19398
19399 2009-03-31 Pedro Alves <pedro@codesourcery.com>
19400
19401 * server.c (main): After the inferior having exited, call
19402 remote_close before exiting gdbserver.
19403
19404 2009-03-25 Thiago Jung Bauermann <bauerman@br.ibm.com>
19405
19406 Fix size of FPSCR in Power 7 processors.
19407 * linux-ppc-low.c (PPC_FEATURE_ARCH_2_05): Remove #define.
19408 (PPC_FEATURE_HAS_DFP): New #define.
19409 (ppc_arch_setup): Check for DFP feature instead of ISA 2.05 to decide on
19410 size of the FPSCR.
19411
19412 2009-03-23 Pedro Alves <pedro@codesourcery.com>
19413
19414 * server.c (handle_query) Whitespace and formatting.
19415
19416 2009-03-22 Pedro Alves <pedro@codesourcery.com>
19417
19418 * i387-fp.c, linux-arm-low.c, linux-cris-low.c,
19419 linux-crisv32-low.c, linux-i386-low.c, linux-low.c,
19420 linux-mips-low.c, linux-s390-low.c, linux-sparc-low.c,
19421 linux-x86-64-low.c, linux-xtensa-low.c, proc-service.c,
19422 regcache.c, remote-utils.c, server.c, spu-low.c, target.h,
19423 thread-db.c, win32-low.c, xtensa-xtregs.c, gdbreplay.c,
19424 Makefile.in, configure.ac: Fix whitespace throughout.
19425 * configure: Regenerate.
19426
19427 2009-03-22 Pedro Alves <pedro@codesourcery.com>
19428
19429 * inferiors.c (find_inferior): Make it safe for the callback
19430 function to delete the currently iterated inferior.
19431
19432 2009-03-22 Pedro Alves <pedro@codesourcery.com>
19433
19434 * Makefile.in (linuw_low_h): Move higher.
19435 (thread-db.o): Depend on $(linux_low_h).
19436
19437 2009-03-17 Pedro Alves <pedro@codesourcery.com>
19438
19439 Rename "process" to "lwp" throughout.
19440
19441 * linux-low.c (all_processes): Rename to...
19442 (all_lwps): ... this.
19443 (inferior_pid, handle_extended_wait, get_stop_pc): Adjust.
19444 (add_process): Rename to ...
19445 (add_lwp): ... this. Adjust.
19446 (linux_create_inferior): Adjust.
19447 (linux_attach_lwp): Adjust.
19448 (linux_attach): Adjust.
19449 (linux_kill_one_process): Rename to ...
19450 (linux_kill_one_lwp): ... this. Adjust.
19451 (linux_kill): Adjust.
19452 (linux_detach_one_process): Rename to ...
19453 (linux_detach_one_lwp): ... this. Adjust.
19454 (linux_detach): Adjust.
19455 (check_removed_breakpoint): Adjust.
19456 (status_pending_p): Adjust.
19457 (linux_wait_for_process): Rename to ...
19458 (linux_wait_for_lwp): ... this. Adjust.
19459 (linux_wait_for_event): Adjust.
19460 (send_sigstop): Adjust.
19461 (wait_for_sigstop): Adjust.
19462 (stop_all_processes): Rename to ...
19463 (stop_all_lwps): ... this.
19464 (linux_resume_one_process): Rename to ...
19465 (linux_resume_one_lwp): ... this. Adjust.
19466 (linux_set_resume_request, linux_continue_one_thread)
19467 (linux_queue_one_thread, resume_status_pending_p)
19468 (usr_store_inferior_registers, regsets_store_inferior_registers)
19469 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
19470 Adjust.
19471 * linux-low.h (get_process): Rename to ...
19472 (get_lwp): ... this. Adjust.
19473 (get_thread_process): Rename to ...
19474 (get_thread_lwp): ... this. Adjust.
19475 (get_process_thread): Rename to ...
19476 (get_lwp_thread): ... this. Adjust.
19477 (struct process_info): Rename to ...
19478 (struct lwp_info): ... this.
19479 (all_processes): Rename to ...
19480 (all_lwps): ... this.
19481 * proc-service.c (ps_lgetregs): Adjust.
19482 * thread-db.c (thread_db_create_event, find_one_thread)
19483 (maybe_attach_thread, thread_db_get_tls_address): Adjust.
19484
19485 2009-03-14 Pedro Alves <pedro@codesourcery.com>
19486
19487 * server.c (handle_query): Handle "qAttached".
19488
19489 2009-03-13 Nathan Sidwell <nathan@codesourcery.com>
19490
19491 * Makefile.in, hostio-errno.c, errno.c, xtensa-xtregs.c: Change to
19492 GPLv3, update license URL.
19493
19494 2009-03-01 Doug Evans <dje@google.com>
19495
19496 * Makefile.in (INCLUDE_CFLAGS): Add -I$(srcdir)/../common.
19497 (server_h): Add gdb_signals.h.
19498 (signals.o): Update.
19499 * server.h (target_signal_from_host,target_signal_to_host_p)
19500 (target_signal_to_host,target_signal_to_name): Moved to gdb_signals.h.
19501
19502 2009-02-14 Pierre Muller <muller@ics.u-strasbg.fr>
19503
19504 * remote-utils.c (getpkt): Also generate remote-debug
19505 information if noack_mode is set.
19506
19507 2009-02-06 Pedro Alves <pedro@codesourcery.com>
19508
19509 * server.c (handle_query): Report qXfer:siginfo:read and
19510 qXfer:siginfo:write as supported and handle them.
19511 * target.h (struct target_ops) <qxfer_siginfo>: New field.
19512 * linux-low.c (linux_xfer_siginfo): New.
19513 (linux_target_ops): Set it.
19514
19515 2009-01-26 Pedro Alves <pedro@codesourcery.com>
19516
19517 * server.c (gdbserver_usage): Mention --remote-debug.
19518 (main): Accept '--remote-debug' switch.
19519
19520 2009-01-18 Doug Evans <dje@google.com>
19521
19522 * regcache.c (new_register_cache): No need to check result of xcalloc.
19523 * server.c (handle_search_memory): Back out calls to xmalloc,
19524 result is checked and error is returned to user upon failure.
19525 (handle_query): Ditto. Add more checks for result of malloc.
19526 (handle_v_cont): Check result of malloc, report error back to
19527 user upon failure.
19528 (handle_v_run): Ditto. Call freeargv.
19529 * server.h (freeargv): Declare.
19530 * utils.c (freeargv): New fn.
19531
19532 2009-01-15 Doug Evans <dje@google.com>
19533
19534 * gdbreplay.c (perror_with_name): Make arg const char *.
19535 * server.h (target_signal_to_name): Make return type const char *.
19536 * thread-db.c (thread_db_err_str): Make return type const char *.
19537 * utils.c (perror_with_name): Make arg const char *.
19538
19539 2009-01-14 Pedro Alves <pedro@codesourcery.com>
19540
19541 * win32-low.c (get_child_debug_event): Issue a final DBG_CONTINUE
19542 when handling a EXIT_PROCESS_DEBUG_EVENT.
19543
19544 2009-01-06 Joel Brobecker <brobecker@adacore.com>
19545
19546 * gdbreplay.c (gdbreplay_version): Update copyright year.
19547 * server.c (gdbserver_version): Likewise.
19548
19549 2009-01-05 Doug Evans <dje@google.com>
19550
19551 * linux-low.c (linux_attach_lwp): Add some comments/fixmes.
19552 (handle_extended_wait): Improve comment.
19553
19554 2008-12-13 Doug Evans <dje@google.com>
19555
19556 * utils.c (xmalloc,xcalloc,xstrdup): New fns.
19557 * server.h (ATTR_MALLOC): New macro.
19558 (xmalloc,xcalloc,xstrdup): Declare.
19559 * hostio.c: Replace malloc,calloc,strdup with xmalloc,xcalloc,xstrdup.
19560 * inferiors.c: Ditto.
19561 * linux-low.c: Ditto.
19562 * mem-break.c: Ditto.
19563 * regcache.c: Ditto.
19564 * remote-utils.c: Ditto.
19565 * server.c: Ditto.
19566 * target.c: Ditto.
19567 * win32-low.c: Ditto.
19568
19569 2008-12-12 Doug Evans <dje@google.com>
19570
19571 * linux-low.c (linux_wait_for_process): Don't clobber current_inferior
19572 in debugging printf.
19573
19574 * linux-low.c (handle_extended_wait): Simplify, use my_waitpid.
19575
19576 2008-12-09 Doug Evans <dje@google.com>
19577
19578 * linux-low.h (struct process_info): Delete member tid, unused.
19579 * thread-db.c (find_one_thread): Update.
19580 (maybe_attach_thread): Update.
19581
19582 2008-12-02 Pedro Alves <pedro@codesourcery.com>
19583
19584 * target.h (struct target_ops): Add qxfer_osdata member.
19585 * linux-low.c: Include ctype.h and pwd.h and sys/types.h
19586 and dirent.h.
19587 (linux_qxfer_osdata): New functions.
19588 (linux_target_ops): Register linux_qxfer_osdata as qxfer_osdata
19589 callback.
19590 * server.c (handle_query): Handle "qXfer:osdata:read:".
19591 * remote-utils.c (buffer_grow, buffer_free, buffer_init, buffer_finish)
19592 (buffer_xml_printf): New functions.
19593 * server.h (struct buffer): New.
19594 (buffer_grow_str, buffer_grow_str0): New macros.
19595 (buffer_grow, buffer_free, buffer_init, buffer_finish)
19596 (buffer_xml_printf): Declare.
19597
19598 2008-11-24 Doug Evans <dje@google.com>
19599
19600 * Makefile.in (VERSION,DIST,LINT,LINTFLAGS): Delete, unused.
19601
19602 2008-11-24 Daniel Jacobowitz <dan@codesourcery.com>
19603
19604 * server.c (handle_v_run): Always use the supplied argument list.
19605
19606 2008-11-19 Bob Wilson <bob.wilson@acm.org>
19607
19608 * xtensa-xtregs.c (XTENSA_ELF_XTREG_SIZE): Change to 4.
19609 (xtensa_regmap_table): Add entry for scompare1.
19610
19611 2008-11-18 Thiago Jung Bauermann <bauerman@br.ibm.com>
19612
19613 * Makefile.in (powerpc-isa205-32l.o, powerpc-isa205-32l.c,
19614 powerpc-isa205-altivec32l.o, powerpc-isa205-altivec32l.c,
19615 powerpc-isa205-vsx32l.o, powerpc-isa205-vsx32l.c,
19616 powerpc-isa205-64l.o, powerpc-isa205-64l.c,
19617 powerpc-isa205-altivec64l.o, powerpc-isa205-altivec64l.c,
19618 powerpc-isa205-vsx64l.o, powerpc-isa205-vsx64l.c): New targets.
19619 * configure.srv (powerpc*-*-linux*): Add ISA 2.05 object files and
19620 XML target descriptions.
19621 * linux-ppc-low.c (ppc_arch_setup): Init registers with 64-bit FPSCR
19622 when inferior is running on an ISA 2.05 or later processor. Add
19623 special case to return offset for full 64-bit slot of FPSCR when
19624 in 32-bits.
19625
19626 2008-11-14 Daniel Gutson <dgutson@codesourcery.com>
19627
19628 * Makefile.in (SFILES, clean): Added sparc64 files.
19629 (reg-sparc64.o, reg-sparc64.c): New.
19630 * configure.srv (sparc*-*-linux*): New configuration.
19631 * linux-low.c (regsets_fetch_inferior_registers): Swap ptrace
19632 syscall arguments for SPARC.
19633 (regsets_store_inferior_registers): Likewise.
19634 * linux-sparc-low.c: New file.
19635
19636 2008-10-21 Doug Evans <dje@google.com>
19637
19638 * Makefile.in (BFD_DIR,BFD,BFD_SRC,BFD_CFLAGS): Delete.
19639 (READLINE_DIR,READLINE_DEP): Delete.
19640 (INTERNAL_CFLAGS): Update.
19641 (LINTFLAGS): Update.
19642
19643 2008-10-10 Pedro Alves <pedro@codesourcery.com>
19644
19645 * server.c (handle_v_run): If GDB didn't specify an argv, use the
19646 whole argv from the last run, not just argv[0].
19647
19648 2008-09-08 Pedro Alves <pedro@codesourcery.com>
19649
19650 * regcache.c (new_register_cache): Return NULL if the register
19651 cache size isn't known yet.
19652 (free_register_cache): Avoid dereferencing a NULL regcache.
19653
19654 2008-09-04 Daniel Jacobowitz <dan@codesourcery.com>
19655
19656 * configure.srv: Merge MIPS and MIPS64.
19657
19658 2008-08-24 Maciej W. Rozycki <macro@linux-mips.org>
19659
19660 * Makefile.in (uninstall): Apply $(EXEEXT) too.
19661
19662 2008-08-18 Luis Machado <luisgpm@br.ibm.com>
19663
19664 * Makefile.in: Add required vsx dependencies.
19665
19666 * linux-ppc-low: Define PPC_FEATURE_HAS_VSX.
19667 Declare init_registers_powerpc_vsx32l.
19668 Declare init_registers_powerpc_vsx64l.
19669 Define PTRACE_GETVSXREGS and PTRACE_SETVSXREGS.
19670 (ppc_arch_setup): Check for VSX in hwcap.
19671 (ppc_fill_vsxregset): New function.
19672 (ppc_store_vsxregset): New function.
19673 Add new VSX entry in regset_info target_regsets.
19674
19675 * configure.srv: Add new VSX dependencies.
19676
19677 2008-08-12 Pedro Alves <pedro@codesourcery.com>
19678
19679 * remote-utils.c (noack_mode, transport_is_reliable): New globals.
19680 (remote_open): Set or clear transport_is_reliable.
19681 (putpkt_binary): Don't expect acks in noack mode.
19682 (getpkt): Don't send ack/nac in noack mode.
19683 * server.c (handle_general_set): Handle QStartNoAckMode.
19684 (handle_query): If connected by tcp pass QStartNoAckMode+ in
19685 qSupported.
19686 (main): Reset noack_mode on every connection.
19687 * server.h (noack_mode): Declare.
19688
19689 2008-08-07 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
19690
19691 * Makefile.in (GDBREPLAY_OBS): New variable.
19692 (gdbreplay$(EXEEXT)): Use it to avoid unportable $^.
19693
19694 2008-08-05 Ulrich Weigand <uweigand@de.ibm.com>
19695 Daniel Jacobowitz <dan@codesourcery.com>
19696
19697 * linux-low.c (linux_resume_one_process): Ignore ESRCH.
19698 (usr_store_inferior_registers): Likewise.
19699 (regsets_store_inferior_registers): Likewise.
19700
19701 2008-07-31 Rolf Jansen <rj@surtec.com>
19702 Pedro Alves <pedro@codesourcery.com>
19703
19704 * configure.ac: Check for memmem declaration.
19705 * server.c [HAVE_MALLOC_H]: Include malloc.h.
19706 (disable_packet_vCont, disable_packet_Tthread, disable_packet_qC)
19707 (disable_packet_qfThreadInfo): Unconditionally compile.
19708 * server.h [!HAVE_DECL_MEMMEM]: Declare memmem.
19709 * configure, config.in: Regenerate.
19710
19711 2008-07-28 Doug Kwan <dougkwan@google.com>
19712
19713 * linux-low.c (sys/dir.h, sys/user.h): Remove includes.
19714 (linux_write_memory): Remove declaration of errno.
19715
19716 2008-07-12 Ulrich Weigand <uweigand@de.ibm.com>
19717
19718 * linux-low.c (handle_extended_wait): Do not use "status"
19719 variable uninitialized.
19720
19721 2008-07-07 Pedro Alves <pedro@codesourcery.com>
19722
19723 * server.c (handle_v_attach): Inhibit reporting dll changes.
19724
19725 2008-06-27 Pedro Alves <pedro@codesourcery.com>
19726
19727 * remote-utils.c (prepare_resume_reply): If requested, don't
19728 output "thread:TID" in the T stop reply.
19729
19730 * server.c (disable_packet_vCont, disable_packet_Tthread)
19731 (disable_packet_qC, disable_packet_qfThreadInfo): New globals.
19732 (handle_query): If requested, disable support for qC, qfThreadInfo
19733 and qsThreadInfo.
19734 (handle_v_requests): If requested, disable support for vCont.
19735 (gdbserver_show_disableable): New.
19736 (main): Handle --disable-packet and --disable-packet=LIST.
19737
19738 * server.h (disable_packet_vCont, disable_packet_Tthread)
19739 (disable_packet_qC, disable_packet_qfThreadInfo): Declare.
19740
19741 2008-06-20 Carlos O'Donell <carlos@codesourcery.com>
19742
19743 * server.c (gdbserver_usage): Mention --version.
19744
19745 2008-06-06 Daniel Jacobowitz <dan@codesourcery.com>
19746
19747 * Makefile.in (gdbreplay.o): New rule.
19748
19749 2008-06-06 Joseph Myers <joseph@codesourcery.com>
19750
19751 * gdbreplay.c (gdbreplay_version): Say gdbreplay in version
19752 message, not gdbserver.
19753
19754 2008-06-05 Vladimir Prus <vladimir@codesourcery.com>
19755 Nathan Sidwell <nathan@codesourcery.com>
19756 Joseph Myers <joseph@codesourcery.com>
19757
19758 * acinclude.m4: Include ../../config/acx.m4.
19759 * configure.ac: Use ACX_PKGVERSION and ACX_BUGURL.
19760 * configure, config.in: Regenerate.
19761 * Makefile.in (gdbreplay$(EXEEXT)): Add version.o.
19762 * server.c (gdbserver_version): Print PKGVERSION.
19763 (gdbsrever_usage): Add stream parameter. Print REPORT_BUGS_TO.
19764 (main): Adjust gdbserver_usage calls.
19765 * gdbreplay.c (version, host_name): Add declarations.
19766 (gdbreplay_version, gdbreplay_usage): New.
19767 (main): Accept --version and --help options.
19768
19769 2008-06-04 Daniel Jacobowitz <dan@codesourcery.com>
19770
19771 * linux-arm-low.c (thumb_breakpoint, thumb_breakpoint_len): New.
19772 (arm_breakpoint_at): Handle Thumb.
19773 (the_low_target): Add comment.
19774
19775 2008-05-29 Ulrich Weigand <uweigand@de.ibm.com>
19776
19777 * linux-ppc-low.c (ppc_collect_ptrace_register): Clear buffer.
19778
19779 2008-05-09 Doug Evans <dje@google.com>
19780
19781 * server.h (decode_search_memory_packet): Declare.
19782 * remote-utils.c (decode_search_memory_packet): New fn.
19783 * server.c (handle_search_memory_1): New fn.
19784 (handle_search_memory): New fn.
19785 (handle_query): Process qSearch:memory packets.
19786
19787 2008-05-08 Ulrich Weigand <uweigand@de.ibm.com>
19788
19789 * regcache.c (registers_length): Remove.
19790 (set_register_cache): Verify that PBUFSIZ is large enough to hold a
19791 full register packet.
19792 * regcache.h (registers_length): Remove prototype.
19793 * server.h (PBUFSIZ): Define to 16384.
19794
19795 2008-05-03 Ulrich Weigand <uweigand@de.ibm.com>
19796
19797 * configure.srv (powerpc*-*-linux*): Set srv_regobj to
19798 powerpc-32l.o, powerpc-altivec32l.o, powerpc-e500l.o,
19799 powerpc-64l.o, and powerpc-altivec64l.o.
19800 Remove rs6000/powerpc-32.xml, rs6000/powerpc-64.xml, and
19801 rs6000/powerpc-e500.xml; add rs6000/powerpc-32l.xml,
19802 rs6000/powerpc-altivec32l.xml, rs6000/powerpc-e500l.xml,
19803 rs6000/powerpc-64l.xml, rs6000/powerpc-altivec64l.xml,
19804 rs6000/power-linux.xml, and rs6000/power64-linux.xml
19805 to srv_xmlfiles.
19806
19807 * Makefile.in (reg-ppc.o, reg-ppc.c): Remove, replace by ...
19808 (powerpc-32l.o, powerpc-32l.c): ... these new rules.
19809 (powerpc-32.o, powerpc-32.c): Remove, replace by ...
19810 (powerpc-altivec32l.o, powerpc-altivec32l.c): ... these new rules.
19811 (powerpc-e500.o, powerpc-e500.c): Remove, replace by ...
19812 (powerpc-e500l.o, powerpc-e500l.c): ... these new rules.
19813 (reg-ppc64.o, reg-ppc64.c): Remove, replace by ...
19814 (powerpc-64l.o, powerpc-64l.c): ... these new rules.
19815 (powerpc-64.o, powerpc-64.c): Remove, replace by ...
19816 (powerpc-altivec64l.o, powerpc-altivec64l.c): ... these new rules.
19817 (clean): Update.
19818
19819 * linux-ppc-low.c (init_registers_ppc): Remove, replace by ...
19820 (init_registers_powerpc_32l): ... this new prototype.
19821 (init_registers_powerpc_32): Remove, replace by ...
19822 (init_registers_powerpc_altivec32l): ... this new prototype.
19823 (init_registers_powerpc_e500): Remove, replace by ...
19824 (init_registers_powerpc_e500l): ... this new prototype.
19825 (init_registers_ppc64): Remove, replace by ...
19826 (init_registers_powerpc_64l): ... this new prototype.
19827 (init_registers_powerpc_64): Remove, replace by ...
19828 (init_registers_powerpc_altivec64l): ... this new prototype.
19829 (ppc_num_regs): Set to 73.
19830 (PT_ORIG_R3, PT_TRAP): Define if necessary.
19831 (ppc_regmap, ppc_regmap_e500): Add values for orig_r3 and trap.
19832 (ppc_cannot_store_register): Handle orig_r3 and trap.
19833 (ppc_arch_setup): Update init_registers_... calls.
19834 (ppc_fill_gregset): Handle orig_r3 and trap.
19835
19836 * inferiors.c (clear_inferiors): Reset current_inferior.
19837
19838 2008-04-23 Paolo Bonzini <bonzini@gnu.org>
19839
19840 * acinclude.m4: Add override.m4.
19841 * configure: Regenerate.
19842
19843 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
19844
19845 * linux-ppc-low.c (ppc_arch_setup): Reset ppc_hwcap after the
19846 initial call to init_register_ppc64.
19847
19848 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
19849
19850 * configure.srv (powerpc64-*-linux*, powerpc-*-linux*): Merge into
19851 single powerpc*-*-linux* case.
19852 (s390-*-linux*, s390x-*-linux*): Merge into single s390*-*-linux* case.
19853
19854 2008-04-17 Ulrich Weigand <uweigand@de.ibm.com>
19855
19856 * configure.srv [powerpc64-*-linux*]: Remove powerpc-e500.o from
19857 srv_regobj. Remove rs6000/powerpc-e500.xml and rs6000/power-spe.xml
19858 from reg_xmlfiles.
19859 * linux-ppc-low.c: Include <elf.h>.
19860 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Define.
19861 (ppc_hwcap): New global variable.
19862 (ppc_regmap): Remove __SPE__ #ifdef sections.
19863 (ppc_regmap_e500): New global variable.
19864 (ppc_cannot_store_register): Update __SPE__ special case.
19865 (ppc_get_hwcap): New function.
19866 (ppc_arch_setup): Use it to determine whether inferior supports
19867 AltiVec or SPE registers. Set the_low_target.regmap if appropriate.
19868 (ppc_fill_vrregset, ppc_store_vrregset): Define unconditionally.
19869 Do not access registers if target does not support AltiVec.
19870 (ppc_fill_evrregset, ppc_store_evrregset): Define unconditionally.
19871 Do not access registers if target does not support SPE.
19872 (target_regsets): Unconditionally include AltiVec and SPE regsets.
19873
19874 2008-04-17 Daniel Jacobowitz <dan@codesourcery.com>
19875
19876 * linux-low.c (disabled_regsets, num_regsets): New.
19877 (use_regsets_p): Delete.
19878 (linux_wait_for_process): Clear disabled_regsets.
19879 (regsets_fetch_inferior_registers): Check and set it.
19880 (regsets_store_inferior_registers): Likewise.
19881 (linux_fetch_registers, linux_store_registers): Do not use
19882 use_regsets_p.
19883 (initialize_low): Allocate disabled_regsets.
19884
19885 2008-04-14 Daniel Jacobowitz <dan@codesourcery.com>
19886
19887 * Makefile.in (LIBOBJS): New.
19888 (OBS): Use LIBOBJS.
19889 (memmem.o): New rule.
19890 * configure.ac: Use AC_CONFIG_LIBOBJ_DIR and check for memmem.
19891 * configure: Regenerated.
19892
19893 2008-04-04 Ulrich Weigand <uweigand@de.ibm.com>
19894
19895 * server.c (handle_query): Never return "unsupported" for
19896 qXfer:features:read queries.
19897
19898 2008-03-27 Ulrich Weigand <uweigand@de.ibm.com>
19899
19900 * server.c (get_features_xml): Fix inverted condition.
19901 (handle_query): Always support qXfer:feature:read.
19902
19903 2008-03-10 Daniel Jacobowitz <dan@codesourcery.com>
19904
19905 * server.c (wrapper_argv): New.
19906 (start_inferior): Handle wrapper_argv. If set, expect an extra
19907 trap.
19908 (gdbserver_usage): Document --wrapper.
19909 (main): Parse --wrapper.
19910
19911 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
19912
19913 * configure.srv [powerpc64-*-linux*]: Add all files mentioned for
19914 powerpc-*-linux* to srv_regobj and reg_xmlfiles.
19915 * linux-ppc-low.c (ppc_get_pc): Support bi-arch operation.
19916 (ppc_set_pc): Likewise.
19917 (ppc_arch_setup): New function.
19918 (ppc_fill_gregset): Call ppc_collect_ptrace_register instead
19919 of collect_register.
19920 (the_low_target): Use ppc_arch_setup as arch_setup initializer.
19921
19922 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
19923
19924 * configure.srv [powerpc64-*-linux*]: Use linux-ppc-low.o
19925 instead of linux-ppc64-low.o.
19926 * linux-ppc64-low.c: Remove file.
19927 * Makefile.in (SFILES): Remove linux-ppc64-low.c.
19928 (linux-ppc64-low.o): Remove rule.
19929
19930 * linux-ppc-low.c (init_registers_ppc64): Add prototype.
19931 (init_registers_powerpc_64): Likewise.
19932 (ppc_regmap): Conditionally define depending on __powerpc64__.
19933 (ppc_cannot_store_register): Do not special-case "fpscr" when
19934 compiled on __powerpc64__.
19935 (ppc_collect_ptrace_register): New function.
19936 (ppc_supply_ptrace_register): New function.
19937 (ppc_breakpoint): Change type to "unsigned int".
19938 (ppc_breakpoint_at): Change type of "insn" to "unsigned int".
19939 (the_low_target): Conditionally provide initializers for the
19940 arch_setup member depending on __powerpc64__. Install
19941 collect_ptrace_register and supply_ptrace_register members.
19942
19943 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
19944
19945 * regcache.h (gdbserver_xmltarget): Add extern declaration.
19946 * server.c (gdbserver_xmltarget): Define.
19947 (get_features_xml): Use it to replace "target.xml" and arch_string.
19948
19949 * configure.srv: Remove srv_xmltarget. Add XML files that were
19950 mentioned there to srv_xmlfiles instead. Remove conditional tests
19951 on gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe; set
19952 srv_xmlfiles and srv_regobj to include all possible choices.
19953 * configure.ac (srv_xmltarget): Remove.
19954 (srv_xmlfiles): Do not add "target.xml".
19955 (gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe): Remove
19956 checks for supplementary target information.
19957 * configure: Regenerate.
19958 * Makefile.in (XML_TARGET): Remove.
19959 (target.xml): Remove rule.
19960 (clean): Do not clean up target.xml.
19961 (.PRECIOUS): Do not mention target.xml.
19962
19963 * target.h (struct target_ops): Remove arch_string member.
19964 * linux-low.c (linux_arch_string): Remove.
19965 (linux_target_ops): Remove arch_string initializer.
19966 * linux-low.h (struct linux_target_ops): Remove arch_string member.
19967 * linux-i386-low.c (the_low_target): Remove arch_string initializer.
19968 * linux-x86-64-low.c (the_low_target): Remove arch_string initializer.
19969 * spu-low.c (spu_arch_string): Remove.
19970 (spu_target_ops): Remove arch_string initializer.
19971 * win32-low.c (win32_arch_string): Remove.
19972 (win32_target_ops): Remove arch_string initializer.
19973 * win32-low.h (struct win32_target_ops): Remove arch_string member.
19974 * win32-arm-low.c (the_low_target): Remove arch_string initializer.
19975 * win32-i368-low.c (the_low_target): Remove arch_string initializer.
19976
19977 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
19978
19979 * linux-low.h (struct linux_target_ops): Replace left_pad_xfer field
19980 by collect_ptrace_register and supply_ptrace_register hooks.
19981 * linux-low.c (fetch_register): Use supply_ptrace_register callback
19982 instead of checking for the_low_target.left_pad_xfer.
19983 (usr_store_inferior_registers): Use collect_ptrace_register callback
19984 instead of checking for the_low_target.left_pad_xfer.
19985
19986 * linux-s390-low.c (s390_collect_ptrace_register): New function.
19987 (s390_supply_ptrace_register): Likewise.
19988 (s390_fill_gregset): Call s390_collect_ptrace_register.
19989 (the_low_target): Update.
19990
19991 * linux-ppc64-low.c (ppc_collect_ptrace_register): New function.
19992 (ppc_supply_ptrace_register): Likewise.
19993 (the_low_target): Update.
19994
19995 * linux-i386-low.c (the_low_target): Update.
19996 * linux-x86-64-low.c (the_low_target): Update.
19997
19998 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
19999
20000 * configure.srv [s390x-*-linux*]: Set srv_regobj to include both
20001 reg-s390.o and reg-s390x.o.
20002
20003 * linux-low.c (new_inferior): New global variable.
20004 (linux_create_inferior, linux_attach): Set it.
20005 (linux_wait_for_process): Call the_low_target.arch_setup after the
20006 target has stopped for the first time.
20007 (initialize_low): Do not call the_low_target.arch_setup.
20008
20009 * linux-s390-low.c (s390_get_pc): Support bi-arch operation.
20010 (s390_set_pc): Likewise.
20011 (s390_arch_setup): New function.
20012 (the_low_target): Use s390_arch_setup as arch_setup routine.
20013
20014 * regcache.c (realloc_register_cache): New function.
20015 (set_register_cache): Call it for each existing regcache.
20016
20017 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
20018
20019 * server.h (init_registers): Remove prototype.
20020
20021 * linux-low.h (struct linux_target_ops): Add arch_setup field.
20022 * linux-low.c (initialize_low): Call the_low_target.arch_setup ()
20023 instead of init_registers ().
20024 * linux-arm-low.c (init_registers_arm): Add prototype.
20025 (init_registers_arm_with_iwmmxt): Likewise.
20026 (the_low_target): Add initializer for arch_setup field.
20027 * linux-cris-low.c (init_registers_cris): Add prototype.
20028 (the_low_target): Add initializer for arch_setup field.
20029 * linux-crisv32-low.c (init_registers_crisv32): Add prototype.
20030 (the_low_target): Add initializer for arch_setup field.
20031 * linux-i386-low.c (init_registers_i386_linux): Add prototype.
20032 (the_low_target): Add initializer for arch_setup field.
20033 * linux-ia64-low.c (init_registers_ia64): Add prototype.
20034 (the_low_target): Add initializer for arch_setup field.
20035 * linux-m32r-low.c (init_registers_m32r): Add prototype.
20036 (the_low_target): Add initializer for arch_setup field.
20037 * linux-m68k-low.c (init_registers_m68k): Add prototype.
20038 (the_low_target): Add initializer for arch_setup field.
20039 * linux-mips-low.c (init_registers_mips_linux): Add prototype.
20040 (init_registers_mips64_linux): Likewise.
20041 (the_low_target): Add initializer for arch_setup field.
20042 * linux-ppc-low.c (init_registers_ppc): Add prototype.
20043 (init_registers_powerpc_32, init_registers_powerpc_e500): Likewise.
20044 (the_low_target): Add initializer for arch_setup field.
20045 * linux-ppc64-low.c (init_registers_ppc64): Add prototype.
20046 (init_registers_powerpc_64): Likewise.
20047 (the_low_target): Add initializer for arch_setup field.
20048 * linux-s390-low.c (init_registers_s390): Add prototype.
20049 (init_registers_s390x): Likewise.
20050 (the_low_target): Add initializer for arch_setup field.
20051 * linux-sh-low.c (init_registers_sh): Add prototype.
20052 (the_low_target): Add initializer for arch_setup field.
20053 * linux-x86-64-low.c (init_registers_x86_64_linux): Add prototype.
20054 (the_low_target): Add initializer for arch_setup field.
20055 * linux-xtensa-low.c (init_registers_xtensa): Add prototype.
20056 (the_low_target): Add initializer for arch_setup field.
20057
20058 * win32-low.h (struct win32_target_ops): Add arch_setup field.
20059 * win32-low.c (initialize_low): Call the_low_target.arch_setup ()
20060 instead of init_registers ().
20061 * win32-arm-low.c (init_registers_arm): Add prototype.
20062 (the_low_target): Add initializer for arch_setup field.
20063 * win32-i386-low.c (init_registers_i386): Add prototype.
20064 (the_low_target): Add initializer for arch_setup field.
20065
20066 * spu-low.c (init_registers_spu): Add prototype.
20067 (initialize_low): Call initialie_registers_spu () instead of
20068 initialize_registers ().
20069
20070 2008-02-19 Pedro Alves <pedro@codesourcery.com>
20071
20072 * server.c (handle_v_requests): When handling the vRun and vAttach
20073 packets, if already debugging a process, don't kill it. Return an
20074 error instead.
20075
20076 2008-02-17 Daniel Jacobowitz <dan@codesourcery.com>
20077
20078 * server.c (handle_query): Correct length check.
20079
20080 2008-02-14 Pedro Alves <pedro_alves@portugalmail.pt>
20081
20082 * win32-low.c (do_initial_child_stuff): Add process handle
20083 parameter. Set current_process_handle and current_process_id from the
20084 parameters. Clear globals.
20085 (win32_create_inferior): Don't set current_process_handle and
20086 current_process_id here. Instead pass them on the call to
20087 do_initial_child_stuff.
20088 (win32_attach): Likewise.
20089 (win32_clear_inferiors): New.
20090 (win32_kill): Don't close the current process handle or the
20091 current thread handle here. Instead call win32_clear_inferiors.
20092 (win32_detach): Don't open a new handle to the process. Call
20093 win32_clear_inferiors.
20094 (win32_join): Don't rely on current_process_handle; open a new
20095 handle using the process id.
20096 (win32_wait): Call win32_clear_inferiors when the inferior process
20097 has exited.
20098
20099 2008-02-14 Daniel Jacobowitz <dan@codesourcery.com>
20100
20101 * server.c (monitor_show_help): Add "exit".
20102
20103 2008-02-11 Maxim Grigoriev <maxim2405@gmail.com>
20104
20105 * Makefile.in (SFILES): Add linux-xtensa-low.c.
20106 (clean): Add reg-xtensa.c.
20107 (linux-xtensa-low.o, reg-xtensa.o, reg-xtensa.c): New dependencies.
20108 * configure.srv (xtensa*-*-linux*) New target.
20109 * linux-xtensa-low.c: New.
20110 * xtensa-xtregs.c: New.
20111
20112 2008-02-01 Pedro Alves <pedro_alves@portugalmail.pt>
20113
20114 * hostio.c: Don't include errno.h.
20115 (errno_to_fileio_errno): Move to hostio-errno.
20116 * hostio.c: (hostio_error): Remove the error parameter. Defer the
20117 error number outputting to the target->hostio_last_error callback.
20118 (hostio_packet_error): Use FILEIO_EINVAL directly.
20119 (handle_open, handle_pread, hostio_error, handle_unlink): Update
20120 calls to hostio_error.
20121 * hostio-errno.c: New.
20122 * server.h (hostio_last_error_from_errno): Declare.
20123 * target.h (target_ops): Add hostio_last_error member.
20124 * linux-low.c (linux_target_op): Register hostio_last_error_from_errno
20125 as hostio_last_error handler.
20126 * spu-low.c (spu_target_ops): Likewise.
20127 * win32-low.c [_WIN32_WCE] (win32_error_to_fileio_error)
20128 (wince_hostio_last_error): New functions.
20129 (win32_target_ops) [_WIN32_WCE]: Register wince_hostio_last_error
20130 as hostio_last_error handler.
20131 (win32_target_ops) [!_WIN32_WCE]: Register
20132 hostio_last_error_from_errno as hostio_last_error handler.
20133 * Makefile.in (SFILES): Add hostio.c and hostio-errno.c.
20134 (hostio-errno.o): New rule.
20135 * configure.ac (GDBSERVER_DEPFILES): Add $srv_hostio_err_objs.
20136 * configure.srv (srv_hostio_err_objs): New variable. Default to
20137 hostio-errno.o.
20138 (arm*-*-mingw32ce*): Set srv_hostio_err_objs to "".
20139 * configure: Regenerate.
20140
20141 2008-01-29 Daniel Jacobowitz <dan@codesourcery.com>
20142
20143 * linux-low.c (linux_attach_lwp): Do not _exit after errors.
20144 (linux_kill, linux_detach): Clean up the process list.
20145 * remote-utils.c (remote_open): Improve port number parsing.
20146 (putpkt_binary, input_interrupt): Only send interrupts if the target
20147 is running.
20148 * server.c (extended_protocol): Make static.
20149 (attached): Define earlier.
20150 (exit_requested, response_needed, program_argv): New variables.
20151 (target_running): New.
20152 (start_inferior): Clear attached here.
20153 (attach_inferior): Set attached here.
20154 (require_running): Define.
20155 (handle_query): Use require_running and target_running. Implement
20156 "monitor exit".
20157 (handle_v_attach, handle_v_run): New.
20158 (handle_v_requests): Use require_running. Handle vAttach and vRun.
20159 (gdbserver_usage): Update.
20160 (main): Redo argument parsing. Handle --debug and --multi. Handle
20161 --attach along with other options or after the port. Save
20162 program_argv. Support no initial program. Resynchronize
20163 communication with GDB after an error. Handle "monitor exit".
20164 Use require_running and target_running. Always allow the extended
20165 protocol. Do not error out for Hc0 or Hc-1. Do not automatically
20166 restart in extended mode.
20167 * README: Refer to the GDB manual. Update --attach usage.
20168
20169 2007-12-20 Andreas Schwab <schwab@suse.de>
20170
20171 * linux-low.c (STACK_SIZE): Define.
20172 (linux_tracefork_child): Use it. Use __clone2 on ia64.
20173 (linux_test_for_tracefork): Likewise.
20174
20175 2007-12-18 Daniel Jacobowitz <dan@codesourcery.com>
20176
20177 * linux-low.c (linux_wait_for_event): Update messages. Do not
20178 reinsert auto-delete breakpoints.
20179 * mem-break.c (struct breakpoint): Change return type of handler to
20180 int.
20181 (set_breakpoint_at): Update handler type.
20182 (reinsert_breakpoint_handler): Return 1 instead of calling
20183 delete_breakpoint.
20184 (reinsert_breakpoint_by_bp): Check for the original breakpoint before
20185 setting a new one.
20186 (check_breakpoints): Delete auto-delete breakpoints and return 2.
20187 * mem-break.h (set_breakpoint_at): Update handler type.
20188 * thread-db.c (thread_db_create_event, thread_db_create_event): Update.
20189 * win32-low.c (auto_delete_breakpoint): New.
20190 (get_child_debug_event): Use it.
20191
20192 2007-12-16 Daniel Jacobowitz <dan@codesourcery.com>
20193
20194 * configure.ac: Check for pread and pwrite.
20195 * hostio.c (handle_pread): Fall back to lseek and read.
20196 (handle_pwrite): Fall back to lseek and write.
20197 * config.in, configure: Regenerated.
20198
20199 2007-12-07 Daniel Jacobowitz <dan@codesourcery.com>
20200
20201 * server.c (myresume): Add own_buf argument.
20202 (main): Update calls.
20203
20204 2007-12-06 Daniel Jacobowitz <dan@codesourcery.com>
20205
20206 * linux-low.c (linux_wait, linux_resume): Do not handle async I/O.
20207 * remote-utils.c (remote_open): Do not call disable_async_io.
20208 (block_async_io): Delete.
20209 (unblock_async_io): Make static.
20210 (initialize_async_io): New.
20211 * server.c (handle_v_cont): Handle async I/O here.
20212 (myresume): Likewise. Move other common resume tasks here...
20213 (main): ... from here. Call initialize_async_io. Disable async
20214 I/O before the main loop.
20215 * server.h (initialize_async_io): Declare.
20216 (block_async_io, unblock_async_io): Delete prototypes.
20217 * spu-low.c (spu_resume, spu_wait): Do not handle async I/O here.
20218
20219 2007-12-06 Mick Davis <mickd@goanna.iinet.net.au>
20220
20221 * remote-utils.c (readchar): Allow binary data in received messages.
20222
20223 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
20224
20225 * win32-low.c (attaching): New global.
20226 (win32_create_inferior): Clear the `attaching' global.
20227 (win32_attach): Set the `attaching' global.
20228 (get_child_debug_event) [_WIN32_WCE]: Stop the inferior when
20229 attaching. Only set a breakpoint at the entry point if not
20230 attaching.
20231
20232 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
20233
20234 * server.c (main): Don't report dll events on the initial
20235 connection on attaches.
20236
20237 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
20238
20239 * server.c (main): Relax numerical bases supported for the pid of
20240 the --attach command line argument.
20241
20242 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
20243
20244 * win32-low.c (win32_attach): Call OpenProcess before
20245 DebugActiveProcess, not after. Add last error output to error
20246 call.
20247
20248 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
20249
20250 * win32-low.c (win32_get_thread_context)
20251 (win32_set_thread_context): New functions.
20252 (thread_rec): Use win32_get_thread_context.
20253 (continue_one_thread, win32_resume): Use win32_set_thread_context.
20254 * win32-low.h (win32_thread_info) [_WIN32_WCE]: Add `base_context'
20255 field.
20256
20257 2007-12-03 Leo Zayas
20258 Pedro Alves <pedro_alves@portugalmail.pt>
20259
20260 * win32-low.c (soft_interrupt_requested, faked_breakpoint): New
20261 global variables.
20262 (child_add_thread): Minor cleanup.
20263 (child_continue): Resume artificially suspended threads before
20264 calling ContinueDebugEvent.
20265 (suspend_one_thread): New.
20266 (fake_breakpoint_event): New.
20267 (get_child_debug_event): Change return type to int. Check here if
20268 gdb sent an interrupt request. If a soft interrupt was requested,
20269 fake a breakpoint event. Return 0 if there is no event to handle,
20270 and 1 otherwise.
20271 (win32_wait): Don't check here if gdb sent an interrupt request.
20272 Ensure there is a valid event to handle.
20273 (win32_request_interrupt): Add soft interruption method as last
20274 resort.
20275
20276 2007-12-03 Leo Zayas
20277 Pedro Alves <pedro_alves@portugalmail.pt>
20278
20279 * win32-low.h (win32_thread_info): Add descriptions to the
20280 structure members. Replace `suspend_count' counter by a
20281 `suspended' flag.
20282 * win32-low.c (thread_rec): Update condition of when to get the
20283 context from the inferior. Rely on ContextFlags being set if it
20284 has already been retrieved. Only suspend the inferior thread if
20285 we haven't already. Warn if that fails.
20286 (continue_one_thread): s/suspend_count/suspended/. Only call
20287 ResumeThread once. Warn if that fails.
20288
20289 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
20290
20291 * win32-low.c (win32_wait): Don't read from the inferior when it
20292 has already exited.
20293
20294 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
20295
20296 * Makefile.in (win32_low_h): New variable.
20297 (win32-low.o): Add dependency on $(win32_low_h).
20298 (win32-arm-low.o, win32-i386-low.o): New rules.
20299
20300 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
20301
20302 * hostio.c: Correct copyright year.
20303
20304 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
20305
20306 * Makefile.in (OBS): Add hostio.o.
20307 (hostio.o): New rule.
20308 * server.h (handle_vFile): Declare.
20309 * hostio.c: New file.
20310 * server.c (handle_v_requests): Take packet_len and new_packet_len
20311 for binary packets. Call handle_vFile.
20312 (main): Update call to handle_v_requests.
20313
20314 2007-11-05 Daniel Jacobowitz <dan@codesourcery.com>
20315
20316 * linux-low.c: Include <sched.h>.
20317
20318 2007-11-01 Daniel Jacobowitz <dan@codesourcery.com>
20319
20320 * linux-low.c (linux_tracefork_grandchild): New.
20321 (linux_tracefork_child): Use clone.
20322 (linux_test_for_tracefork): Use clone; allocate and free a stack.
20323
20324 2007-10-31 Joel Brobecker <brobecker@adacore.com>
20325
20326 * Makefile.in: Use $(SHELL) instead of "sh" to call regdat.sh.
20327
20328 2007-10-24 Daniel Jacobowitz <dan@codesourcery.com>
20329
20330 * linux-low.c (handle_extended_wait): Handle unexpected signals.
20331
20332 2007-10-23 Daniel Jacobowitz <dan@codesourcery.com>
20333
20334 * inferiors.c (change_inferior_id): Delete.
20335 (add_pid_to_list, pull_pid_from_list): New.
20336 * linux-low.c (PTRACE_SETOPTIONS, PTRACE_GETEVENTMSG)
20337 (PTRACE_O_TRACESYSGOOD, PTRACE_O_TRACEFORK, PTRACE_O_TRACEVFORK)
20338 (PTRACE_O_TRACECLONE, PTRACE_O_TRACEEXEC, PTRACE_O_TRACEVFORKDONE)
20339 (PTRACE_O_TRACEEXIT, PTRACE_EVENT_FORK, PTRACE_EVENT_VFORK)
20340 (PTRACE_EVENT_CLONE, PTRACE_EVENT_EXEC, PTRACE_EVENT_VFORK_DONE)
20341 (PTRACE_EVENT_EXIT, __WALL): Provide default definitions.
20342 (stopped_pids, thread_db_active, must_set_ptrace_flags): New variables.
20343 (using_threads): Always set to 1.
20344 (handle_extended_wait): New.
20345 (add_process): Do not set TID.
20346 (linux_create_inferior): Set must_set_ptrace_flags.
20347 (linux_attach_lwp): Remove TID argument. Do not check using_threads.
20348 Use PTRACE_SETOPTIONS. Call new_thread_notify. Update all callers.
20349 (linux_thread_alive): Rename TID argument to LWPID.
20350 (linux_wait_for_process): Handle unknown processes. Do not use TID.
20351 (linux_wait_for_event): Do not use TID or check using_threads. Update
20352 call to dead_thread_notify. Call handle_extended_wait.
20353 (linux_create_inferior): Use PTRACE_SETOPTIONS.
20354 (send_sigstop): Delete sigstop_sent.
20355 (wait_for_sigstop): Avoid TID.
20356 (linux_supports_tracefork_flag, linux_tracefork_child, my_waitpid)
20357 (linux_test_for_tracefork): New.
20358 (linux_lookup_signals): Use thread_db_active and
20359 linux_supports_tracefork_flag.
20360 (initialize_low): Use thread_db_active and linux_test_for_tracefork.
20361 * linux-low.h (get_process_thread): Avoid TID.
20362 (struct process_ifo): Move thread_known and tid to the end. Remove
20363 sigstop_sent.
20364 (linux_attach_lwp, thread_db_init): Update prototypes.
20365 * server.h (change_inferior_id): Delete prototype.
20366 (add_pid_to_list, pull_pid_from_list): New prototypes.
20367 * thread-db.c (thread_db_use_events): New.
20368 (find_first_thread): Rename to...
20369 (find_one_thread): ...this. Update callers and messages. Do not
20370 call fatal. Check thread_db_use_events. Do not call
20371 change_inferior_id or new_thread_notify.
20372 (maybe_attach_thread): Update. Do not call new_thread_notify.
20373 (thread_db_init): Set thread_db_use_events. Check use_events.
20374 * utils.c (fatal, warning): Correct message prefix.
20375
20376 2007-10-15 Daniel Jacobowitz <dan@codesourcery.com>
20377
20378 * Makefile.in (clean): Remove new files.
20379 (powerpc-32.o, powerpc-32.c, powerpc-e500.o, powerpc-e500.c)
20380 (powerpc-64.o, powerpc-64.c): New rules.
20381 * configure.srv: Use alternate register sets for powerpc64-*-linux*
20382 with AltiVec, powerpc-*-linux* with AltiVec, and powerpc-*-linux*
20383 with SPE.
20384 * linux-ppc-low.c (ppc_regmap): Do not fetch the FP registers for
20385 SPE targets.
20386 (ppc_cannot_store_register): Do not check for FPSCR for SPE targets.
20387 (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS, ppc_fill_vrregset)
20388 (ppc_store_vrregset, PTRACE_GETEVRREGS, PTRACE_SETEVRREGS)
20389 (struct gdb_evrregset_t, ppc_fill_evrregset, ppc_store_evrregset): New.
20390 (target_regsets): Add AltiVec and SPE register sets.
20391 * configure.ac: Check for AltiVec and SPE.
20392 * linux-ppc64-low.c (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS)
20393 (ppc_fill_vrregset, ppc_store_vrregset): New.
20394 (target_regsets): Add AltiVec register set.
20395 * configure: Regenerated.
20396
20397 2007-09-19 Daniel Jacobowitz <dan@codesourcery.com>
20398
20399 * linux-low.c (O_LARGEFILE): Define.
20400 (linux_read_memory): Use /proc/PID/mem.
20401 * configure.ac: Use AC_GNU_SOURCE. Check for pread64.
20402 * configure, config.in: Regenerated.
20403
20404 2007-09-04 Daniel Jacobowitz <dan@codesourcery.com>
20405
20406 * linux-low.c (linux_wait_for_event): Do not pass signals while
20407 single-stepping.
20408
20409 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
20410
20411 * win32-low.c (create_process): New.
20412 (win32_create_inferior): Use create_process instead of
20413 CreateProcess. If create_process failed retry appending an ".exe"
20414 suffix. Store the GetLastError result immediatelly after
20415 create_process calls and use it on the call to error.
20416
20417 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
20418
20419 * win32-low.c (handle_load_dll): Don't use toolhelp when waiting.
20420
20421 2007-08-23 Joel Brobecker <brobecker@adacore.com>
20422
20423 * configure.ac: Switch license to GPLv3.
20424
20425 2007-08-01 Michael Snyder <msnyder@access-company.com>
20426
20427 * remote-utils.c (putpkt_binary): Memory leak, free buf2.
20428
20429 2007-07-31 Pedro Alves <pedro_alves@portugalmail.pt>
20430
20431 * win32-low.c (winapi_CloseToolhelp32Snapshot) [_WIN32_WCE]: New
20432 typedef.
20433 (win32_CloseToolhelp32Snapshot) [_WIN32_WCE]: New global var.
20434 (load_toolhelp) [_WIN32_WCE]: Load TOOLHELP.DLL. Get
20435 CloseToolhelp32Snapshot.
20436 (toolhelp_get_dll_name) [_WIN32_WCE]: Close the snapshot with
20437 CloseToolhelp32Snapshot.
20438
20439 2007-07-27 Michael Snyder <michael.snyder@access-company.com>
20440
20441 * server.c (main): Check for inferior exit before main loop.
20442
20443 2007-07-18 Pedro Alves <pedro_alves@portugalmail.pt>
20444
20445 * remote-utils.c (remote_open): Set SO_KEEPALIVE on remote_desc
20446 instead of on tmp_desc.
20447
20448 2007-07-17 Pedro Alves <pedro_alves@portugalmail.pt>
20449 Daniel Jacobowitz <dan@codesourcery.com>
20450
20451 * inferiors.c (all_dlls, dlls_changed, get_dll): New.
20452 (add_thread): Minor cleanups.
20453 (clear_inferiors): Move lower in the file. Clear the DLL
20454 list.
20455 (free_one_dll, match_dll, loaded_dll, unloaded_dll, clear_list): New.
20456 * remote-utils.c (prepare_resume_reply): Check dlls_changed.
20457 (xml_escape_text): New.
20458 * server.c (handle_query): Handle qXfer:libraries:read. Report it
20459 for qSupported.
20460 (handle_v_cont): Report errors.
20461 (gdbserver_version): Update.
20462 (main): Correct size of own_buf. Do not report initial DLL events.
20463 * server.h (struct dll_info, all_dlls, dlls_changed, loaded_dll)
20464 (unloaded_dll, xml_escape_text): New.
20465 * win32-low.c (enum target_waitkind): Update comments.
20466 (win32_add_one_solib, get_image_name, winapi_EnumProcessModules)
20467 (winapi_GetModuleInformation, winapi_GetModuleFileNameExA)
20468 (win32_EnumProcessModules, win32_GetModuleInformation)
20469 (win32_GetModuleFileNameExA, load_psapi, psapi_get_dll_name)
20470 (winapi_CreateToolhelp32Snapshot, winapi_Module32First)
20471 (winapi_Module32Next, win32_CreateToolhelp32Snapshot)
20472 (win32_Module32First, win32_Module32Next, load_toolhelp)
20473 (toolhelp_get_dll_name, handle_load_dll, handle_unload_dll): New.
20474 (get_child_debug_event): Handle DLL events.
20475 (win32_wait): Likewise.
20476
20477 2007-07-12 Daniel Jacobowitz <dan@codesourcery.com>
20478
20479 * configure.srv: Set srv_linux_regsets for sh*-*-linux*.
20480 * linux-sh-low.c (sh_fill_gregset, target_regsets): New.
20481
20482 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
20483
20484 * win32-low.c (handle_output_debug_string): Ignore event if not
20485 waiting.
20486
20487 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
20488
20489 * win32-arm-low.c (arm_wince_breakpoint): Fix typo.
20490
20491 2007-07-03 Daniel Jacobowitz <dan@codesourcery.com>
20492
20493 * remote-utils.c (look_up_one_symbol): Handle 'm' packets.
20494
20495 2007-07-02 Daniel Jacobowitz <dan@codesourcery.com>
20496
20497 * inferiors.c (change_inferior_id): Add comment.
20498 * linux-low.c (check_removed_breakpoint): Add an early
20499 prototype. Improve debug output.
20500 (linux_attach): Doc update.
20501 (linux_detach_one_process, linux_detach): Clean up before releasing
20502 each process.
20503 (send_sigstop, wait_for_sigstop): Improve comments and debug output.
20504 * linux-low.h (struct process_info): Doc improvement.
20505 * mem-break.c (delete_all_breakpoints): New.
20506 * mem-break.h (delete_all_breakpoints): New prototype.
20507 * thread-db.c (find_first_thread): New.
20508 (thread_db_create_event): Call it instead of
20509 thread_db_find_new_threads. Clean up unused variables.
20510 (maybe_attach_thread): Remove first thread handling.
20511 (thread_db_find_new_threads): Use find_first_thread.
20512 (thread_db_get_tls_address): Likewise.
20513
20514 2007-06-27 Daniel Jacobowitz <dan@codesourcery.com>
20515
20516 * thread-db.c (thread_db_find_new_threads): Add prototype.
20517 (thread_db_create_event): Check for the main thread before adding
20518 a new thread.
20519 (maybe_attach_thread): Only enable event reporting if TID == 0.
20520 (thread_db_get_tls_address): Check for new threads.
20521
20522 2007-06-20 Daniel Jacobowitz <dan@codesourcery.com>
20523
20524 * linux-low.c (linux_create_inferior): Try execv before execvp.
20525 * spu-low.c (spu_create_inferior): Likewise.
20526
20527 2007-06-13 Mike Frysinger <vapier@gentoo.org>
20528
20529 * linux-low.c (linux_create_inferior): Change execv to execvp.
20530 * spu-low.c (spu_create_inferior): Likewies.
20531
20532 2007-06-13 Daniel Jacobowitz <dan@codesourcery.com>
20533
20534 * Makefile.in (clean): Clean new files instead of deleted ones.
20535 (reg-mips.o, reg-mips.c, reg-mips64.o, reg-mips64.c): Delete.
20536 (mips-linux.o, mips-linux.c, mips64-linux.o, mips64-linux.c): New
20537 rules.
20538 * configure.srv: Specify XML files and new regformats for MIPS and
20539 MIPS64 GNU/Linux.
20540 * linux-mips-low.c (mips_num_regs): Set to only used registers.
20541 (mips_regmap): Do not fetch $0. Remove unused registers. Add
20542 an entry for the restart register.
20543 (mips_cannot_fetch_register, mips_cannot_store_register)
20544 (mips_reinsert_addr, mips_fill_fpregset, mips_store_fpregset): Update
20545 register names to match the XML descriptions.
20546 (mips_fill_gregset, mips_store_gregset): Likewise. Handle the
20547 restart register instead of $0.
20548
20549 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
20550 Markus Deuling <deuling@de.ibm.com>
20551
20552 * remote-utils.c (decode_xfer_write): New function.
20553 * server.h (decode_xfer_write): Add prototype.
20554 * server.c (handle_query): Add PACKET_LEN argument. Support
20555 qXfer:spu:read and qXfer:spu:write packets.
20556 (main): Pass packet_len to handle_query.
20557 * spu-low.c (spu_target_ops): Add spu_proc_xfer_spu.
20558 * target.h (target_ops): Add qxfer_spu.
20559
20560 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
20561
20562 * spu-low.c (spu_proc_xfer_spu): Do not return failure when
20563 accessing non-seekable spufs files.
20564
20565 2007-05-16 Markus Deuling <deuling@de.ibm.com>
20566
20567 * server.c (handle_query): Add reply for qC packet.
20568
20569 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20570 Leo Zayas <lerele@champenstudios@com>
20571
20572 * server.h (check_remote_input_interrupt_request): New function.
20573 * remote_utils.c (INVALID_DESCRIPTOR): New define.
20574 (remote_desc): Initialize with INVALID_DESCRIPTOR.
20575 (input_interrupt): Expose on USE_WIN32API too. Fix whitespace.
20576 (check_remote_input_interrupt_request): New function.
20577 * server.h (check_remote_input_interrupt_request): Declare.
20578 * win32-low.c (winapi_DebugBreakProcess,
20579 winapi_GenerateConsoleCtrlEvent): New typedefs.
20580 (get_child_debug_event): Lower Win32 debug event polling from 1 sec
20581 to 250 ms.
20582 (win32_wait): Check for remote interrupt request
20583 with check_remote_input_interrupt_request.
20584 (win32_request_interrupt): New function.
20585 (win32_target_op): Set request_interrupt to win32_request_interrupt.
20586
20587 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20588
20589 * win32-low.c (debug_registers_changed,
20590 debug_registers_used, CONTEXT_EXTENDED_REGISTERS,
20591 CONTEXT_FLOATING_POINT, CONTEXT_DEBUG_REGISTERS,
20592 CONTEXT_DEBUGGER, CONTEXT_DEBUGGER_DR): Delete.
20593 (thread_rec): Get context using the low target.
20594 (child_add_thread): Call thread_added on the low target,
20595 which does the same thing.
20596 (regptr): Delete.
20597 (do_initial_child_stuff): Remove debug registers references.
20598 Set context using the low target. Resume threads after
20599 setting the contexts.
20600 (child_continue): Remove dead variable. Remove debug
20601 registers references.
20602 (child_fetch_inferior_registers): Go through the low target.
20603 (do_child_store_inferior_registers): Remove.
20604 (child_store_inferior_registers): Go through the low target.
20605 (win32_resume): Remove debug registers references.
20606 Set context using the low target.
20607 (handle_exception): Change return type to void. Don't record
20608 context here. Set status to TARGET_WAITKIND_SPURIOUS on a
20609 first chance exception.
20610 (get_child_debug_event): Change return type to void. Remove
20611 goto loop. Always return after waiting for debug event.
20612 (win32_wait): Convert to switch statement. Handle spurious
20613 events.
20614
20615 * win32-i386-low.c (debug_registers_changed,
20616 debug_registers_used): New.
20617 (initial_stuff): Rename to ...
20618 (i386_initial_stuff): ... this. Clear debug registers
20619 state variables.
20620 (store_debug_registers): Delete.
20621 (i386_get_thread_context): New.
20622 (load_debug_registers): Delete.
20623 (i386_set_thread_context): New.
20624 (i386_thread_added): New.
20625 (single_step): Rename to ...
20626 (i386_single_step): ... this.
20627 (do_fetch_inferior_registers): Rename to ...
20628 (i386_fetch_inferior_register): ... this.
20629 (i386_store_inferior_register): New.
20630 (the_low_target): Adapt to new interface.
20631
20632 * win32-arm-low.c (CONTEXT_FLOATING_POINT): Define.
20633 (arm_get_thread_context): New.
20634 (arm_set_thread_context): New.
20635 (regptr): New.
20636 (do_fetch_inferior_registers): Rename to ...
20637 (arm_fetch_inferior_register): ... this.
20638 (arm_store_inferior_register): New.
20639 (arm_wince_breakpoint): Reimplement as unsigned long.
20640 (arm_wince_breakpoint_len): Define.
20641 (the_low_target): Adapt to new interface.
20642
20643 * win32-low.h (target_ops): Remove regmap, store_debug_registers and
20644 load_debug_registers. Add get_thread_context, set_thread_context,
20645 thread_added and store_inferior_register. Rename
20646 fetch_inferior_registers to fetch_inferior_register.
20647 (regptr): Remove declaration.
20648
20649 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20650
20651 * linux-low.c (linux_detach): Change return type to int. Return 0.
20652 * spu-low.c (spu_detach): Likewise.
20653
20654 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20655
20656 * target.h (target_ops): Change return type of detach to int.
20657 Add join.
20658 (join_inferior): New.
20659 * server.c (main): Don't skip detach support on mingw32.
20660 If the inferior doesn't support detaching return error.
20661 Call join_inferior instead of using waitpid.
20662 * linux-low.c (linux_join): New.
20663 (linux_target_op): Add linux_join.
20664 * spu-low.c (spu_join): New.
20665 (spu_target_ops): Add spu_join.
20666 * win32-low.c (win32_detach): Adapt to new interface.
20667 Reopen current_process_handle before detaching. Issue a child
20668 resume before detaching.
20669 (win32_join): New.
20670 (win32_target_op): Add win32_join.
20671
20672 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20673
20674 * win32-low.c (win32-attach): Fix return value.
20675 * target.h (target_ops): Describe ATTACH return values.
20676
20677 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20678
20679 * win32-low.c (GETPROCADDRESS): Define.
20680 (winapi_DebugActiveProcessStop): Add WINAPI. typedef as pointer.
20681 (winapi_DebugSetProcessKillOnExit): Likewise.
20682 (win32_create_inferior): Force usage of ansi CreateProcessA.
20683 (win32_attach): Use GETPROCADDRESS.
20684 (win32_detach): Likewise.
20685
20686 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20687
20688 * win32-low.c (win32_wait): Don't use WSTOPSIG.
20689
20690 2007-03-30 Pedro Alves <pedro_alves@portugalmail.pt>
20691
20692 * win32-low.c: Commit leftover changes from 2007-03-29.
20693
20694 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
20695
20696 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Make 16-bit
20697 fields short instead of int. Add explicit padding.
20698 (i387_cache_to_fsave): Remove unnecessary casts.
20699 (i387_fsave_to_cache): Doc fix.
20700 (i387_cache_to_fxsave): Remove unnecessary casts and masking.
20701
20702 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
20703
20704 * i387-fp.c (i387_cache_to_fxsave): Reinitialize val2 before use.
20705 (i387_fxsave_to_cache): Check fp->ftag while building ftag value.
20706
20707 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
20708
20709 * configure.srv (arm*-*-mingw32ce*): Move near the other
20710 arm targets.
20711
20712 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
20713
20714 * configure.ac: Add errno checking.
20715 (AC_CHECK_HEADERS): Add errno.h, fcntl.h, signal.h,
20716 sys/file.h and malloc.h.
20717 (AC_CHECK_DECLS): Add perror.
20718 (srv_mingwce): Handle.
20719 * configure.srv (i[34567]86-*-cygwin*): Add
20720 win32-i386-low.o to srv_tgtobj.
20721 (i[34567]86-*-mingw*): Likewise.
20722 (arm*-*-mingw32ce*): Add case.
20723 * gdbreplay.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
20724 HAVE_FCNTL_H, HAVE_ERRNO_H, HAVE_MALLOC_H]: Check.
20725 [__MINGW32CE__] (strerror): New function.
20726 [__MINGW32CE__] (errno): Define to GetLastError.
20727 [__MINGW32CE__] (COUNTOF): New macro.
20728 (remote_open): Remove extra close call.
20729 * mem-break.c (delete_breakpoint_at): New function.
20730 * mem-break.h (delete_breakpoint_at): Declare.
20731 * remote-utils.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
20732 HAVE_FCNTL_H, HAVE_UNISTD_H, HAVE_ERRNO_H]: Check.
20733 [USE_WIN32API] (read, write): Add char* casts.
20734 * server.c [HAVE_UNISTD_H, HAVE_SIGNAL_H]: Check.
20735 * server.h: Include wincecompat.h on Windows CE.
20736 [HAVE_ERRNO_H]: Check.
20737 (perror): Declare if not declared.
20738 * utils.c: Add stdlib.h, errno.h and malloc.h includes.
20739 (perror_with_name): Remove errno declaration.
20740 * wincecompat.h: New.
20741 * wincecompat.c: New.
20742 * win32-low.h: New.
20743 * win32-arm-low.c: New.
20744 * win32-i386-low.c: New.
20745 (win32-low.c): Include mem-break.h and win32-low.h, and winnt.h.
20746 (OUTMSG2): Make it safe.
20747 (_T): New macro.
20748 (COUNTOF): New macro.
20749 (NUM_REGS): Get it from the low target.
20750 (CONTEXT_EXTENDED_REGISTERS, CONTEXT_FLOATING_POINT,
20751 CONTEXT_DEBUG_REGISTERS): Add fallbacks to 0.
20752 (thread_rec): Let low target handle debug registers.
20753 (child_add_thread): Likewise.
20754 (child_init_thread_list): Likewise.
20755 (continue_one_thread): Likewise.
20756 (regptr): New.
20757 (do_child_fetch_inferior_registers): Move to ...
20758 * win32-i386-low.c: ... here, and rename to ...
20759 (do_fetch_inferior_registers): ... this.
20760 * win32-low.c (child_fetch_inferior_registers):
20761 Go through the low target.
20762 (do_child_store_inferior_registers): Use regptr.
20763 (strwinerror): New function.
20764 (win32_create_inferior): Handle Windows CE.
20765 Use strwinerror instead of strerror on Windows error
20766 codes. Add program to the error output.
20767 Don't close the main thread handle on Windows CE.
20768 (win32_attach): Use coredll.dll on Windows CE.
20769 (win32_kill): Close current process and current
20770 thread handles.
20771 (win32_detach): Use coredll.dll on Windows CE.
20772 (win32_resume): Let low target handle debug registers, and
20773 step request.
20774 (handle_exception): Add/Remove initial breakpoint. Avoid
20775 non-existant WSTOPSIG on Windows CE.
20776 (win32_read_inferior_memory): Cast to remove warning.
20777 (win32_arch_string): Go through the low target.
20778 (initialize_low): Call set_breakpoint_data with the low
20779 target's breakpoint.
20780 * win32-low.c (dr, FLAG_TRACE_BIT, FCS_REGNUM,
20781 FOP_REGNUM, mappings): Move to ...
20782 * win32-i386-low.c: ... here.
20783 * win32-low.c (win32_thread_info): Move to ...
20784 * win32-low.h: ... here.
20785 * Makefile.in (SFILES): Add win32-low.c, win32-i386-low.c,
20786 win32-arm-low.c and wincecompat.c.
20787 (all:): Add $EXEEXT.
20788 (install-only:): Likewise.
20789 (gdbserver:): Likewise.
20790 (gdbreplay:): Likewise.
20791 * config.in: Regenerate.
20792 * configure: Regenerate.
20793
20794 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
20795
20796 * win32-low.c: Rename typedef thread_info to
20797 win32_thread_info throughout.
20798
20799 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
20800
20801 * win32-i386-low.c: Rename to ...
20802 * win32-low.c: ... this.
20803 * configure.srv: Replace win32-i386-low.o with win32-low.o.
20804 * Makefile.in: Likewise.
20805
20806 2007-03-27 Pedro Alves <pedro_alves@portugalmail.pt>
20807
20808 * remote-utils.c (monitor_output): Constify msg parameter.
20809 * server.h (monitor_output): Likewise.
20810 * win32-i386-low.c (handle_output_debug_string): New.
20811 (win32_kill): Handle OUTPUT_DEBUG_STRING_EVENT events using
20812 handle_output_debug_string.
20813 (get_child_debug_event): Likewise.
20814
20815 2007-03-27 Mat Hostetter <mat@lcs.mit.edu>
20816
20817 * server.c (main): Correct strtoul check.
20818
20819 2007-03-27 Jon Ringle <jon@ringle.org>
20820
20821 * linux-low.c: Check __ARCH_HAS_MMU__ also.
20822
20823 2007-03-27 Brooks Moses <brooks.moses@codesourcery.com>
20824
20825 * Makefile.in: Add dummy "pdf" and "install-pdf" targets.
20826
20827 2007-02-27 Daniel Jacobowitz <dan@codesourcery.com>
20828
20829 * terminal.h: Check HAVE_SGTTY_H.
20830
20831 2007-02-27 Mat Hostetter <mat@lcs.mit.edu>
20832
20833 * remote-utils.c (remote_open): Print out the assigned port number.
20834
20835 2007-02-26 Daniel Jacobowitz <dan@codesourcery.com>
20836
20837 * remote-utils.c (monitor_output): New function.
20838 * server.c (debug_threads): Define here.
20839 (monitor_show_help): New function.
20840 (handle_query): Handle qRcmd.
20841 (main): Do not handle 'd' packet.
20842 * server.h (debug_threads, remote_debug, monitor_output): Declare.
20843 * linux-low.c, spu-low.c, win32-i386-low.c: Remove definitions
20844 of debug_threads.
20845
20846 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
20847
20848 * Makefile.in (EXEEXT): New.
20849 (clean): Use $(EXEEXT).
20850
20851 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
20852
20853 * target.h (target_ops): Rename send_signal to request_interrupt,
20854 and remove enum target_signal parameter.
20855 * linux-low.c (linux_request_interrupt): Rename from
20856 linux_send_signal, and always send SIGINT.
20857 * spu-low.c (spu_request_interrupt): Rename from spu_send_signal,
20858 and always send SIGINT.
20859 * remote-utils.c (putpkt_binary): Call request_interrupt, instead
20860 of send_signal.
20861 (input_interrupt): Likewise.
20862
20863 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
20864
20865 * server.c (get_features_xml): Check if target implemented
20866 arch_string.
20867 * win32-i386-low.c (win32_arch_string): New.
20868 (win32_target_ops): Add win32_arch_string as arch_string member.
20869
20870 2007-02-22 Markus Deuling <deuling@de.ibm.com>
20871
20872 * spu-low.c (spu_arch_string): New.
20873 (spu_target_ops): Add spu_arch_string.
20874
20875 2007-02-16 Daniel Jacobowitz <dan@codesourcery.com>
20876
20877 * remote-utils.c: Remove HAVE_TERMINAL_H check.
20878 * configure.ac: Do not check for terminal.h.
20879 * configure, config.in: Regenerated.
20880
20881 2007-02-08 Daniel Jacobowitz <dan@codesourcery.com>
20882
20883 * Makefile.in (OBS): Add $(XML_BUILTIN).
20884 (XML_DIR, XML_TARGET, XML_FILES, XML_BUILTIN): New.
20885 (clean): Update.
20886 (target.xml, xml-builtin.c, stamp-xml, arm-with-iwmmxt.o)
20887 (arm-with-iwmmxt.c): New.
20888 * config.in, configure: Regenerate.
20889 * configure.ac: Check for iWMMXt. Handle srv_xmltarget,
20890 srv_xmlbuiltin, and srv_xmlfiles. Define USE_XML.
20891 * configure.srv: Mention srv_xmltarget and srv_xmlfiles.
20892 (arm*-*-linux*): Add iWMMXt and regset support.
20893 * linux-arm-low.c (PTRACE_GETWMMXREGS, PTRACE_SETWMMXREGS): Define.
20894 (arm_fill_gregset, arm_store_gregset, arm_fill_wmmxregset)
20895 (arm_store_wmmxregset, target_regsets): New.
20896 * server.c (get_features_xml): Take annex argument. Check builtin
20897 XML documents.
20898 (handle_query): Handle multiple annexes.
20899
20900 2007-01-29 Daniel Jacobowitz <dan@codesourcery.com>
20901
20902 * remote-utils.c [USE_WIN32API] (read, write): Define.
20903 (putpkt_binary, input_interrupt, readchar, getpkt): Use read and
20904 write.
20905
20906 2007-01-09 Daniel Jacobowitz <dan@codesourcery.com>
20907
20908 * linux-i386-low.c (the_low_target): Set arch_string.
20909 * linux-x86-64-low.c (the_low_target): Likewise.
20910 * linux-low.c (linux_arch_string): New.
20911 (linux_target_ops): Add it.
20912 * linux-low.h (struct linux_target_ops): Add arch_string.
20913 * server.c (write_qxfer_response): Use const void * for DATA.
20914 (get_features_xml): New.
20915 (handle_query): Handle qXfer:features:read. Report it for qSupported.
20916 * target.h (struct target_ops): Add arch_string method.
20917
20918 2007-01-03 Denis Pilat <denis.pilat@st.com>
20919 Daniel Jacobowitz <dan@codesourcery.com>
20920
20921 * linux-low.c (linux_kill): Handle being called with no threads.
20922 * win32-i386-low.c (win32_kill): Likewise.
20923 (get_child_debug_event): Clear current_process_handle.
20924
20925 2006-12-30 Denis PILAT <denis.pilat@st.com>
20926 Daniel Jacobowitz <dan@codesourcery.com>
20927
20928 * remote-utils.c (remote_open): Check the type of specified
20929 serial port devices before opening them.
20930 * server.c (main): Kill the inferior if an error occurs during
20931 the first remote_open.
20932
20933 2006-12-05 Markus Deuling <deuling@de.ibm.com>
20934
20935 * README: Update supported targets.
20936
20937 2006-11-28 Daniel Jacobowitz <dan@codesourcery.com>
20938
20939 * Makefile.in (clean): Remove reg-mips64.c.
20940 (reg-mips64.c, reg-mips64.o): New rules.
20941 * configure.srv: Handle mips64. Include regset support for mips.
20942 * linux-mips-low.c (union mips_register): New.
20943 (mips_get_pc, mips_set_pc, mips_reinsert_addr): Use it.
20944 (mips_breakpoint, mips_breakpoint_at): Use int.
20945 (mips_collect_register, mips_supply_register)
20946 (mips_collect_register_32bit, mips_supply_register_32bit)
20947 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
20948 (mips_store_fpregset, target_regsets): New.
20949 * thread-db.c (thread_db_get_tls_address): Use uintptr_t.
20950
20951 2006-11-22 Ulrich Weigand <uweigand@de.ibm.com>
20952
20953 * configure.srv: Add target "spu*-*-*".
20954 * Makefile.in (clean): Remove reg-spu.c.
20955 (reg-spu.c, reg-spu.o, spu-low.o): Add dependencies.
20956 * spu-low.c: New file.
20957
20958 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
20959
20960 * configure.ac: Correct td_thr_tls_get_addr test.
20961 * configure: Regenerated.
20962
20963 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
20964
20965 * linux-low.c (linux_wait_for_event): Reformat. Use the
20966 pass_signals array.
20967 * remote-utils.c (decode_address_to_semicolon): New.
20968 * server.c (pass_signals, handle_general_set): New.
20969 (handle_query): Mention QPassSignals for qSupported.
20970 (main): Call handle_general_set.
20971 * server.h (pass_signals, decode_address_to_semicolon): New.
20972
20973 2006-11-06 Daniel Jacobowitz <dan@codesourcery.com>
20974
20975 * server.c (handle_query): Correct error handling for read_auxv.
20976
20977 2005-10-19 Ulrich Weigand <uweigand@de.ibm.com>
20978
20979 * configure.srv [s390-*-linux*, s390x-*-linux*]: Set srv_linux_regsets
20980 and srv_linux_thread_db to yes.
20981 * linux-s390-low.c (s390_fill_gregset): New function.
20982 (target_regsets): Define data structure.
20983
20984 2006-10-17 Daniel Jacobowitz <dan@codesourcery.com>
20985
20986 * acinclude.m4 (SRV_CHECK_TLS_GET_ADDR): New.
20987 * configure.ac: Use it. Define HAVE_TD_THR_TLS_GET_ADDR.
20988 * config.in, configure: Regenerated.
20989 * inferiors.c (gdb_id_to_thread): New function.
20990 (gdb_id_to_thread_id): Use it.
20991 * linux-low.c (linux_target_ops): Use thread_db_get_tls_address.
20992 * linux-low.h (struct process_info): Add th member.
20993 (thread_db_get_tls_address): New prototype.
20994 * remote-utils.c (decode_address): Make non-static.
20995 * server.c (handle_query): Handle qGetTLSAddr.
20996 * server.h (gdb_id_to_thread, decode_address): New prototypes.
20997 * target.h (struct target_ops): Add get_tls_address.
20998 * thread-db.c (maybe_attach_thread): Save the thread handle.
20999 (thread_db_get_tls_address): New.
21000
21001 2006-09-28 Daniel Jacobowitz <dan@codesourcery.com>
21002
21003 * linux-low.c (PTRACE_GETSIGINFO, PTRACE_SETSIGINFO): Define.
21004 (linux_resume_one_process): Take a siginfo_t *. Update all
21005 callers. Queue it if necessary. Use PTRACE_SETSIGINFO.
21006 (struct pending_signals): Add a siginfo_t.
21007 (linux_wait_for_process): Always set last_status.
21008 (linux_wait_for_event): Use PTRACE_GETSIGINFO.
21009 (linux_queue_one_thread): Use PTRACE_GETSIGINFO.
21010 * linux-low.h (struct process_info): Add last_status.
21011
21012 2006-09-21 Daniel Jacobowitz <dan@codesourcery.com>
21013
21014 * remote-utils.c (try_rle): New function.
21015 (putpkt_binary): Use it.
21016
21017 2006-08-19 Daniel Jacobowitz <dan@codesourcery.com>
21018
21019 * Makefile.in (clean): Clean reg-x86-64-linux.c.
21020 (reg-x86-64-linux.o, reg-x86-64-linux.c): New.
21021 * configure.srv (x86_64-*-linux*): Use reg-x86-64-linux.o.
21022 * linux-x86-64-low.c (x86_64_regmap): Include ORIG_RAX.
21023 (x86_64_fill_gregset, x86_64_store_gregset): Skip floating
21024 point registers.
21025
21026 2006-08-08 Richard Sandiford <richard@codesourcery.com>
21027
21028 * server.c (terminal_fd): New variable.
21029 (old_foreground_pgrp): Likewise.
21030 (restore_old_foreground_pgrp): New function.
21031 (start_inferior): Record the terminal file descriptor in terminal_fd
21032 and its original foreground group in old_foreground_pgrp. Register
21033 restore_old_foreground_pgrp with atexit().
21034
21035 2006-07-26 Daniel Jacobowitz <dan@codesourcery.com>
21036
21037 * server.c (handle_query): Correct qPart to qXfer.
21038
21039 2006-07-22 Daniel Jacobowitz <dan@codesourcery.com>
21040
21041 * configure.ac: Check for more headers which are missing on
21042 Windows. Automatically supply -lwsock32 and USE_WIN32API.
21043 * configure.srv: Add Cygwin and mingw32.
21044 * remote-utils.c: Don't include headers unconditionally which
21045 are missing on mingw32. Include <winsock.h> for mingw32.
21046 (remote_open): Adjust for mingw32 support. Flush
21047 standard error after writing to it.
21048 (remote_close, putpkt_binary, input_interrupt, block_async_io)
21049 (unblock_async_io, enable_async_io, disable_async_io)
21050 (readchar, getpkt): Update for Winsock support.
21051 (prepare_resume_reply): Expect a protocol signal number.
21052 * server.c: Disable <sys/wait.h> on mingw32.
21053 (start_inferior): Adjust for mingw32 support. Flush
21054 standard error after writing to it.
21055 (attach_inferior): Likewise. Use protocol signal
21056 numbers.
21057 (main): Skip 'D' packet on mingw32. Use protocol signal numbers
21058 and names.
21059 * win32-i386-low.c: New file.
21060 * Makefile.in (XM_CLIBS): Set.
21061 (gdbserver, gdbreplay): Use $(INTERNAL_CFLAGS).
21062 (win32-i386-low.o): New dependency rule.
21063 * linux-low.c (linux_wait): Use target signal numbers.
21064 * target.h (struct target_ops): Doc fix.
21065 * server.h (target_signal_to_name): New prototype.
21066 * gdbreplay.c: Don't include headers unconditionally which
21067 are missing on mingw32. Include <winsock.h> for mingw32.
21068 (remote_close, remote_open): Adjust for Winsock support.
21069 * configure, config.in: Regenerated.
21070
21071 2006-07-12 Daniel Jacobowitz <dan@codesourcery.com>
21072
21073 * server.c (decode_xfer_read, write_qxfer_response): New.
21074 (handle_query): Take a packet length argument. Handle
21075 qXfer:auxv:read instead of qPart:auxv:read. Mention it in
21076 the qSupported response.
21077 (main): Update call to handle_query.
21078
21079 2006-06-22 Daniel Jacobowitz <dan@codesourcery.com>
21080
21081 * remote-utils.c (remote_escape_output, remote_unescape_input): New.
21082 (putpkt_binary): Renamed from putpkt and adjusted for binary
21083 data.
21084 (putpkt): New wrapper for putpkt_binary.
21085 (readchar): Don't mask off the high bit.
21086 (decode_X_packet): New function.
21087 * server.c (main): Call putpkt_binary if a handler sets the packet
21088 length. Save the length of the incoming packet. Handle 'X'.
21089 * server.h (gdb_byte, remote_escape_output, decode_X_packet): New.
21090
21091 2006-06-21 Daniel Jacobowitz <dan@codesourcery.com>
21092
21093 * server.c (handle_query): Handle qSupported.
21094
21095 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
21096
21097 * remote-utils.c (all_symbols_looked_up): New variable.
21098 (look_up_one_symbol): Check it.
21099 * server.h (look_up_one_symbol): New declaration.
21100 * thread-db.c (thread_db_init): Set all_symbols_looked_up.
21101
21102 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
21103
21104 * Makefile.in (linux-arm-low.o): Update dependencies.
21105 * linux-arm-low.c: Include "gdb_proc_service.h".
21106 (PTRACE_GET_THREAD_AREA): Define.
21107 (ps_get_thread_area): New function.
21108
21109 2006-05-09 Nathan Sidwell <nathan@codesourcery.com>
21110
21111 * configure.srv (m68k*-*-uclinux*): New target.
21112 * linux-low.c (linux_create_inferior): Use vfork on mmuless systems.
21113 (linux_resume_one_process): Remove extraneous cast.
21114 (linux_read_offsets): New.
21115 (linux_target_op): Add linux_read_offsets on mmuless systems.
21116 * server.c (handle_query): Add qOffsets logic.
21117 * target.h (struct target_ops): Add read_offsets.
21118
21119 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
21120
21121 * linux-mips-low.c: Include <sys/ptrace.h> and "gdb_proc_service.h".
21122 (PTRACE_GET_THREAD_AREA): Define.
21123 (ps_get_thread_area): New function.
21124 * Makefile.in (linux-i386-low.o, linux-mips-low.o)
21125 (linux-x86-64-low.o): Update.
21126
21127 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
21128
21129 * configure.ac: Remove checks for prfpregset_t.
21130 * gdb_proc_service.h: New file.
21131 * linux-i386-low.c, linux-x86-64-low.c, thread-db.c: Use the
21132 new "gdb_proc_service.h".
21133 * proc-service.c: Likewise.
21134 (ps_pglobal_lookup, ps_pdread, ps_pdwrite): Use psaddr_t.
21135 (ps_lgetfpregs, ps_lsetfpregs): Use a void* argument.
21136 * Makefile.in (gdb_proc_service_h): Updated.
21137 * configure, config.in: Regenerated.
21138
21139 2006-03-03 Daniel Jacobowitz <dan@codesourcery.com>
21140
21141 * remote-utils.c (prepare_resume_reply): Move declaration
21142 of gdb_id_from_wait to the top of the block.
21143
21144 2006-02-15 Daniel Jacobowitz <dan@codesourcery.com>
21145
21146 * linux-low.c (regsets_store_inferior_registers): Read the regset
21147 from the target before filling it.
21148
21149 2006-02-08 Daniel Jacobowitz <dan@codesourcery.com>
21150
21151 * server.c (attach_inferior): Return SIGTRAP for a successful
21152 attach.
21153
21154 2006-02-01 Daniel Jacobowitz <dan@codesourcery.com>
21155
21156 * Makefile.in (OBS): Add version.o.
21157 (STAGESTUFF): Delete.
21158 (version.o): Add dependencies.
21159 (version.c): Replace rule.
21160 (clean): Remove version.c.
21161 * server.c (gdbserver_version): New.
21162 (gdbserver_usage): Use printf.
21163 (main): Handle --version and --help.
21164 * server.h (version, host_name): Add declarations.
21165
21166 2005-12-23 Eli Zaretskii <eliz@gnu.org>
21167
21168 * linux-arm-low.c:
21169 * linux-arm-low.c:
21170 * inferiors.c:
21171 * i387-fp.h:
21172 * i387-fp.c:
21173 * gdbreplay.c:
21174 * regcache.c:
21175 * proc-service.c:
21176 * mem-break.h:
21177 * mem-break.c:
21178 * linux-x86-64-low.c:
21179 * linux-sh-low.c:
21180 * linux-s390-low.c:
21181 * linux-ppc64-low.c:
21182 * linux-ppc-low.c:
21183 * linux-mips-low.c:
21184 * linux-m68k-low.c:
21185 * linux-m32r-low.c:
21186 * linux-low.h:
21187 * linux-low.c:
21188 * linux-ia64-low.c:
21189 * linux-i386-low.c:
21190 * linux-crisv32-low.c:
21191 * thread-db.c:
21192 * terminal.h:
21193 * target.h:
21194 * target.c:
21195 * server.h:
21196 * server.c:
21197 * remote-utils.c:
21198 * regcache.h:
21199 * utils.c:
21200 * Makefile.in:
21201 * configure.ac:
21202 * gdbserver.1: Add (C) after Copyright. Update the FSF
21203 address.
21204
21205 2005-11-13 Daniel Jacobowitz <dan@codesourcery.com>
21206
21207 * linux-arm-low.c (arm_eabi_breakpoint): New variable.
21208 (arm_breakpoint_at): Recognize both breakpoints.
21209 (the_low_target): Use the correct breakpoint instruction.
21210
21211 2005-11-02 Daniel Jacobowitz <dan@codesourcery.com>
21212
21213 * configure.srv (x86_64-*-linux*): Turn on thread_db support.
21214 * linux-x86-64-low.c (x86_64_breakpoint, x86_64_breakpoint_len)
21215 (x86_64_get_pc, x86_64_set_pc, x86_64_breakpoint_at): New.
21216 (the_low_target): Update.
21217
21218 2005-10-25 Andreas Schwab <schwab@suse.de>
21219
21220 * server.c (main): Allocate mem_buf with PBUFSIZ bytes.
21221
21222 * linux-ia64-low.c (ia64_regmap): Remove NAT registers.
21223 (ia64_num_regs): Reduce to 462.
21224
21225 2005-09-17 Daniel Jacobowitz <dan@codesourcery.com>
21226
21227 * acinclude.m4: Correct quoting.
21228 * aclocal.m4: Regenerated.
21229
21230 Suggested by SZOKOVACS Robert <szo@ies.hu>:
21231 * thread-db.c (thread_db_err_str): Handle TD_VERSION.
21232 (thread_db_init): Call thread_db_err_str.
21233 * configure.ac: Check for TD_VERSION.
21234 * config.in, configure: Regenerated.
21235
21236 2005-07-31 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
21237
21238 * server.h (error, fatal, warning): Add ATTR_FORMAT.
21239
21240 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
21241
21242 * configure.ac: Define HAVE_LINUX_REGSETS even if PTRACE_GETREGS
21243 is not available. Define HAVE_PTRACE_GETREGS if it is.
21244 * config.in, configure: Regenerated.
21245 * configure.srv: Set srv_linux_regsets for PowerPC and PowerPC64.
21246 * linux-i386-low.c, linux-m68k-low.c: Update to use
21247 HAVE_PTRACE_GETREGS.
21248 * linux-low.c (regsets_fetch_inferior_registers)
21249 (regsets_store_inferior_registers): Only return 0 if we processed
21250 GENERAL_REGS.
21251 * linux-ppc-low.c (ppc_fill_gregset, target_regsets): New.
21252 * linux-ppc64-low.c (ppc_fill_gregset, target_regsets): New.
21253
21254 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
21255
21256 * inferiors.c (struct thread_info): Add gdb_id.
21257 (add_thread): Add gdb_id argument.
21258 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New.
21259 * linux-low.c (linux_create_inferior, linux_attach_lwp): Update
21260 calls to add_thread.
21261 * remote-utils.c (prepare_resume_reply: Use thread_to_gdb_id.
21262 * server.c (handle_query): Use thread_to_gdb_id.
21263 (handle_v_cont, main): Use gdb_id_to_thread_id.
21264 * server.h (add_thread): Update prototype.
21265 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New
21266 prototypes.
21267
21268 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
21269
21270 * linux-low.c (fetch_register, usr_store_inferior_registers): Handle
21271 left-padded registers.
21272 * linux-low.h (struct linux_target_ops): Add left_pad_xfer.
21273 * linux-ppc64-low.c (the_low_target): Set left_pad_xfer.
21274
21275 2005-07-01 Steve Ellcey <sje@cup.hp.com>
21276
21277 * configure.ac (BFD_NEED_DECLARATION): Replace with AC_CHECK_DECLS.
21278 * configure: Regenerate.
21279 * config.in: Regenerate.
21280 * server.h (NEED_DECLARATION_STRERROR):
21281 Replace with !HAVE_DECL_STRERROR.
21282
21283 2005-06-16 Daniel Jacobowitz <dan@codesourcery.com>
21284
21285 * linux-low.c (linux_wait, linux_send_signal): Don't test
21286 an unsigned long variable for > 0 if it could be MAX_ULONG.
21287 * server.c (myresume): Likewise.
21288 * target.c (set_desired_inferior): Likewise.
21289
21290 2005-06-13 Mark Kettenis <kettenis@gnu.org>
21291
21292 * configure.ac: Simplify and improve check for socklen_t.
21293 * configure, config.in: Regenerate.
21294
21295 2005-06-12 Daniel Jacobowitz <dan@codesourcery.com>
21296
21297 * acconfig.h: Remove.
21298 * configure.ac: Add a test for socklen_t. Use three-argument
21299 AC_DEFINE throughout.
21300 * config.in: Regenerated using autoheader 2.59.
21301 * configure: Regenerated.
21302
21303 * gdbreplay.c (socklen_t): Provide a default.
21304 (remote_open): Use socklen_t.
21305 * remote-utils.c (socklen_t): Provide a default.
21306 (remote_open): Use socklen_t.
21307 (convert_int_to_ascii, convert_ascii_to_int, decode_M_packet): Use
21308 unsigned char.
21309
21310 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Use unsigned
21311 char for buffers.
21312 * linux-low.c (linux_read_memory, linux_write_memory)
21313 (linux_read_auxv): Likewise.
21314 * mem-break.c (breakpoint_data, set_breakpoint_data, check_mem_read)
21315 (check_mem_write): Likewise.
21316 * mem-break.h (set_breakpoint_data, check_mem_read, check_mem_write):
21317 Likewise.
21318 * regcache.c (struct inferior_rgcache_data, registers_to_string)
21319 (registers_from_string, register_data): Likewise.
21320 * server.c (handle_query, main): Likewise.
21321 * server.h (convert_ascii_to_int, convert_int_to_ascii)
21322 (decode_M_packet): Likewise.
21323 * target.c (read_inferior_memory, write_inferior_memory): Likewise.
21324 * target.h (struct target_ops): Update read_memory, write_memory,
21325 and read_auxv.
21326 (read_inferior_memory, write_inferior_memory): Update.
21327 * linux-low.h (struct linux_target_ops): Change type of breakpoint
21328 to unsigned char *.
21329 * linux-arm-low.c, linux-cris-low.c, linux-crisv32-low.c,
21330 linux-i386-low.c, linux-m32r-low.c, linux-m68k-low.c,
21331 linux-mips-low.c, linux-ppc-low.c, linux-ppc64-low.c,
21332 linux-s390-low.c, linux-sh-low.c: Update for changes in
21333 read_inferior_memory and the_low_target->breakpoint.
21334
21335 2005-05-28 Daniel Jacobowitz <dan@codesourcery.com>
21336
21337 * Makefile.in (SFILES): Add linux-ppc64-low.c.
21338 (linux-ppc64-low.o, reg-ppc64.c, reg-ppc64.o): New targets.
21339 * configure.srv: Add powerpc64-*-linux*.
21340 * linux-ppc64-low.c: New file.
21341
21342 2005-05-23 Orjan Friberg <orjanf@axis.com>
21343
21344 * linux-cris-low.c: New file with support for CRIS.
21345 * linux-crisv32-low.c: Ditto for CRISv32.
21346 * Makefile.in (SFILES): Add linux-cris-low.c, linux-crisv32-low.c.
21347 (clean): Add reg-cris.c and reg-crisv32.c.
21348 Add linux-cris-low.o, linux-crisv32-low.o, reg-cris.o, reg-cris.c,
21349 reg-crisv32.o, and reg-crisv32.c to make rules.
21350 * configure.srv: Add cris-*-linux* and crisv32-*-linux* to list of
21351 recognized targets.
21352
21353 2005-05-16 Ulrich Weigand <uweigand@de.ibm.com>
21354
21355 * linux-low.c (fetch_register): Ensure buffer size is a multiple
21356 of sizeof (PTRACE_XFER_TYPE).
21357 (usr_store_inferior_registers): Likewise. Zero out excess bytes.
21358
21359 2005-05-12 Orjan Friberg <orjanf@axis.com>
21360
21361 * target.h (struct target_ops): Add insert_watchpoint,
21362 remove_watchpoint, stopped_by_watchpoint, stopped_data_address function
21363 pointers for hardware watchpoint support.
21364 * linux-low.h (struct linux_target_ops): Ditto.
21365 * linux-low.c (linux_insert_watchpoint, linux_remove_watchpoint)
21366 (linux_stopped_by_watchpoint, linux_stopped_data_address): New. Add
21367 to linux_target_ops.
21368 * remote-utils.c (prepare_resume_reply): Add watchpoint information to
21369 reply packet.
21370 * server.c (main): Recognize 'Z' and 'z' packets.
21371
21372 2005-05-10 Ulrich Weigand <uweigand@de.ibm.com>
21373
21374 * linux-s390-low.c (s390_breakpoint, s390_breakpoint_len): Define.
21375 (s390_get_pc, s390_set_pc, s390_breakpoint_at): New functions.
21376 (the_low_target): Add new members.
21377
21378 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
21379
21380 * proc-service.c (ps_lgetregs): Search all_processes instead of
21381 all_threads.
21382
21383 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
21384
21385 * server.c (start_inferior): Change return type to int.
21386 (attach_inferior): Change sigptr to int *.
21387 (handle_v_cont, handle_v_requests): Change signal to int *.
21388 (main): Change signal to int.
21389
21390 2005-04-15 Kei Sakamoto <sakamoto.kei@renesas.com>
21391
21392 * Makefile.in: Add linux-m32r-low.o, reg-m32r.c and reg-m32r.o.
21393 * configure.srv: Add m32r*-*-linux*.
21394 * linux-m32r-low.c: New file.
21395
21396 2005-03-04 Daniel Jacobowitz <dan@codesourcery.com>
21397
21398 * Makefile.in (stamp-h): Set CONFIG_HEADERS explicitly.
21399
21400 2005-03-03 Daniel Jacobowitz <dan@codesourcery.com>
21401
21402 * inferiors.c (change_inferior_id, add_thread, find_inferior_id):
21403 Take unsigned long arguments for PIDs.
21404 * linux-low.c (add_process, linux_attach_lwp, linux_attach)
21405 (linux_thread_alive, linux_wait_for_event, kill_lwp, send_sigstop)
21406 (wait_for_sigstop, linux_resume_one_process)
21407 (regsets_fetch_inferior_registers, linux_send_signal)
21408 (linux_read_auxv): Likewise. Update the types of variables holding
21409 PIDs. Update format string specifiers.
21410 * linux-low.h (struct process_info, linux_attach_lwp): Likewise.
21411 * remote-utils.c (prepare_resume_reply): Likewise.
21412 * server.c (cont_thread, general_thread, step_thread)
21413 (thread_from_wait, old_thread_from_wait, signal_pid): Change type to
21414 unsigned long.
21415 (handle_query): Update format specifiers.
21416 (handle_v_cont, main): Use strtoul for thread IDs.
21417 * server.h (struct inferior_list_entry): Use unsigned long for ID.
21418 (add_thread, find_inferior_id, change_inferior_id, cont_thread)
21419 (general_thread, step_thread, thread_from_wait)
21420 (old_thread_from_wait): Update.
21421 * target.h (struct thread_resume): Use unsigned long for THREAD.
21422 (struct target_ops): Use unsigned long for arguments to attach and
21423 thread_alive.
21424
21425 2005-02-24 Daniel Jacobowitz <dan@codesourcery.com>
21426
21427 * acinclude.m4: Include bfd/bfd.m4 directly.
21428 * configure.ac: Use AC_ARG_PROGRAM. Suggested by Aron Griffis
21429 <agriffis@toolchain.org>.
21430 * aclocal.m4, configure: Regenerated.
21431
21432 2005-01-07 Andrew Cagney <cagney@gnu.org>
21433
21434 * configure.ac: Rename configure.in, require autoconf 2.59.
21435 * configure: Re-generate.
21436
21437 2004-12-08 Daniel Jacobowitz <dan@debian.org>
21438
21439 * acinclude.m4 (SRV_CHECK_THREAD_DB): Add ps_get_thread_area. Reset
21440 LIBS when finished.
21441 * aclocal.m4: Regenerated.
21442 * configure: Regenerated.
21443
21444 2004-11-21 Andreas Schwab <schwab@suse.de>
21445
21446 * linux-m68k-low.c (m68k_num_gregs): Define.
21447 (m68k_fill_gregset, m68k_store_gregset, m68k_fill_fpregset)
21448 (m68k_store_fpregset, target_regsets) [HAVE_LINUX_REGSETS]: New.
21449 (m68k_breakpoint, m68k_breakpoint_len, m68k_get_pc, m68k_set_pc)
21450 (m68k_breakpoint_at): New. Add to the_low_target.
21451
21452 * configure.srv (m68*-*-linux*): Set srv_linux_regsets and
21453 srv_linux_thread_db to yes.
21454
21455 2004-10-20 Joel Brobecker <brobecker@gnat.com>
21456
21457 * linux-x86-64-low.c (ARCH_SET_GS): Add definition if missing.
21458 (ARCH_SET_FS): Likewise.
21459 (ARCH_GET_FS): Likewise.
21460 (ARCH_GET_GS): Likewise.
21461
21462 2004-10-16 Daniel Jacobowitz <dan@debian.org>
21463
21464 * linux-i386-low.c (ps_get_thread_area): New.
21465 * linux-x86-64-low.c (ps_get_thread_area): New.
21466 * linux-low.c: Include <sys/syscall.h>.
21467 (linux_kill_one_process): Don't kill the first thread here.
21468 (linux_kill): Kill the first thread here.
21469 (kill_lwp): New function.
21470 (send_sigstop, linux_send_signal): Use it.
21471 * proc-service.c: Clean up #ifdefs.
21472 (fpregset_info): Delete.
21473 (ps_lgetregs): Update and enable implementation.
21474 (ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs): Remove disabled
21475 implementations.
21476 * remote-utils.c (struct sym_cache, symbol_cache): New.
21477 (input_interrupt): Print a clearer message.
21478 (async_io_enabled): New variable.
21479 (enable_async_io, disable_async_io): Use it. Update comments.
21480 (look_up_one_symbol): Use the symbol cache.
21481 * thread-db.c (thread_db_look_up_symbols): New function.
21482 (thread_db_init): Update comments. Call thread_db_look_up_symbols.
21483
21484 2004-10-16 Daniel Jacobowitz <dan@debian.org>
21485
21486 * configure.in: Test for -rdynamic.
21487 * configure: Regenerated.
21488 * Makefile (INTERNAL_LDFLAGS): New.
21489 (gdbserver, gdbreplay): Use it.
21490
21491 2004-09-02 Andrew Cagney <cagney@gnu.org>
21492
21493 * Makefile.in (TAGS): Replace TM_FILE with DEPRECATED_TM_FILE.
21494
21495 2004-03-23 Daniel Jacobowitz <drow@mvista.com>
21496
21497 * linux-low.c (linux_wait): Clear all_processes list also.
21498
21499 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
21500
21501 * linux-low.c: Include <errno.h>. Remove extern declaration of
21502 errno.
21503
21504 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
21505
21506 * gdbreplay.c, server.h, utils.c: Update copyright years.
21507
21508 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
21509
21510 * server.c (main): Print child status or termination signal from
21511 variable 'signal', not 'sig'.
21512
21513 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
21514
21515 * linux-low.c (linux_read_memory): Change return type to
21516 int. Check for and return error from ptrace().
21517 * target.c (read_inferior_memory): Change return type to int. Pass
21518 back return status from the_target->read_memory().
21519 * target.h (struct target_ops): Adapt *read_memory() prototype.
21520 Update comment.
21521 (read_inferior_memory): Adapt prototype.
21522 * server.c (main): Return an error packet if
21523 read_inferior_memory() returns an error.
21524
21525 2004-03-04 Daniel Jacobowitz <drow@mvista.com>
21526
21527 * Makefile.in (distclean): Remove config.h, stamp-h, and config.log.
21528 Unify with other clean targets.
21529
21530 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
21531
21532 * server.c (handle_v_cont): Call set_desired_inferior.
21533
21534 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
21535
21536 * remote-utils.c (prepare_resume_reply): Always supply "thread:".
21537
21538 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
21539
21540 * linux-low.c (linux_wait): Unblock async I/O.
21541 (linux_resume): Block and enable async I/O.
21542 * remote-utils.c (block_async_io, unblock_async_io): New functions.
21543 * server.h (block_async_io, unblock_async_io): Add prototypes.
21544
21545 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
21546
21547 * remote-utils.c (remote_open): Print a status notice after
21548 opening a TCP port.
21549 * server.c (attach_inferior): Print a status notice after
21550 attaching.
21551
21552 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
21553
21554 * linux-arm-low.c (arm_get_pc): Print out stop PC in debug mode.
21555
21556 2004-02-26 Daniel Jacobowitz <drow@mvista.com>
21557
21558 * remote-utils.c (write_enn): Use "E01" instead of "ENN" for the
21559 error packet.
21560 * server.c, target.h: Update copyright years.
21561
21562 2004-02-25 Roland McGrath <roland@redhat.com>
21563
21564 * target.h (struct target_ops): New member `read_auxv'.
21565 * server.c (handle_query): Handle qPart:auxv:read: query using that.
21566 * linux-low.c (linux_read_auxv): New function.
21567 (linux_target_ops): Initialize `read_auxv' member to that.
21568
21569 2004-02-17 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
21570
21571 Committed by Jim Blandy <jimb@redhat.com>.
21572
21573 * linux-s390-low.c (s390_num_regs): Update.
21574 (s390_regmap): Remove control registers. Use __s390x__ predefine
21575 instead of GPR_SIZE to distiguish s390 and s390x targets.
21576
21577 2004-01-31 Daniel Jacobowitz <drow@mvista.com>
21578
21579 * linux-low.c: Update copyright year.
21580 (check_removed_breakpoint): Clear pending_is_breakpoint.
21581 (linux_set_resume_request, linux_queue_one_thread)
21582 (resume_status_pending_p): New functions.
21583 (linux_continue_one_thread): Use process->resume.
21584 (linux_resume): Only resume threads if there are no pending events.
21585 * linux-low.h (struct process_info): Add resume request
21586 pointer.
21587
21588 2004-01-30 Daniel Jacobowitz <drow@mvista.com>
21589
21590 * regcache.c (new_register_cache): Clear the allocated register
21591 buffer. Suggested by Atsushi Nemoto <anemo@mba.ocn.ne.jp>.
21592
21593 2003-10-13 Daniel Jacobowitz <drow@mvista.com>
21594
21595 * linux-low.c (linux_resume): Take a struct thread_resume *
21596 argument.
21597 (linux_wait): Update call.
21598 (resume_ptr): New static variable.
21599 (linux_continue_one_thread): Renamed from
21600 linux_continue_one_process. Use resume_ptr.
21601 (linux_resume): Use linux_continue_one_thread.
21602 * server.c (handle_v_cont, handle_v_requests): New functions.
21603 (myresume): New function.
21604 (main): Handle 'v' case.
21605 * target.h (struct thread_resume): New type.
21606 (struct target_ops): Change argument of "resume" to struct
21607 thread_resume *.
21608 (myresume): Delete macro.
21609
21610 2003-08-08 H.J. Lu <hongjiu.lu@intel.com>
21611
21612 * Makefile.in (install-only): Create dest dir. Support DESTDIR.
21613 (uninstall): Support DESTDIR.
21614
21615 Mon Jul 21 20:09:34 UTC 2003 Brendan Conoboy <blc@redhat.com>
21616
21617 * configure.srv: Add xscale*linux copy of arm*linux entry.
21618
21619 2003-07-24 Daniel Jacobowitz <drow@mvista.com>
21620
21621 * linux-arm-low.c (arm_reinsert_addr): New function.
21622 (the_low_target): Add arm_reinsert_addr.
21623
21624 2003-07-08 Mark Kettenis <kettenis@gnu.org>
21625
21626 * mem-break.c: Remove whitespace at end of file.
21627
21628 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
21629
21630 * configure.in: Check whether we need to prototype strerror.
21631 * server.h: Optionally prototype strerror.
21632 * gdbreplay.c (perror_with_name): Use strerror.
21633 * linux-low.c (linux_attach_lwp): Use strerror.
21634 * utils.c (perror_with_name): Use strerror.
21635 * config.in, configure: Regenerated.
21636
21637 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
21638
21639 * linux-sh-low.c (sh_regmap): Fix FP register offsets, reported by
21640 SUGIOKA Toshinobu <sugioka@itonet.co.jp>.
21641
21642 2003-06-20 Daniel Jacobowitz <drow@mvista.com>
21643
21644 * Makefile.in (SFILES): Update.
21645 * low-hppabsd.c, low-lynx.c, low-nbsd.c, low-sim.c, low-sparc.c,
21646 low-sun3.c: Remove files.
21647
21648 2003-06-17 Daniel Jacobowitz <drow@mvista.com>
21649
21650 * linux-low.c: Move comment to linux_thread_alive where it belonged.
21651 (linux_detach_one_process, linux_detach): New functions.
21652 (linux_target_ops): Add linux_detach.
21653 * server.c (main): Handle 'D' packet.
21654 * target.h (struct target_ops): Add "detach" member.
21655 (detach_inferior): Define.
21656
21657 2003-06-13 Mark Kettenis <kettenis@gnu.org>
21658
21659 From Kelley Cook <kelleycook@wideopenwest.com>:
21660 * configure.srv: Accept i[34567]86 variants.
21661
21662 2003-06-05 Daniel Jacobowitz <drow@mvista.com>
21663
21664 * linux-low.c (linux_wait_for_event): Correct comment typos.
21665 (linux_resume_one_process): Call check_removed_breakpoint.
21666 (linux_send_signal): New function.
21667 (linux_target_ops): Add linux_send_signal.
21668 * remote-utils.c (putpkt, input_interrupt): Use send_signal instead
21669 of kill.
21670 * target.h (struct target_ops): Add send_signal.
21671
21672 2003-05-29 Jim Blandy <jimb@redhat.com>
21673
21674 * linux-low.c (usr_store_inferior_registers): Transfer buf in
21675 PTRACE_XFER_TYPE-sized chunks, not int-sized chunks. Otherwise,
21676 if 'int' is smaller than PTRACE_XFER_TYPE, you end up throwing
21677 away part of the register's value.
21678
21679 2003-03-26 Daniel Jacobowitz <drow@mvista.com>
21680
21681 * linux-low.c (linux_create_inferior): Use __SIGRTMIN.
21682 (linux_wait_for_event, linux_init_signals): Likewise.
21683
21684 2003-03-17 Daniel Jacobowitz <drow@mvista.com>
21685
21686 * configure.in: Check for stdlib.h.
21687 * configure: Regenerated.
21688 * config.in: Regenerated.
21689
21690 2003-01-04 Andreas Schwab <schwab@suse.de>
21691
21692 * linux-m68k-low.c (m68k_num_regs): Define to 29 instead of 31.
21693
21694 2003-01-02 Andrew Cagney <ac131313@redhat.com>
21695
21696 * Makefile.in: Remove obsolete code.
21697
21698 2002-11-20 Daniel Jacobowitz <drow@mvista.com>
21699
21700 * linux-s390-low.c (s390_regmap): Check GPR_SIZE instead of
21701 defined(PT_FPR0_HI).
21702
21703 2002-11-17 Stuart Hughes <seh@zee2.com>
21704
21705 * linux-arm-low.c (arm_num_regs): Increase.
21706 (arm_regmap): Include status register.
21707
21708 2002-11-17 Daniel Jacobowitz <drow@mvista.com>
21709
21710 * linux-low.c (register_addr): Remove incorrect -1 check.
21711
21712 2002-08-29 Daniel Jacobowitz <drow@mvista.com>
21713
21714 * linux-low.c (linux_create_inferior): Call setpgid. Return
21715 the new PID.
21716 (unstopped_p, linux_signal_pid): Remove.
21717 (linux_target_ops): Remove linux_signal_pid.
21718 * remote-utils.c (putpkt, input_interrupt): Use signal_pid
21719 global instead of target method.
21720 * target.h (struct target_ops): Remove signal_pid. Update comment
21721 for create_inferior.
21722 * server.c (signal_pid): New variable.
21723 (create_inferior): Set signal_pid. Block SIGTTOU and SIGTTIN in
21724 gdbserver. Set the child to be the foreground process group.
21725 (attach_inferior): Set signal_pid.
21726
21727 2002-08-23 Daniel Jacobowitz <drow@mvista.com>
21728
21729 * ChangeLog: New file, with entries from gdb/ChangeLog after GDB 5.2.
21730
21731 2002-08-20 Jim Blandy <jimb@redhat.com>
21732
21733 * Makefile.in (LDFLAGS): Allow the configure script to establish a
21734 default for this.
21735
21736 2002-08-01 Andrew Cagney <cagney@redhat.com>
21737
21738 * Makefile.in: Make chill references obsolete.
21739
21740 2002-07-24 Kevin Buettner <kevinb@redhat.com>
21741
21742 * configure.in (unistd.h): Add to AC_CHECK_HEADERS list.
21743 * configure: Regenerate.
21744 * config.in: Regenerate.
21745
21746 2002-07-09 David O'Brien <obrien@FreeBSD.org>
21747
21748 * gdbreplay.c (stdlib.h, unistd.h): Conditionaly include.
21749 (perror_with_name, remote_close, remote_open, expect, play): Static.
21750
21751 2002-07-04 Michal Ludvig <mludvig@suse.cz>
21752
21753 * linux-x86-64-low.c (x86_64_regmap): Make it an array of
21754 byte offsets instead of an array of indexes.
21755 (x86_64_store_gregset, x86_64_store_fpregset): Parameter made const.
21756
21757 2002-06-13 Daniel Jacobowitz <drow@mvista.com>
21758
21759 * regcache.c: Add comment.
21760
21761 2002-06-11 Daniel Jacobowitz <drow@mvista.com>
21762
21763 * thread-db.c: New file.
21764 * proc-service.c: New file.
21765 * acinclude.m4: New file.
21766 * Makefile.in: Add GDBSERVER_LIBS, gdb_proc_service_h,
21767 proc-service.o, and thread-db.o.
21768 (linux-low.o): Add USE_THREAD_DB.
21769 * acconfig.h: Add HAVE_PRGREGSET_T, HAVE_PRFPREGSET_T,
21770 HAVE_LWPID_T, HAVE_PSADDR_T, and PRFPREGSET_T_BROKEN.
21771 * aclocal.m4: Regenerated.
21772 * config.in: Regenerated.
21773 * configure: Regenerated.
21774 * configure.in: Check for proc_service.h, sys/procfs.h,
21775 thread_db.h, and linux/elf.h headrs.
21776 Check for lwpid_t, psaddr_t, prgregset_t, prfpregset_t, and
21777 PRFPREGSET_T_BROKEN. Introduce srv_thread_depfiles and USE_THREAD_DB.
21778 Check for -lthread_db and thread support.
21779 * configure.srv: Enable thread_db support for ARM, i386, MIPS,
21780 PowerPC, and SuperH.
21781 * i387-fp.c: Constify arguments.
21782 * i387-fp.h: Likewise.
21783 * inferiors.c: (struct thread_info): Renamed from
21784 `struct inferior_info'. Remove PID member. Use generic inferior
21785 list header. All uses updated.
21786 (inferiors, signal_pid): Removed.
21787 (all_threads): New variable.
21788 (get_thread): Define.
21789 (add_inferior_to_list): New function.
21790 (for_each_inferior): New function.
21791 (change_inferior_id): New function.
21792 (add_inferior): Removed.
21793 (remove_inferior): New function.
21794 (add_thread): New function.
21795 (free_one_thread): New function.
21796 (remove_thread): New function.
21797 (clear_inferiors): Use for_each_inferior and free_one_thread.
21798 (find_inferior): New function.
21799 (find_inferior_id): New function.
21800 (inferior_target_data): Update argument type.
21801 (set_inferior_target_data): Likewise.
21802 (inferior_regcache_data): Likewise.
21803 (set_inferior_regcache_data): Likewise.
21804 * linux-low.c (linux_bp_reinsert): Remove.
21805 (all_processes, stopping_threads, using_thrads)
21806 (struct pending_signals, debug_threads, pid_of): New.
21807 (inferior_pid): Replace with macro.
21808 (struct inferior_linux_data): Remove.
21809 (get_stop_pc, add_process): New functions.
21810 (linux_create_inferior): Restore SIGRTMIN+1 before calling exec.
21811 Use add_process and add_thread.
21812 (linux_attach_lwp): New function, based on old linux_attach. Use
21813 add_process and add_thread. Set stop_expected for new threads.
21814 (linux_attach): New function.
21815 (linux_kill_one_process): New function.
21816 (linux_kill): Kill all LWPs.
21817 (linux_thread_alive): Use find_inferior_id.
21818 (check_removed_breakpoints, status_pending_p): New functions.
21819 (linux_wait_for_process): Renamed from linux_wait_for_one_inferior.
21820 Update. Use WNOHANG. Wait for cloned processes also. Update process
21821 struct for the found process.
21822 (linux_wait_for_event): New function.
21823 (linux_wait): Use it. Support LWPs.
21824 (send_sigstop, wait_for_sigstop, stop_all_processes)
21825 (linux_resume_one_process, linux_continue_one_process): New functions.
21826 (linux_resume): Support LWPs.
21827 (REGISTER_RAW_SIZE): Remove.
21828 (fetch_register): Use register_size instead. Call supply_register.
21829 (usr_store_inferior_registers): Likewise. Call collect_register.
21830 Fix recursive case.
21831 (regsets_fetch_inferior_registers): Improve error message.
21832 (regsets_store_inferior_registers): Add debugging.
21833 (linux_look_up_symbols): Call thread_db_init if USE_THREAD_DB.
21834 (unstopped_p, linux_signal_pid): New functions.
21835 (linux_target_ops): Add linux_signal_pid.
21836 (linux_init_signals): New function.
21837 (initialize_low): Call it. Initialize using_threads.
21838 * regcache.c (inferior_regcache_data): Add valid
21839 flag.
21840 (get_regcache): Fetch registers lazily. Add fetch argument
21841 and update all callers.
21842 (regcache_invalidate_one, regcache_invalidate): New
21843 functions.
21844 (new_register_cache): Renamed from create_register_cache.
21845 Return the new regcache.
21846 (free_register_cache): Change argument to a void *.
21847 (registers_to_string, registers_from_string): Call get_regcache
21848 with fetch flag set.
21849 (register_data): Make static. Pass fetch flag to get_regcache.
21850 (supply_register): Call get_regcache with fetch flag clear.
21851 (collect_register): Call get_regcache with fetch flag set.
21852 (collect_register_as_string): New function.
21853 * regcache.h: Update.
21854 * remote-utils.c (putpkt): Flush after debug output and use
21855 stderr.
21856 Handle input interrupts while waiting for an ACK.
21857 (input_interrupt): Use signal_pid method.
21858 (getpkt): Flush after debug output and use stderr.
21859 (outreg): Use collect_register_as_string.
21860 (new_thread_notify, dead_thread_notify): New functions.
21861 (prepare_resume_reply): Check using_threads. Set thread_from_wait
21862 and general_thread.
21863 (look_up_one_symbol): Flush after debug output.
21864 * server.c (step_thread, server_waiting): New variables.
21865 (start_inferior): Don't use signal_pid. Update call to mywait.
21866 (attach_inferior): Update call to mywait.
21867 (handle_query): Handle qfThreadInfo and qsThreadInfo.
21868 (main): Don't fetch/store registers explicitly. Use
21869 set_desired_inferior. Support proposed ``Hs'' packet. Update
21870 calls to mywait.
21871 * server.h: Update.
21872 (struct inferior_list, struct_inferior_list_entry): New.
21873 * target.c (set_desired_inferior): New.
21874 (write_inferior_memory): Constify.
21875 (mywait): New function.
21876 * target.h: Update.
21877 (struct target_ops): New signal_pid method.
21878 (mywait): Removed macro, added prototype.
21879
21880 * linux-low.h (regset_func): Removed.
21881 (regset_fill_func, regset_store_func): New.
21882 (enum regset_type): New.
21883 (struct regset_info): Add type field. Use new operation types.
21884 (struct linux_target_ops): stop_pc renamed to get_pc.
21885 Add decr_pc_after_break and breakpoint_at.
21886 (get_process, get_thread_proess, get_process_thread)
21887 (strut process_info, all_processes, linux_attach_lwp)
21888 (thread_db_init): New.
21889
21890 * linux-arm-low.c (arm_get_pc, arm_set_pc,
21891 arm_breakpoint, arm_breakpoint_len, arm_breakpoint_at): New.
21892 (the_low_target): Add new members.
21893 * linux-i386-low.c (i386_store_gregset, i386_store_fpregset)
21894 (i386_store_fpxregset): Constify.
21895 (target_regsets): Add new kind identifier.
21896 (i386_get_pc): Renamed from i386_stop_pc. Simplify.
21897 (i386_set_pc): Add debugging.
21898 (i386_breakpoint_at): New function.
21899 (the_low_target): Add new members.
21900 * linux-mips-low.c (mips_get_pc, mips_set_pc)
21901 (mips_breakpoint, mips_breakpoint_len, mips_reinsert_addr)
21902 (mips_breakpoint_at): New.
21903 (the_low_target): Add new members.
21904 * linux-ppc-low.c (ppc_get_pc, ppc_set_pc)
21905 (ppc_breakpoint, ppc_breakpoint_len, ppc_breakpoint_at): New.
21906 (the_low_target): Add new members.
21907 * linux-sh-low.c (sh_get_pc, sh_set_pc)
21908 (sh_breakpoint, sh_breakpoint_len, sh_breakpoint_at): New.
21909 (the_low_target): Add new members.
21910 * linux-x86-64-low.c (target_regsets): Add new kind
21911 identifier.
21912
21913 2002-05-15 Daniel Jacobowitz <drow@mvista.com>
21914
21915 From Martin Pool <mbp@samba.org>:
21916 * server.c (gdbserver_usage): New function.
21917 (main): Call it.
21918
21919 2002-05-14 Daniel Jacobowitz <drow@mvista.com>
21920
21921 * mem-break.c (reinsert_breakpoint_by_bp): Correct typo
21922 stop_at -> stop_pc.
21923
21924 2002-05-04 Andrew Cagney <ac131313@redhat.com>
21925
21926 * Makefile.in: Remove obsolete code.
21927
21928 2002-04-24 Michal Ludvig <mludvig@suse.cz>
21929
21930 * linux-low.c (regsets_fetch_inferior_registers),
21931 (regsets_store_inferior_registers): Removed cast to int from
21932 ptrace() calls.
21933 * regcache.h: Added declaration of struct inferior_info.
21934
21935 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
21936
21937 * inferiors.c (struct inferior_info): Add regcache_data.
21938 (add_inferior): Call create_register_cache.
21939 (clear_inferiors): Call free_register_cache.
21940 (inferior_regcache_data, set_inferior_regcache_data): New functions.
21941 * regcache.c (struct inferior_regcache_data): New.
21942 (registers): Remove.
21943 (get_regcache): New function.
21944 (create_register_cache, free_register_cache): New functions.
21945 (set_register_cache): Don't initialize the register cache here.
21946 (registers_to_string, registers_from_string, register_data): Call
21947 get_regcache.
21948 * regcache.h: Add prototypes.
21949 * server.h: Likewise.
21950
21951 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
21952
21953 * mem-break.c: New file.
21954 * mem-break.h: New file.
21955 * Makefile.in: Add mem-break.o rule; update server.h
21956 dependencies.
21957 * inferiors.c (struct inferior_info): Add target_data
21958 member.
21959 (clear_inferiors): Free target_data member if set.
21960 (inferior_target_data, set_inferior_target_data): New functions.
21961 * linux-i386-low.c (i386_breakpoint, i386_breakpoint_len)
21962 (i386_stop_pc, i386_set_pc): New. Add to the_low_target.
21963 * linux-low.c (linux_bp_reinsert): New variable.
21964 (struct inferior_linux_data): New.
21965 (linux_create_inferior): Use set_inferior_target_data.
21966 (linux_attach): Likewise. Call add_inferior.
21967 (linux_wait_for_one_inferior): New function.
21968 (linux_wait): Call it.
21969 (linux_write_memory): Add const.
21970 (initialize_low): Call set_breakpoint_data.
21971 * linux-low.h (struct linux_target_ops): Add breakpoint
21972 handling members.
21973 * server.c (attach_inferior): Remove extra add_inferior
21974 call.
21975 * server.h: Include mem-break.h. Update inferior.c
21976 prototypes.
21977 * target.c (read_inferior_memory)
21978 (write_inferior_memory): New functions.
21979 * target.h (read_inferior_memory)
21980 (write_inferior_memory): Change macros to prototypes.
21981 (struct target_ops): Update comments. Add const to write_memory
21982 definition.
21983
21984 2002-04-11 Daniel Jacobowitz <drow@mvista.com>
21985
21986 * linux-low.c (usr_store_inferior_registers): Support
21987 registers which are allowed to fail to store.
21988 * linux-low.h (linux_target_ops): Likewise.
21989 * linux-ppc-low.c (ppc_regmap): Support FPSCR.
21990 (ppc_cannot_store_register): FPSCR may not be storable.
21991
21992 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
21993
21994 * server.h: Include <string.h> if HAVE_STRING_H.
21995 * ChangeLog: Correct paths in last ChangeLog entry.
21996
21997 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
21998
21999 * linux-low.h: Remove obsolete prototypes.
22000 (struct linux_target_ops): New.
22001 (extern the_low_target): New.
22002 * linux-low.c (num_regs, regmap): Remove declarations.
22003 (register_addr): Use the_low_target explicitly.
22004 (fetch_register): Likewise.
22005 (usr_fetch_inferior_registers): Likewise.
22006 (usr_store_inferior_registers): Likewise.
22007 * linux-arm-low.c (num_regs): Remove.
22008 (arm_num_regs): Define.
22009 (arm_regmap): Renamed from regmap, made static.
22010 (arm_cannot_fetch_register): Renamed from cannot_fetch_register,
22011 made static.
22012 (arm_cannot_store_register): Renamed from cannot_store_register,
22013 made static.
22014 (the_low_target): New.
22015 * linux-i386-low.c (num_regs): Remove.
22016 (i386_num_regs): Define.
22017 (i386_regmap): Renamed from regmap, made static.
22018 (i386_cannot_fetch_register): Renamed from cannot_fetch_register,
22019 made static.
22020 (i386_cannot_store_register): Renamed from cannot_store_register,
22021 made static.
22022 (the_low_target): New.
22023 * linux-ia64-low.c (num_regs): Remove.
22024 (ia64_num_regs): Define.
22025 (ia64_regmap): Renamed from regmap, made static.
22026 (ia64_cannot_fetch_register): Renamed from cannot_fetch_register,
22027 made static.
22028 (ia64_cannot_store_register): Renamed from cannot_store_register,
22029 made static.
22030 (the_low_target): New.
22031 * linux-m68k-low.c (num_regs): Remove.
22032 (m68k_num_regs): Define.
22033 (m68k_regmap): Renamed from regmap, made static.
22034 (m68k_cannot_fetch_register): Renamed from cannot_fetch_register,
22035 made static.
22036 (m68k_cannot_store_register): Renamed from cannot_store_register,
22037 made static.
22038 (the_low_target): New.
22039 * linux-mips-low.c (num_regs): Remove.
22040 (mips_num_regs): Define.
22041 (mips_regmap): Renamed from regmap, made static.
22042 (mips_cannot_fetch_register): Renamed from cannot_fetch_register,
22043 made static.
22044 (mips_cannot_store_register): Renamed from cannot_store_register,
22045 made static.
22046 (the_low_target): New.
22047 * linux-ppc-low.c (num_regs): Remove.
22048 (ppc_num_regs): Define.
22049 (ppc_regmap): Renamed from regmap, made static.
22050 (ppc_cannot_fetch_register): Renamed from cannot_fetch_register,
22051 made static.
22052 (ppc_cannot_store_register): Renamed from cannot_store_register,
22053 made static.
22054 (the_low_target): New.
22055 * linux-s390-low.c (num_regs): Remove.
22056 (s390_num_regs): Define.
22057 (s390_regmap): Renamed from regmap, made static.
22058 (s390_cannot_fetch_register): Renamed from cannot_fetch_register,
22059 made static.
22060 (s390_cannot_store_register): Renamed from cannot_store_register,
22061 made static.
22062 (the_low_target): New.
22063 * linux-sh-low.c (num_regs): Remove.
22064 (sh_num_regs): Define.
22065 (sh_regmap): Renamed from regmap, made static.
22066 (sh_cannot_fetch_register): Renamed from cannot_fetch_register,
22067 made static.
22068 (sh_cannot_store_register): Renamed from cannot_store_register,
22069 made static.
22070 (the_low_target): New.
22071 * linux-x86-64-low.c (x86_64_regmap): Renamed from regmap.
22072 (the_low_target): New.
22073
22074 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
22075
22076 * Makefile.in: Add stamp-h target.
22077 * configure.in: Create stamp-h.
22078 * configure: Regenerated.
22079
22080 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
22081
22082 * inferiors.c: New file.
22083 * target.c: New file.
22084 * target.h: New file.
22085 * Makefile.in: Add target.o and inferiors.o. Update
22086 dependencies.
22087 * linux-low.c (inferior_pid): New static variable,
22088 moved from server.c.
22089 (linux_create_inferior): Renamed from create_inferior.
22090 Call add_inferior. Return 0 on success instead of a PID.
22091 (linux_attach): Renamed from myattach.
22092 (linux_kill): Renamed from kill_inferior. Call clear_inferiors ().
22093 (linux_thread_alive): Renamed from mythread_alive.
22094 (linux_wait): Renamed from mywait. Call clear_inferiors () if the
22095 child dies.
22096 (linux_resume): Renamed from myresume. Add missing ``return 0''.
22097 (regsets_store_inferior_registers): Correct error message.
22098 Add missing ``return 0''.
22099 (linux_fetch_registers): Renamed from fetch_inferior_registers.
22100 (linux_store_registers): Renamed from store_inferior_registers.
22101 (linux_read_memory): Renamed from read_inferior_memory.
22102 (linux_write_memory): Renamed from write_inferior_memory.
22103 (linux_target_ops): New structure.
22104 (initialize_low): Call set_target_ops ().
22105 * remote-utils.c (unhexify): New function.
22106 (hexify): New function.
22107 (input_interrupt): Send signals to ``signal_pid''.
22108 * server.c (inferior_pid): Remove.
22109 (start_inferior): Update create_inferior call.
22110 (attach_inferior): Call add_inferior.
22111 (handle_query): New function.
22112 (main): Call handle_query for `q' packets.
22113 * server.h: Include "target.h". Remove obsolete prototypes.
22114 Add prototypes for "inferiors.c", "target.c", hexify, and unhexify.
22115
22116 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
22117
22118 * Makefile.in: Add WARN_CFLAGS. Update configury
22119 dependencies.
22120 * configure.in: Check for <string.h>
22121 * configure: Regenerate.
22122 * config.in: Regenerate.
22123 * gdbreplay.c: Include needed system headers.
22124 (remote_open): Remove strchr prototype.
22125 * linux-low.h: Correct #ifdef to HAVE_LINUX_USRREGS.
22126 * regcache.c (supply_register): Change buf argument to const void *.
22127 (supply_register_by_name): Likewise.
22128 (collect_register): Change buf argument to void *.
22129 (collect_register_by_name): Likewise.
22130 * regcache.h: Add missing prototypes.
22131 * remote-utils.c: Include <arpa/inet.h> for inet_ntoa.
22132 * server.c (handle_query): New function.
22133 (attached): New static variable, moved out of main.
22134 (main): Quiet longjmp clobber warnings.
22135 * server.h: Add ATTR_NORETURN and ATTR_FORMAT. Update prototypes.
22136 * utils.c (error): Remove NORETURN.
22137 (fatal): Likewise.