1 2020-04-08 Tom Tromey <tromey@adacore.com>
3 * win32-low.c (child_continue): Call continue_last_debug_event.
5 2020-04-08 Tom Tromey <tromey@adacore.com>
7 * win32-low.c (handle_exception): Remove.
8 (windows_nat::handle_ms_vc_exception): New function.
9 (get_child_debug_event): Add "continue_status" parameter.
13 2020-04-08 Tom Tromey <tromey@adacore.com>
15 * win32-low.c (windows_nat::handle_load_dll): Rename from
16 handle_load_dll. No longer static.
17 (windows_nat::handle_unload_dll): Rename from handle_unload_dll.
20 2020-04-08 Tom Tromey <tromey@adacore.com>
22 * win32-low.c (handle_output_debug_string): Add parameter. Change
24 (win32_kill, get_child_debug_event): Update.
26 2020-04-08 Tom Tromey <tromey@adacore.com>
28 * win32-low.c (current_process_handle, current_process_id)
29 (main_thread_id, last_sig, current_event, siginfo_er): Move to
32 2020-04-08 Tom Tromey <tromey@adacore.com>
34 * win32-low.c (get_image_name): Remove.
35 (handle_load_dll): Update.
37 2020-04-08 Tom Tromey <tromey@adacore.com>
39 * win32-low.c (windows_nat::thread_rec): Rename from thread_rec.
40 No longer static. Change parameters.
41 (child_add_thread, child_fetch_inferior_registers)
42 (child_store_inferior_registers, win32_resume)
43 (win32_get_tib_address): Update.
45 2020-04-08 Tom Tromey <tromey@adacore.com>
47 * win32-low.h (struct win32_target_ops): Use qualified names where
49 * win32-i386-low.c: Add "using namespace".
50 * win32-low.c: Add "using namespace".
51 * win32-arm-low.c: Add "using namespace".
53 2020-04-08 Tom Tromey <tromey@adacore.com>
55 * win32-low.c (delete_thread_info): Don't call CloseHandle.
57 2020-04-08 Tom Tromey <tromey@adacore.com>
59 * win32-low.c (win32_require_context, suspend_one_thread): Use
60 windows_thread_info::suspend.
61 (continue_one_thread): Use windows_thread_info::resume.
62 * configure.srv (srv_tgtobj): Add windows-nat.o when needed.
64 2020-04-08 Tom Tromey <tromey@adacore.com>
66 * win32-i386-low.c (update_debug_registers)
67 (i386_prepare_to_resume, i386_thread_added): Update.
69 2020-04-08 Tom Tromey <tromey@adacore.com>
71 * win32-low.c (child_add_thread): Use new.
72 (delete_thread_info): Use delete.
74 2020-04-08 Tom Tromey <tromey@adacore.com>
76 * win32-low.h (struct windows_thread_info): Remove.
78 2020-04-08 Tom Tromey <tromey@adacore.com>
80 * win32-low.h (struct windows_thread_info): Rename from
81 win32_thread_info. Remove typedef.
82 (struct win32_target_ops, win32_require_context): Update.
83 * win32-low.c (win32_get_thread_context)
84 (win32_set_thread_context, win32_prepare_to_resume)
85 (win32_require_context, thread_rec, child_add_thread)
86 (delete_thread_info, continue_one_thread)
87 (child_fetch_inferior_registers, child_store_inferior_registers)
88 (win32_resume, suspend_one_thread, win32_get_tib_address):
90 * win32-i386-low.c (update_debug_registers)
91 (win32_get_current_dr, i386_get_thread_context)
92 (i386_prepare_to_resume, i386_thread_added, i386_single_step)
93 (i386_fetch_inferior_register, i386_store_inferior_register):
95 * win32-arm-low.c (arm_get_thread_context)
96 (arm_fetch_inferior_register, arm_store_inferior_register):
99 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
101 * linux-low.h (struct linux_target_ops): Remove.
102 (the_low_target): Remove.
103 * linux-x86-low.cc (the_low_target): Remove.
104 * linux-aarch64-low.cc (the_low_target): Ditto.
105 * linux-arm-low.cc (the_low_target): Ditto.
106 * linux-bfin-low.cc (the_low_target): Ditto.
107 * linux-cris-low.cc (the_low_target): Ditto.
108 * linux-crisv32-low.cc (the_low_target): Ditto.
109 * linux-ia64-low.cc (the_low_target): Ditto.
110 * linux-m32r-low.cc (the_low_target): Ditto.
111 * linux-m68k-low.cc (the_low_target): Ditto.
112 * linux-mips-low.cc (the_low_target): Ditto.
113 * linux-nios2-low.cc (the_low_target): Ditto.
114 * linux-ppc-low.cc (the_low_target): Ditto.
115 * linux-riscv-low.cc (the_low_target): Ditto.
116 * linux-s390-low.cc (the_low_target): Ditto.
117 * linux-sh-low.cc (the_low_target): Ditto.
118 * linux-sparc-low.cc (the_low_target): Ditto.
119 * linux-tic6x-low.cc (the_low_target): Ditto.
120 * linux-tile-low.cc (the_low_target): Ditto.
121 * linux-xtensa-low.cc (the_low_target): Ditto.
123 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
125 Remove the 'get_ipa_tdesc_idx' linux target op and let a concrete
126 linux target define the op by overriding the declaration in
127 process_stratum_target.
129 * linux-low.h (struct linux_target_ops): Remove the op.
130 (class linux_process_target) <get_ipa_tdesc_idx>: Remove.
131 * linux-low.cc (linux_process_target::get_ipa_tdesc_idx): Remove.
132 * linux-x86-low.cc (class x86_target) <get_ipa_tdesc_idx>: Declare.
133 (x86_get_ipa_tdesc_idx): Turn into...
134 (x86_target::get_ipa_tdesc_idx): ...this.
135 (the_low_target): Remove the op field.
136 * linux-ppc-low.cc (class ppc_target) <get_ipa_tdesc_idx>: Declare.
137 (ppc_get_ipa_tdesc_idx): Turn into...
138 (ppc_target::get_ipa_tdesc_idx): ...this.
139 (the_low_target): Remove the op field.
140 * linux-s390-low.cc (class s390_target) <get_ipa_tdesc_idx>: Declare.
141 (s390_get_ipa_tdesc_idx): Turn into...
142 (s390_target::get_ipa_tdesc_idx): ...this.
143 (the_low_target): Remove the op field.
145 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
147 Turn the 'get_syscall_trapinfo' linux target op into a method
148 of process_stratum_target.
150 * linux-low.h (struct linux_target_ops): Remove the op.
151 (class linux_process_target) <get_syscall_trapinfo>
152 <gdb_catch_this_syscall>
153 <low_supports_catch_syscall>
154 <low_get_syscall_trapinfo>: Declare.
155 * linux-low.cc (get_syscall_trapinfo): Turn into...
156 (linux_process_target::get_syscall_trapinfo): ...this.
157 (linux_process_target::low_get_syscall_trapinfo): Define.
158 (gdb_catch_this_syscall_p): Turn into...
159 (linux_process_target::gdb_catch_this_syscall): ...this.
160 (linux_process_target::low_supports_catch_syscall): Define.
162 Update the callers below.
164 (linux_process_target::wait_1)
165 (linux_process_target::supports_catch_syscall)
167 * linux-x86-low.cc (class x86_target) <low_supports_catch_syscall>
168 <low_get_syscall_trapinfo>: Declare.
169 (x86_target::low_supports_catch_syscall): Define.
170 (x86_get_syscall_trapinfo): Turn into...
171 (x86_target::low_get_syscall_trapinfo): ...this.
172 (the_low_target): Remove the op field.
173 * linux-aarch64-low.cc (class aarch64_target)
174 <low_supports_catch_syscall>
175 <low_get_syscall_trapinfo>: Declare.
176 (aarch64_target::low_supports_catch_syscall): Define.
177 (aarch64_get_syscall_trapinfo): Turn into...
178 (aarch64_target::low_get_syscall_trapinfo): ...this.
179 (the_low_target): Remove the op field.
180 * linux-arm-low.cc (class arm_target) <low_supports_catch_syscall>
181 <low_get_syscall_trapinfo>: Declare.
182 (arm_target::low_supports_catch_syscall): Define.
183 (arm_get_syscall_trapinfo): Turn into...
184 (arm_target::low_get_syscall_trapinfo): ...this.
185 (the_low_target): Remove the op field.
186 * linux-ppc-low.cc (the_low_target): Remove the op field.
187 * linux-s390-low.cc (the_low_target): Remove the op field.
189 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
191 Remove the 'supports_hardware_single_step' linux target op and
192 override the process_stratum_target's op definition in
193 linux_process_target to return true.
195 * linux-low.h (struct linux_target_ops): Remove the op.
196 (class linux_process_target) <finish_step_over>
197 <maybe_hw_step>: Declare.
198 * linux-low.cc (can_hardware_single_step): Remove.
199 (maybe_hw_step): Turn into...
200 (linux_process_target::maybe_hw_step): ...this.
201 (finish_step_over): Turn into...
202 (linux_process_target::finish_step_over): ...this.
203 (linux_process_target::supports_hardware_single_step): Update
206 Update the callers below.
208 (linux_process_target::single_step)
209 (linux_process_target::resume_one_lwp_throw)
211 * linux-arm-low.cc (class arm_target)
212 <supports_hardware_single_step>: Declare.
213 (arm_supports_hardware_single_step): Turn into...
214 (arm_target::supports_hardware_single_step): ...this.
215 (the_low_target): Remove the op field.
216 * linux-x86-low.cc (x86_supports_hardware_single_step): Remove.
217 (the_low_target): Remove the op field.
218 * linux-aarch64-low.cc (aarch64_supports_hardware_single_step):
220 (the_low_target): Remove the op field.
221 * linux-bfin-low.cc (bfin_supports_hardware_single_step): Remove.
222 (the_low_target): Remove the op field.
223 * linux-crisv32-low.cc (cris_supports_hardware_single_step): Remove.
224 (the_low_target): Remove the op field.
225 * linux-m32r-low.cc (m32r_supports_hardware_single_step): Remove.
226 (the_low_target): Remove the op field.
227 * linux-m68k-low.cc (m68k_supports_hardware_single_step): Remove.
228 (the_low_target): Remove the op field.
229 * linux-ppc-low.cc (ppc_supports_hardware_single_step): Remove.
230 (the_low_target): Remove the op field.
231 * linux-s390-low.cc (s390_supports_hardware_single_step): Remove.
232 (the_low_target): Remove the op field.
233 * linux-sh-low.cc (sh_supports_hardware_single_step): Remove.
234 (the_low_target): Remove the op field.
235 * linux-tic6x-low.cc (tic6x_supports_hardware_single_step): Remove.
236 (the_low_target): Remove the op field.
237 * linux-tile-low.cc (tile_supports_hardware_single_step): Remove.
238 (the_low_target): Remove the op field.
239 * linux-xtensa-low.cc (xtensa_supports_hardware_single_step):
241 (the_low_target): Remove the op field.
243 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
245 Turn the 'supports_range_stepping' linux target op into a method
246 of linux_process_target.
248 * linux-low.h (struct linux_target_ops): Remove the op.
249 (class linux_process_target) <low_supports_range_stepping>: Declare.
250 * linux-low.cc (linux_process_target::low_supports_range_stepping):
252 (linux_process_target::supports_range_stepping): Update the call
254 * linux-x86-low.cc (class x86_target)
255 <low_supports_range_stepping>: Declare.
256 (x86_supports_range_stepping): Turn into...
257 (x86_target::low_supports_range_stepping): ...this.
258 (the_low_target): Remove the op field.
259 * linux-aarch64-low.cc (class aarch64_target)
260 <low_supports_range_stepping>: Declare.
261 (aarch64_supports_range_stepping): Turn into...
262 (aarch64_target::low_supports_range_stepping): ...this.
263 (the_low_target): Remove the op field.
264 * linux-arm-low.cc (the_low_target): Remove the op field.
265 * linux-bfin-low.cc (the_low_target): Ditto.
266 * linux-crisv32-low.cc (the_low_target): Ditto.
267 * linux-m32r-low.cc (the_low_target): Ditto.
268 * linux-m68k-low.cc (the_low_target): Ditto.
269 * linux-ppc-low.cc (the_low_target): Ditto.
270 * linux-s390-low.cc (the_low_target): Ditto.
271 * linux-sh-low.cc (the_low_target): Ditto.
272 * linux-tic6x-low.cc (the_low_target): Ditto.
273 * linux-tile-low.cc (the_low_target): Ditto.
274 * linux-xtensa-low.cc (the_low_target): Ditto.
276 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
278 Remove the 'emit_ops' linux target ops and let the concrete
279 linux target define the op by overriding the declaration of
280 process_stratum_target.
282 * linux-low.h (struct linux_target_ops): Remove the op.
283 (class linux_process_target) <emit_ops>: Remove.
284 * linux-low.cc (linux_process_target::emit_ops): Remove.
285 * linux-x86-low.cc (class x86_target) <emit_ops>: Declare.
286 (x86_emit_ops): Turn into...
287 (x86_target::emit_ops): ...this.
288 (the_low_target): Remove the op field.
289 * linux-aarch64-low.cc (class aarch64_target) <emit_ops>: Declare.
290 (aarch64_emit_ops): Turn into...
291 (aarch64_target::emit_ops): ...this.
292 (the_low_target): Remove the op field.
293 * linux-ppc-low.cc (class ppc_target) <emit_ops>: Declare.
294 (ppc_emit_ops): Turn into...
295 (ppc_target::emit_ops): ...this.
296 (the_low_target): Remove the op field.
297 * linux-s390-low.cc (class s390_target) <emit_ops>: Declare.
298 (s390_emit_ops): Turn into...
299 (s390_target::emit_ops): ...this.
300 (the_low_target): Remove the op field.
301 * linux-arm-low.cc (the_low_target): Remove the op field.
302 * linux-bfin-low.cc (the_low_target): Ditto.
303 * linux-crisv32-low.cc (the_low_target): Ditto.
304 * linux-m32r-low.cc (the_low_target): Ditto.
305 * linux-m68k-low.cc (the_low_target): Ditto.
306 * linux-sh-low.cc (the_low_target): Ditto.
307 * linux-tic6x-low.cc (the_low_target): Ditto.
308 * linux-tile-low.cc (the_low_target): Ditto.
309 * linux-xtensa-low.cc (the_low_target): Ditto.
311 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
313 Remove the 'install_fast_tracepoint_jump_pad' and
314 'get_min_fast_tracepoint_insn_len' linux target ops to let the
315 concrete linux target define the ops by overriding the declarations
316 of process_stratum_target.
318 * linux-low.h (struct linux_target_ops): Remove the ops.
319 (class linux_process_target) <supports_fast_tracepoints>
320 <install_fast_tracepoint_jump_pad>
321 <get_min_fast_tracepoint_insn_len>: Remove.
322 * linux-low.cc (linux_process_target::supports_fast_tracepoints)
323 (linux_process_target::install_fast_tracepoint_jump_pad)
324 (linux_process_target::get_min_fast_tracepoint_insn_len): Remove.
325 * linux-x86-low.cc (class x86_target) <supports_fast_tracepoints>
326 <install_fast_tracepoint_jump_pad>
327 <get_min_fast_tracepoint_insn_len>: Declare.
328 (x86_target::supports_fast_tracepoints): Define.
329 (x86_install_fast_tracepoint_jump_pad): Turn into...
330 (x86_target::install_fast_tracepoint_jump_pad): ...this.
331 (x86_get_min_fast_tracepoint_insn_len): Turn into...
332 (x86_target::get_min_fast_tracepoint_insn_len): ...this.
333 (the_low_target): Remove the op fields.
334 * linux-aarch64-low.cc (class aarch64_target)
335 <supports_fast_tracepoints>
336 <install_fast_tracepoint_jump_pad>
337 <get_min_fast_tracepoint_insn_len>: Declare.
338 (aarch64_target::supports_fast_tracepoints): Define.
339 (aarch64_install_fast_tracepoint_jump_pad): Turn into...
340 (aarch64_target::install_fast_tracepoint_jump_pad): ...this.
341 (aarch64_get_min_fast_tracepoint_insn_len): Turn into...
342 (aarch64_target::get_min_fast_tracepoint_insn_len): ...this.
343 (the_low_target): Remove the op fields.
344 * linux-ppc-low.cc (class ppc_target) <supports_fast_tracepoints>
345 <install_fast_tracepoint_jump_pad>
346 <get_min_fast_tracepoint_insn_len>: Declare.
347 (ppc_target::supports_fast_tracepoints): Define.
348 (ppc_install_fast_tracepoint_jump_pad): Turn into...
349 (ppc_target::install_fast_tracepoint_jump_pad): ...this.
350 (ppc_get_min_fast_tracepoint_insn_len): Turn into...
351 (ppc_target::get_min_fast_tracepoint_insn_len): ...this.
352 (the_low_target): Remove the op fields.
353 * linux-s390-low.cc (class s390_target) <supports_fast_tracepoints>
354 <install_fast_tracepoint_jump_pad>
355 <get_min_fast_tracepoint_insn_len>: Declare.
356 (s390_target::supports_fast_tracepoints): Define.
357 (s390_install_fast_tracepoint_jump_pad): Turn into...
358 (s390_target::install_fast_tracepoint_jump_pad): ...this.
359 (s390_get_min_fast_tracepoint_insn_len): Turn into...
360 (s390_target::get_min_fast_tracepoint_insn_len): ...this.
361 (the_low_target): Remove the op fields.
362 * linux-arm-low.cc (the_low_target): Remove the op fields.
363 * linux-bfin-low.cc (the_low_target): Ditto.
364 * linux-crisv32-low.cc (the_low_target): Ditto.
365 * linux-m32r-low.cc (the_low_target): Ditto.
366 * linux-m68k-low.cc (the_low_target): Ditto.
367 * linux-sh-low.cc (the_low_target): Ditto.
368 * linux-tic6x-low.cc (the_low_target): Ditto.
369 * linux-tile-low.cc (the_low_target): Ditto.
370 * linux-xtensa-low.cc (the_low_target): Ditto.
372 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
374 Turn the 'get_thread_area' linux target op into a method of
375 process_stratum_target.
377 * linux-low.h (struct linux_target_ops): Remove the op.
378 (class linux_process_target) <stuck_in_jump_pad>
379 <linux_fast_tracepoint_collecting>
380 <low_get_thread_area>: Declare.
381 * linux-low.cc (supports_fast_tracepoints): Remove.
382 (linux_fast_tracepoint_collecting): Turn into...
383 (linux_process_target::linux_fast_tracepoint_collecting): ...this.
384 (linux_process_target::low_get_thread_area): Define.
385 (stuck_in_jump_pad_callback): Turn into...
386 (linux_process_target::stuck_in_jump_pad): ...this.
388 Update the caller below.
390 (linux_process_target::stabilize_threads)
392 * linux-x86-low.cc (class x86_target) <low_get_thread_area>:
394 (x86_get_thread_area): Turn into...
395 (x86_target::low_get_thread_area): ...this.
396 (the_low_target): Remove the op field.
397 * linux-aarch64-low.cc (class aarch64_target) <low_get_thread_area>:
399 (aarch64_get_thread_area): Turn into...
400 (aarch64_target::low_get_thread_area): ...this.
401 (the_low_target): Remove the op field.
402 * linux-ppc-low.cc (class ppc_target) <low_get_thread_area>:
404 (ppc_get_thread_area): Turn into...
405 (ppc_target::low_get_thread_area): ...this.
406 (the_low_target): Remove the op field.
407 * linux-s390-low.cc (class s390_target) <low_get_thread_area>:
409 (s390_get_thread_area): Turn into...
410 (s390_target::low_get_thread_area): ...this.
411 (the_low_target): Remove the op field.
412 * linux-arm-low.cc (the_low_target): Remove the op field.
413 * linux-bfin-low.cc (the_low_target): Ditto.
414 * linux-crisv32-low.cc (the_low_target): Ditto.
415 * linux-m32r-low.cc (the_low_target): Ditto.
416 * linux-m68k-low.cc (the_low_target): Ditto.
417 * linux-sh-low.cc (the_low_target): Ditto.
418 * linux-tic6x-low.cc (the_low_target): Ditto.
419 * linux-tile-low.cc (the_low_target): Ditto.
420 * linux-xtensa-low.cc (the_low_target): Ditto.
422 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
424 Remote the 'supports_tracepoints' linux target op and let the
425 concrete linux target define it by overriding the op declared in
426 process_stratum_target.
428 * linux-low.h (struct linux_target_ops): Remove the op.
429 (class linux_process_target) <supports_tracepoints>: Remove.
430 * linux-low.cc (linux_process_target::supports_tracepoints): Remove.
431 * linux-x86-low.cc (class x86_target) <supports_tracepoints>:
433 (x86_supports_tracepoints): Turn into...
434 (x86_target::supports_tracepoints): ...this.
435 (the_low_target): Remove the op field.
436 * linux-aarch64-low.cc (class aarch64_target)
437 <supports_tracepoints>: Declare.
438 (aarch64_supports_tracepoints): Turn into...
439 (aarch64_target::supports_tracepoints): ...this.
440 (the_low_target): Remove the op field.
441 * linux-ppc-low.cc (class ppc_target) <supports_tracepoints>:
443 (ppc_supports_tracepoints): Turn into...
444 (ppc_target::supports_tracepoints): ...this.
445 (the_low_target): Remove the op field.
446 * linux-s390-low.cc (class s390_target) <supports_tracepoints>:
448 (s390_supports_tracepoints): Turn into...
449 (s390_target::supports_tracepoints): ...this.
450 (the_low_target): Remove the op field.
451 * linux-arm-low.cc (the_low_target): Remove the op field.
452 * linux-bfin-low.cc (the_low_target): Ditto.
453 * linux-crisv32-low.cc (the_low_target): Ditto.
454 * linux-m32r-low.cc (the_low_target): Ditto.
455 * linux-m68k-low.cc (the_low_target): Ditto.
456 * linux-sh-low.cc (the_low_target): Ditto.
457 * linux-tic6x-low.cc (the_low_target): Ditto.
458 * linux-tile-low.cc (the_low_target): Ditto.
459 * linux-xtensa-low.cc (the_low_target): Ditto.
461 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
463 Remove the 'process_qsupported' linux target op and let a concrete
464 linux target define the op by overriding the op declaration in
465 process_stratum_target.
467 * linux-low.h (struct linux_target_ops): Remove the op.
468 (class linux_process_target) <process_qsupported>: Remove.
469 * linux-low.cc (linux_process_target::process_qsupported): Remove.
470 * linux-x86-low.cc (class x86_target) <process_qsupported>: Declare.
471 (x86_linux_process_qsupported): Turn into...
472 (x86_target::process_qsupported): ...this.
473 (the_low_target): Remove the op field.
474 * linux-aarch64-low.cc (the_low_target): Remove the op
476 * linux-arm-low.cc (the_low_target): Ditto.
477 * linux-bfin-low.cc (the_low_target): Ditto.
478 * linux-crisv32-low.cc (the_low_target): Ditto.
479 * linux-m32r-low.cc (the_low_target): Ditto.
480 * linux-m68k-low.cc (the_low_target): Ditto.
481 * linux-ppc-low.cc (the_low_target): Ditto.
482 * linux-s390-low.cc (the_low_target): Ditto.
483 * linux-sh-low.cc (the_low_target): Ditto.
484 * linux-tic6x-low.cc (the_low_target): Ditto.
485 * linux-tile-low.cc (the_low_target): Ditto.
486 * linux-xtensa-low.cc (the_low_target): Ditto.
488 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
490 Turn the 'prepare_to_resume' linux target op into a method of
491 linux_process_target.
493 * linux-low.h (struct linux_target_ops): Remove the op.
494 (class linux_process_target) <low_prepare_to_resume>: Declare.
495 * linux-low.cc (linux_process_target::low_prepare_to_resume):
498 Update the callers below:
500 (linux_process_target::resume_one_lwp_throw)
501 (linux_process_target::low_prepare_to_resume)
503 * linux-x86-low.cc (class x86_target) <low_prepare_to_resume>:
505 (x86_target::low_prepare_to_resume): Define.
506 (the_low_target): Remove the op field.
507 * linux-aarch64-low.cc (class aarch64_target)
508 <low_prepare_to_resume>: Declare.
509 (aarch64_target::low_prepare_to_resume): Define.
510 (the_low_target): Remove the op field.
511 * linux-arm-low.cc (class arm_target) <low_prepare_to_resume>:
513 (arm_prepare_to_resume): Turn into...
514 (arm_target::low_prepare_to_resume): ...this.
515 (the_low_target): Remove the op field.
516 * linux-mips-low.cc (class mips_target) <low_prepare_to_resume>:
518 (mips_linux_prepare_to_resume): Turn into...
519 (mips_target::low_prepare_to_resume): ...this.
520 (the_low_target): Remove the op field.
521 * linux-bfin-low.cc (the_low_target): Remove the op field.
522 * linux-crisv32-low.cc (the_low_target): Ditto.
523 * linux-m32r-low.cc (the_low_target): Ditto.
524 * linux-m68k-low.cc (the_low_target): Ditto.
525 * linux-ppc-low.cc (the_low_target): Ditto.
526 * linux-s390-low.cc (the_low_target): Ditto.
527 * linux-sh-low.cc (the_low_target): Ditto.
528 * linux-tic6x-low.cc (the_low_target): Ditto.
529 * linux-tile-low.cc (the_low_target): Ditto.
530 * linux-xtensa-low.cc (the_low_target): Ditto.
532 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
534 Turn the 'new_process', 'delete_process', 'new_thread',
535 'delete_thread', and 'new_fork' linux target ops into methods
536 of linux_process_target.
538 * linux-low.h (struct linux_target_ops): Remove the ops.
539 (class linux_process_target) <add_linux_process>
544 <check_zombie_leaders>
550 <low_new_fork>: Declare.
551 * linux-low.cc (delete_lwp): Turn into...
552 (linux_process_target::delete_lwp): ...this.
553 (linux_process_target::low_delete_thread): Define.
554 (linux_add_process): Turn into...
555 (linux_process_target::add_linux_process): ...this.
556 (linux_process_target::low_new_process): Define.
557 (linux_process_target::low_delete_process): Define.
558 (linux_process_target::low_new_fork): Define.
559 (add_lwp): Turn into...
560 (linux_process_target::add_lwp): ...this.
561 (linux_process_target::low_new_thread): Define.
562 (linux_attach_lwp): Turn into...
563 (linux_process_target::attach_lwp): ...this.
564 (linux_detach_one_lwp): Turn into...
565 (linux_process_target::detach_one_lwp): ...this.
566 (linux_detach_lwp_callback): Remove and inline...
567 (linux_process_target::detach): ...here.
568 (check_zombie_leaders): Turn into...
569 (linux_process_target::check_zombie_leaders): ...this.
570 (filter_exit_event): Turn into...
571 (linux_process_target::filter_exit_event): ...this.
573 Update the callers below.
575 (linux_process_target::handle_extended_wait)
576 (linux_process_target::create_inferior)
577 (attach_proc_task_lwp_callback)
578 (linux_process_target::attach)
579 (linux_process_target::detach)
580 (linux_process_target::mourn)
581 * thread-db.cc (attach_thread)
583 * linux-x86-low.cc (class x86_target) <low_new_process>
587 <low_new_fork>: Declare.
588 (x86_linux_new_process): Turn into...
589 (x86_target::low_new_process): ...this.
590 (x86_linux_delete_process): Turn into...
591 (x86_target::low_delete_process): ...this.
592 (x86_target::low_new_thread): Define.
593 (x86_target::low_delete_thread): Define.
594 (x86_linux_new_fork): Turn into...
595 (x86_target::low_new_fork): ...this.
596 (the_low_target): Remove the op fields.
597 * linux-aarch64-low.cc (class aarch64_target) <low_new_process>
601 <low_new_fork>: Declare.
602 (aarch64_linux_new_process): Turn into...
603 (aarch64_target::low_new_process): ...this.
604 (aarch64_linux_delete_process): Turn into...
605 (aarch64_target::low_delete_process): ...this.
606 (aarch64_target::low_new_thread): Define.
607 (aarch64_target::low_delete_thread): Define.
608 (aarch64_linux_new_fork): Turn into...
609 (aarch64_target::low_new_fork): ...this.
610 (the_low_target): Remove the op fields.
611 * linux-arm-low.cc (class arm_target) <low_new_process>
615 <low_new_fork>: Declare.
616 (arm_new_process): Turn into...
617 (arm_target::low_new_process): ...this.
618 (arm_delete_process): Turn into...
619 (arm_target::low_delete_process): ...this.
620 (arm_new_thread): Turn into...
621 (arm_target::low_new_thread): ...this.
622 (arm_delete_thread): Turn into...
623 (arm_target::low_delete_thread): ...this.
624 (arm_new_fork): Turn into...
625 (arm_target::low_new_fork): ...this.
626 (the_low_target): Remove the op fields.
627 * linux-mips-low.cc (class mips_target) <low_new_process>
631 <low_new_fork>: Declare.
632 (mips_linux_new_process): Turn into...
633 (mips_target::low_new_process): ...this.
634 (mips_linux_delete_process): Turn into...
635 (mips_target::low_delete_process): ...this.
636 (mips_linux_new_thread): Turn into...
637 (mips_target::low_new_thread): ...this.
638 (mips_linux_delete_thread): Turn into...
639 (mips_target::low_delete_thread): ...this.
640 (mips_linux_new_fork): Turn into...
641 (mips_target::low_new_fork): ...this.
642 (the_low_target): Remove the op fields.
643 * linux-bfin-low.cc (the_low_target): Remove the op fields.
644 * linux-crisv32-low.cc (the_low_target): Ditto.
645 * linux-m32r-low.cc (the_low_target): Ditto.
646 * linux-m68k-low.cc (the_low_target): Ditto.
647 * linux-ppc-low.cc (the_low_target): Ditto.
648 * linux-s390-low.cc (the_low_target): Ditto.
649 * linux-sh-low.cc (the_low_target): Ditto.
650 * linux-tic6x-low.cc (the_low_target): Ditto.
651 * linux-tile-low.cc (the_low_target): Ditto.
652 * linux-xtensa-low.cc (the_low_target): Ditto.
654 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
656 Turn the 'siginfo_fixup' linux target op into a method of
657 linux_process_target.
659 * linux-low.h (struct linux_target_ops): Remove the op.
660 (class linux_process_target) <siginfo_fixup>
661 <low_siginfo_fixup>: Declare.
662 * linux-low.cc (siginfo_fixup): Turn into...
663 (linux_process_target::siginfo_fixup): ...this.
664 (linux_process_target::low_siginfo_fixup): Define.
665 * linux-x86-low.cc (class x86_target) <low_siginfo_fixup>: Declare.
666 (x86_siginfo_fixup): Turn into...
667 (x86_target::low_siginfo_fixup): ...this.
668 (the_low_target): Remove the op field.
669 * linux-aarch64-low.cc (class aarch64_target):
670 <low_siginfo_fixup>: Declare.
671 (aarch64_linux_siginfo_fixup): Turn into...
672 (aarch64_target::low_siginfo_fixup): ...this.
673 (the_low_target): Remove the op field.
674 * linux-arm-low.cc (the_low_target): Remove the op field.
675 * linux-bfin-low.cc (the_low_target): Ditto.
676 * linux-crisv32-low.cc (the_low_target): Ditto.
677 * linux-m32r-low.cc (the_low_target): Ditto.
678 * linux-m68k-low.cc (the_low_target): Ditto.
679 * linux-mips-low.cc (the_low_target): Ditto.
680 * linux-ppc-low.cc (the_low_target): Ditto.
681 * linux-s390-low.cc (the_low_target): Ditto.
682 * linux-sh-low.cc (the_low_target): Ditto.
683 * linux-tic6x-low.cc (the_low_target): Ditto.
684 * linux-tile-low.cc (the_low_target): Ditto.
685 * linux-xtensa-low.cc (the_low_target): Ditto.
687 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
689 Turn the 'collect_ptrace_register' and 'supply_ptrace_register'
690 linux target ops into methods of linux_process_target.
692 * linux-low.h (struct linux_target_ops): Remove the ops.
693 (class linux_process_target) <low_collect_ptrace_register>
694 <low_store_ptrace_register>: Declare.
695 * linux-low.cc (linux_process_target::low_collect_ptrace_register)
696 (linux_process_target::low_supply_ptrace_register): Define.
698 Update the callers below.
700 (linux_process_target::fetch_register)
701 (linux_process_target::store_register)
703 * linux-x86-low.cc (the_low_target): Remove the op fields.
704 * linux-aarch64-low.cc (the_low_target): Ditto.
705 * linux-arm-low.cc (the_low_target): Ditto.
706 * linux-bfin-low.cc (the_low_target): Ditto.
707 * linux-crisv32-low.cc (the_low_target): Ditto.
708 * linux-m32r-low.cc (the_low_target): Ditto.
709 * linux-m68k-low.cc (the_low_target): Ditto.
710 * linux-sh-low.cc (the_low_target): Ditto.
711 * linux-sparc-low.cc (the_low_target): Ditto.
712 * linux-tic6x-low.cc (the_low_target): Ditto.
713 * linux-tile-low.cc (the_low_target): Ditto.
714 * linux-xtensa-low.cc (the_low_target): Ditto.
715 * linux-mips-low.cc (class mips_target)
716 <low_collect_ptrace_register>
717 <low_supply_ptrace_register>: Declare.
718 (mips_collect_ptrace_register): Turn into ...
719 (mips_target::low_collect_ptrace_register): ...this.
720 (mips_supply_ptrace_register): Turn into...
721 (mips_target::low_supply_ptrace_register): ...this.
722 (the_low_target): Remove the op fields.
723 * linux-ppc-low.cc (class ppc_target)
724 <low_collect_ptrace_register>
725 <low_supply_ptrace_register>: Declare.
726 (ppc_collect_ptrace_register): Turn into ...
727 (ppc_target::low_collect_ptrace_register): ...this.
728 (ppc_supply_ptrace_register): Turn into ...
729 (ppc_target::low_supply_ptrace_register): ...this.
730 (ppc_fill_gregset): Update for the calls to
731 low_collect_ptrace_register.
732 (the_low_target): Remove the op fields.
733 * linux-s390-low.cc (class s390_target)
734 <low_collect_ptrace_register>
735 <low_supply_ptrace_register>: Declare.
736 (s390_collect_ptrace_register): Turn into ...
737 (s390_target::low_collect_ptrace_register): ...this.
738 (s390_supply_ptrace_register): Turn into ...
739 (s390_target::low_supply_ptrace_register): ...this.
740 (s390_fill_gregset): Update for the calls to
741 low_collect_ptrace_register.
742 (the_low_target): Remove the op fields.
744 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
746 Turn the 'stopped_by_watchpoint' and 'stopped_data_address' linux
747 target ops into methods of linux_process_target.
749 * linux-low.h (struct linux_target_ops): Remove the ops.
750 (class linux_process_target) <check_stopped_by_watchpoint>
751 <low_stopped_by_watchpoint>
752 <low_stopped_data_address>: Declare.
753 * linux-low.cc (check_stopped_by_watchpoint): Turn into...
754 (linux_process_target::check_stopped_by_watchpoint): ...this.
755 (linux_process_target::low_stopped_by_watchpoint): Define.
756 (linux_process_target::low_stopped_data_address): Define.
757 * linux-x86-low.cc (class x86_target) <low_stopped_by_watchpoint>
758 <low_stopped_data_address>: Declare.
759 (x86_stopped_by_watchpoint): Turn into...
760 (x86_target::low_stopped_by_watchpoint): ...this.
761 (x86_stopped_data_address): Turn into...
762 (x86_target::low_stopped_data_address): ...this.
763 (the_low_target): Remove the op fields.
764 * linux-aarch64-low.cc (class aarch64_target)
765 <low_stopped_by_watchpoint>
766 <low_stopped_data_address>: Declare.
767 (aarch64_stopped_by_watchpoint): Turn into...
768 (aarch64_target::low_stopped_by_watchpoint): ...this.
769 (aarch64_stopped_data_address): Turn into...
770 (aarch64_target::low_stopped_data_address): ...this.
771 (the_low_target): Remove the op fields.
772 * linux-arm-low.cc (class arm_target) <low_stopped_by_watchpoint>
773 <low_stopped_data_address>: Declare.
774 (arm_stopped_by_watchpoint): Turn into...
775 (arm_target::low_stopped_by_watchpoint): ...this.
776 (arm_stopped_data_address): Turn into...
777 (arm_target::low_stopped_data_address): ...this.
778 (the_low_target): Remove the op fields.
779 * linux-crisv32-low.cc (class crisv32_target)
780 <low_stopped_by_watchpoint>
781 <low_stopped_data_address>: Declare.
782 (cris_stopped_by_watchpoint): Turn into...
783 (crisv32_target::low_stopped_by_watchpoint): ...this.
784 (cris_stopped_data_address): Turn into...
785 (crisv32_target::low_stopped_data_address): ...this.
786 (the_low_target): Remove the op fields.
787 * linux-mips-low.cc (class mips_target) <low_stopped_by_watchpoint>
788 <low_stopped_data_address>: Declare.
789 (mips_stopped_by_watchpoint): Turn into...
790 (mips_target::low_stopped_by_watchpoint): ...this.
791 (mips_stopped_data_address): Turn into...
792 (mips_target::low_stopped_data_address): ...this.
793 (the_low_target): Remove the op fields.
794 * linux-bfin-low.cc (the_low_target): Remove the op fields.
795 * linux-m32r-low.cc (the_low_target): Ditto.
796 * linux-m68k-low.cc (the_low_target): Ditto.
797 * linux-ppc-low.cc (the_low_target): Ditto.
798 * linux-s390-low.cc (the_low_target): Ditto.
799 * linux-sh-low.cc (the_low_target): Ditto.
800 * linux-sparc-low.cc (the_low_target): Ditto.
801 * linux-tic6x-low.cc (the_low_target): Ditto.
802 * linux-tile-low.cc (the_low_target): Ditto.
803 * linux-xtensa-low.cc (the_low_target): Ditto.
805 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
807 Turn the 'insert_point' and 'remove_point' linux target ops into
808 methods of linux_process_target.
810 * linux-low.h (struct linux_target_ops): Remove the ops.
811 (class linux_process_target) <low_insert_point>
812 <low_remove_point>: Declare.
813 * linux-low.cc (linux_process_target::low_insert_point)
814 (linux_process_target::low_remove_point): Define.
815 (linux_process_target::insert_point)
816 (linux_process_target::remove_point): Update for calls to
817 low_insert_point and low_remove_point.
818 * linux-x86-low.cc (class x86_target) <low_insert_point>
819 <low_remove_point>: Declare.
820 (x86_insert_point): Turn into...
821 (x86_target::low_insert_point): ...this.
822 (x86_remove_point): Turn into...
823 (x86_target::low_remove_point): ...this.
824 (the_low_target): Remove the op fields.
825 * linux-aarch64-low.cc (class aarch64_target) <low_insert_point>
826 <low_remove_point>: Declare.
827 (aarch64_insert_point): Turn into...
828 (aarch64_target::low_insert_point): ...this.
829 (aarch64_remove_point): Turn into...
830 (aarch64_target::low_remove_point): ...this.
831 (the_low_target): Remove the op fields.
832 * linux-arm-low.cc (class arm_target) <low_insert_point>
833 <low_remove_point>: Declare.
834 (arm_insert_point): Turn into...
835 (arm_target::low_insert_point): ...this.
836 (arm_remove_point): Turn into...
837 (arm_target::low_remove_point): ...this.
838 (the_low_target): Remove the op fields.
839 * linux-crisv32-low.cc (class crisv32_target) <low_insert_point>
840 <low_remove_point>: Declare.
841 (crisv32_insert_point): Turn into...
842 (crisv32_target::low_insert_point): ...this.
843 (crisv32_remove_point): Turn into...
844 (crisv32_target::low_remove_point): ...this.
845 (the_low_target): Remove the op fields.
846 * linux-mips-low.cc (class mips_target) <low_insert_point>
847 <low_remove_point>: Declare.
848 (mips_insert_point): Turn into...
849 (mips_target::low_insert_point): ...this.
850 (mips_remove_point): Turn into...
851 (mips_target::low_remove_point): ...this.
852 (the_low_target): Remove the op fields.
853 * linux-ppc-low.cc (class ppc_target) <low_insert_point>
854 <low_remove_point>: Declare.
855 (ppc_insert_point): Turn into...
856 (ppc_target::low_insert_point): ...this.
857 (ppc_remove_point): Turn into...
858 (ppc_target::low_remove_point): ...this.
859 (the_low_target): Remove the op fields.
860 * linux-bfin-low.cc (the_low_target): Remove the op fields.
861 * linux-m32r-low.cc (the_low_target): Ditto.
862 * linux-m68k-low.cc (the_low_target): Ditto.
863 * linux-s390-low.cc (the_low_target): Ditto.
864 * linux-sh-low.cc (the_low_target): Ditto.
865 * linux-sparc-low.cc (the_low_target): Ditto.
866 * linux-tic6x-low.cc (the_low_target): Ditto.
867 * linux-tile-low.cc (the_low_target): Ditto.
868 * linux-xtensa-low.cc (the_low_target): Ditto.
870 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
872 Remove the 'supports_z_point_type' linux target op and let the
873 concrete linux target define it by overriding the op declared in
874 process_stratum_target.
876 * linux-low.cc (linux_process_target::supports_z_point_type):
878 * linux-low.h (struct linux_target_ops): Remove the op.
879 (class linux_process_target) <supports_z_point_type>: Remove.
880 * linux-x86-low.cc (class x86_target) <supports_z_point_type>:
882 (x86_supports_z_point_type): Turn into...
883 (x86_target::supports_z_point_type): ...this.
884 (the_low_target): Remove the op field.
885 * linux-aarch64-low.cc (class aarch64_target)
886 <supports_z_point_type>: Declare.
887 (aarch64_supports_z_point_type): Turn into...
888 (aarch64_target::supports_z_point_type): ...this.
889 (the_low_target): Remove the op field.
890 * linux-arm-low.cc (class arm_target) <supports_z_point_type>:
892 (arm_supports_z_point_type): Turn into...
893 (arm_target::supports_z_point_type): ...this.
894 (the_low_target): Remove the op field.
895 * linux-crisv32-low.cc (class crisv32_target)
896 <supports_z_point_type>: Declare.
897 (cris_supports_z_point_type): Turn into...
898 (crisv32_target::supports_z_point_type): ...this.
899 (the_low_target): Remove the op field.
900 * linux-mips-low.cc (class mips_target) <supports_z_point_type>:
902 (mips_supports_z_point_type): Turn into...
903 (mips_target::supports_z_point_type): ...this.
904 (the_low_target): Remove the op field.
905 * linux-ppc-low.cc (class ppc_target) <supports_z_point_type>:
907 (ppc_supports_z_point_type): Turn into...
908 (ppc_target::supports_z_point_type): ...this.
909 (the_low_target): Remove the op field.
910 * linux-s390-low.cc (class s390_target) <supports_z_point_type>:
912 (s390_supports_z_point_type): Turn into...
913 (s390_target::supports_z_point_type): ...this.
914 (the_low_target): Remove the op field.
915 * linux-bfin-low.cc (the_low_target): Remove the op field.
916 * linux-m32r-low.cc (the_low_target): Ditto.
917 * linux-m68k-low.cc (the_low_target): Ditto.
918 * linux-sh-low.cc (the_low_target): Ditto.
919 * linux-sparc-low.cc (the_low_target): Ditto.
920 * linux-tic6x-low.cc (the_low_target): Ditto.
921 * linux-tile-low.cc (the_low_target): Ditto.
922 * linux-xtensa-low.cc (the_low_target): Ditto.
924 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
926 Turn the 'breakpoint_at' linux target op into a method of
927 linux_process_target.
929 * linux-low.h (struct linux_target_ops): Remove the op.
930 (class linux_process_target) <low_breakpoint_at>: Declare.
932 Update the callers below:
934 * linux-low.cc (linux_process_target::save_stop_reason)
935 (linux_process_target::thread_still_has_status_pending)
936 (linux_process_target::wait_1)
938 * linux-x86-low.cc (class x86_target)
939 <low_breakpoint_at>: Declare.
940 (x86_breakpoint_at): Turn into...
941 (x86_target::low_breakpoint_at): ...this.
942 (the_low_target): Remove the op field.
943 * linux-aarch64-low.cc (class aarch64_target)
944 <low_breakpoint_at>: Declare.
945 (aarch64_breakpoint_at): Turn into...
946 (aarch64_target::low_breakpoint_at): ...this.
947 (the_low_target): Remove the op field.
948 * linux-arm-low.cc (class arm_target)
949 <low_breakpoint_at>: Declare.
950 (arm_target::low_breakpoint_at): Define.
951 (the_low_target): Remove the op field.
952 * linux-bfin-low.cc (class bfin_target)
953 <low_breakpoint_at>: Declare.
954 (bfin_breakpoint_at): Turn into...
955 (bfin_target::low_breakpoint_at): ...this.
956 (the_low_target): Remove the op field.
957 * linux-cris-low.cc (class cris_target)
958 <low_breakpoint_at>: Declare.
959 (cris_breakpoint_at): Turn into...
960 (cris_target::low_breakpoint_at): ...this.
961 (the_low_target): Remove the op field.
962 * linux-crisv32-low.cc (class crisv32_target)
963 <low_breakpoint_at>: Declare.
964 (crisv32_breakpoint_at): Turn into...
965 (crisv32_target::low_breakpoint_at): ...this.
966 (the_low_target): Remove the op field.
967 * linux-ia64-low.cc (class ia64_target)
968 <low_breakpoint_at>: Declare.
969 (ia64_target::low_breakpoint_at): Define.
970 * linux-m32r-low.cc (class m32r_target)
971 <low_breakpoint_at>: Declare.
972 (m32r_breakpoint_at): Turn into...
973 (m32r_target::low_breakpoint_at): ...this.
974 (the_low_target): Remove the op field.
975 * linux-m68k-low.cc (class m68k_target)
976 <low_breakpoint_at>: Declare.
977 (m68k_breakpoint_at): Turn into...
978 (m68k_target::low_breakpoint_at): ...this.
979 (the_low_target): Remove the op field.
980 * linux-mips-low.cc (class mips_target)
981 <low_breakpoint_at>: Declare.
982 (mips_breakpoint_at): Turn into...
983 (mips_target::low_breakpoint_at): ...this.
984 (the_low_target): Remove the op field.
985 * linux-nios2-low.cc (class nios2_target)
986 <low_breakpoint_at>: Declare.
987 (nios2_breakpoint_at): Turn into...
988 (nios2_target::low_breakpoint_at): ...this.
989 (the_low_target): Remove the op field.
990 * linux-ppc-low.cc (class ppc_target)
991 <low_breakpoint_at>: Declare.
992 (ppc_breakpoint_at): Turn into...
993 (ppc_target::low_breakpoint_at): ...this.
994 (the_low_target): Remove the op field.
995 * linux-riscv-low.cc (class riscv_target)
996 <low_breakpoint_at>: Declare.
997 (riscv_breakpoint_at): Turn into...
998 (riscv_target::low_breakpoint_at): ...this.
999 (the_low_target): Remove the op field.
1000 * linux-s390-low.cc (class s390_target)
1001 <low_breakpoint_at>: Declare.
1002 (s390_breakpoint_at): Turn into...
1003 (s390_target::low_breakpoint_at): ...this.
1004 (the_low_target): Remove the op field.
1005 * linux-sh-low.cc (class sh_target)
1006 <low_breakpoint_at>: Declare.
1007 (sh_breakpoint_at): Turn into...
1008 (sh_target::low_breakpoint_at): ...this.
1009 (the_low_target): Remove the op field.
1010 * linux-sparc-low.cc (class sparc_target)
1011 <low_breakpoint_at>: Declare.
1012 (sparc_breakpoint_at): Turn into...
1013 (sparc_target::low_breakpoint_at): ...this.
1014 (the_low_target): Remove the op field.
1015 * linux-tic6x-low.cc (class tic6x_target)
1016 <low_breakpoint_at>: Declare.
1017 (tic6x_breakpoint_at): Turn into...
1018 (tic6x_target::low_breakpoint_at): ...this.
1019 (the_low_target): Remove the op field.
1020 * linux-tile-low.cc (class tile_target)
1021 <low_breakpoint_at>: Declare.
1022 (tile_breakpoint_at): Turn into...
1023 (tile_target::low_breakpoint_at): ...this.
1024 (the_low_target): Remove the op field.
1025 * linux-xtensa-low.cc (class xtensa_target)
1026 <low_breakpoint_at>: Declare.
1027 (xtensa_breakpoint_at): Turn into...
1028 (xtensa_target::low_breakpoint_at): ...this.
1029 (the_low_target): Remove the op field.
1031 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1033 Turn the 'decr_pc_after_break' linux_target_ops field into
1034 a method of linux_process_target.
1036 * linux-low.h (struct linux_target_ops)
1037 <decr_pc_after_break>: Remove.
1038 (class linux_process_target) <low_decr_pc_after_break>: New method
1040 * linux-low.cc (linux_process_target::low_decr_pc_after_break):
1041 New method implementation.
1043 Update the users below.
1045 (linux_process_target::save_stop_reason)
1046 (linux_process_target::wait_1)
1047 * linux-x86-low.cc (class x86_target) <low_decr_pc_after_break>:
1049 (x86_target::low_decr_pc_after_break): New method implementation.
1050 (the_low_target): Remove the field.
1051 * linux-bfin-low.cc (class bfin_target) <low_decr_pc_after_break>:
1053 (bfin_target::low_decr_pc_after_break): New method implementation.
1054 (the_low_target): Remove the field.
1055 * linux-m68k-low.cc (class m68k_target) <low_decr_pc_after_break>:
1057 (m68k_target::low_decr_pc_after_break): New method implementation.
1058 (the_low_target): Remove the field.
1059 * linux-s390-low.cc (class s390_target) <low_decr_pc_after_break>:
1061 (s390_target::low_decr_pc_after_break): New method implementation.
1062 (the_low_target): Remove the field.
1063 * linux-aarch64-low.cc (the_low_target): Remove the field.
1064 * linux-arm-low.cc (the_low_target): Remove the field.
1065 * linux-cris-low.cc (the_low_target): Remove the field.
1066 * linux-crisv32-low.cc (the_low_target): Remove the field.
1067 * linux-m32r-low.cc (the_low_target): Remove the field.
1068 * linux-mips-low.cc (the_low_target): Remove the field.
1069 * linux-nios2-low.cc (the_low_target): Remove the field.
1070 * linux-ppc-low.cc (the_low_target): Remove the field.
1071 * linux-riscv-low.cc (the_low_target): Remove the field.
1072 * linux-sh-low.cc (the_low_target): Remove the field.
1073 * linux-sparc-low.cc (the_low_target): Remove the field.
1074 * linux-tic6x-low.cc (the_low_target): Remove the field.
1075 * linux-tile-low.cc (the_low_target): Remove the field.
1076 * linux-xtensa-low.cc (the_low_target): Remove the field.
1078 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1080 Remove the 'supports_software_single_step' linux target op and let
1081 the concrete linux target define it by overriding the op in
1082 process_stratum_target.
1083 Turn the 'get_next_pcs' linux target op into a method of
1084 linux_process_target.
1086 * linux-low.h (struct linux_target_ops): Remove the ops.
1087 (class linux_process_target) <supports_software_single_step>:
1089 <low_get_next_pcs>: Declare.
1090 * linux-low.cc (can_software_single_step): Remove.
1091 (linux_process_target::low_get_next_pcs): Define.
1092 (linux_process_target::supports_software_single_step): Remove.
1094 Update the callers below.
1096 (linux_process_target::handle_extended_wait)
1097 (linux_process_target::wait_1)
1098 (linux_process_target::install_software_single_step_breakpoints)
1099 (linux_process_target::single_step)
1100 (linux_process_target::thread_needs_step_over)
1101 (linux_process_target::proceed_one_lwp)
1102 (linux_process_target::supports_range_stepping)
1104 * linux-x86-low.cc (the_low_target): Remove the op field.
1105 * linux-aarch64-low.cc (the_low_target): Ditto.
1106 * linux-bfin-low.cc (the_low_target): Ditto.
1107 * linux-cris-low.cc (the_low_target): Ditto.
1108 * linux-crisv32-low.cc (the_low_target): Ditto.
1109 * linux-m32r-low.cc (the_low_target): Ditto.
1110 * linux-m68k-low.cc (the_low_target): Ditto.
1111 * linux-mips-low.cc (the_low_target): Ditto.
1112 * linux-nios2-low.cc (the_low_target): Ditto.
1113 * linux-ppc-low.cc (the_low_target): Ditto.
1114 * linux-riscv-low.cc (the_low_target): Ditto.
1115 * linux-s390-low.cc (the_low_target): Ditto.
1116 * linux-sh-low.cc (the_low_target): Ditto.
1117 * linux-sparc-low.cc (the_low_target): Ditto.
1118 * linux-tic6x-low.cc (the_low_target): Ditto.
1119 * linux-tile-low.cc (the_low_target): Ditto.
1120 * linux-xtensa-low.cc (the_low_target): Ditto.
1121 * linux-arm-low.cc (class arm_target) <low_get_next_pcs>
1122 <supports_software_single_step>: Declare.
1123 (arm_target::supports_software_single_step): Define.
1124 (arm_gdbserver_get_next_pcs): Turn into...
1125 (arm_target::low_get_next_pcs): ...this.
1126 (the_low_target): Remove the op field.
1128 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1130 Remove the 'sw_breakpoint_from_kind' linux target op, and let
1131 the concrete linux target define it by overriding the op
1132 in process_stratum_target.
1134 * linux-low.cc (linux_process_target::sw_breakpoint_from_kind):
1136 * linux-low.h (struct linux_target_ops): Remove the op.
1137 (class linux_process_target) <sw_breakpoint_from_kind>: Remove.
1138 * linux-x86-low.cc (class x86_target) <sw_breakpoint_from_kind>:
1140 (x86_sw_breakpoint_from_kind): Turn into...
1141 (x86_target::sw_breakpoint_from_kind): ...this.
1142 (the_low_target): Remove the op field.
1143 * linux-aarch64-low.cc (class aarch64_target)
1144 <sw_breakpoint_from_kind>: Declare.
1145 (aarch64_sw_breakpoint_from_kind): Turn into...
1146 (aarch64_target::sw_breakpoint_from_kind): ...this.
1147 (the_low_target): Remove the op field.
1148 * linux-arm-low.cc (class arm_target) <sw_breakpoint_from_kind>:
1150 (arm_target::sw_breakpoint_from_kind): Define.
1151 (the_low_target): Remove the op field.
1152 * linux-bfin-low.cc (class bfin_target) <sw_breakpoint_from_kind>:
1154 (bfin_sw_breakpoint_from_kind): Turn into...
1155 (bfin_target::sw_breakpoint_from_kind): ...this.
1156 (the_low_target): Remove the op field.
1157 * linux-cris-low.cc (class cris_target) <sw_breakpoint_from_kind>:
1159 (cris_sw_breakpoint_from_kind): Turn into...
1160 (cris_target::sw_breakpoint_from_kind): ...this.
1161 (the_low_target): Remove the op field.
1162 * linux-crisv32-low.cc (class crisv32_target)
1163 <sw_breakpoint_from_kind>: Declare.
1164 (cris_sw_breakpoint_from_kind): Turn into...
1165 (crisv32_target::sw_breakpoint_from_kind): ...this.
1166 (the_low_target): Remove the op field.
1167 * linux-ia64-low.cc (class ia64_target) <sw_breakpoint_from_kind>:
1169 (ia64_target::sw_breakpoint_from_kind): Define.
1170 * linux-m32r-low.cc (class m32r_target) <sw_breakpoint_from_kind>:
1172 (m32r_sw_breakpoint_from_kind): Turn into...
1173 (m32r_target::sw_breakpoint_from_kind): ...this.
1174 (the_low_target): Remove the op field.
1175 * linux-m68k-low.cc (class m68k_target) <sw_breakpoint_from_kind>:
1177 (m68k_sw_breakpoint_from_kind): Turn into...
1178 (m68k_target::sw_breakpoint_from_kind): ...this.
1179 (the_low_target): Remove the op field.
1180 * linux-mips-low.cc (class mips_target) <sw_breakpoint_from_kind>:
1182 (mips_sw_breakpoint_from_kind): Turn into...
1183 (mips_target::sw_breakpoint_from_kind): ...this.
1184 (the_low_target): Remove the op field.
1185 * linux-nios2-low.cc (class nios2_target) <sw_breakpoint_from_kind>:
1187 (nios2_sw_breakpoint_from_kind): Turn into...
1188 (nios2_target::sw_breakpoint_from_kind): ...this.
1189 (the_low_target): Remove the op field.
1190 * linux-ppc-low.cc (class ppc_target) <sw_breakpoint_from_kind>:
1192 (ppc_sw_breakpoint_from_kind): Turn into...
1193 (ppc_target::sw_breakpoint_from_kind): ...this.
1194 (the_low_target): Remove the op field.
1195 * linux-riscv-low.cc (class riscv_target) <sw_breakpoint_from_kind>:
1197 (riscv_sw_breakpoint_from_kind): Turn into...
1198 (riscv_target::sw_breakpoint_from_kind): ...this.
1199 (the_low_target): Remove the op field.
1200 * linux-s390-low.cc (class s390_target) <sw_breakpoint_from_kind>:
1202 (s390_sw_breakpoint_from_kind): Turn into...
1203 (s390_target::sw_breakpoint_from_kind): ...this.
1204 (the_low_target): Remove the op field.
1205 * linux-sh-low.cc (class sh_target) <sw_breakpoint_from_kind>:
1207 (sh_sw_breakpoint_from_kind): Turn into...
1208 (sh_target::sw_breakpoint_from_kind): ...this.
1209 (the_low_target): Remove the op field.
1210 * linux-sparc-low.cc (class sparc_target) <sw_breakpoint_from_kind>:
1212 (sparc_sw_breakpoint_from_kind): Turn into...
1213 (sparc_target::sw_breakpoint_from_kind): ...this.
1214 (the_low_target): Remove the op field.
1215 * linux-tic6x-low.cc (class tic6x_target) <sw_breakpoint_from_kind>:
1217 (tic6x_sw_breakpoint_from_kind): Turn into...
1218 (tic6x_target::sw_breakpoint_from_kind): ...this.
1219 (the_low_target): Remove the op field.
1220 * linux-tile-low.cc (class tile_target) <sw_breakpoint_from_kind>:
1222 (tile_sw_breakpoint_from_kind): Turn into...
1223 (tile_target::sw_breakpoint_from_kind): ...this.
1224 (the_low_target): Remove the op field.
1225 * linux-xtensa-low.cc (class xtensa_target)
1226 <sw_breakpoint_from_kind>: Declare.
1227 (xtensa_sw_breakpoint_from_kind): Turn into...
1228 (xtensa_target::sw_breakpoint_from_kind): ...this.
1229 (the_low_target): Remove the op field.
1231 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1233 Remove the 'breakpoint_kind_from_pc' and
1234 'breakpoint_kind_from_current_state' linux target ops, and let the
1235 concrete linux target define them by overriding the ops of
1236 process_stratum_target.
1238 * linux-low.cc (linux_process_target::breakpoint_kind_from_pc):
1240 (linux_process_target::breakpoint_kind_from_current_state): Remove.
1241 * linux-low.h (struct linux_target_ops): Remove ops.
1242 (class linux_process_target) <breakpoint_kind_from_pc>: Remove.
1243 <breakpoint_kind_from_current_state>: Remove.
1244 * linux-x86-low.cc (the_low_target): Remove the op fields.
1245 * linux-bfin-low.cc (the_low_target): Ditto.
1246 * linux-cris-low.cc (the_low_target): Ditto.
1247 * linux-crisv32-low.cc (the_low_target): Ditto.
1248 * linux-m32r-low.cc (the_low_target): Ditto.
1249 * linux-m68k-low.cc (the_low_target): Ditto.
1250 * linux-mips-low.cc (the_low_target): Ditto.
1251 * linux-nios2-low.cc (the_low_target): Ditto.
1252 * linux-ppc-low.cc (the_low_target): Ditto.
1253 * linux-s390-low.cc (the_low_target): Ditto.
1254 * linux-sh-low.cc (the_low_target): Ditto.
1255 * linux-sparc-low.cc (the_low_target): Ditto.
1256 * linux-tic6x-low.cc (the_low_target): Ditto.
1257 * linux-tile-low.cc (the_low_target): Ditto.
1258 * linux-xtensa-low.cc (the_low_target): Ditto.
1259 * linux-aarch64-low.cc (class aarch64_target)
1260 <breakpoint_kind_from_pc>
1261 <breakpoint_kind_from_current_state>: Declare.
1262 (aarch64_breakpoint_kind_from_pc): Turn into...
1263 (aarch64_target::breakpoint_kind_from_pc): ...this.
1264 (aarch64_breakpoint_kind_from_current_state): Turn into...
1265 (aarch64_target::breakpoint_kind_from_current_state): ...this.
1266 (the_low_target): Remove the op fields.
1267 * linux-arm-low.cc (class arm_target):
1268 <breakpoint_kind_from_pc>
1269 <breakpoint_kind_from_current_state>: Declare.
1270 (arm_target::breakpoint_kind_from_pc): Define.
1271 (arm_target::breakpoint_kind_from_current_state): Define.
1272 (the_low_target): Remove the op fields.
1273 * linux-riscv-low.cc (class riscv_target):
1274 <breakpoint_kind_from_pc>: Declare.
1275 (riscv_breakpoint_kind_from_pc): Turn into...
1276 (riscv_target::breakpoint_kind_from_pc): ...this.
1277 (the_low_target): Remove the op fields.
1279 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1281 Turn the 'get_pc' and 'set_pc' linux target ops into methods
1282 of linux_process_target.
1284 * linux-low.h (struct linux_target_ops): Remove the ops.
1285 (class linux_process_target) <low_supports_breakpoints>
1287 <low_set_pc>: Declare.
1288 * linux-low.cc (supports_breakpoints): Turn into...
1289 (linux_process_target::low_supports_breakpoints): ...this.
1290 (linux_process_target::low_get_pc): Define.
1291 (linux_process_target::low_set_pc): Define.
1293 Update the callers below.
1295 (linux_process_target::get_pc)
1296 (linux_process_target::save_stop_reason)
1297 (linux_process_target::maybe_move_out_of_jump_pad)
1298 (linux_process_target::wait_1)
1299 (linux_process_target::resume_one_lwp_throw)
1300 (linux_process_target::resume)
1301 (linux_process_target::proceed_all_lwps)
1302 (linux_process_target::read_pc)
1303 (linux_process_target::write_pc)
1305 * linux-x86-low.cc (class linux_process_target)
1306 <low_supports_breakpoints>
1308 <low_set_pc>: Declare.
1309 (x86_target::low_supports_breakpoints): Define.
1310 (x86_get_pc): Turn into...
1311 (x86_target::low_get_pc): ...this.
1312 (x86_set_pc): Turn into...
1313 (x86_target::low_set_pc): ...this.
1314 (the_low_target): Remove the op fields.
1315 * linux-arm-low.cc (class arm_target)
1316 <low_supports_breakpoints>
1318 <low_set_pc>: Declare.
1319 (arm_target::low_supports_breakpoints)
1320 (arm_target::low_get_pc)
1321 (arm_target::low_set_pc): Define.
1322 (the_low_target): Remove the op fields.
1323 * linux-bfin-low.cc (class bfin_target)
1324 <low_supports_breakpoints>
1326 <low_set_pc>: Declare.
1327 (bfin_target::low_supports_breakpoints)
1328 (bfin_target::low_get_pc)
1329 (bfin_target::low_set_pc): Define.
1330 (the_low_target): Remove the op fields.
1331 * linux-cris-low.cc (class cris_target)
1332 <low_supports_breakpoints>
1334 <low_set_pc>: Declare.
1335 (cris_target::low_supports_breakpoints)
1336 (cris_target::low_get_pc)
1337 (cris_target::low_set_pc): Define.
1338 (the_low_target): Remove the op fields.
1339 * linux-crisv32-low.cc (class crisv32_target)
1340 <low_supports_breakpoints>
1342 <low_set_pc>: Declare.
1343 (crisv32_target::low_supports_breakpoints)
1344 (crisv32_target::low_get_pc)
1345 (crisv32_target::low_set_pc): Define.
1346 (the_low_target): Remove the op fields.
1347 * linux-m32r-low.cc (class m32r_target)
1348 <low_supports_breakpoints>
1350 <low_set_pc>: Declare.
1351 (m32r_target::low_supports_breakpoints)
1352 (m32r_target::low_get_pc)
1353 (m32r_target::low_set_pc): Define.
1354 (the_low_target): Remove the op fields.
1355 * linux-m68k-low.cc (class m68k_target)
1356 <low_supports_breakpoints>
1358 <low_set_pc>: Declare.
1359 (m68k_target::low_supports_breakpoints)
1360 (m68k_target::low_get_pc)
1361 (m68k_target::low_set_pc): Define.
1362 (the_low_target): Remove the op fields.
1363 * linux-nios2-low.cc (class nios2_target)
1364 <low_supports_breakpoints>
1366 <low_set_pc>: Declare.
1367 (nios2_target::low_supports_breakpoints)
1368 (nios2_target::low_get_pc)
1369 (nios2_target::low_set_pc): Define.
1370 (the_low_target): Remove the op fields.
1371 * linux-sh-low.cc (class sh_target)
1372 <low_supports_breakpoints>
1374 <low_set_pc>: Declare.
1375 (sh_target::low_supports_breakpoints)
1376 (sh_target::low_get_pc)
1377 (sh_target::low_set_pc): Define.
1378 (the_low_target): Remove the op fields.
1379 * linux-xtensa-low.cc (class xtensa_target)
1380 <low_supports_breakpoints>
1382 <low_set_pc>: Declare.
1383 (xtensa_target::low_supports_breakpoints)
1384 (xtensa_target::low_get_pc)
1385 (xtensa_target::low_set_pc): Define.
1386 (the_low_target): Remove the op fields.
1387 * linux-sparc-low.cc (class sparc_target)
1388 <low_supports_breakpoints>
1389 <low_get_pc>: Declare.
1390 (sparc_target::low_supports_breakpoints)
1391 (sparc_target::low_get_pc): Define.
1392 (the_low_target): Remove the op fields.
1393 * linux-tile-low.cc (class tile_target)
1394 <low_supports_breakpoints>
1396 <low_set_pc>: Declare.
1397 (tile_target::low_supports_breakpoints)
1398 (tile_target::low_get_pc)
1399 (tile_target::low_set_pc): Define.
1400 (the_low_target): Remove the op fields.
1401 * linux-aarch64-low.cc (class aarch64_target)
1402 <low_supports_breakpoints>
1404 <low_set_pc>: Declare.
1405 (aarch64_target::low_supports_breakpoints): Define.
1406 (aarch64_get_pc): Turn into...
1407 (aarch64_target::low_get_pc): ...this.
1408 (aarch64_set_pc): Turn into...
1409 (aarch64_target::low_set_pc): ...this.
1410 (the_low_target): Remove the op fields.
1411 * linux-mips-low.cc (class mips_target)
1412 <low_supports_breakpoints>
1414 <low_set_pc>: Declare.
1415 (mips_target::low_supports_breakpoints): Define.
1416 (mips_get_pc): Turn into...
1417 (mips_target::low_get_pc): ...this.
1418 (mips_set_pc): Turn into...
1419 (mips_target::low_set_pc): ...this.
1420 (the_low_target): Remove the op fields.
1421 * linux-ppc-low.cc (class ppc_target)
1422 <low_supports_breakpoints>
1424 <low_set_pc>: Declare.
1425 (ppc_target::low_supports_breakpoints): Define.
1426 (ppc_get_pc): Turn into...
1427 (ppc_target::low_get_pc): ...this.
1428 (ppc_set_pc): Turn into...
1429 (ppc_target::low_set_pc): ...this.
1430 (the_low_target): Remove the op fields.
1431 * linux-riscv-low.cc (class riscv_target)
1432 <low_supports_breakpoints>
1434 <low_set_pc>: Declare.
1435 (riscv_target::low_supports_breakpoints): Define.
1436 (riscv_get_pc): Turn into...
1437 (riscv_target::low_get_pc): ...this.
1438 (riscv_set_pc): Turn into...
1439 (riscv_target::low_set_pc): ...this.
1440 (the_low_target): Remove the op fields.
1441 * linux-s390-low.cc (class s390_target)
1442 <low_supports_breakpoints>
1444 <low_set_pc>: Declare.
1445 (s390_target::low_supports_breakpoints): Define.
1446 (s390_get_pc): Turn into...
1447 (s390_target::low_get_pc): ...this.
1448 (s390_set_pc): Turn into...
1449 (s390_target::low_set_pc): ...this.
1450 (the_low_target): Remove the op fields.
1451 * linux-tic6x-low.cc (class tic6x_target)
1452 <low_supports_breakpoints>
1454 <low_set_pc>: Declare.
1455 (tic6x_target::low_supports_breakpoints): Define.
1456 (tic6x_get_pc): Turn into...
1457 (tic6x_target::low_get_pc): ...this.
1458 (tic6x_set_pc): Turn into...
1459 (tic6x_target::low_set_pc): ...this.
1460 (the_low_target): Remove the op fields.
1462 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1464 Turn some more static methods in linux-low into private methods
1465 of linux_process_target.
1467 * linux-low.cc (get_pc): Turn into...
1468 (linux_process_target::get_pc): ...this.
1469 (save_stop_reason): Turn into...
1470 (linux_process_target::save_stop_reason): ...this.
1471 (thread_still_has_status_pending_p): Turn into...
1472 (linux_process_target::thread_still_has_status_pending): ...this.
1473 (status_pending_p_callback): Turn into...
1474 (linux_process_target::status_pending_p_callback): ...this.
1475 (resume_stopped_resumed_lwps): Turn into...
1476 (linux_process_target::resume_stopped_resumed_lwps): ...this.
1477 (install_software_single_step_breakpoints): Turn into...
1478 (linux_process_target::install_software_single_step_breakpoints):
1480 (single_step): Turn into...
1481 (linux_process_target::single_step): ...this.
1482 (linux_resume_one_lwp_throw): Turn into...
1483 (linux_process_target::resume_one_lwp_throw): ...this.
1484 (linux_resume_one_lwp): Turn into...
1485 (linux_process_target::resume_one_lwp): ...this.
1486 (resume_status_pending_p): Turn into...
1487 (linux_process_target::resume_status_pending): ...this.
1488 (need_step_over_p): Turn into...
1489 (linux_process_target::thread_needs_step_over): ...this.
1490 (linux_resume_one_thread): Turn into...
1491 (linux_process_target::resume_one_thread): ...this.
1492 (proceed_one_lwp): Turn into...
1493 (linux_process_target::proceed_one_lwp): ...this.
1494 (unsuspend_and_proceed_one_lwp): Turn into...
1495 (linux_process_target::unsuspend_and_proceed_one_lwp): ...this.
1497 Update the calls/references to the above functions below.
1499 (linux_process_target::handle_extended_wait)
1500 (linux_process_target::filter_event)
1501 (linux_process_target::wait_for_event_filtered)
1502 (linux_process_target::wait_1)
1503 (linux_process_target::move_out_of_jump_pad)
1504 (linux_process_target::start_step_over)
1505 (linux_process_target::resume)
1506 (linux_process_target::proceed_all_lwps)
1507 (regsets_store_inferior_registers)
1508 (linux_process_target::store_register)
1510 * linux-low.h (class linux_process_target)
1513 <thread_still_has_status_pending>
1514 <status_pending_p_callback>
1515 <resume_stopped_resumed_lwps>
1516 <install_software_single_step_breakpoints>
1518 <resume_one_lwp_throw>
1520 <resume_status_pending>
1521 <thread_needs_step_over>
1524 <unsuspend_and_proceed_one_lwp>: Declare.
1526 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1528 Turn the 'fetch_register' linux target op into a method of
1529 linux_process_target.
1531 * linux-low.h (struct linux_target_ops) <fetch_register>: Remove.
1532 (class linux_process_target) <low_fetch_register>: Declare.
1533 * linux-x86-low.cc (the_low_target)
1534 * linux-aarch64-low.cc (the_low_target)
1535 * linux-arm-low.cc (the_low_target)
1536 * linux-bfin-low.cc (the_low_target)
1537 * linux-cris-low.cc (the_low_target)
1538 * linux-crisv32-low.cc (the_low_target)
1539 * linux-m32r-low.cc (the_low_target)
1540 * linux-m68k-low.cc (the_low_target)
1541 * linux-nios2-low.cc (the_low_target)
1542 * linux-ppc-low.cc (the_low_target)
1543 * linux-s390-low.cc (the_low_target)
1544 * linux-sh-low.cc (the_low_target)
1545 * linux-sparc-low.cc (the_low_target)
1546 * linux-tic6x-low.cc (the_low_target)
1547 * linux-tile-low.cc (the_low_target)
1548 * linux-xtensa-low.cc (the_low_target): Remove the op field.
1549 * linux-ia64-low.cc (class ia64_target) <low_fetch_register>:
1551 (ia64_fetch_register): Turn into...
1552 (ia64_target::low_fetch_register): ...this.
1553 (the_low_target): Remove the op field.
1554 * linux-mips-low.cc (class mips_target) <low_fetch_register>:
1556 (mips_fetch_register): Turn into...
1557 (mips_target::low_fetch_register): ...this.
1558 (the_low_target): Remove the op field.
1559 * linux-riscv-low.cc (class riscv_target) <low_fetch_register>:
1561 (riscv_fetch_register): Turn into...
1562 (riscv_target::low_fetch_register): ...this.
1563 (the_low_target): Remove the op field.
1565 Update the callers below.
1567 * linux-low.cc (linux_process_target::fetch_registers)
1568 (linux_process_target::low_fetch_register)
1570 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1572 Turn the 'cannot_fetch_register' and 'cannot_store_register'
1573 linux target ops into methods of linux_process_target.
1575 * linux-low.h (struct linux_target_ops): Remove the low target ops.
1576 (class linux_process_target) <fetch_register>
1578 <usr_fetch_inferior_registers>
1579 <usr_store_inferior_registers>
1580 <low_cannot_fetch_register>
1581 <low_cannot_fetch_register> Declare.
1582 * linux-low.cc (fetch_register): Turn into...
1583 (linux_process_target::fetch_register): ...this.
1584 (store_register): Turn into ...
1585 (linux_process_target::store_register): ...this.
1586 (usr_fetch_inferior_registers): Turn into...
1587 (linux_process_target::usr_fetch_inferior_registers): ...this.
1588 (usr_store_inferior_registers): Turn into...
1589 (linux_process_target::usr_store_inferior_registers): ...this.
1590 * linux-x86-low.cc (class x86_target)
1591 <low_cannot_fetch_register>
1592 <low_cannot_store_register>: Declare.
1593 (x86_cannot_store_register): Turn into...
1594 (x86_target::low_cannot_store_register): ...this.
1595 (x86_cannot_fetch_register): Turn into...
1596 (x86_target::low_cannot_fetch_register): ...this.
1597 (the_low_target): Remove the target op fields.
1598 * linux-aarch64-low.cc (class aarch64_target)
1599 <low_cannot_fetch_register>
1600 <low_cannot_store_register>: Declare.
1601 (aarch64_target::low_cannot_fetch_register)
1602 (aarch64_target::low_cannot_store_register): Define.
1603 (the_low_target): Remove the op fields.
1604 * linux-arm-low.cc (class arm_target)
1605 <low_cannot_fetch_register>
1606 <low_cannot_store_register>: Declare.
1607 (arm_cannot_fetch_register): Turn into...
1608 (arm_target::low_cannot_fetch_register): ...this.
1609 (arm_cannot_store_register): Turn into...
1610 (arm_target::low_cannot_store_register): ...this.
1611 (the_low_target): Remove the op fields.
1612 * linux-bfin-low.cc (class bfin_target)
1613 <low_cannot_fetch_register>
1614 <low_cannot_store_register>: Declare.
1615 (bfin_cannot_fetch_register): Turn into...
1616 (bfin_target::low_cannot_fetch_register): ...this.
1617 (bfin_cannot_store_register): Turn into...
1618 (bfin_target::low_cannot_store_register): ...this.
1619 (the_low_target): Remove the op fields.
1620 * linux-cris-low.cc (class cris_target)
1621 <low_cannot_fetch_register>
1622 <low_cannot_store_register>: Declare.
1623 (cris_cannot_fetch_register): Turn into...
1624 (cris_target::low_cannot_fetch_register): ...this.
1625 (cris_cannot_store_register): Turn into...
1626 (cris_target::low_cannot_store_register): ...this.
1627 (the_low_target): Remove the op fields.
1628 * linux-crisv32-low.cc (class crisv32_target)
1629 <low_cannot_fetch_register>
1630 <low_cannot_store_register>: Declare.
1631 (crisv32_target::low_cannot_fetch_register)
1632 (crisv32_target::low_cannot_store_register): Define.
1633 (the_low_target): Remove the op fields.
1634 * linux-ia64-low.cc (class ia64_target)
1635 <low_cannot_fetch_register>
1636 <low_cannot_store_register>: Declare.
1637 (ia64_cannot_fetch_register): Turn into...
1638 (ia64_target::low_cannot_fetch_register): ...this.
1639 (ia64_cannot_store_register): Turn into...
1640 (ia64_target::low_cannot_store_register): ...this.
1641 (the_low_target): Remove the op fields.
1642 * linux-m32r-low.cc (class m32r_target)
1643 <low_cannot_fetch_register>
1644 <low_cannot_store_register>: Declare.
1645 (m32r_cannot_fetch_register): Turn into...
1646 (m32r_target::low_cannot_fetch_register): ...this.
1647 (m32r_cannot_store_register): Turn into...
1648 (m32r_target::low_cannot_store_register): ...this.
1649 (the_low_target): Remove the op fields.
1650 * linux-m68k-low.cc (class m68k_target)
1651 <low_cannot_fetch_register>
1652 <low_cannot_store_register>: Declare.
1653 (m68k_cannot_fetch_register): Turn into...
1654 (m68k_target::low_cannot_fetch_register): ...this.
1655 (m68k_cannot_store_register): Turn into...
1656 (m68k_target::low_cannot_store_register): ...this.
1657 (the_low_target): Remove the op fields.
1658 * linux-mips-low.cc (class mips_target)
1659 <low_cannot_fetch_register>
1660 <low_cannot_store_register>: Declare.
1661 (mips_cannot_fetch_register): Turn into...
1662 (mips_target::low_cannot_fetch_register): ...this.
1663 (mips_cannot_store_register): Turn into...
1664 (mips_target::low_cannot_store_register): ...this.
1665 (get_usrregs_info): Inline at the call sites in
1666 low_cannot_fetch_register and low_cannot_store_register,
1668 (the_low_target): Remove the op fields.
1669 * linux-nios2-low.cc (class nios2_target)
1670 <low_cannot_fetch_register>
1671 <low_cannot_store_register>: Declare.
1672 (nios2_cannot_fetch_register): Turn into...
1673 (nios2_target::low_cannot_fetch_register): ...this.
1674 (nios2_cannot_store_register): Turn into...
1675 (nios2_target::low_cannot_store_register): ...this.
1676 (the_low_target): Remove the op fields.
1677 * linux-ppc-low.cc (class ppc_target)
1678 <low_cannot_fetch_register>
1679 <low_cannot_store_register>: Declare.
1680 (ppc_cannot_fetch_register): Turn into...
1681 (ppc_target::low_cannot_fetch_register): ...this.
1682 (ppc_cannot_store_register): Turn into...
1683 (ppc_target::low_cannot_store_register): ...this.
1684 (the_low_target): Remove the op fields.
1685 * linux-riscv-low.cc (class riscv_target)
1686 <low_cannot_fetch_register>
1687 <low_cannot_store_register>: Declare.
1688 (riscv_target::low_cannot_fetch_register)
1689 (riscv_target::low_cannot_store_register): Define.
1690 (the_low_target): Remove the op fields.
1691 * linux-s390-low.cc (class s390_target)
1692 <low_cannot_fetch_register>
1693 <low_cannot_store_register>: Declare.
1694 (s390_cannot_fetch_register): Turn into...
1695 (s390_target::low_cannot_fetch_register): ...this.
1696 (s390_cannot_store_register): Turn into...
1697 (s390_target::low_cannot_store_register): ...this.
1698 (the_low_target): Remove the op fields.
1699 * linux-sh-low.cc (class sh_target)
1700 <low_cannot_fetch_register>
1701 <low_cannot_store_register>: Declare.
1702 (sh_cannot_fetch_register): Turn into...
1703 (sh_target::low_cannot_fetch_register): ...this.
1704 (sh_cannot_store_register): Turn into...
1705 (sh_target::low_cannot_store_register): ...this.
1706 (the_low_target): Remove the op fields.
1707 * linux-sparc-low.cc (class sparc_target)
1708 <low_cannot_fetch_register>
1709 <low_cannot_store_register>: Declare.
1710 (sparc_cannot_fetch_register): Turn into...
1711 (sparc_target::low_cannot_fetch_register): ...this.
1712 (sparc_cannot_store_register): Turn into...
1713 (sparc_target::low_cannot_store_register): ...this.
1714 (the_low_target): Remove the op fields.
1715 * linux-tic6x-low.cc (class tic6x_target)
1716 <low_cannot_fetch_register>
1717 <low_cannot_store_register>: Declare.
1718 (tic6x_cannot_fetch_register): Turn into...
1719 (tic6x_target::low_cannot_fetch_register): ...this.
1720 (tic6x_cannot_store_register): Turn into...
1721 (tic6x_target::low_cannot_store_register): ...this.
1722 (the_low_target): Remove the op fields.
1723 * linux-tile-low.cc (class tile_target)
1724 <low_cannot_fetch_register>
1725 <low_cannot_store_register>: Declare.
1726 (tile_cannot_fetch_register): Turn into...
1727 (tile_target::low_cannot_fetch_register): ...this.
1728 (tile_cannot_store_register): Turn into...
1729 (tile_target::low_cannot_store_register): ...this.
1730 (the_low_target): Remove the op fields.
1731 * linux-xtensa-low.cc (class xtensa_target)
1732 <low_cannot_fetch_register>
1733 <low_cannot_store_register>: Declare.
1734 (xtensa_target::low_cannot_fetch_register)
1735 (xtensa_target::low_cannot_store_register): Define.
1736 (the_low_target): Remove the op fields.
1738 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1740 Turn the 'regs_info' linux target op into a method of
1741 linux_process_target.
1743 * linux-low.h (struct linux_target_ops) <regs_info>: Remove.
1744 (class linux_process_target) <get_regs_info>: Define.
1746 Update the callers below.
1748 * linux-low.cc (linux_process_target::fetch_registers)
1749 (linux_process_target::store_registers)
1750 * proc-service.cc (gregset_info)
1752 * linux-x86-low.cc (class x86_target) <get_regs_info>: Declare.
1753 (x86_linux_regs_info): Turn into ...
1754 (x86_target::get_regs_info): ...this.
1755 (the_low_target): Remove the op field.
1756 * linux-aarch64-low.cc (class aarch64_target) <get_regs_info>:
1758 (aarch64_regs_info): Turn into ...
1759 (aarch64_target::get_regs_info): ...this.
1760 (the_low_target): Remove the op field.
1761 * linux-arm-low.cc (class arm_target) <get_regs_info>: Declare.
1762 (arm_regs_info): Turn into ...
1763 (arm_target::get_regs_info): ...this.
1764 (the_low_target): Remove the op field.
1765 * linux-bfin-low.cc (class bfin_target) <get_regs_info>: Declare.
1766 (bfin_regs_info): Turn into ...
1767 (bfin_target::get_regs_info): ...this.
1768 (the_low_target): Remove the op field.
1769 * linux-cris-low.cc (class cris_target) <get_regs_info>: Declare.
1770 (cris_regs_info): Turn into ...
1771 (cris_target::get_regs_info): ...this.
1772 (the_low_target): Remove the op field.
1773 * linux-crisv32-low.cc (class crisv32_target) <get_regs_info>:
1775 (crisv32_regs_info): Turn into ...
1776 (crisv32_target::get_regs_info): ...this.
1777 (the_low_target): Remove the op field.
1778 * linux-ia64-low.cc (class ia64_target) <get_regs_info>: Declare.
1779 (ia64_regs_info): Turn into ...
1780 (ia64_target::get_regs_info): ...this.
1781 (the_low_target): Remove the op field.
1782 * linux-m32r-low.cc (class m32r_target) <get_regs_info>: Declare.
1783 (m32r_regs_info): Turn into ...
1784 (m32r_target::get_regs_info): ...this.
1785 (the_low_target): Remove the op field.
1786 * linux-m68k-low.cc (class m68k_target) <get_regs_info>: Declare.
1787 (m68k_regs_info): Turn into ...
1788 (m68k_target::get_regs_info): ...this.
1789 (the_low_target): Remove the op field.
1790 * linux-mips-low.cc (class mips_target) <get_regs_info>: Declare.
1791 (mips_regs_info): Turn into ...
1792 (mips_target::get_regs_info): ...this.
1793 (the_low_target): Remove the op field.
1794 (get_usrregs_info): Update the call to the op.
1795 * linux-nios2-low.cc (class nios2_target) <get_regs_info>: Declare.
1796 (nios2_regs_info): Turn into ...
1797 (nios2_target::get_regs_info): ...this.
1798 (the_low_target): Remove the op field.
1799 * linux-ppc-low.cc (class ppc_target) <get_regs_info>: Declare.
1800 (ppc_regs_info): Turn into ...
1801 (ppc_target::get_regs_info): ...this.
1802 (the_low_target): Remove the op field.
1803 * linux-riscv-low.cc (class riscv_target) <get_regs_info>: Declare.
1804 (riscv_regs_info): Turn into ...
1805 (riscv_target::get_regs_info): ...this.
1806 (the_low_target): Remove the op field.
1807 * linux-s390-low.cc (class s390_target) <get_regs_info>: Declare.
1808 (s390_regs_info): Turn into ...
1809 (s390_target::get_regs_info): ...this.
1810 (the_low_target): Remove the op field.
1811 (s390_collect_ptrace_register)
1812 (s390_supply_ptrace_register)
1813 (s390_fill_gregset): Update the call to the op.
1814 * linux-sh-low.cc (class sh_target) <get_regs_info>: Declare.
1815 (sh_regs_info): Turn into ...
1816 (sh_target::get_regs_info): ...this.
1817 (the_low_target): Remove the op field.
1818 * linux-sparc-low.cc (class sparc_target) <get_regs_info>: Declare.
1819 (sparc_regs_info): Turn into ...
1820 (sparc_target::get_regs_info): ...this.
1821 (the_low_target): Remove the op field.
1822 * linux-tic6x-low.cc (class tic6x_target) <get_regs_info>: Declare.
1823 (tic6x_regs_info): Turn into ...
1824 (tic6x_target::get_regs_info): ...this.
1825 (the_low_target): Remove the op field.
1826 * linux-tile-low.cc (class tile_target) <get_regs_info>: Declare.
1827 (tile_regs_info): Turn into ...
1828 (tile_target::get_regs_info): ...this.
1829 (the_low_target): Remove the op field.
1830 * linux-xtensa-low.cc (class xtensa_target) <get_regs_info>:
1832 (xtensa_regs_info): Turn into ...
1833 (xtensa_target::get_regs_info): ...this.
1834 (the_low_target): Remove the op field.
1836 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1838 Turn the 'arch_setup' linux target op into a method of
1839 linux_process_target.
1841 * linux-low.h (struct linux_target_ops) <arch_setup>: Delete.
1842 (class linux_process_target) <arch_setup_thread>
1843 <low_arch_setup>: New declarations.
1844 * linux-low.cc (linux_arch_setup): Delete.
1845 (linux_arch_setup_thread): Turn into...
1846 (linux_process_target::arch_setup_thread): ... this.
1848 Update the callers below.
1850 (linux_process_target::handle_extended_wait)
1851 (linux_process_target::post_create_inferior)
1852 (linux_process_target::filter_event)
1854 * linux-x86-low.cc (class x86_target) <low_arch_setup>: New
1856 (x86_linux_update_xmltarget): Turn into...
1857 (x86_target::update_xmltarget): ...this.
1858 (x86_linux_process_qsupported): Update the call to
1859 x86_linux_update_xmltarget.
1860 (x86_arch_setup): Turn into ...
1861 (x86_target::low_arch_setup): ...this.
1862 (the_low_target): Remove the op field.
1863 * linux-aarch64-low.cc (class aarch64_target) <low_arch_setup>: New
1865 (aarch64_arch_setup): Turn into ...
1866 (aarch64_target::low_arch_setup): ...this.
1867 (the_low_target): Remove the op field.
1868 * linux-arm-low.cc (class arm_target) <low_arch_setup>: New
1870 (arm_arch_setup): Turn into ...
1871 (arm_target::low_arch_setup): ...this.
1872 (the_low_target): Remove the op field.
1873 * linux-bfin-low.cc (class bfin_target) <low_arch_setup>: New
1875 (bfin_arch_setup): Turn into ...
1876 (bfin_target::low_arch_setup): ...this.
1877 (the_low_target): Remove the op field.
1878 * linux-cris-low.cc (class cris_target) <low_arch_setup>: New
1880 (cris_arch_setup): Turn into ...
1881 (cris_target::low_arch_setup): ...this.
1882 (the_low_target): Remove the op field.
1883 * linux-crisv32-low.cc (class crisv32_target) <low_arch_setup>: New
1885 (crisv32_arch_setup): Turn into ...
1886 (crisv32_target::low_arch_setup): ...this.
1887 (the_low_target): Remove the op field.
1888 * linux-ia64-low.cc (class ia64_target) <low_arch_setup>: New
1890 (ia64_arch_setup): Turn into ...
1891 (ia64_target::low_arch_setup): ...this.
1892 (the_low_target): Remove the op field.
1893 * linux-m32r-low.cc (class m32r_target) <low_arch_setup>: New
1895 (m32r_arch_setup): Turn into ...
1896 (m32r_target::low_arch_setup): ...this.
1897 (the_low_target): Remove the op field.
1898 * linux-m68k-low.cc (class m68k_target) <low_arch_setup>: New
1900 (m68k_arch_setup): Turn into ...
1901 (m68k_target::low_arch_setup): ...this.
1902 (the_low_target): Remove the op field.
1903 * linux-mips-low.cc (class mips_target) <low_arch_setup>: New
1905 (mips_arch_setup): Turn into ...
1906 (mips_target::low_arch_setup): ...this.
1907 (the_low_target): Remove the op field.
1908 * linux-nios2-low.cc (class nios2_target) <low_arch_setup>: New
1910 (nios2_arch_setup): Turn into ...
1911 (nios2_target::low_arch_setup): ...this.
1912 (the_low_target): Remove the op field.
1913 * linux-ppc-low.cc (class ppc_target) <low_arch_setup>: New
1915 (ppc_arch_setup): Turn into ...
1916 (ppc_target::low_arch_setup): ...this.
1917 (the_low_target): Remove the op field.
1918 * linux-riscv-low.cc (class riscv_target) <low_arch_setup>: New
1920 (riscv_arch_setup): Turn into ...
1921 (riscv_target::low_arch_setup): ...this.
1922 (the_low_target): Remove the op field.
1923 * linux-s390-low.cc (class s390_target) <low_arch_setup>: New
1925 (s390_arch_setup): Turn into ...
1926 (s390_target::low_arch_setup): ...this.
1927 (the_low_target): Remove the op field.
1928 * linux-sh-low.cc (class sh_target) <low_arch_setup>: New
1930 (sh_arch_setup): Turn into ...
1931 (sh_target::low_arch_setup): ...this.
1932 (the_low_target): Remove the op field.
1933 * linux-sparc-low.cc (class sparc_target) <low_arch_setup>: New
1935 (sparc_arch_setup): Turn into ...
1936 (sparc_target::low_arch_setup): ...this.
1937 (the_low_target): Remove the op field.
1938 * linux-tic6x-low.cc (class tic6x_target) <low_arch_setup>: New
1940 (tic6x_arch_setup): Turn into ...
1941 (tic6x_target::low_arch_setup): ...this.
1942 (the_low_target): Remove the op field.
1943 * linux-tile-low.cc (class tile_target) <low_arch_setup>: New
1945 (tile_arch_setup): Turn into ...
1946 (tile_target::low_arch_setup): ...this.
1947 (the_low_target): Remove the op field.
1948 * linux-xtensa-low.cc (class xtensa_target) <low_arch_setup>: New
1950 (xtensa_arch_setup): Turn into ...
1951 (xtensa_target::low_arch_setup): ...this.
1952 (the_low_target): Remove the op field.
1954 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1956 * linux-low.h (the_linux_target): New extern declaration.
1957 * linux-low.cc (initialize_low): Use 'the_linux_target' to set
1959 (the_linux_target): Remove.
1960 * linux-x86-low.cc (class x86_target): New class.
1961 (the_x86_target): New static object.
1962 (the_linux_target): Define as pointer to the_x86_target.
1963 * linux-aarch64-low.cc (class aarch64_target): New class.
1964 (the_aarch64_target): New static object.
1965 (the_linux_target): Define as pointer to the_aarch64_target.
1966 * linux-arm-low.cc (class arm_target): New class.
1967 (the_arm_target): New static object.
1968 (the_linux_target): Define as pointer to the_arm_target.
1969 * linux-bfin-low.cc (class bfin_target): New class.
1970 (the_bfin_target): New static object.
1971 (the_linux_target): Define as pointer to the_bfin_target.
1972 * linux-cris-low.cc (class cris_target): New class.
1973 (the_cris_target): New static object.
1974 (the_linux_target): Define as pointer to the_cris_target.
1975 * linux-crisv32-low.cc (class crisv32_target): New class.
1976 (the_crisv32_target): New static object.
1977 (the_linux_target): Define as pointer to the_crisv32_target.
1978 * linux-ia64-low.cc (class ia64_target): New class.
1979 (the_ia64_target): New static object.
1980 (the_linux_target): Define as pointer to the_ia64_target.
1981 * linux-m32r-low.cc (class m32r_target): New class.
1982 (the_m32r_target): New static object.
1983 (the_linux_target): Define as pointer to the_m32r_target.
1984 * linux-m68k-low.cc (class m68k_target): New class.
1985 (the_m68k_target): New static object.
1986 (the_linux_target): Define as pointer to the_m68k_target.
1987 * linux-mips-low.cc (class mips_target): New class.
1988 (the_mips_target): New static object.
1989 (the_linux_target): Define as pointer to the_mips_target.
1990 * linux-nios2-low.cc (class nios2_target): New class.
1991 (the_nios2_target): New static object.
1992 (the_linux_target): Define as pointer to the_nios2_target.
1993 * linux-ppc-low.cc (class ppc_target): New class.
1994 (the_ppc_target): New static object.
1995 (the_linux_target): Define as pointer to the_ppc_target.
1996 * linux-riscv-low.cc (class riscv_target): New class.
1997 (the_riscv_target): New static object.
1998 (the_linux_target): Define as pointer to the_riscv_target.
1999 * linux-s390-low.cc (class s390_target): New class.
2000 (the_s390_target): New static object.
2001 (the_linux_target): Define as pointer to the_s390_target.
2002 * linux-sh-low.cc (class sh_target): New class.
2003 (the_sh_target): New static object.
2004 (the_linux_target): Define as pointer to the_sh_target.
2005 * linux-sparc-low.cc (class sparc_target): New class.
2006 (the_sparc_target): New static object.
2007 (the_linux_target): Define as pointer to the_sparc_target.
2008 * linux-tic6x-low.cc (class tic6x_target): New class.
2009 (the_tic6x_target): New static object.
2010 (the_linux_target): Define as pointer to the_tic6x_target.
2011 * linux-tile-low.cc (class tile_target): New class.
2012 (the_tile_target): New static object.
2013 (the_linux_target): Define as pointer to the_tile_target.
2014 * linux-xtensa-low.cc (class xtensa_target): New class.
2015 (the_xtensa_target): New static object.
2016 (the_linux_target): Define as pointer to the_xtensa_target.
2018 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2020 Turn some static functions in linux-low.cc into private methods of
2021 linux_process_target.
2023 * linux-low.cc (handle_extended_wait): Turn into ...
2024 (linux_process_target::handle_extended_wait): ...this. Call
2025 'mourn' on 'this' object instead of 'the_target'.
2026 (maybe_move_out_of_jump_pad): Turn into...
2027 (linux_process_target::maybe_move_out_of_jump_pad): ...this.
2028 (linux_low_filter_event): Turn into...
2029 (linux_process_target::filter_event): ...this.
2030 (linux_wait_for_event_filtered): Turn into...
2031 (linux_process_target::wait_for_event_filtered): ...this.
2032 (linux_wait_for_event): Turn into...
2033 (linux_process_target::wait_for_event): ...this.
2034 (linux_wait_1): Turn into...
2035 (linux_process_target::wait_1): ...this.
2036 (wait_for_sigstop): Turn into...
2037 (linux_process_target::wait_for_sigstop): ...this.
2038 (move_out_of_jump_pad_callback): Turn into...
2039 (linux_process_target::move_out_of_jump_pad): ...this.
2040 (stop_all_lwps): Turn into...
2041 (linux_process_target::stop_all_lwps): ...this.
2042 (start_step_over): Turn into...
2043 (linux_process_target::start_step_over): ...this.
2044 (complete_ongoing_step_over): Turn into...
2045 (linux_process_target::complete_ongoing_step_over): ...this.
2046 (proceed_all_lwps): Turn into...
2047 (linux_process_target::proceed_all_lwps): ...this.
2048 (unstop_all_lwps): Turn into...
2049 (linux_process_target::unstop_all_lwps): ...this.
2051 * linux-low.h (class linux_process_target)
2052 <handle_extended_wait>
2053 <maybe_move_out_of_jump_pad>
2055 <wait_for_event_filtered>
2059 <move_out_of_jump_pad>
2062 <complete_ongoing_step_over>
2064 <unstop_all_lwps>: Declare.
2066 Update the callers below.
2068 * linux-low.cc (linux_process_target::attach): Update.
2069 (linux_process_target::stabilize_threads): Ditto.
2070 (linux_process_target::wait): Ditto.
2072 2020-04-02 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2074 * linux-low.h (struct linux_target_ops): Update the comment for
2075 'cannot_store_register' to return 0 or 1.
2076 * linux-ppc-low.cc (ppc_cannot_store_register): Return 1 instead
2079 2020-03-20 Simon Marchi <simon.marchi@efficios.com>
2081 * config.in: Re-generate.
2082 * configure: Re-generate.
2084 2020-03-17 Kamil Rytarowski <n54@gmx.com>
2086 * regcache.cc (find_register_by_number): Update.
2087 * tdesc.cc (init_target_desc): Likewise.
2088 * tdesc.h (target_desc::reg_defs): Likewise.
2090 2020-03-12 Tom Tromey <tom@tromey.com>
2092 * configure: Rebuild.
2093 * configure.ac (GDBSERVER_DEPFILES): Remove srv_selftest_objs.
2094 (WIN32APILIBS): New subst.
2095 * Makefile.in (SFILES, OBS, TAGS, GDBREPLAY_OBS): Remove
2097 (gdbsupport/%.o): Remove target.
2098 (GDBSUPPORT_BUILDDIR, GDBSUPPORT): New variables.
2099 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Add GDBSUPPORT.
2100 (WIN32APILIBS): New variable.
2101 (gdbserver$(EXEEXT)): Add WIN32APILIBS.
2102 (gdbreplay$(EXEEXT)): Likewise.
2104 2020-03-12 Tom Tromey <tom@tromey.com>
2106 * config.in, configure: Rebuild.
2107 * configure.ac: Call ZW_GNU_GETTEXT_SISTER_DIR.
2108 * acinclude.m4: Include gettext-sister.m4.
2109 * Makefile.in (top_builddir, INTL, INTL_DEPS, INTL_CFLAGS): New
2111 (INCLUDE_CFLAGS): Add INTL_CFLAGS.
2112 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Use INTL_DEPS, INTL.
2114 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
2116 * acinclude.m4: Update path to selftest.m4.
2118 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
2120 * configure.ac: Don't source bfd/development.sh, move
2121 GDB_AC_COMMON higher.
2122 * configure: Re-generate.
2124 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
2126 * configure: Re-generate.
2128 2020-03-11 Simon Marchi <simon.marchi@efficios.com>
2130 * configure: Re-generate.
2132 2020-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
2134 * .dir-locals.el: New file.
2136 2020-03-05 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2138 * .gitattributes: New file.
2140 2020-03-02 Andrew Burgess <andrew.burgess@embecosm.com>
2142 * remote-utils.cc (prepare_resume_reply): Add ability to convert T
2143 reply into an S reply.
2144 * server.cc (disable_packet_T): New global.
2145 (captured_main): Set new global when appropriate.
2146 * server.h (disable_packet_T): Declare.
2148 2020-02-21 Tom Tromey <tom@tromey.com>
2150 * Makefile.in (mostlyclean): New target.
2152 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2154 * target.h (struct process_stratum_target): Remove.
2155 (class process_target): Rename to ...
2156 (class process_stratum_target): ... this.
2157 * linux-low.h (class linux_process_target): Derive from
2158 'process_stratum_target'.
2159 * linux-low.cc (linux_target_ops): Remove.
2160 (initialize_low): Set the_target to the singleton instance of
2161 linux_process_target.
2162 * lynx-low.h (class lynx_process_target): Derive from
2163 'process_stratum_target'.
2164 * lynx-low.cc (lynx_target_ops): Remove.
2165 (initialize_low): Set the_target to the singleton instance of
2166 lynx_process_target.
2167 * nto-low.h (class nto_process_target): Derive from
2168 'process_stratum_target'.
2169 * nto-low.cc (nto_target_ops): Remove.
2170 (initialize_low): Set the_target to the singleton instance of
2172 * win32-low.h (class win32_process_target): Derive from
2173 'process_stratum_target'.
2174 * win32-low.cc (win32_target_ops): Remove.
2175 (initialize_low): Set the_target to the singleton instance of
2176 win32_process_target.
2178 Replace 'the_target->pt' with 'the_target' in the uses below.
2180 * hostio.cc (hostio_error)
2185 * linux-aarch32-low.cc (arm_breakpoint_at)
2186 * linux-aarch64-low.cc (aarch64_breakpoint_at)
2187 * linux-arm-low.cc (arm_sigreturn_next_pc)
2189 (arm_get_syscall_trapinfo)
2190 * linux-cris-low.cc (cris_breakpoint_at)
2191 * linux-crisv32-low.cc (cris_breakpoint_at)
2192 * linux-low.cc (handle_extended_wait)
2195 (linux_process_target::breakpoint_kind_from_pc)
2197 * linux-m32r-low.cc (m32r_breakpoint_at)
2198 * linux-mips-low.cc (mips_breakpoint_at)
2199 * linux-nios2-low.cc (nios2_breakpoint_at)
2200 * linux-ppc-low.cc (ppc_breakpoint_at)
2201 * linux-s390-low.cc (s390_get_hwcap)
2202 * linux-sh-low.cc (sh_breakpoint_at)
2203 * linux-sparc-low.cc (sparc_fill_gregset_to_stack)
2204 (sparc_store_gregset_from_stack)
2205 (sparc_breakpoint_at)
2206 * linux-tic6x-low.cc (tic6x_breakpoint_at)
2207 * linux-tile-low.cc (tile_breakpoint_at)
2208 * linux-x86-low.cc (x86_breakpoint_at)
2209 * linux-xtensa-low.cc (xtensa_breakpoint_at)
2210 * mem-break.cc (bp_size)
2212 (insert_memory_breakpoint)
2213 (set_raw_breakpoint_at)
2214 (delete_raw_breakpoint)
2216 (uninsert_raw_breakpoint)
2217 (reinsert_raw_breakpoint)
2218 (validate_inserted_breakpoint)
2219 * regcache.cc (regcache_read_pc)
2221 * remote-utils.cc (putpkt_binary_1)
2224 (prepare_resume_reply)
2225 * server.cc (handle_general_set)
2228 (handle_qxfer_exec_file)
2229 (handle_qxfer_libraries_svr4)
2230 (handle_qxfer_osdata)
2231 (handle_qxfer_siginfo)
2232 (handle_qxfer_fdpic)
2236 (queue_stop_reply_callback)
2238 * target.cc (prepare_to_access_memory)
2239 (done_accessing_memory)
2240 (read_inferior_memory)
2241 (target_write_memory)
2242 (target_stop_and_wait)
2244 (target_mourn_inferior)
2245 (target_continue_no_signal)
2247 (target_supports_multi_process)
2250 (target_create_inferior)
2251 (target_post_create_inferior)
2253 (target_supports_fork_events)
2254 (target_supports_vfork_events)
2255 (target_supports_exec_events)
2256 (target_handle_new_gdb_connection)
2259 (fetch_inferior_registers)
2260 (store_inferior_registers)
2262 (target_supports_non_stop)
2264 (target_process_qsupported)
2265 (target_supports_catch_syscall)
2266 (target_get_ipa_tdesc_idx)
2267 (target_supports_tracepoints)
2268 (target_supports_fast_tracepoints)
2269 (target_get_min_fast_tracepoint_insn_len)
2270 (target_thread_stopped)
2272 (target_unpause_all)
2273 (target_stabilize_threads)
2274 (target_install_fast_tracepoint_jump_pad)
2276 (target_supports_disable_randomization)
2277 (target_supports_agent)
2278 (target_enable_btrace)
2279 (target_disable_btrace)
2280 (target_read_btrace)
2281 (target_read_btrace_conf)
2282 (target_supports_range_stepping)
2283 (target_supports_stopped_by_sw_breakpoint)
2284 (target_stopped_by_sw_breakpoint)
2285 (target_supports_stopped_by_hw_breakpoint)
2286 (target_supports_hardware_single_step)
2287 (target_stopped_by_hw_breakpoint)
2288 (target_breakpoint_kind_from_pc)
2289 (target_breakpoint_kind_from_current_state)
2290 (target_supports_software_single_step)
2291 (target_core_of_thread)
2292 (target_thread_name)
2293 (target_thread_handle)
2294 * win32-low.cc (do_initial_child_stuff)
2296 Rename target op default definitions listed below.
2298 * target.cc (process_target::post_create_inferior): Rename as ...
2299 (process_stratum_target::post_create_inferior): ... this.
2300 (process_target::prepare_to_access_memory): Rename as ...
2301 (process_stratum_target::prepare_to_access_memory): ... this.
2302 (process_target::done_accessing_memory): Rename as ...
2303 (process_stratum_target::done_accessing_memory): ... this.
2304 (process_target::look_up_symbols): Rename as ...
2305 (process_stratum_target::look_up_symbols): ... this.
2306 (process_target::supports_read_auxv): Rename as ...
2307 (process_stratum_target::supports_read_auxv): ... this.
2308 (process_target::read_auxv): Rename as ...
2309 (process_stratum_target::read_auxv): ... this.
2310 (process_target::supports_z_point_type): Rename as ...
2311 (process_stratum_target::supports_z_point_type): ... this.
2312 (process_target::insert_point): Rename as ...
2313 (process_stratum_target::insert_point): ... this.
2314 (process_target::remove_point): Rename as ...
2315 (process_stratum_target::remove_point): ... this.
2316 (process_target::stopped_by_sw_breakpoint): Rename as ...
2317 (process_stratum_target::stopped_by_sw_breakpoint): ... this.
2318 (process_target::supports_stopped_by_sw_breakpoint): Rename as ...
2319 (process_stratum_target::supports_stopped_by_sw_breakpoint): ... this.
2320 (process_target::stopped_by_hw_breakpoint): Rename as ...
2321 (process_stratum_target::stopped_by_hw_breakpoint): ... this.
2322 (process_target::supports_stopped_by_hw_breakpoint): Rename as ...
2323 (process_stratum_target::supports_stopped_by_hw_breakpoint): ... this.
2324 (process_target::supports_hardware_single_step): Rename as ...
2325 (process_stratum_target::supports_hardware_single_step): ... this.
2326 (process_target::stopped_by_watchpoint): Rename as ...
2327 (process_stratum_target::stopped_by_watchpoint): ... this.
2328 (process_target::stopped_data_address): Rename as ...
2329 (process_stratum_target::stopped_data_address): ... this.
2330 (process_target::supports_read_offsets): Rename as ...
2331 (process_stratum_target::supports_read_offsets): ... this.
2332 (process_target::read_offsets): Rename as ...
2333 (process_stratum_target::read_offsets): ... this.
2334 (process_target::supports_get_tls_address): Rename as ...
2335 (process_stratum_target::supports_get_tls_address): ... this.
2336 (process_target::get_tls_address): Rename as ...
2337 (process_stratum_target::get_tls_address): ... this.
2338 (process_target::hostio_last_error): Rename as ...
2339 (process_stratum_target::hostio_last_error): ... this.
2340 (process_target::supports_qxfer_osdata): Rename as ...
2341 (process_stratum_target::supports_qxfer_osdata): ... this.
2342 (process_target::qxfer_osdata): Rename as ...
2343 (process_stratum_target::qxfer_osdata): ... this.
2344 (process_target::supports_qxfer_siginfo): Rename as ...
2345 (process_stratum_target::supports_qxfer_siginfo): ... this.
2346 (process_target::qxfer_siginfo): Rename as ...
2347 (process_stratum_target::qxfer_siginfo): ... this.
2348 (process_target::supports_non_stop): Rename as ...
2349 (process_stratum_target::supports_non_stop): ... this.
2350 (process_target::async): Rename as ...
2351 (process_stratum_target::async): ... this.
2352 (process_target::start_non_stop): Rename as ...
2353 (process_stratum_target::start_non_stop): ... this.
2354 (process_target::supports_multi_process): Rename as ...
2355 (process_stratum_target::supports_multi_process): ... this.
2356 (process_target::supports_fork_events): Rename as ...
2357 (process_stratum_target::supports_fork_events): ... this.
2358 (process_target::supports_vfork_events): Rename as ...
2359 (process_stratum_target::supports_vfork_events): ... this.
2360 (process_target::supports_exec_events): Rename as ...
2361 (process_stratum_target::supports_exec_events): ... this.
2362 (process_target::handle_new_gdb_connection): Rename as ...
2363 (process_stratum_target::handle_new_gdb_connection): ... this.
2364 (process_target::handle_monitor_command): Rename as ...
2365 (process_stratum_target::handle_monitor_command): ... this.
2366 (process_target::core_of_thread): Rename as ...
2367 (process_stratum_target::core_of_thread): ... this.
2368 (process_target::supports_read_loadmap): Rename as ...
2369 (process_stratum_target::supports_read_loadmap): ... this.
2370 (process_target::read_loadmap): Rename as ...
2371 (process_stratum_target::read_loadmap): ... this.
2372 (process_target::process_qsupported): Rename as ...
2373 (process_stratum_target::process_qsupported): ... this.
2374 (process_target::supports_tracepoints): Rename as ...
2375 (process_stratum_target::supports_tracepoints): ... this.
2376 (process_target::read_pc): Rename as ...
2377 (process_stratum_target::read_pc): ... this.
2378 (process_target::write_pc): Rename as ...
2379 (process_stratum_target::write_pc): ... this.
2380 (process_target::supports_thread_stopped): Rename as ...
2381 (process_stratum_target::supports_thread_stopped): ... this.
2382 (process_target::thread_stopped): Rename as ...
2383 (process_stratum_target::thread_stopped): ... this.
2384 (process_target::supports_get_tib_address): Rename as ...
2385 (process_stratum_target::supports_get_tib_address): ... this.
2386 (process_target::get_tib_address): Rename as ...
2387 (process_stratum_target::get_tib_address): ... this.
2388 (process_target::pause_all): Rename as ...
2389 (process_stratum_target::pause_all): ... this.
2390 (process_target::unpause_all): Rename as ...
2391 (process_stratum_target::unpause_all): ... this.
2392 (process_target::stabilize_threads): Rename as ...
2393 (process_stratum_target::stabilize_threads): ... this.
2394 (process_target::supports_fast_tracepoints): Rename as ...
2395 (process_stratum_target::supports_fast_tracepoints): ... this.
2396 (process_target::get_min_fast_tracepoint_insn_len): Rename as ...
2397 (process_stratum_target::get_min_fast_tracepoint_insn_len): ... this.
2398 (process_target::emit_ops): Rename as ...
2399 (process_stratum_target::emit_ops): ... this.
2400 (process_target::supports_disable_randomization): Rename as ...
2401 (process_stratum_target::supports_disable_randomization): ... this.
2402 (process_target::supports_qxfer_libraries_svr4): Rename as ...
2403 (process_stratum_target::supports_qxfer_libraries_svr4): ... this.
2404 (process_target::qxfer_libraries_svr4): Rename as ...
2405 (process_stratum_target::qxfer_libraries_svr4): ... this.
2406 (process_target::supports_agent): Rename as ...
2407 (process_stratum_target::supports_agent): ... this.
2408 (process_target::enable_btrace): Rename as ...
2409 (process_stratum_target::enable_btrace): ... this.
2410 (process_target::disable_btrace): Rename as ...
2411 (process_stratum_target::disable_btrace): ... this.
2412 (process_target::read_btrace): Rename as ...
2413 (process_stratum_target::read_btrace): ... this.
2414 (process_target::read_btrace_conf): Rename as ...
2415 (process_stratum_target::read_btrace_conf): ... this.
2416 (process_target::supports_range_stepping): Rename as ...
2417 (process_stratum_target::supports_range_stepping): ... this.
2418 (process_target::supports_pid_to_exec_file): Rename as ...
2419 (process_stratum_target::supports_pid_to_exec_file): ... this.
2420 (process_target::pid_to_exec_file): Rename as ...
2421 (process_stratum_target::pid_to_exec_file): ... this.
2422 (process_target::supports_multifs): Rename as ...
2423 (process_stratum_target::supports_multifs): ... this.
2424 (process_target::multifs_open): Rename as ...
2425 (process_stratum_target::multifs_open): ... this.
2426 (process_target::multifs_unlink): Rename as ...
2427 (process_stratum_target::multifs_unlink): ... this.
2428 (process_target::multifs_readlink): Rename as ...
2429 (process_stratum_target::multifs_readlink): ... this.
2430 (process_target::breakpoint_kind_from_pc): Rename as ...
2431 (process_stratum_target::breakpoint_kind_from_pc): ... this.
2432 (process_target::breakpoint_kind_from_current_state): Rename as ...
2433 (process_stratum_target::breakpoint_kind_from_current_state): ... this.
2434 (process_target::thread_name): Rename as ...
2435 (process_stratum_target::thread_name): ... this.
2436 (process_target::thread_handle): Rename as ...
2437 (process_stratum_target::thread_handle): ... this.
2438 (process_target::supports_software_single_step): Rename as ...
2439 (process_stratum_target::supports_software_single_step): ... this.
2440 (process_target::supports_catch_syscall): Rename as ...
2441 (process_stratum_target::supports_catch_syscall): ... this.
2442 (process_target::get_ipa_tdesc_idx): Rename as ...
2443 (process_stratum_target::get_ipa_tdesc_idx): ... this.
2445 2020-02-20 Pedro Alves <palves@redhat.com>
2447 * target.cc (set_target_ops): Simply copy the given target pointer
2448 instead of creating a copy of the pointed object.
2450 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2452 Turn process_stratum_target's get_ipa_tdesc_idx op into a method
2455 * target.h (struct process_stratum_target): Remove the target op.
2456 (class process_target): Add the target op.
2457 (target_get_ipa_tdesc_idx): Update the macro.
2458 * target.cc (process_target::get_ipa_tdesc_idx): Define.
2460 Update the derived classes and callers below.
2462 * linux-low.cc (linux_target_ops): Update.
2463 (linux_get_ipa_tdesc_idx): Turn into ...
2464 (linux_process_target::get_ipa_tdesc_idx): ... this.
2465 * linux-low.h (class linux_process_target): Update.
2466 * lynx-low.cc (lynx_target_ops): Update.
2467 * nto-low.cc (nto_target_ops): Update.
2468 * win32-low.cc (win32_target_ops): Update.
2470 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2472 Turn process_stratum_target's supports_catch_syscall op into a
2473 method of process_target.
2475 * target.h (struct process_stratum_target): Remove the target op.
2476 (class process_target): Add the target op.
2477 (target_supports_catch_syscall): Update the macro.
2478 * target.cc (process_target::supports_catch_syscall): Define.
2480 Update the derived classes and callers below.
2482 * linux-low.cc (linux_target_ops): Update.
2483 (linux_supports_catch_syscall): Turn into ...
2484 (linux_process_target::supports_catch_syscall): ... this.
2485 * linux-low.h (class linux_process_target): Update.
2486 * lynx-low.cc (lynx_target_ops): Update.
2487 * nto-low.cc (nto_target_ops): Update.
2488 * win32-low.cc (win32_target_ops): Update.
2490 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2492 Turn process_stratum_target's supports_software_single_step op
2493 into a method of process_target.
2495 * target.h (struct process_stratum_target): Remove the target op.
2496 (class process_target): Add the target op.
2497 (target_supports_software_single_step): Update the macro.
2498 * target.cc (process_target::supports_software_single_step): Define.
2500 Update the derived classes and callers below.
2502 * linux-low.cc (linux_target_ops): Update.
2503 (linux_supports_software_single_step): Turn into ...
2504 (linux_process_target::supports_software_single_step): ... this.
2505 * linux-low.h (class linux_process_target): Update.
2506 * lynx-low.cc (lynx_target_ops): Update.
2507 * nto-low.cc (nto_target_ops): Update.
2508 * win32-low.cc (win32_target_ops): Update.
2510 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2512 Turn process_stratum_target's thread_name and thread_handle ops
2513 into methods of process_target.
2515 * target.h (struct process_stratum_target): Remove the target ops.
2516 (class process_target): Add the target ops.
2517 (target_thread_name): Update the macro.
2518 (target_thread_handle): Update the macro.
2519 * target.cc (process_target::thread_name): Define.
2520 (process_target::thread_handle): Define.
2522 Update the derived classes and callers below.
2524 * linux-low.cc (linux_target_ops): Update.
2525 (linux_process_target::thread_name): Define.
2526 (linux_process_target::thread_handle): Define.
2527 * linux-low.h (class linux_process_target): Update.
2528 * lynx-low.cc (lynx_target_ops): Update.
2529 * nto-low.cc (nto_target_ops): Update.
2530 * win32-low.cc (win32_target_ops): Update.
2532 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2534 Turn process_stratum_target's breakpoint_kind_from_pc,
2535 sw_breakpoint_from_kind, and breakpoint_kind_from_current_state
2536 ops into methods of process_target.
2538 * target.h (struct process_stratum_target): Remove the target op.
2539 (class process_target): Add the target op.
2540 (target_breakpoint_kind_from_pc): Update the macro.
2541 (target_breakpoint_kind_from_current_state): Update the macro.
2542 (default_breakpoint_kind_from_pc): Remove declaration.
2543 * target.cc (default_breakpoint_kind_from_pc): Turn into ...
2544 (process_target::breakpoint_kind_from_pc): ... this.
2545 (process_target::breakpoint_kind_from_current_state): Define.
2547 Update the derived classes and callers below.
2549 * mem-break.cc (bp_size): Update.
2550 (bp_opcode): Update.
2551 * linux-low.cc (linux_target_ops): Update.
2552 (linux_wait_1): Update.
2553 (linux_breakpoint_kind_from_pc): Turn into ...
2554 (linux_process_target::breakpoint_kind_from_pc): ... this.
2555 (linux_sw_breakpoint_from_kind): Turn into ...
2556 (linux_process_target::sw_breakpoint_from_kind): ... this.
2557 (linux_breakpoint_kind_from_current_state): Turn into ...
2558 (linux_process_target::breakpoint_kind_from_current_state): ... this.
2559 * linux-low.h (class linux_process_target): Update.
2560 * lynx-low.cc (lynx_target_ops): Update.
2561 (lynx_process_target::sw_breakpoint_from_kind): Define.
2562 * lynx-low.h (class lynx_process_target): Update.
2563 * nto-low.cc (nto_target_ops): Update.
2564 (nto_sw_breakpoint_from_kind): Turn into ...
2565 (nto_process_target::sw_breakpoint_from_kind): ... this.
2566 * nto-low.h (class nto_process_target): Update.
2567 * win32-low.cc (win32_target_ops): Update.
2568 (win32_sw_breakpoint_from_kind): Turn into ...
2569 (win32_process_target::sw_breakpoint_from_kind): ... this.
2570 * win32-low.h (class win32_process_target): Update.
2572 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2574 Turn process_stratum_target's multifs_open, multifs_readlink,
2575 multifs_unlink ops into methods of process_target.
2577 * target.h (struct process_stratum_target): Remove the target ops.
2578 (class process_target): Add the target ops. Also add
2580 * target.cc: Include "fcntl.h", "unistd.h", "sys/types.h", and
2582 (process_target::supports_multifs): Define.
2583 (process_target::multifs_open): Define.
2584 (process_target::multifs_readlink): Define.
2585 (process_target::multifs_unlink): Define.
2587 Update the derived classes and callers below.
2589 * hostio.cc (handle_setfs): Update.
2590 (handle_open): Update.
2591 (handle_unlink): Update.
2592 (handle_readlink): Update.
2593 * linux-low.cc (linux_target_ops): Update.
2594 (linux_process_target::supports_multifs): Define.
2595 (linux_process_target::multifs_open): Define.
2596 (linux_process_target::multifs_readlink): Define.
2597 (linux_process_target::multifs_unlink): Define.
2598 * linux-low.h (class linux_process_target): Update.
2599 * lynx-low.cc (lynx_target_ops): Update.
2600 * nto-low.cc (nto_target_ops): Update.
2601 * win32-low.cc (win32_target_ops): Update.
2603 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2605 Turn process_stratum_target's pid_to_exec_file op into a method
2608 * target.h (struct process_stratum_target): Remove the target op.
2609 (class process_target): Add the target op. Also add
2610 'supports_pid_to_exec_file'.
2611 * target.cc (process_target::pid_to_exec_file): Define.
2612 (process_target::supports_pid_to_exec_file): Define.
2614 Update the derived classes and callers below.
2616 * server.cc (handle_qxfer_exec_file): Update.
2617 (handle_query): Update.
2618 * linux-low.cc (linux_target_ops): Update.
2619 (linux_process_target::supports_pid_to_exec_file): Define.
2620 (linux_process_target::pid_to_exec_file): Define.
2621 * linux-low.h (class linux_process_target): Update.
2622 * lynx-low.cc (lynx_target_ops): Update.
2623 * nto-low.cc (nto_target_ops): Update.
2624 * win32-low.cc (win32_target_ops): Update.
2626 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2628 Turn process_stratum_target's supports_range_stepping op into a
2629 method of process_target.
2631 * target.h (struct process_stratum_target): Remove the target op.
2632 (class process_target): Add the target op.
2633 (target_supports_range_stepping): Update the macro.
2634 * target.cc (process_target::supports_range_stepping): Define.
2636 Update the derived classes and callers below.
2638 * linux-low.cc (linux_target_ops): Update.
2639 (linux_supports_range_stepping): Turn into ...
2640 (linux_process_target::supports_range_stepping): ... this.
2641 * linux-low.h (class linux_process_target): Update.
2642 * lynx-low.cc (lynx_target_ops): Update.
2643 * nto-low.cc (nto_target_ops): Update.
2644 * win32-low.cc (win32_target_ops): Update.
2646 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2648 Turn process_stratum_target's btrace-related ops (enable_btrace,
2649 disable_btrace, read_btrace, read_btrace_conf) into methods of
2652 * target.h (struct process_stratum_target): Remove the target ops.
2653 (class process_target): Add the target ops.
2654 (target_enable_btrace): Update.
2655 (target_disable_btrace): Update.
2656 (target_read_btrace): Update.
2657 (target_read_btrace_conf): Update.
2658 * target.cc (process_target::enable_btrace): Define.
2659 (process_target::disable_btrace): Define.
2660 (process_target::read_btrace): Define.
2661 (process_target::read_btrace_conf): Define.
2663 Update the derived classes and callers below.
2665 * linux-low.cc (linux_target_ops): Update.
2666 (linux_process_target:enable_btrace): Define as a wrapper around
2667 linux_enable_btrace.
2668 (linux_low_disable_btrace): Turn into ...
2669 (linux_process_target::disable_btrace): ... this.
2670 (linux_low_read_btrace): Turn into ...
2671 (linux_process_target::read_btrace): ... this.
2672 (linux_low_btrace_conf): Turn into ...
2673 (linux_process_target::read_btrace_conf): ... this.
2674 * linux-low.h (class linux_process_target): Update.
2675 * lynx-low.cc (lynx_target_ops): Update.
2676 * nto-low.cc (nto_target_ops): Update.
2677 * win32-low.cc (win32_target_ops): Update.
2679 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2681 Turn process_stratum_target's supports_agent op into a method of
2684 * target.h (struct process_stratum_target): Remove the target op.
2685 (class process_target): Add the target op.
2686 (target_supports_agent): Update the macro.
2687 * target.cc (process_target::supports_agent): Define.
2689 Update the derived classes and callers below.
2691 * linux-low.cc (linux_target_ops): Update.
2692 (linux_supports_agent): Turn into ...
2693 (linux_process_target::supports_agent): ... this.
2694 * linux-low.h (class linux_process_target): Update.
2695 * lynx-low.cc (lynx_target_ops): Update.
2696 * nto-low.cc (nto_target_ops): Update.
2697 * win32-low.cc (win32_target_ops): Update.
2699 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2701 Turn process_stratum_target's qxfer_libraries_svr4 op into a
2702 method of process_target.
2704 * target.h (struct process_stratum_target): Remove the target op.
2705 (class process_target): Add the target op. Also add
2706 'supports_qxfer_libraries_svr4'.
2707 * target.cc (process_target::qxfer_libraries_svr4): Define.
2708 (process_target::supports_qxfer_libraries_svr4): Define.
2710 Update the derived classes and callers below.
2712 * server.cc (handle_qxfer_libraries_svr4): Update.
2713 (handle_query): Update.
2714 * linux-low.cc (linux_target_ops): Update.
2715 (linux_process_target::supports_qxfer_libraries_svr4): Define.
2716 (linux_qxfer_libraries_svr4): Turn into ...
2717 (linux_process_target::qxfer_libraries_svr4): ... this.
2718 * linux-low.h (class linux_process_target): Update.
2719 * lynx-low.cc (lynx_target_ops): Update.
2720 * nto-low.cc (nto_target_ops): Update.
2721 * win32-low.cc (win32_target_ops): Update.
2723 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2725 Turn process_stratum_target's supports_disable_randomization op
2726 into a method of process_target.
2728 * target.h (struct process_stratum_target): Remove the target op.
2729 (class process_target): Add the target op.
2730 (target_supports_disable_randomization): Update the macro.
2731 * target.cc (process_target::supports_disable_randomization): Define.
2733 Update the derived classes and callers below.
2735 * linux-low.cc (linux_target_ops): Update.
2736 (linux_supports_disable_randomization): Turn into ...
2737 (linux_process_target::supports_disable_randomization): ... this.
2738 * linux-low.h (class linux_process_target): Update.
2739 * lynx-low.cc (lynx_target_ops): Update.
2740 * nto-low.cc (nto_target_ops): Update.
2741 * win32-low.cc (win32_target_ops): Update.
2743 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2745 Turn process_stratum_target's emit_ops op into a method of
2748 * target.h (struct process_stratum_target): Remove the target op.
2749 (class process_target): Add the target op.
2750 (target_emit_ops): Update the macro.
2751 * target.cc (process_target::emit_ops): Define.
2753 Update the derived classes and callers below.
2755 * linux-low.cc (linux_target_ops): Update.
2756 (linux_emit_ops): Turn into ...
2757 (linux_process_target::emit_ops): ... this.
2758 * linux-low.h (class linux_process_target): Update.
2759 * lynx-low.cc (lynx_target_ops): Update.
2760 * nto-low.cc (nto_target_ops): Update.
2761 * win32-low.cc (win32_target_ops): Update.
2763 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2765 Turn process_stratum_target's install_fast_tracepoint_jump_pad
2766 and get_min_fast_tracepoint_insn_len ops into methods of
2769 * target.h (struct process_stratum_target): Remove the target ops.
2770 (class process_target): Add the target ops. Also add
2771 'supports_fast_tracepoints'.
2772 (target_supports_fast_tracepoints): Update the macro.
2773 (target_get_min_fast_tracepoint_insn_len): Update the macro.
2774 (install_fast_tracepoint_jump_pad): Update and rename the macro
2776 (target_install_fast_tracepoint_jump_pad): ... this.
2777 * target.cc (process_target::supports_fast_tracepoints): Define.
2778 (process_target::install_fast_tracepoint_jump_pad): Define.
2779 (process_target::get_min_fast_tracepoint_insn_len): Define.
2781 Update the derived classes and callers below.
2783 * tracepoint.cc (install_fast_tracepoint): Update.
2784 * linux-low.cc (linux_target_ops): Update.
2785 (linux_process_target::supports_fast_tracepoints): Define.
2786 (linux_install_fast_tracepoint_jump_pad): Turn into ...
2787 (linux_process_target::install_fast_tracepoint_jump_pad): ... this.
2788 (linux_get_min_fast_tracepoint_insn_len): Turn into ...
2789 (linux_process_target::get_min_fast_tracepoint_insn_len): ... this.
2790 * linux-low.h (class linux_process_target): Update.
2791 * lynx-low.cc (lynx_target_ops): Update.
2792 * nto-low.cc (nto_target_ops): Update.
2793 * win32-low.cc (win32_target_ops): Update.
2795 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2797 Turn process_stratum_target's stabilize_threads op into a
2798 method of process_target.
2800 * target.h (struct process_stratum_target): Remove the target op.
2801 (class process_target): Add the target op.
2802 (target_stabilize_threads): Update the macro.
2803 * target.cc (process_target::stabilize_threads): Define.
2805 Update the derived classes and callers below.
2807 * server.cc (handle_status): Update.
2808 * tracepoint.cc (cmd_qtdp): Update.
2809 (cmd_qtstart): Update.
2810 * linux-low.cc (linux_target_ops): Update.
2811 (linux_stabilize_threads): Turn into ...
2812 (linux_process_target::stabilize_threads): ... this.
2813 (linux_wait_1): Update.
2814 * linux-low.h (class linux_process_target): Update.
2815 * lynx-low.cc (lynx_target_ops): Update.
2816 * nto-low.cc (nto_target_ops): Update.
2817 * win32-low.cc (win32_target_ops): Update.
2819 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2821 Turn process_stratum_target's pause_all and unpause_all ops
2822 into methods of process_target.
2824 * target.h (struct process_stratum_target): Remove the target ops.
2825 (class process_target): Add the target ops.
2826 (pause_all): Update the macro and rename to...
2827 (target_pause_all): ... this.
2828 (unpause_all): Update the macro and rename to...
2829 (target_unpause_all): ... this.
2830 * target.cc (process_target::pause_all): Define.
2831 (process_target::unpause_all): Define.
2833 Update the derived classes and callers below.
2835 * server.cc (handle_status): Update.
2836 * tracepoint.cc (clear_installed_tracepoints): Update.
2838 (cmd_qtstart): Update.
2839 (stop_tracing): Update.
2840 (cmd_qtstatus): Update.
2841 (upload_fast_traceframes): Update.
2842 (run_inferior_command): Update.
2843 * linux-low.cc (linux_target_ops): Update.
2844 (linux_pause_all): Turn into ...
2845 (linux_process_target::pause_all): ... this.
2846 (linux_unpause_all): Turn into ...
2847 (linux_process_target::unpause_all): ... this.
2848 (linux_process_target::prepare_to_access_memory): Update.
2849 (linux_process_target::done_accessing_memory): Update.
2850 * linux-low.h (class linux_process_target): Update.
2851 * lynx-low.cc (lynx_target_ops): Update.
2852 * nto-low.cc (nto_target_ops): Update.
2853 * win32-low.cc (win32_target_ops): Update.
2855 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2857 Turn process_stratum_target's get_tib_address op into a method of
2860 * target.h (struct process_stratum_target): Remove the target op.
2861 (class process_target): Add the target op. Also add
2862 'supports_get_tib_address'.
2863 * target.cc (process_target::get_tib_address): Define.
2864 (process_target::supports_get_tib_address): Define.
2866 Update the derived classes and callers below.
2868 * server.cc (handle_query): Update.
2869 * linux-low.cc (win32_target_ops): Update.
2870 * lynx-low.cc (lynx_target_ops): Update.
2871 * nto-low.cc (nto_target_ops): Update.
2872 * win32-low.cc (win32_target_ops): Update.
2873 (win32_process_target::supports_get_tib_address): Define.
2874 (win32_get_tib_address): Turn into ...
2875 (win32_process_target::get_tib_address): ... this.
2876 * win32-low.h (class win32_process_target): Update.
2878 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2880 Turn process_stratum_target's thread_stopped op into a method of
2883 * target.h (struct process_stratum_target): Remove the target op.
2884 (class process_target): Add the target op. Also add
2885 'supports_thread_stopped'.
2886 (target_thread_stopped): Update the macro.
2887 * target.cc (process_target::thread_stopped): Define.
2888 (process_target::supports_thread_stopped): Define.
2889 (prepare_to_access_memory): Update.
2891 Update the derived classes and callers below.
2893 * server.cc (queue_stop_reply_callback): Update.
2894 * linux-low.cc (linux_target_ops): Update.
2895 (linux_process_target::supports_thread_stopped): Define.
2896 (linux_thread_stopped): Turn into ...
2897 (linux_process_target::thread_stopped): ... this.
2898 * linux-low.h (class linux_process_target): Update.
2899 * lynx-low.cc (lynx_target_ops): Update.
2900 * nto-low.cc (nto_target_ops): Update.
2901 * win32-low.cc (win32_target_ops): Update.
2903 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2905 Turn process_stratum_target's read_pc and write_pc ops into
2906 methods of process_target.
2908 * target.h (struct process_stratum_target): Remove the target ops.
2909 (class process_target): Add the target ops.
2910 * target.cc (process_target::read_pc): Define.
2911 (process_target::write_pc): Define.
2913 Update the derived classes and callers below.
2915 * regcache.cc (regcache_read_pc): Update.
2916 (regcache_write_pc): Update.
2917 * linux-low.cc (linux_target_ops): Update.
2918 (linux_read_pc): Turn into ...
2919 (linux_process_target::read_pc): ... this.
2920 (linux_write_pc): Turn into ...
2921 (linux_process_target::write_pc): ... this.
2922 * linux-low.h (class linux_process_target): Update.
2923 * lynx-low.cc (lynx_target_ops): Update.
2924 * nto-low.cc (nto_target_ops): Update.
2925 * win32-low.cc (win32_target_ops): Update.
2927 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2929 Turn process_stratum_target's supports_tracepoints op into a
2930 method of process_target.
2932 * target.h (struct process_stratum_target): Remove the target op.
2933 (class process_target): Add the target op.
2934 (target_supports_tracepoints): Update the macro.
2935 * target.cc (process_target::supports_tracepoints): Define.
2937 Update the derived classes and callers below.
2939 * linux-low.cc (linux_target_ops): Update.
2940 (linux_supports_tracepoints): Turn into ...
2941 (linux_process_target::supports_tracepoints): ... this.
2942 * linux-low.h (class linux_process_target): Update.
2943 * lynx-low.cc (lynx_target_ops): Update.
2944 * nto-low.cc (nto_target_ops): Update.
2945 * win32-low.cc (win32_target_ops): Update.
2947 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2949 Turn process_stratum_target's process_qsupported op into a method
2952 * target.h (struct process_stratum_target): Remove the target op.
2953 (class process_target): Add the target op.
2954 (target_process_qsupported): Update the macro.
2955 * target.cc (process_target::process_qsupported): Define.
2957 Update the derived classes and callers below.
2959 * linux-low.cc (linux_target_ops): Update.
2960 (linux_process_qsupported): Turn into ...
2961 (linux_process_target::process_qsupported): ... this.
2962 * linux-low.h (class linux_process_target): Update.
2963 * lynx-low.cc (lynx_target_ops): Update.
2964 * nto-low.cc (nto_target_ops): Update.
2965 * win32-low.cc (win32_target_ops): Update.
2967 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2969 Turn process_stratum_target's read_loadmap op into a method of
2972 * target.h (struct process_stratum_target): Remove the target op.
2973 (class process_target): Add the target op. Also add
2974 'supports_read_loadmap'.
2975 * target.cc (process_target::read_loadmap): Define.
2976 (process_target::supports_read_loadmap): Define.
2978 Update the derived classes and callers below.
2980 * server.cc (handle_qxfer_fdpic): Update.
2981 (handle_query): Update.
2982 * linux-low.cc (linux_target_ops): Update.
2983 (linux_process_target::supports_read_loadmap): Define.
2984 (linux_read_loadmap): Turn into ...
2985 (linux_process_target::read_loadmap): ... this.
2986 * linux-low.h (class linux_process_target): Update.
2987 * lynx-low.cc (lynx_target_ops): Update.
2988 * nto-low.cc (nto_target_ops): Update.
2989 * win32-low.cc (win32_target_ops): Update.
2991 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2993 Turn process_stratum_target's core_of_thread op into a method of
2996 * target.h (struct process_stratum_target): Remove the target op.
2997 (class process_target): Add the target op.
2998 (target_core_of_thread): Update the macro.
2999 * target.cc (process_target::core_of_thread): Define.
3001 Update the derived classes and callers below.
3003 * linux-low.cc (linux_target_ops): Update.
3004 (linux_process_target::core_of_thread): Define.
3005 * linux-low.h (class linux_process_target): Update.
3006 * lynx-low.cc (lynx_target_ops): Update.
3007 * nto-low.cc (nto_target_ops): Update.
3008 * win32-low.cc (win32_target_ops): Update.
3010 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3012 Turn process_stratum_target's handle_monitor_command op into a
3013 method of process_target.
3015 * target.h (struct process_stratum_target): Remove the target op.
3016 (class process_target): Add the target op.
3017 (target_handle_monitor_command): Update the macro.
3018 * target.cc (process_target::handle_monitor_command): Define.
3020 Update the derived classes and callers below.
3022 * server.cc (handle_query): Update.
3023 * linux-low.cc (linux_target_ops): Update.
3024 (linux_process_target::handle_monitor_command): Define.
3025 * linux-low.h (class linux_process_target): Update.
3026 * lynx-low.cc (lynx_target_ops): Update.
3027 * nto-low.cc (nto_target_ops): Update.
3028 * win32-low.cc (win32_target_ops): Update.
3030 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3032 Turn process_stratum_target's handle_new_gdb_connection op into a
3033 method of process_target.
3035 * target.h (struct process_stratum_target): Remove the target op.
3036 (class process_target): Add the target op.
3037 (target_handle_new_gdb_connection): Update the macro.
3038 * target.cc (process_target::handle_new_gdb_connection): Define.
3040 Update the derived classes and callers below.
3042 * linux-low.cc (linux_target_ops): Update.
3043 (linux_handle_new_gdb_connection): Turn into ...
3044 (linux_process_target::handle_new_gdb_connection): ... this.
3045 * linux-low.h (class linux_process_target): Update.
3046 * lynx-low.cc (lynx_target_ops): Update.
3047 * nto-low.cc (nto_target_ops): Update.
3048 * win32-low.cc (win32_target_ops): Update.
3050 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3052 Turn process_stratum_target's supports_fork_events,
3053 supports_vfork_events, and supports_exec_events ops into methods
3056 * target.h (struct process_stratum_target): Remove the target ops.
3057 (class process_target): Add the target ops.
3058 (target_supports_fork_events): Update the macro.
3059 (target_supports_vfork_events): Update the macro.
3060 (target_supports_exec_events): Update the macro.
3061 * target.cc (process_target::supports_fork_events): Define.
3062 (process_target::supports_vfork_events): Define.
3063 (process_target::supports_exec_events): Define.
3065 Update the derived classes and callers below.
3067 * linux-low.cc (linux_target_ops): Update.
3068 (linux_supports_fork_events): Turn into ...
3069 (linux_process_target::supports_fork_events): ... this.
3070 (linux_supports_vfork_events): Turn into ...
3071 (linux_process_target::supports_vfork_events): ... this.
3072 (linux_supports_exec_events): Turn into ...
3073 (linux_process_target::supports_exec_events): ... this.
3074 * linux-low.h (class linux_process_target): Update.
3075 * lynx-low.cc (lynx_target_ops): Update.
3076 * nto-low.cc (nto_target_ops): Update.
3077 * win32-low.cc (win32_target_ops): Update.
3079 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3081 Turn process_stratum_target's supports_multi_process op into a
3082 method of process_target.
3084 * target.h (struct process_stratum_target): Remove the target op.
3085 (class process_target): Add the target op.
3086 * target.cc (process_target::supports_multi_process): Define.
3087 (target_supports_multi_process): Update.
3089 Update the derived classes and callers below.
3091 * linux-low.cc (linux_target_ops): Update.
3092 (linux_supports_multi_process): Turn into ...
3093 (linux_process_target::supports_multi_process): ... this.
3094 * linux-low.h (class linux_process_target): Update.
3095 * lynx-low.cc (lynx_target_ops): Update.
3096 * nto-low.cc (nto_target_ops): Update.
3097 * win32-low.cc (win32_target_ops): Update.
3099 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3101 Turn process_stratum_target's supports_non_stop, async, and
3102 start_non_stop ops into methods of process_target.
3104 * target.h (struct process_stratum_target): Remove the target ops.
3105 (class process_target): Add the target ops.
3106 (target_supports_non_stop): Update the macro.
3107 (target_async): Update the macro.
3108 (start_non_stop): Remove declaration.
3109 * target.cc (process_target::supports_non_stop): Define.
3110 (process_target::async): Define.
3111 (process_target::start_non_stop): Define.
3112 (start_non_stop): Remove.
3114 Update the derived classes and callers below.
3116 * server.cc (handle_qxfer_siginfo): Update.
3117 (handle_query): Update.
3118 * linux-low.cc (linux_target_ops): Update.
3119 (linux_supports_non_stop): Turn into ...
3120 (linux_process_target::supports_non_stop): ... this.
3121 (linux_async): Turn into ...
3122 (linux_process_target::async): ... this.
3123 (linux_start_non_stop): Turn into ...
3124 (linux_process_target::start_non_stop): ... this.
3125 * linux-low.h (class linux_process_target): Update.
3126 * lynx-low.cc (lynx_target_ops): Update.
3127 * nto-low.cc (nto_target_ops): Update.
3128 (nto_supports_non_stop): Remove; rely on the default behavior
3130 * win32-low.cc (win32_target_ops): Update.
3132 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3134 Turn process_stratum_target's qxfer_siginfo op into a method of
3137 * target.h (struct process_stratum_target): Remove the target op.
3138 (class process_target): Add the target op. Also add
3139 'supports_qxfer_siginfo'.
3140 * target.cc (process_target::qxfer_siginfo): Define.
3141 (process_target::supports_qxfer_siginfo): Define.
3143 Update the derived classes and callers below.
3145 * server.cc (handle_qxfer_siginfo): Update.
3146 (handle_query): Update.
3147 * linux-low.cc (linux_target_ops): Update.
3148 (linux_process_target::supports_qxfer_siginfo): Define.
3149 (linux_xfer_siginfo): Turn into ...
3150 (linux_process_target::qxfer_siginfo): ... this.
3151 * linux-low.h (class linux_process_target): Update.
3152 * lynx-low.cc (lynx_target_ops): Update.
3153 * nto-low.cc (nto_target_ops): Update.
3154 * win32-low.cc (win32_target_ops): Update.
3156 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3158 Turn process_stratum_target's qxfer_osdata op into a method of
3161 * target.h (struct process_stratum_target): Remove the target op.
3162 (class process_target): Add the target op. Also add
3163 'supports_qxfer_osdata'.
3164 * target.cc (process_target::qxfer_osdata): Define.
3165 (process_target::supports_qxfer_osdata): Define.
3167 Update the derived classes and callers below.
3169 * server.cc (handle_qxfer_osdata): Update.
3170 (handle_query): Update.
3171 * linux-low.cc (linux_target_ops): Update.
3172 (linux_process_target::supports_qxfer_osdata): Define.
3173 (linux_qxfer_osdata): Turn into ...
3174 (linux_process_target::qxfer_osdata): ... this.
3175 * linux-low.h (class linux_process_target): Update.
3176 * lynx-low.cc (lynx_target_ops): Update.
3177 * nto-low.cc (nto_target_ops): Update.
3178 * win32-low.cc (win32_target_ops): Update.
3180 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3182 Turn process_stratum_target's hostio_last_error op into a
3183 method of process_target.
3185 * target.h (struct process_stratum_target): Remove the target op.
3186 (class process_target): Add the target op.
3187 * target.cc: Add "hostio.h" to includes.
3188 (process_target::hostio_last_error): Define.
3190 Update the derived classes and callers below.
3192 * hostio.cc (hostio_error): Update.
3193 * linux-low.cc: Remove "hostio.h" from includes.
3194 (linux_target_ops): Update.
3195 * lynx-low.cc (lynx_target_ops): Update.
3196 * nto-low.cc (nto_target_ops): Update.
3197 * win32-low.h (class win32_process_target): Update.
3198 * win32-low.cc (win32_target_ops): Update.
3199 (wince_hostio_last_error): Turn into ...
3200 (win32_process_target::hostio_last_error): ... this.
3202 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3204 Turn process_stratum_target's get_tls_address op into a method of
3207 * target.h (struct process_stratum_target): Remove the target op.
3208 (class process_target): Add the target op. Also add
3209 'supports_get_tls_address'.
3210 * target.cc (process_target::get_tls_address): Define.
3211 (process_target::supports_get_tls_address): Define.
3213 Update the derived classes and callers below.
3215 * server.cc (handle_query): Update.
3216 * linux-low.cc (linux_target_ops): Update.
3217 (linux_process_target::supports_get_tls_address): Define.
3218 (linux_process_target::get_tls_address): Define.
3219 * linux-low.h (class linux_process_target): Update.
3220 * lynx-low.cc (lynx_target_ops): Update.
3221 * nto-low.cc (nto_target_ops): Update.
3222 * win32-low.cc (win32_target_ops): Update.
3224 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3226 Turn process_stratum_target's read_offsets op into a method of
3229 * target.h (struct process_stratum_target): Remove the target op.
3230 (class process_target): Add the target op. Also add
3231 'supports_read_offsets'.
3232 * target.cc (process_target::read_offsets): Define.
3233 (process_target::supports_read_offsets): Define.
3235 Update the derived classes and callers below.
3237 * server.cc (handle_query): Update.
3238 * linux-low.cc (SUPPORTS_READ_OFFSETS): New #define directive.
3239 (linux_target_ops): Update.
3240 (linux_process_target::supports_read_offsets): Define.
3241 (linux_read_offsets): Turn into ...
3242 (linux_process_target::read_offsets): ... this.
3243 * linux-low.h (class linux_process_target): Update.
3244 * lynx-low.cc (lynx_target_ops): Update.
3245 * nto-low.cc (nto_target_ops): Update.
3246 * win32-low.cc (win32_target_ops): Update.
3248 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3250 Turn process_stratum_target's stopped_by_watchpoint and
3251 stopped_data_address ops into methods of process_target.
3253 * target.h (struct process_stratum_target): Remove the target ops.
3254 (class process_target): Add the target ops.
3255 * target.cc (process_target::stopped_by_watchpoint): Define.
3256 (process_target::stopped_data_address): Define.
3258 Update the derived classes and callers below.
3260 * remote-utils.cc (prepare_resume_reply): Update.
3261 * linux-low.cc (linux_target_ops): Update.
3262 (linux_stopped_by_watchpoint): Turn into ...
3263 (linux_process_target::stopped_by_watchpoint): ... this.
3264 (linux_stopped_data_address): Turn into ...
3265 (linux_process_target::stopped_data_address): ... this.
3266 * linux-low.h (class linux_process_target): Update.
3267 * lynx-low.cc (lynx_target_ops): Update.
3268 * nto-low.cc (nto_target_ops): Update.
3269 (nto_stopped_by_watchpoint): Turn into ...
3270 (nto_process_target::stopped_by_watchpoint): ... this.
3271 (nto_stopped_data_address): Turn into ...
3272 (nto_process_target::stopped_data_address): ... this.
3273 * nto-low.h (class nto_process_target): Update.
3274 * win32-low.cc (win32_target_ops): Update.
3275 (win32_stopped_by_watchpoint): Turn into ...
3276 (win32_process_target::stopped_by_watchpoint): ... this.
3277 (win32_stopped_data_address): Turn into ...
3278 (win32_process_target::stopped_data_address): ... this.
3279 * win32-low.h (class win32_process_target): Update.
3281 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3283 Turn process_stratum_target's supports_hardware_single_step op into
3284 a method of process_target.
3286 * target.h (struct process_stratum_target): Remove the target op.
3287 (class process_target): Add the target op.
3288 (target_supports_hardware_single_step): Update the macro.
3289 (target_can_do_hardware_single_step): Remove declaration.
3290 * target.cc (process_target::supports_hardware_single_step): Define.
3291 (target_can_do_hardware_single_step): Remove.
3293 Update the derived classes and callers below.
3295 * linux-low.h (class linux_process_target): Update.
3296 * linux-low.cc (linux_target_ops): Update.
3297 (linux_supports_hardware_single_step): Turn into ...
3298 (linux_process_target::supports_hardware_single_step): ... this.
3299 * lynx-low.h (class lynx_process_target): Update.
3300 * lynx-low.cc (lynx_target_ops): Update.
3301 (lynx_process_target::supports_hardware_single_step): Define.
3302 * nto-low.h (class nto_process_target): Update.
3303 * nto-low.cc (nto_target_ops): Update.
3304 (nto_process_target::supports_hardware_single_step): Define.
3305 * win32-low.h (class win32_process_target): Update.
3306 * win32-low.cc (win32_target_ops): Update.
3307 (win32_process_target::supports_hardware_single_step): Define.
3309 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3311 Turn process_stratum_target's {supports_}stopped_by_hw_breakpoint
3312 ops into methods of process_target.
3314 * target.h (struct process_stratum_target): Remove the target ops.
3315 (class process_target): Add the target ops.
3316 (target_stopped_by_hw_breakpoint): Update the macro.
3317 (target_supports_stopped_by_hw_breakpoint): Update the macro.
3318 * target.cc (process_target::stopped_by_hw_breakpoint): Define.
3319 (process_target::supports_stopped_by_hw_breakpoint): Define.
3321 Update the derived classes and callers below.
3323 * linux-low.cc (linux_target_ops): Update.
3324 (linux_stopped_by_hw_breakpoint): Turn into ...
3325 (linux_process_target::stopped_by_hw_breakpoint): ... this.
3326 (linux_supports_stopped_by_hw_breakpoint): Turn into ...
3327 (linux_process_target::supports_stopped_by_hw_breakpoint): ... this.
3328 * linux-low.h (class linux_process_target): Update.
3329 * lynx-low.cc (lynx_target_ops): Update.
3330 * nto-low.cc (nto_target_ops): Update.
3331 * win32-low.cc (win32_target_ops): Update.
3333 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3335 Turn process_stratum_target's {supports_}stopped_by_sw_breakpoint
3336 ops into methods of process_target.
3338 * target.h (struct process_stratum_target): Remove the target ops.
3339 (class process_target): Add the target ops.
3340 (target_stopped_by_sw_breakpoint): Update the macro.
3341 (target_supports_stopped_by_sw_breakpoint): Update the macro.
3342 * target.cc (process_target::stopped_by_sw_breakpoint): Define.
3343 (process_target::supports_stopped_by_sw_breakpoint): Define.
3345 Update the derived classes and callers below.
3347 * linux-low.cc (linux_target_ops): Update.
3348 (linux_stopped_by_sw_breakpoint): Turn into ...
3349 (linux_process_target::stopped_by_sw_breakpoint): ... this.
3350 (linux_supports_stopped_by_sw_breakpoint): Turn into ...
3351 (linux_process_target::supports_stopped_by_sw_breakpoint): ... this.
3352 * linux-low.h (class linux_process_target): Update.
3353 * lynx-low.cc (lynx_target_ops): Update.
3354 * nto-low.cc (nto_target_ops): Update.
3355 * win32-low.cc (win32_target_ops): Update.
3357 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3359 Turn process_stratum_target's insert_point and remove_point ops
3360 into methods of process_target.
3362 * target.h (struct process_stratum_target): Remove the target ops.
3363 (class process_target): Add the target ops.
3364 * target.cc (process_target::insert_point): Define.
3365 (process_target::remove_point): Define.
3367 Update the derived classes and callers below.
3369 * mem-break.cc (set_raw_breakpoint_at): Update.
3370 (delete_raw_breakpoint): Update.
3371 (uninsert_raw_breakpoint): Update.
3372 (reinsert_raw_breakpoint): Update.
3373 * linux-low.cc (linux_target_ops): Update.
3374 (linux_insert_point): Turn into ...
3375 (linux_process_target::insert_point): ... this.
3376 (linux_remove_point): Turn into ...
3377 (linux_process_target::remove_point): ... this.
3378 * linux-low.h (class linux_process_target): Update.
3379 * lynx-low.cc (lynx_target_ops): Update.
3380 * nto-low.cc (nto_target_ops): Update.
3381 (nto_insert_point): Turn into ...
3382 (nto_process_target::insert_point): ... this.
3383 (nto_remove_point): Turn into ...
3384 (nto_process_target::remove_point): ... this.
3385 * nto-low.h (class nto_process_target): Update.
3386 * win32-low.cc (win32_target_ops): Update.
3387 (win32_insert_point): Turn into ...
3388 (win32_process_target::insert_point): ... this.
3389 (win32_remove_point): Turn into ...
3390 (win32_process_target::remove_point): ... this.
3391 * win32-low.h (class win32_process_target): Update.
3393 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3395 Turn process_stratum_target's supports_z_point_type op into a
3396 method of process_target.
3398 * target.h (struct process_stratum_target): Remove the target op.
3399 (class process_target): Add the target op.
3400 * target.cc (process_target::supports_z_point_type): Define.
3402 Update the derived classes and callers below.
3404 * mem-break.cc (z_type_supported): Update.
3405 * linux-low.cc (linux_target_ops): Update.
3406 (linux_supports_z_point_type): Turn into ...
3407 (linux_process_target::supports_z_point_type): ... this.
3408 * linux-low.h (class linux_process_target): Update.
3409 * lynx-low.cc (lynx_target_ops): Update.
3410 * nto-low.cc (nto_target_ops): Update.
3411 (nto_supports_z_point_type): Turn into ...
3412 (nto_process_target::supports_z_point_type): ... this.
3413 * nto-low.h (class nto_process_target): Update.
3414 * win32-low.cc (win32_target_ops): Update.
3415 (win32_supports_z_point_type): Turn into ...
3416 (win32_process_target::supports_z_point_type): ... this.
3417 * win32-low.h (class win32_process_target): Update.
3419 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3421 Turn process_stratum_target's read_auxv op into a method of
3424 * target.h (class process_stratum_target): Remove the target op.
3425 (struct process_target): Add the target op. Also add
3426 'supports_read_auxv'.
3427 * target.cc (process_target::read_auxv): Define.
3428 (process_target::supports_read_auxv): Define.
3430 Update the derived classes and callers below.
3432 * server.cc (handle_qxfer_auxv): Update.
3433 (handle_query): Update.
3434 * linux-low.cc (linux_target_ops): Update.
3435 (linux_process_target::supports_read_auxv): Define.
3436 (linux_read_auxv): Turn into ...
3437 (linux_process_target::read_auxv): ... this.
3438 * linux-low.h (class linux_process_target): Update.
3439 * lynx-low.cc (lynx_target_ops): Update.
3440 * nto-low.cc (nto_target_ops): Update.
3441 (nto_process_target::supports_read_auxv): Define.
3442 (nto_read_auxv): Turn into ...
3443 (nto_process_target::read_auxv): ... this.
3444 * nto-low.h (class nto_process_target): Update.
3445 * win32-low.cc (win32_target_ops): Update.
3447 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3449 Turn process_stratum_target's request_interrupt op into a method of
3452 * target.h (struct process_stratum_target): Remove the target op.
3453 (class process_target): Add the target op.
3455 Update the derived classes and callers below.
3457 * remote-utils.cc (putpkt_binary_1): Update.
3458 (input_interrupt): Update.
3460 * server.cc (handle_v_requests): Update.
3461 * linux-low.cc (linux_target_ops): Update.
3462 (linux_request_interrupt): Turn into ...
3463 (linux_process_target::request_interrupt): ... this.
3464 * linux-low.h (class linux_process_target): Update.
3465 * lynx-low.cc (lynx_target_ops): Update.
3466 (lynx_request_interrupt): Turn into ...
3467 (lynx_process_target::request_interrupt): ... this.
3468 * lynx-low.h (class lynx_process_target): Update.
3469 * nto-low.cc (nto_target_ops): Update.
3470 (nto_request_interrupt): Turn into ...
3471 (nto_process_target::request_interrupt): ... this.
3472 * nto-low.h (class nto_process_target): Update.
3473 * win32-low.cc (win32_target_ops): Update.
3474 (win32_request_interrupt): Turn into ...
3475 (win32_process_target::request_interrupt): ... this.
3476 * win32-low.h (class win32_process_target): Update.
3478 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3480 Turn process_stratum_target's look_up_symbols op into a method of
3483 * target.h (struct process_stratum_target): Remove the target op.
3484 (class process_target): Add the target op.
3485 * target.cc (process_target::look_up_symbols): Define.
3487 Update the derived classes and callers below.
3489 * server.cc (handle_query): Update.
3490 * linux-low.cc (linux_target_ops): Update.
3491 (linux_look_up_symbols): Turn into ...
3492 (linux_process_target::look_up_symbols): ... this.
3493 * linux-low.h (class linux_process_target): Update.
3494 * lynx-low.cc (lynx_target_ops): Update.
3495 * nto-low.cc (nto_target_ops): Update.
3496 * win32-low.cc (win32_target_ops): Update.
3498 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3500 Turn process_stratum_target's read_memory and write_memory
3501 ops into methods of process_target.
3503 * target.h (struct process_stratum_target): Remove the target ops.
3504 (class process_target): Add the target ops.
3506 Update the derived classes and callers below.
3508 * linux-aarch32-low.cc (arm_breakpoint_at): Update.
3509 * linux-aarch64-low.cc (aarch64_breakpoint_at): Update.
3510 * linux-arm-low.cc (arm_sigreturn_next_pc): Update.
3511 (arm_get_syscall_trapinfo): Update.
3512 * linux-cris-low.cc (cris_breakpoint_at): Update.
3513 * linux-crisv32-low.cc (cris_breakpoint_at): Update.
3514 * linux-m32r-low.cc (m32r_breakpoint_at): Update.
3515 * linux-mips-low.cc (mips_breakpoint_at): Update.
3516 * linux-nios2-low.cc (nios2_breakpoint_at): Update.
3517 * linux-ppc-low.cc (ppc_breakpoint_at): Update.
3518 * linux-sh-low.cc (sh_breakpoint_at): Update.
3519 * linux-sparc-low.cc (sparc_fill_gregset_to_stack): Update.
3520 (sparc_store_gregset_from_stack): Update.
3521 (sparc_breakpoint_at): Update.
3522 * linux-tic6x-low.cc (tic6x_breakpoint_at): Update.
3523 * linux-tile-low.cc (tile_breakpoint_at): Update.
3524 * linux-x86-low.cc (x86_breakpoint_at): Update.
3525 * linux-xtensa-low.cc (xtensa_breakpoint_at): Update.
3526 * mem-brea.cc (insert_memory_breakpoint): Update.
3527 (validate_inserted_breakpoint): Update.
3528 * target.cc (read_inferior_memory): Update.
3529 (target_write_memory): Update.
3530 * linux-low.cc (linux_target_ops): Update.
3531 (linux_read_memory): Make a wrapper around the read_memory target
3533 (linux_process_target::read_memory): Rename from linux_read_memory.
3534 (linux_write_memory): Turn into ...
3535 (linux_process_target::write_memory): ... this.
3536 * linux-low.h (class linux_process_target): Update.
3537 * lynx-low.cc (lynx_target_ops): Update.
3538 (lynx_read_memory): Turn into ...
3539 (lynx_process_target::read_memory): ... this.
3540 (lynx_write_memory): Turn into ...
3541 (lynx_process_target::write_memory): ... this.
3542 * lynx-low.h (class lynx_process_target): Update.
3543 * nto-low.cc (nto_target_ops): Update.
3544 (nto_read_memory): Turn into ...
3545 (nto_process_target::read_memory): ... this.
3546 (nto_write_memory): Turn into ...
3547 (nto_process_target::write_memory): ... this.
3548 * nto-low.h (class nto_process_target): Update.
3549 * win32-low.cc (win32_target_ops): Update.
3550 (win32_read_inferior_memory): Turn into ...
3551 (win32_process_target::read_memory): ... this.
3552 (win32_write_inferior_memory): Turn into ...
3553 (win32_process_target::write_memory): ... this.
3554 * win32-low.h (class win32_process_target): Update.
3556 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3558 Turn process_stratum_target's prepare_to_access_memory and
3559 done_accessing_memory ops into methods of process_target.
3561 * target.h (struct process_stratum_target): Remove the target ops.
3562 (class process_target): Add the target ops.
3563 * target.cc (process_target::prepare_to_access_memory): Define.
3564 (process_target::done_accessing_memory): Define.
3565 (prepare_to_access_memory): Update.
3566 (done_accessing_memory): Update.
3568 Update the derived classes and callers below.
3570 * linux-low.cc (linux_target_ops): Update.
3571 (linux_prepare_to_access_memory): Turn into ...
3572 (linux_process_target::prepare_to_access_memory): ... this.
3573 (linux_done_accessing_memory): Turn into ...
3574 (linux_process_target::done_accessing_memory): ... this.
3575 * linux-low.h (class linux_process_target): Update.
3576 * lynx-low.cc (lynx_target_ops): Update.
3577 * nto-low.cc (nto_target_ops): Update.
3578 * win32-low.cc (win32_target_ops): Update.
3580 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3582 Turn process_stratum_target's fetch_registers and store_registers
3583 ops into methods of process_target.
3585 * target.h (struct process_stratum_target): Remove the target ops.
3586 (class process_target): Add the target ops.
3587 (fetch_inferior_registers): Update the macro.
3588 (store_inferior_registers): Update the macro.
3590 Update the derived classes and callers below.
3592 * linux-low.cc (linux_target_ops): Update.
3593 (linux_fetch_registers): Turn into ...
3594 (linux_process_target::fetch_registers): ... this.
3595 (linux_store_registers): Turn into ...
3596 (linux_process_target::store_registers): ... this.
3597 * linux-low.h (class linux_process_target): Update.
3598 * lynx-low.cc (lynx_target_ops): Update.
3599 (lynx_fetch_registers): Turn into ...
3600 (lynx_process_target::fetch_registers): ... this.
3601 (lynx_store_registers): Turn into ...
3602 (lynx_process_target::store_registers): ... this.
3603 * lynx-low.h (class lynx_process_target): Update.
3604 * nto-low.cc (nto_target_ops): Update.
3605 (nto_fetch_registers): Turn into ...
3606 (nto_process_target::fetch_registers): ... this.
3607 (nto_store_registers): Turn into ...
3608 (nto_process_target::store_registers): ... this.
3609 * nto-low.h (class nto_process_target): Update.
3610 * win32-low.cc (win32_target_ops): Update.
3611 (win32_fetch_inferior_registers): Turn into ...
3612 (win32_process_target::fetch_registers): ... this.
3613 (win32_store_inferior_registers): Turn into ...
3614 (win32_process_target::store_registers): ... this.
3615 * win32-low.h (class win32_process_target): Update.
3617 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3619 Turn process_stratum_target's wait op into a method of
3622 * target.h (struct process_stratum_target): Remove the target op.
3623 (class process_target): Add the target op.
3625 Update the derived classes and callers below.
3627 * target.cc (target_wait): Update.
3628 * linux-low.cc (linux_target_ops): Update.
3629 (linux_wait): Turn into ...
3630 (linux_process_target::wait): ... this.
3631 * linux-low.h (class linux_process_target): Update.
3632 * lynx-low.cc (lynx_target_ops): Update.
3633 (lynx_wait): Turn into ...
3634 (lynx_process_target::wait): ... this.
3635 * lynx-low.h (class lynx_process_target): Update.
3636 * nto-low.cc (nto_target_ops): Update.
3637 (nto_wait): Turn into ...
3638 (nto_process_target::wait): ... this.
3639 * nto-low.h (class nto_process_target): Update.
3640 * win32-low.cc (win32_target_ops): Update.
3641 (win32_wait): Turn into ...
3642 (win32_process_target::wait): ... this.
3643 (do_initial_child_stuff): Update.
3644 * win32-low.h (class win32_process_target): Update.
3646 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3648 Turn process_stratum_target's resume op into a method of
3651 * target.h (struct process_stratum_target): Remove the target op.
3652 (class process_target): Add the target op.
3654 Update the derived classes and callers below.
3656 * server.cc (resume): Update.
3657 * target.cc (target_stop_and_wait): Update.
3658 (target_continue_no_signal): Update.
3659 (target_continue): Update.
3660 * linux-low.cc (linux_target_ops): Update.
3661 (linux_resume): Turn into ...
3662 (linux_process_target::resume): ... this.
3663 * linux-low.h (class linux_process_target): Update.
3664 * lynx-low.cc (lynx_target_ops): Update.
3665 (lynx_resume): Turn into ...
3666 (lynx_process_target::resume): ... this.
3667 * lynx-low.h (class lynx_process_target): Update.
3668 * nto-low.cc (nto_target_ops): Update.
3669 (nto_resume): Turn into ...
3670 (nto_process_target::resume): ... this.
3671 * nto-low.h (class nto_process_target): Update.
3672 * win32-low.cc (win32_target_ops): Update.
3673 (win32_resume): Turn into ...
3674 (win32_process_target::resume): ... this.
3675 (win32_process_target::detach): Update.
3676 (do_initial_child_stuff): Update.
3677 * win32-low.h (class win32_process_target): Update.
3679 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3681 Turn process_stratum_target's thread_alive op into a method of
3684 * target.h (struct process_stratum_target): Remove the target op.
3685 (class process_target): Add the target op.
3686 (mythread_alive): Update the macro.
3688 Update the derived classes and callers below.
3690 * linux-low.cc (linux_target_ops): Update.
3691 (linux_thread_alive): Turn into ...
3692 (linux_process_target::thread_alive): ... this.
3693 (wait_for_sigstop): Update.
3694 * linux-low.h (class linux_process_target): Update.
3695 * lynx-low.cc (lynx_target_ops): Update.
3696 (lynx_thread_alive): Turn into ...
3697 (lynx_process_target::thread_alive): ... this.
3698 * lynx-low.h (class lynx_process_target): Update.
3699 * nto-low.cc (nto_target_ops): Update.
3700 (nto_thread_alive): Turn into ...
3701 (nto_process_target::thread_alive): ... this.
3702 * nto-low.h (class nto_process_target): Update.
3703 * win32-low.cc (win32_target_ops): Update.
3704 (win32_thread_alive): Turn into ...
3705 (win32_process_target::thread_alive): ... this.
3706 * win32-low.h (class win32_process_target): Update.
3708 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3710 Turn process_stratum_target's join op into a method of
3713 * target.h (struct process_stratum_target): Remove the target op.
3714 (class process_target): Add the target op.
3715 (join_inferior): Update the macro.
3717 Update the derived classes and callers below.
3719 * linux-low.cc (linux_target_ops): Update.
3720 (linux_join): Turn into ...
3721 (linux_process_target::join): ... this.
3722 * linux-low.h (class linux_process_target): Update.
3723 * lynx-low.cc (lynx_target_ops): Update.
3724 (lynx_join): Turn into ...
3725 (lynx_process_target::join): ... this.
3726 * lynx-low.h (class lynx_process_target): Update.
3727 * nto-low.cc (nto_target_ops): Update.
3728 (nto_process_target::join): Define.
3729 * nto-low.h (class nto_process_target): Update.
3730 * win32-low.cc (win32_target_ops): Update.
3731 (win32_join): Turn into ...
3732 (win32_process_target::join): ... this.
3733 * win32-low.h (class win32_process_target): Update.
3735 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3737 Turn process_stratum_target's mourn op into a method of
3740 * target.h (struct process_stratum_target): Remove the target op.
3741 (class process_target): Add the target op.
3743 Update the derived classes and callers below.
3745 * target.cc (target_mourn_inferior): Update.
3746 * linux-low.cc (linux_target_ops): Update.
3747 (linux_mourn): Turn into ...
3748 (linux_process_target::mourn): ... this.
3749 (handle_extended_wait): Update.
3750 (linux_process_target::kill): Update.
3751 (linux_process_target::detach): Update.
3752 * linux-low.h (class linux_process_target): Update.
3753 * lynx-low.cc (lynx_target_ops): Update.
3754 (lynx_mourn): Turn into ...
3755 (lynx_process_target::mourn): ... this.
3756 * lynx-low.h (class lynx_process_target): Update.
3757 * nto-low.cc (nto_target_ops): Update.
3758 (nto_mourn): Turn into ...
3759 (nto_process_target::mourn): ... this.
3760 * nto-low.h (class nto_process_target): Update.
3761 * win32-low.cc (win32_target_ops): Update.
3762 (win32_mourn): Turn into ...
3763 (win32_process_target::mourn): ... this.
3764 * win32-low.h (class win32_process_target): Update.
3766 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3768 Turn process_stratum_target's detach op into a method of
3771 * target.h (struct process_stratum_target): Remove the target op.
3772 (class process_target): Add the target op.
3773 (detach_inferior): Update the macro.
3775 Update the derived classes and callers below.
3777 * linux-low.cc (linux_target_ops): Update.
3778 (linux_detach): Turn into ...
3779 (linux_process_target::detach): ... this.
3780 * linux-low.h (class linux_process_target): Update.
3781 * lynx-low.cc (lynx_target_ops): Update.
3782 (lynx_detach): Turn into ...
3783 (lynx_process_target::detach): ... this.
3784 * lynx-low.h (class lynx_process_target): Update.
3785 * nto-low.cc (nto_target_ops): Update.
3786 (nto_detach): Turn into ...
3787 (nto_process_target::detach): ... this.
3788 * nto-low.h (class nto_process_target): Update.
3789 * win32-low.cc (win32_target_ops): Update.
3790 (win32_detach): Turn into ...
3791 (win32_process_target::detach): ... this.
3792 * win32-low.h (class win32_process_target): Update.
3794 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3796 Turn process_stratum_target's kill op into a method of
3799 * target.h (struct process_stratum_target): Remove the target op.
3800 (class process_target): Add the target op.
3802 Update the derived classes and callers below.
3804 * target.cc (kill_inferior): Update.
3805 * linux-low.cc (linux_target_ops): Update.
3806 (linux_kill): Turn into ...
3807 (linux_process_target::kill): ... this.
3808 * linux-low.h (class linux_process_target): Update.
3809 * lynx-low.cc (lynx_target_ops): Update.
3810 (lynx_kill): Turn into ...
3811 (lynx_process_target::kill): ... this.
3812 * lynx-low.h (class lynx_process_target): Update.
3813 * nto-low.cc (nto_target_ops): Update.
3814 (nto_kill): Turn into ...
3815 (nto_process_target::kill): ... this.
3816 * nto-low.h (class nto_process_target): Update.
3817 * win32-low.cc (win32_target_ops): Update.
3818 (win32_kill): Turn into ...
3819 (win32_process_target::kill): ... this.
3820 * win32-low.h (class win32_process_target): Update.
3822 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3824 Turn process_stratum_target's attach op into a method of
3827 * target.h (struct process_stratum_target): Remove the target op.
3828 (class process_target): Add the target op.
3829 (myattach): Update the macro.
3831 Update the derived classes and callers below.
3833 * linux-low.cc (linux_target_ops): Update.
3834 (linux_attach): Turn into ...
3835 (linux_process_target::attach): ... this.
3836 * linux-low.h (class linux_process_target): Update.
3837 * lynx-low.cc (lynx_target_ops): Update.
3838 (lynx_attach): Turn into ...
3839 (lynx_process_target::attach): ... this.
3840 * lynx-low.h (class lynx_process_target): Update.
3841 * nto-low.cc (nto_target_ops): Update.
3842 (nto_attach): Turn into ...
3843 (nto_process_target::attach): ... this.
3844 * nto-low.h (class nto_process_target): Update.
3845 * win32-low.cc (win32_target_ops): Update.
3846 (win32_attach): Turn into ...
3847 (win32_process_target::attach): ... this.
3848 * win32-low.h (class win32_process_target): Update.
3850 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3852 Turn process_stratum_target's post_create_inferior op into a method
3855 * target.h (struct process_stratum_target): Remove the target op.
3856 (class process_target): Add the target op.
3857 (target_post_create_inferior): Update the macro.
3858 * target.cc (process_target::post_create_inferior): Define.
3860 Update the derived classes and callers below.
3862 * linux-low.cc (linux_target_ops): Update.
3863 (linux_post_create_inferior): Turn into ...
3864 (linux_process_target::post_create_inferior): ... this.
3865 * linux-low.h (class linux_process_target): Update.
3866 * lynx-low.cc (lynx_target_ops): Update.
3867 * nto-low.cc (nto_target_ops): Update.
3868 * win32-low.cc (win32_target_ops): Update.
3870 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3872 Turn process_stratum_target's create_inferior op into a method of
3875 * target.h (struct process_stratum_target): Remove the target op.
3876 (class process_target): Add the target op.
3877 (create_inferior): Rename the macro to ...
3878 (target_create_inferior): ... this.
3880 Update the derived classes and callers below.
3882 * server.cc (handle_v_run): Update.
3883 (captured_main): Update.
3884 (process_serial_event): Update.
3885 * linux-low.cc (linux_target_ops): Update.
3886 (linux_create_inferior): Turn into ...
3887 (linux_process_target::create_inferior): ... this.
3888 * linux-low.h (class linux_process_target): Update.
3889 * lynx-low.cc (lynx_target_ops): Update.
3890 (lynx_create_inferior): Turn into ...
3891 (lynx_process_target::create_inferior): ... this.
3892 * lynx-low.h (class lynx_process_target): Update.
3893 * nto-low.cc (nto_target_ops): Update.
3894 (nto_create_inferior): Turn into ...
3895 (nto_process_target::create_inferior): ... this.
3896 * nto-low.h (class nto_process_target): Update.
3897 * win32-low.cc (win32_target_ops): Update.
3898 (win32_create_inferior): Turn into ...
3899 (win32_process_target::create_inferior): ... this.
3900 * win32-low.h (class win32_process_target): Update.
3902 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3904 * target.h (class process_target): New class definition.
3905 (struct process_stratum_target) <pt>: New field with type
3907 * linux-low.h (class linux_process_target): Define as a derived
3908 class of 'process_target'.
3909 * linux-low.cc (linux_target_ops): Add a linux_process_target*
3911 * lynx-low.h (class lynx_process_target): Define as a derived
3912 class of 'process_target'.
3913 * lynx-low.cc (lynx_target_ops): Add a lynx_process_target*
3915 * nto-low.h (class nto_process_target): Define as a derived
3916 class of 'process_target'.
3917 * nto-low.cc (nto_target_ops): Add an nto_process_target*
3919 * win32-low.h (class win32_process_target): Define as a derived
3920 class of 'process_target'.
3921 * win32-low.cc (win32_target_ops): Add a win32_process_target*
3924 2020-02-19 Andrew Burgess <andrew.burgess@embecosm.com>
3926 * configure: Regenerate.
3928 2020-02-19 Maciej W. Rozycki <macro@wdc.com>
3929 Andrew Burgess <andrew.burgess@embecosm.com>
3931 * linux-riscv-low.cc: New file.
3932 * Makefile.in (SFILES): Add linux-riscv-low.cc, arch/riscv.c,
3933 and nat/riscv-linux-tdesc.c.
3934 * configure.srv <riscv*-*-linux*> (srv_tgtobj)
3935 (srv_linux_regsets, srv_linux_usrregs, srv_linux_thread_db):
3938 2020-02-14 Tom Tromey <tom@tromey.com>
3940 * acinclude.m4: Don't include acx_configure_dir.m4.
3941 * Makefile.in (LIBIBERTY_BUILDDIR, GNULIB_BUILDDIR): Update.
3942 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): Remove.
3943 (all, install-only, uninstall, clean-info, clean)
3944 (maintainer-clean): Don't recurse.
3945 (subdir_do, all-lib): Remove.
3946 ($(LIBGNU) $(LIBIBERTY) $(GNULIB_H)): Remove rule.
3948 (generated_files): Update.
3949 ($(GNULIB_BUILDDIR)/Makefile): Remove rule.
3950 * configure: Rebuild.
3951 * configure.ac: Don't configure gnulib or libiberty.
3954 2020-02-14 Eli Zaretskii <eliz@gnu.org>
3956 * win32-low.c (create_process): Prepend PROGRAM to ARGS when
3957 preparing the command line for CreateProcess.
3958 (win32_create_inferior): Reflect the program name in debugging
3959 output that shows the process and its command line.
3961 2020-02-13 Simon Marchi <simon.marchi@efficios.com>
3963 * Makefile.in: Rename source files from .c to .cc.
3964 * %.c: Rename to %.cc.
3965 * configure.ac: Rename server.c to server.cc.
3966 * configure: Re-generate.
3968 2020-02-13 Simon Marchi <simon.marchi@efficios.com>
3970 * Makefile.in: Rename gdbsupport source files from .c to .cc.
3972 2020-02-12 Hannes Domani <ssbssa@yahoo.de>
3974 * win32-low.c (win32_create_inferior): Set signal_pid.
3976 2020-02-12 Maciej W. Rozycki <macro@wdc.com>
3977 Pedro Alves <palves@redhat.com>
3979 Skip building gdbserver in a cross-configuration.
3980 * configure.srv: Set $gdbserver_host depending on whether $target
3981 is $host. Use $gdbserver_host instead of $host.
3983 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
3985 * configure: Re-generate.
3987 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
3989 * configure: Re-generate.
3991 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
3993 * acinclude.m4: Update warning.m4 path.
3995 2020-02-09 Hannes Domani <ssbssa@yahoo.de>
3997 * win32-low.c (win32_clear_inferiors): Reset siginfo_er.
3998 (handle_exception): Set siginfo_er.
3999 (win32_xfer_siginfo): New function.
4001 2020-02-07 Tom Tromey <tom@tromey.com>
4002 Pedro Alves <palves@redhat.com>
4004 * README: Update build documentation.
4005 * configure.srv: Set UNSUPPORTED if host is unsupported. Check
4007 * configure.ac: Update paths.
4008 * configure: Rebuild.
4009 * acinclude.m4: Update paths.
4010 * Makefile.in: Update include paths.
4011 (depcomp, INCLUDE_DIR, INCGNU, INCSUPPORT, INCLUDE_CFLAGS)
4012 (SFILES, XML_DIR, n, $(GNULIB_BUILDDIR)/Makefile, config.status)
4013 (version-generated.c, stamp-xml, regdat_sh, arch/%-ipa.o)
4014 (gdbsupport/%-ipa.o, %-ipa.o, arch/%.o, gdbsupport/%.o, %.o)
4015 (%-generated.c): Update paths.
4016 * Move entire directory from ../gdb/gdbserver.
4018 2020-01-29 Maciej W. Rozycki <macro@wdc.com>
4020 * configure.srv <i[34567]86-*-mingw*>: Fix whitespace damage.
4022 2020-01-29 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4024 * configure.srv (powerpc*-*-linux*): Use srv_tgtobj in second
4025 assignment instead of srv_linux_obj.
4027 2020-01-28 Hannes Domani <ssbssa@yahoo.de>
4029 * server.c (handle_qxfer_libraries): Write segment-address with
4032 2020-01-24 Hannes Domani <ssbssa@yahoo.de>
4034 * Makefile.in (install-strip): New target.
4035 (install_sh, INSTALL_STRIP_PROGRAM, STRIP): New variables.
4036 * aclocal.m4: Regenerate.
4037 * configure: Regenerate.
4038 * configure.ac: Add AM_PROG_INSTALL_STRIP.
4040 2020-01-24 Maciej W. Rozycki <macro@wdc.com>
4042 * Makefile.in (SFILES): Adjust paths to point to real files.
4043 (OBS): Move waitstatus.o to target/waitstatus.o.
4044 (TAGS): Transform paths appropriately.
4046 (nat/%.o): ... this pattern rule.
4048 (target/%.o): ... this pattern rule.
4049 * configure.srv: Adjust paths throughout to include nat/ prefix
4050 with the revant files.
4051 * configure.ac: Add `nat' and `target' to CONFIG_SRC_SUBDIR.
4052 * configure: Regenerate.
4054 2020-01-24 Maciej W. Rozycki <macro@wdc.com>
4056 * Makefile.in (TAGS): Remove config files from the recipe.
4058 2020-01-14 Tom Tromey <tom@tromey.com>
4060 * configure: Rebuild.
4061 * configure.ac: Remove any checks that were added to common.m4.
4062 * acinclude.m4: Include lib-ld.m4, lib-prefix.m4, and
4065 2020-01-14 Tom Tromey <tom@tromey.com>
4067 * server.h: Include config.h.
4068 * gdbreplay.c: Include config.h.
4069 * configure: Rebuild.
4070 * configure.ac: Don't source common.host.
4071 * acinclude.m4: Update path.
4072 * Makefile.in (INCSUPPORT): New variable.
4073 (INCLUDE_CFLAGS): Add INCSUPPORT.
4074 (SFILES): Update paths.
4075 (version-generated.c): Update path to create-version.sh.
4076 (gdbsupport/%-ipa.o, gdbsupport/%.o): Update paths.
4078 2020-01-14 Tom Tromey <tom@tromey.com>
4080 * configure.ac (LIBS): Use WIN32APILIBS.
4081 (USE_WIN32API): Don't define.
4082 * configure: Rebuild.
4084 2020-01-14 Tom Tromey <tom@tromey.com>
4086 * configure: Rebuild.
4088 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
4090 * Makefile.in (%-generated.c): Remove rule for files from
4093 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
4095 * configure: Re-generate.
4097 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
4099 * tracepoint.h (IP_AGENT_EXPORT_FUNC) [!IN_PROCESS_AGENT]:
4101 * tracepoint.c (stop_tracing, flush_trace_buffer,
4102 about_to_request_buffer_space, get_trace_state_variable_value,
4103 set_trace_state_variable_value, gdb_collect): Add declaration.
4105 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
4107 * linux-x86-low.c (x86_linux_regs_info, amd64_emit_eq_goto,
4108 amd64_emit_ne_goto, amd64_emit_lt_goto, amd64_emit_le_goto,
4109 amd64_emit_gt_goto, amd64_emit_ge_goto, amd64_emit_ge_goto,
4110 i386_emit_eq_goto, i386_emit_ne_goto, i386_emit_lt_goto,
4111 i386_emit_le_goto, i386_emit_gt_goto, i386_emit_ge_goto): Make
4114 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
4116 * inferiors.c: Include gdbsupport/common-inferior.h.
4118 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
4120 * hostio-errno.c: Include hostio.h.
4122 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
4124 * Makefile.in (%-generated.c): Make $(regdat_sh) a regular
4127 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
4129 * linux-arm-tdesc.c: Include linux-arm-tdesc.h.
4130 * linux-arm-tdesc.h: Include arch/arm.h.
4132 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
4134 * linux-aarch64-low.c (aarch64_write_goto_address): Make static.
4136 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
4138 * linux-aarch32-tdesc.c: Include linux-aarch32-tdesc.h.
4139 * linux-aarch64-tdesc.c: Include linux-aarch64-tdesc.h.
4141 2020-01-10 Pedro Alves <palves@redhat.com>
4143 * fork-child.c (post_fork_inferior): Pass target down to
4145 * inferiors.c (switch_to_thread): Add process_stratum_target
4147 * lynx-low.c (lynx_target_ops): Now a process_stratum_target.
4148 * nto-low.c (nto_target_ops): Now a process_stratum_target.
4149 * linux-low.c (linux_target_ops): Now a process_stratum_target.
4150 * remote-utils.c (prepare_resume_reply): Pass the target to
4152 * target.c (the_target): Now a process_stratum_target.
4153 (done_accessing_memory): Pass the target to switch_to_thread.
4154 (set_target_ops): Ajust to use process_stratum_target.
4155 * target.h (struct target_ops): Rename to ...
4156 (struct process_stratum_target): ... this.
4157 (the_target, set_target_ops): Adjust.
4158 (prepare_to_access_memory): Adjust comment.
4159 * win32-low.c (child_xfer_memory): Adjust to use
4160 process_stratum_target.
4161 (win32_target_ops): Now a process_stratum_target.
4163 2020-01-06 Eli Zaretskii <eliz@gnu.org>
4164 Pedro Alves <palves@redhat.com>
4166 * win32-low.c (get_child_debug_event): Extract the fatal exception
4167 from the exit status and convert to the equivalent Posix signal
4169 (win32_wait): Allow TARGET_WAITKIND_SIGNALLED status as well.
4170 * Makefile.in (OBS, SFILES): Add gdb_wait.[co].
4172 2020-01-01 Hannes Domani <ssbssa@yahoo.de>
4174 * Makefile.in: Use INSTALL_PROGRAM_ENV.
4176 2020-01-01 Joel Brobecker <brobecker@adacore.com>
4178 * server.c (gdbserver_version): Change copyright year to 2020.
4179 * gdbreplay.c (gdbreplay_version): Likewise.
4181 2019-12-19 Christian Biesinger <cbiesinger@google.com>
4183 * configure: Regenerate.
4184 * configure.ac: Quote variable arguments of test.
4186 2019-12-16 Bernd Edlinger <bernd.edlinger@hotmail.de>
4188 * Makefile.in: Fix build with GNU Make 3.81
4190 2019-12-16 Tom Tromey <tromey@adacore.com>
4192 * server.c (get_exec_file): Constify result.
4194 2019-12-10 Christian Biesinger <cbiesinger@google.com>
4196 * Makefile.in: Add safe-strerror.c to gdbreplay and IPA, and change
4197 UNDO_GNULIB_CFLAGS to undo strerror_r instead of strerror.
4198 * config.in: Regenerate.
4199 * configure: Regenerate.
4200 * configure.ac: Don't check for strerror.
4201 * linux-i386-ipa.c (initialize_fast_tracepoint_trampoline_buffer):
4202 Call safe_strerror instead of strerror.
4203 * server.h (strerror): Remove this now-unnecessary declaration.
4204 * tracepoint.c (init_named_socket): Call safe_strerror instead of
4206 (gdb_agent_helper_thread): Likewise.
4207 * utils.c (perror_with_name): Likewise.
4209 2019-11-26 Tom Tromey <tom@tromey.com>
4211 * configure, config.in: Rebuild.
4213 2019-11-26 Tom Tromey <tom@tromey.com>
4215 * remote-utils.c (block_unblock_async_io): Use gdb_sigmask.
4216 * linux-low.c (linux_wait_for_event_filtered, linux_async): Use
4218 * configure, config.in: Rebuild.
4220 2019-11-26 Tom Tromey <tom@tromey.com>
4222 * Makefile.in (PTHREAD_CFLAGS, PTHREAD_LIBS): New variables.
4223 (INTERNAL_CFLAGS_BASE): Use PTHREAD_CFLAGS.
4224 (GDBSERVER_LIBS): Use PTHREAD_LIBS.
4225 * acinclude.m4: Include ax_pthread.m4.
4226 * config.in, configure: Rebuild.
4228 2019-11-26 Christian Biesinger <cbiesinger@google.com>
4230 * debug.c (debug_set_output): Call safe_strerror instead of
4232 * linux-low.c (attach_proc_task_lwp_callback): Likewise.
4233 (linux_kill_one_lwp): Likewise.
4234 (linux_detach_one_lwp): Likewise.
4235 (linux_wait_for_event_filtered): Likewise.
4236 (store_register): Likewise.
4237 * lynx-low.c (lynx_attach): Likewise.
4238 * mem-break.c (insert_memory_breakpoint): Likewise.
4239 (remove_memory_breakpoint): Likewise.
4240 (delete_fast_tracepoint_jump): Likewise.
4241 (set_fast_tracepoint_jump): Likewise.
4242 (uninsert_fast_tracepoint_jumps_at): Likewise.
4243 (reinsert_fast_tracepoint_jumps_at): Likewise.
4244 * nto-low.c (nto_xfer_memory): Likewise.
4245 (nto_resume): Likewise.
4247 2019-11-20 Luis Machado <luis.machado@linaro.org>
4249 * linux-aarch64-low.c (is_sve_tdesc): Check against target feature
4250 instead of register count.
4251 * tdesc.c (tdesc_contains_feature): New function.
4252 * tdesc.h (tdesc_contains_feature): New prototype.
4254 2019-11-15 Christian Biesinger <cbiesinger@google.com>
4256 * Makefile.in: Add safe-strerror.c.
4257 * configure: Regenerate.
4258 * configure.ac: Don't source common.host.
4260 2019-11-15 Christian Biesinger <cbiesinger@google.com>
4262 * config.in: Regenerate.
4263 * configure: Regenerate.
4265 2019-11-12 Andrew Burgess <andrew.burgess@embecosm.com>
4267 * ax.c (ax_printf): Handle size_t_arg.
4269 2019-11-06 Christian Biesinger <cbiesinger@google.com>
4271 * linux-tdep.c (linux_info_proc): Use strtok_r instead of strtok.
4272 * mi/mi-main.c (output_cores): Likewise.
4273 * nat/linux-osdata.c (linux_xfer_osdata_cpus): Likewise.
4274 (linux_xfer_osdata_modules): Likewise.
4275 * remote.c (register_remote_support_xml): Likewise.
4276 * sparc64-tdep.c (adi_is_addr_mapped): Likewise.
4277 * xml-syscall.c (syscall_create_syscall_desc): Likewise.
4279 2019-11-01 Christian Biesinger <cbiesinger@google.com>
4281 * configure: Regenerate.
4282 * configure.ac: Remove check for strerror_r.
4284 2019-10-31 Christian Biesinger <cbiesinger@google.com>
4286 * config.in: Regenerate.
4287 * configure: Regenerate.
4288 * configure.ac: Also check for strerror_r.
4290 2019-10-31 Christian Biesinger <cbiesinger@google.com>
4292 * ax.h (debug_agent): Remove duplicate declaration.
4294 2019-10-26 Tom de Vries <tdevries@suse.de>
4296 * linux-aarch64-low.c: Fix typos in comments.
4297 * linux-arm-low.c: Same.
4298 * linux-low.c: Same.
4299 * linux-ppc-low.c: Same.
4300 * proc-service.c: Same.
4303 * tracepoint.c: Same.
4304 * win32-low.c: Same.
4306 2019-10-25 Tom Tromey <tromey@adacore.com>
4308 * utils.c (xstrdup): Remove.
4310 2019-10-23 Tom Tromey <tom@tromey.com>
4312 * configure, config.in: Rebuild.
4314 2019-10-23 Tom Tromey <tom@tromey.com>
4316 * configure: Rebuild.
4317 * acinclude.m4: Use m4_include, not sinclude.
4319 2019-10-17 Tom Tromey <tromey@adacore.com>
4321 * configure: Rebuild.
4322 * configure.ac: Use AC_CONFIG_HEADERS. Create stamp-h there, not
4323 in AC_CONFIG_FILES invocation.
4324 * Makefile.in (stamp-h, Makefile): Use new-style config.status
4327 2019-10-16 Christian Biesinger <cbiesinger@google.com>
4329 * server.c: Include xml-builtin.h.
4330 (get_xml_features): Don't declare xml_builtins here.
4332 2019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
4334 * Makefile.in: Remove references to vec-ipa.o.
4336 2019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
4338 * Makefile.in: Remove references to vec.c.
4340 2019-10-02 Christian Biesinger <cbiesinger@google.com>
4342 * server.c (server_waiting): Change to bool.
4343 (extended_protocol): Likewise.
4344 (response_needed): Likewise.
4345 (exit_requested): Likewise.
4346 (run_once): Likewise.
4347 (report_no_resumed): Likewise.
4348 (non_stop): Likewise.
4349 (disable_packet_vCont): Likewise.
4350 (disable_packet_Tthread): Likewise.
4351 (disable_packet_qC): Likewise.
4352 (disable_packet_qfThreadInfo): Likewise.
4353 (handle_general_set): Update.
4354 (handle_detach): Update.
4355 (handle_monitor_command): Update.
4356 (handle_query): Update.
4357 (captured_main): Update.
4358 (process_serial_event): Update.
4359 * server.h (server_waiting): Change to bool.
4360 (disable_packet_vCont): Likewise.
4361 (disable_packet_Tthread): Likewise.
4362 (disable_packet_qC): Likewise.
4363 (disable_packet_qfThreadInfo): Likewise.
4364 (run_once): Likewise.
4365 (non_stop): Likewise.
4366 * target.c (target_stop_and_wait): Update.
4368 2019-10-02 Tom Tromey <tromey@adacore.com>
4370 * Makefile.in (SFILES): Add common-inferior.c.
4371 (OBS): Add common-inferior.o.
4372 * server.c (startup_with_shell): Don't define.
4374 2019-10-02 Andrew Burgess <andrew.burgess@embecosm.com>
4376 * linux-low.c (linux_low_read_btrace): Update for change to
4379 2019-09-20 Christian Biesinger <cbiesinger@google.com>
4381 * debug.c (debug_threads): Remove comment in favor of the header.
4382 * debug.h (using_threads): Add declaration.
4383 (debug_threads): Add comment.
4384 * linux-aarch64-low.c: Include debug.h and remove declaration of
4386 * nto-low.c: Likewise.
4387 * remote-utils.c: Likewise.
4388 * thread-db.c: Likewise.
4390 2019-09-20 Ulrich Weigand <uweigand@de.ibm.com>
4392 * configure.srv (ipa_ppc_linux_regobj): Remove powerpc-cell32l-ipa.o
4393 and powerpc-cell64l-ipa.o.
4394 (powerpc*-*-linux*): Remove powerpc-cell32l.o and powerpc-cell64l.o
4395 from srv_regobj. Remove rs6000/powerpc-cell32l.xml and
4396 rs6000/powerpc-cell64l.xml from srv_xmlfiles.
4399 * spu-low.c: Remove file.
4401 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Remove.
4402 (parse_spufs_run): Remove.
4403 (ppc_get_pc): Remove Cell/B.E. support.
4404 (ppc_set_pc): Likewise.
4405 (ppc_breakpoint_at): Likewise.
4406 (ppc_arch_setup): Likewise.
4407 (ppc_get_ipa_tdesc_idx): Do not handle tdesc_powerpc_cell64l or
4408 tdesc_powerpc_cell32l.
4409 (initialize_low_arch): Do not call init_registers_powerpc_cell64l
4410 or init_registers_powerpc_cell32l.
4411 * linux-ppc-ipa.c (get_ipa_tdesc): Do not handle PPC_TDESC_CELL.
4412 (initialize_low_tracepoint): Do not call init_registers_powerpc_cell64l
4413 or init_registers_powerpc_cell32l.
4414 * linux-ppc-tdesc-init.h (PPC_TDESC_CELL): Mark as unused.
4415 (init_registers_powerpc_cell32l): Remove prototype.
4416 (init_registers_powerpc_cell64l): Likewise.
4418 * target.h (struct target_ops): Remove qxfer_spu member.
4419 * server.c (handle_qxfer_spu): Remove.
4420 (qxfer_packets): Remove entry for "spu".
4421 (handle_query): No longer support qXfer:spu:read or qXfer:spu:write.
4422 * linux-low.c (SPUFS_MAGIC): Remove.
4423 (spu_enumerate_spu_ids): Remove.
4424 (linux_qxfer_spu): Remove.
4425 (linux_target_ops): Remove qxfer_spu member.
4426 * lynx-low.c (lynx_target_ops): Remove qxfer_spu member.
4427 * nto-low.c (nto_target_ops): Remove qxfer_spu member.
4428 * win32-low.c (win32_target_ops): Remove qxfer_spu member.
4430 2019-08-23 Sergio Durigan Junior <sergiodj@redhat.com>
4432 * Makefile.in (SFILES): Add 'gdbsupport/gdb-dlfcn.c'.
4433 (OBS): Add 'gdbsupport/gdb-dlfcn.o'.
4434 * config.in: Regenerate.
4435 * configure: Regenerate.
4437 2019-08-15 Tom Tromey <tromey@adacore.com>
4439 * target.c (target_write_memory): Use gdb::byte_vector.
4441 2019-08-15 Tom Tromey <tromey@adacore.com>
4443 * tracepoint.c (write_inferior_data_pointer)
4444 (write_inferior_integer, write_inferior_int8)
4445 (write_inferior_uinteger, m_tracepoint_action_download)
4446 (r_tracepoint_action_download, x_tracepoint_action_download)
4447 (l_tracepoint_action_download, clear_inferior_trace_buffer)
4448 (download_agent_expr, download_tracepoint_1)
4449 (download_trace_state_variables, upload_fast_traceframes): Update.
4450 * server.c (gdb_write_memory): Update.
4451 * remote-utils.c (relocate_instruction): Update.
4452 * proc-service.c (ps_pdwrite): Update.
4453 * mem-break.c (remove_memory_breakpoint)
4454 (delete_fast_tracepoint_jump, set_fast_tracepoint_jump)
4455 (uninsert_fast_tracepoint_jumps_at)
4456 (reinsert_fast_tracepoint_jumps_at): Update.
4457 * linux-x86-low.c (append_insns)
4458 (i386_install_fast_tracepoint_jump_pad)
4459 (amd64_write_goto_address, i386_write_goto_address): Update.
4460 * linux-s390-low.c (append_insns, s390_write_goto_address):
4462 * linux-ppc-low.c (ppc_relocate_instruction)
4463 (ppc_install_fast_tracepoint_jump_pad, emit_insns)
4464 (ppc_write_goto_address): Update.
4465 * linux-aarch64-low.c (append_insns): Update.
4466 * target.h (struct target_ops): Update.
4467 (write_inferior_memory): Don't declare.
4468 * target.c (target_write_memory): Rename from
4469 write_inferior_memory. Remove old target_write_memory.
4471 2019-08-15 Tom Tromey <tromey@adacore.com>
4473 * target.c (write_inferior_memory): Use std::vector.
4475 2019-08-06 Frank Ch. Eigler <fche@redhat.com>
4478 * configure.ac: Drop enable-libmcheck support.
4479 * configure, config.in: Rebuild.
4480 * acinclude.m4: Don't include it.
4482 2019-07-19 Alan Hayward <alan.hayward@arm.com>
4484 * configure.srv: Remove Arm xml files.
4486 2019-07-19 Alan Hayward <alan.hayward@arm.com>
4488 * configure.srv: Add new files. Remove xml generated files.
4489 * linux-aarch32-low.c (initialize_low_arch_aarch32): Don't init
4491 * linux-aarch32-low.h (tdesc_arm_with_neon): Remove.
4492 * linux-aarch32-tdesc.c: New file.
4493 * linux-aarch32-tdesc.h: New file.
4494 * linux-aarch64-low.c (aarch64_arch_setup): Call aarch32_linux_read_description.
4495 * linux-arm-low.c (init_registers_arm, tdesc_arm)
4496 (init_registers_arm_with_iwmmxt, tdesc_arm_with_iwmmxt)
4497 (init_registers_arm_with_vfpv2, tdesc_arm_with_vfpv2)
4498 (init_registers_arm_with_vfpv3, tdesc_arm_with_vfpv3): Remove.
4499 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
4500 (arm_store_vfpregset): Call arm_linux_get_tdesc_fp_type.
4501 (arm_read_description): Call arm_linux_read_description.
4502 (initialize_low_arch): Don't init registers.
4503 * linux-arm-tdesc.c: New file.
4504 * linux-arm-tdesc.h: New file.
4506 2019-07-10 Alan Hayward <alan.hayward@arm.com>
4508 * linux-arm-low.c (arm_fill_wmmxregset, arm_store_wmmxregset):
4509 Move counter inside for.
4510 (arm_read_description): Check ptrace earlier.
4511 (arm_arch_setup): Call arm_linux_init_hwbp_cap here.
4513 2019-07-09 Tom Tromey <tom@tromey.com>
4515 * configure: Rebuild.
4516 * configure.ac: Change common to gdbsupport.
4517 * acinclude.m4: Change common to gdbsupport.
4518 * Makefile.in (SFILES, OBS, GDBREPLAY_OBS, IPA_OBJS)
4519 (version-generated.c, gdbsupport/%-ipa.o, gdbsupport/%.o): Change
4520 common to gdbsupport.
4521 * ax.c, event-loop.c, fork-child.c, gdb_proc_service.h,
4522 gdbreplay.c, gdbthread.h, hostio-errno.c, hostio.c, i387-fp.c,
4523 inferiors.c, inferiors.h, linux-aarch64-tdesc-selftest.c,
4524 linux-amd64-ipa.c, linux-i386-ipa.c, linux-low.c,
4525 linux-tic6x-low.c, linux-x86-low.c, linux-x86-tdesc-selftest.c,
4526 linux-x86-tdesc.c, lynx-i386-low.c, lynx-low.c, mem-break.h,
4527 nto-x86-low.c, regcache.c, regcache.h, remote-utils.c, server.c,
4528 server.h, spu-low.c, symbol.c, target.h, tdesc.c, tdesc.h,
4529 thread-db.c, tracepoint.c, win32-i386-low.c, win32-low.c: Change
4530 common to gdbsupport.
4532 2019-07-04 Alan Hayward <alan.hayward@arm.com>
4534 * linux-aarch32-low.c (arm_read_description, arm_regsets): Use new
4536 * linux-arm-low.c (arm_read_description, arm_regsets): Likewise.
4538 2019-07-04 Alan Hayward <alan.hayward@arm.com>
4540 * configure.srv: Remove legacy xml.
4541 * linux-aarch64-low.c (initialize_low_arch): Remove
4542 initialize_low_tdesc call.
4543 * linux-aarch64-tdesc-selftest.c: Remove file.
4544 * linux-aarch64-tdesc.h (initialize_low_tdesc): Remove.
4545 * linux-x86-low.c (initialize_low_arch): Remove
4546 initialize_low_tdesc call.
4547 * linux-x86-tdesc-selftest.c: Remove file.
4548 * linux-x86-tdesc.h (initialize_low_tdesc): Remove.
4550 2019-06-20 Tom de Vries <tdevries@suse.de>
4552 * linux-s390-ipa.c (get_ipa_tdesc)[!__s390x__]: Use
4553 s390_te_linux64_ft_collect_regmap for S390_TDESC_GS.
4555 2019-06-19 Tom de Vries <tdevries@suse.de>
4557 * debug.h (debug_write): Change return type to ssize_t.
4558 * debug.c (debug_write): Same.
4560 2019-06-14 Tom Tromey <tom@tromey.com>
4562 * configure.ac: Use new path to gnulib.
4563 * configure: Rebuild.
4564 * Makefile.in (INCGNU, $(GNULIB_BUILDDIR)/Makefile): Use new path
4567 2019-06-11 Tom Tromey <tom@tromey.com>
4569 * Makefile.in (SFILES): Add alloc.c.
4571 (IPA_OBJS): Add alloc-ipa.o.
4572 (alloc-ipa.o): New target.
4573 (%.o: ../%.c): New pattern rule.
4575 2019-06-10 Tom Tromey <tromey@adacore.com>
4577 * remote-utils.c (look_up_one_symbol, relocate_instruction): Don't
4578 end warning with a newline.
4579 * linux-s390-low.c (s390_get_wordsize): Don't end warning with a
4581 * thread-db.c (attach_thread): Don't end warning with a newline.
4582 (thread_db_notice_clone): Likewise.
4583 * tracepoint.c (gdb_agent_helper_thread): Don't end warning with a
4585 * linux-x86-low.c (x86_get_min_fast_tracepoint_insn_len): Don't
4586 end warning with a newline.
4588 2019-06-04 Pedro Alves <palves@redhat.com>
4590 * server.c (captured_main): Use make_unique_xstrdup.
4592 2019-06-02 Tom Tromey <tom@tromey.com>
4594 * gdbreplay.c (fromhex): Remove.
4595 * Makefile.in (GDBREPLAY_OBS): Add rsp-low.o.
4597 2019-05-29 Tom Tromey <tromey@adacore.com>
4599 * configure: Rebuild.
4601 2019-05-06 Kevin Buettner <kevinb@redhat.com>
4603 * linux-x86-low.c (x86_fill_gregset): Don't compile 64-bit
4604 sign extension code on 32-bit builds.
4606 2019-05-03 Eli Zaretskii <eliz@gnu.org>
4609 * gdbreplay.c [USE_WIN32API]: Remove the _WIN32_WINNT override.
4611 2019-04-19 Tom Tromey <tom@tromey.com>
4613 * server.c (struct vstop_notif): Derive from notif_event.
4615 (queue_stop_reply): Update.
4616 (remove_all_on_match_ptid): Change type. Rewrite.
4617 (discard_queued_stop_replies): Rewrite.
4618 (in_queued_stop_replies_ptid): Change type.
4619 (in_queued_stop_replies): Rewrite.
4620 (notif_stop): Update.
4621 (queue_stop_reply_callback): Update.
4622 (captured_main): Don't call initialize_notif.
4623 (push_stop_notification): Update.
4624 * notif.c (notif_write_event, handle_notif_ack)
4625 (notif_event_enque, notif_push): Update.
4626 (notif_event_xfree, initialize_notif): Remove.
4627 * notif.h (struct notif_event): Include <list>, not
4629 (struct notif_server) <queue>: Now a std::list.
4630 (notif_event_p): Remove typedef.
4631 (initialize_notif): Don't declare.
4632 (struct notif_event): Add virtual destructor.
4634 2019-04-17 Alan Hayward <alan.hayward@arm.com>
4636 * ax.c (ax_vdebug): Call debug_printf.
4637 * debug.c (debug_write): New function.
4638 * debug.h (debug_write): New declaration.
4639 * linux-low.c (sigchld_handler): Call debug_write.
4641 2019-04-17 Alan Hayward <alan.hayward@arm.com>
4643 * debug.c (debug_set_output): New function.
4644 (debug_vprintf): Send output to debug_file.
4645 (debug_flush): Likewise.
4646 * debug.h (debug_set_output): New declaration.
4647 * server.c (handle_monitor_command): Add debug-file option.
4648 (captured_main): Likewise.
4650 2019-04-17 Alan Hayward <alan.hayward@arm.com>
4652 * debug.c (remote_debug): Add definition.
4653 * debug.h (remote_debug): Add declaration.
4654 * hostio.c (remote_debug): Remove declaration.
4655 * remote-utils.c (struct ui_file): Likewise.
4656 (remote_debug): Likewise.
4657 * remote-utils.h (remote_debug): Likewise,
4658 * server.c (remote_debug): Remove definition.
4660 2019-04-10 Kevin Buettner <kevinb@redhat.com>
4662 * linux-x86-low.c (x86_fill_gregset): Sign extend EAX value
4663 when using a 64-bit gdbserver.
4665 2019-04-09 Tom Tromey <tromey@adacore.com>
4667 * linux-low.c (select_event_lwp): Use find_thread_in_random.
4669 2019-04-08 Tom Tromey <tom@tromey.com>
4671 * linux-low.c (linux_detach_one_lwp): Replace throw_exception with
4673 (linux_resume_one_lwp): Likewise.
4675 2019-04-08 Tom Tromey <tom@tromey.com>
4677 * gdbreplay.c: Update.
4678 * linux-low.c: Update.
4681 2019-04-08 Tom Tromey <tom@tromey.com>
4683 * server.c: Use C++ exception handling.
4684 * linux-low.c: Use C++ exception handling.
4685 * gdbreplay.c: Use C++ exception handling.
4687 2019-04-08 Tom Tromey <tom@tromey.com>
4689 * server.c (handle_btrace_general_set, handle_qxfer_btrace)
4690 (handle_qxfer_btrace_conf, detach_or_kill_for_exit_cleanup)
4691 (captured_main, main): Update.
4692 * gdbreplay.c (main): Update.
4694 2019-04-05 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4696 * linux-low.c (linux_get_auxv): Remove static. Return auxv entry
4697 value in argument pointer, return 1 if the entry is found and 0
4698 otherwise. Move comment.
4699 (linux_get_hwcap, linux_get_hwcap2): Use modified linux_get_auxv.
4700 * linux-low.h (linux_get_auxv): Declare.
4701 * linux-ppc-low.c (is_elfv2_inferior): Use linux_get_auxv.
4703 2019-04-05 Tom Tromey <tromey@adacore.com>
4705 * server.c (gdbserver_usage): Use upper-case for metasyntactic
4708 2019-03-28 Alan Hayward <alan.hayward@arm.com>
4710 * linux-low.c (AT_HWCAP2): Add define if not already included.
4712 2019-03-26 Alan Hayward <alan.hayward@arm.com>
4714 * linux-aarch64-low.c (aarch64_get_hwcap): Remove function.
4715 (aarch64_arch_setup): Call linux_get_hwcap.
4716 * linux-arm-low.c (arm_get_hwcap): Remove function.
4717 (arm_read_description): Call linux_get_hwcap.
4718 * linux-low.c (linux_get_auxv): New function.
4719 (linux_get_hwcap): Likewise.
4720 (linux_get_hwcap2): Likewise.
4721 * linux-low.h (linux_get_hwcap): New declaration.
4722 (linux_get_hwcap2): Likewise.
4723 * linux-ppc-low.c (ppc_get_auxv): Remove function.
4724 (ppc_arch_setup): Call linux_get_hwcap.
4725 * linux-s390-low.c (s390_get_hwcap): Remove function.
4726 (s390_arch_setup): Call linux_get_hwcap.
4728 2019-03-22 Alan Hayward <alan.hayward@arm.com>
4729 Jiong Wang <jiong.wang@arm.com>
4731 * linux-aarch64-low.c (aarch64_store_pauthregset): New function.
4732 * linux-low.c (regsets_store_inferior_registers): Allow optional reads
4734 * linux-low.h (enum regset_type): Add OPTIONAL_REGS.
4736 2019-03-22 Alan Hayward <alan.hayward@arm.com>
4737 Jiong Wang <jiong.wang@arm.com>
4739 * linux-aarch64-low.c (AARCH64_HWCAP_PACA): New define.
4740 (aarch64_get_hwcap): New function.
4741 (aarch64_arch_setup): Read APIA hwcap.
4743 2019-03-22 Alan Hayward <alan.hayward@arm.com>
4744 Jiong Wang <jiong.wang@arm.com>
4746 * linux-aarch64-ipa.c (get_ipa_tdesc): Add pauth param.
4747 (initialize_low_tracepoint): Likewise.
4748 * linux-aarch64-low.c (aarch64_arch_setup): Likewise.
4749 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Likewise.
4750 * linux-aarch64-tdesc.c (struct target_desc): Likewise.
4751 (aarch64_linux_read_description): Likewise.
4752 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Likewise.
4754 2019-03-12 John Baldwin <jhb@FreeBSD.org>
4756 * linux-x86-tdesc.c (i386_linux_read_description): Update call to
4757 i386_create_target_description for 'segments' parameter.
4758 * lynx-i386-low.c (lynx_i386_arch_setup): Likewise.
4759 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
4760 * win32-i386-low.c (i386_arch_setup): Likewise.
4762 2019-03-12 Tom Tromey <tromey@adacore.com>
4764 * linux-low.c (iterate_over_lwps): Update.
4766 2019-03-06 Tom Tromey <tom@tromey.com>
4768 * server.c (detach_or_kill_for_exit_cleanup): Remove parameter.
4769 (captured_main): Use SCOPE_EXIT.
4771 2019-03-04 Sergio Durigan Junior <sergiodj@redhat.com>
4773 * configure.srv: Use '$enable_unittest' instead of '$development'
4774 when checking whether to fill 'srv_regobj' on 'aarch64*-*-linux*'
4777 2019-02-27 Tom Tromey <tromey@adacore.com>
4779 * gdbreplay.c (logchar): Handle \r\n.
4781 2019-02-07 Alan Hayward <alan.hayward@arm.com>
4783 * linux-low.c (linux_attach): Add process before lwp.
4784 * server.c (attach_inferior): Check if already attached.
4786 2019-02-07 Tom Tromey <tom@tromey.com>
4788 * x86-tdesc.h: Rename include guard.
4789 * x86-low.h: Add include guard.
4790 * wincecompat.h: Rename include guard.
4791 * win32-low.h: Add include guard.
4792 * utils.h: Rename include guard.
4793 * tracepoint.h: Rename include guard.
4794 * tdesc.h: Rename include guard.
4795 * target.h: Rename include guard.
4796 * server.h: Rename include guard.
4797 * remote-utils.h: Rename include guard.
4798 * regcache.h: Rename include guard.
4799 * nto-low.h: Rename include guard.
4800 * notif.h: Add include guard.
4801 * mem-break.h: Rename include guard.
4802 * lynx-low.h: Add include guard.
4803 * linux-x86-tdesc.h: Add include guard.
4804 * linux-s390-tdesc.h: Add include guard.
4805 * linux-ppc-tdesc-init.h: Add include guard.
4806 * linux-low.h: Add include guard.
4807 * linux-aarch64-tdesc.h: Add include guard.
4808 * linux-aarch32-low.h: Add include guard.
4809 * inferiors.h: Rename include guard.
4810 * i387-fp.h: Rename include guard.
4811 * hostio.h: Rename include guard.
4812 * gdbthread.h: Rename include guard.
4813 * gdb_proc_service.h: Rename include guard.
4814 * event-loop.h: Rename include guard.
4815 * dll.h: Rename include guard.
4816 * debug.h: Rename include guard.
4817 * ax.h: Rename include guard.
4819 2018-01-30 Szabolcs Nagy <szabolcs.nagy@arm.com>
4822 * Makefile.in (IPAGENT_CFLAGS): Add UNDO_GNULIB_CFLAGS.
4823 (UNDO_GNULIB_CFLAGS): Undo gnulib replacements.
4825 2019-01-25 Tom Tromey <tom@tromey.com>
4827 * Makefile.in (INCLUDE_CFLAGS): Don't add -I for common.
4829 2019-01-25 Tom Tromey <tom@tromey.com>
4831 * win32-low.c: Fix common/ includes.
4832 * win32-i386-low.c: Fix common/ includes.
4833 * tracepoint.c: Fix common/ includes.
4834 * thread-db.c: Fix common/ includes.
4835 * target.h: Fix common/ includes.
4836 * symbol.c: Fix common/ includes.
4837 * spu-low.c: Fix common/ includes.
4838 * server.h: Fix common/ includes.
4839 * server.c: Fix common/ includes.
4840 * remote-utils.c: Fix common/ includes.
4841 * regcache.h: Fix common/ includes.
4842 * regcache.c: Fix common/ includes.
4843 * nto-x86-low.c: Fix common/ includes.
4844 * notif.h: Fix common/ includes.
4845 * mem-break.h: Fix common/ includes.
4846 * lynx-low.c: Fix common/ includes.
4847 * lynx-i386-low.c: Fix common/ includes.
4848 * linux-x86-tdesc-selftest.c: Fix common/ includes.
4849 * linux-x86-low.c: Fix common/ includes.
4850 * linux-low.c: Fix common/ includes.
4851 * inferiors.h: Fix common/ includes.
4852 * i387-fp.c: Fix common/ includes.
4853 * hostio.c: Fix common/ includes.
4854 * hostio-errno.c: Fix common/ includes.
4855 * gdbthread.h: Fix common/ includes.
4856 * gdbreplay.c: Fix common/ includes.
4857 * fork-child.c: Fix common/ includes.
4858 * event-loop.c: Fix common/ includes.
4860 (enum gdb_agent_op): Fix common/ includes.
4862 2019-01-21 Tom Tromey <tom@tromey.com>
4864 * tracepoint.c: Fix includes.
4865 * remote-utils.c: Fix includes.
4866 * linux-x86-low.c: Fix includes.
4868 2019-01-01 Joel Brobecker <brobecker@adacore.com>
4870 * gdbreplay.c (gdbreplay_version): Update copyright year in
4872 * server.c (gdbserver_version): Likewise.
4874 2018-12-05 Alan Hayward <alan.hayward@arm.com>
4876 * linux-low.c (add_lwp): Switch ordering.
4878 2018-11-29 Tom Tromey <tom@tromey.com>
4880 * win32-low.c (win32_join): Take pid, not process.
4881 * target.h (struct target_ops) <join>: Change argument type.
4882 (join_inferior): Change argument name.
4883 * spu-low.c (spu_join): Take pid, not process.
4884 * server.c (handle_detach): Preserve pid before destroying
4886 * lynx-low.c (lynx_join): Take pid, not process.
4887 * linux-low.c (linux_join): Take pid, not process.
4889 2018-11-23 Alan Hayward <alan.hayward@arm.com>
4891 * linux-aarch64-low.c (aarch64_cannot_store_register): Remove.
4892 (aarch64_cannot_fetch_register): Likewise.
4893 (struct linux_target_ops): Update references.
4895 2018-10-31 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4897 * linux-ppc-low.c: Include nat/linux-ptrace.h.
4899 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4901 * configure.srv (ipa_ppc_linux_regobj): Add
4902 powerpc-isa207-htm-vsx32l-ipa.o and
4903 powerpc-isa207-htm-vsx64l-ipa.o.
4904 (powerpc*-*-linux*): Add powerpc-isa207-htm-vsx32l.o and
4905 powerpc-isa207-htm-vsx64l.o to srv_regobj. Add
4906 rs6000/power-htm-spr.xml, rs6000/power-htm-core.xml,
4907 rs6000/power64-htm-core.xml, rs6000/power-htm-fpu.xml,
4908 rs6000/power-htm-altivec.xml, rs6000/power-htm-vsx.xml,
4909 rs6000/power-htm-ppr.xml, rs6000/power-htm-dscr.xml,
4910 rs6000/power-htm-tar.xml, rs6000/powerpc-isa207-htm-vsx32l.xml,
4911 and rs6000/powerpc-isa207-htm-vsx64l.xml to srv_xmlfiles.
4912 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
4913 <PPC_TDESC_ISA207_HTM_VSX>: New enum value.
4914 (init_registers_powerpc_isa207_htm_vsx32l)
4915 (init_registers_powerpc_isa207_htm_vsx64l): Declare.
4916 * linux-ppc-low.c (ppc_fill_tm_sprregset, ppc_store_tm_sprregset)
4917 (ppc_store_tm_cgprregset, ppc_store_tm_cfprregset)
4918 (ppc_store_tm_cvrregset, ppc_store_tm_cvsxregset)
4919 (ppc_store_tm_cpprregset, ppc_store_tm_cdscrregset)
4920 (ppc_store_tm_ctarregset): New functions.
4921 (ppc_regsets): Add entries for HTM regsets.
4922 (ppc_arch_setup): Set htm in features struct when needed. Set
4923 sizes for the HTM regsets.
4924 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_HTM_VSX.
4925 (initialize_low_arch): Call
4926 init_registers_powerpc_isa207_htm_vsx32l and
4927 init_registers_powerpc_isa207_htm_vsx64l.
4928 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
4929 PPC_TDESC_ISA207_HTM_VSX.
4930 (initialize_low_tracepoint): Call
4931 init_registers_powerpc_isa207_htm_vsx32l and
4932 init_registers_powerpc_isa207_htm_vsx64l.
4934 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4936 * configure.srv (powerpc*-*-linux*): Add rs6000/power-ebb.xml and
4937 rs6000/power-linux-pmu.xml to srv_xmlfiles.
4938 * linux-ppc-low.c (ppc_store_ebbregset, ppc_fill_pmuregset)
4939 (ppc_store_pmuregset): New functions.
4940 (ppc_regsets): Add entries for ebb and pmu regsets.
4941 (ppc_arch_setup): Set isa207 in features struct if the ebb and
4942 pmu regsets are available. Set sizes for these regsets.
4944 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4946 * configure.srv (ipa_ppc_linux_regobj): Add
4947 powerpc-isa207-vsx64l-ipa.o and powerpc-isa207-vsx32l-ipa.o.
4948 (powerpc*-*-linux*): Add powerpc-isa207-vsx32l.o and
4949 powerpc-isa207-vsx64l.o to srv_regobj, add rs6000/power-tar.xml,
4950 rs6000/powerpc-isa207-vsx32l.xml, and
4951 rs6000/powerpc-isa207-vsx64l.xml to srv_xmlfiles.
4952 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
4953 <PPC_TDESC_ISA207_VSX>: New enum value.
4954 (init_registers_powerpc_isa207_vsx32l): Declare.
4955 (init_registers_powerpc_isa207_vsx64l): Declare.
4956 * linux-ppc-low.c (ppc_fill_tarregset): New function.
4957 (ppc_store_tarregset): New function.
4958 (ppc_regsets): Add entry for the TAR regset.
4959 (ppc_arch_setup): Set isa207 in features struct when needed. Set
4960 size for the TAR regsets.
4961 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_VSX.
4962 (initialize_low_arch): Call init_registers_powerpc_isa207_vsx32l
4963 and init_registers_powerpc_isa207_vsx64l.
4964 * linux-ppc-ipa.c (get_ipa_tdesc): Handle PPC_TDESC_ISA207_VSX.
4965 (initialize_low_tracepoint): Call
4966 init_registers_powerpc_isa207_vsx32l and
4967 init_registers_powerpc_isa207_vsx64l.
4969 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
4970 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4972 * configure.srv (ipa_ppc_linux_regobj): Add
4973 powerpc-isa205-ppr-dscr-vsx32l-ipa.o and
4974 powerpc-isa205-ppr-dscr-vsx64l-ipa.o.
4975 (powerpc*-*-linux*): Add powerpc-isa205-ppr-dscr-vsx32l.o and
4976 powerpc-isa205-ppr-dscr-vsx64l.o to srv_regobj, add
4977 rs6000/power-dscr.xml, rs6000/power-ppr.xml,
4978 rs6000/powerpc-isa205-ppr-dscr-vsx32l.xml and
4979 rs6000/powerpc-isa205-ppr-dscr-vsx64l.xml to srv_xmlfiles.
4980 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
4981 <PPC_TDESC_ISA205_PPR_DSCR_VSX>: New enum value.
4982 (init_registers_powerpc_isa205_ppr_dscr_vsx32l)
4983 (init_registers_powerpc_isa205_ppr_dscr_vsx64l): Declare.
4984 * linux-ppc-low.c: Include "elf/common.h" and <sys/uio.h>.
4985 (ppc_hwcap): Add comment.
4986 (ppc_hwcap2): New global.
4987 (ppc_check_regset, ppc_fill_pprregset, ppc_store_pprregset)
4988 (ppc_fill_dscrregset, ppc_store_dscrregset): New functions.
4989 (ppc_regsets): Add entries for the DSCR and PPR regsets.
4990 (ppc_arch_setup): Get AT_HWCAP2. Set ppr_dscr in features struct
4991 when needed. Set sizes for the the DSCR and PPR regsets.
4992 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA205_PPR_DSCR_VSX.
4993 (initialize_low_arch): Call
4994 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
4995 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
4996 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
4997 PPC_TDESC_ISA205_PPR_DSCR_VSX.
4998 (initialize_low_tracepoint): Call
4999 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
5000 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
5002 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5004 * linux-ppc-low.c (ppc_fill_vrregset): Remove memset calls.
5006 2018-10-10 Sergio Durigan Junior <sergiodj@redhat.com>
5007 Simon Marchi <simark@simark.ca>
5009 * acinclude.m4: Include "../selftest.m4".
5010 * configure: Regenerate.
5011 * configure.ac: Use "GDB_AC_SELFTEST".
5012 * configure.srv: Use "$enable_unittests" instead of
5013 "$development" when checking whether unit tests have been
5015 * server.c (captured_main): Update message informing that
5016 selftests have been disabled.
5018 2018-10-04 Tom Tromey <tom@tromey.com>
5020 * configure: Rebuild.
5022 2018-10-04 Tom Tromey <tom@tromey.com>
5024 * server.c (handle_status): Rename inner "thread".
5025 (process_serial_event): Declare "res" in 'm' case.
5026 * linux-low.c (last_thread_of_process_p, find_lwp_pid)
5027 (iterate_over_lwps): Rename inner "thread".
5028 (linux_qxfer_libraries_svr4): Rename inner "len".
5029 * gdbthread.h (find_thread_in_random): Rename inner "thread".
5031 2018-10-01 Gary Benson <gbenson@redhat.com>
5033 * gdb_proc_service.h: Moved common code to
5034 common/gdb_proc_service.h.
5036 2018-10-01 Gary Benson <gbenson@redhat.com>
5038 * gdb_proc_service.h: Synchronize comments and whitespace with
5039 GDB's version of this file.
5041 2018-09-25 Tom Tromey <tom@tromey.com>
5043 * configure: Rebuild.
5044 * configure.ac (WARN_CFLAGS): Don't remove -Wmissing-prototypes.
5046 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
5048 * Makefile.in (gdbserver$(EXEEXT)): Sort OBS.
5049 (gdbreplay$(EXEEXT)): Sort GDBREPLAY_OBS.
5050 ($(IPA_LIB)): Sort IPA_OBJS.
5052 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
5054 * Makefile.in: Remove references to $(ADD_DEPS).
5056 2018-09-16 Tom Tromey <tom@tromey.com>
5058 * remote-utils.c (remote_open): Use GNU style for metasyntactic
5060 * gdbreplay.c (gdbreplay_usage): Use GNU style for metasyntactic
5063 2018-09-05 Tom Tromey <tom@tromey.com>
5065 * configure: Rebuild.
5067 2018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
5070 * tracepoint.c (IPA_SYM_STRUCT_NAME): Define.
5072 2018-08-27 Tom Tromey <tom@tromey.com>
5075 * configure: Rebuild.
5077 2018-08-27 Tom Tromey <tom@tromey.com>
5079 * linux-s390-low.c (s390_emit_ext, s390_emit_litpool)
5080 (s390_emit_const, s390_emit_reg, s390_emit_zero_ext)
5081 (s390_emit_stack_adjust, s390_emit_set_r2, s390x_emit_ext)
5082 (s390x_emit_const, s390x_emit_reg, s390x_emit_zero_ext)
5083 (s390x_emit_stack_adjust): Add casts to unsigned char.
5085 2018-08-22 Simon Marchi <simon.marchi@ericsson.com>
5089 * server.h (struct client_state) <disable_randomization>:
5092 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
5094 * linux-mips-low.c (mips_collect_ptrace_register): Remove unused
5096 (mips_supply_ptrace_register): Likewise.
5098 2018-07-22 Tom Tromey <tom@tromey.com>
5100 * configure: Rebuild.
5102 2018-07-22 Tom Tromey <tom@tromey.com>
5104 * win32-low.c (win32_create_inferior): Remove unused variables.
5105 * gdbreplay.c (remote_open): Remove unused variable.
5106 * remote-utils.c (remote_prepare): Remove unused variable.
5107 * x86-tdesc.h (X86_TDESC_H): Define.
5108 (amd64_expedite_regs): Define conditionally.
5109 (i386_expedite_regs): Mark ATTRIBUTE_UNUSED.
5110 * linux-x86-tdesc.c (i386_tdescs): Move inside #if.
5111 * remote-utils.c (readchar): Remove unused variable.
5113 2018-07-13 Pedro Alves <palves@redhat.com>
5115 * linux-low.c (linux_kill): Change parameter to process_info
5116 pointer instead of pid. Adjust.
5117 * lynx-low.c (lynx_kill): Likewise.
5118 * nto-low.c (nto_kill): Likewise.
5119 * spu-low.c (spu_kill): Likewise.
5120 * win32-low.c (win32_kill): Likewise.
5121 * server.c (handle_v_kill, kill_inferior_callback)
5122 (detach_or_kill_for_exit): Adjust.
5123 * target.c (kill_inferior): Change parameter to process_info
5124 pointer instead of pid. Adjust.
5125 * target.h (struct target_ops) <kill>: Change parameter to
5126 process_info pointer instead of pid. Adjust all implementations
5128 (kill_inferior): Likewise.
5130 2018-07-13 Pedro Alves <palves@redhat.com>
5132 * linux-low.c (linux_detach, linux_join): Change parameter to
5133 process_info pointer instead of pid. Adjust.
5134 * lynx-low.c (lynx_detach, lynx_join): Likewise.
5135 * nto-low.c (nto_detach): Likewise.
5136 * spu-low.c (spu_detach, spu_join): Likewise.
5137 * win32-low.c (win32_detach, win32_join): Likewise.
5138 * server.c (handle_detach, detach_or_kill_for_exit): Adjust.
5139 * target.h (struct target_ops) <detach, join>: Change parameter to
5140 process_info pointer instead of pid. Adjust all implementations
5142 (detach_inferior, join_inferior): Rename 'pid' parameter to
5145 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
5146 Jan Kratochvil <jan.kratochvil@redhat.com>
5147 Paul Fertser <fercerpav@gmail.com>
5148 Tsutomu Seki <sekiriki@gmail.com>
5150 * Makefile.in (SFILES): Add '$(srcdir)/common/netstuff.c'.
5151 (OBS): Add 'common/netstuff.o'.
5152 (GDBREPLAY_OBS): Likewise.
5153 * gdbreplay.c: Include 'wspiapi.h' and 'netstuff.h'.
5154 (remote_open): Implement support for IPv6
5156 * remote-utils.c: Include 'netstuff.h', 'filestuff.h'
5158 (handle_accept_event): Accept connections from IPv6 sources.
5159 (remote_prepare): Handle IPv6-style hostnames; implement
5160 support for IPv6 connections.
5161 (remote_open): Implement support for printing connections from
5164 2018-07-11 Pedro Alves <palves@redhat.com>
5167 * mem-break.c (any_persistent_commands): Add process_info
5168 parameter and use it instead of relying on the current process.
5169 Change return type to bool.
5170 * mem-break.h (any_persistent_commands): Add process_info
5171 parameter and change return type to bool.
5172 * server.c (handle_detach): Remove require_running_or_return call.
5173 Look up the process_info for the process we're about to detach.
5174 If not found, return back error to GDB. Adjust
5175 any_persistent_commands call to pass down a process pointer.
5177 2018-07-11 Pedro Alves <palves@redhat.com>
5179 * i387-fp.c (i387_cache_to_fsave, cache_to_fxsave)
5180 (i387_cache_to_xsave): Use regcache_raw_get_unsigned_by_name
5181 instead of collect_register_by_name.
5182 * regcache.c (regcache_raw_get_unsigned_by_name): New.
5183 * regcache.h (regcache_raw_get_unsigned_by_name): New.
5185 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
5186 Pedro Alves <palves@redhat.com>
5188 * linux-low.c (initialize_low): Call linux_proc_init_warnings.
5190 2018-07-03 Tom Tromey <tom@tromey.com>
5192 * linux-low.c: Update.
5193 * lynx-low.c: Update.
5194 * mem-break.c: Update.
5195 * nto-low.c: Update.
5196 * remote-utils.c: Update.
5198 * spu-low.c: Update.
5200 * win32-low.c: Update.
5202 2018-07-03 Tom Tromey <tom@tromey.com>
5206 2018-07-03 Tom Tromey <tom@tromey.com>
5208 * linux-low.c: Update.
5210 2018-07-03 Tom Tromey <tom@tromey.com>
5214 2018-07-03 Tom Tromey <tom@tromey.com>
5216 * linux-low.c: Update.
5217 * linux-mips-low.c: Update.
5218 * lynx-low.c: Update.
5219 * nto-low.c: Update.
5220 * remote-utils.c: Update.
5222 * spu-low.c: Update.
5224 * thread-db.c: Update.
5226 2018-07-03 Tom Tromey <tom@tromey.com>
5228 * linux-low.c: Update.
5229 * linux-mips-low.c: Update.
5230 * lynx-low.c: Update.
5231 * mem-break.c: Update.
5232 * nto-low.c: Update.
5233 * remote-utils.c: Update.
5235 * spu-low.c: Update.
5237 * tracepoint.c: Update.
5239 2018-07-03 Tom Tromey <tom@tromey.com>
5241 * linux-low.c: Update.
5242 * linux-ppc-low.c: Update.
5243 * linux-x86-low.c: Update.
5244 * proc-service.c: Update.
5246 * spu-low.c: Update.
5247 * thread-db.c: Update.
5248 * win32-low.c: Update.
5250 2018-07-03 Tom Tromey <tom@tromey.com>
5252 * linux-low.c: Update.
5253 * lynx-low.c: Update.
5254 * nto-low.c: Update.
5255 * remote-utils.c: Update.
5256 * spu-low.c: Update.
5257 * thread-db.c: Update.
5258 * win32-low.c: Update.
5260 2018-06-29 Joel Brobecker <brobecker@adacore.com>
5262 * linux-x86-tdesc.c (amd64_linux_read_description): Add missing
5263 parameter in call to 'amd64_create_target_description'.
5265 2018-06-28 Jan Kratochvil <jan.kratochvil@redhat.com>
5267 * x86-tdesc.h: Remove executable permission flag.
5269 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
5271 * configure.ac: Remove AC_PREREQ, add missing quoting.
5272 * configure: Re-generate.
5273 * config.in: Re-generate.
5274 * aclocal.m4: Re-generate.
5276 2018-06-18 Simon Marchi <simon.marchi@ericsson.com>
5278 * tracepoint.h (current_traceframe): Remove declaration.
5280 2018-06-18 Alan Hayward <alan.hayward@arm.com>
5282 * linux-aarch64-low.c (is_sve_tdesc): New function.
5283 (aarch64_sve_regs_copy_to_regcache): Likewise.
5284 (aarch64_sve_regs_copy_from_regcache): Likewise.
5285 (aarch64_regs_info): Add SVE checks.
5286 (initialize_low_arch): Initialize SVE.
5288 2018-06-18 Alan Hayward <alan.hayward@arm.com>
5290 * Makefile.in: Add aarch64-sve-linux-ptrace.c.
5292 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5294 * linux-aarch64-ipa.c (get_ipa_tdesc): Add null VQ param.
5295 (initialize_low_tracepoint): Likewise
5296 * linux-aarch64-low.c (aarch64_arch_setup): Get VQ.
5297 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Add null VQ
5299 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add VQ
5301 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Add VQ.
5303 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5305 * server.h (PBUFSIZ): Increase size
5307 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5309 * regcache.c (regcache::raw_compare): New function.
5310 * regcache.h (regcache::raw_compare): New declaration.
5312 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5314 * regcache.c (new_register_cache): Use new.
5315 (free_register_cache): Use delete.
5316 (register_data): Use const.
5317 (supply_register): Move body inside regcache.
5318 (regcache::raw_supply): New override function.
5319 (collect_register): Move body inside regcache.
5320 (regcache::raw_collect): New override function.
5321 (regcache::get_register_status): New override function.
5322 * regcache.h (struct regcache): Inherit from reg_buffer_common.
5324 2018-06-09 Tom Tromey <tom@tromey.com>
5326 * event-loop.c (gdb_event, gdb_event_p): Remove typedefs. Don't
5328 (event_queue): Use std::queue.
5329 (gdb_event_xfree): Remove.
5330 (initialize_event_loop, process_event, wait_for_event): Update.
5332 2018-06-08 Stan Cox <scox@redhat.com>
5334 * win32-low.c (win32_create_inferior): last_ptid and last_status
5335 moved to client_state.
5337 2018-06-08 Pedro Alves <palves@redhat.com>
5339 * Makefile.in (GDBREPLAY_OBS): Add common/cleanups.o,
5340 common/common-exceptions.o, common/common-utils.o,
5341 common/errors.o, common/print-utils.o and utils.o.
5342 * gdbreplay.c: Include "common-defs.h" instead of the two
5343 'config.h's here. Don't include stdio.h, errno.h, stdlib.h,
5344 string.h or alloca.h.
5345 (perror_with_name): Delete.
5346 (remote_open): Use xstrdup instead of strdup.
5347 (main): Rename to ...
5348 (captured_main): ... this.
5351 2018-06-08 Tom Tromey <tom@tromey.com>
5353 * linux-low.c (linux_low_read_btrace): Update.
5355 2018-06-04 Stan Cox <scox@redhat.com>
5357 * server.h (struct client_state): New.
5358 * server.c (cont_thread, general_thread, multi_process)
5359 (report_fork_events, report_vfork_events, report_exec_events)
5360 (report_thread_events, swbreak_feature, hwbreak_feature)
5361 (vCont_supported, disable_randomization, pass_signals)
5362 (program_signals, program_signals_p, last_status, last_ptid, own_buf):
5363 Moved to client_state.
5364 * remote-utils.c (remote_debug, noack_mode)
5365 (transport_is_reliable): Moved to client_state.
5366 * tracepoint.c (current_traceframe): Moved to client_state.
5369 * server.c, remote-utils.c, tracepoint.c, fork-child.c,
5370 linux-low.c, remote-utils.h, target.c: Use client_state.
5372 2018-05-31 Alan Hayward <alan.hayward@arm.com>
5374 * configure.srv: Add new c/h file.
5376 2018-05-31 Alan Hayward <alan.hayward@arm.com>
5378 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add
5381 2018-05-25 Maciej W. Rozycki <macro@mips.com>
5383 * gdb.arch/mips-fpregset-core.exp: New test.
5384 * gdb.arch/mips-fpregset-core.c: New test source.
5386 2018-05-23 Erik Kurzinger <ekurzinger@nvidia.com>
5389 * hostio.c (require_int): Do not report overflow for integers
5390 between 0xfffffff and 0x7fffffff.
5392 2018-05-22 Maciej W. Rozycki <macro@mips.com>
5394 * linux-mips-low.c [HAVE_PTRACE_GETREGS] (mips_collect_register)
5395 (mips_supply_register): Move outside HAVE_PTRACE_GETREGS.
5396 (mips_collect_ptrace_register, mips_supply_ptrace_register): New
5398 (the_low_target): Wire them.
5400 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5402 * linux-ppc-low.c (ppc_fill_vrregset): Add vscr_offset variable.
5403 Set vscr_offset to 0 in little-endian mode and 12 in big-endian
5404 mode. Call collect_register_by_name with vscr using
5405 vscr_offset. Zero-pad vscr and vrsave fields in collector buffer.
5406 (ppc_store_vrregset): Add and set vscr_offset variable as in
5407 ppc_fill_vrregset. Call supply_register_by_name with vscr using
5410 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5412 * linux-ppc-low.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
5413 (ppc_arch_setup): Change SIZEOF_VRREGS and SIZEOF_VSXREGS to
5414 PPC_LINUX_SIZEOF_VRREGSET and PPC_LINUX_SIZEOF_VSXREGSET.
5416 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5418 * linux-ppc-low.c (ppc_fill_vsxregset): Remove ppc_hwcap check.
5419 (ppc_store_vsxregset): Likewise.
5420 (ppc_fill_vrregset): Likewise.
5421 (ppc_store_vrregset): Likewise.
5422 (ppc_fill_evrregset): Likewise.
5423 (ppc_store_evrregset): Likewise.
5424 (ppc_regsets): Set VSX/VR/EVR regset sizes to 0.
5425 (ppc_arch_setup): Iterate through ppc_regsets and set sizes when
5428 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5430 * linux-ppc-low.c (ppc_arch_setup): Remove code for getting the
5431 wordsize of the inferior. Call ppc_linux_target_wordsize.
5433 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5435 * configure.srv (srv_tgtobj): Add arch/ppc-linux-common.o.
5436 * Makefile.in (SFILES): Add arch/ppc-linux-common.c.
5437 * linux-ppc-tdesc.h: Rename to linux-ppc-tdesc-init.h.
5438 * linux-ppc-tdesc-init.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
5439 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
5440 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
5441 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
5442 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
5443 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
5444 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
5445 (tdesc_powerpc_e500l): Remove.
5446 * linux-ppc-ipa.c: Include arch/ppc-linux-tdesc.h and
5447 linux-ppc-tdesc-init.h. Don't include linux-ppc-tdesc.h.
5448 * linux-ppc-low.c: Include arch/ppc-linux-common.h,
5449 arch/ppc-linux-tdesc.h, and linux-ppc-tdesc-init.h. Don't include
5451 (ppc_arch_setup): Remove target description matching code. Fill a
5452 ppc_linux_features struct and call ppc_linux_match_description
5455 2018-05-22 Maciej W. Rozycki <macro@mips.com>
5457 * linux-mips-low.c (mips_cannot_fetch_register): Return 1 if the
5458 width of the requested register exceeds the width of the
5460 (mips_cannot_store_register): Likewise.
5462 2018-05-21 Maciej W. Rozycki <macro@mips.com>
5464 * linux-mips-low.c (mips_fetch_register): New function. Update
5466 (mips_store_gregset): Supply 0 rather than $restart for $zero.
5467 (the_low_target): Wire `mips_fetch_register'.
5469 2018-05-10 Joel Brobecker <brobecker@adacore.com>
5471 * lynx-i386-low.c (LYNXOS_178): New macro.
5472 [LYNXOS_178] (usr_fcontext_t): Provide a definition that matches
5473 the layout on LynxOS-178.
5474 (lynx_i386_fill_fpregset, lynx_i386_store_fpregset): Do not
5475 handle floating point registers that are not supported by
5478 2018-05-10 Tom Tromey <tom@tromey.com>
5480 * configure: Rebuild.
5482 2018-05-10 Joel Brobecker <brobecker@adacore.com>
5485 * tdesc.h (init_target_desc) <expedite_regs>: New parameter.
5486 * tdesc.c (init_target_desc) <expedite_regs>: New parameter.
5487 Use it to set the expedite_regs field in the given tdesc.
5488 * x86-tdesc.h: New file.
5489 * linux-aarch64-tdesc.c (aarch64_linux_read_description):
5490 Adjust following the addition of the new expedite_regs parameter
5491 to init_target_desc.
5492 * linux-tic6x-low.c (tic6x_read_description): Likewise.
5493 * linux-x86-tdesc.c: #include "x86-tdesc.h".
5494 (i386_linux_read_description, amd64_linux_read_description):
5495 Adjust following the addition of the new expedite_regs parameter
5496 to init_target_desc.
5497 * lynx-i386-low.c: #include "x86-tdesc.h".
5498 (lynx_i386_arch_setup): Adjust following the addition of the new
5499 expedite_regs parameter to init_target_desc.
5500 * nto-x86-low.c: #include "x86-tdesc.h".
5501 (nto_x86_arch_setup): Adjust following the addition of the new
5502 expedite_regs parameter to init_target_desc.
5503 * win32-i386-low.c: #include "x86-tdesc.h".
5504 (i386_arch_setup): Adjust following the addition of the new
5505 expedite_regs parameter to init_target_desc.
5507 2018-05-10 Joel Brobecker <brobecker@adacore.com>
5510 * win32-low.c (win32_create_inferior): Add call to my_wait
5511 setting last_status global.
5513 2018-05-10 Joel Brobecker <brobecker@adacore.com>
5516 * win32-low.c (create_process): Only call gdb_tilde_expand if
5517 inferior_cwd is not NULL.
5519 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
5521 * i387-fp.c (i387_cache_to_xsave): Only write x87 control
5522 registers to the cache if their values have changed.
5523 (i387_xsave_to_cache): Provide default values for x87 control
5524 registers when these features are available, but disabled.
5525 * regcache.c (supply_register_by_name_zeroed): New function.
5526 * regcache.h (supply_register_by_name_zeroed): Declare new
5529 2018-05-07 Tom Tromey <tom@tromey.com>
5531 * configure: Rebuild.
5533 2018-05-04 Tom Tromey <tom@tromey.com>
5535 * configure: Rebuild.
5537 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
5538 Pedro Alves <palves@redhat.com>
5540 * linux-aarch64-low.c (aarch64_stopped_data_address):
5543 2018-04-27 Tom Tromey <tom@tromey.com>
5545 * configure: Rebuild.
5547 2018-04-23 Tom Tromey <tom@tromey.com>
5549 * configure: Rebuild.
5551 2018-04-19 Simon Marchi <simon.marchi@ericsson.com>
5553 * Makefile.in (depcomp): Add "..".
5554 (all_deps_files): New and use it.
5556 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5558 * configure.srv (aarch64*-*-linux*): Don't include xml.
5559 (i[34567]86-*-cygwin*): Likewise.
5560 (i[34567]86-*-linux*): Likewise.
5561 (i[34567]86-*-lynxos*): Likewise.
5562 (i[34567]86-*-mingw32ce*): Likewise.
5563 (i[34567]86-*-mingw*): Likewise.
5564 (i[34567]86-*-nto*): Likewise.
5565 (tic6x-*-uclinux): Likewise.
5566 (x86_64-*-linux*): Likewise.
5567 (x86_64-*-mingw*): Likewise.
5568 (x86_64-*-cygwin*): Likewise.
5570 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5572 * tdesc.c: Remove xml parameter.
5574 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5576 * server.c (get_features_xml): Remove cast.
5577 * tdesc.c (void target_desc::accept): Fill in function.
5578 (tdesc_get_features_xml): Remove old xml creation.
5579 (print_xml_feature::visit_pre): Add xml vistor.
5580 * tdesc.h (struct target_desc): Make xmltarget mutable.
5581 (tdesc_get_features_xml): Remove declaration.
5583 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5585 * tdesc.c (tdesc_architecture_name): Add new function.
5586 (tdesc_osabi_name): Likewise.
5587 (tdesc_get_features_xml): Use new functions.
5589 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5591 * tdesc.c (tdesc_create_flags): Remove.
5592 (tdesc_add_flag): Likewise.
5593 (tdesc_named_type): Likewise.
5594 (tdesc_create_union): Likewise.
5595 (tdesc_create_struct): Likewise.
5596 (tdesc_create_vector): Likewise.
5597 (tdesc_add_bitfield): Likewise.
5598 (tdesc_add_field): Likewise.
5599 (tdesc_set_struct_size): Likewise.
5601 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5603 * tdesc.c (~target_desc): Remove implictly deleted items.
5604 (init_target_desc): Iterate all features.
5605 (tdesc_get_features_xml): Use vector.
5606 (tdesc_create_feature): Create feature.
5607 * tdesc.h (tdesc_feature) Remove
5608 (target_desc): Add features.
5610 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5612 * Makefile.in: Add common/tdesc.c
5613 * tdesc.c (init_target_desc): init all reg_defs from register
5615 (tdesc_create_reg): Create tdesc_reg.
5616 * tdesc.h (tdesc_feature): Add register vector.
5618 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
5620 * tdesc.h (struct target_desc) <features>: Change type to
5621 std::vector<std::string>.
5622 * tdesc.c (target_desc::~target_desc): Adjust to std::vector
5624 (tdesc_get_features_xml): Likewise.
5625 (tdesc_create_feature): Likewise.
5627 2018-03-26 Alan Hayward <alan.hayward@arm.com>
5629 * regcache.c (find_register_by_number): Return a ref.
5630 (find_regno): Use references.
5631 (register_size): Likewise.
5632 (register_data): Likewise.
5633 * tdesc.c (target_desc::~target_desc): Remove free calls.
5634 (target_desc::operator==): Use std::vector compare.
5635 (init_target_desc): Use reference.
5636 (tdesc_create_reg): Use reg constructors.
5637 * tdesc.h (struct target_desc): Replace pointer with object.
5639 2018-03-23 Alan Hayward <alan.hayward@arm.com>
5641 * regcache.c (find_register_by_number): Make static.
5642 (find_regno): Use find_register_by_number
5643 * regcache.h (struct reg): Remove declaration.
5645 2018-03-23 Alan Hayward <alan.hayward@arm.com>
5647 * tdesc.c (target_desc::~target_desc): Move to here.
5648 (target_desc::operator==): Likewise.
5649 * tdesc.h (target_desc::~target_desc): Move from here.
5650 (target_desc::operator==): Likewise.
5652 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
5654 * linux-s390-low.c (s390_get_wordsize): Correct brace style.
5656 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
5658 * linux-s390-ipa.c (get_ipa_tdesc): Add handling for
5660 * linux-s390-low.c (s390_get_ipa_tdesc_idx): Likewise.
5661 (initialize_low_tracepoint): Call init_registers_s390x_gs_linux64
5662 and init_registers_s390_gs_linux64.
5664 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
5666 * linux-s390-low.c (s390_fill_gs): Remove function.
5667 (s390_fill_gsbc): Remove function.
5668 (s390_regsets): Set fill functions for the guarded storage regsets
5671 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
5673 * linux-s390-low.c (s390_get_hwcap): Replace tdesc parameter by
5674 the word size. Add comment.
5675 (s390_get_wordsize): New function.
5676 (s390_arch_setup): No longer select a temporary tdesc to fetch the
5677 pswm with it. Instead, use s390_get_wordsize to determine the
5678 word size first and derive the correct tdesc from that directly.
5680 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
5682 * Makefile.in: Include silent-rules.mk.
5683 (srcdir, abs_top_srcdir, abs_srcdir, VPATH): Move up.
5684 (COMPILE): Add ECHO_CXX.
5685 (gdbserver$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
5686 (gdbreplay$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
5687 ($(IPA_LIB)): Add SILENCE and ECHO_CXXLD.
5688 (version-generated.c): Add ECHO_GEN.
5689 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN_GENERATED.
5690 (IPAGENT_COMPILE): Add ECHO_CXX.
5691 (%-generated.c): Add ECHO_REGDAT.
5693 2018-03-14 Tom Tromey <tom@tromey.com>
5696 * ax.c (ax_printf): Special case for NULL.
5698 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
5700 * linux-low.c (linux_qxfer_libraries_svr4): Use
5701 xml_escape_text_append.
5703 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
5705 * linux-low.c (linux_qxfer_libraries_svr4): Use std::string.
5707 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
5709 * server.c (handle_general_set): Remove unnecessary xstrdup.
5711 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
5713 * server.c (parse_debug_format_options): Adjust to
5714 delim_string_to_char_ptr_vec changes.
5715 * thread-db.c (thread_db_load_search): Adjust to
5716 dirnames_to_char_ptr_vec changes.
5718 2018-03-01 Markus Metzger <markus.t.metzger@intel.com>
5720 * target.h (target_enable_btrace, target_disable_btrace)
5721 (target_read_btrace, target_read_btrace_conf): Turn macro into
5722 inline function. Throw error if target method is not defined.
5723 * server.c (handle_qxfer_btrace handle_qxfer_btrace_conf): Remove
5724 check for btrace target method. Be prepared to handle exceptions
5725 from btrace target methods.
5727 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
5729 * server.c (captured_main): Change order of error message printed
5730 when the current working directory cannot be found.
5732 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
5734 * server.c: Include "filenames.h" and "pathstuff.h".
5735 (program_name): Delete variable.
5736 (program_path): New anonymous class.
5737 (get_exec_wrapper): Use "program_path" instead of
5739 (handle_v_run): Likewise.
5740 (captured_main): Likewise.
5741 (process_serial_event): Likewise.
5743 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
5745 * Makefile.in (SFILES): Add "$(srcdir)/common/pathstuff.c".
5746 (OBJS): Add "pathstuff.o".
5747 * server.c (current_directory): New global variable.
5748 (captured_main): Initialize "current_directory".
5750 2018-02-26 Alan Hayward <alan.hayward@arm.com>
5752 * tdesc.c: Use common/tdesc.h.
5753 * tdesc.h: Likewise.
5755 2018-02-20 Alan Hayward <alan.hayward@arm.com>
5756 Simon Marchi <simon.marchi@ericsson.com>
5758 * Makefile.in: Switch order of make rules.
5760 2018-02-19 Alan Hayward <alan.hayward@arm.com>
5762 * Makefile.in: Add common directory in build.
5763 * configure.ac: Add common reference.
5764 * configure: Regenerate.
5766 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
5768 * linux-low.c (linux_target_ops): Remove linux_supports_btrace.
5769 * nto-low.c (nto_target_ops): Remove NULL for supports_btrace.
5770 * spu-low.c (spu_target_ops): Likewise.
5771 * win32-low.c (win32_target_ops): Likewise.
5772 * server.c (supported_btrace_packets): Report packets unconditionally.
5773 * target.h (target_ops) <supports_btrace>: Remove.
5774 (target_supports_btrace): Remove.
5776 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
5778 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt)
5779 (handle_btrace_disable): Change return type to void. Use exceptions
5781 (handle_btrace_general_set): Catch exception and copy message to
5784 2018-02-08 Tom Tromey <tom@tromey.com>
5786 * linux-low.c (install_software_single_step_breakpoints): Use
5787 make_scoped_restore.
5788 * inferiors.c (make_cleanup_restore_current_thread): Remove.
5789 (do_restore_current_thread_cleanup): Remove.
5790 * gdbthread.h (make_cleanup_restore_current_thread): Don't
5793 2018-02-08 Tom Tromey <tom@tromey.com>
5795 * mem-break.c (set_raw_breakpoint_at): Use
5796 gdb::unique_xmalloc_ptr.
5798 2018-01-30 Pedro Alves <palves@redhat.com>
5801 * target.c (target_terminal::terminal_state): Rename to ...
5802 (target_terminal::m_terminal_state): ... this.
5804 2018-01-19 James Clarke <jrtc27@jrtc27.com>
5806 * linux-low.c (handle_extended_wait): Surround call to
5807 thread_db_notice_clone with #ifdef USE_THREAD_DB.
5809 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
5811 * linux-low.c (attach_proc_task_lwp_callback): Adjust to
5812 linux_ptrace_attach_fail_reason_string now returning an
5814 (linux_attach): Likewise.
5815 * thread-db.c (attach_thread): Likewise.
5817 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
5820 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
5821 checking for fs_base/gs_base fields in struct user_regs_struct.
5822 * configure: Regenerate.
5824 2018-01-16 Yao Qi <yao.qi@linaro.org>
5827 * linux-low.c (fetch_register): Call supply_register instead of
5830 2018-01-08 Yao Qi <yao.qi@linaro.org>
5831 Simon Marchi <simon.marchi@ericsson.com>
5833 * Makefile.in (OBS): Remove selftest.o.
5834 * configure.ac: Set srv_selftest_objs if $development is true.
5835 (GDBSERVER_DEPFILES): Append $srv_selftest_objs.
5836 * configure: Re-generated.
5837 * server.c (captured_main): Wrap variable selftest_filter with
5840 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
5842 * server.c (parse_debug_format_options): Return std::string.
5843 (handle_monitor_command, captured_main): Adjust.
5845 2018-01-05 Pedro Alves <palves@redhat.com>
5848 * server.c (captured_main): Pass quiet=false to
5849 save_original_signals_state.
5851 2018-01-01 Joel Brobecker <brobecker@adacore.com>
5853 * gdbreplay.c (gdbreplay_version): Update copyright year in
5855 * server.c (gdbserver_version): Likewise.
5857 2017-12-08 Tom Tromey <tom@tromey.com>
5859 * ax.c (ax_printf): Update.
5861 2017-12-07 Yao Qi <yao.qi@linaro.org>
5863 * linux-aarch64-ipa.c (initialize_low_tracepoint): Call
5864 aarch64_linux_read_description.
5865 * linux-amd64-ipa.c (idx2mask): New array.
5866 (get_ipa_tdesc): Move idx2mask out.
5867 (initialize_low_tracepoint): Initialize target descriptions.
5868 * linux-i386-ipa.c (idx2mask): New array.
5869 (get_ipa_tdesc): Move idx2mask out.
5870 (initialize_low_tracepoint): Initialize target descriptions.
5872 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
5874 * tdesc.c (struct tdesc_type): Change return type.
5875 (tdesc_add_flag): Change parameter type.
5876 (tdesc_add_bitfield): Likewise.
5877 (tdesc_add_field): Likewise.
5878 (tdesc_set_struct_size): Likewise.
5880 2017-12-05 Simon Marchi <simon.marchi@ericsson.com>
5882 * regcache.c (registers_to_string): Remove unused variable.
5884 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5886 * inferiors.c (for_each_inferior_with_data): Remove.
5887 * inferiors.h (for_each_inferior_with_data): Remove.
5888 * server.c (handle_qxfer_threads_worker): Change parameter type.
5889 (handle_qxfer_threads_proper): Use for_each_thread.
5891 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5893 * inferiors.c (for_each_inferior): Remove.
5894 (clear_inferiors): Use for_each_thread.
5895 * inferiors.h (for_each_inferior): Remove.
5896 * linux-low.c (linux_wait_for_event_filtered): Use
5898 (linux_stabilize_threads): Likewise.
5899 * regcache.c (regcache_release): Likewise.
5900 * server.c (gdb_wants_all_threads_stopped): Likewise.
5901 (clear_pending_status_callback): Remove.
5902 (handle_status): Use for_each_thread.
5903 (captured_main): Likewise.
5904 * win32-low.c (child_init_thread_list): Likewise.
5905 (win32_clear_inferiors): Likewise.
5906 (fake_breakpoint_event): Likewise.
5908 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5910 * inferiors.h (find_inferior): Remove.
5911 * inferiors.c (find_inferior): Remove.
5913 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5915 * linux-low.c (resume_status_pending_p): Update comment.
5916 (need_step_over_p): Update comment.
5918 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5920 * linux-low.c (proceed_one_lwp): Return void, change parameter
5922 (unsuspend_and_proceed_one_lwp): Likewise.
5923 (proceed_all_lwps): Use for_each_thread.
5924 (unstop_all_lwps): Likewise.
5926 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5928 * linux-low.c (linux_resume_one_thread): Return void, take
5930 (linux_resume): Use for_each_thread.
5932 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5934 * linux-low.c (send_sigstop_callback): Return void, change
5935 parameter type. Rename to...
5936 (send_sigstop): ... this.
5937 (suspend_and_send_sigstop_callback): Return void, change parameter
5939 (suspend_and_send_sigstop): ... this.
5940 (stop_all_lwps): Use for_each_thread.
5942 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5944 * linux-low.c (lwp_running): Return bool, remove unused
5946 (linux_stabilize_threads): Use find_thread.
5948 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5950 * linux-low.c (select_singlestep_lwp_callback): Remove.
5951 (count_events_callback): Remove.
5952 (select_event_lwp_callback): Remove.
5953 (select_event_lwp): Use find_thread/for_each_thread.
5955 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5957 * linux-low.c (not_stopped_callback): Return bool, take filter
5959 (linux_wait_for_event_filtered): Use find_thread.
5960 (linux_wait_1): Likewise.
5962 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5964 * linux-low.c (same_lwp): Remove.
5965 (find_lwp_pid): Use find_thread.
5967 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5969 * linux-low.c (delete_lwp_callback): Remove.
5970 (linux_mourn): Use for_each_thread.
5972 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5974 * linux-low.c (linux_detach_lwp_callback): Return void, remove
5975 args parameter, don't check for pid.
5976 (linux_detach): Use for_each_thread.
5978 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5980 * linux-low.c (struct counter): Remove.
5981 (second_thread_of_pid_p): Remove.
5982 (last_thread_of_process_p): Use find_thread.
5984 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5986 * inferiors.c (find_inferior_in_random): Remove.
5987 * inferiors.h (find_inferior_in_random): Remove.
5988 * linux-low.c (status_pending_p_callback): Return bool, accept
5989 parameter ptid directly.
5990 (linux_wait_for_event_filtered): Use find_thread_in_random.
5991 (linux_wait_1): Likewise.
5993 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
5995 * inferiors.c (find_inferior_id): Remove.
5996 (find_thread_ptid): Move implemention from find_inferior_id to
5998 * inferiors.h (find_inferior_id): Remove.
5999 * server.c (handle_status): Use find_thread_ptid.
6000 (process_serial_event): Likewise.
6001 * thread-db.c (find_one_thread): Likewise.
6002 (thread_db_thread_handle): Likewise.
6003 * win32-low.c (thread_rec): Likewise.
6004 (child_delete_thread): Likewise.
6005 (win32_thread_alive): Likewise.
6006 (get_child_debug_event): Likewise.
6008 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6010 * linux-mips-low.c (update_watch_registers_callback): Return
6011 void, remove pid_p parameter, don't check for pid.
6012 (mips_insert_point, mips_remove_point): Use for_each_thread.
6014 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6016 * lynx.low (lynx_delete_thread_callback): Remove.
6017 (lynx_mourn): Use for_each_thread.
6019 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
6021 * regcache.c (regcache_invalidate_one): Remove.
6022 (regcache_invalidate_pid): use for_each_thread.
6024 2017-11-26 Tom Tromey <tom@tromey.com>
6026 * linux-low.c (linux_create_inferior): Update.
6028 2017-11-24 Ulrich Weigand <uweigand@de.ibm.com>
6030 * spu-low.c (spu_create_inferior): Fix typo in argument name.
6032 2017-11-24 Alan Hayward <alan.hayward@arm.com>
6034 * configure.srv: Add linux-aarch64-tdesc-selftest.o.
6035 * linux-aarch64-low.c (initialize_low_arch): Call init func.
6036 * linux-aarch64-tdesc-selftest.c: New file.
6037 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
6039 2017-11-24 Alan Hayward <alan.hayward@arm.com>
6041 * configure.srv: Add new file.
6042 * linux-aarch64-low.c (initialize_low_arch): Call init func.
6043 * linux-aarch64-tdesc-selftest.c: New file.
6044 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
6046 2017-11-24 Alan Hayward <alan.hayward@arm.com>
6048 * linux-aarch64-ipa.c (initialize_low_tracepoint): Remove init.
6049 * linux-aarch64-low.c (initialize_low_arch): Remove init.
6050 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add init.
6052 2017-11-24 Alan Hayward <alan.hayward@arm.com>
6054 * configure.srv: Add new files.
6055 * linux-aarch64-ipa.c (get_ipa_tdesc): Call
6056 aarch64_linux_read_description.
6057 * linux-aarch64-low.c (aarch64_linux_read_description):
6058 Merge with aarch64_arch_setup.
6059 (aarch64_arch_setup): Call aarch64_linux_read_description.
6060 * linux-aarch64-tdesc.c: New file.
6061 * linux-aarch64-tdesc.h: New file.
6063 2017-11-24 Yao Qi <yao.qi@linaro.org>
6065 * configure.srv: Set $srv_regobj for tic6x-linux.
6066 * linux-tic6x-low.c: Include "arch/tic6x.h" and "tdesc.h".
6067 (tic6x_read_description): Move some code to tic6x_arch_setup.
6068 (tic6x_tdesc_test): New function.
6069 (initialize_low_arch): Call selftests::register_test.
6071 2017-11-22 Yao Qi <yao.qi@linaro.org>
6073 * remote-utils.c (prepare_resume_reply): Use memcpy.
6075 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6077 * linux-low.c (kill_one_lwp_callback): Return void, take
6078 argument directly, don't filter on pid.
6079 (linux_kill): Use for_each_thread.
6081 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6083 * linux-low.c (need_step_over_p): Return bool, remove dummy
6085 (linux_resume, proceed_all_lwps): Use find_thread.
6087 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6089 * linux-low.c (resume_status_pending_p): Return bool, remove
6091 (linux_resume): Use find_thread.
6093 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6095 * linux-low.c (struct thread_resume_array): Remove.
6096 (linux_set_resume_request): Return void, take arguments
6098 (linux_resume): Use for_each_thread.
6100 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6102 * linux-low.c (stuck_in_jump_pad_callback): Change prototype,
6103 return bool, remove data argument.
6104 (linux_stabilize_threads): Use find_thread.
6106 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6108 * linux-low.c (unsuspend_one_lwp): Remove.
6109 (unsuspend_all_lwps): Use for_each_thread, inline code from
6112 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6114 * gdbthread.h (find_thread): Add overload with ptid_t filter.
6115 * linux-low.c (struct iterate_over_lwps_args): Remove.
6116 (iterate_over_lwps_filter): Remove.
6117 (iterate_over_lwps): Use find_thread.
6119 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6121 * linux-low.c (reset_lwp_ptrace_options_callback): Remove.
6122 (linux_handle_new_gdb_connection): Use for_each_thread, inline
6123 code from reset_lwp_ptrace_options_callback.
6125 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6127 * linux-arm-low.c (struct update_registers_data): Remove.
6128 (update_registers_callback): Return void, take arguments
6129 directly, don't check thread's pid.
6130 (arm_insert_point, arm_remove_point): Use for_each_thread.
6132 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6134 * win32-low.c (continue_one_thread): Return void, take argument
6136 (child_continue): Use for_each_thread.
6138 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
6140 * win32-i386-low.c (update_debug_registers_callback): Rename
6142 (update_debug_registers): ... this, return void, remove pid_p arg.
6143 (x86_dr_low_set_addr, x86_dr_low_set_control): Use for_each_thread.
6145 2017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
6147 * inferiors.h (struct process_info): Add constructor, initialize
6149 <syscalls_to_catch>: Change type to std::vector<int>.
6150 * inferiors.c (add_process): Allocate process_info with new.
6151 (remove_process): Free process_info with delete.
6152 * linux-low.c (handle_extended_wait): Adjust.
6153 (gdb_catching_syscalls_p, gdb_catch_this_syscall_p): Adjust.
6154 * server.c (handle_general_set): Adjust.
6156 2017-11-16 Pedro Alves <palves@redhat.com>
6158 * remote-utils.c (remote_close): Block SIGIO signals instead of
6159 uninstalling the SIGIO handler.
6161 2017-11-16 Alan Hayward <alan.hayward@arm.com>
6163 * tdesc.c (tdesc_get_features_xml): Allow null osabi.
6165 2017-11-16 Yao Qi <yao.qi@linaro.org>
6167 * linux-tic6x-low.c (tic6x_fill_gregset): Cast buf.
6168 (tic6x_store_gregset): Likewise.
6169 (tic6x_usrregs_info): Move it up.
6171 2017-11-15 Alan Hayward <alan.hayward@arm.com>
6173 * Makefile.in: Update arch rules.
6174 * configure.srv: Explicitly mark arch/ files.
6176 2017-11-13 Andreas Schwab <schwab@suse.de>
6178 * linux-m68k-low.c (m68k_supports_hardware_single_step): New
6180 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
6182 2017-11-06 Pedro Alves <palves@redhat.com>
6184 * config.in, configure: Regenerate.
6186 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
6188 * target.c (struct thread_search): Remove.
6189 (thread_search_callback): Remove.
6190 (prepare_to_access_memory): Use for_each_thread instead of
6191 find_inferior. Inline code from thread_search_callback.
6193 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
6195 * server.c (struct visit_actioned_threads_data): Remove.
6196 (visit_actioned_threads): Change prototype to take arguments
6198 (resume): Use find_thread instead of find_inferior.
6200 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
6202 * server.c (queue_stop_reply_callback): Change prototype, return
6204 (find_status_pending_thread_callback): Remove.
6205 (handle_status): Replace find_inferior with find_thread and
6208 2017-10-25 Alan Hayward <alan.hayward@arm.com>
6210 * linux-aarch64-low.c (aarch64_fill_gregset): Replace defines
6212 (aarch64_store_gregset): Likewise.
6213 (aarch64_fill_fpregset): Likewise.
6214 (aarch64_store_fpregset): Likewise.
6216 2017-10-21 Simon Marchi <simon.marchi@ericsson.com>
6218 * gdbthread.h (find_thread, for_each_thread): New functions.
6219 * inferiors.c (thread_of_pid): Remove.
6220 (find_any_thread_of_pid): Use find_thread.
6221 * linux-low.c (num_lwps): Use for_each_thread.
6223 2017-10-17 Yao Qi <yao.qi@linaro.org>
6225 * Makefile.in: Remove one rule.
6226 * configure.srv: Rename aarch64-insn.o with arch/aarch64-insn.o.
6228 2017-10-17 Yao Qi <yao.qi@linaro.org>
6230 * configure.srv: Rename arm-linux.o with arch/arm-linux.o.
6231 Rename arm-get-next-pcs.o with arch/arm-get-next-pcs.o.
6233 2017-10-17 Yao Qi <yao.qi@linaro.org>
6235 * configure.srv: Rename arm.o with arch/arm.o.
6237 2017-10-17 Yao Qi <yao.qi@linaro.org>
6239 * Makefile.in (CONFIG_SRC_SUBDIR): New variable.
6240 (clean): Remove .o files in CONFIG_SRC_SUBDIR.
6241 (distclean): Remove DEPDIR in CONFIG_SRC_SUBDIR.
6242 (arch-i386.o, arch-amd64.o): Remove rules.
6243 (arch/%.o): New rule.
6244 Update POSTCOMPILE and COMPILE.pre.
6245 * configure.ac: Invoke AC_CONFIG_COMMANDS.
6246 * configure: Re-generated.
6247 * configure.srv: Replace arch-i386.o with arch/i386.o.
6248 Replace arch-amd64.o with arch/amd64.o.
6250 2017-10-16 Yao Qi <yao.qi@linaro.org>
6252 * configure: Regenerated.
6254 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
6256 * inferiors.h: (struct inferior_list): Remove.
6257 (struct inferior_list_entry); Remove.
6258 (add_inferior_to_list, clear_inferior_list, one_inferior_p,
6259 A_I_NEXT, ALL_INFERIORS_TYPE, ALL_INFERIORS, remove_inferior,
6260 get_first_inferior): Remove.
6261 (for_each_inferior, for_each_inferior_with_data, find_inferior,
6262 find_inferior_id, find_inferior_in_random): Change signature.
6263 * inferiors.c (all_threads): Change type to
6264 std::list<thread_info *>.
6265 (get_thread): Remove macro.
6266 (find_inferior, find_inferior_id): Change signature, implement
6268 (find_inferior_in_random): Change signature, implement using
6269 find_thread_in_random.
6270 (for_each_inferior, for_each_inferior_with_data): Change
6271 signature, implement using for_each_thread.
6272 (add_inferior_to_list, remove_inferior): Remove.
6273 (add_thread, get_first_thread, thread_of_pid,
6274 find_any_thread_of_pid, free_one_thread, remove_thread): Update.
6275 (get_first_inferior, one_inferior_p, clear_inferior_list):
6277 (clear_inferiors, get_thread_process): Update.
6278 * gdbthread.h: Include <list>.
6279 (struct thread_info) <entry>: Remove field.
6281 (all_threads): Change type to std::list<thread_info *>.
6282 (get_first_inferior): Add doc.
6283 (find_thread, for_each_thread, find_thread_in_random): New
6285 (current_ptid, pid_of, ptid_of, lwpid_of): Update.
6286 * linux-arm-low.c (update_registers_callback): Update.
6287 * linux-low.c (second_thread_of_pid_p): Update.
6288 (kill_one_lwp_callback, linux_detach_lwp_callback,
6289 delete_lwp_callback, status_pending_p_callback, same_lwp,
6290 find_lwp_pid, num_lwps, iterate_over_lwps_filter,
6291 iterate_over_lwps, not_stopped_callback,
6292 resume_stopped_resumed_lwps, count_events_callback,
6293 select_singlestep_lwp_callback, select_event_lwp_callback,
6294 unsuspend_one_lwp, linux_wait_1, send_sigstop_callback,
6295 suspend_and_send_sigstop_callback, wait_for_sigstop,
6296 stuck_in_jump_pad_callback, move_out_of_jump_pad_callback,
6297 lwp_running, linux_set_resume_request, resume_status_pending_p,
6298 need_step_over_p, start_step_over, linux_resume_one_thread,
6299 proceed_one_lwp, unsuspend_and_proceed_one_lwp,
6300 reset_lwp_ptrace_options_callback): Update.
6301 * linux-mips-low.c (update_watch_registers_callback): Update.
6302 * regcache.c (regcache_invalidate_one, regcache_invalidate):
6304 (free_register_cache_thread_one): Remove.
6305 (regcache_release): Update.
6306 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt,
6307 handle_qxfer_threads_worker): Update.
6308 (handle_query): Update, use list iterator.
6309 (visit_actioned_threads, handle_pending_status,
6310 queue_stop_reply_callback, gdb_wants_all_threads_stopped,
6311 clear_pending_status_callback, set_pending_status_callback,
6312 find_status_pending_thread_callback, handle_status,
6313 process_serial_event): Update.
6314 * target.c (thread_search_callback): Update.
6315 * thread-db.c (thread_db_get_tls_address): Update.
6316 * tracepoint.c (tracepoint_finished_step, tracepoint_was_hit):
6318 * win32-i386-low.c (update_debug_registers_callback): Update.
6319 * win32-low.c (delete_thread_info, child_delete_thread,
6320 continue_one_thread, suspend_one_thread,
6321 get_child_debug_event): Adjust.
6323 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
6325 * gdbthread.h (ptid_of, pid_of, lwpid_of): New functions.
6326 * inferiors.h: Include <list>.
6327 (struct process_info) <entry>: Remove field.
6329 (pid_of): Change macro to function.
6330 (ptid_of, lwpid_of): Remove macro.
6331 (all_processes): Change type to std::list<process_info *>.
6332 (ALL_PROCESSES): Remove macro.
6333 (for_each_process, find_process): New function.
6334 * inferiors.c (all_processes): Change type to
6335 std::list<process_info *>.
6336 (find_thread_process): Adjust.
6337 (add_process): Likewise.
6338 (remove_process): Likewise.
6339 (find_process_pid): Likewise.
6340 (get_first_process): Likewise.
6341 (started_inferior_callback): Remove.
6342 (have_started_inferiors_p): Adjust.
6343 (attached_inferior_callback): Remove.
6344 (have_attached_inferiors_p): Adjust.
6345 * linux-low.c (check_zombie_leaders): Likewise.
6346 * linux-x86-low.c (x86_arch_setup_process_callback): Remove.
6347 (x86_linux_update_xmltarget): Adjust.
6348 * server.c (handle_query): Likewise.
6349 (gdb_reattached_process): Remove.
6350 (handle_status): Adjust.
6351 (kill_inferior_callback): Likewise.
6352 (detach_or_kill_inferior): Remove.
6353 (print_started_pid): Likewise.
6354 (print_attached_pid): Likewise.
6355 (detach_or_kill_for_exit): Update.
6356 (process_serial_event): Likewise.
6357 * linux-arm-low.c (arm_new_fork): Likewise.
6359 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
6361 * dll.h: Include <list>.
6362 (struct dll_info): Add constructor.
6363 <entry>: Remove field.
6364 (all_dlls): Change type to std::list<dll_info>.
6365 * dll.c: Include <algorithm>.
6366 (get_dll): Remove macro.
6367 (all_dlls): Change type to std::list<dll_info *>.
6368 (free_one_dll): Remove.
6369 (match_dll): Likewise.
6370 (loaded_dll): Adjust.
6371 (unloaded_dll): Adjust to all_dlls type change, use
6372 std::find_if. Inline code from match_dll.
6373 (clear_dlls): Adjust to all_dlls type change.
6374 * server.c (emit_dll_description): Remove.
6375 (handle_qxfer_libraries): Adjust to all_dlls type change,
6376 integrate emit_dll_description's functionality.
6378 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
6380 * linux-low.h (struct linux_target_ops) <delete_process>: New
6382 * linux-low.c (linux_mourn): Call the_low_target.delete_process.
6383 * linux-aarch64-low.c (aarch64_linux_delete_process): New.
6384 (struct linux_target_ops): Add delete_process callback.
6385 * linux-arm-low.c (arm_delete_process): New.
6386 (struct linux_target_ops): Add delete_process callback.
6387 * linux-bfin-low.c (struct linux_target_ops): Likewise.
6388 * linux-crisv32-low.c (struct linux_target_ops): Likewise.
6389 * linux-m32r-low.c (struct linux_target_ops): Likewise.
6390 * linux-mips-low.c (mips_linux_delete_process): New.
6391 (struct linux_target_ops): Add delete_process callback.
6392 * linux-ppc-low.c (struct linux_target_ops): Likewise.
6393 * linux-s390-low.c (struct linux_target_ops): Likewise.
6394 * linux-sh-low.c (struct linux_target_ops): Likewise.
6395 * linux-tic6x-low.c (struct linux_target_ops): Likewise.
6396 * linux-tile-low.c (struct linux_target_ops): Likewise.
6397 * linux-x86-low.c (x86_linux_delete_process): New.
6398 (struct linux_target_ops): Add delete_process callback.
6399 * linux-xtensa-low.c (struct linux_target_ops): Likewise.
6401 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
6403 * linux-aarch64-low.c (the_low_target): Add thread delete
6405 * linux-arm-low.c (arm_delete_thread): New function.
6406 (the_low_target): Add thread delete callback.
6407 * linux-bfin-low.c (the_low_target): Likewise.
6408 * linux-crisv32-low.c (the_low_target): Likewise.
6409 * linux-low.c (delete_lwp): Invoke delete_thread callback if
6411 * linux-low.h (struct linux_target_ops) <delete_thread>: New
6413 * linux-m32r-low.c (the_low_target): Add thread delete callback.
6414 * linux-mips-low.c (mips_linux_delete_thread): New function.
6415 (the_low_target): Add thread delete callback.
6416 * linux-ppc-low.c (the_low_target): Likewise.
6417 * linux-s390-low.c (the_low_target): Likewise.
6418 * linux-sh-low.c (the_low_target): Likewise.
6419 * linux-tic6x-low.c (the_low_target): Likewise.
6420 * linux-tile-low.c (the_low_target): Likewise.
6421 * linux-x86-low.c (the_low_target): Likewise.
6422 * linux-xtensa-low.c (the_low_target): Likewise.
6424 2017-10-06 Yuanhui Zhang <asmwarrior@gmail.com>
6426 * win32-low.c: Include "common-inferior.h".
6428 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
6430 * inferiors.c (set_inferior_cwd): New function.
6431 * server.c (handle_general_set): Handle QSetWorkingDir packet.
6432 (handle_query): Inform that QSetWorkingDir is supported.
6433 * win32-low.c (create_process): Pass the inferior's cwd to
6436 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
6438 * inferiors.c (current_inferior_cwd): New global variable.
6439 (get_inferior_cwd): New function.
6440 * inferiors.h (struct process_info) <cwd>: New field.
6442 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
6444 * Makefile.in (SFILES): Add $(srcdir)/common/gdb_tilde_expand.c.
6445 (OBS): Add gdb_tilde_expand.o.
6447 2017-10-02 Simon Marchi <simon.marchi@ericsson.com>
6449 * lynx-i386-low.c (lynx_i386_arch_setup): Call init_target_desc.
6450 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
6452 2017-09-29 Pedro Alves <palves@redhat.com>
6454 * ax.c (gdb_parse_agent_expr): Constify.
6455 * ax.h (gdb_parse_agent_expr): Constify.
6456 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
6458 * mem-break.h (add_breakpoint_condition, add_breakpoint_commands): Constify.
6459 * remote-utils.c (hex_or_minus_one, read_ptid): Constify.
6460 * remote-utils.h (read_ptid): Constify.
6461 * server.c (handle_qxfer_exec_file, handle_query, handle_v_cont)
6462 (process_point_options, process_serial_event): Constify.
6463 * tracepoint.c (add_tracepoint_action, cmd_qtdp, cmd_qtdpsrc)
6464 (cmd_qtdv, cmd_qtenable_disable, cmd_qtro, cmd_qtframe, cmd_qtp)
6465 (cmd_qtbuffer): Constify.
6467 2017-09-29 Pedro Alves <palves@redhat.com>
6469 * proc-service.c (ps_pdread): Return PS_ERR if reading memory
6472 2017-09-29 Pedro Alves <palves@redhat.com>
6474 * linux-low.c (handle_extended_wait): Pass parent thread instead
6475 of process to thread_db_notice_clone.
6476 * linux-low.h (thread_db_notice_clone): Replace parent process
6477 parameter with parent thread parameter.
6478 * thread-db.c (find_one_thread): Add comment.
6479 (thread_db_notice_clone): Replace parent process parameter with
6480 parent thread parameter. Temporarily switch to the parent thread.
6482 2017-09-26 Sergio Durigan Junior <sergiodj@redhat.com>
6484 * gdbthread.h: Include "common-gdbthread.h".
6485 * inferiors.c (switch_to_thread): Use "gdb_assert" instead of
6486 "if" when validating the ptid.
6487 * remote-utils.c: Include "gdbthread.h".
6488 (prepare_resume_reply): Use "switch_to_thread".
6489 * target.c (done_accessing_memory): Likewise.
6491 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
6493 * configure.srv (s390*-*-linux*): Add s390-gs-linux64.o and
6494 s390x-gs-linux64.o to srv_regobj. Add s390-gs-linux64.xml,
6495 s390x-gs-linux64.xml, s390-gs.xml, and s390-gsbc.xml to
6496 srv_xmlfiles. Add s390-gs-linux64-ipa.o and
6497 s390x-gs-linux64-ipa.o to ipa_obj.
6498 * linux-s390-low.c (HWCAP_S390_GS): New define.
6499 (s390_fill_gs, s390_store_gs, s390_fill_gsbc, s390_store_gsbc):
6501 (s390_regsets): Add regsets for NT_S390_GS_CB and NT_S390_GS_BC.
6502 (s390_arch_setup): Check for guarded-storage support and choose
6504 (initialize_low_arch): Invoke init_registers_s390_gs_linux64 and
6505 init_registers_s390x_gs_linux64.
6506 * linux-s390-tdesc.h (enum s390_linux_tdesc) <S390_TDESC_GS>: New
6508 (init_registers_s390x_gs_linux64, tdesc_s390x_gs_linux64)
6509 (init_registers_s390_gs_linux64, tdesc_s390_gs_linux64): Declare.
6511 2017-09-22 Simon Marchi <simon.marchi@ericsson.com>
6513 * win32-i386-low.c (i386_arch_setup): Call init_target_desc.
6515 2017-09-21 Kevin Buettner <kevinb@redhat.com>
6517 * linux-low.h (struct lwp_info): Add new field, thread_handle.
6518 (thread_db_thread_handle): Declare.
6519 * linux-low.c (linux_target_ops): Initialize thread_handle.
6520 * server.c (handle_qxfer_threads_worker): Add support for
6522 * target.h (struct target_ops): Add new function pointer,
6524 (target_thread_handle): Define.
6525 * thread-db.c (find_one_thread, attach_thread): Set thread_handle
6527 (thread_db_thread_handle): New function.
6529 2017-09-21 Kevin Buettner <kevinb@redhat.com>
6531 * linux-low.c (handle_extended_wait): Call thread_db_notice_clone().
6532 * linux-low.h (thread_db_notice_clone): Declare.
6533 * thread-db.c (thread_db_notice_clone): New function.
6535 2017-09-21 Pedro Alves <palves@redhat.com>
6537 * server.c (gdb_read_memory, handle_status, process_serial_event)
6538 (handle_serial_event, handle_target_event): Adjust to
6539 set_desired_thread prototype change.
6540 * target.c (set_desired_thread): Remove 'use_general' parameter
6542 * target.h (set_desired_thread): Remove 'use_general' parameter.
6544 2017-09-20 Tom Tromey <tom@tromey.com>
6546 * target.c (target_terminal::terminal_state): Define.
6547 (target_terminal::init): Rename from target_terminal_init.
6548 (target_terminal::inferior): Rename from
6549 target_terminal_inferior.
6550 (target_terminal::ours): Rename from target_terminal_ours.
6551 (target_terminal::ours_for_output, target_terminal::info): New.
6553 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6555 * server.c (accumulate_file_name_length): Remove.
6556 (emit_dll_description): Adjust to std::string change.
6557 (handle_qxfer_libraries): Use std::string to hold document.
6559 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6561 * linux-low.c (linux_qxfer_libraries_svr4): Adjust to change of
6562 return type of xml_escape_text.
6563 * server.c (emit_dll_description): Likewise.
6565 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6567 * server.c (captured_main): Accept argument for --selftest.
6568 Update run_tests call.
6569 * linux-x86-tdesc-selftest.c (initialize_low_tdesc): Add names
6570 when registering selftests.
6572 2017-09-16 Sergio Durigan Junior <sergiodj@redhat.com>
6574 * regcache.c (get_thread_regcache): Update code to use "std::vector"
6575 instead of "VEC" for "target_desc.reg_defs".
6576 (regcache_cpy): Likewise.
6577 (registers_to_string): Likewise.
6578 (registers_from_string): Likewise.
6579 (find_regno): Likewise.
6580 (supply_regblock): Likewise.
6581 (regcache_raw_read_unsigned): Likewise.
6582 * tdesc.c (init_target_desc): Likewise.
6583 (tdesc_create_reg): Likewise.
6584 * tdesc.h: Remove declaration of "tdesc_reg_p". Include <vector>.
6585 (struct target_desc) <reg_defs>: Convert to "std::vector".
6586 (target_desc): Do not initialize "reg_defs".
6587 (~target_desc): Update code to use "std::vector" instead of "VEC"
6588 for "target_desc.reg_defs".
6589 (operator==): Likewise.
6591 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6593 * inferiors.h (thread_to_gdb_id): Remove.
6594 * inferiors.c (thread_to_gdb_id): Remove.
6595 * server.c (handle_qxfer_threads_worker, handle_query): Adjust.
6596 * lynx-low.c (lynx_resume, lynx_wait_1, lynx_fetch_registers,
6597 lynx_store_registers, lynx_read_memory, lynx_write_memory):
6599 * nto-low.c (nto_fetch_registers, nto_store_registers,
6600 nto_stopped_by_watchpoint, nto_stopped_data_address): Likewise.
6602 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6604 * inferiors.h (gdb_id_to_thread_id): Remove.
6605 * inferiors.c (gdb_id_to_thread_id): Remove.
6606 * server.c (process_serial_event): Adjust to gdb_id_to_thread_id
6607 removal. Move pid declaration closer to where it's used.
6609 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6611 * server.c (handle_detach): New function.
6612 (process_serial_event): Move code out, call handle_detach.
6614 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6616 * server.c (require_running): Rename to ...
6617 (require_running_or_return): ... this ...
6618 (require_running_or_break): ... and this.
6619 (handle_query, process_serial_event): Adjust.
6621 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6623 * linux-low.c (linux_set_resume_request): Remove unused
6626 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6628 * server.c (first_thread_of): Remove.
6629 (process_serial_event): Replace usage of first_thread_of with
6630 find_any_thread_of_pid.
6631 * tracepoint.c (same_process_p): Remove.
6632 (gdb_agent_about_to_close): Replace usage of same_process_p with
6633 find_any_thread_of_pid.
6634 * linux-x86-low.c (same_process_callback): Remove.
6635 (x86_arch_setup_process_callback): Replace usage of
6636 same_process_callback with find_any_thread_of_pid.
6637 * thread-db.c (any_thread_of): Remove.
6638 (switch_to_process): Replace usage of any_thread_of with
6639 find_any_thread_of_pid.
6640 * inferiors.c (thread_pid_matches_callback): Remove.
6641 (find_thread_process): Adjust to use find_any_thread_of_pid.
6643 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
6645 * regcache.c (get_thread_regcache): Guard calls to "memset"
6648 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
6650 * linux-low.c (handle_extended_wait): Use
6651 "allocate_target_description" instead of "XNEW".
6652 * linux-x86-low.c (initialize_low_arch): Likewise.
6654 2017-09-05 Yao Qi <yao.qi@linaro.org>
6656 * configure.srv (srv_i386_regobj): Remove.
6657 (srv_amd64_regobj): Remove.
6658 (srv_regobj): Set it to "" for x86 non-linux targets.
6659 * linux-x86-tdesc.c (i386_linux_read_description):
6660 * lynx-i386-low.c: Include x86-xstate.h and arch/i386.h.
6661 (init_registers_i386): Remove the declaration.
6662 (tdesc_i386): Remove the declaration.
6663 (lynx_i386_arch_setup): Call i386_create_target_description.
6664 * nto-x86-low.c: Likewise.
6665 * win32-i386-low.c [__x86_64__]: include arch/amd64.h.
6666 [!__x86_64__]: include arch/i386.h.
6667 (i386_arch_setup) [__x86_64__]: Call amd64_create_target_description.
6669 2017-09-05 Yao Qi <yao.qi@linaro.org>
6671 * configure.srv (srv_amd64_linux_xmlfiles): Remove
6672 i386/amd64-XXX-linux from it.
6674 2017-09-05 Yao Qi <yao.qi@linaro.org>
6676 * configure.srv: Empty srv_amd64_linux_regobj if $development is
6678 (ipa_amd64_linux_regobj): Remove.
6679 (ipa_x32_linux_regobj): Remove.
6681 2017-09-05 Yao Qi <yao.qi@linaro.org>
6683 * Makefile.in (arch-amd64.o): New rule.
6684 * configure.srv: Append arch-amd64.o.
6685 * linux-amd64-ipa.c: Include common/x86-xstate.h.
6686 (get_ipa_tdesc): Call amd64_linux_read_description.
6687 (initialize_low_tracepoint): Don't call init_registers_x32_XXX
6688 and init_registers_amd64_XXX.
6689 * linux-x86-low.c (x86_linux_read_description): Call
6690 amd64_linux_read_description.
6691 (x86_get_ipa_tdesc_idx): Call amd64_get_ipa_tdesc_idx.
6692 (initialize_low_arch): Don't call init_registers_x32_XXX and
6693 init_registers_amd64_XXX.
6694 * linux-x86-tdesc-selftest.c: Declare init_registers_amd64_XXX
6695 and tdesc_amd64_XXX.
6696 [__x86_64__] (amd64_tdesc_test): New function.
6697 (initialize_low_tdesc) [__x86_64__]: Call init_registers_x32_XXX
6698 and init_registers_amd64_XXX.
6699 * linux-x86-tdesc.c: Include arch/amd64.h.
6700 (xcr0_to_tdesc_idx): New function.
6701 (i386_linux_read_description): New function.
6702 (amd64_get_ipa_tdesc_idx): New function.
6703 * linux-x86-tdesc.h (amd64_get_ipa_tdesc_idx): Declare.
6704 (amd64_get_ipa_tdesc): Declare.
6706 2017-09-05 Yao Qi <yao.qi@linaro.org>
6708 * configure.srv (srv_i386_linux_xmlfiles): Remove
6709 i386/i386-XXX-linux.xml from it.
6711 2017-09-05 Yao Qi <yao.qi@linaro.org>
6713 * configure.srv: Set srv_i386_linux_regobj empty if $development
6715 * linux-i386-ipa.c (initialize_low_tracepoint): Don't call
6716 initialize_low_tdesc.
6717 * linux-x86-low.c (initialize_low_arch): Wrap initialize_low_tdesc
6718 with #if initialize_low_tdesc.
6719 * linux-x86-tdesc-selftest.c: New file.
6720 * linux-x86-tdesc.c: Move code to linux-x86-tdesc-selftest.c.
6722 2017-09-05 Yao Qi <yao.qi@linaro.org>
6724 * Makefile.in (arch-i386.o): New rule.
6725 * configure.srv (i[34567]86-*-linux*): Add arch-i386.o.
6726 (x86_64-*-linux*): Likewise.
6727 * linux-x86-tdesc.c: Don't include ../features/i386/32bit-XXX.c,
6728 include arch/i386.h.
6729 (i386_linux_read_description): Remove code and call
6730 i386_create_target_description.
6731 * tdesc.c (allocate_target_description): New function.
6732 * tdesc.h (set_tdesc_architecture): Remove declaration.
6733 (set_tdesc_osabi): Likewise.
6735 2017-09-05 Yao Qi <yao.qi@linaro.org>
6737 * linux-x86-tdesc.c: Don't include <inttypes.h>.
6738 (i386_linux_read_description) [!IN_PROCESS_AGENT]: Call
6739 set_tdesc_architecture and set_tdesc_osabi. Remove code setting
6741 * server.c (get_features_xml): Call tdesc_get_features_xml.
6742 * tdesc.c (set_tdesc_architecture): New function.
6743 (set_tdesc_osabi): New function.
6744 (tdesc_get_features_xml): New function.
6745 (tdesc_create_feature): Add an argument.
6746 * tdesc.h (struct target_desc) <features>: New field.
6747 <arch, osabi>: New field.
6748 (~target_desc): xfree features, arch, and osabi.
6749 (target_desc::oerator==): Don't compare .xmltarget.
6750 [!IN_PROCESS_AGENT] (set_tdesc_architecture): Declare.
6751 (set_tdesc_osabi): Likewise.
6752 (tdesc_get_features_xml): Likewise.
6754 2017-09-05 Yao Qi <yao.qi@linaro.org>
6756 * linux-x86-tdesc.c: Include selftest.h.
6757 (i386_tdesc_test): New function.
6758 (initialize_low_tdesc): Call selftests::register_test.
6759 * tdesc.h: Include regdef.h.
6760 (target_desc): Override operator == and !=.
6762 2017-09-05 Yao Qi <yao.qi@linaro.org>
6764 * configure.srv (srv_tgtobj): Append linux-x86-tdesc.o.
6765 (ipa_obj): Likewise.
6766 * linux-i386-ipa.c: Include common/x86-xstate.h
6767 (get_ipa_tdesc): Call i386_linux_read_description.
6768 (initialize_low_tracepoint): Don't call init_registers_XXX
6769 functions, call initialize_low_tdesc instead.
6770 * linux-x86-low.c (x86_linux_read_description): Call
6771 i386_linux_read_description.
6772 (initialize_low_arch): Don't call init_registers_i386_XXX
6773 functions, call initialize_low_tdesc.
6774 * linux-x86-tdesc.c: New file.
6775 * linux-x86-tdesc.h (x86_linux_tdesc): New X86_TDESC_LAST.
6776 (i386_get_ipa_tdesc_idx): Declare.
6777 (i386_get_ipa_tdesc): Declare.
6778 (initialize_low_tdesc): Declare.
6780 2017-09-05 Yao Qi <yao.qi@linaro.org>
6782 * linux-x86-low.c (x86_get_ipa_tdesc_idx): Use X86_TDESC_MMX
6785 2017-09-05 Yao Qi <yao.qi@linaro.org>
6787 * Makefile.in (IPA_OBJS): Add vec-ipa.o
6788 * regcache.c (get_thread_regcache): Use VEC_length.
6789 (init_register_cache): Likewise.
6790 (regcache_cpy): Likewise.
6791 (registers_to_string): Iterate reg_defs via VEC_iterate.
6792 (find_regno): Likewise.
6793 (find_register_by_number): Use VEC_index.
6794 (register_size): Call find_register_by_number.
6795 (register_data): Call find_register_by_number.
6796 (supply_regblock): Use VEC_length.
6797 (regcache_raw_read_unsigned): Likewise.
6798 * tdesc.c (init_target_desc): Iterate reg_defs via
6800 (default_description): Update initializer.
6801 (copy_target_description): Don't update field num_registers.
6802 * tdesc.h (struct target_desc) <reg_defs>: Change it to VEC.
6803 <num_registers>: Remove.
6805 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
6807 * Makefile.in (.SECONDARY): Define target.
6809 2017-09-03 Simon Marchi <simon.marchi@ericsson.com>
6811 * linux-low.c (linux_wait_1): Adjust.
6812 * server.c (queue_stop_reply_callback): Adjust.
6814 2017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
6816 * server.c (handle_general_set): Handle QEnvironmentHexEncoded,
6817 QEnvironmentUnset and QEnvironmentReset packets.
6818 (handle_query): Inform remote that QEnvironmentHexEncoded,
6819 QEnvironmentUnset and QEnvironmentReset are supported.
6821 2017-08-25 Simon Marchi <simon.marchi@ericsson.com>
6823 * inferiors.h (inferior_target_data): Rename to ...
6824 (thread_target_data): ... this.
6825 (inferior_regcache_data): Rename to ...
6826 (thread_regcache_data): ... this.
6827 (set_inferior_regcache_data): Rename to ...
6828 (set_thread_regcache_data): ... this.
6829 * inferiors.c (inferior_target_data): Rename to ...
6830 (thread_target_data): ... this.
6831 (inferior_regcache_data): Rename to ...
6832 (thread_regcache_data): ... this.
6833 (set_inferior_regcache_data): Rename to ...
6834 (set_thread_regcache_data): ... this.
6835 (free_one_thread): Update.
6836 * linux-low.h (get_thread_lwp): Update.
6837 * regcache.c (get_thread_regcache): Update.
6838 (regcache_invalidate_thread): Update.
6839 (free_register_cache_thread): Update.
6840 * win32-i386-low.c (update_debug_registers_callback): Update.
6841 (win32_get_current_dr): Update.
6842 * win32-low.c (thread_rec): Update.
6843 (delete_thread_info): Update.
6844 (continue_one_thread): Update.
6845 (suspend_one_thread): Update.
6847 2017-08-24 Simon Marchi <simon.marchi@ericsson.com>
6849 * inferiors.c (set_inferior_target_data): Remove.
6850 * inferiors.h (set_inferior_target_data): Remove.
6852 2017-08-18 Yao Qi <yao.qi@linaro.org>
6854 * Makefile.in (OBS): Add selftest.o.
6855 * configure.ac: AC_DEFINE GDB_SELF_TEST if $development.
6856 * configure, config.in: Re-generated.
6857 * server.c: Include common/sefltest.h.
6858 (captured_main): Handle option --selftest.
6860 2017-08-09 Yao Qi <yao.qi@linaro.org>
6862 * configure.srv (srv_i386_regobj): Remove i386-avx.o,
6863 i386-avx-avx512.o, i386-avx-mpx-avx512-pku.o, i386-mpx.o,
6864 i386-avx-mpx.o and i386-mmx.o.
6865 (srv_amd64_regobj): Remove amd64-avx.o, amd64-avx-avx512.o,
6866 amd64-avx-mpx-avx512-pku.o, amd64-mpx.o and amd64-avx-mpx.o.
6867 (srv_i386_xmlfiles): Remove i386/i386-avx.xml,
6868 i386/i386-avx-avx512.xml, i386/i386-avx-mpx-avx512-pku.xml,
6869 i386/i386-mpx.xml, i386/i386-avx-mpx.xml and i386/i386-mmx.xml.
6870 (srv_amd64_xmlfile):i386/amd64-avx.xml, i386/amd64-avx-avx512.xml,
6871 i386/amd64-avx-mpx-avx512-pku.xml, i386/amd64-mpx.xml,
6872 i386/amd64-avx-mpx.xml.
6874 2017-08-09 Yao Qi <yao.qi@linaro.org>
6876 * configure.srv (srv_amd64_regobj): Remove x32.o, x32-avx.o
6877 and x32-avx-avx512.o.
6878 (srv_amd64_xmlfiles): Remove i386/x32.xml, i386/x32-avx.xml
6879 i386/x32-avx-avx512.xml.
6881 2017-07-26 Simon Marchi <simon.marchi@ericsson.com>
6883 * tracepoint.h (enum class fast_tpoint_collect_result): New
6885 (fast_tracepoint_collecting): Change return type to
6886 fast_tpoint_collect_result.
6887 * tracepoint.c (fast_tracepoint_collecting): Likewise.
6888 * linux-low.h: Include tracepoint.h.
6889 (struct lwp_info) <collecting_fast_tracepoint>: Change type to
6890 fast_tpoint_collect_result.
6891 * linux-low.c (handle_tracepoints): Adjust.
6892 (linux_fast_tracepoint_collecting): Change return type to
6893 fast_tpoint_collect_result.
6894 (maybe_move_out_of_jump_pad, linux_wait_for_event_filtered,
6895 linux_wait_1, stuck_in_jump_pad_callback,
6896 lwp_signal_can_be_delivered, linux_resume_one_lwp_throw,
6897 proceed_one_lwp): Adjust to type change.
6899 2017-07-10 Yao Qi <yao.qi@linaro.org>
6901 * linux-x86-low.c (x86_linux_read_description): Re-indent the code.
6903 2017-06-29 Yao Qi <yao.qi@linaro.org>
6905 * tdesc.h (struct target_desc) [IN_PROCESS_AGENT] <expedite_regs>:
6907 [IN_PROCESS_AGENT] <xmltarget>: Likewise.
6909 2017-06-20 Simon Marchi <simon.marchi@ericsson.com>
6911 * Makefile.in (IPA_OBJS): Sort and format one item per line.
6913 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
6915 * linux-low.c (linux_create_inferior): Adjust code to access the
6916 environment information via 'gdb_environ' class.
6917 * lynx-low.c (lynx_create_inferior): Likewise.
6918 * server.c (our_environ): Make it an instance of 'gdb_environ'.
6919 (get_environ): Return a pointer to 'our_environ'.
6920 (captured_main): Initialize 'our_environ'.
6921 * server.h (get_environ): Adjust prototype.
6922 * spu-low.c (spu_create_inferior): Adjust code to access the
6923 environment information via 'gdb_environ' class.
6925 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
6927 * linux-low.c (linux_read_memory, linux_write_memory): Remove
6928 usage of "register" keyword.
6930 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
6932 * configure: Re-generate.
6934 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
6936 * configure: Re-generate.
6938 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
6940 * Makefile.in (COMPILE.pre): Add "-x c++".
6942 2017-06-09 Sergio Durigan Junior <sergiodj@redhat.com>
6944 * fork-child.c: Conditionally include <signal.h>.
6946 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
6948 * server.c (handle_general_set): Handle new packet
6949 "QStartupWithShell".
6950 (handle_query): Add "QStartupWithShell" to the list of supported
6952 (gdbserver_usage): Add help text explaining the
6953 new "--startup-with-shell" and "--no-startup-with-shell" CLI
6955 (captured_main): Recognize and act upon the presence of the new
6958 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
6959 Pedro Alves <palves@redhat.com>
6961 * Makefile.in (SFILES): Add "nat/fork-inferior.o".
6962 * configure: Regenerate.
6963 * configure.srv (srv_linux_obj): Add "fork-child.o" and
6965 (i[34567]86-*-lynxos*): Likewise.
6966 (spu*-*-*): Likewise.
6967 * fork-child.c: New file.
6968 * linux-low.c: Include "common-inferior.h", "nat/fork-inferior.h"
6970 (linux_ptrace_fun): New function.
6971 (linux_create_inferior): Adjust function prototype to reflect
6972 change on "target.h". Adjust function code to use
6974 (linux_request_interrupt): Delete "signal_pid".
6975 * lynx-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
6976 (lynx_ptrace_fun): New function.
6977 (lynx_create_inferior): Adjust function prototype to reflect
6978 change on "target.h". Adjust function code to use
6980 * nto-low.c (nto_create_inferior): Adjust function prototype and
6981 code to reflect change on "target.h". Update comments.
6982 * server.c: Include "common-inferior.h", "nat/fork-inferior.h",
6983 "common-terminal.h" and "environ.h".
6984 (terminal_fd): Moved to fork-child.c.
6985 (old_foreground_pgrp): Likewise.
6986 (restore_old_foreground_pgrp): Likewise.
6987 (last_status): Make it global.
6988 (last_ptid): Likewise.
6989 (our_environ): New variable.
6990 (startup_with_shell): Likewise.
6991 (program_name): Likewise.
6992 (program_argv): Rename to...
6993 (program_args): ...this.
6994 (wrapper_argv): New variable.
6995 (start_inferior): Delete function.
6996 (get_exec_wrapper): New function.
6997 (get_exec_file): Likewise.
6998 (get_environ): Likewise.
6999 (prefork_hook): Likewise.
7000 (post_fork_inferior): Likewise.
7001 (postfork_hook): Likewise.
7002 (postfork_child_hook): Likewise.
7003 (handle_v_run): Update code to deal with arguments coming from the
7004 remote host. Update calls from "start_inferior" to
7006 (captured_main): Likewise. Initialize environment variable. Call
7008 * server.h (post_fork_inferior): New prototype.
7009 (get_environ): Likewise.
7010 (last_status): Declare.
7011 (last_ptid): Likewise.
7012 (signal_pid): Likewise.
7013 * spu-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
7014 (spu_ptrace_fun): New function.
7015 (spu_create_inferior): Adjust function prototype to reflect change
7016 on "target.h". Adjust function code to use "fork_inferior".
7017 * target.c (target_terminal_init): New function.
7018 (target_terminal_inferior): Likewise.
7019 (target_terminal_ours): Likewise.
7020 * target.h: Include <vector>.
7021 (struct target_ops) <create_inferior>: Update prototype.
7022 (create_inferior): Update macro.
7023 * utils.c (gdb_flush_out_err): New function.
7024 * win32-low.c (win32_create_inferior): Adjust function prototype
7025 and code to reflect change on "target.h".
7027 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
7029 * inferiors.c (switch_to_thread): New function.
7031 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
7033 * Makefile.in (SFILE): Add "common/job-control.c".
7034 (OBS): Add "job-control.o".
7036 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
7038 * Makefile: Remove "@host_makefile_frag@".
7040 2017-05-05 Pedro Alves <palves@redhat.com>
7042 * configure: Regenerate.
7044 2017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
7046 * configure: Regenerate.
7048 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
7050 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Adjust to
7051 software_single_step change of return type to
7052 std::vector<CORE_ADDR>.
7053 * linux-low.c (install_software_single_step_breakpoints):
7055 * linux-low.h (install_software_single_step_breakpoints):
7058 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
7060 * remote-utils.c: Include "gdb_termios.h" instead of
7062 * terminal.h: Delete file.
7064 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
7066 * server.c: Include <vector>.
7067 <program_argv, wrapper_argv>: Convert to std::vector.
7068 (start_inferior): Rewrite function to use C++.
7069 (handle_v_run): Likewise. Update code that calculates the argv
7070 based on the vRun packet; use C++.
7071 (captured_main): Likewise.
7073 2017-04-06 Simon Marchi <simon.marchi@ericsson.com>
7075 * server.c (handle_v_cont): Initialize thread_resume::thread
7078 2017-04-05 Pedro Alves <palves@redhat.com>
7080 * configure: Regenerate.
7082 2017-04-05 Pedro Alves <palves@redhat.com>
7084 * gdbreplay.c (sync_error): Constify.
7085 * linux-x86-low.c (push_opcode): Constify.
7087 2017-04-05 Pedro Alves <palves@redhat.com>
7089 * win32-low.c (get_child_debug_event)
7090 <CREATE_PROCESS_DEBUG_EVENT>: Don't report TARGET_WAITKIND_EXECD.
7091 Report TARGET_WAITKIND_SPURIOUS instead.
7093 2017-04-05 Pedro Alves <palves@redhat.com>
7095 * remote-utils.c (remote_prepare, remote_open): Constify.
7096 * remote-utils.h (remote_prepare, remote_open): Constify.
7097 * server.c (captured_main): Constify 'port' handling.
7099 2017-04-04 Simon Marchi <simon.marchi@ericsson.com>
7101 * Makefile.in (clean): Clear .deps.
7103 2017-03-31 Simon Marchi <simon.marchi@polymtl.ca>
7105 * .gitignore: Remove generated files, replace with wildcard.
7106 * (clean): Replace removal of generated files with wildcard.
7107 (version.c): Replace with...
7108 (version-generated.c): ...this.
7109 (xml-builtin.c): Replace with...
7110 (xml-builtin-generated.c): ...this.
7111 (%-ipa.o: %-generated.c, %.o: %-generated.c): New rules.
7112 (%.c: *regformats*): Replace with...
7113 (%-generated.c: *regformats*): ...this.
7115 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
7117 * linux-xtensa-low.c (regnum::R_THREADPTR): New enum member.
7118 (xtensa_fill_gregset): Call collect_register_by_name for
7120 (xtensa_store_gregset): Call supply_register_by_name for
7123 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
7125 * linux-xtensa-low.c (xtensa_fill_gregset): Call collect_register
7126 for all registers in a0_regnum..a0_regnum + C0_NREGS range.
7127 (xtensa_store_gregset): Call supply_register for all registers in
7128 a0_regnum..a0_regnum + C0_NREGS range.
7130 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7132 * Makefile.in (%-ipa.o: %-ipa.c): New rule.
7133 (ax-ipa.o: ax.c): Remove.
7134 (linux-i386-ipa.o: linux-i386-ipa.c): Remove.
7135 (linux-amd64-ipa.o: linux-amd64-ipa.c): Remove.
7136 (linux-aarch64-ipa.o: linux-aarch64-ipa.c): Remove.
7137 (linux-s390-ipa.o: linux-s390-ipa.c): Remove.
7138 (linux-ppc-ipa.o: linux-ppc-ipa.c): Remove.
7140 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7142 * Makefile.in (%-ipa.o: ../common/%.c): New rule.
7143 (print-utils-ipa.o: ../common/print-utils.c): Remove.
7144 (rsp-low-ipa.o: ../common/rsp-low.c): Remove.
7145 (errors-ipa.o: ../common/errors.c): Remove.
7146 (format-ipa.o: ../common/format.c): Remove.
7147 (common-utils-ipa.o: ../common/common-utils.c): Remove.
7149 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7151 * Makefile.in (%-ipa.o: %.c): New rule.
7152 (tracepoint-ipa.o: tracepoint.c): Remove.
7153 (utils-ipa.o: utils.c): Remove.
7154 (remote-utils-ipa.o: remote-utils.c): Remove.
7155 (regcache-ipa.o: regcache.c): Remove.
7156 (i386-linux-ipa.o: i386-linux.c): Remove.
7157 (i386-mmx-linux-ipa.o: i386-mmx-linux.c): Remove.
7158 (i386-avx-linux-ipa.o: i386-avx-linux.c): Remove.
7159 (i386-mpx-linux-ipa.o: i386-mpx-linux.c): Remove.
7160 (i386-avx-mpx-linux-ipa.o: i386-avx-mpx-linux.c): Remove.
7161 (i386-avx-avx512-linux-ipa.o: i386-avx-avx512-linux.c): Remove.
7162 (i386-avx-mpx-avx512-pku-linux-ipa.o: i386-avx-mpx-avx512-pku-linux.c): Remove.
7163 (amd64-linux-ipa.o: amd64-linux.c): Remove.
7164 (amd64-avx-linux-ipa.o: amd64-avx-linux.c): Remove.
7165 (amd64-mpx-linux-ipa.o: amd64-mpx-linux.c): Remove.
7166 (amd64-avx-mpx-linux-ipa.o: amd64-avx-mpx-linux.c): Remove.
7167 (amd64-avx-avx512-linux-ipa.o: amd64-avx-avx512-linux.c): Remove.
7168 (amd64-avx-mpx-avx512-pku-linux-ipa.o: amd64-avx-mpx-avx512-pku-linux.c): Remove.
7169 (aarch64-ipa.o: aarch64.c): Remove.
7170 (s390-linux32-ipa.o: s390-linux32.c): Remove.
7171 (s390-linux32v1-ipa.o: s390-linux32v1.c): Remove.
7172 (s390-linux32v2-ipa.o: s390-linux32v2.c): Remove.
7173 (s390-linux64-ipa.o: s390-linux64.c): Remove.
7174 (s390-linux64v1-ipa.o: s390-linux64v1.c): Remove.
7175 (s390-linux64v2-ipa.o: s390-linux64v2.c): Remove.
7176 (s390-te-linux64-ipa.o: s390-te-linux64.c): Remove.
7177 (s390-vx-linux64-ipa.o: s390-vx-linux64.c): Remove.
7178 (s390-tevx-linux64-ipa.o: s390-tevx-linux64.c): Remove.
7179 (s390x-linux64-ipa.o: s390x-linux64.c): Remove.
7180 (s390x-linux64v1-ipa.o: s390x-linux64v1.c): Remove.
7181 (s390x-linux64v2-ipa.o: s390x-linux64v2.c): Remove.
7182 (s390x-te-linux64-ipa.o: s390x-te-linux64.c): Remove.
7183 (s390x-vx-linux64-ipa.o: s390x-vx-linux64.c): Remove.
7184 (s390x-tevx-linux64-ipa.o: s390x-tevx-linux64.c): Remove.
7185 (powerpc-32l-ipa.o: powerpc-32l.c): Remove.
7186 (powerpc-altivec32l-ipa.o: powerpc-altivec32l.c): Remove.
7187 (powerpc-cell32l-ipa.o: powerpc-cell32l.c): Remove.
7188 (powerpc-vsx32l-ipa.o: powerpc-vsx32l.c): Remove.
7189 (powerpc-isa205-32l-ipa.o: powerpc-isa205-32l.c): Remove.
7190 (powerpc-isa205-altivec32l-ipa.o: powerpc-isa205-altivec32l.c): Remove.
7191 (powerpc-isa205-vsx32l-ipa.o: powerpc-isa205-vsx32l.c): Remove.
7192 (powerpc-e500l-ipa.o: powerpc-e500l.c): Remove.
7193 (powerpc-64l-ipa.o: powerpc-64l.c): Remove.
7194 (powerpc-altivec64l-ipa.o: powerpc-altivec64l.c): Remove.
7195 (powerpc-cell64l-ipa.o: powerpc-cell64l.c): Remove.
7196 (powerpc-vsx64l-ipa.o: powerpc-vsx64l.c): Remove.
7197 (powerpc-isa205-64l-ipa.o: powerpc-isa205-64l.c): Remove.
7198 (powerpc-isa205-altivec64l-ipa.o: powerpc-isa205-altivec64l.c): Remove.
7199 (powerpc-isa205-vsx64l-ipa.o: powerpc-isa205-vsx64l.c): Remove.
7200 (tdesc-ipa.o: tdesc.c): Remove.
7201 (x32-linux-ipa.o: x32-linux.c): Remove.
7202 (x32-avx-linux-ipa.o: x32-avx-linux.c): Remove.
7203 (x32-avx512-linux-ipa.o: x32-avx512-linux.c): Remove.
7205 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7207 * Makefile.in (%.o: ../arch/%.c): New rule.
7208 (arm.o: ../arch/arm.c): Remove.
7209 (arm-linux.o: ../arch/arm-linux.c): Remove.
7210 (arm-get-next-pcs.o: ../arch/arm-get-next-pcs.c): Remove.
7211 (aarch64-insn.o: ../arch/aarch64-insn.c): Remove.
7213 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7215 * Makefile.in (%.o: ../nat/%.c): New rule.
7216 (x86-dregs.o: ../nat/x86-dregs.c): Remove.
7217 (amd64-linux-siginfo.o: ../nat/amd64-linux-siginfo.c): Remove.
7218 (linux-btrace.o: ../nat/linux-btrace.c): Remove.
7219 (linux-osdata.o: ../nat/linux-osdata.c): Remove.
7220 (linux-procfs.o: ../nat/linux-procfs.c): Remove.
7221 (linux-ptrace.o: ../nat/linux-ptrace.c): Remove.
7222 (linux-waitpid.o: ../nat/linux-waitpid.c): Remove.
7223 (mips-linux-watch.o: ../nat/mips-linux-watch.c): Remove.
7224 (ppc-linux.o: ../nat/ppc-linux.c): Remove.
7225 (linux-personality.o: ../nat/linux-personality.c): Remove.
7226 (aarch64-linux-hw-point.o: ../nat/aarch64-linux-hw-point.c): Remove.
7227 (aarch64-linux.o: ../nat/aarch64-linux.c): Remove.
7228 (x86-linux.o: ../nat/x86-linux.c): Remove.
7229 (x86-linux-dregs.o: ../nat/x86-linux-dregs.c): Remove.
7230 (linux-namespaces.o: ../nat/linux-namespaces.c): Remove.
7232 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7234 * Makefile.in (%.o: ../common/%.c): New rule.
7235 (signals.o: ../common/signals.c): Remove.
7236 (print-utils.o: ../common/print-utils.c): Remove.
7237 (rsp-low.o: ../common/rsp-low.c): Remove.
7238 (common-utils.o: ../common/common-utils.c): Remove.
7239 (posix-strerror.o: ../common/posix-strerror.c): Remove.
7240 (mingw-strerror.o: ../common/mingw-strerror.c): Remove.
7241 (vec.o: ../common/vec.c): Remove.
7242 (gdb_vecs.o: ../common/gdb_vecs.c): Remove.
7243 (xml-utils.o: ../common/xml-utils.c): Remove.
7244 (ptid.o: ../common/ptid.c): Remove.
7245 (buffer.o: ../common/buffer.c): Remove.
7246 (format.o: ../common/format.c): Remove.
7247 (filestuff.o: ../common/filestuff.c): Remove.
7248 (agent.o: ../common/agent.c): Remove.
7249 (errors.o: ../common/errors.c): Remove.
7250 (environ.o: ../common/environ.c): Remove.
7251 (common-debug.o: ../common/common-debug.c): Remove.
7252 (cleanups.o: ../common/cleanups.c): Remove.
7253 (common-exceptions.o: ../common/common-exceptions.c): Remove.
7254 (fileio.o: ../common/fileio.c): Remove.
7255 (common-regcache.o: ../common/common-regcache.c): Remove.
7256 (signals-state-save-restore.o: ../common/signals-state-save-restore.c): Remove.
7257 (new-op.o: ../common/new-op.c): Remove.
7258 (btrace-common.o: ../common/btrace-common.c): Remove.
7260 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7262 * Makefile.in (%.o: ../target/%.c): New rule.
7263 (waitstatus.o: ../target/waitstatus.c): Remove.
7265 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
7268 (%.c: ../regformats/%.dat,
7269 (%.c: ../regformats/arm/%.dat,
7270 (%.c: ../regformats/i386/%.dat,
7271 (%.c: ../regformats/rs6000/%.dat): New rules.
7272 (aarch64.c): Remove.
7273 (reg-arm.c): Remove.
7274 (arm-with-iwmmxt.c): Remove.
7275 (arm-with-vfpv2.c): Remove.
7276 (arm-with-vfpv3.c): Remove.
7277 (arm-with-neon.c): Remove.
7278 (reg-bfin.c): Remove.
7279 (reg-cris.c): Remove.
7280 (reg-crisv32.c): Remove.
7282 (i386-linux.c): Remove.
7283 (i386-avx.c): Remove.
7284 (i386-avx-linux.c): Remove.
7285 (i386-avx-avx512.c): Remove.
7286 (i386-avx-avx512-linux.c): Remove.
7287 (i386-mpx.c): Remove.
7288 (i386-mpx-linux.c): Remove.
7289 (i386-avx-mpx-avx512-pku.c): Remove.
7290 (i386-avx-mpx-avx512-pku-linux.c): Remove.
7291 (i386-avx-mpx.c): Remove.
7292 (i386-avx-mpx-linux.c): Remove.
7293 (i386-mmx.c): Remove.
7294 (i386-mmx-linux.c): Remove.
7295 (reg-ia64.c): Remove.
7296 (reg-m32r.c): Remove.
7297 (reg-m68k.c): Remove.
7299 (mips-linux.c): Remove.
7300 (mips-dsp-linux.c): Remove.
7301 (mips64-linux.c): Remove.
7302 (mips64-dsp-linux.c): Remove.
7303 (nios2-linux.c): Remove.
7304 (powerpc-32.c): Remove.
7305 (powerpc-32l.c): Remove.
7306 (powerpc-altivec32l.c): Remove.
7307 (powerpc-cell32l.c): Remove.
7308 (powerpc-vsx32l.c): Remove.
7309 (powerpc-isa205-32l.c): Remove.
7310 (powerpc-isa205-altivec32l.c): Remove.
7311 (powerpc-isa205-vsx32l.c): Remove.
7312 (powerpc-e500l.c): Remove.
7313 (powerpc-64l.c): Remove.
7314 (powerpc-altivec64l.c): Remove.
7315 (powerpc-cell64l.c): Remove.
7316 (powerpc-vsx64l.c): Remove.
7317 (powerpc-isa205-64l.c): Remove.
7318 (powerpc-isa205-altivec64l.c): Remove.
7319 (powerpc-isa205-vsx64l.c): Remove.
7320 (s390-linux32.c): Remove.
7321 (s390-linux32v1.c): Remove.
7322 (s390-linux32v2.c): Remove.
7323 (s390-linux64.c): Remove.
7324 (s390-linux64v1.c): Remove.
7325 (s390-linux64v2.c): Remove.
7326 (s390-te-linux64.c): Remove.
7327 (s390-vx-linux64.c): Remove.
7328 (s390-tevx-linux64.c): Remove.
7329 (s390x-linux64.c): Remove.
7330 (s390x-linux64v1.c): Remove.
7331 (s390x-linux64v2.c): Remove.
7332 (s390x-te-linux64.c): Remove.
7333 (s390x-vx-linux64.c): Remove.
7334 (s390x-tevx-linux64.c): Remove.
7335 (tic6x-c64xp-linux.c): Remove.
7336 (tic6x-c64x-linux.c): Remove.
7337 (tic6x-c62x-linux.c): Remove.
7339 (reg-sparc64.c): Remove.
7340 (reg-spu.c): Remove.
7342 (amd64-linux.c): Remove.
7343 (amd64-avx.c): Remove.
7344 (amd64-avx-linux.c): Remove.
7345 (amd64-avx-avx512.c): Remove.
7346 (amd64-avx-avx512-linux.c): Remove.
7347 (amd64-mpx.c): Remove.
7348 (amd64-mpx-linux.c): Remove.
7349 (amd64-avx-mpx-avx512-pku.c): Remove.
7350 (amd64-avx-mpx-avx512-pku-linux.c): Remove.
7351 (amd64-avx-mpx.c): Remove.
7352 (amd64-avx-mpx-linux.c): Remove.
7354 (x32-linux.c): Remove.
7355 (x32-avx.c): Remove.
7356 (x32-avx-linux.c): Remove.
7357 (x32-avx-avx512.c): Remove.
7358 (x32-avx-avx512-linux.c): Remove.
7359 (reg-xtensa.c): Remove.
7360 (reg-tilegx.c): Remove.
7361 (reg-tilegx32.c): Remove.
7363 2017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
7365 * Makefile.in (SFILES): Add "common/environ.c".
7366 (OBJS): Add "common/environ.h".
7368 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
7370 * configure.ac: Check if the fs_base and gs_base members of
7371 `struct user_regs_struct' exist.
7372 * config.in: Regenerated.
7373 * configure: Likewise.
7375 2017-01-09 Antoine Tremblay <antoine.tremblay@ericsson.com>
7377 * linux-aarch32-low.c (arm_breakpoint_kind_from_pc): Use
7379 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer): Likewise.
7380 (get_next_pcs_syscall_next_pc): Likewise.
7382 2016-12-23 Luis Machado <lgustavo@codesourcery.com>
7384 * win32-i386-low.c: Fix incorrect reference to a couple source files.
7385 * nto-x86-low.c: Likewise.
7387 2016-11-30 Simon Marchi <simon.marchi@polymtl.ca>
7389 * Makefile.in: Include disable-implicit-rules.mk.
7391 2016-11-23 Pedro Alves <palves@redhat.com>
7393 * debug.c: Include <chrono> instead of "gdb_sys_time.h".
7394 (debug_vprintf): Use std::chrono::steady_clock instead of
7395 gettimeofday. Use '.' instead of ':'.
7396 * tracepoint.c: Include <chrono> instead of "gdb_sys_time.h".
7397 (get_timestamp): Use std::chrono::steady_clock instead of
7400 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
7402 * Makefile.in: Fix whitespace formatting.
7404 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
7406 * Makefile.in (SFILES, OBS): Flatten list and order
7409 2016-11-23 Pedro Alves <palves@redhat.com>
7411 * event-loop.c (handle_file_event): Use warning.
7412 * linux-low.c (linux_resume_one_lwp_throw): Use warning.
7413 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
7416 2016-11-23 Pedro Alves <palves@redhat.com>
7418 * linux-low.c (check_zombie_leaders): Use debug_printf for debug
7420 * notif.c (handle_notif_ack, notif_event_enque): Likewise.
7421 * remote-utils.c (putpkt_binary_1, readchar, getpkt): Use
7422 debug_printf and debug_flush for debug output.
7423 * server.c (handle_general_set): Likewise.
7424 * thread-db.c (try_thread_db_load): Use debug_printf for debug
7427 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
7429 * Makefile.in (.c.o): Replace rule with ...
7430 (%.o: %.c): ... this one.
7432 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
7434 * Makefile.in: Remove @GMAKE_TRUE@ prefixes and removes lines
7435 prefixed with @GMAKE_FALSE@. Update comment related to non-GNU
7437 * configure.ac: Remove checks for the make program.
7438 * configure: Re-generate.
7440 2016-10-28 Pedro Alves <palves@redhat.com>
7442 * Makefile.in (CXX_DIALECT): Get from configure.
7443 (COMPILE.pre, CC_LD): Append $(CXX_DIALECT).
7444 * acinclude.m4: Include ../ax_cxx_compile_stdcxx.m4.
7445 * configure.ac: Call AX_CXX_COMPILE_STDCXX.
7446 * config.in: Regenerate.
7447 * configure: Regenerate.
7449 2016-10-27 Yao Qi <yao.qi@linaro.org>
7451 * linux-low.c (linux_supports_range_stepping): Return true if
7452 can_software_single_step return true.
7454 2016-10-27 Yao Qi <yao.qi@linaro.org>
7456 * inferiors.c (find_inferior_in_random): New function.
7457 * inferiors.h (find_inferior_in_random): Declare.
7458 * linux-low.c (linux_wait_for_event_filtered): Call
7459 find_inferior_in_random instead of find_inferior.
7461 2016-10-27 Yao Qi <yao.qi@linaro.org>
7463 * linux-low.c (linux_wait_1): If single-step breakpoints are
7464 inserted, remove them.
7466 2016-10-26 Pedro Alves <palves@redhat.com>
7468 * linux-low.c (handle_extended_wait): Link parent/child fork
7470 (linux_wait_1): Unlink them.
7471 (linux_set_resume_request): Ignore resume requests for
7472 already-resumed and unhandled fork child threads.
7473 * linux-low.h (struct lwp_info) <fork_relative>: New field.
7474 * server.c (in_queued_stop_replies_ptid, in_queued_stop_replies):
7476 (handle_v_requests) <vCont>: Don't call require_running.
7477 * server.h (in_queued_stop_replies): New declaration.
7479 2016-10-24 Yao Qi <yao.qi@linaro.org>
7482 * linux-aarch64-low.c (append_insns): Cast the return value to
7485 2016-10-10 Yao Qi <yao.qi@linaro.org>
7487 * linux-aarch32-low.c (enum arm_breakpoint_kinds): Remove.
7489 2016-10-06 Sergio Durigan Junior <sergiodj@redhat.com>
7491 * target.c (target_supports_multi_process): New function, moved
7493 * target.h (target_supports_multi_process): ... here. Remove
7496 2016-10-05 Tom Tromey <tom@tromey.com>
7499 * tracepoint.c (handle_tracepoint_bkpts): Check
7500 ipa_error_tracepoint, not ipa_stopping_tracepoint.
7502 2016-10-05 Yao Qi <yao.qi@linaro.org>
7504 * configure.srv: Update the path of arm-*.xml files.
7506 2016-10-05 Terry Guo <terry.guo@arm.com>
7507 Yao Qi <yao.qi@linaro.org>
7509 * Makefile.in: Adjust the path of rules.
7510 * configure.srv: Update the path of xml files.
7511 * regformats/arm-with-iwmmxt.dat: Regenerated.
7512 * regformats/arm-with-neon.dat: Likewise.
7513 * regformats/arm-with-vfpv2.dat: Likewise.
7514 * regformats/arm-with-vfpv3.dat Likewise.
7516 2016-09-30 Yao Qi <yao.qi@linaro.org>
7519 * target.c (target_stop_and_wait): Don't call
7520 target_continue_no_signal, use resume_stop instead.
7522 2016-09-26 Yao Qi <yao.qi@linaro.org>
7524 * linux-low.c (linux_wait_1): Call debug_exit.
7526 2016-09-23 Pedro Alves <palves@redhat.com>
7528 * Makefile.in (SFILES): Add common/new-op.c.
7529 (OBS): Add common/new-op.o.
7530 (new-op.o): New rule.
7532 2016-09-21 Simon Marchi <simon.marchi@ericsson.com>
7534 * .gitinore: Ignore more files.
7536 2016-09-21 Yao Qi <yao.qi@linaro.org>
7538 * linux-aarch32-low.c (arm_fill_gregset): Keep bits 20 to
7541 2016-09-19 Sergio Durigan Junior <sergiodj@redhat.com>
7543 * server.c (start_inferior): Call target_mourn_inferior instead of
7544 mourn_inferior; pass ptid_t argument to it.
7546 (handle_target_event): Likewise.
7547 * target.c (target_mourn_inferior): New function.
7548 * target.h (mourn_inferior): Delete macro.
7550 2016-09-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
7552 * linux-low.c (lwp_is_stepping): New function.
7554 2016-09-06 Carl Love <cel@us.ibm.com>
7556 * server.c (start_inferior): Fixed comment, requested comment change
7557 didn't get updated correctly. Removed reference to ptrace () call as
7558 it is only true on Linux systems.
7560 2016-09-06 Carl Love <cel@us.ibm.com>
7562 * server.c (start_inferior): Do not call
7563 function target_post_create_inferior () if the
7564 inferior process has already exited.
7566 2016-09-05 Pedro Alves <palves@redhat.com>
7568 * Makefile.in (COMPILER, COMPILER_CFLAGS): Remove.
7569 (COMPILE.pre, CC_LD): Use CXX directly.
7570 (INTERNAL_CFLAGS_BASE): Use CXXFLAGS directly.
7571 * acinclude.m4: Don't include build-with-cxx.m4.
7572 * configure.ac: Remove GDB_AC_BUILD_WITH_CXX call.
7573 * configure: Regenerate.
7575 2016-09-02 Akash Trehan <akash.trehan123@gmail.com>
7578 * remote-utils.c (relocate_instruction): Remove redundant strcpy()
7579 call writing data to own_buf.
7581 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
7583 * target.c (mywait): Call target_wait instead of
7585 (target_wait): New function.
7587 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
7589 * server.c (start_inferior): New variable 'ptid'. Replace calls
7590 to the_target->resume by target_continue{,_no_signal}, depending
7592 * target.c (target_stop_and_wait): Call target_continue_no_signal
7593 instead of the_target->resume.
7594 (target_continue): New function.
7596 2016-08-31 Antoine Tremblay <antoine.tremblay@ericsson.com>
7598 * linux-low.c (linux_wait_1): Move event switch after unsuspend_lwps.
7600 2016-08-25 Adhemerval Zanella <adhemerval.zanella@linaro.org>
7603 * gdb_proc_service.h (ps_get_thread_area): Remove const from struct
7605 * linux-aarch64-low.c (ps_get_thread_area): Likewise.
7606 * linux-arm-low.c (ps_get_thread_area): Likewise.
7607 * linux-crisv32-low.c (ps_get_thread_area): Likewise.
7608 * linux-m68k-low.c (ps_get_thread_area): Likewise.
7609 * linux-mips-low.c (ps_get_thread_area): Likewise.
7610 * linux-nios2-low.c (ps_get_thread_area): Likewise.
7611 * linux-tic6x-low.c (ps_get_thread_area): Likewise.
7612 * linux-x86-low.c (ps_get_thread_area): Likewise.
7613 * linux-xtensa-low.c (ps_get_thread_area): Likewise.
7615 2016-08-19 Pedro Alves <palves@redhat.com>
7617 * linux-x86-low.c (amd64_emit_call): Emit missing call opcode.
7619 2016-08-19 Pedro Alves <palves@redhat.com>
7621 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Fix
7622 comment. Use memcpy instead of casting through unsigned long.
7624 2016-08-19 Pedro Alves <palves@redhat.com>
7626 * linux-amd64-ipa.c (alloc_jump_pad_buffer) [__ILP32__]: Try
7627 allocating around 0x80000000.
7629 2016-08-19 Pedro Alves <palves@redhat.com>
7632 * Makefile.in (x32-linux-ipa.o, x32-avx-linux-ipa.o)
7633 (x32-avx512-linux-ipa.o): New rules.
7634 * configure.ac (x86_64-*-linux*): New x32 check.
7635 * configure.srv (ipa_x32_linux_regobj): New.
7636 (x86_64-*-linux*): Use $ipa_x32_linux_regobj if building for x32.
7637 * linux-amd64-ipa.c (get_ipa_tdesc) [__ILP32__]: Return x32
7639 (initialize_low_tracepoint) [__ILP32__]: Initialize x32
7641 * configure: Regenerate.
7643 2016-08-09 Pedro Alves <palves@redhat.com>
7646 * Makefile.in (OBS): Add signals-state-save-restore.o.
7647 (signals-state-save-restore.o): New rule.
7648 * config.in: Regenerate.
7649 * configure: Regenerate.
7650 * linux-low.c: Include "signals-state-save-restore.h".
7651 (linux_create_inferior): Call
7652 restore_original_signals_state.
7653 * server.c: Include "dispositions-save-restore.h".
7654 (captured_main): Call save_original_signals_state.
7656 2016-08-05 Pedro Alves <palves@redhat.com>
7658 * configure: Regenerate.
7660 2016-08-04 Yao Qi <yao.qi@linaro.org>
7662 * linux-low.c (regsets_fetch_inferior_registers): Check
7663 errno is ESRCH or not.
7665 2016-08-02 Yao Qi <yao.qi@linaro.org>
7667 * thread-db.c (struct thread_db) <td_ta_event_getmsg_p>: Remove.
7668 <td_ta_set_event_p, td_ta_event_addr_p>: Remove.
7669 (thread_db_load_search): Update.
7670 (try_thread_db_load_1): Don't look for td_ta_event_addr,
7671 td_ta_set_event and td_ta_event_getmsg.
7673 2016-07-26 Pedro Alves <palves@redhat.com>
7676 * linux-x86-low.c (x86_get_pc, x86_set_pc): Use uint64_t instead
7677 of unsigned long for 64-bit registers and use uint32_t instead of
7678 unsigned int for 32-bit registers.
7680 2016-07-26 Pedro Alves <palves@redhat.com>
7682 * linux-x86-low.c (x86_siginfo_fixup): Rename 'native' parameter
7685 2016-07-21 Tom Tromey <tom@tromey.com>
7687 * configure: Rebuild.
7689 2016-07-21 Yao Qi <yao.qi@linaro.org>
7691 * mem-break.c (find_gdb_breakpoint): Cast bp to
7692 'struct gdb_breakpoint *' rather than 'gdb_breakpoint *'.
7694 2016-07-21 Yao Qi <yao.qi@linaro.org>
7696 * server.c (handle_v_requests): Support s and S actions
7697 if target_supports_software_single_step return true.
7699 2016-07-21 Yao Qi <yao.qi@linaro.org>
7701 * linux-low.c (resume_stopped_resumed_lwps): If resume request
7702 is resume_step, call maybe_hw_step.
7703 (linux_wait_1): Stop all threads, remove reinsert breakpoints,
7705 (linux_resume_one_lwp_throw): Don't assert the thread has reinsert
7707 (proceed_one_lwp): If resume request is resume_step, install
7708 reinsert breakpoints and call maybe_hw_step.
7710 2016-07-21 Yao Qi <yao.qi@linaro.org>
7712 * linux-low.c (proceed_one_lwp): Declare.
7713 (linux_resume_one_thread): Remove local variable 'step'.
7714 Lift code enqueue signal. Call proceed_one_lwp instead of
7715 linux_resume_one_lwp.
7717 2016-07-21 Yao Qi <yao.qi@linaro.org>
7719 * linux-low.c (linux_resume_one_thread): Call
7720 enqueue_pending_signal.
7722 2016-07-21 Yao Qi <yao.qi@linaro.org>
7724 * gdbthread.h (make_cleanup_restore_current_thread): Declare.
7725 * inferiors.c (do_restore_current_thread_cleanup): New function.
7726 (make_cleanup_restore_current_thread): Likewise.
7727 * linux-low.c (install_software_single_step_breakpoints): Call
7728 make_cleanup_restore_current_thread. Switch current_thread to
7731 2016-07-21 Yao Qi <yao.qi@linaro.org>
7733 * mem-break.c (struct reinsert_breakpoint) <ptid>: New field.
7734 (set_reinsert_breakpoint): New parameter ptid. Callers updated.
7735 (clone_one_breakpoint): Likewise.
7736 (delete_reinsert_breakpoints): Change parameter to thread.
7738 (has_reinsert_breakpoints): Likewise.
7739 (uninsert_reinsert_breakpoints): Likewise.
7740 (reinsert_reinsert_breakpoints): Likewise.
7741 * mem-break.h (set_reinsert_breakpoint): Update declaration.
7742 (delete_reinsert_breakpoints): Likewise.
7743 (reinsert_reinsert_breakpoints): Likewise.
7744 (uninsert_reinsert_breakpoints): Likewise.
7745 (has_reinsert_breakpoints): Likewise.
7747 2016-07-21 Yao Qi <yao.qi@linaro.org>
7749 * inferiors.c (get_thread_process): Make parameter const.
7750 * inferiors.h (get_thread_process): Update declaration.
7751 * mem-break.c (clone_all_breakpoints): Remove all parameters.
7752 Add new parameters child_thread and parent_thread. Callers
7754 * mem-break.h (clone_all_breakpoints): Update declaration.
7756 2016-07-21 Yao Qi <yao.qi@linaro.org>
7758 * mem-break.c (struct breakpoint) <cond_list>: Remove.
7759 <command_list, handler>: Remove.
7760 (struct gdb_breakpoint): New.
7761 (struct other_breakpoint): New.
7762 (struct reinsert_breakpoint): New.
7763 (is_gdb_breakpoint): New function.
7764 (any_persistent_commands): Update command_list if
7765 is_gdb_breakpoint returns true.
7766 (set_breakpoint): Create breakpoints according to their types.
7767 (find_gdb_breakpoint): Return 'struct gdb_breakpoint *'.
7768 (set_gdb_breakpoint_1): Likewise.
7769 (set_gdb_breakpoint): Likewise.
7770 (clear_breakpoint_conditions): Change parameter type to
7771 'struct gdb_breakpoint *'.
7772 (clear_breakpoint_commands): Likewise.
7773 (clear_breakpoint_conditions_and_commands): Likewise.
7774 (add_condition_to_breakpoint): Likewise.
7775 (add_breakpoint_condition): Likewise.
7776 (add_commands_to_breakpoint): Likewise.
7777 (check_breakpoints): Check other_breakpoint.
7778 (clone_one_breakpoint): Clone breakpopint according to its type.
7779 * mem-break.h (struct gdb_breakpoint): Declare.
7780 (set_gdb_breakpoint): Update declaration.
7781 (clear_breakpoint_conditions_and_commands): Likewise.
7782 (add_breakpoint_condition): Likewise.
7783 (add_breakpoint_commands): Likewise.
7784 * server.c (process_point_options): Change parameter type to
7785 'struct gdb_breakpoint *'.
7787 2016-07-21 Yao Qi <yao.qi@linaro.org>
7789 * mem-break.c (set_breakpoint_at): Rename it to ...
7790 (set_breakpoint_type_at): ... it.
7791 (set_breakpoint_at): Call set_breakpoint_type_at.
7792 (set_reinsert_breakpoint): Call set_breakpoint_type_at.
7793 * mem-break.h (set_breakpoint_at): Update comments.
7795 2016-07-12 Chung-Lin Tang <cltang@codesourcery.com>
7797 * linux-nios2-low.c (nios2_fill_gregset): Add type cast
7799 (nios2_store_gregset): Likewise.
7801 2016-07-01 Pedro Alves <palves@redhat.com>
7802 Antoine Tremblay <antoine.tremblay@ericsson.com>
7804 * linux-low.c: Change interface to take the target lwp_info
7805 pointer directly and return void. Handle detaching from a zombie
7807 (linux_detach_lwp_callback): New function.
7808 (linux_detach): Detach from the leader thread after detaching from
7811 2016-06-28 Yao Qi <yao.qi@linaro.org>
7813 * linux-aarch64-low.c (aarch64_ftrace_insn_reloc_b): Use int64_t
7814 for variable new_offset.
7815 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
7816 (aarch64_ftrace_insn_reloc_cb): Likewise.
7817 (aarch64_ftrace_insn_reloc_tb): Likewise.
7818 (aarch64_install_fast_tracepoint_jump_pad): Likewise. Use
7819 PRIx64 instead of PRIx32.
7821 2016-06-28 Yao Qi <yao.qi@linaro.org>
7823 * linux-arm-low.c (arm_get_syscall_trapinfo): New function.
7824 (the_low_target): Install arm_get_syscall_trapinfo.
7826 2016-06-28 Yao Qi <yao.qi@linaro.org>
7828 * linux-aarch64-low.c (aarch64_get_syscall_trapinfo): New
7830 (the_low_target): Install aarch64_get_syscall_trapinfo.
7832 2016-06-28 Yao Qi <yao.qi@linaro.org>
7834 * linux-low.c (get_syscall_trapinfo): Remove parameter sysret.
7836 * linux-low.h (struct linux_target_ops) <get_syscall_trapinfo>:
7837 Remove parameter sysno.
7838 * linux-x86-low.c (x86_get_syscall_trapinfo): Remove parameter
7841 2016-06-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
7843 * linux-s390-low.c (s390_emit_eq_goto): Mark function static.
7844 (s390_emit_ne_goto): Likewise.
7845 (s390_emit_lt_goto): Likewise.
7846 (s390_emit_le_goto): Likewise.
7847 (s390_emit_gt_goto): Likewise.
7848 (s390_emit_ge_goto): Likewise.
7849 (s390x_emit_eq_goto): Likewise.
7850 (s390x_emit_ne_goto): Likewise.
7851 (s390x_emit_lt_goto): Likewise.
7852 (s390x_emit_le_goto): Likewise.
7853 (s390x_emit_gt_goto): Likewise.
7854 (s390x_emit_ge_goto): Likewise.
7855 (s390_emit_ops_impl): Mark variable static.
7856 (s390x_emit_ops): Likewise.
7858 2016-06-17 Yao Qi <yao.qi@linaro.org>
7860 * linux-low.c (handle_extended_wait): Call
7861 uninsert_reinsert_breakpoints for the parent process. Remove
7862 reinsert breakpoints from the child process. Reinsert them to
7863 the parent process when vfork is done.
7864 * mem-break.c (uninsert_reinsert_breakpoints): New function.
7865 (reinsert_reinsert_breakpoints): New function.
7866 * mem-break.h (uninsert_reinsert_breakpoints): Declare
7867 (reinsert_reinsert_breakpoints): Declare.
7869 2016-06-17 Yao Qi <yao.qi@linaro.org>
7871 * linux-low.c (handle_extended_wait): If the parent is doing
7872 step-over, remove the reinsert breakpoints from the forked child.
7874 2016-06-17 Yao Qi <yao.qi@linaro.org>
7876 * linux-low.c (unsuspend_all_lwps): Declare.
7877 (linux_low_filter_event): If thread exited, call finish_step_over.
7878 If step-over is finished, unsuspend other threads.
7880 2016-06-17 Yao Qi <yao.qi@linaro.org>
7882 * linux-low.c (linux_resume_one_lwp_throw): Assert
7883 has_reinsert_breakpoints returns false.
7884 * mem-break.c (delete_disabled_breakpoints): Assert
7885 bp type isn't reinsert_breakpoint.
7887 2016-06-17 Yao Qi <yao.qi@linaro.org>
7889 * linux-low.c (maybe_hw_step): New function.
7890 (linux_resume_one_lwp_throw): Call maybe_hw_step.
7891 (finish_step_over): Switch current_thread to lwp temporarily,
7892 and assert has_reinsert_breakpoints returns true.
7893 (proceed_one_lwp): Call maybe_hw_step.
7894 * mem-break.c (has_reinsert_breakpoints): New function.
7895 * mem-break.h (has_reinsert_breakpoints): Declare.
7897 2016-06-02 Jon Turney <jon.turney@dronecode.org.uk>
7899 * win32-low.c (win32_create_inferior): Add pointer casts for C++.
7901 2016-05-17 Yao Qi <yao.qi@linaro.org>
7903 * linux-low.c (linux_stabilize_threads): Call unsuspend_all_lwps
7904 instead of find_inferior.
7906 2016-05-05 Yao Qi <yao.qi@linaro.org>
7908 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer):
7909 Initialize res to zero.
7911 2016-05-05 Yao Qi <yao.qi@linaro.org>
7913 * linux-arm-low.c (arm_sigreturn_next_pc): Change type of cpsr
7916 2016-05-04 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
7918 * spu-low.c (fetch_ppc_register): Cast PowerPC-Linux-specific value
7919 used as first ptrace argument to PTRACE_TYPE_ARG1 for C++.
7920 (fetch_ppc_memory_1, store_ppc_memory_1): Likewise.
7922 2016-04-28 Par Olsson <par.olsson@windriver.com>
7923 Simon Marchi <simon.marchi@ericsson.com>
7925 * tracepoint.c (write_inferior_int8): New function.
7926 (cmd_qtenable_disable): Write enable flag using
7927 write_inferior_int8.
7929 2016-04-25 Yao Qi <yao.qi@linaro.org>
7931 * linux-low.c (lwp_signal_can_be_delivered): Adjust.
7932 (need_step_over_p): Return zero if the LWP has pending signals
7933 can be delivered on software single step target.
7935 2016-04-25 Yao Qi <yao.qi@linaro.org>
7937 * linux-low.c (reinsert_raw_breakpoint): If bp->inserted is true
7938 return instead of error.
7940 2016-04-22 Yao Qi <yao.qi@linaro.org>
7942 * linux-aarch32-low.c (arm_store_gregset): Clear CPSR bits 20
7945 2016-04-22 Yao Qi <yao.qi@linaro.org>
7947 * linux-low.c (lwp_signal_can_be_delivered): Don't deliver
7948 signal when stepping over breakpoint with software single
7951 2016-04-21 Pedro Alves <palves@redhat.com>
7953 * linux-s390-low.c (s390_collect_ptrace_register)
7954 (s390_supply_ptrace_register, s390_get_hwcap): Use gdb_byte * and
7956 (s390_check_regset): Use void * instead of gdb_byte *.
7958 2016-04-20 Pedro Alves <palves@redhat.com>
7960 * configure: Renegerate.
7962 2016-04-20 Yao Qi <yao.qi@linaro.org>
7964 * linux-aarch32-low.c: Include "arch/arm-linux.h".
7965 (arm_fill_gregset): Use ARM_CPSR_GREGNUM rather than magic
7967 (arm_store_gregset): Likewise.
7969 2016-04-16 Walfred Tedeschi <walfred.tedeschi@intel.com>
7971 * Makefile.in (clean): Add removal for i386-avx-mpx.c,
7972 i386-avx-mpx-linux.c, amd64-avx-mpx.c and amd64-avx-mpx-linux.c.
7973 (i386-avx-mpx.c, i386-avx-mpx-linux.c, amd64-avx-mpx.c)
7974 (amd64-avx-mpx-linux.c): New rules.
7975 (amd64-avx-mpx-linux-ipa.o, i386-avx-mpx-linux-ipa.o): New rule.
7976 * configure.srv (srv_i386_regobj): Add i386-avx-mpx.o.
7977 (srv_i386_linux_regobj): Add i386-avx-mpx-linux.o.
7978 (srv_amd64_regobj): Add amd64-avx-mpx.o.
7979 (srv_amd64_linux_regobj): Add amd64-avx-mpx-linux.o.
7980 (srv_i386_xmlfiles): Add i386/i386-avx-mpx.xml.
7981 (srv_amd64_xmlfiles): Add i386/amd64-avx-mpx.xml.
7982 (srv_i386_linux_xmlfiles): Add i386/i386-avx-mpx-linux.xml.
7983 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-mpx-linux.xml.
7984 (ipa_i386_linux_regobj): Add i386-avx-mpx-linux-ipa.o.
7985 (ipa_amd64_linux_regobj): Add amd64-avx-mpx-linux-ipa.o.
7986 * linux-x86-low.c (x86_linux_read_description): Add case for
7987 X86_XSTATE_AVX_MPX_MASK.
7988 (x86_get_ipa_tdesc_idx): Add cases for avx_mpx.
7989 (initialize_low_arch): Call init_registers_amd64_avx_mpx_linux and
7990 init_registers_i386_avx_mpx_linux.
7991 * linux-i386-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
7992 (initialize_low_tracepoint): Call
7993 init_registers_i386_avx_mpx_linux.
7994 * linux-amd64-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
7995 (initialize_low_tracepoint): Call
7996 init_registers_amd64_avx_mpx_linux.
7997 * linux-x86-tdesc.h (X86_TDESC_AVX_MPX): New enum value.
7998 (init_registers_amd64_avx_mpx_linux, tdesc_amd64_avx_mpx_linux)
7999 (init_registers_i386_avx_mpx_linux, tdesc_i386_avx_mpx_linux): New
8002 2016-04-18 Pedro Alves <palves@redhat.com>
8004 * configure: Regenerate.
8006 2016-04-13 Antoine Tremblay <antoine.tremblay@ericsson.com>
8008 * linux-aarch64-low.c (aarch64_emit_add): Switch x1 and x0.
8009 (aarch64_emit_sub): Likewise.
8011 2016-04-12 Pedro Alves <palves@redhat.com>
8013 * utils.c (prepare_to_throw_exception): Delete.
8015 2016-04-05 Simon Marchi <simon.marchi@ericsson.com>
8017 * Makefile.in ($(IPA_LIB)): Set SONAME of the IPA lib.
8019 2016-04-05 Marcin Kościelnicki <koriakin@0x04.net>
8021 * tracepoint.c (getauxval): Move to #ifdef IN_PROCESS_AGENT.
8023 2016-04-03 Marcin Kościelnicki <koriakin@0x04.net>
8025 * linux-aarch64-ipa.c: Add <elf.h> include.
8026 * linux-ppc-ipa.c: Add <elf.h> include.
8027 * linux-s390-ipa.c: Add <elf.h> include.
8029 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
8031 * tracepoint.c (gdb_collect_ptr): Remove const qualifier.
8032 (get_raw_reg_ptr): Likewise.
8033 (get_trace_state_variable_value_ptr): Likewise.
8034 (set_trace_state_variable_value_ptr): Likewise.
8035 (initialize_tracepoint): Cast alloc_jump_pad_buffer result to
8038 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
8039 Marcin Kościelnicki <koriakin@0x04.net>
8042 * linux-ppc-low.c (emit_insns): New function.
8043 (__EMIT_ASM, _EMIT_ASM, EMIT_ASM): New macros.
8044 (ppc_emit_prologue): New function.
8045 (ppc_emit_epilogue): New function.
8046 (ppc_emit_add): New function.
8047 (ppc_emit_sub): New function.
8048 (ppc_emit_mul): New function.
8049 (ppc_emit_lsh): New function.
8050 (ppc_emit_rsh_signed): New function.
8051 (ppc_emit_rsh_unsigned): New function.
8052 (ppc_emit_ext): New function.
8053 (ppc_emit_zero_ext): New function.
8054 (ppc_emit_log_not): New function.
8055 (ppc_emit_bit_and): New function.
8056 (ppc_emit_bit_or): New function.
8057 (ppc_emit_bit_xor): New function.
8058 (ppc_emit_bit_not): New function.
8059 (ppc_emit_equal): New function.
8060 (ppc_emit_less_signed): New function.
8061 (ppc_emit_less_unsigned): New function.
8062 (ppc_emit_ref): New function.
8063 (ppc_emit_const): New function.
8064 (ppc_emit_reg): New function.
8065 (ppc_emit_pop): New function.
8066 (ppc_emit_stack_flush): New function.
8067 (ppc_emit_swap): New function.
8068 (ppc_emit_stack_adjust): New function.
8069 (ppc_emit_call): New function.
8070 (ppc_emit_int_call_1): New function.
8071 (ppc_emit_void_call_2): New function.
8072 (ppc_emit_if_goto): New function.
8073 (ppc_emit_goto): New function.
8074 (ppc_emit_eq_goto): New function.
8075 (ppc_emit_ne_goto): New function.
8076 (ppc_emit_lt_goto): New function.
8077 (ppc_emit_le_goto): New function.
8078 (ppc_emit_gt_goto): New function.
8079 (ppc_emit_ge_goto): New function.
8080 (ppc_write_goto_address): New function.
8081 (ppc_emit_ops_impl): New static variable.
8082 (ppc64v1_emit_prologue): New function.
8083 (ppc64v2_emit_prologue): New function.
8084 (ppc64_emit_epilogue): New function.
8085 (ppc64_emit_add): New function.
8086 (ppc64_emit_sub): New function.
8087 (ppc64_emit_mul): New function.
8088 (ppc64_emit_lsh): New function.
8089 (ppc64_emit_rsh_signed): New function.
8090 (ppc64_emit_rsh_unsigned): New function.
8091 (ppc64_emit_ext): New function.
8092 (ppc64_emit_zero_ext): New function.
8093 (ppc64_emit_log_not): New function.
8094 (ppc64_emit_bit_and): New function.
8095 (ppc64_emit_bit_or): New function.
8096 (ppc64_emit_bit_xor): New function.
8097 (ppc64_emit_bit_not): New function.
8098 (ppc64_emit_equal): New function.
8099 (ppc64_emit_less_signed): New function.
8100 (ppc64_emit_less_unsigned): New function.
8101 (ppc64_emit_ref): New function.
8102 (ppc64_emit_const): New function.
8103 (ppc64v1_emit_reg): New function.
8104 (ppc64v2_emit_reg): New function.
8105 (ppc64_emit_pop): New function.
8106 (ppc64_emit_stack_flush): New function.
8107 (ppc64_emit_swap): New function.
8108 (ppc64v1_emit_call): New function.
8109 (ppc64v2_emit_call): New function.
8110 (ppc64v1_emit_int_call_1): New function.
8111 (ppc64v2_emit_int_call_1): New function.
8112 (ppc64v1_emit_void_call_2): New function.
8113 (ppc64v2_emit_void_call_2): New function.
8114 (ppc64_emit_if_goto): New function.
8115 (ppc64_emit_eq_goto): New function.
8116 (ppc64_emit_ne_goto): New function.
8117 (ppc64_emit_lt_goto): New function.
8118 (ppc64_emit_le_goto): New function.
8119 (ppc64_emit_gt_goto): New function.
8120 (ppc64_emit_ge_goto): New function.
8121 (ppc64v1_emit_ops_impl): New static variable.
8122 (ppc64v2_emit_ops_impl): New static variable.
8123 (ppc_emit_ops): New function.
8124 (linux_low_target): Wire in ppc_emit_ops.
8126 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
8127 Marcin Kościelnicki <koriakin@0x04.net>
8130 * Makefile.in: Add powerpc-*-ipa.o
8131 * configure.srv: Add ipa_obj for powerpc*-linux.
8132 * linux-ppc-ipa.c: New file.
8133 * linux-ppc-low.c: Added linux-ppc-tdesc.h, ax.h, tracepoint.h
8135 (PPC_FIELD): New macro.
8136 (PPC_SEXT): New macro.
8137 (PPC_OP6): New macro.
8138 (PPC_BO): New macro.
8139 (PPC_LI): New macro.
8140 (PPC_BD): New macro.
8141 (init_registers_*): Move prototype to linux-ppc-tdesc.h.
8142 (tdesc_*): Move declaration to linux-ppc-tdesc.h.
8143 (ppc_get_hwcap): Rename to ppc_get_auxv and add type parameter.
8144 (ppc_get_thread_area): New function.
8145 (is_elfv2_inferior): New function.
8146 (gen_ds_form): New function.
8147 (GEN_STD): New macro.
8148 (GEN_STDU): New macro.
8149 (GEN_LD): New macro.
8150 (GEN_LDU): New macro.
8151 (gen_d_form): New function.
8152 (GEN_ADDI): New macro.
8153 (GEN_ADDIS): New macro.
8154 (GEN_LI): New macro.
8155 (GEN_LIS): New macro.
8156 (GEN_ORI): New macro.
8157 (GEN_ORIS): New macro.
8158 (GEN_LWZ): New macro.
8159 (GEN_STW): New macro.
8160 (GEN_STWU): New macro.
8161 (gen_xfx_form): New function.
8162 (GEN_MFSPR): New macro.
8163 (GEN_MTSPR): New macro.
8164 (GEN_MFCR): New macro.
8165 (GEN_MTCR): New macro.
8166 (GEN_SYNC): New macro.
8167 (GEN_LWSYNC): New macro.
8168 (gen_x_form): New function.
8169 (GEN_OR): New macro.
8170 (GEN_MR): New macro.
8171 (GEN_LWARX): New macro.
8172 (GEN_STWCX): New macro.
8173 (GEN_CMPW): New macro.
8174 (gen_md_form): New function.
8175 (GEN_RLDICL): New macro.
8176 (GEN_RLDICR): New macro.
8177 (gen_i_form): New function.
8179 (GEN_BL): New macro.
8180 (gen_b_form): New function.
8181 (GEN_BNE): New macro.
8182 (GEN_LOAD): New macro.
8183 (GEN_STORE): New macro.
8184 (gen_limm): New function.
8185 (gen_atomic_xchg): New function.
8186 (gen_call): New function.
8187 (ppc_relocate_instruction): New function.
8188 (ppc_install_fast_tracepoint_jump_pad): New function.
8189 (ppc_get_min_fast_tracepoint_insn_len): New function.
8190 (ppc_get_ipa_tdesc_idx): New function.
8191 (the_low_target): Wire in the new functions.
8192 (initialize_low_arch) [!__powerpc64__]: Don'it initialize 64-bit
8194 * linux-ppc-tdesc.h: New file.
8196 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
8198 * linux-aarch64-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
8199 (alloc_jump_pad_buffer): New function.
8200 * linux-amd64-ipa.c: Add <sys/mman.h> include.
8201 (alloc_jump_pad_buffer): New function.
8202 * linux-i386-ipa.c (alloc_jump_pad_buffer): New function.
8203 * linux-s390-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
8204 (alloc_jump_pad_buffer): New function.
8205 * tracepoint.c (getauxval) [!HAVE_GETAUXVAL]: New function.
8206 (initialize_tracepoint): Delegate to alloc_jump_pad_buffer.
8207 * tracepoint.h (alloc_jump_pad_buffer): New prototype.
8208 (getauxval) [!HAVE_GETAUXVAL]: New prototype.
8210 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
8212 * linux-aarch64-ipa.c: Rename gdb_agent_get_raw_reg to get_raw_reg.
8213 * linux-amd64-ipa.c: Likewise.
8214 * linux-i386-ipa.c: Likewise.
8215 * linux-s390-ipa.c: Likewise.
8216 * tracepoint.c: IPA-export gdb_collect_ptr instead of gdb_collect,
8217 ditto for get_raw_reg_ptr, get_trace_state_variable_value_ptr,
8218 set_trace_state_variable_value_ptr.
8219 (struct ipa_sym_addresses): Likewise.
8220 (symbol_list): Likewise.
8221 (install_fast_tracepoint): Dereference gdb_collect_ptr instead of
8222 accessing gdb_collect directly.
8223 (gdb_collect_ptr_type): New typedef.
8224 (get_raw_reg_ptr_type): New typedef.
8225 (get_trace_state_variable_value_ptr_type): New typedef.
8226 (set_trace_state_variable_value_ptr_type): New typedef.
8227 (gdb_collect_ptr): New global.
8228 (get_raw_reg_ptr): New global.
8229 (get_trace_state_variable_value_ptr): New global.
8230 (set_trace_state_variable_value_ptr): New global.
8231 (get_raw_reg_func_addr): Dereference get_raw_reg_ptr instead of
8232 accessing get_raw_reg directly.
8233 (get_get_tsv_func_addr): Likewise for
8234 get_trace_state_variable_value_ptr.
8235 (get_set_tsv_func_addr): Likewise for
8236 set_trace_state_variable_value_ptr.
8237 * tracepoint.h: Rename gdb_agent_get_raw_reg to get_raw_reg.
8239 2016-03-30 Simon Marchi <simon.marchi@ericsson.com>
8241 * tracepoint.c (cmd_qtenable_disable): Remove whitespace.
8243 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
8245 * remote-utils.c (look_up_one_symbol): Remove own_buf, handle 'v'
8247 (relocate_instruction): Remove own_buf.
8248 * server.c (own_buf): Make global.
8249 (handle_v_requests): Make global.
8250 * server.h (own_buf): New declaration.
8251 (handle_v_requests): New prototype.
8253 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
8256 * linux-s390-low.c (add_insns): New function.
8257 (s390_emit_prologue): New function.
8258 (s390_emit_epilogue): New function.
8259 (s390_emit_add): New function.
8260 (s390_emit_sub): New function.
8261 (s390_emit_mul): New function.
8262 (s390_emit_lsh): New function.
8263 (s390_emit_rsh_signed): New function.
8264 (s390_emit_rsh_unsigned): New function.
8265 (s390_emit_ext): New function.
8266 (s390_emit_log_not): New function.
8267 (s390_emit_bit_and): New function.
8268 (s390_emit_bit_or): New function.
8269 (s390_emit_bit_xor): New function.
8270 (s390_emit_bit_not): New function.
8271 (s390_emit_equal): New function.
8272 (s390_emit_less_signed): New function.
8273 (s390_emit_less_unsigned): New function.
8274 (s390_emit_ref): New function.
8275 (s390_emit_if_goto): New function.
8276 (s390_emit_goto): New function.
8277 (s390_write_goto_address): New function.
8278 (s390_emit_litpool): New function.
8279 (s390_emit_const): New function.
8280 (s390_emit_call): New function.
8281 (s390_emit_reg): New function.
8282 (s390_emit_pop): New function.
8283 (s390_emit_stack_flush): New function.
8284 (s390_emit_zero_ext): New function.
8285 (s390_emit_swap): New function.
8286 (s390_emit_stack_adjust): New function.
8287 (s390_emit_set_r2): New function.
8288 (s390_emit_int_call_1): New function.
8289 (s390_emit_void_call_2): New function.
8290 (s390_emit_eq_goto): New function.
8291 (s390_emit_ne_goto): New function.
8292 (s390_emit_lt_goto): New function.
8293 (s390_emit_le_goto): New function.
8294 (s390_emit_gt_goto): New function.
8295 (s390_emit_ge_goto): New function.
8296 (s390x_emit_prologue): New function.
8297 (s390x_emit_epilogue): New function.
8298 (s390x_emit_add): New function.
8299 (s390x_emit_sub): New function.
8300 (s390x_emit_mul): New function.
8301 (s390x_emit_lsh): New function.
8302 (s390x_emit_rsh_signed): New function.
8303 (s390x_emit_rsh_unsigned): New function.
8304 (s390x_emit_ext): New function.
8305 (s390x_emit_log_not): New function.
8306 (s390x_emit_bit_and): New function.
8307 (s390x_emit_bit_or): New function.
8308 (s390x_emit_bit_xor): New function.
8309 (s390x_emit_bit_not): New function.
8310 (s390x_emit_equal): New function.
8311 (s390x_emit_less_signed): New function.
8312 (s390x_emit_less_unsigned): New function.
8313 (s390x_emit_ref): New function.
8314 (s390x_emit_if_goto): New function.
8315 (s390x_emit_const): New function.
8316 (s390x_emit_call): New function.
8317 (s390x_emit_reg): New function.
8318 (s390x_emit_pop): New function.
8319 (s390x_emit_stack_flush): New function.
8320 (s390x_emit_zero_ext): New function.
8321 (s390x_emit_swap): New function.
8322 (s390x_emit_stack_adjust): New function.
8323 (s390x_emit_int_call_1): New function.
8324 (s390x_emit_void_call_2): New function.
8325 (s390x_emit_eq_goto): New function.
8326 (s390x_emit_ne_goto): New function.
8327 (s390x_emit_lt_goto): New function.
8328 (s390x_emit_le_goto): New function.
8329 (s390x_emit_gt_goto): New function.
8330 (s390x_emit_ge_goto): New function.
8331 (s390_emit_ops): New function.
8332 (struct linux_target_ops): Fill in emit_ops hook.
8334 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
8337 * Makefile.in: Add s390 IPA files.
8338 * configure.srv: Build IPA for s390.
8339 * linux-s390-ipa.c: New file.
8340 * linux-s390-low.c: New includes - inttypes.h and linux-s390-tdesc.h.
8341 (init_registers_s390_linux32): Move declaration to linux-s390-tdesc.h.
8342 (tdesc_s390_linux32): Likewise.
8343 (init_registers_s390_linux32v1): Likewise.
8344 (tdesc_s390_linux32v1): Likewise.
8345 (init_registers_s390_linux32v2): Likewise.
8346 (tdesc_s390_linux32v2): Likewise.
8347 (init_registers_s390_linux64): Likewise.
8348 (tdesc_s390_linux64): Likewise.
8349 (init_registers_s390_linux64v1): Likewise.
8350 (tdesc_s390_linux64v1): Likewise.
8351 (init_registers_s390_linux64v2): Likewise.
8352 (tdesc_s390_linux64v2): Likewise.
8353 (init_registers_s390_te_linux64): Likewise.
8354 (tdesc_s390_te_linux64): Likewise.
8355 (init_registers_s390_vx_linux64): Likewise.
8356 (tdesc_s390_vx_linux64): Likewise.
8357 (init_registers_s390_tevx_linux64): Likewise.
8358 (tdesc_s390_tevx_linux64): Likewise.
8359 (init_registers_s390x_linux64): Likewise.
8360 (tdesc_s390x_linux64): Likewise.
8361 (init_registers_s390x_linux64v1): Likewise.
8362 (tdesc_s390x_linux64v1): Likewise.
8363 (init_registers_s390x_linux64v2): Likewise.
8364 (tdesc_s390x_linux64v2): Likewise.
8365 (init_registers_s390x_te_linux64): Likewise.
8366 (tdesc_s390x_te_linux64): Likewise.
8367 (init_registers_s390x_vx_linux64): Likewise.
8368 (tdesc_s390x_vx_linux64): Likewise.
8369 (init_registers_s390x_tevx_linux64): Likewise.
8370 (tdesc_s390x_tevx_linux64): Likewise.
8371 (have_hwcap_s390_vx): New static variable.
8372 (s390_arch_setup): Fill have_hwcap_s390_vx.
8373 (s390_get_thread_area): New function.
8374 (s390_ft_entry_gpr_esa): New const.
8375 (s390_ft_entry_gpr_zarch): New const.
8376 (s390_ft_entry_misc): New const.
8377 (s390_ft_entry_fr): New const.
8378 (s390_ft_entry_vr): New const.
8379 (s390_ft_main_31): New const.
8380 (s390_ft_main_64): New const.
8381 (s390_ft_exit_fr): New const.
8382 (s390_ft_exit_vr): New const.
8383 (s390_ft_exit_misc): New const.
8384 (s390_ft_exit_gpr_esa): New const.
8385 (s390_ft_exit_gpr_zarch): New const.
8386 (append_insns): New function.
8387 (s390_relocate_instruction): New function.
8388 (s390_install_fast_tracepoint_jump_pad): New function.
8389 (s390_get_min_fast_tracepoint_insn_len): New function.
8390 (s390_get_ipa_tdesc_idx): New function.
8391 (struct linux_target_ops): Wire in the above functions.
8392 (initialize_low_arch) [!__s390x__]: Don't initialize s390x tdescs.
8393 * linux-s390-tdesc.h: New file.
8395 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
8397 * linux-s390-low.c (s390_supports_tracepoints): New function.
8398 (struct linux_target_ops): Fill supports_tracepoints hook.
8400 2016-03-18 Yao Qi <yao.qi@linaro.org>
8402 * linux-low.c (lwp_signal_can_be_delivered): New function.
8403 (linux_resume_one_lwp_throw): Use lwp_signal_can_be_delivered.
8405 2016-03-18 Yao Qi <yao.qi@linaro.org>
8407 * linux-low.c (linux_resume_one_lwp_throw): Set 'signal' to
8408 0 if signal is enqueued. Remove 'signal' from one debugging
8409 message. Move one debugging message to some lines below.
8410 Remove code setting 'signal' to 0.
8412 2016-03-18 Yao Qi <yao.qi@linaro.org>
8414 * linux-low.c (linux_low_filter_event): Remove redundant
8415 WIFSTOPPED check together with linux_wstatus_maybe_breakpoint.
8417 2016-03-09 Marcin Kościelnicki <koriakin@0x04.net>
8419 * linux-ppc-low.c (ppc_supports_tracepoints): New function.
8420 (struct linux_target_ops): Wire in the above.
8422 2016-03-03 Yao Qi <yao.qi@linaro.org>
8424 * linux-low.c: Update comments to start_step_over.
8426 2016-03-03 Yao Qi <yao.qi@linaro.org>
8429 * linux-low.c (handle_extended_wait): Set child suspended
8430 if event_lwp->bp_reinsert isn't zero.
8432 2016-03-02 Yao Qi <yao.qi@linaro.org>
8434 * linux-low.c (linux_resume_one_lwp_throw): Replace code with
8435 enqueue_pending_signal.
8437 2016-03-02 Marcin Kościelnicki <koriakin@0x04.net>
8439 * tracepoint.c (cmd_qtstart): Only set ipa_tdesc_idx if agent
8442 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
8444 * linux-s390-low.c (s390_num_regs_3264): Define on 31-bit too.
8445 (s390_regmap_3264) [!__s390x__]: New global.
8446 (s390_collect_ptrace_register): Skip map entries containing -1.
8447 (s390_supply_ptrace_register): Ditto.
8448 (s390_fill_gprs_high): New function.
8449 (s390_store_gprs_high): New function.
8450 (s390_regsets): Add NT_S390_HIGH_GPRS.
8451 (s390_get_hwcap): Enable on 31-bit.
8452 (have_hwcap_s390_high_gprs): Enable on 31-bit.
8453 (s390_arch_setup): Enable detection of high GPRs, TDB, VX on 31-bit.
8454 Detect NT_S390_HIGH_GPRS.
8455 (s390_usrregs_info_3264): Enable on 31-bit.
8456 (s390_regs_info): Enable regs_info_3264 on 31-bit.
8457 (initialize_low_arch): Initialize s390_regsets_info_3264 on 31-bit.
8459 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
8462 * Makefile.in: Add i386-*-linux-ipa.o and amd64-*-linux-ipa.o.
8463 * configure.srv: Ditto.
8464 * linux-aarch64-ipa.c (get_ipa_tdesc): New function.
8465 (initialize_low_tracepoint): Remove ipa_tdesc assignment.
8466 * linux-amd64-ipa.c: Add "linux-x86-tdesc.h" include.
8467 (init_registers_amd64_linux): Remove prototype.
8468 (tdesc_amd64_linux): Remove declaration.
8469 (get_ipa_tdesc): New function.
8470 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
8471 initialize remaining tdescs.
8472 * linux-i386-ipa.c: Add "linux-x86-tdesc.h" include.
8473 (init_registers_i386_linux): Remove prototype.
8474 (tdesc_i386_linux): Remove declaration.
8475 (get_ipa_tdesc): New function.
8476 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
8477 initialize remaining tdescs.
8478 * linux-low.c (linux_get_ipa_tdesc_idx): New function.
8479 (linux_target_ops): wire in linux_get_ipa_tdesc_idx.
8480 * linux-low.h (struct linux_target_ops): Add get_ipa_tdesc_idx.
8481 * linux-x86-low.c: Move tdesc declarations to linux-x86-tdesc.h.
8482 (x86_get_ipa_tdesc_idx): New function.
8483 (the_low_target): Wire in x86_get_ipa_tdesc_idx.
8484 * linux-x86-tdesc.h: New file.
8485 * target.h (struct target_ops): Add get_ipa_tdesc_idx.
8486 (target_get_ipa_tdesc_idx): New macro.
8487 * tracepoint.c (ipa_tdesc_idx): New macro.
8488 (struct ipa_sym_addresses): Add addr_ipa_tdesc_idx.
8489 (symbol_list): Add ipa_tdesc_idx.
8490 (cmd_qtstart): Write ipa_tdesc_idx in the target.
8491 (ipa_tdesc): Remove.
8492 (ipa_tdesc_idx): New variable.
8493 (get_context_regcache): Use get_ipa_tdesc.
8494 (gdb_collect): Ditto.
8496 * tracepoint.h (get_ipa_tdesc): New prototype.
8497 (ipa_tdesc): Remove.
8499 2016-02-24 Pedro Alves <palves@redhat.com>
8501 * linux-low.c (check_stopped_by_breakpoint): Rename to ...
8502 (save_stop_reason): ... this. Use GDB_ARCH_IS_TRAP_HWBKPT and
8503 handle ambiguous GDB_ARCH_IS_TRAP_BRKPT / GDB_ARCH_IS_TRAP_HWBKPT.
8504 Factor out common code between the USE_SIGTRAP_SIGINFO and
8505 !USE_SIGTRAP_SIGINFO blocks.
8506 (linux_low_filter_event): Call save_stop_reason instead of
8507 check_stopped_by_breakpoint and check_stopped_by_watchpoint.
8509 (linux_wait_1): Update comments.
8511 2016-02-24 Wei-cheng Wang <cole945@gmail.com>
8513 * linux-ppc-low.c (ppc_supports_z_point_type): New function:
8514 (ppc_insert_point, ppc_remove_point): Insert/remove z-packet breakpoints.
8515 (ppc64_emit_ops_vector): Add target ops - ppc_supports_z_point_type,
8516 ppc_insert_point, ppc_remove_point.
8518 2016-02-17 Marcin Kościelnicki <koriakin@0x04.net>
8520 * linux-s390-low.c (s390_supports_z_point_type): New function.
8521 (struct linux_target_ops): Wire s390_supports_z_point_type in.
8523 2016-02-16 Yao Qi <yao.qi@linaro.org>
8525 * linux-arm-low.c (get_next_pcs_syscall_next_pc): Remove argument
8526 PC. Get pc from regcache_read_pc.
8528 2016-02-12 Yao Qi <yao.qi@linaro.org>
8530 * linux-aarch64-low.c (aarch64_get_pc): Call linux_get_pc_64bit
8531 or linux_get_pc_32bit.
8532 (aarch64_set_pc): Call linux_set_pc_64bit or linux_set_pc_32bit.
8534 2016-02-12 Yao Qi <yao.qi@linaro.org>
8536 * linux-arm-low.c (get_next_pcs_ops): Initialize it with
8537 arm_linux_get_next_pcs_fixup.
8539 2016-02-12 Marcin Kościelnicki <koriakin@0x04.net>
8541 * tracepoint.c (x_tracepoint_action_download): Change
8542 write_inferior_data_ptr to write_inferior_data_pointer.
8543 (cmd_qtstart): Likewise.
8544 (write_inferior_data_ptr): Remove.
8545 (download_agent_expr): Change write_inferior_data_ptr to
8546 write_inferior_data_pointer.
8547 (download_tracepoint_1): Likewise.
8548 (download_tracepoint): Likewise.
8549 (download_trace_state_variables): Likewise.
8551 2016-02-11 Wei-cheng Wang <cole945@gmail.com>
8552 Marcin Kościelnicki <koriakin@0x04.net>
8554 * tracepoint.c (struct tracepoint_action_ops): Remove.
8555 (struct tracepoint_action): Remove ops.
8556 (m_tracepoint_action_download, r_tracepoint_action_download)
8557 (x_tracepoint_action_download, l_tracepoint_action_download): Adjust
8558 size and offset accordingly.
8559 (m_tracepoint_action_ops, r_tracepoint_action_ops)
8560 (x_tracepoint_action_ops, l_tracepoint_action_ops): Remove.
8561 (tracepoint_action_send, tracepoint_action_download): New functions.
8562 Helpers for trace action handlers.
8563 (add_tracepoint_action): Remove setup actions ops.
8564 (download_tracepoint_1, tracepoint_send_agent): Call helper functions.
8566 2016-02-10 Yao Qi <yao.qi@linaro.org>
8568 * regcache.c (regcache_raw_read_unsigned): Clear *VAL.
8570 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
8572 * configure.ac: Use AC_CONFIG_FILES instead of passing arguments
8574 * configure: Regenerate.
8576 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
8578 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): Change
8579 void * to gdb_byte *.
8580 * linux-low.c (siginfo_fixup): Likewise.
8581 (linux_xfer_siginfo): Likewise.
8582 * linux-low.h (struct linux_target_ops) <siginfo_fixup>:
8584 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
8586 2016-02-02 Walfred Tedeschi <walfred.tedeschi@intel.com>
8588 * configure.srv (x86_64-*-linux*): Add amd64-linux-siginfo.o
8590 (i[34567]86-*-linux*): Add amd64-linux-siginfo.o
8592 * linux-x86-low.c [__x86_64__]: Include
8593 "nat/amd64-linux-siginfo.h".
8594 (compat_siginfo_from_siginfo, siginfo_from_compat_siginfo)
8595 (compat_x32_siginfo_from_siginfo, siginfo_from_compat_x32_siginfo)
8596 (compat_timeval, compat_sigval, compat_x32_clock, cpt_si_pid)
8597 (cpt_si_uid, cpt_si_timerid, cpt_si_overrun, cpt_si_status)
8598 (cpt_si_utime, cpt_si_stime, cpt_si_ptr, cpt_si_addr, cpt_si_band)
8599 (cpt_si_fd, si_timerid, si_overrun): Move from
8600 nat/amd64-linux-siginfo.c.
8601 * Makefile.in (amd64-linux-siginfo.o:): New rule.
8603 2016-01-28 Simon Marchi <simon.marchi@ericsson.com>
8605 * server.c (skip_to_semicolon): Remove.
8606 (process_point_options): Use strchrnul instead of
8609 2016-01-26 Yao Qi <yao.qi@linaro.org>
8611 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Remove argument pc.
8612 * linux-low.c (install_software_single_step_breakpoints): Don't
8613 call regcache_read_pc.
8614 * linux-low.h (struct linux_target_ops) <get_next_pcs>: Remove
8617 2016-01-26 Yao Qi <yao.qi@linaro.org>
8619 * linux-low.c (install_software_single_step_breakpoints): Call
8620 regcache_read_pc instead of get_pc.
8622 2016-01-26 Yao Qi <yao.qi@linaro.org>
8624 * remote-utils.c (remote_close) [!USE_WIN32API]: Ignore SIGIO.
8625 (unblock_async_io): Rename to ...
8626 (block_unblock_async_io): ... it. New function.
8627 (enable_async_io): Don't install SIGIO handler. Unblock it
8629 (disable_async_io): Don't ignore SIGIO. Block it instead.
8630 (initialize_async_io): Install SIGIO handler. Don't call
8633 2016-01-26 Yao Qi <yao.qi@linaro.org>
8635 * remote-utils.c (getpkt): If the buffer isn't empty, and the
8636 first character is '\003', call *the_target->request_interrupt.
8638 2016-01-25 Yao Qi <yao.qi@linaro.org>
8640 * remote-utils.c (new_thread_notify): Remove.
8641 (dead_thread_notify): Likewise.
8642 * remote-utils.h (new_thread_notify): Remove declaration.
8643 (dead_thread_notify): Likewise.
8645 2016-01-23 Marcin Kościelnicki <koriakin@0x04.net>
8647 * gdb.trace/pending.exp: Fix expected message on continue.
8649 2016-01-22 Marcin Kościelnicki <koriakin@0x04.net>
8651 * tracepoint.c (write_inferior_data_ptr): Cast to uintptr_t, so that
8652 it works properly on big-endian machines where sizeof (CORE_ADDR)
8655 2016-01-21 Pedro Alves <palves@redhat.com>
8657 * Makefile.in (COMPILER_CFLAGS, CXXFLAGS): New.
8658 (INTERNAL_CFLAGS_BASE): Use COMPILER_CFLAGS instead of CFLAGS.
8659 * configure: Regenerate.
8661 2016-01-21 Yao Qi <yao.qi@linaro.org>
8663 * linux-arm-low.c (arm_sigreturn_next_pc): Add parameter
8664 is_thumb and set it according to CPSR saved on the stack.
8665 (get_next_pcs_syscall_next_pc): Pass is_thumb to
8666 arm_sigreturn_next_pc.
8668 2016-01-18 Yao Qi <yao.qi@linaro.org>
8670 * linux-low.c (linux_set_pc_64bit): New function.
8671 (linux_get_pc_64bit): New function.
8672 * linux-low.h (linux_set_pc_64bit, linux_get_pc_64bit):
8674 * linux-sparc-low.c (debug_threads): Remove declaration.
8675 (sparc_get_pc): Remove.
8676 (the_low_target): Use linux_get_pc_64bit instead of
8678 * linux-tile-low.c (tile_get_pc, tile_set_pc): Remove.
8679 (the_low_target): Use linux_get_pc_64bit and
8682 2016-01-18 Yao Qi <yao.qi@linaro.org>
8684 * linux-arm-low.c (debug_threads): Remove declaration.
8685 (arm_get_pc, arm_set_pc): Remove.
8686 (the_low_target): Use linux_get_pc_32bit and
8688 * linux-bfin-low.c (bfin_get_pc, bfin_set_pc): Remove.
8689 (the_low_target): Use linux_get_pc_32bit and
8691 * linux-cris-low.c (debug_threads): Remove declaration.
8692 (cris_get_pc, cris_set_pc,): Remove.
8693 (the_low_target): Use linux_get_pc_32bit and
8695 * linux-crisv32-low.c (debug_threads): Remove declaration.
8696 (cris_get_pc, cris_set_pc): Remove.
8697 (the_low_target): Use linux_get_pc_32bit and
8699 * linux-low.c: Include inttypes.h.
8700 (linux_get_pc_32bit, linux_set_pc_32bit): New functions.
8701 * linux-low.h (linux_get_pc_32bit, linux_set_pc_32bit): Declare.
8702 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Remove.
8703 (the_low_target): Use linux_get_pc_32bit and
8705 * linux-m68k-low.c (m68k_get_pc, m68k_set_pc): Remove.
8706 (the_low_target): Use linux_get_pc_32bit and
8708 * linux-nios2-low.c (nios2_get_pc, nios2_set_pc): Remove.
8709 (the_low_target): Use linux_get_pc_32bit and
8711 * linux-sh-low.c (sh_get_pc, sh_set_pc): Remove.
8712 (the_low_target): Use linux_get_pc_32bit and
8714 * linux-xtensa-low.c (xtensa_get_pc, xtensa_set_pc): Remove.
8715 (the_low_target): Use linux_get_pc_32bit and
8718 2016-01-18 Gary Benson <gbenson@redhat.com>
8720 * configure.ac (AC_FUNC_FORK): New check.
8721 * config.in: Regenerate.
8722 * configure: Likewise.
8724 2016-01-14 Yao Qi <yao.qi@linaro.org>
8726 * linux-aarch32-low.c (thumb2_breakpoint): Make it static.
8727 * linux-aarch32-low.h (thumb2_breakpoint): Remove declaration.
8728 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Pass 1 to
8729 arm_get_next_pcs_ctor.
8731 2016-01-12 Josh Stone <jistone@redhat.com>
8732 Philippe Waroquiers <philippe.waroquiers@skynet.be>
8734 * inferiors.h: Include "gdb_vecs.h".
8735 (struct process_info): Add syscalls_to_catch.
8736 * inferiors.c (remove_process): Free syscalls_to_catch.
8737 * remote-utils.c (prepare_resume_reply): Report syscall_entry and
8738 syscall_return stops.
8739 * server.h (UNKNOWN_SYSCALL, ANY_SYSCALL): Define.
8740 * server.c (handle_general_set): Handle QCatchSyscalls.
8741 (handle_query): Report support for QCatchSyscalls.
8742 * target.h (struct target_ops): Add supports_catch_syscall.
8743 (target_supports_catch_syscall): New macro.
8744 * linux-low.h (struct linux_target_ops): Add get_syscall_trapinfo.
8745 (struct lwp_info): Add syscall_state.
8746 * linux-low.c (handle_extended_wait): Mark syscall_state as an entry.
8747 Maintain syscall_state and syscalls_to_catch across exec.
8748 (get_syscall_trapinfo): New function, proxy to the_low_target.
8749 (linux_low_ptrace_options): Enable PTRACE_O_TRACESYSGOOD.
8750 (linux_low_filter_event): Toggle syscall_state entry/return for
8751 syscall traps, and set it ignored for all others.
8752 (gdb_catching_syscalls_p): New function.
8753 (gdb_catch_this_syscall_p): New function.
8754 (linux_wait_1): Handle SYSCALL_SIGTRAP.
8755 (linux_resume_one_lwp_throw): Add PTRACE_SYSCALL possibility.
8756 (linux_supports_catch_syscall): New function.
8757 (linux_target_ops): Install it.
8758 * linux-x86-low.c (x86_get_syscall_trapinfo): New function.
8759 (the_low_target): Install it.
8761 2016-01-12 Mike Frysinger <vapier@gentoo.org>
8763 * acinclude.m4: Include new ../warning.m4 file.
8764 * configure: Regenerated.
8765 * configure.ac: Replace all warning logic with AM_GDB_WARNINGS.
8767 2016-01-12 Mike Frysinger <vapier@gentoo.org>
8769 * ax.c (is_goto_target): Mark static.
8770 * linux-low.c (register_addr): Likewise.
8771 (linux_fetch_registers, linux_store_registers): Likewise.
8772 * mem-break.c (any_persistent_commands): Fix old prototype.
8773 (add_commands_to_breakpoint): Mark static.
8774 * regcache.c (find_register_by_name): Delete unused func.
8775 * remote-utils.c (hex_or_minus_one): Mark static.
8776 * server.c (monitor_show_help): Mark static.
8777 (handle_query, handle_v_cont, handle_v_attach, handle_v_kill,
8778 handle_v_requests): Likewise.
8780 2016-01-12 Pedro Alves <palves@redhat.com>
8782 Remove use of the registered trademark symbol throughout.
8784 2016-01-08 Yao Qi <yao.qi@linaro.org>
8786 * remote-utils.c (getpkt): If c is '\003', call target hook
8789 2016-01-06 Yao Qi <yao.qi@linaro.org>
8791 * linux-aarch32-low.h (arm_abi_breakpoint): Move to
8792 linux-aarch32-low.c.
8793 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
8794 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
8795 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
8796 (thumb2_breakpoint): Declare.
8797 * linux-aarch32-low.c (arm_abi_breakpoint): Moved from
8798 linux-aarch32-low.h.
8799 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
8800 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
8801 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
8803 2016-01-01 Joel Brobecker <brobecker@adacore.com>
8805 * gdbreplay.c (gdbreplay_version): Change copyright year in
8807 * server.c (gdbserver_version): Likewise.
8809 2015-12-28 Patrick Palka <patrick@parcs.ath.cx>
8811 * server.c (crc32_table): Delete.
8812 (crc32): Use libiberty's xcrc32 function.
8814 2015-12-22 Joel Brobecker <brobecker@adacore.com>
8816 * lynx-low.c (lynx_delete_thread_callback): New function.
8817 (lynx_mourn): Properly delete our process and all of its
8818 threads. Remove call to clear_inferiors.
8820 2015-12-22 Joel Brobecker <brobecker@adacore.com>
8822 * target.c (thread_search_callback): Add check that
8823 the thread_stopped target callback is not NULL before
8826 2015-12-21 Yao Qi <yao.qi@linaro.org>
8828 * linux-aarch32-low.h [__aarch64__]: Use arm_abi_breakpoint
8831 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
8833 * server.c (handle_query): Call target_supports_software_single_step.
8835 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
8837 * linux-low.c (single_step): New function.
8838 (linux_resume_one_lwp_throw): Call single_step.
8839 (start_step_over): Likewise.
8841 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
8843 * Makefile.in (SFILES): Append arch/arm-linux.c,
8844 arch/arm-get-next-pcs.c.
8845 (arm-linux.o): New rule.
8846 (arm-get-next-pcs.o): New rule.
8847 * configure.srv (arm*-*-linux*): Add arm-get-next-pcs.o,
8849 * linux-aarch32-low.c (arm_abi_breakpoint): Remove macro. Moved
8850 to linux-aarch32-low.c.
8851 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
8852 (arm_breakpoint_len, thumb_breakpoint): Likewise.
8853 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
8854 (thumb2_breakpoint_len): Likewise.
8855 (arm_is_thumb_mode): Make non-static.
8856 * linux-aarch32-low.h (arm_abi_breakpoint): New macro. Moved
8857 from linux-aarch32-low.c.
8858 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
8859 (arm_breakpoint_len, thumb_breakpoint): Likewise.
8860 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
8861 (thumb2_breakpoint_len): Likewise.
8862 (arm_is_thumb_mode): New declaration.
8863 * linux-arm-low.c: Include arch/arm-linux.h
8864 aarch/arm-get-next-pcs.h, sys/syscall.h.
8865 (get_next_pcs_ops): New struct.
8866 (get_next_pcs_addr_bits_remove): New function.
8867 (get_next_pcs_is_thumb): New function.
8868 (get_next_pcs_read_memory_unsigned_integer): Likewise.
8869 (arm_sigreturn_next_pc): Likewise.
8870 (get_next_pcs_syscall_next_pc): Likewise.
8871 (arm_gdbserver_get_next_pcs): Likewise.
8872 (struct linux_target_ops) <arm_gdbserver_get_next_pcs>:
8874 * linux-low.h: Move CORE_ADDR vector definition to gdb_vecs.h.
8875 * server.h: Include gdb_vecs.h.
8877 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
8879 * Makefile.in (SFILES): Append common/common-regcache.c.
8880 (OBS): Append common-regcache.o.
8881 (common-regcache.o): New rule.
8882 * regcache.c (init_register_cache): Initialize cache to
8884 (regcache_raw_read_unsigned): New function.
8885 * regcache.h (REG_UNAVAILABLE, REG_VALID): Replaced by shared
8886 register_status enum.
8888 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
8890 * linux-aarch64-low.c (the_low_targets): Rename
8891 breakpoint_reinsert_addr to get_next_pcs.
8892 * linux-arm-low.c (the_low_targets): Likewise.
8893 * linux-bfin-low.c (the_low_targets): Likewise.
8894 * linux-cris-low.c (the_low_targets): Likewise.
8895 * linux-crisv32-low.c (the_low_targets): Likewise.
8896 * linux-low.c (can_software_single_step): Likewise.
8897 (install_software_single_step_breakpoints): New function.
8898 (start_step_over): Use install_software_single_step_breakpoints.
8899 * linux-low.h: New CORE_ADDR vector.
8900 (struct linux_target_ops) Rename breakpoint_reinsert_addr to
8902 * linux-mips-low.c (the_low_targets): Likewise.
8903 * linux-nios2-low.c (the_low_targets): Likewise.
8904 * linux-sparc-low.c (the_low_targets): Likewise.
8906 2015-12-17 Pedro Alves <palves@redhat.com>
8908 * linux-low.c (linux_kill_one_lwp): Remove references to
8910 (kill_lwp): Remove HAVE_TKILL_SYSCALL check. No longer fall back
8912 (linux_init_signals): Delete.
8913 (initialize_low): Adjust.
8914 * thread-db.c (thread_db_init): Remove LinuxThreads reference.
8916 2015-12-16 Pedro Alves <palves@redhat.com>
8918 * configure.ac (compiler warning flags): When testing a
8919 -Wno-foo option, check whether -Wfoo works instead.
8920 * configure: Regenerate.
8922 2015-12-11 Don Breazeal <donb@codesourcery.com>
8924 * server.c (process_serial_event): Don't exit from gdbserver
8925 in remote mode if there are still active inferiors.
8927 2015-12-11 Yao Qi <yao.qi@linaro.org>
8929 * linux-aarch64-low.c (aarch64_breakpoint_at): Call
8930 arm_breakpoint_at if the process is 32-bit.
8932 2015-12-11 Yao Qi <yao.qi@linaro.org>
8934 * linux-aarch32-low.c [__aarch64__]: Use arm_abi_breakpoint
8937 2015-12-07 Yao Qi <yao.qi@linaro.org>
8939 * configure.srv: Append arm.o to srv_tgtobj for
8940 aarch64*-*-linux* target.
8941 * linux-aarch32-low.c (arm_abi_breakpoint): New macro. Moved
8942 from linux-arm-low.c.
8943 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
8944 (arm_breakpoint_len, thumb_breakpoint): Likewise.
8945 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
8946 (thumb2_breakpoint_len): Likewise.
8947 (arm_is_thumb_mode, arm_breakpoint_at): Likewise.
8948 (arm_breakpoint_kinds): Likewise.
8949 (arm_breakpoint_kind_from_pc): Likewise.
8950 (arm_sw_breakpoint_from_kind): Likewise.
8951 (arm_breakpoint_kind_from_current_state): Likewise.
8952 * linux-aarch32-low.h (arm_breakpoint_kind_from_pc): Declare.
8953 (arm_sw_breakpoint_from_kind): Declare.
8954 (arm_breakpoint_kind_from_current_state): Declare.
8955 (arm_breakpoint_at): Declare.
8956 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): Call
8957 arm_sw_breakpoint_from_kind if process is 32-bit.
8958 (aarch64_breakpoint_kind_from_pc): New function.
8959 (aarch64_breakpoint_kind_from_current_state): New function.
8960 (the_low_target): Initialize fields breakpoint_kind_from_pc
8961 and breakpoint_kind_from_current_state.
8962 * linux-arm-low.c (arm_breakpoint_kinds): Move to
8963 linux-aarch32-low.c.
8964 (arm_abi_breakpoint, arm_eabi_breakpoint): Likewise.
8965 (arm_breakpoint, arm_breakpoint_len): Likewise.
8966 (thumb_breakpoint, thumb_breakpoint_len): Likewise.
8967 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
8968 (arm_is_thumb_mode): Likewise.
8969 (arm_breakpoint_at): Likewise.
8970 (arm_breakpoint_kind_from_pc): Likewise.
8971 (arm_sw_breakpoint_from_kind): Likewise.
8972 (arm_breakpoint_kind_from_current_state): Likewise.
8975 2015-08-04 Yao Qi <yao.qi@linaro.org>
8977 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
8978 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
8979 * server.c (extended_protocol): Remove "static".
8980 * server.h (extended_protocol): Declare it.
8982 2015-12-04 Josh Stone <jistone@redhat.com>
8984 * target.h (struct target_ops) <arch_setup>: Rename to ...
8985 (struct target_ops) <post_create_inferior>: ... this.
8986 (target_arch_setup): Rename to ...
8987 (target_post_create_inferior): ... this, calling post_create_inferior.
8988 * server.c (start_inferior): Update target_arch_setup calls to
8989 target_post_create_inferior.
8990 * linux-low.c (linux_low_ptrace_options): Forward declare.
8991 (linux_arch_setup): Update its comment for general use.
8992 (linux_post_create_inferior): New, run arch_setup and setup ptrace.
8993 (struct linux_target_ops): Use linux_post_create_inferior.
8994 * lynx-low.c (struct lynx_target_ops): Update arch_setup stub comment
8995 to post_create_inferior.
8996 * nto-low.c (struct nto_target_ops): Likewise.
8997 * spu-low.c (struct spu_target_ops): Likewise.
8998 * win32-low.c (struct win32_target_ops): Likewise.
9000 2015-12-03 Antoine Tremblay <antoine.tremblay@ericsson.com>
9002 * linux-arm-low.c: Remove duplicate arch/arm.h include.
9004 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
9006 * linux-arm-low.c (arm_reinsert_addr): Remove function.
9007 (struct linux_target_ops <breakpoint_reinsert_addr>: Set to NULL.
9008 * linux-cris-low.c (cris_reinsert_addr> Remove function.
9009 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
9010 * linux-crisv32-low.c (cris_reinsert_addr): Remove function.
9011 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
9012 * linux-mips-low.c (mips_reinsert_addr): Remove function.
9013 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
9014 * linux-nios2-low.c (nios2_reinsert_addr): Remove function.
9015 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
9016 * linux-sparc-low.c (sparc_reinsert_addr): Remove function.
9017 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
9019 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
9021 * linux-low.c (linux_look_up_symbols): Don't call
9022 linux_supports_traceclone.
9023 * linux-low.h (thread_db_init): Remove use_events argument.
9024 * thread-db.c (thread_db_use_event): Remove global variable.
9025 (struct thread_db) <td_thr_event_enable_p>: Remove field.
9026 (struct thread_db) <td_create_bp>: Remove field.
9027 (thread_db_create_event): Remove function.
9028 (thread_db_enable_reporting): Likewise.
9029 (find_one_thread): Don't check for thread_db_use_events.
9030 (attach_thread): Likewise.
9031 (thread_db_load_search): Remove td_thr_event_enable_p initialization.
9032 (try_thread_db_load_1): Don't check for thread_db_use_events.
9033 (thread_db_init): Remove use_events argument and thread events
9035 (remove_thread_event_breakpoints): Remove function.
9036 (thread_db_detach): Remove call to remove_thred_event_breakpoints.
9038 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
9040 * linux-aarch64-low.c (aarch64_supports_hardware_single_step):
9042 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9043 * linux-arm-low.c (arm_supports_hardware_single_step): New function.
9044 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9045 * linux-bfin-low.c (bfin_supports_hardware_single_step): New function.
9046 (struct linux_target_ops) <bfin_supports_hardware_single_step>:
9048 * linux-crisv32-low.c (cris_supports_hardware_single_step):
9050 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9051 * linux-low.c (can_hardware_single_step): Use
9052 supports_hardware_single_step.
9053 (can_software_single_step): New function.
9054 (start_step_over): Call can_software_single_step.
9055 (linux_supports_hardware_single_step): New function.
9056 (struct target_ops) <supports_software_single_step>: Initialize.
9057 * linux-low.h (struct linux_target_ops)
9058 <supports_hardware_single_step>: Initialize.
9059 * linux-m32r-low.c (m32r_supports_hardware_single_step): New function.
9060 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9061 * linux-ppc-low.c (ppc_supports_hardware_single_step): New function.
9062 (struct linux_target_ops) <supports_hardware_single_step> Initialize.
9063 * linux-s390-low.c (s390_supports_hardware_single_step): New function.
9064 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9065 * linux-sh-low.c (sh_supports_hardware_single_step): New function.
9066 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9067 * linux-tic6x-low.c (tic6x_supports_hardware_single_step): New function.
9068 (struct linux_target_ops) <tic6x_supports_hardware_single_step>:
9070 * linux-tile-low.c (tile_supports_hardware_single_step): New function.
9071 (struct linux_target_ops) <tile_supports_hardware_single_step>:
9073 * linux-x86-low.c (x86_supports_hardware_single_step) New function.
9074 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9075 * linux-xtensa-low.c (xtensa_supports_hardware_single_step):
9077 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9078 * target.h (struct target_ops): <supports_software_single_step>:
9080 (target_supports_software_single_step): New macro.
9082 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
9084 * linux-low.c (linux_wait_1): Fix pc advance condition.
9085 * mem-break.c (reinsert_breakpoint_inserted_here): New function.
9086 * mem-break.h (reinsert_breakpoint_inserted_here): New declaration.
9088 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
9090 * linux-arm-low.c (arm_is_thumb_mode): New function.
9091 (arm_breakpoint_at): Use arm_is_thumb_mode.
9092 (arm_breakpoint_kind_from_current_state): New function.
9093 (struct linux_target_ops) <breakpoint_kind_from_current_state>:
9095 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_current_state.
9096 (linux_breakpoint_kind_from_current_state): New function.
9097 (struct target_ops <breakpoint_kind_from_current_state>: Initialize.
9098 * linux-low.h (struct linux_target_ops)
9099 <breakpoint_kind_from_current_state>: New field.
9100 * target.h (struct target_ops): Likewise.
9101 (target_breakpoint_kind_from_current_state): New macro.
9103 2015-11-30 Pedro Alves <palves@redhat.com>
9105 * linux-low.c (linux_resume): Wake up the event loop before
9108 2015-11-30 Pedro Alves <palves@redhat.com>
9110 * mem-break.c (check_gdb_bp_preconditions): Remove current_thread
9112 (set_gdb_breakpoint): If prepare_to_access_memory fails, set *ERR
9114 * target.c (struct thread_search): New structure.
9115 (thread_search_callback): New function.
9116 (prev_general_thread): New global.
9117 (prepare_to_access_memory, done_accessing_memory): New functions.
9118 * target.h (prepare_to_access_memory, done_accessing_memory):
9119 Replace macros with function declarations.
9121 2015-11-30 Pedro Alves <palves@redhat.com>
9124 * linux-low.c (linux_wait_1): If the last resumed thread is gone,
9125 report TARGET_WAITKIND_NO_RESUMED.
9126 * remote-utils.c (prepare_resume_reply): Handle
9127 TARGET_WAITKIND_NO_RESUMED.
9128 * server.c (report_no_resumed): New global.
9129 (handle_query) <qSupported>: Handle "no-resumed+". Report
9130 "no-resumed+" support.
9131 (resume): When the target reports TARGET_WAITKIND_NO_RESUMED, only
9132 return error if the client doesn't support no-resumed events.
9133 (push_stop_notification): New function.
9134 (handle_target_event): Use it. Report TARGET_WAITKIND_NO_RESUMED
9135 events if the client supports them.
9137 2015-11-30 Pedro Alves <palves@redhat.com>
9139 * linux-low.c (thread_still_has_status_pending_p): Don't check
9141 (lwp_resumed): New function.
9142 (status_pending_p_callback): Return early if the LWP is not
9143 supposed to be resumed.
9145 2015-11-30 Pedro Alves <palves@redhat.com>
9147 * linux-low.c (handle_extended_wait): Assert that the LWP's
9148 waitstatus is TARGET_WAITKIND_IGNORE. If GDB wants to hear about
9149 thread create events, leave the new child's status pending.
9150 (linux_low_filter_event): If GDB wants to hear about thread exit
9151 events, leave the LWP marked dead and don't delete it.
9152 (linux_wait_for_event_filtered): Don't check for thread exit.
9153 (filter_exit_event): New function.
9154 (linux_wait_1): Use it, when returning an exit event.
9155 (linux_resume_one_lwp_throw): Assert that the LWP's
9156 waitstatus is TARGET_WAITKIND_IGNORE.
9157 * remote-utils.c (prepare_resume_reply): Handle
9158 TARGET_WAITKIND_THREAD_CREATED and TARGET_WAITKIND_THREAD_EXITED.
9159 * server.c (report_thread_events): New global.
9160 (handle_general_set): Handle QThreadEvents.
9161 (handle_query) <qSupported>: Handle and report QThreadEvents+;
9162 (handle_target_event): Handle TARGET_WAITKIND_THREAD_CREATED and
9163 TARGET_WAITKIND_THREAD_EXITED.
9164 * server.h (report_thread_events): Declare.
9166 2015-11-30 Pedro Alves <palves@redhat.com>
9168 * linux-low.c (resume_stopped_resumed_lwps): Don't check whether
9169 the thread's last_resume_kind was resume_stop.
9171 2015-11-30 Pedro Alves <palves@redhat.com>
9173 * linux-low.c (linux_attach): In non-stop mode, wait for one stop
9176 2015-11-30 Pedro Alves <palves@redhat.com>
9178 * server.c (handle_v_requests): Handle vCtrlC.
9180 2015-11-30 Pedro Alves <palves@redhat.com>
9182 * gdbthread.h (find_any_thread_of_pid): Declare.
9183 * inferiors.c (thread_of_pid, find_any_thread_of_pid): New
9185 * server.c (handle_query): If current_thread is NULL, look for
9186 another thread of the selected process.
9188 2015-11-26 Daniel Colascione <dancol@dancol.org>
9189 Simon Marchi <simon.marchi@ericsson.com>
9191 * linux-low.c (linux_target_ops): Use linux_proc_tid_get_name.
9192 * server.c (handle_qxfer_threads_worker): Refactor to include thread
9194 * target.h (struct target_ops) <thread_name>: New field.
9195 (target_thread_name): New macro.
9197 2015-11-23 Joel Brobecker <brobecker@adacore.com>
9199 * regcache.h (regcache_invalidate_pid): Add declaration.
9200 * regcache.c (regcache_invalidate_pid): New function, extracted
9201 from regcache_invalidate.
9202 (regcache_invalidate): Reimplement using regcache_invalidate_pid.
9203 Add trivial documentation comment.
9204 * lynx-low.c: Use regcache_invalidate_pid instead of
9205 regcache_invalidate.
9207 2015-11-23 Joel Brobecker <brobecker@adacore.com>
9209 * configure.ac: Do not call AC_CHECK_TYPES for Elf32_auxv_t
9210 and Elf64_auxv_t if the target is Android.
9212 2015-11-22 Doug Evans <xdje42@gmail.com>
9214 * target.h: #include <sys/types.h>.
9216 2015-11-19 Pedro Alves <palves@redhat.com>
9218 * linux-low.c (linux_process_qsupported): Change prototype.
9220 * linux-low.h (struct linux_target_ops) <process_qsupported>:
9222 * linux-x86-low.c (x86_linux_process_qsupported): Change prototype
9223 and adjust to loop over all features.
9224 * server.c (handle_query) <qSupported>: Adjust to call
9225 target_process_qsupported once, passing it a vector of unprocessed
9227 * target.h (struct target_ops) <process_qsupported>: Change
9229 (target_process_qsupported): Adjust.
9231 2015-11-19 Pedro Alves <palves@redhat.com>
9233 * configure.ac (ERROR_ON_WARNING): Don't check whether in C++
9235 * configure: Regenerate.
9237 2015-11-19 Pedro Alves <palves@redhat.com>
9239 * configure: Regenerate.
9241 2015-11-19 Yao Qi <yao.qi@linaro.org>
9243 * linux-aarch64-low.c (emit_data_processing_reg): Change opcode
9246 2015-11-19 Yao Qi <yao.qi@linaro.org>
9248 * linux-aarch64-low.c (enum aarch64_operand_type): New.
9249 (struct aarch64_operand): Move enum out.
9251 2015-11-19 Yao Qi <yao.qi@linaro.org>
9253 * linux-aarch64-low.c (aarch64_fill_fpregset): Cast buf to
9254 struct user_fpsimd_state *.
9255 (aarch64_store_fpregset): Likewise.
9257 2015-11-19 Yao Qi <yao.qi@linaro.org>
9259 * linux-aarch64-low.c (aarch64_fill_gregset): Cast buf to
9260 struct user_pt_regs *.
9261 (aarch64_store_gregset): Likewise.
9263 2015-11-18 Pedro Alves <palves@redhat.com>
9265 * Makefile.in (all_object_files): Add $IPA_OBJS.
9267 2015-11-17 Pedro Alves <palves@redhat.com>
9269 * win32-low.c (win32_resume): Use gdb_signal_from_host,
9270 GDB_SIGNAL_0 and gdb_signal_to_string.
9272 2015-11-17 Pedro Alves <palves@redhat.com>
9274 * win32-low.c (handle_output_debug_string): Remove parameter.
9275 (win32_kill): Remove our_status local and adjust call to
9276 handle_output_debug_string.
9277 (get_child_debug_event): Adjust call to
9278 handle_output_debug_string.
9280 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9282 * linux-mips-low.c (mips_fill_gregset): Add cast.
9283 (mips_store_gregset): Likewise.
9284 (mips_fill_fpregset): Likewise.
9285 (mips_store_fpregset): Likewise.
9287 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9289 * linux-mips-low.c (mips_add_watchpoint): Rename private to
9292 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9294 * linux-mips-low.c (mips_linux_new_thread): Change type of
9295 watch_type to enum target_hw_bp_type.
9297 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9299 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type):
9300 Change return type to arm_hwbp_type.
9302 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9304 * linux-aarch32-low.c (arm_fill_gregset): Add cast.
9305 (arm_store_gregset): Likewise.
9306 * linux-arm-low.c (arm_get_hwcap): Likewise.
9307 (arm_read_description): Likewise.
9309 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9311 * linux-aarch32-low.c (aarch32_regsets): Use NULL_REGSET.
9313 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9315 * linux-ppc-low.c (ppc_get_hwcap): Add cast.
9316 (ppc_fill_vsxregset): Likewise.
9317 (ppc_store_vsxregset): Likewise.
9318 (ppc_fill_vrregset): Likewise.
9319 (ppc_store_vrregset): Likewise.
9320 (ppc_fill_evrregset): Likewise.
9321 (ppc_store_evrregset): Likewise.
9323 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
9325 * linux-ppc-low.c (ppc_usrregs_info): Remove
9326 forward-declaration.
9327 (ppc_arch_setup): Move lower in file.
9329 2015-10-30 Simon Marchi <simon.marchi@ericsson.com>
9331 * proc-service.c (ps_pdread): Change CORE_ADDR cast to uintptr_t.
9332 (ps_pdwrite): Likewise.
9334 2015-10-29 Henrik Wallin <henrik.wallin@windriver.com>
9336 * linux-arm-low.c (arm_new_thread): Move pointer dereference
9337 to after assert checks.
9339 2015-10-29 Simon Marchi <simon.marchi@ericsson.com>
9341 * proc-service.c (ps_pdread): Add/adjust casts.
9342 (ps_pdwrite): Add/adjust casts.
9344 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
9346 * server.c (handle_search_memory_1): Cast return value of
9349 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
9351 * server.c (write_qxfer_response): Change type of data to
9354 2015-10-29 Pedro Alves <palves@redhat.com>
9356 * mem-break.c (Z_packet_to_bkpt_type): Add cast.
9358 2015-10-29 Pedro Alves <palves@redhat.com>
9360 * tracepoint.c (clear_installed_tracepoints): Add casts.
9362 2015-10-29 Pedro Alves <palves@redhat.com>
9364 * server.c (handle_v_cont, process_serial_event): Add enum
9365 gdb_signal casts to signal parsing code.
9367 2015-10-29 Pedro Alves <palves@redhat.com>
9369 * linux-low.h (NULL_REGSET): Define.
9370 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
9371 * linux-arm-low.c (arm_regsets): Likewise.
9372 * linux-crisv32-low.c (cris_regsets): Likewise.
9373 * linux-m68k-low.c (m68k_regsets): Likewise.
9374 * linux-mips-low.c (mips_regsets): Likewise.
9375 * linux-nios2-low.c (nios2_regsets): Likewise.
9376 * linux-ppc-low.c (ppc_regsets): Likewise.
9377 * linux-s390-low.c (s390_regsets): Likewise.
9378 * linux-sh-low.c (sh_regsets): Likewise.
9379 * linux-sparc-low.c (sparc_regsets): Likewise.
9380 * linux-tic6x-low.c (tic6x_regsets): Likewise.
9381 * linux-tile-low.c (tile_regsets): Likewise.
9382 * linux-x86-low.c (x86_regsets): Likewise.
9383 * linux-xtensa-low.c (xtensa_regsets): Likewise.
9385 2015-10-29 Pedro Alves <palves@redhat.com>
9387 * linux-low.h (NULL_REGSET): Define.
9388 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
9389 * linux-arm-low.c (arm_regsets): Likewise.
9390 * linux-crisv32-low.c (cris_regsets): Likewise.
9391 * linux-m68k-low.c (m68k_regsets): Likewise.
9392 * linux-mips-low.c (mips_regsets): Likewise.
9393 * linux-nios2-low.c (nios2_regsets): Likewise.
9394 * linux-ppc-low.c (ppc_regsets): Likewise.
9395 * linux-s390-low.c (s390_regsets): Likewise.
9396 * linux-sh-low.c (sh_regsets): Likewise.
9397 * linux-sparc-low.c (sparc_regsets): Likewise.
9398 * linux-tic6x-low.c (tic6x_regsets): Likewise.
9399 * linux-tile-low.c (tile_regsets): Likewise.
9400 * linux-x86-low.c (x86_regsets): Likewise.
9401 * linux-xtensa-low.c (xtensa_regsets): Likewise.
9403 2015-10-26 Doug Evans <dje@google.com>
9405 * linux-low.c (__SIGRTMIN): Move to nat/linux-nat.h.
9407 2015-10-26 Doug Evans <dje@google.com>
9409 * linux-low.c (W_STOPCODE): Moved to common/gdb_wait.h.
9411 2015-10-26 Doug Evans <dje@google.com>
9413 * thread-db.c (find_one_thread): Cast ti.ti_tid to unsigned long
9415 (attach_thread, find_new_threads_callback): Ditto.
9417 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
9419 * mem-break.h (set_breakpoint_data): Remove.
9421 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
9423 * nto-low.c (nto_sw_breakpoint_from_kind): New function.
9424 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
9425 (initialize_low): Remove set_breakpoint_data call.
9426 * spu-low.c (spu_sw_breakpoint_from_kind): New function.
9427 (struct target_ops) <sw_breakpoint_from_kind>: Iniitalize.
9428 (initialize_low): Remove set_breakpoint_data call.
9429 * win32-low.c (win32_sw_breakpoint_from_kind): New function.
9430 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
9431 (initialize_low): Remove set_breakpoint_data call.
9433 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
9435 * linux-low.c (default_breakpoint_kind_from_pc): Move to target.c.
9436 * mem-break.c (set_breakpoint_at): Use target_breakpoint_kind_from_pc.
9437 * target.c (default_breakpoint_kind_from_pc): Moved from linux-low.c
9438 * target.h (target_breakpoint_kind_from_pc): New macro.
9440 2015-10-22 Antoine Tremblay <antoine.tremblay@ericsson.com>
9442 * linux-low.c (default_breakpoint_kind_from_pc): New function.
9443 (linux_breakpoint_kind_from_pc): Use default_breakpoint_kind_from_pc for
9444 the default breakpoint kind.
9446 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9448 * linux-arm-low.c (arm_supports_z_point_type): Add software
9451 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9453 * linux-arm-low.c: Refactor breakpoint definitions.
9454 (arm_breakpoint_at): Adjust for arm_abi_breakpoint.
9455 (arm_sw_breakpoint_from_kind): Adjust for arm_breakpoint.
9457 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9459 * Makefile.in: Add arm.c/o.
9460 * configure.srv: Likewise.
9461 * linux-arm-low.c (arm_breakpoint_kinds): New enum.
9462 (arm_breakpoint_kind_from_pc): New function.
9463 (arm_sw_breakpoint_from_kind): Return proper kind.
9464 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize.
9466 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9468 * linux-low.c (initialize_low): Ajdust for breakpoint global variables
9470 * mem-break.c : Remove breakpoint_data/breakpoint_len global variables.
9471 (struct raw_breakpoint) <size>: Remove.
9472 (struct raw_breakpoint) <kind>: Add.
9473 (bp_size): New function.
9474 (bp_opcode): Likewise.
9475 (find_raw_breakpoint_at): Adjust for kind.
9476 (insert_memory_breakpoint): Adjust for kind call bp_size,bp_opcode.
9477 (remove_memory_breakpoint): Adjust for kind call bp_size.
9478 (set_raw_breakpoint_at): Adjust for kind.
9479 (set_breakpoint): Likewise.
9480 (set_breakpoint_at): Call breakpoint_kind_from_pc.
9481 (delete_raw_breakpoint): Adjust for kind.
9482 (delete_breakpoint): Likewise.
9483 (find_gdb_breakpoint): Likewise.
9484 (set_gdb_breakpoint_1): Likewise.
9485 (set_gdb_breakpoint): Likewise.
9486 (delete_gdb_breakpoint_1): Likewise.
9487 (delete_gdb_breakpoint): Likewise.
9488 (uninsert_raw_breakpoint): Likewise.
9489 (reinsert_raw_breakpoint): Likewise.
9490 (set_breakpoint_data): Remove.
9491 (validate_inserted_breakpoint): Adjust for kind call bp_size,bp_opcode.
9492 (check_mem_read): Adjust for kind call bp_size.
9493 (check_mem_write): Adjust for kind call bp_size,bp_opcode.
9494 (clone_one_breakpoint): Adjust for kind.
9495 * mem-break.h (set_gdb_breakpoint): Likewise.
9496 (delete_gdb_breakpoint): Likewise.
9497 * server.c (process_serial_event): Likewise.
9499 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9501 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): New function.
9502 (struct linux_target_ops) <breakpoint>: Remove.
9503 (struct linux_target_ops) <breakpoint_len>: Remove.
9504 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9505 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9506 * linux-arm-low.c (arm_breakpoint_kind_from_pc): New function.
9507 (arm_sw_breakpoint_from_kind): New function.
9508 * linux-bfin-low.c (bfin_sw_breakpoint_from_kind): New function.
9509 (struct linux_target_ops) <breakpoint>: Remove.
9510 (struct linux_target_ops) <breakpoint_len>: Remove.
9511 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9512 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9513 * linux-cris-low.c (cris_sw_breakpoint_from_kind): New function.
9514 (struct linux_target_ops) <breakpoint>: Remove.
9515 (struct linux_target_ops) <breakpoint_len>: Remove.
9516 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9517 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9518 * linux-crisv32-low.c (cris_sw_breakpoint_from_kind): New function.
9519 (struct linux_target_ops) <breakpoint>: Remove.
9520 (struct linux_target_ops) <breakpoint_len>: Remove.
9521 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9522 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9523 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_pc
9524 and sw_breakpoint_from_kind to increment the pc.
9525 (linux_breakpoint_kind_from_pc): New function.
9526 (linux_sw_breakpoint_from_kind): New function.
9527 (struct target_ops) <sw_breakpoint_from_kind>: Initialize field.
9528 (initialize_low): Call breakpoint_kind_from_pc and
9529 sw_breakpoint_from_kind to replace breakpoint_data/len.
9530 * linux-low.h (struct linux_target_ops) <breakpoint_kind_from_pc>:
9532 (struct linux_target_ops) <sw_breakpoint_from_kind>: Likewise.
9533 * linux-m32r-low.c (m32r_sw_breakpoint_from_kind): New function.
9534 (struct linux_target_ops) <breakpoint>: Remove.
9535 (struct linux_target_ops) <breakpoint_len>: Remove.
9536 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9537 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9538 * linux-m68k-low.c (m68k_sw_breakpoint_from_kind): New function.
9539 (struct linux_target_ops) <breakpoint>: Remove.
9540 (struct linux_target_ops) <breakpoint_len>: Remove.
9541 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9542 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9543 * linux-mips-low.c (mips_sw_breakpoint_from_kind): New function.
9544 (struct linux_target_ops) <breakpoint>: Remove.
9545 (struct linux_target_ops) <breakpoint_len>: Remove.
9546 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9547 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9548 * linux-nios2-low.c (nios2_sw_breakpoint_from_kind): New function.
9549 (struct linux_target_ops) <breakpoint>: Remove.
9550 (struct linux_target_ops) <breakpoint_len>: Remove.
9551 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9552 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9553 * linux-ppc-low.c (ppc_sw_breakpoint_from_kind): New function.
9554 (struct linux_target_ops) <breakpoint>: Remove.
9555 (struct linux_target_ops) <breakpoint_len>: Remove.
9556 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9557 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9558 * linux-s390-low.c (s390_sw_breakpoint_from_kind): New function.
9559 (struct linux_target_ops) <breakpoint>: Remove.
9560 (struct linux_target_ops) <breakpoint_len>: Remove.
9561 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9562 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9563 * linux-sh-low.c (sh_sw_breakpoint_from_kind): New function.
9564 (struct linux_target_ops) <breakpoint>: Remove.
9565 (struct linux_target_ops) <breakpoint_len>: Remove.
9566 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9567 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9568 * linux-sparc-low.c (sparc_sw_breakpoint_from_kind): New function.
9569 (struct linux_target_ops) <breakpoint>: Remove.
9570 (struct linux_target_ops) <breakpoint_len>: Remove.
9571 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9572 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9573 * linux-tic6x-low.c (tic6x_sw_breakpoint_from_kind): New function.
9574 (struct linux_target_ops) <breakpoint>: Remove.
9575 (struct linux_target_ops) <breakpoint_len>: Remove.
9576 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9577 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9578 * linux-tile-low.c (tile_sw_breakpoint_from_kind): New function.
9579 * linux-x86-low.c (x86_sw_breakpoint_from_kind): New function.
9580 (struct linux_target_ops) <breakpoint>: Remove.
9581 (struct linux_target_ops) <breakpoint_len>: Remove.
9582 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9583 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9584 * linux-xtensa-low.c (xtensa_sw_breakpoint_from_kind) New function.
9585 (struct linux_target_ops) <breakpoint>: Remove.
9586 (struct linux_target_ops) <breakpoint_len>: Remove.
9587 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
9588 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
9590 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
9592 * linux-cris-low.c (cris_get_pc): Remove void arg.
9594 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
9596 * gdbserver/nto-low.c (nto_insert_point, nto_remove_point): Fix
9599 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
9601 * inferiors.c (thread_pid_matches_callback): New function.
9602 (find_thread_process): New function.
9603 (remove_thread): Reset current_thread.
9604 (remove_process): Assert threads have been removed first.
9606 2015-10-15 Yao Qi <yao.qi@linaro.org>
9608 * linux-aarch64-low.c (aarch64_insert_point): Set len to 2
9610 (aarch64_remove_point): Likewise.
9611 * regcache.c (regcache_register_size): New function.
9613 2015-10-12 Yao Qi <yao.qi@linaro.org>
9615 * linux-aarch64-low.c: Update all callers as emit_load_store
9616 is renamed to aarch64_emit_load_store.
9618 2015-10-12 Yao Qi <yao.qi@linaro.org>
9620 * linux-aarch64-low.c: Update all callers of function renaming
9621 from emit_insn to aarch64_emit_insn.
9623 2015-10-12 Yao Qi <yao.qi@linaro.org>
9625 * linux-aarch64-low.c (enum aarch64_opcodes): Move to
9626 arch/aarch64-insn.h.
9627 (struct aarch64_memory_operand): Likewise.
9629 (emit_insn): Move to arch/aarch64-insn.c.
9630 (emit_b, emit_bcond, emit_cb, emit_tb): Remove.
9631 (emit_load_store): Move to arch/aarch64-insn.c.
9632 (emit_ldr, emit_ldrb, emit_ldrsw, emit_nop): Remove.
9633 (can_encode_int32): Remove.
9635 2015-10-12 Yao Qi <yao.qi@linaro.org>
9637 * linux-aarch64-low.c (extract_signed_bitfield): Remove.
9638 (aarch64_decode_ldr_literal): Move to gdb/arch/aarch64-insn.c.
9639 (aarch64_relocate_instruction): Likewise.
9640 (struct aarch64_insn_data): Move to gdb/arch/aarch64-insn.h.
9641 (struct aarch64_insn_visitor): Likewise.
9643 2015-10-12 Yao Qi <yao.qi@linaro.org>
9645 * linux-aarch64-low.c (struct aarch64_insn_data): New.
9646 (struct aarch64_insn_visitor): New.
9647 (struct aarch64_insn_relocation_data): New.
9648 (aarch64_ftrace_insn_reloc_b): New function.
9649 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
9650 (aarch64_ftrace_insn_reloc_cb): Likewise.
9651 (aarch64_ftrace_insn_reloc_tb): Likewise.
9652 (aarch64_ftrace_insn_reloc_adr): Likewise.
9653 (aarch64_ftrace_insn_reloc_ldr_literal): Likewise.
9654 (aarch64_ftrace_insn_reloc_others): Likewise.
9656 (aarch64_relocate_instruction): Use visitor.
9658 2015-10-12 Yao Qi <yao.qi@linaro.org>
9660 * linux-aarch64-low.c (aarch64_relocate_instruction): Return
9661 int. Add argument buf.
9662 (aarch64_install_fast_tracepoint_jump_pad): Pass buf to
9663 aarch64_relocate_instruction.
9665 2015-10-12 Yao Qi <yao.qi@linaro.org>
9667 * linux-aarch64-low.c (aarch64_relocate_instruction): Add
9668 argument insn. Remove local variable insn. Don't call
9670 (aarch64_install_fast_tracepoint_jump_pad): Call
9673 2015-09-30 Yao Qi <yao.qi@linaro.org>
9675 * linux-aarch64-low.c (emit_movk): Shorten a long line.
9676 (emit_load_store_pair): Likewise.
9678 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
9680 * dll.c (match_dll): Add cast(s).
9681 (unloaded_dll): Likewise.
9682 * linux-low.c (second_thread_of_pid_p): Likewise.
9683 (delete_lwp_callback): Likewise.
9684 (count_events_callback): Likewise.
9685 (select_event_lwp_callback): Likewise.
9686 (linux_set_resume_request): Likewise.
9687 * server.c (accumulate_file_name_length): Likewise.
9688 (emit_dll_description): Likewise.
9689 (handle_qxfer_threads_worker): Likewise.
9690 (visit_actioned_threads): Likewise.
9691 * thread-db.c (any_thread_of): Likewise.
9692 * tracepoint.c (same_process_p): Likewise.
9693 (match_blocktype): Likewise.
9694 (build_traceframe_info_xml): Likewise.
9696 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
9698 * ax.c (gdb_parse_agent_expr): Add cast to allocation result
9700 (gdb_unparse_agent_expr): Likewise.
9701 * hostio.c (require_data): Likewise.
9702 (handle_pread): Likewise.
9703 * linux-low.c (disable_regset): Likewise.
9704 (fetch_register): Likewise.
9705 (store_register): Likewise.
9706 (get_dynamic): Likewise.
9707 (linux_qxfer_libraries_svr4): Likewise.
9708 * mem-break.c (delete_fast_tracepoint_jump): Likewise.
9709 (set_fast_tracepoint_jump): Likewise.
9710 (uninsert_fast_tracepoint_jumps_at): Likewise.
9711 (reinsert_fast_tracepoint_jumps_at): Likewise.
9712 (validate_inserted_breakpoint): Likewise.
9713 (clone_agent_expr): Likewise.
9714 * regcache.c (init_register_cache): Likewise.
9715 * remote-utils.c (putpkt_binary_1): Likewise.
9716 (decode_M_packet): Likewise.
9717 (decode_X_packet): Likewise.
9718 (look_up_one_symbol): Likewise.
9719 (relocate_instruction): Likewise.
9720 (monitor_output): Likewise.
9721 * server.c (handle_search_memory): Likewise.
9722 (handle_qxfer_exec_file): Likewise.
9723 (handle_qxfer_libraries): Likewise.
9724 (handle_qxfer): Likewise.
9725 (handle_query): Likewise.
9726 (handle_v_cont): Likewise.
9727 (handle_v_run): Likewise.
9728 (captured_main): Likewise.
9729 * target.c (write_inferior_memory): Likewise.
9730 * thread-db.c (try_thread_db_load_from_dir): Likewise.
9731 * tracepoint.c (init_trace_buffer): Likewise.
9732 (add_tracepoint_action): Likewise.
9733 (add_traceframe): Likewise.
9734 (add_traceframe_block): Likewise.
9735 (cmd_qtdpsrc): Likewise.
9736 (cmd_qtdv): Likewise.
9737 (cmd_qtstatus): Likewise.
9738 (response_source): Likewise.
9739 (response_tsv): Likewise.
9740 (cmd_qtnotes): Likewise.
9741 (gdb_collect): Likewise.
9742 (initialize_tracepoint): Likewise.
9744 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
9746 * linux-aarch64-low-.c: Include ax.h and tracepoint.h.
9747 (enum aarch64_opcodes) <RET>, <SUBS>, <AND>, <ORR>, <ORN>,
9748 <EOR>, <LSLV>, <LSRV>, <ASRV>, <SBFM>, <UBFM>, <CSINC>, <MUL>,
9750 (enum aarch64_condition_codes): New enum.
9751 (w0): New static global.
9754 (struct aarch64_memory_operand) <type>: New
9755 MEMORY_OPERAND_POSTINDEX type.
9756 (postindex_memory_operand): New helper function.
9757 (emit_ret): New function.
9758 (emit_load_store_pair): New function, factored out of emit_stp
9759 with support for MEMORY_OPERAND_POSTINDEX.
9760 (emit_stp): Rewrite using emit_load_store_pair.
9761 (emit_ldp): New function.
9762 (emit_load_store): Likewise.
9763 (emit_ldr): Mention post-index instruction in comment.
9764 (emit_ldrh): New function.
9765 (emit_ldrb): New function.
9766 (emit_ldrsw): Mention post-index instruction in comment.
9767 (emit_str): Likewise.
9768 (emit_subs): New function.
9769 (emit_cmp): Likewise.
9770 (emit_and): Likewise.
9771 (emit_orr): Likewise.
9772 (emit_orn): Likewise.
9773 (emit_eor): Likewise.
9774 (emit_mvn): Likewise.
9775 (emit_lslv): Likewise.
9776 (emit_lsrv): Likewise.
9777 (emit_asrv): Likewise.
9778 (emit_mul): Likewise.
9779 (emit_sbfm): Likewise.
9780 (emit_sbfx): Likewise.
9781 (emit_ubfm): Likewise.
9782 (emit_ubfx): Likewise.
9783 (emit_csinc): Likewise.
9784 (emit_cset): Likewise.
9785 (emit_nop): Likewise.
9786 (emit_ops_insns): New helper function.
9787 (emit_pop): Likewise.
9788 (emit_push): Likewise.
9789 (aarch64_emit_prologue): New function.
9790 (aarch64_emit_epilogue): Likewise.
9791 (aarch64_emit_add): Likewise.
9792 (aarch64_emit_sub): Likewise.
9793 (aarch64_emit_mul): Likewise.
9794 (aarch64_emit_lsh): Likewise.
9795 (aarch64_emit_rsh_signed): Likewise.
9796 (aarch64_emit_rsh_unsigned): Likewise.
9797 (aarch64_emit_ext): Likewise.
9798 (aarch64_emit_log_not): Likewise.
9799 (aarch64_emit_bit_and): Likewise.
9800 (aarch64_emit_bit_or): Likewise.
9801 (aarch64_emit_bit_xor): Likewise.
9802 (aarch64_emit_bit_not): Likewise.
9803 (aarch64_emit_equal): Likewise.
9804 (aarch64_emit_less_signed): Likewise.
9805 (aarch64_emit_less_unsigned): Likewise.
9806 (aarch64_emit_ref): Likewise.
9807 (aarch64_emit_if_goto): Likewise.
9808 (aarch64_emit_goto): Likewise.
9809 (aarch64_write_goto_address): Likewise.
9810 (aarch64_emit_const): Likewise.
9811 (aarch64_emit_call): Likewise.
9812 (aarch64_emit_reg): Likewise.
9813 (aarch64_emit_pop): Likewise.
9814 (aarch64_emit_stack_flush): Likewise.
9815 (aarch64_emit_zero_ext): Likewise.
9816 (aarch64_emit_swap): Likewise.
9817 (aarch64_emit_stack_adjust): Likewise.
9818 (aarch64_emit_int_call_1): Likewise.
9819 (aarch64_emit_void_call_2): Likewise.
9820 (aarch64_emit_eq_goto): Likewise.
9821 (aarch64_emit_ne_goto): Likewise.
9822 (aarch64_emit_lt_goto): Likewise.
9823 (aarch64_emit_le_goto): Likewise.
9824 (aarch64_emit_gt_goto): Likewise.
9825 (aarch64_emit_ge_got): Likewise.
9826 (aarch64_emit_ops_impl): New static global variable.
9827 (aarch64_emit_ops): New target function, return
9828 &aarch64_emit_ops_impl.
9829 (struct linux_target_ops): Install it.
9831 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
9833 * Makefile.in (linux-aarch64-ipa.o, aarch64-ipa.o): New rules.
9834 * configure.srv (aarch64*-*-linux*): Add linux-aarch64-ipa.o and
9836 * linux-aarch64-ipa.c: New file.
9837 * linux-aarch64-low.c: Include arch/aarch64-insn.h, inttypes.h
9839 (aarch64_get_thread_area): New target method.
9840 (extract_signed_bitfield): New helper function.
9841 (aarch64_decode_ldr_literal): New function.
9842 (enum aarch64_opcodes): New enum.
9843 (struct aarch64_register): New struct.
9844 (struct aarch64_operand): New struct.
9845 (x0): New static global.
9854 (aarch64_register): New helper function.
9855 (register_operand): Likewise.
9856 (immediate_operand): Likewise.
9857 (struct aarch64_memory_operand): New struct.
9858 (offset_memory_operand): New helper function.
9859 (preindex_memory_operand): Likewise.
9860 (enum aarch64_system_control_registers): New enum.
9861 (ENCODE): New macro.
9862 (emit_insn): New helper function.
9863 (emit_b): New function.
9864 (emit_bcond): Likewise.
9865 (emit_cb): Likewise.
9866 (emit_tb): Likewise.
9867 (emit_blr): Likewise.
9868 (emit_stp): Likewise.
9869 (emit_ldp_q_offset): Likewise.
9870 (emit_stp_q_offset): Likewise.
9871 (emit_load_store): Likewise.
9872 (emit_ldr): Likewise.
9873 (emit_ldrsw): Likewise.
9874 (emit_str): Likewise.
9875 (emit_ldaxr): Likewise.
9876 (emit_stxr): Likewise.
9877 (emit_stlr): Likewise.
9878 (emit_data_processing_reg): Likewise.
9879 (emit_data_processing): Likewise.
9880 (emit_add): Likewise.
9881 (emit_sub): Likewise.
9882 (emit_mov): Likewise.
9883 (emit_movk): Likewise.
9884 (emit_mov_addr): Likewise.
9885 (emit_mrs): Likewise.
9886 (emit_msr): Likewise.
9887 (emit_sevl): Likewise.
9888 (emit_wfe): Likewise.
9889 (append_insns): Likewise.
9890 (can_encode_int32_in): New helper function.
9891 (aarch64_relocate_instruction): New function.
9892 (aarch64_install_fast_tracepoint_jump_pad): Likewise.
9893 (aarch64_get_min_fast_tracepoint_insn_len): Likewise.
9894 (struct linux_target_ops): Install aarch64_get_thread_area,
9895 aarch64_install_fast_tracepoint_jump_pad and
9896 aarch64_get_min_fast_tracepoint_insn_len.
9898 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
9900 * Makefile.in (aarch64-insn.o): New rule.
9901 * configure.srv (aarch64*-*-linux*): Add aarch64-insn.o.
9903 2015-09-21 Yao Qi <yao.qi@linaro.org>
9905 * ax.c [!IN_PROCESS_AGENT] (gdb_agent_op_sizes): Define it.
9907 2015-09-21 Yao Qi <yao.qi@linaro.org>
9909 * tracepoint.c (max_jump_pad_size): Remove.
9911 2015-09-18 Yao Qi <yao.qi@linaro.org>
9913 * linux-aarch64-low.c: Don't include sys/uio.h.
9914 (ps_get_thread_area): Call aarch64_ps_get_thread_area.
9916 2015-09-16 Wei-cheng Wang <cole945@gmail.com>
9918 * tracepoint.c (eval_result_type): Change prototype.
9919 (condition_true_at_tracepoint): Fix argument to compiled_cond.
9921 2015-09-15 Pedro Alves <palves@redhat.com>
9923 * remote-utils.c (prepare_resume_reply) <TARGET_WAITKIND_EXECD>:
9924 Check whether to report exec events instead of checking whether
9925 multiprocess is enabled.
9927 2015-09-15 Pedro Alves <palves@redhat.com>
9930 * remote-utils.c (prepare_resume_reply): Merge
9931 TARGET_WAITKIND_VFORK_DONE switch case with the
9932 TARGET_WAITKIND_FORKED case.
9934 2015-09-15 Yao Qi <yao.qi@linaro.org>
9936 * server.c (handle_query): Check string comparison using
9937 "else if" instead of "if".
9939 2015-09-15 Yao Qi <yao.qi@linaro.org>
9941 * server.c (vCont_supported): New global variable.
9942 (handle_query): Set vCont_supported to 1 if "vContSupported+"
9943 matches. Append ";vContSupported+" to own_buf.
9944 (handle_v_requests): Append ";s;S" to own_buf if target supports
9945 hardware single step or vCont_supported is false.
9946 (capture_main): Set vCont_supported to zero.
9948 2015-09-15 Yao Qi <yao.qi@linaro.org>
9950 * linux-low.c (linux_supports_conditional_breakpoints): Rename
9952 (linux_supports_hardware_single_step): ... New function.
9953 (linux_target_ops): Update.
9954 * lynx-low.c (lynx_target_ops): Set field
9955 supports_hardware_single_step to target_can_do_hardware_single_step.
9956 * nto-low.c (nto_target_ops): Likewise.
9957 * spu-low.c (spu_target_ops): Likewise.
9958 * win32-low.c (win32_target_ops): Likewise.
9959 * target.c (target_can_do_hardware_single_step): New function.
9960 * target.h (struct target_ops) <supports_conditional_breakpoints>:
9961 Remove. <supports_hardware_single_step>: New field.
9962 (target_supports_conditional_breakpoints): Remove.
9963 (target_supports_hardware_single_step): New macro.
9964 (target_can_do_hardware_single_step): Declare.
9965 * server.c (handle_query): Use target_supports_hardware_single_step
9966 instead of target_supports_conditional_breakpoints.
9968 2015-09-15 Yao Qi <yao.qi@linaro.org>
9970 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): New
9972 (struct linux_target_ops the_low_target): Install
9973 aarch64_linux_siginfo_fixup.
9975 2015-09-11 Don Breazeal <donb@codesourcery.com>
9976 Luis Machado <lgustavo@codesourcery.com>
9978 * linux-low.c (linux_mourn): Static declaration.
9979 (linux_arch_setup): Move in front of
9980 handle_extended_wait.
9981 (linux_arch_setup_thread): New function.
9982 (handle_extended_wait): Handle exec events. Call
9983 linux_arch_setup_thread. Make event_lwp argument a
9984 pointer-to-a-pointer.
9985 (check_zombie_leaders): Do not check stopped threads.
9986 (linux_low_ptrace_options): Add PTRACE_O_TRACEEXEC.
9987 (linux_low_filter_event): Add lwp and thread for exec'ing
9988 non-leader thread if leader thread has been deleted.
9989 Refactor code into linux_arch_setup_thread and call it.
9990 Pass child lwp pointer by reference to handle_extended_wait.
9991 (linux_wait_for_event_filtered): Update comment.
9992 (linux_wait_1): Prevent clobbering exec event status.
9993 (linux_supports_exec_events): New function.
9994 (linux_target_ops) <supports_exec_events>: Initialize new member.
9995 * lynx-low.c (lynx_target_ops) <supports_exec_events>: Initialize
9997 * remote-utils.c (prepare_resume_reply): New stop reason 'exec'.
9998 * server.c (report_exec_events): New global variable.
9999 (handle_query): Handle qSupported query for exec-events feature.
10000 (captured_main): Initialize report_exec_events.
10001 * server.h (report_exec_events): Declare new global variable.
10002 * target.h (struct target_ops) <supports_exec_events>: New
10004 (target_supports_exec_events): New macro.
10005 * win32-low.c (win32_target_ops) <supports_exec_events>:
10006 Initialize new member.
10008 2015-09-09 Markus Metzger <markus.t.metzger@intel.com>
10010 * linux-low.c (linux_low_enable_btrace): Remove.
10011 (linux_target_ops): Replace linux_low_enable_btrace with
10012 linux_enable_btrace.
10014 2015-09-03 Yao Qi <yao.qi@linaro.org>
10016 * linux-aarch64-low.c (aarch64_insert_point): Call
10017 aarch64_handle_watchpoint if aarch64_linux_region_ok_for_watchpoint
10020 2015-08-27 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
10022 * linux-low.c (check_stopped_by_breakpoint): Use
10023 GDB_ARCH_IS_TRAP_BRKPT instead of GDB_ARCH_TRAP_BRKPT.
10025 2015-08-27 Pedro Alves <palves@redhat.com>
10027 * proc-service.c (ps_pdwrite): Return PS_ERR/PS_OK explicily.
10029 2015-08-26 Simon Marchi <simon.marchi@ericsson.com>
10031 * ax.c (gdb_parse_agent_expr): Replace xmalloc-family function with
10032 the XNEW-family equivalent.
10033 (compile_bytecodes): Likewise.
10034 * dll.c (loaded_dll): Likewise.
10035 * event-loop.c (append_callback_event): Likewise.
10036 (create_file_handler): Likewise.
10037 (create_file_event): Likewise.
10038 * hostio.c (handle_open): Likewise.
10039 * inferiors.c (add_thread): Likewise.
10040 (add_process): Likewise.
10041 * linux-aarch64-low.c (aarch64_linux_new_process): Likewise.
10042 * linux-arm-low.c (arm_new_process): Likewise.
10043 (arm_new_thread): Likewise.
10044 * linux-low.c (add_to_pid_list): Likewise.
10045 (linux_add_process): Likewise.
10046 (handle_extended_wait): Likewise.
10047 (add_lwp): Likewise.
10048 (enqueue_one_deferred_signal): Likewise.
10049 (enqueue_pending_signal): Likewise.
10050 (linux_resume_one_lwp_throw): Likewise.
10051 (linux_resume_one_thread): Likewise.
10052 (linux_read_memory): Likewise.
10053 (linux_write_memory): Likewise.
10054 * linux-mips-low.c (mips_linux_new_process): Likewise.
10055 (mips_linux_new_thread): Likewise.
10056 (mips_add_watchpoint): Likewise.
10057 * linux-x86-low.c (initialize_low_arch): Likewise.
10058 * lynx-low.c (lynx_add_process): Likewise.
10059 * mem-break.c (set_raw_breakpoint_at): Likewise.
10060 (set_breakpoint): Likewise.
10061 (add_condition_to_breakpoint): Likewise.
10062 (add_commands_to_breakpoint): Likewise.
10063 (clone_agent_expr): Likewise.
10064 (clone_one_breakpoint): Likewise.
10065 * regcache.c (new_register_cache): Likewise.
10066 * remote-utils.c (look_up_one_symbol): Likewise.
10067 * server.c (queue_stop_reply): Likewise.
10068 (start_inferior): Likewise.
10069 (queue_stop_reply_callback): Likewise.
10070 (handle_target_event): Likewise.
10071 * spu-low.c (fetch_ppc_memory): Likewise.
10072 (store_ppc_memory): Likewise.
10073 * target.c (set_target_ops): Likewise.
10074 * thread-db.c (thread_db_load_search): Likewise.
10075 (try_thread_db_load_1): Likewise.
10076 * tracepoint.c (add_tracepoint): Likewise.
10077 (add_tracepoint_action): Likewise.
10078 (create_trace_state_variable): Likewise.
10079 (cmd_qtdpsrc): Likewise.
10080 (cmd_qtro): Likewise.
10081 (add_while_stepping_state): Likewise.
10082 * win32-low.c (child_add_thread): Likewise.
10083 (get_image_name): Likewise.
10085 2015-08-25 Yao Qi <yao.qi@linaro.org>
10087 * linux-aarch64-low.c (aarch64_linux_new_thread): Remove.
10089 2015-08-25 Yao Qi <yao.qi@linaro.org>
10091 * Makefile.in (aarch64-linux.o): New rule.
10092 * configure.srv (aarch64*-*-linux*): Append aarch64-linux.o to
10094 * linux-aarch64-low.c: Include nat/aarch64-linux.h.
10095 (aarch64_init_debug_reg_state): Make it extern.
10096 (aarch64_linux_prepare_to_resume): Remove.
10098 2015-08-25 Yao Qi <yao.qi@linaro.org>
10100 * linux-aarch64-low.c (aarch64_linux_prepare_to_resume): Use
10101 lwp_arch_private_info and ptid_of_lwp.
10103 2015-08-25 Yao Qi <yao.qi@linaro.org>
10105 * linux-aarch64-low.c (aarch64_get_debug_reg_state): Add argument pid.
10106 Find proc_info by find_process_pid. All callers updated.
10108 2015-08-25 Yao Qi <yao.qi@linaro.org>
10110 * linux-aarch64-low.c (struct arch64_dr_update_callback_param):
10112 (debug_reg_change_callback): Remove.
10113 (aarch64_notify_debug_reg_change): Remove.
10115 2015-08-25 Yao Qi <yao.qi@linaro.org>
10117 * linux-aarch64-low.c (aarch64_notify_debug_reg_change):
10118 Call current_lwp_ptid.
10120 2015-08-25 Yao Qi <yao.qi@linaro.org>
10122 * linux-aarch64-low.c (debug_reg_change_callback): Use
10125 2015-08-25 Yao Qi <yao.qi@linaro.org>
10127 * linux-aarch64-low.c (debug_reg_change_callback): Use phex.
10129 2015-08-25 Yao Qi <yao.qi@linaro.org>
10131 * linux-aarch64-low.c (debug_reg_change_callback): Remove comments.
10133 2015-08-25 Yao Qi <yao.qi@linaro.org>
10135 * linux-aarch64-low.c (debug_reg_change_callback): Re-indent
10138 2015-08-25 Yao Qi <yao.qi@linaro.org>
10140 * linux-aarch64-low.c (aarch64_dr_update_callback_param) <pid>:
10142 (debug_reg_change_callback): Remove argument entry and add argument
10143 lwp. Remove local variable thread. Don't print thread id in the
10144 debugging output. Don't check whether pid of thread equals to pid.
10145 (aarch64_notify_debug_reg_change): Don't set param.pid. Call
10146 iterate_over_lwps instead find_inferior.
10148 2015-08-24 Pedro Alves <palves@redhat.com>
10150 * inferiors.c (get_first_process): New function.
10151 * inferiors.h (get_first_process): New declaration.
10152 * remote-utils.c (read_ptid): Default to the first process in the
10153 list, instead of to the current thread's process.
10155 2015-08-24 Pedro Alves <palves@redhat.com>
10157 * debug.c: Include gdb_sys_time.h instead of sys/time.h.
10158 * event-loop.c: Likewise.
10159 * remote-utils.c: Likewise.
10160 * tracepoint.c: Likewise.
10162 2015-08-24 Pedro Alves <palves@redhat.com>
10164 * spu-low.c (spu_request_interrupt): Use lwpid_of instead of
10167 2015-08-21 Pedro Alves <palves@redhat.com>
10169 * ax.c (gdb_eval_agent_expr): Return expr_eval_unhandled_opcode
10170 instead of literal 1.
10172 2015-08-21 Pedro Alves <palves@redhat.com>
10174 * tdesc.c (default_description): Explicitly zero-initialize.
10176 2015-08-21 Pedro Alves <palves@redhat.com>
10179 * inferiors.c (remove_thread): Discard any pending stop reply for
10181 * server.c (remove_all_on_match_pid): Rename to ...
10182 (remove_all_on_match_ptid): ... this. Work with a filter ptid
10184 (discard_queued_stop_replies): Change parameter to a ptid. Now
10186 (handle_v_kill, kill_inferior_callback, captured_main)
10187 (process_serial_event): Adjust.
10188 * server.h (discard_queued_stop_replies): Declare.
10190 2015-08-21 Pedro Alves <palves@redhat.com>
10192 * linux-low.c (wait_for_sigstop): Always switch to no thread
10193 selected if the previously current thread dies.
10194 * lynx-low.c (lynx_request_interrupt): Use the first thread's
10195 process instead of the current thread's.
10196 * remote-utils.c (input_interrupt): Don't check if there's no
10198 * server.c (gdb_read_memory, gdb_write_memory): If setting the
10199 current thread to the general thread fails, error out.
10200 (handle_qxfer_auxv, handle_qxfer_libraries)
10201 (handle_qxfer_libraries_svr4, handle_qxfer_siginfo)
10202 (handle_qxfer_spu, handle_qxfer_statictrace, handle_qxfer_fdpic)
10203 (handle_query): Check if there's a thread selected instead of
10204 checking whether there's any thread in the thread list.
10205 (handle_qxfer_threads, handle_qxfer_btrace)
10206 (handle_qxfer_btrace_conf): Don't error out early if there's no
10207 thread in the thread list.
10208 (handle_v_cont, myresume): Don't set the current thread to the
10210 (process_serial_event) <Hg handling>: Also set thread_id if the
10211 previous general thread is still alive.
10212 (process_serial_event) <g/G handling>: If setting the current
10213 thread to the general thread fails, error out.
10214 * spu-low.c (spu_resume, spu_request_interrupt): Use the first
10215 thread's lwp instead of the current thread's.
10216 * target.c (set_desired_thread): If the desired thread was not
10217 found, leave the current thread pointing to NULL. Return an int
10218 (boolean) indicating success.
10219 * target.h (set_desired_thread): Change return type to int.
10221 2015-08-20 Max Filippov <jcmvbkbc@gmail.com>
10223 * configure.srv (xtensa*-*-linux*): Add srv_linux_thread_db=yes.
10224 * linux-xtensa-low.c (arch/xtensa.h gdb_proc_service.h): New
10226 (ps_get_thread_area): New function.
10228 2015-08-19 Gary Benson <gbenson@redhat.com>
10230 * hostio.c (handle_pread): Do not attempt to read more data
10231 than hostio_reply_with_data can fit in a packet.
10233 2015-08-18 Joel Brobecker <brobecker@adacore.com>
10235 * linux-aarch32-low.c (NT_ARM_VFP): Define if not already defined.
10237 2015-08-14 Matthew Fortune <matthew.fortune@imgtec.com>
10239 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP_REL.
10241 2015-08-06 Pedro Alves <palves@redhat.com>
10243 * tracepoint.c (expr_eval_result): Now an int.
10245 2015-08-06 Pedro Alves <palves@redhat.com>
10247 * gdbthread.h (struct regcache): Forward declare.
10248 (struct thread_info) <regcache_data>: Now a struct regcache
10250 * inferiors.c (inferior_regcache_data)
10251 (set_inferior_regcache_data): Now work with struct regcache
10253 * inferiors.h (struct regcache): Forward declare.
10254 (inferior_regcache_data, set_inferior_regcache_data): Now work
10255 with struct regcache pointers.
10256 * regcache.c (get_thread_regcache, regcache_invalidate_thread)
10257 (free_register_cache_thread): Remove struct regcache pointer
10260 2015-08-06 Pedro Alves <palves@redhat.com>
10262 * server.c (captured_main): On error, print the exception message
10263 to stderr, and if run_once is set, throw a quit.
10265 2015-08-06 Pedro Alves <palves@redhat.com>
10267 * linux-low.c (move_out_of_jump_pad_callback): Temporarily switch
10268 the current thread.
10270 2015-08-06 Pedro Alves <palves@redhat.com>
10272 * linux-low.c (linux_write_memory): Rewrite debug output to avoid
10273 reading beyond the passed in buffer length.
10275 2015-08-06 Pierre Langlois <pierre.langlois@arm.com>
10277 * tracepoint.c (symbol_list) <required>: Remove.
10279 2015-08-06 Pedro Alves <palves@redhat.com>
10281 * linux-low.c (handle_extended_wait): Set the fork child's suspend
10282 count if stopping and suspending threads.
10283 (check_stopped_by_breakpoint): If stopped by trace, set the LWP's
10284 stop reason to TARGET_STOPPED_BY_SINGLE_STEP.
10285 (linux_detach): Complete an ongoing step-over.
10286 (lwp_suspended_inc, lwp_suspended_decr): New functions. Use
10288 (resume_stopped_resumed_lwps): Don't resume a suspended thread.
10289 (linux_wait_1): If passing a signal to the inferior after
10290 finishing a step-over, unsuspend and re-resume all lwps. If we
10291 see a single-step event but the thread should be continuing, don't
10292 pass the trap to gdb.
10293 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback): Use
10294 internal_error instead of gdb_assert.
10295 (enqueue_pending_signal): New function.
10296 (check_ptrace_stopped_lwp_gone): Add debug output.
10297 (start_step_over): Use internal_error instead of gdb_assert.
10298 (complete_ongoing_step_over): New function.
10299 (linux_resume_one_thread): Don't resume a suspended thread.
10300 (proceed_one_lwp): If the LWP is stepping over a breakpoint, reset
10303 2015-08-06 Pedro Alves <palves@redhat.com>
10305 * linux-low.c (add_lwp): Set waitstatus to TARGET_WAITKIND_IGNORE.
10306 (linux_thread_alive): Use lwp_is_marked_dead.
10307 (extended_event_reported): Delete.
10308 (linux_wait_1): Check if waitstatus is TARGET_WAITKIND_IGNORE
10309 instead of extended_event_reported.
10310 (mark_lwp_dead): Don't set the 'dead' flag. Store the waitstatus
10312 (lwp_is_marked_dead): New function.
10313 (lwp_running): Use lwp_is_marked_dead.
10314 * linux-low.h: Delete 'dead' field, and update 'waitstatus's
10317 2015-08-06 Pedro Alves <palves@redhat.com>
10319 * linux-low.c (linux_wait_1): Move fork event output out of the
10320 !report_to_gdb check. Pass event_child->waitstatus to
10321 target_waitstatus_to_string instead of ourstatus.
10323 2015-08-04 Yao Qi <yao.qi@linaro.org>
10325 * linux-aarch64-low.c (aarch64_supports_tracepoints): Return 0
10326 if current_thread is 32 bit.
10328 2015-08-04 Yao Qi <yao.qi@linaro.org>
10330 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
10331 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
10332 * server.c (extended_protocol): Remove "static".
10333 * server.h (extended_protocol): Declare it.
10335 2015-08-04 Yao Qi <yao.qi@linaro.org>
10337 * linux-aarch64-low.c (aarch64_get_pc): Get PC register on
10338 both aarch64 and aarch32.
10339 (aarch64_set_pc): Likewise.
10341 2015-08-04 Yao Qi <yao.qi@linaro.org>
10343 * configure.srv (case aarch64*-*-linux*): Append arm-with-neon.o
10344 to srv_regobj and append arm-core.xml arm-vfpv3.xml and
10345 arm-with-neon.xml to srv_xmlfiles.
10346 * linux-aarch64-low.c: Include linux-aarch32-low.h.
10347 (is_64bit_tdesc): New function.
10348 (aarch64_linux_read_description): New function.
10349 (aarch64_arch_setup): Call aarch64_linux_read_description.
10350 (regs_info): Rename to regs_info_aarch64.
10351 (aarch64_regs_info): Return right regs_info.
10352 (initialize_low_arch): Call initialize_low_arch_aarch32.
10354 2015-08-04 Yao Qi <yao.qi@linaro.org>
10356 * configure.srv (srv_tgtobj): Add linux-aarch32-low.o.
10357 * linux-aarch32-low.c: New file.
10358 * linux-aarch32-low.h: New file.
10359 * linux-arm-low.c (arm_fill_gregset): Move it to
10360 linux-aarch32-low.c.
10361 (arm_store_gregset): Likewise.
10362 (arm_fill_vfpregset): Call arm_fill_vfpregset_num
10363 (arm_store_vfpregset): Call arm_store_vfpregset_num.
10364 (arm_arch_setup): Check if PTRACE_GETREGSET works.
10365 (regs_info): Rename to regs_info_arm.
10366 (arm_regs_info): Return regs_info_aarch32 if
10367 have_ptrace_getregset is 1 and target description is
10368 arm_with_neon or arm_with_vfpv3.
10369 (initialize_low_arch): Don't call init_registers_arm_with_neon.
10370 Call initialize_low_arch_aarch32 instead.
10372 2015-08-04 Yao Qi <yao.qi@linaro.org>
10374 * linux-x86-low.c (have_ptrace_getregset): Move it to ...
10375 * linux-low.c: ... here.
10376 * linux-low.h (have_ptrace_getregset): Declare it.
10378 2015-08-04 Pedro Alves <palves@redhat.com>
10380 * thread-db.c (struct thread_db): Use new typedefs.
10381 (try_thread_db_load_1): Define local TDB_DLSYM macro and use it in
10383 (disable_thread_event_reporting): Cast result of dlsym to
10384 destination function pointer type.
10385 (thread_db_mourn): Use td_ta_delete_ftype.
10387 2015-08-03 Sandra Loosemore <sandra@codesourcery.com>
10389 * linux-nios2-low.c (NIOS2_BREAKPOINT): Conditionalize for
10391 (CDX_BREAKPOINT): Define for R2.
10392 (nios2_breakpoint_at): Check for CDX_BREAKPOINT when R2.
10393 (the_low_target): Add comments.
10395 2015-07-30 Yao Qi <yao.qi@linaro.org>
10397 * linux-arm-low.c (arm_hwcap): Remove it.
10398 (arm_read_description): New local variable arm_hwcap. Don't
10399 set arm_hwcap to zero.
10401 2015-07-30 Yao Qi <yao.qi@linaro.org>
10403 * linux-arm-low.c (arm_fill_wmmxregset): Don't use arm_hwcap.
10404 Use regcache->tdesc instead.
10405 (arm_store_wmmxregset): Likewise.
10406 (arm_fill_vfpregset): Likewise.
10407 (arm_store_vfpregset): Likewise.
10409 2015-07-30 Yao Qi <yao.qi@linaro.org>
10411 * linux-arm-low.c: Include arch/arm.h.
10412 (arm_fill_gregset): Don't use arm_num_regs and arm_regmap.
10413 (arm_store_gregset): Likewise.
10415 2015-07-29 Simon Marchi <simon.marchi@ericsson.com>
10417 * linux-mips-low.c (mips_linux_prepare_to_resume): Add NULL as
10418 ptrace's 4th parameter.
10420 2015-07-27 Yao Qi <yao.qi@linaro.org>
10422 * configure.srv (case aarch64*-*-linux*): Don't set
10425 2015-07-24 Pedro Alves <palves@redhat.c: Likewise.om>
10427 * linux-aarch64-low.c: Include nat/gdb_ptrace.h instead of
10429 * linux-arm-low.c: Likewise.
10430 * linux-cris-low.c: Likewise.
10431 * linux-crisv32-low.c: Likewise.
10432 * linux-low.c: Likewise.
10433 * linux-m68k-low.c: Likewise.
10434 * linux-mips-low.c: Likewise.
10435 * linux-nios2-low.c: Likewise.
10436 * linux-s390-low.c: Likewise.
10437 * linux-sparc-low.c: Likewise.
10438 * linux-tic6x-low.c: Likewise.
10439 * linux-tile-low.c: Likewise.
10440 * linux-x86-low.c: Likewise.
10442 2015-07-24 Pedro Alves <palves@redhat.com>
10444 * config.in: Regenerate.
10445 * configure: Regenerate.
10447 2015-07-24 Pedro Alves <palves@redhat.com>
10449 * acinclude.m4: Include ../ptrace.m4.
10450 * configure.ac: Call GDB_AC_PTRACE.
10451 * config.in, configure: Regenerate.
10453 2015-07-24 Yao Qi <yao.qi@linaro.org>
10455 * linux-low.c (linux_create_inferior): Remove setting to
10456 proc->priv->new_inferior.
10457 (linux_attach): Likewise.
10458 (linux_low_filter_event): Likewise.
10459 * linux-low.h (struct process_info_private) <new_inferior>: Remove.
10461 2015-07-24 Yao Qi <yao.qi@linaro.org>
10463 * linux-low.c (linux_arch_setup): New function.
10464 (linux_low_filter_event): If proc->tdesc is NULL and
10465 proc->attached is true, call the_low_target.arch_setup.
10466 Otherwise, keep status pending, and return.
10467 (linux_resume_one_lwp_throw): Don't call get_pc if
10468 thread->while_stepping isn't NULL. Don't call
10469 get_thread_regcache if proc->tdesc is NULL.
10470 (need_step_over_p): Return 0 if proc->tdesc is NULL.
10471 (linux_target_ops): Install arch_setup.
10472 * server.c (start_inferior): Call the_target->arch_setup.
10473 * target.h (struct target_ops) <arch_setup>: New field.
10474 (target_arch_setup): New marco.
10475 * lynx-low.c (lynx_target_ops): Update.
10476 * nto-low.c (nto_target_ops): Update.
10477 * spu-low.c (spu_target_ops): Update.
10478 * win32-low.c (win32_target_ops): Update.
10480 2015-07-24 Yao Qi <yao.qi@linaro.org>
10482 * linux-low.c (linux_add_process): Don't set
10483 proc->priv->new_inferior.
10484 (linux_create_inferior): Set proc->priv->new_inferior to 1.
10485 (linux_attach): Likewise.
10487 2015-07-24 Yao Qi <yao.qi@linaro.org>
10489 * server.c (start_inferior): Code refactor.
10491 2015-07-24 Yao Qi <yao.qi@linaro.org>
10493 * server.c (process_serial_event): Set general_thread.
10495 2015-07-21 Yao Qi <yao.qi@linaro.org>
10497 * linux-aarch64-low.c (aarch64_arch_setup): Remove code and call
10498 aarch64_linux_get_debug_reg_capacity.
10500 2015-07-17 Yao Qi <yao.qi@linaro.org>
10502 * Makefile.in (aarch64-linux-hw-point.o): New rule.
10503 * configure.srv (srv_tgtobj): Append aarch64-linux-hw-point.o.
10504 * linux-aarch64-low.c: Include nat/aarch64-linux-hw-point.h.
10505 (AARCH64_HBP_MAX_NUM): Move to nat/aarch64-linux-hw-point.h.
10506 (AARCH64_HWP_MAX_NUM, AARCH64_HBP_ALIGNMENT): Likewise.
10507 (AARCH64_HWP_ALIGNMENT): Likewise.
10508 (AARCH64_HWP_MAX_LEN_PER_REG): Likewise.
10509 (AARCH64_DEBUG_NUM_SLOTS, AARCH64_DEBUG_ARCH): Likewise.
10510 (aarch64_num_bp_regs, aarch64_num_wp_regs): Likewise.
10511 (AARCH64_DEBUG_ARCH_V8, DR_MARK_ALL_CHANGED): Likewise.
10512 (DR_MARK_N_CHANGED, DR_CLEAR_CHANGED): Likewise.
10513 (DR_HAS_CHANGED, DR_N_HAS_CHANGE): Likewise.
10514 (struct aarch64_debug_reg_state): Likewise.
10515 (struct arch_lwp_info): Likewise.
10516 (aarch64_align_watchpoint): Likewise.
10517 (DR_CONTROL_ENABLED, DR_CONTROL_LENGTH): Likewise.
10518 (aarch64_watchpoint_length): Likewise.
10519 (aarch64_point_encode_ctrl_reg): Likewise
10520 (aarch64_point_is_aligned): Likewise.
10521 (aarch64_align_watchpoint): Likewise.
10522 (aarch64_linux_set_debug_regs):
10523 (aarch64_dr_state_insert_one_point): Likewise.
10524 (aarch64_dr_state_remove_one_point): Likewise.
10525 (aarch64_handle_breakpoint): Likewise.
10526 (aarch64_handle_aligned_watchpoint): Likewise.
10527 (aarch64_handle_unaligned_watchpoint): Likewise.
10528 (aarch64_handle_watchpoint): Likewise.
10530 2015-07-17 Yao Qi <yao.qi@linaro.org>
10532 * linux-aarch64-low.c (aarch64_handle_breakpoint): Add argument state
10533 and don't aarch64_get_debug_reg_state. All callers update.
10534 (aarch64_handle_aligned_watchpoint): Likewise.
10535 (aarch64_handle_unaligned_watchpoint): Likewise.
10536 (aarch64_handle_watchpoint): Likewise.
10537 (aarch64_insert_point): Call aarch64_get_debug_reg_state earlier.
10538 (aarch64_remove_point): Likewise.
10540 2015-07-17 Yao Qi <yao.qi@linaro.org>
10542 * linux-aarch64-low.c (aarch64_show_debug_reg_state): Use
10544 (aarch64_handle_unaligned_watchpoint): Likewise.
10546 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
10548 Revert the previous 3 commits:
10549 Move gdb_regex* to common/
10550 Move linux_find_memory_regions_full & co.
10551 gdbserver build-id attribute generator
10553 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
10554 Jan Kratochvil <jan.kratochvil@redhat.com>
10556 gdbserver build-id attribute generator.
10557 * linux-low.c (nat/linux-maps.h, search.h, rsp-low.h): Include.
10558 (ElfXX_Ehdr, ElfXX_Phdr, ElfXX_Nhdr): New.
10559 (ELFXX_FLD, ELFXX_SIZEOF, ELFXX_ROUNDUP, BUILD_ID_INVALID): New.
10561 (get_dynamic): Use find_pdhr to traverse program headers.
10562 (struct mapping_entry, mapping_entry_s, free_mapping_entry_vec)
10563 (compare_mapping_entry_range, struct find_memory_region_callback_data)
10564 (read_build_id, find_memory_region_callback, lrfind_mapping_entry)
10565 (get_hex_build_id): New.
10566 (linux_qxfer_libraries_svr4): Add optional build-id attribute
10567 to reply XML document.
10569 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
10570 Jan Kratochvil <jan.kratochvil@redhat.com>
10572 * target.c: Include target/target-utils.h and fcntl.h.
10573 (target_fileio_read_stralloc_1_pread, target_fileio_read_stralloc_1)
10574 (target_fileio_read_stralloc): New functions.
10576 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
10578 * Makefile.in (OBS): Add gdb_regex.o.
10579 (gdb_regex.o): New.
10580 * config.in: Rebuilt.
10581 * configure: Rebuilt.
10583 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
10584 Jan Kratochvil <jan.kratochvil@redhat.com>
10586 Create empty nat/linux-maps.[ch] and common/target-utils.[ch].
10587 * Makefile.in (OBS): Add target-utils.o.
10588 (linux-maps.o, target-utils.o): New.
10589 * configure.srv (srv_linux_obj): Add linux-maps.o.
10591 2015-07-15 Pierre Langlois <pierre.langlois@arm.com>
10593 * linux-aarch64-low.c (aarch64_supports_range_stepping): New
10594 function, return 1.
10595 (the_low_target): Install it.
10597 2015-07-14 Pedro Alves <palves@redhat.com>
10599 * linux-low.c (kill_wait_lwp): Don't assert if waitpid fails.
10600 Instead, ignore ECHILD, and throw an error for other errnos.
10602 2015-07-10 Pedro Alves <palves@redhat.com>
10604 * event-loop.c (struct callback_event) <data>: Change type to
10605 gdb_client_data instance instead of gdb_client_data pointer.
10606 (append_callback_event): Adjust.
10608 2015-07-10 Pierre Langlois <pierre.langlois@arm.com>
10610 * linux-aarch64-low.c: Add comments for each linux_target_ops
10611 method. Remove comments already covered in target_ops and
10612 linux_target_ops definitions.
10613 (the_low_target): Add comments for each unimplemented method.
10615 2015-07-09 Yao Qi <yao.qi@linaro.org>
10617 * linux-aarch64-low.c (aarch64_regmap): Remove.
10618 (aarch64_usrregs_info): Remove.
10619 (regs_info): Set field usrregs to NULL.
10621 2015-07-02 Markus Metzger <markus.t.metzger@intel.com>
10623 * linux-low.c: Include "rsp-low.h"
10624 (linux_low_encode_pt_config, linux_low_encode_raw): New.
10625 (linux_low_read_btrace): Support BTRACE_FORMAT_PT.
10626 (linux_low_btrace_conf): Support BTRACE_FORMAT_PT.
10627 (handle_btrace_enable_pt): New.
10628 (handle_btrace_general_set): Support "pt".
10629 (handle_btrace_conf_general_set): Support "pt:size".
10631 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
10633 * linux-aarch64-low.c (aarch64_supports_z_point_type): Enable for
10636 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
10638 * linux-aarch64-low.c: Remove comment about endianness.
10639 (aarch64_breakpoint): Change type to gdb_byte[]. Set to "brk #0".
10640 (aarch64_breakpoint_at): Change type of insn to gdb_byte[]. Use
10643 2015-06-24 Gary Benson <gbenson@redhat.com>
10645 * linux-i386-ipa.c (stdint.h): Do not include.
10646 * lynx-i386-low.c (stdint.h): Likewise.
10647 * lynx-ppc-low.c (stdint.h): Likewise.
10648 * mem-break.c (stdint.h): Likewise.
10649 * thread-db.c (stdint.h): Likewise.
10650 * tracepoint.c (stdint.h): Likewise.
10651 * win32-low.c (stdint.h): Likewise.
10653 2015-06-18 Simon Marchi <simon.marchi@ericsson.com>
10655 * server.c (write_qxfer_response): Update call to
10656 remote_escape_output.
10658 2015-06-15 Aleksandar Ristovski <aristovski@qnx.com
10659 Jan Kratochvil <jan.kratochvil@redhat.com>
10661 Merge multiple hex conversions.
10662 * gdbreplay.c (tohex): Rename to 'fromhex'.
10663 (logchar): Use fromhex.
10665 2015-06-10 Jan Kratochvil <jan.kratochvil@redhat.com>
10667 * server.c (handle_qxfer_libraries): Set `version' attribute for
10670 2015-06-10 Gary Benson <gbenson@redhat.com>
10672 * target.h (struct target_ops) <multifs_open>: New field.
10673 <multifs_unlink>: Likewise.
10674 <multifs_readlink>: Likewise.
10675 * linux-low.c (nat/linux-namespaces.h): New include.
10676 (linux_target_ops): Initialize the_target->multifs_open,
10677 the_target->multifs_unlink and the_target->multifs_readlink.
10678 * hostio.h (hostio_handle_new_gdb_connection): New declaration.
10679 * hostio.c (hostio_fs_pid): New static variable.
10680 (hostio_handle_new_gdb_connection): New function.
10681 (handle_setfs): Likewise.
10682 (handle_open): Use the_target->multifs_open as appropriate.
10683 (handle_unlink): Use the_target->multifs_unlink as appropriate.
10684 (handle_readlink): Use the_target->multifs_readlink as
10686 (handle_vFile): Handle vFile:setfs packets.
10687 * server.c (handle_query): Call hostio_handle_new_gdb_connection
10688 after target_handle_new_gdb_connection.
10690 2015-06-10 Gary Benson <gbenson@redhat.com>
10692 * configure.ac (AC_CHECK_FUNCS): Add setns.
10693 * config.in: Regenerate.
10694 * configure: Likewise.
10695 * Makefile.in (SFILES): Add nat/linux-namespaces.c.
10696 (linux-namespaces.o): New rule.
10697 * configure.srv (srv_linux_obj): Add linux-namespaces.o.
10699 2015-06-09 Gary Benson <gbenson@redhat.com>
10701 * hostio.c (handle_open): Process mode argument with
10702 fileio_to_host_mode.
10704 2015-06-01 Yao Qi <yao.qi@linaro.org>
10706 * linux-s390-low.c (PTRACE_GETREGSET, PTRACE_SETREGSET): Remove.
10707 * linux-x86-low.c: Likewise.
10709 2015-05-28 Don Breazeal <donb@codesourcery.com>
10711 * linux-low.c (handle_extended_wait): Initialize
10712 thread_info.last_resume_kind for new fork children.
10714 2015-05-15 Pedro Alves <palves@redhat.com>
10716 * target.h (target_handle_new_gdb_connection): Rewrite using if
10717 wrapped in do/while.
10719 2015-05-14 Joel Brobecker <brobecker@adacore.com>
10721 * configure.ac: Add prfpregset_t BFD_HAVE_SYS_PROCFS_TYPE check.
10722 * configure, config.in: Regenerate.
10723 * gdb_proc_service.h [HAVE_PRFPREGSET_T] (prfpregset_t):
10726 2015-05-12 Don Breazeal <donb@codesourcery.com>
10728 * linux-low.c (handle_extended_wait): Handle PTRACE_EVENT_FORK and
10729 PTRACE_EVENT_VFORK_DONE.
10730 (linux_low_ptrace_options, extended_event_reported): Add vfork
10732 * remote-utils.c (prepare_resume_reply): New stop reasons "vfork"
10733 and "vforkdone" for RSP 'T' Stop Reply Packet.
10734 * server.h (report_vfork_events): Declare
10737 2015-05-12 Don Breazeal <donb@codesourcery.com>
10739 * linux-aarch64-low.c (aarch64_linux_new_fork): New function.
10740 (the_low_target) <new_fork>: Initialize new member.
10741 * linux-arm-low.c (arm_new_fork): New function.
10742 (the_low_target) <new_fork>: Initialize new member.
10743 * linux-low.c (handle_extended_wait): Call new target function
10745 * linux-low.h (struct linux_target_ops) <new_fork>: New member.
10746 * linux-mips-low.c (mips_add_watchpoint): New function
10747 extracted from mips_insert_point.
10748 (the_low_target) <new_fork>: Initialize new member.
10749 (mips_linux_new_fork): New function.
10750 (mips_insert_point): Call mips_add_watchpoint.
10751 * linux-x86-low.c (x86_linux_new_fork): New function.
10752 (the_low_target) <new_fork>: Initialize new member.
10754 2015-05-12 Don Breazeal <donb@codesourcery.com>
10756 * linux-low.c (handle_extended_wait): Implement return value,
10757 rename argument 'event_child' to 'event_lwp', handle
10758 PTRACE_EVENT_FORK, call internal_error for unrecognized event.
10759 (linux_low_ptrace_options): New function.
10760 (linux_low_filter_event): Call linux_low_ptrace_options,
10761 use different argument fo linux_enable_event_reporting,
10762 use return value from handle_extended_wait.
10763 (extended_event_reported): New function.
10764 (linux_wait_1): Call extended_event_reported and set
10765 status to report fork events.
10766 (linux_write_memory): Add pid to debug message.
10767 (reset_lwp_ptrace_options_callback): New function.
10768 (linux_handle_new_gdb_connection): New function.
10769 (linux_target_ops): Initialize new structure member.
10770 * linux-low.h (struct lwp_info) <waitstatus>: New member.
10771 * lynx-low.c: Initialize new structure member.
10772 * remote-utils.c (prepare_resume_reply): Implement stop reason
10773 "fork" for "T" stop message.
10774 * server.c (handle_query): Call handle_new_gdb_connection.
10775 * server.h (report_fork_events): Declare global flag.
10776 * target.h (struct target_ops) <handle_new_gdb_connection>:
10778 (target_handle_new_gdb_connection): New macro.
10779 * win32-low.c: Initialize new structure member.
10781 2015-05-12 Don Breazeal <donb@codesourcery.com>
10783 * mem-break.c (APPEND_TO_LIST): Define macro.
10784 (clone_agent_expr): New function.
10785 (clone_one_breakpoint): New function.
10786 (clone_all_breakpoints): New function.
10787 * mem-break.h: Declare new functions.
10789 2015-05-12 Don Breazeal <donb@codesourcery.com>
10791 * linux-low.c (linux_supports_fork_events): New function.
10792 (linux_supports_vfork_events): New function.
10793 (linux_target_ops): Initialize new structure members.
10794 (initialize_low): Call linux_check_ptrace_features.
10795 * lynx-low.c (lynx_target_ops): Initialize new structure
10797 * server.c (report_fork_events, report_vfork_events):
10799 (handle_query): Add new features to qSupported packet and
10801 (captured_main): Initialize new global variables.
10802 * target.h (struct target_ops) <supports_fork_events>:
10804 <supports_vfork_events>: New member.
10805 (target_supports_fork_events): New macro.
10806 (target_supports_vfork_events): New macro.
10807 * win32-low.c (win32_target_ops): Initialize new structure
10810 2015-05-12 Gary Benson <gbenson@redhat.com>
10812 * server.c (handle_qxfer_exec_file): Use current process
10815 2015-05-08 Sandra Loosemore <sandra@codesourcery.com>
10817 * linux-nios2-low.c: Include elf/common.h. Adjust comments.
10818 Remove HAVE_PTRACE_GETREGS conditionals.
10819 (nios2_regsets): Use PTRACE_GETREGSET and PTRACE_SETREGSET
10820 instead of PTRACE_GETREGS and PTRACE_SETREGS.
10822 2015-05-08 Yao Qi <yao.qi@linaro.org>
10824 * linux-low.c (linux_supports_conditional_breakpoints): New
10826 (linux_target_ops): Install new target method.
10827 * lynx-low.c (lynx_target_ops): Install NULL hook for
10828 supports_conditional_breakpoints.
10829 * nto-low.c (nto_target_ops): Likewise.
10830 * spu-low.c (spu_target_ops): Likewise.
10831 * win32-low.c (win32_target_ops): Likewise.
10832 * server.c (handle_query): Check
10833 target_supports_conditional_breakpoints.
10834 * target.h (struct target_ops) <supports_conditional_breakpoints>:
10836 (target_supports_conditional_breakpoints): New macro.
10838 2015-05-06 Pedro Alves <palves@redhat.com>
10841 * server.c (start_inferior): If the process exits, mourn it.
10843 2015-04-21 Gary Benson <gbenson@redhat.com>
10845 * hostio.c (fileio_open_flags_to_host): Factored out to
10846 fileio_to_host_openflags in common/fileio.c. Single use
10849 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
10851 * linux-xtensa-low.c (xtensa_fill_gregset)
10852 (xtensa_store_gregset): Check XCHAL_HAVE_LOOPS instead of
10855 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
10857 * linux-xtensa-low.c (xtensa_usrregs_info): Remove.
10858 (regs_info): Replace usrregs pointer with NULL.
10860 2015-04-17 Gary Benson <gbenson@redhat.com>
10862 * target.h (struct target_ops) <pid_to_exec_file>: New field.
10863 * linux-low.c (linux_target_ops): Initialize pid_to_exec_file.
10864 * server.c (handle_qxfer_exec_file): New function.
10865 (qxfer_packets): Add exec-file entry.
10866 (handle_query): Report qXfer:exec-file:read as supported packet.
10868 2015-04-14 Romain Naour <romain.naour@openwide.fr> (tiny change)
10870 * linux-low.c (linux_read_offsets): Remove get_thread_lwp.
10872 2015-04-09 Gary Benson <gbenson@redhat.com>
10874 * hostio-errno.c (errno_to_fileio_error): Remove function.
10875 Update caller to use remote_fileio_to_fio_error.
10877 2015-04-09 Yao Qi <yao.qi@linaro.org>
10879 * linux-low.c (linux_insert_point): Call
10880 insert_memory_breakpoint if TYPE is raw_bkpt_type_sw.
10881 (linux_remove_point): Call remove_memory_breakpoint if type is
10883 * linux-x86-low.c (x86_insert_point): Don't call
10884 insert_memory_breakpoint.
10885 (x86_remove_point): Don't call remove_memory_breakpoint.
10887 2015-04-01 Pedro Alves <palves@redhat.com>
10888 Cleber Rosa <crosa@redhat.com>
10890 * server.c (gdbserver_usage): Reorganize and extend the usage
10893 2015-03-24 Pedro Alves <palves@redhat.com>
10895 * linux-low.c (check_stopped_by_breakpoint): Tweak debug log
10896 output. Also dump TRAP_TRACE.
10897 (linux_low_filter_event): In debug output, distinguish a
10898 resume_stop SIGSTOP from a delayed SIGSTOP.
10900 2015-03-24 Gary Benson <gbenson@redhat.com>
10902 * linux-x86-low.c (x86_linux_new_thread): Moved to
10904 (x86_linux_prepare_to_resume): Likewise.
10906 2015-03-24 Gary Benson <gbenson@redhat.com>
10908 * Makefile.in (x86-linux-dregs.o): New rule.
10909 * configure.srv: Add x86-linux-dregs.o to relevant targets.
10910 * linux-x86-low.c: Include nat/x86-linux-dregs.h.
10911 (u_debugreg_offset): Moved to nat/x86-linux-dregs.c.
10912 (x86_linux_dr_get): Likewise.
10913 (x86_linux_dr_set): Likewise.
10914 (update_debug_registers_callback): Likewise.
10915 (x86_linux_dr_set_addr): Likewise.
10916 (x86_linux_dr_get_addr): Likewise.
10917 (x86_linux_dr_set_control): Likewise.
10918 (x86_linux_dr_get_control): Likewise.
10919 (x86_linux_dr_get_status): Likewise.
10920 (x86_linux_update_debug_registers): Likewise.
10922 2015-03-24 Gary Benson <gbenson@redhat.com>
10924 * linux-x86-low.c (x86_linux_update_debug_registers):
10925 New function, factored out from...
10926 (x86_linux_prepare_to_resume): ...this.
10928 2015-03-24 Gary Benson <gbenson@redhat.com>
10930 * linux-x86-low.c (x86_linux_dr_get): Update comments.
10931 (x86_linux_dr_set): Likewise.
10932 (update_debug_registers_callback): Likewise.
10933 (x86_linux_dr_set_addr): Likewise.
10934 (x86_linux_dr_get_addr): Likewise.
10935 (x86_linux_dr_set_control): Likewise.
10936 (x86_linux_dr_get_control): Likewise.
10937 (x86_linux_dr_get_status): Likewise.
10938 (x86_linux_prepare_to_resume): Likewise.
10940 2015-03-24 Gary Benson <gbenson@redhat.com>
10942 * linux-x86-low.c (x86_linux_dr_get): Add assertion.
10943 Use perror_with_name. Pass string through gettext.
10944 (x86_linux_dr_set): Likewise.
10946 2015-03-24 Gary Benson <gbenson@redhat.com>
10948 * linux-x86-low.c (x86_dr_low_set_addr): Rename to...
10949 (x86_linux_dr_set_addr): ...this.
10950 (x86_dr_low_get_addr): Rename to...
10951 (x86_linux_dr_get_addr): ...this.
10952 (x86_dr_low_set_control): Rename to...
10953 (x86_linux_dr_set_control): ...this.
10954 (x86_dr_low_get_control): Rename to...
10955 (x86_linux_dr_get_control): ...this.
10956 (x86_dr_low_get_status): Rename to...
10957 (x86_linux_dr_get_status): ...this.
10958 (x86_dr_low): Update with new function names.
10960 2015-03-24 Gary Benson <gbenson@redhat.com>
10962 * Makefile.in (x86-linux.o): New rule.
10963 * configure.srv: Add x86-linux.o to relevant targets.
10964 * linux-low.c (lwp_set_arch_private_info): New function.
10965 (lwp_arch_private_info): Likewise.
10966 * linux-x86-low.c: Include nat/x86-linux.h.
10967 (arch_lwp_info): Removed structure.
10968 (update_debug_registers_callback):
10969 Use lwp_set_debug_registers_changed.
10970 (x86_linux_prepare_to_resume): Use lwp_debug_registers_changed
10971 and lwp_set_debug_registers_changed.
10972 (x86_linux_new_thread): Use lwp_set_debug_registers_changed.
10974 2015-03-24 Gary Benson <gbenson@redhat.com>
10976 * linux-low.h (linux_target_ops) <new_thread>: Changed signature.
10977 * linux-arm-low.c (arm_new_thread): Likewise.
10978 * linux-aarch64-low.c (aarch64_linux_new_thread): Likewise.
10979 * linux-mips-low.c (mips_linux_new_thread): Likewise.
10980 * linux-x86-low.c (x86_linux_new_thread): Likewise.
10981 * linux-low.c (add_lwp): Update the_low_target.new_thread call.
10983 2015-03-24 Gary Benson <gbenson@redhat.com>
10985 * linux-low.c (ptid_of_lwp): New function.
10986 (lwp_is_stopped): Likewise.
10987 (lwp_stop_reason): Likewise.
10988 * linux-x86-low.c (update_debug_registers_callback):
10989 Use lwp_is_stopped.
10990 (x86_linux_prepare_to_resume): Use ptid_of_lwp and
10993 2015-03-24 Gary Benson <gbenson@redhat.com>
10995 * linux-low.h (linux_stop_lwp): Remove declaration.
10997 2015-03-24 Gary Benson <gbenson@redhat.com>
10999 * linux-low.h: Include nat/linux-nat.h.
11000 * linux-low.c (iterate_over_lwps_args): New structure.
11001 (iterate_over_lwps_filter): New function.
11002 (iterate_over_lwps): Likewise.
11003 * linux-x86-low.c (update_debug_registers_callback):
11004 Update signature to what iterate_over_lwps expects.
11005 Remove PID check that iterate_over_lwps now performs.
11006 (x86_dr_low_set_addr): Use iterate_over_lwps.
11007 (x86_dr_low_set_control): Likewise.
11009 2015-03-24 Gary Benson <gbenson@redhat.com>
11011 * linux-x86-low.c (x86_debug_reg_state): New function.
11012 (x86_linux_prepare_to_resume): Use the above.
11014 2015-03-24 Gary Benson <gbenson@redhat.com>
11016 * linux-low.c (current_lwp_ptid): New function.
11017 * linux-x86-low.c: Include nat/linux-nat.h.
11018 (x86_dr_low_get_addr): Use current_lwp_ptid.
11019 (x86_dr_low_get_control): Likewise.
11020 (x86_dr_low_get_status): Likewise.
11022 2015-03-20 Pedro Alves <palves@redhat.com>
11024 * tracepoint.c (cmd_qtstatus): Make "str" const.
11026 2015-03-20 Pedro Alves <palves@redhat.com>
11028 * server.c (handle_general_set): Make "req_str" const.
11030 2015-03-19 Pedro Alves <palves@redhat.com>
11032 * linux-low.c (linux_resume_one_lwp): Rename to ...
11033 (linux_resume_one_lwp_throw): ... this. Don't handle ESRCH here,
11034 instead call perror_with_name.
11035 (check_ptrace_stopped_lwp_gone): New function.
11036 (linux_resume_one_lwp): Reimplement as wrapper around
11037 linux_resume_one_lwp_throw that swallows errors if the LWP is
11040 2015-03-19 Pedro Alves <palves@redhat.com>
11042 * linux-low.c (count_events_callback, select_event_lwp_callback):
11043 No longer check whether the thread has resume_stop as last resume
11046 2015-03-19 Pedro Alves <palves@redhat.com>
11048 * linux-low.c (count_events_callback, select_event_lwp_callback):
11049 Use the lwp's status_pending_p field, not the thread's.
11051 2015-03-19 Pedro Alves <palves@redhat.com>
11053 * linux-low.c (select_event_lwp_callback): Update comments to
11054 no longer mention SIGTRAP.
11056 2015-03-18 Gary Benson <gbenson@redhat.com>
11058 * server.c (handle_query): Do not report vFile:fstat as supported.
11060 2015-03-11 Gary Benson <gbenson@redhat.com>
11062 * hostio.c (sys/types.h): New include.
11063 (sys/stat.h): Likewise.
11064 (common-remote-fileio.h): Likewise.
11065 (handle_fstat): New function.
11066 (handle_vFile): Handle vFile:fstat packets.
11068 2015-03-11 Gary Benson <gbenson@redhat.com>
11070 * configure.ac (AC_CHECK_MEMBERS): Add checks for
11071 struct stat.st_blocks and struct stat.st_blksize.
11072 * configure: Regenerate.
11073 * config.in: Likewise.
11074 * Makefile.in (SFILES): Add common/common-remote-fileio.c.
11075 (OBS): Add common-remote-fileio.o.
11076 (common-remote-fileio.o): New rule.
11078 2015-03-09 Pedro Alves <palves@redhat.com>
11080 * tracepoint.c (gdb_agent_helper_thread): Cast '&sockaddr' to
11081 'struct sockaddr' pointer in 'accept' call.
11083 2015-03-09 Pedro Alves <palves@redhat.com>
11086 2015-03-07 Pedro Alves <palves@redhat.com>
11087 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
11088 or <winsock2.h> here. Instead include "gdb_socket.h".
11089 (remote_open): Use union gdb_sockaddr_u.
11090 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
11091 or <winsock2.h> here. Instead include "gdb_socket.h".
11092 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
11093 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
11095 (init_named_socket, gdb_agent_helper_thread): Use union
11098 2015-03-07 Pedro Alves <palves@redhat.com>
11100 * configure.ac (build_warnings): Move
11101 -Wdeclaration-after-statement to the C-specific set.
11102 * configure: Regenerate.
11104 2015-03-07 Pedro Alves <palves@redhat.com>
11106 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
11107 or <winsock2.h> here. Instead include "gdb_socket.h".
11108 (remote_open): Use union gdb_sockaddr_u.
11109 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
11110 or <winsock2.h> here. Instead include "gdb_socket.h".
11111 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
11112 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
11114 (init_named_socket, gdb_agent_helper_thread): Use union
11117 2015-03-07 Pedro Alves <palves@redhat.com>
11119 Adjust all callers of TRY_CATCH to use TRY/CATCH/END_CATCH
11122 2015-03-06 Yao Qi <yao.qi@linaro.org>
11124 * linux-aarch64-low.c (aarch64_insert_point): Use
11125 show_debug_regs as a boolean.
11126 (aarch64_remove_point): Likewise.
11128 2015-03-05 Pedro Alves <palves@redhat.com>
11130 * lynx-low.c (lynx_target_ops): Install NULL hooks for
11131 stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
11132 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint.
11133 * nto-low.c (nto_target_ops): Likewise.
11134 * spu-low.c (spu_target_ops): Likewise.
11135 * win32-low.c (win32_target_ops): Likewise.
11137 2015-03-04 Pedro Alves <palves@redhat.com>
11139 * linux-low.c (check_stopped_by_breakpoint) [USE_SIGTRAP_SIGINFO]:
11140 Decide whether a breakpoint triggered based on the SIGTRAP's
11142 (thread_still_has_status_pending_p) [USE_SIGTRAP_SIGINFO]: Don't check whether a
11143 breakpoint is inserted if relying on SIGTRAP's siginfo.si_code.
11144 (linux_low_filter_event): Check for breakpoints before checking
11146 (linux_wait_1): Don't re-increment the PC if relying on SIGTRAP's
11148 (linux_stopped_by_sw_breakpoint)
11149 (linux_supports_stopped_by_sw_breakpoint)
11150 (linux_stopped_by_hw_breakpoint)
11151 (linux_supports_stopped_by_hw_breakpoint): New functions.
11152 (linux_target_ops): Install new target methods.
11154 2015-03-04 Pedro Alves <palves@redhat.com>
11156 * remote-utils.c (prepare_resume_reply): Report swbreak/hbreak.
11157 * server.c (swbreak_feature, hwbreak_feature): New globals.
11158 (handle_query) <qSupported>: Handle "swbreak+" and "hwbreak+".
11159 (captured_main): Clear swbreak_feature and hwbreak_feature.
11160 * server.h (swbreak_feature, hwbreak_feature): Declare.
11161 * target.h (struct target_ops) <stopped_by_sw_breakpoint,
11162 supports_stopped_by_sw_breakpoint, stopped_by_hw_breakpoint,
11163 supports_stopped_by_hw_breakpoint>: New fields.
11164 (target_supports_stopped_by_sw_breakpoint)
11165 (target_stopped_by_sw_breakpoint)
11166 (target_supports_stopped_by_hw_breakpoint)
11167 (target_stopped_by_hw_breakpoint): Declare.
11169 2015-03-04 Pedro Alves <palves@redhat.com>
11171 enum lwp_stop_reason -> enum target_stop_reason
11172 * linux-low.c (check_stopped_by_breakpoint): Adjust.
11173 (thread_still_has_status_pending_p, check_stopped_by_watchpoint)
11174 (linux_wait_1, stuck_in_jump_pad_callback)
11175 (move_out_of_jump_pad_callback, linux_resume_one_lwp)
11176 (linux_stopped_by_watchpoint):
11177 * linux-low.h (enum lwp_stop_reason): Delete.
11178 (struct lwp_info) <stop_reason>: Now an enum target_stop_reason.
11179 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
11181 2015-03-04 Yao Qi <yao.qi@linaro.org>
11183 * Makefile.in (SFILES): Add linux-aarch64-low.c.
11185 2015-03-03 Gary Benson <gbenson@redhat.com>
11187 * hostio.c (handle_vFile): Fix prefix lengths.
11189 2015-03-03 Markus Metzger <markus.t.metzger@intel.com>
11191 * linux-low.c (linux_low_enable_btrace): Do not overwrite non-zero
11194 2015-03-02 Andreas Arnez <arnez@linux.vnet.ibm.com>
11196 * Makefile.in (s390-vx-linux64.c, s390-tevx-linux64.c)
11197 (s390x-vx-linux64.c, s390x-tevx-linux64.c): New rules.
11198 (clean): Add "rm -f" for above C files.
11199 * configure.srv (srv_regobj): Add s390-vx-linux64.o,
11200 s390-tevx-linux64.o, s390x-vx-linux64.o, and s390x-tevx-linux64.o.
11201 (srv_xmlfiles): Add s390-vx-linux64.xml, s390-tevx-linux64.xml,
11202 s390x-vx-linux64.xml, s390x-tevx-linux64.xml, and s390-vx.xml.
11203 * linux-s390-low.c (HWCAP_S390_VX): New macro.
11204 (init_registers_s390_vx_linux64, init_registers_s390_tevx_linux64)
11205 (init_registers_s390x_vx_linux64)
11206 (init_registers_s390x_tevx_linux64)
11207 (tdesc_s390_vx_linux64, tdesc_s390_tevx_linux64)
11208 (tdesc_s390x_vx_linux64, tdesc_s390x_tevx_linux64): New extern
11210 (s390_fill_vxrs_low, s390_store_vxrs_low, s390_fill_vxrs_high)
11211 (s390_store_vxrs_high): New functions.
11212 (s390_regsets): Add entries for NT_S390_VXRS_LOW and
11214 (s390_arch_setup): Add logic for selecting one of the new target
11215 descriptions. Activate the new vector regsets if applicable.
11216 (initialize_low_arch): Also invoke init_registers_s390_vx_linux64,
11217 init_registers_s390_tevx_linux64, init_registers_s390x_vx_linux64,
11218 and init_registers_s390x_tevx_linux64.
11220 2015-03-01 Pedro Alves <palves@redhat.com>
11222 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Constify 'raw_regs'
11225 2015-02-27 Pedro Alves <palves@redhat.com>
11227 * linux-x86-low.c (u_debugreg_offset): New function.
11228 (x86_linux_dr_get, x86_linux_dr_set): Use it.
11230 2015-02-27 Pedro Alves <palves@redhat.com>
11232 * gdb_proc_service.h: Wrap with EXTERN_C_PUSH/EXTERN_C_POP.
11233 [!HAVE_PROC_SERVICE_H] (struct ps_prochandle): Forward declare.
11234 [!HAVE_PROC_SERVICE_H] (ps_pdread, ps_pdwrite, ps_ptread)
11235 ps_ptwrite, ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
11236 (ps_lsetfpregs, ps_getpid)
11237 (ps_get_thread_area, ps_pglobal_lookup, ps_pstop, ps_pcontinue)
11238 (ps_lstop, ps_lcontinue, ps_lgetxregsize, ps_lgetxregs)
11239 (ps_lsetxregs, ps_plog): Declare.
11241 2015-02-27 Pedro Alves <palves@redhat.com>
11243 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Use
11244 IP_AGENT_EXPORT_FUNC.
11245 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Use
11246 IP_AGENT_EXPORT_FUNC.
11247 * tracepoint.c (ATTR_USED, ATTR_NOINLINE, ATTR_CONSTRUCTOR)
11248 (IP_AGENT_EXPORT): Delete.
11249 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
11250 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
11251 (gdb_trampoline_buffer_error, collecting, gdb_collect)
11252 (stop_tracing, flush_trace_buffer, about_to_request_buffer_space)
11253 (trace_buffer_is_full, stopping_tracepoint, expr_eval_result)
11254 (error_tracepoint, tracepoints, tracing, trace_buffer_ctrl)
11255 (trace_buffer_ctrl_curr, trace_buffer_lo, trace_buffer_hi)
11256 (traceframe_read_count, traceframe_write_count)
11257 (traceframes_created, trace_state_variables, get_raw_reg)
11258 (get_trace_state_variable_value, set_trace_state_variable_value)
11259 (ust_loaded, helper_thread_id, cmd_buf): Use
11260 IPA_SYM_EXPORTED_NAME.
11261 (stop_tracing, flush_trace_buffer): Use IP_AGENT_EXPORT_FUNC.
11262 (tracepoints) Use IP_AGENT_EXPORT_VAR.
11263 (stopping_tracepoint, trace_buffer_is_full, expr_eval_result): Use
11264 IP_AGENT_EXPORT_VAR and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
11265 (last_tracepoint): Move into !IN_PROCESS_AGENT block.
11266 (error_tracepoint): Use IP_AGENT_EXPORT_VAR and wrap in
11267 EXTERN_C_PUSH/EXTERN_C_POP.
11268 (trace_state_variables): Use IP_AGENT_EXPORT_VAR.
11269 (trace_buffer_lo, trace_buffer_hi): Use IP_AGENT_EXPORT_VAR and
11270 wrap in EXTERN_C_PUSH/EXTERN_C_POP.
11271 (trace_buffer_ctrl, trace_buffer_ctrl_curr)
11272 (traceframe_write_count, traceframe_read_count)
11273 (traceframes_created, tracing): Use IP_AGENT_EXPORT_VAR.
11274 (about_to_request_buffer_space, get_trace_state_variable_value)
11275 (set_trace_state_variable_value): Use IP_AGENT_EXPORT_FUNC.
11276 (collecting): Use IP_AGENT_EXPORT_VAR and wrap in
11277 EXTERN_C_PUSH/EXTERN_C_POP.
11278 (gdb_collect): Use IP_AGENT_EXPORT_FUNC.
11279 (ust_loaded, cmd_buf): Use IP_AGENT_EXPORT_VAR.
11280 (helper_thread_id, gdb_agent_capability): Use IP_AGENT_EXPORT_VAR
11281 and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
11282 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
11283 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
11284 (gdb_trampoline_buffer_error): Use IP_AGENT_EXPORT_VAR.
11285 * tracepoint.h (ATTR_USED, ATTR_NOINLINE, EXPORTED_SYMBOL):
11287 (IP_AGENT_EXPORT_FUNC, IP_AGENT_EXPORT_VAR)
11288 (IP_AGENT_EXPORT_VAR_DECL): Define.
11289 (tracing): Declare.
11290 (gdb_agent_get_raw_reg): Declare.
11292 2015-02-27 Tom Tromey <tromey@redhat.com>
11293 Pedro Alves <palves@redhat.com>
11295 Rename symbols whose names are reserved C++ keywords throughout.
11297 2015-02-27 Pedro Alves <palves@redhat.com>
11299 * Makefile.in (COMPILER): New, get it from autoconf.
11300 (CXX): Get from autoconf instead.
11301 (COMPILE.pre): Use COMPILER.
11302 (CC-LD): Rename to ...
11303 (CC_LD): ... this. Use COMPILER.
11304 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT), $(IPA_LIB)): Adjust.
11305 (CXX_FOR_TARGET): Default to g++ instead of gcc.
11306 * acinclude.m4: Include build-with-cxx.m4.
11307 * configure.ac: Call AC_PROG_CXX and GDB_AC_BUILD_WITH_CXX.
11308 Disable -Werror by default if building in C++ mode.
11309 (build_warnings): Add -Wno-sign-compare, -Wno-write-strings and
11310 -Wno-narrowing in C++ mode. Run supported-warning-flags tests with
11311 the C++ compiler. Save/restore CXXFLAGS too.
11312 * configure: Regenerate.
11314 2015-02-27 Pedro Alves <palves@redhat.com>
11316 * acinclude.m4: Include libiberty.m4.
11317 * configure.ac: Call libiberty_INIT.
11318 * config.in, configure: Regenerate.
11320 2015-02-26 Pedro Alves <palves@redhat.com>
11322 * linux-low.c (linux_wait_1): When incrementing the PC past a
11323 program breakpoint always use the_low_target.breakpoint_len as
11324 increment, rather than the maximum between that and
11325 the_low_target.decr_pc_after_break.
11327 2015-02-23 Pedro Alves <palves@redhat.com>
11329 * linux-low.c (check_stopped_by_breakpoint): Don't check if the
11330 thread was doing a step-over; always adjust the PC if
11331 we stepped over a permanent breakpoint.
11332 (linux_wait_1): If we stepped over breakpoint that was on top of a
11333 permanent breakpoint, manually advance the PC past it.
11335 2015-02-23 Pedro Alves <palves@redhat.com>
11337 * linux-x86-low.c (REGSIZE): Define in both 32-bit and 64-bit
11339 (x86_fill_gregset, x86_store_gregset): Use it when handling
11342 2015-02-20 Pedro Alves <palves@redhat.com>
11344 * thread-db.c: Include "nat/linux-procfs.h".
11345 (thread_db_init): Skip listing new threads if the kernel supports
11346 PTRACE_EVENT_CLONE and /proc/PID/task/ is accessible.
11348 2015-02-20 Pedro Alves <palves@redhat.com>
11350 * linux-low.c (status_pending_p_callback): Use ptid_match.
11352 2015-02-19 Antoine Tremblay <antoine.tremblay@ericsson.com>
11354 PR breakpoints/16812
11355 * linux-low.c (wstatus_maybe_breakpoint): Remove.
11356 (linux_low_filter_event): Update wstatus_maybe_breakpoint name.
11357 (linux_wait_1): Report SIGTRAP,SIGILL,SIGSEGV.
11359 2015-02-10 Antoine Tremblay <antoine.tremblay@ericsson.com>
11361 PR breakpoints/15956
11362 * tracepoint.c (cmd_qtinit): Add check for current_thread.
11364 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
11366 * linux-low.c (linux_low_btrace_conf): Print size.
11367 * server.c (handle_btrace_conf_general_set): New.
11368 (hanle_general_set): Call handle_btrace_conf_general_set.
11369 (handle_query): Report Qbtrace-conf:bts:size as supported.
11371 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
11373 * linux-low.c (linux_low_enable_btrace): Update parameters.
11374 (linux_low_btrace_conf): New.
11375 (linux_target_ops)<to_btrace_conf>: Initialize.
11376 * server.c (current_btrace_conf): New.
11377 (handle_btrace_enable): Rename to ...
11378 (handle_btrace_enable_bts): ... this. Pass ¤t_btrace_conf
11379 to target_enable_btrace. Update comment. Update users.
11380 (handle_qxfer_btrace_conf): New.
11381 (qxfer_packets): Add btrace-conf entry.
11382 (handle_query): Report qXfer:btrace-conf:read as supported packet.
11383 * target.h (target_ops)<enable_btrace>: Update parameters and comment.
11384 (target_ops)<read_btrace_conf>: New.
11385 (target_enable_btrace): Update parameters.
11386 (target_read_btrace_conf): New.
11388 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
11390 * server.c (handle_btrace_general_set): Remove call to
11391 target_supports_btrace.
11392 (supported_btrace_packets): New.
11393 (handle_query): Call supported_btrace_packets.
11394 * target.h: include btrace-common.h.
11395 (btrace_target_info): Removed.
11396 (supports_btrace, target_supports_btrace): Update parameters.
11398 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
11400 * Makefile.in (SFILES): Add common/btrace-common.c.
11401 (OBS): Add common/btrace-common.o.
11402 (btrace-common.o): Add build rules.
11403 * linux-low: Include btrace-common.h.
11404 (linux_low_read_btrace): Use struct btrace_data. Call
11405 btrace_data_init and btrace_data_fini.
11407 2015-02-06 Pedro Alves <palves@redhat.com>
11409 * thread-db.c (find_new_threads_callback): Add debug output.
11411 2015-02-04 Pedro Alves <palves@redhat.com>
11413 * linux-low.c (handle_extended_wait): Don't resume LWPs here.
11414 (resume_stopped_resumed_lwps): New function.
11415 (linux_wait_for_event_filtered): Use it.
11417 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
11419 * Makefile.in (SFILES): Add linux-personality.c.
11420 (linux-personality.o): New rule.
11421 * configure.srv (srv_linux_obj): Add linux-personality.o to the
11422 list of objects to be built.
11423 * linux-low.c: Include nat/linux-personality.h.
11424 (linux_create_inferior): Remove code to disable address space
11425 randomization (moved to ../nat/linux-personality.c). Create
11426 cleanup to disable address space randomization.
11428 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
11430 * Makefile.in (posix-strerror.o): New rule.
11431 (mingw-strerror.o): Likewise.
11432 * configure: Regenerated.
11433 * configure.ac: Source file ../common/common.host. Initialize new
11434 variable srv_host_obs. Add srv_host_obs to GDBSERVER_DEPFILES.
11436 2015-01-14 Yao Qi <yao@codesourcery.com>
11438 * Makefile.in (SFILES): Add nat/ppc-linux.c.
11439 (ppc-linux.o): New rule.
11440 * configure.srv (powerpc*-*-linux*): Add ppc-linux.o.
11441 * configure.ac: AC_CHECK_FUNCS(getauxval).
11442 * config.in: Re-generated.
11443 * configure: Re-generated.
11444 * linux-ppc-low.c (ppc_arch_setup) [__powerpc64__]: Call
11445 ppc64_64bit_inferior_p
11447 2015-01-14 Yao Qi <yao@codesourcery.com>
11449 * linux-ppc-low.c: Include "nat/ppc-linux.h".
11450 (PPC_FEATURE_HAS_VSX): Move to nat/ppc-linux.h.
11451 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Likewise.
11452 (PT_ORIG_R3, PT_TRAP): Likewise.
11453 (PTRACE_GETVSXREGS, PTRACE_SETVSXREGS): Likewise.
11454 (PTRACE_GETVRREGS, PTRACE_SETVRREGS): Likewise.
11455 (PTRACE_GETEVRREGS, PTRACE_SETEVRREGS): Likewise.
11457 2015-01-10 Joel Brobecker <brobecker@adacore.com>
11459 * i387-fp.c (i387_cache_to_xsave): In look over
11460 num_avx512_zmmh_high_registers, replace use of struct i387_xsave
11461 zmmh_low_space field by use of zmmh_high_space.
11463 2015-01-09 Pedro Alves <palves@redhat.com>
11465 * linux-low.c (step_over_bkpt): Move higher up in the file.
11466 (handle_extended_wait): Don't store the stop_pc here.
11467 (get_stop_pc): Adjust comments and rename to ...
11468 (check_stopped_by_breakpoint): ... this. Record whether the LWP
11469 stopped for a software breakpoint or hardware breakpoint.
11470 (thread_still_has_status_pending_p): New function.
11471 (status_pending_p_callback): Use
11472 thread_still_has_status_pending_p. If the event is no longer
11473 interesting, resume the LWP.
11474 (handle_tracepoints): Add assert.
11475 (maybe_move_out_of_jump_pad): Remove cancel_breakpoints call.
11476 (wstatus_maybe_breakpoint): New function.
11477 (cancel_breakpoint): Delete function.
11478 (check_stopped_by_watchpoint): New function, factored out from
11479 linux_low_filter_event.
11480 (lp_status_maybe_breakpoint): Delete function.
11481 (linux_low_filter_event): Remove filter_ptid argument.
11482 Leave thread group exits pending here. Store the LWP's stop PC.
11483 Always leave events pending.
11484 (linux_wait_for_event_filtered): Pull all events out of the
11485 kernel, and leave them all pending.
11486 (count_events_callback, select_event_lwp_callback): Consider all
11488 (cancel_breakpoints_callback, linux_cancel_breakpoints): Delete.
11489 (select_event_lwp): Only give preference to the stepping LWP in
11490 all-stop mode. Adjust comments.
11491 (ignore_event): New function.
11492 (linux_wait_1): Delete 'retry' label. Use ignore_event. Remove
11493 references to cancel_breakpoints. Adjust to renames. Also give
11494 equal priority to all LWPs that have had events in non-stop mode.
11495 If reporting a software breakpoint event, unadjust the LWP's PC.
11496 (linux_wait): If linux_wait_1 returned an ignored event, retry.
11497 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback):
11499 (linux_resume_one_lwp): Store the LWP's PC. Adjust.
11500 (resume_status_pending_p): Use thread_still_has_status_pending_p.
11501 (linux_stopped_by_watchpoint): Adjust.
11502 (linux_target_ops): Remove reference to linux_cancel_breakpoints.
11503 * linux-low.h (enum lwp_stop_reason): New.
11504 (struct lwp_info) <stop_pc>: Adjust comment.
11505 <stopped_by_watchpoint>: Delete field.
11506 <stop_reason>: New field.
11507 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
11508 * mem-break.c (software_breakpoint_inserted_here)
11509 (hardware_breakpoint_inserted_here): New function.
11510 * mem-break.h (software_breakpoint_inserted_here)
11511 (hardware_breakpoint_inserted_here): Declare.
11512 * target.h (struct target_ops) <cancel_breakpoints>: Remove field.
11513 (cancel_breakpoints): Delete.
11514 * tracepoint.c (clear_installed_tracepoints, stop_tracing)
11515 (upload_fast_traceframes): Remove references to
11516 cancel_breakpoints.
11518 2015-01-09 Pedro Alves <palves@redhat.com>
11520 * thread-db.c (find_new_threads_callback): Ignore thread if the
11521 kernel thread ID is -1.
11523 2015-01-09 Pedro Alves <palves@redhat.com>
11525 * linux-low.c (linux_attach_fail_reason_string): Move to
11526 nat/linux-ptrace.c, and rename.
11527 (linux_attach_lwp): Update comment.
11528 (attach_proc_task_lwp_callback): New function.
11529 (linux_attach): Adjust to rename and use
11530 linux_proc_attach_tgid_threads.
11531 (linux_attach_fail_reason_string): Delete declaration.
11533 2015-01-01 Joel Brobecker <brobecker@adacore.com>
11535 * gdbreplay.c (gdbreplay_version): Update copyright year to 2015.
11536 * server.c (gdbserver_version): Likewise.
11538 2014-12-29 Sergio Durigan Junior <sergiodj@redhat.com>
11540 * remote-utils.c: Include ctype.h.
11541 (input_interrupt): Explicitly handle the case when the char
11542 received is the NUL byte. Improve the printing of non-ASCII
11545 2014-12-16 Joel Brobecker <brobecker@adacore.com>
11547 * linux-low.c (linux_low_filter_event): Update call to
11548 linux_enable_event_reporting following the addition of
11549 a new parameter to that function.
11551 2014-12-16 Catalin Udma <catalin.udma@freescale.com>
11554 * linux-aarch64-low.c (AARCH64_FPSR_REGNO): New define.
11555 (AARCH64_FPCR_REGNO): Likewise.
11556 (AARCH64_NUM_REGS): Update to include fpsr/fpcr registers.
11557 (aarch64_fill_fpregset): Add missing fpsr/fpcr registers.
11558 (aarch64_store_fpregset): Likewise.
11560 2014-12-15 Joel Brobecker <brobecker@adacore.com>
11562 * lynx-low.c (lynx_resume): Use PTRACE_SINGLESTEP_ONE if N == 1.
11563 Remove FIXME comment about assumption about N.
11565 2014-12-13 Joel Brobecker <brobecker@adacore.com>
11567 * configure.ac: If large-file support is disabled in GDBserver,
11568 pass --disable-largefile to ACX_CONFIGURE_DIR call for "gnulib".
11569 * configure: Regenerate.
11571 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
11573 * linux-low.c (regsets_fetch_inferior_registers): Suppress the
11574 warning upon ENODATA from ptrace.
11575 * linux-s390-low.c (s390_store_tdb): New.
11576 (s390_regsets): Add regset for NT_S390_TDB.
11578 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
11580 * linux-low.c (regsets_store_inferior_registers): Skip regsets
11581 without a fill_function.
11582 * linux-s390-low.c (s390_fill_last_break): Remove.
11583 (s390_regsets): Set fill_function to NULL for NT_S390_LAST_BREAK.
11584 (s390_arch_setup): Use regset's size instead of fill_function for
11585 loop end condition.
11587 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
11589 * linux-low.c (regsets_fetch_inferior_registers): Do not invoke
11590 the regset's store function when ptrace returned an error.
11591 * regcache.c (get_thread_regcache): Invalidate register cache
11592 before fetching inferior's registers.
11594 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
11596 * linux-low.c (regsets_fetch_inferior_registers): Rephrase
11597 while-loop as for-loop.
11598 (regsets_store_inferior_registers): Likewise.
11600 2014-11-28 Yao Qi <yao@codesourcery.com>
11602 * configure.ac(AC_CHECK_FUNCS): Remove readlink.
11603 * config.in, configure: Re-generate.
11604 * hostio.c (handle_unlink): Remove code checking HAVE_READLINK
11607 2014-11-21 Yao Qi <yao@codesourcery.com>
11609 * configure.ac: Don't invoke AC_FUNC_ALLOCA.
11610 (AC_CHECK_HEADERS): Remove malloc.h.
11611 * configure: Re-generated.
11612 * config.in: Re-generated.
11613 * server.h: Don't include alloca.h and malloc.h.
11614 * gdbreplay.c: Don't check HAVE_ALLOCA_H is defined.
11615 Don't include malloc.h.
11617 2014-11-17 Joel Brobecker <brobecker@adacore.com>
11619 * lynx-low.c (lynx_write_memory): Put lynx_read_memory and
11620 corresponding ERRNO check in same block.
11622 2014-11-12 Pedro Alves <palves@redhat.com>
11624 * server.c (cont_thread): Update comment.
11625 (start_inferior, attach_inferior): No longer clear cont_thread.
11626 (handle_v_cont): No longer set cont_thread.
11627 (captured_main): Clear cont_thread each time a GDB connects.
11629 2014-11-12 Pedro Alves <palves@redhat.com>
11631 * linux-low.c (linux_wait_1): Don't force a wait for the Hc
11632 thread, and don't resume all threads if the Hc thread has exited.
11634 2014-11-12 Pedro Alves <palves@redhat.com>
11636 * linux-low.c (linux_request_interrupt): Always send a SIGINT to
11637 the process group instead of to a specific LWP.
11639 2014-10-15 Pedro Alves <palves@redhat.com>
11642 * win32-arm-low.c (arm_set_thread_context): Remove current_event
11644 (arm_set_thread_context): Delete.
11645 (the_low_target): Adjust.
11646 * win32-i386-low.c (debug_registers_changed)
11647 (debug_registers_used): Delete.
11648 (update_debug_registers_callback): New function.
11649 (x86_dr_low_set_addr, x86_dr_low_set_control): Mark all threads as
11650 needing to update their debug registers.
11651 (win32_get_current_dr): New function.
11652 (x86_dr_low_get_addr, x86_dr_low_get_control)
11653 (x86_dr_low_get_status): Fetch the debug register from the thread
11655 (i386_initial_stuff): Adjust.
11656 (i386_get_thread_context): Remove current_event parameter. Don't
11657 clear debug_registers_changed nor copy DR values to
11659 (i386_set_thread_context): Delete.
11660 (i386_prepare_to_resume): New function.
11661 (i386_thread_added): Mark the thread as needing to update irs
11663 (the_low_target): Remove i386_set_thread_context and install
11664 i386_prepare_to_resume.
11665 * win32-low.c (win32_get_thread_context): Adjust.
11666 (win32_set_thread_context): Use SetThreadContext
11668 (win32_prepare_to_resume): New function.
11669 (win32_require_context): New function, factored out from ...
11670 (thread_rec): ... this.
11671 (continue_one_thread): Call win32_prepare_to_resume on each thread
11672 we're about to continue.
11673 (win32_resume): Call win32_prepare_to_resume on the event thread.
11674 * win32-low.h (struct win32_thread_info)
11675 <debug_registers_changed>: New field.
11676 (struct win32_target_ops): Change prototype of set_thread_context,
11677 delete set_thread_context and add prepare_to_resume.
11678 (win32_require_context): New declaration.
11680 2014-10-08 Gary Benson <gbenson@redhat.com>
11682 * server.h: Do not include common-exceptions.h.
11684 2014-10-08 Gary Benson <gbenson@redhat.com>
11686 * server.h: Do not include cleanups.h.
11688 2014-09-30 James Hogan <james.hogan@imgtec.com>
11690 * Makefile.in (clean): Add rm -f commands for mips-dsp-linux.c and
11691 mips64-dsp-linux.c.
11693 2014-09-23 Yao Qi <yao@codesourcery.com>
11695 * linux-low.c (lp_status_maybe_breakpoint): New function.
11696 (linux_low_filter_event): Call lp_status_maybe_breakpoint.
11697 (count_events_callback): Likewise.
11698 (select_event_lwp_callback): Likewise.
11699 (cancel_breakpoints_callback): Likewise.
11701 2014-09-19 Don Breazeal <donb@codesourcery.com>
11703 * linux-low.c (handle_extended_wait): Call
11704 linux_ptrace_get_extended_event.
11705 (get_stop_pc, get_detach_signal, linux_low_filter_event): Call
11706 linux_is_extended_waitstatus.
11708 2014-09-16 Joel Brobecker <brobecker@adacore.com>
11710 * Makefile.in (CPPFLAGS): Define.
11711 (INTERNAL_CFLAGS_BASE): Add ${CPPFLAGS}.
11712 (IPAGENT_CFLAGS): Remove ${CPPFLAGS}.
11714 2014-09-16 Gary Benson <gbenson@redhat.com>
11716 * inferiors.h (current_inferior): Renamed as...
11717 (current_thread): New variable. All uses updated.
11718 * linux-low.c (get_pc): Renamed saved_inferior as saved_thread.
11719 (maybe_move_out_of_jump_pad): Likewise.
11720 (cancel_breakpoint): Likewise.
11721 (linux_low_filter_event): Likewise.
11722 (wait_for_sigstop): Likewise.
11723 (linux_resume_one_lwp): Likewise.
11724 (need_step_over_p): Likewise.
11725 (start_step_over): Likewise.
11726 (linux_stabilize_threads): Renamed save_inferior as saved_thread.
11727 * linux-x86-low.c (x86_linux_update_xmltarget): Likewise.
11728 * proc-service.c (ps_lgetregs): Renamed reg_inferior as reg_thread
11729 and save_inferior as saved_thread.
11730 * regcache.c (get_thread_regcache): Renamed saved_inferior as
11732 (regcache_invalidate_thread): Likewise.
11733 * remote-utils.c (prepare_resume_reply): Likewise.
11734 * thread-db.c (thread_db_get_tls_address): Likewise.
11735 (disable_thread_event_reporting): Likewise.
11736 (remove_thread_event_breakpoints): Likewise.
11737 * tracepoint.c (gdb_agent_about_to_close): Renamed save_inferior
11739 * target.h (set_desired_inferior): Renamed as...
11740 (set_desired_thread): New declaration. All uses updated.
11741 * server.c (myresume): Updated comment to reference thread instead
11743 (handle_serial_event): Likewise.
11744 (handle_target_event): Likewise.
11746 2014-09-12 Tom Tromey <tromey@redhat.com>
11747 Gary Benson <gbenson@redhat.com>
11749 * regcache.h: Include common-regcache.h.
11750 (regcache_read_pc): Don't declare.
11751 * regcache.c (get_thread_regcache_for_ptid): New function.
11753 2014-09-11 Tom Tromey <tromey@redhat.com>
11754 Gary Benson <gbenson@redhat.com>
11756 * symbol.c: New file.
11757 * Makefile.in (SFILES): Add symbol.c.
11758 (OBS): Add symbol.o.
11760 2014-09-11 Gary Benson <gbenson@redhat.com>
11762 * target.c (target_stop_ptid, target_continue_ptid): New
11765 2014-09-11 Tom Tromey <tromey@redhat.com>
11766 Gary Benson <gbenson@redhat.com>
11768 * target.h: Include target/target.h.
11769 * target.c (target_read_memory, target_read_uint32)
11770 (target_write_memory): New functions.
11772 2014-09-11 Gary Benson <gbenson@redhat.com>
11774 * server.h (debug_hw_points): Don't declare.
11775 * server.c (debug_hw_points): Don't define. Replace all uses
11776 with show_debug_regs.
11777 * linux-aarch64-low.c (debug_hw_points): Don't define. Replace
11778 all uses with show_debug_regs.
11780 2014-09-08 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
11782 * linux-ppc-low.c (ppc_collect_ptrace_register): Adjust routine to take
11783 endianness into account.
11784 (ppc_supply_ptrace_register): Likewise.
11786 2014-09-03 James Hogan <james.hogan@imgtec.com>
11788 * linux-mips-low.c (mips_read_description): Reset errno to 0 prior
11789 to reading DSP_CONTROL with PTRACE_PEEKUSER ptrace call.
11791 2014-09-03 Gary Benson <gbenson@redhat.com>
11793 * linux-x86-low.c (x86_linux_prepare_to_resume): Use
11794 ALL_DEBUG_ADDRESS_REGISTERS.
11796 2014-09-02 Gary Benson <gbenson@redhat.com>
11798 * i386-low.h: Renamed as...
11799 * x86-low.h: New file. All type, function and variable name
11800 prefixes changed from "i386_" to "x86_". All references updated.
11801 * i386-low.c: Renamed as...
11802 * x86-low.c: New file. All type, function and variable name
11803 prefixes changed from "i386_" to "x86_". All references updated.
11805 2014-09-02 Gary Benson <gbenson@redhat.com>
11807 * linux-x86-low.c (x86_linux_new_process): Use XCNEW.
11808 (x86_linux_new_thread): Likewise.
11810 2014-08-29 Gary Benson <gbenson@redhat.com>
11812 * server.h (setjmp.h): Do not include.
11813 (toplevel): Do not declare.
11814 (common-exceptions.h): Include.
11815 (cleanups.h): Likewise.
11816 * server.c (toplevel): Do not define.
11817 (exit_code): New static global.
11818 (detach_or_kill_for_exit_cleanup): New function.
11819 (main): New function. Original main renamed to...
11820 (captured_main): New function.
11821 * utils.c (verror) [!IN_PROCESS_AGENT]: Use throw_verror.
11823 2014-08-29 Gary Benson <gbenson@redhat.com>
11825 * Makefile.in (SFILES): Add common/common-exceptions.c.
11826 (OBS): Add common-exceptions.o.
11827 (common-exceptions.o): New rule.
11828 * utils.c (prepare_to_throw_exception): New function.
11830 2014-08-29 Gary Benson <gbenson@redhat.com>
11832 * config.in: Regenerate.
11833 * configure: Likewise.
11835 2014-08-29 Gary Benson <gbenson@redhat.com>
11837 * Makefile.in (SFILES): Add common/cleanups.c.
11839 (cleanups.o): New rule.
11841 2014-08-29 Gary Benson <gbenson@redhat.com>
11843 * utils.c (internal_vwarning): New function.
11845 2014-08-28 Gary Benson <gbenson@redhat.com>
11847 * utils.h (fatal): Remove declaration.
11848 * utils.c (fatal): Remove function.
11850 2014-08-28 Gary Benson <gbenson@redhat.com>
11852 * tracepoint.c (gdb_agent_init): Replace fatal with
11854 (initialize_tracepoint): Likewise.
11856 2014-08-28 Gary Benson <gbenson@redhat.com>
11858 * remote-utils.c (remote_prepare): Replace fatal with error.
11860 2014-08-28 Gary Benson <gbenson@redhat.com>
11862 * linux-low.c (linux_async): Replace fatal with warning.
11863 Tidy up and return.
11864 (linux_start_non_stop): Return -1 if linux_async failed.
11866 2014-08-28 Gary Benson <gbenson@redhat.com>
11868 * linux-x86-low.c (i386_dr_low_set_addr): Replace check with
11870 (i386_dr_low_get_addr): Remove vague comment.
11871 * win32-i386-low.c (i386_dr_low_set_addr): Replace check with
11874 2014-08-28 Gary Benson <gbenson@redhat.com>
11876 * inferiors.c (get_thread_process): Replace check with gdb_assert.
11877 * linux-low.c (linux_wait_for_event_filtered): Replace fatal with
11879 (linux_resume_one_lwp): Likewise.
11880 * linux-x86-low.c (x86_siginfo_fixup): Replace checks with
11882 * mem-break.c (raw_bkpt_type_to_target_hw_bp_type): Replace fatal
11883 with internal_error.
11884 * regcache.c (get_thread_regcache): Replace check with gdb_assert.
11885 (init_register_cache): Replace fatal with gdb_assert_not_reached.
11886 (find_register_by_name): Replace fatal with internal_error.
11887 (find_regno): Likewise.
11888 * tdesc.c (init_target_desc): Replace check with gdb_assert.
11889 * thread-db.c (thread_db_create_event): Likewise.
11890 (thread_db_load_search): Likewise.
11891 (try_thread_db_load_1): Likewise.
11892 * tracepoint.c (get_jump_space_head): Replace fatal with
11894 (claim_trampoline_space): Likewise.
11895 (have_fast_tracepoint_trampoline_buffer): Likewise.
11896 (cmd_qtstart): Likewise.
11897 (stop_tracing): Likewise.
11898 (fast_tracepoint_collecting): Likewise.
11899 (target_malloc): Likewise.
11900 (download_tracepoint): Likewise.
11901 (download_trace_state_variables): Replace check with gdb_assert.
11902 (upload_fast_traceframes): Replace fatal with internal_error.
11904 2014-08-19 Tom Tromey <tromey@redhat.com>
11905 Gary Benson <gbenson@redhat.com>
11907 * Makefile.in (SFILES): Add common/common-debug.c.
11908 (OBS): Add common-debug.o.
11909 (common-debug.o): New rule.
11910 * debug.h (debug_printf): Don't declare.
11911 * debug.c (debug_printf): Renamed and rewritten as...
11912 (debug_vprintf): New function.
11914 2014-08-19 Gary Benson <gbenson@redhat.com>
11916 * utils.h: Do not include print-utils.h.
11918 2014-08-19 Tom Tromey <tromey@redhat.com>
11919 Gary Benson <gbenson@redhat.com>
11921 * server.h: Add static assertion.
11922 (gdb_byte, CORE_ADDR, LONGEST, ULONGEST): Remove.
11924 2014-08-19 Tom Tromey <tromey@redhat.com>
11925 Gary Benson <gbenson@redhat.com>
11927 * Makefile.in (SFILES): Add common/errors.c.
11928 (OBS): Add errors.o.
11929 (IPA_OBS): Add errors-ipa.o.
11930 (errors.o): New rule.
11931 (errors-ipa.o): Likewise.
11932 * utils.h (perror_with_name, error, warning): Don't declare.
11933 * utils.c (warning): Renamed and rewritten as...
11934 (vwarning): New function.
11935 (error): Renamed and rewritten as...
11936 (verror): New function.
11937 (internal_error): Renamed and rewritten as...
11938 (internal_verror): New function.
11940 2014-08-07 Gary Benson <gbenson@redhat.com>
11942 * configure.ac (AC_CHECK_HEADERS): Remove errno.h.
11943 * configure: Regenerate.
11944 * config.in: Likewise.
11945 * server.h: Do not include errno.h.
11946 * event-loop.c: Likewise.
11947 * hostio-errno.c: Likewise.
11948 * linux-low.c: Likewise.
11949 * remote-utils.c: Likewise.
11950 * spu-low.c: Likewise.
11951 * utils.c: Likewise.
11952 * gdbreplay.c: Unconditionally include errno.h.
11954 2014-08-07 Gary Benson <gbenson@redhat.com>
11956 * server.h: Do not include string.h.
11957 * event-loop.c: Likewise.
11958 * linux-low.c: Likewise.
11959 * regcache.c: Likewise.
11960 * remote-utils.c: Likewise.
11961 * spu-low.c: Likewise.
11962 * utils.c: Likewise.
11964 2014-08-07 Gary Benson <gbenson@redhat.com>
11966 * server.h: Do not include gdb_assert.h.
11968 2014-08-07 Gary Benson <gbenson@redhat.com>
11970 * server.h: Do not include common-utils.h.
11972 2014-08-07 Gary Benson <gbenson@redhat.com>
11974 * server.h: Do not include ptid.h.
11975 * notif.h: Likewise.
11977 2014-08-07 Gary Benson <gbenson@redhat.com>
11979 * server.h: Do not include gdb_locale.h.
11981 2014-08-07 Gary Benson <gbenson@redhat.com>
11983 * server.h: Do not include gdb/signals.h.
11984 * win32-low.c: Likewise.
11986 2014-08-07 Gary Benson <gbenson@redhat.com>
11988 * server.h: Do not include pathmax.h.
11990 2014-08-07 Gary Benson <gbenson@redhat.com>
11992 * server.h: Do not include libiberty.h.
11993 * linux-bfin-low.c: Likewise.
11995 2014-08-07 Gary Benson <gbenson@redhat.com>
11997 * server.h: Do not include ansidecl.h.
11999 2014-08-07 Gary Benson <gbenson@redhat.com>
12001 * linux-x86-low.c: Do not include stddef.h.
12002 * lynx-ppc-low.c: Likewise.
12003 * tracepoint.c: Likewise.
12005 2014-08-07 Gary Benson <gbenson@redhat.com>
12007 * server.h: Do not include stdarg.h.
12008 * nto-low.c: Likewise.
12010 2014-08-07 Gary Benson <gbenson@redhat.com>
12012 * server.h: Do not include stdlib.h.
12013 * inferiors.c: Likewise.
12014 * linux-low.c: Likewise.
12015 * regcache.c: Likewise.
12016 * spu-low.c: Likewise.
12017 * tracepoint.c: Likewise.
12018 * utils.c: Likewise.
12020 2014-08-07 Gary Benson <gbenson@redhat.com>
12022 * server.h: Do not include stdio.h.
12023 * linux-low.c: Likewise.
12024 * remote-utils.c: Likewise.
12025 * spu-low.c: Likewise.
12026 * utils.c: Likewise.
12027 * wincecompat.c: Likewise.
12029 2014-08-06 Gary Benson <gbenson@redhat.com>
12031 * regcache.c (init_register_cache): Move conditionals inside if.
12033 2014-08-06 Gary Benson <gbenson@redhat.com>
12035 * linux-low.c (linux_supports_non_stop): Use target_is_async_p.
12037 2014-07-31 Gary Benson <gbenson@redhat.com>
12039 * ax.h: Do not include server.h.
12040 * gdbthread.h: Likewise.
12041 * lynx-low.h: Likewise.
12042 * notif.h: Likewise.
12044 2014-07-30 Gary Benson <gbenson@redhat.com>
12046 * server.h: Include common-defs.h.
12047 Do not include config.h or build-gnulib-gdbserver/config.h.
12049 2014-07-30 Gary Benson <gbenson@redhat.com>
12051 * hostio-errno.c: Move server.h to top of includes list.
12052 * inferiors.c: Likewise.
12053 * linux-x86-low.c: Likewise.
12054 * notif.c: Include server.h.
12056 2014-07-24 Tom Tromey <tromey@redhat.com>
12057 Gary Benson <gbenson@redhat.com>
12059 * server.h (CORE_ADDR): Now unsigned.
12061 2014-07-16 Pedro Alves <palves@redhat.com>
12063 * linux-low.c (linux_kill_one_lwp): Use kill_lwp, not kill.
12065 2014-07-15 Pedro Alves <palves@redhat.com>
12067 * linux-low.c (linux_kill_one_lwp): Save errno and work with saved
12070 2014-07-11 Pedro Alves <palves@redhat.com>
12072 * linux-low.c (kill_wait_lwp): New function, based on
12073 kill_one_lwp_callback, but use my_waitpid directly.
12074 (kill_one_lwp_callback, linux_kill): Use it.
12076 2014-06-23 Pedro Alves <palves@redhat.com>
12078 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR_CONTROL
12079 before setting DR0..DR3.
12081 2014-06-20 Gary Benson <gbenson@redhat.com>
12083 * configure.ac (AC_REPLACE_FUNCS) <vasprintf, vsnprintf>: Removed.
12084 * configure: Regenerated.
12085 * config.in: Likewise.
12087 2014-06-20 Gary Benson <gbenson@redhat.com>
12089 * Makefile.in (SFILES): Update locations for files moved
12090 from common to nat.
12091 (object file files): Reordered.
12093 2014-06-20 Gary Benson <gbenson@redhat.com>
12095 * i386-low.h (i386_dr_low_can_set_addr): Removed.
12096 (i386_dr_low_set_addr): Likewise.
12097 (i386_dr_low_get_addr): Likewise.
12098 (i386_dr_low_can_set_control): Likewise.
12099 (i386_dr_low_set_control): Likewise.
12100 (i386_dr_low_get_control): Likewise.
12101 (i386_dr_low_get_status): Likewise.
12102 (i386_get_debug_register_length): Likewise.
12103 * linux-x86-low.c (i386_dr_low_set_addr):
12104 Changed signature. Made static.
12105 (i386_dr_low_get_addr): Likewise.
12106 (i386_dr_low_set_control): Likewise.
12107 (i386_dr_low_get_control): Likewise.
12108 (i386_dr_low_get_status): Likewise.
12109 (i386_dr_low): New global variable.
12110 * win32-i386-low.c (i386_dr_low_set_addr):
12111 Changed signature. Made static.
12112 (i386_dr_low_get_addr): Likewise.
12113 (i386_dr_low_set_control): Likewise.
12114 (i386_dr_low_get_control): Likewise.
12115 (i386_dr_low_get_status): Likewise.
12116 (i386_dr_low): New global variable.
12118 2014-06-20 Marcus Shawcroft <marcus.shawcroft@arm.com>
12120 * configure.ac: Invoke. AC_CHECK_TOOL(AR, ar).
12121 * Makefile.in (AR, AR_FLAGS): Define.
12122 * configure: Regenerate.
12124 2014-06-19 Gary Benson <gbenson@redhat.com>
12126 * Makefile.in (i386-dregs.o): New rule.
12127 * configure.srv: Add i386-dregs.o to all targets using i386-low.o.
12128 * i386-low.c (target.h): Remove include.
12129 (TARGET_HAS_DR_LEN_8): Now in i386-dregs.c.
12130 (DR_CONTROL_SHIFT): Likewise.
12131 (DR_CONTROL_SIZE): Likewise.
12132 (DR_RW_EXECUTE): Likewise.
12133 (DR_RW_WRITE): Likewise.
12134 (DR_RW_READ): Likewise.
12135 (DR_RW_IORW): Likewise.
12136 (DR_LEN_1): Likewise.
12137 (DR_LEN_2): Likewise.
12138 (DR_LEN_4): Likewise.
12139 (DR_LEN_8): Likewise.
12140 (DR_LOCAL_ENABLE_SHIFT): Likewise.
12141 (DR_GLOBAL_ENABLE_SHIFT): Likewise.
12142 (DR_ENABLE_SIZE): Likewise.
12143 (DR_LOCAL_SLOWDOWN): Likewise.
12144 (DR_GLOBAL_SLOWDOWN): Likewise.
12145 (DR_CONTROL_RESERVED): Likewise.
12146 (I386_DR_CONTROL_MASK): Likewise.
12147 (I386_DR_VACANT): Likewise.
12148 (I386_DR_LOCAL_ENABLE): Likewise.
12149 (I386_DR_GLOBAL_ENABLE): Likewise.
12150 (I386_DR_DISABLE): Likewise.
12151 (I386_DR_SET_RW_LEN): Likewise.
12152 (I386_DR_GET_RW_LEN): Likewise.
12153 (I386_DR_WATCH_HIT): Likewise.
12154 (i386_wp_op_t): Likewise.
12155 (i386_show_dr): Likewise.
12156 (i386_length_and_rw_bits): Likewise.
12157 (i386_insert_aligned_watchpoint): Likewise.
12158 (i386_remove_aligned_watchpoint): Likewise.
12159 (i386_handle_nonaligned_watchpoint): Likewise.
12160 i386_update_inferior_debug_regs(): Likewise.
12161 (i386_dr_insert_watchpoint): Likewise.
12162 (i386_dr_remove_watchpoint): Likewise.
12163 (i386_dr_region_ok_for_watchpoint): Likewise.
12164 (i386_dr_stopped_data_address): Likewise.
12165 (i386_dr_stopped_by_watchpoint): Likewise.
12167 2014-06-19 Gary Benson <gbenson@redhat.com>
12169 * i386-low.c (i386_dr_show): Renamed to
12170 i386_show_dr and made static. All uses updated.
12171 (i386_dr_length_and_rw_bits): Renamed to
12172 i386_length_and_rw_bits and made static.
12174 (i386_dr_insert_aligned_watchpoint): Renamed to
12175 i386_insert_aligned_watchpoint and made static.
12177 (i386_dr_remove_aligned_watchpoint): Renamed to
12178 i386_remove_aligned_watchpoint and made static.
12180 (i386_dr_update_inferior_debug_regs): Renamed to
12181 i386_update_inferior_debug_regs and made static.
12184 2014-06-18 Gary Benson <gbenson@redhat.com>
12186 * i386-low.h (i386_dr_low_can_set_addr): New macro.
12187 (i386_dr_low_can_set_control): Likewise.
12188 (i386_get_debug_register_length): Likewise.
12189 * i386-low.c (i386_dr_low_can_set_addr): Now in i386-low.h.
12190 (i386_dr_low_can_set_control): Likewise.
12191 (i386_get_debug_register_length): Likewise.
12193 2014-06-17 Gary Benson <gbenson@redhat.com>
12195 * i386-low.h (i386-dregs.h): New include.
12196 (DR_FIRSTADDR): Now in i386-dregs.h.
12197 (DR_LASTADDR): Likewise.
12198 (DR_NADDR): Likewise.
12199 (DR_STATUS): Likewise.
12200 (DR_CONTROL): Likewise.
12201 (i386_debug_reg_state): Likewise.
12202 (i386_dr_insert_watchpoint): Likewise.
12203 (i386_dr_remove_watchpoint): Likewise.
12204 (i386_dr_region_ok_for_watchpoint): Likewise.
12205 (i386_dr_stopped_data_address): Likewise.
12206 (i386_dr_stopped_by_watchpoint): Likewise.
12207 * i386-low.c (ALL_DEBUG_REGISTERS): Likewise.
12209 2014-06-18 Gary Benson <gbenson@redhat.com>
12211 * i386-low.h (i386_low_insert_watchpoint): Renamed to
12212 i386_dr_insert_watchpoint.
12213 (i386_low_remove_watchpoint): Renamed to
12214 i386_dr_remove_watchpoint.
12215 (i386_low_region_ok_for_watchpoint): Renamed to
12216 i386_dr_region_ok_for_watchpoint.
12217 (i386_low_stopped_data_address): Renamed to
12218 i386_dr_stopped_data_address.
12219 (i386_low_stopped_by_watchpoint): Renamed to
12220 i386_dr_stopped_by_watchpoint.
12221 * i386-low.c (i386_show_dr): Renamed to
12222 i386_dr_show and made nonstatic. All uses updated.
12223 (i386_length_and_rw_bits): Renamed to
12224 i386_dr_length_and_rw_bits and made nonstatic.
12226 (i386_insert_aligned_watchpoint): Renamed to
12227 i386_dr_insert_aligned_watchpoint and made nonstatic.
12229 (i386_remove_aligned_watchpoint): Renamed to
12230 i386_dr_remove_aligned_watchpoint and made nonstatic.
12232 (i386_update_inferior_debug_regs): Renamed to
12233 i386_dr_update_inferior_debug_regs and made nonstatic.
12235 (i386_low_insert_watchpoint): Renamed to
12236 i386_dr_insert_watchpoint. All uses updated.
12237 (i386_low_remove_watchpoint): Renamed to
12238 i386_dr_remove_watchpoint. All uses updated.
12239 (i386_low_region_ok_for_watchpoint): Renamed to
12240 i386_dr_region_ok_for_watchpoint. All uses updated.
12241 (i386_low_stopped_data_address): Renamed to
12242 i386_dr_stopped_data_address. All uses updated.
12243 (i386_low_stopped_by_watchpoint): Renamed to
12244 i386_dr_stopped_by_watchpoint. All uses updated.
12246 2014-06-18 Gary Benson <gbenson@redhat.com>
12248 * i386-low.c (i386_dr_low_can_set_addr): New macro.
12249 (i386_dr_low_can_set_control): Likewise.
12250 (i386_insert_aligned_watchpoint): New check.
12252 2014-06-18 Gary Benson <gbenson@redhat.com>
12254 * i386-low.c (i386_update_inferior_debug_regs) <inf_state>:
12257 2014-06-18 Gary Benson <gbenson@redhat.com>
12259 * i386-low.c (i386_length_and_rw_bits): Use internal_error
12260 instead of fatal and error.
12261 (i386_handle_nonaligned_watchpoint): Likewise.
12263 2014-06-18 Gary Benson <gbenson@redhat.com>
12265 * i386-low.c (i386_get_debug_register_length): New macro.
12266 (TARGET_HAS_DR_LEN_8): Remove conditional. Use above macro.
12267 (i386_show_dr): Use debug_printf instead of fprintf. Use
12268 phex to format values.
12270 2014-06-18 Gary Benson <gbenson@redhat.com>
12272 * i386-low.h: Comment changes.
12273 * i386-low.c: Likewise.
12275 2014-06-18 Gary Benson <gbenson@redhat.com>
12277 * i386-low.c: Whitespace changes.
12279 2014-06-12 Tom Tromey <tromey@redhat.com>
12281 * utils.c (freeargv): Remove.
12283 2014-06-12 Tom Tromey <tromey@redhat.com>
12285 * debug.c (debug_printf): Remove HAVE_GETTIMEOFDAY checks.
12286 * server.c (monitor_show_help): Remove HAVE_GETTIMEOFDAY check.
12287 (parse_debug_format_options): Likewise.
12288 (gdbserver_usage): Likewise.
12289 * Makefile.in (LIBIBERTY_BUILDDIR, LIBIBERTY): New variables.
12290 (SUBDIRS, REQUIRED_SUBDIRS): Add libiberty.
12291 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Depend on and link
12293 ($(LIBGNU)): Depend on libiberty.
12294 (all-lib): Recurse into all subdirs.
12295 (install-only): Invoke "install" target in subdirs.
12296 (vasprintf.o, vsnprintf.o, safe-ctype.o, lbasename.o): Remove
12298 * configure: Rebuild.
12299 * configure.ac: Add ACX_CONFIGURE_DIR for libiberty. Don't check
12300 for vasprintf, vsnprintf, or gettimeofday.
12301 * configure.srv: Don't add safe-ctype.o or lbasename.o to
12304 2014-06-05 Joel Brobecker <brobecker@adacore.com>
12306 * development.sh: Delete.
12307 * Makefile.in (config.status): Adjust dependency on development.sh.
12308 * configure.ac: Adjust development.sh source call.
12309 * configure: Regenerate.
12311 2014-06-02 Pedro Alves <palves@redhat.com>
12313 * ax.c (gdb_free_agent_expr): New function.
12314 * ax.h (gdb_free_agent_expr): New declaration.
12315 * mem-break.c (delete_gdb_breakpoint_1): Also clear the commands
12317 (clear_breakpoint_conditions, clear_breakpoint_commands): Make
12319 (clear_breakpoint_conditions_and_commands): New function.
12320 * mem-break.h (clear_breakpoint_conditions): Delete declaration.
12321 (clear_breakpoint_conditions_and_commands): New declaration.
12323 2014-05-23 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
12325 * linux-aarch64-low.c (asm/ptrace.h): Include.
12327 2014-05-21 Jan Kratochvil <jan.kratochvil@redhat.com>
12329 Fix TLS access for -static -pthread.
12330 * gdbserver/thread-db.c (struct thread_db): Add td_thr_tlsbase_p.
12331 (thread_db_get_tls_address): Call it if LOAD_MODULE is zero.
12332 (thread_db_load_search, try_thread_db_load_1): Initialize it.
12334 2014-05-20 Pedro Alves <palves@redhat.com>
12336 * linux-aarch64-low.c (aarch64_insert_point)
12337 (aarch64_remove_point): No longer check whether the type is
12338 supported here. Adjust to new interface.
12339 (the_low_target): Install aarch64_supports_z_point_type as
12340 supports_z_point_type method.
12341 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type): New function.
12342 (arm_linux_hw_point_initialize): Take an enum raw_bkpt_type
12343 instead of a Z packet char. Adjust.
12344 (arm_supports_z_point_type): New function.
12345 (arm_insert_point, arm_remove_point): Adjust to new interface.
12346 (the_low_target): Install arm_supports_z_point_type.
12347 * linux-crisv32-low.c (cris_supports_z_point_type): New function.
12348 (cris_insert_point, cris_remove_point): Adjust to new interface.
12349 Don't check whether the type is supported here.
12350 (the_low_target): Install cris_supports_z_point_type.
12351 * linux-low.c (linux_supports_z_point_type): New function.
12352 (linux_insert_point, linux_remove_point): Adjust to new interface.
12353 * linux-low.h (struct linux_target_ops) <insert_point,
12354 remove_point>: Take an enum raw_bkpt_type instead of a char. Add
12355 raw_breakpoint pointer parameter.
12356 <supports_z_point_type>: New method.
12357 * linux-mips-low.c (mips_supports_z_point_type): New function.
12358 (mips_insert_point, mips_remove_point): Adjust to new interface.
12359 Use mips_supports_z_point_type.
12360 (the_low_target): Install mips_supports_z_point_type.
12361 * linux-ppc-low.c (the_low_target): Install NULL as
12362 supports_z_point_type method.
12363 * linux-s390-low.c (the_low_target): Install NULL as
12364 supports_z_point_type method.
12365 * linux-sparc-low.c (the_low_target): Install NULL as
12366 supports_z_point_type method.
12367 * linux-x86-low.c (x86_supports_z_point_type): New function.
12368 (x86_insert_point): Adjust to new insert_point interface. Use
12369 insert_memory_breakpoint. Adjust to new
12370 i386_low_insert_watchpoint interface.
12371 (x86_remove_point): Adjust to remove_point interface. Use
12372 remove_memory_breakpoint. Adjust to new
12373 i386_low_remove_watchpoint interface.
12374 (the_low_target): Install x86_supports_z_point_type.
12375 * lynx-low.c (lynx_target_ops): Install NULL as
12376 supports_z_point_type callback.
12377 * nto-low.c (nto_supports_z_point_type): New.
12378 (nto_insert_point, nto_remove_point): Adjust to new interface.
12379 (nto_target_ops): Install nto_supports_z_point_type.
12380 * mem-break.c: Adjust intro comment.
12381 (struct raw_breakpoint) <raw_type, size>: New fields.
12382 <inserted>: Update comment.
12383 <shlib_disabled>: Delete field.
12384 (enum bkpt_type) <gdb_breakpoint>: Delete value.
12385 <gdb_breakpoint_Z0, gdb_breakpoint_Z1, gdb_breakpoint_Z2,
12386 gdb_breakpoint_Z3, gdb_breakpoint_Z4>: New values.
12387 (raw_bkpt_type_to_target_hw_bp_type): New function.
12388 (find_enabled_raw_code_breakpoint_at): New function.
12389 (find_raw_breakpoint_at): New type and size parameters. Use them.
12390 (insert_memory_breakpoint): New function, based off
12391 set_raw_breakpoint_at.
12392 (remove_memory_breakpoint): New function.
12393 (set_raw_breakpoint_at): Reimplement.
12394 (set_breakpoint): New, based on set_breakpoint_at.
12395 (set_breakpoint_at): Reimplement.
12396 (delete_raw_breakpoint): Go through the_target->remove_point
12397 instead of assuming memory breakpoints.
12398 (find_gdb_breakpoint_at): Delete.
12399 (Z_packet_to_bkpt_type, Z_packet_to_raw_bkpt_type): New functions.
12400 (find_gdb_breakpoint): New function.
12401 (set_gdb_breakpoint_at): Delete.
12402 (z_type_supported): New function.
12403 (set_gdb_breakpoint_1): New function, loosely based off
12404 set_gdb_breakpoint_at.
12405 (check_gdb_bp_preconditions, set_gdb_breakpoint): New functions.
12406 (delete_gdb_breakpoint_at): Delete.
12407 (delete_gdb_breakpoint_1): New function, loosely based off
12408 delete_gdb_breakpoint_at.
12409 (delete_gdb_breakpoint): New function.
12410 (clear_gdb_breakpoint_conditions): Rename to ...
12411 (clear_breakpoint_conditions): ... this. Don't handle a NULL
12413 (add_condition_to_breakpoint): Make static.
12414 (add_breakpoint_condition): Take a struct breakpoint pointer
12415 instead of an address. Adjust.
12416 (gdb_condition_true_at_breakpoint): Rename to ...
12417 (gdb_condition_true_at_breakpoint_z_type): ... this, and add
12419 (gdb_condition_true_at_breakpoint): Reimplement.
12420 (add_breakpoint_commands): Take a struct breakpoint pointer
12421 instead of an address. Adjust.
12422 (gdb_no_commands_at_breakpoint): Rename to ...
12423 (gdb_no_commands_at_breakpoint_z_type): ... this. Add z_type
12424 parameter. Return true if no breakpoint was found. Change debug
12426 (gdb_no_commands_at_breakpoint): Reimplement.
12427 (run_breakpoint_commands): Rename to ...
12428 (run_breakpoint_commands_z_type): ... this. Add z_type parameter,
12429 and change return type to boolean.
12430 (run_breakpoint_commands): New function.
12431 (gdb_breakpoint_here): Also check for Z1 breakpoints.
12432 (uninsert_raw_breakpoint): Don't try to reinsert a disabled
12433 breakpoint. Go through the_target->remove_point instead of
12434 assuming memory breakpoint.
12435 (uninsert_breakpoints_at, uninsert_all_breakpoints): Uninsert
12436 software and hardware breakpoints.
12437 (reinsert_raw_breakpoint): Go through the_target->insert_point
12438 instead of assuming memory breakpoint.
12439 (reinsert_breakpoints_at, reinsert_all_breakpoints): Reinsert
12440 software and hardware breakpoints.
12441 (check_breakpoints, breakpoint_here, breakpoint_inserted_here):
12442 Check both software and hardware breakpoints.
12443 (validate_inserted_breakpoint): Assert the breakpoint is a
12444 software breakpoint. Set the inserted flag to -1 instead of
12445 setting shlib_disabled.
12446 (delete_disabled_breakpoints): Adjust.
12447 (validate_breakpoints): Only validate software breakpoints.
12448 Adjust to inserted flag change.
12449 (check_mem_read, check_mem_write): Skip breakpoint types other
12450 than software breakpoints. Adjust to inserted flag change.
12451 * mem-break.h (enum raw_bkpt_type): New enum.
12452 (raw_breakpoint, struct process_info): Forward declare.
12453 (Z_packet_to_target_hw_bp_type): Delete declaration.
12454 (raw_bkpt_type_to_target_hw_bp_type, Z_packet_to_raw_bkpt_type)
12455 (set_gdb_breakpoint, delete_gdb_breakpoint)
12456 (clear_breakpoint_conditions): New declarations.
12457 (set_gdb_breakpoint_at, clear_gdb_breakpoint_conditions): Delete.
12458 (breakpoint_inserted_here): Update comment.
12459 (add_breakpoint_condition, add_breakpoint_commands): Replace
12460 address parameter with a breakpoint pointer parameter.
12461 (gdb_breakpoint_here): Update comment.
12462 (delete_gdb_breakpoint_at): Delete.
12463 (insert_memory_breakpoint, remove_memory_breakpoint): Declare.
12464 * server.c (process_point_options): Take a struct breakpoint
12465 pointer instead of an address. Adjust.
12466 (process_serial_event) <Z/z packets>: Use set_gdb_breakpoint and
12467 delete_gdb_breakpoint.
12468 * spu-low.c (spu_target_ops): Install NULL as
12469 supports_z_point_type method.
12470 * target.h: Include mem-break.h.
12471 (struct target_ops) <prepare_to_access_memory>: Update comment.
12472 <supports_z_point_type>: New field.
12473 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
12474 instead of a char. Also take a raw breakpoint pointer.
12475 * win32-arm-low.c (the_low_target): Install NULL as
12476 supports_z_point_type.
12477 * win32-i386-low.c (i386_supports_z_point_type): New function.
12478 (i386_insert_point, i386_remove_point): Adjust to new interface.
12479 (the_low_target): Install i386_supports_z_point_type.
12480 * win32-low.c (win32_supports_z_point_type): New function.
12481 (win32_insert_point, win32_remove_point): Adjust to new interface.
12482 (win32_target_ops): Install win32_supports_z_point_type.
12483 * win32-low.h (struct win32_target_ops):
12484 <supports_z_point_type>: New method.
12485 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
12486 instead of a char. Also take a raw breakpoint pointer.
12488 2014-05-20 Pedro Alves <palves@redhat.com>
12490 * mem-break.h: Include break-common.h.
12491 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
12492 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): New defines.
12493 (Z_packet_to_target_hw_bp_type): New declaration.
12494 * mem-break.c (Z_packet_to_target_hw_bp_type): New function.
12495 * i386-low.c (Z_PACKET_HW_BP, Z_PACKET_WRITE_WP, Z_PACKET_READ_WP)
12496 (Z_PACKET_ACCESS_WP): Delete macros.
12497 (Z_packet_to_hw_type): Delete function.
12498 * i386-low.h: Don't include break-common.h here.
12499 (Z_packet_to_hw_type): Delete declaration.
12500 * linux-x86-low.c (x86_insert_point, x86_insert_point): Call
12501 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
12502 * win32-i386-low.c (i386_insert_point, i386_remove_point): Call
12503 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
12504 * linux-aarch64-low.c: Don't include break-common.h here.
12505 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
12506 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): Delete macros.
12507 (Z_packet_to_target_hw_bp_type): Delete function.
12508 * linux-mips-low.c (rsp_bp_type_to_target_hw_bp_type): Delete
12510 (mips_insert_point, mips_remove_point): Use
12511 Z_packet_to_target_hw_bp_type.
12513 2014-05-20 Pedro Alves <palves@redhat.com>
12515 * linux-aarch64-low.c: Include break-common.h.
12516 (enum target_point_type): Delete.
12517 (Z_packet_to_point_type): Rename to ...
12518 (Z_packet_to_target_hw_bp_type): ... this, and return a
12519 target_hw_bp_type instead.
12520 (aarch64_show_debug_reg_state): Take an enum target_hw_bp_type
12521 instead of an enum target_point_type.
12522 (aarch64_point_encode_ctrl_reg): Likewise. Compute type mask from
12524 (aarch64_dr_state_insert_one_point)
12525 (aarch64_dr_state_remove_one_point, aarch64_handle_breakpoint)
12526 (aarch64_handle_aligned_watchpoint)
12527 (aarch64_handle_unaligned_watchpoint, aarch64_handle_watchpoint):
12528 Take an enum target_hw_bp_type instead of an enum
12530 (aarch64_supports_z_point_type): New function.
12531 (aarch64_insert_point, aarch64_remove_point): Use it. Adjust to
12532 use Z_packet_to_target_hw_bp_type.
12534 2014-05-20 Joel Brobecker <brobecker@adacore.com>
12536 * configure.ac: Only use -Werror by default when DEVELOPMENT
12538 * configure: Regenerate.
12540 2014-05-19 Jan Kratochvil <jan.kratochvil@redhat.com>
12542 Fix gdbserver qGetTLSAddr for x86_64 -m32.
12543 * linux-x86-low.c (X86_64_USER_REGS): New.
12544 (x86_fill_gregset): Call memset for BUF first in x86_64 -m32 case.
12546 2014-04-28 Yao Qi <yao@codesourcery.com>
12548 * Makefile.in (i386-avx512.c): Fix the typo of generated file
12551 2014-04-25 Pedro Alves <palves@redhat.com>
12554 * linux-low.c (linux_attach_fail_reason_string): New function.
12555 (linux_attach_lwp): Delete.
12556 (linux_attach_lwp_1): Rename to ...
12557 (linux_attach_lwp): ... this. Take a ptid instead of a pid as
12558 argument. Remove "initial" parameter. Return int instead of
12559 void. Don't error or warn here.
12560 (linux_attach): Adjust to call linux_attach_lwp. Call error on
12561 failure to attach to the tgid. Call warning when failing to
12563 * linux-low.h (linux_attach_lwp): Take a ptid instead of a pid as
12564 argument. Remove "initial" parameter. Return int instead of
12565 void. Don't error or warn here.
12566 (linux_attach_fail_reason_string): New declaration.
12567 * thread-db.c (attach_thread): Adjust to linux_attach_lwp's
12568 interface change. Use linux_attach_fail_reason_string.
12570 2014-04-24 Michael Sturm <michael.sturm@mintel.com>
12571 Walfred Tedeschi <walfred.tedeschi@intel.com>
12573 * Makefile.in: Added rules to handle new files
12574 i386-avx512.c i386-avx512-linux.c amd64-avx512.c
12575 amd64-avx512-linux.c x32-avx512.c x32-avx512-linux.c.
12576 * configure.srv (srv_i386_regobj): Add i386-avx512.o.
12577 (srv_i386_linux_regobj): Add i386-avx512-linux.o.
12578 (srv_amd64_regobj): Add amd64-avx512.o and x32-avx512.o.
12579 (srv_amd64_linux_regobj): Add amd64-avx512-linux.o and
12580 x32-avx512-linux.o.
12581 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx512.xml.
12582 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx512.xml.
12583 (srv_amd64_xmlfiles): Add i386/amd64-avx512.xml and
12584 i386/x32-avx512.xml.
12585 (srv_i386_linux_xmlfiles): Add i386/i386-avx512-linux.xml.
12586 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx512-linux.xml and
12587 i386/x32-avx512-linux.xml.
12588 * i387-fp.c (num_avx512_k_registers): New constant for number
12590 (num_avx512_zmmh_low_registers): New constant for number of
12591 lower ZMM registers (0-15).
12592 (num_avx512_zmmh_high_registers): New constant for number of
12593 higher ZMM registers (16-31).
12594 (num_avx512_ymmh_registers): New contant for number of higher
12595 YMM registers (ymm16-31 added by avx521 on x86_64).
12596 (num_avx512_xmm_registers): New constant for number of higher
12597 XMM registers (xmm16-31 added by AVX512 on x86_64).
12598 (struct i387_xsave): Add space for AVX512 registers.
12599 (i387_cache_to_xsave): Change raw buffer size to 64 characters.
12600 Add code to handle AVX512 registers.
12601 (i387_xsave_to_cache): Add code to handle AVX512 registers.
12602 * linux-x86-low.c (init_registers_amd64_avx512_linux): New
12603 prototypei from generated file.
12604 (tdesc_amd64_avx512_linux): Likewise.
12605 (init_registers_x32_avx512_linux): Likewise.
12606 (tdesc_x32_avx512_linux): Likewise.
12607 (init_registers_i386_avx512_linux): Likewise.
12608 (tdesc_i386_avx512_linux): Likewise.
12609 (x86_64_regmap): Add AVX512 registers.
12610 (x86_linux_read_description): Add code to handle AVX512 XSTATE
12612 (initialize_low_arch): Add code to initialize AVX512 registers.
12614 2014-04-23 Pedro Alves <palves@redhat.com>
12616 * mem-break.c (find_gdb_breakpoint_at): Make static.
12617 * mem-break.h (find_gdb_breakpoint_at): Delete declaration.
12619 2014-04-23 Pedro Alves <palves@redhat.com>
12621 * i386-low.c: Don't include break-common.h here.
12622 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
12623 prototype to take target_hw_bp_type as argument instead of a Z
12625 * i386-low.h: Include break-common.h here.
12626 (Z_packet_to_hw_type): Declare.
12627 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
12629 * linux-x86-low.c (x86_insert_point): Convert the packet number to
12630 a target_hw_bp_type before calling i386_low_insert_watchpoint.
12631 (x86_remove_point): Convert the packet number to a
12632 target_hw_bp_type before calling i386_low_remove_watchpoint.
12633 * win32-i386-low.c (i386_insert_point): Convert the packet number
12634 to a target_hw_bp_type before calling i386_low_insert_watchpoint.
12635 (i386_remove_point): Convert the packet number to a
12636 target_hw_bp_type before calling i386_low_remove_watchpoint.
12638 2014-04-23 Pedro Alves <palves@redhat.com>
12640 * utils.h (perror_with_name): Add ATTRIBUTE_NORETURN.
12642 2014-04-10 Pedro Alves <palves@redhat.com>
12644 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
12645 Check if the condition or command is NULL before checking if the
12646 breakpoint is known. On success, return true.
12647 * mem-break.h (add_breakpoint_condition): Document return.
12648 (add_breakpoint_commands): Add describing comment.
12649 * server.c (skip_to_semicolon): New function.
12650 (process_point_options): Use it.
12652 2014-04-09 Pedro Alves <palves@redhat.com>
12654 * linux-low.c (linux_read_loadmap): Pass current_inferior directly
12657 2014-02-27 Pedro Alves <palves@redhat.com>
12660 * inferiors.h (A_I_NEXT, ALL_INFERIORS_TYPE, ALL_PROCESSES): New
12662 * linux-low.c (delete_lwp, handle_extended_wait): Add debug
12664 (last_thread_of_process_p): Take a PID argument instead of a
12666 (linux_wait_for_lwp): Delete.
12667 (num_lwps, check_zombie_leaders, not_stopped_callback): New
12669 (linux_low_filter_event): New function, party factored out from
12670 linux_wait_for_event.
12671 (linux_wait_for_event): Rename to ...
12672 (linux_wait_for_event_filtered): ... this. Add new filter ptid
12673 argument. Partly rewrite. Always use waitpid(-1, WNOHANG) and
12674 sigsuspend. Check for zombie leaders.
12675 (linux_wait_for_event): Reimplement as wrapper around
12676 linux_wait_for_event_filtered.
12677 (linux_wait_1): Handle TARGET_WAITKIND_NO_RESUMED. Assume that if
12678 a normal or signal exit is seen, it's the whole process exiting.
12679 (wait_for_sigstop): No longer a for_each_inferior callback.
12680 Rewrite on top of linux_wait_for_event_filtered.
12681 (stop_all_lwps): Call wait_for_sigstop directly.
12682 * server.c (resume, handle_target_event): Handle
12683 TARGET_WAITKIND_NO_RESUMED.
12685 2014-02-26 Joel Brobecker <brobecker@adacore.com>
12687 * win32-low.c (psapi_get_dll_name,
12688 * win32_CreateToolhelp32Snapshot): Delete.
12689 (win32_CreateToolhelp32Snapshot, win32_Module32First)
12690 (win32_Module32Next, load_toolhelp, toolhelp_get_dll_name):
12692 (handle_load_dll): Add function description.
12693 Remove code using psapi_get_dll_name and toolhelp_get_dll_name.
12695 2014-02-26 Joel Brobecker <brobecker@adacore.com>
12697 * win32-low.c (win32_add_one_solib): Add 0x1000 to load_addr.
12699 (win32_add_all_dlls): Remove 0x1000 offset applied to DLL
12700 base address when calling win32_add_one_solib.
12701 (handle_load_dll): Delete local variable load_addr.
12702 Remove 0x1000 offset applied to DLL base address when calling
12703 win32_add_one_solib.
12704 (handle_unload_dll): Add comment.
12706 2014-02-26 Joel Brobecker <brobecker@adacore.com>
12708 * win32-low.c (win32_add_all_dlls): Renames
12709 win32_ensure_ntdll_loaded. Rewrite function documentation.
12710 Adjust implementation to always load all DLLs.
12711 Add 0x1000 offset to DLL base address when calling
12712 win32_add_one_solib.
12713 (child_initialization_done): New static global.
12714 (do_initial_child_stuff): Set child_initialization_done to
12715 zero during child initialization, and 1 after. Replace call
12716 to win32_ensure_ntdll_loaded by call to win32_add_all_dlls.
12718 (match_dll_by_basename, dll_is_loaded_by_basename): Delete.
12719 (handle_unload_dll): Add function documentation.
12720 (get_child_debug_event): Ignore load and unload DLL events
12721 during child initialization.
12723 2014-02-20 Doug Evans <dje@google.com>
12725 Remove global all_lwps.
12726 * inferiors.h (ptid_of): Move here from linux-low.h.
12727 (pid_of, lwpid_of): Ditto.
12728 * linux-aarch64-low.c (debug_reg_change_callback): Update, "entry"
12729 parameter is a struct thread_info * now.
12730 (aarch64_notify_debug_reg_change): Fetch pid from current_inferior
12731 directly. Pass &all_threads to find_inferior instead of &all_lwps.
12732 (aarch64_stopped_data_address): Fetch lwpid from current_inferior
12734 (aarch64_linux_prepare_to_resume): Fetch ptid from thread.
12735 (aarch64_arch_setup): Fetch lwpid from current_inferior directly.
12736 * linux-arm-low.c (update_registers_callback): Update, "entry"
12737 parameter is a struct thread_info * now.
12738 Fetch lwpid from current_inferior directly.
12739 (arm_insert_point): Pass &all_threads to find_inferior instead of
12741 (arm_remove_point): Ditto.
12742 (arm_stopped_by_watchpoint): Fetch lwp from current_inferior.
12743 (arm_prepare_to_resume): Fetch pid from thread.
12744 (arm_read_description): Fetch lwpid from current_inferior directly.
12745 * linux-low.c (all_lwps): Delete.
12746 (delete_lwp): Delete call to remove_inferior.
12747 (handle_extended_wait): Fetch lwpid from thread.
12748 (add_lwp): Don't set lwp->entry.id. Remove call to
12749 add_inferior_to_list.
12750 (linux_attach_lwp_1): Fetch pid from current_inferior directly.
12751 (linux_kill_one_lwp): Fetch ptid,lwpid from thread.
12752 (kill_one_lwp_callback): Ditto.
12753 (linux_kill): Don't dereference NULL pointer.
12754 Fetch ptid,lwpid from thread.
12755 (get_detach_signal): Fetch ptid from thread.
12756 (linux_detach_one_lwp): Fetch ptid,lwpid from thread.
12757 Simplify call to regcache_invalidate_thread.
12758 (delete_lwp_callback): Update, "entry" parameter is a
12759 struct thread_info * now. Fetch pid from thread.
12760 (linux_mourn): Pass &all_threads to find_inferior instead of &all_lwps.
12761 (status_pending_p_callback): Update, "entry" parameter is a
12762 struct thread_info * now. Fetch ptid from thread.
12763 (find_lwp_pid): Update, "entry" parameter is a
12764 struct thread_info * now.
12765 (linux_wait_for_lwp): Fetch pid from thread.
12766 (linux_fast_tracepoint_collecting): Fetch lwpid from thread.
12767 (maybe_move_out_of_jump_pad): Fetch lwpid from current_inferior.
12768 (enqueue_one_deferred_signal): Fetch lwpid from thread.
12769 (dequeue_one_deferred_signal): Ditto.
12770 (cancel_breakpoint): Fetch ptid from current_inferior.
12771 (linux_wait_for_event): Pass &all_threads to find_inferior,
12772 not &all_lwps. Fetch ptid, lwpid from thread.
12773 (count_events_callback): Update, "entry" parameter is a
12774 struct thread_info * now.
12775 (select_singlestep_lwp_callback): Ditto.
12776 (select_event_lwp_callback): Ditto.
12777 (cancel_breakpoints_callback): Ditto.
12778 (linux_cancel_breakpoints): Pass &all_threads to find_inferior,
12780 (select_event_lwp): Ditto. Fetch ptid from event_thread.
12781 (unsuspend_one_lwp): Update, "entry" parameter is a
12782 struct thread_info * now.
12783 (unsuspend_all_lwps): Pass &all_threads to find_inferior,
12785 (linux_stabilize_threads): Ditto. And for for_each_inferior.
12786 Fetch lwpid from thread, not lwp.
12787 (linux_wait_1): Fetch ptid, lwpid from current_inferior.
12788 Pass &all_threads to find_inferior, not &all_lwps.
12789 (send_sigstop): Fetch lwpid from thread, not lwp.
12790 (send_sigstop_callback): Update, "entry" parameter is a
12791 struct thread_info * now.
12792 (suspend_and_send_sigstop_callback): Ditto.
12793 (wait_for_sigstop): Ditto. Fetch ptid, lwpid from thread, lwp.
12794 (stuck_in_jump_pad_callback): Update, "entry" parameter is a
12795 struct thread_info * now.
12796 (move_out_of_jump_pad_callback): Ditto. Fetch ptid, lwpid
12798 (lwp_running): Update, "entry" parameter is a
12799 struct thread_info * now.
12800 (stop_all_lwps): Fetch ptid from thread.
12801 Pass &all_threads to find_inferior, for_each_inferior, not &all_lwps.
12802 (linux_resume_one_lwp): Fetch lwpid from thread.
12803 (linux_set_resume_request): Update, "entry" parameter is a
12804 struct thread_info * now. Fetch pid, lwpid from thread.
12805 (resume_status_pending_p): Update, "entry" parameter is a
12806 struct thread_info * now.
12807 (need_step_over_p): Ditto. Fetch lwpid from thread.
12808 (start_step_over): Fetch lwpid from thread.
12809 (linux_resume_one_thread): Update, "entry" parameter is a
12810 struct thread_info * now. Fetch lwpid from thread.
12811 (linux_resume): Pass &all_threads to find_inferior, not &all_lwps.
12812 (proceed_one_lwp): Update, "entry" parameter is a
12813 struct thread_info * now. Fetch lwpid from thread.
12814 (unsuspend_and_proceed_one_lwp): Update, "entry" parameter is a
12815 struct thread_info * now.
12816 (proceed_all_lwps): Pass &all_threads to find_inferior, not &all_lwps.
12817 (unstop_all_lwps): Ditto. Fetch lwpid from thread.
12818 (regsets_fetch_inferior_registers): Fetch lwpid from current_inferior
12820 (regsets_store_inferior_registers): Ditto.
12821 (fetch_register, store_register): Ditto.
12822 (linux_read_memory, linux_write_memory): Ditto.
12823 (linux_request_interrupt): Ditto.
12824 (linux_read_auxv): Ditto.
12825 (linux_xfer_siginfo): Ditto.
12826 (linux_qxfer_spu): Ditto.
12827 (linux_qxfer_libraries_svr4): Ditto.
12828 * linux-low.h (ptid_of, pid_of, lwpid_of): Delete,
12829 moved to inferiors.h.
12831 (get_thread_lwp): Update.
12832 (struct lwp_info): Delete member "entry". Simplify comment for
12834 (all_lwps): Delete.
12835 * linux-mips-low.c (mips_read_description): Fetch lwpid from
12836 current_inferior directly.
12837 (update_watch_registers_callback): Update, "entry" parameter is a
12838 struct thread_info * now. Fetch pid from thread.
12839 (mips_linux_prepare_to_resume): Fetch ptid from thread.
12840 (mips_insert_point): Fetch lwpid from current_inferior.
12841 Pass &all_threads to find_inferior, not &all_lwps.
12842 (mips_remove_point): Pass &all_threads to find_inferior, not &all_lwps.
12843 (mips_stopped_by_watchpoint): Fetch lwpid from current_inferior
12845 (mips_stopped_data_address): Ditto.
12846 * linux-s390-low.c (s390_arch_setup): Fetch pid from current_inferior
12848 * linux-tile-low.c (tile_arch_setup): Ditto.
12849 * linux-x86-low.c (x86_get_thread_area): Fetch lwpid from thread.
12850 (update_debug_registers_callback): Update, "entry" parameter is a
12851 struct thread_info * now. Fetch pid from thread.
12852 (i386_dr_low_set_addr): Fetch pid from current_inferior directly.
12853 Pass &all_threads to find_inferior, not &all_lwps.
12854 (i386_dr_low_get_addr): Fetch ptid from current_inferior directly.
12855 (i386_dr_low_set_control): Fetch pid from current_inferior directly.
12856 Pass &all_threads to find_inferior, not &all_lwps.
12857 (i386_dr_low_get_control): Fetch ptid from current_inferior directly.
12858 (i386_dr_low_get_status): Ditto.
12859 (x86_linux_prepare_to_resume): Fetch ptid from thread.
12860 (x86_siginfo_fixup): Fetch lwpid from current_inferior directly.
12861 (x86_linux_read_description): Ditto.
12862 * proc-service.c (ps_getpid): Fetch pid from current_inferior directly.
12864 2014-02-20 Doug Evans <dje@google.com>
12866 * inferiors.c (get_first_inferior): Fix buglet.
12868 2014-02-19 Doug Evans <dje@google.com>
12870 * gdbthread.h (add_thread): Change result type to struct thread_info *.
12871 * inferiors.c (add_thread): Change result type to struct thread_info *.
12872 All callers updated.
12873 (add_lwp): Call add_thread here instead of in callers.
12874 All callers updated.
12875 * linux-low.h (get_lwp_thread): Rewrite.
12876 (struct lwp_info): New member "thread".
12878 2014-02-19 Doug Evans <dje@google.com>
12880 * linux-low.c (add_lwp): Change result to struct lwp_info *.
12881 All callers updated.
12883 2014-02-19 Doug Evans <dje@google.com>
12885 * inferiors.c (add_thread): Fix whitespace.
12887 2014-02-19 Doug Evans <dje@google.com>
12889 * dll.c (clear_dlls): Replace accessing list implemention details
12891 * gdbthread.h (get_first_thread): Declare.
12892 * inferiors.c (for_each_inferior_with_data): New function.
12893 (get_first_thread): New function.
12894 (find_thread_ptid): Simplify.
12895 (get_first_inferior): New function.
12896 (clear_list): Delete.
12897 (one_inferior_p): New function.
12898 (clear_inferior_list): New function.
12899 (clear_inferiors): Update.
12900 * inferiors.h (for_each_inferior_with_data): Declare.
12901 (clear_inferior_list): Declare.
12902 (one_inferior_p): Declare.
12903 (get_first_inferior): Declare.
12904 * linux-low.c (linux_wait_for_event): Replace accessing list
12905 implemention details with API function.
12906 * server.c (target_running): Ditto.
12907 (accumulate_file_name_length): New function.
12908 (emit_dll_description): New function.
12909 (handle_qxfer_libraries): Replace accessing list implemention
12910 details with API function.
12911 (handle_qxfer_threads_worker): New function.
12912 (handle_qxfer_threads_proper): Replace accessing list implemention
12913 details with API function.
12914 (handle_query): Ditto.
12915 (visit_actioned_threads_callback_ftype): New typedef.
12916 (visit_actioned_threads_data): New struct.
12917 (visit_actioned_threads): Rewrite to be find_inferior callback.
12918 (resume): Call find_inferior.
12919 (handle_status): Replace accessing list implemention
12920 details with API function.
12921 (process_serial_event): Replace accessing list implemention details
12923 * target.c (set_desired_inferior): Replace accessing list implemention
12924 details with API function.
12925 * tracepoint.c (same_process_p): New function.
12926 (gdb_agent_about_to_close): Replace accessing list implemention
12927 details with API function.
12928 * win32-low.c (child_delete_thread): Replace accessing list
12929 implemention details with API function.
12930 (match_dll_by_basename): New function.
12931 (dll_is_loaded_by_basename): New function.
12932 (win32_ensure_ntdll_loaded): Replace accessing list implemention
12933 details call to dll_is_loaded_by_basename.
12935 2014-02-19 Doug Evans <dje@google.com>
12937 * dll.h (struct dll_info): Add comment.
12938 * gdbthread.h (struct thread_info): Add comment.
12939 (current_ptid): Simplify.
12940 * inferiors.c (add_process): Update.
12941 (remove_process): Update.
12942 * inferiors.h (struct process_info): Rename member "head" to "entry".
12943 * linux-low.c (delete_lwp): Update.
12945 (last_thread_of_process_p): Update.
12946 (kill_one_lwp_callback, linux_kill): Update.
12947 (status_pending_p_callback): Update.
12948 (wait_for_sigstop): Update. Simplify read of ptid.
12949 (start_step_over): Update.
12950 * linux-low.h (ptid_of, pid_of, lwpid_of): Update.
12951 (get_lwp_thread): Update.
12952 (struct lwp_info): Rename member "head" to "entry".
12953 * regcache.h (inferior_list_entry): Delete.
12954 * server.c (kill_inferior_callback): Update.
12955 (detach_or_kill_inferior_callback): Update.
12956 (print_started_pid): Update.
12957 (print_attached_pid): Update.
12958 (process_serial_event): Simplify read of ptid.
12959 * thread-db.c (thread_db_create_event): Update.
12960 (thread_db_get_tls_address): Update.
12961 * win32-low.c (current_inferior_ptid): Simplify.
12963 2014-02-19 Tom Tromey <tromey@redhat.com>
12965 * target.h (struct target_ops) <supports_btrace>: Add target_ops
12967 (target_supports_btrace): Update.
12969 2014-02-14 Yao Qi <yao@codesourcery.com>
12971 * Makefile.in (IPA_OBJS): Append rsp-low-ipa.o.
12972 (rsp-low-ipa.o): New target.
12974 2014-02-12 Tom Tromey <tromey@redhat.com>
12976 * ax.c (gdb_parse_agent_expr): Use hex2bin, not
12977 convert_ascii_to_int.
12978 * regcache.c (registers_to_string): Likewise.
12979 * remote-utils.c (decode_M_packet): Likewise.
12980 * server.c (process_serial_event): Likewise.
12982 2014-02-12 Tom Tromey <tromey@redhat.com>
12984 * server.c (handle_query, handle_v_run): Use hex2bin, not
12986 * tracepoint.c (cmd_qtdpsrc, cmd_qtdv, cmd_qtnotes): Likewise.
12988 2014-02-12 Tom Tromey <tromey@redhat.com>
12990 * ax.c (gdb_unparse_agent_expr): Use bin2hex, not
12991 convert_int_to_ascii.
12992 * regcache.c (registers_to_string, collect_register_as_string):
12994 * remote-utils.c (look_up_one_symbol, relocate_instruction):
12996 * server.c (process_serial_event): Likewise.
12997 * tracepoint.c (cmd_qtstatus, response_source, response_tsv)
12998 (cmd_qtbuffer, cstr_to_hexstr): Likewise.
13000 2014-02-12 Tom Tromey <tromey@redhat.com>
13002 * remote-utils.c (look_up_one_symbol, monitor_output): Use
13003 bin2hex, not hexify.
13004 * tracepoint.c (cmd_qtstatus): Likewise.
13006 2014-02-12 Tom Tromey <tromey@redhat.com>
13008 * remote-utils.c (monitor_output): Pass explicit length to
13011 2014-02-12 Tom Tromey <tromey@redhat.com>
13013 * tracepoint.c: Include rsp-low.h.
13014 * server.c: Include rsp-low.h.
13015 * remote-utils.h (convert_ascii_to_int, convert_int_to_ascii)
13016 (unhexify, hexify, remote_escape_output, unpack_varlen_hex): Don't
13018 * remote-utils.c: Include rsp-low.h.
13019 (fromhex, hexchars, ishex, unhexify, tohex, hexify)
13020 (remote_escape_output, remote_unescape_input, unpack_varlen_hex)
13021 (convert_int_to_ascii, convert_ascii_to_int): Move to
13023 * regcache.c: Include rsp-low.h.
13024 * ax.c: Include rsp-low.h.
13025 * Makefile.in (SFILES): Add common/rsp-low.c.
13026 (OBS): Add rsp-low.o.
13027 (rsp-low.o): New target.
13029 2014-02-12 Tom Tromey <tromey@redhat.com>
13031 * utils.h (pulongest, plongest, phex_nz): Don't declare.
13032 Include print-utils.h.
13033 * utils.c (NUMCELLS, CELLSIZE, get_cell, decimal2str, pulongest)
13034 (plongest, thirty_two, phex_nz): Remove.
13035 * Makefile.in (SFILES): Add common/print-utils.c.
13036 (OBS): Add print-utils.o.
13037 (print-utils-ipa.o): New target.
13038 (print-utils.o): New target.
13039 (IPA_OBJS): Add print-utils-ipa.o.
13041 2014-02-06 Tom Tromey <tromey@redhat.com>
13043 * Makefile.in (SFILES): Fix indentation.
13045 2014-02-05 Doug Evans <dje@google.com>
13047 * linux-low.c (linux_wait_for_event): Improve comment.
13048 (linux_wait_1): Keep current_inferior in sync with event_child.
13050 2014-01-22 Doug Evans <dje@google.com>
13052 * gdbthread.h (gdb_id_to_thread): Delete, unused.
13054 2014-01-22 Doug Evans <dje@google.com>
13056 * configure.ac (AC_CHECK_FUNCS): Add test for gettimeofday.
13057 * configure: Regenerate.
13058 * config.in: Regenerate.
13059 * Makefile.in (SFILES): Add debug.c.
13060 (OBS): Add debug.o.
13061 * debug.c: New file.
13062 * debug.h: New file.
13063 * linux-aarch64-low.c (*): Update all debugging printfs to use
13064 debug_printf instead of fprintf.
13065 * linux-arm-low.c (*): Ditto.
13066 * linux-cris-low.c (*): Ditto.
13067 * linux-crisv32-low.c (*): Ditto.
13068 * linux-m32r-low.c (*): Ditto.
13069 * linux-sparc-low.c (*): Ditto.
13070 * linux-x86.c (*): Ditto.
13071 * linux-low.c (*): Ditto.
13072 (linux_wait_1): Add calls to debug_enter, debug_exit.
13073 (linux_wait): Remove redundant debugging printf.
13074 (stop_all_lwps): Add calls to debug_enter, debug_exit.
13075 (linux_resume, unstop_all_lwps): Ditto.
13076 * mem-break.c (*): Update all debugging printfs to use
13077 debug_printf instead of fprintf.
13078 * remote-utils.c (*): Ditto.
13079 * thread-db.c (*): Ditto.
13080 * server.c #include <ctype.h>, "gdb_vecs.h".
13081 (debug_threads): Moved to debug.c.
13082 (*): Update all debugging printfs to use debug_printf instead of
13084 (start_inferior): Replace call to fflush with call to debug_flush.
13085 (monitor_show_help): Mention set debug-format.
13086 (parse_debug_format_options): New function.
13087 (handle_monitor_command): Handle "monitor set debug-format".
13088 (gdbserver_usage): Mention --debug-format.
13089 (main): Parse --debug-format.
13090 * server.h (debug_threads): Declaration moved to debug.h.
13091 #include "debug.h".
13092 * tracepoint.c (trace_debug_1) [!IN_PROCESS_AGENT]: Add version of
13093 trace_debug_1 that uses debug_printf.
13094 (tracepoint_look_up_symbols): Update all debugging printfs to use
13095 debug_printf instead of fprintf.
13097 2014-01-20 Baruch Siach <baruch@tkos.co.il>
13099 * linux-xtensa-low.c: Include asm/ptrace.h instead of
13102 2014-01-17 Pedro Alves <palves@redhat.com>
13105 * linux-x86-low.c: Don't include elf/common.h if ELFMAG0 is
13106 defined after including gdb_proc_service.h.
13108 2014-01-16 Doug Evans <dje@google.com>
13110 * dll.c (UNSPECIFIED_CORE_ADDR): New macro.
13111 (match_dll): Use it.
13113 2014-01-16 Markus Metzger <markus.t.metzger@intel.com>
13115 * target.h (target_ops) <read_btrace>: Change parameters and
13116 return type to allow error reporting.
13117 * server.c (handle_qxfer_btrace): Support delta reads. Pass
13118 trace reading errors on.
13119 * linux-low.c (linux_low_read_btrace): Pass trace reading
13121 (linux_low_disable_btrace): New.
13123 2014-01-15 Doug Evans <dje@google.com>
13125 * inferiors.c (thread_id_to_gdb_id): Delete.
13126 * inferiors.h (thread_id_to_gdb_id): Delete.
13128 2014-01-13 Eli Zaretskii <eliz@gnu.org>
13130 * Makefile.in (INCLUDE_CFLAGS): Remove trailing slash from
13131 "-I$(srcdir)/../". Fixes MinGW compilation errors with old GCC
13134 2014-01-08 Pedro Alves <palves@redhat.com>
13136 * server.c (handle_status): Don't discard previous queued stop
13137 replies or thread's pending status here.
13138 (main) <disconnection>: Do it here instead.
13140 2014-01-08 Pedro Alves <palves@redhat.com>
13142 * gdbthread.h (struct thread_info) <status_pending_p>: New field.
13143 * server.c (visit_actioned_threads, handle_pending_status): New
13145 (handle_v_cont): Factor out parts to ...
13146 (resume): ... this new function. If in all-stop, and a thread
13147 being resumed has a pending status, report it without actually
13149 (myresume): Adjust to use the new 'resume' function.
13150 (clear_pending_status_callback, set_pending_status_callback)
13151 (find_status_pending_thread_callback): New functions.
13152 (handle_status): Handle the case of multiple threads having
13153 interesting statuses to report. Report threads' real last signal
13154 instead of always reporting GDB_SIGNAL_TRAP. Look for a thread
13155 with an interesting thread to report the status for, instead of
13156 always reporting the status of the first thread.
13158 2014-01-01 Joel Brobecker <brobecker@adacore.com>
13160 * gdbserver.c (gdbserver_version): Set copyright year to 2014.
13161 * gdbreplay.c (gdbreplay_version): Likewise.
13163 2013-12-18 Yufeng Zhang <yufeng.zhang@arm.com>
13165 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Set
13166 iov.iov_len with the real length in use.
13168 2013-12-13 Joel Brobecker <brobecker@adacore.com>
13170 * Makefile.in (safe-ctype.o, lbasename.o): New rules.
13171 * configure.srv: Add safe-ctype.o and lbasename.o to srv_tgtobj
13172 for all targets that use win32-low.c.
13173 * win32-low.c (win32_ensure_ntdll_loaded): New function.
13174 (do_initial_child_stuff): Add call to win32_ensure_ntdll_loaded.
13176 2013-12-13 Pedro Alves <palves@redhat.com>
13178 * target.c (mywait): Set OURSTATUS->KIND to TARGET_WAITKIND_STOPPED
13179 if equal to TARGET_WAITKIND_LOADED.
13180 * win32-low.c (cached_status): New static global.
13181 (win32_wait): Add declaration.
13182 (do_initial_child_stuff): Flush all initial pending debug events
13183 up to the initial breakpoint.
13184 (win32_wait): If CACHED_STATUS was set, return that instead
13185 of doing a real wait. Remove the code resuming the execution
13186 of the inferior after receiving a TARGET_WAITKIND_LOADED event
13187 during the initial phase. Also remove the code changing
13188 OURSTATUS->KIND from TARGET_WAITKIND_LOADED to
13189 TARGET_WAITKIND_STOPPED.
13191 2013-12-11 Yao Qi <yao@codesourcery.com>
13193 * notif.c (handle_notif_ack): Return 0 if no notification
13196 2013-11-20 Doug Evans <dje@google.com>
13198 * linux-low.c (linux_set_resume_request): Fix comment.
13200 2013-11-20 Doug Evans <dje@google.com>
13202 * linux-low.c (resume_status_pending_p): Tweak comment.
13204 2013-11-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
13206 * Makefile.in: Add i386-mpx.c, i386-mpx-linux.c, amd64-mpx.c,
13207 amd64-mpx-linux.c, x32-mpx.c and x32-mpx-linux.c generation.
13208 * configure.srv (srv_i386_regobj): Add i386-mpx.o.
13209 (srv_i386_linux_regobj): Add i386-mpx-linux.o.
13210 (srv_amd64_regobj): Add amd64-mpx.o.
13211 (srv_amd64_linux_regobj): Add amd64-mpx-linux.o.
13212 (srv_i386_32bit_xmlfiles): Add i386/32bit-mpx.xml.
13213 (srv_i386_64bit_xmlfiles): Add i386/64bit-mpx.xml.
13214 * i387-fp.c (num_pl_bnd_register) Added constant.
13215 (num_pl_bnd_cfg_registers) Added constant.
13216 (struct i387_xsave) Added reserved area and MPX fields.
13217 (i387_cache_to_xsave, i387_xsave_to_cache) Add MPX.
13218 * linux-x86-low.c (init_registers_i386_mpx_linux): Declare new
13220 (tdesc_i386_mpx_linux): Add MPX amd64 target.
13221 (init_registers_amd64_mpx_linux): Declare new function.
13222 (tdesc_amd64_mpx_linux): Add MPX amd64 target.
13223 (x86_64_regmap): Add MPX registers.
13224 (x86_linux_read_description): Add MPX case.
13225 (initialize_low_arch): Initialize MPX targets.
13227 2013-11-18 Tom Tromey <tromey@redhat.com>
13229 * configure: Rebuild.
13230 * configure.ac: Don't check for stdlib.h.
13231 * gdbreplay.c: Unconditionally include stdlib.h.
13233 2013-11-18 Tom Tromey <tromey@redhat.com>
13235 * config.in: Rebuild.
13236 * configure: Rebuild.
13237 * configure.ac: Don't use AC_HEADER_DIRENT.
13239 2013-11-18 Tom Tromey <tromey@redhat.com>
13241 * server.h: Don't check HAVE_STRING_H.
13242 * gdbreplay.c: Don't check HAVE_STRING_H.
13243 * configure: Rebuild.
13245 2013-11-18 Tom Tromey <tromey@redhat.com>
13247 * Makefile.in (gdbreplay$(EXEEXT)): Depend on and link against
13250 2013-11-08 Tom Tromey <tromey@redhat.com>
13252 * configure, config.in: Rebuild.
13253 * configure.ac: Remove unused configury.
13255 2013-11-08 Tom Tromey <tromey@redhat.com>
13257 * acinclude.m4: Include common.m4, codeset.m4.
13258 * configure, config.in: Rebuild.
13259 * configure.ac: Use GDB_AC_COMMON.
13261 2013-11-06 Andreas Arnez <arnez@linux.vnet.ibm.com>
13263 * linux-s390-low.c (HWCAP_S390_TE): New define.
13264 (s390_arch_setup): Consider the TE field in the HWCAP for
13265 determining 'have_regset_tdb'.
13267 2013-10-16 Sergio Durigan Junior <sergiodj@redhat.com>
13270 * tracepoint.c (download_tracepoint_1): Remove unnecessary double
13273 2013-10-02 Pedro Alves <palves@redhat.com>
13275 * server.c (process_serial_event): Don't output "GDBserver
13276 exiting" if GDB is connected through stdio.
13277 * target.c (mywait): Likewise, be silent if GDB is connected
13280 2013-10-01 Joel Brobecker <brobecker@adacore.com>
13282 * lynx-low.c (lynx_add_threads_after_attach): New function.
13283 (lynx_attach): Remove call to add_thread. Add call to
13284 lynx_add_threads_after_attach instead.
13286 2013-09-28 Mike Frysinger <vapier@gentoo.org>
13288 * configure.ac (AC_CHECK_HEADERS): Add sys/syscall.h
13289 * config.in, configure: Regenerated.
13291 2013-09-18 Yao Qi <yao@codesourcery.com>
13294 * server.c (start_inferior): Clear 'resume_info'.
13296 2013-09-16 Jiong Wang <jiwang@tilera.com>
13298 * linux-tile-low.c (tile_regsets): Modify the size field to 64-bit
13301 2013-09-16 Jiong Wang <jiwang@tilera.com>
13303 * configure.srv <tilegx*-*-linux*>: Remove linux-osdata.o from and add
13304 linux-tile-low.o to srv_tgtobj.
13306 2013-09-16 Will Newton <will.newton@linaro.org>
13308 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Zero
13311 2013-09-06 Pedro Alves <palves@redhat.com>
13313 * Makefile.in (gdb_proc_service_h, regdef_h, regcache_h)
13314 (signals_def, signals_h, ptid_h, ax_h, agent_h, linux_btrace_h)
13315 (linux_osdata_h, vec_h, gdb_vecs_h, host_defs_h, libiberty_h)
13316 (server_h, gdbthread_h, linux_low_h, linux_ptrace_h)
13317 (gdb_thread_db_h, linux_procfs_h, lynx_low_h, nto_low_h)
13318 (mips_linux_watch_h, i386_low_h, win32_low_h): Delete.
13320 2013-09-06 Pedro Alves <palves@redhat.com>
13322 * Makefile.in (linux-btrace.o, mips-linux-watch.o): Remove
13323 explicit header dependencies and use $COMPILE/$POSTCOMPILE.
13325 2013-09-06 Pedro Alves <palves@redhat.com>
13327 * linux-amd64-ipa.c: Include tracepoint.h.
13328 * linux-i386-ipa.c: Include tracepoint.h.
13330 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
13332 * linux-crisv32-low.c (PTRACE_GET_THREAD_AREA): New macro.
13333 (ps_get_thread_area): New function.
13335 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
13337 * linux-crisv32-low.c (elf_gregset_t): Delete typedef.
13338 (initialize_low_arch): Call init_registers_crisv32 rather than
13339 init_register_crisv32.
13341 2013-09-05 Pedro Alves <palves@redhat.com>
13343 * server.h (handle_vFile, hostio_last_error_from_errno): Move
13345 * hostio.h: ... this new file.
13346 * hostio.c, server.c, linux-low.c, nto-low.c, spu-low,
13347 win32-low.c: Include hostio.h.
13349 2013-09-05 Pedro Alves <palves@redhat.com>
13351 * server.h (gdb_client_data, handler_func, callback_handler_func)
13352 (delete_file_handler, add_file_handler, append_callback_event)
13353 (delete_callback_event, start_event_loop, initialize_event_loop):
13354 Move to event-loop.h and include it.
13355 * event-loop.h: New file.
13357 2013-09-05 Pedro Alves <palves@redhat.com>
13359 * dll.c, inferiors.c, remote-utils.c, server.c: Include "dll.h".
13360 * server.h (struct dll_info, all_dlls, dlls_changed, clear_dlls)
13361 (loaded_dll, unloaded_dll): Move to ...
13362 * dll.h: ... this new file.
13363 * inferiors.c, remote-utils.c, win32-low.c: Include "dll.h".
13365 2013-09-05 Pedro Alves <palves@redhat.com>
13367 * server.h (current_process, get_thread_process, all_processes)
13368 (add_inferior_to_list, for_each_inferior, current_inferior)
13369 (remove_inferior, add_process, remove_process, find_process_pid)
13370 (have_started_inferiors_p, have_attached_inferiors_p)
13371 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id)
13372 (clear_inferiors, find_inferior, find_inferior_id)
13373 (inferior_target_data, set_inferior_target_data)
13374 (inferior_regcache_data, set_inferior_regcache_data): Move to
13375 inferiors.h, and include it.
13376 * inferiors.h: New file.
13378 2013-09-05 Pedro Alves <palves@redhat.com>
13380 * server.h (struct emit_ops, current_insn_ptr, emit_error):
13384 2013-09-05 Pedro Alves <palves@redhat.com>
13386 * ax.c, linux-low.c, linux-x86-low.c, server.c: Include
13388 * server.h (IPA_BUFSIZ, initialize_tracepoint, tracing)
13389 (disconnected_tracing, tracepoint_look_up_symbols, stop_tracing
13390 (handle_tracepoint_general_set, handle_tracepoint_query)
13391 (tracepoint_finished_step, tracepoint_was_hit)
13392 (release_while_stepping_state_list, current_traceframe)
13393 (in_readonly_region, traceframe_read_mem)
13394 (fetch_traceframe_registers, traceframe_read_sdata)
13395 (traceframe_read_info, struct fast_tpoint_collect_status)
13396 (fast_tracepoint_collecting, force_unlock_trace_buffer)
13397 (handle_tracepoit_bkpts, initialize_low_tracepoint)
13398 (supply_fast_tracepoint_registers)
13399 (supply_static_tracepoint_registers, set_trampoline_buffer_space)
13400 (ipa_tdesc, claim_trampoline_space)
13401 (have_fast_tracepoint_trampoline_buffer, gdb_agent_about_to_close)
13402 (agent_mem_read, agent_get_trace_state_variable_value)
13403 (agent_set_trace_state_variable_value, agent_tsv_read)
13404 (agent_mem_read_string, get_raw_reg_func_addr)
13405 (get_get_tsv_func_addr, get_set_tsv_func_addr): Move to ...
13406 * tracepoint.h: ... this new file.
13408 2013-09-05 Pedro Alves <palves@redhat.com>
13410 * server.h (perror_with_name, error, fatal, warning, paddress)
13411 (pulongest, plongest, phex_nz, pfildes): Move to utils.h, and
13413 * utils.h: New file.
13415 2013-09-05 Pedro Alves <palves@redhat.com>
13417 * server.h (remote_debug, noack_mode, transport_is_reliable)
13418 (gdb_connected, STDIO_CONNECTION_NAME, remote_connection_is_stdio)
13419 (read_ptid, write_ptid, putpkt, putpkt_binary, putpkt_notif)
13420 (getpkt, remote_prepare, remote_open, remote_close, write_ok)
13421 (write_enn, initialize_async_io, enable_async_io)
13422 (disable_async_io, check_remote_input_interrupt_request)
13423 (convert_ascii_to_int, convert_int_to_ascii, new_thread_notify)
13424 (dead_thread_notify, prepare_resume_reply)
13425 (decode_address_to_semicolon, decode_address, decode_m_packet)
13426 (decode_M_packet, decode_X_packet, decode_xfer_write)
13427 (decode_search_memory_packet, unhexify, hexify)
13428 (remote_escape_output, unpack_varlen_hex, clear_symbol_cache)
13429 (look_up_one_symbol, relocate_instruction)
13430 (monitor_output): Move to remote-utils.h, and include it.
13431 * remote-utils.h: New file.
13433 2013-09-05 Pedro Alves <palves@redhat.com>
13435 * server.h (_): Delete.
13437 2013-09-02 Pedro Alves <palves@redhat.com>
13439 * tracepoint.c (TRACEFRAME_EOB_MARKER_SIZE): New macro.
13440 (init_trace_buffer): Ensure at least TRACEFRAME_EOB_MARKER_SIZE is
13442 (trace_buffer_alloc): Use TRACEFRAME_EOB_MARKER_SIZE.
13444 2013-09-02 Pierre Muller <muller@sourceware.org>
13446 * win32-low.c (child_xfer_memory): Check if ReadProcessMemory
13447 or WriteProcessMemory complete successfully and handle
13448 ERROR_PARTIAL_COPY error.
13450 2013-09-02 Pedro Alves <palves@redhat.com>
13452 * server.c (gdb_read_memory): Return -1 on traceframe memory read
13453 error instead of EIO.
13455 2013-08-28 Jan Kratochvil <jan.kratochvil@redhat.com>
13458 * linux-low.c: Include filestuff.h.
13459 (linux_create_inferior) <pid == 0>: Call close_most_fds.
13460 * lynx-low.c: Include filestuff.h.
13461 (lynx_create_inferior) <pid == 0>: Call close_most_fds.
13462 * server.c: Include filestuff.h.
13463 (main): Call notice_open_fds.
13464 * spu-low.c: Include filestuff.h.
13465 (spu_create_inferior) <pid == 0>: Call close_most_fds.
13467 2013-08-22 Luis Machado <lgustavo@codesourcery.com>
13469 * Makefile.in: Explain why ../target and ../nat are not
13470 listed as include file search paths.
13471 (linux-waitpid.o): New object file rule.
13472 * configure.srv (srv_native_linux_obj): New variable.
13473 Replace all occurrences of linux native object files with
13474 $srv_native_linux_obj.
13475 * linux-low.c: Include nat/linux-nat.h and nat/linux-waitpid.h.
13476 (HAS_NOMMU): Move defining logic to common/linux-ptrace.c.
13477 (linux_enable_event_reporting): Remove declaration.
13478 (my_waitpid): Moved to common/linux-waitpid.c.
13479 (linux_wait_for_event): Pass ptid when calling
13480 linux_enable_event_reporting.
13481 (linux_supports_tracefork_flag): Remove.
13482 (linux_enable_event_reporting): Likewise.
13483 (linux_tracefork_grandchild): Remove.
13484 (STACK_SIZE): Moved to common/linux-ptrace.c.
13485 (linux_tracefork_child): Remove.
13486 (linux_test_for_tracefork): Remove.
13487 (linux_look_up_symbols): Call linux_supports_traceclone.
13488 (initialize_low): Remove call to linux_test_for_tracefork.
13489 * linux-low.h (PTRACE_TYPE_ARG3): Move to
13490 common/linux-ptrace.h.
13491 (PTRACE_TYPE_ARG4): Likewise.
13492 Include linux-ptrace.h.
13494 2013-08-21 Pedro Alves <palves@redhat.com>
13496 * config.in: Renegerate.
13498 2013-08-19 Luis Machado <lgustavo@codesourcery.com>
13500 * Makefile.in (INCLUDE_CFLAGS): Include -I$(srcdir)/../.
13501 (SFILES): Remove $(srcdir)/common/target-common.c and
13502 add $(srcdir)/target/waitstatus.c.
13503 (OBS): Remove target-common.o and add waitstatus.o.
13504 (server_h): Remove $(srcdir)/../common/target-common.h and
13505 add $(srcdir)/../target/resume.h, $(srcdir)/../target/wait.h
13506 and $(srcdir)/../target/waitstatus.h.
13507 (target-common.o): Remove.
13508 (waitstatus.o): New target object file.
13509 * target.h: Do not include target-common.h and
13510 include target/resume.h, target/wait.h and
13511 target/waitstatus.h.
13513 2013-08-13 Luis Machado <lgustavo@codesourcery.com>
13515 * linux-arm-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
13516 to PTRACE_TYPE_ARG3.
13517 * linux-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
13518 to PTRACE_TYPE_ARG3 and PTRACE_ARG4_TYPE to
13520 * linux-low.h (PTRACE_ARG3_TYPE): Rename to PTRACE_TYPE_ARG3.
13521 (PTRACE_ARG4_TYPE): Rename to PTRACE_TYPE_ARG4.
13523 2013-07-27 Jie Zhang <jie@codesourcery.com>
13524 Daniel Jacobowitz <dan@codesourcery.com>
13525 Yao Qi <yao@codesourcery.com>
13527 * Makefile.in (SFILES): Add common/mips-linux-watch.c.
13528 (mips-linux-watch.o): New rule.
13529 (mips_linux_watch_h): New variable.
13530 * configure.srv <mips*-*-linux*>: Add mips-linux-watch.o to
13532 * linux-mips-low.c: Include mips-linux-watch.h.
13533 (struct arch_process_info, struct arch_lwp_info): New.
13534 (update_watch_registers_callback): New function.
13535 (mips_linux_new_process, mips_linux_new_thread) New functions.
13536 (mips_linux_prepare_to_resume, mips_insert_point): New
13538 (mips_remove_point, mips_stopped_by_watchpoint): New
13540 (rsp_bp_type_to_target_hw_bp_type): New function.
13541 (mips_stopped_data_address): New function.
13542 (the_low_target): Add watchpoint support functions.
13544 2013-07-27 Yao Qi <yao@codesourcery.com>
13546 * i386-low.c: Include break-common.h.
13547 (enum target_hw_bp_type): Remove.
13549 2013-07-24 Luis Machado <lgustavo@codesourcery.com>
13551 * Makefile.in (SFILES): /common/target-common.c.
13552 (OBS): Add target-common.o.
13553 (server_h): Add $(srcdir)/../common/target-common.h.
13554 (target-common.o): New target.
13555 * server.c (queue_stop_reply_callback): Free
13556 status string after use.
13557 * target.c (target_waitstatus_to_string): Remove.
13558 * target.h: Include target-common.h.
13559 (resume_kind): Likewise.
13560 (target_waitkind): Likewise.
13561 (target_waitstatus): Likewise.
13562 (TARGET_WNOHANG): Likewise.
13564 2013-07-04 Yao Qi <yao@codesourcery.com>
13566 * Makefile.in (host_alias): Use @host_noncanonical@.
13567 (target_alias): Use @target_noncanonical@.
13568 * configure.ac: Use ACX_NONCANONICAL_TARGET and
13569 ACX_NONCANONICAL_HOST.
13570 * configure: Regenerated.
13573 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
13575 * configure.ac (version_host, version_target): Set and AC_SUBST them.
13576 * configure: Rebuild.
13577 * Makefile.in (version_host, version_target): Get from configure.
13578 (version.c): Use $(version_host) and $(version_target).
13580 2013-07-03 Pedro Alves <palves@redhat.com>
13582 * Makefile.in (config.status): Depend on development.sh.
13583 * acinclude.m4: Include libmcheck.m4.
13584 * configure: Regenerate.
13586 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
13588 * win32-low.c (winapi_DebugActiveProcessStop): Move the WINAPI
13589 attribute inside the parentheses.
13590 (winapi_DebugSetProcessKillOnExit): Ditto.
13591 (winapi_DebugBreakProcess): Ditto.
13592 (winapi_GenerateConsoleCtrlEvent): Ditto.
13594 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
13596 * notif.h (notif_event): Add a dummy member to avoid compiler
13599 2013-07-01 Pedro Alves <palves@redhat.com>
13601 * hostio.c (HOSTIO_PATH_MAX): Define.
13602 (require_filename, handle_open, handle_unlink, handle_readlink):
13605 2013-07-01 Pedro Alves <palves@redhat.com>
13607 * server.h: Include "pathmax.h".
13608 * linux-low.c: Don't include sys/param.h.
13609 (linux_pid_exe_is_elf_64_file): Use PATH_MAX instead of
13611 * win32-low.c: Don't include sys/param.h.
13612 (win32_create_inferior): Use PATH_MAX instead of MAXPATHLEN.
13614 2013-07-01 Pedro Alves <palves@redhat.com>
13616 * event-loop.c: Don't check HAVE_UNISTD_H before including
13618 * gdbreplay.c: Likewise.
13619 * remote-utils.c: Likewise.
13620 * server.c: Likewise.
13621 * configure.ac: Don't check for unistd.h.
13622 * configure: Regenerate.
13624 2013-06-28 Tom Tromey <tromey@redhat.com>
13626 * Makefile.in (version.c): Use version.in, not
13629 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
13631 * configure.ac (version_host, version_target): Set and AC_SUBST them.
13632 * configure: Rebuild.
13633 * Makefile.in (version_host, version_target): Get from configure.
13634 (version.c): Use $(version_host) and $(version_target).
13636 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
13638 Fix trace-status to output user name without trailing colon.
13639 * tracepoint.c (cmd_qtstatus): Remove unnecessary colon from user name.
13641 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
13643 Fix trace-status to output proper start-time and stop-time.
13644 * tracepoint.c (cmd_qtstatus): Modify trace-status output to
13645 output start time and stop time in hex as gdb expects.
13647 2013-06-26 Pedro Alves <pedro@codesourcery.com>
13649 * tracepoint.c (build_traceframe_info_xml): Output trace state
13650 variables present in the trace buffer.
13652 2013-06-24 Tom Tromey <tromey@redhat.com>
13654 * Makefile.in (version.c): Use bfd/version.h, common/version.in,
13656 (version.o): Remove.
13657 * gdbreplay.c: Include version.h.
13658 (version, host_name): Don't declare.
13659 * server.h: Include version.h.
13660 (version, host_name): Don't declare.
13662 2013-06-12 Pedro Alves <palves@redhat.com>
13664 * linux-x86-low.c (linux_is_elf64): Delete global.
13665 (x86_siginfo_fixup): Replace reference to `linux_is_elf64' global
13666 with local linux_pid_exe_is_elf_64_file use.
13668 2013-06-11 Pedro Alves <palves@redhat.com>
13670 * linux-low.c (regset_disabled, disable_regset): New functions.
13671 (regsets_fetch_inferior_registers)
13672 (regsets_store_inferior_registers): Use them.
13673 (initialize_regsets_info); Don't allocate the disabled_regsets
13675 * linux-low.h (struct regsets_info) <disabled_regsets>: Extend
13678 2013-06-11 Pedro Alves <palves@redhat.com>
13680 * linux-low.c (initialize_regsets_info): Use xcalloc instead of
13683 2013-06-11 Pedro Alves <palves@redhat.com>
13685 * linux-x86-low.c (initialize_low_arch): Call
13686 init_registers_x32_avx_linux.
13688 2013-06-09 Jan Kratochvil <jan.kratochvil@redhat.com>
13690 Fix compatibility with Android Bionic.
13691 * linux-low.c (linux_qxfer_libraries_svr4): Ignore first entry even if
13694 2013-06-07 Pedro Alves <palves@redhat.com>
13697 * Makefile.in (OBS): Add tdesc.o.
13698 (IPA_OBJS): Add tdesc-ipa.o.
13699 (tdesc-ipa.o): New rule.
13700 * ax.c (gdb_eval_agent_expr): Adjust register_size call to new
13702 * linux-low.c (new_inferior): Delete.
13703 (disabled_regsets, num_regsets): Delete.
13704 (linux_add_process): Adjust to set the new per-process
13706 (linux_detach_one_lwp): Adjust to call regcache_invalidate_thread.
13707 (linux_wait_for_lwp): Adjust. Only call arch_setup if the event
13708 was a stop. When calling arch_setup, switch the current inferior
13709 to the thread that got an event.
13710 (linux_resume_one_lwp): Adjust to call regcache_invalidate_thread.
13711 (regsets_fetch_inferior_registers)
13712 (regsets_store_inferior_registers): New regsets_info parameter.
13714 (linux_register_in_regsets): New regs_info parameter. Adjust to
13716 (register_addr, fetch_register, store_register): New usrregs_info
13717 parameter. Adjust to use it.
13718 (usr_fetch_inferior_registers, usr_store_inferior_registers): New
13719 parameter regs_info. Adjust to use it.
13720 (linux_fetch_registers): Get the current inferior's regs_info, and
13722 (linux_store_registers): Ditto.
13723 [HAVE_LINUX_REGSETS] (initialize_regsets_info): New.
13724 (initialize_low): Don't initialize the target_regsets here. Call
13725 initialize_low_arch.
13726 * linux-low.h (target_regsets): Delete declaration.
13727 (struct regsets_info): New.
13728 (struct usrregs_info): New.
13729 (struct regs_info): New.
13730 (struct process_info_private) <new_inferior>: New field.
13731 (struct linux_target_ops): Delete the num_regs, regmap, and
13732 regset_bitmap fields. New field regs_info.
13733 [HAVE_LINUX_REGSETS] (initialize_regsets_info): Declare.
13734 * i387-fp.c (num_xmm_registers): Delete.
13735 (i387_cache_to_fsave, i387_fsave_to_cache): Adjust find_regno
13736 calls to new interface.
13737 (i387_cache_to_fxsave, i387_cache_to_xsave, i387_fxsave_to_cache)
13738 (i387_xsave_to_cache): Adjust find_regno calls to new interface.
13739 Infer the number of xmm registers from the regcache's target
13741 * i387-fp.h (num_xmm_registers): Delete.
13742 * inferiors.c (add_thread): Don't install the thread's regcache
13744 * proc-service.c (gregset_info): Fetch the current inferior's
13745 regs_info. Adjust to use it.
13746 * regcache.c: Include tdesc.h.
13747 (register_bytes, reg_defs, num_registers)
13748 (gdbserver_expedite_regs): Delete.
13749 (get_thread_regcache): If the thread doesn't have a regcache yet,
13750 create one, instead of aborting gdbserver.
13751 (regcache_invalidate_one): Rename to ...
13752 (regcache_invalidate_thread): ... this.
13753 (regcache_invalidate_one): New.
13754 (regcache_invalidate): Only invalidate registers of the current
13756 (init_register_cache): Add target_desc parameter, and use it.
13757 (new_register_cache): Ditto. Assert the target description has a
13758 non zero registers_size.
13759 (regcache_cpy): Add assertions. Adjust.
13760 (realloc_register_cache, set_register_cache): Delete.
13761 (registers_to_string, registers_from_string): Adjust.
13762 (find_register_by_name, find_regno, find_register_by_number)
13763 (register_cache_size): Add target_desc parameter, and use it.
13764 (free_register_cache_thread, free_register_cache_thread_one)
13765 (regcache_release, register_cache_size): New.
13766 (register_size): Add target_desc parameter, and use it.
13767 (register_data, supply_register, supply_register_zeroed)
13768 (supply_regblock, supply_register_by_name, collect_register)
13769 (collect_register_as_string, collect_register_by_name): Adjust.
13770 * regcache.h (struct target_desc): Forward declare.
13771 (struct regcache) <tdesc>: New field.
13772 (init_register_cache, new_register_cache): Add target_desc
13774 (regcache_invalidate_thread): Declare.
13775 (regcache_invalidate_one): Delete declaration.
13776 (regcache_release): Declare.
13777 (find_register_by_number, register_cache_size, register_size)
13778 (find_regno): Add target_desc parameter.
13779 (gdbserver_expedite_regs, gdbserver_xmltarget): Delete
13781 * remote-utils.c: Include tdesc.h.
13782 (outreg, prepare_resume_reply): Adjust.
13783 * server.c: Include tdesc.h.
13784 (gdbserver_xmltarget): Delete declaration.
13785 (get_features_xml, process_serial_event): Adjust.
13786 * server.h [IN_PROCESS_AGENT] (struct target_desc): Forward
13788 (struct process_info) <tdesc>: New field.
13789 (ipa_tdesc): Declare.
13790 * tdesc.c: New file.
13791 * tdesc.h: New file.
13792 * tracepoint.c: Include tdesc.h.
13793 [IN_PROCESS_AGENT] (ipa_tdesc): Define.
13794 (get_context_regcache): Adjust to pass ipa_tdesc down.
13795 (do_action_at_tracepoint): Adjust to get the register cache size
13796 from the context regcache's description.
13797 (traceframe_walk_blocks): Adjust to get the register cache size
13798 from the current trace frame's description.
13799 (traceframe_get_pc): Adjust to get current trace frame's
13800 description and pass it down.
13801 (gdb_collect): Adjust to get the register cache size from the
13803 * linux-amd64-ipa.c (tdesc_amd64_linux): Declare.
13804 (gdbserver_xmltarget): Delete.
13805 (initialize_low_tracepoint): Set the ipa's target description.
13806 * linux-i386-ipa.c (tdesc_i386_linux): Declare.
13807 (initialize_low_tracepoint): Set the ipa's target description.
13808 * linux-x86-low.c: Include tdesc.h.
13809 [__x86_64__] (is_64bit_tdesc): New.
13810 (ps_get_thread_area, x86_get_thread_area): Use it.
13811 (i386_cannot_store_register): Rename to ...
13812 (x86_cannot_store_register): ... this. Use is_64bit_tdesc.
13813 (i386_cannot_fetch_register): Rename to ...
13814 (x86_cannot_fetch_register): ... this. Use is_64bit_tdesc.
13815 (x86_fill_gregset, x86_store_gregset): Adjust register_size calls
13817 (target_regsets): Rename to ...
13818 (x86_regsets): ... this.
13819 (x86_get_pc, x86_set_pc): Adjust register_size calls to new
13821 (x86_siginfo_fixup): Use is_64bit_tdesc.
13822 [__x86_64__] (tdesc_amd64_linux, tdesc_amd64_avx_linux)
13823 (tdesc_x32_avx_linux, tdesc_x32_linux)
13824 (tdesc_i386_linux, tdesc_i386_mmx_linux, tdesc_i386_avx_linux):
13826 (x86_linux_update_xmltarget): Delete.
13827 (I386_LINUX_XSAVE_XCR0_OFFSET): Define.
13828 (have_ptrace_getfpxregs, have_ptrace_getregset): New.
13829 (AMD64_LINUX_USER64_CS): New.
13830 (x86_linux_read_description): New, based on
13831 x86_linux_update_xmltarget.
13832 (same_process_callback): New.
13833 (x86_arch_setup_process_callback): New.
13834 (x86_linux_update_xmltarget): New.
13835 (x86_regsets_info): New.
13836 (amd64_linux_regs_info): New.
13837 (i386_linux_usrregs_info): New.
13838 (i386_linux_regs_info): New.
13839 (x86_linux_regs_info): New.
13840 (x86_arch_setup): Reimplement.
13841 (x86_install_fast_tracepoint_jump_pad): Use is_64bit_tdesc.
13842 (x86_emit_ops): Ditto.
13843 (the_low_target): Adjust. Install x86_linux_regs_info,
13844 x86_cannot_fetch_register, and x86_cannot_store_register.
13845 (initialize_low_arch): New.
13846 * linux-ia64-low.c (tdesc_ia64): Declare.
13847 (ia64_fetch_register): Adjust.
13848 (ia64_usrregs_info, regs_info): New globals.
13849 (ia64_regs_info): New function.
13850 (the_low_target): Adjust.
13851 (initialize_low_arch): New function.
13852 * linux-sparc-low.c (tdesc_sparc64): Declare.
13853 (sparc_fill_gregset_to_stack, sparc_store_gregset_from_stack):
13855 (sparc_arch_setup): New function.
13856 (sparc_regsets_info, sparc_usrregs_info, regs_info): New globals.
13857 (the_low_target): Adjust.
13858 (initialize_low_arch): New function.
13859 * linux-ppc-low.c (tdesc_powerpc_32l, tdesc_powerpc_altivec32l)
13860 (tdesc_powerpc_cell32l, tdesc_powerpc_vsx32l)
13861 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_altivec32l)
13862 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_e500l)
13863 (tdesc_powerpc_64l, tdesc_powerpc_altivec64l)
13864 (tdesc_powerpc_cell64l, tdesc_powerpc_vsx64l)
13865 (tdesc_powerpc_isa205_64l, tdesc_powerpc_isa205_altivec64l)
13866 (tdesc_powerpc_isa205_vsx64l): Declare.
13867 (ppc_cannot_store_register, ppc_collect_ptrace_register)
13868 (ppc_supply_ptrace_register, parse_spufs_run, ppc_get_pc)
13869 (ppc_set_pc, ppc_get_hwcap): Adjust.
13870 (ppc_usrregs_info): Forward declare.
13871 (!__powerpc64__) ppc_regmap_adjusted: New global.
13872 (ppc_arch_setup): Adjust to the current process'es target
13874 (ppc_fill_vsxregset, ppc_store_vsxregset, ppc_fill_vrregset)
13875 (ppc_store_vrregset, ppc_fill_evrregset, ppc_store_evrregse)
13876 (ppc_store_evrregset): Adjust.
13877 (target_regsets): Rename to ...
13878 (ppc_regsets): ... this, and make static.
13879 (ppc_usrregs_info, ppc_regsets_info, regs_info): New globals.
13880 (ppc_regs_info): New function.
13881 (the_low_target): Adjust.
13882 (initialize_low_arch): New function.
13883 * linux-s390-low.c (tdesc_s390_linux32, tdesc_s390_linux32v1)
13884 (tdesc_s390_linux32v2, tdesc_s390_linux64, tdesc_s390_linux64v1)
13885 (tdesc_s390_linux64v2, tdesc_s390x_linux64, tdesc_s390x_linux64v1)
13886 (tdesc_s390x_linux64v2): Declare.
13887 (s390_collect_ptrace_register, s390_supply_ptrace_register)
13888 (s390_fill_gregset, s390_store_last_break): Adjust.
13889 (target_regsets): Rename to ...
13890 (s390_regsets): ... this, and make static.
13891 (s390_get_pc, s390_set_pc): Adjust.
13892 (s390_get_hwcap): New target_desc parameter, and use it.
13893 [__s390x__] (have_hwcap_s390_high_gprs): New global.
13894 (s390_arch_setup): Adjust to set the current process'es target
13895 description. Don't adjust the regmap.
13896 (s390_usrregs_info, s390_regsets_info, regs_info): New globals.
13897 [__s390x__] (s390_usrregs_info_3264, s390_regsets_info_3264)
13898 (regs_info_3264): New globals.
13899 (s390_regs_info): New function.
13900 (the_low_target): Adjust.
13901 (initialize_low_arch): New function.
13902 * linux-mips-low.c (tdesc_mips_linux, tdesc_mips_dsp_linux)
13903 (tdesc_mips64_linux, tdesc_mips64_dsp_linux): Declare.
13904 [__mips64] (init_registers_mips_linux)
13905 (init_registers_mips_dsp_linux): Delete defines.
13906 [__mips64] (tdesc_mips_linux, tdesc_mips_dsp_linux): New defines.
13907 (have_dsp): New global.
13908 (mips_read_description): New, based on mips_arch_setup.
13909 (mips_arch_setup): Reimplement.
13910 (get_usrregs_info): New function.
13911 (mips_cannot_fetch_register, mips_cannot_store_register)
13912 (mips_get_pc, mips_set_pc, mips_fill_gregset, mips_store_gregset)
13913 (mips_fill_fpregset, mips_store_fpregset): Adjust.
13914 (target_regsets): Rename to ...
13915 (mips_regsets): ... this, and make static.
13916 (mips_regsets_info, mips_dsp_usrregs_info, mips_usrregs_info)
13917 (dsp_regs_info, regs_info): New globals.
13918 (mips_regs_info): New function.
13919 (the_low_target): Adjust.
13920 (initialize_low_arch): New function.
13921 * linux-arm-low.c (tdesc_arm, tdesc_arm_with_iwmmxt)
13922 (tdesc_arm_with_vfpv2, tdesc_arm_with_vfpv3, tdesc_arm_with_neon):
13924 (arm_fill_vfpregset, arm_store_vfpregset): Adjust.
13925 (arm_read_description): New, with bits factored from
13927 (arm_arch_setup): Reimplement.
13928 (target_regsets): Rename to ...
13929 (arm_regsets): ... this, and make static.
13930 (arm_regsets_info, arm_usrregs_info, regs_info): New globals.
13931 (arm_regs_info): New function.
13932 (the_low_target): Adjust.
13933 (initialize_low_arch): New function.
13934 * linux-m68k-low.c (tdesc_m68k): Declare.
13935 (target_regsets): Rename to ...
13936 (m68k_regsets): ... this, and make static.
13937 (m68k_regsets_info, m68k_usrregs_info, regs_info): New globals.
13938 (m68k_regs_info): New function.
13939 (m68k_arch_setup): New function.
13940 (the_low_target): Adjust.
13941 (initialize_low_arch): New function.
13942 * linux-sh-low.c (tdesc_sharch): Declare.
13943 (target_regsets): Rename to ...
13944 (sh_regsets): ... this, and make static.
13945 (sh_regsets_info, sh_usrregs_info, regs_info): New globals.
13946 (sh_regs_info, sh_arch_setup): New functions.
13947 (the_low_target): Adjust.
13948 (initialize_low_arch): New function.
13949 * linux-bfin-low.c (tdesc_bfin): Declare.
13950 (bfin_arch_setup): New function.
13951 (bfin_usrregs_info, regs_info): New globals.
13952 (bfin_regs_info): New function.
13953 (the_low_target): Adjust.
13954 (initialize_low_arch): New function.
13955 * linux-cris-low.c (tdesc_cris): Declare.
13956 (cris_arch_setup): New function.
13957 (cris_usrregs_info, regs_info): New globals.
13958 (cris_regs_info): New function.
13959 (the_low_target): Adjust.
13960 (initialize_low_arch): New function.
13961 * linux-cris-low.c (tdesc_crisv32): Declare.
13962 (cris_arch_setup): New function.
13963 (cris_regsets_info, cris_usrregs_info, regs_info): New globals.
13964 (cris_regs_info): New function.
13965 (the_low_target): Adjust.
13966 (initialize_low_arch): New function.
13967 * linux-m32r-low.c (tdesc_m32r): Declare.
13968 (m32r_arch_setup): New function.
13969 (m32r_usrregs_info, regs_info): New globals.
13970 (m32r_regs_info): Adjust.
13971 (initialize_low_arch): New function.
13972 * linux-tic6x-low.c (tdesc_tic6x_c64xp_linux)
13973 (tdesc_tic6x_c64x_linux, tdesc_tic6x_c62x_linux): Declare.
13974 (tic6x_usrregs_info): Forward declare.
13975 (tic6x_read_description): New function, based on ...
13976 (tic6x_arch_setup): ... this. Reimplement.
13977 (target_regsets): Rename to ...
13978 (tic6x_regsets): ... this, and make static.
13979 (tic6x_regsets_info, tic6x_usrregs_info, regs_info): New globals.
13980 (tic6x_regs_info): New function.
13981 (the_low_target): Adjust.
13982 (initialize_low_arch): New function.
13983 * linux-xtensa-low.c (tdesc_xtensa): Declare.
13984 (xtensa_fill_gregset, xtensa_store_gregset): Adjust.
13985 (target_regsets): Rename to ...
13986 (xtensa_regsets): ... this, and make static.
13987 (xtensa_regsets_info, xtensa_usrregs_info, regs_info): New
13989 (xtensa_arch_setup, xtensa_regs_info): New functions.
13990 (the_low_target): Adjust.
13991 (initialize_low_arch): New function.
13992 * linux-nios2-low.c (tdesc_nios2_linux): Declare.
13993 (nios2_arch_setup): Set the current process'es tdesc.
13994 (target_regsets): Rename to ...
13995 (nios2_regsets): ... this.
13996 (nios2_regsets_info, nios2_usrregs_info, regs_info): New globals.
13997 (nios2_regs_info): New function.
13998 (the_low_target): Adjust.
13999 (initialize_low_arch): New function.
14000 * linux-aarch64-low.c (tdesc_aarch64): Declare.
14001 (aarch64_arch_setup): Set the current process'es tdesc.
14002 (target_regsets): Rename to ...
14003 (aarch64_regsets): ... this.
14004 (aarch64_regsets_info, aarch64_usrregs_info, regs_info): New globals.
14005 (aarch64_regs_info): New function.
14006 (the_low_target): Adjust.
14007 (initialize_low_arch): New function.
14008 * linux-tile-low.c (tdesc_tilegx, tdesc_tilegx32): Declare
14010 (target_regsets): Rename to ...
14011 (tile_regsets): ... this.
14012 (tile_regsets_info, tile_usrregs_info, regs_info): New globals.
14013 (tile_regs_info): New function.
14014 (tile_arch_setup): Set the current process'es tdesc.
14015 (the_low_target): Adjust.
14016 (initialize_low_arch): New function.
14017 * spu-low.c (tdesc_spu): Declare.
14018 (spu_create_inferior, spu_attach): Set the new process'es tdesc.
14019 * win32-arm-low.c (tdesc_arm): Declare.
14020 (arm_arch_setup): New function.
14021 (the_low_target): Install arm_arch_setup instead of
14022 init_registers_arm.
14023 * win32-i386-low.c (tdesc_i386, tdesc_amd64): Declare.
14024 (init_windows_x86): Rename to ...
14025 (i386_arch_setup): ... this. Set `win32_tdesc'.
14026 (the_low_target): Adjust.
14027 * win32-low.c (win32_tdesc): New global.
14028 (child_add_thread): Don't create the thread cache here.
14029 (do_initial_child_stuff): Set the new process'es tdesc.
14030 * win32-low.h (struct target_desc): Forward declare.
14031 (win32_tdesc): Declare.
14032 * lynx-i386-low.c (tdesc_i386): Declare global.
14033 (lynx_i386_arch_setup): Set `lynx_tdesc'.
14034 * lynx-low.c (lynx_tdesc): New global.
14035 (lynx_add_process): Set the new process'es tdesc.
14036 * lynx-low.h (struct target_desc): Forward declare.
14037 (lynx_tdesc): Declare global.
14038 * lynx-ppc-low.c (tdesc_powerpc_32): Declare global.
14039 (lynx_ppc_arch_setup): Set `lynx_tdesc'.
14040 * nto-low.c (nto_tdesc): New global.
14041 (do_attach): Set the new process'es tdesc.
14042 * nto-low.h (struct target_desc): Forward declare.
14043 (nto_tdesc): Declare.
14044 * nto-x86-low.c (tdesc_i386): Declare.
14045 (nto_x86_arch_setup): Set `nto_tdesc'.
14047 2013-06-04 Gary Benson <gbenson@redhat.com>
14049 * server.c (handle_query): Add "augmented-libraries-svr4-read+"
14050 to qSupported response when appropriate.
14051 (handle_qxfer_libraries_svr4): Allow qXfer:libraries-svr4:read
14052 with nonzero-length annex.
14053 * linux-low.c (linux_qxfer_libraries_svr4): Parse and handle
14054 arguments supplied in annex.
14056 2013-05-31 Doug Evans <dje@google.com>
14059 * linux-x86-low.c (ps_get_thread_area): Properly extend address to
14060 64 bits in 64-cross-32 environment.
14062 2013-05-28 Pedro Alves <palves@redhat.com>
14064 * Makefile.in (clean): Remove reference to aarch64-without-fpu.c.
14065 (aarch64-without-fpu.c): Delete rule.
14066 * configure.srv (aarch64*-*-linux*): Remove references to
14067 aarch64-without-fpu.o and aarch64-without-fpu.xml.
14068 * linux-aarch64-low.c (init_registers_aarch64_without_fpu): Remove
14071 2013-05-24 Pedro Alves <palves@redhat.com>
14073 * server.c (handle_v_cont) <vCont;r>: Use unpack_varlen_hex
14074 instead of strchr/decode_address. Error if the range isn't split
14075 with a ','. Don't assume there's be a ':' in the action.
14077 2013-05-23 Yao Qi <yao@codesourcery.com>
14078 Pedro Alves <palves@redhat.com>
14080 * linux-low.c (lwp_in_step_range): New function.
14081 (linux_wait_1): If the thread was range stepping and stopped
14082 outside the stepping range, report the stop to GDB. Otherwise,
14083 continue stepping. Add range stepping debug output.
14084 (linux_set_resume_request): Copy the step range from the resume
14085 request to the lwp.
14086 (linux_supports_range_stepping): New.
14087 (linux_target_ops) <supports_range_stepping>: Set to
14088 linux_supports_range_stepping.
14089 * linux-low.h (struct linux_target_ops)
14090 <supports_range_stepping>: New field.
14091 (struct lwp_info) <step_range_start, step_range_end>: New fields.
14092 * linux-x86-low.c (x86_supports_range_stepping): New.
14093 (the_low_target) <supports_range_stepping>: Set to
14094 x86_supports_range_stepping.
14095 * server.c (handle_v_cont): Handle 'r' action.
14096 (handle_v_requests): Append ";r" if the target supports range
14098 * target.h (struct thread_resume) <step_range_start,
14099 step_range_end>: New fields.
14100 (struct target_ops) <supports_range_stepping>:
14102 (target_supports_range_stepping): New macro.
14104 2013-05-17 Joel Brobecker <brobecker@adacore.com>
14106 * lynx-low.c (lynx_resume): Fix null_ptid/minus_one_ptid
14107 confusion in comment.
14109 2013-05-17 Joel Brobecker <brobecker@adacore.com>
14111 * lynx-low.c (struct process_info_private): New type.
14112 (lynx_add_process): New function.
14113 (lynx_create_inferior, lynx_attach): Replace calls to
14114 add_process by calls to lynx_add_process.
14115 (lynx_resume): If PTID is null, then try using
14116 current_process()->private->last_wait_event_ptid.
14118 (lynx_clear_inferiors): Delete. The contents of that function
14119 has been inlined in lynx_mourn;
14120 (lynx_wait_1): Save the ptid in the process's private data.
14121 (lynx_mourn): Free the process' private data. Replace call
14122 to lynx_clear_inferiors by call to clear_inferiors.
14124 2013-05-17 Yao Qi <yao@codesourcery.com>
14126 * i386-low.c (i386_length_and_rw_bits): Move the comment to
14129 2013-05-16 Luis Machado <lgustavo@codesourcery.com>
14131 * linux-low.c: Move definition checks upwards for PT_TEXT_ADDR,
14132 PT_DATA_ADDR and PT_TEXT_END_ADDR. Update comments.
14133 (linux_read_offsets): Remove PT_TEXT_ADDR, PT_DATA_ADDR and
14134 PT_TEXT_END_ADDR guards. Update comments.
14135 (linux_target_op) <read_offsets>: Conditionally define to
14136 linux_read_offsets if the target is UCLIBC and if it defines
14137 PT_TEXT_ADDR, PT_DATA_ADDR and PT_TEXT_END_ADDR.
14139 2013-05-06 Sandra Loosemore <sandra@codesourcery.com>
14140 Andrew Jenner <andrew@codesourcery.com>
14142 * Makefile.in (SFILES): Add linux-nios2-low.c.
14143 (clean): Add action to delete nios2-linux.c.
14144 (nios2-linux.c): New rule.
14145 * configure.srv: Add nios2*-*-linux*.
14146 * linux-nios2-low.c: New.
14148 2013-05-03 Hafiz Abid Qadeer <abidh@codesourcery.com>
14150 * tracepoint.c (cmd_qtinit): Call 'stop_tracing'.
14152 2013-04-25 Hui Zhu <hui@codesourcery.com>
14155 * ax.c (ax_printf): Add fflush.
14157 2013-04-22 Tom Tromey <tromey@redhat.com>
14159 * Makefile.in (SFILES): Add filestuff.c.
14160 (OBS): Add filestuff.o.
14161 (filestuff.o): New target.
14162 * config.in, configure: Rebuild.
14163 * configure.ac: Check for fdwalk, pipe2.
14165 2013-04-17 Pedro Alves <palves@redhat.com>
14167 * configure.ac (USE_THREAD_DB): Delete variable.
14168 (if test "$srv_linux_thread_db" = "yes"): AC_DEFINE USE_THREAD_DB.
14169 Don't AC_SUBST USE_THREAD_DB.
14170 * Makefile.in (INTERNAL_CFLAGS): Remove @USE_THREAD_DB@.
14171 * config.in, configure: Regenerate.
14173 2013-04-16 Pedro Alves <palves@redhat.com>
14175 * linux-low.h (struct lwp_info) <thread_known>: Move under
14176 the USE_THREAD_DB #ifdef.
14178 2013-04-16 Pedro Alves <palves@redhat.com>
14180 * Makefile.in (INTERNAL_CFLAGS): Add @USE_THREAD_DB@.
14181 (linux-low.o): Delete rule.
14182 * linux-low.h: Always include "gdb_thread_db.h" instead of
14183 conditionally including thread_db.h.
14184 (struct lwp_info) <th>: Guard with #ifdef USE_THREAD_DB instead of
14187 2013-04-07 Jan Kratochvil <jan.kratochvil@redhat.com>
14189 * Makefile.in (install-only): Fix make install regression.
14191 2013-04-05 Jan Kratochvil <jan.kratochvil@redhat.com>
14193 Convert man pages to texinfo, new gdbinit.5 texinfo page.
14194 * Makefile.in (install-only): Remove $(man1dir) and gdbserver.1
14196 * gdbserver.1: Remove.
14198 2013-03-22 Pedro Alves <palves@redhat.com>
14200 * linux-low.c (handle_extended_wait): Don't call
14201 linux_enable_event_reporting.
14203 2013-03-15 Tony Theodore <tonyt@logyst.com>
14206 * Makefile.in (SHELL): Use @SHELL@.
14208 2013-03-14 Sergio Durigan Junior <sergiodj@redhat.com>
14210 * tracepoint.c (cmd_qtv): Initialize `val' with zero, silencing
14213 2013-03-13 Joel Brobecker <brobecker@adacore.com>
14215 * linux-low.c (linux_target_ops) [!HAVE_LINUX_BTRACE]:
14216 Remove extraneous NULL element.
14218 2013-03-13 Yao Qi <yao@codesourcery.com>
14220 * tracepoint.c (traceframe_read_tsv): Look for the last matched
14221 'V' block in trace frame.
14223 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
14225 * target.h (struct target_ops): Add btrace ops.
14226 (target_supports_btrace): New macro.
14227 (target_enable_btrace): New macro.
14228 (target_disable_btrace): New macro.
14229 (target_read_btrace): New macro.
14230 * gdbthread.h (struct thread_info): Add btrace field.
14231 * server.c: Include btrace-common.h.
14232 (handle_btrace_general_set): New function.
14233 (handle_btrace_enable): New function.
14234 (handle_btrace_disable): New function.
14235 (handle_general_set): Call handle_btrace_general_set.
14236 (handle_qxfer_btrace): New function.
14237 (struct qxfer qxfer_packets[]): Add btrace entry.
14238 * inferiors.c (remove_thread): Disable btrace.
14239 * linux-low: Include linux-btrace.h.
14240 (linux_low_enable_btrace): New function.
14241 (linux_low_read_btrace): New function.
14242 (linux_target_ops): Add btrace ops.
14243 * configure.srv (i[34567]86-*-linux*): Add linux-btrace.o.
14244 Add srv_linux_btrace=yes.
14245 (x86_64-*-linux*): Add linux-btrace.o.
14246 Add srv_linux_btrace=yes.
14247 * configure.ac: Define HAVE_LINUX_BTRACE.
14248 * config.in: Regenerated.
14249 * configure: Regenerated.
14251 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
14253 * server.c (handle_qxfer): Preserve error message if -3 is
14255 (qxfer): Document the -3 return value.
14257 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
14259 * Makefile.in (SFILES): Add $(srcdir)/common/linux-btrace.c.
14260 (linux_btrace_h): New variable.
14261 (linux-btrace.o): New rule.
14263 2013-03-08 Stan Shebs <stan@codesourcery.com>
14264 Hafiz Abid Qadeer <abidh@codesourcery.com>
14266 * tracepoint.c (trace_buffer_size): New global.
14267 (DEFAULT_TRACE_BUFFER_SIZE): New define.
14268 (init_trace_buffer): Change to one-argument function. Allocate
14269 trace buffer memory.
14270 (handle_tracepoint_general_set): Call cmd_bigqtbuffer_size to
14271 handle QTBuffer:size packet.
14272 (cmd_bigqtbuffer_size): New function.
14273 (initialize_tracepoint): Call init_trace_buffer with
14274 DEFAULT_TRACE_BUFFER_SIZE.
14275 * server.c (handle_query): Add QTBuffer:size in the
14278 2013-03-07 Yao Qi <yao@codesourcery.com>
14280 * tracepoint.c (cur_action, cur_step_action): Make them unsigned.
14281 (cmd_qtfp): Initialize cur_action and cur_step_action 0 instead
14283 (cmd_qtsp): Adjust condition. Do post increment.
14284 Set cur_action and cur_step_action back to 0.
14286 2013-03-07 Jeremy Bennett <jeremy.bennett@embecosm.com>
14289 * linux-low.c (linux_write_memory): Return early success if LEN is
14292 2013-03-05 Corinna Vinschen <vinschen@redhat.de>
14294 * configure.srv: Add x86_64-*-cygwin* as target.
14296 2013-02-28 Tom Tromey <tromey@redhat.com>
14298 * configure.ac: Invoke AC_SYS_LARGEFILE.
14299 * configure, config.in: Rebuild.
14301 2013-02-28 Corinna Vinschen <vinschen@redhat.com>
14303 * win32-low.c: Throughout, fix format strings and casts of
14304 printf-like functions to avoid type related warnings on all
14306 (get_child_debug_event): Print dwDebugEventCode as hex since
14307 that's how it's usually documented.
14309 2013-02-28 Yao Qi <yao@codesourcery.com>
14311 * tracepoint.c (cmd_qtbuffer): Call phex_nz instead of
14314 2013-02-27 Jiong Wang <jiwang@tilera.com>
14316 * Makefile.in (clean): Remove reg-tilegx.c, reg-tilegx32.c.
14317 (reg-tilegx32.c): New rule.
14318 * configure.srv (tilegx-*-linux*): Add reg-tilegx32.o to srv_regobj.
14319 * linux-tile-low.c (tile_arch_setup): New function. Invoke
14320 different register info initializer according to elf class.
14321 (init_registers_tilgx32): New function. The tilegx32 register info
14323 (tile_fill_gregset): Use "uint_reg_t" to represent register size.
14324 (tile_store_gregset): Likewise.
14326 2013-02-27 Yao Qi <yao@codesourcery.com>
14328 * server.c (process_point_options): Print debug message when
14329 debug_threads is true.
14331 2013-02-26 Yao Qi <yao@codesourcery.com>
14333 * tracepoint.c (cmd_qtbuffer): Don't set '\0' in OWN_BUF.
14335 2013-02-19 Pedro Alves <palves@redhat.com>
14336 Kai Tietz <ktietz@redhat.com>
14340 * server.c (handle_query) <CRC check>: Use unpack_varlen_hex
14341 instead of strtoul to extract address from packet.
14342 (process_serial_event) <'z'>: Likewise.
14344 2013-02-18 Yao Qi <yao@codesourcery.com>
14346 * linux-bfin-low.c (the_low_target): Use NULL instead of 0.
14348 2013-02-14 Pedro Alves <palves@redhat.com>
14352 * tracepoint.c (cmd_qtnotes): Free TRACING_USER_NAME,
14353 TRACING_NOTES and TRACING_STOP_NOTE before clobbering.
14355 2013-02-14 Pedro Alves <palves@redhat.com>
14357 * tracepoint.c (cmd_qtdpsrc): Use savestring.
14359 2013-02-14 Pedro Alves <palves@redhat.com>
14361 * tracepoint.c (save_string): Delete.
14362 (add_tracepoint_action): Use savestring instead of save_string.
14364 2013-02-12 Pedro Alves <palves@redhat.com>
14366 * linux-xtensa-low.c: Ditto.
14367 * xtensa-xtregs.c: Ditto.
14369 2013-02-12 Sanimir Agovic <sanimir.agovic@intel.com>
14371 * thread-db.c (thread_db_get_tls_address): NULL pointer check
14374 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
14376 * linux-aarch64-low.c (aarch64_arch_setup): Clamp
14377 aarch64_num_wp_regs and aarch64_num_bp_regs to
14378 AARCH64_HWP_MAX_NUM and AARCH64_HBP_MAX_NUM respectively.
14380 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
14382 * linux-aarch64-low.c (ps_get_thread_area): Replace
14383 PTRACE_GET_THREAD_AREA with PTRACE_GETREGSET.
14385 2013-02-04 Jim MacArthur <jim.macarthur@arm.com>
14386 Marcus Shawcroft <marcus.shawcroft@arm.com>
14387 Nigel Stephens <nigel.stephens@arm.com>
14388 Yufeng Zhang <yufeng.zhang@arm.com>
14390 * Makefile.in (clean): Remove aarch64.c and aarch64-without-fpu.c.
14391 (aarch64.c, aarch64-without-fpu.c): New targets.
14392 * configure.srv (aarch64*-*-linux*): New.
14393 * linux-aarch64-low.c: New file.
14395 2013-02-04 Marcus Shawcroft <marcus.shawcroft@arm.com>
14397 * linux-low.c (handle_extended_wait, linux_create_inferior)
14398 (linux_attach_lwp_1, linux_kill_one_lwp, linux_attach_one_lwp)
14399 (dequeue_one_deferred_signal, linux_resume_one_thread)
14400 (fetch_register, linux_write_memory, linux_enable_event_reporting)
14401 (linux_tracefork_grandchild, linux_test_for_tracefork)
14402 (linux_read_offsets, linux_xfer_siginfo, linux_xfer_siginfo): Add
14403 PTRACE_ARG3_TYPE and PTRACE_ARG4_TYPE cast to ptrace arguments
14404 where the argument is 0.
14406 2013-01-25 Yao Qi <yao@codesourcery.com>
14408 * event-loop.c: Include "queue.h".
14409 (gdb_event_p): New typedef.
14410 (struct gdb_event) <next_event>: Remove.
14411 (event_queue): Change to QUEUE(gdb_event_p).
14412 (async_queue_event): Remove.
14413 (gdb_event_xfree): New.
14414 (initialize_event_loop): New.
14415 (process_event): Use API from QUEUE.
14416 (wait_for_event): Likewise.
14417 * server.c (main): Call initialize_event_loop.
14418 * server.h (initialize_event_loop): Declare.
14420 2013-01-18 Yao Qi <yao@codesourcery.com>
14422 * ax.h (struct eval_agent_expr_context): New.
14423 (gdb_eval_agent_expr): Update declaration.
14424 * ax.c (gdb_eval_agent_expr): Remove argument REGCACHE and
14425 TFRAME. Add new argument CTX.
14426 * server.h (struct eval_agent_expr_context): Declare.
14427 (agent_mem_read, agent_tsv_read): Update declaration.
14428 (agent_mem_read_string): Likewise.
14429 * tracepoint.c (eval_tracepoint_agent_expr): Remove.
14430 (add_traceframe_block): Add new argument TPOINT.
14431 Increase TPOINT->traceframe_usage.
14432 (do_action_at_tracepoint): Call gdb_eval_agent_expr instead of
14433 eval_tracepoint_agent_expr.
14434 (condition_true_at_tracepoint): Likewise.
14435 (agent_mem_read): Remove argument TFRAME. Add argument CTX.
14436 (agent_mem_read_string, agent_tsv_read): Likewise.
14438 2013-01-16 Yao Qi <yao@codesourcery.com>
14440 * linux-low.c (linux_resume_one_lwp): Don't check
14441 'lwp->bp_reinsert != 0'.
14443 2013-01-07 Joel Brobecker <brobecker@adacore.com>
14444 Pedro Alves <palves@redhat.com>
14446 * lynx-low.c (ptrace_request_to_str): Define a temporary
14447 macro and use it to simplify this function's implementation.
14449 2013-01-07 Joel Brobecker <brobecker@adacore.com>
14451 * lynx-low.c (lynx_resume): Call perror_with_name if lynx_ptrace
14454 2013-01-07 Joel Brobecker <brobecker@adacore.com>
14456 * configure.srv (i[34567]86-*-lynxos*): Set srv_xmlfiles.
14458 2013-01-07 Joel Brobecker <brobecker@adacore.com>
14460 * configure.srv (powerpc-*-lynxos*): Set srv_xmlfiles.
14462 2013-01-07 Joel Brobecker <brobecker@adacore.com>
14464 * lynx-low.c (lynx_resume): Use the resume_info parameter
14465 to determine the ptid for the lynx_ptrace call, unless
14466 it is equal to minus_one_ptid, in which case we use the
14467 ptid of the current_inferior.
14468 (lynx_wait_1): After having received a thread create/exit
14469 event, resume the inferior's execution using the signaling
14470 thread's ptid, rather than the old ptid.
14472 2013-01-07 Joel Brobecker <brobecker@adacore.com>
14474 * lynx-low.c (lynx_resume): Delete variable ret.
14476 2013-01-01 Joel Brobecker <brobecker@adacore.com>
14478 * gdbreplay.c (gdbreplay_version): Update copyright year.
14479 * server.c (gdbserver_version): Likewise.
14481 2012-12-17 Joel Brobecker <brobecker@adacore.com>
14483 * lynx-low.c (lynx_wait_1): Add debug trace before adding
14486 2012-12-17 Joel Brobecker <brobecker@adacore.com>
14488 * lynx-low.c (ptrace_request_to_str): Add handling for
14489 PTRACE_GETTRACESIG.
14491 2012-12-17 Joel Brobecker <brobecker@adacore.com>
14493 * lynx-low.c (lynx_attach): Delete variable new_process.
14495 2012-12-17 Joel Brobecker <brobecker@adacore.com>
14497 * lynx-low.c (lynx_create_inferior): Delete variable
14500 2012-12-17 Joel Brobecker <brobecker@adacore.com>
14502 * lynx-low.c (ptrace_request_to_str): Do not handle
14503 PTRACE_GETTHREADLIST if this macro does not exist.
14505 2012-12-15 Yao Qi <yao@codesourcery.com>
14507 * Makefile.in (OBS): Add notif.o.
14508 * notif.c, notif.h: New.
14509 * server.c: Include "notif.h".
14510 (struct vstop_notif) <next>: Remove.
14512 (queue_stop_reply): Update.
14513 (push_event, send_next_stop_reply): Remove.
14514 (discard_queued_stop_replies): Update.
14515 (notif_stop): New variable.
14516 (handle_v_stopped): Remove.
14517 (handle_v_requests): Don't call handle_v_stopped. Call
14518 handle_ack_notif instead.
14519 (queue_stop_reply_callback): Call notif_event_enque instead
14520 of queue_stop_reply.
14521 (handle_status): Don't call send_next_stop_reply, call
14522 notif_write_event instead.
14523 (kill_inferior_callback): Likewise.
14524 (detach_or_kill_inferior_callback): Likewise.
14525 (main): Call initialize_notif.
14526 (process_serial_event): Call QUEUE_is_empty.
14527 (handle_target_event): Call notif_push instead of push event.
14528 * server.h (push_event): Remove declaration.
14530 2012-12-10 Tom Tromey <tromey@redhat.com>
14532 * Makefile.in (DEPMODE, DEPDIR, depcomp, COMPILE.pre)
14533 (COMPILE.post, COMPILE, POSTCOMPILE, IPAGENT_COMPILE): New
14536 (ax-ipa.o, tracepoint-ipa.o, utils-ipa.o, format-ipa.o)
14537 (common-utils-ipa.o, remote-utils-ipa.o, regcache-ipa.o)
14538 (i386-linux-ipa.o, linux-i386-ipa.o, linux-amd64-ipa.o)
14539 (amd64-linux-ipa.o, ax.o): Rewrite.
14540 (event-loop.o, hostio.o, hostio-errno.o, inferiors.o, mem-break.o)
14541 (proc-service.o, regcache.o, remote-utils.o, server.o, target.o)
14542 (thread-db.o, tracepoint.o, utils.o, gdbreplay.o, dll.o): Remove.
14543 (signals.o, linux-procfs.o, linux-ptrace.o, common-utils.o, vec.o)
14544 (gdb_vecs.o, xml-utils.o, linux-osdata.o, ptid.o, buffer.o)
14545 (format.o, agent.o, vasprintf.o, vsnprintf.o): Rewrite.
14546 (i386-low.o, i387-fp.o, linux-low.o, linux-arm-low.o)
14547 (linux-bfin-low.o, linux-cris-low.o, linux-crisv32-low.o)
14548 (linux-ia64-low.o, linux-m32r-low.o, linux-mips-low.o)
14549 (linux-ppc-low.o, linux-s390-low.o, linux-sh-low.o)
14550 (linux-tic6x-low.o, linux-x86-low.o, linux-xtensa-low.o)
14551 (linux-tile-low.o, lynx-low.o, lynx-ppc-low.o, nto-low.o)
14552 (nto-x86-low.o, linux-low.o, win32-low.o, win32-arm-low.o)
14553 (win32-i386-low.o, spu-low.o, reg-arm.o, arm-with-iwmmxt.o)
14554 (arm-with-vfpv2.o, arm-with-vfpv3.o, arm-with-neon.o, reg-bfin.o)
14555 (reg-cris.o, reg-crisv32.o, i386.o, i386-linux.o, i386-avx.o)
14556 (i386-avx-linux.o, i386-mmx.o, i386-mmx-linux.o, reg-ia64.o)
14557 (reg-m32r.o, reg-m68k.o, reg-cf.o, mips-linux.o, mips-dsp-linux.o)
14558 (mips64-linux.o, mips64-dsp-linux.o, powerpc-32.o, powerpc-32l.o)
14559 (powerpc-altivec32l.o, powerpc-cell32l.o, powerpc-vsx32l.o)
14560 (powerpc-isa205-32l.o, powerpc-isa205-altivec32l.o)
14561 (powerpc-isa205-vsx32l.o, powerpc-e500l.o, powerpc-64l.o)
14562 (powerpc-altivec64l.o, powerpc-cell64l.o, powerpc-vsx64l.o)
14563 (powerpc-isa205-64l.o, powerpc-isa205-altivec64l.o)
14564 (powerpc-isa205-vsx64l.o, s390-linux32.o, s390-linux32v1.o)
14565 (s390-linux32v2.o, s390-linux64.o, s390-linux64v1.o)
14566 (s390-linux64v2.o, s390x-linux64.o, s390x-linux64v1.o)
14567 (s390x-linux64v2.o, tic6x-c64xp-linux.o, tic6x-c64x-linux.o)
14568 (tic6x-c62x-linux.o, reg-sh.o, reg-sparc64.o, reg-spu.o, amd64.o)
14569 (amd64-linux.o, amd64-avx.o, amd64-avx-linux.o, x32.o)
14570 (x32-linux.o, x32-avx.o, x32-avx-linux.o, reg-xtensa.o)
14571 (reg-tilegx.o): Remove.
14572 (all_object_files): New macro.
14573 Include .deps files.
14574 * aclocal.m4, configure: Rebuild.
14575 * acinclude.m4: Include depstand.m4, lead-dot.m4.
14576 * configure.ac: Invoke ZW_CREATE_DEPDIR,
14577 ZW_PROG_COMPILER_DEPENDENCIES. Compute GMAKE condition.
14579 2012-12-05 Tom Tromey <tromey@redhat.com>
14582 * server.h (current_insn_ptr, emit_error): Declare 'extern'.
14584 2012-11-28 Markus Metzger <markus.t.metzger@intel.com>
14586 * configure.ac: Check for linux/perf_event.h.
14587 * config.in: Regenerated.
14588 * configure: Regenerated.
14590 2012-11-26 Maxime Villard <rustyBSD@gmx.fr>
14592 * hostio.c (handle_readlink): Decrease buffer size
14593 parameter passed to readlink by one byte.
14595 2012-11-26 Yao Qi <yao@codesourcery.com>
14597 * configure.ac (build_warnings): Append '-Wempty-body'.
14598 * configure: Regenerated.
14599 * linux-low.c (linux_create_inferior): Use braces for empty 'if'
14602 2012-11-15 Pierre Muller <muller@sourceware.org>
14604 * configure.ac (AC_CHECK_HEADERS): Add wait.h header.
14605 * config.in: Regenerate.
14606 * configure: Regenerate.
14607 * linux-low.c: Use "gdb_stat.h" header instead of <sys/stat.h> header.
14608 Use "gdb_wait.h" header instead of <sys/wait.h> header.
14609 * lynx-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
14610 * remote-utils.c: Use "gdb_stat.h" header instead of <sys/stat.h>
14612 * server.c: Remove HAVE_WAIT_H conditional. Use "gdb_wait.h" header
14613 instead of <sys/wait.h> header.
14614 * spu-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
14616 2012-11-13 Markus Metzger <markus.t.metzger@intel.com>
14618 * Makefile.in: (INTERNAL_CFLAGS): Add -DGDBSERVER
14619 (various make rules): Remove -DGDBSERVER
14621 2012-11-09 Yao Qi <yao@codesourcery.com>
14623 * spu-low.c (current_ptid): Move it to ..
14624 * gdbthread.h: ... here. New.
14625 * remote-utils.c (read_ptid): Use macro 'current_ptid'.
14626 * server.c (myresume, process_serial_event): Likewise.
14627 * thread-db.c (thread_db_find_new_threads): Likewise.
14628 * tracepoint.c (run_inferior_command): Likewise.
14630 2012-10-01 Andrew Burgess <aburgess@broadcom.com>
14632 * server.c (handle_search_memory_1): Include access length in
14635 2012-09-05 Michael Brandt <michael.brandt@axis.com>
14637 * linux-crisv32-low.c: Fix compile errors.
14639 2012-09-04 Yao Qi <yao@codesourcery.com>
14641 * tracepoint.c (cmd_qtsv): Adjust debug message.
14642 Don't check CUR_TPOINT.
14644 2012-08-28 Yao Qi <yao@codesourcery.com>
14646 * ax.c, tracepoint.c: Replace ATTR_FORMAT with ATTRIBUTE_PRINTF.
14647 * server.h: Include 'libiberty.h' and 'ansidecl.h'.
14648 (ATTR_NORETURN, ATTR_FORMAT, ATTR_MALLOC): Remove.
14649 Remove declarations of xmalloc, xreallloc, xstrdup and
14651 * Makefile.in (libiberty_h): New.
14652 (server_h): Append dependencies 'libiberty.h' and 'ansidecl.h'.
14653 (linux-bfin-low.o): Append dependency 'libiberty.h'.
14655 2012-08-23 Yao Qi <yao@codesourcery.com>
14657 * server.h: Remove declaration of 'xsnprintf'.
14659 2012-08-22 Keith Seitz <keiths@redhat.com>
14661 * server.h: Include build-gnulib-gbserver/config.h.
14662 * gdbreplay.c: Likewise.
14664 2012-08-08 Doug Evans <dje@google.com>
14666 * Makefile.in (SFILES): Add gdb_vecs.c.
14667 (OBS): Add gdb_vecs.o.
14668 (gdb_vecs_h, host_defs_h): New variables.
14669 (thread-db.o): Add $(gdb_vecs_h) dependency.
14670 (gdb_vecs.o): New rule.
14671 * thread-db.c: #include "gdb_vecs.h".
14672 (thread_db_load_search): Use a vector to iterate over path elements.
14673 Handle text appearing after "$pdir".
14675 * configure.ac: Add check for strstr.
14676 * config.in: Regenerate.
14677 * configure: Regenerate.
14679 2012-08-02 Ulrich Weigand <ulrich.weigand@linaro.org>
14681 * hostio.c (handle_pread): If pread fails, fall back to attempting
14683 (handle_pwrite): Likewise for pwrite.
14685 2012-08-01 Ulrich Weigand <ulrich.weigand@linaro.org>
14687 * linux-arm-low.c (arm_linux_hw_point_initialize): Distinguish
14688 between unsupported TYPE and unimplementable ADDR/LEN combination.
14689 (arm_insert_point): Act on new return value.
14691 2012-07-31 Pedro Alves <palves@redhat.com>
14693 * server.c (process_point_options): Only skip tokens if we find
14694 one that is unrecognized. Don't treat 'X' specially while
14695 skipping unrecognized tokens.
14697 2012-07-30 Ulrich Weigand <ulrich.weigand@linaro.org>
14699 * linux-arm-low.c (arm_linux_hw_point_initialize): Do not attempt
14700 to 4-byte-align HW breakpoint addresses for Thumb.
14702 2012-07-27 Yao Qi <yao@codesourcery.com>
14706 * server.h: Declare gdb_agent_about_to_close.
14707 * target.c (kill_inferior): Include "agent.h".
14708 New. Send command 'kill'.
14709 * target.h (kill_inferior): Removed macro.
14710 * tracepoint.c (gdb_agent_about_to_close): New.
14711 (gdb_agent_helper_thread): Handle command 'close'.
14712 Wait endlessly until the inferior stops.
14713 Install gdb_agent_remove_socket to atexit hook.
14714 (agent_socket_name): New static variable.
14715 (gdb_agent_socket_init): Replace local variable 'name' with
14716 'agent_socket_name'.
14717 (gdb_agent_remove_socket): New.
14719 2012-07-27 Yao Qi <yao@codesourcery.com>
14721 * server.c (process_point_options): Stop at 'X' when parsing.
14723 2012-07-19 Michael Eager <eager@eagercon.com>
14725 * i386-low.c (Z_packet_to_hw_type): Add Z_PACKET_HW_BP, translate
14727 * linux-x86-low.c (x86_insert_point, x86_remove_point):
14728 Call i386_low_insert_watchpoint, i386_low_remove_watchpoint to add/del
14729 hardware breakpoint.
14731 2012-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
14733 * gdbserver/linux-low.c (initialize_low): Call
14734 linux_ptrace_init_warnings.
14736 2012-07-02 Doug Evans <dje@google.com>
14738 * mem-break.c (gdb_no_commands_at_breakpoint): Fix cast from
14741 2012-07-02 Stan Shebs <stan@codesourcery.com>
14743 * Makefile.in (WARN_CFLAGS_NO_FORMAT): Define.
14744 (ax.o): Add it to build rule.
14746 (OBS): Add format.o.
14747 (IPA_OBS): Add format.o.
14748 * server.c (handle_query): Claim support for breakpoint commands.
14749 (process_point_options): Add command case.
14750 (process_serial_event): Leave running if there are printfs in
14752 * mem-break.h (any_persistent_commands): Declare.
14753 (add_breakpoint_commands): Declare.
14754 (gdb_no_commands_at_breakpoint): Declare.
14755 (run_breakpoint_commands): Declare.
14756 * mem-break.c (struct point_command_list): New struct.
14757 (struct breakpoint): New field command_list.
14758 (any_persistent_commands): New function.
14759 (add_commands_to_breakpoint): New function.
14760 (add_breakpoint_commands): New function.
14761 (gdb_no_commands_at_breakpoint): New function.
14762 (run_breakpoint_commands): New function.
14763 * linux-low.c (linux_wait_1): Test for and run breakpoint commands
14765 * ax.c: Include format.h.
14766 (ax_printf): New function.
14767 (gdb_eval_agent_expr): Add printf opcode.
14769 2012-06-13 Yao Qi <yao@codesourcery.com>
14771 * server.c (start_inferior): Remove duplicated writes to fields
14772 'last_resume_kind' and 'last_status' of 'current_inferior'.
14774 2012-06-12 Yao Qi <yao@codesourcery.com>
14775 Pedro Alves <palves@redhat.com>
14777 * linux-low.c (linux_set_resume_request): Simplify predicate. Add
14779 * server.c (handle_v_cont): Extend comment.
14781 2012-06-11 Yao Qi <yao@codesourcery.com>
14783 * linux-low.c (linux_attach): Add 'static'.
14785 2012-06-06 Yao Qi <yao@codesourcery.com>
14787 * ax.c (gdb_eval_agent_expr): Print `top' in hex.
14789 2012-06-01 Jan Kratochvil <jan.kratochvil@redhat.com>
14791 Fix gcc -flto compilation warning.
14792 * server.c (main): Make variable multi_mode and attach volatile.
14794 2012-05-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
14796 * linux-low.c (get_r_debug): Disable code using DT_MIPS_RLD_MAP
14797 if the platform doesn't know about it.
14799 2012-05-30 Jeff Kenton <jkenton@tilera.com>
14801 * Makefile.in (SFILES): Add linux-tile-low.c.
14802 (linux-tile-low.o, reg-tilegx.o, reg-tilegx.c): New rules.
14803 * configure.srv: Handle tilegx-*-linux*.
14804 * linux-tile-low.c: New file.
14806 2012-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
14808 * linux-low.c (linux_qxfer_libraries_svr4): Return -1 if R_DEBUG is -1.
14810 2012-05-24 Pedro Alves <palves@redhat.com>
14814 Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.
14816 2012-05-24 Pedro Alves <palves@redhat.com>
14820 Replace target_signal with gdb_signal throughout.
14822 2012-05-22 Maciej W. Rozycki <macro@codesourcery.com>
14824 * linux-low.c (linux_store_registers): Avoid the copying sequence
14825 when no data has been retrieved by ptrace.
14827 2012-05-22 Will Deacon <will.deacon@arm.com>
14829 * linux-low (__UCLIBC__ && !(__UCLIBC_HAS_MMU__ || __ARCH_HAS_MMU__)):
14830 Include asm/ptrace.h.
14831 (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define only if not
14834 2012-05-21 Maciej W. Rozycki <macro@codesourcery.com>
14836 * linux-low.c (linux_store_registers): Don't re-retrieve data
14837 with ptrace that has already been obtained from /proc. Always
14838 copy any data retrieved with ptrace to the buffer supplied.
14840 2012-05-11 Yao Qi <yao@codesourcery.com>
14841 Pedro Alves <palves@redhat.com>
14843 * linux-low.c (enum stopping_threads_kind): New.
14844 (stopping_threads): Change type to `enum stopping_threads_kind'.
14845 (handle_extended_wait): If stopping and suspending threads, leave
14846 the new_lwp suspended too.
14847 (linux_wait_for_event): Adjust.
14848 (stop_all_lwps): Set `stopping_threads' to
14849 STOPPING_AND_SUSPENDING_THREADS or STOPPING_THREADS depending on
14850 whether we're suspending threads or just stopping them. Assert no
14853 2012-04-29 Yao Qi <yao@codesourcery.com>
14855 * server.h: Move some code to ...
14856 * gdbthread.h: ... here. New.
14857 * Makefile.in (inferiors.o, regcache.o): Depends on gdbthread.h
14858 (remote-utils.o, server.o, target.o tracepoint.o): Likewise.
14859 (nto-low.o, win32-low.o): Likewise.
14860 * inferiors.c, linux-low.h, nto-low.c: Include gdbthread.h.
14861 * regcache.c, remote-utils.c, server.c: Likewise.
14862 * target.c, tracepoint.c, win32-low.c: Likewise.
14864 2012-04-24 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
14866 * linux-low.h (PTRACE_ARG3_TYPE): Move macro from linux-low.c.
14867 (PTRACE_ARG4_TYPE): Likewise.
14868 (PTRACE_XFER_TYPE): Likewise.
14869 * linux-arm-low.c (arm_prepare_to_resume): Cast third argument of
14870 ptrace to PTRACE_ARG3_TYPE.
14871 * linux-low.c (PTRACE_ARG3_TYPE): Move macro to linux-low.h.
14872 (PTRACE_ARG4_TYPE): Likewise.
14873 (PTRACE_XFER_TYPE): Likewise.
14874 (linux_detach_one_lwp): Cast fourth argument of
14875 ptrace to long then PTRACE_ARG4_TYPE.
14876 (regsets_fetch_inferior_registers): Cast third argument of
14877 ptrace to long then PTRACE_ARG3_TYPE.
14878 (regsets_store_inferior_registers): Likewise.
14880 2012-04-20 Pedro Alves <palves@redhat.com>
14882 * configure: Regenerate.
14884 2012-04-19 Pedro Alves <palves@redhat.com>
14886 * Makefile.in (GNULIB_BUILDDIR): New.
14887 (LIBGNU, INCGNU, GNULIB_H): Adjust.
14888 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): New.
14889 (all, install-only, uninstall, clean-info, all-lib, clean): No
14890 longer pass GNULIB_FLAGS_TO_PASS. Use subdir_do.
14891 (maintainer-clean realclean distclean): Use subdir_do.
14893 (gnulib/import/Makefile): Adjust. Replace gnulib/import with
14894 $(GNULIB_BUILDDIR). Don't pass argument to config.status.
14895 * acinclude.m4: Include acx_configure_dir.m4.
14896 * configure.ac: Remove gl_EARLY, gl_INIT, and AM_INIT_AUTOMAKE
14897 calls. Call AC_PROG_RANLIB. Configure gnulib using
14900 (GNULIB_STDINT_H): Adjust.
14901 (AC_OUTPUT): Don't output gnulib/Makefile anymore.
14902 * gdbreplay.c: Include build-gnulib/config.h.
14903 * server.h: Likewise.
14904 * aclocal.m4: Regenerate.
14905 * config.in: Regenerate.
14906 * configure: Regenerate.
14908 2012-04-19 Pedro Alves <palves@redhat.com>
14910 * Makefile.in (LIBGNU, INCGNU): Adjust.
14911 (GNULIB_FLAGS_TO_PASS, GNULIB_H): Adjust.
14912 (all, install-only, uninstall, clean-info, all-lib, clean)
14913 (maintainer-clean, Makefile, gnulib/Makefile): Adjust.
14914 * configure.ac: Adjust AC_OUTPUT output.
14915 * aclocal.m4: Regenerate.
14916 * configure: Regenerate.
14918 2012-04-19 Pedro Alves <palves@redhat.com>
14920 * Makefile.in (generated_files): New.
14921 (server_h): Remove the explicit dependency on config.h, and depend
14922 on $generated_files.
14924 2012-04-19 Pedro Alves <palves@redhat.com>
14926 * Makefile.in (INCGNU): Add -Ignulib.
14928 2012-04-19 Pedro Alves <palves@redhat.com>
14930 * Makefile.in (GNULIB_INCLUDE_DIR): Rename to ...
14931 (INCGNU): ... this, and spell out -I here.
14932 (GNULIB_LIB): Rename to ...
14933 (LIBGNU): ... this.
14934 (INCLUDE_CFLAGS, gdbserver$(EXEEXT), $(GNULIB_LIB) rule): Adjust.
14936 2012-04-19 Pedro Alves <palves@redhat.com>
14938 * config.in: Regenerate.
14940 2012-04-19 Pedro Alves <palves@redhat.com>
14942 * configure.ac: Remove AC_CHECK_DECLS check for memmem.
14943 * server.h (memmem): Remove declaration.
14944 * config.in: Regenerate.
14945 * configure: Regenerate.
14947 2012-04-19 Yao Qi <yao@codesourcery.com>
14949 * Makefile.in (SFILES): Add common/vec.c.
14953 2012-04-19 Yao Qi <yao@codesourcery.com>
14955 * remote-utils.c (prepare_resume_reply): Replace with macro
14956 target_core_of_thread.
14957 * server.c (handle_qxfer_threads_proper): Likewise.
14958 * target.h (traget_core_of_thread): New macro.
14960 2012-04-18 Pedro Alves <palves@redhat.com>
14962 * aclocal.m4: Regenerate.
14963 * configure: Regenerate.
14965 2012-04-16 Yao Qi <yao@codesourcery.com>
14967 * tracepoint.c (cmd_qtstart): Download tracepoints even when they are
14968 duplicated on address.
14970 2012-04-16 Yao Qi <yao@codesourcery.com>
14972 * tracepoint.c (COPY_FIELD_TO_BUF): New macro.
14973 (struct tracepoint_action_ops) <send>: New field.
14974 (m_tracepoint_action_send, r_tracepoint_action_send): New.
14975 (agent_expr_send, x_tracepoint_action_send): New.
14976 (l_tracepoint_action_send): New.
14977 (cmd_qtdp): Download and install tracepoint
14978 according to `use_agent'.
14979 (run_inferior_command): Add one more parameter `len'.
14981 (tracepoint_send_agent): New.
14982 (cmd_qtdp, cmd_qtstart): Call tracepoint_send_agent.
14984 2012-04-16 Yao Qi <yao@codesourcery.com>
14986 * tracepoint.c (download_tracepoints): Moved to ...
14987 (cmd_qtstart): ... here.
14989 2012-04-14 Yao Qi <yao@codesourcery.com>
14991 * tracepoint.c: Include inttypes.h.
14992 (struct collect_memory_action): Use sized types.
14993 (struct tracepoint): Likewise.
14994 (cmd_qtdp, stop_tracing): Update print specifiers.
14995 (cmd_qtp, response_tracepoint): Likewise.
14996 (collect_data_at_tracepoint): Likewise.
14997 (collect_data_at_step): Likewise.
14999 2012-04-14 Yao Qi <yao@codesourcery.com>
15001 Import gnulib module inttypes.
15002 * aclocal.m4, config.in, configure: Regenerated.
15004 2012-04-14 Yao Qi <yao@codesourcery.com>
15006 * Makefile.in (maintainer-clean, realclean, distclean): Remove
15007 Makefile and config.status at last.
15009 2012-04-13 Yao Qi <yao@codesourcery.com>
15011 * tracepoint.c: Include stdint.h unconditionally.
15013 2012-04-13 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
15015 * acinclude.m4 (GDBSERVER_HAVE_THREAD_DB_TYPE): New macro based
15016 on BFD_HAVE_SYS_PROCFS_TYPE.
15017 * configure.ac: Look for lwpid_t and psaddr_t in libthread_db.h.
15018 * configure: Regenerate.
15019 * config.in: Likewise.
15021 2012-04-13 H.J. Lu <hongjiu.lu@intel.com>
15023 * Makefile.in (clean): Also remove x32.c x32-linux.c
15024 x32-avx.c x32-avx-linux.c.
15025 (x32.o): New target.
15027 (x32-linux.o): Likewise.
15028 (x32-linux.c): Likewise.
15029 (x32-avx.o): Likewise.
15030 (x32-avx.c): Likewise.
15031 (x32-avx-linux.o): Likewise.
15032 (x32-avx-linux.c): Likewise.
15034 * configure.srv (srv_amd64_regobj): Add x32.o x32-avx.o.
15035 (srv_amd64_linux_regobj): Add x32-linux.o x32-avx-linux.o.
15036 (srv_i386_64bit_xmlfiles): Add i386/x32-core.xml.
15037 (srv_amd64_xmlfiles): Add i386/x32.xml i386/x32-avx.xml.
15038 (srv_amd64_linux_xmlfiles): Add i386/x32-linux.xml
15039 i386/x32-avx-linux.xml.
15041 * linux-x86-low.c (init_registers_x32_linux): New prototype.
15042 (init_registers_x32_avx_linux): Likwise.
15043 (x86_linux_update_xmltarget): Call init_registers_x32_linux
15044 or init_registers_x32_avx_linux if linux_is_elf64 is false.
15046 2012-04-13 Pedro Alves <palves@redhat.com>
15048 * Makefile.in (GNULIB_FLAGS_TO_PASS): New.
15049 (FLAGS_TO_PASS): Don't change or set $top_srcdir, $srcdir and VPATH.
15050 (all, uninstall, clean-info, all-lib, clean, maintainer-clean)
15051 (realclean, distclean): Explicitly pass $GNULIB_FLAGS_TO_PASS to
15054 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
15056 * linux-x86-low.c (compat_x32_clock_t): New.
15057 (compat_x32_siginfo_t): Likewise.
15058 (compat_x32_siginfo_from_siginfo): Likewise.
15059 (siginfo_from_compat_x32_siginfo): Likewise.
15060 (linux_is_elf64): Likewise.
15061 (x86_siginfo_fixup): Call compat_x32_siginfo_from_siginfo
15062 and siginfo_from_compat_x32_siginfo for x32.
15063 (x86_arch_setup): Set linux_is_elf64.
15065 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
15068 * linux-low.c (linux_pid_exe_is_elf_64_file): Also return the
15070 (linux_qxfer_libraries_svr4): Update call to elf_64_file_p.
15071 * linux-low.h (linux_pid_exe_is_elf_64_file): Updated.
15072 * linux-x86-low.c (x86_arch_setup): Check if GDBserver is
15073 compatible with process.
15075 2012-04-12 Yao Qi <yao@codesourcery.com>
15077 * Makefile.in: Define abs_top_srcdir and abs_srcdir.
15078 (INCLUDE_CFLAGS): Append GNULIB_INCLUDE_DIR.
15079 (install-only, install-info, clean): Handle sub dir gnulib.
15080 (all-lib, am--refresh): New targets.
15081 (memmem.o): Remove target.
15082 * configure.ac: Remove AC_CONFIG_LIBOBJ_DIR.
15083 Invoke gl_EARLY. Invoke AC_CHECK_PROGS for make.
15084 (AC_REPLACE_FUNCS): Remove memmem.
15085 Invoke gl_INIT and AM_INIT_AUTOMAKE.
15086 (AC_OUTPUT): Generate Makefile in gnulib/.
15087 * aclocal.m4, config.in, configure: Regenerated.
15089 2012-04-10 Maciej W. Rozycki <macro@codesourcery.com>
15091 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP.
15093 2012-04-05 Pedro Alves <palves@redhat.com>
15095 -Werror=strict-aliasing
15097 * spu-low.c (parse_spufs_run): Avoid dereferencing type-punned
15100 2012-04-04 Pedro Alves <palves@redhat.com>
15102 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
15103 (sparc_store_gregset_from_stack, sparc_store_gregset)
15104 (sparc_breakpoint_at): Fix formatting.
15106 2012-03-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
15108 * configure.ac: Check whether Elf32_auxv_t and Elf64_auxv_t
15110 * linux-low.c [HAVE_ELF32_AUXV_T] (Elf32_auxv_t): Add typedef.
15111 [HAVE_ELF64_AUXV_T] (Elf64_auxv_t): Likewise.
15112 * config.in: Regenerate.
15113 * configure: Likewise.
15115 2012-03-29 Pedro Alves <palves@redhat.com>
15117 * linux-low.c (regsets_store_inferior_registers) [__sparc__]:
15118 Correct ptrace arguments.
15120 2012-03-28 Pedro Alves <palves@redhat.com>
15122 * linux-ia64-low.c (ia64_regmap): Map IA64_EC_REGNUM to PT_AR_EC.
15123 (IA64_GR0_REGNUM, IA64_FR0_REGNUM)
15124 (IA64_FR1_REGNUM): New defines.
15125 (ia64_fetch_register): New.
15126 (the_low_target): Install it.
15127 * linux-low.h (struct linux_target_ops) <fetch_register>: New
15129 * linux-low.c (linux_fetch_registers): Try the
15130 the_low_target.fetch_register hook first.
15132 * linux-arm-low.c (the_low_target): Adjust.
15133 * linux-bfin-low.c (the_low_target): Adjust.
15134 * linux-cris-low.c (the_low_target): Adjust.
15135 * linux-crisv32-low.c (the_low_target): Adjust.
15136 * linux-m32r-low.c (the_low_target): Adjust.
15137 * linux-m68k-low.c (the_low_target): Adjust.
15138 * linux-mips-low.c (the_low_target): Adjust.
15139 * linux-ppc-low.c (the_low_target): Adjust.
15140 * linux-s390-low.c (the_low_target): Adjust.
15141 * linux-sh-low.c (the_low_target): Adjust.
15142 * linux-sparc-low.c (the_low_target): Adjust.
15143 * linux-tic6x-low.c (the_low_target): Adjust.
15144 * linux-x86-low.c (the_low_target): Adjust.
15145 * linux-xtensa-low.c (the_low_target): Adjust.
15147 2012-03-26 Pedro Alves <palves@redhat.com>
15149 * server.c (handle_qxfer_libraries): Don't bail early if
15150 the_target->qxfer_libraries_svr4 is not NULL.
15152 2012-03-26 Pedro Alves <palves@redhat.com>
15154 * linux-low.c (linux_qxfer_libraries_svr4): Fix pasto in comment.
15156 2012-03-23 Pedro Alves <palves@redhat.com>
15158 * linux-low.c (linux_qxfer_libraries_svr4): Terminate the
15159 "library-list-svr4" element's start tag when the the DSO list is
15162 2012-03-23 Pedro Alves <palves@redhat.com>
15164 * linux-low.c (read_one_ptr): Read the inferior's pointer through
15165 a variable whose type size is the same as the inferior's pointer
15168 2012-03-21 Thomas Schwinge <thomas@codesourcery.com>
15170 * linux-arm-low.c (arm_stopped_by_watchpoint): Use siginfo_t instead of
15172 * linux-low.c (siginfo_fixup, linux_xfer_siginfo): Likewise.
15173 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
15174 * linux-low.h: Include <signal.h>.
15175 (struct siginfo): Remove forward declaration.
15176 (struct linux_target_ops) <siginfo_fixup>: Use siginfo_t instead of
15179 2012-03-21 Mike Frysinger <vapier@gentoo.org>
15181 * .gitignore: Ignore more files.
15183 2012-03-19 Pedro Alves <palves@redhat.com>
15184 Jan Kratochvil <jan.kratochvil@redhat.com>
15186 * server.c (cont_thread, general_thread): Add describing comments.
15187 (start_inferior): Clear `cont_thread'.
15188 (handle_v_cont): Don't set `cont_thread' if resuming all threads
15191 2012-03-15 Yao Qi <yao@codesourcery.com>
15193 * tracepoint.c (install_tracepoint): Move duplicated tracepoint
15195 (cmd_qtdp): ... here.
15197 2012-03-15 Yao Qi <yao@codesourcery.com>
15199 * tracepoint.c (struct tracepoint_action_ops): New.
15200 (struct tracepoint_action) [!IN_PROCESS_AGENT] <ops>: New field.
15201 (m_tracepoint_action_download): New.
15202 (r_tracepoint_action_download): New.
15203 (x_tracepoint_action_download): New.
15204 (l_tracepoint_action_download): New.
15205 (add_tracepoint_action): Install `action->ops' according type.
15206 (download_tracepoint_1): Move code `download' function pointer
15207 of various tracepoint_action_ops.
15209 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
15211 * linux-low.c (linux_attach_lwp_1): New variable buffer. Call
15212 linux_ptrace_attach_warnings.
15214 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
15216 * Makefile.in (linux-ptrace.o): New.
15217 * configure.srv (arm*-*-linux*, bfin-*-*linux*, crisv32-*-linux*)
15218 (cris-*-linux*, i[34567]86-*-linux*, ia64-*-linux*, m32r*-*-linux*)
15219 (m68*-*-linux*, m68*-*-uclinux*, mips*-*-linux*, powerpc*-*-linux*)
15220 (s390*-*-linux*, sh*-*-linux*, sparc*-*-linux*, tic6x-*-uclinux)
15221 (x86_64-*-linux*, xtensa*-*-linux*): Add linux-ptrace.o to SRV_TGTOBJ
15223 * linux-low.c (linux_attach_lwp_1): Remove redundent else clause.
15225 2012-03-08 Yao Qi <yao@codesourcery.com>
15226 Pedro Alves <palves@redhat.com>
15228 Fix PR server/13392.
15229 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Check
15230 offset of JMP insn.
15231 * tracepoint.c (remove_tracepoint): New.
15232 (cmd_qtdp): Call remove_tracepoint when failed to install.
15234 2012-03-07 Pedro Alves <palves@redhat.com>
15236 * linux-low.c (get_detach_signal): New.
15237 (linux_detach_one_lwp): Get rid of a pending SIGSTOP with SIGCONT.
15238 Pass on pending signals to PTRACE_DETACH. Check the result of the
15240 * server.c (program_signals, program_signals_p): New.
15241 (handle_general_set): Handle QProgramSignals.
15242 * server.h (program_signals, program_signals_p): Declare.
15244 2012-03-05 Pedro Alves <palves@redhat.com>
15245 Jan Kratochvil <jan.kratochvil@redhat.com>
15247 * linux-low.c (get_dynamic): Don't warn when PT_PHDR isn't found.
15250 2012-03-03 Yao Qi <yao@codesourcery.com>
15252 * tracepoint.c (tracepoint_look_up_symbols): Update call to
15253 agent_look_up_symbols.
15255 2012-03-03 Yao Qi <yao@codesourcery.com>
15257 * Makefile.in (linux-low.o): Keep dependence on agent.h.
15258 (linux-x86-low.o): Likewise.
15259 * server.h: Remove in_process_agent_loaded.
15260 * tracepoint.c (in_process_agent_loaded): Removed. Moved it
15264 2012-03-03 Yao Qi <yao@codesourcery.com>
15266 * tracepoint.c (gdb_agent_capability): New global.
15267 (in_process_agent_loaded_ust): Renamed to
15268 `in_process_agent_supports_ust'.
15270 (in_process_agent_supports_ust): Call agent_capability_check.
15271 (clear_installed_tracepoints): Assert that agent supports
15274 2012-03-03 Yao Qi <yao@codesourcery.com>
15276 * linux-low.c (linux_supports_agent): New.
15277 (linux_target_ops): Initialize field `supports_agent' with
15278 linux_supports_agent.
15279 * target.h (struct target_ops) <supports_agent>: New.
15280 (target_supports_agent): New macro.
15281 * server.c (handle_general_set): Handle packet 'QAgent'.
15282 (handle_query): Send `QAgent+'.
15283 * Makefile.in (server.o): Depends on agent.h.
15285 2012-03-03 Yao Qi <yao@codesourcery.com>
15287 * Makefile.in (OBS): Add agent.o.
15288 Add new rule for agent.o.
15289 Track dependence of tracepoint.c on agent.h.
15290 * tracepoint.c (run_inferior_command_1):
15291 (run_inferior_command): Call agent_run_command.
15292 (gdb_ust_connect_sync_socket): Deleted. Move it to
15294 (resume_thread, stop_thread): Likewise.
15295 (gdb_ust_socket_init): Renamed to ...
15296 (gdb_agent_socket_init): ... New.
15297 (gdb_ust_thread): Renamed to ...
15298 (gdb_agent_helper_thread): ... New.
15299 (gdb_ust_init): Move some code to ...
15300 (gdb_agent_init): ... here. New.
15301 [HAVE_UST]: Call gdb_ust_init.
15302 (initialize_tracepoint_ftlib): Call gdb_agent_init.
15303 * configure.ac: Add `sys/un.h' to AC_CHECK_HEADERS.
15304 * config.in, configure: Regenerated.
15306 2012-03-02 Pedro Alves <palves@redhat.com>
15308 * inferiors.c (add_pid_to_list, pull_pid_from_list): Delete.
15309 * linux-low.c (struct simple_pid_list): New.
15310 (stopped_pids): New a struct simple_pid_list pointer.
15311 (add_to_pid_list, pull_pid_from_list): New.
15312 (handle_extended_wait): Don't assume the first signal new children
15313 report is SIGSTOP. Adjust call to pull_pid_from_list.
15314 (linux_wait_for_lwp): Adjust.
15316 2012-03-02 Yao Qi <yao@codesourcery.com>
15318 * tracepoint.c (do_action_at_tracepoint): Write `stop_pc' in
15321 2012-03-02 Yao Qi <yao@codesourcery.com>
15323 * tracepoint.c (collect_ust_data_at_tracepoint): Remove parameters
15324 `stop_pc' and `tpoint'. Update caller.
15326 2012-03-01 Maciej W. Rozycki <macro@codesourcery.com>
15328 * linux-low.h (linux_target_ops): Add regset_bitmap member.
15329 * linux-low.c (use_linux_regsets): New macro.
15330 [!HAVE_LINUX_REGSETS] (regsets_fetch_inferior_registers): Likewise.
15331 [!HAVE_LINUX_REGSETS] (regsets_store_inferior_registers): Likewise.
15332 (linux_register_in_regsets): New function.
15333 (usr_fetch_inferior_registers): Skip registers covered by
15335 (usr_store_inferior_registers): Likewise.
15336 (usr_fetch_inferior_registers): New macro.
15337 (usr_store_inferior_registers): Likewise.
15338 (linux_fetch_registers): Handle mixed regset/non-regset targets.
15339 (linux_store_registers): Likewise.
15340 * linux-mips-low.c (init_registers_mips_dsp_linux): New
15342 (init_registers_mips64_dsp_linux): Likewise.
15343 (init_registers_mips_linux): New macro.
15344 (init_registers_mips_dsp_linux): Likewise.
15345 (mips_dsp_num_regs): Likewise.
15346 (DSP_BASE, DSP_CONTROL): New fallback macros.
15347 (mips_base_regs): New macro.
15348 (mips_regmap): Use it. Fix the size.
15349 (mips_dsp_regmap): New variable.
15350 (mips_dsp_regset_bitmap): Likewise.
15351 (mips_arch_setup): New function.
15352 (mips_cannot_fetch_register): Use the_low_target.regmap rather
15354 (mips_cannot_store_register): Likewise.
15355 (the_low_target): Update .arch_setup, .num_regs and .regmap
15356 initializers. Add .regset_bitmap initializer.
15357 * linux-arm-low.c (the_low_target): Add .regset_bitmap
15359 * linux-bfin-low.c (the_low_target): Likewise.
15360 * linux-cris-low.c (the_low_target): Likewise.
15361 * linux-crisv32-low.c (the_low_target): Likewise.
15362 * linux-ia64-low.c (the_low_target): Likewise.
15363 * linux-m32r-low.c (the_low_target): Likewise.
15364 * linux-m68k-low.c (the_low_target): Likewise.
15365 * linux-ppc-low.c (the_low_target): Likewise.
15366 * linux-s390-low.c (the_low_target): Likewise.
15367 * linux-sh-low.c (the_low_target): Likewise.
15368 * linux-sparc-low.c (the_low_target): Likewise.
15369 * linux-tic6x-low.c (the_low_target): Likewise.
15370 * linux-x86-low.c (the_low_target): Likewise.
15371 * linux-xtensa-low.c (the_low_target): Likewise.
15372 * configure.srv <mips*-*-linux*>: Add mips-dsp-linux.o and
15373 mips64-dsp-linux.o to srv_regobj. Add mips-dsp-linux.xml,
15374 mips64-dsp-linux.xml, mips-dsp.xml and mips64-dsp.xml to
15376 * Makefile.in (mips-dsp-linux.o, mips-dsp-linux.c): New targets.
15377 (mips64-dsp-linux.o, mips64-dsp-linux.c): Likewise.
15379 2012-02-29 Yao Qi <yao@codesourcery.com>
15380 Pedro Alves <palves@redhat.com>
15382 * linux-low.c: (linux_wait_1): Call unsuspend_all_lwps when
15383 `step_over_finished' is true.
15385 2012-02-27 Pedro Alves <palves@redhat.com>
15387 * linux-low.c (pid_is_stopped): Delete, moved to common/.
15388 (linux_attach_lwp_1): Adjust to use linux_proc_pid_is_stopped.
15390 2012-02-27 Pedro Alves <palves@redhat.com>
15393 * linux-low.c (pid_is_stopped): New.
15394 (linux_attach_lwp_1): Handle attaching to 'T (stopped)' processes.
15396 2012-02-25 Luis Machado <lgustavo@codesourcery.com>
15398 * mem-break.c (clear_gdb_breakpoint_conditions): Fix de-allocation
15401 2012-02-24 Maciej W. Rozycki <macro@codesourcery.com>
15403 * linux-mips-low.c (mips_regmap): Correct the index of $f9.
15405 2012-02-24 Luis Machado <lgustavo@codesourcery>
15407 * server.c (handle_query): Advertise support for target-side
15408 breakpoint condition evaluation.
15409 (process_point_options): New function.
15410 (process_serial_event): When inserting a breakpoint, check for
15411 a target-side condition that should be evaluated.
15413 * mem-break.c: Include regcache.h and ax.h.
15414 (point_cond_list_t): New data structure.
15415 (breakpoint) <cond_list>: New field.
15416 (find_gdb_breakpoint_at): Make non-static.
15417 (delete_gdb_breakpoint_at): Clear any target-side
15419 (clear_gdb_breakpoint_conditions): New function.
15420 (add_condition_to_breakpoint): Likewise.
15421 (add_breakpoint_condition): Likewise.
15422 (gdb_condition_true_at_breakpoint): Likewise.
15423 (gdb_breakpoint_here): Return result directly instead
15424 of going through a local variable.
15426 * mem-break.h (find_gdb_breakpoint_at): New prototype.
15427 (clear_gdb_breakpoint_conditions): Likewise.
15428 (add_breakpoint_condition): Likewise.
15429 (gdb_condition_true_at_breakpoint): Likewise.
15431 * linux-low.c (linux_wait_1): Evaluate target-side breakpoint condition.
15432 (need_step_over_p): Take target-side breakpoint condition into
15435 2012-02-24 Luis Machado <lgustavo@codesourcery>
15437 * server.h: Include tracepoint.h.
15438 (agent_mem_read, agent_get_trace_state_variable_value,
15439 agent_set_trace_state_variable_value,
15440 agent_tsv_read, agent_mem_read_string, get_get_tsv_func_addr,
15441 get_set_tsv_func_addr): New prototypes.
15443 * ax.h: New include file.
15444 * ax.c: New source file.
15446 * tracepoint.c: Include ax.h.
15447 (gdb_agent_op, gdb_agent_op_names, gdb_agent_op_sizes,
15448 agent_expr, eval_result_type): Move to ax.h.
15449 (parse_agent_expr): Rename to ...
15450 (gdb_parse_agent_expr): ... this, make it non-static and move
15452 (unparse_agent_expr) Rename to ...
15453 (gdb_unparse_agent_expr): ... this, make it non-static and move
15455 (eval_agent_expr): Rename to ...
15456 (eval_tracepoint_agent_expr): ... this.
15457 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Remove
15458 forward declarations.
15459 (add_tracepoint_action): Call gdb_parse_agent_expr (...).
15460 (agent_get_trace_state_variable_value): New function.
15461 (agent_set_trace_state_variable_value): New function.
15462 (cmd_qtdp): Call gdb_parse_agent_expr (...).
15463 (response_tracepoint): Call gdb_unparse_agent_expr (...).
15464 (do_action_at_tracepoint): Call eval_tracepoint_agent_expr (...).
15465 (condition_true_at_tracepoint): Likewise.
15466 (parse_agent_expr): Rename to ...
15467 (gdb_parse_agent_expr): ... this and move to ax.c.
15468 (unparse_agent_expr): Rename to ...
15469 (gdb_unparse_agent_expr): ... this and move to ax.c.
15470 (gdb_agent_op_name): Move to ax.c.
15471 (eval_agent_expr): Rename to ...
15472 (gdb_eval_agent_expr): ... this, use regcache passed as parameter
15474 (eval_tracepoint_agent_expr): New function.
15475 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Make
15477 (current_insn_ptr, emit_error, struct bytecode_address): Move to
15479 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul, emit_lsh,
15480 emit_rsh_signed, emit_rsh_unsigned, emit_ext, emit_log_not,
15481 emit_bit_and, emit_bit_or, emit_bit_xor, emit_bit_not, emit_equal,
15482 emit_less_signed, emit_less_unsigned, emit_ref, emit_if_goto,
15483 emit_goto, write_goto_address, emit_const, emit_reg, emit_pop,
15484 emit_stack, emit_zero_ext, emit_swap, emit_stack_adjust,
15485 emit_int_call_1, emit_void_call_2, emit_eq_goto, emit_ne_goto,
15486 emit_lt_goto, emit_ge_goto, emit_gt_goto, emit_le_goto): Move to ax.c.
15487 (get_get_tsv_func_addr, get_set_tsv_func_addr): New functions.
15488 (compile_bytecodes): Remove forward declaration.
15489 (is_goto_target): Move to ax.c.
15490 (compile_bytecodes): Move to ax.c and call
15491 agent_get_trace_state_variable_value (...) and
15492 agent_set_trace_state_variable_value (...).
15494 * Makefile.in: Update ax.c and IPA dependencies.
15496 2012-02-24 Pedro Alves <palves@redhat.com>
15498 * tracepoint.c (cmd_bigqtbuffer): Rename as ...
15499 (cmd_bigqtbuffer_circular): ... this. Only handle
15500 'QTBuffer:circular:'.
15501 (handle_tracepoint_general_set): Adjust.
15503 2012-02-16 Yao Qi <yao@codesourcery.com>
15505 * inferiors.c: Move code to ...
15506 * dll.c: .... here. New.
15507 * server.h: Declare clear_dlls.
15508 * Makefile.in (SFILES): Add dll.c.
15512 2012-02-11 Yao Qi <yao@codesourcery.com>
15514 * server.c: (handle_monitor_command): Add a new parameter
15516 (handle_query): Update caller.
15518 2012-02-09 Joel Brobecker <brobecker@adacore.com>
15520 * configure.ac: Add readlink to AC_CHECK_FUNCS list.
15521 * configure, config.in: Regenerate.
15522 * hostio.c: Provide an alternate implementation if HAVE_READLINK
15525 2012-02-02 Pedro Alves <palves@redhat.com>
15527 Try SIGKILL first, then PTRACE_KILL.
15528 * linux-low.c (linux_kill_one_lwp): New.
15529 (linux_kill_one_lwp): Rename to ...
15530 (kill_one_lwp_callback): ... this. Use the new
15531 linux_kill_one_lwp.
15533 2012-02-02 Pedro Alves <palves@redhat.com>
15535 * tracepoint.c (cmd_qtminftpilen): Return 0 if there's no current
15538 2012-01-27 Pedro Alves <palves@redhat.com>
15540 * linux-low.c (linux_child_pid_to_exec_file): Delete.
15541 (elf_64_file_p): Make static.
15542 (linux_pid_exe_is_elf_64_file): New.
15543 * linux-low.h (linux_child_pid_to_exec_file, elf_64_file_p):
15544 Delete declarations.
15545 (linux_pid_exe_is_elf_64_file): Declare.
15546 * linux-x86-low.c (x86_arch_setup): Use
15547 linux_pid_exe_is_elf_64_file.
15549 2012-01-25 Jan Kratochvil <jan.kratochvil@redhat.com>
15551 * linux-low.c (linux_wait_for_event_1): Rename to ...
15552 (linux_wait_for_event): ... here and merge it with former
15553 linux_wait_for_event - new variable wait_ptid, use it.
15554 (linux_wait_for_event): Remove - merge it to linux_wait_for_event_1.
15556 2012-01-23 Pedro Alves <palves@redhat.com>
15558 * server.c (main): Avoid yet another case of infinite loop while
15559 detaching/killing after a longjmp.
15561 2012-01-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15564 * linux-low.c (linux_wait_for_event_1): Use ptid_is_pid.
15566 2012-01-20 Ulrich Weigand <ulrich.weigand@linaro.org>
15568 * hostio.c (handle_readlink): New function.
15569 (handle_vFile): Call it to handle "vFile:readlink" packets.
15571 2012-01-20 Pedro Alves <palves@redhat.com>
15572 Ulrich Weigand <ulrich.weigand@linaro.org>
15574 * server.c (handle_v_requests): Only support vAttach and vRun to
15575 start multiple processes when in extended protocol mode.
15577 2012-01-17 Pedro Alves <palves@redhat.com>
15579 * tracepoint.c (initialize_tracepoint): Use mmap instead of
15580 memalign plus mprotect to allocate the scratch buffer.
15582 2012-01-13 Pedro Alves <palves@redhat.com>
15584 * server.c (attach_inferior): Clear `cont_thread'.
15586 2012-01-13 Pedro Alves <palves@redhat.com>
15588 * server.c (main): Avoid infinite loop while detaching/killing
15591 2012-01-09 Doug Evans <dje@google.com>
15593 * server.c (start_inferior): Set last_ptid in --wrapper case.
15595 2012-01-06 Yao Qi <yao@codesourcery.com>
15597 * tracepoint.c [IN_PROCESS_AGENT] (debug_threads): Macro
15599 [IN_PROCESS_AGENT] (debug_agent): New global variable.
15601 2012-01-04 Yao Qi <yao@codesourcery.com>
15603 * tracepoint.c (cmd_qtdp): Print debug message
15604 for static tracepoint.
15606 2012-01-04 Yao Qi <yao@codesourcery.com>
15608 * tracepoint.c (trace_vdebug): Differentiate debug message
15609 between gdbserver and IPA.
15611 2012-01-03 Yao Qi <yao@codesourcery.com>
15613 * tracepoint.c (tracepoint_was_hit): Don't collect for
15616 2012-01-02 Joel Brobecker <brobecker@adacore.com>
15618 * terminal.h: Reformat copyright header.
15620 2012-01-02 Joel Brobecker <brobecker@adacore.com>
15622 * server.c (gdbserver_version): Update copyright year.
15623 * gdbreplay.c (gdbreplay_version): Likewise.
15625 2011-12-18 Jan Kratochvil <jan.kratochvil@redhat.com>
15627 * linux-low.c (linux_create_inferior): Put empty if clause for write.
15630 2011-12-18 Hui Zhu <teawater@gmail.com>
15631 * linux-low.c (linux_create_inferior): Save return value to ret.
15633 2011-12-18 Hui Zhu <teawater@gmail.com>
15635 * linux-low.c (linux_create_inferior): Save return value to ret.
15637 2011-12-16 Doug Evans <dje@google.com>
15639 * linux-low.c (linux_create_inferior): If stdio connection,
15640 redirect stdin from /dev/null, stdout to stderr.
15641 * remote-utils.c (remote_is_stdio): New static global.
15642 (remote_connection_is_stdio): New function.
15643 (remote_prepare): Handle stdio connection.
15644 (remote_open): Ditto.
15645 (remote_close): Don't close stdin for stdio connections.
15646 (read_prim,write_prim): New functions. Replace all calls to
15647 read/write to these.
15648 * server.c (main): Watch for "-" argument. Move call to
15649 remote_prepare before start_inferior.
15650 * server.h (STDIO_CONNECTION_NAME): New macro.
15651 (remote_connection_is_stdio): Declare.
15653 * remote-utils.c (prepare_resume_reply): Remove extraneous \n
15654 in debugging output.
15656 2011-12-15 Yao Qi <yao@codesourcery.com>
15658 * tracepoint.c: Include sys/syscall.h.
15659 (gdb_ust_thread): Remove preprocessor conditional.
15661 2011-12-14 Pedro Alves <pedro@codesourcery.com>
15663 * linux-low.c (linux_detach_one_lwp): Call
15664 the_low_target.prepare_to_resume before detaching.
15666 2011-12-14 Yao Qi <yao@codesourcery.com>
15668 * tracepoint.c (gdb_ust_thread): Don't ignore return value
15671 2011-12-14 Yao Qi <yao@codesourcery.com>
15673 * i386-low.c (i386_low_stopped_data_address): Initialize local
15674 variable `control'.
15676 2011-12-13 Pedro Alves <pedro@codesourcery.com>
15680 * i386-low.c (i386_low_stopped_data_address): Avoid fetching
15681 DR_CONTROL unless necessary. Extend comments.
15682 * linux-x86-low.c (x86_linux_prepare_to_resume): Don't write to
15683 DR0-3 if not used. If any watchpoint was set, clear DR_STATUS.
15685 2011-12-13 Yao Qi <yao@codesourcery.com>
15687 * tracepoint.c (trace_buffer_alloc): Replace magic numbers with
15689 (upload_fast_traceframes, upload_fast_traceframes): Likewise.
15691 2011-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
15693 * linux-low.c (linux_kill): Skip PTRACE_KILL if LWP does not exist.
15694 Print new debug message for such case.
15696 2011-12-06 Jan Kratochvil <jan.kratochvil@redhat.com>
15698 Fix overlapping memcpy.
15699 * mem-break.c (set_raw_breakpoint_at): New variable buf. Use it for
15700 the read_inferior_memory transfer.
15701 (delete_fast_tracepoint_jump): New variable buf. Use it for the
15702 write_inferior_memory transfer.
15703 (set_fast_tracepoint_jump): New variable buf. Use it for the
15704 read_inferior_memory and write_inferior_memory transfers.
15705 (uninsert_fast_tracepoint_jumps_at, reinsert_fast_tracepoint_jumps_at)
15706 (delete_raw_breakpoint, uninsert_raw_breakpoint): New variable buf.
15707 Use it for the write_inferior_memory transfer.
15708 (check_mem_read, check_mem_write): New gdb_asserts for overlapping
15711 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
15713 * linux-low.c (fetch_register, store_register): Make code
15714 consistent, fix formatting.
15716 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
15718 * linux-low.c (usr_store_inferior_registers): Factor out code
15719 to handle individual registers into...
15720 (store_register): ... this new function.
15722 2011-12-06 Ulrich Weigand <uweigand@de.ibm.com>
15724 * Makefile.in (s390-linux32v1.o, s390-linux32v1.c): New rules.
15725 (s390-linux32v2.o, s390-linux32v2.c): Likewise.
15726 (s390-linux64v1.o, s390-linux64v1.c): Likewise.
15727 (s390-linux64v2.o, s390-linux64v2.c): Likewise.
15728 (s390x-linux64v1.o, s390x-linux64v1.c): Likewise.
15729 (s390x-linux64v2.o, s390x-linux64v2.c): Likewise.
15730 * configure.srv [s390*-*-linux*] (srv_regobj): Add new objects.
15731 (srv_xmlfiles): Add new XML files.
15733 * linux-s390-low.c: Include "elf/common.h", <sys/ptrace.h>,
15735 (PTRACE_GETREGSET, PTRACE_SETREGSET): Define if undefined.
15736 (init_registers_s390_linux32v1): Add prototype.
15737 (init_registers_s390_linux32v2): Likewise.
15738 (init_registers_s390_linux64v1): Likewise.
15739 (init_registers_s390_linux64v2): Likewise.
15740 (init_registers_s390x_linux64v1): Likewise.
15741 (init_registers_s390x_linux64v2): Likewise.
15742 (s390_num_regs): Increment to 52.
15743 (s390_regmap): Add orig_r2 register.
15744 (s390_num_regs_3264): Increment to 68.
15745 (s390_regmap_3264): Add orig_r2 register.
15746 (s390_collect_ptrace_register): Handle orig_r2 register.
15747 (s390_supply_ptrace_register): Likewise.
15748 (s390_fill_last_break): New function.
15749 (s390_store_last_break): Likewise.
15750 (s390_fill_system_call): New function.
15751 (s390_store_system_call): Likewise.
15752 (target_regsets): Handle NT_S390_LAST_BREAK and NT_S390_SYSTEM_CALL
15754 (s390_check_regset): New function.
15755 (s390_arch_setup): Check for presence of NT_S390_LAST_BREAK and
15756 NT_S390_SYSTEM_CALL regsets and use appropriate description.
15757 Update target_regsets for available register sets.
15759 2011-12-02 Paul Pluzhnikov <ppluzhnikov@google.com>
15760 Jan Kratochvil <jan.kratochvil@redhat.com>
15762 * linux-low.c (get_phdr_phnum_from_proc_auxv, get_dynamic, get_r_debug)
15763 (read_one_ptr, struct link_map_offsets, linux_qxfer_libraries_svr4):
15765 (struct linux_target_ops): Install linux_qxfer_libraries_svr4.
15766 * linux-low.h (struct process_info_private): New member r_debug.
15767 * server.c (handle_qxfer_libraries): Call
15768 the_target->qxfer_libraries_svr4.
15769 (handle_qxfer_libraries_svr4): New function.
15770 (qxfer_packets): New entry "libraries-svr4".
15771 (handle_query): Check QXFER_LIBRARIES_SVR4 and report libraries-svr4.
15772 * target.h (struct target_ops): New member qxfer_libraries_svr4.
15773 * remote.c (remote_xfer_partial): Call add_packet_config_cmd for
15774 PACKET_qXfer_libraries_svr4.
15776 2011-11-30 Ulrich Weigand <uweigand@de.ibm.com>
15778 * linux-s390-low.c (s390_collect_ptrace_register): Fully convert
15779 PSW address/mask between 8-byte and 16-byte formats.
15780 (s390_supply_ptrace_register): Likewise.
15781 (s390_get_pc, s390_set_pc): 4-byte PSW address always includes
15782 basic addressing mode bit.
15784 2011-11-24 Stan Shebs <stan@codesourcery.com>
15786 * tracepoint.c (cmd_qtstatus): Use plongest instead of %llx.
15788 2011-11-17 Stan Shebs <stan@codesourcery.com>
15790 * tracepoint.c (struct tracepoint): New field traceframe_usage.
15791 (tracing_start_time): New global.
15792 (tracing_stop_time): New global.
15793 (tracing_user_name): New global.
15794 (tracing_notes): New global.
15795 (tracing_stop_note): New global.
15796 (cmd_qtstart): Set traceframe_usage, start_time.
15797 (stop_tracing): Set stop_time.
15798 (cmd_qtstatus): Report additional status.
15799 (cmd_qtp): New function.
15800 (handle_tracepoint_query): Call it.
15801 (cmd_qtnotes): New function.
15802 (handle_tracepoint_general_set): Call it.
15803 (get_timestamp): Rename from tsv_get_timestamp.
15805 2011-11-14 Stan Shebs <stan@codesourcery.com>
15806 Kwok Cheung Yeung <kcy@codesourcery.com>
15808 * linux-x86-low.c (small_jump_insn): New.
15809 (i386_install_fast_tracepoint_jump_pad): Add arguments for
15810 trampoline and error message, build a trampoline and issue a small
15811 jump instruction to it.
15812 (x86_install_fast_tracepoint_jump_pad): Add arguments for
15813 trampoline and error message.
15814 (x86_get_min_fast_tracepoint_insn_len): New.
15815 (the_low_target): Add call to x86_get_min_fast_tracepoint_insn_len.
15816 * linux-low.h (struct linux_target_ops): Add arguments to
15817 install_fast_tracepoint_jump_pad operation, add new operation.
15818 * linux-low.c (linux_install_fast_tracepoint_jump_pad): Add
15820 (linux_get_min_fast_tracepoint_insn_len): New function.
15821 (linux_target_op): Add new operation.
15822 * tracepoint.c (gdb_trampoline_buffer): New IPA variable.
15823 (gdb_trampoline_buffer_end): Ditto.
15824 (gdb_trampoline_buffer_error): Ditto.
15825 (struct ipa_sym_addresses): Add fields for new IPA variables.
15826 (symbol_list): Add entries for new IPA variables.
15827 (struct tracepoint): Add fields to hold the address range of the
15828 trampoline used by the tracepoint.
15829 (trampoline_buffer_head): New static variable.
15830 (trampoline_buffer_tail): Ditto.
15831 (claim_trampoline_space): New function.
15832 (have_fast_tracepoint_trampoline_buffer): New function.
15833 (clone_fast_tracepoint): Fill in trampoline fields of tracepoint
15835 (install_fast_tracepoint): Ditto, also add error buffer argument.
15836 (cmd_qtminftpilen): New function.
15837 (handle_tracepoint_query): Add response to qTMinFTPILen packet.
15838 (fast_tracepoint_from_trampoline_address): New function.
15839 (fast_tracepoint_collecting): Handle trampoline as part of jump
15841 (set_trampoline_buffer_space): New function.
15842 (initialize_tracepoint): Initialize new IPA variables.
15843 * target.h (struct target_ops): Add arguments to
15844 install_fast_tracepoint_jump_pad operation, add new
15845 get_min_fast_tracepoint_insn_len operation.
15846 (target_get_min_fast_tracepoint_insn_len): New.
15847 (install_fast_tracepoint_jump_pad): Add arguments.
15848 * server.h (IPA_BUFSIZ): Define.
15849 * linux-i386-ipa.c: Include extra header files.
15850 (initialize_fast_tracepoint_trampoline_buffer): New function.
15851 (initialize_low_tracepoint): Call it.
15852 * server.h (set_trampoline_buffer_space): Declare.
15853 (claim_trampoline_space): Ditto.
15854 (have_fast_tracepoint_trampoline_buffer): Ditto.
15856 2011-11-14 Yao Qi <yao@codesourcery.com>
15858 * server.c (handle_query): Handle InstallInTrace for qSupported.
15859 * tracepoint.c (add_tracepoint): Sort list.
15860 (install_tracepoint, download_tracepoint): New.
15861 (cmd_qtdp): Call them to install and download tracepoints.
15862 (sort_tracepoints): Removed.
15863 (cmd_qtstart): Update.
15865 2011-11-14 Yao Qi <yao@codesourcery.com>
15867 * mem-break.c (inc_ref_fast_tracepoint_jump): New.
15868 * mem-break.h: Declare.
15869 * tracepoint.c (cmd_qtstart): Move some code to ...
15870 (clone_fast_tracepoint, install_fast_tracepoint): ... here.
15872 (download_tracepoints): Move some code to ...
15873 (download_tracepoint_1): ... here. New.
15875 2011-11-08 Yao Qi <yao@codesourcery.com>
15877 * remote-utils.c (relocate_instruction): A comment fix.
15879 2011-11-07 Joel Brobecker <brobecker@adacore.com>
15881 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): Delete.
15882 (i386_dr_low_get_control, i386_dr_low_get_status): Use
15883 dr_status_mirror and dr_control_mirror from debug_reg_state.
15884 (i386_dr_low_get_status): Use debug_reg_state.dr_status_mirror
15885 (i386_initial_stuff): Remove use of deleted globals.
15886 (i386_get_thread_context, i386_set_thread_context,
15887 i386_thread_added): Use dr_status_mirror and dr_control_mirror
15888 from debug_reg_state.
15890 2011-11-05 Yao Qi <yao@codesourcery.com>
15892 * tracepoint.c (gdb_collect): Loop over tracepoints of same
15893 address as TPOINT's.
15895 2011-11-02 Stan Shebs <stan@codesourcery.com>
15897 * tracepoint.c (agent_mem_read_string): New function.
15898 (eval_agent_expr): Call it for tracenz.
15899 * server.c (handle_query): Report support for tracenz.
15901 2011-11-02 Yao Qi <yao@codesourcery.com>
15903 * tracepoint.c (cmd_qtstart): Remove unused local variables.
15905 2011-11-02 Yao Qi <yao@codesourcery.com>
15907 * target.h: Fix a typo in comment.
15909 2011-10-31 Pedro Alves <pedro@codesourcery.com>
15911 * mem-break.c (check_mem_write): Add `myaddr' parameter. Don't
15912 clobber the breakpoints' shadows with fast tracepoint jumps.
15913 * mem-break.h (check_mem_write): Add `myaddr' parameter.
15914 * target.c (write_inferior_memory): Also pass MYADDR down to
15917 2011-10-07 Ulrich Weigand <ulrich.weigand@linaro.org>
15919 * configure.ac: Check support for personality routine.
15920 * configure: Regenerate.
15921 * config.in: Likewise.
15922 * linux-low.c: Include <sys/personality.h>.
15923 Define ADDR_NO_RANDOMIZE if necessary.
15924 (linux_create_inferior): Disable address space randomization when
15925 forking inferior, if requested.
15926 (linux_supports_disable_randomization): New function.
15927 (linux_target_ops): Install it.
15928 * server.h (disable_randomization): Declare.
15929 * server.c (disable_randomization): New global variable.
15930 (handle_general_set): Handle QDisableRandomization.
15931 (handle_query): Likewise for qSupported.
15932 (main): Support --disable-randomization and --no-disable-randomization
15933 command line arguments.
15934 * target.h (struct target_ops): Add supports_disable_randomization.
15935 (target_supports_disable_randomization): New macro.
15937 2011-09-29 Mike Frysinger <vapier@gentoo.org>
15939 * linux-low.c (target_loadseg): Add defined PTRACE_GETFDPIC to the
15941 [PT_GETDSBT] (target_loadmap): Wrap in a defined PT_GETDSBT check.
15942 [!PT_GETDSBT] (target_loadmap): New definition.
15943 (LINUX_LOADMAP, LINUX_LOADMAP_EXEC, LINUX_LOADMAP_INTERP): Define.
15944 (linux_read_loadmap): Change PTRACE_GETDSBT_EXEC to
15945 LINUX_LOADMAP_EXEC, PTRACE_GETDSBT_INTERP to LINUX_LOADMAP_INTERP,
15946 and PT_GETDSBT to LINUX_LOADMAP.
15947 [!PT_GETDSBT] (linux_read_loadmap): Define to NULL.
15948 (linux_target_ops): Delete unnecessary ifdef PT_GETDSBT check.
15950 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
15952 * linux-arm-low.c (struct arm_linux_hwbp_cap): Remove.
15953 (arm_linux_hwbp_cap): New static variable.
15954 (arm_linux_get_hwbp_cap): Replace by ...
15955 (arm_linux_init_hwbp_cap): ... this new function.
15956 (arm_linux_get_hw_breakpoint_count): Use arm_linux_hwbp_cap.
15957 (arm_linux_get_hw_watchpoint_count): Likewise.
15958 (arm_linux_get_hw_watchpoint_max_length): Likewise.
15959 (arm_arch_setup): Call arm_linux_init_hwbp_cap.
15960 (arm_prepare_to_resume): Use perror_with_name instead of error.
15962 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
15964 * linux-arm-low.c: Include <signal.h>.
15965 (PTRACE_GETHBPREGS, PTRACE_SETHBPREGS): Define if necessary.
15966 (struct arm_linux_hwbp_cap): New data type.
15967 (arm_hwbp_type, arm_hwbp_control_t): New typedefs.
15968 (struct arm_linux_hw_breakpoint): New data type.
15969 (MAX_BPTS, MAX_WPTS): Define.
15970 (struct arch_process_info, struct arch_lwp_info): New data types.
15971 (arm_linux_get_hwbp_cap): New function.
15972 (arm_linux_get_hw_breakpoint_count): Likewise.
15973 (arm_linux_get_hw_watchpoint_count): Likewise.
15974 (arm_linux_get_hw_watchpoint_max_length): Likewise.
15975 (arm_hwbp_control_initialize): Likewise.
15976 (arm_hwbp_control_is_enabled): Likewise.
15977 (arm_hwbp_control_is_initialized): Likewise.
15978 (arm_hwbp_control_disable): Likewise.
15979 (arm_linux_hw_breakpoint_equal): Likewise.
15980 (arm_linux_hw_point_initialize): Likewise.
15981 (struct update_registers_data): New data structure.
15982 (update_registers_callback: New function.
15983 (arm_insert_point): Likewise.
15984 (arm_remove_point): Likewise.
15985 (arm_stopped_by_watchpoint): Likewise.
15986 (arm_stopped_data_address): Likewise.
15987 (arm_new_process): Likewise.
15988 (arm_new_thread): Likewise.
15989 (arm_prepare_to_resume): Likewise.
15990 (the_low_target): Register arm_insert_point, arm_remove_point,
15991 arm_stopped_by_watchpoint, arm_stopped_data_address, arm_new_process,
15992 arm_new_thread, and arm_prepare_to_resume.
15994 2011-09-15 Stan Shebs <stan@codesourcery.com>
15996 * server.h (struct emit_ops): Add compare-goto fields.
15997 * tracepoint.c (gdb_agent_op_sizes): New table.
15998 (emit_eq_goto): New function.
15999 (emit_ne_goto): New function.
16000 (emit_lt_goto): New function.
16001 (emit_le_goto): New function.
16002 (emit_gt_goto): New function.
16003 (emit_ge_goto): New function.
16004 (is_goto_target): New function.
16005 (compile_bytecodes): Recognize special cases of compare-goto
16006 combinations and call specialized emitters for them.
16007 * linux-x86-low.c (amd64_emit_eq_goto): New function.
16008 (amd64_emit_ne_goto): New function.
16009 (amd64_emit_lt_goto): New function.
16010 (amd64_emit_le_goto): New function.
16011 (amd64_emit_gt_goto): New function.
16012 (amd64_emit_ge_goto): New function.
16013 (amd64_emit_ops): Add the new functions.
16014 (i386_emit_eq_goto): New function.
16015 (i386_emit_ne_goto): New function.
16016 (i386_emit_lt_goto): New function.
16017 (i386_emit_le_goto): New function.
16018 (i386_emit_gt_goto): New function.
16019 (i386_emit_ge_goto): New function.
16020 (i386_emit_ops): Add the new functions.
16022 2011-09-08 Stan Shebs <stan@codesourcery.com>
16024 * linux-x86-low.c (i386_emit_prologue): Save %ebx.
16025 (i386_emit_epilogue): Restore %ebx.
16027 2011-08-31 Jie Zhang <jzhang918@gmail.com>
16029 * server.c (step_thread): Remove definition.
16030 (process_serial_event): Don't handle Hs.
16031 * server.h (step_thread): Remove declaration.
16032 * target.c (set_desired_inferior): Remove use of step_thread.
16034 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
16036 * linux-low.c: Include linux-procfs.h.
16037 (linux_attach_lwp_1): Update comments.
16038 (linux_attach): Scan for existing threads when attaching to a
16039 process that is the tgid.
16040 * Makefile.in: Update dependencies.
16042 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
16044 * configure.srv: Add linux-procfs.o dependencies.
16046 2011-08-14 Yao Qi <yao@codesourcery.com>
16048 * target.h (struct target_ops): Fix indent.
16049 * win32-low.c (win32_target_ops): Fix comment.
16051 2011-08-14 Andrew Jenner <andrew@codesourcery.com>
16052 Yao Qi <yao@codesourcery.com>
16054 * Makefile.in (clean): Remove tic6x-*.c files.
16055 (linux-tic6x-low.o, tic6x-c62x-linux.o, tic6x-c64x-linux.o): New rules.
16056 (tic6x-c64xp-linux.o, tic6x-c62x-linux.c, tic6x-c64x-linux.c): Likewise.
16057 (tic6x-c64xp-linux.c): Likewise.
16058 * configure.srv: Add support for tic6x-*-uclinux.
16059 * linux-tic6x-low.c: New.
16060 * linux-low.c (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define.
16062 2011-08-14 Andrew Stubbs <ams@codesourcery.com>
16063 Yao Qi <yao@codesourcery.com>
16065 * target.h (struct target_ops): Add read_loadmap.
16066 * linux-low.c (struct target_loadseg): New type.
16067 (struct target_loadmap): New type.
16068 (linux_read_loadmap): New function.
16069 (linux_target_ops): Add linux_read_loadmap.
16070 * server.c (handle_query): Support qXfer:fdpic:read packet.
16071 * win32-low.c (win32_target_ops): Initialize field `read_loadmap'
16074 2011-08-05 Eli Zaretskii <eliz@gnu.org>
16076 * win32-low.c: Include <stdint.h>.
16078 2011-07-22 Pedro Alves <pedro@codesourcery.com>
16080 * i386-low.c (i386_insert_aligned_watchpoint): Don't pass the info
16081 to the inferior here.
16082 (i386_remove_aligned_watchpoint): Ditto.
16083 (i386_handle_nonaligned_watchpoint): Return immediate on fail to
16084 fit part of the watchpoint in the debug registers.
16085 (i386_update_inferior_debug_regs): New.
16086 (i386_low_insert_watchpoint): Work on a local mirror of the debug
16087 registers, and only update the inferior on success.
16088 (i386_low_remove_watchpoint): Ditto.
16090 2011-07-22 Kwok Cheung Yeung <kcy@codesourcery.com>
16092 * linux-low.c (compare_ints, unique, list_threads, show_process,
16093 linux_core_of_thread): Delete.
16094 (linux_target_ops): Change linux_core_of_thread to
16095 linux_common_core_of_thread.
16096 (linux_qxfer_osdata): Defer to linux_common_xfer_osdata.
16097 * utils.c (malloc_failure): Change type of argument.
16098 (xmalloc, xrealloc, xcalloc, xsnprintf): Delete.
16099 * Makefile.in (SFILES): Add common/common-utils.c, common/xml-utils.c,
16100 common/linux-osdata.c, common/ptid.c and common/buffer.c.
16101 (OBS): Add xml-utils.o, common-utils.o, ptid.o and buffer.o.
16102 (IPA_OBJS): Add common-utils-ipa.o.
16103 (ptid_h, linux_osdata_h): New macros.
16104 (server_h): Add common/common-utils.h, common/xml-utils.h,
16105 common/buffer.h, common/gdb_assert.h, common/gdb_locale.h and
16107 (common-utils-ipa.o, common-utils.o, xml-utils.o, linux-osdata.o,
16108 ptid.o, buffer.o): New rules.
16109 (linux-low.o): Add common/linux-osdata.h as a dependency.
16110 * configure.srv (srv_tgtobj): Add linux-osdata.o to Linux targets.
16111 * configure.ac: Add AC_HEADER_DIRENT check.
16112 * config.in: Regenerate.
16113 * configure: Regenerate.
16114 * remote-utils.c (xml_escape_text): Delete.
16115 (buffer_grow, buffer_free, buffer_init, buffer_finish,
16116 buffer_xml_printf): Move to common/buffer.c.
16117 * server.c (main): Remove call to initialize_inferiors.
16118 * server.h (struct ptid, ptid_t, minus_one_ptid, null_ptid,
16119 ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp, ptid_get_tid,
16120 ptid_equal, ptid_is_pid, initialize_inferiors, xml_escape_text,
16121 internal_error, gdb_assert, gdb_assert_fail): Delete.
16122 (struct buffer, buffer_grow, buffer_free, buffer_init, buffer_finish,
16123 buffer_xml_printf, buffer_grow_str, buffer_grow_str0): Move to
16125 * inferiors.c (null_ptid, minus_one_ptid, ptid_build, pid_to_ptid,
16126 ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal, ptid_is_pid,
16127 initialize_inferiors): Delete.
16129 2011-07-20 Pedro Alves <pedro@codesourcery.com>
16131 * tracepoint.c (tracepoint_look_up_symbols): Return upon the first
16134 2011-05-31 Pedro Alves <pedro@codesourcery.com>
16136 * linux-x86-low.c (i386_dr_low_get_addr): Fix off by one in
16138 * win32-i386-low.c (i386_dr_low_get_addr): Ditto.
16140 2011-05-26 Yao Qi <yao@codesourcery.com>
16142 * Makefile.in (thread-db.o): Track dependence to
16143 common/gdb_thread_db.h.
16144 * thread-db.c: include gdb_thread_db.h from right place.
16146 2011-05-16 Adrian Cornish <gnu@bluedreamer.com>
16148 * linux-i386-ipa.c (supply_static_tracepoint_registers): Pass
16149 __FILE__ and __LINE__ to internal_error.
16151 2011-05-13 Doug Evans <dje@google.com>
16153 * thread-db.c (try_thread_db_load_from_sdir): New function.
16154 (try_thread_db_load_from_dir): New function.
16155 (thread_db_load_search): Handle $sdir, ignore $pdir.
16156 Remove trying of system directories if search of
16157 libthread-db-search-path fails, that is now done via $sdir.
16159 2011-05-12 Kwok Cheung Yeung <kcy@codesourcery.com>
16161 * server.c (handle_query): Add EnableDisableTracepoints to the list
16162 of supported features.
16163 * tracepoint.c (clear_installed_tracepoints): Uninstall disabled
16165 (cmd_qtenable_disable): New.
16166 (cmd_qtstart): Install tracepoints even if disabled.
16167 (handle_tracepoint_general_set): Add call to cmd_qtenable_disable on
16168 receiving a QTEnable or QTDisable packet.
16169 (gdb_collect): Skip data collection if fast tracepoint is disabled.
16170 (ust_marker_to_static_tracepoint): Do not ignore disabled static
16172 (gdb_probe): Skip data collection if static tracepoint is disabled.
16174 2011-05-10 Doug Evans <dje@google.com>
16176 * thread-db.c (thread_db_handle_monitor_command): Handle elided path.
16178 2011-05-04 Doug Evans <dje@google.com>
16180 * linux-low.c (linux_join): Skip process lookup.
16181 * spu-low.c (spu_join): Ditto.
16182 * server.c (join_inferiors_callback): Delete.
16183 (process_serial_event): For 'D' packet (detach) call join_inferior
16186 2011-05-04 Joseph Myers <joseph@codesourcery.com>
16188 * README: Don't mention xscale*-*-linux*.
16189 * configure.srv (xscale*-*-linux*): Don't handle target.
16191 2011-04-27 Nathan Froyd <froydnj@codesourcery.com>
16193 * linux-x86-low.c (amd64_emit_const): Call memcpy instead of
16195 (amd64_emit_reg, amd64_emit_int_call_1, amd64_emit_void_call_2):
16196 (i386_emit_const, i386_emit_reg, i386_emit_int_call_1):
16197 (i386_emit_void_call_2): Likewise.
16199 2011-04-26 Yao Qi <yao@codesourcery.com>
16201 * linux-low.c: Move common macros to linux-ptrace.h.
16202 Include linux-ptrace.h.
16203 * Makefile.in (linux_ptrace_h): New.
16204 (linux-low.o): Depends on linux-ptrace.h.
16206 2011-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
16208 * remote-utils.c (handle_accept_event): Close LISTEN_DESC only if
16209 RUN_ONCE. Comment for the LISTEN_DESC delete_file_handler call.
16210 (remote_prepare): New function with most of the TCP code from ...
16211 (remote_open): ... here. Detect PORT here unconditionally. Move also
16212 setting transport_is_reliable.
16213 * server.c (run_once): New variable.
16214 (gdbserver_usage): Document it.
16215 (main): Set run_once for `--once'. Call remote_prepare. Exit after
16216 the first run if RUN_ONCE.
16217 * server.h (run_once, remote_prepare): New declarations.
16219 2011-04-19 Tom Tromey <tromey@redhat.com>
16221 * win32-low.c (handle_load_dll): Remove duplicate "the".
16223 2011-04-07 Pierre Muller <muller@ics.u-strasbg.fr>
16225 Remove support for old Cygwin 1.5 versions.
16226 * win32-low.c (win32_create_inferior): Use new cygwin_path_list
16227 function to avoid warning.
16228 (win32_add_one_solib): Use cygwin_conv_path function to avoid
16231 2011-03-18 Pierre Muller <muller@ics.u-strasbg.fr>
16233 * gdbserver/server.h (Macro _): Define it if not available.
16235 2011-03-14 Michael Snyder <msnyder@vmware.com>
16237 * hostio.c (handle_close): Remove unnecessary null test.
16239 2011-03-10 Joel Brobecker <brobecker@adacore.com>
16241 * Makefile.in (maintainer-clean realclean distclean): Remove
16242 "make ... subdir_do" command.
16244 2011-03-10 Michael Snyder <msnyder@vmware.com>
16246 * tracepoint.c (tracepoint_finish_step): Fix loop variable.
16248 * server.c (handle_v_run): Free alloced buffer on early return.
16250 2011-03-09 Yao Qi <yao@codesourcery.com>
16253 2011-03-04 Yao Qi <yao@codesourcery.com>
16255 * Makefile.in: Remove GNU make feature --directory.
16257 2011-03-05 Yao Qi <yao@codesourcery.com>
16259 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
16260 (subdir_do): New make target. Copied from gdb/Makefile.
16261 (maintainer-clean, realclean, distclean, clean): Call corresponding
16262 make targets in common/Makefile.
16264 2011-02-11 Yao Qi <yao@codesourcery.com>
16266 * configure.ac: Call AC_PROG_RANLIB.
16267 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
16268 * configure: Regenerate.
16270 2011-03-07 Jan Kratochvil <jan.kratochvil@redhat.com>
16272 * remote-utils.c (putpkt_binary_1): Calculate BUF2 size dynamically.
16274 2011-03-06 Yao Qi <yao@codesourcery.com>
16276 * Makefile.in (REQUIRED_SUBDIRS): Remove $(LIBCOMMON_DIR).
16278 2011-03-05 Yao Qi <yao@codesourcery.com>
16280 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
16281 (subdir_do): New make target. Copied from gdb/Makefile.
16282 (maintainer-clean, realclean, distclean, clean): Call corresponding
16283 make targets in common/Makefile.
16285 2011-03-04 Yao Qi <yao@codesourcery.com>
16287 * Makefile.in: Remove GNU make feature --directory.
16289 2011-03-04 Michael Snyder <msnyder@vmware.com>
16291 * server.c (queue_stop_reply): Call xmalloc not malloc.
16293 2011-03-02 Michael Snyder <msnyder@vmware.com>
16295 * linux-arm-low.c (arm_arch_setup): Replace malloc with xmalloc.
16297 2011-02-28 Michael Snyder <msnyder@vmware.com>
16299 * tracepoint.c (cmd_qtv): Discard unused value 'packet'.
16300 (cmd_qtframe): Ditto.
16301 (cmd_qtbuffer): Ditto.
16302 (cmd_bigqtbuffer): Ditto.
16304 * utils.c (decimal2str): Initialize 'width' to nine, then
16305 don't mess with it.
16307 2011-02-28 Ulrich Weigand <uweigand@de.ibm.com>
16309 * hostio.c (require_data): Free *data, not data.
16311 2011-02-28 Jan Kratochvil <jan.kratochvil@redhat.com>
16313 * hostio.c (require_data): Use free, not xfree.
16315 2011-02-27 Michael Snyder <msnyder@vmware.com>
16317 * server.c (handle_query): Discard unused value.
16319 * hostio.c (require_data): Free malloc memory before returning
16322 2011-02-26 Michael Snyder <msnyder@vmware.com>
16324 * linux-low.c (list_threads): Call closedir for dirent.
16326 2011-02-27 Michael Snyder <msnyder@vmware.com>
16328 * i386-low.c (i386-length_and_rw_bits): Comment the fact that
16329 a case statement falls through.
16331 * linux-low.c (linux_xfer_siginfo): Fix fencepost error.
16333 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Fix fencepost error
16336 2011-02-26 Michael Snyder <msnyder@vmware.com>
16338 * utils.c (decimal2str): Eliminate dead code and dead param.
16339 (pulongest): Drop dead param from call to decimal2str.
16342 2011-02-24 Joel Brobecker <brobecker@adacore.com>
16344 Revert the following patch (not approved yet):
16345 2011-02-21 Hui Zhu <teawater@gmail.com>
16346 * tracepoint.c (tp_printf): New function.
16347 (eval_agent_expr): Handle gdb_agent_op_printf.
16349 2011-02-21 Hui Zhu <teawater@gmail.com>
16351 * tracepoint.c (tp_printf): New function.
16352 (eval_agent_expr): Handle gdb_agent_op_printf.
16354 2011-02-18 Tom Tromey <tromey@redhat.com>
16356 * Makefile.in (tracepoint-ipa.o): Depend on ax.def.
16357 (tracepoint.o): Likewise.
16358 * tracepoint.c (enum gdb_agent_op): Use ax.def.
16359 (gdb_agent_op_names): Likewise.
16361 2011-02-18 Tom Tromey <tromey@redhat.com>
16363 * tracepoint.c (enum gdb_agent_op) <gdb_agent_op_pick,
16364 gdb_agent_op_rot>: New constants.
16365 (gdb_agent_op_names): Add pick and roll.
16366 (eval_agent_expr) <gdb_agent_op_pick, gdb_agent_op_rot>: New
16369 2011-02-15 Jan Kratochvil <jan.kratochvil@redhat.com>
16371 * aclocal.m4: Regenerated with aclocal-1.11.1.
16373 2011-02-14 Pedro Alves <pedro@codesourcery.com>
16375 * server.c (handle_qxfer_traceframe_info): New.
16376 (qxfer_packets): Register "traceframe-info".
16377 (handle_query): Report support for qXfer:traceframe-info:read+.
16378 * tracepoint.c (match_blocktype): New.
16379 (traceframe_find_block_type): Rename to ...
16380 (traceframe_walk_blocks): ... this. Add callback filter argument,
16382 (traceframe_find_block_type): New, reimplemented on top of
16383 traceframe_walk_blocks.
16384 (build_traceframe_info_xml): New.
16385 (traceframe_read_info): New.
16386 * server.h (traceframe_read_info): Declare.
16388 2011-02-11 Yao Qi <yao@codesourcery.com>
16390 * configure.ac: Call AC_PROG_RANLIB.
16391 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
16392 * configure: Regenerate.
16394 2011-02-07 Pedro Alves <pedro@codesourcery.com>
16396 * server.c (gdb_read_memory): Change return semantics to allow
16398 (handle_search_memory_1): Adjust.
16399 (process_serial_event) <'m' packet>: Handle partial transfers.
16400 * tracepoint.c (traceframe_read_mem): Handle partial transfers.
16402 2011-01-28 Pedro Alves <pedro@codesourcery.com>
16404 * regcache.c (init_register_cache): Initialize
16405 regcache->register_status.
16406 (free_register_cache): Release regcache->register_status.
16407 (regcache_cpy): Copy register_status.
16408 (registers_to_string): Print 'x's for unavailable registers.
16409 (supply_register): Mark the register's status valid or
16410 unavailable, depending on whether a buffer was passed in or not.
16411 (supply_register_zeroed): New.
16412 (supply_regblock): Mark the registers' status valid or
16413 unavailable, depending on whether a buffer was passed in or not.
16414 * regcache.h (REG_UNAVAILABLE, REG_VALID): New defines.
16415 (struct regcache): New `register_status' field.
16416 (supply_register_zeroed): Declare.
16417 * i387-fp.c (i387_xsave_to_cache): Zero out registers using
16418 supply_register_zeroed, rather than passing a NULL buffer to
16420 * tracepoint.c (fetch_traceframe_registers): Update comment.
16422 2011-01-28 Pedro Alves <pedro@codesourcery.com>
16424 * i387-fp.c (i387_xsave_to_cache): Make passing NULL as register
16427 2011-01-25 Pedro Alves <pedro@codesourcery.com>
16429 * server.h (decode_xfer_write): Change prototype.
16430 * remote-utils.c (decode_xfer_write): Remove `annex' parameter,
16431 and don't extract the annex here.
16432 * server.c (decode_xfer_read): Remove `annex' parameter,
16433 and don't extract the annex here.
16434 (decode_xfer): New.
16435 (struct qxfer): New.
16436 (handle_qxfer_auxv, handle_qxfer_features, handle_qxfer_libraries)
16437 (handle_qxfer_osdata, handle_qxfer_siginfo, handle_qxfer_spu)
16438 (handle_qxfer_statictrace): New functions, abstracted out from
16439 handle_query, and made to use the struct qxfer interface.
16440 (handle_threads_qxfer_proper): Rename to ...
16441 (handle_qxfer_threads_proper): ... this.
16442 (handle_threads_qxfer): Rename to ...
16443 (handle_qxfer_threads): ... this. Adjust.
16444 (qxfer_packets): New array.
16445 (handle_qxfer): New function.
16446 (handle_query): Use handle_qxfer.
16448 2011-01-05 Michael Snyder <msnyder@msnyder-server.eng.vmware.com>
16450 * gdbreplay.c: Shorten lines of >= 80 columns.
16451 * linux-low.c: Ditto.
16452 * linux-ppc-low.c: Ditto.
16453 * linux-s390-low.c: Ditto.
16454 * linux-sparc-low.c: Ditto.
16455 * linux-x86-low.c: Ditto.
16456 * linux-xtensa-low.c: Ditto.
16457 * mem-break.c: Ditto.
16458 * nto-low.c: Ditto.
16459 * regcache.h: Ditto.
16460 * remote-utils.c: Ditto.
16463 * thread-db.c: Ditto.
16464 * tracepoint.c: Ditto.
16466 * win32-low.h: Ditto.
16468 2011-01-05 Joel Brobecker <brobecker@adacore.com>
16470 * gdbserver/configure.ac, gdbserver/gdbserver.1: Copyright year
16473 2011-01-01 Joel Brobecker <brobecker@adacore.com>
16475 * server.c (gdbserver_version): Update copyright year in version
16477 * gdbreplay.c (gdbreplay_version): Ditto.
16479 2010-12-29 Jie Zhang <jie.zhang@analog.com>
16481 * configure.srv (bfin-*-*linux*): Handle Blackfin/Linux targets.
16482 * linux-bfin-low.c: New file.
16483 * linux-low.c: Define PT_TEXT_ADDR, PT_TEXT_END_ADDR, and
16484 PT_DATA_ADDR for BFIN targets.
16485 * Makefile.in (SFILES): Add linux-bfin-low.c.
16486 (clean): Remove reg-bfin.c.
16487 (linux-bfin-low.o, reg-bfin.o, reg-bfin.c): New targets.
16488 * README: Mention supported Blackfin targets.
16490 2010-12-23 Mike Frysinger <vapier@gentoo.org>
16492 * .gitignore: New file.
16494 2010-11-16 Mike Frysinger <vapier@gentoo.org>
16496 * linux-low.c (linux_tracefork_child): Add char* cast to arg.
16498 2010-10-22 Jie Zhang <jie@codesourcery.com>
16500 * Makefile.in: Add FLAGS_TO_PASS variable.
16501 (install): Remove dependency of install-only and recursively
16502 invoke make for install-only.
16504 2010-10-04 Doug Evans <dje@google.com>
16506 * Makefile.in (uninstall): Use $(DESTDIR).
16508 2010-09-24 Pedro Alves <pedro@codesourcery.com>
16512 * linux-x86-low.c (compat_siginfo_from_siginfo)
16513 (siginfo_from_compat_siginfo): Also copy si_pid and si_uid when
16514 si_code is < 0. Check for si_code == SI_TIMER before checking for
16517 2010-09-13 Joel Brobecker <brobecker@adacore.com>
16519 * lynx-i386-low.c: New file.
16520 * configure.srv: Add handling of i[34567]86-*-lynxos* targets.
16522 2010-09-13 Joel Brobecker <brobecker@adacore.com>
16524 * lynx-low.c (ptrace_request_to_str): Remove handling for
16525 request values that have been removed in LynxOS 5.x.
16527 2010-09-13 Joel Brobecker <brobecker@adacore.com>
16529 * lynx-low.c, lynx-ppc-loc.c: Include <sys/ptrace.h> instead of
16532 2010-09-09 Nathan Sidwell <nathan@codesourcery.com>
16534 * configure.ac: Add --enable-inprocess-agent option.
16535 * configure: Rebuilt.
16537 2010-09-06 Yao Qi <yao@codesourcery.com>
16539 * linux-low.c (linux_kill): Remove unused variable.
16540 (linux_stabilize_threads): Likewise.
16541 * server.c (start_inferior): Likewise.
16542 (queue_stop_reply_callback): Likewise.
16543 * tracepoint.c (do_action_at_tracepoint): Likewise.
16545 2010-09-06 Yao Qi <yao@codesourcery.com>
16547 * linux-low.c (maybe_move_out_of_jump_pad): Restore current_inferior
16550 2010-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
16552 * target.c (mywait) <TARGET_WAITKIND_EXITED>: Fix to use INTEGER.
16554 2010-09-06 Pedro Alves <pedro@codesourcery.com>
16556 * Makefile.in (install-only): Replace $IPA_DEPFILES with
16559 2010-09-01 Joel Brobecker <brobecker@adacore.com>
16561 * gdbserver/lynx-low.c, gdbserver/lynx-low.h,
16562 gdbserver/lynx-ppc-low.c: New files.
16563 * Makefile.in (lynx_low_h): New variable.
16564 (lynx-low.o, lynx-ppc-low.o): New rules.
16565 * configure.ac: On LynxOS, link with -lnetinet.
16566 * configure.srv: Add handling of powerpc-*-lynxos* targets.
16567 * configure: regenerate.
16569 2010-09-01 Joel Brobecker <brobecker@adacore.com>
16571 * Makefile.in (vasprintf.o, vsnprintf.o): New rules.
16572 * configure.ac: Add check for vasprintf and vsnprintf.
16573 * configure, config.in: Regenerate.
16574 * server.h (vasprintf, vsnprintf): Add conditional declarations.
16576 2010-09-01 Joel Brobecker <brobecker@adacore.com>
16578 * gdbreplay.c: Move include of alloca.h up, next to include of
16580 * server.h: Add include of malloc.h.
16581 * mem-break.c: Remove include of malloc.h.
16582 * server.c, tracepoint.c, utils.c, win32-low.c: Likewise.
16584 2010-09-01 Joel Brobecker <brobecker@adacore.com>
16586 * Makefile.in (memmem.o): Build with -Wno-error.
16588 2010-09-01 Joel Brobecker <brobecker@adacore.com>
16590 * utils.c (xsnprintf): Make non-static.
16591 * server.h: Add xsnprintf declaration.
16592 * linux-low.c, nto-low.c, target.c, thread-db.c, tracepoint.c:
16593 replace calls to snprintf by calls to xsnprintf throughout.
16595 2010-09-01 Joel Brobecker <brobecker@adacore.com>
16597 * configure.ac: Add configure check for alloca.
16598 * configure, config.in: Regenerate.
16599 * server.h: Include alloca.h if it exists.
16600 * gdbreplay.c: Include alloca.h if it exists.
16602 2010-08-28 Pedro Alves <pedro@codesourcery.com>
16604 * linux-low.c (__SIGRTMIN): Define if not already defined.
16605 (linux_create_inferior): Check for __ANDROID__ rather than
16607 (enqueue_one_deferred_signal): Don't requeue non-RT signals that
16608 are already deferred.
16609 (linux_wait_1): Check for __ANDROID__ rather than __SIGRTMIN.
16610 (linux_resume_one_thread): Don't queue a SIGSTOP if the lwp is
16611 stopped and already has a pending signal to report.
16612 (proceed_one_lwp): : Don't queue a SIGSTOP if the lwp already has
16613 a pending signal to report or is moving out of a jump pad.
16614 (linux_init_signals): Check for __ANDROID__ rather than
16617 2010-08-28 Pedro Alves <pedro@codesourcery.com>
16619 * linux-low.c (linux_stabilize_threads): Wrap debug output in a
16620 debug_threads check. Avoid a linear search when not doing debug
16623 2010-08-27 Pedro Alves <pedro@codesourcery.com>
16625 * event-loop.c (event_handle_func): Adjust to use gdb_fildes_t.
16626 (struct gdb_event) <fd>: Change type to gdb_fildes_t.
16627 (struct file_handler) <fd>: Change type to gdb_fildes_t.
16628 (process_event): Change local fd's type to gdb_fildes_t.
16629 (create_file_handler): Adjust prototype.
16630 (delete_file_handler): Adjust prototype.
16631 (handle_file_event): Adjust prototype. Use pfildes.
16632 (create_file_event): Adjsut prototype.
16633 * remote-utils.c (remote_desc, listen_desc): Change type to
16635 * server.h: New gdb_fildes_t typedef.
16636 [USE_WIN32API]: Include winsock2.h.
16637 (delete_file_handler, add_file_handler): Adjust prototypes.
16638 (pfildes): Declare.
16639 * utils.c (pfildes): New.
16641 2010-08-27 Pedro Alves <pedro@codesourcery.com>
16643 * configure.ac (build_warnings): Add -Wno-char-subscripts.
16644 * configure: Regenerate.
16646 2010-08-27 Pedro Alves <pedro@codesourcery.com>
16648 * linux-low.c (linux_unprepare_to_access_memory): Rename to ...
16649 (linux_done_accessing_memory): ... this.
16650 (linux_target_ops): Adjust.
16651 * linux-x86-low.c (x86_insert_point, x86_remove_point): Adjust.
16652 * nto-low.c (nto_target_ops): Adjust comment.
16653 * server.c (gdb_read_memory, gdb_write_memory): Adjust.
16654 * spu-low.c (spu_target_ops): Adjust comment.
16655 * target.h (target_ops): Rename unprepare_to_access_memory field
16656 to done_accessing_memory.
16657 (unprepare_to_access_memory): Rename to ...
16658 (done_accessing_memory): ... this.
16660 2010-08-26 Pedro Alves <pedro@codesourcery.com>
16662 * linux-low.c (linux_prepare_to_access_memory): New.
16663 (linux_unprepare_to_access_memory): New.
16664 (linux_target_ops): Install them.
16665 * server.c (read_memory): Rename to ...
16666 (gdb_read_memory): ... this. Use
16667 prepare_to_access_memory/prepare_to_access_memory.
16668 (write_memory): Rename to ...
16669 (gdb_write_memory): ... this. Use
16670 prepare_to_access_memory/prepare_to_access_memory.
16671 (handle_search_memory_1): Adjust.
16672 (process_serial_event): Adjust.
16673 * target.h (struct target_ops): New fields
16674 prepare_to_access_memory and unprepare_to_access_memory.
16675 (prepare_to_access_memory, unprepare_to_access_memory): New.
16676 * linux-x86-low.c (x86_insert_point, x86_remove_point): Use
16677 prepare_to_access_memory/prepare_to_access_memory.
16678 * nto-low.c (nto_target_ops): Adjust.
16679 * spu-low.c (spu_target_ops): Adjust.
16680 * win32-low.c (win32_target_ops): Adjust.
16682 2010-08-26 Pedro Alves <pedro@codesourcery.com>
16684 * Makefile.in (WARN_CFLAGS): Get it from configure.
16685 (WERROR_CFLAGS): New.
16686 (INTERNAL_CFLAGS): Add WERROR_CFLAGS.
16687 * configure.ac: Introduce --enable-werror, which adds -Werror to
16688 the compiler command line. Enabled by default. Disable with
16689 --disable-werror. Add -Wdeclaration-after-statement
16690 Wpointer-arith and -Wformat-nonliteral to warning flags.
16691 * configure: Regenerate.
16693 2010-08-26 Pedro Alves <pedro@codesourcery.com>
16695 * mem-break.c [HAVE_MALLOC_H]: Include malloc.h.
16697 2010-08-26 Pedro Alves <pedro@codesourcery.com>
16699 * gdbreplay.c (remote_error): New.
16701 (expect): Use gdbchar. Check for error reading from GDB.
16702 Clarify sync error output.
16703 (play): Check for errors writing to GDB.
16704 * linux-low.c (sigchld_handler): Really ignore `write' errors.
16705 * remote-utils.c (getpkt): Check for errors writing to the remote
16708 2010-08-25 Pedro Alves <pedro@codesourcery.com>
16710 * linux-low.c (linux_wait_1): Move non-debugging code out of
16711 `debug_threads' control.
16713 2010-08-25 Pedro Alves <pedro@codesourcery.com>
16715 * linux-low.c (linux_wait_1): Don't set last_status here.
16716 * server.c (push_event, queue_stop_reply_callback): Assert we're
16717 not pushing a TARGET_WAITKIND_IGNORE event.
16718 (start_inferior, start_inferior, attach_inferior, handle_v_cont)
16719 (myresume, handle_target_event): Set the thread's last_resume_kind
16720 and last_status from the target returned status.
16722 2010-08-25 Pedro Alves <pedro@codesourcery.com>
16726 * linux-x86-low.c (update_debug_registers_callback): New.
16727 (i386_dr_low_set_addr): Use it.
16728 (i386_dr_low_get_addr): New.
16729 (i386_dr_low_set_control): Use update_debug_registers_callback.
16730 (i386_dr_low_get_control): New.
16731 (i386_dr_low_get_status): Adjust.
16732 * linux-low.c (linux_stop_lwp): New.
16733 * linux-low.h (linux_stop_lwp): Declare.
16735 * i386-low.c (I386_DR_GET_RW_LEN): Take the dr7 contents as
16736 argument instead of a i386_debug_reg_state.
16737 (I386_DR_WATCH_HIT): Take the dr6 contents as argument instead of
16738 a i386_debug_reg_state.
16739 (i386_insert_aligned_watchpoint): Adjust.
16740 (i386_remove_aligned_watchpoint): Adjust.
16741 (i386_low_stopped_data_address): Read the debug registers from the
16742 inferior instead of from the mirrors.
16743 * i386-low.h (struct i386_debug_reg_state): Extend comment.
16744 (i386_dr_low_get_addr): Declare.
16745 (i386_dr_low_get_control): Declare.
16746 (i386_dr_low_get_status): Change prototype.
16748 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): New globals.
16749 (i386_dr_low_get_addr): New.
16750 (i386_dr_low_get_control): New.
16751 (i386_dr_low_get_status): Adjust prototype. Return
16753 (i386_initial_stuff): Clear dr_status_mirror and
16755 (i386_get_thread_context): Adjust.
16756 (i386_set_thread_context): Adjust.
16757 (i386_thread_added): Adjust.
16759 2010-08-24 Pedro Alves <pedro@codesourcery.com>
16761 * linux-low.h (linux_thread_area): Delete declaration.
16763 2010-08-11 Thomas Schwinge <thomas@codesourcery.com>
16765 * linux-low.c (linux_wait_1): Correctly return the ptid of the child
16766 after its termination.
16768 2010-08-09 Pedro Alves <pedro@codesourcery.com>
16770 * linux-low.c (gdb_wants_lwp_stopped): Delete.
16771 (gdb_wants_all_stopped): Delete.
16772 (linux_wait_1): Don't call them.
16773 * server.c (handle_v_cont): Tag all threads as want-stopped.
16774 (gdb_wants_thread_stopped): Fix comments. Tag the thread that
16775 stopped as "client-wants-stopped".
16777 2010-07-31 Pedro Alves <pedro@codesourcery.com>
16779 * Makefile.in (signals_h): New.
16780 (server_h): Depend on it.
16781 (server.o): Don't depend on $(signals_def).
16782 (signals.o): Depend on $(signals_def).
16784 2010-07-31 Jan Kratochvil <jan.kratochvil@redhat.com>
16786 * Makefile.in (signals_def): New.
16787 (server_h): Append include/gdb/signals.h and signals_def.
16788 (server.o): Append signals_def.
16790 2010-07-25 Jan Kratochvil <jan.kratochvil@redhat.com>
16792 * server.c (handle_target_event): Use target_signal_to_host for
16793 resume_info.sig initialization.
16794 * target.h (struct thread_resume) <sig>: New comment.
16796 2010-07-20 Ozkan Sezer <sezeroz@gmail.com>
16798 * server.c (handle_query): strcpy() the returned string from paddress()
16799 instead of sprintf().
16800 * utils.c (paddress): Return phex_nz().
16802 2010-07-07 Joel Brobecker <brobecker@adacore.com>
16804 * server.c (handle_v_cont): Call mourn_inferior if process
16806 (myresume): Likewise.
16808 2010-07-01 Pedro Alves <pedro@codesourcery.com>
16810 Static tracepoints, and integration with UST.
16812 * configure.ac: Handle --with-ust. substitute ustlibs and ustinc.
16813 * mem-break.c (uninsert_all_breakpoints)
16814 (reinsert_all_breakpoints): New.
16815 * mem-break.h (reinsert_all_breakpoints, uninsert_all_breakpoints):
16816 * tracepoint.c (ust_loaded, helper_thread_id, cmd_buf): New.
16817 (gdb_agent_ust_loaded, helper_thread_id)
16818 (gdb_agent_helper_thread_id): New macros.
16819 (struct ipa_sym_addresses): Add addr_ust_loaded,
16820 addr_helper_thread_id, addr_cmd_buf.
16821 (symbol_list): Add ust_loaded, helper_thread_id, cmd_buf.
16822 (in_process_agent_loaded_ust): New.
16823 (write_e_ust_not_loaded): New.
16824 (maybe_write_ipa_ust_not_loaded): New.
16825 (struct collect_static_trace_data_action): New.
16826 (enum tracepoint_type) <static_tracepoint>: New.
16827 (struct tracepoint) <handle>: Mention static tracepoints.
16828 (struct static_tracepoint_ctx): New.
16829 (CMD_BUF_SIZE): New.
16830 (add_tracepoint_action): Handle static tracepoint actions.
16831 (unprobe_marker_at): New.
16832 (clear_installed_tracepoints): Handle static tracepoints.
16833 (cmd_qtdp): Handle static tracepoints.
16834 (probe_marker_at): New.
16835 (cmd_qtstart): Handle static tracepoints.
16836 (response_tracepoint): Handle static tracepoints.
16837 (cmd_qtfstm, cmd_qtsstm, cmd_qtstmat): New.
16838 (handle_tracepoint_query): Handle qTfSTM, qTsSTM and qTSTMat.
16839 (get_context_regcache): Handle static tracepoints.
16840 (do_action_at_tracepoint): Handle static tracepoint actions.
16841 (traceframe_find_block_type): Handle static trace data blocks.
16842 (traceframe_read_sdata): New.
16843 (download_tracepoints): Download static tracepoint actions.
16844 [HAVE_UST] Include ust/ust.h, dlfcn.h, sys/socket.h, and sys/un.h.
16845 (GDB_PROBE_NAME): New.
16847 (GET_UST_SYM): New.
16850 (ust_marker_to_static_tracepoint): New.
16852 (collect_ust_data_at_tracepoint): New.
16853 (gdb_ust_probe): New.
16854 (UNIX_PATH_MAX, SOCK_DIR): New.
16855 (gdb_ust_connect_sync_socket): New.
16856 (resume_thread, stop_thread): New.
16857 (run_inferior_command): New.
16858 (init_named_socket): New.
16859 (gdb_ust_socket_init): New.
16860 (cstr_to_hexstr): New.
16862 (first_marker, next_marker): New.
16863 (response_ust_marker): New.
16864 (cmd_qtfstm, cmd_qtsstm): New.
16865 (unprobe_marker_at, probe_marker_at): New.
16866 (cmd_qtstmat, gdb_ust_thread): New.
16867 (gdb_ust_init): New.
16868 (initialize_tracepoint_ftlib): Call gdb_ust_init.
16869 * linux-amd64-ipa.c [HAVE_UST]: Include ust/processor.h
16870 (ST_REGENTRY): New.
16871 (x86_64_st_collect_regmap): New.
16872 (X86_64_NUM_ST_COLLECT_GREGS): New.
16873 (AMD64_RIP_REGNUM): New.
16874 (supply_static_tracepoint_registers): New.
16875 * linux-i386-ipa.c [HAVE_UST]: Include ust/processor.h
16876 (ST_REGENTRY): New.
16877 (i386_st_collect_regmap): New.
16878 (i386_NUM_ST_COLLECT_GREGS): New.
16879 (supply_static_tracepoint_registers): New.
16880 * server.c (handle_query): Handle qXfer:statictrace:read.
16881 <qSupported>: Report support for StaticTracepoints, and
16882 qXfer:statictrace:read features.
16883 * server.h (traceframe_read_sdata)
16884 (supply_static_tracepoint_registers): Declare.
16885 * remote-utils.c (convert_int_to_ascii, hexchars, ishex, tohex)
16886 (unpack_varlen_hex): Include in IPA build.
16887 * Makefile.in (ustlibs, ustinc): New.
16888 (IPA_OBJS): Add remote-utils-ipa.o.
16889 ($(IPA_LIB)): Link -ldl and -lpthread.
16891 (IPAGENT_CFLAGS): Add UST_CFLAGS.
16892 * config.in, configure: Regenerate.
16894 2010-06-20 Ian Lance Taylor <iant@google.com>
16895 Pedro Alves <pedro@codesourcery.com>
16897 * linux-x86-low.c (always_true): Delete.
16898 (EMIT_ASM, EMIT_ASM32): Use an uncondition asm jmp instead of
16899 trying to fool the compiler with always_true.
16901 2010-06-20 Pedro Alves <pedro@codesourcery.com>
16903 * tracepoint.c (condition_true_at_tracepoint): Don't run compiled
16904 conditions in gdbserver.
16906 2010-06-19 Ulrich Weigand <uweigand@de.ibm.com>
16908 * spu-low.c (spu_read_memory): Wrap around local store limit.
16909 (spu_write_memory): Likewise.
16911 2010-06-15 Pedro Alves <pedro@codesourcery.com>
16913 * linux-x86-low.c (amd64_emit_const, amd64_emit_void_call_2)
16914 (i386_emit_const, i386_emit_void_call_2): Replace int64_t uses with
16916 * server.h (struct emit_ops): Replace int64_t uses with LONGEST
16918 * tracepoint.c (emit_const, emit_void_call_2): Replace int64_t
16919 uses with LONGEST uses.
16921 2010-06-14 Stan Shebs <stan@codesourcery.com>
16922 Pedro Alves <pedro@codesourcery.com>
16926 * linux-x86-low.c: Include limits.h.
16928 (always_true): New.
16931 (amd64_emit_prologue, amd64_emit_epilogue, amd64_emit_add)
16932 (amd64_emit_sub, amd64_emit_mul, amd64_emit_lsh)
16933 (amd64_emit_rsh_signed, amd64_emit_rsh_unsigned, amd64_emit_ext,
16934 (amd64_emit_log_not, amd64_emit_bit_and, amd64_emit_bit_or)
16935 (amd64_emit_bit_xor, amd64_emit_bit_not, amd64_emit_equal,
16936 (amd64_emit_less_signed, amd64_emit_less_unsigned, amd64_emit_ref,
16937 (amd64_emit_if_goto, amd64_emit_goto, amd64_write_goto_address)
16938 (amd64_emit_const, amd64_emit_call, amd64_emit_reg)
16939 (amd64_emit_pop, amd64_emit_stack_flush, amd64_emit_zero_ext)
16940 (amd64_emit_swap, amd64_emit_stack_adjust, amd64_emit_int_call_1)
16941 (amd64_emit_void_call_2): New.
16942 (amd64_emit_ops): New.
16943 (i386_emit_prologue, i386_emit_epilogue, i386_emit_add)
16944 (i386_emit_sub,i386_emit_mul, i386_emit_lsh, i386_emit_rsh_signed)
16945 (i386_emit_rsh_unsigned, i386_emit_ext, i386_emit_log_not)
16946 (i386_emit_bit_and, i386_emit_bit_or, i386_emit_bit_xor)
16947 (i386_emit_bit_not, i386_emit_equal, i386_emit_less_signed)
16948 (i386_emit_less_unsigned, i386_emit_ref, i386_emit_if_goto)
16949 (i386_emit_goto, i386_write_goto_address, i386_emit_const)
16950 (i386_emit_call, i386_emit_reg, i386_emit_pop)
16951 (i386_emit_stack_flush, i386_emit_zero_ext, i386_emit_swap)
16952 (i386_emit_stack_adjust, i386_emit_int_call_1)
16953 (i386_emit_void_call_2): New.
16954 (i386_emit_ops): New.
16955 (x86_emit_ops): New.
16956 (the_low_target): Install x86_emit_ops.
16957 * server.h (struct emit_ops): New.
16958 (get_raw_reg_func_addr): Declare.
16959 (current_insn_ptr, emit_error): Declare.
16960 * tracepoint.c (get_raw_reg, get_trace_state_variable_value)
16961 (set_trace_state_variable_value): New defines.
16962 (struct ipa_sym_addresses): New fields addr_get_raw_reg,
16963 addr_get_trace_state_variable_value and
16964 addr_set_trace_state_variable_value.
16965 (symbol_list): New fields for get_raw_reg,
16966 get_trace_state_variable_value and set_trace_state_variable_value.
16967 (condfn): New typedef.
16968 (struct tracepoint): New field `compiled_cond'.
16969 (do_action_at_tracepoint): Clear compiled_cond.
16970 (get_trace_state_variable_value, set_trace_state_variable_value):
16972 (condition_true_at_tracepoint): If there's a compiled condition,
16974 (current_insn_ptr, emit_error): New globals.
16975 (struct bytecode_address): New.
16976 (get_raw_reg_func_addr): New.
16977 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul)
16978 (emit_lsh, emit_rsh_signed, emit_rsh_unsigned, emit_ext)
16979 (emit_log_not, emit_bit_and, emit_bit_or, emit_bit_xor)
16980 (emit_bit_not, emit_equal, emit_less_signed, emit_less_unsigned)
16981 (emit_ref, emit_if_goto, emit_goto, write_goto_address, emit_const)
16982 (emit_reg, emit_pop, emit_stack_flush, emit_zero_ext, emit_swap)
16983 (emit_stack_adjust, emit_int_call_1, emit_void_call_2): New.
16984 (compile_tracepoint_condition, compile_bytecodes): New.
16985 * target.h (emit_ops): Forward declare.
16986 (struct target_ops): New field emit_ops.
16987 (target_emit_ops): New.
16988 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): New.
16989 * linux-i386-ipa.c (gdb_agent_get_raw_reg): New.
16990 * linux-low.c (linux_emit_ops): New.
16991 (linux_target_ops): Install it.
16992 * linux-low.h (struct linux_target_ops): New field emit_ops.
16994 2010-06-14 Ulrich Weigand <uweigand@de.ibm.com>
16996 * linux-ppc-low.c (ppc_arch_setup): Use private regcache to test MSR.
16997 * linux-s390-low.c (ppc_arch_setup): Use private regcache to test PSW.
16999 2010-06-01 Pedro Alves <pedro@codesourcery.com>
17000 Stan Shebs <stan@codesourcery.com>
17002 * Makefile.in (IPA_DEPFILES, extra_libraries): New.
17003 (all): Depend on $(extra_libraries).
17004 (install-only): Install the IPA.
17005 (IPA_OBJS, IPA_LIB): New.
17006 (clean): Remove the IPA lib.
17007 (IPAGENT_CFLAGS): New.
17008 (tracepoint-ipa.o, utils-ipa.o, remote-utils-ipa.o)
17009 (regcache-ipa.o, i386-linux-ipa.o, linux-i386-ipa.o)
17010 (linux-amd64-ipa.o, amd64-linux-ipa.o): New rules.
17011 * linux-amd64-ipa.c, linux-i386-ipa.c: New files.
17012 * configure.ac: Check for atomic builtins support in the compiler.
17013 (IPA_DEPFILES, extra_libraries): Define.
17014 * configure.srv (ipa_obj): Add description.
17015 (ipa_i386_linux_regobj, ipa_amd64_linux_regobj): Define.
17016 (i[34567]86-*-linux*): Set ipa_obj.
17017 (x86_64-*-linux*): Set ipa_obj.
17018 * linux-low.c (stabilizing_threads): New.
17019 (supports_fast_tracepoints): New.
17020 (linux_detach): Stabilize threads before detaching.
17021 (handle_tracepoints): Handle internal tracing breakpoints. Assert
17022 the lwp is either not stabilizing, or is moving out of a jump pad.
17023 (linux_fast_tracepoint_collecting): New.
17024 (maybe_move_out_of_jump_pad): New.
17025 (enqueue_one_deferred_signal): New.
17026 (dequeue_one_deferred_signal): New.
17027 (linux_wait_for_event_1): If moving out of a jump pad, defer
17028 pending signals to later.
17029 (linux_stabilize_threads): New.
17030 (linux_wait_1): Check if threads need moving out of jump pads, and
17032 (stuck_in_jump_pad_callback): New.
17033 (move_out_of_jump_pad_callback): New.
17034 (lwp_running): New.
17035 (linux_resume_one_lwp): Handle moving out of jump pads.
17036 (linux_set_resume_request): Dequeue deferred signals.
17037 (need_step_over_p): Also step over fast tracepoint jumps.
17038 (start_step_over): Also uninsert fast tracepoint jumps.
17039 (finish_step_over): Also reinsert fast tracepoint jumps.
17040 (linux_install_fast_tracepoint_jump): New.
17041 (linux_target_ops): Install linux_stabilize_threads and
17042 linux_install_fast_tracepoint_jump_pad.
17043 * linux-low.h (linux_target_ops) <get_thread_area,
17044 install_fast_tracepoint_jump_pad>: New fields.
17045 (struct lwp_info) <collecting_fast_tracepoint,
17046 pending_signals_to_report, exit_jump_pad_bkpt>: New fields.
17047 (linux_get_thread_area): Declare.
17048 * linux-x86-low.c (jump_insn): New.
17049 (x86_get_thread_area): New.
17050 (append_insns): New.
17051 (push_opcode): New.
17052 (amd64_install_fast_tracepoint_jump_pad): New.
17053 (i386_install_fast_tracepoint_jump_pad): New.
17054 (x86_install_fast_tracepoint_jump_pad): New.
17055 (the_low_target): Install x86_get_thread_area and
17056 x86_install_fast_tracepoint_jump_pad.
17057 * mem-break.c (set_raw_breakpoint_at): Use read_inferior_memory.
17058 (struct fast_tracepoint_jump): New.
17059 (fast_tracepoint_jump_insn): New.
17060 (fast_tracepoint_jump_shadow): New.
17061 (find_fast_tracepoint_jump_at): New.
17062 (fast_tracepoint_jump_here): New.
17063 (delete_fast_tracepoint_jump): New.
17064 (set_fast_tracepoint_jump): New.
17065 (uninsert_fast_tracepoint_jumps_at): New.
17066 (reinsert_fast_tracepoint_jumps_at): New.
17067 (set_breakpoint_at): Use write_inferior_memory.
17068 (uninsert_raw_breakpoint): Use write_inferior_memory.
17069 (check_mem_read): Mask out fast tracepoint jumps.
17070 (check_mem_write): Mask out fast tracepoint jumps.
17071 * mem-break.h (struct fast_tracepoint_jump): Forward declare.
17072 (set_fast_tracepoint_jump): Declare.
17073 (delete_fast_tracepoint_jump)
17074 (fast_tracepoint_jump_here, uninsert_fast_tracepoint_jumps_at)
17075 (reinsert_fast_tracepoint_jumps_at): Declare.
17076 * regcache.c: Don't compile many functions when building the
17077 in-process agent library.
17078 (init_register_cache) [IN_PROCESS_AGENT]: Don't allow allocating
17079 the register buffer in the heap.
17080 (free_register_cache): If the register buffer isn't owned by the
17081 regcache, don't free it.
17082 (set_register_cache) [IN_PROCESS_AGENT]: Don't re-alocate
17083 pre-existing register caches.
17084 * remote-utils.c (convert_int_to_ascii): Constify `from' parameter
17086 (convert_ascii_to_int): : Constify `from' parameter type.
17087 (decode_M_packet, decode_X_packet): Replace the `to' parameter by
17088 a `to_p' pointer to pointer parameter. If TO_P is NULL, malloc
17089 the needed buffer in-place.
17090 (relocate_instruction): New.
17091 * server.c (handle_query) <qSymbols>: If the target supports
17092 tracepoints, give it a chance of looking up symbols. Report
17093 support for fast tracepoints.
17094 (handle_status): Stabilize threads.
17095 (process_serial_event): Adjust.
17096 * server.h (struct fast_tracepoint_jump): Forward declare.
17097 (struct process_info) <fast_tracepoint_jumps>: New field.
17098 (convert_ascii_to_int, convert_int_to_ascii): Adjust.
17099 (decode_X_packet, decode_M_packet): Adjust.
17100 (relocate_instruction): Declare.
17101 (in_process_agent_loaded): Declare.
17102 (tracepoint_look_up_symbols): Declare.
17103 (struct fast_tpoint_collect_status): Declare.
17104 (fast_tracepoint_collecting): Declare.
17105 (force_unlock_trace_buffer): Declare.
17106 (handle_tracepoint_bkpts): Declare.
17107 (initialize_low_tracepoint)
17108 (supply_fast_tracepoint_registers) [IN_PROCESS_AGENT]: Declare.
17109 * target.h (struct target_ops) <stabilize_threads,
17110 install_fast_tracepoint_jump_pad>: New fields.
17111 (stabilize_threads, install_fast_tracepoint_jump_pad): New.
17112 * tracepoint.c [HAVE_MALLOC_H]: Include malloc.h.
17113 [HAVE_STDINT_H]: Include stdint.h.
17114 (trace_debug_1): Rename to ...
17115 (trace_vdebug): ... this.
17116 (trace_debug): Rename to ...
17117 (trace_debug_1): ... this. Add `level' parameter.
17118 (trace_debug): New.
17119 (ATTR_USED, ATTR_NOINLINE): New.
17120 (IP_AGENT_EXPORT): New.
17121 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
17122 (collecting, gdb_collect, stop_tracing, flush_trace_buffer)
17123 (about_to_request_buffer_space, trace_buffer_is_full)
17124 (stopping_tracepoint, expr_eval_result, error_tracepoint)
17125 (tracepoints, tracing, trace_buffer_ctrl, trace_buffer_ctrl_curr)
17126 (trace_buffer_lo, trace_buffer_hi, traceframe_read_count)
17127 (traceframe_write_count, traceframes_created)
17128 (trace_state_variables)
17129 New renaming defines.
17130 (struct ipa_sym_addresses): New.
17131 (STRINGIZE_1, STRINGIZE, IPA_SYM): New.
17132 (symbol_list): New.
17133 (ipa_sym_addrs): New.
17134 (all_tracepoint_symbols_looked_up): New.
17135 (in_process_agent_loaded): New.
17136 (write_e_ipa_not_loaded): New.
17137 (maybe_write_ipa_not_loaded): New.
17138 (tracepoint_look_up_symbols): New.
17139 (debug_threads) [IN_PROCESS_AGENT]: New.
17140 (read_inferior_memory) [IN_PROCESS_AGENT]: New.
17141 (UNKNOWN_SIDE_EFFECTS): New.
17142 (stop_tracing): New.
17143 (flush_trace_buffer): New.
17144 (stop_tracing_bkpt): New.
17145 (flush_trace_buffer_bkpt): New.
17146 (read_inferior_integer): New.
17147 (read_inferior_uinteger): New.
17148 (read_inferior_data_pointer): New.
17149 (write_inferior_data_pointer): New.
17150 (write_inferior_integer): New.
17151 (write_inferior_uinteger): New.
17152 (struct collect_static_trace_data_action): Delete.
17153 (enum tracepoint_type): New.
17154 (struct tracepoint) <type>: New field `type'.
17155 <actions_str, step_actions, step_actions_str>: Only include in
17157 <orig_size, obj_addr_on_target, adjusted_insn_addr>
17158 <adjusted_insn_addr_end, jump_pad, jump_pad_end>: New fields.
17159 (tracepoints): Use IP_AGENT_EXPORT.
17160 (last_tracepoint): Don't include in the IPA.
17161 (stopping_tracepoint): Use IP_AGENT_EXPORT.
17162 (trace_buffer_is_full): Use IP_AGENT_EXPORT.
17163 (alloced_trace_state_variables): New.
17164 (trace_state_variables): Use IP_AGENT_EXPORT.
17165 (traceframe_t): Delete unused variable.
17166 (circular_trace_buffer): Don't include in the IPA.
17167 (trace_buffer_start): Delete.
17168 (struct trace_buffer_control): New.
17169 (trace_buffer_free): Delete.
17170 (struct ipa_trace_buffer_control): New.
17171 (GDBSERVER_FLUSH_COUNT_MASK, GDBSERVER_FLUSH_COUNT_MASK_PREV)
17172 (GDBSERVER_FLUSH_COUNT_MASK_CURR, GDBSERVER_UPDATED_FLUSH_COUNT_BIT):
17174 (trace_buffer_ctrl): New.
17175 (TRACE_BUFFER_CTRL_CURR): New.
17176 (trace_buffer_start, trace_buffer_free, trace_buffer_end_free):
17177 Reimplement as macros.
17178 (trace_buffer_wrap): Delete.
17179 (traceframe_write_count, traceframe_read_count)
17180 (traceframes_created, tracing): Use IP_AGENT_EXPORT.
17181 (struct tracepoint_hit_ctx) <type>: New field.
17182 (struct fast_tracepoint_ctx): New.
17183 (memory_barrier): New.
17185 (record_tracepoint_error): Update atomically in the IPA.
17186 (clear_inferior_trace_buffer): New.
17187 (about_to_request_buffer_space): New.
17188 (trace_buffer_alloc): Handle GDBserver and inferior simulatenous
17189 updating the same buffer.
17190 (add_tracepoint): Default the tracepoint's type to trap
17191 tracepoint, and orig_size to -1.
17192 (get_trace_state_variable) [IN_PROCESS_AGENT]: Handle allocated
17193 internal variables.
17194 (create_trace_state_variable): New parameter `gdb'. Handle it.
17195 (clear_installed_tracepoints): Clear fast tracepoint jumps.
17196 (cmd_qtdp): Handle fast tracepoints.
17197 (cmd_qtdv): Adjust.
17198 (max_jump_pad_size): New.
17199 (gdb_jump_pad_head): New.
17200 (get_jump_space_head): New.
17201 (claim_jump_space): New.
17202 (sort_tracepoints): New.
17203 (MAX_JUMP_SIZE): New.
17204 (cmd_qtstart): Handle fast tracepoints. Sync tracepoints with the
17206 (stop_tracing) [IN_PROCESS_AGENT]: Don't include the tdisconnected
17207 support. Upload fast traceframes, and delete internal IPA
17209 (stop_tracing_handler): New.
17210 (flush_trace_buffer_handler): New.
17211 (cmd_qtstop): Upload fast tracepoints.
17212 (response_tracepoint): Handle fast tracepoints.
17213 (tracepoint_finished_step): Upload fast traceframes. Set the
17214 tracepoint hit context's tracepoint type.
17215 (handle_tracepoint_bkpts): New.
17216 (tracepoint_was_hit): Set the tracepoint hit context's tracepoint
17217 type. Add comment about fast tracepoints.
17218 (collect_data_at_tracepoint) [IN_PROCESS_AGENT]: Don't access the
17219 non-existing action_str field.
17220 (get_context_regcache): Handle fast tracepoints.
17221 (do_action_at_tracepoint) [!IN_PROCESS_AGENT]: Don't write the PC
17223 (fast_tracepoint_from_jump_pad_address): New.
17224 (fast_tracepoint_from_ipa_tpoint_address): New.
17225 (collecting_t): New.
17226 (force_unlock_trace_buffer): New.
17227 (fast_tracepoint_collecting): New.
17229 (gdb_collect): New.
17230 (write_inferior_data_ptr): New.
17231 (target_tp_heap): New.
17232 (target_malloc): New.
17233 (download_agent_expr): New.
17235 (download_tracepoints): New.
17236 (download_trace_state_variables): New.
17237 (upload_fast_traceframes): New.
17238 (IPA_FIRST_TRACEFRAME): New.
17239 (IPA_NEXT_TRACEFRAME_1): New.
17240 (IPA_NEXT_TRACEFRAME): New.
17241 [IN_PROCESS_AGENT]: Include sys/mman.h and fcntl.h.
17242 [IN_PROCESS_AGENT] (gdb_tp_heap_buffer, gdb_jump_pad_buffer)
17243 (gdb_jump_pad_buffer_end): New.
17244 [IN_PROCESS_AGENT] (initialize_tracepoint_ftlib): New.
17245 (initialize_tracepoint): Adjust.
17246 [IN_PROCESS_AGENT]: Allocate the IPA heap, and jump pad scratch
17247 buffer. Initialize the low module.
17248 * utils.c (PREFIX, TOOLNAME): New.
17249 (malloc_failure): Use PREFIX.
17250 (error): In the IPA, an error causes an exit.
17251 (fatal, warning): Use PREFIX.
17252 (internal_error): Use TOOLNAME.
17253 (NUMCELLS): Increase to 10.
17254 * configure, config.in: Regenerate.
17256 2010-06-01 Pedro Alves <pedro@codesourcery.com>
17258 * server.c (handle_query) <qSupported>: Do two passes over the
17259 qSupported string to avoid nesting strtok.
17261 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
17263 * Makefile.in (SFILES): Add $(srcdir)/proc-service.list.
17265 * configure.ac (RDYNAMIC): New AC_MSG_CHECKING wrapping. Test also
17266 -Wl,--dynamic-list.
17267 * configure: Regenerate.
17268 * proc-service.list: New.
17270 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
17272 * linux-low.c (linux_core_of_thread): Fix crash on invalid CONTENT.
17275 2010-05-26 Ozkan Sezer <sezeroz@gmail.com>
17277 * gdbreplay.c (remote_open): Check error return from socket() call by
17278 its equality to -1 not by it being negative.
17279 * remote-utils.c (remote_open): Likewise.
17281 2010-05-23 Pedro Alves <pedro@codesourcery.com>
17283 * config.h: Regenerate.
17285 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
17287 * linux-m68k-low.c (ps_get_thread_area): Don't define if kernel
17288 doesn't provide PTRACE_GET_THREAD_AREA.
17290 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
17292 * linux-m68k-low.c: Include <asm/ptrace.h>
17293 (ps_get_thread_area): Implement.
17295 2010-05-03 Doug Evans <dje@google.com>
17297 * event-loop.c (struct callback_event): New struct.
17298 (callback_list): New global.
17299 (append_callback_event, delete_callback_event): New functions.
17300 (process_callback): New function.
17301 (start_event_loop): Call it.
17302 * remote-utils.c (NOT_SCHEDULED): Define.
17303 (readchar_buf, readchar_bufcnt, readchar_bufp): New static globals,
17304 moved out of readchar.
17305 (readchar): Rewrite. Call reschedule before returning.
17306 (reset_readchar): New function.
17307 (remote_close): Call it.
17308 (process_remaining, reschedule): New functions.
17309 * server.h (callback_handler_func): New typedef.
17310 (append_callback_event, delete_callback_event): Declare.
17312 2010-05-03 Pedro Alves <pedro@codesourcery.com>
17314 * proc-service.c (ps_pglobal_lookup): Use
17315 thread_db_look_up_one_symbol.
17316 * remote-utils.c (look_up_one_symbol): Add new `may_ask_gdb'
17317 parameter. Use it instead of all_symbols_looked_up.
17318 * server.h (struct process_info) <all_symbols_looked_up>: Delete
17320 (all_symbols_looked_up): Don't declare.
17321 (look_up_one_symbol): Add new `may_ask_gdb' parameter.
17322 * thread-db.c (struct thread_db) <all_symbols_looked_up>: New
17324 (thread_db_look_up_symbols): Adjust call to look_up_one_symbol.
17325 Set all_symbols_looked_up here.
17326 (thread_db_look_up_one_symbol): New.
17327 (thread_db_get_tls_address): Adjust.
17328 (thread_db_load_search, try_thread_db_load_1): Always allocate the
17329 thread_db object on the heap, and tentatively set it in the
17331 (thread_db_init): Don't set all_symbols_looked_up here.
17332 * linux-low.h (thread_db_look_up_one_symbol): Declare.
17334 2010-05-03 Pedro Alves <pedro@codesourcery.com>
17336 * linux-low.c (linux_kill, linux_detach): Adjust.
17337 (status_pending_p_callback): Remove redundant statement. Check
17338 for !TARGET_WAITIKIND_IGNORE, instead of
17339 TARGET_WAITKIND_STOPPED.
17340 (handle_tracepoints): Make sure LWP is locked. Adjust.
17341 (linux_wait_for_event_1): Adjust.
17342 (linux_cancel_breakpoints): New.
17343 (unsuspend_one_lwp): New.
17344 (unsuspend_all_lwps): New.
17345 (linux_wait_1): If finishing a step-over, unsuspend all lwps.
17346 (send_sigstop_callback): Change return type to int, add new
17347 `except' parameter and handle it.
17348 (suspend_and_send_sigstop_callback): New.
17349 (stop_all_lwps): Add new `suspend' and `expect' parameters, and
17350 pass them down. If SUSPEND, also increment the lwp's suspend
17352 (linux_resume_one_lwp): Add notice about resuming a suspended LWP.
17353 (need_step_over_p): Don't consider suspended LWPs.
17354 (start_step_over): Adjust.
17355 (proceed_one_lwp): Change return type to int, add new `except'
17356 parameter and handle it.
17357 (unsuspend_and_proceed_one_lwp): New.
17358 (proceed_all_lwps): Use find_inferior instead of
17360 (unstop_all_lwps): Add `unsuspend' parameter. If UNSUSPEND, them
17361 also decrement the suspend count of LWPs. Pass `except' down,
17362 instead of hacking its suspend count.
17363 (linux_pause_all): Add `freeze' parameter. Adjust.
17364 (linux_unpause_all): New.
17365 (linux_target_ops): Install linux_unpause_all.
17366 * server.c (handle_status): Adjust.
17367 * target.h (struct target_ops): New fields `unpause_all' and
17368 `cancel_breakpoints'. Add new parameter to `pause_all'.
17369 (pause_all): Add new `freeze' parameter.
17370 (unpause_all): New.
17371 (cancel_breakpoints): New.
17372 * tracepoint.c (clear_installed_tracepoints): Pause threads, and
17373 cancel breakpoints.
17374 (cmd_qtstart): Pause threads.
17375 (stop_tracing): Pause threads, and cancel breakpoints.
17376 * win32-low.c (win32_target_ops): Adjust.
17378 2010-05-03 Pedro Alves <pedro@codesourcery.com>
17380 * linux-low.c (linux_wait_for_event_1): Move passing the signal to
17381 the inferior right away from here...
17382 (linux_wait_1): ... to here, and adjust to check the thread's
17383 last_resume_kind instead of the lwp's step or stop_expected flags.
17385 2010-05-02 Pedro Alves <pedro@codesourcery.com>
17387 * README: Use consistent `GDB' and `GDBserver' spellings.
17389 2010-05-02 Pedro Alves <pedro@codesourcery.com>
17391 * linux-low.c (linux_kill_one_lwp): Assume the lwp is stopped.
17392 (linux_kill): Stop all lwps here. Don't delete the main lwp here.
17393 (linux_detach_one_lwp): Assume the lwp is stopped.
17394 (any_thread_of): Delete.
17395 (linux_detach): Stop all lwps here. Don't blindly delete all
17397 (delete_lwp_callback): New.
17398 (linux_mourn): Delete all lwps of the process that is gone.
17399 (linux_wait_1): Don't delete the last lwp of the process here.
17400 * mem-break.h (mark_breakpoints_out): Declare.
17401 * mem-break.c (mark_breakpoints_out): New.
17402 (free_all_breakpoints): Use it.
17403 * server.c (handle_target_event): If the process is gone, mark
17405 * thread-db.c (struct thread_db) <create_bp>: New field.
17406 (thread_db_enable_reporting): Fix prototype. Store a thread event
17407 breakpoint reference in the thread_db struct.
17408 (thread_db_load_search): Clear the thread_db object.
17409 (try_thread_db_load_1): Ditto.
17410 (switch_to_process): New.
17411 (disable_thread_event_reporting): Use it.
17412 (remove_thread_event_breakpoints): New.
17413 (thread_db_detach, thread_db_mourn): Use it.
17415 2010-05-01 Pedro Alves <pedro@codesourcery.com>
17417 * linux-low.c (linux_enable_event_reporting): New.
17418 (linux_wait_for_event_1, handle_extended_wait): Use it.
17420 2010-04-30 Pedro Alves <pedro@codesourcery.com>
17422 * linux-low.c (linux_kill_one_lwp, linux_kill)
17423 (linux_detach_one_lwp): Adjust to send_sigstop interface change.
17424 (send_sigstop): Take an lwp_info as parameter instead. Queue a
17425 SIGSTOP even if the LWP is stopped.
17426 (send_sigstop_callback): New.
17427 (stop_all_lwps): Use send_sigstop_callback instead.
17428 (linux_resume_one_thread): Adjust.
17429 (proceed_one_lwp): Still proceed an LWP that the client has
17430 requested to stop, if we haven't reported it as stopped yet. Make
17431 sure that LWPs the client want stopped, have a pending SIGSTOP.
17433 2010-04-26 Doug Evans <dje@google.com>
17435 * server.c (handle_general_set): Make static.
17437 * remote-utils.c (putpkt_binary_1): Call readchar instead of read.
17438 Print received char after testing for error/eof instead of before.
17439 (input_interrupt): Tweak comment.
17441 2010-04-23 Doug Evans <dje@google.com>
17443 * server.c (start_inferior): Print inferior argv if --debug.
17445 2010-04-21 Aleksandar Ristovski <aristovski@qnx.com>
17447 * Makefile.in (nto_low_h nto-low.o nto-x86-low.o): New dependency lists.
17448 * nto-x86-low.c: Include server.h
17450 2010-04-20 Pierre Muller <muller@ics.u-strasbg.fr>
17452 * win32-i386-low.c: Use __x86_64__ macro instead of __x86_64 to
17453 be consistent with other sources of this directory.
17454 (init_registers_amd64): Correct name of source file of this function
17457 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
17459 * configure.srv (x86_64-*-mingw*): New configuration for Windows
17460 64-bit executables.
17462 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
17464 * win32-i386-low.c: Add 64-bit support.
17465 (CONTEXT_EXTENDED_REGISTERS): Set macro to zero if not exisiting.
17466 (init_registers_amd64): Declare.
17467 (mappings): Add 64-bit version of array.
17468 (init_windows_x86): New function.
17469 (the_low_target): Change init_arch field to init_windows_x86.
17471 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
17473 * win32-low.c: Adapt to support also 64-bit architecture.
17474 (child_xfer_memory): Use uintptr_t type for local variable `addr'.
17475 (get_image_name): Use SIZE_T type for local variable `done'.
17476 (psapi_get_dll_name): Use LPVOID type for parameter `BaseAddress'.
17477 (toolhelp_get_dll_name): Idem.
17478 (handle_load_dll): Use CORE_ADDR type for local variable `load_addr'.
17479 Use uintptr_t typecast to avoid warning.
17480 (handle_unload_dll): Use uintptr_t typecast to avoid warning.
17481 (handle_exception): Use phex_nz to avoid warning.
17482 (win32_wait): Remove unused local variable `process'.
17484 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
17486 * configure.srv (srv_amd64_regobj): Replace `x86-64-avx.o' by
17489 2010-04-17 Pierre Muller <muller@ics.u-strasbg.fr>
17491 * configure.ac: Use `ws2_32' library for srv_mingw.
17492 * configure: Regenerate.
17493 * gdbreplay.c: Include winsock2.h instead of winsock.h.
17494 * remote-utils.c: Likewise.
17496 2010-04-17 H.J. Lu <hongjiu.lu@intel.com>
17498 * linux-x86-low.c (xmltarget_amd64_linux_no_xml): Define only
17499 if __x86_64__ is defined.
17501 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
17503 * configure: Regenerate.
17505 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
17507 * server.c (handle_query): Handle 'qGetTIBAddr' query.
17508 * target.h (target_ops): New get_tib_address field.
17509 * win32-low.h (win32_thread_info): Add thread_local_base field.
17510 * win32-low.c (child_add_thread): Add tlb argument.
17511 Set thread_local_base field to TLB.
17512 (get_child_debug_event): Adapt to child_add_thread change.
17513 (win32_get_tib_address): New function.
17514 (win32_target_ops): Set get_tib_address field to
17515 win32_get_tib_address.
17516 * linux-low.c (linux_target_ops): Set get_tib_address field to NULL.
17518 2010-04-12 Pedro Alves <pedro@codesourcery.com>
17520 * linux-low.c (linux_mourn): Also remove the process.
17521 * server.c (handle_target_event): Don't remove the process here.
17522 * nto-low.c (nto_mourn): New.
17523 (nto_target_ops): Install it.
17524 * spu-low.c (spu_mourn): New.
17525 (spu_target_ops): Install it.
17526 * win32-low.c (win32_mourn): New.
17527 (win32_target_ops): Install it.
17529 2010-04-12 Pedro Alves <pedro@codesourcery.com>
17531 * server.h (buffer_xml_printf): Remove redundant `;'.
17533 2010-04-12 Pedro Alves <pedro@codesourcery.com>
17535 * regcache.c (set_register_cache): Invalidate regcaches before
17536 changing the register cache layout.
17537 (regcache_invalidate_one): Allow a NULL regcache.
17538 * linux-x86-low.c (x86_linux_update_xmltarget): Invalidate
17539 regcaches before changing the register cache layout or the target
17542 2010-04-12 H.J. Lu <hongjiu.lu@intel.com>
17544 * linux-x86-low.c (x86_linux_update_xmltarget): Avoid unused
17545 variable warning on Linux/x86-64.
17547 2010-04-11 Pedro Alves <pedro@codesourcery.com>
17549 GDBserver disconnected tracing support.
17551 * linux-low.c (linux_remove_process): Delete.
17552 (add_lwp): Don't set last_resume_kind here.
17553 (linux_kill): Use `mourn'.
17554 (linux_detach): Use `thread_db_detach', and `mourn'.
17555 (linux_mourn): New.
17556 (linux_attach_lwp_1): Adjust comment.
17557 (linux_attach): last_resume_kind moved the thread_info; adjust.
17558 (status_pending_p_callback): Adjust.
17559 (linux_wait_for_event_1): Adjust.
17560 (count_events_callback, select_singlestep_lwp_callback)
17561 (select_event_lwp_callback, cancel_breakpoints_callback)
17562 (db_wants_lwp_stopped, linux_wait_1, need_step_over_p)
17563 (proceed_one_lwp): Adjust.
17564 (linux_async): Add debug output.
17565 (linux_thread_stopped): New.
17566 (linux_pause_all): New.
17567 (linux_target_ops): Install linux_mourn, linux_thread_stopped and
17569 * linux-low.h (struct lwp_info): Delete last_resume_kind field.
17570 (thread_db_free): Delete declaration.
17571 (thread_db_detach, thread_db_mourn): Declare.
17572 * thread-db.c (thread_db_init): Use thread_db_mourn.
17573 (thread_db_free): Delete, split in two.
17574 (disable_thread_event_reporting): New.
17575 (thread_db_detach): New.
17576 (thread_db_mourn): New.
17578 * server.h (struct thread_info) <last_resume_kind>: New field.
17579 <attached>: Add comment.
17580 <gdb_detached>: New field.
17581 (handler_func): Change return type to int.
17582 (handle_serial_event, handle_target_event): Ditto.
17583 (gdb_connected): Declare.
17585 (disconnected_tracing): Declare.
17586 (stop_tracing): Declare.
17588 * server.c (handle_query) <qSupported>: Report support for
17589 disconnected tracing.
17590 (queue_stop_reply_callback): Account for running threads.
17591 (gdb_wants_thread_stopped): New.
17592 (gdb_wants_all_threads_stopped): New.
17593 (gdb_reattached_process): New.
17594 (handle_status): Clear the `gdb_detached' flag of all processes.
17595 In all-stop, stop all threads.
17596 (main): Be sure to leave tfind mode. Handle disconnected tracing.
17597 (process_serial_event): If the remote connection breaks, or if an
17598 exit was forced with "monitor exit", force an event loop exit.
17599 Handle disconnected tracing on detach.
17600 (handle_serial_event): Adjust.
17601 (handle_target_event): If GDB isn't connected, forward events back
17602 to the inferior, unless the last process exited, in which case,
17603 exit gdbserver. Adjust interface.
17605 * remote-utils.c (remote_open): Don't block in accept. Instead
17606 register an event loop source on the listen socket file
17607 descriptor. Refactor bits into ...
17608 (listen_desc): ... this new global.
17609 (gdb_connected): ... this new function.
17610 (enable_async_notification): ... this new function.
17611 (handle_accept_event): ... this new function.
17612 (remote_close): Clear remote_desc.
17614 * inferiors.c (add_thread): Set the new thread's last_resume_kind.
17616 * target.h (struct target_ops) <mourn, thread_stopped, pause_all>:
17618 (mourn_inferior): Define.
17619 (target_process_qsupported): Avoid the dangling else problem.
17620 (thread_stopped): Define.
17621 (pause_all): Define.
17622 (target_waitstatus_to_string): Declare.
17623 * target.c (target_waitstatus_to_string): New.
17625 * tracepoint.c (tracing): Make extern.
17626 (disconnected_tracing): New.
17627 (stop_tracing): Make extern. Handle tracing stops due to GDB
17629 (cmd_qtdisconnected): New.
17630 (cmd_qtstatus): Report disconnected tracing status in trace reply.
17631 (handle_tracepoint_general_set): Handle QTDisconnected.
17633 * event-loop.c (event_handler_func): Change return type to int.
17634 (process_event): Bail out if the event handler wants the event
17636 (handle_file_event): Ditto.
17637 (start_event_loop): Bail out if the event handler wants the event
17640 * nto-low.c (nto_target_ops): Adjust.
17641 * spu-low.c (spu_wait): Don't remove the process here.
17642 (spu_target_ops): Adjust.
17643 * win32-low.c (win32_wait): Don't remove the process here.
17644 (win32_target_ops): Adjust.
17646 2010-04-11 Pedro Alves <pedro@codesourcery.com>
17648 * regcache.c (realloc_register_cache): Invalidate inferior's
17649 regcache before recreating it.
17651 2010-04-09 Pedro Alves <pedro@codesourcery.com>
17653 * tracepoint.c (cmd_qtstatus): Report trace buffer circularity.
17655 2010-04-09 Stan Shebs <stan@codesourcery.com>
17656 Pedro Alves <pedro@codesourcery.com>
17658 * server.h (LONGEST): New.
17659 (struct thread_info) <while_stepping>: New field.
17660 (unpack_varlen_hex, xrealloc, pulongest, plongest, phex_nz):
17662 (initialize_tracepoint, handle_tracepoint_general_set)
17663 (handle_tracepoint_query, tracepoint_finished_step)
17664 (tracepoint_was_hit, release_while_stepping_state_list):
17665 (current_traceframe): Declare.
17666 * server.c (handle_general_set): Handle tracepoint packets.
17667 (read_memory): New.
17668 (write_memory): New.
17669 (handle_search_memory_1): Use read_memory.
17670 (handle_query): Report support for conditional tracepoints, trace
17671 state variables, and tracepoint sources. Handle tracepoint
17673 (main): Initialize the tracepoints module.
17674 (process_serial_event): Handle traceframe reads/writes.
17676 * linux-low.c (handle_tracepoints): New.
17677 (linux_wait_1): Call it.
17678 (linux_resume_one_lwp): Handle while-stepping.
17679 (linux_supports_tracepoints, linux_read_pc, linux_write_pc): New.
17680 (linux_target_ops): Install them.
17681 * linux-low.h (struct linux_target_ops) <supports_tracepoints>:
17683 * linux-x86-low.c (x86_supports_tracepoints): New.
17684 (the_low_target). Install it.
17686 * mem-break.h (delete_breakpoint): Declare.
17687 * mem-break.c (delete_breakpoint): Make external.
17689 * target.h (struct target_ops): Add `supports_tracepoints',
17690 `read_pc', and `write_pc' fields.
17691 (target_supports_tracepoints): Define.
17692 * utils.c (xrealloc, decimal2str, pulongest, plongest, thirty_two)
17695 * regcache.h (struct regcache) <registers_owned>: New field.
17696 (init_register_cache, regcache_cpy): Declare.
17697 (regcache_read_pc, regcache_write_pc): Declare.
17698 (register_cache_size): Declare.
17699 (supply_regblock): Declare.
17700 * regcache.c (init_register_cache): New.
17701 (new_register_cache): Use it.
17702 (regcache_cpy): New.
17703 (register_cache_size): New.
17704 (supply_regblock): New.
17705 (regcache_read_pc, regcache_write_pc): New.
17707 * tracepoint.c: New.
17709 * Makefile.in (OBS): Add tracepoint.o.
17710 (tracepoint.o): New rule.
17712 2010-04-08 H.J. Lu <hongjiu.lu@intel.com>
17714 * Makefile.in (clean): Also remove i386-mmx.c i386-mmx-linux.c.
17716 (i386-mmx.c): Likewise.
17717 (i386-mmx-linux.o): Likewise.
17718 (i386-mmx-linux.c): Likewise.
17720 * configure.srv (srv_i386_regobj): Add i386-mmx.o.
17721 (srv_i386_linux_regobj): Add i386-mmx-linux.o.
17722 (srv_i386_xmlfiles): Add i386/i386-mmx.xml.
17723 (srv_i386_linux_xmlfiles): Add i386/i386-mmx-linux.xml.
17725 * linux-x86-low.c (init_registers_i386_mmx_linux): New.
17726 (x86_linux_update_xmltarget): Call init_registers_i386_mmx_linux
17727 and return if ptrace PTRACE_GETFPXREGS failed in 32bit.
17729 2010-04-07 H.J. Lu <hongjiu.lu@intel.com>
17731 * Makefile.in (clean): Updated.
17733 (i386-avx.c): Likewise.
17734 (i386-avx-linux.o): Likewise.
17735 (i386-avx-linux.c): Likewise.
17736 (amd64-avx.o): Likewise.
17737 (amd64-avx.c): Likewise.
17738 (amd64-avx-linux.o): Likewise.
17739 (amd64-avx-linux.c): Likewise.
17741 * configure.srv (srv_i386_regobj): Add i386-avx.o.
17742 (srv_i386_linux_regobj): Add i386-avx-linux.o.
17743 (srv_amd64_regobj): Add amd64-avx.o.
17744 (srv_amd64_linux_regobj): Add amd64-avx-linux.o.
17745 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx.xml.
17746 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx.xml.
17747 (srv_i386_xmlfiles): Add i386/i386-avx.xml.
17748 (srv_amd64_xmlfiles): Add i386/amd64-avx.xml.
17749 (srv_i386_linux_xmlfiles): Add i386/i386-avx-linux.xml.
17750 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-linux.xml.
17752 * i387-fp.c: Include "i386-xstate.h".
17754 (i387_cache_to_xsave): Likewise.
17755 (i387_xsave_to_cache): Likewise.
17756 (x86_xcr0): Likewise.
17758 * i387-fp.h (i387_cache_to_xsave): Likewise.
17759 (i387_xsave_to_cache): Likewise.
17760 (x86_xcr0): Likewise.
17762 * linux-arm-low.c (target_regsets): Initialize nt_type to 0.
17763 * linux-crisv32-low.c (target_regsets): Likewise.
17764 * linux-m68k-low.c (target_regsets): Likewise.
17765 * linux-mips-low.c (target_regsets): Likewise.
17766 * linux-ppc-low.c (target_regsets): Likewise.
17767 * linux-s390-low.c (target_regsets): Likewise.
17768 * linux-sh-low.c (target_regsets): Likewise.
17769 * linux-sparc-low.c (target_regsets): Likewise.
17770 * linux-xtensa-low.c (target_regsets): Likewise.
17772 * linux-low.c: Include <sys/uio.h>.
17773 (regsets_fetch_inferior_registers): Support nt_type.
17774 (regsets_store_inferior_registers): Likewise.
17775 (linux_process_qsupported): New.
17776 (linux_target_ops): Add linux_process_qsupported.
17778 * linux-low.h (regset_info): Add nt_type.
17779 (linux_target_ops): Add process_qsupported.
17781 * linux-x86-low.c: Include "i386-xstate.h", "elf/common.h"
17783 (init_registers_i386_avx_linux): New.
17784 (init_registers_amd64_avx_linux): Likewise.
17785 (xmltarget_i386_linux_no_xml): Likewise.
17786 (xmltarget_amd64_linux_no_xml): Likewise.
17787 (PTRACE_GETREGSET): Likewise.
17788 (PTRACE_SETREGSET): Likewise.
17789 (x86_fill_xstateregset): Likewise.
17790 (x86_store_xstateregset): Likewise.
17791 (use_xml): Likewise.
17792 (x86_linux_update_xmltarget): Likewise.
17793 (x86_linux_process_qsupported): Likewise.
17794 (target_regsets): Add NT_X86_XSTATE entry and Initialize nt_type.
17795 (x86_arch_setup): Don't call init_registers_amd64_linux nor
17796 init_registers_i386_linux here. Call
17797 x86_linux_update_xmltarget.
17798 (the_low_target): Add x86_linux_process_qsupported.
17800 * server.c (handle_query): Call target_process_qsupported.
17802 * target.h (target_ops): Add process_qsupported.
17803 (target_process_qsupported): New.
17805 2010-04-03 Pedro Alves <pedro@codesourcery.com>
17807 * inferiors.c (add_thread): Set last_status kind to
17808 TARGET_WAITKIND_IGNORE.
17809 * linux-low.c (cancel_breakpoint): Remove unnecessary regcache
17810 fetch. Use ptid_of. Avoid unnecessary get_lwp_thread calls.
17811 (linux_wait_1): Move `thread' local definition to block that uses
17812 it. Don't NULL initialize `event_child'.
17813 (linux_resume_one_thread): Avoid unnecessary get_lwp_thread calls.
17814 Alway set the thread's last_status to TARGET_WAITKIND_IGNORE.
17815 * linux-x86-low.c (x86_breakpoint_at): Read raw memory.
17817 2010-04-01 Pedro Alves <pedro@codesourcery.com>
17819 * linux-low.c (get_stop_pc): Don't adjust the PC if stopped with
17820 an extended waitstatus, or by a watchpoint.
17821 (cancel_breakpoints_callback): Don't cancel a breakpoint if the
17822 thread was stepping or has been stopped by a watchpoint.
17824 2010-04-01 Pedro Alves <pedro@codesourcery.com>
17826 * mem-break.c (struct raw_breakpoint): New field shlib_disabled.
17827 (set_gdb_breakpoint_at): If GDB is inserting a breakpoint on top
17828 of another, then delete the previous, and validate all
17830 (validate_inserted_breakpoint): New.
17831 (delete_disabled_breakpoints): New.
17832 (validate_breakpoints): New.
17833 (check_mem_read): Validate breakpoints before trusting their
17834 shadow. Delete disabled breakpoints.
17835 (check_mem_write): Validate breakpoints before trusting they
17836 should be inserted. Delete disabled breakpoints.
17837 * mem-break.h (validate_breakpoints):
17838 * server.c (handle_query): Validate breakpoints when we see a
17841 2010-04-01 Pedro Alves <pedro@codesourcery.com>
17843 * linux-low.c (linux_wait_1): Avoid setting need_step_over is
17844 there's a GDB breakpoint at stop_pc. Always report a trap to GDB
17845 if we could tell there's a GDB breakpoint at stop_pc.
17846 (need_step_over_p): Don't do a step over if we find a GDB
17847 breakpoint at the resume PC.
17849 * mem-break.c (struct raw_breakpoint): New.
17850 (enum bkpt_type): New type `gdb_breakpoint'.
17851 (struct breakpoint): Delete the `PC', `old_data' and `inserted'
17852 fields. New field `raw'.
17853 (find_raw_breakpoint_at): New.
17854 (set_raw_breakpoint_at): Handle refcounting. Create a raw
17855 breakpoint instead.
17856 (set_breakpoint_at): Adjust.
17857 (delete_raw_breakpoint): New.
17858 (release_breakpoint): New.
17859 (delete_breakpoint): Rename to...
17860 (delete_breakpoint_1): ... this. Add proc parameter. Use
17861 release_breakpoint. Return ENOENT.
17862 (delete_breakpoint): Reimplement.
17863 (find_breakpoint_at): Delete.
17864 (find_gdb_breakpoint_at): New.
17865 (delete_breakpoint_at): Delete.
17866 (set_gdb_breakpoint_at): New.
17867 (delete_gdb_breakpoint_at): New.
17868 (gdb_breakpoint_here): New.
17869 (set_reinsert_breakpoint): Use release_breakpoint.
17870 (uninsert_breakpoint): Rename to ...
17871 (uninsert_raw_breakpoint): ... this.
17872 (uninsert_breakpoints_at): Adjust to handle raw breakpoints.
17873 (reinsert_raw_breakpoint): Change parameter type to
17875 (reinsert_breakpoints_at): Adjust to handle raw breakpoints
17877 (check_breakpoints): Adjust. Use release_breakpoint.
17878 (breakpoint_here): Rewrite using find_raw_breakpoint_at.
17879 (breakpoint_inserted_here): Ditto.
17880 (check_mem_read): Adjust to iterate over raw breakpoints instead.
17881 Don't trust the breakpoint's shadow if it is not inserted.
17882 (check_mem_write): Adjust to iterate over raw breakpoints instead.
17883 (delete_all_breakpoints): Adjust.
17884 (free_all_breakpoints): Mark all breakpoints as uninserted, and
17885 use delete_breakpoint_1.
17887 * mem-break.h (breakpoints_supported): Delete declaration.
17888 (set_gdb_breakpoint_at): Declare.
17889 (gdb_breakpoint_here): Declare.
17890 (delete_breakpoint_at): Delete.
17891 (delete_gdb_breakpoint_at): Declare.
17893 * server.h (struct raw_breakpoint): Forward declare.
17894 (struct process_info): New field `raw_breakpoints'.
17896 * linux-x86-low.c (x86_insert_point, x86_remote_point): Handle Z0
17899 2010-03-24 Pedro Alves <pedro@codesourcery.com>
17901 * linux-low.c (status_pending_p_callback): Fix comment.
17902 (linux_wait_for_event_1): Move most of the internal breakpoint
17903 handling from here...
17904 (linux_wait_1): ... to here.
17905 (count_events_callback): New.
17906 (select_singlestep_lwp_callback): New.
17907 (select_event_lwp_callback): New.
17908 (cancel_breakpoints_callback): New.
17909 (select_event_lwp): New.
17910 (linux_wait_1): Simplify internal breakpoint handling. Give equal
17911 priority to all LWPs that have had events that should be reported
17912 to the client. Cancel breakpoints when about to reporting the
17913 event to the client, not while stopping lwps. No longer cancel
17914 finished single-steps here.
17915 (cancel_finished_single_step): Delete.
17916 (cancel_finished_single_steps): Delete.
17918 2010-03-24 Pedro Alves <pedro@codesourcery.com>
17920 * mem-break.c (enum bkpt_type): New.
17921 (struct breakpoint): New field `type'.
17922 (set_breakpoint_at): Change return type to struct breakpoint
17923 pointer. Set type to `other_breakpoint' by default.
17924 (delete_breakpoint): Rewrite, supporting more than one breakpoint
17925 in the breakpoint list.
17926 (delete_reinsert_breakpoints): Only delete reinsert breakpoints.
17927 (reinsert_breakpoint): Rename to ...
17928 (reinsert_raw_breakpoint): ... this.
17929 (reinsert_breakpoints_at): Adjust.
17930 * mem-break.h (struct breakpoint): Declare.
17931 (set_breakpoint_at): Change return type to struct breakpoint
17934 2010-03-24 Pedro Alves <pedro@codesourcery.com>
17936 * server.c (handle_query): Assign, not compare.
17938 2010-03-24 Pedro Alves <pedro@codesourcery.com>
17940 Teach linux gdbserver to step-over-breakpoints.
17942 * linux-low.c (can_hardware_single_step): New.
17943 (supports_breakpoints): New.
17944 (handle_extended_wait): If stopping threads, read the stop pc of
17945 the new cloned LWP.
17947 (get_stop_pc): Add `lwp' parameter. Handle it. Bail out if the
17948 low target doesn't support retrieving the PC.
17949 (add_lwp): Set last_resume_kind to resume_continue.
17950 (linux_attach_lwp_1): Adjust comments. Always set stop_expected.
17951 (linux_attach): Don't clear stop_expected. Set the lwp's
17952 last_resume_kind to resume_stop.
17953 (linux_detach_one_lwp): Don't check for removed breakpoints.
17954 (check_removed_breakpoint): Delete.
17955 (status_pending_p): Rename to ...
17956 (status_pending_p_callback): ... this. Don't check for removed
17957 breakpoints. Don't consider threads that are stopped from GDB's
17959 (linux_wait_for_lwp): Always read the stop_pc here.
17960 (cancel_breakpoint): New.
17961 (step_over_bkpt): New global.
17962 (linux_wait_for_event_1): Implement stepping over breakpoints.
17963 (gdb_wants_lwp_stopped): New.
17964 (gdb_wants_all_stopped): New.
17965 (linux_wait_1): Tag threads as gdb-wants-stopped. Cancel finished
17966 single-step traps here. Store the thread's last reported target
17968 (send_sigstop): Don't clear stop_expected. Always set it,
17970 (mark_lwp_dead): Remove reference to pending_is_breakpoint.
17971 (cancel_finished_single_step): New.
17972 (cancel_finished_single_steps): New.
17973 (wait_for_sigstop): Don't cancel finished single-step traps here.
17974 (linux_resume_one_lwp): Don't check for removed breakpoints.
17975 Don't set `step' on non-hardware step archs.
17976 (linux_set_resume_request): Ignore resume_stop requests if already
17977 stopping or stopped. Set the lwp's last_resume_kind.
17978 (resume_status_pending_p): Don't check for removed breakpoints.
17979 (need_step_over_p): New.
17980 (start_step_over): New.
17981 (finish_step_over): New.
17982 (linux_resume_one_thread): Always queue a sigstop for resume_stop
17983 requests. Clear the thread's last reported target waitstatus.
17984 Don't use the `suspended' flag. Don't consider pending breakpoints.
17985 (linux_resume): Start a step-over if necessary.
17986 (proceed_one_lwp): New.
17987 (proceed_all_lwps): New.
17988 (unstop_all_lwps): New.
17989 * linux-low.h (struct lwp_info): Rewrite comment for the
17990 `suspended' flag. Add the `stop_pc' field. Delete the
17991 `pending_stop_pc' field. Tweak the `stepping' flag's comment.
17992 Add `'last_resume_kind' and `need_step_over' fields.
17993 * inferiors.c (struct thread_info): Delete, moved elsewhere.
17994 * mem-break.c (struct breakpoint): Delete `reinserting' flag.
17995 Delete `breakpoint_to_reinsert' field. New flag `inserted'.
17996 (set_raw_breakpoint_at): New.
17997 (set_breakpoint_at): Rewrite to use it.
17998 (reinsert_breakpoint_handler): Delete.
17999 (set_reinsert_breakpoint): New.
18000 (reinsert_breakpoint_by_bp): Delete.
18001 (delete_reinsert_breakpoints): New.
18002 (uninsert_breakpoint): Rewrite.
18003 (uninsert_breakpoints_at): New.
18004 (reinsert_breakpoint): Rewrite.
18005 (reinsert_breakpoints_at): New.
18006 (check_breakpoints): Rewrite.
18007 (breakpoint_here): New.
18008 (breakpoint_inserted_here): New.
18009 (check_mem_read): Adjust.
18010 * mem-break.h (breakpoints_supported, breakpoint_here)
18011 (breakpoint_inserted_here, set_reinsert_breakpoint): Declare.
18012 (reinsert_breakpoint_by_bp): Delete declaration.
18013 (delete_reinsert_breakpoints): Declare.
18014 (reinsert_breakpoint): Delete declaration.
18015 (reinsert_breakpoints_at): Declare.
18016 (uninsert_breakpoint): Delete declaration.
18017 (uninsert_breakpoints_at): Declare.
18018 (check_breakpoints): Adjust prototype.
18019 * server.h: Adjust include order.
18020 (struct thread_info): Declare here. Add a `last_status' field.
18022 2010-03-23 Michael Snyder <msnyder@vmware.com>
18024 * server.c (crc32): New function.
18025 (handle_query): Add handling for 'qCRC:' request.
18027 2010-03-23 Pedro Alves <pedro@codesourcery.com>
18029 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR6 if the
18030 lwp had been stopped by a watchpoint.
18032 2010-03-16 Pedro Alves <pedro@codesourcery.com>
18034 * server.h (internal_error): Declare.
18035 (gdb_assert, ASSERT_FUNCTION, gdb_assert_fail): Define.
18036 * utils.c (internal_error): New function.
18038 2010-03-15 Andreas Schwab <schwab@redhat.com>
18040 * configure.srv: Fix typo setting srv_regobj.
18042 2010-03-15 Pedro Alves <pedro@codesourcery.com>
18044 * linux-low.c (fetch_register): Avoid passing a non string literal
18046 (usr_store_inferior_registers): Ditto.
18048 2010-03-14 Pedro Alves <pedro@codesourcery.com>
18050 * linux-low.c (linux_write_memory): Bail out early if peeking
18053 2010-03-14 Pedro Alves <pedro@codesourcery.com>
18055 * linux-low.h (struct lwp_info): New fields
18056 `stopped_by_watchpoint' and `stopped_data_address'.
18057 * linux-low.c (linux_wait_for_lwp): Check for watchpoint triggers
18058 here, and cache them in the lwp object.
18059 (wait_for_sigstop): Check stopped_by_watchpoint lwp field
18061 (linux_resume_one_lwp): Clear the lwp's stopped_by_watchpoint
18063 (linux_stopped_by_watchpoint): Rewrite.
18064 (linux_stopped_data_address): Rewrite.
18066 2010-03-06 Simo Melenius <simo.melenius@iki.fi>
18068 * linux-low.c (linux_wait_for_lwp): Fetch the regcache after
18069 switching the current inferior, not before.
18071 2010-03-01 H.J. Lu <hongjiu.lu@intel.com>
18073 * Makefile.in (clean): Replace reg-i386.c, reg-x86-64.c,
18074 reg-i386-linux.c and reg-x86-64-linux.c with i386.c, amd64.c,
18075 i386-linux.c and amd64-linux.c.
18076 (reg-i386.o): Removed.
18077 (reg-i386.c): Likewise.
18078 (reg-i386-linux.o): Likewise.
18079 (reg-i386-linux.c): Likewise.
18080 (reg-x86-64.o): Likewise.
18081 (reg-x86-64.c): Likewise.
18082 (reg-x86-64-linux.o): Likewise.
18083 (reg-x86-64-linux.c): Likewise.
18085 (i386.c): Likewise.
18086 (i386-linux.o): Likewise.
18087 (i386-linux.c): Likewise.
18088 (amd64.o): Likewise.
18089 (amd64.c): Likewise.
18090 (amd64-linux.o): Likewise.
18091 (amd64-linux.c): Likewise.
18093 * configure.srv (srv_i386_regobj): New.
18094 (srv_i386_linux_regobj): Likewise.
18095 (srv_amd64_regobj): Likewise.
18096 (srv_amd64_linux_regobj): Likewise.
18097 (srv_i386_32bit_xmlfiles): Likewise.
18098 (srv_i386_64bit_xmlfiles): Likewise.
18099 (srv_i386_xmlfiles): Likewise.
18100 (srv_amd64_xmlfiles): Likewise.
18101 (srv_i386_linux_xmlfiles): Likewise.
18102 (srv_amd64_linux_xmlfiles): Likewise.
18103 (i[34567]86-*-cygwin*): Set srv_regobj to $srv_i386_regobj. Set
18104 srv_xmlfiles to $srv_i386_xmlfiles.
18105 (i[34567]86-*-mingw32ce*): Likewise.
18106 (i[34567]86-*-mingw*): Likewise.
18107 (i[34567]86-*-nto*): Likewise.
18108 (i[34567]86-*-linux*): Set srv_regobj to $srv_i386_linux_regobj
18109 and $srv_amd64_linux_regobj. Set srv_xmlfiles to
18110 $srv_i386_linux_xmlfiles and $srv_amd64_linux_xmlfiles.
18111 (x86_64-*-linux*): Likewise.
18113 * linux-x86-low.c (init_registers_x86_64_linux): Removed.
18114 (init_registers_amd64_linux): New.
18115 (x86_arch_setup): Replace init_registers_x86_64_linux with
18116 init_registers_amd64_linux.
18118 2010-02-23 Maxim Kuvyrkov <maxim@codesourcery.com>
18120 * configure.ac: Check for libdl. If it is not available link against
18121 static libthread_db.
18122 * configure: Regenerate.
18124 2010-02-22 Pedro Alves <pedro@codesourcery.com>
18128 * i386-low.c (i386_length_and_rw_bits): Throw a fatal error if
18129 handing a read watchpoint.
18130 (i386_low_insert_watchpoint): Read watchpoints aren't supported.
18132 2010-02-12 Doug Evans <dje@google.com>
18134 * linux-low.c (linux_supports_tracefork_flag): Document.
18135 (linux_look_up_symbols): Add comment.
18137 2010-02-03 H.J. Lu <hongjiu.lu@intel.com>
18139 * regcache.c (supply_register): Clear regcache if buf is NULL.
18141 2010-02-02 Nicolas Roche <roche@sourceware.org>
18142 Joel Brobecker <brobecker@adacore.com>
18144 * inferiors.c (find_inferior): Add function documentation.
18145 (unloaded_dll): Handle the case where the unloaded dll has not
18146 been previously registered in the dll list.
18148 2010-02-01 Daniel Jacobowitz <dan@codesourcery.com>
18150 * linux-arm-low.c (thumb_breakpoint_len): Delete.
18151 (thumb2_breakpoint): New.
18152 (arm_breakpoint_at): Check for Thumb-2 breakpoints.
18154 2010-01-29 Daniel Jacobowitz <dan@codesourcery.com>
18156 * linux-low.c (get_stop_pc): Check for SIGTRAP.
18157 (linux_wait_for_event_1): Handle SIGILL and SIGSEGV as possible
18160 2010-01-21 Pedro Alves <pedro@codesourcery.com>
18162 * linux-ppc-low.c (ppc_arch_setup): Adjust to regcache changes.
18164 2010-01-21 Jan Kratochvil <jan.kratochvil@redhat.com>
18166 * linux-s390-low.c (s390_collect_ptrace_register)
18167 (s390_supply_ptrace_register): Adjust it for the new regcache parameter.
18169 2010-01-21 Doug Evans <dje@google.com>
18171 * linux-low.c (PTRACE_ARG3_TYPE): Change from long to void*.
18172 (PTRACE_ARG4_TYPE): New macro.
18173 (handle_extended_wait): Cast ptrace arg4 to PTRACE_ARG4_TYPE.
18174 (linux_wait_for_event_1, linux_resume_one_lwp): Ditto.
18175 (fetch_register): Cast to uintptr_t before casting to PTRACE_ARG3_TYPE.
18176 (usr_store_inferior_registers): Ditto.
18177 (linux_read_memory, linux_write_memory): Ditto.
18178 (linux_test_for_tracefork): Ditto.
18180 * linux-arm-low.c: Remove redundant include of gdb_proc_service.h.
18181 Only include elf.h if gdb_proc_service.h didn't include linux/elf.h.
18183 2010-01-21 Pedro Alves <pedro@codesourcery.com>
18185 * proc-service.c (ps_lgetregs): Don't refetch registers from the
18188 2010-01-21 Pedro Alves <pedro@codesourcery.com>
18190 * spu-low.c (spu_fetch_registers, spu_store_registers): Change
18191 prototype to take a regcache. Adjust.
18193 2010-01-20 Pedro Alves <pedro@codesourcery.com>
18195 * regcache.h (struct thread_info): Forward declare.
18196 (struct regcache): New.
18197 (new_register_cache): Adjust prototype.
18198 (get_thread_regcache): Declare.
18199 (free_register_cache): Adjust prototype.
18200 (registers_to_string, registers_from_string): Ditto.
18201 (supply_register, supply_register_by_name, collect_register)
18202 (collect_register_as_string, collect_register_by_name): Ditto.
18203 * regcache.c (struct inferior_regcache_data): Delete.
18204 (get_regcache): Rename to ...
18205 (get_thread_regcache): ... this. Adjust. Switch inferior before
18206 fetching registers.
18207 (regcache_invalidate_one): Adjust.
18208 (regcache_invalidate): Fix prototype.
18209 (new_register_cache): Return the new register cache.
18210 (free_register_cache): Change prototype.
18211 (realloc_register_cache): Adjust.
18212 (registers_to_string): Change prototype to take a regcache. Adjust.
18213 (registers_from_string): Ditto.
18214 (register_data): Ditto.
18215 (supply_register): Ditto.
18216 (supply_register_by_name): Ditto.
18217 (collect_register): Ditto.
18218 (collect_register_as_string): Ditto.
18219 (collect_register_by_name): Ditto.
18220 * server.c (process_serial_event): Adjust.
18221 * linux-low.h (regset_fill_func, regset_store_func): Change
18223 (get_pc, set_pc, collect_ptrace_register, supply_ptrace_register):
18225 * linux-low.c (get_stop_pc): Adjust.
18226 (check_removed_breakpoint): Adjust.
18227 (linux_wait_for_event): Adjust.
18228 (linux_resume_one_lwp): Adjust.
18229 (fetch_register): Add regcache parameter. Adjust.
18230 (usr_store_inferior_registers): Ditto.
18231 (regsets_fetch_inferior_registers): Ditto.
18232 (regsets_store_inferior_registers): Ditto.
18233 (linux_fetch_registers, linux_store_registers): Ditto.
18234 * i387-fp.c (i387_cache_to_fsave): Change prototype to take a
18236 (i387_fsave_to_cache, i387_cache_to_fxsave, i387_fxsave_to_cache):
18238 * i387-fp.h (i387_cache_to_fsave, i387_fsave_to_cache): Change
18239 prototype to take a regcache.
18240 (i387_cache_to_fxsave, i387_fxsave_to_cache): Ditto.
18241 * remote-utils.c (convert_ascii_to_int, outreg)
18242 (prepare_resume_reply): Change prototype to take a regcache.
18244 * target.h (struct target_ops) <fetch_registers, store_registers>:
18245 Change prototype to take a regcache.
18246 (fetch_inferior_registers, store_inferior_registers): Change
18247 prototype to take a regcache. Adjust.
18248 * proc-service.c (ps_lgetregs): Adjust.
18249 * linux-x86-low.c (x86_fill_gregset, x86_store_gregset)
18250 (x86_fill_fpregset, x86_store_fpregset, x86_fill_fpxregset)
18251 (x86_store_fpxregset, x86_get_pc, x86_set_pc): Change prototype to
18252 take a regcache. Adjust.
18253 * linux-arm-low.c (arm_fill_gregset, arm_store_gregset)
18254 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
18255 (arm_store_vfpregset, arm_get_pc, arm_set_pc):
18256 (arm_breakpoint_at): Change prototype to take a regcache. Adjust.
18257 * linux-cris-low.c (cris_get_pc, cris_set_pc)
18258 (cris_cannot_fetch_register):
18259 (cris_breakpoint_at): Change prototype to take a regcache.
18261 * linux-crisv32-low.c (cris_get_pc, cris_set_pc,
18262 cris_reinsert_addr, cris_write_data_breakpoint): Change prototype
18263 to take a regcache. Adjust.
18264 (cris_breakpoint_at, cris_insert_point, cris_remove_point):
18266 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Change prototype to
18267 take a regcache. Adjust.
18268 * linux-m68k-low.c (m68k_fill_gregset, m68k_store_gregset)
18269 (m68k_fill_fpregset, m68k_store_fpregset, m68k_get_pc,
18270 (m68k_set_pc): Change prototype to take a regcache. Adjust.
18271 * linux-mips-low.c (mips_get_pc):
18272 (mips_set_pc): Change prototype to take a regcache. Adjust.
18273 (mips_reinsert_addr): Adjust.
18274 (mips_collect_register): Change prototype to take a regcache.
18276 (mips_supply_register):
18277 (mips_collect_register_32bit, mips_supply_register_32bit)
18278 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
18279 (mips_store_fpregset): Ditto.
18280 * linux-ppc-low.c (ppc_supply_ptrace_register)
18281 (ppc_supply_ptrace_register): Ditto.
18282 (parse_spufs_run): Adjust.
18283 (ppc_get_pc, ppc_set_pc, ppc_fill_gregset, ppc_fill_vsxregset)
18284 (ppc_store_vsxregset, ppc_fill_vrregset, ppc_store_vrregset)
18285 (ppc_fill_evrregset, ppc_store_evrregset): Change prototype to
18286 take a regcache. Adjust.
18287 * linux-s390-low.c (s390_collect_ptrace_register)
18288 (s390_supply_ptrace_register, s390_fill_gregset, s390_get_pc)
18289 (s390_set_pc): Change prototype to take a regcache. Adjust.
18290 (s390_arch_setup): Adjust.
18291 * linux-sh-low.c (sh_get_pc, sh_breakpoint_at)
18292 (sh_fill_gregset): Change prototype to take a regcache. Adjust.
18293 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
18294 (sparc_fill_gregset, sparc_store_gregset_from_stack)
18295 (sparc_store_gregset, sparc_get_pc): Change prototype to take a
18297 (sparc_breakpoint_at): Adjust.
18298 * linux-xtensa-low.c (xtensa_fill_gregset):
18299 (xtensa_store_gregset):
18300 (xtensa_fill_xtregset, xtensa_store_xtregset, xtensa_get_pc)
18301 (xtensa_set_pc): Change prototype to take a regcache. Adjust.
18302 * nto-low.c (nto_fetch_registers, nto_store_registers): Change
18303 prototype to take a regcache. Adjust.
18304 * win32-arm-low.c (arm_fetch_inferior_register)
18305 (arm_store_inferior_register): Change prototype to take a
18307 * win32-i386-low.c (i386_fetch_inferior_register)
18308 (i386_store_inferior_register): Change prototype to take a
18310 * win32-low.c (child_fetch_inferior_registers)
18311 (child_store_inferior_registers): Change prototype to take a
18313 (win32_wait): Adjust.
18314 (win32_fetch_inferior_registers): Change prototype to take a
18316 (win32_store_inferior_registers): Adjust.
18317 * win32-low.h (struct win32_target_ops) <fetch_inferior_register,
18318 store_inferior_register>: Change prototype to take a regcache.
18320 2010-01-20 Doug Evans <dje@google.com>
18322 * linux-low.c (linux_create_inferior): Wrap use of __SIGRTMIN in
18324 (linux_wait_for_event1, linux_init_signals): Ditto.
18325 (W_STOPCODE): Provide definition if missing.
18327 2010-01-13 Vladimir Prus <vladimir@codesourcery.com>
18329 * linux-low.c (linux_core_of_thread): New.
18330 (compare_ints, show_process, list_threads): New.
18331 (linux_qxfer_osdata): Report threads and cores.
18332 (linux_target_op): Register linux_core_of_thread.
18333 * remote-utils.c (prepare_resume_reply): Report the core.
18334 (buffer_xml_printf): Support %d specifier.
18335 * server.c (handle_threads_qxfer_proper, handle_threads_qxfer):
18337 (handle_query): Handle qXfer:threads. Announce availability
18339 * target.h (struct target_ops): New field core_of_thread.
18341 2010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
18343 * Makefile.in (clean): Remove new generated files.
18344 (reg-s390.o, reg-s390.c): Remove rules.
18345 (reg-s390x.o, reg-s390x.c): Likewise.
18346 (s390-linux32.o, s390-linux32.c): Add rules.
18347 (s390-linux64.o, s390-linux64.c): Likewise.
18348 (s390x-linux64.o, s390x-linux64.c): Likewise.
18349 * configure.srv (s390*-*-linux*): Update srv_regobj and srv_xmlfiles.
18350 * linux-s390-low.c: Include <elf.h>.
18351 (HWCAP_S390_HIGH_GPRS): Define if undefined.
18352 (init_registers_s390): Remove prototype.
18353 (init_registers_s390x): Likewise.
18354 (init_registers_s390_linux32): Add prototype.
18355 (init_registers_s390_linux64): Likewise.
18356 (init_registers_s390x_linux64): Likewise.
18357 (s390_num_regs_3264): New define.
18358 (s390_regmap_3264): New global variable.
18359 (s390_cannot_fetch_register): Remove obsolete check.
18360 (s390_cannot_store_register): Likewise.
18361 (s390_collect_ptrace_register): Handle upper/lower register halves.
18362 (s390_supply_ptrace_register): Likewise.
18363 (s390_fill_gregset): Update to register number changes.
18364 (s390_get_hwcap): New routine.
18365 (s390_arch_setup): Detect 32-bit process running on 64-bit system.
18366 Install appropriate regmap and register set.
18368 2010-01-01 Joel Brobecker <brobecker@adacore.com>
18370 * server.c (gdbserver_version): Update copyright year to 2010.
18371 * gdbreplay.c (gdbreplay_version): Likewise.
18373 2009-12-28 Doug Evans <dje@google.com>
18375 * linux-low.c: Delete inclusion of ansidecl.h, elf/common.h,
18376 elf/external.h. Include <elf.h> instead but only if necessary.
18378 2009-12-28 Pedro Alves <pedro@codesourcery.com>
18380 * linux-low.c (linux_remove_process): Remove `detaching'
18381 parameter. Don't release/detach from thread_db here.
18382 (linux_kill): Release/detach from thread_db here, ...
18383 (linux_detach): ... and here, before actually detaching.
18384 (linux_wait_1): ... and here, when a process exits.
18385 * thread-db.c (any_thread_of): New.
18386 (thread_db_free): Switch the current inferior to a thread of the
18389 2009-12-21 Doug Evans <dje@google.com>
18391 * linux-x86-low.c: Delete outdated comment about Elf32_Phdr.
18393 * linux-low.c (kill_lwp): Use __NR_tkill instead of SYS_tkill.
18394 Move definition of tkill_failed to ifdef __NR_tkill to avoid gcc
18395 warning ifndef __NR_tkill. Move setting of errno there too.
18396 Delete unnecessary resetting of errno after syscall.
18397 Minor comment changes to match gdb/linux-nat.c:kill_lwp.
18399 * configure.ac: Check for dladdr.
18400 * config.in: Regenerate.
18401 * configure: Regenerate.
18402 * thread-db.c (dladdr_to_soname): Only define ifdef HAVE_DLADDR.
18403 (try_thread_db_load): Update.
18405 * linux-low.c (my_waitpid): Delete unnecessary prototype.
18407 2009-12-18 Doug Evans <dje@google.com>
18409 * event-loop.c: Include unistd.h if it exists.
18411 * linux-low.c (my_waitpid): Move definition away from being in
18412 between linux_tracefork_child/linux_test_for_tracefork.
18414 * gdb_proc_service.h (psaddr_t): Fix type.
18415 * thread-db.c (thread_db_info.td_thr_tls_get_addr_p): Fix
18416 signature to match glibc.
18418 2009-12-16 Doug Evans <dje@google.com>
18420 * linux-low.c (linux_read_memory): Fix argument to read.
18422 2009-11-26 Pedro Alves <pedro@codesourcery.com>
18424 * win32-low.c (get_child_debug_event): On EXIT_THREAD_DEBUG_EVENT
18425 events, don't leave current_inferior pointing at null.
18427 2009-11-26 Pedro Alves <pedro@codesourcery.com>
18429 * win32-low.c (LOG): Delete.
18430 (OUTMSG): Output to stderr.
18431 (OUTMSG2): Conditionalize on `debug_threads' variable, instead of
18432 on compile time LOG macro.
18433 (win32_wait): Fix debug output.
18435 2009-11-26 Pedro Alves <pedro@codesourcery.com>
18437 * win32-low.c (win32_add_one_solib): If the dll name is
18438 "ntdll.dll", prepend the system directory to the dll path.
18440 2009-11-17 Daniel Jacobowitz <dan@codesourcery.com>
18442 * m68k-tdep.c (m68k_gdbarch_init): Reuse previous initialization.
18444 2009-11-17 Nathan Sidwell <nathan@codesourcery.com>
18445 Vladimir Prus <vladimir@codesourcery.com>
18447 * Makefile.in (reg-cf.o, reg-cf.c): New targets.
18448 * configure.ac: Check for __mcoldfire__ and set
18449 gdb_cv_m68k_is_coldfire.
18450 * configure.srv: Use gdb_cv_m68k_is_coldfire to select between
18451 reg-cf.o and reg-m68k.o.
18452 * configure: Regenerated.
18454 2009-11-16 Pedro Alves <pedro@codesourcery.com>
18456 * linux-low.c (linux_remove_process): Add `detaching' parameter.
18457 Pass it to thread_db_free.
18458 (linux_kill, linux_detach, linux_wait_1): Adjust to pass the
18459 proper `detaching' argument to linux_remove_process.
18460 * linux-low.h (thread_db_free): Add `detaching' parameter.
18461 * thread-db.c (thread_db_init): Pass false as `detaching' argument
18463 (thread_db_free): Add `detaching' parameter. Only
18464 call td_ta_clear_event if detaching from process.
18466 2009-11-12 Maxim Kuvyrkov <maxim@codesourcery.com>
18468 * thread-db.c (thread_db_free): Fix typo.
18470 2009-11-11 Paul Pluzhnikov <ppluzhnikov@google.com>
18473 * thread-db.c (thread_db_free): Call td_ta_clear_event.
18475 2009-11-03 Nathan Sidwell <nathan@codesourcery.com>
18477 * configure.ac (i[34567]86-*): Check if we're targetting x86-64
18478 with an i686 compiler.
18479 * configure.srv (i[34567]86-*-linux*): Pull in x86-64 handling if
18481 * configure: Rebuilt.
18483 2009-10-29 Sandra Loosemore <sandra@codesourcery.com>
18487 * server.c (handle_search_memory_1): Correct read_addr initialization
18488 in loop for searching subsequent chunks.
18490 2009-10-29 Paul Pluzhnikov <ppluzhnikov@google.com>
18492 * configure.ac: New --with-libthread-db option.
18493 * thread-db.c: Allow direct dependence on libthread_db.
18494 (thread_db_free): Adjust.
18495 * config.in: Regenerate.
18496 * configure: Likewise.
18498 2009-10-28 Paul Pluzhnikov <ppluzhnikov@google.com>
18501 * thread-db.c (attach_thread): New function.
18502 (maybe_attach_thread): Return success/failure.
18503 (find_new_threads_callback): Adjust.
18504 (thread_db_find_new_threads): Loop until no new threads.
18506 2009-10-13 Pedro Alves <pedro@codesourcery.com>
18508 * proc-service.c (ps_lgetregs): Formatting.
18510 2009-10-08 Paul Pluzhnikov <ppluzhnikov@google.com>
18512 * acinclude.m4: (SRV_CHECK_THREAD_DB, SRV_CHECK_TLS_GET_ADDR): Remove.
18513 * configure.ac: Adjust.
18514 * linux-low.h (struct process_info_private): Move members to struct
18516 (thread_db_free, thread_db_handle_monitor_command): New prototype.
18517 * linux-low.c (linux_remove_process): Adjust.
18518 (linux_wait_for_event_1, linux_look_up_symbols): Likewise.
18519 * server.c (handle_query): Move code ...
18520 (handle_monitor_command): ... here. New function.
18521 * target.h (struct target_ops): New member.
18522 * thread-db.c (struct thread_db): New.
18523 (libthread_db_search_path): New variable.
18524 (thread_db_create_event, thread_db_enable_reporting)
18525 (find_one_thread, maybe_attach_thread, find_new_threads_callback)
18526 (thread_db_find_new_threads, (thread_db_get_tls_address): Adjust.
18527 (try_thread_db_load_1, dladdr_to_soname): New functions.
18528 (try_thread_db_load, thread_db_load_search): New functions.
18529 (thread_db_init): Search for libthread_db.
18530 (thread_db_free): New function.
18531 (thread_db_handle_monitor_command): Likewise.
18532 * config.in: Regenerate.
18533 * configure: Regenerate.
18535 2009-09-27 Ulrich Weigand <uweigand@de.ibm.com>
18537 * spu-low.c (spu_kill): Wait for inferior to terminate.
18538 Call clear_inferiors.
18539 (spu_detach): Call clear_inferiors.
18541 2009-08-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
18543 * aclocal.m4: Regenerate.
18544 * config.in: Likewise.
18545 * configure: Likewise.
18547 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
18549 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Define.
18550 (parse_spufs_run): New function.
18551 (ppc_get_pc, ppc_set_pc): Detect and handle SPU PC.
18552 (ppc_breakpoint_at): Handle SPU breakpoints.
18554 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
18556 * linux-low.c: Include <sys/stat.h> and <sys/vfs.h>.
18557 (SPUFS_MAGIC): Define.
18558 (spu_enumerate_spu_ids): New function.
18559 (linux_qxfer_spu): New function.
18560 (linux_target_ops): Install linux_qxfer_spu.
18562 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
18564 * configure.srv (powerpc*-*-linux*): Add powerpc-cell32l.o
18565 and powerpc-cell64l.o to srv_regobj. Add rs6000/powerpc-cell32l.xml
18566 and rs6000/powerpc-cell64l.xml to srv_xmlfiles.
18567 * Makefile.in (powerpc-cell32l.o, powerpc-cell32l.c): New rules.
18568 (powerpc-cell64l.o, powerpc-cell64l.c): Likewise.
18569 (clean): Handle powerpc-cell32l.c and powerpc-cell64l.c.
18570 * linux-ppc-low.c (PPC_FEATURE_CELL): Define.
18571 (init_registers_powerpc_cell32l): Add prototype.
18572 (init_registers_powerpc_cell64l): Likewise.
18573 (ppc_arch_setup): Detect Cell/B.E. architecture.
18575 2009-07-30 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
18577 * Makefile.in (datarootdir): New variable.
18579 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
18581 * linux-low.c (linux_write_memory): Update debugging output.
18582 * Makefile.in (clean): Add new descriptions.
18583 (arm-with-vfpv2.o, arm-with-vfpv2.c, arm-with-vfpv3.o)
18584 (arm-with-vfpv3.c, arm-with-neon.o, arm-with-neon.c): New rules.
18585 * configure.srv: Add new files for arm*-*-linux*.
18586 * linux-arm-low.c: Add new declarations.
18587 (PTRACE_GETVFPREGS, PTRACE_SETVFPREGS): Define if undefined.
18588 (arm_hwcap, HWCAP_VFP, HWCAP_IWMMXT, HWCAP_NEON, HWCAP_VFPv3)
18589 (HWCAP_VFPv3D16): New.
18590 (arm_fill_wmmxregset, arm_store_wmmxregset): Check HWCAP_IWMMXT
18591 instead of __IWMMXT__.
18592 (arm_fill_vfpregset, arm_store_vfpregset, arm_get_hwcap)
18593 (arm_arch_setup): New.
18594 (target_regsets): Remove #ifdef. Add VFP regset.
18595 (the_low_target): Use arm_arch_setup.
18597 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
18599 * linux-low.c (linux_kill_one_lwp): Adjust kernel workaround to skip
18600 the main thread again.
18602 2009-07-06 Aleksandar Ristovski <aristovski@qnx.com>
18604 Adding Neutrino gdbserver.
18605 * configure: Regenerated.
18606 * configure.ac: Add case for srv_qnx and set LIBS accordingly.
18607 * configure.srv (i[34567]86-*-nto*): New target.
18608 * nto-low.c, nto-low.h, nto-x86-low.c: New files.
18609 * remote-utils.c [__QNX__]: Include sys/iomgr.h
18610 (nto_comctrl) [__QNX__]: New function.
18611 (enable_async_io, disable_async_io) [__QNX__]: Call nto_comctrl.
18613 2009-07-05 Danny Backx <dannybackx@users.sourceforge.net>
18615 * configure.srv (i[34567]86-*-mingw32ce*): Add i386-low.o to
18618 2009-07-04 Danny Backx <dannybackx@users.sourceforge.net>
18619 Pedro Alves <pedro@codesourcery.com>
18621 * win32-i386-low.c (i386_get_thread_context): Handle systems that
18622 don't support CONTEXT_EXTENDED_REGISTERS.
18623 (i386_win32_breakpoint, i386_win32_breakpoint_len): New.
18624 (the_low_target): Install them.
18625 * win32-low.c (get_child_debug_event): Handle WaitForDebugEvent
18626 failing with ERROR_PIPE_NOT_CONNECTED.
18628 2009-06-30 Doug Evans <dje@google.com>
18629 Pierre Muller <muller@ics.u-strasbg.fr>
18631 Add h/w watchpoint support to x86-linux, win32-i386.
18632 * Makefile.in (SFILES): Add i386-low.c
18633 (i386_low_h): Define.
18634 (i386-low.o): Add dependencies.
18635 (linux-x86-low.o): Add i386-low.h dependency.
18636 (win32-i386-low.o): Ditto.
18637 * i386-low.c: New file.
18638 * i386-low.h: New file.
18639 * configure.srv (i[34567]86-*-cygwin*): Add i386-low.o to srv_tgtobj.
18640 (i[34567]86-*-linux*, i[34567]86-*-mingw*, x86_64-*-linux*): Ditto.
18641 * linux-low.c (linux_add_process): Initialize arch_private.
18642 (linux_remove_process): Free arch_private.
18643 (add_lwp): Initialize arch_private.
18644 (delete_lwp): Free arch_private.
18645 (linux_resume_one_lwp): Call the_low_target.prepare_to_resume if
18647 * linux-low.h (process_info_private): New member arch_private.
18648 (lwp_info): New member arch_private.
18649 (linux_target_ops): New members new_process, new_thread,
18651 (ptid_of): New macro.
18652 * linux-x86-low.c: Include stddef.h, i386-low.h.
18653 (arch_process_info): New struct.
18654 (arch_lwp_info): New struct.
18655 (x86_linux_dr_get, x86_linux_dr_set): New functions.
18656 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
18657 (i386_dr_low_get_status): New function.
18658 (x86_insert_point, x86_remove_point): New functions.
18659 (x86_stopped_by_watchpoint): New function.
18660 (x86_stopped_data_address): New function.
18661 (x86_linux_new_process, x86_linux_new_thread): New functions.
18662 (x86_linux_prepare_to_resume): New function.
18663 (the_low_target): Add entries for insert_point, remove_point,
18664 stopped_by_watchpoint, stopped_data_address, new_process, new_thread,
18666 * server.c (debug_hw_points): New global.
18667 (monitor_show_help): Document set debug-hw-points.
18668 (handle_query): Process "set debug-hw-points".
18669 * server.h (debug_hw_points): Declare.
18670 (paddress): Declare.
18671 * utils.c (NUMCELLS, CELLSIZE): New macros.
18672 (get_sell, xsnprintf, paddress): New functions.
18673 * win32-arm-low.c (the_low_target): Add entries for insert_point,
18674 remove_point, stopped_by_watchpoint, stopped_data_address.
18675 * win32-i386-low.c: Include i386-low.h.
18676 (debug_reg_state): Replaces dr.
18677 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
18678 (i386_dr_low_get_status): New function.
18679 (i386_insert_point, i386_remove_point): New functions.
18680 (i386_stopped_by_watchpoint): New function.
18681 (i386_stopped_data_address): New function.
18682 (i386_initial_stuff): Update.
18683 (get_thread_context,set_thread_context,i386_thread_added): Update.
18684 (the_low_target): Add entries for insert_point,
18685 remove_point, stopped_by_watchpoint, stopped_data_address.
18686 * win32-low.c (win32_insert_watchpoint): New function.
18687 (win32_remove_watchpoint): New function.
18688 (win32_stopped_by_watchpoint): New function.
18689 (win32_stopped_data_address): New function.
18690 (win32_target_ops): Add entries for insert_watchpoint,
18691 remove_watchpoint, stopped_by_watchpoint, stopped_data_address.
18692 * win32-low.h (win32_target_ops): New members insert_point,
18693 remove_point, stopped_by_watchpoint, stopped_data_address.
18695 2009-06-25 Pedro Alves <pedro@codesourcery.com>
18697 * server.c (process_serial_event): Re-return unsupported, not
18698 error, if the type isn't recognized. Re-allow supporting only
18699 insert or remove packets. Also call require_running for
18700 breakpoints. Add missing break statement to default case. Tidy.
18701 * target.h (struct target_ops): Rename insert_watchpoint to
18702 insert_point, and remove_watchpoint to remove_point.
18704 * linux-low.h (struct linux_target_ops): Likewise.
18705 * linux-low.c (linux_insert_watchpoint): Rename to ...
18706 (linux_insert_point): ... this. Adjust.
18707 (linux_remove_watchpoint): Rename to ...
18708 (linux_remove_point): ... this. Adjust.
18709 (linux_target_ops): Adjust.
18710 * linux-crisv32-low.c (cris_insert_watchpoint): Rename to ...
18711 (cris_insert_point): ... this.
18712 (cris_remove_watchpoint): Rename to ...
18713 (cris_remove_point): ... this.
18714 (the_low_target): Adjust.
18716 2009-06-24 Pierre Muller <muller@ics.u-strasbg.fr>
18718 * server.c (handle_v_kill): Pass signal_pid to
18719 kill_inferior if multi_process is zero.
18721 2009-06-23 Aleksandar Ristovski <aristovski@qnx.com>
18723 * server.c (process_serial_event): Add support for Z0 and Z1 packet.
18724 * target.h (target_ops): Comment for *_watchpoint to make it clear
18725 the functions can get types '0' and '1'.
18727 2009-06-22 Aleksandar Ristovski <aristovski@qnx.com>
18729 * linux-low.c (usr_fetch_inferior_registers): Remove check for regno 0.
18730 * proc-service.c (ps_lgetregs): Pass -1 to fetch all registers.
18731 * regcache.c (get_regcache): Likewise.
18732 * spu-low.c (spu_fetch_registers): Remove 0 to -1 conversion.
18733 * win32-low.c (child_fetch_inferior_registers): Remove check for
18736 2009-06-19 Aleksandar Ristovski <aristovski@qnx.com>
18737 Pedro Alves <pedro@codesourcery.com>
18739 * target.h (struct target_ops) <supports_multi_process>: New
18741 (target_supports_multi_process): New.
18742 * server.c (handle_query): Even if GDB reports support, only
18743 enable multi-process if the target also supports it. Report
18744 multi-process support only if the target backend supports it.
18745 * linux-low.c (linux_supports_multi_process): New function.
18746 (linux_target_ops): Install it as target_supports_multi_process
18749 2009-05-24 Doug Evans <dje@google.com>
18751 Global renaming of find_thread_pid to find_thread_ptid.
18752 * server.h (find_thread_ptid): Renamed from find_thread_pid.
18753 * inferiors.c (find_thread_ptid): Renamed from find_thread_pid.
18754 All callers updated.
18756 * linux-low.c (handle_extended_wait): Use linux_resume_one_lwp
18757 to resume the newly created thread, don't call ptrace (PTRACE_CONT)
18760 * linux-low.c (get_stop_pc): Print pc if debug_threads.
18761 (check_removed_breakpoint, linux_wait_for_lwp): Ditto.
18762 (linux_resume_one_lwp): Ditto.
18764 2009-05-23 Doug Evans <dje@google.com>
18766 * linux-low.c (linux_resume_one_lwp): Change type of first arg
18767 from struct inferior_list_entry * to struct lwp_info *.
18768 All callers updated.
18770 2009-05-13 Doug Evans <dje@google.com>
18772 * linux-x86-low.c: Don't include assert.h.
18773 (x86_siginfo_fixup): Use fatal, not assert.
18774 (x86_arch_setup): Fix comment.
18776 2009-05-12 Doug Evans <dje@google.com>
18778 Biarch support for i386/amd64 gdbserver.
18779 * Makefile.in (SFILES): Remove linux-i386-low.c, linux-x86-64-low.c.
18780 Add linux-x86-low.c.
18781 (linux-i386-low.o, linux-x86-64-low.o): Delete.
18782 (linux-x86-low.o): Add.
18783 * linux-x86-64-low.c: Delete.
18784 * linux-i386-low.c: Delete.
18785 * linux-x86-low.c: New file.
18786 * configure.srv (i?86-linux srv_tgtobj): Replace linux-i386-low.o with
18788 (x86_64-linux srv_tgtobj): Replace linux-x86-64-low.o with
18790 (x86_64-linux srv_regobj): Add reg-i386-linux.o.
18791 * linux-low.c: Include ansidecl.h, elf/common.h, elf/external.h.
18792 (linux_child_pid_to_exec_file): New function.
18793 (elf_64_header_p, elf_64_file_p): New functions.
18794 (siginfo_fixup): New function.
18795 (linux_xfer_siginfo): New local inf_siginfo. Call siginfo_fixup to
18796 give target a chance to convert layout.
18797 * linux-low.h (linux_target_ops): New member siginfo_fixup.
18798 (linux_child_pid_to_exec_file, elf_64_file_p): Declare.
18800 2009-05-07 Doug Evans <dje@google.com>
18802 * linux-low.c (regsets_fetch_inferior_registers): Fix memory leak.
18803 (regsets_store_inferior_registers): Ditto.
18805 2009-05-06 Pedro Alves <pedro@codesourcery.com>
18809 * linux-low.c (must_set_ptrace_flags): Delete.
18810 (linux_create_inferior): Set `lwp->must_set_ptrace_flags' instead
18812 (linux_attach_lwp_1): Don't set PTRACE_SETOPTIONS here. Set
18813 `lwp->must_set_ptrace_flags' instead.
18814 (linux_wait_for_event_1): Set ptrace options here.
18815 (linux_wait_1): ... not here.
18817 2009-04-30 Doug Evans <dje@google.com>
18819 * inferiors.c (started_inferior_callback): New function.
18820 (attached_inferior_callback): New function.
18821 (have_started_inferiors_p, have_attached_inferiors_p): New functions.
18822 * server.c (print_started_pid, print_attached_pid): New functions.
18823 (detach_or_kill_for_exit): New function.
18824 (main): Call it instead of for_each_inferior (kill_inferior_callback).
18825 * server.h (have_started_inferiors_p): Declare.
18826 (have_attached_inferiors_p): Declare.
18828 * inferiors.c (remove_process): Fix memory leak, free process.
18829 * linux-low.c (linux_remove_process): New function.
18830 (linux_kill): Call it instead of remove_process.
18831 (linux_detach, linux_wait_1): Ditto.
18833 2009-04-19 Danny Backx <dannybackx@users.sourceforge.net>
18835 * configure.srv: Add x86 Windows CE target.
18837 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
18839 * inferiors.c (get_thread_process): Make global.
18840 * server.h (get_thread_process): Add prototype.
18841 * thread-db.c (find_one_thread): Use get_thread_process
18842 instead of current_process.
18843 (thread_db_get_tls_address): Do not crash if called when
18844 thread layer is not yet initialized.
18846 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
18848 * remote-utils.c (prepare_resume_reply): Null-terminate packet.
18849 * spu-low.c (current_tid): Rename to ...
18850 (current_ptid): ... this.
18851 (fetch_ppc_register, fetch_ppc_memory, store_ppc_memory,
18852 spu_proc_xfer_spu, spu_resume, spu_request_interrupt): Use
18853 ptid_get_lwp (current_ptid) instead of current_tid.
18854 (spu_kill, spu_detach, spu_join, spu_wait): Use pid argument
18855 instead of current_tid. Use find_process_pid to verify pid
18856 argument is valid. Pass proper argument to remove_process.
18857 (spu_thread_alive): Compare current_ptid instead of current_tid.
18858 (spu_resume): Likewise.
18860 2009-04-02 Pedro Alves <pedro@codesourcery.com>
18862 * linux-low.c (usr_store_inferior_registers): Declare local `pid'
18865 2009-04-01 Pedro Alves <pedro@codesourcery.com>
18867 Implement the multiprocess extensions, and add linux multiprocess
18870 * server.h (ULONGEST): Declare.
18871 (struct ptid, ptid_t): New.
18872 (minus_one_ptid, null_ptid): Declare.
18873 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
18874 (ptid_get_tid, ptid_equal, ptid_is_pid): Declare.
18875 (struct inferior_list_entry): Change `id' type from unsigned from
18877 (struct sym_cache, struct breakpoint, struct
18878 process_info_private): Forward declare.
18879 (struct process_info): Declare.
18880 (current_process): Declare.
18881 (all_processes): Declare.
18882 (initialize_inferiors): Declare.
18883 (add_thread): Adjust to use ptid_t.
18884 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): Ditto.
18885 (add_process, remove_process, find_thread_pid): Declare.
18886 (find_inferior_id): Adjust to use ptid_t.
18887 (cont_thread, general_thread, step_thread): Change type to ptid_t.
18888 (multi_process): Declare.
18889 (push_event): Adjust to use ptid_t.
18890 (read_ptid, write_ptid): Declare.
18891 (prepare_resume_reply): Adjust to use ptid_t.
18892 (clear_symbol_cache): Declare.
18893 * inferiors.c (all_processes): New.
18894 (null_ptid, minus_one_ptid): New.
18895 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
18896 (ptid_get_tid, ptid_equal, ptid_is_pid): New.
18897 (add_thread): Change unsigned long to ptid. Remove gdb_id
18899 (thread_id_to_gdb_id, thread_to_gdb_id): Change unsigned long to ptid.
18900 (gdb_id_to_thread): Rename to ...
18901 (find_thread_pid): ... this. Change unsigned long to ptid.
18902 (gdb_id_to_thread_id, find_inferior_id): Change unsigned long to ptid.
18903 (loaded_dll, pull_pid_from_list): Adjust.
18904 (add_process, remove_process, find_process_pid)
18905 (get_thread_process, current_process, initialize_inferiors): New.
18906 * target.h (struct thread_resume) <thread>: Change type to ptid_t.
18907 (struct target_waitstatus) <related_pid>: Ditto.
18908 (struct target_ops) <kill, detach>: Add `pid' argument. Change
18909 return type to int.
18910 (struct target_ops) <join>: Add `pid' argument.
18911 (struct target_ops) <thread_alive>: Change pid's type to ptid_t.
18912 (struct target_ops) <wait>: Add `ptid' field. Change return type
18914 (kill_inferior, detach_inferior, join_inferior): Add `pid' argument.
18915 (mywait): Add `ptid' argument. Change return type to ptid_t.
18916 (target_pid_to_str): Declare.
18917 * target.c (set_desired_inferior): Adjust to use ptids.
18918 (mywait): Add new `ptid' argument. Adjust.
18919 (target_pid_to_str): New.
18920 * mem-break.h (free_all_breakpoints): Declare.
18921 * mem-break.c (breakpoints): Delelete.
18922 (set_breakpoint_at, delete_breakpoint, find_breakpoint_at)
18923 (check_mem_read, check_mem_write, delete_all_breakpoints): Adjust
18924 to use per-process breakpoint list.
18925 (free_all_breakpoints): New.
18926 * remote-utils.c (struct sym_cache) <name>: Drop `const'.
18927 (symbol_cache, all_symbols_looked_up): Delete.
18929 (ishex, unpack_varlen_hex, write_ptid, hex_or_minus_one,
18931 (prepare_resume_reply): Change ptid argument's type from unsigned
18932 long to ptid_t. Adjust. Implement W;process and X;process.
18933 (free_sym_cache, clear_symbol_cache): New.
18934 (look_up_one_symbol): Adjust to per-process symbol cache. *
18935 * server.c (cont_thread, general_thread, step_thread): Change type
18937 (attached): Delete.
18938 (multi_process): New.
18939 (last_ptid): Change type to ptid_t.
18940 (struct vstop_notif) <ptid>: Change type to ptid_t.
18941 (queue_stop_reply, push_event): Change `ptid' argument's type to
18943 (discard_queued_stop_replies): Add `pid' argument.
18944 (start_inferior): Adjust to use ptids. Adjust to mywait interface
18945 changes. Don't reference the `attached' global.
18946 (attach_inferior): Adjust to mywait interface changes.
18947 (handle_query): Adjust to use ptids. Parse GDB's qSupported
18948 features. Handle and report "multiprocess+". Handle
18950 (handle_v_cont): Adjust to use ptids. Adjust to mywait interface
18952 (handle_v_kill): New.
18953 (handle_v_stopped): Adjust to use target_pid_to_str.
18954 (handle_v_requests): Allow multiple attaches and runs when
18955 multiprocess extensions are in effect. Handle "vKill".
18956 (myresume): Adjust to use ptids.
18957 (queue_stop_reply_callback): Add `arg' parameter. Handle it.
18958 (handle_status): Adjust to discard_queued_stop_replies interface
18960 (first_thread_of, kill_inferior_callback)
18961 (detach_or_kill_inferior_callback, join_inferiors_callback): New.
18962 (main): Call initialize_inferiors. Adjust to use ptids, killing
18963 and detaching from all inferiors. Handle multiprocess packet
18965 * linux-low.h: Include gdb_proc_service.h.
18966 (struct process_info_private): New.
18967 (struct linux_target_ops) <pid_of>: Use ptid_get_pid.
18968 <lwpid_of>: Use ptid_get_lwp.
18969 (get_lwp_thread): Adjust.
18970 (struct lwp_info): Add `dead' member.
18971 (find_lwp_pid): Declare.
18972 * linux-low.c (thread_db_active): Delete.
18973 (new_inferior): Adjust comment.
18974 (inferior_pid): Delete.
18975 (linux_add_process): New.
18976 (handle_extended_wait): Adjust.
18977 (add_lwp): Change unsigned long to ptid.
18978 (linux_create_inferior): Add process to processes table. Adjust
18979 to use ptids. Don't set new_inferior here.
18980 (linux_attach_lwp): Rename to ...
18981 (linux_attach_lwp_1): ... this. Add `initial' argument. Handle
18982 it. Adjust to use ptids.
18983 (linux_attach_lwp): New.
18984 (linux_attach): Add process to processes table. Don't set
18986 (struct counter): New.
18987 (second_thread_of_pid_p, last_thread_of_process_p): New.
18988 (linux_kill_one_lwp): Add `args' parameter. Handle it. Adjust to
18989 multiple processes.
18990 (linux_kill): Add `pid' argument. Handle it. Adjust to multiple
18991 processes. Remove process from process table.
18992 (linux_detach_one_lwp): Add `args' parameter. Handle it. Adjust
18993 to multiple processes.
18994 (any_thread_of): New.
18995 (linux_detach): Add `pid' argument, and handle it. Remove process
18996 from processes table.
18997 (linux_join): Add `pid' argument. Handle it.
18998 (linux_thread_alive): Change unsighed long argument to ptid_t.
18999 Consider dead lwps as not being alive.
19000 (status_pending_p): Rename `dummy' argument to `arg'. Filter out
19001 threads we're not interested in.
19002 (same_lwp, find_lwp_pid): New.
19003 (linux_wait_for_lwp): Change `pid' argument's type from int to
19005 (linux_wait_for_event): Rename to ...
19006 (linux_wait_for_event_1): ... this. Change `pid' argument's type
19007 from int to ptid_t. Adjust.
19008 (linux_wait_for_event): New.
19009 (linux_wait_1): Add `ptid' argument. Change return type to
19010 ptid_t. Adjust. Use last_thread_of_process_p. Remove processes
19011 that exit from the process table.
19012 (linux_wait): Add `ptid' argument. Change return type to ptid_t.
19014 (mark_lwp_dead): New.
19015 (wait_for_sigstop): Adjust to use ptids. If a process exits while
19016 stopping all threads, mark its main lwp as dead.
19017 (linux_set_resume_request, linux_resume_one_thread): Adjust to use
19019 (fetch_register, usr_store_inferior_registers)
19020 (regsets_fetch_inferior_registers)
19021 (regsets_store_inferior_registers, linux_read_memory)
19022 (linux_write_memory): Inline `inferior_pid'.
19023 (linux_look_up_symbols): Adjust to use per-process
19024 `thread_db_active'.
19025 (linux_request_interrupt): Adjust to use ptids.
19026 (linux_read_auxv): Inline `inferior_pid'.
19027 (initialize_low): Don't reference thread_db_active.
19028 * gdb_proc_service.h (struct ps_prochandle) <pid>: Remove.
19029 * proc-service.c (ps_lgetregs): Use find_lwp_pid.
19030 (ps_getpid): Return the pid of the current inferior.
19031 * thread-db.c (proc_handle, thread_agent): Delete.
19032 (thread_db_create_event, thread_db_enable_reporting): Adjust to
19034 (find_one_thread): Change argument type to ptid_t. Adjust to
19036 (maybe_attach_thread): Adjust to per-process data and ptids.
19037 (thread_db_find_new_threads): Ditto.
19038 (thread_db_init): Ditto.
19039 * spu-low.c (spu_create_inferior, spu_attach): Add process to
19040 processes table. Adjust to use ptids.
19041 (spu_kill, spu_detach): Adjust interface. Remove process from
19043 (spu_join, spu_thread_alive): Adjust interface.
19044 (spu_wait): Adjust interface. Remove process from processes
19045 table. Adjust to use ptids.
19046 * win32-low.c (current_inferior_tid): Delete.
19047 (current_inferior_ptid): New.
19048 (debug_event_ptid): New.
19049 (thread_rec): Take a ptid. Adjust.
19050 (child_add_thread): Add `pid' argument. Adjust to use ptids.
19051 (child_delete_thread): Ditto.
19052 (do_initial_child_stuff): Add `attached' argument. Add process to
19054 (child_fetch_inferior_registers, child_store_inferior_registers):
19056 (win32_create_inferior): Pass 0 to do_initial_child_stuff.
19057 (win32_attach): Pass 1 to do_initial_child_stuff.
19058 (win32_kill): Adjust interface. Remove process from processes
19060 (win32_detach): Ditto.
19061 (win32_join): Adjust interface.
19062 (win32_thread_alive): Take a ptid.
19063 (win32_resume): Adjust to use ptids.
19064 (get_child_debug_event): Ditto.
19065 (win32_wait): Adjust interface. Remove exiting process from
19068 2009-04-01 Pedro Alves <pedro@codesourcery.com>
19070 Non-stop mode support.
19072 * server.h (non_stop): Declare.
19073 (gdb_client_data, handler_func): Declare.
19074 (delete_file_handler, add_file_handler, start_event_loop):
19076 (handle_serial_event, handle_target_event, push_event)
19077 (putpkt_notif): Declare.
19078 * target.h (enum resume_kind): New.
19079 (struct thread_resume): Replace `step' field by `kind' field.
19080 (TARGET_WNOHANG): Define.
19081 (struct target_ops) <wait>: Add `options' argument.
19082 <supports_non_stop, async, start_non_stop>: New fields.
19083 (target_supports_non_stop, target_async): New.
19084 (start_non_stop): Declare.
19085 (mywait): Add `options' argument.
19086 * target.c (mywait): Add `options' argument. Print child exit
19087 notifications here.
19088 (start_non_stop): New.
19089 * server.c (non_stop, own_buf, mem_buf): New globals.
19090 (struct vstop_notif): New.
19091 (notif_queue): New global.
19092 (queue_stop_reply, push_event, discard_queued_stop_replies)
19093 (send_next_stop_reply): New.
19094 (start_inferior): Adjust to use resume_kind. Adjust to mywait
19096 (attach_inferior): In non-stop mode, don't wait for the target
19098 (handle_general_set): Handle QNonStop.
19099 (handle_query): When handling qC, return the current general
19100 thread, instead of the first thread of the list.
19101 (handle_query): If the backend supports non-stop mode, include
19102 QNonStop+ in the qSupported query response.
19103 (handle_v_cont): Adjust to use resume_kind. Handle resume_stop
19105 (handle_v_attach, handle_v_run): Handle non-stop mode.
19106 (handle_v_stopped): New.
19107 (handle_v_requests): Report support for vCont;t. Handle vStopped.
19108 (myresume): Adjust to use resume_kind. Handle non-stop.
19109 (queue_stop_reply_callback): New.
19110 (handle_status): Handle non-stop mode.
19111 (main): Clear non_stop flag on reconnection. Use the event-loop.
19112 Refactor serial protocol handling from here ...
19113 (process_serial_event): ... to this new function. When GDB
19114 selects any thread, select one here. In non-stop mode, wait until
19115 GDB acks all pending events before exiting.
19116 (handle_serial_event, handle_target_event): New.
19117 * remote-utils.c (remote_open): Install remote_desc in the event
19119 (remote_close): Remove remote_desc from the event loop.
19120 (putpkt_binary): Rename to...
19121 (putpkt_binary_1): ... this. Add `is_notic' argument. Handle it.
19122 (putpkt_binary): New as wrapper around putpkt_binary_1.
19123 (putpkt_notif): New.
19124 (prepare_resume_reply): In non-stop mode, don't change the
19126 * event-loop.c: New.
19127 * Makefile.in (OBJ): Add event-loop.o.
19128 (event-loop.o): New rule.
19130 * linux-low.h (pid_of): Moved here.
19132 (get_lwp_thread): Use lwpid_of.
19133 (struct lwp_info): Delete `lwpid' field. Add `suspended' field.
19134 * linux-low.c (pid_of): Delete.
19135 (inferior_pid): Use lwpid_of.
19136 (linux_event_pipe): New.
19137 (target_is_async_p): New.
19139 (handle_extended_wait): Use lwpid_of.
19140 (add_lwp): Don't set lwpid field.
19141 (linux_attach_lwp): Adjust debug output. Use lwpid_of.
19142 (linux_kill_one_lwp): If killing a running lwp, stop it first.
19143 Use lwpid_of. Adjust to linux_wait_for_event interface changes.
19144 (linux_detach_one_lwp): If detaching from a running lwp, stop it
19145 first. Adjust to linux_wait_for_event interface changes. Use
19147 (linux_detach): Don't delete the main lwp here.
19148 (linux_join): Use my_waitpid. Avoid signal_pid. Use lwpid_of.
19149 (status_pending_p): Don't consider explicitly suspended lwps.
19150 (linux_wait_for_lwp): Take an integer pid instead of a lwp_info
19151 pointer. Add OPTIONS argument. Change return type to int. Use
19152 my_waitpid instead of sleeping. Handle WNOHANG. Use lwpid_of.
19153 (linux_wait_for_event): Take an integer pid instead of a lwp_info
19154 pointer. Add status pointer argument. Return a pid instead of a
19155 status. Use lwpid_of. Adjust to linux_wait_for_lwp interface
19156 changes. In non-stop mode, don't switch to a random thread.
19157 (linux_wait): Rename to...
19158 (linux_wait_1): ... this. Add target_options argument, and handle
19159 it. Adjust to use resume_kind. Use lwpid_of. In non-stop mode,
19160 don't handle the continue thread. Handle TARGET_WNOHANG. Merge
19161 clean exit and signal exit code. Don't stop all threads in
19162 non-stop mode. In all-stop mode, only stop all threads when
19163 reporting a stop to GDB. Handle explicit thread stop requests.
19164 (async_file_flush, async_file_mark): New.
19166 (send_sigstop): Use lwpid_of.
19167 (wait_for_sigstop): Use lwpid_of. Adjust to linux_wait_for_event
19168 interface changes. In non-stop mode, don't switch to a random
19170 (linux_resume_one_lwp): Use lwpid_of.
19171 (linux_continue_one_thread, linux_queue_one_thread): Merge into ...
19172 (linux_resume_one_thread): ... this. Handle resume_stop. In
19173 non-stop mode, don't look for pending flag in all threads.
19174 (resume_status_pending_p): Don't consider explicitly suspended
19176 (my_waitpid): Reimplement. Emulate __WALL.
19177 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
19179 (sigchld_handler, linux_supports_non_stop, linux_async)
19180 (linux_start_non_stop): New.
19181 (linux_target_ops): Register linux_supports_non_stop, linux_async
19182 and linux_start_non_stop.
19183 (initialize_low): Install SIGCHLD handler.
19184 * thread-db.c (thread_db_create_event, find_one_thread)
19185 (thread_db_get_tls_address): Use lwpid_of.
19186 * win32-low.c (win32_detach): Adjust to use resume_kind.
19187 (win32_wait): Add `options' argument.
19188 * spu-low.c (spu_resume): Adjust to use resume_kind.
19189 (spu_wait): Add `options' argument.
19191 2009-04-01 Pedro Alves <pedro@codesourcery.com>
19193 Decouple target code from remote protocol.
19195 * target.h (enum target_waitkind): New.
19196 (struct target_waitstatus): New.
19197 (struct target_ops) <wait>: Return an unsigned long. Take a
19198 target_waitstatus pointer instead of a char pointer.
19199 (mywait): Likewise.
19200 * target.c (mywait): Change prototype to return an unsigned long.
19201 Take a target_waitstatus pointer instead of a char pointer. Adjust.
19202 * server.h (thread_from_wait, old_thread_from_wait): Delete
19204 (prepare_resume_reply): Change prototype to take a
19206 * server.c (thread_from_wait, old_thread_from_wait): Delete.
19207 (last_status, last_ptid): New.
19208 (start_inferior): Remove "statusptr" argument. Adjust. Return a
19209 pid instead of a signal.
19210 (attach_inferior): Remove "status" and "signal" parameters.
19212 (handle_query): For qGetTLSAddr, parse the thread id with strtol,
19214 (handle_v_cont, handle_v_attach, handle_v_run, handle_v_kill)
19215 (handle_v_requests, myresume): Remove "status" and "signal"
19216 parameters. Adjust.
19217 (handle_status): New.
19218 (main): Delete local `status'. Adjust.
19219 * remote-utils.c: Include target.h.
19220 (prepare_resume_reply): Change prototype to take a
19221 target_waitstatus. Adjust.
19223 * linux-low.c (linux_wait): Adjust to new target_ops->wait
19225 * spu-low.c (spu_wait): Adjust.
19226 * win32-low.c (enum target_waitkind, struct target_waitstatus):
19228 (win32_wait): Adjust.
19230 2009-04-01 Pedro Alves <pedro@codesourcery.com>
19232 * target.h (struct thread_resume): Delete leave_stopped member.
19233 (struct target_ops): Add a `n' argument to the `resume' callback.
19234 * server.c (start_inferior): Adjust.
19235 (handle_v_cont, myresume): Adjust.
19236 * linux-low.c (check_removed_breakpoint): Adjust to resume
19237 interface change, and to removed leave_stopped field.
19238 (resume_ptr): Delete.
19239 (struct thread_resume_array): New.
19240 (linux_set_resume_request): Add new `arg' parameter. Adjust to
19241 resume interface change.
19242 (linux_continue_one_thread, linux_queue_one_thread)
19243 (resume_status_pending_p): Check if the resume field is NULL
19244 instead of checking the leave_stopped member.
19245 (linux_resume): Adjust to the target resume interface change.
19246 * spu-low.c (spu_resume): Adjust to the target resume interface
19248 * win32-low.c (win32_detach, win32_resume): Ditto.
19250 2009-04-01 Pedro Alves <pedro@codesourcery.com>
19252 * linux-low.c (linux_wait_for_event): Don't clear the `stepping'
19254 (wait_for_sigstop): Don't leave a finished single-step SIGTRAP
19256 (linux_continue_one_thread): Only preserve the stepping flag if
19257 there's a pending breakpoint.
19259 2009-03-31 Pedro Alves <pedro@codesourcery.com>
19261 * server.c (main): After the inferior having exited, call
19262 remote_close before exiting gdbserver.
19264 2009-03-25 Thiago Jung Bauermann <bauerman@br.ibm.com>
19266 Fix size of FPSCR in Power 7 processors.
19267 * linux-ppc-low.c (PPC_FEATURE_ARCH_2_05): Remove #define.
19268 (PPC_FEATURE_HAS_DFP): New #define.
19269 (ppc_arch_setup): Check for DFP feature instead of ISA 2.05 to decide on
19272 2009-03-23 Pedro Alves <pedro@codesourcery.com>
19274 * server.c (handle_query) Whitespace and formatting.
19276 2009-03-22 Pedro Alves <pedro@codesourcery.com>
19278 * i387-fp.c, linux-arm-low.c, linux-cris-low.c,
19279 linux-crisv32-low.c, linux-i386-low.c, linux-low.c,
19280 linux-mips-low.c, linux-s390-low.c, linux-sparc-low.c,
19281 linux-x86-64-low.c, linux-xtensa-low.c, proc-service.c,
19282 regcache.c, remote-utils.c, server.c, spu-low.c, target.h,
19283 thread-db.c, win32-low.c, xtensa-xtregs.c, gdbreplay.c,
19284 Makefile.in, configure.ac: Fix whitespace throughout.
19285 * configure: Regenerate.
19287 2009-03-22 Pedro Alves <pedro@codesourcery.com>
19289 * inferiors.c (find_inferior): Make it safe for the callback
19290 function to delete the currently iterated inferior.
19292 2009-03-22 Pedro Alves <pedro@codesourcery.com>
19294 * Makefile.in (linuw_low_h): Move higher.
19295 (thread-db.o): Depend on $(linux_low_h).
19297 2009-03-17 Pedro Alves <pedro@codesourcery.com>
19299 Rename "process" to "lwp" throughout.
19301 * linux-low.c (all_processes): Rename to...
19302 (all_lwps): ... this.
19303 (inferior_pid, handle_extended_wait, get_stop_pc): Adjust.
19304 (add_process): Rename to ...
19305 (add_lwp): ... this. Adjust.
19306 (linux_create_inferior): Adjust.
19307 (linux_attach_lwp): Adjust.
19308 (linux_attach): Adjust.
19309 (linux_kill_one_process): Rename to ...
19310 (linux_kill_one_lwp): ... this. Adjust.
19311 (linux_kill): Adjust.
19312 (linux_detach_one_process): Rename to ...
19313 (linux_detach_one_lwp): ... this. Adjust.
19314 (linux_detach): Adjust.
19315 (check_removed_breakpoint): Adjust.
19316 (status_pending_p): Adjust.
19317 (linux_wait_for_process): Rename to ...
19318 (linux_wait_for_lwp): ... this. Adjust.
19319 (linux_wait_for_event): Adjust.
19320 (send_sigstop): Adjust.
19321 (wait_for_sigstop): Adjust.
19322 (stop_all_processes): Rename to ...
19323 (stop_all_lwps): ... this.
19324 (linux_resume_one_process): Rename to ...
19325 (linux_resume_one_lwp): ... this. Adjust.
19326 (linux_set_resume_request, linux_continue_one_thread)
19327 (linux_queue_one_thread, resume_status_pending_p)
19328 (usr_store_inferior_registers, regsets_store_inferior_registers)
19329 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
19331 * linux-low.h (get_process): Rename to ...
19332 (get_lwp): ... this. Adjust.
19333 (get_thread_process): Rename to ...
19334 (get_thread_lwp): ... this. Adjust.
19335 (get_process_thread): Rename to ...
19336 (get_lwp_thread): ... this. Adjust.
19337 (struct process_info): Rename to ...
19338 (struct lwp_info): ... this.
19339 (all_processes): Rename to ...
19340 (all_lwps): ... this.
19341 * proc-service.c (ps_lgetregs): Adjust.
19342 * thread-db.c (thread_db_create_event, find_one_thread)
19343 (maybe_attach_thread, thread_db_get_tls_address): Adjust.
19345 2009-03-14 Pedro Alves <pedro@codesourcery.com>
19347 * server.c (handle_query): Handle "qAttached".
19349 2009-03-13 Nathan Sidwell <nathan@codesourcery.com>
19351 * Makefile.in, hostio-errno.c, errno.c, xtensa-xtregs.c: Change to
19352 GPLv3, update license URL.
19354 2009-03-01 Doug Evans <dje@google.com>
19356 * Makefile.in (INCLUDE_CFLAGS): Add -I$(srcdir)/../common.
19357 (server_h): Add gdb_signals.h.
19358 (signals.o): Update.
19359 * server.h (target_signal_from_host,target_signal_to_host_p)
19360 (target_signal_to_host,target_signal_to_name): Moved to gdb_signals.h.
19362 2009-02-14 Pierre Muller <muller@ics.u-strasbg.fr>
19364 * remote-utils.c (getpkt): Also generate remote-debug
19365 information if noack_mode is set.
19367 2009-02-06 Pedro Alves <pedro@codesourcery.com>
19369 * server.c (handle_query): Report qXfer:siginfo:read and
19370 qXfer:siginfo:write as supported and handle them.
19371 * target.h (struct target_ops) <qxfer_siginfo>: New field.
19372 * linux-low.c (linux_xfer_siginfo): New.
19373 (linux_target_ops): Set it.
19375 2009-01-26 Pedro Alves <pedro@codesourcery.com>
19377 * server.c (gdbserver_usage): Mention --remote-debug.
19378 (main): Accept '--remote-debug' switch.
19380 2009-01-18 Doug Evans <dje@google.com>
19382 * regcache.c (new_register_cache): No need to check result of xcalloc.
19383 * server.c (handle_search_memory): Back out calls to xmalloc,
19384 result is checked and error is returned to user upon failure.
19385 (handle_query): Ditto. Add more checks for result of malloc.
19386 (handle_v_cont): Check result of malloc, report error back to
19388 (handle_v_run): Ditto. Call freeargv.
19389 * server.h (freeargv): Declare.
19390 * utils.c (freeargv): New fn.
19392 2009-01-15 Doug Evans <dje@google.com>
19394 * gdbreplay.c (perror_with_name): Make arg const char *.
19395 * server.h (target_signal_to_name): Make return type const char *.
19396 * thread-db.c (thread_db_err_str): Make return type const char *.
19397 * utils.c (perror_with_name): Make arg const char *.
19399 2009-01-14 Pedro Alves <pedro@codesourcery.com>
19401 * win32-low.c (get_child_debug_event): Issue a final DBG_CONTINUE
19402 when handling a EXIT_PROCESS_DEBUG_EVENT.
19404 2009-01-06 Joel Brobecker <brobecker@adacore.com>
19406 * gdbreplay.c (gdbreplay_version): Update copyright year.
19407 * server.c (gdbserver_version): Likewise.
19409 2009-01-05 Doug Evans <dje@google.com>
19411 * linux-low.c (linux_attach_lwp): Add some comments/fixmes.
19412 (handle_extended_wait): Improve comment.
19414 2008-12-13 Doug Evans <dje@google.com>
19416 * utils.c (xmalloc,xcalloc,xstrdup): New fns.
19417 * server.h (ATTR_MALLOC): New macro.
19418 (xmalloc,xcalloc,xstrdup): Declare.
19419 * hostio.c: Replace malloc,calloc,strdup with xmalloc,xcalloc,xstrdup.
19420 * inferiors.c: Ditto.
19421 * linux-low.c: Ditto.
19422 * mem-break.c: Ditto.
19423 * regcache.c: Ditto.
19424 * remote-utils.c: Ditto.
19427 * win32-low.c: Ditto.
19429 2008-12-12 Doug Evans <dje@google.com>
19431 * linux-low.c (linux_wait_for_process): Don't clobber current_inferior
19432 in debugging printf.
19434 * linux-low.c (handle_extended_wait): Simplify, use my_waitpid.
19436 2008-12-09 Doug Evans <dje@google.com>
19438 * linux-low.h (struct process_info): Delete member tid, unused.
19439 * thread-db.c (find_one_thread): Update.
19440 (maybe_attach_thread): Update.
19442 2008-12-02 Pedro Alves <pedro@codesourcery.com>
19444 * target.h (struct target_ops): Add qxfer_osdata member.
19445 * linux-low.c: Include ctype.h and pwd.h and sys/types.h
19447 (linux_qxfer_osdata): New functions.
19448 (linux_target_ops): Register linux_qxfer_osdata as qxfer_osdata
19450 * server.c (handle_query): Handle "qXfer:osdata:read:".
19451 * remote-utils.c (buffer_grow, buffer_free, buffer_init, buffer_finish)
19452 (buffer_xml_printf): New functions.
19453 * server.h (struct buffer): New.
19454 (buffer_grow_str, buffer_grow_str0): New macros.
19455 (buffer_grow, buffer_free, buffer_init, buffer_finish)
19456 (buffer_xml_printf): Declare.
19458 2008-11-24 Doug Evans <dje@google.com>
19460 * Makefile.in (VERSION,DIST,LINT,LINTFLAGS): Delete, unused.
19462 2008-11-24 Daniel Jacobowitz <dan@codesourcery.com>
19464 * server.c (handle_v_run): Always use the supplied argument list.
19466 2008-11-19 Bob Wilson <bob.wilson@acm.org>
19468 * xtensa-xtregs.c (XTENSA_ELF_XTREG_SIZE): Change to 4.
19469 (xtensa_regmap_table): Add entry for scompare1.
19471 2008-11-18 Thiago Jung Bauermann <bauerman@br.ibm.com>
19473 * Makefile.in (powerpc-isa205-32l.o, powerpc-isa205-32l.c,
19474 powerpc-isa205-altivec32l.o, powerpc-isa205-altivec32l.c,
19475 powerpc-isa205-vsx32l.o, powerpc-isa205-vsx32l.c,
19476 powerpc-isa205-64l.o, powerpc-isa205-64l.c,
19477 powerpc-isa205-altivec64l.o, powerpc-isa205-altivec64l.c,
19478 powerpc-isa205-vsx64l.o, powerpc-isa205-vsx64l.c): New targets.
19479 * configure.srv (powerpc*-*-linux*): Add ISA 2.05 object files and
19480 XML target descriptions.
19481 * linux-ppc-low.c (ppc_arch_setup): Init registers with 64-bit FPSCR
19482 when inferior is running on an ISA 2.05 or later processor. Add
19483 special case to return offset for full 64-bit slot of FPSCR when
19486 2008-11-14 Daniel Gutson <dgutson@codesourcery.com>
19488 * Makefile.in (SFILES, clean): Added sparc64 files.
19489 (reg-sparc64.o, reg-sparc64.c): New.
19490 * configure.srv (sparc*-*-linux*): New configuration.
19491 * linux-low.c (regsets_fetch_inferior_registers): Swap ptrace
19492 syscall arguments for SPARC.
19493 (regsets_store_inferior_registers): Likewise.
19494 * linux-sparc-low.c: New file.
19496 2008-10-21 Doug Evans <dje@google.com>
19498 * Makefile.in (BFD_DIR,BFD,BFD_SRC,BFD_CFLAGS): Delete.
19499 (READLINE_DIR,READLINE_DEP): Delete.
19500 (INTERNAL_CFLAGS): Update.
19501 (LINTFLAGS): Update.
19503 2008-10-10 Pedro Alves <pedro@codesourcery.com>
19505 * server.c (handle_v_run): If GDB didn't specify an argv, use the
19506 whole argv from the last run, not just argv[0].
19508 2008-09-08 Pedro Alves <pedro@codesourcery.com>
19510 * regcache.c (new_register_cache): Return NULL if the register
19511 cache size isn't known yet.
19512 (free_register_cache): Avoid dereferencing a NULL regcache.
19514 2008-09-04 Daniel Jacobowitz <dan@codesourcery.com>
19516 * configure.srv: Merge MIPS and MIPS64.
19518 2008-08-24 Maciej W. Rozycki <macro@linux-mips.org>
19520 * Makefile.in (uninstall): Apply $(EXEEXT) too.
19522 2008-08-18 Luis Machado <luisgpm@br.ibm.com>
19524 * Makefile.in: Add required vsx dependencies.
19526 * linux-ppc-low: Define PPC_FEATURE_HAS_VSX.
19527 Declare init_registers_powerpc_vsx32l.
19528 Declare init_registers_powerpc_vsx64l.
19529 Define PTRACE_GETVSXREGS and PTRACE_SETVSXREGS.
19530 (ppc_arch_setup): Check for VSX in hwcap.
19531 (ppc_fill_vsxregset): New function.
19532 (ppc_store_vsxregset): New function.
19533 Add new VSX entry in regset_info target_regsets.
19535 * configure.srv: Add new VSX dependencies.
19537 2008-08-12 Pedro Alves <pedro@codesourcery.com>
19539 * remote-utils.c (noack_mode, transport_is_reliable): New globals.
19540 (remote_open): Set or clear transport_is_reliable.
19541 (putpkt_binary): Don't expect acks in noack mode.
19542 (getpkt): Don't send ack/nac in noack mode.
19543 * server.c (handle_general_set): Handle QStartNoAckMode.
19544 (handle_query): If connected by tcp pass QStartNoAckMode+ in
19546 (main): Reset noack_mode on every connection.
19547 * server.h (noack_mode): Declare.
19549 2008-08-07 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
19551 * Makefile.in (GDBREPLAY_OBS): New variable.
19552 (gdbreplay$(EXEEXT)): Use it to avoid unportable $^.
19554 2008-08-05 Ulrich Weigand <uweigand@de.ibm.com>
19555 Daniel Jacobowitz <dan@codesourcery.com>
19557 * linux-low.c (linux_resume_one_process): Ignore ESRCH.
19558 (usr_store_inferior_registers): Likewise.
19559 (regsets_store_inferior_registers): Likewise.
19561 2008-07-31 Rolf Jansen <rj@surtec.com>
19562 Pedro Alves <pedro@codesourcery.com>
19564 * configure.ac: Check for memmem declaration.
19565 * server.c [HAVE_MALLOC_H]: Include malloc.h.
19566 (disable_packet_vCont, disable_packet_Tthread, disable_packet_qC)
19567 (disable_packet_qfThreadInfo): Unconditionally compile.
19568 * server.h [!HAVE_DECL_MEMMEM]: Declare memmem.
19569 * configure, config.in: Regenerate.
19571 2008-07-28 Doug Kwan <dougkwan@google.com>
19573 * linux-low.c (sys/dir.h, sys/user.h): Remove includes.
19574 (linux_write_memory): Remove declaration of errno.
19576 2008-07-12 Ulrich Weigand <uweigand@de.ibm.com>
19578 * linux-low.c (handle_extended_wait): Do not use "status"
19579 variable uninitialized.
19581 2008-07-07 Pedro Alves <pedro@codesourcery.com>
19583 * server.c (handle_v_attach): Inhibit reporting dll changes.
19585 2008-06-27 Pedro Alves <pedro@codesourcery.com>
19587 * remote-utils.c (prepare_resume_reply): If requested, don't
19588 output "thread:TID" in the T stop reply.
19590 * server.c (disable_packet_vCont, disable_packet_Tthread)
19591 (disable_packet_qC, disable_packet_qfThreadInfo): New globals.
19592 (handle_query): If requested, disable support for qC, qfThreadInfo
19594 (handle_v_requests): If requested, disable support for vCont.
19595 (gdbserver_show_disableable): New.
19596 (main): Handle --disable-packet and --disable-packet=LIST.
19598 * server.h (disable_packet_vCont, disable_packet_Tthread)
19599 (disable_packet_qC, disable_packet_qfThreadInfo): Declare.
19601 2008-06-20 Carlos O'Donell <carlos@codesourcery.com>
19603 * server.c (gdbserver_usage): Mention --version.
19605 2008-06-06 Daniel Jacobowitz <dan@codesourcery.com>
19607 * Makefile.in (gdbreplay.o): New rule.
19609 2008-06-06 Joseph Myers <joseph@codesourcery.com>
19611 * gdbreplay.c (gdbreplay_version): Say gdbreplay in version
19612 message, not gdbserver.
19614 2008-06-05 Vladimir Prus <vladimir@codesourcery.com>
19615 Nathan Sidwell <nathan@codesourcery.com>
19616 Joseph Myers <joseph@codesourcery.com>
19618 * acinclude.m4: Include ../../config/acx.m4.
19619 * configure.ac: Use ACX_PKGVERSION and ACX_BUGURL.
19620 * configure, config.in: Regenerate.
19621 * Makefile.in (gdbreplay$(EXEEXT)): Add version.o.
19622 * server.c (gdbserver_version): Print PKGVERSION.
19623 (gdbsrever_usage): Add stream parameter. Print REPORT_BUGS_TO.
19624 (main): Adjust gdbserver_usage calls.
19625 * gdbreplay.c (version, host_name): Add declarations.
19626 (gdbreplay_version, gdbreplay_usage): New.
19627 (main): Accept --version and --help options.
19629 2008-06-04 Daniel Jacobowitz <dan@codesourcery.com>
19631 * linux-arm-low.c (thumb_breakpoint, thumb_breakpoint_len): New.
19632 (arm_breakpoint_at): Handle Thumb.
19633 (the_low_target): Add comment.
19635 2008-05-29 Ulrich Weigand <uweigand@de.ibm.com>
19637 * linux-ppc-low.c (ppc_collect_ptrace_register): Clear buffer.
19639 2008-05-09 Doug Evans <dje@google.com>
19641 * server.h (decode_search_memory_packet): Declare.
19642 * remote-utils.c (decode_search_memory_packet): New fn.
19643 * server.c (handle_search_memory_1): New fn.
19644 (handle_search_memory): New fn.
19645 (handle_query): Process qSearch:memory packets.
19647 2008-05-08 Ulrich Weigand <uweigand@de.ibm.com>
19649 * regcache.c (registers_length): Remove.
19650 (set_register_cache): Verify that PBUFSIZ is large enough to hold a
19651 full register packet.
19652 * regcache.h (registers_length): Remove prototype.
19653 * server.h (PBUFSIZ): Define to 16384.
19655 2008-05-03 Ulrich Weigand <uweigand@de.ibm.com>
19657 * configure.srv (powerpc*-*-linux*): Set srv_regobj to
19658 powerpc-32l.o, powerpc-altivec32l.o, powerpc-e500l.o,
19659 powerpc-64l.o, and powerpc-altivec64l.o.
19660 Remove rs6000/powerpc-32.xml, rs6000/powerpc-64.xml, and
19661 rs6000/powerpc-e500.xml; add rs6000/powerpc-32l.xml,
19662 rs6000/powerpc-altivec32l.xml, rs6000/powerpc-e500l.xml,
19663 rs6000/powerpc-64l.xml, rs6000/powerpc-altivec64l.xml,
19664 rs6000/power-linux.xml, and rs6000/power64-linux.xml
19667 * Makefile.in (reg-ppc.o, reg-ppc.c): Remove, replace by ...
19668 (powerpc-32l.o, powerpc-32l.c): ... these new rules.
19669 (powerpc-32.o, powerpc-32.c): Remove, replace by ...
19670 (powerpc-altivec32l.o, powerpc-altivec32l.c): ... these new rules.
19671 (powerpc-e500.o, powerpc-e500.c): Remove, replace by ...
19672 (powerpc-e500l.o, powerpc-e500l.c): ... these new rules.
19673 (reg-ppc64.o, reg-ppc64.c): Remove, replace by ...
19674 (powerpc-64l.o, powerpc-64l.c): ... these new rules.
19675 (powerpc-64.o, powerpc-64.c): Remove, replace by ...
19676 (powerpc-altivec64l.o, powerpc-altivec64l.c): ... these new rules.
19679 * linux-ppc-low.c (init_registers_ppc): Remove, replace by ...
19680 (init_registers_powerpc_32l): ... this new prototype.
19681 (init_registers_powerpc_32): Remove, replace by ...
19682 (init_registers_powerpc_altivec32l): ... this new prototype.
19683 (init_registers_powerpc_e500): Remove, replace by ...
19684 (init_registers_powerpc_e500l): ... this new prototype.
19685 (init_registers_ppc64): Remove, replace by ...
19686 (init_registers_powerpc_64l): ... this new prototype.
19687 (init_registers_powerpc_64): Remove, replace by ...
19688 (init_registers_powerpc_altivec64l): ... this new prototype.
19689 (ppc_num_regs): Set to 73.
19690 (PT_ORIG_R3, PT_TRAP): Define if necessary.
19691 (ppc_regmap, ppc_regmap_e500): Add values for orig_r3 and trap.
19692 (ppc_cannot_store_register): Handle orig_r3 and trap.
19693 (ppc_arch_setup): Update init_registers_... calls.
19694 (ppc_fill_gregset): Handle orig_r3 and trap.
19696 * inferiors.c (clear_inferiors): Reset current_inferior.
19698 2008-04-23 Paolo Bonzini <bonzini@gnu.org>
19700 * acinclude.m4: Add override.m4.
19701 * configure: Regenerate.
19703 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
19705 * linux-ppc-low.c (ppc_arch_setup): Reset ppc_hwcap after the
19706 initial call to init_register_ppc64.
19708 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
19710 * configure.srv (powerpc64-*-linux*, powerpc-*-linux*): Merge into
19711 single powerpc*-*-linux* case.
19712 (s390-*-linux*, s390x-*-linux*): Merge into single s390*-*-linux* case.
19714 2008-04-17 Ulrich Weigand <uweigand@de.ibm.com>
19716 * configure.srv [powerpc64-*-linux*]: Remove powerpc-e500.o from
19717 srv_regobj. Remove rs6000/powerpc-e500.xml and rs6000/power-spe.xml
19719 * linux-ppc-low.c: Include <elf.h>.
19720 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Define.
19721 (ppc_hwcap): New global variable.
19722 (ppc_regmap): Remove __SPE__ #ifdef sections.
19723 (ppc_regmap_e500): New global variable.
19724 (ppc_cannot_store_register): Update __SPE__ special case.
19725 (ppc_get_hwcap): New function.
19726 (ppc_arch_setup): Use it to determine whether inferior supports
19727 AltiVec or SPE registers. Set the_low_target.regmap if appropriate.
19728 (ppc_fill_vrregset, ppc_store_vrregset): Define unconditionally.
19729 Do not access registers if target does not support AltiVec.
19730 (ppc_fill_evrregset, ppc_store_evrregset): Define unconditionally.
19731 Do not access registers if target does not support SPE.
19732 (target_regsets): Unconditionally include AltiVec and SPE regsets.
19734 2008-04-17 Daniel Jacobowitz <dan@codesourcery.com>
19736 * linux-low.c (disabled_regsets, num_regsets): New.
19737 (use_regsets_p): Delete.
19738 (linux_wait_for_process): Clear disabled_regsets.
19739 (regsets_fetch_inferior_registers): Check and set it.
19740 (regsets_store_inferior_registers): Likewise.
19741 (linux_fetch_registers, linux_store_registers): Do not use
19743 (initialize_low): Allocate disabled_regsets.
19745 2008-04-14 Daniel Jacobowitz <dan@codesourcery.com>
19747 * Makefile.in (LIBOBJS): New.
19748 (OBS): Use LIBOBJS.
19749 (memmem.o): New rule.
19750 * configure.ac: Use AC_CONFIG_LIBOBJ_DIR and check for memmem.
19751 * configure: Regenerated.
19753 2008-04-04 Ulrich Weigand <uweigand@de.ibm.com>
19755 * server.c (handle_query): Never return "unsupported" for
19756 qXfer:features:read queries.
19758 2008-03-27 Ulrich Weigand <uweigand@de.ibm.com>
19760 * server.c (get_features_xml): Fix inverted condition.
19761 (handle_query): Always support qXfer:feature:read.
19763 2008-03-10 Daniel Jacobowitz <dan@codesourcery.com>
19765 * server.c (wrapper_argv): New.
19766 (start_inferior): Handle wrapper_argv. If set, expect an extra
19768 (gdbserver_usage): Document --wrapper.
19769 (main): Parse --wrapper.
19771 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
19773 * configure.srv [powerpc64-*-linux*]: Add all files mentioned for
19774 powerpc-*-linux* to srv_regobj and reg_xmlfiles.
19775 * linux-ppc-low.c (ppc_get_pc): Support bi-arch operation.
19776 (ppc_set_pc): Likewise.
19777 (ppc_arch_setup): New function.
19778 (ppc_fill_gregset): Call ppc_collect_ptrace_register instead
19779 of collect_register.
19780 (the_low_target): Use ppc_arch_setup as arch_setup initializer.
19782 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
19784 * configure.srv [powerpc64-*-linux*]: Use linux-ppc-low.o
19785 instead of linux-ppc64-low.o.
19786 * linux-ppc64-low.c: Remove file.
19787 * Makefile.in (SFILES): Remove linux-ppc64-low.c.
19788 (linux-ppc64-low.o): Remove rule.
19790 * linux-ppc-low.c (init_registers_ppc64): Add prototype.
19791 (init_registers_powerpc_64): Likewise.
19792 (ppc_regmap): Conditionally define depending on __powerpc64__.
19793 (ppc_cannot_store_register): Do not special-case "fpscr" when
19794 compiled on __powerpc64__.
19795 (ppc_collect_ptrace_register): New function.
19796 (ppc_supply_ptrace_register): New function.
19797 (ppc_breakpoint): Change type to "unsigned int".
19798 (ppc_breakpoint_at): Change type of "insn" to "unsigned int".
19799 (the_low_target): Conditionally provide initializers for the
19800 arch_setup member depending on __powerpc64__. Install
19801 collect_ptrace_register and supply_ptrace_register members.
19803 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
19805 * regcache.h (gdbserver_xmltarget): Add extern declaration.
19806 * server.c (gdbserver_xmltarget): Define.
19807 (get_features_xml): Use it to replace "target.xml" and arch_string.
19809 * configure.srv: Remove srv_xmltarget. Add XML files that were
19810 mentioned there to srv_xmlfiles instead. Remove conditional tests
19811 on gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe; set
19812 srv_xmlfiles and srv_regobj to include all possible choices.
19813 * configure.ac (srv_xmltarget): Remove.
19814 (srv_xmlfiles): Do not add "target.xml".
19815 (gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe): Remove
19816 checks for supplementary target information.
19817 * configure: Regenerate.
19818 * Makefile.in (XML_TARGET): Remove.
19819 (target.xml): Remove rule.
19820 (clean): Do not clean up target.xml.
19821 (.PRECIOUS): Do not mention target.xml.
19823 * target.h (struct target_ops): Remove arch_string member.
19824 * linux-low.c (linux_arch_string): Remove.
19825 (linux_target_ops): Remove arch_string initializer.
19826 * linux-low.h (struct linux_target_ops): Remove arch_string member.
19827 * linux-i386-low.c (the_low_target): Remove arch_string initializer.
19828 * linux-x86-64-low.c (the_low_target): Remove arch_string initializer.
19829 * spu-low.c (spu_arch_string): Remove.
19830 (spu_target_ops): Remove arch_string initializer.
19831 * win32-low.c (win32_arch_string): Remove.
19832 (win32_target_ops): Remove arch_string initializer.
19833 * win32-low.h (struct win32_target_ops): Remove arch_string member.
19834 * win32-arm-low.c (the_low_target): Remove arch_string initializer.
19835 * win32-i368-low.c (the_low_target): Remove arch_string initializer.
19837 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
19839 * linux-low.h (struct linux_target_ops): Replace left_pad_xfer field
19840 by collect_ptrace_register and supply_ptrace_register hooks.
19841 * linux-low.c (fetch_register): Use supply_ptrace_register callback
19842 instead of checking for the_low_target.left_pad_xfer.
19843 (usr_store_inferior_registers): Use collect_ptrace_register callback
19844 instead of checking for the_low_target.left_pad_xfer.
19846 * linux-s390-low.c (s390_collect_ptrace_register): New function.
19847 (s390_supply_ptrace_register): Likewise.
19848 (s390_fill_gregset): Call s390_collect_ptrace_register.
19849 (the_low_target): Update.
19851 * linux-ppc64-low.c (ppc_collect_ptrace_register): New function.
19852 (ppc_supply_ptrace_register): Likewise.
19853 (the_low_target): Update.
19855 * linux-i386-low.c (the_low_target): Update.
19856 * linux-x86-64-low.c (the_low_target): Update.
19858 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
19860 * configure.srv [s390x-*-linux*]: Set srv_regobj to include both
19861 reg-s390.o and reg-s390x.o.
19863 * linux-low.c (new_inferior): New global variable.
19864 (linux_create_inferior, linux_attach): Set it.
19865 (linux_wait_for_process): Call the_low_target.arch_setup after the
19866 target has stopped for the first time.
19867 (initialize_low): Do not call the_low_target.arch_setup.
19869 * linux-s390-low.c (s390_get_pc): Support bi-arch operation.
19870 (s390_set_pc): Likewise.
19871 (s390_arch_setup): New function.
19872 (the_low_target): Use s390_arch_setup as arch_setup routine.
19874 * regcache.c (realloc_register_cache): New function.
19875 (set_register_cache): Call it for each existing regcache.
19877 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
19879 * server.h (init_registers): Remove prototype.
19881 * linux-low.h (struct linux_target_ops): Add arch_setup field.
19882 * linux-low.c (initialize_low): Call the_low_target.arch_setup ()
19883 instead of init_registers ().
19884 * linux-arm-low.c (init_registers_arm): Add prototype.
19885 (init_registers_arm_with_iwmmxt): Likewise.
19886 (the_low_target): Add initializer for arch_setup field.
19887 * linux-cris-low.c (init_registers_cris): Add prototype.
19888 (the_low_target): Add initializer for arch_setup field.
19889 * linux-crisv32-low.c (init_registers_crisv32): Add prototype.
19890 (the_low_target): Add initializer for arch_setup field.
19891 * linux-i386-low.c (init_registers_i386_linux): Add prototype.
19892 (the_low_target): Add initializer for arch_setup field.
19893 * linux-ia64-low.c (init_registers_ia64): Add prototype.
19894 (the_low_target): Add initializer for arch_setup field.
19895 * linux-m32r-low.c (init_registers_m32r): Add prototype.
19896 (the_low_target): Add initializer for arch_setup field.
19897 * linux-m68k-low.c (init_registers_m68k): Add prototype.
19898 (the_low_target): Add initializer for arch_setup field.
19899 * linux-mips-low.c (init_registers_mips_linux): Add prototype.
19900 (init_registers_mips64_linux): Likewise.
19901 (the_low_target): Add initializer for arch_setup field.
19902 * linux-ppc-low.c (init_registers_ppc): Add prototype.
19903 (init_registers_powerpc_32, init_registers_powerpc_e500): Likewise.
19904 (the_low_target): Add initializer for arch_setup field.
19905 * linux-ppc64-low.c (init_registers_ppc64): Add prototype.
19906 (init_registers_powerpc_64): Likewise.
19907 (the_low_target): Add initializer for arch_setup field.
19908 * linux-s390-low.c (init_registers_s390): Add prototype.
19909 (init_registers_s390x): Likewise.
19910 (the_low_target): Add initializer for arch_setup field.
19911 * linux-sh-low.c (init_registers_sh): Add prototype.
19912 (the_low_target): Add initializer for arch_setup field.
19913 * linux-x86-64-low.c (init_registers_x86_64_linux): Add prototype.
19914 (the_low_target): Add initializer for arch_setup field.
19915 * linux-xtensa-low.c (init_registers_xtensa): Add prototype.
19916 (the_low_target): Add initializer for arch_setup field.
19918 * win32-low.h (struct win32_target_ops): Add arch_setup field.
19919 * win32-low.c (initialize_low): Call the_low_target.arch_setup ()
19920 instead of init_registers ().
19921 * win32-arm-low.c (init_registers_arm): Add prototype.
19922 (the_low_target): Add initializer for arch_setup field.
19923 * win32-i386-low.c (init_registers_i386): Add prototype.
19924 (the_low_target): Add initializer for arch_setup field.
19926 * spu-low.c (init_registers_spu): Add prototype.
19927 (initialize_low): Call initialie_registers_spu () instead of
19928 initialize_registers ().
19930 2008-02-19 Pedro Alves <pedro@codesourcery.com>
19932 * server.c (handle_v_requests): When handling the vRun and vAttach
19933 packets, if already debugging a process, don't kill it. Return an
19936 2008-02-17 Daniel Jacobowitz <dan@codesourcery.com>
19938 * server.c (handle_query): Correct length check.
19940 2008-02-14 Pedro Alves <pedro_alves@portugalmail.pt>
19942 * win32-low.c (do_initial_child_stuff): Add process handle
19943 parameter. Set current_process_handle and current_process_id from the
19944 parameters. Clear globals.
19945 (win32_create_inferior): Don't set current_process_handle and
19946 current_process_id here. Instead pass them on the call to
19947 do_initial_child_stuff.
19948 (win32_attach): Likewise.
19949 (win32_clear_inferiors): New.
19950 (win32_kill): Don't close the current process handle or the
19951 current thread handle here. Instead call win32_clear_inferiors.
19952 (win32_detach): Don't open a new handle to the process. Call
19953 win32_clear_inferiors.
19954 (win32_join): Don't rely on current_process_handle; open a new
19955 handle using the process id.
19956 (win32_wait): Call win32_clear_inferiors when the inferior process
19959 2008-02-14 Daniel Jacobowitz <dan@codesourcery.com>
19961 * server.c (monitor_show_help): Add "exit".
19963 2008-02-11 Maxim Grigoriev <maxim2405@gmail.com>
19965 * Makefile.in (SFILES): Add linux-xtensa-low.c.
19966 (clean): Add reg-xtensa.c.
19967 (linux-xtensa-low.o, reg-xtensa.o, reg-xtensa.c): New dependencies.
19968 * configure.srv (xtensa*-*-linux*) New target.
19969 * linux-xtensa-low.c: New.
19970 * xtensa-xtregs.c: New.
19972 2008-02-01 Pedro Alves <pedro_alves@portugalmail.pt>
19974 * hostio.c: Don't include errno.h.
19975 (errno_to_fileio_errno): Move to hostio-errno.
19976 * hostio.c: (hostio_error): Remove the error parameter. Defer the
19977 error number outputting to the target->hostio_last_error callback.
19978 (hostio_packet_error): Use FILEIO_EINVAL directly.
19979 (handle_open, handle_pread, hostio_error, handle_unlink): Update
19980 calls to hostio_error.
19981 * hostio-errno.c: New.
19982 * server.h (hostio_last_error_from_errno): Declare.
19983 * target.h (target_ops): Add hostio_last_error member.
19984 * linux-low.c (linux_target_op): Register hostio_last_error_from_errno
19985 as hostio_last_error handler.
19986 * spu-low.c (spu_target_ops): Likewise.
19987 * win32-low.c [_WIN32_WCE] (win32_error_to_fileio_error)
19988 (wince_hostio_last_error): New functions.
19989 (win32_target_ops) [_WIN32_WCE]: Register wince_hostio_last_error
19990 as hostio_last_error handler.
19991 (win32_target_ops) [!_WIN32_WCE]: Register
19992 hostio_last_error_from_errno as hostio_last_error handler.
19993 * Makefile.in (SFILES): Add hostio.c and hostio-errno.c.
19994 (hostio-errno.o): New rule.
19995 * configure.ac (GDBSERVER_DEPFILES): Add $srv_hostio_err_objs.
19996 * configure.srv (srv_hostio_err_objs): New variable. Default to
19998 (arm*-*-mingw32ce*): Set srv_hostio_err_objs to "".
19999 * configure: Regenerate.
20001 2008-01-29 Daniel Jacobowitz <dan@codesourcery.com>
20003 * linux-low.c (linux_attach_lwp): Do not _exit after errors.
20004 (linux_kill, linux_detach): Clean up the process list.
20005 * remote-utils.c (remote_open): Improve port number parsing.
20006 (putpkt_binary, input_interrupt): Only send interrupts if the target
20008 * server.c (extended_protocol): Make static.
20009 (attached): Define earlier.
20010 (exit_requested, response_needed, program_argv): New variables.
20011 (target_running): New.
20012 (start_inferior): Clear attached here.
20013 (attach_inferior): Set attached here.
20014 (require_running): Define.
20015 (handle_query): Use require_running and target_running. Implement
20017 (handle_v_attach, handle_v_run): New.
20018 (handle_v_requests): Use require_running. Handle vAttach and vRun.
20019 (gdbserver_usage): Update.
20020 (main): Redo argument parsing. Handle --debug and --multi. Handle
20021 --attach along with other options or after the port. Save
20022 program_argv. Support no initial program. Resynchronize
20023 communication with GDB after an error. Handle "monitor exit".
20024 Use require_running and target_running. Always allow the extended
20025 protocol. Do not error out for Hc0 or Hc-1. Do not automatically
20026 restart in extended mode.
20027 * README: Refer to the GDB manual. Update --attach usage.
20029 2007-12-20 Andreas Schwab <schwab@suse.de>
20031 * linux-low.c (STACK_SIZE): Define.
20032 (linux_tracefork_child): Use it. Use __clone2 on ia64.
20033 (linux_test_for_tracefork): Likewise.
20035 2007-12-18 Daniel Jacobowitz <dan@codesourcery.com>
20037 * linux-low.c (linux_wait_for_event): Update messages. Do not
20038 reinsert auto-delete breakpoints.
20039 * mem-break.c (struct breakpoint): Change return type of handler to
20041 (set_breakpoint_at): Update handler type.
20042 (reinsert_breakpoint_handler): Return 1 instead of calling
20044 (reinsert_breakpoint_by_bp): Check for the original breakpoint before
20046 (check_breakpoints): Delete auto-delete breakpoints and return 2.
20047 * mem-break.h (set_breakpoint_at): Update handler type.
20048 * thread-db.c (thread_db_create_event, thread_db_create_event): Update.
20049 * win32-low.c (auto_delete_breakpoint): New.
20050 (get_child_debug_event): Use it.
20052 2007-12-16 Daniel Jacobowitz <dan@codesourcery.com>
20054 * configure.ac: Check for pread and pwrite.
20055 * hostio.c (handle_pread): Fall back to lseek and read.
20056 (handle_pwrite): Fall back to lseek and write.
20057 * config.in, configure: Regenerated.
20059 2007-12-07 Daniel Jacobowitz <dan@codesourcery.com>
20061 * server.c (myresume): Add own_buf argument.
20062 (main): Update calls.
20064 2007-12-06 Daniel Jacobowitz <dan@codesourcery.com>
20066 * linux-low.c (linux_wait, linux_resume): Do not handle async I/O.
20067 * remote-utils.c (remote_open): Do not call disable_async_io.
20068 (block_async_io): Delete.
20069 (unblock_async_io): Make static.
20070 (initialize_async_io): New.
20071 * server.c (handle_v_cont): Handle async I/O here.
20072 (myresume): Likewise. Move other common resume tasks here...
20073 (main): ... from here. Call initialize_async_io. Disable async
20074 I/O before the main loop.
20075 * server.h (initialize_async_io): Declare.
20076 (block_async_io, unblock_async_io): Delete prototypes.
20077 * spu-low.c (spu_resume, spu_wait): Do not handle async I/O here.
20079 2007-12-06 Mick Davis <mickd@goanna.iinet.net.au>
20081 * remote-utils.c (readchar): Allow binary data in received messages.
20083 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
20085 * win32-low.c (attaching): New global.
20086 (win32_create_inferior): Clear the `attaching' global.
20087 (win32_attach): Set the `attaching' global.
20088 (get_child_debug_event) [_WIN32_WCE]: Stop the inferior when
20089 attaching. Only set a breakpoint at the entry point if not
20092 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
20094 * server.c (main): Don't report dll events on the initial
20095 connection on attaches.
20097 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
20099 * server.c (main): Relax numerical bases supported for the pid of
20100 the --attach command line argument.
20102 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
20104 * win32-low.c (win32_attach): Call OpenProcess before
20105 DebugActiveProcess, not after. Add last error output to error
20108 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
20110 * win32-low.c (win32_get_thread_context)
20111 (win32_set_thread_context): New functions.
20112 (thread_rec): Use win32_get_thread_context.
20113 (continue_one_thread, win32_resume): Use win32_set_thread_context.
20114 * win32-low.h (win32_thread_info) [_WIN32_WCE]: Add `base_context'
20117 2007-12-03 Leo Zayas
20118 Pedro Alves <pedro_alves@portugalmail.pt>
20120 * win32-low.c (soft_interrupt_requested, faked_breakpoint): New
20122 (child_add_thread): Minor cleanup.
20123 (child_continue): Resume artificially suspended threads before
20124 calling ContinueDebugEvent.
20125 (suspend_one_thread): New.
20126 (fake_breakpoint_event): New.
20127 (get_child_debug_event): Change return type to int. Check here if
20128 gdb sent an interrupt request. If a soft interrupt was requested,
20129 fake a breakpoint event. Return 0 if there is no event to handle,
20131 (win32_wait): Don't check here if gdb sent an interrupt request.
20132 Ensure there is a valid event to handle.
20133 (win32_request_interrupt): Add soft interruption method as last
20136 2007-12-03 Leo Zayas
20137 Pedro Alves <pedro_alves@portugalmail.pt>
20139 * win32-low.h (win32_thread_info): Add descriptions to the
20140 structure members. Replace `suspend_count' counter by a
20142 * win32-low.c (thread_rec): Update condition of when to get the
20143 context from the inferior. Rely on ContextFlags being set if it
20144 has already been retrieved. Only suspend the inferior thread if
20145 we haven't already. Warn if that fails.
20146 (continue_one_thread): s/suspend_count/suspended/. Only call
20147 ResumeThread once. Warn if that fails.
20149 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
20151 * win32-low.c (win32_wait): Don't read from the inferior when it
20152 has already exited.
20154 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
20156 * Makefile.in (win32_low_h): New variable.
20157 (win32-low.o): Add dependency on $(win32_low_h).
20158 (win32-arm-low.o, win32-i386-low.o): New rules.
20160 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
20162 * hostio.c: Correct copyright year.
20164 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
20166 * Makefile.in (OBS): Add hostio.o.
20167 (hostio.o): New rule.
20168 * server.h (handle_vFile): Declare.
20169 * hostio.c: New file.
20170 * server.c (handle_v_requests): Take packet_len and new_packet_len
20171 for binary packets. Call handle_vFile.
20172 (main): Update call to handle_v_requests.
20174 2007-11-05 Daniel Jacobowitz <dan@codesourcery.com>
20176 * linux-low.c: Include <sched.h>.
20178 2007-11-01 Daniel Jacobowitz <dan@codesourcery.com>
20180 * linux-low.c (linux_tracefork_grandchild): New.
20181 (linux_tracefork_child): Use clone.
20182 (linux_test_for_tracefork): Use clone; allocate and free a stack.
20184 2007-10-31 Joel Brobecker <brobecker@adacore.com>
20186 * Makefile.in: Use $(SHELL) instead of "sh" to call regdat.sh.
20188 2007-10-24 Daniel Jacobowitz <dan@codesourcery.com>
20190 * linux-low.c (handle_extended_wait): Handle unexpected signals.
20192 2007-10-23 Daniel Jacobowitz <dan@codesourcery.com>
20194 * inferiors.c (change_inferior_id): Delete.
20195 (add_pid_to_list, pull_pid_from_list): New.
20196 * linux-low.c (PTRACE_SETOPTIONS, PTRACE_GETEVENTMSG)
20197 (PTRACE_O_TRACESYSGOOD, PTRACE_O_TRACEFORK, PTRACE_O_TRACEVFORK)
20198 (PTRACE_O_TRACECLONE, PTRACE_O_TRACEEXEC, PTRACE_O_TRACEVFORKDONE)
20199 (PTRACE_O_TRACEEXIT, PTRACE_EVENT_FORK, PTRACE_EVENT_VFORK)
20200 (PTRACE_EVENT_CLONE, PTRACE_EVENT_EXEC, PTRACE_EVENT_VFORK_DONE)
20201 (PTRACE_EVENT_EXIT, __WALL): Provide default definitions.
20202 (stopped_pids, thread_db_active, must_set_ptrace_flags): New variables.
20203 (using_threads): Always set to 1.
20204 (handle_extended_wait): New.
20205 (add_process): Do not set TID.
20206 (linux_create_inferior): Set must_set_ptrace_flags.
20207 (linux_attach_lwp): Remove TID argument. Do not check using_threads.
20208 Use PTRACE_SETOPTIONS. Call new_thread_notify. Update all callers.
20209 (linux_thread_alive): Rename TID argument to LWPID.
20210 (linux_wait_for_process): Handle unknown processes. Do not use TID.
20211 (linux_wait_for_event): Do not use TID or check using_threads. Update
20212 call to dead_thread_notify. Call handle_extended_wait.
20213 (linux_create_inferior): Use PTRACE_SETOPTIONS.
20214 (send_sigstop): Delete sigstop_sent.
20215 (wait_for_sigstop): Avoid TID.
20216 (linux_supports_tracefork_flag, linux_tracefork_child, my_waitpid)
20217 (linux_test_for_tracefork): New.
20218 (linux_lookup_signals): Use thread_db_active and
20219 linux_supports_tracefork_flag.
20220 (initialize_low): Use thread_db_active and linux_test_for_tracefork.
20221 * linux-low.h (get_process_thread): Avoid TID.
20222 (struct process_ifo): Move thread_known and tid to the end. Remove
20224 (linux_attach_lwp, thread_db_init): Update prototypes.
20225 * server.h (change_inferior_id): Delete prototype.
20226 (add_pid_to_list, pull_pid_from_list): New prototypes.
20227 * thread-db.c (thread_db_use_events): New.
20228 (find_first_thread): Rename to...
20229 (find_one_thread): ...this. Update callers and messages. Do not
20230 call fatal. Check thread_db_use_events. Do not call
20231 change_inferior_id or new_thread_notify.
20232 (maybe_attach_thread): Update. Do not call new_thread_notify.
20233 (thread_db_init): Set thread_db_use_events. Check use_events.
20234 * utils.c (fatal, warning): Correct message prefix.
20236 2007-10-15 Daniel Jacobowitz <dan@codesourcery.com>
20238 * Makefile.in (clean): Remove new files.
20239 (powerpc-32.o, powerpc-32.c, powerpc-e500.o, powerpc-e500.c)
20240 (powerpc-64.o, powerpc-64.c): New rules.
20241 * configure.srv: Use alternate register sets for powerpc64-*-linux*
20242 with AltiVec, powerpc-*-linux* with AltiVec, and powerpc-*-linux*
20244 * linux-ppc-low.c (ppc_regmap): Do not fetch the FP registers for
20246 (ppc_cannot_store_register): Do not check for FPSCR for SPE targets.
20247 (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS, ppc_fill_vrregset)
20248 (ppc_store_vrregset, PTRACE_GETEVRREGS, PTRACE_SETEVRREGS)
20249 (struct gdb_evrregset_t, ppc_fill_evrregset, ppc_store_evrregset): New.
20250 (target_regsets): Add AltiVec and SPE register sets.
20251 * configure.ac: Check for AltiVec and SPE.
20252 * linux-ppc64-low.c (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS)
20253 (ppc_fill_vrregset, ppc_store_vrregset): New.
20254 (target_regsets): Add AltiVec register set.
20255 * configure: Regenerated.
20257 2007-09-19 Daniel Jacobowitz <dan@codesourcery.com>
20259 * linux-low.c (O_LARGEFILE): Define.
20260 (linux_read_memory): Use /proc/PID/mem.
20261 * configure.ac: Use AC_GNU_SOURCE. Check for pread64.
20262 * configure, config.in: Regenerated.
20264 2007-09-04 Daniel Jacobowitz <dan@codesourcery.com>
20266 * linux-low.c (linux_wait_for_event): Do not pass signals while
20269 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
20271 * win32-low.c (create_process): New.
20272 (win32_create_inferior): Use create_process instead of
20273 CreateProcess. If create_process failed retry appending an ".exe"
20274 suffix. Store the GetLastError result immediatelly after
20275 create_process calls and use it on the call to error.
20277 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
20279 * win32-low.c (handle_load_dll): Don't use toolhelp when waiting.
20281 2007-08-23 Joel Brobecker <brobecker@adacore.com>
20283 * configure.ac: Switch license to GPLv3.
20285 2007-08-01 Michael Snyder <msnyder@access-company.com>
20287 * remote-utils.c (putpkt_binary): Memory leak, free buf2.
20289 2007-07-31 Pedro Alves <pedro_alves@portugalmail.pt>
20291 * win32-low.c (winapi_CloseToolhelp32Snapshot) [_WIN32_WCE]: New
20293 (win32_CloseToolhelp32Snapshot) [_WIN32_WCE]: New global var.
20294 (load_toolhelp) [_WIN32_WCE]: Load TOOLHELP.DLL. Get
20295 CloseToolhelp32Snapshot.
20296 (toolhelp_get_dll_name) [_WIN32_WCE]: Close the snapshot with
20297 CloseToolhelp32Snapshot.
20299 2007-07-27 Michael Snyder <michael.snyder@access-company.com>
20301 * server.c (main): Check for inferior exit before main loop.
20303 2007-07-18 Pedro Alves <pedro_alves@portugalmail.pt>
20305 * remote-utils.c (remote_open): Set SO_KEEPALIVE on remote_desc
20306 instead of on tmp_desc.
20308 2007-07-17 Pedro Alves <pedro_alves@portugalmail.pt>
20309 Daniel Jacobowitz <dan@codesourcery.com>
20311 * inferiors.c (all_dlls, dlls_changed, get_dll): New.
20312 (add_thread): Minor cleanups.
20313 (clear_inferiors): Move lower in the file. Clear the DLL
20315 (free_one_dll, match_dll, loaded_dll, unloaded_dll, clear_list): New.
20316 * remote-utils.c (prepare_resume_reply): Check dlls_changed.
20317 (xml_escape_text): New.
20318 * server.c (handle_query): Handle qXfer:libraries:read. Report it
20320 (handle_v_cont): Report errors.
20321 (gdbserver_version): Update.
20322 (main): Correct size of own_buf. Do not report initial DLL events.
20323 * server.h (struct dll_info, all_dlls, dlls_changed, loaded_dll)
20324 (unloaded_dll, xml_escape_text): New.
20325 * win32-low.c (enum target_waitkind): Update comments.
20326 (win32_add_one_solib, get_image_name, winapi_EnumProcessModules)
20327 (winapi_GetModuleInformation, winapi_GetModuleFileNameExA)
20328 (win32_EnumProcessModules, win32_GetModuleInformation)
20329 (win32_GetModuleFileNameExA, load_psapi, psapi_get_dll_name)
20330 (winapi_CreateToolhelp32Snapshot, winapi_Module32First)
20331 (winapi_Module32Next, win32_CreateToolhelp32Snapshot)
20332 (win32_Module32First, win32_Module32Next, load_toolhelp)
20333 (toolhelp_get_dll_name, handle_load_dll, handle_unload_dll): New.
20334 (get_child_debug_event): Handle DLL events.
20335 (win32_wait): Likewise.
20337 2007-07-12 Daniel Jacobowitz <dan@codesourcery.com>
20339 * configure.srv: Set srv_linux_regsets for sh*-*-linux*.
20340 * linux-sh-low.c (sh_fill_gregset, target_regsets): New.
20342 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
20344 * win32-low.c (handle_output_debug_string): Ignore event if not
20347 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
20349 * win32-arm-low.c (arm_wince_breakpoint): Fix typo.
20351 2007-07-03 Daniel Jacobowitz <dan@codesourcery.com>
20353 * remote-utils.c (look_up_one_symbol): Handle 'm' packets.
20355 2007-07-02 Daniel Jacobowitz <dan@codesourcery.com>
20357 * inferiors.c (change_inferior_id): Add comment.
20358 * linux-low.c (check_removed_breakpoint): Add an early
20359 prototype. Improve debug output.
20360 (linux_attach): Doc update.
20361 (linux_detach_one_process, linux_detach): Clean up before releasing
20363 (send_sigstop, wait_for_sigstop): Improve comments and debug output.
20364 * linux-low.h (struct process_info): Doc improvement.
20365 * mem-break.c (delete_all_breakpoints): New.
20366 * mem-break.h (delete_all_breakpoints): New prototype.
20367 * thread-db.c (find_first_thread): New.
20368 (thread_db_create_event): Call it instead of
20369 thread_db_find_new_threads. Clean up unused variables.
20370 (maybe_attach_thread): Remove first thread handling.
20371 (thread_db_find_new_threads): Use find_first_thread.
20372 (thread_db_get_tls_address): Likewise.
20374 2007-06-27 Daniel Jacobowitz <dan@codesourcery.com>
20376 * thread-db.c (thread_db_find_new_threads): Add prototype.
20377 (thread_db_create_event): Check for the main thread before adding
20379 (maybe_attach_thread): Only enable event reporting if TID == 0.
20380 (thread_db_get_tls_address): Check for new threads.
20382 2007-06-20 Daniel Jacobowitz <dan@codesourcery.com>
20384 * linux-low.c (linux_create_inferior): Try execv before execvp.
20385 * spu-low.c (spu_create_inferior): Likewise.
20387 2007-06-13 Mike Frysinger <vapier@gentoo.org>
20389 * linux-low.c (linux_create_inferior): Change execv to execvp.
20390 * spu-low.c (spu_create_inferior): Likewies.
20392 2007-06-13 Daniel Jacobowitz <dan@codesourcery.com>
20394 * Makefile.in (clean): Clean new files instead of deleted ones.
20395 (reg-mips.o, reg-mips.c, reg-mips64.o, reg-mips64.c): Delete.
20396 (mips-linux.o, mips-linux.c, mips64-linux.o, mips64-linux.c): New
20398 * configure.srv: Specify XML files and new regformats for MIPS and
20400 * linux-mips-low.c (mips_num_regs): Set to only used registers.
20401 (mips_regmap): Do not fetch $0. Remove unused registers. Add
20402 an entry for the restart register.
20403 (mips_cannot_fetch_register, mips_cannot_store_register)
20404 (mips_reinsert_addr, mips_fill_fpregset, mips_store_fpregset): Update
20405 register names to match the XML descriptions.
20406 (mips_fill_gregset, mips_store_gregset): Likewise. Handle the
20407 restart register instead of $0.
20409 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
20410 Markus Deuling <deuling@de.ibm.com>
20412 * remote-utils.c (decode_xfer_write): New function.
20413 * server.h (decode_xfer_write): Add prototype.
20414 * server.c (handle_query): Add PACKET_LEN argument. Support
20415 qXfer:spu:read and qXfer:spu:write packets.
20416 (main): Pass packet_len to handle_query.
20417 * spu-low.c (spu_target_ops): Add spu_proc_xfer_spu.
20418 * target.h (target_ops): Add qxfer_spu.
20420 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
20422 * spu-low.c (spu_proc_xfer_spu): Do not return failure when
20423 accessing non-seekable spufs files.
20425 2007-05-16 Markus Deuling <deuling@de.ibm.com>
20427 * server.c (handle_query): Add reply for qC packet.
20429 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20430 Leo Zayas <lerele@champenstudios@com>
20432 * server.h (check_remote_input_interrupt_request): New function.
20433 * remote_utils.c (INVALID_DESCRIPTOR): New define.
20434 (remote_desc): Initialize with INVALID_DESCRIPTOR.
20435 (input_interrupt): Expose on USE_WIN32API too. Fix whitespace.
20436 (check_remote_input_interrupt_request): New function.
20437 * server.h (check_remote_input_interrupt_request): Declare.
20438 * win32-low.c (winapi_DebugBreakProcess,
20439 winapi_GenerateConsoleCtrlEvent): New typedefs.
20440 (get_child_debug_event): Lower Win32 debug event polling from 1 sec
20442 (win32_wait): Check for remote interrupt request
20443 with check_remote_input_interrupt_request.
20444 (win32_request_interrupt): New function.
20445 (win32_target_op): Set request_interrupt to win32_request_interrupt.
20447 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20449 * win32-low.c (debug_registers_changed,
20450 debug_registers_used, CONTEXT_EXTENDED_REGISTERS,
20451 CONTEXT_FLOATING_POINT, CONTEXT_DEBUG_REGISTERS,
20452 CONTEXT_DEBUGGER, CONTEXT_DEBUGGER_DR): Delete.
20453 (thread_rec): Get context using the low target.
20454 (child_add_thread): Call thread_added on the low target,
20455 which does the same thing.
20457 (do_initial_child_stuff): Remove debug registers references.
20458 Set context using the low target. Resume threads after
20459 setting the contexts.
20460 (child_continue): Remove dead variable. Remove debug
20461 registers references.
20462 (child_fetch_inferior_registers): Go through the low target.
20463 (do_child_store_inferior_registers): Remove.
20464 (child_store_inferior_registers): Go through the low target.
20465 (win32_resume): Remove debug registers references.
20466 Set context using the low target.
20467 (handle_exception): Change return type to void. Don't record
20468 context here. Set status to TARGET_WAITKIND_SPURIOUS on a
20469 first chance exception.
20470 (get_child_debug_event): Change return type to void. Remove
20471 goto loop. Always return after waiting for debug event.
20472 (win32_wait): Convert to switch statement. Handle spurious
20475 * win32-i386-low.c (debug_registers_changed,
20476 debug_registers_used): New.
20477 (initial_stuff): Rename to ...
20478 (i386_initial_stuff): ... this. Clear debug registers
20480 (store_debug_registers): Delete.
20481 (i386_get_thread_context): New.
20482 (load_debug_registers): Delete.
20483 (i386_set_thread_context): New.
20484 (i386_thread_added): New.
20485 (single_step): Rename to ...
20486 (i386_single_step): ... this.
20487 (do_fetch_inferior_registers): Rename to ...
20488 (i386_fetch_inferior_register): ... this.
20489 (i386_store_inferior_register): New.
20490 (the_low_target): Adapt to new interface.
20492 * win32-arm-low.c (CONTEXT_FLOATING_POINT): Define.
20493 (arm_get_thread_context): New.
20494 (arm_set_thread_context): New.
20496 (do_fetch_inferior_registers): Rename to ...
20497 (arm_fetch_inferior_register): ... this.
20498 (arm_store_inferior_register): New.
20499 (arm_wince_breakpoint): Reimplement as unsigned long.
20500 (arm_wince_breakpoint_len): Define.
20501 (the_low_target): Adapt to new interface.
20503 * win32-low.h (target_ops): Remove regmap, store_debug_registers and
20504 load_debug_registers. Add get_thread_context, set_thread_context,
20505 thread_added and store_inferior_register. Rename
20506 fetch_inferior_registers to fetch_inferior_register.
20507 (regptr): Remove declaration.
20509 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20511 * linux-low.c (linux_detach): Change return type to int. Return 0.
20512 * spu-low.c (spu_detach): Likewise.
20514 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20516 * target.h (target_ops): Change return type of detach to int.
20518 (join_inferior): New.
20519 * server.c (main): Don't skip detach support on mingw32.
20520 If the inferior doesn't support detaching return error.
20521 Call join_inferior instead of using waitpid.
20522 * linux-low.c (linux_join): New.
20523 (linux_target_op): Add linux_join.
20524 * spu-low.c (spu_join): New.
20525 (spu_target_ops): Add spu_join.
20526 * win32-low.c (win32_detach): Adapt to new interface.
20527 Reopen current_process_handle before detaching. Issue a child
20528 resume before detaching.
20530 (win32_target_op): Add win32_join.
20532 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20534 * win32-low.c (win32-attach): Fix return value.
20535 * target.h (target_ops): Describe ATTACH return values.
20537 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20539 * win32-low.c (GETPROCADDRESS): Define.
20540 (winapi_DebugActiveProcessStop): Add WINAPI. typedef as pointer.
20541 (winapi_DebugSetProcessKillOnExit): Likewise.
20542 (win32_create_inferior): Force usage of ansi CreateProcessA.
20543 (win32_attach): Use GETPROCADDRESS.
20544 (win32_detach): Likewise.
20546 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
20548 * win32-low.c (win32_wait): Don't use WSTOPSIG.
20550 2007-03-30 Pedro Alves <pedro_alves@portugalmail.pt>
20552 * win32-low.c: Commit leftover changes from 2007-03-29.
20554 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
20556 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Make 16-bit
20557 fields short instead of int. Add explicit padding.
20558 (i387_cache_to_fsave): Remove unnecessary casts.
20559 (i387_fsave_to_cache): Doc fix.
20560 (i387_cache_to_fxsave): Remove unnecessary casts and masking.
20562 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
20564 * i387-fp.c (i387_cache_to_fxsave): Reinitialize val2 before use.
20565 (i387_fxsave_to_cache): Check fp->ftag while building ftag value.
20567 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
20569 * configure.srv (arm*-*-mingw32ce*): Move near the other
20572 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
20574 * configure.ac: Add errno checking.
20575 (AC_CHECK_HEADERS): Add errno.h, fcntl.h, signal.h,
20576 sys/file.h and malloc.h.
20577 (AC_CHECK_DECLS): Add perror.
20578 (srv_mingwce): Handle.
20579 * configure.srv (i[34567]86-*-cygwin*): Add
20580 win32-i386-low.o to srv_tgtobj.
20581 (i[34567]86-*-mingw*): Likewise.
20582 (arm*-*-mingw32ce*): Add case.
20583 * gdbreplay.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
20584 HAVE_FCNTL_H, HAVE_ERRNO_H, HAVE_MALLOC_H]: Check.
20585 [__MINGW32CE__] (strerror): New function.
20586 [__MINGW32CE__] (errno): Define to GetLastError.
20587 [__MINGW32CE__] (COUNTOF): New macro.
20588 (remote_open): Remove extra close call.
20589 * mem-break.c (delete_breakpoint_at): New function.
20590 * mem-break.h (delete_breakpoint_at): Declare.
20591 * remote-utils.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
20592 HAVE_FCNTL_H, HAVE_UNISTD_H, HAVE_ERRNO_H]: Check.
20593 [USE_WIN32API] (read, write): Add char* casts.
20594 * server.c [HAVE_UNISTD_H, HAVE_SIGNAL_H]: Check.
20595 * server.h: Include wincecompat.h on Windows CE.
20596 [HAVE_ERRNO_H]: Check.
20597 (perror): Declare if not declared.
20598 * utils.c: Add stdlib.h, errno.h and malloc.h includes.
20599 (perror_with_name): Remove errno declaration.
20600 * wincecompat.h: New.
20601 * wincecompat.c: New.
20602 * win32-low.h: New.
20603 * win32-arm-low.c: New.
20604 * win32-i386-low.c: New.
20605 (win32-low.c): Include mem-break.h and win32-low.h, and winnt.h.
20606 (OUTMSG2): Make it safe.
20608 (COUNTOF): New macro.
20609 (NUM_REGS): Get it from the low target.
20610 (CONTEXT_EXTENDED_REGISTERS, CONTEXT_FLOATING_POINT,
20611 CONTEXT_DEBUG_REGISTERS): Add fallbacks to 0.
20612 (thread_rec): Let low target handle debug registers.
20613 (child_add_thread): Likewise.
20614 (child_init_thread_list): Likewise.
20615 (continue_one_thread): Likewise.
20617 (do_child_fetch_inferior_registers): Move to ...
20618 * win32-i386-low.c: ... here, and rename to ...
20619 (do_fetch_inferior_registers): ... this.
20620 * win32-low.c (child_fetch_inferior_registers):
20621 Go through the low target.
20622 (do_child_store_inferior_registers): Use regptr.
20623 (strwinerror): New function.
20624 (win32_create_inferior): Handle Windows CE.
20625 Use strwinerror instead of strerror on Windows error
20626 codes. Add program to the error output.
20627 Don't close the main thread handle on Windows CE.
20628 (win32_attach): Use coredll.dll on Windows CE.
20629 (win32_kill): Close current process and current
20631 (win32_detach): Use coredll.dll on Windows CE.
20632 (win32_resume): Let low target handle debug registers, and
20634 (handle_exception): Add/Remove initial breakpoint. Avoid
20635 non-existant WSTOPSIG on Windows CE.
20636 (win32_read_inferior_memory): Cast to remove warning.
20637 (win32_arch_string): Go through the low target.
20638 (initialize_low): Call set_breakpoint_data with the low
20639 target's breakpoint.
20640 * win32-low.c (dr, FLAG_TRACE_BIT, FCS_REGNUM,
20641 FOP_REGNUM, mappings): Move to ...
20642 * win32-i386-low.c: ... here.
20643 * win32-low.c (win32_thread_info): Move to ...
20644 * win32-low.h: ... here.
20645 * Makefile.in (SFILES): Add win32-low.c, win32-i386-low.c,
20646 win32-arm-low.c and wincecompat.c.
20647 (all:): Add $EXEEXT.
20648 (install-only:): Likewise.
20649 (gdbserver:): Likewise.
20650 (gdbreplay:): Likewise.
20651 * config.in: Regenerate.
20652 * configure: Regenerate.
20654 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
20656 * win32-low.c: Rename typedef thread_info to
20657 win32_thread_info throughout.
20659 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
20661 * win32-i386-low.c: Rename to ...
20662 * win32-low.c: ... this.
20663 * configure.srv: Replace win32-i386-low.o with win32-low.o.
20664 * Makefile.in: Likewise.
20666 2007-03-27 Pedro Alves <pedro_alves@portugalmail.pt>
20668 * remote-utils.c (monitor_output): Constify msg parameter.
20669 * server.h (monitor_output): Likewise.
20670 * win32-i386-low.c (handle_output_debug_string): New.
20671 (win32_kill): Handle OUTPUT_DEBUG_STRING_EVENT events using
20672 handle_output_debug_string.
20673 (get_child_debug_event): Likewise.
20675 2007-03-27 Mat Hostetter <mat@lcs.mit.edu>
20677 * server.c (main): Correct strtoul check.
20679 2007-03-27 Jon Ringle <jon@ringle.org>
20681 * linux-low.c: Check __ARCH_HAS_MMU__ also.
20683 2007-03-27 Brooks Moses <brooks.moses@codesourcery.com>
20685 * Makefile.in: Add dummy "pdf" and "install-pdf" targets.
20687 2007-02-27 Daniel Jacobowitz <dan@codesourcery.com>
20689 * terminal.h: Check HAVE_SGTTY_H.
20691 2007-02-27 Mat Hostetter <mat@lcs.mit.edu>
20693 * remote-utils.c (remote_open): Print out the assigned port number.
20695 2007-02-26 Daniel Jacobowitz <dan@codesourcery.com>
20697 * remote-utils.c (monitor_output): New function.
20698 * server.c (debug_threads): Define here.
20699 (monitor_show_help): New function.
20700 (handle_query): Handle qRcmd.
20701 (main): Do not handle 'd' packet.
20702 * server.h (debug_threads, remote_debug, monitor_output): Declare.
20703 * linux-low.c, spu-low.c, win32-i386-low.c: Remove definitions
20706 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
20708 * Makefile.in (EXEEXT): New.
20709 (clean): Use $(EXEEXT).
20711 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
20713 * target.h (target_ops): Rename send_signal to request_interrupt,
20714 and remove enum target_signal parameter.
20715 * linux-low.c (linux_request_interrupt): Rename from
20716 linux_send_signal, and always send SIGINT.
20717 * spu-low.c (spu_request_interrupt): Rename from spu_send_signal,
20718 and always send SIGINT.
20719 * remote-utils.c (putpkt_binary): Call request_interrupt, instead
20721 (input_interrupt): Likewise.
20723 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
20725 * server.c (get_features_xml): Check if target implemented
20727 * win32-i386-low.c (win32_arch_string): New.
20728 (win32_target_ops): Add win32_arch_string as arch_string member.
20730 2007-02-22 Markus Deuling <deuling@de.ibm.com>
20732 * spu-low.c (spu_arch_string): New.
20733 (spu_target_ops): Add spu_arch_string.
20735 2007-02-16 Daniel Jacobowitz <dan@codesourcery.com>
20737 * remote-utils.c: Remove HAVE_TERMINAL_H check.
20738 * configure.ac: Do not check for terminal.h.
20739 * configure, config.in: Regenerated.
20741 2007-02-08 Daniel Jacobowitz <dan@codesourcery.com>
20743 * Makefile.in (OBS): Add $(XML_BUILTIN).
20744 (XML_DIR, XML_TARGET, XML_FILES, XML_BUILTIN): New.
20746 (target.xml, xml-builtin.c, stamp-xml, arm-with-iwmmxt.o)
20747 (arm-with-iwmmxt.c): New.
20748 * config.in, configure: Regenerate.
20749 * configure.ac: Check for iWMMXt. Handle srv_xmltarget,
20750 srv_xmlbuiltin, and srv_xmlfiles. Define USE_XML.
20751 * configure.srv: Mention srv_xmltarget and srv_xmlfiles.
20752 (arm*-*-linux*): Add iWMMXt and regset support.
20753 * linux-arm-low.c (PTRACE_GETWMMXREGS, PTRACE_SETWMMXREGS): Define.
20754 (arm_fill_gregset, arm_store_gregset, arm_fill_wmmxregset)
20755 (arm_store_wmmxregset, target_regsets): New.
20756 * server.c (get_features_xml): Take annex argument. Check builtin
20758 (handle_query): Handle multiple annexes.
20760 2007-01-29 Daniel Jacobowitz <dan@codesourcery.com>
20762 * remote-utils.c [USE_WIN32API] (read, write): Define.
20763 (putpkt_binary, input_interrupt, readchar, getpkt): Use read and
20766 2007-01-09 Daniel Jacobowitz <dan@codesourcery.com>
20768 * linux-i386-low.c (the_low_target): Set arch_string.
20769 * linux-x86-64-low.c (the_low_target): Likewise.
20770 * linux-low.c (linux_arch_string): New.
20771 (linux_target_ops): Add it.
20772 * linux-low.h (struct linux_target_ops): Add arch_string.
20773 * server.c (write_qxfer_response): Use const void * for DATA.
20774 (get_features_xml): New.
20775 (handle_query): Handle qXfer:features:read. Report it for qSupported.
20776 * target.h (struct target_ops): Add arch_string method.
20778 2007-01-03 Denis Pilat <denis.pilat@st.com>
20779 Daniel Jacobowitz <dan@codesourcery.com>
20781 * linux-low.c (linux_kill): Handle being called with no threads.
20782 * win32-i386-low.c (win32_kill): Likewise.
20783 (get_child_debug_event): Clear current_process_handle.
20785 2006-12-30 Denis PILAT <denis.pilat@st.com>
20786 Daniel Jacobowitz <dan@codesourcery.com>
20788 * remote-utils.c (remote_open): Check the type of specified
20789 serial port devices before opening them.
20790 * server.c (main): Kill the inferior if an error occurs during
20791 the first remote_open.
20793 2006-12-05 Markus Deuling <deuling@de.ibm.com>
20795 * README: Update supported targets.
20797 2006-11-28 Daniel Jacobowitz <dan@codesourcery.com>
20799 * Makefile.in (clean): Remove reg-mips64.c.
20800 (reg-mips64.c, reg-mips64.o): New rules.
20801 * configure.srv: Handle mips64. Include regset support for mips.
20802 * linux-mips-low.c (union mips_register): New.
20803 (mips_get_pc, mips_set_pc, mips_reinsert_addr): Use it.
20804 (mips_breakpoint, mips_breakpoint_at): Use int.
20805 (mips_collect_register, mips_supply_register)
20806 (mips_collect_register_32bit, mips_supply_register_32bit)
20807 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
20808 (mips_store_fpregset, target_regsets): New.
20809 * thread-db.c (thread_db_get_tls_address): Use uintptr_t.
20811 2006-11-22 Ulrich Weigand <uweigand@de.ibm.com>
20813 * configure.srv: Add target "spu*-*-*".
20814 * Makefile.in (clean): Remove reg-spu.c.
20815 (reg-spu.c, reg-spu.o, spu-low.o): Add dependencies.
20816 * spu-low.c: New file.
20818 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
20820 * configure.ac: Correct td_thr_tls_get_addr test.
20821 * configure: Regenerated.
20823 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
20825 * linux-low.c (linux_wait_for_event): Reformat. Use the
20826 pass_signals array.
20827 * remote-utils.c (decode_address_to_semicolon): New.
20828 * server.c (pass_signals, handle_general_set): New.
20829 (handle_query): Mention QPassSignals for qSupported.
20830 (main): Call handle_general_set.
20831 * server.h (pass_signals, decode_address_to_semicolon): New.
20833 2006-11-06 Daniel Jacobowitz <dan@codesourcery.com>
20835 * server.c (handle_query): Correct error handling for read_auxv.
20837 2005-10-19 Ulrich Weigand <uweigand@de.ibm.com>
20839 * configure.srv [s390-*-linux*, s390x-*-linux*]: Set srv_linux_regsets
20840 and srv_linux_thread_db to yes.
20841 * linux-s390-low.c (s390_fill_gregset): New function.
20842 (target_regsets): Define data structure.
20844 2006-10-17 Daniel Jacobowitz <dan@codesourcery.com>
20846 * acinclude.m4 (SRV_CHECK_TLS_GET_ADDR): New.
20847 * configure.ac: Use it. Define HAVE_TD_THR_TLS_GET_ADDR.
20848 * config.in, configure: Regenerated.
20849 * inferiors.c (gdb_id_to_thread): New function.
20850 (gdb_id_to_thread_id): Use it.
20851 * linux-low.c (linux_target_ops): Use thread_db_get_tls_address.
20852 * linux-low.h (struct process_info): Add th member.
20853 (thread_db_get_tls_address): New prototype.
20854 * remote-utils.c (decode_address): Make non-static.
20855 * server.c (handle_query): Handle qGetTLSAddr.
20856 * server.h (gdb_id_to_thread, decode_address): New prototypes.
20857 * target.h (struct target_ops): Add get_tls_address.
20858 * thread-db.c (maybe_attach_thread): Save the thread handle.
20859 (thread_db_get_tls_address): New.
20861 2006-09-28 Daniel Jacobowitz <dan@codesourcery.com>
20863 * linux-low.c (PTRACE_GETSIGINFO, PTRACE_SETSIGINFO): Define.
20864 (linux_resume_one_process): Take a siginfo_t *. Update all
20865 callers. Queue it if necessary. Use PTRACE_SETSIGINFO.
20866 (struct pending_signals): Add a siginfo_t.
20867 (linux_wait_for_process): Always set last_status.
20868 (linux_wait_for_event): Use PTRACE_GETSIGINFO.
20869 (linux_queue_one_thread): Use PTRACE_GETSIGINFO.
20870 * linux-low.h (struct process_info): Add last_status.
20872 2006-09-21 Daniel Jacobowitz <dan@codesourcery.com>
20874 * remote-utils.c (try_rle): New function.
20875 (putpkt_binary): Use it.
20877 2006-08-19 Daniel Jacobowitz <dan@codesourcery.com>
20879 * Makefile.in (clean): Clean reg-x86-64-linux.c.
20880 (reg-x86-64-linux.o, reg-x86-64-linux.c): New.
20881 * configure.srv (x86_64-*-linux*): Use reg-x86-64-linux.o.
20882 * linux-x86-64-low.c (x86_64_regmap): Include ORIG_RAX.
20883 (x86_64_fill_gregset, x86_64_store_gregset): Skip floating
20886 2006-08-08 Richard Sandiford <richard@codesourcery.com>
20888 * server.c (terminal_fd): New variable.
20889 (old_foreground_pgrp): Likewise.
20890 (restore_old_foreground_pgrp): New function.
20891 (start_inferior): Record the terminal file descriptor in terminal_fd
20892 and its original foreground group in old_foreground_pgrp. Register
20893 restore_old_foreground_pgrp with atexit().
20895 2006-07-26 Daniel Jacobowitz <dan@codesourcery.com>
20897 * server.c (handle_query): Correct qPart to qXfer.
20899 2006-07-22 Daniel Jacobowitz <dan@codesourcery.com>
20901 * configure.ac: Check for more headers which are missing on
20902 Windows. Automatically supply -lwsock32 and USE_WIN32API.
20903 * configure.srv: Add Cygwin and mingw32.
20904 * remote-utils.c: Don't include headers unconditionally which
20905 are missing on mingw32. Include <winsock.h> for mingw32.
20906 (remote_open): Adjust for mingw32 support. Flush
20907 standard error after writing to it.
20908 (remote_close, putpkt_binary, input_interrupt, block_async_io)
20909 (unblock_async_io, enable_async_io, disable_async_io)
20910 (readchar, getpkt): Update for Winsock support.
20911 (prepare_resume_reply): Expect a protocol signal number.
20912 * server.c: Disable <sys/wait.h> on mingw32.
20913 (start_inferior): Adjust for mingw32 support. Flush
20914 standard error after writing to it.
20915 (attach_inferior): Likewise. Use protocol signal
20917 (main): Skip 'D' packet on mingw32. Use protocol signal numbers
20919 * win32-i386-low.c: New file.
20920 * Makefile.in (XM_CLIBS): Set.
20921 (gdbserver, gdbreplay): Use $(INTERNAL_CFLAGS).
20922 (win32-i386-low.o): New dependency rule.
20923 * linux-low.c (linux_wait): Use target signal numbers.
20924 * target.h (struct target_ops): Doc fix.
20925 * server.h (target_signal_to_name): New prototype.
20926 * gdbreplay.c: Don't include headers unconditionally which
20927 are missing on mingw32. Include <winsock.h> for mingw32.
20928 (remote_close, remote_open): Adjust for Winsock support.
20929 * configure, config.in: Regenerated.
20931 2006-07-12 Daniel Jacobowitz <dan@codesourcery.com>
20933 * server.c (decode_xfer_read, write_qxfer_response): New.
20934 (handle_query): Take a packet length argument. Handle
20935 qXfer:auxv:read instead of qPart:auxv:read. Mention it in
20936 the qSupported response.
20937 (main): Update call to handle_query.
20939 2006-06-22 Daniel Jacobowitz <dan@codesourcery.com>
20941 * remote-utils.c (remote_escape_output, remote_unescape_input): New.
20942 (putpkt_binary): Renamed from putpkt and adjusted for binary
20944 (putpkt): New wrapper for putpkt_binary.
20945 (readchar): Don't mask off the high bit.
20946 (decode_X_packet): New function.
20947 * server.c (main): Call putpkt_binary if a handler sets the packet
20948 length. Save the length of the incoming packet. Handle 'X'.
20949 * server.h (gdb_byte, remote_escape_output, decode_X_packet): New.
20951 2006-06-21 Daniel Jacobowitz <dan@codesourcery.com>
20953 * server.c (handle_query): Handle qSupported.
20955 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
20957 * remote-utils.c (all_symbols_looked_up): New variable.
20958 (look_up_one_symbol): Check it.
20959 * server.h (look_up_one_symbol): New declaration.
20960 * thread-db.c (thread_db_init): Set all_symbols_looked_up.
20962 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
20964 * Makefile.in (linux-arm-low.o): Update dependencies.
20965 * linux-arm-low.c: Include "gdb_proc_service.h".
20966 (PTRACE_GET_THREAD_AREA): Define.
20967 (ps_get_thread_area): New function.
20969 2006-05-09 Nathan Sidwell <nathan@codesourcery.com>
20971 * configure.srv (m68k*-*-uclinux*): New target.
20972 * linux-low.c (linux_create_inferior): Use vfork on mmuless systems.
20973 (linux_resume_one_process): Remove extraneous cast.
20974 (linux_read_offsets): New.
20975 (linux_target_op): Add linux_read_offsets on mmuless systems.
20976 * server.c (handle_query): Add qOffsets logic.
20977 * target.h (struct target_ops): Add read_offsets.
20979 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
20981 * linux-mips-low.c: Include <sys/ptrace.h> and "gdb_proc_service.h".
20982 (PTRACE_GET_THREAD_AREA): Define.
20983 (ps_get_thread_area): New function.
20984 * Makefile.in (linux-i386-low.o, linux-mips-low.o)
20985 (linux-x86-64-low.o): Update.
20987 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
20989 * configure.ac: Remove checks for prfpregset_t.
20990 * gdb_proc_service.h: New file.
20991 * linux-i386-low.c, linux-x86-64-low.c, thread-db.c: Use the
20992 new "gdb_proc_service.h".
20993 * proc-service.c: Likewise.
20994 (ps_pglobal_lookup, ps_pdread, ps_pdwrite): Use psaddr_t.
20995 (ps_lgetfpregs, ps_lsetfpregs): Use a void* argument.
20996 * Makefile.in (gdb_proc_service_h): Updated.
20997 * configure, config.in: Regenerated.
20999 2006-03-03 Daniel Jacobowitz <dan@codesourcery.com>
21001 * remote-utils.c (prepare_resume_reply): Move declaration
21002 of gdb_id_from_wait to the top of the block.
21004 2006-02-15 Daniel Jacobowitz <dan@codesourcery.com>
21006 * linux-low.c (regsets_store_inferior_registers): Read the regset
21007 from the target before filling it.
21009 2006-02-08 Daniel Jacobowitz <dan@codesourcery.com>
21011 * server.c (attach_inferior): Return SIGTRAP for a successful
21014 2006-02-01 Daniel Jacobowitz <dan@codesourcery.com>
21016 * Makefile.in (OBS): Add version.o.
21017 (STAGESTUFF): Delete.
21018 (version.o): Add dependencies.
21019 (version.c): Replace rule.
21020 (clean): Remove version.c.
21021 * server.c (gdbserver_version): New.
21022 (gdbserver_usage): Use printf.
21023 (main): Handle --version and --help.
21024 * server.h (version, host_name): Add declarations.
21026 2005-12-23 Eli Zaretskii <eliz@gnu.org>
21038 * linux-x86-64-low.c:
21040 * linux-s390-low.c:
21041 * linux-ppc64-low.c:
21043 * linux-mips-low.c:
21044 * linux-m68k-low.c:
21045 * linux-m32r-low.c:
21048 * linux-ia64-low.c:
21049 * linux-i386-low.c:
21050 * linux-crisv32-low.c:
21062 * gdbserver.1: Add (C) after Copyright. Update the FSF
21065 2005-11-13 Daniel Jacobowitz <dan@codesourcery.com>
21067 * linux-arm-low.c (arm_eabi_breakpoint): New variable.
21068 (arm_breakpoint_at): Recognize both breakpoints.
21069 (the_low_target): Use the correct breakpoint instruction.
21071 2005-11-02 Daniel Jacobowitz <dan@codesourcery.com>
21073 * configure.srv (x86_64-*-linux*): Turn on thread_db support.
21074 * linux-x86-64-low.c (x86_64_breakpoint, x86_64_breakpoint_len)
21075 (x86_64_get_pc, x86_64_set_pc, x86_64_breakpoint_at): New.
21076 (the_low_target): Update.
21078 2005-10-25 Andreas Schwab <schwab@suse.de>
21080 * server.c (main): Allocate mem_buf with PBUFSIZ bytes.
21082 * linux-ia64-low.c (ia64_regmap): Remove NAT registers.
21083 (ia64_num_regs): Reduce to 462.
21085 2005-09-17 Daniel Jacobowitz <dan@codesourcery.com>
21087 * acinclude.m4: Correct quoting.
21088 * aclocal.m4: Regenerated.
21090 Suggested by SZOKOVACS Robert <szo@ies.hu>:
21091 * thread-db.c (thread_db_err_str): Handle TD_VERSION.
21092 (thread_db_init): Call thread_db_err_str.
21093 * configure.ac: Check for TD_VERSION.
21094 * config.in, configure: Regenerated.
21096 2005-07-31 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
21098 * server.h (error, fatal, warning): Add ATTR_FORMAT.
21100 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
21102 * configure.ac: Define HAVE_LINUX_REGSETS even if PTRACE_GETREGS
21103 is not available. Define HAVE_PTRACE_GETREGS if it is.
21104 * config.in, configure: Regenerated.
21105 * configure.srv: Set srv_linux_regsets for PowerPC and PowerPC64.
21106 * linux-i386-low.c, linux-m68k-low.c: Update to use
21107 HAVE_PTRACE_GETREGS.
21108 * linux-low.c (regsets_fetch_inferior_registers)
21109 (regsets_store_inferior_registers): Only return 0 if we processed
21111 * linux-ppc-low.c (ppc_fill_gregset, target_regsets): New.
21112 * linux-ppc64-low.c (ppc_fill_gregset, target_regsets): New.
21114 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
21116 * inferiors.c (struct thread_info): Add gdb_id.
21117 (add_thread): Add gdb_id argument.
21118 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New.
21119 * linux-low.c (linux_create_inferior, linux_attach_lwp): Update
21120 calls to add_thread.
21121 * remote-utils.c (prepare_resume_reply: Use thread_to_gdb_id.
21122 * server.c (handle_query): Use thread_to_gdb_id.
21123 (handle_v_cont, main): Use gdb_id_to_thread_id.
21124 * server.h (add_thread): Update prototype.
21125 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New
21128 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
21130 * linux-low.c (fetch_register, usr_store_inferior_registers): Handle
21131 left-padded registers.
21132 * linux-low.h (struct linux_target_ops): Add left_pad_xfer.
21133 * linux-ppc64-low.c (the_low_target): Set left_pad_xfer.
21135 2005-07-01 Steve Ellcey <sje@cup.hp.com>
21137 * configure.ac (BFD_NEED_DECLARATION): Replace with AC_CHECK_DECLS.
21138 * configure: Regenerate.
21139 * config.in: Regenerate.
21140 * server.h (NEED_DECLARATION_STRERROR):
21141 Replace with !HAVE_DECL_STRERROR.
21143 2005-06-16 Daniel Jacobowitz <dan@codesourcery.com>
21145 * linux-low.c (linux_wait, linux_send_signal): Don't test
21146 an unsigned long variable for > 0 if it could be MAX_ULONG.
21147 * server.c (myresume): Likewise.
21148 * target.c (set_desired_inferior): Likewise.
21150 2005-06-13 Mark Kettenis <kettenis@gnu.org>
21152 * configure.ac: Simplify and improve check for socklen_t.
21153 * configure, config.in: Regenerate.
21155 2005-06-12 Daniel Jacobowitz <dan@codesourcery.com>
21157 * acconfig.h: Remove.
21158 * configure.ac: Add a test for socklen_t. Use three-argument
21159 AC_DEFINE throughout.
21160 * config.in: Regenerated using autoheader 2.59.
21161 * configure: Regenerated.
21163 * gdbreplay.c (socklen_t): Provide a default.
21164 (remote_open): Use socklen_t.
21165 * remote-utils.c (socklen_t): Provide a default.
21166 (remote_open): Use socklen_t.
21167 (convert_int_to_ascii, convert_ascii_to_int, decode_M_packet): Use
21170 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Use unsigned
21172 * linux-low.c (linux_read_memory, linux_write_memory)
21173 (linux_read_auxv): Likewise.
21174 * mem-break.c (breakpoint_data, set_breakpoint_data, check_mem_read)
21175 (check_mem_write): Likewise.
21176 * mem-break.h (set_breakpoint_data, check_mem_read, check_mem_write):
21178 * regcache.c (struct inferior_rgcache_data, registers_to_string)
21179 (registers_from_string, register_data): Likewise.
21180 * server.c (handle_query, main): Likewise.
21181 * server.h (convert_ascii_to_int, convert_int_to_ascii)
21182 (decode_M_packet): Likewise.
21183 * target.c (read_inferior_memory, write_inferior_memory): Likewise.
21184 * target.h (struct target_ops): Update read_memory, write_memory,
21186 (read_inferior_memory, write_inferior_memory): Update.
21187 * linux-low.h (struct linux_target_ops): Change type of breakpoint
21188 to unsigned char *.
21189 * linux-arm-low.c, linux-cris-low.c, linux-crisv32-low.c,
21190 linux-i386-low.c, linux-m32r-low.c, linux-m68k-low.c,
21191 linux-mips-low.c, linux-ppc-low.c, linux-ppc64-low.c,
21192 linux-s390-low.c, linux-sh-low.c: Update for changes in
21193 read_inferior_memory and the_low_target->breakpoint.
21195 2005-05-28 Daniel Jacobowitz <dan@codesourcery.com>
21197 * Makefile.in (SFILES): Add linux-ppc64-low.c.
21198 (linux-ppc64-low.o, reg-ppc64.c, reg-ppc64.o): New targets.
21199 * configure.srv: Add powerpc64-*-linux*.
21200 * linux-ppc64-low.c: New file.
21202 2005-05-23 Orjan Friberg <orjanf@axis.com>
21204 * linux-cris-low.c: New file with support for CRIS.
21205 * linux-crisv32-low.c: Ditto for CRISv32.
21206 * Makefile.in (SFILES): Add linux-cris-low.c, linux-crisv32-low.c.
21207 (clean): Add reg-cris.c and reg-crisv32.c.
21208 Add linux-cris-low.o, linux-crisv32-low.o, reg-cris.o, reg-cris.c,
21209 reg-crisv32.o, and reg-crisv32.c to make rules.
21210 * configure.srv: Add cris-*-linux* and crisv32-*-linux* to list of
21211 recognized targets.
21213 2005-05-16 Ulrich Weigand <uweigand@de.ibm.com>
21215 * linux-low.c (fetch_register): Ensure buffer size is a multiple
21216 of sizeof (PTRACE_XFER_TYPE).
21217 (usr_store_inferior_registers): Likewise. Zero out excess bytes.
21219 2005-05-12 Orjan Friberg <orjanf@axis.com>
21221 * target.h (struct target_ops): Add insert_watchpoint,
21222 remove_watchpoint, stopped_by_watchpoint, stopped_data_address function
21223 pointers for hardware watchpoint support.
21224 * linux-low.h (struct linux_target_ops): Ditto.
21225 * linux-low.c (linux_insert_watchpoint, linux_remove_watchpoint)
21226 (linux_stopped_by_watchpoint, linux_stopped_data_address): New. Add
21227 to linux_target_ops.
21228 * remote-utils.c (prepare_resume_reply): Add watchpoint information to
21230 * server.c (main): Recognize 'Z' and 'z' packets.
21232 2005-05-10 Ulrich Weigand <uweigand@de.ibm.com>
21234 * linux-s390-low.c (s390_breakpoint, s390_breakpoint_len): Define.
21235 (s390_get_pc, s390_set_pc, s390_breakpoint_at): New functions.
21236 (the_low_target): Add new members.
21238 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
21240 * proc-service.c (ps_lgetregs): Search all_processes instead of
21243 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
21245 * server.c (start_inferior): Change return type to int.
21246 (attach_inferior): Change sigptr to int *.
21247 (handle_v_cont, handle_v_requests): Change signal to int *.
21248 (main): Change signal to int.
21250 2005-04-15 Kei Sakamoto <sakamoto.kei@renesas.com>
21252 * Makefile.in: Add linux-m32r-low.o, reg-m32r.c and reg-m32r.o.
21253 * configure.srv: Add m32r*-*-linux*.
21254 * linux-m32r-low.c: New file.
21256 2005-03-04 Daniel Jacobowitz <dan@codesourcery.com>
21258 * Makefile.in (stamp-h): Set CONFIG_HEADERS explicitly.
21260 2005-03-03 Daniel Jacobowitz <dan@codesourcery.com>
21262 * inferiors.c (change_inferior_id, add_thread, find_inferior_id):
21263 Take unsigned long arguments for PIDs.
21264 * linux-low.c (add_process, linux_attach_lwp, linux_attach)
21265 (linux_thread_alive, linux_wait_for_event, kill_lwp, send_sigstop)
21266 (wait_for_sigstop, linux_resume_one_process)
21267 (regsets_fetch_inferior_registers, linux_send_signal)
21268 (linux_read_auxv): Likewise. Update the types of variables holding
21269 PIDs. Update format string specifiers.
21270 * linux-low.h (struct process_info, linux_attach_lwp): Likewise.
21271 * remote-utils.c (prepare_resume_reply): Likewise.
21272 * server.c (cont_thread, general_thread, step_thread)
21273 (thread_from_wait, old_thread_from_wait, signal_pid): Change type to
21275 (handle_query): Update format specifiers.
21276 (handle_v_cont, main): Use strtoul for thread IDs.
21277 * server.h (struct inferior_list_entry): Use unsigned long for ID.
21278 (add_thread, find_inferior_id, change_inferior_id, cont_thread)
21279 (general_thread, step_thread, thread_from_wait)
21280 (old_thread_from_wait): Update.
21281 * target.h (struct thread_resume): Use unsigned long for THREAD.
21282 (struct target_ops): Use unsigned long for arguments to attach and
21285 2005-02-24 Daniel Jacobowitz <dan@codesourcery.com>
21287 * acinclude.m4: Include bfd/bfd.m4 directly.
21288 * configure.ac: Use AC_ARG_PROGRAM. Suggested by Aron Griffis
21289 <agriffis@toolchain.org>.
21290 * aclocal.m4, configure: Regenerated.
21292 2005-01-07 Andrew Cagney <cagney@gnu.org>
21294 * configure.ac: Rename configure.in, require autoconf 2.59.
21295 * configure: Re-generate.
21297 2004-12-08 Daniel Jacobowitz <dan@debian.org>
21299 * acinclude.m4 (SRV_CHECK_THREAD_DB): Add ps_get_thread_area. Reset
21300 LIBS when finished.
21301 * aclocal.m4: Regenerated.
21302 * configure: Regenerated.
21304 2004-11-21 Andreas Schwab <schwab@suse.de>
21306 * linux-m68k-low.c (m68k_num_gregs): Define.
21307 (m68k_fill_gregset, m68k_store_gregset, m68k_fill_fpregset)
21308 (m68k_store_fpregset, target_regsets) [HAVE_LINUX_REGSETS]: New.
21309 (m68k_breakpoint, m68k_breakpoint_len, m68k_get_pc, m68k_set_pc)
21310 (m68k_breakpoint_at): New. Add to the_low_target.
21312 * configure.srv (m68*-*-linux*): Set srv_linux_regsets and
21313 srv_linux_thread_db to yes.
21315 2004-10-20 Joel Brobecker <brobecker@gnat.com>
21317 * linux-x86-64-low.c (ARCH_SET_GS): Add definition if missing.
21318 (ARCH_SET_FS): Likewise.
21319 (ARCH_GET_FS): Likewise.
21320 (ARCH_GET_GS): Likewise.
21322 2004-10-16 Daniel Jacobowitz <dan@debian.org>
21324 * linux-i386-low.c (ps_get_thread_area): New.
21325 * linux-x86-64-low.c (ps_get_thread_area): New.
21326 * linux-low.c: Include <sys/syscall.h>.
21327 (linux_kill_one_process): Don't kill the first thread here.
21328 (linux_kill): Kill the first thread here.
21329 (kill_lwp): New function.
21330 (send_sigstop, linux_send_signal): Use it.
21331 * proc-service.c: Clean up #ifdefs.
21332 (fpregset_info): Delete.
21333 (ps_lgetregs): Update and enable implementation.
21334 (ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs): Remove disabled
21336 * remote-utils.c (struct sym_cache, symbol_cache): New.
21337 (input_interrupt): Print a clearer message.
21338 (async_io_enabled): New variable.
21339 (enable_async_io, disable_async_io): Use it. Update comments.
21340 (look_up_one_symbol): Use the symbol cache.
21341 * thread-db.c (thread_db_look_up_symbols): New function.
21342 (thread_db_init): Update comments. Call thread_db_look_up_symbols.
21344 2004-10-16 Daniel Jacobowitz <dan@debian.org>
21346 * configure.in: Test for -rdynamic.
21347 * configure: Regenerated.
21348 * Makefile (INTERNAL_LDFLAGS): New.
21349 (gdbserver, gdbreplay): Use it.
21351 2004-09-02 Andrew Cagney <cagney@gnu.org>
21353 * Makefile.in (TAGS): Replace TM_FILE with DEPRECATED_TM_FILE.
21355 2004-03-23 Daniel Jacobowitz <drow@mvista.com>
21357 * linux-low.c (linux_wait): Clear all_processes list also.
21359 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
21361 * linux-low.c: Include <errno.h>. Remove extern declaration of
21364 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
21366 * gdbreplay.c, server.h, utils.c: Update copyright years.
21368 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
21370 * server.c (main): Print child status or termination signal from
21371 variable 'signal', not 'sig'.
21373 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
21375 * linux-low.c (linux_read_memory): Change return type to
21376 int. Check for and return error from ptrace().
21377 * target.c (read_inferior_memory): Change return type to int. Pass
21378 back return status from the_target->read_memory().
21379 * target.h (struct target_ops): Adapt *read_memory() prototype.
21381 (read_inferior_memory): Adapt prototype.
21382 * server.c (main): Return an error packet if
21383 read_inferior_memory() returns an error.
21385 2004-03-04 Daniel Jacobowitz <drow@mvista.com>
21387 * Makefile.in (distclean): Remove config.h, stamp-h, and config.log.
21388 Unify with other clean targets.
21390 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
21392 * server.c (handle_v_cont): Call set_desired_inferior.
21394 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
21396 * remote-utils.c (prepare_resume_reply): Always supply "thread:".
21398 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
21400 * linux-low.c (linux_wait): Unblock async I/O.
21401 (linux_resume): Block and enable async I/O.
21402 * remote-utils.c (block_async_io, unblock_async_io): New functions.
21403 * server.h (block_async_io, unblock_async_io): Add prototypes.
21405 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
21407 * remote-utils.c (remote_open): Print a status notice after
21408 opening a TCP port.
21409 * server.c (attach_inferior): Print a status notice after
21412 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
21414 * linux-arm-low.c (arm_get_pc): Print out stop PC in debug mode.
21416 2004-02-26 Daniel Jacobowitz <drow@mvista.com>
21418 * remote-utils.c (write_enn): Use "E01" instead of "ENN" for the
21420 * server.c, target.h: Update copyright years.
21422 2004-02-25 Roland McGrath <roland@redhat.com>
21424 * target.h (struct target_ops): New member `read_auxv'.
21425 * server.c (handle_query): Handle qPart:auxv:read: query using that.
21426 * linux-low.c (linux_read_auxv): New function.
21427 (linux_target_ops): Initialize `read_auxv' member to that.
21429 2004-02-17 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
21431 Committed by Jim Blandy <jimb@redhat.com>.
21433 * linux-s390-low.c (s390_num_regs): Update.
21434 (s390_regmap): Remove control registers. Use __s390x__ predefine
21435 instead of GPR_SIZE to distiguish s390 and s390x targets.
21437 2004-01-31 Daniel Jacobowitz <drow@mvista.com>
21439 * linux-low.c: Update copyright year.
21440 (check_removed_breakpoint): Clear pending_is_breakpoint.
21441 (linux_set_resume_request, linux_queue_one_thread)
21442 (resume_status_pending_p): New functions.
21443 (linux_continue_one_thread): Use process->resume.
21444 (linux_resume): Only resume threads if there are no pending events.
21445 * linux-low.h (struct process_info): Add resume request
21448 2004-01-30 Daniel Jacobowitz <drow@mvista.com>
21450 * regcache.c (new_register_cache): Clear the allocated register
21451 buffer. Suggested by Atsushi Nemoto <anemo@mba.ocn.ne.jp>.
21453 2003-10-13 Daniel Jacobowitz <drow@mvista.com>
21455 * linux-low.c (linux_resume): Take a struct thread_resume *
21457 (linux_wait): Update call.
21458 (resume_ptr): New static variable.
21459 (linux_continue_one_thread): Renamed from
21460 linux_continue_one_process. Use resume_ptr.
21461 (linux_resume): Use linux_continue_one_thread.
21462 * server.c (handle_v_cont, handle_v_requests): New functions.
21463 (myresume): New function.
21464 (main): Handle 'v' case.
21465 * target.h (struct thread_resume): New type.
21466 (struct target_ops): Change argument of "resume" to struct
21468 (myresume): Delete macro.
21470 2003-08-08 H.J. Lu <hongjiu.lu@intel.com>
21472 * Makefile.in (install-only): Create dest dir. Support DESTDIR.
21473 (uninstall): Support DESTDIR.
21475 Mon Jul 21 20:09:34 UTC 2003 Brendan Conoboy <blc@redhat.com>
21477 * configure.srv: Add xscale*linux copy of arm*linux entry.
21479 2003-07-24 Daniel Jacobowitz <drow@mvista.com>
21481 * linux-arm-low.c (arm_reinsert_addr): New function.
21482 (the_low_target): Add arm_reinsert_addr.
21484 2003-07-08 Mark Kettenis <kettenis@gnu.org>
21486 * mem-break.c: Remove whitespace at end of file.
21488 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
21490 * configure.in: Check whether we need to prototype strerror.
21491 * server.h: Optionally prototype strerror.
21492 * gdbreplay.c (perror_with_name): Use strerror.
21493 * linux-low.c (linux_attach_lwp): Use strerror.
21494 * utils.c (perror_with_name): Use strerror.
21495 * config.in, configure: Regenerated.
21497 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
21499 * linux-sh-low.c (sh_regmap): Fix FP register offsets, reported by
21500 SUGIOKA Toshinobu <sugioka@itonet.co.jp>.
21502 2003-06-20 Daniel Jacobowitz <drow@mvista.com>
21504 * Makefile.in (SFILES): Update.
21505 * low-hppabsd.c, low-lynx.c, low-nbsd.c, low-sim.c, low-sparc.c,
21506 low-sun3.c: Remove files.
21508 2003-06-17 Daniel Jacobowitz <drow@mvista.com>
21510 * linux-low.c: Move comment to linux_thread_alive where it belonged.
21511 (linux_detach_one_process, linux_detach): New functions.
21512 (linux_target_ops): Add linux_detach.
21513 * server.c (main): Handle 'D' packet.
21514 * target.h (struct target_ops): Add "detach" member.
21515 (detach_inferior): Define.
21517 2003-06-13 Mark Kettenis <kettenis@gnu.org>
21519 From Kelley Cook <kelleycook@wideopenwest.com>:
21520 * configure.srv: Accept i[34567]86 variants.
21522 2003-06-05 Daniel Jacobowitz <drow@mvista.com>
21524 * linux-low.c (linux_wait_for_event): Correct comment typos.
21525 (linux_resume_one_process): Call check_removed_breakpoint.
21526 (linux_send_signal): New function.
21527 (linux_target_ops): Add linux_send_signal.
21528 * remote-utils.c (putpkt, input_interrupt): Use send_signal instead
21530 * target.h (struct target_ops): Add send_signal.
21532 2003-05-29 Jim Blandy <jimb@redhat.com>
21534 * linux-low.c (usr_store_inferior_registers): Transfer buf in
21535 PTRACE_XFER_TYPE-sized chunks, not int-sized chunks. Otherwise,
21536 if 'int' is smaller than PTRACE_XFER_TYPE, you end up throwing
21537 away part of the register's value.
21539 2003-03-26 Daniel Jacobowitz <drow@mvista.com>
21541 * linux-low.c (linux_create_inferior): Use __SIGRTMIN.
21542 (linux_wait_for_event, linux_init_signals): Likewise.
21544 2003-03-17 Daniel Jacobowitz <drow@mvista.com>
21546 * configure.in: Check for stdlib.h.
21547 * configure: Regenerated.
21548 * config.in: Regenerated.
21550 2003-01-04 Andreas Schwab <schwab@suse.de>
21552 * linux-m68k-low.c (m68k_num_regs): Define to 29 instead of 31.
21554 2003-01-02 Andrew Cagney <ac131313@redhat.com>
21556 * Makefile.in: Remove obsolete code.
21558 2002-11-20 Daniel Jacobowitz <drow@mvista.com>
21560 * linux-s390-low.c (s390_regmap): Check GPR_SIZE instead of
21561 defined(PT_FPR0_HI).
21563 2002-11-17 Stuart Hughes <seh@zee2.com>
21565 * linux-arm-low.c (arm_num_regs): Increase.
21566 (arm_regmap): Include status register.
21568 2002-11-17 Daniel Jacobowitz <drow@mvista.com>
21570 * linux-low.c (register_addr): Remove incorrect -1 check.
21572 2002-08-29 Daniel Jacobowitz <drow@mvista.com>
21574 * linux-low.c (linux_create_inferior): Call setpgid. Return
21576 (unstopped_p, linux_signal_pid): Remove.
21577 (linux_target_ops): Remove linux_signal_pid.
21578 * remote-utils.c (putpkt, input_interrupt): Use signal_pid
21579 global instead of target method.
21580 * target.h (struct target_ops): Remove signal_pid. Update comment
21581 for create_inferior.
21582 * server.c (signal_pid): New variable.
21583 (create_inferior): Set signal_pid. Block SIGTTOU and SIGTTIN in
21584 gdbserver. Set the child to be the foreground process group.
21585 (attach_inferior): Set signal_pid.
21587 2002-08-23 Daniel Jacobowitz <drow@mvista.com>
21589 * ChangeLog: New file, with entries from gdb/ChangeLog after GDB 5.2.
21591 2002-08-20 Jim Blandy <jimb@redhat.com>
21593 * Makefile.in (LDFLAGS): Allow the configure script to establish a
21596 2002-08-01 Andrew Cagney <cagney@redhat.com>
21598 * Makefile.in: Make chill references obsolete.
21600 2002-07-24 Kevin Buettner <kevinb@redhat.com>
21602 * configure.in (unistd.h): Add to AC_CHECK_HEADERS list.
21603 * configure: Regenerate.
21604 * config.in: Regenerate.
21606 2002-07-09 David O'Brien <obrien@FreeBSD.org>
21608 * gdbreplay.c (stdlib.h, unistd.h): Conditionaly include.
21609 (perror_with_name, remote_close, remote_open, expect, play): Static.
21611 2002-07-04 Michal Ludvig <mludvig@suse.cz>
21613 * linux-x86-64-low.c (x86_64_regmap): Make it an array of
21614 byte offsets instead of an array of indexes.
21615 (x86_64_store_gregset, x86_64_store_fpregset): Parameter made const.
21617 2002-06-13 Daniel Jacobowitz <drow@mvista.com>
21619 * regcache.c: Add comment.
21621 2002-06-11 Daniel Jacobowitz <drow@mvista.com>
21623 * thread-db.c: New file.
21624 * proc-service.c: New file.
21625 * acinclude.m4: New file.
21626 * Makefile.in: Add GDBSERVER_LIBS, gdb_proc_service_h,
21627 proc-service.o, and thread-db.o.
21628 (linux-low.o): Add USE_THREAD_DB.
21629 * acconfig.h: Add HAVE_PRGREGSET_T, HAVE_PRFPREGSET_T,
21630 HAVE_LWPID_T, HAVE_PSADDR_T, and PRFPREGSET_T_BROKEN.
21631 * aclocal.m4: Regenerated.
21632 * config.in: Regenerated.
21633 * configure: Regenerated.
21634 * configure.in: Check for proc_service.h, sys/procfs.h,
21635 thread_db.h, and linux/elf.h headrs.
21636 Check for lwpid_t, psaddr_t, prgregset_t, prfpregset_t, and
21637 PRFPREGSET_T_BROKEN. Introduce srv_thread_depfiles and USE_THREAD_DB.
21638 Check for -lthread_db and thread support.
21639 * configure.srv: Enable thread_db support for ARM, i386, MIPS,
21640 PowerPC, and SuperH.
21641 * i387-fp.c: Constify arguments.
21642 * i387-fp.h: Likewise.
21643 * inferiors.c: (struct thread_info): Renamed from
21644 `struct inferior_info'. Remove PID member. Use generic inferior
21645 list header. All uses updated.
21646 (inferiors, signal_pid): Removed.
21647 (all_threads): New variable.
21648 (get_thread): Define.
21649 (add_inferior_to_list): New function.
21650 (for_each_inferior): New function.
21651 (change_inferior_id): New function.
21652 (add_inferior): Removed.
21653 (remove_inferior): New function.
21654 (add_thread): New function.
21655 (free_one_thread): New function.
21656 (remove_thread): New function.
21657 (clear_inferiors): Use for_each_inferior and free_one_thread.
21658 (find_inferior): New function.
21659 (find_inferior_id): New function.
21660 (inferior_target_data): Update argument type.
21661 (set_inferior_target_data): Likewise.
21662 (inferior_regcache_data): Likewise.
21663 (set_inferior_regcache_data): Likewise.
21664 * linux-low.c (linux_bp_reinsert): Remove.
21665 (all_processes, stopping_threads, using_thrads)
21666 (struct pending_signals, debug_threads, pid_of): New.
21667 (inferior_pid): Replace with macro.
21668 (struct inferior_linux_data): Remove.
21669 (get_stop_pc, add_process): New functions.
21670 (linux_create_inferior): Restore SIGRTMIN+1 before calling exec.
21671 Use add_process and add_thread.
21672 (linux_attach_lwp): New function, based on old linux_attach. Use
21673 add_process and add_thread. Set stop_expected for new threads.
21674 (linux_attach): New function.
21675 (linux_kill_one_process): New function.
21676 (linux_kill): Kill all LWPs.
21677 (linux_thread_alive): Use find_inferior_id.
21678 (check_removed_breakpoints, status_pending_p): New functions.
21679 (linux_wait_for_process): Renamed from linux_wait_for_one_inferior.
21680 Update. Use WNOHANG. Wait for cloned processes also. Update process
21681 struct for the found process.
21682 (linux_wait_for_event): New function.
21683 (linux_wait): Use it. Support LWPs.
21684 (send_sigstop, wait_for_sigstop, stop_all_processes)
21685 (linux_resume_one_process, linux_continue_one_process): New functions.
21686 (linux_resume): Support LWPs.
21687 (REGISTER_RAW_SIZE): Remove.
21688 (fetch_register): Use register_size instead. Call supply_register.
21689 (usr_store_inferior_registers): Likewise. Call collect_register.
21690 Fix recursive case.
21691 (regsets_fetch_inferior_registers): Improve error message.
21692 (regsets_store_inferior_registers): Add debugging.
21693 (linux_look_up_symbols): Call thread_db_init if USE_THREAD_DB.
21694 (unstopped_p, linux_signal_pid): New functions.
21695 (linux_target_ops): Add linux_signal_pid.
21696 (linux_init_signals): New function.
21697 (initialize_low): Call it. Initialize using_threads.
21698 * regcache.c (inferior_regcache_data): Add valid
21700 (get_regcache): Fetch registers lazily. Add fetch argument
21701 and update all callers.
21702 (regcache_invalidate_one, regcache_invalidate): New
21704 (new_register_cache): Renamed from create_register_cache.
21705 Return the new regcache.
21706 (free_register_cache): Change argument to a void *.
21707 (registers_to_string, registers_from_string): Call get_regcache
21708 with fetch flag set.
21709 (register_data): Make static. Pass fetch flag to get_regcache.
21710 (supply_register): Call get_regcache with fetch flag clear.
21711 (collect_register): Call get_regcache with fetch flag set.
21712 (collect_register_as_string): New function.
21713 * regcache.h: Update.
21714 * remote-utils.c (putpkt): Flush after debug output and use
21716 Handle input interrupts while waiting for an ACK.
21717 (input_interrupt): Use signal_pid method.
21718 (getpkt): Flush after debug output and use stderr.
21719 (outreg): Use collect_register_as_string.
21720 (new_thread_notify, dead_thread_notify): New functions.
21721 (prepare_resume_reply): Check using_threads. Set thread_from_wait
21722 and general_thread.
21723 (look_up_one_symbol): Flush after debug output.
21724 * server.c (step_thread, server_waiting): New variables.
21725 (start_inferior): Don't use signal_pid. Update call to mywait.
21726 (attach_inferior): Update call to mywait.
21727 (handle_query): Handle qfThreadInfo and qsThreadInfo.
21728 (main): Don't fetch/store registers explicitly. Use
21729 set_desired_inferior. Support proposed ``Hs'' packet. Update
21731 * server.h: Update.
21732 (struct inferior_list, struct_inferior_list_entry): New.
21733 * target.c (set_desired_inferior): New.
21734 (write_inferior_memory): Constify.
21735 (mywait): New function.
21736 * target.h: Update.
21737 (struct target_ops): New signal_pid method.
21738 (mywait): Removed macro, added prototype.
21740 * linux-low.h (regset_func): Removed.
21741 (regset_fill_func, regset_store_func): New.
21742 (enum regset_type): New.
21743 (struct regset_info): Add type field. Use new operation types.
21744 (struct linux_target_ops): stop_pc renamed to get_pc.
21745 Add decr_pc_after_break and breakpoint_at.
21746 (get_process, get_thread_proess, get_process_thread)
21747 (strut process_info, all_processes, linux_attach_lwp)
21748 (thread_db_init): New.
21750 * linux-arm-low.c (arm_get_pc, arm_set_pc,
21751 arm_breakpoint, arm_breakpoint_len, arm_breakpoint_at): New.
21752 (the_low_target): Add new members.
21753 * linux-i386-low.c (i386_store_gregset, i386_store_fpregset)
21754 (i386_store_fpxregset): Constify.
21755 (target_regsets): Add new kind identifier.
21756 (i386_get_pc): Renamed from i386_stop_pc. Simplify.
21757 (i386_set_pc): Add debugging.
21758 (i386_breakpoint_at): New function.
21759 (the_low_target): Add new members.
21760 * linux-mips-low.c (mips_get_pc, mips_set_pc)
21761 (mips_breakpoint, mips_breakpoint_len, mips_reinsert_addr)
21762 (mips_breakpoint_at): New.
21763 (the_low_target): Add new members.
21764 * linux-ppc-low.c (ppc_get_pc, ppc_set_pc)
21765 (ppc_breakpoint, ppc_breakpoint_len, ppc_breakpoint_at): New.
21766 (the_low_target): Add new members.
21767 * linux-sh-low.c (sh_get_pc, sh_set_pc)
21768 (sh_breakpoint, sh_breakpoint_len, sh_breakpoint_at): New.
21769 (the_low_target): Add new members.
21770 * linux-x86-64-low.c (target_regsets): Add new kind
21773 2002-05-15 Daniel Jacobowitz <drow@mvista.com>
21775 From Martin Pool <mbp@samba.org>:
21776 * server.c (gdbserver_usage): New function.
21779 2002-05-14 Daniel Jacobowitz <drow@mvista.com>
21781 * mem-break.c (reinsert_breakpoint_by_bp): Correct typo
21782 stop_at -> stop_pc.
21784 2002-05-04 Andrew Cagney <ac131313@redhat.com>
21786 * Makefile.in: Remove obsolete code.
21788 2002-04-24 Michal Ludvig <mludvig@suse.cz>
21790 * linux-low.c (regsets_fetch_inferior_registers),
21791 (regsets_store_inferior_registers): Removed cast to int from
21793 * regcache.h: Added declaration of struct inferior_info.
21795 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
21797 * inferiors.c (struct inferior_info): Add regcache_data.
21798 (add_inferior): Call create_register_cache.
21799 (clear_inferiors): Call free_register_cache.
21800 (inferior_regcache_data, set_inferior_regcache_data): New functions.
21801 * regcache.c (struct inferior_regcache_data): New.
21802 (registers): Remove.
21803 (get_regcache): New function.
21804 (create_register_cache, free_register_cache): New functions.
21805 (set_register_cache): Don't initialize the register cache here.
21806 (registers_to_string, registers_from_string, register_data): Call
21808 * regcache.h: Add prototypes.
21809 * server.h: Likewise.
21811 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
21813 * mem-break.c: New file.
21814 * mem-break.h: New file.
21815 * Makefile.in: Add mem-break.o rule; update server.h
21817 * inferiors.c (struct inferior_info): Add target_data
21819 (clear_inferiors): Free target_data member if set.
21820 (inferior_target_data, set_inferior_target_data): New functions.
21821 * linux-i386-low.c (i386_breakpoint, i386_breakpoint_len)
21822 (i386_stop_pc, i386_set_pc): New. Add to the_low_target.
21823 * linux-low.c (linux_bp_reinsert): New variable.
21824 (struct inferior_linux_data): New.
21825 (linux_create_inferior): Use set_inferior_target_data.
21826 (linux_attach): Likewise. Call add_inferior.
21827 (linux_wait_for_one_inferior): New function.
21828 (linux_wait): Call it.
21829 (linux_write_memory): Add const.
21830 (initialize_low): Call set_breakpoint_data.
21831 * linux-low.h (struct linux_target_ops): Add breakpoint
21833 * server.c (attach_inferior): Remove extra add_inferior
21835 * server.h: Include mem-break.h. Update inferior.c
21837 * target.c (read_inferior_memory)
21838 (write_inferior_memory): New functions.
21839 * target.h (read_inferior_memory)
21840 (write_inferior_memory): Change macros to prototypes.
21841 (struct target_ops): Update comments. Add const to write_memory
21844 2002-04-11 Daniel Jacobowitz <drow@mvista.com>
21846 * linux-low.c (usr_store_inferior_registers): Support
21847 registers which are allowed to fail to store.
21848 * linux-low.h (linux_target_ops): Likewise.
21849 * linux-ppc-low.c (ppc_regmap): Support FPSCR.
21850 (ppc_cannot_store_register): FPSCR may not be storable.
21852 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
21854 * server.h: Include <string.h> if HAVE_STRING_H.
21855 * ChangeLog: Correct paths in last ChangeLog entry.
21857 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
21859 * linux-low.h: Remove obsolete prototypes.
21860 (struct linux_target_ops): New.
21861 (extern the_low_target): New.
21862 * linux-low.c (num_regs, regmap): Remove declarations.
21863 (register_addr): Use the_low_target explicitly.
21864 (fetch_register): Likewise.
21865 (usr_fetch_inferior_registers): Likewise.
21866 (usr_store_inferior_registers): Likewise.
21867 * linux-arm-low.c (num_regs): Remove.
21868 (arm_num_regs): Define.
21869 (arm_regmap): Renamed from regmap, made static.
21870 (arm_cannot_fetch_register): Renamed from cannot_fetch_register,
21872 (arm_cannot_store_register): Renamed from cannot_store_register,
21874 (the_low_target): New.
21875 * linux-i386-low.c (num_regs): Remove.
21876 (i386_num_regs): Define.
21877 (i386_regmap): Renamed from regmap, made static.
21878 (i386_cannot_fetch_register): Renamed from cannot_fetch_register,
21880 (i386_cannot_store_register): Renamed from cannot_store_register,
21882 (the_low_target): New.
21883 * linux-ia64-low.c (num_regs): Remove.
21884 (ia64_num_regs): Define.
21885 (ia64_regmap): Renamed from regmap, made static.
21886 (ia64_cannot_fetch_register): Renamed from cannot_fetch_register,
21888 (ia64_cannot_store_register): Renamed from cannot_store_register,
21890 (the_low_target): New.
21891 * linux-m68k-low.c (num_regs): Remove.
21892 (m68k_num_regs): Define.
21893 (m68k_regmap): Renamed from regmap, made static.
21894 (m68k_cannot_fetch_register): Renamed from cannot_fetch_register,
21896 (m68k_cannot_store_register): Renamed from cannot_store_register,
21898 (the_low_target): New.
21899 * linux-mips-low.c (num_regs): Remove.
21900 (mips_num_regs): Define.
21901 (mips_regmap): Renamed from regmap, made static.
21902 (mips_cannot_fetch_register): Renamed from cannot_fetch_register,
21904 (mips_cannot_store_register): Renamed from cannot_store_register,
21906 (the_low_target): New.
21907 * linux-ppc-low.c (num_regs): Remove.
21908 (ppc_num_regs): Define.
21909 (ppc_regmap): Renamed from regmap, made static.
21910 (ppc_cannot_fetch_register): Renamed from cannot_fetch_register,
21912 (ppc_cannot_store_register): Renamed from cannot_store_register,
21914 (the_low_target): New.
21915 * linux-s390-low.c (num_regs): Remove.
21916 (s390_num_regs): Define.
21917 (s390_regmap): Renamed from regmap, made static.
21918 (s390_cannot_fetch_register): Renamed from cannot_fetch_register,
21920 (s390_cannot_store_register): Renamed from cannot_store_register,
21922 (the_low_target): New.
21923 * linux-sh-low.c (num_regs): Remove.
21924 (sh_num_regs): Define.
21925 (sh_regmap): Renamed from regmap, made static.
21926 (sh_cannot_fetch_register): Renamed from cannot_fetch_register,
21928 (sh_cannot_store_register): Renamed from cannot_store_register,
21930 (the_low_target): New.
21931 * linux-x86-64-low.c (x86_64_regmap): Renamed from regmap.
21932 (the_low_target): New.
21934 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
21936 * Makefile.in: Add stamp-h target.
21937 * configure.in: Create stamp-h.
21938 * configure: Regenerated.
21940 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
21942 * inferiors.c: New file.
21943 * target.c: New file.
21944 * target.h: New file.
21945 * Makefile.in: Add target.o and inferiors.o. Update
21947 * linux-low.c (inferior_pid): New static variable,
21948 moved from server.c.
21949 (linux_create_inferior): Renamed from create_inferior.
21950 Call add_inferior. Return 0 on success instead of a PID.
21951 (linux_attach): Renamed from myattach.
21952 (linux_kill): Renamed from kill_inferior. Call clear_inferiors ().
21953 (linux_thread_alive): Renamed from mythread_alive.
21954 (linux_wait): Renamed from mywait. Call clear_inferiors () if the
21956 (linux_resume): Renamed from myresume. Add missing ``return 0''.
21957 (regsets_store_inferior_registers): Correct error message.
21958 Add missing ``return 0''.
21959 (linux_fetch_registers): Renamed from fetch_inferior_registers.
21960 (linux_store_registers): Renamed from store_inferior_registers.
21961 (linux_read_memory): Renamed from read_inferior_memory.
21962 (linux_write_memory): Renamed from write_inferior_memory.
21963 (linux_target_ops): New structure.
21964 (initialize_low): Call set_target_ops ().
21965 * remote-utils.c (unhexify): New function.
21966 (hexify): New function.
21967 (input_interrupt): Send signals to ``signal_pid''.
21968 * server.c (inferior_pid): Remove.
21969 (start_inferior): Update create_inferior call.
21970 (attach_inferior): Call add_inferior.
21971 (handle_query): New function.
21972 (main): Call handle_query for `q' packets.
21973 * server.h: Include "target.h". Remove obsolete prototypes.
21974 Add prototypes for "inferiors.c", "target.c", hexify, and unhexify.
21976 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
21978 * Makefile.in: Add WARN_CFLAGS. Update configury
21980 * configure.in: Check for <string.h>
21981 * configure: Regenerate.
21982 * config.in: Regenerate.
21983 * gdbreplay.c: Include needed system headers.
21984 (remote_open): Remove strchr prototype.
21985 * linux-low.h: Correct #ifdef to HAVE_LINUX_USRREGS.
21986 * regcache.c (supply_register): Change buf argument to const void *.
21987 (supply_register_by_name): Likewise.
21988 (collect_register): Change buf argument to void *.
21989 (collect_register_by_name): Likewise.
21990 * regcache.h: Add missing prototypes.
21991 * remote-utils.c: Include <arpa/inet.h> for inet_ntoa.
21992 * server.c (handle_query): New function.
21993 (attached): New static variable, moved out of main.
21994 (main): Quiet longjmp clobber warnings.
21995 * server.h: Add ATTR_NORETURN and ATTR_FORMAT. Update prototypes.
21996 * utils.c (error): Remove NORETURN.