]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blame - gdbserver/ChangeLog
Change gdbsupport not to rely on BFD
[thirdparty/binutils-gdb.git] / gdbserver / ChangeLog
CommitLineData
9a665d62
TT
12020-03-12 Tom Tromey <tom@tromey.com>
2
3 * config.in, configure: Rebuild.
4 * configure.ac: Call ZW_GNU_GETTEXT_SISTER_DIR.
5 * acinclude.m4: Include gettext-sister.m4.
6 * Makefile.in (top_builddir, INTL, INTL_DEPS, INTL_CFLAGS): New
7 variables.
8 (INCLUDE_CFLAGS): Add INTL_CFLAGS.
9 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Use INTL_DEPS, INTL.
10
272cd5a3
SM
112020-03-12 Simon Marchi <simon.marchi@efficios.com>
12
13 * acinclude.m4: Update path to selftest.m4.
14
db6878ac
SM
152020-03-12 Simon Marchi <simon.marchi@efficios.com>
16
17 * configure.ac: Don't source bfd/development.sh, move
18 GDB_AC_COMMON higher.
19 * configure: Re-generate.
20
4d696a5c
SM
212020-03-12 Simon Marchi <simon.marchi@efficios.com>
22
23 * configure: Re-generate.
24
a0761e34
SM
252020-03-11 Simon Marchi <simon.marchi@efficios.com>
26
27 * configure: Re-generate.
28
20ea4a60
AB
292020-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
30
31 * .dir-locals.el: New file.
32
842806cb
TBA
332020-03-05 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
34
35 * .gitattributes: New file.
36
442131c1
AB
372020-03-02 Andrew Burgess <andrew.burgess@embecosm.com>
38
39 * remote-utils.cc (prepare_resume_reply): Add ability to convert T
40 reply into an S reply.
41 * server.cc (disable_packet_T): New global.
42 (captured_main): Set new global when appropriate.
43 * server.h (disable_packet_T): Declare.
44
dda42c0b
TT
452020-02-21 Tom Tromey <tom@tromey.com>
46
47 * Makefile.in (mostlyclean): New target.
48
52405d85
TBA
492020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
50
51 * target.h (struct process_stratum_target): Remove.
52 (class process_target): Rename to ...
53 (class process_stratum_target): ... this.
54 * linux-low.h (class linux_process_target): Derive from
55 'process_stratum_target'.
56 * linux-low.cc (linux_target_ops): Remove.
57 (initialize_low): Set the_target to the singleton instance of
58 linux_process_target.
59 * lynx-low.h (class lynx_process_target): Derive from
60 'process_stratum_target'.
61 * lynx-low.cc (lynx_target_ops): Remove.
62 (initialize_low): Set the_target to the singleton instance of
63 lynx_process_target.
64 * nto-low.h (class nto_process_target): Derive from
65 'process_stratum_target'.
66 * nto-low.cc (nto_target_ops): Remove.
67 (initialize_low): Set the_target to the singleton instance of
68 nto_process_target.
69 * win32-low.h (class win32_process_target): Derive from
70 'process_stratum_target'.
71 * win32-low.cc (win32_target_ops): Remove.
72 (initialize_low): Set the_target to the singleton instance of
73 win32_process_target.
74
75 Replace 'the_target->pt' with 'the_target' in the uses below.
76
77 * hostio.cc (hostio_error)
78 (handle_setfs)
79 (handle_open)
80 (handle_unlink)
81 (handle_readlink)
82 * linux-aarch32-low.cc (arm_breakpoint_at)
83 * linux-aarch64-low.cc (aarch64_breakpoint_at)
84 * linux-arm-low.cc (arm_sigreturn_next_pc)
85 (arm_get_hwcap)
86 (arm_get_syscall_trapinfo)
87 * linux-cris-low.cc (cris_breakpoint_at)
88 * linux-crisv32-low.cc (cris_breakpoint_at)
89 * linux-low.cc (handle_extended_wait)
90 (linux_wait_1)
91 (linux_read_memory)
92 (linux_process_target::breakpoint_kind_from_pc)
93 (linux_get_auxv)
94 * linux-m32r-low.cc (m32r_breakpoint_at)
95 * linux-mips-low.cc (mips_breakpoint_at)
96 * linux-nios2-low.cc (nios2_breakpoint_at)
97 * linux-ppc-low.cc (ppc_breakpoint_at)
98 * linux-s390-low.cc (s390_get_hwcap)
99 * linux-sh-low.cc (sh_breakpoint_at)
100 * linux-sparc-low.cc (sparc_fill_gregset_to_stack)
101 (sparc_store_gregset_from_stack)
102 (sparc_breakpoint_at)
103 * linux-tic6x-low.cc (tic6x_breakpoint_at)
104 * linux-tile-low.cc (tile_breakpoint_at)
105 * linux-x86-low.cc (x86_breakpoint_at)
106 * linux-xtensa-low.cc (xtensa_breakpoint_at)
107 * mem-break.cc (bp_size)
108 (bp_opcode)
109 (insert_memory_breakpoint)
110 (set_raw_breakpoint_at)
111 (delete_raw_breakpoint)
112 (z_type_supported)
113 (uninsert_raw_breakpoint)
114 (reinsert_raw_breakpoint)
115 (validate_inserted_breakpoint)
116 * regcache.cc (regcache_read_pc)
117 (regcache_write_pc)
118 * remote-utils.cc (putpkt_binary_1)
119 (input_interrupt)
120 (getpkt)
121 (prepare_resume_reply)
122 * server.cc (handle_general_set)
123 (handle_detach)
124 (handle_qxfer_auxv)
125 (handle_qxfer_exec_file)
126 (handle_qxfer_libraries_svr4)
127 (handle_qxfer_osdata)
128 (handle_qxfer_siginfo)
129 (handle_qxfer_fdpic)
130 (handle_query)
131 (resume)
132 (handle_v_requests)
133 (queue_stop_reply_callback)
134 (captured_main)
135 * target.cc (prepare_to_access_memory)
136 (done_accessing_memory)
137 (read_inferior_memory)
138 (target_write_memory)
139 (target_stop_and_wait)
140 (target_wait)
141 (target_mourn_inferior)
142 (target_continue_no_signal)
143 (target_continue)
144 (target_supports_multi_process)
145 (kill_inferior)
146 * target.h
147 (target_create_inferior)
148 (target_post_create_inferior)
149 (myattach)
150 (target_supports_fork_events)
151 (target_supports_vfork_events)
152 (target_supports_exec_events)
153 (target_handle_new_gdb_connection)
154 (detach_inferior)
155 (mythread_alive)
156 (fetch_inferior_registers)
157 (store_inferior_registers)
158 (join_inferior)
159 (target_supports_non_stop)
160 (target_async)
161 (target_process_qsupported)
162 (target_supports_catch_syscall)
163 (target_get_ipa_tdesc_idx)
164 (target_supports_tracepoints)
165 (target_supports_fast_tracepoints)
166 (target_get_min_fast_tracepoint_insn_len)
167 (target_thread_stopped)
168 (target_pause_all)
169 (target_unpause_all)
170 (target_stabilize_threads)
171 (target_install_fast_tracepoint_jump_pad)
172 (target_emit_ops)
173 (target_supports_disable_randomization)
174 (target_supports_agent)
175 (target_enable_btrace)
176 (target_disable_btrace)
177 (target_read_btrace)
178 (target_read_btrace_conf)
179 (target_supports_range_stepping)
180 (target_supports_stopped_by_sw_breakpoint)
181 (target_stopped_by_sw_breakpoint)
182 (target_supports_stopped_by_hw_breakpoint)
183 (target_supports_hardware_single_step)
184 (target_stopped_by_hw_breakpoint)
185 (target_breakpoint_kind_from_pc)
186 (target_breakpoint_kind_from_current_state)
187 (target_supports_software_single_step)
188 (target_core_of_thread)
189 (target_thread_name)
190 (target_thread_handle)
191 * win32-low.cc (do_initial_child_stuff)
192
193 Rename target op default definitions listed below.
194
195 * target.cc (process_target::post_create_inferior): Rename as ...
196 (process_stratum_target::post_create_inferior): ... this.
197 (process_target::prepare_to_access_memory): Rename as ...
198 (process_stratum_target::prepare_to_access_memory): ... this.
199 (process_target::done_accessing_memory): Rename as ...
200 (process_stratum_target::done_accessing_memory): ... this.
201 (process_target::look_up_symbols): Rename as ...
202 (process_stratum_target::look_up_symbols): ... this.
203 (process_target::supports_read_auxv): Rename as ...
204 (process_stratum_target::supports_read_auxv): ... this.
205 (process_target::read_auxv): Rename as ...
206 (process_stratum_target::read_auxv): ... this.
207 (process_target::supports_z_point_type): Rename as ...
208 (process_stratum_target::supports_z_point_type): ... this.
209 (process_target::insert_point): Rename as ...
210 (process_stratum_target::insert_point): ... this.
211 (process_target::remove_point): Rename as ...
212 (process_stratum_target::remove_point): ... this.
213 (process_target::stopped_by_sw_breakpoint): Rename as ...
214 (process_stratum_target::stopped_by_sw_breakpoint): ... this.
215 (process_target::supports_stopped_by_sw_breakpoint): Rename as ...
216 (process_stratum_target::supports_stopped_by_sw_breakpoint): ... this.
217 (process_target::stopped_by_hw_breakpoint): Rename as ...
218 (process_stratum_target::stopped_by_hw_breakpoint): ... this.
219 (process_target::supports_stopped_by_hw_breakpoint): Rename as ...
220 (process_stratum_target::supports_stopped_by_hw_breakpoint): ... this.
221 (process_target::supports_hardware_single_step): Rename as ...
222 (process_stratum_target::supports_hardware_single_step): ... this.
223 (process_target::stopped_by_watchpoint): Rename as ...
224 (process_stratum_target::stopped_by_watchpoint): ... this.
225 (process_target::stopped_data_address): Rename as ...
226 (process_stratum_target::stopped_data_address): ... this.
227 (process_target::supports_read_offsets): Rename as ...
228 (process_stratum_target::supports_read_offsets): ... this.
229 (process_target::read_offsets): Rename as ...
230 (process_stratum_target::read_offsets): ... this.
231 (process_target::supports_get_tls_address): Rename as ...
232 (process_stratum_target::supports_get_tls_address): ... this.
233 (process_target::get_tls_address): Rename as ...
234 (process_stratum_target::get_tls_address): ... this.
235 (process_target::hostio_last_error): Rename as ...
236 (process_stratum_target::hostio_last_error): ... this.
237 (process_target::supports_qxfer_osdata): Rename as ...
238 (process_stratum_target::supports_qxfer_osdata): ... this.
239 (process_target::qxfer_osdata): Rename as ...
240 (process_stratum_target::qxfer_osdata): ... this.
241 (process_target::supports_qxfer_siginfo): Rename as ...
242 (process_stratum_target::supports_qxfer_siginfo): ... this.
243 (process_target::qxfer_siginfo): Rename as ...
244 (process_stratum_target::qxfer_siginfo): ... this.
245 (process_target::supports_non_stop): Rename as ...
246 (process_stratum_target::supports_non_stop): ... this.
247 (process_target::async): Rename as ...
248 (process_stratum_target::async): ... this.
249 (process_target::start_non_stop): Rename as ...
250 (process_stratum_target::start_non_stop): ... this.
251 (process_target::supports_multi_process): Rename as ...
252 (process_stratum_target::supports_multi_process): ... this.
253 (process_target::supports_fork_events): Rename as ...
254 (process_stratum_target::supports_fork_events): ... this.
255 (process_target::supports_vfork_events): Rename as ...
256 (process_stratum_target::supports_vfork_events): ... this.
257 (process_target::supports_exec_events): Rename as ...
258 (process_stratum_target::supports_exec_events): ... this.
259 (process_target::handle_new_gdb_connection): Rename as ...
260 (process_stratum_target::handle_new_gdb_connection): ... this.
261 (process_target::handle_monitor_command): Rename as ...
262 (process_stratum_target::handle_monitor_command): ... this.
263 (process_target::core_of_thread): Rename as ...
264 (process_stratum_target::core_of_thread): ... this.
265 (process_target::supports_read_loadmap): Rename as ...
266 (process_stratum_target::supports_read_loadmap): ... this.
267 (process_target::read_loadmap): Rename as ...
268 (process_stratum_target::read_loadmap): ... this.
269 (process_target::process_qsupported): Rename as ...
270 (process_stratum_target::process_qsupported): ... this.
271 (process_target::supports_tracepoints): Rename as ...
272 (process_stratum_target::supports_tracepoints): ... this.
273 (process_target::read_pc): Rename as ...
274 (process_stratum_target::read_pc): ... this.
275 (process_target::write_pc): Rename as ...
276 (process_stratum_target::write_pc): ... this.
277 (process_target::supports_thread_stopped): Rename as ...
278 (process_stratum_target::supports_thread_stopped): ... this.
279 (process_target::thread_stopped): Rename as ...
280 (process_stratum_target::thread_stopped): ... this.
281 (process_target::supports_get_tib_address): Rename as ...
282 (process_stratum_target::supports_get_tib_address): ... this.
283 (process_target::get_tib_address): Rename as ...
284 (process_stratum_target::get_tib_address): ... this.
285 (process_target::pause_all): Rename as ...
286 (process_stratum_target::pause_all): ... this.
287 (process_target::unpause_all): Rename as ...
288 (process_stratum_target::unpause_all): ... this.
289 (process_target::stabilize_threads): Rename as ...
290 (process_stratum_target::stabilize_threads): ... this.
291 (process_target::supports_fast_tracepoints): Rename as ...
292 (process_stratum_target::supports_fast_tracepoints): ... this.
293 (process_target::get_min_fast_tracepoint_insn_len): Rename as ...
294 (process_stratum_target::get_min_fast_tracepoint_insn_len): ... this.
295 (process_target::emit_ops): Rename as ...
296 (process_stratum_target::emit_ops): ... this.
297 (process_target::supports_disable_randomization): Rename as ...
298 (process_stratum_target::supports_disable_randomization): ... this.
299 (process_target::supports_qxfer_libraries_svr4): Rename as ...
300 (process_stratum_target::supports_qxfer_libraries_svr4): ... this.
301 (process_target::qxfer_libraries_svr4): Rename as ...
302 (process_stratum_target::qxfer_libraries_svr4): ... this.
303 (process_target::supports_agent): Rename as ...
304 (process_stratum_target::supports_agent): ... this.
305 (process_target::enable_btrace): Rename as ...
306 (process_stratum_target::enable_btrace): ... this.
307 (process_target::disable_btrace): Rename as ...
308 (process_stratum_target::disable_btrace): ... this.
309 (process_target::read_btrace): Rename as ...
310 (process_stratum_target::read_btrace): ... this.
311 (process_target::read_btrace_conf): Rename as ...
312 (process_stratum_target::read_btrace_conf): ... this.
313 (process_target::supports_range_stepping): Rename as ...
314 (process_stratum_target::supports_range_stepping): ... this.
315 (process_target::supports_pid_to_exec_file): Rename as ...
316 (process_stratum_target::supports_pid_to_exec_file): ... this.
317 (process_target::pid_to_exec_file): Rename as ...
318 (process_stratum_target::pid_to_exec_file): ... this.
319 (process_target::supports_multifs): Rename as ...
320 (process_stratum_target::supports_multifs): ... this.
321 (process_target::multifs_open): Rename as ...
322 (process_stratum_target::multifs_open): ... this.
323 (process_target::multifs_unlink): Rename as ...
324 (process_stratum_target::multifs_unlink): ... this.
325 (process_target::multifs_readlink): Rename as ...
326 (process_stratum_target::multifs_readlink): ... this.
327 (process_target::breakpoint_kind_from_pc): Rename as ...
328 (process_stratum_target::breakpoint_kind_from_pc): ... this.
329 (process_target::breakpoint_kind_from_current_state): Rename as ...
330 (process_stratum_target::breakpoint_kind_from_current_state): ... this.
331 (process_target::thread_name): Rename as ...
332 (process_stratum_target::thread_name): ... this.
333 (process_target::thread_handle): Rename as ...
334 (process_stratum_target::thread_handle): ... this.
335 (process_target::supports_software_single_step): Rename as ...
336 (process_stratum_target::supports_software_single_step): ... this.
337 (process_target::supports_catch_syscall): Rename as ...
338 (process_stratum_target::supports_catch_syscall): ... this.
339 (process_target::get_ipa_tdesc_idx): Rename as ...
340 (process_stratum_target::get_ipa_tdesc_idx): ... this.
341
478f9adf
PA
3422020-02-20 Pedro Alves <palves@redhat.com>
343
344 * target.cc (set_target_ops): Simply copy the given target pointer
345 instead of creating a copy of the pointed object.
346
d633e831
TBA
3472020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
348
349 Turn process_stratum_target's get_ipa_tdesc_idx op into a method
350 of process_target.
351
352 * target.h (struct process_stratum_target): Remove the target op.
353 (class process_target): Add the target op.
354 (target_get_ipa_tdesc_idx): Update the macro.
355 * target.cc (process_target::get_ipa_tdesc_idx): Define.
356
357 Update the derived classes and callers below.
358
359 * linux-low.cc (linux_target_ops): Update.
360 (linux_get_ipa_tdesc_idx): Turn into ...
361 (linux_process_target::get_ipa_tdesc_idx): ... this.
362 * linux-low.h (class linux_process_target): Update.
363 * lynx-low.cc (lynx_target_ops): Update.
364 * nto-low.cc (nto_target_ops): Update.
365 * win32-low.cc (win32_target_ops): Update.
366
bc8d3ae4
TBA
3672020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
368
369 Turn process_stratum_target's supports_catch_syscall op into a
370 method of process_target.
371
372 * target.h (struct process_stratum_target): Remove the target op.
373 (class process_target): Add the target op.
374 (target_supports_catch_syscall): Update the macro.
375 * target.cc (process_target::supports_catch_syscall): Define.
376
377 Update the derived classes and callers below.
378
379 * linux-low.cc (linux_target_ops): Update.
380 (linux_supports_catch_syscall): Turn into ...
381 (linux_process_target::supports_catch_syscall): ... this.
382 * linux-low.h (class linux_process_target): Update.
383 * lynx-low.cc (lynx_target_ops): Update.
384 * nto-low.cc (nto_target_ops): Update.
385 * win32-low.cc (win32_target_ops): Update.
386
5303a34f
TBA
3872020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
388
389 Turn process_stratum_target's supports_software_single_step op
390 into a method of process_target.
391
392 * target.h (struct process_stratum_target): Remove the target op.
393 (class process_target): Add the target op.
394 (target_supports_software_single_step): Update the macro.
395 * target.cc (process_target::supports_software_single_step): Define.
396
397 Update the derived classes and callers below.
398
399 * linux-low.cc (linux_target_ops): Update.
400 (linux_supports_software_single_step): Turn into ...
401 (linux_process_target::supports_software_single_step): ... this.
402 * linux-low.h (class linux_process_target): Update.
403 * lynx-low.cc (lynx_target_ops): Update.
404 * nto-low.cc (nto_target_ops): Update.
405 * win32-low.cc (win32_target_ops): Update.
406
7f63b89b
TBA
4072020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
408
409 Turn process_stratum_target's thread_name and thread_handle ops
410 into methods of process_target.
411
412 * target.h (struct process_stratum_target): Remove the target ops.
413 (class process_target): Add the target ops.
414 (target_thread_name): Update the macro.
415 (target_thread_handle): Update the macro.
416 * target.cc (process_target::thread_name): Define.
417 (process_target::thread_handle): Define.
418
419 Update the derived classes and callers below.
420
421 * linux-low.cc (linux_target_ops): Update.
422 (linux_process_target::thread_name): Define.
423 (linux_process_target::thread_handle): Define.
424 * linux-low.h (class linux_process_target): Update.
425 * lynx-low.cc (lynx_target_ops): Update.
426 * nto-low.cc (nto_target_ops): Update.
427 * win32-low.cc (win32_target_ops): Update.
428
d367006f
TBA
4292020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
430
431 Turn process_stratum_target's breakpoint_kind_from_pc,
432 sw_breakpoint_from_kind, and breakpoint_kind_from_current_state
433 ops into methods of process_target.
434
435 * target.h (struct process_stratum_target): Remove the target op.
436 (class process_target): Add the target op.
437 (target_breakpoint_kind_from_pc): Update the macro.
438 (target_breakpoint_kind_from_current_state): Update the macro.
439 (default_breakpoint_kind_from_pc): Remove declaration.
440 * target.cc (default_breakpoint_kind_from_pc): Turn into ...
441 (process_target::breakpoint_kind_from_pc): ... this.
442 (process_target::breakpoint_kind_from_current_state): Define.
443
444 Update the derived classes and callers below.
445
446 * mem-break.cc (bp_size): Update.
447 (bp_opcode): Update.
448 * linux-low.cc (linux_target_ops): Update.
449 (linux_wait_1): Update.
450 (linux_breakpoint_kind_from_pc): Turn into ...
451 (linux_process_target::breakpoint_kind_from_pc): ... this.
452 (linux_sw_breakpoint_from_kind): Turn into ...
453 (linux_process_target::sw_breakpoint_from_kind): ... this.
454 (linux_breakpoint_kind_from_current_state): Turn into ...
455 (linux_process_target::breakpoint_kind_from_current_state): ... this.
456 * linux-low.h (class linux_process_target): Update.
457 * lynx-low.cc (lynx_target_ops): Update.
458 (lynx_process_target::sw_breakpoint_from_kind): Define.
459 * lynx-low.h (class lynx_process_target): Update.
460 * nto-low.cc (nto_target_ops): Update.
461 (nto_sw_breakpoint_from_kind): Turn into ...
462 (nto_process_target::sw_breakpoint_from_kind): ... this.
463 * nto-low.h (class nto_process_target): Update.
464 * win32-low.cc (win32_target_ops): Update.
465 (win32_sw_breakpoint_from_kind): Turn into ...
466 (win32_process_target::sw_breakpoint_from_kind): ... this.
467 * win32-low.h (class win32_process_target): Update.
468
c9b7b804
TBA
4692020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
470
471 Turn process_stratum_target's multifs_open, multifs_readlink,
472 multifs_unlink ops into methods of process_target.
473
474 * target.h (struct process_stratum_target): Remove the target ops.
475 (class process_target): Add the target ops. Also add
476 'supports_multifs'.
477 * target.cc: Include "fcntl.h", "unistd.h", "sys/types.h", and
478 "sys/stat.h".
479 (process_target::supports_multifs): Define.
480 (process_target::multifs_open): Define.
481 (process_target::multifs_readlink): Define.
482 (process_target::multifs_unlink): Define.
483
484 Update the derived classes and callers below.
485
486 * hostio.cc (handle_setfs): Update.
487 (handle_open): Update.
488 (handle_unlink): Update.
489 (handle_readlink): Update.
490 * linux-low.cc (linux_target_ops): Update.
491 (linux_process_target::supports_multifs): Define.
492 (linux_process_target::multifs_open): Define.
493 (linux_process_target::multifs_readlink): Define.
494 (linux_process_target::multifs_unlink): Define.
495 * linux-low.h (class linux_process_target): Update.
496 * lynx-low.cc (lynx_target_ops): Update.
497 * nto-low.cc (nto_target_ops): Update.
498 * win32-low.cc (win32_target_ops): Update.
499
8247b823
TBA
5002020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
501
502 Turn process_stratum_target's pid_to_exec_file op into a method
503 of process_target.
504
505 * target.h (struct process_stratum_target): Remove the target op.
506 (class process_target): Add the target op. Also add
507 'supports_pid_to_exec_file'.
508 * target.cc (process_target::pid_to_exec_file): Define.
509 (process_target::supports_pid_to_exec_file): Define.
510
511 Update the derived classes and callers below.
512
513 * server.cc (handle_qxfer_exec_file): Update.
514 (handle_query): Update.
515 * linux-low.cc (linux_target_ops): Update.
516 (linux_process_target::supports_pid_to_exec_file): Define.
517 (linux_process_target::pid_to_exec_file): Define.
518 * linux-low.h (class linux_process_target): Update.
519 * lynx-low.cc (lynx_target_ops): Update.
520 * nto-low.cc (nto_target_ops): Update.
521 * win32-low.cc (win32_target_ops): Update.
522
2526e0cd
TBA
5232020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
524
525 Turn process_stratum_target's supports_range_stepping op into a
526 method of process_target.
527
528 * target.h (struct process_stratum_target): Remove the target op.
529 (class process_target): Add the target op.
530 (target_supports_range_stepping): Update the macro.
531 * target.cc (process_target::supports_range_stepping): Define.
532
533 Update the derived classes and callers below.
534
535 * linux-low.cc (linux_target_ops): Update.
536 (linux_supports_range_stepping): Turn into ...
537 (linux_process_target::supports_range_stepping): ... this.
538 * linux-low.h (class linux_process_target): Update.
539 * lynx-low.cc (lynx_target_ops): Update.
540 * nto-low.cc (nto_target_ops): Update.
541 * win32-low.cc (win32_target_ops): Update.
542
79597bdd
TBA
5432020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
544
545 Turn process_stratum_target's btrace-related ops (enable_btrace,
546 disable_btrace, read_btrace, read_btrace_conf) into methods of
547 process_target.
548
549 * target.h (struct process_stratum_target): Remove the target ops.
550 (class process_target): Add the target ops.
551 (target_enable_btrace): Update.
552 (target_disable_btrace): Update.
553 (target_read_btrace): Update.
554 (target_read_btrace_conf): Update.
555 * target.cc (process_target::enable_btrace): Define.
556 (process_target::disable_btrace): Define.
557 (process_target::read_btrace): Define.
558 (process_target::read_btrace_conf): Define.
559
560 Update the derived classes and callers below.
561
562 * linux-low.cc (linux_target_ops): Update.
563 (linux_process_target:enable_btrace): Define as a wrapper around
564 linux_enable_btrace.
565 (linux_low_disable_btrace): Turn into ...
566 (linux_process_target::disable_btrace): ... this.
567 (linux_low_read_btrace): Turn into ...
568 (linux_process_target::read_btrace): ... this.
569 (linux_low_btrace_conf): Turn into ...
570 (linux_process_target::read_btrace_conf): ... this.
571 * linux-low.h (class linux_process_target): Update.
572 * lynx-low.cc (lynx_target_ops): Update.
573 * nto-low.cc (nto_target_ops): Update.
574 * win32-low.cc (win32_target_ops): Update.
575
c0245cb9
TBA
5762020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
577
578 Turn process_stratum_target's supports_agent op into a method of
579 process_target.
580
581 * target.h (struct process_stratum_target): Remove the target op.
582 (class process_target): Add the target op.
583 (target_supports_agent): Update the macro.
584 * target.cc (process_target::supports_agent): Define.
585
586 Update the derived classes and callers below.
587
588 * linux-low.cc (linux_target_ops): Update.
589 (linux_supports_agent): Turn into ...
590 (linux_process_target::supports_agent): ... this.
591 * linux-low.h (class linux_process_target): Update.
592 * lynx-low.cc (lynx_target_ops): Update.
593 * nto-low.cc (nto_target_ops): Update.
594 * win32-low.cc (win32_target_ops): Update.
595
974387bb
TBA
5962020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
597
598 Turn process_stratum_target's qxfer_libraries_svr4 op into a
599 method of process_target.
600
601 * target.h (struct process_stratum_target): Remove the target op.
602 (class process_target): Add the target op. Also add
603 'supports_qxfer_libraries_svr4'.
604 * target.cc (process_target::qxfer_libraries_svr4): Define.
605 (process_target::supports_qxfer_libraries_svr4): Define.
606
607 Update the derived classes and callers below.
608
609 * server.cc (handle_qxfer_libraries_svr4): Update.
610 (handle_query): Update.
611 * linux-low.cc (linux_target_ops): Update.
612 (linux_process_target::supports_qxfer_libraries_svr4): Define.
613 (linux_qxfer_libraries_svr4): Turn into ...
614 (linux_process_target::qxfer_libraries_svr4): ... this.
615 * linux-low.h (class linux_process_target): Update.
616 * lynx-low.cc (lynx_target_ops): Update.
617 * nto-low.cc (nto_target_ops): Update.
618 * win32-low.cc (win32_target_ops): Update.
619
c756403b
TBA
6202020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
621
622 Turn process_stratum_target's supports_disable_randomization op
623 into a method of process_target.
624
625 * target.h (struct process_stratum_target): Remove the target op.
626 (class process_target): Add the target op.
627 (target_supports_disable_randomization): Update the macro.
628 * target.cc (process_target::supports_disable_randomization): Define.
629
630 Update the derived classes and callers below.
631
632 * linux-low.cc (linux_target_ops): Update.
633 (linux_supports_disable_randomization): Turn into ...
634 (linux_process_target::supports_disable_randomization): ... this.
635 * linux-low.h (class linux_process_target): Update.
636 * lynx-low.cc (lynx_target_ops): Update.
637 * nto-low.cc (nto_target_ops): Update.
638 * win32-low.cc (win32_target_ops): Update.
639
345dafad
TBA
6402020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
641
642 Turn process_stratum_target's emit_ops op into a method of
643 process_target.
644
645 * target.h (struct process_stratum_target): Remove the target op.
646 (class process_target): Add the target op.
647 (target_emit_ops): Update the macro.
648 * target.cc (process_target::emit_ops): Define.
649
650 Update the derived classes and callers below.
651
652 * linux-low.cc (linux_target_ops): Update.
653 (linux_emit_ops): Turn into ...
654 (linux_process_target::emit_ops): ... this.
655 * linux-low.h (class linux_process_target): Update.
656 * lynx-low.cc (lynx_target_ops): Update.
657 * nto-low.cc (nto_target_ops): Update.
658 * win32-low.cc (win32_target_ops): Update.
659
c23c9391
TBA
6602020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
661
662 Turn process_stratum_target's install_fast_tracepoint_jump_pad
663 and get_min_fast_tracepoint_insn_len ops into methods of
664 process_target.
665
666 * target.h (struct process_stratum_target): Remove the target ops.
667 (class process_target): Add the target ops. Also add
668 'supports_fast_tracepoints'.
669 (target_supports_fast_tracepoints): Update the macro.
670 (target_get_min_fast_tracepoint_insn_len): Update the macro.
671 (install_fast_tracepoint_jump_pad): Update and rename the macro
672 to ...
673 (target_install_fast_tracepoint_jump_pad): ... this.
674 * target.cc (process_target::supports_fast_tracepoints): Define.
675 (process_target::install_fast_tracepoint_jump_pad): Define.
676 (process_target::get_min_fast_tracepoint_insn_len): Define.
677
678 Update the derived classes and callers below.
679
680 * tracepoint.cc (install_fast_tracepoint): Update.
681 * linux-low.cc (linux_target_ops): Update.
682 (linux_process_target::supports_fast_tracepoints): Define.
683 (linux_install_fast_tracepoint_jump_pad): Turn into ...
684 (linux_process_target::install_fast_tracepoint_jump_pad): ... this.
685 (linux_get_min_fast_tracepoint_insn_len): Turn into ...
686 (linux_process_target::get_min_fast_tracepoint_insn_len): ... this.
687 * linux-low.h (class linux_process_target): Update.
688 * lynx-low.cc (lynx_target_ops): Update.
689 * nto-low.cc (nto_target_ops): Update.
690 * win32-low.cc (win32_target_ops): Update.
691
5c9eb2f2
TBA
6922020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
693
694 Turn process_stratum_target's stabilize_threads op into a
695 method of process_target.
696
697 * target.h (struct process_stratum_target): Remove the target op.
698 (class process_target): Add the target op.
699 (target_stabilize_threads): Update the macro.
700 * target.cc (process_target::stabilize_threads): Define.
701
702 Update the derived classes and callers below.
703
704 * server.cc (handle_status): Update.
705 * tracepoint.cc (cmd_qtdp): Update.
706 (cmd_qtstart): Update.
707 * linux-low.cc (linux_target_ops): Update.
708 (linux_stabilize_threads): Turn into ...
709 (linux_process_target::stabilize_threads): ... this.
710 (linux_wait_1): Update.
711 * linux-low.h (class linux_process_target): Update.
712 * lynx-low.cc (lynx_target_ops): Update.
713 * nto-low.cc (nto_target_ops): Update.
714 * win32-low.cc (win32_target_ops): Update.
715
29e8dc09
TBA
7162020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
717
718 Turn process_stratum_target's pause_all and unpause_all ops
719 into methods of process_target.
720
721 * target.h (struct process_stratum_target): Remove the target ops.
722 (class process_target): Add the target ops.
723 (pause_all): Update the macro and rename to...
724 (target_pause_all): ... this.
725 (unpause_all): Update the macro and rename to...
726 (target_unpause_all): ... this.
727 * target.cc (process_target::pause_all): Define.
728 (process_target::unpause_all): Define.
729
730 Update the derived classes and callers below.
731
732 * server.cc (handle_status): Update.
733 * tracepoint.cc (clear_installed_tracepoints): Update.
734 (cmd_qtdp): Update.
735 (cmd_qtstart): Update.
736 (stop_tracing): Update.
737 (cmd_qtstatus): Update.
738 (upload_fast_traceframes): Update.
739 (run_inferior_command): Update.
740 * linux-low.cc (linux_target_ops): Update.
741 (linux_pause_all): Turn into ...
742 (linux_process_target::pause_all): ... this.
743 (linux_unpause_all): Turn into ...
744 (linux_process_target::unpause_all): ... this.
745 (linux_process_target::prepare_to_access_memory): Update.
746 (linux_process_target::done_accessing_memory): Update.
747 * linux-low.h (class linux_process_target): Update.
748 * lynx-low.cc (lynx_target_ops): Update.
749 * nto-low.cc (nto_target_ops): Update.
750 * win32-low.cc (win32_target_ops): Update.
751
4e2e869c
TBA
7522020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
753
754 Turn process_stratum_target's get_tib_address op into a method of
755 process_target.
756
757 * target.h (struct process_stratum_target): Remove the target op.
758 (class process_target): Add the target op. Also add
759 'supports_get_tib_address'.
760 * target.cc (process_target::get_tib_address): Define.
761 (process_target::supports_get_tib_address): Define.
762
763 Update the derived classes and callers below.
764
765 * server.cc (handle_query): Update.
766 * linux-low.cc (win32_target_ops): Update.
767 * lynx-low.cc (lynx_target_ops): Update.
768 * nto-low.cc (nto_target_ops): Update.
769 * win32-low.cc (win32_target_ops): Update.
770 (win32_process_target::supports_get_tib_address): Define.
771 (win32_get_tib_address): Turn into ...
772 (win32_process_target::get_tib_address): ... this.
773 * win32-low.h (class win32_process_target): Update.
774
68119632
TBA
7752020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
776
777 Turn process_stratum_target's thread_stopped op into a method of
778 process_target.
779
780 * target.h (struct process_stratum_target): Remove the target op.
781 (class process_target): Add the target op. Also add
782 'supports_thread_stopped'.
783 (target_thread_stopped): Update the macro.
784 * target.cc (process_target::thread_stopped): Define.
785 (process_target::supports_thread_stopped): Define.
786 (prepare_to_access_memory): Update.
787
788 Update the derived classes and callers below.
789
790 * server.cc (queue_stop_reply_callback): Update.
791 * linux-low.cc (linux_target_ops): Update.
792 (linux_process_target::supports_thread_stopped): Define.
793 (linux_thread_stopped): Turn into ...
794 (linux_process_target::thread_stopped): ... this.
795 * linux-low.h (class linux_process_target): Update.
796 * lynx-low.cc (lynx_target_ops): Update.
797 * nto-low.cc (nto_target_ops): Update.
798 * win32-low.cc (win32_target_ops): Update.
799
770d8f6a
TBA
8002020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
801
802 Turn process_stratum_target's read_pc and write_pc ops into
803 methods of process_target.
804
805 * target.h (struct process_stratum_target): Remove the target ops.
806 (class process_target): Add the target ops.
807 * target.cc (process_target::read_pc): Define.
808 (process_target::write_pc): Define.
809
810 Update the derived classes and callers below.
811
812 * regcache.cc (regcache_read_pc): Update.
813 (regcache_write_pc): Update.
814 * linux-low.cc (linux_target_ops): Update.
815 (linux_read_pc): Turn into ...
816 (linux_process_target::read_pc): ... this.
817 (linux_write_pc): Turn into ...
818 (linux_process_target::write_pc): ... this.
819 * linux-low.h (class linux_process_target): Update.
820 * lynx-low.cc (lynx_target_ops): Update.
821 * nto-low.cc (nto_target_ops): Update.
822 * win32-low.cc (win32_target_ops): Update.
823
290732bf
TBA
8242020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
825
826 Turn process_stratum_target's supports_tracepoints op into a
827 method of process_target.
828
829 * target.h (struct process_stratum_target): Remove the target op.
830 (class process_target): Add the target op.
831 (target_supports_tracepoints): Update the macro.
832 * target.cc (process_target::supports_tracepoints): Define.
833
834 Update the derived classes and callers below.
835
836 * linux-low.cc (linux_target_ops): Update.
837 (linux_supports_tracepoints): Turn into ...
838 (linux_process_target::supports_tracepoints): ... this.
839 * linux-low.h (class linux_process_target): Update.
840 * lynx-low.cc (lynx_target_ops): Update.
841 * nto-low.cc (nto_target_ops): Update.
842 * win32-low.cc (win32_target_ops): Update.
843
0df28b1b
TBA
8442020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
845
846 Turn process_stratum_target's process_qsupported op into a method
847 of process_target.
848
849 * target.h (struct process_stratum_target): Remove the target op.
850 (class process_target): Add the target op.
851 (target_process_qsupported): Update the macro.
852 * target.cc (process_target::process_qsupported): Define.
853
854 Update the derived classes and callers below.
855
856 * linux-low.cc (linux_target_ops): Update.
857 (linux_process_qsupported): Turn into ...
858 (linux_process_target::process_qsupported): ... this.
859 * linux-low.h (class linux_process_target): Update.
860 * lynx-low.cc (lynx_target_ops): Update.
861 * nto-low.cc (nto_target_ops): Update.
862 * win32-low.cc (win32_target_ops): Update.
863
9da41fda
TBA
8642020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
865
866 Turn process_stratum_target's read_loadmap op into a method of
867 process_target.
868
869 * target.h (struct process_stratum_target): Remove the target op.
870 (class process_target): Add the target op. Also add
871 'supports_read_loadmap'.
872 * target.cc (process_target::read_loadmap): Define.
873 (process_target::supports_read_loadmap): Define.
874
875 Update the derived classes and callers below.
876
877 * server.cc (handle_qxfer_fdpic): Update.
878 (handle_query): Update.
879 * linux-low.cc (linux_target_ops): Update.
880 (linux_process_target::supports_read_loadmap): Define.
881 (linux_read_loadmap): Turn into ...
882 (linux_process_target::read_loadmap): ... this.
883 * linux-low.h (class linux_process_target): Update.
884 * lynx-low.cc (lynx_target_ops): Update.
885 * nto-low.cc (nto_target_ops): Update.
886 * win32-low.cc (win32_target_ops): Update.
887
95a45fc1
TBA
8882020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
889
890 Turn process_stratum_target's core_of_thread op into a method of
891 process_target.
892
893 * target.h (struct process_stratum_target): Remove the target op.
894 (class process_target): Add the target op.
895 (target_core_of_thread): Update the macro.
896 * target.cc (process_target::core_of_thread): Define.
897
898 Update the derived classes and callers below.
899
900 * linux-low.cc (linux_target_ops): Update.
901 (linux_process_target::core_of_thread): Define.
902 * linux-low.h (class linux_process_target): Update.
903 * lynx-low.cc (lynx_target_ops): Update.
904 * nto-low.cc (nto_target_ops): Update.
905 * win32-low.cc (win32_target_ops): Update.
906
55cf3021
TBA
9072020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
908
909 Turn process_stratum_target's handle_monitor_command op into a
910 method of process_target.
911
912 * target.h (struct process_stratum_target): Remove the target op.
913 (class process_target): Add the target op.
914 (target_handle_monitor_command): Update the macro.
915 * target.cc (process_target::handle_monitor_command): Define.
916
917 Update the derived classes and callers below.
918
919 * server.cc (handle_query): Update.
920 * linux-low.cc (linux_target_ops): Update.
921 (linux_process_target::handle_monitor_command): Define.
922 * linux-low.h (class linux_process_target): Update.
923 * lynx-low.cc (lynx_target_ops): Update.
924 * nto-low.cc (nto_target_ops): Update.
925 * win32-low.cc (win32_target_ops): Update.
926
fb00dfce
TBA
9272020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
928
929 Turn process_stratum_target's handle_new_gdb_connection op into a
930 method of process_target.
931
932 * target.h (struct process_stratum_target): Remove the target op.
933 (class process_target): Add the target op.
934 (target_handle_new_gdb_connection): Update the macro.
935 * target.cc (process_target::handle_new_gdb_connection): Define.
936
937 Update the derived classes and callers below.
938
939 * linux-low.cc (linux_target_ops): Update.
940 (linux_handle_new_gdb_connection): Turn into ...
941 (linux_process_target::handle_new_gdb_connection): ... this.
942 * linux-low.h (class linux_process_target): Update.
943 * lynx-low.cc (lynx_target_ops): Update.
944 * nto-low.cc (nto_target_ops): Update.
945 * win32-low.cc (win32_target_ops): Update.
946
9690a72a
TBA
9472020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
948
949 Turn process_stratum_target's supports_fork_events,
950 supports_vfork_events, and supports_exec_events ops into methods
951 of process_target.
952
953 * target.h (struct process_stratum_target): Remove the target ops.
954 (class process_target): Add the target ops.
955 (target_supports_fork_events): Update the macro.
956 (target_supports_vfork_events): Update the macro.
957 (target_supports_exec_events): Update the macro.
958 * target.cc (process_target::supports_fork_events): Define.
959 (process_target::supports_vfork_events): Define.
960 (process_target::supports_exec_events): Define.
961
962 Update the derived classes and callers below.
963
964 * linux-low.cc (linux_target_ops): Update.
965 (linux_supports_fork_events): Turn into ...
966 (linux_process_target::supports_fork_events): ... this.
967 (linux_supports_vfork_events): Turn into ...
968 (linux_process_target::supports_vfork_events): ... this.
969 (linux_supports_exec_events): Turn into ...
970 (linux_process_target::supports_exec_events): ... this.
971 * linux-low.h (class linux_process_target): Update.
972 * lynx-low.cc (lynx_target_ops): Update.
973 * nto-low.cc (nto_target_ops): Update.
974 * win32-low.cc (win32_target_ops): Update.
975
652aef77
TBA
9762020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
977
978 Turn process_stratum_target's supports_multi_process op into a
979 method of process_target.
980
981 * target.h (struct process_stratum_target): Remove the target op.
982 (class process_target): Add the target op.
983 * target.cc (process_target::supports_multi_process): Define.
984 (target_supports_multi_process): Update.
985
986 Update the derived classes and callers below.
987
988 * linux-low.cc (linux_target_ops): Update.
989 (linux_supports_multi_process): Turn into ...
990 (linux_process_target::supports_multi_process): ... this.
991 * linux-low.h (class linux_process_target): Update.
992 * lynx-low.cc (lynx_target_ops): Update.
993 * nto-low.cc (nto_target_ops): Update.
994 * win32-low.cc (win32_target_ops): Update.
995
0dc587d4
TBA
9962020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
997
998 Turn process_stratum_target's supports_non_stop, async, and
999 start_non_stop ops into methods of process_target.
1000
1001 * target.h (struct process_stratum_target): Remove the target ops.
1002 (class process_target): Add the target ops.
1003 (target_supports_non_stop): Update the macro.
1004 (target_async): Update the macro.
1005 (start_non_stop): Remove declaration.
1006 * target.cc (process_target::supports_non_stop): Define.
1007 (process_target::async): Define.
1008 (process_target::start_non_stop): Define.
1009 (start_non_stop): Remove.
1010
1011 Update the derived classes and callers below.
1012
1013 * server.cc (handle_qxfer_siginfo): Update.
1014 (handle_query): Update.
1015 * linux-low.cc (linux_target_ops): Update.
1016 (linux_supports_non_stop): Turn into ...
1017 (linux_process_target::supports_non_stop): ... this.
1018 (linux_async): Turn into ...
1019 (linux_process_target::async): ... this.
1020 (linux_start_non_stop): Turn into ...
1021 (linux_process_target::start_non_stop): ... this.
1022 * linux-low.h (class linux_process_target): Update.
1023 * lynx-low.cc (lynx_target_ops): Update.
1024 * nto-low.cc (nto_target_ops): Update.
1025 (nto_supports_non_stop): Remove; rely on the default behavior
1026 instead.
1027 * win32-low.cc (win32_target_ops): Update.
1028
d7abedf7
TBA
10292020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1030
1031 Turn process_stratum_target's qxfer_siginfo op into a method of
1032 process_target.
1033
1034 * target.h (struct process_stratum_target): Remove the target op.
1035 (class process_target): Add the target op. Also add
1036 'supports_qxfer_siginfo'.
1037 * target.cc (process_target::qxfer_siginfo): Define.
1038 (process_target::supports_qxfer_siginfo): Define.
1039
1040 Update the derived classes and callers below.
1041
1042 * server.cc (handle_qxfer_siginfo): Update.
1043 (handle_query): Update.
1044 * linux-low.cc (linux_target_ops): Update.
1045 (linux_process_target::supports_qxfer_siginfo): Define.
1046 (linux_xfer_siginfo): Turn into ...
1047 (linux_process_target::qxfer_siginfo): ... this.
1048 * linux-low.h (class linux_process_target): Update.
1049 * lynx-low.cc (lynx_target_ops): Update.
1050 * nto-low.cc (nto_target_ops): Update.
1051 * win32-low.cc (win32_target_ops): Update.
1052
2d0795ee
TBA
10532020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1054
1055 Turn process_stratum_target's qxfer_osdata op into a method of
1056 process_target.
1057
1058 * target.h (struct process_stratum_target): Remove the target op.
1059 (class process_target): Add the target op. Also add
1060 'supports_qxfer_osdata'.
1061 * target.cc (process_target::qxfer_osdata): Define.
1062 (process_target::supports_qxfer_osdata): Define.
1063
1064 Update the derived classes and callers below.
1065
1066 * server.cc (handle_qxfer_osdata): Update.
1067 (handle_query): Update.
1068 * linux-low.cc (linux_target_ops): Update.
1069 (linux_process_target::supports_qxfer_osdata): Define.
1070 (linux_qxfer_osdata): Turn into ...
1071 (linux_process_target::qxfer_osdata): ... this.
1072 * linux-low.h (class linux_process_target): Update.
1073 * lynx-low.cc (lynx_target_ops): Update.
1074 * nto-low.cc (nto_target_ops): Update.
1075 * win32-low.cc (win32_target_ops): Update.
1076
ea06bbaa
TBA
10772020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1078
1079 Turn process_stratum_target's hostio_last_error op into a
1080 method of process_target.
1081
1082 * target.h (struct process_stratum_target): Remove the target op.
1083 (class process_target): Add the target op.
1084 * target.cc: Add "hostio.h" to includes.
1085 (process_target::hostio_last_error): Define.
1086
1087 Update the derived classes and callers below.
1088
1089 * hostio.cc (hostio_error): Update.
1090 * linux-low.cc: Remove "hostio.h" from includes.
1091 (linux_target_ops): Update.
1092 * lynx-low.cc (lynx_target_ops): Update.
1093 * nto-low.cc (nto_target_ops): Update.
1094 * win32-low.h (class win32_process_target): Update.
1095 * win32-low.cc (win32_target_ops): Update.
1096 (wince_hostio_last_error): Turn into ...
1097 (win32_process_target::hostio_last_error): ... this.
1098
6e3fd7e9
TBA
10992020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1100
1101 Turn process_stratum_target's get_tls_address op into a method of
1102 process_target.
1103
1104 * target.h (struct process_stratum_target): Remove the target op.
1105 (class process_target): Add the target op. Also add
1106 'supports_get_tls_address'.
1107 * target.cc (process_target::get_tls_address): Define.
1108 (process_target::supports_get_tls_address): Define.
1109
1110 Update the derived classes and callers below.
1111
1112 * server.cc (handle_query): Update.
1113 * linux-low.cc (linux_target_ops): Update.
1114 (linux_process_target::supports_get_tls_address): Define.
1115 (linux_process_target::get_tls_address): Define.
1116 * linux-low.h (class linux_process_target): Update.
1117 * lynx-low.cc (lynx_target_ops): Update.
1118 * nto-low.cc (nto_target_ops): Update.
1119 * win32-low.cc (win32_target_ops): Update.
1120
5203ae1e
TBA
11212020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1122
1123 Turn process_stratum_target's read_offsets op into a method of
1124 process_target.
1125
1126 * target.h (struct process_stratum_target): Remove the target op.
1127 (class process_target): Add the target op. Also add
1128 'supports_read_offsets'.
1129 * target.cc (process_target::read_offsets): Define.
1130 (process_target::supports_read_offsets): Define.
1131
1132 Update the derived classes and callers below.
1133
1134 * server.cc (handle_query): Update.
1135 * linux-low.cc (SUPPORTS_READ_OFFSETS): New #define directive.
1136 (linux_target_ops): Update.
1137 (linux_process_target::supports_read_offsets): Define.
1138 (linux_read_offsets): Turn into ...
1139 (linux_process_target::read_offsets): ... this.
1140 * linux-low.h (class linux_process_target): Update.
1141 * lynx-low.cc (lynx_target_ops): Update.
1142 * nto-low.cc (nto_target_ops): Update.
1143 * win32-low.cc (win32_target_ops): Update.
1144
6eeb5c55
TBA
11452020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1146
1147 Turn process_stratum_target's stopped_by_watchpoint and
1148 stopped_data_address ops into methods of process_target.
1149
1150 * target.h (struct process_stratum_target): Remove the target ops.
1151 (class process_target): Add the target ops.
1152 * target.cc (process_target::stopped_by_watchpoint): Define.
1153 (process_target::stopped_data_address): Define.
1154
1155 Update the derived classes and callers below.
1156
1157 * remote-utils.cc (prepare_resume_reply): Update.
1158 * linux-low.cc (linux_target_ops): Update.
1159 (linux_stopped_by_watchpoint): Turn into ...
1160 (linux_process_target::stopped_by_watchpoint): ... this.
1161 (linux_stopped_data_address): Turn into ...
1162 (linux_process_target::stopped_data_address): ... this.
1163 * linux-low.h (class linux_process_target): Update.
1164 * lynx-low.cc (lynx_target_ops): Update.
1165 * nto-low.cc (nto_target_ops): Update.
1166 (nto_stopped_by_watchpoint): Turn into ...
1167 (nto_process_target::stopped_by_watchpoint): ... this.
1168 (nto_stopped_data_address): Turn into ...
1169 (nto_process_target::stopped_data_address): ... this.
1170 * nto-low.h (class nto_process_target): Update.
1171 * win32-low.cc (win32_target_ops): Update.
1172 (win32_stopped_by_watchpoint): Turn into ...
1173 (win32_process_target::stopped_by_watchpoint): ... this.
1174 (win32_stopped_data_address): Turn into ...
1175 (win32_process_target::stopped_data_address): ... this.
1176 * win32-low.h (class win32_process_target): Update.
1177
22aa6223
TBA
11782020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1179
1180 Turn process_stratum_target's supports_hardware_single_step op into
1181 a method of process_target.
1182
1183 * target.h (struct process_stratum_target): Remove the target op.
1184 (class process_target): Add the target op.
1185 (target_supports_hardware_single_step): Update the macro.
1186 (target_can_do_hardware_single_step): Remove declaration.
1187 * target.cc (process_target::supports_hardware_single_step): Define.
1188 (target_can_do_hardware_single_step): Remove.
1189
1190 Update the derived classes and callers below.
1191
1192 * linux-low.h (class linux_process_target): Update.
1193 * linux-low.cc (linux_target_ops): Update.
1194 (linux_supports_hardware_single_step): Turn into ...
1195 (linux_process_target::supports_hardware_single_step): ... this.
1196 * lynx-low.h (class lynx_process_target): Update.
1197 * lynx-low.cc (lynx_target_ops): Update.
1198 (lynx_process_target::supports_hardware_single_step): Define.
1199 * nto-low.h (class nto_process_target): Update.
1200 * nto-low.cc (nto_target_ops): Update.
1201 (nto_process_target::supports_hardware_single_step): Define.
1202 * win32-low.h (class win32_process_target): Update.
1203 * win32-low.cc (win32_target_ops): Update.
1204 (win32_process_target::supports_hardware_single_step): Define.
1205
93fe88b2
TBA
12062020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1207
1208 Turn process_stratum_target's {supports_}stopped_by_hw_breakpoint
1209 ops into methods of process_target.
1210
1211 * target.h (struct process_stratum_target): Remove the target ops.
1212 (class process_target): Add the target ops.
1213 (target_stopped_by_hw_breakpoint): Update the macro.
1214 (target_supports_stopped_by_hw_breakpoint): Update the macro.
1215 * target.cc (process_target::stopped_by_hw_breakpoint): Define.
1216 (process_target::supports_stopped_by_hw_breakpoint): Define.
1217
1218 Update the derived classes and callers below.
1219
1220 * linux-low.cc (linux_target_ops): Update.
1221 (linux_stopped_by_hw_breakpoint): Turn into ...
1222 (linux_process_target::stopped_by_hw_breakpoint): ... this.
1223 (linux_supports_stopped_by_hw_breakpoint): Turn into ...
1224 (linux_process_target::supports_stopped_by_hw_breakpoint): ... this.
1225 * linux-low.h (class linux_process_target): Update.
1226 * lynx-low.cc (lynx_target_ops): Update.
1227 * nto-low.cc (nto_target_ops): Update.
1228 * win32-low.cc (win32_target_ops): Update.
1229
84320c4e
TBA
12302020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1231
1232 Turn process_stratum_target's {supports_}stopped_by_sw_breakpoint
1233 ops into methods of process_target.
1234
1235 * target.h (struct process_stratum_target): Remove the target ops.
1236 (class process_target): Add the target ops.
1237 (target_stopped_by_sw_breakpoint): Update the macro.
1238 (target_supports_stopped_by_sw_breakpoint): Update the macro.
1239 * target.cc (process_target::stopped_by_sw_breakpoint): Define.
1240 (process_target::supports_stopped_by_sw_breakpoint): Define.
1241
1242 Update the derived classes and callers below.
1243
1244 * linux-low.cc (linux_target_ops): Update.
1245 (linux_stopped_by_sw_breakpoint): Turn into ...
1246 (linux_process_target::stopped_by_sw_breakpoint): ... this.
1247 (linux_supports_stopped_by_sw_breakpoint): Turn into ...
1248 (linux_process_target::supports_stopped_by_sw_breakpoint): ... this.
1249 * linux-low.h (class linux_process_target): Update.
1250 * lynx-low.cc (lynx_target_ops): Update.
1251 * nto-low.cc (nto_target_ops): Update.
1252 * win32-low.cc (win32_target_ops): Update.
1253
7e0bde70
TBA
12542020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1255
1256 Turn process_stratum_target's insert_point and remove_point ops
1257 into methods of process_target.
1258
1259 * target.h (struct process_stratum_target): Remove the target ops.
1260 (class process_target): Add the target ops.
1261 * target.cc (process_target::insert_point): Define.
1262 (process_target::remove_point): Define.
1263
1264 Update the derived classes and callers below.
1265
1266 * mem-break.cc (set_raw_breakpoint_at): Update.
1267 (delete_raw_breakpoint): Update.
1268 (uninsert_raw_breakpoint): Update.
1269 (reinsert_raw_breakpoint): Update.
1270 * linux-low.cc (linux_target_ops): Update.
1271 (linux_insert_point): Turn into ...
1272 (linux_process_target::insert_point): ... this.
1273 (linux_remove_point): Turn into ...
1274 (linux_process_target::remove_point): ... this.
1275 * linux-low.h (class linux_process_target): Update.
1276 * lynx-low.cc (lynx_target_ops): Update.
1277 * nto-low.cc (nto_target_ops): Update.
1278 (nto_insert_point): Turn into ...
1279 (nto_process_target::insert_point): ... this.
1280 (nto_remove_point): Turn into ...
1281 (nto_process_target::remove_point): ... this.
1282 * nto-low.h (class nto_process_target): Update.
1283 * win32-low.cc (win32_target_ops): Update.
1284 (win32_insert_point): Turn into ...
1285 (win32_process_target::insert_point): ... this.
1286 (win32_remove_point): Turn into ...
1287 (win32_process_target::remove_point): ... this.
1288 * win32-low.h (class win32_process_target): Update.
1289
a2b2297a
TBA
12902020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1291
1292 Turn process_stratum_target's supports_z_point_type op into a
1293 method of process_target.
1294
1295 * target.h (struct process_stratum_target): Remove the target op.
1296 (class process_target): Add the target op.
1297 * target.cc (process_target::supports_z_point_type): Define.
1298
1299 Update the derived classes and callers below.
1300
1301 * mem-break.cc (z_type_supported): Update.
1302 * linux-low.cc (linux_target_ops): Update.
1303 (linux_supports_z_point_type): Turn into ...
1304 (linux_process_target::supports_z_point_type): ... this.
1305 * linux-low.h (class linux_process_target): Update.
1306 * lynx-low.cc (lynx_target_ops): Update.
1307 * nto-low.cc (nto_target_ops): Update.
1308 (nto_supports_z_point_type): Turn into ...
1309 (nto_process_target::supports_z_point_type): ... this.
1310 * nto-low.h (class nto_process_target): Update.
1311 * win32-low.cc (win32_target_ops): Update.
1312 (win32_supports_z_point_type): Turn into ...
1313 (win32_process_target::supports_z_point_type): ... this.
1314 * win32-low.h (class win32_process_target): Update.
1315
eac215cc
TBA
13162020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1317
1318 Turn process_stratum_target's read_auxv op into a method of
1319 process_target.
1320
1321 * target.h (class process_stratum_target): Remove the target op.
1322 (struct process_target): Add the target op. Also add
1323 'supports_read_auxv'.
1324 * target.cc (process_target::read_auxv): Define.
1325 (process_target::supports_read_auxv): Define.
1326
1327 Update the derived classes and callers below.
1328
1329 * server.cc (handle_qxfer_auxv): Update.
1330 (handle_query): Update.
1331 * linux-low.cc (linux_target_ops): Update.
1332 (linux_process_target::supports_read_auxv): Define.
1333 (linux_read_auxv): Turn into ...
1334 (linux_process_target::read_auxv): ... this.
1335 * linux-low.h (class linux_process_target): Update.
1336 * lynx-low.cc (lynx_target_ops): Update.
1337 * nto-low.cc (nto_target_ops): Update.
1338 (nto_process_target::supports_read_auxv): Define.
1339 (nto_read_auxv): Turn into ...
1340 (nto_process_target::read_auxv): ... this.
1341 * nto-low.h (class nto_process_target): Update.
1342 * win32-low.cc (win32_target_ops): Update.
1343
eb497a2a
TBA
13442020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1345
1346 Turn process_stratum_target's request_interrupt op into a method of
1347 process_target.
1348
1349 * target.h (struct process_stratum_target): Remove the target op.
1350 (class process_target): Add the target op.
1351
1352 Update the derived classes and callers below.
1353
1354 * remote-utils.cc (putpkt_binary_1): Update.
1355 (input_interrupt): Update.
1356 (getpkt): Update.
1357 * server.cc (handle_v_requests): Update.
1358 * linux-low.cc (linux_target_ops): Update.
1359 (linux_request_interrupt): Turn into ...
1360 (linux_process_target::request_interrupt): ... this.
1361 * linux-low.h (class linux_process_target): Update.
1362 * lynx-low.cc (lynx_target_ops): Update.
1363 (lynx_request_interrupt): Turn into ...
1364 (lynx_process_target::request_interrupt): ... this.
1365 * lynx-low.h (class lynx_process_target): Update.
1366 * nto-low.cc (nto_target_ops): Update.
1367 (nto_request_interrupt): Turn into ...
1368 (nto_process_target::request_interrupt): ... this.
1369 * nto-low.h (class nto_process_target): Update.
1370 * win32-low.cc (win32_target_ops): Update.
1371 (win32_request_interrupt): Turn into ...
1372 (win32_process_target::request_interrupt): ... this.
1373 * win32-low.h (class win32_process_target): Update.
1374
2a31c7aa
TBA
13752020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1376
1377 Turn process_stratum_target's look_up_symbols op into a method of
1378 process_target.
1379
1380 * target.h (struct process_stratum_target): Remove the target op.
1381 (class process_target): Add the target op.
1382 * target.cc (process_target::look_up_symbols): Define.
1383
1384 Update the derived classes and callers below.
1385
1386 * server.cc (handle_query): Update.
1387 * linux-low.cc (linux_target_ops): Update.
1388 (linux_look_up_symbols): Turn into ...
1389 (linux_process_target::look_up_symbols): ... this.
1390 * linux-low.h (class linux_process_target): Update.
1391 * lynx-low.cc (lynx_target_ops): Update.
1392 * nto-low.cc (nto_target_ops): Update.
1393 * win32-low.cc (win32_target_ops): Update.
1394
e2558df3
TBA
13952020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1396
1397 Turn process_stratum_target's read_memory and write_memory
1398 ops into methods of process_target.
1399
1400 * target.h (struct process_stratum_target): Remove the target ops.
1401 (class process_target): Add the target ops.
1402
1403 Update the derived classes and callers below.
1404
1405 * linux-aarch32-low.cc (arm_breakpoint_at): Update.
1406 * linux-aarch64-low.cc (aarch64_breakpoint_at): Update.
1407 * linux-arm-low.cc (arm_sigreturn_next_pc): Update.
1408 (arm_get_syscall_trapinfo): Update.
1409 * linux-cris-low.cc (cris_breakpoint_at): Update.
1410 * linux-crisv32-low.cc (cris_breakpoint_at): Update.
1411 * linux-m32r-low.cc (m32r_breakpoint_at): Update.
1412 * linux-mips-low.cc (mips_breakpoint_at): Update.
1413 * linux-nios2-low.cc (nios2_breakpoint_at): Update.
1414 * linux-ppc-low.cc (ppc_breakpoint_at): Update.
1415 * linux-sh-low.cc (sh_breakpoint_at): Update.
1416 * linux-sparc-low.cc (sparc_fill_gregset_to_stack): Update.
1417 (sparc_store_gregset_from_stack): Update.
1418 (sparc_breakpoint_at): Update.
1419 * linux-tic6x-low.cc (tic6x_breakpoint_at): Update.
1420 * linux-tile-low.cc (tile_breakpoint_at): Update.
1421 * linux-x86-low.cc (x86_breakpoint_at): Update.
1422 * linux-xtensa-low.cc (xtensa_breakpoint_at): Update.
1423 * mem-brea.cc (insert_memory_breakpoint): Update.
1424 (validate_inserted_breakpoint): Update.
1425 * target.cc (read_inferior_memory): Update.
1426 (target_write_memory): Update.
1427 * linux-low.cc (linux_target_ops): Update.
1428 (linux_read_memory): Make a wrapper around the read_memory target
1429 op call.
1430 (linux_process_target::read_memory): Rename from linux_read_memory.
1431 (linux_write_memory): Turn into ...
1432 (linux_process_target::write_memory): ... this.
1433 * linux-low.h (class linux_process_target): Update.
1434 * lynx-low.cc (lynx_target_ops): Update.
1435 (lynx_read_memory): Turn into ...
1436 (lynx_process_target::read_memory): ... this.
1437 (lynx_write_memory): Turn into ...
1438 (lynx_process_target::write_memory): ... this.
1439 * lynx-low.h (class lynx_process_target): Update.
1440 * nto-low.cc (nto_target_ops): Update.
1441 (nto_read_memory): Turn into ...
1442 (nto_process_target::read_memory): ... this.
1443 (nto_write_memory): Turn into ...
1444 (nto_process_target::write_memory): ... this.
1445 * nto-low.h (class nto_process_target): Update.
1446 * win32-low.cc (win32_target_ops): Update.
1447 (win32_read_inferior_memory): Turn into ...
1448 (win32_process_target::read_memory): ... this.
1449 (win32_write_inferior_memory): Turn into ...
1450 (win32_process_target::write_memory): ... this.
1451 * win32-low.h (class win32_process_target): Update.
1452
79b44087
TBA
14532020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1454
1455 Turn process_stratum_target's prepare_to_access_memory and
1456 done_accessing_memory ops into methods of process_target.
1457
1458 * target.h (struct process_stratum_target): Remove the target ops.
1459 (class process_target): Add the target ops.
1460 * target.cc (process_target::prepare_to_access_memory): Define.
1461 (process_target::done_accessing_memory): Define.
1462 (prepare_to_access_memory): Update.
1463 (done_accessing_memory): Update.
1464
1465 Update the derived classes and callers below.
1466
1467 * linux-low.cc (linux_target_ops): Update.
1468 (linux_prepare_to_access_memory): Turn into ...
1469 (linux_process_target::prepare_to_access_memory): ... this.
1470 (linux_done_accessing_memory): Turn into ...
1471 (linux_process_target::done_accessing_memory): ... this.
1472 * linux-low.h (class linux_process_target): Update.
1473 * lynx-low.cc (lynx_target_ops): Update.
1474 * nto-low.cc (nto_target_ops): Update.
1475 * win32-low.cc (win32_target_ops): Update.
1476
a5a4d4cd
TBA
14772020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1478
1479 Turn process_stratum_target's fetch_registers and store_registers
1480 ops into methods of process_target.
1481
1482 * target.h (struct process_stratum_target): Remove the target ops.
1483 (class process_target): Add the target ops.
1484 (fetch_inferior_registers): Update the macro.
1485 (store_inferior_registers): Update the macro.
1486
1487 Update the derived classes and callers below.
1488
1489 * linux-low.cc (linux_target_ops): Update.
1490 (linux_fetch_registers): Turn into ...
1491 (linux_process_target::fetch_registers): ... this.
1492 (linux_store_registers): Turn into ...
1493 (linux_process_target::store_registers): ... this.
1494 * linux-low.h (class linux_process_target): Update.
1495 * lynx-low.cc (lynx_target_ops): Update.
1496 (lynx_fetch_registers): Turn into ...
1497 (lynx_process_target::fetch_registers): ... this.
1498 (lynx_store_registers): Turn into ...
1499 (lynx_process_target::store_registers): ... this.
1500 * lynx-low.h (class lynx_process_target): Update.
1501 * nto-low.cc (nto_target_ops): Update.
1502 (nto_fetch_registers): Turn into ...
1503 (nto_process_target::fetch_registers): ... this.
1504 (nto_store_registers): Turn into ...
1505 (nto_process_target::store_registers): ... this.
1506 * nto-low.h (class nto_process_target): Update.
1507 * win32-low.cc (win32_target_ops): Update.
1508 (win32_fetch_inferior_registers): Turn into ...
1509 (win32_process_target::fetch_registers): ... this.
1510 (win32_store_inferior_registers): Turn into ...
1511 (win32_process_target::store_registers): ... this.
1512 * win32-low.h (class win32_process_target): Update.
1513
6532e7e3
TBA
15142020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1515
1516 Turn process_stratum_target's wait op into a method of
1517 process_target.
1518
1519 * target.h (struct process_stratum_target): Remove the target op.
1520 (class process_target): Add the target op.
1521
1522 Update the derived classes and callers below.
1523
1524 * target.cc (target_wait): Update.
1525 * linux-low.cc (linux_target_ops): Update.
1526 (linux_wait): Turn into ...
1527 (linux_process_target::wait): ... this.
1528 * linux-low.h (class linux_process_target): Update.
1529 * lynx-low.cc (lynx_target_ops): Update.
1530 (lynx_wait): Turn into ...
1531 (lynx_process_target::wait): ... this.
1532 * lynx-low.h (class lynx_process_target): Update.
1533 * nto-low.cc (nto_target_ops): Update.
1534 (nto_wait): Turn into ...
1535 (nto_process_target::wait): ... this.
1536 * nto-low.h (class nto_process_target): Update.
1537 * win32-low.cc (win32_target_ops): Update.
1538 (win32_wait): Turn into ...
1539 (win32_process_target::wait): ... this.
1540 (do_initial_child_stuff): Update.
1541 * win32-low.h (class win32_process_target): Update.
1542
0e4d7e35
TBA
15432020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1544
1545 Turn process_stratum_target's resume op into a method of
1546 process_target.
1547
1548 * target.h (struct process_stratum_target): Remove the target op.
1549 (class process_target): Add the target op.
1550
1551 Update the derived classes and callers below.
1552
1553 * server.cc (resume): Update.
1554 * target.cc (target_stop_and_wait): Update.
1555 (target_continue_no_signal): Update.
1556 (target_continue): Update.
1557 * linux-low.cc (linux_target_ops): Update.
1558 (linux_resume): Turn into ...
1559 (linux_process_target::resume): ... this.
1560 * linux-low.h (class linux_process_target): Update.
1561 * lynx-low.cc (lynx_target_ops): Update.
1562 (lynx_resume): Turn into ...
1563 (lynx_process_target::resume): ... this.
1564 * lynx-low.h (class lynx_process_target): Update.
1565 * nto-low.cc (nto_target_ops): Update.
1566 (nto_resume): Turn into ...
1567 (nto_process_target::resume): ... this.
1568 * nto-low.h (class nto_process_target): Update.
1569 * win32-low.cc (win32_target_ops): Update.
1570 (win32_resume): Turn into ...
1571 (win32_process_target::resume): ... this.
1572 (win32_process_target::detach): Update.
1573 (do_initial_child_stuff): Update.
1574 * win32-low.h (class win32_process_target): Update.
1575
13d3d99b
TBA
15762020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1577
1578 Turn process_stratum_target's thread_alive op into a method of
1579 process_target.
1580
1581 * target.h (struct process_stratum_target): Remove the target op.
1582 (class process_target): Add the target op.
1583 (mythread_alive): Update the macro.
1584
1585 Update the derived classes and callers below.
1586
1587 * linux-low.cc (linux_target_ops): Update.
1588 (linux_thread_alive): Turn into ...
1589 (linux_process_target::thread_alive): ... this.
1590 (wait_for_sigstop): Update.
1591 * linux-low.h (class linux_process_target): Update.
1592 * lynx-low.cc (lynx_target_ops): Update.
1593 (lynx_thread_alive): Turn into ...
1594 (lynx_process_target::thread_alive): ... this.
1595 * lynx-low.h (class lynx_process_target): Update.
1596 * nto-low.cc (nto_target_ops): Update.
1597 (nto_thread_alive): Turn into ...
1598 (nto_process_target::thread_alive): ... this.
1599 * nto-low.h (class nto_process_target): Update.
1600 * win32-low.cc (win32_target_ops): Update.
1601 (win32_thread_alive): Turn into ...
1602 (win32_process_target::thread_alive): ... this.
1603 * win32-low.h (class win32_process_target): Update.
1604
95a49a39
TBA
16052020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1606
1607 Turn process_stratum_target's join op into a method of
1608 process_target.
1609
1610 * target.h (struct process_stratum_target): Remove the target op.
1611 (class process_target): Add the target op.
1612 (join_inferior): Update the macro.
1613
1614 Update the derived classes and callers below.
1615
1616 * linux-low.cc (linux_target_ops): Update.
1617 (linux_join): Turn into ...
1618 (linux_process_target::join): ... this.
1619 * linux-low.h (class linux_process_target): Update.
1620 * lynx-low.cc (lynx_target_ops): Update.
1621 (lynx_join): Turn into ...
1622 (lynx_process_target::join): ... this.
1623 * lynx-low.h (class lynx_process_target): Update.
1624 * nto-low.cc (nto_target_ops): Update.
1625 (nto_process_target::join): Define.
1626 * nto-low.h (class nto_process_target): Update.
1627 * win32-low.cc (win32_target_ops): Update.
1628 (win32_join): Turn into ...
1629 (win32_process_target::join): ... this.
1630 * win32-low.h (class win32_process_target): Update.
1631
8adb37b9
TBA
16322020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1633
1634 Turn process_stratum_target's mourn op into a method of
1635 process_target.
1636
1637 * target.h (struct process_stratum_target): Remove the target op.
1638 (class process_target): Add the target op.
1639
1640 Update the derived classes and callers below.
1641
1642 * target.cc (target_mourn_inferior): Update.
1643 * linux-low.cc (linux_target_ops): Update.
1644 (linux_mourn): Turn into ...
1645 (linux_process_target::mourn): ... this.
1646 (handle_extended_wait): Update.
1647 (linux_process_target::kill): Update.
1648 (linux_process_target::detach): Update.
1649 * linux-low.h (class linux_process_target): Update.
1650 * lynx-low.cc (lynx_target_ops): Update.
1651 (lynx_mourn): Turn into ...
1652 (lynx_process_target::mourn): ... this.
1653 * lynx-low.h (class lynx_process_target): Update.
1654 * nto-low.cc (nto_target_ops): Update.
1655 (nto_mourn): Turn into ...
1656 (nto_process_target::mourn): ... this.
1657 * nto-low.h (class nto_process_target): Update.
1658 * win32-low.cc (win32_target_ops): Update.
1659 (win32_mourn): Turn into ...
1660 (win32_process_target::mourn): ... this.
1661 * win32-low.h (class win32_process_target): Update.
1662
9061c9cf
TBA
16632020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1664
1665 Turn process_stratum_target's detach op into a method of
1666 process_target.
1667
1668 * target.h (struct process_stratum_target): Remove the target op.
1669 (class process_target): Add the target op.
1670 (detach_inferior): Update the macro.
1671
1672 Update the derived classes and callers below.
1673
1674 * linux-low.cc (linux_target_ops): Update.
1675 (linux_detach): Turn into ...
1676 (linux_process_target::detach): ... this.
1677 * linux-low.h (class linux_process_target): Update.
1678 * lynx-low.cc (lynx_target_ops): Update.
1679 (lynx_detach): Turn into ...
1680 (lynx_process_target::detach): ... this.
1681 * lynx-low.h (class lynx_process_target): Update.
1682 * nto-low.cc (nto_target_ops): Update.
1683 (nto_detach): Turn into ...
1684 (nto_process_target::detach): ... this.
1685 * nto-low.h (class nto_process_target): Update.
1686 * win32-low.cc (win32_target_ops): Update.
1687 (win32_detach): Turn into ...
1688 (win32_process_target::detach): ... this.
1689 * win32-low.h (class win32_process_target): Update.
1690
c6885a57
TBA
16912020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1692
1693 Turn process_stratum_target's kill op into a method of
1694 process_target.
1695
1696 * target.h (struct process_stratum_target): Remove the target op.
1697 (class process_target): Add the target op.
1698
1699 Update the derived classes and callers below.
1700
1701 * target.cc (kill_inferior): Update.
1702 * linux-low.cc (linux_target_ops): Update.
1703 (linux_kill): Turn into ...
1704 (linux_process_target::kill): ... this.
1705 * linux-low.h (class linux_process_target): Update.
1706 * lynx-low.cc (lynx_target_ops): Update.
1707 (lynx_kill): Turn into ...
1708 (lynx_process_target::kill): ... this.
1709 * lynx-low.h (class lynx_process_target): Update.
1710 * nto-low.cc (nto_target_ops): Update.
1711 (nto_kill): Turn into ...
1712 (nto_process_target::kill): ... this.
1713 * nto-low.h (class nto_process_target): Update.
1714 * win32-low.cc (win32_target_ops): Update.
1715 (win32_kill): Turn into ...
1716 (win32_process_target::kill): ... this.
1717 * win32-low.h (class win32_process_target): Update.
1718
ef03dad8
TBA
17192020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1720
1721 Turn process_stratum_target's attach op into a method of
1722 process_target.
1723
1724 * target.h (struct process_stratum_target): Remove the target op.
1725 (class process_target): Add the target op.
1726 (myattach): Update the macro.
1727
1728 Update the derived classes and callers below.
1729
1730 * linux-low.cc (linux_target_ops): Update.
1731 (linux_attach): Turn into ...
1732 (linux_process_target::attach): ... this.
1733 * linux-low.h (class linux_process_target): Update.
1734 * lynx-low.cc (lynx_target_ops): Update.
1735 (lynx_attach): Turn into ...
1736 (lynx_process_target::attach): ... this.
1737 * lynx-low.h (class lynx_process_target): Update.
1738 * nto-low.cc (nto_target_ops): Update.
1739 (nto_attach): Turn into ...
1740 (nto_process_target::attach): ... this.
1741 * nto-low.h (class nto_process_target): Update.
1742 * win32-low.cc (win32_target_ops): Update.
1743 (win32_attach): Turn into ...
1744 (win32_process_target::attach): ... this.
1745 * win32-low.h (class win32_process_target): Update.
1746
6dee9afb
TBA
17472020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1748
1749 Turn process_stratum_target's post_create_inferior op into a method
1750 of process_target.
1751
1752 * target.h (struct process_stratum_target): Remove the target op.
1753 (class process_target): Add the target op.
1754 (target_post_create_inferior): Update the macro.
1755 * target.cc (process_target::post_create_inferior): Define.
1756
1757 Update the derived classes and callers below.
1758
1759 * linux-low.cc (linux_target_ops): Update.
1760 (linux_post_create_inferior): Turn into ...
1761 (linux_process_target::post_create_inferior): ... this.
1762 * linux-low.h (class linux_process_target): Update.
1763 * lynx-low.cc (lynx_target_ops): Update.
1764 * nto-low.cc (nto_target_ops): Update.
1765 * win32-low.cc (win32_target_ops): Update.
1766
15295543
TBA
17672020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1768
1769 Turn process_stratum_target's create_inferior op into a method of
1770 process_target.
1771
1772 * target.h (struct process_stratum_target): Remove the target op.
1773 (class process_target): Add the target op.
1774 (create_inferior): Rename the macro to ...
1775 (target_create_inferior): ... this.
1776
1777 Update the derived classes and callers below.
1778
1779 * server.cc (handle_v_run): Update.
1780 (captured_main): Update.
1781 (process_serial_event): Update.
1782 * linux-low.cc (linux_target_ops): Update.
1783 (linux_create_inferior): Turn into ...
1784 (linux_process_target::create_inferior): ... this.
1785 * linux-low.h (class linux_process_target): Update.
1786 * lynx-low.cc (lynx_target_ops): Update.
1787 (lynx_create_inferior): Turn into ...
1788 (lynx_process_target::create_inferior): ... this.
1789 * lynx-low.h (class lynx_process_target): Update.
1790 * nto-low.cc (nto_target_ops): Update.
1791 (nto_create_inferior): Turn into ...
1792 (nto_process_target::create_inferior): ... this.
1793 * nto-low.h (class nto_process_target): Update.
1794 * win32-low.cc (win32_target_ops): Update.
1795 (win32_create_inferior): Turn into ...
1796 (win32_process_target::create_inferior): ... this.
1797 * win32-low.h (class win32_process_target): Update.
1798
5ef9273d
TBA
17992020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1800
1801 * target.h (class process_target): New class definition.
1802 (struct process_stratum_target) <pt>: New field with type
1803 'process_target*'.
1804 * linux-low.h (class linux_process_target): Define as a derived
1805 class of 'process_target'.
1806 * linux-low.cc (linux_target_ops): Add a linux_process_target*
1807 as the 'pt' field.
1808 * lynx-low.h (class lynx_process_target): Define as a derived
1809 class of 'process_target'.
1810 * lynx-low.cc (lynx_target_ops): Add a lynx_process_target*
1811 as the 'pt' field.
1812 * nto-low.h (class nto_process_target): Define as a derived
1813 class of 'process_target'.
1814 * nto-low.cc (nto_target_ops): Add an nto_process_target*
1815 as the 'pt' field.
1816 * win32-low.h (class win32_process_target): Define as a derived
1817 class of 'process_target'.
1818 * win32-low.cc (win32_target_ops): Add a win32_process_target*
1819 as the 'pt' field.
1820
9f1528a1
AB
18212020-02-19 Andrew Burgess <andrew.burgess@embecosm.com>
1822
1823 * configure: Regenerate.
1824
bf84f706
MR
18252020-02-19 Maciej W. Rozycki <macro@wdc.com>
1826 Andrew Burgess <andrew.burgess@embecosm.com>
1827
1828 * linux-riscv-low.cc: New file.
1829 * Makefile.in (SFILES): Add linux-riscv-low.cc, arch/riscv.c,
1830 and nat/riscv-linux-tdesc.c.
1831 * configure.srv <riscv*-*-linux*> (srv_tgtobj)
1832 (srv_linux_regsets, srv_linux_usrregs, srv_linux_thread_db):
1833 Define.
1834
1a627e7e
TT
18352020-02-14 Tom Tromey <tom@tromey.com>
1836
1837 * acinclude.m4: Don't include acx_configure_dir.m4.
1838 * Makefile.in (LIBIBERTY_BUILDDIR, GNULIB_BUILDDIR): Update.
1839 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): Remove.
1840 (all, install-only, uninstall, clean-info, clean)
1841 (maintainer-clean): Don't recurse.
1842 (subdir_do, all-lib): Remove.
1843 ($(LIBGNU) $(LIBIBERTY) $(GNULIB_H)): Remove rule.
1844 (GNULIB_H): Remove.
1845 (generated_files): Update.
1846 ($(GNULIB_BUILDDIR)/Makefile): Remove rule.
1847 * configure: Rebuild.
1848 * configure.ac: Don't configure gnulib or libiberty.
1849 (GNULIB): Update.
1850
a9b34532
EZ
18512020-02-14 Eli Zaretskii <eliz@gnu.org>
1852
1853 * win32-low.c (create_process): Prepend PROGRAM to ARGS when
1854 preparing the command line for CreateProcess.
1855 (win32_create_inferior): Reflect the program name in debugging
1856 output that shows the process and its command line.
1857
feacfcac
SM
18582020-02-13 Simon Marchi <simon.marchi@efficios.com>
1859
1860 * Makefile.in: Rename source files from .c to .cc.
1861 * %.c: Rename to %.cc.
1862 * configure.ac: Rename server.c to server.cc.
1863 * configure: Re-generate.
1864
06b3c5bd
SM
18652020-02-13 Simon Marchi <simon.marchi@efficios.com>
1866
1867 * Makefile.in: Rename gdbsupport source files from .c to .cc.
1868
052793ad
HD
18692020-02-12 Hannes Domani <ssbssa@yahoo.de>
1870
1871 * win32-low.c (win32_create_inferior): Set signal_pid.
1872
f20e3e82
MR
18732020-02-12 Maciej W. Rozycki <macro@wdc.com>
1874 Pedro Alves <palves@redhat.com>
1875
1876 Skip building gdbserver in a cross-configuration.
1877 * configure.srv: Set $gdbserver_host depending on whether $target
1878 is $host. Use $gdbserver_host instead of $host.
1879
8ddd8e0e
SM
18802020-02-11 Simon Marchi <simon.marchi@efficios.com>
1881
1882 * configure: Re-generate.
1883
898e7f60
SM
18842020-02-11 Simon Marchi <simon.marchi@efficios.com>
1885
1886 * configure: Re-generate.
1887
58df732b
SM
18882020-02-11 Simon Marchi <simon.marchi@efficios.com>
1889
1890 * acinclude.m4: Update warning.m4 path.
1891
7928d571
HD
18922020-02-09 Hannes Domani <ssbssa@yahoo.de>
1893
1894 * win32-low.c (win32_clear_inferiors): Reset siginfo_er.
1895 (handle_exception): Set siginfo_er.
1896 (win32_xfer_siginfo): New function.
1897
919adfe8
TT
18982020-02-07 Tom Tromey <tom@tromey.com>
1899 Pedro Alves <palves@redhat.com>
1900
1901 * README: Update build documentation.
1902 * configure.srv: Set UNSUPPORTED if host is unsupported. Check
1903 host, not target.
1904 * configure.ac: Update paths.
1905 * configure: Rebuild.
1906 * acinclude.m4: Update paths.
1907 * Makefile.in: Update include paths.
1908 (depcomp, INCLUDE_DIR, INCGNU, INCSUPPORT, INCLUDE_CFLAGS)
1909 (SFILES, XML_DIR, n, $(GNULIB_BUILDDIR)/Makefile, config.status)
1910 (version-generated.c, stamp-xml, regdat_sh, arch/%-ipa.o)
1911 (gdbsupport/%-ipa.o, %-ipa.o, arch/%.o, gdbsupport/%.o, %.o)
1912 (%-generated.c): Update paths.
1913 * Move entire directory from ../gdb/gdbserver.
1914
287c844a
MR
19152020-01-29 Maciej W. Rozycki <macro@wdc.com>
1916
1917 * configure.srv <i[34567]86-*-mingw*>: Fix whitespace damage.
1918
548a204f
PFC
19192020-01-29 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1920
1921 * configure.srv (powerpc*-*-linux*): Use srv_tgtobj in second
1922 assignment instead of srv_linux_obj.
1923
a2236a08
HD
19242020-01-28 Hannes Domani <ssbssa@yahoo.de>
1925
1926 * server.c (handle_qxfer_libraries): Write segment-address with
1927 paddress.
1928
bdaed379
HD
19292020-01-24 Hannes Domani <ssbssa@yahoo.de>
1930
1931 * Makefile.in (install-strip): New target.
1932 (install_sh, INSTALL_STRIP_PROGRAM, STRIP): New variables.
1933 * aclocal.m4: Regenerate.
1934 * configure: Regenerate.
1935 * configure.ac: Add AM_PROG_INSTALL_STRIP.
1936
42cd72aa
MR
19372020-01-24 Maciej W. Rozycki <macro@wdc.com>
1938
1939 * Makefile.in (SFILES): Adjust paths to point to real files.
1940 (OBS): Move waitstatus.o to target/waitstatus.o.
1941 (TAGS): Transform paths appropriately.
1942 (%.o): Rename to...
1943 (nat/%.o): ... this pattern rule.
1944 (%.o): Rename to...
1945 (target/%.o): ... this pattern rule.
1946 * configure.srv: Adjust paths throughout to include nat/ prefix
1947 with the revant files.
1948 * configure.ac: Add `nat' and `target' to CONFIG_SRC_SUBDIR.
1949 * configure: Regenerate.
1950
42ba50ec
MR
19512020-01-24 Maciej W. Rozycki <macro@wdc.com>
1952
1953 * Makefile.in (TAGS): Remove config files from the recipe.
1954
05ea2a05
TT
19552020-01-14 Tom Tromey <tom@tromey.com>
1956
1957 * configure: Rebuild.
1958 * configure.ac: Remove any checks that were added to common.m4.
1959 * acinclude.m4: Include lib-ld.m4, lib-prefix.m4, and
1960 lib-link.m4.
1961
01027315
TT
19622020-01-14 Tom Tromey <tom@tromey.com>
1963
1964 * server.h: Include config.h.
1965 * gdbreplay.c: Include config.h.
1966 * configure: Rebuild.
1967 * configure.ac: Don't source common.host.
1968 * acinclude.m4: Update path.
1969 * Makefile.in (INCSUPPORT): New variable.
1970 (INCLUDE_CFLAGS): Add INCSUPPORT.
1971 (SFILES): Update paths.
1972 (version-generated.c): Update path to create-version.sh.
1973 (gdbsupport/%-ipa.o, gdbsupport/%.o): Update paths.
1974
b2ceabe8
TT
19752020-01-14 Tom Tromey <tom@tromey.com>
1976
1977 * configure.ac (LIBS): Use WIN32APILIBS.
1978 (USE_WIN32API): Don't define.
1979 * configure: Rebuild.
1980
25c51f71
TT
19812020-01-14 Tom Tromey <tom@tromey.com>
1982
1983 * configure: Rebuild.
1984
c0bd321d
SM
19852020-01-13 Simon Marchi <simon.marchi@efficios.com>
1986
1987 * Makefile.in (%-generated.c): Remove rule for files from
1988 regformats/i386.
1989
bb564c58
SM
19902020-01-13 Simon Marchi <simon.marchi@efficios.com>
1991
1992 * configure: Re-generate.
1993
6e37c371
SM
19942020-01-13 Simon Marchi <simon.marchi@efficios.com>
1995
1996 * tracepoint.h (IP_AGENT_EXPORT_FUNC) [!IN_PROCESS_AGENT]:
1997 Define to static.
1998 * tracepoint.c (stop_tracing, flush_trace_buffer,
1999 about_to_request_buffer_space, get_trace_state_variable_value,
2000 set_trace_state_variable_value, gdb_collect): Add declaration.
2001
df4a0200
SM
20022020-01-13 Simon Marchi <simon.marchi@efficios.com>
2003
2004 * linux-x86-low.c (x86_linux_regs_info, amd64_emit_eq_goto,
2005 amd64_emit_ne_goto, amd64_emit_lt_goto, amd64_emit_le_goto,
2006 amd64_emit_gt_goto, amd64_emit_ge_goto, amd64_emit_ge_goto,
2007 i386_emit_eq_goto, i386_emit_ne_goto, i386_emit_lt_goto,
2008 i386_emit_le_goto, i386_emit_gt_goto, i386_emit_ge_goto): Make
2009 static.
2010
89e94ec9
SM
20112020-01-13 Simon Marchi <simon.marchi@efficios.com>
2012
2013 * inferiors.c: Include gdbsupport/common-inferior.h.
2014
2552728a
SM
20152020-01-13 Simon Marchi <simon.marchi@efficios.com>
2016
2017 * hostio-errno.c: Include hostio.h.
2018
4025fa09
SM
20192020-01-13 Simon Marchi <simon.marchi@efficios.com>
2020
2021 * Makefile.in (%-generated.c): Make $(regdat_sh) a regular
2022 prerequisite.
2023
c0b0a142
SM
20242020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
2025
2026 * linux-arm-tdesc.c: Include linux-arm-tdesc.h.
2027 * linux-arm-tdesc.h: Include arch/arm.h.
2028
bb1183e2
SM
20292020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
2030
2031 * linux-aarch64-low.c (aarch64_write_goto_address): Make static.
2032
f5df0b5f
SM
20332020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
2034
2035 * linux-aarch32-tdesc.c: Include linux-aarch32-tdesc.h.
2036 * linux-aarch64-tdesc.c: Include linux-aarch64-tdesc.h.
2037
5b6d1e4f
PA
20382020-01-10 Pedro Alves <palves@redhat.com>
2039
2040 * fork-child.c (post_fork_inferior): Pass target down to
2041 startup_inferior.
2042 * inferiors.c (switch_to_thread): Add process_stratum_target
2043 parameter.
2044 * lynx-low.c (lynx_target_ops): Now a process_stratum_target.
2045 * nto-low.c (nto_target_ops): Now a process_stratum_target.
2046 * linux-low.c (linux_target_ops): Now a process_stratum_target.
2047 * remote-utils.c (prepare_resume_reply): Pass the target to
2048 switch_to_thread.
2049 * target.c (the_target): Now a process_stratum_target.
2050 (done_accessing_memory): Pass the target to switch_to_thread.
2051 (set_target_ops): Ajust to use process_stratum_target.
2052 * target.h (struct target_ops): Rename to ...
2053 (struct process_stratum_target): ... this.
2054 (the_target, set_target_ops): Adjust.
2055 (prepare_to_access_memory): Adjust comment.
2056 * win32-low.c (child_xfer_memory): Adjust to use
2057 process_stratum_target.
2058 (win32_target_ops): Now a process_stratum_target.
2059
559e7e50
EZ
20602020-01-06 Eli Zaretskii <eliz@gnu.org>
2061 Pedro Alves <palves@redhat.com>
2062
2063 * win32-low.c (get_child_debug_event): Extract the fatal exception
2064 from the exit status and convert to the equivalent Posix signal
2065 number.
2066 (win32_wait): Allow TARGET_WAITKIND_SIGNALLED status as well.
2067 * Makefile.in (OBS, SFILES): Add gdb_wait.[co].
2068
48189bec
HD
20692020-01-01 Hannes Domani <ssbssa@yahoo.de>
2070
2071 * Makefile.in: Use INSTALL_PROGRAM_ENV.
2072
5dd8bf88
JB
20732020-01-01 Joel Brobecker <brobecker@adacore.com>
2074
2075 * server.c (gdbserver_version): Change copyright year to 2020.
2076 * gdbreplay.c (gdbreplay_version): Likewise.
2077
0ad6b8ee
CB
20782019-12-19 Christian Biesinger <cbiesinger@google.com>
2079
2080 * configure: Regenerate.
2081 * configure.ac: Quote variable arguments of test.
2082
1ee7b812
BE
20832019-12-16 Bernd Edlinger <bernd.edlinger@hotmail.de>
2084
2085 * Makefile.in: Fix build with GNU Make 3.81
2086
d9fa87f4
TT
20872019-12-16 Tom Tromey <tromey@adacore.com>
2088
2089 * server.c (get_exec_file): Constify result.
2090
ab7d13f0
CB
20912019-12-10 Christian Biesinger <cbiesinger@google.com>
2092
2093 * Makefile.in: Add safe-strerror.c to gdbreplay and IPA, and change
2094 UNDO_GNULIB_CFLAGS to undo strerror_r instead of strerror.
2095 * config.in: Regenerate.
2096 * configure: Regenerate.
2097 * configure.ac: Don't check for strerror.
2098 * linux-i386-ipa.c (initialize_fast_tracepoint_trampoline_buffer):
2099 Call safe_strerror instead of strerror.
2100 * server.h (strerror): Remove this now-unnecessary declaration.
2101 * tracepoint.c (init_named_socket): Call safe_strerror instead of
2102 strerror.
2103 (gdb_agent_helper_thread): Likewise.
2104 * utils.c (perror_with_name): Likewise.
2105
4da8c3a8
TT
21062019-11-26 Tom Tromey <tom@tromey.com>
2107
2108 * configure, config.in: Rebuild.
2109
21987b9c
TT
21102019-11-26 Tom Tromey <tom@tromey.com>
2111
2112 * remote-utils.c (block_unblock_async_io): Use gdb_sigmask.
2113 * linux-low.c (linux_wait_for_event_filtered, linux_async): Use
2114 gdb_sigmask.
2115 * configure, config.in: Rebuild.
2116
5e030278
TT
21172019-11-26 Tom Tromey <tom@tromey.com>
2118
2119 * Makefile.in (PTHREAD_CFLAGS, PTHREAD_LIBS): New variables.
2120 (INTERNAL_CFLAGS_BASE): Use PTHREAD_CFLAGS.
2121 (GDBSERVER_LIBS): Use PTHREAD_LIBS.
2122 * acinclude.m4: Include ax_pthread.m4.
2123 * config.in, configure: Rebuild.
2124
6d91ce9a
CB
21252019-11-26 Christian Biesinger <cbiesinger@google.com>
2126
2127 * debug.c (debug_set_output): Call safe_strerror instead of
2128 strerror.
2129 * linux-low.c (attach_proc_task_lwp_callback): Likewise.
2130 (linux_kill_one_lwp): Likewise.
2131 (linux_detach_one_lwp): Likewise.
2132 (linux_wait_for_event_filtered): Likewise.
2133 (store_register): Likewise.
2134 * lynx-low.c (lynx_attach): Likewise.
2135 * mem-break.c (insert_memory_breakpoint): Likewise.
2136 (remove_memory_breakpoint): Likewise.
2137 (delete_fast_tracepoint_jump): Likewise.
2138 (set_fast_tracepoint_jump): Likewise.
2139 (uninsert_fast_tracepoint_jumps_at): Likewise.
2140 (reinsert_fast_tracepoint_jumps_at): Likewise.
2141 * nto-low.c (nto_xfer_memory): Likewise.
2142 (nto_resume): Likewise.
2143
6cdd651f
LM
21442019-11-20 Luis Machado <luis.machado@linaro.org>
2145
2146 * linux-aarch64-low.c (is_sve_tdesc): Check against target feature
2147 instead of register count.
2148 * tdesc.c (tdesc_contains_feature): New function.
2149 * tdesc.h (tdesc_contains_feature): New prototype.
2150
cd850b40
CB
21512019-11-15 Christian Biesinger <cbiesinger@google.com>
2152
2153 * Makefile.in: Add safe-strerror.c.
2154 * configure: Regenerate.
2155 * configure.ac: Don't source common.host.
2156
5abebf3c
CB
21572019-11-15 Christian Biesinger <cbiesinger@google.com>
2158
2159 * config.in: Regenerate.
2160 * configure: Regenerate.
2161
e06f3d6e
AB
21622019-11-12 Andrew Burgess <andrew.burgess@embecosm.com>
2163
2164 * ax.c (ax_printf): Handle size_t_arg.
2165
ca3a04f6
CB
21662019-11-06 Christian Biesinger <cbiesinger@google.com>
2167
2168 * linux-tdep.c (linux_info_proc): Use strtok_r instead of strtok.
2169 * mi/mi-main.c (output_cores): Likewise.
2170 * nat/linux-osdata.c (linux_xfer_osdata_cpus): Likewise.
2171 (linux_xfer_osdata_modules): Likewise.
2172 * remote.c (register_remote_support_xml): Likewise.
2173 * sparc64-tdep.c (adi_is_addr_mapped): Likewise.
2174 * xml-syscall.c (syscall_create_syscall_desc): Likewise.
2175
e48f6033
CB
21762019-11-01 Christian Biesinger <cbiesinger@google.com>
2177
2178 * configure: Regenerate.
2179 * configure.ac: Remove check for strerror_r.
2180
e7e97a2e
CB
21812019-10-31 Christian Biesinger <cbiesinger@google.com>
2182
2183 * config.in: Regenerate.
2184 * configure: Regenerate.
2185 * configure.ac: Also check for strerror_r.
2186
75cafaa6
CB
21872019-10-31 Christian Biesinger <cbiesinger@google.com>
2188
2189 * ax.h (debug_agent): Remove duplicate declaration.
2190
30baf67b
TV
21912019-10-26 Tom de Vries <tdevries@suse.de>
2192
2193 * linux-aarch64-low.c: Fix typos in comments.
2194 * linux-arm-low.c: Same.
2195 * linux-low.c: Same.
2196 * linux-ppc-low.c: Same.
2197 * proc-service.c: Same.
2198 * regcache.h: Same.
2199 * server.c: Same.
2200 * tracepoint.c: Same.
2201 * win32-low.c: Same.
2202
52c64cf7
TT
22032019-10-25 Tom Tromey <tromey@adacore.com>
2204
2205 * utils.c (xstrdup): Remove.
2206
c12d372d
TT
22072019-10-23 Tom Tromey <tom@tromey.com>
2208
2209 * configure, config.in: Rebuild.
2210
4d0b984b
TT
22112019-10-23 Tom Tromey <tom@tromey.com>
2212
2213 * configure: Rebuild.
2214 * acinclude.m4: Use m4_include, not sinclude.
2215
c5adaa19
TT
22162019-10-17 Tom Tromey <tromey@adacore.com>
2217
2218 * configure: Rebuild.
2219 * configure.ac: Use AC_CONFIG_HEADERS. Create stamp-h there, not
2220 in AC_CONFIG_FILES invocation.
2221 * Makefile.in (stamp-h, Makefile): Use new-style config.status
2222 invocation.
2223
fec4e896
CB
22242019-10-16 Christian Biesinger <cbiesinger@google.com>
2225
2226 * server.c: Include xml-builtin.h.
2227 (get_xml_features): Don't declare xml_builtins here.
2228
00975ff6
AB
22292019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
2230
2231 * Makefile.in: Remove references to vec-ipa.o.
2232
0dc32745
AB
22332019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
2234
2235 * Makefile.in: Remove references to vec.c.
2236
3e6ec53a
CB
22372019-10-02 Christian Biesinger <cbiesinger@google.com>
2238
2239 * server.c (server_waiting): Change to bool.
2240 (extended_protocol): Likewise.
2241 (response_needed): Likewise.
2242 (exit_requested): Likewise.
2243 (run_once): Likewise.
2244 (report_no_resumed): Likewise.
2245 (non_stop): Likewise.
2246 (disable_packet_vCont): Likewise.
2247 (disable_packet_Tthread): Likewise.
2248 (disable_packet_qC): Likewise.
2249 (disable_packet_qfThreadInfo): Likewise.
2250 (handle_general_set): Update.
2251 (handle_detach): Update.
2252 (handle_monitor_command): Update.
2253 (handle_query): Update.
2254 (captured_main): Update.
2255 (process_serial_event): Update.
2256 * server.h (server_waiting): Change to bool.
2257 (disable_packet_vCont): Likewise.
2258 (disable_packet_Tthread): Likewise.
2259 (disable_packet_qC): Likewise.
2260 (disable_packet_qfThreadInfo): Likewise.
2261 (run_once): Likewise.
2262 (non_stop): Likewise.
2263 * target.c (target_stop_and_wait): Update.
2264
80fd2826
TT
22652019-10-02 Tom Tromey <tromey@adacore.com>
2266
2267 * Makefile.in (SFILES): Add common-inferior.c.
2268 (OBS): Add common-inferior.o.
2269 * server.c (startup_with_shell): Don't define.
2270
46f29a9a
AB
22712019-10-02 Andrew Burgess <andrew.burgess@embecosm.com>
2272
2273 * linux-low.c (linux_low_read_btrace): Update for change to
2274 std::vector.
2275
f9d949fb
CB
22762019-09-20 Christian Biesinger <cbiesinger@google.com>
2277
2278 * debug.c (debug_threads): Remove comment in favor of the header.
2279 * debug.h (using_threads): Add declaration.
2280 (debug_threads): Add comment.
2281 * linux-aarch64-low.c: Include debug.h and remove declaration of
2282 debug_threads.
2283 * nto-low.c: Likewise.
2284 * remote-utils.c: Likewise.
2285 * thread-db.c: Likewise.
2286
abf516c6
UW
22872019-09-20 Ulrich Weigand <uweigand@de.ibm.com>
2288
2289 * configure.srv (ipa_ppc_linux_regobj): Remove powerpc-cell32l-ipa.o
2290 and powerpc-cell64l-ipa.o.
2291 (powerpc*-*-linux*): Remove powerpc-cell32l.o and powerpc-cell64l.o
2292 from srv_regobj. Remove rs6000/powerpc-cell32l.xml and
2293 rs6000/powerpc-cell64l.xml from srv_xmlfiles.
2294 (spu*-*-*): Remove.
2295
2296 * spu-low.c: Remove file.
2297
2298 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Remove.
2299 (parse_spufs_run): Remove.
2300 (ppc_get_pc): Remove Cell/B.E. support.
2301 (ppc_set_pc): Likewise.
2302 (ppc_breakpoint_at): Likewise.
2303 (ppc_arch_setup): Likewise.
2304 (ppc_get_ipa_tdesc_idx): Do not handle tdesc_powerpc_cell64l or
2305 tdesc_powerpc_cell32l.
2306 (initialize_low_arch): Do not call init_registers_powerpc_cell64l
2307 or init_registers_powerpc_cell32l.
2308 * linux-ppc-ipa.c (get_ipa_tdesc): Do not handle PPC_TDESC_CELL.
2309 (initialize_low_tracepoint): Do not call init_registers_powerpc_cell64l
2310 or init_registers_powerpc_cell32l.
2311 * linux-ppc-tdesc-init.h (PPC_TDESC_CELL): Mark as unused.
2312 (init_registers_powerpc_cell32l): Remove prototype.
2313 (init_registers_powerpc_cell64l): Likewise.
2314
2315 * target.h (struct target_ops): Remove qxfer_spu member.
2316 * server.c (handle_qxfer_spu): Remove.
2317 (qxfer_packets): Remove entry for "spu".
2318 (handle_query): No longer support qXfer:spu:read or qXfer:spu:write.
2319 * linux-low.c (SPUFS_MAGIC): Remove.
2320 (spu_enumerate_spu_ids): Remove.
2321 (linux_qxfer_spu): Remove.
2322 (linux_target_ops): Remove qxfer_spu member.
2323 * lynx-low.c (lynx_target_ops): Remove qxfer_spu member.
2324 * nto-low.c (nto_target_ops): Remove qxfer_spu member.
2325 * win32-low.c (win32_target_ops): Remove qxfer_spu member.
2326
2d41fa11
SDJ
23272019-08-23 Sergio Durigan Junior <sergiodj@redhat.com>
2328
2329 * Makefile.in (SFILES): Add 'gdbsupport/gdb-dlfcn.c'.
2330 (OBS): Add 'gdbsupport/gdb-dlfcn.o'.
2331 * config.in: Regenerate.
2332 * configure: Regenerate.
2333
d59b55f0
TT
23342019-08-15 Tom Tromey <tromey@adacore.com>
2335
2336 * target.c (target_write_memory): Use gdb::byte_vector.
2337
4196ab2a
TT
23382019-08-15 Tom Tromey <tromey@adacore.com>
2339
2340 * tracepoint.c (write_inferior_data_pointer)
2341 (write_inferior_integer, write_inferior_int8)
2342 (write_inferior_uinteger, m_tracepoint_action_download)
2343 (r_tracepoint_action_download, x_tracepoint_action_download)
2344 (l_tracepoint_action_download, clear_inferior_trace_buffer)
2345 (download_agent_expr, download_tracepoint_1)
2346 (download_trace_state_variables, upload_fast_traceframes): Update.
2347 * server.c (gdb_write_memory): Update.
2348 * remote-utils.c (relocate_instruction): Update.
2349 * proc-service.c (ps_pdwrite): Update.
2350 * mem-break.c (remove_memory_breakpoint)
2351 (delete_fast_tracepoint_jump, set_fast_tracepoint_jump)
2352 (uninsert_fast_tracepoint_jumps_at)
2353 (reinsert_fast_tracepoint_jumps_at): Update.
2354 * linux-x86-low.c (append_insns)
2355 (i386_install_fast_tracepoint_jump_pad)
2356 (amd64_write_goto_address, i386_write_goto_address): Update.
2357 * linux-s390-low.c (append_insns, s390_write_goto_address):
2358 Update.
2359 * linux-ppc-low.c (ppc_relocate_instruction)
2360 (ppc_install_fast_tracepoint_jump_pad, emit_insns)
2361 (ppc_write_goto_address): Update.
2362 * linux-aarch64-low.c (append_insns): Update.
2363 * target.h (struct target_ops): Update.
2364 (write_inferior_memory): Don't declare.
2365 * target.c (target_write_memory): Rename from
2366 write_inferior_memory. Remove old target_write_memory.
2367
c6778d00
TT
23682019-08-15 Tom Tromey <tromey@adacore.com>
2369
2370 * target.c (write_inferior_memory): Use std::vector.
2371
404f2902
FCE
23722019-08-06 Frank Ch. Eigler <fche@redhat.com>
2373
2374 PR build/24886
2375 * configure.ac: Drop enable-libmcheck support.
2376 * configure, config.in: Rebuild.
2377 * acinclude.m4: Don't include it.
2378
4c5aa8e0
AH
23792019-07-19 Alan Hayward <alan.hayward@arm.com>
2380
2381 * configure.srv: Remove Arm xml files.
2382
7cc17433
AH
23832019-07-19 Alan Hayward <alan.hayward@arm.com>
2384
2385 * configure.srv: Add new files. Remove xml generated files.
2386 * linux-aarch32-low.c (initialize_low_arch_aarch32): Don't init
2387 registers.
2388 * linux-aarch32-low.h (tdesc_arm_with_neon): Remove.
2389 * linux-aarch32-tdesc.c: New file.
2390 * linux-aarch32-tdesc.h: New file.
2391 * linux-aarch64-low.c (aarch64_arch_setup): Call aarch32_linux_read_description.
2392 * linux-arm-low.c (init_registers_arm, tdesc_arm)
2393 (init_registers_arm_with_iwmmxt, tdesc_arm_with_iwmmxt)
2394 (init_registers_arm_with_vfpv2, tdesc_arm_with_vfpv2)
2395 (init_registers_arm_with_vfpv3, tdesc_arm_with_vfpv3): Remove.
2396 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
2397 (arm_store_vfpregset): Call arm_linux_get_tdesc_fp_type.
2398 (arm_read_description): Call arm_linux_read_description.
2399 (initialize_low_arch): Don't init registers.
2400 * linux-arm-tdesc.c: New file.
2401 * linux-arm-tdesc.h: New file.
2402
166a82be
AH
24032019-07-10 Alan Hayward <alan.hayward@arm.com>
2404
2405 * linux-arm-low.c (arm_fill_wmmxregset, arm_store_wmmxregset):
2406 Move counter inside for.
2407 (arm_read_description): Check ptrace earlier.
2408 (arm_arch_setup): Call arm_linux_init_hwbp_cap here.
2409
268a13a5
TT
24102019-07-09 Tom Tromey <tom@tromey.com>
2411
2412 * configure: Rebuild.
2413 * configure.ac: Change common to gdbsupport.
2414 * acinclude.m4: Change common to gdbsupport.
2415 * Makefile.in (SFILES, OBS, GDBREPLAY_OBS, IPA_OBJS)
2416 (version-generated.c, gdbsupport/%-ipa.o, gdbsupport/%.o): Change
2417 common to gdbsupport.
2418 * ax.c, event-loop.c, fork-child.c, gdb_proc_service.h,
2419 gdbreplay.c, gdbthread.h, hostio-errno.c, hostio.c, i387-fp.c,
2420 inferiors.c, inferiors.h, linux-aarch64-tdesc-selftest.c,
2421 linux-amd64-ipa.c, linux-i386-ipa.c, linux-low.c,
2422 linux-tic6x-low.c, linux-x86-low.c, linux-x86-tdesc-selftest.c,
2423 linux-x86-tdesc.c, lynx-i386-low.c, lynx-low.c, mem-break.h,
2424 nto-x86-low.c, regcache.c, regcache.h, remote-utils.c, server.c,
2425 server.h, spu-low.c, symbol.c, target.h, tdesc.c, tdesc.h,
2426 thread-db.c, tracepoint.c, win32-i386-low.c, win32-low.c: Change
2427 common to gdbsupport.
2428
350fab54
AH
24292019-07-04 Alan Hayward <alan.hayward@arm.com>
2430
2431 * linux-aarch32-low.c (arm_read_description, arm_regsets): Use new
2432 defines.
2433 * linux-arm-low.c (arm_read_description, arm_regsets): Likewise.
2434
2b40fda7
AH
24352019-07-04 Alan Hayward <alan.hayward@arm.com>
2436
2437 * configure.srv: Remove legacy xml.
2438 * linux-aarch64-low.c (initialize_low_arch): Remove
2439 initialize_low_tdesc call.
2440 * linux-aarch64-tdesc-selftest.c: Remove file.
2441 * linux-aarch64-tdesc.h (initialize_low_tdesc): Remove.
2442 * linux-x86-low.c (initialize_low_arch): Remove
2443 initialize_low_tdesc call.
2444 * linux-x86-tdesc-selftest.c: Remove file.
2445 * linux-x86-tdesc.h (initialize_low_tdesc): Remove.
2446
7d10623d
TV
24472019-06-20 Tom de Vries <tdevries@suse.de>
2448
2449 * linux-s390-ipa.c (get_ipa_tdesc)[!__s390x__]: Use
2450 s390_te_linux64_ft_collect_regmap for S390_TDESC_GS.
2451
8d6a48df
TV
24522019-06-19 Tom de Vries <tdevries@suse.de>
2453
2454 * debug.h (debug_write): Change return type to ssize_t.
2455 * debug.c (debug_write): Same.
2456
73cc7272
TT
24572019-06-14 Tom Tromey <tom@tromey.com>
2458
2459 * configure.ac: Use new path to gnulib.
2460 * configure: Rebuild.
2461 * Makefile.in (INCGNU, $(GNULIB_BUILDDIR)/Makefile): Use new path
2462 to gnulib.
2463
08f10e02
TT
24642019-06-11 Tom Tromey <tom@tromey.com>
2465
2466 * Makefile.in (SFILES): Add alloc.c.
2467 (OBS): Add alloc.o.
2468 (IPA_OBJS): Add alloc-ipa.o.
2469 (alloc-ipa.o): New target.
2470 (%.o: ../%.c): New pattern rule.
2471
422186a9
TT
24722019-06-10 Tom Tromey <tromey@adacore.com>
2473
2474 * remote-utils.c (look_up_one_symbol, relocate_instruction): Don't
2475 end warning with a newline.
2476 * linux-s390-low.c (s390_get_wordsize): Don't end warning with a
2477 newline.
2478 * thread-db.c (attach_thread): Don't end warning with a newline.
2479 (thread_db_notice_clone): Likewise.
2480 * tracepoint.c (gdb_agent_helper_thread): Don't end warning with a
2481 newline.
2482 * linux-x86-low.c (x86_get_min_fast_tracepoint_insn_len): Don't
2483 end warning with a newline.
2484
b02f78f9
PA
24852019-06-04 Pedro Alves <palves@redhat.com>
2486
2487 * server.c (captured_main): Use make_unique_xstrdup.
2488
88ed7edb
TT
24892019-06-02 Tom Tromey <tom@tromey.com>
2490
2491 * gdbreplay.c (fromhex): Remove.
2492 * Makefile.in (GDBREPLAY_OBS): Add rsp-low.o.
2493
33a6bc35
TT
24942019-05-29 Tom Tromey <tromey@adacore.com>
2495
2496 * configure: Rebuild.
2497
e90a813d
KB
24982019-05-06 Kevin Buettner <kevinb@redhat.com>
2499
2500 * linux-x86-low.c (x86_fill_gregset): Don't compile 64-bit
2501 sign extension code on 32-bit builds.
2502
353ea2d1
EZ
25032019-05-03 Eli Zaretskii <eliz@gnu.org>
2504
2505 * remote-utils.c:
2506 * gdbreplay.c [USE_WIN32API]: Remove the _WIN32_WINNT override.
2507
b494cdff
TT
25082019-04-19 Tom Tromey <tom@tromey.com>
2509
2510 * server.c (struct vstop_notif): Derive from notif_event.
2511 <base>: Remove.
2512 (queue_stop_reply): Update.
2513 (remove_all_on_match_ptid): Change type. Rewrite.
2514 (discard_queued_stop_replies): Rewrite.
2515 (in_queued_stop_replies_ptid): Change type.
2516 (in_queued_stop_replies): Rewrite.
2517 (notif_stop): Update.
2518 (queue_stop_reply_callback): Update.
2519 (captured_main): Don't call initialize_notif.
2520 (push_stop_notification): Update.
2521 * notif.c (notif_write_event, handle_notif_ack)
2522 (notif_event_enque, notif_push): Update.
2523 (notif_event_xfree, initialize_notif): Remove.
2524 * notif.h (struct notif_event): Include <list>, not
2525 "common/queue.h".
2526 (struct notif_server) <queue>: Now a std::list.
2527 (notif_event_p): Remove typedef.
2528 (initialize_notif): Don't declare.
2529 (struct notif_event): Add virtual destructor.
2530
a7e559cc
AH
25312019-04-17 Alan Hayward <alan.hayward@arm.com>
2532
2533 * ax.c (ax_vdebug): Call debug_printf.
2534 * debug.c (debug_write): New function.
2535 * debug.h (debug_write): New declaration.
2536 * linux-low.c (sigchld_handler): Call debug_write.
2537
aeb2e706
AH
25382019-04-17 Alan Hayward <alan.hayward@arm.com>
2539
2540 * debug.c (debug_set_output): New function.
2541 (debug_vprintf): Send output to debug_file.
2542 (debug_flush): Likewise.
2543 * debug.h (debug_set_output): New declaration.
2544 * server.c (handle_monitor_command): Add debug-file option.
2545 (captured_main): Likewise.
2546
c1bc0935
AH
25472019-04-17 Alan Hayward <alan.hayward@arm.com>
2548
2549 * debug.c (remote_debug): Add definition.
2550 * debug.h (remote_debug): Add declaration.
2551 * hostio.c (remote_debug): Remove declaration.
2552 * remote-utils.c (struct ui_file): Likewise.
2553 (remote_debug): Likewise.
2554 * remote-utils.h (remote_debug): Likewise,
2555 * server.c (remote_debug): Remove definition.
2556
3f52fdbc
KB
25572019-04-10 Kevin Buettner <kevinb@redhat.com>
2558
2559 * linux-x86-low.c (x86_fill_gregset): Sign extend EAX value
2560 when using a 64-bit gdbserver.
2561
b0319eaa
TT
25622019-04-09 Tom Tromey <tromey@adacore.com>
2563
2564 * linux-low.c (select_event_lwp): Use find_thread_in_random.
2565
eedc3f4f
TT
25662019-04-08 Tom Tromey <tom@tromey.com>
2567
2568 * linux-low.c (linux_detach_one_lwp): Replace throw_exception with
2569 throw.
2570 (linux_resume_one_lwp): Likewise.
2571
230d2906
TT
25722019-04-08 Tom Tromey <tom@tromey.com>
2573
2574 * gdbreplay.c: Update.
2575 * linux-low.c: Update.
2576 * server.c: Update.
2577
a70b8144
TT
25782019-04-08 Tom Tromey <tom@tromey.com>
2579
2580 * server.c: Use C++ exception handling.
2581 * linux-low.c: Use C++ exception handling.
2582 * gdbreplay.c: Use C++ exception handling.
2583
3d6e9d23
TT
25842019-04-08 Tom Tromey <tom@tromey.com>
2585
2586 * server.c (handle_btrace_general_set, handle_qxfer_btrace)
2587 (handle_qxfer_btrace_conf, detach_or_kill_for_exit_cleanup)
2588 (captured_main, main): Update.
2589 * gdbreplay.c (main): Update.
2590
0570503d
PFC
25912019-04-05 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2592
2593 * linux-low.c (linux_get_auxv): Remove static. Return auxv entry
2594 value in argument pointer, return 1 if the entry is found and 0
2595 otherwise. Move comment.
2596 (linux_get_hwcap, linux_get_hwcap2): Use modified linux_get_auxv.
2597 * linux-low.h (linux_get_auxv): Declare.
2598 * linux-ppc-low.c (is_elfv2_inferior): Use linux_get_auxv.
2599
227a9e65
TT
26002019-04-05 Tom Tromey <tromey@adacore.com>
2601
2602 * server.c (gdbserver_usage): Use upper-case for metasyntactic
2603 variables.
2604
69f4c9cc
AH
26052019-03-28 Alan Hayward <alan.hayward@arm.com>
2606
2607 * linux-low.c (AT_HWCAP2): Add define if not already included.
2608
974c89e0
AH
26092019-03-26 Alan Hayward <alan.hayward@arm.com>
2610
2611 * linux-aarch64-low.c (aarch64_get_hwcap): Remove function.
2612 (aarch64_arch_setup): Call linux_get_hwcap.
2613 * linux-arm-low.c (arm_get_hwcap): Remove function.
2614 (arm_read_description): Call linux_get_hwcap.
2615 * linux-low.c (linux_get_auxv): New function.
2616 (linux_get_hwcap): Likewise.
2617 (linux_get_hwcap2): Likewise.
2618 * linux-low.h (linux_get_hwcap): New declaration.
2619 (linux_get_hwcap2): Likewise.
2620 * linux-ppc-low.c (ppc_get_auxv): Remove function.
2621 (ppc_arch_setup): Call linux_get_hwcap.
2622 * linux-s390-low.c (s390_get_hwcap): Remove function.
2623 (s390_arch_setup): Call linux_get_hwcap.
2624
1ef53e6b
AH
26252019-03-22 Alan Hayward <alan.hayward@arm.com>
2626 Jiong Wang <jiong.wang@arm.com>
2627
2628 * linux-aarch64-low.c (aarch64_store_pauthregset): New function.
2629 * linux-low.c (regsets_store_inferior_registers): Allow optional reads
2630 to fail.
2631 * linux-low.h (enum regset_type): Add OPTIONAL_REGS.
2632
ee4fbcfa
AH
26332019-03-22 Alan Hayward <alan.hayward@arm.com>
2634 Jiong Wang <jiong.wang@arm.com>
2635
2636 * linux-aarch64-low.c (AARCH64_HWCAP_PACA): New define.
2637 (aarch64_get_hwcap): New function.
2638 (aarch64_arch_setup): Read APIA hwcap.
2639
6dc0ebde
AH
26402019-03-22 Alan Hayward <alan.hayward@arm.com>
2641 Jiong Wang <jiong.wang@arm.com>
2642
2643 * linux-aarch64-ipa.c (get_ipa_tdesc): Add pauth param.
2644 (initialize_low_tracepoint): Likewise.
2645 * linux-aarch64-low.c (aarch64_arch_setup): Likewise.
2646 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Likewise.
2647 * linux-aarch64-tdesc.c (struct target_desc): Likewise.
2648 (aarch64_linux_read_description): Likewise.
2649 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Likewise.
2650
1163a4b7
JB
26512019-03-12 John Baldwin <jhb@FreeBSD.org>
2652
2653 * linux-x86-tdesc.c (i386_linux_read_description): Update call to
2654 i386_create_target_description for 'segments' parameter.
2655 * lynx-i386-low.c (lynx_i386_arch_setup): Likewise.
2656 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
2657 * win32-i386-low.c (i386_arch_setup): Likewise.
2658
d3a70e03
TT
26592019-03-12 Tom Tromey <tromey@adacore.com>
2660
2661 * linux-low.c (iterate_over_lwps): Update.
2662
37991b4f
TT
26632019-03-06 Tom Tromey <tom@tromey.com>
2664
2665 * server.c (detach_or_kill_for_exit_cleanup): Remove parameter.
2666 (captured_main): Use SCOPE_EXIT.
2667
45950eb6
SDJ
26682019-03-04 Sergio Durigan Junior <sergiodj@redhat.com>
2669
2670 * configure.srv: Use '$enable_unittest' instead of '$development'
2671 when checking whether to fill 'srv_regobj' on 'aarch64*-*-linux*'
2672 case.
2673
43ac54fc
TT
26742019-02-27 Tom Tromey <tromey@adacore.com>
2675
2676 * gdbreplay.c (logchar): Handle \r\n.
2677
df0da8a2
AH
26782019-02-07 Alan Hayward <alan.hayward@arm.com>
2679
2680 * linux-low.c (linux_attach): Add process before lwp.
2681 * server.c (attach_inferior): Check if already attached.
2682
1a5c2598
TT
26832019-02-07 Tom Tromey <tom@tromey.com>
2684
2685 * x86-tdesc.h: Rename include guard.
2686 * x86-low.h: Add include guard.
2687 * wincecompat.h: Rename include guard.
2688 * win32-low.h: Add include guard.
2689 * utils.h: Rename include guard.
2690 * tracepoint.h: Rename include guard.
2691 * tdesc.h: Rename include guard.
2692 * target.h: Rename include guard.
2693 * server.h: Rename include guard.
2694 * remote-utils.h: Rename include guard.
2695 * regcache.h: Rename include guard.
2696 * nto-low.h: Rename include guard.
2697 * notif.h: Add include guard.
2698 * mem-break.h: Rename include guard.
2699 * lynx-low.h: Add include guard.
2700 * linux-x86-tdesc.h: Add include guard.
2701 * linux-s390-tdesc.h: Add include guard.
2702 * linux-ppc-tdesc-init.h: Add include guard.
2703 * linux-low.h: Add include guard.
2704 * linux-aarch64-tdesc.h: Add include guard.
2705 * linux-aarch32-low.h: Add include guard.
2706 * inferiors.h: Rename include guard.
2707 * i387-fp.h: Rename include guard.
2708 * hostio.h: Rename include guard.
2709 * gdbthread.h: Rename include guard.
2710 * gdb_proc_service.h: Rename include guard.
2711 * event-loop.h: Rename include guard.
2712 * dll.h: Rename include guard.
2713 * debug.h: Rename include guard.
2714 * ax.h: Rename include guard.
2715
956cc47c
SN
27162018-01-30 Szabolcs Nagy <szabolcs.nagy@arm.com>
2717
2718 PR gdb/23985
2719 * Makefile.in (IPAGENT_CFLAGS): Add UNDO_GNULIB_CFLAGS.
2720 (UNDO_GNULIB_CFLAGS): Undo gnulib replacements.
2721
a0707f3c
TT
27222019-01-25 Tom Tromey <tom@tromey.com>
2723
2724 * Makefile.in (INCLUDE_CFLAGS): Don't add -I for common.
2725
0747795c
TT
27262019-01-25 Tom Tromey <tom@tromey.com>
2727
2728 * win32-low.c: Fix common/ includes.
2729 * win32-i386-low.c: Fix common/ includes.
2730 * tracepoint.c: Fix common/ includes.
2731 * thread-db.c: Fix common/ includes.
2732 * target.h: Fix common/ includes.
2733 * symbol.c: Fix common/ includes.
2734 * spu-low.c: Fix common/ includes.
2735 * server.h: Fix common/ includes.
2736 * server.c: Fix common/ includes.
2737 * remote-utils.c: Fix common/ includes.
2738 * regcache.h: Fix common/ includes.
2739 * regcache.c: Fix common/ includes.
2740 * nto-x86-low.c: Fix common/ includes.
2741 * notif.h: Fix common/ includes.
2742 * mem-break.h: Fix common/ includes.
2743 * lynx-low.c: Fix common/ includes.
2744 * lynx-i386-low.c: Fix common/ includes.
2745 * linux-x86-tdesc-selftest.c: Fix common/ includes.
2746 * linux-x86-low.c: Fix common/ includes.
2747 * linux-low.c: Fix common/ includes.
2748 * inferiors.h: Fix common/ includes.
2749 * i387-fp.c: Fix common/ includes.
2750 * hostio.c: Fix common/ includes.
2751 * hostio-errno.c: Fix common/ includes.
2752 * gdbthread.h: Fix common/ includes.
2753 * gdbreplay.c: Fix common/ includes.
2754 * fork-child.c: Fix common/ includes.
2755 * event-loop.c: Fix common/ includes.
2756 * ax.c:
2757 (enum gdb_agent_op): Fix common/ includes.
2758
be6d4f74
TT
27592019-01-21 Tom Tromey <tom@tromey.com>
2760
2761 * tracepoint.c: Fix includes.
2762 * remote-utils.c: Fix includes.
2763 * linux-x86-low.c: Fix includes.
2764
66d91b39
JB
27652019-01-01 Joel Brobecker <brobecker@adacore.com>
2766
2767 * gdbreplay.c (gdbreplay_version): Update copyright year in
2768 version message.
2769 * server.c (gdbserver_version): Likewise.
2770
754e3168
AH
27712018-12-05 Alan Hayward <alan.hayward@arm.com>
2772
2773 * linux-low.c (add_lwp): Switch ordering.
2774
d105de22
TT
27752018-11-29 Tom Tromey <tom@tromey.com>
2776
2777 * win32-low.c (win32_join): Take pid, not process.
2778 * target.h (struct target_ops) <join>: Change argument type.
2779 (join_inferior): Change argument name.
2780 * spu-low.c (spu_join): Take pid, not process.
2781 * server.c (handle_detach): Preserve pid before destroying
2782 process.
2783 * lynx-low.c (lynx_join): Take pid, not process.
2784 * linux-low.c (linux_join): Take pid, not process.
2785
50138245
AH
27862018-11-23 Alan Hayward <alan.hayward@arm.com>
2787
2788 * linux-aarch64-low.c (aarch64_cannot_store_register): Remove.
2789 (aarch64_cannot_fetch_register): Likewise.
2790 (struct linux_target_ops): Update references.
2791
64f57f3d
PFC
27922018-10-31 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2793
2794 * linux-ppc-low.c: Include nat/linux-ptrace.h.
2795
8d619c01
EBM
27962018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2797
2798 * configure.srv (ipa_ppc_linux_regobj): Add
2799 powerpc-isa207-htm-vsx32l-ipa.o and
2800 powerpc-isa207-htm-vsx64l-ipa.o.
2801 (powerpc*-*-linux*): Add powerpc-isa207-htm-vsx32l.o and
2802 powerpc-isa207-htm-vsx64l.o to srv_regobj. Add
2803 rs6000/power-htm-spr.xml, rs6000/power-htm-core.xml,
2804 rs6000/power64-htm-core.xml, rs6000/power-htm-fpu.xml,
2805 rs6000/power-htm-altivec.xml, rs6000/power-htm-vsx.xml,
2806 rs6000/power-htm-ppr.xml, rs6000/power-htm-dscr.xml,
2807 rs6000/power-htm-tar.xml, rs6000/powerpc-isa207-htm-vsx32l.xml,
2808 and rs6000/powerpc-isa207-htm-vsx64l.xml to srv_xmlfiles.
2809 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
2810 <PPC_TDESC_ISA207_HTM_VSX>: New enum value.
2811 (init_registers_powerpc_isa207_htm_vsx32l)
2812 (init_registers_powerpc_isa207_htm_vsx64l): Declare.
2813 * linux-ppc-low.c (ppc_fill_tm_sprregset, ppc_store_tm_sprregset)
2814 (ppc_store_tm_cgprregset, ppc_store_tm_cfprregset)
2815 (ppc_store_tm_cvrregset, ppc_store_tm_cvsxregset)
2816 (ppc_store_tm_cpprregset, ppc_store_tm_cdscrregset)
2817 (ppc_store_tm_ctarregset): New functions.
2818 (ppc_regsets): Add entries for HTM regsets.
2819 (ppc_arch_setup): Set htm in features struct when needed. Set
2820 sizes for the HTM regsets.
2821 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_HTM_VSX.
2822 (initialize_low_arch): Call
2823 init_registers_powerpc_isa207_htm_vsx32l and
2824 init_registers_powerpc_isa207_htm_vsx64l.
2825 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
2826 PPC_TDESC_ISA207_HTM_VSX.
2827 (initialize_low_tracepoint): Call
2828 init_registers_powerpc_isa207_htm_vsx32l and
2829 init_registers_powerpc_isa207_htm_vsx64l.
2830
232bfb86
EBM
28312018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2832
2833 * configure.srv (powerpc*-*-linux*): Add rs6000/power-ebb.xml and
2834 rs6000/power-linux-pmu.xml to srv_xmlfiles.
2835 * linux-ppc-low.c (ppc_store_ebbregset, ppc_fill_pmuregset)
2836 (ppc_store_pmuregset): New functions.
2837 (ppc_regsets): Add entries for ebb and pmu regsets.
2838 (ppc_arch_setup): Set isa207 in features struct if the ebb and
2839 pmu regsets are available. Set sizes for these regsets.
2840
f2cf6173
EBM
28412018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2842
2843 * configure.srv (ipa_ppc_linux_regobj): Add
2844 powerpc-isa207-vsx64l-ipa.o and powerpc-isa207-vsx32l-ipa.o.
2845 (powerpc*-*-linux*): Add powerpc-isa207-vsx32l.o and
2846 powerpc-isa207-vsx64l.o to srv_regobj, add rs6000/power-tar.xml,
2847 rs6000/powerpc-isa207-vsx32l.xml, and
2848 rs6000/powerpc-isa207-vsx64l.xml to srv_xmlfiles.
2849 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
2850 <PPC_TDESC_ISA207_VSX>: New enum value.
2851 (init_registers_powerpc_isa207_vsx32l): Declare.
2852 (init_registers_powerpc_isa207_vsx64l): Declare.
2853 * linux-ppc-low.c (ppc_fill_tarregset): New function.
2854 (ppc_store_tarregset): New function.
2855 (ppc_regsets): Add entry for the TAR regset.
2856 (ppc_arch_setup): Set isa207 in features struct when needed. Set
2857 size for the TAR regsets.
2858 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_VSX.
2859 (initialize_low_arch): Call init_registers_powerpc_isa207_vsx32l
2860 and init_registers_powerpc_isa207_vsx64l.
2861 * linux-ppc-ipa.c (get_ipa_tdesc): Handle PPC_TDESC_ISA207_VSX.
2862 (initialize_low_tracepoint): Call
2863 init_registers_powerpc_isa207_vsx32l and
2864 init_registers_powerpc_isa207_vsx64l.
2865
7ca18ed6
EBM
28662018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
2867 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2868
2869 * configure.srv (ipa_ppc_linux_regobj): Add
2870 powerpc-isa205-ppr-dscr-vsx32l-ipa.o and
2871 powerpc-isa205-ppr-dscr-vsx64l-ipa.o.
2872 (powerpc*-*-linux*): Add powerpc-isa205-ppr-dscr-vsx32l.o and
2873 powerpc-isa205-ppr-dscr-vsx64l.o to srv_regobj, add
2874 rs6000/power-dscr.xml, rs6000/power-ppr.xml,
2875 rs6000/powerpc-isa205-ppr-dscr-vsx32l.xml and
2876 rs6000/powerpc-isa205-ppr-dscr-vsx64l.xml to srv_xmlfiles.
2877 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
2878 <PPC_TDESC_ISA205_PPR_DSCR_VSX>: New enum value.
2879 (init_registers_powerpc_isa205_ppr_dscr_vsx32l)
2880 (init_registers_powerpc_isa205_ppr_dscr_vsx64l): Declare.
2881 * linux-ppc-low.c: Include "elf/common.h" and <sys/uio.h>.
2882 (ppc_hwcap): Add comment.
2883 (ppc_hwcap2): New global.
2884 (ppc_check_regset, ppc_fill_pprregset, ppc_store_pprregset)
2885 (ppc_fill_dscrregset, ppc_store_dscrregset): New functions.
2886 (ppc_regsets): Add entries for the DSCR and PPR regsets.
2887 (ppc_arch_setup): Get AT_HWCAP2. Set ppr_dscr in features struct
2888 when needed. Set sizes for the the DSCR and PPR regsets.
2889 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA205_PPR_DSCR_VSX.
2890 (initialize_low_arch): Call
2891 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
2892 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
2893 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
2894 PPC_TDESC_ISA205_PPR_DSCR_VSX.
2895 (initialize_low_tracepoint): Call
2896 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
2897 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
2898
5c849b22
PFC
28992018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2900
2901 * linux-ppc-low.c (ppc_fill_vrregset): Remove memset calls.
2902
8ecfd7bd
SDJ
29032018-10-10 Sergio Durigan Junior <sergiodj@redhat.com>
2904 Simon Marchi <simark@simark.ca>
2905
2906 * acinclude.m4: Include "../selftest.m4".
2907 * configure: Regenerate.
2908 * configure.ac: Use "GDB_AC_SELFTEST".
2909 * configure.srv: Use "$enable_unittests" instead of
2910 "$development" when checking whether unit tests have been
2911 enabled.
2912 * server.c (captured_main): Update message informing that
2913 selftests have been disabled.
2914
96643e35
TT
29152018-10-04 Tom Tromey <tom@tromey.com>
2916
2917 * configure: Rebuild.
2918
da4ae14a
TT
29192018-10-04 Tom Tromey <tom@tromey.com>
2920
2921 * server.c (handle_status): Rename inner "thread".
2922 (process_serial_event): Declare "res" in 'm' case.
2923 * linux-low.c (last_thread_of_process_p, find_lwp_pid)
2924 (iterate_over_lwps): Rename inner "thread".
2925 (linux_qxfer_libraries_svr4): Rename inner "len".
2926 * gdbthread.h (find_thread_in_random): Rename inner "thread".
2927
7c619dbd
GB
29282018-10-01 Gary Benson <gbenson@redhat.com>
2929
2930 * gdb_proc_service.h: Moved common code to
2931 common/gdb_proc_service.h.
2932
3795e814
GB
29332018-10-01 Gary Benson <gbenson@redhat.com>
2934
2935 * gdb_proc_service.h: Synchronize comments and whitespace with
2936 GDB's version of this file.
2937
49b036f1
TT
29382018-09-25 Tom Tromey <tom@tromey.com>
2939
2940 * configure: Rebuild.
2941 * configure.ac (WARN_CFLAGS): Don't remove -Wmissing-prototypes.
2942
8ff03f0b
SM
29432018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
2944
2945 * Makefile.in (gdbserver$(EXEEXT)): Sort OBS.
2946 (gdbreplay$(EXEEXT)): Sort GDBREPLAY_OBS.
2947 ($(IPA_LIB)): Sort IPA_OBJS.
2948
a1cd91dc
SM
29492018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
2950
2951 * Makefile.in: Remove references to $(ADD_DEPS).
2952
752312ba
TT
29532018-09-16 Tom Tromey <tom@tromey.com>
2954
2955 * remote-utils.c (remote_open): Use GNU style for metasyntactic
2956 variables.
2957 * gdbreplay.c (gdbreplay_usage): Use GNU style for metasyntactic
2958 variables.
2959
f1628857
TT
29602018-09-05 Tom Tromey <tom@tromey.com>
2961
2962 * configure: Rebuild.
2963
ad202fcc
SM
29642018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
2965
2966 PR build/23399
2967 * tracepoint.c (IPA_SYM_STRUCT_NAME): Define.
2968
d3d8724a
TT
29692018-08-27 Tom Tromey <tom@tromey.com>
2970
2971 PR build/23087:
2972 * configure: Rebuild.
2973
b4f183d2
TT
29742018-08-27 Tom Tromey <tom@tromey.com>
2975
2976 * linux-s390-low.c (s390_emit_ext, s390_emit_litpool)
2977 (s390_emit_const, s390_emit_reg, s390_emit_zero_ext)
2978 (s390_emit_stack_adjust, s390_emit_set_r2, s390x_emit_ext)
2979 (s390x_emit_const, s390x_emit_reg, s390x_emit_zero_ext)
2980 (s390x_emit_stack_adjust): Add casts to unsigned char.
2981
4e2aa472
SM
29822018-08-22 Simon Marchi <simon.marchi@ericsson.com>
2983
2984 PR gdb/23374
2985 PR gdb/23375
2986 * server.h (struct client_state) <disable_randomization>:
2987 Initialize to 1.
2988
cf4088a9
SM
29892018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
2990
2991 * linux-mips-low.c (mips_collect_ptrace_register): Remove unused
2992 variable.
2993 (mips_supply_ptrace_register): Likewise.
2994
a0de763e
TT
29952018-07-22 Tom Tromey <tom@tromey.com>
2996
2997 * configure: Rebuild.
2998
b0a7723d
TT
29992018-07-22 Tom Tromey <tom@tromey.com>
3000
3001 * win32-low.c (win32_create_inferior): Remove unused variables.
3002 * gdbreplay.c (remote_open): Remove unused variable.
3003 * remote-utils.c (remote_prepare): Remove unused variable.
3004 * x86-tdesc.h (X86_TDESC_H): Define.
3005 (amd64_expedite_regs): Define conditionally.
3006 (i386_expedite_regs): Mark ATTRIBUTE_UNUSED.
3007 * linux-x86-tdesc.c (i386_tdescs): Move inside #if.
3008 * remote-utils.c (readchar): Remove unused variable.
3009
a780ef4f
PA
30102018-07-13 Pedro Alves <palves@redhat.com>
3011
3012 * linux-low.c (linux_kill): Change parameter to process_info
3013 pointer instead of pid. Adjust.
3014 * lynx-low.c (lynx_kill): Likewise.
3015 * nto-low.c (nto_kill): Likewise.
3016 * spu-low.c (spu_kill): Likewise.
3017 * win32-low.c (win32_kill): Likewise.
3018 * server.c (handle_v_kill, kill_inferior_callback)
3019 (detach_or_kill_for_exit): Adjust.
3020 * target.c (kill_inferior): Change parameter to process_info
3021 pointer instead of pid. Adjust.
3022 * target.h (struct target_ops) <kill>: Change parameter to
3023 process_info pointer instead of pid. Adjust all implementations
3024 and callers.
3025 (kill_inferior): Likewise.
3026
ef2ddb33
PA
30272018-07-13 Pedro Alves <palves@redhat.com>
3028
3029 * linux-low.c (linux_detach, linux_join): Change parameter to
3030 process_info pointer instead of pid. Adjust.
3031 * lynx-low.c (lynx_detach, lynx_join): Likewise.
3032 * nto-low.c (nto_detach): Likewise.
3033 * spu-low.c (spu_detach, spu_join): Likewise.
3034 * win32-low.c (win32_detach, win32_join): Likewise.
3035 * server.c (handle_detach, detach_or_kill_for_exit): Adjust.
3036 * target.h (struct target_ops) <detach, join>: Change parameter to
3037 process_info pointer instead of pid. Adjust all implementations
3038 and callers.
3039 (detach_inferior, join_inferior): Rename 'pid' parameter to
3040 'proc'.
3041
c7ab0aef
SDJ
30422018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
3043 Jan Kratochvil <jan.kratochvil@redhat.com>
3044 Paul Fertser <fercerpav@gmail.com>
3045 Tsutomu Seki <sekiriki@gmail.com>
3046
3047 * Makefile.in (SFILES): Add '$(srcdir)/common/netstuff.c'.
3048 (OBS): Add 'common/netstuff.o'.
3049 (GDBREPLAY_OBS): Likewise.
3050 * gdbreplay.c: Include 'wspiapi.h' and 'netstuff.h'.
3051 (remote_open): Implement support for IPv6
3052 connections.
3053 * remote-utils.c: Include 'netstuff.h', 'filestuff.h'
3054 and 'wspiapi.h'.
3055 (handle_accept_event): Accept connections from IPv6 sources.
3056 (remote_prepare): Handle IPv6-style hostnames; implement
3057 support for IPv6 connections.
3058 (remote_open): Implement support for printing connections from
3059 IPv6 sources.
3060
31445d10
PA
30612018-07-11 Pedro Alves <palves@redhat.com>
3062
3063 PR gdb/23377
3064 * mem-break.c (any_persistent_commands): Add process_info
3065 parameter and use it instead of relying on the current process.
3066 Change return type to bool.
3067 * mem-break.h (any_persistent_commands): Add process_info
3068 parameter and change return type to bool.
3069 * server.c (handle_detach): Remove require_running_or_return call.
3070 Look up the process_info for the process we're about to detach.
3071 If not found, return back error to GDB. Adjust
3072 any_persistent_commands call to pass down a process pointer.
3073
cb197132
PA
30742018-07-11 Pedro Alves <palves@redhat.com>
3075
3076 * i387-fp.c (i387_cache_to_fsave, cache_to_fxsave)
3077 (i387_cache_to_xsave): Use regcache_raw_get_unsigned_by_name
3078 instead of collect_register_by_name.
3079 * regcache.c (regcache_raw_get_unsigned_by_name): New.
3080 * regcache.h (regcache_raw_get_unsigned_by_name): New.
3081
1b919490
VB
30822018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
3083 Pedro Alves <palves@redhat.com>
3084
3085 * linux-low.c (initialize_low): Call linux_proc_init_warnings.
3086
d7e15655
TT
30872018-07-03 Tom Tromey <tom@tromey.com>
3088
3089 * linux-low.c: Update.
3090 * lynx-low.c: Update.
3091 * mem-break.c: Update.
3092 * nto-low.c: Update.
3093 * remote-utils.c: Update.
3094 * server.c: Update.
3095 * spu-low.c: Update.
3096 * target.c: Update.
3097 * win32-low.c: Update.
3098
26a57c92
TT
30992018-07-03 Tom Tromey <tom@tromey.com>
3100
3101 * server.c: Update.
3102
0e998d96
TT
31032018-07-03 Tom Tromey <tom@tromey.com>
3104
3105 * linux-low.c: Update.
3106
cc6bcb54
TT
31072018-07-03 Tom Tromey <tom@tromey.com>
3108
3109 * target.c: Update.
3110
e38504b3
TT
31112018-07-03 Tom Tromey <tom@tromey.com>
3112
3113 * linux-low.c: Update.
3114 * linux-mips-low.c: Update.
3115 * lynx-low.c: Update.
3116 * nto-low.c: Update.
3117 * remote-utils.c: Update.
3118 * server.c: Update.
3119 * spu-low.c: Update.
3120 * target.c: Update.
3121 * thread-db.c: Update.
3122
e99b03dc
TT
31232018-07-03 Tom Tromey <tom@tromey.com>
3124
3125 * linux-low.c: Update.
3126 * linux-mips-low.c: Update.
3127 * lynx-low.c: Update.
3128 * mem-break.c: Update.
3129 * nto-low.c: Update.
3130 * remote-utils.c: Update.
3131 * server.c: Update.
3132 * spu-low.c: Update.
3133 * target.c: Update.
3134 * tracepoint.c: Update.
3135
f2907e49
TT
31362018-07-03 Tom Tromey <tom@tromey.com>
3137
3138 * linux-low.c: Update.
3139 * linux-ppc-low.c: Update.
3140 * linux-x86-low.c: Update.
3141 * proc-service.c: Update.
3142 * server.c: Update.
3143 * spu-low.c: Update.
3144 * thread-db.c: Update.
3145 * win32-low.c: Update.
3146
fd79271b
TT
31472018-07-03 Tom Tromey <tom@tromey.com>
3148
3149 * linux-low.c: Update.
3150 * lynx-low.c: Update.
3151 * nto-low.c: Update.
3152 * remote-utils.c: Update.
3153 * spu-low.c: Update.
3154 * thread-db.c: Update.
3155 * win32-low.c: Update.
3156
c0867626
SDJ
31572018-06-29 Joel Brobecker <brobecker@adacore.com>
3158
3159 * linux-x86-tdesc.c (amd64_linux_read_description): Add missing
3160 parameter in call to 'amd64_create_target_description'.
3161
2512d7ef
JK
31622018-06-28 Jan Kratochvil <jan.kratochvil@redhat.com>
3163
3164 * x86-tdesc.h: Remove executable permission flag.
3165
d0ac1c44
SM
31662018-06-19 Simon Marchi <simon.marchi@ericsson.com>
3167
3168 * configure.ac: Remove AC_PREREQ, add missing quoting.
3169 * configure: Re-generate.
3170 * config.in: Re-generate.
3171 * aclocal.m4: Re-generate.
3172
c4eb05ff
SM
31732018-06-18 Simon Marchi <simon.marchi@ericsson.com>
3174
3175 * tracepoint.h (current_traceframe): Remove declaration.
3176
02895270
AH
31772018-06-18 Alan Hayward <alan.hayward@arm.com>
3178
3179 * linux-aarch64-low.c (is_sve_tdesc): New function.
3180 (aarch64_sve_regs_copy_to_regcache): Likewise.
3181 (aarch64_sve_regs_copy_from_regcache): Likewise.
3182 (aarch64_regs_info): Add SVE checks.
3183 (initialize_low_arch): Initialize SVE.
3184
e9902bfc
AH
31852018-06-18 Alan Hayward <alan.hayward@arm.com>
3186
3187 * Makefile.in: Add aarch64-sve-linux-ptrace.c.
3188
fefa175e
AH
31892018-06-11 Alan Hayward <alan.hayward@arm.com>
3190
3191 * linux-aarch64-ipa.c (get_ipa_tdesc): Add null VQ param.
3192 (initialize_low_tracepoint): Likewise
3193 * linux-aarch64-low.c (aarch64_arch_setup): Get VQ.
3194 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Add null VQ
3195 param.
3196 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add VQ
3197 checks.
3198 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Add VQ.
3199
b91ad3ff
AH
32002018-06-11 Alan Hayward <alan.hayward@arm.com>
3201
3202 * server.h (PBUFSIZ): Increase size
3203
f868386e
AH
32042018-06-11 Alan Hayward <alan.hayward@arm.com>
3205
3206 * regcache.c (regcache::raw_compare): New function.
3207 * regcache.h (regcache::raw_compare): New declaration.
3208
9c861883
AH
32092018-06-11 Alan Hayward <alan.hayward@arm.com>
3210
3211 * regcache.c (new_register_cache): Use new.
3212 (free_register_cache): Use delete.
3213 (register_data): Use const.
3214 (supply_register): Move body inside regcache.
3215 (regcache::raw_supply): New override function.
3216 (collect_register): Move body inside regcache.
3217 (regcache::raw_collect): New override function.
3218 (regcache::get_register_status): New override function.
3219 * regcache.h (struct regcache): Inherit from reg_buffer_common.
3220
40591844
TT
32212018-06-09 Tom Tromey <tom@tromey.com>
3222
3223 * event-loop.c (gdb_event, gdb_event_p): Remove typedefs. Don't
3224 declare queue.
3225 (event_queue): Use std::queue.
3226 (gdb_event_xfree): Remove.
3227 (initialize_event_loop, process_event, wait_for_event): Update.
3228
6341380d
SC
32292018-06-08 Stan Cox <scox@redhat.com>
3230
3231 * win32-low.c (win32_create_inferior): last_ptid and last_status
3232 moved to client_state.
3233
03349c93
PA
32342018-06-08 Pedro Alves <palves@redhat.com>
3235
3236 * Makefile.in (GDBREPLAY_OBS): Add common/cleanups.o,
3237 common/common-exceptions.o, common/common-utils.o,
3238 common/errors.o, common/print-utils.o and utils.o.
3239 * gdbreplay.c: Include "common-defs.h" instead of the two
3240 'config.h's here. Don't include stdio.h, errno.h, stdlib.h,
3241 string.h or alloca.h.
3242 (perror_with_name): Delete.
3243 (remote_open): Use xstrdup instead of strdup.
3244 (main): Rename to ...
3245 (captured_main): ... this.
3246 (main): New.
3247
8dcc53b3
TT
32482018-06-08 Tom Tromey <tom@tromey.com>
3249
3250 * linux-low.c (linux_low_read_btrace): Update.
3251
c12a5089
SC
32522018-06-04 Stan Cox <scox@redhat.com>
3253
3254 * server.h (struct client_state): New.
3255 * server.c (cont_thread, general_thread, multi_process)
3256 (report_fork_events, report_vfork_events, report_exec_events)
3257 (report_thread_events, swbreak_feature, hwbreak_feature)
3258 (vCont_supported, disable_randomization, pass_signals)
3259 (program_signals, program_signals_p, last_status, last_ptid, own_buf):
3260 Moved to client_state.
3261 * remote-utils.c (remote_debug, noack_mode)
3262 (transport_is_reliable): Moved to client_state.
3263 * tracepoint.c (current_traceframe): Moved to client_state.
3264
3265 Update all callers.
3266 * server.c, remote-utils.c, tracepoint.c, fork-child.c,
3267 linux-low.c, remote-utils.h, target.c: Use client_state.
3268
122394f1
AH
32692018-05-31 Alan Hayward <alan.hayward@arm.com>
3270
3271 * configure.srv: Add new c/h file.
3272
95228a0d
AH
32732018-05-31 Alan Hayward <alan.hayward@arm.com>
3274
3275 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add
3276 null VQ.
3277
d8dab6c3
MR
32782018-05-25 Maciej W. Rozycki <macro@mips.com>
3279
3280 * gdb.arch/mips-fpregset-core.exp: New test.
3281 * gdb.arch/mips-fpregset-core.c: New test source.
3282
81e25b7c
EK
32832018-05-23 Erik Kurzinger <ekurzinger@nvidia.com>
3284
3285 PR server/23198
3286 * hostio.c (require_int): Do not report overflow for integers
3287 between 0xfffffff and 0x7fffffff.
3288
7e947ad3
MR
32892018-05-22 Maciej W. Rozycki <macro@mips.com>
3290
3291 * linux-mips-low.c [HAVE_PTRACE_GETREGS] (mips_collect_register)
3292 (mips_supply_register): Move outside HAVE_PTRACE_GETREGS.
3293 (mips_collect_ptrace_register, mips_supply_ptrace_register): New
3294 functions.
3295 (the_low_target): Wire them.
3296
1d75a658
PFC
32972018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3298
3299 * linux-ppc-low.c (ppc_fill_vrregset): Add vscr_offset variable.
3300 Set vscr_offset to 0 in little-endian mode and 12 in big-endian
3301 mode. Call collect_register_by_name with vscr using
3302 vscr_offset. Zero-pad vscr and vrsave fields in collector buffer.
3303 (ppc_store_vrregset): Add and set vscr_offset variable as in
3304 ppc_fill_vrregset. Call supply_register_by_name with vscr using
3305 vscr_offset.
3306
d078308a
PFC
33072018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3308
3309 * linux-ppc-low.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
3310 (ppc_arch_setup): Change SIZEOF_VRREGS and SIZEOF_VSXREGS to
3311 PPC_LINUX_SIZEOF_VRREGSET and PPC_LINUX_SIZEOF_VSXREGSET.
3312
7273b5fc
PFC
33132018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3314
3315 * linux-ppc-low.c (ppc_fill_vsxregset): Remove ppc_hwcap check.
3316 (ppc_store_vsxregset): Likewise.
3317 (ppc_fill_vrregset): Likewise.
3318 (ppc_store_vrregset): Likewise.
3319 (ppc_fill_evrregset): Likewise.
3320 (ppc_store_evrregset): Likewise.
3321 (ppc_regsets): Set VSX/VR/EVR regset sizes to 0.
3322 (ppc_arch_setup): Iterate through ppc_regsets and set sizes when
3323 needed.
3324
2e077f5e
PFC
33252018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3326
3327 * linux-ppc-low.c (ppc_arch_setup): Remove code for getting the
3328 wordsize of the inferior. Call ppc_linux_target_wordsize.
3329
bd64614e
PFC
33302018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3331
3332 * configure.srv (srv_tgtobj): Add arch/ppc-linux-common.o.
3333 * Makefile.in (SFILES): Add arch/ppc-linux-common.c.
3334 * linux-ppc-tdesc.h: Rename to linux-ppc-tdesc-init.h.
3335 * linux-ppc-tdesc-init.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
3336 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
3337 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
3338 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
3339 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
3340 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
3341 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
3342 (tdesc_powerpc_e500l): Remove.
3343 * linux-ppc-ipa.c: Include arch/ppc-linux-tdesc.h and
3344 linux-ppc-tdesc-init.h. Don't include linux-ppc-tdesc.h.
3345 * linux-ppc-low.c: Include arch/ppc-linux-common.h,
3346 arch/ppc-linux-tdesc.h, and linux-ppc-tdesc-init.h. Don't include
3347 linux-ppc-tdesc.h.
3348 (ppc_arch_setup): Remove target description matching code. Fill a
3349 ppc_linux_features struct and call ppc_linux_match_description
3350 with it.
3351
75d74cca
MR
33522018-05-22 Maciej W. Rozycki <macro@mips.com>
3353
3354 * linux-mips-low.c (mips_cannot_fetch_register): Return 1 if the
3355 width of the requested register exceeds the width of the
3356 `ptrace' data type.
3357 (mips_cannot_store_register): Likewise.
3358
e4439e43
MR
33592018-05-21 Maciej W. Rozycki <macro@mips.com>
3360
3361 * linux-mips-low.c (mips_fetch_register): New function. Update
3362 preceding comment.
3363 (mips_store_gregset): Supply 0 rather than $restart for $zero.
3364 (the_low_target): Wire `mips_fetch_register'.
3365
55271bf9
JB
33662018-05-10 Joel Brobecker <brobecker@adacore.com>
3367
3368 * lynx-i386-low.c (LYNXOS_178): New macro.
3369 [LYNXOS_178] (usr_fcontext_t): Provide a definition that matches
3370 the layout on LynxOS-178.
3371 (lynx_i386_fill_fpregset, lynx_i386_store_fpregset): Do not
3372 handle floating point registers that are not supported by
3373 LynxOS-178.
3374
1a34f210
TT
33752018-05-10 Tom Tromey <tom@tromey.com>
3376
3377 * configure: Rebuild.
3378
190852c8
JB
33792018-05-10 Joel Brobecker <brobecker@adacore.com>
3380
3381 PR server/23158:
3382 * tdesc.h (init_target_desc) <expedite_regs>: New parameter.
3383 * tdesc.c (init_target_desc) <expedite_regs>: New parameter.
3384 Use it to set the expedite_regs field in the given tdesc.
3385 * x86-tdesc.h: New file.
3386 * linux-aarch64-tdesc.c (aarch64_linux_read_description):
3387 Adjust following the addition of the new expedite_regs parameter
3388 to init_target_desc.
3389 * linux-tic6x-low.c (tic6x_read_description): Likewise.
3390 * linux-x86-tdesc.c: #include "x86-tdesc.h".
3391 (i386_linux_read_description, amd64_linux_read_description):
3392 Adjust following the addition of the new expedite_regs parameter
3393 to init_target_desc.
3394 * lynx-i386-low.c: #include "x86-tdesc.h".
3395 (lynx_i386_arch_setup): Adjust following the addition of the new
3396 expedite_regs parameter to init_target_desc.
3397 * nto-x86-low.c: #include "x86-tdesc.h".
3398 (nto_x86_arch_setup): Adjust following the addition of the new
3399 expedite_regs parameter to init_target_desc.
3400 * win32-i386-low.c: #include "x86-tdesc.h".
3401 (i386_arch_setup): Adjust following the addition of the new
3402 expedite_regs parameter to init_target_desc.
3403
7dbac825
JB
34042018-05-10 Joel Brobecker <brobecker@adacore.com>
3405
3406 PR server/23158:
3407 * win32-low.c (win32_create_inferior): Add call to my_wait
3408 setting last_status global.
3409
906994d9
JB
34102018-05-10 Joel Brobecker <brobecker@adacore.com>
3411
3412 PR server/23158:
3413 * win32-low.c (create_process): Only call gdb_tilde_expand if
3414 inferior_cwd is not NULL.
3415
8ee22052
AB
34162018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
3417
3418 * i387-fp.c (i387_cache_to_xsave): Only write x87 control
3419 registers to the cache if their values have changed.
3420 (i387_xsave_to_cache): Provide default values for x87 control
3421 registers when these features are available, but disabled.
3422 * regcache.c (supply_register_by_name_zeroed): New function.
3423 * regcache.h (supply_register_by_name_zeroed): Declare new
3424 function.
3425
aff689d3
TT
34262018-05-07 Tom Tromey <tom@tromey.com>
3427
3428 * configure: Rebuild.
3429
85e26832
TT
34302018-05-04 Tom Tromey <tom@tromey.com>
3431
3432 * configure: Rebuild.
3433
a3b60e45
JK
34342018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
3435 Pedro Alves <palves@redhat.com>
3436
3437 * linux-aarch64-low.c (aarch64_stopped_data_address):
3438 Likewise.
3439
632e107b
TT
34402018-04-27 Tom Tromey <tom@tromey.com>
3441
3442 * configure: Rebuild.
3443
458412c3
TT
34442018-04-23 Tom Tromey <tom@tromey.com>
3445
3446 * configure: Rebuild.
3447
f31c089e
SM
34482018-04-19 Simon Marchi <simon.marchi@ericsson.com>
3449
3450 * Makefile.in (depcomp): Add "..".
3451 (all_deps_files): New and use it.
3452
b319b098
AH
34532018-04-18 Alan Hayward <alan.hayward@arm.com>
3454
3455 * configure.srv (aarch64*-*-linux*): Don't include xml.
3456 (i[34567]86-*-cygwin*): Likewise.
3457 (i[34567]86-*-linux*): Likewise.
3458 (i[34567]86-*-lynxos*): Likewise.
3459 (i[34567]86-*-mingw32ce*): Likewise.
3460 (i[34567]86-*-mingw*): Likewise.
3461 (i[34567]86-*-nto*): Likewise.
3462 (tic6x-*-uclinux): Likewise.
3463 (x86_64-*-linux*): Likewise.
3464 (x86_64-*-mingw*): Likewise.
3465 (x86_64-*-cygwin*): Likewise.
3466
3b74854b
AH
34672018-04-18 Alan Hayward <alan.hayward@arm.com>
3468
3469 * tdesc.c: Remove xml parameter.
3470
e98577a9
AH
34712018-04-18 Alan Hayward <alan.hayward@arm.com>
3472
3473 * server.c (get_features_xml): Remove cast.
3474 * tdesc.c (void target_desc::accept): Fill in function.
3475 (tdesc_get_features_xml): Remove old xml creation.
3476 (print_xml_feature::visit_pre): Add xml vistor.
3477 * tdesc.h (struct target_desc): Make xmltarget mutable.
3478 (tdesc_get_features_xml): Remove declaration.
3479
d278f585
AH
34802018-04-18 Alan Hayward <alan.hayward@arm.com>
3481
3482 * tdesc.c (tdesc_architecture_name): Add new function.
3483 (tdesc_osabi_name): Likewise.
3484 (tdesc_get_features_xml): Use new functions.
3485
eee8a18d
AH
34862018-04-18 Alan Hayward <alan.hayward@arm.com>
3487
3488 * tdesc.c (tdesc_create_flags): Remove.
3489 (tdesc_add_flag): Likewise.
3490 (tdesc_named_type): Likewise.
3491 (tdesc_create_union): Likewise.
3492 (tdesc_create_struct): Likewise.
3493 (tdesc_create_vector): Likewise.
3494 (tdesc_add_bitfield): Likewise.
3495 (tdesc_add_field): Likewise.
3496 (tdesc_set_struct_size): Likewise.
3497
82ec9bc7
AH
34982018-04-18 Alan Hayward <alan.hayward@arm.com>
3499
3500 * tdesc.c (~target_desc): Remove implictly deleted items.
3501 (init_target_desc): Iterate all features.
3502 (tdesc_get_features_xml): Use vector.
3503 (tdesc_create_feature): Create feature.
3504 * tdesc.h (tdesc_feature) Remove
3505 (target_desc): Add features.
3506
ea3e7d71
AH
35072018-04-18 Alan Hayward <alan.hayward@arm.com>
3508
3509 * Makefile.in: Add common/tdesc.c
3510 * tdesc.c (init_target_desc): init all reg_defs from register
3511 vector.
3512 (tdesc_create_reg): Create tdesc_reg.
3513 * tdesc.h (tdesc_feature): Add register vector.
3514
17d08cd4
SM
35152018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
3516
3517 * tdesc.h (struct target_desc) <features>: Change type to
3518 std::vector<std::string>.
3519 * tdesc.c (target_desc::~target_desc): Adjust to std::vector
3520 changes.
3521 (tdesc_get_features_xml): Likewise.
3522 (tdesc_create_feature): Likewise.
3523
5cd3e386
AH
35242018-03-26 Alan Hayward <alan.hayward@arm.com>
3525
3526 * regcache.c (find_register_by_number): Return a ref.
3527 (find_regno): Use references.
3528 (register_size): Likewise.
3529 (register_data): Likewise.
3530 * tdesc.c (target_desc::~target_desc): Remove free calls.
3531 (target_desc::operator==): Use std::vector compare.
3532 (init_target_desc): Use reference.
3533 (tdesc_create_reg): Use reg constructors.
3534 * tdesc.h (struct target_desc): Replace pointer with object.
3535
dff7492c
AH
35362018-03-23 Alan Hayward <alan.hayward@arm.com>
3537
3538 * regcache.c (find_register_by_number): Make static.
3539 (find_regno): Use find_register_by_number
3540 * regcache.h (struct reg): Remove declaration.
3541
d80e5242
AH
35422018-03-23 Alan Hayward <alan.hayward@arm.com>
3543
3544 * tdesc.c (target_desc::~target_desc): Move to here.
3545 (target_desc::operator==): Likewise.
3546 * tdesc.h (target_desc::~target_desc): Move from here.
3547 (target_desc::operator==): Likewise.
3548
f69c5afb
AA
35492018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
3550
3551 * linux-s390-low.c (s390_get_wordsize): Correct brace style.
3552
ce29f843
AA
35532018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
3554
3555 * linux-s390-ipa.c (get_ipa_tdesc): Add handling for
3556 S390_TDESC_GS.
3557 * linux-s390-low.c (s390_get_ipa_tdesc_idx): Likewise.
3558 (initialize_low_tracepoint): Call init_registers_s390x_gs_linux64
3559 and init_registers_s390_gs_linux64.
3560
c49bd90b
AA
35612018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
3562
3563 * linux-s390-low.c (s390_fill_gs): Remove function.
3564 (s390_fill_gsbc): Remove function.
3565 (s390_regsets): Set fill functions for the guarded storage regsets
3566 to NULL.
3567
7edb9bd3
AA
35682018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
3569
3570 * linux-s390-low.c (s390_get_hwcap): Replace tdesc parameter by
3571 the word size. Add comment.
3572 (s390_get_wordsize): New function.
3573 (s390_arch_setup): No longer select a temporary tdesc to fetch the
3574 pswm with it. Instead, use s390_get_wordsize to determine the
3575 word size first and derive the correct tdesc from that directly.
3576
39be3c7e
SM
35772018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
3578
3579 * Makefile.in: Include silent-rules.mk.
3580 (srcdir, abs_top_srcdir, abs_srcdir, VPATH): Move up.
3581 (COMPILE): Add ECHO_CXX.
3582 (gdbserver$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
3583 (gdbreplay$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
3584 ($(IPA_LIB)): Add SILENCE and ECHO_CXXLD.
3585 (version-generated.c): Add ECHO_GEN.
3586 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN_GENERATED.
3587 (IPAGENT_COMPILE): Add ECHO_CXX.
3588 (%-generated.c): Add ECHO_REGDAT.
3589
3ae9ce5d
TT
35902018-03-14 Tom Tromey <tom@tromey.com>
3591
3592 PR cli/14977:
3593 * ax.c (ax_printf): Special case for NULL.
3594
e6a58aa8
SM
35952018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
3596
3597 * linux-low.c (linux_qxfer_libraries_svr4): Use
3598 xml_escape_text_append.
3599
f6e8a41e
SM
36002018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
3601
3602 * linux-low.c (linux_qxfer_libraries_svr4): Use std::string.
3603
b9671caf
SM
36042018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
3605
3606 * server.c (handle_general_set): Remove unnecessary xstrdup.
3607
e80aaf61
SM
36082018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
3609
3610 * server.c (parse_debug_format_options): Adjust to
3611 delim_string_to_char_ptr_vec changes.
3612 * thread-db.c (thread_db_load_search): Adjust to
3613 dirnames_to_char_ptr_vec changes.
3614
b1223e78
MM
36152018-03-01 Markus Metzger <markus.t.metzger@intel.com>
3616
3617 * target.h (target_enable_btrace, target_disable_btrace)
3618 (target_read_btrace, target_read_btrace_conf): Turn macro into
3619 inline function. Throw error if target method is not defined.
3620 * server.c (handle_qxfer_btrace handle_qxfer_btrace_conf): Remove
3621 check for btrace target method. Be prepared to handle exceptions
3622 from btrace target methods.
3623
81561546
SDJ
36242018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
3625
3626 * server.c (captured_main): Change order of error message printed
3627 when the current working directory cannot be found.
3628
25e3c82c
SDJ
36292018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
3630
3631 * server.c: Include "filenames.h" and "pathstuff.h".
3632 (program_name): Delete variable.
3633 (program_path): New anonymous class.
3634 (get_exec_wrapper): Use "program_path" instead of
3635 "program_name".
3636 (handle_v_run): Likewise.
3637 (captured_main): Likewise.
3638 (process_serial_event): Likewise.
3639
b4987c95
SDJ
36402018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
3641
3642 * Makefile.in (SFILES): Add "$(srcdir)/common/pathstuff.c".
3643 (OBJS): Add "pathstuff.o".
3644 * server.c (current_directory): New global variable.
3645 (captured_main): Initialize "current_directory".
3646
f46cd62a
AH
36472018-02-26 Alan Hayward <alan.hayward@arm.com>
3648
3649 * tdesc.c: Use common/tdesc.h.
3650 * tdesc.h: Likewise.
3651
a543c5ca
AH
36522018-02-20 Alan Hayward <alan.hayward@arm.com>
3653 Simon Marchi <simon.marchi@ericsson.com>
3654
3655 * Makefile.in: Switch order of make rules.
3656
b5884fa7
AH
36572018-02-19 Alan Hayward <alan.hayward@arm.com>
3658
3659 * Makefile.in: Add common directory in build.
3660 * configure.ac: Add common reference.
3661 * configure: Regenerate.
3662
de6242d3
MM
36632018-02-09 Markus Metzger <markus.t.metzger@intel.com>
3664
3665 * linux-low.c (linux_target_ops): Remove linux_supports_btrace.
3666 * nto-low.c (nto_target_ops): Remove NULL for supports_btrace.
3667 * spu-low.c (spu_target_ops): Likewise.
3668 * win32-low.c (win32_target_ops): Likewise.
3669 * server.c (supported_btrace_packets): Report packets unconditionally.
3670 * target.h (target_ops) <supports_btrace>: Remove.
3671 (target_supports_btrace): Remove.
3672
9ee23a85
MM
36732018-02-09 Markus Metzger <markus.t.metzger@intel.com>
3674
3675 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt)
3676 (handle_btrace_disable): Change return type to void. Use exceptions
3677 to report errors.
3678 (handle_btrace_general_set): Catch exception and copy message to
3679 return message.
3680
8ce47547
TT
36812018-02-08 Tom Tromey <tom@tromey.com>
3682
3683 * linux-low.c (install_software_single_step_breakpoints): Use
3684 make_scoped_restore.
3685 * inferiors.c (make_cleanup_restore_current_thread): Remove.
3686 (do_restore_current_thread_cleanup): Remove.
3687 * gdbthread.h (make_cleanup_restore_current_thread): Don't
3688 declare.
3689
45dd3607
TT
36902018-02-08 Tom Tromey <tom@tromey.com>
3691
3692 * mem-break.c (set_raw_breakpoint_at): Use
3693 gdb::unique_xmalloc_ptr.
3694
e671cd59
PA
36952018-01-30 Pedro Alves <palves@redhat.com>
3696
3697 PR gdb/13211
3698 * target.c (target_terminal::terminal_state): Rename to ...
3699 (target_terminal::m_terminal_state): ... this.
3700
a0aad537
JC
37012018-01-19 James Clarke <jrtc27@jrtc27.com>
3702
3703 * linux-low.c (handle_extended_wait): Surround call to
3704 thread_db_notice_clone with #ifdef USE_THREAD_DB.
3705
4d9b86e1
SM
37062018-01-17 Simon Marchi <simon.marchi@ericsson.com>
3707
3708 * linux-low.c (attach_proc_task_lwp_callback): Adjust to
3709 linux_ptrace_attach_fail_reason_string now returning an
3710 std::string.
3711 (linux_attach): Likewise.
3712 * thread-db.c (attach_thread): Likewise.
3713
f517c180
EA
37142018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
3715
3716 PR gdb/21559
3717 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
3718 checking for fs_base/gs_base fields in struct user_regs_struct.
3719 * configure: Regenerate.
3720
9a70f35c
YQ
37212018-01-16 Yao Qi <yao.qi@linaro.org>
3722
3723 PR gdb/18749
3724 * linux-low.c (fetch_register): Call supply_register instead of
3725 error.
3726
605fd3c6
YQ
37272018-01-08 Yao Qi <yao.qi@linaro.org>
3728 Simon Marchi <simon.marchi@ericsson.com>
3729
3730 * Makefile.in (OBS): Remove selftest.o.
3731 * configure.ac: Set srv_selftest_objs if $development is true.
3732 (GDBSERVER_DEPFILES): Append $srv_selftest_objs.
3733 * configure: Re-generated.
3734 * server.c (captured_main): Wrap variable selftest_filter with
3735 GDB_SELF_TEST.
3736
2cc05030
SM
37372018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
3738
3739 * server.c (parse_debug_format_options): Return std::string.
3740 (handle_monitor_command, captured_main): Adjust.
3741
e379cee6
PA
37422018-01-05 Pedro Alves <palves@redhat.com>
3743
3744 PR gdb/18653
3745 * server.c (captured_main): Pass quiet=false to
3746 save_original_signals_state.
3747
82e1e79a
JB
37482018-01-01 Joel Brobecker <brobecker@adacore.com>
3749
3750 * gdbreplay.c (gdbreplay_version): Update copyright year in
3751 version message.
3752 * server.c (gdbserver_version): Likewise.
3753
8e481c3b
TT
37542017-12-08 Tom Tromey <tom@tromey.com>
3755
3756 * ax.c (ax_printf): Update.
3757
a8806230
YQ
37582017-12-07 Yao Qi <yao.qi@linaro.org>
3759
3760 * linux-aarch64-ipa.c (initialize_low_tracepoint): Call
3761 aarch64_linux_read_description.
3762 * linux-amd64-ipa.c (idx2mask): New array.
3763 (get_ipa_tdesc): Move idx2mask out.
3764 (initialize_low_tracepoint): Initialize target descriptions.
3765 * linux-i386-ipa.c (idx2mask): New array.
3766 (get_ipa_tdesc): Move idx2mask out.
3767 (initialize_low_tracepoint): Initialize target descriptions.
3768
d4a0e8b5
SM
37692017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
3770
3771 * tdesc.c (struct tdesc_type): Change return type.
3772 (tdesc_add_flag): Change parameter type.
3773 (tdesc_add_bitfield): Likewise.
3774 (tdesc_add_field): Likewise.
3775 (tdesc_set_struct_size): Likewise.
3776
798a7429
SM
37772017-12-05 Simon Marchi <simon.marchi@ericsson.com>
3778
3779 * regcache.c (registers_to_string): Remove unused variable.
3780
c0e15c9b
SM
37812017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3782
3783 * inferiors.c (for_each_inferior_with_data): Remove.
3784 * inferiors.h (for_each_inferior_with_data): Remove.
3785 * server.c (handle_qxfer_threads_worker): Change parameter type.
3786 (handle_qxfer_threads_proper): Use for_each_thread.
3787
f0045347
SM
37882017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3789
3790 * inferiors.c (for_each_inferior): Remove.
3791 (clear_inferiors): Use for_each_thread.
3792 * inferiors.h (for_each_inferior): Remove.
3793 * linux-low.c (linux_wait_for_event_filtered): Use
3794 for_each_thread.
3795 (linux_stabilize_threads): Likewise.
3796 * regcache.c (regcache_release): Likewise.
3797 * server.c (gdb_wants_all_threads_stopped): Likewise.
3798 (clear_pending_status_callback): Remove.
3799 (handle_status): Use for_each_thread.
3800 (captured_main): Likewise.
3801 * win32-low.c (child_init_thread_list): Likewise.
3802 (win32_clear_inferiors): Likewise.
3803 (fake_breakpoint_event): Likewise.
3804
9521758b
SM
38052017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3806
3807 * inferiors.h (find_inferior): Remove.
3808 * inferiors.c (find_inferior): Remove.
3809
8f86d7aa
SM
38102017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3811
3812 * linux-low.c (resume_status_pending_p): Update comment.
3813 (need_step_over_p): Update comment.
3814
e2b44075
SM
38152017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3816
3817 * linux-low.c (proceed_one_lwp): Return void, change parameter
3818 type.
3819 (unsuspend_and_proceed_one_lwp): Likewise.
3820 (proceed_all_lwps): Use for_each_thread.
3821 (unstop_all_lwps): Likewise.
3822
c80825ff
SM
38232017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3824
3825 * linux-low.c (linux_resume_one_thread): Return void, take
3826 parameter directly.
3827 (linux_resume): Use for_each_thread.
3828
df3e4dbe
SM
38292017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3830
3831 * linux-low.c (send_sigstop_callback): Return void, change
3832 parameter type. Rename to...
3833 (send_sigstop): ... this.
3834 (suspend_and_send_sigstop_callback): Return void, change parameter
3835 type. Rename to...
3836 (suspend_and_send_sigstop): ... this.
3837 (stop_all_lwps): Use for_each_thread.
3838
5a6b0a41
SM
38392017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3840
3841 * linux-low.c (lwp_running): Return bool, remove unused
3842 argument.
3843 (linux_stabilize_threads): Use find_thread.
3844
39a64da5
SM
38452017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3846
3847 * linux-low.c (select_singlestep_lwp_callback): Remove.
3848 (count_events_callback): Remove.
3849 (select_event_lwp_callback): Remove.
3850 (select_event_lwp): Use find_thread/for_each_thread.
3851
a1385b7b
SM
38522017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3853
3854 * linux-low.c (not_stopped_callback): Return bool, take filter
3855 argument directly.
3856 (linux_wait_for_event_filtered): Use find_thread.
3857 (linux_wait_1): Likewise.
3858
454296a2
SM
38592017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3860
3861 * linux-low.c (same_lwp): Remove.
3862 (find_lwp_pid): Use find_thread.
3863
6b2a85da
SM
38642017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3865
3866 * linux-low.c (delete_lwp_callback): Remove.
3867 (linux_mourn): Use for_each_thread.
3868
798a38e8
SM
38692017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3870
3871 * linux-low.c (linux_detach_lwp_callback): Return void, remove
3872 args parameter, don't check for pid.
3873 (linux_detach): Use for_each_thread.
3874
e4eb0dec
SM
38752017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3876
3877 * linux-low.c (struct counter): Remove.
3878 (second_thread_of_pid_p): Remove.
3879 (last_thread_of_process_p): Use find_thread.
3880
83e1b6c1
SM
38812017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3882
3883 * inferiors.c (find_inferior_in_random): Remove.
3884 * inferiors.h (find_inferior_in_random): Remove.
3885 * linux-low.c (status_pending_p_callback): Return bool, accept
3886 parameter ptid directly.
3887 (linux_wait_for_event_filtered): Use find_thread_in_random.
3888 (linux_wait_1): Likewise.
3889
8dc7b443
SM
38902017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3891
3892 * inferiors.c (find_inferior_id): Remove.
3893 (find_thread_ptid): Move implemention from find_inferior_id to
3894 here.
3895 * inferiors.h (find_inferior_id): Remove.
3896 * server.c (handle_status): Use find_thread_ptid.
3897 (process_serial_event): Likewise.
3898 * thread-db.c (find_one_thread): Likewise.
3899 (thread_db_thread_handle): Likewise.
3900 * win32-low.c (thread_rec): Likewise.
3901 (child_delete_thread): Likewise.
3902 (win32_thread_alive): Likewise.
3903 (get_child_debug_event): Likewise.
3904
da25033c
SM
39052017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3906
3907 * linux-mips-low.c (update_watch_registers_callback): Return
3908 void, remove pid_p parameter, don't check for pid.
3909 (mips_insert_point, mips_remove_point): Use for_each_thread.
3910
c91bb56b
SM
39112017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3912
3913 * lynx.low (lynx_delete_thread_callback): Remove.
3914 (lynx_mourn): Use for_each_thread.
3915
634a3254
SM
39162017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
3917
3918 * regcache.c (regcache_invalidate_one): Remove.
3919 (regcache_invalidate_pid): use for_each_thread.
3920
41272101
TT
39212017-11-26 Tom Tromey <tom@tromey.com>
3922
3923 * linux-low.c (linux_create_inferior): Update.
3924
f5291a6f
UW
39252017-11-24 Ulrich Weigand <uweigand@de.ibm.com>
3926
3927 * spu-low.c (spu_create_inferior): Fix typo in argument name.
3928
6654d750
AH
39292017-11-24 Alan Hayward <alan.hayward@arm.com>
3930
3931 * configure.srv: Add linux-aarch64-tdesc-selftest.o.
3932 * linux-aarch64-low.c (initialize_low_arch): Call init func.
3933 * linux-aarch64-tdesc-selftest.c: New file.
3934 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
3935
39362017-11-24 Alan Hayward <alan.hayward@arm.com>
3937
3938 * configure.srv: Add new file.
3939 * linux-aarch64-low.c (initialize_low_arch): Call init func.
3940 * linux-aarch64-tdesc-selftest.c: New file.
3941 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
3942
49bdb7ee
AH
39432017-11-24 Alan Hayward <alan.hayward@arm.com>
3944
3945 * linux-aarch64-ipa.c (initialize_low_tracepoint): Remove init.
3946 * linux-aarch64-low.c (initialize_low_arch): Remove init.
3947 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add init.
3948
d6d7ce56
AH
39492017-11-24 Alan Hayward <alan.hayward@arm.com>
3950
3951 * configure.srv: Add new files.
3952 * linux-aarch64-ipa.c (get_ipa_tdesc): Call
3953 aarch64_linux_read_description.
3954 * linux-aarch64-low.c (aarch64_linux_read_description):
3955 Merge with aarch64_arch_setup.
3956 (aarch64_arch_setup): Call aarch64_linux_read_description.
3957 * linux-aarch64-tdesc.c: New file.
3958 * linux-aarch64-tdesc.h: New file.
3959
506fe5f4
YQ
39602017-11-24 Yao Qi <yao.qi@linaro.org>
3961
3962 * configure.srv: Set $srv_regobj for tic6x-linux.
3963 * linux-tic6x-low.c: Include "arch/tic6x.h" and "tdesc.h".
3964 (tic6x_read_description): Move some code to tic6x_arch_setup.
3965 (tic6x_tdesc_test): New function.
3966 (initialize_low_arch): Call selftests::register_test.
3967
29f9a567
YQ
39682017-11-22 Yao Qi <yao.qi@linaro.org>
3969
3970 * remote-utils.c (prepare_resume_reply): Use memcpy.
3971
578290ec
SM
39722017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3973
3974 * linux-low.c (kill_one_lwp_callback): Return void, take
3975 argument directly, don't filter on pid.
3976 (linux_kill): Use for_each_thread.
3977
eca55aec
SM
39782017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3979
3980 * linux-low.c (need_step_over_p): Return bool, remove dummy
3981 argument.
3982 (linux_resume, proceed_all_lwps): Use find_thread.
3983
25c28b4d
SM
39842017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3985
3986 * linux-low.c (resume_status_pending_p): Return bool, remove
3987 flag_p argument.
3988 (linux_resume): Use find_thread.
3989
5fdda392
SM
39902017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3991
3992 * linux-low.c (struct thread_resume_array): Remove.
3993 (linux_set_resume_request): Return void, take arguments
3994 directly.
3995 (linux_resume): Use for_each_thread.
3996
fcb056a5
SM
39972017-11-19 Simon Marchi <simon.marchi@ericsson.com>
3998
3999 * linux-low.c (stuck_in_jump_pad_callback): Change prototype,
4000 return bool, remove data argument.
4001 (linux_stabilize_threads): Use find_thread.
4002
139720c5
SM
40032017-11-19 Simon Marchi <simon.marchi@ericsson.com>
4004
4005 * linux-low.c (unsuspend_one_lwp): Remove.
4006 (unsuspend_all_lwps): Use for_each_thread, inline code from
4007 unsuspend_one_lwp.
4008
6d1e5673
SM
40092017-11-19 Simon Marchi <simon.marchi@ericsson.com>
4010
4011 * gdbthread.h (find_thread): Add overload with ptid_t filter.
4012 * linux-low.c (struct iterate_over_lwps_args): Remove.
4013 (iterate_over_lwps_filter): Remove.
4014 (iterate_over_lwps): Use find_thread.
4015
bbf550d5
SM
40162017-11-19 Simon Marchi <simon.marchi@ericsson.com>
4017
4018 * linux-low.c (reset_lwp_ptrace_options_callback): Remove.
4019 (linux_handle_new_gdb_connection): Use for_each_thread, inline
4020 code from reset_lwp_ptrace_options_callback.
4021
00192f77
SM
40222017-11-19 Simon Marchi <simon.marchi@ericsson.com>
4023
4024 * linux-arm-low.c (struct update_registers_data): Remove.
4025 (update_registers_callback): Return void, take arguments
4026 directly, don't check thread's pid.
4027 (arm_insert_point, arm_remove_point): Use for_each_thread.
4028
2bee2b6c
SM
40292017-11-19 Simon Marchi <simon.marchi@ericsson.com>
4030
4031 * win32-low.c (continue_one_thread): Return void, take argument
4032 directly.
4033 (child_continue): Use for_each_thread.
4034
0b360f19
SM
40352017-11-19 Simon Marchi <simon.marchi@ericsson.com>
4036
4037 * win32-i386-low.c (update_debug_registers_callback): Rename
4038 to ...
4039 (update_debug_registers): ... this, return void, remove pid_p arg.
4040 (x86_dr_low_set_addr, x86_dr_low_set_control): Use for_each_thread.
4041
f27866ba
SM
40422017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
4043
4044 * inferiors.h (struct process_info): Add constructor, initialize
4045 fields..
4046 <syscalls_to_catch>: Change type to std::vector<int>.
4047 * inferiors.c (add_process): Allocate process_info with new.
4048 (remove_process): Free process_info with delete.
4049 * linux-low.c (handle_extended_wait): Adjust.
4050 (gdb_catching_syscalls_p, gdb_catch_this_syscall_p): Adjust.
4051 * server.c (handle_general_set): Adjust.
4052
e849ea89
PA
40532017-11-16 Pedro Alves <palves@redhat.com>
4054
4055 * remote-utils.c (remote_close): Block SIGIO signals instead of
4056 uninstalling the SIGIO handler.
4057
1d0aa65c
AH
40582017-11-16 Alan Hayward <alan.hayward@arm.com>
4059
4060 * tdesc.c (tdesc_get_features_xml): Allow null osabi.
4061
3491a34c
YQ
40622017-11-16 Yao Qi <yao.qi@linaro.org>
4063
4064 * linux-tic6x-low.c (tic6x_fill_gregset): Cast buf.
4065 (tic6x_store_gregset): Likewise.
4066 (tic6x_usrregs_info): Move it up.
4067
a602f924
AH
40682017-11-15 Alan Hayward <alan.hayward@arm.com>
4069
4070 * Makefile.in: Update arch rules.
4071 * configure.srv: Explicitly mark arch/ files.
4072
5616b6c3
AS
40732017-11-13 Andreas Schwab <schwab@suse.de>
4074
4075 * linux-m68k-low.c (m68k_supports_hardware_single_step): New
4076 function.
4077 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4078
d1928160
PA
40792017-11-06 Pedro Alves <palves@redhat.com>
4080
4081 * config.in, configure: Regenerate.
4082
bac608e7
SM
40832017-10-27 Simon Marchi <simon.marchi@ericsson.com>
4084
4085 * target.c (struct thread_search): Remove.
4086 (thread_search_callback): Remove.
4087 (prepare_to_access_memory): Use for_each_thread instead of
4088 find_inferior. Inline code from thread_search_callback.
4089
eaddb425
SM
40902017-10-27 Simon Marchi <simon.marchi@ericsson.com>
4091
4092 * server.c (struct visit_actioned_threads_data): Remove.
4093 (visit_actioned_threads): Change prototype to take arguments
4094 directly.
4095 (resume): Use find_thread instead of find_inferior.
4096
99078d34
SM
40972017-10-27 Simon Marchi <simon.marchi@ericsson.com>
4098
4099 * server.c (queue_stop_reply_callback): Change prototype, return
4100 void.
4101 (find_status_pending_thread_callback): Remove.
4102 (handle_status): Replace find_inferior with find_thread and
4103 for_each_thread.
4104
cc628f3d
AH
41052017-10-25 Alan Hayward <alan.hayward@arm.com>
4106
4107 * linux-aarch64-low.c (aarch64_fill_gregset): Replace defines
4108 with REGNO.
4109 (aarch64_store_gregset): Likewise.
4110 (aarch64_fill_fpregset): Likewise.
4111 (aarch64_store_fpregset): Likewise.
4112
4d3bb80e
SM
41132017-10-21 Simon Marchi <simon.marchi@ericsson.com>
4114
4115 * gdbthread.h (find_thread, for_each_thread): New functions.
4116 * inferiors.c (thread_of_pid): Remove.
4117 (find_any_thread_of_pid): Use find_thread.
4118 * linux-low.c (num_lwps): Use for_each_thread.
4119
7a7cdfa0
YQ
41202017-10-17 Yao Qi <yao.qi@linaro.org>
4121
4122 * Makefile.in: Remove one rule.
4123 * configure.srv: Rename aarch64-insn.o with arch/aarch64-insn.o.
4124
e675d170
YQ
41252017-10-17 Yao Qi <yao.qi@linaro.org>
4126
4127 * configure.srv: Rename arm-linux.o with arch/arm-linux.o.
4128 Rename arm-get-next-pcs.o with arch/arm-get-next-pcs.o.
4129
7eb4e0f9
YQ
41302017-10-17 Yao Qi <yao.qi@linaro.org>
4131
4132 * configure.srv: Rename arm.o with arch/arm.o.
4133
60d6cfc9
YQ
41342017-10-17 Yao Qi <yao.qi@linaro.org>
4135
4136 * Makefile.in (CONFIG_SRC_SUBDIR): New variable.
4137 (clean): Remove .o files in CONFIG_SRC_SUBDIR.
4138 (distclean): Remove DEPDIR in CONFIG_SRC_SUBDIR.
4139 (arch-i386.o, arch-amd64.o): Remove rules.
4140 (arch/%.o): New rule.
4141 Update POSTCOMPILE and COMPILE.pre.
4142 * configure.ac: Invoke AC_CONFIG_COMMANDS.
4143 * configure: Re-generated.
4144 * configure.srv: Replace arch-i386.o with arch/i386.o.
4145 Replace arch-amd64.o with arch/amd64.o.
4146
5bfda255
YQ
41472017-10-16 Yao Qi <yao.qi@linaro.org>
4148
4149 * configure: Regenerated.
4150
9c80ecd6
SM
41512017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
4152
4153 * inferiors.h: (struct inferior_list): Remove.
4154 (struct inferior_list_entry); Remove.
4155 (add_inferior_to_list, clear_inferior_list, one_inferior_p,
4156 A_I_NEXT, ALL_INFERIORS_TYPE, ALL_INFERIORS, remove_inferior,
4157 get_first_inferior): Remove.
4158 (for_each_inferior, for_each_inferior_with_data, find_inferior,
4159 find_inferior_id, find_inferior_in_random): Change signature.
4160 * inferiors.c (all_threads): Change type to
4161 std::list<thread_info *>.
4162 (get_thread): Remove macro.
4163 (find_inferior, find_inferior_id): Change signature, implement
4164 using find_thread.
4165 (find_inferior_in_random): Change signature, implement using
4166 find_thread_in_random.
4167 (for_each_inferior, for_each_inferior_with_data): Change
4168 signature, implement using for_each_thread.
4169 (add_inferior_to_list, remove_inferior): Remove.
4170 (add_thread, get_first_thread, thread_of_pid,
4171 find_any_thread_of_pid, free_one_thread, remove_thread): Update.
4172 (get_first_inferior, one_inferior_p, clear_inferior_list):
4173 Remove.
4174 (clear_inferiors, get_thread_process): Update.
4175 * gdbthread.h: Include <list>.
4176 (struct thread_info) <entry>: Remove field.
4177 <id>: New field.
4178 (all_threads): Change type to std::list<thread_info *>.
4179 (get_first_inferior): Add doc.
4180 (find_thread, for_each_thread, find_thread_in_random): New
4181 functions.
4182 (current_ptid, pid_of, ptid_of, lwpid_of): Update.
4183 * linux-arm-low.c (update_registers_callback): Update.
4184 * linux-low.c (second_thread_of_pid_p): Update.
4185 (kill_one_lwp_callback, linux_detach_lwp_callback,
4186 delete_lwp_callback, status_pending_p_callback, same_lwp,
4187 find_lwp_pid, num_lwps, iterate_over_lwps_filter,
4188 iterate_over_lwps, not_stopped_callback,
4189 resume_stopped_resumed_lwps, count_events_callback,
4190 select_singlestep_lwp_callback, select_event_lwp_callback,
4191 unsuspend_one_lwp, linux_wait_1, send_sigstop_callback,
4192 suspend_and_send_sigstop_callback, wait_for_sigstop,
4193 stuck_in_jump_pad_callback, move_out_of_jump_pad_callback,
4194 lwp_running, linux_set_resume_request, resume_status_pending_p,
4195 need_step_over_p, start_step_over, linux_resume_one_thread,
4196 proceed_one_lwp, unsuspend_and_proceed_one_lwp,
4197 reset_lwp_ptrace_options_callback): Update.
4198 * linux-mips-low.c (update_watch_registers_callback): Update.
4199 * regcache.c (regcache_invalidate_one, regcache_invalidate):
4200 Update.
4201 (free_register_cache_thread_one): Remove.
4202 (regcache_release): Update.
4203 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt,
4204 handle_qxfer_threads_worker): Update.
4205 (handle_query): Update, use list iterator.
4206 (visit_actioned_threads, handle_pending_status,
4207 queue_stop_reply_callback, gdb_wants_all_threads_stopped,
4208 clear_pending_status_callback, set_pending_status_callback,
4209 find_status_pending_thread_callback, handle_status,
4210 process_serial_event): Update.
4211 * target.c (thread_search_callback): Update.
4212 * thread-db.c (thread_db_get_tls_address): Update.
4213 * tracepoint.c (tracepoint_finished_step, tracepoint_was_hit):
4214 Update.
4215 * win32-i386-low.c (update_debug_registers_callback): Update.
4216 * win32-low.c (delete_thread_info, child_delete_thread,
4217 continue_one_thread, suspend_one_thread,
4218 get_child_debug_event): Adjust.
4219
9179355e
SM
42202017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
4221
4222 * gdbthread.h (ptid_of, pid_of, lwpid_of): New functions.
4223 * inferiors.h: Include <list>.
4224 (struct process_info) <entry>: Remove field.
4225 <pid>: New field.
4226 (pid_of): Change macro to function.
4227 (ptid_of, lwpid_of): Remove macro.
4228 (all_processes): Change type to std::list<process_info *>.
4229 (ALL_PROCESSES): Remove macro.
4230 (for_each_process, find_process): New function.
4231 * inferiors.c (all_processes): Change type to
4232 std::list<process_info *>.
4233 (find_thread_process): Adjust.
4234 (add_process): Likewise.
4235 (remove_process): Likewise.
4236 (find_process_pid): Likewise.
4237 (get_first_process): Likewise.
4238 (started_inferior_callback): Remove.
4239 (have_started_inferiors_p): Adjust.
4240 (attached_inferior_callback): Remove.
4241 (have_attached_inferiors_p): Adjust.
4242 * linux-low.c (check_zombie_leaders): Likewise.
4243 * linux-x86-low.c (x86_arch_setup_process_callback): Remove.
4244 (x86_linux_update_xmltarget): Adjust.
4245 * server.c (handle_query): Likewise.
4246 (gdb_reattached_process): Remove.
4247 (handle_status): Adjust.
4248 (kill_inferior_callback): Likewise.
4249 (detach_or_kill_inferior): Remove.
4250 (print_started_pid): Likewise.
4251 (print_attached_pid): Likewise.
4252 (detach_or_kill_for_exit): Update.
4253 (process_serial_event): Likewise.
4254 * linux-arm-low.c (arm_new_fork): Likewise.
4255
c9cb8905
SM
42562017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
4257
4258 * dll.h: Include <list>.
4259 (struct dll_info): Add constructor.
4260 <entry>: Remove field.
4261 (all_dlls): Change type to std::list<dll_info>.
4262 * dll.c: Include <algorithm>.
4263 (get_dll): Remove macro.
4264 (all_dlls): Change type to std::list<dll_info *>.
4265 (free_one_dll): Remove.
4266 (match_dll): Likewise.
4267 (loaded_dll): Adjust.
4268 (unloaded_dll): Adjust to all_dlls type change, use
4269 std::find_if. Inline code from match_dll.
4270 (clear_dlls): Adjust to all_dlls type change.
4271 * server.c (emit_dll_description): Remove.
4272 (handle_qxfer_libraries): Adjust to all_dlls type change,
4273 integrate emit_dll_description's functionality.
4274
04ec7890
SM
42752017-10-12 Simon Marchi <simon.marchi@ericsson.com>
4276
4277 * linux-low.h (struct linux_target_ops) <delete_process>: New
4278 field.
4279 * linux-low.c (linux_mourn): Call the_low_target.delete_process.
4280 * linux-aarch64-low.c (aarch64_linux_delete_process): New.
4281 (struct linux_target_ops): Add delete_process callback.
4282 * linux-arm-low.c (arm_delete_process): New.
4283 (struct linux_target_ops): Add delete_process callback.
4284 * linux-bfin-low.c (struct linux_target_ops): Likewise.
4285 * linux-crisv32-low.c (struct linux_target_ops): Likewise.
4286 * linux-m32r-low.c (struct linux_target_ops): Likewise.
4287 * linux-mips-low.c (mips_linux_delete_process): New.
4288 (struct linux_target_ops): Add delete_process callback.
4289 * linux-ppc-low.c (struct linux_target_ops): Likewise.
4290 * linux-s390-low.c (struct linux_target_ops): Likewise.
4291 * linux-sh-low.c (struct linux_target_ops): Likewise.
4292 * linux-tic6x-low.c (struct linux_target_ops): Likewise.
4293 * linux-tile-low.c (struct linux_target_ops): Likewise.
4294 * linux-x86-low.c (x86_linux_delete_process): New.
4295 (struct linux_target_ops): Add delete_process callback.
4296 * linux-xtensa-low.c (struct linux_target_ops): Likewise.
4297
466eecee
SM
42982017-10-12 Simon Marchi <simon.marchi@ericsson.com>
4299
4300 * linux-aarch64-low.c (the_low_target): Add thread delete
4301 callback.
4302 * linux-arm-low.c (arm_delete_thread): New function.
4303 (the_low_target): Add thread delete callback.
4304 * linux-bfin-low.c (the_low_target): Likewise.
4305 * linux-crisv32-low.c (the_low_target): Likewise.
4306 * linux-low.c (delete_lwp): Invoke delete_thread callback if
4307 set.
4308 * linux-low.h (struct linux_target_ops) <delete_thread>: New
4309 field.
4310 * linux-m32r-low.c (the_low_target): Add thread delete callback.
4311 * linux-mips-low.c (mips_linux_delete_thread): New function.
4312 (the_low_target): Add thread delete callback.
4313 * linux-ppc-low.c (the_low_target): Likewise.
4314 * linux-s390-low.c (the_low_target): Likewise.
4315 * linux-sh-low.c (the_low_target): Likewise.
4316 * linux-tic6x-low.c (the_low_target): Likewise.
4317 * linux-tile-low.c (the_low_target): Likewise.
4318 * linux-x86-low.c (the_low_target): Likewise.
4319 * linux-xtensa-low.c (the_low_target): Likewise.
4320
b79f7801
YZ
43212017-10-06 Yuanhui Zhang <asmwarrior@gmail.com>
4322
4323 * win32-low.c: Include "common-inferior.h".
4324
bc3b087d
SDJ
43252017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
4326
4327 * inferiors.c (set_inferior_cwd): New function.
4328 * server.c (handle_general_set): Handle QSetWorkingDir packet.
4329 (handle_query): Inform that QSetWorkingDir is supported.
4330 * win32-low.c (create_process): Pass the inferior's cwd to
4331 CreateProcess.
4332
d092c5a2
SDJ
43332017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
4334
4335 * inferiors.c (current_inferior_cwd): New global variable.
4336 (get_inferior_cwd): New function.
4337 * inferiors.h (struct process_info) <cwd>: New field.
4338
7da0a886
SDJ
43392017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
4340
4341 * Makefile.in (SFILES): Add $(srcdir)/common/gdb_tilde_expand.c.
4342 (OBS): Add gdb_tilde_expand.o.
4343
289a6840
SM
43442017-10-02 Simon Marchi <simon.marchi@ericsson.com>
4345
4346 * lynx-i386-low.c (lynx_i386_arch_setup): Call init_target_desc.
4347 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
4348
256642e8
PA
43492017-09-29 Pedro Alves <palves@redhat.com>
4350
4351 * ax.c (gdb_parse_agent_expr): Constify.
4352 * ax.h (gdb_parse_agent_expr): Constify.
4353 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
4354 Constify.
4355 * mem-break.h (add_breakpoint_condition, add_breakpoint_commands): Constify.
4356 * remote-utils.c (hex_or_minus_one, read_ptid): Constify.
4357 * remote-utils.h (read_ptid): Constify.
4358 * server.c (handle_qxfer_exec_file, handle_query, handle_v_cont)
4359 (process_point_options, process_serial_event): Constify.
4360 * tracepoint.c (add_tracepoint_action, cmd_qtdp, cmd_qtdpsrc)
4361 (cmd_qtdv, cmd_qtenable_disable, cmd_qtro, cmd_qtframe, cmd_qtp)
4362 (cmd_qtbuffer): Constify.
4363
5b9ca4d4
PA
43642017-09-29 Pedro Alves <palves@redhat.com>
4365
4366 * proc-service.c (ps_pdread): Return PS_ERR if reading memory
4367 fails.
4368
94c207e0
PA
43692017-09-29 Pedro Alves <palves@redhat.com>
4370
4371 * linux-low.c (handle_extended_wait): Pass parent thread instead
4372 of process to thread_db_notice_clone.
4373 * linux-low.h (thread_db_notice_clone): Replace parent process
4374 parameter with parent thread parameter.
4375 * thread-db.c (find_one_thread): Add comment.
4376 (thread_db_notice_clone): Replace parent process parameter with
4377 parent thread parameter. Temporarily switch to the parent thread.
4378
75352e28
SDJ
43792017-09-26 Sergio Durigan Junior <sergiodj@redhat.com>
4380
4381 * gdbthread.h: Include "common-gdbthread.h".
4382 * inferiors.c (switch_to_thread): Use "gdb_assert" instead of
4383 "if" when validating the ptid.
4384 * remote-utils.c: Include "gdbthread.h".
4385 (prepare_resume_reply): Use "switch_to_thread".
4386 * target.c (done_accessing_memory): Likewise.
4387
ad339634
AA
43882017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
4389
4390 * configure.srv (s390*-*-linux*): Add s390-gs-linux64.o and
4391 s390x-gs-linux64.o to srv_regobj. Add s390-gs-linux64.xml,
4392 s390x-gs-linux64.xml, s390-gs.xml, and s390-gsbc.xml to
4393 srv_xmlfiles. Add s390-gs-linux64-ipa.o and
4394 s390x-gs-linux64-ipa.o to ipa_obj.
4395 * linux-s390-low.c (HWCAP_S390_GS): New define.
4396 (s390_fill_gs, s390_store_gs, s390_fill_gsbc, s390_store_gsbc):
4397 New functions.
4398 (s390_regsets): Add regsets for NT_S390_GS_CB and NT_S390_GS_BC.
4399 (s390_arch_setup): Check for guarded-storage support and choose
4400 appropriate tdesc.
4401 (initialize_low_arch): Invoke init_registers_s390_gs_linux64 and
4402 init_registers_s390x_gs_linux64.
4403 * linux-s390-tdesc.h (enum s390_linux_tdesc) <S390_TDESC_GS>: New
4404 enum value.
4405 (init_registers_s390x_gs_linux64, tdesc_s390x_gs_linux64)
4406 (init_registers_s390_gs_linux64, tdesc_s390_gs_linux64): Declare.
4407
cc4d742f
SM
44082017-09-22 Simon Marchi <simon.marchi@ericsson.com>
4409
4410 * win32-i386-low.c (i386_arch_setup): Call init_target_desc.
4411
f6327dcb
KB
44122017-09-21 Kevin Buettner <kevinb@redhat.com>
4413
4414 * linux-low.h (struct lwp_info): Add new field, thread_handle.
4415 (thread_db_thread_handle): Declare.
4416 * linux-low.c (linux_target_ops): Initialize thread_handle.
4417 * server.c (handle_qxfer_threads_worker): Add support for
4418 "handle" attribute.
4419 * target.h (struct target_ops): Add new function pointer,
4420 thread_handle.
4421 (target_thread_handle): Define.
4422 * thread-db.c (find_one_thread, attach_thread): Set thread_handle
4423 field in lwp.
4424 (thread_db_thread_handle): New function.
4425
86299109
KB
44262017-09-21 Kevin Buettner <kevinb@redhat.com>
4427
4428 * linux-low.c (handle_extended_wait): Call thread_db_notice_clone().
4429 * linux-low.h (thread_db_notice_clone): Declare.
4430 * thread-db.c (thread_db_notice_clone): New function.
4431
f557a88a
PA
44322017-09-21 Pedro Alves <palves@redhat.com>
4433
4434 * server.c (gdb_read_memory, handle_status, process_serial_event)
4435 (handle_serial_event, handle_target_event): Adjust to
4436 set_desired_thread prototype change.
4437 * target.c (set_desired_thread): Remove 'use_general' parameter
4438 and adjust.
4439 * target.h (set_desired_thread): Remove 'use_general' parameter.
4440
223ffa71
TT
44412017-09-20 Tom Tromey <tom@tromey.com>
4442
4443 * target.c (target_terminal::terminal_state): Define.
4444 (target_terminal::init): Rename from target_terminal_init.
4445 (target_terminal::inferior): Rename from
4446 target_terminal_inferior.
4447 (target_terminal::ours): Rename from target_terminal_ours.
4448 (target_terminal::ours_for_output, target_terminal::info): New.
4449
04fd3ba9
SM
44502017-09-16 Simon Marchi <simon.marchi@ericsson.com>
4451
4452 * server.c (accumulate_file_name_length): Remove.
4453 (emit_dll_description): Adjust to std::string change.
4454 (handle_qxfer_libraries): Use std::string to hold document.
4455
5e187554
SM
44562017-09-16 Simon Marchi <simon.marchi@ericsson.com>
4457
4458 * linux-low.c (linux_qxfer_libraries_svr4): Adjust to change of
4459 return type of xml_escape_text.
4460 * server.c (emit_dll_description): Likewise.
4461
1526853e
SM
44622017-09-16 Simon Marchi <simon.marchi@ericsson.com>
4463
4464 * server.c (captured_main): Accept argument for --selftest.
4465 Update run_tests call.
4466 * linux-x86-tdesc-selftest.c (initialize_low_tdesc): Add names
4467 when registering selftests.
4468
c4dfafab
SDJ
44692017-09-16 Sergio Durigan Junior <sergiodj@redhat.com>
4470
4471 * regcache.c (get_thread_regcache): Update code to use "std::vector"
4472 instead of "VEC" for "target_desc.reg_defs".
4473 (regcache_cpy): Likewise.
4474 (registers_to_string): Likewise.
4475 (registers_from_string): Likewise.
4476 (find_regno): Likewise.
4477 (supply_regblock): Likewise.
4478 (regcache_raw_read_unsigned): Likewise.
4479 * tdesc.c (init_target_desc): Likewise.
4480 (tdesc_create_reg): Likewise.
4481 * tdesc.h: Remove declaration of "tdesc_reg_p". Include <vector>.
4482 (struct target_desc) <reg_defs>: Convert to "std::vector".
4483 (target_desc): Do not initialize "reg_defs".
4484 (~target_desc): Update code to use "std::vector" instead of "VEC"
4485 for "target_desc.reg_defs".
4486 (operator==): Likewise.
4487
124aceb4
SM
44882017-09-15 Simon Marchi <simon.marchi@ericsson.com>
4489
4490 * inferiors.h (thread_to_gdb_id): Remove.
4491 * inferiors.c (thread_to_gdb_id): Remove.
4492 * server.c (handle_qxfer_threads_worker, handle_query): Adjust.
4493 * lynx-low.c (lynx_resume, lynx_wait_1, lynx_fetch_registers,
4494 lynx_store_registers, lynx_read_memory, lynx_write_memory):
4495 Likewise.
4496 * nto-low.c (nto_fetch_registers, nto_store_registers,
4497 nto_stopped_by_watchpoint, nto_stopped_data_address): Likewise.
4498
96cde54f
SM
44992017-09-15 Simon Marchi <simon.marchi@ericsson.com>
4500
4501 * inferiors.h (gdb_id_to_thread_id): Remove.
4502 * inferiors.c (gdb_id_to_thread_id): Remove.
4503 * server.c (process_serial_event): Adjust to gdb_id_to_thread_id
4504 removal. Move pid declaration closer to where it's used.
4505
e8ca139e
SM
45062017-09-15 Simon Marchi <simon.marchi@ericsson.com>
4507
4508 * server.c (handle_detach): New function.
4509 (process_serial_event): Move code out, call handle_detach.
4510
f8a4e119
SM
45112017-09-15 Simon Marchi <simon.marchi@ericsson.com>
4512
4513 * server.c (require_running): Rename to ...
4514 (require_running_or_return): ... this ...
4515 (require_running_or_break): ... and this.
4516 (handle_query, process_serial_event): Adjust.
4517
0eb0a407
SM
45182017-09-15 Simon Marchi <simon.marchi@ericsson.com>
4519
4520 * linux-low.c (linux_set_resume_request): Remove unused
4521 variables.
4522
785922a5
SM
45232017-09-15 Simon Marchi <simon.marchi@ericsson.com>
4524
4525 * server.c (first_thread_of): Remove.
4526 (process_serial_event): Replace usage of first_thread_of with
4527 find_any_thread_of_pid.
4528 * tracepoint.c (same_process_p): Remove.
4529 (gdb_agent_about_to_close): Replace usage of same_process_p with
4530 find_any_thread_of_pid.
4531 * linux-x86-low.c (same_process_callback): Remove.
4532 (x86_arch_setup_process_callback): Replace usage of
4533 same_process_callback with find_any_thread_of_pid.
4534 * thread-db.c (any_thread_of): Remove.
4535 (switch_to_process): Replace usage of any_thread_of with
4536 find_any_thread_of_pid.
4537 * inferiors.c (thread_pid_matches_callback): Remove.
4538 (find_thread_process): Adjust to use find_any_thread_of_pid.
4539
a059f00c
SDJ
45402017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
4541
4542 * regcache.c (get_thread_regcache): Guard calls to "memset"
e79be6e5 4543 with "!VEC_empty".
a059f00c 4544
cc397f3a
SDJ
45452017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
4546
4547 * linux-low.c (handle_extended_wait): Use
4548 "allocate_target_description" instead of "XNEW".
4549 * linux-x86-low.c (initialize_low_arch): Likewise.
4550
22916b07
YQ
45512017-09-05 Yao Qi <yao.qi@linaro.org>
4552
4553 * configure.srv (srv_i386_regobj): Remove.
4554 (srv_amd64_regobj): Remove.
4555 (srv_regobj): Set it to "" for x86 non-linux targets.
4556 * linux-x86-tdesc.c (i386_linux_read_description):
4557 * lynx-i386-low.c: Include x86-xstate.h and arch/i386.h.
4558 (init_registers_i386): Remove the declaration.
4559 (tdesc_i386): Remove the declaration.
4560 (lynx_i386_arch_setup): Call i386_create_target_description.
4561 * nto-x86-low.c: Likewise.
4562 * win32-i386-low.c [__x86_64__]: include arch/amd64.h.
4563 [!__x86_64__]: include arch/i386.h.
4564 (i386_arch_setup) [__x86_64__]: Call amd64_create_target_description.
4565
38602d55
YQ
45662017-09-05 Yao Qi <yao.qi@linaro.org>
4567
4568 * configure.srv (srv_amd64_linux_xmlfiles): Remove
4569 i386/amd64-XXX-linux from it.
4570
44b886ff
YQ
45712017-09-05 Yao Qi <yao.qi@linaro.org>
4572
4573 * configure.srv: Empty srv_amd64_linux_regobj if $development is
4574 false.
4575 (ipa_amd64_linux_regobj): Remove.
4576 (ipa_x32_linux_regobj): Remove.
4577
b4570e4b
YQ
45782017-09-05 Yao Qi <yao.qi@linaro.org>
4579
4580 * Makefile.in (arch-amd64.o): New rule.
4581 * configure.srv: Append arch-amd64.o.
4582 * linux-amd64-ipa.c: Include common/x86-xstate.h.
4583 (get_ipa_tdesc): Call amd64_linux_read_description.
4584 (initialize_low_tracepoint): Don't call init_registers_x32_XXX
4585 and init_registers_amd64_XXX.
4586 * linux-x86-low.c (x86_linux_read_description): Call
4587 amd64_linux_read_description.
4588 (x86_get_ipa_tdesc_idx): Call amd64_get_ipa_tdesc_idx.
4589 (initialize_low_arch): Don't call init_registers_x32_XXX and
4590 init_registers_amd64_XXX.
4591 * linux-x86-tdesc-selftest.c: Declare init_registers_amd64_XXX
4592 and tdesc_amd64_XXX.
4593 [__x86_64__] (amd64_tdesc_test): New function.
4594 (initialize_low_tdesc) [__x86_64__]: Call init_registers_x32_XXX
4595 and init_registers_amd64_XXX.
4596 * linux-x86-tdesc.c: Include arch/amd64.h.
4597 (xcr0_to_tdesc_idx): New function.
4598 (i386_linux_read_description): New function.
4599 (amd64_get_ipa_tdesc_idx): New function.
4600 * linux-x86-tdesc.h (amd64_get_ipa_tdesc_idx): Declare.
4601 (amd64_get_ipa_tdesc): Declare.
4602
d1f28ea2
YQ
46032017-09-05 Yao Qi <yao.qi@linaro.org>
4604
4605 * configure.srv (srv_i386_linux_xmlfiles): Remove
4606 i386/i386-XXX-linux.xml from it.
4607
25a93583
YQ
46082017-09-05 Yao Qi <yao.qi@linaro.org>
4609
4610 * configure.srv: Set srv_i386_linux_regobj empty if $development
4611 is false.
4612 * linux-i386-ipa.c (initialize_low_tracepoint): Don't call
4613 initialize_low_tdesc.
4614 * linux-x86-low.c (initialize_low_arch): Wrap initialize_low_tdesc
4615 with #if initialize_low_tdesc.
4616 * linux-x86-tdesc-selftest.c: New file.
4617 * linux-x86-tdesc.c: Move code to linux-x86-tdesc-selftest.c.
4618
5f035c07
YQ
46192017-09-05 Yao Qi <yao.qi@linaro.org>
4620
4621 * Makefile.in (arch-i386.o): New rule.
4622 * configure.srv (i[34567]86-*-linux*): Add arch-i386.o.
4623 (x86_64-*-linux*): Likewise.
4624 * linux-x86-tdesc.c: Don't include ../features/i386/32bit-XXX.c,
4625 include arch/i386.h.
4626 (i386_linux_read_description): Remove code and call
4627 i386_create_target_description.
4628 * tdesc.c (allocate_target_description): New function.
4629 * tdesc.h (set_tdesc_architecture): Remove declaration.
4630 (set_tdesc_osabi): Likewise.
4631
0abe8a89
YQ
46322017-09-05 Yao Qi <yao.qi@linaro.org>
4633
4634 * linux-x86-tdesc.c: Don't include <inttypes.h>.
4635 (i386_linux_read_description) [!IN_PROCESS_AGENT]: Call
4636 set_tdesc_architecture and set_tdesc_osabi. Remove code setting
4637 .xmltarget.
4638 * server.c (get_features_xml): Call tdesc_get_features_xml.
4639 * tdesc.c (set_tdesc_architecture): New function.
4640 (set_tdesc_osabi): New function.
4641 (tdesc_get_features_xml): New function.
4642 (tdesc_create_feature): Add an argument.
4643 * tdesc.h (struct target_desc) <features>: New field.
4644 <arch, osabi>: New field.
4645 (~target_desc): xfree features, arch, and osabi.
4646 (target_desc::oerator==): Don't compare .xmltarget.
4647 [!IN_PROCESS_AGENT] (set_tdesc_architecture): Declare.
4648 (set_tdesc_osabi): Likewise.
4649 (tdesc_get_features_xml): Likewise.
4650
0a188386
YQ
46512017-09-05 Yao Qi <yao.qi@linaro.org>
4652
4653 * linux-x86-tdesc.c: Include selftest.h.
4654 (i386_tdesc_test): New function.
4655 (initialize_low_tdesc): Call selftests::register_test.
4656 * tdesc.h: Include regdef.h.
4657 (target_desc): Override operator == and !=.
4658
f49ff000
YQ
46592017-09-05 Yao Qi <yao.qi@linaro.org>
4660
4661 * configure.srv (srv_tgtobj): Append linux-x86-tdesc.o.
4662 (ipa_obj): Likewise.
4663 * linux-i386-ipa.c: Include common/x86-xstate.h
4664 (get_ipa_tdesc): Call i386_linux_read_description.
4665 (initialize_low_tracepoint): Don't call init_registers_XXX
4666 functions, call initialize_low_tdesc instead.
4667 * linux-x86-low.c (x86_linux_read_description): Call
4668 i386_linux_read_description.
4669 (initialize_low_arch): Don't call init_registers_i386_XXX
4670 functions, call initialize_low_tdesc.
4671 * linux-x86-tdesc.c: New file.
4672 * linux-x86-tdesc.h (x86_linux_tdesc): New X86_TDESC_LAST.
4673 (i386_get_ipa_tdesc_idx): Declare.
4674 (i386_get_ipa_tdesc): Declare.
4675 (initialize_low_tdesc): Declare.
4676
2b68ef2f
YQ
46772017-09-05 Yao Qi <yao.qi@linaro.org>
4678
4679 * linux-x86-low.c (x86_get_ipa_tdesc_idx): Use X86_TDESC_MMX
4680 instead of 0.
4681
f7000548
YQ
46822017-09-05 Yao Qi <yao.qi@linaro.org>
4683
4684 * Makefile.in (IPA_OBJS): Add vec-ipa.o
4685 * regcache.c (get_thread_regcache): Use VEC_length.
4686 (init_register_cache): Likewise.
4687 (regcache_cpy): Likewise.
4688 (registers_to_string): Iterate reg_defs via VEC_iterate.
4689 (find_regno): Likewise.
4690 (find_register_by_number): Use VEC_index.
4691 (register_size): Call find_register_by_number.
4692 (register_data): Call find_register_by_number.
4693 (supply_regblock): Use VEC_length.
4694 (regcache_raw_read_unsigned): Likewise.
4695 * tdesc.c (init_target_desc): Iterate reg_defs via
4696 VEC_iterate.
4697 (default_description): Update initializer.
4698 (copy_target_description): Don't update field num_registers.
4699 * tdesc.h (struct target_desc) <reg_defs>: Change it to VEC.
4700 <num_registers>: Remove.
4701
50a421ac
SM
47022017-09-04 Simon Marchi <simon.marchi@ericsson.com>
4703
4704 * Makefile.in (.SECONDARY): Define target.
4705
23fdd69e
SM
47062017-09-03 Simon Marchi <simon.marchi@ericsson.com>
4707
4708 * linux-low.c (linux_wait_1): Adjust.
4709 * server.c (queue_stop_reply_callback): Adjust.
4710
0a2dde4a
SDJ
47112017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
4712
4713 * server.c (handle_general_set): Handle QEnvironmentHexEncoded,
4714 QEnvironmentUnset and QEnvironmentReset packets.
4715 (handle_query): Inform remote that QEnvironmentHexEncoded,
4716 QEnvironmentUnset and QEnvironmentReset are supported.
4717
6afd337d
SM
47182017-08-25 Simon Marchi <simon.marchi@ericsson.com>
4719
4720 * inferiors.h (inferior_target_data): Rename to ...
4721 (thread_target_data): ... this.
4722 (inferior_regcache_data): Rename to ...
4723 (thread_regcache_data): ... this.
4724 (set_inferior_regcache_data): Rename to ...
4725 (set_thread_regcache_data): ... this.
4726 * inferiors.c (inferior_target_data): Rename to ...
4727 (thread_target_data): ... this.
4728 (inferior_regcache_data): Rename to ...
4729 (thread_regcache_data): ... this.
4730 (set_inferior_regcache_data): Rename to ...
4731 (set_thread_regcache_data): ... this.
4732 (free_one_thread): Update.
4733 * linux-low.h (get_thread_lwp): Update.
4734 * regcache.c (get_thread_regcache): Update.
4735 (regcache_invalidate_thread): Update.
4736 (free_register_cache_thread): Update.
4737 * win32-i386-low.c (update_debug_registers_callback): Update.
4738 (win32_get_current_dr): Update.
4739 * win32-low.c (thread_rec): Update.
4740 (delete_thread_info): Update.
4741 (continue_one_thread): Update.
4742 (suspend_one_thread): Update.
4743
a160cc46
SM
47442017-08-24 Simon Marchi <simon.marchi@ericsson.com>
4745
4746 * inferiors.c (set_inferior_target_data): Remove.
4747 * inferiors.h (set_inferior_target_data): Remove.
4748
6d580b63
YQ
47492017-08-18 Yao Qi <yao.qi@linaro.org>
4750
4751 * Makefile.in (OBS): Add selftest.o.
4752 * configure.ac: AC_DEFINE GDB_SELF_TEST if $development.
4753 * configure, config.in: Re-generated.
4754 * server.c: Include common/sefltest.h.
4755 (captured_main): Handle option --selftest.
4756
f5a29eb0
YQ
47572017-08-09 Yao Qi <yao.qi@linaro.org>
4758
4759 * configure.srv (srv_i386_regobj): Remove i386-avx.o,
4760 i386-avx-avx512.o, i386-avx-mpx-avx512-pku.o, i386-mpx.o,
4761 i386-avx-mpx.o and i386-mmx.o.
4762 (srv_amd64_regobj): Remove amd64-avx.o, amd64-avx-avx512.o,
4763 amd64-avx-mpx-avx512-pku.o, amd64-mpx.o and amd64-avx-mpx.o.
4764 (srv_i386_xmlfiles): Remove i386/i386-avx.xml,
4765 i386/i386-avx-avx512.xml, i386/i386-avx-mpx-avx512-pku.xml,
4766 i386/i386-mpx.xml, i386/i386-avx-mpx.xml and i386/i386-mmx.xml.
4767 (srv_amd64_xmlfile):i386/amd64-avx.xml, i386/amd64-avx-avx512.xml,
4768 i386/amd64-avx-mpx-avx512-pku.xml, i386/amd64-mpx.xml,
4769 i386/amd64-avx-mpx.xml.
4770
57757c2f
YQ
47712017-08-09 Yao Qi <yao.qi@linaro.org>
4772
4773 * configure.srv (srv_amd64_regobj): Remove x32.o, x32-avx.o
4774 and x32-avx-avx512.o.
4775 (srv_amd64_xmlfiles): Remove i386/x32.xml, i386/x32-avx.xml
4776 i386/x32-avx-avx512.xml.
4777
229d26fc
SM
47782017-07-26 Simon Marchi <simon.marchi@ericsson.com>
4779
4780 * tracepoint.h (enum class fast_tpoint_collect_result): New
4781 enumeration.
4782 (fast_tracepoint_collecting): Change return type to
4783 fast_tpoint_collect_result.
4784 * tracepoint.c (fast_tracepoint_collecting): Likewise.
4785 * linux-low.h: Include tracepoint.h.
4786 (struct lwp_info) <collecting_fast_tracepoint>: Change type to
4787 fast_tpoint_collect_result.
4788 * linux-low.c (handle_tracepoints): Adjust.
4789 (linux_fast_tracepoint_collecting): Change return type to
4790 fast_tpoint_collect_result.
4791 (maybe_move_out_of_jump_pad, linux_wait_for_event_filtered,
4792 linux_wait_1, stuck_in_jump_pad_callback,
4793 lwp_signal_can_be_delivered, linux_resume_one_lwp_throw,
4794 proceed_one_lwp): Adjust to type change.
4795
2e1e43e1
YQ
47962017-07-10 Yao Qi <yao.qi@linaro.org>
4797
4798 * linux-x86-low.c (x86_linux_read_description): Re-indent the code.
4799
adc764e7
YQ
48002017-06-29 Yao Qi <yao.qi@linaro.org>
4801
4802 * tdesc.h (struct target_desc) [IN_PROCESS_AGENT] <expedite_regs>:
4803 Remove.
4804 [IN_PROCESS_AGENT] <xmltarget>: Likewise.
4805
a206891a
SM
48062017-06-20 Simon Marchi <simon.marchi@ericsson.com>
4807
4808 * Makefile.in (IPA_OBJS): Sort and format one item per line.
4809
9a6c7d9c
SDJ
48102017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
4811
4812 * linux-low.c (linux_create_inferior): Adjust code to access the
4813 environment information via 'gdb_environ' class.
4814 * lynx-low.c (lynx_create_inferior): Likewise.
4815 * server.c (our_environ): Make it an instance of 'gdb_environ'.
4816 (get_environ): Return a pointer to 'our_environ'.
4817 (captured_main): Initialize 'our_environ'.
4818 * server.h (get_environ): Adjust prototype.
4819 * spu-low.c (spu_create_inferior): Adjust code to access the
4820 environment information via 'gdb_environ' class.
4821
ae3e2ccf
SM
48222017-06-17 Simon Marchi <simon.marchi@ericsson.com>
4823
4824 * linux-low.c (linux_read_memory, linux_write_memory): Remove
4825 usage of "register" keyword.
4826
3e019bdc
SM
48272017-06-17 Simon Marchi <simon.marchi@ericsson.com>
4828
4829 * configure: Re-generate.
4830
8465943a
SM
48312017-06-17 Simon Marchi <simon.marchi@ericsson.com>
4832
4833 * configure: Re-generate.
4834
cf0dd6f0
SM
48352017-06-17 Simon Marchi <simon.marchi@ericsson.com>
4836
4837 * Makefile.in (COMPILE.pre): Add "-x c++".
4838
9845682b
SDJ
48392017-06-09 Sergio Durigan Junior <sergiodj@redhat.com>
4840
4841 * fork-child.c: Conditionally include <signal.h>.
4842
aefd8b33
SDJ
48432017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
4844
4845 * server.c (handle_general_set): Handle new packet
4846 "QStartupWithShell".
4847 (handle_query): Add "QStartupWithShell" to the list of supported
4848 packets.
4849 (gdbserver_usage): Add help text explaining the
4850 new "--startup-with-shell" and "--no-startup-with-shell" CLI
4851 options.
4852 (captured_main): Recognize and act upon the presence of the new
4853 CLI options.
4854
2090129c
SDJ
48552017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
4856 Pedro Alves <palves@redhat.com>
4857
4858 * Makefile.in (SFILES): Add "nat/fork-inferior.o".
4859 * configure: Regenerate.
4860 * configure.srv (srv_linux_obj): Add "fork-child.o" and
4861 "fork-inferior.o".
4862 (i[34567]86-*-lynxos*): Likewise.
4863 (spu*-*-*): Likewise.
4864 * fork-child.c: New file.
4865 * linux-low.c: Include "common-inferior.h", "nat/fork-inferior.h"
4866 and "environ.h".
4867 (linux_ptrace_fun): New function.
4868 (linux_create_inferior): Adjust function prototype to reflect
4869 change on "target.h". Adjust function code to use
4870 "fork_inferior".
4871 (linux_request_interrupt): Delete "signal_pid".
4872 * lynx-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
4873 (lynx_ptrace_fun): New function.
4874 (lynx_create_inferior): Adjust function prototype to reflect
4875 change on "target.h". Adjust function code to use
4876 "fork_inferior".
4877 * nto-low.c (nto_create_inferior): Adjust function prototype and
4878 code to reflect change on "target.h". Update comments.
4879 * server.c: Include "common-inferior.h", "nat/fork-inferior.h",
4880 "common-terminal.h" and "environ.h".
4881 (terminal_fd): Moved to fork-child.c.
4882 (old_foreground_pgrp): Likewise.
4883 (restore_old_foreground_pgrp): Likewise.
4884 (last_status): Make it global.
4885 (last_ptid): Likewise.
4886 (our_environ): New variable.
4887 (startup_with_shell): Likewise.
4888 (program_name): Likewise.
4889 (program_argv): Rename to...
4890 (program_args): ...this.
4891 (wrapper_argv): New variable.
4892 (start_inferior): Delete function.
4893 (get_exec_wrapper): New function.
4894 (get_exec_file): Likewise.
4895 (get_environ): Likewise.
4896 (prefork_hook): Likewise.
4897 (post_fork_inferior): Likewise.
4898 (postfork_hook): Likewise.
4899 (postfork_child_hook): Likewise.
4900 (handle_v_run): Update code to deal with arguments coming from the
4901 remote host. Update calls from "start_inferior" to
4902 "create_inferior".
4903 (captured_main): Likewise. Initialize environment variable. Call
4904 "have_job_control".
4905 * server.h (post_fork_inferior): New prototype.
4906 (get_environ): Likewise.
4907 (last_status): Declare.
4908 (last_ptid): Likewise.
4909 (signal_pid): Likewise.
4910 * spu-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
4911 (spu_ptrace_fun): New function.
4912 (spu_create_inferior): Adjust function prototype to reflect change
4913 on "target.h". Adjust function code to use "fork_inferior".
4914 * target.c (target_terminal_init): New function.
4915 (target_terminal_inferior): Likewise.
4916 (target_terminal_ours): Likewise.
4917 * target.h: Include <vector>.
4918 (struct target_ops) <create_inferior>: Update prototype.
4919 (create_inferior): Update macro.
4920 * utils.c (gdb_flush_out_err): New function.
4921 * win32-low.c (win32_create_inferior): Adjust function prototype
4922 and code to reflect change on "target.h".
4923
043a4934
SDJ
49242017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
4925
4926 * inferiors.c (switch_to_thread): New function.
4927
15652511
SDJ
49282017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
4929
4930 * Makefile.in (SFILE): Add "common/job-control.c".
4931 (OBS): Add "job-control.o".
4932
21ea5acd
SDJ
49332017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
4934
4935 * Makefile: Remove "@host_makefile_frag@".
4936
e13cb306
PA
49372017-05-05 Pedro Alves <palves@redhat.com>
4938
4939 * configure: Regenerate.
4940
c94fee56
SDJ
49412017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
4942
4943 * configure: Regenerate.
4944
a0ff9e1a
SM
49452017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
4946
4947 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Adjust to
4948 software_single_step change of return type to
4949 std::vector<CORE_ADDR>.
4950 * linux-low.c (install_software_single_step_breakpoints):
4951 Likewise.
4952 * linux-low.h (install_software_single_step_breakpoints):
4953 Likewise.
4954
be628ab8
SDJ
49552017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
4956
4957 * remote-utils.c: Include "gdb_termios.h" instead of
4958 "terminal.h".
4959 * terminal.h: Delete file.
4960
7c5ded6a
SDJ
49612017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
4962
4963 * server.c: Include <vector>.
4964 <program_argv, wrapper_argv>: Convert to std::vector.
4965 (start_inferior): Rewrite function to use C++.
4966 (handle_v_run): Likewise. Update code that calculates the argv
4967 based on the vRun packet; use C++.
4968 (captured_main): Likewise.
4969
436252de
SM
49702017-04-06 Simon Marchi <simon.marchi@ericsson.com>
4971
4972 * server.c (handle_v_cont): Initialize thread_resume::thread
4973 with null_ptid.
4974
9bf2a700
PA
49752017-04-05 Pedro Alves <palves@redhat.com>
4976
4977 * configure: Regenerate.
4978
a121b7c1
PA
49792017-04-05 Pedro Alves <palves@redhat.com>
4980
4981 * gdbreplay.c (sync_error): Constify.
4982 * linux-x86-low.c (push_opcode): Constify.
4983
21c8a587
PA
49842017-04-05 Pedro Alves <palves@redhat.com>
4985
4986 * win32-low.c (get_child_debug_event)
4987 <CREATE_PROCESS_DEBUG_EVENT>: Don't report TARGET_WAITKIND_EXECD.
4988 Report TARGET_WAITKIND_SPURIOUS instead.
4989
fb32b4f7
PA
49902017-04-05 Pedro Alves <palves@redhat.com>
4991
e79be6e5
SM
4992 * remote-utils.c (remote_prepare, remote_open): Constify.
4993 * remote-utils.h (remote_prepare, remote_open): Constify.
4994 * server.c (captured_main): Constify 'port' handling.
fb32b4f7 4995
65dd1e59
SM
49962017-04-04 Simon Marchi <simon.marchi@ericsson.com>
4997
4998 * Makefile.in (clean): Clear .deps.
4999
8fa5b777
SM
50002017-03-31 Simon Marchi <simon.marchi@polymtl.ca>
5001
5002 * .gitignore: Remove generated files, replace with wildcard.
5003 * (clean): Replace removal of generated files with wildcard.
5004 (version.c): Replace with...
5005 (version-generated.c): ...this.
5006 (xml-builtin.c): Replace with...
5007 (xml-builtin-generated.c): ...this.
5008 (%-ipa.o: %-generated.c, %.o: %-generated.c): New rules.
5009 (%.c: *regformats*): Replace with...
5010 (%-generated.c: *regformats*): ...this.
5011
a12e714b
MF
50122017-03-27 Max Filippov <jcmvbkbc@gmail.com>
5013
5014 * linux-xtensa-low.c (regnum::R_THREADPTR): New enum member.
5015 (xtensa_fill_gregset): Call collect_register_by_name for
5016 threadptr register.
5017 (xtensa_store_gregset): Call supply_register_by_name for
5018 threadptr register.
5019
1a09b50a
MF
50202017-03-27 Max Filippov <jcmvbkbc@gmail.com>
5021
5022 * linux-xtensa-low.c (xtensa_fill_gregset): Call collect_register
5023 for all registers in a0_regnum..a0_regnum + C0_NREGS range.
5024 (xtensa_store_gregset): Call supply_register for all registers in
5025 a0_regnum..a0_regnum + C0_NREGS range.
5026
1a01e7c6
SM
50272017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
5028
5029 * Makefile.in (%-ipa.o: %-ipa.c): New rule.
5030 (ax-ipa.o: ax.c): Remove.
5031 (linux-i386-ipa.o: linux-i386-ipa.c): Remove.
5032 (linux-amd64-ipa.o: linux-amd64-ipa.c): Remove.
5033 (linux-aarch64-ipa.o: linux-aarch64-ipa.c): Remove.
5034 (linux-s390-ipa.o: linux-s390-ipa.c): Remove.
5035 (linux-ppc-ipa.o: linux-ppc-ipa.c): Remove.
5036
36bc18a8
SM
50372017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
5038
5039 * Makefile.in (%-ipa.o: ../common/%.c): New rule.
5040 (print-utils-ipa.o: ../common/print-utils.c): Remove.
5041 (rsp-low-ipa.o: ../common/rsp-low.c): Remove.
5042 (errors-ipa.o: ../common/errors.c): Remove.
5043 (format-ipa.o: ../common/format.c): Remove.
5044 (common-utils-ipa.o: ../common/common-utils.c): Remove.
5045
a8ebe3d5
SM
50462017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
5047
5048 * Makefile.in (%-ipa.o: %.c): New rule.
5049 (tracepoint-ipa.o: tracepoint.c): Remove.
5050 (utils-ipa.o: utils.c): Remove.
5051 (remote-utils-ipa.o: remote-utils.c): Remove.
5052 (regcache-ipa.o: regcache.c): Remove.
5053 (i386-linux-ipa.o: i386-linux.c): Remove.
5054 (i386-mmx-linux-ipa.o: i386-mmx-linux.c): Remove.
5055 (i386-avx-linux-ipa.o: i386-avx-linux.c): Remove.
5056 (i386-mpx-linux-ipa.o: i386-mpx-linux.c): Remove.
5057 (i386-avx-mpx-linux-ipa.o: i386-avx-mpx-linux.c): Remove.
5058 (i386-avx-avx512-linux-ipa.o: i386-avx-avx512-linux.c): Remove.
5059 (i386-avx-mpx-avx512-pku-linux-ipa.o: i386-avx-mpx-avx512-pku-linux.c): Remove.
5060 (amd64-linux-ipa.o: amd64-linux.c): Remove.
5061 (amd64-avx-linux-ipa.o: amd64-avx-linux.c): Remove.
5062 (amd64-mpx-linux-ipa.o: amd64-mpx-linux.c): Remove.
5063 (amd64-avx-mpx-linux-ipa.o: amd64-avx-mpx-linux.c): Remove.
5064 (amd64-avx-avx512-linux-ipa.o: amd64-avx-avx512-linux.c): Remove.
5065 (amd64-avx-mpx-avx512-pku-linux-ipa.o: amd64-avx-mpx-avx512-pku-linux.c): Remove.
5066 (aarch64-ipa.o: aarch64.c): Remove.
5067 (s390-linux32-ipa.o: s390-linux32.c): Remove.
5068 (s390-linux32v1-ipa.o: s390-linux32v1.c): Remove.
5069 (s390-linux32v2-ipa.o: s390-linux32v2.c): Remove.
5070 (s390-linux64-ipa.o: s390-linux64.c): Remove.
5071 (s390-linux64v1-ipa.o: s390-linux64v1.c): Remove.
5072 (s390-linux64v2-ipa.o: s390-linux64v2.c): Remove.
5073 (s390-te-linux64-ipa.o: s390-te-linux64.c): Remove.
5074 (s390-vx-linux64-ipa.o: s390-vx-linux64.c): Remove.
5075 (s390-tevx-linux64-ipa.o: s390-tevx-linux64.c): Remove.
5076 (s390x-linux64-ipa.o: s390x-linux64.c): Remove.
5077 (s390x-linux64v1-ipa.o: s390x-linux64v1.c): Remove.
5078 (s390x-linux64v2-ipa.o: s390x-linux64v2.c): Remove.
5079 (s390x-te-linux64-ipa.o: s390x-te-linux64.c): Remove.
5080 (s390x-vx-linux64-ipa.o: s390x-vx-linux64.c): Remove.
5081 (s390x-tevx-linux64-ipa.o: s390x-tevx-linux64.c): Remove.
5082 (powerpc-32l-ipa.o: powerpc-32l.c): Remove.
5083 (powerpc-altivec32l-ipa.o: powerpc-altivec32l.c): Remove.
5084 (powerpc-cell32l-ipa.o: powerpc-cell32l.c): Remove.
5085 (powerpc-vsx32l-ipa.o: powerpc-vsx32l.c): Remove.
5086 (powerpc-isa205-32l-ipa.o: powerpc-isa205-32l.c): Remove.
5087 (powerpc-isa205-altivec32l-ipa.o: powerpc-isa205-altivec32l.c): Remove.
5088 (powerpc-isa205-vsx32l-ipa.o: powerpc-isa205-vsx32l.c): Remove.
5089 (powerpc-e500l-ipa.o: powerpc-e500l.c): Remove.
5090 (powerpc-64l-ipa.o: powerpc-64l.c): Remove.
5091 (powerpc-altivec64l-ipa.o: powerpc-altivec64l.c): Remove.
5092 (powerpc-cell64l-ipa.o: powerpc-cell64l.c): Remove.
5093 (powerpc-vsx64l-ipa.o: powerpc-vsx64l.c): Remove.
5094 (powerpc-isa205-64l-ipa.o: powerpc-isa205-64l.c): Remove.
5095 (powerpc-isa205-altivec64l-ipa.o: powerpc-isa205-altivec64l.c): Remove.
5096 (powerpc-isa205-vsx64l-ipa.o: powerpc-isa205-vsx64l.c): Remove.
5097 (tdesc-ipa.o: tdesc.c): Remove.
5098 (x32-linux-ipa.o: x32-linux.c): Remove.
5099 (x32-avx-linux-ipa.o: x32-avx-linux.c): Remove.
5100 (x32-avx512-linux-ipa.o: x32-avx512-linux.c): Remove.
5101
50cfacb7
SM
51022017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
5103
5104 * Makefile.in (%.o: ../arch/%.c): New rule.
5105 (arm.o: ../arch/arm.c): Remove.
5106 (arm-linux.o: ../arch/arm-linux.c): Remove.
5107 (arm-get-next-pcs.o: ../arch/arm-get-next-pcs.c): Remove.
5108 (aarch64-insn.o: ../arch/aarch64-insn.c): Remove.
5109
c5a22423
SM
51102017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
5111
5112 * Makefile.in (%.o: ../nat/%.c): New rule.
5113 (x86-dregs.o: ../nat/x86-dregs.c): Remove.
5114 (amd64-linux-siginfo.o: ../nat/amd64-linux-siginfo.c): Remove.
5115 (linux-btrace.o: ../nat/linux-btrace.c): Remove.
5116 (linux-osdata.o: ../nat/linux-osdata.c): Remove.
5117 (linux-procfs.o: ../nat/linux-procfs.c): Remove.
5118 (linux-ptrace.o: ../nat/linux-ptrace.c): Remove.
5119 (linux-waitpid.o: ../nat/linux-waitpid.c): Remove.
5120 (mips-linux-watch.o: ../nat/mips-linux-watch.c): Remove.
5121 (ppc-linux.o: ../nat/ppc-linux.c): Remove.
5122 (linux-personality.o: ../nat/linux-personality.c): Remove.
5123 (aarch64-linux-hw-point.o: ../nat/aarch64-linux-hw-point.c): Remove.
5124 (aarch64-linux.o: ../nat/aarch64-linux.c): Remove.
5125 (x86-linux.o: ../nat/x86-linux.c): Remove.
5126 (x86-linux-dregs.o: ../nat/x86-linux-dregs.c): Remove.
5127 (linux-namespaces.o: ../nat/linux-namespaces.c): Remove.
5128
6bda016b
SM
51292017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
5130
5131 * Makefile.in (%.o: ../common/%.c): New rule.
5132 (signals.o: ../common/signals.c): Remove.
5133 (print-utils.o: ../common/print-utils.c): Remove.
5134 (rsp-low.o: ../common/rsp-low.c): Remove.
5135 (common-utils.o: ../common/common-utils.c): Remove.
5136 (posix-strerror.o: ../common/posix-strerror.c): Remove.
5137 (mingw-strerror.o: ../common/mingw-strerror.c): Remove.
5138 (vec.o: ../common/vec.c): Remove.
5139 (gdb_vecs.o: ../common/gdb_vecs.c): Remove.
5140 (xml-utils.o: ../common/xml-utils.c): Remove.
5141 (ptid.o: ../common/ptid.c): Remove.
5142 (buffer.o: ../common/buffer.c): Remove.
5143 (format.o: ../common/format.c): Remove.
5144 (filestuff.o: ../common/filestuff.c): Remove.
5145 (agent.o: ../common/agent.c): Remove.
5146 (errors.o: ../common/errors.c): Remove.
5147 (environ.o: ../common/environ.c): Remove.
5148 (common-debug.o: ../common/common-debug.c): Remove.
5149 (cleanups.o: ../common/cleanups.c): Remove.
5150 (common-exceptions.o: ../common/common-exceptions.c): Remove.
5151 (fileio.o: ../common/fileio.c): Remove.
5152 (common-regcache.o: ../common/common-regcache.c): Remove.
5153 (signals-state-save-restore.o: ../common/signals-state-save-restore.c): Remove.
5154 (new-op.o: ../common/new-op.c): Remove.
5155 (btrace-common.o: ../common/btrace-common.c): Remove.
5156
21122961
SM
51572017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
5158
5159 * Makefile.in (%.o: ../target/%.c): New rule.
5160 (waitstatus.o: ../target/waitstatus.c): Remove.
5161
c362e621
SM
51622017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
5163
5164 * Makefile.in
5165 (%.c: ../regformats/%.dat,
5166 (%.c: ../regformats/arm/%.dat,
5167 (%.c: ../regformats/i386/%.dat,
5168 (%.c: ../regformats/rs6000/%.dat): New rules.
5169 (aarch64.c): Remove.
5170 (reg-arm.c): Remove.
5171 (arm-with-iwmmxt.c): Remove.
5172 (arm-with-vfpv2.c): Remove.
5173 (arm-with-vfpv3.c): Remove.
5174 (arm-with-neon.c): Remove.
5175 (reg-bfin.c): Remove.
5176 (reg-cris.c): Remove.
5177 (reg-crisv32.c): Remove.
5178 (i386.c): Remove.
5179 (i386-linux.c): Remove.
5180 (i386-avx.c): Remove.
5181 (i386-avx-linux.c): Remove.
5182 (i386-avx-avx512.c): Remove.
5183 (i386-avx-avx512-linux.c): Remove.
5184 (i386-mpx.c): Remove.
5185 (i386-mpx-linux.c): Remove.
5186 (i386-avx-mpx-avx512-pku.c): Remove.
5187 (i386-avx-mpx-avx512-pku-linux.c): Remove.
5188 (i386-avx-mpx.c): Remove.
5189 (i386-avx-mpx-linux.c): Remove.
5190 (i386-mmx.c): Remove.
5191 (i386-mmx-linux.c): Remove.
5192 (reg-ia64.c): Remove.
5193 (reg-m32r.c): Remove.
5194 (reg-m68k.c): Remove.
5195 (reg-cf.c): Remove.
5196 (mips-linux.c): Remove.
5197 (mips-dsp-linux.c): Remove.
5198 (mips64-linux.c): Remove.
5199 (mips64-dsp-linux.c): Remove.
5200 (nios2-linux.c): Remove.
5201 (powerpc-32.c): Remove.
5202 (powerpc-32l.c): Remove.
5203 (powerpc-altivec32l.c): Remove.
5204 (powerpc-cell32l.c): Remove.
5205 (powerpc-vsx32l.c): Remove.
5206 (powerpc-isa205-32l.c): Remove.
5207 (powerpc-isa205-altivec32l.c): Remove.
5208 (powerpc-isa205-vsx32l.c): Remove.
5209 (powerpc-e500l.c): Remove.
5210 (powerpc-64l.c): Remove.
5211 (powerpc-altivec64l.c): Remove.
5212 (powerpc-cell64l.c): Remove.
5213 (powerpc-vsx64l.c): Remove.
5214 (powerpc-isa205-64l.c): Remove.
5215 (powerpc-isa205-altivec64l.c): Remove.
5216 (powerpc-isa205-vsx64l.c): Remove.
5217 (s390-linux32.c): Remove.
5218 (s390-linux32v1.c): Remove.
5219 (s390-linux32v2.c): Remove.
5220 (s390-linux64.c): Remove.
5221 (s390-linux64v1.c): Remove.
5222 (s390-linux64v2.c): Remove.
5223 (s390-te-linux64.c): Remove.
5224 (s390-vx-linux64.c): Remove.
5225 (s390-tevx-linux64.c): Remove.
5226 (s390x-linux64.c): Remove.
5227 (s390x-linux64v1.c): Remove.
5228 (s390x-linux64v2.c): Remove.
5229 (s390x-te-linux64.c): Remove.
5230 (s390x-vx-linux64.c): Remove.
5231 (s390x-tevx-linux64.c): Remove.
5232 (tic6x-c64xp-linux.c): Remove.
5233 (tic6x-c64x-linux.c): Remove.
5234 (tic6x-c62x-linux.c): Remove.
5235 (reg-sh.c): Remove.
5236 (reg-sparc64.c): Remove.
5237 (reg-spu.c): Remove.
5238 (amd64.c): Remove.
5239 (amd64-linux.c): Remove.
5240 (amd64-avx.c): Remove.
5241 (amd64-avx-linux.c): Remove.
5242 (amd64-avx-avx512.c): Remove.
5243 (amd64-avx-avx512-linux.c): Remove.
5244 (amd64-mpx.c): Remove.
5245 (amd64-mpx-linux.c): Remove.
5246 (amd64-avx-mpx-avx512-pku.c): Remove.
5247 (amd64-avx-mpx-avx512-pku-linux.c): Remove.
5248 (amd64-avx-mpx.c): Remove.
5249 (amd64-avx-mpx-linux.c): Remove.
5250 (x32.c): Remove.
5251 (x32-linux.c): Remove.
5252 (x32-avx.c): Remove.
5253 (x32-avx-linux.c): Remove.
5254 (x32-avx-avx512.c): Remove.
5255 (x32-avx-avx512-linux.c): Remove.
5256 (reg-xtensa.c): Remove.
5257 (reg-tilegx.c): Remove.
5258 (reg-tilegx32.c): Remove.
5259
1672e0d9
SDJ
52602017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
5261
5262 * Makefile.in (SFILES): Add "common/environ.c".
5263 (OBJS): Add "common/environ.h".
5264
239b6d10
WT
52652017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
5266
5267 * configure.ac: Check if the fs_base and gs_base members of
5268 `struct user_regs_struct' exist.
5269 * config.in: Regenerated.
5270 * configure: Likewise.
5271
694b382c
AT
52722017-01-09 Antoine Tremblay <antoine.tremblay@ericsson.com>
5273
5274 * linux-aarch32-low.c (arm_breakpoint_kind_from_pc): Use
5275 target_read_memory.
5276 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer): Likewise.
5277 (get_next_pcs_syscall_next_pc): Likewise.
5278
7dc53023
LM
52792016-12-23 Luis Machado <lgustavo@codesourcery.com>
5280
5281 * win32-i386-low.c: Fix incorrect reference to a couple source files.
5282 * nto-x86-low.c: Likewise.
5283
ad02e4fe
SM
52842016-11-30 Simon Marchi <simon.marchi@polymtl.ca>
5285
5286 * Makefile.in: Include disable-implicit-rules.mk.
5287
dcb07cfa
PA
52882016-11-23 Pedro Alves <palves@redhat.com>
5289
5290 * debug.c: Include <chrono> instead of "gdb_sys_time.h".
5291 (debug_vprintf): Use std::chrono::steady_clock instead of
5292 gettimeofday. Use '.' instead of ':'.
5293 * tracepoint.c: Include <chrono> instead of "gdb_sys_time.h".
5294 (get_timestamp): Use std::chrono::steady_clock instead of
5295 gettimeofday.
5296
8629c02c
SM
52972016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
5298
5299 * Makefile.in: Fix whitespace formatting.
5300
b593ecca
SM
53012016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
5302
5303 * Makefile.in (SFILES, OBS): Flatten list and order
5304 alphabetically.
5305
9986ba08
PA
53062016-11-23 Pedro Alves <palves@redhat.com>
5307
5308 * event-loop.c (handle_file_event): Use warning.
5309 * linux-low.c (linux_resume_one_lwp_throw): Use warning.
5310 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
5311 Use warning.
5312
4eefa7bc
PA
53132016-11-23 Pedro Alves <palves@redhat.com>
5314
5315 * linux-low.c (check_zombie_leaders): Use debug_printf for debug
5316 output.
5317 * notif.c (handle_notif_ack, notif_event_enque): Likewise.
5318 * remote-utils.c (putpkt_binary_1, readchar, getpkt): Use
5319 debug_printf and debug_flush for debug output.
5320 * server.c (handle_general_set): Likewise.
5321 * thread-db.c (try_thread_db_load): Use debug_printf for debug
5322 output.
5323
5443506e
SM
53242016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
5325
5326 * Makefile.in (.c.o): Replace rule with ...
5327 (%.o: %.c): ... this one.
5328
3b165252
SM
53292016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
5330
5331 * Makefile.in: Remove @GMAKE_TRUE@ prefixes and removes lines
5332 prefixed with @GMAKE_FALSE@. Update comment related to non-GNU
5333 make.
5334 * configure.ac: Remove checks for the make program.
5335 * configure: Re-generate.
5336
0bcda685
PA
53372016-10-28 Pedro Alves <palves@redhat.com>
5338
5339 * Makefile.in (CXX_DIALECT): Get from configure.
5340 (COMPILE.pre, CC_LD): Append $(CXX_DIALECT).
5341 * acinclude.m4: Include ../ax_cxx_compile_stdcxx.m4.
5342 * configure.ac: Call AX_CXX_COMPILE_STDCXX.
5343 * config.in: Regenerate.
5344 * configure: Regenerate.
5345
c3805894
YQ
53462016-10-27 Yao Qi <yao.qi@linaro.org>
5347
5348 * linux-low.c (linux_supports_range_stepping): Return true if
5349 can_software_single_step return true.
5350
89342618
YQ
53512016-10-27 Yao Qi <yao.qi@linaro.org>
5352
5353 * inferiors.c (find_inferior_in_random): New function.
5354 * inferiors.h (find_inferior_in_random): Declare.
5355 * linux-low.c (linux_wait_for_event_filtered): Call
5356 find_inferior_in_random instead of find_inferior.
5357
e3652c84
YQ
53582016-10-27 Yao Qi <yao.qi@linaro.org>
5359
5360 * linux-low.c (linux_wait_1): If single-step breakpoints are
5361 inserted, remove them.
5362
5a04c4cf
PA
53632016-10-26 Pedro Alves <palves@redhat.com>
5364
5365 * linux-low.c (handle_extended_wait): Link parent/child fork
5366 threads.
5367 (linux_wait_1): Unlink them.
5368 (linux_set_resume_request): Ignore resume requests for
5369 already-resumed and unhandled fork child threads.
5370 * linux-low.h (struct lwp_info) <fork_relative>: New field.
5371 * server.c (in_queued_stop_replies_ptid, in_queued_stop_replies):
5372 New functions.
5373 (handle_v_requests) <vCont>: Don't call require_running.
5374 * server.h (in_queued_stop_replies): New declaration.
5375
cb93dc7f
YQ
53762016-10-24 Yao Qi <yao.qi@linaro.org>
5377
5378 PR server/20733
5379 * linux-aarch64-low.c (append_insns): Cast the return value to
5380 'uint32_t *'.
5381
a1078bea
YQ
53822016-10-10 Yao Qi <yao.qi@linaro.org>
5383
5384 * linux-aarch32-low.c (enum arm_breakpoint_kinds): Remove.
5385
1fb77080
SDJ
53862016-10-06 Sergio Durigan Junior <sergiodj@redhat.com>
5387
5388 * target.c (target_supports_multi_process): New function, moved
5389 from...
5390 * target.h (target_supports_multi_process): ... here. Remove
5391 macro.
5392
39b5a3b9
TT
53932016-10-05 Tom Tromey <tom@tromey.com>
5394
5395 PR remote/20655:
5396 * tracepoint.c (handle_tracepoint_bkpts): Check
5397 ipa_error_tracepoint, not ipa_stopping_tracepoint.
5398
c1d0b70a
YQ
53992016-10-05 Yao Qi <yao.qi@linaro.org>
5400
5401 * configure.srv: Update the path of arm-*.xml files.
5402
0a69eedb
YQ
54032016-10-05 Terry Guo <terry.guo@arm.com>
5404 Yao Qi <yao.qi@linaro.org>
5405
5406 * Makefile.in: Adjust the path of rules.
5407 * configure.srv: Update the path of xml files.
5408 * regformats/arm-with-iwmmxt.dat: Regenerated.
5409 * regformats/arm-with-neon.dat: Likewise.
5410 * regformats/arm-with-vfpv2.dat: Likewise.
5411 * regformats/arm-with-vfpv3.dat Likewise.
5412
17e16485
YQ
54132016-09-30 Yao Qi <yao.qi@linaro.org>
5414
5415 PR gdbserver/20627
5416 * target.c (target_stop_and_wait): Don't call
5417 target_continue_no_signal, use resume_stop instead.
5418
edeeb602
YQ
54192016-09-26 Yao Qi <yao.qi@linaro.org>
5420
5421 * linux-low.c (linux_wait_1): Call debug_exit.
5422
503b1c39
PA
54232016-09-23 Pedro Alves <palves@redhat.com>
5424
5425 * Makefile.in (SFILES): Add common/new-op.c.
5426 (OBS): Add common/new-op.o.
5427 (new-op.o): New rule.
5428
74172ecf
SM
54292016-09-21 Simon Marchi <simon.marchi@ericsson.com>
5430
5431 * .gitinore: Ignore more files.
5432
fc6cda2e
YQ
54332016-09-21 Yao Qi <yao.qi@linaro.org>
5434
5435 * linux-aarch32-low.c (arm_fill_gregset): Keep bits 20 to
5436 23.
5437
bc1e6c81
SDJ
54382016-09-19 Sergio Durigan Junior <sergiodj@redhat.com>
5439
5440 * server.c (start_inferior): Call target_mourn_inferior instead of
5441 mourn_inferior; pass ptid_t argument to it.
5442 (resume): Likewise.
5443 (handle_target_event): Likewise.
5444 * target.c (target_mourn_inferior): New function.
5445 * target.h (mourn_inferior): Delete macro.
5446
0e00e962
AA
54472016-09-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
5448
5449 * linux-low.c (lwp_is_stepping): New function.
5450
1d8cb77d
CL
54512016-09-06 Carl Love <cel@us.ibm.com>
5452
5453 * server.c (start_inferior): Fixed comment, requested comment change
5454 didn't get updated correctly. Removed reference to ptrace () call as
5455 it is only true on Linux systems.
5456
7313bced
CL
54572016-09-06 Carl Love <cel@us.ibm.com>
5458
5459 * server.c (start_inferior): Do not call
5460 function target_post_create_inferior () if the
5461 inferior process has already exited.
5462
cf6de44d
PA
54632016-09-05 Pedro Alves <palves@redhat.com>
5464
5465 * Makefile.in (COMPILER, COMPILER_CFLAGS): Remove.
5466 (COMPILE.pre, CC_LD): Use CXX directly.
5467 (INTERNAL_CFLAGS_BASE): Use CXXFLAGS directly.
5468 * acinclude.m4: Don't include build-with-cxx.m4.
5469 * configure.ac: Remove GDB_AC_BUILD_WITH_CXX call.
5470 * configure: Regenerate.
5471
c1da6748
AT
54722016-09-02 Akash Trehan <akash.trehan123@gmail.com>
5473
5474 PR gdb/19495
5475 * remote-utils.c (relocate_instruction): Remove redundant strcpy()
5476 call writing data to own_buf.
5477
f2b9e3df
SDJ
54782016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
5479
5480 * target.c (mywait): Call target_wait instead of
5481 the_target->wait.
5482 (target_wait): New function.
5483
049a8570
SDJ
54842016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
5485
5486 * server.c (start_inferior): New variable 'ptid'. Replace calls
5487 to the_target->resume by target_continue{,_no_signal}, depending
5488 on the case.
5489 * target.c (target_stop_and_wait): Call target_continue_no_signal
5490 instead of the_target->resume.
5491 (target_continue): New function.
5492
3aa5cfa0
AT
54932016-08-31 Antoine Tremblay <antoine.tremblay@ericsson.com>
5494
5495 * linux-low.c (linux_wait_1): Move event switch after unsuspend_lwps.
5496
754653a7
AZ
54972016-08-25 Adhemerval Zanella <adhemerval.zanella@linaro.org>
5498
5499 PR server/20491
5500 * gdb_proc_service.h (ps_get_thread_area): Remove const from struct
5501 ps_prochandle.
5502 * linux-aarch64-low.c (ps_get_thread_area): Likewise.
5503 * linux-arm-low.c (ps_get_thread_area): Likewise.
5504 * linux-crisv32-low.c (ps_get_thread_area): Likewise.
5505 * linux-m68k-low.c (ps_get_thread_area): Likewise.
5506 * linux-mips-low.c (ps_get_thread_area): Likewise.
5507 * linux-nios2-low.c (ps_get_thread_area): Likewise.
5508 * linux-tic6x-low.c (ps_get_thread_area): Likewise.
5509 * linux-x86-low.c (ps_get_thread_area): Likewise.
5510 * linux-xtensa-low.c (ps_get_thread_area): Likewise.
5511
ed036b40
PA
55122016-08-19 Pedro Alves <palves@redhat.com>
5513
5514 * linux-x86-low.c (amd64_emit_call): Emit missing call opcode.
5515
c8ef42ee
PA
55162016-08-19 Pedro Alves <palves@redhat.com>
5517
5518 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Fix
5519 comment. Use memcpy instead of casting through unsigned long.
5520
9c235a72
PA
55212016-08-19 Pedro Alves <palves@redhat.com>
5522
5523 * linux-amd64-ipa.c (alloc_jump_pad_buffer) [__ILP32__]: Try
5524 allocating around 0x80000000.
5525
201506da
PA
55262016-08-19 Pedro Alves <palves@redhat.com>
5527
5528 PR gdb/20415
5529 * Makefile.in (x32-linux-ipa.o, x32-avx-linux-ipa.o)
5530 (x32-avx512-linux-ipa.o): New rules.
5531 * configure.ac (x86_64-*-linux*): New x32 check.
5532 * configure.srv (ipa_x32_linux_regobj): New.
5533 (x86_64-*-linux*): Use $ipa_x32_linux_regobj if building for x32.
5534 * linux-amd64-ipa.c (get_ipa_tdesc) [__ILP32__]: Return x32
5535 descriptions.
5536 (initialize_low_tracepoint) [__ILP32__]: Initialize x32
5537 descriptions.
5538 * configure: Regenerate.
5539
f348d89a
PA
55402016-08-09 Pedro Alves <palves@redhat.com>
5541
5542 PR gdb/18653
5543 * Makefile.in (OBS): Add signals-state-save-restore.o.
5544 (signals-state-save-restore.o): New rule.
5545 * config.in: Regenerate.
5546 * configure: Regenerate.
5547 * linux-low.c: Include "signals-state-save-restore.h".
5548 (linux_create_inferior): Call
5549 restore_original_signals_state.
5550 * server.c: Include "dispositions-save-restore.h".
5551 (captured_main): Call save_original_signals_state.
5552
1baf5149
PA
55532016-08-05 Pedro Alves <palves@redhat.com>
5554
5555 * configure: Regenerate.
5556
fcd4a73d
YQ
55572016-08-04 Yao Qi <yao.qi@linaro.org>
5558
5559 * linux-low.c (regsets_fetch_inferior_registers): Check
5560 errno is ESRCH or not.
5561
979659d0
YQ
55622016-08-02 Yao Qi <yao.qi@linaro.org>
5563
5564 * thread-db.c (struct thread_db) <td_ta_event_getmsg_p>: Remove.
5565 <td_ta_set_event_p, td_ta_event_addr_p>: Remove.
5566 (thread_db_load_search): Update.
5567 (try_thread_db_load_1): Don't look for td_ta_event_addr,
5568 td_ta_set_event and td_ta_event_getmsg.
5569
6598661d
PA
55702016-07-26 Pedro Alves <palves@redhat.com>
5571
5572 PR server/20414
5573 * linux-x86-low.c (x86_get_pc, x86_set_pc): Use uint64_t instead
5574 of unsigned long for 64-bit registers and use uint32_t instead of
5575 unsigned int for 32-bit registers.
5576
9cf12d57
PA
55772016-07-26 Pedro Alves <palves@redhat.com>
5578
5579 * linux-x86-low.c (x86_siginfo_fixup): Rename 'native' parameter
5580 to 'ptrace'.
5581
305450ed
TT
55822016-07-21 Tom Tromey <tom@tromey.com>
5583
5584 * configure: Rebuild.
5585
2583da7c
YQ
55862016-07-21 Yao Qi <yao.qi@linaro.org>
5587
5588 * mem-break.c (find_gdb_breakpoint): Cast bp to
5589 'struct gdb_breakpoint *' rather than 'gdb_breakpoint *'.
5590
21536b36
YQ
55912016-07-21 Yao Qi <yao.qi@linaro.org>
5592
5593 * server.c (handle_v_requests): Support s and S actions
5594 if target_supports_software_single_step return true.
5595
8901d193
YQ
55962016-07-21 Yao Qi <yao.qi@linaro.org>
5597
5598 * linux-low.c (resume_stopped_resumed_lwps): If resume request
5599 is resume_step, call maybe_hw_step.
5600 (linux_wait_1): Stop all threads, remove reinsert breakpoints,
5601 and unstop them.
5602 (linux_resume_one_lwp_throw): Don't assert the thread has reinsert
5603 breakpoints or not.
5604 (proceed_one_lwp): If resume request is resume_step, install
5605 reinsert breakpoints and call maybe_hw_step.
5606
0e9a339e
YQ
56072016-07-21 Yao Qi <yao.qi@linaro.org>
5608
5609 * linux-low.c (proceed_one_lwp): Declare.
5610 (linux_resume_one_thread): Remove local variable 'step'.
5611 Lift code enqueue signal. Call proceed_one_lwp instead of
5612 linux_resume_one_lwp.
5613
4281b351
YQ
56142016-07-21 Yao Qi <yao.qi@linaro.org>
5615
5616 * linux-low.c (linux_resume_one_thread): Call
5617 enqueue_pending_signal.
5618
984a2c04
YQ
56192016-07-21 Yao Qi <yao.qi@linaro.org>
5620
5621 * gdbthread.h (make_cleanup_restore_current_thread): Declare.
5622 * inferiors.c (do_restore_current_thread_cleanup): New function.
5623 (make_cleanup_restore_current_thread): Likewise.
5624 * linux-low.c (install_software_single_step_breakpoints): Call
5625 make_cleanup_restore_current_thread. Switch current_thread to
5626 thread.
5627
bec903c9
YQ
56282016-07-21 Yao Qi <yao.qi@linaro.org>
5629
5630 * mem-break.c (struct reinsert_breakpoint) <ptid>: New field.
5631 (set_reinsert_breakpoint): New parameter ptid. Callers updated.
5632 (clone_one_breakpoint): Likewise.
5633 (delete_reinsert_breakpoints): Change parameter to thread.
5634 Callers updated.
5635 (has_reinsert_breakpoints): Likewise.
5636 (uninsert_reinsert_breakpoints): Likewise.
5637 (reinsert_reinsert_breakpoints): Likewise.
5638 * mem-break.h (set_reinsert_breakpoint): Update declaration.
5639 (delete_reinsert_breakpoints): Likewise.
5640 (reinsert_reinsert_breakpoints): Likewise.
5641 (uninsert_reinsert_breakpoints): Likewise.
5642 (has_reinsert_breakpoints): Likewise.
5643
63c40ec7
YQ
56442016-07-21 Yao Qi <yao.qi@linaro.org>
5645
5646 * inferiors.c (get_thread_process): Make parameter const.
5647 * inferiors.h (get_thread_process): Update declaration.
5648 * mem-break.c (clone_all_breakpoints): Remove all parameters.
5649 Add new parameters child_thread and parent_thread. Callers
5650 updated.
5651 * mem-break.h (clone_all_breakpoints): Update declaration.
5652
9aa76cd0
YQ
56532016-07-21 Yao Qi <yao.qi@linaro.org>
5654
5655 * mem-break.c (struct breakpoint) <cond_list>: Remove.
5656 <command_list, handler>: Remove.
5657 (struct gdb_breakpoint): New.
5658 (struct other_breakpoint): New.
5659 (struct reinsert_breakpoint): New.
5660 (is_gdb_breakpoint): New function.
5661 (any_persistent_commands): Update command_list if
5662 is_gdb_breakpoint returns true.
5663 (set_breakpoint): Create breakpoints according to their types.
5664 (find_gdb_breakpoint): Return 'struct gdb_breakpoint *'.
5665 (set_gdb_breakpoint_1): Likewise.
5666 (set_gdb_breakpoint): Likewise.
5667 (clear_breakpoint_conditions): Change parameter type to
5668 'struct gdb_breakpoint *'.
5669 (clear_breakpoint_commands): Likewise.
5670 (clear_breakpoint_conditions_and_commands): Likewise.
5671 (add_condition_to_breakpoint): Likewise.
5672 (add_breakpoint_condition): Likewise.
5673 (add_commands_to_breakpoint): Likewise.
5674 (check_breakpoints): Check other_breakpoint.
5675 (clone_one_breakpoint): Clone breakpopint according to its type.
5676 * mem-break.h (struct gdb_breakpoint): Declare.
5677 (set_gdb_breakpoint): Update declaration.
5678 (clear_breakpoint_conditions_and_commands): Likewise.
5679 (add_breakpoint_condition): Likewise.
5680 (add_breakpoint_commands): Likewise.
5681 * server.c (process_point_options): Change parameter type to
5682 'struct gdb_breakpoint *'.
5683
811f8301
YQ
56842016-07-21 Yao Qi <yao.qi@linaro.org>
5685
5686 * mem-break.c (set_breakpoint_at): Rename it to ...
5687 (set_breakpoint_type_at): ... it.
5688 (set_breakpoint_at): Call set_breakpoint_type_at.
5689 (set_reinsert_breakpoint): Call set_breakpoint_type_at.
5690 * mem-break.h (set_breakpoint_at): Update comments.
5691
b1c51e36
CLT
56922016-07-12 Chung-Lin Tang <cltang@codesourcery.com>
5693
5694 * linux-nios2-low.c (nios2_fill_gregset): Add type cast
5695 to buf parameter.
5696 (nios2_store_gregset): Likewise.
5697
ced2dffb
PA
56982016-07-01 Pedro Alves <palves@redhat.com>
5699 Antoine Tremblay <antoine.tremblay@ericsson.com>
5700
5701 * linux-low.c: Change interface to take the target lwp_info
5702 pointer directly and return void. Handle detaching from a zombie
5703 thread.
5704 (linux_detach_lwp_callback): New function.
5705 (linux_detach): Detach from the leader thread after detaching from
5706 the clone threads.
5707
2ac09a5b
YQ
57082016-06-28 Yao Qi <yao.qi@linaro.org>
5709
5710 * linux-aarch64-low.c (aarch64_ftrace_insn_reloc_b): Use int64_t
5711 for variable new_offset.
5712 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
5713 (aarch64_ftrace_insn_reloc_cb): Likewise.
5714 (aarch64_ftrace_insn_reloc_tb): Likewise.
5715 (aarch64_install_fast_tracepoint_jump_pad): Likewise. Use
5716 PRIx64 instead of PRIx32.
5717
79e7fd4f
YQ
57182016-06-28 Yao Qi <yao.qi@linaro.org>
5719
5720 * linux-arm-low.c (arm_get_syscall_trapinfo): New function.
5721 (the_low_target): Install arm_get_syscall_trapinfo.
5722
061fc021
YQ
57232016-06-28 Yao Qi <yao.qi@linaro.org>
5724
5725 * linux-aarch64-low.c (aarch64_get_syscall_trapinfo): New
5726 function.
5727 (the_low_target): Install aarch64_get_syscall_trapinfo.
5728
4cc32bec
YQ
57292016-06-28 Yao Qi <yao.qi@linaro.org>
5730
5731 * linux-low.c (get_syscall_trapinfo): Remove parameter sysret.
5732 Callers updated.
5733 * linux-low.h (struct linux_target_ops) <get_syscall_trapinfo>:
5734 Remove parameter sysno.
5735 * linux-x86-low.c (x86_get_syscall_trapinfo): Remove parameter
5736 sysret.
5737
782c1122
AA
57382016-06-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
5739
5740 * linux-s390-low.c (s390_emit_eq_goto): Mark function static.
5741 (s390_emit_ne_goto): Likewise.
5742 (s390_emit_lt_goto): Likewise.
5743 (s390_emit_le_goto): Likewise.
5744 (s390_emit_gt_goto): Likewise.
5745 (s390_emit_ge_goto): Likewise.
5746 (s390x_emit_eq_goto): Likewise.
5747 (s390x_emit_ne_goto): Likewise.
5748 (s390x_emit_lt_goto): Likewise.
5749 (s390x_emit_le_goto): Likewise.
5750 (s390x_emit_gt_goto): Likewise.
5751 (s390x_emit_ge_goto): Likewise.
5752 (s390_emit_ops_impl): Mark variable static.
5753 (s390x_emit_ops): Likewise.
5754
2e7b624b
YQ
57552016-06-17 Yao Qi <yao.qi@linaro.org>
5756
5757 * linux-low.c (handle_extended_wait): Call
5758 uninsert_reinsert_breakpoints for the parent process. Remove
5759 reinsert breakpoints from the child process. Reinsert them to
5760 the parent process when vfork is done.
5761 * mem-break.c (uninsert_reinsert_breakpoints): New function.
5762 (reinsert_reinsert_breakpoints): New function.
5763 * mem-break.h (uninsert_reinsert_breakpoints): Declare
5764 (reinsert_reinsert_breakpoints): Declare.
5765
8a81c5d7
YQ
57662016-06-17 Yao Qi <yao.qi@linaro.org>
5767
5768 * linux-low.c (handle_extended_wait): If the parent is doing
5769 step-over, remove the reinsert breakpoints from the forked child.
5770
f50bf8e5
YQ
57712016-06-17 Yao Qi <yao.qi@linaro.org>
5772
5773 * linux-low.c (unsuspend_all_lwps): Declare.
5774 (linux_low_filter_event): If thread exited, call finish_step_over.
5775 If step-over is finished, unsuspend other threads.
5776
8376a3cb
YQ
57772016-06-17 Yao Qi <yao.qi@linaro.org>
5778
5779 * linux-low.c (linux_resume_one_lwp_throw): Assert
5780 has_reinsert_breakpoints returns false.
5781 * mem-break.c (delete_disabled_breakpoints): Assert
5782 bp type isn't reinsert_breakpoint.
5783
f79b145d
YQ
57842016-06-17 Yao Qi <yao.qi@linaro.org>
5785
5786 * linux-low.c (maybe_hw_step): New function.
5787 (linux_resume_one_lwp_throw): Call maybe_hw_step.
5788 (finish_step_over): Switch current_thread to lwp temporarily,
5789 and assert has_reinsert_breakpoints returns true.
5790 (proceed_one_lwp): Call maybe_hw_step.
5791 * mem-break.c (has_reinsert_breakpoints): New function.
5792 * mem-break.h (has_reinsert_breakpoints): Declare.
5793
0ae534d2
JT
57942016-06-02 Jon Turney <jon.turney@dronecode.org.uk>
5795
5796 * win32-low.c (win32_create_inferior): Add pointer casts for C++.
5797
fcdad592
YQ
57982016-05-17 Yao Qi <yao.qi@linaro.org>
5799
5800 * linux-low.c (linux_stabilize_threads): Call unsuspend_all_lwps
5801 instead of find_inferior.
5802
9e784964
YQ
58032016-05-05 Yao Qi <yao.qi@linaro.org>
5804
5805 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer):
5806 Initialize res to zero.
5807
cf2ebb6e
YQ
58082016-05-05 Yao Qi <yao.qi@linaro.org>
5809
5810 * linux-arm-low.c (arm_sigreturn_next_pc): Change type of cpsr
5811 to uint32_t.
5812
c1aebf87
UW
58132016-05-04 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
5814
5815 * spu-low.c (fetch_ppc_register): Cast PowerPC-Linux-specific value
5816 used as first ptrace argument to PTRACE_TYPE_ARG1 for C++.
5817 (fetch_ppc_memory_1, store_ppc_memory_1): Likewise.
5818
35fd2deb 58192016-04-28 Par Olsson <par.olsson@windriver.com>
cbe14bcf 5820 Simon Marchi <simon.marchi@ericsson.com>
35fd2deb
PO
5821
5822 * tracepoint.c (write_inferior_int8): New function.
5823 (cmd_qtenable_disable): Write enable flag using
5824 write_inferior_int8.
5825
484b3c32
YQ
58262016-04-25 Yao Qi <yao.qi@linaro.org>
5827
5828 * linux-low.c (lwp_signal_can_be_delivered): Adjust.
5829 (need_step_over_p): Return zero if the LWP has pending signals
5830 can be delivered on software single step target.
5831
85ba7d86
YQ
58322016-04-25 Yao Qi <yao.qi@linaro.org>
5833
5834 * linux-low.c (reinsert_raw_breakpoint): If bp->inserted is true
5835 return instead of error.
5836
3539aa13
YQ
58372016-04-22 Yao Qi <yao.qi@linaro.org>
5838
5839 * linux-aarch32-low.c (arm_store_gregset): Clear CPSR bits 20
5840 to 23.
5841
5b061e98
YQ
58422016-04-22 Yao Qi <yao.qi@linaro.org>
5843
5844 * linux-low.c (lwp_signal_can_be_delivered): Don't deliver
5845 signal when stepping over breakpoint with software single
5846 step.
5847
3451269c
PA
58482016-04-21 Pedro Alves <palves@redhat.com>
5849
5850 * linux-s390-low.c (s390_collect_ptrace_register)
5851 (s390_supply_ptrace_register, s390_get_hwcap): Use gdb_byte * and
5852 add casts.
5853 (s390_check_regset): Use void * instead of gdb_byte *.
5854
a2358508
PA
58552016-04-20 Pedro Alves <palves@redhat.com>
5856
5857 * configure: Renegerate.
5858
6885166d
YQ
58592016-04-20 Yao Qi <yao.qi@linaro.org>
5860
5861 * linux-aarch32-low.c: Include "arch/arm-linux.h".
5862 (arm_fill_gregset): Use ARM_CPSR_GREGNUM rather than magic
5863 number 16.
5864 (arm_store_gregset): Likewise.
5865
2b863f51
WT
58662016-04-16 Walfred Tedeschi <walfred.tedeschi@intel.com>
5867
5868 * Makefile.in (clean): Add removal for i386-avx-mpx.c,
5869 i386-avx-mpx-linux.c, amd64-avx-mpx.c and amd64-avx-mpx-linux.c.
5870 (i386-avx-mpx.c, i386-avx-mpx-linux.c, amd64-avx-mpx.c)
5871 (amd64-avx-mpx-linux.c): New rules.
5872 (amd64-avx-mpx-linux-ipa.o, i386-avx-mpx-linux-ipa.o): New rule.
5873 * configure.srv (srv_i386_regobj): Add i386-avx-mpx.o.
5874 (srv_i386_linux_regobj): Add i386-avx-mpx-linux.o.
5875 (srv_amd64_regobj): Add amd64-avx-mpx.o.
5876 (srv_amd64_linux_regobj): Add amd64-avx-mpx-linux.o.
5877 (srv_i386_xmlfiles): Add i386/i386-avx-mpx.xml.
5878 (srv_amd64_xmlfiles): Add i386/amd64-avx-mpx.xml.
5879 (srv_i386_linux_xmlfiles): Add i386/i386-avx-mpx-linux.xml.
5880 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-mpx-linux.xml.
5881 (ipa_i386_linux_regobj): Add i386-avx-mpx-linux-ipa.o.
5882 (ipa_amd64_linux_regobj): Add amd64-avx-mpx-linux-ipa.o.
5883 * linux-x86-low.c (x86_linux_read_description): Add case for
5884 X86_XSTATE_AVX_MPX_MASK.
5885 (x86_get_ipa_tdesc_idx): Add cases for avx_mpx.
5886 (initialize_low_arch): Call init_registers_amd64_avx_mpx_linux and
5887 init_registers_i386_avx_mpx_linux.
5888 * linux-i386-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
5889 (initialize_low_tracepoint): Call
5890 init_registers_i386_avx_mpx_linux.
5891 * linux-amd64-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
5892 (initialize_low_tracepoint): Call
5893 init_registers_amd64_avx_mpx_linux.
5894 * linux-x86-tdesc.h (X86_TDESC_AVX_MPX): New enum value.
5895 (init_registers_amd64_avx_mpx_linux, tdesc_amd64_avx_mpx_linux)
5896 (init_registers_i386_avx_mpx_linux, tdesc_i386_avx_mpx_linux): New
5897 declarations.
5898
9b30624b
PA
58992016-04-18 Pedro Alves <palves@redhat.com>
5900
5901 * configure: Regenerate.
5902
45e3745e
AT
59032016-04-13 Antoine Tremblay <antoine.tremblay@ericsson.com>
5904
5905 * linux-aarch64-low.c (aarch64_emit_add): Switch x1 and x0.
5906 (aarch64_emit_sub): Likewise.
5907
2afc13ff
PA
59082016-04-12 Pedro Alves <palves@redhat.com>
5909
5910 * utils.c (prepare_to_throw_exception): Delete.
5911
6e774b13
SM
59122016-04-05 Simon Marchi <simon.marchi@ericsson.com>
5913
5914 * Makefile.in ($(IPA_LIB)): Set SONAME of the IPA lib.
5915
4dca19f8
MK
59162016-04-05 Marcin Kościelnicki <koriakin@0x04.net>
5917
5918 * tracepoint.c (getauxval): Move to #ifdef IN_PROCESS_AGENT.
5919
d0a9981f
MK
59202016-04-03 Marcin Kościelnicki <koriakin@0x04.net>
5921
5922 * linux-aarch64-ipa.c: Add <elf.h> include.
5923 * linux-ppc-ipa.c: Add <elf.h> include.
5924 * linux-s390-ipa.c: Add <elf.h> include.
5925
252db07e
MK
59262016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
5927
5928 * tracepoint.c (gdb_collect_ptr): Remove const qualifier.
5929 (get_raw_reg_ptr): Likewise.
5930 (get_trace_state_variable_value_ptr): Likewise.
5931 (set_trace_state_variable_value_ptr): Likewise.
5932 (initialize_tracepoint): Cast alloc_jump_pad_buffer result to
5933 char *.
5934
14e2b6d9
MK
59352016-03-31 Wei-cheng Wang <cole945@gmail.com>
5936 Marcin Kościelnicki <koriakin@0x04.net>
5937
5938 PR/17221
5939 * linux-ppc-low.c (emit_insns): New function.
5940 (__EMIT_ASM, _EMIT_ASM, EMIT_ASM): New macros.
5941 (ppc_emit_prologue): New function.
5942 (ppc_emit_epilogue): New function.
5943 (ppc_emit_add): New function.
5944 (ppc_emit_sub): New function.
5945 (ppc_emit_mul): New function.
5946 (ppc_emit_lsh): New function.
5947 (ppc_emit_rsh_signed): New function.
5948 (ppc_emit_rsh_unsigned): New function.
5949 (ppc_emit_ext): New function.
5950 (ppc_emit_zero_ext): New function.
5951 (ppc_emit_log_not): New function.
5952 (ppc_emit_bit_and): New function.
5953 (ppc_emit_bit_or): New function.
5954 (ppc_emit_bit_xor): New function.
5955 (ppc_emit_bit_not): New function.
5956 (ppc_emit_equal): New function.
5957 (ppc_emit_less_signed): New function.
5958 (ppc_emit_less_unsigned): New function.
5959 (ppc_emit_ref): New function.
5960 (ppc_emit_const): New function.
5961 (ppc_emit_reg): New function.
5962 (ppc_emit_pop): New function.
5963 (ppc_emit_stack_flush): New function.
5964 (ppc_emit_swap): New function.
5965 (ppc_emit_stack_adjust): New function.
5966 (ppc_emit_call): New function.
5967 (ppc_emit_int_call_1): New function.
5968 (ppc_emit_void_call_2): New function.
5969 (ppc_emit_if_goto): New function.
5970 (ppc_emit_goto): New function.
5971 (ppc_emit_eq_goto): New function.
5972 (ppc_emit_ne_goto): New function.
5973 (ppc_emit_lt_goto): New function.
5974 (ppc_emit_le_goto): New function.
5975 (ppc_emit_gt_goto): New function.
5976 (ppc_emit_ge_goto): New function.
5977 (ppc_write_goto_address): New function.
5978 (ppc_emit_ops_impl): New static variable.
5979 (ppc64v1_emit_prologue): New function.
5980 (ppc64v2_emit_prologue): New function.
5981 (ppc64_emit_epilogue): New function.
5982 (ppc64_emit_add): New function.
5983 (ppc64_emit_sub): New function.
5984 (ppc64_emit_mul): New function.
5985 (ppc64_emit_lsh): New function.
5986 (ppc64_emit_rsh_signed): New function.
5987 (ppc64_emit_rsh_unsigned): New function.
5988 (ppc64_emit_ext): New function.
5989 (ppc64_emit_zero_ext): New function.
5990 (ppc64_emit_log_not): New function.
5991 (ppc64_emit_bit_and): New function.
5992 (ppc64_emit_bit_or): New function.
5993 (ppc64_emit_bit_xor): New function.
5994 (ppc64_emit_bit_not): New function.
5995 (ppc64_emit_equal): New function.
5996 (ppc64_emit_less_signed): New function.
5997 (ppc64_emit_less_unsigned): New function.
5998 (ppc64_emit_ref): New function.
5999 (ppc64_emit_const): New function.
6000 (ppc64v1_emit_reg): New function.
6001 (ppc64v2_emit_reg): New function.
6002 (ppc64_emit_pop): New function.
6003 (ppc64_emit_stack_flush): New function.
6004 (ppc64_emit_swap): New function.
6005 (ppc64v1_emit_call): New function.
6006 (ppc64v2_emit_call): New function.
6007 (ppc64v1_emit_int_call_1): New function.
6008 (ppc64v2_emit_int_call_1): New function.
6009 (ppc64v1_emit_void_call_2): New function.
6010 (ppc64v2_emit_void_call_2): New function.
6011 (ppc64_emit_if_goto): New function.
6012 (ppc64_emit_eq_goto): New function.
6013 (ppc64_emit_ne_goto): New function.
6014 (ppc64_emit_lt_goto): New function.
6015 (ppc64_emit_le_goto): New function.
6016 (ppc64_emit_gt_goto): New function.
6017 (ppc64_emit_ge_goto): New function.
6018 (ppc64v1_emit_ops_impl): New static variable.
6019 (ppc64v2_emit_ops_impl): New static variable.
6020 (ppc_emit_ops): New function.
6021 (linux_low_target): Wire in ppc_emit_ops.
6022
a2174ba4
MK
60232016-03-31 Wei-cheng Wang <cole945@gmail.com>
6024 Marcin Kościelnicki <koriakin@0x04.net>
6025
6026 PR/17221
6027 * Makefile.in: Add powerpc-*-ipa.o
6028 * configure.srv: Add ipa_obj for powerpc*-linux.
6029 * linux-ppc-ipa.c: New file.
6030 * linux-ppc-low.c: Added linux-ppc-tdesc.h, ax.h, tracepoint.h
6031 includes.
6032 (PPC_FIELD): New macro.
6033 (PPC_SEXT): New macro.
6034 (PPC_OP6): New macro.
6035 (PPC_BO): New macro.
6036 (PPC_LI): New macro.
6037 (PPC_BD): New macro.
6038 (init_registers_*): Move prototype to linux-ppc-tdesc.h.
6039 (tdesc_*): Move declaration to linux-ppc-tdesc.h.
6040 (ppc_get_hwcap): Rename to ppc_get_auxv and add type parameter.
6041 (ppc_get_thread_area): New function.
6042 (is_elfv2_inferior): New function.
6043 (gen_ds_form): New function.
6044 (GEN_STD): New macro.
6045 (GEN_STDU): New macro.
6046 (GEN_LD): New macro.
6047 (GEN_LDU): New macro.
6048 (gen_d_form): New function.
6049 (GEN_ADDI): New macro.
6050 (GEN_ADDIS): New macro.
6051 (GEN_LI): New macro.
6052 (GEN_LIS): New macro.
6053 (GEN_ORI): New macro.
6054 (GEN_ORIS): New macro.
6055 (GEN_LWZ): New macro.
6056 (GEN_STW): New macro.
6057 (GEN_STWU): New macro.
6058 (gen_xfx_form): New function.
6059 (GEN_MFSPR): New macro.
6060 (GEN_MTSPR): New macro.
6061 (GEN_MFCR): New macro.
6062 (GEN_MTCR): New macro.
6063 (GEN_SYNC): New macro.
6064 (GEN_LWSYNC): New macro.
6065 (gen_x_form): New function.
6066 (GEN_OR): New macro.
6067 (GEN_MR): New macro.
6068 (GEN_LWARX): New macro.
6069 (GEN_STWCX): New macro.
6070 (GEN_CMPW): New macro.
6071 (gen_md_form): New function.
6072 (GEN_RLDICL): New macro.
6073 (GEN_RLDICR): New macro.
6074 (gen_i_form): New function.
6075 (GEN_B): New macro.
6076 (GEN_BL): New macro.
6077 (gen_b_form): New function.
6078 (GEN_BNE): New macro.
6079 (GEN_LOAD): New macro.
6080 (GEN_STORE): New macro.
6081 (gen_limm): New function.
6082 (gen_atomic_xchg): New function.
6083 (gen_call): New function.
6084 (ppc_relocate_instruction): New function.
6085 (ppc_install_fast_tracepoint_jump_pad): New function.
6086 (ppc_get_min_fast_tracepoint_insn_len): New function.
6087 (ppc_get_ipa_tdesc_idx): New function.
6088 (the_low_target): Wire in the new functions.
6089 (initialize_low_arch) [!__powerpc64__]: Don'it initialize 64-bit
6090 tdescs.
6091 * linux-ppc-tdesc.h: New file.
6092
a13c4696
MK
60932016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
6094
6095 * linux-aarch64-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
6096 (alloc_jump_pad_buffer): New function.
6097 * linux-amd64-ipa.c: Add <sys/mman.h> include.
6098 (alloc_jump_pad_buffer): New function.
6099 * linux-i386-ipa.c (alloc_jump_pad_buffer): New function.
6100 * linux-s390-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
6101 (alloc_jump_pad_buffer): New function.
6102 * tracepoint.c (getauxval) [!HAVE_GETAUXVAL]: New function.
6103 (initialize_tracepoint): Delegate to alloc_jump_pad_buffer.
6104 * tracepoint.h (alloc_jump_pad_buffer): New prototype.
6105 (getauxval) [!HAVE_GETAUXVAL]: New prototype.
6106
1cda1512
MK
61072016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
6108
6109 * linux-aarch64-ipa.c: Rename gdb_agent_get_raw_reg to get_raw_reg.
6110 * linux-amd64-ipa.c: Likewise.
6111 * linux-i386-ipa.c: Likewise.
6112 * linux-s390-ipa.c: Likewise.
6113 * tracepoint.c: IPA-export gdb_collect_ptr instead of gdb_collect,
6114 ditto for get_raw_reg_ptr, get_trace_state_variable_value_ptr,
6115 set_trace_state_variable_value_ptr.
6116 (struct ipa_sym_addresses): Likewise.
6117 (symbol_list): Likewise.
6118 (install_fast_tracepoint): Dereference gdb_collect_ptr instead of
6119 accessing gdb_collect directly.
6120 (gdb_collect_ptr_type): New typedef.
6121 (get_raw_reg_ptr_type): New typedef.
6122 (get_trace_state_variable_value_ptr_type): New typedef.
6123 (set_trace_state_variable_value_ptr_type): New typedef.
6124 (gdb_collect_ptr): New global.
6125 (get_raw_reg_ptr): New global.
6126 (get_trace_state_variable_value_ptr): New global.
6127 (set_trace_state_variable_value_ptr): New global.
6128 (get_raw_reg_func_addr): Dereference get_raw_reg_ptr instead of
6129 accessing get_raw_reg directly.
6130 (get_get_tsv_func_addr): Likewise for
6131 get_trace_state_variable_value_ptr.
6132 (get_set_tsv_func_addr): Likewise for
6133 set_trace_state_variable_value_ptr.
6134 * tracepoint.h: Rename gdb_agent_get_raw_reg to get_raw_reg.
6135
72fb5488
SM
61362016-03-30 Simon Marchi <simon.marchi@ericsson.com>
6137
6138 * tracepoint.c (cmd_qtenable_disable): Remove whitespace.
6139
28170b88
MK
61402016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
6141
6142 * remote-utils.c (look_up_one_symbol): Remove own_buf, handle 'v'
6143 packets.
6144 (relocate_instruction): Remove own_buf.
6145 * server.c (own_buf): Make global.
6146 (handle_v_requests): Make global.
6147 * server.h (own_buf): New declaration.
6148 (handle_v_requests): New prototype.
6149
f39e8743
MK
61502016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
6151
6152 PR 18377
6153 * linux-s390-low.c (add_insns): New function.
6154 (s390_emit_prologue): New function.
6155 (s390_emit_epilogue): New function.
6156 (s390_emit_add): New function.
6157 (s390_emit_sub): New function.
6158 (s390_emit_mul): New function.
6159 (s390_emit_lsh): New function.
6160 (s390_emit_rsh_signed): New function.
6161 (s390_emit_rsh_unsigned): New function.
6162 (s390_emit_ext): New function.
6163 (s390_emit_log_not): New function.
6164 (s390_emit_bit_and): New function.
6165 (s390_emit_bit_or): New function.
6166 (s390_emit_bit_xor): New function.
6167 (s390_emit_bit_not): New function.
6168 (s390_emit_equal): New function.
6169 (s390_emit_less_signed): New function.
6170 (s390_emit_less_unsigned): New function.
6171 (s390_emit_ref): New function.
6172 (s390_emit_if_goto): New function.
6173 (s390_emit_goto): New function.
6174 (s390_write_goto_address): New function.
6175 (s390_emit_litpool): New function.
6176 (s390_emit_const): New function.
6177 (s390_emit_call): New function.
6178 (s390_emit_reg): New function.
6179 (s390_emit_pop): New function.
6180 (s390_emit_stack_flush): New function.
6181 (s390_emit_zero_ext): New function.
6182 (s390_emit_swap): New function.
6183 (s390_emit_stack_adjust): New function.
6184 (s390_emit_set_r2): New function.
6185 (s390_emit_int_call_1): New function.
6186 (s390_emit_void_call_2): New function.
6187 (s390_emit_eq_goto): New function.
6188 (s390_emit_ne_goto): New function.
6189 (s390_emit_lt_goto): New function.
6190 (s390_emit_le_goto): New function.
6191 (s390_emit_gt_goto): New function.
6192 (s390_emit_ge_goto): New function.
6193 (s390x_emit_prologue): New function.
6194 (s390x_emit_epilogue): New function.
6195 (s390x_emit_add): New function.
6196 (s390x_emit_sub): New function.
6197 (s390x_emit_mul): New function.
6198 (s390x_emit_lsh): New function.
6199 (s390x_emit_rsh_signed): New function.
6200 (s390x_emit_rsh_unsigned): New function.
6201 (s390x_emit_ext): New function.
6202 (s390x_emit_log_not): New function.
6203 (s390x_emit_bit_and): New function.
6204 (s390x_emit_bit_or): New function.
6205 (s390x_emit_bit_xor): New function.
6206 (s390x_emit_bit_not): New function.
6207 (s390x_emit_equal): New function.
6208 (s390x_emit_less_signed): New function.
6209 (s390x_emit_less_unsigned): New function.
6210 (s390x_emit_ref): New function.
6211 (s390x_emit_if_goto): New function.
6212 (s390x_emit_const): New function.
6213 (s390x_emit_call): New function.
6214 (s390x_emit_reg): New function.
6215 (s390x_emit_pop): New function.
6216 (s390x_emit_stack_flush): New function.
6217 (s390x_emit_zero_ext): New function.
6218 (s390x_emit_swap): New function.
6219 (s390x_emit_stack_adjust): New function.
6220 (s390x_emit_int_call_1): New function.
6221 (s390x_emit_void_call_2): New function.
6222 (s390x_emit_eq_goto): New function.
6223 (s390x_emit_ne_goto): New function.
6224 (s390x_emit_lt_goto): New function.
6225 (s390x_emit_le_goto): New function.
6226 (s390x_emit_gt_goto): New function.
6227 (s390x_emit_ge_goto): New function.
6228 (s390_emit_ops): New function.
6229 (struct linux_target_ops): Fill in emit_ops hook.
6230
abd9baf9
MK
62312016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
6232
6233 PR 18377
6234 * Makefile.in: Add s390 IPA files.
6235 * configure.srv: Build IPA for s390.
6236 * linux-s390-ipa.c: New file.
6237 * linux-s390-low.c: New includes - inttypes.h and linux-s390-tdesc.h.
6238 (init_registers_s390_linux32): Move declaration to linux-s390-tdesc.h.
6239 (tdesc_s390_linux32): Likewise.
6240 (init_registers_s390_linux32v1): Likewise.
6241 (tdesc_s390_linux32v1): Likewise.
6242 (init_registers_s390_linux32v2): Likewise.
6243 (tdesc_s390_linux32v2): Likewise.
6244 (init_registers_s390_linux64): Likewise.
6245 (tdesc_s390_linux64): Likewise.
6246 (init_registers_s390_linux64v1): Likewise.
6247 (tdesc_s390_linux64v1): Likewise.
6248 (init_registers_s390_linux64v2): Likewise.
6249 (tdesc_s390_linux64v2): Likewise.
6250 (init_registers_s390_te_linux64): Likewise.
6251 (tdesc_s390_te_linux64): Likewise.
6252 (init_registers_s390_vx_linux64): Likewise.
6253 (tdesc_s390_vx_linux64): Likewise.
6254 (init_registers_s390_tevx_linux64): Likewise.
6255 (tdesc_s390_tevx_linux64): Likewise.
6256 (init_registers_s390x_linux64): Likewise.
6257 (tdesc_s390x_linux64): Likewise.
6258 (init_registers_s390x_linux64v1): Likewise.
6259 (tdesc_s390x_linux64v1): Likewise.
6260 (init_registers_s390x_linux64v2): Likewise.
6261 (tdesc_s390x_linux64v2): Likewise.
6262 (init_registers_s390x_te_linux64): Likewise.
6263 (tdesc_s390x_te_linux64): Likewise.
6264 (init_registers_s390x_vx_linux64): Likewise.
6265 (tdesc_s390x_vx_linux64): Likewise.
6266 (init_registers_s390x_tevx_linux64): Likewise.
6267 (tdesc_s390x_tevx_linux64): Likewise.
6268 (have_hwcap_s390_vx): New static variable.
6269 (s390_arch_setup): Fill have_hwcap_s390_vx.
6270 (s390_get_thread_area): New function.
6271 (s390_ft_entry_gpr_esa): New const.
6272 (s390_ft_entry_gpr_zarch): New const.
6273 (s390_ft_entry_misc): New const.
6274 (s390_ft_entry_fr): New const.
6275 (s390_ft_entry_vr): New const.
6276 (s390_ft_main_31): New const.
6277 (s390_ft_main_64): New const.
6278 (s390_ft_exit_fr): New const.
6279 (s390_ft_exit_vr): New const.
6280 (s390_ft_exit_misc): New const.
6281 (s390_ft_exit_gpr_esa): New const.
6282 (s390_ft_exit_gpr_zarch): New const.
6283 (append_insns): New function.
6284 (s390_relocate_instruction): New function.
6285 (s390_install_fast_tracepoint_jump_pad): New function.
6286 (s390_get_min_fast_tracepoint_insn_len): New function.
6287 (s390_get_ipa_tdesc_idx): New function.
6288 (struct linux_target_ops): Wire in the above functions.
6289 (initialize_low_arch) [!__s390x__]: Don't initialize s390x tdescs.
6290 * linux-s390-tdesc.h: New file.
6291
a4105d04
MK
62922016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
6293
6294 * linux-s390-low.c (s390_supports_tracepoints): New function.
6295 (struct linux_target_ops): Fill supports_tracepoints hook.
6296
35ac8b3e
YQ
62972016-03-18 Yao Qi <yao.qi@linaro.org>
6298
6299 * linux-low.c (lwp_signal_can_be_delivered): New function.
6300 (linux_resume_one_lwp_throw): Use lwp_signal_can_be_delivered.
6301
94610ec4
YQ
63022016-03-18 Yao Qi <yao.qi@linaro.org>
6303
6304 * linux-low.c (linux_resume_one_lwp_throw): Set 'signal' to
6305 0 if signal is enqueued. Remove 'signal' from one debugging
6306 message. Move one debugging message to some lines below.
6307 Remove code setting 'signal' to 0.
6308
80aea927
YQ
63092016-03-18 Yao Qi <yao.qi@linaro.org>
6310
6311 * linux-low.c (linux_low_filter_event): Remove redundant
6312 WIFSTOPPED check together with linux_wstatus_maybe_breakpoint.
6313
b04fd3be
MK
63142016-03-09 Marcin Kościelnicki <koriakin@0x04.net>
6315
6316 * linux-ppc-low.c (ppc_supports_tracepoints): New function.
6317 (struct linux_target_ops): Wire in the above.
6318
c40c8d4b
YQ
63192016-03-03 Yao Qi <yao.qi@linaro.org>
6320
6321 * linux-low.c: Update comments to start_step_over.
6322
0f8288ae
YQ
63232016-03-03 Yao Qi <yao.qi@linaro.org>
6324
6325 PR server/19736
6326 * linux-low.c (handle_extended_wait): Set child suspended
6327 if event_lwp->bp_reinsert isn't zero.
6328
fdbd04a8
YQ
63292016-03-02 Yao Qi <yao.qi@linaro.org>
6330
6331 * linux-low.c (linux_resume_one_lwp_throw): Replace code with
6332 enqueue_pending_signal.
6333
6896a8fa
MK
63342016-03-02 Marcin Kościelnicki <koriakin@0x04.net>
6335
6336 * tracepoint.c (cmd_qtstart): Only set ipa_tdesc_idx if agent
6337 is actually loaded.
6338
ab503087
MK
63392016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
6340
6341 * linux-s390-low.c (s390_num_regs_3264): Define on 31-bit too.
6342 (s390_regmap_3264) [!__s390x__]: New global.
6343 (s390_collect_ptrace_register): Skip map entries containing -1.
6344 (s390_supply_ptrace_register): Ditto.
6345 (s390_fill_gprs_high): New function.
6346 (s390_store_gprs_high): New function.
6347 (s390_regsets): Add NT_S390_HIGH_GPRS.
6348 (s390_get_hwcap): Enable on 31-bit.
6349 (have_hwcap_s390_high_gprs): Enable on 31-bit.
6350 (s390_arch_setup): Enable detection of high GPRs, TDB, VX on 31-bit.
6351 Detect NT_S390_HIGH_GPRS.
6352 (s390_usrregs_info_3264): Enable on 31-bit.
6353 (s390_regs_info): Enable regs_info_3264 on 31-bit.
6354 (initialize_low_arch): Initialize s390_regsets_info_3264 on 31-bit.
6355
ae91f625
MK
63562016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
6357
6358 PR gdb/13808
6359 * Makefile.in: Add i386-*-linux-ipa.o and amd64-*-linux-ipa.o.
6360 * configure.srv: Ditto.
6361 * linux-aarch64-ipa.c (get_ipa_tdesc): New function.
6362 (initialize_low_tracepoint): Remove ipa_tdesc assignment.
6363 * linux-amd64-ipa.c: Add "linux-x86-tdesc.h" include.
6364 (init_registers_amd64_linux): Remove prototype.
6365 (tdesc_amd64_linux): Remove declaration.
6366 (get_ipa_tdesc): New function.
6367 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
6368 initialize remaining tdescs.
6369 * linux-i386-ipa.c: Add "linux-x86-tdesc.h" include.
6370 (init_registers_i386_linux): Remove prototype.
6371 (tdesc_i386_linux): Remove declaration.
6372 (get_ipa_tdesc): New function.
6373 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
6374 initialize remaining tdescs.
6375 * linux-low.c (linux_get_ipa_tdesc_idx): New function.
6376 (linux_target_ops): wire in linux_get_ipa_tdesc_idx.
6377 * linux-low.h (struct linux_target_ops): Add get_ipa_tdesc_idx.
6378 * linux-x86-low.c: Move tdesc declarations to linux-x86-tdesc.h.
6379 (x86_get_ipa_tdesc_idx): New function.
6380 (the_low_target): Wire in x86_get_ipa_tdesc_idx.
6381 * linux-x86-tdesc.h: New file.
6382 * target.h (struct target_ops): Add get_ipa_tdesc_idx.
6383 (target_get_ipa_tdesc_idx): New macro.
6384 * tracepoint.c (ipa_tdesc_idx): New macro.
6385 (struct ipa_sym_addresses): Add addr_ipa_tdesc_idx.
6386 (symbol_list): Add ipa_tdesc_idx.
6387 (cmd_qtstart): Write ipa_tdesc_idx in the target.
6388 (ipa_tdesc): Remove.
6389 (ipa_tdesc_idx): New variable.
6390 (get_context_regcache): Use get_ipa_tdesc.
6391 (gdb_collect): Ditto.
6392 (gdb_probe): Ditto.
6393 * tracepoint.h (get_ipa_tdesc): New prototype.
6394 (ipa_tdesc): Remove.
6395
e7ad2f14
PA
63962016-02-24 Pedro Alves <palves@redhat.com>
6397
6398 * linux-low.c (check_stopped_by_breakpoint): Rename to ...
6399 (save_stop_reason): ... this. Use GDB_ARCH_IS_TRAP_HWBKPT and
6400 handle ambiguous GDB_ARCH_IS_TRAP_BRKPT / GDB_ARCH_IS_TRAP_HWBKPT.
6401 Factor out common code between the USE_SIGTRAP_SIGINFO and
6402 !USE_SIGTRAP_SIGINFO blocks.
6403 (linux_low_filter_event): Call save_stop_reason instead of
6404 check_stopped_by_breakpoint and check_stopped_by_watchpoint.
6405 Update comments.
6406 (linux_wait_1): Update comments.
6407
657f9cde
WW
64082016-02-24 Wei-cheng Wang <cole945@gmail.com>
6409
6410 * linux-ppc-low.c (ppc_supports_z_point_type): New function:
6411 (ppc_insert_point, ppc_remove_point): Insert/remove z-packet breakpoints.
6412 (ppc64_emit_ops_vector): Add target ops - ppc_supports_z_point_type,
6413 ppc_insert_point, ppc_remove_point.
6414
b00b61e1
MK
64152016-02-17 Marcin Kościelnicki <koriakin@0x04.net>
6416
6417 * linux-s390-low.c (s390_supports_z_point_type): New function.
6418 (struct linux_target_ops): Wire s390_supports_z_point_type in.
6419
553cb527
YQ
64202016-02-16 Yao Qi <yao.qi@linaro.org>
6421
6422 * linux-arm-low.c (get_next_pcs_syscall_next_pc): Remove argument
6423 PC. Get pc from regcache_read_pc.
6424
a5652c21
YQ
64252016-02-12 Yao Qi <yao.qi@linaro.org>
6426
6427 * linux-aarch64-low.c (aarch64_get_pc): Call linux_get_pc_64bit
6428 or linux_get_pc_32bit.
6429 (aarch64_set_pc): Call linux_set_pc_64bit or linux_set_pc_32bit.
6430
ed443b61
YQ
64312016-02-12 Yao Qi <yao.qi@linaro.org>
6432
6433 * linux-arm-low.c (get_next_pcs_ops): Initialize it with
6434 arm_linux_get_next_pcs_fixup.
6435
020ecd38
MK
64362016-02-12 Marcin Kościelnicki <koriakin@0x04.net>
6437
6438 * tracepoint.c (x_tracepoint_action_download): Change
6439 write_inferior_data_ptr to write_inferior_data_pointer.
6440 (cmd_qtstart): Likewise.
6441 (write_inferior_data_ptr): Remove.
6442 (download_agent_expr): Change write_inferior_data_ptr to
6443 write_inferior_data_pointer.
6444 (download_tracepoint_1): Likewise.
6445 (download_tracepoint): Likewise.
6446 (download_trace_state_variables): Likewise.
6447
7cae9051
WW
64482016-02-11 Wei-cheng Wang <cole945@gmail.com>
6449 Marcin Kościelnicki <koriakin@0x04.net>
6450
6451 * tracepoint.c (struct tracepoint_action_ops): Remove.
6452 (struct tracepoint_action): Remove ops.
6453 (m_tracepoint_action_download, r_tracepoint_action_download)
6454 (x_tracepoint_action_download, l_tracepoint_action_download): Adjust
6455 size and offset accordingly.
6456 (m_tracepoint_action_ops, r_tracepoint_action_ops)
6457 (x_tracepoint_action_ops, l_tracepoint_action_ops): Remove.
6458 (tracepoint_action_send, tracepoint_action_download): New functions.
6459 Helpers for trace action handlers.
6460 (add_tracepoint_action): Remove setup actions ops.
6461 (download_tracepoint_1, tracepoint_send_agent): Call helper functions.
6462
9f6a71b4
YQ
64632016-02-10 Yao Qi <yao.qi@linaro.org>
6464
6465 * regcache.c (regcache_raw_read_unsigned): Clear *VAL.
6466
1e94266c
SM
64672016-02-09 Simon Marchi <simon.marchi@ericsson.com>
6468
6469 * configure.ac: Use AC_CONFIG_FILES instead of passing arguments
6470 to AC_OUTPUT.
6471 * configure: Regenerate.
6472
8adce034
SM
64732016-02-09 Simon Marchi <simon.marchi@ericsson.com>
6474
6475 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): Change
6476 void * to gdb_byte *.
6477 * linux-low.c (siginfo_fixup): Likewise.
6478 (linux_xfer_siginfo): Likewise.
6479 * linux-low.h (struct linux_target_ops) <siginfo_fixup>:
6480 Likewise.
6481 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
6482
93813b37
WT
64832016-02-02 Walfred Tedeschi <walfred.tedeschi@intel.com>
6484
6485 * configure.srv (x86_64-*-linux*): Add amd64-linux-siginfo.o
6486 to srv_tgtobj.
6487 (i[34567]86-*-linux*): Add amd64-linux-siginfo.o
6488 to srv_tgtobj.
6489 * linux-x86-low.c [__x86_64__]: Include
6490 "nat/amd64-linux-siginfo.h".
6491 (compat_siginfo_from_siginfo, siginfo_from_compat_siginfo)
6492 (compat_x32_siginfo_from_siginfo, siginfo_from_compat_x32_siginfo)
6493 (compat_timeval, compat_sigval, compat_x32_clock, cpt_si_pid)
6494 (cpt_si_uid, cpt_si_timerid, cpt_si_overrun, cpt_si_status)
6495 (cpt_si_utime, cpt_si_stime, cpt_si_ptr, cpt_si_addr, cpt_si_band)
6496 (cpt_si_fd, si_timerid, si_overrun): Move from
6497 nat/amd64-linux-siginfo.c.
6498 * Makefile.in (amd64-linux-siginfo.o:): New rule.
6499
8424cc97
SM
65002016-01-28 Simon Marchi <simon.marchi@ericsson.com>
6501
6502 * server.c (skip_to_semicolon): Remove.
6503 (process_point_options): Use strchrnul instead of
6504 skip_to_semicolon.
6505
4d18591b
YQ
65062016-01-26 Yao Qi <yao.qi@linaro.org>
6507
6508 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Remove argument pc.
6509 * linux-low.c (install_software_single_step_breakpoints): Don't
6510 call regcache_read_pc.
6511 * linux-low.h (struct linux_target_ops) <get_next_pcs>: Remove
6512 argument pc.
6513
d8020970
YQ
65142016-01-26 Yao Qi <yao.qi@linaro.org>
6515
6516 * linux-low.c (install_software_single_step_breakpoints): Call
6517 regcache_read_pc instead of get_pc.
6518
8b207339
YQ
65192016-01-26 Yao Qi <yao.qi@linaro.org>
6520
6521 * remote-utils.c (remote_close) [!USE_WIN32API]: Ignore SIGIO.
6522 (unblock_async_io): Rename to ...
6523 (block_unblock_async_io): ... it. New function.
6524 (enable_async_io): Don't install SIGIO handler. Unblock it
6525 instead.
6526 (disable_async_io): Don't ignore SIGIO. Block it instead.
6527 (initialize_async_io): Install SIGIO handler. Don't call
6528 unblock_async_io.
6529
18879fef
YQ
65302016-01-26 Yao Qi <yao.qi@linaro.org>
6531
6532 * remote-utils.c (getpkt): If the buffer isn't empty, and the
6533 first character is '\003', call *the_target->request_interrupt.
6534
a0f8e08a
YQ
65352016-01-25 Yao Qi <yao.qi@linaro.org>
6536
6537 * remote-utils.c (new_thread_notify): Remove.
6538 (dead_thread_notify): Likewise.
6539 * remote-utils.h (new_thread_notify): Remove declaration.
6540 (dead_thread_notify): Likewise.
6541
cc5fd9ab
MK
65422016-01-23 Marcin Kościelnicki <koriakin@0x04.net>
6543
6544 * gdb.trace/pending.exp: Fix expected message on continue.
6545
99e8eb11
MK
65462016-01-22 Marcin Kościelnicki <koriakin@0x04.net>
6547
6548 * tracepoint.c (write_inferior_data_ptr): Cast to uintptr_t, so that
6549 it works properly on big-endian machines where sizeof (CORE_ADDR)
6550 != sizeof (void *).
6551
a994041d
PA
65522016-01-21 Pedro Alves <palves@redhat.com>
6553
6554 * Makefile.in (COMPILER_CFLAGS, CXXFLAGS): New.
6555 (INTERNAL_CFLAGS_BASE): Use COMPILER_CFLAGS instead of CFLAGS.
6556 * configure: Regenerate.
6557
f7a6a40d
YQ
65582016-01-21 Yao Qi <yao.qi@linaro.org>
6559
6560 * linux-arm-low.c (arm_sigreturn_next_pc): Add parameter
6561 is_thumb and set it according to CPSR saved on the stack.
6562 (get_next_pcs_syscall_next_pc): Pass is_thumb to
6563 arm_sigreturn_next_pc.
6564
6f69e520
YQ
65652016-01-18 Yao Qi <yao.qi@linaro.org>
6566
6567 * linux-low.c (linux_set_pc_64bit): New function.
6568 (linux_get_pc_64bit): New function.
6569 * linux-low.h (linux_set_pc_64bit, linux_get_pc_64bit):
6570 Declare.
6571 * linux-sparc-low.c (debug_threads): Remove declaration.
6572 (sparc_get_pc): Remove.
6573 (the_low_target): Use linux_get_pc_64bit instead of
6574 sparc_get_pc.
6575 * linux-tile-low.c (tile_get_pc, tile_set_pc): Remove.
6576 (the_low_target): Use linux_get_pc_64bit and
6577 linux_set_pc_64bit.
6578
276d4552
YQ
65792016-01-18 Yao Qi <yao.qi@linaro.org>
6580
6581 * linux-arm-low.c (debug_threads): Remove declaration.
6582 (arm_get_pc, arm_set_pc): Remove.
6583 (the_low_target): Use linux_get_pc_32bit and
6584 linux_set_pc_32bit.
6585 * linux-bfin-low.c (bfin_get_pc, bfin_set_pc): Remove.
6586 (the_low_target): Use linux_get_pc_32bit and
6587 linux_set_pc_32bit.
6588 * linux-cris-low.c (debug_threads): Remove declaration.
6589 (cris_get_pc, cris_set_pc,): Remove.
6590 (the_low_target): Use linux_get_pc_32bit and
6591 linux_set_pc_32bit.
6592 * linux-crisv32-low.c (debug_threads): Remove declaration.
6593 (cris_get_pc, cris_set_pc): Remove.
6594 (the_low_target): Use linux_get_pc_32bit and
6595 linux_set_pc_32bit.
6596 * linux-low.c: Include inttypes.h.
6597 (linux_get_pc_32bit, linux_set_pc_32bit): New functions.
6598 * linux-low.h (linux_get_pc_32bit, linux_set_pc_32bit): Declare.
6599 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Remove.
6600 (the_low_target): Use linux_get_pc_32bit and
6601 linux_set_pc_32bit.
6602 * linux-m68k-low.c (m68k_get_pc, m68k_set_pc): Remove.
6603 (the_low_target): Use linux_get_pc_32bit and
6604 linux_set_pc_32bit.
6605 * linux-nios2-low.c (nios2_get_pc, nios2_set_pc): Remove.
6606 (the_low_target): Use linux_get_pc_32bit and
6607 linux_set_pc_32bit.
6608 * linux-sh-low.c (sh_get_pc, sh_set_pc): Remove.
6609 (the_low_target): Use linux_get_pc_32bit and
6610 linux_set_pc_32bit.
6611 * linux-xtensa-low.c (xtensa_get_pc, xtensa_set_pc): Remove.
6612 (the_low_target): Use linux_get_pc_32bit and
6613 linux_set_pc_32bit.
6614
eb0edac8
GB
66152016-01-18 Gary Benson <gbenson@redhat.com>
6616
6617 * configure.ac (AC_FUNC_FORK): New check.
6618 * config.in: Regenerate.
6619 * configure: Likewise.
6620
1b451dda
YQ
66212016-01-14 Yao Qi <yao.qi@linaro.org>
6622
6623 * linux-aarch32-low.c (thumb2_breakpoint): Make it static.
6624 * linux-aarch32-low.h (thumb2_breakpoint): Remove declaration.
6625 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Pass 1 to
6626 arm_get_next_pcs_ctor.
6627
82075af2
JS
66282016-01-12 Josh Stone <jistone@redhat.com>
6629 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6630
6631 * inferiors.h: Include "gdb_vecs.h".
6632 (struct process_info): Add syscalls_to_catch.
6633 * inferiors.c (remove_process): Free syscalls_to_catch.
6634 * remote-utils.c (prepare_resume_reply): Report syscall_entry and
6635 syscall_return stops.
6636 * server.h (UNKNOWN_SYSCALL, ANY_SYSCALL): Define.
6637 * server.c (handle_general_set): Handle QCatchSyscalls.
6638 (handle_query): Report support for QCatchSyscalls.
6639 * target.h (struct target_ops): Add supports_catch_syscall.
6640 (target_supports_catch_syscall): New macro.
6641 * linux-low.h (struct linux_target_ops): Add get_syscall_trapinfo.
6642 (struct lwp_info): Add syscall_state.
6643 * linux-low.c (handle_extended_wait): Mark syscall_state as an entry.
6644 Maintain syscall_state and syscalls_to_catch across exec.
6645 (get_syscall_trapinfo): New function, proxy to the_low_target.
6646 (linux_low_ptrace_options): Enable PTRACE_O_TRACESYSGOOD.
6647 (linux_low_filter_event): Toggle syscall_state entry/return for
6648 syscall traps, and set it ignored for all others.
6649 (gdb_catching_syscalls_p): New function.
6650 (gdb_catch_this_syscall_p): New function.
6651 (linux_wait_1): Handle SYSCALL_SIGTRAP.
6652 (linux_resume_one_lwp_throw): Add PTRACE_SYSCALL possibility.
6653 (linux_supports_catch_syscall): New function.
6654 (linux_target_ops): Install it.
6655 * linux-x86-low.c (x86_get_syscall_trapinfo): New function.
6656 (the_low_target): Install it.
6657
8f13a3ce
MF
66582016-01-12 Mike Frysinger <vapier@gentoo.org>
6659
6660 * acinclude.m4: Include new ../warning.m4 file.
6661 * configure: Regenerated.
6662 * configure.ac: Replace all warning logic with AM_GDB_WARNINGS.
6663
5b3da067
MF
66642016-01-12 Mike Frysinger <vapier@gentoo.org>
6665
6666 * ax.c (is_goto_target): Mark static.
6667 * linux-low.c (register_addr): Likewise.
6668 (linux_fetch_registers, linux_store_registers): Likewise.
6669 * mem-break.c (any_persistent_commands): Fix old prototype.
6670 (add_commands_to_breakpoint): Mark static.
6671 * regcache.c (find_register_by_name): Delete unused func.
6672 * remote-utils.c (hex_or_minus_one): Mark static.
6673 * server.c (monitor_show_help): Mark static.
6674 (handle_query, handle_v_cont, handle_v_attach, handle_v_kill,
6675 handle_v_requests): Likewise.
6676
bc504a31
PA
66772016-01-12 Pedro Alves <palves@redhat.com>
6678
6679 Remove use of the registered trademark symbol throughout.
6680
5a0dd67a
YQ
66812016-01-08 Yao Qi <yao.qi@linaro.org>
6682
6683 * remote-utils.c (getpkt): If c is '\003', call target hook
6684 request_interrupt.
6685
b2ca446f
YQ
66862016-01-06 Yao Qi <yao.qi@linaro.org>
6687
6688 * linux-aarch32-low.h (arm_abi_breakpoint): Move to
6689 linux-aarch32-low.c.
6690 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
6691 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
6692 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
6693 (thumb2_breakpoint): Declare.
6694 * linux-aarch32-low.c (arm_abi_breakpoint): Moved from
6695 linux-aarch32-low.h.
6696 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
6697 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
6698 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
6699
edd88788
JB
67002016-01-01 Joel Brobecker <brobecker@adacore.com>
6701
6702 * gdbreplay.c (gdbreplay_version): Change copyright year in
6703 version message.
6704 * server.c (gdbserver_version): Likewise.
6705
65da7f14
PP
67062015-12-28 Patrick Palka <patrick@parcs.ath.cx>
6707
6708 * server.c (crc32_table): Delete.
6709 (crc32): Use libiberty's xcrc32 function.
6710
4abd5ed2
JB
67112015-12-22 Joel Brobecker <brobecker@adacore.com>
6712
6713 * lynx-low.c (lynx_delete_thread_callback): New function.
6714 (lynx_mourn): Properly delete our process and all of its
6715 threads. Remove call to clear_inferiors.
6716
0e50fe5c
JB
67172015-12-22 Joel Brobecker <brobecker@adacore.com>
6718
6719 * target.c (thread_search_callback): Add check that
6720 the thread_stopped target callback is not NULL before
6721 calling it.
6722
35adc03f
YQ
67232015-12-21 Yao Qi <yao.qi@linaro.org>
6724
6725 * linux-aarch32-low.h [__aarch64__]: Use arm_abi_breakpoint
6726 arm breakpoint.
6727
bd2b2909
AT
67282015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
6729
6730 * server.c (handle_query): Call target_supports_software_single_step.
6731
7fe5e27e
AT
67322015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
6733
6734 * linux-low.c (single_step): New function.
6735 (linux_resume_one_lwp_throw): Call single_step.
6736 (start_step_over): Likewise.
6737
d9311bfa
AT
67382015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
6739
6740 * Makefile.in (SFILES): Append arch/arm-linux.c,
6741 arch/arm-get-next-pcs.c.
6742 (arm-linux.o): New rule.
6743 (arm-get-next-pcs.o): New rule.
6744 * configure.srv (arm*-*-linux*): Add arm-get-next-pcs.o,
6745 arm-linux.o.
6746 * linux-aarch32-low.c (arm_abi_breakpoint): Remove macro. Moved
6747 to linux-aarch32-low.c.
6748 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
6749 (arm_breakpoint_len, thumb_breakpoint): Likewise.
6750 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
6751 (thumb2_breakpoint_len): Likewise.
6752 (arm_is_thumb_mode): Make non-static.
6753 * linux-aarch32-low.h (arm_abi_breakpoint): New macro. Moved
6754 from linux-aarch32-low.c.
6755 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
6756 (arm_breakpoint_len, thumb_breakpoint): Likewise.
6757 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
6758 (thumb2_breakpoint_len): Likewise.
6759 (arm_is_thumb_mode): New declaration.
6760 * linux-arm-low.c: Include arch/arm-linux.h
6761 aarch/arm-get-next-pcs.h, sys/syscall.h.
6762 (get_next_pcs_ops): New struct.
6763 (get_next_pcs_addr_bits_remove): New function.
6764 (get_next_pcs_is_thumb): New function.
6765 (get_next_pcs_read_memory_unsigned_integer): Likewise.
6766 (arm_sigreturn_next_pc): Likewise.
6767 (get_next_pcs_syscall_next_pc): Likewise.
6768 (arm_gdbserver_get_next_pcs): Likewise.
6769 (struct linux_target_ops) <arm_gdbserver_get_next_pcs>:
6770 Initialize.
6771 * linux-low.h: Move CORE_ADDR vector definition to gdb_vecs.h.
6772 * server.h: Include gdb_vecs.h.
6773
68ce2059
AT
67742015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
6775
6776 * Makefile.in (SFILES): Append common/common-regcache.c.
6777 (OBS): Append common-regcache.o.
6778 (common-regcache.o): New rule.
6779 * regcache.c (init_register_cache): Initialize cache to
6780 REG_UNAVAILABLE.
6781 (regcache_raw_read_unsigned): New function.
6782 * regcache.h (REG_UNAVAILABLE, REG_VALID): Replaced by shared
6783 register_status enum.
6784
fa5308bd
AT
67852015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
6786
6787 * linux-aarch64-low.c (the_low_targets): Rename
6788 breakpoint_reinsert_addr to get_next_pcs.
6789 * linux-arm-low.c (the_low_targets): Likewise.
6790 * linux-bfin-low.c (the_low_targets): Likewise.
6791 * linux-cris-low.c (the_low_targets): Likewise.
6792 * linux-crisv32-low.c (the_low_targets): Likewise.
6793 * linux-low.c (can_software_single_step): Likewise.
6794 (install_software_single_step_breakpoints): New function.
6795 (start_step_over): Use install_software_single_step_breakpoints.
6796 * linux-low.h: New CORE_ADDR vector.
6797 (struct linux_target_ops) Rename breakpoint_reinsert_addr to
6798 get_next_pcs.
6799 * linux-mips-low.c (the_low_targets): Likewise.
6800 * linux-nios2-low.c (the_low_targets): Likewise.
6801 * linux-sparc-low.c (the_low_targets): Likewise.
6802
4a6ed09b
PA
68032015-12-17 Pedro Alves <palves@redhat.com>
6804
6805 * linux-low.c (linux_kill_one_lwp): Remove references to
6806 LinuxThreads.
6807 (kill_lwp): Remove HAVE_TKILL_SYSCALL check. No longer fall back
6808 to 'kill'.
6809 (linux_init_signals): Delete.
6810 (initialize_low): Adjust.
6811 * thread-db.c (thread_db_init): Remove LinuxThreads reference.
6812
7544db95
PA
68132015-12-16 Pedro Alves <palves@redhat.com>
6814
6815 * configure.ac (compiler warning flags): When testing a
6816 -Wno-foo option, check whether -Wfoo works instead.
6817 * configure: Regenerate.
6818
8020350c
DB
68192015-12-11 Don Breazeal <donb@codesourcery.com>
6820
6821 * server.c (process_serial_event): Don't exit from gdbserver
6822 in remote mode if there are still active inferiors.
6823
db91f502
YQ
68242015-12-11 Yao Qi <yao.qi@linaro.org>
6825
6826 * linux-aarch64-low.c (aarch64_breakpoint_at): Call
6827 arm_breakpoint_at if the process is 32-bit.
6828
b37a6290
YQ
68292015-12-11 Yao Qi <yao.qi@linaro.org>
6830
6831 * linux-aarch32-low.c [__aarch64__]: Use arm_abi_breakpoint
6832 arm breakpoint.
6833
17b1509a
YQ
68342015-12-07 Yao Qi <yao.qi@linaro.org>
6835
6836 * configure.srv: Append arm.o to srv_tgtobj for
6837 aarch64*-*-linux* target.
6838 * linux-aarch32-low.c (arm_abi_breakpoint): New macro. Moved
6839 from linux-arm-low.c.
6840 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
6841 (arm_breakpoint_len, thumb_breakpoint): Likewise.
6842 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
6843 (thumb2_breakpoint_len): Likewise.
6844 (arm_is_thumb_mode, arm_breakpoint_at): Likewise.
6845 (arm_breakpoint_kinds): Likewise.
6846 (arm_breakpoint_kind_from_pc): Likewise.
6847 (arm_sw_breakpoint_from_kind): Likewise.
6848 (arm_breakpoint_kind_from_current_state): Likewise.
6849 * linux-aarch32-low.h (arm_breakpoint_kind_from_pc): Declare.
6850 (arm_sw_breakpoint_from_kind): Declare.
6851 (arm_breakpoint_kind_from_current_state): Declare.
6852 (arm_breakpoint_at): Declare.
6853 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): Call
6854 arm_sw_breakpoint_from_kind if process is 32-bit.
6855 (aarch64_breakpoint_kind_from_pc): New function.
6856 (aarch64_breakpoint_kind_from_current_state): New function.
6857 (the_low_target): Initialize fields breakpoint_kind_from_pc
6858 and breakpoint_kind_from_current_state.
6859 * linux-arm-low.c (arm_breakpoint_kinds): Move to
6860 linux-aarch32-low.c.
6861 (arm_abi_breakpoint, arm_eabi_breakpoint): Likewise.
6862 (arm_breakpoint, arm_breakpoint_len): Likewise.
6863 (thumb_breakpoint, thumb_breakpoint_len): Likewise.
6864 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
6865 (arm_is_thumb_mode): Likewise.
6866 (arm_breakpoint_at): Likewise.
6867 (arm_breakpoint_kind_from_pc): Likewise.
6868 (arm_sw_breakpoint_from_kind): Likewise.
6869 (arm_breakpoint_kind_from_current_state): Likewise.
6870
6871 Revert:
6872 2015-08-04 Yao Qi <yao.qi@linaro.org>
6873
6874 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
6875 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
6876 * server.c (extended_protocol): Remove "static".
6877 * server.h (extended_protocol): Declare it.
6878
ece66d65
JS
68792015-12-04 Josh Stone <jistone@redhat.com>
6880
6881 * target.h (struct target_ops) <arch_setup>: Rename to ...
6882 (struct target_ops) <post_create_inferior>: ... this.
6883 (target_arch_setup): Rename to ...
6884 (target_post_create_inferior): ... this, calling post_create_inferior.
6885 * server.c (start_inferior): Update target_arch_setup calls to
6886 target_post_create_inferior.
6887 * linux-low.c (linux_low_ptrace_options): Forward declare.
6888 (linux_arch_setup): Update its comment for general use.
6889 (linux_post_create_inferior): New, run arch_setup and setup ptrace.
6890 (struct linux_target_ops): Use linux_post_create_inferior.
6891 * lynx-low.c (struct lynx_target_ops): Update arch_setup stub comment
6892 to post_create_inferior.
6893 * nto-low.c (struct nto_target_ops): Likewise.
6894 * spu-low.c (struct spu_target_ops): Likewise.
6895 * win32-low.c (struct win32_target_ops): Likewise.
6896
e58c48b4
AT
68972015-12-03 Antoine Tremblay <antoine.tremblay@ericsson.com>
6898
6899 * linux-arm-low.c: Remove duplicate arch/arm.h include.
6900
fbec8956
AT
69012015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
6902
6903 * linux-arm-low.c (arm_reinsert_addr): Remove function.
6904 (struct linux_target_ops <breakpoint_reinsert_addr>: Set to NULL.
6905 * linux-cris-low.c (cris_reinsert_addr> Remove function.
6906 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
6907 * linux-crisv32-low.c (cris_reinsert_addr): Remove function.
6908 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
6909 * linux-mips-low.c (mips_reinsert_addr): Remove function.
6910 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
6911 * linux-nios2-low.c (nios2_reinsert_addr): Remove function.
6912 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
6913 * linux-sparc-low.c (sparc_reinsert_addr): Remove function.
6914 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
6915
9b4c5f87
AT
69162015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
6917
6918 * linux-low.c (linux_look_up_symbols): Don't call
6919 linux_supports_traceclone.
6920 * linux-low.h (thread_db_init): Remove use_events argument.
6921 * thread-db.c (thread_db_use_event): Remove global variable.
6922 (struct thread_db) <td_thr_event_enable_p>: Remove field.
6923 (struct thread_db) <td_create_bp>: Remove field.
6924 (thread_db_create_event): Remove function.
6925 (thread_db_enable_reporting): Likewise.
6926 (find_one_thread): Don't check for thread_db_use_events.
6927 (attach_thread): Likewise.
6928 (thread_db_load_search): Remove td_thr_event_enable_p initialization.
6929 (try_thread_db_load_1): Don't check for thread_db_use_events.
6930 (thread_db_init): Remove use_events argument and thread events
6931 handling.
6932 (remove_thread_event_breakpoints): Remove function.
6933 (thread_db_detach): Remove call to remove_thred_event_breakpoints.
6934
7d00775e
AT
69352015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
6936
6937 * linux-aarch64-low.c (aarch64_supports_hardware_single_step):
6938 New function.
6939 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6940 * linux-arm-low.c (arm_supports_hardware_single_step): New function.
6941 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6942 * linux-bfin-low.c (bfin_supports_hardware_single_step): New function.
6943 (struct linux_target_ops) <bfin_supports_hardware_single_step>:
6944 Initialize.
6945 * linux-crisv32-low.c (cris_supports_hardware_single_step):
6946 New function.
6947 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6948 * linux-low.c (can_hardware_single_step): Use
6949 supports_hardware_single_step.
6950 (can_software_single_step): New function.
6951 (start_step_over): Call can_software_single_step.
6952 (linux_supports_hardware_single_step): New function.
6953 (struct target_ops) <supports_software_single_step>: Initialize.
6954 * linux-low.h (struct linux_target_ops)
6955 <supports_hardware_single_step>: Initialize.
6956 * linux-m32r-low.c (m32r_supports_hardware_single_step): New function.
6957 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6958 * linux-ppc-low.c (ppc_supports_hardware_single_step): New function.
6959 (struct linux_target_ops) <supports_hardware_single_step> Initialize.
6960 * linux-s390-low.c (s390_supports_hardware_single_step): New function.
6961 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6962 * linux-sh-low.c (sh_supports_hardware_single_step): New function.
6963 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6964 * linux-tic6x-low.c (tic6x_supports_hardware_single_step): New function.
6965 (struct linux_target_ops) <tic6x_supports_hardware_single_step>:
6966 Initialize.
6967 * linux-tile-low.c (tile_supports_hardware_single_step): New function.
6968 (struct linux_target_ops) <tile_supports_hardware_single_step>:
6969 Initialize.
6970 * linux-x86-low.c (x86_supports_hardware_single_step) New function.
6971 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6972 * linux-xtensa-low.c (xtensa_supports_hardware_single_step):
6973 New function.
6974 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6975 * target.h (struct target_ops): <supports_software_single_step>:
6976 New field.
6977 (target_supports_software_single_step): New macro.
6978
2d97cd35
AT
69792015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
6980
6981 * linux-low.c (linux_wait_1): Fix pc advance condition.
6982 * mem-break.c (reinsert_breakpoint_inserted_here): New function.
6983 * mem-break.h (reinsert_breakpoint_inserted_here): New declaration.
6984
769ef81f
AT
69852015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
6986
6987 * linux-arm-low.c (arm_is_thumb_mode): New function.
6988 (arm_breakpoint_at): Use arm_is_thumb_mode.
6989 (arm_breakpoint_kind_from_current_state): New function.
6990 (struct linux_target_ops) <breakpoint_kind_from_current_state>:
6991 Initialize.
6992 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_current_state.
6993 (linux_breakpoint_kind_from_current_state): New function.
6994 (struct target_ops <breakpoint_kind_from_current_state>: Initialize.
6995 * linux-low.h (struct linux_target_ops)
6996 <breakpoint_kind_from_current_state>: New field.
6997 * target.h (struct target_ops): Likewise.
6998 (target_breakpoint_kind_from_current_state): New macro.
6999
1bebeeca
PA
70002015-11-30 Pedro Alves <palves@redhat.com>
7001
7002 * linux-low.c (linux_resume): Wake up the event loop before
7003 returning.
7004
a67a9fae
PA
70052015-11-30 Pedro Alves <palves@redhat.com>
7006
7007 * mem-break.c (check_gdb_bp_preconditions): Remove current_thread
7008 check.
7009 (set_gdb_breakpoint): If prepare_to_access_memory fails, set *ERR
7010 to -1.
7011 * target.c (struct thread_search): New structure.
7012 (thread_search_callback): New function.
7013 (prev_general_thread): New global.
7014 (prepare_to_access_memory, done_accessing_memory): New functions.
7015 * target.h (prepare_to_access_memory, done_accessing_memory):
7016 Replace macros with function declarations.
7017
f2faf941
PA
70182015-11-30 Pedro Alves <palves@redhat.com>
7019
7020 PR 14618
7021 * linux-low.c (linux_wait_1): If the last resumed thread is gone,
7022 report TARGET_WAITKIND_NO_RESUMED.
7023 * remote-utils.c (prepare_resume_reply): Handle
7024 TARGET_WAITKIND_NO_RESUMED.
7025 * server.c (report_no_resumed): New global.
7026 (handle_query) <qSupported>: Handle "no-resumed+". Report
7027 "no-resumed+" support.
7028 (resume): When the target reports TARGET_WAITKIND_NO_RESUMED, only
7029 return error if the client doesn't support no-resumed events.
7030 (push_stop_notification): New function.
7031 (handle_target_event): Use it. Report TARGET_WAITKIND_NO_RESUMED
7032 events if the client supports them.
7033
a681f9c9
PA
70342015-11-30 Pedro Alves <palves@redhat.com>
7035
7036 * linux-low.c (thread_still_has_status_pending_p): Don't check
7037 vCont;t here.
7038 (lwp_resumed): New function.
7039 (status_pending_p_callback): Return early if the LWP is not
7040 supposed to be resumed.
7041
65706a29
PA
70422015-11-30 Pedro Alves <palves@redhat.com>
7043
7044 * linux-low.c (handle_extended_wait): Assert that the LWP's
7045 waitstatus is TARGET_WAITKIND_IGNORE. If GDB wants to hear about
7046 thread create events, leave the new child's status pending.
7047 (linux_low_filter_event): If GDB wants to hear about thread exit
7048 events, leave the LWP marked dead and don't delete it.
7049 (linux_wait_for_event_filtered): Don't check for thread exit.
7050 (filter_exit_event): New function.
7051 (linux_wait_1): Use it, when returning an exit event.
7052 (linux_resume_one_lwp_throw): Assert that the LWP's
7053 waitstatus is TARGET_WAITKIND_IGNORE.
7054 * remote-utils.c (prepare_resume_reply): Handle
7055 TARGET_WAITKIND_THREAD_CREATED and TARGET_WAITKIND_THREAD_EXITED.
7056 * server.c (report_thread_events): New global.
7057 (handle_general_set): Handle QThreadEvents.
7058 (handle_query) <qSupported>: Handle and report QThreadEvents+;
7059 (handle_target_event): Handle TARGET_WAITKIND_THREAD_CREATED and
7060 TARGET_WAITKIND_THREAD_EXITED.
7061 * server.h (report_thread_events): Declare.
7062
56cf4bed
PA
70632015-11-30 Pedro Alves <palves@redhat.com>
7064
7065 * linux-low.c (resume_stopped_resumed_lwps): Don't check whether
7066 the thread's last_resume_kind was resume_stop.
7067
500c1d85
PA
70682015-11-30 Pedro Alves <palves@redhat.com>
7069
7070 * linux-low.c (linux_attach): In non-stop mode, wait for one stop
7071 before returning.
7072
de979965
PA
70732015-11-30 Pedro Alves <palves@redhat.com>
7074
7075 * server.c (handle_v_requests): Handle vCtrlC.
7076
34c65914
PA
70772015-11-30 Pedro Alves <palves@redhat.com>
7078
7079 * gdbthread.h (find_any_thread_of_pid): Declare.
7080 * inferiors.c (thread_of_pid, find_any_thread_of_pid): New
7081 functions.
7082 * server.c (handle_query): If current_thread is NULL, look for
7083 another thread of the selected process.
7084
79efa585 70852015-11-26 Daniel Colascione <dancol@dancol.org>
01a49af8 7086 Simon Marchi <simon.marchi@ericsson.com>
79efa585
SM
7087
7088 * linux-low.c (linux_target_ops): Use linux_proc_tid_get_name.
7089 * server.c (handle_qxfer_threads_worker): Refactor to include thread
7090 name in reply.
7091 * target.h (struct target_ops) <thread_name>: New field.
7092 (target_thread_name): New macro.
7093
80d82c19
JB
70942015-11-23 Joel Brobecker <brobecker@adacore.com>
7095
7096 * regcache.h (regcache_invalidate_pid): Add declaration.
7097 * regcache.c (regcache_invalidate_pid): New function, extracted
7098 from regcache_invalidate.
7099 (regcache_invalidate): Reimplement using regcache_invalidate_pid.
7100 Add trivial documentation comment.
7101 * lynx-low.c: Use regcache_invalidate_pid instead of
7102 regcache_invalidate.
7103
64da5dd5
JB
71042015-11-23 Joel Brobecker <brobecker@adacore.com>
7105
7106 * configure.ac: Do not call AC_CHECK_TYPES for Elf32_auxv_t
7107 and Elf64_auxv_t if the target is Android.
7108
37ce4055
DE
71092015-11-22 Doug Evans <xdje42@gmail.com>
7110
7111 * target.h: #include <sys/types.h>.
7112
06e03fff
PA
71132015-11-19 Pedro Alves <palves@redhat.com>
7114
7115 * linux-low.c (linux_process_qsupported): Change prototype.
7116 Adjust.
7117 * linux-low.h (struct linux_target_ops) <process_qsupported>:
7118 Change prototype.
7119 * linux-x86-low.c (x86_linux_process_qsupported): Change prototype
7120 and adjust to loop over all features.
7121 * server.c (handle_query) <qSupported>: Adjust to call
7122 target_process_qsupported once, passing it a vector of unprocessed
7123 features.
7124 * target.h (struct target_ops) <process_qsupported>: Change
7125 prototype.
7126 (target_process_qsupported): Adjust.
7127
9a084706
PA
71282015-11-19 Pedro Alves <palves@redhat.com>
7129
7130 * configure.ac (ERROR_ON_WARNING): Don't check whether in C++
7131 mode.
7132 * configure: Regenerate.
7133
dad44a1f
PA
71342015-11-19 Pedro Alves <palves@redhat.com>
7135
7136 * configure: Regenerate.
7137
231c0592
YQ
71382015-11-19 Yao Qi <yao.qi@linaro.org>
7139
7140 * linux-aarch64-low.c (emit_data_processing_reg): Change opcode
7141 type to uint32_t.
7142
6c1c9a8b
YQ
71432015-11-19 Yao Qi <yao.qi@linaro.org>
7144
7145 * linux-aarch64-low.c (enum aarch64_operand_type): New.
7146 (struct aarch64_operand): Move enum out.
7147
9caa3311
YQ
71482015-11-19 Yao Qi <yao.qi@linaro.org>
7149
7150 * linux-aarch64-low.c (aarch64_fill_fpregset): Cast buf to
7151 struct user_fpsimd_state *.
7152 (aarch64_store_fpregset): Likewise.
7153
6a69a054
YQ
71542015-11-19 Yao Qi <yao.qi@linaro.org>
7155
7156 * linux-aarch64-low.c (aarch64_fill_gregset): Cast buf to
7157 struct user_pt_regs *.
7158 (aarch64_store_gregset): Likewise.
7159
1798301e
PA
71602015-11-18 Pedro Alves <palves@redhat.com>
7161
7162 * Makefile.in (all_object_files): Add $IPA_OBJS.
7163
ce7715e2
PA
71642015-11-17 Pedro Alves <palves@redhat.com>
7165
7166 * win32-low.c (win32_resume): Use gdb_signal_from_host,
7167 GDB_SIGNAL_0 and gdb_signal_to_string.
7168
c0879059
PA
71692015-11-17 Pedro Alves <palves@redhat.com>
7170
7171 * win32-low.c (handle_output_debug_string): Remove parameter.
7172 (win32_kill): Remove our_status local and adjust call to
7173 handle_output_debug_string.
7174 (get_child_debug_event): Adjust call to
7175 handle_output_debug_string.
7176
1996e237
SM
71772015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
7178
7179 * linux-mips-low.c (mips_fill_gregset): Add cast.
7180 (mips_store_gregset): Likewise.
7181 (mips_fill_fpregset): Likewise.
7182 (mips_store_fpregset): Likewise.
7183
cbec665b
SM
71842015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
7185
7186 * linux-mips-low.c (mips_add_watchpoint): Rename private to
7187 priv.
7188
eb3e3c67
SM
71892015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
7190
7191 * linux-mips-low.c (mips_linux_new_thread): Change type of
7192 watch_type to enum target_hw_bp_type.
7193
171de4b8
SM
71942015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
7195
7196 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type):
7197 Change return type to arm_hwbp_type.
7198
04248ead
SM
71992015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
7200
7201 * linux-aarch32-low.c (arm_fill_gregset): Add cast.
7202 (arm_store_gregset): Likewise.
7203 * linux-arm-low.c (arm_get_hwcap): Likewise.
7204 (arm_read_description): Likewise.
7205
04b3479c
SM
72062015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
7207
7208 * linux-aarch32-low.c (aarch32_regsets): Use NULL_REGSET.
7209
2bc84e8a
SM
72102015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
7211
7212 * linux-ppc-low.c (ppc_get_hwcap): Add cast.
7213 (ppc_fill_vsxregset): Likewise.
7214 (ppc_store_vsxregset): Likewise.
7215 (ppc_fill_vrregset): Likewise.
7216 (ppc_store_vrregset): Likewise.
7217 (ppc_fill_evrregset): Likewise.
7218 (ppc_store_evrregset): Likewise.
7219
e6c5bb05
SM
72202015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
7221
7222 * linux-ppc-low.c (ppc_usrregs_info): Remove
7223 forward-declaration.
7224 (ppc_arch_setup): Move lower in file.
7225
7ea45d72
SM
72262015-10-30 Simon Marchi <simon.marchi@ericsson.com>
7227
7228 * proc-service.c (ps_pdread): Change CORE_ADDR cast to uintptr_t.
7229 (ps_pdwrite): Likewise.
7230
69291610
HW
72312015-10-29 Henrik Wallin <henrik.wallin@windriver.com>
7232
7233 * linux-arm-low.c (arm_new_thread): Move pointer dereference
7234 to after assert checks.
7235
b42945fd
SM
72362015-10-29 Simon Marchi <simon.marchi@ericsson.com>
7237
7238 * proc-service.c (ps_pdread): Add/adjust casts.
7239 (ps_pdwrite): Add/adjust casts.
7240
d6f85c84
SM
72412015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
7242
7243 * server.c (handle_search_memory_1): Cast return value of
7244 memmem.
7245
f98cd059
SM
72462015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
7247
7248 * server.c (write_qxfer_response): Change type of data to
7249 gdb_byte *.
7250
d2412fa5
PA
72512015-10-29 Pedro Alves <palves@redhat.com>
7252
7253 * mem-break.c (Z_packet_to_bkpt_type): Add cast.
7254
c17414a2
PA
72552015-10-29 Pedro Alves <palves@redhat.com>
7256
7257 * tracepoint.c (clear_installed_tracepoints): Add casts.
7258
e053fbc4
PA
72592015-10-29 Pedro Alves <palves@redhat.com>
7260
7261 * server.c (handle_v_cont, process_serial_event): Add enum
7262 gdb_signal casts to signal parsing code.
7263
add67df8
PA
72642015-10-29 Pedro Alves <palves@redhat.com>
7265
7266 * linux-low.h (NULL_REGSET): Define.
7267 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
7268 * linux-arm-low.c (arm_regsets): Likewise.
7269 * linux-crisv32-low.c (cris_regsets): Likewise.
7270 * linux-m68k-low.c (m68k_regsets): Likewise.
7271 * linux-mips-low.c (mips_regsets): Likewise.
7272 * linux-nios2-low.c (nios2_regsets): Likewise.
7273 * linux-ppc-low.c (ppc_regsets): Likewise.
7274 * linux-s390-low.c (s390_regsets): Likewise.
7275 * linux-sh-low.c (sh_regsets): Likewise.
7276 * linux-sparc-low.c (sparc_regsets): Likewise.
7277 * linux-tic6x-low.c (tic6x_regsets): Likewise.
7278 * linux-tile-low.c (tile_regsets): Likewise.
7279 * linux-x86-low.c (x86_regsets): Likewise.
7280 * linux-xtensa-low.c (xtensa_regsets): Likewise.
7281
50bc912a
PA
72822015-10-29 Pedro Alves <palves@redhat.com>
7283
7284 * linux-low.h (NULL_REGSET): Define.
7285 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
7286 * linux-arm-low.c (arm_regsets): Likewise.
7287 * linux-crisv32-low.c (cris_regsets): Likewise.
7288 * linux-m68k-low.c (m68k_regsets): Likewise.
7289 * linux-mips-low.c (mips_regsets): Likewise.
7290 * linux-nios2-low.c (nios2_regsets): Likewise.
7291 * linux-ppc-low.c (ppc_regsets): Likewise.
7292 * linux-s390-low.c (s390_regsets): Likewise.
7293 * linux-sh-low.c (sh_regsets): Likewise.
7294 * linux-sparc-low.c (sparc_regsets): Likewise.
7295 * linux-tic6x-low.c (tic6x_regsets): Likewise.
7296 * linux-tile-low.c (tile_regsets): Likewise.
7297 * linux-x86-low.c (x86_regsets): Likewise.
7298 * linux-xtensa-low.c (xtensa_regsets): Likewise.
7299
682b2546
DE
73002015-10-26 Doug Evans <dje@google.com>
7301
7302 * linux-low.c (__SIGRTMIN): Move to nat/linux-nat.h.
7303
963843d4
DE
73042015-10-26 Doug Evans <dje@google.com>
7305
7306 * linux-low.c (W_STOPCODE): Moved to common/gdb_wait.h.
7307
d41401ac
DE
73082015-10-26 Doug Evans <dje@google.com>
7309
7310 * thread-db.c (find_one_thread): Cast ti.ti_tid to unsigned long
7311 for debug_printf.
7312 (attach_thread, find_new_threads_callback): Ditto.
7313
3db28855
AT
73142015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
7315
7316 * mem-break.h (set_breakpoint_data): Remove.
7317
fb78e89c
AT
73182015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
7319
7320 * nto-low.c (nto_sw_breakpoint_from_kind): New function.
7321 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
7322 (initialize_low): Remove set_breakpoint_data call.
7323 * spu-low.c (spu_sw_breakpoint_from_kind): New function.
7324 (struct target_ops) <sw_breakpoint_from_kind>: Iniitalize.
7325 (initialize_low): Remove set_breakpoint_data call.
7326 * win32-low.c (win32_sw_breakpoint_from_kind): New function.
7327 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
7328 (initialize_low): Remove set_breakpoint_data call.
7329
2e6ee069
AT
73302015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
7331
7332 * linux-low.c (default_breakpoint_kind_from_pc): Move to target.c.
7333 * mem-break.c (set_breakpoint_at): Use target_breakpoint_kind_from_pc.
7334 * target.c (default_breakpoint_kind_from_pc): Moved from linux-low.c
7335 * target.h (target_breakpoint_kind_from_pc): New macro.
7336
1652a986
AT
73372015-10-22 Antoine Tremblay <antoine.tremblay@ericsson.com>
7338
7339 * linux-low.c (default_breakpoint_kind_from_pc): New function.
7340 (linux_breakpoint_kind_from_pc): Use default_breakpoint_kind_from_pc for
7341 the default breakpoint kind.
7342
abeead09
AT
73432015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
7344
7345 * linux-arm-low.c (arm_supports_z_point_type): Add software
7346 breakpoint support.
7347
b0b4b501
AT
73482015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
7349
7350 * linux-arm-low.c: Refactor breakpoint definitions.
7351 (arm_breakpoint_at): Adjust for arm_abi_breakpoint.
7352 (arm_sw_breakpoint_from_kind): Adjust for arm_breakpoint.
7353
8689682c
AT
73542015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
7355
7356 * Makefile.in: Add arm.c/o.
7357 * configure.srv: Likewise.
7358 * linux-arm-low.c (arm_breakpoint_kinds): New enum.
7359 (arm_breakpoint_kind_from_pc): New function.
7360 (arm_sw_breakpoint_from_kind): Return proper kind.
7361 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize.
7362
27165294
AT
73632015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
7364
7365 * linux-low.c (initialize_low): Ajdust for breakpoint global variables
7366 removal.
7367 * mem-break.c : Remove breakpoint_data/breakpoint_len global variables.
7368 (struct raw_breakpoint) <size>: Remove.
7369 (struct raw_breakpoint) <kind>: Add.
7370 (bp_size): New function.
7371 (bp_opcode): Likewise.
7372 (find_raw_breakpoint_at): Adjust for kind.
7373 (insert_memory_breakpoint): Adjust for kind call bp_size,bp_opcode.
7374 (remove_memory_breakpoint): Adjust for kind call bp_size.
7375 (set_raw_breakpoint_at): Adjust for kind.
7376 (set_breakpoint): Likewise.
7377 (set_breakpoint_at): Call breakpoint_kind_from_pc.
7378 (delete_raw_breakpoint): Adjust for kind.
7379 (delete_breakpoint): Likewise.
7380 (find_gdb_breakpoint): Likewise.
7381 (set_gdb_breakpoint_1): Likewise.
7382 (set_gdb_breakpoint): Likewise.
7383 (delete_gdb_breakpoint_1): Likewise.
7384 (delete_gdb_breakpoint): Likewise.
7385 (uninsert_raw_breakpoint): Likewise.
7386 (reinsert_raw_breakpoint): Likewise.
7387 (set_breakpoint_data): Remove.
7388 (validate_inserted_breakpoint): Adjust for kind call bp_size,bp_opcode.
7389 (check_mem_read): Adjust for kind call bp_size.
7390 (check_mem_write): Adjust for kind call bp_size,bp_opcode.
7391 (clone_one_breakpoint): Adjust for kind.
7392 * mem-break.h (set_gdb_breakpoint): Likewise.
7393 (delete_gdb_breakpoint): Likewise.
7394 * server.c (process_serial_event): Likewise.
7395
dd373349
AT
73962015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
7397
7398 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): New function.
7399 (struct linux_target_ops) <breakpoint>: Remove.
7400 (struct linux_target_ops) <breakpoint_len>: Remove.
7401 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7402 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7403 * linux-arm-low.c (arm_breakpoint_kind_from_pc): New function.
7404 (arm_sw_breakpoint_from_kind): New function.
7405 * linux-bfin-low.c (bfin_sw_breakpoint_from_kind): New function.
7406 (struct linux_target_ops) <breakpoint>: Remove.
7407 (struct linux_target_ops) <breakpoint_len>: Remove.
7408 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7409 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7410 * linux-cris-low.c (cris_sw_breakpoint_from_kind): New function.
7411 (struct linux_target_ops) <breakpoint>: Remove.
7412 (struct linux_target_ops) <breakpoint_len>: Remove.
7413 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7414 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7415 * linux-crisv32-low.c (cris_sw_breakpoint_from_kind): New function.
7416 (struct linux_target_ops) <breakpoint>: Remove.
7417 (struct linux_target_ops) <breakpoint_len>: Remove.
7418 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7419 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7420 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_pc
7421 and sw_breakpoint_from_kind to increment the pc.
7422 (linux_breakpoint_kind_from_pc): New function.
7423 (linux_sw_breakpoint_from_kind): New function.
7424 (struct target_ops) <sw_breakpoint_from_kind>: Initialize field.
7425 (initialize_low): Call breakpoint_kind_from_pc and
7426 sw_breakpoint_from_kind to replace breakpoint_data/len.
7427 * linux-low.h (struct linux_target_ops) <breakpoint_kind_from_pc>:
7428 New field.
7429 (struct linux_target_ops) <sw_breakpoint_from_kind>: Likewise.
7430 * linux-m32r-low.c (m32r_sw_breakpoint_from_kind): New function.
7431 (struct linux_target_ops) <breakpoint>: Remove.
7432 (struct linux_target_ops) <breakpoint_len>: Remove.
7433 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7434 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7435 * linux-m68k-low.c (m68k_sw_breakpoint_from_kind): New function.
7436 (struct linux_target_ops) <breakpoint>: Remove.
7437 (struct linux_target_ops) <breakpoint_len>: Remove.
7438 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7439 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7440 * linux-mips-low.c (mips_sw_breakpoint_from_kind): New function.
7441 (struct linux_target_ops) <breakpoint>: Remove.
7442 (struct linux_target_ops) <breakpoint_len>: Remove.
7443 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7444 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7445 * linux-nios2-low.c (nios2_sw_breakpoint_from_kind): New function.
7446 (struct linux_target_ops) <breakpoint>: Remove.
7447 (struct linux_target_ops) <breakpoint_len>: Remove.
7448 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7449 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7450 * linux-ppc-low.c (ppc_sw_breakpoint_from_kind): New function.
7451 (struct linux_target_ops) <breakpoint>: Remove.
7452 (struct linux_target_ops) <breakpoint_len>: Remove.
7453 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7454 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7455 * linux-s390-low.c (s390_sw_breakpoint_from_kind): New function.
7456 (struct linux_target_ops) <breakpoint>: Remove.
7457 (struct linux_target_ops) <breakpoint_len>: Remove.
7458 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7459 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7460 * linux-sh-low.c (sh_sw_breakpoint_from_kind): New function.
7461 (struct linux_target_ops) <breakpoint>: Remove.
7462 (struct linux_target_ops) <breakpoint_len>: Remove.
7463 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7464 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7465 * linux-sparc-low.c (sparc_sw_breakpoint_from_kind): New function.
7466 (struct linux_target_ops) <breakpoint>: Remove.
7467 (struct linux_target_ops) <breakpoint_len>: Remove.
7468 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7469 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7470 * linux-tic6x-low.c (tic6x_sw_breakpoint_from_kind): New function.
7471 (struct linux_target_ops) <breakpoint>: Remove.
7472 (struct linux_target_ops) <breakpoint_len>: Remove.
7473 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7474 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7475 * linux-tile-low.c (tile_sw_breakpoint_from_kind): New function.
7476 * linux-x86-low.c (x86_sw_breakpoint_from_kind): New function.
7477 (struct linux_target_ops) <breakpoint>: Remove.
7478 (struct linux_target_ops) <breakpoint_len>: Remove.
7479 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7480 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7481 * linux-xtensa-low.c (xtensa_sw_breakpoint_from_kind) New function.
7482 (struct linux_target_ops) <breakpoint>: Remove.
7483 (struct linux_target_ops) <breakpoint_len>: Remove.
7484 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
7485 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
7486
4cd98a19
AT
74872015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
7488
7489 * linux-cris-low.c (cris_get_pc): Remove void arg.
7490
774ee6d2
AR
74912015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
7492
7493 * gdbserver/nto-low.c (nto_insert_point, nto_remove_point): Fix
7494 variable name.
7495
833dcd29
AR
74962015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
7497
7498 * inferiors.c (thread_pid_matches_callback): New function.
7499 (find_thread_process): New function.
7500 (remove_thread): Reset current_thread.
7501 (remove_process): Assert threads have been removed first.
7502
8d689ee5
YQ
75032015-10-15 Yao Qi <yao.qi@linaro.org>
7504
7505 * linux-aarch64-low.c (aarch64_insert_point): Set len to 2
7506 if it is 3.
7507 (aarch64_remove_point): Likewise.
7508 * regcache.c (regcache_register_size): New function.
7509
1c2e1515
YQ
75102015-10-12 Yao Qi <yao.qi@linaro.org>
7511
7512 * linux-aarch64-low.c: Update all callers as emit_load_store
7513 is renamed to aarch64_emit_load_store.
7514
e1c587c3
YQ
75152015-10-12 Yao Qi <yao.qi@linaro.org>
7516
7517 * linux-aarch64-low.c: Update all callers of function renaming
7518 from emit_insn to aarch64_emit_insn.
7519
b6542f81
YQ
75202015-10-12 Yao Qi <yao.qi@linaro.org>
7521
7522 * linux-aarch64-low.c (enum aarch64_opcodes): Move to
7523 arch/aarch64-insn.h.
7524 (struct aarch64_memory_operand): Likewise.
7525 (ENCODE): Likewise.
7526 (emit_insn): Move to arch/aarch64-insn.c.
7527 (emit_b, emit_bcond, emit_cb, emit_tb): Remove.
7528 (emit_load_store): Move to arch/aarch64-insn.c.
7529 (emit_ldr, emit_ldrb, emit_ldrsw, emit_nop): Remove.
7530 (can_encode_int32): Remove.
7531
246994ce
YQ
75322015-10-12 Yao Qi <yao.qi@linaro.org>
7533
7534 * linux-aarch64-low.c (extract_signed_bitfield): Remove.
7535 (aarch64_decode_ldr_literal): Move to gdb/arch/aarch64-insn.c.
7536 (aarch64_relocate_instruction): Likewise.
7537 (struct aarch64_insn_data): Move to gdb/arch/aarch64-insn.h.
7538 (struct aarch64_insn_visitor): Likewise.
7539
0badd99f
YQ
75402015-10-12 Yao Qi <yao.qi@linaro.org>
7541
7542 * linux-aarch64-low.c (struct aarch64_insn_data): New.
7543 (struct aarch64_insn_visitor): New.
7544 (struct aarch64_insn_relocation_data): New.
7545 (aarch64_ftrace_insn_reloc_b): New function.
7546 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
7547 (aarch64_ftrace_insn_reloc_cb): Likewise.
7548 (aarch64_ftrace_insn_reloc_tb): Likewise.
7549 (aarch64_ftrace_insn_reloc_adr): Likewise.
7550 (aarch64_ftrace_insn_reloc_ldr_literal): Likewise.
7551 (aarch64_ftrace_insn_reloc_others): Likewise.
7552 (visitor): New.
7553 (aarch64_relocate_instruction): Use visitor.
7554
dfaffe9d
YQ
75552015-10-12 Yao Qi <yao.qi@linaro.org>
7556
7557 * linux-aarch64-low.c (aarch64_relocate_instruction): Return
7558 int. Add argument buf.
7559 (aarch64_install_fast_tracepoint_jump_pad): Pass buf to
7560 aarch64_relocate_instruction.
7561
70b439f0
YQ
75622015-10-12 Yao Qi <yao.qi@linaro.org>
7563
7564 * linux-aarch64-low.c (aarch64_relocate_instruction): Add
7565 argument insn. Remove local variable insn. Don't call
7566 target_read_uint32.
7567 (aarch64_install_fast_tracepoint_jump_pad): Call
7568 target_read_uint32.
7569
7781c06f
YQ
75702015-09-30 Yao Qi <yao.qi@linaro.org>
7571
7572 * linux-aarch64-low.c (emit_movk): Shorten a long line.
7573 (emit_load_store_pair): Likewise.
7574
9a3c8263
SM
75752015-09-25 Simon Marchi <simon.marchi@ericsson.com>
7576
7577 * dll.c (match_dll): Add cast(s).
7578 (unloaded_dll): Likewise.
7579 * linux-low.c (second_thread_of_pid_p): Likewise.
7580 (delete_lwp_callback): Likewise.
7581 (count_events_callback): Likewise.
7582 (select_event_lwp_callback): Likewise.
7583 (linux_set_resume_request): Likewise.
7584 * server.c (accumulate_file_name_length): Likewise.
7585 (emit_dll_description): Likewise.
7586 (handle_qxfer_threads_worker): Likewise.
7587 (visit_actioned_threads): Likewise.
7588 * thread-db.c (any_thread_of): Likewise.
7589 * tracepoint.c (same_process_p): Likewise.
7590 (match_blocktype): Likewise.
7591 (build_traceframe_info_xml): Likewise.
7592
224c3ddb
SM
75932015-09-25 Simon Marchi <simon.marchi@ericsson.com>
7594
7595 * ax.c (gdb_parse_agent_expr): Add cast to allocation result
7596 assignment.
7597 (gdb_unparse_agent_expr): Likewise.
7598 * hostio.c (require_data): Likewise.
7599 (handle_pread): Likewise.
7600 * linux-low.c (disable_regset): Likewise.
7601 (fetch_register): Likewise.
7602 (store_register): Likewise.
7603 (get_dynamic): Likewise.
7604 (linux_qxfer_libraries_svr4): Likewise.
7605 * mem-break.c (delete_fast_tracepoint_jump): Likewise.
7606 (set_fast_tracepoint_jump): Likewise.
7607 (uninsert_fast_tracepoint_jumps_at): Likewise.
7608 (reinsert_fast_tracepoint_jumps_at): Likewise.
7609 (validate_inserted_breakpoint): Likewise.
7610 (clone_agent_expr): Likewise.
7611 * regcache.c (init_register_cache): Likewise.
7612 * remote-utils.c (putpkt_binary_1): Likewise.
7613 (decode_M_packet): Likewise.
7614 (decode_X_packet): Likewise.
7615 (look_up_one_symbol): Likewise.
7616 (relocate_instruction): Likewise.
7617 (monitor_output): Likewise.
7618 * server.c (handle_search_memory): Likewise.
7619 (handle_qxfer_exec_file): Likewise.
7620 (handle_qxfer_libraries): Likewise.
7621 (handle_qxfer): Likewise.
7622 (handle_query): Likewise.
7623 (handle_v_cont): Likewise.
7624 (handle_v_run): Likewise.
7625 (captured_main): Likewise.
7626 * target.c (write_inferior_memory): Likewise.
7627 * thread-db.c (try_thread_db_load_from_dir): Likewise.
7628 * tracepoint.c (init_trace_buffer): Likewise.
7629 (add_tracepoint_action): Likewise.
7630 (add_traceframe): Likewise.
7631 (add_traceframe_block): Likewise.
7632 (cmd_qtdpsrc): Likewise.
7633 (cmd_qtdv): Likewise.
7634 (cmd_qtstatus): Likewise.
7635 (response_source): Likewise.
7636 (response_tsv): Likewise.
7637 (cmd_qtnotes): Likewise.
7638 (gdb_collect): Likewise.
7639 (initialize_tracepoint): Likewise.
7640
afbe19f8
PL
76412015-09-21 Pierre Langlois <pierre.langlois@arm.com>
7642
7643 * linux-aarch64-low-.c: Include ax.h and tracepoint.h.
7644 (enum aarch64_opcodes) <RET>, <SUBS>, <AND>, <ORR>, <ORN>,
7645 <EOR>, <LSLV>, <LSRV>, <ASRV>, <SBFM>, <UBFM>, <CSINC>, <MUL>,
7646 <NOP>: New.
7647 (enum aarch64_condition_codes): New enum.
7648 (w0): New static global.
7649 (fp): Likewise.
7650 (lr): Likewise.
7651 (struct aarch64_memory_operand) <type>: New
7652 MEMORY_OPERAND_POSTINDEX type.
7653 (postindex_memory_operand): New helper function.
7654 (emit_ret): New function.
7655 (emit_load_store_pair): New function, factored out of emit_stp
7656 with support for MEMORY_OPERAND_POSTINDEX.
7657 (emit_stp): Rewrite using emit_load_store_pair.
7658 (emit_ldp): New function.
7659 (emit_load_store): Likewise.
7660 (emit_ldr): Mention post-index instruction in comment.
7661 (emit_ldrh): New function.
7662 (emit_ldrb): New function.
7663 (emit_ldrsw): Mention post-index instruction in comment.
7664 (emit_str): Likewise.
7665 (emit_subs): New function.
7666 (emit_cmp): Likewise.
7667 (emit_and): Likewise.
7668 (emit_orr): Likewise.
7669 (emit_orn): Likewise.
7670 (emit_eor): Likewise.
7671 (emit_mvn): Likewise.
7672 (emit_lslv): Likewise.
7673 (emit_lsrv): Likewise.
7674 (emit_asrv): Likewise.
7675 (emit_mul): Likewise.
7676 (emit_sbfm): Likewise.
7677 (emit_sbfx): Likewise.
7678 (emit_ubfm): Likewise.
7679 (emit_ubfx): Likewise.
7680 (emit_csinc): Likewise.
7681 (emit_cset): Likewise.
7682 (emit_nop): Likewise.
7683 (emit_ops_insns): New helper function.
7684 (emit_pop): Likewise.
7685 (emit_push): Likewise.
7686 (aarch64_emit_prologue): New function.
7687 (aarch64_emit_epilogue): Likewise.
7688 (aarch64_emit_add): Likewise.
7689 (aarch64_emit_sub): Likewise.
7690 (aarch64_emit_mul): Likewise.
7691 (aarch64_emit_lsh): Likewise.
7692 (aarch64_emit_rsh_signed): Likewise.
7693 (aarch64_emit_rsh_unsigned): Likewise.
7694 (aarch64_emit_ext): Likewise.
7695 (aarch64_emit_log_not): Likewise.
7696 (aarch64_emit_bit_and): Likewise.
7697 (aarch64_emit_bit_or): Likewise.
7698 (aarch64_emit_bit_xor): Likewise.
7699 (aarch64_emit_bit_not): Likewise.
7700 (aarch64_emit_equal): Likewise.
7701 (aarch64_emit_less_signed): Likewise.
7702 (aarch64_emit_less_unsigned): Likewise.
7703 (aarch64_emit_ref): Likewise.
7704 (aarch64_emit_if_goto): Likewise.
7705 (aarch64_emit_goto): Likewise.
7706 (aarch64_write_goto_address): Likewise.
7707 (aarch64_emit_const): Likewise.
7708 (aarch64_emit_call): Likewise.
7709 (aarch64_emit_reg): Likewise.
7710 (aarch64_emit_pop): Likewise.
7711 (aarch64_emit_stack_flush): Likewise.
7712 (aarch64_emit_zero_ext): Likewise.
7713 (aarch64_emit_swap): Likewise.
7714 (aarch64_emit_stack_adjust): Likewise.
7715 (aarch64_emit_int_call_1): Likewise.
7716 (aarch64_emit_void_call_2): Likewise.
7717 (aarch64_emit_eq_goto): Likewise.
7718 (aarch64_emit_ne_goto): Likewise.
7719 (aarch64_emit_lt_goto): Likewise.
7720 (aarch64_emit_le_goto): Likewise.
7721 (aarch64_emit_gt_goto): Likewise.
7722 (aarch64_emit_ge_got): Likewise.
7723 (aarch64_emit_ops_impl): New static global variable.
7724 (aarch64_emit_ops): New target function, return
7725 &aarch64_emit_ops_impl.
7726 (struct linux_target_ops): Install it.
7727
bb903df0
PL
77282015-09-21 Pierre Langlois <pierre.langlois@arm.com>
7729
7730 * Makefile.in (linux-aarch64-ipa.o, aarch64-ipa.o): New rules.
7731 * configure.srv (aarch64*-*-linux*): Add linux-aarch64-ipa.o and
7732 aarch64-ipa.o.
7733 * linux-aarch64-ipa.c: New file.
7734 * linux-aarch64-low.c: Include arch/aarch64-insn.h, inttypes.h
7735 and endian.h.
7736 (aarch64_get_thread_area): New target method.
7737 (extract_signed_bitfield): New helper function.
7738 (aarch64_decode_ldr_literal): New function.
7739 (enum aarch64_opcodes): New enum.
7740 (struct aarch64_register): New struct.
7741 (struct aarch64_operand): New struct.
7742 (x0): New static global.
7743 (x1): Likewise.
7744 (x2): Likewise.
7745 (x3): Likewise.
7746 (x4): Likewise.
7747 (w2): Likewise.
7748 (ip0): Likewise.
7749 (sp): Likewise.
7750 (xzr): Likewise.
7751 (aarch64_register): New helper function.
7752 (register_operand): Likewise.
7753 (immediate_operand): Likewise.
7754 (struct aarch64_memory_operand): New struct.
7755 (offset_memory_operand): New helper function.
7756 (preindex_memory_operand): Likewise.
7757 (enum aarch64_system_control_registers): New enum.
7758 (ENCODE): New macro.
7759 (emit_insn): New helper function.
7760 (emit_b): New function.
7761 (emit_bcond): Likewise.
7762 (emit_cb): Likewise.
7763 (emit_tb): Likewise.
7764 (emit_blr): Likewise.
7765 (emit_stp): Likewise.
7766 (emit_ldp_q_offset): Likewise.
7767 (emit_stp_q_offset): Likewise.
7768 (emit_load_store): Likewise.
7769 (emit_ldr): Likewise.
7770 (emit_ldrsw): Likewise.
7771 (emit_str): Likewise.
7772 (emit_ldaxr): Likewise.
7773 (emit_stxr): Likewise.
7774 (emit_stlr): Likewise.
7775 (emit_data_processing_reg): Likewise.
7776 (emit_data_processing): Likewise.
7777 (emit_add): Likewise.
7778 (emit_sub): Likewise.
7779 (emit_mov): Likewise.
7780 (emit_movk): Likewise.
7781 (emit_mov_addr): Likewise.
7782 (emit_mrs): Likewise.
7783 (emit_msr): Likewise.
7784 (emit_sevl): Likewise.
7785 (emit_wfe): Likewise.
7786 (append_insns): Likewise.
7787 (can_encode_int32_in): New helper function.
7788 (aarch64_relocate_instruction): New function.
7789 (aarch64_install_fast_tracepoint_jump_pad): Likewise.
7790 (aarch64_get_min_fast_tracepoint_insn_len): Likewise.
7791 (struct linux_target_ops): Install aarch64_get_thread_area,
7792 aarch64_install_fast_tracepoint_jump_pad and
7793 aarch64_get_min_fast_tracepoint_insn_len.
7794
787749ea
PL
77952015-09-21 Pierre Langlois <pierre.langlois@arm.com>
7796
7797 * Makefile.in (aarch64-insn.o): New rule.
7798 * configure.srv (aarch64*-*-linux*): Add aarch64-insn.o.
7799
9812b2e6
YQ
78002015-09-21 Yao Qi <yao.qi@linaro.org>
7801
7802 * ax.c [!IN_PROCESS_AGENT] (gdb_agent_op_sizes): Define it.
7803
18fe412b
YQ
78042015-09-21 Yao Qi <yao.qi@linaro.org>
7805
7806 * tracepoint.c (max_jump_pad_size): Remove.
7807
a0cc84cd
YQ
78082015-09-18 Yao Qi <yao.qi@linaro.org>
7809
7810 * linux-aarch64-low.c: Don't include sys/uio.h.
7811 (ps_get_thread_area): Call aarch64_ps_get_thread_area.
7812
d78908cf
WW
78132015-09-16 Wei-cheng Wang <cole945@gmail.com>
7814
7815 * tracepoint.c (eval_result_type): Change prototype.
7816 (condition_true_at_tracepoint): Fix argument to compiled_cond.
7817
d57e0d50
PA
78182015-09-15 Pedro Alves <palves@redhat.com>
7819
7820 * remote-utils.c (prepare_resume_reply) <TARGET_WAITKIND_EXECD>:
7821 Check whether to report exec events instead of checking whether
7822 multiprocess is enabled.
7823
5a676acc
PA
78242015-09-15 Pedro Alves <palves@redhat.com>
7825
7826 PR remote/18965
7827 * remote-utils.c (prepare_resume_reply): Merge
7828 TARGET_WAITKIND_VFORK_DONE switch case with the
7829 TARGET_WAITKIND_FORKED case.
7830
7c5d0fad
YQ
78312015-09-15 Yao Qi <yao.qi@linaro.org>
7832
7833 * server.c (handle_query): Check string comparison using
7834 "else if" instead of "if".
7835
750ce8d1
YQ
78362015-09-15 Yao Qi <yao.qi@linaro.org>
7837
7838 * server.c (vCont_supported): New global variable.
7839 (handle_query): Set vCont_supported to 1 if "vContSupported+"
7840 matches. Append ";vContSupported+" to own_buf.
7841 (handle_v_requests): Append ";s;S" to own_buf if target supports
7842 hardware single step or vCont_supported is false.
7843 (capture_main): Set vCont_supported to zero.
7844
70b90b91
YQ
78452015-09-15 Yao Qi <yao.qi@linaro.org>
7846
7847 * linux-low.c (linux_supports_conditional_breakpoints): Rename
7848 it to ...
7849 (linux_supports_hardware_single_step): ... New function.
7850 (linux_target_ops): Update.
7851 * lynx-low.c (lynx_target_ops): Set field
7852 supports_hardware_single_step to target_can_do_hardware_single_step.
7853 * nto-low.c (nto_target_ops): Likewise.
7854 * spu-low.c (spu_target_ops): Likewise.
7855 * win32-low.c (win32_target_ops): Likewise.
7856 * target.c (target_can_do_hardware_single_step): New function.
7857 * target.h (struct target_ops) <supports_conditional_breakpoints>:
7858 Remove. <supports_hardware_single_step>: New field.
7859 (target_supports_conditional_breakpoints): Remove.
7860 (target_supports_hardware_single_step): New macro.
7861 (target_can_do_hardware_single_step): Declare.
7862 * server.c (handle_query): Use target_supports_hardware_single_step
7863 instead of target_supports_conditional_breakpoints.
7864
ade90bde
YQ
78652015-09-15 Yao Qi <yao.qi@linaro.org>
7866
7867 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): New
7868 function.
7869 (struct linux_target_ops the_low_target): Install
7870 aarch64_linux_siginfo_fixup.
7871
94585166
DB
78722015-09-11 Don Breazeal <donb@codesourcery.com>
7873 Luis Machado <lgustavo@codesourcery.com>
7874
7875 * linux-low.c (linux_mourn): Static declaration.
7876 (linux_arch_setup): Move in front of
7877 handle_extended_wait.
7878 (linux_arch_setup_thread): New function.
7879 (handle_extended_wait): Handle exec events. Call
7880 linux_arch_setup_thread. Make event_lwp argument a
7881 pointer-to-a-pointer.
7882 (check_zombie_leaders): Do not check stopped threads.
7883 (linux_low_ptrace_options): Add PTRACE_O_TRACEEXEC.
7884 (linux_low_filter_event): Add lwp and thread for exec'ing
7885 non-leader thread if leader thread has been deleted.
7886 Refactor code into linux_arch_setup_thread and call it.
7887 Pass child lwp pointer by reference to handle_extended_wait.
7888 (linux_wait_for_event_filtered): Update comment.
7889 (linux_wait_1): Prevent clobbering exec event status.
7890 (linux_supports_exec_events): New function.
7891 (linux_target_ops) <supports_exec_events>: Initialize new member.
7892 * lynx-low.c (lynx_target_ops) <supports_exec_events>: Initialize
7893 new member.
7894 * remote-utils.c (prepare_resume_reply): New stop reason 'exec'.
7895 * server.c (report_exec_events): New global variable.
7896 (handle_query): Handle qSupported query for exec-events feature.
7897 (captured_main): Initialize report_exec_events.
7898 * server.h (report_exec_events): Declare new global variable.
7899 * target.h (struct target_ops) <supports_exec_events>: New
7900 member.
7901 (target_supports_exec_events): New macro.
7902 * win32-low.c (win32_target_ops) <supports_exec_events>:
7903 Initialize new member.
7904
0568462b
MM
79052015-09-09 Markus Metzger <markus.t.metzger@intel.com>
7906
7907 * linux-low.c (linux_low_enable_btrace): Remove.
7908 (linux_target_ops): Replace linux_low_enable_btrace with
7909 linux_enable_btrace.
7910
39edd165
YQ
79112015-09-03 Yao Qi <yao.qi@linaro.org>
7912
7913 * linux-aarch64-low.c (aarch64_insert_point): Call
7914 aarch64_handle_watchpoint if aarch64_linux_region_ok_for_watchpoint
7915 returns true.
7916
1db33b5a
UW
79172015-08-27 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
7918
7919 * linux-low.c (check_stopped_by_breakpoint): Use
7920 GDB_ARCH_IS_TRAP_BRKPT instead of GDB_ARCH_TRAP_BRKPT.
7921
ab290430
PA
79222015-08-27 Pedro Alves <palves@redhat.com>
7923
7924 * proc-service.c (ps_pdwrite): Return PS_ERR/PS_OK explicily.
7925
8d749320
SM
79262015-08-26 Simon Marchi <simon.marchi@ericsson.com>
7927
6711b7f8
SM
7928 * ax.c (gdb_parse_agent_expr): Replace xmalloc-family function with
7929 the XNEW-family equivalent.
8d749320
SM
7930 (compile_bytecodes): Likewise.
7931 * dll.c (loaded_dll): Likewise.
7932 * event-loop.c (append_callback_event): Likewise.
7933 (create_file_handler): Likewise.
7934 (create_file_event): Likewise.
7935 * hostio.c (handle_open): Likewise.
7936 * inferiors.c (add_thread): Likewise.
7937 (add_process): Likewise.
7938 * linux-aarch64-low.c (aarch64_linux_new_process): Likewise.
7939 * linux-arm-low.c (arm_new_process): Likewise.
7940 (arm_new_thread): Likewise.
7941 * linux-low.c (add_to_pid_list): Likewise.
7942 (linux_add_process): Likewise.
7943 (handle_extended_wait): Likewise.
7944 (add_lwp): Likewise.
7945 (enqueue_one_deferred_signal): Likewise.
7946 (enqueue_pending_signal): Likewise.
7947 (linux_resume_one_lwp_throw): Likewise.
7948 (linux_resume_one_thread): Likewise.
7949 (linux_read_memory): Likewise.
7950 (linux_write_memory): Likewise.
7951 * linux-mips-low.c (mips_linux_new_process): Likewise.
7952 (mips_linux_new_thread): Likewise.
7953 (mips_add_watchpoint): Likewise.
7954 * linux-x86-low.c (initialize_low_arch): Likewise.
7955 * lynx-low.c (lynx_add_process): Likewise.
7956 * mem-break.c (set_raw_breakpoint_at): Likewise.
7957 (set_breakpoint): Likewise.
7958 (add_condition_to_breakpoint): Likewise.
7959 (add_commands_to_breakpoint): Likewise.
7960 (clone_agent_expr): Likewise.
7961 (clone_one_breakpoint): Likewise.
7962 * regcache.c (new_register_cache): Likewise.
7963 * remote-utils.c (look_up_one_symbol): Likewise.
7964 * server.c (queue_stop_reply): Likewise.
7965 (start_inferior): Likewise.
7966 (queue_stop_reply_callback): Likewise.
7967 (handle_target_event): Likewise.
7968 * spu-low.c (fetch_ppc_memory): Likewise.
7969 (store_ppc_memory): Likewise.
7970 * target.c (set_target_ops): Likewise.
7971 * thread-db.c (thread_db_load_search): Likewise.
7972 (try_thread_db_load_1): Likewise.
7973 * tracepoint.c (add_tracepoint): Likewise.
7974 (add_tracepoint_action): Likewise.
7975 (create_trace_state_variable): Likewise.
7976 (cmd_qtdpsrc): Likewise.
7977 (cmd_qtro): Likewise.
7978 (add_while_stepping_state): Likewise.
7979 * win32-low.c (child_add_thread): Likewise.
7980 (get_image_name): Likewise.
7981
ed8b7b42
YQ
79822015-08-25 Yao Qi <yao.qi@linaro.org>
7983
7984 * linux-aarch64-low.c (aarch64_linux_new_thread): Remove.
7985
db3cb7cb
YQ
79862015-08-25 Yao Qi <yao.qi@linaro.org>
7987
7988 * Makefile.in (aarch64-linux.o): New rule.
7989 * configure.srv (aarch64*-*-linux*): Append aarch64-linux.o to
7990 srv_tgtobj.
7991 * linux-aarch64-low.c: Include nat/aarch64-linux.h.
7992 (aarch64_init_debug_reg_state): Make it extern.
7993 (aarch64_linux_prepare_to_resume): Remove.
7994
f6011a1c
YQ
79952015-08-25 Yao Qi <yao.qi@linaro.org>
7996
7997 * linux-aarch64-low.c (aarch64_linux_prepare_to_resume): Use
7998 lwp_arch_private_info and ptid_of_lwp.
7999
88e2cf7e
YQ
80002015-08-25 Yao Qi <yao.qi@linaro.org>
8001
8002 * linux-aarch64-low.c (aarch64_get_debug_reg_state): Add argument pid.
8003 Find proc_info by find_process_pid. All callers updated.
8004
5e35436e
YQ
80052015-08-25 Yao Qi <yao.qi@linaro.org>
8006
8007 * linux-aarch64-low.c (struct arch64_dr_update_callback_param):
8008 Remove.
8009 (debug_reg_change_callback): Remove.
8010 (aarch64_notify_debug_reg_change): Remove.
8011
4a8a7965
YQ
80122015-08-25 Yao Qi <yao.qi@linaro.org>
8013
8014 * linux-aarch64-low.c (aarch64_notify_debug_reg_change):
8015 Call current_lwp_ptid.
8016
32a271ee
YQ
80172015-08-25 Yao Qi <yao.qi@linaro.org>
8018
8019 * linux-aarch64-low.c (debug_reg_change_callback): Use
8020 debug_printf.
8021
0d51c8d7
YQ
80222015-08-25 Yao Qi <yao.qi@linaro.org>
8023
8024 * linux-aarch64-low.c (debug_reg_change_callback): Use phex.
8025
31a43dd5
YQ
80262015-08-25 Yao Qi <yao.qi@linaro.org>
8027
8028 * linux-aarch64-low.c (debug_reg_change_callback): Remove comments.
8029
8ee52567
YQ
80302015-08-25 Yao Qi <yao.qi@linaro.org>
8031
8032 * linux-aarch64-low.c (debug_reg_change_callback): Re-indent
8033 the code.
8034
ff3f0f45
YQ
80352015-08-25 Yao Qi <yao.qi@linaro.org>
8036
8037 * linux-aarch64-low.c (aarch64_dr_update_callback_param) <pid>:
8038 Remove.
8039 (debug_reg_change_callback): Remove argument entry and add argument
8040 lwp. Remove local variable thread. Don't print thread id in the
8041 debugging output. Don't check whether pid of thread equals to pid.
8042 (aarch64_notify_debug_reg_change): Don't set param.pid. Call
8043 iterate_over_lwps instead find_inferior.
8044
3d40fbb5
PA
80452015-08-24 Pedro Alves <palves@redhat.com>
8046
8047 * inferiors.c (get_first_process): New function.
8048 * inferiors.h (get_first_process): New declaration.
8049 * remote-utils.c (read_ptid): Default to the first process in the
8050 list, instead of to the current thread's process.
8051
438e1e42
PA
80522015-08-24 Pedro Alves <palves@redhat.com>
8053
8054 * debug.c: Include gdb_sys_time.h instead of sys/time.h.
8055 * event-loop.c: Likewise.
8056 * remote-utils.c: Likewise.
8057 * tracepoint.c: Likewise.
8058
a8c6d4fc
PA
80592015-08-24 Pedro Alves <palves@redhat.com>
8060
8061 * spu-low.c (spu_request_interrupt): Use lwpid_of instead of
8062 ptid_get_lwp.
8063
99b0bb12
PA
80642015-08-21 Pedro Alves <palves@redhat.com>
8065
8066 * ax.c (gdb_eval_agent_expr): Return expr_eval_unhandled_opcode
8067 instead of literal 1.
8068
f8904751
PA
80692015-08-21 Pedro Alves <palves@redhat.com>
8070
8071 * tdesc.c (default_description): Explicitly zero-initialize.
8072
465a859e
PA
80732015-08-21 Pedro Alves <palves@redhat.com>
8074
8075 PR gdb/18749
8076 * inferiors.c (remove_thread): Discard any pending stop reply for
8077 this thread.
8078 * server.c (remove_all_on_match_pid): Rename to ...
8079 (remove_all_on_match_ptid): ... this. Work with a filter ptid
8080 instead of a pid.
8081 (discard_queued_stop_replies): Change parameter to a ptid. Now
8082 extern.
8083 (handle_v_kill, kill_inferior_callback, captured_main)
8084 (process_serial_event): Adjust.
8085 * server.h (discard_queued_stop_replies): Declare.
8086
f0db101d
PA
80872015-08-21 Pedro Alves <palves@redhat.com>
8088
8089 * linux-low.c (wait_for_sigstop): Always switch to no thread
8090 selected if the previously current thread dies.
8091 * lynx-low.c (lynx_request_interrupt): Use the first thread's
8092 process instead of the current thread's.
8093 * remote-utils.c (input_interrupt): Don't check if there's no
8094 current thread.
8095 * server.c (gdb_read_memory, gdb_write_memory): If setting the
8096 current thread to the general thread fails, error out.
8097 (handle_qxfer_auxv, handle_qxfer_libraries)
8098 (handle_qxfer_libraries_svr4, handle_qxfer_siginfo)
8099 (handle_qxfer_spu, handle_qxfer_statictrace, handle_qxfer_fdpic)
8100 (handle_query): Check if there's a thread selected instead of
8101 checking whether there's any thread in the thread list.
8102 (handle_qxfer_threads, handle_qxfer_btrace)
8103 (handle_qxfer_btrace_conf): Don't error out early if there's no
8104 thread in the thread list.
8105 (handle_v_cont, myresume): Don't set the current thread to the
8106 continue thread.
8107 (process_serial_event) <Hg handling>: Also set thread_id if the
8108 previous general thread is still alive.
8109 (process_serial_event) <g/G handling>: If setting the current
8110 thread to the general thread fails, error out.
8111 * spu-low.c (spu_resume, spu_request_interrupt): Use the first
8112 thread's lwp instead of the current thread's.
8113 * target.c (set_desired_thread): If the desired thread was not
8114 found, leave the current thread pointing to NULL. Return an int
8115 (boolean) indicating success.
8116 * target.h (set_desired_thread): Change return type to int.
8117
40045d91
MF
81182015-08-20 Max Filippov <jcmvbkbc@gmail.com>
8119
8120 * configure.srv (xtensa*-*-linux*): Add srv_linux_thread_db=yes.
8121 * linux-xtensa-low.c (arch/xtensa.h gdb_proc_service.h): New
8122 #includes.
8123 (ps_get_thread_area): New function.
8124
45face3b
GB
81252015-08-19 Gary Benson <gbenson@redhat.com>
8126
8127 * hostio.c (handle_pread): Do not attempt to read more data
8128 than hostio_reply_with_data can fit in a packet.
8129
16d5f642
JB
81302015-08-18 Joel Brobecker <brobecker@adacore.com>
8131
8132 * linux-aarch32-low.c (NT_ARM_VFP): Define if not already defined.
8133
a738da3a
MF
81342015-08-14 Matthew Fortune <matthew.fortune@imgtec.com>
8135
8136 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP_REL.
8137
33ebda9d
PA
81382015-08-06 Pedro Alves <palves@redhat.com>
8139
8140 * tracepoint.c (expr_eval_result): Now an int.
8141
a44892be
PA
81422015-08-06 Pedro Alves <palves@redhat.com>
8143
8144 * gdbthread.h (struct regcache): Forward declare.
8145 (struct thread_info) <regcache_data>: Now a struct regcache
8146 pointer.
8147 * inferiors.c (inferior_regcache_data)
8148 (set_inferior_regcache_data): Now work with struct regcache
8149 pointers.
8150 * inferiors.h (struct regcache): Forward declare.
8151 (inferior_regcache_data, set_inferior_regcache_data): Now work
8152 with struct regcache pointers.
8153 * regcache.c (get_thread_regcache, regcache_invalidate_thread)
8154 (free_register_cache_thread): Remove struct regcache pointer
8155 casts.
8156
608a1e46
PA
81572015-08-06 Pedro Alves <palves@redhat.com>
8158
8159 * server.c (captured_main): On error, print the exception message
8160 to stderr, and if run_once is set, throw a quit.
8161
f0ce0d3a
PA
81622015-08-06 Pedro Alves <palves@redhat.com>
8163
8164 * linux-low.c (move_out_of_jump_pad_callback): Temporarily switch
8165 the current thread.
8166
bf47e248
PA
81672015-08-06 Pedro Alves <palves@redhat.com>
8168
8169 * linux-low.c (linux_write_memory): Rewrite debug output to avoid
8170 reading beyond the passed in buffer length.
8171
b6b9ffcc
PL
81722015-08-06 Pierre Langlois <pierre.langlois@arm.com>
8173
8174 * tracepoint.c (symbol_list) <required>: Remove.
8175
863d01bd
PA
81762015-08-06 Pedro Alves <palves@redhat.com>
8177
8178 * linux-low.c (handle_extended_wait): Set the fork child's suspend
8179 count if stopping and suspending threads.
8180 (check_stopped_by_breakpoint): If stopped by trace, set the LWP's
8181 stop reason to TARGET_STOPPED_BY_SINGLE_STEP.
8182 (linux_detach): Complete an ongoing step-over.
8183 (lwp_suspended_inc, lwp_suspended_decr): New functions. Use
8184 throughout.
8185 (resume_stopped_resumed_lwps): Don't resume a suspended thread.
8186 (linux_wait_1): If passing a signal to the inferior after
8187 finishing a step-over, unsuspend and re-resume all lwps. If we
8188 see a single-step event but the thread should be continuing, don't
8189 pass the trap to gdb.
8190 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback): Use
8191 internal_error instead of gdb_assert.
8192 (enqueue_pending_signal): New function.
8193 (check_ptrace_stopped_lwp_gone): Add debug output.
8194 (start_step_over): Use internal_error instead of gdb_assert.
8195 (complete_ongoing_step_over): New function.
8196 (linux_resume_one_thread): Don't resume a suspended thread.
8197 (proceed_one_lwp): If the LWP is stepping over a breakpoint, reset
8198 it stepping.
8199
00db26fa
PA
82002015-08-06 Pedro Alves <palves@redhat.com>
8201
8202 * linux-low.c (add_lwp): Set waitstatus to TARGET_WAITKIND_IGNORE.
8203 (linux_thread_alive): Use lwp_is_marked_dead.
8204 (extended_event_reported): Delete.
8205 (linux_wait_1): Check if waitstatus is TARGET_WAITKIND_IGNORE
8206 instead of extended_event_reported.
8207 (mark_lwp_dead): Don't set the 'dead' flag. Store the waitstatus
8208 as well.
8209 (lwp_is_marked_dead): New function.
8210 (lwp_running): Use lwp_is_marked_dead.
8211 * linux-low.h: Delete 'dead' field, and update 'waitstatus's
8212 comment.
8213
ad071a30
PA
82142015-08-06 Pedro Alves <palves@redhat.com>
8215
8216 * linux-low.c (linux_wait_1): Move fork event output out of the
8217 !report_to_gdb check. Pass event_child->waitstatus to
8218 target_waitstatus_to_string instead of ourstatus.
8219
524b57e6
YQ
82202015-08-04 Yao Qi <yao.qi@linaro.org>
8221
8222 * linux-aarch64-low.c (aarch64_supports_tracepoints): Return 0
8223 if current_thread is 32 bit.
8224
6085d6f6
YQ
82252015-08-04 Yao Qi <yao.qi@linaro.org>
8226
8227 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
8228 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
8229 * server.c (extended_protocol): Remove "static".
8230 * server.h (extended_protocol): Declare it.
8231
8a7e4587
YQ
82322015-08-04 Yao Qi <yao.qi@linaro.org>
8233
8234 * linux-aarch64-low.c (aarch64_get_pc): Get PC register on
8235 both aarch64 and aarch32.
8236 (aarch64_set_pc): Likewise.
8237
3b53ae99
YQ
82382015-08-04 Yao Qi <yao.qi@linaro.org>
8239
8240 * configure.srv (case aarch64*-*-linux*): Append arm-with-neon.o
8241 to srv_regobj and append arm-core.xml arm-vfpv3.xml and
8242 arm-with-neon.xml to srv_xmlfiles.
8243 * linux-aarch64-low.c: Include linux-aarch32-low.h.
8244 (is_64bit_tdesc): New function.
8245 (aarch64_linux_read_description): New function.
8246 (aarch64_arch_setup): Call aarch64_linux_read_description.
8247 (regs_info): Rename to regs_info_aarch64.
8248 (aarch64_regs_info): Return right regs_info.
8249 (initialize_low_arch): Call initialize_low_arch_aarch32.
8250
bd9e6534
YQ
82512015-08-04 Yao Qi <yao.qi@linaro.org>
8252
8253 * configure.srv (srv_tgtobj): Add linux-aarch32-low.o.
8254 * linux-aarch32-low.c: New file.
8255 * linux-aarch32-low.h: New file.
8256 * linux-arm-low.c (arm_fill_gregset): Move it to
8257 linux-aarch32-low.c.
8258 (arm_store_gregset): Likewise.
8259 (arm_fill_vfpregset): Call arm_fill_vfpregset_num
8260 (arm_store_vfpregset): Call arm_store_vfpregset_num.
8261 (arm_arch_setup): Check if PTRACE_GETREGSET works.
8262 (regs_info): Rename to regs_info_arm.
8263 (arm_regs_info): Return regs_info_aarch32 if
8264 have_ptrace_getregset is 1 and target description is
8265 arm_with_neon or arm_with_vfpv3.
8266 (initialize_low_arch): Don't call init_registers_arm_with_neon.
8267 Call initialize_low_arch_aarch32 instead.
8268
ded48a5e
YQ
82692015-08-04 Yao Qi <yao.qi@linaro.org>
8270
8271 * linux-x86-low.c (have_ptrace_getregset): Move it to ...
8272 * linux-low.c: ... here.
8273 * linux-low.h (have_ptrace_getregset): Declare it.
8274
96e9210f
PA
82752015-08-04 Pedro Alves <palves@redhat.com>
8276
8277 * thread-db.c (struct thread_db): Use new typedefs.
8278 (try_thread_db_load_1): Define local TDB_DLSYM macro and use it in
8279 CHK calls.
8280 (disable_thread_event_reporting): Cast result of dlsym to
8281 destination function pointer type.
8282 (thread_db_mourn): Use td_ta_delete_ftype.
8283
af60a1ef
SL
82842015-08-03 Sandra Loosemore <sandra@codesourcery.com>
8285
8286 * linux-nios2-low.c (NIOS2_BREAKPOINT): Conditionalize for
8287 arch variant.
8288 (CDX_BREAKPOINT): Define for R2.
8289 (nios2_breakpoint_at): Check for CDX_BREAKPOINT when R2.
8290 (the_low_target): Add comments.
8291
e8b41681
YQ
82922015-07-30 Yao Qi <yao.qi@linaro.org>
8293
8294 * linux-arm-low.c (arm_hwcap): Remove it.
8295 (arm_read_description): New local variable arm_hwcap. Don't
8296 set arm_hwcap to zero.
8297
89abb039
YQ
82982015-07-30 Yao Qi <yao.qi@linaro.org>
8299
8300 * linux-arm-low.c (arm_fill_wmmxregset): Don't use arm_hwcap.
8301 Use regcache->tdesc instead.
8302 (arm_store_wmmxregset): Likewise.
8303 (arm_fill_vfpregset): Likewise.
8304 (arm_store_vfpregset): Likewise.
8305
deca266c
YQ
83062015-07-30 Yao Qi <yao.qi@linaro.org>
8307
8308 * linux-arm-low.c: Include arch/arm.h.
8309 (arm_fill_gregset): Don't use arm_num_regs and arm_regmap.
8310 (arm_store_gregset): Likewise.
8311
aa58a496
SM
83122015-07-29 Simon Marchi <simon.marchi@ericsson.com>
8313
8314 * linux-mips-low.c (mips_linux_prepare_to_resume): Add NULL as
8315 ptrace's 4th parameter.
8316
50904b25
YQ
83172015-07-27 Yao Qi <yao.qi@linaro.org>
8318
8319 * configure.srv (case aarch64*-*-linux*): Don't set
8320 srv_linux_usrregs.
8321
5826e159
PA
83222015-07-24 Pedro Alves <palves@redhat.c: Likewise.om>
8323
8324 * linux-aarch64-low.c: Include nat/gdb_ptrace.h instead of
8325 sys/ptrace.h.
8326 * linux-arm-low.c: Likewise.
8327 * linux-cris-low.c: Likewise.
8328 * linux-crisv32-low.c: Likewise.
8329 * linux-low.c: Likewise.
8330 * linux-m68k-low.c: Likewise.
8331 * linux-mips-low.c: Likewise.
8332 * linux-nios2-low.c: Likewise.
8333 * linux-s390-low.c: Likewise.
8334 * linux-sparc-low.c: Likewise.
8335 * linux-tic6x-low.c: Likewise.
8336 * linux-tile-low.c: Likewise.
8337 * linux-x86-low.c: Likewise.
8338
54019719
PA
83392015-07-24 Pedro Alves <palves@redhat.com>
8340
8341 * config.in: Regenerate.
8342 * configure: Regenerate.
8343
eb7aa561
PA
83442015-07-24 Pedro Alves <palves@redhat.com>
8345
8346 * acinclude.m4: Include ../ptrace.m4.
8347 * configure.ac: Call GDB_AC_PTRACE.
8348 * config.in, configure: Regenerate.
8349
55d7b841
YQ
83502015-07-24 Yao Qi <yao.qi@linaro.org>
8351
8352 * linux-low.c (linux_create_inferior): Remove setting to
8353 proc->priv->new_inferior.
8354 (linux_attach): Likewise.
8355 (linux_low_filter_event): Likewise.
8356 * linux-low.h (struct process_info_private) <new_inferior>: Remove.
8357
c06cbd92
YQ
83582015-07-24 Yao Qi <yao.qi@linaro.org>
8359
8360 * linux-low.c (linux_arch_setup): New function.
8361 (linux_low_filter_event): If proc->tdesc is NULL and
8362 proc->attached is true, call the_low_target.arch_setup.
8363 Otherwise, keep status pending, and return.
8364 (linux_resume_one_lwp_throw): Don't call get_pc if
8365 thread->while_stepping isn't NULL. Don't call
8366 get_thread_regcache if proc->tdesc is NULL.
8367 (need_step_over_p): Return 0 if proc->tdesc is NULL.
8368 (linux_target_ops): Install arch_setup.
8369 * server.c (start_inferior): Call the_target->arch_setup.
8370 * target.h (struct target_ops) <arch_setup>: New field.
8371 (target_arch_setup): New marco.
8372 * lynx-low.c (lynx_target_ops): Update.
8373 * nto-low.c (nto_target_ops): Update.
8374 * spu-low.c (spu_target_ops): Update.
8375 * win32-low.c (win32_target_ops): Update.
8376
5ae3ebba
YQ
83772015-07-24 Yao Qi <yao.qi@linaro.org>
8378
8379 * linux-low.c (linux_add_process): Don't set
8380 proc->priv->new_inferior.
8381 (linux_create_inferior): Set proc->priv->new_inferior to 1.
8382 (linux_attach): Likewise.
8383
eb97750b
YQ
83842015-07-24 Yao Qi <yao.qi@linaro.org>
8385
8386 * server.c (start_inferior): Code refactor.
8387
51aee833
YQ
83882015-07-24 Yao Qi <yao.qi@linaro.org>
8389
8390 * server.c (process_serial_event): Set general_thread.
8391
af1b22f3
YQ
83922015-07-21 Yao Qi <yao.qi@linaro.org>
8393
8394 * linux-aarch64-low.c (aarch64_arch_setup): Remove code and call
8395 aarch64_linux_get_debug_reg_capacity.
8396
554717a3
YQ
83972015-07-17 Yao Qi <yao.qi@linaro.org>
8398
8399 * Makefile.in (aarch64-linux-hw-point.o): New rule.
8400 * configure.srv (srv_tgtobj): Append aarch64-linux-hw-point.o.
8401 * linux-aarch64-low.c: Include nat/aarch64-linux-hw-point.h.
8402 (AARCH64_HBP_MAX_NUM): Move to nat/aarch64-linux-hw-point.h.
8403 (AARCH64_HWP_MAX_NUM, AARCH64_HBP_ALIGNMENT): Likewise.
8404 (AARCH64_HWP_ALIGNMENT): Likewise.
8405 (AARCH64_HWP_MAX_LEN_PER_REG): Likewise.
8406 (AARCH64_DEBUG_NUM_SLOTS, AARCH64_DEBUG_ARCH): Likewise.
8407 (aarch64_num_bp_regs, aarch64_num_wp_regs): Likewise.
8408 (AARCH64_DEBUG_ARCH_V8, DR_MARK_ALL_CHANGED): Likewise.
8409 (DR_MARK_N_CHANGED, DR_CLEAR_CHANGED): Likewise.
8410 (DR_HAS_CHANGED, DR_N_HAS_CHANGE): Likewise.
8411 (struct aarch64_debug_reg_state): Likewise.
8412 (struct arch_lwp_info): Likewise.
8413 (aarch64_align_watchpoint): Likewise.
8414 (DR_CONTROL_ENABLED, DR_CONTROL_LENGTH): Likewise.
8415 (aarch64_watchpoint_length): Likewise.
8416 (aarch64_point_encode_ctrl_reg): Likewise
8417 (aarch64_point_is_aligned): Likewise.
8418 (aarch64_align_watchpoint): Likewise.
8419 (aarch64_linux_set_debug_regs):
8420 (aarch64_dr_state_insert_one_point): Likewise.
8421 (aarch64_dr_state_remove_one_point): Likewise.
8422 (aarch64_handle_breakpoint): Likewise.
8423 (aarch64_handle_aligned_watchpoint): Likewise.
8424 (aarch64_handle_unaligned_watchpoint): Likewise.
8425 (aarch64_handle_watchpoint): Likewise.
8426
c67ca4de
YQ
84272015-07-17 Yao Qi <yao.qi@linaro.org>
8428
8429 * linux-aarch64-low.c (aarch64_handle_breakpoint): Add argument state
8430 and don't aarch64_get_debug_reg_state. All callers update.
8431 (aarch64_handle_aligned_watchpoint): Likewise.
8432 (aarch64_handle_unaligned_watchpoint): Likewise.
8433 (aarch64_handle_watchpoint): Likewise.
8434 (aarch64_insert_point): Call aarch64_get_debug_reg_state earlier.
8435 (aarch64_remove_point): Likewise.
8436
25abf979
YQ
84372015-07-17 Yao Qi <yao.qi@linaro.org>
8438
8439 * linux-aarch64-low.c (aarch64_show_debug_reg_state): Use
8440 debug_printf.
8441 (aarch64_handle_unaligned_watchpoint): Likewise.
8442
db1ff28b
JK
84432015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
8444
8445 Revert the previous 3 commits:
8446 Move gdb_regex* to common/
8447 Move linux_find_memory_regions_full & co.
8448 gdbserver build-id attribute generator
8449
700ca40f
JK
84502015-07-15 Aleksandar Ristovski <aristovski@qnx.com
8451 Jan Kratochvil <jan.kratochvil@redhat.com>
8452
8453 gdbserver build-id attribute generator.
8454 * linux-low.c (nat/linux-maps.h, search.h, rsp-low.h): Include.
8455 (ElfXX_Ehdr, ElfXX_Phdr, ElfXX_Nhdr): New.
8456 (ELFXX_FLD, ELFXX_SIZEOF, ELFXX_ROUNDUP, BUILD_ID_INVALID): New.
8457 (find_phdr): New.
8458 (get_dynamic): Use find_pdhr to traverse program headers.
8459 (struct mapping_entry, mapping_entry_s, free_mapping_entry_vec)
8460 (compare_mapping_entry_range, struct find_memory_region_callback_data)
8461 (read_build_id, find_memory_region_callback, lrfind_mapping_entry)
8462 (get_hex_build_id): New.
8463 (linux_qxfer_libraries_svr4): Add optional build-id attribute
8464 to reply XML document.
8465
9904185c
JK
84662015-07-15 Aleksandar Ristovski <aristovski@qnx.com
8467 Jan Kratochvil <jan.kratochvil@redhat.com>
8468
8469 * target.c: Include target/target-utils.h and fcntl.h.
8470 (target_fileio_read_stralloc_1_pread, target_fileio_read_stralloc_1)
8471 (target_fileio_read_stralloc): New functions.
8472
6e5b4429
JK
84732015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
8474
8475 * Makefile.in (OBS): Add gdb_regex.o.
8476 (gdb_regex.o): New.
8477 * config.in: Rebuilt.
8478 * configure: Rebuilt.
8479
ddc98fbf
JK
84802015-07-15 Aleksandar Ristovski <aristovski@qnx.com
8481 Jan Kratochvil <jan.kratochvil@redhat.com>
8482
8483 Create empty nat/linux-maps.[ch] and common/target-utils.[ch].
8484 * Makefile.in (OBS): Add target-utils.o.
8485 (linux-maps.o, target-utils.o): New.
8486 * configure.srv (srv_linux_obj): Add linux-maps.o.
8487
e57bb7a0
PL
84882015-07-15 Pierre Langlois <pierre.langlois@arm.com>
8489
8490 * linux-aarch64-low.c (aarch64_supports_range_stepping): New
8491 function, return 1.
8492 (the_low_target): Install it.
8493
586b02a9
PA
84942015-07-14 Pedro Alves <palves@redhat.com>
8495
8496 * linux-low.c (kill_wait_lwp): Don't assert if waitpid fails.
8497 Instead, ignore ECHILD, and throw an error for other errnos.
8498
58c1b36c
PA
84992015-07-10 Pedro Alves <palves@redhat.com>
8500
8501 * event-loop.c (struct callback_event) <data>: Change type to
8502 gdb_client_data instance instead of gdb_client_data pointer.
8503 (append_callback_event): Adjust.
8504
421530db
PL
85052015-07-10 Pierre Langlois <pierre.langlois@arm.com>
8506
8507 * linux-aarch64-low.c: Add comments for each linux_target_ops
8508 method. Remove comments already covered in target_ops and
8509 linux_target_ops definitions.
8510 (the_low_target): Add comments for each unimplemented method.
8511
c2d65f38
YQ
85122015-07-09 Yao Qi <yao.qi@linaro.org>
8513
8514 * linux-aarch64-low.c (aarch64_regmap): Remove.
8515 (aarch64_usrregs_info): Remove.
8516 (regs_info): Set field usrregs to NULL.
8517
b20a6524
MM
85182015-07-02 Markus Metzger <markus.t.metzger@intel.com>
8519
8520 * linux-low.c: Include "rsp-low.h"
8521 (linux_low_encode_pt_config, linux_low_encode_raw): New.
8522 (linux_low_read_btrace): Support BTRACE_FORMAT_PT.
8523 (linux_low_btrace_conf): Support BTRACE_FORMAT_PT.
8524 (handle_btrace_enable_pt): New.
8525 (handle_btrace_general_set): Support "pt".
8526 (handle_btrace_conf_general_set): Support "pt:size".
8527
96c97461
PL
85282015-06-29 Pierre Langlois <pierre.langlois@arm.com>
8529
8530 * linux-aarch64-low.c (aarch64_supports_z_point_type): Enable for
8531 Z_PACKET_SW_BP.
8532
37d66942
PL
85332015-06-29 Pierre Langlois <pierre.langlois@arm.com>
8534
8535 * linux-aarch64-low.c: Remove comment about endianness.
8536 (aarch64_breakpoint): Change type to gdb_byte[]. Set to "brk #0".
8537 (aarch64_breakpoint_at): Change type of insn to gdb_byte[]. Use
8538 memcmp.
8539
dc06243f
GB
85402015-06-24 Gary Benson <gbenson@redhat.com>
8541
8542 * linux-i386-ipa.c (stdint.h): Do not include.
8543 * lynx-i386-low.c (stdint.h): Likewise.
8544 * lynx-ppc-low.c (stdint.h): Likewise.
8545 * mem-break.c (stdint.h): Likewise.
8546 * thread-db.c (stdint.h): Likewise.
8547 * tracepoint.c (stdint.h): Likewise.
8548 * win32-low.c (stdint.h): Likewise.
8549
124e13d9
SM
85502015-06-18 Simon Marchi <simon.marchi@ericsson.com>
8551
8552 * server.c (write_qxfer_response): Update call to
8553 remote_escape_output.
8554
909c2cda
JK
85552015-06-15 Aleksandar Ristovski <aristovski@qnx.com
8556 Jan Kratochvil <jan.kratochvil@redhat.com>
8557
8558 Merge multiple hex conversions.
8559 * gdbreplay.c (tohex): Rename to 'fromhex'.
8560 (logchar): Use fromhex.
8561
24c05f46
JK
85622015-06-10 Jan Kratochvil <jan.kratochvil@redhat.com>
8563
8564 * server.c (handle_qxfer_libraries): Set `version' attribute for
8565 <library-list>.
8566
14d2069a
GB
85672015-06-10 Gary Benson <gbenson@redhat.com>
8568
8569 * target.h (struct target_ops) <multifs_open>: New field.
8570 <multifs_unlink>: Likewise.
8571 <multifs_readlink>: Likewise.
8572 * linux-low.c (nat/linux-namespaces.h): New include.
8573 (linux_target_ops): Initialize the_target->multifs_open,
8574 the_target->multifs_unlink and the_target->multifs_readlink.
8575 * hostio.h (hostio_handle_new_gdb_connection): New declaration.
8576 * hostio.c (hostio_fs_pid): New static variable.
8577 (hostio_handle_new_gdb_connection): New function.
8578 (handle_setfs): Likewise.
8579 (handle_open): Use the_target->multifs_open as appropriate.
8580 (handle_unlink): Use the_target->multifs_unlink as appropriate.
8581 (handle_readlink): Use the_target->multifs_readlink as
8582 appropriate.
8583 (handle_vFile): Handle vFile:setfs packets.
8584 * server.c (handle_query): Call hostio_handle_new_gdb_connection
8585 after target_handle_new_gdb_connection.
8586
4b8b5e72
GB
85872015-06-10 Gary Benson <gbenson@redhat.com>
8588
8589 * configure.ac (AC_CHECK_FUNCS): Add setns.
8590 * config.in: Regenerate.
8591 * configure: Likewise.
8592 * Makefile.in (SFILES): Add nat/linux-namespaces.c.
8593 (linux-namespaces.o): New rule.
8594 * configure.srv (srv_linux_obj): Add linux-namespaces.o.
8595
3ac2e371
GB
85962015-06-09 Gary Benson <gbenson@redhat.com>
8597
8598 * hostio.c (handle_open): Process mode argument with
8599 fileio_to_host_mode.
8600
ca9b78ce
YQ
86012015-06-01 Yao Qi <yao.qi@linaro.org>
8602
8603 * linux-s390-low.c (PTRACE_GETREGSET, PTRACE_SETREGSET): Remove.
8604 * linux-x86-low.c: Likewise.
8605
bfacd19d
DB
86062015-05-28 Don Breazeal <donb@codesourcery.com>
8607
8608 * linux-low.c (handle_extended_wait): Initialize
8609 thread_info.last_resume_kind for new fork children.
8610
452003ef
PA
86112015-05-15 Pedro Alves <palves@redhat.com>
8612
8613 * target.h (target_handle_new_gdb_connection): Rewrite using if
8614 wrapped in do/while.
8615
1041a03c
JB
86162015-05-14 Joel Brobecker <brobecker@adacore.com>
8617
8618 * configure.ac: Add prfpregset_t BFD_HAVE_SYS_PROCFS_TYPE check.
8619 * configure, config.in: Regenerate.
8620 * gdb_proc_service.h [HAVE_PRFPREGSET_T] (prfpregset_t):
8621 Declare typedef.
8622
c269dbdb
DB
86232015-05-12 Don Breazeal <donb@codesourcery.com>
8624
8625 * linux-low.c (handle_extended_wait): Handle PTRACE_EVENT_FORK and
8626 PTRACE_EVENT_VFORK_DONE.
8627 (linux_low_ptrace_options, extended_event_reported): Add vfork
8628 events.
8629 * remote-utils.c (prepare_resume_reply): New stop reasons "vfork"
8630 and "vforkdone" for RSP 'T' Stop Reply Packet.
8631 * server.h (report_vfork_events): Declare
8632 global variable.
8633
3a8a0396
DB
86342015-05-12 Don Breazeal <donb@codesourcery.com>
8635
8636 * linux-aarch64-low.c (aarch64_linux_new_fork): New function.
8637 (the_low_target) <new_fork>: Initialize new member.
8638 * linux-arm-low.c (arm_new_fork): New function.
8639 (the_low_target) <new_fork>: Initialize new member.
8640 * linux-low.c (handle_extended_wait): Call new target function
8641 new_fork.
8642 * linux-low.h (struct linux_target_ops) <new_fork>: New member.
8643 * linux-mips-low.c (mips_add_watchpoint): New function
8644 extracted from mips_insert_point.
8645 (the_low_target) <new_fork>: Initialize new member.
8646 (mips_linux_new_fork): New function.
8647 (mips_insert_point): Call mips_add_watchpoint.
8648 * linux-x86-low.c (x86_linux_new_fork): New function.
8649 (the_low_target) <new_fork>: Initialize new member.
8650
de0d863e
DB
86512015-05-12 Don Breazeal <donb@codesourcery.com>
8652
8653 * linux-low.c (handle_extended_wait): Implement return value,
8654 rename argument 'event_child' to 'event_lwp', handle
8655 PTRACE_EVENT_FORK, call internal_error for unrecognized event.
8656 (linux_low_ptrace_options): New function.
8657 (linux_low_filter_event): Call linux_low_ptrace_options,
8658 use different argument fo linux_enable_event_reporting,
8659 use return value from handle_extended_wait.
8660 (extended_event_reported): New function.
8661 (linux_wait_1): Call extended_event_reported and set
8662 status to report fork events.
8663 (linux_write_memory): Add pid to debug message.
8664 (reset_lwp_ptrace_options_callback): New function.
8665 (linux_handle_new_gdb_connection): New function.
8666 (linux_target_ops): Initialize new structure member.
8667 * linux-low.h (struct lwp_info) <waitstatus>: New member.
8668 * lynx-low.c: Initialize new structure member.
8669 * remote-utils.c (prepare_resume_reply): Implement stop reason
8670 "fork" for "T" stop message.
8671 * server.c (handle_query): Call handle_new_gdb_connection.
8672 * server.h (report_fork_events): Declare global flag.
8673 * target.h (struct target_ops) <handle_new_gdb_connection>:
8674 New member.
8675 (target_handle_new_gdb_connection): New macro.
8676 * win32-low.c: Initialize new structure member.
8677
ddcbc397
DB
86782015-05-12 Don Breazeal <donb@codesourcery.com>
8679
8680 * mem-break.c (APPEND_TO_LIST): Define macro.
8681 (clone_agent_expr): New function.
8682 (clone_one_breakpoint): New function.
8683 (clone_all_breakpoints): New function.
8684 * mem-break.h: Declare new functions.
8685
89245bc0
DB
86862015-05-12 Don Breazeal <donb@codesourcery.com>
8687
8688 * linux-low.c (linux_supports_fork_events): New function.
8689 (linux_supports_vfork_events): New function.
8690 (linux_target_ops): Initialize new structure members.
8691 (initialize_low): Call linux_check_ptrace_features.
8692 * lynx-low.c (lynx_target_ops): Initialize new structure
8693 members.
8694 * server.c (report_fork_events, report_vfork_events):
8695 New global flags.
8696 (handle_query): Add new features to qSupported packet and
8697 response.
8698 (captured_main): Initialize new global variables.
8699 * target.h (struct target_ops) <supports_fork_events>:
8700 New member.
8701 <supports_vfork_events>: New member.
8702 (target_supports_fork_events): New macro.
8703 (target_supports_vfork_events): New macro.
8704 * win32-low.c (win32_target_ops): Initialize new structure
8705 members.
8706
835205d0
GB
87072015-05-12 Gary Benson <gbenson@redhat.com>
8708
8709 * server.c (handle_qxfer_exec_file): Use current process
8710 if annex is empty.
8711
21e94bd9
SL
87122015-05-08 Sandra Loosemore <sandra@codesourcery.com>
8713
8714 * linux-nios2-low.c: Include elf/common.h. Adjust comments.
8715 Remove HAVE_PTRACE_GETREGS conditionals.
8716 (nios2_regsets): Use PTRACE_GETREGSET and PTRACE_SETREGSET
8717 instead of PTRACE_GETREGS and PTRACE_SETREGS.
8718
45614f15
YQ
87192015-05-08 Yao Qi <yao.qi@linaro.org>
8720
8721 * linux-low.c (linux_supports_conditional_breakpoints): New
8722 function.
8723 (linux_target_ops): Install new target method.
8724 * lynx-low.c (lynx_target_ops): Install NULL hook for
8725 supports_conditional_breakpoints.
8726 * nto-low.c (nto_target_ops): Likewise.
8727 * spu-low.c (spu_target_ops): Likewise.
8728 * win32-low.c (win32_target_ops): Likewise.
8729 * server.c (handle_query): Check
8730 target_supports_conditional_breakpoints.
8731 * target.h (struct target_ops) <supports_conditional_breakpoints>:
8732 New field.
8733 (target_supports_conditional_breakpoints): New macro.
8734
80ad801e
PA
87352015-05-06 Pedro Alves <palves@redhat.com>
8736
8737 PR server/18081
8738 * server.c (start_inferior): If the process exits, mourn it.
8739
819843c7
GB
87402015-04-21 Gary Benson <gbenson@redhat.com>
8741
8742 * hostio.c (fileio_open_flags_to_host): Factored out to
8743 fileio_to_host_openflags in common/fileio.c. Single use
8744 updated.
8745
a2d5a9d7
MF
87462015-04-17 Max Filippov <jcmvbkbc@gmail.com>
8747
8748 * linux-xtensa-low.c (xtensa_fill_gregset)
8749 (xtensa_store_gregset): Check XCHAL_HAVE_LOOPS instead of
8750 XCHAL_HAVE_LOOP.
8751
deb44829
MF
87522015-04-17 Max Filippov <jcmvbkbc@gmail.com>
8753
8754 * linux-xtensa-low.c (xtensa_usrregs_info): Remove.
8755 (regs_info): Replace usrregs pointer with NULL.
8756
e57f1de3
GB
87572015-04-17 Gary Benson <gbenson@redhat.com>
8758
8759 * target.h (struct target_ops) <pid_to_exec_file>: New field.
8760 * linux-low.c (linux_target_ops): Initialize pid_to_exec_file.
8761 * server.c (handle_qxfer_exec_file): New function.
8762 (qxfer_packets): Add exec-file entry.
8763 (handle_query): Report qXfer:exec-file:read as supported packet.
8764
62828379
RN
87652015-04-14 Romain Naour <romain.naour@openwide.fr> (tiny change)
8766
8767 * linux-low.c (linux_read_offsets): Remove get_thread_lwp.
8768
b88bb450
GB
87692015-04-09 Gary Benson <gbenson@redhat.com>
8770
8771 * hostio-errno.c (errno_to_fileio_error): Remove function.
8772 Update caller to use remote_fileio_to_fio_error.
8773
c8f4bfdd
YQ
87742015-04-09 Yao Qi <yao.qi@linaro.org>
8775
8776 * linux-low.c (linux_insert_point): Call
8777 insert_memory_breakpoint if TYPE is raw_bkpt_type_sw.
8778 (linux_remove_point): Call remove_memory_breakpoint if type is
8779 raw_bkpt_type_sw.
8780 * linux-x86-low.c (x86_insert_point): Don't call
8781 insert_memory_breakpoint.
8782 (x86_remove_point): Don't call remove_memory_breakpoint.
8783
41f98f02
PA
87842015-04-01 Pedro Alves <palves@redhat.com>
8785 Cleber Rosa <crosa@redhat.com>
8786
8787 * server.c (gdbserver_usage): Reorganize and extend the usage
8788 message.
8789
2bf6fb9d
PA
87902015-03-24 Pedro Alves <palves@redhat.com>
8791
8792 * linux-low.c (check_stopped_by_breakpoint): Tweak debug log
8793 output. Also dump TRAP_TRACE.
8794 (linux_low_filter_event): In debug output, distinguish a
8795 resume_stop SIGSTOP from a delayed SIGSTOP.
8796
369f6daa
GB
87972015-03-24 Gary Benson <gbenson@redhat.com>
8798
8799 * linux-x86-low.c (x86_linux_new_thread): Moved to
8800 nat/x86-linux.c.
8801 (x86_linux_prepare_to_resume): Likewise.
8802
8e5d4070
GB
88032015-03-24 Gary Benson <gbenson@redhat.com>
8804
8805 * Makefile.in (x86-linux-dregs.o): New rule.
8806 * configure.srv: Add x86-linux-dregs.o to relevant targets.
8807 * linux-x86-low.c: Include nat/x86-linux-dregs.h.
8808 (u_debugreg_offset): Moved to nat/x86-linux-dregs.c.
8809 (x86_linux_dr_get): Likewise.
8810 (x86_linux_dr_set): Likewise.
8811 (update_debug_registers_callback): Likewise.
8812 (x86_linux_dr_set_addr): Likewise.
8813 (x86_linux_dr_get_addr): Likewise.
8814 (x86_linux_dr_set_control): Likewise.
8815 (x86_linux_dr_get_control): Likewise.
8816 (x86_linux_dr_get_status): Likewise.
8817 (x86_linux_update_debug_registers): Likewise.
8818
2b95d440
GB
88192015-03-24 Gary Benson <gbenson@redhat.com>
8820
8821 * linux-x86-low.c (x86_linux_update_debug_registers):
8822 New function, factored out from...
8823 (x86_linux_prepare_to_resume): ...this.
8824
14b0bc68
GB
88252015-03-24 Gary Benson <gbenson@redhat.com>
8826
8827 * linux-x86-low.c (x86_linux_dr_get): Update comments.
8828 (x86_linux_dr_set): Likewise.
8829 (update_debug_registers_callback): Likewise.
8830 (x86_linux_dr_set_addr): Likewise.
8831 (x86_linux_dr_get_addr): Likewise.
8832 (x86_linux_dr_set_control): Likewise.
8833 (x86_linux_dr_get_control): Likewise.
8834 (x86_linux_dr_get_status): Likewise.
8835 (x86_linux_prepare_to_resume): Likewise.
8836
5dfe6ca8
GB
88372015-03-24 Gary Benson <gbenson@redhat.com>
8838
8839 * linux-x86-low.c (x86_linux_dr_get): Add assertion.
8840 Use perror_with_name. Pass string through gettext.
8841 (x86_linux_dr_set): Likewise.
8842
d33472ad
GB
88432015-03-24 Gary Benson <gbenson@redhat.com>
8844
8845 * linux-x86-low.c (x86_dr_low_set_addr): Rename to...
8846 (x86_linux_dr_set_addr): ...this.
8847 (x86_dr_low_get_addr): Rename to...
8848 (x86_linux_dr_get_addr): ...this.
8849 (x86_dr_low_set_control): Rename to...
8850 (x86_linux_dr_set_control): ...this.
8851 (x86_dr_low_get_control): Rename to...
8852 (x86_linux_dr_get_control): ...this.
8853 (x86_dr_low_get_status): Rename to...
8854 (x86_linux_dr_get_status): ...this.
8855 (x86_dr_low): Update with new function names.
8856
4b134ca1
GB
88572015-03-24 Gary Benson <gbenson@redhat.com>
8858
8859 * Makefile.in (x86-linux.o): New rule.
8860 * configure.srv: Add x86-linux.o to relevant targets.
8861 * linux-low.c (lwp_set_arch_private_info): New function.
8862 (lwp_arch_private_info): Likewise.
8863 * linux-x86-low.c: Include nat/x86-linux.h.
8864 (arch_lwp_info): Removed structure.
8865 (update_debug_registers_callback):
8866 Use lwp_set_debug_registers_changed.
8867 (x86_linux_prepare_to_resume): Use lwp_debug_registers_changed
8868 and lwp_set_debug_registers_changed.
8869 (x86_linux_new_thread): Use lwp_set_debug_registers_changed.
8870
34c703da
GB
88712015-03-24 Gary Benson <gbenson@redhat.com>
8872
8873 * linux-low.h (linux_target_ops) <new_thread>: Changed signature.
8874 * linux-arm-low.c (arm_new_thread): Likewise.
8875 * linux-aarch64-low.c (aarch64_linux_new_thread): Likewise.
8876 * linux-mips-low.c (mips_linux_new_thread): Likewise.
8877 * linux-x86-low.c (x86_linux_new_thread): Likewise.
8878 * linux-low.c (add_lwp): Update the_low_target.new_thread call.
8879
cff068da
GB
88802015-03-24 Gary Benson <gbenson@redhat.com>
8881
8882 * linux-low.c (ptid_of_lwp): New function.
8883 (lwp_is_stopped): Likewise.
8884 (lwp_stop_reason): Likewise.
8885 * linux-x86-low.c (update_debug_registers_callback):
8886 Use lwp_is_stopped.
8887 (x86_linux_prepare_to_resume): Use ptid_of_lwp and
8888 lwp_stop_reason.
8889
b2f7c7e8
GB
88902015-03-24 Gary Benson <gbenson@redhat.com>
8891
8892 * linux-low.h (linux_stop_lwp): Remove declaration.
8893
6d4ee8c6
GB
88942015-03-24 Gary Benson <gbenson@redhat.com>
8895
8896 * linux-low.h: Include nat/linux-nat.h.
8897 * linux-low.c (iterate_over_lwps_args): New structure.
8898 (iterate_over_lwps_filter): New function.
8899 (iterate_over_lwps): Likewise.
8900 * linux-x86-low.c (update_debug_registers_callback):
8901 Update signature to what iterate_over_lwps expects.
8902 Remove PID check that iterate_over_lwps now performs.
8903 (x86_dr_low_set_addr): Use iterate_over_lwps.
8904 (x86_dr_low_set_control): Likewise.
8905
70a0bb6b
GB
89062015-03-24 Gary Benson <gbenson@redhat.com>
8907
8908 * linux-x86-low.c (x86_debug_reg_state): New function.
8909 (x86_linux_prepare_to_resume): Use the above.
8910
7b669087
GB
89112015-03-24 Gary Benson <gbenson@redhat.com>
8912
8913 * linux-low.c (current_lwp_ptid): New function.
8914 * linux-x86-low.c: Include nat/linux-nat.h.
8915 (x86_dr_low_get_addr): Use current_lwp_ptid.
8916 (x86_dr_low_get_control): Likewise.
8917 (x86_dr_low_get_status): Likewise.
8918
eef49a3d
PA
89192015-03-20 Pedro Alves <palves@redhat.com>
8920
8921 * tracepoint.c (cmd_qtstatus): Make "str" const.
8922
b2333d22
PA
89232015-03-20 Pedro Alves <palves@redhat.com>
8924
8925 * server.c (handle_general_set): Make "req_str" const.
8926
23f238d3
PA
89272015-03-19 Pedro Alves <palves@redhat.com>
8928
8929 * linux-low.c (linux_resume_one_lwp): Rename to ...
8930 (linux_resume_one_lwp_throw): ... this. Don't handle ESRCH here,
8931 instead call perror_with_name.
8932 (check_ptrace_stopped_lwp_gone): New function.
8933 (linux_resume_one_lwp): Reimplement as wrapper around
8934 linux_resume_one_lwp_throw that swallows errors if the LWP is
8935 gone.
8936
91baf43f
PA
89372015-03-19 Pedro Alves <palves@redhat.com>
8938
8939 * linux-low.c (count_events_callback, select_event_lwp_callback):
8940 No longer check whether the thread has resume_stop as last resume
8941 kind.
8942
8bf3b159
PA
89432015-03-19 Pedro Alves <palves@redhat.com>
8944
8945 * linux-low.c (count_events_callback, select_event_lwp_callback):
8946 Use the lwp's status_pending_p field, not the thread's.
8947
b90fc188
PA
89482015-03-19 Pedro Alves <palves@redhat.com>
8949
8950 * linux-low.c (select_event_lwp_callback): Update comments to
8951 no longer mention SIGTRAP.
8952
464b0089
GB
89532015-03-18 Gary Benson <gbenson@redhat.com>
8954
8955 * server.c (handle_query): Do not report vFile:fstat as supported.
8956
aa9e327f
GB
89572015-03-11 Gary Benson <gbenson@redhat.com>
8958
8959 * hostio.c (sys/types.h): New include.
8960 (sys/stat.h): Likewise.
8961 (common-remote-fileio.h): Likewise.
8962 (handle_fstat): New function.
8963 (handle_vFile): Handle vFile:fstat packets.
aa9e327f 8964
791c0056
GB
89652015-03-11 Gary Benson <gbenson@redhat.com>
8966
8967 * configure.ac (AC_CHECK_MEMBERS): Add checks for
8968 struct stat.st_blocks and struct stat.st_blksize.
8969 * configure: Regenerate.
8970 * config.in: Likewise.
8971 * Makefile.in (SFILES): Add common/common-remote-fileio.c.
8972 (OBS): Add common-remote-fileio.o.
8973 (common-remote-fileio.o): New rule.
8974
9a9df970
PA
89752015-03-09 Pedro Alves <palves@redhat.com>
8976
8977 * tracepoint.c (gdb_agent_helper_thread): Cast '&sockaddr' to
8978 'struct sockaddr' pointer in 'accept' call.
8979
9eb1356e
PA
89802015-03-09 Pedro Alves <palves@redhat.com>
8981
8982 Revert:
8983 2015-03-07 Pedro Alves <palves@redhat.com>
8984 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
8985 or <winsock2.h> here. Instead include "gdb_socket.h".
8986 (remote_open): Use union gdb_sockaddr_u.
8987 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
8988 or <winsock2.h> here. Instead include "gdb_socket.h".
8989 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
8990 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
8991 or <sys/un.h>.
8992 (init_named_socket, gdb_agent_helper_thread): Use union
8993 gdb_sockaddr_u.
8994
aac331e4
PA
89952015-03-07 Pedro Alves <palves@redhat.com>
8996
8997 * configure.ac (build_warnings): Move
8998 -Wdeclaration-after-statement to the C-specific set.
8999 * configure: Regenerate.
9000
366c75fc
PA
90012015-03-07 Pedro Alves <palves@redhat.com>
9002
9003 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
9004 or <winsock2.h> here. Instead include "gdb_socket.h".
9005 (remote_open): Use union gdb_sockaddr_u.
9006 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
9007 or <winsock2.h> here. Instead include "gdb_socket.h".
9008 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
9009 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
9010 or <sys/un.h>.
9011 (init_named_socket, gdb_agent_helper_thread): Use union
9012 gdb_sockaddr_u.
9013
492d29ea
PA
90142015-03-07 Pedro Alves <palves@redhat.com>
9015
9016 Adjust all callers of TRY_CATCH to use TRY/CATCH/END_CATCH
9017 instead.
9018
60a191ed
YQ
90192015-03-06 Yao Qi <yao.qi@linaro.org>
9020
9021 * linux-aarch64-low.c (aarch64_insert_point): Use
9022 show_debug_regs as a boolean.
9023 (aarch64_remove_point): Likewise.
9024
f5771b1d
PA
90252015-03-05 Pedro Alves <palves@redhat.com>
9026
9027 * lynx-low.c (lynx_target_ops): Install NULL hooks for
9028 stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
9029 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint.
9030 * nto-low.c (nto_target_ops): Likewise.
9031 * spu-low.c (spu_target_ops): Likewise.
9032 * win32-low.c (win32_target_ops): Likewise.
9033
3e572f71
PA
90342015-03-04 Pedro Alves <palves@redhat.com>
9035
72f4393d 9036 * linux-low.c (check_stopped_by_breakpoint) [USE_SIGTRAP_SIGINFO]:
3e572f71
PA
9037 Decide whether a breakpoint triggered based on the SIGTRAP's
9038 siginfo.si_code.
72f4393d
L
9039 (thread_still_has_status_pending_p) [USE_SIGTRAP_SIGINFO]: Don't check whether a
9040 breakpoint is inserted if relying on SIGTRAP's siginfo.si_code.
3e572f71
PA
9041 (linux_low_filter_event): Check for breakpoints before checking
9042 watchpoints.
9043 (linux_wait_1): Don't re-increment the PC if relying on SIGTRAP's
9044 siginfo.si_code.
72f4393d
L
9045 (linux_stopped_by_sw_breakpoint)
9046 (linux_supports_stopped_by_sw_breakpoint)
9047 (linux_stopped_by_hw_breakpoint)
9048 (linux_supports_stopped_by_hw_breakpoint): New functions.
9049 (linux_target_ops): Install new target methods.
3e572f71 9050
1ec68e26
PA
90512015-03-04 Pedro Alves <palves@redhat.com>
9052
9053 * remote-utils.c (prepare_resume_reply): Report swbreak/hbreak.
9054 * server.c (swbreak_feature, hwbreak_feature): New globals.
9055 (handle_query) <qSupported>: Handle "swbreak+" and "hwbreak+".
9056 (captured_main): Clear swbreak_feature and hwbreak_feature.
9057 * server.h (swbreak_feature, hwbreak_feature): Declare.
9058 * target.h (struct target_ops) <stopped_by_sw_breakpoint,
9059 supports_stopped_by_sw_breakpoint, stopped_by_hw_breakpoint,
9060 supports_stopped_by_hw_breakpoint>: New fields.
9061 (target_supports_stopped_by_sw_breakpoint)
9062 (target_stopped_by_sw_breakpoint)
9063 (target_supports_stopped_by_hw_breakpoint)
9064 (target_stopped_by_hw_breakpoint): Declare.
9065
15c66dd6
PA
90662015-03-04 Pedro Alves <palves@redhat.com>
9067
9068 enum lwp_stop_reason -> enum target_stop_reason
9069 * linux-low.c (check_stopped_by_breakpoint): Adjust.
9070 (thread_still_has_status_pending_p, check_stopped_by_watchpoint)
9071 (linux_wait_1, stuck_in_jump_pad_callback)
9072 (move_out_of_jump_pad_callback, linux_resume_one_lwp)
9073 (linux_stopped_by_watchpoint):
9074 * linux-low.h (enum lwp_stop_reason): Delete.
9075 (struct lwp_info) <stop_reason>: Now an enum target_stop_reason.
9076 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
9077
98fc70d6
YQ
90782015-03-04 Yao Qi <yao.qi@linaro.org>
9079
9080 * Makefile.in (SFILES): Add linux-aarch64-low.c.
9081
dd2ac174
GB
90822015-03-03 Gary Benson <gbenson@redhat.com>
9083
9084 * hostio.c (handle_vFile): Fix prefix lengths.
9085
d68e53f4
MM
90862015-03-03 Markus Metzger <markus.t.metzger@intel.com>
9087
9088 * linux-low.c (linux_low_enable_btrace): Do not overwrite non-zero
9089 ptr_bits.
9090
bf2d68ab
AA
90912015-03-02 Andreas Arnez <arnez@linux.vnet.ibm.com>
9092
9093 * Makefile.in (s390-vx-linux64.c, s390-tevx-linux64.c)
9094 (s390x-vx-linux64.c, s390x-tevx-linux64.c): New rules.
9095 (clean): Add "rm -f" for above C files.
9096 * configure.srv (srv_regobj): Add s390-vx-linux64.o,
9097 s390-tevx-linux64.o, s390x-vx-linux64.o, and s390x-tevx-linux64.o.
9098 (srv_xmlfiles): Add s390-vx-linux64.xml, s390-tevx-linux64.xml,
9099 s390x-vx-linux64.xml, s390x-tevx-linux64.xml, and s390-vx.xml.
9100 * linux-s390-low.c (HWCAP_S390_VX): New macro.
9101 (init_registers_s390_vx_linux64, init_registers_s390_tevx_linux64)
9102 (init_registers_s390x_vx_linux64)
9103 (init_registers_s390x_tevx_linux64)
9104 (tdesc_s390_vx_linux64, tdesc_s390_tevx_linux64)
9105 (tdesc_s390x_vx_linux64, tdesc_s390x_tevx_linux64): New extern
9106 declarations.
9107 (s390_fill_vxrs_low, s390_store_vxrs_low, s390_fill_vxrs_high)
9108 (s390_store_vxrs_high): New functions.
9109 (s390_regsets): Add entries for NT_S390_VXRS_LOW and
9110 NT_S390_VXRS_HIGH.
9111 (s390_arch_setup): Add logic for selecting one of the new target
9112 descriptions. Activate the new vector regsets if applicable.
9113 (initialize_low_arch): Also invoke init_registers_s390_vx_linux64,
9114 init_registers_s390_tevx_linux64, init_registers_s390x_vx_linux64,
9115 and init_registers_s390x_tevx_linux64.
9116
c966a859
PA
91172015-03-01 Pedro Alves <palves@redhat.com>
9118
9119 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Constify 'raw_regs'
9120 parameter.
9121
4180215b
PA
91222015-02-27 Pedro Alves <palves@redhat.com>
9123
9124 * linux-x86-low.c (u_debugreg_offset): New function.
9125 (x86_linux_dr_get, x86_linux_dr_set): Use it.
9126
749bab01
PA
91272015-02-27 Pedro Alves <palves@redhat.com>
9128
9129 * gdb_proc_service.h: Wrap with EXTERN_C_PUSH/EXTERN_C_POP.
9130 [!HAVE_PROC_SERVICE_H] (struct ps_prochandle): Forward declare.
9131 [!HAVE_PROC_SERVICE_H] (ps_pdread, ps_pdwrite, ps_ptread)
9132 ps_ptwrite, ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
9133 (ps_lsetfpregs, ps_getpid)
9134 (ps_get_thread_area, ps_pglobal_lookup, ps_pstop, ps_pcontinue)
9135 (ps_lstop, ps_lcontinue, ps_lgetxregsize, ps_lgetxregs)
9136 (ps_lsetxregs, ps_plog): Declare.
9137
3c14e5a3
PA
91382015-02-27 Pedro Alves <palves@redhat.com>
9139
9140 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Use
9141 IP_AGENT_EXPORT_FUNC.
9142 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Use
9143 IP_AGENT_EXPORT_FUNC.
9144 * tracepoint.c (ATTR_USED, ATTR_NOINLINE, ATTR_CONSTRUCTOR)
9145 (IP_AGENT_EXPORT): Delete.
9146 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
9147 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
9148 (gdb_trampoline_buffer_error, collecting, gdb_collect)
9149 (stop_tracing, flush_trace_buffer, about_to_request_buffer_space)
9150 (trace_buffer_is_full, stopping_tracepoint, expr_eval_result)
9151 (error_tracepoint, tracepoints, tracing, trace_buffer_ctrl)
9152 (trace_buffer_ctrl_curr, trace_buffer_lo, trace_buffer_hi)
9153 (traceframe_read_count, traceframe_write_count)
9154 (traceframes_created, trace_state_variables, get_raw_reg)
9155 (get_trace_state_variable_value, set_trace_state_variable_value)
9156 (ust_loaded, helper_thread_id, cmd_buf): Use
9157 IPA_SYM_EXPORTED_NAME.
9158 (stop_tracing, flush_trace_buffer): Use IP_AGENT_EXPORT_FUNC.
9159 (tracepoints) Use IP_AGENT_EXPORT_VAR.
9160 (stopping_tracepoint, trace_buffer_is_full, expr_eval_result): Use
9161 IP_AGENT_EXPORT_VAR and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
9162 (last_tracepoint): Move into !IN_PROCESS_AGENT block.
9163 (error_tracepoint): Use IP_AGENT_EXPORT_VAR and wrap in
9164 EXTERN_C_PUSH/EXTERN_C_POP.
9165 (trace_state_variables): Use IP_AGENT_EXPORT_VAR.
9166 (trace_buffer_lo, trace_buffer_hi): Use IP_AGENT_EXPORT_VAR and
9167 wrap in EXTERN_C_PUSH/EXTERN_C_POP.
9168 (trace_buffer_ctrl, trace_buffer_ctrl_curr)
9169 (traceframe_write_count, traceframe_read_count)
9170 (traceframes_created, tracing): Use IP_AGENT_EXPORT_VAR.
9171 (about_to_request_buffer_space, get_trace_state_variable_value)
9172 (set_trace_state_variable_value): Use IP_AGENT_EXPORT_FUNC.
9173 (collecting): Use IP_AGENT_EXPORT_VAR and wrap in
9174 EXTERN_C_PUSH/EXTERN_C_POP.
9175 (gdb_collect): Use IP_AGENT_EXPORT_FUNC.
9176 (ust_loaded, cmd_buf): Use IP_AGENT_EXPORT_VAR.
9177 (helper_thread_id, gdb_agent_capability): Use IP_AGENT_EXPORT_VAR
9178 and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
9179 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
9180 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
9181 (gdb_trampoline_buffer_error): Use IP_AGENT_EXPORT_VAR.
9182 * tracepoint.h (ATTR_USED, ATTR_NOINLINE, EXPORTED_SYMBOL):
9183 Define.
9184 (IP_AGENT_EXPORT_FUNC, IP_AGENT_EXPORT_VAR)
9185 (IP_AGENT_EXPORT_VAR_DECL): Define.
9186 (tracing): Declare.
9187 (gdb_agent_get_raw_reg): Declare.
9188
fe978cb0
PA
91892015-02-27 Tom Tromey <tromey@redhat.com>
9190 Pedro Alves <palves@redhat.com>
9191
9192 Rename symbols whose names are reserved C++ keywords throughout.
9193
3bc3d82a
PA
91942015-02-27 Pedro Alves <palves@redhat.com>
9195
9196 * Makefile.in (COMPILER): New, get it from autoconf.
9197 (CXX): Get from autoconf instead.
9198 (COMPILE.pre): Use COMPILER.
9199 (CC-LD): Rename to ...
9200 (CC_LD): ... this. Use COMPILER.
9201 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT), $(IPA_LIB)): Adjust.
9202 (CXX_FOR_TARGET): Default to g++ instead of gcc.
9203 * acinclude.m4: Include build-with-cxx.m4.
9204 * configure.ac: Call AC_PROG_CXX and GDB_AC_BUILD_WITH_CXX.
9205 Disable -Werror by default if building in C++ mode.
9206 (build_warnings): Add -Wno-sign-compare, -Wno-write-strings and
9207 -Wno-narrowing in C++ mode. Run supported-warning-flags tests with
9208 the C++ compiler. Save/restore CXXFLAGS too.
9209 * configure: Regenerate.
9210
07697489
PA
92112015-02-27 Pedro Alves <palves@redhat.com>
9212
9213 * acinclude.m4: Include libiberty.m4.
9214 * configure.ac: Call libiberty_INIT.
9215 * config.in, configure: Regenerate.
9216
9beb7c4e
PA
92172015-02-26 Pedro Alves <palves@redhat.com>
9218
9219 * linux-low.c (linux_wait_1): When incrementing the PC past a
9220 program breakpoint always use the_low_target.breakpoint_len as
9221 increment, rather than the maximum between that and
9222 the_low_target.decr_pc_after_break.
9223
8090aef2
PA
92242015-02-23 Pedro Alves <palves@redhat.com>
9225
9226 * linux-low.c (check_stopped_by_breakpoint): Don't check if the
9227 thread was doing a step-over; always adjust the PC if
9228 we stepped over a permanent breakpoint.
9229 (linux_wait_1): If we stepped over breakpoint that was on top of a
9230 permanent breakpoint, manually advance the PC past it.
9231
bc9540e8
PA
92322015-02-23 Pedro Alves <palves@redhat.com>
9233
9234 * linux-x86-low.c (REGSIZE): Define in both 32-bit and 64-bit
9235 modes.
9236 (x86_fill_gregset, x86_store_gregset): Use it when handling
9237 $orig_eax.
9238
2db9a427
PA
92392015-02-20 Pedro Alves <palves@redhat.com>
9240
9241 * thread-db.c: Include "nat/linux-procfs.h".
9242 (thread_db_init): Skip listing new threads if the kernel supports
9243 PTRACE_EVENT_CLONE and /proc/PID/task/ is accessible.
9244
afa8d396
PA
92452015-02-20 Pedro Alves <palves@redhat.com>
9246
9247 * linux-low.c (status_pending_p_callback): Use ptid_match.
9248
c9587f88
AT
92492015-02-19 Antoine Tremblay <antoine.tremblay@ericsson.com>
9250
9251 PR breakpoints/16812
9252 * linux-low.c (wstatus_maybe_breakpoint): Remove.
9253 (linux_low_filter_event): Update wstatus_maybe_breakpoint name.
9254 (linux_wait_1): Report SIGTRAP,SIGILL,SIGSEGV.
9255
b05ec7a5
AT
92562015-02-10 Antoine Tremblay <antoine.tremblay@ericsson.com>
9257
9258 PR breakpoints/15956
9259 * tracepoint.c (cmd_qtinit): Add check for current_thread.
9260
d33501a5
MM
92612015-02-09 Markus Metzger <markus.t.metzger@intel.com>
9262
9263 * linux-low.c (linux_low_btrace_conf): Print size.
9264 * server.c (handle_btrace_conf_general_set): New.
9265 (hanle_general_set): Call handle_btrace_conf_general_set.
9266 (handle_query): Report Qbtrace-conf:bts:size as supported.
9267
f4abbc16
MM
92682015-02-09 Markus Metzger <markus.t.metzger@intel.com>
9269
9270 * linux-low.c (linux_low_enable_btrace): Update parameters.
9271 (linux_low_btrace_conf): New.
9272 (linux_target_ops)<to_btrace_conf>: Initialize.
9273 * server.c (current_btrace_conf): New.
9274 (handle_btrace_enable): Rename to ...
9275 (handle_btrace_enable_bts): ... this. Pass &current_btrace_conf
9276 to target_enable_btrace. Update comment. Update users.
9277 (handle_qxfer_btrace_conf): New.
9278 (qxfer_packets): Add btrace-conf entry.
9279 (handle_query): Report qXfer:btrace-conf:read as supported packet.
9280 * target.h (target_ops)<enable_btrace>: Update parameters and comment.
9281 (target_ops)<read_btrace_conf>: New.
9282 (target_enable_btrace): Update parameters.
9283 (target_read_btrace_conf): New.
9284
043c3577
MM
92852015-02-09 Markus Metzger <markus.t.metzger@intel.com>
9286
9287 * server.c (handle_btrace_general_set): Remove call to
9288 target_supports_btrace.
9289 (supported_btrace_packets): New.
9290 (handle_query): Call supported_btrace_packets.
9291 * target.h: include btrace-common.h.
9292 (btrace_target_info): Removed.
9293 (supports_btrace, target_supports_btrace): Update parameters.
9294
734b0e4b
MM
92952015-02-09 Markus Metzger <markus.t.metzger@intel.com>
9296
9297 * Makefile.in (SFILES): Add common/btrace-common.c.
9298 (OBS): Add common/btrace-common.o.
9299 (btrace-common.o): Add build rules.
9300 * linux-low: Include btrace-common.h.
9301 (linux_low_read_btrace): Use struct btrace_data. Call
9302 btrace_data_init and btrace_data_fini.
9303
d6c146e9
PA
93042015-02-06 Pedro Alves <palves@redhat.com>
9305
9306 * thread-db.c (find_new_threads_callback): Add debug output.
9307
20ba1ce6
PA
93082015-02-04 Pedro Alves <palves@redhat.com>
9309
9310 * linux-low.c (handle_extended_wait): Don't resume LWPs here.
9311 (resume_stopped_resumed_lwps): New function.
9312 (linux_wait_for_event_filtered): Use it.
9313
8cc73a39
SDJ
93142015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
9315
9316 * Makefile.in (SFILES): Add linux-personality.c.
9317 (linux-personality.o): New rule.
9318 * configure.srv (srv_linux_obj): Add linux-personality.o to the
9319 list of objects to be built.
9320 * linux-low.c: Include nat/linux-personality.h.
9321 (linux_create_inferior): Remove code to disable address space
9322 randomization (moved to ../nat/linux-personality.c). Create
9323 cleanup to disable address space randomization.
9324
fb23d554
SDJ
93252015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
9326
9327 * Makefile.in (posix-strerror.o): New rule.
9328 (mingw-strerror.o): Likewise.
9329 * configure: Regenerated.
9330 * configure.ac: Source file ../common/common.host. Initialize new
9331 variable srv_host_obs. Add srv_host_obs to GDBSERVER_DEPFILES.
9332
cdf43629
YQ
93332015-01-14 Yao Qi <yao@codesourcery.com>
9334
9335 * Makefile.in (SFILES): Add nat/ppc-linux.c.
9336 (ppc-linux.o): New rule.
9337 * configure.srv (powerpc*-*-linux*): Add ppc-linux.o.
9338 * configure.ac: AC_CHECK_FUNCS(getauxval).
9339 * config.in: Re-generated.
9340 * configure: Re-generated.
9341 * linux-ppc-low.c (ppc_arch_setup) [__powerpc64__]: Call
9342 ppc64_64bit_inferior_p
9343
514c5338
YQ
93442015-01-14 Yao Qi <yao@codesourcery.com>
9345
9346 * linux-ppc-low.c: Include "nat/ppc-linux.h".
9347 (PPC_FEATURE_HAS_VSX): Move to nat/ppc-linux.h.
9348 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Likewise.
9349 (PT_ORIG_R3, PT_TRAP): Likewise.
9350 (PTRACE_GETVSXREGS, PTRACE_SETVSXREGS): Likewise.
9351 (PTRACE_GETVRREGS, PTRACE_SETVRREGS): Likewise.
9352 (PTRACE_GETEVRREGS, PTRACE_SETEVRREGS): Likewise.
9353
3368c1e5
JB
93542015-01-10 Joel Brobecker <brobecker@adacore.com>
9355
9356 * i387-fp.c (i387_cache_to_xsave): In look over
9357 num_avx512_zmmh_high_registers, replace use of struct i387_xsave
9358 zmmh_low_space field by use of zmmh_high_space.
9359
582511be
PA
93602015-01-09 Pedro Alves <palves@redhat.com>
9361
9362 * linux-low.c (step_over_bkpt): Move higher up in the file.
9363 (handle_extended_wait): Don't store the stop_pc here.
9364 (get_stop_pc): Adjust comments and rename to ...
9365 (check_stopped_by_breakpoint): ... this. Record whether the LWP
9366 stopped for a software breakpoint or hardware breakpoint.
9367 (thread_still_has_status_pending_p): New function.
9368 (status_pending_p_callback): Use
9369 thread_still_has_status_pending_p. If the event is no longer
9370 interesting, resume the LWP.
9371 (handle_tracepoints): Add assert.
9372 (maybe_move_out_of_jump_pad): Remove cancel_breakpoints call.
9373 (wstatus_maybe_breakpoint): New function.
9374 (cancel_breakpoint): Delete function.
9375 (check_stopped_by_watchpoint): New function, factored out from
9376 linux_low_filter_event.
9377 (lp_status_maybe_breakpoint): Delete function.
9378 (linux_low_filter_event): Remove filter_ptid argument.
9379 Leave thread group exits pending here. Store the LWP's stop PC.
9380 Always leave events pending.
9381 (linux_wait_for_event_filtered): Pull all events out of the
9382 kernel, and leave them all pending.
9383 (count_events_callback, select_event_lwp_callback): Consider all
9384 events.
9385 (cancel_breakpoints_callback, linux_cancel_breakpoints): Delete.
9386 (select_event_lwp): Only give preference to the stepping LWP in
9387 all-stop mode. Adjust comments.
9388 (ignore_event): New function.
9389 (linux_wait_1): Delete 'retry' label. Use ignore_event. Remove
9390 references to cancel_breakpoints. Adjust to renames. Also give
9391 equal priority to all LWPs that have had events in non-stop mode.
9392 If reporting a software breakpoint event, unadjust the LWP's PC.
9393 (linux_wait): If linux_wait_1 returned an ignored event, retry.
9394 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback):
9395 Adjust.
9396 (linux_resume_one_lwp): Store the LWP's PC. Adjust.
9397 (resume_status_pending_p): Use thread_still_has_status_pending_p.
9398 (linux_stopped_by_watchpoint): Adjust.
9399 (linux_target_ops): Remove reference to linux_cancel_breakpoints.
9400 * linux-low.h (enum lwp_stop_reason): New.
9401 (struct lwp_info) <stop_pc>: Adjust comment.
9402 <stopped_by_watchpoint>: Delete field.
9403 <stop_reason>: New field.
9404 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
9405 * mem-break.c (software_breakpoint_inserted_here)
9406 (hardware_breakpoint_inserted_here): New function.
9407 * mem-break.h (software_breakpoint_inserted_here)
9408 (hardware_breakpoint_inserted_here): Declare.
9409 * target.h (struct target_ops) <cancel_breakpoints>: Remove field.
9410 (cancel_breakpoints): Delete.
9411 * tracepoint.c (clear_installed_tracepoints, stop_tracing)
9412 (upload_fast_traceframes): Remove references to
9413 cancel_breakpoints.
9414
a33e3959
PA
94152015-01-09 Pedro Alves <palves@redhat.com>
9416
9417 * thread-db.c (find_new_threads_callback): Ignore thread if the
9418 kernel thread ID is -1.
9419
8784d563
PA
94202015-01-09 Pedro Alves <palves@redhat.com>
9421
9422 * linux-low.c (linux_attach_fail_reason_string): Move to
9423 nat/linux-ptrace.c, and rename.
9424 (linux_attach_lwp): Update comment.
9425 (attach_proc_task_lwp_callback): New function.
9426 (linux_attach): Adjust to rename and use
9427 linux_proc_attach_tgid_threads.
9428 (linux_attach_fail_reason_string): Delete declaration.
9429
76f2b779
JB
94302015-01-01 Joel Brobecker <brobecker@adacore.com>
9431
9432 * gdbreplay.c (gdbreplay_version): Update copyright year to 2015.
9433 * server.c (gdbserver_version): Likewise.
9434
fafcc06a
SDJ
94352014-12-29 Sergio Durigan Junior <sergiodj@redhat.com>
9436
9437 * remote-utils.c: Include ctype.h.
9438 (input_interrupt): Explicitly handle the case when the char
9439 received is the NUL byte. Improve the printing of non-ASCII
9440 characters.
9441
beed38b8
JB
94422014-12-16 Joel Brobecker <brobecker@adacore.com>
9443
9444 * linux-low.c (linux_low_filter_event): Update call to
9445 linux_enable_event_reporting following the addition of
9446 a new parameter to that function.
9447
bf330350
CU
94482014-12-16 Catalin Udma <catalin.udma@freescale.com>
9449
9450 PR server/17457
9451 * linux-aarch64-low.c (AARCH64_FPSR_REGNO): New define.
9452 (AARCH64_FPCR_REGNO): Likewise.
9453 (AARCH64_NUM_REGS): Update to include fpsr/fpcr registers.
9454 (aarch64_fill_fpregset): Add missing fpsr/fpcr registers.
9455 (aarch64_store_fpregset): Likewise.
9456
5227d625
JB
94572014-12-15 Joel Brobecker <brobecker@adacore.com>
9458
9459 * lynx-low.c (lynx_resume): Use PTRACE_SINGLESTEP_ONE if N == 1.
9460 Remove FIXME comment about assumption about N.
9461
f93b65a0
JB
94622014-12-13 Joel Brobecker <brobecker@adacore.com>
9463
9464 * configure.ac: If large-file support is disabled in GDBserver,
9465 pass --disable-largefile to ACX_CONFIGURE_DIR call for "gnulib".
9466 * configure: Regenerate.
9467
e5a9158d
AA
94682014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
9469
9470 * linux-low.c (regsets_fetch_inferior_registers): Suppress the
9471 warning upon ENODATA from ptrace.
9472 * linux-s390-low.c (s390_store_tdb): New.
9473 (s390_regsets): Add regset for NT_S390_TDB.
9474
feea5f36
AA
94752014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
9476
9477 * linux-low.c (regsets_store_inferior_registers): Skip regsets
9478 without a fill_function.
9479 * linux-s390-low.c (s390_fill_last_break): Remove.
9480 (s390_regsets): Set fill_function to NULL for NT_S390_LAST_BREAK.
9481 (s390_arch_setup): Use regset's size instead of fill_function for
9482 loop end condition.
9483
098dbe61
AA
94842014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
9485
9486 * linux-low.c (regsets_fetch_inferior_registers): Do not invoke
9487 the regset's store function when ptrace returned an error.
9488 * regcache.c (get_thread_regcache): Invalidate register cache
9489 before fetching inferior's registers.
9490
28eef672
AA
94912014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
9492
9493 * linux-low.c (regsets_fetch_inferior_registers): Rephrase
9494 while-loop as for-loop.
9495 (regsets_store_inferior_registers): Likewise.
9496
bdca27a2
YQ
94972014-11-28 Yao Qi <yao@codesourcery.com>
9498
9499 * configure.ac(AC_CHECK_FUNCS): Remove readlink.
9500 * config.in, configure: Re-generate.
9501 * hostio.c (handle_unlink): Remove code checking HAVE_READLINK
9502 is defined.
9503
9c232dda
YQ
95042014-11-21 Yao Qi <yao@codesourcery.com>
9505
9506 * configure.ac: Don't invoke AC_FUNC_ALLOCA.
9507 (AC_CHECK_HEADERS): Remove malloc.h.
9508 * configure: Re-generated.
9509 * config.in: Re-generated.
9510 * server.h: Don't include alloca.h and malloc.h.
9511 * gdbreplay.c: Don't check HAVE_ALLOCA_H is defined.
9512 Don't include malloc.h.
9513
43968415
JB
95142014-11-17 Joel Brobecker <brobecker@adacore.com>
9515
9516 * lynx-low.c (lynx_write_memory): Put lynx_read_memory and
9517 corresponding ERRNO check in same block.
9518
40e91bc7
PA
95192014-11-12 Pedro Alves <palves@redhat.com>
9520
9521 * server.c (cont_thread): Update comment.
9522 (start_inferior, attach_inferior): No longer clear cont_thread.
9523 (handle_v_cont): No longer set cont_thread.
9524 (captured_main): Clear cont_thread each time a GDB connects.
9525
c2c118cf
PA
95262014-11-12 Pedro Alves <palves@redhat.com>
9527
9528 * linux-low.c (linux_wait_1): Don't force a wait for the Hc
9529 thread, and don't resume all threads if the Hc thread has exited.
9530
78708b7c
PA
95312014-11-12 Pedro Alves <palves@redhat.com>
9532
9533 * linux-low.c (linux_request_interrupt): Always send a SIGINT to
9534 the process group instead of to a specific LWP.
9535
a2abc7de
PA
95362014-10-15 Pedro Alves <palves@redhat.com>
9537
9538 PR server/17487
9539 * win32-arm-low.c (arm_set_thread_context): Remove current_event
9540 parameter.
9541 (arm_set_thread_context): Delete.
9542 (the_low_target): Adjust.
9543 * win32-i386-low.c (debug_registers_changed)
9544 (debug_registers_used): Delete.
9545 (update_debug_registers_callback): New function.
9546 (x86_dr_low_set_addr, x86_dr_low_set_control): Mark all threads as
9547 needing to update their debug registers.
9548 (win32_get_current_dr): New function.
9549 (x86_dr_low_get_addr, x86_dr_low_get_control)
9550 (x86_dr_low_get_status): Fetch the debug register from the thread
9551 record's context.
9552 (i386_initial_stuff): Adjust.
9553 (i386_get_thread_context): Remove current_event parameter. Don't
9554 clear debug_registers_changed nor copy DR values to
9555 debug_reg_state.
9556 (i386_set_thread_context): Delete.
9557 (i386_prepare_to_resume): New function.
9558 (i386_thread_added): Mark the thread as needing to update irs
9559 debug registers.
9560 (the_low_target): Remove i386_set_thread_context and install
9561 i386_prepare_to_resume.
9562 * win32-low.c (win32_get_thread_context): Adjust.
9563 (win32_set_thread_context): Use SetThreadContext
9564 directly.
9565 (win32_prepare_to_resume): New function.
9566 (win32_require_context): New function, factored out from ...
9567 (thread_rec): ... this.
9568 (continue_one_thread): Call win32_prepare_to_resume on each thread
9569 we're about to continue.
9570 (win32_resume): Call win32_prepare_to_resume on the event thread.
9571 * win32-low.h (struct win32_thread_info)
9572 <debug_registers_changed>: New field.
9573 (struct win32_target_ops): Change prototype of set_thread_context,
9574 delete set_thread_context and add prepare_to_resume.
9575 (win32_require_context): New declaration.
9576
a442d071
GB
95772014-10-08 Gary Benson <gbenson@redhat.com>
9578
9579 * server.h: Do not include common-exceptions.h.
9580
6f1947e8
GB
95812014-10-08 Gary Benson <gbenson@redhat.com>
9582
9583 * server.h: Do not include cleanups.h.
9584
63b434a4
JH
95852014-09-30 James Hogan <james.hogan@imgtec.com>
9586
9587 * Makefile.in (clean): Add rm -f commands for mips-dsp-linux.c and
9588 mips64-dsp-linux.c.
9589
c4d9ceb6
YQ
95902014-09-23 Yao Qi <yao@codesourcery.com>
9591
9592 * linux-low.c (lp_status_maybe_breakpoint): New function.
9593 (linux_low_filter_event): Call lp_status_maybe_breakpoint.
9594 (count_events_callback): Likewise.
9595 (select_event_lwp_callback): Likewise.
9596 (cancel_breakpoints_callback): Likewise.
9597
89a5711c
DB
95982014-09-19 Don Breazeal <donb@codesourcery.com>
9599
9600 * linux-low.c (handle_extended_wait): Call
9601 linux_ptrace_get_extended_event.
9602 (get_stop_pc, get_detach_signal, linux_low_filter_event): Call
9603 linux_is_extended_waitstatus.
9604
bffc0964
JB
96052014-09-16 Joel Brobecker <brobecker@adacore.com>
9606
9607 * Makefile.in (CPPFLAGS): Define.
9608 (INTERNAL_CFLAGS_BASE): Add ${CPPFLAGS}.
9609 (IPAGENT_CFLAGS): Remove ${CPPFLAGS}.
9610
0bfdf32f
GB
96112014-09-16 Gary Benson <gbenson@redhat.com>
9612
9613 * inferiors.h (current_inferior): Renamed as...
9614 (current_thread): New variable. All uses updated.
9615 * linux-low.c (get_pc): Renamed saved_inferior as saved_thread.
9616 (maybe_move_out_of_jump_pad): Likewise.
9617 (cancel_breakpoint): Likewise.
9618 (linux_low_filter_event): Likewise.
9619 (wait_for_sigstop): Likewise.
9620 (linux_resume_one_lwp): Likewise.
9621 (need_step_over_p): Likewise.
9622 (start_step_over): Likewise.
9623 (linux_stabilize_threads): Renamed save_inferior as saved_thread.
9624 * linux-x86-low.c (x86_linux_update_xmltarget): Likewise.
9625 * proc-service.c (ps_lgetregs): Renamed reg_inferior as reg_thread
9626 and save_inferior as saved_thread.
9627 * regcache.c (get_thread_regcache): Renamed saved_inferior as
9628 saved_thread.
9629 (regcache_invalidate_thread): Likewise.
9630 * remote-utils.c (prepare_resume_reply): Likewise.
9631 * thread-db.c (thread_db_get_tls_address): Likewise.
9632 (disable_thread_event_reporting): Likewise.
9633 (remove_thread_event_breakpoints): Likewise.
9634 * tracepoint.c (gdb_agent_about_to_close): Renamed save_inferior
9635 as saved_thread.
9636 * target.h (set_desired_inferior): Renamed as...
9637 (set_desired_thread): New declaration. All uses updated.
9638 * server.c (myresume): Updated comment to reference thread instead
9639 of inferior.
9640 (handle_serial_event): Likewise.
9641 (handle_target_event): Likewise.
9642
361c8ade
GB
96432014-09-12 Tom Tromey <tromey@redhat.com>
9644 Gary Benson <gbenson@redhat.com>
9645
9646 * regcache.h: Include common-regcache.h.
9647 (regcache_read_pc): Don't declare.
9648 * regcache.c (get_thread_regcache_for_ptid): New function.
9649
bd9269f7
GB
96502014-09-11 Tom Tromey <tromey@redhat.com>
9651 Gary Benson <gbenson@redhat.com>
9652
9653 * symbol.c: New file.
9654 * Makefile.in (SFILES): Add symbol.c.
9655 (OBS): Add symbol.o.
9656
f8c1d06b
GB
96572014-09-11 Gary Benson <gbenson@redhat.com>
9658
9659 * target.c (target_stop_ptid, target_continue_ptid): New
9660 functions.
9661
721ec300
GB
96622014-09-11 Tom Tromey <tromey@redhat.com>
9663 Gary Benson <gbenson@redhat.com>
9664
9665 * target.h: Include target/target.h.
9666 * target.c (target_read_memory, target_read_uint32)
9667 (target_write_memory): New functions.
9668
c5e92cca
GB
96692014-09-11 Gary Benson <gbenson@redhat.com>
9670
9671 * server.h (debug_hw_points): Don't declare.
9672 * server.c (debug_hw_points): Don't define. Replace all uses
9673 with show_debug_regs.
9674 * linux-aarch64-low.c (debug_hw_points): Don't define. Replace
9675 all uses with show_debug_regs.
9676
2e4bb98a
EBM
96772014-09-08 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
9678
9679 * linux-ppc-low.c (ppc_collect_ptrace_register): Adjust routine to take
9680 endianness into account.
9681 (ppc_supply_ptrace_register): Likewise.
9682
ac740bc7
JH
96832014-09-03 James Hogan <james.hogan@imgtec.com>
9684
9685 * linux-mips-low.c (mips_read_description): Reset errno to 0 prior
9686 to reading DSP_CONTROL with PTRACE_PEEKUSER ptrace call.
9687
97ea6506
GB
96882014-09-03 Gary Benson <gbenson@redhat.com>
9689
9690 * linux-x86-low.c (x86_linux_prepare_to_resume): Use
9691 ALL_DEBUG_ADDRESS_REGISTERS.
9692
df7e5265
GB
96932014-09-02 Gary Benson <gbenson@redhat.com>
9694
9695 * i386-low.h: Renamed as...
9696 * x86-low.h: New file. All type, function and variable name
9697 prefixes changed from "i386_" to "x86_". All references updated.
9698 * i386-low.c: Renamed as...
9699 * x86-low.c: New file. All type, function and variable name
9700 prefixes changed from "i386_" to "x86_". All references updated.
9701
ed859da7
GB
97022014-09-02 Gary Benson <gbenson@redhat.com>
9703
9704 * linux-x86-low.c (x86_linux_new_process): Use XCNEW.
9705 (x86_linux_new_thread): Likewise.
9706
860789c7
GB
97072014-08-29 Gary Benson <gbenson@redhat.com>
9708
9709 * server.h (setjmp.h): Do not include.
9710 (toplevel): Do not declare.
9711 (common-exceptions.h): Include.
9712 (cleanups.h): Likewise.
9713 * server.c (toplevel): Do not define.
9714 (exit_code): New static global.
9715 (detach_or_kill_for_exit_cleanup): New function.
9716 (main): New function. Original main renamed to...
9717 (captured_main): New function.
9718 * utils.c (verror) [!IN_PROCESS_AGENT]: Use throw_verror.
9719
ff55e1b5
GB
97202014-08-29 Gary Benson <gbenson@redhat.com>
9721
9722 * Makefile.in (SFILES): Add common/common-exceptions.c.
9723 (OBS): Add common-exceptions.o.
9724 (common-exceptions.o): New rule.
9725 * utils.c (prepare_to_throw_exception): New function.
9726
e9bcb658
GB
97272014-08-29 Gary Benson <gbenson@redhat.com>
9728
9729 * config.in: Regenerate.
9730 * configure: Likewise.
9731
e3180625
GB
97322014-08-29 Gary Benson <gbenson@redhat.com>
9733
9734 * Makefile.in (SFILES): Add common/cleanups.c.
9735 (OBS): cleanups.o.
9736 (cleanups.o): New rule.
9737
e3d6ba5d
GB
97382014-08-29 Gary Benson <gbenson@redhat.com>
9739
9740 * utils.c (internal_vwarning): New function.
9741
7096e886
GB
97422014-08-28 Gary Benson <gbenson@redhat.com>
9743
9744 * utils.h (fatal): Remove declaration.
9745 * utils.c (fatal): Remove function.
9746
14ce3192
GB
97472014-08-28 Gary Benson <gbenson@redhat.com>
9748
9749 * tracepoint.c (gdb_agent_init): Replace fatal with
9750 perror_with_name.
9751 (initialize_tracepoint): Likewise.
9752
50278d59
GB
97532014-08-28 Gary Benson <gbenson@redhat.com>
9754
9755 * remote-utils.c (remote_prepare): Replace fatal with error.
9756
aa96c426
GB
97572014-08-28 Gary Benson <gbenson@redhat.com>
9758
9759 * linux-low.c (linux_async): Replace fatal with warning.
9760 Tidy up and return.
9761 (linux_start_non_stop): Return -1 if linux_async failed.
9762
f7160e97
GB
97632014-08-28 Gary Benson <gbenson@redhat.com>
9764
9765 * linux-x86-low.c (i386_dr_low_set_addr): Replace check with
9766 gdb_assert.
9767 (i386_dr_low_get_addr): Remove vague comment.
9768 * win32-i386-low.c (i386_dr_low_set_addr): Replace check with
9769 gdb_assert.
9770
38e08fca
GB
97712014-08-28 Gary Benson <gbenson@redhat.com>
9772
9773 * inferiors.c (get_thread_process): Replace check with gdb_assert.
9774 * linux-low.c (linux_wait_for_event_filtered): Replace fatal with
9775 internal_error.
9776 (linux_resume_one_lwp): Likewise.
9777 * linux-x86-low.c (x86_siginfo_fixup): Replace checks with
9778 gdb_assert.
9779 * mem-break.c (raw_bkpt_type_to_target_hw_bp_type): Replace fatal
9780 with internal_error.
9781 * regcache.c (get_thread_regcache): Replace check with gdb_assert.
9782 (init_register_cache): Replace fatal with gdb_assert_not_reached.
9783 (find_register_by_name): Replace fatal with internal_error.
9784 (find_regno): Likewise.
9785 * tdesc.c (init_target_desc): Replace check with gdb_assert.
9786 * thread-db.c (thread_db_create_event): Likewise.
9787 (thread_db_load_search): Likewise.
9788 (try_thread_db_load_1): Likewise.
9789 * tracepoint.c (get_jump_space_head): Replace fatal with
9790 internal_error.
9791 (claim_trampoline_space): Likewise.
9792 (have_fast_tracepoint_trampoline_buffer): Likewise.
9793 (cmd_qtstart): Likewise.
9794 (stop_tracing): Likewise.
9795 (fast_tracepoint_collecting): Likewise.
9796 (target_malloc): Likewise.
9797 (download_tracepoint): Likewise.
9798 (download_trace_state_variables): Replace check with gdb_assert.
9799 (upload_fast_traceframes): Replace fatal with internal_error.
9800
34abf635
GB
98012014-08-19 Tom Tromey <tromey@redhat.com>
9802 Gary Benson <gbenson@redhat.com>
9803
9804 * Makefile.in (SFILES): Add common/common-debug.c.
9805 (OBS): Add common-debug.o.
9806 (common-debug.o): New rule.
9807 * debug.h (debug_printf): Don't declare.
9808 * debug.c (debug_printf): Renamed and rewritten as...
9809 (debug_vprintf): New function.
9810
f6e94d78
GB
98112014-08-19 Gary Benson <gbenson@redhat.com>
9812
9813 * utils.h: Do not include print-utils.h.
9814
9239eeab
GB
98152014-08-19 Tom Tromey <tromey@redhat.com>
9816 Gary Benson <gbenson@redhat.com>
9817
9818 * server.h: Add static assertion.
9819 (gdb_byte, CORE_ADDR, LONGEST, ULONGEST): Remove.
9820
ef87c8bb
GB
98212014-08-19 Tom Tromey <tromey@redhat.com>
9822 Gary Benson <gbenson@redhat.com>
9823
9824 * Makefile.in (SFILES): Add common/errors.c.
9825 (OBS): Add errors.o.
9826 (IPA_OBS): Add errors-ipa.o.
9827 (errors.o): New rule.
9828 (errors-ipa.o): Likewise.
9829 * utils.h (perror_with_name, error, warning): Don't declare.
9830 * utils.c (warning): Renamed and rewritten as...
9831 (vwarning): New function.
9832 (error): Renamed and rewritten as...
9833 (verror): New function.
9834 (internal_error): Renamed and rewritten as...
9835 (internal_verror): New function.
9836
bb974a24
GB
98372014-08-07 Gary Benson <gbenson@redhat.com>
9838
9839 * configure.ac (AC_CHECK_HEADERS): Remove errno.h.
9840 * configure: Regenerate.
9841 * config.in: Likewise.
9842 * server.h: Do not include errno.h.
9843 * event-loop.c: Likewise.
9844 * hostio-errno.c: Likewise.
9845 * linux-low.c: Likewise.
9846 * remote-utils.c: Likewise.
9847 * spu-low.c: Likewise.
9848 * utils.c: Likewise.
9849 * gdbreplay.c: Unconditionally include errno.h.
9850
6d3d12eb
GB
98512014-08-07 Gary Benson <gbenson@redhat.com>
9852
9853 * server.h: Do not include string.h.
9854 * event-loop.c: Likewise.
9855 * linux-low.c: Likewise.
9856 * regcache.c: Likewise.
9857 * remote-utils.c: Likewise.
9858 * spu-low.c: Likewise.
9859 * utils.c: Likewise.
9860
dccbb609
GB
98612014-08-07 Gary Benson <gbenson@redhat.com>
9862
9863 * server.h: Do not include gdb_assert.h.
9864
e76df0d0
GB
98652014-08-07 Gary Benson <gbenson@redhat.com>
9866
9867 * server.h: Do not include common-utils.h.
9868
4cb9c816
GB
98692014-08-07 Gary Benson <gbenson@redhat.com>
9870
9871 * server.h: Do not include ptid.h.
9872 * notif.h: Likewise.
9873
3995eeee
GB
98742014-08-07 Gary Benson <gbenson@redhat.com>
9875
9876 * server.h: Do not include gdb_locale.h.
9877
cb9f1a9b
GB
98782014-08-07 Gary Benson <gbenson@redhat.com>
9879
9880 * server.h: Do not include gdb/signals.h.
9881 * win32-low.c: Likewise.
9882
a5fceff8
GB
98832014-08-07 Gary Benson <gbenson@redhat.com>
9884
9885 * server.h: Do not include pathmax.h.
9886
b9391142
GB
98872014-08-07 Gary Benson <gbenson@redhat.com>
9888
9889 * server.h: Do not include libiberty.h.
9890 * linux-bfin-low.c: Likewise.
9891
0e443c87
GB
98922014-08-07 Gary Benson <gbenson@redhat.com>
9893
9894 * server.h: Do not include ansidecl.h.
9895
8ebb3f56
GB
98962014-08-07 Gary Benson <gbenson@redhat.com>
9897
9898 * linux-x86-low.c: Do not include stddef.h.
9899 * lynx-ppc-low.c: Likewise.
9900 * tracepoint.c: Likewise.
9901
8980bdf6
GB
99022014-08-07 Gary Benson <gbenson@redhat.com>
9903
9904 * server.h: Do not include stdarg.h.
9905 * nto-low.c: Likewise.
9906
d7096f71
GB
99072014-08-07 Gary Benson <gbenson@redhat.com>
9908
9909 * server.h: Do not include stdlib.h.
9910 * inferiors.c: Likewise.
9911 * linux-low.c: Likewise.
9912 * regcache.c: Likewise.
9913 * spu-low.c: Likewise.
9914 * tracepoint.c: Likewise.
9915 * utils.c: Likewise.
9916
d02f550d
GB
99172014-08-07 Gary Benson <gbenson@redhat.com>
9918
9919 * server.h: Do not include stdio.h.
9920 * linux-low.c: Likewise.
9921 * remote-utils.c: Likewise.
9922 * spu-low.c: Likewise.
9923 * utils.c: Likewise.
9924 * wincecompat.c: Likewise.
9925
87f6c4e3
GB
99262014-08-06 Gary Benson <gbenson@redhat.com>
9927
9928 * regcache.c (init_register_cache): Move conditionals inside if.
9929
7089dca4
GB
99302014-08-06 Gary Benson <gbenson@redhat.com>
9931
9932 * linux-low.c (linux_supports_non_stop): Use target_is_async_p.
9933
462f517e
GB
99342014-07-31 Gary Benson <gbenson@redhat.com>
9935
9936 * ax.h: Do not include server.h.
9937 * gdbthread.h: Likewise.
9938 * lynx-low.h: Likewise.
9939 * notif.h: Likewise.
9940
976411d6
GB
99412014-07-30 Gary Benson <gbenson@redhat.com>
9942
9943 * server.h: Include common-defs.h.
9944 Do not include config.h or build-gnulib-gdbserver/config.h.
9945
d41f6d8e
GB
99462014-07-30 Gary Benson <gbenson@redhat.com>
9947
9948 * hostio-errno.c: Move server.h to top of includes list.
9949 * inferiors.c: Likewise.
9950 * linux-x86-low.c: Likewise.
9951 * notif.c: Include server.h.
9952
314c6a35
TT
99532014-07-24 Tom Tromey <tromey@redhat.com>
9954 Gary Benson <gbenson@redhat.com>
9955
9956 * server.h (CORE_ADDR): Now unsigned.
9957
69ff6be5
PA
99582014-07-16 Pedro Alves <palves@redhat.com>
9959
9960 * linux-low.c (linux_kill_one_lwp): Use kill_lwp, not kill.
9961
ce9e3fe7
PA
99622014-07-15 Pedro Alves <palves@redhat.com>
9963
9964 * linux-low.c (linux_kill_one_lwp): Save errno and work with saved
9965 copy.
9966
e76126e8
PA
99672014-07-11 Pedro Alves <palves@redhat.com>
9968
9969 * linux-low.c (kill_wait_lwp): New function, based on
9970 kill_one_lwp_callback, but use my_waitpid directly.
9971 (kill_one_lwp_callback, linux_kill): Use it.
9972
8e9db26e
PA
99732014-06-23 Pedro Alves <palves@redhat.com>
9974
9975 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR_CONTROL
9976 before setting DR0..DR3.
9977
698b3e08
GB
99782014-06-20 Gary Benson <gbenson@redhat.com>
9979
9980 * configure.ac (AC_REPLACE_FUNCS) <vasprintf, vsnprintf>: Removed.
9981 * configure: Regenerated.
9982 * config.in: Likewise.
9983
125f8a3d
GB
99842014-06-20 Gary Benson <gbenson@redhat.com>
9985
9986 * Makefile.in (SFILES): Update locations for files moved
9987 from common to nat.
9988 (object file files): Reordered.
9989
42995dbd
GB
99902014-06-20 Gary Benson <gbenson@redhat.com>
9991
9992 * i386-low.h (i386_dr_low_can_set_addr): Removed.
9993 (i386_dr_low_set_addr): Likewise.
9994 (i386_dr_low_get_addr): Likewise.
9995 (i386_dr_low_can_set_control): Likewise.
9996 (i386_dr_low_set_control): Likewise.
9997 (i386_dr_low_get_control): Likewise.
9998 (i386_dr_low_get_status): Likewise.
9999 (i386_get_debug_register_length): Likewise.
10000 * linux-x86-low.c (i386_dr_low_set_addr):
10001 Changed signature. Made static.
10002 (i386_dr_low_get_addr): Likewise.
10003 (i386_dr_low_set_control): Likewise.
10004 (i386_dr_low_get_control): Likewise.
10005 (i386_dr_low_get_status): Likewise.
10006 (i386_dr_low): New global variable.
10007 * win32-i386-low.c (i386_dr_low_set_addr):
10008 Changed signature. Made static.
10009 (i386_dr_low_get_addr): Likewise.
10010 (i386_dr_low_set_control): Likewise.
10011 (i386_dr_low_get_control): Likewise.
10012 (i386_dr_low_get_status): Likewise.
10013 (i386_dr_low): New global variable.
10014
e1d2394b
MS
100152014-06-20 Marcus Shawcroft <marcus.shawcroft@arm.com>
10016
10017 * configure.ac: Invoke. AC_CHECK_TOOL(AR, ar).
10018 * Makefile.in (AR, AR_FLAGS): Define.
10019 * configure: Regenerate.
10020
3a8ee006
GB
100212014-06-19 Gary Benson <gbenson@redhat.com>
10022
10023 * Makefile.in (i386-dregs.o): New rule.
10024 * configure.srv: Add i386-dregs.o to all targets using i386-low.o.
10025 * i386-low.c (target.h): Remove include.
10026 (TARGET_HAS_DR_LEN_8): Now in i386-dregs.c.
10027 (DR_CONTROL_SHIFT): Likewise.
10028 (DR_CONTROL_SIZE): Likewise.
10029 (DR_RW_EXECUTE): Likewise.
10030 (DR_RW_WRITE): Likewise.
10031 (DR_RW_READ): Likewise.
10032 (DR_RW_IORW): Likewise.
10033 (DR_LEN_1): Likewise.
10034 (DR_LEN_2): Likewise.
10035 (DR_LEN_4): Likewise.
10036 (DR_LEN_8): Likewise.
10037 (DR_LOCAL_ENABLE_SHIFT): Likewise.
10038 (DR_GLOBAL_ENABLE_SHIFT): Likewise.
10039 (DR_ENABLE_SIZE): Likewise.
10040 (DR_LOCAL_SLOWDOWN): Likewise.
10041 (DR_GLOBAL_SLOWDOWN): Likewise.
10042 (DR_CONTROL_RESERVED): Likewise.
10043 (I386_DR_CONTROL_MASK): Likewise.
10044 (I386_DR_VACANT): Likewise.
10045 (I386_DR_LOCAL_ENABLE): Likewise.
10046 (I386_DR_GLOBAL_ENABLE): Likewise.
10047 (I386_DR_DISABLE): Likewise.
10048 (I386_DR_SET_RW_LEN): Likewise.
10049 (I386_DR_GET_RW_LEN): Likewise.
10050 (I386_DR_WATCH_HIT): Likewise.
10051 (i386_wp_op_t): Likewise.
10052 (i386_show_dr): Likewise.
10053 (i386_length_and_rw_bits): Likewise.
10054 (i386_insert_aligned_watchpoint): Likewise.
10055 (i386_remove_aligned_watchpoint): Likewise.
10056 (i386_handle_nonaligned_watchpoint): Likewise.
10057 i386_update_inferior_debug_regs(): Likewise.
10058 (i386_dr_insert_watchpoint): Likewise.
10059 (i386_dr_remove_watchpoint): Likewise.
10060 (i386_dr_region_ok_for_watchpoint): Likewise.
10061 (i386_dr_stopped_data_address): Likewise.
10062 (i386_dr_stopped_by_watchpoint): Likewise.
10063
8f26655c
GB
100642014-06-19 Gary Benson <gbenson@redhat.com>
10065
10066 * i386-low.c (i386_dr_show): Renamed to
10067 i386_show_dr and made static. All uses updated.
10068 (i386_dr_length_and_rw_bits): Renamed to
10069 i386_length_and_rw_bits and made static.
10070 All uses updated.
10071 (i386_dr_insert_aligned_watchpoint): Renamed to
10072 i386_insert_aligned_watchpoint and made static.
10073 All uses updated.
10074 (i386_dr_remove_aligned_watchpoint): Renamed to
10075 i386_remove_aligned_watchpoint and made static.
10076 All uses updated.
10077 (i386_dr_update_inferior_debug_regs): Renamed to
10078 i386_update_inferior_debug_regs and made static.
10079 All uses updated.
10080
b9228891
GB
100812014-06-18 Gary Benson <gbenson@redhat.com>
10082
5171def3
GB
10083 * i386-low.h (i386_dr_low_can_set_addr): New macro.
10084 (i386_dr_low_can_set_control): Likewise.
10085 (i386_get_debug_register_length): Likewise.
10086 * i386-low.c (i386_dr_low_can_set_addr): Now in i386-low.h.
10087 (i386_dr_low_can_set_control): Likewise.
10088 (i386_get_debug_register_length): Likewise.
10089
100902014-06-17 Gary Benson <gbenson@redhat.com>
10091
b9228891
GB
10092 * i386-low.h (i386-dregs.h): New include.
10093 (DR_FIRSTADDR): Now in i386-dregs.h.
10094 (DR_LASTADDR): Likewise.
10095 (DR_NADDR): Likewise.
10096 (DR_STATUS): Likewise.
10097 (DR_CONTROL): Likewise.
10098 (i386_debug_reg_state): Likewise.
10099 (i386_dr_insert_watchpoint): Likewise.
10100 (i386_dr_remove_watchpoint): Likewise.
10101 (i386_dr_region_ok_for_watchpoint): Likewise.
10102 (i386_dr_stopped_data_address): Likewise.
10103 (i386_dr_stopped_by_watchpoint): Likewise.
10104 * i386-low.c (ALL_DEBUG_REGISTERS): Likewise.
10105
4be83cc2
GB
101062014-06-18 Gary Benson <gbenson@redhat.com>
10107
10108 * i386-low.h (i386_low_insert_watchpoint): Renamed to
10109 i386_dr_insert_watchpoint.
10110 (i386_low_remove_watchpoint): Renamed to
10111 i386_dr_remove_watchpoint.
10112 (i386_low_region_ok_for_watchpoint): Renamed to
10113 i386_dr_region_ok_for_watchpoint.
10114 (i386_low_stopped_data_address): Renamed to
10115 i386_dr_stopped_data_address.
10116 (i386_low_stopped_by_watchpoint): Renamed to
10117 i386_dr_stopped_by_watchpoint.
10118 * i386-low.c (i386_show_dr): Renamed to
10119 i386_dr_show and made nonstatic. All uses updated.
10120 (i386_length_and_rw_bits): Renamed to
10121 i386_dr_length_and_rw_bits and made nonstatic.
10122 All uses updated.
10123 (i386_insert_aligned_watchpoint): Renamed to
10124 i386_dr_insert_aligned_watchpoint and made nonstatic.
10125 All uses updated.
10126 (i386_remove_aligned_watchpoint): Renamed to
10127 i386_dr_remove_aligned_watchpoint and made nonstatic.
10128 All uses updated.
10129 (i386_update_inferior_debug_regs): Renamed to
10130 i386_dr_update_inferior_debug_regs and made nonstatic.
10131 All uses updated.
10132 (i386_low_insert_watchpoint): Renamed to
10133 i386_dr_insert_watchpoint. All uses updated.
10134 (i386_low_remove_watchpoint): Renamed to
10135 i386_dr_remove_watchpoint. All uses updated.
10136 (i386_low_region_ok_for_watchpoint): Renamed to
10137 i386_dr_region_ok_for_watchpoint. All uses updated.
10138 (i386_low_stopped_data_address): Renamed to
10139 i386_dr_stopped_data_address. All uses updated.
10140 (i386_low_stopped_by_watchpoint): Renamed to
10141 i386_dr_stopped_by_watchpoint. All uses updated.
10142
131aa0d4
GB
101432014-06-18 Gary Benson <gbenson@redhat.com>
10144
10145 * i386-low.c (i386_dr_low_can_set_addr): New macro.
10146 (i386_dr_low_can_set_control): Likewise.
10147 (i386_insert_aligned_watchpoint): New check.
10148
d9305f7f
GB
101492014-06-18 Gary Benson <gbenson@redhat.com>
10150
10151 * i386-low.c (i386_update_inferior_debug_regs) <inf_state>:
10152 Renamed to state.
10153
e927c9fc
GB
101542014-06-18 Gary Benson <gbenson@redhat.com>
10155
10156 * i386-low.c (i386_length_and_rw_bits): Use internal_error
10157 instead of fatal and error.
10158 (i386_handle_nonaligned_watchpoint): Likewise.
10159
1b6d4134
GB
101602014-06-18 Gary Benson <gbenson@redhat.com>
10161
10162 * i386-low.c (i386_get_debug_register_length): New macro.
10163 (TARGET_HAS_DR_LEN_8): Remove conditional. Use above macro.
10164 (i386_show_dr): Use debug_printf instead of fprintf. Use
10165 phex to format values.
10166
6e62758f
GB
101672014-06-18 Gary Benson <gbenson@redhat.com>
10168
10169 * i386-low.h: Comment changes.
10170 * i386-low.c: Likewise.
10171
fc6e2f03
GB
101722014-06-18 Gary Benson <gbenson@redhat.com>
10173
10174 * i386-low.c: Whitespace changes.
10175
f9d1eeed
TT
101762014-06-12 Tom Tromey <tromey@redhat.com>
10177
10178 * utils.c (freeargv): Remove.
10179
0b04e523
TT
101802014-06-12 Tom Tromey <tromey@redhat.com>
10181
10182 * debug.c (debug_printf): Remove HAVE_GETTIMEOFDAY checks.
10183 * server.c (monitor_show_help): Remove HAVE_GETTIMEOFDAY check.
10184 (parse_debug_format_options): Likewise.
10185 (gdbserver_usage): Likewise.
10186 * Makefile.in (LIBIBERTY_BUILDDIR, LIBIBERTY): New variables.
10187 (SUBDIRS, REQUIRED_SUBDIRS): Add libiberty.
10188 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Depend on and link
10189 against libiberty.
10190 ($(LIBGNU)): Depend on libiberty.
10191 (all-lib): Recurse into all subdirs.
10192 (install-only): Invoke "install" target in subdirs.
10193 (vasprintf.o, vsnprintf.o, safe-ctype.o, lbasename.o): Remove
10194 targets.
10195 * configure: Rebuild.
10196 * configure.ac: Add ACX_CONFIGURE_DIR for libiberty. Don't check
10197 for vasprintf, vsnprintf, or gettimeofday.
10198 * configure.srv: Don't add safe-ctype.o or lbasename.o to
10199 srv_tgtobj.
10200
270c9937
JB
102012014-06-05 Joel Brobecker <brobecker@adacore.com>
10202
10203 * development.sh: Delete.
10204 * Makefile.in (config.status): Adjust dependency on development.sh.
10205 * configure.ac: Adjust development.sh source call.
10206 * configure: Regenerate.
10207
0a261ed8
PA
102082014-06-02 Pedro Alves <palves@redhat.com>
10209
10210 * ax.c (gdb_free_agent_expr): New function.
10211 * ax.h (gdb_free_agent_expr): New declaration.
10212 * mem-break.c (delete_gdb_breakpoint_1): Also clear the commands
10213 list.
10214 (clear_breakpoint_conditions, clear_breakpoint_commands): Make
10215 static.
10216 (clear_breakpoint_conditions_and_commands): New function.
10217 * mem-break.h (clear_breakpoint_conditions): Delete declaration.
10218 (clear_breakpoint_conditions_and_commands): New declaration.
10219
e9dae05e
RR
102202014-05-23 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
10221
10222 * linux-aarch64-low.c (asm/ptrace.h): Include.
10223
5876f503
JK
102242014-05-21 Jan Kratochvil <jan.kratochvil@redhat.com>
10225
10226 Fix TLS access for -static -pthread.
10227 * gdbserver/thread-db.c (struct thread_db): Add td_thr_tlsbase_p.
10228 (thread_db_get_tls_address): Call it if LOAD_MODULE is zero.
10229 (thread_db_load_search, try_thread_db_load_1): Initialize it.
10230
802e8e6d
PA
102312014-05-20 Pedro Alves <palves@redhat.com>
10232
10233 * linux-aarch64-low.c (aarch64_insert_point)
10234 (aarch64_remove_point): No longer check whether the type is
10235 supported here. Adjust to new interface.
10236 (the_low_target): Install aarch64_supports_z_point_type as
10237 supports_z_point_type method.
10238 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type): New function.
10239 (arm_linux_hw_point_initialize): Take an enum raw_bkpt_type
10240 instead of a Z packet char. Adjust.
10241 (arm_supports_z_point_type): New function.
10242 (arm_insert_point, arm_remove_point): Adjust to new interface.
10243 (the_low_target): Install arm_supports_z_point_type.
10244 * linux-crisv32-low.c (cris_supports_z_point_type): New function.
10245 (cris_insert_point, cris_remove_point): Adjust to new interface.
10246 Don't check whether the type is supported here.
10247 (the_low_target): Install cris_supports_z_point_type.
10248 * linux-low.c (linux_supports_z_point_type): New function.
10249 (linux_insert_point, linux_remove_point): Adjust to new interface.
10250 * linux-low.h (struct linux_target_ops) <insert_point,
10251 remove_point>: Take an enum raw_bkpt_type instead of a char. Add
10252 raw_breakpoint pointer parameter.
10253 <supports_z_point_type>: New method.
10254 * linux-mips-low.c (mips_supports_z_point_type): New function.
10255 (mips_insert_point, mips_remove_point): Adjust to new interface.
10256 Use mips_supports_z_point_type.
10257 (the_low_target): Install mips_supports_z_point_type.
10258 * linux-ppc-low.c (the_low_target): Install NULL as
10259 supports_z_point_type method.
10260 * linux-s390-low.c (the_low_target): Install NULL as
10261 supports_z_point_type method.
10262 * linux-sparc-low.c (the_low_target): Install NULL as
10263 supports_z_point_type method.
10264 * linux-x86-low.c (x86_supports_z_point_type): New function.
10265 (x86_insert_point): Adjust to new insert_point interface. Use
10266 insert_memory_breakpoint. Adjust to new
10267 i386_low_insert_watchpoint interface.
10268 (x86_remove_point): Adjust to remove_point interface. Use
10269 remove_memory_breakpoint. Adjust to new
10270 i386_low_remove_watchpoint interface.
10271 (the_low_target): Install x86_supports_z_point_type.
10272 * lynx-low.c (lynx_target_ops): Install NULL as
10273 supports_z_point_type callback.
10274 * nto-low.c (nto_supports_z_point_type): New.
10275 (nto_insert_point, nto_remove_point): Adjust to new interface.
10276 (nto_target_ops): Install nto_supports_z_point_type.
10277 * mem-break.c: Adjust intro comment.
10278 (struct raw_breakpoint) <raw_type, size>: New fields.
10279 <inserted>: Update comment.
10280 <shlib_disabled>: Delete field.
10281 (enum bkpt_type) <gdb_breakpoint>: Delete value.
10282 <gdb_breakpoint_Z0, gdb_breakpoint_Z1, gdb_breakpoint_Z2,
10283 gdb_breakpoint_Z3, gdb_breakpoint_Z4>: New values.
10284 (raw_bkpt_type_to_target_hw_bp_type): New function.
10285 (find_enabled_raw_code_breakpoint_at): New function.
10286 (find_raw_breakpoint_at): New type and size parameters. Use them.
10287 (insert_memory_breakpoint): New function, based off
10288 set_raw_breakpoint_at.
10289 (remove_memory_breakpoint): New function.
10290 (set_raw_breakpoint_at): Reimplement.
10291 (set_breakpoint): New, based on set_breakpoint_at.
10292 (set_breakpoint_at): Reimplement.
10293 (delete_raw_breakpoint): Go through the_target->remove_point
10294 instead of assuming memory breakpoints.
10295 (find_gdb_breakpoint_at): Delete.
10296 (Z_packet_to_bkpt_type, Z_packet_to_raw_bkpt_type): New functions.
10297 (find_gdb_breakpoint): New function.
10298 (set_gdb_breakpoint_at): Delete.
10299 (z_type_supported): New function.
10300 (set_gdb_breakpoint_1): New function, loosely based off
10301 set_gdb_breakpoint_at.
10302 (check_gdb_bp_preconditions, set_gdb_breakpoint): New functions.
10303 (delete_gdb_breakpoint_at): Delete.
10304 (delete_gdb_breakpoint_1): New function, loosely based off
10305 delete_gdb_breakpoint_at.
10306 (delete_gdb_breakpoint): New function.
10307 (clear_gdb_breakpoint_conditions): Rename to ...
10308 (clear_breakpoint_conditions): ... this. Don't handle a NULL
10309 breakpoint.
10310 (add_condition_to_breakpoint): Make static.
10311 (add_breakpoint_condition): Take a struct breakpoint pointer
10312 instead of an address. Adjust.
10313 (gdb_condition_true_at_breakpoint): Rename to ...
10314 (gdb_condition_true_at_breakpoint_z_type): ... this, and add
10315 z_type parameter.
10316 (gdb_condition_true_at_breakpoint): Reimplement.
10317 (add_breakpoint_commands): Take a struct breakpoint pointer
10318 instead of an address. Adjust.
10319 (gdb_no_commands_at_breakpoint): Rename to ...
10320 (gdb_no_commands_at_breakpoint_z_type): ... this. Add z_type
10321 parameter. Return true if no breakpoint was found. Change debug
10322 output.
10323 (gdb_no_commands_at_breakpoint): Reimplement.
10324 (run_breakpoint_commands): Rename to ...
10325 (run_breakpoint_commands_z_type): ... this. Add z_type parameter,
10326 and change return type to boolean.
10327 (run_breakpoint_commands): New function.
10328 (gdb_breakpoint_here): Also check for Z1 breakpoints.
10329 (uninsert_raw_breakpoint): Don't try to reinsert a disabled
10330 breakpoint. Go through the_target->remove_point instead of
10331 assuming memory breakpoint.
10332 (uninsert_breakpoints_at, uninsert_all_breakpoints): Uninsert
10333 software and hardware breakpoints.
10334 (reinsert_raw_breakpoint): Go through the_target->insert_point
10335 instead of assuming memory breakpoint.
10336 (reinsert_breakpoints_at, reinsert_all_breakpoints): Reinsert
10337 software and hardware breakpoints.
10338 (check_breakpoints, breakpoint_here, breakpoint_inserted_here):
10339 Check both software and hardware breakpoints.
10340 (validate_inserted_breakpoint): Assert the breakpoint is a
10341 software breakpoint. Set the inserted flag to -1 instead of
10342 setting shlib_disabled.
10343 (delete_disabled_breakpoints): Adjust.
10344 (validate_breakpoints): Only validate software breakpoints.
10345 Adjust to inserted flag change.
10346 (check_mem_read, check_mem_write): Skip breakpoint types other
10347 than software breakpoints. Adjust to inserted flag change.
10348 * mem-break.h (enum raw_bkpt_type): New enum.
10349 (raw_breakpoint, struct process_info): Forward declare.
10350 (Z_packet_to_target_hw_bp_type): Delete declaration.
10351 (raw_bkpt_type_to_target_hw_bp_type, Z_packet_to_raw_bkpt_type)
10352 (set_gdb_breakpoint, delete_gdb_breakpoint)
10353 (clear_breakpoint_conditions): New declarations.
10354 (set_gdb_breakpoint_at, clear_gdb_breakpoint_conditions): Delete.
10355 (breakpoint_inserted_here): Update comment.
10356 (add_breakpoint_condition, add_breakpoint_commands): Replace
10357 address parameter with a breakpoint pointer parameter.
10358 (gdb_breakpoint_here): Update comment.
10359 (delete_gdb_breakpoint_at): Delete.
10360 (insert_memory_breakpoint, remove_memory_breakpoint): Declare.
10361 * server.c (process_point_options): Take a struct breakpoint
10362 pointer instead of an address. Adjust.
10363 (process_serial_event) <Z/z packets>: Use set_gdb_breakpoint and
10364 delete_gdb_breakpoint.
10365 * spu-low.c (spu_target_ops): Install NULL as
10366 supports_z_point_type method.
10367 * target.h: Include mem-break.h.
10368 (struct target_ops) <prepare_to_access_memory>: Update comment.
10369 <supports_z_point_type>: New field.
10370 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
10371 instead of a char. Also take a raw breakpoint pointer.
10372 * win32-arm-low.c (the_low_target): Install NULL as
10373 supports_z_point_type.
10374 * win32-i386-low.c (i386_supports_z_point_type): New function.
10375 (i386_insert_point, i386_remove_point): Adjust to new interface.
10376 (the_low_target): Install i386_supports_z_point_type.
10377 * win32-low.c (win32_supports_z_point_type): New function.
10378 (win32_insert_point, win32_remove_point): Adjust to new interface.
10379 (win32_target_ops): Install win32_supports_z_point_type.
10380 * win32-low.h (struct win32_target_ops):
10381 <supports_z_point_type>: New method.
10382 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
10383 instead of a char. Also take a raw breakpoint pointer.
10384
932539e3
PA
103852014-05-20 Pedro Alves <palves@redhat.com>
10386
10387 * mem-break.h: Include break-common.h.
10388 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
10389 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): New defines.
10390 (Z_packet_to_target_hw_bp_type): New declaration.
10391 * mem-break.c (Z_packet_to_target_hw_bp_type): New function.
10392 * i386-low.c (Z_PACKET_HW_BP, Z_PACKET_WRITE_WP, Z_PACKET_READ_WP)
10393 (Z_PACKET_ACCESS_WP): Delete macros.
10394 (Z_packet_to_hw_type): Delete function.
10395 * i386-low.h: Don't include break-common.h here.
10396 (Z_packet_to_hw_type): Delete declaration.
10397 * linux-x86-low.c (x86_insert_point, x86_insert_point): Call
10398 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
10399 * win32-i386-low.c (i386_insert_point, i386_remove_point): Call
10400 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
10401 * linux-aarch64-low.c: Don't include break-common.h here.
10402 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
10403 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): Delete macros.
10404 (Z_packet_to_target_hw_bp_type): Delete function.
10405 * linux-mips-low.c (rsp_bp_type_to_target_hw_bp_type): Delete
10406 function.
10407 (mips_insert_point, mips_remove_point): Use
10408 Z_packet_to_target_hw_bp_type.
10409
4ff0d3d8
PA
104102014-05-20 Pedro Alves <palves@redhat.com>
10411
10412 * linux-aarch64-low.c: Include break-common.h.
10413 (enum target_point_type): Delete.
10414 (Z_packet_to_point_type): Rename to ...
10415 (Z_packet_to_target_hw_bp_type): ... this, and return a
10416 target_hw_bp_type instead.
10417 (aarch64_show_debug_reg_state): Take an enum target_hw_bp_type
10418 instead of an enum target_point_type.
10419 (aarch64_point_encode_ctrl_reg): Likewise. Compute type mask from
10420 breakpoint type.
10421 (aarch64_dr_state_insert_one_point)
10422 (aarch64_dr_state_remove_one_point, aarch64_handle_breakpoint)
10423 (aarch64_handle_aligned_watchpoint)
10424 (aarch64_handle_unaligned_watchpoint, aarch64_handle_watchpoint):
10425 Take an enum target_hw_bp_type instead of an enum
10426 target_point_type.
10427 (aarch64_supports_z_point_type): New function.
10428 (aarch64_insert_point, aarch64_remove_point): Use it. Adjust to
10429 use Z_packet_to_target_hw_bp_type.
10430
786dc519
JB
104312014-05-20 Joel Brobecker <brobecker@adacore.com>
10432
10433 * configure.ac: Only use -Werror by default when DEVELOPMENT
10434 is true.
10435 * configure: Regenerate.
10436
9e0aa64f
JK
104372014-05-19 Jan Kratochvil <jan.kratochvil@redhat.com>
10438
10439 Fix gdbserver qGetTLSAddr for x86_64 -m32.
10440 * linux-x86-low.c (X86_64_USER_REGS): New.
10441 (x86_fill_gregset): Call memset for BUF first in x86_64 -m32 case.
10442
2b577b92
YQ
104432014-04-28 Yao Qi <yao@codesourcery.com>
10444
10445 * Makefile.in (i386-avx512.c): Fix the typo of generated file
10446 name.
10447
94611da2
PA
104482014-04-25 Pedro Alves <palves@redhat.com>
10449
10450 PR server/16255
10451 * linux-low.c (linux_attach_fail_reason_string): New function.
10452 (linux_attach_lwp): Delete.
10453 (linux_attach_lwp_1): Rename to ...
10454 (linux_attach_lwp): ... this. Take a ptid instead of a pid as
10455 argument. Remove "initial" parameter. Return int instead of
10456 void. Don't error or warn here.
10457 (linux_attach): Adjust to call linux_attach_lwp. Call error on
10458 failure to attach to the tgid. Call warning when failing to
10459 attach to an lwp.
10460 * linux-low.h (linux_attach_lwp): Take a ptid instead of a pid as
10461 argument. Remove "initial" parameter. Return int instead of
10462 void. Don't error or warn here.
10463 (linux_attach_fail_reason_string): New declaration.
10464 * thread-db.c (attach_thread): Adjust to linux_attach_lwp's
10465 interface change. Use linux_attach_fail_reason_string.
10466
01f9f808
MS
104672014-04-24 Michael Sturm <michael.sturm@mintel.com>
10468 Walfred Tedeschi <walfred.tedeschi@intel.com>
10469
10470 * Makefile.in: Added rules to handle new files
10471 i386-avx512.c i386-avx512-linux.c amd64-avx512.c
10472 amd64-avx512-linux.c x32-avx512.c x32-avx512-linux.c.
10473 * configure.srv (srv_i386_regobj): Add i386-avx512.o.
10474 (srv_i386_linux_regobj): Add i386-avx512-linux.o.
10475 (srv_amd64_regobj): Add amd64-avx512.o and x32-avx512.o.
10476 (srv_amd64_linux_regobj): Add amd64-avx512-linux.o and
10477 x32-avx512-linux.o.
10478 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx512.xml.
10479 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx512.xml.
10480 (srv_amd64_xmlfiles): Add i386/amd64-avx512.xml and
10481 i386/x32-avx512.xml.
10482 (srv_i386_linux_xmlfiles): Add i386/i386-avx512-linux.xml.
10483 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx512-linux.xml and
10484 i386/x32-avx512-linux.xml.
10485 * i387-fp.c (num_avx512_k_registers): New constant for number
10486 of K registers.
10487 (num_avx512_zmmh_low_registers): New constant for number of
10488 lower ZMM registers (0-15).
10489 (num_avx512_zmmh_high_registers): New constant for number of
10490 higher ZMM registers (16-31).
10491 (num_avx512_ymmh_registers): New contant for number of higher
10492 YMM registers (ymm16-31 added by avx521 on x86_64).
10493 (num_avx512_xmm_registers): New constant for number of higher
10494 XMM registers (xmm16-31 added by AVX512 on x86_64).
10495 (struct i387_xsave): Add space for AVX512 registers.
10496 (i387_cache_to_xsave): Change raw buffer size to 64 characters.
10497 Add code to handle AVX512 registers.
10498 (i387_xsave_to_cache): Add code to handle AVX512 registers.
10499 * linux-x86-low.c (init_registers_amd64_avx512_linux): New
10500 prototypei from generated file.
10501 (tdesc_amd64_avx512_linux): Likewise.
10502 (init_registers_x32_avx512_linux): Likewise.
10503 (tdesc_x32_avx512_linux): Likewise.
10504 (init_registers_i386_avx512_linux): Likewise.
10505 (tdesc_i386_avx512_linux): Likewise.
10506 (x86_64_regmap): Add AVX512 registers.
10507 (x86_linux_read_description): Add code to handle AVX512 XSTATE
10508 mask.
10509 (initialize_low_arch): Add code to initialize AVX512 registers.
10510
51aa91f9
PA
105112014-04-23 Pedro Alves <palves@redhat.com>
10512
10513 * mem-break.c (find_gdb_breakpoint_at): Make static.
10514 * mem-break.h (find_gdb_breakpoint_at): Delete declaration.
10515
a4165e94
PA
105162014-04-23 Pedro Alves <palves@redhat.com>
10517
10518 * i386-low.c: Don't include break-common.h here.
10519 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
10520 prototype to take target_hw_bp_type as argument instead of a Z
10521 packet char.
10522 * i386-low.h: Include break-common.h here.
10523 (Z_packet_to_hw_type): Declare.
10524 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
10525 prototypes.
10526 * linux-x86-low.c (x86_insert_point): Convert the packet number to
10527 a target_hw_bp_type before calling i386_low_insert_watchpoint.
10528 (x86_remove_point): Convert the packet number to a
10529 target_hw_bp_type before calling i386_low_remove_watchpoint.
10530 * win32-i386-low.c (i386_insert_point): Convert the packet number
10531 to a target_hw_bp_type before calling i386_low_insert_watchpoint.
10532 (i386_remove_point): Convert the packet number to a
10533 target_hw_bp_type before calling i386_low_remove_watchpoint.
10534
b8acf843
PA
105352014-04-23 Pedro Alves <palves@redhat.com>
10536
10537 * utils.h (perror_with_name): Add ATTRIBUTE_NORETURN.
10538
d708bcd1
PA
105392014-04-10 Pedro Alves <palves@redhat.com>
10540
10541 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
10542 Check if the condition or command is NULL before checking if the
10543 breakpoint is known. On success, return true.
10544 * mem-break.h (add_breakpoint_condition): Document return.
10545 (add_breakpoint_commands): Add describing comment.
10546 * server.c (skip_to_semicolon): New function.
10547 (process_point_options): Use it.
10548
2eec7d5b
PA
105492014-04-09 Pedro Alves <palves@redhat.com>
10550
10551 * linux-low.c (linux_read_loadmap): Pass current_inferior directly
10552 to lwpid_of.
10553
fa96cb38
PA
105542014-02-27 Pedro Alves <palves@redhat.com>
10555
10556 PR 12702
10557 * inferiors.h (A_I_NEXT, ALL_INFERIORS_TYPE, ALL_PROCESSES): New
10558 macros.
10559 * linux-low.c (delete_lwp, handle_extended_wait): Add debug
10560 output.
10561 (last_thread_of_process_p): Take a PID argument instead of a
10562 thread pointer.
10563 (linux_wait_for_lwp): Delete.
10564 (num_lwps, check_zombie_leaders, not_stopped_callback): New
10565 functions.
10566 (linux_low_filter_event): New function, party factored out from
10567 linux_wait_for_event.
10568 (linux_wait_for_event): Rename to ...
10569 (linux_wait_for_event_filtered): ... this. Add new filter ptid
10570 argument. Partly rewrite. Always use waitpid(-1, WNOHANG) and
10571 sigsuspend. Check for zombie leaders.
10572 (linux_wait_for_event): Reimplement as wrapper around
10573 linux_wait_for_event_filtered.
10574 (linux_wait_1): Handle TARGET_WAITKIND_NO_RESUMED. Assume that if
10575 a normal or signal exit is seen, it's the whole process exiting.
10576 (wait_for_sigstop): No longer a for_each_inferior callback.
10577 Rewrite on top of linux_wait_for_event_filtered.
10578 (stop_all_lwps): Call wait_for_sigstop directly.
10579 * server.c (resume, handle_target_event): Handle
10580 TARGET_WAITKIND_NO_RESUMED.
10581
d763de10
JB
105822014-02-26 Joel Brobecker <brobecker@adacore.com>
10583
10584 * win32-low.c (psapi_get_dll_name,
10585 * win32_CreateToolhelp32Snapshot): Delete.
10586 (win32_CreateToolhelp32Snapshot, win32_Module32First)
10587 (win32_Module32Next, load_toolhelp, toolhelp_get_dll_name):
10588 Delete.
10589 (handle_load_dll): Add function description.
10590 Remove code using psapi_get_dll_name and toolhelp_get_dll_name.
10591
850a0f76
JB
105922014-02-26 Joel Brobecker <brobecker@adacore.com>
10593
10594 * win32-low.c (win32_add_one_solib): Add 0x1000 to load_addr.
10595 Add comment.
10596 (win32_add_all_dlls): Remove 0x1000 offset applied to DLL
10597 base address when calling win32_add_one_solib.
10598 (handle_load_dll): Delete local variable load_addr.
10599 Remove 0x1000 offset applied to DLL base address when calling
10600 win32_add_one_solib.
10601 (handle_unload_dll): Add comment.
10602
f25b3fc3
JB
106032014-02-26 Joel Brobecker <brobecker@adacore.com>
10604
10605 * win32-low.c (win32_add_all_dlls): Renames
10606 win32_ensure_ntdll_loaded. Rewrite function documentation.
10607 Adjust implementation to always load all DLLs.
10608 Add 0x1000 offset to DLL base address when calling
10609 win32_add_one_solib.
10610 (child_initialization_done): New static global.
10611 (do_initial_child_stuff): Set child_initialization_done to
10612 zero during child initialization, and 1 after. Replace call
10613 to win32_ensure_ntdll_loaded by call to win32_add_all_dlls.
10614 Add comment.
10615 (match_dll_by_basename, dll_is_loaded_by_basename): Delete.
10616 (handle_unload_dll): Add function documentation.
10617 (get_child_debug_event): Ignore load and unload DLL events
10618 during child initialization.
10619
d86d4aaf
DE
106202014-02-20 Doug Evans <dje@google.com>
10621
3bc32da3 10622 Remove global all_lwps.
d86d4aaf
DE
10623 * inferiors.h (ptid_of): Move here from linux-low.h.
10624 (pid_of, lwpid_of): Ditto.
10625 * linux-aarch64-low.c (debug_reg_change_callback): Update, "entry"
10626 parameter is a struct thread_info * now.
10627 (aarch64_notify_debug_reg_change): Fetch pid from current_inferior
10628 directly. Pass &all_threads to find_inferior instead of &all_lwps.
10629 (aarch64_stopped_data_address): Fetch lwpid from current_inferior
10630 directly.
10631 (aarch64_linux_prepare_to_resume): Fetch ptid from thread.
10632 (aarch64_arch_setup): Fetch lwpid from current_inferior directly.
10633 * linux-arm-low.c (update_registers_callback): Update, "entry"
10634 parameter is a struct thread_info * now.
10635 Fetch lwpid from current_inferior directly.
10636 (arm_insert_point): Pass &all_threads to find_inferior instead of
10637 &all_lwps.
10638 (arm_remove_point): Ditto.
10639 (arm_stopped_by_watchpoint): Fetch lwp from current_inferior.
10640 (arm_prepare_to_resume): Fetch pid from thread.
10641 (arm_read_description): Fetch lwpid from current_inferior directly.
10642 * linux-low.c (all_lwps): Delete.
10643 (delete_lwp): Delete call to remove_inferior.
10644 (handle_extended_wait): Fetch lwpid from thread.
10645 (add_lwp): Don't set lwp->entry.id. Remove call to
10646 add_inferior_to_list.
10647 (linux_attach_lwp_1): Fetch pid from current_inferior directly.
10648 (linux_kill_one_lwp): Fetch ptid,lwpid from thread.
10649 (kill_one_lwp_callback): Ditto.
10650 (linux_kill): Don't dereference NULL pointer.
10651 Fetch ptid,lwpid from thread.
10652 (get_detach_signal): Fetch ptid from thread.
10653 (linux_detach_one_lwp): Fetch ptid,lwpid from thread.
10654 Simplify call to regcache_invalidate_thread.
10655 (delete_lwp_callback): Update, "entry" parameter is a
10656 struct thread_info * now. Fetch pid from thread.
10657 (linux_mourn): Pass &all_threads to find_inferior instead of &all_lwps.
10658 (status_pending_p_callback): Update, "entry" parameter is a
10659 struct thread_info * now. Fetch ptid from thread.
10660 (find_lwp_pid): Update, "entry" parameter is a
10661 struct thread_info * now.
10662 (linux_wait_for_lwp): Fetch pid from thread.
10663 (linux_fast_tracepoint_collecting): Fetch lwpid from thread.
10664 (maybe_move_out_of_jump_pad): Fetch lwpid from current_inferior.
10665 (enqueue_one_deferred_signal): Fetch lwpid from thread.
10666 (dequeue_one_deferred_signal): Ditto.
10667 (cancel_breakpoint): Fetch ptid from current_inferior.
10668 (linux_wait_for_event): Pass &all_threads to find_inferior,
10669 not &all_lwps. Fetch ptid, lwpid from thread.
10670 (count_events_callback): Update, "entry" parameter is a
10671 struct thread_info * now.
10672 (select_singlestep_lwp_callback): Ditto.
10673 (select_event_lwp_callback): Ditto.
10674 (cancel_breakpoints_callback): Ditto.
10675 (linux_cancel_breakpoints): Pass &all_threads to find_inferior,
10676 not &all_lwps.
10677 (select_event_lwp): Ditto. Fetch ptid from event_thread.
10678 (unsuspend_one_lwp): Update, "entry" parameter is a
10679 struct thread_info * now.
10680 (unsuspend_all_lwps): Pass &all_threads to find_inferior,
10681 not &all_lwps.
10682 (linux_stabilize_threads): Ditto. And for for_each_inferior.
10683 Fetch lwpid from thread, not lwp.
10684 (linux_wait_1): Fetch ptid, lwpid from current_inferior.
10685 Pass &all_threads to find_inferior, not &all_lwps.
10686 (send_sigstop): Fetch lwpid from thread, not lwp.
10687 (send_sigstop_callback): Update, "entry" parameter is a
10688 struct thread_info * now.
10689 (suspend_and_send_sigstop_callback): Ditto.
10690 (wait_for_sigstop): Ditto. Fetch ptid, lwpid from thread, lwp.
10691 (stuck_in_jump_pad_callback): Update, "entry" parameter is a
10692 struct thread_info * now.
10693 (move_out_of_jump_pad_callback): Ditto. Fetch ptid, lwpid
10694 from thread, lwp.
10695 (lwp_running): Update, "entry" parameter is a
10696 struct thread_info * now.
10697 (stop_all_lwps): Fetch ptid from thread.
10698 Pass &all_threads to find_inferior, for_each_inferior, not &all_lwps.
10699 (linux_resume_one_lwp): Fetch lwpid from thread.
10700 (linux_set_resume_request): Update, "entry" parameter is a
10701 struct thread_info * now. Fetch pid, lwpid from thread.
10702 (resume_status_pending_p): Update, "entry" parameter is a
10703 struct thread_info * now.
10704 (need_step_over_p): Ditto. Fetch lwpid from thread.
10705 (start_step_over): Fetch lwpid from thread.
10706 (linux_resume_one_thread): Update, "entry" parameter is a
10707 struct thread_info * now. Fetch lwpid from thread.
10708 (linux_resume): Pass &all_threads to find_inferior, not &all_lwps.
10709 (proceed_one_lwp): Update, "entry" parameter is a
10710 struct thread_info * now. Fetch lwpid from thread.
10711 (unsuspend_and_proceed_one_lwp): Update, "entry" parameter is a
10712 struct thread_info * now.
10713 (proceed_all_lwps): Pass &all_threads to find_inferior, not &all_lwps.
10714 (unstop_all_lwps): Ditto. Fetch lwpid from thread.
10715 (regsets_fetch_inferior_registers): Fetch lwpid from current_inferior
10716 directly.
10717 (regsets_store_inferior_registers): Ditto.
10718 (fetch_register, store_register): Ditto.
10719 (linux_read_memory, linux_write_memory): Ditto.
10720 (linux_request_interrupt): Ditto.
10721 (linux_read_auxv): Ditto.
10722 (linux_xfer_siginfo): Ditto.
10723 (linux_qxfer_spu): Ditto.
10724 (linux_qxfer_libraries_svr4): Ditto.
10725 * linux-low.h (ptid_of, pid_of, lwpid_of): Delete,
10726 moved to inferiors.h.
10727 (get_lwp): Delete.
10728 (get_thread_lwp): Update.
10729 (struct lwp_info): Delete member "entry". Simplify comment for
10730 member "thread".
10731 (all_lwps): Delete.
10732 * linux-mips-low.c (mips_read_description): Fetch lwpid from
10733 current_inferior directly.
10734 (update_watch_registers_callback): Update, "entry" parameter is a
10735 struct thread_info * now. Fetch pid from thread.
10736 (mips_linux_prepare_to_resume): Fetch ptid from thread.
10737 (mips_insert_point): Fetch lwpid from current_inferior.
10738 Pass &all_threads to find_inferior, not &all_lwps.
10739 (mips_remove_point): Pass &all_threads to find_inferior, not &all_lwps.
10740 (mips_stopped_by_watchpoint): Fetch lwpid from current_inferior
10741 directly.
10742 (mips_stopped_data_address): Ditto.
10743 * linux-s390-low.c (s390_arch_setup): Fetch pid from current_inferior
10744 directly.
10745 * linux-tile-low.c (tile_arch_setup): Ditto.
10746 * linux-x86-low.c (x86_get_thread_area): Fetch lwpid from thread.
10747 (update_debug_registers_callback): Update, "entry" parameter is a
10748 struct thread_info * now. Fetch pid from thread.
10749 (i386_dr_low_set_addr): Fetch pid from current_inferior directly.
10750 Pass &all_threads to find_inferior, not &all_lwps.
10751 (i386_dr_low_get_addr): Fetch ptid from current_inferior directly.
10752 (i386_dr_low_set_control): Fetch pid from current_inferior directly.
10753 Pass &all_threads to find_inferior, not &all_lwps.
10754 (i386_dr_low_get_control): Fetch ptid from current_inferior directly.
10755 (i386_dr_low_get_status): Ditto.
10756 (x86_linux_prepare_to_resume): Fetch ptid from thread.
10757 (x86_siginfo_fixup): Fetch lwpid from current_inferior directly.
10758 (x86_linux_read_description): Ditto.
10759 * proc-service.c (ps_getpid): Fetch pid from current_inferior directly.
10760
3b8361aa
DE
107612014-02-20 Doug Evans <dje@google.com>
10762
10763 * inferiors.c (get_first_inferior): Fix buglet.
10764
f7667f0d
DE
107652014-02-19 Doug Evans <dje@google.com>
10766
10767 * gdbthread.h (add_thread): Change result type to struct thread_info *.
10768 * inferiors.c (add_thread): Change result type to struct thread_info *.
10769 All callers updated.
10770 (add_lwp): Call add_thread here instead of in callers.
10771 All callers updated.
10772 * linux-low.h (get_lwp_thread): Rewrite.
10773 (struct lwp_info): New member "thread".
10774
b3312d80
DE
107752014-02-19 Doug Evans <dje@google.com>
10776
10777 * linux-low.c (add_lwp): Change result to struct lwp_info *.
10778 All callers updated.
10779
ecc6f45c
DE
107802014-02-19 Doug Evans <dje@google.com>
10781
10782 * inferiors.c (add_thread): Fix whitespace.
10783
649ebbca
DE
107842014-02-19 Doug Evans <dje@google.com>
10785
10786 * dll.c (clear_dlls): Replace accessing list implemention details
10787 with API function.
10788 * gdbthread.h (get_first_thread): Declare.
10789 * inferiors.c (for_each_inferior_with_data): New function.
10790 (get_first_thread): New function.
10791 (find_thread_ptid): Simplify.
10792 (get_first_inferior): New function.
10793 (clear_list): Delete.
10794 (one_inferior_p): New function.
10795 (clear_inferior_list): New function.
10796 (clear_inferiors): Update.
10797 * inferiors.h (for_each_inferior_with_data): Declare.
10798 (clear_inferior_list): Declare.
10799 (one_inferior_p): Declare.
10800 (get_first_inferior): Declare.
10801 * linux-low.c (linux_wait_for_event): Replace accessing list
10802 implemention details with API function.
10803 * server.c (target_running): Ditto.
10804 (accumulate_file_name_length): New function.
10805 (emit_dll_description): New function.
10806 (handle_qxfer_libraries): Replace accessing list implemention
10807 details with API function.
10808 (handle_qxfer_threads_worker): New function.
10809 (handle_qxfer_threads_proper): Replace accessing list implemention
10810 details with API function.
10811 (handle_query): Ditto.
10812 (visit_actioned_threads_callback_ftype): New typedef.
10813 (visit_actioned_threads_data): New struct.
10814 (visit_actioned_threads): Rewrite to be find_inferior callback.
10815 (resume): Call find_inferior.
10816 (handle_status): Replace accessing list implemention
10817 details with API function.
10818 (process_serial_event): Replace accessing list implemention details
10819 with API function.
10820 * target.c (set_desired_inferior): Replace accessing list implemention
10821 details with API function.
10822 * tracepoint.c (same_process_p): New function.
10823 (gdb_agent_about_to_close): Replace accessing list implemention
10824 details with API function.
10825 * win32-low.c (child_delete_thread): Replace accessing list
10826 implemention details with API function.
10827 (match_dll_by_basename): New function.
10828 (dll_is_loaded_by_basename): New function.
10829 (win32_ensure_ntdll_loaded): Replace accessing list implemention
10830 details call to dll_is_loaded_by_basename.
10831
80894984
DE
108322014-02-19 Doug Evans <dje@google.com>
10833
10834 * dll.h (struct dll_info): Add comment.
10835 * gdbthread.h (struct thread_info): Add comment.
10836 (current_ptid): Simplify.
10837 * inferiors.c (add_process): Update.
10838 (remove_process): Update.
10839 * inferiors.h (struct process_info): Rename member "head" to "entry".
10840 * linux-low.c (delete_lwp): Update.
10841 (add_lwp): Update.
10842 (last_thread_of_process_p): Update.
10843 (kill_one_lwp_callback, linux_kill): Update.
10844 (status_pending_p_callback): Update.
10845 (wait_for_sigstop): Update. Simplify read of ptid.
10846 (start_step_over): Update.
10847 * linux-low.h (ptid_of, pid_of, lwpid_of): Update.
10848 (get_lwp_thread): Update.
10849 (struct lwp_info): Rename member "head" to "entry".
10850 * regcache.h (inferior_list_entry): Delete.
10851 * server.c (kill_inferior_callback): Update.
10852 (detach_or_kill_inferior_callback): Update.
10853 (print_started_pid): Update.
10854 (print_attached_pid): Update.
10855 (process_serial_event): Simplify read of ptid.
10856 * thread-db.c (thread_db_create_event): Update.
10857 (thread_db_get_tls_address): Update.
10858 * win32-low.c (current_inferior_ptid): Simplify.
10859
46917d26
TT
108602014-02-19 Tom Tromey <tromey@redhat.com>
10861
10862 * target.h (struct target_ops) <supports_btrace>: Add target_ops
10863 argument.
10864 (target_supports_btrace): Update.
10865
0759a81e
YQ
108662014-02-14 Yao Qi <yao@codesourcery.com>
10867
10868 * Makefile.in (IPA_OBJS): Append rsp-low-ipa.o.
10869 (rsp-low-ipa.o): New target.
10870
a7191e8b
TT
108712014-02-12 Tom Tromey <tromey@redhat.com>
10872
10873 * ax.c (gdb_parse_agent_expr): Use hex2bin, not
10874 convert_ascii_to_int.
10875 * regcache.c (registers_to_string): Likewise.
10876 * remote-utils.c (decode_M_packet): Likewise.
10877 * server.c (process_serial_event): Likewise.
10878
ff0e980e
TT
108792014-02-12 Tom Tromey <tromey@redhat.com>
10880
10881 * server.c (handle_query, handle_v_run): Use hex2bin, not
10882 unhexify.
10883 * tracepoint.c (cmd_qtdpsrc, cmd_qtdv, cmd_qtnotes): Likewise.
10884
e9371aff
TT
108852014-02-12 Tom Tromey <tromey@redhat.com>
10886
10887 * ax.c (gdb_unparse_agent_expr): Use bin2hex, not
10888 convert_int_to_ascii.
10889 * regcache.c (registers_to_string, collect_register_as_string):
10890 Likewise.
10891 * remote-utils.c (look_up_one_symbol, relocate_instruction):
10892 Likewise.
10893 * server.c (process_serial_event): Likewise.
10894 * tracepoint.c (cmd_qtstatus, response_source, response_tsv)
10895 (cmd_qtbuffer, cstr_to_hexstr): Likewise.
10896
971dc0b8
TT
108972014-02-12 Tom Tromey <tromey@redhat.com>
10898
10899 * remote-utils.c (look_up_one_symbol, monitor_output): Use
10900 bin2hex, not hexify.
10901 * tracepoint.c (cmd_qtstatus): Likewise.
10902
0a822afb
TT
109032014-02-12 Tom Tromey <tromey@redhat.com>
10904
10905 * remote-utils.c (monitor_output): Pass explicit length to
10906 hexify.
10907
9c3d6531
TT
109082014-02-12 Tom Tromey <tromey@redhat.com>
10909
10910 * tracepoint.c: Include rsp-low.h.
10911 * server.c: Include rsp-low.h.
10912 * remote-utils.h (convert_ascii_to_int, convert_int_to_ascii)
10913 (unhexify, hexify, remote_escape_output, unpack_varlen_hex): Don't
10914 declare.
10915 * remote-utils.c: Include rsp-low.h.
10916 (fromhex, hexchars, ishex, unhexify, tohex, hexify)
10917 (remote_escape_output, remote_unescape_input, unpack_varlen_hex)
10918 (convert_int_to_ascii, convert_ascii_to_int): Move to
10919 common/rsp-low.c.
10920 * regcache.c: Include rsp-low.h.
10921 * ax.c: Include rsp-low.h.
10922 * Makefile.in (SFILES): Add common/rsp-low.c.
10923 (OBS): Add rsp-low.o.
10924 (rsp-low.o): New target.
10925
01fd3ea5
TT
109262014-02-12 Tom Tromey <tromey@redhat.com>
10927
10928 * utils.h (pulongest, plongest, phex_nz): Don't declare.
10929 Include print-utils.h.
10930 * utils.c (NUMCELLS, CELLSIZE, get_cell, decimal2str, pulongest)
10931 (plongest, thirty_two, phex_nz): Remove.
10932 * Makefile.in (SFILES): Add common/print-utils.c.
10933 (OBS): Add print-utils.o.
10934 (print-utils-ipa.o): New target.
10935 (print-utils.o): New target.
10936 (IPA_OBJS): Add print-utils-ipa.o.
10937
e99dc820
TT
109382014-02-06 Tom Tromey <tromey@redhat.com>
10939
10940 * Makefile.in (SFILES): Fix indentation.
10941
ee1e2d4f
DE
109422014-02-05 Doug Evans <dje@google.com>
10943
10944 * linux-low.c (linux_wait_for_event): Improve comment.
10945 (linux_wait_1): Keep current_inferior in sync with event_child.
10946
f5a02773
DE
109472014-01-22 Doug Evans <dje@google.com>
10948
10949 * gdbthread.h (gdb_id_to_thread): Delete, unused.
10950
87ce2a04
DE
109512014-01-22 Doug Evans <dje@google.com>
10952
10953 * configure.ac (AC_CHECK_FUNCS): Add test for gettimeofday.
10954 * configure: Regenerate.
10955 * config.in: Regenerate.
10956 * Makefile.in (SFILES): Add debug.c.
10957 (OBS): Add debug.o.
10958 * debug.c: New file.
10959 * debug.h: New file.
10960 * linux-aarch64-low.c (*): Update all debugging printfs to use
10961 debug_printf instead of fprintf.
10962 * linux-arm-low.c (*): Ditto.
10963 * linux-cris-low.c (*): Ditto.
10964 * linux-crisv32-low.c (*): Ditto.
10965 * linux-m32r-low.c (*): Ditto.
10966 * linux-sparc-low.c (*): Ditto.
10967 * linux-x86.c (*): Ditto.
10968 * linux-low.c (*): Ditto.
10969 (linux_wait_1): Add calls to debug_enter, debug_exit.
10970 (linux_wait): Remove redundant debugging printf.
10971 (stop_all_lwps): Add calls to debug_enter, debug_exit.
10972 (linux_resume, unstop_all_lwps): Ditto.
10973 * mem-break.c (*): Update all debugging printfs to use
10974 debug_printf instead of fprintf.
10975 * remote-utils.c (*): Ditto.
10976 * thread-db.c (*): Ditto.
10977 * server.c #include <ctype.h>, "gdb_vecs.h".
10978 (debug_threads): Moved to debug.c.
10979 (*): Update all debugging printfs to use debug_printf instead of
10980 fprintf.
10981 (start_inferior): Replace call to fflush with call to debug_flush.
10982 (monitor_show_help): Mention set debug-format.
10983 (parse_debug_format_options): New function.
10984 (handle_monitor_command): Handle "monitor set debug-format".
10985 (gdbserver_usage): Mention --debug-format.
10986 (main): Parse --debug-format.
10987 * server.h (debug_threads): Declaration moved to debug.h.
10988 #include "debug.h".
10989 * tracepoint.c (trace_debug_1) [!IN_PROCESS_AGENT]: Add version of
10990 trace_debug_1 that uses debug_printf.
10991 (tracepoint_look_up_symbols): Update all debugging printfs to use
10992 debug_printf instead of fprintf.
10993
e671835b
BS
109942014-01-20 Baruch Siach <baruch@tkos.co.il>
10995
10996 * linux-xtensa-low.c: Include asm/ptrace.h instead of
10997 sys/ptrace.h.
10998
b5737fa9
PA
109992014-01-17 Pedro Alves <palves@redhat.com>
11000
ea38d2a9 11001 PR build/16445
c7faa97a
PA
11002 * linux-x86-low.c: Don't include elf/common.h if ELFMAG0 is
11003 defined after including gdb_proc_service.h.
b5737fa9 11004
40ed484e
DE
110052014-01-16 Doug Evans <dje@google.com>
11006
11007 * dll.c (UNSPECIFIED_CORE_ADDR): New macro.
11008 (match_dll): Use it.
11009
969c39fb
MM
110102014-01-16 Markus Metzger <markus.t.metzger@intel.com>
11011
11012 * target.h (target_ops) <read_btrace>: Change parameters and
11013 return type to allow error reporting.
11014 * server.c (handle_qxfer_btrace): Support delta reads. Pass
11015 trace reading errors on.
11016 * linux-low.c (linux_low_read_btrace): Pass trace reading
11017 errors on.
11018 (linux_low_disable_btrace): New.
11019
ab7f45ba
DE
110202014-01-15 Doug Evans <dje@google.com>
11021
11022 * inferiors.c (thread_id_to_gdb_id): Delete.
11023 * inferiors.h (thread_id_to_gdb_id): Delete.
11024
66af0f44
EZ
110252014-01-13 Eli Zaretskii <eliz@gnu.org>
11026
11027 * Makefile.in (INCLUDE_CFLAGS): Remove trailing slash from
11028 "-I$(srcdir)/../". Fixes MinGW compilation errors with old GCC
11029 versions.
11030
9939e131
PA
110312014-01-08 Pedro Alves <palves@redhat.com>
11032
11033 * server.c (handle_status): Don't discard previous queued stop
11034 replies or thread's pending status here.
11035 (main) <disconnection>: Do it here instead.
11036
b7ea362b
PA
110372014-01-08 Pedro Alves <palves@redhat.com>
11038
11039 * gdbthread.h (struct thread_info) <status_pending_p>: New field.
11040 * server.c (visit_actioned_threads, handle_pending_status): New
11041 function.
11042 (handle_v_cont): Factor out parts to ...
11043 (resume): ... this new function. If in all-stop, and a thread
11044 being resumed has a pending status, report it without actually
11045 resuming.
11046 (myresume): Adjust to use the new 'resume' function.
11047 (clear_pending_status_callback, set_pending_status_callback)
11048 (find_status_pending_thread_callback): New functions.
11049 (handle_status): Handle the case of multiple threads having
11050 interesting statuses to report. Report threads' real last signal
11051 instead of always reporting GDB_SIGNAL_TRAP. Look for a thread
11052 with an interesting thread to report the status for, instead of
11053 always reporting the status of the first thread.
11054
28498c42
JB
110552014-01-01 Joel Brobecker <brobecker@adacore.com>
11056
11057 * gdbserver.c (gdbserver_version): Set copyright year to 2014.
11058 * gdbreplay.c (gdbreplay_version): Likewise.
11059
f45c82da
YZ
110602013-12-18 Yufeng Zhang <yufeng.zhang@arm.com>
11061
11062 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Set
11063 iov.iov_len with the real length in use.
11064
379a5e2d
JB
110652013-12-13 Joel Brobecker <brobecker@adacore.com>
11066
11067 * Makefile.in (safe-ctype.o, lbasename.o): New rules.
11068 * configure.srv: Add safe-ctype.o and lbasename.o to srv_tgtobj
11069 for all targets that use win32-low.c.
11070 * win32-low.c (win32_ensure_ntdll_loaded): New function.
11071 (do_initial_child_stuff): Add call to win32_ensure_ntdll_loaded.
11072
4210d83e
PA
110732013-12-13 Pedro Alves <palves@redhat.com>
11074
11075 * target.c (mywait): Set OURSTATUS->KIND to TARGET_WAITKIND_STOPPED
11076 if equal to TARGET_WAITKIND_LOADED.
11077 * win32-low.c (cached_status): New static global.
11078 (win32_wait): Add declaration.
11079 (do_initial_child_stuff): Flush all initial pending debug events
11080 up to the initial breakpoint.
11081 (win32_wait): If CACHED_STATUS was set, return that instead
11082 of doing a real wait. Remove the code resuming the execution
11083 of the inferior after receiving a TARGET_WAITKIND_LOADED event
11084 during the initial phase. Also remove the code changing
11085 OURSTATUS->KIND from TARGET_WAITKIND_LOADED to
11086 TARGET_WAITKIND_STOPPED.
11087
e7f0d979
YQ
110882013-12-11 Yao Qi <yao@codesourcery.com>
11089
11090 * notif.c (handle_notif_ack): Return 0 if no notification
11091 matches.
11092
ebcf782c
DE
110932013-11-20 Doug Evans <dje@google.com>
11094
11095 * linux-low.c (linux_set_resume_request): Fix comment.
11096
20ad9378
DE
110972013-11-20 Doug Evans <dje@google.com>
11098
11099 * linux-low.c (resume_status_pending_p): Tweak comment.
11100
a196ebeb
WT
111012013-11-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
11102
11103 * Makefile.in: Add i386-mpx.c, i386-mpx-linux.c, amd64-mpx.c,
11104 amd64-mpx-linux.c, x32-mpx.c and x32-mpx-linux.c generation.
11105 * configure.srv (srv_i386_regobj): Add i386-mpx.o.
11106 (srv_i386_linux_regobj): Add i386-mpx-linux.o.
11107 (srv_amd64_regobj): Add amd64-mpx.o.
11108 (srv_amd64_linux_regobj): Add amd64-mpx-linux.o.
11109 (srv_i386_32bit_xmlfiles): Add i386/32bit-mpx.xml.
11110 (srv_i386_64bit_xmlfiles): Add i386/64bit-mpx.xml.
11111 * i387-fp.c (num_pl_bnd_register) Added constant.
11112 (num_pl_bnd_cfg_registers) Added constant.
11113 (struct i387_xsave) Added reserved area and MPX fields.
11114 (i387_cache_to_xsave, i387_xsave_to_cache) Add MPX.
11115 * linux-x86-low.c (init_registers_i386_mpx_linux): Declare new
11116 function.
11117 (tdesc_i386_mpx_linux): Add MPX amd64 target.
11118 (init_registers_amd64_mpx_linux): Declare new function.
11119 (tdesc_amd64_mpx_linux): Add MPX amd64 target.
11120 (x86_64_regmap): Add MPX registers.
11121 (x86_linux_read_description): Add MPX case.
11122 (initialize_low_arch): Initialize MPX targets.
11123
0080a2f6
TT
111242013-11-18 Tom Tromey <tromey@redhat.com>
11125
11126 * configure: Rebuild.
11127 * configure.ac: Don't check for stdlib.h.
11128 * gdbreplay.c: Unconditionally include stdlib.h.
11129
2978b111
TT
111302013-11-18 Tom Tromey <tromey@redhat.com>
11131
11132 * config.in: Rebuild.
11133 * configure: Rebuild.
11134 * configure.ac: Don't use AC_HEADER_DIRENT.
11135
a3d08894
TT
111362013-11-18 Tom Tromey <tromey@redhat.com>
11137
11138 * server.h: Don't check HAVE_STRING_H.
11139 * gdbreplay.c: Don't check HAVE_STRING_H.
11140 * configure: Rebuild.
11141
0a5dd17d
TT
111422013-11-18 Tom Tromey <tromey@redhat.com>
11143
11144 * Makefile.in (gdbreplay$(EXEEXT)): Depend on and link against
11145 LIBGNU.
11146
1bd2f0ba
TT
111472013-11-08 Tom Tromey <tromey@redhat.com>
11148
11149 * configure, config.in: Rebuild.
11150 * configure.ac: Remove unused configury.
11151
3266f10b
TT
111522013-11-08 Tom Tromey <tromey@redhat.com>
11153
11154 * acinclude.m4: Include common.m4, codeset.m4.
11155 * configure, config.in: Rebuild.
11156 * configure.ac: Use GDB_AC_COMMON.
11157
6682d959
AA
111582013-11-06 Andreas Arnez <arnez@linux.vnet.ibm.com>
11159
11160 * linux-s390-low.c (HWCAP_S390_TE): New define.
11161 (s390_arch_setup): Consider the TE field in the HWCAP for
11162 determining 'have_regset_tdb'.
11163
fd0a4d76
SDJ
111642013-10-16 Sergio Durigan Junior <sergiodj@redhat.com>
11165
11166 PR gdb/16014
11167 * tracepoint.c (download_tracepoint_1): Remove unnecessary double
11168 call to sizeof.
11169
1a3d890b
PA
111702013-10-02 Pedro Alves <palves@redhat.com>
11171
11172 * server.c (process_serial_event): Don't output "GDBserver
11173 exiting" if GDB is connected through stdio.
11174 * target.c (mywait): Likewise, be silent if GDB is connected
11175 through stdio.
11176
97ad4581
JB
111772013-10-01 Joel Brobecker <brobecker@adacore.com>
11178
11179 * lynx-low.c (lynx_add_threads_after_attach): New function.
11180 (lynx_attach): Remove call to add_thread. Add call to
11181 lynx_add_threads_after_attach instead.
11182
5b4e221c
MF
111832013-09-28 Mike Frysinger <vapier@gentoo.org>
11184
11185 * configure.ac (AC_CHECK_HEADERS): Add sys/syscall.h
11186 * config.in, configure: Regenerated.
11187
ee47b2f8
YQ
111882013-09-18 Yao Qi <yao@codesourcery.com>
11189
11190 PR server/15959
11191 * server.c (start_inferior): Clear 'resume_info'.
11192
d6707650 111932013-09-16 Jiong Wang <jiwang@tilera.com>
0f63d4db 11194
d6707650
JW
11195 * linux-tile-low.c (tile_regsets): Modify the size field to 64-bit
11196 for each register.
11197
9243dd0e 111982013-09-16 Jiong Wang <jiwang@tilera.com>
0f63d4db 11199
9243dd0e
JW
11200 * configure.srv <tilegx*-*-linux*>: Remove linux-osdata.o from and add
11201 linux-tile-low.o to srv_tgtobj.
11202
c623a6ef
WN
112032013-09-16 Will Newton <will.newton@linaro.org>
11204
11205 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Zero
11206 out regs.
11207
fb71d39e
PA
112082013-09-06 Pedro Alves <palves@redhat.com>
11209
11210 * Makefile.in (gdb_proc_service_h, regdef_h, regcache_h)
11211 (signals_def, signals_h, ptid_h, ax_h, agent_h, linux_btrace_h)
11212 (linux_osdata_h, vec_h, gdb_vecs_h, host_defs_h, libiberty_h)
11213 (server_h, gdbthread_h, linux_low_h, linux_ptrace_h)
11214 (gdb_thread_db_h, linux_procfs_h, lynx_low_h, nto_low_h)
11215 (mips_linux_watch_h, i386_low_h, win32_low_h): Delete.
11216
8e7e9910
PA
112172013-09-06 Pedro Alves <palves@redhat.com>
11218
11219 * Makefile.in (linux-btrace.o, mips-linux-watch.o): Remove
11220 explicit header dependencies and use $COMPILE/$POSTCOMPILE.
11221
7c3a12ca
PA
112222013-09-06 Pedro Alves <palves@redhat.com>
11223
11224 * linux-amd64-ipa.c: Include tracepoint.h.
11225 * linux-i386-ipa.c: Include tracepoint.h.
11226
8eb3d7b6
RW
112272013-09-06 Ricard Wanderlof <ricardw@axis.com>
11228
11229 * linux-crisv32-low.c (PTRACE_GET_THREAD_AREA): New macro.
11230 (ps_get_thread_area): New function.
11231
eddddb9d
RW
112322013-09-06 Ricard Wanderlof <ricardw@axis.com>
11233
11234 * linux-crisv32-low.c (elf_gregset_t): Delete typedef.
11235 (initialize_low_arch): Call init_registers_crisv32 rather than
11236 init_register_crisv32.
11237
533b0600
PA
112382013-09-05 Pedro Alves <palves@redhat.com>
11239
11240 * server.h (handle_vFile, hostio_last_error_from_errno): Move
11241 to ...
11242 * hostio.h: ... this new file.
11243 * hostio.c, server.c, linux-low.c, nto-low.c, spu-low,
11244 win32-low.c: Include hostio.h.
11245
0ce3d3b5
PA
112462013-09-05 Pedro Alves <palves@redhat.com>
11247
11248 * server.h (gdb_client_data, handler_func, callback_handler_func)
11249 (delete_file_handler, add_file_handler, append_callback_event)
11250 (delete_callback_event, start_event_loop, initialize_event_loop):
11251 Move to event-loop.h and include it.
11252 * event-loop.h: New file.
11253
799cdc37
PA
112542013-09-05 Pedro Alves <palves@redhat.com>
11255
11256 * dll.c, inferiors.c, remote-utils.c, server.c: Include "dll.h".
11257 * server.h (struct dll_info, all_dlls, dlls_changed, clear_dlls)
11258 (loaded_dll, unloaded_dll): Move to ...
11259 * dll.h: ... this new file.
11260 * inferiors.c, remote-utils.c, win32-low.c: Include "dll.h".
11261
6a6bbd9d
PA
112622013-09-05 Pedro Alves <palves@redhat.com>
11263
11264 * server.h (current_process, get_thread_process, all_processes)
11265 (add_inferior_to_list, for_each_inferior, current_inferior)
11266 (remove_inferior, add_process, remove_process, find_process_pid)
11267 (have_started_inferiors_p, have_attached_inferiors_p)
11268 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id)
11269 (clear_inferiors, find_inferior, find_inferior_id)
11270 (inferior_target_data, set_inferior_target_data)
11271 (inferior_regcache_data, set_inferior_regcache_data): Move to
11272 inferiors.h, and include it.
11273 * inferiors.h: New file.
11274
f699aaba
PA
112752013-09-05 Pedro Alves <palves@redhat.com>
11276
11277 * server.h (struct emit_ops, current_insn_ptr, emit_error):
11278 Move ...
72f4393d 11279 * ax.h: ... here.
f699aaba 11280
c144c7a0
PA
112812013-09-05 Pedro Alves <palves@redhat.com>
11282
11283 * ax.c, linux-low.c, linux-x86-low.c, server.c: Include
11284 tracepoint.h.
11285 * server.h (IPA_BUFSIZ, initialize_tracepoint, tracing)
11286 (disconnected_tracing, tracepoint_look_up_symbols, stop_tracing
11287 (handle_tracepoint_general_set, handle_tracepoint_query)
11288 (tracepoint_finished_step, tracepoint_was_hit)
11289 (release_while_stepping_state_list, current_traceframe)
11290 (in_readonly_region, traceframe_read_mem)
11291 (fetch_traceframe_registers, traceframe_read_sdata)
11292 (traceframe_read_info, struct fast_tpoint_collect_status)
11293 (fast_tracepoint_collecting, force_unlock_trace_buffer)
11294 (handle_tracepoit_bkpts, initialize_low_tracepoint)
11295 (supply_fast_tracepoint_registers)
11296 (supply_static_tracepoint_registers, set_trampoline_buffer_space)
11297 (ipa_tdesc, claim_trampoline_space)
11298 (have_fast_tracepoint_trampoline_buffer, gdb_agent_about_to_close)
11299 (agent_mem_read, agent_get_trace_state_variable_value)
11300 (agent_set_trace_state_variable_value, agent_tsv_read)
11301 (agent_mem_read_string, get_raw_reg_func_addr)
11302 (get_get_tsv_func_addr, get_set_tsv_func_addr): Move to ...
11303 * tracepoint.h: ... this new file.
11304
ff42e6ab
PA
113052013-09-05 Pedro Alves <palves@redhat.com>
11306
11307 * server.h (perror_with_name, error, fatal, warning, paddress)
11308 (pulongest, plongest, phex_nz, pfildes): Move to utils.h, and
11309 include it.
11310 * utils.h: New file.
11311
541af0f4
PA
113122013-09-05 Pedro Alves <palves@redhat.com>
11313
11314 * server.h (remote_debug, noack_mode, transport_is_reliable)
11315 (gdb_connected, STDIO_CONNECTION_NAME, remote_connection_is_stdio)
11316 (read_ptid, write_ptid, putpkt, putpkt_binary, putpkt_notif)
11317 (getpkt, remote_prepare, remote_open, remote_close, write_ok)
11318 (write_enn, initialize_async_io, enable_async_io)
11319 (disable_async_io, check_remote_input_interrupt_request)
11320 (convert_ascii_to_int, convert_int_to_ascii, new_thread_notify)
11321 (dead_thread_notify, prepare_resume_reply)
11322 (decode_address_to_semicolon, decode_address, decode_m_packet)
11323 (decode_M_packet, decode_X_packet, decode_xfer_write)
11324 (decode_search_memory_packet, unhexify, hexify)
11325 (remote_escape_output, unpack_varlen_hex, clear_symbol_cache)
11326 (look_up_one_symbol, relocate_instruction)
11327 (monitor_output): Move to remote-utils.h, and include it.
11328 * remote-utils.h: New file.
11329
eebdf26b
PA
113302013-09-05 Pedro Alves <palves@redhat.com>
11331
11332 * server.h (_): Delete.
11333
3aafd2ff
PA
113342013-09-02 Pedro Alves <palves@redhat.com>
11335
11336 * tracepoint.c (TRACEFRAME_EOB_MARKER_SIZE): New macro.
11337 (init_trace_buffer): Ensure at least TRACEFRAME_EOB_MARKER_SIZE is
11338 allocated.
11339 (trace_buffer_alloc): Use TRACEFRAME_EOB_MARKER_SIZE.
11340
cee83bcb
PM
113412013-09-02 Pierre Muller <muller@sourceware.org>
11342
11343 * win32-low.c (child_xfer_memory): Check if ReadProcessMemory
11344 or WriteProcessMemory complete successfully and handle
11345 ERROR_PARTIAL_COPY error.
11346
9a13b2fa
PA
113472013-09-02 Pedro Alves <palves@redhat.com>
11348
11349 * server.c (gdb_read_memory): Return -1 on traceframe memory read
11350 error instead of EIO.
11351
602e3198
JK
113522013-08-28 Jan Kratochvil <jan.kratochvil@redhat.com>
11353
11354 PR server/15604
11355 * linux-low.c: Include filestuff.h.
11356 (linux_create_inferior) <pid == 0>: Call close_most_fds.
11357 * lynx-low.c: Include filestuff.h.
11358 (lynx_create_inferior) <pid == 0>: Call close_most_fds.
11359 * server.c: Include filestuff.h.
11360 (main): Call notice_open_fds.
11361 * spu-low.c: Include filestuff.h.
11362 (spu_create_inferior) <pid == 0>: Call close_most_fds.
11363
96d7229d
LM
113642013-08-22 Luis Machado <lgustavo@codesourcery.com>
11365
11366 * Makefile.in: Explain why ../target and ../nat are not
11367 listed as include file search paths.
11368 (linux-waitpid.o): New object file rule.
11369 * configure.srv (srv_native_linux_obj): New variable.
11370 Replace all occurrences of linux native object files with
11371 $srv_native_linux_obj.
11372 * linux-low.c: Include nat/linux-nat.h and nat/linux-waitpid.h.
11373 (HAS_NOMMU): Move defining logic to common/linux-ptrace.c.
11374 (linux_enable_event_reporting): Remove declaration.
11375 (my_waitpid): Moved to common/linux-waitpid.c.
11376 (linux_wait_for_event): Pass ptid when calling
11377 linux_enable_event_reporting.
11378 (linux_supports_tracefork_flag): Remove.
11379 (linux_enable_event_reporting): Likewise.
11380 (linux_tracefork_grandchild): Remove.
11381 (STACK_SIZE): Moved to common/linux-ptrace.c.
11382 (linux_tracefork_child): Remove.
11383 (linux_test_for_tracefork): Remove.
11384 (linux_look_up_symbols): Call linux_supports_traceclone.
11385 (initialize_low): Remove call to linux_test_for_tracefork.
11386 * linux-low.h (PTRACE_TYPE_ARG3): Move to
11387 common/linux-ptrace.h.
11388 (PTRACE_TYPE_ARG4): Likewise.
11389 Include linux-ptrace.h.
11390
32940073
PA
113912013-08-21 Pedro Alves <palves@redhat.com>
11392
11393 * config.in: Renegerate.
11394
33b60d58 113952013-08-19 Luis Machado <lgustavo@codesourcery.com>
a261b8f5 11396
33b60d58
LM
11397 * Makefile.in (INCLUDE_CFLAGS): Include -I$(srcdir)/../.
11398 (SFILES): Remove $(srcdir)/common/target-common.c and
11399 add $(srcdir)/target/waitstatus.c.
11400 (OBS): Remove target-common.o and add waitstatus.o.
11401 (server_h): Remove $(srcdir)/../common/target-common.h and
11402 add $(srcdir)/../target/resume.h, $(srcdir)/../target/wait.h
11403 and $(srcdir)/../target/waitstatus.h.
11404 (target-common.o): Remove.
11405 (waitstatus.o): New target object file.
11406 * target.h: Do not include target-common.h and
11407 include target/resume.h, target/wait.h and
11408 target/waitstatus.h.
11409
b8e1b30e
LM
114102013-08-13 Luis Machado <lgustavo@codesourcery.com>
11411
11412 * linux-arm-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
11413 to PTRACE_TYPE_ARG3.
11414 * linux-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
11415 to PTRACE_TYPE_ARG3 and PTRACE_ARG4_TYPE to
11416 PTRACE_TYPE_ARG4.
11417 * linux-low.h (PTRACE_ARG3_TYPE): Rename to PTRACE_TYPE_ARG3.
11418 (PTRACE_ARG4_TYPE): Rename to PTRACE_TYPE_ARG4.
11419
7a60ad40
YQ
114202013-07-27 Jie Zhang <jie@codesourcery.com>
11421 Daniel Jacobowitz <dan@codesourcery.com>
11422 Yao Qi <yao@codesourcery.com>
11423
11424 * Makefile.in (SFILES): Add common/mips-linux-watch.c.
11425 (mips-linux-watch.o): New rule.
11426 (mips_linux_watch_h): New variable.
11427 * configure.srv <mips*-*-linux*>: Add mips-linux-watch.o to
11428 srv_tgtobj.
11429 * linux-mips-low.c: Include mips-linux-watch.h.
11430 (struct arch_process_info, struct arch_lwp_info): New.
11431 (update_watch_registers_callback): New function.
11432 (mips_linux_new_process, mips_linux_new_thread) New functions.
11433 (mips_linux_prepare_to_resume, mips_insert_point): New
11434 functions.
11435 (mips_remove_point, mips_stopped_by_watchpoint): New
11436 functions.
11437 (rsp_bp_type_to_target_hw_bp_type): New function.
11438 (mips_stopped_data_address): New function.
11439 (the_low_target): Add watchpoint support functions.
11440
de6f69ad
YQ
114412013-07-27 Yao Qi <yao@codesourcery.com>
11442
11443 * i386-low.c: Include break-common.h.
11444 (enum target_hw_bp_type): Remove.
11445
3360c0bf
LM
114462013-07-24 Luis Machado <lgustavo@codesourcery.com>
11447
11448 * Makefile.in (SFILES): /common/target-common.c.
11449 (OBS): Add target-common.o.
11450 (server_h): Add $(srcdir)/../common/target-common.h.
11451 (target-common.o): New target.
11452 * server.c (queue_stop_reply_callback): Free
11453 status string after use.
11454 * target.c (target_waitstatus_to_string): Remove.
11455 * target.h: Include target-common.h.
11456 (resume_kind): Likewise.
11457 (target_waitkind): Likewise.
11458 (target_waitstatus): Likewise.
11459 (TARGET_WNOHANG): Likewise.
11460
bd885420
YQ
114612013-07-04 Yao Qi <yao@codesourcery.com>
11462
11463 * Makefile.in (host_alias): Use @host_noncanonical@.
11464 (target_alias): Use @target_noncanonical@.
11465 * configure.ac: Use ACX_NONCANONICAL_TARGET and
11466 ACX_NONCANONICAL_HOST.
11467 * configure: Regenerated.
11468
11469 Revert:
11470 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
11471
11472 * configure.ac (version_host, version_target): Set and AC_SUBST them.
11473 * configure: Rebuild.
11474 * Makefile.in (version_host, version_target): Get from configure.
11475 (version.c): Use $(version_host) and $(version_target).
11476
17ef446e
PA
114772013-07-03 Pedro Alves <palves@redhat.com>
11478
11479 * Makefile.in (config.status): Depend on development.sh.
11480 * acinclude.m4: Include libmcheck.m4.
11481 * configure: Regenerate.
11482
7a9a7487
MG
114832013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
11484
11485 * win32-low.c (winapi_DebugActiveProcessStop): Move the WINAPI
11486 attribute inside the parentheses.
11487 (winapi_DebugSetProcessKillOnExit): Ditto.
11488 (winapi_DebugBreakProcess): Ditto.
11489 (winapi_GenerateConsoleCtrlEvent): Ditto.
a261b8f5 11490
49b64de6
MG
114912013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
11492
11493 * notif.h (notif_event): Add a dummy member to avoid compiler
11494 errors.
11495
d5749ee7
PA
114962013-07-01 Pedro Alves <palves@redhat.com>
11497
11498 * hostio.c (HOSTIO_PATH_MAX): Define.
11499 (require_filename, handle_open, handle_unlink, handle_readlink):
11500 Use it.
11501
d8d2a3ee
PA
115022013-07-01 Pedro Alves <palves@redhat.com>
11503
11504 * server.h: Include "pathmax.h".
11505 * linux-low.c: Don't include sys/param.h.
11506 (linux_pid_exe_is_elf_64_file): Use PATH_MAX instead of
11507 MAXPATHLEN.
11508 * win32-low.c: Don't include sys/param.h.
11509 (win32_create_inferior): Use PATH_MAX instead of MAXPATHLEN.
11510
bc7dea8d
PA
115112013-07-01 Pedro Alves <palves@redhat.com>
11512
11513 * event-loop.c: Don't check HAVE_UNISTD_H before including
11514 <unistd.h>.
11515 * gdbreplay.c: Likewise.
11516 * remote-utils.c: Likewise.
11517 * server.c: Likewise.
11518 * configure.ac: Don't check for unistd.h.
11519 * configure: Regenerate.
11520
d6c2da54
TT
115212013-06-28 Tom Tromey <tromey@redhat.com>
11522
11523 * Makefile.in (version.c): Use version.in, not
11524 common/version.in.
11525
257b6bec
MG
115262013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
11527
11528 * configure.ac (version_host, version_target): Set and AC_SUBST them.
11529 * configure: Rebuild.
11530 * Makefile.in (version_host, version_target): Get from configure.
11531 (version.c): Use $(version_host) and $(version_target).
11532
86ebe149
DK
115332013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
11534
11535 Fix trace-status to output user name without trailing colon.
11536 * tracepoint.c (cmd_qtstatus): Remove unnecessary colon from user name.
11537
f30aa5af
DK
115382013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
11539
11540 Fix trace-status to output proper start-time and stop-time.
11541 * tracepoint.c (cmd_qtstatus): Modify trace-status output to
11542 output start time and stop time in hex as gdb expects.
11543
28a93511
YQ
115442013-06-26 Pedro Alves <pedro@codesourcery.com>
11545
11546 * tracepoint.c (build_traceframe_info_xml): Output trace state
11547 variables present in the trace buffer.
11548
01208463
TT
115492013-06-24 Tom Tromey <tromey@redhat.com>
11550
11551 * Makefile.in (version.c): Use bfd/version.h, common/version.in,
11552 create-version.sh.
11553 (version.o): Remove.
11554 * gdbreplay.c: Include version.h.
11555 (version, host_name): Don't declare.
11556 * server.h: Include version.h.
11557 (version, host_name): Don't declare.
11558
760256f9
PA
115592013-06-12 Pedro Alves <palves@redhat.com>
11560
11561 * linux-x86-low.c (linux_is_elf64): Delete global.
11562 (x86_siginfo_fixup): Replace reference to `linux_is_elf64' global
11563 with local linux_pid_exe_is_elf_64_file use.
11564
030031ee
PA
115652013-06-11 Pedro Alves <palves@redhat.com>
11566
11567 * linux-low.c (regset_disabled, disable_regset): New functions.
11568 (regsets_fetch_inferior_registers)
11569 (regsets_store_inferior_registers): Use them.
11570 (initialize_regsets_info); Don't allocate the disabled_regsets
11571 array here.
11572 * linux-low.h (struct regsets_info) <disabled_regsets>: Extend
11573 comment.
11574
5da6eb0a
PA
115752013-06-11 Pedro Alves <palves@redhat.com>
11576
11577 * linux-low.c (initialize_regsets_info): Use xcalloc instead of
11578 xmalloc.
11579
7e5aaa09
PA
115802013-06-11 Pedro Alves <palves@redhat.com>
11581
11582 * linux-x86-low.c (initialize_low_arch): Call
11583 init_registers_x32_avx_linux.
11584
d878444c
JK
115852013-06-09 Jan Kratochvil <jan.kratochvil@redhat.com>
11586
11587 Fix compatibility with Android Bionic.
11588 * linux-low.c (linux_qxfer_libraries_svr4): Ignore first entry even if
11589 it is not empty.
11590
3aee8918
PA
115912013-06-07 Pedro Alves <palves@redhat.com>
11592
5f2b57b5 11593 PR server/14823
3aee8918
PA
11594 * Makefile.in (OBS): Add tdesc.o.
11595 (IPA_OBJS): Add tdesc-ipa.o.
11596 (tdesc-ipa.o): New rule.
11597 * ax.c (gdb_eval_agent_expr): Adjust register_size call to new
11598 interface.
11599 * linux-low.c (new_inferior): Delete.
11600 (disabled_regsets, num_regsets): Delete.
11601 (linux_add_process): Adjust to set the new per-process
11602 new_inferior flag.
11603 (linux_detach_one_lwp): Adjust to call regcache_invalidate_thread.
11604 (linux_wait_for_lwp): Adjust. Only call arch_setup if the event
11605 was a stop. When calling arch_setup, switch the current inferior
11606 to the thread that got an event.
11607 (linux_resume_one_lwp): Adjust to call regcache_invalidate_thread.
11608 (regsets_fetch_inferior_registers)
11609 (regsets_store_inferior_registers): New regsets_info parameter.
11610 Adjust to use it.
11611 (linux_register_in_regsets): New regs_info parameter. Adjust to
11612 use it.
11613 (register_addr, fetch_register, store_register): New usrregs_info
11614 parameter. Adjust to use it.
11615 (usr_fetch_inferior_registers, usr_store_inferior_registers): New
11616 parameter regs_info. Adjust to use it.
11617 (linux_fetch_registers): Get the current inferior's regs_info, and
11618 adjust to use it.
11619 (linux_store_registers): Ditto.
11620 [HAVE_LINUX_REGSETS] (initialize_regsets_info): New.
11621 (initialize_low): Don't initialize the target_regsets here. Call
11622 initialize_low_arch.
11623 * linux-low.h (target_regsets): Delete declaration.
11624 (struct regsets_info): New.
11625 (struct usrregs_info): New.
11626 (struct regs_info): New.
11627 (struct process_info_private) <new_inferior>: New field.
11628 (struct linux_target_ops): Delete the num_regs, regmap, and
11629 regset_bitmap fields. New field regs_info.
11630 [HAVE_LINUX_REGSETS] (initialize_regsets_info): Declare.
11631 * i387-fp.c (num_xmm_registers): Delete.
11632 (i387_cache_to_fsave, i387_fsave_to_cache): Adjust find_regno
11633 calls to new interface.
11634 (i387_cache_to_fxsave, i387_cache_to_xsave, i387_fxsave_to_cache)
11635 (i387_xsave_to_cache): Adjust find_regno calls to new interface.
11636 Infer the number of xmm registers from the regcache's target
11637 description.
11638 * i387-fp.h (num_xmm_registers): Delete.
11639 * inferiors.c (add_thread): Don't install the thread's regcache
11640 here.
11641 * proc-service.c (gregset_info): Fetch the current inferior's
11642 regs_info. Adjust to use it.
11643 * regcache.c: Include tdesc.h.
11644 (register_bytes, reg_defs, num_registers)
11645 (gdbserver_expedite_regs): Delete.
11646 (get_thread_regcache): If the thread doesn't have a regcache yet,
11647 create one, instead of aborting gdbserver.
11648 (regcache_invalidate_one): Rename to ...
11649 (regcache_invalidate_thread): ... this.
11650 (regcache_invalidate_one): New.
11651 (regcache_invalidate): Only invalidate registers of the current
11652 process.
11653 (init_register_cache): Add target_desc parameter, and use it.
11654 (new_register_cache): Ditto. Assert the target description has a
11655 non zero registers_size.
11656 (regcache_cpy): Add assertions. Adjust.
11657 (realloc_register_cache, set_register_cache): Delete.
11658 (registers_to_string, registers_from_string): Adjust.
11659 (find_register_by_name, find_regno, find_register_by_number)
11660 (register_cache_size): Add target_desc parameter, and use it.
11661 (free_register_cache_thread, free_register_cache_thread_one)
11662 (regcache_release, register_cache_size): New.
11663 (register_size): Add target_desc parameter, and use it.
11664 (register_data, supply_register, supply_register_zeroed)
11665 (supply_regblock, supply_register_by_name, collect_register)
11666 (collect_register_as_string, collect_register_by_name): Adjust.
11667 * regcache.h (struct target_desc): Forward declare.
11668 (struct regcache) <tdesc>: New field.
11669 (init_register_cache, new_register_cache): Add target_desc
11670 parameter.
11671 (regcache_invalidate_thread): Declare.
11672 (regcache_invalidate_one): Delete declaration.
11673 (regcache_release): Declare.
11674 (find_register_by_number, register_cache_size, register_size)
11675 (find_regno): Add target_desc parameter.
11676 (gdbserver_expedite_regs, gdbserver_xmltarget): Delete
11677 declarations.
11678 * remote-utils.c: Include tdesc.h.
11679 (outreg, prepare_resume_reply): Adjust.
11680 * server.c: Include tdesc.h.
11681 (gdbserver_xmltarget): Delete declaration.
11682 (get_features_xml, process_serial_event): Adjust.
11683 * server.h [IN_PROCESS_AGENT] (struct target_desc): Forward
11684 declare.
11685 (struct process_info) <tdesc>: New field.
11686 (ipa_tdesc): Declare.
11687 * tdesc.c: New file.
11688 * tdesc.h: New file.
11689 * tracepoint.c: Include tdesc.h.
11690 [IN_PROCESS_AGENT] (ipa_tdesc): Define.
11691 (get_context_regcache): Adjust to pass ipa_tdesc down.
11692 (do_action_at_tracepoint): Adjust to get the register cache size
11693 from the context regcache's description.
11694 (traceframe_walk_blocks): Adjust to get the register cache size
11695 from the current trace frame's description.
11696 (traceframe_get_pc): Adjust to get current trace frame's
11697 description and pass it down.
11698 (gdb_collect): Adjust to get the register cache size from the
11699 IPA's description.
11700 * linux-amd64-ipa.c (tdesc_amd64_linux): Declare.
11701 (gdbserver_xmltarget): Delete.
11702 (initialize_low_tracepoint): Set the ipa's target description.
11703 * linux-i386-ipa.c (tdesc_i386_linux): Declare.
11704 (initialize_low_tracepoint): Set the ipa's target description.
11705 * linux-x86-low.c: Include tdesc.h.
11706 [__x86_64__] (is_64bit_tdesc): New.
11707 (ps_get_thread_area, x86_get_thread_area): Use it.
11708 (i386_cannot_store_register): Rename to ...
11709 (x86_cannot_store_register): ... this. Use is_64bit_tdesc.
11710 (i386_cannot_fetch_register): Rename to ...
11711 (x86_cannot_fetch_register): ... this. Use is_64bit_tdesc.
11712 (x86_fill_gregset, x86_store_gregset): Adjust register_size calls
11713 to new interface.
11714 (target_regsets): Rename to ...
11715 (x86_regsets): ... this.
11716 (x86_get_pc, x86_set_pc): Adjust register_size calls to new
11717 interface.
11718 (x86_siginfo_fixup): Use is_64bit_tdesc.
11719 [__x86_64__] (tdesc_amd64_linux, tdesc_amd64_avx_linux)
11720 (tdesc_x32_avx_linux, tdesc_x32_linux)
11721 (tdesc_i386_linux, tdesc_i386_mmx_linux, tdesc_i386_avx_linux):
11722 Declare.
11723 (x86_linux_update_xmltarget): Delete.
11724 (I386_LINUX_XSAVE_XCR0_OFFSET): Define.
11725 (have_ptrace_getfpxregs, have_ptrace_getregset): New.
11726 (AMD64_LINUX_USER64_CS): New.
11727 (x86_linux_read_description): New, based on
11728 x86_linux_update_xmltarget.
11729 (same_process_callback): New.
11730 (x86_arch_setup_process_callback): New.
11731 (x86_linux_update_xmltarget): New.
11732 (x86_regsets_info): New.
11733 (amd64_linux_regs_info): New.
11734 (i386_linux_usrregs_info): New.
11735 (i386_linux_regs_info): New.
11736 (x86_linux_regs_info): New.
11737 (x86_arch_setup): Reimplement.
11738 (x86_install_fast_tracepoint_jump_pad): Use is_64bit_tdesc.
11739 (x86_emit_ops): Ditto.
11740 (the_low_target): Adjust. Install x86_linux_regs_info,
11741 x86_cannot_fetch_register, and x86_cannot_store_register.
11742 (initialize_low_arch): New.
11743 * linux-ia64-low.c (tdesc_ia64): Declare.
11744 (ia64_fetch_register): Adjust.
11745 (ia64_usrregs_info, regs_info): New globals.
11746 (ia64_regs_info): New function.
11747 (the_low_target): Adjust.
11748 (initialize_low_arch): New function.
11749 * linux-sparc-low.c (tdesc_sparc64): Declare.
11750 (sparc_fill_gregset_to_stack, sparc_store_gregset_from_stack):
11751 Adjust.
11752 (sparc_arch_setup): New function.
11753 (sparc_regsets_info, sparc_usrregs_info, regs_info): New globals.
11754 (the_low_target): Adjust.
11755 (initialize_low_arch): New function.
11756 * linux-ppc-low.c (tdesc_powerpc_32l, tdesc_powerpc_altivec32l)
11757 (tdesc_powerpc_cell32l, tdesc_powerpc_vsx32l)
11758 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_altivec32l)
11759 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_e500l)
11760 (tdesc_powerpc_64l, tdesc_powerpc_altivec64l)
11761 (tdesc_powerpc_cell64l, tdesc_powerpc_vsx64l)
11762 (tdesc_powerpc_isa205_64l, tdesc_powerpc_isa205_altivec64l)
11763 (tdesc_powerpc_isa205_vsx64l): Declare.
11764 (ppc_cannot_store_register, ppc_collect_ptrace_register)
11765 (ppc_supply_ptrace_register, parse_spufs_run, ppc_get_pc)
11766 (ppc_set_pc, ppc_get_hwcap): Adjust.
11767 (ppc_usrregs_info): Forward declare.
11768 (!__powerpc64__) ppc_regmap_adjusted: New global.
11769 (ppc_arch_setup): Adjust to the current process'es target
11770 description.
11771 (ppc_fill_vsxregset, ppc_store_vsxregset, ppc_fill_vrregset)
11772 (ppc_store_vrregset, ppc_fill_evrregset, ppc_store_evrregse)
11773 (ppc_store_evrregset): Adjust.
11774 (target_regsets): Rename to ...
11775 (ppc_regsets): ... this, and make static.
11776 (ppc_usrregs_info, ppc_regsets_info, regs_info): New globals.
11777 (ppc_regs_info): New function.
11778 (the_low_target): Adjust.
11779 (initialize_low_arch): New function.
11780 * linux-s390-low.c (tdesc_s390_linux32, tdesc_s390_linux32v1)
11781 (tdesc_s390_linux32v2, tdesc_s390_linux64, tdesc_s390_linux64v1)
11782 (tdesc_s390_linux64v2, tdesc_s390x_linux64, tdesc_s390x_linux64v1)
11783 (tdesc_s390x_linux64v2): Declare.
11784 (s390_collect_ptrace_register, s390_supply_ptrace_register)
11785 (s390_fill_gregset, s390_store_last_break): Adjust.
11786 (target_regsets): Rename to ...
11787 (s390_regsets): ... this, and make static.
11788 (s390_get_pc, s390_set_pc): Adjust.
11789 (s390_get_hwcap): New target_desc parameter, and use it.
11790 [__s390x__] (have_hwcap_s390_high_gprs): New global.
11791 (s390_arch_setup): Adjust to set the current process'es target
11792 description. Don't adjust the regmap.
11793 (s390_usrregs_info, s390_regsets_info, regs_info): New globals.
11794 [__s390x__] (s390_usrregs_info_3264, s390_regsets_info_3264)
11795 (regs_info_3264): New globals.
11796 (s390_regs_info): New function.
11797 (the_low_target): Adjust.
11798 (initialize_low_arch): New function.
11799 * linux-mips-low.c (tdesc_mips_linux, tdesc_mips_dsp_linux)
11800 (tdesc_mips64_linux, tdesc_mips64_dsp_linux): Declare.
11801 [__mips64] (init_registers_mips_linux)
11802 (init_registers_mips_dsp_linux): Delete defines.
11803 [__mips64] (tdesc_mips_linux, tdesc_mips_dsp_linux): New defines.
11804 (have_dsp): New global.
11805 (mips_read_description): New, based on mips_arch_setup.
11806 (mips_arch_setup): Reimplement.
11807 (get_usrregs_info): New function.
11808 (mips_cannot_fetch_register, mips_cannot_store_register)
11809 (mips_get_pc, mips_set_pc, mips_fill_gregset, mips_store_gregset)
11810 (mips_fill_fpregset, mips_store_fpregset): Adjust.
11811 (target_regsets): Rename to ...
11812 (mips_regsets): ... this, and make static.
11813 (mips_regsets_info, mips_dsp_usrregs_info, mips_usrregs_info)
11814 (dsp_regs_info, regs_info): New globals.
11815 (mips_regs_info): New function.
11816 (the_low_target): Adjust.
11817 (initialize_low_arch): New function.
11818 * linux-arm-low.c (tdesc_arm, tdesc_arm_with_iwmmxt)
11819 (tdesc_arm_with_vfpv2, tdesc_arm_with_vfpv3, tdesc_arm_with_neon):
11820 Declare.
11821 (arm_fill_vfpregset, arm_store_vfpregset): Adjust.
11822 (arm_read_description): New, with bits factored from
11823 arm_arch_setup.
11824 (arm_arch_setup): Reimplement.
11825 (target_regsets): Rename to ...
11826 (arm_regsets): ... this, and make static.
11827 (arm_regsets_info, arm_usrregs_info, regs_info): New globals.
11828 (arm_regs_info): New function.
11829 (the_low_target): Adjust.
11830 (initialize_low_arch): New function.
11831 * linux-m68k-low.c (tdesc_m68k): Declare.
11832 (target_regsets): Rename to ...
11833 (m68k_regsets): ... this, and make static.
11834 (m68k_regsets_info, m68k_usrregs_info, regs_info): New globals.
11835 (m68k_regs_info): New function.
11836 (m68k_arch_setup): New function.
11837 (the_low_target): Adjust.
11838 (initialize_low_arch): New function.
11839 * linux-sh-low.c (tdesc_sharch): Declare.
11840 (target_regsets): Rename to ...
11841 (sh_regsets): ... this, and make static.
11842 (sh_regsets_info, sh_usrregs_info, regs_info): New globals.
11843 (sh_regs_info, sh_arch_setup): New functions.
11844 (the_low_target): Adjust.
11845 (initialize_low_arch): New function.
11846 * linux-bfin-low.c (tdesc_bfin): Declare.
11847 (bfin_arch_setup): New function.
11848 (bfin_usrregs_info, regs_info): New globals.
11849 (bfin_regs_info): New function.
11850 (the_low_target): Adjust.
11851 (initialize_low_arch): New function.
11852 * linux-cris-low.c (tdesc_cris): Declare.
11853 (cris_arch_setup): New function.
11854 (cris_usrregs_info, regs_info): New globals.
11855 (cris_regs_info): New function.
11856 (the_low_target): Adjust.
11857 (initialize_low_arch): New function.
11858 * linux-cris-low.c (tdesc_crisv32): Declare.
11859 (cris_arch_setup): New function.
11860 (cris_regsets_info, cris_usrregs_info, regs_info): New globals.
11861 (cris_regs_info): New function.
11862 (the_low_target): Adjust.
11863 (initialize_low_arch): New function.
11864 * linux-m32r-low.c (tdesc_m32r): Declare.
11865 (m32r_arch_setup): New function.
11866 (m32r_usrregs_info, regs_info): New globals.
11867 (m32r_regs_info): Adjust.
11868 (initialize_low_arch): New function.
11869 * linux-tic6x-low.c (tdesc_tic6x_c64xp_linux)
11870 (tdesc_tic6x_c64x_linux, tdesc_tic6x_c62x_linux): Declare.
11871 (tic6x_usrregs_info): Forward declare.
11872 (tic6x_read_description): New function, based on ...
11873 (tic6x_arch_setup): ... this. Reimplement.
11874 (target_regsets): Rename to ...
11875 (tic6x_regsets): ... this, and make static.
11876 (tic6x_regsets_info, tic6x_usrregs_info, regs_info): New globals.
11877 (tic6x_regs_info): New function.
11878 (the_low_target): Adjust.
11879 (initialize_low_arch): New function.
11880 * linux-xtensa-low.c (tdesc_xtensa): Declare.
11881 (xtensa_fill_gregset, xtensa_store_gregset): Adjust.
11882 (target_regsets): Rename to ...
11883 (xtensa_regsets): ... this, and make static.
11884 (xtensa_regsets_info, xtensa_usrregs_info, regs_info): New
11885 globals.
11886 (xtensa_arch_setup, xtensa_regs_info): New functions.
11887 (the_low_target): Adjust.
11888 (initialize_low_arch): New function.
11889 * linux-nios2-low.c (tdesc_nios2_linux): Declare.
11890 (nios2_arch_setup): Set the current process'es tdesc.
11891 (target_regsets): Rename to ...
11892 (nios2_regsets): ... this.
11893 (nios2_regsets_info, nios2_usrregs_info, regs_info): New globals.
11894 (nios2_regs_info): New function.
11895 (the_low_target): Adjust.
11896 (initialize_low_arch): New function.
a261b8f5
PA
11897 * linux-aarch64-low.c (tdesc_aarch64): Declare.
11898 (aarch64_arch_setup): Set the current process'es tdesc.
11899 (target_regsets): Rename to ...
11900 (aarch64_regsets): ... this.
11901 (aarch64_regsets_info, aarch64_usrregs_info, regs_info): New globals.
11902 (aarch64_regs_info): New function.
11903 (the_low_target): Adjust.
11904 (initialize_low_arch): New function.
3aee8918
PA
11905 * linux-tile-low.c (tdesc_tilegx, tdesc_tilegx32): Declare
11906 globals.
11907 (target_regsets): Rename to ...
11908 (tile_regsets): ... this.
11909 (tile_regsets_info, tile_usrregs_info, regs_info): New globals.
11910 (tile_regs_info): New function.
11911 (tile_arch_setup): Set the current process'es tdesc.
11912 (the_low_target): Adjust.
11913 (initialize_low_arch): New function.
11914 * spu-low.c (tdesc_spu): Declare.
11915 (spu_create_inferior, spu_attach): Set the new process'es tdesc.
11916 * win32-arm-low.c (tdesc_arm): Declare.
11917 (arm_arch_setup): New function.
11918 (the_low_target): Install arm_arch_setup instead of
11919 init_registers_arm.
11920 * win32-i386-low.c (tdesc_i386, tdesc_amd64): Declare.
11921 (init_windows_x86): Rename to ...
11922 (i386_arch_setup): ... this. Set `win32_tdesc'.
11923 (the_low_target): Adjust.
11924 * win32-low.c (win32_tdesc): New global.
11925 (child_add_thread): Don't create the thread cache here.
11926 (do_initial_child_stuff): Set the new process'es tdesc.
11927 * win32-low.h (struct target_desc): Forward declare.
11928 (win32_tdesc): Declare.
11929 * lynx-i386-low.c (tdesc_i386): Declare global.
11930 (lynx_i386_arch_setup): Set `lynx_tdesc'.
11931 * lynx-low.c (lynx_tdesc): New global.
11932 (lynx_add_process): Set the new process'es tdesc.
11933 * lynx-low.h (struct target_desc): Forward declare.
11934 (lynx_tdesc): Declare global.
11935 * lynx-ppc-low.c (tdesc_powerpc_32): Declare global.
11936 (lynx_ppc_arch_setup): Set `lynx_tdesc'.
11937 * nto-low.c (nto_tdesc): New global.
11938 (do_attach): Set the new process'es tdesc.
11939 * nto-low.h (struct target_desc): Forward declare.
11940 (nto_tdesc): Declare.
11941 * nto-x86-low.c (tdesc_i386): Declare.
11942 (nto_x86_arch_setup): Set `nto_tdesc'.
11943
b1fbec62
GB
119442013-06-04 Gary Benson <gbenson@redhat.com>
11945
11946 * server.c (handle_query): Add "augmented-libraries-svr4-read+"
11947 to qSupported response when appropriate.
11948 (handle_qxfer_libraries_svr4): Allow qXfer:libraries-svr4:read
11949 with nonzero-length annex.
11950 * linux-low.c (linux_qxfer_libraries_svr4): Parse and handle
11951 arguments supplied in annex.
11952
d1ec4ce7
DE
119532013-05-31 Doug Evans <dje@google.com>
11954
ac44adcb 11955 PR server/15594
d1ec4ce7
DE
11956 * linux-x86-low.c (ps_get_thread_area): Properly extend address to
11957 64 bits in 64-cross-32 environment.
11958
9b25f2d3
PA
119592013-05-28 Pedro Alves <palves@redhat.com>
11960
11961 * Makefile.in (clean): Remove reference to aarch64-without-fpu.c.
11962 (aarch64-without-fpu.c): Delete rule.
11963 * configure.srv (aarch64*-*-linux*): Remove references to
11964 aarch64-without-fpu.o and aarch64-without-fpu.xml.
11965 * linux-aarch64-low.c (init_registers_aarch64_without_fpu): Remove
11966 declaration.
11967
6740dc9c
PA
119682013-05-24 Pedro Alves <palves@redhat.com>
11969
11970 * server.c (handle_v_cont) <vCont;r>: Use unpack_varlen_hex
11971 instead of strchr/decode_address. Error if the range isn't split
11972 with a ','. Don't assume there's be a ':' in the action.
11973
c2d6af84
PA
119742013-05-23 Yao Qi <yao@codesourcery.com>
11975 Pedro Alves <palves@redhat.com>
11976
11977 * linux-low.c (lwp_in_step_range): New function.
11978 (linux_wait_1): If the thread was range stepping and stopped
11979 outside the stepping range, report the stop to GDB. Otherwise,
11980 continue stepping. Add range stepping debug output.
11981 (linux_set_resume_request): Copy the step range from the resume
11982 request to the lwp.
11983 (linux_supports_range_stepping): New.
11984 (linux_target_ops) <supports_range_stepping>: Set to
11985 linux_supports_range_stepping.
11986 * linux-low.h (struct linux_target_ops)
11987 <supports_range_stepping>: New field.
11988 (struct lwp_info) <step_range_start, step_range_end>: New fields.
11989 * linux-x86-low.c (x86_supports_range_stepping): New.
11990 (the_low_target) <supports_range_stepping>: Set to
11991 x86_supports_range_stepping.
11992 * server.c (handle_v_cont): Handle 'r' action.
11993 (handle_v_requests): Append ";r" if the target supports range
11994 stepping.
11995 * target.h (struct thread_resume) <step_range_start,
11996 step_range_end>: New fields.
11997 (struct target_ops) <supports_range_stepping>:
11998 New field.
11999 (target_supports_range_stepping): New macro.
12000
58794e1a
JB
120012013-05-17 Joel Brobecker <brobecker@adacore.com>
12002
12003 * lynx-low.c (lynx_resume): Fix null_ptid/minus_one_ptid
12004 confusion in comment.
12005
d631c5a7
JB
120062013-05-17 Joel Brobecker <brobecker@adacore.com>
12007
12008 * lynx-low.c (struct process_info_private): New type.
12009 (lynx_add_process): New function.
12010 (lynx_create_inferior, lynx_attach): Replace calls to
12011 add_process by calls to lynx_add_process.
12012 (lynx_resume): If PTID is null, then try using
12013 current_process()->private->last_wait_event_ptid.
12014 Add comments.
12015 (lynx_clear_inferiors): Delete. The contents of that function
12016 has been inlined in lynx_mourn;
12017 (lynx_wait_1): Save the ptid in the process's private data.
12018 (lynx_mourn): Free the process' private data. Replace call
12019 to lynx_clear_inferiors by call to clear_inferiors.
12020
96f7a20f
YQ
120212013-05-17 Yao Qi <yao@codesourcery.com>
12022
12023 * i386-low.c (i386_length_and_rw_bits): Move the comment to
12024 the right place.
12025
db0dfaa0
LM
120262013-05-16 Luis Machado <lgustavo@codesourcery.com>
12027
12028 * linux-low.c: Move definition checks upwards for PT_TEXT_ADDR,
12029 PT_DATA_ADDR and PT_TEXT_END_ADDR. Update comments.
12030 (linux_read_offsets): Remove PT_TEXT_ADDR, PT_DATA_ADDR and
12031 PT_TEXT_END_ADDR guards. Update comments.
12032 (linux_target_op) <read_offsets>: Conditionally define to
12033 linux_read_offsets if the target is UCLIBC and if it defines
12034 PT_TEXT_ADDR, PT_DATA_ADDR and PT_TEXT_END_ADDR.
12035
68f5f838
SL
120362013-05-06 Sandra Loosemore <sandra@codesourcery.com>
12037 Andrew Jenner <andrew@codesourcery.com>
12038
12039 * Makefile.in (SFILES): Add linux-nios2-low.c.
12040 (clean): Add action to delete nios2-linux.c.
12041 (nios2-linux.c): New rule.
12042 * configure.srv: Add nios2*-*-linux*.
12043 * linux-nios2-low.c: New.
12044
1ebff1fd
HAQ
120452013-05-03 Hafiz Abid Qadeer <abidh@codesourcery.com>
12046
12047 * tracepoint.c (cmd_qtinit): Call 'stop_tracing'.
12048
f6150862
HZ
120492013-04-25 Hui Zhu <hui@codesourcery.com>
12050
12051 PR gdb/15186
f6150862
HZ
12052 * ax.c (ax_printf): Add fflush.
12053
614c279d
TT
120542013-04-22 Tom Tromey <tromey@redhat.com>
12055
12056 * Makefile.in (SFILES): Add filestuff.c.
12057 (OBS): Add filestuff.o.
12058 (filestuff.o): New target.
12059 * config.in, configure: Rebuild.
12060 * configure.ac: Check for fdwalk, pipe2.
12061
7d4e5717
PA
120622013-04-17 Pedro Alves <palves@redhat.com>
12063
12064 * configure.ac (USE_THREAD_DB): Delete variable.
12065 (if test "$srv_linux_thread_db" = "yes"): AC_DEFINE USE_THREAD_DB.
12066 Don't AC_SUBST USE_THREAD_DB.
12067 * Makefile.in (INTERNAL_CFLAGS): Remove @USE_THREAD_DB@.
12068 * config.in, configure: Regenerate.
12069
d5c93e41
PA
120702013-04-16 Pedro Alves <palves@redhat.com>
12071
12072 * linux-low.h (struct lwp_info) <thread_known>: Move under
12073 the USE_THREAD_DB #ifdef.
12074
04f5fe89
PA
120752013-04-16 Pedro Alves <palves@redhat.com>
12076
12077 * Makefile.in (INTERNAL_CFLAGS): Add @USE_THREAD_DB@.
12078 (linux-low.o): Delete rule.
12079 * linux-low.h: Always include "gdb_thread_db.h" instead of
12080 conditionally including thread_db.h.
12081 (struct lwp_info) <th>: Guard with #ifdef USE_THREAD_DB instead of
12082 HAVE_THREAD_DB_H.
12083
480b27bf
JK
120842013-04-07 Jan Kratochvil <jan.kratochvil@redhat.com>
12085
12086 * Makefile.in (install-only): Fix make install regression.
12087
43662968
JK
120882013-04-05 Jan Kratochvil <jan.kratochvil@redhat.com>
12089
12090 Convert man pages to texinfo, new gdbinit.5 texinfo page.
12091 * Makefile.in (install-only): Remove $(man1dir) and gdbserver.1
12092 installation.
12093 * gdbserver.1: Remove.
12094
3e74e146
PA
120952013-03-22 Pedro Alves <palves@redhat.com>
12096
12097 * linux-low.c (handle_extended_wait): Don't call
12098 linux_enable_event_reporting.
12099
a8347a2a
TT
121002013-03-15 Tony Theodore <tonyt@logyst.com>
12101
12102 PR build/9098:
12103 * Makefile.in (SHELL): Use @SHELL@.
12104
eeb56fa7
SDJ
121052013-03-14 Sergio Durigan Junior <sergiodj@redhat.com>
12106
12107 * tracepoint.c (cmd_qtv): Initialize `val' with zero, silencing
12108 compiler warning.
12109
4fa7e2ff
JB
121102013-03-13 Joel Brobecker <brobecker@adacore.com>
12111
12112 * linux-low.c (linux_target_ops) [!HAVE_LINUX_BTRACE]:
12113 Remove extraneous NULL element.
12114
8ddb1965
YQ
121152013-03-13 Yao Qi <yao@codesourcery.com>
12116
12117 * tracepoint.c (traceframe_read_tsv): Look for the last matched
12118 'V' block in trace frame.
12119
9accd112
MM
121202013-03-11 Markus Metzger <markus.t.metzger@intel.com>
12121
12122 * target.h (struct target_ops): Add btrace ops.
12123 (target_supports_btrace): New macro.
12124 (target_enable_btrace): New macro.
12125 (target_disable_btrace): New macro.
12126 (target_read_btrace): New macro.
12127 * gdbthread.h (struct thread_info): Add btrace field.
12128 * server.c: Include btrace-common.h.
12129 (handle_btrace_general_set): New function.
12130 (handle_btrace_enable): New function.
12131 (handle_btrace_disable): New function.
12132 (handle_general_set): Call handle_btrace_general_set.
12133 (handle_qxfer_btrace): New function.
12134 (struct qxfer qxfer_packets[]): Add btrace entry.
12135 * inferiors.c (remove_thread): Disable btrace.
12136 * linux-low: Include linux-btrace.h.
12137 (linux_low_enable_btrace): New function.
12138 (linux_low_read_btrace): New function.
12139 (linux_target_ops): Add btrace ops.
12140 * configure.srv (i[34567]86-*-linux*): Add linux-btrace.o.
12141 Add srv_linux_btrace=yes.
12142 (x86_64-*-linux*): Add linux-btrace.o.
12143 Add srv_linux_btrace=yes.
12144 * configure.ac: Define HAVE_LINUX_BTRACE.
12145 * config.in: Regenerated.
12146 * configure: Regenerated.
12147
5cc22e4c
MM
121482013-03-11 Markus Metzger <markus.t.metzger@intel.com>
12149
12150 * server.c (handle_qxfer): Preserve error message if -3 is
12151 returned.
12152 (qxfer): Document the -3 return value.
12153
7c97f91e
MM
121542013-03-11 Markus Metzger <markus.t.metzger@intel.com>
12155
12156 * Makefile.in (SFILES): Add $(srcdir)/common/linux-btrace.c.
12157 (linux_btrace_h): New variable.
12158 (linux-btrace.o): New rule.
12159
be9a119c 121602013-03-08 Stan Shebs <stan@codesourcery.com>
f6f899bf
HAQ
12161 Hafiz Abid Qadeer <abidh@codesourcery.com>
12162
12163 * tracepoint.c (trace_buffer_size): New global.
12164 (DEFAULT_TRACE_BUFFER_SIZE): New define.
12165 (init_trace_buffer): Change to one-argument function. Allocate
12166 trace buffer memory.
12167 (handle_tracepoint_general_set): Call cmd_bigqtbuffer_size to
12168 handle QTBuffer:size packet.
12169 (cmd_bigqtbuffer_size): New function.
12170 (initialize_tracepoint): Call init_trace_buffer with
12171 DEFAULT_TRACE_BUFFER_SIZE.
12172 * server.c (handle_query): Add QTBuffer:size in the
12173 supported packets.
12174
e64f7499
YQ
121752013-03-07 Yao Qi <yao@codesourcery.com>
12176
12177 * tracepoint.c (cur_action, cur_step_action): Make them unsigned.
12178 (cmd_qtfp): Initialize cur_action and cur_step_action 0 instead
12179 of -1.
12180 (cmd_qtsp): Adjust condition. Do post increment.
12181 Set cur_action and cur_step_action back to 0.
12182
f0ae6fc3
PA
121832013-03-07 Jeremy Bennett <jeremy.bennett@embecosm.com>
12184
12185 PR server/15236
12186 * linux-low.c (linux_write_memory): Return early success if LEN is
12187 zero.
12188
b5b0b0af
CV
121892013-03-05 Corinna Vinschen <vinschen@redhat.de>
12190
334ad4a8 12191 * configure.srv: Add x86_64-*-cygwin* as target.
b5b0b0af 12192
589bc927
TT
121932013-02-28 Tom Tromey <tromey@redhat.com>
12194
12195 * configure.ac: Invoke AC_SYS_LARGEFILE.
12196 * configure, config.in: Rebuild.
12197
dfe07582
CV
121982013-02-28 Corinna Vinschen <vinschen@redhat.com>
12199
12200 * win32-low.c: Throughout, fix format strings and casts of
12201 printf-like functions to avoid type related warnings on all
12202 platforms.
12203 (get_child_debug_event): Print dwDebugEventCode as hex since
12204 that's how it's usually documented.
12205
736cd585
YQ
122062013-02-28 Yao Qi <yao@codesourcery.com>
12207
12208 * tracepoint.c (cmd_qtbuffer): Call phex_nz instead of
12209 pulongest.
12210
e1f58301
JW
122112013-02-27 Jiong Wang <jiwang@tilera.com>
12212
12213 * Makefile.in (clean): Remove reg-tilegx.c, reg-tilegx32.c.
12214 (reg-tilegx32.c): New rule.
12215 * configure.srv (tilegx-*-linux*): Add reg-tilegx32.o to srv_regobj.
12216 * linux-tile-low.c (tile_arch_setup): New function. Invoke
12217 different register info initializer according to elf class.
12218 (init_registers_tilgx32): New function. The tilegx32 register info
12219 initializer.
12220 (tile_fill_gregset): Use "uint_reg_t" to represent register size.
12221 (tile_store_gregset): Likewise.
12222
d171ca78
YQ
122232013-02-27 Yao Qi <yao@codesourcery.com>
12224
12225 * server.c (process_point_options): Print debug message when
12226 debug_threads is true.
12227
282bbdf3
YQ
122282013-02-26 Yao Qi <yao@codesourcery.com>
12229
12230 * tracepoint.c (cmd_qtbuffer): Don't set '\0' in OWN_BUF.
12231
aca22551
PA
122322013-02-19 Pedro Alves <palves@redhat.com>
12233 Kai Tietz <ktietz@redhat.com>
12234
12235 PR gdb/15161
12236
12237 * server.c (handle_query) <CRC check>: Use unpack_varlen_hex
12238 instead of strtoul to extract address from packet.
12239 (process_serial_event) <'z'>: Likewise.
12240
4f3cee1c
YQ
122412013-02-18 Yao Qi <yao@codesourcery.com>
12242
12243 * linux-bfin-low.c (the_low_target): Use NULL instead of 0.
12244
8e1d55a3
PA
122452013-02-14 Pedro Alves <palves@redhat.com>
12246
12247 Plug memory leak.
12248
12249 * tracepoint.c (cmd_qtnotes): Free TRACING_USER_NAME,
12250 TRACING_NOTES and TRACING_STOP_NOTE before clobbering.
12251
458820da
PA
122522013-02-14 Pedro Alves <palves@redhat.com>
12253
12254 * tracepoint.c (cmd_qtdpsrc): Use savestring.
12255
baea0dae
PA
122562013-02-14 Pedro Alves <palves@redhat.com>
12257
12258 * tracepoint.c (save_string): Delete.
12259 (add_tracepoint_action): Use savestring instead of save_string.
12260
0b1afbb3
PA
122612013-02-12 Pedro Alves <palves@redhat.com>
12262
12263 * linux-xtensa-low.c: Ditto.
12264 * xtensa-xtregs.c: Ditto.
12265
8a4ac37e
PA
122662013-02-12 Sanimir Agovic <sanimir.agovic@intel.com>
12267
12268 * thread-db.c (thread_db_get_tls_address): NULL pointer check
12269 thread_db.
12270
148de6bb
MS
122712013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
12272
12273 * linux-aarch64-low.c (aarch64_arch_setup): Clamp
12274 aarch64_num_wp_regs and aarch64_num_bp_regs to
12275 AARCH64_HWP_MAX_NUM and AARCH64_HBP_MAX_NUM respectively.
12276
55fac6e0
MS
122772013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
12278
12279 * linux-aarch64-low.c (ps_get_thread_area): Replace
12280 PTRACE_GET_THREAD_AREA with PTRACE_GETREGSET.
12281
176eb98c
MS
122822013-02-04 Jim MacArthur <jim.macarthur@arm.com>
12283 Marcus Shawcroft <marcus.shawcroft@arm.com>
12284 Nigel Stephens <nigel.stephens@arm.com>
12285 Yufeng Zhang <yufeng.zhang@arm.com>
12286
12287 * Makefile.in (clean): Remove aarch64.c and aarch64-without-fpu.c.
12288 (aarch64.c, aarch64-without-fpu.c): New targets.
12289 * configure.srv (aarch64*-*-linux*): New.
12290 * linux-aarch64-low.c: New file.
12291
56f7af9c
MS
122922013-02-04 Marcus Shawcroft <marcus.shawcroft@arm.com>
12293
43aaf8b6 12294 * linux-low.c (handle_extended_wait, linux_create_inferior)
56f7af9c
MS
12295 (linux_attach_lwp_1, linux_kill_one_lwp, linux_attach_one_lwp)
12296 (dequeue_one_deferred_signal, linux_resume_one_thread)
12297 (fetch_register, linux_write_memory, linux_enable_event_reporting)
12298 (linux_tracefork_grandchild, linux_test_for_tracefork)
12299 (linux_read_offsets, linux_xfer_siginfo, linux_xfer_siginfo): Add
12300 PTRACE_ARG3_TYPE and PTRACE_ARG4_TYPE cast to ptrace arguments
12301 where the argument is 0.
12302
60f662b0
YQ
123032013-01-25 Yao Qi <yao@codesourcery.com>
12304
12305 * event-loop.c: Include "queue.h".
12306 (gdb_event_p): New typedef.
12307 (struct gdb_event) <next_event>: Remove.
12308 (event_queue): Change to QUEUE(gdb_event_p).
12309 (async_queue_event): Remove.
12310 (gdb_event_xfree): New.
12311 (initialize_event_loop): New.
12312 (process_event): Use API from QUEUE.
12313 (wait_for_event): Likewise.
12314 * server.c (main): Call initialize_event_loop.
12315 * server.h (initialize_event_loop): Declare.
12316
5ae4861a
YQ
123172013-01-18 Yao Qi <yao@codesourcery.com>
12318
12319 * ax.h (struct eval_agent_expr_context): New.
12320 (gdb_eval_agent_expr): Update declaration.
12321 * ax.c (gdb_eval_agent_expr): Remove argument REGCACHE and
12322 TFRAME. Add new argument CTX.
12323 * server.h (struct eval_agent_expr_context): Declare.
12324 (agent_mem_read, agent_tsv_read): Update declaration.
12325 (agent_mem_read_string): Likewise.
12326 * tracepoint.c (eval_tracepoint_agent_expr): Remove.
12327 (add_traceframe_block): Add new argument TPOINT.
12328 Increase TPOINT->traceframe_usage.
12329 (do_action_at_tracepoint): Call gdb_eval_agent_expr instead of
12330 eval_tracepoint_agent_expr.
12331 (condition_true_at_tracepoint): Likewise.
12332 (agent_mem_read): Remove argument TFRAME. Add argument CTX.
12333 (agent_mem_read_string, agent_tsv_read): Likewise.
12334
85e00e85
YQ
123352013-01-16 Yao Qi <yao@codesourcery.com>
12336
12337 * linux-low.c (linux_resume_one_lwp): Don't check
12338 'lwp->bp_reinsert != 0'.
12339
4039cf45
JB
123402013-01-07 Joel Brobecker <brobecker@adacore.com>
12341 Pedro Alves <palves@redhat.com>
12342
12343 * lynx-low.c (ptrace_request_to_str): Define a temporary
12344 macro and use it to simplify this function's implementation.
12345
9044dee2
JB
123462013-01-07 Joel Brobecker <brobecker@adacore.com>
12347
12348 * lynx-low.c (lynx_resume): Call perror_with_name if lynx_ptrace
12349 sets errno.
12350
e6352c8f
JB
123512013-01-07 Joel Brobecker <brobecker@adacore.com>
12352
12353 * configure.srv (i[34567]86-*-lynxos*): Set srv_xmlfiles.
12354
50681a27
JB
123552013-01-07 Joel Brobecker <brobecker@adacore.com>
12356
12357 * configure.srv (powerpc-*-lynxos*): Set srv_xmlfiles.
12358
3f6e77ef
JB
123592013-01-07 Joel Brobecker <brobecker@adacore.com>
12360
12361 * lynx-low.c (lynx_resume): Use the resume_info parameter
12362 to determine the ptid for the lynx_ptrace call, unless
12363 it is equal to minus_one_ptid, in which case we use the
12364 ptid of the current_inferior.
12365 (lynx_wait_1): After having received a thread create/exit
12366 event, resume the inferior's execution using the signaling
12367 thread's ptid, rather than the old ptid.
12368
7fda33ae
JB
123692013-01-07 Joel Brobecker <brobecker@adacore.com>
12370
12371 * lynx-low.c (lynx_resume): Delete variable ret.
12372
b9786c74
JB
123732013-01-01 Joel Brobecker <brobecker@adacore.com>
12374
12375 * gdbreplay.c (gdbreplay_version): Update copyright year.
12376 * server.c (gdbserver_version): Likewise.
12377
8b93d60f
JB
123782012-12-17 Joel Brobecker <brobecker@adacore.com>
12379
12380 * lynx-low.c (lynx_wait_1): Add debug trace before adding
12381 new thread.
12382
037335a7
JB
123832012-12-17 Joel Brobecker <brobecker@adacore.com>
12384
12385 * lynx-low.c (ptrace_request_to_str): Add handling for
12386 PTRACE_GETTRACESIG.
12387
52d4cbd8
JB
123882012-12-17 Joel Brobecker <brobecker@adacore.com>
12389
12390 * lynx-low.c (lynx_attach): Delete variable new_process.
12391
ab8f6ca9
JB
123922012-12-17 Joel Brobecker <brobecker@adacore.com>
12393
12394 * lynx-low.c (lynx_create_inferior): Delete variable
12395 new_process.
12396
78cbc024
JB
123972012-12-17 Joel Brobecker <brobecker@adacore.com>
12398
12399 * lynx-low.c (ptrace_request_to_str): Do not handle
12400 PTRACE_GETTHREADLIST if this macro does not exist.
12401
14a00470
YQ
124022012-12-15 Yao Qi <yao@codesourcery.com>
12403
12404 * Makefile.in (OBS): Add notif.o.
12405 * notif.c, notif.h: New.
12406 * server.c: Include "notif.h".
12407 (struct vstop_notif) <next>: Remove.
12408 <base>: New field.
12409 (queue_stop_reply): Update.
12410 (push_event, send_next_stop_reply): Remove.
12411 (discard_queued_stop_replies): Update.
12412 (notif_stop): New variable.
12413 (handle_v_stopped): Remove.
12414 (handle_v_requests): Don't call handle_v_stopped. Call
12415 handle_ack_notif instead.
12416 (queue_stop_reply_callback): Call notif_event_enque instead
12417 of queue_stop_reply.
12418 (handle_status): Don't call send_next_stop_reply, call
12419 notif_write_event instead.
12420 (kill_inferior_callback): Likewise.
12421 (detach_or_kill_inferior_callback): Likewise.
12422 (main): Call initialize_notif.
12423 (process_serial_event): Call QUEUE_is_empty.
12424 (handle_target_event): Call notif_push instead of push event.
12425 * server.h (push_event): Remove declaration.
12426
61c125b9
TT
124272012-12-10 Tom Tromey <tromey@redhat.com>
12428
12429 * Makefile.in (DEPMODE, DEPDIR, depcomp, COMPILE.pre)
12430 (COMPILE.post, COMPILE, POSTCOMPILE, IPAGENT_COMPILE): New
12431 macros.
12432 (.c.o): Rewrite.
12433 (ax-ipa.o, tracepoint-ipa.o, utils-ipa.o, format-ipa.o)
12434 (common-utils-ipa.o, remote-utils-ipa.o, regcache-ipa.o)
12435 (i386-linux-ipa.o, linux-i386-ipa.o, linux-amd64-ipa.o)
12436 (amd64-linux-ipa.o, ax.o): Rewrite.
12437 (event-loop.o, hostio.o, hostio-errno.o, inferiors.o, mem-break.o)
12438 (proc-service.o, regcache.o, remote-utils.o, server.o, target.o)
12439 (thread-db.o, tracepoint.o, utils.o, gdbreplay.o, dll.o): Remove.
12440 (signals.o, linux-procfs.o, linux-ptrace.o, common-utils.o, vec.o)
12441 (gdb_vecs.o, xml-utils.o, linux-osdata.o, ptid.o, buffer.o)
12442 (format.o, agent.o, vasprintf.o, vsnprintf.o): Rewrite.
12443 (i386-low.o, i387-fp.o, linux-low.o, linux-arm-low.o)
12444 (linux-bfin-low.o, linux-cris-low.o, linux-crisv32-low.o)
12445 (linux-ia64-low.o, linux-m32r-low.o, linux-mips-low.o)
12446 (linux-ppc-low.o, linux-s390-low.o, linux-sh-low.o)
12447 (linux-tic6x-low.o, linux-x86-low.o, linux-xtensa-low.o)
12448 (linux-tile-low.o, lynx-low.o, lynx-ppc-low.o, nto-low.o)
12449 (nto-x86-low.o, linux-low.o, win32-low.o, win32-arm-low.o)
12450 (win32-i386-low.o, spu-low.o, reg-arm.o, arm-with-iwmmxt.o)
12451 (arm-with-vfpv2.o, arm-with-vfpv3.o, arm-with-neon.o, reg-bfin.o)
12452 (reg-cris.o, reg-crisv32.o, i386.o, i386-linux.o, i386-avx.o)
12453 (i386-avx-linux.o, i386-mmx.o, i386-mmx-linux.o, reg-ia64.o)
12454 (reg-m32r.o, reg-m68k.o, reg-cf.o, mips-linux.o, mips-dsp-linux.o)
12455 (mips64-linux.o, mips64-dsp-linux.o, powerpc-32.o, powerpc-32l.o)
12456 (powerpc-altivec32l.o, powerpc-cell32l.o, powerpc-vsx32l.o)
12457 (powerpc-isa205-32l.o, powerpc-isa205-altivec32l.o)
12458 (powerpc-isa205-vsx32l.o, powerpc-e500l.o, powerpc-64l.o)
12459 (powerpc-altivec64l.o, powerpc-cell64l.o, powerpc-vsx64l.o)
12460 (powerpc-isa205-64l.o, powerpc-isa205-altivec64l.o)
12461 (powerpc-isa205-vsx64l.o, s390-linux32.o, s390-linux32v1.o)
12462 (s390-linux32v2.o, s390-linux64.o, s390-linux64v1.o)
12463 (s390-linux64v2.o, s390x-linux64.o, s390x-linux64v1.o)
12464 (s390x-linux64v2.o, tic6x-c64xp-linux.o, tic6x-c64x-linux.o)
12465 (tic6x-c62x-linux.o, reg-sh.o, reg-sparc64.o, reg-spu.o, amd64.o)
12466 (amd64-linux.o, amd64-avx.o, amd64-avx-linux.o, x32.o)
12467 (x32-linux.o, x32-avx.o, x32-avx-linux.o, reg-xtensa.o)
12468 (reg-tilegx.o): Remove.
12469 (all_object_files): New macro.
12470 Include .deps files.
12471 * aclocal.m4, configure: Rebuild.
12472 * acinclude.m4: Include depstand.m4, lead-dot.m4.
12473 * configure.ac: Invoke ZW_CREATE_DEPDIR,
12474 ZW_PROG_COMPILER_DEPENDENCIES. Compute GMAKE condition.
12475
e90e9ad9
TT
124762012-12-05 Tom Tromey <tromey@redhat.com>
12477
12478 PR gdb/14917:
12479 * server.h (current_insn_ptr, emit_error): Declare 'extern'.
12480
02d403bf 124812012-11-28 Markus Metzger <markus.t.metzger@intel.com>
945bf713
MM
12482
12483 * configure.ac: Check for linux/perf_event.h.
12484 * config.in: Regenerated.
12485 * configure: Regenerated.
12486
0270a750
PA
124872012-11-26 Maxime Villard <rustyBSD@gmx.fr>
12488
12489 * hostio.c (handle_readlink): Decrease buffer size
12490 parameter passed to readlink by one byte.
12491
8c29b58e
YQ
124922012-11-26 Yao Qi <yao@codesourcery.com>
12493
12494 * configure.ac (build_warnings): Append '-Wempty-body'.
12495 * configure: Regenerated.
12496 * linux-low.c (linux_create_inferior): Use braces for empty 'if'
12497 body.
12498
8bdce1ff
PM
124992012-11-15 Pierre Muller <muller@sourceware.org>
12500
12501 * configure.ac (AC_CHECK_HEADERS): Add wait.h header.
12502 * config.in: Regenerate.
12503 * configure: Regenerate.
12504 * linux-low.c: Use "gdb_stat.h" header instead of <sys/stat.h> header.
12505 Use "gdb_wait.h" header instead of <sys/wait.h> header.
12506 * lynx-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
12507 * remote-utils.c: Use "gdb_stat.h" header instead of <sys/stat.h>
12508 header.
12509 * server.c: Remove HAVE_WAIT_H conditional. Use "gdb_wait.h" header
12510 instead of <sys/wait.h> header.
12511 * spu-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
12512
02d403bf 125132012-11-13 Markus Metzger <markus.t.metzger@intel.com>
3ba6ad0f
MM
12514
12515 * Makefile.in: (INTERNAL_CFLAGS): Add -DGDBSERVER
12516 (various make rules): Remove -DGDBSERVER
12517
fbd5db48
YQ
125182012-11-09 Yao Qi <yao@codesourcery.com>
12519
12520 * spu-low.c (current_ptid): Move it to ..
12521 * gdbthread.h: ... here. New.
12522 * remote-utils.c (read_ptid): Use macro 'current_ptid'.
12523 * server.c (myresume, process_serial_event): Likewise.
12524 * thread-db.c (thread_db_find_new_threads): Likewise.
12525 * tracepoint.c (run_inferior_command): Likewise.
12526
b3dc46ff
AB
125272012-10-01 Andrew Burgess <aburgess@broadcom.com>
12528
12529 * server.c (handle_search_memory_1): Include access length in
12530 warning message.
12531
07c04788
HPN
125322012-09-05 Michael Brandt <michael.brandt@axis.com>
12533
12534 * linux-crisv32-low.c: Fix compile errors.
12535
918d227b
YQ
125362012-09-04 Yao Qi <yao@codesourcery.com>
12537
12538 * tracepoint.c (cmd_qtsv): Adjust debug message.
12539 Don't check CUR_TPOINT.
12540
18c1b81a
YQ
125412012-08-28 Yao Qi <yao@codesourcery.com>
12542
12543 * ax.c, tracepoint.c: Replace ATTR_FORMAT with ATTRIBUTE_PRINTF.
12544 * server.h: Include 'libiberty.h' and 'ansidecl.h'.
12545 (ATTR_NORETURN, ATTR_FORMAT, ATTR_MALLOC): Remove.
12546 Remove declarations of xmalloc, xreallloc, xstrdup and
12547 freeargv.
12548 * Makefile.in (libiberty_h): New.
12549 (server_h): Append dependencies 'libiberty.h' and 'ansidecl.h'.
12550 (linux-bfin-low.o): Append dependency 'libiberty.h'.
12551
dc82f37b
YQ
125522012-08-23 Yao Qi <yao@codesourcery.com>
12553
12554 * server.h: Remove declaration of 'xsnprintf'.
12555
406b1477
KS
125562012-08-22 Keith Seitz <keiths@redhat.com>
12557
12558 * server.h: Include build-gnulib-gbserver/config.h.
12559 * gdbreplay.c: Likewise.
12560
e6712ff1
DE
125612012-08-08 Doug Evans <dje@google.com>
12562
12563 * Makefile.in (SFILES): Add gdb_vecs.c.
12564 (OBS): Add gdb_vecs.o.
12565 (gdb_vecs_h, host_defs_h): New variables.
12566 (thread-db.o): Add $(gdb_vecs_h) dependency.
12567 (gdb_vecs.o): New rule.
12568 * thread-db.c: #include "gdb_vecs.h".
12569 (thread_db_load_search): Use a vector to iterate over path elements.
12570 Handle text appearing after "$pdir".
12571
12572 * configure.ac: Add check for strstr.
12573 * config.in: Regenerate.
12574 * configure: Regenerate.
12575
7c3270ae
UW
125762012-08-02 Ulrich Weigand <ulrich.weigand@linaro.org>
12577
12578 * hostio.c (handle_pread): If pread fails, fall back to attempting
12579 lseek/read.
12580 (handle_pwrite): Likewise for pwrite.
12581
b62e2b27
UW
125822012-08-01 Ulrich Weigand <ulrich.weigand@linaro.org>
12583
12584 * linux-arm-low.c (arm_linux_hw_point_initialize): Distinguish
12585 between unsupported TYPE and unimplementable ADDR/LEN combination.
12586 (arm_insert_point): Act on new return value.
12587
78a99e91
PA
125882012-07-31 Pedro Alves <palves@redhat.com>
12589
12590 * server.c (process_point_options): Only skip tokens if we find
12591 one that is unrecognized. Don't treat 'X' specially while
12592 skipping unrecognized tokens.
12593
fcf303ab
UW
125942012-07-30 Ulrich Weigand <ulrich.weigand@linaro.org>
12595
12596 * linux-arm-low.c (arm_linux_hw_point_initialize): Do not attempt
12597 to 4-byte-align HW breakpoint addresses for Thumb.
12598
7255706c
YQ
125992012-07-27 Yao Qi <yao@codesourcery.com>
12600
12601 PR remote/14161.
12602
12603 * server.h: Declare gdb_agent_about_to_close.
12604 * target.c (kill_inferior): Include "agent.h".
12605 New. Send command 'kill'.
12606 * target.h (kill_inferior): Removed macro.
12607 * tracepoint.c (gdb_agent_about_to_close): New.
12608 (gdb_agent_helper_thread): Handle command 'close'.
12609 Wait endlessly until the inferior stops.
12610 Install gdb_agent_remove_socket to atexit hook.
12611 (agent_socket_name): New static variable.
12612 (gdb_agent_socket_init): Replace local variable 'name' with
12613 'agent_socket_name'.
12614 (gdb_agent_remove_socket): New.
12615
5a3f286f
YQ
126162012-07-27 Yao Qi <yao@codesourcery.com>
12617
12618 * server.c (process_point_options): Stop at 'X' when parsing.
12619
961bd387
ME
126202012-07-19 Michael Eager <eager@eagercon.com>
12621
a261b8f5 12622 * i386-low.c (Z_packet_to_hw_type): Add Z_PACKET_HW_BP, translate
961bd387
ME
12623 to hw_execute.
12624 * linux-x86-low.c (x86_insert_point, x86_remove_point):
12625 Call i386_low_insert_watchpoint, i386_low_remove_watchpoint to add/del
12626 hardware breakpoint.
12627
aa7c7447
JK
126282012-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
12629
12630 * gdbserver/linux-low.c (initialize_low): Call
12631 linux_ptrace_init_warnings.
12632
7f216e7c
DE
126332012-07-02 Doug Evans <dje@google.com>
12634
12635 * mem-break.c (gdb_no_commands_at_breakpoint): Fix cast from
12636 pointer to int.
12637
d3ce09f5
SS
126382012-07-02 Stan Shebs <stan@codesourcery.com>
12639
12640 * Makefile.in (WARN_CFLAGS_NO_FORMAT): Define.
12641 (ax.o): Add it to build rule.
12642 (ax-ipa.o): Ditto.
12643 (OBS): Add format.o.
12644 (IPA_OBS): Add format.o.
12645 * server.c (handle_query): Claim support for breakpoint commands.
12646 (process_point_options): Add command case.
12647 (process_serial_event): Leave running if there are printfs in
12648 effect.
12649 * mem-break.h (any_persistent_commands): Declare.
12650 (add_breakpoint_commands): Declare.
12651 (gdb_no_commands_at_breakpoint): Declare.
12652 (run_breakpoint_commands): Declare.
12653 * mem-break.c (struct point_command_list): New struct.
12654 (struct breakpoint): New field command_list.
12655 (any_persistent_commands): New function.
12656 (add_commands_to_breakpoint): New function.
12657 (add_breakpoint_commands): New function.
12658 (gdb_no_commands_at_breakpoint): New function.
12659 (run_breakpoint_commands): New function.
12660 * linux-low.c (linux_wait_1): Test for and run breakpoint commands
12661 locally.
12662 * ax.c: Include format.h.
12663 (ax_printf): New function.
12664 (gdb_eval_agent_expr): Add printf opcode.
12665
2f8f6aed
YQ
126662012-06-13 Yao Qi <yao@codesourcery.com>
12667
12668 * server.c (start_inferior): Remove duplicated writes to fields
12669 'last_resume_kind' and 'last_status' of 'current_inferior'.
12670
0c9070b3
YQ
126712012-06-12 Yao Qi <yao@codesourcery.com>
12672 Pedro Alves <palves@redhat.com>
12673
12674 * linux-low.c (linux_set_resume_request): Simplify predicate. Add
12675 comment.
12676 * server.c (handle_v_cont): Extend comment.
12677
c52daf70
YQ
126782012-06-11 Yao Qi <yao@codesourcery.com>
12679
12680 * linux-low.c (linux_attach): Add 'static'.
12681
d38bbb0a
YQ
126822012-06-06 Yao Qi <yao@codesourcery.com>
12683
12684 * ax.c (gdb_eval_agent_expr): Print `top' in hex.
12685
89dc0afd
JK
126862012-06-01 Jan Kratochvil <jan.kratochvil@redhat.com>
12687
12688 Fix gcc -flto compilation warning.
12689 * server.c (main): Make variable multi_mode and attach volatile.
12690
75f62ce7
TJB
126912012-05-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
12692
12693 * linux-low.c (get_r_debug): Disable code using DT_MIPS_RLD_MAP
12694 if the platform doesn't know about it.
12695
65f479b6
PA
126962012-05-30 Jeff Kenton <jkenton@tilera.com>
12697
12698 * Makefile.in (SFILES): Add linux-tile-low.c.
12699 (linux-tile-low.o, reg-tilegx.o, reg-tilegx.c): New rules.
12700 * configure.srv: Handle tilegx-*-linux*.
12701 * linux-tile-low.c: New file.
12702
0c5bf5a9
JK
127032012-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
12704
12705 * linux-low.c (linux_qxfer_libraries_svr4): Return -1 if R_DEBUG is -1.
12706
a493e3e2
PA
127072012-05-24 Pedro Alves <palves@redhat.com>
12708
12709 PR gdb/7205
12710
43aaf8b6 12711 Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.
a493e3e2 12712
2ea28649
PA
127132012-05-24 Pedro Alves <palves@redhat.com>
12714
12715 PR gdb/7205
12716
12717 Replace target_signal with gdb_signal throughout.
12718
8d409d16
MR
127192012-05-22 Maciej W. Rozycki <macro@codesourcery.com>
12720
12721 * linux-low.c (linux_store_registers): Avoid the copying sequence
12722 when no data has been retrieved by ptrace.
12723
23512c01
MGD
127242012-05-22 Will Deacon <will.deacon@arm.com>
12725
12726 * linux-low (__UCLIBC__ && !(__UCLIBC_HAS_MMU__ || __ARCH_HAS_MMU__)):
12727 Include asm/ptrace.h.
12728 (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define only if not
12729 already defined.
12730
4934b29e
MR
127312012-05-21 Maciej W. Rozycki <macro@codesourcery.com>
12732
12733 * linux-low.c (linux_store_registers): Don't re-retrieve data
12734 with ptrace that has already been obtained from /proc. Always
12735 copy any data retrieved with ptrace to the buffer supplied.
12736
bde24c0a
PA
127372012-05-11 Yao Qi <yao@codesourcery.com>
12738 Pedro Alves <palves@redhat.com>
12739
12740 * linux-low.c (enum stopping_threads_kind): New.
12741 (stopping_threads): Change type to `enum stopping_threads_kind'.
12742 (handle_extended_wait): If stopping and suspending threads, leave
12743 the new_lwp suspended too.
12744 (linux_wait_for_event): Adjust.
12745 (stop_all_lwps): Set `stopping_threads' to
12746 STOPPING_AND_SUSPENDING_THREADS or STOPPING_THREADS depending on
12747 whether we're suspending threads or just stopping them. Assert no
12748 recursion happens.
12749
623b6bdf
YQ
127502012-04-29 Yao Qi <yao@codesourcery.com>
12751
12752 * server.h: Move some code to ...
12753 * gdbthread.h: ... here. New.
12754 * Makefile.in (inferiors.o, regcache.o): Depends on gdbthread.h
12755 (remote-utils.o, server.o, target.o tracepoint.o): Likewise.
12756 (nto-low.o, win32-low.o): Likewise.
12757 * inferiors.c, linux-low.h, nto-low.c: Include gdbthread.h.
12758 * regcache.c, remote-utils.c, server.c: Likewise.
12759 * target.c, tracepoint.c, win32-low.c: Likewise.
12760
f15f9948
TJB
127612012-04-24 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
12762
12763 * linux-low.h (PTRACE_ARG3_TYPE): Move macro from linux-low.c.
12764 (PTRACE_ARG4_TYPE): Likewise.
12765 (PTRACE_XFER_TYPE): Likewise.
12766 * linux-arm-low.c (arm_prepare_to_resume): Cast third argument of
12767 ptrace to PTRACE_ARG3_TYPE.
12768 * linux-low.c (PTRACE_ARG3_TYPE): Move macro to linux-low.h.
12769 (PTRACE_ARG4_TYPE): Likewise.
12770 (PTRACE_XFER_TYPE): Likewise.
12771 (linux_detach_one_lwp): Cast fourth argument of
12772 ptrace to long then PTRACE_ARG4_TYPE.
12773 (regsets_fetch_inferior_registers): Cast third argument of
12774 ptrace to long then PTRACE_ARG3_TYPE.
12775 (regsets_store_inferior_registers): Likewise.
12776
38ea300a
PA
127772012-04-20 Pedro Alves <palves@redhat.com>
12778
12779 * configure: Regenerate.
12780
c971b7fa
PA
127812012-04-19 Pedro Alves <palves@redhat.com>
12782
43aaf8b6 12783 * Makefile.in (GNULIB_BUILDDIR): New.
c971b7fa 12784 (LIBGNU, INCGNU, GNULIB_H): Adjust.
43aaf8b6
PA
12785 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): New.
12786 (all, install-only, uninstall, clean-info, all-lib, clean): No
12787 longer pass GNULIB_FLAGS_TO_PASS. Use subdir_do.
12788 (maintainer-clean realclean distclean): Use subdir_do.
12789 (subdir_do): New.
12790 (gnulib/import/Makefile): Adjust. Replace gnulib/import with
c971b7fa 12791 $(GNULIB_BUILDDIR). Don't pass argument to config.status.
43aaf8b6
PA
12792 * acinclude.m4: Include acx_configure_dir.m4.
12793 * configure.ac: Remove gl_EARLY, gl_INIT, and AM_INIT_AUTOMAKE
12794 calls. Call AC_PROG_RANLIB. Configure gnulib using
12795 ACX_CONFIGURE_DIR.
12796 (GNULIB): New.
12797 (GNULIB_STDINT_H): Adjust.
12798 (AC_OUTPUT): Don't output gnulib/Makefile anymore.
12799 * gdbreplay.c: Include build-gnulib/config.h.
12800 * server.h: Likewise.
12801 * aclocal.m4: Regenerate.
12802 * config.in: Regenerate.
12803 * configure: Regenerate.
c971b7fa 12804
809277f8
PA
128052012-04-19 Pedro Alves <palves@redhat.com>
12806
12807 * Makefile.in (LIBGNU, INCGNU): Adjust.
12808 (GNULIB_FLAGS_TO_PASS, GNULIB_H): Adjust.
12809 (all, install-only, uninstall, clean-info, all-lib, clean)
12810 (maintainer-clean, Makefile, gnulib/Makefile): Adjust.
12811 * configure.ac: Adjust AC_OUTPUT output.
12812 * aclocal.m4: Regenerate.
12813 * configure: Regenerate.
12814
fd9bb8b8
PA
128152012-04-19 Pedro Alves <palves@redhat.com>
12816
12817 * Makefile.in (generated_files): New.
12818 (server_h): Remove the explicit dependency on config.h, and depend
12819 on $generated_files.
12820
1c298c66
PA
128212012-04-19 Pedro Alves <palves@redhat.com>
12822
12823 * Makefile.in (INCGNU): Add -Ignulib.
12824
57c4b50b
PA
128252012-04-19 Pedro Alves <palves@redhat.com>
12826
12827 * Makefile.in (GNULIB_INCLUDE_DIR): Rename to ...
12828 (INCGNU): ... this, and spell out -I here.
12829 (GNULIB_LIB): Rename to ...
12830 (LIBGNU): ... this.
12831 (INCLUDE_CFLAGS, gdbserver$(EXEEXT), $(GNULIB_LIB) rule): Adjust.
12832
1030e047
PA
128332012-04-19 Pedro Alves <palves@redhat.com>
12834
12835 * config.in: Regenerate.
12836
447d4319
PA
128372012-04-19 Pedro Alves <palves@redhat.com>
12838
12839 * configure.ac: Remove AC_CHECK_DECLS check for memmem.
12840 * server.h (memmem): Remove declaration.
12841 * config.in: Regenerate.
12842 * configure: Regenerate.
12843
aad9eab9
YQ
128442012-04-19 Yao Qi <yao@codesourcery.com>
12845
12846 * Makefile.in (SFILES): Add common/vec.c.
12847 (OBS): Add vec.o.
12848 (vec.o): New rule.
12849
3e10640f
YQ
128502012-04-19 Yao Qi <yao@codesourcery.com>
12851
12852 * remote-utils.c (prepare_resume_reply): Replace with macro
12853 target_core_of_thread.
12854 * server.c (handle_qxfer_threads_proper): Likewise.
12855 * target.h (traget_core_of_thread): New macro.
12856
71622373
PA
128572012-04-18 Pedro Alves <palves@redhat.com>
12858
12859 * aclocal.m4: Regenerate.
12860 * configure: Regenerate.
12861
80d26939
YQ
128622012-04-16 Yao Qi <yao@codesourcery.com>
12863
12864 * tracepoint.c (cmd_qtstart): Download tracepoints even when they are
12865 duplicated on address.
12866
42476b70
YQ
128672012-04-16 Yao Qi <yao@codesourcery.com>
12868
12869 * tracepoint.c (COPY_FIELD_TO_BUF): New macro.
12870 (struct tracepoint_action_ops) <send>: New field.
12871 (m_tracepoint_action_send, r_tracepoint_action_send): New.
12872 (agent_expr_send, x_tracepoint_action_send): New.
12873 (l_tracepoint_action_send): New.
12874 (cmd_qtdp): Download and install tracepoint
12875 according to `use_agent'.
12876 (run_inferior_command): Add one more parameter `len'.
12877 Update callers.
12878 (tracepoint_send_agent): New.
12879 (cmd_qtdp, cmd_qtstart): Call tracepoint_send_agent.
12880
7bc83639
YQ
128812012-04-16 Yao Qi <yao@codesourcery.com>
12882
12883 * tracepoint.c (download_tracepoints): Moved to ...
12884 (cmd_qtstart): ... here.
12885
5f18041e
YQ
128862012-04-14 Yao Qi <yao@codesourcery.com>
12887
12888 * tracepoint.c: Include inttypes.h.
12889 (struct collect_memory_action): Use sized types.
12890 (struct tracepoint): Likewise.
12891 (cmd_qtdp, stop_tracing): Update print specifiers.
12892 (cmd_qtp, response_tracepoint): Likewise.
12893 (collect_data_at_tracepoint): Likewise.
12894 (collect_data_at_step): Likewise.
12895
55a8c076
YQ
128962012-04-14 Yao Qi <yao@codesourcery.com>
12897
12898 Import gnulib module inttypes.
12899 * aclocal.m4, config.in, configure: Regenerated.
12900
dc750257
YQ
129012012-04-14 Yao Qi <yao@codesourcery.com>
12902
12903 * Makefile.in (maintainer-clean, realclean, distclean): Remove
12904 Makefile and config.status at last.
12905
0ab5faf9
YQ
129062012-04-13 Yao Qi <yao@codesourcery.com>
12907
12908 * tracepoint.c: Include stdint.h unconditionally.
12909
18f5fd81
TJB
129102012-04-13 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
12911
12912 * acinclude.m4 (GDBSERVER_HAVE_THREAD_DB_TYPE): New macro based
12913 on BFD_HAVE_SYS_PROCFS_TYPE.
12914 * configure.ac: Look for lwpid_t and psaddr_t in libthread_db.h.
12915 * configure: Regenerate.
12916 * config.in: Likewise.
12917
4d47af5c
L
129182012-04-13 H.J. Lu <hongjiu.lu@intel.com>
12919
12920 * Makefile.in (clean): Also remove x32.c x32-linux.c
12921 x32-avx.c x32-avx-linux.c.
12922 (x32.o): New target.
12923 (x32.c): Likewise.
12924 (x32-linux.o): Likewise.
12925 (x32-linux.c): Likewise.
12926 (x32-avx.o): Likewise.
12927 (x32-avx.c): Likewise.
12928 (x32-avx-linux.o): Likewise.
12929 (x32-avx-linux.c): Likewise.
12930
12931 * configure.srv (srv_amd64_regobj): Add x32.o x32-avx.o.
12932 (srv_amd64_linux_regobj): Add x32-linux.o x32-avx-linux.o.
12933 (srv_i386_64bit_xmlfiles): Add i386/x32-core.xml.
12934 (srv_amd64_xmlfiles): Add i386/x32.xml i386/x32-avx.xml.
12935 (srv_amd64_linux_xmlfiles): Add i386/x32-linux.xml
12936 i386/x32-avx-linux.xml.
12937
12938 * linux-x86-low.c (init_registers_x32_linux): New prototype.
12939 (init_registers_x32_avx_linux): Likwise.
12940 (x86_linux_update_xmltarget): Call init_registers_x32_linux
12941 or init_registers_x32_avx_linux if linux_is_elf64 is false.
12942
ecedbe58
PA
129432012-04-13 Pedro Alves <palves@redhat.com>
12944
12945 * Makefile.in (GNULIB_FLAGS_TO_PASS): New.
12946 (FLAGS_TO_PASS): Don't change or set $top_srcdir, $srcdir and VPATH.
12947 (all, uninstall, clean-info, all-lib, clean, maintainer-clean)
12948 (realclean, distclean): Explicitly pass $GNULIB_FLAGS_TO_PASS to
12949 the sub-make.
12950
c92b5177
L
129512012-04-12 H.J. Lu <hongjiu.lu@intel.com>
12952
12953 * linux-x86-low.c (compat_x32_clock_t): New.
12954 (compat_x32_siginfo_t): Likewise.
12955 (compat_x32_siginfo_from_siginfo): Likewise.
12956 (siginfo_from_compat_x32_siginfo): Likewise.
12957 (linux_is_elf64): Likewise.
12958 (x86_siginfo_fixup): Call compat_x32_siginfo_from_siginfo
12959 and siginfo_from_compat_x32_siginfo for x32.
12960 (x86_arch_setup): Set linux_is_elf64.
12961
214d508e
L
129622012-04-12 H.J. Lu <hongjiu.lu@intel.com>
12963
12964 PR gdb/13969
12965 * linux-low.c (linux_pid_exe_is_elf_64_file): Also return the
12966 e_machine field.
12967 (linux_qxfer_libraries_svr4): Update call to elf_64_file_p.
12968 * linux-low.h (linux_pid_exe_is_elf_64_file): Updated.
12969 * linux-x86-low.c (x86_arch_setup): Check if GDBserver is
12970 compatible with process.
12971
c9a1864a
YQ
129722012-04-12 Yao Qi <yao@codesourcery.com>
12973
12974 * Makefile.in: Define abs_top_srcdir and abs_srcdir.
12975 (INCLUDE_CFLAGS): Append GNULIB_INCLUDE_DIR.
12976 (install-only, install-info, clean): Handle sub dir gnulib.
12977 (all-lib, am--refresh): New targets.
12978 (memmem.o): Remove target.
12979 * configure.ac: Remove AC_CONFIG_LIBOBJ_DIR.
12980 Invoke gl_EARLY. Invoke AC_CHECK_PROGS for make.
12981 (AC_REPLACE_FUNCS): Remove memmem.
12982 Invoke gl_INIT and AM_INIT_AUTOMAKE.
12983 (AC_OUTPUT): Generate Makefile in gnulib/.
12984 * aclocal.m4, config.in, configure: Regenerated.
12985
367ba2c2
MR
129862012-04-10 Maciej W. Rozycki <macro@codesourcery.com>
12987
12988 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP.
12989
9d236627
PA
129902012-04-05 Pedro Alves <palves@redhat.com>
12991
12992 -Werror=strict-aliasing
12993
12994 * spu-low.c (parse_spufs_run): Avoid dereferencing type-punned
12995 pointer.
12996
111217b3
PA
129972012-04-04 Pedro Alves <palves@redhat.com>
12998
12999 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
13000 (sparc_store_gregset_from_stack, sparc_store_gregset)
13001 (sparc_breakpoint_at): Fix formatting.
13002
8365dcf5
TJB
130032012-03-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
13004
13005 * configure.ac: Check whether Elf32_auxv_t and Elf64_auxv_t
13006 are available.
13007 * linux-low.c [HAVE_ELF32_AUXV_T] (Elf32_auxv_t): Add typedef.
13008 [HAVE_ELF64_AUXV_T] (Elf64_auxv_t): Likewise.
13009 * config.in: Regenerate.
13010 * configure: Likewise.
13011
689cc2ae
PA
130122012-03-29 Pedro Alves <palves@redhat.com>
13013
13014 * linux-low.c (regsets_store_inferior_registers) [__sparc__]:
13015 Correct ptrace arguments.
13016
c14dfd32
PA
130172012-03-28 Pedro Alves <palves@redhat.com>
13018
13019 * linux-ia64-low.c (ia64_regmap): Map IA64_EC_REGNUM to PT_AR_EC.
13020 (IA64_GR0_REGNUM, IA64_FR0_REGNUM)
13021 (IA64_FR1_REGNUM): New defines.
13022 (ia64_fetch_register): New.
13023 (the_low_target): Install it.
13024 * linux-low.h (struct linux_target_ops) <fetch_register>: New
13025 field.
13026 * linux-low.c (linux_fetch_registers): Try the
13027 the_low_target.fetch_register hook first.
13028
13029 * linux-arm-low.c (the_low_target): Adjust.
13030 * linux-bfin-low.c (the_low_target): Adjust.
13031 * linux-cris-low.c (the_low_target): Adjust.
13032 * linux-crisv32-low.c (the_low_target): Adjust.
13033 * linux-m32r-low.c (the_low_target): Adjust.
13034 * linux-m68k-low.c (the_low_target): Adjust.
13035 * linux-mips-low.c (the_low_target): Adjust.
13036 * linux-ppc-low.c (the_low_target): Adjust.
13037 * linux-s390-low.c (the_low_target): Adjust.
13038 * linux-sh-low.c (the_low_target): Adjust.
13039 * linux-sparc-low.c (the_low_target): Adjust.
13040 * linux-tic6x-low.c (the_low_target): Adjust.
13041 * linux-x86-low.c (the_low_target): Adjust.
13042 * linux-xtensa-low.c (the_low_target): Adjust.
13043
63c88e13
PA
130442012-03-26 Pedro Alves <palves@redhat.com>
13045
13046 * server.c (handle_qxfer_libraries): Don't bail early if
13047 the_target->qxfer_libraries_svr4 is not NULL.
13048
fb723180
PA
130492012-03-26 Pedro Alves <palves@redhat.com>
13050
13051 * linux-low.c (linux_qxfer_libraries_svr4): Fix pasto in comment.
13052
0afae3cf
PA
130532012-03-23 Pedro Alves <palves@redhat.com>
13054
13055 * linux-low.c (linux_qxfer_libraries_svr4): Terminate the
13056 "library-list-svr4" element's start tag when the the DSO list is
13057 empty.
13058
485f1ee4
PA
130592012-03-23 Pedro Alves <palves@redhat.com>
13060
13061 * linux-low.c (read_one_ptr): Read the inferior's pointer through
13062 a variable whose type size is the same as the inferior's pointer
13063 size.
13064
a5362b9a
TS
130652012-03-21 Thomas Schwinge <thomas@codesourcery.com>
13066
13067 * linux-arm-low.c (arm_stopped_by_watchpoint): Use siginfo_t instead of
13068 struct siginfo.
13069 * linux-low.c (siginfo_fixup, linux_xfer_siginfo): Likewise.
13070 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
13071 * linux-low.h: Include <signal.h>.
13072 (struct siginfo): Remove forward declaration.
13073 (struct linux_target_ops) <siginfo_fixup>: Use siginfo_t instead of
13074 struct siginfo.
13075
d226c142
MF
130762012-03-21 Mike Frysinger <vapier@gentoo.org>
13077
13078 * .gitignore: Ignore more files.
13079
122f36ef
PA
130802012-03-19 Pedro Alves <palves@redhat.com>
13081 Jan Kratochvil <jan.kratochvil@redhat.com>
13082
13083 * server.c (cont_thread, general_thread): Add describing comments.
13084 (start_inferior): Clear `cont_thread'.
13085 (handle_v_cont): Don't set `cont_thread' if resuming all threads
13086 of a process.
13087
fc3e5175
YQ
130882012-03-15 Yao Qi <yao@codesourcery.com>
13089
13090 * tracepoint.c (install_tracepoint): Move duplicated tracepoint
13091 handling to ...
13092 (cmd_qtdp): ... here.
13093
8d0d92cd
YQ
130942012-03-15 Yao Qi <yao@codesourcery.com>
13095
13096 * tracepoint.c (struct tracepoint_action_ops): New.
13097 (struct tracepoint_action) [!IN_PROCESS_AGENT] <ops>: New field.
13098 (m_tracepoint_action_download): New.
13099 (r_tracepoint_action_download): New.
13100 (x_tracepoint_action_download): New.
13101 (l_tracepoint_action_download): New.
13102 (add_tracepoint_action): Install `action->ops' according type.
13103 (download_tracepoint_1): Move code `download' function pointer
13104 of various tracepoint_action_ops.
13105
87b0bb13
JK
131062012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
13107
13108 * linux-low.c (linux_attach_lwp_1): New variable buffer. Call
13109 linux_ptrace_attach_warnings.
13110
5f572dec
JK
131112012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
13112
13113 * Makefile.in (linux-ptrace.o): New.
13114 * configure.srv (arm*-*-linux*, bfin-*-*linux*, crisv32-*-linux*)
13115 (cris-*-linux*, i[34567]86-*-linux*, ia64-*-linux*, m32r*-*-linux*)
13116 (m68*-*-linux*, m68*-*-uclinux*, mips*-*-linux*, powerpc*-*-linux*)
13117 (s390*-*-linux*, sh*-*-linux*, sparc*-*-linux*, tic6x-*-uclinux)
13118 (x86_64-*-linux*, xtensa*-*-linux*): Add linux-ptrace.o to SRV_TGTOBJ
13119 of these targets.
13120 * linux-low.c (linux_attach_lwp_1): Remove redundent else clause.
13121
f4647387
YQ
131222012-03-08 Yao Qi <yao@codesourcery.com>
13123 Pedro Alves <palves@redhat.com>
13124
13125 Fix PR server/13392.
13126 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Check
13127 offset of JMP insn.
13128 * tracepoint.c (remove_tracepoint): New.
13129 (cmd_qtdp): Call remove_tracepoint when failed to install.
13130
9b224c5e
PA
131312012-03-07 Pedro Alves <palves@redhat.com>
13132
13133 * linux-low.c (get_detach_signal): New.
13134 (linux_detach_one_lwp): Get rid of a pending SIGSTOP with SIGCONT.
13135 Pass on pending signals to PTRACE_DETACH. Check the result of the
13136 ptrace call.
13137 * server.c (program_signals, program_signals_p): New.
13138 (handle_general_set): Handle QProgramSignals.
13139 * server.h (program_signals, program_signals_p): Declare.
13140
e237a7e2
JK
131412012-03-05 Pedro Alves <palves@redhat.com>
13142 Jan Kratochvil <jan.kratochvil@redhat.com>
13143
13144 * linux-low.c (get_dynamic): Don't warn when PT_PHDR isn't found.
13145 New comment why.
13146
5808517f
YQ
131472012-03-03 Yao Qi <yao@codesourcery.com>
13148
13149 * tracepoint.c (tracepoint_look_up_symbols): Update call to
13150 agent_look_up_symbols.
13151
58b4daa5
YQ
131522012-03-03 Yao Qi <yao@codesourcery.com>
13153
13154 * Makefile.in (linux-low.o): Keep dependence on agent.h.
13155 (linux-x86-low.o): Likewise.
13156 * server.h: Remove in_process_agent_loaded.
13157 * tracepoint.c (in_process_agent_loaded): Removed. Moved it
13158 common/agent.c.
13159 Update callers.
13160
8ffcbaaf
YQ
131612012-03-03 Yao Qi <yao@codesourcery.com>
13162
13163 * tracepoint.c (gdb_agent_capability): New global.
13164 (in_process_agent_loaded_ust): Renamed to
13165 `in_process_agent_supports_ust'.
13166 Update callers.
13167 (in_process_agent_supports_ust): Call agent_capability_check.
13168 (clear_installed_tracepoints): Assert that agent supports
13169 agent.
13170
d1feda86
YQ
131712012-03-03 Yao Qi <yao@codesourcery.com>
13172
13173 * linux-low.c (linux_supports_agent): New.
13174 (linux_target_ops): Initialize field `supports_agent' with
13175 linux_supports_agent.
13176 * target.h (struct target_ops) <supports_agent>: New.
13177 (target_supports_agent): New macro.
13178 * server.c (handle_general_set): Handle packet 'QAgent'.
13179 (handle_query): Send `QAgent+'.
13180 * Makefile.in (server.o): Depends on agent.h.
13181
2fa291ac
YQ
131822012-03-03 Yao Qi <yao@codesourcery.com>
13183
13184 * Makefile.in (OBS): Add agent.o.
13185 Add new rule for agent.o.
13186 Track dependence of tracepoint.c on agent.h.
13187 * tracepoint.c (run_inferior_command_1):
13188 (run_inferior_command): Call agent_run_command.
13189 (gdb_ust_connect_sync_socket): Deleted. Move it to
13190 common/agent.c.
13191 (resume_thread, stop_thread): Likewise.
13192 (gdb_ust_socket_init): Renamed to ...
13193 (gdb_agent_socket_init): ... New.
13194 (gdb_ust_thread): Renamed to ...
13195 (gdb_agent_helper_thread): ... New.
13196 (gdb_ust_init): Move some code to ...
13197 (gdb_agent_init): ... here. New.
13198 [HAVE_UST]: Call gdb_ust_init.
13199 (initialize_tracepoint_ftlib): Call gdb_agent_init.
13200 * configure.ac: Add `sys/un.h' to AC_CHECK_HEADERS.
13201 * config.in, configure: Regenerated.
13202
05044653
PA
132032012-03-02 Pedro Alves <palves@redhat.com>
13204
13205 * inferiors.c (add_pid_to_list, pull_pid_from_list): Delete.
13206 * linux-low.c (struct simple_pid_list): New.
13207 (stopped_pids): New a struct simple_pid_list pointer.
13208 (add_to_pid_list, pull_pid_from_list): New.
13209 (handle_extended_wait): Don't assume the first signal new children
13210 report is SIGSTOP. Adjust call to pull_pid_from_list.
13211 (linux_wait_for_lwp): Adjust.
13212
8d00225b
YQ
132132012-03-02 Yao Qi <yao@codesourcery.com>
13214
13215 * tracepoint.c (do_action_at_tracepoint): Write `stop_pc' in
13216 debug log.
13217
19560ba5
YQ
132182012-03-02 Yao Qi <yao@codesourcery.com>
13219
13220 * tracepoint.c (collect_ust_data_at_tracepoint): Remove parameters
13221 `stop_pc' and `tpoint'. Update caller.
13222
1faeff08
MR
132232012-03-01 Maciej W. Rozycki <macro@codesourcery.com>
13224
13225 * linux-low.h (linux_target_ops): Add regset_bitmap member.
13226 * linux-low.c (use_linux_regsets): New macro.
13227 [!HAVE_LINUX_REGSETS] (regsets_fetch_inferior_registers): Likewise.
13228 [!HAVE_LINUX_REGSETS] (regsets_store_inferior_registers): Likewise.
13229 (linux_register_in_regsets): New function.
13230 (usr_fetch_inferior_registers): Skip registers covered by
13231 regsets.
13232 (usr_store_inferior_registers): Likewise.
13233 (usr_fetch_inferior_registers): New macro.
13234 (usr_store_inferior_registers): Likewise.
13235 (linux_fetch_registers): Handle mixed regset/non-regset targets.
13236 (linux_store_registers): Likewise.
13237 * linux-mips-low.c (init_registers_mips_dsp_linux): New
13238 prototype.
13239 (init_registers_mips64_dsp_linux): Likewise.
13240 (init_registers_mips_linux): New macro.
13241 (init_registers_mips_dsp_linux): Likewise.
13242 (mips_dsp_num_regs): Likewise.
13243 (DSP_BASE, DSP_CONTROL): New fallback macros.
13244 (mips_base_regs): New macro.
13245 (mips_regmap): Use it. Fix the size.
13246 (mips_dsp_regmap): New variable.
13247 (mips_dsp_regset_bitmap): Likewise.
13248 (mips_arch_setup): New function.
13249 (mips_cannot_fetch_register): Use the_low_target.regmap rather
13250 than mips_regmap.
13251 (mips_cannot_store_register): Likewise.
13252 (the_low_target): Update .arch_setup, .num_regs and .regmap
13253 initializers. Add .regset_bitmap initializer.
13254 * linux-arm-low.c (the_low_target): Add .regset_bitmap
13255 initializer.
13256 * linux-bfin-low.c (the_low_target): Likewise.
13257 * linux-cris-low.c (the_low_target): Likewise.
13258 * linux-crisv32-low.c (the_low_target): Likewise.
13259 * linux-ia64-low.c (the_low_target): Likewise.
13260 * linux-m32r-low.c (the_low_target): Likewise.
13261 * linux-m68k-low.c (the_low_target): Likewise.
13262 * linux-ppc-low.c (the_low_target): Likewise.
13263 * linux-s390-low.c (the_low_target): Likewise.
13264 * linux-sh-low.c (the_low_target): Likewise.
13265 * linux-sparc-low.c (the_low_target): Likewise.
13266 * linux-tic6x-low.c (the_low_target): Likewise.
13267 * linux-x86-low.c (the_low_target): Likewise.
13268 * linux-xtensa-low.c (the_low_target): Likewise.
13269 * configure.srv <mips*-*-linux*>: Add mips-dsp-linux.o and
13270 mips64-dsp-linux.o to srv_regobj. Add mips-dsp-linux.xml,
13271 mips64-dsp-linux.xml, mips-dsp.xml and mips64-dsp.xml to
13272 srv_xmlfiles.
13273 * Makefile.in (mips-dsp-linux.o, mips-dsp-linux.c): New targets.
13274 (mips64-dsp-linux.o, mips64-dsp-linux.c): Likewise.
13275
c03e6ccc
YQ
132762012-02-29 Yao Qi <yao@codesourcery.com>
13277 Pedro Alves <palves@redhat.com>
13278
13279 * linux-low.c: (linux_wait_1): Call unsuspend_all_lwps when
13280 `step_over_finished' is true.
13281
644cebc9
PA
132822012-02-27 Pedro Alves <palves@redhat.com>
13283
13284 * linux-low.c (pid_is_stopped): Delete, moved to common/.
13285 (linux_attach_lwp_1): Adjust to use linux_proc_pid_is_stopped.
13286
c14d7ab2
PA
132872012-02-27 Pedro Alves <palves@redhat.com>
13288
13289 PR server/9684
13290 * linux-low.c (pid_is_stopped): New.
13291 (linux_attach_lwp_1): Handle attaching to 'T (stopped)' processes.
13292
412c89dd
LM
132932012-02-25 Luis Machado <lgustavo@codesourcery.com>
13294
13295 * mem-break.c (clear_gdb_breakpoint_conditions): Fix de-allocation
13296 of conditions.
13297
b745defe
MR
132982012-02-24 Maciej W. Rozycki <macro@codesourcery.com>
13299
13300 * linux-mips-low.c (mips_regmap): Correct the index of $f9.
13301
9f3a5c85
LM
133022012-02-24 Luis Machado <lgustavo@codesourcery>
13303
13304 * server.c (handle_query): Advertise support for target-side
13305 breakpoint condition evaluation.
13306 (process_point_options): New function.
13307 (process_serial_event): When inserting a breakpoint, check for
13308 a target-side condition that should be evaluated.
13309
13310 * mem-break.c: Include regcache.h and ax.h.
13311 (point_cond_list_t): New data structure.
13312 (breakpoint) <cond_list>: New field.
13313 (find_gdb_breakpoint_at): Make non-static.
13314 (delete_gdb_breakpoint_at): Clear any target-side
13315 conditions.
13316 (clear_gdb_breakpoint_conditions): New function.
13317 (add_condition_to_breakpoint): Likewise.
13318 (add_breakpoint_condition): Likewise.
13319 (gdb_condition_true_at_breakpoint): Likewise.
13320 (gdb_breakpoint_here): Return result directly instead
13321 of going through a local variable.
13322
13323 * mem-break.h (find_gdb_breakpoint_at): New prototype.
13324 (clear_gdb_breakpoint_conditions): Likewise.
13325 (add_breakpoint_condition): Likewise.
13326 (gdb_condition_true_at_breakpoint): Likewise.
13327
13328 * linux-low.c (linux_wait_1): Evaluate target-side breakpoint condition.
13329 (need_step_over_p): Take target-side breakpoint condition into
13330 consideration.
13331
5e1dc496
LM
133322012-02-24 Luis Machado <lgustavo@codesourcery>
13333
13334 * server.h: Include tracepoint.h.
13335 (agent_mem_read, agent_get_trace_state_variable_value,
13336 agent_set_trace_state_variable_value,
13337 agent_tsv_read, agent_mem_read_string, get_get_tsv_func_addr,
13338 get_set_tsv_func_addr): New prototypes.
13339
13340 * ax.h: New include file.
13341 * ax.c: New source file.
13342
13343 * tracepoint.c: Include ax.h.
13344 (gdb_agent_op, gdb_agent_op_names, gdb_agent_op_sizes,
13345 agent_expr, eval_result_type): Move to ax.h.
13346 (parse_agent_expr): Rename to ...
13347 (gdb_parse_agent_expr): ... this, make it non-static and move
13348 to ax.h.
13349 (unparse_agent_expr) Rename to ...
13350 (gdb_unparse_agent_expr): ... this, make it non-static and move
13351 to ax.h.
13352 (eval_agent_expr): Rename to ...
13353 (eval_tracepoint_agent_expr): ... this.
13354 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Remove
13355 forward declarations.
13356 (add_tracepoint_action): Call gdb_parse_agent_expr (...).
13357 (agent_get_trace_state_variable_value): New function.
13358 (agent_set_trace_state_variable_value): New function.
13359 (cmd_qtdp): Call gdb_parse_agent_expr (...).
13360 (response_tracepoint): Call gdb_unparse_agent_expr (...).
13361 (do_action_at_tracepoint): Call eval_tracepoint_agent_expr (...).
13362 (condition_true_at_tracepoint): Likewise.
13363 (parse_agent_expr): Rename to ...
13364 (gdb_parse_agent_expr): ... this and move to ax.c.
13365 (unparse_agent_expr): Rename to ...
13366 (gdb_unparse_agent_expr): ... this and move to ax.c.
13367 (gdb_agent_op_name): Move to ax.c.
13368 (eval_agent_expr): Rename to ...
13369 (gdb_eval_agent_expr): ... this, use regcache passed as parameter
13370 and move to ax.c.
13371 (eval_tracepoint_agent_expr): New function.
13372 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Make
43aaf8b6 13373 non-static.
5e1dc496
LM
13374 (current_insn_ptr, emit_error, struct bytecode_address): Move to
13375 ax.c.
13376 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul, emit_lsh,
13377 emit_rsh_signed, emit_rsh_unsigned, emit_ext, emit_log_not,
13378 emit_bit_and, emit_bit_or, emit_bit_xor, emit_bit_not, emit_equal,
13379 emit_less_signed, emit_less_unsigned, emit_ref, emit_if_goto,
13380 emit_goto, write_goto_address, emit_const, emit_reg, emit_pop,
13381 emit_stack, emit_zero_ext, emit_swap, emit_stack_adjust,
13382 emit_int_call_1, emit_void_call_2, emit_eq_goto, emit_ne_goto,
13383 emit_lt_goto, emit_ge_goto, emit_gt_goto, emit_le_goto): Move to ax.c.
13384 (get_get_tsv_func_addr, get_set_tsv_func_addr): New functions.
13385 (compile_bytecodes): Remove forward declaration.
13386 (is_goto_target): Move to ax.c.
13387 (compile_bytecodes): Move to ax.c and call
13388 agent_get_trace_state_variable_value (...) and
13389 agent_set_trace_state_variable_value (...).
13390
13391 * Makefile.in: Update ax.c and IPA dependencies.
13392
277e4e52
PA
133932012-02-24 Pedro Alves <palves@redhat.com>
13394
13395 * tracepoint.c (cmd_bigqtbuffer): Rename as ...
13396 (cmd_bigqtbuffer_circular): ... this. Only handle
13397 'QTBuffer:circular:'.
13398 (handle_tracepoint_general_set): Adjust.
13399
bf4c19f7
YQ
134002012-02-16 Yao Qi <yao@codesourcery.com>
13401
13402 * inferiors.c: Move code to ...
13403 * dll.c: .... here. New.
13404 * server.h: Declare clear_dlls.
13405 * Makefile.in (SFILES): Add dll.c.
13406 (OBS): Add dll.o
13407 (dll.o): New rule.
13408
d73f2619
YQ
134092012-02-11 Yao Qi <yao@codesourcery.com>
13410
13411 * server.c: (handle_monitor_command): Add a new parameter
13412 `own_buf'.
13413 (handle_query): Update caller.
13414
f8255c2a
JB
134152012-02-09 Joel Brobecker <brobecker@adacore.com>
13416
13417 * configure.ac: Add readlink to AC_CHECK_FUNCS list.
13418 * configure, config.in: Regenerate.
13419 * hostio.c: Provide an alternate implementation if HAVE_READLINK
13420 is not defined.
13421
da84f473
PA
134222012-02-02 Pedro Alves <palves@redhat.com>
13423
13424 Try SIGKILL first, then PTRACE_KILL.
13425 * linux-low.c (linux_kill_one_lwp): New.
13426 (linux_kill_one_lwp): Rename to ...
13427 (kill_one_lwp_callback): ... this. Use the new
13428 linux_kill_one_lwp.
13429
e886a173
PA
134302012-02-02 Pedro Alves <palves@redhat.com>
13431
13432 * tracepoint.c (cmd_qtminftpilen): Return 0 if there's no current
13433 inferior.
13434
be07f1a2
PA
134352012-01-27 Pedro Alves <palves@redhat.com>
13436
13437 * linux-low.c (linux_child_pid_to_exec_file): Delete.
13438 (elf_64_file_p): Make static.
13439 (linux_pid_exe_is_elf_64_file): New.
13440 * linux-low.h (linux_child_pid_to_exec_file, elf_64_file_p):
13441 Delete declarations.
13442 (linux_pid_exe_is_elf_64_file): Declare.
13443 * linux-x86-low.c (x86_arch_setup): Use
13444 linux_pid_exe_is_elf_64_file.
13445
d8301ad1
JK
134462012-01-25 Jan Kratochvil <jan.kratochvil@redhat.com>
13447
13448 * linux-low.c (linux_wait_for_event_1): Rename to ...
13449 (linux_wait_for_event): ... here and merge it with former
13450 linux_wait_for_event - new variable wait_ptid, use it.
13451 (linux_wait_for_event): Remove - merge it to linux_wait_for_event_1.
13452
01b17894
PA
134532012-01-23 Pedro Alves <palves@redhat.com>
13454
13455 * server.c (main): Avoid yet another case of infinite loop while
13456 detaching/killing after a longjmp.
13457
e825046f
JK
134582012-01-20 Jan Kratochvil <jan.kratochvil@redhat.com>
13459
13460 Code cleanup.
13461 * linux-low.c (linux_wait_for_event_1): Use ptid_is_pid.
13462
b9e7b9c3
UW
134632012-01-20 Ulrich Weigand <ulrich.weigand@linaro.org>
13464
13465 * hostio.c (handle_readlink): New function.
13466 (handle_vFile): Call it to handle "vFile:readlink" packets.
13467
901f9912
UW
134682012-01-20 Pedro Alves <palves@redhat.com>
13469 Ulrich Weigand <ulrich.weigand@linaro.org>
13470
13471 * server.c (handle_v_requests): Only support vAttach and vRun to
13472 start multiple processes when in extended protocol mode.
13473
fc1ab1a0
PA
134742012-01-17 Pedro Alves <palves@redhat.com>
13475
13476 * tracepoint.c (initialize_tracepoint): Use mmap instead of
13477 memalign plus mprotect to allocate the scratch buffer.
13478
7d5d4e98
PA
134792012-01-13 Pedro Alves <palves@redhat.com>
13480
13481 * server.c (attach_inferior): Clear `cont_thread'.
13482
f128d5e9
PA
134832012-01-13 Pedro Alves <palves@redhat.com>
13484
13485 * server.c (main): Avoid infinite loop while detaching/killing
13486 after a longjmp.
13487
06db92f0
DE
134882012-01-09 Doug Evans <dje@google.com>
13489
13490 * server.c (start_inferior): Set last_ptid in --wrapper case.
13491
32d92999
YQ
134922012-01-06 Yao Qi <yao@codesourcery.com>
13493
13494 * tracepoint.c [IN_PROCESS_AGENT] (debug_threads): Macro
13495 defined.
13496 [IN_PROCESS_AGENT] (debug_agent): New global variable.
13497
5e0a92a9
YQ
134982012-01-04 Yao Qi <yao@codesourcery.com>
13499
13500 * tracepoint.c (cmd_qtdp): Print debug message
13501 for static tracepoint.
13502
ae639e8c
YQ
135032012-01-04 Yao Qi <yao@codesourcery.com>
13504
13505 * tracepoint.c (trace_vdebug): Differentiate debug message
13506 between gdbserver and IPA.
13507
f72429c5
YQ
135082012-01-03 Yao Qi <yao@codesourcery.com>
13509
13510 * tracepoint.c (tracepoint_was_hit): Don't collect for
13511 static tracepoint.
13512
12c3e59c
JB
135132012-01-02 Joel Brobecker <brobecker@adacore.com>
13514
13515 * terminal.h: Reformat copyright header.
13516
67827812
JB
135172012-01-02 Joel Brobecker <brobecker@adacore.com>
13518
13519 * server.c (gdbserver_version): Update copyright year.
13520 * gdbreplay.c (gdbreplay_version): Likewise.
13521
3e52c33d
JK
135222011-12-18 Jan Kratochvil <jan.kratochvil@redhat.com>
13523
13524 * linux-low.c (linux_create_inferior): Put empty if clause for write.
13525
13526 Revert:
13527 2011-12-18 Hui Zhu <teawater@gmail.com>
13528 * linux-low.c (linux_create_inferior): Save return value to ret.
13529
66f1260e
HZ
135302011-12-18 Hui Zhu <teawater@gmail.com>
13531
13532 * linux-low.c (linux_create_inferior): Save return value to ret.
13533
e77616d7
DE
135342011-12-16 Doug Evans <dje@google.com>
13535
e7b06c57
DE
13536 * linux-low.c (linux_create_inferior): If stdio connection,
13537 redirect stdin from /dev/null, stdout to stderr.
13538 * remote-utils.c (remote_is_stdio): New static global.
13539 (remote_connection_is_stdio): New function.
13540 (remote_prepare): Handle stdio connection.
13541 (remote_open): Ditto.
13542 (remote_close): Don't close stdin for stdio connections.
13543 (read_prim,write_prim): New functions. Replace all calls to
13544 read/write to these.
13545 * server.c (main): Watch for "-" argument. Move call to
13546 remote_prepare before start_inferior.
13547 * server.h (STDIO_CONNECTION_NAME): New macro.
13548 (remote_connection_is_stdio): Declare.
13549
e77616d7
DE
13550 * remote-utils.c (prepare_resume_reply): Remove extraneous \n
13551 in debugging output.
13552
82067193
YQ
135532011-12-15 Yao Qi <yao@codesourcery.com>
13554
13555 * tracepoint.c: Include sys/syscall.h.
13556 (gdb_ust_thread): Remove preprocessor conditional.
13557
82bfbe7e
PA
135582011-12-14 Pedro Alves <pedro@codesourcery.com>
13559
13560 * linux-low.c (linux_detach_one_lwp): Call
13561 the_low_target.prepare_to_resume before detaching.
13562
712c6575
YQ
135632011-12-14 Yao Qi <yao@codesourcery.com>
13564
13565 * tracepoint.c (gdb_ust_thread): Don't ignore return value
13566 of write.
13567
d54d1edf
YQ
135682011-12-14 Yao Qi <yao@codesourcery.com>
13569
13570 * i386-low.c (i386_low_stopped_data_address): Initialize local
13571 variable `control'.
13572
6210a125
PA
135732011-12-13 Pedro Alves <pedro@codesourcery.com>
13574
13575 PR remote/13492
13576
13577 * i386-low.c (i386_low_stopped_data_address): Avoid fetching
13578 DR_CONTROL unless necessary. Extend comments.
13579 * linux-x86-low.c (x86_linux_prepare_to_resume): Don't write to
13580 DR0-3 if not used. If any watchpoint was set, clear DR_STATUS.
13581
2ece8244
YQ
135822011-12-13 Yao Qi <yao@codesourcery.com>
13583
13584 * tracepoint.c (trace_buffer_alloc): Replace magic numbers with
13585 macros.
13586 (upload_fast_traceframes, upload_fast_traceframes): Likewise.
13587
784867a5
JK
135882011-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
13589
13590 * linux-low.c (linux_kill): Skip PTRACE_KILL if LWP does not exist.
13591 Print new debug message for such case.
13592
6bf36717
JK
135932011-12-06 Jan Kratochvil <jan.kratochvil@redhat.com>
13594
13595 Fix overlapping memcpy.
13596 * mem-break.c (set_raw_breakpoint_at): New variable buf. Use it for
13597 the read_inferior_memory transfer.
13598 (delete_fast_tracepoint_jump): New variable buf. Use it for the
13599 write_inferior_memory transfer.
13600 (set_fast_tracepoint_jump): New variable buf. Use it for the
13601 read_inferior_memory and write_inferior_memory transfers.
13602 (uninsert_fast_tracepoint_jumps_at, reinsert_fast_tracepoint_jumps_at)
13603 (delete_raw_breakpoint, uninsert_raw_breakpoint): New variable buf.
13604 Use it for the write_inferior_memory transfer.
13605 (check_mem_read, check_mem_write): New gdb_asserts for overlapping
13606 buffers.
13607
50275556
MR
136082011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
13609
13610 * linux-low.c (fetch_register, store_register): Make code
13611 consistent, fix formatting.
13612
7325beb4
MR
136132011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
13614
13615 * linux-low.c (usr_store_inferior_registers): Factor out code
13616 to handle individual registers into...
13617 (store_register): ... this new function.
13618
c642a434
UW
136192011-12-06 Ulrich Weigand <uweigand@de.ibm.com>
13620
13621 * Makefile.in (s390-linux32v1.o, s390-linux32v1.c): New rules.
13622 (s390-linux32v2.o, s390-linux32v2.c): Likewise.
13623 (s390-linux64v1.o, s390-linux64v1.c): Likewise.
13624 (s390-linux64v2.o, s390-linux64v2.c): Likewise.
13625 (s390x-linux64v1.o, s390x-linux64v1.c): Likewise.
13626 (s390x-linux64v2.o, s390x-linux64v2.c): Likewise.
13627 * configure.srv [s390*-*-linux*] (srv_regobj): Add new objects.
13628 (srv_xmlfiles): Add new XML files.
13629
13630 * linux-s390-low.c: Include "elf/common.h", <sys/ptrace.h>,
13631 and <sys/uio.h>.
13632 (PTRACE_GETREGSET, PTRACE_SETREGSET): Define if undefined.
13633 (init_registers_s390_linux32v1): Add prototype.
13634 (init_registers_s390_linux32v2): Likewise.
13635 (init_registers_s390_linux64v1): Likewise.
13636 (init_registers_s390_linux64v2): Likewise.
13637 (init_registers_s390x_linux64v1): Likewise.
13638 (init_registers_s390x_linux64v2): Likewise.
13639 (s390_num_regs): Increment to 52.
13640 (s390_regmap): Add orig_r2 register.
13641 (s390_num_regs_3264): Increment to 68.
13642 (s390_regmap_3264): Add orig_r2 register.
13643 (s390_collect_ptrace_register): Handle orig_r2 register.
13644 (s390_supply_ptrace_register): Likewise.
13645 (s390_fill_last_break): New function.
13646 (s390_store_last_break): Likewise.
13647 (s390_fill_system_call): New function.
13648 (s390_store_system_call): Likewise.
13649 (target_regsets): Handle NT_S390_LAST_BREAK and NT_S390_SYSTEM_CALL
13650 register sets.
13651 (s390_check_regset): New function.
13652 (s390_arch_setup): Check for presence of NT_S390_LAST_BREAK and
13653 NT_S390_SYSTEM_CALL regsets and use appropriate description.
13654 Update target_regsets for available register sets.
13655
2268b414
JK
136562011-12-02 Paul Pluzhnikov <ppluzhnikov@google.com>
13657 Jan Kratochvil <jan.kratochvil@redhat.com>
13658
13659 * linux-low.c (get_phdr_phnum_from_proc_auxv, get_dynamic, get_r_debug)
13660 (read_one_ptr, struct link_map_offsets, linux_qxfer_libraries_svr4):
13661 New.
13662 (struct linux_target_ops): Install linux_qxfer_libraries_svr4.
13663 * linux-low.h (struct process_info_private): New member r_debug.
13664 * server.c (handle_qxfer_libraries): Call
13665 the_target->qxfer_libraries_svr4.
13666 (handle_qxfer_libraries_svr4): New function.
13667 (qxfer_packets): New entry "libraries-svr4".
13668 (handle_query): Check QXFER_LIBRARIES_SVR4 and report libraries-svr4.
13669 * target.h (struct target_ops): New member qxfer_libraries_svr4.
13670 * remote.c (remote_xfer_partial): Call add_packet_config_cmd for
13671 PACKET_qXfer_libraries_svr4.
13672
d6db1fab
UW
136732011-11-30 Ulrich Weigand <uweigand@de.ibm.com>
13674
13675 * linux-s390-low.c (s390_collect_ptrace_register): Fully convert
13676 PSW address/mask between 8-byte and 16-byte formats.
13677 (s390_supply_ptrace_register): Likewise.
13678 (s390_get_pc, s390_set_pc): 4-byte PSW address always includes
13679 basic addressing mode bit.
13680
242f5f1c
SS
136812011-11-24 Stan Shebs <stan@codesourcery.com>
13682
13683 * tracepoint.c (cmd_qtstatus): Use plongest instead of %llx.
13684
f196051f
SS
136852011-11-17 Stan Shebs <stan@codesourcery.com>
13686
13687 * tracepoint.c (struct tracepoint): New field traceframe_usage.
13688 (tracing_start_time): New global.
13689 (tracing_stop_time): New global.
13690 (tracing_user_name): New global.
13691 (tracing_notes): New global.
13692 (tracing_stop_note): New global.
13693 (cmd_qtstart): Set traceframe_usage, start_time.
13694 (stop_tracing): Set stop_time.
13695 (cmd_qtstatus): Report additional status.
13696 (cmd_qtp): New function.
13697 (handle_tracepoint_query): Call it.
13698 (cmd_qtnotes): New function.
13699 (handle_tracepoint_general_set): Call it.
13700 (get_timestamp): Rename from tsv_get_timestamp.
13701
405f8e94
SS
137022011-11-14 Stan Shebs <stan@codesourcery.com>
13703 Kwok Cheung Yeung <kcy@codesourcery.com>
13704
13705 * linux-x86-low.c (small_jump_insn): New.
13706 (i386_install_fast_tracepoint_jump_pad): Add arguments for
13707 trampoline and error message, build a trampoline and issue a small
13708 jump instruction to it.
13709 (x86_install_fast_tracepoint_jump_pad): Add arguments for
13710 trampoline and error message.
13711 (x86_get_min_fast_tracepoint_insn_len): New.
13712 (the_low_target): Add call to x86_get_min_fast_tracepoint_insn_len.
13713 * linux-low.h (struct linux_target_ops): Add arguments to
13714 install_fast_tracepoint_jump_pad operation, add new operation.
13715 * linux-low.c (linux_install_fast_tracepoint_jump_pad): Add
13716 arguments.
13717 (linux_get_min_fast_tracepoint_insn_len): New function.
13718 (linux_target_op): Add new operation.
13719 * tracepoint.c (gdb_trampoline_buffer): New IPA variable.
13720 (gdb_trampoline_buffer_end): Ditto.
13721 (gdb_trampoline_buffer_error): Ditto.
13722 (struct ipa_sym_addresses): Add fields for new IPA variables.
13723 (symbol_list): Add entries for new IPA variables.
13724 (struct tracepoint): Add fields to hold the address range of the
13725 trampoline used by the tracepoint.
13726 (trampoline_buffer_head): New static variable.
13727 (trampoline_buffer_tail): Ditto.
13728 (claim_trampoline_space): New function.
13729 (have_fast_tracepoint_trampoline_buffer): New function.
13730 (clone_fast_tracepoint): Fill in trampoline fields of tracepoint
13731 structure.
13732 (install_fast_tracepoint): Ditto, also add error buffer argument.
13733 (cmd_qtminftpilen): New function.
13734 (handle_tracepoint_query): Add response to qTMinFTPILen packet.
13735 (fast_tracepoint_from_trampoline_address): New function.
13736 (fast_tracepoint_collecting): Handle trampoline as part of jump
13737 pad space.
13738 (set_trampoline_buffer_space): New function.
13739 (initialize_tracepoint): Initialize new IPA variables.
13740 * target.h (struct target_ops): Add arguments to
13741 install_fast_tracepoint_jump_pad operation, add new
13742 get_min_fast_tracepoint_insn_len operation.
13743 (target_get_min_fast_tracepoint_insn_len): New.
13744 (install_fast_tracepoint_jump_pad): Add arguments.
13745 * server.h (IPA_BUFSIZ): Define.
13746 * linux-i386-ipa.c: Include extra header files.
13747 (initialize_fast_tracepoint_trampoline_buffer): New function.
13748 (initialize_low_tracepoint): Call it.
13749 * server.h (set_trampoline_buffer_space): Declare.
13750 (claim_trampoline_space): Ditto.
13751 (have_fast_tracepoint_trampoline_buffer): Ditto.
13752
1e4d1764
YQ
137532011-11-14 Yao Qi <yao@codesourcery.com>
13754
13755 * server.c (handle_query): Handle InstallInTrace for qSupported.
13756 * tracepoint.c (add_tracepoint): Sort list.
13757 (install_tracepoint, download_tracepoint): New.
13758 (cmd_qtdp): Call them to install and download tracepoints.
13759 (sort_tracepoints): Removed.
13760 (cmd_qtstart): Update.
13761
5c73ff4e
YQ
137622011-11-14 Yao Qi <yao@codesourcery.com>
13763
13764 * mem-break.c (inc_ref_fast_tracepoint_jump): New.
13765 * mem-break.h: Declare.
13766 * tracepoint.c (cmd_qtstart): Move some code to ...
13767 (clone_fast_tracepoint, install_fast_tracepoint): ... here.
13768 New.
13769 (download_tracepoints): Move some code to ...
13770 (download_tracepoint_1): ... here. New.
13771
86a30030
YQ
137722011-11-08 Yao Qi <yao@codesourcery.com>
13773
13774 * remote-utils.c (relocate_instruction): A comment fix.
13775
8d26e50c
JB
137762011-11-07 Joel Brobecker <brobecker@adacore.com>
13777
13778 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): Delete.
13779 (i386_dr_low_get_control, i386_dr_low_get_status): Use
13780 dr_status_mirror and dr_control_mirror from debug_reg_state.
13781 (i386_dr_low_get_status): Use debug_reg_state.dr_status_mirror
13782 (i386_initial_stuff): Remove use of deleted globals.
13783 (i386_get_thread_context, i386_set_thread_context,
13784 i386_thread_added): Use dr_status_mirror and dr_control_mirror
13785 from debug_reg_state.
13786
a59306a3
YQ
137872011-11-05 Yao Qi <yao@codesourcery.com>
13788
13789 * tracepoint.c (gdb_collect): Loop over tracepoints of same
13790 address as TPOINT's.
13791
3065dfb6
SS
137922011-11-02 Stan Shebs <stan@codesourcery.com>
13793
13794 * tracepoint.c (agent_mem_read_string): New function.
13795 (eval_agent_expr): Call it for tracenz.
13796 * server.c (handle_query): Report support for tracenz.
13797
fd0d8c7c
YQ
137982011-11-02 Yao Qi <yao@codesourcery.com>
13799
13800 * tracepoint.c (cmd_qtstart): Remove unused local variables.
13801
609086b1
YQ
138022011-11-02 Yao Qi <yao@codesourcery.com>
13803
13804 * target.h: Fix a typo in comment.
13805
b9fd1791
PA
138062011-10-31 Pedro Alves <pedro@codesourcery.com>
13807
13808 * mem-break.c (check_mem_write): Add `myaddr' parameter. Don't
13809 clobber the breakpoints' shadows with fast tracepoint jumps.
13810 * mem-break.h (check_mem_write): Add `myaddr' parameter.
13811 * target.c (write_inferior_memory): Also pass MYADDR down to
13812 check_mem_write.
13813
03583c20
UW
138142011-10-07 Ulrich Weigand <ulrich.weigand@linaro.org>
13815
13816 * configure.ac: Check support for personality routine.
13817 * configure: Regenerate.
13818 * config.in: Likewise.
13819 * linux-low.c: Include <sys/personality.h>.
13820 Define ADDR_NO_RANDOMIZE if necessary.
13821 (linux_create_inferior): Disable address space randomization when
13822 forking inferior, if requested.
13823 (linux_supports_disable_randomization): New function.
13824 (linux_target_ops): Install it.
13825 * server.h (disable_randomization): Declare.
13826 * server.c (disable_randomization): New global variable.
13827 (handle_general_set): Handle QDisableRandomization.
13828 (handle_query): Likewise for qSupported.
13829 (main): Support --disable-randomization and --no-disable-randomization
13830 command line arguments.
13831 * target.h (struct target_ops): Add supports_disable_randomization.
13832 (target_supports_disable_randomization): New macro.
13833
723b724b
MF
138342011-09-29 Mike Frysinger <vapier@gentoo.org>
13835
13836 * linux-low.c (target_loadseg): Add defined PTRACE_GETFDPIC to the
13837 ifdef check.
13838 [PT_GETDSBT] (target_loadmap): Wrap in a defined PT_GETDSBT check.
13839 [!PT_GETDSBT] (target_loadmap): New definition.
13840 (LINUX_LOADMAP, LINUX_LOADMAP_EXEC, LINUX_LOADMAP_INTERP): Define.
13841 (linux_read_loadmap): Change PTRACE_GETDSBT_EXEC to
13842 LINUX_LOADMAP_EXEC, PTRACE_GETDSBT_INTERP to LINUX_LOADMAP_INTERP,
13843 and PT_GETDSBT to LINUX_LOADMAP.
13844 [!PT_GETDSBT] (linux_read_loadmap): Define to NULL.
13845 (linux_target_ops): Delete unnecessary ifdef PT_GETDSBT check.
13846
55329a5c 138472011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
71487fd7
UW
13848
13849 * linux-arm-low.c (struct arm_linux_hwbp_cap): Remove.
13850 (arm_linux_hwbp_cap): New static variable.
13851 (arm_linux_get_hwbp_cap): Replace by ...
13852 (arm_linux_init_hwbp_cap): ... this new function.
13853 (arm_linux_get_hw_breakpoint_count): Use arm_linux_hwbp_cap.
13854 (arm_linux_get_hw_watchpoint_count): Likewise.
13855 (arm_linux_get_hw_watchpoint_max_length): Likewise.
13856 (arm_arch_setup): Call arm_linux_init_hwbp_cap.
13857 (arm_prepare_to_resume): Use perror_with_name instead of error.
13858
55329a5c 138592011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
09b4ad9f
UW
13860
13861 * linux-arm-low.c: Include <signal.h>.
13862 (PTRACE_GETHBPREGS, PTRACE_SETHBPREGS): Define if necessary.
13863 (struct arm_linux_hwbp_cap): New data type.
13864 (arm_hwbp_type, arm_hwbp_control_t): New typedefs.
13865 (struct arm_linux_hw_breakpoint): New data type.
13866 (MAX_BPTS, MAX_WPTS): Define.
13867 (struct arch_process_info, struct arch_lwp_info): New data types.
13868 (arm_linux_get_hwbp_cap): New function.
13869 (arm_linux_get_hw_breakpoint_count): Likewise.
13870 (arm_linux_get_hw_watchpoint_count): Likewise.
13871 (arm_linux_get_hw_watchpoint_max_length): Likewise.
13872 (arm_hwbp_control_initialize): Likewise.
13873 (arm_hwbp_control_is_enabled): Likewise.
13874 (arm_hwbp_control_is_initialized): Likewise.
13875 (arm_hwbp_control_disable): Likewise.
13876 (arm_linux_hw_breakpoint_equal): Likewise.
13877 (arm_linux_hw_point_initialize): Likewise.
13878 (struct update_registers_data): New data structure.
13879 (update_registers_callback: New function.
13880 (arm_insert_point): Likewise.
13881 (arm_remove_point): Likewise.
13882 (arm_stopped_by_watchpoint): Likewise.
13883 (arm_stopped_data_address): Likewise.
13884 (arm_new_process): Likewise.
13885 (arm_new_thread): Likewise.
13886 (arm_prepare_to_resume): Likewise.
13887 (the_low_target): Register arm_insert_point, arm_remove_point,
13888 arm_stopped_by_watchpoint, arm_stopped_data_address, arm_new_process,
13889 arm_new_thread, and arm_prepare_to_resume.
13890
6b9801d4
SS
138912011-09-15 Stan Shebs <stan@codesourcery.com>
13892
13893 * server.h (struct emit_ops): Add compare-goto fields.
13894 * tracepoint.c (gdb_agent_op_sizes): New table.
13895 (emit_eq_goto): New function.
13896 (emit_ne_goto): New function.
13897 (emit_lt_goto): New function.
13898 (emit_le_goto): New function.
13899 (emit_gt_goto): New function.
13900 (emit_ge_goto): New function.
13901 (is_goto_target): New function.
13902 (compile_bytecodes): Recognize special cases of compare-goto
13903 combinations and call specialized emitters for them.
13904 * linux-x86-low.c (amd64_emit_eq_goto): New function.
13905 (amd64_emit_ne_goto): New function.
13906 (amd64_emit_lt_goto): New function.
13907 (amd64_emit_le_goto): New function.
13908 (amd64_emit_gt_goto): New function.
13909 (amd64_emit_ge_goto): New function.
13910 (amd64_emit_ops): Add the new functions.
13911 (i386_emit_eq_goto): New function.
13912 (i386_emit_ne_goto): New function.
13913 (i386_emit_lt_goto): New function.
13914 (i386_emit_le_goto): New function.
13915 (i386_emit_gt_goto): New function.
13916 (i386_emit_ge_goto): New function.
13917 (i386_emit_ops): Add the new functions.
13918
bf15cbda
SS
139192011-09-08 Stan Shebs <stan@codesourcery.com>
13920
13921 * linux-x86-low.c (i386_emit_prologue): Save %ebx.
13922 (i386_emit_epilogue): Restore %ebx.
13923
943ca1dd
JZ
139242011-08-31 Jie Zhang <jzhang918@gmail.com>
13925
13926 * server.c (step_thread): Remove definition.
13927 (process_serial_event): Don't handle Hs.
13928 * server.h (step_thread): Remove declaration.
13929 * target.c (set_desired_inferior): Remove use of step_thread.
13930
e3deef73
LM
139312011-08-24 Luis Machado <lgustavo@codesourcery.com>
13932
13933 * linux-low.c: Include linux-procfs.h.
13934 (linux_attach_lwp_1): Update comments.
13935 (linux_attach): Scan for existing threads when attaching to a
13936 process that is the tgid.
13937 * Makefile.in: Update dependencies.
13938
13da1c97
LM
139392011-08-24 Luis Machado <lgustavo@codesourcery.com>
13940
13941 * configure.srv: Add linux-procfs.o dependencies.
13942
881127c9
YQ
139432011-08-14 Yao Qi <yao@codesourcery.com>
13944
13945 * target.h (struct target_ops): Fix indent.
13946 * win32-low.c (win32_target_ops): Fix comment.
13947
58dbd541
YQ
139482011-08-14 Andrew Jenner <andrew@codesourcery.com>
13949 Yao Qi <yao@codesourcery.com>
13950
13951 * Makefile.in (clean): Remove tic6x-*.c files.
13952 (linux-tic6x-low.o, tic6x-c62x-linux.o, tic6x-c64x-linux.o): New rules.
13953 (tic6x-c64xp-linux.o, tic6x-c62x-linux.c, tic6x-c64x-linux.c): Likewise.
13954 (tic6x-c64xp-linux.c): Likewise.
13955 * configure.srv: Add support for tic6x-*-uclinux.
13956 * linux-tic6x-low.c: New.
13957 * linux-low.c (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define.
13958
78d85199
YQ
139592011-08-14 Andrew Stubbs <ams@codesourcery.com>
13960 Yao Qi <yao@codesourcery.com>
13961
13962 * target.h (struct target_ops): Add read_loadmap.
13963 * linux-low.c (struct target_loadseg): New type.
13964 (struct target_loadmap): New type.
13965 (linux_read_loadmap): New function.
13966 (linux_target_ops): Add linux_read_loadmap.
13967 * server.c (handle_query): Support qXfer:fdpic:read packet.
43aaf8b6
PA
13968 * win32-low.c (win32_target_ops): Initialize field `read_loadmap'
13969 to NULL.
78d85199 13970
a959a88d
EZ
139712011-08-05 Eli Zaretskii <eliz@gnu.org>
13972
13973 * win32-low.c: Include <stdint.h>.
13974
1ced966e
PA
139752011-07-22 Pedro Alves <pedro@codesourcery.com>
13976
13977 * i386-low.c (i386_insert_aligned_watchpoint): Don't pass the info
13978 to the inferior here.
13979 (i386_remove_aligned_watchpoint): Ditto.
13980 (i386_handle_nonaligned_watchpoint): Return immediate on fail to
13981 fit part of the watchpoint in the debug registers.
13982 (i386_update_inferior_debug_regs): New.
13983 (i386_low_insert_watchpoint): Work on a local mirror of the debug
13984 registers, and only update the inferior on success.
13985 (i386_low_remove_watchpoint): Ditto.
13986
d26e3629
KY
139872011-07-22 Kwok Cheung Yeung <kcy@codesourcery.com>
13988
13989 * linux-low.c (compare_ints, unique, list_threads, show_process,
13990 linux_core_of_thread): Delete.
13991 (linux_target_ops): Change linux_core_of_thread to
13992 linux_common_core_of_thread.
13993 (linux_qxfer_osdata): Defer to linux_common_xfer_osdata.
13994 * utils.c (malloc_failure): Change type of argument.
13995 (xmalloc, xrealloc, xcalloc, xsnprintf): Delete.
13996 * Makefile.in (SFILES): Add common/common-utils.c, common/xml-utils.c,
13997 common/linux-osdata.c, common/ptid.c and common/buffer.c.
13998 (OBS): Add xml-utils.o, common-utils.o, ptid.o and buffer.o.
13999 (IPA_OBJS): Add common-utils-ipa.o.
14000 (ptid_h, linux_osdata_h): New macros.
14001 (server_h): Add common/common-utils.h, common/xml-utils.h,
14002 common/buffer.h, common/gdb_assert.h, common/gdb_locale.h and
14003 common/ptid.h.
14004 (common-utils-ipa.o, common-utils.o, xml-utils.o, linux-osdata.o,
14005 ptid.o, buffer.o): New rules.
14006 (linux-low.o): Add common/linux-osdata.h as a dependency.
14007 * configure.srv (srv_tgtobj): Add linux-osdata.o to Linux targets.
14008 * configure.ac: Add AC_HEADER_DIRENT check.
14009 * config.in: Regenerate.
14010 * configure: Regenerate.
14011 * remote-utils.c (xml_escape_text): Delete.
14012 (buffer_grow, buffer_free, buffer_init, buffer_finish,
14013 buffer_xml_printf): Move to common/buffer.c.
14014 * server.c (main): Remove call to initialize_inferiors.
14015 * server.h (struct ptid, ptid_t, minus_one_ptid, null_ptid,
14016 ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp, ptid_get_tid,
14017 ptid_equal, ptid_is_pid, initialize_inferiors, xml_escape_text,
14018 internal_error, gdb_assert, gdb_assert_fail): Delete.
14019 (struct buffer, buffer_grow, buffer_free, buffer_init, buffer_finish,
14020 buffer_xml_printf, buffer_grow_str, buffer_grow_str0): Move to
14021 common/buffer.h.
14022 * inferiors.c (null_ptid, minus_one_ptid, ptid_build, pid_to_ptid,
14023 ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal, ptid_is_pid,
14024 initialize_inferiors): Delete.
14025
2275a1a7
PA
140262011-07-20 Pedro Alves <pedro@codesourcery.com>
14027
14028 * tracepoint.c (tracepoint_look_up_symbols): Return upon the first
14029 symbol error.
14030
0a5b1e09
PA
140312011-05-31 Pedro Alves <pedro@codesourcery.com>
14032
14033 * linux-x86-low.c (i386_dr_low_get_addr): Fix off by one in
14034 assertion.
14035 * win32-i386-low.c (i386_dr_low_get_addr): Ditto.
14036
6938fd34
YQ
140372011-05-26 Yao Qi <yao@codesourcery.com>
14038
14039 * Makefile.in (thread-db.o): Track dependence to
14040 common/gdb_thread_db.h.
14041 * thread-db.c: include gdb_thread_db.h from right place.
14042
b481f9e0
TT
140432011-05-16 Adrian Cornish <gnu@bluedreamer.com>
14044
14045 * linux-i386-ipa.c (supply_static_tracepoint_registers): Pass
14046 __FILE__ and __LINE__ to internal_error.
14047
98a5dd13
DE
140482011-05-13 Doug Evans <dje@google.com>
14049
14050 * thread-db.c (try_thread_db_load_from_sdir): New function.
14051 (try_thread_db_load_from_dir): New function.
14052 (thread_db_load_search): Handle $sdir, ignore $pdir.
14053 Remove trying of system directories if search of
14054 libthread-db-search-path fails, that is now done via $sdir.
14055
d248b706
KY
140562011-05-12 Kwok Cheung Yeung <kcy@codesourcery.com>
14057
14058 * server.c (handle_query): Add EnableDisableTracepoints to the list
14059 of supported features.
43aaf8b6 14060 * tracepoint.c (clear_installed_tracepoints): Uninstall disabled
d248b706 14061 tracepoints.
43aaf8b6
PA
14062 (cmd_qtenable_disable): New.
14063 (cmd_qtstart): Install tracepoints even if disabled.
14064 (handle_tracepoint_general_set): Add call to cmd_qtenable_disable on
14065 receiving a QTEnable or QTDisable packet.
14066 (gdb_collect): Skip data collection if fast tracepoint is disabled.
14067 (ust_marker_to_static_tracepoint): Do not ignore disabled static
14068 tracepoints.
14069 (gdb_probe): Skip data collection if static tracepoint is disabled.
d248b706 14070
84e578fb
DE
140712011-05-10 Doug Evans <dje@google.com>
14072
14073 * thread-db.c (thread_db_handle_monitor_command): Handle elided path.
14074
71f55dd8
DE
140752011-05-04 Doug Evans <dje@google.com>
14076
14077 * linux-low.c (linux_join): Skip process lookup.
14078 * spu-low.c (spu_join): Ditto.
14079 * server.c (join_inferiors_callback): Delete.
14080 (process_serial_event): For 'D' packet (detach) call join_inferior
14081 directly.
14082
4d393d60
JM
140832011-05-04 Joseph Myers <joseph@codesourcery.com>
14084
14085 * README: Don't mention xscale*-*-linux*.
14086 * configure.srv (xscale*-*-linux*): Don't handle target.
14087
b00ad6ff
NF
140882011-04-27 Nathan Froyd <froydnj@codesourcery.com>
14089
14090 * linux-x86-low.c (amd64_emit_const): Call memcpy instead of
14091 casting pointers.
14092 (amd64_emit_reg, amd64_emit_int_call_1, amd64_emit_void_call_2):
14093 (i386_emit_const, i386_emit_reg, i386_emit_int_call_1):
14094 (i386_emit_void_call_2): Likewise.
14095
af96c192
YQ
140962011-04-26 Yao Qi <yao@codesourcery.com>
14097
43aaf8b6
PA
14098 * linux-low.c: Move common macros to linux-ptrace.h.
14099 Include linux-ptrace.h.
af96c192
YQ
14100 * Makefile.in (linux_ptrace_h): New.
14101 (linux-low.o): Depends on linux-ptrace.h.
14102
03f2bd59
JK
141032011-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
14104
14105 * remote-utils.c (handle_accept_event): Close LISTEN_DESC only if
14106 RUN_ONCE. Comment for the LISTEN_DESC delete_file_handler call.
14107 (remote_prepare): New function with most of the TCP code from ...
14108 (remote_open): ... here. Detect PORT here unconditionally. Move also
14109 setting transport_is_reliable.
14110 * server.c (run_once): New variable.
14111 (gdbserver_usage): Document it.
14112 (main): Set run_once for `--once'. Call remote_prepare. Exit after
14113 the first run if RUN_ONCE.
14114 * server.h (run_once, remote_prepare): New declarations.
14115
7a9dd1b2
TT
141162011-04-19 Tom Tromey <tromey@redhat.com>
14117
14118 * win32-low.c (handle_load_dll): Remove duplicate "the".
14119
81239425
PM
141202011-04-07 Pierre Muller <muller@ics.u-strasbg.fr>
14121
14122 Remove support for old Cygwin 1.5 versions.
14123 * win32-low.c (win32_create_inferior): Use new cygwin_path_list
14124 function to avoid warning.
14125 (win32_add_one_solib): Use cygwin_conv_path function to avoid
14126 warning.
14127
9e0627f1
PM
141282011-03-18 Pierre Muller <muller@ics.u-strasbg.fr>
14129
14130 * gdbserver/server.h (Macro _): Define it if not available.
14131
588eebee
MS
141322011-03-14 Michael Snyder <msnyder@vmware.com>
14133
348af9f7 14134 * hostio.c (handle_close): Remove unnecessary null test.
588eebee 14135
43f70d4c
JB
141362011-03-10 Joel Brobecker <brobecker@adacore.com>
14137
14138 * Makefile.in (maintainer-clean realclean distclean): Remove
14139 "make ... subdir_do" command.
14140
348af9f7
MS
141412011-03-10 Michael Snyder <msnyder@vmware.com>
14142
14143 * tracepoint.c (tracepoint_finish_step): Fix loop variable.
14144
14145 * server.c (handle_v_run): Free alloced buffer on early return.
14146
e637a4f5
YQ
141472011-03-09 Yao Qi <yao@codesourcery.com>
14148
14149 Revert:
14150 2011-03-04 Yao Qi <yao@codesourcery.com>
14151
14152 * Makefile.in: Remove GNU make feature --directory.
14153
14154 2011-03-05 Yao Qi <yao@codesourcery.com>
14155
14156 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
14157 (subdir_do): New make target. Copied from gdb/Makefile.
14158 (maintainer-clean, realclean, distclean, clean): Call corresponding
14159 make targets in common/Makefile.
14160
14161 2011-02-11 Yao Qi <yao@codesourcery.com>
14162
14163 * configure.ac: Call AC_PROG_RANLIB.
14164 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
14165 * configure: Regenerate.
14166
e6edda56
JK
141672011-03-07 Jan Kratochvil <jan.kratochvil@redhat.com>
14168
14169 * remote-utils.c (putpkt_binary_1): Calculate BUF2 size dynamically.
14170
e5141119
JB
141712011-03-06 Yao Qi <yao@codesourcery.com>
14172
14173 * Makefile.in (REQUIRED_SUBDIRS): Remove $(LIBCOMMON_DIR).
14174
64794aa4
JB
141752011-03-05 Yao Qi <yao@codesourcery.com>
14176
14177 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
14178 (subdir_do): New make target. Copied from gdb/Makefile.
14179 (maintainer-clean, realclean, distclean, clean): Call corresponding
14180 make targets in common/Makefile.
14181
7a762829
YQ
141822011-03-04 Yao Qi <yao@codesourcery.com>
14183
14184 * Makefile.in: Remove GNU make feature --directory.
14185
348af9f7
MS
141862011-03-04 Michael Snyder <msnyder@vmware.com>
14187
14188 * server.c (queue_stop_reply): Call xmalloc not malloc.
14189
141902011-03-02 Michael Snyder <msnyder@vmware.com>
14191
14192 * linux-arm-low.c (arm_arch_setup): Replace malloc with xmalloc.
14193
9f72fee2
MS
141942011-02-28 Michael Snyder <msnyder@vmware.com>
14195
588eebee
MS
14196 * tracepoint.c (cmd_qtv): Discard unused value 'packet'.
14197 (cmd_qtframe): Ditto.
14198 (cmd_qtbuffer): Ditto.
14199 (cmd_bigqtbuffer): Ditto.
14200
9f72fee2
MS
14201 * utils.c (decimal2str): Initialize 'width' to nine, then
14202 don't mess with it.
14203
8040bd49
UW
142042011-02-28 Ulrich Weigand <uweigand@de.ibm.com>
14205
14206 * hostio.c (require_data): Free *data, not data.
14207
7e52cbd0
JK
142082011-02-28 Jan Kratochvil <jan.kratochvil@redhat.com>
14209
14210 * hostio.c (require_data): Use free, not xfree.
14211
9130f83e
MS
142122011-02-27 Michael Snyder <msnyder@vmware.com>
14213
4b812f4e
MS
14214 * server.c (handle_query): Discard unused value.
14215
9130f83e
MS
14216 * hostio.c (require_data): Free malloc memory before returning
14217 error.
14218
69d37113
MS
142192011-02-26 Michael Snyder <msnyder@vmware.com>
14220
14221 * linux-low.c (list_threads): Call closedir for dirent.
14222
35f5825a
MS
142232011-02-27 Michael Snyder <msnyder@vmware.com>
14224
2a589cef
MS
14225 * i386-low.c (i386-length_and_rw_bits): Comment the fact that
14226 a case statement falls through.
14227
0adea5f7
MS
14228 * linux-low.c (linux_xfer_siginfo): Fix fencepost error.
14229
35f5825a
MS
14230 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Fix fencepost error
14231 in comparison.
14232
238f1c74
MS
142332011-02-26 Michael Snyder <msnyder@vmware.com>
14234
14235 * utils.c (decimal2str): Eliminate dead code and dead param.
14236 (pulongest): Drop dead param from call to decimal2str.
14237 (plongest): Ditto.
14238
633ff500
JB
142392011-02-24 Joel Brobecker <brobecker@adacore.com>
14240
14241 Revert the following patch (not approved yet):
14242 2011-02-21 Hui Zhu <teawater@gmail.com>
14243 * tracepoint.c (tp_printf): New function.
14244 (eval_agent_expr): Handle gdb_agent_op_printf.
14245
f9c6ff72
HZ
142462011-02-21 Hui Zhu <teawater@gmail.com>
14247
14248 * tracepoint.c (tp_printf): New function.
14249 (eval_agent_expr): Handle gdb_agent_op_printf.
14250
94d5e490
TT
142512011-02-18 Tom Tromey <tromey@redhat.com>
14252
14253 * Makefile.in (tracepoint-ipa.o): Depend on ax.def.
14254 (tracepoint.o): Likewise.
14255 * tracepoint.c (enum gdb_agent_op): Use ax.def.
14256 (gdb_agent_op_names): Likewise.
14257
c7f96d2b
TT
142582011-02-18 Tom Tromey <tromey@redhat.com>
14259
14260 * tracepoint.c (enum gdb_agent_op) <gdb_agent_op_pick,
14261 gdb_agent_op_rot>: New constants.
14262 (gdb_agent_op_names): Add pick and roll.
14263 (eval_agent_expr) <gdb_agent_op_pick, gdb_agent_op_rot>: New
14264 cases.
14265
0feedb2c
JK
142662011-02-15 Jan Kratochvil <jan.kratochvil@redhat.com>
14267
14268 * aclocal.m4: Regenerated with aclocal-1.11.1.
14269
b3b9301e
PA
142702011-02-14 Pedro Alves <pedro@codesourcery.com>
14271
14272 * server.c (handle_qxfer_traceframe_info): New.
14273 (qxfer_packets): Register "traceframe-info".
14274 (handle_query): Report support for qXfer:traceframe-info:read+.
14275 * tracepoint.c (match_blocktype): New.
14276 (traceframe_find_block_type): Rename to ...
14277 (traceframe_walk_blocks): ... this. Add callback filter argument,
14278 and use it.
14279 (traceframe_find_block_type): New, reimplemented on top of
14280 traceframe_walk_blocks.
14281 (build_traceframe_info_xml): New.
14282 (traceframe_read_info): New.
14283 * server.h (traceframe_read_info): Declare.
14284
4f3e6fb7
YQ
142852011-02-11 Yao Qi <yao@codesourcery.com>
14286
14287 * configure.ac: Call AC_PROG_RANLIB.
14288 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
14289 * configure: Regenerate.
14290
764880b7
PA
142912011-02-07 Pedro Alves <pedro@codesourcery.com>
14292
14293 * server.c (gdb_read_memory): Change return semantics to allow
14294 partial transfers.
14295 (handle_search_memory_1): Adjust.
14296 (process_serial_event) <'m' packet>: Handle partial transfers.
14297 * tracepoint.c (traceframe_read_mem): Handle partial transfers.
14298
1c79eb8a
PA
142992011-01-28 Pedro Alves <pedro@codesourcery.com>
14300
14301 * regcache.c (init_register_cache): Initialize
14302 regcache->register_status.
14303 (free_register_cache): Release regcache->register_status.
14304 (regcache_cpy): Copy register_status.
14305 (registers_to_string): Print 'x's for unavailable registers.
14306 (supply_register): Mark the register's status valid or
14307 unavailable, depending on whether a buffer was passed in or not.
14308 (supply_register_zeroed): New.
14309 (supply_regblock): Mark the registers' status valid or
14310 unavailable, depending on whether a buffer was passed in or not.
14311 * regcache.h (REG_UNAVAILABLE, REG_VALID): New defines.
14312 (struct regcache): New `register_status' field.
14313 (supply_register_zeroed): Declare.
14314 * i387-fp.c (i387_xsave_to_cache): Zero out registers using
14315 supply_register_zeroed, rather than passing a NULL buffer to
14316 supply_register.
14317 * tracepoint.c (fetch_traceframe_registers): Update comment.
14318
85724a0e
PA
143192011-01-28 Pedro Alves <pedro@codesourcery.com>
14320
14321 * i387-fp.c (i387_xsave_to_cache): Make passing NULL as register
14322 buffer explicit.
14323
d08aafef
PA
143242011-01-25 Pedro Alves <pedro@codesourcery.com>
14325
14326 * server.h (decode_xfer_write): Change prototype.
14327 * remote-utils.c (decode_xfer_write): Remove `annex' parameter,
14328 and don't extract the annex here.
14329 * server.c (decode_xfer_read): Remove `annex' parameter,
14330 and don't extract the annex here.
14331 (decode_xfer): New.
14332 (struct qxfer): New.
14333 (handle_qxfer_auxv, handle_qxfer_features, handle_qxfer_libraries)
14334 (handle_qxfer_osdata, handle_qxfer_siginfo, handle_qxfer_spu)
14335 (handle_qxfer_statictrace): New functions, abstracted out from
14336 handle_query, and made to use the struct qxfer interface.
14337 (handle_threads_qxfer_proper): Rename to ...
14338 (handle_qxfer_threads_proper): ... this.
14339 (handle_threads_qxfer): Rename to ...
14340 (handle_qxfer_threads): ... this. Adjust.
14341 (qxfer_packets): New array.
14342 (handle_qxfer): New function.
14343 (handle_query): Use handle_qxfer.
14344
493e2a69
MS
143452011-01-05 Michael Snyder <msnyder@msnyder-server.eng.vmware.com>
14346
14347 * gdbreplay.c: Shorten lines of >= 80 columns.
14348 * linux-low.c: Ditto.
14349 * linux-ppc-low.c: Ditto.
14350 * linux-s390-low.c: Ditto.
14351 * linux-sparc-low.c: Ditto.
14352 * linux-x86-low.c: Ditto.
14353 * linux-xtensa-low.c: Ditto.
14354 * mem-break.c: Ditto.
14355 * nto-low.c: Ditto.
14356 * regcache.h: Ditto.
14357 * remote-utils.c: Ditto.
14358 * server.c: Ditto.
14359 * server.h: Ditto.
14360 * thread-db.c: Ditto.
14361 * tracepoint.c: Ditto.
14362 * utils.c: Ditto.
14363 * win32-low.h: Ditto.
14364
44944448
JB
143652011-01-05 Joel Brobecker <brobecker@adacore.com>
14366
14367 * gdbserver/configure.ac, gdbserver/gdbserver.1: Copyright year
14368 update.
14369
71ce852c
JB
143702011-01-01 Joel Brobecker <brobecker@adacore.com>
14371
14372 * server.c (gdbserver_version): Update copyright year in version
14373 output.
14374 * gdbreplay.c (gdbreplay_version): Ditto.
14375
eb826dc6
MF
143762010-12-29 Jie Zhang <jie.zhang@analog.com>
14377
14378 * configure.srv (bfin-*-*linux*): Handle Blackfin/Linux targets.
14379 * linux-bfin-low.c: New file.
14380 * linux-low.c: Define PT_TEXT_ADDR, PT_TEXT_END_ADDR, and
14381 PT_DATA_ADDR for BFIN targets.
14382 * Makefile.in (SFILES): Add linux-bfin-low.c.
14383 (clean): Remove reg-bfin.c.
14384 (linux-bfin-low.o, reg-bfin.o, reg-bfin.c): New targets.
14385 * README: Mention supported Blackfin targets.
14386
39ab222a
MF
143872010-12-23 Mike Frysinger <vapier@gentoo.org>
14388
14389 * .gitignore: New file.
14390
a1f2ce7d
MF
143912010-11-16 Mike Frysinger <vapier@gentoo.org>
14392
14393 * linux-low.c (linux_tracefork_child): Add char* cast to arg.
14394
f474844c
JZ
143952010-10-22 Jie Zhang <jie@codesourcery.com>
14396
14397 * Makefile.in: Add FLAGS_TO_PASS variable.
14398 (install): Remove dependency of install-only and recursively
14399 invoke make for install-only.
14400
f1048712
DE
144012010-10-04 Doug Evans <dje@google.com>
14402
14403 * Makefile.in (uninstall): Use $(DESTDIR).
14404
b53a1623
PA
144052010-09-24 Pedro Alves <pedro@codesourcery.com>
14406
e6ee044d
PA
14407 PR gdb/11842
14408
b53a1623
PA
14409 * linux-x86-low.c (compat_siginfo_from_siginfo)
14410 (siginfo_from_compat_siginfo): Also copy si_pid and si_uid when
14411 si_code is < 0. Check for si_code == SI_TIMER before checking for
14412 si_code < 0.
14413
fa1bd1e4
JB
144142010-09-13 Joel Brobecker <brobecker@adacore.com>
14415
14416 * lynx-i386-low.c: New file.
14417 * configure.srv: Add handling of i[34567]86-*-lynxos* targets.
14418
47fac8f8
JB
144192010-09-13 Joel Brobecker <brobecker@adacore.com>
14420
14421 * lynx-low.c (ptrace_request_to_str): Remove handling for
14422 request values that have been removed in LynxOS 5.x.
14423
1adfc54d
JB
144242010-09-13 Joel Brobecker <brobecker@adacore.com>
14425
14426 * lynx-low.c, lynx-ppc-loc.c: Include <sys/ptrace.h> instead of
14427 <ptrace.h>
14428
c2a66c29
NS
144292010-09-09 Nathan Sidwell <nathan@codesourcery.com>
14430
14431 * configure.ac: Add --enable-inprocess-agent option.
14432 * configure: Rebuilt.
14433
32fcada3
YQ
144342010-09-06 Yao Qi <yao@codesourcery.com>
14435
14436 * linux-low.c (linux_kill): Remove unused variable.
14437 (linux_stabilize_threads): Likewise.
14438 * server.c (start_inferior): Likewise.
14439 (queue_stop_reply_callback): Likewise.
14440 * tracepoint.c (do_action_at_tracepoint): Likewise.
14441
0cccb683
YQ
144422010-09-06 Yao Qi <yao@codesourcery.com>
14443
14444 * linux-low.c (maybe_move_out_of_jump_pad): Restore current_inferior
14445 on return.
14446
423ec54c
JK
144472010-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
14448
14449 * target.c (mywait) <TARGET_WAITKIND_EXITED>: Fix to use INTEGER.
14450
12ac6819
PA
144512010-09-06 Pedro Alves <pedro@codesourcery.com>
14452
14453 * Makefile.in (install-only): Replace $IPA_DEPFILES with
14454 "$(IPA_DEPFILES)".
14455
8ed54b31
JB
144562010-09-01 Joel Brobecker <brobecker@adacore.com>
14457
14458 * gdbserver/lynx-low.c, gdbserver/lynx-low.h,
14459 gdbserver/lynx-ppc-low.c: New files.
14460 * Makefile.in (lynx_low_h): New variable.
14461 (lynx-low.o, lynx-ppc-low.o): New rules.
14462 * configure.ac: On LynxOS, link with -lnetinet.
14463 * configure.srv: Add handling of powerpc-*-lynxos* targets.
14464 * configure: regenerate.
14465
bb0116a4
JB
144662010-09-01 Joel Brobecker <brobecker@adacore.com>
14467
14468 * Makefile.in (vasprintf.o, vsnprintf.o): New rules.
14469 * configure.ac: Add check for vasprintf and vsnprintf.
14470 * configure, config.in: Regenerate.
14471 * server.h (vasprintf, vsnprintf): Add conditional declarations.
14472
a778ab81 144732010-09-01 Joel Brobecker <brobecker@adacore.com>
14474
14475 * gdbreplay.c: Move include of alloca.h up, next to include of
14476 malloc.h.
14477 * server.h: Add include of malloc.h.
14478 * mem-break.c: Remove include of malloc.h.
14479 * server.c, tracepoint.c, utils.c, win32-low.c: Likewise.
14480
8b034a19 144812010-09-01 Joel Brobecker <brobecker@adacore.com>
14482
14483 * Makefile.in (memmem.o): Build with -Wno-error.
14484
144852010-09-01 Joel Brobecker <brobecker@adacore.com>
14486
14487 * utils.c (xsnprintf): Make non-static.
14488 * server.h: Add xsnprintf declaration.
14489 * linux-low.c, nto-low.c, target.c, thread-db.c, tracepoint.c:
14490 replace calls to snprintf by calls to xsnprintf throughout.
14491
144922010-09-01 Joel Brobecker <brobecker@adacore.com>
14493
14494 * configure.ac: Add configure check for alloca.
14495 * configure, config.in: Regenerate.
14496 * server.h: Include alloca.h if it exists.
14497 * gdbreplay.c: Include alloca.h if it exists.
14498
1a981360
PA
144992010-08-28 Pedro Alves <pedro@codesourcery.com>
14500
14501 * linux-low.c (__SIGRTMIN): Define if not already defined.
14502 (linux_create_inferior): Check for __ANDROID__ rather than
14503 __SIGRTMIN.
14504 (enqueue_one_deferred_signal): Don't requeue non-RT signals that
14505 are already deferred.
14506 (linux_wait_1): Check for __ANDROID__ rather than __SIGRTMIN.
14507 (linux_resume_one_thread): Don't queue a SIGSTOP if the lwp is
14508 stopped and already has a pending signal to report.
14509 (proceed_one_lwp): : Don't queue a SIGSTOP if the lwp already has
14510 a pending signal to report or is moving out of a jump pad.
14511 (linux_init_signals): Check for __ANDROID__ rather than
14512 __SIGRTMIN.
14513
b4d51a55
PA
145142010-08-28 Pedro Alves <pedro@codesourcery.com>
14515
14516 * linux-low.c (linux_stabilize_threads): Wrap debug output in a
14517 debug_threads check. Avoid a linear search when not doing debug
14518 output.
14519
ec48365d
PA
145202010-08-27 Pedro Alves <pedro@codesourcery.com>
14521
14522 * event-loop.c (event_handle_func): Adjust to use gdb_fildes_t.
14523 (struct gdb_event) <fd>: Change type to gdb_fildes_t.
14524 (struct file_handler) <fd>: Change type to gdb_fildes_t.
14525 (process_event): Change local fd's type to gdb_fildes_t.
14526 (create_file_handler): Adjust prototype.
14527 (delete_file_handler): Adjust prototype.
14528 (handle_file_event): Adjust prototype. Use pfildes.
14529 (create_file_event): Adjsut prototype.
14530 * remote-utils.c (remote_desc, listen_desc): Change type to
14531 gdb_fildes_t.
14532 * server.h: New gdb_fildes_t typedef.
14533 [USE_WIN32API]: Include winsock2.h.
14534 (delete_file_handler, add_file_handler): Adjust prototypes.
14535 (pfildes): Declare.
14536 * utils.c (pfildes): New.
14537
854d88f0
PA
145382010-08-27 Pedro Alves <pedro@codesourcery.com>
14539
14540 * configure.ac (build_warnings): Add -Wno-char-subscripts.
14541 * configure: Regenerate.
14542
0146f85b
PA
145432010-08-27 Pedro Alves <pedro@codesourcery.com>
14544
14545 * linux-low.c (linux_unprepare_to_access_memory): Rename to ...
14546 (linux_done_accessing_memory): ... this.
14547 (linux_target_ops): Adjust.
14548 * linux-x86-low.c (x86_insert_point, x86_remove_point): Adjust.
14549 * nto-low.c (nto_target_ops): Adjust comment.
14550 * server.c (gdb_read_memory, gdb_write_memory): Adjust.
14551 * spu-low.c (spu_target_ops): Adjust comment.
14552 * target.h (target_ops): Rename unprepare_to_access_memory field
14553 to done_accessing_memory.
14554 (unprepare_to_access_memory): Rename to ...
14555 (done_accessing_memory): ... this.
14556
90d74c30
PA
145572010-08-26 Pedro Alves <pedro@codesourcery.com>
14558
14559 * linux-low.c (linux_prepare_to_access_memory): New.
14560 (linux_unprepare_to_access_memory): New.
14561 (linux_target_ops): Install them.
14562 * server.c (read_memory): Rename to ...
14563 (gdb_read_memory): ... this. Use
14564 prepare_to_access_memory/prepare_to_access_memory.
14565 (write_memory): Rename to ...
14566 (gdb_write_memory): ... this. Use
14567 prepare_to_access_memory/prepare_to_access_memory.
14568 (handle_search_memory_1): Adjust.
14569 (process_serial_event): Adjust.
14570 * target.h (struct target_ops): New fields
14571 prepare_to_access_memory and unprepare_to_access_memory.
14572 (prepare_to_access_memory, unprepare_to_access_memory): New.
14573 * linux-x86-low.c (x86_insert_point, x86_remove_point): Use
14574 prepare_to_access_memory/prepare_to_access_memory.
14575 * nto-low.c (nto_target_ops): Adjust.
14576 * spu-low.c (spu_target_ops): Adjust.
14577 * win32-low.c (win32_target_ops): Adjust.
14578
fd467969
PA
145792010-08-26 Pedro Alves <pedro@codesourcery.com>
14580
14581 * Makefile.in (WARN_CFLAGS): Get it from configure.
14582 (WERROR_CFLAGS): New.
14583 (INTERNAL_CFLAGS): Add WERROR_CFLAGS.
14584 * configure.ac: Introduce --enable-werror, which adds -Werror to
14585 the compiler command line. Enabled by default. Disable with
14586 --disable-werror. Add -Wdeclaration-after-statement
14587 Wpointer-arith and -Wformat-nonliteral to warning flags.
14588 * configure: Regenerate.
14589
331e2f5f
PA
145902010-08-26 Pedro Alves <pedro@codesourcery.com>
14591
14592 * mem-break.c [HAVE_MALLOC_H]: Include malloc.h.
14593
e581f2b4
PA
145942010-08-26 Pedro Alves <pedro@codesourcery.com>
14595
14596 * gdbreplay.c (remote_error): New.
14597 (gdbchar): New.
14598 (expect): Use gdbchar. Check for error reading from GDB.
14599 Clarify sync error output.
14600 (play): Check for errors writing to GDB.
14601 * linux-low.c (sigchld_handler): Really ignore `write' errors.
14602 * remote-utils.c (getpkt): Check for errors writing to the remote
14603 descriptor.
14604
3c11dd79
PA
146052010-08-25 Pedro Alves <pedro@codesourcery.com>
14606
14607 * linux-low.c (linux_wait_1): Move non-debugging code out of
14608 `debug_threads' control.
14609
d20a8ad9
PA
146102010-08-25 Pedro Alves <pedro@codesourcery.com>
14611
14612 * linux-low.c (linux_wait_1): Don't set last_status here.
14613 * server.c (push_event, queue_stop_reply_callback): Assert we're
14614 not pushing a TARGET_WAITKIND_IGNORE event.
14615 (start_inferior, start_inferior, attach_inferior, handle_v_cont)
14616 (myresume, handle_target_event): Set the thread's last_resume_kind
14617 and last_status from the target returned status.
14618
964e4306
PA
146192010-08-25 Pedro Alves <pedro@codesourcery.com>
14620
14621 PR threads/10729
14622
14623 * linux-x86-low.c (update_debug_registers_callback): New.
14624 (i386_dr_low_set_addr): Use it.
14625 (i386_dr_low_get_addr): New.
14626 (i386_dr_low_set_control): Use update_debug_registers_callback.
14627 (i386_dr_low_get_control): New.
14628 (i386_dr_low_get_status): Adjust.
14629 * linux-low.c (linux_stop_lwp): New.
14630 * linux-low.h (linux_stop_lwp): Declare.
14631
14632 * i386-low.c (I386_DR_GET_RW_LEN): Take the dr7 contents as
14633 argument instead of a i386_debug_reg_state.
14634 (I386_DR_WATCH_HIT): Take the dr6 contents as argument instead of
14635 a i386_debug_reg_state.
14636 (i386_insert_aligned_watchpoint): Adjust.
14637 (i386_remove_aligned_watchpoint): Adjust.
14638 (i386_low_stopped_data_address): Read the debug registers from the
14639 inferior instead of from the mirrors.
14640 * i386-low.h (struct i386_debug_reg_state): Extend comment.
14641 (i386_dr_low_get_addr): Declare.
14642 (i386_dr_low_get_control): Declare.
14643 (i386_dr_low_get_status): Change prototype.
14644
14645 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): New globals.
14646 (i386_dr_low_get_addr): New.
14647 (i386_dr_low_get_control): New.
14648 (i386_dr_low_get_status): Adjust prototype. Return
14649 dr_status_mirror.
14650 (i386_initial_stuff): Clear dr_status_mirror and
14651 dr_control_mirror.
14652 (i386_get_thread_context): Adjust.
14653 (i386_set_thread_context): Adjust.
14654 (i386_thread_added): Adjust.
14655
5f21a75b
PA
146562010-08-24 Pedro Alves <pedro@codesourcery.com>
14657
14658 * linux-low.h (linux_thread_area): Delete declaration.
14659
3e4c1235
TS
146602010-08-11 Thomas Schwinge <thomas@codesourcery.com>
14661
14662 * linux-low.c (linux_wait_1): Correctly return the ptid of the child
14663 after its termination.
14664
1971b033
PA
146652010-08-09 Pedro Alves <pedro@codesourcery.com>
14666
14667 * linux-low.c (gdb_wants_lwp_stopped): Delete.
14668 (gdb_wants_all_stopped): Delete.
14669 (linux_wait_1): Don't call them.
14670 * server.c (handle_v_cont): Tag all threads as want-stopped.
14671 (gdb_wants_thread_stopped): Fix comments. Tag the thread that
14672 stopped as "client-wants-stopped".
14673
310444ac
PA
146742010-07-31 Pedro Alves <pedro@codesourcery.com>
14675
14676 * Makefile.in (signals_h): New.
14677 (server_h): Depend on it.
14678 (server.o): Don't depend on $(signals_def).
14679 (signals.o): Depend on $(signals_def).
14680
a19cae16
JK
146812010-07-31 Jan Kratochvil <jan.kratochvil@redhat.com>
14682
14683 * Makefile.in (signals_def): New.
14684 (server_h): Append include/gdb/signals.h and signals_def.
14685 (server.o): Append signals_def.
14686
30d50328
JK
146872010-07-25 Jan Kratochvil <jan.kratochvil@redhat.com>
14688
14689 * server.c (handle_target_event): Use target_signal_to_host for
14690 resume_info.sig initialization.
14691 * target.h (struct thread_resume) <sig>: New comment.
14692
5c3216e2
OS
146932010-07-20 Ozkan Sezer <sezeroz@gmail.com>
14694
c6f46ca0
OS
14695 * server.c (handle_query): strcpy() the returned string from paddress()
14696 instead of sprintf().
5c3216e2
OS
14697 * utils.c (paddress): Return phex_nz().
14698
6bd31874
JB
146992010-07-07 Joel Brobecker <brobecker@adacore.com>
14700
14701 * server.c (handle_v_cont): Call mourn_inferior if process
14702 just exited.
14703 (myresume): Likewise.
14704
0fb4aa4b
PA
147052010-07-01 Pedro Alves <pedro@codesourcery.com>
14706
14707 Static tracepoints, and integration with UST.
14708
14709 * configure.ac: Handle --with-ust. substitute ustlibs and ustinc.
14710 * mem-break.c (uninsert_all_breakpoints)
14711 (reinsert_all_breakpoints): New.
14712 * mem-break.h (reinsert_all_breakpoints, uninsert_all_breakpoints):
14713 * tracepoint.c (ust_loaded, helper_thread_id, cmd_buf): New.
14714 (gdb_agent_ust_loaded, helper_thread_id)
14715 (gdb_agent_helper_thread_id): New macros.
14716 (struct ipa_sym_addresses): Add addr_ust_loaded,
14717 addr_helper_thread_id, addr_cmd_buf.
14718 (symbol_list): Add ust_loaded, helper_thread_id, cmd_buf.
14719 (in_process_agent_loaded_ust): New.
14720 (write_e_ust_not_loaded): New.
14721 (maybe_write_ipa_ust_not_loaded): New.
14722 (struct collect_static_trace_data_action): New.
14723 (enum tracepoint_type) <static_tracepoint>: New.
14724 (struct tracepoint) <handle>: Mention static tracepoints.
14725 (struct static_tracepoint_ctx): New.
14726 (CMD_BUF_SIZE): New.
14727 (add_tracepoint_action): Handle static tracepoint actions.
14728 (unprobe_marker_at): New.
14729 (clear_installed_tracepoints): Handle static tracepoints.
14730 (cmd_qtdp): Handle static tracepoints.
14731 (probe_marker_at): New.
14732 (cmd_qtstart): Handle static tracepoints.
14733 (response_tracepoint): Handle static tracepoints.
14734 (cmd_qtfstm, cmd_qtsstm, cmd_qtstmat): New.
14735 (handle_tracepoint_query): Handle qTfSTM, qTsSTM and qTSTMat.
14736 (get_context_regcache): Handle static tracepoints.
14737 (do_action_at_tracepoint): Handle static tracepoint actions.
14738 (traceframe_find_block_type): Handle static trace data blocks.
14739 (traceframe_read_sdata): New.
14740 (download_tracepoints): Download static tracepoint actions.
14741 [HAVE_UST] Include ust/ust.h, dlfcn.h, sys/socket.h, and sys/un.h.
14742 (GDB_PROBE_NAME): New.
14743 (ust_ops): New.
14744 (GET_UST_SYM): New.
14745 (USTF): New.
14746 (dlsym_ust): New.
14747 (ust_marker_to_static_tracepoint): New.
14748 (gdb_probe): New.
14749 (collect_ust_data_at_tracepoint): New.
14750 (gdb_ust_probe): New.
14751 (UNIX_PATH_MAX, SOCK_DIR): New.
14752 (gdb_ust_connect_sync_socket): New.
14753 (resume_thread, stop_thread): New.
14754 (run_inferior_command): New.
14755 (init_named_socket): New.
14756 (gdb_ust_socket_init): New.
14757 (cstr_to_hexstr): New.
14758 (next_st): New.
14759 (first_marker, next_marker): New.
14760 (response_ust_marker): New.
14761 (cmd_qtfstm, cmd_qtsstm): New.
14762 (unprobe_marker_at, probe_marker_at): New.
14763 (cmd_qtstmat, gdb_ust_thread): New.
14764 (gdb_ust_init): New.
14765 (initialize_tracepoint_ftlib): Call gdb_ust_init.
14766 * linux-amd64-ipa.c [HAVE_UST]: Include ust/processor.h
14767 (ST_REGENTRY): New.
14768 (x86_64_st_collect_regmap): New.
14769 (X86_64_NUM_ST_COLLECT_GREGS): New.
14770 (AMD64_RIP_REGNUM): New.
14771 (supply_static_tracepoint_registers): New.
14772 * linux-i386-ipa.c [HAVE_UST]: Include ust/processor.h
14773 (ST_REGENTRY): New.
14774 (i386_st_collect_regmap): New.
14775 (i386_NUM_ST_COLLECT_GREGS): New.
14776 (supply_static_tracepoint_registers): New.
14777 * server.c (handle_query): Handle qXfer:statictrace:read.
14778 <qSupported>: Report support for StaticTracepoints, and
14779 qXfer:statictrace:read features.
14780 * server.h (traceframe_read_sdata)
14781 (supply_static_tracepoint_registers): Declare.
14782 * remote-utils.c (convert_int_to_ascii, hexchars, ishex, tohex)
14783 (unpack_varlen_hex): Include in IPA build.
14784 * Makefile.in (ustlibs, ustinc): New.
14785 (IPA_OBJS): Add remote-utils-ipa.o.
14786 ($(IPA_LIB)): Link -ldl and -lpthread.
14787 (UST_CFLAGS): New.
14788 (IPAGENT_CFLAGS): Add UST_CFLAGS.
14789 * config.in, configure: Regenerate.
14790
9e4344e5
PA
147912010-06-20 Ian Lance Taylor <iant@google.com>
14792 Pedro Alves <pedro@codesourcery.com>
14793
14794 * linux-x86-low.c (always_true): Delete.
14795 (EMIT_ASM, EMIT_ASM32): Use an uncondition asm jmp instead of
14796 trying to fool the compiler with always_true.
14797
c6beb2cb
PA
147982010-06-20 Pedro Alves <pedro@codesourcery.com>
14799
14800 * tracepoint.c (condition_true_at_tracepoint): Don't run compiled
14801 conditions in gdbserver.
14802
d2ed6730
UW
148032010-06-19 Ulrich Weigand <uweigand@de.ibm.com>
14804
14805 * spu-low.c (spu_read_memory): Wrap around local store limit.
14806 (spu_write_memory): Likewise.
14807
4e29fb54
PA
148082010-06-15 Pedro Alves <pedro@codesourcery.com>
14809
14810 * linux-x86-low.c (amd64_emit_const, amd64_emit_void_call_2)
14811 (i386_emit_const, i386_emit_void_call_2): Replace int64_t uses with
14812 LONGEST uses.
14813 * server.h (struct emit_ops): Replace int64_t uses with LONGEST
14814 uses.
14815 * tracepoint.c (emit_const, emit_void_call_2): Replace int64_t
14816 uses with LONGEST uses.
14817
6a271cae
PA
148182010-06-14 Stan Shebs <stan@codesourcery.com>
14819 Pedro Alves <pedro@codesourcery.com>
14820
14821 Bytecode compiler.
14822
14823 * linux-x86-low.c: Include limits.h.
14824 (add_insns): New.
14825 (always_true): New.
14826 (EMIT_ASM): New.
14827 (EMIT_ASM32): New.
14828 (amd64_emit_prologue, amd64_emit_epilogue, amd64_emit_add)
14829 (amd64_emit_sub, amd64_emit_mul, amd64_emit_lsh)
14830 (amd64_emit_rsh_signed, amd64_emit_rsh_unsigned, amd64_emit_ext,
14831 (amd64_emit_log_not, amd64_emit_bit_and, amd64_emit_bit_or)
14832 (amd64_emit_bit_xor, amd64_emit_bit_not, amd64_emit_equal,
14833 (amd64_emit_less_signed, amd64_emit_less_unsigned, amd64_emit_ref,
14834 (amd64_emit_if_goto, amd64_emit_goto, amd64_write_goto_address)
14835 (amd64_emit_const, amd64_emit_call, amd64_emit_reg)
14836 (amd64_emit_pop, amd64_emit_stack_flush, amd64_emit_zero_ext)
14837 (amd64_emit_swap, amd64_emit_stack_adjust, amd64_emit_int_call_1)
14838 (amd64_emit_void_call_2): New.
14839 (amd64_emit_ops): New.
14840 (i386_emit_prologue, i386_emit_epilogue, i386_emit_add)
14841 (i386_emit_sub,i386_emit_mul, i386_emit_lsh, i386_emit_rsh_signed)
14842 (i386_emit_rsh_unsigned, i386_emit_ext, i386_emit_log_not)
14843 (i386_emit_bit_and, i386_emit_bit_or, i386_emit_bit_xor)
14844 (i386_emit_bit_not, i386_emit_equal, i386_emit_less_signed)
14845 (i386_emit_less_unsigned, i386_emit_ref, i386_emit_if_goto)
14846 (i386_emit_goto, i386_write_goto_address, i386_emit_const)
14847 (i386_emit_call, i386_emit_reg, i386_emit_pop)
14848 (i386_emit_stack_flush, i386_emit_zero_ext, i386_emit_swap)
14849 (i386_emit_stack_adjust, i386_emit_int_call_1)
14850 (i386_emit_void_call_2): New.
14851 (i386_emit_ops): New.
14852 (x86_emit_ops): New.
14853 (the_low_target): Install x86_emit_ops.
14854 * server.h (struct emit_ops): New.
14855 (get_raw_reg_func_addr): Declare.
14856 (current_insn_ptr, emit_error): Declare.
14857 * tracepoint.c (get_raw_reg, get_trace_state_variable_value)
14858 (set_trace_state_variable_value): New defines.
14859 (struct ipa_sym_addresses): New fields addr_get_raw_reg,
14860 addr_get_trace_state_variable_value and
14861 addr_set_trace_state_variable_value.
14862 (symbol_list): New fields for get_raw_reg,
14863 get_trace_state_variable_value and set_trace_state_variable_value.
14864 (condfn): New typedef.
14865 (struct tracepoint): New field `compiled_cond'.
14866 (do_action_at_tracepoint): Clear compiled_cond.
14867 (get_trace_state_variable_value, set_trace_state_variable_value):
14868 Export in the IPA.
14869 (condition_true_at_tracepoint): If there's a compiled condition,
14870 run that.
14871 (current_insn_ptr, emit_error): New globals.
14872 (struct bytecode_address): New.
14873 (get_raw_reg_func_addr): New.
14874 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul)
14875 (emit_lsh, emit_rsh_signed, emit_rsh_unsigned, emit_ext)
14876 (emit_log_not, emit_bit_and, emit_bit_or, emit_bit_xor)
14877 (emit_bit_not, emit_equal, emit_less_signed, emit_less_unsigned)
14878 (emit_ref, emit_if_goto, emit_goto, write_goto_address, emit_const)
14879 (emit_reg, emit_pop, emit_stack_flush, emit_zero_ext, emit_swap)
14880 (emit_stack_adjust, emit_int_call_1, emit_void_call_2): New.
14881 (compile_tracepoint_condition, compile_bytecodes): New.
14882 * target.h (emit_ops): Forward declare.
14883 (struct target_ops): New field emit_ops.
14884 (target_emit_ops): New.
14885 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): New.
14886 * linux-i386-ipa.c (gdb_agent_get_raw_reg): New.
14887 * linux-low.c (linux_emit_ops): New.
14888 (linux_target_ops): Install it.
14889 * linux-low.h (struct linux_target_ops): New field emit_ops.
14890
92b72907
UW
148912010-06-14 Ulrich Weigand <uweigand@de.ibm.com>
14892
14893 * linux-ppc-low.c (ppc_arch_setup): Use private regcache to test MSR.
14894 * linux-s390-low.c (ppc_arch_setup): Use private regcache to test PSW.
14895
fa593d66
PA
148962010-06-01 Pedro Alves <pedro@codesourcery.com>
14897 Stan Shebs <stan@codesourcery.com>
14898
14899 * Makefile.in (IPA_DEPFILES, extra_libraries): New.
14900 (all): Depend on $(extra_libraries).
14901 (install-only): Install the IPA.
14902 (IPA_OBJS, IPA_LIB): New.
14903 (clean): Remove the IPA lib.
14904 (IPAGENT_CFLAGS): New.
14905 (tracepoint-ipa.o, utils-ipa.o, remote-utils-ipa.o)
14906 (regcache-ipa.o, i386-linux-ipa.o, linux-i386-ipa.o)
14907 (linux-amd64-ipa.o, amd64-linux-ipa.o): New rules.
14908 * linux-amd64-ipa.c, linux-i386-ipa.c: New files.
14909 * configure.ac: Check for atomic builtins support in the compiler.
14910 (IPA_DEPFILES, extra_libraries): Define.
14911 * configure.srv (ipa_obj): Add description.
14912 (ipa_i386_linux_regobj, ipa_amd64_linux_regobj): Define.
14913 (i[34567]86-*-linux*): Set ipa_obj.
14914 (x86_64-*-linux*): Set ipa_obj.
14915 * linux-low.c (stabilizing_threads): New.
14916 (supports_fast_tracepoints): New.
14917 (linux_detach): Stabilize threads before detaching.
14918 (handle_tracepoints): Handle internal tracing breakpoints. Assert
14919 the lwp is either not stabilizing, or is moving out of a jump pad.
14920 (linux_fast_tracepoint_collecting): New.
14921 (maybe_move_out_of_jump_pad): New.
14922 (enqueue_one_deferred_signal): New.
14923 (dequeue_one_deferred_signal): New.
14924 (linux_wait_for_event_1): If moving out of a jump pad, defer
14925 pending signals to later.
14926 (linux_stabilize_threads): New.
14927 (linux_wait_1): Check if threads need moving out of jump pads, and
14928 do it if so.
14929 (stuck_in_jump_pad_callback): New.
14930 (move_out_of_jump_pad_callback): New.
14931 (lwp_running): New.
14932 (linux_resume_one_lwp): Handle moving out of jump pads.
14933 (linux_set_resume_request): Dequeue deferred signals.
14934 (need_step_over_p): Also step over fast tracepoint jumps.
14935 (start_step_over): Also uninsert fast tracepoint jumps.
14936 (finish_step_over): Also reinsert fast tracepoint jumps.
14937 (linux_install_fast_tracepoint_jump): New.
14938 (linux_target_ops): Install linux_stabilize_threads and
14939 linux_install_fast_tracepoint_jump_pad.
14940 * linux-low.h (linux_target_ops) <get_thread_area,
14941 install_fast_tracepoint_jump_pad>: New fields.
14942 (struct lwp_info) <collecting_fast_tracepoint,
14943 pending_signals_to_report, exit_jump_pad_bkpt>: New fields.
14944 (linux_get_thread_area): Declare.
14945 * linux-x86-low.c (jump_insn): New.
14946 (x86_get_thread_area): New.
14947 (append_insns): New.
14948 (push_opcode): New.
14949 (amd64_install_fast_tracepoint_jump_pad): New.
14950 (i386_install_fast_tracepoint_jump_pad): New.
14951 (x86_install_fast_tracepoint_jump_pad): New.
14952 (the_low_target): Install x86_get_thread_area and
14953 x86_install_fast_tracepoint_jump_pad.
14954 * mem-break.c (set_raw_breakpoint_at): Use read_inferior_memory.
14955 (struct fast_tracepoint_jump): New.
14956 (fast_tracepoint_jump_insn): New.
14957 (fast_tracepoint_jump_shadow): New.
14958 (find_fast_tracepoint_jump_at): New.
14959 (fast_tracepoint_jump_here): New.
14960 (delete_fast_tracepoint_jump): New.
14961 (set_fast_tracepoint_jump): New.
14962 (uninsert_fast_tracepoint_jumps_at): New.
14963 (reinsert_fast_tracepoint_jumps_at): New.
14964 (set_breakpoint_at): Use write_inferior_memory.
14965 (uninsert_raw_breakpoint): Use write_inferior_memory.
14966 (check_mem_read): Mask out fast tracepoint jumps.
14967 (check_mem_write): Mask out fast tracepoint jumps.
14968 * mem-break.h (struct fast_tracepoint_jump): Forward declare.
14969 (set_fast_tracepoint_jump): Declare.
14970 (delete_fast_tracepoint_jump)
14971 (fast_tracepoint_jump_here, uninsert_fast_tracepoint_jumps_at)
14972 (reinsert_fast_tracepoint_jumps_at): Declare.
14973 * regcache.c: Don't compile many functions when building the
14974 in-process agent library.
14975 (init_register_cache) [IN_PROCESS_AGENT]: Don't allow allocating
14976 the register buffer in the heap.
14977 (free_register_cache): If the register buffer isn't owned by the
14978 regcache, don't free it.
14979 (set_register_cache) [IN_PROCESS_AGENT]: Don't re-alocate
14980 pre-existing register caches.
14981 * remote-utils.c (convert_int_to_ascii): Constify `from' parameter
14982 type.
14983 (convert_ascii_to_int): : Constify `from' parameter type.
14984 (decode_M_packet, decode_X_packet): Replace the `to' parameter by
14985 a `to_p' pointer to pointer parameter. If TO_P is NULL, malloc
14986 the needed buffer in-place.
14987 (relocate_instruction): New.
14988 * server.c (handle_query) <qSymbols>: If the target supports
14989 tracepoints, give it a chance of looking up symbols. Report
14990 support for fast tracepoints.
14991 (handle_status): Stabilize threads.
14992 (process_serial_event): Adjust.
14993 * server.h (struct fast_tracepoint_jump): Forward declare.
14994 (struct process_info) <fast_tracepoint_jumps>: New field.
14995 (convert_ascii_to_int, convert_int_to_ascii): Adjust.
14996 (decode_X_packet, decode_M_packet): Adjust.
14997 (relocate_instruction): Declare.
14998 (in_process_agent_loaded): Declare.
14999 (tracepoint_look_up_symbols): Declare.
15000 (struct fast_tpoint_collect_status): Declare.
15001 (fast_tracepoint_collecting): Declare.
15002 (force_unlock_trace_buffer): Declare.
15003 (handle_tracepoint_bkpts): Declare.
15004 (initialize_low_tracepoint)
15005 (supply_fast_tracepoint_registers) [IN_PROCESS_AGENT]: Declare.
15006 * target.h (struct target_ops) <stabilize_threads,
15007 install_fast_tracepoint_jump_pad>: New fields.
15008 (stabilize_threads, install_fast_tracepoint_jump_pad): New.
15009 * tracepoint.c [HAVE_MALLOC_H]: Include malloc.h.
15010 [HAVE_STDINT_H]: Include stdint.h.
15011 (trace_debug_1): Rename to ...
15012 (trace_vdebug): ... this.
15013 (trace_debug): Rename to ...
15014 (trace_debug_1): ... this. Add `level' parameter.
15015 (trace_debug): New.
15016 (ATTR_USED, ATTR_NOINLINE): New.
15017 (IP_AGENT_EXPORT): New.
15018 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
15019 (collecting, gdb_collect, stop_tracing, flush_trace_buffer)
15020 (about_to_request_buffer_space, trace_buffer_is_full)
15021 (stopping_tracepoint, expr_eval_result, error_tracepoint)
15022 (tracepoints, tracing, trace_buffer_ctrl, trace_buffer_ctrl_curr)
15023 (trace_buffer_lo, trace_buffer_hi, traceframe_read_count)
15024 (traceframe_write_count, traceframes_created)
15025 (trace_state_variables)
15026 New renaming defines.
15027 (struct ipa_sym_addresses): New.
15028 (STRINGIZE_1, STRINGIZE, IPA_SYM): New.
15029 (symbol_list): New.
15030 (ipa_sym_addrs): New.
15031 (all_tracepoint_symbols_looked_up): New.
15032 (in_process_agent_loaded): New.
15033 (write_e_ipa_not_loaded): New.
15034 (maybe_write_ipa_not_loaded): New.
15035 (tracepoint_look_up_symbols): New.
15036 (debug_threads) [IN_PROCESS_AGENT]: New.
15037 (read_inferior_memory) [IN_PROCESS_AGENT]: New.
15038 (UNKNOWN_SIDE_EFFECTS): New.
15039 (stop_tracing): New.
15040 (flush_trace_buffer): New.
15041 (stop_tracing_bkpt): New.
15042 (flush_trace_buffer_bkpt): New.
15043 (read_inferior_integer): New.
15044 (read_inferior_uinteger): New.
15045 (read_inferior_data_pointer): New.
15046 (write_inferior_data_pointer): New.
15047 (write_inferior_integer): New.
15048 (write_inferior_uinteger): New.
15049 (struct collect_static_trace_data_action): Delete.
15050 (enum tracepoint_type): New.
15051 (struct tracepoint) <type>: New field `type'.
43aaf8b6
PA
15052 <actions_str, step_actions, step_actions_str>: Only include in
15053 GDBserver.
fa593d66
PA
15054 <orig_size, obj_addr_on_target, adjusted_insn_addr>
15055 <adjusted_insn_addr_end, jump_pad, jump_pad_end>: New fields.
15056 (tracepoints): Use IP_AGENT_EXPORT.
15057 (last_tracepoint): Don't include in the IPA.
15058 (stopping_tracepoint): Use IP_AGENT_EXPORT.
15059 (trace_buffer_is_full): Use IP_AGENT_EXPORT.
15060 (alloced_trace_state_variables): New.
15061 (trace_state_variables): Use IP_AGENT_EXPORT.
15062 (traceframe_t): Delete unused variable.
15063 (circular_trace_buffer): Don't include in the IPA.
15064 (trace_buffer_start): Delete.
15065 (struct trace_buffer_control): New.
15066 (trace_buffer_free): Delete.
15067 (struct ipa_trace_buffer_control): New.
15068 (GDBSERVER_FLUSH_COUNT_MASK, GDBSERVER_FLUSH_COUNT_MASK_PREV)
15069 (GDBSERVER_FLUSH_COUNT_MASK_CURR, GDBSERVER_UPDATED_FLUSH_COUNT_BIT):
15070 New.
15071 (trace_buffer_ctrl): New.
15072 (TRACE_BUFFER_CTRL_CURR): New.
15073 (trace_buffer_start, trace_buffer_free, trace_buffer_end_free):
15074 Reimplement as macros.
15075 (trace_buffer_wrap): Delete.
15076 (traceframe_write_count, traceframe_read_count)
15077 (traceframes_created, tracing): Use IP_AGENT_EXPORT.
15078 (struct tracepoint_hit_ctx) <type>: New field.
15079 (struct fast_tracepoint_ctx): New.
15080 (memory_barrier): New.
15081 (cmpxchg): New.
15082 (record_tracepoint_error): Update atomically in the IPA.
15083 (clear_inferior_trace_buffer): New.
15084 (about_to_request_buffer_space): New.
15085 (trace_buffer_alloc): Handle GDBserver and inferior simulatenous
15086 updating the same buffer.
15087 (add_tracepoint): Default the tracepoint's type to trap
15088 tracepoint, and orig_size to -1.
15089 (get_trace_state_variable) [IN_PROCESS_AGENT]: Handle allocated
15090 internal variables.
15091 (create_trace_state_variable): New parameter `gdb'. Handle it.
15092 (clear_installed_tracepoints): Clear fast tracepoint jumps.
15093 (cmd_qtdp): Handle fast tracepoints.
15094 (cmd_qtdv): Adjust.
15095 (max_jump_pad_size): New.
15096 (gdb_jump_pad_head): New.
15097 (get_jump_space_head): New.
15098 (claim_jump_space): New.
15099 (sort_tracepoints): New.
15100 (MAX_JUMP_SIZE): New.
15101 (cmd_qtstart): Handle fast tracepoints. Sync tracepoints with the
15102 IPA.
15103 (stop_tracing) [IN_PROCESS_AGENT]: Don't include the tdisconnected
15104 support. Upload fast traceframes, and delete internal IPA
15105 breakpoints.
15106 (stop_tracing_handler): New.
15107 (flush_trace_buffer_handler): New.
15108 (cmd_qtstop): Upload fast tracepoints.
15109 (response_tracepoint): Handle fast tracepoints.
15110 (tracepoint_finished_step): Upload fast traceframes. Set the
15111 tracepoint hit context's tracepoint type.
15112 (handle_tracepoint_bkpts): New.
15113 (tracepoint_was_hit): Set the tracepoint hit context's tracepoint
15114 type. Add comment about fast tracepoints.
15115 (collect_data_at_tracepoint) [IN_PROCESS_AGENT]: Don't access the
15116 non-existing action_str field.
15117 (get_context_regcache): Handle fast tracepoints.
15118 (do_action_at_tracepoint) [!IN_PROCESS_AGENT]: Don't write the PC
15119 to the regcache.
15120 (fast_tracepoint_from_jump_pad_address): New.
15121 (fast_tracepoint_from_ipa_tpoint_address): New.
15122 (collecting_t): New.
15123 (force_unlock_trace_buffer): New.
15124 (fast_tracepoint_collecting): New.
15125 (collecting): New.
15126 (gdb_collect): New.
15127 (write_inferior_data_ptr): New.
15128 (target_tp_heap): New.
15129 (target_malloc): New.
15130 (download_agent_expr): New.
15131 (UALIGN): New.
15132 (download_tracepoints): New.
15133 (download_trace_state_variables): New.
15134 (upload_fast_traceframes): New.
15135 (IPA_FIRST_TRACEFRAME): New.
15136 (IPA_NEXT_TRACEFRAME_1): New.
15137 (IPA_NEXT_TRACEFRAME): New.
15138 [IN_PROCESS_AGENT]: Include sys/mman.h and fcntl.h.
15139 [IN_PROCESS_AGENT] (gdb_tp_heap_buffer, gdb_jump_pad_buffer)
15140 (gdb_jump_pad_buffer_end): New.
15141 [IN_PROCESS_AGENT] (initialize_tracepoint_ftlib): New.
15142 (initialize_tracepoint): Adjust.
15143 [IN_PROCESS_AGENT]: Allocate the IPA heap, and jump pad scratch
15144 buffer. Initialize the low module.
15145 * utils.c (PREFIX, TOOLNAME): New.
15146 (malloc_failure): Use PREFIX.
15147 (error): In the IPA, an error causes an exit.
15148 (fatal, warning): Use PREFIX.
15149 (internal_error): Use TOOLNAME.
15150 (NUMCELLS): Increase to 10.
15151 * configure, config.in: Regenerate.
15152
d149dd1d
PA
151532010-06-01 Pedro Alves <pedro@codesourcery.com>
15154
15155 * server.c (handle_query) <qSupported>: Do two passes over the
15156 qSupported string to avoid nesting strtok.
15157
f6528abd
JK
151582010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
15159
15160 * Makefile.in (SFILES): Add $(srcdir)/proc-service.list.
15161 (CDEPS): New.
15162 * configure.ac (RDYNAMIC): New AC_MSG_CHECKING wrapping. Test also
15163 -Wl,--dynamic-list.
15164 * configure: Regenerate.
15165 * proc-service.list: New.
15166
ca2a87a0
JK
151672010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
15168
15169 * linux-low.c (linux_core_of_thread): Fix crash on invalid CONTENT.
15170 New comment.
15171
363a6e9f
OS
151722010-05-26 Ozkan Sezer <sezeroz@gmail.com>
15173
15174 * gdbreplay.c (remote_open): Check error return from socket() call by
15175 its equality to -1 not by it being negative.
15176 * remote-utils.c (remote_open): Likewise.
15177
d23b6cb1
PA
151782010-05-23 Pedro Alves <pedro@codesourcery.com>
15179
15180 * config.h: Regenerate.
15181
28d3cf85
MK
151822010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
15183
15184 * linux-m68k-low.c (ps_get_thread_area): Don't define if kernel
15185 doesn't provide PTRACE_GET_THREAD_AREA.
15186
fea36a59
MK
151872010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
15188
15189 * linux-m68k-low.c: Include <asm/ptrace.h>
15190 (ps_get_thread_area): Implement.
15191
24b066ba
DE
151922010-05-03 Doug Evans <dje@google.com>
15193
15194 * event-loop.c (struct callback_event): New struct.
15195 (callback_list): New global.
15196 (append_callback_event, delete_callback_event): New functions.
15197 (process_callback): New function.
15198 (start_event_loop): Call it.
15199 * remote-utils.c (NOT_SCHEDULED): Define.
15200 (readchar_buf, readchar_bufcnt, readchar_bufp): New static globals,
15201 moved out of readchar.
15202 (readchar): Rewrite. Call reschedule before returning.
15203 (reset_readchar): New function.
15204 (remote_close): Call it.
15205 (process_remaining, reschedule): New functions.
15206 * server.h (callback_handler_func): New typedef.
15207 (append_callback_event, delete_callback_event): Declare.
15208
9836d6ea
PA
152092010-05-03 Pedro Alves <pedro@codesourcery.com>
15210
15211 * proc-service.c (ps_pglobal_lookup): Use
15212 thread_db_look_up_one_symbol.
15213 * remote-utils.c (look_up_one_symbol): Add new `may_ask_gdb'
15214 parameter. Use it instead of all_symbols_looked_up.
15215 * server.h (struct process_info) <all_symbols_looked_up>: Delete
15216 field.
15217 (all_symbols_looked_up): Don't declare.
15218 (look_up_one_symbol): Add new `may_ask_gdb' parameter.
15219 * thread-db.c (struct thread_db) <all_symbols_looked_up>: New
15220 field.
15221 (thread_db_look_up_symbols): Adjust call to look_up_one_symbol.
15222 Set all_symbols_looked_up here.
15223 (thread_db_look_up_one_symbol): New.
15224 (thread_db_get_tls_address): Adjust.
15225 (thread_db_load_search, try_thread_db_load_1): Always allocate the
15226 thread_db object on the heap, and tentatively set it in the
15227 process structure.
15228 (thread_db_init): Don't set all_symbols_looked_up here.
15229 * linux-low.h (thread_db_look_up_one_symbol): Declare.
15230
7984d532
PA
152312010-05-03 Pedro Alves <pedro@codesourcery.com>
15232
15233 * linux-low.c (linux_kill, linux_detach): Adjust.
15234 (status_pending_p_callback): Remove redundant statement. Check
15235 for !TARGET_WAITIKIND_IGNORE, instead of
15236 TARGET_WAITKIND_STOPPED.
15237 (handle_tracepoints): Make sure LWP is locked. Adjust.
15238 (linux_wait_for_event_1): Adjust.
15239 (linux_cancel_breakpoints): New.
15240 (unsuspend_one_lwp): New.
15241 (unsuspend_all_lwps): New.
15242 (linux_wait_1): If finishing a step-over, unsuspend all lwps.
15243 (send_sigstop_callback): Change return type to int, add new
15244 `except' parameter and handle it.
15245 (suspend_and_send_sigstop_callback): New.
15246 (stop_all_lwps): Add new `suspend' and `expect' parameters, and
15247 pass them down. If SUSPEND, also increment the lwp's suspend
15248 count.
15249 (linux_resume_one_lwp): Add notice about resuming a suspended LWP.
15250 (need_step_over_p): Don't consider suspended LWPs.
15251 (start_step_over): Adjust.
15252 (proceed_one_lwp): Change return type to int, add new `except'
15253 parameter and handle it.
15254 (unsuspend_and_proceed_one_lwp): New.
15255 (proceed_all_lwps): Use find_inferior instead of
15256 for_each_inferior.
15257 (unstop_all_lwps): Add `unsuspend' parameter. If UNSUSPEND, them
15258 also decrement the suspend count of LWPs. Pass `except' down,
15259 instead of hacking its suspend count.
15260 (linux_pause_all): Add `freeze' parameter. Adjust.
15261 (linux_unpause_all): New.
15262 (linux_target_ops): Install linux_unpause_all.
15263 * server.c (handle_status): Adjust.
15264 * target.h (struct target_ops): New fields `unpause_all' and
15265 `cancel_breakpoints'. Add new parameter to `pause_all'.
15266 (pause_all): Add new `freeze' parameter.
15267 (unpause_all): New.
15268 (cancel_breakpoints): New.
15269 * tracepoint.c (clear_installed_tracepoints): Pause threads, and
15270 cancel breakpoints.
15271 (cmd_qtstart): Pause threads.
15272 (stop_tracing): Pause threads, and cancel breakpoints.
15273 * win32-low.c (win32_target_ops): Adjust.
15274
e471f25b
PA
152752010-05-03 Pedro Alves <pedro@codesourcery.com>
15276
15277 * linux-low.c (linux_wait_for_event_1): Move passing the signal to
15278 the inferior right away from here...
15279 (linux_wait_1): ... to here, and adjust to check the thread's
15280 last_resume_kind instead of the lwp's step or stop_expected flags.
15281
1915ef4f
PA
152822010-05-02 Pedro Alves <pedro@codesourcery.com>
15283
15284 * README: Use consistent `GDB' and `GDBserver' spellings.
15285
f9e39928
PA
152862010-05-02 Pedro Alves <pedro@codesourcery.com>
15287
15288 * linux-low.c (linux_kill_one_lwp): Assume the lwp is stopped.
15289 (linux_kill): Stop all lwps here. Don't delete the main lwp here.
15290 (linux_detach_one_lwp): Assume the lwp is stopped.
15291 (any_thread_of): Delete.
15292 (linux_detach): Stop all lwps here. Don't blindly delete all
15293 breakpoints.
15294 (delete_lwp_callback): New.
15295 (linux_mourn): Delete all lwps of the process that is gone.
15296 (linux_wait_1): Don't delete the last lwp of the process here.
15297 * mem-break.h (mark_breakpoints_out): Declare.
15298 * mem-break.c (mark_breakpoints_out): New.
15299 (free_all_breakpoints): Use it.
15300 * server.c (handle_target_event): If the process is gone, mark
15301 breakpoints out.
15302 * thread-db.c (struct thread_db) <create_bp>: New field.
15303 (thread_db_enable_reporting): Fix prototype. Store a thread event
15304 breakpoint reference in the thread_db struct.
15305 (thread_db_load_search): Clear the thread_db object.
15306 (try_thread_db_load_1): Ditto.
15307 (switch_to_process): New.
15308 (disable_thread_event_reporting): Use it.
15309 (remove_thread_event_breakpoints): New.
15310 (thread_db_detach, thread_db_mourn): Use it.
15311
1e7fc18c
PA
153122010-05-01 Pedro Alves <pedro@codesourcery.com>
15313
15314 * linux-low.c (linux_enable_event_reporting): New.
15315 (linux_wait_for_event_1, handle_extended_wait): Use it.
15316
02fc4de7
PA
153172010-04-30 Pedro Alves <pedro@codesourcery.com>
15318
15319 * linux-low.c (linux_kill_one_lwp, linux_kill)
15320 (linux_detach_one_lwp): Adjust to send_sigstop interface change.
15321 (send_sigstop): Take an lwp_info as parameter instead. Queue a
15322 SIGSTOP even if the LWP is stopped.
15323 (send_sigstop_callback): New.
15324 (stop_all_lwps): Use send_sigstop_callback instead.
15325 (linux_resume_one_thread): Adjust.
15326 (proceed_one_lwp): Still proceed an LWP that the client has
15327 requested to stop, if we haven't reported it as stopped yet. Make
15328 sure that LWPs the client want stopped, have a pending SIGSTOP.
15329
bc3b5632
DE
153302010-04-26 Doug Evans <dje@google.com>
15331
ae1ada35
DE
15332 * server.c (handle_general_set): Make static.
15333
bc3b5632
DE
15334 * remote-utils.c (putpkt_binary_1): Call readchar instead of read.
15335 Print received char after testing for error/eof instead of before.
15336 (input_interrupt): Tweak comment.
15337
65730243
DE
153382010-04-23 Doug Evans <dje@google.com>
15339
15340 * server.c (start_inferior): Print inferior argv if --debug.
15341
a8ae7dc0
AR
153422010-04-21 Aleksandar Ristovski <aristovski@qnx.com>
15343
15344 * Makefile.in (nto_low_h nto-low.o nto-x86-low.o): New dependency lists.
15345 * nto-x86-low.c: Include server.h
15346
1c07cc19
PM
153472010-04-20 Pierre Muller <muller@ics.u-strasbg.fr>
15348
15349 * win32-i386-low.c: Use __x86_64__ macro instead of __x86_64 to
15350 be consistent with other sources of this directory.
15351 (init_registers_amd64): Correct name of source file of this function
15352 in the comment.
15353
e0a61e09
PM
153542010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
15355
15356 * configure.srv (x86_64-*-mingw*): New configuration for Windows
15357 64-bit executables.
15358
54709339
PM
153592010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
15360
15361 * win32-i386-low.c: Add 64-bit support.
15362 (CONTEXT_EXTENDED_REGISTERS): Set macro to zero if not exisiting.
15363 (init_registers_amd64): Declare.
15364 (mappings): Add 64-bit version of array.
15365 (init_windows_x86): New function.
15366 (the_low_target): Change init_arch field to init_windows_x86.
15367
e8f0053d
PM
153682010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
15369
15370 * win32-low.c: Adapt to support also 64-bit architecture.
15371 (child_xfer_memory): Use uintptr_t type for local variable `addr'.
15372 (get_image_name): Use SIZE_T type for local variable `done'.
15373 (psapi_get_dll_name): Use LPVOID type for parameter `BaseAddress'.
15374 (toolhelp_get_dll_name): Idem.
15375 (handle_load_dll): Use CORE_ADDR type for local variable `load_addr'.
15376 Use uintptr_t typecast to avoid warning.
15377 (handle_unload_dll): Use uintptr_t typecast to avoid warning.
15378 (handle_exception): Use phex_nz to avoid warning.
15379 (win32_wait): Remove unused local variable `process'.
15380
c481e77e
PM
153812010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
15382
15383 * configure.srv (srv_amd64_regobj): Replace `x86-64-avx.o' by
15384 `amd64-avx.o'.
15385
12ea4b69
PM
153862010-04-17 Pierre Muller <muller@ics.u-strasbg.fr>
15387
15388 * configure.ac: Use `ws2_32' library for srv_mingw.
15389 * configure: Regenerate.
15390 * gdbreplay.c: Include winsock2.h instead of winsock.h.
15391 * remote-utils.c: Likewise.
15392
f6d1620c
L
153932010-04-17 H.J. Lu <hongjiu.lu@intel.com>
15394
15395 * linux-x86-low.c (xmltarget_amd64_linux_no_xml): Define only
15396 if __x86_64__ is defined.
15397
8e642873
PM
153982010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
15399
15400 * configure: Regenerate.
15401
711e434b
PM
154022010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
15403
15404 * server.c (handle_query): Handle 'qGetTIBAddr' query.
15405 * target.h (target_ops): New get_tib_address field.
15406 * win32-low.h (win32_thread_info): Add thread_local_base field.
15407 * win32-low.c (child_add_thread): Add tlb argument.
15408 Set thread_local_base field to TLB.
15409 (get_child_debug_event): Adapt to child_add_thread change.
15410 (win32_get_tib_address): New function.
15411 (win32_target_ops): Set get_tib_address field to
15412 win32_get_tib_address.
15413 * linux-low.c (linux_target_ops): Set get_tib_address field to NULL.
15414
505106cd
PA
154152010-04-12 Pedro Alves <pedro@codesourcery.com>
15416
505106cd
PA
15417 * linux-low.c (linux_mourn): Also remove the process.
15418 * server.c (handle_target_event): Don't remove the process here.
15419 * nto-low.c (nto_mourn): New.
15420 (nto_target_ops): Install it.
15421 * spu-low.c (spu_mourn): New.
15422 (spu_target_ops): Install it.
15423 * win32-low.c (win32_mourn): New.
15424 (win32_target_ops): Install it.
15425
e8470a06
PA
154262010-04-12 Pedro Alves <pedro@codesourcery.com>
15427
15428 * server.h (buffer_xml_printf): Remove redundant `;'.
15429
45ba0d02
PA
154302010-04-12 Pedro Alves <pedro@codesourcery.com>
15431
15432 * regcache.c (set_register_cache): Invalidate regcaches before
15433 changing the register cache layout.
15434 (regcache_invalidate_one): Allow a NULL regcache.
15435 * linux-x86-low.c (x86_linux_update_xmltarget): Invalidate
15436 regcaches before changing the register cache layout or the target
15437 regsets.
15438
59e04013
L
154392010-04-12 H.J. Lu <hongjiu.lu@intel.com>
15440
15441 * linux-x86-low.c (x86_linux_update_xmltarget): Avoid unused
15442 variable warning on Linux/x86-64.
15443
8336d594
PA
154442010-04-11 Pedro Alves <pedro@codesourcery.com>
15445
15446 GDBserver disconnected tracing support.
15447
15448 * linux-low.c (linux_remove_process): Delete.
15449 (add_lwp): Don't set last_resume_kind here.
15450 (linux_kill): Use `mourn'.
15451 (linux_detach): Use `thread_db_detach', and `mourn'.
15452 (linux_mourn): New.
15453 (linux_attach_lwp_1): Adjust comment.
15454 (linux_attach): last_resume_kind moved the thread_info; adjust.
15455 (status_pending_p_callback): Adjust.
15456 (linux_wait_for_event_1): Adjust.
15457 (count_events_callback, select_singlestep_lwp_callback)
15458 (select_event_lwp_callback, cancel_breakpoints_callback)
15459 (db_wants_lwp_stopped, linux_wait_1, need_step_over_p)
15460 (proceed_one_lwp): Adjust.
15461 (linux_async): Add debug output.
15462 (linux_thread_stopped): New.
15463 (linux_pause_all): New.
15464 (linux_target_ops): Install linux_mourn, linux_thread_stopped and
15465 linux_pause_all.
15466 * linux-low.h (struct lwp_info): Delete last_resume_kind field.
15467 (thread_db_free): Delete declaration.
15468 (thread_db_detach, thread_db_mourn): Declare.
15469 * thread-db.c (thread_db_init): Use thread_db_mourn.
15470 (thread_db_free): Delete, split in two.
15471 (disable_thread_event_reporting): New.
15472 (thread_db_detach): New.
15473 (thread_db_mourn): New.
15474
15475 * server.h (struct thread_info) <last_resume_kind>: New field.
15476 <attached>: Add comment.
15477 <gdb_detached>: New field.
15478 (handler_func): Change return type to int.
15479 (handle_serial_event, handle_target_event): Ditto.
15480 (gdb_connected): Declare.
15481 (tracing): Delete.
15482 (disconnected_tracing): Declare.
15483 (stop_tracing): Declare.
15484
15485 * server.c (handle_query) <qSupported>: Report support for
15486 disconnected tracing.
15487 (queue_stop_reply_callback): Account for running threads.
15488 (gdb_wants_thread_stopped): New.
15489 (gdb_wants_all_threads_stopped): New.
15490 (gdb_reattached_process): New.
15491 (handle_status): Clear the `gdb_detached' flag of all processes.
15492 In all-stop, stop all threads.
15493 (main): Be sure to leave tfind mode. Handle disconnected tracing.
15494 (process_serial_event): If the remote connection breaks, or if an
15495 exit was forced with "monitor exit", force an event loop exit.
15496 Handle disconnected tracing on detach.
15497 (handle_serial_event): Adjust.
15498 (handle_target_event): If GDB isn't connected, forward events back
15499 to the inferior, unless the last process exited, in which case,
15500 exit gdbserver. Adjust interface.
15501
15502 * remote-utils.c (remote_open): Don't block in accept. Instead
15503 register an event loop source on the listen socket file
15504 descriptor. Refactor bits into ...
15505 (listen_desc): ... this new global.
15506 (gdb_connected): ... this new function.
15507 (enable_async_notification): ... this new function.
15508 (handle_accept_event): ... this new function.
15509 (remote_close): Clear remote_desc.
15510
15511 * inferiors.c (add_thread): Set the new thread's last_resume_kind.
15512
15513 * target.h (struct target_ops) <mourn, thread_stopped, pause_all>:
15514 New fields.
15515 (mourn_inferior): Define.
15516 (target_process_qsupported): Avoid the dangling else problem.
15517 (thread_stopped): Define.
15518 (pause_all): Define.
15519 (target_waitstatus_to_string): Declare.
15520 * target.c (target_waitstatus_to_string): New.
15521
15522 * tracepoint.c (tracing): Make extern.
15523 (disconnected_tracing): New.
15524 (stop_tracing): Make extern. Handle tracing stops due to GDB
15525 disconnecting.
15526 (cmd_qtdisconnected): New.
15527 (cmd_qtstatus): Report disconnected tracing status in trace reply.
15528 (handle_tracepoint_general_set): Handle QTDisconnected.
15529
15530 * event-loop.c (event_handler_func): Change return type to int.
15531 (process_event): Bail out if the event handler wants the event
15532 loop to stop.
15533 (handle_file_event): Ditto.
15534 (start_event_loop): Bail out if the event handler wants the event
15535 loop to stop.
15536
15537 * nto-low.c (nto_target_ops): Adjust.
15538 * spu-low.c (spu_wait): Don't remove the process here.
15539 (spu_target_ops): Adjust.
15540 * win32-low.c (win32_wait): Don't remove the process here.
15541 (win32_target_ops): Adjust.
15542
5d267c4c
PA
155432010-04-11 Pedro Alves <pedro@codesourcery.com>
15544
15545 * regcache.c (realloc_register_cache): Invalidate inferior's
15546 regcache before recreating it.
15547
623ccd72
PA
155482010-04-09 Pedro Alves <pedro@codesourcery.com>
15549
15550 * tracepoint.c (cmd_qtstatus): Report trace buffer circularity.
15551
219f2f23
PA
155522010-04-09 Stan Shebs <stan@codesourcery.com>
15553 Pedro Alves <pedro@codesourcery.com>
15554
15555 * server.h (LONGEST): New.
15556 (struct thread_info) <while_stepping>: New field.
15557 (unpack_varlen_hex, xrealloc, pulongest, plongest, phex_nz):
15558 Declare.
15559 (initialize_tracepoint, handle_tracepoint_general_set)
15560 (handle_tracepoint_query, tracepoint_finished_step)
15561 (tracepoint_was_hit, release_while_stepping_state_list):
15562 (current_traceframe): Declare.
15563 * server.c (handle_general_set): Handle tracepoint packets.
15564 (read_memory): New.
15565 (write_memory): New.
15566 (handle_search_memory_1): Use read_memory.
15567 (handle_query): Report support for conditional tracepoints, trace
15568 state variables, and tracepoint sources. Handle tracepoint
15569 queries.
15570 (main): Initialize the tracepoints module.
15571 (process_serial_event): Handle traceframe reads/writes.
15572
15573 * linux-low.c (handle_tracepoints): New.
15574 (linux_wait_1): Call it.
15575 (linux_resume_one_lwp): Handle while-stepping.
15576 (linux_supports_tracepoints, linux_read_pc, linux_write_pc): New.
15577 (linux_target_ops): Install them.
15578 * linux-low.h (struct linux_target_ops) <supports_tracepoints>:
15579 New field.
15580 * linux-x86-low.c (x86_supports_tracepoints): New.
15581 (the_low_target). Install it.
15582
15583 * mem-break.h (delete_breakpoint): Declare.
15584 * mem-break.c (delete_breakpoint): Make external.
15585
15586 * target.h (struct target_ops): Add `supports_tracepoints',
15587 `read_pc', and `write_pc' fields.
15588 (target_supports_tracepoints): Define.
15589 * utils.c (xrealloc, decimal2str, pulongest, plongest, thirty_two)
15590 (phex_nz): New.
15591
15592 * regcache.h (struct regcache) <registers_owned>: New field.
15593 (init_register_cache, regcache_cpy): Declare.
15594 (regcache_read_pc, regcache_write_pc): Declare.
15595 (register_cache_size): Declare.
15596 (supply_regblock): Declare.
15597 * regcache.c (init_register_cache): New.
15598 (new_register_cache): Use it.
15599 (regcache_cpy): New.
15600 (register_cache_size): New.
15601 (supply_regblock): New.
15602 (regcache_read_pc, regcache_write_pc): New.
889bf7c5 15603
219f2f23
PA
15604 * tracepoint.c: New.
15605
15606 * Makefile.in (OBS): Add tracepoint.o.
15607 (tracepoint.o): New rule.
15608
3a13a53b
L
156092010-04-08 H.J. Lu <hongjiu.lu@intel.com>
15610
15611 * Makefile.in (clean): Also remove i386-mmx.c i386-mmx-linux.c.
15612 (i386-mmx.o): New.
15613 (i386-mmx.c): Likewise.
15614 (i386-mmx-linux.o): Likewise.
15615 (i386-mmx-linux.c): Likewise.
15616
15617 * configure.srv (srv_i386_regobj): Add i386-mmx.o.
15618 (srv_i386_linux_regobj): Add i386-mmx-linux.o.
15619 (srv_i386_xmlfiles): Add i386/i386-mmx.xml.
15620 (srv_i386_linux_xmlfiles): Add i386/i386-mmx-linux.xml.
15621
15622 * linux-x86-low.c (init_registers_i386_mmx_linux): New.
15623 (x86_linux_update_xmltarget): Call init_registers_i386_mmx_linux
15624 and return if ptrace PTRACE_GETFPXREGS failed in 32bit.
15625
1570b33e
L
156262010-04-07 H.J. Lu <hongjiu.lu@intel.com>
15627
15628 * Makefile.in (clean): Updated.
15629 (i386-avx.o): New.
15630 (i386-avx.c): Likewise.
15631 (i386-avx-linux.o): Likewise.
15632 (i386-avx-linux.c): Likewise.
15633 (amd64-avx.o): Likewise.
15634 (amd64-avx.c): Likewise.
15635 (amd64-avx-linux.o): Likewise.
15636 (amd64-avx-linux.c): Likewise.
15637
15638 * configure.srv (srv_i386_regobj): Add i386-avx.o.
15639 (srv_i386_linux_regobj): Add i386-avx-linux.o.
15640 (srv_amd64_regobj): Add amd64-avx.o.
15641 (srv_amd64_linux_regobj): Add amd64-avx-linux.o.
15642 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx.xml.
15643 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx.xml.
15644 (srv_i386_xmlfiles): Add i386/i386-avx.xml.
15645 (srv_amd64_xmlfiles): Add i386/amd64-avx.xml.
15646 (srv_i386_linux_xmlfiles): Add i386/i386-avx-linux.xml.
15647 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-linux.xml.
15648
15649 * i387-fp.c: Include "i386-xstate.h".
15650 (i387_xsave): New.
15651 (i387_cache_to_xsave): Likewise.
15652 (i387_xsave_to_cache): Likewise.
15653 (x86_xcr0): Likewise.
15654
15655 * i387-fp.h (i387_cache_to_xsave): Likewise.
15656 (i387_xsave_to_cache): Likewise.
15657 (x86_xcr0): Likewise.
15658
15659 * linux-arm-low.c (target_regsets): Initialize nt_type to 0.
15660 * linux-crisv32-low.c (target_regsets): Likewise.
15661 * linux-m68k-low.c (target_regsets): Likewise.
15662 * linux-mips-low.c (target_regsets): Likewise.
15663 * linux-ppc-low.c (target_regsets): Likewise.
15664 * linux-s390-low.c (target_regsets): Likewise.
15665 * linux-sh-low.c (target_regsets): Likewise.
15666 * linux-sparc-low.c (target_regsets): Likewise.
15667 * linux-xtensa-low.c (target_regsets): Likewise.
15668
15669 * linux-low.c: Include <sys/uio.h>.
15670 (regsets_fetch_inferior_registers): Support nt_type.
15671 (regsets_store_inferior_registers): Likewise.
15672 (linux_process_qsupported): New.
15673 (linux_target_ops): Add linux_process_qsupported.
15674
15675 * linux-low.h (regset_info): Add nt_type.
15676 (linux_target_ops): Add process_qsupported.
15677
15678 * linux-x86-low.c: Include "i386-xstate.h", "elf/common.h"
15679 and <sys/uio.h>.
15680 (init_registers_i386_avx_linux): New.
15681 (init_registers_amd64_avx_linux): Likewise.
15682 (xmltarget_i386_linux_no_xml): Likewise.
15683 (xmltarget_amd64_linux_no_xml): Likewise.
15684 (PTRACE_GETREGSET): Likewise.
15685 (PTRACE_SETREGSET): Likewise.
15686 (x86_fill_xstateregset): Likewise.
15687 (x86_store_xstateregset): Likewise.
15688 (use_xml): Likewise.
15689 (x86_linux_update_xmltarget): Likewise.
15690 (x86_linux_process_qsupported): Likewise.
15691 (target_regsets): Add NT_X86_XSTATE entry and Initialize nt_type.
15692 (x86_arch_setup): Don't call init_registers_amd64_linux nor
15693 init_registers_i386_linux here. Call
15694 x86_linux_update_xmltarget.
15695 (the_low_target): Add x86_linux_process_qsupported.
15696
15697 * server.c (handle_query): Call target_process_qsupported.
15698
15699 * target.h (target_ops): Add process_qsupported.
15700 (target_process_qsupported): New.
15701
fc7238bb
PA
157022010-04-03 Pedro Alves <pedro@codesourcery.com>
15703
15704 * inferiors.c (add_thread): Set last_status kind to
15705 TARGET_WAITKIND_IGNORE.
15706 * linux-low.c (cancel_breakpoint): Remove unnecessary regcache
15707 fetch. Use ptid_of. Avoid unnecessary get_lwp_thread calls.
15708 (linux_wait_1): Move `thread' local definition to block that uses
15709 it. Don't NULL initialize `event_child'.
15710 (linux_resume_one_thread): Avoid unnecessary get_lwp_thread calls.
15711 Alway set the thread's last_status to TARGET_WAITKIND_IGNORE.
15712 * linux-x86-low.c (x86_breakpoint_at): Read raw memory.
15713
bdabb078
PA
157142010-04-01 Pedro Alves <pedro@codesourcery.com>
15715
15716 * linux-low.c (get_stop_pc): Don't adjust the PC if stopped with
15717 an extended waitstatus, or by a watchpoint.
15718 (cancel_breakpoints_callback): Don't cancel a breakpoint if the
15719 thread was stepping or has been stopped by a watchpoint.
15720
d3bbe7a0
PA
157212010-04-01 Pedro Alves <pedro@codesourcery.com>
15722
15723 * mem-break.c (struct raw_breakpoint): New field shlib_disabled.
15724 (set_gdb_breakpoint_at): If GDB is inserting a breakpoint on top
15725 of another, then delete the previous, and validate all
15726 breakpoints.
15727 (validate_inserted_breakpoint): New.
15728 (delete_disabled_breakpoints): New.
15729 (validate_breakpoints): New.
15730 (check_mem_read): Validate breakpoints before trusting their
15731 shadow. Delete disabled breakpoints.
15732 (check_mem_write): Validate breakpoints before trusting they
15733 should be inserted. Delete disabled breakpoints.
15734 * mem-break.h (validate_breakpoints):
15735 * server.c (handle_query): Validate breakpoints when we see a
15736 qSymbol query.
15737
8b07ae33
PA
157382010-04-01 Pedro Alves <pedro@codesourcery.com>
15739
15740 * linux-low.c (linux_wait_1): Avoid setting need_step_over is
15741 there's a GDB breakpoint at stop_pc. Always report a trap to GDB
15742 if we could tell there's a GDB breakpoint at stop_pc.
15743 (need_step_over_p): Don't do a step over if we find a GDB
15744 breakpoint at the resume PC.
15745
15746 * mem-break.c (struct raw_breakpoint): New.
15747 (enum bkpt_type): New type `gdb_breakpoint'.
15748 (struct breakpoint): Delete the `PC', `old_data' and `inserted'
15749 fields. New field `raw'.
15750 (find_raw_breakpoint_at): New.
15751 (set_raw_breakpoint_at): Handle refcounting. Create a raw
15752 breakpoint instead.
15753 (set_breakpoint_at): Adjust.
15754 (delete_raw_breakpoint): New.
15755 (release_breakpoint): New.
15756 (delete_breakpoint): Rename to...
15757 (delete_breakpoint_1): ... this. Add proc parameter. Use
15758 release_breakpoint. Return ENOENT.
15759 (delete_breakpoint): Reimplement.
15760 (find_breakpoint_at): Delete.
15761 (find_gdb_breakpoint_at): New.
15762 (delete_breakpoint_at): Delete.
15763 (set_gdb_breakpoint_at): New.
15764 (delete_gdb_breakpoint_at): New.
15765 (gdb_breakpoint_here): New.
15766 (set_reinsert_breakpoint): Use release_breakpoint.
15767 (uninsert_breakpoint): Rename to ...
15768 (uninsert_raw_breakpoint): ... this.
15769 (uninsert_breakpoints_at): Adjust to handle raw breakpoints.
15770 (reinsert_raw_breakpoint): Change parameter type to
15771 raw_breakpoint.
15772 (reinsert_breakpoints_at): Adjust to handle raw breakpoints
15773 instead.
15774 (check_breakpoints): Adjust. Use release_breakpoint.
15775 (breakpoint_here): Rewrite using find_raw_breakpoint_at.
15776 (breakpoint_inserted_here): Ditto.
15777 (check_mem_read): Adjust to iterate over raw breakpoints instead.
15778 Don't trust the breakpoint's shadow if it is not inserted.
15779 (check_mem_write): Adjust to iterate over raw breakpoints instead.
15780 (delete_all_breakpoints): Adjust.
15781 (free_all_breakpoints): Mark all breakpoints as uninserted, and
15782 use delete_breakpoint_1.
15783
15784 * mem-break.h (breakpoints_supported): Delete declaration.
15785 (set_gdb_breakpoint_at): Declare.
15786 (gdb_breakpoint_here): Declare.
15787 (delete_breakpoint_at): Delete.
15788 (delete_gdb_breakpoint_at): Declare.
15789
15790 * server.h (struct raw_breakpoint): Forward declare.
15791 (struct process_info): New field `raw_breakpoints'.
15792
15793 * linux-x86-low.c (x86_insert_point, x86_remote_point): Handle Z0
15794 breakpoints.
15795
6bf5e0ba
PA
157962010-03-24 Pedro Alves <pedro@codesourcery.com>
15797
15798 * linux-low.c (status_pending_p_callback): Fix comment.
15799 (linux_wait_for_event_1): Move most of the internal breakpoint
15800 handling from here...
15801 (linux_wait_1): ... to here.
15802 (count_events_callback): New.
15803 (select_singlestep_lwp_callback): New.
15804 (select_event_lwp_callback): New.
15805 (cancel_breakpoints_callback): New.
15806 (select_event_lwp): New.
15807 (linux_wait_1): Simplify internal breakpoint handling. Give equal
15808 priority to all LWPs that have had events that should be reported
15809 to the client. Cancel breakpoints when about to reporting the
15810 event to the client, not while stopping lwps. No longer cancel
15811 finished single-steps here.
15812 (cancel_finished_single_step): Delete.
15813 (cancel_finished_single_steps): Delete.
15814
414a389f
PA
158152010-03-24 Pedro Alves <pedro@codesourcery.com>
15816
15817 * mem-break.c (enum bkpt_type): New.
15818 (struct breakpoint): New field `type'.
15819 (set_breakpoint_at): Change return type to struct breakpoint
15820 pointer. Set type to `other_breakpoint' by default.
15821 (delete_breakpoint): Rewrite, supporting more than one breakpoint
15822 in the breakpoint list.
15823 (delete_reinsert_breakpoints): Only delete reinsert breakpoints.
15824 (reinsert_breakpoint): Rename to ...
15825 (reinsert_raw_breakpoint): ... this.
15826 (reinsert_breakpoints_at): Adjust.
15827 * mem-break.h (struct breakpoint): Declare.
15828 (set_breakpoint_at): Change return type to struct breakpoint
15829 pointer.
15830
2280c721
PA
158312010-03-24 Pedro Alves <pedro@codesourcery.com>
15832
15833 * server.c (handle_query): Assign, not compare.
15834
d50171e4
PA
158352010-03-24 Pedro Alves <pedro@codesourcery.com>
15836
15837 Teach linux gdbserver to step-over-breakpoints.
15838
15839 * linux-low.c (can_hardware_single_step): New.
15840 (supports_breakpoints): New.
15841 (handle_extended_wait): If stopping threads, read the stop pc of
15842 the new cloned LWP.
15843 (get_pc): New.
15844 (get_stop_pc): Add `lwp' parameter. Handle it. Bail out if the
15845 low target doesn't support retrieving the PC.
15846 (add_lwp): Set last_resume_kind to resume_continue.
15847 (linux_attach_lwp_1): Adjust comments. Always set stop_expected.
15848 (linux_attach): Don't clear stop_expected. Set the lwp's
15849 last_resume_kind to resume_stop.
15850 (linux_detach_one_lwp): Don't check for removed breakpoints.
15851 (check_removed_breakpoint): Delete.
15852 (status_pending_p): Rename to ...
15853 (status_pending_p_callback): ... this. Don't check for removed
15854 breakpoints. Don't consider threads that are stopped from GDB's
15855 perspective.
15856 (linux_wait_for_lwp): Always read the stop_pc here.
15857 (cancel_breakpoint): New.
15858 (step_over_bkpt): New global.
15859 (linux_wait_for_event_1): Implement stepping over breakpoints.
15860 (gdb_wants_lwp_stopped): New.
15861 (gdb_wants_all_stopped): New.
15862 (linux_wait_1): Tag threads as gdb-wants-stopped. Cancel finished
15863 single-step traps here. Store the thread's last reported target
15864 wait status.
15865 (send_sigstop): Don't clear stop_expected. Always set it,
15866 instead.
15867 (mark_lwp_dead): Remove reference to pending_is_breakpoint.
15868 (cancel_finished_single_step): New.
15869 (cancel_finished_single_steps): New.
15870 (wait_for_sigstop): Don't cancel finished single-step traps here.
15871 (linux_resume_one_lwp): Don't check for removed breakpoints.
15872 Don't set `step' on non-hardware step archs.
15873 (linux_set_resume_request): Ignore resume_stop requests if already
15874 stopping or stopped. Set the lwp's last_resume_kind.
15875 (resume_status_pending_p): Don't check for removed breakpoints.
15876 (need_step_over_p): New.
15877 (start_step_over): New.
15878 (finish_step_over): New.
15879 (linux_resume_one_thread): Always queue a sigstop for resume_stop
15880 requests. Clear the thread's last reported target waitstatus.
15881 Don't use the `suspended' flag. Don't consider pending breakpoints.
15882 (linux_resume): Start a step-over if necessary.
15883 (proceed_one_lwp): New.
15884 (proceed_all_lwps): New.
15885 (unstop_all_lwps): New.
15886 * linux-low.h (struct lwp_info): Rewrite comment for the
15887 `suspended' flag. Add the `stop_pc' field. Delete the
15888 `pending_stop_pc' field. Tweak the `stepping' flag's comment.
15889 Add `'last_resume_kind' and `need_step_over' fields.
15890 * inferiors.c (struct thread_info): Delete, moved elsewhere.
15891 * mem-break.c (struct breakpoint): Delete `reinserting' flag.
15892 Delete `breakpoint_to_reinsert' field. New flag `inserted'.
15893 (set_raw_breakpoint_at): New.
15894 (set_breakpoint_at): Rewrite to use it.
15895 (reinsert_breakpoint_handler): Delete.
15896 (set_reinsert_breakpoint): New.
15897 (reinsert_breakpoint_by_bp): Delete.
15898 (delete_reinsert_breakpoints): New.
15899 (uninsert_breakpoint): Rewrite.
15900 (uninsert_breakpoints_at): New.
15901 (reinsert_breakpoint): Rewrite.
15902 (reinsert_breakpoints_at): New.
15903 (check_breakpoints): Rewrite.
15904 (breakpoint_here): New.
15905 (breakpoint_inserted_here): New.
15906 (check_mem_read): Adjust.
15907 * mem-break.h (breakpoints_supported, breakpoint_here)
15908 (breakpoint_inserted_here, set_reinsert_breakpoint): Declare.
15909 (reinsert_breakpoint_by_bp): Delete declaration.
15910 (delete_reinsert_breakpoints): Declare.
15911 (reinsert_breakpoint): Delete declaration.
15912 (reinsert_breakpoints_at): Declare.
15913 (uninsert_breakpoint): Delete declaration.
15914 (uninsert_breakpoints_at): Declare.
15915 (check_breakpoints): Adjust prototype.
15916 * server.h: Adjust include order.
15917 (struct thread_info): Declare here. Add a `last_status' field.
15918
30ba68cb
MS
159192010-03-23 Michael Snyder <msnyder@vmware.com>
15920
15921 * server.c (crc32): New function.
15922 (handle_query): Add handling for 'qCRC:' request.
15923
b9a881c2
PA
159242010-03-23 Pedro Alves <pedro@codesourcery.com>
15925
15926 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR6 if the
15927 lwp had been stopped by a watchpoint.
15928
e92d13d5
PA
159292010-03-16 Pedro Alves <pedro@codesourcery.com>
15930
15931 * server.h (internal_error): Declare.
15932 (gdb_assert, ASSERT_FUNCTION, gdb_assert_fail): Define.
15933 * utils.c (internal_error): New function.
15934
64daa791
AS
159352010-03-15 Andreas Schwab <schwab@redhat.com>
15936
15937 * configure.srv: Fix typo setting srv_regobj.
15938
f52cd8cd
PA
159392010-03-15 Pedro Alves <pedro@codesourcery.com>
15940
15941 * linux-low.c (fetch_register): Avoid passing a non string literal
15942 format to `error'.
15943 (usr_store_inferior_registers): Ditto.
15944
93ae6fdc
PA
159452010-03-14 Pedro Alves <pedro@codesourcery.com>
15946
15947 * linux-low.c (linux_write_memory): Bail out early if peeking
15948 memory failed.
15949
c3adc08c
PA
159502010-03-14 Pedro Alves <pedro@codesourcery.com>
15951
15952 * linux-low.h (struct lwp_info): New fields
15953 `stopped_by_watchpoint' and `stopped_data_address'.
15954 * linux-low.c (linux_wait_for_lwp): Check for watchpoint triggers
15955 here, and cache them in the lwp object.
15956 (wait_for_sigstop): Check stopped_by_watchpoint lwp field
15957 directly.
15958 (linux_resume_one_lwp): Clear the lwp's stopped_by_watchpoint
15959 field.
15960 (linux_stopped_by_watchpoint): Rewrite.
15961 (linux_stopped_data_address): Rewrite.
15962
bce522a2
PA
159632010-03-06 Simo Melenius <simo.melenius@iki.fi>
15964
15965 * linux-low.c (linux_wait_for_lwp): Fetch the regcache after
15966 switching the current inferior, not before.
15967
90884b2b
L
159682010-03-01 H.J. Lu <hongjiu.lu@intel.com>
15969
15970 * Makefile.in (clean): Replace reg-i386.c, reg-x86-64.c,
15971 reg-i386-linux.c and reg-x86-64-linux.c with i386.c, amd64.c,
15972 i386-linux.c and amd64-linux.c.
15973 (reg-i386.o): Removed.
15974 (reg-i386.c): Likewise.
15975 (reg-i386-linux.o): Likewise.
15976 (reg-i386-linux.c): Likewise.
15977 (reg-x86-64.o): Likewise.
15978 (reg-x86-64.c): Likewise.
15979 (reg-x86-64-linux.o): Likewise.
15980 (reg-x86-64-linux.c): Likewise.
15981 (i386.o): New.
15982 (i386.c): Likewise.
15983 (i386-linux.o): Likewise.
15984 (i386-linux.c): Likewise.
15985 (amd64.o): Likewise.
15986 (amd64.c): Likewise.
15987 (amd64-linux.o): Likewise.
15988 (amd64-linux.c): Likewise.
15989
15990 * configure.srv (srv_i386_regobj): New.
15991 (srv_i386_linux_regobj): Likewise.
15992 (srv_amd64_regobj): Likewise.
15993 (srv_amd64_linux_regobj): Likewise.
15994 (srv_i386_32bit_xmlfiles): Likewise.
15995 (srv_i386_64bit_xmlfiles): Likewise.
15996 (srv_i386_xmlfiles): Likewise.
15997 (srv_amd64_xmlfiles): Likewise.
15998 (srv_i386_linux_xmlfiles): Likewise.
15999 (srv_amd64_linux_xmlfiles): Likewise.
16000 (i[34567]86-*-cygwin*): Set srv_regobj to $srv_i386_regobj. Set
16001 srv_xmlfiles to $srv_i386_xmlfiles.
16002 (i[34567]86-*-mingw32ce*): Likewise.
16003 (i[34567]86-*-mingw*): Likewise.
16004 (i[34567]86-*-nto*): Likewise.
16005 (i[34567]86-*-linux*): Set srv_regobj to $srv_i386_linux_regobj
16006 and $srv_amd64_linux_regobj. Set srv_xmlfiles to
16007 $srv_i386_linux_xmlfiles and $srv_amd64_linux_xmlfiles.
16008 (x86_64-*-linux*): Likewise.
16009
16010 * linux-x86-low.c (init_registers_x86_64_linux): Removed.
16011 (init_registers_amd64_linux): New.
16012 (x86_arch_setup): Replace init_registers_x86_64_linux with
16013 init_registers_amd64_linux.
16014
193f13e6
MK
160152010-02-23 Maxim Kuvyrkov <maxim@codesourcery.com>
16016
16017 * configure.ac: Check for libdl. If it is not available link against
16018 static libthread_db.
16019 * configure: Regenerate.
16020
85d721b8
PA
160212010-02-22 Pedro Alves <pedro@codesourcery.com>
16022
16023 PR9605
16024
16025 * i386-low.c (i386_length_and_rw_bits): Throw a fatal error if
16026 handing a read watchpoint.
16027 (i386_low_insert_watchpoint): Read watchpoints aren't supported.
16028
6076632b
DE
160292010-02-12 Doug Evans <dje@google.com>
16030
16031 * linux-low.c (linux_supports_tracefork_flag): Document.
16032 (linux_look_up_symbols): Add comment.
16033
3327ccf7
L
160342010-02-03 H.J. Lu <hongjiu.lu@intel.com>
16035
16036 * regcache.c (supply_register): Clear regcache if buf is NULL.
16037
0718675c 160382010-02-02 Nicolas Roche <roche@sourceware.org>
3327ccf7 16039 Joel Brobecker <brobecker@adacore.com>
0718675c
JB
16040
16041 * inferiors.c (find_inferior): Add function documentation.
16042 (unloaded_dll): Handle the case where the unloaded dll has not
16043 been previously registered in the dll list.
16044
177321bd
DJ
160452010-02-01 Daniel Jacobowitz <dan@codesourcery.com>
16046
16047 * linux-arm-low.c (thumb_breakpoint_len): Delete.
16048 (thumb2_breakpoint): New.
16049 (arm_breakpoint_at): Check for Thumb-2 breakpoints.
16050
2b009048
DJ
160512010-01-29 Daniel Jacobowitz <dan@codesourcery.com>
16052
16053 * linux-low.c (get_stop_pc): Check for SIGTRAP.
16054 (linux_wait_for_event_1): Handle SIGILL and SIGSEGV as possible
16055 breakpoints.
16056
3be029c7
PA
160572010-01-21 Pedro Alves <pedro@codesourcery.com>
16058
16059 * linux-ppc-low.c (ppc_arch_setup): Adjust to regcache changes.
16060
18f5de3b
JK
160612010-01-21 Jan Kratochvil <jan.kratochvil@redhat.com>
16062
16063 * linux-s390-low.c (s390_collect_ptrace_register)
16064 (s390_supply_ptrace_register): Adjust it for the new regcache parameter.
16065
3743bb4f
DE
160662010-01-21 Doug Evans <dje@google.com>
16067
14ce3065
DE
16068 * linux-low.c (PTRACE_ARG3_TYPE): Change from long to void*.
16069 (PTRACE_ARG4_TYPE): New macro.
16070 (handle_extended_wait): Cast ptrace arg4 to PTRACE_ARG4_TYPE.
16071 (linux_wait_for_event_1, linux_resume_one_lwp): Ditto.
16072 (fetch_register): Cast to uintptr_t before casting to PTRACE_ARG3_TYPE.
16073 (usr_store_inferior_registers): Ditto.
16074 (linux_read_memory, linux_write_memory): Ditto.
16075 (linux_test_for_tracefork): Ditto.
16076
3743bb4f
DE
16077 * linux-arm-low.c: Remove redundant include of gdb_proc_service.h.
16078 Only include elf.h if gdb_proc_service.h didn't include linux/elf.h.
16079
8b315be5
PA
160802010-01-21 Pedro Alves <pedro@codesourcery.com>
16081
16082 * proc-service.c (ps_lgetregs): Don't refetch registers from the
16083 target.
16084
85492558
PA
160852010-01-21 Pedro Alves <pedro@codesourcery.com>
16086
16087 * spu-low.c (spu_fetch_registers, spu_store_registers): Change
16088 prototype to take a regcache. Adjust.
16089
442ea881
PA
160902010-01-20 Pedro Alves <pedro@codesourcery.com>
16091
16092 * regcache.h (struct thread_info): Forward declare.
16093 (struct regcache): New.
16094 (new_register_cache): Adjust prototype.
16095 (get_thread_regcache): Declare.
16096 (free_register_cache): Adjust prototype.
16097 (registers_to_string, registers_from_string): Ditto.
16098 (supply_register, supply_register_by_name, collect_register)
16099 (collect_register_as_string, collect_register_by_name): Ditto.
16100 * regcache.c (struct inferior_regcache_data): Delete.
16101 (get_regcache): Rename to ...
16102 (get_thread_regcache): ... this. Adjust. Switch inferior before
16103 fetching registers.
16104 (regcache_invalidate_one): Adjust.
16105 (regcache_invalidate): Fix prototype.
16106 (new_register_cache): Return the new register cache.
16107 (free_register_cache): Change prototype.
16108 (realloc_register_cache): Adjust.
16109 (registers_to_string): Change prototype to take a regcache. Adjust.
16110 (registers_from_string): Ditto.
16111 (register_data): Ditto.
16112 (supply_register): Ditto.
16113 (supply_register_by_name): Ditto.
16114 (collect_register): Ditto.
16115 (collect_register_as_string): Ditto.
16116 (collect_register_by_name): Ditto.
16117 * server.c (process_serial_event): Adjust.
16118 * linux-low.h (regset_fill_func, regset_store_func): Change
16119 prototype.
16120 (get_pc, set_pc, collect_ptrace_register, supply_ptrace_register):
16121 Change prototype.
16122 * linux-low.c (get_stop_pc): Adjust.
16123 (check_removed_breakpoint): Adjust.
16124 (linux_wait_for_event): Adjust.
16125 (linux_resume_one_lwp): Adjust.
16126 (fetch_register): Add regcache parameter. Adjust.
16127 (usr_store_inferior_registers): Ditto.
16128 (regsets_fetch_inferior_registers): Ditto.
16129 (regsets_store_inferior_registers): Ditto.
16130 (linux_fetch_registers, linux_store_registers): Ditto.
16131 * i387-fp.c (i387_cache_to_fsave): Change prototype to take a
16132 regcache. Adjust.
43aaf8b6
PA
16133 (i387_fsave_to_cache, i387_cache_to_fxsave, i387_fxsave_to_cache):
16134 Ditto.
442ea881
PA
16135 * i387-fp.h (i387_cache_to_fsave, i387_fsave_to_cache): Change
16136 prototype to take a regcache.
16137 (i387_cache_to_fxsave, i387_fxsave_to_cache): Ditto.
16138 * remote-utils.c (convert_ascii_to_int, outreg)
16139 (prepare_resume_reply): Change prototype to take a regcache.
16140 Adjust.
16141 * target.h (struct target_ops) <fetch_registers, store_registers>:
16142 Change prototype to take a regcache.
16143 (fetch_inferior_registers, store_inferior_registers): Change
16144 prototype to take a regcache. Adjust.
16145 * proc-service.c (ps_lgetregs): Adjust.
16146 * linux-x86-low.c (x86_fill_gregset, x86_store_gregset)
16147 (x86_fill_fpregset, x86_store_fpregset, x86_fill_fpxregset)
16148 (x86_store_fpxregset, x86_get_pc, x86_set_pc): Change prototype to
16149 take a regcache. Adjust.
16150 * linux-arm-low.c (arm_fill_gregset, arm_store_gregset)
16151 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
16152 (arm_store_vfpregset, arm_get_pc, arm_set_pc):
16153 (arm_breakpoint_at): Change prototype to take a regcache. Adjust.
16154 * linux-cris-low.c (cris_get_pc, cris_set_pc)
16155 (cris_cannot_fetch_register):
16156 (cris_breakpoint_at): Change prototype to take a regcache.
16157 Adjust.
16158 * linux-crisv32-low.c (cris_get_pc, cris_set_pc,
16159 cris_reinsert_addr, cris_write_data_breakpoint): Change prototype
16160 to take a regcache. Adjust.
16161 (cris_breakpoint_at, cris_insert_point, cris_remove_point):
16162 Adjust.
16163 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Change prototype to
16164 take a regcache. Adjust.
16165 * linux-m68k-low.c (m68k_fill_gregset, m68k_store_gregset)
16166 (m68k_fill_fpregset, m68k_store_fpregset, m68k_get_pc,
16167 (m68k_set_pc): Change prototype to take a regcache. Adjust.
16168 * linux-mips-low.c (mips_get_pc):
16169 (mips_set_pc): Change prototype to take a regcache. Adjust.
16170 (mips_reinsert_addr): Adjust.
16171 (mips_collect_register): Change prototype to take a regcache.
16172 Adjust.
16173 (mips_supply_register):
16174 (mips_collect_register_32bit, mips_supply_register_32bit)
16175 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
16176 (mips_store_fpregset): Ditto.
43aaf8b6
PA
16177 * linux-ppc-low.c (ppc_supply_ptrace_register)
16178 (ppc_supply_ptrace_register): Ditto.
442ea881
PA
16179 (parse_spufs_run): Adjust.
16180 (ppc_get_pc, ppc_set_pc, ppc_fill_gregset, ppc_fill_vsxregset)
16181 (ppc_store_vsxregset, ppc_fill_vrregset, ppc_store_vrregset)
16182 (ppc_fill_evrregset, ppc_store_evrregset): Change prototype to
16183 take a regcache. Adjust.
16184 * linux-s390-low.c (s390_collect_ptrace_register)
16185 (s390_supply_ptrace_register, s390_fill_gregset, s390_get_pc)
16186 (s390_set_pc): Change prototype to take a regcache. Adjust.
16187 (s390_arch_setup): Adjust.
16188 * linux-sh-low.c (sh_get_pc, sh_breakpoint_at)
16189 (sh_fill_gregset): Change prototype to take a regcache. Adjust.
16190 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
16191 (sparc_fill_gregset, sparc_store_gregset_from_stack)
16192 (sparc_store_gregset, sparc_get_pc): Change prototype to take a
16193 regcache. Adjust.
16194 (sparc_breakpoint_at): Adjust.
16195 * linux-xtensa-low.c (xtensa_fill_gregset):
16196 (xtensa_store_gregset):
16197 (xtensa_fill_xtregset, xtensa_store_xtregset, xtensa_get_pc)
16198 (xtensa_set_pc): Change prototype to take a regcache. Adjust.
16199 * nto-low.c (nto_fetch_registers, nto_store_registers): Change
16200 prototype to take a regcache. Adjust.
16201 * win32-arm-low.c (arm_fetch_inferior_register)
16202 (arm_store_inferior_register): Change prototype to take a
16203 regcache. Adjust.
16204 * win32-i386-low.c (i386_fetch_inferior_register)
16205 (i386_store_inferior_register): Change prototype to take a
16206 regcache. Adjust.
16207 * win32-low.c (child_fetch_inferior_registers)
16208 (child_store_inferior_registers): Change prototype to take a
16209 regcache. Adjust.
16210 (win32_wait): Adjust.
16211 (win32_fetch_inferior_registers): Change prototype to take a
16212 regcache. Adjust.
16213 (win32_store_inferior_registers): Adjust.
16214 * win32-low.h (struct win32_target_ops) <fetch_inferior_register,
16215 store_inferior_register>: Change prototype to take a regcache.
16216
60c3d7b0
DE
162172010-01-20 Doug Evans <dje@google.com>
16218
16219 * linux-low.c (linux_create_inferior): Wrap use of __SIGRTMIN in
16220 #ifdef.
16221 (linux_wait_for_event1, linux_init_signals): Ditto.
ec8ebe72 16222 (W_STOPCODE): Provide definition if missing.
60c3d7b0 16223
dc146f7c
VP
162242010-01-13 Vladimir Prus <vladimir@codesourcery.com>
16225
16226 * linux-low.c (linux_core_of_thread): New.
16227 (compare_ints, show_process, list_threads): New.
16228 (linux_qxfer_osdata): Report threads and cores.
16229 (linux_target_op): Register linux_core_of_thread.
16230 * remote-utils.c (prepare_resume_reply): Report the core.
16231 (buffer_xml_printf): Support %d specifier.
16232 * server.c (handle_threads_qxfer_proper, handle_threads_qxfer):
16233 New.
16234 (handle_query): Handle qXfer:threads. Announce availability
16235 thereof.
16236 * target.h (struct target_ops): New field core_of_thread.
16237
7803799a
UW
162382010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
16239
16240 * Makefile.in (clean): Remove new generated files.
16241 (reg-s390.o, reg-s390.c): Remove rules.
16242 (reg-s390x.o, reg-s390x.c): Likewise.
16243 (s390-linux32.o, s390-linux32.c): Add rules.
16244 (s390-linux64.o, s390-linux64.c): Likewise.
16245 (s390x-linux64.o, s390x-linux64.c): Likewise.
16246 * configure.srv (s390*-*-linux*): Update srv_regobj and srv_xmlfiles.
16247 * linux-s390-low.c: Include <elf.h>.
16248 (HWCAP_S390_HIGH_GPRS): Define if undefined.
16249 (init_registers_s390): Remove prototype.
16250 (init_registers_s390x): Likewise.
16251 (init_registers_s390_linux32): Add prototype.
16252 (init_registers_s390_linux64): Likewise.
16253 (init_registers_s390x_linux64): Likewise.
16254 (s390_num_regs_3264): New define.
16255 (s390_regmap_3264): New global variable.
16256 (s390_cannot_fetch_register): Remove obsolete check.
16257 (s390_cannot_store_register): Likewise.
16258 (s390_collect_ptrace_register): Handle upper/lower register halves.
16259 (s390_supply_ptrace_register): Likewise.
16260 (s390_fill_gregset): Update to register number changes.
16261 (s390_get_hwcap): New routine.
16262 (s390_arch_setup): Detect 32-bit process running on 64-bit system.
16263 Install appropriate regmap and register set.
16264
6e7ffa39
JB
162652010-01-01 Joel Brobecker <brobecker@adacore.com>
16266
16267 * server.c (gdbserver_version): Update copyright year to 2010.
16268 * gdbreplay.c (gdbreplay_version): Likewise.
16269
957f3f49
DE
162702009-12-28 Doug Evans <dje@google.com>
16271
16272 * linux-low.c: Delete inclusion of ansidecl.h, elf/common.h,
16273 elf/external.h. Include <elf.h> instead but only if necessary.
16274
ca5c370d
PA
162752009-12-28 Pedro Alves <pedro@codesourcery.com>
16276
16277 * linux-low.c (linux_remove_process): Remove `detaching'
16278 parameter. Don't release/detach from thread_db here.
16279 (linux_kill): Release/detach from thread_db here, ...
16280 (linux_detach): ... and here, before actually detaching.
16281 (linux_wait_1): ... and here, when a process exits.
16282 * thread-db.c (any_thread_of): New.
16283 (thread_db_free): Switch the current inferior to a thread of the
16284 passed in process.
16285
4ee62156
DE
162862009-12-21 Doug Evans <dje@google.com>
16287
d90e6a88
DE
16288 * linux-x86-low.c: Delete outdated comment about Elf32_Phdr.
16289
c5f62d5f
DE
16290 * linux-low.c (kill_lwp): Use __NR_tkill instead of SYS_tkill.
16291 Move definition of tkill_failed to ifdef __NR_tkill to avoid gcc
16292 warning ifndef __NR_tkill. Move setting of errno there too.
16293 Delete unnecessary resetting of errno after syscall.
16294 Minor comment changes to match gdb/linux-nat.c:kill_lwp.
16295
10e86dd7
DE
16296 * configure.ac: Check for dladdr.
16297 * config.in: Regenerate.
16298 * configure: Regenerate.
16299 * thread-db.c (dladdr_to_soname): Only define ifdef HAVE_DLADDR.
16300 (try_thread_db_load): Update.
16301
4ee62156
DE
16302 * linux-low.c (my_waitpid): Delete unnecessary prototype.
16303
00f515da
DE
163042009-12-18 Doug Evans <dje@google.com>
16305
e9464885
DE
16306 * event-loop.c: Include unistd.h if it exists.
16307
07d4f67e
DE
16308 * linux-low.c (my_waitpid): Move definition away from being in
16309 between linux_tracefork_child/linux_test_for_tracefork.
16310
00f515da
DE
16311 * gdb_proc_service.h (psaddr_t): Fix type.
16312 * thread-db.c (thread_db_info.td_thr_tls_get_addr_p): Fix
16313 signature to match glibc.
16314
1de1badb
DE
163152009-12-16 Doug Evans <dje@google.com>
16316
16317 * linux-low.c (linux_read_memory): Fix argument to read.
16318
aeeb81d1
PA
163192009-11-26 Pedro Alves <pedro@codesourcery.com>
16320
16321 * win32-low.c (get_child_debug_event): On EXIT_THREAD_DEBUG_EVENT
16322 events, don't leave current_inferior pointing at null.
16323
10357975
PA
163242009-11-26 Pedro Alves <pedro@codesourcery.com>
16325
16326 * win32-low.c (LOG): Delete.
16327 (OUTMSG): Output to stderr.
16328 (OUTMSG2): Conditionalize on `debug_threads' variable, instead of
16329 on compile time LOG macro.
16330 (win32_wait): Fix debug output.
16331
cf6e3471
PA
163322009-11-26 Pedro Alves <pedro@codesourcery.com>
16333
16334 * win32-low.c (win32_add_one_solib): If the dll name is
16335 "ntdll.dll", prepend the system directory to the dll path.
16336
0c85e18e
MK
163372009-11-17 Daniel Jacobowitz <dan@codesourcery.com>
16338
16339 * m68k-tdep.c (m68k_gdbarch_init): Reuse previous initialization.
16340
9ac544ce 163412009-11-17 Nathan Sidwell <nathan@codesourcery.com>
889bf7c5 16342 Vladimir Prus <vladimir@codesourcery.com>
9ac544ce
MK
16343
16344 * Makefile.in (reg-cf.o, reg-cf.c): New targets.
16345 * configure.ac: Check for __mcoldfire__ and set
16346 gdb_cv_m68k_is_coldfire.
16347 * configure.srv: Use gdb_cv_m68k_is_coldfire to select between
16348 reg-cf.o and reg-m68k.o.
16349 * configure: Regenerated.
16350
fd7dd3e6
PA
163512009-11-16 Pedro Alves <pedro@codesourcery.com>
16352
16353 * linux-low.c (linux_remove_process): Add `detaching' parameter.
16354 Pass it to thread_db_free.
16355 (linux_kill, linux_detach, linux_wait_1): Adjust to pass the
16356 proper `detaching' argument to linux_remove_process.
16357 * linux-low.h (thread_db_free): Add `detaching' parameter.
16358 * thread-db.c (thread_db_init): Pass false as `detaching' argument
16359 to thread_db_free.
16360 (thread_db_free): Add `detaching' parameter. Only
16361 call td_ta_clear_event if detaching from process.
16362
75aa492e
MK
163632009-11-12 Maxim Kuvyrkov <maxim@codesourcery.com>
16364
16365 * thread-db.c (thread_db_free): Fix typo.
16366
21e1bee4
PP
163672009-11-11 Paul Pluzhnikov <ppluzhnikov@google.com>
16368
16369 PR gdb/10838
16370 * thread-db.c (thread_db_free): Call td_ta_clear_event.
16371
8838b45e
NS
163722009-11-03 Nathan Sidwell <nathan@codesourcery.com>
16373
16374 * configure.ac (i[34567]86-*): Check if we're targetting x86-64
16375 with an i686 compiler.
16376 * configure.srv (i[34567]86-*-linux*): Pull in x86-64 handling if
16377 needed.
16378 * configure: Rebuilt.
16379
8a35fb51
SL
163802009-10-29 Sandra Loosemore <sandra@codesourcery.com>
16381
16382 PR gdb/10783
16383
16384 * server.c (handle_search_memory_1): Correct read_addr initialization
16385 in loop for searching subsequent chunks.
16386
96f15937
PP
163872009-10-29 Paul Pluzhnikov <ppluzhnikov@google.com>
16388
16389 * configure.ac: New --with-libthread-db option.
16390 * thread-db.c: Allow direct dependence on libthread_db.
16391 (thread_db_free): Adjust.
16392 * config.in: Regenerate.
16393 * configure: Likewise.
889bf7c5 16394
5f7d1694
PP
163952009-10-28 Paul Pluzhnikov <ppluzhnikov@google.com>
16396
16397 PR gdb/10757
16398 * thread-db.c (attach_thread): New function.
16399 (maybe_attach_thread): Return success/failure.
16400 (find_new_threads_callback): Adjust.
889bf7c5
PA
16401 (thread_db_find_new_threads): Loop until no new threads.
16402
88e3b899
PA
164032009-10-13 Pedro Alves <pedro@codesourcery.com>
16404
16405 * proc-service.c (ps_lgetregs): Formatting.
16406
cdbfd419
PP
164072009-10-08 Paul Pluzhnikov <ppluzhnikov@google.com>
16408
16409 * acinclude.m4: (SRV_CHECK_THREAD_DB, SRV_CHECK_TLS_GET_ADDR): Remove.
16410 * configure.ac: Adjust.
16411 * linux-low.h (struct process_info_private): Move members to struct
16412 thread_db.
16413 (thread_db_free, thread_db_handle_monitor_command): New prototype.
16414 * linux-low.c (linux_remove_process): Adjust.
16415 (linux_wait_for_event_1, linux_look_up_symbols): Likewise.
16416 * server.c (handle_query): Move code ...
16417 (handle_monitor_command): ... here. New function.
16418 * target.h (struct target_ops): New member.
16419 * thread-db.c (struct thread_db): New.
16420 (libthread_db_search_path): New variable.
16421 (thread_db_create_event, thread_db_enable_reporting)
16422 (find_one_thread, maybe_attach_thread, find_new_threads_callback)
16423 (thread_db_find_new_threads, (thread_db_get_tls_address): Adjust.
16424 (try_thread_db_load_1, dladdr_to_soname): New functions.
16425 (try_thread_db_load, thread_db_load_search): New functions.
16426 (thread_db_init): Search for libthread_db.
16427 (thread_db_free): New function.
16428 (thread_db_handle_monitor_command): Likewise.
16429 * config.in: Regenerate.
16430 * configure: Regenerate.
889bf7c5 16431
4168d2d6
UW
164322009-09-27 Ulrich Weigand <uweigand@de.ibm.com>
16433
16434 * spu-low.c (spu_kill): Wait for inferior to terminate.
16435 Call clear_inferiors.
16436 (spu_detach): Call clear_inferiors.
16437
81ecdfbb
RW
164382009-08-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
16439
16440 * aclocal.m4: Regenerate.
16441 * config.in: Likewise.
16442 * configure: Likewise.
16443
0b9ff2c0
UW
164442009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
16445
16446 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Define.
16447 (parse_spufs_run): New function.
16448 (ppc_get_pc, ppc_set_pc): Detect and handle SPU PC.
16449 (ppc_breakpoint_at): Handle SPU breakpoints.
16450
efcbbd14
UW
164512009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
16452
16453 * linux-low.c: Include <sys/stat.h> and <sys/vfs.h>.
16454 (SPUFS_MAGIC): Define.
16455 (spu_enumerate_spu_ids): New function.
16456 (linux_qxfer_spu): New function.
16457 (linux_target_ops): Install linux_qxfer_spu.
16458
f4d9bade
UW
164592009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
16460
16461 * configure.srv (powerpc*-*-linux*): Add powerpc-cell32l.o
16462 and powerpc-cell64l.o to srv_regobj. Add rs6000/powerpc-cell32l.xml
16463 and rs6000/powerpc-cell64l.xml to srv_xmlfiles.
16464 * Makefile.in (powerpc-cell32l.o, powerpc-cell32l.c): New rules.
16465 (powerpc-cell64l.o, powerpc-cell64l.c): Likewise.
16466 (clean): Handle powerpc-cell32l.c and powerpc-cell64l.c.
16467 * linux-ppc-low.c (PPC_FEATURE_CELL): Define.
16468 (init_registers_powerpc_cell32l): Add prototype.
16469 (init_registers_powerpc_cell64l): Likewise.
16470 (ppc_arch_setup): Detect Cell/B.E. architecture.
16471
96e946ca
RW
164722009-07-30 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
16473
16474 * Makefile.in (datarootdir): New variable.
16475
58d6951d
DJ
164762009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
16477
16478 * linux-low.c (linux_write_memory): Update debugging output.
16479 * Makefile.in (clean): Add new descriptions.
16480 (arm-with-vfpv2.o, arm-with-vfpv2.c, arm-with-vfpv3.o)
16481 (arm-with-vfpv3.c, arm-with-neon.o, arm-with-neon.c): New rules.
16482 * configure.srv: Add new files for arm*-*-linux*.
16483 * linux-arm-low.c: Add new declarations.
16484 (PTRACE_GETVFPREGS, PTRACE_SETVFPREGS): Define if undefined.
16485 (arm_hwcap, HWCAP_VFP, HWCAP_IWMMXT, HWCAP_NEON, HWCAP_VFPv3)
16486 (HWCAP_VFPv3D16): New.
16487 (arm_fill_wmmxregset, arm_store_wmmxregset): Check HWCAP_IWMMXT
16488 instead of __IWMMXT__.
16489 (arm_fill_vfpregset, arm_store_vfpregset, arm_get_hwcap)
16490 (arm_arch_setup): New.
16491 (target_regsets): Remove #ifdef. Add VFP regset.
16492 (the_low_target): Use arm_arch_setup.
16493
12b42a12
DJ
164942009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
16495
16496 * linux-low.c (linux_kill_one_lwp): Adjust kernel workaround to skip
16497 the main thread again.
16498
ac8c974e
AR
164992009-07-06 Aleksandar Ristovski <aristovski@qnx.com>
16500
16501 Adding Neutrino gdbserver.
16502 * configure: Regenerated.
16503 * configure.ac: Add case for srv_qnx and set LIBS accordingly.
16504 * configure.srv (i[34567]86-*-nto*): New target.
16505 * nto-low.c, nto-low.h, nto-x86-low.c: New files.
16506 * remote-utils.c [__QNX__]: Include sys/iomgr.h
16507 (nto_comctrl) [__QNX__]: New function.
16508 (enable_async_io, disable_async_io) [__QNX__]: Call nto_comctrl.
16509
4424e0c3 165102009-07-05 Danny Backx <dannybackx@users.sourceforge.net>
7437790a
PA
16511
16512 * configure.srv (i[34567]86-*-mingw32ce*): Add i386-low.o to
16513 srv_tgtobj.
16514
912cf4ba
PA
165152009-07-04 Danny Backx <dannybackx@users.sourceforge.net>
16516 Pedro Alves <pedro@codesourcery.com>
16517
16518 * win32-i386-low.c (i386_get_thread_context): Handle systems that
16519 don't support CONTEXT_EXTENDED_REGISTERS.
16520 (i386_win32_breakpoint, i386_win32_breakpoint_len): New.
16521 (the_low_target): Install them.
16522 * win32-low.c (get_child_debug_event): Handle WaitForDebugEvent
16523 failing with ERROR_PIPE_NOT_CONNECTED.
16524
aa5ca48f
DE
165252009-06-30 Doug Evans <dje@google.com>
16526 Pierre Muller <muller@ics.u-strasbg.fr>
16527
16528 Add h/w watchpoint support to x86-linux, win32-i386.
16529 * Makefile.in (SFILES): Add i386-low.c
16530 (i386_low_h): Define.
16531 (i386-low.o): Add dependencies.
16532 (linux-x86-low.o): Add i386-low.h dependency.
16533 (win32-i386-low.o): Ditto.
16534 * i386-low.c: New file.
16535 * i386-low.h: New file.
16536 * configure.srv (i[34567]86-*-cygwin*): Add i386-low.o to srv_tgtobj.
16537 (i[34567]86-*-linux*, i[34567]86-*-mingw*, x86_64-*-linux*): Ditto.
16538 * linux-low.c (linux_add_process): Initialize arch_private.
16539 (linux_remove_process): Free arch_private.
16540 (add_lwp): Initialize arch_private.
16541 (delete_lwp): Free arch_private.
16542 (linux_resume_one_lwp): Call the_low_target.prepare_to_resume if
16543 provided.
16544 * linux-low.h (process_info_private): New member arch_private.
16545 (lwp_info): New member arch_private.
16546 (linux_target_ops): New members new_process, new_thread,
16547 prepare_to_resume.
16548 (ptid_of): New macro.
16549 * linux-x86-low.c: Include stddef.h, i386-low.h.
16550 (arch_process_info): New struct.
16551 (arch_lwp_info): New struct.
16552 (x86_linux_dr_get, x86_linux_dr_set): New functions.
16553 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
16554 (i386_dr_low_get_status): New function.
16555 (x86_insert_point, x86_remove_point): New functions.
16556 (x86_stopped_by_watchpoint): New function.
16557 (x86_stopped_data_address): New function.
16558 (x86_linux_new_process, x86_linux_new_thread): New functions.
16559 (x86_linux_prepare_to_resume): New function.
16560 (the_low_target): Add entries for insert_point, remove_point,
16561 stopped_by_watchpoint, stopped_data_address, new_process, new_thread,
16562 prepare_to_resume.
16563 * server.c (debug_hw_points): New global.
16564 (monitor_show_help): Document set debug-hw-points.
16565 (handle_query): Process "set debug-hw-points".
16566 * server.h (debug_hw_points): Declare.
16567 (paddress): Declare.
16568 * utils.c (NUMCELLS, CELLSIZE): New macros.
16569 (get_sell, xsnprintf, paddress): New functions.
16570 * win32-arm-low.c (the_low_target): Add entries for insert_point,
16571 remove_point, stopped_by_watchpoint, stopped_data_address.
16572 * win32-i386-low.c: Include i386-low.h.
16573 (debug_reg_state): Replaces dr.
16574 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
16575 (i386_dr_low_get_status): New function.
16576 (i386_insert_point, i386_remove_point): New functions.
16577 (i386_stopped_by_watchpoint): New function.
16578 (i386_stopped_data_address): New function.
16579 (i386_initial_stuff): Update.
16580 (get_thread_context,set_thread_context,i386_thread_added): Update.
16581 (the_low_target): Add entries for insert_point,
16582 remove_point, stopped_by_watchpoint, stopped_data_address.
16583 * win32-low.c (win32_insert_watchpoint): New function.
16584 (win32_remove_watchpoint): New function.
16585 (win32_stopped_by_watchpoint): New function.
16586 (win32_stopped_data_address): New function.
16587 (win32_target_ops): Add entries for insert_watchpoint,
16588 remove_watchpoint, stopped_by_watchpoint, stopped_data_address.
16589 * win32-low.h (win32_target_ops): New members insert_point,
16590 remove_point, stopped_by_watchpoint, stopped_data_address.
16591
d993e290
PA
165922009-06-25 Pedro Alves <pedro@codesourcery.com>
16593
16594 * server.c (process_serial_event): Re-return unsupported, not
16595 error, if the type isn't recognized. Re-allow supporting only
16596 insert or remove packets. Also call require_running for
16597 breakpoints. Add missing break statement to default case. Tidy.
16598 * target.h (struct target_ops): Rename insert_watchpoint to
16599 insert_point, and remove_watchpoint to remove_point.
16600
16601 * linux-low.h (struct linux_target_ops): Likewise.
16602 * linux-low.c (linux_insert_watchpoint): Rename to ...
16603 (linux_insert_point): ... this. Adjust.
16604 (linux_remove_watchpoint): Rename to ...
16605 (linux_remove_point): ... this. Adjust.
16606 (linux_target_ops): Adjust.
16607 * linux-crisv32-low.c (cris_insert_watchpoint): Rename to ...
16608 (cris_insert_point): ... this.
16609 (cris_remove_watchpoint): Rename to ...
16610 (cris_remove_point): ... this.
16611 (the_low_target): Adjust.
16612
0f54c268
PM
166132009-06-24 Pierre Muller <muller@ics.u-strasbg.fr>
16614
16615 * server.c (handle_v_kill): Pass signal_pid to
16616 kill_inferior if multi_process is zero.
16617
c6314022
AR
166182009-06-23 Aleksandar Ristovski <aristovski@qnx.com>
16619
16620 * server.c (process_serial_event): Add support for Z0 and Z1 packet.
16621 * target.h (target_ops): Comment for *_watchpoint to make it clear
16622 the functions can get types '0' and '1'.
16623
4463ce24
AR
166242009-06-22 Aleksandar Ristovski <aristovski@qnx.com>
16625
16626 * linux-low.c (usr_fetch_inferior_registers): Remove check for regno 0.
16627 * proc-service.c (ps_lgetregs): Pass -1 to fetch all registers.
16628 * regcache.c (get_regcache): Likewise.
16629 * spu-low.c (spu_fetch_registers): Remove 0 to -1 conversion.
16630 * win32-low.c (child_fetch_inferior_registers): Remove check for
16631 regno 0.
16632
cf8fd78b
PA
166332009-06-19 Aleksandar Ristovski <aristovski@qnx.com>
16634 Pedro Alves <pedro@codesourcery.com>
16635
16636 * target.h (struct target_ops) <supports_multi_process>: New
16637 callback.
16638 (target_supports_multi_process): New.
16639 * server.c (handle_query): Even if GDB reports support, only
16640 enable multi-process if the target also supports it. Report
16641 multi-process support only if the target backend supports it.
16642 * linux-low.c (linux_supports_multi_process): New function.
16643 (linux_target_ops): Install it as target_supports_multi_process
16644 callback.
16645
47c0c975
DE
166462009-05-24 Doug Evans <dje@google.com>
16647
e09875d4
DE
16648 Global renaming of find_thread_pid to find_thread_ptid.
16649 * server.h (find_thread_ptid): Renamed from find_thread_pid.
16650 * inferiors.c (find_thread_ptid): Renamed from find_thread_pid.
16651 All callers updated.
16652
e27d73f6
DE
16653 * linux-low.c (handle_extended_wait): Use linux_resume_one_lwp
16654 to resume the newly created thread, don't call ptrace (PTRACE_CONT)
16655 directly.
16656
47c0c975
DE
16657 * linux-low.c (get_stop_pc): Print pc if debug_threads.
16658 (check_removed_breakpoint, linux_wait_for_lwp): Ditto.
16659 (linux_resume_one_lwp): Ditto.
16660
2acc282a
DE
166612009-05-23 Doug Evans <dje@google.com>
16662
16663 * linux-low.c (linux_resume_one_lwp): Change type of first arg
16664 from struct inferior_list_entry * to struct lwp_info *.
16665 All callers updated.
16666
9f1036c1
DE
166672009-05-13 Doug Evans <dje@google.com>
16668
16669 * linux-x86-low.c: Don't include assert.h.
16670 (x86_siginfo_fixup): Use fatal, not assert.
16671 (x86_arch_setup): Fix comment.
16672
d0722149
DE
166732009-05-12 Doug Evans <dje@google.com>
16674
16675 Biarch support for i386/amd64 gdbserver.
16676 * Makefile.in (SFILES): Remove linux-i386-low.c, linux-x86-64-low.c.
16677 Add linux-x86-low.c.
16678 (linux-i386-low.o, linux-x86-64-low.o): Delete.
16679 (linux-x86-low.o): Add.
16680 * linux-x86-64-low.c: Delete.
16681 * linux-i386-low.c: Delete.
16682 * linux-x86-low.c: New file.
16683 * configure.srv (i?86-linux srv_tgtobj): Replace linux-i386-low.o with
16684 linux-x86-low.o.
16685 (x86_64-linux srv_tgtobj): Replace linux-x86-64-low.o with
16686 linux-x86-low.o.
16687 (x86_64-linux srv_regobj): Add reg-i386-linux.o.
16688 * linux-low.c: Include ansidecl.h, elf/common.h, elf/external.h.
16689 (linux_child_pid_to_exec_file): New function.
16690 (elf_64_header_p, elf_64_file_p): New functions.
16691 (siginfo_fixup): New function.
16692 (linux_xfer_siginfo): New local inf_siginfo. Call siginfo_fixup to
16693 give target a chance to convert layout.
16694 * linux-low.h (linux_target_ops): New member siginfo_fixup.
16695 (linux_child_pid_to_exec_file, elf_64_file_p): Declare.
16696
fdeb2a12
DE
166972009-05-07 Doug Evans <dje@google.com>
16698
16699 * linux-low.c (regsets_fetch_inferior_registers): Fix memory leak.
16700 (regsets_store_inferior_registers): Ditto.
16701
a6dbe5df
PA
167022009-05-06 Pedro Alves <pedro@codesourcery.com>
16703
16704 PR server/10048
16705
16706 * linux-low.c (must_set_ptrace_flags): Delete.
16707 (linux_create_inferior): Set `lwp->must_set_ptrace_flags' instead
16708 of the global.
16709 (linux_attach_lwp_1): Don't set PTRACE_SETOPTIONS here. Set
16710 `lwp->must_set_ptrace_flags' instead.
ba42693b 16711 (linux_wait_for_event_1): Set ptrace options here.
a6dbe5df
PA
16712 (linux_wait_1): ... not here.
16713
5091eb23
DE
167142009-04-30 Doug Evans <dje@google.com>
16715
9f767825
DE
16716 * inferiors.c (started_inferior_callback): New function.
16717 (attached_inferior_callback): New function.
16718 (have_started_inferiors_p, have_attached_inferiors_p): New functions.
16719 * server.c (print_started_pid, print_attached_pid): New functions.
16720 (detach_or_kill_for_exit): New function.
16721 (main): Call it instead of for_each_inferior (kill_inferior_callback).
16722 * server.h (have_started_inferiors_p): Declare.
16723 (have_attached_inferiors_p): Declare.
16724
5091eb23
DE
16725 * inferiors.c (remove_process): Fix memory leak, free process.
16726 * linux-low.c (linux_remove_process): New function.
16727 (linux_kill): Call it instead of remove_process.
16728 (linux_detach, linux_wait_1): Ditto.
16729
155c8968
PA
167302009-04-19 Danny Backx <dannybackx@users.sourceforge.net>
16731
16732 * configure.srv: Add x86 Windows CE target.
16733
7fe519cb
UW
167342009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
16735
16736 * inferiors.c (get_thread_process): Make global.
16737 * server.h (get_thread_process): Add prototype.
16738 * thread-db.c (find_one_thread): Use get_thread_process
16739 instead of current_process.
16740 (thread_db_get_tls_address): Do not crash if called when
16741 thread layer is not yet initialized.
16742
5472f405
UW
167432009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
16744
16745 * remote-utils.c (prepare_resume_reply): Null-terminate packet.
16746 * spu-low.c (current_tid): Rename to ...
16747 (current_ptid): ... this.
16748 (fetch_ppc_register, fetch_ppc_memory, store_ppc_memory,
16749 spu_proc_xfer_spu, spu_resume, spu_request_interrupt): Use
16750 ptid_get_lwp (current_ptid) instead of current_tid.
16751 (spu_kill, spu_detach, spu_join, spu_wait): Use pid argument
16752 instead of current_tid. Use find_process_pid to verify pid
16753 argument is valid. Pass proper argument to remove_process.
16754 (spu_thread_alive): Compare current_ptid instead of current_tid.
16755 (spu_resume): Likewise.
16756
55ac2b99
PA
167572009-04-02 Pedro Alves <pedro@codesourcery.com>
16758
16759 * linux-low.c (usr_store_inferior_registers): Declare local `pid'
16760 variable.
16761
95954743
PA
167622009-04-01 Pedro Alves <pedro@codesourcery.com>
16763
16764 Implement the multiprocess extensions, and add linux multiprocess
16765 support.
16766
16767 * server.h (ULONGEST): Declare.
16768 (struct ptid, ptid_t): New.
16769 (minus_one_ptid, null_ptid): Declare.
16770 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
16771 (ptid_get_tid, ptid_equal, ptid_is_pid): Declare.
16772 (struct inferior_list_entry): Change `id' type from unsigned from
16773 to ptid_t.
16774 (struct sym_cache, struct breakpoint, struct
16775 process_info_private): Forward declare.
16776 (struct process_info): Declare.
16777 (current_process): Declare.
16778 (all_processes): Declare.
16779 (initialize_inferiors): Declare.
16780 (add_thread): Adjust to use ptid_t.
16781 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): Ditto.
16782 (add_process, remove_process, find_thread_pid): Declare.
16783 (find_inferior_id): Adjust to use ptid_t.
16784 (cont_thread, general_thread, step_thread): Change type to ptid_t.
16785 (multi_process): Declare.
16786 (push_event): Adjust to use ptid_t.
16787 (read_ptid, write_ptid): Declare.
16788 (prepare_resume_reply): Adjust to use ptid_t.
16789 (clear_symbol_cache): Declare.
16790 * inferiors.c (all_processes): New.
16791 (null_ptid, minus_one_ptid): New.
16792 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
16793 (ptid_get_tid, ptid_equal, ptid_is_pid): New.
16794 (add_thread): Change unsigned long to ptid. Remove gdb_id
16795 parameter. Adjust.
16796 (thread_id_to_gdb_id, thread_to_gdb_id): Change unsigned long to ptid.
16797 (gdb_id_to_thread): Rename to ...
16798 (find_thread_pid): ... this. Change unsigned long to ptid.
16799 (gdb_id_to_thread_id, find_inferior_id): Change unsigned long to ptid.
16800 (loaded_dll, pull_pid_from_list): Adjust.
16801 (add_process, remove_process, find_process_pid)
16802 (get_thread_process, current_process, initialize_inferiors): New.
16803 * target.h (struct thread_resume) <thread>: Change type to ptid_t.
16804 (struct target_waitstatus) <related_pid>: Ditto.
16805 (struct target_ops) <kill, detach>: Add `pid' argument. Change
16806 return type to int.
16807 (struct target_ops) <join>: Add `pid' argument.
16808 (struct target_ops) <thread_alive>: Change pid's type to ptid_t.
16809 (struct target_ops) <wait>: Add `ptid' field. Change return type
16810 to ptid.
16811 (kill_inferior, detach_inferior, join_inferior): Add `pid' argument.
16812 (mywait): Add `ptid' argument. Change return type to ptid_t.
16813 (target_pid_to_str): Declare.
16814 * target.c (set_desired_inferior): Adjust to use ptids.
16815 (mywait): Add new `ptid' argument. Adjust.
16816 (target_pid_to_str): New.
16817 * mem-break.h (free_all_breakpoints): Declare.
16818 * mem-break.c (breakpoints): Delelete.
16819 (set_breakpoint_at, delete_breakpoint, find_breakpoint_at)
16820 (check_mem_read, check_mem_write, delete_all_breakpoints): Adjust
16821 to use per-process breakpoint list.
16822 (free_all_breakpoints): New.
16823 * remote-utils.c (struct sym_cache) <name>: Drop `const'.
16824 (symbol_cache, all_symbols_looked_up): Delete.
16825 (hexchars): New.
16826 (ishex, unpack_varlen_hex, write_ptid, hex_or_minus_one,
16827 read_ptid): New.
16828 (prepare_resume_reply): Change ptid argument's type from unsigned
16829 long to ptid_t. Adjust. Implement W;process and X;process.
16830 (free_sym_cache, clear_symbol_cache): New.
16831 (look_up_one_symbol): Adjust to per-process symbol cache. *
16832 * server.c (cont_thread, general_thread, step_thread): Change type
16833 to ptid_t.
16834 (attached): Delete.
16835 (multi_process): New.
16836 (last_ptid): Change type to ptid_t.
16837 (struct vstop_notif) <ptid>: Change type to ptid_t.
16838 (queue_stop_reply, push_event): Change `ptid' argument's type to
16839 ptid_t.
16840 (discard_queued_stop_replies): Add `pid' argument.
16841 (start_inferior): Adjust to use ptids. Adjust to mywait interface
16842 changes. Don't reference the `attached' global.
16843 (attach_inferior): Adjust to mywait interface changes.
16844 (handle_query): Adjust to use ptids. Parse GDB's qSupported
16845 features. Handle and report "multiprocess+". Handle
16846 "qAttached:PID".
16847 (handle_v_cont): Adjust to use ptids. Adjust to mywait interface
16848 changes.
16849 (handle_v_kill): New.
16850 (handle_v_stopped): Adjust to use target_pid_to_str.
16851 (handle_v_requests): Allow multiple attaches and runs when
16852 multiprocess extensions are in effect. Handle "vKill".
16853 (myresume): Adjust to use ptids.
16854 (queue_stop_reply_callback): Add `arg' parameter. Handle it.
16855 (handle_status): Adjust to discard_queued_stop_replies interface
16856 change.
16857 (first_thread_of, kill_inferior_callback)
16858 (detach_or_kill_inferior_callback, join_inferiors_callback): New.
16859 (main): Call initialize_inferiors. Adjust to use ptids, killing
16860 and detaching from all inferiors. Handle multiprocess packet
16861 variants.
16862 * linux-low.h: Include gdb_proc_service.h.
16863 (struct process_info_private): New.
16864 (struct linux_target_ops) <pid_of>: Use ptid_get_pid.
16865 <lwpid_of>: Use ptid_get_lwp.
16866 (get_lwp_thread): Adjust.
16867 (struct lwp_info): Add `dead' member.
16868 (find_lwp_pid): Declare.
16869 * linux-low.c (thread_db_active): Delete.
16870 (new_inferior): Adjust comment.
16871 (inferior_pid): Delete.
16872 (linux_add_process): New.
16873 (handle_extended_wait): Adjust.
16874 (add_lwp): Change unsigned long to ptid.
16875 (linux_create_inferior): Add process to processes table. Adjust
16876 to use ptids. Don't set new_inferior here.
16877 (linux_attach_lwp): Rename to ...
16878 (linux_attach_lwp_1): ... this. Add `initial' argument. Handle
16879 it. Adjust to use ptids.
16880 (linux_attach_lwp): New.
16881 (linux_attach): Add process to processes table. Don't set
16882 new_inferior here.
16883 (struct counter): New.
16884 (second_thread_of_pid_p, last_thread_of_process_p): New.
16885 (linux_kill_one_lwp): Add `args' parameter. Handle it. Adjust to
16886 multiple processes.
16887 (linux_kill): Add `pid' argument. Handle it. Adjust to multiple
16888 processes. Remove process from process table.
16889 (linux_detach_one_lwp): Add `args' parameter. Handle it. Adjust
16890 to multiple processes.
16891 (any_thread_of): New.
16892 (linux_detach): Add `pid' argument, and handle it. Remove process
16893 from processes table.
16894 (linux_join): Add `pid' argument. Handle it.
16895 (linux_thread_alive): Change unsighed long argument to ptid_t.
16896 Consider dead lwps as not being alive.
16897 (status_pending_p): Rename `dummy' argument to `arg'. Filter out
16898 threads we're not interested in.
16899 (same_lwp, find_lwp_pid): New.
16900 (linux_wait_for_lwp): Change `pid' argument's type from int to
16901 ptid_t. Adjust.
16902 (linux_wait_for_event): Rename to ...
16903 (linux_wait_for_event_1): ... this. Change `pid' argument's type
16904 from int to ptid_t. Adjust.
16905 (linux_wait_for_event): New.
16906 (linux_wait_1): Add `ptid' argument. Change return type to
16907 ptid_t. Adjust. Use last_thread_of_process_p. Remove processes
16908 that exit from the process table.
16909 (linux_wait): Add `ptid' argument. Change return type to ptid_t.
16910 Adjust.
16911 (mark_lwp_dead): New.
16912 (wait_for_sigstop): Adjust to use ptids. If a process exits while
16913 stopping all threads, mark its main lwp as dead.
16914 (linux_set_resume_request, linux_resume_one_thread): Adjust to use
16915 ptids.
16916 (fetch_register, usr_store_inferior_registers)
16917 (regsets_fetch_inferior_registers)
16918 (regsets_store_inferior_registers, linux_read_memory)
16919 (linux_write_memory): Inline `inferior_pid'.
16920 (linux_look_up_symbols): Adjust to use per-process
16921 `thread_db_active'.
16922 (linux_request_interrupt): Adjust to use ptids.
16923 (linux_read_auxv): Inline `inferior_pid'.
16924 (initialize_low): Don't reference thread_db_active.
16925 * gdb_proc_service.h (struct ps_prochandle) <pid>: Remove.
16926 * proc-service.c (ps_lgetregs): Use find_lwp_pid.
16927 (ps_getpid): Return the pid of the current inferior.
16928 * thread-db.c (proc_handle, thread_agent): Delete.
16929 (thread_db_create_event, thread_db_enable_reporting): Adjust to
16930 per-process data.
16931 (find_one_thread): Change argument type to ptid_t. Adjust to
16932 per-process data.
16933 (maybe_attach_thread): Adjust to per-process data and ptids.
16934 (thread_db_find_new_threads): Ditto.
16935 (thread_db_init): Ditto.
16936 * spu-low.c (spu_create_inferior, spu_attach): Add process to
16937 processes table. Adjust to use ptids.
16938 (spu_kill, spu_detach): Adjust interface. Remove process from
16939 processes table.
16940 (spu_join, spu_thread_alive): Adjust interface.
16941 (spu_wait): Adjust interface. Remove process from processes
16942 table. Adjust to use ptids.
16943 * win32-low.c (current_inferior_tid): Delete.
16944 (current_inferior_ptid): New.
16945 (debug_event_ptid): New.
16946 (thread_rec): Take a ptid. Adjust.
16947 (child_add_thread): Add `pid' argument. Adjust to use ptids.
16948 (child_delete_thread): Ditto.
16949 (do_initial_child_stuff): Add `attached' argument. Add process to
16950 processes table.
16951 (child_fetch_inferior_registers, child_store_inferior_registers):
16952 Adjust.
16953 (win32_create_inferior): Pass 0 to do_initial_child_stuff.
16954 (win32_attach): Pass 1 to do_initial_child_stuff.
16955 (win32_kill): Adjust interface. Remove process from processes
16956 table.
16957 (win32_detach): Ditto.
16958 (win32_join): Adjust interface.
16959 (win32_thread_alive): Take a ptid.
16960 (win32_resume): Adjust to use ptids.
16961 (get_child_debug_event): Ditto.
16962 (win32_wait): Adjust interface. Remove exiting process from
16963 processes table.
16964
bd99dc85
PA
169652009-04-01 Pedro Alves <pedro@codesourcery.com>
16966
16967 Non-stop mode support.
16968
16969 * server.h (non_stop): Declare.
16970 (gdb_client_data, handler_func): Declare.
16971 (delete_file_handler, add_file_handler, start_event_loop):
16972 Declare.
16973 (handle_serial_event, handle_target_event, push_event)
16974 (putpkt_notif): Declare.
16975 * target.h (enum resume_kind): New.
16976 (struct thread_resume): Replace `step' field by `kind' field.
16977 (TARGET_WNOHANG): Define.
16978 (struct target_ops) <wait>: Add `options' argument.
16979 <supports_non_stop, async, start_non_stop>: New fields.
16980 (target_supports_non_stop, target_async): New.
16981 (start_non_stop): Declare.
16982 (mywait): Add `options' argument.
16983 * target.c (mywait): Add `options' argument. Print child exit
16984 notifications here.
16985 (start_non_stop): New.
16986 * server.c (non_stop, own_buf, mem_buf): New globals.
16987 (struct vstop_notif): New.
16988 (notif_queue): New global.
16989 (queue_stop_reply, push_event, discard_queued_stop_replies)
16990 (send_next_stop_reply): New.
16991 (start_inferior): Adjust to use resume_kind. Adjust to mywait
16992 interface changes.
16993 (attach_inferior): In non-stop mode, don't wait for the target
16994 here.
16995 (handle_general_set): Handle QNonStop.
16996 (handle_query): When handling qC, return the current general
16997 thread, instead of the first thread of the list.
16998 (handle_query): If the backend supports non-stop mode, include
16999 QNonStop+ in the qSupported query response.
17000 (handle_v_cont): Adjust to use resume_kind. Handle resume_stop
17001 and non-stop mode.
17002 (handle_v_attach, handle_v_run): Handle non-stop mode.
17003 (handle_v_stopped): New.
17004 (handle_v_requests): Report support for vCont;t. Handle vStopped.
17005 (myresume): Adjust to use resume_kind. Handle non-stop.
17006 (queue_stop_reply_callback): New.
17007 (handle_status): Handle non-stop mode.
17008 (main): Clear non_stop flag on reconnection. Use the event-loop.
17009 Refactor serial protocol handling from here ...
17010 (process_serial_event): ... to this new function. When GDB
17011 selects any thread, select one here. In non-stop mode, wait until
17012 GDB acks all pending events before exiting.
17013 (handle_serial_event, handle_target_event): New.
17014 * remote-utils.c (remote_open): Install remote_desc in the event
17015 loop.
17016 (remote_close): Remove remote_desc from the event loop.
17017 (putpkt_binary): Rename to...
17018 (putpkt_binary_1): ... this. Add `is_notic' argument. Handle it.
17019 (putpkt_binary): New as wrapper around putpkt_binary_1.
17020 (putpkt_notif): New.
17021 (prepare_resume_reply): In non-stop mode, don't change the
17022 general_thread.
17023 * event-loop.c: New.
17024 * Makefile.in (OBJ): Add event-loop.o.
17025 (event-loop.o): New rule.
17026
17027 * linux-low.h (pid_of): Moved here.
17028 (lwpid_of): New.
17029 (get_lwp_thread): Use lwpid_of.
17030 (struct lwp_info): Delete `lwpid' field. Add `suspended' field.
17031 * linux-low.c (pid_of): Delete.
17032 (inferior_pid): Use lwpid_of.
17033 (linux_event_pipe): New.
17034 (target_is_async_p): New.
17035 (delete_lwp): New.
17036 (handle_extended_wait): Use lwpid_of.
17037 (add_lwp): Don't set lwpid field.
17038 (linux_attach_lwp): Adjust debug output. Use lwpid_of.
17039 (linux_kill_one_lwp): If killing a running lwp, stop it first.
17040 Use lwpid_of. Adjust to linux_wait_for_event interface changes.
17041 (linux_detach_one_lwp): If detaching from a running lwp, stop it
17042 first. Adjust to linux_wait_for_event interface changes. Use
17043 lwpid_of.
17044 (linux_detach): Don't delete the main lwp here.
17045 (linux_join): Use my_waitpid. Avoid signal_pid. Use lwpid_of.
17046 (status_pending_p): Don't consider explicitly suspended lwps.
17047 (linux_wait_for_lwp): Take an integer pid instead of a lwp_info
17048 pointer. Add OPTIONS argument. Change return type to int. Use
17049 my_waitpid instead of sleeping. Handle WNOHANG. Use lwpid_of.
17050 (linux_wait_for_event): Take an integer pid instead of a lwp_info
17051 pointer. Add status pointer argument. Return a pid instead of a
17052 status. Use lwpid_of. Adjust to linux_wait_for_lwp interface
17053 changes. In non-stop mode, don't switch to a random thread.
17054 (linux_wait): Rename to...
17055 (linux_wait_1): ... this. Add target_options argument, and handle
17056 it. Adjust to use resume_kind. Use lwpid_of. In non-stop mode,
17057 don't handle the continue thread. Handle TARGET_WNOHANG. Merge
17058 clean exit and signal exit code. Don't stop all threads in
17059 non-stop mode. In all-stop mode, only stop all threads when
17060 reporting a stop to GDB. Handle explicit thread stop requests.
17061 (async_file_flush, async_file_mark): New.
17062 (linux_wait): New.
17063 (send_sigstop): Use lwpid_of.
17064 (wait_for_sigstop): Use lwpid_of. Adjust to linux_wait_for_event
17065 interface changes. In non-stop mode, don't switch to a random
17066 thread.
17067 (linux_resume_one_lwp): Use lwpid_of.
17068 (linux_continue_one_thread, linux_queue_one_thread): Merge into ...
17069 (linux_resume_one_thread): ... this. Handle resume_stop. In
17070 non-stop mode, don't look for pending flag in all threads.
17071 (resume_status_pending_p): Don't consider explicitly suspended
17072 threads.
17073 (my_waitpid): Reimplement. Emulate __WALL.
17074 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
17075 Use lwpid_of.
17076 (sigchld_handler, linux_supports_non_stop, linux_async)
17077 (linux_start_non_stop): New.
17078 (linux_target_ops): Register linux_supports_non_stop, linux_async
17079 and linux_start_non_stop.
17080 (initialize_low): Install SIGCHLD handler.
17081 * thread-db.c (thread_db_create_event, find_one_thread)
17082 (thread_db_get_tls_address): Use lwpid_of.
17083 * win32-low.c (win32_detach): Adjust to use resume_kind.
17084 (win32_wait): Add `options' argument.
17085 * spu-low.c (spu_resume): Adjust to use resume_kind.
17086 (spu_wait): Add `options' argument.
17087
5b1c542e
PA
170882009-04-01 Pedro Alves <pedro@codesourcery.com>
17089
17090 Decouple target code from remote protocol.
17091
17092 * target.h (enum target_waitkind): New.
17093 (struct target_waitstatus): New.
17094 (struct target_ops) <wait>: Return an unsigned long. Take a
17095 target_waitstatus pointer instead of a char pointer.
17096 (mywait): Likewise.
17097 * target.c (mywait): Change prototype to return an unsigned long.
17098 Take a target_waitstatus pointer instead of a char pointer. Adjust.
17099 * server.h (thread_from_wait, old_thread_from_wait): Delete
17100 declarations.
17101 (prepare_resume_reply): Change prototype to take a
17102 target_waitstatus.
17103 * server.c (thread_from_wait, old_thread_from_wait): Delete.
17104 (last_status, last_ptid): New.
17105 (start_inferior): Remove "statusptr" argument. Adjust. Return a
17106 pid instead of a signal.
17107 (attach_inferior): Remove "status" and "signal" parameters.
17108 Adjust.
17109 (handle_query): For qGetTLSAddr, parse the thread id with strtol,
17110 not as an address.
17111 (handle_v_cont, handle_v_attach, handle_v_run, handle_v_kill)
17112 (handle_v_requests, myresume): Remove "status" and "signal"
17113 parameters. Adjust.
17114 (handle_status): New.
17115 (main): Delete local `status'. Adjust.
17116 * remote-utils.c: Include target.h.
17117 (prepare_resume_reply): Change prototype to take a
17118 target_waitstatus. Adjust.
17119
17120 * linux-low.c (linux_wait): Adjust to new target_ops->wait
17121 interface.
17122 * spu-low.c (spu_wait): Adjust.
17123 * win32-low.c (enum target_waitkind, struct target_waitstatus):
17124 Delete.
17125 (win32_wait): Adjust.
17126
2bd7c093
PA
171272009-04-01 Pedro Alves <pedro@codesourcery.com>
17128
17129 * target.h (struct thread_resume): Delete leave_stopped member.
17130 (struct target_ops): Add a `n' argument to the `resume' callback.
17131 * server.c (start_inferior): Adjust.
17132 (handle_v_cont, myresume): Adjust.
17133 * linux-low.c (check_removed_breakpoint): Adjust to resume
17134 interface change, and to removed leave_stopped field.
17135 (resume_ptr): Delete.
17136 (struct thread_resume_array): New.
17137 (linux_set_resume_request): Add new `arg' parameter. Adjust to
17138 resume interface change.
17139 (linux_continue_one_thread, linux_queue_one_thread)
17140 (resume_status_pending_p): Check if the resume field is NULL
17141 instead of checking the leave_stopped member.
17142 (linux_resume): Adjust to the target resume interface change.
17143 * spu-low.c (spu_resume): Adjust to the target resume interface
17144 change.
17145 * win32-low.c (win32_detach, win32_resume): Ditto.
17146
c35fafde
PA
171472009-04-01 Pedro Alves <pedro@codesourcery.com>
17148
17149 * linux-low.c (linux_wait_for_event): Don't clear the `stepping'
17150 flag.
17151 (wait_for_sigstop): Don't leave a finished single-step SIGTRAP
17152 pending.
17153 (linux_continue_one_thread): Only preserve the stepping flag if
17154 there's a pending breakpoint.
17155
0a59d50b
PA
171562009-03-31 Pedro Alves <pedro@codesourcery.com>
17157
17158 * server.c (main): After the inferior having exited, call
17159 remote_close before exiting gdbserver.
17160
f04c6d38
TJB
171612009-03-25 Thiago Jung Bauermann <bauerman@br.ibm.com>
17162
17163 Fix size of FPSCR in Power 7 processors.
17164 * linux-ppc-low.c (PPC_FEATURE_ARCH_2_05): Remove #define.
17165 (PPC_FEATURE_HAS_DFP): New #define.
17166 (ppc_arch_setup): Check for DFP feature instead of ISA 2.05 to decide on
17167 size of the FPSCR.
17168
78e5cee6
PA
171692009-03-23 Pedro Alves <pedro@codesourcery.com>
17170
17171 * server.c (handle_query) Whitespace and formatting.
17172
1b3f6016
PA
171732009-03-22 Pedro Alves <pedro@codesourcery.com>
17174
17175 * i387-fp.c, linux-arm-low.c, linux-cris-low.c,
17176 linux-crisv32-low.c, linux-i386-low.c, linux-low.c,
17177 linux-mips-low.c, linux-s390-low.c, linux-sparc-low.c,
17178 linux-x86-64-low.c, linux-xtensa-low.c, proc-service.c,
17179 regcache.c, remote-utils.c, server.c, spu-low.c, target.h,
17180 thread-db.c, win32-low.c, xtensa-xtregs.c, gdbreplay.c,
17181 Makefile.in, configure.ac: Fix whitespace throughout.
17182 * configure: Regenerate.
17183
a07b2135
PA
171842009-03-22 Pedro Alves <pedro@codesourcery.com>
17185
17186 * inferiors.c (find_inferior): Make it safe for the callback
17187 function to delete the currently iterated inferior.
17188
67cc2626
PA
171892009-03-22 Pedro Alves <pedro@codesourcery.com>
17190
17191 * Makefile.in (linuw_low_h): Move higher.
17192 (thread-db.o): Depend on $(linux_low_h).
17193
54a0b537
PA
171942009-03-17 Pedro Alves <pedro@codesourcery.com>
17195
17196 Rename "process" to "lwp" throughout.
17197
17198 * linux-low.c (all_processes): Rename to...
17199 (all_lwps): ... this.
17200 (inferior_pid, handle_extended_wait, get_stop_pc): Adjust.
17201 (add_process): Rename to ...
17202 (add_lwp): ... this. Adjust.
17203 (linux_create_inferior): Adjust.
17204 (linux_attach_lwp): Adjust.
17205 (linux_attach): Adjust.
17206 (linux_kill_one_process): Rename to ...
17207 (linux_kill_one_lwp): ... this. Adjust.
17208 (linux_kill): Adjust.
17209 (linux_detach_one_process): Rename to ...
17210 (linux_detach_one_lwp): ... this. Adjust.
17211 (linux_detach): Adjust.
17212 (check_removed_breakpoint): Adjust.
17213 (status_pending_p): Adjust.
17214 (linux_wait_for_process): Rename to ...
17215 (linux_wait_for_lwp): ... this. Adjust.
17216 (linux_wait_for_event): Adjust.
17217 (send_sigstop): Adjust.
17218 (wait_for_sigstop): Adjust.
17219 (stop_all_processes): Rename to ...
17220 (stop_all_lwps): ... this.
17221 (linux_resume_one_process): Rename to ...
17222 (linux_resume_one_lwp): ... this. Adjust.
17223 (linux_set_resume_request, linux_continue_one_thread)
17224 (linux_queue_one_thread, resume_status_pending_p)
17225 (usr_store_inferior_registers, regsets_store_inferior_registers)
17226 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
17227 Adjust.
17228 * linux-low.h (get_process): Rename to ...
17229 (get_lwp): ... this. Adjust.
17230 (get_thread_process): Rename to ...
17231 (get_thread_lwp): ... this. Adjust.
17232 (get_process_thread): Rename to ...
17233 (get_lwp_thread): ... this. Adjust.
17234 (struct process_info): Rename to ...
17235 (struct lwp_info): ... this.
17236 (all_processes): Rename to ...
17237 (all_lwps): ... this.
17238 * proc-service.c (ps_lgetregs): Adjust.
17239 * thread-db.c (thread_db_create_event, find_one_thread)
17240 (maybe_attach_thread, thread_db_get_tls_address): Adjust.
17241
0b16c5cf
PA
172422009-03-14 Pedro Alves <pedro@codesourcery.com>
17243
17244 * server.c (handle_query): Handle "qAttached".
17245
32de4b9d
NS
172462009-03-13 Nathan Sidwell <nathan@codesourcery.com>
17247
17248 * Makefile.in, hostio-errno.c, errno.c, xtensa-xtregs.c: Change to
17249 GPLv3, update license URL.
17250
2aecd87f
DE
172512009-03-01 Doug Evans <dje@google.com>
17252
93efd302 17253 * Makefile.in (INCLUDE_CFLAGS): Add -I$(srcdir)/../common.
2aecd87f
DE
17254 (server_h): Add gdb_signals.h.
17255 (signals.o): Update.
17256 * server.h (target_signal_from_host,target_signal_to_host_p)
17257 (target_signal_to_host,target_signal_to_name): Moved to gdb_signals.h.
17258
86b1f9c5
PM
172592009-02-14 Pierre Muller <muller@ics.u-strasbg.fr>
17260
17261 * remote-utils.c (getpkt): Also generate remote-debug
17262 information if noack_mode is set.
17263
4aa995e1
PA
172642009-02-06 Pedro Alves <pedro@codesourcery.com>
17265
17266 * server.c (handle_query): Report qXfer:siginfo:read and
17267 qXfer:siginfo:write as supported and handle them.
17268 * target.h (struct target_ops) <qxfer_siginfo>: New field.
17269 * linux-low.c (linux_xfer_siginfo): New.
17270 (linux_target_ops): Set it.
17271
62709adf
PA
172722009-01-26 Pedro Alves <pedro@codesourcery.com>
17273
17274 * server.c (gdbserver_usage): Mention --remote-debug.
17275 (main): Accept '--remote-debug' switch.
17276
aef93bd7
DE
172772009-01-18 Doug Evans <dje@google.com>
17278
17279 * regcache.c (new_register_cache): No need to check result of xcalloc.
17280 * server.c (handle_search_memory): Back out calls to xmalloc,
17281 result is checked and error is returned to user upon failure.
17282 (handle_query): Ditto. Add more checks for result of malloc.
17283 (handle_v_cont): Check result of malloc, report error back to
17284 user upon failure.
17285 (handle_v_run): Ditto. Call freeargv.
17286 * server.h (freeargv): Declare.
17287 * utils.c (freeargv): New fn.
17288
54363045
DE
172892009-01-15 Doug Evans <dje@google.com>
17290
f626972c
DE
17291 * gdbreplay.c (perror_with_name): Make arg const char *.
17292 * server.h (target_signal_to_name): Make return type const char *.
0842e787 17293 * thread-db.c (thread_db_err_str): Make return type const char *.
f626972c 17294 * utils.c (perror_with_name): Make arg const char *.
54363045 17295
18aae699
PA
172962009-01-14 Pedro Alves <pedro@codesourcery.com>
17297
17298 * win32-low.c (get_child_debug_event): Issue a final DBG_CONTINUE
17299 when handling a EXIT_PROCESS_DEBUG_EVENT.
17300
ff703abe
JB
173012009-01-06 Joel Brobecker <brobecker@adacore.com>
17302
17303 * gdbreplay.c (gdbreplay_version): Update copyright year.
17304 * server.c (gdbserver_version): Likewise.
17305
f21cc1a2 173062009-01-05 Doug Evans <dje@google.com>
0e21c1ec
DE
17307
17308 * linux-low.c (linux_attach_lwp): Add some comments/fixmes.
f21cc1a2 17309 (handle_extended_wait): Improve comment.
0e21c1ec 17310
bca929d3
DE
173112008-12-13 Doug Evans <dje@google.com>
17312
17313 * utils.c (xmalloc,xcalloc,xstrdup): New fns.
17314 * server.h (ATTR_MALLOC): New macro.
17315 (xmalloc,xcalloc,xstrdup): Declare.
17316 * hostio.c: Replace malloc,calloc,strdup with xmalloc,xcalloc,xstrdup.
17317 * inferiors.c: Ditto.
17318 * linux-low.c: Ditto.
17319 * mem-break.c: Ditto.
17320 * regcache.c: Ditto.
17321 * remote-utils.c: Ditto.
17322 * server.c: Ditto.
17323 * target.c: Ditto.
17324 * win32-low.c: Ditto.
17325
97438e3f
DE
173262008-12-12 Doug Evans <dje@google.com>
17327
896c7fbb
DE
17328 * linux-low.c (linux_wait_for_process): Don't clobber current_inferior
17329 in debugging printf.
17330
97438e3f
DE
17331 * linux-low.c (handle_extended_wait): Simplify, use my_waitpid.
17332
e3b886f8
DE
173332008-12-09 Doug Evans <dje@google.com>
17334
17335 * linux-low.h (struct process_info): Delete member tid, unused.
17336 * thread-db.c (find_one_thread): Update.
17337 (maybe_attach_thread): Update.
17338
07e059b5
VP
173392008-12-02 Pedro Alves <pedro@codesourcery.com>
17340
889bf7c5
PA
17341 * target.h (struct target_ops): Add qxfer_osdata member.
17342 * linux-low.c: Include ctype.h and pwd.h and sys/types.h
17343 and dirent.h.
17344 (linux_qxfer_osdata): New functions.
17345 (linux_target_ops): Register linux_qxfer_osdata as qxfer_osdata
17346 callback.
17347 * server.c (handle_query): Handle "qXfer:osdata:read:".
17348 * remote-utils.c (buffer_grow, buffer_free, buffer_init, buffer_finish)
17349 (buffer_xml_printf): New functions.
17350 * server.h (struct buffer): New.
17351 (buffer_grow_str, buffer_grow_str0): New macros.
17352 (buffer_grow, buffer_free, buffer_init, buffer_finish)
17353 (buffer_xml_printf): Declare.
07e059b5 17354
4cab47ab
DE
173552008-11-24 Doug Evans <dje@google.com>
17356
17357 * Makefile.in (VERSION,DIST,LINT,LINTFLAGS): Delete, unused.
17358
f142445f
DJ
173592008-11-24 Daniel Jacobowitz <dan@codesourcery.com>
17360
17361 * server.c (handle_v_run): Always use the supplied argument list.
17362
d0107bb6 173632008-11-19 Bob Wilson <bob.wilson@acm.org>
889bf7c5 17364
d0107bb6
BW
17365 * xtensa-xtregs.c (XTENSA_ELF_XTREG_SIZE): Change to 4.
17366 (xtensa_regmap_table): Add entry for scompare1.
889bf7c5 17367
2c4ad781
TJB
173682008-11-18 Thiago Jung Bauermann <bauerman@br.ibm.com>
17369
17370 * Makefile.in (powerpc-isa205-32l.o, powerpc-isa205-32l.c,
17371 powerpc-isa205-altivec32l.o, powerpc-isa205-altivec32l.c,
17372 powerpc-isa205-vsx32l.o, powerpc-isa205-vsx32l.c,
17373 powerpc-isa205-64l.o, powerpc-isa205-64l.c,
17374 powerpc-isa205-altivec64l.o, powerpc-isa205-altivec64l.c,
17375 powerpc-isa205-vsx64l.o, powerpc-isa205-vsx64l.c): New targets.
17376 * configure.srv (powerpc*-*-linux*): Add ISA 2.05 object files and
17377 XML target descriptions.
17378 * linux-ppc-low.c (ppc_arch_setup): Init registers with 64-bit FPSCR
17379 when inferior is running on an ISA 2.05 or later processor. Add
17380 special case to return offset for full 64-bit slot of FPSCR when
17381 in 32-bits.
17382
dfb64f85
DJ
173832008-11-14 Daniel Gutson <dgutson@codesourcery.com>
17384
17385 * Makefile.in (SFILES, clean): Added sparc64 files.
17386 (reg-sparc64.o, reg-sparc64.c): New.
17387 * configure.srv (sparc*-*-linux*): New configuration.
17388 * linux-low.c (regsets_fetch_inferior_registers): Swap ptrace
17389 syscall arguments for SPARC.
17390 (regsets_store_inferior_registers): Likewise.
17391 * linux-sparc-low.c: New file.
17392
66b6e1dd
DE
173932008-10-21 Doug Evans <dje@google.com>
17394
17395 * Makefile.in (BFD_DIR,BFD,BFD_SRC,BFD_CFLAGS): Delete.
17396 (READLINE_DIR,READLINE_DEP): Delete.
17397 (INTERNAL_CFLAGS): Update.
17398 (LINTFLAGS): Update.
17399
9b710a42
PA
174002008-10-10 Pedro Alves <pedro@codesourcery.com>
17401
17402 * server.c (handle_v_run): If GDB didn't specify an argv, use the
17403 whole argv from the last run, not just argv[0].
17404
5822d809
PA
174052008-09-08 Pedro Alves <pedro@codesourcery.com>
17406
17407 * regcache.c (new_register_cache): Return NULL if the register
17408 cache size isn't known yet.
17409 (free_register_cache): Avoid dereferencing a NULL regcache.
17410
74aac56f
DJ
174112008-09-04 Daniel Jacobowitz <dan@codesourcery.com>
17412
17413 * configure.srv: Merge MIPS and MIPS64.
17414
400b20f5
MR
174152008-08-24 Maciej W. Rozycki <macro@linux-mips.org>
17416
17417 * Makefile.in (uninstall): Apply $(EXEEXT) too.
17418
677c5bb1
LM
174192008-08-18 Luis Machado <luisgpm@br.ibm.com>
17420
17421 * Makefile.in: Add required vsx dependencies.
17422
17423 * linux-ppc-low: Define PPC_FEATURE_HAS_VSX.
17424 Declare init_registers_powerpc_vsx32l.
17425 Declare init_registers_powerpc_vsx64l.
17426 Define PTRACE_GETVSXREGS and PTRACE_SETVSXREGS.
17427 (ppc_arch_setup): Check for VSX in hwcap.
17428 (ppc_fill_vsxregset): New function.
17429 (ppc_store_vsxregset): New function.
17430 Add new VSX entry in regset_info target_regsets.
17431
17432 * configure.srv: Add new VSX dependencies.
17433
a6f3e723
SL
174342008-08-12 Pedro Alves <pedro@codesourcery.com>
17435
17436 * remote-utils.c (noack_mode, transport_is_reliable): New globals.
17437 (remote_open): Set or clear transport_is_reliable.
17438 (putpkt_binary): Don't expect acks in noack mode.
17439 (getpkt): Don't send ack/nac in noack mode.
17440 * server.c (handle_general_set): Handle QStartNoAckMode.
17441 (handle_query): If connected by tcp pass QStartNoAckMode+ in
17442 qSupported.
17443 (main): Reset noack_mode on every connection.
17444 * server.h (noack_mode): Declare.
17445
a417dc56
RW
174462008-08-07 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
17447
17448 * Makefile.in (GDBREPLAY_OBS): New variable.
17449 (gdbreplay$(EXEEXT)): Use it to avoid unportable $^.
17450
3221518c
UW
174512008-08-05 Ulrich Weigand <uweigand@de.ibm.com>
17452 Daniel Jacobowitz <dan@codesourcery.com>
17453
17454 * linux-low.c (linux_resume_one_process): Ignore ESRCH.
17455 (usr_store_inferior_registers): Likewise.
17456 (regsets_store_inferior_registers): Likewise.
17457
ec56be1b
PA
174582008-07-31 Rolf Jansen <rj@surtec.com>
17459 Pedro Alves <pedro@codesourcery.com>
17460
17461 * configure.ac: Check for memmem declaration.
17462 * server.c [HAVE_MALLOC_H]: Include malloc.h.
17463 (disable_packet_vCont, disable_packet_Tthread, disable_packet_qC)
17464 (disable_packet_qfThreadInfo): Unconditionally compile.
17465 * server.h [!HAVE_DECL_MEMMEM]: Declare memmem.
17466 * configure, config.in: Regenerate.
17467
2fe5e3ff
DE
174682008-07-28 Doug Kwan <dougkwan@google.com>
17469
17470 * linux-low.c (sys/dir.h, sys/user.h): Remove includes.
17471 (linux_write_memory): Remove declaration of errno.
17472
836acd6d
UW
174732008-07-12 Ulrich Weigand <uweigand@de.ibm.com>
17474
17475 * linux-low.c (handle_extended_wait): Do not use "status"
17476 variable uninitialized.
17477
aeba519e
PA
174782008-07-07 Pedro Alves <pedro@codesourcery.com>
17479
17480 * server.c (handle_v_attach): Inhibit reporting dll changes.
17481
db42f210
PA
174822008-06-27 Pedro Alves <pedro@codesourcery.com>
17483
17484 * remote-utils.c (prepare_resume_reply): If requested, don't
17485 output "thread:TID" in the T stop reply.
17486
17487 * server.c (disable_packet_vCont, disable_packet_Tthread)
17488 (disable_packet_qC, disable_packet_qfThreadInfo): New globals.
17489 (handle_query): If requested, disable support for qC, qfThreadInfo
17490 and qsThreadInfo.
17491 (handle_v_requests): If requested, disable support for vCont.
17492 (gdbserver_show_disableable): New.
17493 (main): Handle --disable-packet and --disable-packet=LIST.
17494
17495 * server.h (disable_packet_vCont, disable_packet_Tthread)
17496 (disable_packet_qC, disable_packet_qfThreadInfo): Declare.
17497
8e4c5421
CD
174982008-06-20 Carlos O'Donell <carlos@codesourcery.com>
17499
17500 * server.c (gdbserver_usage): Mention --version.
17501
6e23a804
DJ
175022008-06-06 Daniel Jacobowitz <dan@codesourcery.com>
17503
17504 * Makefile.in (gdbreplay.o): New rule.
17505
90aa6a40
JM
175062008-06-06 Joseph Myers <joseph@codesourcery.com>
17507
17508 * gdbreplay.c (gdbreplay_version): Say gdbreplay in version
17509 message, not gdbserver.
17510
c16158bc 175112008-06-05 Vladimir Prus <vladimir@codesourcery.com>
889bf7c5
PA
17512 Nathan Sidwell <nathan@codesourcery.com>
17513 Joseph Myers <joseph@codesourcery.com>
c16158bc
JM
17514
17515 * acinclude.m4: Include ../../config/acx.m4.
17516 * configure.ac: Use ACX_PKGVERSION and ACX_BUGURL.
17517 * configure, config.in: Regenerate.
17518 * Makefile.in (gdbreplay$(EXEEXT)): Add version.o.
17519 * server.c (gdbserver_version): Print PKGVERSION.
17520 (gdbsrever_usage): Add stream parameter. Print REPORT_BUGS_TO.
17521 (main): Adjust gdbserver_usage calls.
17522 * gdbreplay.c (version, host_name): Add declarations.
17523 (gdbreplay_version, gdbreplay_usage): New.
17524 (main): Accept --version and --help options.
17525
aeb75bf5
DJ
175262008-06-04 Daniel Jacobowitz <dan@codesourcery.com>
17527
17528 * linux-arm-low.c (thumb_breakpoint, thumb_breakpoint_len): New.
17529 (arm_breakpoint_at): Handle Thumb.
17530 (the_low_target): Add comment.
17531
76b233dd
UW
175322008-05-29 Ulrich Weigand <uweigand@de.ibm.com>
17533
17534 * linux-ppc-low.c (ppc_collect_ptrace_register): Clear buffer.
17535
08388c79
DE
175362008-05-09 Doug Evans <dje@google.com>
17537
a3c83fae
DE
17538 * server.h (decode_search_memory_packet): Declare.
17539 * remote-utils.c (decode_search_memory_packet): New fn.
17540 * server.c (handle_search_memory_1): New fn.
08388c79
DE
17541 (handle_search_memory): New fn.
17542 (handle_query): Process qSearch:memory packets.
17543
bb9c3d36
UW
175442008-05-08 Ulrich Weigand <uweigand@de.ibm.com>
17545
17546 * regcache.c (registers_length): Remove.
17547 (set_register_cache): Verify that PBUFSIZ is large enough to hold a
17548 full register packet.
17549 * regcache.h (registers_length): Remove prototype.
17550 * server.h (PBUFSIZ): Define to 16384.
17551
7284e1be
UW
175522008-05-03 Ulrich Weigand <uweigand@de.ibm.com>
17553
17554 * configure.srv (powerpc*-*-linux*): Set srv_regobj to
17555 powerpc-32l.o, powerpc-altivec32l.o, powerpc-e500l.o,
17556 powerpc-64l.o, and powerpc-altivec64l.o.
17557 Remove rs6000/powerpc-32.xml, rs6000/powerpc-64.xml, and
17558 rs6000/powerpc-e500.xml; add rs6000/powerpc-32l.xml,
17559 rs6000/powerpc-altivec32l.xml, rs6000/powerpc-e500l.xml,
17560 rs6000/powerpc-64l.xml, rs6000/powerpc-altivec64l.xml,
17561 rs6000/power-linux.xml, and rs6000/power64-linux.xml
17562 to srv_xmlfiles.
17563
17564 * Makefile.in (reg-ppc.o, reg-ppc.c): Remove, replace by ...
17565 (powerpc-32l.o, powerpc-32l.c): ... these new rules.
17566 (powerpc-32.o, powerpc-32.c): Remove, replace by ...
17567 (powerpc-altivec32l.o, powerpc-altivec32l.c): ... these new rules.
17568 (powerpc-e500.o, powerpc-e500.c): Remove, replace by ...
17569 (powerpc-e500l.o, powerpc-e500l.c): ... these new rules.
17570 (reg-ppc64.o, reg-ppc64.c): Remove, replace by ...
17571 (powerpc-64l.o, powerpc-64l.c): ... these new rules.
17572 (powerpc-64.o, powerpc-64.c): Remove, replace by ...
17573 (powerpc-altivec64l.o, powerpc-altivec64l.c): ... these new rules.
17574 (clean): Update.
17575
17576 * linux-ppc-low.c (init_registers_ppc): Remove, replace by ...
17577 (init_registers_powerpc_32l): ... this new prototype.
17578 (init_registers_powerpc_32): Remove, replace by ...
17579 (init_registers_powerpc_altivec32l): ... this new prototype.
17580 (init_registers_powerpc_e500): Remove, replace by ...
17581 (init_registers_powerpc_e500l): ... this new prototype.
17582 (init_registers_ppc64): Remove, replace by ...
17583 (init_registers_powerpc_64l): ... this new prototype.
17584 (init_registers_powerpc_64): Remove, replace by ...
17585 (init_registers_powerpc_altivec64l): ... this new prototype.
17586 (ppc_num_regs): Set to 73.
17587 (PT_ORIG_R3, PT_TRAP): Define if necessary.
17588 (ppc_regmap, ppc_regmap_e500): Add values for orig_r3 and trap.
17589 (ppc_cannot_store_register): Handle orig_r3 and trap.
17590 (ppc_arch_setup): Update init_registers_... calls.
17591 (ppc_fill_gregset): Handle orig_r3 and trap.
17592
17593 * inferiors.c (clear_inferiors): Reset current_inferior.
17594
fdc59709
PB
175952008-04-23 Paolo Bonzini <bonzini@gnu.org>
17596
889bf7c5
PA
17597 * acinclude.m4: Add override.m4.
17598 * configure: Regenerate.
fdc59709 17599
c9b2f845
UW
176002008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
17601
17602 * linux-ppc-low.c (ppc_arch_setup): Reset ppc_hwcap after the
17603 initial call to init_register_ppc64.
17604
550512b8
UW
176052008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
17606
43aaf8b6
PA
17607 * configure.srv (powerpc64-*-linux*, powerpc-*-linux*): Merge into
17608 single powerpc*-*-linux* case.
550512b8
UW
17609 (s390-*-linux*, s390x-*-linux*): Merge into single s390*-*-linux* case.
17610
b6430ec3
UW
176112008-04-17 Ulrich Weigand <uweigand@de.ibm.com>
17612
17613 * configure.srv [powerpc64-*-linux*]: Remove powerpc-e500.o from
889bf7c5 17614 srv_regobj. Remove rs6000/powerpc-e500.xml and rs6000/power-spe.xml
b6430ec3
UW
17615 from reg_xmlfiles.
17616 * linux-ppc-low.c: Include <elf.h>.
17617 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Define.
17618 (ppc_hwcap): New global variable.
17619 (ppc_regmap): Remove __SPE__ #ifdef sections.
17620 (ppc_regmap_e500): New global variable.
17621 (ppc_cannot_store_register): Update __SPE__ special case.
17622 (ppc_get_hwcap): New function.
17623 (ppc_arch_setup): Use it to determine whether inferior supports
17624 AltiVec or SPE registers. Set the_low_target.regmap if appropriate.
17625 (ppc_fill_vrregset, ppc_store_vrregset): Define unconditionally.
17626 Do not access registers if target does not support AltiVec.
17627 (ppc_fill_evrregset, ppc_store_evrregset): Define unconditionally.
17628 Do not access registers if target does not support SPE.
17629 (target_regsets): Unconditionally include AltiVec and SPE regsets.
17630
52fa2412
UW
176312008-04-17 Daniel Jacobowitz <dan@codesourcery.com>
17632
17633 * linux-low.c (disabled_regsets, num_regsets): New.
17634 (use_regsets_p): Delete.
17635 (linux_wait_for_process): Clear disabled_regsets.
17636 (regsets_fetch_inferior_registers): Check and set it.
17637 (regsets_store_inferior_registers): Likewise.
17638 (linux_fetch_registers, linux_store_registers): Do not use
17639 use_regsets_p.
17640 (initialize_low): Allocate disabled_regsets.
17641
e28b3332
DJ
176422008-04-14 Daniel Jacobowitz <dan@codesourcery.com>
17643
17644 * Makefile.in (LIBOBJS): New.
17645 (OBS): Use LIBOBJS.
17646 (memmem.o): New rule.
17647 * configure.ac: Use AC_CONFIG_LIBOBJ_DIR and check for memmem.
17648 * configure: Regenerated.
17649
4536995d
UW
176502008-04-04 Ulrich Weigand <uweigand@de.ibm.com>
17651
17652 * server.c (handle_query): Never return "unsupported" for
17653 qXfer:features:read queries.
17654
221c031f
UW
176552008-03-27 Ulrich Weigand <uweigand@de.ibm.com>
17656
17657 * server.c (get_features_xml): Fix inverted condition.
17658 (handle_query): Always support qXfer:feature:read.
17659
ccd213ac
DJ
176602008-03-10 Daniel Jacobowitz <dan@codesourcery.com>
17661
17662 * server.c (wrapper_argv): New.
17663 (start_inferior): Handle wrapper_argv. If set, expect an extra
17664 trap.
17665 (gdbserver_usage): Document --wrapper.
17666 (main): Parse --wrapper.
17667
6fe305f7
UW
176682008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
17669
17670 * configure.srv [powerpc64-*-linux*]: Add all files mentioned for
17671 powerpc-*-linux* to srv_regobj and reg_xmlfiles.
17672 * linux-ppc-low.c (ppc_get_pc): Support bi-arch operation.
17673 (ppc_set_pc): Likewise.
17674 (ppc_arch_setup): New function.
17675 (ppc_fill_gregset): Call ppc_collect_ptrace_register instead
17676 of collect_register.
889bf7c5 17677 (the_low_target): Use ppc_arch_setup as arch_setup initializer.
6fe305f7 17678
5b0a002e
UW
176792008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
17680
17681 * configure.srv [powerpc64-*-linux*]: Use linux-ppc-low.o
17682 instead of linux-ppc64-low.o.
17683 * linux-ppc64-low.c: Remove file.
17684 * Makefile.in (SFILES): Remove linux-ppc64-low.c.
17685 (linux-ppc64-low.o): Remove rule.
17686
17687 * linux-ppc-low.c (init_registers_ppc64): Add prototype.
17688 (init_registers_powerpc_64): Likewise.
17689 (ppc_regmap): Conditionally define depending on __powerpc64__.
17690 (ppc_cannot_store_register): Do not special-case "fpscr" when
17691 compiled on __powerpc64__.
17692 (ppc_collect_ptrace_register): New function.
17693 (ppc_supply_ptrace_register): New function.
17694 (ppc_breakpoint): Change type to "unsigned int".
17695 (ppc_breakpoint_at): Change type of "insn" to "unsigned int".
17696 (the_low_target): Conditionally provide initializers for the
889bf7c5 17697 arch_setup member depending on __powerpc64__. Install
5b0a002e
UW
17698 collect_ptrace_register and supply_ptrace_register members.
17699
9b4b61c8
UW
177002008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
17701
17702 * regcache.h (gdbserver_xmltarget): Add extern declaration.
17703 * server.c (gdbserver_xmltarget): Define.
17704 (get_features_xml): Use it to replace "target.xml" and arch_string.
17705
17706 * configure.srv: Remove srv_xmltarget. Add XML files that were
17707 mentioned there to srv_xmlfiles instead. Remove conditional tests
17708 on gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe; set
17709 srv_xmlfiles and srv_regobj to include all possible choices.
17710 * configure.ac (srv_xmltarget): Remove.
17711 (srv_xmlfiles): Do not add "target.xml".
17712 (gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe): Remove
17713 checks for supplementary target information.
17714 * configure: Regenerate.
17715 * Makefile.in (XML_TARGET): Remove.
17716 (target.xml): Remove rule.
17717 (clean): Do not clean up target.xml.
17718 (.PRECIOUS): Do not mention target.xml.
17719
17720 * target.h (struct target_ops): Remove arch_string member.
17721 * linux-low.c (linux_arch_string): Remove.
17722 (linux_target_ops): Remove arch_string initializer.
17723 * linux-low.h (struct linux_target_ops): Remove arch_string member.
17724 * linux-i386-low.c (the_low_target): Remove arch_string initializer.
17725 * linux-x86-64-low.c (the_low_target): Remove arch_string initializer.
17726 * spu-low.c (spu_arch_string): Remove.
17727 (spu_target_ops): Remove arch_string initializer.
17728 * win32-low.c (win32_arch_string): Remove.
17729 (win32_target_ops): Remove arch_string initializer.
17730 * win32-low.h (struct win32_target_ops): Remove arch_string member.
17731 * win32-arm-low.c (the_low_target): Remove arch_string initializer.
17732 * win32-i368-low.c (the_low_target): Remove arch_string initializer.
17733
ee1a7ae4
UW
177342008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
17735
17736 * linux-low.h (struct linux_target_ops): Replace left_pad_xfer field
17737 by collect_ptrace_register and supply_ptrace_register hooks.
17738 * linux-low.c (fetch_register): Use supply_ptrace_register callback
17739 instead of checking for the_low_target.left_pad_xfer.
17740 (usr_store_inferior_registers): Use collect_ptrace_register callback
17741 instead of checking for the_low_target.left_pad_xfer.
17742
17743 * linux-s390-low.c (s390_collect_ptrace_register): New function.
17744 (s390_supply_ptrace_register): Likewise.
17745 (s390_fill_gregset): Call s390_collect_ptrace_register.
17746 (the_low_target): Update.
17747
17748 * linux-ppc64-low.c (ppc_collect_ptrace_register): New function.
17749 (ppc_supply_ptrace_register): Likewise.
17750 (the_low_target): Update.
17751
17752 * linux-i386-low.c (the_low_target): Update.
17753 * linux-x86-64-low.c (the_low_target): Update.
17754
d61ddec4
UW
177552008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
17756
17757 * configure.srv [s390x-*-linux*]: Set srv_regobj to include both
17758 reg-s390.o and reg-s390x.o.
17759
17760 * linux-low.c (new_inferior): New global variable.
17761 (linux_create_inferior, linux_attach): Set it.
17762 (linux_wait_for_process): Call the_low_target.arch_setup after the
17763 target has stopped for the first time.
17764 (initialize_low): Do not call the_low_target.arch_setup.
17765
17766 * linux-s390-low.c (s390_get_pc): Support bi-arch operation.
17767 (s390_set_pc): Likewise.
17768 (s390_arch_setup): New function.
17769 (the_low_target): Use s390_arch_setup as arch_setup routine.
17770
17771 * regcache.c (realloc_register_cache): New function.
17772 (set_register_cache): Call it for each existing regcache.
17773
d05b4ac3
UW
177742008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
17775
17776 * server.h (init_registers): Remove prototype.
17777
17778 * linux-low.h (struct linux_target_ops): Add arch_setup field.
17779 * linux-low.c (initialize_low): Call the_low_target.arch_setup ()
17780 instead of init_registers ().
17781 * linux-arm-low.c (init_registers_arm): Add prototype.
17782 (init_registers_arm_with_iwmmxt): Likewise.
17783 (the_low_target): Add initializer for arch_setup field.
17784 * linux-cris-low.c (init_registers_cris): Add prototype.
17785 (the_low_target): Add initializer for arch_setup field.
17786 * linux-crisv32-low.c (init_registers_crisv32): Add prototype.
17787 (the_low_target): Add initializer for arch_setup field.
17788 * linux-i386-low.c (init_registers_i386_linux): Add prototype.
17789 (the_low_target): Add initializer for arch_setup field.
17790 * linux-ia64-low.c (init_registers_ia64): Add prototype.
17791 (the_low_target): Add initializer for arch_setup field.
17792 * linux-m32r-low.c (init_registers_m32r): Add prototype.
17793 (the_low_target): Add initializer for arch_setup field.
17794 * linux-m68k-low.c (init_registers_m68k): Add prototype.
17795 (the_low_target): Add initializer for arch_setup field.
17796 * linux-mips-low.c (init_registers_mips_linux): Add prototype.
17797 (init_registers_mips64_linux): Likewise.
17798 (the_low_target): Add initializer for arch_setup field.
17799 * linux-ppc-low.c (init_registers_ppc): Add prototype.
17800 (init_registers_powerpc_32, init_registers_powerpc_e500): Likewise.
17801 (the_low_target): Add initializer for arch_setup field.
17802 * linux-ppc64-low.c (init_registers_ppc64): Add prototype.
17803 (init_registers_powerpc_64): Likewise.
17804 (the_low_target): Add initializer for arch_setup field.
17805 * linux-s390-low.c (init_registers_s390): Add prototype.
17806 (init_registers_s390x): Likewise.
17807 (the_low_target): Add initializer for arch_setup field.
17808 * linux-sh-low.c (init_registers_sh): Add prototype.
17809 (the_low_target): Add initializer for arch_setup field.
17810 * linux-x86-64-low.c (init_registers_x86_64_linux): Add prototype.
17811 (the_low_target): Add initializer for arch_setup field.
17812 * linux-xtensa-low.c (init_registers_xtensa): Add prototype.
17813 (the_low_target): Add initializer for arch_setup field.
17814
17815 * win32-low.h (struct win32_target_ops): Add arch_setup field.
17816 * win32-low.c (initialize_low): Call the_low_target.arch_setup ()
17817 instead of init_registers ().
17818 * win32-arm-low.c (init_registers_arm): Add prototype.
17819 (the_low_target): Add initializer for arch_setup field.
17820 * win32-i386-low.c (init_registers_i386): Add prototype.
17821 (the_low_target): Add initializer for arch_setup field.
17822
17823 * spu-low.c (init_registers_spu): Add prototype.
17824 (initialize_low): Call initialie_registers_spu () instead of
17825 initialize_registers ().
17826
fd96d250
PA
178272008-02-19 Pedro Alves <pedro@codesourcery.com>
17828
17829 * server.c (handle_v_requests): When handling the vRun and vAttach
17830 packets, if already debugging a process, don't kill it. Return an
17831 error instead.
17832
d41b6bb4
DJ
178332008-02-17 Daniel Jacobowitz <dan@codesourcery.com>
17834
17835 * server.c (handle_query): Correct length check.
17836
5ac588cf
PA
178372008-02-14 Pedro Alves <pedro_alves@portugalmail.pt>
17838
17839 * win32-low.c (do_initial_child_stuff): Add process handle
17840 parameter. Set current_process_handle and current_process_id from the
17841 parameters. Clear globals.
17842 (win32_create_inferior): Don't set current_process_handle and
17843 current_process_id here. Instead pass them on the call to
17844 do_initial_child_stuff.
17845 (win32_attach): Likewise.
17846 (win32_clear_inferiors): New.
17847 (win32_kill): Don't close the current process handle or the
17848 current thread handle here. Instead call win32_clear_inferiors.
17849 (win32_detach): Don't open a new handle to the process. Call
17850 win32_clear_inferiors.
17851 (win32_join): Don't rely on current_process_handle; open a new
17852 handle using the process id.
17853 (win32_wait): Call win32_clear_inferiors when the inferior process
17854 has exited.
17855
ecd7ecbc
DJ
178562008-02-14 Daniel Jacobowitz <dan@codesourcery.com>
17857
17858 * server.c (monitor_show_help): Add "exit".
17859
1525d545
MG
178602008-02-11 Maxim Grigoriev <maxim2405@gmail.com>
17861
ecd7ecbc 17862 * Makefile.in (SFILES): Add linux-xtensa-low.c.
1525d545
MG
17863 (clean): Add reg-xtensa.c.
17864 (linux-xtensa-low.o, reg-xtensa.o, reg-xtensa.c): New dependencies.
ecd7ecbc
DJ
17865 * configure.srv (xtensa*-*-linux*) New target.
17866 * linux-xtensa-low.c: New.
17867 * xtensa-xtregs.c: New.
1525d545 17868
59a016f0
PA
178692008-02-01 Pedro Alves <pedro_alves@portugalmail.pt>
17870
17871 * hostio.c: Don't include errno.h.
17872 (errno_to_fileio_errno): Move to hostio-errno.
17873 * hostio.c: (hostio_error): Remove the error parameter. Defer the
17874 error number outputting to the target->hostio_last_error callback.
17875 (hostio_packet_error): Use FILEIO_EINVAL directly.
17876 (handle_open, handle_pread, hostio_error, handle_unlink): Update
17877 calls to hostio_error.
17878 * hostio-errno.c: New.
17879 * server.h (hostio_last_error_from_errno): Declare.
17880 * target.h (target_ops): Add hostio_last_error member.
17881 * linux-low.c (linux_target_op): Register hostio_last_error_from_errno
17882 as hostio_last_error handler.
889bf7c5 17883 * spu-low.c (spu_target_ops): Likewise.
59a016f0
PA
17884 * win32-low.c [_WIN32_WCE] (win32_error_to_fileio_error)
17885 (wince_hostio_last_error): New functions.
17886 (win32_target_ops) [_WIN32_WCE]: Register wince_hostio_last_error
17887 as hostio_last_error handler.
17888 (win32_target_ops) [!_WIN32_WCE]: Register
17889 hostio_last_error_from_errno as hostio_last_error handler.
17890 * Makefile.in (SFILES): Add hostio.c and hostio-errno.c.
17891 (hostio-errno.o): New rule.
17892 * configure.ac (GDBSERVER_DEPFILES): Add $srv_hostio_err_objs.
17893 * configure.srv (srv_hostio_err_objs): New variable. Default to
17894 hostio-errno.o.
17895 (arm*-*-mingw32ce*): Set srv_hostio_err_objs to "".
17896 * configure: Regenerate.
17897
2d717e4f
DJ
178982008-01-29 Daniel Jacobowitz <dan@codesourcery.com>
17899
17900 * linux-low.c (linux_attach_lwp): Do not _exit after errors.
17901 (linux_kill, linux_detach): Clean up the process list.
17902 * remote-utils.c (remote_open): Improve port number parsing.
17903 (putpkt_binary, input_interrupt): Only send interrupts if the target
17904 is running.
17905 * server.c (extended_protocol): Make static.
17906 (attached): Define earlier.
17907 (exit_requested, response_needed, program_argv): New variables.
17908 (target_running): New.
17909 (start_inferior): Clear attached here.
17910 (attach_inferior): Set attached here.
17911 (require_running): Define.
17912 (handle_query): Use require_running and target_running. Implement
17913 "monitor exit".
17914 (handle_v_attach, handle_v_run): New.
17915 (handle_v_requests): Use require_running. Handle vAttach and vRun.
17916 (gdbserver_usage): Update.
17917 (main): Redo argument parsing. Handle --debug and --multi. Handle
17918 --attach along with other options or after the port. Save
17919 program_argv. Support no initial program. Resynchronize
17920 communication with GDB after an error. Handle "monitor exit".
17921 Use require_running and target_running. Always allow the extended
17922 protocol. Do not error out for Hc0 or Hc-1. Do not automatically
17923 restart in extended mode.
17924 * README: Refer to the GDB manual. Update --attach usage.
17925
7407e2de
AS
179262007-12-20 Andreas Schwab <schwab@suse.de>
17927
17928 * linux-low.c (STACK_SIZE): Define.
17929 (linux_tracefork_child): Use it. Use __clone2 on ia64.
17930 (linux_test_for_tracefork): Likewise.
17931
b65d95c5
DJ
179322007-12-18 Daniel Jacobowitz <dan@codesourcery.com>
17933
17934 * linux-low.c (linux_wait_for_event): Update messages. Do not
17935 reinsert auto-delete breakpoints.
17936 * mem-break.c (struct breakpoint): Change return type of handler to
17937 int.
17938 (set_breakpoint_at): Update handler type.
17939 (reinsert_breakpoint_handler): Return 1 instead of calling
17940 delete_breakpoint.
17941 (reinsert_breakpoint_by_bp): Check for the original breakpoint before
17942 setting a new one.
17943 (check_breakpoints): Delete auto-delete breakpoints and return 2.
17944 * mem-break.h (set_breakpoint_at): Update handler type.
17945 * thread-db.c (thread_db_create_event, thread_db_create_event): Update.
17946 * win32-low.c (auto_delete_breakpoint): New.
17947 (get_child_debug_event): Use it.
17948
4e799345
DJ
179492007-12-16 Daniel Jacobowitz <dan@codesourcery.com>
17950
17951 * configure.ac: Check for pread and pwrite.
17952 * hostio.c (handle_pread): Fall back to lseek and read.
17953 (handle_pwrite): Fall back to lseek and write.
17954 * config.in, configure: Regenerated.
17955
27524b67
DJ
179562007-12-07 Daniel Jacobowitz <dan@codesourcery.com>
17957
17958 * server.c (myresume): Add own_buf argument.
17959 (main): Update calls.
17960
a20d5e98
DJ
179612007-12-06 Daniel Jacobowitz <dan@codesourcery.com>
17962
17963 * linux-low.c (linux_wait, linux_resume): Do not handle async I/O.
17964 * remote-utils.c (remote_open): Do not call disable_async_io.
17965 (block_async_io): Delete.
17966 (unblock_async_io): Make static.
17967 (initialize_async_io): New.
17968 * server.c (handle_v_cont): Handle async I/O here.
17969 (myresume): Likewise. Move other common resume tasks here...
17970 (main): ... from here. Call initialize_async_io. Disable async
17971 I/O before the main loop.
17972 * server.h (initialize_async_io): Declare.
17973 (block_async_io, unblock_async_io): Delete prototypes.
17974 * spu-low.c (spu_resume, spu_wait): Do not handle async I/O here.
17975
b79d787e
DJ
179762007-12-06 Mick Davis <mickd@goanna.iinet.net.au>
17977
17978 * remote-utils.c (readchar): Allow binary data in received messages.
17979
d97903b2
PA
179802007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
17981
17982 * win32-low.c (attaching): New global.
17983 (win32_create_inferior): Clear the `attaching' global.
17984 (win32_attach): Set the `attaching' global.
17985 (get_child_debug_event) [_WIN32_WCE]: Stop the inferior when
17986 attaching. Only set a breakpoint at the entry point if not
17987 attaching.
17988
311de423
PA
179892007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
17990
17991 * server.c (main): Don't report dll events on the initial
17992 connection on attaches.
17993
6c2d16d2
PA
179942007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
17995
17996 * server.c (main): Relax numerical bases supported for the pid of
17997 the --attach command line argument.
17998
5ca906e6
PA
179992007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
18000
18001 * win32-low.c (win32_attach): Call OpenProcess before
18002 DebugActiveProcess, not after. Add last error output to error
18003 call.
18004
9c6c8194
PA
180052007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
18006
18007 * win32-low.c (win32_get_thread_context)
18008 (win32_set_thread_context): New functions.
18009 (thread_rec): Use win32_get_thread_context.
18010 (continue_one_thread, win32_resume): Use win32_set_thread_context.
18011 * win32-low.h (win32_thread_info) [_WIN32_WCE]: Add `base_context'
18012 field.
18013
4d5d1aaa
PA
180142007-12-03 Leo Zayas
18015 Pedro Alves <pedro_alves@portugalmail.pt>
18016
18017 * win32-low.c (soft_interrupt_requested, faked_breakpoint): New
18018 global variables.
18019 (child_add_thread): Minor cleanup.
18020 (child_continue): Resume artificially suspended threads before
18021 calling ContinueDebugEvent.
18022 (suspend_one_thread): New.
18023 (fake_breakpoint_event): New.
18024 (get_child_debug_event): Change return type to int. Check here if
18025 gdb sent an interrupt request. If a soft interrupt was requested,
18026 fake a breakpoint event. Return 0 if there is no event to handle,
18027 and 1 otherwise.
18028 (win32_wait): Don't check here if gdb sent an interrupt request.
18029 Ensure there is a valid event to handle.
18030 (win32_request_interrupt): Add soft interruption method as last
18031 resort.
18032
c436e841
PA
180332007-12-03 Leo Zayas
18034 Pedro Alves <pedro_alves@portugalmail.pt>
18035
18036 * win32-low.h (win32_thread_info): Add descriptions to the
18037 structure members. Replace `suspend_count' counter by a
18038 `suspended' flag.
18039 * win32-low.c (thread_rec): Update condition of when to get the
18040 context from the inferior. Rely on ContextFlags being set if it
18041 has already been retrieved. Only suspend the inferior thread if
18042 we haven't already. Warn if that fails.
18043 (continue_one_thread): s/suspend_count/suspended/. Only call
18044 ResumeThread once. Warn if that fails.
18045
e7b5fa67
PA
180462007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
18047
18048 * win32-low.c (win32_wait): Don't read from the inferior when it
18049 has already exited.
18050
a385171d
PA
180512007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
18052
18053 * Makefile.in (win32_low_h): New variable.
18054 (win32-low.o): Add dependency on $(win32_low_h).
18055 (win32-arm-low.o, win32-i386-low.o): New rules.
18056
f80c84b3
DJ
180572007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
18058
18059 * hostio.c: Correct copyright year.
18060
a6b151f1
DJ
180612007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
18062
18063 * Makefile.in (OBS): Add hostio.o.
18064 (hostio.o): New rule.
18065 * server.h (handle_vFile): Declare.
18066 * hostio.c: New file.
18067 * server.c (handle_v_requests): Take packet_len and new_packet_len
18068 for binary packets. Call handle_vFile.
18069 (main): Update call to handle_v_requests.
18070
f9387fc3
DJ
180712007-11-05 Daniel Jacobowitz <dan@codesourcery.com>
18072
18073 * linux-low.c: Include <sched.h>.
18074
51c2684e
DJ
180752007-11-01 Daniel Jacobowitz <dan@codesourcery.com>
18076
18077 * linux-low.c (linux_tracefork_grandchild): New.
18078 (linux_tracefork_child): Use clone.
18079 (linux_test_for_tracefork): Use clone; allocate and free a stack.
18080
75f83163
JB
180812007-10-31 Joel Brobecker <brobecker@adacore.com>
18082
18083 * Makefile.in: Use $(SHELL) instead of "sh" to call regdat.sh.
18084
da5898ce
DJ
180852007-10-24 Daniel Jacobowitz <dan@codesourcery.com>
18086
18087 * linux-low.c (handle_extended_wait): Handle unexpected signals.
18088
24a09b5f
DJ
180892007-10-23 Daniel Jacobowitz <dan@codesourcery.com>
18090
18091 * inferiors.c (change_inferior_id): Delete.
18092 (add_pid_to_list, pull_pid_from_list): New.
18093 * linux-low.c (PTRACE_SETOPTIONS, PTRACE_GETEVENTMSG)
18094 (PTRACE_O_TRACESYSGOOD, PTRACE_O_TRACEFORK, PTRACE_O_TRACEVFORK)
18095 (PTRACE_O_TRACECLONE, PTRACE_O_TRACEEXEC, PTRACE_O_TRACEVFORKDONE)
18096 (PTRACE_O_TRACEEXIT, PTRACE_EVENT_FORK, PTRACE_EVENT_VFORK)
18097 (PTRACE_EVENT_CLONE, PTRACE_EVENT_EXEC, PTRACE_EVENT_VFORK_DONE)
18098 (PTRACE_EVENT_EXIT, __WALL): Provide default definitions.
18099 (stopped_pids, thread_db_active, must_set_ptrace_flags): New variables.
18100 (using_threads): Always set to 1.
18101 (handle_extended_wait): New.
18102 (add_process): Do not set TID.
18103 (linux_create_inferior): Set must_set_ptrace_flags.
18104 (linux_attach_lwp): Remove TID argument. Do not check using_threads.
18105 Use PTRACE_SETOPTIONS. Call new_thread_notify. Update all callers.
18106 (linux_thread_alive): Rename TID argument to LWPID.
18107 (linux_wait_for_process): Handle unknown processes. Do not use TID.
18108 (linux_wait_for_event): Do not use TID or check using_threads. Update
18109 call to dead_thread_notify. Call handle_extended_wait.
18110 (linux_create_inferior): Use PTRACE_SETOPTIONS.
18111 (send_sigstop): Delete sigstop_sent.
18112 (wait_for_sigstop): Avoid TID.
18113 (linux_supports_tracefork_flag, linux_tracefork_child, my_waitpid)
18114 (linux_test_for_tracefork): New.
18115 (linux_lookup_signals): Use thread_db_active and
18116 linux_supports_tracefork_flag.
18117 (initialize_low): Use thread_db_active and linux_test_for_tracefork.
18118 * linux-low.h (get_process_thread): Avoid TID.
18119 (struct process_ifo): Move thread_known and tid to the end. Remove
18120 sigstop_sent.
18121 (linux_attach_lwp, thread_db_init): Update prototypes.
18122 * server.h (change_inferior_id): Delete prototype.
18123 (add_pid_to_list, pull_pid_from_list): New prototypes.
18124 * thread-db.c (thread_db_use_events): New.
18125 (find_first_thread): Rename to...
18126 (find_one_thread): ...this. Update callers and messages. Do not
18127 call fatal. Check thread_db_use_events. Do not call
18128 change_inferior_id or new_thread_notify.
18129 (maybe_attach_thread): Update. Do not call new_thread_notify.
18130 (thread_db_init): Set thread_db_use_events. Check use_events.
18131 * utils.c (fatal, warning): Correct message prefix.
18132
30ed0a8f
DJ
181332007-10-15 Daniel Jacobowitz <dan@codesourcery.com>
18134
18135 * Makefile.in (clean): Remove new files.
18136 (powerpc-32.o, powerpc-32.c, powerpc-e500.o, powerpc-e500.c)
18137 (powerpc-64.o, powerpc-64.c): New rules.
18138 * configure.srv: Use alternate register sets for powerpc64-*-linux*
18139 with AltiVec, powerpc-*-linux* with AltiVec, and powerpc-*-linux*
18140 with SPE.
18141 * linux-ppc-low.c (ppc_regmap): Do not fetch the FP registers for
18142 SPE targets.
18143 (ppc_cannot_store_register): Do not check for FPSCR for SPE targets.
18144 (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS, ppc_fill_vrregset)
18145 (ppc_store_vrregset, PTRACE_GETEVRREGS, PTRACE_SETEVRREGS)
18146 (struct gdb_evrregset_t, ppc_fill_evrregset, ppc_store_evrregset): New.
18147 (target_regsets): Add AltiVec and SPE register sets.
18148 * configure.ac: Check for AltiVec and SPE.
18149 * linux-ppc64-low.c (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS)
18150 (ppc_fill_vrregset, ppc_store_vrregset): New.
18151 (target_regsets): Add AltiVec register set.
18152 * configure: Regenerated.
18153
fd462a61
DJ
181542007-09-19 Daniel Jacobowitz <dan@codesourcery.com>
18155
18156 * linux-low.c (O_LARGEFILE): Define.
18157 (linux_read_memory): Use /proc/PID/mem.
18158 * configure.ac: Use AC_GNU_SOURCE. Check for pread64.
18159 * configure, config.in: Regenerated.
18160
69f223ed
DJ
181612007-09-04 Daniel Jacobowitz <dan@codesourcery.com>
18162
18163 * linux-low.c (linux_wait_for_event): Do not pass signals while
18164 single-stepping.
18165
aec18585
PA
181662007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
18167
18168 * win32-low.c (create_process): New.
18169 (win32_create_inferior): Use create_process instead of
18170 CreateProcess. If create_process failed retry appending an ".exe"
18171 suffix. Store the GetLastError result immediatelly after
18172 create_process calls and use it on the call to error.
18173
34d86ddd
PA
181742007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
18175
18176 * win32-low.c (handle_load_dll): Don't use toolhelp when waiting.
18177
5a0e3bd0
JB
181782007-08-23 Joel Brobecker <brobecker@adacore.com>
18179
18180 * configure.ac: Switch license to GPLv3.
18181
f88c79e6
MS
181822007-08-01 Michael Snyder <msnyder@access-company.com>
18183
18184 * remote-utils.c (putpkt_binary): Memory leak, free buf2.
18185
6b3d9b83
PA
181862007-07-31 Pedro Alves <pedro_alves@portugalmail.pt>
18187
18188 * win32-low.c (winapi_CloseToolhelp32Snapshot) [_WIN32_WCE]: New
18189 typedef.
18190 (win32_CloseToolhelp32Snapshot) [_WIN32_WCE]: New global var.
18191 (load_toolhelp) [_WIN32_WCE]: Load TOOLHELP.DLL. Get
18192 CloseToolhelp32Snapshot.
18193 (toolhelp_get_dll_name) [_WIN32_WCE]: Close the snapshot with
18194 CloseToolhelp32Snapshot.
18195
c588c53c
MS
181962007-07-27 Michael Snyder <michael.snyder@access-company.com>
18197
18198 * server.c (main): Check for inferior exit before main loop.
18199
aa0403d9
PA
182002007-07-18 Pedro Alves <pedro_alves@portugalmail.pt>
18201
18202 * remote-utils.c (remote_open): Set SO_KEEPALIVE on remote_desc
18203 instead of on tmp_desc.
18204
255e7678
DJ
182052007-07-17 Pedro Alves <pedro_alves@portugalmail.pt>
18206 Daniel Jacobowitz <dan@codesourcery.com>
18207
18208 * inferiors.c (all_dlls, dlls_changed, get_dll): New.
18209 (add_thread): Minor cleanups.
18210 (clear_inferiors): Move lower in the file. Clear the DLL
18211 list.
18212 (free_one_dll, match_dll, loaded_dll, unloaded_dll, clear_list): New.
18213 * remote-utils.c (prepare_resume_reply): Check dlls_changed.
18214 (xml_escape_text): New.
18215 * server.c (handle_query): Handle qXfer:libraries:read. Report it
18216 for qSupported.
18217 (handle_v_cont): Report errors.
18218 (gdbserver_version): Update.
18219 (main): Correct size of own_buf. Do not report initial DLL events.
18220 * server.h (struct dll_info, all_dlls, dlls_changed, loaded_dll)
18221 (unloaded_dll, xml_escape_text): New.
18222 * win32-low.c (enum target_waitkind): Update comments.
18223 (win32_add_one_solib, get_image_name, winapi_EnumProcessModules)
18224 (winapi_GetModuleInformation, winapi_GetModuleFileNameExA)
18225 (win32_EnumProcessModules, win32_GetModuleInformation)
18226 (win32_GetModuleFileNameExA, load_psapi, psapi_get_dll_name)
18227 (winapi_CreateToolhelp32Snapshot, winapi_Module32First)
18228 (winapi_Module32Next, win32_CreateToolhelp32Snapshot)
18229 (win32_Module32First, win32_Module32Next, load_toolhelp)
18230 (toolhelp_get_dll_name, handle_load_dll, handle_unload_dll): New.
18231 (get_child_debug_event): Handle DLL events.
18232 (win32_wait): Likewise.
18233
0d37add9
DJ
182342007-07-12 Daniel Jacobowitz <dan@codesourcery.com>
18235
18236 * configure.srv: Set srv_linux_regsets for sh*-*-linux*.
18237 * linux-sh-low.c (sh_fill_gregset, target_regsets): New.
18238
45e2715e
PA
182392007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
18240
18241 * win32-low.c (handle_output_debug_string): Ignore event if not
18242 waiting.
18243
c5674cf1
PA
182442007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
18245
18246 * win32-arm-low.c (arm_wince_breakpoint): Fix typo.
18247
2bbe3cc1
DJ
182482007-07-03 Daniel Jacobowitz <dan@codesourcery.com>
18249
18250 * remote-utils.c (look_up_one_symbol): Handle 'm' packets.
18251
ae13219e
DJ
182522007-07-02 Daniel Jacobowitz <dan@codesourcery.com>
18253
18254 * inferiors.c (change_inferior_id): Add comment.
18255 * linux-low.c (check_removed_breakpoint): Add an early
18256 prototype. Improve debug output.
18257 (linux_attach): Doc update.
18258 (linux_detach_one_process, linux_detach): Clean up before releasing
18259 each process.
18260 (send_sigstop, wait_for_sigstop): Improve comments and debug output.
18261 * linux-low.h (struct process_info): Doc improvement.
18262 * mem-break.c (delete_all_breakpoints): New.
18263 * mem-break.h (delete_all_breakpoints): New prototype.
18264 * thread-db.c (find_first_thread): New.
18265 (thread_db_create_event): Call it instead of
18266 thread_db_find_new_threads. Clean up unused variables.
18267 (maybe_attach_thread): Remove first thread handling.
18268 (thread_db_find_new_threads): Use find_first_thread.
18269 (thread_db_get_tls_address): Likewise.
18270
4105de34
DJ
182712007-06-27 Daniel Jacobowitz <dan@codesourcery.com>
18272
18273 * thread-db.c (thread_db_find_new_threads): Add prototype.
18274 (thread_db_create_event): Check for the main thread before adding
18275 a new thread.
18276 (maybe_attach_thread): Only enable event reporting if TID == 0.
18277 (thread_db_get_tls_address): Check for new threads.
18278
2b876972
DJ
182792007-06-20 Daniel Jacobowitz <dan@codesourcery.com>
18280
18281 * linux-low.c (linux_create_inferior): Try execv before execvp.
18282 * spu-low.c (spu_create_inferior): Likewise.
18283
7a245884
DJ
182842007-06-13 Mike Frysinger <vapier@gentoo.org>
18285
18286 * linux-low.c (linux_create_inferior): Change execv to execvp.
18287 * spu-low.c (spu_create_inferior): Likewies.
18288
117ce543
DJ
182892007-06-13 Daniel Jacobowitz <dan@codesourcery.com>
18290
18291 * Makefile.in (clean): Clean new files instead of deleted ones.
18292 (reg-mips.o, reg-mips.c, reg-mips64.o, reg-mips64.c): Delete.
18293 (mips-linux.o, mips-linux.c, mips64-linux.o, mips64-linux.c): New
18294 rules.
18295 * configure.srv: Specify XML files and new regformats for MIPS and
18296 MIPS64 GNU/Linux.
18297 * linux-mips-low.c (mips_num_regs): Set to only used registers.
18298 (mips_regmap): Do not fetch $0. Remove unused registers. Add
18299 an entry for the restart register.
18300 (mips_cannot_fetch_register, mips_cannot_store_register)
18301 (mips_reinsert_addr, mips_fill_fpregset, mips_store_fpregset): Update
18302 register names to match the XML descriptions.
18303 (mips_fill_gregset, mips_store_gregset): Likewise. Handle the
18304 restart register instead of $0.
18305
0e7f50da
UW
183062007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
18307 Markus Deuling <deuling@de.ibm.com>
18308
18309 * remote-utils.c (decode_xfer_write): New function.
18310 * server.h (decode_xfer_write): Add prototype.
18311 * server.c (handle_query): Add PACKET_LEN argument. Support
18312 qXfer:spu:read and qXfer:spu:write packets.
18313 (main): Pass packet_len to handle_query.
18314 * spu-low.c (spu_target_ops): Add spu_proc_xfer_spu.
18315 * target.h (target_ops): Add qxfer_spu.
18316
374c1d38
UW
183172007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
18318
18319 * spu-low.c (spu_proc_xfer_spu): Do not return failure when
18320 accessing non-seekable spufs files.
18321
bb63802a
UW
183222007-05-16 Markus Deuling <deuling@de.ibm.com>
18323
889bf7c5 18324 * server.c (handle_query): Add reply for qC packet.
bb63802a 18325
7390519e
PA
183262007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
18327 Leo Zayas <lerele@champenstudios@com>
18328
18329 * server.h (check_remote_input_interrupt_request): New function.
18330 * remote_utils.c (INVALID_DESCRIPTOR): New define.
18331 (remote_desc): Initialize with INVALID_DESCRIPTOR.
18332 (input_interrupt): Expose on USE_WIN32API too. Fix whitespace.
18333 (check_remote_input_interrupt_request): New function.
18334 * server.h (check_remote_input_interrupt_request): Declare.
3ecf0694 18335 * win32-low.c (winapi_DebugBreakProcess,
7390519e
PA
18336 winapi_GenerateConsoleCtrlEvent): New typedefs.
18337 (get_child_debug_event): Lower Win32 debug event polling from 1 sec
18338 to 250 ms.
18339 (win32_wait): Check for remote interrupt request
18340 with check_remote_input_interrupt_request.
18341 (win32_request_interrupt): New function.
18342 (win32_target_op): Set request_interrupt to win32_request_interrupt.
18343
34b34921
PA
183442007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
18345
18346 * win32-low.c (debug_registers_changed,
18347 debug_registers_used, CONTEXT_EXTENDED_REGISTERS,
18348 CONTEXT_FLOATING_POINT, CONTEXT_DEBUG_REGISTERS,
18349 CONTEXT_DEBUGGER, CONTEXT_DEBUGGER_DR): Delete.
18350 (thread_rec): Get context using the low target.
18351 (child_add_thread): Call thread_added on the low target,
18352 which does the same thing.
18353 (regptr): Delete.
18354 (do_initial_child_stuff): Remove debug registers references.
18355 Set context using the low target. Resume threads after
18356 setting the contexts.
18357 (child_continue): Remove dead variable. Remove debug
18358 registers references.
18359 (child_fetch_inferior_registers): Go through the low target.
18360 (do_child_store_inferior_registers): Remove.
18361 (child_store_inferior_registers): Go through the low target.
18362 (win32_resume): Remove debug registers references.
18363 Set context using the low target.
18364 (handle_exception): Change return type to void. Don't record
18365 context here. Set status to TARGET_WAITKIND_SPURIOUS on a
18366 first chance exception.
889bf7c5 18367 (get_child_debug_event): Change return type to void. Remove
34b34921
PA
18368 goto loop. Always return after waiting for debug event.
18369 (win32_wait): Convert to switch statement. Handle spurious
18370 events.
18371
18372 * win32-i386-low.c (debug_registers_changed,
18373 debug_registers_used): New.
18374 (initial_stuff): Rename to ...
18375 (i386_initial_stuff): ... this. Clear debug registers
18376 state variables.
18377 (store_debug_registers): Delete.
18378 (i386_get_thread_context): New.
18379 (load_debug_registers): Delete.
18380 (i386_set_thread_context): New.
18381 (i386_thread_added): New.
18382 (single_step): Rename to ...
18383 (i386_single_step): ... this.
18384 (do_fetch_inferior_registers): Rename to ...
18385 (i386_fetch_inferior_register): ... this.
18386 (i386_store_inferior_register): New.
18387 (the_low_target): Adapt to new interface.
18388
18389 * win32-arm-low.c (CONTEXT_FLOATING_POINT): Define.
18390 (arm_get_thread_context): New.
18391 (arm_set_thread_context): New.
18392 (regptr): New.
18393 (do_fetch_inferior_registers): Rename to ...
18394 (arm_fetch_inferior_register): ... this.
18395 (arm_store_inferior_register): New.
18396 (arm_wince_breakpoint): Reimplement as unsigned long.
18397 (arm_wince_breakpoint_len): Define.
18398 (the_low_target): Adapt to new interface.
18399
18400 * win32-low.h (target_ops): Remove regmap, store_debug_registers and
18401 load_debug_registers. Add get_thread_context, set_thread_context,
18402 thread_added and store_inferior_register. Rename
18403 fetch_inferior_registers to fetch_inferior_register.
18404 (regptr): Remove declaration.
18405
dd6953e1
PA
184062007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
18407
18408 * linux-low.c (linux_detach): Change return type to int. Return 0.
18409 * spu-low.c (spu_detach): Likewise.
18410
444d6139
PA
184112007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
18412
18413 * target.h (target_ops): Change return type of detach to int.
18414 Add join.
18415 (join_inferior): New.
18416 * server.c (main): Don't skip detach support on mingw32.
18417 If the inferior doesn't support detaching return error.
18418 Call join_inferior instead of using waitpid.
18419 * linux-low.c (linux_join): New.
18420 (linux_target_op): Add linux_join.
18421 * spu-low.c (spu_join): New.
18422 (spu_target_ops): Add spu_join.
18423 * win32-low.c (win32_detach): Adapt to new interface.
18424 Reopen current_process_handle before detaching. Issue a child
18425 resume before detaching.
18426 (win32_join): New.
18427 (win32_target_op): Add win32_join.
18428
1d5315fe
PA
184292007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
18430
18431 * win32-low.c (win32-attach): Fix return value.
18432 * target.h (target_ops): Describe ATTACH return values.
18433
bf914831
PA
184342007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
18435
18436 * win32-low.c (GETPROCADDRESS): Define.
18437 (winapi_DebugActiveProcessStop): Add WINAPI. typedef as pointer.
18438 (winapi_DebugSetProcessKillOnExit): Likewise.
18439 (win32_create_inferior): Force usage of ansi CreateProcessA.
18440 (win32_attach): Use GETPROCADDRESS.
18441 (win32_detach): Likewise.
18442
f72f3e60
PA
184432007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
18444
18445 * win32-low.c (win32_wait): Don't use WSTOPSIG.
18446
ed50f18f
PA
184472007-03-30 Pedro Alves <pedro_alves@portugalmail.pt>
18448
18449 * win32-low.c: Commit leftover changes from 2007-03-29.
18450
0c2ead7e
DJ
184512007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
18452
18453 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Make 16-bit
18454 fields short instead of int. Add explicit padding.
18455 (i387_cache_to_fsave): Remove unnecessary casts.
18456 (i387_fsave_to_cache): Doc fix.
18457 (i387_cache_to_fxsave): Remove unnecessary casts and masking.
18458
73725ff3
DJ
184592007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
18460
18461 * i387-fp.c (i387_cache_to_fxsave): Reinitialize val2 before use.
18462 (i387_fxsave_to_cache): Check fp->ftag while building ftag value.
18463
d99f33d8
PA
184642007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
18465
18466 * configure.srv (arm*-*-mingw32ce*): Move near the other
18467 arm targets.
18468
68070c10
PA
184692007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
18470
2482afc6 18471 * configure.ac: Add errno checking.
68070c10
PA
18472 (AC_CHECK_HEADERS): Add errno.h, fcntl.h, signal.h,
18473 sys/file.h and malloc.h.
18474 (AC_CHECK_DECLS): Add perror.
18475 (srv_mingwce): Handle.
2482afc6 18476 * configure.srv (i[34567]86-*-cygwin*): Add
68070c10
PA
18477 win32-i386-low.o to srv_tgtobj.
18478 (i[34567]86-*-mingw*): Likewise.
18479 (arm*-*-mingw32ce*): Add case.
18480 * gdbreplay.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
18481 HAVE_FCNTL_H, HAVE_ERRNO_H, HAVE_MALLOC_H]: Check.
18482 [__MINGW32CE__] (strerror): New function.
18483 [__MINGW32CE__] (errno): Define to GetLastError.
18484 [__MINGW32CE__] (COUNTOF): New macro.
18485 (remote_open): Remove extra close call.
18486 * mem-break.c (delete_breakpoint_at): New function.
18487 * mem-break.h (delete_breakpoint_at): Declare.
18488 * remote-utils.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
18489 HAVE_FCNTL_H, HAVE_UNISTD_H, HAVE_ERRNO_H]: Check.
18490 [USE_WIN32API] (read, write): Add char* casts.
18491 * server.c [HAVE_UNISTD_H, HAVE_SIGNAL_H]: Check.
18492 * server.h: Include wincecompat.h on Windows CE.
18493 [HAVE_ERRNO_H]: Check.
18494 (perror): Declare if not declared.
18495 * utils.c: Add stdlib.h, errno.h and malloc.h includes.
18496 (perror_with_name): Remove errno declaration.
18497 * wincecompat.h: New.
18498 * wincecompat.c: New.
18499 * win32-low.h: New.
18500 * win32-arm-low.c: New.
18501 * win32-i386-low.c: New.
18502 (win32-low.c): Include mem-break.h and win32-low.h, and winnt.h.
18503 (OUTMSG2): Make it safe.
18504 (_T): New macro.
18505 (COUNTOF): New macro.
18506 (NUM_REGS): Get it from the low target.
18507 (CONTEXT_EXTENDED_REGISTERS, CONTEXT_FLOATING_POINT,
18508 CONTEXT_DEBUG_REGISTERS): Add fallbacks to 0.
18509 (thread_rec): Let low target handle debug registers.
18510 (child_add_thread): Likewise.
18511 (child_init_thread_list): Likewise.
18512 (continue_one_thread): Likewise.
18513 (regptr): New.
18514 (do_child_fetch_inferior_registers): Move to ...
18515 * win32-i386-low.c: ... here, and rename to ...
18516 (do_fetch_inferior_registers): ... this.
889bf7c5 18517 * win32-low.c (child_fetch_inferior_registers):
68070c10
PA
18518 Go through the low target.
18519 (do_child_store_inferior_registers): Use regptr.
18520 (strwinerror): New function.
18521 (win32_create_inferior): Handle Windows CE.
18522 Use strwinerror instead of strerror on Windows error
18523 codes. Add program to the error output.
18524 Don't close the main thread handle on Windows CE.
18525 (win32_attach): Use coredll.dll on Windows CE.
18526 (win32_kill): Close current process and current
18527 thread handles.
18528 (win32_detach): Use coredll.dll on Windows CE.
18529 (win32_resume): Let low target handle debug registers, and
18530 step request.
18531 (handle_exception): Add/Remove initial breakpoint. Avoid
18532 non-existant WSTOPSIG on Windows CE.
18533 (win32_read_inferior_memory): Cast to remove warning.
18534 (win32_arch_string): Go through the low target.
18535 (initialize_low): Call set_breakpoint_data with the low
18536 target's breakpoint.
18537 * win32-low.c (dr, FLAG_TRACE_BIT, FCS_REGNUM,
18538 FOP_REGNUM, mappings): Move to ...
18539 * win32-i386-low.c: ... here.
18540 * win32-low.c (win32_thread_info): Move to ...
18541 * win32-low.h: ... here.
18542 * Makefile.in (SFILES): Add win32-low.c, win32-i386-low.c,
18543 win32-arm-low.c and wincecompat.c.
18544 (all:): Add $EXEEXT.
18545 (install-only:): Likewise.
18546 (gdbserver:): Likewise.
18547 (gdbreplay:): Likewise.
18548 * config.in: Regenerate.
18549 * configure: Regenerate.
18550
41093d81
PA
185512007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
18552
18553 * win32-low.c: Rename typedef thread_info to
18554 win32_thread_info throughout.
18555
544afa54
PA
185562007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
18557
18558 * win32-i386-low.c: Rename to ...
18559 * win32-low.c: ... this.
18560 * configure.srv: Replace win32-i386-low.o with win32-low.o.
18561 * Makefile.in: Likewise.
18562
bce7165d
PA
185632007-03-27 Pedro Alves <pedro_alves@portugalmail.pt>
18564
18565 * remote-utils.c (monitor_output): Constify msg parameter.
18566 * server.h (monitor_output): Likewise.
18567 * win32-i386-low.c (handle_output_debug_string): New.
18568 (win32_kill): Handle OUTPUT_DEBUG_STRING_EVENT events using
18569 handle_output_debug_string.
18570 (get_child_debug_event): Likewise.
18571
506c7aa0
DJ
185722007-03-27 Mat Hostetter <mat@lcs.mit.edu>
18573
18574 * server.c (main): Correct strtoul check.
18575
42c81e2a
DJ
185762007-03-27 Jon Ringle <jon@ringle.org>
18577
18578 * linux-low.c: Check __ARCH_HAS_MMU__ also.
18579
9453113a
DJ
185802007-03-27 Brooks Moses <brooks.moses@codesourcery.com>
18581
18582 * Makefile.in: Add dummy "pdf" and "install-pdf" targets.
18583
64a69107
DJ
185842007-02-27 Daniel Jacobowitz <dan@codesourcery.com>
18585
18586 * terminal.h: Check HAVE_SGTTY_H.
18587
185882007-02-27 Mat Hostetter <mat@lcs.mit.edu>
6f8486da
DJ
18589
18590 * remote-utils.c (remote_open): Print out the assigned port number.
18591
c74d0ad8
DJ
185922007-02-26 Daniel Jacobowitz <dan@codesourcery.com>
18593
18594 * remote-utils.c (monitor_output): New function.
18595 * server.c (debug_threads): Define here.
18596 (monitor_show_help): New function.
18597 (handle_query): Handle qRcmd.
18598 (main): Do not handle 'd' packet.
18599 * server.h (debug_threads, remote_debug, monitor_output): Declare.
18600 * linux-low.c, spu-low.c, win32-i386-low.c: Remove definitions
18601 of debug_threads.
18602
de7c3b4a
PA
186032007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
18604
18605 * Makefile.in (EXEEXT): New.
18606 (clean): Use $(EXEEXT).
18607
ef57601b
PA
186082007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
18609
18610 * target.h (target_ops): Rename send_signal to request_interrupt,
18611 and remove enum target_signal parameter.
18612 * linux-low.c (linux_request_interrupt): Rename from
18613 linux_send_signal, and always send SIGINT.
18614 * spu-low.c (spu_request_interrupt): Rename from spu_send_signal,
18615 and always send SIGINT.
18616 * remote-utils.c (putpkt_binary): Call request_interrupt, instead
18617 of send_signal.
18618 (input_interrupt): Likewise.
18619
820f2bda
PA
186202007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
18621
18622 * server.c (get_features_xml): Check if target implemented
18623 arch_string.
18624 * win32-i386-low.c (win32_arch_string): New.
18625 (win32_target_ops): Add win32_arch_string as arch_string member.
18626
ab39bf24
UW
186272007-02-22 Markus Deuling <deuling@de.ibm.com>
18628
18629 * spu-low.c (spu_arch_string): New.
18630 (spu_target_ops): Add spu_arch_string.
18631
61ff6e04
DJ
186322007-02-16 Daniel Jacobowitz <dan@codesourcery.com>
18633
18634 * remote-utils.c: Remove HAVE_TERMINAL_H check.
18635 * configure.ac: Do not check for terminal.h.
18636 * configure, config.in: Regenerated.
18637
fb1e4ffc
DJ
186382007-02-08 Daniel Jacobowitz <dan@codesourcery.com>
18639
18640 * Makefile.in (OBS): Add $(XML_BUILTIN).
18641 (XML_DIR, XML_TARGET, XML_FILES, XML_BUILTIN): New.
18642 (clean): Update.
18643 (target.xml, xml-builtin.c, stamp-xml, arm-with-iwmmxt.o)
18644 (arm-with-iwmmxt.c): New.
18645 * config.in, configure: Regenerate.
18646 * configure.ac: Check for iWMMXt. Handle srv_xmltarget,
18647 srv_xmlbuiltin, and srv_xmlfiles. Define USE_XML.
18648 * configure.srv: Mention srv_xmltarget and srv_xmlfiles.
18649 (arm*-*-linux*): Add iWMMXt and regset support.
18650 * linux-arm-low.c (PTRACE_GETWMMXREGS, PTRACE_SETWMMXREGS): Define.
18651 (arm_fill_gregset, arm_store_gregset, arm_fill_wmmxregset)
18652 (arm_store_wmmxregset, target_regsets): New.
18653 * server.c (get_features_xml): Take annex argument. Check builtin
18654 XML documents.
18655 (handle_query): Handle multiple annexes.
18656
0f48aa01
DJ
186572007-01-29 Daniel Jacobowitz <dan@codesourcery.com>
18658
18659 * remote-utils.c [USE_WIN32API] (read, write): Define.
18660 (putpkt_binary, input_interrupt, readchar, getpkt): Use read and
18661 write.
18662
23181151
DJ
186632007-01-09 Daniel Jacobowitz <dan@codesourcery.com>
18664
18665 * linux-i386-low.c (the_low_target): Set arch_string.
18666 * linux-x86-64-low.c (the_low_target): Likewise.
18667 * linux-low.c (linux_arch_string): New.
18668 (linux_target_ops): Add it.
18669 * linux-low.h (struct linux_target_ops): Add arch_string.
18670 * server.c (write_qxfer_response): Use const void * for DATA.
18671 (get_features_xml): New.
18672 (handle_query): Handle qXfer:features:read. Report it for qSupported.
18673 * target.h (struct target_ops): Add arch_string method.
18674
9d606399
DJ
186752007-01-03 Denis Pilat <denis.pilat@st.com>
18676 Daniel Jacobowitz <dan@codesourcery.com>
18677
18678 * linux-low.c (linux_kill): Handle being called with no threads.
18679 * win32-i386-low.c (win32_kill): Likewise.
18680 (get_child_debug_event): Clear current_process_handle.
18681
186822006-12-30 Denis PILAT <denis.pilat@st.com>
8264bb58
DJ
18683 Daniel Jacobowitz <dan@codesourcery.com>
18684
18685 * remote-utils.c (remote_open): Check the type of specified
18686 serial port devices before opening them.
18687 * server.c (main): Kill the inferior if an error occurs during
18688 the first remote_open.
18689
a5e13d24
DJ
186902006-12-05 Markus Deuling <deuling@de.ibm.com>
18691
18692 * README: Update supported targets.
18693
186947f7
DJ
186942006-11-28 Daniel Jacobowitz <dan@codesourcery.com>
18695
18696 * Makefile.in (clean): Remove reg-mips64.c.
18697 (reg-mips64.c, reg-mips64.o): New rules.
18698 * configure.srv: Handle mips64. Include regset support for mips.
18699 * linux-mips-low.c (union mips_register): New.
18700 (mips_get_pc, mips_set_pc, mips_reinsert_addr): Use it.
18701 (mips_breakpoint, mips_breakpoint_at): Use int.
18702 (mips_collect_register, mips_supply_register)
18703 (mips_collect_register_32bit, mips_supply_register_32bit)
18704 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
18705 (mips_store_fpregset, target_regsets): New.
18706 * thread-db.c (thread_db_get_tls_address): Use uintptr_t.
18707
a13e2c95
UW
187082006-11-22 Ulrich Weigand <uweigand@de.ibm.com>
18709
18710 * configure.srv: Add target "spu*-*-*".
18711 * Makefile.in (clean): Remove reg-spu.c.
18712 (reg-spu.c, reg-spu.o, spu-low.o): Add dependencies.
18713 * spu-low.c: New file.
18714
cb7283db
DJ
187152006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
18716
18717 * configure.ac: Correct td_thr_tls_get_addr test.
18718 * configure: Regenerated.
18719
89be2091
DJ
187202006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
18721
18722 * linux-low.c (linux_wait_for_event): Reformat. Use the
18723 pass_signals array.
18724 * remote-utils.c (decode_address_to_semicolon): New.
18725 * server.c (pass_signals, handle_general_set): New.
18726 (handle_query): Mention QPassSignals for qSupported.
18727 (main): Call handle_general_set.
18728 * server.h (pass_signals, decode_address_to_semicolon): New.
18729
000ef4f0
DJ
187302006-11-06 Daniel Jacobowitz <dan@codesourcery.com>
18731
18732 * server.c (handle_query): Correct error handling for read_auxv.
18733
b7149293
UW
187342005-10-19 Ulrich Weigand <uweigand@de.ibm.com>
18735
18736 * configure.srv [s390-*-linux*, s390x-*-linux*]: Set srv_linux_regsets
18737 and srv_linux_thread_db to yes.
18738 * linux-s390-low.c (s390_fill_gregset): New function.
18739 (target_regsets): Define data structure.
18740
dae5f5cf
DJ
187412006-10-17 Daniel Jacobowitz <dan@codesourcery.com>
18742
18743 * acinclude.m4 (SRV_CHECK_TLS_GET_ADDR): New.
18744 * configure.ac: Use it. Define HAVE_TD_THR_TLS_GET_ADDR.
18745 * config.in, configure: Regenerated.
18746 * inferiors.c (gdb_id_to_thread): New function.
18747 (gdb_id_to_thread_id): Use it.
18748 * linux-low.c (linux_target_ops): Use thread_db_get_tls_address.
18749 * linux-low.h (struct process_info): Add th member.
18750 (thread_db_get_tls_address): New prototype.
18751 * remote-utils.c (decode_address): Make non-static.
18752 * server.c (handle_query): Handle qGetTLSAddr.
18753 * server.h (gdb_id_to_thread, decode_address): New prototypes.
18754 * target.h (struct target_ops): Add get_tls_address.
18755 * thread-db.c (maybe_attach_thread): Save the thread handle.
18756 (thread_db_get_tls_address): New.
18757
32ca6d61
DJ
187582006-09-28 Daniel Jacobowitz <dan@codesourcery.com>
18759
18760 * linux-low.c (PTRACE_GETSIGINFO, PTRACE_SETSIGINFO): Define.
18761 (linux_resume_one_process): Take a siginfo_t *. Update all
18762 callers. Queue it if necessary. Use PTRACE_SETSIGINFO.
18763 (struct pending_signals): Add a siginfo_t.
18764 (linux_wait_for_process): Always set last_status.
18765 (linux_wait_for_event): Use PTRACE_GETSIGINFO.
18766 (linux_queue_one_thread): Use PTRACE_GETSIGINFO.
18767 * linux-low.h (struct process_info): Add last_status.
18768
5ffff7c1
DJ
187692006-09-21 Daniel Jacobowitz <dan@codesourcery.com>
18770
18771 * remote-utils.c (try_rle): New function.
18772 (putpkt_binary): Use it.
18773
8695c747
DJ
187742006-08-19 Daniel Jacobowitz <dan@codesourcery.com>
18775
18776 * Makefile.in (clean): Clean reg-x86-64-linux.c.
18777 (reg-x86-64-linux.o, reg-x86-64-linux.c): New.
18778 * configure.srv (x86_64-*-linux*): Use reg-x86-64-linux.o.
18779 * linux-x86-64-low.c (x86_64_regmap): Include ORIG_RAX.
18780 (x86_64_fill_gregset, x86_64_store_gregset): Skip floating
18781 point registers.
18782
290fadea
RS
187832006-08-08 Richard Sandiford <richard@codesourcery.com>
18784
18785 * server.c (terminal_fd): New variable.
18786 (old_foreground_pgrp): Likewise.
18787 (restore_old_foreground_pgrp): New function.
18788 (start_inferior): Record the terminal file descriptor in terminal_fd
18789 and its original foreground group in old_foreground_pgrp. Register
18790 restore_old_foreground_pgrp with atexit().
18791
9f2e1e63
DJ
187922006-07-26 Daniel Jacobowitz <dan@codesourcery.com>
18793
18794 * server.c (handle_query): Correct qPart to qXfer.
18795
b80864fb
DJ
187962006-07-22 Daniel Jacobowitz <dan@codesourcery.com>
18797
18798 * configure.ac: Check for more headers which are missing on
18799 Windows. Automatically supply -lwsock32 and USE_WIN32API.
18800 * configure.srv: Add Cygwin and mingw32.
18801 * remote-utils.c: Don't include headers unconditionally which
18802 are missing on mingw32. Include <winsock.h> for mingw32.
18803 (remote_open): Adjust for mingw32 support. Flush
18804 standard error after writing to it.
18805 (remote_close, putpkt_binary, input_interrupt, block_async_io)
18806 (unblock_async_io, enable_async_io, disable_async_io)
18807 (readchar, getpkt): Update for Winsock support.
18808 (prepare_resume_reply): Expect a protocol signal number.
18809 * server.c: Disable <sys/wait.h> on mingw32.
18810 (start_inferior): Adjust for mingw32 support. Flush
18811 standard error after writing to it.
18812 (attach_inferior): Likewise. Use protocol signal
18813 numbers.
18814 (main): Skip 'D' packet on mingw32. Use protocol signal numbers
18815 and names.
18816 * win32-i386-low.c: New file.
18817 * Makefile.in (XM_CLIBS): Set.
18818 (gdbserver, gdbreplay): Use $(INTERNAL_CFLAGS).
18819 (win32-i386-low.o): New dependency rule.
18820 * linux-low.c (linux_wait): Use target signal numbers.
18821 * target.h (struct target_ops): Doc fix.
18822 * server.h (target_signal_to_name): New prototype.
18823 * gdbreplay.c: Don't include headers unconditionally which
18824 are missing on mingw32. Include <winsock.h> for mingw32.
18825 (remote_close, remote_open): Adjust for Winsock support.
18826 * configure, config.in: Regenerated.
18827
0876f84a
DJ
188282006-07-12 Daniel Jacobowitz <dan@codesourcery.com>
18829
18830 * server.c (decode_xfer_read, write_qxfer_response): New.
18831 (handle_query): Take a packet length argument. Handle
18832 qXfer:auxv:read instead of qPart:auxv:read. Mention it in
18833 the qSupported response.
18834 (main): Update call to handle_query.
18835
01f9e8fa
DJ
188362006-06-22 Daniel Jacobowitz <dan@codesourcery.com>
18837
18838 * remote-utils.c (remote_escape_output, remote_unescape_input): New.
18839 (putpkt_binary): Renamed from putpkt and adjusted for binary
18840 data.
18841 (putpkt): New wrapper for putpkt_binary.
18842 (readchar): Don't mask off the high bit.
18843 (decode_X_packet): New function.
18844 * server.c (main): Call putpkt_binary if a handler sets the packet
18845 length. Save the length of the incoming packet. Handle 'X'.
18846 * server.h (gdb_byte, remote_escape_output, decode_X_packet): New.
18847
be2a5f71
DJ
188482006-06-21 Daniel Jacobowitz <dan@codesourcery.com>
18849
18850 * server.c (handle_query): Handle qSupported.
18851
ea025f5f
DJ
188522006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
18853
18854 * remote-utils.c (all_symbols_looked_up): New variable.
18855 (look_up_one_symbol): Check it.
18856 * server.h (look_up_one_symbol): New declaration.
18857 * thread-db.c (thread_db_init): Set all_symbols_looked_up.
18858
9308fc88
DJ
188592006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
18860
18861 * Makefile.in (linux-arm-low.o): Update dependencies.
66f338c7 18862 * linux-arm-low.c: Include "gdb_proc_service.h".
9308fc88
DJ
18863 (PTRACE_GET_THREAD_AREA): Define.
18864 (ps_get_thread_area): New function.
18865
52fb6437
NS
188662006-05-09 Nathan Sidwell <nathan@codesourcery.com>
18867
18868 * configure.srv (m68k*-*-uclinux*): New target.
18869 * linux-low.c (linux_create_inferior): Use vfork on mmuless systems.
18870 (linux_resume_one_process): Remove extraneous cast.
18871 (linux_read_offsets): New.
18872 (linux_target_op): Add linux_read_offsets on mmuless systems.
18873 * server.c (handle_query): Add qOffsets logic.
18874 * target.h (struct target_ops): Add read_offsets.
18875
21b0f40c
DJ
188762006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
18877
18878 * linux-mips-low.c: Include <sys/ptrace.h> and "gdb_proc_service.h".
18879 (PTRACE_GET_THREAD_AREA): Define.
18880 (ps_get_thread_area): New function.
18881 * Makefile.in (linux-i386-low.o, linux-mips-low.o)
18882 (linux-x86-64-low.o): Update.
18883
0050a760
DJ
188842006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
18885
18886 * configure.ac: Remove checks for prfpregset_t.
18887 * gdb_proc_service.h: New file.
18888 * linux-i386-low.c, linux-x86-64-low.c, thread-db.c: Use the
18889 new "gdb_proc_service.h".
18890 * proc-service.c: Likewise.
18891 (ps_pglobal_lookup, ps_pdread, ps_pdwrite): Use psaddr_t.
18892 (ps_lgetfpregs, ps_lsetfpregs): Use a void* argument.
18893 * Makefile.in (gdb_proc_service_h): Updated.
18894 * configure, config.in: Regenerated.
18895
b92a518e
DJ
188962006-03-03 Daniel Jacobowitz <dan@codesourcery.com>
18897
18898 * remote-utils.c (prepare_resume_reply): Move declaration
18899 of gdb_id_from_wait to the top of the block.
18900
545587ee
DJ
189012006-02-15 Daniel Jacobowitz <dan@codesourcery.com>
18902
18903 * linux-low.c (regsets_store_inferior_registers): Read the regset
18904 from the target before filling it.
18905
9db87ebd
DJ
189062006-02-08 Daniel Jacobowitz <dan@codesourcery.com>
18907
18908 * server.c (attach_inferior): Return SIGTRAP for a successful
18909 attach.
18910
dd24457d
DJ
189112006-02-01 Daniel Jacobowitz <dan@codesourcery.com>
18912
18913 * Makefile.in (OBS): Add version.o.
18914 (STAGESTUFF): Delete.
18915 (version.o): Add dependencies.
18916 (version.c): Replace rule.
18917 (clean): Remove version.c.
18918 * server.c (gdbserver_version): New.
18919 (gdbserver_usage): Use printf.
18920 (main): Handle --version and --help.
18921 * server.h (version, host_name): Add declarations.
18922
6f0f660e
EZ
189232005-12-23 Eli Zaretskii <eliz@gnu.org>
18924
889bf7c5
PA
18925 * linux-arm-low.c:
18926 * linux-arm-low.c:
18927 * inferiors.c:
18928 * i387-fp.h:
18929 * i387-fp.c:
18930 * gdbreplay.c:
18931 * regcache.c:
18932 * proc-service.c:
18933 * mem-break.h:
18934 * mem-break.c:
18935 * linux-x86-64-low.c:
18936 * linux-sh-low.c:
18937 * linux-s390-low.c:
18938 * linux-ppc64-low.c:
18939 * linux-ppc-low.c:
18940 * linux-mips-low.c:
18941 * linux-m68k-low.c:
18942 * linux-m32r-low.c:
18943 * linux-low.h:
18944 * linux-low.c:
18945 * linux-ia64-low.c:
18946 * linux-i386-low.c:
18947 * linux-crisv32-low.c:
18948 * thread-db.c:
18949 * terminal.h:
18950 * target.h:
18951 * target.c:
18952 * server.h:
18953 * server.c:
18954 * remote-utils.c:
18955 * regcache.h:
18956 * utils.c:
18957 * Makefile.in:
18958 * configure.ac:
6f0f660e
EZ
18959 * gdbserver.1: Add (C) after Copyright. Update the FSF
18960 address.
18961
9d1fb177
DJ
189622005-11-13 Daniel Jacobowitz <dan@codesourcery.com>
18963
18964 * linux-arm-low.c (arm_eabi_breakpoint): New variable.
18965 (arm_breakpoint_at): Recognize both breakpoints.
18966 (the_low_target): Use the correct breakpoint instruction.
18967
011a70c2
DJ
189682005-11-02 Daniel Jacobowitz <dan@codesourcery.com>
18969
18970 * configure.srv (x86_64-*-linux*): Turn on thread_db support.
18971 * linux-x86-64-low.c (x86_64_breakpoint, x86_64_breakpoint_len)
18972 (x86_64_get_pc, x86_64_set_pc, x86_64_breakpoint_at): New.
18973 (the_low_target): Update.
18974
7fb85e41
AS
189752005-10-25 Andreas Schwab <schwab@suse.de>
18976
18977 * server.c (main): Allocate mem_buf with PBUFSIZ bytes.
18978
18979 * linux-ia64-low.c (ia64_regmap): Remove NAT registers.
18980 (ia64_num_regs): Reduce to 462.
18981
3db0444b
DJ
189822005-09-17 Daniel Jacobowitz <dan@codesourcery.com>
18983
18984 * acinclude.m4: Correct quoting.
18985 * aclocal.m4: Regenerated.
18986
18987 Suggested by SZOKOVACS Robert <szo@ies.hu>:
18988 * thread-db.c (thread_db_err_str): Handle TD_VERSION.
18989 (thread_db_init): Call thread_db_err_str.
18990 * configure.ac: Check for TD_VERSION.
18991 * config.in, configure: Regenerated.
18992
bee0189a
DJ
189932005-07-31 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
18994
18995 * server.h (error, fatal, warning): Add ATTR_FORMAT.
18996
e9d25b98
DJ
189972005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
18998
18999 * configure.ac: Define HAVE_LINUX_REGSETS even if PTRACE_GETREGS
19000 is not available. Define HAVE_PTRACE_GETREGS if it is.
19001 * config.in, configure: Regenerated.
19002 * configure.srv: Set srv_linux_regsets for PowerPC and PowerPC64.
19003 * linux-i386-low.c, linux-m68k-low.c: Update to use
19004 HAVE_PTRACE_GETREGS.
19005 * linux-low.c (regsets_fetch_inferior_registers)
19006 (regsets_store_inferior_registers): Only return 0 if we processed
19007 GENERAL_REGS.
19008 * linux-ppc-low.c (ppc_fill_gregset, target_regsets): New.
19009 * linux-ppc64-low.c (ppc_fill_gregset, target_regsets): New.
19010
a06660f7
DJ
190112005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
19012
19013 * inferiors.c (struct thread_info): Add gdb_id.
19014 (add_thread): Add gdb_id argument.
19015 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New.
19016 * linux-low.c (linux_create_inferior, linux_attach_lwp): Update
19017 calls to add_thread.
19018 * remote-utils.c (prepare_resume_reply: Use thread_to_gdb_id.
19019 * server.c (handle_query): Use thread_to_gdb_id.
19020 (handle_v_cont, main): Use gdb_id_to_thread_id.
19021 * server.h (add_thread): Update prototype.
19022 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New
19023 prototypes.
19024
5a1f5858
DJ
190252005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
19026
19027 * linux-low.c (fetch_register, usr_store_inferior_registers): Handle
19028 left-padded registers.
19029 * linux-low.h (struct linux_target_ops): Add left_pad_xfer.
19030 * linux-ppc64-low.c (the_low_target): Set left_pad_xfer.
19031
e122f1f5
SE
190322005-07-01 Steve Ellcey <sje@cup.hp.com>
19033
19034 * configure.ac (BFD_NEED_DECLARATION): Replace with AC_CHECK_DECLS.
19035 * configure: Regenerate.
19036 * config.in: Regenerate.
19037 * server.h (NEED_DECLARATION_STRERROR):
19038 Replace with !HAVE_DECL_STRERROR.
19039
d592fa2f
DJ
190402005-06-16 Daniel Jacobowitz <dan@codesourcery.com>
19041
19042 * linux-low.c (linux_wait, linux_send_signal): Don't test
19043 an unsigned long variable for > 0 if it could be MAX_ULONG.
19044 * server.c (myresume): Likewise.
19045 * target.c (set_desired_inferior): Likewise.
19046
ccbd4912
MK
190472005-06-13 Mark Kettenis <kettenis@gnu.org>
19048
19049 * configure.ac: Simplify and improve check for socklen_t.
19050 * configure, config.in: Regenerate.
19051
f450004a
DJ
190522005-06-12 Daniel Jacobowitz <dan@codesourcery.com>
19053
19054 * acconfig.h: Remove.
19055 * configure.ac: Add a test for socklen_t. Use three-argument
19056 AC_DEFINE throughout.
19057 * config.in: Regenerated using autoheader 2.59.
19058 * configure: Regenerated.
19059
19060 * gdbreplay.c (socklen_t): Provide a default.
19061 (remote_open): Use socklen_t.
19062 * remote-utils.c (socklen_t): Provide a default.
19063 (remote_open): Use socklen_t.
19064 (convert_int_to_ascii, convert_ascii_to_int, decode_M_packet): Use
19065 unsigned char.
19066
19067 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Use unsigned
19068 char for buffers.
19069 * linux-low.c (linux_read_memory, linux_write_memory)
19070 (linux_read_auxv): Likewise.
19071 * mem-break.c (breakpoint_data, set_breakpoint_data, check_mem_read)
19072 (check_mem_write): Likewise.
19073 * mem-break.h (set_breakpoint_data, check_mem_read, check_mem_write):
19074 Likewise.
19075 * regcache.c (struct inferior_rgcache_data, registers_to_string)
19076 (registers_from_string, register_data): Likewise.
19077 * server.c (handle_query, main): Likewise.
19078 * server.h (convert_ascii_to_int, convert_int_to_ascii)
19079 (decode_M_packet): Likewise.
19080 * target.c (read_inferior_memory, write_inferior_memory): Likewise.
19081 * target.h (struct target_ops): Update read_memory, write_memory,
19082 and read_auxv.
19083 (read_inferior_memory, write_inferior_memory): Update.
19084 * linux-low.h (struct linux_target_ops): Change type of breakpoint
19085 to unsigned char *.
19086 * linux-arm-low.c, linux-cris-low.c, linux-crisv32-low.c,
19087 linux-i386-low.c, linux-m32r-low.c, linux-m68k-low.c,
19088 linux-mips-low.c, linux-ppc-low.c, linux-ppc64-low.c,
19089 linux-s390-low.c, linux-sh-low.c: Update for changes in
19090 read_inferior_memory and the_low_target->breakpoint.
19091
eee84df1
DJ
190922005-05-28 Daniel Jacobowitz <dan@codesourcery.com>
19093
19094 * Makefile.in (SFILES): Add linux-ppc64-low.c.
19095 (linux-ppc64-low.o, reg-ppc64.c, reg-ppc64.o): New targets.
19096 * configure.srv: Add powerpc64-*-linux*.
19097 * linux-ppc64-low.c: New file.
19098
45b134e5
OF
190992005-05-23 Orjan Friberg <orjanf@axis.com>
19100
19101 * linux-cris-low.c: New file with support for CRIS.
19102 * linux-crisv32-low.c: Ditto for CRISv32.
19103 * Makefile.in (SFILES): Add linux-cris-low.c, linux-crisv32-low.c.
19104 (clean): Add reg-cris.c and reg-crisv32.c.
889bf7c5 19105 Add linux-cris-low.o, linux-crisv32-low.o, reg-cris.o, reg-cris.c,
45b134e5
OF
19106 reg-crisv32.o, and reg-crisv32.c to make rules.
19107 * configure.srv: Add cris-*-linux* and crisv32-*-linux* to list of
19108 recognized targets.
19109
48d93c75
UW
191102005-05-16 Ulrich Weigand <uweigand@de.ibm.com>
19111
19112 * linux-low.c (fetch_register): Ensure buffer size is a multiple
19113 of sizeof (PTRACE_XFER_TYPE).
19114 (usr_store_inferior_registers): Likewise. Zero out excess bytes.
19115
e013ee27
OF
191162005-05-12 Orjan Friberg <orjanf@axis.com>
19117
889bf7c5 19118 * target.h (struct target_ops): Add insert_watchpoint,
e013ee27
OF
19119 remove_watchpoint, stopped_by_watchpoint, stopped_data_address function
19120 pointers for hardware watchpoint support.
19121 * linux-low.h (struct linux_target_ops): Ditto.
19122 * linux-low.c (linux_insert_watchpoint, linux_remove_watchpoint)
19123 (linux_stopped_by_watchpoint, linux_stopped_data_address): New. Add
19124 to linux_target_ops.
19125 * remote-utils.c (prepare_resume_reply): Add watchpoint information to
19126 reply packet.
19127 * server.c (main): Recognize 'Z' and 'z' packets.
19128
b0ded00b
UW
191292005-05-10 Ulrich Weigand <uweigand@de.ibm.com>
19130
19131 * linux-s390-low.c (s390_breakpoint, s390_breakpoint_len): Define.
19132 (s390_get_pc, s390_set_pc, s390_breakpoint_at): New functions.
19133 (the_low_target): Add new members.
19134
8643e2ad
DJ
191352005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
19136
19137 * proc-service.c (ps_lgetregs): Search all_processes instead of
19138 all_threads.
19139
fc620387
DJ
191402005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
19141
19142 * server.c (start_inferior): Change return type to int.
19143 (attach_inferior): Change sigptr to int *.
19144 (handle_v_cont, handle_v_requests): Change signal to int *.
19145 (main): Change signal to int.
19146
191472005-04-15 Kei Sakamoto <sakamoto.kei@renesas.com>
7cfbc4a0
KI
19148
19149 * Makefile.in: Add linux-m32r-low.o, reg-m32r.c and reg-m32r.o.
19150 * configure.srv: Add m32r*-*-linux*.
19151 * linux-m32r-low.c: New file.
19152
e0e76420
DJ
191532005-03-04 Daniel Jacobowitz <dan@codesourcery.com>
19154
19155 * Makefile.in (stamp-h): Set CONFIG_HEADERS explicitly.
19156
a1928bad
DJ
191572005-03-03 Daniel Jacobowitz <dan@codesourcery.com>
19158
19159 * inferiors.c (change_inferior_id, add_thread, find_inferior_id):
19160 Take unsigned long arguments for PIDs.
19161 * linux-low.c (add_process, linux_attach_lwp, linux_attach)
19162 (linux_thread_alive, linux_wait_for_event, kill_lwp, send_sigstop)
19163 (wait_for_sigstop, linux_resume_one_process)
19164 (regsets_fetch_inferior_registers, linux_send_signal)
19165 (linux_read_auxv): Likewise. Update the types of variables holding
19166 PIDs. Update format string specifiers.
19167 * linux-low.h (struct process_info, linux_attach_lwp): Likewise.
19168 * remote-utils.c (prepare_resume_reply): Likewise.
19169 * server.c (cont_thread, general_thread, step_thread)
19170 (thread_from_wait, old_thread_from_wait, signal_pid): Change type to
19171 unsigned long.
19172 (handle_query): Update format specifiers.
19173 (handle_v_cont, main): Use strtoul for thread IDs.
19174 * server.h (struct inferior_list_entry): Use unsigned long for ID.
19175 (add_thread, find_inferior_id, change_inferior_id, cont_thread)
19176 (general_thread, step_thread, thread_from_wait)
19177 (old_thread_from_wait): Update.
19178 * target.h (struct thread_resume): Use unsigned long for THREAD.
19179 (struct target_ops): Use unsigned long for arguments to attach and
19180 thread_alive.
19181
dcdb98d2
DJ
191822005-02-24 Daniel Jacobowitz <dan@codesourcery.com>
19183
19184 * acinclude.m4: Include bfd/bfd.m4 directly.
19185 * configure.ac: Use AC_ARG_PROGRAM. Suggested by Aron Griffis
19186 <agriffis@toolchain.org>.
19187 * aclocal.m4, configure: Regenerated.
19188
bec39cab
AC
191892005-01-07 Andrew Cagney <cagney@gnu.org>
19190
19191 * configure.ac: Rename configure.in, require autoconf 2.59.
19192 * configure: Re-generate.
19193
434c4c77
DJ
191942004-12-08 Daniel Jacobowitz <dan@debian.org>
19195
19196 * acinclude.m4 (SRV_CHECK_THREAD_DB): Add ps_get_thread_area. Reset
19197 LIBS when finished.
19198 * aclocal.m4: Regenerated.
19199 * configure: Regenerated.
19200
db1d3e1b
AS
192012004-11-21 Andreas Schwab <schwab@suse.de>
19202
19203 * linux-m68k-low.c (m68k_num_gregs): Define.
19204 (m68k_fill_gregset, m68k_store_gregset, m68k_fill_fpregset)
19205 (m68k_store_fpregset, target_regsets) [HAVE_LINUX_REGSETS]: New.
19206 (m68k_breakpoint, m68k_breakpoint_len, m68k_get_pc, m68k_set_pc)
19207 (m68k_breakpoint_at): New. Add to the_low_target.
19208
19209 * configure.srv (m68*-*-linux*): Set srv_linux_regsets and
19210 srv_linux_thread_db to yes.
19211
43360365
JB
192122004-10-20 Joel Brobecker <brobecker@gnat.com>
19213
19214 * linux-x86-64-low.c (ARCH_SET_GS): Add definition if missing.
19215 (ARCH_SET_FS): Likewise.
19216 (ARCH_GET_FS): Likewise.
19217 (ARCH_GET_GS): Likewise.
19218
fd500816
DJ
192192004-10-16 Daniel Jacobowitz <dan@debian.org>
19220
19221 * linux-i386-low.c (ps_get_thread_area): New.
19222 * linux-x86-64-low.c (ps_get_thread_area): New.
19223 * linux-low.c: Include <sys/syscall.h>.
19224 (linux_kill_one_process): Don't kill the first thread here.
19225 (linux_kill): Kill the first thread here.
19226 (kill_lwp): New function.
19227 (send_sigstop, linux_send_signal): Use it.
19228 * proc-service.c: Clean up #ifdefs.
19229 (fpregset_info): Delete.
19230 (ps_lgetregs): Update and enable implementation.
19231 (ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs): Remove disabled
19232 implementations.
19233 * remote-utils.c (struct sym_cache, symbol_cache): New.
19234 (input_interrupt): Print a clearer message.
19235 (async_io_enabled): New variable.
19236 (enable_async_io, disable_async_io): Use it. Update comments.
19237 (look_up_one_symbol): Use the symbol cache.
19238 * thread-db.c (thread_db_look_up_symbols): New function.
19239 (thread_db_init): Update comments. Call thread_db_look_up_symbols.
19240
f6de3c42
DJ
192412004-10-16 Daniel Jacobowitz <dan@debian.org>
19242
19243 * configure.in: Test for -rdynamic.
19244 * configure: Regenerated.
19245 * Makefile (INTERNAL_LDFLAGS): New.
19246 (gdbserver, gdbreplay): Use it.
19247
2c0fc042
AC
192482004-09-02 Andrew Cagney <cagney@gnu.org>
19249
19250 * Makefile.in (TAGS): Replace TM_FILE with DEPRECATED_TM_FILE.
19251
075b3282
DJ
192522004-03-23 Daniel Jacobowitz <drow@mvista.com>
19253
19254 * linux-low.c (linux_wait): Clear all_processes list also.
19255
fa6a77dc
DJ
192562004-03-12 Daniel Jacobowitz <drow@mvista.com>
19257
19258 * linux-low.c: Include <errno.h>. Remove extern declaration of
19259 errno.
19260
6d782a97
DJ
192612004-03-12 Daniel Jacobowitz <drow@mvista.com>
19262
19263 * gdbreplay.c, server.h, utils.c: Update copyright years.
19264
3a7fb99b
DJ
192652004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
19266
19267 * server.c (main): Print child status or termination signal from
19268 variable 'signal', not 'sig'.
19269
c3e735a6
DJ
192702004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
19271
19272 * linux-low.c (linux_read_memory): Change return type to
19273 int. Check for and return error from ptrace().
19274 * target.c (read_inferior_memory): Change return type to int. Pass
19275 back return status from the_target->read_memory().
19276 * target.h (struct target_ops): Adapt *read_memory() prototype.
19277 Update comment.
19278 (read_inferior_memory): Adapt prototype.
19279 * server.c (main): Return an error packet if
19280 read_inferior_memory() returns an error.
19281
a59d1c82
DJ
192822004-03-04 Daniel Jacobowitz <drow@mvista.com>
19283
19284 * Makefile.in (distclean): Remove config.h, stamp-h, and config.log.
19285 Unify with other clean targets.
19286
dc3f8883
DJ
192872004-02-29 Daniel Jacobowitz <drow@mvista.com>
19288
19289 * server.c (handle_v_cont): Call set_desired_inferior.
19290
89a208da
DJ
192912004-02-29 Daniel Jacobowitz <drow@mvista.com>
19292
19293 * remote-utils.c (prepare_resume_reply): Always supply "thread:".
19294
62ea82f5
DJ
192952004-02-29 Daniel Jacobowitz <drow@mvista.com>
19296
19297 * linux-low.c (linux_wait): Unblock async I/O.
19298 (linux_resume): Block and enable async I/O.
19299 * remote-utils.c (block_async_io, unblock_async_io): New functions.
19300 * server.h (block_async_io, unblock_async_io): Add prototypes.
19301
6910d122
DJ
193022004-02-29 Daniel Jacobowitz <drow@mvista.com>
19303
19304 * remote-utils.c (remote_open): Print a status notice after
19305 opening a TCP port.
19306 * server.c (attach_inferior): Print a status notice after
19307 attaching.
19308
193092004-02-29 Daniel Jacobowitz <drow@mvista.com>
d677d77d
DJ
19310
19311 * linux-arm-low.c (arm_get_pc): Print out stop PC in debug mode.
19312
c89dc5d4
DJ
193132004-02-26 Daniel Jacobowitz <drow@mvista.com>
19314
19315 * remote-utils.c (write_enn): Use "E01" instead of "ENN" for the
19316 error packet.
19317 * server.c, target.h: Update copyright years.
19318
4b8dad4a
RM
193192004-02-25 Roland McGrath <roland@redhat.com>
19320
19321 * target.h (struct target_ops): New member `read_auxv'.
19322 * server.c (handle_query): Handle qPart:auxv:read: query using that.
19323 * linux-low.c (linux_read_auxv): New function.
19324 (linux_target_ops): Initialize `read_auxv' member to that.
19325
d7446758
JB
193262004-02-17 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
19327
19328 Committed by Jim Blandy <jimb@redhat.com>.
19329
19330 * linux-s390-low.c (s390_num_regs): Update.
4b8dad4a 19331 (s390_regmap): Remove control registers. Use __s390x__ predefine
d7446758
JB
19332 instead of GPR_SIZE to distiguish s390 and s390x targets.
19333
5544ad89
DJ
193342004-01-31 Daniel Jacobowitz <drow@mvista.com>
19335
19336 * linux-low.c: Update copyright year.
19337 (check_removed_breakpoint): Clear pending_is_breakpoint.
19338 (linux_set_resume_request, linux_queue_one_thread)
19339 (resume_status_pending_p): New functions.
19340 (linux_continue_one_thread): Use process->resume.
19341 (linux_resume): Only resume threads if there are no pending events.
19342 * linux-low.h (struct process_info): Add resume request
19343 pointer.
19344
2a68b70e
DJ
193452004-01-30 Daniel Jacobowitz <drow@mvista.com>
19346
19347 * regcache.c (new_register_cache): Clear the allocated register
19348 buffer. Suggested by Atsushi Nemoto <anemo@mba.ocn.ne.jp>.
19349
64386c31
DJ
193502003-10-13 Daniel Jacobowitz <drow@mvista.com>
19351
19352 * linux-low.c (linux_resume): Take a struct thread_resume *
19353 argument.
19354 (linux_wait): Update call.
19355 (resume_ptr): New static variable.
19356 (linux_continue_one_thread): Renamed from
19357 linux_continue_one_process. Use resume_ptr.
19358 (linux_resume): Use linux_continue_one_thread.
19359 * server.c (handle_v_cont, handle_v_requests): New functions.
19360 (myresume): New function.
19361 (main): Handle 'v' case.
19362 * target.h (struct thread_resume): New type.
19363 (struct target_ops): Change argument of "resume" to struct
19364 thread_resume *.
19365 (myresume): Delete macro.
19366
c938e9b0
L
193672003-08-08 H.J. Lu <hongjiu.lu@intel.com>
19368
19369 * Makefile.in (install-only): Create dest dir. Support DESTDIR.
19370 (uninstall): Support DESTDIR.
19371
7f313d07
BC
19372Mon Jul 21 20:09:34 UTC 2003 Brendan Conoboy <blc@redhat.com>
19373
19374 * configure.srv: Add xscale*linux copy of arm*linux entry.
19375
3b2fc2ea
DJ
193762003-07-24 Daniel Jacobowitz <drow@mvista.com>
19377
19378 * linux-arm-low.c (arm_reinsert_addr): New function.
19379 (the_low_target): Add arm_reinsert_addr.
19380
1c0a559e
MK
193812003-07-08 Mark Kettenis <kettenis@gnu.org>
19382
19383 * mem-break.c: Remove whitespace at end of file.
19384
43d5792c
DJ
193852003-06-28 Daniel Jacobowitz <drow@mvista.com>
19386
19387 * configure.in: Check whether we need to prototype strerror.
19388 * server.h: Optionally prototype strerror.
19389 * gdbreplay.c (perror_with_name): Use strerror.
19390 * linux-low.c (linux_attach_lwp): Use strerror.
19391 * utils.c (perror_with_name): Use strerror.
19392 * config.in, configure: Regenerated.
19393
c8a86edf
DJ
193942003-06-28 Daniel Jacobowitz <drow@mvista.com>
19395
19396 * linux-sh-low.c (sh_regmap): Fix FP register offsets, reported by
19397 SUGIOKA Toshinobu <sugioka@itonet.co.jp>.
19398
73d37363
DJ
193992003-06-20 Daniel Jacobowitz <drow@mvista.com>
19400
19401 * Makefile.in (SFILES): Update.
19402 * low-hppabsd.c, low-lynx.c, low-nbsd.c, low-sim.c, low-sparc.c,
19403 low-sun3.c: Remove files.
19404
6ad8ae5c
DJ
194052003-06-17 Daniel Jacobowitz <drow@mvista.com>
19406
19407 * linux-low.c: Move comment to linux_thread_alive where it belonged.
19408 (linux_detach_one_process, linux_detach): New functions.
19409 (linux_target_ops): Add linux_detach.
19410 * server.c (main): Handle 'D' packet.
19411 * target.h (struct target_ops): Add "detach" member.
19412 (detach_inferior): Define.
19413
1581182a
MK
194142003-06-13 Mark Kettenis <kettenis@gnu.org>
19415
19416 From Kelley Cook <kelleycook@wideopenwest.com>:
19417 * configure.srv: Accept i[34567]86 variants.
19418
e5379b03
DJ
194192003-06-05 Daniel Jacobowitz <drow@mvista.com>
19420
19421 * linux-low.c (linux_wait_for_event): Correct comment typos.
19422 (linux_resume_one_process): Call check_removed_breakpoint.
19423 (linux_send_signal): New function.
19424 (linux_target_ops): Add linux_send_signal.
19425 * remote-utils.c (putpkt, input_interrupt): Use send_signal instead
19426 of kill.
19427 * target.h (struct target_ops): Add send_signal.
19428
2ff29de4
JB
194292003-05-29 Jim Blandy <jimb@redhat.com>
19430
19431 * linux-low.c (usr_store_inferior_registers): Transfer buf in
19432 PTRACE_XFER_TYPE-sized chunks, not int-sized chunks. Otherwise,
19433 if 'int' is smaller than PTRACE_XFER_TYPE, you end up throwing
19434 away part of the register's value.
19435
254787d4
DJ
194362003-03-26 Daniel Jacobowitz <drow@mvista.com>
19437
19438 * linux-low.c (linux_create_inferior): Use __SIGRTMIN.
19439 (linux_wait_for_event, linux_init_signals): Likewise.
19440
94e10508
DJ
194412003-03-17 Daniel Jacobowitz <drow@mvista.com>
19442
19443 * configure.in: Check for stdlib.h.
19444 * configure: Regenerated.
19445 * config.in: Regenerated.
19446
4c0711e0
DJ
194472003-01-04 Andreas Schwab <schwab@suse.de>
19448
19449 * linux-m68k-low.c (m68k_num_regs): Define to 29 instead of 31.
19450
ef66e766
AC
194512003-01-02 Andrew Cagney <ac131313@redhat.com>
19452
19453 * Makefile.in: Remove obsolete code.
19454
a1358604
DJ
194552002-11-20 Daniel Jacobowitz <drow@mvista.com>
19456
19457 * linux-s390-low.c (s390_regmap): Check GPR_SIZE instead of
19458 defined(PT_FPR0_HI).
19459
23ce3b1c
DJ
194602002-11-17 Stuart Hughes <seh@zee2.com>
19461
19462 * linux-arm-low.c (arm_num_regs): Increase.
19463 (arm_regmap): Include status register.
19464
194652002-11-17 Daniel Jacobowitz <drow@mvista.com>
19466
19467 * linux-low.c (register_addr): Remove incorrect -1 check.
19468
a9fa9f7d
DJ
194692002-08-29 Daniel Jacobowitz <drow@mvista.com>
19470
19471 * linux-low.c (linux_create_inferior): Call setpgid. Return
19472 the new PID.
19473 (unstopped_p, linux_signal_pid): Remove.
19474 (linux_target_ops): Remove linux_signal_pid.
19475 * remote-utils.c (putpkt, input_interrupt): Use signal_pid
19476 global instead of target method.
19477 * target.h (struct target_ops): Remove signal_pid. Update comment
19478 for create_inferior.
19479 * server.c (signal_pid): New variable.
19480 (create_inferior): Set signal_pid. Block SIGTTOU and SIGTTIN in
4b8dad4a 19481 gdbserver. Set the child to be the foreground process group.
a9fa9f7d
DJ
19482 (attach_inferior): Set signal_pid.
19483
17574093
DJ
194842002-08-23 Daniel Jacobowitz <drow@mvista.com>
19485
19486 * ChangeLog: New file, with entries from gdb/ChangeLog after GDB 5.2.
19487
194882002-08-20 Jim Blandy <jimb@redhat.com>
19489
19490 * Makefile.in (LDFLAGS): Allow the configure script to establish a
19491 default for this.
19492
194932002-08-01 Andrew Cagney <cagney@redhat.com>
19494
19495 * Makefile.in: Make chill references obsolete.
19496
194972002-07-24 Kevin Buettner <kevinb@redhat.com>
19498
19499 * configure.in (unistd.h): Add to AC_CHECK_HEADERS list.
19500 * configure: Regenerate.
19501 * config.in: Regenerate.
19502
195032002-07-09 David O'Brien <obrien@FreeBSD.org>
19504
19505 * gdbreplay.c (stdlib.h, unistd.h): Conditionaly include.
19506 (perror_with_name, remote_close, remote_open, expect, play): Static.
19507
195082002-07-04 Michal Ludvig <mludvig@suse.cz>
19509
4b8dad4a 19510 * linux-x86-64-low.c (x86_64_regmap): Make it an array of
17574093
DJ
19511 byte offsets instead of an array of indexes.
19512 (x86_64_store_gregset, x86_64_store_fpregset): Parameter made const.
19513
195142002-06-13 Daniel Jacobowitz <drow@mvista.com>
19515
19516 * regcache.c: Add comment.
19517
195182002-06-11 Daniel Jacobowitz <drow@mvista.com>
19519
19520 * thread-db.c: New file.
19521 * proc-service.c: New file.
19522 * acinclude.m4: New file.
19523 * Makefile.in: Add GDBSERVER_LIBS, gdb_proc_service_h,
19524 proc-service.o, and thread-db.o.
19525 (linux-low.o): Add USE_THREAD_DB.
19526 * acconfig.h: Add HAVE_PRGREGSET_T, HAVE_PRFPREGSET_T,
19527 HAVE_LWPID_T, HAVE_PSADDR_T, and PRFPREGSET_T_BROKEN.
19528 * aclocal.m4: Regenerated.
19529 * config.in: Regenerated.
19530 * configure: Regenerated.
19531 * configure.in: Check for proc_service.h, sys/procfs.h,
19532 thread_db.h, and linux/elf.h headrs.
19533 Check for lwpid_t, psaddr_t, prgregset_t, prfpregset_t, and
19534 PRFPREGSET_T_BROKEN. Introduce srv_thread_depfiles and USE_THREAD_DB.
19535 Check for -lthread_db and thread support.
19536 * configure.srv: Enable thread_db support for ARM, i386, MIPS,
19537 PowerPC, and SuperH.
19538 * i387-fp.c: Constify arguments.
19539 * i387-fp.h: Likewise.
19540 * inferiors.c: (struct thread_info): Renamed from
19541 `struct inferior_info'. Remove PID member. Use generic inferior
19542 list header. All uses updated.
19543 (inferiors, signal_pid): Removed.
19544 (all_threads): New variable.
19545 (get_thread): Define.
19546 (add_inferior_to_list): New function.
19547 (for_each_inferior): New function.
19548 (change_inferior_id): New function.
19549 (add_inferior): Removed.
19550 (remove_inferior): New function.
19551 (add_thread): New function.
19552 (free_one_thread): New function.
19553 (remove_thread): New function.
19554 (clear_inferiors): Use for_each_inferior and free_one_thread.
19555 (find_inferior): New function.
19556 (find_inferior_id): New function.
19557 (inferior_target_data): Update argument type.
19558 (set_inferior_target_data): Likewise.
19559 (inferior_regcache_data): Likewise.
19560 (set_inferior_regcache_data): Likewise.
19561 * linux-low.c (linux_bp_reinsert): Remove.
19562 (all_processes, stopping_threads, using_thrads)
19563 (struct pending_signals, debug_threads, pid_of): New.
19564 (inferior_pid): Replace with macro.
19565 (struct inferior_linux_data): Remove.
19566 (get_stop_pc, add_process): New functions.
19567 (linux_create_inferior): Restore SIGRTMIN+1 before calling exec.
19568 Use add_process and add_thread.
19569 (linux_attach_lwp): New function, based on old linux_attach. Use
19570 add_process and add_thread. Set stop_expected for new threads.
19571 (linux_attach): New function.
19572 (linux_kill_one_process): New function.
19573 (linux_kill): Kill all LWPs.
19574 (linux_thread_alive): Use find_inferior_id.
19575 (check_removed_breakpoints, status_pending_p): New functions.
19576 (linux_wait_for_process): Renamed from linux_wait_for_one_inferior.
19577 Update. Use WNOHANG. Wait for cloned processes also. Update process
19578 struct for the found process.
19579 (linux_wait_for_event): New function.
19580 (linux_wait): Use it. Support LWPs.
19581 (send_sigstop, wait_for_sigstop, stop_all_processes)
19582 (linux_resume_one_process, linux_continue_one_process): New functions.
19583 (linux_resume): Support LWPs.
19584 (REGISTER_RAW_SIZE): Remove.
19585 (fetch_register): Use register_size instead. Call supply_register.
19586 (usr_store_inferior_registers): Likewise. Call collect_register.
19587 Fix recursive case.
19588 (regsets_fetch_inferior_registers): Improve error message.
19589 (regsets_store_inferior_registers): Add debugging.
19590 (linux_look_up_symbols): Call thread_db_init if USE_THREAD_DB.
19591 (unstopped_p, linux_signal_pid): New functions.
19592 (linux_target_ops): Add linux_signal_pid.
19593 (linux_init_signals): New function.
19594 (initialize_low): Call it. Initialize using_threads.
19595 * regcache.c (inferior_regcache_data): Add valid
19596 flag.
19597 (get_regcache): Fetch registers lazily. Add fetch argument
19598 and update all callers.
19599 (regcache_invalidate_one, regcache_invalidate): New
19600 functions.
19601 (new_register_cache): Renamed from create_register_cache.
19602 Return the new regcache.
19603 (free_register_cache): Change argument to a void *.
19604 (registers_to_string, registers_from_string): Call get_regcache
19605 with fetch flag set.
19606 (register_data): Make static. Pass fetch flag to get_regcache.
19607 (supply_register): Call get_regcache with fetch flag clear.
19608 (collect_register): Call get_regcache with fetch flag set.
19609 (collect_register_as_string): New function.
19610 * regcache.h: Update.
19611 * remote-utils.c (putpkt): Flush after debug output and use
19612 stderr.
19613 Handle input interrupts while waiting for an ACK.
19614 (input_interrupt): Use signal_pid method.
19615 (getpkt): Flush after debug output and use stderr.
19616 (outreg): Use collect_register_as_string.
19617 (new_thread_notify, dead_thread_notify): New functions.
19618 (prepare_resume_reply): Check using_threads. Set thread_from_wait
19619 and general_thread.
19620 (look_up_one_symbol): Flush after debug output.
19621 * server.c (step_thread, server_waiting): New variables.
19622 (start_inferior): Don't use signal_pid. Update call to mywait.
19623 (attach_inferior): Update call to mywait.
19624 (handle_query): Handle qfThreadInfo and qsThreadInfo.
19625 (main): Don't fetch/store registers explicitly. Use
19626 set_desired_inferior. Support proposed ``Hs'' packet. Update
19627 calls to mywait.
19628 * server.h: Update.
19629 (struct inferior_list, struct_inferior_list_entry): New.
19630 * target.c (set_desired_inferior): New.
19631 (write_inferior_memory): Constify.
19632 (mywait): New function.
19633 * target.h: Update.
19634 (struct target_ops): New signal_pid method.
19635 (mywait): Removed macro, added prototype.
19636
19637 * linux-low.h (regset_func): Removed.
19638 (regset_fill_func, regset_store_func): New.
19639 (enum regset_type): New.
19640 (struct regset_info): Add type field. Use new operation types.
19641 (struct linux_target_ops): stop_pc renamed to get_pc.
19642 Add decr_pc_after_break and breakpoint_at.
19643 (get_process, get_thread_proess, get_process_thread)
19644 (strut process_info, all_processes, linux_attach_lwp)
19645 (thread_db_init): New.
19646
19647 * linux-arm-low.c (arm_get_pc, arm_set_pc,
19648 arm_breakpoint, arm_breakpoint_len, arm_breakpoint_at): New.
19649 (the_low_target): Add new members.
19650 * linux-i386-low.c (i386_store_gregset, i386_store_fpregset)
19651 (i386_store_fpxregset): Constify.
19652 (target_regsets): Add new kind identifier.
19653 (i386_get_pc): Renamed from i386_stop_pc. Simplify.
19654 (i386_set_pc): Add debugging.
19655 (i386_breakpoint_at): New function.
19656 (the_low_target): Add new members.
19657 * linux-mips-low.c (mips_get_pc, mips_set_pc)
19658 (mips_breakpoint, mips_breakpoint_len, mips_reinsert_addr)
19659 (mips_breakpoint_at): New.
19660 (the_low_target): Add new members.
19661 * linux-ppc-low.c (ppc_get_pc, ppc_set_pc)
19662 (ppc_breakpoint, ppc_breakpoint_len, ppc_breakpoint_at): New.
19663 (the_low_target): Add new members.
19664 * linux-sh-low.c (sh_get_pc, sh_set_pc)
19665 (sh_breakpoint, sh_breakpoint_len, sh_breakpoint_at): New.
19666 (the_low_target): Add new members.
19667 * linux-x86-64-low.c (target_regsets): Add new kind
19668 identifier.
19669
196702002-05-15 Daniel Jacobowitz <drow@mvista.com>
19671
19672 From Martin Pool <mbp@samba.org>:
19673 * server.c (gdbserver_usage): New function.
19674 (main): Call it.
19675
196762002-05-14 Daniel Jacobowitz <drow@mvista.com>
19677
19678 * mem-break.c (reinsert_breakpoint_by_bp): Correct typo
19679 stop_at -> stop_pc.
19680
196812002-05-04 Andrew Cagney <ac131313@redhat.com>
19682
19683 * Makefile.in: Remove obsolete code.
19684
196852002-04-24 Michal Ludvig <mludvig@suse.cz>
19686
19687 * linux-low.c (regsets_fetch_inferior_registers),
19688 (regsets_store_inferior_registers): Removed cast to int from
19689 ptrace() calls.
19690 * regcache.h: Added declaration of struct inferior_info.
19691
196922002-04-20 Daniel Jacobowitz <drow@mvista.com>
19693
19694 * inferiors.c (struct inferior_info): Add regcache_data.
19695 (add_inferior): Call create_register_cache.
19696 (clear_inferiors): Call free_register_cache.
19697 (inferior_regcache_data, set_inferior_regcache_data): New functions.
19698 * regcache.c (struct inferior_regcache_data): New.
19699 (registers): Remove.
19700 (get_regcache): New function.
19701 (create_register_cache, free_register_cache): New functions.
19702 (set_register_cache): Don't initialize the register cache here.
19703 (registers_to_string, registers_from_string, register_data): Call
19704 get_regcache.
19705 * regcache.h: Add prototypes.
19706 * server.h: Likewise.
19707
197082002-04-20 Daniel Jacobowitz <drow@mvista.com>
19709
19710 * mem-break.c: New file.
19711 * mem-break.h: New file.
19712 * Makefile.in: Add mem-break.o rule; update server.h
19713 dependencies.
19714 * inferiors.c (struct inferior_info): Add target_data
19715 member.
19716 (clear_inferiors): Free target_data member if set.
19717 (inferior_target_data, set_inferior_target_data): New functions.
19718 * linux-i386-low.c (i386_breakpoint, i386_breakpoint_len)
19719 (i386_stop_pc, i386_set_pc): New. Add to the_low_target.
19720 * linux-low.c (linux_bp_reinsert): New variable.
19721 (struct inferior_linux_data): New.
19722 (linux_create_inferior): Use set_inferior_target_data.
19723 (linux_attach): Likewise. Call add_inferior.
19724 (linux_wait_for_one_inferior): New function.
19725 (linux_wait): Call it.
19726 (linux_write_memory): Add const.
19727 (initialize_low): Call set_breakpoint_data.
19728 * linux-low.h (struct linux_target_ops): Add breakpoint
19729 handling members.
19730 * server.c (attach_inferior): Remove extra add_inferior
19731 call.
19732 * server.h: Include mem-break.h. Update inferior.c
19733 prototypes.
19734 * target.c (read_inferior_memory)
19735 (write_inferior_memory): New functions.
19736 * target.h (read_inferior_memory)
19737 (write_inferior_memory): Change macros to prototypes.
19738 (struct target_ops): Update comments. Add const to write_memory
19739 definition.
19740
197412002-04-11 Daniel Jacobowitz <drow@mvista.com>
19742
19743 * linux-low.c (usr_store_inferior_registers): Support
19744 registers which are allowed to fail to store.
19745 * linux-low.h (linux_target_ops): Likewise.
19746 * linux-ppc-low.c (ppc_regmap): Support FPSCR.
19747 (ppc_cannot_store_register): FPSCR may not be storable.
19748
197492002-04-09 Daniel Jacobowitz <drow@mvista.com>
19750
19751 * server.h: Include <string.h> if HAVE_STRING_H.
19752 * ChangeLog: Correct paths in last ChangeLog entry.
19753
197542002-04-09 Daniel Jacobowitz <drow@mvista.com>
19755
19756 * linux-low.h: Remove obsolete prototypes.
19757 (struct linux_target_ops): New.
19758 (extern the_low_target): New.
19759 * linux-low.c (num_regs, regmap): Remove declarations.
19760 (register_addr): Use the_low_target explicitly.
19761 (fetch_register): Likewise.
19762 (usr_fetch_inferior_registers): Likewise.
19763 (usr_store_inferior_registers): Likewise.
19764 * linux-arm-low.c (num_regs): Remove.
19765 (arm_num_regs): Define.
19766 (arm_regmap): Renamed from regmap, made static.
19767 (arm_cannot_fetch_register): Renamed from cannot_fetch_register,
19768 made static.
19769 (arm_cannot_store_register): Renamed from cannot_store_register,
19770 made static.
19771 (the_low_target): New.
19772 * linux-i386-low.c (num_regs): Remove.
19773 (i386_num_regs): Define.
19774 (i386_regmap): Renamed from regmap, made static.
19775 (i386_cannot_fetch_register): Renamed from cannot_fetch_register,
19776 made static.
19777 (i386_cannot_store_register): Renamed from cannot_store_register,
19778 made static.
19779 (the_low_target): New.
19780 * linux-ia64-low.c (num_regs): Remove.
19781 (ia64_num_regs): Define.
19782 (ia64_regmap): Renamed from regmap, made static.
19783 (ia64_cannot_fetch_register): Renamed from cannot_fetch_register,
19784 made static.
19785 (ia64_cannot_store_register): Renamed from cannot_store_register,
19786 made static.
19787 (the_low_target): New.
19788 * linux-m68k-low.c (num_regs): Remove.
19789 (m68k_num_regs): Define.
19790 (m68k_regmap): Renamed from regmap, made static.
19791 (m68k_cannot_fetch_register): Renamed from cannot_fetch_register,
19792 made static.
19793 (m68k_cannot_store_register): Renamed from cannot_store_register,
19794 made static.
19795 (the_low_target): New.
19796 * linux-mips-low.c (num_regs): Remove.
19797 (mips_num_regs): Define.
19798 (mips_regmap): Renamed from regmap, made static.
19799 (mips_cannot_fetch_register): Renamed from cannot_fetch_register,
19800 made static.
19801 (mips_cannot_store_register): Renamed from cannot_store_register,
19802 made static.
19803 (the_low_target): New.
19804 * linux-ppc-low.c (num_regs): Remove.
19805 (ppc_num_regs): Define.
19806 (ppc_regmap): Renamed from regmap, made static.
19807 (ppc_cannot_fetch_register): Renamed from cannot_fetch_register,
19808 made static.
19809 (ppc_cannot_store_register): Renamed from cannot_store_register,
19810 made static.
19811 (the_low_target): New.
19812 * linux-s390-low.c (num_regs): Remove.
19813 (s390_num_regs): Define.
19814 (s390_regmap): Renamed from regmap, made static.
19815 (s390_cannot_fetch_register): Renamed from cannot_fetch_register,
19816 made static.
19817 (s390_cannot_store_register): Renamed from cannot_store_register,
19818 made static.
19819 (the_low_target): New.
19820 * linux-sh-low.c (num_regs): Remove.
19821 (sh_num_regs): Define.
19822 (sh_regmap): Renamed from regmap, made static.
19823 (sh_cannot_fetch_register): Renamed from cannot_fetch_register,
19824 made static.
19825 (sh_cannot_store_register): Renamed from cannot_store_register,
19826 made static.
19827 (the_low_target): New.
19828 * linux-x86-64-low.c (x86_64_regmap): Renamed from regmap.
19829 (the_low_target): New.
19830
198312002-04-09 Daniel Jacobowitz <drow@mvista.com>
19832
19833 * Makefile.in: Add stamp-h target.
19834 * configure.in: Create stamp-h.
19835 * configure: Regenerated.
19836
198372002-04-09 Daniel Jacobowitz <drow@mvista.com>
19838
19839 * inferiors.c: New file.
19840 * target.c: New file.
19841 * target.h: New file.
19842 * Makefile.in: Add target.o and inferiors.o. Update
19843 dependencies.
19844 * linux-low.c (inferior_pid): New static variable,
19845 moved from server.c.
19846 (linux_create_inferior): Renamed from create_inferior.
19847 Call add_inferior. Return 0 on success instead of a PID.
19848 (linux_attach): Renamed from myattach.
19849 (linux_kill): Renamed from kill_inferior. Call clear_inferiors ().
19850 (linux_thread_alive): Renamed from mythread_alive.
19851 (linux_wait): Renamed from mywait. Call clear_inferiors () if the
19852 child dies.
19853 (linux_resume): Renamed from myresume. Add missing ``return 0''.
19854 (regsets_store_inferior_registers): Correct error message.
19855 Add missing ``return 0''.
19856 (linux_fetch_registers): Renamed from fetch_inferior_registers.
19857 (linux_store_registers): Renamed from store_inferior_registers.
19858 (linux_read_memory): Renamed from read_inferior_memory.
19859 (linux_write_memory): Renamed from write_inferior_memory.
19860 (linux_target_ops): New structure.
19861 (initialize_low): Call set_target_ops ().
19862 * remote-utils.c (unhexify): New function.
19863 (hexify): New function.
19864 (input_interrupt): Send signals to ``signal_pid''.
19865 * server.c (inferior_pid): Remove.
19866 (start_inferior): Update create_inferior call.
19867 (attach_inferior): Call add_inferior.
19868 (handle_query): New function.
19869 (main): Call handle_query for `q' packets.
19870 * server.h: Include "target.h". Remove obsolete prototypes.
19871 Add prototypes for "inferiors.c", "target.c", hexify, and unhexify.
19872
198732002-04-09 Daniel Jacobowitz <drow@mvista.com>
19874
19875 * Makefile.in: Add WARN_CFLAGS. Update configury
19876 dependencies.
19877 * configure.in: Check for <string.h>
19878 * configure: Regenerate.
19879 * config.in: Regenerate.
19880 * gdbreplay.c: Include needed system headers.
19881 (remote_open): Remove strchr prototype.
19882 * linux-low.h: Correct #ifdef to HAVE_LINUX_USRREGS.
19883 * regcache.c (supply_register): Change buf argument to const void *.
19884 (supply_register_by_name): Likewise.
19885 (collect_register): Change buf argument to void *.
19886 (collect_register_by_name): Likewise.
19887 * regcache.h: Add missing prototypes.
19888 * remote-utils.c: Include <arpa/inet.h> for inet_ntoa.
19889 * server.c (handle_query): New function.
19890 (attached): New static variable, moved out of main.
19891 (main): Quiet longjmp clobber warnings.
19892 * server.h: Add ATTR_NORETURN and ATTR_FORMAT. Update prototypes.
19893 * utils.c (error): Remove NORETURN.
19894 (fatal): Likewise.